summaryrefslogtreecommitdiff
path: root/www/wiki/extensions
diff options
context:
space:
mode:
authorYaco <franco@reevo.org>2019-07-31 14:50:50 -0300
committerYaco <franco@reevo.org>2019-07-31 14:50:50 -0300
commit3848848fc3bc2db035c824f1453635949505d76e (patch)
tree71fd898ebb220e7ba034cf2bc1bf708fdd0d6219 /www/wiki/extensions
parent2dfe0b926fe5c6c4f27ad1f9bc1c1377cb091111 (diff)
ACTUALIZA MW a 1.31.3, SMW a 3.0.2 y extensiones menores
Diffstat (limited to 'www/wiki/extensions')
-rw-r--r--www/wiki/extensions/CategoryByList/CategoryByList.i18n.php14
-rw-r--r--www/wiki/extensions/CategoryByList/CategoryByListHooks.php24
-rw-r--r--www/wiki/extensions/CategoryByList/extension.json24
-rw-r--r--www/wiki/extensions/CategoryTree/CODE_OF_CONDUCT.md1
-rw-r--r--www/wiki/extensions/CategoryTree/COPYING339
-rw-r--r--www/wiki/extensions/CategoryTree/CategoryTree.alias.php507
-rw-r--r--www/wiki/extensions/CategoryTree/CategoryTree.i18n.magic.php263
-rw-r--r--www/wiki/extensions/CategoryTree/CategoryTree.php48
-rw-r--r--www/wiki/extensions/CategoryTree/Gruntfile.js43
-rw-r--r--www/wiki/extensions/CategoryTree/README18
-rw-r--r--www/wiki/extensions/CategoryTree/composer.json20
-rw-r--r--www/wiki/extensions/CategoryTree/extension.json143
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ace.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ady-cyrl.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/aeb-arab.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/aeb-latn.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/aeb.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/af.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ais.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/am.json23
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/an.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ang.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/anp.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ar.json49
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/arc.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/arq.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/arz.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/as.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ase.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ast.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/atj.json19
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/av.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/avk.json25
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/awa.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ay.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/az.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/azb.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ba.json43
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bar.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bbc-latn.json18
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bcc.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bcl.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/be-tarask.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/be.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bg.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bgn.json23
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bho.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bi.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bjn.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bn.json46
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bo.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bqi.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/br.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bs.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/bto.json26
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ca.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cbk-zam.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cdo.json20
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ce.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ceb.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ch.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ckb.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/co.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cop.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/crh-cyrl.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/crh-latn.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cs.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/csb.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cu.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cv.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/cy.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/da.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/de-ch.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/de-formal.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/de.json47
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/din.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/diq.json45
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/dsb.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/dtp.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/dty.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ee.json4
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/egl.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/el.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/en-gb.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/en.json45
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/eo.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/es.json52
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/et.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/eu.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ext.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fa.json48
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fi.json45
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fit.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fo.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fr.json51
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/frc.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/frp.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/frr.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fur.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/fy.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ga.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gcf.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gcr.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gd.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gl.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/glk.json22
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gn.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gom-deva.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gom-latn.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gor.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/got.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/grc.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gsw.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gu.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/gv.json19
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ha.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hak.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/haw.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/he.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hi.json47
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hif-latn.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hoc.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hr.json45
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hrx.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hsb.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ht.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hu-formal.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hu.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hy.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/hyw.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ia.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/id.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ie.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ig.json21
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ilo.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/inh.json31
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/io.json26
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/is.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/it.json49
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ja.json50
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/jam.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/jut.json31
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/jv.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ka.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kaa.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kab.json16
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kbp.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kea.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/khw.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kk-arab.json21
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kk-cyrl.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kk-latn.json21
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/km.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kn.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ko.json49
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/krc.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kri.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/krj.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/krl.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ks-arab.json6
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ksh.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ku-latn.json31
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kum.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/kw.json17
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ky.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/la.json32
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lad.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lag.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lb.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lez.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lfn.json17
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/li.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lij.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lki.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lmo.json27
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ln.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lo.json30
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lrc.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lt.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ltg.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lus.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/luz.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lv.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lzh.json17
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/lzz.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mai.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/map-bms.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mg.json20
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mhr.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/min.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mk.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ml.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mn.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mo.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mr.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ms.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mt.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mui.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mwl.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/my.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/myv.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/mzn.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/na.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nah.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nan.json17
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nap.json39
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nb.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nds-nl.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nds.json30
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ne.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/niu.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nl-informal.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nl.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nn.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nso.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/nys.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/oc.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/olo.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/or.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/os.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pa.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pag.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pam.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pcd.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pdc.json30
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pfl.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pih.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pl.json44
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pms.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pnb.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pnt.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/prs.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ps.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pt-br.json48
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/pt.json47
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/qqq.json63
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/qu.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/qwh.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/rif.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/rm.json20
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ro.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/roa-tara.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ru.json46
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/rue.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sa.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sah.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sat.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sc.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/scn.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sco.json35
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sd.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sdc.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sdh.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sgs.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sh.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/shi.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/shn.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/shy-latn.json9
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/si.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sk.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/skr-arab.json31
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sl.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sm.json8
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/so.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sq.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sr-ec.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sr-el.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/st.json16
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/stq.json30
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sty.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/su.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sv.json48
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/sw.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/szl.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ta.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tay.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tcy.json22
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/te.json40
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tet.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tg-cyrl.json32
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tg-latn.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/th.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tk.json30
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tl.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tly.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/to.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tpi.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tr.json42
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tru.json18
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ts.json10
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tt-cyrl.json43
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tt-latn.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tyv.json13
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/tzm.json19
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/udm.json15
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ug-arab.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/uk.json45
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/ur.json41
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/uz.json11
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/vec.json36
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/vep.json26
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/vi.json38
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/vls.json4
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/vo.json34
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/vro.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/wa.json28
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/war.json16
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/wo.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/wuu.json29
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/xal.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/xmf.json12
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/yi.json37
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/yo.json33
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/yue.json43
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/zea.json31
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/zgh.json14
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/zh-hans.json48
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/zh-hant.json50
-rw-r--r--www/wiki/extensions/CategoryTree/i18n/zu.json5
-rw-r--r--www/wiki/extensions/CategoryTree/includes/ApiCategoryTree.php143
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTree.php822
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryPage.php23
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryViewer.php78
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTreeHidePrefix.php39
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTreeHooks.php321
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTreeMode.php38
-rw-r--r--www/wiki/extensions/CategoryTree/includes/CategoryTreePage.php214
-rw-r--r--www/wiki/extensions/CategoryTree/modules/ext.categoryTree.css118
-rw-r--r--www/wiki/extensions/CategoryTree/modules/ext.categoryTree.js205
-rw-r--r--www/wiki/extensions/CategoryTree/tests/phan/config.php9
-rw-r--r--www/wiki/extensions/Cite/Gruntfile.js39
-rw-r--r--www/wiki/extensions/Cite/MIT-LICENSE.txt4
-rw-r--r--www/wiki/extensions/Cite/composer.json17
-rw-r--r--www/wiki/extensions/Cite/extension.json11
-rw-r--r--www/wiki/extensions/Cite/i18n/ais.json17
-rw-r--r--www/wiki/extensions/Cite/i18n/an.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/arz.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/as.json6
-rw-r--r--www/wiki/extensions/Cite/i18n/bcc.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/bcl.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/bg.json8
-rw-r--r--www/wiki/extensions/Cite/i18n/ca.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ckb.json10
-rw-r--r--www/wiki/extensions/Cite/i18n/cy.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/da.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/de-formal.json3
-rw-r--r--www/wiki/extensions/Cite/i18n/de.json4
-rw-r--r--www/wiki/extensions/Cite/i18n/diq.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/dsb.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/el.json7
-rw-r--r--www/wiki/extensions/Cite/i18n/eo.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/es.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/fa.json8
-rw-r--r--www/wiki/extensions/Cite/i18n/fi.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/fr.json18
-rw-r--r--www/wiki/extensions/Cite/i18n/frp.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/fy.json3
-rw-r--r--www/wiki/extensions/Cite/i18n/gcr.json8
-rw-r--r--www/wiki/extensions/Cite/i18n/gsw.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/gu.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/hr.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/hsb.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ht.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/hu.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/id.json24
-rw-r--r--www/wiki/extensions/Cite/i18n/ilo.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/io.json15
-rw-r--r--www/wiki/extensions/Cite/i18n/is.json9
-rw-r--r--www/wiki/extensions/Cite/i18n/ja.json4
-rw-r--r--www/wiki/extensions/Cite/i18n/ka.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/kk-cyrl.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ksh.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/kum.json8
-rw-r--r--www/wiki/extensions/Cite/i18n/lb.json2
-rw-r--r--www/wiki/extensions/Cite/i18n/li.json13
-rw-r--r--www/wiki/extensions/Cite/i18n/lij.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/lki.json6
-rw-r--r--www/wiki/extensions/Cite/i18n/lrc.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/lt.json6
-rw-r--r--www/wiki/extensions/Cite/i18n/lv.json7
-rw-r--r--www/wiki/extensions/Cite/i18n/min.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ml.json10
-rw-r--r--www/wiki/extensions/Cite/i18n/mr.json28
-rw-r--r--www/wiki/extensions/Cite/i18n/ms.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/mt.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/mwl.json7
-rw-r--r--www/wiki/extensions/Cite/i18n/nap.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/nds.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/nl.json6
-rw-r--r--www/wiki/extensions/Cite/i18n/nn.json4
-rw-r--r--www/wiki/extensions/Cite/i18n/nys.json8
-rw-r--r--www/wiki/extensions/Cite/i18n/oc.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/or.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/pms.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/pnb.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ps.json7
-rw-r--r--www/wiki/extensions/Cite/i18n/pt.json2
-rw-r--r--www/wiki/extensions/Cite/i18n/qqq.json7
-rw-r--r--www/wiki/extensions/Cite/i18n/qu.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ro.json19
-rw-r--r--www/wiki/extensions/Cite/i18n/ru.json5
-rw-r--r--www/wiki/extensions/Cite/i18n/rue.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sa.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sah.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sat.json5
-rw-r--r--www/wiki/extensions/Cite/i18n/scn.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sco.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/si.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sk.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sq.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sr-ec.json26
-rw-r--r--www/wiki/extensions/Cite/i18n/sr-el.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/stq.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/sv.json4
-rw-r--r--www/wiki/extensions/Cite/i18n/tg-cyrl.json5
-rw-r--r--www/wiki/extensions/Cite/i18n/tg-latn.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/th.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/tl.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/ur.json12
-rw-r--r--www/wiki/extensions/Cite/i18n/vec.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/yo.json5
-rw-r--r--www/wiki/extensions/Cite/i18n/yue.json1
-rw-r--r--www/wiki/extensions/Cite/i18n/zh-hant.json9
-rw-r--r--www/wiki/extensions/Cite/includes/ApiQueryReferences.php17
-rw-r--r--www/wiki/extensions/Cite/includes/Cite.php166
-rw-r--r--www/wiki/extensions/Cite/includes/CiteCSSFileModule.php10
-rw-r--r--www/wiki/extensions/Cite/includes/CiteDataModule.php19
-rw-r--r--www/wiki/extensions/Cite/includes/CiteHooks.php92
-rw-r--r--www/wiki/extensions/Cite/modules/ext.cite.style.css30
-rw-r--r--www/wiki/extensions/Cite/modules/ext.cite.style.fa.css6
-rw-r--r--www/wiki/extensions/Cite/modules/ext.cite.styles.css3
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ace.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ais.json11
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/am.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ar.json8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/arc.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/arq.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ast.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ay.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/az.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/bcl.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/be-tarask.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/be.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/bg.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/bho.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/bn.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/br.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ca.json7
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/co.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/cs.json13
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/cu.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/da.json8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/de.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/dsb.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/egl.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/el.json11
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/eml.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/en.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/eo.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/es.json6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/et.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/eu.json9
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/fa.json38
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/fo.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/fr.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/frr.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/fur.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/fy.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ga.json8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/gl.json1
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/glk.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-deva.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-latn.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/gsw.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/he.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/hi.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/hr.json6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/hsb.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/hu-formal.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/hu.json19
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/hy.json7
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ia.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/id.json18
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ie.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ilo.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/is.json9
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/it.json1
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ja.json25
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/jbo.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/jv.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ka.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/kk-cyrl.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/km.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/kn.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ko.json6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/krc.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ku-latn.json17
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/kw.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ky.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/lb.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/li.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/lki.json8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/lmo.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/lt.json7
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/luz.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/lv.json16
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/lzh.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/min.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/mk.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ml.json6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/mn.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/mr.json24
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ms.json23
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/mt.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/mwl.json3
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/my.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/nah.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/nap.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/nb.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/nds-nl.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/nds.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/nl.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/oc.json8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/or.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/pfl.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/pms.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/pt-br.json9
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/pt.json10
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/qqq.json10
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/qu.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/rm.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ro.json21
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/roa-tara.json1
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ru.json10
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sa.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sah.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sc.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/scn.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sco.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sd.json7
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sdc.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sh.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/shn.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/si.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sk.json15
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-ec.json31
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-el.json31
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sv.json5
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/sw.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ta.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/tay.json6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/te.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/tg-cyrl.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/th.json14
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/tl.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ug-arab.json6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/uk.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/ur.json16
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/uz.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/vec.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/vo.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/war.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/xmf.json2
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/yi.json13
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/yue.json4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hans.json8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hant.json22
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-book.svg8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-ltr.svg12
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-rtl.svg12
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-ltr.svg18
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-rtl.svg18
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-web.svg10
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-ltr.svg10
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-rtl.svg10
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/reference-ltr.svg8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/reference-rtl.svg8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/references-ltr.svg8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/icons/references-rtl.svg8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Converter.test.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.InternalList.test.js8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Transaction.test.js100
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.citeExample.js294
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.DiffElement.test.js67
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.MWWikitextStringTransferHandler.test.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.css4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.css6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.js63
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceModel.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceNode.js16
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferencesListNode.js121
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationAction.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationContextItem.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialog.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialogTool.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReference.init.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.css6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialog.js8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialogTool.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.css6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.css6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.css6
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.js8
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListCommand.js4
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListContextItem.js20
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListDialog.js26
-rw-r--r--www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWUseExistingReferenceCommand.js4
-rw-r--r--www/wiki/extensions/Cite/tests/parser/citeParserTests.txt480
-rw-r--r--www/wiki/extensions/Cite/tests/phan/config.php7
-rw-r--r--www/wiki/extensions/CiteThisPage/composer.json17
-rw-r--r--www/wiki/extensions/CiteThisPage/extension.json10
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/ce.json2
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/cv.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/es.json2
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/frp.json2
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/fy.json3
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/ga.json5
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/gcr.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/got.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/hoc.json8
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/hy.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/ia.json2
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/ja.json4
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/kea.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/kum.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/li.json3
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/lij.json5
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/lrc.json7
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/mk.json2
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/mo.json10
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/mr.json8
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/mui.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/mwl.json3
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/nl.json4
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/nys.json9
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/pt.json2
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/sat.json10
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/sd.json3
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/sr-ec.json12
-rw-r--r--www/wiki/extensions/CiteThisPage/i18n/zgh.json6
-rw-r--r--www/wiki/extensions/CiteThisPage/includes/CiteThisPageHooks.php62
-rw-r--r--www/wiki/extensions/CiteThisPage/includes/SpecialCiteThisPage.php217
-rw-r--r--www/wiki/extensions/CiteThisPage/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/CodeEditor/CODE_OF_CONDUCT.md1
-rw-r--r--www/wiki/extensions/CodeEditor/COPYING349
-rw-r--r--www/wiki/extensions/CodeEditor/CodeEditor.php31
-rw-r--r--www/wiki/extensions/CodeEditor/Gruntfile.js46
-rw-r--r--www/wiki/extensions/CodeEditor/Makefile19
-rw-r--r--www/wiki/extensions/CodeEditor/composer.json23
-rw-r--r--www/wiki/extensions/CodeEditor/extension.json146
-rw-r--r--www/wiki/extensions/CodeEditor/hooks.txt4
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/af.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ar.json23
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ast.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/azb.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ba.json17
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/bcl.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/be-tarask.json11
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/bn.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/br.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/bs.json12
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ca.json17
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ce.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/cs.json22
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/da.json23
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/de.json22
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/diq.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/dsb.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/el.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/en.json22
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/eo.json12
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/es.json24
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/et.json19
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/fa.json18
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/fi.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/fo.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/fr.json26
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/gl.json24
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/he.json23
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/hi.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/hr.json18
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/hsb.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/hu.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ia.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/id.json11
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ilo.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/is.json14
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/it.json19
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ja.json20
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ka.json16
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/kk-cyrl.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/km.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ko.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ksh.json17
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/lb.json15
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/li.json22
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/lij.json17
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/lt.json14
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/lv.json12
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/mk.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ml.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ms.json11
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/mt.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/nb.json24
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/nl.json24
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/nn.json19
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/pl.json26
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/pms.json10
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/pt-br.json23
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/pt.json25
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/qqq.json25
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ro.json19
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/roa-tara.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ru.json25
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sco.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sd.json18
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/si.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sk.json23
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sl.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sr-ec.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sr-el.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/sv.json23
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ta.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/te.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/tl.json9
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/tr.json15
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ug-arab.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/uk.json25
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/ur.json8
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/vi.json21
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/zh-hans.json24
-rw-r--r--www/wiki/extensions/CodeEditor/i18n/zh-hant.json24
-rw-r--r--www/wiki/extensions/CodeEditor/images/gotoLine.svg8
-rw-r--r--www/wiki/extensions/CodeEditor/images/pilcrow.svg7
-rw-r--r--www/wiki/extensions/CodeEditor/images/wrapping.svg9
-rw-r--r--www/wiki/extensions/CodeEditor/includes/CodeEditorHooks.php63
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/LICENSE24
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ace.js20199
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-beautify.js334
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-elastic_tabstops_lite.js274
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-emmet.js1223
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-error_marker.js6
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-keybinding_menu.js170
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-language_tools.js1956
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-linking.js61
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-modelist.js209
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-searchbox.js508
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-settings_menu.js663
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-spellcheck.js71
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-split.js246
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-static_highlight.js161
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-statusbar.js53
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-textarea.js560
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-themelist.js62
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/ext-whitespace.js206
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/keybinding-emacs.js1181
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/keybinding-vim.js5598
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-abap.js214
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-abc.js261
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-actionscript.js267
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-ada.js87
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-apache_conf.js356
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-applescript.js271
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-asciidoc.js342
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-assembly_x86.js186
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-autohotkey.js235
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-batchfile.js223
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-bro.js327
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-c9search.js287
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-c_cpp.js487
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-cirru.js203
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-clojure.js307
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-cobol.js94
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-coffee.js392
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-coldfusion.js2567
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-csharp.js495
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-css.js699
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-curly.js2535
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-d.js513
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-dart.js689
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-diff.js139
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-django.js2565
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-dockerfile.js492
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-dot.js410
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-drools.js457
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-eiffel.js128
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-ejs.js2999
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-elixir.js494
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-elm.js299
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-erlang.js1002
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-forth.js290
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-fortran.js423
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-ftl.js1182
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-gcode.js86
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-gherkin.js163
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-gitignore.js52
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-glsl.js564
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-gobstones.js922
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-golang.js406
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-graphqlschema.js206
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-groovy.js980
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-haml.js1547
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-handlebars.js2593
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-haskell.js372
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-haskell_cabal.js134
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-haxe.js379
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-hjson.js346
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-html.js2480
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-html_elixir.js3059
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-html_ruby.js3016
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-ini.js155
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-io.js246
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-jack.js339
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-jade.js2129
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-java.js935
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-javascript.js789
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-json.js319
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-jsoniq.js2619
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-jsp.js1388
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-jsx.js404
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-julia.js296
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-kotlin.js786
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-latex.js289
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-less.js819
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-liquid.js1184
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-lisp.js105
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-livescript.js271
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-logiql.js310
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-lsl.js335
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-lua.js424
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-luapage.js2978
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-lucene.js70
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-makefile.js404
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-markdown.js2865
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-mask.js1786
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-matlab.js256
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-maze.js284
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-mel.js256
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-mushcode.js674
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-mysql.js160
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-nix.js631
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-nsis.js305
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-objectivec.js725
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-ocaml.js414
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-pascal.js198
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-perl.js373
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-pgsql.js1500
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-php.js12856
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-pig.js303
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-plain_text.js25
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-powershell.js411
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-praat.js468
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-prolog.js364
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-properties.js73
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-protobuf.js577
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-python.js265
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-r.js301
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-razor.js2845
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-rdoc.js236
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-rhtml.js2779
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-rst.js249
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-ruby.js491
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-rust.js272
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-sass.js434
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-scad.js407
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-scala.js975
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-scheme.js225
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-scss.js586
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-sh.js441
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-sjs.js1006
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-smarty.js2606
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-snippets.js199
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-soy_template.js2819
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-space.js160
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-sparql.js313
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-sql.js103
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-sqlserver.js437
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-stylus.js462
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-svg.js1568
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-swift.js382
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-tcl.js376
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-tex.js152
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-text.js1
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-textile.js142
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-toml.js146
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-tsx.js891
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-turtle.js289
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-twig.js2664
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-typescript.js872
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-vala.js669
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-vbscript.js199
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-velocity.js2762
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-verilog.js104
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-vhdl.js110
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-wollok.js905
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-xml.js664
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-xquery.js2631
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/mode-yaml.js289
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/abap.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/abc.js38
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/actionscript.js164
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/ada.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/apache_conf.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/applescript.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/asciidoc.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/assembly_x86.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/autohotkey.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/batchfile.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/bro.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/c9search.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/c_cpp.js138
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/cirru.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/clojure.js97
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/cobol.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/coffee.js102
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/coldfusion.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/csharp.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/css.js974
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/curly.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/d.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/dart.js90
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/diff.js18
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/django.js115
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/dockerfile.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/dot.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/drools.js26
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/eiffel.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/ejs.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/elixir.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/elm.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/erlang.js167
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/forth.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/fortran.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/ftl.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/gcode.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/gherkin.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/gitignore.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/glsl.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/gobstones.js41
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/golang.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/graphqlschema.js39
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/groovy.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/haml.js27
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/handlebars.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell.js89
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell_cabal.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/haxe.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/hjson.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/html.js862
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/html_elixir.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/html_ruby.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/ini.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/io.js69
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/jack.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/jade.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/java.js247
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/javascript.js202
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/json.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/jsoniq.js68
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/jsp.js106
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/jsx.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/julia.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/kotlin.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/latex.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/less.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/liquid.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/lisp.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/livescript.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/logiql.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/lsl.js1239
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/lua.js28
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/luapage.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/lucene.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/makefile.js11
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/markdown.js95
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/mask.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/matlab.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/maze.js16
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/mel.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/mushcode.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/mysql.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/nix.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/nsis.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/objectivec.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/ocaml.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/pascal.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/perl.js354
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/pgsql.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/php.js384
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/pig.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/plain_text.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/powershell.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/praat.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/prolog.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/properties.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/protobuf.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/python.js165
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/r.js128
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/razor.js10
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/rdoc.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/rhtml.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/rst.js29
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/ruby.js935
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/rust.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/sass.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/scad.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/scala.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/scheme.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/scss.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/sh.js90
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/sjs.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/smarty.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/snippets.js16
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/soy_template.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/space.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/sparql.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/sql.js33
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/sqlserver.js76
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/stylus.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/svg.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/swift.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/tcl.js99
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/tex.js197
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/text.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/textile.js37
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/toml.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/tsx.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/turtle.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/twig.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/typescript.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/vala.js193
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/vbscript.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/velocity.js36
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/verilog.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/vhdl.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/wollok.js91
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/xml.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/xquery.js68
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/snippets/yaml.js7
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-ambiance.js182
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-chaos.js156
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-chrome.js128
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-clouds.js95
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-clouds_midnight.js96
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-cobalt.js113
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-crimson_editor.js118
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-dawn.js108
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-dreamweaver.js141
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-eclipse.js98
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-github.js103
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-gob.js112
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-gruvbox.js82
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-idle_fingers.js96
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-iplastic.js121
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-katzenmilch.js121
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-kr_theme.js104
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-kuroir.js61
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore.js95
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore_soft.js96
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-mono_industrial.js107
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-monokai.js105
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-pastel_on_dark.js108
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_dark.js88
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_light.js91
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-sqlserver.js138
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-terminal.js114
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-textmate.js129
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow.js108
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night.js108
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_blue.js106
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_bright.js121
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_eighties.js108
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-twilight.js109
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-vibrant_ink.js94
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/theme-xcode.js88
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-coffee.js2157
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-css.js8761
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-html.js11605
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-javascript.js12528
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-json.js2396
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-lua.js3632
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-php.js4302
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-xml.js3887
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ace/worker-xquery.js58351
-rw-r--r--www/wiki/extensions/CodeEditor/modules/ext.codeEditor.js36
-rw-r--r--www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.js851
-rw-r--r--www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.less75
-rw-r--r--www/wiki/extensions/CodeEditor/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/ConfirmEdit/ConfirmEdit.alias.php5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/ApiFancyCaptchaReload.php1
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/FancyCaptcha.class.php51
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/HTMLFancyCaptchaField.php22
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/extension.json3
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ais.json13
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/am.json3
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ang.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ar.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/av.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bg.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bto.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/cdo.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ce.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/chr.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-cyrl.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-latn.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/diq.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ee.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/el.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/es.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fa.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fr.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/frp.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fy.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/gcr.json11
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/got.json9
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/haw.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hi.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hrx.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ht.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hyw.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/id.json3
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/io.json3
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/jv.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kg.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ku-latn.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kum.json12
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kw.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ky.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lij.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lmo.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lrc.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lt.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/map-bms.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mfe.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/min.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mn.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mo.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mwl.json12
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/myv.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nan.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nds-nl.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nl.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nys.json11
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/os.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ppl.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ps.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/pt.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rmf.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ro.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rup.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sah.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sat.json11
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sc.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ses.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/so.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sw.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/tl.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/uz.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/wa.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zgh.json9
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hans.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hant.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/FancyCaptcha/resources/ext.confirmEdit.fancyCaptcha.js6
-rw-r--r--www/wiki/extensions/ConfirmEdit/MathCaptcha/MathCaptcha.class.php15
-rw-r--r--www/wiki/extensions/ConfirmEdit/QuestyCaptcha/QuestyCaptcha.class.php4
-rw-r--r--www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/cs.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/io.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/lb.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/pt.json7
-rw-r--r--www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/zh-hans.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptcha/ReCaptcha.class.php10
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/ja.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hans.json10
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hant.json22
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/ReCaptchaNoCaptcha.class.php17
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/pt-br.json16
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/qqq.json18
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hans.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hant.json17
-rw-r--r--www/wiki/extensions/ConfirmEdit/SimpleCaptcha/Captcha.php147
-rw-r--r--www/wiki/extensions/ConfirmEdit/composer.json18
-rw-r--r--www/wiki/extensions/ConfirmEdit/extension.json15
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/aa.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ais.json17
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/bg.json6
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/bi.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ce.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ch.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/chr.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/cs.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/el.json28
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/fa.json28
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/fi.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/fr.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/fy.json3
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/gcr.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/gl.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/hi.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/hr.json3
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/is.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ja.json19
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/jv.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ka.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/kum.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/lb.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/li.json15
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/lv.json1
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ml.json24
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/mwl.json9
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/myv.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/na.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/niu.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/nys.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/or.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/pih.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/pt.json7
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/qqq.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ro.json17
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/sah.json4
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/sat.json9
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/sm.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/tay.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/tg-cyrl.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/tg-latn.json5
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/to.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/ur.json23
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/uz.json8
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/wuu.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/zh-hans.json2
-rw-r--r--www/wiki/extensions/ConfirmEdit/i18n/zh-hant.json24
-rw-r--r--www/wiki/extensions/ConfirmEdit/includes/CaptchaTriggers.php17
-rw-r--r--www/wiki/extensions/ConfirmEdit/includes/ConfirmEditHooks.php13
-rw-r--r--www/wiki/extensions/ConfirmEdit/includes/store/CaptchaCacheStore.php30
-rw-r--r--www/wiki/extensions/ConfirmEdit/includes/store/CaptchaHashStore.php28
-rw-r--r--www/wiki/extensions/ConfirmEdit/includes/store/CaptchaSessionStore.php26
-rw-r--r--www/wiki/extensions/ConfirmEdit/includes/store/CaptchaStore.php66
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaAuthenticationRequestTest.php4
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaPreAuthenticationProviderTest.php6
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLFancyCaptchaFieldTest.php5
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaFieldTest.php5
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaNoCaptchaFieldTest.php5
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLSubmittedValueFieldTest.php5
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/QuestyCaptchaTest.php17
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaAuthenticationRequestTest.php3
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaNoCaptchaAuthenticationRequestTest.php3
-rw-r--r--www/wiki/extensions/ConfirmEdit/tests/phpunit/SimpleCaptcha/CaptchaTest.php116
-rw-r--r--www/wiki/extensions/Gadgets/Gadgets.alias.php6
-rw-r--r--www/wiki/extensions/Gadgets/Gadgets.namespaces.php21
-rw-r--r--www/wiki/extensions/Gadgets/composer.json17
-rw-r--r--www/wiki/extensions/Gadgets/extension.json17
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ais.json30
-rw-r--r--www/wiki/extensions/Gadgets/i18n/as.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/be.json8
-rw-r--r--www/wiki/extensions/Gadgets/i18n/bg.json12
-rw-r--r--www/wiki/extensions/Gadgets/i18n/bho.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ca.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/diq.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/es.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/fa.json17
-rw-r--r--www/wiki/extensions/Gadgets/i18n/he.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/hy.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/id.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/io.json8
-rw-r--r--www/wiki/extensions/Gadgets/i18n/is.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ja.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/jv.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ksh.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/lb.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/mg.json16
-rw-r--r--www/wiki/extensions/Gadgets/i18n/min.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/mr.json6
-rw-r--r--www/wiki/extensions/Gadgets/i18n/mwl.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/nl.json20
-rw-r--r--www/wiki/extensions/Gadgets/i18n/pl.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/pt-br.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ro.json19
-rw-r--r--www/wiki/extensions/Gadgets/i18n/roa-tara.json7
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ru.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/sd.json2
-rw-r--r--www/wiki/extensions/Gadgets/i18n/sr-ec.json6
-rw-r--r--www/wiki/extensions/Gadgets/i18n/tay.json5
-rw-r--r--www/wiki/extensions/Gadgets/i18n/ur.json6
-rw-r--r--www/wiki/extensions/Gadgets/i18n/zh-hant.json8
-rw-r--r--www/wiki/extensions/Gadgets/includes/Gadget.php315
-rw-r--r--www/wiki/extensions/Gadgets/includes/GadgetDefinitionNamespaceRepo.php39
-rw-r--r--www/wiki/extensions/Gadgets/includes/GadgetHooks.php342
-rw-r--r--www/wiki/extensions/Gadgets/includes/GadgetRepo.php35
-rw-r--r--www/wiki/extensions/Gadgets/includes/GadgetResourceLoaderModule.php2
-rw-r--r--www/wiki/extensions/Gadgets/includes/MediaWikiGadgetsDefinitionRepo.php16
-rw-r--r--www/wiki/extensions/Gadgets/includes/SpecialGadgetUsage.php252
-rw-r--r--www/wiki/extensions/Gadgets/includes/SpecialGadgets.php232
-rw-r--r--www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgetCategories.php110
-rw-r--r--www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgets.php231
-rw-r--r--www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionContent.php7
-rw-r--r--www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionDeletionUpdate.php18
-rw-r--r--www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionSecondaryDataUpdate.php17
-rw-r--r--www/wiki/extensions/Gadgets/tests/phan/config.php7
-rw-r--r--www/wiki/extensions/Gadgets/tests/phpunit/GadgetTest.php43
-rw-r--r--www/wiki/extensions/ImageMap/Gruntfile.js3
-rw-r--r--www/wiki/extensions/ImageMap/composer.json26
-rw-r--r--www/wiki/extensions/ImageMap/extension.json7
-rw-r--r--www/wiki/extensions/ImageMap/i18n/ais.json16
-rw-r--r--www/wiki/extensions/ImageMap/i18n/bg.json21
-rw-r--r--www/wiki/extensions/ImageMap/i18n/hu.json23
-rw-r--r--www/wiki/extensions/ImageMap/i18n/id.json19
-rw-r--r--www/wiki/extensions/ImageMap/i18n/ko.json5
-rw-r--r--www/wiki/extensions/ImageMap/i18n/nb.json6
-rw-r--r--www/wiki/extensions/ImageMap/i18n/pt.json4
-rw-r--r--www/wiki/extensions/ImageMap/i18n/sat.json8
-rw-r--r--www/wiki/extensions/ImageMap/i18n/ur.json12
-rw-r--r--www/wiki/extensions/ImageMap/includes/ImageMap.php406
-rw-r--r--www/wiki/extensions/ImageMap/tests/parser/imageMapParserTests.txt10
-rw-r--r--www/wiki/extensions/ImageMap/tests/phan/config.php11
-rw-r--r--www/wiki/extensions/InputBox/composer.json17
-rw-r--r--www/wiki/extensions/InputBox/extension.json11
-rw-r--r--www/wiki/extensions/InputBox/i18n/ais.json4
-rw-r--r--www/wiki/extensions/InputBox/i18n/bg.json5
-rw-r--r--www/wiki/extensions/InputBox/i18n/ckb.json3
-rw-r--r--www/wiki/extensions/InputBox/i18n/csb.json6
-rw-r--r--www/wiki/extensions/InputBox/i18n/frp.json2
-rw-r--r--www/wiki/extensions/InputBox/i18n/gcr.json8
-rw-r--r--www/wiki/extensions/InputBox/i18n/id.json6
-rw-r--r--www/wiki/extensions/InputBox/i18n/is.json6
-rw-r--r--www/wiki/extensions/InputBox/i18n/km.json6
-rw-r--r--www/wiki/extensions/InputBox/i18n/kum.json8
-rw-r--r--www/wiki/extensions/InputBox/i18n/mwl.json9
-rw-r--r--www/wiki/extensions/InputBox/i18n/nb.json3
-rw-r--r--www/wiki/extensions/InputBox/i18n/nys.json8
-rw-r--r--www/wiki/extensions/InputBox/i18n/sat.json5
-rw-r--r--www/wiki/extensions/InputBox/i18n/tay.json3
-rw-r--r--www/wiki/extensions/InputBox/i18n/ur.json6
-rw-r--r--www/wiki/extensions/InputBox/includes/InputBox.php729
-rw-r--r--www/wiki/extensions/InputBox/includes/InputBoxHooks.php108
-rw-r--r--www/wiki/extensions/InputBox/tests/parser/inputBoxParserTests.txt240
-rw-r--r--www/wiki/extensions/InputBox/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/Interwiki/Interwiki.css4
-rw-r--r--www/wiki/extensions/Interwiki/composer.json21
-rw-r--r--www/wiki/extensions/Interwiki/extension.json13
-rw-r--r--www/wiki/extensions/Interwiki/i18n/ar.json22
-rw-r--r--www/wiki/extensions/Interwiki/i18n/ast.json6
-rw-r--r--www/wiki/extensions/Interwiki/i18n/avk.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/bg.json13
-rw-r--r--www/wiki/extensions/Interwiki/i18n/de.json2
-rw-r--r--www/wiki/extensions/Interwiki/i18n/es.json2
-rw-r--r--www/wiki/extensions/Interwiki/i18n/fa.json18
-rw-r--r--www/wiki/extensions/Interwiki/i18n/fy.json3
-rw-r--r--www/wiki/extensions/Interwiki/i18n/got.json2
-rw-r--r--www/wiki/extensions/Interwiki/i18n/hr.json2
-rw-r--r--www/wiki/extensions/Interwiki/i18n/is.json12
-rw-r--r--www/wiki/extensions/Interwiki/i18n/ja.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/lb.json10
-rw-r--r--www/wiki/extensions/Interwiki/i18n/li.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/lzh.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/mk.json8
-rw-r--r--www/wiki/extensions/Interwiki/i18n/mr.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/mwl.json3
-rw-r--r--www/wiki/extensions/Interwiki/i18n/myv.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/pt.json13
-rw-r--r--www/wiki/extensions/Interwiki/i18n/skr-arab.json17
-rw-r--r--www/wiki/extensions/Interwiki/i18n/sr-ec.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/vo.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/yue.json5
-rw-r--r--www/wiki/extensions/Interwiki/i18n/zh-hans.json3
-rw-r--r--www/wiki/extensions/Interwiki/i18n/zh-hant.json11
-rw-r--r--www/wiki/extensions/Interwiki/includes/InterwikiHooks.php54
-rw-r--r--www/wiki/extensions/Interwiki/includes/InterwikiLogFormatter.php17
-rw-r--r--www/wiki/extensions/Interwiki/includes/SpecialInterwiki.php498
-rw-r--r--www/wiki/extensions/Interwiki/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/LocalisationUpdate/Gruntfile.js3
-rw-r--r--www/wiki/extensions/LocalisationUpdate/composer.json21
-rw-r--r--www/wiki/extensions/LocalisationUpdate/extension.json28
-rw-r--r--www/wiki/extensions/LocalisationUpdate/i18n/ca.json5
-rw-r--r--www/wiki/extensions/LocalisationUpdate/i18n/es.json5
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/LocalisationUpdate.php73
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/QuickArrayReader.php214
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/Updater.php204
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/fetcher/Fetcher.php30
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/fetcher/FetcherFactory.php25
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/fetcher/FileSystemFetcher.php47
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/fetcher/GitHubFetcher.php47
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/fetcher/HttpFetcher.php49
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/finder/Finder.php124
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/reader/JSONReader.php37
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/reader/PHPReader.php61
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/reader/Reader.php21
-rw-r--r--www/wiki/extensions/LocalisationUpdate/includes/reader/ReaderFactory.php38
-rw-r--r--www/wiki/extensions/LocalisationUpdate/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/LocalisationUpdate/tests/phpunit/UpdaterTest.php11
-rw-r--r--www/wiki/extensions/LocalisationUpdate/tests/phpunit/finder/FinderTest.php7
-rw-r--r--www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/JSONReaderTest.php7
-rw-r--r--www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/ReaderFactoryTest.php7
-rw-r--r--www/wiki/extensions/LocalisationUpdate/update.php23
-rw-r--r--www/wiki/extensions/Maps/.gitignore13
-rw-r--r--www/wiki/extensions/Maps/.scrutinizer.yml12
-rw-r--r--www/wiki/extensions/Maps/.travis.install.sh66
-rw-r--r--www/wiki/extensions/Maps/.travis.yml31
-rw-r--r--www/wiki/extensions/Maps/COPYING347
-rw-r--r--www/wiki/extensions/Maps/DefaultSettings.php374
-rw-r--r--www/wiki/extensions/Maps/INSTALL.md267
-rw-r--r--www/wiki/extensions/Maps/ISSUE_TEMPLATE.md15
-rw-r--r--www/wiki/extensions/Maps/Maps.php14
-rw-r--r--www/wiki/extensions/Maps/Maps.resources.php92
-rw-r--r--www/wiki/extensions/Maps/MapsRegistration.php57
-rwxr-xr-xwww/wiki/extensions/Maps/Maps_Settings.php17
-rw-r--r--www/wiki/extensions/Maps/README.md105
-rw-r--r--www/wiki/extensions/Maps/RELEASE-NOTES.md1289
-rw-r--r--www/wiki/extensions/Maps/composer.json74
-rw-r--r--www/wiki/extensions/Maps/extension.json52
-rw-r--r--www/wiki/extensions/Maps/i18n/af.json27
-rw-r--r--www/wiki/extensions/Maps/i18n/aliases/Aliases.php129
-rw-r--r--www/wiki/extensions/Maps/i18n/aln.json19
-rw-r--r--www/wiki/extensions/Maps/i18n/ar.json227
-rw-r--r--www/wiki/extensions/Maps/i18n/arc.json15
-rw-r--r--www/wiki/extensions/Maps/i18n/arz.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/ast.json223
-rw-r--r--www/wiki/extensions/Maps/i18n/az.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/ba.json15
-rw-r--r--www/wiki/extensions/Maps/i18n/bar.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/be-tarask.json153
-rw-r--r--www/wiki/extensions/Maps/i18n/bg.json33
-rw-r--r--www/wiki/extensions/Maps/i18n/bjn.json11
-rw-r--r--www/wiki/extensions/Maps/i18n/bn.json114
-rw-r--r--www/wiki/extensions/Maps/i18n/br.json127
-rw-r--r--www/wiki/extensions/Maps/i18n/bs.json51
-rw-r--r--www/wiki/extensions/Maps/i18n/ca.json28
-rw-r--r--www/wiki/extensions/Maps/i18n/ce.json34
-rw-r--r--www/wiki/extensions/Maps/i18n/cs.json91
-rw-r--r--www/wiki/extensions/Maps/i18n/cu.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/cv.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/da.json64
-rw-r--r--www/wiki/extensions/Maps/i18n/de.json231
-rw-r--r--www/wiki/extensions/Maps/i18n/diq.json36
-rw-r--r--www/wiki/extensions/Maps/i18n/dsb.json77
-rw-r--r--www/wiki/extensions/Maps/i18n/el.json165
-rw-r--r--www/wiki/extensions/Maps/i18n/en-gb.json19
-rw-r--r--www/wiki/extensions/Maps/i18n/en.json225
-rw-r--r--www/wiki/extensions/Maps/i18n/eo.json15
-rw-r--r--www/wiki/extensions/Maps/i18n/es.json233
-rw-r--r--www/wiki/extensions/Maps/i18n/et.json40
-rw-r--r--www/wiki/extensions/Maps/i18n/eu.json78
-rw-r--r--www/wiki/extensions/Maps/i18n/fa.json194
-rw-r--r--www/wiki/extensions/Maps/i18n/fi.json158
-rw-r--r--www/wiki/extensions/Maps/i18n/fr.json243
-rw-r--r--www/wiki/extensions/Maps/i18n/frp.json84
-rw-r--r--www/wiki/extensions/Maps/i18n/fur.json12
-rw-r--r--www/wiki/extensions/Maps/i18n/fy.json11
-rw-r--r--www/wiki/extensions/Maps/i18n/ga.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/gl.json220
-rw-r--r--www/wiki/extensions/Maps/i18n/grc.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/gsw.json49
-rw-r--r--www/wiki/extensions/Maps/i18n/he.json217
-rw-r--r--www/wiki/extensions/Maps/i18n/hi.json26
-rw-r--r--www/wiki/extensions/Maps/i18n/hr.json92
-rw-r--r--www/wiki/extensions/Maps/i18n/hsb.json172
-rw-r--r--www/wiki/extensions/Maps/i18n/ht.json7
-rw-r--r--www/wiki/extensions/Maps/i18n/hu.json89
-rw-r--r--www/wiki/extensions/Maps/i18n/ia.json161
-rw-r--r--www/wiki/extensions/Maps/i18n/id.json139
-rw-r--r--www/wiki/extensions/Maps/i18n/ig.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/it.json163
-rw-r--r--www/wiki/extensions/Maps/i18n/ja.json176
-rw-r--r--www/wiki/extensions/Maps/i18n/jv.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/ka.json75
-rw-r--r--www/wiki/extensions/Maps/i18n/km.json18
-rw-r--r--www/wiki/extensions/Maps/i18n/ko.json208
-rw-r--r--www/wiki/extensions/Maps/i18n/ksh.json69
-rw-r--r--www/wiki/extensions/Maps/i18n/ku-latn.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/lad.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/lb.json123
-rw-r--r--www/wiki/extensions/Maps/i18n/lt.json119
-rw-r--r--www/wiki/extensions/Maps/i18n/lv.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/magic/MagicWords.php387
-rw-r--r--www/wiki/extensions/Maps/i18n/map-bms.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/mg.json24
-rw-r--r--www/wiki/extensions/Maps/i18n/mk.json226
-rw-r--r--www/wiki/extensions/Maps/i18n/ml.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/mr.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/ms.json158
-rw-r--r--www/wiki/extensions/Maps/i18n/mt.json48
-rw-r--r--www/wiki/extensions/Maps/i18n/myv.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/nah.json6
-rw-r--r--www/wiki/extensions/Maps/i18n/nb.json228
-rw-r--r--www/wiki/extensions/Maps/i18n/nds.json24
-rw-r--r--www/wiki/extensions/Maps/i18n/nl-informal.json12
-rw-r--r--www/wiki/extensions/Maps/i18n/nl.json206
-rw-r--r--www/wiki/extensions/Maps/i18n/nn.json20
-rw-r--r--www/wiki/extensions/Maps/i18n/oc.json74
-rw-r--r--www/wiki/extensions/Maps/i18n/or.json10
-rw-r--r--www/wiki/extensions/Maps/i18n/pa.json72
-rw-r--r--www/wiki/extensions/Maps/i18n/pdc.json11
-rw-r--r--www/wiki/extensions/Maps/i18n/pfl.json53
-rw-r--r--www/wiki/extensions/Maps/i18n/pl.json168
-rw-r--r--www/wiki/extensions/Maps/i18n/pms.json174
-rw-r--r--www/wiki/extensions/Maps/i18n/ps.json26
-rw-r--r--www/wiki/extensions/Maps/i18n/pt-br.json231
-rw-r--r--www/wiki/extensions/Maps/i18n/pt.json233
-rw-r--r--www/wiki/extensions/Maps/i18n/qqq.json235
-rw-r--r--www/wiki/extensions/Maps/i18n/ro.json96
-rw-r--r--www/wiki/extensions/Maps/i18n/roa-tara.json65
-rw-r--r--www/wiki/extensions/Maps/i18n/ru.json251
-rw-r--r--www/wiki/extensions/Maps/i18n/rue.json13
-rw-r--r--www/wiki/extensions/Maps/i18n/sco.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/si.json109
-rw-r--r--www/wiki/extensions/Maps/i18n/sk.json19
-rw-r--r--www/wiki/extensions/Maps/i18n/sl.json28
-rw-r--r--www/wiki/extensions/Maps/i18n/sq.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/sr-ec.json28
-rw-r--r--www/wiki/extensions/Maps/i18n/sr-el.json26
-rw-r--r--www/wiki/extensions/Maps/i18n/sv.json232
-rw-r--r--www/wiki/extensions/Maps/i18n/sw.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/ta.json63
-rw-r--r--www/wiki/extensions/Maps/i18n/te.json25
-rw-r--r--www/wiki/extensions/Maps/i18n/th.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/tl.json158
-rw-r--r--www/wiki/extensions/Maps/i18n/tr.json84
-rw-r--r--www/wiki/extensions/Maps/i18n/tzm.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/uk.json232
-rw-r--r--www/wiki/extensions/Maps/i18n/ur.json44
-rw-r--r--www/wiki/extensions/Maps/i18n/vep.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/vi.json107
-rw-r--r--www/wiki/extensions/Maps/i18n/vo.json9
-rw-r--r--www/wiki/extensions/Maps/i18n/wa.json8
-rw-r--r--www/wiki/extensions/Maps/i18n/yi.json11
-rw-r--r--www/wiki/extensions/Maps/i18n/zh-hans.json235
-rw-r--r--www/wiki/extensions/Maps/i18n/zh-hant.json235
-rw-r--r--www/wiki/extensions/Maps/phpunit.xml.dist29
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/ext.maps.googlemaps3.js25
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/ext.sm.googlemaps3ajax.js48
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ProjectedOverlay.js139
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/README5
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ZipFile.complete.js2172
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/geoxml3.js1855
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/README6
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/googleearth-compiled.js20
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerclusterer.js1637
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.css13
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.js568
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/img/blue-dot.pngbin0 -> 1274 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/GoogleMaps/jquery.googlemap.js900
-rw-r--r--www/wiki/extensions/Maps/resources/editor/css/jquery.miniColors.css70
-rw-r--r--www/wiki/extensions/Maps/resources/editor/css/mapeditor.css79
-rw-r--r--www/wiki/extensions/Maps/resources/editor/images/circle.gifbin0 -> 78 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/editor/images/gradient.pngbin0 -> 6548 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/editor/images/line.gifbin0 -> 1104 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/editor/images/rainbow.pngbin0 -> 1665 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/editor/images/trigger.pngbin0 -> 538 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/editor/js/README3
-rw-r--r--www/wiki/extensions/Maps/resources/editor/js/jquery.miniColors.js567
-rw-r--r--www/wiki/extensions/Maps/resources/editor/js/mapeditor.iefixes.js28
-rw-r--r--www/wiki/extensions/Maps/resources/editor/js/mapeditor.js919
-rw-r--r--www/wiki/extensions/Maps/resources/ext.maps.common.js4
-rw-r--r--www/wiki/extensions/Maps/resources/ext.maps.services.js86
-rw-r--r--www/wiki/extensions/Maps/resources/ext.sm.common.js76
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/cluster/m1.pngbin0 -> 3003 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/cluster/m2.pngbin0 -> 3259 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/cluster/m3.pngbin0 -> 3956 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/cluster/m4.pngbin0 -> 5705 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/cluster/m5.pngbin0 -> 6839 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/ext.maps.leaflet.js3
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/ext.sm.leafletajax.js44
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/jquery.leaflet.js434
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet-providers/leaflet-providers.js774
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.editable/Leaflet.Editable.js1945
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.editor.js15
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/.jshintrc12
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.css4
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.js164
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/LICENSE22
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/README.md68
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/bower.json30
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen-2x.pngbin0 -> 228 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen.pngbin0 -> 153 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/index.html48
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/package.json25
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/MarkerCluster.css14
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/leaflet.markercluster.js3
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers-2x.pngbin0 -> 1259 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers.pngbin0 -> 696 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon-2x.pngbin0 -> 2586 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon.pngbin0 -> 1466 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-shadow.pngbin0 -> 618 bytes
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.css635
-rw-r--r--www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.js5
-rw-r--r--www/wiki/extensions/Maps/src/DataAccess/CachingGeocoder.php46
-rw-r--r--www/wiki/extensions/Maps/src/DataAccess/JsonFileParser.php79
-rw-r--r--www/wiki/extensions/Maps/src/DataAccess/MapsFileFetcher.php26
-rw-r--r--www/wiki/extensions/Maps/src/DataAccess/MediaWikiFileUrlFinder.php31
-rw-r--r--www/wiki/extensions/Maps/src/DataAccess/PageContentFetcher.php40
-rw-r--r--www/wiki/extensions/Maps/src/Elements/BaseElement.php57
-rw-r--r--www/wiki/extensions/Maps/src/Elements/BaseFillableElement.php45
-rw-r--r--www/wiki/extensions/Maps/src/Elements/BaseStrokableElement.php63
-rw-r--r--www/wiki/extensions/Maps/src/Elements/Circle.php62
-rw-r--r--www/wiki/extensions/Maps/src/Elements/ImageOverlay.php36
-rw-r--r--www/wiki/extensions/Maps/src/Elements/Line.php69
-rw-r--r--www/wiki/extensions/Maps/src/Elements/Location.php157
-rw-r--r--www/wiki/extensions/Maps/src/Elements/Polygon.php44
-rw-r--r--www/wiki/extensions/Maps/src/Elements/Rectangle.php80
-rw-r--r--www/wiki/extensions/Maps/src/Elements/WmsOverlay.php71
-rw-r--r--www/wiki/extensions/Maps/src/FileUrlFinder.php18
-rw-r--r--www/wiki/extensions/Maps/src/GeoFunctions.php99
-rw-r--r--www/wiki/extensions/Maps/src/GoogleMapsService.php314
-rw-r--r--www/wiki/extensions/Maps/src/LeafletService.php184
-rw-r--r--www/wiki/extensions/Maps/src/MappingService.php33
-rw-r--r--www/wiki/extensions/Maps/src/MappingServices.php82
-rw-r--r--www/wiki/extensions/Maps/src/MapsFactory.php168
-rw-r--r--www/wiki/extensions/Maps/src/MapsFunctions.php218
-rw-r--r--www/wiki/extensions/Maps/src/MapsSetup.php462
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContent.php49
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContentHandler.php15
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/MapsHooks.php68
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/CoordinatesFunction.php102
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapFunction.php171
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapRenderer.php205
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DistanceFunction.php100
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/FindDestinationFunction.php120
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeoDistanceFunction.php117
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeocodeFunction.php113
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/MapsDocFunction.php200
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/SemanticMapsHooks.php115
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/Specials/MapEditorHTML.php221
-rw-r--r--www/wiki/extensions/Maps/src/MediaWiki/Specials/SpecialMapEditor.php69
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/CoordinateFormatter.php36
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/ElementJsonSerializer.php35
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/KmlFormatter.php78
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/MapsDistanceParser.php133
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/ParameterExtractor.php47
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParser.php30
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/CircleParser.php86
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/DistanceParser.php38
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/ImageOverlayParser.php83
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LineParser.php163
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LocationParser.php147
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/PolygonParser.php41
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/RectangleParser.php89
-rw-r--r--www/wiki/extensions/Maps/src/Presentation/WikitextParsers/WmsOverlayParser.php49
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMW/DataValues/CoordinateValue.php266
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/KmlPrinter.php146
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/MapPrinter.php423
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/QueryHandler.php511
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/AreaDescription.php146
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/CoordinateDescription.php74
-rw-r--r--www/wiki/extensions/Maps/src/SemanticMaps.php74
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/DataAccess/MediaWikiFileUrlFinderTest.php33
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/InitializationTest.php20
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MapsDistanceParserTest.php177
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MapsMapperTest.php42
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/CoordinatesTest.php125
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/DistanceTest.php91
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/FinddestinationTest.php94
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeocodeTest.php64
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeodistanceTest.php81
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/MapsDocTest.php54
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/ParserHookTest.php133
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/Parser/CoordinatesTest.php96
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/Parser/DisplayMapTest.php192
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/Semantic/ValueDescriptions/AreaDescriptionTest.php81
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/CircleParserTest.php43
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/DistanceParserTest.php66
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/JsonFileParserTest.php120
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/LineParserTest.php77
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/LocationParserTest.php119
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/RectlangleParserTest.php44
-rw-r--r--www/wiki/extensions/Maps/tests/Integration/parsers/WmsOverlayParserTest.php54
-rw-r--r--www/wiki/extensions/Maps/tests/System/SemanticMW/MapQueryTest.php93
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/BaseElementTest.php85
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/CircleTest.php70
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/ImageOverlayTest.php52
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/LineTest.php74
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/LocationTest.php36
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/PolygonTest.php68
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Elements/RectangleTest.php73
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Presentation/KmlFormatterTest.php88
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Presentation/ParameterExtractorTest.php80
-rw-r--r--www/wiki/extensions/Maps/tests/Unit/Semantic/DataValues/CoordinateValueTest.php113
-rw-r--r--www/wiki/extensions/Maps/tests/Util/PageCreator.php24
-rw-r--r--www/wiki/extensions/Maps/tests/Util/TestFactory.php21
-rw-r--r--www/wiki/extensions/Maps/tests/bootstrap.php33
-rw-r--r--www/wiki/extensions/MultimediaViewer/.eslintrc.json15
-rw-r--r--www/wiki/extensions/MultimediaViewer/.gitignore5
-rw-r--r--www/wiki/extensions/MultimediaViewer/.gitreview6
-rw-r--r--www/wiki/extensions/MultimediaViewer/.phpcs.xml9
-rw-r--r--www/wiki/extensions/MultimediaViewer/.rubocop.yml24
-rw-r--r--www/wiki/extensions/MultimediaViewer/.rubocop_todo.yml40
-rw-r--r--www/wiki/extensions/MultimediaViewer/.stylelintrc.json6
-rw-r--r--www/wiki/extensions/MultimediaViewer/AUTHORS24
-rw-r--r--www/wiki/extensions/MultimediaViewer/CODE_OF_CONDUCT.md1
-rw-r--r--www/wiki/extensions/MultimediaViewer/COPYING339
-rw-r--r--www/wiki/extensions/MultimediaViewer/Gemfile5
-rw-r--r--www/wiki/extensions/MultimediaViewer/Gemfile.lock113
-rw-r--r--www/wiki/extensions/MultimediaViewer/Gruntfile.js72
-rw-r--r--www/wiki/extensions/MultimediaViewer/MultimediaViewer.php132
-rw-r--r--www/wiki/extensions/MultimediaViewer/Rakefile17
-rw-r--r--www/wiki/extensions/MultimediaViewer/composer.json20
-rw-r--r--www/wiki/extensions/MultimediaViewer/extension.json444
-rw-r--r--www/wiki/extensions/MultimediaViewer/gitinfo.json1
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/af.json103
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ais.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ar.json133
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/as.json18
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ast.json127
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/atj.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/av.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/az.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/bcl.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/be-tarask.json46
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/be.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/bg.json21
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/bgn.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/bn.json130
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/br.json44
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/bs.json80
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ca.json83
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ce.json95
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ckb.json51
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/cs.json139
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/cu.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/cy.json27
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/da.json20
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/de-ch.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/de-formal.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/de.json137
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/diq.json12
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/dsb.json20
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/el.json99
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/eml.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/en-gb.json11
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/en.json156
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/eo.json103
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/es-formal.json57
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/es.json138
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/et.json116
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/eu.json28
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/fa.json126
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/fi.json87
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/fr.json142
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/frr.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/fy.json15
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/gd.json123
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/gl.json131
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/gu.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/he.json138
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/hi.json25
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/hr.json135
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/hsb.json81
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/hu.json114
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/hy.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ia.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/id.json22
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ilo.json71
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/inh.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/io.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/is.json82
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/it.json137
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ja.json107
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/jv.json36
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ka.json58
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/kk-cyrl.json91
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/km.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/kn.json49
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ko.json77
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/krc.json17
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ksh.json63
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ku-latn.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/lb.json91
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/lki.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/lrc.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/lt.json101
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/lv.json69
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/lzh.json14
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/mg.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/mk.json137
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ml.json144
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/mn.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/mr.json16
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ms.json24
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/mwl.json12
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/my.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/nan.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/nap.json11
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/nb.json131
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/nds-nl.json11
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ne.json14
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/nl.json107
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/nn.json92
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/oc.json42
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/om.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/or.json55
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/pa.json10
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/pl.json110
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ps.json44
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/pt-br.json161
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/pt.json132
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/qqq.json166
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/qu.json33
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ro.json118
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/roa-tara.json11
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ru.json122
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sa.json18
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sco.json44
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sd.json12
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sdc.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sgs.json25
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/si.json18
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sk.json71
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sl.json50
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sq.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sr-ec.json111
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sr-el.json93
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/su.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sv.json119
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/sw.json14
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ta.json12
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/tcy.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/te.json60
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/tg-cyrl.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/th.json27
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/tl.json12
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/tr.json80
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/tt-cyrl.json77
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/uk.json133
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/ur.json70
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/vi.json138
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/vo.json9
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/wa.json8
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/yi.json55
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/zh-hans.json159
-rw-r--r--www/wiki/extensions/MultimediaViewer/i18n/zh-hant.json116
-rwxr-xr-xwww/wiki/extensions/MultimediaViewer/importml.sh25
-rw-r--r--www/wiki/extensions/MultimediaViewer/includes/MultimediaViewerHooks.php349
-rw-r--r--www/wiki/extensions/MultimediaViewer/jsduck.categories.json104
-rw-r--r--www/wiki/extensions/MultimediaViewer/jsduck.external.js87
-rw-r--r--www/wiki/extensions/MultimediaViewer/jsduck.json12
-rw-r--r--www/wiki/extensions/MultimediaViewer/package.json18
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/jquery.hashchange/jquery.hashchange.js260
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/img/down.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/img/expand.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/img/gear.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/img/x_gray.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ActionLogger.js192
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Api.js58
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.AttributionLogger.js73
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DimensionLogger.js81
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DurationLogger.js162
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Logger.js160
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.PerformanceLogger.js455
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ViewLogger.js178
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.Config.js272
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.EmbedFileFormatter.js251
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.HtmlUtils.js269
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.ThumbnailWidthCalculator.js172
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.base.js34
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.autostart.js34
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.js631
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.less69
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.globals.less31
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.head.js59
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.js1031
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboximage.js63
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.js509
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.less105
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.mixins.less60
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.EmbedFileInfo.js53
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Image.js343
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.IwTitle.js80
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.License.js144
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Repo.js209
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.TaskQueue.js141
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Thumbnail.js48
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.ThumbnailWidth.js82
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.js20
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Api.js199
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.FileRepoInfo.js63
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.GuessedThumbnailInfo.js307
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Image.js153
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ImageInfo.js117
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ThumbnailInfo.js89
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.MainFileRoute.js30
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Route.js28
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Router.js197
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.ThumbnailRoute.js36
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.js20
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/checker.pngbin0 -> 81 bytes
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/cc.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/commons_white.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_darkgray.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_gray.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_lightgray.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/error-media-icon.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/file.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/gear.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/grayscale.svg6
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_mmv.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_page.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/license.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link-hover.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/location.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-close.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-ltr.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-rtl.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-download.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-ltr.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-rtl.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-ltr.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-rtl.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/open.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/page.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting-hover.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pd.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-ltr.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-rtl.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-2257.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-aus-reserve.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-communist.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-costume.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-currency.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-default.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-design.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-fan-art.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ihl.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-insignia.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ita-mibac.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-nazi.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-personality.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/time.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-ltr.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-rtl.svg5
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-ltr.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-rtl.svg7
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_gray.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_white.svg4
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.js467
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.less89
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.js285
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.less142
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.description.js69
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.js258
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.less45
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.js128
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.less34
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.js20
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.js429
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.less206
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.js268
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.js886
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.less392
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.js247
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.less69
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.js173
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.less81
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.js93
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.less46
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.js264
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.less72
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.js542
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.less77
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.js166
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.less49
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.shareembed.less8
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.tab.js57
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.js136
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.less68
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.js202
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.less56
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.js240
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.less74
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.utils.js210
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.js397
-rw-r--r--www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.less160
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/LocalSettings.php2
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/README.md1
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/ci.yml28
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/environments.yml42
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.download.feature59
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.navigation.feature23
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.options.feature44
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.performance.feature42
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_download_steps.rb101
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_navigation_steps.rb44
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_options_steps.rb69
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_performance_steps.rb48
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_steps.rb174
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/support/env.rb3
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/commons_page.rb51
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/e2e_test_page.rb87
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/browser/samples/MediaViewerE2ETest.wikitext14
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/phan/config.php19
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ActionLogger.test.js48
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.AttributionLogger.test.js22
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DimensionLogger.test.js17
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DurationLogger.test.js218
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.PerformanceLogger.test.js341
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ViewLogger.test.js87
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.Config.test.js203
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.EmbedFileFormatter.test.js293
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.HtmlUtils.test.js192
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.ThumbnailWidthCalculator.test.js149
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.bootstrap.test.js582
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboximage.test.js10
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboxinterface.test.js306
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.test.js706
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.testhelpers.js174
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.EmbedFileInfo.test.js40
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Image.test.js151
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.IwTitle.test.js43
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.License.test.js161
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Repo.test.js100
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.TaskQueue.test.js276
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.test.js58
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Api.test.js270
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.FileRepoInfo.test.js126
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.GuessedThumbnailInfo.test.js280
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Image.test.js200
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ImageInfo.test.js241
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ThumbnailInfo.test.js165
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.MainFileRoute.test.js24
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.Router.test.js232
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.ThumbnailRoute.test.js32
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvas.test.js287
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvasButtons.test.js36
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.description.test.js42
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.download.pane.test.js164
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanel.test.js207
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanelScroller.test.js232
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.permission.test.js112
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.progressBar.test.js77
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.dialog.test.js250
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.embed.test.js398
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.share.test.js95
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.tab.test.js43
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.utils.test.js117
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js76
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.test.js109
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.tipsyDialog.test.js68
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.truncatableTextField.test.js64
-rw-r--r--www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.viewingOptions.test.js139
-rw-r--r--www/wiki/extensions/MultimediaViewer/version4
-rw-r--r--www/wiki/extensions/MultimediaViewer/viewer-ltr.svg24
-rw-r--r--www/wiki/extensions/MultimediaViewer/viewer-rtl.svg24
-rw-r--r--www/wiki/extensions/NoTitle/NoTitle.body.php2
-rw-r--r--www/wiki/extensions/Nuke/Gruntfile.js3
-rw-r--r--www/wiki/extensions/Nuke/Nuke.alias.php5
-rw-r--r--www/wiki/extensions/Nuke/composer.json19
-rw-r--r--www/wiki/extensions/Nuke/ext.nuke.confirm.js14
-rw-r--r--www/wiki/extensions/Nuke/extension.json14
-rw-r--r--www/wiki/extensions/Nuke/i18n/ar.json7
-rw-r--r--www/wiki/extensions/Nuke/i18n/ast.json5
-rw-r--r--www/wiki/extensions/Nuke/i18n/be-tarask.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/bg.json6
-rw-r--r--www/wiki/extensions/Nuke/i18n/bn.json12
-rw-r--r--www/wiki/extensions/Nuke/i18n/ckb.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/cs.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/de.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/en.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/es.json6
-rw-r--r--www/wiki/extensions/Nuke/i18n/eu.json2
-rw-r--r--www/wiki/extensions/Nuke/i18n/fa.json11
-rw-r--r--www/wiki/extensions/Nuke/i18n/fr.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/gl.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/he.json5
-rw-r--r--www/wiki/extensions/Nuke/i18n/hu.json22
-rw-r--r--www/wiki/extensions/Nuke/i18n/hy.json10
-rw-r--r--www/wiki/extensions/Nuke/i18n/io.json6
-rw-r--r--www/wiki/extensions/Nuke/i18n/is.json10
-rw-r--r--www/wiki/extensions/Nuke/i18n/ja.json9
-rw-r--r--www/wiki/extensions/Nuke/i18n/jv.json31
-rw-r--r--www/wiki/extensions/Nuke/i18n/ko.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/ku-latn.json5
-rw-r--r--www/wiki/extensions/Nuke/i18n/lb.json4
-rw-r--r--www/wiki/extensions/Nuke/i18n/lt.json5
-rw-r--r--www/wiki/extensions/Nuke/i18n/lzh.json8
-rw-r--r--www/wiki/extensions/Nuke/i18n/mk.json7
-rw-r--r--www/wiki/extensions/Nuke/i18n/mwl.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/mzn.json8
-rw-r--r--www/wiki/extensions/Nuke/i18n/nb.json7
-rw-r--r--www/wiki/extensions/Nuke/i18n/nl.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/nn.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/pl.json10
-rw-r--r--www/wiki/extensions/Nuke/i18n/ps.json6
-rw-r--r--www/wiki/extensions/Nuke/i18n/pt-br.json6
-rw-r--r--www/wiki/extensions/Nuke/i18n/pt.json7
-rw-r--r--www/wiki/extensions/Nuke/i18n/qqq.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/roa-tara.json7
-rw-r--r--www/wiki/extensions/Nuke/i18n/ru.json6
-rw-r--r--www/wiki/extensions/Nuke/i18n/sd.json11
-rw-r--r--www/wiki/extensions/Nuke/i18n/uk.json5
-rw-r--r--www/wiki/extensions/Nuke/i18n/zh-hans.json3
-rw-r--r--www/wiki/extensions/Nuke/i18n/zh-hant.json7
-rw-r--r--www/wiki/extensions/Nuke/includes/NukeHooks.php26
-rw-r--r--www/wiki/extensions/Nuke/includes/SpecialNuke.php407
-rw-r--r--www/wiki/extensions/Nuke/tests/phan/config.php19
-rw-r--r--www/wiki/extensions/OATHAuth/CODE_OF_CONDUCT.md1
-rw-r--r--www/wiki/extensions/OATHAuth/COPYING339
-rw-r--r--www/wiki/extensions/OATHAuth/Gruntfile.js41
-rw-r--r--www/wiki/extensions/OATHAuth/OATHAuth.alias.php49
-rw-r--r--www/wiki/extensions/OATHAuth/OATHAuth.php29
-rw-r--r--www/wiki/extensions/OATHAuth/composer.json25
-rw-r--r--www/wiki/extensions/OATHAuth/extension.json120
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/af.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ar.json53
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ast.json50
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/az.json10
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ba.json15
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/be-tarask.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/be.json19
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/bg.json26
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/bn.json37
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/br.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/bs.json32
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ce.json33
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/cs.json41
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/de-formal.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/de.json46
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/diq.json10
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/dsb.json20
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/el.json13
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/en.json52
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/es.json45
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/et.json25
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/fa.json51
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/fi.json26
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/fr.json62
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/frp.json16
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/gl.json52
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/he.json52
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/hi.json13
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/hr.json21
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/hsb.json19
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/hu.json44
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/hy.json10
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ia.json26
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/id.json14
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/is.json11
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/it.json44
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ja.json23
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/jv.json40
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ka.json24
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ko.json50
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ksh.json18
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/lb.json22
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/lki.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/lt.json9
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/lv.json14
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/mk.json50
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ml.json21
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/mr.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ms.json19
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/mwl.json12
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/nb.json51
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ne.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/nl.json27
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/oc.json15
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/pl.json30
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/pms.json19
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ps.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/pt-br.json55
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/pt.json52
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/qqq.json59
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ro.json16
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/roa-tara.json16
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ru.json57
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sa.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sah.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sd.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/si.json14
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sk.json38
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sq.json9
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sr-ec.json10
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sr-el.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/sv.json32
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ta.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/te.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/th.json21
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/tl.json20
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/tr.json26
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/uk.json52
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/ur.json14
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/vi.json40
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/yi.json8
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/zh-hans.json53
-rw-r--r--www/wiki/extensions/OATHAuth/i18n/zh-hant.json43
-rw-r--r--www/wiki/extensions/OATHAuth/includes/OATHAuthHooks.php221
-rw-r--r--www/wiki/extensions/OATHAuth/includes/OATHAuthKey.php187
-rw-r--r--www/wiki/extensions/OATHAuth/includes/OATHAuthUtils.php141
-rw-r--r--www/wiki/extensions/OATHAuth/includes/OATHUser.php83
-rw-r--r--www/wiki/extensions/OATHAuth/includes/OATHUserRepository.php103
-rw-r--r--www/wiki/extensions/OATHAuth/includes/api/ApiOATHValidate.php101
-rw-r--r--www/wiki/extensions/OATHAuth/includes/api/ApiQueryOATH.php90
-rw-r--r--www/wiki/extensions/OATHAuth/includes/auth/TOTPAuthenticationRequest.php43
-rw-r--r--www/wiki/extensions/OATHAuth/includes/auth/TOTPSecondaryAuthenticationProvider.php121
-rw-r--r--www/wiki/extensions/OATHAuth/includes/lib/base32.php105
-rw-r--r--www/wiki/extensions/OATHAuth/includes/lib/hotp.php179
-rw-r--r--www/wiki/extensions/OATHAuth/includes/special/ProxySpecialPage.php227
-rw-r--r--www/wiki/extensions/OATHAuth/includes/special/SpecialOATH.php44
-rw-r--r--www/wiki/extensions/OATHAuth/includes/special/SpecialOATHDisable.php136
-rw-r--r--www/wiki/extensions/OATHAuth/includes/special/SpecialOATHEnable.php241
-rw-r--r--www/wiki/extensions/OATHAuth/maintenance/disableOATHAuthForUser.php40
-rw-r--r--www/wiki/extensions/OATHAuth/maintenance/updateScratchTokenFormat.php51
-rw-r--r--www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.js6
-rw-r--r--www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.styles.css13
-rw-r--r--www/wiki/extensions/OATHAuth/modules/jquery.qrcode.js88
-rw-r--r--www/wiki/extensions/OATHAuth/modules/qrcode.js1237
-rw-r--r--www/wiki/extensions/OATHAuth/sql/mssql/tables.sql10
-rw-r--r--www/wiki/extensions/OATHAuth/sql/mysql/patch-remove_reset.sql8
-rw-r--r--www/wiki/extensions/OATHAuth/sql/mysql/tables.sql11
-rw-r--r--www/wiki/extensions/OATHAuth/sql/oracle/tables.sql15
-rw-r--r--www/wiki/extensions/OATHAuth/sql/postgres/tables.sql19
-rw-r--r--www/wiki/extensions/OATHAuth/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/OATHAuth/tests/phpunit/TOTPAuthenticationRequestTest.php17
-rw-r--r--www/wiki/extensions/OpenGraphMeta/OpenGraphMeta.class.php9
-rw-r--r--www/wiki/extensions/PageForms/.jshintrc7
-rw-r--r--www/wiki/extensions/PageForms/Gruntfile.js3
-rw-r--r--www/wiki/extensions/PageForms/INSTALL2
-rw-r--r--www/wiki/extensions/PageForms/PageForms.php45
-rw-r--r--www/wiki/extensions/PageForms/README24
-rw-r--r--www/wiki/extensions/PageForms/composer.json2
-rw-r--r--www/wiki/extensions/PageForms/extension.json48
-rw-r--r--www/wiki/extensions/PageForms/i18n/ar.json7
-rw-r--r--www/wiki/extensions/PageForms/i18n/ast.json5
-rw-r--r--www/wiki/extensions/PageForms/i18n/be.json6
-rw-r--r--www/wiki/extensions/PageForms/i18n/bn.json3
-rw-r--r--www/wiki/extensions/PageForms/i18n/cs.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/de.json7
-rw-r--r--www/wiki/extensions/PageForms/i18n/el.json15
-rw-r--r--www/wiki/extensions/PageForms/i18n/en.json11
-rw-r--r--www/wiki/extensions/PageForms/i18n/es.json3
-rw-r--r--www/wiki/extensions/PageForms/i18n/fr.json9
-rw-r--r--www/wiki/extensions/PageForms/i18n/fy.json5
-rw-r--r--www/wiki/extensions/PageForms/i18n/gl.json8
-rw-r--r--www/wiki/extensions/PageForms/i18n/hr.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/ia.json2
-rw-r--r--www/wiki/extensions/PageForms/i18n/inh.json1
-rw-r--r--www/wiki/extensions/PageForms/i18n/it.json2
-rw-r--r--www/wiki/extensions/PageForms/i18n/kjp.json8
-rw-r--r--www/wiki/extensions/PageForms/i18n/ko.json6
-rw-r--r--www/wiki/extensions/PageForms/i18n/lb.json2
-rw-r--r--www/wiki/extensions/PageForms/i18n/lt.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/lv.json1
-rw-r--r--www/wiki/extensions/PageForms/i18n/mk.json7
-rw-r--r--www/wiki/extensions/PageForms/i18n/my.json35
-rw-r--r--www/wiki/extensions/PageForms/i18n/nb.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/pl.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/pt-br.json7
-rw-r--r--www/wiki/extensions/PageForms/i18n/pt.json11
-rw-r--r--www/wiki/extensions/PageForms/i18n/qqq.json5
-rw-r--r--www/wiki/extensions/PageForms/i18n/roa-tara.json1
-rw-r--r--www/wiki/extensions/PageForms/i18n/ru.json23
-rw-r--r--www/wiki/extensions/PageForms/i18n/sd.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/skr-arab.json (renamed from www/wiki/extensions/PageForms/i18n/skr.json)6
-rw-r--r--www/wiki/extensions/PageForms/i18n/sr-ec.json60
-rw-r--r--www/wiki/extensions/PageForms/i18n/sr-el.json2
-rw-r--r--www/wiki/extensions/PageForms/i18n/sv.json1
-rw-r--r--www/wiki/extensions/PageForms/i18n/tr.json4
-rw-r--r--www/wiki/extensions/PageForms/i18n/tt-cyrl.json6
-rw-r--r--www/wiki/extensions/PageForms/i18n/zh-hans.json5
-rw-r--r--www/wiki/extensions/PageForms/i18n/zh-hant.json62
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_AutocompleteAPI.php17
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_AutoeditAPI.php12
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_Form.php2
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_FormField.php1
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_FormLinker.php83
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_FormPrinter.php24
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_FormUtils.php2
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_Hooks.php123
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_PageSchemas.php9
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_ParserFunctions.php108
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_Template.php95
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_TemplateField.php66
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_TemplateInForm.php62
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_Utils.php14
-rw-r--r--www/wiki/extensions/PageForms/includes/PF_ValuesUtils.php14
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_CheckboxesInput.php7
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_DateInput.php32
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_DatePickerInput.php44
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimeInput.php28
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimePicker.php3
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_FormInput.php2
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_ListBoxInput.php2
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_TextAreaInput.php24
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_TextInput.php8
-rw-r--r--www/wiki/extensions/PageForms/includes/forminputs/PF_TreeInput.php26
-rw-r--r--www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPage.php11
-rw-r--r--www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageFreeText.php43
-rw-r--r--www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageTemplateParam.php7
-rw-r--r--www/wiki/extensions/PageForms/languages/PF_Aliases.php2
-rw-r--r--www/wiki/extensions/PageForms/languages/PF_Namespaces.php2
-rw-r--r--www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.1.3.4.js1152
-rw-r--r--www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.3.2.10.js (renamed from www/wiki/extensions/PageForms/libs/jquery.fancybox.js)0
-rw-r--r--www/wiki/extensions/PageForms/libs/PF_MultiPageEdit.js337
-rw-r--r--www/wiki/extensions/PageForms/libs/PF_jsGrid.js467
-rw-r--r--www/wiki/extensions/PageForms/libs/PF_popupform.js23
-rw-r--r--www/wiki/extensions/PageForms/libs/PageForms.js232
-rw-r--r--www/wiki/extensions/PageForms/libs/ext.pf.select2.base.js24
-rw-r--r--www/wiki/extensions/PageForms/libs/ext.pf.select2.tokens.js10
-rw-r--r--www/wiki/extensions/PageForms/libs/select2.js4
-rw-r--r--www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.target.js118
-rw-r--r--www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.targetwide.js6
-rw-r--r--www/wiki/extensions/PageForms/libs/ve/veforpageform.js60
-rw-r--r--www/wiki/extensions/PageForms/package.json18
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/blank.gif (renamed from www/wiki/extensions/PageForms/skins/blank.gif)bin43 -> 43 bytes
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/fancy_close.png (renamed from www/wiki/extensions/PageForms/skins/fancy_close.png)bin1133 -> 1133 bytes
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/fancy_title_over.png (renamed from www/wiki/extensions/PageForms/skins/fancy_title_over.png)bin70 -> 70 bytes
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/fancybox-x.png (renamed from www/wiki/extensions/PageForms/skins/fancybox-x.png)bin297 -> 297 bytes
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/fancybox-y.png (renamed from www/wiki/extensions/PageForms/skins/fancybox-y.png)bin247 -> 247 bytes
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/fancybox.png (renamed from www/wiki/extensions/PageForms/skins/fancybox.png)bin17318 -> 17318 bytes
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.1.3.4.css359
-rw-r--r--www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.3.2.10.css (renamed from www/wiki/extensions/PageForms/skins/jquery.fancybox.css)0
-rw-r--r--www/wiki/extensions/PageForms/skins/PF_UploadWindow.css81
-rw-r--r--www/wiki/extensions/PageForms/skins/PF_popupform.css2
-rw-r--r--www/wiki/extensions/PageForms/specials/PF_CreateForm.php2
-rw-r--r--www/wiki/extensions/PageForms/specials/PF_FormEdit.php2
-rw-r--r--www/wiki/extensions/PageForms/specials/PF_MultiPageEdit.php284
-rw-r--r--www/wiki/extensions/PageForms/specials/PF_UploadForm.php16
-rw-r--r--www/wiki/extensions/PageForms/specials/PF_UploadWindow.php11
-rw-r--r--www/wiki/extensions/ParserFunctions/Gruntfile.js3
-rw-r--r--www/wiki/extensions/ParserFunctions/ParserFunctions.i18n.magic.php19
-rw-r--r--www/wiki/extensions/ParserFunctions/composer.json17
-rw-r--r--www/wiki/extensions/ParserFunctions/extension.json16
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/ais.json17
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/anp.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/ar.json5
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/bg.json6
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/bho.json3
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/ckb.json3
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/cv.json9
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/dty.json7
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/frp.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/gcr.json13
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/hy.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/hyw.json9
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/inh.json3
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/io.json3
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/jv.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/km.json2
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/krl.json7
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/kum.json14
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/lb.json7
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/lv.json3
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/mui.json9
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/mwl.json9
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/myv.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/nan.json7
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/nys.json13
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/pa.json7
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/ps.json5
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/ro.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/sat.json14
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/sco.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/sd.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/sty.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/sv.json11
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/tay.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/udm.json4
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/war.json6
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/wuu.json7
-rw-r--r--www/wiki/extensions/ParserFunctions/i18n/zgh.json9
-rw-r--r--www/wiki/extensions/ParserFunctions/includes/ExprError.php33
-rw-r--r--www/wiki/extensions/ParserFunctions/includes/ExprParser.php673
-rw-r--r--www/wiki/extensions/ParserFunctions/includes/ExtParserFunctions.php891
-rw-r--r--www/wiki/extensions/ParserFunctions/includes/ParserFunctionsHooks.php59
-rw-r--r--www/wiki/extensions/ParserFunctions/includes/Scribunto_LuaParserFunctionsLibrary.php23
-rw-r--r--www/wiki/extensions/ParserFunctions/includes/mw.ext.ParserFunctions.lua22
-rw-r--r--www/wiki/extensions/ParserFunctions/tests/parser/funcsParserTests.txt343
-rw-r--r--www/wiki/extensions/ParserFunctions/tests/parser/stringFunctionTests.txt50
-rw-r--r--www/wiki/extensions/ParserFunctions/tests/phan/config.php19
-rw-r--r--www/wiki/extensions/ParserFunctions/tests/phpunit/ExpressionTest.php4
-rw-r--r--www/wiki/extensions/PdfHandler/Gruntfile.js3
-rw-r--r--www/wiki/extensions/PdfHandler/composer.json17
-rw-r--r--www/wiki/extensions/PdfHandler/extension.json8
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/ais.json6
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/bg.json5
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/ca.json5
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/de.json10
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/is.json9
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/ko.json5
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/la.json8
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/mwl.json19
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/nb.json3
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/pt.json2
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/tay.json5
-rw-r--r--www/wiki/extensions/PdfHandler/i18n/zh-hant.json5
-rw-r--r--www/wiki/extensions/PdfHandler/includes/CreatePdfThumbnailsJob.php130
-rw-r--r--www/wiki/extensions/PdfHandler/includes/PdfHandler.php453
-rw-r--r--www/wiki/extensions/PdfHandler/includes/PdfImage.php329
-rw-r--r--www/wiki/extensions/PdfHandler/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/Poem/Gruntfile.js3
-rw-r--r--www/wiki/extensions/Poem/composer.json20
-rw-r--r--www/wiki/extensions/Poem/extension.json5
-rw-r--r--www/wiki/extensions/Poem/i18n/km.json5
-rw-r--r--www/wiki/extensions/Poem/i18n/lb.json3
-rw-r--r--www/wiki/extensions/Poem/i18n/sr-ec.json5
-rw-r--r--www/wiki/extensions/Poem/includes/Poem.php87
-rw-r--r--www/wiki/extensions/Poem/tests/parser/parserTests.txt162
-rw-r--r--www/wiki/extensions/Poem/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/Renameuser/Gruntfile.js3
-rw-r--r--www/wiki/extensions/Renameuser/Renameuser.alias.php5
-rw-r--r--www/wiki/extensions/Renameuser/Renameuser.php2
-rw-r--r--www/wiki/extensions/Renameuser/composer.json21
-rw-r--r--www/wiki/extensions/Renameuser/extension.json14
-rw-r--r--www/wiki/extensions/Renameuser/i18n/bg.json5
-rw-r--r--www/wiki/extensions/Renameuser/i18n/bn.json4
-rw-r--r--www/wiki/extensions/Renameuser/i18n/ckb.json3
-rw-r--r--www/wiki/extensions/Renameuser/i18n/el.json7
-rw-r--r--www/wiki/extensions/Renameuser/i18n/es.json22
-rw-r--r--www/wiki/extensions/Renameuser/i18n/fa.json18
-rw-r--r--www/wiki/extensions/Renameuser/i18n/fy.json3
-rw-r--r--www/wiki/extensions/Renameuser/i18n/he.json2
-rw-r--r--www/wiki/extensions/Renameuser/i18n/hr.json2
-rw-r--r--www/wiki/extensions/Renameuser/i18n/io.json4
-rw-r--r--www/wiki/extensions/Renameuser/i18n/lt.json19
-rw-r--r--www/wiki/extensions/Renameuser/i18n/mk.json12
-rw-r--r--www/wiki/extensions/Renameuser/i18n/ml.json12
-rw-r--r--www/wiki/extensions/Renameuser/i18n/mwl.json3
-rw-r--r--www/wiki/extensions/Renameuser/i18n/my.json4
-rw-r--r--www/wiki/extensions/Renameuser/i18n/pt-br.json2
-rw-r--r--www/wiki/extensions/Renameuser/i18n/skr-arab.json8
-rw-r--r--www/wiki/extensions/Renameuser/i18n/th.json5
-rw-r--r--www/wiki/extensions/Renameuser/i18n/zh-hant.json5
-rw-r--r--www/wiki/extensions/Renameuser/includes/RenameUserJob.php229
-rw-r--r--www/wiki/extensions/Renameuser/includes/RenameuserHooks.php66
-rw-r--r--www/wiki/extensions/Renameuser/includes/RenameuserLogFormatter.php99
-rw-r--r--www/wiki/extensions/Renameuser/includes/RenameuserSQL.php411
-rw-r--r--www/wiki/extensions/Renameuser/includes/SpecialRenameuser.php432
-rw-r--r--www/wiki/extensions/Renameuser/maintenance/cleanupArchiveUserText.php7
-rw-r--r--www/wiki/extensions/Renameuser/maintenance/renameUserCleanup.php35
-rw-r--r--www/wiki/extensions/Renameuser/tests/phan/config.php3
-rw-r--r--www/wiki/extensions/ReplaceText/COPYING339
-rw-r--r--www/wiki/extensions/ReplaceText/Gruntfile.js35
-rw-r--r--www/wiki/extensions/ReplaceText/README52
-rw-r--r--www/wiki/extensions/ReplaceText/ReplaceText.i18n.alias.php289
-rw-r--r--www/wiki/extensions/ReplaceText/ReplaceText.php73
-rw-r--r--www/wiki/extensions/ReplaceText/composer.json20
-rw-r--r--www/wiki/extensions/ReplaceText/extension.json73
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/af.json36
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ais.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ar.json46
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/arc.json10
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/arz.json29
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ast.json43
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/az.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/azb.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ba.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/bcc.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/be-tarask.json47
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/bg.json19
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/bn.json17
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/br.json42
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/bs.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ca.json45
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ce.json15
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/crh-cyrl.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/crh-latn.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/cs.json49
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/cy.json18
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/de-formal.json14
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/de.json50
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/diq.json10
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/dsb.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/el.json46
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/en.json43
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/eo.json23
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/es.json54
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/et.json12
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/eu.json20
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/fa.json47
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/fi.json44
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/fr.json53
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/frp.json26
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/gl.json42
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/grc.json16
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/gsw.json40
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/he.json44
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/hr.json29
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/hsb.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/hu.json42
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ia.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/id.json43
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ig.json9
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/it.json46
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ja.json45
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/jv.json11
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ka.json26
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/km.json21
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ko.json49
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ksh.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/lb.json42
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/lki.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/lt.json12
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/mg.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/mk.json43
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ml.json35
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/mr.json21
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ms.json42
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/nb.json45
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/nl.json46
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/nn.json40
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/oc.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/pdc.json9
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/pl.json50
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/pms.json42
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/pnt.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ps.json21
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/pt-br.json54
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/pt.json52
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/qqq.json52
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ro.json19
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/roa-tara.json19
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ru.json53
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/si.json18
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/sk.json41
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/sr-ec.json36
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/sr-el.json34
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/sv.json50
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/sw.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ta.json12
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/te.json12
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/th.json9
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/tl.json40
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/tr.json39
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/tt-cyrl.json8
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/uk.json46
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/ur.json20
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/vep.json10
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/vi.json44
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/vo.json22
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/zh-hans.json49
-rw-r--r--www/wiki/extensions/ReplaceText/i18n/zh-hant.json51
-rwxr-xr-xwww/wiki/extensions/ReplaceText/maintenance/replaceAll.php408
-rwxr-xr-xwww/wiki/extensions/ReplaceText/replaceAll.php32
-rw-r--r--www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.css3
-rw-r--r--www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.js27
-rw-r--r--www/wiki/extensions/ReplaceText/src/ReplaceTextHooks.php73
-rw-r--r--www/wiki/extensions/ReplaceText/src/ReplaceTextJob.php136
-rw-r--r--www/wiki/extensions/ReplaceText/src/ReplaceTextSearch.php111
-rw-r--r--www/wiki/extensions/ReplaceText/src/ReplaceTextUtils.php41
-rw-r--r--www/wiki/extensions/ReplaceText/src/SpecialReplaceText.php792
-rw-r--r--www/wiki/extensions/ReplaceText/tests/phan/config.php19
-rw-r--r--www/wiki/extensions/SemanticFormsSelect/res/select2.css16
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/DefaultSettings.php65
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/SemanticMediaWiki.php9
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/INSTALL.md2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/README.md2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/RELEASE-NOTES.md385
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/README.md3
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.0.md375
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.1.md39
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.2.md24
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/docs/technical/code-snippets/approve.update.md3
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/extension.json2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ar.json43
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ast.json1
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/be-tarask.json107
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ca.json100
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/cs.json3
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/de.json37
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/el.json1
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/en.json15
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/es.json2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/eu.json1
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/fa.json13
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/fi.json83
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/fr.json49
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/gl.json74
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/he.json43
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ia.json1
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/it.json10
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ja.json2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ko.json28
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/lb.json4
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/mk.json6
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/nb.json8
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/nl.json28
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/pl.json44
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/pt-br.json53
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/pt.json81
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/qqq.json29
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/ru.json209
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/sr-ec.json115
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/sr-el.json213
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/sv.json22
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/uk.json125
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/zh-hans.json12
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/i18n/zh-hant.json465
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/IdeAliases.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/RecurringEvents.php35
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/Settings.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/Setup.php29
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Record.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_URI.php5
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_WikiPage.php45
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DataValue.php13
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/maintenance/README.md84
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/maintenance/populateHashField.php222
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/DataValues/ReferenceValue.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/Indexer.php19
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotReadableException.php24
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotWritableException.php24
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Factbox/Factbox.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Connection/Query.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/TransactionalCallableUpdate.php9
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/BeforePageDisplay.php23
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/HookListener.php9
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/ResourceLoaderTestModules.php4
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Admin/TaskHandler.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/HtmlForm.php4
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/ParametersProcessor.php65
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Browse/ValueFormatter.php6
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/SpecialAsk.php22
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/ParserFunctionFactory.php21
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/ParserFunctions/RecurringEventsParserFunction.php59
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Query/Parser/DescriptionProcessor.php15
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Query/Processor/ParamListProcessor.php16
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Query/RemoteRequest.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/SQLStore/EntityStore/SemanticDataLookup.php50
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/SQLStore/Installer.php138
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/SQLStore/SQLStoreFactory.php4
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/Examiner/HashField.php87
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/MySQLTableBuilder.php6
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableIntegrityExaminer.php88
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Serializers/QueryResultSerializer.php23
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Site.php12
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/TypesRegistry.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Utils/Csv.php7
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/src/Utils/File.php19
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/bootstrap.php6
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/JsonTestCaseScriptRunnerTest.php1
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0112.json58
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0113.json126
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0114.json85
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0115.json130
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0208.json2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0443.json128
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0461.json92
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0503.json25
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0504.json49
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0712.json64
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0612.json21
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0623.json85
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0018.json44
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0031.json95
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0032.json65
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0033.json59
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/Maintenance/PopulateHashFieldTest.php45
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/EventHandlerTest.php5
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotReadableExceptionTest.php33
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotWritableExceptionTest.php33
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Deferred/TransactionalCallableUpdateTest.php41
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/BeforePageDisplayTest.php24
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/ResourceLoaderTestModulesTest.php10
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Specials/Ask/ParametersProcessorTest.php57
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/ParserFunctions/RecurringEventsParserFunctionTest.php22
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Parser/DescriptionProcessorTest.php6
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Processor/ParamListProcessorTest.php41
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/EntityStore/SemanticDataLookupTest.php52
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/InstallerTest.php68
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/Examiner/HashFieldTest.php106
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/MySQLTableBuilderTest.php195
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/PostgresTableBuilderTest.php301
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/SQLiteTableBuilderTest.php257
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableIntegrityExaminerTest.php35
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/CsvTest.php24
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/FileTest.php19
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Utils/Validators/SemanticDataValidator.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/DataValues/WikiPageValueTest.php68
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/InfolinkTest.php2
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/RecurringEventsTest.php80
-rw-r--r--www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/SetupTest.php3
-rw-r--r--www/wiki/extensions/SpamBlacklist/Gruntfile.js3
-rw-r--r--www/wiki/extensions/SpamBlacklist/composer.json17
-rw-r--r--www/wiki/extensions/SpamBlacklist/extension.json30
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/ais.json11
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/ast.json2
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/bg.json10
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/br.json5
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/de.json4
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/el.json5
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/gl.json2
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/id.json7
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/ja.json4
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/ko.json10
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/pl.json4
-rw-r--r--www/wiki/extensions/SpamBlacklist/i18n/ur.json5
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/ApiSpamBlacklist.php72
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/BaseBlacklist.php448
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/EmailBlacklist.php67
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/SpamBlacklist.php348
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistHooks.php283
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistLogFormatter.php11
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistPreAuthenticationProvider.php14
-rw-r--r--www/wiki/extensions/SpamBlacklist/includes/SpamRegexBatch.php175
-rw-r--r--www/wiki/extensions/SpamBlacklist/maintenance/cleanup.php205
-rw-r--r--www/wiki/extensions/SpamBlacklist/tests/phan/config.php19
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/Gruntfile.js2
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/README5
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/composer.json24
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/extension.json22
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/ar.json12
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/az.json3
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/de.json6
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hr.json1
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hy.json14
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/mwl.json9
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-ec.json6
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-el.json6
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/includes/GeSHi.php42
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/includes/ResourceLoaderSyntaxHighlightVisualEditorModule.php70
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlight.php577
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightAce.php174
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightGeSHiCompat.php113
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateCSS.php28
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateLexerList.php25
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/modules/pygments.wrapper.css1
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.css3
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialogTool.js2
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.css3
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspectorTool.js2
-rwxr-xr-xwww/wiki/extensions/SyntaxHighlight_GeSHi/pygments/create_pygmentize_bundle22
-rwxr-xr-xwww/wiki/extensions/SyntaxHighlight_GeSHi/pygments/pygmentizebin842005 -> 842007 bytes
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/tests/parser/parserTests.txt168
-rw-r--r--www/wiki/extensions/SyntaxHighlight_GeSHi/tests/phan/config.php6
-rw-r--r--www/wiki/extensions/TitleBlacklist/Gruntfile.js3
-rw-r--r--www/wiki/extensions/TitleBlacklist/composer.json17
-rw-r--r--www/wiki/extensions/TitleBlacklist/extension.json26
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/ais.json27
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/bg.json16
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/de.json4
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/fa.json5
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/ja.json7
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/roa-tara.json5
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/ru.json9
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/th.json3
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/uk.json2
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/ur.json5
-rw-r--r--www/wiki/extensions/TitleBlacklist/i18n/zh-hant.json5
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/Scribunto_LuaTitleBlacklistLibrary.php35
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/TitleBlacklist.php343
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistAuthenticationRequest.php22
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistEntry.php293
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistHooks.php269
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistPreAuthenticationProvider.php58
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/api/ApiQueryTitleBlacklist.php107
-rw-r--r--www/wiki/extensions/TitleBlacklist/includes/mw.ext.TitleBlacklist.lua22
-rw-r--r--www/wiki/extensions/TitleBlacklist/tests/phan/config.php19
-rw-r--r--www/wiki/extensions/TitleBlacklist/tests/phpunit/ApiQueryTitleBlacklistTest.php3
-rw-r--r--www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistAuthenticationRequestTest.php3
-rw-r--r--www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistPreAuthenticationProviderTest.php1
-rw-r--r--www/wiki/extensions/Validator/.gitignore10
-rw-r--r--www/wiki/extensions/Validator/.scrutinizer.yml12
-rw-r--r--www/wiki/extensions/Validator/.travis.yml20
-rw-r--r--www/wiki/extensions/Validator/COPYING103
-rw-r--r--www/wiki/extensions/Validator/README.md348
-rw-r--r--www/wiki/extensions/Validator/Validator.php82
-rw-r--r--www/wiki/extensions/Validator/build/travis/after_success.sh14
-rw-r--r--www/wiki/extensions/Validator/build/travis/before_script.sh39
-rw-r--r--www/wiki/extensions/Validator/build/travis/script.sh14
-rw-r--r--www/wiki/extensions/Validator/composer.json48
-rw-r--r--www/wiki/extensions/Validator/i18n/af.json51
-rw-r--r--www/wiki/extensions/Validator/i18n/aln.json24
-rw-r--r--www/wiki/extensions/Validator/i18n/ar.json48
-rw-r--r--www/wiki/extensions/Validator/i18n/be-tarask.json96
-rw-r--r--www/wiki/extensions/Validator/i18n/bg.json17
-rw-r--r--www/wiki/extensions/Validator/i18n/bn.json9
-rw-r--r--www/wiki/extensions/Validator/i18n/br.json73
-rw-r--r--www/wiki/extensions/Validator/i18n/bs.json33
-rw-r--r--www/wiki/extensions/Validator/i18n/ca.json9
-rw-r--r--www/wiki/extensions/Validator/i18n/ce.json37
-rw-r--r--www/wiki/extensions/Validator/i18n/cs.json70
-rw-r--r--www/wiki/extensions/Validator/i18n/cu.json9
-rw-r--r--www/wiki/extensions/Validator/i18n/da.json8
-rw-r--r--www/wiki/extensions/Validator/i18n/de.json99
-rw-r--r--www/wiki/extensions/Validator/i18n/diq.json19
-rw-r--r--www/wiki/extensions/Validator/i18n/dsb.json51
-rw-r--r--www/wiki/extensions/Validator/i18n/el.json22
-rw-r--r--www/wiki/extensions/Validator/i18n/en.json96
-rw-r--r--www/wiki/extensions/Validator/i18n/eo.json17
-rw-r--r--www/wiki/extensions/Validator/i18n/es.json100
-rw-r--r--www/wiki/extensions/Validator/i18n/et.json30
-rw-r--r--www/wiki/extensions/Validator/i18n/eu.json22
-rw-r--r--www/wiki/extensions/Validator/i18n/fa.json94
-rw-r--r--www/wiki/extensions/Validator/i18n/fi.json31
-rw-r--r--www/wiki/extensions/Validator/i18n/fr.json105
-rw-r--r--www/wiki/extensions/Validator/i18n/frp.json60
-rw-r--r--www/wiki/extensions/Validator/i18n/frr.json8
-rw-r--r--www/wiki/extensions/Validator/i18n/fy.json11
-rw-r--r--www/wiki/extensions/Validator/i18n/ga.json11
-rw-r--r--www/wiki/extensions/Validator/i18n/gl.json94
-rw-r--r--www/wiki/extensions/Validator/i18n/gsw.json81
-rw-r--r--www/wiki/extensions/Validator/i18n/he.json98
-rw-r--r--www/wiki/extensions/Validator/i18n/hsb.json92
-rw-r--r--www/wiki/extensions/Validator/i18n/hu.json64
-rw-r--r--www/wiki/extensions/Validator/i18n/ia.json92
-rw-r--r--www/wiki/extensions/Validator/i18n/id.json82
-rw-r--r--www/wiki/extensions/Validator/i18n/it.json95
-rw-r--r--www/wiki/extensions/Validator/i18n/ja.json82
-rw-r--r--www/wiki/extensions/Validator/i18n/ka.json40
-rw-r--r--www/wiki/extensions/Validator/i18n/ko.json96
-rw-r--r--www/wiki/extensions/Validator/i18n/ksh.json65
-rw-r--r--www/wiki/extensions/Validator/i18n/ku-latn.json17
-rw-r--r--www/wiki/extensions/Validator/i18n/lb.json79
-rw-r--r--www/wiki/extensions/Validator/i18n/lki.json9
-rw-r--r--www/wiki/extensions/Validator/i18n/lt.json59
-rw-r--r--www/wiki/extensions/Validator/i18n/lv.json10
-rw-r--r--www/wiki/extensions/Validator/i18n/mk.json95
-rw-r--r--www/wiki/extensions/Validator/i18n/ms.json11
-rw-r--r--www/wiki/extensions/Validator/i18n/nb.json81
-rw-r--r--www/wiki/extensions/Validator/i18n/nl.json94
-rw-r--r--www/wiki/extensions/Validator/i18n/oc.json45
-rw-r--r--www/wiki/extensions/Validator/i18n/os.json8
-rw-r--r--www/wiki/extensions/Validator/i18n/pfl.json10
-rw-r--r--www/wiki/extensions/Validator/i18n/pl.json96
-rw-r--r--www/wiki/extensions/Validator/i18n/pms.json94
-rw-r--r--www/wiki/extensions/Validator/i18n/ps.json21
-rw-r--r--www/wiki/extensions/Validator/i18n/pt-br.json96
-rw-r--r--www/wiki/extensions/Validator/i18n/pt.json94
-rw-r--r--www/wiki/extensions/Validator/i18n/qqq.json101
-rw-r--r--www/wiki/extensions/Validator/i18n/qu.json8
-rw-r--r--www/wiki/extensions/Validator/i18n/ro.json49
-rw-r--r--www/wiki/extensions/Validator/i18n/roa-tara.json24
-rw-r--r--www/wiki/extensions/Validator/i18n/ru.json102
-rw-r--r--www/wiki/extensions/Validator/i18n/rue.json9
-rw-r--r--www/wiki/extensions/Validator/i18n/sah.json14
-rw-r--r--www/wiki/extensions/Validator/i18n/si.json71
-rw-r--r--www/wiki/extensions/Validator/i18n/sr-ec.json10
-rw-r--r--www/wiki/extensions/Validator/i18n/sr-el.json9
-rw-r--r--www/wiki/extensions/Validator/i18n/sv.json100
-rw-r--r--www/wiki/extensions/Validator/i18n/ta.json38
-rw-r--r--www/wiki/extensions/Validator/i18n/te.json33
-rw-r--r--www/wiki/extensions/Validator/i18n/tl.json93
-rw-r--r--www/wiki/extensions/Validator/i18n/tr.json20
-rw-r--r--www/wiki/extensions/Validator/i18n/uk.json99
-rw-r--r--www/wiki/extensions/Validator/i18n/ur.json20
-rw-r--r--www/wiki/extensions/Validator/i18n/vi.json52
-rw-r--r--www/wiki/extensions/Validator/i18n/yi.json12
-rw-r--r--www/wiki/extensions/Validator/i18n/zh-hans.json101
-rw-r--r--www/wiki/extensions/Validator/i18n/zh-hant.json90
-rw-r--r--www/wiki/extensions/Validator/phpunit.xml.dist24
-rw-r--r--www/wiki/extensions/Validator/src/ParamProcessor/MediaWikiTitleValue.php105
-rw-r--r--www/wiki/extensions/Validator/src/ParamProcessor/TitleParser.php36
-rw-r--r--www/wiki/extensions/Validator/src/legacy/ParserHook.php613
-rw-r--r--www/wiki/extensions/Validator/src/legacy/README.md4
-rw-r--r--www/wiki/extensions/Validator/tests/bootstrap.php24
-rw-r--r--www/wiki/extensions/Validator/tests/evilMediaWikiBootstrap.php72
-rw-r--r--www/wiki/extensions/Validator/tests/phpunit/Definitions/TitleParamTest.php77
-rw-r--r--www/wiki/extensions/Validator/tests/phpunit/MediaWikiTitleValueTest.php22
-rw-r--r--www/wiki/extensions/Validator/tests/phpunit/TitleParserTest.php43
-rw-r--r--www/wiki/extensions/WikiEditor/README24
-rw-r--r--www/wiki/extensions/WikiEditor/composer.json21
-rw-r--r--www/wiki/extensions/WikiEditor/extension.json284
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/af.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ais.json84
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/aln.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/an.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ar.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/arc.json5
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/arz.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/as.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ast.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/az.json9
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/azb.json10
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ba.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/be-tarask.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/be.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/bg.json26
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/bjn.json7
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/bn.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/bo.json2
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/bpy.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/br.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/bs.json28
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ca.json15
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ce.json15
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ckb.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/cs.json18
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/csb.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/cu.json5
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/cy.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/da.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/de-ch.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/de-formal.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/de.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/diq.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/dsb.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/el.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/eml.json2
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/en.json15
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/eo.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/es.json20
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/et.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/eu.json42
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/fa.json19
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/fi.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/fr.json18
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/frp.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/fur.json3
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/fy.json4
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ga.json25
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/gd.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/gl.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/grc.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/gsw.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/gu.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/gv.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/he.json20
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/hi.json12
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/hr.json17
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/hsb.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/hu.json18
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/hy.json18
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ia.json22
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/id.json22
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ig.json7
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ilo.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/inh.json62
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/io.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/is.json19
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/it.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ja.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/jv.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ka.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/kiu.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/kk-cyrl.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/km.json68
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/kn.json12
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ko.json22
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/krc.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ksh.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ku-latn.json11
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/kw.json9
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ky.json4
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/la.json8
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lad.json5
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lb.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/li.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lij.json3
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lki.json22
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lrc.json11
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lt.json63
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lus.json3
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/lv.json11
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/mai.json12
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/min.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/mk.json22
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ml.json27
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/mr.json19
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ms.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/mt.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/mwl.json40
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nah.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nan.json8
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nap.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nb.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nds-nl.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nds.json7
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ne.json7
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nl-informal.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nl.json21
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nn.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/nso.json4
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/oc.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/olo.json6
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/or.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/os.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pa.json12
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pdc.json6
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pfl.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pl.json19
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pms.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pnb.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ps.json18
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pt-br.json15
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/pt.json66
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/qqq.json25
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/qu.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ro.json19
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/roa-tara.json16
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ru.json19
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/rue.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sa.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sah.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sat.json11
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sc.json8
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/scn.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sd.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sh.json2
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/si.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sk.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sl.json21
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/so.json3
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sq.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sr-ec.json101
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sr-el.json29
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/su.json11
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sv.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/sw.json17
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ta.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tay.json63
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/te.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/th.json20
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tk.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tl.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tr.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tt-cyrl.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tyv.json7
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/tzm.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/udm.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ug-arab.json8
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/uk.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/ur.json25
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/uz.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/vec.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/vep.json6
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/vi.json13
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/vo.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/wo.json1
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/yi.json15
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/yo.json15
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/yue.json14
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/zh-hans.json18
-rw-r--r--www/wiki/extensions/WikiEditor/i18n/zh-hant.json20
-rw-r--r--www/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php332
-rw-r--r--www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.dialogs.js4
-rw-r--r--www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.js21
-rw-r--r--www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.js4
-rw-r--r--www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.styles.less11
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.js93
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.less19
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.js6
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.less10
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.js151
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.less23
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.config.js209
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.js91
-rw-r--r--www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.less98
-rw-r--r--www/wiki/extensions/WikiEditor/tests/phan/config.php22
-rw-r--r--www/wiki/extensions/WikiEditor/tests/qunit/ext.wikiEditor.toolbar.test.js4
3042 files changed, 403957 insertions, 6807 deletions
diff --git a/www/wiki/extensions/CategoryByList/CategoryByList.i18n.php b/www/wiki/extensions/CategoryByList/CategoryByList.i18n.php
new file mode 100644
index 00000000..29125d50
--- /dev/null
+++ b/www/wiki/extensions/CategoryByList/CategoryByList.i18n.php
@@ -0,0 +1,14 @@
+<?php
+/**
+ * @license GPL-2.0-or-later
+ * @author Your Name (YourUserName)
+ */
+
+$magicWords = [];
+
+/** English
+ * @author Your Name (YourUserName)
+ */
+$magicWords['en'] = [
+ 'CategoryByList' => [ 0, 'CategoryByList' ],
+];
diff --git a/www/wiki/extensions/CategoryByList/CategoryByListHooks.php b/www/wiki/extensions/CategoryByList/CategoryByListHooks.php
new file mode 100644
index 00000000..d99795af
--- /dev/null
+++ b/www/wiki/extensions/CategoryByList/CategoryByListHooks.php
@@ -0,0 +1,24 @@
+<?php
+class CategoryByListHooks {
+ // Register any render callbacks with the parser
+ public static function onParserFirstCallInit( Parser $parser ) {
+
+ // Create a function hook associating the "example" magic word with CategoryByList()
+ $parser->setFunctionHook( 'CategoryByList', [ self::class, 'CategoryByList' ] );
+ }
+
+ // Render the output of {{#example:}}.
+ public static function CategoryByList( Parser $parser, $param1 = '', $param2 = '', $param3 = '' ) {
+
+ // The input parameters are wikitext with templates expanded.
+ // The output should be wikitext too.
+ $output = "";
+
+ $categories = explode(', ', $param1);
+ foreach ($categories as $item) {
+ $output .= '[[Categoría:'.$item.']]';
+ }
+
+ return $output;
+ }
+}
diff --git a/www/wiki/extensions/CategoryByList/extension.json b/www/wiki/extensions/CategoryByList/extension.json
new file mode 100644
index 00000000..4308f83a
--- /dev/null
+++ b/www/wiki/extensions/CategoryByList/extension.json
@@ -0,0 +1,24 @@
+{
+ "name": "CategoryByList",
+ "author": "Yaco",
+ "version": "1.0.0",
+ "url": "",
+ "descriptionmsg": "Used to convert a list of separated categories into categories",
+ "license-name": "GPL-2.0-or-later",
+ "type": "parserhook",
+ "MessagesDirs": {
+ "CategoryByList": [
+ "i18n"
+ ]
+ },
+ "AutoloadClasses": {
+ "CategoryByListHooks": "CategoryByListHooks.php"
+ },
+ "ExtensionMessagesFiles": {
+ "CategoryByListMagic": "CategoryByList.i18n.php"
+ },
+ "Hooks": {
+ "ParserFirstCallInit": "CategoryByListHooks::onParserFirstCallInit"
+ },
+ "manifest_version": 1
+}
diff --git a/www/wiki/extensions/CategoryTree/CODE_OF_CONDUCT.md b/www/wiki/extensions/CategoryTree/CODE_OF_CONDUCT.md
new file mode 100644
index 00000000..d8e5d087
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/CODE_OF_CONDUCT.md
@@ -0,0 +1 @@
+The development of this software is covered by a [Code of Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
diff --git a/www/wiki/extensions/CategoryTree/COPYING b/www/wiki/extensions/CategoryTree/COPYING
new file mode 100644
index 00000000..d159169d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/COPYING
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/www/wiki/extensions/CategoryTree/CategoryTree.alias.php b/www/wiki/extensions/CategoryTree/CategoryTree.alias.php
new file mode 100644
index 00000000..1e0215da
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/CategoryTree.alias.php
@@ -0,0 +1,507 @@
+<?php
+/**
+ * Aliases for Special:CategoryTree
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ * @copyright © 2006-2008 Daniel Kinzler and others
+ * @license GPL-2.0-or-later
+ */
+
+$specialPageAliases = [];
+
+/** English (English) */
+$specialPageAliases['en'] = [
+ 'CategoryTree' => [ 'CategoryTree' ],
+];
+
+/** Afrikaans (Afrikaans) */
+$specialPageAliases['af'] = [
+ 'CategoryTree' => [ 'KategorieBoom' ],
+];
+
+/** Aragonese (aragonés) */
+$specialPageAliases['an'] = [
+ 'CategoryTree' => [ 'Árbol_de_categorías' ],
+];
+
+/** Arabic (العربية) */
+$specialPageAliases['ar'] = [
+ 'CategoryTree' => [ 'شجرة_تصنيف' ],
+];
+
+/** Aramaic (ܐܪܡܝܐ) */
+$specialPageAliases['arc'] = [
+ 'CategoryTree' => [ 'ܐܝܠܢܐ_ܕܣܕܪܐ' ],
+];
+
+/** Egyptian Arabic (مصرى) */
+$specialPageAliases['arz'] = [
+ 'CategoryTree' => [ 'شجرة_تصنيف' ],
+];
+
+/** Assamese (অসমীয়া) */
+$specialPageAliases['as'] = [
+ 'CategoryTree' => [ 'শ্ৰেণীবৃক্ষ' ],
+];
+
+/** Avaric (авар) */
+$specialPageAliases['av'] = [
+ 'CategoryTree' => [ 'Категориязул_гъветІ' ],
+];
+
+/** Bashkir (башҡортса) */
+$specialPageAliases['ba'] = [
+ 'CategoryTree' => [ 'Категория_ағасы' ],
+];
+
+/** Bikol Central (Bikol Central) */
+$specialPageAliases['bcl'] = [
+ 'CategoryTree' => [ 'KahoyNinKategorya' ],
+];
+
+/** Belarusian (Taraškievica orthography) (беларуская (тарашкевіца)‎) */
+$specialPageAliases['be-tarask'] = [
+ 'CategoryTree' => [ 'Дрэва_катэгорыяў' ],
+];
+
+/** Bulgarian (български) */
+$specialPageAliases['bg'] = [
+ 'CategoryTree' => [ 'Дърво_на_категориите' ],
+];
+
+/** Western Balochi (بلوچی رخشانی) */
+$specialPageAliases['bgn'] = [
+ 'CategoryTree' => [ 'تهری_درچّگ_یا_درخت' ],
+];
+
+/** Banjar (Bahasa Banjar) */
+$specialPageAliases['bjn'] = [
+ 'CategoryTree' => [ 'Puhun_tumbung' ],
+];
+
+/** Bengali (বাংলা) */
+$specialPageAliases['bn'] = [
+ 'CategoryTree' => [ 'বিষয়শ্রেণী_বৃক্ষ' ],
+];
+
+/** Breton (brezhoneg) */
+$specialPageAliases['br'] = [
+ 'CategoryTree' => [ 'GwezennadurRummad' ],
+];
+
+/** Bosnian (bosanski) */
+$specialPageAliases['bs'] = [
+ 'CategoryTree' => [ 'StabloKategorija' ],
+];
+
+/** Catalan (català) */
+$specialPageAliases['ca'] = [
+ 'CategoryTree' => [ 'Categories_en_arbre', 'Arbre_de_categories' ],
+];
+
+/** Min Dong Chinese (Mìng-dĕ̤ng-ngṳ̄) */
+$specialPageAliases['cdo'] = [
+ 'CategoryTree' => [ '分類樹' ],
+];
+
+/** Chechen (нохчийн) */
+$specialPageAliases['ce'] = [
+ 'CategoryTree' => [ 'Категорийн_дит' ],
+];
+
+/** Czech (čeština) */
+$specialPageAliases['cs'] = [
+ 'CategoryTree' => [ 'Strom_kategorií' ],
+];
+
+/** Danish (dansk) */
+$specialPageAliases['da'] = [
+ 'CategoryTree' => [ 'Kategoritræ' ],
+];
+
+/** German (Deutsch) */
+$specialPageAliases['de'] = [
+ 'CategoryTree' => [ 'Kategorienbaum', 'Kategoriebaum' ],
+];
+
+/** Zazaki (Zazaki) */
+$specialPageAliases['diq'] = [
+ 'CategoryTree' => [ 'DaraKategoriye' ],
+];
+
+/** Lower Sorbian (dolnoserbski) */
+$specialPageAliases['dsb'] = [
+ 'CategoryTree' => [ 'Bom_kategorijow' ],
+];
+
+/** Greek (Ελληνικά) */
+$specialPageAliases['el'] = [
+ 'CategoryTree' => [ 'ΔέντροΚατηγορίας' ],
+];
+
+/** Esperanto (Esperanto) */
+$specialPageAliases['eo'] = [
+ 'CategoryTree' => [ 'Arbo_de_kategorioj', 'Kategorio-arbo' ],
+];
+
+/** Spanish (español) */
+$specialPageAliases['es'] = [
+ 'CategoryTree' => [ 'ÁrbolDeCategorías', 'Árbol_de_categorías' ],
+];
+
+/** Estonian (eesti) */
+$specialPageAliases['et'] = [
+ 'CategoryTree' => [ 'Kategooriapuu' ],
+];
+
+/** Basque (euskara) */
+$specialPageAliases['eu'] = [
+ 'CategoryTree' => [ 'KategoriaZuhaitza' ],
+];
+
+/** Persian (فارسی) */
+$specialPageAliases['fa'] = [
+ 'CategoryTree' => [ 'درخت_رده' ],
+];
+
+/** Finnish (suomi) */
+$specialPageAliases['fi'] = [
+ 'CategoryTree' => [ 'Luokkapuu' ],
+];
+
+/** French (français) */
+$specialPageAliases['fr'] = [
+ 'CategoryTree' => [ 'ArbreCatégorie', 'ArbreCategorie', 'Arbre_catégorie' ],
+];
+
+/** Arpitan (arpetan) */
+$specialPageAliases['frp'] = [
+ 'CategoryTree' => [ 'Structura_d\'âbro_de_les_catègories', 'StructuraDÂbroDeLesCatègories' ],
+];
+
+/** Western Frisian (Frysk) */
+$specialPageAliases['fy'] = [
+ 'CategoryTree' => [ 'Kategorybeam' ],
+];
+
+/** Galician (galego) */
+$specialPageAliases['gl'] = [
+ 'CategoryTree' => [ 'Árbore_de_categorías' ],
+];
+
+/** Swiss German (Alemannisch) */
+$specialPageAliases['gsw'] = [
+ 'CategoryTree' => [ 'Kategoriebaum' ],
+];
+
+/** Gujarati (ગુજરાતી) */
+$specialPageAliases['gu'] = [
+ 'CategoryTree' => [ 'શ્રેણીવૃક્ષ' ],
+];
+
+/** Hebrew (עברית) */
+$specialPageAliases['he'] = [
+ 'CategoryTree' => [ 'עץ_קטגוריות' ],
+];
+
+/** Hindi (हिन्दी) */
+$specialPageAliases['hi'] = [
+ 'CategoryTree' => [ 'श्रेणी_वृक्ष', 'श्रेणीवृक्ष' ],
+];
+
+/** Upper Sorbian (hornjoserbsce) */
+$specialPageAliases['hsb'] = [
+ 'CategoryTree' => [ 'Kategorijowy_štom' ],
+];
+
+/** Xiang Chinese (湘语) */
+$specialPageAliases['hsn'] = [
+ 'CategoryTree' => [ '类别树' ],
+];
+
+/** Haitian (Kreyòl ayisyen) */
+$specialPageAliases['ht'] = [
+ 'CategoryTree' => [ 'NivoKategori' ],
+];
+
+/** Hungarian (magyar) */
+$specialPageAliases['hu'] = [
+ 'CategoryTree' => [ 'Kategóriafa' ],
+];
+
+/** Interlingua (interlingua) */
+$specialPageAliases['ia'] = [
+ 'CategoryTree' => [ 'Arbore_de_categorias' ],
+];
+
+/** Indonesian (Bahasa Indonesia) */
+$specialPageAliases['id'] = [
+ 'CategoryTree' => [ 'Pohon_kategori', 'PohonKategori' ],
+];
+
+/** Ido (Ido) */
+$specialPageAliases['io'] = [
+ 'CategoryTree' => [ 'KategorioArboro' ],
+];
+
+/** Italian (italiano) */
+$specialPageAliases['it'] = [
+ 'CategoryTree' => [ 'AlberoCategorie' ],
+];
+
+/** Japanese (日本語) */
+$specialPageAliases['ja'] = [
+ 'CategoryTree' => [ 'カテゴリツリー' ],
+];
+
+/** Georgian (ქართული) */
+$specialPageAliases['ka'] = [
+ 'CategoryTree' => [ 'კატეგორიის_ხე' ],
+];
+
+/** Khmer (ភាសាខ្មែរ) */
+$specialPageAliases['km'] = [
+ 'CategoryTree' => [ 'មែកធាងចំណាត់ថ្នាក់ក្រុម' ],
+];
+
+/** Korean (한국어) */
+$specialPageAliases['ko'] = [
+ 'CategoryTree' => [ '분류트리' ],
+];
+
+/** Colognian (Ripoarisch) */
+$specialPageAliases['ksh'] = [
+ 'CategoryTree' => [ 'Saachjruppeboum' ],
+];
+
+/** Kurdish (Kurdî) */
+$specialPageAliases['ku'] = [
+ 'CategoryTree' => [ 'Dara_kategoriyan' ],
+];
+
+/** Cornish (kernowek) */
+$specialPageAliases['kw'] = [
+ 'CategoryTree' => [ 'GwedhenGlassys' ],
+];
+
+/** Latin (Latina) */
+$specialPageAliases['la'] = [
+ 'CategoryTree' => [ 'Categoriarum_arbor' ],
+];
+
+/** Ladino (Ladino) */
+$specialPageAliases['lad'] = [
+ 'CategoryTree' => [ 'Árvole_de_Kateggorías' ],
+];
+
+/** Luxembourgish (Lëtzebuergesch) */
+$specialPageAliases['lb'] = [
+ 'CategoryTree' => [ 'Struktur_vun_de_Kategorien' ],
+];
+
+/** Northern Luri (لۊری شومالی) */
+$specialPageAliases['lrc'] = [
+ 'CategoryTree' => [ 'دار_دأسە' ],
+];
+
+/** Malagasy (Malagasy) */
+$specialPageAliases['mg'] = [
+ 'CategoryTree' => [ 'Hazon-tsokajy', 'Hazontsokajy' ],
+];
+
+/** Minangkabau (Baso Minangkabau) */
+$specialPageAliases['min'] = [
+ 'CategoryTree' => [ 'BatangKategori' ],
+];
+
+/** Macedonian (македонски) */
+$specialPageAliases['mk'] = [
+ 'CategoryTree' => [ 'ДрвоНаКатегории' ],
+];
+
+/** Malayalam (മലയാളം) */
+$specialPageAliases['ml'] = [
+ 'CategoryTree' => [ 'വർഗ്ഗവൃക്ഷം' ],
+];
+
+/** Marathi (मराठी) */
+$specialPageAliases['mr'] = [
+ 'CategoryTree' => [ 'वर्गवृक्ष' ],
+];
+
+/** Malay (Bahasa Melayu) */
+$specialPageAliases['ms'] = [
+ 'CategoryTree' => [ 'Salasilah_kategori' ],
+];
+
+/** Maltese (Malti) */
+$specialPageAliases['mt'] = [
+ 'CategoryTree' => [ 'SiġraKategorija' ],
+];
+
+/** Erzya (эрзянь) */
+$specialPageAliases['myv'] = [
+ 'CategoryTree' => [ 'КатегорияньЧувто' ],
+];
+
+/** Norwegian Bokmål (norsk bokmål) */
+$specialPageAliases['nb'] = [
+ 'CategoryTree' => [ 'Kategoritre' ],
+];
+
+/** Low German (Plattdüütsch) */
+$specialPageAliases['nds'] = [
+ 'CategoryTree' => [ 'Kategorieboom' ],
+];
+
+/** Low Saxon (Netherlands) (Nedersaksies) */
+$specialPageAliases['nds-nl'] = [
+ 'CategoryTree' => [ 'Kategorieboom' ],
+];
+
+/** Dutch (Nederlands) */
+$specialPageAliases['nl'] = [
+ 'CategoryTree' => [ 'Categorieboom' ],
+];
+
+/** Norwegian Nynorsk (norsk nynorsk) */
+$specialPageAliases['nn'] = [
+ 'CategoryTree' => [ 'Kategoritre' ],
+];
+
+/** Occitan (occitan) */
+$specialPageAliases['oc'] = [
+ 'CategoryTree' => [ 'ArbreCategoria', 'Arbre_categoria' ],
+];
+
+/** Polish (polski) */
+$specialPageAliases['pl'] = [
+ 'CategoryTree' => [ 'Drzewo_kategorii' ],
+];
+
+/** Pashto (پښتو) */
+$specialPageAliases['ps'] = [
+ 'CategoryTree' => [ 'د_وېشنيزو_ونه' ],
+];
+
+/** Portuguese (português) */
+$specialPageAliases['pt'] = [
+ 'CategoryTree' => [ 'Árvore_de_categorias' ],
+];
+
+/** Brazilian Portuguese (português do Brasil) */
+$specialPageAliases['pt-br'] = [
+ 'CategoryTree' => [ 'Árvore_de_categorias', 'Árvore_de_categoria' ],
+];
+
+/** Romanian (română) */
+$specialPageAliases['ro'] = [
+ 'CategoryTree' => [ 'Arborele_categoriilor' ],
+];
+
+/** Russian (русский) */
+$specialPageAliases['ru'] = [
+ 'CategoryTree' => [ 'Дерево_категорий' ],
+];
+
+/** Sanskrit (संस्कृतम्) */
+$specialPageAliases['sa'] = [
+ 'CategoryTree' => [ 'वर्गवृक्ष:' ],
+];
+
+/** Sicilian (sicilianu) */
+$specialPageAliases['scn'] = [
+ 'CategoryTree' => [ 'AlberoCategorie' ],
+];
+
+/** Sinhala (සිංහල) */
+$specialPageAliases['si'] = [
+ 'CategoryTree' => [ 'ප්‍රවර්ගරුක' ],
+];
+
+/** Slovak (slovenčina) */
+$specialPageAliases['sk'] = [
+ 'CategoryTree' => [ 'StromKategórií' ],
+];
+
+/** Swedish (svenska) */
+$specialPageAliases['sv'] = [
+ 'CategoryTree' => [ 'Kategoriträd' ],
+];
+
+/** Swahili (Kiswahili) */
+$specialPageAliases['sw'] = [
+ 'CategoryTree' => [ 'SafuyaJamii' ],
+];
+
+/** Telugu (తెలుగు) */
+$specialPageAliases['te'] = [
+ 'CategoryTree' => [ 'వర్గవృక్షం' ],
+];
+
+/** Thai (ไทย) */
+$specialPageAliases['th'] = [
+ 'CategoryTree' => [ 'หมวดหมู่แบบผังต้นไม้' ],
+];
+
+/** Tagalog (Tagalog) */
+$specialPageAliases['tl'] = [
+ 'CategoryTree' => [ 'Puno_ng_kaurian' ],
+];
+
+/** Talysh (толышә зывон) */
+$specialPageAliases['tly'] = [
+ 'CategoryTree' => [ 'Категоријон_до' ],
+];
+
+/** Turkish (Türkçe) */
+$specialPageAliases['tr'] = [
+ 'CategoryTree' => [ 'KategoriAğacı', 'KategoriHiyerarşisi', 'UlamAğacı', 'UlamHiyerarşisi' ],
+];
+
+/** Ukrainian (українська) */
+$specialPageAliases['uk'] = [
+ 'CategoryTree' => [ 'Дерево_категорій', 'Дерево_категорий' ],
+];
+
+/** Urdu (اردو) */
+$specialPageAliases['ur'] = [
+ 'CategoryTree' => [ 'شجرہ_زمرہ' ],
+];
+
+/** Venetian (vèneto) */
+$specialPageAliases['vec'] = [
+ 'CategoryTree' => [ 'ÀlbaroCategorie' ],
+];
+
+/** Veps (vepsän kel’) */
+$specialPageAliases['vep'] = [
+ 'CategoryTree' => [ 'KategorijoidenPu' ],
+];
+
+/** Vietnamese (Tiếng Việt) */
+$specialPageAliases['vi'] = [
+ 'CategoryTree' => [ 'Cây_thể_loại' ],
+];
+
+/** Yiddish (ייִדיש) */
+$specialPageAliases['yi'] = [
+ 'CategoryTree' => [ 'קאטעגאריע_בוים' ],
+];
+
+/** Simplified Chinese (中文(简体)‎) */
+$specialPageAliases['zh-hans'] = [
+ 'CategoryTree' => [ '分类树' ],
+];
+
+/** Traditional Chinese (中文(繁體)‎) */
+$specialPageAliases['zh-hant'] = [
+ 'CategoryTree' => [ '分類樹' ],
+];
+
+/** Chinese (Taiwan) (中文(台灣)‎) */
+$specialPageAliases['zh-tw'] = [
+ 'CategoryTree' => [ '分類樹' ],
+];
diff --git a/www/wiki/extensions/CategoryTree/CategoryTree.i18n.magic.php b/www/wiki/extensions/CategoryTree/CategoryTree.i18n.magic.php
new file mode 100644
index 00000000..5fec9fcd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/CategoryTree.i18n.magic.php
@@ -0,0 +1,263 @@
+<?php
+/**
+ * Internationalisation file for extension CategoryTree.
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ * @copyright © 2006-2008 Daniel Kinzler
+ * @license GPL-2.0-or-later
+ */
+
+$magicWords = [];
+
+/** English (English) */
+$magicWords['en'] = [
+ 'categorytree' => [ 0, 'categorytree' ],
+];
+
+/** Afrikaans (Afrikaans) */
+$magicWords['af'] = [
+ 'categorytree' => [ 0, 'kategorieboom', 'categorytree' ],
+];
+
+/** Arabic (العربية) */
+$magicWords['ar'] = [
+ 'categorytree' => [ 0, 'شجرة_تصنيف' ],
+];
+
+/** Egyptian Arabic (مصرى) */
+$magicWords['arz'] = [
+ 'categorytree' => [ 0, 'شجرة_تصنيف' ],
+];
+
+/** Bengali (বাংলা) */
+$magicWords['bn'] = [
+ 'categorytree' => [ 0, 'বিষয়শ্রেণী_বৃক্ষ', 'বিষয়শ্রেণীবৃক্ষ', 'categorytree' ],
+];
+
+/** Breton (brezhoneg) */
+$magicWords['br'] = [
+ 'categorytree' => [ 0, 'GwezennadurRummad' ],
+];
+
+/** Chechen (нохчийн) */
+$magicWords['ce'] = [
+ 'categorytree' => [ 0, 'категоридит', 'деревокатегорий' ],
+];
+
+/** German (Deutsch) */
+$magicWords['de'] = [
+ 'categorytree' => [ 0, 'kategorienbaum', 'kategoriebaum' ],
+];
+
+/** Zazaki (Zazaki) */
+$magicWords['diq'] = [
+ 'categorytree' => [ 0, 'darakategori' ],
+];
+
+/** Esperanto (Esperanto) */
+$magicWords['eo'] = [
+ 'categorytree' => [ 0, 'kategoriarbo' ],
+];
+
+/** Spanish (español) */
+$magicWords['es'] = [
+ 'categorytree' => [ 0, 'árboldecategorías', 'arboldecategorias' ],
+];
+
+/** Estonian (eesti) */
+$magicWords['et'] = [
+ 'categorytree' => [ 0, 'kategooriapuu' ],
+];
+
+/** Persian (فارسی) */
+$magicWords['fa'] = [
+ 'categorytree' => [ 0, 'درخت‌رده', 'درخت_رده' ],
+];
+
+/** French (français) */
+$magicWords['fr'] = [
+ 'categorytree' => [ 0, 'arbrecatégories', 'arbrecats' ],
+];
+
+/** Western Frisian (Frysk) */
+$magicWords['fy'] = [
+ 'categorytree' => [ 0, 'kategorybeam' ],
+];
+
+/** Galician (galego) */
+$magicWords['gl'] = [
+ 'categorytree' => [ 0, 'árboredecategorías' ],
+];
+
+/** Hebrew (עברית) */
+$magicWords['he'] = [
+ 'categorytree' => [ 0, 'עץ_קטגוריה' ],
+];
+
+/** Hindi (हिन्दी) */
+$magicWords['hi'] = [
+ 'categorytree' => [ 0, 'श्रेणी_वृक्ष' ],
+];
+
+/** Igbo (Igbo) */
+$magicWords['ig'] = [
+ 'categorytree' => [ 0, 'óshíshíébéonọr', 'categorytree' ],
+];
+
+/** Italian (italiano) */
+$magicWords['it'] = [
+ 'categorytree' => [ 0, 'alberocategorie' ],
+];
+
+/** Japanese (日本語) */
+$magicWords['ja'] = [
+ 'categorytree' => [ 0, 'カテゴリツリー' ],
+];
+
+/** Georgian (ქართული) */
+$magicWords['ka'] = [
+ 'categorytree' => [ 0, 'კატეგორიის_ხე' ],
+];
+
+/** Korean (한국어) */
+$magicWords['ko'] = [
+ 'categorytree' => [ 0, '분류트리' ],
+];
+
+/** Kurdish (Latin script) (Kurdî (latînî)‎) */
+$magicWords['ku-latn'] = [
+ 'categorytree' => [ 0, 'dara_kategoriyan' ],
+];
+
+/** Cornish (kernowek) */
+$magicWords['kw'] = [
+ 'categorytree' => [ 0, 'gwedhenglass' ],
+];
+
+/** Ladino (Ladino) */
+$magicWords['lad'] = [
+ 'categorytree' => [ 0, 'árvoledekateggorías', 'árboldecategorías', 'arboldecategorias',
+ 'categorytree' ],
+];
+
+/** Malagasy (Malagasy) */
+$magicWords['mg'] = [
+ 'categorytree' => [ 0, 'karazantsokajy', 'categorytree' ],
+];
+
+/** Macedonian (македонски) */
+$magicWords['mk'] = [
+ 'categorytree' => [ 0, 'стеблонакатегории' ],
+];
+
+/** Malayalam (മലയാളം) */
+$magicWords['ml'] = [
+ 'categorytree' => [ 0, 'വർഗ്ഗവൃക്ഷം' ],
+];
+
+/** Marathi (मराठी) */
+$magicWords['mr'] = [
+ 'categorytree' => [ 0, 'वर्गवृक्ष' ],
+];
+
+/** Norwegian Bokmål (norsk bokmål) */
+$magicWords['nb'] = [
+ 'categorytree' => [ 0, 'kategoritre' ],
+];
+
+/** Low Saxon (Netherlands) (Nedersaksies) */
+$magicWords['nds-nl'] = [
+ 'categorytree' => [ 0, 'kategorieboom', 'categorieboom' ],
+];
+
+/** Dutch (Nederlands) */
+$magicWords['nl'] = [
+ 'categorytree' => [ 0, 'categorieboom' ],
+];
+
+/** Norwegian Nynorsk (norsk nynorsk) */
+$magicWords['nn'] = [
+ 'categorytree' => [ 0, 'kategoritre' ],
+];
+
+/** Polish (polski) */
+$magicWords['pl'] = [
+ 'categorytree' => [ 0, 'drzewokategorii' ],
+];
+
+/** Romanian (română) */
+$magicWords['ro'] = [
+ 'categorytree' => [ 0, 'arborecategorie' ],
+];
+
+/** Russian (русский) */
+$magicWords['ru'] = [
+ 'categorytree' => [ 0, 'деревокатегорий' ],
+];
+
+/** Serbian (Cyrillic script) (српски (ћирилица)‎) */
+$magicWords['sr-ec'] = [
+ 'categorytree' => [ 0, 'стаблокатегорије', 'стабло_категорије' ],
+];
+
+/** Serbian (Latin script) (srpski (latinica)‎) */
+$magicWords['sr-el'] = [
+ 'categorytree' => [ 0, 'stablokategorije', 'stablo_kategorije' ],
+];
+
+/** Swedish (svenska) */
+$magicWords['sv'] = [
+ 'categorytree' => [ 0, 'kategoriträd', 'categorytree' ],
+];
+
+/** Turkish (Türkçe) */
+$magicWords['tr'] = [
+ 'categorytree' => [ 0, 'kategorihiyerarşisi', 'kategoriağacı', 'ulamhiyerarşisi', 'ulamağacı' ],
+];
+
+/** Tatar (Cyrillic script) (татарча) */
+$magicWords['tt-cyrl'] = [
+ 'categorytree' => [ 0, 'төркемнәр_шәҗәрәсе' ],
+];
+
+/** Tuvinian (тыва дыл) */
+$magicWords['tyv'] = [
+ 'categorytree' => [ 0, 'аңгылал_ыяжы' ],
+];
+
+/** Ukrainian (українська) */
+$magicWords['uk'] = [
+ 'categorytree' => [ 0, 'деревокатегорій', 'деревокатегорий' ],
+];
+
+/** Urdu (اردو) */
+$magicWords['ur'] = [
+ 'categorytree' => [ 0, 'شجرہ_زمرہ', 'شجر_زمرہ' ],
+];
+
+/** Uzbek (oʻzbekcha/ўзбекча) */
+$magicWords['uz'] = [
+ 'categorytree' => [ 0, 'turkumiyerarxiyasi', 'turkumdaraxti' ],
+];
+
+/** Vietnamese (Tiếng Việt) */
+$magicWords['vi'] = [
+ 'categorytree' => [ 0, 'cây_thể_loại', 'câythểloại' ],
+];
+
+/** Yiddish (ייִדיש) */
+$magicWords['yi'] = [
+ 'categorytree' => [ 0, 'קאטעגאריע_בוים' ],
+];
+
+/** Simplified Chinese (中文(简体)‎) */
+$magicWords['zh-hans'] = [
+ 'categorytree' => [ 0, '分类树' ],
+];
+
+/** Traditional Chinese (中文(繁體)‎) */
+$magicWords['zh-hant'] = [
+ 'categorytree' => [ 0, '分類樹' ],
+];
diff --git a/www/wiki/extensions/CategoryTree/CategoryTree.php b/www/wiki/extensions/CategoryTree/CategoryTree.php
new file mode 100644
index 00000000..697ee270
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/CategoryTree.php
@@ -0,0 +1,48 @@
+<?php
+
+/**
+ * CategoryTree extension, an AJAX based gadget
+ * to display the category structure of a wiki
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ * @copyright © 2006-2008 Daniel Kinzler and others
+ * @license GPL-2.0-or-later
+ */
+
+if ( function_exists( 'wfLoadExtension' ) ) {
+ wfLoadExtension( 'CategoryTree' );
+ // Keep i18n globals so mergeMessageFileList.php doesn't break
+ $wgMessagesDirs['CategoryTree'] = __DIR__ . '/i18n';
+ /* wfWarn(
+ 'Deprecated PHP entry point used for CategoryTree extension. ' .
+ 'Please use wfLoadExtension instead, ' .
+ 'see https://www.mediawiki.org/wiki/Extension_registration for more details.'
+ ); */
+ return true;
+} else {
+ die( 'This version of the CategoryTree extension requires MediaWiki 1.25+' );
+}
+
+// To maintain compatibility with configuration we currently keep
+// the defines, but there are deprecated, and we'll be removed in
+// a future MediaWiki release, in addition to this file.
+
+/**
+* Constants for use with the mode,
+* defining what should be shown in the tree
+*/
+define( 'CT_MODE_CATEGORIES', 0 );
+define( 'CT_MODE_PAGES', 10 );
+define( 'CT_MODE_ALL', 20 );
+define( 'CT_MODE_PARENTS', 100 );
+
+/**
+* Constants for use with the hideprefix option,
+* defining when the namespace prefix should be hidden
+*/
+define( 'CT_HIDEPREFIX_NEVER', 0 );
+define( 'CT_HIDEPREFIX_ALWAYS', 10 );
+define( 'CT_HIDEPREFIX_CATEGORIES', 20 );
+define( 'CT_HIDEPREFIX_AUTO', 30 );
diff --git a/www/wiki/extensions/CategoryTree/Gruntfile.js b/www/wiki/extensions/CategoryTree/Gruntfile.js
new file mode 100644
index 00000000..4aab7c17
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/Gruntfile.js
@@ -0,0 +1,43 @@
+/*!
+ * Grunt file
+ *
+ * @package CategoryTree
+ */
+
+/* eslint-env node */
+module.exports = function ( grunt ) {
+ grunt.loadNpmTasks( 'grunt-jsonlint' );
+ grunt.loadNpmTasks( 'grunt-eslint' );
+ grunt.loadNpmTasks( 'grunt-banana-checker' );
+ grunt.loadNpmTasks( 'grunt-stylelint' );
+
+ grunt.initConfig( {
+ banana: {
+ all: [ 'i18n/' ]
+ },
+ eslint: {
+ all: [
+ '**/*.js',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ },
+ jsonlint: {
+ all: [
+ '**/*.json',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ },
+ stylelint: {
+ all: [
+ '**/*.css',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ }
+ } );
+
+ grunt.registerTask( 'test', [ 'jsonlint', 'banana', 'eslint', 'stylelint' ] );
+ grunt.registerTask( 'default', 'test' );
+};
diff --git a/www/wiki/extensions/CategoryTree/README b/www/wiki/extensions/CategoryTree/README
new file mode 100644
index 00000000..b36de002
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/README
@@ -0,0 +1,18 @@
+--------------------------------------------------------------------------
+README for the CategoryTree extension
+Copyright © 2006-2008 Daniel Kinzler and others
+Licenses: GNU General Public Licence (GPL)
+ GNU Free Documentation License (GFDL)
+--------------------------------------------------------------------------
+
+The CategoryTree extension provides a dynamic view of the wiki's category
+structure as a tree. It uses AJAX to load parts of the tree on demand.
+
+The CategoryTree extension was originally written by Daniel Kinzler in
+2006 and is released under the GNU General Public Licence (GPL). The
+internationalization files contain contributions by several people;
+they are mentioned in each file individually. Also thanks to Tim Starling
+for his contributions.
+
+Instructions on installing and using this extension are available at
+<http://www.mediawiki.org/wiki/Extension:CategoryTree>
diff --git a/www/wiki/extensions/CategoryTree/composer.json b/www/wiki/extensions/CategoryTree/composer.json
new file mode 100644
index 00000000..0107a5d4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/composer.json
@@ -0,0 +1,20 @@
+{
+ "require-dev": {
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
+ },
+ "scripts": {
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
+ "test": [
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
+ ]
+ }
+}
diff --git a/www/wiki/extensions/CategoryTree/extension.json b/www/wiki/extensions/CategoryTree/extension.json
new file mode 100644
index 00000000..9f2d1349
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/extension.json
@@ -0,0 +1,143 @@
+{
+ "name": "CategoryTree",
+ "author": "Daniel Kinzler",
+ "url": "https://www.mediawiki.org/wiki/Extension:CategoryTree",
+ "descriptionmsg": "categorytree-desc",
+ "license-name": "GPL-2.0-or-later",
+ "type": "parserhook",
+ "ConfigRegistry": {
+ "categorytree": "GlobalVarConfig::newInstance"
+ },
+ "ExtensionFunctions": [
+ "CategoryTreeHooks::initialize"
+ ],
+ "SpecialPages": {
+ "CategoryTree": "CategoryTreePage"
+ },
+ "APIModules": {
+ "categorytree": "ApiCategoryTree"
+ },
+ "MessagesDirs": {
+ "CategoryTree": [
+ "i18n"
+ ]
+ },
+ "ExtensionMessagesFiles": {
+ "CategoryTreeAlias": "CategoryTree.alias.php",
+ "CategoryTreeMagic": "CategoryTree.i18n.magic.php"
+ },
+ "AutoloadClasses": {
+ "CategoryTreePage": "includes/CategoryTreePage.php",
+ "CategoryTree": "includes/CategoryTree.php",
+ "CategoryTreeCategoryPage": "includes/CategoryTreeCategoryPage.php",
+ "CategoryTreeCategoryViewer": "includes/CategoryTreeCategoryViewer.php",
+ "CategoryTreeHooks": "includes/CategoryTreeHooks.php",
+ "CategoryTreeMode": "includes/CategoryTreeMode.php",
+ "CategoryTreeHidePrefix": "includes/CategoryTreeHidePrefix.php",
+ "ApiCategoryTree": "includes/ApiCategoryTree.php"
+ },
+ "ResourceModules": {
+ "ext.categoryTree": {
+ "scripts": "ext.categoryTree.js",
+ "targets": [
+ "desktop",
+ "mobile"
+ ],
+ "messages": [
+ "categorytree-collapse",
+ "categorytree-expand",
+ "categorytree-collapse-bullet",
+ "categorytree-expand-bullet",
+ "categorytree-load",
+ "categorytree-loading",
+ "categorytree-nothing-found",
+ "categorytree-no-subcategories",
+ "categorytree-no-parent-categories",
+ "categorytree-no-pages",
+ "categorytree-error",
+ "categorytree-retry"
+ ],
+ "dependencies": [
+ "mediawiki.api"
+ ]
+ },
+ "ext.categoryTree.css": {
+ "targets": [
+ "desktop",
+ "mobile"
+ ],
+ "styles": "ext.categoryTree.css"
+ }
+ },
+ "ResourceFileModulePaths": {
+ "localBasePath": "modules",
+ "remoteExtPath": "CategoryTree/modules"
+ },
+ "Hooks": {
+ "ArticleFromTitle": [
+ "CategoryTreeHooks::articleFromTitle"
+ ],
+ "SpecialTrackingCategories::preprocess": [
+ "CategoryTreeHooks::onSpecialTrackingCategoriesPreprocess"
+ ],
+ "SpecialTrackingCategories::generateCatLink": [
+ "CategoryTreeHooks::onSpecialTrackingCategoriesGenerateCatLink"
+ ],
+ "SkinTemplateOutputPageBeforeExec": "CategoryTreeHooks::skinTemplateOutputPageBeforeExec",
+ "MakeGlobalVariablesScript": "CategoryTreeHooks::getConfigVars",
+ "ParserFirstCallInit": "CategoryTreeHooks::setHooks",
+ "OutputPageMakeCategoryLinks": "CategoryTreeHooks::outputPageMakeCategoryLinks",
+ "SkinJoinCategoryLinks": "CategoryTreeHooks::skinJoinCategoryLinks",
+ "BeforePageDisplay": "CategoryTreeHooks::addHeaders",
+ "BeforePageDisplayMobile": "CategoryTreeHooks::addHeaders",
+ "OutputPageParserOutput": "CategoryTreeHooks::parserOutput"
+ },
+ "config": {
+ "CategoryTreeMaxChildren": 200,
+ "CategoryTreeAllowTag": true,
+ "CategoryTreeDisableCache": 21600,
+ "CategoryTreeHTTPCache": false,
+ "CategoryTreeMaxDepth": {
+ "10": 1,
+ "20": 1,
+ "0": 2
+ },
+ "CategoryTreeForceHeaders": false,
+ "CategoryTreeSidebarRoot": null,
+ "CategoryTreeHijackPageCategories": false,
+ "CategoryTreeUseCategoryTable": true,
+ "CategoryTreeOmitNamespace": 20,
+ "CategoryTreeDefaultMode": 0,
+ "CategoryTreeDefaultOptions": {
+ "mode": null,
+ "hideprefix": null,
+ "showcount": false,
+ "namespaces": false
+ },
+ "CategoryTreeCategoryPageMode": 0,
+ "CategoryTreeCategoryPageOptions": {
+ "mode": null,
+ "showcount": true
+ },
+ "CategoryTreeSpecialPageOptions": {
+ "showcount": true
+ },
+ "CategoryTreeSidebarOptions": {
+ "mode": 0,
+ "hideprefix": 20,
+ "showcount": false,
+ "hideroot": true,
+ "namespaces": false,
+ "depth": 1
+ },
+ "CategoryTreePageCategoryOptions": {
+ "mode": 100,
+ "hideprefix": 20,
+ "showcount": false,
+ "hideroot": false,
+ "namespaces": false,
+ "depth": 0
+ }
+ },
+ "manifest_version": 1
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ace.json b/www/wiki/extensions/CategoryTree/i18n/ace.json
new file mode 100644
index 00000000..29458e5d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ace.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Si Gam Acèh"
+ ]
+ },
+ "categorytree-expand": "Peuluwaih",
+ "categorytree-member-counts": "Na {{PLURAL:$1|1 aneuk kawan}}, {{PLURAL:$2|1 miëng}}, ngön {{PLURAL:$3|1 beureukaih}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 B"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ady-cyrl.json b/www/wiki/extensions/CategoryTree/i18n/ady-cyrl.json
new file mode 100644
index 00000000..da70e5aa
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ady-cyrl.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bedynokue.nart",
+ "Highlander45temp",
+ "SamGamgee",
+ "Amire80"
+ ]
+ },
+ "categorytree-expand": "зэхэщ",
+ "categorytree-member-counts": "{{PLURAL:$1|1 КӀэткатегорие|$1 КӀэткатегориехэр}}, {{PLURAL:$2|1 нэкӀубгъу|$2 нэкӀубгъохэр}}, ыкӀи {{PLURAL:$3|1 файл|$3 файлэхэр}} илъых",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Н",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/aeb-arab.json b/www/wiki/extensions/CategoryTree/i18n/aeb-arab.json
new file mode 100644
index 00000000..ae7ae0d2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/aeb-arab.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Csisc"
+ ]
+ },
+ "categorytree-num-pages": " $1 پ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/aeb-latn.json b/www/wiki/extensions/CategoryTree/i18n/aeb-latn.json
new file mode 100644
index 00000000..9951733d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/aeb-latn.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "GeekEmad"
+ ]
+ },
+ "categorytree-expand": "wesseģ",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/aeb.json b/www/wiki/extensions/CategoryTree/i18n/aeb.json
new file mode 100644
index 00000000..f54765c8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/aeb.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Csisc"
+ ]
+ },
+ "categorytree-expand": "Wassiģ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/af.json b/www/wiki/extensions/CategoryTree/i18n/af.json
new file mode 100644
index 00000000..e015dd34
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/af.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arnobarnard",
+ "Naudefj",
+ "SPQRobin",
+ "Fwolff"
+ ]
+ },
+ "categorytree": "Kategorieboom",
+ "categorytree-portlet": "Kategorieë",
+ "categorytree-legend": "Wys kategorieboom",
+ "categorytree-desc": "Bekyk en navigeer deur die [[Special:CategoryTree|kategoriestruktuur]] van 'n wiki",
+ "categorytree-header": "Tik 'n kategorienaam om die inhoud as 'n boomstruktuur te sien. Hierdie benodig gevorderde JavaScript-funksionaliteit, bekend as AJAX. Dit sal egter nie werk as u 'n baie ou blaaier gebruik of as JavaScript gedeaktiveer is nie.",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Wys boom",
+ "categorytree-parents": "ouers",
+ "categorytree-mode-categories": "slegs kategorieë",
+ "categorytree-mode-pages": "bladsye met prentbladsye uitgesluit",
+ "categorytree-mode-all": "alle bladsye",
+ "categorytree-collapse": "vou toe",
+ "categorytree-expand": "vou oop",
+ "categorytree-member-counts": "bevat {{PLURAL:$1|een subkategorie|$1 subkategorieë}}, {{PLURAL:$2|een bladsy|$2 bladsye}} en {{PLURAL:$3|een lêer|$3 lêers}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 B",
+ "categorytree-num-files": "$1 L",
+ "categorytree-num-empty": "leeg",
+ "categorytree-load": "laai",
+ "categorytree-loading": "laai tans…",
+ "categorytree-nothing-found": "niks gevind nie",
+ "categorytree-no-subcategories": "geen subkategorieë nie",
+ "categorytree-no-parent-categories": "geen kategorieë boontoe",
+ "categorytree-no-pages": "geen bladsye of subkategorieë nie",
+ "categorytree-not-found": "Kategorie <i>$1</i> nie gevind nie",
+ "categorytree-error": "Probleem met die laai van die data.",
+ "categorytree-retry": "Wag asseblief 'n rukkie en probeer weer."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ais.json b/www/wiki/extensions/CategoryTree/i18n/ais.json
new file mode 100644
index 00000000..8cfd53e2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ais.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Benel",
+ "Bunukwiki",
+ "Tokoabibi"
+ ]
+ },
+ "categorytree": "kakuniza a kilang",
+ "categorytree-portlet": "kakuniza",
+ "categorytree-legend": "paazih kakuniza a kilang",
+ "categorytree-desc": "kapahay likit a kawaw misabaluh a sasakawawen pasubana’ tu miidangay [[Special:CategoryTree|kakuniza pakaukak]]",
+ "categorytree-header": "kapisulitan tu kakunizaay a kalungangan u misaungayay masakilangay a zunga kulit miciwsace kakuniza lacul. (maydih misaungay JavaScript.)",
+ "categorytree-category": "kakuniza:",
+ "categorytree-go": "paazih sakilang zunga a kulit",
+ "categorytree-parents": "ipabaway a kakuniza",
+ "categorytree-mode-label": "muse:",
+ "categorytree-mode-categories": "paazih kakuniza a cacay",
+ "categorytree-mode-pages": "kasabelih caay yamalyilu tangan",
+ "categorytree-mode-all": "hamin nu kasabelih",
+ "categorytree-collapse": "piked",
+ "categorytree-expand": "micuwat",
+ "categorytree-member-counts": "yamalyilu {{PLURAL:$1|$1 iluc-kasasizuma}}, {{PLURAL:$2|$2 kasabelih}}, atu {{PLURAL:$3|$3 tangan}}",
+ "categorytree-num-categories": "$1 kakuniza",
+ "categorytree-num-pages": "$1 kasabelih",
+ "categorytree-num-files": "$1 tangan",
+ "categorytree-num-empty": "inayi’",
+ "categorytree-load": "maasip",
+ "categorytree-loading": "miasip henay ayza…",
+ "categorytree-nothing-found": "caykatepa amahicahica tu kasacacay",
+ "categorytree-no-subcategories": "inayi’ sailuc-kasasizuma",
+ "categorytree-no-parent-categories": "inayi’ pabaway a kakuniza",
+ "categorytree-no-pages": "inayi’ kasabelih saca sailuc-kasasizuma",
+ "categorytree-not-found": "inayi’ kakuniza <i>$1</i>",
+ "categorytree-error": "imahini miasip kalunasulitan mungangaw.",
+ "categorytree-retry": "pihalhal’i pitaneng henay ku cacay.",
+ "apihelp-categorytree-description": "saungay i CategoryTree sacunus a labu bacu-saupu.",
+ "apihelp-categorytree-param-category": "i kakuniza pangangananay a salaedan a satangahan, anu izaw saayaway sulit amasekipo",
+ "apihelp-categorytree-param-options": "patudud CategoryTree patizeng ilucay nu JSON tuutuud aazihen-sulyang. <var>depth</var> kasacacay pataayaw tu kawaw ku <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "mapiliay kanca ku kapahay a JSON tuutuud."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/am.json b/www/wiki/extensions/CategoryTree/i18n/am.json
new file mode 100644
index 00000000..5e68e4bc
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/am.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Codex Sinaiticus",
+ "Elfalem"
+ ]
+ },
+ "categorytree": "የመደቦች ዛፍ",
+ "categorytree-portlet": "መደቦች",
+ "categorytree-legend": "የመደቦች ዛፍ ለማየት",
+ "categorytree-header": "[+] ተጭነው ንዑሱ-መደብ ይዘረጋል፣ [-] ተጭነው ደግሞ ይመልሳል።\n\nበግራ በኩል ባለው ሳጥን ውስጥ የመደቡን ስም ዝም ብለው መጻፍ ይችላሉ። (የዚሁ ዊኪ መደብ ስሞች ለመመልከት፣ [[Special:Mostlinkedcategories|እዚህ ይጫኑ]]።) ከዚያ፥ ምን ያሕል ንዑስ-መደቦች እንዳሉበት ለማየት «ዛፉ ይታይ» የሚለውን ይጫኑ። በቀኝ በኩል ካለው ሳጥን 'all pages' ከመረጡ፥ በየመደቡ ውስጥ ያሉት መጣጥፎች በተጨማሪ ይታያሉ።\n\n''(ማስታወሻ: ይህ በኮምፒውተርዎ እንዲሠራ 'ጃቫ' የሚችል ዌብ-ብራውዘር ያስፈልጋል።)''",
+ "categorytree-category": "የመደብ ስም፦",
+ "categorytree-go": "ዛፉ ይታይ",
+ "categorytree-parents": "ላዕላይ መደቦች",
+ "categorytree-mode-categories": "መደቦች ብቻ",
+ "categorytree-mode-all": "ሁሉም ገጾች",
+ "categorytree-loading": "ሊመጣ ነው",
+ "categorytree-nothing-found": "የለም",
+ "categorytree-no-subcategories": "ንዑስ መደብ የለም",
+ "categorytree-no-pages": "ምንም ገጾችና ንዑስ-መደቦች የሉም",
+ "categorytree-not-found": "«$1» የተባለ መደብ የለም።",
+ "categorytree-retry": "ትንሽ ቆይተው እንደገና ይሞክሩ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/an.json b/www/wiki/extensions/CategoryTree/i18n/an.json
new file mode 100644
index 00000000..1e52c0cd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/an.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Juanpabl"
+ ]
+ },
+ "categorytree": "Árbol de categorías",
+ "categorytree-portlet": "Categorías",
+ "categorytree-legend": "Amostar l'árbol de categorías",
+ "categorytree-desc": "Traste basato en AJAX t'amostrar a [[Special:CategoryTree|estrutura de categorías]] d'una wiki",
+ "categorytree-header": "Escriba un nombre de categoría ta veyer os suyos contenius en forma d'árbol. Pare cuenta que ista pachina requiere as funcions JavaScriptz abanzatas conoixitas como AJAX. Si tiene un navegador antigo, u tiene desactivato JavaScript, a pachina no funcionará.",
+ "categorytree-category": "Categoría:",
+ "categorytree-go": "Amostrar l'Árbol",
+ "categorytree-parents": "Categorías mais",
+ "categorytree-mode-label": "Modo:",
+ "categorytree-mode-categories": "amostrar nomás categorías",
+ "categorytree-mode-pages": "pachinas pero no ficheros",
+ "categorytree-mode-all": "todas as pachinas",
+ "categorytree-collapse": "amagar",
+ "categorytree-expand": "amostrar",
+ "categorytree-member-counts": "contiene {{PLURAL:$1|1 sucategoría|$1 subcategorías}}, {{PLURAL:$2|1 pachina|$2 pachinas}}, y {{PLURAL:$3|1 fichero|$3 ficheros}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vueda",
+ "categorytree-load": "cargar",
+ "categorytree-loading": "cargando",
+ "categorytree-nothing-found": "No s'ha trobato cosa",
+ "categorytree-no-subcategories": "no bi ha subcategorías",
+ "categorytree-no-parent-categories": "Garra categoría mai",
+ "categorytree-no-pages": "No bi ha articlos ni subcategorías",
+ "categorytree-not-found": "Categoría ''$1'' no trobata",
+ "categorytree-error": "Error en cargar os datos",
+ "categorytree-retry": "Por favor, aspere bels intes y prebe de nuevas."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ang.json b/www/wiki/extensions/CategoryTree/i18n/ang.json
new file mode 100644
index 00000000..c5eed62b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ang.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gott wisst"
+ ]
+ },
+ "categorytree-expand": "gebrǣded",
+ "categorytree-num-categories": "$1 F",
+ "categorytree-num-pages": "$1 T",
+ "categorytree-num-files": "$1 Y"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/anp.json b/www/wiki/extensions/CategoryTree/i18n/anp.json
new file mode 100644
index 00000000..9df2a449
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/anp.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Angpradesh",
+ "Samyo"
+ ]
+ },
+ "categorytree-expand": "विस्तार",
+ "categorytree-member-counts": "एकरा मं॑ {{PLURAL:$1|एगऽ उपश्रेणी|$1 उपश्रेणी}}, {{PLURAL:$2|एगऽ पन्ना |$2 पन्ना}},आरू {{PLURAL:$3|एगऽ फ़ाइल|$3 फ़ाइल}} छै",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ar.json b/www/wiki/extensions/CategoryTree/i18n/ar.json
new file mode 100644
index 00000000..3d3ee06e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ar.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "AwamerT",
+ "Meno25",
+ "Mido",
+ "OsamaK",
+ "زكريا",
+ "Abanima",
+ "Maroen1990",
+ "Moud hosny"
+ ]
+ },
+ "categorytree": "شجرة تصنيفات",
+ "categorytree-portlet": "تصنيفات",
+ "categorytree-legend": "عرض شجرة التصنيفات",
+ "categorytree-desc": "إضافة معتمدة على الأجاكس لعرض [[Special:CategoryTree|هيكل التصنيف]] لويكي",
+ "categorytree-header": "أدخل اسم تصنيف لترى محتوياته كتركيب شجري. (يتطلب جافا سكريبت.)",
+ "categorytree-category": "تصنيف:",
+ "categorytree-go": "عرض الشجرة",
+ "categorytree-parents": "مصنف تحت",
+ "categorytree-mode-label": "الوضع:",
+ "categorytree-mode-categories": "تصنيفات فقط",
+ "categorytree-mode-pages": "الصفحات ماعدا الملفات",
+ "categorytree-mode-all": "كل الصفحات",
+ "categorytree-collapse": "اطو",
+ "categorytree-expand": "فرد",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "يحتوي على {{PLURAL:$1|1 تصنيف فرعي واحد|تصنيفين فرعيين|$1 تصنيفات فرعية|$1 تصنيف فرعي}} و{{PLURAL:$2| صفحة واحدة|صفحتين|$2 صفحات|$2 صفحة}}، و {{PLURAL:$3| ملف واحد|ملفين|$3 ملفات|$3 ملفاً|$3 ملف}}",
+ "categorytree-num-categories": "$1 ت",
+ "categorytree-num-pages": " $1 ص",
+ "categorytree-num-files": " $1 م",
+ "categorytree-num-empty": "فارغ",
+ "categorytree-load": "حمل",
+ "categorytree-loading": "جار التحميل",
+ "categorytree-nothing-found": "لم يتم العثور على شيء",
+ "categorytree-no-subcategories": "لا تصنيفات فرعية",
+ "categorytree-no-parent-categories": "لا تصنيفات أصلية",
+ "categorytree-no-pages": "لا صفحات ولا تصنيفات فرعية",
+ "categorytree-not-found": "التصنيف «$1» لم يتم العثور عليه",
+ "categorytree-error": "مشكلة في تحميل البيانات.",
+ "categorytree-retry": "من فضلك انتظر لحظة وحاول مرة أخرى.",
+ "apihelp-categorytree-description": "الوحدة لداخلية للتصنيفات الصحيحة.",
+ "apihelp-categorytree-summary": "جزء داخلي لامتداد CategoryTree.",
+ "apihelp-categorytree-param-category": "العنوان في مساحة اسم الفئة. يتم تجاهل البادئة إذا كان محدد.",
+ "apihelp-categorytree-param-options": "الخيارات لمنشيء CategoryTree ككائن JSON object. خيار <var>depth</var> القيمة الافتراضية له هي <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "الخيارات يجب أن تكون كائن JSON صحيح."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/arc.json b/www/wiki/extensions/CategoryTree/i18n/arc.json
new file mode 100644
index 00000000..5ceaa134
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/arc.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Basharh"
+ ]
+ },
+ "categorytree": "ܐܝܠܢܐ ܕܣܕܪܐ",
+ "categorytree-portlet": "ܣܕܪ̈ܐ",
+ "categorytree-legend": "ܚܘܝ ܐܝܠܢܐ ܕܣܘܕܪܐ",
+ "categorytree-category": "ܣܕܪܐ:",
+ "categorytree-go": "ܚܘܝ ܐܝܠܢܐ",
+ "categorytree-mode-categories": "ܣܕܪ̈ܐ ܒܠܚܘܕ",
+ "categorytree-mode-pages": "ܦܐܬܬ̈ܐ ܫܒܘܩ ܕܠܦܦ̈ܐ",
+ "categorytree-mode-all": "ܟܠ ܦܐܬܬ̈ܐ",
+ "categorytree-collapse": "ܐܟܪܟ",
+ "categorytree-expand": "ܐܪܘܚ",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "ܚܒܫ ܥܠ {{PLURAL:$1|1 ܣܕܪܐ ܦܪܥܝܐ|$1 ܣܕܪ̈ ܦܪ̈ܥܝܐ}}، {{PLURAL:$2|1 ܦܐܬܐ|$2 ܦܐܬܬ̈ܐ}}، ܘ{{PLURAL:$3|1 ܠܦܦܐ|$3 ܠܦܦ̈ܐ}}",
+ "categorytree-num-categories": "$1 ܣ",
+ "categorytree-num-pages": " $1 ܦ",
+ "categorytree-num-files": "$1 ܠ",
+ "categorytree-num-empty": "ܣܦܝܩܐ",
+ "categorytree-load": "ܛܥܢ",
+ "categorytree-loading": "ܛܘܥܢܐ...",
+ "categorytree-no-subcategories": "ܠܝܬ ܣܕܪ̈ܐ ܦܪ̈ܥܝܐ",
+ "categorytree-not-found": "ܣܕܪܐ <i>$1</i> ܠܐ ܐܫܟܚܬ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/arq.json b/www/wiki/extensions/CategoryTree/i18n/arq.json
new file mode 100644
index 00000000..17458514
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/arq.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bachounda",
+ "Oldstoneage"
+ ]
+ },
+ "categorytree-expand": "طوّر",
+ "categorytree-member-counts": "محمول فيه {{PLURAL:$1|1 تحتتصنيفة|$1 تحتتصنيفات}}, {{PLURAL:$2|1 باجة|$2 باجات}}، و {{PLURAL:$3|1 فيشي|$3 فيشيّات}}",
+ "categorytree-num-categories": " $1 ص",
+ "categorytree-num-pages": " $1 ص",
+ "categorytree-num-files": " $1 م"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/arz.json b/www/wiki/extensions/CategoryTree/i18n/arz.json
new file mode 100644
index 00000000..73ff04f4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/arz.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ghaly",
+ "Meno25",
+ "Ramsis II"
+ ]
+ },
+ "categorytree": "شجرة تصنيف",
+ "categorytree-portlet": "تصنيفات",
+ "categorytree-legend": "عرض شجرة التصنيف",
+ "categorytree-desc": "ابحار بديناميكية فى [[Special:CategoryTree|هيكل التصنيف]]",
+ "categorytree-header": "دخل اسم التصنيف علشان تشوف المحتويات بتاعته على هيئة شجرة.\nلاحظ ان دا بيعوز خاصية جافاسكريبت متقدمة اسمها اجاكس.\nلو البراوز بتاعك قديم جدا،او الجافاسكريبت عندك متعطلة،دا مش ح يشتغل.",
+ "categorytree-category": "تصنيف:",
+ "categorytree-go": "عرض الشجره",
+ "categorytree-parents": "متصنف تحت",
+ "categorytree-mode-categories": "تصانيف بس",
+ "categorytree-mode-pages": "الصفحات من غير الملفات",
+ "categorytree-mode-all": "كل الصفحات",
+ "categorytree-collapse": "اضغط",
+ "categorytree-expand": "اتوسع",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "فيه {{PLURAL:$1|1 تصنيف فرعي|$1 تصنيف فرعي}}، {{PLURAL:$2|1 صفحة|$2 صفحة}}، و {{PLURAL:$3|1 ملف|$3 ملف}}",
+ "categorytree-num-categories": "$1 ت",
+ "categorytree-num-pages": " $1 ص",
+ "categorytree-num-files": " $1 م",
+ "categorytree-load": "تحميل",
+ "categorytree-loading": "بيحمل",
+ "categorytree-nothing-found": "مالقيناش حاجة",
+ "categorytree-no-subcategories": "مافيش تصنيفات فرعية",
+ "categorytree-no-parent-categories": "مافيش تصانيف أصلية",
+ "categorytree-no-pages": "مافيش ولا فى صفحات ولا تصانيف فرعية",
+ "categorytree-not-found": "التصنيف <i>$1</i> مش متلاقي",
+ "categorytree-error": "مشكلة فى تحميل البيانات.",
+ "categorytree-retry": "لو سمحت تستنا لحظة و بعدين حاول تاني"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/as.json b/www/wiki/extensions/CategoryTree/i18n/as.json
new file mode 100644
index 00000000..9c1d2cd2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/as.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bishnu Saikia",
+ "Chaipau",
+ "Gitartha.bordoloi",
+ "Psneog",
+ "Rajuonline",
+ "Simbu123"
+ ]
+ },
+ "categorytree": "শ্ৰেণীবৃক্ষ",
+ "categorytree-portlet": "শ্ৰেণী",
+ "categorytree-legend": "শ্ৰেণীবৃক্ষ দেখুৱাওক",
+ "categorytree-desc": "[[Special:CategoryTree|শ্ৰেণীবৃক্ষ গঠন]] পৰিদৰ্শন কৰক",
+ "categorytree-header": "সমলসমূহ বৃক্ষৰূপত চাবলৈ এটা শ্ৰেণীৰ নাম লিখক।\nমন কৰক যে এনে কৰিবলৈ AJAX নামৰ এটা উচ্চস্তৰৰ জাভা কৌশলৰ আৱশ্যক।\nআপোনাৰ ব্ৰাওজাৰ অতি পুৰণি হ'লে বা জাভাস্ক্ৰিপ্ট নিষ্ক্ৰিয় হৈ থাকিলে ই কাম নকৰিব।",
+ "categorytree-category": "শ্ৰেণীবৄক্ষ:",
+ "categorytree-go": "বৃক্ষ দেখুৱাওক",
+ "categorytree-parents": "পালক",
+ "categorytree-mode-label": "প্ৰণালী:",
+ "categorytree-mode-categories": "কেৱল শ্ৰেণী",
+ "categorytree-mode-pages": "ফাইল বাদে পৃষ্ঠাসমূহ",
+ "categorytree-mode-all": "সকলো পৃষ্ঠা",
+ "categorytree-collapse": "সংকোচন",
+ "categorytree-expand": "বহলাওক",
+ "categorytree-member-counts": "{{PLURAL:$1|এটা উপশ্ৰেণী|$1টা উপশ্ৰেণী}}, {{PLURAL:$2|এটা পৃষ্ঠা|$2টা পৃষ্ঠা}}, আৰু {{PLURAL:$3|এটা ফাইল|$3টা ফাইল}} আছে",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "খালি",
+ "categorytree-load": "ল'ড কৰক",
+ "categorytree-loading": "ল'ড কৰি থকা হৈছে...",
+ "categorytree-nothing-found": "একো পোৱা নগ'ল",
+ "categorytree-no-subcategories": "উপশ্ৰেণী নাই",
+ "categorytree-no-parent-categories": "কোনো মূল বিষয়শ্ৰেণী নাই",
+ "categorytree-no-pages": "এনে কোনো পৃষ্ঠা বা উপশ্ৰেণী নাই",
+ "categorytree-not-found": "<i>$1</i> শ্ৰেণীটো বিচাৰি পোৱা নগল",
+ "categorytree-error": "তথ্য ল'ড কৰাত সমস্যা হৈছে।",
+ "categorytree-retry": "অনুগ্ৰহ কৰি কিছু সময় অপেক্ষা কৰি তাৰ পিছত চেষ্টা কৰক।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ase.json b/www/wiki/extensions/CategoryTree/i18n/ase.json
new file mode 100644
index 00000000..e6a60ac4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ase.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Icemandeaf"
+ ]
+ },
+ "categorytree-num-categories": "$1 M509x510S16d20492x490",
+ "categorytree-num-pages": "$1 M516x512S14051485x488",
+ "categorytree-num-files": "$1 M511x515S1ce20489x485"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ast.json b/www/wiki/extensions/CategoryTree/i18n/ast.json
new file mode 100644
index 00000000..06f5af2c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ast.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Esbardu",
+ "Xuacu"
+ ]
+ },
+ "categorytree": "Árbole de categoríes",
+ "categorytree-portlet": "Categoríes",
+ "categorytree-legend": "Amosar l'árbole de categoríes",
+ "categorytree-desc": "Accesoriu basáu n'AJAX qu'amuesa la [[Special:CategoryTree|estructura de categoríes]] d'una wiki",
+ "categorytree-header": "Escribe un nome de categoría pa ver el so conteníu con estructura d'árbole. (Rique JavaScript)",
+ "categorytree-category": "Categoría:",
+ "categorytree-go": "Amosar árbole",
+ "categorytree-parents": "Categoríes superiores",
+ "categorytree-mode-label": "Mou:",
+ "categorytree-mode-categories": "categoríes namái",
+ "categorytree-mode-pages": "páxines sacante los archivos",
+ "categorytree-mode-all": "toles páxines",
+ "categorytree-collapse": "anubrir",
+ "categorytree-expand": "espander",
+ "categorytree-member-counts": "Contien {{PLURAL:$1|1 subcategoría|$1 subcategoríes}}, {{PLURAL:$2|1 páxina|$2 páxines}} y {{PLURAL:$3|1 ficheru|$3 ficheros}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "balera",
+ "categorytree-load": "cargar",
+ "categorytree-loading": "cargando",
+ "categorytree-nothing-found": "nun s'atopó nada",
+ "categorytree-no-subcategories": "nun hai subcategoríes",
+ "categorytree-no-parent-categories": "nun hai categoríes padre",
+ "categorytree-no-pages": "ensin páxines nin subcategoríes",
+ "categorytree-not-found": "Nun s'atopó la categoría <i>$1</i>",
+ "categorytree-error": "Hebo un problema al cargar los datos.",
+ "categorytree-retry": "Por favor, espera unos momentos y inténtalo otra vuelta.",
+ "apihelp-categorytree-description": "Módulu internu pa la estensión CategoryTree.",
+ "apihelp-categorytree-summary": "Módulu internu pa la estensión CategoryTree.",
+ "apihelp-categorytree-param-category": "Títulu nel espaciu de nomes de categoríes, inoraráse'l prefixu si se da.",
+ "apihelp-categorytree-param-options": "Opciones pal constructor de CategoryTree como oxetu JSON. La opción <var>depth</var> (fondura) tien el valor predetermináu de <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Les opciones tienen de ser un oxetu JSON válidu."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/atj.json b/www/wiki/extensions/CategoryTree/i18n/atj.json
new file mode 100644
index 00000000..aa8c54f2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/atj.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amqui",
+ "Jean-paul echaquan",
+ "Nehirowisiw",
+ "Ninmeka",
+ "Benoit Rochon"
+ ]
+ },
+ "categorytree-portlet": "Ka ici arimotcikateki",
+ "categorytree-category": "Ka ici arimotcikatek:",
+ "categorytree-mode-all": "Kaskina paskickwemikana",
+ "categorytree-expand": "otamirota",
+ "categorytree-member-counts": "Ka acteki{{PLURAL:$1|1 subcategory|$1 subcategories}} $1 {{PLURAL:$1|Ka tatwenikateki}}, {{PLURAL:$2|1 page|$2 pages}} $2 {{PLURAL:$2|masinahikana}}, kaie {{PLURAL:$3|1 file|$3 files}} $3 {{PLURAL:$3|Masinahikaniwoc}}",
+ "categorytree-num-categories": "$1 M",
+ "categorytree-num-pages": "$1 M",
+ "categorytree-num-files": "$1 M"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/av.json b/www/wiki/extensions/CategoryTree/i18n/av.json
new file mode 100644
index 00000000..a2984593
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/av.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gazimagomedov"
+ ]
+ },
+ "categorytree-expand": "рагьизе",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Гь",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/avk.json b/www/wiki/extensions/CategoryTree/i18n/avk.json
new file mode 100644
index 00000000..2fbc6b2e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/avk.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Wikimistusik"
+ ]
+ },
+ "categorytree": "LomaAal",
+ "categorytree-header": "Ta wira va aaldrekoraf cek va lomayolt bazel !\nStragal da batcoba va AJAX JavaScript fliaca kucilar.\nEde va guazafi exulesiki favel oke ede JavaScript fliaceem tir metegis, batcoba me guyundeter.",
+ "categorytree-category": "Loma:",
+ "categorytree-go": "Nedira va aal",
+ "categorytree-parents": "Veylomeem",
+ "categorytree-mode-categories": "Anton lomeem",
+ "categorytree-mode-pages": "Bueem rade ewaveem",
+ "categorytree-mode-all": "bueem",
+ "categorytree-collapse": "koatcera",
+ "categorytree-expand": "divatcera",
+ "categorytree-load": "vajara",
+ "categorytree-loading": "vajas",
+ "categorytree-nothing-found": "mek trasiks",
+ "categorytree-no-subcategories": "meka volveyloma",
+ "categorytree-no-pages": "meku bu oku volveyloma",
+ "categorytree-not-found": "<i>$1</i> loma metrasiyina",
+ "categorytree-error": "Zvak remi origvajara.",
+ "categorytree-retry": "Vay kemel aze tolyawal !"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/awa.json b/www/wiki/extensions/CategoryTree/i18n/awa.json
new file mode 100644
index 00000000..d99d8c0c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/awa.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "1AnuraagPandey"
+ ]
+ },
+ "categorytree": "श्रेणीवृक्ष",
+ "categorytree-portlet": "कुल श्रेणि",
+ "categorytree-legend": "श्रेणीवृक्ष देखाओ",
+ "categorytree-desc": "विकि कय [[Special:CategoryTree|श्रेणी संरचना]] देखा जाय",
+ "categorytree-header": "कवनो श्रेणी कय कुल चिज पेड कय रूप में देखावे कय लिये ओकर नावँ दिहा जाय।\nध्यान रख्खा जाय कि इ सुविधा कय लिये AJAX नावँ कय जावास्क्रिप्ट सुविधा कय ज़रूरत होत है।\nअगर आप कय ब्राउज़र बहुत पुरान है, या जावास्क्रिप्ट अक्षम है, तव इ काम नाई करि।",
+ "categorytree-category": "श्रेणी:",
+ "categorytree-go": "पेड देखाओ",
+ "categorytree-parents": "पालक",
+ "categorytree-mode-label": "मोड:",
+ "categorytree-mode-categories": "खाली श्रेणी कुल",
+ "categorytree-mode-pages": "फ़ाइल कय अलावा पन्ना",
+ "categorytree-mode-all": "कुल पन्ना",
+ "categorytree-collapse": "छोट करो",
+ "categorytree-expand": "बडा करो",
+ "categorytree-member-counts": "एहमा {{PLURAL:$1|एक उपश्रेणी|$1 उपश्रेणिन्}}, {{PLURAL:$2|एक पन्ना|$2 पन्नन}}, अव {{PLURAL:$3|एक फ़ाइल|$3 फ़ाइलन्}} हँय।",
+ "categorytree-num-categories": "$1 श्र",
+ "categorytree-num-pages": "$1 प",
+ "categorytree-num-files": "$1 फ़ा",
+ "categorytree-num-empty": "खाली",
+ "categorytree-load": "लोड करा जाय",
+ "categorytree-loading": "लोड होत है...",
+ "categorytree-nothing-found": "कुछ नाई मिला",
+ "categorytree-no-subcategories": "उपश्रेणी नाँई हँय",
+ "categorytree-no-parent-categories": "कवनो जनक श्रेणि नाई हँय",
+ "categorytree-no-pages": "कवनो पन्ना या उपश्रेणी नाई हय",
+ "categorytree-not-found": "श्रेणी <i>$1</i> नाई मिला",
+ "categorytree-error": "डाटा लोड करय में समस्या।",
+ "categorytree-retry": "तनी थोरै समय बाद प्रयास करा जाय।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ay.json b/www/wiki/extensions/CategoryTree/i18n/ay.json
new file mode 100644
index 00000000..43c62663
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ay.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dferg",
+ "MarcoAurelio"
+ ]
+ },
+ "categorytree-category": "Patawi:"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/az.json b/www/wiki/extensions/CategoryTree/i18n/az.json
new file mode 100644
index 00000000..067c4f08
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/az.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cekli829",
+ "PPerviz",
+ "Vugar 1981",
+ "Wertuose",
+ "Dağlı95"
+ ]
+ },
+ "categorytree": "Kateqoriya ağacı",
+ "categorytree-portlet": "Kateqoriyalar",
+ "categorytree-legend": "Kateqoriya ağacını göstər.",
+ "categorytree-desc": "[[Special:CategoryTree|Kategori sistemini]] dinamik idarə et",
+ "categorytree-header": "Kategoriya adını girib, içerisini ierarxik şəkildə görə bilərsiniz. Bu özəllik AJAX adıyla biliən JavaScript ilə oşləyər. əgər operatorunuz köhnə isə ya da JavaScript istifadəsi mümkün deyilsə, işləməz.",
+ "categorytree-category": "Kateqoriya:",
+ "categorytree-go": "Yüklə",
+ "categorytree-parents": "Üst kateqoriyalar",
+ "categorytree-mode-categories": "sadəcə kateqoriyaları göstər",
+ "categorytree-mode-pages": "Fayllardan əlavə səhifələr",
+ "categorytree-mode-all": "bütün səhifələr",
+ "categorytree-collapse": "gizlə",
+ "categorytree-expand": "genişləndir",
+ "categorytree-member-counts": "Bu kateqoriya, {{PLURAL:$1|1 altkategoriya|$1 altkategoriya}}, {{PLURAL:$2|1 səhifə|$2 səhifə}} və {{PLURAL:$3|1 şəkil|$3 şəkil}}dən ibarətdir.",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "boş",
+ "categorytree-load": "yüklə",
+ "categorytree-loading": "yüklənir…",
+ "categorytree-nothing-found": "Təəsüf edirik, nəticə yoxdur.",
+ "categorytree-no-subcategories": "alt kateqoriyalar yoxdur",
+ "categorytree-no-parent-categories": "Üst kateqoriya yoxdur.",
+ "categorytree-no-pages": "Alt kateqoriya və məqalə yoxdur.",
+ "categorytree-not-found": "<i>\"$1\"</i> adlı kateqoriya tapılmadı.",
+ "categorytree-error": "Məlumat bazasında problem var.",
+ "categorytree-retry": "Xahiş edirik bir az gözləyin və yenidən yoxlayın."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/azb.json b/www/wiki/extensions/CategoryTree/i18n/azb.json
new file mode 100644
index 00000000..14b3707c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/azb.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amir a57",
+ "E THP",
+ "Mousa",
+ "Koroğlu",
+ "Alp Er Tunqa",
+ "ییلماز"
+ ]
+ },
+ "categorytree": "بولمه آغاجی",
+ "categorytree-portlet": "بؤلمه‌لر",
+ "categorytree-legend": "بولمه آغاجین گوستر",
+ "categorytree-desc": "[[Special:CategoryTree|بولمه لر سیستئمینی]] دینامیک ایداره ائت",
+ "categorytree-header": "بولمه آدینی گیریب، ایچئری‌سینی آغاج شکیلده گؤره بیلرسینیز. بو خصوصی ای جکس آدییلا بیلین جاوااسکریپت ایله اوشلیر. اگر اوپئراتورونوز کؤهنه ایسه یا دا جاوااسکریپت ایستیفاده‌سی مومکون دئییلسه، ایشلمز.",
+ "categorytree-category": "بؤلمه:",
+ "categorytree-go": "یوکله",
+ "categorytree-parents": "اوست بولمه لر",
+ "categorytree-mode-label": "مود:",
+ "categorytree-mode-categories": "ساده‌جه بولمه لری گؤستر",
+ "categorytree-mode-pages": "فایل‌لاردان علاوه صحیفه‌لر",
+ "categorytree-mode-all": "بوتون صفحه‌لر",
+ "categorytree-collapse": "گیزلت",
+ "categorytree-expand": "گئنیشلندیر",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "{{PLURAL:$1|1 آلت بولمه|$1 آلت بولمه}}، {{PLURAL:$2|1 صفحه|$2 صفحه}}، و {{PLURAL:$3|1 فایل|$3 فایل}} واریدیر",
+ "categorytree-num-categories": "$1 ب",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 ف",
+ "categorytree-num-empty": "بوش",
+ "categorytree-load": "یوکله",
+ "categorytree-loading": "یوکلنیر",
+ "categorytree-nothing-found": "تاسوف ائدیریک، نتیجه یوخ‌دور.",
+ "categorytree-no-subcategories": "آلت بولمه لر یوخ‌دور",
+ "categorytree-no-parent-categories": "اوست بولمه یوخ‌دور.",
+ "categorytree-no-pages": "آلت بولمه و مقاله یوخ‌دور.",
+ "categorytree-not-found": "<i>\"$1\"</i آدلی بولمه تاپیلمادی.",
+ "categorytree-error": "معلومات بازاسیندا پروبلئم وار.",
+ "categorytree-retry": "خاهیش ائدیریک بیر آز صبر ائدین و یئنی‌دن ایمتحان ائدین."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ba.json b/www/wiki/extensions/CategoryTree/i18n/ba.json
new file mode 100644
index 00000000..0ae4d871
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ba.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Assele",
+ "Haqmar",
+ "Sagan",
+ "ҒатаУлла",
+ "Янмурза Баки",
+ "Ләйсән"
+ ]
+ },
+ "categorytree": "Категориялар картаһы",
+ "categorytree-portlet": "Категориялар",
+ "categorytree-legend": "Категориялар ағасын күрһәтергә",
+ "categorytree-desc": "[[Special:CategoryTree|Категориялар төҙөлөшө]] буйлап динамик йөрөү мөмкинлеге",
+ "categorytree-header": "Категорияның исемен керетегеҙ, ул ағас төҙөлөшөндә күрһәтеләсәк\n(JavaScript кәрәк буласаҡ).",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Тейәү",
+ "categorytree-parents": "Төп категориялар",
+ "categorytree-mode-label": "Режим",
+ "categorytree-mode-categories": "категориялар ғына",
+ "categorytree-mode-pages": "файлдарҙан башҡа",
+ "categorytree-mode-all": "бар биттәр",
+ "categorytree-collapse": "төрөргә",
+ "categorytree-expand": "асырға",
+ "categorytree-member-counts": "{{PLURAL:$1|$1 эске категорияһы}}, {{PLURAL:$2|$2 бите}} һәм {{PLURAL:$3|$3 файлы}} бар",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Б",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "буш",
+ "categorytree-load": "сығарырға",
+ "categorytree-loading": "сығарыу бара...",
+ "categorytree-nothing-found": "бер ни ҙә табылманы",
+ "categorytree-no-subcategories": "эске категориялар юҡ.",
+ "categorytree-no-parent-categories": "төп категориялар юҡ",
+ "categorytree-no-pages": "мәҡәләләр йәки эске категориялар юҡ.",
+ "categorytree-not-found": "<i>$1</i> категорияһы табылманы.",
+ "categorytree-error": "Мәғлүмәт сығарыуҙа хата бар.",
+ "categorytree-retry": "Зинһар, бер аҙ көткәндән һуң яңынан ҡабатлап ҡарағыҙ.",
+ "apihelp-categorytree-description": "CategoryTree ҡушымтаһы өсөн эске модуль.",
+ "apihelp-categorytree-param-category": "Исемдәр категориялары аралығындағы атама, ҡулланылған осраҡта префикс күрһәтелмәй.",
+ "apihelp-categorytree-param-options": "JSON объектары кеүек CategoryTree төҙөүсе төрҙәре. Тәрәнлек параметры <kbd>1</kbd> итеп куйылған."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bar.json b/www/wiki/extensions/CategoryTree/i18n/bar.json
new file mode 100644
index 00000000..9e62a152
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bar.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Man77",
+ "Mucalexx",
+ "Matthias Klostermayr",
+ "Joe Watzmo"
+ ]
+ },
+ "categorytree": "Kategorienbaam",
+ "categorytree-portlet": "Kategorina",
+ "categorytree-legend": "an Kategorienbaam ozoang",
+ "categorytree-desc": "Dynaamische Navigazion fian [[Special:CategoryTree|Kategorienbaam]]",
+ "categorytree-header": "Zoagt fia de ogebane Kategorie de Untakategorie in ana Baamstruktur.\nDe Seitn braucht bstimmte JavaScript-Funkziona (Ajax) und funkzioniad meglichaweis ned, wen JavaScript ausgschoitn is oder a uaoida Brausa vawendt wead.",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Kategoriebaam ozoang",
+ "categorytree-parents": "Obakategorina",
+ "categorytree-mode-categories": "nua Kategorina",
+ "categorytree-mode-pages": "Seitn aussa Datein",
+ "categorytree-mode-all": "olle Seitn",
+ "categorytree-collapse": "eikloppm",
+ "categorytree-expand": "auskloppm",
+ "categorytree-member-counts": "enthoit {{PLURAL:$1|1 Unterkategorie|$1 Unterkategorina}}, {{PLURAL:$2|1 Seitn|$2 Seitn}} und {{PLURAL:$3|1 Datei|$3 Datein}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "laar",
+ "categorytree-load": "lodn",
+ "categorytree-loading": "lod ...",
+ "categorytree-nothing-found": "Nix gfundn",
+ "categorytree-no-subcategories": "Koa Untakategorie",
+ "categorytree-no-parent-categories": "Koa Obakategorie",
+ "categorytree-no-pages": "Koane Seiten oder Unterkategorien",
+ "categorytree-not-found": "Kategorie „$1“ ned gfunden",
+ "categorytree-error": "Probleem beim Loon voh de Daaten.",
+ "categorytree-retry": "Bittschee wort a Momenterl und vasuachs dånn nuamoi."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bbc-latn.json b/www/wiki/extensions/CategoryTree/i18n/bbc-latn.json
new file mode 100644
index 00000000..82db3625
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bbc-latn.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Stephensuleeman"
+ ]
+ },
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "rumar",
+ "categorytree-load": "mangisi",
+ "categorytree-loading": "mangisi...",
+ "categorytree-nothing-found": "ndang adong jumpang",
+ "categorytree-no-subcategories": "ndang adong subkategori",
+ "categorytree-no-parent-categories": "ndang adong kategori na tumimbo",
+ "categorytree-no-pages": "ndang adong alaman manang subkategori",
+ "categorytree-not-found": "Kategori <i>$1</i> ndang jumpang"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bcc.json b/www/wiki/extensions/CategoryTree/i18n/bcc.json
new file mode 100644
index 00000000..bcdf2472
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bcc.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mostafadaneshvar",
+ "RigiMahnoor",
+ "Baloch Afghanistan"
+ ]
+ },
+ "categorytree": "تهرئی درچک",
+ "categorytree-portlet": "تهرئان",
+ "categorytree-legend": "تهر ئی دراچگی نیمایش",
+ "categorytree-desc": "گجت آن آژاکسی په پیش دارگ [[Special:CategoryTree|شکل دسته]] یک ویکی",
+ "categorytree-header": "یک نام دسته ای وارد کنیت تا شکل درچکی آییء پیش داریت.\nتوجه بیت که شی نیاز په پیشرپتگین عملگری جاوا اسکریپت په داب آژاکس داریت.\nاگر شما را یک کهنه بروزر ای هستن یا جاوا اسکریپ غیر غعال انت آیی کار نه کنت.",
+ "categorytree-category": "تهر:",
+ "categorytree-go": "پیش دار درچکء",
+ "categorytree-parents": "پت و مات آن",
+ "categorytree-mode-label": "حالت:",
+ "categorytree-mode-categories": "فقط دسته جات",
+ "categorytree-mode-pages": "صفحات بجر فایلان",
+ "categorytree-mode-all": "موچین دیمان",
+ "categorytree-collapse": "سقوط",
+ "categorytree-expand": "پچ",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "شامل چه {{PLURAL:$1|یک چیررده|$1 چیررده}}، {{PLURAL:$2|یک تاک|$2 تاک}} ءُ {{PLURAL:$3|یک فایل|$3 فایل انت}}",
+ "categorytree-num-categories": "$1 س",
+ "categorytree-num-pages": "$1 پ",
+ "categorytree-num-files": "$1 ف",
+ "categorytree-num-empty": "هالیگ",
+ "categorytree-load": "لود",
+ "categorytree-loading": "لودبیت...",
+ "categorytree-nothing-found": "هچی در نه بوت",
+ "categorytree-no-subcategories": "هچ زیر دسته ای",
+ "categorytree-no-parent-categories": "دسته جات بی پت و مات",
+ "categorytree-no-pages": "هچ صفحه یا زیر دسته",
+ "categorytree-not-found": "تهر <i>$1</i> ودی نه بوت",
+ "categorytree-error": "مشکل لود دیتا",
+ "categorytree-retry": "یک لحظه ای صبر کنیت و پدا دگه تلاش کن"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bcl.json b/www/wiki/extensions/CategoryTree/i18n/bcl.json
new file mode 100644
index 00000000..2bdd08ad
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bcl.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Filipinayzd",
+ "Geopoet"
+ ]
+ },
+ "categorytree": "Kahoy nin Kategoriya",
+ "categorytree-portlet": "Mga Kategoriya",
+ "categorytree-legend": "Ipatanaw an kahoy nin kategoriya",
+ "categorytree-desc": "Dinamikong dumanan an [[Special:CategoryTree|estruktura nin kategoriya]]",
+ "categorytree-header": "Ikaag an sarong pangaran nin kategoriya tanganing mahiling an kalamnan kaini bilang sarong estruktura nin kahoy. Tandai na ini minahagad nin abantidong JavaScript na punksyonalidad na bisto bilang AJAX. Kun ika igwa nin grabe kagurang na pangilyaw, o pinag-untok an JavaScript, ini dae maandar.",
+ "categorytree-category": "Kategoriya",
+ "categorytree-go": "Ipatanaw an kahoy",
+ "categorytree-parents": "Kamagurangan",
+ "categorytree-mode-label": "Moda:",
+ "categorytree-mode-categories": "mga kategoriya sana",
+ "categorytree-mode-pages": "mga pahina laen lang sa mga sagunson",
+ "categorytree-mode-all": "gabos na mga pahina",
+ "categorytree-collapse": "komyuson",
+ "categorytree-expand": "halawigon",
+ "categorytree-member-counts": "Minalaman nin {{PLURAL:$1|1 subkategoriya|$1 mga subkategoriya}},{{PLURAL:$2|1 pahina|$2 mga pahina}}, asin {{PLURAL:$3|1 sagunson|$3 mga sagunson}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "bokya",
+ "categorytree-load": "ikarga",
+ "categorytree-loading": "pigkakarga",
+ "categorytree-nothing-found": "mayong nanumpungan",
+ "categorytree-no-subcategories": "mayong mga sub-kategorya",
+ "categorytree-no-parent-categories": "mayong ginikanang mga kategoriya",
+ "categorytree-no-pages": "mayong mga pahina o sub-kategorya",
+ "categorytree-not-found": "Kategoriya <i>$1</i> dae nanagboan",
+ "categorytree-error": "Problema sa pagkakarga nin datos.",
+ "categorytree-retry": "Pakihalat ngûna tapos probaran giraray."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/be-tarask.json b/www/wiki/extensions/CategoryTree/i18n/be-tarask.json
new file mode 100644
index 00000000..c86445e4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/be-tarask.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cesco",
+ "EugeneZelenko",
+ "Jim-by",
+ "Red Winged Duck",
+ "Wizardist"
+ ]
+ },
+ "categorytree": "Дрэва катэгорыяў",
+ "categorytree-portlet": "Катэгорыі",
+ "categorytree-legend": "Паказаць дрэва катэгорыяў",
+ "categorytree-desc": "Заснаваная на AJAX прылада для паказу [[Special:CategoryTree|структуры катэгорыяў]] {{GRAMMAR:родны|{{SITENAME}}}}",
+ "categorytree-header": "Увядзіце назву катэгорыі, каб пабачыць яе ў выглядзе дрэва (патрабуе JavaScript).",
+ "categorytree-category": "Катэгорыя:",
+ "categorytree-go": "Паказаць дрэва",
+ "categorytree-parents": "Продкі",
+ "categorytree-mode-label": "Рэжым:",
+ "categorytree-mode-categories": "толькі катэгорыі",
+ "categorytree-mode-pages": "старонкі за выключэньнем файлаў",
+ "categorytree-mode-all": "усе старонкі",
+ "categorytree-collapse": "згарнуць",
+ "categorytree-expand": "разгарнуць",
+ "categorytree-member-counts": "утрымлівае $1 {{PLURAL:$1|падкатэгорыю|падкатэгорыі|падкатэгорыяў}}, $2 {{PLURAL:$2|старонку|старонкі|старонак}} і $3 {{PLURAL:$3|файл|файлы|файлаў}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "пуста",
+ "categorytree-load": "загрузіць",
+ "categorytree-loading": "загрузка…",
+ "categorytree-nothing-found": "нічога ня знойдзена",
+ "categorytree-no-subcategories": "няма падкатэгорыяў",
+ "categorytree-no-parent-categories": "няма бацькаўскіх катэгорыяў",
+ "categorytree-no-pages": "няма старонак ці падкатэгорыяў",
+ "categorytree-not-found": "Катэгорыя <i>$1</i> ня знойдзена",
+ "categorytree-error": "Праблема загрузкі зьвестак.",
+ "categorytree-retry": "Калі ласка, пачакайце і паспрабуйце яшчэ раз.",
+ "apihelp-categorytree-description": "Унутраны модуль для пашырэньня CategoryTree.",
+ "apihelp-categorytree-summary": "Унутраны модуль для пашырэньня структуры катэгорыяў.",
+ "apihelp-categorytree-param-category": "Назва ў прасторы назваў катэгорыяў, прэфікс будзе ігнаравацца ў выпадку, калі будзе пададзены.",
+ "apihelp-categorytree-param-options": "Налады для канструктару CategoryTree як JSON-аб’екту. Парамэтар <var>depth</var> па змоўчаньні роўны <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Варыянты мусяць быць слушнымі JSON-аб’ектамі."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/be.json b/www/wiki/extensions/CategoryTree/i18n/be.json
new file mode 100644
index 00000000..819e2ae9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/be.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Тест",
+ "Чаховіч Уладзіслаў",
+ "Mikalai Udodau",
+ "Mechanizatar"
+ ]
+ },
+ "categorytree": "Дрэва катэгорый",
+ "categorytree-portlet": "Катэгорыі",
+ "categorytree-legend": "Паказаць дрэва катэгорый",
+ "categorytree-desc": "AJAX-кампанент для адлюстравання [[Special:CategoryTree|структуры катэгорый]] вікі",
+ "categorytree-header": "Увядзіце назву катэгорыі, каб пабачыць яе змесціва ў выглядзе дрэва (патрабуе JavaScript).",
+ "categorytree-category": "Катэгорыя:",
+ "categorytree-go": "Загрузіць",
+ "categorytree-parents": "Бацькоўскія катэгорыі",
+ "categorytree-mode-label": "Рэжым:",
+ "categorytree-mode-categories": "толькі катэгорыі",
+ "categorytree-mode-pages": "акрамя файлаў",
+ "categorytree-mode-all": "усе старонкі",
+ "categorytree-collapse": "схаваць",
+ "categorytree-expand": "паказаць",
+ "categorytree-member-counts": "утрымлівае $1 {{PLURAL:$1|падкатэгорыю|падкатэгорыі|падкатэгорый}}, $2 {{PLURAL:$2|старонку|старонкі|старонак}} і $3 {{PLURAL:$3|выяву|выявы|выяў}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 В",
+ "categorytree-num-empty": "пуста",
+ "categorytree-load": "загрузіць",
+ "categorytree-loading": "загрузка…",
+ "categorytree-nothing-found": "Гэта катэгорыя не ўтрымлівае падкатэгорый.",
+ "categorytree-no-subcategories": "няма падкатэгорый",
+ "categorytree-no-parent-categories": "няма бацькоўскіх катэгорый",
+ "categorytree-no-pages": "няма артыкулаў і падкатэгорый",
+ "categorytree-not-found": "Катэгорыя «$1» не знойдзена.",
+ "categorytree-error": "Памылка загрузкі даных.",
+ "categorytree-retry": "Калі ласка, пачакайце і паспрабуйце яшчэ раз.",
+ "apihelp-categorytree-description": "Унутраны модуль пашырэння CategoryTree.",
+ "apihelp-categorytree-param-category": "Назва ў прасторы імёнаў катэгорыяў. Прэфікс, калі будзе пададзены, будзе ігнаравацца.",
+ "apihelp-categorytree-param-options": "Налады для канструктару CategoryTree як JSON-аб’екту. Параметр глыбіні (<var>depth</var>) па змоўчанні роўны <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Опцыі павінны быць дапушчальнымі JSON-аб’ектамі."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bg.json b/www/wiki/extensions/CategoryTree/i18n/bg.json
new file mode 100644
index 00000000..991b2fcd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bg.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Borislav",
+ "DCLXVI",
+ "Spiritia",
+ "Stanqo",
+ "Vodnokon4e",
+ "V111P",
+ "StanProg"
+ ]
+ },
+ "categorytree": "Дърво на категориите",
+ "categorytree-portlet": "Категории",
+ "categorytree-legend": "Показване на дървото с категориите",
+ "categorytree-desc": "Инструмент на AJAX, който показва [[Special:CategoryTree|структурата на категориите]] в уикито",
+ "categorytree-header": "Въведете категория, за да видите съдържанието ѝ в дървовиден вид от категории. (Изисква JavaScript.)",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Показване",
+ "categorytree-parents": "Родителски категории",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "само категории",
+ "categorytree-mode-pages": "страници, без файлове",
+ "categorytree-mode-all": "всички страници",
+ "categorytree-collapse": "свиване",
+ "categorytree-expand": "разгръщане",
+ "categorytree-member-counts": "Съдържа {{PLURAL:$1|една подкатегория|$1 подкатегории}}, {{PLURAL:$2|една страница|$2 страници}} и {{PLURAL:$3|един файл|$3 файла}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Стр",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "празна",
+ "categorytree-load": "зареждане",
+ "categorytree-loading": "зареждане",
+ "categorytree-nothing-found": "няма открити подкатегории",
+ "categorytree-no-subcategories": "няма подкатегории",
+ "categorytree-no-parent-categories": "няма родителски категории",
+ "categorytree-no-pages": "няма страници или подкатегории",
+ "categorytree-not-found": "Категория <i>$1</i> не беше намерена",
+ "categorytree-error": "Възникна проблем при зареждане на данните.",
+ "categorytree-retry": "Изчакайте малко и опитайте отново."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bgn.json b/www/wiki/extensions/CategoryTree/i18n/bgn.json
new file mode 100644
index 00000000..bd31386b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bgn.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Baloch Afghanistan"
+ ]
+ },
+ "categorytree": "تهرئ درخت یا درچگ",
+ "categorytree-portlet": "تهرئان",
+ "categorytree-legend": "تهرئ درخت ئی نشان داتین",
+ "categorytree-desc": "مبتنی وسایل بئ AJAX په [[Special:CategoryTree|تهرهانی جوڑ بوتینگ]] نشان داتین بئ یک ویکی تا",
+ "categorytree-category": "تهر:",
+ "categorytree-go": "درختئ نمایش داتین",
+ "categorytree-parents": "ریشگ",
+ "categorytree-mode-label": "حالت:",
+ "categorytree-mode-categories": "فقط تهرهان",
+ "categorytree-mode-all": "موچین تاکدیمان",
+ "categorytree-expand": "پراخ کورتین",
+ "categorytree-member-counts": "شامل {{PLURAL:$1|یک گۆنڈ تهر|$1 گۆنڈ تهر}}، {{PLURAL:$2|یک دیم|$2 دیم}} و {{PLURAL:$3|یک فایل|$3 فایل اینت}}",
+ "categorytree-num-categories": "$1 ر",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 پ",
+ "categorytree-num-empty": "خالی"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bho.json b/www/wiki/extensions/CategoryTree/i18n/bho.json
new file mode 100644
index 00000000..dfea7d61
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bho.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ganesh",
+ "Nepaboy",
+ "SatyamMishra"
+ ]
+ },
+ "categorytree-portlet": "श्रेणी",
+ "categorytree-expand": "फइलाईं",
+ "categorytree-member-counts": "{{PLURAL:$1|1 उप श्रेणी|$1 उप श्रेणी कुल}}, {{PLURAL:$2|1 पन्ना|$2 पन्ना कुल}}, आ {{PLURAL:$3|1 फाइल|$3 फाइल कुल}} शामिल बाड़ें",
+ "categorytree-num-categories": "$1 श्रे",
+ "categorytree-num-pages": "$1 प",
+ "categorytree-num-files": "$1 फा"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bi.json b/www/wiki/extensions/CategoryTree/i18n/bi.json
new file mode 100644
index 00000000..87bfff53
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bi.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-member-counts": "Contains {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 pej|$2 pejs}}, and {{PLURAL:$3|1 file|$3 files}}"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bjn.json b/www/wiki/extensions/CategoryTree/i18n/bjn.json
new file mode 100644
index 00000000..76d8ca35
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bjn.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "J Subhi",
+ "Riemogerz"
+ ]
+ },
+ "categorytree": "Puhun tumbung",
+ "categorytree-portlet": "Tutumbung",
+ "categorytree-legend": "Tampaiakan tumbung puhun",
+ "categorytree-desc": "Napigasi dinamis [[Special:CategoryTree|struktur tumbung]]",
+ "categorytree-header": "Masukakan sabuah ngaran tumbung gasan malihat isinya di bantuk puhun.\nTulung diitihi bahwa pitur naya mamarluakan dukungan JavaScript lanjutan nang dipinandui sabagai AJAX.\nAmun Pian mamakai panjalajah web lawas, atawa mamatiakan pungsi JavaScript Pian, pitur naya kada kawa dijalanakan.",
+ "categorytree-category": "Tumbung",
+ "categorytree-go": "Tampaiakan puhun",
+ "categorytree-parents": "Kuitan",
+ "categorytree-mode-categories": "Tutumbung haja",
+ "categorytree-mode-pages": "tutungkaran kacuali barakas",
+ "categorytree-mode-all": "samunyaan tutungkaran",
+ "categorytree-collapse": "tutup",
+ "categorytree-expand": "Singkai",
+ "categorytree-member-counts": "baisi {{PLURAL:$1|1 subtumbung|$1 subtumbung}}, {{PLURAL:$2|1 tungkaran|$2 tungkaran}}, dan {{PLURAL:$3|1 barakas|$3 barakas}}",
+ "categorytree-num-categories": "$1 T",
+ "categorytree-num-pages": "$1 T",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "kusung",
+ "categorytree-load": "muatakan",
+ "categorytree-loading": "mamuat...",
+ "categorytree-nothing-found": "Kada taugai",
+ "categorytree-no-subcategories": "kada sub-tutumbung",
+ "categorytree-no-parent-categories": "kada kuitan tutumbung",
+ "categorytree-no-pages": "kadada tutungkaran atawa sub-tutumbung",
+ "categorytree-not-found": "Tumbung <i>$1</i> kada taugai",
+ "categorytree-error": "Masalah mamuat data.",
+ "categorytree-retry": "Muhun hadangi satumat wan cubai pulang."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bn.json b/www/wiki/extensions/CategoryTree/i18n/bn.json
new file mode 100644
index 00000000..4b690416
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bn.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ansumang",
+ "Bellayet",
+ "Nasir8891",
+ "Zaheen",
+ "Aftab1995",
+ "Aftabuzzaman",
+ "আজিজ",
+ "Bodhisattwa"
+ ]
+ },
+ "categorytree": "বিষয়শ্রেণীবৃক্ষ",
+ "categorytree-portlet": "বিষয়শ্রেণী",
+ "categorytree-legend": "বিষয়শ্রেণীগুলো বৃক্ষ আকারে দেখাও",
+ "categorytree-desc": "কোন উইকির [[Special:CategoryTree|বিষয়শ্রেণী কাঠামো]] প্রদর্শনের জন্য এজ্যাক্স-ভিত্তিক গ্যাজেট",
+ "categorytree-header": "যে বিষয়শ্রেণীটির অন্তর্ভুক্ত বিষয়বস্তু বৃক্ষাকারে দেখতে চান, সেটির নাম প্রবেশ করান। (জাভাস্ক্রিপ্ট প্রয়োজন)",
+ "categorytree-category": "বিষয়শ্রেণী:",
+ "categorytree-go": "বৃক্ষ দেখানো হোক",
+ "categorytree-parents": "পিতামাতা",
+ "categorytree-mode-label": "মোড:",
+ "categorytree-mode-categories": "শুধুমাত্র বিষয়শ্রেণী",
+ "categorytree-mode-pages": "ফাইল ব্যতীত পাতাসমূহ",
+ "categorytree-mode-all": "সব পাতা",
+ "categorytree-collapse": "সংকোচন",
+ "categorytree-expand": "প্রসারণ",
+ "categorytree-member-counts": "{{PLURAL:$1|$1টি উপবিষয়শ্রেণী}}, {{PLURAL:$2|$2টি পৃষ্ঠা}}, এবং {{PLURAL:$3|$3টি ফাইল}} রয়েছে",
+ "categorytree-num-categories": "$1টি ব",
+ "categorytree-num-pages": "$1টি প",
+ "categorytree-num-files": "$1টি ফ",
+ "categorytree-num-empty": "খালি",
+ "categorytree-load": "লোড করুন",
+ "categorytree-loading": "লোড হচ্ছে...",
+ "categorytree-nothing-found": "কিছু পাওয়া যায়নি",
+ "categorytree-no-subcategories": "কোন উপ-বিষয়শ্রেণী নেই",
+ "categorytree-no-parent-categories": "কোন মূল বিষয়শ্রেণী নেই",
+ "categorytree-no-pages": "কোন পাতা বা উপ-বিষয়শ্রেণী নেই",
+ "categorytree-not-found": "<i>$1</i> বিষয়শ্রেণীটি পাওয়া যায়নি",
+ "categorytree-error": "উপাত্ত লোডকরণে সমস্যা।",
+ "categorytree-retry": "অনুগ্রহ করে একটু অপেক্ষা করুন ও আবার চেষ্টা করুন।",
+ "apihelp-categorytree-description": "CategoryTree এক্সটেনশনের জন্য আভ্যন্তরীণ মডিউল।",
+ "apihelp-categorytree-summary": "CategoryTree এক্সটেনশনের জন্য আভ্যন্তরীণ মডিউল।",
+ "apihelp-categorytree-param-category": "বিষয়শ্রেণী নামস্থানে শিরোনাম, উপসর্গ উপেক্ষা করা হবে যদি দেয়া হয়।",
+ "apierror-categorytree-invalidjson": "বিকল্প অবশ্যই একটি বৈধ JSON বস্তু হতে হবে।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bo.json b/www/wiki/extensions/CategoryTree/i18n/bo.json
new file mode 100644
index 00000000..c551f6a5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bo.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Freeyak"
+ ]
+ },
+ "categorytree-portlet": "རྣམ་གྲངས།"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bqi.json b/www/wiki/extensions/CategoryTree/i18n/bqi.json
new file mode 100644
index 00000000..4d01bece
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bqi.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bonevarluri",
+ "Mogoeilor"
+ ]
+ },
+ "categorytree-mode-all": "همه بلگه آ",
+ "categorytree-collapse": "جم كردن",
+ "categorytree-expand": "وا كردن",
+ "categorytree-member-counts": "هو د ڤر گرهڌإ {{PLURAL:$1|1 زیردسدأ|$1 زيردسدأ آ}}, {{PLURAL:$2|1 بألگأ|$2 بألگإیل}}, و {{PLURAL:$3|1 جانيا|$3 جانيایل}} إ",
+ "categorytree-num-categories": "$1 س",
+ "categorytree-num-pages": " $1 پ",
+ "categorytree-num-files": " $1 ف"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/br.json b/www/wiki/extensions/CategoryTree/i18n/br.json
new file mode 100644
index 00000000..cf7ed224
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/br.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fohanno",
+ "Fulup"
+ ]
+ },
+ "categorytree": "Gwezennadur ar rummadoù",
+ "categorytree-portlet": "Rummadoù",
+ "categorytree-legend": "Gwelet gwezennadur ar rummad",
+ "categorytree-desc": "Furchal a ra ent dinamek [[Special:CategoryTree|framm ar rummadoù]]",
+ "categorytree-header": "Merkit anv ur rummad evit gwelet petra zo ennañ e stumm ur gwezennadur.\nNotit e rankit kaout an arc'hwelioù JavaScript araokaet anvet AJAX.\nM'eo kozh-mat stumm ho merdeer pe m'eo diweredekaet JavaScript ganeoc'h, ne'z aio ket en-dro.",
+ "categorytree-category": "Rummad :",
+ "categorytree-go": "Diskouez ar gwezennadur",
+ "categorytree-parents": "Usrummadoù",
+ "categorytree-mode-label": "Mod :",
+ "categorytree-mode-categories": "Rummadoù hepken",
+ "categorytree-mode-pages": "pajennoù hep ar skeudennoù",
+ "categorytree-mode-all": "an holl bajennoù",
+ "categorytree-collapse": "Serriñ",
+ "categorytree-expand": "Dispakañ",
+ "categorytree-member-counts": "ennañ {{PLURAL:$1|1 isrummad|$1 isrummad}}, {{PLURAL:$2|1 bajenn|$2 pajenn}}, ha {{PLURAL:$3|1 restr|$3 restr}}",
+ "categorytree-num-categories": "$1 Rum.",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "goullo",
+ "categorytree-load": "kargañ",
+ "categorytree-loading": "o kargañ",
+ "categorytree-nothing-found": "N'eus bet kavet netra",
+ "categorytree-no-subcategories": "isrummad ebet",
+ "categorytree-no-parent-categories": "Rummad kar ebet",
+ "categorytree-no-pages": "Pennad ebet hag isrummad ebet",
+ "categorytree-not-found": "N'eo ket bet kavet ar rummad <i>$1</i>",
+ "categorytree-error": "Ur gudenn zo bet e-ser kargañ ar roadennoù.",
+ "categorytree-retry": "Gortozit un tamm ha klaskit en-dro."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bs.json b/www/wiki/extensions/CategoryTree/i18n/bs.json
new file mode 100644
index 00000000..ed24894a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bs.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "CERminator",
+ "DzWiki",
+ "editors of bs.wikipedia",
+ "Palapa",
+ "KWiki",
+ "Srdjan m"
+ ]
+ },
+ "categorytree": "Stablo kategorija",
+ "categorytree-portlet": "Kategorije",
+ "categorytree-legend": "Prikazuje stablo kategorija",
+ "categorytree-desc": "Dinamičko pregledavanje [[Special:CategoryTree|strukture kategorija]]",
+ "categorytree-header": "Upišite ime kategorije da biste vidjeli njen sadržaj u stablastoj strukturi (zahtijeva JavaScript).",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Prikaži stablo",
+ "categorytree-parents": "Nadkategorije",
+ "categorytree-mode-label": "Režim:",
+ "categorytree-mode-categories": "samo kategorije",
+ "categorytree-mode-pages": "stranice umjesto slika",
+ "categorytree-mode-all": "sve stranice",
+ "categorytree-collapse": "sakrij",
+ "categorytree-expand": "proširi",
+ "categorytree-member-counts": "sadrži {{PLURAL:$1|jednu potkategoriju|$1 potkategorije|$1 potkategorija}}, {{PLURAL:$2|jednu stranicu|$2 stranice|$2 stranica}} i {{PLURAL:$3|jednu datoteku|$3 datoteke|$3 datoteka}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "prazno",
+ "categorytree-load": "učitaj",
+ "categorytree-loading": "učitavam…",
+ "categorytree-nothing-found": "nema potkategorija",
+ "categorytree-no-subcategories": "nema potkategorija",
+ "categorytree-no-parent-categories": "nema nadređene kategorije",
+ "categorytree-no-pages": "nema ni stranica ni potkategorija",
+ "categorytree-not-found": "Kategorija <i>$1</i> nije nađena",
+ "categorytree-error": "Problem pri učitavanju podataka.",
+ "categorytree-retry": "Molimo pričekate trenutak i pokušajte ponovno."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/bto.json b/www/wiki/extensions/CategoryTree/i18n/bto.json
new file mode 100644
index 00000000..1987db28
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/bto.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Filipinayzd"
+ ]
+ },
+ "categorytree-portlet": "Mga kategorya",
+ "categorytree-category": "Kategorya:",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "mga kategorya sana",
+ "categorytree-mode-all": "ngamin na mga pahina",
+ "categorytree-collapse": "Ibaba",
+ "categorytree-expand": "Ibuka",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "uda butang",
+ "categorytree-load": "ikarga",
+ "categorytree-loading": "kinakarga...",
+ "categorytree-nothing-found": "uda naturakan",
+ "categorytree-no-subcategories": "udang mga subkategorya",
+ "categorytree-no-pages": "udang mga pahina o subkategorya",
+ "categorytree-not-found": "Diri naturakang a <i>$1</i>",
+ "categorytree-error": "Agko problema sa pagkarga ka data.",
+ "categorytree-retry": "Paki ulat muna angga prubaran dayday."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ca.json b/www/wiki/extensions/CategoryTree/i18n/ca.json
new file mode 100644
index 00000000..e8827171
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ca.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aleator",
+ "Arnaugir",
+ "Paucabot",
+ "SMP",
+ "Toniher",
+ "Vriullop",
+ "Qllach",
+ "Fitoschido"
+ ]
+ },
+ "categorytree": "Categories en arbre",
+ "categorytree-portlet": "Categories",
+ "categorytree-legend": "Mostra l'arbre de categories",
+ "categorytree-desc": "Navegació dinàmica per l'[[Special:CategoryTree|estructura de categories]]",
+ "categorytree-header": "Entreu el nom d'una categoria per a veure l'arbre del seu contingut. Aquesta pàgina utilitza una funcionalitat avançada del JavaScript coneguda com a AJAX, i no funciona en navegadors antics o que tinguin el JavaScript desactivat.",
+ "categorytree-category": "Categoria:",
+ "categorytree-go": "Mostra l'arbre",
+ "categorytree-parents": "Categories superiors",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "mostra només categories",
+ "categorytree-mode-pages": "mostra categories i pàgines",
+ "categorytree-mode-all": "mostra categories, pàgines i imatges",
+ "categorytree-collapse": "Tancar",
+ "categorytree-expand": "amplia",
+ "categorytree-member-counts": "conté {{PLURAL:$1|1 subcategoria|$1 subcategories}}, {{PLURAL:$2|1 pàgina|$2 pàgines}}, i {{PLURAL:$3|1 fitxer|$3 fitxers}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "buit",
+ "categorytree-load": "Carrega",
+ "categorytree-loading": "s’està carregant…",
+ "categorytree-nothing-found": "no s’ha trobat res",
+ "categorytree-no-subcategories": "no hi ha subcategories.",
+ "categorytree-no-parent-categories": "cap categoria superior",
+ "categorytree-no-pages": "no hi ha articles o subcategories.",
+ "categorytree-not-found": "No s’ha trobat la categoria <i>$1</i>",
+ "categorytree-error": "Problema en la càrrega de dades.",
+ "categorytree-retry": "Torneu-ho a intentar en uns moments."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cbk-zam.json b/www/wiki/extensions/CategoryTree/i18n/cbk-zam.json
new file mode 100644
index 00000000..20771e84
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cbk-zam.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Weekeejames"
+ ]
+ },
+ "categorytree": "El pono de maga categoria",
+ "categorytree-category": "Categoria:",
+ "categorytree-collapse": "esconde",
+ "categorytree-expand": "extende"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cdo.json b/www/wiki/extensions/CategoryTree/i18n/cdo.json
new file mode 100644
index 00000000..3d65a8e2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cdo.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "GnuDoyng",
+ "Yejianfei"
+ ]
+ },
+ "categorytree": "類別樹",
+ "categorytree-header": "Sṳ̆-ĭk lôi-biék miàng-chĭng, káng ĭ gì chéu-hìng giék-gáiu. Chiāng cé̤ṳ-é, ciā hiĕk-miêng sāi-ê̤ṳng siŏh cṳ̄ng gŏ̤-gék JavaScript gé-sŭk, giéu lō̤ AJAX. Nṳ̄ nâ sāi-ê̤ṳng guó-sì gì báuk-lāng-ké, hĕ̤k-ciā cĕk lâi JavaScript, cêu mâ̤ ciáng-siòng gĕ̤ng-cáuk.",
+ "categorytree-category": "分類:",
+ "categorytree-go": "顯示樹",
+ "categorytree-mode-categories": "囇有類別",
+ "categorytree-mode-pages": "無文件其頁面",
+ "categorytree-mode-all": "全部頁面",
+ "categorytree-num-pages": "$1頁",
+ "categorytree-loading": "載入…",
+ "categorytree-no-subcategories": "無子類別",
+ "categorytree-no-pages": "無頁面或者子類別",
+ "categorytree-not-found": "無處討類別<i>$1</i>"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ce.json b/www/wiki/extensions/CategoryTree/i18n/ce.json
new file mode 100644
index 00000000..8823ff97
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ce.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sasan700",
+ "Умар",
+ "Исмаил Садуев"
+ ]
+ },
+ "categorytree": "Категорийн дит",
+ "categorytree-portlet": "Категореш",
+ "categorytree-legend": "Гайта категорийн дит",
+ "categorytree-desc": "AJAX [[Special:CategoryTree|категори дӀахӀоттаран]] компонент ю",
+ "categorytree-header": "Язъе категорин цӀе тӀакха иза гойтур ю диттан кепара.\nХӀара таро ю хьан браузеро AJAX ловш елахь.\nХӀан браузер шира ела елахь я JavaScript дӀаяйина елахь, бухара категореш диттан кепара гойтур яц.",
+ "categorytree-category": "Категори:",
+ "categorytree-go": "Чуяккха",
+ "categorytree-parents": "Кхолламан категореш",
+ "categorytree-mode-label": "РогӀехь:",
+ "categorytree-mode-categories": "екъ категореш",
+ "categorytree-mode-pages": "файлийн совнаха",
+ "categorytree-mode-all": "массо агӀонаш",
+ "categorytree-collapse": "дӀахьарчо",
+ "categorytree-expand": "схьаяста",
+ "categorytree-member-counts": "чохь ю $1 {{PLURAL:$1|1=бухара категори|бухара категореш}}, $2 {{PLURAL:$2|1=агӀо|агӀонаш}} а $3 {{PLURAL:$3|1=файл|файлаш}} а",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 А",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "есса",
+ "categorytree-load": "чуяккха",
+ "categorytree-loading": "чуйолуш…",
+ "categorytree-nothing-found": "ХӀокху категорин чохь бухара категореш яц.",
+ "categorytree-no-subcategories": "бухара категореш яц",
+ "categorytree-no-parent-categories": "доланиг дожаран категореш яц",
+ "categorytree-no-pages": "агӀонаш я бухара категореш яц",
+ "categorytree-not-found": "Категори «$1» ца карийна.",
+ "categorytree-error": "Хаамаш чубахаран гӀалат.",
+ "categorytree-retry": "Дехар до, собар а дийна юха кхин гӀорта."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ceb.json b/www/wiki/extensions/CategoryTree/i18n/ceb.json
new file mode 100644
index 00000000..90f3d69c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ceb.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Abastillas",
+ "Bentong Isles"
+ ]
+ },
+ "categorytree-portlet": "Mga kategoriya",
+ "categorytree-category": "Kategoriya:",
+ "categorytree-expand": "palapda",
+ "categorytree-member-counts": "May {{PLURAL:$1|usa ka subkategorya|$1 ka mga subkategorya}}, {{PLURAL:$2|usa ka panid|$2 ka mga panid}}, ug {{PLURAL:$3|usa ka payl|$3 ka mga payl}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ch.json b/www/wiki/extensions/CategoryTree/i18n/ch.json
new file mode 100644
index 00000000..e76e06fc
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ch.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 L"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ckb.json b/www/wiki/extensions/CategoryTree/i18n/ckb.json
new file mode 100644
index 00000000..2e2765a1
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ckb.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Asoxor",
+ "Calak",
+ "Muhammed taha",
+ "Épine"
+ ]
+ },
+ "categorytree": "درەختی پۆل",
+ "categorytree-portlet": "پۆلەكان",
+ "categorytree-legend": "درەختی پۆل نیشانبدە",
+ "categorytree-header": "ناوی پۆلێک بنووسە بۆ بینینی ناوەرۆک و پێکھاتە درەختییەکەی.\nئاگادار بە کە ئەمە پێویستی بە کارگێڕییەکی پێشکەوتووی JavaScript ھەیە کە بە AJAX ناسراوە.\nئەگەر وێبگەڕێکی زۆر کۆنت ھەیە یان JavaScriptت لەکارخستووە، کار ناکات.",
+ "categorytree-category": "پۆل:",
+ "categorytree-go": "دەرختەکە نیشانبدە",
+ "categorytree-parents": "باوانەکان",
+ "categorytree-mode-categories": "تەنیا پۆلەکان",
+ "categorytree-mode-pages": "لاپەڕەکان جگە لەپەڕەکان",
+ "categorytree-mode-all": "ھەموو پەڕەکان",
+ "categorytree-collapse": "کۆیبکەوە",
+ "categorytree-expand": "بڵاویبکەوە",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "{{PLURAL:$1|یەک ژێرپۆل|$1 ژێرپۆل}}، {{PLURAL:$2|یەک پەڕە|$2 پەڕە}}، and {{PLURAL:$3|یەک پەڕگە|$3 پەڕگە}} لەبەردەگرێتەوە",
+ "categorytree-num-categories": "$1 پۆل",
+ "categorytree-num-pages": "$1 پەڕە",
+ "categorytree-num-files": "$1 پەڕگە",
+ "categorytree-num-empty": "واڵا",
+ "categorytree-load": "باربکە",
+ "categorytree-loading": "بارکردن...",
+ "categorytree-nothing-found": "ھیچ نەدۆزرایەوە",
+ "categorytree-no-subcategories": "ھیچ ژێرھاوپۆلێک نییە",
+ "categorytree-no-parent-categories": "پۆلی باوان نییە",
+ "categorytree-no-pages": "پەڕە و ژێر پۆل نییە",
+ "categorytree-not-found": "پۆلی <i>$1</i> نەدۆزرایەوە",
+ "categorytree-error": "کێشە لە بارکردنی داتا.",
+ "categorytree-retry": "تکایە دەمێک ڕاوەستە و دیسان تاقیبکەوە."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/co.json b/www/wiki/extensions/CategoryTree/i18n/co.json
new file mode 100644
index 00000000..6adb741c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/co.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Paulu"
+ ]
+ },
+ "categorytree-category": "Categuria:",
+ "categorytree-mode-pages": "pagine senza imagin",
+ "categorytree-mode-all": "tutte e pagine",
+ "categorytree-collapse": "cumprime"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cop.json b/www/wiki/extensions/CategoryTree/i18n/cop.json
new file mode 100644
index 00000000..ddb2b9de
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cop.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "ⲁϩⲙⲉⲧ"
+ ]
+ },
+ "categorytree-num-pages": "$1 `ⲛⲥ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/crh-cyrl.json b/www/wiki/extensions/CategoryTree/i18n/crh-cyrl.json
new file mode 100644
index 00000000..b2dac439
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/crh-cyrl.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Don Alessandro",
+ "Danvintius Bookix"
+ ]
+ },
+ "categorytree-mode-all": "саифелернинъ эписи",
+ "categorytree-expand": "кенишлет",
+ "categorytree-member-counts": "Ичинде {{PLURAL:$1|1 алткатегория|$1 алткатегория}}, {{PLURAL:$2|1 саифе|$2 саифе}}, ве {{PLURAL:$3|1 файл|$3 файл}} бар",
+ "categorytree-no-parent-categories": "усть категория ёкъ",
+ "categorytree-error": "Малюмат юкленмеси хатасы."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/crh-latn.json b/www/wiki/extensions/CategoryTree/i18n/crh-latn.json
new file mode 100644
index 00000000..1219590f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/crh-latn.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Don Alessandro"
+ ]
+ },
+ "categorytree-mode-all": "saifelerniñ episi",
+ "categorytree-expand": "kenişlet",
+ "categorytree-member-counts": "İçinde {{PLURAL:$1|1 altkategoriya|$1 altkategoriya}}, {{PLURAL:$2|1 saife|$2 saife}}, ve {{PLURAL:$3|1 fayl|$3 fayl}} bar",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-no-parent-categories": "üst kategoriya yoq",
+ "categorytree-error": "Malümat yüklenmesi hatası."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cs.json b/www/wiki/extensions/CategoryTree/i18n/cs.json
new file mode 100644
index 00000000..056d47bf
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cs.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Danny B.",
+ "Li-sung",
+ "Mormegil",
+ "LordMsz",
+ "Matěj Suchánek"
+ ]
+ },
+ "categorytree": "Strom kategorií",
+ "categorytree-portlet": "Kategorie",
+ "categorytree-legend": "Zobrazí strom kategorie",
+ "categorytree-desc": "Ajaxový nástroj zobrazující [[Special:CategoryTree|stromovou strukturu kategorií]] na této wiki",
+ "categorytree-header": "Zadejte název kategorie pro zobrazení jejího obsahu jako stromové struktury. (Vyžaduje JavaScript.)",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Zobrazit",
+ "categorytree-parents": "Nadřazené kategorie",
+ "categorytree-mode-label": "Režim:",
+ "categorytree-mode-categories": "pouze kategorie",
+ "categorytree-mode-pages": "stránky kromě souborů",
+ "categorytree-mode-all": "všechny stránky",
+ "categorytree-collapse": "zavřít",
+ "categorytree-expand": "rozbalit",
+ "categorytree-member-counts": "obsahuje {{PLURAL:$1|1 podkategorii|$1 podkategorie|$1 podkategorií}}, {{PLURAL:$2|1 stránku|$2 stránky|$2 stránek}} a {{PLURAL:$3|1 soubor|$3 soubory|$3 souborů}}",
+ "categorytree-num-categories": "$1 kat.",
+ "categorytree-num-pages": "$1 str.",
+ "categorytree-num-files": "$1 soub.",
+ "categorytree-num-empty": "prázdná",
+ "categorytree-load": "načíst",
+ "categorytree-loading": "načítá se",
+ "categorytree-nothing-found": "nic nebylo nalezeno",
+ "categorytree-no-subcategories": "žádné podkategorie.",
+ "categorytree-no-parent-categories": "žádné nadřazené kategorie",
+ "categorytree-no-pages": "žádné články ani podkategorie.",
+ "categorytree-not-found": "Kategorie <em>$1</em> nenalezena",
+ "categorytree-error": "Chyba při načítání dat.",
+ "categorytree-retry": "Počkejte chvilku a zkuste to znova.",
+ "apihelp-categorytree-description": "Interní modul pro rozšíření CategoryTree."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/csb.json b/www/wiki/extensions/CategoryTree/i18n/csb.json
new file mode 100644
index 00000000..2d77bc48
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/csb.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kirsan",
+ "Kaszeba"
+ ]
+ },
+ "categorytree": "Drzéwiã kategòrëji",
+ "categorytree-portlet": "Kategòrëje",
+ "categorytree-legend": "Wëskrzëni drzéwiã kategòrëji",
+ "categorytree-desc": "Dinamicznô nawigacëjô dlô [[Special:CategoryTree|strukturë kategòrëji]]",
+ "categorytree-header": "Wpiszë miono kategòrëji, abë òbôczëc ji zamkłosc jakno drzéwiã (nót je JavaScript).",
+ "categorytree-category": "Kategòrëjô:",
+ "categorytree-go": "Wëskrzëni drzéwiã kategòrëji",
+ "categorytree-parents": "Wëższô kategòrëjô",
+ "categorytree-mode-label": "Trib:",
+ "categorytree-mode-categories": "blós kategòrëje",
+ "categorytree-mode-pages": "starnë bez lopków",
+ "categorytree-mode-all": "wszëtczé starnë",
+ "categorytree-collapse": "zwinie",
+ "categorytree-expand": "rozwinie",
+ "categorytree-member-counts": "Zamëkô w se{{PLURAL:$1|1 pòdkategòrëjã|$1 pòdkategòrëje|$1 pòdkategòrëjów}}, {{PLURAL:$2|1 starnã|$2 starnë|$2 starnów}} i {{PLURAL:$3|1 lopk|$3 lopczii|$3 lopków}}",
+ "categorytree-num-categories": "$1 kat.",
+ "categorytree-num-pages": "$1 str.",
+ "categorytree-num-files": "$1 kat.",
+ "categorytree-num-empty": "pùstô",
+ "categorytree-load": "wladëjë",
+ "categorytree-loading": "wladënk...",
+ "categorytree-nothing-found": "nick nie je nalazłé",
+ "categorytree-no-subcategories": "felënk pòdkategòrëjów",
+ "categorytree-no-parent-categories": "felënk wëższi kategòrëji",
+ "categorytree-no-pages": "felënk starnów abò pòdkategòrëjów",
+ "categorytree-not-found": "Kategòrëjô <i>$1</i> nie òsta nalazłô",
+ "categorytree-error": "Problem z wladowaniém pòdôwków.",
+ "categorytree-retry": "Pòżdôj kąsk é spróbùjë znowa.",
+ "apihelp-categorytree-description": "Bënowi mòduł rozszérzeniô \"CategoryTree\"",
+ "apihelp-categorytree-summary": "Bënowi mòduł rozszérzeniô \"CategoryTree\"",
+ "apihelp-categorytree-param-category": "Titel w rumach mionów kategòrëji, prefiks bãdze jignorowóny jeżlë òstónie pòdóny.",
+ "apihelp-categorytree-param-options": "Optacëjô dlô kònstruktora CategoryTree jakno òbjekt JSON. Optacëjô <var>depth</var> domëslno je <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Òptacëje mùszą bëc pòprôwnyma òbjektama JSON."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cu.json b/www/wiki/extensions/CategoryTree/i18n/cu.json
new file mode 100644
index 00000000..e902605a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cu.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "ОйЛ"
+ ]
+ },
+ "categorytree": "катигорїи дрѣво",
+ "categorytree-portlet": "катигорїѩ",
+ "categorytree-category": "катигорїꙗ :",
+ "categorytree-mode-all": "вьсѩ страницѧ",
+ "categorytree-num-categories": "$1 К҃",
+ "categorytree-num-pages": "$1 С҃",
+ "categorytree-num-files": "$1 Д҃"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cv.json b/www/wiki/extensions/CategoryTree/i18n/cv.json
new file mode 100644
index 00000000..da202011
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cv.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chuvash2014",
+ "Chavash"
+ ]
+ },
+ "categorytree-portlet": "Категорисем",
+ "categorytree-category": "Категори:",
+ "categorytree-expand": "сар",
+ "categorytree-member-counts": "$1 айтӗркем, $2 эл тата $3 файл пур",
+ "categorytree-num-categories": "$1 Э",
+ "categorytree-num-pages": "$1 Э",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/cy.json b/www/wiki/extensions/CategoryTree/i18n/cy.json
new file mode 100644
index 00000000..47c02ae9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/cy.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lloffiwr"
+ ]
+ },
+ "categorytree": "Coeden gategori",
+ "categorytree-portlet": "Categorïau",
+ "categorytree-legend": "Dangos y goeden gategori",
+ "categorytree-desc": "Teclyn AJAX yn arddangos [[Special:CategoryTree|adeiledd categorïau]]'r wici",
+ "categorytree-header": "Teipiwch enw categori yn y blwch er mwyn gweld ei gynnwys ar lun coeden.\nSylwer bod yn rhaid defnyddio offer uwch Sgript Java o'r enw AJAX er mwyn gwneud hyn.\nNi lwydda'r gofyniad os yw'ch porwr yn hen iawn neu os nad yw Sgript Java wedi ei alluogi.",
+ "categorytree-category": "Categori:",
+ "categorytree-go": "Dangos y Goeden",
+ "categorytree-parents": "Rhieni",
+ "categorytree-mode-label": "Modd:",
+ "categorytree-mode-categories": "categorïau yn unig",
+ "categorytree-mode-pages": "tudalennau ag eithrio ffeiliau",
+ "categorytree-mode-all": "pob tudalen",
+ "categorytree-collapse": "crebachu",
+ "categorytree-expand": "ehangu",
+ "categorytree-member-counts": "yn cynnwys y canlynol: {{PLURAL:$1|$1 is-gategori}}, $2 {{PLURAL:$2|tudalen|dudalen|dudalen|tudalen|thudalen|tudalen}}, {{PLURAL:$3|$3 ffeil}}",
+ "categorytree-num-categories": "$1 Cat",
+ "categorytree-num-pages": "$1 Tud",
+ "categorytree-num-files": "$1 Ff",
+ "categorytree-num-empty": "gwag",
+ "categorytree-load": "llwytho",
+ "categorytree-loading": "wrthi'n llwytho...",
+ "categorytree-nothing-found": "dim i'w gael",
+ "categorytree-no-subcategories": "dim is-gategorïau",
+ "categorytree-no-parent-categories": "dim uwch-gategorïau",
+ "categorytree-no-pages": "dim tudalennau nag is-gategorïau",
+ "categorytree-not-found": "Heb ddod o hyd i'r categori <i>$1</i>",
+ "categorytree-error": "Cafwyd problem wrth lwytho'r data.",
+ "categorytree-retry": "Arhoswch ennyd, yna ceisiwch eto."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/da.json b/www/wiki/extensions/CategoryTree/i18n/da.json
new file mode 100644
index 00000000..1375b8b9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/da.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Barklund",
+ "Byrial",
+ "Christian List",
+ "Fredelige",
+ "Jon Harald Søby",
+ "Peter Alberti"
+ ]
+ },
+ "categorytree": "Kategoritræ",
+ "categorytree-portlet": "Kategorier",
+ "categorytree-legend": "Vis kategoritræ",
+ "categorytree-desc": "Dynamisk navigation i [[Special:CategoryTree|kategoristrukturen]]",
+ "categorytree-header": "Indtast navnet på en kategori for at se indholdet som et træ. Bemærk at dette kræver avanceret JavaScript-funktionalitet kendt som AJAX, det virker ikke hvis du har en meget gammel browser eller hvis du har slået JavaScript fra.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Vis træ",
+ "categorytree-parents": "Overkategorier",
+ "categorytree-mode-label": "Tilstand:",
+ "categorytree-mode-categories": "kun kategorier",
+ "categorytree-mode-pages": "sider med undtagelse af filer",
+ "categorytree-mode-all": "alle sider",
+ "categorytree-collapse": "fold sammen",
+ "categorytree-expand": "fold ud",
+ "categorytree-member-counts": "indeholder {{PLURAL:$1|én underkategori|$1 underkategorier}}, {{PLURAL:$2|én side|$2 sider}} og {{PLURAL:$3|én fil|$3 filer}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tom",
+ "categorytree-load": "hent",
+ "categorytree-loading": "indlæser",
+ "categorytree-nothing-found": "intet fundet",
+ "categorytree-no-subcategories": "ingen underkategorier",
+ "categorytree-no-parent-categories": "ingen overkategorier",
+ "categorytree-no-pages": "ingen sider eller underkategorier",
+ "categorytree-not-found": "Kategorien ''$1'' blev ikke fundet",
+ "categorytree-error": "Der opstod et problem under indlæsning af data.",
+ "categorytree-retry": "Vent et øjeblik og prøv igen."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/de-ch.json b/www/wiki/extensions/CategoryTree/i18n/de-ch.json
new file mode 100644
index 00000000..ad8e0b88
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/de-ch.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "MichaelFrey"
+ ]
+ },
+ "categorytree-mode-pages": "Seiten ausser Dateien"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/de-formal.json b/www/wiki/extensions/CategoryTree/i18n/de-formal.json
new file mode 100644
index 00000000..4e3169d0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/de-formal.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Raimond Spekking"
+ ]
+ },
+ "categorytree-retry": "Bitte warten Sie einen Moment und versuchen Sie es dann erneut."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/de.json b/www/wiki/extensions/CategoryTree/i18n/de.json
new file mode 100644
index 00000000..af1f470f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/de.json
@@ -0,0 +1,47 @@
+{
+ "@metadata": {
+ "authors": [
+ "Daniel Kinzler, brightbyte.de",
+ "Kghbln",
+ "Metalhead64",
+ "Purodha",
+ "Raimond Spekking",
+ "SVG",
+ "MGChecker",
+ "Umherirrender"
+ ]
+ },
+ "categorytree": "Kategorienbaum",
+ "categorytree-portlet": "Kategorien",
+ "categorytree-legend": "Zeige Kategorienbaum",
+ "categorytree-desc": "Fügt dem Wiki eine [[Special:CategoryTree|Spezialseite]] hinzu, welche die dynamische Navigation durch die Kategorienstruktur ermöglicht",
+ "categorytree-header": "Gib den Namen einer Kategorie ein, um ihre Inhalte als Baumstruktur darzustellen. Erfordert JavaScript.",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Kategorienbaum anzeigen",
+ "categorytree-parents": "Oberkategorien",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "nur Kategorien",
+ "categorytree-mode-pages": "Seiten außer Dateien",
+ "categorytree-mode-all": "alle Seiten",
+ "categorytree-collapse": "einklappen",
+ "categorytree-expand": "ausklappen",
+ "categorytree-member-counts": "enthält {{PLURAL:$1|1 Unterkategorie|$1 Unterkategorien}}, {{PLURAL:$2|1 Seite|$2 Seiten}} und {{PLURAL:$3|1 Datei|$3 Dateien}}",
+ "categorytree-num-categories": "$1&nbsp;K",
+ "categorytree-num-pages": "$1&nbsp;S",
+ "categorytree-num-files": "$1&nbsp;D",
+ "categorytree-num-empty": "leer",
+ "categorytree-load": "laden",
+ "categorytree-loading": "lade …",
+ "categorytree-nothing-found": "Es wurde nichts gefunden.",
+ "categorytree-no-subcategories": "Keine Unterkategorien",
+ "categorytree-no-parent-categories": "Keine Oberkategorien",
+ "categorytree-no-pages": "Keine Seiten oder Unterkategorien",
+ "categorytree-not-found": "Kategorie „$1“ wurde nicht nicht gefunden",
+ "categorytree-error": "Beim Laden der Daten ist ein Problem aufgetreten.",
+ "categorytree-retry": "Bitte warte einen Moment und versuche es dann erneut.",
+ "apihelp-categorytree-description": "Internes Modul für die Erweiterung „CategoryTree“.",
+ "apihelp-categorytree-summary": "Internes Modul für die Erweiterung „CategoryTree“.",
+ "apihelp-categorytree-param-category": "Titel im Kategorie-Namensraum. Das Präfix wird ignoriert, falls angegeben.",
+ "apihelp-categorytree-param-options": "Optionen für den CategoryTree-Konstruktor als JSON-Objekt. Der Standard für die <var>depth</var>-Option ist <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Optionen müssen ein gültiges JSON-Objekt sein."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/din.json b/www/wiki/extensions/CategoryTree/i18n/din.json
new file mode 100644
index 00000000..cad7df5e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/din.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dinkawiki"
+ ]
+ },
+ "categorytree-expand": "cuotyic",
+ "categorytree-member-counts": "Aleŋic {{PLURAL:$1|1 bekätakthookkor|$1 bekätakthuɔkkor}}, {{PLURAL:$2|1 apäm|$2 apääm}}, ku {{PLURAL:$3|1 wëtmät|$3 wëlmät}}$2",
+ "categorytree-num-categories": "$1 At",
+ "categorytree-num-pages": "$1 Ap",
+ "categorytree-num-files": "$1 M"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/diq.json b/www/wiki/extensions/CategoryTree/i18n/diq.json
new file mode 100644
index 00000000..ef220c2c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/diq.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Erdemaslancan",
+ "Marmase",
+ "Mirzali",
+ "Xoser",
+ "Kumkumuk",
+ "1917 Ekim Devrimi",
+ "Gırd"
+ ]
+ },
+ "categorytree": "Dara Kategoriya",
+ "categorytree-portlet": "Kategoriyi",
+ "categorytree-legend": "Dara kategori bımotné",
+ "categorytree-desc": "[[Special:CategoryTree|Babeta kategoriya]] dinamikey sera idare ke",
+ "categorytree-header": "Yew namey kategori bınuse kı zerrekê ey zey vıraştışê dare bıvêne. (Javaskript lazımo)",
+ "categorytree-category": "Kategoriye:",
+ "categorytree-go": "Bar ke",
+ "categorytree-parents": "Kategoriyê serêni",
+ "categorytree-mode-label": "Modê cı:",
+ "categorytree-mode-categories": "tenya kategoriy",
+ "categorytree-mode-pages": "Teyna pelan, dosyayan hesab meke",
+ "categorytree-mode-all": "peley pêro",
+ "categorytree-collapse": "teng kı",
+ "categorytree-expand": "Hera ke",
+ "categorytree-member-counts": "Tede {{PLURAL:$1|1 bınkategoriye|$1 bınkategoriy}}, {{PLURAL:$2|1 pele|$2 peli}} û {{PLURAL:$3|1 dosya|$3 dosyey}} estê",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "'''Venga'''",
+ "categorytree-load": "Bar ke",
+ "categorytree-loading": "bar beno...",
+ "categorytree-nothing-found": "maalesef netice çınyo",
+ "categorytree-no-subcategories": "bınkategoriy çıniyê",
+ "categorytree-no-parent-categories": "ser kategoriye cı çınyo",
+ "categorytree-no-pages": "peli ya zi bınkategoriy çıniyê",
+ "categorytree-not-found": "Kategoriya <i>$1</i> nêvêniye",
+ "categorytree-error": "Barkerdış de malumati dı problem esta.",
+ "categorytree-retry": "Şıma ra reca tenekê pıpawê, bahdo fına bıcerbnê.",
+ "apihelp-categorytree-description": "Derganiya zerre de Module Categorytree.",
+ "apihelp-categorytree-param-category": "Serekê canameya kategori, verole grotış do nê gêriyeno",
+ "apihelp-categorytree-param-options": "İnşaya weçeneganê Categorytree JSON objeyan vıraziya.\nHesıbyaye xoriyeya weçena <kbd>1</kbd> a.",
+ "apierror-categorytree-invalidjson": "Weçenegê objeyê JSON'i ravêreno"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/dsb.json b/www/wiki/extensions/CategoryTree/i18n/dsb.json
new file mode 100644
index 00000000..cd9633cf
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/dsb.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "categorytree": "Bom kategorijow",
+ "categorytree-portlet": "Kategorije",
+ "categorytree-legend": "Kategorijowy bom pokazaś",
+ "categorytree-desc": "Dynamiski pśez [[Special:CategoryTree|kategorijowu strukturu]] nawigěrowaś",
+ "categorytree-header": "Zapódaj mě kategorije, aby jeje wopśimjeśe ako bomowu strukturu wiźeł.\nGlědaj, až se to wěste funkcije JavaScripta pomina, znate ako AJAX.\nJolic maš wjelgin stary browser abo jolic JavaScript jo wótšaltowane, toś ten bok ewentuelnje njefunkcioněrujo.",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Bom pokazaś",
+ "categorytree-parents": "Wuše kategorije",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "jano kategorije",
+ "categorytree-mode-pages": "Boki mimo datajow",
+ "categorytree-mode-all": "wšykne boki",
+ "categorytree-collapse": "złožyś",
+ "categorytree-expand": "rozłožyś",
+ "categorytree-member-counts": "wopśimujo {{PLURAL:$1|1 pódkategoriju|$1 pódkategoriji|$1 pódkategorije|$1 pódkategorijow}}, {{PLURAL:$2|1 bok|$2 boka|$2 boki|$2 bokow}} a {{PLURAL:$3|1 dataju|$3 dataji|$3 dataje|$3 datajow}}",
+ "categorytree-num-categories": "$1 k",
+ "categorytree-num-pages": "$1 b",
+ "categorytree-num-files": "$1 d",
+ "categorytree-num-empty": "prozny",
+ "categorytree-load": "lodowaś",
+ "categorytree-loading": "lodujo se...",
+ "categorytree-nothing-found": "Nic namakany",
+ "categorytree-no-subcategories": "Žedne pódkategorije",
+ "categorytree-no-parent-categories": "žedne wuše kategorije",
+ "categorytree-no-pages": "Žedne boki abo pódkategorije",
+ "categorytree-not-found": "Kategorija <i>$1</i> njenamakana",
+ "categorytree-error": "Problem pśi lodowanju datow.",
+ "categorytree-retry": "Pócakaj pšosym moment a wopytaj hyšći raz."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/dtp.json b/www/wiki/extensions/CategoryTree/i18n/dtp.json
new file mode 100644
index 00000000..d8483239
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/dtp.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "FRANCIS5091"
+ ]
+ },
+ "categorytree-portlet": "Tinanansar",
+ "categorytree-category": "Tinansar",
+ "categorytree-mode-all": "Oinsanan bobolikon",
+ "categorytree-no-subcategories": "Ingaa kawo do kalas"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/dty.json b/www/wiki/extensions/CategoryTree/i18n/dty.json
new file mode 100644
index 00000000..64420454
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/dty.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "रमेश सिंह बोहरा",
+ "Nirajan pant"
+ ]
+ },
+ "categorytree-expand": "फैलौन",
+ "categorytree-member-counts": "मि {{PLURAL:$1|1 श्रेणी छ|$1 श्रेणीहरू छन्}}, {{PLURAL:$2|1 पृष्ठ छ|$2 पृष्ठहरू छन्}}, और {{PLURAL:$3|1 फाइल छ|$3 फाइलहरू छन्}}",
+ "categorytree-num-categories": "$1 C (श्रे)",
+ "categorytree-num-pages": "$1 P (पृ)",
+ "categorytree-num-files": "$1 F (फा)"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ee.json b/www/wiki/extensions/CategoryTree/i18n/ee.json
new file mode 100644
index 00000000..e3ddb9d3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ee.json
@@ -0,0 +1,4 @@
+{
+ "@metadata": [],
+ "categorytree-mode-all": "axawo katã"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/egl.json b/www/wiki/extensions/CategoryTree/i18n/egl.json
new file mode 100644
index 00000000..1562f290
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/egl.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lévi",
+ "Reder"
+ ]
+ },
+ "categorytree-portlet": "Categoréi",
+ "categorytree-category": "Categoréi:",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/el.json b/www/wiki/extensions/CategoryTree/i18n/el.json
new file mode 100644
index 00000000..2c875455
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/el.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "AK",
+ "Badseed",
+ "Consta",
+ "Dead3y3",
+ "Protnet",
+ "ZaDiak",
+ "SucreRouge"
+ ]
+ },
+ "categorytree": "Δέντρο κατηγορίας",
+ "categorytree-portlet": "Κατηγορίες",
+ "categorytree-legend": "Εμφάνιση δέντρου κατηγορίας",
+ "categorytree-desc": "Πλοηγηθείτε δυναμικά στη [[Special:CategoryTree|δομή της κατηγορίας]]",
+ "categorytree-header": "Εισαγάγετε όνομα κατηγορίας για να δείτε τα περιεχόμενά της ως δεντρική δομή.\nΣημειώστε ότι αυτό απαιτεί προηγμένη λειτουργικότητα JavaScript γνωστή ως AJAX.\nΑν έχετε πολύ παλιό περιηγητή, ή αν έχετε απενεργοποιημένο το JavaScript, δεν θα δουλέψει.",
+ "categorytree-category": "Κατηγορία:",
+ "categorytree-go": "Εμφάνιση δέντρου",
+ "categorytree-parents": "Γονείς",
+ "categorytree-mode-label": "Λειτουργία:",
+ "categorytree-mode-categories": "μόνο κατηγορίες",
+ "categorytree-mode-pages": "Σελίδες εξαιρουμένων αρχείων",
+ "categorytree-mode-all": "όλες οι σελίδες",
+ "categorytree-collapse": "σύμπτυξη",
+ "categorytree-expand": "επέκτεινε",
+ "categorytree-member-counts": "Περιέχει {{PLURAL:$1|1 υποκατηγορία|$1 υποκατηγορίες}}, {{PLURAL:$2|1 σελίδα|$2 σελίδες}} και {{PLURAL:$3|1 αρχείο|$3 αρχεία}}",
+ "categorytree-num-categories": "$1 Κ",
+ "categorytree-num-pages": "$1 Σ",
+ "categorytree-num-files": "$1 Α",
+ "categorytree-num-empty": "κενή",
+ "categorytree-load": "φορτώστε",
+ "categorytree-loading": "φόρτωση",
+ "categorytree-nothing-found": "δεν βρέθηκε τίποτα",
+ "categorytree-no-subcategories": "καμία υποκατηγορία",
+ "categorytree-no-parent-categories": "δεν υπάρχουν πατρικές κατηγορίες",
+ "categorytree-no-pages": "καμία σελίδα ή υποκατηγορία",
+ "categorytree-not-found": "Η κατηγορία <i>$1</i> δεν βρέθηκε",
+ "categorytree-error": "Πρόβλημα φόρτωσης δεδομένων.",
+ "categorytree-retry": "Παρακαλούμε περιμένετε μια στιγμή και προσπαθήστε ξανά."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/en-gb.json b/www/wiki/extensions/CategoryTree/i18n/en-gb.json
new file mode 100644
index 00000000..65b79887
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/en-gb.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chase me ladies, I'm the Cavalry",
+ "Dejavu"
+ ]
+ },
+ "categorytree": "Category tree",
+ "categorytree-portlet": "Categories",
+ "categorytree-legend": "Show category tree",
+ "categorytree-desc": "Dynamically navigate the [[Special:CategoryTree|category structure]]",
+ "categorytree-header": "Enter a category name to see its contents as a tree structure. (Requires JavaScript.)",
+ "categorytree-category": "Category:",
+ "categorytree-go": "Show tree",
+ "categorytree-parents": "Parents",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "categories only",
+ "categorytree-mode-pages": "pages except files",
+ "categorytree-mode-all": "all pages",
+ "categorytree-collapse": "collapse",
+ "categorytree-expand": "expand",
+ "categorytree-member-counts": "Contains {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 page|$2 pages}}, and {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "empty",
+ "categorytree-load": "load",
+ "categorytree-loading": "loading…",
+ "categorytree-nothing-found": "nothing found",
+ "categorytree-no-subcategories": "no subcategories",
+ "categorytree-no-parent-categories": "no parent categories",
+ "categorytree-no-pages": "no pages or subcategories",
+ "categorytree-not-found": "Category <i>$1</i> not found",
+ "categorytree-error": "Problem loading data.",
+ "categorytree-retry": "Please wait a moment and try again.",
+ "apihelp-categorytree-description": "Internal module for the CategoryTree extension.",
+ "apihelp-categorytree-param-category": "Title in the category namespace, prefix will be ignored if given.",
+ "apihelp-categorytree-param-options": "Options for the CategoryTree constructor as a JSON object. The <var>depth</var> option defaults to <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Options must be valid a JSON object."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/en.json b/www/wiki/extensions/CategoryTree/i18n/en.json
new file mode 100644
index 00000000..654e1f7f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/en.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Daniel Kinzler, brightbyte.de"
+ ]
+ },
+ "categorytree": "Category tree",
+ "categorytree-portlet": "Categories",
+ "categorytree-legend": "Show category tree",
+ "categorytree-desc": "Dynamically navigate the [[Special:CategoryTree|category structure]]",
+ "categorytree-header": "Enter a category name to see its contents as a tree structure. (Requires JavaScript.)",
+ "categorytree-category": "Category:",
+ "categorytree-go": "Show tree",
+ "categorytree-parents": "Parents",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "categories only",
+ "categorytree-mode-pages": "pages except files",
+ "categorytree-mode-all": "all pages",
+ "categorytree-collapse": "collapse",
+ "categorytree-expand": "expand",
+ "categorytree-collapse-bullet": "▼",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-page-bullet": "&nbsp;",
+ "categorytree-member-counts": "Contains {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 page|$2 pages}}, and {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-member-num": "($5)",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "empty",
+ "categorytree-load": "load",
+ "categorytree-loading": "loading…",
+ "categorytree-nothing-found": "nothing found",
+ "categorytree-no-subcategories": "no subcategories",
+ "categorytree-no-parent-categories": "no parent categories",
+ "categorytree-no-pages": "no pages or subcategories",
+ "categorytree-not-found": "Category <i>$1</i> not found",
+ "categorytree-error": "Problem loading data.",
+ "categorytree-retry": "Please wait a moment and try again.",
+ "apihelp-categorytree-description": "Internal module for the CategoryTree extension.",
+ "apihelp-categorytree-summary": "Internal module for the CategoryTree extension.",
+ "apihelp-categorytree-param-category": "Title in the category namespace, prefix will be ignored if given.",
+ "apihelp-categorytree-param-options": "Options for the CategoryTree constructor as a JSON object. The <var>depth</var> option defaults to <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Options must be valid a JSON object."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/eo.json b/www/wiki/extensions/CategoryTree/i18n/eo.json
new file mode 100644
index 00000000..05a4cc64
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/eo.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "KuboF",
+ "Tlustulimu",
+ "Yekrats"
+ ]
+ },
+ "categorytree": "Kategoriarbo",
+ "categorytree-portlet": "Kategorioj",
+ "categorytree-legend": "Montri kategorian arbon",
+ "categorytree-desc": "AJAX-bazita aldonaĵo por montri la [[Special:CategoryTree|kategorian strukturon]] de vikio",
+ "categorytree-header": "Tajpu kategorinomon por vidi ties enhavon en arboforma strukturo. Notu ke tio postulas progresajn javaskripatajn funkciojn nomitajn AJAX. Se via foliumilo estas tre malnova aŭ se Javaskripto estas malaktivigita, tio ne funkcios.",
+ "categorytree-category": "Kategorio:",
+ "categorytree-go": "Montri arbon",
+ "categorytree-parents": "Patraj kategorioj",
+ "categorytree-mode-label": "Reĝimo:",
+ "categorytree-mode-categories": "nur kategorioj",
+ "categorytree-mode-pages": "paĝoj krom dosieroj",
+ "categorytree-mode-all": "ĉiuj paĝoj",
+ "categorytree-collapse": "kaŝi",
+ "categorytree-expand": "montri",
+ "categorytree-member-counts": "enhavas {{PLURAL:$1|1 subkategorion|$1 subkategoriojn}}, {{PLURAL:$2|1 paĝon|$2 paĝojn}}, kaj {{PLURAL:$3|1 dosieron|$3 dosierojn}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "malplena",
+ "categorytree-load": "elŝuti",
+ "categorytree-loading": "ŝarĝante...",
+ "categorytree-nothing-found": "nenio trovita",
+ "categorytree-no-subcategories": "neniu subkategorio",
+ "categorytree-no-parent-categories": "neniuj superaj kategorioj",
+ "categorytree-no-pages": "neniuj paĝoj aŭ subkategorioj",
+ "categorytree-not-found": "La kategorio <i>$1</i> ne estis trovita.",
+ "categorytree-error": "Problemo ŝarĝante datenojn",
+ "categorytree-retry": "Bonvolu atendi momenton kaj provi denove."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/es.json b/www/wiki/extensions/CategoryTree/i18n/es.json
new file mode 100644
index 00000000..bf2e7d44
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/es.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Locos epraix",
+ "Muro de Aguas",
+ "Ralgis",
+ "Remember the dot",
+ "Sanbec",
+ "Spacebirdy",
+ "Vivaelcelta",
+ "Fitoschido",
+ "Themasterriot",
+ "Macofe",
+ "Dgstranz"
+ ]
+ },
+ "categorytree": "Árbol de categorías",
+ "categorytree-portlet": "Categorías",
+ "categorytree-legend": "Mostrar árbol de categorías",
+ "categorytree-desc": "Navegar dinámicamente por la [[Special:CategoryTree|estructura de categorías]]",
+ "categorytree-header": "Escribe un nombre de categoría para ver su contenido con una estructura de árbol. (Requiere JavaScript.)",
+ "categorytree-category": "Categoría:",
+ "categorytree-go": "Cargar",
+ "categorytree-parents": "Categorías superiores",
+ "categorytree-mode-label": "Modo:",
+ "categorytree-mode-categories": "solo categorías",
+ "categorytree-mode-pages": "páginas excepto imágenes",
+ "categorytree-mode-all": "todas las páginas",
+ "categorytree-collapse": "contraer",
+ "categorytree-expand": "expandir",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "Contiene {{PLURAL:$1|una subcategoría|$1 subcategorías}}, {{PLURAL:$2|una página|$2 páginas}} y {{PLURAL:$3|un archivo|$3 archivos}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vacía",
+ "categorytree-load": "cargar",
+ "categorytree-loading": "cargando…",
+ "categorytree-nothing-found": "no se ha encontrado nada",
+ "categorytree-no-subcategories": "sin subcategorías",
+ "categorytree-no-parent-categories": "no hay categorías superiores",
+ "categorytree-no-pages": "sin páginas ni subcategorías",
+ "categorytree-not-found": "Categoría <i>$1</i> no encontrada",
+ "categorytree-error": "Error al cargar los datos.",
+ "categorytree-retry": "Espera un momento y vuelve a intentarlo.",
+ "apihelp-categorytree-description": "Módulo interno para la extensión CategoryTree.",
+ "apihelp-categorytree-summary": "Módulo interno para la extensión CategoryTree.",
+ "apihelp-categorytree-param-category": "Título en el espacio de nombres Categoría; el prefijo, en caso de indicarse, se ignorará.",
+ "apihelp-categorytree-param-options": "Opciones para el constructor CategoryTree como objeto JSON. La opción <var>depth</var> por defecto toma el valor <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Las opciones deben ser un objeto JSON válido."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/et.json b/www/wiki/extensions/CategoryTree/i18n/et.json
new file mode 100644
index 00000000..259abbf2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/et.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Avjoska",
+ "Jaan513",
+ "Pikne"
+ ]
+ },
+ "categorytree": "Kategooriapuu",
+ "categorytree-portlet": "Kategooriad",
+ "categorytree-legend": "Kategooriapuu näitamine",
+ "categorytree-desc": "[[Special:CategoryTree|Kategooriate ülesehituse]] dünaamiline vaatamine.",
+ "categorytree-header": "Sisesta kategooria nimi, et näha selle sisu puustruktuurina. (Nõuab JavaScripti.)",
+ "categorytree-category": "Kategooria:",
+ "categorytree-go": "Näita puud",
+ "categorytree-parents": "Ülemkategooriad",
+ "categorytree-mode-label": "Moodus:",
+ "categorytree-mode-categories": "ainult kategooriad",
+ "categorytree-mode-pages": "failideta",
+ "categorytree-mode-all": "kõik leheküljed",
+ "categorytree-collapse": "peida",
+ "categorytree-expand": "näita",
+ "categorytree-member-counts": "sisaldab {{PLURAL:$1|üht|$1}} alamkategooriat, {{PLURAL:$2|üht|$2}} lehekülge ja {{PLURAL:$3|üht|$3}} faili",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tühi",
+ "categorytree-load": "laadi",
+ "categorytree-loading": "laadimine...",
+ "categorytree-nothing-found": "ei leitud midagi",
+ "categorytree-no-subcategories": "alamkategooriaid ei ole",
+ "categorytree-no-parent-categories": "ülemkategooriad pole",
+ "categorytree-no-pages": "lehekülgi ega alamkategooriad pole",
+ "categorytree-not-found": "Kategooriat <i>$1</i> ei leitud.",
+ "categorytree-error": "Probleem andmete laadimisel.",
+ "categorytree-retry": "Palun oota hetk ja proovi uuesti."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/eu.json b/www/wiki/extensions/CategoryTree/i18n/eu.json
new file mode 100644
index 00000000..acb0c809
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/eu.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "An13sa",
+ "Theklan"
+ ]
+ },
+ "categorytree": "Kategoria Zuhaitza",
+ "categorytree-portlet": "Kategoriak",
+ "categorytree-legend": "Erakutsi kategoria zuhaitza",
+ "categorytree-desc": "Dinamikoki nabigatu [[Special:CategoryTree|kategoria zuhaitza]]",
+ "categorytree-header": "Idatzi kategoria baten izena bere edukia zuhaitz eran ikusteko. Kontuan izan horrek AJAX bezala ezagutzen diren JavaScript funtzio aurreratuen beharra duela. Nabigatzaile zahar bat erabiltzen baduzu, edo JavaScript ezgaituta badaukazu, ez du funtzionatuko.",
+ "categorytree-category": "Kategoria",
+ "categorytree-go": "Zuhaitza erakutsi",
+ "categorytree-parents": "Gurasoak",
+ "categorytree-mode-label": "Modua:",
+ "categorytree-mode-categories": "kategoriak bakarrik",
+ "categorytree-mode-pages": "orrialdeak, irudiak ezik",
+ "categorytree-mode-all": "orrialde guztiak",
+ "categorytree-collapse": "itxi",
+ "categorytree-expand": "zabaldu",
+ "categorytree-member-counts": "{{PLURAL:$1|azpikategoria 1|$1 azpikategoria}}, {{PLURAL:$2|orrialde 1|$2 orrialde}} eta {{PLURALK:$3|fitxategi 1|$3 fitxategi}} ditu",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 O",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "hutsik",
+ "categorytree-load": "kargatu",
+ "categorytree-loading": "kargatzen",
+ "categorytree-nothing-found": "ez da ezer aurkitu",
+ "categorytree-no-subcategories": "ez dago azpikategoriarik",
+ "categorytree-no-parent-categories": "ez dago kategoria gurasorik",
+ "categorytree-no-pages": "ez dago orrialde edo azpikategoriarik",
+ "categorytree-not-found": "Ez da <i>$1</i> kategoria aurkitu",
+ "categorytree-error": "Arazoa datuak kargatzerakoan.",
+ "categorytree-retry": "Itxaron pixka bat eta saiatu berriz."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ext.json b/www/wiki/extensions/CategoryTree/i18n/ext.json
new file mode 100644
index 00000000..d292c42e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ext.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Better",
+ "Crucifunked"
+ ]
+ },
+ "categorytree": "Arbu e categorias",
+ "categorytree-category": "Categoria:",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-load": "cargal",
+ "categorytree-loading": "cargandu",
+ "categorytree-no-pages": "nu ai ni páhinas ni sucategorias"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fa.json b/www/wiki/extensions/CategoryTree/i18n/fa.json
new file mode 100644
index 00000000..f9b70180
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fa.json
@@ -0,0 +1,48 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ebraminio",
+ "Huji",
+ "Leyth",
+ "Mjbmr",
+ "ZxxZxxZ",
+ "Alirezaaa",
+ "Rtemis"
+ ]
+ },
+ "categorytree": "درخت رده",
+ "categorytree-portlet": "رده‌ها",
+ "categorytree-legend": "نمایش درخت رده",
+ "categorytree-desc": "ناوبری فعال [[Special:CategoryTree|ساختار رده‌ای]]",
+ "categorytree-header": "نام رده‌ای را وارد کنید تا محتویات آن به صورت درختی نمایش یابد. (نیازمندم جاوااسکریپت)",
+ "categorytree-category": "رده:",
+ "categorytree-go": "نمایش درخت",
+ "categorytree-parents": "والدین",
+ "categorytree-mode-label": "حالت:",
+ "categorytree-mode-categories": "فقط رده‌ها",
+ "categorytree-mode-pages": "صفحه‌ها به غیر از پرونده‌ها",
+ "categorytree-mode-all": "تمام صفحه‌ها",
+ "categorytree-collapse": "نهفتن",
+ "categorytree-expand": "گسترش",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "شامل {{PLURAL:$1|یک زیررده|$1 زیررده}}، {{PLURAL:$2|یک صفحه|$2 صفحه}} و {{PLURAL:$3|یک پرونده|$3 پرونده است}}",
+ "categorytree-num-categories": "$1 ر",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 پ",
+ "categorytree-num-empty": "خالی",
+ "categorytree-load": "بارگیری",
+ "categorytree-loading": "در حال بارگیری...",
+ "categorytree-nothing-found": "هیچ‌چیز یافت نشد.",
+ "categorytree-no-subcategories": "هیچ زیررده‌ای ندارد",
+ "categorytree-no-parent-categories": "فاقد ردهٔ بالاتر",
+ "categorytree-no-pages": "هیچ صفحه یا زیررده‌ای ندارد",
+ "categorytree-not-found": "ردهٔ <i>$1</i> یافت نشد",
+ "categorytree-error": "اشکال در دریافت اطلاعات.",
+ "categorytree-retry": "لطفاً کمی صبر کنید و دوباره امتحان کنید.",
+ "apihelp-categorytree-description": "پودمان داخلی برای افزونهٔ درخت رده",
+ "apihelp-categorytree-summary": "پودمان داخلی برای افزونهٔ درخت رده",
+ "apihelp-categorytree-param-category": "عنوان در فضای نام رده، پیشوند اگر ارائه شود نادیده گرفته می‌شود.",
+ "apihelp-categorytree-param-options": "گزینه‌هایی برای سازندهٔ درخت‌رده به صورت یک شیء جی‌سان. گزینهٔ <var>depth</var> به طور پیش‌فرض مقدار <kbd>1</kbd> دارد.",
+ "apierror-categorytree-invalidjson": "گزینه‌ها باید یک شیء جی‌سان معتبر باشد."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fi.json b/www/wiki/extensions/CategoryTree/i18n/fi.json
new file mode 100644
index 00000000..5f062e4d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fi.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Agony",
+ "Crt",
+ "Linnea",
+ "Nedergard",
+ "Nike",
+ "Str4nd",
+ "01miki10",
+ "Pyscowicz"
+ ]
+ },
+ "categorytree": "Luokkapuu",
+ "categorytree-portlet": "Luokat",
+ "categorytree-legend": "Näytä luokkapuu",
+ "categorytree-desc": "AJAX-pohjainen laajennus, joka näyttää wikin [[Special:CategoryTree|luokkapuurakenteen]].",
+ "categorytree-header": "Syötä alle luokka, jonka haluat nähdä puumuodossa. (Vaatii JavaScriptin.)",
+ "categorytree-category": "Luokka",
+ "categorytree-go": "Näytä puu",
+ "categorytree-parents": "Yläluokat",
+ "categorytree-mode-label": "Tila",
+ "categorytree-mode-categories": "vain luokat",
+ "categorytree-mode-pages": "kaikki sivut tiedostoja lukuun ottamatta",
+ "categorytree-mode-all": "kaikki sivut",
+ "categorytree-collapse": "piilota",
+ "categorytree-expand": "näytä",
+ "categorytree-member-counts": "sisältää {{PLURAL:$1|1 alaluokan|$1 alaluokkaa}}, {{PLURAL:$2|1 sivun|$2 sivua}} ja {{PLURAL:$3|1 tiedoston|$3 tiedostoa}}",
+ "categorytree-num-categories": "$1 L",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 T",
+ "categorytree-num-empty": "tyhjä",
+ "categorytree-load": "näytä",
+ "categorytree-loading": "etsitään",
+ "categorytree-nothing-found": "ei alaluokkia",
+ "categorytree-no-subcategories": "ei alaluokkia",
+ "categorytree-no-parent-categories": "ei yläluokkia",
+ "categorytree-no-pages": "ei sivuja eikä alaluokkia",
+ "categorytree-not-found": "Luokkaa <i>$1</i> ei löytynyt",
+ "categorytree-error": "Ongelma tietojen latauksessa.",
+ "categorytree-retry": "Odota hetki ja yritä uudelleen.",
+ "apihelp-categorytree-description": "Sisäinen moduuli CategoryTree-laajennukselle.",
+ "apihelp-categorytree-summary": "Sisäinen moduuli CategoryTree-laajennukselle.",
+ "apihelp-categorytree-param-category": "Otsikko luokkanimiavaruudessa, etuliitettä ei huomioida, jos se on annettu."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fit.json b/www/wiki/extensions/CategoryTree/i18n/fit.json
new file mode 100644
index 00000000..0697c1e5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fit.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mestos"
+ ]
+ },
+ "categorytree": "Luokkapuu",
+ "categorytree-portlet": "Luokat",
+ "categorytree-legend": "Näytä luokkapuu",
+ "categorytree-header": "Syötä alle luokka jonka haluat nähhä puumuoossa. Tämä toiminalisuus vaatii kehittynheen JavaScript-tuen, jota kuttuthaan AJAXiksi. Jos sulla on vanhaa selain, eli JavaScript ei ole päälä, tämä ominaisuus ei toimi",
+ "categorytree-category": "Luokka",
+ "categorytree-go": "Näytä puu",
+ "categorytree-parents": "Yläluokat",
+ "categorytree-mode-categories": "vain luokat",
+ "categorytree-mode-pages": "kaikki sivut kuvia lukhuun ottamatta",
+ "categorytree-mode-all": "kaikki sivut",
+ "categorytree-collapse": "piilota",
+ "categorytree-expand": "näytä",
+ "categorytree-member-counts": "sisältää {{PLURAL:$1|1 alaluokan|$1 alaluokkaa}}, {{PLURAL:$2|1 sivun|$2 sivua}} ja {{PLURAL:$3|1 tieoston|$3 tieostoa}}",
+ "categorytree-load": "näytä",
+ "categorytree-loading": "haethaan",
+ "categorytree-nothing-found": "ei mithään löyetty",
+ "categorytree-no-subcategories": "ei alaluokkia",
+ "categorytree-no-parent-categories": "ei yläluokkia",
+ "categorytree-no-pages": "ei sivuja eikä alaluokkia",
+ "categorytree-not-found": "Luokkaa <i>$1</i> ei löytyny",
+ "categorytree-error": "Prupleemia tieoitten lattaamisessa",
+ "categorytree-retry": "Oota vähän aikaa ja yritä uuesti"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fo.json b/www/wiki/extensions/CategoryTree/i18n/fo.json
new file mode 100644
index 00000000..abb7f28e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fo.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Diupwijk",
+ "EileenSanda",
+ "Spacebirdy"
+ ]
+ },
+ "categorytree": "BólkaTræ",
+ "categorytree-portlet": "Bólkar",
+ "categorytree-legend": "Vís bólka træið",
+ "categorytree-desc": "Dynamisk stýring í [[Special:CategoryTree|bólka strukturinum]]",
+ "categorytree-header": "Skriva heiti á einum bólki fyri at síggja innihaldið sum træ strukturur.\nLegg til merkis, at hetta krevur víðarikomið JacaScript virksemi (funktionalitet), sum er kent sum AJAX.\nUm tú hevur ein sera gamlan kaga (brovsara), ella hevur gjørt JavaScript óvirkið, so fer tað ikki at virka.",
+ "categorytree-category": "Bólkur:",
+ "categorytree-go": "Vís træ",
+ "categorytree-parents": "Foreldur",
+ "categorytree-mode-label": "Støða:",
+ "categorytree-mode-categories": "bert bólkar",
+ "categorytree-mode-pages": "Síður uttan fílur",
+ "categorytree-mode-all": "allar síður",
+ "categorytree-collapse": "samanbrot",
+ "categorytree-expand": "víðka",
+ "categorytree-member-counts": "Inniheldur {{PLURAL:$1|1 undirbólk|$1 undirbólkar}}, {{PLURAL:$2|1 síðu|$2 síður}}, og {{PLURAL:$3|1 fílu|$3 fílur}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tómur",
+ "categorytree-load": "heinta",
+ "categorytree-loading": "lesur inn",
+ "categorytree-nothing-found": "onki funnið",
+ "categorytree-no-subcategories": "ongir undirbólkar",
+ "categorytree-no-parent-categories": "ongir foreldra bólkar",
+ "categorytree-no-pages": "ongar síður ella undirbólkar",
+ "categorytree-not-found": "Bólkur <i>$1</i> ikki funnin",
+ "categorytree-error": "Trupulleikar við at taka niður dáta.",
+ "categorytree-retry": "Vinarliga bíða eitt bil og royn so aftur."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fr.json b/www/wiki/extensions/CategoryTree/i18n/fr.json
new file mode 100644
index 00000000..9fb43dc9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fr.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Darkdadaah",
+ "DavidL",
+ "Gomoko",
+ "Grondin",
+ "IAlex",
+ "Meithal",
+ "Peter17",
+ "Sherbrooke",
+ "Urhixidur",
+ "Verdy p",
+ "Wladek92",
+ "Dgstranz"
+ ]
+ },
+ "categorytree": "Arborescence des catégories",
+ "categorytree-portlet": "Catégories",
+ "categorytree-legend": "Visionner l’arborescence de la catégorie",
+ "categorytree-desc": "Visite dynamiquement la [[Special:CategoryTree|structure des catégories]]",
+ "categorytree-header": "Entrez un nom de catégorie pour voir son contenu en structure arborescente (nécessite JavaScript).",
+ "categorytree-category": "Catégorie :",
+ "categorytree-go": "Voir l’arborescence",
+ "categorytree-parents": "super-catégorie(s)",
+ "categorytree-mode-label": "Mode :",
+ "categorytree-mode-categories": "seulement les catégories",
+ "categorytree-mode-pages": "pages sans les images",
+ "categorytree-mode-all": "toutes les pages",
+ "categorytree-collapse": "Replier",
+ "categorytree-expand": "Développer",
+ "categorytree-member-counts": "contient $1 sous-catégorie{{PLURAL:$1||s}}, $2 page{{PLURAL:$2||s}} et $3 fichier{{PLURAL:$3||s}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vide",
+ "categorytree-load": "charger",
+ "categorytree-loading": "chargement...",
+ "categorytree-nothing-found": "rien trouvé",
+ "categorytree-no-subcategories": "aucune sous-catégorie",
+ "categorytree-no-parent-categories": "aucune catégorie parente",
+ "categorytree-no-pages": "aucune page ou sous-catégorie",
+ "categorytree-not-found": "Catégorie <i>$1</i> introuvable",
+ "categorytree-error": "Problème de chargement des données.",
+ "categorytree-retry": "Veuillez attendre un instant puis réessayer.",
+ "apihelp-categorytree-description": "Module interne pour l’extension CategoryTree.",
+ "apihelp-categorytree-summary": "Module interne pour l’extension CategoryTree.",
+ "apihelp-categorytree-param-category": "Titre dans l’espace de noms des catégories, le préfixe sera ignoré s’il est fourni.",
+ "apihelp-categorytree-param-options": "Options pour le constructeur CategoryTree comme objet JSON. L’option <var>depth</var> par défaut vaut <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Les options doivent être un objet JSON valide."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/frc.json b/www/wiki/extensions/CategoryTree/i18n/frc.json
new file mode 100644
index 00000000..698ad1a1
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/frc.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hangmanwa7id"
+ ]
+ },
+ "categorytree-expand": "Développer",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/frp.json b/www/wiki/extensions/CategoryTree/i18n/frp.json
new file mode 100644
index 00000000..6c3194c8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/frp.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "ChrisPtDe"
+ ]
+ },
+ "categorytree": "Structura d’âbro de les catègories",
+ "categorytree-portlet": "Catègories",
+ "categorytree-legend": "Vêre la structura d’âbro de la catègorie",
+ "categorytree-desc": "Outil basâ dessus AJAX por afichiér la [[Special:CategoryTree|structura de la catègorie]] d’un vouiqui",
+ "categorytree-header": "Buchiéd un nom de catègorie por vêre son contegnu en structura d’âbro.\nCen utilise des fonccionalitâts JavaScript avanciês cognues desot lo nom d’AJAX.\nSe vos avéd un rudo viely navigator ou ben se vos éd pas activâ la fonccionalitât JavaScript, cen fonccionerat pas.",
+ "categorytree-category": "Catègorie :",
+ "categorytree-go": "Fâre vêre la structura d’âbro",
+ "categorytree-parents": "Sur-catègorie(s) ",
+ "categorytree-mode-label": "Fôrma :",
+ "categorytree-mode-categories": "solament les catègories",
+ "categorytree-mode-pages": "pâges sen los fichiérs",
+ "categorytree-mode-all": "totes les pâges",
+ "categorytree-collapse": "recllôre",
+ "categorytree-expand": "dèpleyér",
+ "categorytree-member-counts": "contint $1 sot-catègori{{PLURAL:$1|a|es}}, $2 pâge{{PLURAL:$2||s}} et pués $3 fichiér{{PLURAL:$3||s}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vouedo",
+ "categorytree-load": "Uvrir",
+ "categorytree-loading": "uvèrtura...",
+ "categorytree-nothing-found": "Pas trovâ, dèsolâ.",
+ "categorytree-no-subcategories": "Gins de sot-catègorie.",
+ "categorytree-no-parent-categories": "gins de catègorie parenta",
+ "categorytree-no-pages": "Gins d’articllo ou de sot-catègorie.",
+ "categorytree-not-found": "La catègorie <i>$1</i> at pas étâ trovâ.",
+ "categorytree-error": "Problèmo de chargement de les balyês.",
+ "categorytree-retry": "Atendéd un moment et pués tornâd èprovar."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/frr.json b/www/wiki/extensions/CategoryTree/i18n/frr.json
new file mode 100644
index 00000000..a6621b5a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/frr.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Murma174"
+ ]
+ },
+ "categorytree": "Kategoriibuum",
+ "categorytree-portlet": "Kategoriin",
+ "categorytree-legend": "Kategoriibuum wise",
+ "categorytree-desc": "Diarmä könst dü lachter det [[Special:CategoryTree|kategorii struktuur]] beluke",
+ "categorytree-header": "Wiset onerkategoriin üs en buum. Detdiar sidj brükt JavaScript (Ajax) an werket ferlicht ei mä en ualen browser.",
+ "categorytree-category": "Kategorii:",
+ "categorytree-go": "Kategoriibuum uunwise",
+ "categorytree-parents": "Auerkategoriin",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "bluas kategoriin",
+ "categorytree-mode-pages": "sidjen saner dateien",
+ "categorytree-mode-all": "Aal a sidjen",
+ "categorytree-collapse": "Fersteeg",
+ "categorytree-expand": "Wise",
+ "categorytree-member-counts": "Diar san {{PLURAL:$1|1 onerkategorii|$1 onerkategoriin}}, {{PLURAL:$2|1 sidj|$2 sidjen}} an {{PLURAL:$3|1 datei|$3 datein}} uun.",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "leesag",
+ "categorytree-load": "loose",
+ "categorytree-loading": "loose ...",
+ "categorytree-nothing-found": "Niks fünjen.",
+ "categorytree-no-subcategories": "Nian onerkategoriin",
+ "categorytree-no-parent-categories": "Nian auerkategoriin",
+ "categorytree-no-pages": "Nian sidjen of onerkategoriin",
+ "categorytree-not-found": "Det kategorii „$1“ as ei fünjen wurden.",
+ "categorytree-error": "Bi't loosin faan dooten as wat skiaf gingen.",
+ "categorytree-retry": "Teew en uugenblak an ferschük det do noch ans."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fur.json b/www/wiki/extensions/CategoryTree/i18n/fur.json
new file mode 100644
index 00000000..dde1e080
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fur.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Klenje",
+ "MF-Warburg",
+ "Tocaibon"
+ ]
+ },
+ "categorytree": "Arbul des categoriis",
+ "categorytree-portlet": "Categoriis",
+ "categorytree-legend": "Mostre arbul des categoriis",
+ "categorytree-desc": "Navigazion dinamic te [[Special:CategoryTree|struture des categoriis]]",
+ "categorytree-header": "Inserìs il non de categorie di cui tu vuelis viodi i siei contignûts intune struture a arbul.\nCheste funzion e à bisugne di funzions avanzadis JavaScript, cognossudis come AJAX.\nSe tu âs un sgarfadôr a vonde vieri, o tu âs disativât JavaScript, cheste pagjine no funzionarà.",
+ "categorytree-category": "Categorie:",
+ "categorytree-go": "Mostre arbul",
+ "categorytree-parents": "Categoriis superiôrs",
+ "categorytree-mode-categories": "mostre dome lis categoriis",
+ "categorytree-mode-pages": "dutis lis pagjinis, fûr che i files",
+ "categorytree-mode-all": "dutis lis pagjinis",
+ "categorytree-collapse": "strenç",
+ "categorytree-expand": "slargje",
+ "categorytree-member-counts": "e à dentri {{PLURAL:$1|1 sotcategorie|$1 sotcategoriis}}, {{PLURAL:$2|1 pagjine|$2 pagjinis}} e {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-load": "cjame",
+ "categorytree-loading": "daûr a cjamâ",
+ "categorytree-nothing-found": "nissun risultât",
+ "categorytree-no-subcategories": "nissune sot categorie.",
+ "categorytree-no-parent-categories": "nissune categorie parsore",
+ "categorytree-no-pages": "nissune pagjine ni sotcategorie",
+ "categorytree-not-found": "Categorie <i>$1</i> no cjatade",
+ "categorytree-error": "Probleme dilunc la cjamade dai dâts.",
+ "categorytree-retry": "Spiete un moment e torne a provâ."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/fy.json b/www/wiki/extensions/CategoryTree/i18n/fy.json
new file mode 100644
index 00000000..2f184b5f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/fy.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "SK-luuut",
+ "Snakesteuben",
+ "Robin0van0der0vliet",
+ "Ieneach fan 'e Esk",
+ "Robin van der Vliet"
+ ]
+ },
+ "categorytree": "Kategorybeam",
+ "categorytree-portlet": "Kategoryen",
+ "categorytree-legend": "Lit kategorystambeam sjen",
+ "categorytree-header": "Folje in kategorynamme yn om de ynhâld yn in beamstruktuer te sjen. Tink dêrom dat dit spesjale JavaScript funksjes brûkt bekend as AJAX. At jo in tige âlde blêdzjer hawwe of jo hawwe JavaScript net oan stean, dan wurket dit net.",
+ "categorytree-category": "Kategory:",
+ "categorytree-go": "Los",
+ "categorytree-mode-categories": "allinne kategoryen",
+ "categorytree-mode-pages": "alle siden útsein ôfbylden",
+ "categorytree-mode-all": "alle siden",
+ "categorytree-collapse": "ticht",
+ "categorytree-expand": "iepen",
+ "categorytree-member-counts": "befettet {{PLURAL:$1|1 subkategory|$1 subkategoryen}}, {{PLURAL:$2|1 side|$2 siden}} en {{PLURAL:$3|1 triem|$3 triemmen}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 T",
+ "categorytree-num-empty": "leech",
+ "categorytree-load": "ynlade",
+ "categorytree-loading": "ynlade...",
+ "categorytree-nothing-found": "neat fûn",
+ "categorytree-no-subcategories": "gjin ûnderlizzende kategoryen",
+ "categorytree-no-pages": "gjin siden of ûnderlizzende siden",
+ "categorytree-not-found": "Kategory <i>$1</i> net fûn"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ga.json b/www/wiki/extensions/CategoryTree/i18n/ga.json
new file mode 100644
index 00000000..b7d81f2d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ga.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Alison",
+ "Alma",
+ "Moilleadóir",
+ "Spacebirdy",
+ "Xosé",
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "categorytree": "Crann na gCatagóirí",
+ "categorytree-portlet": "Catagóirí",
+ "categorytree-legend": "Taispeáin crann na gcatagóirí",
+ "categorytree-desc": "Giuirléid AJAX a thaispeánann an [[Special:CategoryTree|struchtúr catagóirí]] i vicí",
+ "categorytree-header": "Cuir isteach ainm catagóra chun a hinneachar a thaispeáint i struchtúr crainn.\nTabhair faoi deara gur riachtanach ardfheidhmiúlacht JavaScript (AJAX) a bheith agat.\nMá tá do bhrabhsálaí róshean, nó má dhíchumasaigh tú JavaScript, ní oibreoidh sé.",
+ "categorytree-category": "Catagóir:",
+ "categorytree-go": "Taispeán an Crann",
+ "categorytree-parents": "Máthairnóid",
+ "categorytree-mode-categories": "catagóirí amháin",
+ "categorytree-mode-pages": "leathanaigh seachas comhaid",
+ "categorytree-mode-all": "gach leathanach",
+ "categorytree-collapse": "dún",
+ "categorytree-expand": "oscail",
+ "categorytree-member-counts": "tá {{PLURAL:$1|fo-chatagóir amháin|$1 fo-chatagóirí}}, {{PLURAL:$2|leathanach amháin|$2 leathanaigh}}, agus {{PLURAL:$3|comhad amháin|$3 comhaid}} laistigh",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-load": "lódáil",
+ "categorytree-loading": "ag lódáil…",
+ "categorytree-nothing-found": "Ní bhfuarthas dada",
+ "categorytree-no-subcategories": "gan fho-chatagóir",
+ "categorytree-no-parent-categories": "níl aon máthairchatagóirí",
+ "categorytree-no-pages": "gan leathanach ná fo-chatagóir",
+ "categorytree-not-found": "Ní bhfuarthas Catagóir <i>$1</i>",
+ "categorytree-error": "Earráid agus sonraí dá lódáil.",
+ "categorytree-retry": "Fan nóiméad, le do thoil, roimh triail eile a bhaint as."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gcf.json b/www/wiki/extensions/CategoryTree/i18n/gcf.json
new file mode 100644
index 00000000..abec688a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gcf.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Laetitia Kb"
+ ]
+ },
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gcr.json b/www/wiki/extensions/CategoryTree/i18n/gcr.json
new file mode 100644
index 00000000..06572e86
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gcr.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "categorytree-expand": "Dévlopé",
+ "categorytree-member-counts": "Ka kontni $1 soukatégori{{PLURAL:$1|}}, $2 paj{{PLURAL:$2|}} é $3 fiché{{PLURAL:$3|}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gd.json b/www/wiki/extensions/CategoryTree/i18n/gd.json
new file mode 100644
index 00000000..19a0f0f3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gd.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Akerbeltz",
+ "GunChleoc"
+ ]
+ },
+ "categorytree": "Craobh nan roinnean-seòrsa",
+ "categorytree-portlet": "Roinnean-seòrsa",
+ "categorytree-legend": "Seall craobh nan roinnean-seòrsa",
+ "categorytree-desc": "Seòl [[Special:CategoryTree|structar nan roinnean-seòrsa]] gu h-innsgineach",
+ "categorytree-header": "Cuir a-steach ainm roinn-seòrsa gus a susbaint a shealltainn 'na chraobh.\nThoir an aire gum bi feum agad air foincsean JavaScript adhartach air a bheil AJAX.\nChan obraich e ma tha brabhsair glè shean agad no ma tha JavaScript à comas.",
+ "categorytree-category": "Roinn-seòrsa:",
+ "categorytree-go": "Seall a' chraobh",
+ "categorytree-parents": "Pàrantan",
+ "categorytree-mode-label": "Modh:",
+ "categorytree-mode-categories": "roinnean-seòrsa a-mhàin",
+ "categorytree-mode-pages": "duilleagan seach faidhlichean",
+ "categorytree-mode-all": "a h-uile duilleag",
+ "categorytree-collapse": "co-theannaich",
+ "categorytree-expand": "leudaich",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "Tha $1 {{PLURAL:$1|fho-roinn-seòrsa|fho-roinn-seòrsa|fo-roinnean-seòrsa|fo-roinn-seòrsa}}, $2 {{PLURAL:$2|duilleag|dhuilleag|duilleagan|duilleag}} 's $3 {{PLURAL:$3|fhaidhle|fhaidhle|faidhlichean|faidhle}} 'na broinn",
+ "categorytree-num-categories": "$1 R-S",
+ "categorytree-num-pages": "$1 D",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "falamh",
+ "categorytree-load": "luchdaich",
+ "categorytree-loading": "'ga luchdadh…",
+ "categorytree-nothing-found": "cha deach càil a lorg",
+ "categorytree-no-subcategories": "gun fho-roinn-seòrsa",
+ "categorytree-no-parent-categories": "gun roinn-seòrsa pàraint",
+ "categorytree-no-pages": "gun duilleag no fho-roinn-seòrsa",
+ "categorytree-not-found": "Cha deach an roinn-seòrsa <i>$1</i> a lorg",
+ "categorytree-error": "Duilgheadas le luchdadh an dàta.",
+ "categorytree-retry": "Fuirich greiseag 's feuch ris a-rithist.",
+ "apihelp-categorytree-description": "Mòideal inntearnail airson leudachan nan craobhan roinnean-seòrsa.",
+ "apihelp-categorytree-param-category": "Tiotal ann an ainm-spàs \"Roinn-seòrsa\", thèid an ro-leasachan a leigeil seachad ma chaidh e a chur ris.",
+ "apihelp-categorytree-param-options": "Roghainnean airson craobh nan roinnean-seòrsa gus oibseact JSON a thogail. Thèid doimhne dhe <kbd>1</kbd> a chleachdadh a ghnàth."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gl.json b/www/wiki/extensions/CategoryTree/i18n/gl.json
new file mode 100644
index 00000000..73aeab67
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gl.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Alma",
+ "Toliño",
+ "Xosé",
+ "Elisardojm",
+ "Navhy"
+ ]
+ },
+ "categorytree": "Árbore de categorías",
+ "categorytree-portlet": "Categorías",
+ "categorytree-legend": "Mostrar a árbore de categorías",
+ "categorytree-desc": "Navegación dinámica a través da [[Special:CategoryTree|estrutura de categorías]]",
+ "categorytree-header": "Introduza o nome dunha categoría para ver o seu contido nunha estrutura de árbore. (Require JavaScript.)",
+ "categorytree-category": "Categoría:",
+ "categorytree-go": "Amosar a árbore",
+ "categorytree-parents": "Categoría raíz",
+ "categorytree-mode-label": "Modo:",
+ "categorytree-mode-categories": "só as categorías",
+ "categorytree-mode-pages": "páxinas agás os ficheiros",
+ "categorytree-mode-all": "todas as páxinas",
+ "categorytree-collapse": "contraer",
+ "categorytree-expand": "expandir",
+ "categorytree-member-counts": "Contén {{PLURAL:$1|unha subcategoría|$1 subcategorías}}, {{PLURAL:$2|unha páxina|$2 páxinas}} e mais {{PLURAL:$3|un ficheiro|$3 ficheiros}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "baleira",
+ "categorytree-load": "cargar",
+ "categorytree-loading": "cargando…",
+ "categorytree-nothing-found": "non se atopou nada",
+ "categorytree-no-subcategories": "non hai subcategorías",
+ "categorytree-no-parent-categories": "non hai categorías superiores a esta",
+ "categorytree-no-pages": "non hai páxinas nin subcategorías",
+ "categorytree-not-found": "Non se atopou a categoría \"<i>$1</i>\"",
+ "categorytree-error": "Problema coa carga de datos.",
+ "categorytree-retry": "Agarde un momento e inténteo de novo.",
+ "apihelp-categorytree-description": "Módulo interno para a extensión CategoryTree.",
+ "apihelp-categorytree-summary": "Módulo interno para a extensión CategoryTree.",
+ "apihelp-categorytree-param-category": "Título no espazo de nomes das categorías; en caso de indicarse, o prefixo será ignorado.",
+ "apihelp-categorytree-param-options": "Opción para o construtor CategoryTree como un obxecto JSON. A opción <var>depth</var> vale <kbd>1</kbd> por defecto.",
+ "apierror-categorytree-invalidjson": "As opcións deben ser un obxecto JSON válido."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/glk.json b/www/wiki/extensions/CategoryTree/i18n/glk.json
new file mode 100644
index 00000000..4ad1d735
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/glk.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "V6rg",
+ "شیخ"
+ ]
+ },
+ "categorytree": "جرگه دار",
+ "categorytree-portlet": "جرگه'ن",
+ "categorytree-legend": "جرگه داره دئن",
+ "categorytree-category": "جرگه:",
+ "categorytree-go": "داره دئن",
+ "categorytree-mode-categories": "فقط جرگه'ن",
+ "categorytree-mode-all": "همته ولگؤن",
+ "categorytree-expand": "واتينادأن",
+ "categorytree-member-counts": "{{PLURAL:$1|ىکته جيرجرگه|$1 جيرجرگه}}، {{PLURAL:$2|ىکته ولگ|$2 ولگ}} ؤ {{PLURAL:$3|ىکته فاىل|$3 فاىل}} اينˇ مئن دره.",
+ "categorytree-num-categories": "$1 ج",
+ "categorytree-num-pages": "$1 و",
+ "categorytree-num-files": "$1 ف",
+ "categorytree-num-empty": "خالي",
+ "categorytree-nothing-found": "هيچي ىاته نۊبؤ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gn.json b/www/wiki/extensions/CategoryTree/i18n/gn.json
new file mode 100644
index 00000000..c0645e85
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gn.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-num-categories": "$1 N",
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gom-deva.json b/www/wiki/extensions/CategoryTree/i18n/gom-deva.json
new file mode 100644
index 00000000..4c07160b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gom-deva.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Darshan kandolkar",
+ "Supriya kankumbikar",
+ "The Discoverer"
+ ]
+ },
+ "categorytree-expand": "विस्तारित कर",
+ "categorytree-member-counts": "{{PLURAL:$1|1 उपवर्ग|$1 उपवर्ग}}, {{PLURAL:$2|1 पान |$2 पानां}}, आनी {{PLURAL:$3|1 फायल |$3 फायली}} उपलब्ध आसात",
+ "categorytree-num-categories": "$1 व",
+ "categorytree-num-pages": "$1 प",
+ "categorytree-num-files": "$1 फ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gom-latn.json b/www/wiki/extensions/CategoryTree/i18n/gom-latn.json
new file mode 100644
index 00000000..17d21d93
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gom-latn.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "The Discoverer"
+ ]
+ },
+ "categorytree-expand": "vistarit kor",
+ "categorytree-member-counts": "Hantunt asat {{PLURAL:$1|1 upvorg|$1 upvorg}}, {{PLURAL:$2|1 pan|$2 panam}}, ani {{PLURAL:$3|1 fail|$3 faili}}",
+ "categorytree-num-categories": "$1 V",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "ritem"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gor.json b/www/wiki/extensions/CategoryTree/i18n/gor.json
new file mode 100644
index 00000000..89fe2129
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gor.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Marwan Mohamad"
+ ]
+ },
+ "categorytree-expand": "po'otanggala",
+ "categorytree-member-counts": "Tuwango {{PLURAL:$1|1 subkategori|$1 subkategori}}. {{PLURAL:$2|1 halaman|$2 halaman}}, wawu {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 H",
+ "categorytree-num-files": "$1 K"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/got.json b/www/wiki/extensions/CategoryTree/i18n/got.json
new file mode 100644
index 00000000..a7ed7b93
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/got.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gothicspeaker"
+ ]
+ },
+ "categorytree-expand": "𐌿𐍆𐌸𐌰𐌽𐌴𐌹",
+ "categorytree-num-categories": "$1 𐌺",
+ "categorytree-num-pages": "$1 𐌻",
+ "categorytree-num-files": "$1 𐍆"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/grc.json b/www/wiki/extensions/CategoryTree/i18n/grc.json
new file mode 100644
index 00000000..d426d4a3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/grc.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeighvsOptimvsMaximvs",
+ "Omnipaedista",
+ "Gts-tg"
+ ]
+ },
+ "categorytree": "Δένδρον κατηγοριῶν",
+ "categorytree-portlet": "Κατηγορίαι",
+ "categorytree-category": "Κατηγορία:",
+ "categorytree-go": "Ἐμφανίζειν δένδρον",
+ "categorytree-parents": "Γονεῖς",
+ "categorytree-mode-categories": "Κατηγορίαι μόνον",
+ "categorytree-mode-all": "πᾶσαι αἱ δέλτοι",
+ "categorytree-collapse": "συστέλλειν",
+ "categorytree-expand": "διαστέλλειν",
+ "categorytree-member-counts": "Περιέχει{{PLURAL:$1|1 ὑποκατηγορία|$1 ὑποκατηγορίαi}}, {{PLURAL:$2|1 δέλτος|$2 δέλτοι}}, καἰ {{PLURAL:$3|1 ἀρχείον|$3 ἀρχεία}}",
+ "categorytree-num-categories": "$1 Κ",
+ "categorytree-num-pages": "$1 Δ",
+ "categorytree-num-files": "$1 Ἀ",
+ "categorytree-load": "φορτίζειν",
+ "categorytree-loading": "φορτίζειν...",
+ "categorytree-nothing-found": "οὐδὲν εὑρεθέν",
+ "categorytree-no-subcategories": "οὐδεμία ὑποκατηγορία",
+ "categorytree-no-parent-categories": "οὐδεμία γονεικὴ κατηγορία",
+ "categorytree-not-found": "Κατηγορία <i>$1</i> μὴ εὑρεθεῖσα",
+ "categorytree-error": "Πρόβλημα τοῦ φορτίζειν δεδομένα"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gsw.json b/www/wiki/extensions/CategoryTree/i18n/gsw.json
new file mode 100644
index 00000000..c3c6056e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gsw.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Als-Chlämens",
+ "Als-Holder",
+ "Hendergassler"
+ ]
+ },
+ "categorytree": "Kategoriebaum",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Kategoriebaum aazeige",
+ "categorytree-desc": "Dynamischi Navigation fir d [[Special:CategoryTree|Kategorie-Struktur]]",
+ "categorytree-header": "Gib e Kategoriname yy zum dr Inhalt vun ere as Baumstruktur aazluege.\nDes brucht fortgschritteneri JavaScript-Funktione (Ajax). Wänn JavaScript abgschalden isch oder e eltere Browser brucht wird, cha s syy, ass es nit goht.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Baum zeige",
+ "categorytree-parents": "Iberkategorie",
+ "categorytree-mode-categories": "Nume d Kategorie",
+ "categorytree-mode-pages": "Syte user Dateie",
+ "categorytree-mode-all": "Alli Syte",
+ "categorytree-collapse": "zueklappe",
+ "categorytree-expand": "ufklappe",
+ "categorytree-member-counts": "het {{PLURAL:$1|1 Unterkategori|$1 Unterkategorie}}, {{PLURAL:$2|1 Syte|$2 Syte}}, un {{PLURAL:$3|1 Datei|$3 Dateie}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "läär",
+ "categorytree-load": "lade",
+ "categorytree-loading": "s isch am Laade ...",
+ "categorytree-nothing-found": "nyt gfunde",
+ "categorytree-no-subcategories": "Kaini Unterkategorie",
+ "categorytree-no-parent-categories": "Kaini Iberkategorie",
+ "categorytree-no-pages": "Kai Syte oder Unterkategorie",
+ "categorytree-not-found": "Kategori <i>$1</i> nit gfunde",
+ "categorytree-error": "Problem bim Lade vo dr Date",
+ "categorytree-retry": "Wart e Rung un versuech s derno non emol."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gu.json b/www/wiki/extensions/CategoryTree/i18n/gu.json
new file mode 100644
index 00000000..bd6b1565
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gu.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ankit",
+ "Ashok modhvadia",
+ "Dsvyas",
+ "KartikMistry",
+ "Arbhatt"
+ ]
+ },
+ "categorytree": "શ્રેણીવૃક્ષ",
+ "categorytree-portlet": "શ્રેણીઓ",
+ "categorytree-legend": "શ્રેણીવૃક્ષ બતાવો",
+ "categorytree-desc": "[[Special:CategoryTree|શ્રેણી રચના]]નું ગતિશીલ સંચાલન",
+ "categorytree-header": "શ્રેણીની વિષયસૂચી ને વૃક્ષસંરચનામાં જોવા માટે શ્રેણીનું નામ દાખલ કરો.\nએ વાતની નોંધ લેશો કે, આ માટે AJAX તરીકે ઓળખાતી સુધરેલી જાવાસ્ક્રિપ્ટ કાર્યક્ષમતા જરૂરી છે.\nજો તમારૂં બ્રાઉઝર અતિ જુનું હશે કે જાવાસ્ક્રિપ્ટ અક્રિય કરેલી હશે તો આ કાર્ય કરશે નહીં.",
+ "categorytree-category": "શ્રેણી:",
+ "categorytree-go": "વૃક્ષ બતાવો",
+ "categorytree-parents": "પિતૃ",
+ "categorytree-mode-label": "સ્થિતિ:",
+ "categorytree-mode-categories": "ફક્ત શ્રેણીઓ",
+ "categorytree-mode-pages": "ફાઇલો સિવાયનાં પાનાઓ",
+ "categorytree-mode-all": "બધા પાનાં",
+ "categorytree-collapse": "સંકેલો",
+ "categorytree-expand": "વિસ્તારો",
+ "categorytree-member-counts": "સમાવિષ્ટ {{PLURAL:$1|૧ ઉપશ્રેણી|$1 ઉપશ્રેણીઓ}}, {{PLURAL:$2|૧ પાનું|$2 પાનાંઓ}}, અને {{PLURAL:$3|૧ ફાઇલ|$3 ફાઇલો}}",
+ "categorytree-num-categories": "$1 શ્રેણી",
+ "categorytree-num-pages": "$1 પાના",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "ખાલી",
+ "categorytree-load": "લાવો",
+ "categorytree-loading": "લાવે છે...",
+ "categorytree-nothing-found": "કંઈ ન મળ્યું",
+ "categorytree-no-subcategories": "ઉપશ્રેણીઓ નથી",
+ "categorytree-no-parent-categories": "પૈતૃકશ્રેણીઓ નથી",
+ "categorytree-no-pages": "પાનાઓ કે ઉપશ્રેણીઓ નથી",
+ "categorytree-not-found": "શ્રેણી <i>$1</i> મળેલ નથી",
+ "categorytree-error": "ડેટા ભારાક્રાંતરણમાં સમસ્યા.",
+ "categorytree-retry": "કૃપયા એક ક્ષણ પ્રતીક્ષા કરી ફરી પ્રયત્ન કરો"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/gv.json b/www/wiki/extensions/CategoryTree/i18n/gv.json
new file mode 100644
index 00000000..0dc2f721
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/gv.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "MacTire02"
+ ]
+ },
+ "categorytree": "BilleyRonnaghyn",
+ "categorytree-portlet": "Ronnaghyn",
+ "categorytree-legend": "Taishbyney billey ronnaghyn",
+ "categorytree-category": "Ronney:",
+ "categorytree-go": "Taishbyney billey",
+ "categorytree-mode-categories": "ronnaghyn ynrican",
+ "categorytree-mode-all": "dagh ooilley ghuillag",
+ "categorytree-collapse": "filley",
+ "categorytree-expand": "mooadaghey",
+ "categorytree-load": "dy lughtaghey",
+ "categorytree-loading": "lughtaghey...",
+ "categorytree-no-subcategories": "gyn fo-ronnaghyn"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ha.json b/www/wiki/extensions/CategoryTree/i18n/ha.json
new file mode 100644
index 00000000..4797fc58
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ha.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "DonCamillo"
+ ]
+ },
+ "categorytree-category": "Rukuni:",
+ "categorytree-expand": "Fadada",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hak.json b/www/wiki/extensions/CategoryTree/i18n/hak.json
new file mode 100644
index 00000000..426d8ca4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hak.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hakka"
+ ]
+ },
+ "categorytree": "Fûn-lui-su",
+ "categorytree-category": "Fûn-lui:",
+ "categorytree-expand": "Chán-khôi",
+ "categorytree-member-counts": "pâu-hàm $1 ke chṳ́ fûn-lui, $2 ke ya̍p-mien lâu $3 ke tóng-on",
+ "categorytree-num-categories": "$1 fûn-lui",
+ "categorytree-num-pages": "$1 Ya̍p-mien",
+ "categorytree-num-files": "$1 Tóng-on"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/haw.json b/www/wiki/extensions/CategoryTree/i18n/haw.json
new file mode 100644
index 00000000..fd2096ef
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/haw.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Singularity"
+ ]
+ },
+ "categorytree-category": "Mahele:",
+ "categorytree-load": "ho‘ouka",
+ "categorytree-loading": "ke ho‘ouka nei…"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/he.json b/www/wiki/extensions/CategoryTree/i18n/he.json
new file mode 100644
index 00000000..bfa12446
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/he.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Rotem Liss",
+ "Guycn2"
+ ]
+ },
+ "categorytree": "עץ קטגוריות",
+ "categorytree-portlet": "קטגוריות",
+ "categorytree-legend": "הצגת עץ קטגוריות",
+ "categorytree-desc": "ניווט דינמי ב[[Special:CategoryTree|מבנה הקטגוריות]]",
+ "categorytree-header": "נא להקליד את שם הקטגוריה כדי לראות את התוכן שלה במבנה עץ. (תכונה זו דורשת JavaScript.)",
+ "categorytree-category": "קטגוריה:",
+ "categorytree-go": "הצגת העץ",
+ "categorytree-parents": "הורים",
+ "categorytree-mode-label": "מצב:",
+ "categorytree-mode-categories": "קטגוריות בלבד",
+ "categorytree-mode-pages": "דפים שאינם קבצים",
+ "categorytree-mode-all": "כל הדפים",
+ "categorytree-collapse": "כיווץ",
+ "categorytree-expand": "הרחבה",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "מכילה {{PLURAL:$1|קטגוריית משנה אחת|$1 קטגוריות משנה}}, {{PLURAL:$2|דף אחד|$2 דפים}}, ו{{PLURAL:$3|קובץ אחד|־$3 קבצים}}",
+ "categorytree-num-categories": "{{PLURAL:$1|קט' אחת|$1 קט'}}",
+ "categorytree-num-pages": "{{PLURAL:$1|דף אחד|$1 דפים}}",
+ "categorytree-num-files": "{{PLURAL:$1|קובץ אחד|$1 קב'}}",
+ "categorytree-num-empty": "ריקה",
+ "categorytree-load": "טעינה",
+ "categorytree-loading": "בטעינה...",
+ "categorytree-nothing-found": "לא נמצא דבר",
+ "categorytree-no-subcategories": "אין קטגוריות־משנה",
+ "categorytree-no-parent-categories": "אין קטגוריות הורה",
+ "categorytree-no-pages": "אין דפים או קטגוריות משנה",
+ "categorytree-not-found": "הקטגוריה <i>$1</i> לא נמצאה",
+ "categorytree-error": "בעיה בטעינת הנתונים.",
+ "categorytree-retry": "נא להמתין מעט ולנסות שוב.",
+ "apihelp-categorytree-description": "מודול פנימי של ההרחבה CategoryTree.",
+ "apihelp-categorytree-summary": "מודול פנימי של ההרחבה CategoryTree.",
+ "apihelp-categorytree-param-category": "כותרת במרחב השם קטגוריה, התחילית לא תשפיע על התוצאה גם אם תינתן.",
+ "apihelp-categorytree-param-options": "אפשרויות לקונסטרוקטור של CategoryTree בתור עצם JSON. ברירת המחדל עבור האפשרות <var>depth</var> היא <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "האופציות צריכות להיות עצם JSON תקין."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hi.json b/www/wiki/extensions/CategoryTree/i18n/hi.json
new file mode 100644
index 00000000..93d851e9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hi.json
@@ -0,0 +1,47 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kannankumar",
+ "Kaustubh",
+ "Pooja.srivastava",
+ "Shyam123.ckp",
+ "Siddhartha Ghai",
+ "Wikiuser13",
+ "Sfic",
+ "Anamdas"
+ ]
+ },
+ "categorytree": "श्रेणीवृक्ष",
+ "categorytree-portlet": "श्रेणियाँ",
+ "categorytree-legend": "श्रेणीवृक्ष दिखायें",
+ "categorytree-desc": "विकि की [[Special:CategoryTree|श्रेणी संरचना]] देखें",
+ "categorytree-header": "किसी श्रेणी की सामग्री वृक्ष के रूप में देखने के लिये उसका नाम दें। (जावास्क्रिप्ट अनिवार्य है)",
+ "categorytree-category": "श्रेणी:",
+ "categorytree-go": "वृक्ष दिखायें",
+ "categorytree-parents": "पालक",
+ "categorytree-mode-label": "मोड:",
+ "categorytree-mode-categories": "सिर्फ़ श्रेणीयाँ",
+ "categorytree-mode-pages": "फ़ाइलों के अतिरिक्त पृष्ठ",
+ "categorytree-mode-all": "सभी पृष्ठ",
+ "categorytree-collapse": "छोटा करें",
+ "categorytree-expand": "विस्तार करें",
+ "categorytree-member-counts": "इसमें {{PLURAL:$1|एक उपश्रेणी|$1 उपश्रेणियाँ}}, {{PLURAL:$2|एक पृष्ठ|$2 पृष्ठ}}, और {{PLURAL:$3|एक फ़ाइल|$3 फ़ाइलें}} हैं।",
+ "categorytree-num-categories": "$1 श्र",
+ "categorytree-num-pages": "$1 पृ",
+ "categorytree-num-files": "$1 फ़ा",
+ "categorytree-num-empty": "खाली",
+ "categorytree-load": "लोड करें",
+ "categorytree-loading": "लोड हो रहा है...",
+ "categorytree-nothing-found": "कुछ भी नहीं मिला",
+ "categorytree-no-subcategories": "उपश्रेणीयाँ नहीं हैं",
+ "categorytree-no-parent-categories": "कोई जनक श्रेणियाँ नहीं हैं",
+ "categorytree-no-pages": "कोई पृष्ठ या उपश्रेणीयाँ नहीं हैं",
+ "categorytree-not-found": "श्रेणी <i>$1</i> नहीं मिली",
+ "categorytree-error": "डाटा लोड करने में समस्या।",
+ "categorytree-retry": "कृपया थोड़े समय पश्चात पुनः यत्न करें।",
+ "apihelp-categorytree-description": "श्रेणीवृक्ष एक्सटेन्सन के लिए अंतर का मॉड्यूल",
+ "apihelp-categorytree-summary": "श्रेणीवृक्ष एक्सटेन्सन के लिए आंतरिक मॉड्यूल",
+ "apihelp-categorytree-param-category": "श्रेणी नामस्थान में उपसर्ग डालने पर उसे नजरअंदाज कर दिया जाएगा।",
+ "apihelp-categorytree-param-options": "<var>गहराई</var> विकल्प मूल रूप से <kbd>1</kbd> है। श्रेणीवृक्ष जेसन के विकल्प के रूप में है।",
+ "apierror-categorytree-invalidjson": "विकल्प मान्य जेसन वस्तु होना चाहिए"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hif-latn.json b/www/wiki/extensions/CategoryTree/i18n/hif-latn.json
new file mode 100644
index 00000000..c2e9c8f4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hif-latn.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Brijlal",
+ "Girmitya",
+ "Thakurji"
+ ]
+ },
+ "categorytree": "Category tree",
+ "categorytree-portlet": "Vibhag",
+ "categorytree-legend": "Category tree ke dekhao",
+ "categorytree-desc": "Dynamically navigate the [[Special:CategoryTree|category structure]]",
+ "categorytree-category": "Vibhag:",
+ "categorytree-go": "Perr dekhao",
+ "categorytree-parents": "\nParents",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "Khaali category",
+ "categorytree-mode-pages": "file ke chhorr ke panna",
+ "categorytree-mode-all": "Sab panna",
+ "categorytree-collapse": "Chhota karo",
+ "categorytree-expand": "Barraa karo",
+ "categorytree-member-counts": "Isme {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 panna|$2 panna}}, and {{PLURAL:$3|1 file|$3 files}} hae.",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "khaali",
+ "categorytree-load": "load karo",
+ "categorytree-loading": "load hoe hae ...",
+ "categorytree-nothing-found": "kuchh bhi nai mila",
+ "categorytree-no-subcategories": "subcategory nai hae",
+ "categorytree-no-parent-categories": "koi parent category nai hae",
+ "categorytree-no-pages": "koi panna nai to subcategory nai hae",
+ "categorytree-not-found": "Category <i>$1</i> ke nai pawa gais hae",
+ "categorytree-error": "Data load kare me problem hae.",
+ "categorytree-retry": "Meharbani kar ke kuchh deri wait kar ke fir se try karo."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hoc.json b/www/wiki/extensions/CategoryTree/i18n/hoc.json
new file mode 100644
index 00000000..ea47b1db
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hoc.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Singkiring57"
+ ]
+ },
+ "categorytree-expand": "𑣉𑣞𑣁𑣜𑣈",
+ "categorytree-num-pages": "$1 𑢾"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hr.json b/www/wiki/extensions/CategoryTree/i18n/hr.json
new file mode 100644
index 00000000..6a7d7f7e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hr.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dalibor Bosits",
+ "Ex13",
+ "SpeedyGonsales",
+ "MaGa",
+ "Srdjan m",
+ "Bugoslav"
+ ]
+ },
+ "categorytree": "Stablasti prikaz hijerarhije kategorija",
+ "categorytree-portlet": "Kategorije",
+ "categorytree-legend": "Prikaži stablo kategorija",
+ "categorytree-desc": "Dinamička navigacija kroz [[Special:CategoryTree|strukturu kategorija]]",
+ "categorytree-header": "Upišite ime kategorije da biste vidjeli njen sadržaj u stablastom prikazu hijerarhije. (Zahtijeva JavaScript.)",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Pokaži stablo",
+ "categorytree-parents": "Više kategorije",
+ "categorytree-mode-label": "Način:",
+ "categorytree-mode-categories": "pokaži samo kategorije",
+ "categorytree-mode-pages": "stranice bez datoteka",
+ "categorytree-mode-all": "sve stranice",
+ "categorytree-collapse": "sklopi",
+ "categorytree-expand": "raširi",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "sadrži {{PLURAL:$1|1 potkategoriju|$1 potkategorije|$1 potkategorija}}, {{PLURAL:$2|1 stranicu|$2 stranice|$2 stranica}} i {{PLURAL:$3|1 datoteku|$3 datoteke|$3 datoteka}}",
+ "categorytree-num-categories": "$1 kat.",
+ "categorytree-num-pages": "$1 str.",
+ "categorytree-num-files": "$1 dat.",
+ "categorytree-num-empty": "prazna",
+ "categorytree-load": "učitaj",
+ "categorytree-loading": "učitavam...",
+ "categorytree-nothing-found": "nije pronađena ijedna stavka",
+ "categorytree-no-subcategories": "nema potkategorija",
+ "categorytree-no-parent-categories": "nema viših kategorija",
+ "categorytree-no-pages": "Nema članaka ili podkategorija.",
+ "categorytree-not-found": "Kategorija <i>$1</i> nije pronađena",
+ "categorytree-error": "Problem s učitavanjem podataka.",
+ "categorytree-retry": "Pričekajte trenutak pa pokušajte opet.",
+ "apihelp-categorytree-description": "Interni modul za proširenje CategoryTree.",
+ "apihelp-categorytree-summary": "Interni modul za proširenje CategoryTree.",
+ "apihelp-categorytree-param-category": "Naziv u imenskom prostoru kategorija. Ako je prefiks naveden, bit će zanemaren."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hrx.json b/www/wiki/extensions/CategoryTree/i18n/hrx.json
new file mode 100644
index 00000000..4a9d4265
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hrx.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Midnight Gambler"
+ ]
+ },
+ "categorytree-expand": "ausklappe",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hsb.json b/www/wiki/extensions/CategoryTree/i18n/hsb.json
new file mode 100644
index 00000000..d75ef11c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hsb.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki",
+ "J budissin"
+ ]
+ },
+ "categorytree": "Kategorijowy štom",
+ "categorytree-portlet": "Kategorije",
+ "categorytree-legend": "Kategorijowy štom pokazać",
+ "categorytree-desc": "Přisłušk (gadget) na zakładźe AJAX za [[Special:CategoryTree|zwobraznjenje struktury]] wikija",
+ "categorytree-header": "Zapisaj mjeno kategorije, zo by jeje wobsah jako štomowu strukturu widźał. Wobkedźbuj, zo su za to wěste JavaScriptowe funkcije (AJAX) trjeba. Jeli maš jara stary wobhladowak abo jeli JavaScript je wupinjeny, to snano njebudźe fungować.",
+ "categorytree-category": "Kategorija",
+ "categorytree-go": "Štom pokazać",
+ "categorytree-parents": "Nadkategorije",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "jenož kategorije",
+ "categorytree-mode-pages": "strony nimo wobrazow",
+ "categorytree-mode-all": "wšě strony",
+ "categorytree-collapse": "schować",
+ "categorytree-expand": "pokazać",
+ "categorytree-member-counts": "wobsahuje {{PLURAL:$1|1 podkategoriju|$1 podkategoriji|$1 podkategorije|$1 podkategorijow}}, {{PLURAL:$2|1 stronu|$2 stronje|$2 strony|$2 stronow}} a {{PLURAL:$3|1 dataju|$3 dataji|$3 dataje|$3 datajow}}",
+ "categorytree-num-categories": "$1 k",
+ "categorytree-num-pages": "$1 s",
+ "categorytree-num-files": "$1 d",
+ "categorytree-num-empty": "prózdna",
+ "categorytree-load": "začitać",
+ "categorytree-loading": "čita so…",
+ "categorytree-nothing-found": "ničo namakane",
+ "categorytree-no-subcategories": "žane podkategorije",
+ "categorytree-no-parent-categories": "žane nadrjadowane kategorije",
+ "categorytree-no-pages": "žane strony abo podkategorije",
+ "categorytree-not-found": "Kategorija ''$1'' njenamakana",
+ "categorytree-error": "Problem při čitanju datow.",
+ "categorytree-retry": "Prošu čakaj wokomik a spytaj potom hišće raz."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ht.json b/www/wiki/extensions/CategoryTree/i18n/ht.json
new file mode 100644
index 00000000..35012672
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ht.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Boukman",
+ "Masterches",
+ "Tisave",
+ "Bfpage"
+ ]
+ },
+ "categorytree": "Òganizasyon kategori yo",
+ "categorytree-legend": "Montre òganizasyon pou kategori a",
+ "categorytree-desc": "Gade [[Special:CategoryTree|òganizasyon kategori]] toutpandan l ap chanje.",
+ "categorytree-header": "Antre non yon kategori pou wè sa li genyen anndan li sou plizyè nivo.\nNote byen ke sa mande fonksyon avanse JavaScript ki rele AJAX.\nSi ou genyen yon ansyen navigatè entènèt, oubyen JavaScript pa aktive, li pap mache.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Montre òganizasyon sou plizyè nivo",
+ "categorytree-parents": "kategori ki gen pi wo nivo",
+ "categorytree-mode-categories": "Kategori yo sèlman",
+ "categorytree-mode-pages": "paj yo (pa gen imaj yo)",
+ "categorytree-mode-all": "tout paj yo",
+ "categorytree-collapse": "redui",
+ "categorytree-expand": "etann",
+ "categorytree-member-counts": "Gen {{PLURAL:$1|1 subcategory|$1 subcategories}},{{PLURAL:$2|1 page|$2 pages}},ak {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-load": "Chaje",
+ "categorytree-loading": "ap chaje...",
+ "categorytree-nothing-found": "nou pa jwenn anyen",
+ "categorytree-no-subcategories": "kategori sa pa gen pitit, pa gen kategori pi ba.",
+ "categorytree-no-pages": "pa gen paj oubyen kategori ki pi ba",
+ "categorytree-not-found": "Nou pa twouve kategori <i>$1</i>",
+ "categorytree-error": "Pwoblèm lè nou tap chaje, ouvri done yo.",
+ "categorytree-retry": "Tanpri, tann yon moman epi eseye ankò."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hu-formal.json b/www/wiki/extensions/CategoryTree/i18n/hu-formal.json
new file mode 100644
index 00000000..ca58da76
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hu-formal.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dani"
+ ]
+ },
+ "categorytree-retry": "Várjon egy kicsit, majd próbálja újra!"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hu.json b/www/wiki/extensions/CategoryTree/i18n/hu.json
new file mode 100644
index 00000000..2b6958e1
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hu.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dani",
+ "Dj",
+ "Glanthor Reviol",
+ "KossuthRad",
+ "Tacsipacsi"
+ ]
+ },
+ "categorytree": "Kategóriafa",
+ "categorytree-portlet": "Kategóriák",
+ "categorytree-legend": "Mutatsd faként",
+ "categorytree-desc": "AJAX alapú eszköz a wiki [[Special:CategoryTree|kategória-struktúrájának]] megjelenítéséhez",
+ "categorytree-header": "Add meg annak a kategóriának a nevét, amelynek meg szeretnéd tekinteni\na fastruktúráját. (JavaSript szükséges hozzá.)",
+ "categorytree-category": "Kategória:",
+ "categorytree-go": "Mehet",
+ "categorytree-parents": "Szülőkategóriák",
+ "categorytree-mode-label": "Mód:",
+ "categorytree-mode-categories": "csak kategóriák",
+ "categorytree-mode-pages": "lapok fájlok nélkül",
+ "categorytree-mode-all": "az összes oldal",
+ "categorytree-collapse": "becsuk",
+ "categorytree-expand": "kinyit",
+ "categorytree-member-counts": "$1 alkategóriát, $2 lapot és $3 fájlt tartalmaz",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "üres",
+ "categorytree-load": "betöltés",
+ "categorytree-loading": "betöltés…",
+ "categorytree-nothing-found": "nincs találat",
+ "categorytree-no-subcategories": "nincsenek alkategóriák",
+ "categorytree-no-parent-categories": "nincsenek szülőkategóriái",
+ "categorytree-no-pages": "nincsenek lapok és alkategóriák",
+ "categorytree-not-found": "A következő kategória nem található: <i>$1</i>",
+ "categorytree-error": "Hiba történt az adatok betöltése közben.",
+ "categorytree-retry": "Várj egy kicsit, majd próbáld újra!",
+ "apihelp-categorytree-description": "A CategoryTree kiterjesztés belső modulja.",
+ "apihelp-categorytree-summary": "A CategoryTree kiterjesztés belső modulja.",
+ "apihelp-categorytree-param-category": "Cím a kategórianévtérben, az előtag figyelmen kívül lesz hagyva, ha meg van adva.",
+ "apihelp-categorytree-param-options": "Opciók a CategoryTree konstruktora számára JSON-objektumként. A <var>depth</var> opció alapértelmezett értéke <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Az opcióknak érvényes JSON-objektumnak kell lenniük."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hy.json b/www/wiki/extensions/CategoryTree/i18n/hy.json
new file mode 100644
index 00000000..6419aebb
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hy.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chaojoker",
+ "Teak",
+ "Xelgen",
+ "Աշոտ1997"
+ ]
+ },
+ "categorytree": "Կատեգորիաների ծառ",
+ "categorytree-portlet": "Կատեգորիաներ",
+ "categorytree-legend": "Ցույց տալ կատեգորիաների ծառը",
+ "categorytree-desc": "[[Special:CategoryTree|Կատեգորիայի կառուցվծքի]] դինամիկ արտապատկերում",
+ "categorytree-header": "Մուտքագրեք կատեգորիայի անունը՝ ծառի համակարգը տեսնելու համար։\nԻ նկատի ունեցեք, որ սա հնարավոր է միայն ձեր զննարկիչի կողմից AJAX-ի ֆունկցիանալության դեպքում։\nԵթե դուք աշխատում եք շատ հին զննարկիչով, կամ ձեր JavaScript-ը անջատված է՝ այն չի գործի։",
+ "categorytree-category": "Կատեգորիա:",
+ "categorytree-go": "Ցույց տալ ծառը",
+ "categorytree-parents": "Ծնող-կատեգորիաներ",
+ "categorytree-mode-categories": "միայն կատեգորիաները",
+ "categorytree-mode-pages": "նիշքերից բացի",
+ "categorytree-mode-all": "բոլոր էջերը",
+ "categorytree-collapse": "փակել",
+ "categorytree-expand": "բացել",
+ "categorytree-member-counts": "պարունակում է {{PLURAL:$1|1 ենթակատեգորիա|$1 ենթակատեգորիա}}, {{PLURAL:$2|1 էջ|$2 էջ}} և {{PLURAL:$3|1 նիշք|$3 նիշք}}",
+ "categorytree-num-categories": "$1 Կ",
+ "categorytree-num-pages": "$1 Է",
+ "categorytree-num-files": "$1 Ն",
+ "categorytree-num-empty": "դատարկ",
+ "categorytree-load": "բեռնել",
+ "categorytree-loading": "բեռնվում է",
+ "categorytree-nothing-found": "ոչինչ չի գտնվել",
+ "categorytree-no-subcategories": "ենթակատեգորիաներ չկան",
+ "categorytree-no-parent-categories": "ծնող-կատեգորիաներ չկան",
+ "categorytree-no-pages": "ենթակատեգորիաներ և էջեր չկան",
+ "categorytree-not-found": "«<i>$1</i>» կատեգորիան չի գտնվել",
+ "categorytree-error": "Տվյալների բեռնումը չհաջողվեց",
+ "categorytree-retry": "Խնդրում ենք սպասել մեկ ակնթարթ և փորձել կրկին։"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/hyw.json b/www/wiki/extensions/CategoryTree/i18n/hyw.json
new file mode 100644
index 00000000..ce038107
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/hyw.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "ArmenBakkalian"
+ ]
+ },
+ "categorytree-expand": "Ընդարձակել",
+ "categorytree-member-counts": "Կը պարունակէ {{PLURAL:$1|1 ենթախմբաւորում|$1 ենթախմբաւորում}}, {{PLURAL:$2|1 էջ|$2 էջ}} եւ {{PLURAL:$3|1 նիշք|$3 նիշք}}",
+ "categorytree-num-categories": "$1 խմբ.",
+ "categorytree-num-pages": "$1 Էջ",
+ "categorytree-num-files": "$1 Ն"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ia.json b/www/wiki/extensions/CategoryTree/i18n/ia.json
new file mode 100644
index 00000000..e6ab751a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ia.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya",
+ "McDutchie"
+ ]
+ },
+ "categorytree": "Arbore de categorias",
+ "categorytree-portlet": "Categorias",
+ "categorytree-legend": "Monstrar arbore de categorias",
+ "categorytree-desc": "Navigar dynamicamente per le [[Special:CategoryTree|structura de categorias]]",
+ "categorytree-header": "Entra le nomine de un categoria pro vider su contento como un structura arboree.\n(Require JavaScript.)",
+ "categorytree-category": "Categoria:",
+ "categorytree-go": "Monstrar arbore",
+ "categorytree-parents": "Categorias superior",
+ "categorytree-mode-label": "Modo:",
+ "categorytree-mode-categories": "categorias solmente",
+ "categorytree-mode-pages": "paginas excepte files",
+ "categorytree-mode-all": "tote le paginas",
+ "categorytree-collapse": "plicar",
+ "categorytree-expand": "displicar",
+ "categorytree-member-counts": "contine {{PLURAL:$1|1 subcategoria|$1 subcategorias}}, {{PLURAL:$2|1 pagina|$2 paginas}}, e {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vacue",
+ "categorytree-load": "cargar",
+ "categorytree-loading": "cargamento in curso…",
+ "categorytree-nothing-found": "nihil trovate",
+ "categorytree-no-subcategories": "nulle subcategoria",
+ "categorytree-no-parent-categories": "nulle categoria superior",
+ "categorytree-no-pages": "nulle pagina o subcategoria",
+ "categorytree-not-found": "Categoria <i>$1</i> non trovate",
+ "categorytree-error": "Problema de cargamento de datos.",
+ "categorytree-retry": "Per favor attende un momento e reproba.",
+ "apihelp-categorytree-description": "Modulo interne pro le extension CategoryTree.",
+ "apihelp-categorytree-summary": "Modulo interne pro le extension CategoryTree.",
+ "apihelp-categorytree-param-category": "Titulo in le spatio de nomines Categoria. Le prefixo essera ignorate si fornite.",
+ "apihelp-categorytree-param-options": "Optiones pro le constructor CategoryTree como objecto JSON. Le option <var>depth</var> predefinite es <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Le optiones debe esser un objecto JSON valide."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/id.json b/www/wiki/extensions/CategoryTree/i18n/id.json
new file mode 100644
index 00000000..d5bd7c36
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/id.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bennylin",
+ "Farras",
+ "IvanLanin",
+ "Iwan Novirion",
+ "Rex",
+ "Rachmat.Wahidi",
+ "Rachmat04"
+ ]
+ },
+ "categorytree": "Pohon kategori",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Tampilkan pohon kategori",
+ "categorytree-desc": "Gadget berbasis AJAX untuk menampilkan [[Special:CategoryTree|struktur kategori]] suatu wiki",
+ "categorytree-header": "Masukkan suatu nama kategori untuk melihat isinya dalam bentuk pohon.\nHarap diperhatikan bahwa fitur ini memerlukan dukungan JavaScript tingkat lanjut yang dikenal sebagai AJAX.\nJika Anda menggunakan penjelajah web lama, atau mematikan fungsi JavaScript Anda, fitur ini tidak dapat dijalankan.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Tampilkan",
+ "categorytree-parents": "Atasan",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "hanya kategori",
+ "categorytree-mode-pages": "halaman kecuali berkas",
+ "categorytree-mode-all": "semua halaman",
+ "categorytree-collapse": "tutup",
+ "categorytree-expand": "buka",
+ "categorytree-member-counts": "memiliki {{PLURAL:$1|$1 subkategori}}, {{PLURAL:$2|$2 halaman}}, dan {{PLURAL:$3|$3 berkas}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 H",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "kosong",
+ "categorytree-load": "muatkan",
+ "categorytree-loading": "memuat...",
+ "categorytree-nothing-found": "tidak ditemukan",
+ "categorytree-no-subcategories": "tidak ada subkategori",
+ "categorytree-no-parent-categories": "tidak ada kategori lebih tinggi",
+ "categorytree-no-pages": "tidak ada halaman atau subkategori",
+ "categorytree-not-found": "Kategori <i>$1</i> tidak ditemukan",
+ "categorytree-error": "Problem memuat data.",
+ "categorytree-retry": "Tunggulah sesaat dan coba lagi.",
+ "apihelp-categorytree-description": "Modul internal untuk ekstensi CategoryTree.",
+ "apihelp-categorytree-param-category": "Judul di ruangnama kategori, awalan akan diabaikan jika ada.",
+ "apihelp-categorytree-param-options": "Opsi untuk pembangun CategoryTree sebagai sebuah objek JSON. Opsi kedalaman baru menjadi <kbd>1</kbd>."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ie.json b/www/wiki/extensions/CategoryTree/i18n/ie.json
new file mode 100644
index 00000000..272f64e8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ie.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya",
+ "Stavanger7"
+ ]
+ },
+ "categorytree-category": "Categorie:",
+ "categorytree-expand": "expander",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ig.json b/www/wiki/extensions/CategoryTree/i18n/ig.json
new file mode 100644
index 00000000..ec42cd25
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ig.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ukabia"
+ ]
+ },
+ "categorytree": "Egbü nke ébéanọr",
+ "categorytree-portlet": "Ébéanọr",
+ "categorytree-legend": "Zi egbü nke ébéanọr",
+ "categorytree-category": "Ébéonọr:",
+ "categorytree-go": "Zí oshíshí",
+ "categorytree-parents": "Ndi mụrụ",
+ "categorytree-mode-categories": "Náni ébéanọr",
+ "categorytree-mode-all": "Ihü nílé",
+ "categorytree-collapse": "zekpùdo",
+ "categorytree-expand": "Sá àsáá",
+ "categorytree-load": "mmẹ̀wẹ́òbú",
+ "categorytree-loading": "ọ byáwálá...",
+ "categorytree-no-subcategories": "ébéonọr-ime àdíghị",
+ "categorytree-no-pages": "ihü ma ébéonọr-ímé àdíghị"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ilo.json b/www/wiki/extensions/CategoryTree/i18n/ilo.json
new file mode 100644
index 00000000..8a4c9d9b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ilo.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lam-ang"
+ ]
+ },
+ "categorytree": "Kayo ti kategoria",
+ "categorytree-portlet": "Katkategoria",
+ "categorytree-legend": "Ipakita ti kayo ti kategoria",
+ "categorytree-desc": "Dinamiko nga agdaliasat iti [[Special:CategoryTree|estrukrura ti kategoria]]",
+ "categorytree-header": "Ikabil ti nagan ti kategoria tapno makita dagiti linaon a kasla estruktura ti kayo. (Masapul ti JavaScript.)",
+ "categorytree-category": "Kategoria:",
+ "categorytree-go": "Ipakita ti kayo",
+ "categorytree-parents": "Nagannak",
+ "categorytree-mode-label": "Wagas:",
+ "categorytree-mode-categories": "katkategoria laeng",
+ "categorytree-mode-pages": "dagiti panid mailaksid dagiti papeles",
+ "categorytree-mode-all": "amin a pampanid",
+ "categorytree-collapse": "rebbaen",
+ "categorytree-expand": "palawaen",
+ "categorytree-member-counts": "Naglaon ti {{PLURAL:$1|1 a subkategoria|$1 a subkatkategoria}}, {{PLURAL:$2|1 a panid|$2 a pampanid}}, ken {{PLURAL:$3|1 a papeles|$3 a pappapeles}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "awan linaon",
+ "categorytree-load": "agkarga",
+ "categorytree-loading": "agkarkarga...",
+ "categorytree-nothing-found": "awan ti nabirukan",
+ "categorytree-no-subcategories": "awan dagiti subkategoria",
+ "categorytree-no-parent-categories": "awan ti nagannak a katkategoria",
+ "categorytree-no-pages": "awan ti pampanid wenno dagiti subkategoria",
+ "categorytree-not-found": "Ti kategoria <i>$1</i> ket saan a nabirukan",
+ "categorytree-error": "Parikut ti panagikarga ti linaon.",
+ "categorytree-retry": "Pangngaasi nga aguray intono madamdama ken ipadas manen.",
+ "apihelp-categorytree-description": "Akin-uneg a modulo para iti pagpaatiddog ti CategoryTree.",
+ "apihelp-categorytree-param-category": "Titulo iti nagan ti espasio ti kategoria, saanto a maikaskaso ti pasakbay no maited.",
+ "apihelp-categorytree-param-options": "Dagiti pagpilian ti konstruktor ti CategoryTree a kas maysa a banag ti JSON. Ti pagpilian ti <var>depth</var> ket kasisigud iti <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Dagiti pagpilian ket nasken nga umiso a banag ti JSON."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/inh.json b/www/wiki/extensions/CategoryTree/i18n/inh.json
new file mode 100644
index 00000000..68bab658
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/inh.json
@@ -0,0 +1,31 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sapral Mikail",
+ "Исмаил Садуев",
+ "ElizaMag",
+ "Adam-Yourist"
+ ]
+ },
+ "categorytree": "Категорий га",
+ "categorytree-portlet": "Категореш",
+ "categorytree-legend": "Категорий га хьахьокха",
+ "categorytree-category": "Категори:",
+ "categorytree-go": "Га хьахьокха",
+ "categorytree-parents": "Хьалхара категореш",
+ "categorytree-mode-label": "Раж:",
+ "categorytree-mode-categories": "алхха категореш",
+ "categorytree-mode-all": "еррига оагIонаш",
+ "categorytree-expand": "хьадоаржаде",
+ "categorytree-member-counts": "Укхунах йоалл $1 {{PLURAL:$1|1=кIалоагIат}} а, $2 {{PLURAL:$2|1=оагӀув}} а, $3 {{PLURAL:$3|1=файл}} а",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Оа",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "яьсса",
+ "categorytree-load": "чуяккха",
+ "categorytree-loading": "доттар...",
+ "categorytree-nothing-found": "Укх категори чу кIалкатегореш яц.",
+ "categorytree-no-subcategories": "кIалкатегореш яц",
+ "categorytree-no-parent-categories": "хьалхара категореш яц",
+ "categorytree-no-pages": "оагӀонаш а кIалкатегореш а яц"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/io.json b/www/wiki/extensions/CategoryTree/i18n/io.json
new file mode 100644
index 00000000..ffbf8b45
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/io.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya",
+ "Joao Xavier"
+ ]
+ },
+ "categorytree": "Kategorio-arboro",
+ "categorytree-portlet": "Kategorii",
+ "categorytree-legend": "Montrar kategorio-arboro",
+ "categorytree-category": "Kategorio:",
+ "categorytree-go": "Montrar Arboro",
+ "categorytree-mode-categories": "nur kategorii",
+ "categorytree-mode-pages": "pagini ecepte arkivi",
+ "categorytree-mode-all": "omna pagini",
+ "categorytree-expand": "Montrar la listo",
+ "categorytree-member-counts": "kontenas {{PLURAL:$1|1 subkategorio|$1 subkategorii}}, {{PLURAL:$2|1 pagino|$2 pagini}}, ed {{PLURAL:$3|1 arkivo|$3 arkivi}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 P",
+ "categorytree-load": "kargar",
+ "categorytree-nothing-found": "nulo trovita",
+ "categorytree-no-subcategories": "nula subkategorii",
+ "categorytree-no-pages": "nula pagini o subkategorii",
+ "categorytree-not-found": "Kategorio <i>$1</i> ne trovita"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/is.json b/www/wiki/extensions/CategoryTree/i18n/is.json
new file mode 100644
index 00000000..aaec1263
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/is.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "S.Örvarr.S",
+ "Snævar",
+ "Spacebirdy",
+ "Sveinn í Felli"
+ ]
+ },
+ "categorytree": "Flokkatré",
+ "categorytree-portlet": "Flokkar",
+ "categorytree-legend": "Sýna flokkatré",
+ "categorytree-header": "Sláðu inn heiti flokks til að sjá innihald hans sem tré. (Þarfnast JavaScript)",
+ "categorytree-category": "Flokkur:",
+ "categorytree-go": "Birta greinar",
+ "categorytree-parents": "Yfirþræðir",
+ "categorytree-mode-label": "Hamur:",
+ "categorytree-mode-categories": "bara flokka",
+ "categorytree-mode-pages": "síður að myndum undanskildum",
+ "categorytree-mode-all": "allar síður",
+ "categorytree-collapse": "fela",
+ "categorytree-expand": "sýna",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "Inniheldur $1 {{PLURAL:$1|undirflokk|undirflokka}}, $2 {{PLURAL:$2|síðu|síður}}, og $3 {{PLURAL:$3|mynd|myndir}}",
+ "categorytree-num-categories": "$1 F",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 M",
+ "categorytree-num-empty": "tómur",
+ "categorytree-load": "hlaða",
+ "categorytree-loading": "hleð",
+ "categorytree-nothing-found": "ekkert fannst",
+ "categorytree-no-subcategories": "engir undirflokkar",
+ "categorytree-no-parent-categories": "engir yfirflokkar",
+ "categorytree-no-pages": "engar síður eða undirflokkar",
+ "categorytree-not-found": "Flokkurinn <i>$1</i> fannst ekki",
+ "categorytree-error": "Villa við hleðslu gagna.",
+ "categorytree-retry": "Gjörðu svo vel og reyndu síðar.",
+ "apihelp-categorytree-description": "Innri kerfiseining fyrir CategoryTree-viðbótina.",
+ "apihelp-categorytree-summary": "Innri kerfiseining fyrir CategoryTree-viðbótina."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/it.json b/www/wiki/extensions/CategoryTree/i18n/it.json
new file mode 100644
index 00000000..d95d479f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/it.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ ".anaconda",
+ "Aushulz",
+ "Beta16",
+ "BrokenArrow",
+ "Cruccone",
+ "Darth Kule",
+ "Gianfranco",
+ "Nemo bis",
+ "Lucas2",
+ "FRacco",
+ "Nemo ter"
+ ]
+ },
+ "categorytree": "Albero delle categorie",
+ "categorytree-portlet": "Categorie",
+ "categorytree-legend": "Mostra l'albero delle categorie",
+ "categorytree-desc": "Visualizza in modo dinamico la [[Special:CategoryTree|struttura delle categorie]]",
+ "categorytree-header": "Inserisci il nome di una categoria per vederne i contenuti in una struttura ad albero. (richiede JavaScript)",
+ "categorytree-category": "Categoria:",
+ "categorytree-go": "Mostra albero",
+ "categorytree-parents": "Categorie superiori",
+ "categorytree-mode-label": "Modalità:",
+ "categorytree-mode-categories": "mostra solo le categorie",
+ "categorytree-mode-pages": "tutte le pagine, escluse le immagini",
+ "categorytree-mode-all": "tutte le pagine",
+ "categorytree-collapse": "comprimi",
+ "categorytree-expand": "espandi",
+ "categorytree-member-counts": "contiene {{PLURAL:$1|1 sottocategoria|$1 sottocategorie}}, {{PLURAL:$2|1 pagina|$2 pagine}} e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vuota",
+ "categorytree-load": "carica",
+ "categorytree-loading": "caricamento in corso…",
+ "categorytree-nothing-found": "nessun risultato",
+ "categorytree-no-subcategories": "nessuna sottocategoria",
+ "categorytree-no-parent-categories": "nessuna categoria superiore",
+ "categorytree-no-pages": "nessuna pagina né sottocategoria",
+ "categorytree-not-found": "Categoria <i>$1</i> non trovata",
+ "categorytree-error": "Problema nel caricamento dei dati.",
+ "categorytree-retry": "Attendere un momento e riprovare.",
+ "apihelp-categorytree-description": "Modulo interno per l'estensione CategoryTree.",
+ "apihelp-categorytree-param-category": "Titolo nel namespace categoria, il prefisso verrà ignorato se dato.",
+ "apihelp-categorytree-param-options": "Opzioni per il costruttore CategoryTree come oggetto JSON. L'opzione <var>depth</var> predefinita è <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Le opzioni devono essere fornite come un oggetto JSON valido."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ja.json b/www/wiki/extensions/CategoryTree/i18n/ja.json
new file mode 100644
index 00000000..ebc02a51
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ja.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aotake",
+ "Broad-Sky",
+ "Fryed-peach",
+ "JtFuruhata",
+ "Kahusi",
+ "Shirayuki",
+ "Whym",
+ "Mfuji",
+ "Otokoume",
+ "Yusuke1109"
+ ]
+ },
+ "categorytree": "カテゴリツリー",
+ "categorytree-portlet": "カテゴリ",
+ "categorytree-legend": "カテゴリツリーの表示",
+ "categorytree-desc": "ウィキの[[Special:CategoryTree|カテゴリの構造]]をツリー形式で動的に表示する",
+ "categorytree-header": "カテゴリの内容をツリー形式で表示するために、そのカテゴリ名を入力してください (JavaScript が必要)。",
+ "categorytree-category": "カテゴリ:",
+ "categorytree-go": "ツリーを表示",
+ "categorytree-parents": "上位カテゴリ",
+ "categorytree-mode-label": "モード:",
+ "categorytree-mode-categories": "カテゴリのみ",
+ "categorytree-mode-pages": "ファイル以外のページ",
+ "categorytree-mode-all": "すべてのページ",
+ "categorytree-collapse": "折り畳む",
+ "categorytree-expand": "展開する",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "{{PLURAL:$1|下位カテゴリ $1 件}}、{{PLURAL:$2|ページ $2 件}}、{{PLURAL:$3|ファイル $3 件}}を含んでいます",
+ "categorytree-num-categories": "$1カテゴリ",
+ "categorytree-num-pages": "$1頁",
+ "categorytree-num-files": "$1ファイル",
+ "categorytree-num-empty": "空",
+ "categorytree-load": "読み込んで展開する",
+ "categorytree-loading": "読み込み中…",
+ "categorytree-nothing-found": "何も見つかりませんでした",
+ "categorytree-no-subcategories": "下位カテゴリがありません",
+ "categorytree-no-parent-categories": "上位カテゴリはありません",
+ "categorytree-no-pages": "ページや下位カテゴリがありません",
+ "categorytree-not-found": "カテゴリ「<i>$1</i>」はありません",
+ "categorytree-error": "データの読み込み中に問題が発生しました。",
+ "categorytree-retry": "時間をおいてからもう一度試してください。",
+ "apihelp-categorytree-description": "カテゴリツリー拡張機能の内部モジュール。",
+ "apihelp-categorytree-summary": "カテゴリツリー拡張機能の内部モジュール。",
+ "apihelp-categorytree-param-category": "カテゴリ名前空間におけるページ名、接頭辞は指定しても無視される。",
+ "apihelp-categorytree-param-options": "JSONオブジェクトとしてのCategoryTreeコンストラクタのオプション。<var>深さ</var>オプションのデフォルトは<kbd>1</kbd>です。",
+ "apierror-categorytree-invalidjson": "オプションは有効なJSONオブジェクトでなければなりません。"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/jam.json b/www/wiki/extensions/CategoryTree/i18n/jam.json
new file mode 100644
index 00000000..ce62073a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/jam.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Katxis"
+ ]
+ },
+ "categorytree-expand": "expan",
+ "categorytree-member-counts": "Kantien {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 page|$2 pages}}, ah {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/jut.json b/www/wiki/extensions/CategoryTree/i18n/jut.json
new file mode 100644
index 00000000..a087f8a7
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/jut.json
@@ -0,0 +1,31 @@
+{
+ "@metadata": {
+ "authors": [
+ "Huslåke",
+ "Jyllanj"
+ ]
+ },
+ "categorytree": "Kategoriträj",
+ "categorytree-desc": "Dynamisk navigasjon i [[Special:CategoryTree|kategoristrukturen]]",
+ "categorytree-header": "Intast naune på en kategori for å sietj inholje som e träj. Bemærk å detj kräwe avanciirtje JavaScript-funksjonalitiet tjentj som AJAX, dä wirke ett hwes du hår i møj gammel browser elle hwes du hår slotj JavaScript fra.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Wis træj",
+ "categorytree-parents": "Öwekategorie",
+ "categorytree-mode-categories": "kons kategorie",
+ "categorytree-mode-pages": "sider undtaget billeter",
+ "categorytree-mode-all": "åll side",
+ "categorytree-collapse": "folj sammel",
+ "categorytree-expand": "folj ut",
+ "categorytree-member-counts": "inholje {{PLURAL:$1|jen unjekategori|$1 unjekategorie}}, {{PLURAL:$2|jen siid|$2 side}} å {{PLURAL:$3|jej fil|$3 file}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-load": "hentj",
+ "categorytree-loading": "inläse",
+ "categorytree-nothing-found": "ienting funjen",
+ "categorytree-no-subcategories": "ien unjekategorie",
+ "categorytree-no-pages": "ien side elle unjekategorie",
+ "categorytree-not-found": "Kategorien ''$1'' bløw ett funjen",
+ "categorytree-error": "Där opstue e problem unje inläsneng å data.",
+ "categorytree-retry": "Wentj e yeblikk å prööw idjen."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/jv.json b/www/wiki/extensions/CategoryTree/i18n/jv.json
new file mode 100644
index 00000000..6f239c36
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/jv.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bennylin",
+ "Meursault2004",
+ "NoiX180",
+ "Pras"
+ ]
+ },
+ "categorytree": "Wit kategori",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Tuduhaké wit kategori",
+ "categorytree-desc": "Gadget adhedhasar AJAX kanggo nuduhaké [[Special:CategoryTree|struktur kategori]] sawijining wiki",
+ "categorytree-header": "Lebokna sawijining jeneng kategori kanggo deleng isiné minangka sawijining wujud uwit.\nMangga diwigatèkaké yèn fitur iki merlokaké fungsionalitas JavaScript canggih sing diarani AJAX.\nMenawa panjenengan panjlajah wèbé kalebu vèrsi lawa, utawa fitur JavaScript dipatèni, fungsi iki ora bisa dilakokaké.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Tuduhaké wit",
+ "categorytree-parents": "Babon",
+ "categorytree-mode-label": "Cara:",
+ "categorytree-mode-categories": "mligi kategori",
+ "categorytree-mode-pages": "kaca kajaba barkas",
+ "categorytree-mode-all": "kabèh kaca",
+ "categorytree-collapse": "tutup",
+ "categorytree-expand": "bukak",
+ "categorytree-member-counts": "Ngandhut {{PLURAL:$1|1 subkategori|$1 subkategori}}, {{PLURAL:$2|1 kaca|$2 kaca}}, lan {{PLURAL:$3|1 barkas|$3 barkas}}",
+ "categorytree-num-categories": "$1 Kt",
+ "categorytree-num-pages": "$1 Kc",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "suwung",
+ "categorytree-load": "mot",
+ "categorytree-loading": "ngamot…",
+ "categorytree-nothing-found": "ora ana apa-apa",
+ "categorytree-no-subcategories": "anak kategori ora ana",
+ "categorytree-no-parent-categories": "kategori babon ora ana",
+ "categorytree-no-pages": "kaca utawa anak kategori ora ana",
+ "categorytree-not-found": "Kategori <i>$1</i> ora ana",
+ "categorytree-error": "Ana masalah nalika ngamot dhatah.",
+ "categorytree-retry": "Mangga nunggu sadhéla banjur njajal manèh.",
+ "apihelp-categorytree-description": "Modhul njero tumrap jabungan WitKategori.",
+ "apihelp-categorytree-param-category": "Sesirah ing mandala aran kategori. Menawa ana, ater-ater bakal ora kanggo."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ka.json b/www/wiki/extensions/CategoryTree/i18n/ka.json
new file mode 100644
index 00000000..917b1ac5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ka.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "BRUTE",
+ "David1010",
+ "ITshnik",
+ "Malafaya"
+ ]
+ },
+ "categorytree": "კატეგორიების სქემა",
+ "categorytree-portlet": "კატეგორიები",
+ "categorytree-legend": "კატეგორიების სქემის ჩვენება",
+ "categorytree-desc": "[[Special:CategoryTree|კატეგორიის სტრუქტურის]] დინამიური ნავიგაცია",
+ "categorytree-header": "შეიყვანეთ კატეგორიის სახელი, რომ დაინახოთ მისი შიგთავსი ხის სტრუქტურის მსგავსად. (საჭიროა ჯავასკრიპტი.)",
+ "categorytree-category": "კატეგორია:",
+ "categorytree-go": "სქემის ჩვენება",
+ "categorytree-parents": "მშობლები",
+ "categorytree-mode-label": "რეჟიმი:",
+ "categorytree-mode-categories": "მხოლოდ კატეგორიები",
+ "categorytree-mode-pages": "გვერდები ფაილების გარდა",
+ "categorytree-mode-all": "ყველა გვერდი",
+ "categorytree-collapse": "ჩაკეცვა",
+ "categorytree-expand": "გაშლა",
+ "categorytree-member-counts": "შეიცავს {{PLURAL:$1|1 ქვეკატეგორიას|$1 ქვეკატეგორიას}}, {{PLURAL:$2|1 გვერდს|$2 გვერდს}}, და {{PLURAL:$3|1 ფაილს|$3 ფაილს}}",
+ "categorytree-num-categories": "$1 კ",
+ "categorytree-num-pages": "$1 გ",
+ "categorytree-num-files": "$1 ფ",
+ "categorytree-num-empty": "ცარიელი",
+ "categorytree-load": "ჩატვირთვა",
+ "categorytree-loading": "იტვირთება…",
+ "categorytree-nothing-found": "ვერაფერი მოიძებნა",
+ "categorytree-no-subcategories": "ქვეკატეგორიები არაა",
+ "categorytree-no-parent-categories": "მშობელი კატეგორიები არაა",
+ "categorytree-no-pages": "არაა გვერდები ან ქვეკატეგორიები",
+ "categorytree-not-found": "კატეგორია <i>$1</i> ვერ მოიძებნა",
+ "categorytree-error": "ხარვეზი მონაცემთა ჩატვირთვაში.",
+ "categorytree-retry": "გთხოვთ, დაიცადეთ ცოტა ხნით და კვლავ სცადეთ.",
+ "apihelp-categorytree-description": "შიდა მოდული CategoryTree გაფართოებისთვის."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kaa.json b/www/wiki/extensions/CategoryTree/i18n/kaa.json
new file mode 100644
index 00000000..181d9ae3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kaa.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "AlefZet"
+ ]
+ },
+ "categorytree": "Kategoriyalar teregi"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kab.json b/www/wiki/extensions/CategoryTree/i18n/kab.json
new file mode 100644
index 00000000..47e0652c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kab.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mmistmurt",
+ "Belkacem77"
+ ]
+ },
+ "categorytree-portlet": "Tiggayin",
+ "categorytree-category": "Taggayt :",
+ "categorytree-mode-all": "Akk isebtaren",
+ "categorytree-expand": "snefli",
+ "categorytree-member-counts": "yegber $1 {{PLURAL:$1|taggayt tasnawant|taggayin tisnawanin}}, $2 {{PLURAL:$2|aebter|isebtar}} akked $3 {{PLURAL:$3|ufaylu|ifayla}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kbp.json b/www/wiki/extensions/CategoryTree/i18n/kbp.json
new file mode 100644
index 00000000..08b6a00b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kbp.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangbade"
+ ]
+ },
+ "categorytree-expand": "Yazɩ",
+ "categorytree-member-counts": "Kɩ-taa wɛ {{PLURAL:$1|pɩlɩʋ kɩtɛyʋʋ kʋɖʋmʋʋ|$1 pɩlɩŋ kɩtɛyɩŋ}}",
+ "categorytree-num-categories": "P $1",
+ "categorytree-num-pages": "T $1",
+ "categorytree-num-files": "T $1"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kea.json b/www/wiki/extensions/CategoryTree/i18n/kea.json
new file mode 100644
index 00000000..e9aa6aaa
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kea.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Quintino Lopes Castro Tavares"
+ ]
+ },
+ "categorytree-expand": "amplia",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/khw.json b/www/wiki/extensions/CategoryTree/i18n/khw.json
new file mode 100644
index 00000000..a9711ebf
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/khw.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Rachitrali"
+ ]
+ },
+ "categorytree-portlet": "زمرہ جات",
+ "categorytree-legend": "مختلق قسمان پشاوے",
+ "categorytree-category": "زمرہ",
+ "categorytree-go": "بہ ترتیب شجر(کان)",
+ "categorytree-parents": "نن تت",
+ "categorytree-mode-label": "موڈ:",
+ "categorytree-mode-categories": "صرف زمرہ جات",
+ "categorytree-mode-pages": "فائلار علاوہ صفحات",
+ "categorytree-mode-all": "سف صفحات",
+ "categorytree-collapse": "خاتمہ",
+ "categorytree-expand": "فراخ کورے",
+ "categorytree-member-counts": "شامل شینی {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 page|$2 pages}}, and {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "خالی",
+ "categorytree-load": "اثقال/load",
+ "categorytree-loading": "دوران اثقال/loading…",
+ "categorytree-nothing-found": "کیاغ دستیاب نیکی",
+ "categorytree-no-subcategories": "کیہ ذیلی زمرہ نیکی",
+ "categorytree-no-parent-categories": "کیہ نن تتان زمرہ جات"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kk-arab.json b/www/wiki/extensions/CategoryTree/i18n/kk-arab.json
new file mode 100644
index 00000000..89bd0293
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kk-arab.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": [],
+ "categorytree": "سانات بۇتاقتارى",
+ "categorytree-header": "سانات مازمۇنىڭ بۇتاقتار تۇردە كورۋ ٴۇشىن اتاۋىن ەنگىزىڭىز.\nاڭعارپتا: بۇل ىسكە JavaScript قۇرالىنىڭ AJAX دەگەن كەڭەيتىلگەن قابىلەتى قاجەت بولادى.\nەگەر شولعىشىڭىز وتە ەسكى, نەمەسە JavaScript وشىرىلگەن بولسا, بۇل ىسكە اسىرىلمايدى.",
+ "categorytree-category": "سانات:",
+ "categorytree-go": "بۇتاقتارىن كورسەت",
+ "categorytree-parents": "جوعارعىلار",
+ "categorytree-mode-categories": "تەك ساناتتار",
+ "categorytree-mode-pages": "بەتتەر (سۋرەتتەردى ساناماي)",
+ "categorytree-mode-all": "بارلىق بەت",
+ "categorytree-collapse": "تارىلتۋ",
+ "categorytree-expand": "كەڭەيتۋ",
+ "categorytree-load": "جۇكتەۋ",
+ "categorytree-loading": "جۇكتەۋدە",
+ "categorytree-nothing-found": "ەشتەڭە تابىلمادى",
+ "categorytree-no-subcategories": "ساناتشالارى جوق",
+ "categorytree-no-pages": "بەتتەرى نە ساناتشالارى جوق",
+ "categorytree-not-found": "<i>$1</i> دەگەن سانات تابىلمادى",
+ "categorytree-error": "دەرەكتەردى جۇكتەۋ كەزىندە شاتاق شىقتى.",
+ "categorytree-retry": "ٴبىر ٴسات كۇتە تۇرىپ قايتالاڭىز."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kk-cyrl.json b/www/wiki/extensions/CategoryTree/i18n/kk-cyrl.json
new file mode 100644
index 00000000..030c3747
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kk-cyrl.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arystanbek"
+ ]
+ },
+ "categorytree": "Санат бұтақтары",
+ "categorytree-portlet": "Санаттар",
+ "categorytree-legend": "Санат бұтағын көрсету",
+ "categorytree-desc": "[[Special:CategoryTree|Санат құрылымын]] серпінді шарлау",
+ "categorytree-header": "Санат мазмұның бұтақтар түрде көру үшін атауын енгізіңіз.\nАңғарпта: Бұл іске JavaScript құралының AJAX деген кеңейтілген қабілеті қажет болады.\nЕгер шолғышыңыз өте ескі, немесе JavaScript өшірілген болса, бұл іске асырылмайды.",
+ "categorytree-category": "Санат:",
+ "categorytree-go": "Бұтақтарын көрсет",
+ "categorytree-parents": "Жоғарғылар",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "тек санаттар",
+ "categorytree-mode-pages": "беттер (суреттерді санамай)",
+ "categorytree-mode-all": "барлық беттер",
+ "categorytree-collapse": "тарылту",
+ "categorytree-expand": "кеңейту",
+ "categorytree-member-counts": "Қамтылғандар {{PLURAL:$1|1 санатша|$1 санатша}}, {{PLURAL:$2|1 бет|$2 бет}}, және {{PLURAL:$3|1 файл|$3 файл}}",
+ "categorytree-num-categories": "$1 санатша",
+ "categorytree-num-pages": "$1 бет",
+ "categorytree-num-files": "$1 Файл",
+ "categorytree-num-empty": "бос",
+ "categorytree-load": "жүктеу",
+ "categorytree-loading": "жүктеуде...",
+ "categorytree-nothing-found": "ештеңе табылмады",
+ "categorytree-no-subcategories": "санатшалары жоқ",
+ "categorytree-no-parent-categories": "аталық санаттар жоқ",
+ "categorytree-no-pages": "беттері немесе санатшалары жоқ",
+ "categorytree-not-found": "<i>$1</i> деген санат табылмады",
+ "categorytree-error": "Деректерді жүктеу кезінде шатақ шықты.",
+ "categorytree-retry": "Бір сәт күте тұрып қайталаңыз."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kk-latn.json b/www/wiki/extensions/CategoryTree/i18n/kk-latn.json
new file mode 100644
index 00000000..c2071b67
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kk-latn.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": [],
+ "categorytree": "Sanat butaqtarı",
+ "categorytree-header": "Sanat mazmunıñ butaqtar türde körw üşin atawın engiziñiz.\nAñğarpta: Bul iske JavaScript quralınıñ AJAX degen keñeýtilgen qabileti qajet boladı.\nEger şolğışıñız öte eski, nemese JavaScript öşirilgen bolsa, bul iske asırılmaýdı.",
+ "categorytree-category": "Sanat:",
+ "categorytree-go": "Butaqtarın körset",
+ "categorytree-parents": "Joğarğılar",
+ "categorytree-mode-categories": "tek sanattar",
+ "categorytree-mode-pages": "better (swretterdi sanamaý)",
+ "categorytree-mode-all": "barlıq bet",
+ "categorytree-collapse": "tarıltw",
+ "categorytree-expand": "keñeýtw",
+ "categorytree-load": "jüktew",
+ "categorytree-loading": "jüktewde",
+ "categorytree-nothing-found": "eşteñe tabılmadı",
+ "categorytree-no-subcategories": "sanatşaları joq",
+ "categorytree-no-pages": "betteri ne sanatşaları joq",
+ "categorytree-not-found": "<i>$1</i> degen sanat tabılmadı",
+ "categorytree-error": "Derekterdi jüktew kezinde şataq şıqtı.",
+ "categorytree-retry": "Bir sät küte turıp qaýtalañız."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/km.json b/www/wiki/extensions/CategoryTree/i18n/km.json
new file mode 100644
index 00000000..49295341
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/km.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chhorran",
+ "Lovekhmer",
+ "Thearith",
+ "គីមស៊្រុន",
+ "វ័ណថារិទ្ធ"
+ ]
+ },
+ "categorytree": "មែកធាងនៃចំណាត់ថ្នាក់ក្រុម",
+ "categorytree-portlet": "ចំណាត់ថ្នាក់ក្រុម",
+ "categorytree-legend": "បង្ហាញមែកធាងចំណាត់ថ្នាក់ក្រុម",
+ "categorytree-category": "ចំណាត់ថ្នាក់ក្រុម:",
+ "categorytree-go": "បង្ហាញមែកធាង",
+ "categorytree-parents": "ចំណាត់ថ្នាក់ក្រុមកម្រិតខ្ពស់",
+ "categorytree-mode-label": "ម៉ូដ៖",
+ "categorytree-mode-categories": "សម្រាប់តែចំណាត់ថ្នាក់ក្រុមប៉ុណ្ណោះ",
+ "categorytree-mode-pages": "ទំព័រលើកលែងតែរូបភាព",
+ "categorytree-mode-all": "គ្រប់ទំព័រ",
+ "categorytree-collapse": "បង្រួម",
+ "categorytree-expand": "ពន្លាត",
+ "categorytree-member-counts": "មាន{{PLURAL:$1|១ចំណាត់ថ្នាក់ក្រុមរង|$1ចំណាត់ថ្នាក់ក្រុមរង}} {{PLURAL:$2|១ទំព័រ|$2ទំព័រ}} និង{{PLURAL:$3|១ឯកសារ|$3ឯកសារ}}",
+ "categorytree-num-categories": "$1 ចំ",
+ "categorytree-num-pages": "$1 ទំ",
+ "categorytree-num-files": "$1 ឯ",
+ "categorytree-num-empty": "ទទេ",
+ "categorytree-load": "ផ្ទុក",
+ "categorytree-loading": "កំពុងផ្ទុក",
+ "categorytree-nothing-found": "រកមិនឃើញអ្វីទេ",
+ "categorytree-no-subcategories": "មិនមានចំណាត់ថ្នាក់ក្រុមរងទេ",
+ "categorytree-no-parent-categories": "មិនមានចំណាត់ថ្នាក់ក្រុមមេទេ",
+ "categorytree-no-pages": "មិនមានទំព័រឬចំណាត់ថ្នាក់ក្រុមរងទេ",
+ "categorytree-not-found": "រកមិនឃើញចំណាត់ថ្នាក់ក្រុម <i>$1</i> ទេ",
+ "categorytree-error": "មានបញ្ហាក្នុងផ្ទុកទិន្នន័យ។",
+ "categorytree-retry": "សូម​រង់ចាំ​មួយភ្លែត​រួច​ព្យាយាម​ម្តងទៀត​។"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kn.json b/www/wiki/extensions/CategoryTree/i18n/kn.json
new file mode 100644
index 00000000..c1454d68
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kn.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Abhirama",
+ "Nayvik",
+ "VASANTH S.N."
+ ]
+ },
+ "categorytree": "ವರ್ಗವೃಕ್ಷ",
+ "categorytree-portlet": "ವರ್ಗಗಳು",
+ "categorytree-legend": "ವರ್ಗವೃಕ್ಷವನ್ನು ತೋರಿಸಿ",
+ "categorytree-category": "ವರ್ಗ:",
+ "categorytree-go": "ವೃಕ್ಷವನ್ನು ತೋರಿಸಿ",
+ "categorytree-parents": "ಪೋಷಕರು",
+ "categorytree-mode-categories": "ಕೇವಲ ವರ್ಗಗಳು",
+ "categorytree-mode-pages": "ಕಡತಗಳಿಲ್ಲದಿರುವ ಪುಟಗಳು",
+ "categorytree-mode-all": "ಎಲ್ಲಾ ಪುಟಗಳು",
+ "categorytree-collapse": "ಕುಸಿಯಲಿ",
+ "categorytree-expand": "ವಿಸ್ತರಿಸಿ",
+ "categorytree-num-categories": "$1 ವ",
+ "categorytree-num-pages": "$1 ಪು",
+ "categorytree-num-files": "$1 ಕ",
+ "categorytree-num-empty": "ಖಾಲಿ",
+ "categorytree-load": "ತುಂಬಿಸು",
+ "categorytree-loading": "ತುಂಬಿಸಲ್ಪಡುತ್ತಿದೆ.......",
+ "categorytree-nothing-found": "ಏನೂ ಸಿಗಲಿಲ್ಲ",
+ "categorytree-no-subcategories": "ಉಪವರ್ಗಗಳಿಲ್ಲ",
+ "categorytree-no-parent-categories": "ಪೋಷಕ ವರ್ಗಗಳಿಲ್ಲ",
+ "categorytree-no-pages": "ಪುಟಗಳು ಅಥವಾ ಉಪವರ್ಗಗಳಿಲ್ಲ",
+ "categorytree-not-found": "ಈ <i>$1</i> ವರ್ಗವು ಕಾಣಿಸುತ್ತಿಲ್ಲ",
+ "categorytree-error": "ಮಾಹಿತಿ ಉತ್ಪೂರಣೆಯಲ್ಲಿ ತೊಂದರೆಯಾಗಿದೆ.",
+ "categorytree-retry": "ಒಂದು ಕ್ಷಣ ಕಾದು ಅನಂತರ ಪ್ರಯತ್ನಿಸಿ."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ko.json b/www/wiki/extensions/CategoryTree/i18n/ko.json
new file mode 100644
index 00000000..8c849f0d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ko.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ficell",
+ "Klutzy",
+ "Kwj2772",
+ "Priviet",
+ "ToePeu",
+ "아라",
+ "Mooozi",
+ "Ykhwong",
+ "Jerrykim306",
+ "렌즈"
+ ]
+ },
+ "categorytree": "분류 트리",
+ "categorytree-portlet": "분류",
+ "categorytree-legend": "분류 트리 보기",
+ "categorytree-desc": "[[Special:CategoryTree|분류 구조]]를 동적으로 둘러볼 수 있습니다",
+ "categorytree-header": "내용을 트리 구조로 볼 분류 이름을 입력하십시오. (자바스크립트 필요)",
+ "categorytree-category": "분류:",
+ "categorytree-go": "트리 보기",
+ "categorytree-parents": "상위 분류",
+ "categorytree-mode-label": "모드:",
+ "categorytree-mode-categories": "분류 문서만 보기",
+ "categorytree-mode-pages": "파일을 제외한 문서",
+ "categorytree-mode-all": "모든 문서",
+ "categorytree-collapse": "접기",
+ "categorytree-expand": "펼치기",
+ "categorytree-member-counts": "{{PLURAL:$1|하위 분류 1개|하위 분류 $1개}}, {{PLURAL:$2|문서 1개|문서 $2개}}, {{PLURAL:$3|파일 1개|파일 $3개}}를 포함하고 있습니다",
+ "categorytree-num-categories": "$1개 분류",
+ "categorytree-num-pages": "$1개 문서",
+ "categorytree-num-files": "$1개 파일",
+ "categorytree-num-empty": "비었음",
+ "categorytree-load": "불러오기",
+ "categorytree-loading": "불러오는 중…",
+ "categorytree-nothing-found": "결과 없음",
+ "categorytree-no-subcategories": "하위 분류 없음",
+ "categorytree-no-parent-categories": "상위 분류가 없습니다.",
+ "categorytree-no-pages": "문서나 하위 분류 없음",
+ "categorytree-not-found": "$1 분류가 없습니다",
+ "categorytree-error": "값을 불러오는 중 오류 발생",
+ "categorytree-retry": "잠시 후에 다시 해보세요.",
+ "apihelp-categorytree-description": "CategoryTree 확장 기능을 위한 내부 모듈입니다.",
+ "apihelp-categorytree-summary": "CategoryTree 확장 기능을 위한 내부 모듈입니다.",
+ "apihelp-categorytree-param-category": "분류 이름공간에서의 제목, 접두어는 무시됩니다.",
+ "apihelp-categorytree-param-options": "JSON 오브젝트 자격의 CategoryTree 생성자를 위한 옵션입니다. <var>depth</var> 옵션의 기본값은 <kbd>1</kbd>입니다.",
+ "apierror-categorytree-invalidjson": "옵션은 반드시 유효한 JSON 형식이어야 합니다."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/krc.json b/www/wiki/extensions/CategoryTree/i18n/krc.json
new file mode 100644
index 00000000..d3087a58
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/krc.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Iltever",
+ "Ernác"
+ ]
+ },
+ "categorytree": "Категорияланы тереги",
+ "categorytree-portlet": "Категорияла",
+ "categorytree-legend": "Категорияланы терегин кёргюз",
+ "categorytree-desc": "Викини [[Special:CategoryTree|структуры категорияларыны структурасын]] кёргюзюр ючюн AJAX-компонент",
+ "categorytree-header": "Категория атын джазыгъыз да, ол терек кибик кёрюннюкдю.\nОл амал, сизни браузеригиз AJAX-ны тута эсе барды.\nСизни браузеригизни версиясы эски эсе неда JavaScript джукъланыб эсе, тюбкатегорияланы терек кибик кёргюзтюу амал бла хайырланаллыкъ тюлсюз.",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Терекни кёргюз",
+ "categorytree-parents": "Огъары категорияла",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "къуру категорияла",
+ "categorytree-mode-pages": "файлладан къалгъан",
+ "categorytree-mode-all": "бютеу бетле",
+ "categorytree-collapse": "джашыр",
+ "categorytree-expand": "кёргюз",
+ "categorytree-member-counts": "Ичинде $1 {{PLURAL:$1|тюбкатегория}}, $2 {{PLURAL:$2|бет}} эмда $3 {{PLURAL:$3|файл}} барды",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Б",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "бош",
+ "categorytree-load": "джюкле",
+ "categorytree-loading": "джюклениу...",
+ "categorytree-nothing-found": "джукъ да табылмады",
+ "categorytree-no-subcategories": "Тюбкатегория джокъду",
+ "categorytree-no-parent-categories": "огъары категорияла джокъдула",
+ "categorytree-no-pages": "статьяла бла тюбкатегорияла джокъдула",
+ "categorytree-not-found": "«$1» категория табылмады.",
+ "categorytree-error": "Билгиле джюклеуде халат.",
+ "categorytree-retry": "Бираз сакълагъыз да энтда бир кере кёрюрсюз."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kri.json b/www/wiki/extensions/CategoryTree/i18n/kri.json
new file mode 100644
index 00000000..718097bd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kri.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Protostar"
+ ]
+ },
+ "categorytree-expand": "bigifay"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/krj.json b/www/wiki/extensions/CategoryTree/i18n/krj.json
new file mode 100644
index 00000000..b438963f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/krj.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jose77"
+ ]
+ },
+ "categorytree-category": "Kategorya:"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/krl.json b/www/wiki/extensions/CategoryTree/i18n/krl.json
new file mode 100644
index 00000000..af2e5ff8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/krl.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mashoi7",
+ "Varvana"
+ ]
+ },
+ "categorytree-expand": "avua",
+ "categorytree-member-counts": "Täh kuuluu {{PLURAL:$1|1 alaluokka|$1 alaluokkua}}, {{PLURAL:$2|1 šivu|$2 šivuo}}, ta {{PLURAL:$3|1 faili|$3 failie}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 T"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ks-arab.json b/www/wiki/extensions/CategoryTree/i18n/ks-arab.json
new file mode 100644
index 00000000..c54eecad
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ks-arab.json
@@ -0,0 +1,6 @@
+{
+ "@metadata": [],
+ "categorytree-category": "زٲژ:",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ksh.json b/www/wiki/extensions/CategoryTree/i18n/ksh.json
new file mode 100644
index 00000000..962bcf51
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ksh.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha"
+ ]
+ },
+ "categorytree": "Saachjroppe als Boum",
+ "categorytree-portlet": "Saachjroppe",
+ "categorytree-legend": "Zeijsch de Saachjroppe als ene Boum",
+ "categorytree-desc": "Jangk dorsch de [[Special:CategoryTree|Saachjroppe ier Stroktuhr]].",
+ "categorytree-header": "'''Opjepaßß:'''&nbsp;<small>Dat hee brurr_en JavaSkripp_Aadëijl, dä AJAX häijß. Wänn_De enne besöndoß aale Brauser häß, oddo wänn_De JavaSkripp affjeschalldt häß, dann dëijd_et nit.</small> Jivv_enne Saachjroppe_Name enn, dann krėßß_De fun dä Saachjropp dä iere Ennhalld_alls_enne Boum aanjezëijsch.",
+ "categorytree-category": "Saachjropp:",
+ "categorytree-go": "dä Boum zeije",
+ "categorytree-parents": "Övverjeoodnete Jroppe",
+ "categorytree-mode-label": "Aat:",
+ "categorytree-mode-categories": "nor Saachjroppe",
+ "categorytree-mode-pages": "nomahl Sigge un Saachjroppe, kein Mehdije",
+ "categorytree-mode-all": "alles: nomahl Sigge, Saachjroppe, un Mehdije",
+ "categorytree-collapse": "zosammefallde",
+ "categorytree-expand": "opfallde",
+ "categorytree-empty-bullet": "►<!-- https://phabricator.wikimedia.org/T141238 -->",
+ "categorytree-member-counts": "do dren {{PLURAL:$1|{{PLURAL:$4|sin|es|es}} ein Ungerjrupp|sin $1 Ungerjruppe|es kein Ungerjrupp}}, {{PLURAL:$2|ein Sigg|$2 Sigge|kein Sigg}}, un {{PLURAL:$3|ein Datei|$3 Dateie|kein Dateie}}, zosamme {{PLURAL:$4|ein Saach|$4 Saache|och nix}}",
+ "categorytree-num-categories": "$1&nbsp;J",
+ "categorytree-num-pages": "$1&nbsp;S",
+ "categorytree-num-files": "$1&nbsp;D",
+ "categorytree-num-empty": "läddisch",
+ "categorytree-load": "lade",
+ "categorytree-loading": "am lade…",
+ "categorytree-nothing-found": "nix jefonge",
+ "categorytree-no-subcategories": "kein Ungerjruppe",
+ "categorytree-no-parent-categories": "kein övverje'ohdnete Saachjroppe",
+ "categorytree-no-pages": "kein Sigge un kein Ungerjruppe",
+ "categorytree-not-found": "Han di Saachjropp „<strong>$1</strong>“ nit jefonge.",
+ "categorytree-error": "Problem beim Date Lade",
+ "categorytree-retry": "Bess_esu joot un donn et noh enem Moment norr_ens probeere",
+ "apihelp-categorytree-description": "Enträhne Moduhl för et Zohsazprojramm !!FUZZYY!!CategoryTree",
+ "apihelp-categorytree-param-category": "De Övverschreff, em Appachtemanng vun de Saachjroppe. Wann de Saachjropp aanjejovve es, övverjom_mer se.",
+ "apihelp-categorytree-param-options": "De Enschtällonge för der CategoryTree constructor. Dadd es e Objägg em <i lang=\"en\" xml:lang=\"en\" dir=\"ltr\" title=\"JavaScript Object Notation\">JSON</i>-Fommaht. Der Schtanndat för de Enschtällong „<var lang=\"en\" xml:lang=\"en\" dir=\"ltr\">depth</var>“ es „<kbd lang=\"en\" xml:lang=\"en\" dir=\"ltr\">1</kbd>“."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ku-latn.json b/www/wiki/extensions/CategoryTree/i18n/ku-latn.json
new file mode 100644
index 00000000..afa07e4b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ku-latn.json
@@ -0,0 +1,31 @@
+{
+ "@metadata": {
+ "authors": [
+ "Erdal Ronahi",
+ "George Animal",
+ "Ghybu",
+ "Gomada",
+ "Welathêja",
+ "Bikarhêner"
+ ]
+ },
+ "categorytree": "Dara kategoriyan",
+ "categorytree-portlet": "Kategorî",
+ "categorytree-legend": "Dara kategoriyan nîşan bide",
+ "categorytree-category": "Kategorî",
+ "categorytree-go": "Darê nîşan bide",
+ "categorytree-mode-categories": "tenê kategoriyan",
+ "categorytree-mode-all": "hemû rûpel",
+ "categorytree-collapse": "bigre",
+ "categorytree-expand": "veke",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 R",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "vala",
+ "categorytree-load": "bar bike",
+ "categorytree-loading": "tê barkirin",
+ "categorytree-nothing-found": "ti tişt nehate dîtin",
+ "categorytree-no-subcategories": "binkategorî tune",
+ "categorytree-no-pages": "ne rûpelek an jî binkategoriyek",
+ "categorytree-not-found": "Kategorîya <i>$1</i> nehate dîtin"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kum.json b/www/wiki/extensions/CategoryTree/i18n/kum.json
new file mode 100644
index 00000000..b3ec33a0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kum.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arsenekoumyk"
+ ]
+ },
+ "categorytree-expand": "генглешдирмек",
+ "categorytree-member-counts": "Ичинде {{PLURAL:$1|1 субкатегория|$1 субкатегориялар}}, {{PLURAL:$2|1 сагьифа|$2 сагьифалар}}, ва {{PLURAL:$3|1 саплам|$3 саплам}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 С"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/kw.json b/www/wiki/extensions/CategoryTree/i18n/kw.json
new file mode 100644
index 00000000..298105ec
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/kw.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kernoweger",
+ "Kw-Moon",
+ "Nrowe"
+ ]
+ },
+ "categorytree-portlet": "Klassys",
+ "categorytree-category": "Klass:",
+ "categorytree-mode-all": "keniver folen",
+ "categorytree-expand": "efani",
+ "categorytree-member-counts": "Ynno {{PLURAL:$1|1 isglass|$1 isglass}}, {{PLURAL:$2|1 folen|$2 folen}}, ha {{PLURAL:$3|1 restren|$3 restren}}",
+ "categorytree-num-categories": "$1 k",
+ "categorytree-num-pages": "$1 f",
+ "categorytree-num-files": "$1 r"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ky.json b/www/wiki/extensions/CategoryTree/i18n/ky.json
new file mode 100644
index 00000000..ef3af2a4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ky.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chorobek",
+ "Janatkg"
+ ]
+ },
+ "categorytree": "Категориялар бутагы",
+ "categorytree-portlet": "Категориялар",
+ "categorytree-legend": "Категориялардын бутагын көргөз",
+ "categorytree-desc": "[[Special:CategoryTree|category structure]]динамикада көрсөт",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Бутакты көргөз",
+ "categorytree-parents": "Башкы категория",
+ "categorytree-mode-categories": "Категориялар гана",
+ "categorytree-mode-pages": "файлдардан тышкары",
+ "categorytree-mode-all": "баардык барактар",
+ "categorytree-collapse": "бүктө",
+ "categorytree-expand": "жаюу",
+ "categorytree-member-counts": "{{PLURAL:$1|1 ички категорияны|$1 ички категорияларды}}, {{PLURAL:$2|1 баракты|$2 баракты }}, жана {{PLURAL:$3|1 файлды|$3 файлды}} камтыйт",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Б",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "бош",
+ "categorytree-load": "жүктө",
+ "categorytree-loading": "жүктөлүүдөө",
+ "categorytree-nothing-found": "эч нерсе табылган жок",
+ "categorytree-no-subcategories": "ички категориялар табылган жок",
+ "categorytree-no-parent-categories": "Башкы категориялар табылган жок",
+ "categorytree-no-pages": "макалалар же баш ийген категориялар жок",
+ "categorytree-not-found": "<i>$1</i> Категориясы табылган жок",
+ "categorytree-error": "Маалымат жүктөөдө ката кетти",
+ "categorytree-retry": "Кичине күтүп туруп, жаңы аракет кылыңыз"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/la.json b/www/wiki/extensions/CategoryTree/i18n/la.json
new file mode 100644
index 00000000..d0b54248
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/la.json
@@ -0,0 +1,32 @@
+{
+ "@metadata": {
+ "authors": [
+ "UV",
+ "Lesgles"
+ ]
+ },
+ "categorytree": "Categoriarum arbor",
+ "categorytree-portlet": "Categoriae",
+ "categorytree-legend": "Categoriarum arborem monstrare",
+ "categorytree-header": "Titulum categoriae inscribe ad categoriam hanc quasi arborem videndum. JavaScript et AJAX necesse sunt. Si navigatrum veterrimum habes vel si JavaScript potestatem non fecisti, hac pagina non uti poteris.",
+ "categorytree-category": "Categoria",
+ "categorytree-go": "Arborem monstrare",
+ "categorytree-parents": "Parentes",
+ "categorytree-mode-categories": "modo categoriae",
+ "categorytree-mode-pages": "paginae nisi fasciculi",
+ "categorytree-mode-all": "omnes paginae",
+ "categorytree-collapse": "collabi",
+ "categorytree-expand": "dilatare",
+ "categorytree-member-counts": "continet {{PLURAL:$1|1 subcategoriam|$1 subcategorias}}, {{PLURAL:$2|1 paginam|$2 paginas}} et {{PLURAL:$3|1 fasciculum|$3 fasciculos}}",
+ "categorytree-num-categories": "$1 cat.",
+ "categorytree-num-pages": "$1 {{PLURAL:$1|p.|pp.}}",
+ "categorytree-num-files": "$1 fasc.",
+ "categorytree-num-empty": "vacua",
+ "categorytree-load": "depromere",
+ "categorytree-loading": "depromens…",
+ "categorytree-nothing-found": "nullum inventum",
+ "categorytree-no-subcategories": "nullae subcategoriae",
+ "categorytree-no-parent-categories": "nullae supercategoriae",
+ "categorytree-no-pages": "nec paginae nec subcategoriae",
+ "categorytree-not-found": "Categoria <i>$1</i> non inventa"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lad.json b/www/wiki/extensions/CategoryTree/i18n/lad.json
new file mode 100644
index 00000000..089bf5ac
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lad.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jewbask",
+ "Maor X",
+ "Runningfridgesrule",
+ "Universal Life",
+ "StevenJ81"
+ ]
+ },
+ "categorytree": "Árvole de katēgorías",
+ "categorytree-portlet": "Katēggorías",
+ "categorytree-legend": "Amostrar el árvole de katēggorías",
+ "categorytree-category": "Kategoría:",
+ "categorytree-go": "Amostrar el árvole",
+ "categorytree-parents": "Parientes",
+ "categorytree-mode-categories": "sólo kategorías",
+ "categorytree-mode-pages": "ojas, egzepto dossias",
+ "categorytree-mode-all": "todas las hojas",
+ "categorytree-collapse": "eskonder",
+ "categorytree-expand": "amostrar",
+ "categorytree-member-counts": "kontiene {{PLURAL:$1|1 basho-kateggoria|$1 basho-kateggorias}}, {{PLURAL:$2|1 oja|$2 ojas}}, i {{PLURAL:$3|1 dossia|$3 dossias}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 O",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "vazia",
+ "categorytree-load": "cargar",
+ "categorytree-loading": "cargando...",
+ "categorytree-nothing-found": "Eskuza, no ankontramos nada",
+ "categorytree-no-subcategories": "si basho-kateggorias",
+ "categorytree-no-parent-categories": "sin kategorias de enriva",
+ "categorytree-no-pages": "sin ojas ni basho-kateggorias"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lag.json b/www/wiki/extensions/CategoryTree/i18n/lag.json
new file mode 100644
index 00000000..495587d4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lag.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Baba Tabita"
+ ]
+ },
+ "categorytree-num-pages": "$1 Ʉk"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lb.json b/www/wiki/extensions/CategoryTree/i18n/lb.json
new file mode 100644
index 00000000..6c00aecb
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lb.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kaffi",
+ "Robby",
+ "Soued031"
+ ]
+ },
+ "categorytree": "Struktur vun de Kategorien",
+ "categorytree-portlet": "Kategorien",
+ "categorytree-legend": "Weis Kategoriestruktur",
+ "categorytree-desc": "Gadget deen op Ajax opgebaut ass fir d'[[Special:CategoryTree|Kategorie-Struktur]] vun enger Wiki duerzestellen",
+ "categorytree-header": "Gitt den Numm vun enger Kategorie an, fir hiren Inhalt als Bam-Struktur ze gesinn. (Benotzt JavaScript,)",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Struktur weisen",
+ "categorytree-parents": "Uewerkategorien",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "nëmme Kategorien",
+ "categorytree-mode-pages": "Säiten ausser Fichieren",
+ "categorytree-mode-all": "all Säiten",
+ "categorytree-collapse": "Verstoppen",
+ "categorytree-expand": "Opklappen",
+ "categorytree-member-counts": "besteet aus {{PLURAL:$1|1 Ënnerkategorie|$1 Ënnerkategorien}}, {{PLURAL:$2|1 Säit|$1 Säiten}}, an {{PLURAL:$3|1 Fichier|$3 Fichieren}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "eidel",
+ "categorytree-load": "lueden",
+ "categorytree-loading": "lueden …",
+ "categorytree-nothing-found": "Näischt fonnt",
+ "categorytree-no-subcategories": "Keng Ënnerkategorien",
+ "categorytree-no-parent-categories": "Keng Iwwerkategorien",
+ "categorytree-no-pages": "Keng Säiten oder Ënnerkategorien",
+ "categorytree-not-found": "Kategorie ''$1'' net fonnt",
+ "categorytree-error": "Problem beim luede vun den Donneeën.",
+ "categorytree-retry": "Waart w.e.g. een Ament a probéiert dann nach eng Kéier."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lez.json b/www/wiki/extensions/CategoryTree/i18n/lez.json
new file mode 100644
index 00000000..9014cb43
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lez.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Migraghvi",
+ "Namik",
+ "Soul Train"
+ ]
+ },
+ "categorytree": "Категориядин ттар",
+ "categorytree-portlet": "Категорияр",
+ "categorytree-legend": "Категориядин ттар къалурун",
+ "categorytree-category": "Klватlалар:",
+ "categorytree-go": "Ппарун",
+ "categorytree-parents": "Вини категорияр",
+ "categorytree-mode-categories": "анжах категорияр",
+ "categorytree-mode-pages": "файлар галачиз ччинар",
+ "categorytree-mode-all": "Вири ччинар",
+ "categorytree-collapse": "Алчудрун",
+ "categorytree-expand": "Гегьеншрун",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Ч",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "ичIи",
+ "categorytree-load": "ппарун",
+ "categorytree-loading": "ппарзава",
+ "categorytree-nothing-found": "затIни жагъурнавач",
+ "categorytree-no-subcategories": "агъакатегорияр авайд ттуш"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lfn.json b/www/wiki/extensions/CategoryTree/i18n/lfn.json
new file mode 100644
index 00000000..9ef6b2e6
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lfn.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya",
+ "Katxis",
+ "Cgboeree"
+ ]
+ },
+ "categorytree": "Arbor de categorias",
+ "categorytree-portlet": "Categorias",
+ "categorytree-category": "Categoria:",
+ "categorytree-expand": "estende",
+ "categorytree-member-counts": "Conteninte {{PLURAL:$1|1 sucategoria|$1 sucategorias}}, {{PLURAL:$2|1 paje|$2 pajes}}, e {{PLURAL:$3|1 fix|$3 fixes}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/li.json b/www/wiki/extensions/CategoryTree/i18n/li.json
new file mode 100644
index 00000000..6fff7c1c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/li.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Matthias",
+ "Ooswesthoesbes",
+ "Pahles"
+ ]
+ },
+ "categorytree": "Categorieboum",
+ "categorytree-portlet": "Categorieë",
+ "categorytree-legend": "Categorieboum laote zeen",
+ "categorytree-desc": "AJAX-gebaseerde oetbreijing óm de [[Special:CategoryTree|categoriestructuur]] van 'ne wiki te toeane",
+ "categorytree-header": "Gaef 'ne categorienaam in om de inhaud es 'ne boumstructuur te betrachte. (JavaScript nudig)",
+ "categorytree-category": "Categorie:",
+ "categorytree-go": "Laje",
+ "categorytree-parents": "Baoveligkendje categorië",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "allein categorië",
+ "categorytree-mode-pages": "paazjes behaueve aafbeildinge",
+ "categorytree-mode-all": "alle pazjena's",
+ "categorytree-collapse": "inklappe",
+ "categorytree-expand": "oetklappe",
+ "categorytree-member-counts": "bevat {{PLURAL:$1|éin ondercategorie|$1 ondercategorië}}, {{PLURAL:$2|éin pagina|$2 pagina's}} en {{PLURAL:$3|éin bestand|$3 bestande}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "laeg",
+ "categorytree-load": "laje",
+ "categorytree-loading": "aan 't laje",
+ "categorytree-nothing-found": "Dees categorie haet gein subcategorië.",
+ "categorytree-no-subcategories": "Gein subcategorië.",
+ "categorytree-no-parent-categories": "gein baovecategorië",
+ "categorytree-no-pages": "Gein pazjena's of óngercategorië.",
+ "categorytree-not-found": "Categorie ''$1'' neet gevónje",
+ "categorytree-error": "Perbleem bie 't laje van de gegaeves.",
+ "categorytree-retry": "Wach estebleef effe en perbeer 't den opnuuj.",
+ "apihelp-categorytree-description": "Intern moduul veur de oetbreijing CategoryTree.",
+ "apihelp-categorytree-summary": "Intern moduul veur de oetbreijing CategoryTree.",
+ "apihelp-categorytree-param-category": "Naam in de categorienaamruumde, veurveugsel weurt genegeerd es opgegaove.",
+ "apihelp-categorytree-param-options": "Opties veur de constructeur van CategoryTree es e JSON-objectèk. De optie \"depth\" is standerd ingestèldj gewaore op <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Opties mótten e geljig JSON-objèk zeen."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lij.json b/www/wiki/extensions/CategoryTree/i18n/lij.json
new file mode 100644
index 00000000..e31b8bf8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lij.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Giromin Cangiaxo",
+ "S4b1nuz E.656"
+ ]
+ },
+ "categorytree": "Ærbo de categorie",
+ "categorytree-portlet": "Categorie",
+ "categorytree-legend": "Mostra l'ærbo de categorie",
+ "categorytree-desc": "Vixualizza in moddo dinammico a [[Special:CategoryTree|struttua de categorie]]",
+ "categorytree-header": "Inseisci o nomme de 'na categoria pe veddine i contegnui inte 'na struttua fæta a ærbo. (Ghe voeu JavaScript)",
+ "categorytree-category": "Categoria:",
+ "categorytree-go": "Mostra ærbo",
+ "categorytree-parents": "Categorie superioî",
+ "categorytree-mode-label": "Modalitæ:",
+ "categorytree-mode-categories": "mostra solo e categorie",
+ "categorytree-mode-pages": "tutte e paggine, ecetto i file",
+ "categorytree-mode-all": "tutte e paggine",
+ "categorytree-collapse": "comprimmi",
+ "categorytree-expand": "espandi",
+ "categorytree-member-counts": "a conten {{PLURAL:$1|1 sottocategoria|$1 sottocategorie}}, {{PLURAL:$2|1 pagina|$2 pagine}} e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "voeua",
+ "categorytree-load": "carega",
+ "categorytree-loading": "caregaménto in córso…",
+ "categorytree-nothing-found": "nisciun risultou",
+ "categorytree-no-subcategories": "nisciun-a sottocategoria",
+ "categorytree-no-parent-categories": "nisciun-a soviacategoria",
+ "categorytree-no-pages": "nisciun-a paggina ni sottocategoria",
+ "categorytree-not-found": "Categoria <i>$1</i> non trovâ",
+ "categorytree-error": "Problema into caregamento di dæti.",
+ "categorytree-retry": "Pe piaxei attendi un momento e proeuva torna.",
+ "apihelp-categorytree-description": "Moddulo interno pe l'estenscion CategoryTree.",
+ "apihelp-categorytree-param-category": "Tittolo into namespace categoria, o prefisso o saiâ ignorou se dæto.",
+ "apihelp-categorytree-param-options": "Opçioin pe-o costrutô CategoryTree comme oggetto JSON. L'opçion <var>depth</var> predefinia a l'è <kbd>1</kbd>."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lki.json b/www/wiki/extensions/CategoryTree/i18n/lki.json
new file mode 100644
index 00000000..2f4473b0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lki.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hosseinblue",
+ "Lakzon"
+ ]
+ },
+ "categorytree": "دار ڕِزگ",
+ "categorytree-portlet": "ڕزگەل",
+ "categorytree-legend": "دار ڕزگ نیشۆن دە",
+ "categorytree-desc": "ابزار مبتنی بر AJAX برای نمایش [[Special:CategoryTree|ساختار رده‌های]] یک ویکی",
+ "categorytree-header": "نام رده‌ای را وارد کنید تا محتویات آن به صورت درختی نمایش یابد. توجه کنید که این کار نیاز به قابلیت‌های پیشرفتهٔ جاوااسکریپت موسوم به ای‌جکس دارد. اگر از مرورگری خیلی قدیمی استفاده می‌کنید یا جاوااسکریپت را غیرفعال کرده‌اید، کار نمی‌کند.",
+ "categorytree-category": "ڕِزگ:",
+ "categorytree-go": "نمایش درخت",
+ "categorytree-parents": "ریشه",
+ "categorytree-mode-label": "حالت:",
+ "categorytree-mode-categories": "فقط رده‌ها/ڕِزگةل",
+ "categorytree-mode-pages": "صفحات به جز تصاویر",
+ "categorytree-mode-all": "کؤل(گشت)وەڵگەل",
+ "categorytree-collapse": "آشاردِن",
+ "categorytree-expand": "کلنگاکردن/گسترش",
+ "categorytree-member-counts": " شامل {{PLURAL:$1|1 ژئر رده$1 |ژئر رده}}, {{PLURAL:$2|1وۀلگۀ$2|وۀلگۀ}},\n وۀ {{PLURAL:$3|1 فایل $3| فایل}}",
+ "categorytree-num-categories": "$1 ر",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 پ",
+ "categorytree-num-empty": "خالی/پةتی",
+ "categorytree-load": "بارگیری",
+ "categorytree-loading": "در حال بارگیری...",
+ "categorytree-nothing-found": "هیچ‌چیز یافت نشد.",
+ "categorytree-no-subcategories": "هیچ زیررده‌ای ندارد.",
+ "categorytree-no-parent-categories": "فاقد ردهٔ بالاتر",
+ "categorytree-no-pages": "هیچ صفحه یا زیررده‌ای ندارد.",
+ "categorytree-not-found": "ردهٔ <i>$1</i> یافت نشد",
+ "categorytree-error": "اشکال در دریافت اطلاعات.",
+ "categorytree-retry": "لطفاً کمی صبر کنید و دوباره امتحان کنید."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lmo.json b/www/wiki/extensions/CategoryTree/i18n/lmo.json
new file mode 100644
index 00000000..75248c71
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lmo.json
@@ -0,0 +1,27 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dakrismeno"
+ ]
+ },
+ "categorytree": "Àlbur di categurij",
+ "categorytree-portlet": "Categurij",
+ "categorytree-legend": "Fàm ved l'àlbur di categurij",
+ "categorytree-category": "Categuria:",
+ "categorytree-go": "Mustra l'àlbur",
+ "categorytree-parents": "Categurij süperiur",
+ "categorytree-mode-categories": "mustra dumà i categurij",
+ "categorytree-mode-pages": "tüt i paginn, fö che i sumejanz",
+ "categorytree-mode-all": "tüt i paginn",
+ "categorytree-collapse": "sara sü",
+ "categorytree-expand": "slarga",
+ "categorytree-load": "carega",
+ "categorytree-loading": "adree a caregà...",
+ "categorytree-nothing-found": "nissün resültaa",
+ "categorytree-no-subcategories": "nissüna suta-categuria",
+ "categorytree-no-parent-categories": "nissüna categuria süperiur",
+ "categorytree-no-pages": "mía de paginn o de suta-categurij",
+ "categorytree-not-found": "Categuria <i>$1</i> mía truada",
+ "categorytree-error": "Prublema cun 'l caregament di dati.",
+ "categorytree-retry": "Per piasè, specia un mument e pö pröva ancamò."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ln.json b/www/wiki/extensions/CategoryTree/i18n/ln.json
new file mode 100644
index 00000000..73255925
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ln.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eruedin"
+ ]
+ },
+ "categorytree-portlet": "Ndéngé",
+ "categorytree-category": "Katégoli:",
+ "categorytree-mode-all": "Nkásá ínsɔ",
+ "categorytree-no-subcategories": "Ndéngé-bǎna té"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lo.json b/www/wiki/extensions/CategoryTree/i18n/lo.json
new file mode 100644
index 00000000..93068096
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lo.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Passawuth",
+ "Aefgh39622"
+ ]
+ },
+ "categorytree": "ໂຄງສ້າງໝວດ",
+ "categorytree-legend": "ສະແດງແຜນຜັງໝວດ",
+ "categorytree-header": "ພິມຊື່ໝວດໃສ່ ເພື່ອເບິ່ງໂຄງສ້າງມັນ. ຟັງຊັງຕ້ອງການໃຊ້ AJAX ໃນ JavaScript. ຖ້າ ທ່ານ ໃຊ້ໂປຣແກຣມທ່ອງເວັບເກົ່າ ຫຼື ບໍ່ອະນຸຍາດ JavaScript, ມັນກໍ່ຈະບໍ່ເຮັດວຽກ.",
+ "categorytree-category": "ໝວດ",
+ "categorytree-go": "ສະແດງໂຄງສ້າງ",
+ "categorytree-parents": "ໝວດແມ່",
+ "categorytree-mode-categories": "ໝວດເທົ່ານັ້ນ",
+ "categorytree-mode-pages": "ໜ້າ ນອກຈາກ ໜ້າຮູບ",
+ "categorytree-mode-all": "ທຸກໆໜ້າ",
+ "categorytree-collapse": "ຫຍໍ້ເຂົ້າ",
+ "categorytree-expand": "ຂະຫຍາຍອອກ",
+ "categorytree-member-counts": "ມີ {{PLURAL:$1|1 ໝວດຍ່ອຍ|$1 ໝວດຍ່ອຍ}}, {{PLURAL:$2|1 ໜ້າ|$2 ໜ້າ}}, ແລະ {{PLURAL:$3|1 ໄຟລ໌|$3 ໄຟລ໌}}",
+ "categorytree-num-categories": "$1 ມ",
+ "categorytree-num-pages": "$1 ນ",
+ "categorytree-load": "ໂຫຼດ",
+ "categorytree-loading": "ພວມໂຫຼດ",
+ "categorytree-nothing-found": "ບໍ່ພົບຫຍັງ",
+ "categorytree-no-subcategories": "ບໍ່ມີໝວດຍ່ອຍ",
+ "categorytree-no-pages": "ບໍ່ມີໜ້າ ຫຼື ໝວດຍ່ອຍ",
+ "categorytree-not-found": "ບໍ່ເຫັນ",
+ "categorytree-error": "ການໂຫຼດຂໍ້ມູນມີປັນຫາ",
+ "categorytree-retry": "ກະລຸນາຮອສັກຄູ່ ແລ້ວລອງໂຫຼດໃໝ່"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lrc.json b/www/wiki/extensions/CategoryTree/i18n/lrc.json
new file mode 100644
index 00000000..b4892bde
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lrc.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bonevarluri",
+ "Mogoeilor"
+ ]
+ },
+ "categorytree": "دار دسه",
+ "categorytree-portlet": "دسه یا",
+ "categorytree-legend": "دار دسه نه نشو بیئه",
+ "categorytree-desc": "وه شلک جمشدار [[ویجه:دار دسه|ساختار دسه]] ناوجوری بک",
+ "categorytree-header": "یه گل نوم دسه سی دیئن چیا مئن وه شکل یه سازه داری وارد بکید.\nبنیسید که که یه تاوع جاوا اسکریپت پیشکرده که چی آجاکس اشناخته با میها.\nار جاگردتو فره قدیمیه،یا جاوا اسکریپت فعال نئ،وه کار نمی که.",
+ "categorytree-category": "دسه:",
+ "categorytree-go": "وه شلك دار نشون بيه",
+ "categorytree-parents": "ریشه",
+ "categorytree-mode-label": "مد:",
+ "categorytree-mode-categories": "فقط دسه یا",
+ "categorytree-mode-pages": "بلگیا وه جؤز فایلیا",
+ "categorytree-mode-all": "همه بلگيا",
+ "categorytree-collapse": "جم كردن",
+ "categorytree-expand": "گٱپ کلون کردن",
+ "categorytree-member-counts": "وه د ور گرته {{PLURAL:$1|1 زیردسه|$1 زیردسه یا}}, {{PLURAL:$2|1 بلگه|$2 بلگه}}, و {{PLURAL:$3|1 جانیا|$3 جانیایا}} ئه",
+ "categorytree-num-categories": "$1 س",
+ "categorytree-num-pages": " $1 پ",
+ "categorytree-num-files": " $1 ف",
+ "categorytree-num-empty": "حالی",
+ "categorytree-load": "سوۋار كرد",
+ "categorytree-loading": "د حالت سوار كرد",
+ "categorytree-nothing-found": "هيچی پيدا نبی",
+ "categorytree-no-subcategories": "بی زيردسه يا",
+ "categorytree-no-parent-categories": "نه دسه یا ایسنی",
+ "categorytree-no-pages": "نه بلگه ای نه زیر دسه ای",
+ "categorytree-not-found": "دسه <i>$1</i> دیاری نکرد",
+ "categorytree-error": "مشگل د سواركرد داديا",
+ "categorytree-retry": "لطفا يه دم صبر بكيد و هنی تلاش بكيد"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lt.json b/www/wiki/extensions/CategoryTree/i18n/lt.json
new file mode 100644
index 00000000..004fc31a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lt.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eitvys200",
+ "Garas",
+ "Hugo.arg",
+ "Tomasdd",
+ "Zygimantus",
+ "Manvydasz"
+ ]
+ },
+ "categorytree": "Kategorijų medis",
+ "categorytree-portlet": "Kategorijos",
+ "categorytree-legend": "Rodyti kategorijų medį",
+ "categorytree-desc": "Dinamiškai naršykite [[Special:CategoryTree|kategorijų struktūroje]]",
+ "categorytree-header": "Įveskite kategorijos pavadinimą, kad pamatytumėte jos turinį kaip medžio struktūrą. (Reikia JavaScript.)",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Rodyti medį",
+ "categorytree-parents": "Aukštesnio lygio kategorija",
+ "categorytree-mode-label": "Režimas:",
+ "categorytree-mode-categories": "tik kategorijos",
+ "categorytree-mode-pages": "puslapiai išskyrus paveikslėlius",
+ "categorytree-mode-all": "visi puslapiai",
+ "categorytree-collapse": "suskleisti",
+ "categorytree-expand": "išskleisti",
+ "categorytree-member-counts": "turi $1 {{PLURAL:$1|subkategoriją|subkategorijas|subkategorijų}}, $2 {{PLURAL:$2|puslapį|puslapius|puslapių}}, ir $3 {{PLURAL:$3|rinkmeną|rinkmenas|rinkmenų}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tuščia",
+ "categorytree-load": "įkelti",
+ "categorytree-loading": "įkeliama...",
+ "categorytree-nothing-found": "nieko nerasta",
+ "categorytree-no-subcategories": "nėra jokių subkategorijų",
+ "categorytree-no-parent-categories": "jokių aukštesniojo lygio kategorijų",
+ "categorytree-no-pages": "jokių puslapių ar subkategorijų",
+ "categorytree-not-found": "Kategorija <i>$1</i> nerasta",
+ "categorytree-error": "Duomenų įkėlimo problema.",
+ "categorytree-retry": "Palaukite šiek tiek ir bandykite iš naujo.",
+ "apihelp-categorytree-description": "CategoryTree plėtinio vidinis modulis.",
+ "apihelp-categorytree-param-options": "Nustatymai skirti CategoryTree konstruktoriui, kaip JSON objektui. Nustatymo <var>depth</var> numatytoji reikšmė yra <kbd>1</kbd>."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ltg.json b/www/wiki/extensions/CategoryTree/i18n/ltg.json
new file mode 100644
index 00000000..cc60f5bc
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ltg.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dark Eagle"
+ ]
+ },
+ "categorytree": "Kategoreju kūks",
+ "categorytree-portlet": "Kategorejis",
+ "categorytree-legend": "Paruodeit kategoreju kūku",
+ "categorytree-desc": "Dinamiski vada [[Special:CategoryTree|kategoreju strukturu]]",
+ "categorytree-category": "Kategoreja:",
+ "categorytree-go": "Paruodeit kūku",
+ "categorytree-parents": "Augstuokuo leidzīņa kategorejis",
+ "categorytree-mode-categories": "kategorejis viņ",
+ "categorytree-mode-pages": "atskaitūt failus",
+ "categorytree-mode-all": "vysys puslopys",
+ "categorytree-collapse": "nūglobuot",
+ "categorytree-expand": "ruodeit",
+ "categorytree-member-counts": "globuo {{PLURAL:$1|1 zamkategoreju|$1 zamkategorejis}}, {{PLURAL:$2|1 puslopu|$2 puslopys}}, i {{PLURAL:$3|1 failu|$3 failus}}",
+ "categorytree-load": "atsasyuteit",
+ "categorytree-loading": "nūteik atsasyuteišona...",
+ "categorytree-nothing-found": "nikas natyka atrast",
+ "categorytree-no-subcategories": "navā zamkategoreju",
+ "categorytree-no-parent-categories": "navā augstuokuo leidzīņa kategoreju",
+ "categorytree-no-pages": "navā puslopu ci zamkategoreju",
+ "categorytree-not-found": "Kategoreja <i>$1</i> navā savaicuota",
+ "categorytree-error": "Failu atsasyuteišonys problema.",
+ "categorytree-retry": "Lyudzams drupeit pagaidi i raugi vēļ."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lus.json b/www/wiki/extensions/CategoryTree/i18n/lus.json
new file mode 100644
index 00000000..d54a696c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lus.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "RMizo"
+ ]
+ },
+ "categorytree": "Inpàwlchhàwnna",
+ "categorytree-portlet": "Pawlte",
+ "categorytree-legend": "Pawl kung tihlanna",
+ "categorytree-desc": "[[Special:CategoryTree|Pawl inkungkaihdàn]] fankualna",
+ "categorytree-header": "Thingzar anga tihlan i duh chuan pawl hming zawnah hmet rawh.\nHei hian JavaScript hnathawh changkang AJAX a mamawh tih hria ang che.\nRangpuifanna hlui tak i hma emaw, JavaScript tihthih a nih emaw chuan a en theih loh vang.",
+ "categorytree-category": "Pawl:",
+ "categorytree-go": "Küng tihlanna",
+ "categorytree-parents": "Pawlpui",
+ "categorytree-mode-categories": "pawlte chauh",
+ "categorytree-mode-pages": "taksa tiam loh phekte chauh",
+ "categorytree-mode-all": "phek zawng zawngte",
+ "categorytree-collapse": "thlehna",
+ "categorytree-expand": "pharhna",
+ "categorytree-member-counts": "Hetah hian {{PLURAL:$1|pawlpeng 1|pawlpeng $1}}, {{PLURAL:$2|phek 1|phek $2}}, leh {{PLURAL:$3|taksa 1|taksa $3}} a awm",
+ "categorytree-num-categories": "P $1",
+ "categorytree-num-pages": "Ph $1",
+ "categorytree-num-files": "Tks $1",
+ "categorytree-num-empty": "ruak",
+ "categorytree-load": "hlankaina",
+ "categorytree-loading": "nghak lawks...",
+ "categorytree-nothing-found": "engmah hmuh a ni lo",
+ "categorytree-no-subcategories": "pawlpeng awm lo",
+ "categorytree-no-parent-categories": "pawlpui awm lo",
+ "categorytree-no-pages": "phek leh pawlpeng awm lo",
+ "categorytree-not-found": "Pawl <i>$1</i> hmuh a ni lo",
+ "categorytree-error": "Hriatna hlankai hlawhchham",
+ "categorytree-retry": "Nghak lawk la tum nawn leh rawh"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/luz.json b/www/wiki/extensions/CategoryTree/i18n/luz.json
new file mode 100644
index 00000000..6f00d2e4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/luz.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "علی ساکی لرستانی"
+ ]
+ },
+ "categorytree-expand": "ڤا كردن",
+ "categorytree-member-counts": "شامل {{PLURAL:$1|1 دوٙمین شاخە|$1 دوٙمین شاخە یل}}, {{PLURAL:$2|1 بألگە|$2 بألگل}}, ڤ {{PLURAL:$3|1 فایل|$3 فایلل}}",
+ "categorytree-num-categories": "$1 د",
+ "categorytree-num-pages": "$1 ب",
+ "categorytree-num-files": "$1 ف"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lv.json b/www/wiki/extensions/CategoryTree/i18n/lv.json
new file mode 100644
index 00000000..11e902be
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lv.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "GreenZeb",
+ "Marozols",
+ "Papuass",
+ "Xil",
+ "Yyy"
+ ]
+ },
+ "categorytree": "Kategoriju koks",
+ "categorytree-portlet": "Kategorijas",
+ "categorytree-legend": "Rādīt kategoriju koku",
+ "categorytree-desc": "AJAX bāzēts ''gadget'', kuru lieto lai attēlotu wiki [[Special:CategoryTree|kategoriju struktūru]]",
+ "categorytree-header": "Ievadi kategorijas nosaukumu, lai apskatītu tās saturu kā kokveida struktūru (nepieciešams JavaScript).",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Parādīt koku",
+ "categorytree-parents": "Augšējā līmeņa kategorijas",
+ "categorytree-mode-label": "Režīms:",
+ "categorytree-mode-categories": "tikai kategorijas",
+ "categorytree-mode-pages": "lapas (bez attēlu lapām)",
+ "categorytree-mode-all": "visas lapas",
+ "categorytree-collapse": "sakļaut",
+ "categorytree-expand": "izvērst",
+ "categorytree-member-counts": "satur {{PLURAL:$1|$1 apakškategorijas|1 apakškategoriju|$1 apakškategorijas}}, {{PLURAL:$2|$2 lapas|1 lapu|$2 lapas}}, un {{PLURAL:$3|$3 failus|1 failu|$3 failus}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tukšs",
+ "categorytree-load": "ielādēt",
+ "categorytree-loading": "ielādējas...",
+ "categorytree-nothing-found": "neko neatrada",
+ "categorytree-no-subcategories": "nav apakškategoriju",
+ "categorytree-no-parent-categories": "nav augšējā līmeņa kategoriju",
+ "categorytree-no-pages": "nav ne lapu, ne apakškategoriju",
+ "categorytree-not-found": "Kategorija <i>$1</i> netika atrasta",
+ "categorytree-error": "Problēma ar datu ielādi.",
+ "categorytree-retry": "Pagaidi mazliet un mēģini vēlreiz."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lzh.json b/www/wiki/extensions/CategoryTree/i18n/lzh.json
new file mode 100644
index 00000000..30a1cf7e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lzh.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "StephDC",
+ "Davidzdh",
+ "SolidBlock",
+ "Muhebbet"
+ ]
+ },
+ "categorytree-portlet": "類",
+ "categorytree-category": "類:",
+ "categorytree-expand": "展",
+ "categorytree-member-counts": "存$1子類,$2頁,$3文",
+ "categorytree-num-categories": "$1 類",
+ "categorytree-num-pages": "$1 頁",
+ "categorytree-num-files": "$1 檔"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/lzz.json b/www/wiki/extensions/CategoryTree/i18n/lzz.json
new file mode 100644
index 00000000..57fa2415
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/lzz.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Velg"
+ ]
+ },
+ "categorytree-num-pages": "$1 B"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mai.json b/www/wiki/extensions/CategoryTree/i18n/mai.json
new file mode 100644
index 00000000..5d77c14b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mai.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "बिप्लब आनन्द"
+ ]
+ },
+ "categorytree": "संवर्गवृक्ष",
+ "categorytree-portlet": "श्रेणीसभ",
+ "categorytree-legend": "संवर्ग वृक्ष देखाउ",
+ "categorytree-desc": "विकि के [[Special:CategoryTree|संवर्ग संरचना]] देखु",
+ "categorytree-category": "संवर्ग",
+ "categorytree-go": "वृक्ष देखाबी",
+ "categorytree-parents": "पालक",
+ "categorytree-mode-label": "मोड:",
+ "categorytree-mode-categories": "मात्र संवर्ग",
+ "categorytree-mode-pages": "सञ्चिकासभके अतिरिक्त पृष्ठ",
+ "categorytree-mode-all": "सभटा पन्ना",
+ "categorytree-collapse": "भखड़ाउ",
+ "categorytree-expand": "बढाबी",
+ "categorytree-member-counts": "एहिमे {{PLURAL:$1|एकटा उपश्रेणी|$1 उपश्रेणिसभ}}, {{PLURAL:$2|एकटा पृष्ठ|$2 पृष्ठ}}, आर {{PLURAL:$3|एकटा फाइल|$3 फाइलसभ}} अछि।",
+ "categorytree-num-categories": "$1 श्र",
+ "categorytree-num-pages": "$1 पृ",
+ "categorytree-num-files": "$1 फा",
+ "categorytree-num-empty": "खाली",
+ "categorytree-load": "लादू",
+ "categorytree-loading": "उपारोपण भऽ रहल अछि...",
+ "categorytree-nothing-found": "कुछो नै भेटल",
+ "categorytree-no-subcategories": "उपसंवर्ग नै अछि",
+ "categorytree-no-parent-categories": "कोनो जनक श्रेणिसभ नै अछि",
+ "categorytree-no-pages": "कोनो पृष्ठ आ उपसंवर्ग नै अछि",
+ "categorytree-not-found": "श्रेणी <i>$1</i> नै भेटल",
+ "categorytree-error": "डाटा लोड करए मे समस्या।",
+ "categorytree-retry": "कृपया किछु समय पश्चात पुनः प्रयास करु।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/map-bms.json b/www/wiki/extensions/CategoryTree/i18n/map-bms.json
new file mode 100644
index 00000000..5bddf9f0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/map-bms.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "StefanusRA"
+ ]
+ },
+ "categorytree": "Uwit kategori",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Tidhokna uwit kategori",
+ "categorytree-desc": "Gadget sing dasare AJAX nggo nidhokna [[Special:CategoryTree|category structure]] salah siji wiki",
+ "categorytree-header": "Lebokna jeneng kategori kanggo deleng isiné minangka sawijining wujud uwit.\nMangga diwigatèkaké nek fitur kiye merlokna fungsionalitas JavaScript canggih sing diarani AJAX.\nAngger Rika panjlajah wèbé kalebu vèrsi lawas, utawa fitur JavaScript dipatèni, fungsi kiye ora teyeng dilakokna.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Tuduhna uwit",
+ "categorytree-parents": "Kategori sing luwih dhuwur",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "kategori thok",
+ "categorytree-mode-pages": "kaca kajaba gambar",
+ "categorytree-mode-all": "kabèh kaca",
+ "categorytree-collapse": "umpetna",
+ "categorytree-expand": "tidhokna",
+ "categorytree-member-counts": "ngandhut {{PLURAL:$1|1 subkategori|$1 subkategori}}, {{PLURAL:$2|1 kaca|$2 kaca}}, lan {{PLURAL:$3|1 gambar|$3 gambar}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "kosong",
+ "categorytree-load": "unggah",
+ "categorytree-loading": "lagi ngunggahna…",
+ "categorytree-nothing-found": "ora ketemu",
+ "categorytree-no-subcategories": "ora ana subkategori",
+ "categorytree-no-parent-categories": "ora ana kategori indhuk",
+ "categorytree-no-pages": "ora ana kaca utawa subkategori",
+ "categorytree-not-found": "Kategori <i>$1</i> ora ketemu",
+ "categorytree-error": "Ana masalah dong lagi ngunggahna data.",
+ "categorytree-retry": "Tulung dienteni sedela lan dijajal maning."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mg.json b/www/wiki/extensions/CategoryTree/i18n/mg.json
new file mode 100644
index 00000000..f0d415ac
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mg.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jagwar"
+ ]
+ },
+ "categorytree": "Fisampanan'ny sokajy",
+ "categorytree-portlet": "Sokajy",
+ "categorytree-legend": "Aseho ny hazon-tsokajy",
+ "categorytree-category": "Sokajy :",
+ "categorytree-go": "hijery ny hazon-tsokajy",
+ "categorytree-parents": "renisokajy",
+ "categorytree-mode-categories": "sokajy ihany",
+ "categorytree-mode-pages": "pejy tsy misy sary",
+ "categorytree-expand": "hanitatra",
+ "categorytree-member-counts": "Ahitana {{PLURAL:$1|zana-tsokajy iray|zanatsokajy $1}}",
+ "categorytree-num-categories": "$1 Skj",
+ "categorytree-num-pages": "$1 Pj",
+ "categorytree-num-files": "$1 Rkt"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mhr.json b/www/wiki/extensions/CategoryTree/i18n/mhr.json
new file mode 100644
index 00000000..b8d37017
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mhr.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Санюн Вадик"
+ ]
+ },
+ "categorytree-expand": "почаш",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/min.json b/www/wiki/extensions/CategoryTree/i18n/min.json
new file mode 100644
index 00000000..dd4533fa
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/min.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Iwan Novirion"
+ ]
+ },
+ "categorytree": "Pohon kategori",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Tunjuakan pohon kategori",
+ "categorytree-desc": "Manavigasi sacaro dinamih [[Special:CategoryTree|struktur kategori]]",
+ "categorytree-header": "Masuakan suatu kategori untuak mancaliak isinyo dalam bantuak sruktur pohon.\nParalu diparatian koq fitur ko haruih ado dukuangan JavaScript tingkek lanjuik nan dikenal sabagai AJAX.\nJikok Sanak manggunoan paramban web versi lamo, atau mamatian fungsi JavaScript, fitur ko indak dapek bajalan.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Tunjuakan",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "hanyo kategori",
+ "categorytree-mode-pages": "laman salain berkas",
+ "categorytree-mode-all": "kasado laman",
+ "categorytree-collapse": "tutuik",
+ "categorytree-expand": "bukak",
+ "categorytree-member-counts": "Barisi {{PLURAL:$1|$1 subkategori}}, {{PLURAL:$2|$2 laman}}, jo {{PLURAL:$3|$3 berkas}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "kosong",
+ "categorytree-load": "muek",
+ "categorytree-loading": "mamuek...",
+ "categorytree-nothing-found": "indak basobok",
+ "categorytree-no-subcategories": "indak ado subkategori",
+ "categorytree-no-pages": "indak ado laman atau subkategori",
+ "categorytree-not-found": "Kategori <i>$1</i> indak basobok",
+ "categorytree-error": "Problem mamuek data.",
+ "categorytree-retry": "Tunggu sabanta dan cubo lai."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mk.json b/www/wiki/extensions/CategoryTree/i18n/mk.json
new file mode 100644
index 00000000..6f3259f2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mk.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06",
+ "Brest",
+ "Brest2008"
+ ]
+ },
+ "categorytree": "Дрво на категории",
+ "categorytree-portlet": "Категории",
+ "categorytree-legend": "Прикажи дрво на категории",
+ "categorytree-desc": "Динамички прегледник низ [[Special:CategoryTree|структурата на категориите]]",
+ "categorytree-header": "Внесете назив на категорија за да ја видите нејзината содржина во облик на дрво (бара JavaScript).",
+ "categorytree-category": "Категорија:",
+ "categorytree-go": "Прикажи дрво",
+ "categorytree-parents": "Родители",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "само категории",
+ "categorytree-mode-pages": "страници без податотеки",
+ "categorytree-mode-all": "сите страници",
+ "categorytree-collapse": "собери",
+ "categorytree-expand": "отвори",
+ "categorytree-expand-bullet": "[<b>+</b>]",
+ "categorytree-empty-bullet": "[<b>×</b>]",
+ "categorytree-member-counts": "содржи {{PLURAL:$1|една поткатегорија|$1 поткатегории}}, {{PLURAL:$2|една страница|$2 страници}} и {{PLURAL:$3|една податотека|$3 податотеки}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 П",
+ "categorytree-num-empty": "празна",
+ "categorytree-load": "вчитај",
+ "categorytree-loading": "вчитувам...",
+ "categorytree-nothing-found": "не е најдено ништо",
+ "categorytree-no-subcategories": "нема поткатегории",
+ "categorytree-no-parent-categories": "нема родителски категории",
+ "categorytree-no-pages": "нема страници или поткатегории",
+ "categorytree-not-found": "Не е пронајдена категорија <i>$1</i>",
+ "categorytree-error": "Проблеми со вчитување на податоците.",
+ "categorytree-retry": "Почекајте малку, па обидете се пак.",
+ "apihelp-categorytree-description": "Внатрешен модул на додатокот „Дрво на категории“.",
+ "apihelp-categorytree-summary": "Внатрешен модул на додатокот „Дрво на категории“.",
+ "apihelp-categorytree-param-category": "Наслов во категорискиот именски простор. Ако се внесе претставка, истата ќе биде занемарена.",
+ "apihelp-categorytree-param-options": "Можности за конструкторот на „Дрво на категории“ како JSON-објект. Продорноста (<var>depth</var>) по основно е <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Можностите мора да бидат важечки JSON-објект."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ml.json b/www/wiki/extensions/CategoryTree/i18n/ml.json
new file mode 100644
index 00000000..ca34acd6
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ml.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Praveenp",
+ "Shijualex"
+ ]
+ },
+ "categorytree": "വർഗ്ഗവൃക്ഷം",
+ "categorytree-portlet": "വർഗ്ഗങ്ങൾ",
+ "categorytree-legend": "വർഗ്ഗവൃക്ഷം പ്രദർശിപ്പിക്കുക",
+ "categorytree-desc": "വിക്കിയിലെ [[Special:CategoryTree|വർഗ്ഗങ്ങളുടെ ഘടന]] പ്രദർശിപ്പിക്കുവാനുള്ള അജാക്സ് സാങ്കേതികവിദ്യ ഉപയോഗിക്കുന്ന ഗാഡ്ജറ്റ്.",
+ "categorytree-header": "വർഗ്ഗങ്ങളുടെ ഘടന വ്യക്ഷരൂപത്തിൽ കാണുവാൻ ഒരു വർഗ്ഗത്തിന്റെ പേരു ചേർക്കുക.\nഇതു പ്രവർത്തിക്കണമെങ്കിൽ അജാക്സ് എന്ന ചുരുക്കനാമത്തിലറിയപ്പെടുന്ന നൂതന ജാവാസ്ക്രിപ്റ്റ് സാങ്കേതികവിദ്യ ആവശ്യമാണ്‌.\nതാങ്കളുടെ ബ്രൗസറിൽ ജാവാസ്ക്രിപ്റ്റ് പ്രവർത്തനരഹിതമാക്കിയതാണെങ്കിലോ അല്ലെങ്കിൽ ബ്രൗസർ കാലഹരണപ്പെട്ടതാണെങ്കിലോ ഇതു പ്രവർത്തിക്കില്ല.",
+ "categorytree-category": "വർഗ്ഗം:",
+ "categorytree-go": "വർഗ്ഗവൃക്ഷം പ്രദർശിപ്പിക്കുക",
+ "categorytree-parents": "താവഴി",
+ "categorytree-mode-label": "സമ്പ്രദായം:",
+ "categorytree-mode-categories": "വർഗ്ഗങ്ങൾ മാത്രം",
+ "categorytree-mode-pages": "പ്രമാണങ്ങൾ അല്ലാതെയുള്ള താളുകൾ",
+ "categorytree-mode-all": "എല്ലാ താളുകളും",
+ "categorytree-collapse": "ചുരുക്കുക",
+ "categorytree-expand": "വികസിപ്പിക്കുക",
+ "categorytree-member-counts": "{{PLURAL:$1|ഒരു ഉപവർഗ്ഗവും|$1 ഉപവർഗ്ഗങ്ങളും}}, {{PLURAL:$2|ഒരു താളും|$2 താളുകളും}}, {{PLURAL:$3|ഒരു പ്രമാണവും|$3 പ്രമാണങ്ങളും}} ഉൾക്കൊള്ളുന്നു",
+ "categorytree-num-categories": "$1 വ",
+ "categorytree-num-pages": "$1 താ",
+ "categorytree-num-files": "$1 പ്ര",
+ "categorytree-num-empty": "ശൂന്യം",
+ "categorytree-load": "ശേഖരിക്കുക",
+ "categorytree-loading": "ശേഖരിക്കുന്നു…",
+ "categorytree-nothing-found": "ഒന്നും കണ്ടെത്തിയില്ല",
+ "categorytree-no-subcategories": "ഉപവർഗ്ഗങ്ങളില്ല",
+ "categorytree-no-parent-categories": "മാതൃവർഗ്ഗങ്ങൾ ഇല്ല",
+ "categorytree-no-pages": "താളുകളോ ഉപവർഗ്ഗങ്ങളോ ഇല്ല",
+ "categorytree-not-found": "''$1'' എന്ന വർഗ്ഗം കണ്ടില്ല",
+ "categorytree-error": "വിവരം ശേഖരിക്കുന്നതിൽ പിഴവുണ്ടായി.",
+ "categorytree-retry": "ദയവായി അല്പസമയത്തിനു ശേഷം വീണ്ടും ശ്രമിക്കുക."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mn.json b/www/wiki/extensions/CategoryTree/i18n/mn.json
new file mode 100644
index 00000000..36500816
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mn.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chinneeb",
+ "MongolWiki",
+ "Sembuk"
+ ]
+ },
+ "categorytree": "Ангиллын мод",
+ "categorytree-portlet": "Анги",
+ "categorytree-legend": "Ангиллын модыг үзүүлэх",
+ "categorytree-header": "Ангиллын нэрийг бичиж модны бүтэц байдлаар агуулгыг нь харна уу.\nҮүнийг ашиглахын тулд AJAX гэгдэх ЖаваСкрипт функц хэрэгтэй.\nТа маш хуучин вэб хөтөчтэй, эсвэл ЖаваСкриптыг хориглосон байвал ажиллахгүй болохыг анхаарна уу.",
+ "categorytree-category": "Анги:",
+ "categorytree-go": "Модыг үзүүлэх",
+ "categorytree-parents": "Эх ангиллууд",
+ "categorytree-mode-categories": "Зөвхөн ангиллууд",
+ "categorytree-mode-pages": "зурагнаас бусад хуудсууд",
+ "categorytree-mode-all": "бүх хуудас",
+ "categorytree-collapse": "буулгах",
+ "categorytree-expand": "дэлгэх",
+ "categorytree-member-counts": "{{PLURAL:$1|1 дэд анги|$1 дэд анги}}, {{PLURAL:$2|1 хуудас|$2 хуудас}}, {{PLURAL:$3|1 файл|$3 файл}} агуулагдаж байна.",
+ "categorytree-num-categories": "$1 А",
+ "categorytree-num-pages": "$1 Б",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-load": "унших",
+ "categorytree-loading": "уншиж байна...",
+ "categorytree-nothing-found": "юу ч олдсонгүй",
+ "categorytree-no-subcategories": "дэд ангилалгүй байна",
+ "categorytree-no-parent-categories": "эх ангилал байхгүй байна",
+ "categorytree-no-pages": "хуудас буюу дэд ангилалгүй байна",
+ "categorytree-not-found": "<i>$1</i> анги олдсонгүй",
+ "categorytree-error": "Өгөгдлийг ачааллахад асуудал үүсэв.",
+ "categorytree-retry": "Түр хүлээгээд дахин оролдоно уу."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mo.json b/www/wiki/extensions/CategoryTree/i18n/mo.json
new file mode 100644
index 00000000..fd10c94c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mo.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "TheChampionMan1234",
+ "Cybernenea11"
+ ]
+ },
+ "categorytree-expand": "дескидере",
+ "categorytree-member-counts": "Концине {{PLURAL:$1|1 субкатегорие|$1 субкатегорий}}, {{PLURAL:$2|1 паӂинэ|$2 паӂинь}}, ши {{PLURAL:$3|1 фишиер|$3 фишиере}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 п",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mr.json b/www/wiki/extensions/CategoryTree/i18n/mr.json
new file mode 100644
index 00000000..096005cc
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mr.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Balaji",
+ "Evision",
+ "Htt",
+ "Kaustubh",
+ "Mahitgar",
+ "Mvkulkarni23",
+ "Rahuldeshmukh101",
+ "V.narsikar"
+ ]
+ },
+ "categorytree": "वर्गवृक्ष",
+ "categorytree-portlet": "वर्ग",
+ "categorytree-legend": "वर्गवृक्ष दाखवा",
+ "categorytree-desc": "एखाद्या विकिची [[Special:CategoryTree|वर्गीकरण मांडणी]] दाखवण्याकरिता AJAX वापरून बनवलेले उपकरण",
+ "categorytree-header": "एखाद्या वर्गीकरणातील मसुदा वृक्ष स्वरूपात पहाण्याकरिता त्या वर्गाचे नाव भरा.(जावास्क्रिप्ट हवी.)",
+ "categorytree-category": "वर्ग:",
+ "categorytree-go": "वृक्ष दाखवा",
+ "categorytree-parents": "पालक",
+ "categorytree-mode-label": "पद्धति:",
+ "categorytree-mode-categories": "केवळ वर्ग",
+ "categorytree-mode-pages": "विनासंचिकेची पाने",
+ "categorytree-mode-all": "सर्व पाने",
+ "categorytree-collapse": "निपात करा",
+ "categorytree-expand": "विस्तार",
+ "categorytree-member-counts": "{{PLURAL:$1|१ उपवर्ग|$1 उपवर्ग}}, {{PLURAL:$2|१ पान |$2 पाने}}, आणि {{PLURAL:$3|1 संचिका |$3 संचिका}} यामध्ये आहेत",
+ "categorytree-num-categories": "$1 क",
+ "categorytree-num-pages": "$1 प",
+ "categorytree-num-files": "$1 सं.",
+ "categorytree-num-empty": "रिकामे",
+ "categorytree-load": "भारण करा",
+ "categorytree-loading": "अपभारण करीत आहे",
+ "categorytree-nothing-found": "काहीच सापडले नाही",
+ "categorytree-no-subcategories": "उपवर्ग नाहीत",
+ "categorytree-no-parent-categories": "वर्गास मुळवर्गीकरण उपलब्ध नाही",
+ "categorytree-no-pages": "पाने अथवा उपवर्ग नाहीत",
+ "categorytree-not-found": "वर्ग <i>$1</i> आढळला नाही",
+ "categorytree-error": "विदा (डाटा) चढवताना अडचणी आहेत.",
+ "categorytree-retry": "कृपया,क्षणभर थांबा आणि पुन्हा प्रयत्न करा."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ms.json b/www/wiki/extensions/CategoryTree/i18n/ms.json
new file mode 100644
index 00000000..4cfa0a76
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ms.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia",
+ "Aurora",
+ "Aviator",
+ "Kurniasan"
+ ]
+ },
+ "categorytree": "Salasilah kategori",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Papar salasilah kategori",
+ "categorytree-desc": "Alat berdasarkan AJAX yang memaparkan [[Special:CategoryTree|struktur kategori]] bagi sesebuah wiki",
+ "categorytree-header": "Masukkan suatu nama kategori untuk melihat kandungannya dalam bentuk struktur salasilah.\nCiri ini memerlukan kefungsian JavaScript yang maju dikenali sebagai AJAX.\nJika anda menggunakan pelayar web yang sudah ketinggalan, atau mematikan JavaScript, ciri ini tidak akan menjadi.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Tunjukkan salasilah",
+ "categorytree-parents": "Induk",
+ "categorytree-mode-label": "Ragam:",
+ "categorytree-mode-categories": "kategori sahaja",
+ "categorytree-mode-pages": "laman kecuali imej",
+ "categorytree-mode-all": "semua laman",
+ "categorytree-collapse": "lipat",
+ "categorytree-expand": "kembangkan",
+ "categorytree-member-counts": "mengandungi $1 subkategori, $1 laman, dan $3 fail",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "kosong",
+ "categorytree-load": "muat",
+ "categorytree-loading": "memuatkan…",
+ "categorytree-nothing-found": "kosong",
+ "categorytree-no-subcategories": "tiada subkategori",
+ "categorytree-no-parent-categories": "tiada kategori induk",
+ "categorytree-no-pages": "tiada laman atau subkategori",
+ "categorytree-not-found": "Kategori <i>$1</i> tidak ditemui",
+ "categorytree-error": "Masalah memuat data.",
+ "categorytree-retry": "Sila tunggu sebentar dan cuba lagi."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mt.json b/www/wiki/extensions/CategoryTree/i18n/mt.json
new file mode 100644
index 00000000..e1bfb638
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mt.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chrisportelli",
+ "Roderick Mallia",
+ "MTSap"
+ ]
+ },
+ "categorytree": "Siġra tal-kategoriji",
+ "categorytree-portlet": "Kategoriji",
+ "categorytree-legend": "Uri s-siġra tal-kategoriji",
+ "categorytree-desc": "Innaviga b'mod dinamiku fl-[[Special:CategoryTree|istruttura tal-kategorija]]",
+ "categorytree-header": "Daħħal isem ta' kategorija biex tara l-kontenuti taħt struttura ta' siġra. Kun af li din għandha bżonn funzjonalità avvanzata ta' JavaScript magħrufa bħala AJAX. Jekk tuża' browser antik ħafna, jew għandek il-JavaScript diżattivat, din ma tistax taħdem.",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Uri s-siġra",
+ "categorytree-parents": "Parenti",
+ "categorytree-mode-categories": "il-kategoriji biss",
+ "categorytree-mode-pages": "il-paġni esklużi l-fajls",
+ "categorytree-mode-all": "il-paġni kollha",
+ "categorytree-collapse": "niżżel",
+ "categorytree-expand": "espandi",
+ "categorytree-member-counts": "Għandha {{PLURAL:$1|sottokategorija waħda|$1 sottokategoriji}}, {{PLURAL:$2|paġna waħda|$2 paġna}}, u {{PLURAL:$3|1 fajl|$3 fajls}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vojta",
+ "categorytree-load": "tella'",
+ "categorytree-loading": "tiela",
+ "categorytree-nothing-found": "ma nstab xejn",
+ "categorytree-no-subcategories": "l-ebda sottokategorija",
+ "categorytree-no-parent-categories": "l-ebda kategorija parenti",
+ "categorytree-no-pages": "l-ebda paġna jew sottokategorija",
+ "categorytree-not-found": "Il-kategorija <i>$1</i> ma nstabitx",
+ "categorytree-error": "Problema fit-tlugħ tal-informazzjoni.",
+ "categorytree-retry": "Jekk jogħġbok stenna ftit u erġa' pprova."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mui.json b/www/wiki/extensions/CategoryTree/i18n/mui.json
new file mode 100644
index 00000000..b8b0ca2a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mui.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jawadywn"
+ ]
+ },
+ "categorytree-expand": "selék",
+ "categorytree-num-categories": "$1 B",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 B"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mwl.json b/www/wiki/extensions/CategoryTree/i18n/mwl.json
new file mode 100644
index 00000000..5dd56e5c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mwl.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "categorytree": "Arble de catadories",
+ "categorytree-expand": "spandir",
+ "categorytree-member-counts": "Cuntén {{PLURAL:$1|1 subcatadorie|$1 subcatadories}}, {{PLURAL:$2|1 páigina|$2 páiginas}}, i {{PLURAL:$3|1 fexeiro|$3 fexeiros}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/my.json b/www/wiki/extensions/CategoryTree/i18n/my.json
new file mode 100644
index 00000000..1c5586fb
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/my.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ninjastrikers",
+ "9.sinistra"
+ ]
+ },
+ "categorytree-category": "ကဏ္ဍ:",
+ "categorytree-expand": "ချဲ့ကား",
+ "categorytree-member-counts": "{{PLURAL:$1|ကဏ္ဍခွဲ ၁ ခု|$1 ကဏ္ဍခွဲများ}}၊ {{PLURAL:$2|စာမျက်နှာ ၁ ခု| စာမျက်နှာ $2 ခု}}၊ နှင့် {{PLURAL:$3|ဖိုင် ၁ ခု| ဖိုင် $3 ခု }} ပါဝင်သည်",
+ "categorytree-num-categories": "$1 ကဏ္ဍ",
+ "categorytree-num-pages": "$1 စာမျက်နှာ",
+ "categorytree-num-files": "$1 ဖိုင်",
+ "categorytree-num-empty": "ဘာမှမရှိ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/myv.json b/www/wiki/extensions/CategoryTree/i18n/myv.json
new file mode 100644
index 00000000..e1832ee3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/myv.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amdf",
+ "Botuzhaleny-sodamo",
+ "Rueter"
+ ]
+ },
+ "categorytree": "Явкс чувто",
+ "categorytree-portlet": "Категорият",
+ "categorytree-legend": "Невтемс явкс чувтонть",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Невтемс чувтонзо",
+ "categorytree-parents": "Тетянзо-аванзо",
+ "categorytree-mode-categories": "ансяк категорият",
+ "categorytree-mode-all": "весе лопатне",
+ "categorytree-collapse": "теингавтомс",
+ "categorytree-expand": "келемтемс",
+ "categorytree-num-categories": "К-тнеде $1",
+ "categorytree-num-pages": "Лл-тнеде $1",
+ "categorytree-num-files": "Ф-тнеде $1",
+ "categorytree-load": "Йовкстамс",
+ "categorytree-loading": "йовкстамозо моли...",
+ "categorytree-nothing-found": "мезеяк а муеви",
+ "categorytree-no-subcategories": "алкс категорият арасть",
+ "categorytree-no-parent-categories": "верькс категорият арасть",
+ "categorytree-no-pages": "кодамояк лопат эли алкс категорият арасть",
+ "categorytree-not-found": "«$1» категориясь а муеви."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/mzn.json b/www/wiki/extensions/CategoryTree/i18n/mzn.json
new file mode 100644
index 00000000..725e3e67
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/mzn.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "محک"
+ ]
+ },
+ "categorytree": "رج‌دار",
+ "categorytree-portlet": "رج‌ئون",
+ "categorytree-expand": "گت هاکردن",
+ "categorytree-member-counts": "{{PLURAL:$1|اتا زیررج|$1 زیررج}}، {{PLURAL:$2|اتا صفحه|$2 صفحه}} و {{PLURAL:$3|اتا پرونده|$3 پرونده}} ونه دله دره",
+ "categorytree-num-categories": "$1 ر",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 پ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/na.json b/www/wiki/extensions/CategoryTree/i18n/na.json
new file mode 100644
index 00000000..a278c4a5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/na.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nah.json b/www/wiki/extensions/CategoryTree/i18n/nah.json
new file mode 100644
index 00000000..bcd475e3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nah.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fluence",
+ "Teòtlalili",
+ "Taresi",
+ "Akapochtli"
+ ]
+ },
+ "categorytree": "Neneuhcayocuammayotl",
+ "categorytree-portlet": "Neneuhcayomeh",
+ "categorytree-legend": "Monexti in Neneuhcayocuammayotl",
+ "categorytree-desc": "Iciuhca mopanoltiz ipan in [[Special:CategoryTree|Neneuhcayocuammayotl]]",
+ "categorytree-header": "Xikîkuilo sè tlaìxmatkàtlàlilòtòkâtli, ìka tikỉtílìs in ìtlamàmàyòtekpànalpialòl.\nXikmauhtie, molwi yankuik JavaScript tekitìliskàyòtl tètech moneki, ìxmatkàyö kèn AJAX.\nIntlà molwi yi wêkàuhkáyòtl in monetzànìltzòwîkàuh, nòso tiksewîtok in JavaScript, awel tlen monèxtis.",
+ "categorytree-category": "Neneuhcayotl:",
+ "categorytree-go": "Monextiz cuammayotl",
+ "categorytree-parents": "Achcauhcaneneuhcayotl",
+ "categorytree-mode-categories": "Zan neneuhcayomeh monextizqueh",
+ "categorytree-mode-pages": "zan tlahcuilolamameh ahmo ixiptin",
+ "categorytree-mode-all": "Nochtin in tlahcuilolamameh",
+ "categorytree-collapse": "motepitonoz",
+ "categorytree-expand": "mohueyiyaliz",
+ "categorytree-member-counts": "quipiya {{PLURAL:$1|ce tlani-neneuhcayotl|$1 tlani-neneuhcayomeh}}, {{PLURAL:$2|tlahcuilolamatl|$2 tlahcuilolamameh}}, ihuan {{PLURAL:$3|ce tlapiyaliztecpanaliztli|$3 tlapiyaliztecpanaliztin}}",
+ "categorytree-num-files": "$1 Ihcu",
+ "categorytree-load": "motemohuiz",
+ "categorytree-loading": "hualtemohticah...",
+ "categorytree-nothing-found": "ahmo tlen omahcic",
+ "categorytree-no-subcategories": "ahmo quipiya tlani-neneuhcayomeh",
+ "categorytree-no-parent-categories": "ahtle oncah achcauhcaneneuhcayomeh",
+ "categorytree-no-pages": "ahtle oncateh tlahcuilolamameh nozo tlani-neneuhcayomeh",
+ "categorytree-not-found": "Neneuhcayotl <i>$1</i> ahmo omahxilih",
+ "categorytree-error": "Ahhuel temo in tlamatilicehualli",
+ "categorytree-retry": "Timitztlatlauhtiah, ximochiya chihton niman occepa xicyehyeco."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nan.json b/www/wiki/extensions/CategoryTree/i18n/nan.json
new file mode 100644
index 00000000..de98d166
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nan.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ianbu",
+ "唐吉訶德的侍從",
+ "Luuva"
+ ]
+ },
+ "categorytree-category": "Lūi-pia̍t:",
+ "categorytree-expand": "Khui",
+ "categorytree-member-counts": "包括{{PLURAL:$1|个下分類}}、{{PLURAL:$2|个頁}}佮 {{PLURAL:$3|个檔案}}",
+ "categorytree-num-categories": "$1 分類",
+ "categorytree-num-pages": "$1 ia̍h",
+ "categorytree-num-files": "$1檔",
+ "categorytree-loading": "teh ji̍p",
+ "categorytree-no-subcategories": "bô ē-lūi-pia̍t"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nap.json b/www/wiki/extensions/CategoryTree/i18n/nap.json
new file mode 100644
index 00000000..470cf897
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nap.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chelin",
+ "C.R."
+ ]
+ },
+ "categorytree": "Arvero d' 'e categurìe",
+ "categorytree-portlet": "Categurìe",
+ "categorytree-legend": "Fà veré ll'arvero d' 'e categurìe",
+ "categorytree-desc": "Navigà dinamicamente dint' 'a [[Special:CategoryTree|struttura d' 'e categurìe]]",
+ "categorytree-header": "Nzertate 'o nomme 'e na categurìa pe' ne vedé 'e cuntenute comme na struttura d'arvero. (Ce vulesse 'o JavaScript)",
+ "categorytree-category": "Categurìa:",
+ "categorytree-go": "Fà vedé ll'arvero",
+ "categorytree-parents": "Categurìe superiore",
+ "categorytree-mode-label": "Modalità:",
+ "categorytree-mode-categories": "mostra solo 'e categurìe",
+ "categorytree-mode-pages": "tutte 'e paggene accettuanno l'immaggene",
+ "categorytree-mode-all": "Tutte 'e paggene",
+ "categorytree-collapse": "annascunne",
+ "categorytree-expand": "fa vede",
+ "categorytree-member-counts": "Cuntene {{PLURAL:$1|1 sottocategurìa|$1 sottocategurìe}}, {{PLURAL:$2|1 paggena|$2 paggene}} e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "abbacante",
+ "categorytree-load": "carreca",
+ "categorytree-loading": "Se sta caricanno...",
+ "categorytree-nothing-found": "nisciuno risultato",
+ "categorytree-no-subcategories": "nisciuna sottocategurìa",
+ "categorytree-no-parent-categories": "nisciuna categurìa suppiriore",
+ "categorytree-no-pages": "nisciuna paggena ne sottocategurìa",
+ "categorytree-not-found": "Categurìa ''$1'' nun truvata",
+ "categorytree-error": "Probblema c' 'o caricamento d' 'e date.",
+ "categorytree-retry": "Aspetta nu mumento e prova n'ata vota.",
+ "apihelp-categorytree-description": "Modulo nterno pe' ne ffà n'estensione CategoryTree",
+ "apihelp-categorytree-param-category": "Titolo dint' 'o namespace categurìa, 'o prefisso sarrà gnurato si dato.",
+ "apihelp-categorytree-param-options": "Opziune p' 'o costruttore comm'a n'uggetto JSON.\nL'opziona <var>depth</var> è determinata a <kbd>1</kbd>."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nb.json b/www/wiki/extensions/CategoryTree/i18n/nb.json
new file mode 100644
index 00000000..e1608534
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nb.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Audun",
+ "Event",
+ "SuperPotato",
+ "Jon Harald Søby",
+ "Kingu"
+ ]
+ },
+ "categorytree": "Kategoritre",
+ "categorytree-portlet": "Kategorier",
+ "categorytree-legend": "Vis kategoritre",
+ "categorytree-desc": "AJAX-basert verktøy som viser [[Special:CategoryTree|kategoristrukturen]] til en wiki",
+ "categorytree-header": "Skriv inn et kategorinavn for å se dens innhold som en trestruktur. (Krever JavaScript.)",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Vis tre",
+ "categorytree-parents": "Overkategorier",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "kun kategorier",
+ "categorytree-mode-pages": "sider utenom bilder",
+ "categorytree-mode-all": "alle sider",
+ "categorytree-collapse": "skjul",
+ "categorytree-expand": "utvid",
+ "categorytree-member-counts": "Inneholder {{PLURAL:$1|én underkategori|$1 underkategorier}}, {{PLURAL:$2|én side|$2 sider}} og {{PLURAL:$3|én fil|$3 filer}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tom",
+ "categorytree-load": "last",
+ "categorytree-loading": "laster...",
+ "categorytree-nothing-found": "ingenting funnet",
+ "categorytree-no-subcategories": "ingen underkategorier",
+ "categorytree-no-parent-categories": "ingen foreldrekategorier",
+ "categorytree-no-pages": "ingen sider eller underkategorier",
+ "categorytree-not-found": "Kategorien <i>$1</i> ikke funnet",
+ "categorytree-error": "problem under datalasting.",
+ "categorytree-retry": "Vent en stund og prøv igjen.",
+ "apihelp-categorytree-description": "Intern modul for CategoryTree-utvidelsen.",
+ "apihelp-categorytree-summary": "Intern modul for CategoryTree-utvidelsen.",
+ "apihelp-categorytree-param-category": "Tittel i kategorinavnerommet, prefiks vil ignoreres om det oppgis.",
+ "apihelp-categorytree-param-options": "Valg for CategoryTree-konstruktøren som et JSON-objekt. Valget <var>depth</var> sin standardverdi er <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Valg må være et gyldig JSON-objekt."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nds-nl.json b/www/wiki/extensions/CategoryTree/i18n/nds-nl.json
new file mode 100644
index 00000000..bb10689b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nds-nl.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Servien"
+ ]
+ },
+ "categorytree": "Kategorieboom",
+ "categorytree-portlet": "Kategorieën",
+ "categorytree-legend": "Laot kategorieboom zien",
+ "categorytree-desc": "Dynamiese navigasie veur de [[Special:CategoryTree|kategoriestruktuur]]",
+ "categorytree-header": "Voer n kategorienaam in um de inhoud in boomstruktuur te bekieken.\nNB: veur disse funksie he'j de JavaScript-funksionaliteit AJAX neudig. A'j n hele ouwe webkieker hebben, of je JavaScript uuteschakeld hebben, dan zal disse funksie niet warken.",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Laojen",
+ "categorytree-parents": "Ouwerkategorieën",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "allinnig kategorieën",
+ "categorytree-mode-pages": "ziejen, gien aofbeeldingen",
+ "categorytree-mode-all": "alle ziejen",
+ "categorytree-collapse": "samenvouwen",
+ "categorytree-expand": "uutklappen",
+ "categorytree-member-counts": "bevat {{PLURAL:$1|één onderkategorie|$1 onderkategorieën}}, {{PLURAL:$2|één zied|$2 ziejen}} en {{PLURAL:$3|één bestaand|$3 bestaanden}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "leeg",
+ "categorytree-load": "laojen",
+ "categorytree-loading": "bezig mit laojen...",
+ "categorytree-nothing-found": "niks evunnen",
+ "categorytree-no-subcategories": "gien subkategorieën",
+ "categorytree-no-parent-categories": "gien ouwerkategorieën",
+ "categorytree-no-pages": "gien ziejen of subkategorieën",
+ "categorytree-not-found": "Kategorie <i>$1</i> niet evunnen",
+ "categorytree-error": "Probleem bie t laojen van de gegevens.",
+ "categorytree-retry": "Wacht even en probeer t opniej"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nds.json b/www/wiki/extensions/CategoryTree/i18n/nds.json
new file mode 100644
index 00000000..c7335875
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nds.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Slomox"
+ ]
+ },
+ "categorytree": "Kategorie-Boom",
+ "categorytree-portlet": "Kategorien",
+ "categorytree-legend": "Kategorieboom wiesen",
+ "categorytree-desc": "Dynaamsche Navigatschoon för de [[Special:CategoryTree|Kategorien-Struktur]]",
+ "categorytree-header": "Kategorienaam ingeven, den Inholt as Boomstruktur to sehn. Schasst di bewusst wesen, dat Javascript un de AJAX-Funkschoon dor för bruukt warrt. Wenn dien Nettkieker to oolt is oder du keen Javascript hest, denn warrt dat nix.",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Boom wiesen",
+ "categorytree-parents": "Öllernkategorien",
+ "categorytree-mode-categories": "blot Kategorien",
+ "categorytree-mode-pages": "Sieden, ahn Biller",
+ "categorytree-mode-all": "all Sieden",
+ "categorytree-collapse": "nich ganz wiesen",
+ "categorytree-expand": "ganz wiesen",
+ "categorytree-member-counts": "bargt {{PLURAL:$1|ene Ünnerkategorie|$1 Ünnerkategorien}}, {{PLURAL:$2|ene Sied|$2 Sieden}} un {{PLURAL:$3|ene Datei|$3 Datein}}",
+ "categorytree-load": "laden",
+ "categorytree-loading": "läädt",
+ "categorytree-nothing-found": "nix funnen",
+ "categorytree-no-subcategories": "kene Ünnerkategorien",
+ "categorytree-no-parent-categories": "Kene Öllernkategorien",
+ "categorytree-no-pages": "kene Sieden oder Ünnerkategorien",
+ "categorytree-not-found": "Kategorie <i>$1</i> nich funnen",
+ "categorytree-error": "Problem bi’t Laden vun de Daten",
+ "categorytree-retry": "Tööv en beten un denn versöök dat noch wedder."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ne.json b/www/wiki/extensions/CategoryTree/i18n/ne.json
new file mode 100644
index 00000000..3a4fd9db
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ne.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bhawani Gautam",
+ "Bhawani Gautam Rhk",
+ "Krish Dulal",
+ "NehalDaveND"
+ ]
+ },
+ "categorytree": "श्रेणी वृक्ष",
+ "categorytree-portlet": "श्रेणीहरू",
+ "categorytree-legend": "श्रेणी वृक्ष हेर्ने",
+ "categorytree-desc": "[[Special:CategoryTree|श्रेणी संरचना]]को गतिशील अन्वेषण गर्ने",
+ "categorytree-category": "श्रेणी:",
+ "categorytree-go": "वृक्ष हेर्ने",
+ "categorytree-parents": "जनक",
+ "categorytree-mode-label": "मोड",
+ "categorytree-mode-categories": "श्रेणी मात्र",
+ "categorytree-mode-pages": "फाइलहरू बाहेकका पृष्ठहरू",
+ "categorytree-mode-all": "सबै पृष्ठहरू",
+ "categorytree-collapse": "खुम्च्याउनु",
+ "categorytree-expand": "फैलाउनु",
+ "categorytree-member-counts": "मा {{PLURAL:$1|1 श्रेणी छ|$1 श्रेणीहरू छन्}}, {{PLURAL:$2|1 पृष्ठ छ|$2 पृष्ठहरू छन्}}, तथा {{PLURAL:$3|1 फाइल छ|$3 फाइलहरू छन्}}",
+ "categorytree-num-categories": "$1 C (श्रे)",
+ "categorytree-num-pages": "$1 P (पृ)",
+ "categorytree-num-files": "$1 F (फा)",
+ "categorytree-num-empty": "रित्तो",
+ "categorytree-load": "चढाउने",
+ "categorytree-loading": "खोलिंदै…",
+ "categorytree-nothing-found": "केहीपनि फेला परेन",
+ "categorytree-no-subcategories": "उपश्रेणीहरू छैनन्",
+ "categorytree-no-parent-categories": "अभिभावक श्रेणीहरू नभएको",
+ "categorytree-no-pages": "पृष्ठहरू वा उपश्रेणीहरू छैनन्",
+ "categorytree-not-found": "श्रेणी <i>$1</i> फेला परेन",
+ "categorytree-error": "आँकडा (data) चढाउनमा समस्या",
+ "categorytree-retry": "कृपया केही क्षण पर्खेर त्यसपछि पुनः प्रयास गर्नुहोस्"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/niu.json b/www/wiki/extensions/CategoryTree/i18n/niu.json
new file mode 100644
index 00000000..a278c4a5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/niu.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nl-informal.json b/www/wiki/extensions/CategoryTree/i18n/nl-informal.json
new file mode 100644
index 00000000..ffd154de
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nl-informal.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Siebrand"
+ ]
+ },
+ "categorytree-header": "Geef een categorienaam in om de inhoud als een boomstructuur te bekijken.\nLet op: deze functie gebruikt JavaScript-functionaliteit die bekend staat als AJAX.\nAls je een verouderde browser hebt of JavaScript uitgeschakeld is, dan werkt deze functie niet."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nl.json b/www/wiki/extensions/CategoryTree/i18n/nl.json
new file mode 100644
index 00000000..54d19c1a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nl.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kippenvlees1",
+ "SPQRobin",
+ "Siebrand",
+ "Mainframe98",
+ "Huhbakker"
+ ]
+ },
+ "categorytree": "Categorieboom",
+ "categorytree-portlet": "Categorieën",
+ "categorytree-legend": "Categorieboom weergeven",
+ "categorytree-desc": "AJAX-gebaseerde uitbreiding om de [[Special:CategoryTree|categoriestructuur]] van een wiki te bekijken",
+ "categorytree-header": "Geef een categorienaam in om de inhoud als een boomstructuur te bekijken. (Vereist JavaScript.)",
+ "categorytree-category": "Categorie:",
+ "categorytree-go": "Structuur weergeven",
+ "categorytree-parents": "Bovenliggende categorieën",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "alleen categorieën",
+ "categorytree-mode-pages": "geen afbeeldingen",
+ "categorytree-mode-all": "alle pagina's",
+ "categorytree-collapse": "samenvouwen",
+ "categorytree-expand": "uitvouwen",
+ "categorytree-member-counts": "bevat {{PLURAL:$1|één ondercategorie|$1 ondercategorieën}}, {{PLURAL:$2|één pagina|$2 pagina's}} en {{PLURAL:$3|één bestand|$3 bestanden}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "leeg",
+ "categorytree-load": "laden",
+ "categorytree-loading": "aan het laden…",
+ "categorytree-nothing-found": "niets gevonden",
+ "categorytree-no-subcategories": "Geen ondercategorieën.",
+ "categorytree-no-parent-categories": "geen bovencategorieën",
+ "categorytree-no-pages": "Geen pagina's of ondercategorieën.",
+ "categorytree-not-found": "Categorie <i>$1</i> is niet gevonden",
+ "categorytree-error": "Probleem bij het laden van de gegevens.",
+ "categorytree-retry": "Wacht even en probeer het dan opnieuw.",
+ "apihelp-categorytree-description": "Interne module voor de uitbreiding CategoryTree.",
+ "apihelp-categorytree-summary": "Interne module voor de uitbreiding CategoryTree.",
+ "apihelp-categorytree-param-category": "Naam in te categorienaamruimte, voorvoegsel wordt genegeerd als opgegeven.",
+ "apihelp-categorytree-param-options": "Opties voor de constructor van CategoryTree als een JSON-object. De optie \"depth\" is standaard ingesteld op <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Opties moeten een geldig JSON-object zijn."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nn.json b/www/wiki/extensions/CategoryTree/i18n/nn.json
new file mode 100644
index 00000000..8493aa8b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nn.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eirik",
+ "Harald Khan",
+ "Njardarlogar"
+ ]
+ },
+ "categorytree": "Kategoritre",
+ "categorytree-portlet": "Kategoriar",
+ "categorytree-legend": "Vis kategoritre",
+ "categorytree-desc": "AJAX-basert verktøy som viser [[Special:CategoryTree|kategoristrukturen]] til ein wiki",
+ "categorytree-header": "Skriv inn eit kategorinamn for å sjå innhaldet som ein trestruktur. Merk at denne funksjonen nyttar avansert [[JavaScript]]-funksjonalitet ([[AJAX]]). Dersom du brukar ein veldig gammal nettlesar, eller har slått av JavaScript-støtte, vil dette ikkje fungere.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Vis kategoritre",
+ "categorytree-parents": "Overkategoriar",
+ "categorytree-mode-label": "Modus:",
+ "categorytree-mode-categories": "berre kategoriane",
+ "categorytree-mode-pages": "sider med unntak av filer",
+ "categorytree-mode-all": "alle sidene",
+ "categorytree-collapse": "gøym",
+ "categorytree-expand": "vis",
+ "categorytree-member-counts": "inneheld {{PLURAL:$1|éin underkategori|$1 underkategoriar}}, {{PLURAL:$2|éi sida|$2 sider}} og {{PLURAL:$3|éi fil|$3 filer}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tom",
+ "categorytree-load": "last inn",
+ "categorytree-loading": "lastar inn",
+ "categorytree-nothing-found": "fann ikkje noko",
+ "categorytree-no-subcategories": "ingen underkategoriar",
+ "categorytree-no-parent-categories": "ingen foreldrekategoriar",
+ "categorytree-no-pages": "ingen sider eller underkategoriar",
+ "categorytree-not-found": "Fann ikkje kategorien <i>$1</i>",
+ "categorytree-error": "Problem med innlasting av data.",
+ "categorytree-retry": "Ver venleg og vent litt før du prøver ein gong til."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nso.json b/www/wiki/extensions/CategoryTree/i18n/nso.json
new file mode 100644
index 00000000..fcaa1564
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nso.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mohau"
+ ]
+ },
+ "categorytree-category": "Sehlopha:",
+ "categorytree-go": "Bontsha Sehlare",
+ "categorytree-parents": "Batswadi",
+ "categorytree-mode-all": "matlakala kamoka",
+ "categorytree-collapse": "tswalela",
+ "categorytree-expand": "bula",
+ "categorytree-no-pages": "gago matlakala goba dihlophana",
+ "categorytree-not-found": "Sehlopha <i>$1</i> ga se humanege"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/nys.json b/www/wiki/extensions/CategoryTree/i18n/nys.json
new file mode 100644
index 00000000..f6769f2a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/nys.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "categorytree-expand": "koombarabiny",
+ "categorytree-member-counts": "Won-garn {{PLURAL:$1|warrangang}}, {{PLURAL:$2|bibol}}, wer {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 W",
+ "categorytree-num-pages": "$1 B",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/oc.json b/www/wiki/extensions/CategoryTree/i18n/oc.json
new file mode 100644
index 00000000..66ac1726
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/oc.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31"
+ ]
+ },
+ "categorytree": "Arborescéncia de las categorias",
+ "categorytree-portlet": "Categorias",
+ "categorytree-legend": "Visionar l’arborescéncia de la categoria",
+ "categorytree-desc": "Gadget basat sus AJAX per afichar l'[[Special:CategoryTree|estructura de la categoria]] d’un wiki",
+ "categorytree-header": "Entratz un nom de categoria per veire son contengut en estructura arborescenta (necessita JavaScript).",
+ "categorytree-category": "Categoria :",
+ "categorytree-go": "Mostrar l'arborescéncia",
+ "categorytree-parents": "Subrecategoria(s)",
+ "categorytree-mode-label": "Mòde:",
+ "categorytree-mode-categories": "pas que las categorias",
+ "categorytree-mode-pages": "paginas sens los imatges",
+ "categorytree-mode-all": "totas las paginas",
+ "categorytree-collapse": "Rebatre",
+ "categorytree-expand": "desvolopar",
+ "categorytree-member-counts": "conten {{PLURAL:$1|1 soscategoria|$1 soscategorias}}, {{PLURAL:$2|1 pagina|$2 paginas}}, e {{PLURAL:$3|1 fichièr|$3 fichièrs}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "void",
+ "categorytree-load": "Dobrir",
+ "categorytree-loading": "dobertura...",
+ "categorytree-nothing-found": "pas res de trobat",
+ "categorytree-no-subcategories": "pas cap de soscategoria",
+ "categorytree-no-parent-categories": "Cap de categoria parenta",
+ "categorytree-no-pages": "Pas de pagina o de soscategoria",
+ "categorytree-not-found": "La categoria <i>$1</i> es pas estada trobada.",
+ "categorytree-error": "Problèma de cargament de las donadas.",
+ "categorytree-retry": "Esperatz un moment puèi tornatz ensajar."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/olo.json b/www/wiki/extensions/CategoryTree/i18n/olo.json
new file mode 100644
index 00000000..2cf58692
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/olo.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Denö",
+ "Ilja.mos",
+ "Mashoi7"
+ ]
+ },
+ "categorytree": "Kategouriipuu",
+ "categorytree-portlet": "Kategouriet",
+ "categorytree-legend": "Ozuta kategouriipuu",
+ "categorytree-category": "Kategourii:",
+ "categorytree-go": "Ozuta puu",
+ "categorytree-parents": "Yläkategouriet",
+ "categorytree-mode-all": "kai sivut",
+ "categorytree-expand": "avua",
+ "categorytree-member-counts": "Täh kuuluu {{PLURAL:$1|1 alakategourii|$1 alakategouriedu}}, {{PLURAL:$2|1 sivu|$2 sivuu}}, and {{PLURAL:$3|1 failu|$3 failua}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tyhjy",
+ "categorytree-nothing-found": "ei löydynyh nimidä",
+ "categorytree-no-subcategories": "ei alikategourieloi",
+ "categorytree-no-parent-categories": "ei yläkategourieloi",
+ "categorytree-no-pages": "ei sivuloi libo alikategourieloi",
+ "categorytree-not-found": "Kategouriedu <i>$1</i> ei löydynyh",
+ "categorytree-retry": "Ole hyvä, vuota kodvaine da opi vie kerdu"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/or.json b/www/wiki/extensions/CategoryTree/i18n/or.json
new file mode 100644
index 00000000..f44ad2e2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/or.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jnanaranjan Sahu",
+ "Odisha1",
+ "Psubhashish"
+ ]
+ },
+ "categorytree": "ଶ୍ରେଣୀବିଭାଗ",
+ "categorytree-portlet": "ଶ୍ରେଣୀସମୂହ",
+ "categorytree-legend": "ଶ୍ରେଣୀବିଭାଗ",
+ "categorytree-desc": "[[Special:CategoryTree|ଶ୍ରେଣୀବିଭାଗ]]କୁ ଚାଲିଯିବା",
+ "categorytree-header": "ଶ୍ରେଣିସବୁର ଗଛ ପରି ସଜାଣି ଦେଖିବା ନିମନ୍ତେ ତାହାର ନାମ ଦିଅନ୍ତୁ ।\nମନେରକନ୍ତୁ, ଏହା ପାଇଁ ଜାଭାସ୍କ୍ରିପ୍ଟ ଲୋଡ଼ା ଯାହା AJAX ନାମରେ ମଧ୍ୟ ଜଣା ।\nଯଦି ଆପଣଙ୍କ ପାଖରେ ପୁରୁଣା ବ୍ରାଉଜରଟିଏ ଅଛି ବା ଜାଭାସ୍କ୍ରିପ୍ଟ ଅଚଳ ଅଛି, ତେବେ ଏହା କାମ କରିବ ନାହିଁ ।",
+ "categorytree-category": "ଶ୍ରେଣୀ:",
+ "categorytree-go": "ଶ୍ରେଣୀବିଭାଗଗୁଡ଼ିକ ଦେଖାଇବା",
+ "categorytree-parents": "ମୂଳ",
+ "categorytree-mode-label": "ମୋଡ:",
+ "categorytree-mode-categories": "କେବଳ ଶ୍ରେଣୀସମୂହ",
+ "categorytree-mode-pages": "ଫାଇଲ ନଥିବା ପୃଷ୍ଠାସବୁ",
+ "categorytree-mode-all": "ସବୁ ପୃଷ୍ଠା",
+ "categorytree-collapse": "ଲୁଚାଇବେ",
+ "categorytree-expand": "ପୂରା ଦେଖାଇବେ",
+ "categorytree-member-counts": "ଏହା ଭିତରେ {{PLURAL:$1|1ଟି ଶ୍ରେଣୀ|$1 ଟି ସାନଶ୍ରେଣୀ}}, {{PLURAL:$2|1 ପୃଷ୍ଠା|$2 ଟି ପୃଷ୍ଠା}} ଓ {{PLURAL:$3|1 ଟି ଫାଇଲ|$3 ଟି ଫାଇଲ}} ଅଛି ।",
+ "categorytree-num-categories": "$1 ଶ୍ରେଣୀ",
+ "categorytree-num-pages": "$1 ପୃଷ୍ଠା",
+ "categorytree-num-files": "$1 ଫାଇଲ",
+ "categorytree-num-empty": "ଖାଲି",
+ "categorytree-load": "ଖୋଲିବେ",
+ "categorytree-loading": "ଖୋଲୁଛି...",
+ "categorytree-nothing-found": "କିଛି ମିଳିଲା ନାହିଁ",
+ "categorytree-no-subcategories": "ସାନଶ୍ରେଣୀ ନାହିଁ",
+ "categorytree-no-parent-categories": "କିଛି ମୂଳ ଶ୍ରେଣୀ ନାହିଁ",
+ "categorytree-no-pages": "କିଛି ପୃଷ୍ଠା ବା ସାନଶ୍ରେଣୀ ନାହିଁ",
+ "categorytree-not-found": "<i>$1</i> ଶ୍ରେଣୀଟି ମିଳିଲା ନାହିଁ",
+ "categorytree-error": "ଡାଟା ଖୋଲିବା ପାଇଁ ଅସୁବିଧା ହେଉଛି",
+ "categorytree-retry": "ଦୟାକରି କିଛି ସମୟ ପରେ ଚେଷ୍ଟା କରନ୍ତୁ ।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/os.json b/www/wiki/extensions/CategoryTree/i18n/os.json
new file mode 100644
index 00000000..6e3eb84f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/os.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amikeco",
+ "Amire80",
+ "Bouron"
+ ]
+ },
+ "categorytree": "Категориты бæлас",
+ "categorytree-portlet": "Категоритæ",
+ "categorytree-category": "Категори:",
+ "categorytree-go": "Равдис бæлас",
+ "categorytree-mode-categories": "æрмæст категоритæ",
+ "categorytree-mode-pages": "фæрстæ, æнæ файлтæ",
+ "categorytree-mode-all": "æппæт фæрстæ",
+ "categorytree-expand": "райтынг кæнын",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Ф",
+ "categorytree-num-files": "$1 ф",
+ "categorytree-num-empty": "афтид",
+ "categorytree-load": "сæвгæнын",
+ "categorytree-loading": "æвгæд цæуы...",
+ "categorytree-nothing-found": "Ацы категорийы мидæг дæлкатегоритæ нæ разынд",
+ "categorytree-no-subcategories": "дæлкатегоритæ нæй",
+ "categorytree-no-parent-categories": "хистæр категори нæй",
+ "categorytree-no-pages": "фæрстæ æмæ дæлкатегоритæ нæй",
+ "categorytree-not-found": "Категори «$1» не ссардæуы."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pa.json b/www/wiki/extensions/CategoryTree/i18n/pa.json
new file mode 100644
index 00000000..4eccf560
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pa.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aalam",
+ "Babanwalia",
+ "Gman124",
+ "Raj Singh",
+ "TariButtar",
+ "Satdeep gill"
+ ]
+ },
+ "categorytree": "ਸ਼੍ਰੇਣੀ ਰੁੱਖ",
+ "categorytree-portlet": "ਸ਼੍ਰੇਣੀਆਂ",
+ "categorytree-legend": "ਸ਼੍ਰੇਣੀ ਰੁੱਖ ਵਿਖਾਓ",
+ "categorytree-category": "ਸ਼੍ਰੇਣੀ:",
+ "categorytree-go": "ਰੁੱਖ ਵੇਖੋ",
+ "categorytree-parents": "ਮੁਢਲੀਆਂ ਸ਼੍ਰੇਣੀਆਂ",
+ "categorytree-mode-label": "ਰੂਪ:",
+ "categorytree-mode-categories": "ਸਿਰਫ਼ ਸ਼੍ਰੇਣੀਆਂ",
+ "categorytree-mode-pages": "ਫ਼ਾਈਲਾਂ ਤੋਂ ਛੁੱਟ ਸਫ਼ੇ",
+ "categorytree-mode-all": "ਸਭ ਸਫ਼ੇ",
+ "categorytree-collapse": "ਸਮੇਟੋ",
+ "categorytree-expand": "ਫੈਲਾਓ",
+ "categorytree-member-counts": "{{PLURAL:$1|1 ਉੱਪਸ਼੍ਰੇਣੀ|$1 ਉੱਪਸ਼੍ਰੇਣੀਆਂ}}, {{PLURAL:$2|1 ਸਫ਼ਾ|$2 ਸਫ਼ੇ}}, ਅਤੇ {{PLURAL:$3|1 ਫ਼ਾਈਲ|$3 ਫ਼ਾਈਲਾਂ}} ਮੌਜੂਦ",
+ "categorytree-num-categories": "$1 ਸ਼",
+ "categorytree-num-pages": "$1 ਸ",
+ "categorytree-num-files": "$1 ਫ਼",
+ "categorytree-num-empty": "ਖ਼ਾਲੀ",
+ "categorytree-load": "ਲੋਡ ਕਰੋ",
+ "categorytree-loading": "ਲੋਡ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ...",
+ "categorytree-nothing-found": "ਕੁਝ ਨਹੀਂ ਲੱਭਾ",
+ "categorytree-no-subcategories": "ਕੋਈ ਉਪ-ਸ਼੍ਰੇਣੀਆਂ ਨਹੀਂ",
+ "categorytree-no-parent-categories": "ਕੋਈ ਮੁਢਲੀ ਸ਼੍ਰੇਣੀਆਂ ਨਹੀਂ",
+ "categorytree-no-pages": "ਕੋਈ ਸਫ਼ੇ ਜਾਂ ਉਪ-ਸ਼੍ਰੇਣੀਆਂ ਨਹੀਂ",
+ "categorytree-not-found": "ਸ਼੍ਰੇਣੀ <i>$1</i> ਨਹੀਂ ਲੱਭੀ",
+ "categorytree-error": "ਸਮੱਗਰੀ ਲੋਡ ਕਰਨ ਮੌਕੇ ਔਕੜ।",
+ "categorytree-retry": "ਕੁਝ ਪਲ ਉਡੀਕੋ ਅਤੇ ਮੁੜ ਕੋਸ਼ਿਸ਼ ਕਰੋ।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pag.json b/www/wiki/extensions/CategoryTree/i18n/pag.json
new file mode 100644
index 00000000..c53562ff
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pag.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": [],
+ "categorytree-mode-pages": "Saray bolobolong ya aga kaibay picture",
+ "categorytree-mode-all": "Amin ya bolobolong",
+ "categorytree-collapse": "isara",
+ "categorytree-expand": "lukasan",
+ "categorytree-load": "I-lugan",
+ "categorytree-nothing-found": "anggapoy naanap",
+ "categorytree-no-pages": "Anggapoy bolong odino subcategory"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pam.json b/www/wiki/extensions/CategoryTree/i18n/pam.json
new file mode 100644
index 00000000..c723afa9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pam.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Val2397"
+ ]
+ },
+ "categorytree-mode-pages": "↓bulung liban kareng simpan",
+ "categorytree-mode-all": "Eganaganang bulung",
+ "categorytree-collapse": "ilati",
+ "categorytree-expand": "paragulan",
+ "categorytree-load": "lulan",
+ "categorytree-loading": "Lululan",
+ "categorytree-nothing-found": "alang meyakit"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pcd.json b/www/wiki/extensions/CategoryTree/i18n/pcd.json
new file mode 100644
index 00000000..83367c93
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pcd.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Geoleplubo"
+ ]
+ },
+ "categorytree": "Grafe des catégories"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pdc.json b/www/wiki/extensions/CategoryTree/i18n/pdc.json
new file mode 100644
index 00000000..a2c37dd2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pdc.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xqt"
+ ]
+ },
+ "categorytree": "Baam vun Abdeelinge",
+ "categorytree-portlet": "Abdeelinge",
+ "categorytree-legend": "Baam vun de Abdeeling zeige",
+ "categorytree-category": "Abdeeling:",
+ "categorytree-go": "Baam zeige",
+ "categorytree-parents": "Eldere",
+ "categorytree-mode-categories": "nur Abdeelinge",
+ "categorytree-mode-pages": "Bledder ohne Feils",
+ "categorytree-mode-all": "alle Bledder",
+ "categorytree-collapse": "zuklappe",
+ "categorytree-expand": "uffklappe",
+ "categorytree-member-counts": "hot {{PLURAL:$1|1 Unnerabdeeling|$1 Unnerabdeelinge}}, {{PLURAL:$2|1 Blatt|$2 Bledder}} unn {{PLURAL:$3|1 Feil|$3 Feils}}",
+ "categorytree-num-categories": "$1 A",
+ "categorytree-num-pages": "$1 B",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "leer",
+ "categorytree-load": "laade",
+ "categorytree-loading": "laade…",
+ "categorytree-nothing-found": "nix gfunne",
+ "categorytree-no-subcategories": "Ken Unnerabdeeling",
+ "categorytree-no-parent-categories": "Ken Owwerabdeeling",
+ "categorytree-no-pages": "Ken Bledder odder Unnerabdeelinge",
+ "categorytree-not-found": "Abdeeling „$1“ naett gfunne"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pfl.json b/www/wiki/extensions/CategoryTree/i18n/pfl.json
new file mode 100644
index 00000000..9886cc99
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pfl.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Manuae",
+ "Xqt"
+ ]
+ },
+ "categorytree": "Kadegorijeboom",
+ "categorytree-portlet": "Kadegorije",
+ "categorytree-legend": "Kadegorijeboom zaische",
+ "categorytree-category": "Kadegorie:",
+ "categorytree-go": "Lade",
+ "categorytree-parents": "Owakadegorije",
+ "categorytree-mode-all": "alle Saide",
+ "categorytree-collapse": "zuglabbe",
+ "categorytree-expand": "uffglabbe",
+ "categorytree-member-counts": "Hodd {{PLURAL:$1|1 Sachgrubb|$1 Sachgrubbe}}, {{PLURAL:$2|1 Said|$2 Saide}} unn {{PLURAL:$3|1 Dadai|$3 Dadaije}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 K",
+ "categorytree-nothing-found": "nix gfunne",
+ "categorytree-no-subcategories": "Kä Unakadegorije",
+ "categorytree-no-parent-categories": "Kä Owakadegorije",
+ "categorytree-no-pages": "Kä Saide oda Unakadegorije",
+ "categorytree-not-found": "Kadegorie „$1“ hods ned",
+ "categorytree-error": "Daade kennen ned gelade were.",
+ "categorytree-retry": "Waad ä bissl un brobias nomol"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pih.json b/www/wiki/extensions/CategoryTree/i18n/pih.json
new file mode 100644
index 00000000..a123a696
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pih.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-member-counts": "Contains {{PLURAL:$1|1 subcategory|$1 subcategories}}, {{PLURAL:$2|1 paij|$2 paijs}}, and {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pl.json b/www/wiki/extensions/CategoryTree/i18n/pl.json
new file mode 100644
index 00000000..4242dc37
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pl.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Airwolf",
+ "Derbeth",
+ "Matma Rex",
+ "Sp5uhe",
+ "Chrumps",
+ "Woytecr"
+ ]
+ },
+ "categorytree": "Drzewo kategorii",
+ "categorytree-portlet": "Kategorie",
+ "categorytree-legend": "Pokaż drzewo kategorii",
+ "categorytree-desc": "Gadżet oparty na technologii AJAX, wyświetlający [[Special:CategoryTree|drzewo kategorii]]",
+ "categorytree-header": "Wpisz nazwę kategorii, by zobaczyć jej zawartość w postaci drzewa (wymagany JavaScript).",
+ "categorytree-category": "Kategoria",
+ "categorytree-go": "Ładuj kategorię",
+ "categorytree-parents": "Kategorie główne",
+ "categorytree-mode-label": "Tryb:",
+ "categorytree-mode-categories": "tylko kategorie",
+ "categorytree-mode-pages": "strony oprócz plików",
+ "categorytree-mode-all": "wszystkie strony",
+ "categorytree-collapse": "zwiń",
+ "categorytree-expand": "rozwiń",
+ "categorytree-member-counts": "Zawiera {{PLURAL:$1|1 podkategorię|$1 podkategorie|$1 podkategorii}}, {{PLURAL:$2|1 stronę|$2 strony|$2 stron}} i {{PLURAL:$3|1 plik|$3 pliki|$3 plików}}",
+ "categorytree-num-categories": "$1 kat.",
+ "categorytree-num-pages": "$1 str.",
+ "categorytree-num-files": "$1 pl.",
+ "categorytree-num-empty": "pusta",
+ "categorytree-load": "wczytaj",
+ "categorytree-loading": "wczytywanie...",
+ "categorytree-nothing-found": "nic nie znaleziono",
+ "categorytree-no-subcategories": "brak podkategorii",
+ "categorytree-no-parent-categories": "brak kategorii nadrzędnej",
+ "categorytree-no-pages": "brak artykułów lub podkategorii.",
+ "categorytree-not-found": "Kategoria <i>$1</i> nie została znaleziona",
+ "categorytree-error": "Problem z ładowaniem danych.",
+ "categorytree-retry": "Poczekaj chwilę i spróbuj ponownie – kliknij ten napis.",
+ "apihelp-categorytree-description": "Wewnętrzny moduł rozszerzenia CategoryTree.",
+ "apihelp-categorytree-param-category": "Tytuł w przestrzeni nazw kategorii, prefiks będzie ignorowany jeżeli podany.",
+ "apihelp-categorytree-param-options": "Opcje dla konstruktora CategoryTree w postaci obiektu JSON. Opcja <var>depth</var> domyślnie wynosi <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Opcje powinny być prawidłowymi obiektami JSON."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pms.json b/www/wiki/extensions/CategoryTree/i18n/pms.json
new file mode 100644
index 00000000..c5d4b05c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pms.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bèrto 'd Sèra",
+ "Dragonòt"
+ ]
+ },
+ "categorytree": "Erbo dle categorìe",
+ "categorytree-portlet": "Categorìe",
+ "categorytree-legend": "Mosta l'erbo dle categorìe",
+ "categorytree-desc": "Nàviga dinamicament la [[Special:CategoryTree|strutura dle categorìe]]",
+ "categorytree-header": "Ch'a buta ël nòm ëd na categorìa për ës-ciairene ij contnù e la strutura. Ch'a ten-a present che përchè sòn a travaja a-i va na fonsion Javascript avansà ch'as ciama AJAX. Se un a l'ha un navigator vej ò pura a l'ha nen abilità Javascript sossì a travaja nen.",
+ "categorytree-category": "Categorìa:",
+ "categorytree-go": "Deurbe l'erbo",
+ "categorytree-parents": "Cé",
+ "categorytree-mode-label": "Manera:",
+ "categorytree-mode-categories": "smon mach le categorìe",
+ "categorytree-mode-pages": "mach le pàgine gavà le figure",
+ "categorytree-mode-all": "tute le pàgine",
+ "categorytree-collapse": "sëré",
+ "categorytree-expand": "deurbe",
+ "categorytree-member-counts": "a conten {{PLURAL:$1|1 sotcategorìa|$1 sotcategorìe}}, {{PLURAL:$2|1 pàgina|$2 pàgine}}, e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "veuid",
+ "categorytree-load": "carié",
+ "categorytree-loading": "antramentr ch'as carìa",
+ "categorytree-nothing-found": "pa trovà gnente",
+ "categorytree-no-subcategories": "gnun-a sot-categorìa",
+ "categorytree-no-parent-categories": "gnun-e categorìe superior",
+ "categorytree-no-pages": "pa ëd pàgine ò ëd sot-categorìe",
+ "categorytree-not-found": "A l'é pa trovasse la categorìa <i>$1</i>.",
+ "categorytree-error": "Problema ën cariand ij dat",
+ "categorytree-retry": "Për piasì, ch'a speta na minuta e peuj ch'as preuva n'àutra vira."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pnb.json b/www/wiki/extensions/CategoryTree/i18n/pnb.json
new file mode 100644
index 00000000..50786d91
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pnb.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Khalid Mahmood",
+ "Abbas dhothar"
+ ]
+ },
+ "categorytree": "گٹھ لین",
+ "categorytree-portlet": "گٹھاں",
+ "categorytree-legend": "گٹھ لین وکھاؤ",
+ "categorytree-desc": "ویکھ کے [[Special:CategoryTree|گٹھاں]] دی کھوج کرو",
+ "categorytree-header": "کسی گٹھ دا ناں لکھو تاکے ایدا مال رکھ ورگی مورت چ ویکھو۔\nNote that this requires advanced JavaScript functionality known as AJAX.\nIf you have a very old browser, or have JavaScript disabled, it will not work.",
+ "categorytree-category": "گٹھ:",
+ "categorytree-go": "لین وکھاؤ",
+ "categorytree-parents": "وڈوڈیرے",
+ "categorytree-mode-categories": "صرف گٹھاں",
+ "categorytree-mode-pages": "فائلاں بنا صفے",
+ "categorytree-mode-all": "سارے صفے",
+ "categorytree-collapse": "مک گیا",
+ "categorytree-expand": "ودھاؤ",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "ایدے چ {{PLURAL:$1|1 نکی گٹھ|$1 گٹھاں}}, {{PLURAL:$2|1 صفحہ|$2 صفحے}}, تے {{PLURAL:$3|1 فائل|$3 فائلاں}} ہیگیاں نیں۔",
+ "categorytree-num-categories": "$1 سی",
+ "categorytree-num-pages": "$1 پی",
+ "categorytree-num-files": "$1 ایف",
+ "categorytree-num-empty": "خالی",
+ "categorytree-load": "چڑھاؤ",
+ "categorytree-loading": "چڑھ رہی اے",
+ "categorytree-nothing-found": "کجھ نئیں لبھیا",
+ "categorytree-no-subcategories": "ذیلی گٹھاں نئیں",
+ "categorytree-no-parent-categories": "کوئی مڈلیاں گٹھاں نئیں۔",
+ "categorytree-no-pages": "ناں صفحے یا ذیلی گٹھاں",
+ "categorytree-not-found": "<i>$1</i> گٹھ نئیں لبھی",
+ "categorytree-error": "ڈیٹا چڑھان چ رپھڑ۔",
+ "categorytree-retry": "مہربانی کرکے تھوڑا صبر کرو تے فیر کوشش کرو۔"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pnt.json b/www/wiki/extensions/CategoryTree/i18n/pnt.json
new file mode 100644
index 00000000..75d97449
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pnt.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sinopeus"
+ ]
+ },
+ "categorytree-portlet": "Κατηγορίας",
+ "categorytree-category": "Κατηγορία:",
+ "categorytree-mode-all": "ούλ' σελίδας",
+ "categorytree-load": "φόρτωμαν",
+ "categorytree-loading": "φορτών'"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/prs.json b/www/wiki/extensions/CategoryTree/i18n/prs.json
new file mode 100644
index 00000000..4fe6d8f8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/prs.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mjbmr"
+ ]
+ },
+ "categorytree-expand": "گسترش",
+ "categorytree-member-counts": "شامل {{PLURAL:$1|یک زیر دسته|$1 زیر دسته}}، {{PLURAL:$2|یک صفحه|$2 صفحه}}، و {{PLURAL:$3|یک فایل|$3 فایل}} است",
+ "categorytree-num-categories": "$1 د",
+ "categorytree-num-pages": "$1 ص"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ps.json b/www/wiki/extensions/CategoryTree/i18n/ps.json
new file mode 100644
index 00000000..2accb337
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ps.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ahmed-Najib-Biabani-Ibrahimkhel",
+ "عثمان خان شاہ"
+ ]
+ },
+ "categorytree": "د وېشنيزو ونه",
+ "categorytree-portlet": "وېشنيزې",
+ "categorytree-legend": "د وېشنيزې ونه ښکاره کول",
+ "categorytree-category": ":وېشنيزه",
+ "categorytree-go": "ونه ښکاره کول",
+ "categorytree-mode-categories": "يوازې وېشنيزې",
+ "categorytree-mode-pages": "مخونه پرته د دوتنو نه",
+ "categorytree-mode-all": "ټول مخونه",
+ "categorytree-collapse": "پرځول",
+ "categorytree-expand": "غځول",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "{{PLURAL:$1|1 څېرمه وېشنيزه|$1 څېرمه وېشنيزې}}، {{PLURAL:$2|1 مخ|$2 مخونه}} او {{PLURAL:$3|1 دوتنه|$3 دوتنې}} لري",
+ "categorytree-num-categories": "$1 و",
+ "categorytree-num-pages": "$1 م",
+ "categorytree-num-files": "$1 د",
+ "categorytree-num-empty": "تش",
+ "categorytree-load": "برسېرول",
+ "categorytree-loading": "برسېرېدنې کې دی...",
+ "categorytree-nothing-found": "هېڅ هم و نه موندل شو",
+ "categorytree-no-subcategories": "هېڅ وړې-وېشنيزې نشته",
+ "categorytree-no-parent-categories": "مورنۍ وېشنيزې نشته",
+ "categorytree-no-pages": "هېڅ مخ يا وړه-وېشنيزه نشته",
+ "categorytree-not-found": "د <i>$1</i> وېشنيزه و نه موندل شوه",
+ "categorytree-error": "د مالوماتو د برسېرېدلو ستونزه.",
+ "categorytree-retry": "مهرباني وکړی لږ څه تم شی او بيا يې وآزمايۍ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pt-br.json b/www/wiki/extensions/CategoryTree/i18n/pt-br.json
new file mode 100644
index 00000000..01edb413
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pt-br.json
@@ -0,0 +1,48 @@
+{
+ "@metadata": {
+ "authors": [
+ "Carla404",
+ "Dicionarista",
+ "Eduardo.mps",
+ "Rafael Vargas",
+ "555",
+ "Eduardo Addad de Oliveira",
+ "Felipe L. Ewald"
+ ]
+ },
+ "categorytree": "Árvore de categorias",
+ "categorytree-portlet": "Categorias",
+ "categorytree-legend": "Mostrar árvore de categorias",
+ "categorytree-desc": "Navegação dinâmica pela [[Special:CategoryTree|estrutura de categorias]]",
+ "categorytree-header": "Insira o nome de uma categoria para ver os seus conteúdos numa estrutura de árvore. (Requer JavaScript).",
+ "categorytree-category": "Categoria:",
+ "categorytree-go": "Exibir árvore",
+ "categorytree-parents": "Categorias superiores",
+ "categorytree-mode-label": "Modo:",
+ "categorytree-mode-categories": "apenas as categorias",
+ "categorytree-mode-pages": "páginas, exceto arquivos",
+ "categorytree-mode-all": "todas as páginas",
+ "categorytree-collapse": "recolher",
+ "categorytree-expand": "expandir",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "Possui {{PLURAL:$1|1 subcategoria|$1 subcategorias}}, {{PLURAL:$2|1 página|$2 páginas}} e {{PLURAL:$3|1 arquivo|$3 arquivos}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vazio",
+ "categorytree-load": "carregar",
+ "categorytree-loading": "carregando...",
+ "categorytree-nothing-found": "nada foi encontrado",
+ "categorytree-no-subcategories": "sem subcategorias",
+ "categorytree-no-parent-categories": "não há categorias superiores",
+ "categorytree-no-pages": "sem páginas nem subcategorias",
+ "categorytree-not-found": "A categoria <i>$1</i> não foi encontrada",
+ "categorytree-error": "Problema ao acessar os dados.",
+ "categorytree-retry": "Aguarde um momento e tente novamente.",
+ "apihelp-categorytree-description": "Módulo interno para a extensão \"Árvore de categorias\" (<i>CategoryTree</i>).",
+ "apihelp-categorytree-summary": "Módulo interno para a extensão \"Árvore de categorias\" (<i>CategoryTree</i>).",
+ "apihelp-categorytree-param-category": "Título no espaço nominal Categoria, o prefixo será ignorado se for fornecido.",
+ "apihelp-categorytree-param-options": "Opções para o construtor CategoryTree como objeto JSON. A opção <var>depth</var> tem o valor predefinido <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "As opções devem ser um objeto JSON válido."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/pt.json b/www/wiki/extensions/CategoryTree/i18n/pt.json
new file mode 100644
index 00000000..21359822
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/pt.json
@@ -0,0 +1,47 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dicionarista",
+ "Giro720",
+ "Hamilton Abreu",
+ "João Sousa",
+ "Luckas",
+ "555",
+ "Vitorvicentevalente",
+ "Mansil"
+ ]
+ },
+ "categorytree": "Árvore de categorias",
+ "categorytree-portlet": "Categorias",
+ "categorytree-legend": "Mostrar árvore de categorias",
+ "categorytree-desc": "Acessório (<i>gadget</i>) baseado em AJAX que apresenta a [[Special:CategoryTree|estrutura de categorias]] de uma wiki",
+ "categorytree-header": "Insira o nome de uma categoria para ver os seus conteúdos numa estrutura de árvore. (Requer JavaScript).",
+ "categorytree-category": "Categoria:",
+ "categorytree-go": "Mostrar árvore",
+ "categorytree-parents": "Categorias superiores",
+ "categorytree-mode-label": "Modo:",
+ "categorytree-mode-categories": "mostrar apenas as categorias",
+ "categorytree-mode-pages": "páginas, exceto imagens",
+ "categorytree-mode-all": "todas as páginas",
+ "categorytree-collapse": "ocultar",
+ "categorytree-expand": "expandir",
+ "categorytree-member-counts": "Contém {{PLURAL:$1|$1 subcategoria|$1 subcategorias}}, {{PLURAL:$2|$2 página|$2 páginas}} e {{PLURAL:$3|$3 ficheiro|$3 ficheiros}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vazia",
+ "categorytree-load": "carregar",
+ "categorytree-loading": "a carregar...",
+ "categorytree-nothing-found": "não foi encontrado nada",
+ "categorytree-no-subcategories": "sem subcategorias",
+ "categorytree-no-parent-categories": "não há categorias superiores",
+ "categorytree-no-pages": "sem páginas nem subcategorias",
+ "categorytree-not-found": "A categoria <i>$1</i> não foi encontrada",
+ "categorytree-error": "Problema ao carregar os dados.",
+ "categorytree-retry": "Aguarde um momento e tente novamente, por favor.",
+ "apihelp-categorytree-description": "Módulo interno para a extensão \"Árvore de categorias\" (<i>CategoryTree</i>).",
+ "apihelp-categorytree-summary": "Módulo interno para a extensão \"Árvore de categorias\" (<i>CategoryTree</i>).",
+ "apihelp-categorytree-param-category": "Título no espaço nominal Categoria, o prefixo será ignorado se for fornecido.",
+ "apihelp-categorytree-param-options": "Opções para o construtor CategoryTree como objeto JSON. A opção <var>depth</var> tem o valor predefinido <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "As opções devem ser um objeto JSON válido."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/qqq.json b/www/wiki/extensions/CategoryTree/i18n/qqq.json
new file mode 100644
index 00000000..23f188b8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/qqq.json
@@ -0,0 +1,63 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Aotake",
+ "EugeneZelenko",
+ "Jon Harald Søby",
+ "Lloffiwr",
+ "Malafaya",
+ "McDutchie",
+ "Meno25",
+ "Raimond Spekking",
+ "Raymond",
+ "Shirayuki",
+ "Siebrand",
+ "The Evil IP address",
+ "Umherirrender",
+ "Yekrats",
+ "Александр Сигачёв",
+ "פוילישער",
+ "Purodha",
+ "Nemo bis"
+ ]
+ },
+ "categorytree": "{{doc-special|CategoryTree}}",
+ "categorytree-portlet": "Title for the CategoryPortlet, when shown in the side bar.\n{{Identical|Category}}",
+ "categorytree-legend": "Legend of the fieldset around the input form of [[Special:Categorytree]].",
+ "categorytree-desc": "{{desc|name=Category Tree|url=https://www.mediawiki.org/wiki/Extension:CategoryTree}}",
+ "categorytree-header": "Header-text shown on [[Special:CategoryTree]]",
+ "categorytree-category": "Label for the category input field on Special:CategoryTree.\n{{Identical|Category}}",
+ "categorytree-go": "Label for the submit button on [[Special:CategoryTree]]",
+ "categorytree-parents": "Label for the list of parent categories on [[Special:CategoryTree]].\n{{Identical|Parent}}",
+ "categorytree-mode-label": "Used as label for \"Mode\" select box.\n\nThis message follows the input box {{msg-mw|categorytree-category}}.\n\nThis message is followed by the select box {{msg-mw|namespace}}.\n{{Identical|Mode}}",
+ "categorytree-mode-categories": "Item for the mode choice on [[Special:CategoryTree]], indicating that only categories are listed",
+ "categorytree-mode-pages": "Item for the mode choice on [[Special:CategoryTree]], indicating that no images in categories are listed",
+ "categorytree-mode-all": "Item for the mode choice on [[Special:CategoryTree]], indicating that all pages are listed.\n\n{{Identical|All pages}}",
+ "categorytree-collapse": "Tooltip for the \"collapse\" button.\n{{Identical|Collapse}}",
+ "categorytree-expand": "Tooltip for the \"expand\" button.\n{{Identical|Expand}}",
+ "categorytree-collapse-bullet": "{{notranslate}}",
+ "categorytree-expand-bullet": "For right-to-left scripts, set this message to the single character ◄ . Otherwise, do not translate this message. Does not support wiki-syntax, html or entity references. \n{{optional}}",
+ "categorytree-empty-bullet": "Prefix used before category names in category pages when the number of subcategories (or something) is 0, to indicate that there is no sub-tree of items to expand. Does not support wiki-syntax, html or entity references.",
+ "categorytree-page-bullet": "{{notranslate}}",
+ "categorytree-member-counts": "Tooltip showing a detailed summary of subcategory member counts. Parameters:\n* $1 - number of subcategories\n* $2 - number of pages (without subcategories and files)\n* $3 - number of files\n* $4 - (Unused) total number of members\n* $5 - (Unused) members to be shown in the tree, depending on mode\nUse with <nowiki>{{PLURAL}}</nowiki>",
+ "categorytree-member-num": "{{notranslate}}\nHowever, if needed, you can localise the parentheses.\n\n(From https://www.mediawiki.org/wiki/Extension:CategoryTree#categorytree-member-num):\nBy default, when listing subcategories on a category page, each subcategory is followed by an integer indicating how many subcategories lie beneath it:\n<pre>\nMy category name (5)\n</pre>\nYou can change this behavior by overriding this system message. Parameters:\n* $1 - (Unused) number of subcategories\n* $2 - (Unused) number of articles (not including category pages or file pages)\n* $3 - (Unused) number of uploaded files\n* $4 - (Unused) total number of member pages, including category pages and file pages\n* $5 - (Varies depending on CategoryTree mode....Can someone describe it?)\n\nTip: Use the ParserFunctions extension (https://www.mediawiki.org/wiki/Help:Extension:ParserFunctions) to provide if/then/else logic to display different parts conditionally. For example:\n<pre>\n{{#ifeq:$1|0||$1 categories}}\n</pre>",
+ "categorytree-num-categories": "Number of sub-categories in a category. Appears in brackets after a name of an empty category.\n\nThe word \"categories\" should be abbreviated.\n\nParameters:\n* $1 - number of sub-categories. Can be used for PLURAL.\n{{Related|Categorytree-num}}",
+ "categorytree-num-pages": "Number of pages in a category. Appears in brackets after a name of an empty category.\n\nThe word \"pages\" should be abbreviated.\n\nParameters:\n* $1 - number of pages. Can be used for PLURAL.\n{{Related|Categorytree-num}}",
+ "categorytree-num-files": "Number of files in a category. Appears in brackets after a name of an empty category.\n\nThe word \"files\" should be abbreviated.\n\nParameters:\n* $1 - number of files. Can be used for PLURAL.\n{{Related|Categorytree-num}}",
+ "categorytree-num-empty": "The word \"empty\", as in \"empty category\". Appears in brackets after a name of an empty category.\n{{Identical|Empty}}",
+ "categorytree-load": "Tooltip for the \"expand\" button, if the content was not yet loaded.\n{{Identical|Load}}",
+ "categorytree-loading": "Status message shown while loading content.\n{{Identical|Loading}}",
+ "categorytree-nothing-found": "Indicates items with matching criteria have been found",
+ "categorytree-no-subcategories": "Indicates that there are no subcategories to be shown",
+ "categorytree-no-parent-categories": "Indicates that there are no parent categories to be shown",
+ "categorytree-no-pages": "Indicates that there are no pages or subcategories to be shown",
+ "categorytree-not-found": "Indicates that the given category ($1) was not found. Parameters:\n* $1 - category name",
+ "categorytree-error": "Indicates that an error has occurred while loading the node's content",
+ "categorytree-retry": "Instruction to try again later",
+ "apihelp-categorytree-description": "{{doc-apihelp-description|categorytree}}",
+ "apihelp-categorytree-summary": "{{doc-apihelp-summary|categorytree}}",
+ "apihelp-categorytree-param-category": "{{doc-apihelp-param|categorytree|category}}",
+ "apihelp-categorytree-param-options": "{{doc-apihelp-param|categorytree|options}}",
+ "apierror-categorytree-invalidjson": "{{doc-apierror}}"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/qu.json b/www/wiki/extensions/CategoryTree/i18n/qu.json
new file mode 100644
index 00000000..4b405c18
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/qu.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "AlimanRuna"
+ ]
+ },
+ "categorytree": "Katiguriya sach'a (CategoryTree)",
+ "categorytree-portlet": "Katiguriyakuna",
+ "categorytree-legend": "Katiguriya sach'ata rikuchiy",
+ "categorytree-desc": "[[Special:CategoryTree|Katiguriya sach'anta]] kuyuylla wamp'uy",
+ "categorytree-header": "Katiguriya sutita yaykuchiy samiqninta sach'a hinata rikunaykipaq.\nMusyariy, kaytaqa AJAX nisqa sapaq JavaScript ruranallawanmi llamk'achiyta atinki. Mawk'a wamp'unawanqa icha JavaScript nisqaman ama nispaqa manam atinkichu.",
+ "categorytree-category": "Katiguriya:",
+ "categorytree-go": "Sach'ata rikuchiy",
+ "categorytree-parents": "Mama katiguriyakuna",
+ "categorytree-mode-label": "Hina:",
+ "categorytree-mode-categories": "Katiguriyakunalla",
+ "categorytree-mode-pages": "p'anqakuna amataq rikchakuna",
+ "categorytree-mode-all": "tukuy p'anqakuna",
+ "categorytree-collapse": "pakay",
+ "categorytree-expand": "rikuchiy",
+ "categorytree-member-counts": "{{PLURAL:$1|huk urin katiguriyayuqmi|$1 urin katiguriyayuqmi}}, {{PLURAL:$2|huk p'anqayuqmi|$2 p'anqayuqmi}}, {{PLURAL:$3|huk willañiqiyuqmi|$3 willañiqiyuqmi}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 W",
+ "categorytree-num-empty": "ch'usaq",
+ "categorytree-load": "chaqnay",
+ "categorytree-loading": "chaqnaspa",
+ "categorytree-nothing-found": "manam imapas tarisqachu",
+ "categorytree-no-subcategories": "mana ima urin katiguriyapas",
+ "categorytree-no-parent-categories": "manam kanchu mama katiguriyakuna",
+ "categorytree-no-pages": "mana ima urin qillqapas ni katiguriyapas",
+ "categorytree-not-found": "<i>$1</i> sutiyuq katiguriyaqa manam tarisqachu",
+ "categorytree-error": "Manam atinichu willakunata chaqnayta.",
+ "categorytree-retry": "Asllata suyaspa musuqmanta ruraykachay."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/qwh.json b/www/wiki/extensions/CategoryTree/i18n/qwh.json
new file mode 100644
index 00000000..d0a94ebf
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/qwh.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michaelobregon"
+ ]
+ },
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/rif.json b/www/wiki/extensions/CategoryTree/i18n/rif.json
new file mode 100644
index 00000000..1ee06664
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/rif.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amara-Amaziɣ"
+ ]
+ },
+ "categorytree-num-pages": "$1 ⵙⵏ",
+ "categorytree-num-files": "$1 ⴼⵢⵍ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/rm.json b/www/wiki/extensions/CategoryTree/i18n/rm.json
new file mode 100644
index 00000000..0be3ba64
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/rm.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kazu89",
+ "Terfili"
+ ]
+ },
+ "categorytree": "Structura da las categorias",
+ "categorytree-portlet": "Categorias",
+ "categorytree-category": "Categoria:",
+ "categorytree-mode-all": "Tut las paginas",
+ "categorytree-collapse": "cumprimer",
+ "categorytree-expand": "extender",
+ "categorytree-member-counts": "Cuntegna {{PLURAL:$1|1 sutcategoria|$1 sutcategorias}}, {{PLURAL:$2|1 pagina|$2 paginas}}, ed {{PLURAL:$3|1 datoteca|$3 datotecas}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "vid",
+ "categorytree-loading": "chargiar…"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ro.json b/www/wiki/extensions/CategoryTree/i18n/ro.json
new file mode 100644
index 00000000..aa97848c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ro.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cin",
+ "Firilacroco",
+ "KlaudiuMihaila",
+ "Mihai",
+ "Minisarm",
+ "Stelistcristi",
+ "XXN"
+ ]
+ },
+ "categorytree": "Arborele categoriilor",
+ "categorytree-portlet": "Categorii",
+ "categorytree-legend": "Arată arborele categoriilor",
+ "categorytree-desc": "Navighează dinamic în [[Special:CategoryTree|stuctura categoriilor]]",
+ "categorytree-header": "Introduceți numele categoriei pentru vizualizarea conținutului în structură arborescentă. Notați faptul că această operație necesită funcționalități JavaScript avansate cunoscute sub numele de AJAX. Dacă aveți un browser vechi sau nu aveți activat JavaScript, nu va funcționa.",
+ "categorytree-category": "Categorie:",
+ "categorytree-go": "Arată arborele",
+ "categorytree-parents": "Părinți",
+ "categorytree-mode-label": "Mod:",
+ "categorytree-mode-categories": "doar categorii",
+ "categorytree-mode-pages": "pagini fără imagini",
+ "categorytree-mode-all": "toate paginile",
+ "categorytree-collapse": "restrânge",
+ "categorytree-expand": "extinde",
+ "categorytree-member-counts": "conține {{PLURAL:$1|1 subcategorie|$1 subcategorii}}, {{PLURAL:$2|1 pagină|$2 pagini}} și {{PLURAL:$3|1 fișier|$3 fișiere}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "fără conținut",
+ "categorytree-load": "încarcă",
+ "categorytree-loading": "încărcare…",
+ "categorytree-nothing-found": "fără rezultat",
+ "categorytree-no-subcategories": "nici o subcategorie",
+ "categorytree-no-parent-categories": "nici o categorie părinte",
+ "categorytree-no-pages": "nicio pagină sau subcategorie",
+ "categorytree-not-found": "Categoria <i>$1</i> nu a fost găsită",
+ "categorytree-error": "Problemă la încărcarea datelor",
+ "categorytree-retry": "Vă rugăm să așteptați câteva momente și să încercați din nou."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/roa-tara.json b/www/wiki/extensions/CategoryTree/i18n/roa-tara.json
new file mode 100644
index 00000000..d3122bf3
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/roa-tara.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras"
+ ]
+ },
+ "categorytree": "Arvule de le categorije",
+ "categorytree-portlet": "Categorije",
+ "categorytree-legend": "Fa vedè l'arvule de le categorije",
+ "categorytree-desc": "Dinamicamende naveghesce 'a [[Special:CategoryTree|struttura de le categorije]]",
+ "categorytree-header": "'Nzerisce 'nu nome de categorije pe 'ndrucà 'u condenute sue cumme a 'na strutture a arvule. (Vole 'u JavaScript.)",
+ "categorytree-category": "Categorije:",
+ "categorytree-go": "Fa vedè l'arvule",
+ "categorytree-parents": "Attane",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "sulamende categorije",
+ "categorytree-mode-pages": "pàggene eccette le file",
+ "categorytree-mode-all": "tutte le pàggene",
+ "categorytree-collapse": "achiude",
+ "categorytree-expand": "spanne",
+ "categorytree-member-counts": "condene {{PLURAL:$1|1 sotte categorije|$1 sotte categorije}}, {{PLURAL:$2|1 pàgene|$2 pàggene}}, e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vacande",
+ "categorytree-load": "careche",
+ "categorytree-loading": "stoche a careche…",
+ "categorytree-nothing-found": "acchiate ninde",
+ "categorytree-no-subcategories": "nisciuna sotte categorije",
+ "categorytree-no-parent-categories": "nisciuna categorije attane",
+ "categorytree-no-pages": "nisciune pàgene o sotte categorije",
+ "categorytree-not-found": "Categorije <i>$1</i> non acchiate",
+ "categorytree-error": "Probbleme carecanne le date.",
+ "categorytree-retry": "Aspitte 'nu mumende e pruève 'n'otra vote.",
+ "apihelp-categorytree-description": "Module 'nderne de l'estenzione CategoryTree.",
+ "apihelp-categorytree-summary": "Module 'nderne de l'estenzione CategoryTree.",
+ "apihelp-categorytree-param-category": "Titole jndr'à 'u namespace categorije, 'u prefisse avène cacate ce mise.",
+ "apihelp-categorytree-param-options": "Opziune pu costruttore CategoryTree cumme 'n'oggette JSON. L'opzione <var>depth</var> avène mise de base a <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Opziune onna essere valide pe 'n'oggette JSON."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ru.json b/www/wiki/extensions/CategoryTree/i18n/ru.json
new file mode 100644
index 00000000..ec65b951
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ru.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ahonc",
+ "Amire80",
+ "Kaganer",
+ "Lockal",
+ "Putnik",
+ "Александр Сигачёв",
+ "Okras"
+ ]
+ },
+ "categorytree": "Дерево категорий",
+ "categorytree-portlet": "Категории",
+ "categorytree-legend": "Показать дерево категорий",
+ "categorytree-desc": "AJAX-компонент для отображения [[Special:CategoryTree|структуры категорий]] вики",
+ "categorytree-header": "Введите имя категории для показана её содержимого в виде дерева (требуется JavaScript).",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Загрузить",
+ "categorytree-parents": "Родительские категории",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "только категории",
+ "categorytree-mode-pages": "кроме файлов",
+ "categorytree-mode-all": "все страницы",
+ "categorytree-collapse": "свернуть",
+ "categorytree-expand": "развернуть",
+ "categorytree-member-counts": "Содержит $1 {{PLURAL:$1|подкатегорию|подкатегории|подкатегорий}}, $2 {{PLURAL:$2|страницу|страницы|страниц}} и $3 {{PLURAL:$3|файл|файла|файлов}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "пусто",
+ "categorytree-load": "загрузить",
+ "categorytree-loading": "загрузка…",
+ "categorytree-nothing-found": "Данная категория не содержит подкатегорий.",
+ "categorytree-no-subcategories": "нет подкатегорий",
+ "categorytree-no-parent-categories": "нет родительских категорий",
+ "categorytree-no-pages": "нет статей и подкатегорий",
+ "categorytree-not-found": "Категория «$1» не найдена.",
+ "categorytree-error": "Ошибка загрузки данных.",
+ "categorytree-retry": "Пожалуйста, подождите и попробуйте ещё раз.",
+ "apihelp-categorytree-description": "Внутренний модуль для расширения CategoryTree.",
+ "apihelp-categorytree-summary": "Внутренний модуль для расширения CategoryTree.",
+ "apihelp-categorytree-param-category": "Название в пространстве имён категорий, префикс в случае задания игнорируется.",
+ "apihelp-categorytree-param-options": "Варианты для конструктора CategoryTree как JSON-объекта. Параметр <var>depth</var> (глубина) по умолчанию установлен как <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Варианты должны быть валидными JSON-объектами."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/rue.json b/www/wiki/extensions/CategoryTree/i18n/rue.json
new file mode 100644
index 00000000..082bd43b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/rue.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gazeb"
+ ]
+ },
+ "categorytree": "Дерево катеґорій",
+ "categorytree-portlet": "Катеґорії",
+ "categorytree-legend": "Указати дерево катеґорій",
+ "categorytree-desc": "AJAX-компонент про зображіня [[Special:CategoryTree|штруктуры катеґорій]] вікі",
+ "categorytree-header": "Зазначте назву катеґорії ку&nbsp;зображіню єй обсягу як стромовой штруктуры.\n\n(Тота функція потребує покрочілы функції JavaScript знамы як Ajax. Кідь маєте дуже старый переглядач або выпнутый JavaScript, не укаже ся стром правилно або нияк.)",
+ "categorytree-category": "Катеґорія:",
+ "categorytree-go": "Указати дерево",
+ "categorytree-parents": "Родичовскы катеґорії",
+ "categorytree-mode-categories": "лем катеґорії",
+ "categorytree-mode-pages": "сторінкы окрім файлів",
+ "categorytree-mode-all": "вшыткы сторінкы",
+ "categorytree-collapse": "згорнути",
+ "categorytree-expand": "розгорнути",
+ "categorytree-member-counts": "обсягує {{PLURAL:$1|1 підкатеґорію|$1 підкатеґорії|$1 підкатеґорій}}, {{PLURAL:$2|1 сторінку|$2 сторінкы|$2 сторінок}} і {{PLURAL:$3|1 файл|$3 файлы|$3 файлів}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "порожня",
+ "categorytree-load": "начітати",
+ "categorytree-loading": "начітавать ся...",
+ "categorytree-nothing-found": "ніч не найджене",
+ "categorytree-no-subcategories": "жадны підкатеґорії",
+ "categorytree-no-parent-categories": "не має родичовскы катеґорії",
+ "categorytree-no-pages": "жадны статї ані підкатеґорії",
+ "categorytree-not-found": "Катеґорія <em>$1</em> ненайджена",
+ "categorytree-error": "Хыба начітаня дат.",
+ "categorytree-retry": "Кус почекайте і потім спробуйте знову."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sa.json b/www/wiki/extensions/CategoryTree/i18n/sa.json
new file mode 100644
index 00000000..f02b9597
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sa.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ansumang",
+ "Shubha",
+ "Vibhijain",
+ "NehalDaveND"
+ ]
+ },
+ "categorytree": "वर्गवृक्षः",
+ "categorytree-portlet": "वर्गाः",
+ "categorytree-legend": "वर्गवृक्षः दर्श्यताम्",
+ "categorytree-desc": "[[Special:CategoryTree|category structure]] एतत् सक्रियं सञ्चालयतु",
+ "categorytree-header": "आधेयं वृक्षरूपेण द्रष्टुं वर्गस्य नाम योजयतु ।\nएतन्निमित्तं AJAX इति निर्दिष्टा सक्रिया परिष्कृता जावालिपिः अपेक्षिता ।\nयदि जालदर्शिका प्राचीना, जावालिपिः निष्क्रिया तर्हि एतत् कार्यं न करोति ।",
+ "categorytree-category": "वर्गः :",
+ "categorytree-go": "वृक्षं दर्शयतु",
+ "categorytree-parents": "पोषकाः",
+ "categorytree-mode-categories": "वर्गमात्रम्",
+ "categorytree-mode-pages": "सञ्चिकारहितानि पृष्ठानि",
+ "categorytree-mode-all": "सर्वाणि पृष्ठानि",
+ "categorytree-collapse": "सङ्कुच्यताम्",
+ "categorytree-expand": "विस्तीर्यताम्",
+ "categorytree-member-counts": "अस्मिन् {{PLURAL:$1| 1 उपवर्गः | $1 उपवर्गाः}}, {{PLURAL:$2| 1 पृष्ठम्| $2 पृष्ठानि}}, {{PLURAL:$3| 1 सञ्चिका | $3 सञ्चिकाः}} च विद्यन्ते ।",
+ "categorytree-num-categories": "$1 व",
+ "categorytree-num-pages": "$1 पृ",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "रिक्तम्",
+ "categorytree-load": "आरोपणम्",
+ "categorytree-loading": "आरोपयति...",
+ "categorytree-nothing-found": "न किञ्चित् प्राप्तम्",
+ "categorytree-no-subcategories": "उपवर्गाः न विद्यन्ते",
+ "categorytree-no-parent-categories": "पितृवर्गाः न विद्यन्ते",
+ "categorytree-no-pages": "पृष्ठानि उपवर्गाः वा न विद्यन्ते",
+ "categorytree-not-found": "<i>$1</i> वर्गः न प्राप्तः",
+ "categorytree-error": "विषयावतारणे समस्या ।",
+ "categorytree-retry": "कृपया क्षणानन्तरं पुनः प्रयतताम् ।"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sah.json b/www/wiki/extensions/CategoryTree/i18n/sah.json
new file mode 100644
index 00000000..ce7f92ac
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sah.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "HalanTul"
+ ]
+ },
+ "categorytree": "Категориялар мас курдук",
+ "categorytree-portlet": "Категориялар",
+ "categorytree-legend": "Категориялар тутулларын көрдөр",
+ "categorytree-desc": "Биики [[Special:CategoryTree|категорияларын тутулун]] көрдөрөр AJAX-компонент",
+ "categorytree-header": "Категория аатын киллэрдэххинэ мас курдук көстүөҕэ.\nБу кыаҕы браузерыҥ AJAX-ы туһанар эрэ буоллаҕына туттар кыахтааххын.\nБраузерыҥ эргэ буоллаҕына эбэтэр JavaScript арахсыбыт буоллаҕына субкатегорийалары мас курдук көрөр сатаммат.",
+ "categorytree-category": "Категория:",
+ "categorytree-go": "Көрдөр",
+ "categorytree-parents": "Төрөппүттэрэ",
+ "categorytree-mode-categories": "категориялар эрэ",
+ "categorytree-mode-pages": "билэттэн ураты (билэ буолбатах) сирэйдэр",
+ "categorytree-mode-all": "бары сирэйдэр",
+ "categorytree-collapse": "сап",
+ "categorytree-expand": "тэнит",
+ "categorytree-member-counts": "$1 {{PLURAL:$1|субкатегориялаах|субкатегориялардаах}}, $2 {{PLURAL:$2|сирэйдээх|сирэйдэрдээх}} уонна $3 {{PLURAL:$3|билэлээх|билэлэрдээх}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "кураанах",
+ "categorytree-load": "киллэр",
+ "categorytree-loading": "киллэрии",
+ "categorytree-nothing-found": "бу категория подкатегорията суох",
+ "categorytree-no-subcategories": "субкатегорията суох",
+ "categorytree-no-parent-categories": "төрөппүт категорията суох",
+ "categorytree-no-pages": "ыстатыйата эбэтэр субкатегорията суох",
+ "categorytree-not-found": "<i>$1</i> категория көстүбэтэ",
+ "categorytree-error": "Билэни суруйарга алҕас таҕыста",
+ "categorytree-retry": "Кыратык кэтэһэ түһэн баран өссө боруобалаа"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sat.json b/www/wiki/extensions/CategoryTree/i18n/sat.json
new file mode 100644
index 00000000..32258e71
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sat.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Albinus",
+ "Manik Soren",
+ "Ramjit Tudu"
+ ]
+ },
+ "categorytree": "ᱫᱟᱨᱮ ᱛᱷᱚᱠ",
+ "categorytree-portlet": "ᱛᱷᱚᱠ ᱠᱚ",
+ "categorytree-legend": "ᱥᱚᱫᱚᱨᱢᱮ ᱫᱟᱨᱮ ᱛᱷᱚᱠ",
+ "categorytree-category": "ᱛᱷᱚᱠ:",
+ "categorytree-go": "Dare uduḱme",
+ "categorytree-parents": "Gogo baba",
+ "categorytree-mode-label": "ᱰᱷᱚᱝ",
+ "categorytree-mode-categories": "ᱛᱷᱚᱠ ᱠᱚ ᱥᱩᱢᱩᱝ",
+ "categorytree-mode-all": "Sanam sakamko",
+ "categorytree-collapse": "Murchạo caba",
+ "categorytree-expand": "ᱯᱷᱟᱭᱞᱟᱣ",
+ "categorytree-member-counts": "Contains {{PLURAL:$1|1 ᱥᱟᱵ ᱠᱮᱴᱟᱜᱳᱨᱤ|$1 ᱥᱟᱵ ᱠᱮᱴᱟᱜᱳᱨᱤᱥ}}, {{PLURAL:$2|1 ᱥᱟᱦᱴᱟ|$2 ᱥᱟᱦᱴᱟᱠᱩ}}, and {{PLURAL:$3|1 ᱯᱷᱟᱭᱤᱞ|$3 ᱯᱷᱟᱭᱤᱞᱥ}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 ᱮᱯᱷ",
+ "categorytree-num-empty": "Khạligea",
+ "categorytree-load": "Rakaṕ",
+ "categorytree-loading": "Rakaṕkana",
+ "categorytree-nothing-found": "Cet́ hõ baṅ ńamlena",
+ "categorytree-not-found": "ᱛᱷᱚᱠ <i>$1</i> ᱵᱟᱭ ᱧᱟᱢᱞᱮᱱᱟ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sc.json b/www/wiki/extensions/CategoryTree/i18n/sc.json
new file mode 100644
index 00000000..f0fdb73f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sc.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Marzedu"
+ ]
+ },
+ "categorytree-portlet": "Categorias",
+ "categorytree-category": "Categoria:",
+ "categorytree-mode-all": "totu is pàginas"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/scn.json b/www/wiki/extensions/CategoryTree/i18n/scn.json
new file mode 100644
index 00000000..31e037a4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/scn.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aushulz",
+ "Santu",
+ "C.R.",
+ "Pippinu"
+ ]
+ },
+ "categorytree": "Àrvulu di li catigurìi",
+ "categorytree-portlet": "Catigurìi",
+ "categorytree-legend": "Ammustra l'àrvulu di li catigurìi",
+ "categorytree-desc": "Accissòriu AJAX pi taliari la [[Special:CategoryTree|struttura di li catigurìi]] dû situ",
+ "categorytree-header": "Nziriri lu nomu dâ catigirìa di unni si disìa taliari lu cuntinutu sutta furma di struttura a àrvulu. La pàggina addumanna li funziunalitati avanzati di JavaScript saputi sèntiri AJAX; si veni usatu nu browser vecchiu assai o li funzioni JavaScript sunnu disabbilitati, sta pàggina non funziona.",
+ "categorytree-category": "Catigurìa:",
+ "categorytree-go": "Càrica",
+ "categorytree-parents": "Catigurìi cchiù àuti",
+ "categorytree-mode-label": "Modu:",
+ "categorytree-mode-categories": "ammustra sulu li catigurìi",
+ "categorytree-mode-pages": "tutti li pàggini, lassannu fora li mmàggini",
+ "categorytree-mode-all": "tutti li pàggini",
+ "categorytree-collapse": "cumprimi",
+ "categorytree-expand": "spanni",
+ "categorytree-expand-bullet": "[<b>+</b>]",
+ "categorytree-empty-bullet": "[<b>×</b>]",
+ "categorytree-member-counts": "cunteni {{PLURAL:$1|1 suttacatigurìa|$1 suttacatigurìi}}, {{PLURAL:$2|1 pàggina|$2 pàggini}} e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "vacanti",
+ "categorytree-load": "càrica",
+ "categorytree-loading": "sta caricannu...",
+ "categorytree-nothing-found": "nuddu risurtatu",
+ "categorytree-no-subcategories": "nudda suttacatigurìa.",
+ "categorytree-no-parent-categories": "nudda catigurìa cchià àuta",
+ "categorytree-no-pages": "nudda vuci e nudda suttacatigurìa.",
+ "categorytree-not-found": "Catigurìa ''$1'' non attruvata",
+ "categorytree-error": "Prubbrema nnô caricamentu dî dati.",
+ "categorytree-retry": "Aspittari tanticchia e appoi pruvari n'ùutra vota."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sco.json b/www/wiki/extensions/CategoryTree/i18n/sco.json
new file mode 100644
index 00000000..83fe10b1
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sco.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "John Reid"
+ ]
+ },
+ "categorytree": "Categerie tree",
+ "categorytree-portlet": "Categeries",
+ "categorytree-legend": "Shaw categerie tree",
+ "categorytree-desc": "Dynameeclie navigate the [[Special:CategoryTree|categerie structure]]",
+ "categorytree-header": "Enter ae categerie name tae see its contents aes ae tree structure.\nMynd that this needs advanced JavaScript functionalitie knawn aes AJAX.\nGif ye hae ae fair audld brouser, or hae JavaScript disabled, it'll no wirk.",
+ "categorytree-category": "Categerie:",
+ "categorytree-go": "Shaw tree",
+ "categorytree-parents": "Pairents",
+ "categorytree-mode-label": "Mode:",
+ "categorytree-mode-categories": "categeries yinlie",
+ "categorytree-mode-pages": "pages except files",
+ "categorytree-mode-all": "aw pages",
+ "categorytree-collapse": "collapse",
+ "categorytree-expand": "mak muckler",
+ "categorytree-member-counts": "Contains {{PLURAL:$1|1 subcategerie|$1 subcategeries}}, {{PLURAL:$2|1 page|$2 pages}}, n {{PLURAL:$3|1 file|$3 files}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tuim",
+ "categorytree-load": "laid",
+ "categorytree-loading": "laidin…",
+ "categorytree-nothing-found": "nawthing foond",
+ "categorytree-no-subcategories": "nae subcategeries",
+ "categorytree-no-parent-categories": "nae pairent categeries",
+ "categorytree-no-pages": "nae pages or subcategeries",
+ "categorytree-not-found": "Categerie <i>$1</i> no foond",
+ "categorytree-error": "Proablem laidin data.",
+ "categorytree-retry": "Please wait ae moment n gie it anither shot."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sd.json b/www/wiki/extensions/CategoryTree/i18n/sd.json
new file mode 100644
index 00000000..8d6d7348
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sd.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sindhu",
+ "Mehtab ahmed"
+ ]
+ },
+ "categorytree-mode-all": "سڀ صفحا",
+ "categorytree-expand": "ڦھلايو",
+ "categorytree-member-counts": "مشتمل آھي {{PLURAL:$1|ذيلي زمرو|$1 ذيلي زمرا}}، {{PLURAL:$2|صفحو|$2 صفحا}}، ۽ {{PLURAL:$3|هڪ فائيل| $3 فائيلَ}}",
+ "categorytree-num-categories": "$1 ز",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 ف"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sdc.json b/www/wiki/extensions/CategoryTree/i18n/sdc.json
new file mode 100644
index 00000000..152dde5c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sdc.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Felis",
+ "Jun Misugi"
+ ]
+ },
+ "categorytree": "Sthruttura ad'àiburu di li categuri",
+ "categorytree-portlet": "Categuri",
+ "categorytree-legend": "Musthrà sthruttura ad'àiburu di li categuri",
+ "categorytree-header": "Insirì l'innommu di la categuria di la quari si vó vidé lu cuntinuddu attrabessu la sthruttura ad'àiburu. Amminta chi la pàgina vó li funzionariddai abanzaddi di JavaScript ciamaddi AJAX; s'ài un nabiggddori vécciu o cu' li funzioni JavaScript disàbiritaddi, chistha pàgina nò funziunerà.",
+ "categorytree-category": "Categuria:",
+ "categorytree-go": "Musthrà l'àiburu di categuri",
+ "categorytree-parents": "Categuri superiori",
+ "categorytree-mode-categories": "musthra soru li categuri",
+ "categorytree-mode-pages": "tutti li pàgini, eschrusi l'immàgini",
+ "categorytree-mode-all": "tutti li pàgini",
+ "categorytree-collapse": "cumprimi",
+ "categorytree-expand": "ippaglia",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "biodda",
+ "categorytree-load": "carrigga",
+ "categorytree-loading": "carrigghendi...",
+ "categorytree-nothing-found": "nisciun risulthaddu",
+ "categorytree-no-subcategories": "nisciuna sottucateguria.",
+ "categorytree-no-parent-categories": "nisciuni sottucateguri",
+ "categorytree-no-pages": "nisciuna bozi ni sottucateguria.",
+ "categorytree-not-found": "Categuria ''$1'' nò acciappadda",
+ "categorytree-error": "Probrema i' lu carriggamentu di li dati.",
+ "categorytree-retry": "Pa piazeri aisetta un'àttimu e poi torra a prubà."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sdh.json b/www/wiki/extensions/CategoryTree/i18n/sdh.json
new file mode 100644
index 00000000..104b7c26
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sdh.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kurdbuddha",
+ "Paraw2"
+ ]
+ },
+ "categorytree-mode-all": "گشت پەڕەگان",
+ "categorytree-expand": "بڵاوی بکەرە",
+ "categorytree-member-counts": "{{PLURAL:$1|یەک ژێرپۆل|$1 ژێرپۆل}}، {{PLURAL:$2|یەک پەڕە|$2 پەڕە}}، and {{PLURAL:$3|یەک پەڕگە|$3 پەڕگە}} لەوەرگرێدن",
+ "categorytree-num-categories": "$1 پۆل",
+ "categorytree-num-pages": "$1 پەڕە",
+ "categorytree-num-files": "$1 پەڕگە"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sgs.json b/www/wiki/extensions/CategoryTree/i18n/sgs.json
new file mode 100644
index 00000000..1ff24b37
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sgs.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hugo.arg"
+ ]
+ },
+ "categorytree": "Kateguorėju medis",
+ "categorytree-category": "Kateguorėjė:",
+ "categorytree-mode-all": "vėsė poslapē",
+ "categorytree-expand": "atsklēstė",
+ "categorytree-member-counts": "Tor {{PLURAL:$1|1 pukateguorėjė|$1 pukateguorėjės|$1 pukateguorėjū}}, {{PLURAL:$2|1 poslapi|$2 poslapius|$2 poslapiu}}, ė da {{PLURAL:$3|1 abruozdielis|$3 abruozdielius}}",
+ "categorytree-num-categories": "$1 p.",
+ "categorytree-num-pages": "$1 p.",
+ "categorytree-num-files": "$1 abr."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sh.json b/www/wiki/extensions/CategoryTree/i18n/sh.json
new file mode 100644
index 00000000..140e71b2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sh.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kolega2357",
+ "OC Ripper",
+ "Acamicamacaraca"
+ ]
+ },
+ "categorytree": "Stablasti prikaz hijerarhije kategorija",
+ "categorytree-portlet": "Kategorije",
+ "categorytree-legend": "Prikaži stablo kategorija",
+ "categorytree-desc": "Dinamička navigacija [[Special:CategoryTree|strukture kategorija]].",
+ "categorytree-header": "Unesite ime kategorije da vidite njen sadržaj kao strukturno stablo. Ovo zahtijeva proširenu JavaScript funkcionalnost kao AJAX. Ako imate neki stariji preglednik, ili ste isključili JavaScript, ovo neće raditi.",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Prikaži stablo",
+ "categorytree-parents": "Nadkategorije - Наткатегорије",
+ "categorytree-mode-categories": "samo kategorije - само категорије",
+ "categorytree-mode-pages": "stranice bez slika - странице без слика",
+ "categorytree-mode-all": "sve stranice - све странице",
+ "categorytree-collapse": "sakrij - сакриј",
+ "categorytree-expand": "proširi - прошири",
+ "categorytree-member-counts": "sadrži {{PLURAL:$1|jednu podkategoriju|$1 podkategorije|$1 podkategorija}}, {{PLURAL:$2|jednu stranicu|$2 stranice|$2 stranica}} i {{PLURAL:$3|jednu datoteku|$3 datoteke|$3 datoteka}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-load": "učitaj - учитај",
+ "categorytree-loading": "učitavam - учитавам",
+ "categorytree-nothing-found": "ništa nije pronađeno",
+ "categorytree-no-subcategories": "nema potkategorija",
+ "categorytree-no-parent-categories": "nema nadkategorija",
+ "categorytree-no-pages": "nema ni stranica ni podkategorija",
+ "categorytree-not-found": "Kategorija <i>$1</i> nije pronađena",
+ "categorytree-error": "Problem pri učitavanju podataka."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/shi.json b/www/wiki/extensions/CategoryTree/i18n/shi.json
new file mode 100644
index 00000000..14d4e464
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/shi.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amara-Amaziɣ"
+ ]
+ },
+ "categorytree-num-categories": "$1 ⴳⵢ",
+ "categorytree-num-pages": "$1 ⵙⵏ",
+ "categorytree-num-files": "$1 ⴼ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/shn.json b/www/wiki/extensions/CategoryTree/i18n/shn.json
new file mode 100644
index 00000000..a66d76b1
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/shn.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Saimawnkham"
+ ]
+ },
+ "categorytree-expand": "ၶႂၢၵ်ႈ",
+ "categorytree-member-counts": "ၶဝ်ႈပႃးဝႆႉ {{PLURAL:$1|1 ၵၼ်ၽႄ|$1 ၵၼ်ၽႄ}}, {{PLURAL:$2|1 ၼႃႈလိၵ်ႈ|$2 ၼႃႈလိၵ်ႈ}}, လႄႈ {{PLURAL:$3|1 ၾၢႆႇ|$3 ၾၢႆႇ}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/shy-latn.json b/www/wiki/extensions/CategoryTree/i18n/shy-latn.json
new file mode 100644
index 00000000..3ae6f1ee
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/shy-latn.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Vikoula5"
+ ]
+ },
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/si.json b/www/wiki/extensions/CategoryTree/i18n/si.json
new file mode 100644
index 00000000..7d1290db
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/si.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Singhalawap",
+ "නන්දිමිතුරු",
+ "පසිඳු කාවින්ද",
+ "බිඟුවා"
+ ]
+ },
+ "categorytree": "ප්‍රවර්ග බෙදීම් සටහන",
+ "categorytree-portlet": "ප්‍රවර්ග",
+ "categorytree-legend": "ප්‍රවර්ග ගස පෙන්වන්න",
+ "categorytree-desc": "[[Special:CategoryTree|ප්‍රවර්ග ව්‍යුහය]] ගතික වශයෙන් සංචලනය කරන්න",
+ "categorytree-header": "එහි අන්තර්ගතයන් රුක් ව්‍යුවහයක් ලෙස නැරඹීම සඳහා ප්‍රවර්ග නාමයක් ඇතුලත් කරන්න.\nAJAX නමින් හැඳින්වෙන ප්‍රගත ජාවාස්ක්‍රිප්ට් ශ්‍රීතියතායව මේ සඳහා අවශ්‍ය බව සටහන් කර ගන්න.\nඔබ සතුව ඇත්තේ ඉතා පැරණි බ්‍රවුසරයක් නම් හෝ ජාවාස්ක්‍රිප්ට් අක්‍රීය කොට තිබේ නම් මෙය ක්‍රි‍යාත්මක නොවනු ඇත.",
+ "categorytree-category": "ප්‍රවර්ගය:",
+ "categorytree-go": "බෙදීයාම් සටහන පෙන්වන්න",
+ "categorytree-parents": "මාපියන්",
+ "categorytree-mode-label": "ක්‍රමය:",
+ "categorytree-mode-categories": "ප්‍රවර්ග පමණයි",
+ "categorytree-mode-pages": "ගොනු හැර ඉතිරි පිටු",
+ "categorytree-mode-all": "සියළු පිටු",
+ "categorytree-collapse": "හකුලන්න",
+ "categorytree-expand": "විදහාලන්න",
+ "categorytree-member-counts": "{{PLURAL:$1|එක් උපප්‍රවර්ගයක්|උපප්‍රවර්ග $1 ක්}}, {{PLURAL:$2|එක් පිටුවක්|පිටු $2 ක්}}, සහ {{PLURAL:$3|එක් ගොනුවක්|ගොනු $3 ක්}} අඩංගුය",
+ "categorytree-num-categories": "ප්‍ර $1",
+ "categorytree-num-pages": "පිටු $1",
+ "categorytree-num-files": "ලිපි $1",
+ "categorytree-num-empty": "හිස්",
+ "categorytree-load": "බාගන්න",
+ "categorytree-loading": "බාගනිමින්…",
+ "categorytree-nothing-found": "කිසිවක් හමුනොවිනි",
+ "categorytree-no-subcategories": "උපප්‍රවර්ග නොමැත",
+ "categorytree-no-parent-categories": "මවු ප්‍රවර්ග නැත",
+ "categorytree-no-pages": "පිටු හෝ උපප්‍රවර්ග නොමැත",
+ "categorytree-not-found": "<i>$1</i> ප්‍රවර්ගය සොයාගත නොහැකි විය",
+ "categorytree-error": "දත්ත බාගැනීමේ ගැටළු පැවතිණි.",
+ "categorytree-retry": "කරුණාකර බිඳක් සිට යළි උත්සාහ කරන්න."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sk.json b/www/wiki/extensions/CategoryTree/i18n/sk.json
new file mode 100644
index 00000000..1073a341
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sk.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Helix84",
+ "Sudo77(new)",
+ "Teslaton"
+ ]
+ },
+ "categorytree": "Strom kategórií",
+ "categorytree-portlet": "Kategórie",
+ "categorytree-legend": "Zobraziť strom kategórií",
+ "categorytree-desc": "AJAXový nástroj na zobrazovanie [[Special:CategoryTree|štruktúry kategórií]] wiki",
+ "categorytree-header": "Zadajte názov kategórie, ktorej obsah sa má zobraziť ako stromová štruktúra.\nMajte na pamäti, že táto funkcia vyžaduje JavaScriptovú funkcionalitu známu ako AJAX.\nAk máte veľmi starý prehliadač alebo máte vypnutý JavaScrpt, nebude fungovať.",
+ "categorytree-category": "Kategória:",
+ "categorytree-go": "Zobraziť strom",
+ "categorytree-parents": "Nadradené kategórie",
+ "categorytree-mode-label": "Režim:",
+ "categorytree-mode-categories": "iba kategórie",
+ "categorytree-mode-pages": "stránky okrem obrázkov",
+ "categorytree-mode-all": "všetky stránky",
+ "categorytree-collapse": "zbaliť",
+ "categorytree-expand": "rozbaliť",
+ "categorytree-member-counts": "obsahuje {{PLURAL:$1|1 podkategóriu|$1 podkategórie|$1 podkategórií}}, {{PLURAL:$2|1 stránku|$2 stránky|$2 stránok}} a {{PLURAL:$3|1 súbor|$3 súbory|$3 súborov}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "prázdna",
+ "categorytree-load": "načítať",
+ "categorytree-loading": "načítava sa",
+ "categorytree-nothing-found": "nebolo nič nájdené",
+ "categorytree-no-subcategories": "žiadne podkategórie.",
+ "categorytree-no-parent-categories": "nemá nadradené kategórie",
+ "categorytree-no-pages": "žiadne stránky ani podkategórie.",
+ "categorytree-not-found": "Kategória <i>$1</i> nenájdená",
+ "categorytree-error": "Problém pri načítavaní údajov.",
+ "categorytree-retry": "Prosím, chvíľu počkajte a skúste to znova."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/skr-arab.json b/www/wiki/extensions/CategoryTree/i18n/skr-arab.json
new file mode 100644
index 00000000..718da218
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/skr-arab.json
@@ -0,0 +1,31 @@
+{
+ "@metadata": {
+ "authors": [
+ "Saraiki"
+ ]
+ },
+ "categorytree": "قسماں دا شجرہ",
+ "categorytree-portlet": "قسماں، زمرے",
+ "categorytree-legend": "قسماں دا شجرہ ݙکھاؤ",
+ "categorytree-category": "قسم",
+ "categorytree-go": "لین ݙکھاؤ",
+ "categorytree-parents": "والدین",
+ "categorytree-mode-label": "طور:",
+ "categorytree-mode-categories": "صرف زمرہ جات",
+ "categorytree-mode-pages": "فائلاں دے علاوہ ورقے",
+ "categorytree-mode-all": "سارے مقالے",
+ "categorytree-collapse": "لکاؤ",
+ "categorytree-expand": "ودھاؤ",
+ "categorytree-member-counts": "ایندے وچ {{PLURAL:$1|1 ذیلی زمرہ|$1 ذیلی زمرہ جات}}، {{PLURAL:$2|1 ورقہ|$2 ورقے}} تے {{PLURAL:$3|1 فائل|$3 فائلیں}} موجود ہن/ہے۔",
+ "categorytree-num-categories": "$1 ز",
+ "categorytree-num-pages": "$1 پی",
+ "categorytree-num-files": "$1 ایف",
+ "categorytree-num-empty": "خالی",
+ "categorytree-load": "چڑھاؤ",
+ "categorytree-loading": "لوڈ تھیدا پئے",
+ "categorytree-nothing-found": "کجھ نی لبھیا",
+ "categorytree-no-subcategories": "کوئی ذیلی زمرہ کائنی",
+ "categorytree-no-parent-categories": "کوئی پیرنٹ کیٹیگریاں کائنی",
+ "categorytree-no-pages": "کوئی ورقہ یا ذیلی زمرے کائنی",
+ "categorytree-error": "ڈیٹا لوڈ کرݨ وچ رپھڑ۔"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sl.json b/www/wiki/extensions/CategoryTree/i18n/sl.json
new file mode 100644
index 00000000..48d4309b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sl.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dbc334",
+ "Freakolowsky",
+ "editors of sl.wikipedia"
+ ]
+ },
+ "categorytree": "Drevo kategorij",
+ "categorytree-portlet": "Kategorije",
+ "categorytree-legend": "Prikaži drevo kategorij",
+ "categorytree-desc": "Dinamično navigiraj po [[Special:CategoryTree|strukturi kategorij]]",
+ "categorytree-header": "Vnesite ime kategorije, da si ogledate njeno vsebino kot drevesno strukturo. (Zahteva JavaScript.)",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Pokaži drevo",
+ "categorytree-parents": "Starši",
+ "categorytree-mode-label": "Način:",
+ "categorytree-mode-categories": "samo kategorije",
+ "categorytree-mode-pages": "strani z izjemo slik",
+ "categorytree-mode-all": "vse strani",
+ "categorytree-collapse": "skrči",
+ "categorytree-expand": "razširi",
+ "categorytree-member-counts": "vsebuje $1 {{PLURAL:$1|podkategorijo|podkategoriji|podkategorije|podkategorij}}, $2 {{PLURAL:$2|stran|strani|strani}} in $3 {{PLURAL:$3|datoteko|datoteki|datoteke|datotek}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "prazno",
+ "categorytree-load": "naloži",
+ "categorytree-loading": "nalagam",
+ "categorytree-nothing-found": "ni zadetkov",
+ "categorytree-no-subcategories": "ni podkategorij",
+ "categorytree-no-parent-categories": "ni starševskih kategorij",
+ "categorytree-no-pages": "ni strani ali podkategorij",
+ "categorytree-not-found": "Kategorije <i>$1</i> ni moč najti",
+ "categorytree-error": "Težava pri nalaganju podatkov.",
+ "categorytree-retry": "Prosimo, počakajte trenutek in poskusite znova.",
+ "apihelp-categorytree-description": "Notranji modul za razširitev CategoryTree.",
+ "apihelp-categorytree-param-category": "Naslov v imenskem prostoru kategorij; če navedete predpono, jo bomo prezrli.",
+ "apihelp-categorytree-param-options": "Možnosti konstruktorja CategoryTree kot objekt JSON. Možnost <var>depth</var> je privzeto <kbd>1</kbd>."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sm.json b/www/wiki/extensions/CategoryTree/i18n/sm.json
new file mode 100644
index 00000000..a278c4a5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sm.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/so.json b/www/wiki/extensions/CategoryTree/i18n/so.json
new file mode 100644
index 00000000..9ec52554
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/so.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Abshirdheere",
+ "Maax"
+ ]
+ },
+ "categorytree-category": "Qeybta:",
+ "categorytree-no-subcategories": "Ma jiraan wax laamaha qaybaha ah",
+ "categorytree-not-found": "Qeybta <i>$1</i> lama helin"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sq.json b/www/wiki/extensions/CategoryTree/i18n/sq.json
new file mode 100644
index 00000000..02de46ff
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sq.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eagleal",
+ "Olsi",
+ "Arianit"
+ ]
+ },
+ "categorytree": "Pema e kategorive",
+ "categorytree-portlet": "Kategoritë",
+ "categorytree-legend": "Shfaqni pemën e kategorive",
+ "categorytree-desc": "Lundroni shpejt [[Special:CategoryTree|strukturën e kategorisë]]",
+ "categorytree-header": "Fusni emrin e kategorisë për të parë përmbajtjen si pemë kategorish. (Kërkon JavaScript.)",
+ "categorytree-category": "Kategoria:",
+ "categorytree-go": "Plotëso",
+ "categorytree-parents": "Kryekategoritë",
+ "categorytree-mode-categories": "vetëm kategoritë",
+ "categorytree-mode-pages": "faqet pa figurat",
+ "categorytree-mode-all": "të gjitha faqet",
+ "categorytree-collapse": "mbylle",
+ "categorytree-expand": "hape",
+ "categorytree-member-counts": "përmban $1 nënkategori, $2 faqe, dhe {{PLURAL:$3|1 skedë|$3 skeda}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 F",
+ "categorytree-num-files": "$1 S",
+ "categorytree-num-empty": "bosh",
+ "categorytree-load": "hape",
+ "categorytree-loading": "duke plotësuar",
+ "categorytree-nothing-found": "Ju kërkoj ndjesë, nuk u gjet asgjë.",
+ "categorytree-no-subcategories": "Asnjë nënkategori.",
+ "categorytree-no-parent-categories": "nuk ka kategori prindërore",
+ "categorytree-no-pages": "Asnjë artikull ose nënkategori.",
+ "categorytree-not-found": "Kategoria <i>$1</i> nuk u gjet",
+ "categorytree-error": "Problem gjatë ngarkimit të të dhënave.",
+ "categorytree-retry": "Ju lutemi prisni një moment dhe provojeni përsëri."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sr-ec.json b/www/wiki/extensions/CategoryTree/i18n/sr-ec.json
new file mode 100644
index 00000000..43b14796
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sr-ec.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01",
+ "Millosh",
+ "Rancher",
+ "Sasa Stefanovic",
+ "Slaven Kosanovic",
+ "Михајло Анђелковић",
+ "Сербијана",
+ "BadDog"
+ ]
+ },
+ "categorytree": "Стабло категорија",
+ "categorytree-portlet": "Категорије",
+ "categorytree-legend": "Приказ стабла категорија",
+ "categorytree-desc": "Динамичка навигација кроз [[Special:CategoryTree|структуру категорија]]",
+ "categorytree-header": "Унесите назив категорије чији садржај желите да видите у стабластој структури (захтева Јаваскрипту).",
+ "categorytree-category": "Категорија:",
+ "categorytree-go": "Прикажи стабло",
+ "categorytree-parents": "Наткатегорије",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "само категорије",
+ "categorytree-mode-pages": "странице изузевши датотеке",
+ "categorytree-mode-all": "све странице",
+ "categorytree-collapse": "скупи",
+ "categorytree-expand": "прикажи",
+ "categorytree-member-counts": "садржи {{PLURAL:$1|једну поткатегорију|$1 поткатегорије|$1 поткатегорија}}, {{PLURAL:$2|једну страницу|$2 странице|$2 страница}} и {{PLURAL:$3|једну датотеку|$3 датотеке|$3 датотека}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Д",
+ "categorytree-num-empty": "празна",
+ "categorytree-load": "учитај",
+ "categorytree-loading": "учитавам…",
+ "categorytree-nothing-found": "ништа није пронађено",
+ "categorytree-no-subcategories": "нема поткатегорија",
+ "categorytree-no-parent-categories": "нема наткатегорија",
+ "categorytree-no-pages": "нема страница или поткатегорија",
+ "categorytree-not-found": "Категорија <i>$1</i> није пронађена",
+ "categorytree-error": "Проблем при учитавању података.",
+ "categorytree-retry": "Сачекајте неколико тренутака и покушајте поново."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sr-el.json b/www/wiki/extensions/CategoryTree/i18n/sr-el.json
new file mode 100644
index 00000000..a0090cee
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sr-el.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michaello",
+ "Milicevic01",
+ "Rancher"
+ ]
+ },
+ "categorytree": "Stablo kategorija",
+ "categorytree-portlet": "kategorije",
+ "categorytree-legend": "Prikaz stabla kategorija",
+ "categorytree-desc": "Dinamička navigacija kroz [[Special:CategoryTree|strukturu kategorija]]",
+ "categorytree-header": "Unesite naziv kategorije čiji sadržaj želite da vidite u stablastoj strukturi.\nOvo zahteva naprednu funkciju JavaScript-a poznatu kao AJAX.\nAko imate stariji pregledač ili ste onemogućili JavaScript, stablasti prikaz neće raditi.",
+ "categorytree-category": "Kategorija:",
+ "categorytree-go": "Prikaži stablo",
+ "categorytree-parents": "Natkategorije",
+ "categorytree-mode-label": "Režim:",
+ "categorytree-mode-categories": "samo kategorije",
+ "categorytree-mode-pages": "stranice izuzevši datoteke",
+ "categorytree-mode-all": "sve stranice",
+ "categorytree-collapse": "sakrij",
+ "categorytree-expand": "prikaži",
+ "categorytree-member-counts": "sadrži {{PLURAL:$1|jednu potkategoriju|$1 potkategorije|$1 potkategorija}}, {{PLURAL:$2|jednu stranicu|$2 stranice|$2 stranica}} i {{PLURAL:$3|jednu datoteku|$3 datoteke|$3 datoteka}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "prazna",
+ "categorytree-load": "učitaj",
+ "categorytree-loading": "učitavam…",
+ "categorytree-nothing-found": "ništa nije pronađeno",
+ "categorytree-no-subcategories": "nema potkategorija",
+ "categorytree-no-parent-categories": "bez natkategorije",
+ "categorytree-no-pages": "nema stranica ili potkategorija",
+ "categorytree-not-found": "Kategorija <i>$1</i> nije pronađena",
+ "categorytree-error": "Problem pri učitavanju podataka.",
+ "categorytree-retry": "Sačekajte nekoliko trenutaka i pokušajte ponovo."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/st.json b/www/wiki/extensions/CategoryTree/i18n/st.json
new file mode 100644
index 00000000..7365445c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/st.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": [],
+ "categorytree": "Lenane le Mekga",
+ "categorytree-category": "Mokga:",
+ "categorytree-go": "Mpontshe lenane",
+ "categorytree-mode-categories": "mekga feela",
+ "categorytree-mode-pages": "maqephe ntle le ditshwantsho",
+ "categorytree-collapse": "Nyenyefatsa",
+ "categorytree-expand": "Hodisa",
+ "categorytree-load": "jara",
+ "categorytree-loading": "le ntse le jarwa",
+ "categorytree-nothing-found": "Ha ho a fumanwa letho",
+ "categorytree-no-subcategories": "ntle le mekgana",
+ "categorytree-no-pages": "ntle le maqephe le mekgana",
+ "categorytree-not-found": "Mokga wa <i>$1</i> ha o a fumanwa"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/stq.json b/www/wiki/extensions/CategoryTree/i18n/stq.json
new file mode 100644
index 00000000..edf8bbf7
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/stq.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Pyt"
+ ]
+ },
+ "categorytree": "Kategorieboom",
+ "categorytree-portlet": "Kategorien",
+ "categorytree-legend": "Wies Kategorienboom",
+ "categorytree-desc": "AJAX-basierd Gadget uum ju [[Special:CategoryTree|Kategorien-Struktuur]] fon n Wiki antouwiesen",
+ "categorytree-header": "Wiest foar ju anroate Kategorie do Unnerkategorien in n Boomstruktuur.\nDisse Siede bruukt bestimde JavaScript-Funktione (AJAX).\nIn gjucht oolde Browsere, of wan Javascript ouschalted is, funktioniert disse Siede eventuell nit.",
+ "categorytree-category": "Kategorie:",
+ "categorytree-go": "Leede",
+ "categorytree-parents": "Buppekategorien",
+ "categorytree-mode-categories": "bloot Kategorien",
+ "categorytree-mode-pages": "Sieden buute Doatäie",
+ "categorytree-mode-all": "aal Sieden",
+ "categorytree-collapse": "ienklappe",
+ "categorytree-expand": "uutklappe",
+ "categorytree-member-counts": "änthoalt {{PLURAL:$1|1 Unnerkategorie|$1 Unnerkategorien}}, {{PLURAL:$2|1 Siede|$2 Sieden}} un {{PLURAL:$3|1 Doatäi|$3 Doatäie}}",
+ "categorytree-load": "leede",
+ "categorytree-loading": "leede ...",
+ "categorytree-nothing-found": "Niks fuunen",
+ "categorytree-no-subcategories": "Neen Unnerkategorien",
+ "categorytree-no-parent-categories": "Neen Buppekategorien",
+ "categorytree-no-pages": "Neen Sieden of Unnerkategorien",
+ "categorytree-not-found": "Kategorie ''$1'' nit fuunen",
+ "categorytree-error": "Probleme bie dät Leeden fon do Doaten.",
+ "categorytree-retry": "Täif ieuwen un fersäik et dan fon näien."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sty.json b/www/wiki/extensions/CategoryTree/i18n/sty.json
new file mode 100644
index 00000000..1088bf7f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sty.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Khanmarat"
+ ]
+ },
+ "categorytree-expand": "ацҡалы",
+ "categorytree-member-counts": "$1 {{PLURAL:$1|1 төргөннө|$1 төргөннәрне}}, $2 {{PLURAL:$2|1 питне|$2 питләрне}} әм {{PLURAL:$3|1 файл|$3 файлны}}ны үс эценә алаты",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 П",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/su.json b/www/wiki/extensions/CategoryTree/i18n/su.json
new file mode 100644
index 00000000..ec27d2b4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/su.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Irwangatot",
+ "Kandar"
+ ]
+ },
+ "categorytree": "TangkalKategori",
+ "categorytree-portlet": "Kategori",
+ "categorytree-legend": "Témbongkeun tangkal kategori",
+ "categorytree-desc": "Gajet AJAX pikeun némbongkeun [[Special:CategoryTree|wangun kategori]] dina hiji wiki",
+ "categorytree-header": "Asupkeun hiji ngaran kategori pikeun nempo eusina dina wangun tangkal.\nPerhatikeun yén fitur ieu merlukeun pangrojong Javascript tingkat tuluy anu dipikawanoh minangka AJAX.\nLamun Anjeun ngagunakeun panyungsi nu lila, atawa maehan fungsi Javascript Anjeun, fitur ieu henteu bisa dijalankeun.",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Témbongkeun Tangkal",
+ "categorytree-parents": "Luluhur",
+ "categorytree-mode-categories": "kategori wungkul",
+ "categorytree-mode-pages": "kaca iwal berkas",
+ "categorytree-mode-all": "sadaya kaca",
+ "categorytree-collapse": "tilep",
+ "categorytree-expand": "buka",
+ "categorytree-member-counts": "mibanda {{PLURAL:$1|1 subkategori|$1 subkategori}}, {{PLURAL:$2|1 kaca|$2 kaca}}, jeung {{PLURAL:$3|1 berkas|$3 berkas}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-load": "muatkeun",
+ "categorytree-loading": "ngamuat",
+ "categorytree-nothing-found": "teu manggih nanaon",
+ "categorytree-no-subcategories": "euweuh subkategori",
+ "categorytree-no-parent-categories": "taya kategori luhureunana",
+ "categorytree-no-pages": "euweuh kaca atawa subkategori",
+ "categorytree-not-found": "Kategori <i>$1</i> teu kapanggih",
+ "categorytree-error": "Aya masalah dina ngamuat data.",
+ "categorytree-retry": "Dago sakedap, lajeng coba deui."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sv.json b/www/wiki/extensions/CategoryTree/i18n/sv.json
new file mode 100644
index 00000000..6835c14d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sv.json
@@ -0,0 +1,48 @@
+{
+ "@metadata": {
+ "authors": [
+ "Boivie",
+ "Diupwijk",
+ "Jon Harald Søby",
+ "Lejonel",
+ "Lokal Profil",
+ "M.M.S.",
+ "Sannab",
+ "WikiPhoenix",
+ "Jopparn"
+ ]
+ },
+ "categorytree": "Kategoriträd",
+ "categorytree-portlet": "Kategorier",
+ "categorytree-legend": "Visa kategoriträd",
+ "categorytree-desc": "Dynamisk navigation av [[Special:CategoryTree|kategoristrukturen]]",
+ "categorytree-header": "Fyll i ett kategorinamn för att se dess innehåll som en trädstruktur. (Kräver JavaScript.)",
+ "categorytree-category": "Kategori:",
+ "categorytree-go": "Visa träd",
+ "categorytree-parents": "Föräldrakategorier",
+ "categorytree-mode-label": "Läge:",
+ "categorytree-mode-categories": "endast kategorier",
+ "categorytree-mode-pages": "sidor utom filer",
+ "categorytree-mode-all": "alla sidor",
+ "categorytree-collapse": "göm",
+ "categorytree-expand": "expandera",
+ "categorytree-member-counts": "Innehåller {{PLURAL:$1|1 underkategori|$1 underkategorier}}, {{PLURAL:$2|1 sida|$2 sidor}}, och {{PLURAL:$3|1 fil|$3 filer}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 S",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tom",
+ "categorytree-load": "ladda",
+ "categorytree-loading": "laddar",
+ "categorytree-nothing-found": "hittade inget",
+ "categorytree-no-subcategories": "inga underkategorier",
+ "categorytree-no-parent-categories": "inga föräldrakategorier",
+ "categorytree-no-pages": "inga artiklar eller underkategorier",
+ "categorytree-not-found": "Kategori ''$1'' hittades ej",
+ "categorytree-error": "Problem med att ladda data.",
+ "categorytree-retry": "Vänta en stund och försök igen.",
+ "apihelp-categorytree-description": "Intern modul för tillägget CategoryTree.",
+ "apihelp-categorytree-summary": "Intern modul för tillägget CategoryTree.",
+ "apihelp-categorytree-param-category": "Titel i kategorinamnrymden, prefix kommer att ignoreras om de anges.",
+ "apihelp-categorytree-param-options": "Alternativ för CategoryTree-konstruktören som ett JSON-objekt. Den <var>fördjupade</var> alternativa standardvärdet är <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Alternativ måste vara ett giltigt JSON-objekt."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/sw.json b/www/wiki/extensions/CategoryTree/i18n/sw.json
new file mode 100644
index 00000000..76bfc9ca
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/sw.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kwisha",
+ "Lloffiwr",
+ "Muddyb Blast Producer",
+ "Stephenwanjau",
+ "Muddyb"
+ ]
+ },
+ "categorytree": "Mfumo wa jamii",
+ "categorytree-portlet": "Jamii",
+ "categorytree-legend": "Onyesha mfumo wa jamii",
+ "categorytree-desc": "Chungulia kwenye [[Special:CategoryTree|mfumo wa jamii]]",
+ "categorytree-header": "Ingiza jina la jamii ili kuona yaliyomo kwenye mfumo wa jamii. '''Ilani''': hii itahitaji JavaScript ya kisasa ijulilkanayo kwa jina la AJAX. Endapo utakuwa na ya zamani, au JavaScript yako imezimwa, basi hii hatofanya kazi kabisa.",
+ "categorytree-category": "Jamii:",
+ "categorytree-go": "Onyesha mfumo",
+ "categorytree-parents": "Kuu",
+ "categorytree-mode-categories": "jamii tu",
+ "categorytree-mode-pages": "kurasa isipokuwa mafaili",
+ "categorytree-mode-all": "kurasa zote",
+ "categorytree-collapse": "kunja",
+ "categorytree-expand": "kutanua",
+ "categorytree-member-counts": "Imo {{PLURAL:$1|kijamii 1|vijamii $1}}, {{PLURAL:$2|ukurasa 1|kurasa $2}}, na {{PLURAL:$3|faili 1|mafaili $3}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "tupu",
+ "categorytree-load": "kupakia",
+ "categorytree-loading": "inapakizwa...",
+ "categorytree-nothing-found": "hakupatikana kitu",
+ "categorytree-no-subcategories": "jamii ndogo zake hakuna",
+ "categorytree-no-parent-categories": "jamii kuu hakuna",
+ "categorytree-no-pages": "hakuna kurasa wala jamii ndogo zake",
+ "categorytree-not-found": "Jamii inayoitwa $1 haikupatikana",
+ "categorytree-error": "Ilitokea tatizo zilipopakizwa data.",
+ "categorytree-retry": "Subiri kidogo tafadhali, halafu jaribu tena."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/szl.json b/www/wiki/extensions/CategoryTree/i18n/szl.json
new file mode 100644
index 00000000..f5e259fc
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/szl.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Krol111"
+ ]
+ },
+ "categorytree-expand": "rozwjyń",
+ "categorytree-member-counts": "Mo {{PLURAL:$1|1 podkategoryjo|$1 podkategoryje|$1 podkategoryji}}, {{PLURAL:$2|1 zajta|$2 zajty|$2 zajt}} a {{PLURAL:$3|1 plik|$3 pliki|$3 plikůw}}",
+ "categorytree-num-categories": "$1 kat.",
+ "categorytree-num-pages": "$1 zaj.",
+ "categorytree-num-files": "$1 pl."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ta.json b/www/wiki/extensions/CategoryTree/i18n/ta.json
new file mode 100644
index 00000000..73657a88
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ta.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Karthi.dr",
+ "Shanmugamp7",
+ "Surya Prakash.S.A.",
+ "TRYPPN",
+ "Trengarasu",
+ "மதனாஹரன்"
+ ]
+ },
+ "categorytree": "பகுப்பு மரம்",
+ "categorytree-portlet": "பகுப்புகள்",
+ "categorytree-legend": "பகுப்பு மரத்தைக் காட்டு",
+ "categorytree-header": "பகுப்பின் உள்ளடக்கங்களை ஒரு மர வரிப்படமாகப் பார்க்கப் பகுப்பின் பெயரை உள்ளிடவும்.\nஇதற்கு ஏசாக்சு என அறியப்படும் மேம்பட்ட யாவாக்கிறிட்டு வசதி தேவை என்பதை நினைவில் கொள்ளவும்.\nநீங்கள் மிகவும் பழைய மேலோடியொன்றைக் கொண்டிருந்தால் அல்லது யாவாக்கிறிட்டை முடக்கியிருந்தால், இது வேலை செய்யாது.",
+ "categorytree-category": "பகுப்பு:",
+ "categorytree-go": "மரத்தைக் காட்டு",
+ "categorytree-parents": "மூலங்கள்",
+ "categorytree-mode-categories": "பகுப்புகள் மட்டும்",
+ "categorytree-mode-pages": "பக்கங்கள் மட்டும், கோப்புக்கள் தவிர",
+ "categorytree-mode-all": "எல்லா பக்கங்களும்",
+ "categorytree-collapse": "சுருக்கு",
+ "categorytree-expand": "விரிவாக்கு",
+ "categorytree-member-counts": "{{PLURAL:$1|1 உபபகுப்பையும்|$1 உபபகுப்புகளையும்}} {{PLURAL:$2|1 பக்கத்தையும்|$2 பக்கங்களையும்}} {{PLURAL:$3|1 கோப்பையும்|$3 கோப்புகளையும்}} கொண்டுள்ளது",
+ "categorytree-num-categories": "$1 பகு",
+ "categorytree-num-pages": "$1 பக்.",
+ "categorytree-num-files": "$1 கோப்.",
+ "categorytree-num-empty": "காலி",
+ "categorytree-load": "ஏற்று",
+ "categorytree-loading": "ஏற்றப்படுகிறது...",
+ "categorytree-nothing-found": "ஒன்றும் காணப்படவில்லை",
+ "categorytree-no-subcategories": "துணைப்பகுப்புகள் கிடையாது",
+ "categorytree-no-parent-categories": "மூலபகுப்புக்கள் ஏதுமில்லை",
+ "categorytree-no-pages": "பக்கங்களோ அல்லது துணைப்பகுப்புகளோ கிடையாது",
+ "categorytree-not-found": "<i>$1</i> பகுப்பு காணப்படவில்லை",
+ "categorytree-error": "குறிப்புகளை ஏற்றுவதில் சிக்கல்",
+ "categorytree-retry": "கொஞ்ச நேரம் பொறுத்திருந்தபின் மீண்டும் முயற்சி செய்யுங்கள்."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tay.json b/www/wiki/extensions/CategoryTree/i18n/tay.json
new file mode 100644
index 00000000..0a494c33
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tay.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Corainn",
+ "Hitaypayan"
+ ]
+ },
+ "categorytree": "Pintbcyan na mlmlamu’ qhuniq",
+ "categorytree-portlet": "Ptbcyun",
+ "categorytree-legend": "Pkt’aniy quw pintbcyan na mlmlamu’ qhuniq",
+ "categorytree-category": "Ptbcyun:",
+ "categorytree-parents": "Pintbcyan na tay mkraya’",
+ "categorytree-mode-label": "Yaya’ na kkbalay:",
+ "categorytree-mode-categories": "nanak pintbcyan na mlmlamu’ quw spkita’",
+ "categorytree-mode-all": "kwara’ zzngayan",
+ "categorytree-collapse": "qmuzyup",
+ "categorytree-expand": "cankay",
+ "categorytree-member-counts": "Kwara’ kin na{{PLURAL:$1| $1 uzyuk na pintbcyan}}, {{PLURAL:$2|$2 gnyahan lpgan ruw}}, {{PLURAL:$3|$3 biru’ na zayzyuwaw}}",
+ "categorytree-num-categories": "$1 pintbcyan na mlmlamu’",
+ "categorytree-num-pages": "$1 qutux qutux gnyahan",
+ "categorytree-num-files": "$1 biru’ na zayzyuwaw",
+ "categorytree-num-empty": "ungat ana nanu’",
+ "categorytree-load": "lpgun",
+ "categorytree-loading": "nyuw lpgun na’...",
+ "categorytree-nothing-found": "Ktan ga ungat ana nanu’ mlmlamu’ na binkgan",
+ "categorytree-no-subcategories": "ungat quw pintbcyan sinlalu’",
+ "categorytree-no-parent-categories": "ungat pintbcyan tay mkraya’"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tcy.json b/www/wiki/extensions/CategoryTree/i18n/tcy.json
new file mode 100644
index 00000000..81b905bf
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tcy.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "VASANTH S.N.",
+ "Vishwanatha Badikana",
+ "రహ్మానుద్దీన్",
+ "Kiranpoojary"
+ ]
+ },
+ "categorytree-mode-all": "ಮಾತಾ ಪುಟೊಲು",
+ "categorytree-collapse": "ಕುಗ್ಗಿಸಾಲ",
+ "categorytree-expand": "ವಿಸ್ತಾರೊ ಮಲ್ಪುಲೆ",
+ "categorytree-member-counts": "{{PLURAL:$1|1 ಉಪವರ್ಗ|$1 ಉಪವರ್ಗೊಲು}}, {{PLURAL:$2|1 ಪುಟೊ|$2 ಪುಟೊಕುಲು}}, ಬೊಕ್ಕ {{PLURAL:$3|1 ಕಡತ|$3 ಕಡತಲು}} ಉಂಡು",
+ "categorytree-num-categories": "$1 ವ",
+ "categorytree-num-pages": "$1 ಪು",
+ "categorytree-num-files": "$1 ಕ",
+ "categorytree-num-empty": "ಖಾಲಿ",
+ "categorytree-load": "ದಿಂಜಾಲೆ",
+ "categorytree-loading": "ದಿಂಜಾವೊಂದು ಉಂಡು.......",
+ "categorytree-error": "ದತ್ತಾಂಶ ದಿಂಜಾನಗ ದೋಷ",
+ "categorytree-retry": "ದಯದೀದ್ ಒಂತೆ ಕಾತ್‘ದ್ ಪಿರ ಪ್ರಯತ್ನ ಮಲ್ಪುಲೆ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/te.json b/www/wiki/extensions/CategoryTree/i18n/te.json
new file mode 100644
index 00000000..2d9f4540
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/te.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "C.Chandra Kanth Rao",
+ "Kiranmayee",
+ "Mpradeep",
+ "Ravichandra",
+ "Veeven",
+ "వైజాసత్య"
+ ]
+ },
+ "categorytree": "వర్గవృక్షం",
+ "categorytree-portlet": "వర్గాలు",
+ "categorytree-legend": "వర్గ వృక్షాన్ని చూపించు",
+ "categorytree-desc": "వికీ యొక్క [[Special:CategoryTree|వర్గ వృక్షాన్ని]] చూపించడానికి AJAX ఆధారిత పరికరం",
+ "categorytree-header": "ఒక వర్గంలోని అంశాలను వృక్షం లాగా చూసేందుకు ఆ వర్గం పేరును ఇక్కడ ఇవ్వండి. దీనికోసం AJAX అనే ఆధునిక జావాస్క్రిప్టు నైపుణ్యం కావాలి. మీ బ్రౌజరు బాగా పాతదయినా, లేక దానిలో జావాస్క్రిప్టు అశక్తంగా ఉన్నా ఇది పనిచెయ్యదు.",
+ "categorytree-category": "వర్గం:",
+ "categorytree-go": "వృక్షాన్ని చూపించు",
+ "categorytree-parents": "మాతృవర్గాలు",
+ "categorytree-mode-label": "విధం:",
+ "categorytree-mode-categories": "వర్గాలు మాత్రమే",
+ "categorytree-mode-pages": "ఫైళ్ళను మినహాయించి మిగిలిన పేజీలు",
+ "categorytree-mode-all": "అన్ని పేజీలు",
+ "categorytree-collapse": "మూసివేయి",
+ "categorytree-expand": "విస్తరించు",
+ "categorytree-member-counts": "{{PLURAL:$1|1 ఉపవర్గం|$1 ఉపవర్గాలూ}}, {{PLURAL:$2|1 పేజీ|$2 పేజీలూ}}, మరియు {{PLURAL:$3|1 ఫైలూ|$3 ఫైళ్ళూ}} ఉన్నాయి",
+ "categorytree-num-categories": "$1 వ",
+ "categorytree-num-pages": "$1 పే",
+ "categorytree-num-files": "$1 ద",
+ "categorytree-num-empty": "ఖాళీ",
+ "categorytree-load": "లోడు",
+ "categorytree-loading": "లోడవుతోంది...",
+ "categorytree-nothing-found": "ఏమీ లేవు",
+ "categorytree-no-subcategories": "ఉపవర్గాలు లేవు",
+ "categorytree-no-parent-categories": "మాతృవర్గం లేదు",
+ "categorytree-no-pages": "పేజీలు గానీ, ఉపవర్గాలు గానీ లేవు",
+ "categorytree-not-found": "<i>$1</i> అనే వర్గం కనపడలేదు",
+ "categorytree-error": "డేటా లోడు చెయ్యడంలో లోపం దొర్లింది",
+ "categorytree-retry": "కాస్త ఆగి మళ్ళీ ప్రయత్నించండి."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tet.json b/www/wiki/extensions/CategoryTree/i18n/tet.json
new file mode 100644
index 00000000..06e9f74e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tet.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "MF-Warburg"
+ ]
+ },
+ "categorytree": "Ai-hun kategoria",
+ "categorytree-portlet": "Kategoria sira",
+ "categorytree-category": "Kategoria:",
+ "categorytree-go": "Hatudu ai-hun",
+ "categorytree-mode-categories": "hatudu de'it kategoria",
+ "categorytree-mode-all": "pájina hotu",
+ "categorytree-num-categories": "$1 K"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tg-cyrl.json b/www/wiki/extensions/CategoryTree/i18n/tg-cyrl.json
new file mode 100644
index 00000000..c77ae5a1
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tg-cyrl.json
@@ -0,0 +1,32 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ibrahim",
+ "ToJack"
+ ]
+ },
+ "categorytree": "ГурӯҳДарахт",
+ "categorytree-portlet": "Гурӯҳҳо",
+ "categorytree-legend": "Намоиши дарахти гурӯҳ",
+ "categorytree-desc": "Абзоре дар асоси AJAX барои намоиши [[Special:CategoryTree|сохтори гурӯҳи]] вики.",
+ "categorytree-header": "Номи як гурӯҳро ворид кунед, то мӯҳтавиёти он ба сурати дарахт намоиш ёбад.\nТаваҷҷӯҳ кунед, ки ин кор ба қобилиятҳои пешрафтаи ҶаваСкрипт бо номи Аҷакс ниёз дорад.\nАгар аз мурургари хеле кӯҳна истифода мекунед ё ҶаваСкриптро ғайрифаъол кардаед, дар ин ҳол он кор нахоҳад кард.",
+ "categorytree-category": "Гурӯҳ:",
+ "categorytree-go": "Намоиши дарахт",
+ "categorytree-parents": "Волидайн",
+ "categorytree-mode-categories": "Фақат гурӯҳҳо",
+ "categorytree-mode-pages": "саҳифаҳо ғайр аз аксҳо",
+ "categorytree-mode-all": "ҳамаи саҳифаҳо",
+ "categorytree-collapse": "фурукаш",
+ "categorytree-expand": "густариш",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-empty": "холӣ",
+ "categorytree-load": "бор кардан",
+ "categorytree-loading": "дар ҳоли бор шудан…",
+ "categorytree-nothing-found": "ҳеҷчиз ёфт нашуд",
+ "categorytree-no-subcategories": "ҳеҷ зергурӯҳе надорад",
+ "categorytree-no-parent-categories": "гурӯҳи болотаре нест",
+ "categorytree-no-pages": "ҳеҷ саҳифае ё зергурӯҳе",
+ "categorytree-not-found": "Гурӯҳи <i>$1</i> ёфт нашуд",
+ "categorytree-error": "Ишкол дар дарёфти иттилоот",
+ "categorytree-retry": "Лутфан чанд лаҳза сабр кунед ва дубора имтиҳон кунед."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tg-latn.json b/www/wiki/extensions/CategoryTree/i18n/tg-latn.json
new file mode 100644
index 00000000..486d1acd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tg-latn.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liangent"
+ ]
+ },
+ "categorytree": "GurūhDaraxt",
+ "categorytree-portlet": "Gurūhho",
+ "categorytree-legend": "Namoişi daraxti gurūh",
+ "categorytree-desc": "Abzore dar asosi AJAX baroi namoişi [[Special:CategoryTree|soxtori gurūhi]] viki.",
+ "categorytree-header": "Nomi jak gurūhro vorid kuned, to mūhtavijoti on ba surati daraxt namoiş jobad.\nTavaççūh kuned, ki in kor ba qobilijathoi peşraftai ÇavaSkript bo nomi Açaks nijoz dorad.\nAgar az mururgari xele kūhna istifoda mekuned jo ÇavaSkriptro ƣajrifa'ol kardaed, dar in hol on kor naxohad kard.",
+ "categorytree-category": "Gurūh:",
+ "categorytree-go": "Namoişi daraxt",
+ "categorytree-parents": "Volidajn",
+ "categorytree-mode-categories": "Faqat gurūhho",
+ "categorytree-mode-pages": "sahifaho ƣajr az aksho",
+ "categorytree-mode-all": "hamai sahifaho",
+ "categorytree-collapse": "furukaş",
+ "categorytree-expand": "gustariş",
+ "categorytree-load": "bor kardan",
+ "categorytree-loading": "dar holi bor şudan…",
+ "categorytree-nothing-found": "heçciz joft naşud",
+ "categorytree-no-subcategories": "heç zergurūhe nadorad",
+ "categorytree-no-parent-categories": "gurūhi bolotare nest",
+ "categorytree-no-pages": "heç sahifae jo zergurūhe",
+ "categorytree-not-found": "Gurūhi <i>$1</i> joft naşud",
+ "categorytree-error": "Işkol dar darjofti ittiloot",
+ "categorytree-retry": "Lutfan cand lahza sabr kuned va dubora imtihon kuned."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/th.json b/www/wiki/extensions/CategoryTree/i18n/th.json
new file mode 100644
index 00000000..a04449f9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/th.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Horus",
+ "Manop",
+ "Octahedron80",
+ "Passawuth"
+ ]
+ },
+ "categorytree": "หมวดหมู่แบบผังต้นไม้",
+ "categorytree-portlet": "หมวดหมู่",
+ "categorytree-legend": "แสดงผังหมวดหมู่",
+ "categorytree-desc": "สำรวจ[[Special:CategoryTree|โครงสร้างหมวดหมู่]]แบบผังต้นไม้",
+ "categorytree-header": "ป้อนชื่อหมวดหมู่เพื่อดูเนื้อหาเป็นโครงสร้างผังต้นไม้\nการทำงานนี้จำเป็นต้องใช้ความสามารถขั้นสูงของจาวาสคริปต์ที่เรียกว่า เอแจ็กซ์\nหากคุณใช้เบราว์เซอร์รุ่นเก่า หรือปิดการใช้งานจาวาสคริปต์ ความสามารถนี้จะไม่ทำงาน",
+ "categorytree-category": "หมวดหมู่",
+ "categorytree-go": "โหลด",
+ "categorytree-parents": "หมวดหมู่ใหญ่",
+ "categorytree-mode-categories": "แสดงเฉพาะหมวดหมู่",
+ "categorytree-mode-pages": "หน้าต่างๆ ยกเว้นไฟล์",
+ "categorytree-mode-all": "หน้าทุกหน้า",
+ "categorytree-collapse": "ย่อ",
+ "categorytree-expand": "ขยาย",
+ "categorytree-member-counts": "มี {{PLURAL:$1|1 หมวดหมู่ย่อย|$1 หมวดหมู่ย่อย}}, {{PLURAL:$2|1 หน้า|$2 หน้า}}, และ {{PLURAL:$3|1 ไฟล์|$3 ไฟล์}}",
+ "categorytree-num-categories": "$1 ม",
+ "categorytree-num-pages": "$1 น",
+ "categorytree-num-files": "$1 ฟ",
+ "categorytree-num-empty": "ว่าง",
+ "categorytree-load": "โหลด",
+ "categorytree-loading": "กำลังโหลด...",
+ "categorytree-nothing-found": "ไม่พบที่ต้องการ",
+ "categorytree-no-subcategories": "ไม่มีหมวดหมู่ย่อย",
+ "categorytree-no-parent-categories": "ไม่มีหมวดหมู่ระดับบน",
+ "categorytree-no-pages": "ไม่มีหน้าหรือหมวดหมู่ย่อย",
+ "categorytree-not-found": "ไม่พบหมวดหมู่ <i>$1</i>",
+ "categorytree-error": "การโหลดข้อมูลมีปัญหา",
+ "categorytree-retry": "กรุณารอสักครู่ แล้วลองโหลดใหม่อีกครั้ง"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tk.json b/www/wiki/extensions/CategoryTree/i18n/tk.json
new file mode 100644
index 00000000..c1dd4d64
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tk.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hanberke"
+ ]
+ },
+ "categorytree": "Kategoriýa agajy",
+ "categorytree-portlet": "Kategoriýalar",
+ "categorytree-legend": "Kategoriýa agajyny görkez",
+ "categorytree-desc": "[[Special:CategoryTree|Kategoriýa gurluşyny]] dinamik ýagdaýda dolandyr",
+ "categorytree-header": "Kategoriýanyň adyny ýazyp, onuň mazmunyny agaç gurluşy hökmünde görüp bilersiňiz.\nBu aýratynlyk AJAX ady bilen tanalýan ösen JavaScript bilen işleýändir.\nEger brauzeriňiz köne bolsa ýa-da JavaScript ýapyk bolsa, onda ol işlemez.",
+ "categorytree-category": "Kategoriýa:",
+ "categorytree-go": "Agajy görkez",
+ "categorytree-parents": "Ene kategoriýalar",
+ "categorytree-mode-categories": "diňe kategoriýalar",
+ "categorytree-mode-pages": "faýldan başga sahypalar",
+ "categorytree-mode-all": "ähli sahypalar",
+ "categorytree-collapse": "ýygna",
+ "categorytree-expand": "giňelt",
+ "categorytree-member-counts": "{{PLURAL:$1|1 kiçi kategoriýany|$1 kiçi kategoriýany}}, {{PLURAL:$2|1 sahypany|$2 sahypany}} we {{PLURAL:$3|1 faýly|$3 faýly}} öz içine alýar",
+ "categorytree-load": "ýükle",
+ "categorytree-loading": "ýüklenýär...",
+ "categorytree-nothing-found": "hiç zat tapylmady",
+ "categorytree-no-subcategories": "kiçi kategoriýa ýok",
+ "categorytree-no-parent-categories": "ene kategoriýa ýok",
+ "categorytree-no-pages": "sahypa ýa-da kiçi kategoriýa ýok",
+ "categorytree-not-found": "<i>\"$1\"</i> kategoriýasy tapylmady",
+ "categorytree-error": "Maglumat ýükleme problemsy.",
+ "categorytree-retry": "Bir sellem garaşyň we gaýtadan synaň."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tl.json b/www/wiki/extensions/CategoryTree/i18n/tl.json
new file mode 100644
index 00000000..c926f5b7
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tl.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "AnakngAraw",
+ "Lam-ang",
+ "Stranger195"
+ ]
+ },
+ "categorytree": "Puno ng kaurian",
+ "categorytree-portlet": "Mga kaurian",
+ "categorytree-legend": "Ipakita ang puno ng kaurian",
+ "categorytree-desc": "Masiglang libutin ang [[Special:CategoryTree|kayarian ng kaurian]]",
+ "categorytree-header": "Maglagay (magpasok) ng isang pangalan ng kaurian upang makita ang nilalaman nito bilang isang kayarian ng isang puno.\nTandaan na nangangailangan ito ng mas masulong na tungkuling pang-JavaScript na kilala bilang AJAX.\nKapag mayroon kang isang napakatandang/napakalumang pantingin-tingin (''browser''), o hindi pinapagana ang JavaScript, hindi ito magagawa/walang mangyayari.",
+ "categorytree-category": "Kaurian:",
+ "categorytree-go": "Ipakita ang puno",
+ "categorytree-parents": "Mga magulang",
+ "categorytree-mode-categories": "mga kaurian lamang",
+ "categorytree-mode-pages": "mga pahina maliban sa mga talaksan",
+ "categorytree-mode-all": "lahat ng mga pahina",
+ "categorytree-collapse": "tiklupin",
+ "categorytree-expand": "palaparin",
+ "categorytree-expand-bullet": "►",
+ "categorytree-empty-bullet": "►",
+ "categorytree-member-counts": "Naglalaman ng {{PLURAL:$1|1 subkategorya|$1 subkategorya}}, {{PLURAL:$2|1 pahina|$2 mga pahina}}, at {{PLURAL:$3|1 talaksan|$3 mga talaksan}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "walang laman",
+ "categorytree-load": "ikarga",
+ "categorytree-loading": "ikinakarga…",
+ "categorytree-nothing-found": "walang natagpuan",
+ "categorytree-no-subcategories": "walang kabahaging mga kaurian",
+ "categorytree-no-parent-categories": "walang magulang (pinagmulan) na mga kaurian",
+ "categorytree-no-pages": "walang mga pahina o kabahaging mga kaurian/subkaurian (subkategorya)",
+ "categorytree-not-found": "Hindi natagpuan ang kauriang <i>$1</i>",
+ "categorytree-error": "May suliranin sa pagkakarga ng dato.",
+ "categorytree-retry": "Maghintay lamang ng isang sandali at subuking muli."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tly.json b/www/wiki/extensions/CategoryTree/i18n/tly.json
new file mode 100644
index 00000000..3363aa1e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tly.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Гусейн"
+ ]
+ },
+ "categorytree": "Категоријон до",
+ "categorytree-portlet": "Категоријон",
+ "categorytree-legend": "Категоријон до нишо дој",
+ "categorytree-header": "Категоријә номи бынывыштән, ијән ав нишо бәбе бәнә до.\nЫм мымкуне, гирәм шымә браузерәдә AJAX һесте.\nГирәм шымәку браузери канә рәвојәте ја JavaScript быријә быә, жинә категоријон нишо дој бәнә до әбыни.",
+ "categorytree-category": "Тиспир:",
+ "categorytree-go": "Бо жәј",
+ "categorytree-parents": "Пыә-моә категоријон",
+ "categorytree-mode-categories": "әнҹәх категоријон",
+ "categorytree-mode-pages": "сывој фајлон",
+ "categorytree-mode-all": "Һәммәј сәһифон",
+ "categorytree-collapse": "бурмә кардеј",
+ "categorytree-expand": "һовуж кардеј",
+ "categorytree-member-counts": "Дыләдә һестыше {{PLURAL:$1|1 жинә категоријә|$1 жинә категоријә}}, {{PLURAL:$2|1 сәһифә|$2 сәһифә}}, ијән {{PLURAL:$3|1 фајл|$3 фајл}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "тәј",
+ "categorytree-load": "бо жәј",
+ "categorytree-loading": "бо карде...",
+ "categorytree-nothing-found": "Ым категоријәдә жинә категоријә ни.",
+ "categorytree-no-subcategories": "категоријон жинтон ни",
+ "categorytree-no-parent-categories": "пыә-моә категоријә ни",
+ "categorytree-no-pages": "нә мәғолә һесте, нә жинә категоријон",
+ "categorytree-not-found": "Категоријә «$1» пәјдо быәни.",
+ "categorytree-error": "Мәлумоти бо карде сәһве.",
+ "categorytree-retry": "Быһамијән, и тикә чәш быкан ијән икәрән осә быкан."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/to.json b/www/wiki/extensions/CategoryTree/i18n/to.json
new file mode 100644
index 00000000..a3a0a723
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/to.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "categorytree": "Fuʻuʻakau faʻahinga",
+ "categorytree-category": "Faʻahinga:",
+ "categorytree-go": "ʻAsi mai",
+ "categorytree-collapse": "holo",
+ "categorytree-expand": "fano",
+ "categorytree-num-pages": "$1 P"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tpi.json b/www/wiki/extensions/CategoryTree/i18n/tpi.json
new file mode 100644
index 00000000..b8d8a638
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tpi.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Iketsi",
+ "Wantok"
+ ]
+ },
+ "categorytree-portlet": "Ol grup",
+ "categorytree-category": "Grup:",
+ "categorytree-mode-all": "Olgeta pes"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tr.json b/www/wiki/extensions/CategoryTree/i18n/tr.json
new file mode 100644
index 00000000..2a7bfca8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tr.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joseph",
+ "Karduelis",
+ "Khutuck",
+ "Mach",
+ "Runningfridgesrule",
+ "Stultiwikia",
+ "Vito Genovese",
+ "Superyetkin"
+ ]
+ },
+ "categorytree": "Kategori hiyerarşisi",
+ "categorytree-portlet": "Kategoriler",
+ "categorytree-legend": "Kategori ağacını göster",
+ "categorytree-desc": "[[Special:CategoryTree|Kategori yapısını]] dinamik olarak idare et",
+ "categorytree-header": "Kategori ismini girip, içeriğini hiyerarşik şekilde görebilirsiniz. Bu özellik AJAX adıyla bilinen gelişmiş JavaScript ile çalışabilir. Eğer tarayıcınız eski ise ya da JavaScript kullanımı kapalı ise, çalışmaz.",
+ "categorytree-category": "Kategori",
+ "categorytree-go": "Ağacı göster",
+ "categorytree-parents": "Üst kategoriler",
+ "categorytree-mode-label": "Mod:",
+ "categorytree-mode-categories": "sadece kategorileri göster",
+ "categorytree-mode-pages": "dosyalar dışındaki sayfalar",
+ "categorytree-mode-all": "tüm sayfalar",
+ "categorytree-collapse": "aç/kapat",
+ "categorytree-expand": "genişlet",
+ "categorytree-member-counts": "{{PLURAL:$1|1 alt kategori|$1 alt kategori}}, {{PLURAL:$2|1 sayfa|$2 sayfa}} ve {{PLURAL:$3|1 dosya|$3 dosya}} içeriyor",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 M",
+ "categorytree-num-files": "$1 D",
+ "categorytree-num-empty": "boş",
+ "categorytree-load": "yükle",
+ "categorytree-loading": "yükleniyor",
+ "categorytree-nothing-found": "hiçbir şey bulunamadı",
+ "categorytree-no-subcategories": "alt kategori yok.",
+ "categorytree-no-parent-categories": "üst kategori yok",
+ "categorytree-no-pages": "alt kategori veya madde yok.",
+ "categorytree-not-found": "<i>\"$1\"</i> isimli kategori bulunamadı",
+ "categorytree-error": "Bilgi yüklenmesi ile bir problem var.",
+ "categorytree-retry": "Lütfen kısa süre için bekleyin, sonra bir kere daha deneyin."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tru.json b/www/wiki/extensions/CategoryTree/i18n/tru.json
new file mode 100644
index 00000000..085aa9c9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tru.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ariyo"
+ ]
+ },
+ "categorytree": "Dawmo daSedre",
+ "categorytree-portlet": "Sedre",
+ "categorytree-legend": "Maḥway li i Dawmo daSedre",
+ "categorytree-category": "Sedro:",
+ "categorytree-go": "Maḥway li iDawmo",
+ "categorytree-mode-categories": "bes aSedre",
+ "categorytree-num-categories": "$1 S",
+ "categorytree-num-pages": "$1 F",
+ "categorytree-num-files": "$1 M",
+ "categorytree-num-empty": "xalyo",
+ "categorytree-not-found": "uSedro \"$1\" lo komaḥwe."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ts.json b/www/wiki/extensions/CategoryTree/i18n/ts.json
new file mode 100644
index 00000000..17ba181d
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ts.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Thuvack"
+ ]
+ },
+ "categorytree-portlet": "Swiyenge",
+ "categorytree-legend": "Kombisa swi yenge",
+ "categorytree-category": "Xiyenge:"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tt-cyrl.json b/www/wiki/extensions/CategoryTree/i18n/tt-cyrl.json
new file mode 100644
index 00000000..6a06839e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tt-cyrl.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ajdar",
+ "Ilnur efende",
+ "Ильнар",
+ "Derslek",
+ "Don Alessandro"
+ ]
+ },
+ "categorytree": "Төркемнәр \"агачы\".",
+ "categorytree-portlet": "Төркемнәр",
+ "categorytree-legend": "Төркемнәрнең шәҗәрәсен ачарга",
+ "categorytree-desc": "[[Special:CategoryTree|Төркемнәрнең асылы]]н аңлату өчен төзелгән AJAX-бит",
+ "categorytree-header": "Төркемнең исемен кертегез һәм ул шәҗәрә рәвешендә күрсәтеләчәк (JavaScript кирәк булачак).",
+ "categorytree-category": "Төркем:",
+ "categorytree-go": "Йөкләү",
+ "categorytree-parents": "Төп төркемнәр",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "бары тик төркемнәр генә урнаштырылган",
+ "categorytree-mode-pages": "файллардан башка",
+ "categorytree-mode-all": "барлык битләр",
+ "categorytree-collapse": "яшерү",
+ "categorytree-expand": "ачу",
+ "categorytree-member-counts": "$1 {{PLURAL:$1|1 тәркемчәне|$1 тәркемчәләрне|$1 тәркемчәләрдән}}, $2 {{PLURAL:$2|1 битне|$2 битләрне|$2 битләрдән}} һәм {{PLURAL:$3|1 файл|$3 файлны}}ны үз эченә ала",
+ "categorytree-num-categories": "$1 Т",
+ "categorytree-num-pages": "$1 Б",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "буш",
+ "categorytree-load": "йөкләү",
+ "categorytree-loading": "йөкләү бара…",
+ "categorytree-nothing-found": "бернидә табылмады",
+ "categorytree-no-subcategories": "мондый төркемчәләр юк",
+ "categorytree-no-parent-categories": "төп бүлекләр юк",
+ "categorytree-no-pages": "мондый бит яки төркемчә юк",
+ "categorytree-not-found": "<i>$1</i> бүлеге табылмады",
+ "categorytree-error": "Хата",
+ "categorytree-retry": "Зинһар бераз көтеп торыгыз һәм тагын бер кат йөкләүне башкарып карагыз.",
+ "apihelp-categorytree-description": "CategoryTree кушымтасы өчен эчке модуль.",
+ "apihelp-categorytree-param-category": "Төркемнәр мәйданы исемлеге, куелган очракта префикс кулланылмый.",
+ "apihelp-categorytree-param-options": "JSON-җисемнәр сыман CategoryTree төзүчесе төрләре. <var>depth</var> (тирәнлек) параметры <kbd>1</kbd> итеп куелган.",
+ "apierror-categorytree-invalidjson": "Юрамалар JSON-җисемнәре белән валид булырга тиеш."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tt-latn.json b/www/wiki/extensions/CategoryTree/i18n/tt-latn.json
new file mode 100644
index 00000000..e0686e6f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tt-latn.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Frhdkazan"
+ ]
+ },
+ "categorytree-expand": "açırğa",
+ "categorytree-member-counts": "Eçendä {{PLURAL:$1|1 astörkem|$1 astörkem}}, {{PLURAL:$2|1 bit|$2 bit}}, häm {{PLURAL:$3|1 fayl|$3 fayl}} bar",
+ "categorytree-num-categories": "$1 törkem",
+ "categorytree-num-pages": "$1 bit",
+ "categorytree-num-files": "$1 Fayl"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tyv.json b/www/wiki/extensions/CategoryTree/i18n/tyv.json
new file mode 100644
index 00000000..c1a697c5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tyv.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sborsody",
+ "Монгуш Салим"
+ ]
+ },
+ "categorytree-portlet": "Чергелер",
+ "categorytree-category": "Черге:",
+ "categorytree-mode-all": "шупту арыннар",
+ "categorytree-collapse": "кызырары",
+ "categorytree-expand": "херер"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/tzm.json b/www/wiki/extensions/CategoryTree/i18n/tzm.json
new file mode 100644
index 00000000..1f2c0cb9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/tzm.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tifinaghes"
+ ]
+ },
+ "categorytree": "ⵜⴰⴷⴷⴰⴳⵜ ⵏ ⵜⴰⴳⴳⴰⵢⵜ",
+ "categorytree-portlet": "ⵜⴰⴳⴳⴰⵢⵉⵏ",
+ "categorytree-category": "ⵜⴰⴳⴳⴰⵢⵜ",
+ "categorytree-go": "ⵥⵕ ⵜⴰⴷⴷⴰⴳⵜ",
+ "categorytree-mode-categories": "ⵜⴰⴳⴳⴰⵢⵉⵏ ⵚⴰⴼⵉ",
+ "categorytree-mode-all": "ⵎⴰⵕⵕⴰ ⵜⵉⵙⵏⴰⵡⵉⵏ",
+ "categorytree-expand": "ⴰⴼⵔⴷⵉⵙ",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 ⵜ",
+ "categorytree-num-files": "$1 ⴼ",
+ "categorytree-num-empty": "ⵓⵔ ⴷⵉⵙ ⴰⵎⵢⴰ",
+ "categorytree-nothing-found": "ⵓⵔ ⵉⵍⵍⴰ ⵓⵎⵢⴰ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/udm.json b/www/wiki/extensions/CategoryTree/i18n/udm.json
new file mode 100644
index 00000000..f9c20029
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/udm.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kaganer",
+ "AlnashPiyash2",
+ "Wadorgurt"
+ ]
+ },
+ "categorytree-collapse": "ватоно",
+ "categorytree-expand": "возьматоно",
+ "categorytree-member-counts": "Возе {{PLURAL:$1|$1 подкатегория}}, {{PLURAL:$2|$2 бам}} но {{PLURAL:$3|$3 файл}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 Б",
+ "categorytree-num-files": "$1 Ф"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ug-arab.json b/www/wiki/extensions/CategoryTree/i18n/ug-arab.json
new file mode 100644
index 00000000..81b88423
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ug-arab.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sahran",
+ "Uzdil"
+ ]
+ },
+ "categorytree": "تۈرلەر شېخى",
+ "categorytree-portlet": "تۈرلەر",
+ "categorytree-legend": "تۈرلەر شېخىنى كۆرسەت",
+ "categorytree-desc": "[[Special:CategoryTree|تۈرلەر قۇرۇلمىسى]] ھەرىكەتچان يولباشچى",
+ "categorytree-category": "تۈرى:",
+ "categorytree-go": "شاخنى كۆرسەت",
+ "categorytree-parents": "ئاتا تۈرلەر",
+ "categorytree-mode-label": "ئۇسۇلى:",
+ "categorytree-mode-categories": "تۈرلەرلا",
+ "categorytree-mode-pages": "بەتلەردىن باشقا ھۆججەتلەر",
+ "categorytree-mode-all": "ھەممە بەتلەر",
+ "categorytree-collapse": "قاتلا",
+ "categorytree-expand": "ياي",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "{PLURAL:$1|1 تارماق تۈر|$1 تارماق تۈر}}، {{PLURAL:$2|1 بەت|$2 بەت}} ۋە {{PLURAL:$3|1 ھۆججەت|$3 ھۆججەت}}نى ئۆز ئىچىگە ئالىدۇ",
+ "categorytree-num-categories": "$1 تۈر",
+ "categorytree-num-pages": "$1 بەت",
+ "categorytree-num-files": "$1 ھۆججەت",
+ "categorytree-num-empty": "بوش",
+ "categorytree-load": "يۈكلە",
+ "categorytree-loading": "يۈكلەۋاتىدۇ…",
+ "categorytree-nothing-found": "ھېچنېمە تېپىلمىدى",
+ "categorytree-no-subcategories": "تارماق تۈر يوق",
+ "categorytree-no-parent-categories": "ئاتا تۈر يوق",
+ "categorytree-no-pages": "بەت ياكى تارماق تۈر يوق",
+ "categorytree-not-found": "<i>$1</i> تۈر تېپىلمىدى",
+ "categorytree-error": "سانلىق مەلۇمات يۈكلەش مەسىلىسى.",
+ "categorytree-retry": "سەل كۈتۈپ ئاندىن قايتا سىناڭ."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/uk.json b/www/wiki/extensions/CategoryTree/i18n/uk.json
new file mode 100644
index 00000000..591df2b2
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/uk.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "AS",
+ "Ahonc",
+ "Base",
+ "Sodmy",
+ "Piramidion",
+ "Ата"
+ ]
+ },
+ "categorytree": "Дерево категорій",
+ "categorytree-portlet": "Категорії",
+ "categorytree-legend": "Показати дерево категорій",
+ "categorytree-desc": "AJAX-компонент для відображення [[Special:CategoryTree|структури категорій]] вікі",
+ "categorytree-header": "Уведіть назву категорії, і вона буде показана у вигляді дерева. (Вимагає JavaScript).",
+ "categorytree-category": "Категорія:",
+ "categorytree-go": "Показати дерево",
+ "categorytree-parents": "Батьківські категорії",
+ "categorytree-mode-label": "Режим:",
+ "categorytree-mode-categories": "тільки категорії",
+ "categorytree-mode-pages": "окрім зображень",
+ "categorytree-mode-all": "усі сторінки",
+ "categorytree-collapse": "згорнути",
+ "categorytree-expand": "розгорнути",
+ "categorytree-member-counts": "містить $1 {{PLURAL:$1|підкатегорію|підкатегорії|підкатегорій}}, $2 {{PLURAL:$2|сторінку|сторінки|сторінок}} та $3 {{PLURAL:$3|файл|файли|файлів}}",
+ "categorytree-num-categories": "$1 К",
+ "categorytree-num-pages": "$1 С",
+ "categorytree-num-files": "$1 Ф",
+ "categorytree-num-empty": "порожня",
+ "categorytree-load": "завантажити",
+ "categorytree-loading": "завантаження…",
+ "categorytree-nothing-found": "нема підкатегорій",
+ "categorytree-no-subcategories": "нема підкатегорій",
+ "categorytree-no-parent-categories": "нема батьківських категорій",
+ "categorytree-no-pages": "нема статей і підкатегорій",
+ "categorytree-not-found": "Категорія «$1» не знайдена.",
+ "categorytree-error": "Помилка завантаження даних.",
+ "categorytree-retry": "Будь ласка, зачекайте і спробуйте ще раз.",
+ "apihelp-categorytree-description": "Внутрішній модуль для розширення CategoryTree.",
+ "apihelp-categorytree-summary": "Внутрішній модуль для розширення CategoryTree.",
+ "apihelp-categorytree-param-category": "Назва в просторі назв категорій. Якщо буде вказаний префікс, він буде проігнорований.",
+ "apihelp-categorytree-param-options": "Опції для конструктора CategoryTree як об'єкта JSON. Параметр глибини (<var>depth</var>) за замовчуванням встановлений як <kbd>1</kbd>.",
+ "apierror-categorytree-invalidjson": "Опції мають бути коректним JSON-об'єктом."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/ur.json b/www/wiki/extensions/CategoryTree/i18n/ur.json
new file mode 100644
index 00000000..21ee0550
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/ur.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Istabani",
+ "පසිඳු කාවින්ද",
+ "Obaid Raza",
+ "Muhammad Shuaib",
+ "BukhariSaeed"
+ ]
+ },
+ "categorytree": "شجرہ زمرہ جات",
+ "categorytree-portlet": "زمرہ",
+ "categorytree-legend": "مختلف اقسام دکھائیں",
+ "categorytree-desc": "[[Special:CategoryTree|زمرہ جات کی متحرک ساخت]]",
+ "categorytree-header": "ایک زمرہ کا نام لکھ کے اس کا مکمل ساخت کو [[شجرہ نسب|شجرہ]] کی صورت میں دیکھیے۔ (جاوا اسکرپٹ کی ضرورت ہے)",
+ "categorytree-category": "زمرہ",
+ "categorytree-go": "بہ ترتیب شجر",
+ "categorytree-parents": "والدین",
+ "categorytree-mode-label": "طور:",
+ "categorytree-mode-categories": "صرف زمرہ جات",
+ "categorytree-mode-pages": "فائلوں کے علاوہ صفحات",
+ "categorytree-mode-all": "تمام صفحات",
+ "categorytree-collapse": "چھپائیں",
+ "categorytree-expand": "وسیع کریں",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "اس میں {{PLURAL:$1|1 ذیلی زمرہ|$1 ذیلی زمرہ جات}}، {{PLURAL:$2|1 صفحہ|$2 صفحات}} اور {{PLURAL:$3|1 فائل|$3 فائلیں}} موجود ہیں/ہے۔",
+ "categorytree-num-categories": "$1 ز",
+ "categorytree-num-pages": "$1 ص",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "خالی",
+ "categorytree-load": "اثقال",
+ "categorytree-loading": "دوران اثقال",
+ "categorytree-nothing-found": "کچھ دستیاب نہیں",
+ "categorytree-no-subcategories": "کوئی ذیلی زمرہ نہیں",
+ "categorytree-no-parent-categories": "کوئی والدین کے زمرہ جات",
+ "categorytree-no-pages": "کوئی صفحہ یا ذیلی زمرہ موجود نہیں",
+ "categorytree-not-found": "زمرہ <i>$1</i> نہیں ملا",
+ "categorytree-error": "مسئلہ ڈیٹا لوڈ ہو رہا ہے.",
+ "categorytree-retry": "براہ مہربانی ایک لمحے کا انتظار کریں اور دوبارہ کوشش کریں."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/uz.json b/www/wiki/extensions/CategoryTree/i18n/uz.json
new file mode 100644
index 00000000..9249ad34
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/uz.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Abdulla",
+ "Sociologist"
+ ]
+ },
+ "categorytree-category": "Turkum:",
+ "categorytree-mode-all": "barcha sahifalar",
+ "categorytree-expand": "yoyish"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/vec.json b/www/wiki/extensions/CategoryTree/i18n/vec.json
new file mode 100644
index 00000000..507de049
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/vec.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Candalua",
+ "GatoSelvadego"
+ ]
+ },
+ "categorytree": "Strutura ad àlbaro de le categorie",
+ "categorytree-portlet": "Categorie",
+ "categorytree-legend": "Mostra l'àlbaro de le categorie",
+ "categorytree-desc": "Acessorio AJAX par visualizar la [[Special:CategoryTree|strutura de le categorie]] del sito",
+ "categorytree-header": "Inserissi el nome de la categoria de cui te vol védar el contenuto soto forma de strutura ad àlbaro. Nota che la pagina la richiede le funzionalità avanzade de JavaScript ciamà AJAX; se te stè doparando un browser vecio assè o le funzion JavaScript le xe disabilità, sta pagina no la funzionarà mìa.",
+ "categorytree-category": "Categoria",
+ "categorytree-go": "Mostra l'àlbaro",
+ "categorytree-parents": "Categorie superiori",
+ "categorytree-mode-label": "Modałità:",
+ "categorytree-mode-categories": "mostra solo le categorie",
+ "categorytree-mode-pages": "tute le pagine, via de i file",
+ "categorytree-mode-all": "tute le pagine",
+ "categorytree-collapse": "conprimi",
+ "categorytree-expand": "espandi",
+ "categorytree-member-counts": "la contien {{PLURAL:$1|1 sotocategoria|$1 sotocategorie}}, {{PLURAL:$2|1 pagina|$2 pagine}} e {{PLURAL:$3|1 file|$3 file}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "voda",
+ "categorytree-load": "carga",
+ "categorytree-loading": "so' drio cargar…",
+ "categorytree-nothing-found": "nissun risultato",
+ "categorytree-no-subcategories": "nissuna sotocategoria",
+ "categorytree-no-parent-categories": "nissuna categoria superior",
+ "categorytree-no-pages": "nissuna voçe né sotocategoria",
+ "categorytree-not-found": "Categoria <i>$1</i> mìa catà",
+ "categorytree-error": "Ghe xe un problema nel caricamento dei dati.",
+ "categorytree-retry": "Speta n'atimo e dopo próa de novo."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/vep.json b/www/wiki/extensions/CategoryTree/i18n/vep.json
new file mode 100644
index 00000000..8165ee3f
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/vep.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Игорь Бродский"
+ ]
+ },
+ "categorytree": "Kategorijoiden pu",
+ "categorytree-portlet": "Kategorijad",
+ "categorytree-legend": "Ozutada kategorijoiden pu",
+ "categorytree-category": "Kategorii:",
+ "categorytree-go": "Ozutada pu",
+ "categorytree-parents": "Ülembaižed kategorijad",
+ "categorytree-mode-categories": "vaiše kategorijad",
+ "categorytree-mode-pages": "lehtpoled failoita",
+ "categorytree-mode-all": "kaik lehtpoled",
+ "categorytree-collapse": "peitta",
+ "categorytree-expand": "ozutada",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "pall'az",
+ "categorytree-load": "jügutoitta",
+ "categorytree-loading": "jügudoitmine...",
+ "categorytree-nothing-found": "ei voi löuta",
+ "categorytree-no-subcategories": "ei ole alakategorijoid"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/vi.json b/www/wiki/extensions/CategoryTree/i18n/vi.json
new file mode 100644
index 00000000..a0c190af
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/vi.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minh Nguyen",
+ "Vinhtantran"
+ ]
+ },
+ "categorytree": "Cây thể loại",
+ "categorytree-portlet": "Thể loại",
+ "categorytree-legend": "Hiển thị cây thể loại",
+ "categorytree-desc": "Công cụ AJAX để hiển thị [[Special:CategoryTree|cấu trúc thể loại]] của một wiki",
+ "categorytree-header": "Gõ vào tên thể loại để xem nội dung của nó theo cấu trúc cây. (Yêu cầu JavaScript.)",
+ "categorytree-category": "Thể loại:",
+ "categorytree-go": "Hiển thị",
+ "categorytree-parents": "Các thể loại mẹ",
+ "categorytree-mode-label": "Chế độ:",
+ "categorytree-mode-categories": "Chỉ liệt kê các thể loại",
+ "categorytree-mode-pages": "các trang ngoại trừ trang tập tin",
+ "categorytree-mode-all": "tất cả các trang",
+ "categorytree-collapse": "đóng",
+ "categorytree-expand": "mở",
+ "categorytree-member-counts": "Có $1 thể loại con, $2 trang, và $3 tập tin",
+ "categorytree-num-categories": "$1 t.l.",
+ "categorytree-num-pages": "$1 tr.",
+ "categorytree-num-files": "$1 t.t.",
+ "categorytree-num-empty": "trống",
+ "categorytree-load": "tải",
+ "categorytree-loading": "đang tải…",
+ "categorytree-nothing-found": "Không có gì.",
+ "categorytree-no-subcategories": "Không có thể loại con",
+ "categorytree-no-parent-categories": "không nằm trong thể loại nào",
+ "categorytree-no-pages": "Không có trang hay thể loại con",
+ "categorytree-not-found": "Không tìm thấy thể loại <i>$1</i>",
+ "categorytree-error": "Có vấn đề khi tải dữ liệu.",
+ "categorytree-retry": "Xin hãy chờ một chút rồi thử lại.",
+ "apihelp-categorytree-description": "Mô đun nội bộ cho phần mở rộng Cây thể loại.",
+ "apihelp-categorytree-param-category": "Tên trang trong không gian tên thể loại; tiền tố nào đó sẽ được bỏ qua."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/vls.json b/www/wiki/extensions/CategoryTree/i18n/vls.json
new file mode 100644
index 00000000..bc20c36e
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/vls.json
@@ -0,0 +1,4 @@
+{
+ "@metadata": [],
+ "categorytree-collapse": "toesmytn"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/vo.json b/www/wiki/extensions/CategoryTree/i18n/vo.json
new file mode 100644
index 00000000..1a401871
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/vo.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya",
+ "Smeira"
+ ]
+ },
+ "categorytree": "KladaBim",
+ "categorytree-portlet": "Klads",
+ "categorytree-legend": "Jonolöd kladabimi",
+ "categorytree-desc": "Jonön [[Special:CategoryTree|kladabimi]] e mufön ve on.",
+ "categorytree-header": "Penolös kladanemi ad logön ninädi klada as bimabinod. Küpälolös, das atos flagon dili ela JavaScript labü nem: AJAX. No oplöpon if labol bevüresodanafömi vönädik, ud if enemogüköl eli JavaScript.",
+ "categorytree-category": "Klad:",
+ "categorytree-go": "Jonolöd Bimi",
+ "categorytree-parents": "Pals",
+ "categorytree-mode-categories": "te klads",
+ "categorytree-mode-pages": "pads pläamü ragivs",
+ "categorytree-mode-all": "pads valik",
+ "categorytree-collapse": "brefükön",
+ "categorytree-expand": "stäänükön",
+ "categorytree-member-counts": "ninädon {{PLURAL:$1|donakladi 1|donakladis $1}}, {{PLURAL:$2|padi 1|padis $2}} e {{PLURAL:$3|ragivi 1|ragivis $3}}",
+ "categorytree-num-categories": "K $1",
+ "categorytree-num-pages": "P $1",
+ "categorytree-num-files": "R $1",
+ "categorytree-load": "lodön",
+ "categorytree-loading": "lodam",
+ "categorytree-nothing-found": "nos petuvon",
+ "categorytree-no-subcategories": "donaklads nonik",
+ "categorytree-no-parent-categories": "palaklads nonik",
+ "categorytree-no-pages": "pads e donaklads noniks",
+ "categorytree-not-found": "Klad: <i>$1</i> no petuvöl",
+ "categorytree-error": "No eplöpos ad lodön nünis.",
+ "categorytree-retry": "Stebedolös, begö! timüli e steifülolös dönu."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/vro.json b/www/wiki/extensions/CategoryTree/i18n/vro.json
new file mode 100644
index 00000000..2750e57c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/vro.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Võrok"
+ ]
+ },
+ "categorytree-expand": "näüdäq",
+ "categorytree-member-counts": "Tan om {{PLURAL:$1|1 allkatõgooria|$1 allkatõgooriat}}, {{PLURAL:$2|1 leht|$2 lehte}}, ja {{PLURAL:$3|1 fail|$3 faili}}",
+ "categorytree-num-categories": "$1 L",
+ "categorytree-num-pages": "$1 L",
+ "categorytree-num-files": "$1 F"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/wa.json b/www/wiki/extensions/CategoryTree/i18n/wa.json
new file mode 100644
index 00000000..09fefa02
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/wa.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lucyin",
+ "Srtxg"
+ ]
+ },
+ "categorytree": "Coxhlaedje des categoreyes",
+ "categorytree-portlet": "Categoreyes",
+ "categorytree-category": "Categoreye:",
+ "categorytree-parents": "Parints",
+ "categorytree-mode-all": "Totes les pådjes",
+ "categorytree-collapse": "erôler",
+ "categorytree-expand": "diswalper",
+ "categorytree-member-counts": "gn a $1 dizo-categoreye{{PLURAL:$1||s}}, $2 pådje{{PLURAL:$2||s}} et $3 fitchî{{PLURAL:$3||s}}",
+ "categorytree-num-categories": "$1 cat.",
+ "categorytree-num-pages": "$1 p.",
+ "categorytree-num-files": "$1 fitch.",
+ "categorytree-num-empty": "vude",
+ "categorytree-loading": "dji so k' eberwete...",
+ "categorytree-nothing-found": "rén trové",
+ "categorytree-no-subcategories": "Nole dizo-categoreye",
+ "categorytree-no-parent-categories": "Nole dizeu-categoreye",
+ "categorytree-no-pages": "Nole pådje ou categoreye",
+ "categorytree-not-found": "Categoreye <i>$1</i> nén trovêye",
+ "categorytree-error": "Aroke d' eberwetaedje",
+ "categorytree-retry": "Tårdjîz ene miete eyet rsayî"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/war.json b/www/wiki/extensions/CategoryTree/i18n/war.json
new file mode 100644
index 00000000..093148d5
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/war.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "JinJian"
+ ]
+ },
+ "categorytree-parents": "Mga kag-anak",
+ "categorytree-mode-all": "ngatanan nga mga pakli",
+ "categorytree-collapse": "rumpag",
+ "categorytree-expand": "iglatag",
+ "categorytree-member-counts": "Naglalakip hin {{PLURAL:$1|1 ka subcategory|$1 ka mga subcategory}}, {{PLURAL:$2|1 ka pakli|$2 ka mga pakli}}, ngan {{PLURAL:$3|1 file|$3 mga file}}",
+ "categorytree-num-categories": "$1 K",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "waray sulod"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/wo.json b/www/wiki/extensions/CategoryTree/i18n/wo.json
new file mode 100644
index 00000000..706aefce
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/wo.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ibou"
+ ]
+ },
+ "categorytree-expand": "tallal",
+ "categorytree-member-counts": "Ëmb na {{PLURAL:$1|1 ron-wàll|$1 ron-wàll}},{{PLURAL:$2|xët|$2 xët}}, ak {{PLURAL:$3|1 dencukaay|$3 dencukaay}}",
+ "categorytree-num-categories": "$1 W",
+ "categorytree-num-pages": "$1 X",
+ "categorytree-num-files": "$1 D"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/wuu.json b/www/wiki/extensions/CategoryTree/i18n/wuu.json
new file mode 100644
index 00000000..62a8780a
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/wuu.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Wtzdj",
+ "Xiaomingyan",
+ "Poiuyt",
+ "飞舞回堂前"
+ ]
+ },
+ "categorytree": "分类树",
+ "categorytree-portlet": "分类",
+ "categorytree-legend": "显示分类树",
+ "categorytree-category": "分类",
+ "categorytree-go": "显示分类树",
+ "categorytree-mode-categories": "仅分类",
+ "categorytree-mode-pages": "除脱图片以外个页面",
+ "categorytree-mode-all": "所有页面",
+ "categorytree-collapse": "抈出来",
+ "categorytree-expand": "放开来",
+ "categorytree-member-counts": "包括$1个子分类,$2个页面搭$3只文件",
+ "categorytree-num-categories": "$1分类",
+ "categorytree-num-pages": "$1页面",
+ "categorytree-num-files": "$1文件",
+ "categorytree-nothing-found": "一样也朆寻着",
+ "categorytree-no-subcategories": "呒不子分类",
+ "categorytree-no-pages": "呒不页面或者子分类",
+ "categorytree-not-found": "寻弗着分类<i>$1</i>",
+ "categorytree-retry": "请等歇再试。"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/xal.json b/www/wiki/extensions/CategoryTree/i18n/xal.json
new file mode 100644
index 00000000..50a646d0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/xal.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Huuchin"
+ ]
+ },
+ "categorytree-expand": "делгх",
+ "categorytree-member-counts": "$1 дед әәшл, $2 халх, болн $3 боомг бәрдг",
+ "categorytree-num-categories": "$1 Ә",
+ "categorytree-num-pages": "$1 Х",
+ "categorytree-num-files": "$1 Б"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/xmf.json b/www/wiki/extensions/CategoryTree/i18n/xmf.json
new file mode 100644
index 00000000..4a835b0b
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/xmf.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Silovan"
+ ]
+ },
+ "categorytree-expand": "გოფაჩუა",
+ "categorytree-member-counts": "იკათუანს {{PLURAL:$1|1 გიმენკატეგორიას|$1 გიმენკატეგორიას}}, {{PLURAL:$2|1 ხასჷლას|$2 ხასჷლას}}, დო {{PLURAL:$3|1 ფაილს|$3 ფაილს}}",
+ "categorytree-num-categories": "$1 კ",
+ "categorytree-num-pages": "$1 ხ",
+ "categorytree-num-files": "$1 ფ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/yi.json b/www/wiki/extensions/CategoryTree/i18n/yi.json
new file mode 100644
index 00000000..6d2a8843
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/yi.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "פוילישער"
+ ]
+ },
+ "categorytree": "קאַטעגאריע בוים",
+ "categorytree-portlet": "קאַטעגאריעס",
+ "categorytree-legend": "ווײַזן קאַטעגאריע בוים",
+ "categorytree-desc": "נאוויגירן דינאמיש דעם [[Special:CategoryTree|קאטעגאריע סטרוקטור]]",
+ "categorytree-header": "לייגט אריין א קאטעגאריע נאמען צו זען איר אינהאלט אלס א בוים סטרוקטור.(פֿאדערט JavaScript.)",
+ "categorytree-category": "קאטעגאריע:",
+ "categorytree-go": "ווײַזן בוים",
+ "categorytree-parents": "העכערע קאַטעגאריעס",
+ "categorytree-mode-label": "מאדע:",
+ "categorytree-mode-categories": "נאר קאַטעגאריעס",
+ "categorytree-mode-pages": "בלעטער וואס זענען נישט טעקעס",
+ "categorytree-mode-all": "אַלע בלעטער",
+ "categorytree-collapse": "אײַנציען",
+ "categorytree-expand": "פֿאַרברייטערן",
+ "categorytree-expand-bullet": "◄",
+ "categorytree-empty-bullet": "◄",
+ "categorytree-member-counts": "אנטהאלט {{PLURAL:$1|1 אונטערקאטעגאריע|$1 אונטערקאטעגאריעס}}, {{PLURAL:$2|1 בלאט|$2 בלעטער}}, און {{PLURAL:$3|1 טעקע|$3 טעקעס}}",
+ "categorytree-num-categories": "$1 קאַט",
+ "categorytree-num-pages": "$1 ב",
+ "categorytree-num-files": "$1 ט",
+ "categorytree-num-empty": "ליידיק",
+ "categorytree-load": "לאָדן",
+ "categorytree-loading": "לאָדנדיק…",
+ "categorytree-nothing-found": "גארנישט געפֿונען",
+ "categorytree-no-subcategories": "נישטא קיין אונטער-קאַטעגאריעס",
+ "categorytree-no-parent-categories": "נישטא קיין עלטערן קאַטעגאריעס",
+ "categorytree-no-pages": "נישטא קיין בלעטער אדער אונטער-קאַטעגאריעס",
+ "categorytree-not-found": "קאַטעגאריע '''$1''' נישט געפֿונען",
+ "categorytree-error": "פּראָבלעם בײַם ארויפֿלאָדן דאַטן.",
+ "categorytree-retry": "ביטע וואַרט אַ רגע און פרובירט נאכאַמאָל"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/yo.json b/www/wiki/extensions/CategoryTree/i18n/yo.json
new file mode 100644
index 00000000..0a4f0ab0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/yo.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Demmy"
+ ]
+ },
+ "categorytree": "Igi ẹ̀ka",
+ "categorytree-portlet": "Àwọn ẹ̀ka",
+ "categorytree-legend": "Ìfihàn igi ẹ̀ka",
+ "categorytree-header": "Ẹ fi orúkọ ẹ̀ka kan síbẹ̀ láti wo àwọn àkóónú rẹ̀ gẹ́gẹ́ bíi ẹ̀ka igi.\nÀkíyèsí pé irú JavaScript tó únjẹ́ AJAX pọn dandan fun láti ṣiṣẹ́.\nTó bá ṣe pé agbétàkùn yín jẹ́ tàti pípẹ́, tàbí JavaScript jẹ́ dídálẹ́kun, kò ní ṣiṣẹ́.",
+ "categorytree-category": "Ẹ̀ka:",
+ "categorytree-go": "Ìfihàn igi",
+ "categorytree-parents": "Àwọn òbí",
+ "categorytree-mode-categories": "àwọn ẹ̀ka nìkan",
+ "categorytree-mode-pages": "àwọn ojúewé àyàfi àwọn fáìlì",
+ "categorytree-mode-all": "gbogbo àwọn ojúewé",
+ "categorytree-collapse": "kálura",
+ "categorytree-expand": "fẹ̀hàn",
+ "categorytree-member-counts": "ní {{PLURAL:$1|ẹ̀kaabẹ́ 1|àwọn ẹ̀kaabẹ́ $1}}, {{PLURAL:$2|ojúewé 1 page|àwọn ojúewé $2}}, àti {{PLURAL:$3|fáìlì 1|àwọn fáìlì $3}} nínú",
+ "categorytree-num-categories": "Ẹ̀k. $1",
+ "categorytree-num-pages": "Oj. $1",
+ "categorytree-num-files": "Fá. $1",
+ "categorytree-num-empty": "olófo",
+ "categorytree-load": "ìgbéyọ",
+ "categorytree-loading": "úngbéyọ...",
+ "categorytree-nothing-found": "kò sí ùnkankan",
+ "categorytree-no-subcategories": "Kò sí àwọn ẹ̀kaabẹ́",
+ "categorytree-no-parent-categories": "kò sí àwọn ẹ̀ka òbí",
+ "categorytree-no-pages": "kò sí àwọn ojúewé tàbí àwọn ẹ̀kaabẹ́",
+ "categorytree-not-found": "Ẹ̀ka <i>$1</i> kò ṣe é wárí",
+ "categorytree-error": "Ìṣòro ìgbéyọ dátà.",
+ "categorytree-retry": "Ẹ jọ̀wọ́ ẹ dúró fún gbà díẹ̀ kí ẹ tó gbìyànjú lẹ́ẹ̀kansíi."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/yue.json b/www/wiki/extensions/CategoryTree/i18n/yue.json
new file mode 100644
index 00000000..e2c769f9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/yue.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Shinjiman",
+ "CRCHF",
+ "Ktchankt",
+ "Yueman"
+ ]
+ },
+ "categorytree": "分類樹",
+ "categorytree-portlet": "分類",
+ "categorytree-legend": "顯示分類樹",
+ "categorytree-desc": "一個以AJAX為主嘅小工具去顯示響一個wiki嘅[[Special:CategoryTree|分類架構]]",
+ "categorytree-header": "輸入分類名去睇佢嘅樹形結構內容。(需要JavaScript)",
+ "categorytree-category": "分類",
+ "categorytree-go": "載入",
+ "categorytree-parents": "父分類",
+ "categorytree-mode-label": "模式:",
+ "categorytree-mode-categories": "只顯示分類",
+ "categorytree-mode-pages": "除咗圖像之外嘅版",
+ "categorytree-mode-all": "全版",
+ "categorytree-collapse": "收埋",
+ "categorytree-expand": "打開",
+ "categorytree-member-counts": "有$1個細分類、$2版同$3個檔案",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 F",
+ "categorytree-num-empty": "空",
+ "categorytree-load": "載入",
+ "categorytree-loading": "載入緊…",
+ "categorytree-nothing-found": "搵唔到任何嘢",
+ "categorytree-no-subcategories": "冇細分類",
+ "categorytree-no-parent-categories": "冇父分類",
+ "categorytree-no-pages": "冇版或者細分類",
+ "categorytree-not-found": "搵唔到<i>$1</i>分類",
+ "categorytree-error": "載入資料嗰陣發生咗錯誤。",
+ "categorytree-retry": "請等多一陣再試過。",
+ "apihelp-categorytree-description": "CategoryTree嘅內部模組",
+ "apihelp-categorytree-summary": "CategoryTree嘅內部模組",
+ "apihelp-categorytree-param-category": "類空間名嘅標題,如果有字頭會忽略",
+ "apihelp-categorytree-param-options": "將CategoryTree構造器當做JSON物件嘅選項。<var>depth</var>選項預設值係<kbd>1</kbd>。",
+ "apierror-categorytree-invalidjson": "選項一定要係個有效JSON物件。"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/zea.json b/www/wiki/extensions/CategoryTree/i18n/zea.json
new file mode 100644
index 00000000..52da3707
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/zea.json
@@ -0,0 +1,31 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ooswesthoesbes"
+ ]
+ },
+ "categorytree": "Catehorieboôm",
+ "categorytree-portlet": "Categorieën",
+ "categorytree-category": "Categorie:",
+ "categorytree-go": "Structuur weerheven",
+ "categorytree-parents": "Bovenliggende categorieën",
+ "categorytree-mode-categories": "alleên categorieën",
+ "categorytree-mode-pages": "hin aofbildiengen",
+ "categorytree-mode-all": "aolle bladzies",
+ "categorytree-collapse": "inklapp'n",
+ "categorytree-expand": "uutvaow'n",
+ "categorytree-member-counts": "bevat {{PLURAL:$1|eên ondercategorie|$1 ondercategorieën}}, {{PLURAL:$2|eên pagina|$2 pagina's}} en {{PLURAL:$3|eên bestand|$3 bestanden}}",
+ "categorytree-num-categories": "$1 C",
+ "categorytree-num-pages": "$1 P",
+ "categorytree-num-files": "$1 B",
+ "categorytree-num-empty": "leeh",
+ "categorytree-load": "laed'n",
+ "categorytree-loading": "an 't laed'n...",
+ "categorytree-nothing-found": "niks hevaond'n",
+ "categorytree-no-subcategories": "Hin ondercategorieën",
+ "categorytree-no-parent-categories": "hin bovencategorieën",
+ "categorytree-no-pages": "Hin bladzies of ondercategorieën",
+ "categorytree-not-found": "Categorie <i>$1</i> is nie hevond'n",
+ "categorytree-error": "Probleem bie 't laed'n von de hehevens.",
+ "categorytree-retry": "Wacht even en probeer 't dan opnuuw."
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/zgh.json b/www/wiki/extensions/CategoryTree/i18n/zgh.json
new file mode 100644
index 00000000..af718ab4
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/zgh.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amara-Amaziɣ",
+ "YesIn",
+ "Mdb897"
+ ]
+ },
+ "categorytree-expand": "ⴼⵙⵉ",
+ "categorytree-member-counts": "ⵢⵓⵎⴰ {{PLURAL:$1|1 ⴰⴷⵓⵙⵎⵉⵍ|$1 ⵉⴷⵓⵙⵎⵉⵍⵏ}}, {{PLURAL:$2|1 ⵜⴰⵙⵏⴰ|$2 ⵜⵉⵙⵏⴰⵜⵉⵏ}}, ⴷ {{PLURAL:$3|1 ⴰⵙⴷⴰⵡ|$3 ⵉⵙⴷⴰⵡⵏ}}",
+ "categorytree-num-categories": "$1 {{PLURAL:$1|ⵙⵎⵍ|ⵙⵎⵍⵏ}}",
+ "categorytree-num-pages": "$1 {{PLURAL:$1|ⵙⵏ|ⵙⵏⵡⵏ}}",
+ "categorytree-num-files": "$1 ⴼ"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/zh-hans.json b/www/wiki/extensions/CategoryTree/i18n/zh-hans.json
new file mode 100644
index 00000000..98bf7832
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/zh-hans.json
@@ -0,0 +1,48 @@
+{
+ "@metadata": {
+ "authors": [
+ "Breawycker",
+ "Liangent",
+ "PhiLiP",
+ "Shinjiman",
+ "Shizhao",
+ "Xiaomingyan",
+ "Mywood",
+ "Impersonator 1",
+ "Liuxinyu970226"
+ ]
+ },
+ "categorytree": "分类树",
+ "categorytree-portlet": "分类",
+ "categorytree-legend": "显示分类树",
+ "categorytree-desc": "动态导航[[Special:CategoryTree|分类结构]]",
+ "categorytree-header": "请输入一个分类名称以使用树形结构查看其内容。(需要JavaScript。)",
+ "categorytree-category": "分类:",
+ "categorytree-go": "显示分类树",
+ "categorytree-parents": "父分类",
+ "categorytree-mode-label": "模式:",
+ "categorytree-mode-categories": "仅分类",
+ "categorytree-mode-pages": "除文件外的页面",
+ "categorytree-mode-all": "所有页面",
+ "categorytree-collapse": "折叠",
+ "categorytree-expand": "展开",
+ "categorytree-member-counts": "含有$1个子分类,$2个页面和$3个文件",
+ "categorytree-num-categories": "$1分类",
+ "categorytree-num-pages": "$1页面",
+ "categorytree-num-files": "$1文件",
+ "categorytree-num-empty": "空",
+ "categorytree-load": "载入",
+ "categorytree-loading": "正在载入...",
+ "categorytree-nothing-found": "没找到",
+ "categorytree-no-subcategories": "无子分类",
+ "categorytree-no-parent-categories": "无父分类",
+ "categorytree-no-pages": "没有页面或子分类",
+ "categorytree-not-found": "找不到分类<i>$1</i>",
+ "categorytree-error": "载入数据出错。",
+ "categorytree-retry": "请稍后重试。",
+ "apihelp-categorytree-description": "用于CategoryTree扩展的内部模块。",
+ "apihelp-categorytree-summary": "用于CategoryTree扩展的内部模块。",
+ "apihelp-categorytree-param-category": "分类名字空间中的标题,如果提供前缀将会被忽略。",
+ "apihelp-categorytree-param-options": "用于CategoryTree构造器的选项,作为一个JSON对象。<var>depth</var>选项默认为<kbd>1</kbd>。",
+ "apierror-categorytree-invalidjson": "选项必须是有效的JSON对象。"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/zh-hant.json b/www/wiki/extensions/CategoryTree/i18n/zh-hant.json
new file mode 100644
index 00000000..6e8dcdbd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/zh-hant.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Alexsh",
+ "Liangent",
+ "Mark85296341",
+ "Oapbtommy",
+ "Shinjiman",
+ "Simon Shek",
+ "Liuxinyu970226",
+ "Cwlin0416",
+ "Duolaimi",
+ "Wehwei",
+ "Kly"
+ ]
+ },
+ "categorytree": "分類樹",
+ "categorytree-portlet": "分類",
+ "categorytree-legend": "顯示分類樹",
+ "categorytree-desc": "可用動態更新的方式導覽 [[Special:CategoryTree|分類結構]]",
+ "categorytree-header": "請輸入分類名稱以使用樹狀結構檢視分類內容。\n(需要使用 JavaScript。)",
+ "categorytree-category": "分類:",
+ "categorytree-go": "顯示樹狀結構",
+ "categorytree-parents": "上層分類",
+ "categorytree-mode-label": "模式:",
+ "categorytree-mode-categories": "只顯示分類",
+ "categorytree-mode-pages": "頁面不包含檔案",
+ "categorytree-mode-all": "所有頁面",
+ "categorytree-collapse": "摺疊",
+ "categorytree-expand": "展開",
+ "categorytree-member-counts": "包含 $1 個子分類、$2 個頁面和 $3 個檔案",
+ "categorytree-num-categories": "$1 分類",
+ "categorytree-num-pages": "$1 頁面",
+ "categorytree-num-files": "$1 檔案",
+ "categorytree-num-empty": "空的",
+ "categorytree-load": "讀取",
+ "categorytree-loading": "讀取中…",
+ "categorytree-nothing-found": "查無任何項目",
+ "categorytree-no-subcategories": "無子分類",
+ "categorytree-no-parent-categories": "無上層分類",
+ "categorytree-no-pages": "無頁面或子分類",
+ "categorytree-not-found": "查無分類 <i>$1</i>",
+ "categorytree-error": "讀取資料時發生錯誤。",
+ "categorytree-retry": "請稍候再試一次。",
+ "apihelp-categorytree-description": "用於 CategoryTree 擴充套件的內部模組。",
+ "apihelp-categorytree-summary": "用於 CategoryTree 擴充套件的內部模組。",
+ "apihelp-categorytree-param-category": "在分類命名空間中的標題,若有字首則會忽略。",
+ "apihelp-categorytree-param-options": "供 CategoryTree 建構子的 JSON 物件參數。<var>depth</var> 項目預設為 <kbd>1</kbd>。",
+ "apierror-categorytree-invalidjson": "選項必須為有效的 JSON 物件。"
+}
diff --git a/www/wiki/extensions/CategoryTree/i18n/zu.json b/www/wiki/extensions/CategoryTree/i18n/zu.json
new file mode 100644
index 00000000..25077619
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/i18n/zu.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "categorytree-collapse": "Nciphisa",
+ "categorytree-expand": "Khulisa"
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/ApiCategoryTree.php b/www/wiki/extensions/CategoryTree/includes/ApiCategoryTree.php
new file mode 100644
index 00000000..f512ea4c
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/ApiCategoryTree.php
@@ -0,0 +1,143 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+class ApiCategoryTree extends ApiBase {
+ public function execute() {
+ $params = $this->extractRequestParams();
+ $options = [];
+ if ( isset( $params['options'] ) ) {
+ $options = FormatJson::decode( $params['options'] );
+ if ( !is_object( $options ) ) {
+ if ( is_callable( [ $this, 'dieWithError' ] ) ) {
+ $this->dieWithError( 'apierror-categorytree-invalidjson', 'invalidjson' );
+ } else {
+ $this->dieUsage( 'Options must be valid a JSON object', 'invalidjson' );
+ }
+ return;
+ }
+ $options = get_object_vars( $options );
+ }
+ $depth = isset( $options['depth'] ) ? (int)$options['depth'] : 1;
+
+ $ct = new CategoryTree( $options );
+ $depth = CategoryTree::capDepth( $ct->getOption( 'mode' ), $depth );
+ $title = CategoryTree::makeTitle( $params['category'] );
+ $config = $this->getConfig();
+ $ctConfig = ConfigFactory::getDefaultInstance()->makeConfig( 'categorytree' );
+ $html = $this->getHTML( $ct, $title, $depth, $ctConfig );
+
+ if (
+ $ctConfig->get( 'CategoryTreeHTTPCache' ) &&
+ $config->get( 'SquidMaxage' ) &&
+ $config->get( 'UseSquid' )
+ ) {
+ if ( $config->get( 'UseESI' ) ) {
+ $this->getRequest()->response()->header(
+ 'Surrogate-Control: max-age=' . $config->get( 'SquidMaxage' ) . ', content="ESI/1.0"'
+ );
+ $this->getMain()->setCacheMaxAge( 0 );
+ } else {
+ $this->getMain()->setCacheMaxAge( $config->get( 'SquidMaxage' ) );
+ }
+ // cache for anons only
+ $this->getRequest()->response()->header( 'Vary: Accept-Encoding, Cookie' );
+ // TODO: purge the squid cache when a category page is invalidated
+ }
+
+ $this->getResult()->addContentValue( $this->getModuleName(), 'html', $html );
+ }
+
+ /**
+ * @param string $condition
+ *
+ * @return bool|null|string
+ */
+ public function getConditionalRequestData( $condition ) {
+ if ( $condition === 'last-modified' ) {
+ $params = $this->extractRequestParams();
+ $title = CategoryTree::makeTitle( $params['category'] );
+ return wfGetDB( DB_REPLICA )->selectField( 'page', 'page_touched',
+ [
+ 'page_namespace' => NS_CATEGORY,
+ 'page_title' => $title->getDBkey(),
+ ],
+ __METHOD__
+ );
+ }
+ }
+
+ /**
+ * Get category tree HTML for the given tree, title, depth and config
+ *
+ * @param CategoryTree $ct
+ * @param Title $title
+ * @param int $depth
+ * @param Config $ctConfig Config for CategoryTree
+ * @return string HTML
+ */
+ private function getHTML( $ct, $title, $depth, $ctConfig ) {
+ global $wgContLang, $wgMemc;
+
+ $mckey = wfMemcKey(
+ 'ajax-categorytree',
+ md5( $title->getDBkey() ),
+ md5( $ct->getOptionsAsCacheKey( $depth ) ),
+ $this->getLanguage()->getCode(),
+ $wgContLang->getExtraHashOptions(),
+ $ctConfig->get( 'RenderHashAppend' )
+ );
+
+ $touched = $this->getConditionalRequestData( 'last-modified' );
+ if ( $touched ) {
+ $mcvalue = $wgMemc->get( $mckey );
+ if ( $mcvalue && $touched <= $mcvalue['timestamp'] ) {
+ $html = $mcvalue['value'];
+ }
+ }
+
+ if ( !isset( $html ) ) {
+ $html = $ct->renderChildren( $title, $depth );
+
+ $wgMemc->set(
+ $mckey,
+ [
+ 'timestamp' => wfTimestampNow(),
+ 'value' => $html
+ ],
+ 86400
+ );
+ }
+ return trim( $html );
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'category' => [
+ ApiBase::PARAM_TYPE => 'string',
+ ApiBase::PARAM_REQUIRED => true,
+ ],
+ 'options' => [
+ ApiBase::PARAM_TYPE => 'string',
+ ],
+ ];
+ }
+
+ public function isInternal() {
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTree.php b/www/wiki/extensions/CategoryTree/includes/CategoryTree.php
new file mode 100644
index 00000000..139012fd
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTree.php
@@ -0,0 +1,822 @@
+<?php
+/**
+ * © 2006-2007 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+/**
+ * Core functions for the CategoryTree extension, an AJAX based gadget
+ * to display the category structure of a wiki
+ */
+class CategoryTree {
+ public $mOptions = [];
+
+ /**
+ * @param array $options
+ */
+ public function __construct( $options ) {
+ global $wgCategoryTreeDefaultOptions;
+
+ // ensure default values and order of options.
+ // Order may become important, it may influence the cache key!
+ foreach ( $wgCategoryTreeDefaultOptions as $option => $default ) {
+ if ( isset( $options[$option] ) ) {
+ $this->mOptions[$option] = $options[$option];
+ } else {
+ $this->mOptions[$option] = $default;
+ }
+ }
+
+ $this->mOptions['mode'] = self::decodeMode( $this->mOptions['mode'] );
+
+ if ( $this->mOptions['mode'] == CategoryTreeMode::PARENTS ) {
+ // namespace filter makes no sense with CategoryTreeMode::PARENTS
+ $this->mOptions['namespaces'] = false;
+ }
+
+ $this->mOptions['hideprefix'] = self::decodeHidePrefix( $this->mOptions['hideprefix'] );
+ $this->mOptions['showcount'] = self::decodeBoolean( $this->mOptions['showcount'] );
+ $this->mOptions['namespaces'] = self::decodeNamespaces( $this->mOptions['namespaces'] );
+
+ if ( $this->mOptions['namespaces'] ) {
+ # automatically adjust mode to match namespace filter
+ if ( count( $this->mOptions['namespaces'] ) === 1
+ && $this->mOptions['namespaces'][0] == NS_CATEGORY ) {
+ $this->mOptions['mode'] = CategoryTreeMode::CATEGORIES;
+ } elseif ( !in_array( NS_FILE, $this->mOptions['namespaces'] ) ) {
+ $this->mOptions['mode'] = CategoryTreeMode::PAGES;
+ } else {
+ $this->mOptions['mode'] = CategoryTreeMode::ALL;
+ }
+ }
+ }
+
+ /**
+ * @param string $name
+ * @return mixed
+ */
+ public function getOption( $name ) {
+ return $this->mOptions[$name];
+ }
+
+ /**
+ * @return bool
+ */
+ private function isInverse() {
+ return $this->getOption( 'mode' ) == CategoryTreeMode::PARENTS;
+ }
+
+ /**
+ * @param mixed $nn
+ * @return array|bool
+ */
+ private static function decodeNamespaces( $nn ) {
+ global $wgContLang;
+
+ if ( $nn === false || is_null( $nn ) ) {
+ return false;
+ }
+
+ if ( !is_array( $nn ) ) {
+ $nn = preg_split( '![\s#:|]+!', $nn );
+ }
+
+ $namespaces = [];
+
+ foreach ( $nn as $n ) {
+ if ( is_int( $n ) ) {
+ $ns = $n;
+ } else {
+ $n = trim( $n );
+ if ( $n === '' ) {
+ continue;
+ }
+
+ $lower = strtolower( $n );
+
+ if ( is_numeric( $n ) ) {
+ $ns = (int)$n;
+ } elseif ( $n == '-' || $n == '_' || $n == '*' || $lower == 'main' ) {
+ $ns = NS_MAIN;
+ } else {
+ $ns = $wgContLang->getNsIndex( $n );
+ }
+ }
+
+ if ( is_int( $ns ) ) {
+ $namespaces[] = $ns;
+ }
+ }
+
+ sort( $namespaces ); # get elements into canonical order
+ return $namespaces;
+ }
+
+ /**
+ * @param mixed $mode
+ * @return int|string
+ */
+ public static function decodeMode( $mode ) {
+ global $wgCategoryTreeDefaultOptions;
+
+ if ( is_null( $mode ) ) {
+ return $wgCategoryTreeDefaultOptions['mode'];
+ }
+ if ( is_int( $mode ) ) {
+ return $mode;
+ }
+
+ $mode = trim( strtolower( $mode ) );
+
+ if ( is_numeric( $mode ) ) {
+ return (int)$mode;
+ }
+
+ if ( $mode == 'all' ) {
+ $mode = CategoryTreeMode::ALL;
+ } elseif ( $mode == 'pages' ) {
+ $mode = CategoryTreeMode::PAGES;
+ } elseif ( $mode == 'categories' || $mode == 'sub' ) {
+ $mode = CategoryTreeMode::CATEGORIES;
+ } elseif ( $mode == 'parents' || $mode == 'super' || $mode == 'inverse' ) {
+ $mode = CategoryTreeMode::PARENTS;
+ } elseif ( $mode == 'default' ) {
+ $mode = $wgCategoryTreeDefaultOptions['mode'];
+ }
+
+ return (int)$mode;
+ }
+
+ /**
+ * Helper function to convert a string to a boolean value.
+ * Perhaps make this a global function in MediaWiki proper
+ * @param mixed $value
+ * @return bool|null|string
+ */
+ public static function decodeBoolean( $value ) {
+ if ( is_null( $value ) ) {
+ return null;
+ }
+ if ( is_bool( $value ) ) {
+ return $value;
+ }
+ if ( is_int( $value ) ) {
+ return ( $value > 0 );
+ }
+
+ $value = trim( strtolower( $value ) );
+ if ( is_numeric( $value ) ) {
+ return ( (int)$value > 0 );
+ }
+
+ if ( $value == 'yes' || $value == 'y'
+ || $value == 'true' || $value == 't' || $value == 'on'
+ ) {
+ return true;
+ } elseif ( $value == 'no' || $value == 'n'
+ || $value == 'false' || $value == 'f' || $value == 'off'
+ ) {
+ return false;
+ } elseif ( $value == 'null' || $value == 'default' || $value == 'none' || $value == 'x' ) {
+ return null;
+ } else {
+ return false;
+ }
+ }
+
+ /**
+ * @param mixed $value
+ * @return int|string
+ */
+ public static function decodeHidePrefix( $value ) {
+ global $wgCategoryTreeDefaultOptions;
+
+ if ( is_null( $value ) ) {
+ return $wgCategoryTreeDefaultOptions['hideprefix'];
+ }
+ if ( is_int( $value ) ) {
+ return $value;
+ }
+ if ( $value === true ) {
+ return CategoryTreeHidePrefix::ALWAYS;
+ }
+ if ( $value === false ) {
+ return CategoryTreeHidePrefix::NEVER;
+ }
+
+ $value = trim( strtolower( $value ) );
+
+ if ( $value == 'yes' || $value == 'y'
+ || $value == 'true' || $value == 't' || $value == 'on'
+ ) {
+ return CategoryTreeHidePrefix::ALWAYS;
+ } elseif ( $value == 'no' || $value == 'n'
+ || $value == 'false' || $value == 'f' || $value == 'off'
+ ) {
+ return CategoryTreeHidePrefix::NEVER;
+ } elseif ( $value == 'always' ) {
+ return CategoryTreeHidePrefix::ALWAYS;
+ } elseif ( $value == 'never' ) {
+ return CategoryTreeHidePrefix::NEVER;
+ } elseif ( $value == 'auto' ) {
+ return CategoryTreeHidePrefix::AUTO;
+ } elseif ( $value == 'categories' || $value == 'category' || $value == 'smart' ) {
+ return CategoryTreeHidePrefix::CATEGORIES;
+ } else {
+ return $wgCategoryTreeDefaultOptions['hideprefix'];
+ }
+ }
+
+ /**
+ * Add ResourceLoader modules to the OutputPage object
+ * @param OutputPage $outputPage
+ */
+ public static function setHeaders( $outputPage ) {
+ # Add the modules
+ $outputPage->addModuleStyles( 'ext.categoryTree.css' );
+ $outputPage->addModules( 'ext.categoryTree' );
+ }
+
+ /**
+ * @param array $options
+ * @param string $enc
+ * @return mixed
+ * @throws Exception
+ */
+ protected static function encodeOptions( $options, $enc ) {
+ if ( $enc == 'mode' || $enc == '' ) {
+ $opt = $options['mode'];
+ } elseif ( $enc == 'json' ) {
+ $opt = FormatJson::encode( $options );
+ } else {
+ throw new Exception( 'Unknown encoding for CategoryTree options: ' . $enc );
+ }
+
+ return $opt;
+ }
+
+ /**
+ * @param string|null $depth
+ * @return string
+ */
+ public function getOptionsAsCacheKey( $depth = null ) {
+ $key = "";
+
+ foreach ( $this->mOptions as $k => $v ) {
+ if ( is_array( $v ) ) {
+ $v = implode( '|', $v );
+ }
+ $key .= $k . ':' . $v . ';';
+ }
+
+ if ( !is_null( $depth ) ) {
+ $key .= ";depth=" . $depth;
+ }
+ return $key;
+ }
+
+ /**
+ * @param int|null $depth
+ * @return mixed
+ */
+ public function getOptionsAsJsStructure( $depth = null ) {
+ if ( $depth !== null ) {
+ $opt = $this->mOptions;
+ $opt['depth'] = $depth;
+ $s = self::encodeOptions( $opt, 'json' );
+ } else {
+ $s = self::encodeOptions( $this->mOptions, 'json' );
+ }
+
+ return $s;
+ }
+
+ /**
+ * @return string
+ */
+ private function getOptionsAsUrlParameters() {
+ return http_build_query( $this->mOptions );
+ }
+
+ /**
+ * Custom tag implementation. This is called by CategoryTreeHooks::parserHook, which is used to
+ * load CategoryTreeFunctions.php on demand.
+ * @param Parser $parser
+ * @param string $category
+ * @param bool $hideroot
+ * @param array $attr
+ * @param int $depth
+ * @param bool $allowMissing
+ * @return bool|string
+ */
+ public function getTag( $parser, $category, $hideroot = false, $attr = [], $depth = 1,
+ $allowMissing = false
+ ) {
+ global $wgCategoryTreeDisableCache;
+
+ $category = trim( $category );
+ if ( $category === '' ) {
+ return false;
+ }
+
+ if ( $parser ) {
+ if ( $wgCategoryTreeDisableCache === true ) {
+ $parser->disableCache();
+ } elseif ( is_int( $wgCategoryTreeDisableCache ) ) {
+ $parser->getOutput()->updateCacheExpiry( $wgCategoryTreeDisableCache );
+ }
+ }
+
+ $title = self::makeTitle( $category );
+
+ if ( $title === false || $title === null ) {
+ return false;
+ }
+
+ if ( isset( $attr['class'] ) ) {
+ $attr['class'] .= ' CategoryTreeTag';
+ } else {
+ $attr['class'] = ' CategoryTreeTag';
+ }
+
+ $attr['data-ct-mode'] = $this->mOptions['mode'];
+ $attr['data-ct-options'] = $this->getOptionsAsJsStructure();
+
+ $html = '';
+ $html .= Html::openElement( 'div', $attr );
+
+ if ( !$allowMissing && !$title->getArticleID() ) {
+ $html .= Html::openElement( 'span', [ 'class' => 'CategoryTreeNotice' ] );
+ if ( $parser ) {
+ $html .= $parser->recursiveTagParse(
+ wfMessage( 'categorytree-not-found', $category )->plain() );
+ } else {
+ $html .= wfMessage( 'categorytree-not-found', $category )->parse();
+ }
+ $html .= Html::closeElement( 'span' );
+ } else {
+ if ( !$hideroot ) {
+ $html .= $this->renderNode( $title, $depth );
+ } else {
+ $html .= $this->renderChildren( $title, $depth );
+ }
+ }
+
+ $html .= Xml::closeElement( 'div' );
+ $html .= "\n\t\t";
+
+ return $html;
+ }
+
+ /**
+ * Returns a string with an HTML representation of the children of the given category.
+ * @param Title $title
+ * @param int $depth
+ * @return string
+ */
+ public function renderChildren( $title, $depth = 1 ) {
+ global $wgCategoryTreeMaxChildren, $wgCategoryTreeUseCategoryTable;
+
+ if ( $title->getNamespace() != NS_CATEGORY ) {
+ // Non-categories can't have children. :)
+ return '';
+ }
+
+ $dbr = wfGetDB( DB_REPLICA );
+
+ $inverse = $this->isInverse();
+ $mode = $this->getOption( 'mode' );
+ $namespaces = $this->getOption( 'namespaces' );
+
+ $tables = [ 'page', 'categorylinks' ];
+ $fields = [ 'page_id', 'page_namespace', 'page_title',
+ 'page_is_redirect', 'page_len', 'page_latest', 'cl_to',
+ 'cl_from' ];
+ $where = [];
+ $joins = [];
+ $options = [ 'ORDER BY' => 'cl_type, cl_sortkey', 'LIMIT' => $wgCategoryTreeMaxChildren ];
+
+ if ( $inverse ) {
+ $joins['categorylinks'] = [ 'RIGHT JOIN', [
+ 'cl_to = page_title', 'page_namespace' => NS_CATEGORY
+ ] ];
+ $where['cl_from'] = $title->getArticleID();
+ } else {
+ $joins['categorylinks'] = [ 'JOIN', 'cl_from = page_id' ];
+ $where['cl_to'] = $title->getDBkey();
+ $options['USE INDEX']['categorylinks'] = 'cl_sortkey';
+
+ # namespace filter.
+ if ( $namespaces ) {
+ // NOTE: we assume that the $namespaces array contains only integers!
+ // decodeNamepsaces makes it so.
+ $where['page_namespace'] = $namespaces;
+ } elseif ( $mode != CategoryTreeMode::ALL ) {
+ if ( $mode == CategoryTreeMode::PAGES ) {
+ $where['cl_type'] = [ 'page', 'subcat' ];
+ } else {
+ $where['cl_type'] = 'subcat';
+ }
+ }
+ }
+
+ # fetch member count if possible
+ $doCount = !$inverse && $wgCategoryTreeUseCategoryTable;
+
+ if ( $doCount ) {
+ $tables = array_merge( $tables, [ 'category' ] );
+ $fields = array_merge( $fields, [
+ 'cat_id', 'cat_title', 'cat_subcats', 'cat_pages', 'cat_files'
+ ] );
+ $joins['category'] = [ 'LEFT JOIN', [
+ 'cat_title = page_title', 'page_namespace' => NS_CATEGORY ]
+ ];
+ }
+
+ $res = $dbr->select( $tables, $fields, $where, __METHOD__, $options, $joins );
+
+ # collect categories separately from other pages
+ $categories = '';
+ $other = '';
+
+ foreach ( $res as $row ) {
+ # NOTE: in inverse mode, the page record may be null, because we use a right join.
+ # happens for categories with no category page (red cat links)
+ if ( $inverse && $row->page_title === null ) {
+ $t = Title::makeTitle( NS_CATEGORY, $row->cl_to );
+ } else {
+ # TODO: translation support; ideally added to Title object
+ $t = Title::newFromRow( $row );
+ }
+
+ $cat = null;
+
+ if ( $doCount && $row->page_namespace == NS_CATEGORY ) {
+ $cat = Category::newFromRow( $row, $t );
+ }
+
+ $s = $this->renderNodeInfo( $t, $cat, $depth - 1 );
+ $s .= "\n\t\t";
+
+ if ( $row->page_namespace == NS_CATEGORY ) {
+ $categories .= $s;
+ } else {
+ $other .= $s;
+ }
+ }
+
+ return $categories . $other;
+ }
+
+ /**
+ * Returns a string with an HTML representation of the parents of the given category.
+ * @param Title $title
+ * @return string
+ */
+ public function renderParents( $title ) {
+ global $wgCategoryTreeMaxChildren;
+
+ $dbr = wfGetDB( DB_REPLICA );
+
+ $res = $dbr->select(
+ 'categorylinks',
+ [
+ 'page_namespace' => NS_CATEGORY,
+ 'page_title' => 'cl_to',
+ ],
+ [ 'cl_from' => $title->getArticleID() ],
+ __METHOD__,
+ [
+ 'LIMIT' => $wgCategoryTreeMaxChildren,
+ 'ORDER BY' => 'cl_to'
+ ]
+ );
+
+ $special = SpecialPage::getTitleFor( 'CategoryTree' );
+
+ $s = '';
+
+ foreach ( $res as $row ) {
+ $t = Title::newFromRow( $row );
+
+ $label = $t->getText();
+
+ $wikiLink = $special->getLocalURL( 'target=' . $t->getPartialURL() .
+ '&' . $this->getOptionsAsUrlParameters() );
+
+ if ( $s !== '' ) {
+ $s .= wfMessage( 'pipe-separator' )->escaped();
+ }
+
+ $s .= Xml::openElement( 'span', [ 'class' => 'CategoryTreeItem' ] );
+ $s .= Xml::element( 'a', [ 'class' => 'CategoryTreeLabel', 'href' => $wikiLink ], $label );
+ $s .= Xml::closeElement( 'span' );
+
+ $s .= "\n\t\t";
+ }
+
+ return $s;
+ }
+
+ /**
+ * Returns a string with a HTML represenation of the given page.
+ * @param Title $title
+ * @param int $children
+ * @return string
+ */
+ public function renderNode( $title, $children = 0 ) {
+ global $wgCategoryTreeUseCategoryTable;
+
+ if ( $wgCategoryTreeUseCategoryTable && $title->getNamespace() == NS_CATEGORY
+ && !$this->isInverse()
+ ) {
+ $cat = Category::newFromTitle( $title );
+ } else {
+ $cat = null;
+ }
+
+ return $this->renderNodeInfo( $title, $cat, $children );
+ }
+
+ /**
+ * Returns a string with a HTML represenation of the given page.
+ * $info must be an associative array, containing at least a Title object under the 'title' key.
+ * @param Title $title
+ * @param Category $cat
+ * @param int $children
+ * @return string
+ */
+ public function renderNodeInfo( $title, $cat, $children = 0 ) {
+ $mode = $this->getOption( 'mode' );
+
+ $ns = $title->getNamespace();
+ $key = $title->getDBkey();
+
+ $hideprefix = $this->getOption( 'hideprefix' );
+
+ if ( $hideprefix == CategoryTreeHidePrefix::ALWAYS ) {
+ $hideprefix = true;
+ } elseif ( $hideprefix == CategoryTreeHidePrefix::AUTO ) {
+ $hideprefix = ( $mode == CategoryTreeMode::CATEGORIES );
+ } elseif ( $hideprefix == CategoryTreeHidePrefix::CATEGORIES ) {
+ $hideprefix = ( $ns == NS_CATEGORY );
+ } else {
+ $hideprefix = true;
+ }
+
+ // when showing only categories, omit namespace in label unless we explicitely defined the
+ // configuration setting
+ // patch contributed by Manuel Schneider <manuel.schneider@wikimedia.ch>, Bug 8011
+ if ( $hideprefix ) {
+ $label = $title->getText();
+ } else {
+ $label = $title->getPrefixedText();
+ }
+
+ $labelClass = 'CategoryTreeLabel ' . ' CategoryTreeLabelNs' . $ns;
+
+ if ( !$title->getArticleID() ) {
+ $labelClass .= ' new';
+ $wikiLink = $title->getLocalURL( 'action=edit&redlink=1' );
+ } else {
+ $wikiLink = $title->getLocalURL();
+ }
+
+ if ( $ns == NS_CATEGORY ) {
+ $labelClass .= ' CategoryTreeLabelCategory';
+ } else {
+ $labelClass .= ' CategoryTreeLabelPage';
+ }
+
+ if ( ( $ns % 2 ) > 0 ) {
+ $labelClass .= ' CategoryTreeLabelTalk';
+ }
+
+ $count = false;
+ $s = '';
+
+ # NOTE: things in CategoryTree.js rely on the exact order of tags!
+ # Specifically, the CategoryTreeChildren div must be the first
+ # sibling with nodeName = DIV of the grandparent of the expland link.
+
+ $s .= Xml::openElement( 'div', [ 'class' => 'CategoryTreeSection' ] );
+ $s .= Xml::openElement( 'div', [ 'class' => 'CategoryTreeItem' ] );
+
+ $attr = [ 'class' => 'CategoryTreeBullet' ];
+
+ if ( $ns == NS_CATEGORY ) {
+ if ( $cat ) {
+ if ( $mode == CategoryTreeMode::CATEGORIES ) {
+ $count = intval( $cat->getSubcatCount() );
+ } elseif ( $mode == CategoryTreeMode::PAGES ) {
+ $count = intval( $cat->getPageCount() ) - intval( $cat->getFileCount() );
+ } else {
+ $count = intval( $cat->getPageCount() );
+ }
+ }
+ if ( $count === 0 ) {
+ $bullet = wfMessage( 'categorytree-empty-bullet' )->escaped() . ' ';
+ $attr['class'] = 'CategoryTreeEmptyBullet';
+ } else {
+ $linkattr = [];
+
+ $linkattr[ 'class' ] = "CategoryTreeToggle";
+ $linkattr['data-ct-title'] = $key;
+
+ $tag = 'span';
+ if ( $children == 0 ) {
+ // Use ->plain() and htmlspecialchars() to ensure
+ // identical to what is done by JS, which does:
+ // $link.text( mw.msg( 'categorytree-expand-bullet' ) )
+ $txt = htmlspecialchars( wfMessage( 'categorytree-expand-bullet' )->plain() );
+ $linkattr[ 'data-ct-state' ] = 'collapsed';
+ } else {
+ $txt = htmlspecialchars( wfMessage( 'categorytree-collapse-bullet' )->plain() );
+ $linkattr[ 'data-ct-loaded' ] = true;
+ $linkattr[ 'data-ct-state' ] = 'expanded';
+ }
+
+ $bullet = Xml::openElement( $tag, $linkattr ) . $txt . Xml::closeElement( $tag ) . ' ';
+ }
+ } else {
+ $bullet = wfMessage( 'categorytree-page-bullet' )->escaped();
+ }
+ $s .= Xml::tags( 'span', $attr, $bullet ) . ' ';
+
+ $s .= Xml::element(
+ 'a',
+ [
+ 'class' => $labelClass,
+ 'href' => $wikiLink,
+ 'title' => $title->getPrefixedText()
+ ],
+ $label
+ );
+
+ if ( $count !== false && $this->getOption( 'showcount' ) ) {
+ $s .= self::createCountString( RequestContext::getMain(), $cat, $count );
+ }
+
+ $s .= Xml::closeElement( 'div' );
+ $s .= "\n\t\t";
+ $s .= Xml::openElement(
+ 'div',
+ [
+ 'class' => 'CategoryTreeChildren',
+ 'style' => $children > 0 ? "display:block" : "display:none"
+ ]
+ );
+
+ if ( $ns == NS_CATEGORY && $children > 0 ) {
+ $children = $this->renderChildren( $title, $children );
+ if ( $children == '' ) {
+ $s .= Xml::openElement( 'i', [ 'class' => 'CategoryTreeNotice' ] );
+ if ( $mode == CategoryTreeMode::CATEGORIES ) {
+ $s .= wfMessage( 'categorytree-no-subcategories' )->escaped();
+ } elseif ( $mode == CategoryTreeMode::PAGES ) {
+ $s .= wfMessage( 'categorytree-no-pages' )->escaped();
+ } elseif ( $mode == CategoryTreeMode::PARENTS ) {
+ $s .= wfMessage( 'categorytree-no-parent-categories' )->escaped();
+ } else {
+ $s .= wfMessage( 'categorytree-nothing-found' )->escaped();
+ }
+ $s .= Xml::closeElement( 'i' );
+ } else {
+ $s .= $children;
+ }
+ }
+
+ $s .= Xml::closeElement( 'div' );
+ $s .= Xml::closeElement( 'div' );
+
+ $s .= "\n\t\t";
+
+ return $s;
+ }
+
+ /**
+ * Create a string which format the page, subcat and file counts of a category
+ * @param IContextSource $context
+ * @param Category|null $cat
+ * @param int $countMode
+ * @return string
+ */
+ public static function createCountString( IContextSource $context, $cat, $countMode ) {
+ global $wgContLang;
+
+ # Get counts, with conversion to integer so === works
+ # Note: $allCount is the total number of cat members,
+ # not the count of how many members are normal pages.
+ $allCount = $cat ? intval( $cat->getPageCount() ) : 0;
+ $subcatCount = $cat ? intval( $cat->getSubcatCount() ) : 0;
+ $fileCount = $cat ? intval( $cat->getFileCount() ) : 0;
+ $pages = $allCount - $subcatCount - $fileCount;
+
+ $attr = [
+ 'title' => $context->msg( 'categorytree-member-counts' )
+ ->numParams( $subcatCount, $pages, $fileCount, $allCount, $countMode )->text(),
+ 'dir' => $context->getLanguage()->getDir() # numbers and commas get messed up in a mixed dir env
+ ];
+
+ $s = $wgContLang->getDirMark() . ' ';
+
+ # Create a list of category members with only non-zero member counts
+ $memberNums = [];
+ if ( $subcatCount ) {
+ $memberNums[] = $context->msg( 'categorytree-num-categories' )
+ ->numParams( $subcatCount )->text();
+ }
+ if ( $pages ) {
+ $memberNums[] = $context->msg( 'categorytree-num-pages' )->numParams( $pages )->text();
+ }
+ if ( $fileCount ) {
+ $memberNums[] = $context->msg( 'categorytree-num-files' )
+ ->numParams( $fileCount )->text();
+ }
+ $memberNumsShort = $memberNums
+ ? $context->getLanguage()->commaList( $memberNums )
+ : $context->msg( 'categorytree-num-empty' )->text();
+
+ # Only $5 is actually used in the default message.
+ # Other arguments can be used in a customized message.
+ $s .= Xml::tags(
+ 'span',
+ $attr,
+ $context->msg( 'categorytree-member-num' )
+ // Do not use numParams on params 1-4, as they are only used for customisation.
+ ->params( $subcatCount, $pages, $fileCount, $allCount, $memberNumsShort )
+ ->escaped()
+ );
+
+ return $s;
+ }
+
+ /**
+ * Creates a Title object from a user provided (and thus unsafe) string
+ * @param string $title
+ * @return null|Title
+ */
+ public static function makeTitle( $title ) {
+ $title = trim( $title );
+
+ if ( strval( $title ) === '' ) {
+ return null;
+ }
+
+ # The title must be in the category namespace
+ # Ignore a leading Category: if there is one
+ $t = Title::newFromText( $title, NS_CATEGORY );
+ if ( !$t || $t->getNamespace() != NS_CATEGORY || $t->getInterwiki() != '' ) {
+ // If we were given something like "Wikipedia:Foo" or "Template:",
+ // try it again but forced.
+ $title = "Category:$title";
+ $t = Title::newFromText( $title );
+ }
+ return $t;
+ }
+
+ /**
+ * Internal function to cap depth
+ * @param string $mode
+ * @param int $depth
+ * @return int|mixed
+ */
+ public static function capDepth( $mode, $depth ) {
+ global $wgCategoryTreeMaxDepth;
+
+ if ( is_numeric( $depth ) ) {
+ $depth = intval( $depth );
+ } else {
+ return 1;
+ }
+
+ if ( is_array( $wgCategoryTreeMaxDepth ) ) {
+ $max = isset( $wgCategoryTreeMaxDepth[$mode] ) ? $wgCategoryTreeMaxDepth[$mode] : 1;
+ } elseif ( is_numeric( $wgCategoryTreeMaxDepth ) ) {
+ $max = $wgCategoryTreeMaxDepth;
+ } else {
+ wfDebug( 'CategoryTree::capDepth: $wgCategoryTreeMaxDepth is invalid.' );
+ $max = 1;
+ }
+
+ return min( $depth, $max );
+ }
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryPage.php b/www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryPage.php
new file mode 100644
index 00000000..77ab51a0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryPage.php
@@ -0,0 +1,23 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+class CategoryTreeCategoryPage extends CategoryPage {
+ public $mCategoryViewerClass = CategoryTreeCategoryViewer::class;
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryViewer.php b/www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryViewer.php
new file mode 100644
index 00000000..434d7222
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTreeCategoryViewer.php
@@ -0,0 +1,78 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+class CategoryTreeCategoryViewer extends CategoryViewer {
+ public $child_cats;
+
+ /**
+ * @var CategoryTree
+ */
+ public $categorytree;
+
+ /**
+ * @return CategoryTree
+ */
+ private function getCategoryTree() {
+ global $wgCategoryTreeCategoryPageOptions;
+
+ if ( !isset( $this->categorytree ) ) {
+ if ( !CategoryTreeHooks::shouldForceHeaders() ) {
+ CategoryTree::setHeaders( $this->getOutput() );
+ }
+
+ $this->categorytree = new CategoryTree( $wgCategoryTreeCategoryPageOptions );
+ }
+
+ return $this->categorytree;
+ }
+
+ /**
+ * Add a subcategory to the internal lists
+ * @param Category $cat
+ * @param string $sortkey
+ * @param int $pageLength
+ */
+ public function addSubcategoryObject( Category $cat, $sortkey, $pageLength ) {
+ $title = $cat->getTitle();
+
+ if ( $this->getRequest()->getCheck( 'notree' ) ) {
+ parent::addSubcategoryObject( $cat, $sortkey, $pageLength );
+ return;
+ }
+
+ $tree = $this->getCategoryTree();
+
+ $this->children[] = $tree->renderNodeInfo( $title, $cat );
+
+ $this->children_start_char[] = $this->getSubcategorySortChar( $title, $sortkey );
+ }
+
+ public function clearCategoryState() {
+ $this->child_cats = [];
+ parent::clearCategoryState();
+ }
+
+ public function finaliseCategoryState() {
+ if ( $this->flip ) {
+ $this->child_cats = array_reverse( $this->child_cats );
+ }
+ parent::finaliseCategoryState();
+ }
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTreeHidePrefix.php b/www/wiki/extensions/CategoryTree/includes/CategoryTreeHidePrefix.php
new file mode 100644
index 00000000..29d69b70
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTreeHidePrefix.php
@@ -0,0 +1,39 @@
+<?php
+/**
+ * © 2006 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+/**
+ * Constants for use with the hideprefix option,
+ * defining when the namespace prefix should be hidden.
+ */
+class CategoryTreeHidePrefix {
+
+ const NEVER = 0;
+
+ const ALWAYS = 10;
+
+ const CATEGORIES = 20;
+
+ const AUTO = 30;
+
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTreeHooks.php b/www/wiki/extensions/CategoryTree/includes/CategoryTreeHooks.php
new file mode 100644
index 00000000..a30d4932
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTreeHooks.php
@@ -0,0 +1,321 @@
+<?php
+/**
+ * © 2006-2008 Daniel Kinzler and others
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+/**
+ * Hooks for the CategoryTree extension, an AJAX based gadget
+ * to display the category structure of a wiki
+ */
+class CategoryTreeHooks {
+
+ public static function shouldForceHeaders() {
+ global $wgCategoryTreeSidebarRoot, $wgCategoryTreeHijackPageCategories,
+ $wgCategoryTreeForceHeaders;
+ return $wgCategoryTreeForceHeaders || $wgCategoryTreeSidebarRoot
+ || $wgCategoryTreeHijackPageCategories;
+ }
+
+ /**
+ * Adjusts config once MediaWiki is fully initialised
+ * TODO: Don't do this, lazy initialize the config
+ */
+ public static function initialize() {
+ global $wgRequest;
+ global $wgCategoryTreeDefaultOptions, $wgCategoryTreeDefaultMode;
+ global $wgCategoryTreeCategoryPageOptions, $wgCategoryTreeCategoryPageMode;
+ global $wgCategoryTreeOmitNamespace;
+
+ if ( !isset( $wgCategoryTreeDefaultOptions['mode'] )
+ || is_null( $wgCategoryTreeDefaultOptions['mode'] )
+ ) {
+ $wgCategoryTreeDefaultOptions['mode'] = $wgCategoryTreeDefaultMode;
+ }
+
+ if ( !isset( $wgCategoryTreeDefaultOptions['hideprefix'] )
+ || is_null( $wgCategoryTreeDefaultOptions['hideprefix'] )
+ ) {
+ $wgCategoryTreeDefaultOptions['hideprefix'] = $wgCategoryTreeOmitNamespace;
+ }
+
+ if ( !isset( $wgCategoryTreeCategoryPageOptions['mode'] )
+ || is_null( $wgCategoryTreeCategoryPageOptions['mode'] )
+ ) {
+ $mode = $wgRequest->getVal( 'mode' );
+ $wgCategoryTreeCategoryPageOptions['mode'] = ( $mode )
+ ? CategoryTree::decodeMode( $mode ) : $wgCategoryTreeCategoryPageMode;
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ */
+ public static function setHooks( $parser ) {
+ global $wgCategoryTreeAllowTag;
+ if ( !$wgCategoryTreeAllowTag ) {
+ return;
+ }
+ $parser->setHook( 'categorytree', 'CategoryTreeHooks::parserHook' );
+ $parser->setFunctionHook( 'categorytree', 'CategoryTreeHooks::parserFunction' );
+ }
+
+ /**
+ * Entry point for the {{#categorytree}} tag parser function.
+ * This is a wrapper around CategoryTreeHooks::parserHook
+ * @param Parser $parser
+ * @return array|string
+ */
+ public static function parserFunction( $parser ) {
+ $params = func_get_args();
+ array_shift( $params ); // first is $parser, strip it
+
+ // first user-supplied parameter must be category name
+ if ( !$params ) {
+ return ''; // no category specified, return nothing
+ }
+ $cat = array_shift( $params );
+
+ // build associative arguments from flat parameter list
+ $argv = [];
+ foreach ( $params as $p ) {
+ if ( preg_match( '/^\s*(\S.*?)\s*=\s*(.*?)\s*$/', $p, $m ) ) {
+ $k = $m[1];
+ $v = preg_replace( '/^"\s*(.*?)\s*"$/', '$1', $m[2] ); // strip any quotes enclusing the value
+ } else {
+ $k = trim( $p );
+ $v = true;
+ }
+
+ $argv[$k] = $v;
+ }
+
+ // now handle just like a <categorytree> tag
+ $html = self::parserHook( $cat, $argv, $parser );
+ return [ $html, 'noparse' => true, 'isHTML' => true ];
+ }
+
+ /**
+ * Hook implementation for injecting a category tree into the sidebar.
+ * Only does anything if $wgCategoryTreeSidebarRoot is set to a category name.
+ * @param Skin $skin
+ * @param SkinTemplate $tpl
+ */
+ public static function skinTemplateOutputPageBeforeExec( $skin, $tpl ) {
+ global $wgCategoryTreeSidebarRoot, $wgCategoryTreeSidebarOptions;
+
+ if ( !$wgCategoryTreeSidebarRoot ) {
+ return;
+ }
+
+ $html = self::parserHook( $wgCategoryTreeSidebarRoot, $wgCategoryTreeSidebarOptions );
+ if ( $html ) {
+ $tpl->data['sidebar']['categorytree-portlet'] = $html;
+ }
+ }
+
+ /**
+ * Entry point for the <categorytree> tag parser hook.
+ * This loads CategoryTreeFunctions.php and calls CategoryTree::getTag()
+ * @param string $cat
+ * @param array $argv
+ * @param Parser $parser
+ * @param bool $allowMissing
+ * @return bool|string
+ */
+ public static function parserHook( $cat, $argv, $parser = null, $allowMissing = false ) {
+ global $wgOut;
+
+ if ( $parser ) {
+ $parser->mOutput->mCategoryTreeTag = true; # flag for use by CategoryTreeHooks::parserOutput
+ } else {
+ CategoryTree::setHeaders( $wgOut );
+ }
+
+ $ct = new CategoryTree( $argv );
+
+ $attr = Sanitizer::validateTagAttributes( $argv, 'div' );
+
+ $hideroot = isset( $argv['hideroot'] )
+ ? CategoryTree::decodeBoolean( $argv['hideroot'] ) : null;
+ $onlyroot = isset( $argv['onlyroot'] )
+ ? CategoryTree::decodeBoolean( $argv['onlyroot'] ) : null;
+ $depthArg = isset( $argv['depth'] ) ? (int)$argv['depth'] : null;
+
+ $depth = CategoryTree::capDepth( $ct->getOption( 'mode' ), $depthArg );
+ if ( $onlyroot ) {
+ $depth = 0;
+ }
+
+ return $ct->getTag( $parser, $cat, $hideroot, $attr, $depth, $allowMissing );
+ }
+
+ /**
+ * Hook callback that injects messages and things into the <head> tag,
+ * if needed in the current page.
+ * Does nothing if $parserOutput->mCategoryTreeTag is not set
+ * @param OutputPage $outputPage
+ * @param ParserOutput $parserOutput
+ */
+ public static function parserOutput( $outputPage, $parserOutput ) {
+ if ( self::shouldForceHeaders() ) {
+ // Skip, we've already set the headers unconditionally
+ return;
+ }
+ if ( !empty( $parserOutput->mCategoryTreeTag ) ) {
+ CategoryTree::setHeaders( $outputPage );
+ }
+ }
+
+ /**
+ * BeforePageDisplay and BeforePageDisplayMobile hooks.
+ * These hooks are used when $wgCategoryTreeForceHeaders is set.
+ * Otherwise similar to CategoryTreeHooks::parserOutput.
+ * @param OutputPage $out
+ */
+ public static function addHeaders( OutputPage $out ) {
+ if ( !self::shouldForceHeaders() ) {
+ return;
+ }
+ CategoryTree::setHeaders( $out );
+ }
+
+ /**
+ * ArticleFromTitle hook, override category page handling
+ *
+ * @param Title $title
+ * @param Article &$article
+ * @return bool
+ */
+ public static function articleFromTitle( $title, &$article ) {
+ if ( $title->getNamespace() == NS_CATEGORY ) {
+ $article = new CategoryTreeCategoryPage( $title );
+ }
+ return true;
+ }
+
+ /**
+ * OutputPageMakeCategoryLinks hook, override category links
+ * @param OutputPage &$out
+ * @param array $categories
+ * @param array &$links
+ * @return bool
+ */
+ public static function outputPageMakeCategoryLinks( &$out, $categories, &$links ) {
+ global $wgCategoryTreePageCategoryOptions, $wgCategoryTreeHijackPageCategories;
+
+ if ( !$wgCategoryTreeHijackPageCategories ) {
+ // Not enabled, don't do anything
+ return true;
+ }
+
+ foreach ( $categories as $category => $type ) {
+ $links[$type][] = self::parserHook( $category, $wgCategoryTreePageCategoryOptions, null, true );
+ }
+
+ return false;
+ }
+
+ /**
+ * @param Skin $skin
+ * @param array &$links
+ * @param string &$result
+ * @return bool
+ */
+ public static function skinJoinCategoryLinks( $skin, &$links, &$result ) {
+ global $wgCategoryTreeHijackPageCategories;
+ if ( !$wgCategoryTreeHijackPageCategories ) {
+ // Not enabled, don't do anything.
+ return true;
+ }
+ $embed = '<div class="CategoryTreeCategoryBarItem">';
+ $pop = '</div>';
+ $sep = ' ';
+
+ $result = $embed . implode( "{$pop} {$sep} {$embed}", $links ) . $pop;
+
+ return false;
+ }
+
+ /**
+ * @param array &$vars
+ * @return bool
+ */
+ public static function getConfigVars( &$vars ) {
+ global $wgCategoryTreeCategoryPageOptions;
+
+ // Look this is pretty bad but Category tree is just whacky, it needs to be rewritten
+ $ct = new CategoryTree( $wgCategoryTreeCategoryPageOptions );
+ $vars['wgCategoryTreePageCategoryOptions'] = $ct->getOptionsAsJsStructure();
+ return true;
+ }
+
+ /**
+ * Hook handler for the SpecialTrackingCategories::preprocess hook
+ * @param SpecialPage $specialPage SpecialTrackingCategories object
+ * @param array $trackingCategories [ 'msg' => Title, 'cats' => Title[] ]
+ */
+ public static function onSpecialTrackingCategoriesPreprocess(
+ $specialPage, $trackingCategories
+ ) {
+ $categoryDbKeys = [];
+ foreach ( $trackingCategories as $catMsg => $data ) {
+ foreach ( $data['cats'] as $catTitle ) {
+ $categoryDbKeys[] = $catTitle->getDbKey();
+ }
+ }
+ $categories = [];
+ if ( $categoryDbKeys ) {
+ $dbr = wfGetDB( DB_REPLICA );
+ $res = $dbr->select(
+ 'category',
+ [ 'cat_id', 'cat_title', 'cat_pages', 'cat_subcats', 'cat_files' ],
+ [ 'cat_title' => array_unique( $categoryDbKeys ) ],
+ __METHOD__
+ );
+ foreach ( $res as $row ) {
+ $categories[$row->cat_title] = Category::newFromRow( $row );
+ }
+ }
+ $specialPage->categoryTreeCategories = $categories;
+ }
+
+ /**
+ * Hook handler for the SpecialTrackingCategories::generateCatLink hook
+ * @param SpecialPage $specialPage SpecialTrackingCategories object
+ * @param Title $catTitle Title object of the linked category
+ * @param string &$html Result html
+ */
+ public static function onSpecialTrackingCategoriesGenerateCatLink(
+ $specialPage, $catTitle, &$html
+ ) {
+ if ( !isset( $specialPage->categoryTreeCategories ) ) {
+ return;
+ }
+
+ $cat = null;
+ if ( isset( $specialPage->categoryTreeCategories[$catTitle->getDbKey()] ) ) {
+ $cat = $specialPage->categoryTreeCategories[$catTitle->getDbKey()];
+ }
+
+ $html .= CategoryTree::createCountString( $specialPage->getContext(), $cat, 0 );
+ }
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTreeMode.php b/www/wiki/extensions/CategoryTree/includes/CategoryTreeMode.php
new file mode 100644
index 00000000..48ff6133
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTreeMode.php
@@ -0,0 +1,38 @@
+<?php
+/**
+ * © 2006 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+/**
+ * Constants for use with the mode, defining what should be shown in the tree.
+ */
+class CategoryTreeMode {
+
+ const CATEGORIES = 0;
+
+ const PAGES = 10;
+
+ const ALL = 20;
+
+ const PARENTS = 100;
+
+}
diff --git a/www/wiki/extensions/CategoryTree/includes/CategoryTreePage.php b/www/wiki/extensions/CategoryTree/includes/CategoryTreePage.php
new file mode 100644
index 00000000..202e84e8
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/includes/CategoryTreePage.php
@@ -0,0 +1,214 @@
+<?php
+/**
+ * © 2006 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+/**
+ * Special page for the CategoryTree extension, an AJAX based gadget
+ * to display the category structure of a wiki
+ */
+class CategoryTreePage extends SpecialPage {
+ public $target = '';
+
+ /**
+ * @var CategoryTree
+ */
+ public $tree = null;
+
+ public function __construct() {
+ parent::__construct( 'CategoryTree' );
+ }
+
+ /**
+ * @param string $name
+ * @return mixed
+ */
+ private function getOption( $name ) {
+ global $wgCategoryTreeDefaultOptions;
+
+ if ( $this->tree ) {
+ return $this->tree->getOption( $name );
+ } else {
+ return $wgCategoryTreeDefaultOptions[$name];
+ }
+ }
+
+ /**
+ * Main execution function
+ * @param string|null $par Parameters passed to the page
+ */
+ public function execute( $par ) {
+ global $wgCategoryTreeDefaultOptions, $wgCategoryTreeSpecialPageOptions;
+
+ $this->setHeaders();
+ $request = $this->getRequest();
+ if ( $par ) {
+ $this->target = $par;
+ } else {
+ $this->target = $request->getVal( 'target' );
+ if ( $this->target === null ) {
+ $rootcategory = $this->msg( 'rootcategory' );
+ if ( $rootcategory->exists() ) {
+ $this->target = $rootcategory->text();
+ }
+ }
+ }
+
+ $this->target = trim( $this->target );
+
+ $options = [];
+
+ # grab all known options from the request. Normalization is done by the CategoryTree class
+ foreach ( $wgCategoryTreeDefaultOptions as $option => $default ) {
+ if ( isset( $wgCategoryTreeSpecialPageOptions[$option] ) ) {
+ $default = $wgCategoryTreeSpecialPageOptions[$option];
+ }
+
+ $options[$option] = $request->getVal( $option, $default );
+ }
+
+ $this->tree = new CategoryTree( $options );
+
+ $output = $this->getOutput();
+ $output->addWikiMsg( 'categorytree-header' );
+
+ $this->executeInputForm();
+
+ if ( $this->target !== '' && $this->target !== null ) {
+ if ( !CategoryTreeHooks::shouldForceHeaders() ) {
+ CategoryTree::setHeaders( $output );
+ }
+
+ $title = CategoryTree::makeTitle( $this->target );
+
+ if ( $title && $title->getArticleID() ) {
+ $output->addHTML( Xml::openElement( 'div', [ 'class' => 'CategoryTreeParents' ] ) );
+ $output->addHTML( $this->msg( 'categorytree-parents' )->parse() );
+ $output->addHTML( $this->msg( 'colon-separator' )->escaped() );
+
+ $parents = $this->tree->renderParents( $title );
+
+ if ( $parents == '' ) {
+ $output->addHTML( $this->msg( 'categorytree-no-parent-categories' )->parse() );
+ } else {
+ $output->addHTML( $parents );
+ }
+
+ $output->addHTML( Xml::closeElement( 'div' ) );
+
+ $output->addHTML( Xml::openElement( 'div', [ 'class' => 'CategoryTreeResult' ] ) );
+ $output->addHTML( $this->tree->renderNode( $title, 1 ) );
+ $output->addHTML( Xml::closeElement( 'div' ) );
+ } else {
+ $output->addHTML( Xml::openElement( 'div', [ 'class' => 'CategoryTreeNotice' ] ) );
+ $output->addHTML( $this->msg( 'categorytree-not-found', $this->target )->parse() );
+ $output->addHTML( Xml::closeElement( 'div' ) );
+ }
+ }
+ }
+
+ /**
+ * Input form for entering a category
+ */
+ private function executeInputForm() {
+ $namespaces = $this->getRequest()->getVal( 'namespaces', '' );
+ // mode may be overriden by namespaces option
+ $mode = ( $namespaces == '' ? $this->getOption( 'mode' ) : CategoryTreeMode::ALL );
+ if ( $mode == CategoryTreeMode::CATEGORIES ) {
+ $modeDefault = 'categories';
+ } elseif ( $mode == CategoryTreeMode::PAGES ) {
+ $modeDefault = 'pages';
+ } else {
+ $modeDefault = 'all';
+ }
+
+ $formDescriptor = [
+ 'category' => [
+ 'type' => 'title',
+ 'name' => 'target',
+ 'label-message' => 'categorytree-category',
+ 'namespace' => NS_CATEGORY,
+ ],
+
+ 'mode' => [
+ 'type' => 'select',
+ 'name' => 'mode',
+ 'label-message' => 'categorytree-mode-label',
+ 'options-messages' => [
+ 'categorytree-mode-categories' => 'categories',
+ 'categorytree-mode-pages' => 'pages',
+ 'categorytree-mode-all' => 'all',
+ ],
+ 'default' => $modeDefault,
+ 'nodata' => true,
+ ],
+
+ 'namespace' => [
+ 'type' => 'namespaceselect',
+ 'name' => 'namespaces',
+ 'label-message' => 'namespace',
+ 'all' => '',
+ ],
+ ];
+
+ HTMLForm::factory( 'ooui', $formDescriptor, $this->getContext() )
+ ->addHiddenFields( [ 'title' => $this->getPageTitle()->getPrefixedDbKey() ] )
+ ->setWrapperLegendMsg( 'categorytree-legend' )
+ ->setSubmitTextMsg( 'categorytree-go' )
+ ->setMethod( 'get' )
+ ->prepareForm()
+ ->displayForm( false );
+ }
+
+ /**
+ * Return an array of subpages beginning with $search that this special page will accept.
+ *
+ * @param string $search Prefix to search for
+ * @param int $limit Maximum number of results to return (usually 10)
+ * @param int $offset Number of results to skip (usually 0)
+ * @return string[] Matching subpages
+ */
+ public function prefixSearchSubpages( $search, $limit, $offset ) {
+ $title = Title::newFromText( $search, NS_CATEGORY );
+ if ( $title && $title->getNamespace() !== NS_CATEGORY ) {
+ // Someone searching for something like "Wikipedia:Foo"
+ $title = Title::makeTitleSafe( NS_CATEGORY, $search );
+ }
+ if ( !$title ) {
+ // No prefix suggestion outside of category namespace
+ return [];
+ }
+ // Autocomplete subpage the same as a normal search, but just for categories
+ $prefixSearcher = new TitlePrefixSearch;
+ $result = $prefixSearcher->search( $title->getPrefixedText(), $limit, [ NS_CATEGORY ], $offset );
+
+ return array_map( function ( Title $t ) {
+ // Remove namespace in search suggestion
+ return $t->getText();
+ }, $result );
+ }
+
+ protected function getGroupName() {
+ return 'pages';
+ }
+
+}
diff --git a/www/wiki/extensions/CategoryTree/modules/ext.categoryTree.css b/www/wiki/extensions/CategoryTree/modules/ext.categoryTree.css
new file mode 100644
index 00000000..418a0754
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/modules/ext.categoryTree.css
@@ -0,0 +1,118 @@
+/**
+ * Stylesheet for the CategoryTree extension.
+ *
+ * © 2006 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+.client-js #mw-subcategories ul {
+ list-style: none none;
+ margin-left: 0.25em;
+}
+
+#mw-panel div.portal div.body .CategoryTreeTag {
+ margin: 0;
+ font-size: 0.75em;
+ line-height: 1.125em;
+}
+
+#mw-panel div.portal div.body .CategoryTreeItem {
+ padding: 0.25em 0;
+}
+
+.CategoryTreeChildren {
+ margin-left: 1.25em;
+}
+
+.CategoryTreeBullet,
+.CategoryTreeEmptyBullet {
+ cursor: default;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+ user-select: none;
+}
+
+.CategoryTreeToggleHandlerAttached {
+ cursor: pointer;
+}
+
+.CategoryTreeEmptyBullet {
+ color: #c0c0c0;
+}
+
+.CategoryTreeBullet a,
+.CategoryTreeBullet a:link,
+.CategoryTreeBullet a:active,
+.CategoryTreeBullet a:visited {
+ text-decoration: none;
+ color: inherit;
+ speak: none;
+}
+
+/* Hide toggle buttons for clients without JavaScript */
+.client-nojs .CategoryTreeBullet,
+.client-nojs .CategoryTreeEmptyBullet {
+ display: none;
+}
+
+.CategoryTreeToggle {
+ color: #0645ad;
+}
+
+.CategoryTreeLabelPage {
+ font-style: italic;
+}
+
+.CategoryTreeParents {
+ margin-top: 1.5ex;
+ font-style: italic;
+}
+
+.CategoryTreeResult {
+ margin-top: 1.5ex;
+}
+
+.CategoryTreeTag {
+ margin-top: 0.5ex;
+ margin-bottom: 0.5ex;
+}
+
+.CategoryTreeNotice {
+ font-style: italic;
+}
+
+.CategoryTreeCategoryBarItem {
+ /* yes, specify display twice! quirk for FF2 */
+ display: -moz-inline-box;
+ display: inline-block;
+ /* why is the -0.5ex needed? */
+ margin: -0.5ex 0 0 1ex;
+ padding: 0;
+ vertical-align: top;
+ /* IE6-7 Hack for display: inline-block */
+ zoom: 1;
+ *display: inline; /* stylelint-disable-line declaration-block-no-duplicate-properties */
+}
+
+.CategoryTreeSection {
+ direction: ltr;
+}
diff --git a/www/wiki/extensions/CategoryTree/modules/ext.categoryTree.js b/www/wiki/extensions/CategoryTree/modules/ext.categoryTree.js
new file mode 100644
index 00000000..9690a0a0
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/modules/ext.categoryTree.js
@@ -0,0 +1,205 @@
+/**
+ * JavaScript for the CategoryTree extension.
+ *
+ * © 2006 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ */
+
+( function ( $, mw ) {
+ var loadChildren;
+
+ /**
+ * Expands a given node (loading it's children if not loaded)
+ *
+ * @param {jQuery} $link
+ */
+ function expandNode( $link ) {
+ // Show the children node
+ var $children = $link.parents( '.CategoryTreeItem' )
+ .siblings( '.CategoryTreeChildren' );
+ $children.show();
+
+ $link
+ .text( mw.msg( 'categorytree-collapse-bullet' ) )
+ .attr( 'title', mw.msg( 'categorytree-collapse' ) )
+ .data( 'ct-state', 'expanded' );
+
+ if ( !$link.data( 'ct-loaded' ) ) {
+ loadChildren( $link, $children );
+ }
+ }
+
+ /**
+ * Collapses a node
+ *
+ * @param {jQuery} $link
+ */
+ function collapseNode( $link ) {
+ // Hide the children node
+ $link.parents( '.CategoryTreeItem' )
+ .siblings( '.CategoryTreeChildren' ).hide();
+
+ $link
+ .text( mw.msg( 'categorytree-expand-bullet' ) )
+ .attr( 'title', mw.msg( 'categorytree-expand' ) )
+ .data( 'ct-state', 'collapsed' );
+ }
+
+ /**
+ * Handles clicks on the expand buttons, and calls the appropriate function
+ *
+ * @context {Element} CategoryTreeToggle
+ */
+ function handleNode() {
+ var $link = $( this );
+ if ( $link.data( 'ct-state' ) === 'collapsed' ) {
+ expandNode( $link );
+ } else {
+ collapseNode( $link );
+ }
+ }
+
+ /**
+ * Attach click handler to buttons
+ *
+ * @param {jQuery} $content
+ */
+ function attachHandler( $content ) {
+ $content.find( '.CategoryTreeToggle' )
+ .click( handleNode )
+ .attr( 'title', function () {
+ return mw.msg(
+ $( this ).data( 'ct-state' ) === 'collapsed' ?
+ 'categorytree-expand' :
+ 'categorytree-collapse'
+ );
+ } )
+ .addClass( 'CategoryTreeToggleHandlerAttached' );
+ }
+
+ /**
+ * Loads children for a node via an HTTP call
+ *
+ * @param {jQuery} $link
+ * @param {jQuery} $children
+ */
+ loadChildren = function ( $link, $children ) {
+ var $linkParentCTTag, ctTitle, ctMode, ctOptions;
+
+ /**
+ * Error callback
+ */
+ function error() {
+ var $retryLink;
+
+ $retryLink = $( '<a>' )
+ .text( mw.msg( 'categorytree-retry' ) )
+ .attr( {
+ role: 'button',
+ tabindex: 0
+ } )
+ .on( 'click keypress', function ( e ) {
+ if (
+ e.type === 'click' ||
+ e.type === 'keypress' && e.which === 13
+ ) {
+ loadChildren( $link, $children );
+ }
+ } );
+
+ $children
+ .text( mw.msg( 'categorytree-error' ) + ' ' )
+ .append( $retryLink );
+ }
+
+ $link.data( 'ct-loaded', true );
+
+ $children.append(
+ $( '<i class="CategoryTreeNotice"></i>' )
+ .text( mw.msg( 'categorytree-loading' ) )
+ );
+
+ $linkParentCTTag = $link.parents( '.CategoryTreeTag' );
+
+ // Element may not have a .CategoryTreeTag parent, fallback to defauls
+ // Probably a CategoryPage (@todo: based on what?)
+ ctTitle = $link.data( 'ct-title' );
+ ctMode = $linkParentCTTag.data( 'ct-mode' );
+ ctMode = typeof ctMode === 'number' ? ctMode : undefined;
+ ctOptions = $linkParentCTTag.attr( 'data-ct-options' );
+ if ( !ctOptions ) {
+ ctOptions = mw.config.get( 'wgCategoryTreePageCategoryOptions' );
+ }
+
+ // Mode and options have defaults or fallbacks, title does not.
+ // Don't make a request if there is no title.
+ if ( typeof ctTitle !== 'string' ) {
+ error();
+ return;
+ }
+
+ new mw.Api().get( {
+ action: 'categorytree',
+ category: ctTitle,
+ options: ctOptions,
+ uselang: mw.config.get( 'wgUserLanguage' ),
+ formatversion: 2
+ } ).done( function ( data ) {
+ data = data.categorytree.html;
+
+ if ( data === '' ) {
+ switch ( ctMode ) {
+ // CategoryTreeMode::CATEGORIES = 0
+ case 0:
+ data = mw.msg( 'categorytree-no-subcategories' );
+ break;
+ // CategoryTreeMode::PAGES = 10
+ case 10:
+ data = mw.msg( 'categorytree-no-pages' );
+ break;
+ // CategoryTreeMode::PARENTS = 100
+ case 100:
+ data = mw.msg( 'categorytree-no-parent-categories' );
+ break;
+ // CategoryTreeMode::ALL = 20
+ default:
+ data = mw.msg( 'categorytree-nothing-found' );
+ }
+
+ data = $( '<i class="CategoryTreeNotice"></i>' ).text( data );
+ }
+
+ $children.html( data );
+ attachHandler( $children );
+
+ } )
+ .fail( error );
+ };
+
+ // Register click events
+ mw.hook( 'wikipage.content' ).add( attachHandler );
+
+ $( function () {
+ // Attach click handler for sidebar
+ attachHandler( $( '#p-categorytree-portlet' ) );
+ } );
+
+}( jQuery, mediaWiki ) );
diff --git a/www/wiki/extensions/CategoryTree/tests/phan/config.php b/www/wiki/extensions/CategoryTree/tests/phan/config.php
new file mode 100644
index 00000000..5559f8d9
--- /dev/null
+++ b/www/wiki/extensions/CategoryTree/tests/phan/config.php
@@ -0,0 +1,9 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+// SpecialPage->categoryTreeCategories
+$cfg['suppress_issue_types'][] = 'PhanUndeclaredProperty';
+// TitlePrefixSearch
+$cfg['suppress_issue_types'][] = 'PhanDeprecatedClass';
+
+return $cfg;
diff --git a/www/wiki/extensions/Cite/Gruntfile.js b/www/wiki/extensions/Cite/Gruntfile.js
index 38d3bfb1..4082717e 100644
--- a/www/wiki/extensions/Cite/Gruntfile.js
+++ b/www/wiki/extensions/Cite/Gruntfile.js
@@ -13,6 +13,8 @@ module.exports = function ( grunt ) {
grunt.loadNpmTasks( 'grunt-eslint' );
grunt.loadNpmTasks( 'grunt-jsonlint' );
grunt.loadNpmTasks( 'grunt-stylelint' );
+ grunt.loadNpmTasks( 'grunt-svgmin' );
+
grunt.initConfig( {
eslint: {
all: [
@@ -38,9 +40,44 @@ module.exports = function ( grunt ) {
'!node_modules/**',
'!vendor/**'
]
+ },
+ // SVG Optimization
+ svgmin: {
+ options: {
+ js2svg: {
+ pretty: true,
+ multipass: true
+ },
+ plugins: [ {
+ cleanupIDs: false
+ }, {
+ removeDesc: false
+ }, {
+ removeRasterImages: true
+ }, {
+ removeTitle: false
+ }, {
+ removeViewBox: false
+ }, {
+ removeXMLProcInst: false
+ }, {
+ sortAttrs: true
+ } ]
+ },
+ all: {
+ files: [ {
+ expand: true,
+ cwd: 'modules/ve-cite/icons',
+ src: [
+ '**/*.svg'
+ ],
+ dest: 'modules/ve-cite/icons/',
+ ext: '.svg'
+ } ]
+ }
}
} );
- grunt.registerTask( 'test', [ 'eslint', 'stylelint', 'jsonlint', 'banana' ] );
+ grunt.registerTask( 'test', [ 'eslint', 'stylelint', 'jsonlint', 'banana', 'svgmin' ] );
grunt.registerTask( 'default', 'test' );
};
diff --git a/www/wiki/extensions/Cite/MIT-LICENSE.txt b/www/wiki/extensions/Cite/MIT-LICENSE.txt
index a3be0d75..ece90ddb 100644
--- a/www/wiki/extensions/Cite/MIT-LICENSE.txt
+++ b/www/wiki/extensions/Cite/MIT-LICENSE.txt
@@ -1,5 +1,5 @@
-Copyright (c) 2011-2017 Cite VisualEditor Team and others under the terms
-of The MIT License (MIT), as follows:
+Copyright (c) 2011-2018 VisualEditor Team's Cite sub-team and others
+under the terms of The MIT License (MIT), as follows:
This software consists of voluntary contributions made by many
individuals (AUTHORS.txt) For exact contribution history, see the
diff --git a/www/wiki/extensions/Cite/composer.json b/www/wiki/extensions/Cite/composer.json
index 9dc2960d..fea33bfd 100644
--- a/www/wiki/extensions/Cite/composer.json
+++ b/www/wiki/extensions/Cite/composer.json
@@ -1,16 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
],
"fix": [
- "phpcbf"
+ "phpcbf",
+ "minus-x fix ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.1.0"
}
}
diff --git a/www/wiki/extensions/Cite/extension.json b/www/wiki/extensions/Cite/extension.json
index 28a9229e..092f9dc0 100644
--- a/www/wiki/extensions/Cite/extension.json
+++ b/www/wiki/extensions/Cite/extension.json
@@ -12,8 +12,11 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:Cite",
"descriptionmsg": "cite-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "parserhook",
+ "requires": {
+ "MediaWiki": ">= 1.30.0"
+ },
"MessagesDirs": {
"cite": "i18n",
"ve-cite": "modules/ve-cite/i18n"
@@ -58,7 +61,6 @@
"skinStyles": {
"minerva": "ext.cite.styles.minerva.less"
},
- "position": "bottom",
"targets": [
"desktop",
"mobile"
@@ -70,13 +72,11 @@
"messages": [
"cite_references_link_accessibility_label",
"cite_references_link_many_accessibility_label"
- ],
- "position": "bottom"
+ ]
},
"ext.cite.style": {
"class": "CiteCSSFileModule",
"styles": "ext.cite.style.css",
- "position": "top",
"targets": [
"desktop",
"mobile"
@@ -94,7 +94,6 @@
"cite": "GlobalVarConfig::newInstance"
},
"config": {
- "CiteCacheReferences": false,
"CiteStoreReferencesData": false,
"CiteCacheReferencesDataOnParse": false,
"CiteVisualEditorOtherGroup": false,
diff --git a/www/wiki/extensions/Cite/i18n/ais.json b/www/wiki/extensions/Cite/i18n/ais.json
index cc148e01..389099eb 100644
--- a/www/wiki/extensions/Cite/i18n/ais.json
+++ b/www/wiki/extensions/Cite/i18n/ais.json
@@ -6,7 +6,24 @@
"Tokoabibi"
]
},
+ "cite-desc": "midama <nowiki><ref[ name=id]></nowiki> atu <nowiki><references/></nowiki> aazihen-paya, kapah pabacuen miazih tu tatenga’ay nasulitan",
"cite_error": "nicaliwan mungangaw: $1",
+ "cite_error_ref_numeric_key": "la’cus <code>&lt;ref&gt;</code> aazihen-paya, kya susin amama pisaungay asip-bacu, pisaungay taneng misapuelac lacul a satangahan",
+ "cite_error_ref_no_key": "<code>&lt;ref&gt;</code> aazihen-paya angangan a kese mungangaw saca kalungangan caay kalucek.",
+ "cite_error_ref_too_many_keys": "la’cusay <code>&lt;ref&gt;</code> aazihen-paya, la’cusay name susin sulyang, hakay kalungangan tadatanayu’.",
+ "cite_error_ref_no_input": "la’cusay <code>&lt;ref&gt;</code> aazihen-paya, inayi’ ku name susin sa kanca izaway aazihen-paya lacul",
+ "cite_error_references_no_backlink_label": "pakuniza misanga’ mabelih masasiket aazihen-paya tatebanan nu nisulitan mahmintu.\ni <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> satetek yadahay a aazihen-paya tatebanan nu nisulitan.",
+ "cite_error_no_link_label_group": "luyaluy \"$1\" a pakuniza misanga’ masasiket aazihen-paya tatebanan nu nisulitan mahemintu.\npisatetek i <nowiki>[[MediaWiki:$2]]</nowiki> yadahay a aazihen-paya tatebanan nu nisulitan.",
+ "cite_error_references_no_text": "la’cusay <code>&lt;ref&gt;</code> aazihen-paya,\ncaay satetek kalungangan ku <code>$1</code> a miazih tu tatenga’ay nasulitan lacul sulit.",
+ "cite_error_included_ref": "caay kataneng <code>&lt;ref&gt;</code>aazihen-paya a pahezek aazihen-paya <code>&lt;/ref&gt;</code>",
+ "cite_error_group_refs_without_references": "pisaungay luyaluy kalungangan \"$1\" a <code>&lt;ref&gt;</code> aazihen-paya mamueneng tu, caykatepa patatapalen a <code>&lt;references group=\"$1\"/&gt;</code> aazihen-paya,saca caay kataneng <code>&lt;/ref&gt;</code> pahezek aazihen-paya.",
+ "cite_error_references_group_mismatch": "i <code>&lt;references&gt;</code> a <code>&lt;ref&gt;</code> aazihen-paya group susin sasula’cus \"$1\"",
+ "cite_error_references_missing_group": "ihekal nu <code>&lt;ref&gt;</code> satetekay a<code>&lt;references&gt;</code> aazihen-paya izaw ku setin group susin ku \"$1\", uyzasa iayaway a sulit caay misaungay.",
+ "cite_error_references_missing_key": "i <code>&lt;references&gt;</code> satetekay a <code>&lt;ref&gt;</code> aazihen-paya misetin name susin ku \"$1\", uyzasa iayaway a sulit caay henay misaungay.",
+ "cite_error_references_no_key": "<code>&lt;references&gt;</code> satetekay <code>&lt;ref&gt;</code> inayi’ misetin name susin",
+ "cite_error_empty_references_define": "<code>&lt;references&gt;</code> misatetekay a <code>&lt;ref&gt;</code> a name susin \"$1\" inayi’ amahicahica a lacul",
+ "cite-tracking-category-cite-error": "miazih tu tatenga’ay a saangangan mungangaw a kasabelih",
+ "cite-tracking-category-cite-error-desc": "ilabu tina kakuniza a kasabelih miazih tu tatenga’ay saangangan saungay izaw ku mungangaw.",
"cite_references_link_accessibility_label": "palimad i",
"cite_references_link_many_accessibility_label": "milimad ta:",
"cite_section_preview_references": "pataayaway miazih miazih tu tatenga’ay nasulitan",
diff --git a/www/wiki/extensions/Cite/i18n/an.json b/www/wiki/extensions/Cite/i18n/an.json
index c800c5fc..653b155c 100644
--- a/www/wiki/extensions/Cite/i18n/an.json
+++ b/www/wiki/extensions/Cite/i18n/an.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Etiqueta <code>&lt;ref&gt;</code> incorreuta; nombres de parametros incorreutos.",
"cite_error_ref_no_input": "Etiqueta <code>&lt;ref&gt;</code> incorreuta; as referencias sin nombre no han de tener conteniu",
"cite_error_references_invalid_parameters": "Etiqueta <code>&lt;references&gt;</code> incorreuta; no se premiten parametros, faiga servir <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Etiqueta <code>&lt;references&gt;</code> no conforme;\nnomás se premite o parametro \"group\".\nFaiga servir <code>&lt;references /&gt;</code>, u <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Ya no quedan etiquetas backlink presonalizatas, defina más en o mensache <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "S'han acorau as etiquetas de vinclos personalizaus ta o grupo \"$1\".\nDefina-ne mas en o mensache <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Etiqueta <code>&lt;ref&gt;</code> incorreuta; no ha escrito garra testo t'as referencias nombratas <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/arz.json b/www/wiki/extensions/Cite/i18n/arz.json
index 20cbdedf..34cfa640 100644
--- a/www/wiki/extensions/Cite/i18n/arz.json
+++ b/www/wiki/extensions/Cite/i18n/arz.json
@@ -13,7 +13,6 @@
"cite_error_ref_too_many_keys": "التاج <code>&lt;ref&gt;</code> مش صحيح؛\nأسامى مش صحيحة، يعنى مثلا: كتير قوي",
"cite_error_ref_no_input": "تاج <code>&lt;ref&gt;</code> مش صحيح؛\nالمراجع اللى من غير اسم لازم يكون ليها محتوى",
"cite_error_references_invalid_parameters": "مش صحيح <code>&lt;references&gt;</code> تاج;\nمافيش محددات مسموح بيها.\nاستخدم <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "مش صحيح <code>&lt;references&gt;</code> تاج;\nمحدد \"group\" مسموح بيه بس.\nاستخدم <code>&lt;references /&gt;</code>, or <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "علامات الوصلات الراجعة المخصصة خلصت.\nعرف اكتر فى رسالة <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_references_no_text": "مش صحيح <code>&lt;ref&gt;</code> تاج;\nمافيش نص متوافر فى المراجع اللى اسمها<code>$1</code>",
"cite_error_included_ref": "إغلاق <code>&lt;/ref&gt;</code> مفقود لوسم <code>&lt;ref&gt;</code>",
diff --git a/www/wiki/extensions/Cite/i18n/as.json b/www/wiki/extensions/Cite/i18n/as.json
index bbb7f719..fe4fc366 100644
--- a/www/wiki/extensions/Cite/i18n/as.json
+++ b/www/wiki/extensions/Cite/i18n/as.json
@@ -14,7 +14,6 @@
"cite_error_ref_too_many_keys": "অবৈধ <code>&lt;ref&gt;</code> টেগ;\nঅবৈধ নাম, যেনে- বহুসংখ্যক",
"cite_error_ref_no_input": "অবৈধ <code>&lt;ref&gt;</code> টেগ;\nনামবিহীন refসমূহৰ অৱশ্যেই সমল থাকিব লাগিব।",
"cite_error_references_invalid_parameters": "অবৈধ <code>&lt;references&gt;</code> টেগ;\nকোনো পেৰামিটাৰ অনুমোদন কৰা হোৱা নাই।\n<code>&lt;references /&gt;</code> ব্যৱহাৰ কৰক।",
- "cite_error_references_invalid_parameters_group": "অবৈধ <code>&lt;references&gt;</code> টেগ;\nকেৱল পেৰামিটাৰ \"গোট\"ক অনুমতি দিয়া হৈছে।\n<code>&lt;references /&gt;</code>, বা <code>&lt;references group=\"...\" /&gt;</code> ব্যৱহাৰ কৰক",
"cite_error_references_no_backlink_label": "কাষ্টম বেকলিংক লেবেল শেষ হৈছে।\n<nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> বাৰ্তাত আৰু সংজ্ঞা দিয়ক।",
"cite_error_no_link_label_group": "\"$1\" গোটৰ বাবে কাষ্টম লিংক লেবেল উকলিছে।\n<nowiki>[[MediaWiki:$2]]</nowiki> বাৰ্তাত আৰু সংজ্ঞা দিয়ক।",
"cite_error_references_no_text": "অবৈধ <code>&lt;ref&gt;</code> টেগ;\n<code>$1</code> নামৰ refৰ বাবে কোনো পাঠ্য প্ৰদান কৰা হোৱা নাই",
@@ -25,6 +24,9 @@
"cite_error_references_missing_key": "<code>&lt;references&gt;</code>ত দিয়া \"$1\" নামৰ <code>&lt;ref&gt;</code> টেগ্‌টো পূৰ্বৰ পাঠ্যত ব্যৱহাৰ কৰা নাই।",
"cite_error_references_no_key": "<code>&lt;references&gt;</code>ত দিয়া <code>&lt;ref&gt;</code> টেগৰ কোনো নাম আবণ্টন নাই।",
"cite_error_empty_references_define": "<code>&lt;references&gt;</code>ত দিয়া \"$1\" নামৰ <code>&lt;ref&gt;</code> টেগৰ কোনো সমল নাই।",
+ "cite-tracking-category-cite-error": "তথ্যসূত্ৰৰ ত্ৰুটি থকা পৃষ্ঠা",
"cite_references_link_accessibility_label": "যাওক",
- "cite_references_link_many_accessibility_label": "ইয়ালৈ যাওক:"
+ "cite_references_link_many_accessibility_label": "ইয়ালৈ যাওক:",
+ "cite_section_preview_references": "তথ্যসূত্ৰৰ প্ৰাক্‌দৰ্শন",
+ "cite_warning": "তথ্যসূত্ৰ সতৰ্কবাণী: $1"
}
diff --git a/www/wiki/extensions/Cite/i18n/bcc.json b/www/wiki/extensions/Cite/i18n/bcc.json
index bdd35ab0..6af0cd9c 100644
--- a/www/wiki/extensions/Cite/i18n/bcc.json
+++ b/www/wiki/extensions/Cite/i18n/bcc.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "نامعتبر<code>&lt;ref&gt;</code>تگ;\nنامعتبر نامان, په داب بازین",
"cite_error_ref_no_input": "نامعتبر <code>&lt;ref&gt;</code> تگ;\nمراجع بی نام بایدن محتوا داشته بنت",
"cite_error_references_invalid_parameters": "نامعتبر <code>&lt;references&gt;</code>تگ;\nهچ پارامتری مجاز نهنت.\nاستفاده کن چه <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "نامعتبر <code>&lt;references&gt;</code>تگ;\nپارامتر \"گروه\" فقط مجازنت.\nاستفاده کن چه <code>&lt;references /&gt;</code>, یا <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "هلگ برجسپان لینک عقب رسمی.\nگیشتر تعریف کن ته <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> کوله",
"cite_error_references_no_text": "نامعتبر<code>&lt;ref&gt;</code>تگ;\nپه نام ارجاع هچ متنی دهگ نه بیته <code>$1</code>",
"cite_reference_link_prefix": "هل_مرج-",
diff --git a/www/wiki/extensions/Cite/i18n/bcl.json b/www/wiki/extensions/Cite/i18n/bcl.json
index fecc7963..ed2f0011 100644
--- a/www/wiki/extensions/Cite/i18n/bcl.json
+++ b/www/wiki/extensions/Cite/i18n/bcl.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Imbalido an <code>&lt;ref&gt;</code> tatak; imbalidong mga pangaran, e.g. grabe kadakol",
"cite_error_ref_no_input": "Imbalido an <code>&lt;ref&gt;</code> tatak; an mga toltolan na mayong pangaran dapat magkaigwa nin kalamnan",
"cite_error_references_invalid_parameters": "Imbalido an <code>&lt;references&gt;</code> tatak; mayong mga parametro an pinagtutugot. Maggamit nin <code>&lt;mga toltolan /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Imbalido an <code>&lt;references&gt;</code> tatak; an parametrong \"grupo\" sana an pinagtutugot. Maggamit nin <code>&lt;mga toltolan /&gt;</code>, o <code>&lt;mga toltolang grupo=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Naubusan nin pankostumbreng sugpon-panlikod na kamarkahan.\nPakahulugan nin dagdag tabi an <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> mensahe.",
"cite_error_no_link_label_group": "Naubusan nin pankostumbreng sugpon nin mga kamarkahan para sa grupo \"$1\".\nPakahulugan nin dagdag tabi an <nowiki>[[MediaWiki:$2]]</nowiki> mensahe.",
"cite_error_references_no_text": "Imbalidong <code>&lt;ref&gt;</code> tatak; mayong teksto na ipinagtao para sa reperensiya na pinagngaranan na <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/bg.json b/www/wiki/extensions/Cite/i18n/bg.json
index d67dae42..e218d1be 100644
--- a/www/wiki/extensions/Cite/i18n/bg.json
+++ b/www/wiki/extensions/Cite/i18n/bg.json
@@ -10,13 +10,13 @@
},
"cite-desc": "Добавя етикетите <nowiki><ref[ name=id]></nowiki> и <nowiki><references/></nowiki>, подходящи за цитиране",
"cite_error": "Грешка при цитиране: $1",
- "cite_error_ref_numeric_key": "'''Грешка в етикет <code>&lt;ref&gt;</code>:''' името не може да бъде число, използва се описателно име",
+ "cite_error_ref_numeric_key": "Грешка в етикет <code>&lt;ref&gt;</code>;\nимето не може да бъде число. Използвайте описателно име",
"cite_error_ref_no_key": "Отварящият таг <code>&lt;ref&gt;</code> е неправилен или съдържа некоректно име.",
- "cite_error_ref_too_many_keys": "'''Грешка в етикет <code>&lt;ref&gt;</code>:''' грешка в името, например повече от едно име на етикета",
- "cite_error_ref_no_input": "'''Грешка в етикет <code>&lt;ref&gt;</code>:''' етикетите без име трябва да имат съдържание",
+ "cite_error_ref_too_many_keys": "Грешка в етикет <code>&lt;ref&gt;</code>;\nневалидно име, например повече от едно име на етикета",
+ "cite_error_ref_no_input": "Грешка в етикет <code>&lt;ref&gt;</code>;\nетикетите без име трябва да имат съдържание",
"cite_error_references_invalid_parameters": "Невалиден параметър на таг <code>&lt;references&gt;</code>.",
"cite_error_references_no_backlink_label": "Изчерпани са специалните етикети за обратна референция.\nОще етикети могат да се дефинират в системното съобщение <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
- "cite_error_references_no_text": "'''Грешка в етикет <code>&lt;ref&gt;</code>:''' не е подаден текст за бележките на име <code>$1</code>",
+ "cite_error_references_no_text": "Грешка в етикет <code>&lt;ref&gt;</code>;\nне е подаден текст за бележките на име <code>$1</code>",
"cite_error_included_ref": "Липсва затварящ етикет <code>&lt;/ref&gt;</code> след отварящия етикет <code>&lt;ref&gt;</code>",
"cite_error_group_refs_without_references": "Тагове <code>&lt;ref&gt;</code> съществуват за група „$1“, но липсва таг <code>&lt;references group=\"$1\"/&gt;</code> или затварящ таг <code>&lt;/ref&gt;</code>",
"cite-tracking-category-cite-error": "Страници с грешка в източник",
diff --git a/www/wiki/extensions/Cite/i18n/ca.json b/www/wiki/extensions/Cite/i18n/ca.json
index 1a377230..d9c8426e 100644
--- a/www/wiki/extensions/Cite/i18n/ca.json
+++ b/www/wiki/extensions/Cite/i18n/ca.json
@@ -15,7 +15,6 @@
"cite_error_ref_too_many_keys": "Etiqueta <code>&lt;ref&gt;</code> no vàlida;\nempreu l'estructura <code>&lt;ref name=\"Nom\"&gt;</code>",
"cite_error_ref_no_input": "Etiqueta <code>&lt;ref&gt;</code> no vàlida; \nles referències sense nom han de tenir contingut",
"cite_error_references_invalid_parameters": "Etiqueta <code>&lt;references&gt;</code> no vàlida; \nno es permeten paràmetres. \nUseu <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Etiqueta <code>&lt;references&gt;</code> no vàlida;\núnicament es permet el paràmetre \"group\".\nUseu <code>&lt;references /&gt;</code>, o <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Hi ha massa etiquetes personalitzades.\nSe'n poden definir més a <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "No hi ha etiquetes vincle personalitzat per al grup \"$1\".\nDefineix més al missatge <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Etiqueta <code>&lt;ref&gt;</code> no vàlida;\nno s'ha proporcionat text per les refs amb l'etiqueta <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/ckb.json b/www/wiki/extensions/Cite/i18n/ckb.json
index 9398cff2..d537e4b7 100644
--- a/www/wiki/extensions/Cite/i18n/ckb.json
+++ b/www/wiki/extensions/Cite/i18n/ckb.json
@@ -2,9 +2,15 @@
"@metadata": {
"authors": [
"Asoxor",
- "Lost Whispers"
+ "Lost Whispers",
+ "Épine"
]
},
"cite_error": "ھەڵەی ژێدەرەکان: $1",
- "cite_error_ref_too_many_keys": "تاگی <code>&lt;ref&gt;</code>ی ڕێگەپێنەدراو؛\nبۆ نموونە، ناوە ھەڵەیەکان یان لە ڕادە بەدەر"
+ "cite_error_ref_too_many_keys": "تاگی <code>&lt;ref&gt;</code>ی ڕێگەپێنەدراو؛\nبۆ نموونە، ناوە ھەڵەیەکان یان لە ڕادە بەدەر",
+ "cite_error_references_duplicate_key": "تاگی <code>&lt;ref&gt;</code>ی ھەڵە؛ ناوی «$1» زیاتر لە یەک جار پێناسە کراوە لەگەڵ ناوەڕۆکی جیاوازدا",
+ "cite_error_references_no_text": "تاگی <code>&lt;ref&gt;</code> ھەڵە؛\nھیچ دەقێک بۆ ژێدەری <code>$1</code> نەدراوە",
+ "cite_error_included_ref": "داخەری ژێدەر <code>&lt;/ref&gt;</code> بۆ تاگی <code>&lt;ref&gt;</code> بەردەست نییە",
+ "cite_error_references_missing_key": "<code>&lt;ref&gt;</code> تاگی «$1» کە لە <code>&lt;ژێدەرەکاندا&gt;</code> پێناسەکراوە لە دەقی وتاردا بەکارنەھاتووە.",
+ "cite_references_link_many_format_backlink_labels": "ئ ا ب پ ت ج چ ح خ د ر ڕ ز ژ س ش ع غ ف ڤ ق ک گ ل ڵ م ن و ۆ وو ھ ە ی ێ ئا ئب ئپ ئت ئج ئچ ئح ئخ ئد ئر ئڕ ئز ئژ ئس ئش ئع ئغ ئف ئڤ ئق ئک ئگ ئل ئڵ ئم ئن ئو ئۆ ئوو ئھ ئە ئی ئێ بئ با بب بپ بت بج بچ بح بخ بد بر بڕ بز بژ بس بش بع بغ بف بڤ بق بک بگ بل بڵ بم بن بو بۆ بوو بھ بە بی بێ پئ پا پب پپ پت پج پچ پح پخ پد پر پڕ پز پژ پس پش پع پغ پف پڤ پق پک پگ پل پڵ پم پن پو پۆ پوو پھ پە پی پێ تئ تا تب تپ تت تج تچ تح تخ تد تر تڕ تز تژ تس تش تع تغ تف تڤ تق تک تگ تل تڵ تم تن تو تۆ توو تھ تە تی تێ جئ جا جب جپ جت جج جچ جح جخ جد جر جڕ جز جژ جس جش جع جغ جف جڤ جق جک جگ جل جڵ جم جن جو جۆ جوو جھ جە جی جێ"
}
diff --git a/www/wiki/extensions/Cite/i18n/cy.json b/www/wiki/extensions/Cite/i18n/cy.json
index 48906fed..a4a7a971 100644
--- a/www/wiki/extensions/Cite/i18n/cy.json
+++ b/www/wiki/extensions/Cite/i18n/cy.json
@@ -14,7 +14,6 @@
"cite_error_ref_no_input": "Tag <code>&lt;ref&gt;</code> annilys;\nrhaid i dagiau ref heb enw iddynt gynnwys rhywbeth",
"cite_error_references_duplicate_key": "Tag <code>&lt;ref&gt;</code> annilys; mae'r enw \"$1\" wedi'i ddiffinio droeon gyda chynnwys gwahanol",
"cite_error_references_invalid_parameters": "Tag <code>&lt;references&gt;</code> annilys;\nni chaniateir paramedrau.\nDefnyddiwch <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tag <code>&lt;references&gt;</code> annilys;\ndim ond y paramedr \"group\" a ganiateir.\nDefnyddiwch <code>&lt;references /&gt;</code>, neu <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Dim rhagor o labeli ôl-gyswllt ar gael.\nDiffiniwch ragor ohonynt yn y neges <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Wedi rhedeg allan o labeli dolenni unigryw ar gyfer y grŵp \"$1\".\nGallwch ddiffinio rhagor ohonynt yn y neges <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Tag <code>&lt;ref&gt;</code> annilys;\nni osodwyd unrhyw destun ar gyfer y 'ref' <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/da.json b/www/wiki/extensions/Cite/i18n/da.json
index d3b2ee98..75ea2679 100644
--- a/www/wiki/extensions/Cite/i18n/da.json
+++ b/www/wiki/extensions/Cite/i18n/da.json
@@ -16,7 +16,6 @@
"cite_error_ref_no_input": "Ugyldigt <code>&lt;ref&gt;</code>-tag: Et <code>&lt;ref&gt;</code>-tag uden navn skal have indhold",
"cite_error_references_duplicate_key": "Ugyldigt <code>&lt;ref&gt;</code> tag; navnet \"$1\" er defineret flere gange med forskelligt indhold",
"cite_error_references_invalid_parameters": "Ugyldigt <code>&lt;references&gt;</code>-tag: Parametre er ikke tilladt, brug i stedet <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Ugyldigt <code>&lt;references&gt;</code>-tag; den eneste tilladte parameter er \"group\".\nBrug <code>&lt;references /&gt;</code> eller <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Løb tør for backlink-etiketter.\nDefiner flere i beskeden <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Løb tør for tilpassede linketiketter til gruppen \"$1\".\nDefiner flere i beskeden <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Ugyldigt <code>&lt;ref&gt;</code>-tag: Der er ikke specificeret nogen fodnotetekst til navnet <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/de-formal.json b/www/wiki/extensions/Cite/i18n/de-formal.json
index b278a3ee..25b06c9c 100644
--- a/www/wiki/extensions/Cite/i18n/de-formal.json
+++ b/www/wiki/extensions/Cite/i18n/de-formal.json
@@ -7,6 +7,5 @@
]
},
"cite_error_ref_numeric_key": "Ungültige Verwendung von <code>&lt;ref&gt;</code>: Der Parameter „name“ darf kein reiner Zahlenwert sein. Benutzen Sie einen beschreibenden Namen.",
- "cite_error_references_invalid_parameters": "Ungültige Verwendung von <code>&lt;references&gt;</code>: Es sind keine Parameter möglich. Verwenden Sie ausschließlich <code><nowiki><references /></nowiki></code>.",
- "cite_error_references_invalid_parameters_group": "Ungültige Verwendung von <code>&lt;references&gt;</code>: Nur der Parameter „group“ ist möglich. Verwenden Sie entweder <code>&lt;references /&gt;</code> oder <code>&lt;references group=\"…\" /&gt;</code>."
+ "cite_error_references_invalid_parameters": "Ungültige Verwendung von <code>&lt;references&gt;</code>: Es sind keine Parameter möglich. Verwenden Sie ausschließlich <code><nowiki><references /></nowiki></code>."
}
diff --git a/www/wiki/extensions/Cite/i18n/de.json b/www/wiki/extensions/Cite/i18n/de.json
index 57e19372..912b3ed9 100644
--- a/www/wiki/extensions/Cite/i18n/de.json
+++ b/www/wiki/extensions/Cite/i18n/de.json
@@ -7,10 +7,12 @@
"Raimond Spekking",
"The Evil IP address",
"Umherirrender",
- "TMg"
+ "TMg",
+ "Debenben"
]
},
"apihelp-query+references-description": "Gibt eine Datendarstellung von Referenzen zurück, die mit den angegebenen Seiten verbunden sind.",
+ "apihelp-query+references-summary": "Gibt eine Datendarstellung der Referenzen zurück, die mit den angegebenen Seiten verbunden sind.",
"apihelp-query+references-example-1": "Referenzen, die mit <kbd>Albert Einstein</kbd> verbunden sind.",
"apierror-citestoragedisabled": "Der Referenzspeicher der Erweiterung „Cite“ ist nicht aktiviert.",
"cite-desc": "Ermöglicht Referenzierungen mittels <code><nowiki><ref[&nbsp;name=id]></nowiki></code> und <code><nowiki><references&nbsp;/></nowiki></code>",
diff --git a/www/wiki/extensions/Cite/i18n/diq.json b/www/wiki/extensions/Cite/i18n/diq.json
index 4bec5b91..e1316209 100644
--- a/www/wiki/extensions/Cite/i18n/diq.json
+++ b/www/wiki/extensions/Cite/i18n/diq.json
@@ -21,7 +21,6 @@
"cite_error_ref_no_input": "Etiket <code>&lt;ref&gt;</code> ke raşt niyo;\nEka name çini yo, gani kontent biyo",
"cite_error_references_duplicate_key": "Nêravêrde <code>&lt;ref&gt;</code> etiket: \"$1\" name yew ra zeder zerrek de şınasiya yo.",
"cite_error_references_invalid_parameters": "Etiket <code>&lt;ref&gt;</code> ke raşt niyo;\nparametrayan ra destur çini yo.\n<code>&lt;references /&gt;</code> sero kar bike",
- "cite_error_references_invalid_parameters_group": "Etiket <code>&lt;ref&gt;</code> ke raşt niyo;\nparametrayan ra destur çini yo.\n<code>&lt;references /&gt;</code> sero kar bike, ya zi <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Linkanê Custom backlinkî hin çini yo.\nZerreyê mesajê <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>î de hewna tasvir bike",
"cite_error_no_link_label_group": "Eka etiketinê linkê şexsi ser ena grubi \"$1\" ciniyo.\nZerre mesajê <nowiki>[[MediaWiki:$2]]</nowiki> de zafyer qise bike.",
"cite_error_references_no_text": "Nêvêreno<code>&lt;ref&gt;</code> etiket;\nno nuşte çıme be namey <code>$1</code> rê vıraziyao.",
diff --git a/www/wiki/extensions/Cite/i18n/dsb.json b/www/wiki/extensions/Cite/i18n/dsb.json
index cfc66244..d284d4dc 100644
--- a/www/wiki/extensions/Cite/i18n/dsb.json
+++ b/www/wiki/extensions/Cite/i18n/dsb.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Njepłaśiwa toflicka <code>&lt;ref&gt;</code>;\nnjepłaśiwe mjenja, na pś. pśewjele",
"cite_error_ref_no_input": "Njepłaśiwa toflicka <code>&lt;ref&gt;</code>;\n\"ref\" bźez mjenja musy wopśimjeśe měś",
"cite_error_references_invalid_parameters": "Njepłaśiwa toflicka <code>&lt;references&gt;</code>;\nžedne parametry dowólone.\nWužyj <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Njepłaśiwa toflicka <code>&lt;references&gt;</code>;\njano parameter \"group\" jo dowólony,\nWužyj <code>&lt;references /&gt;</code> abo <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Swójske etikety slědkwótkazow wupócerane.\nDefiněruj dalšne w powěsći <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Žedne swójske wótkazowe etikety za \"$1\" wěcej k dispoziciji.\nDefiněruj dalšne w powěsći <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Njepłaśiwa toflicka <code>&lt;ref&gt;</code>;\nza ref z mjenim <code>$1</code> njejo se tekst pódał",
diff --git a/www/wiki/extensions/Cite/i18n/el.json b/www/wiki/extensions/Cite/i18n/el.json
index ed83acf6..5370539c 100644
--- a/www/wiki/extensions/Cite/i18n/el.json
+++ b/www/wiki/extensions/Cite/i18n/el.json
@@ -6,7 +6,8 @@
"Protnet",
"ZaDiak",
"Απεργός",
- "Xaris333"
+ "Xaris333",
+ "Nikosgranturismogt"
]
},
"cite-desc": "Προσθέτει τις ετικέτες <nowiki><ref[ name=αναγνωριστικό]></nowiki> και <nowiki><references/></nowiki>, για παραπομπές",
@@ -15,7 +16,7 @@
"cite_error_ref_no_key": "Μη έγκυρη ετικέτα <code>&lt;ref&gt;</code>·\nπαραπομπές χωρίς περιεχόμενο πρέπει να έχουν όνομα",
"cite_error_ref_too_many_keys": "Μη έγκυρη ετικέτα <code>&lt;ref&gt;</code>·\nμη έγκυρα ονόματα, π.χ. πάρα πολλά",
"cite_error_ref_no_input": "Μη έγκυρη ετικέτα <code>&lt;ref&gt;</code>·\nοι παραπομπές χωρίς όνομα πρέπει να έχουν περιεχόμενο",
- "cite_error_references_invalid_parameters": "Μη έγκυρη ετικέτα <code>&lt;references&gt;</code>·\nδεν επιτρέπονται παράμετροι.\nΧρησιμοποιήστε <code>&lt;references /&gt;</code>",
+ "cite_error_references_invalid_parameters": "Άκυρη παράμετρος στην <code>&lt;references&gt;</code> ετικέτα.",
"cite_error_references_no_backlink_label": "Εξαντλήθηκαν οι ειδικές ετικέτες συνδέσμων προς το κείμενο.\nΚαθορισμός περισσότερων στο μήνυμα <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Εξαντλήθηκαν οι ειδικές ετικέτες συνδέσμων για την ομάδα «$1».\nΚαθορισμός περισσότερων στο μήνυμα <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Μη έγκυρη ετικέτα <code>&lt;ref&gt;</code>·\nδεν δίνεται κείμενο για παραπομπές με όνομα <code>$1</code>",
@@ -26,7 +27,9 @@
"cite_error_references_missing_key": "Η ετικέτα <code>&lt;ref&gt;</code> με όνομα «$1» που ορίζεται μέσα στο <code>&lt;references&gt;</code> δεν χρησιμοποιείται σε προηγούμενο κείμενο.",
"cite_error_references_no_key": "Η ετικέτα <code>&lt;ref&gt;</code> που ορίζεται μέσα στο <code>&lt;references&gt;</code> δεν έχει χαρακτηριστικό ονόματος.",
"cite_error_empty_references_define": "Η ετικέτα <code>&lt;ref&gt;</code> που ορίζεται μέσα στο <code>&lt;references&gt;</code> με όνομα «$1» δεν έχει καθόλου περιεχόμενο.",
+ "cite-tracking-category-cite-error": "Σελίδες με σφάλματα αναφορών",
"cite_references_link_accessibility_label": "Άλμα πάνω",
"cite_references_link_many_accessibility_label": "Άλμα πάνω, στο:",
+ "cite_section_preview_references": "Προεπισκόπηση αναφορών",
"cite_warning_sectionpreview_no_text": "↓\n<code>&lt;ref&gt;</code> Η ετικέτα με την ονομασία <code>$1</code> δεν μπορεί να προβληθεί διότι καθορίζεται έξω από το τρέχον κομμάτι ή δεν καθορίζεται καθόλου."
}
diff --git a/www/wiki/extensions/Cite/i18n/eo.json b/www/wiki/extensions/Cite/i18n/eo.json
index 82412f0a..303df228 100644
--- a/www/wiki/extensions/Cite/i18n/eo.json
+++ b/www/wiki/extensions/Cite/i18n/eo.json
@@ -15,7 +15,6 @@
"cite_error_ref_too_many_keys": "Malvalida etikedo <code>&lt;ref&gt;</code>;\nmalvalidaj nomoj (ekz-e: tro multaj)",
"cite_error_ref_no_input": "Malvalida etikedo <code>&lt;ref&gt;</code>;\nref-etikedoj sen nomo devas havi enhavojn.",
"cite_error_references_invalid_parameters": "Nevalida etikedo <code>&lt;references&gt;</code>; neniuj parametroj estas permesitaj, uzu <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Malvalida etikedon <code>&lt;references&gt;</code>;\nparametro \"group\" nur estas permesita.\nUzu etikedon <code>&lt;references /&gt;</code>, aŭ <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Neniom plu memfaritaj retroligaj etikedoj.\nDifinu pliajn en la mesaĝo <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Mankas proprajn ligilajn etikedojn por grupo \"$1\".\nDifinu pliajn en la <nowiki>[[MediaWiki:$2]]</nowiki> mesaĝo.",
"cite_error_references_no_text": "Nevalida <code>&lt;ref&gt;</code> etikedo;\nneniu teksto estis donita por ref-oj nomataj <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/es.json b/www/wiki/extensions/Cite/i18n/es.json
index 31557b23..8bee19d2 100644
--- a/www/wiki/extensions/Cite/i18n/es.json
+++ b/www/wiki/extensions/Cite/i18n/es.json
@@ -23,6 +23,7 @@
]
},
"apihelp-query+references-description": "Devolver una representación de datos de referencias asociadas con las páginas especificadas.",
+ "apihelp-query+references-summary": "Devuelve una representación de datos de las referencias asociadas con las páginas dadas.",
"apihelp-query+references-example-1": "Referencias asociadas con <kbd>Albert Einstein</kbd>.",
"apierror-citestoragedisabled": "El almacenamiento de referencias de la extensión de citas, no está activado.",
"cite-desc": "Añade las etiquetas <nowiki><ref[ name=id]></nowiki> y <nowiki><references/></nowiki> para citas.",
diff --git a/www/wiki/extensions/Cite/i18n/fa.json b/www/wiki/extensions/Cite/i18n/fa.json
index 845c4fbe..dbc750ab 100644
--- a/www/wiki/extensions/Cite/i18n/fa.json
+++ b/www/wiki/extensions/Cite/i18n/fa.json
@@ -11,17 +11,17 @@
]
},
"apihelp-query+references-description": "یک بازنمودِ دادگانی از ارجاع‌هایی که با صفحه‌های داده شده مرتبط هستند برمی‌گرداند.",
+ "apihelp-query+references-summary": "یک بازنمودِ دادگانی از ارجاع‌هایی که با صفحه‌های داده شده مرتبط هستند برمی‌گرداند.",
"apihelp-query+references-example-1": "ارجاع‌های مرتبط با <kbd>Albert Einstein</kbd>.",
"apierror-citestoragedisabled": "ذخیره‌سازی ارجاع‌ها برای افزونهٔ یادکرد فعال نشده‌است.",
"cite-desc": "برچسب‌های <nowiki><ref[ name=id]></nowiki> و <nowiki><references/></nowiki> را برای یادکرد اضافه می‌کند",
"cite_error": "خطای یادکرد: $1",
"cite_error_ref_numeric_key": "برچسب <code><ref></code> نامعتبر؛ نام نمی‌تواند یک عدد باشد. عنوان روشنی برگزینید",
"cite_error_ref_no_key": "برچسب بازکنندهٔ <code><ref></code> بدشکل است یا نام بدی دارد",
- "cite_error_ref_too_many_keys": "برچسب <code><ref></code> غیر مجاز؛ نام‌های غیر مجاز، مثلاً بیش از اندازه",
+ "cite_error_ref_too_many_keys": "برچسب <code>&lt;ref&gt;</code> غیر مجاز؛ نام‌های غیر مجاز، مثلاً بیش از اندازه",
"cite_error_ref_no_input": "برچسب <code><ref></code> نامعتبر؛ یادکردهای بدون نام باید محتوا داشته باشند",
"cite_error_references_duplicate_key": "برچسب <code>&lt;ref&gt;</code> نامعتبر؛ نام «$1» چندین بار با محتوای متفاوت تعریف شده‌است",
- "cite_error_references_invalid_parameters": "برچسب <code><references></code> نامعتبر؛\nاستفاده از پارامتر مجاز نیست.\nاز <code><references /></code> استفاده کنید",
- "cite_error_references_invalid_parameters_group": "برچسب <code>&lt;references&gt;</code> نامعتبر؛\nتنها پارامتر «group» قابل استفاده است.\nاز <code>&lt;references /&gt;</code> یا <code>&lt;references group=\"...\" /&gt;</code> استفاده کنید",
+ "cite_error_references_invalid_parameters": "پارامتر نامعتبر در برچسب <code><references></code> نامعتبر",
"cite_error_references_no_backlink_label": "برچسب‌های پساپیوند سفارشی به انتها رسید.\nموارد جدیدی را در پیغام <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> تعریف کنید.",
"cite_error_no_link_label_group": "برچسب‌های پساپیوند سفارشی برای گروه «$1» به انتها رسید.\nموارد جدیدی را در پیغام <nowiki>[[MediaWiki:$2]]</nowiki> کنید.",
"cite_error_references_no_text": "برچسب <code><ref></code> نامعتبر؛ متنی برای ارجاع‌های با نام <code>$1</code> وارد نشده‌است",
@@ -32,7 +32,7 @@
"cite_error_references_missing_key": "برچسپ <code>&lt;ref&gt;</code> که با نام «$1» درون <code>&lt;references&gt;</code> تعریف شده، در متن قبل از آن استفاده نشده‌است.",
"cite_error_references_no_key": "برچسپ <code>&lt;ref&gt;</code> درون <code>&lt;references&gt;</code> ویژگی name را ندارد.",
"cite_error_empty_references_define": "برچسپ <code>&lt;ref&gt;</code> تعریف شده درون <code>&lt;references&gt;</code> با نام «$1» محتوایی ندارد.",
- "cite-tracking-category-cite-error": "صفحات داری خطا در ارجاع",
+ "cite-tracking-category-cite-error": "صفحات دارای خطا در ارجاع",
"cite-tracking-category-cite-error-desc": "صفحات موجود در این رده دارای خطا در استفاده از برچسب ارجاع هستند.",
"cite_reference_link_key_with_num": "$1_$2",
"cite_reference_link_prefix": "cite_ref-",
diff --git a/www/wiki/extensions/Cite/i18n/fi.json b/www/wiki/extensions/Cite/i18n/fi.json
index 448d45be..027de93a 100644
--- a/www/wiki/extensions/Cite/i18n/fi.json
+++ b/www/wiki/extensions/Cite/i18n/fi.json
@@ -22,7 +22,6 @@
"cite_error_ref_no_input": "Kelpaamaton <code>&lt;ref&gt;</code>-elementti: viitteillä ilman nimiä täytyy olla sisältöä",
"cite_error_references_duplicate_key": "Virheellinen <code>&lt;ref&gt;</code>-elementti; nimi \"$1\" on määritetty usean kerran eri sisällöillä",
"cite_error_references_invalid_parameters": "Kelpaamaton <code>&lt;references&gt;</code>-elementti: parametrit eivät ole sallittuja. Käytä muotoa <code>&lt;references /&gt;</code>.",
- "cite_error_references_invalid_parameters_group": "Kelpaamaton <code>&lt;references&gt;</code>-elementti: vain parametri ”group” on sallittu. Käytä muotoa <code>&lt;references /&gt;</code> tai <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Määritetyt takaisinviittausnimikkeet loppuivat kesken.\nNiitä voi määritellä lisää sivulla <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Mukautettujen linkkikirjainten määrä ryhmälle ”$1” loppui.\nMääritä niitä lisää viestissä <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Virheellinen <code>&lt;ref&gt;</code>-elementti;\nviitettä <code>$1</code> ei löytynyt",
diff --git a/www/wiki/extensions/Cite/i18n/fr.json b/www/wiki/extensions/Cite/i18n/fr.json
index 3d7cc9a9..caf9dd37 100644
--- a/www/wiki/extensions/Cite/i18n/fr.json
+++ b/www/wiki/extensions/Cite/i18n/fr.json
@@ -24,24 +24,24 @@
"apihelp-query+references-summary": "Renvoyer une représentation des données de référence associées aux pages fournies.",
"apihelp-query+references-example-1": "Références associées avec <kbd>Albert Einstein</kbd>.",
"apierror-citestoragedisabled": "La sauvegarde sur l'extension de référence Cite n'est pas activée.",
- "cite-desc": "Ajoute les balises <nowiki><ref[ name=\"id\"]></nowiki> et <nowiki><references/></nowiki> pour les références et notes de bas de page.",
+ "cite-desc": "Ajoute les balises <nowiki><ref[ name=\"id\"]></nowiki> et <nowiki><references/></nowiki> pour les références",
"cite_error": "Erreur de référence : $1",
- "cite_error_ref_numeric_key": "Balise <code>&lt;ref&gt;</code> incorrecte ;\nle nom ne peut être un entier simple. Utilisez un titre descriptif.",
+ "cite_error_ref_numeric_key": "Balise <code>&lt;ref&gt;</code> incorrecte ;\nle nom ne peut être un entier simple. Utilisez un titre descriptif",
"cite_error_ref_no_key": "La balise ouvrante <code>&lt;ref&gt;</code> est mal formée ou a un mauvais nom.",
- "cite_error_ref_too_many_keys": "Balise <code>&lt;ref&gt;</code> incorrecte ;\nnoms incorrects, par exemple trop nombreux.",
- "cite_error_ref_no_input": "Balise <code>&lt;ref&gt;</code> incorrecte ;\nles références sans nom doivent avoir un contenu.",
+ "cite_error_ref_too_many_keys": "Balise <code>&lt;ref&gt;</code> incorrecte ;\nnoms incorrects, par exemple trop nombreux",
+ "cite_error_ref_no_input": "Balise <code>&lt;ref&gt;</code> incorrecte ;\nles références sans nom doivent avoir un contenu",
"cite_error_references_duplicate_key": "Balise <code>&lt;ref&gt;</code> non valide ; le nom « $1 » est défini plusieurs fois avec des contenus différents",
"cite_error_references_invalid_parameters": "Paramètre invalide dans la balise <code>&lt;references&gt;</code>",
- "cite_error_references_no_backlink_label": "Épuisement des étiquettes de liens personnalisées.\nDéfinissez-en un plus grand nombre dans le message <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
+ "cite_error_references_no_backlink_label": "Plus d'étiquettes de liens personnalisées.\nDéfinissez-en un plus grand nombre dans le message <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Plus d’étiquettes de liens personnalisées pour le groupe « $1 ».\nDéfinissez-en plus dans le message <nowiki>[[MediaWiki:$2]]</nowiki>.",
- "cite_error_references_no_text": "Balise <code>&lt;ref&gt;</code> incorrecte ;\naucun texte n’a été fourni pour les références nommées <code>$1</code>.",
- "cite_error_included_ref": "Balise fermante <code>&lt;/ref&gt;</code> manquante pour la balise <code>&lt;ref&gt;</code>.",
- "cite_error_group_refs_without_references": "Des balises <code>&lt;ref&gt;</code> existent pour un groupe nommé « $1 », mais aucune balise <code>&lt;references group=\"$1\"/&gt;</code> correspondante n’a été trouvée, ou bien une balise fermante <code>&lt;/ref&gt;</code> manque.",
+ "cite_error_references_no_text": "Balise <code>&lt;ref&gt;</code> incorrecte ;\naucun texte n’a été fourni pour les références nommées <code>$1</code>",
+ "cite_error_included_ref": "Balise fermante <code>&lt;/ref&gt;</code> manquante pour la balise <code>&lt;ref&gt;</code>",
+ "cite_error_group_refs_without_references": "Des balises <code>&lt;ref&gt;</code> existent pour un groupe nommé « $1 », mais aucune balise <code>&lt;references group=\"$1\"/&gt;</code> correspondante n’a été trouvée, ou bien une balise fermante <code>&lt;/ref&gt;</code> manque",
"cite_error_references_group_mismatch": "La balise <code>&lt;ref&gt;</code> dans <code>&lt;references&gt;</code> a l’attribut de groupe « $1 » qui entre en conflit avec celui de <code>&lt;references&gt;</code>.",
"cite_error_references_missing_group": "La balise <code>&lt;ref&gt;</code> définie dans <code>&lt;references&gt;</code> a un groupe attribué « $1 » qui ne figure pas dans le texte précédent.",
"cite_error_references_missing_key": "La balise <code>&lt;ref&gt;</code> nommée « $1 » définie dans <code>&lt;references&gt;</code> n’est pas utilisée dans le texte précédent.",
"cite_error_references_no_key": "La balise <code>&lt;ref&gt;</code> définie dans <code>&lt;references&gt;</code> n’a pas d’attribut de nom.",
- "cite_error_empty_references_define": "La balise <code>&lt;ref&gt;</code> défini dans <code>&lt;references&gt;</code> avec le nom « $1 » n’a pas de contenu.",
+ "cite_error_empty_references_define": "La balise <code>&lt;ref&gt;</code> définie dans <code>&lt;references&gt;</code> avec le nom « $1 » n’a pas de contenu.",
"cite-tracking-category-cite-error": "Pages avec des erreurs de référence",
"cite-tracking-category-cite-error-desc": "Les pages dans cette catégorie ont des erreurs dans l’utilisation des balises de référence.",
"cite_references_link_many_format": "<sup style=\"margin-left:.2em;margin-right:.2em;\">[[#$1|$2]]</sup>",
diff --git a/www/wiki/extensions/Cite/i18n/frp.json b/www/wiki/extensions/Cite/i18n/frp.json
index 3ad0098a..85be0d6c 100644
--- a/www/wiki/extensions/Cite/i18n/frp.json
+++ b/www/wiki/extensions/Cite/i18n/frp.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Apèl envalido ; cllâfs envalides, per ègzemplo, trop de cllâfs spècefiâs ou ben cllâf fôssa.",
"cite_error_ref_no_input": "Balisa <code>&lt;ref&gt;</code> fôssa ;\nles refèrences sen nom dêvont avêr un contegnu.",
"cite_error_references_invalid_parameters": "Arguments envalidos ; argument atendu.",
- "cite_error_references_invalid_parameters_group": "Balisa <code>&lt;references&gt;</code> fôssa ;\nsolament lo paramètre « tropa » est ôtorisâ.\nUtilisâd <code>&lt;references /&gt;</code>, ou ben <code>&lt;references group=\"...\" /&gt;</code>.",
"cite_error_references_no_backlink_label": "Èpouesement de les ètiquètes de lims pèrsonalisâs.\nDèfenésséd-nen un ples grant nombro dens lo mèssâjo <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Més d’ètiquètes de lims pèrsonalisâs por la tropa « $1 ».\nDèfenésséd-nen més dens lo mèssâjo <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Balisa <code>&lt;ref&gt;</code> fôssa ;\nnion tèxto at étâ balyê por les refèrences apelâs <code>$1</code>.",
diff --git a/www/wiki/extensions/Cite/i18n/fy.json b/www/wiki/extensions/Cite/i18n/fy.json
index 485d7877..3d9c0b09 100644
--- a/www/wiki/extensions/Cite/i18n/fy.json
+++ b/www/wiki/extensions/Cite/i18n/fy.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
"cite_error": "Citeflater: $1"
diff --git a/www/wiki/extensions/Cite/i18n/gcr.json b/www/wiki/extensions/Cite/i18n/gcr.json
new file mode 100644
index 00000000..0333826a
--- /dev/null
+++ b/www/wiki/extensions/Cite/i18n/gcr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "cite_error": "Éròr di référans : $1"
+}
diff --git a/www/wiki/extensions/Cite/i18n/gsw.json b/www/wiki/extensions/Cite/i18n/gsw.json
index 9c7ac9d6..ad9e9033 100644
--- a/www/wiki/extensions/Cite/i18n/gsw.json
+++ b/www/wiki/extensions/Cite/i18n/gsw.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "Uugiltigi <tt>&lt;ref&gt;</tt>-Verwändig: „name“ isch uugiltig oder z lang.",
"cite_error_ref_no_input": "Uugiltigi <tt>&lt;ref&gt;</tt>-Verwändig: „ref“ ohni Name muess e Inhalt haa.",
"cite_error_references_invalid_parameters": "Uugiltigi <tt>&lt;references&gt;</tt>-Verwändig: S sin kei zuesätzligi Parameter erlaubt, verwänd usschließli <tt><nowiki><references /></nowiki></tt>.",
- "cite_error_references_invalid_parameters_group": "Uugiltigi <tt>&lt;references&gt;</tt>-Verwändig: Nume dr Parameter „group“ isch erlaubt, verwänd <tt>&lt;references /&gt;</tt> oder <tt>&lt;references group=\"...\" /&gt;</tt>",
"cite_error_references_no_backlink_label": "E Referenz mit dr Form <tt>&lt;ref name=\"...\"/&gt;</tt> wird meh brucht as es Buechstabe git. E Ammann muess <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> go wyteri Buechstabe/Zeiche ergänze.",
"cite_error_no_link_label_group": "Fir d Gruppe „$1“ sin kei benutzerdefinierti Linkbezeichnige me verfiegbar.\nDefinier meh unter Systemnochricht <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Uugiltige <tt>&lt;ref&gt;</tt>-Tag; s isch kei Täxt fir s Ref mit em Name <tt>$1</tt> aagee wore.",
diff --git a/www/wiki/extensions/Cite/i18n/gu.json b/www/wiki/extensions/Cite/i18n/gu.json
index f1c6aa46..288262fa 100644
--- a/www/wiki/extensions/Cite/i18n/gu.json
+++ b/www/wiki/extensions/Cite/i18n/gu.json
@@ -14,7 +14,6 @@
"cite_error_ref_too_many_keys": "અમાન્ય <code>&lt;ref&gt;</code> ચકતી;\nઅમાન્ય નામો , દા.ત. ઘણાં બધાં",
"cite_error_ref_no_input": "અમાન્ય <code>&lt;ref&gt;</code> ટેગ;\nનામ વગરના refs માં કાંઈક સામગ્રી હોવી જોઈએ",
"cite_error_references_invalid_parameters": "અમાન્ય <code>&lt;references&gt;</code> ટેગ;\nકોઈ પણ પરિમાણની પરવાનગી નથી.\n<code>&lt;references /&gt;</code> વાપરો",
- "cite_error_references_invalid_parameters_group": "અમાન્ય <code>&lt;references&gt;</code> ટેગ;\nમાત્ર \"group\" પરિમાણની પરવાનગી છે.\n<code>&lt;references /&gt;</code> કે <code>&lt;references group=\"...\" /&gt;</code> વાપરો",
"cite_error_references_no_backlink_label": "કસ્ટમ બેકલિંક લેબલ ખલાસ થઈ ગયાં.\n<nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> સંદેશામાં વહારે લેબલ બનાવો..",
"cite_error_no_link_label_group": "\"$1\" સમૂહ માટે કસ્ટમ બેકલિંક લેબલ ખલાસ થઈ ગયાં.\n<nowiki>[[MediaWiki:$2]]</nowiki> સંદેશામાં વહારે લેબલ બનાવો..",
"cite_error_references_no_text": "અમાન્ય <code>&lt;ref&gt;</code> ટેગ;\n<code>$1</code>નામના સંદર્ભ માટે કોઈ પણ લેખન અપાયું નથી",
diff --git a/www/wiki/extensions/Cite/i18n/hr.json b/www/wiki/extensions/Cite/i18n/hr.json
index 14eba2d7..1f85924a 100644
--- a/www/wiki/extensions/Cite/i18n/hr.json
+++ b/www/wiki/extensions/Cite/i18n/hr.json
@@ -17,7 +17,6 @@
"cite_error_ref_no_input": "nevaljana <code>&lt;ref&gt;</code> oznaka; izvori bez imena moraju imati sadržaj",
"cite_error_references_duplicate_key": "nevaljala <code>&lt;ref&gt;</code> oznaka; ime \"$1\" definirano više puta s različitim sadržajem",
"cite_error_references_invalid_parameters": "nevaljana <code>&lt;references&gt;</code> oznaka; parametri nisu dozvoljeni, koristite <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "neispravna <code>&lt;references&gt;</code> oznaka,\ndopuštena je samo opcija \"group\".\nKoristite <code>&lt;references /&gt;</code>, ili <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "potrošene sve posebne oznake za poveznice unatrag, definirajte više u poruci <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "nedovoljan broj proizvoljnih naslova poveznica za grupu \"$1\".\nDefinirajte više putem poruke <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "nije zadan tekst za izvor <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/hsb.json b/www/wiki/extensions/Cite/i18n/hsb.json
index a829ebca..15eecfe3 100644
--- a/www/wiki/extensions/Cite/i18n/hsb.json
+++ b/www/wiki/extensions/Cite/i18n/hsb.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Njepłaćiwe wužiwanje taflički <code>&lt;ref&gt;</code>; njepłaćiwe mjena, na př. předołho",
"cite_error_ref_no_input": "Njepłaćiwe wužiwanje taflički <code>&lt;ref&gt;</code>; \"ref\" bjez mjena dyrbi wobsah měć",
"cite_error_references_invalid_parameters": "Njepłaćiwe wužiwanje taflički <code>&lt;references&gt;</code>; žane parametry dowolene, wužij jenož <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Njepłaćiwa taflička <code>&lt;references&gt;</code>;\njenož parameter \"group\" je dowoleny.\nWužij <code>&lt;references /&gt;</code> abo <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Zwučene etikety wróćowotkazow wućerpjene.\nDefinuj wjace w powěsći <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Swójske wotkazowe etikety za skupinu \"$1\" hižo njejsu.\nDefinuj dalše w zdźělence <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Njepłaćiwa referenca formy <code>&lt;ref&gt;</code>; žadyn tekst za referency z mjenom <code>$1</code> podaty.",
diff --git a/www/wiki/extensions/Cite/i18n/ht.json b/www/wiki/extensions/Cite/i18n/ht.json
index 84f7bdf2..990fe02f 100644
--- a/www/wiki/extensions/Cite/i18n/ht.json
+++ b/www/wiki/extensions/Cite/i18n/ht.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "Etikèt <code>&lt;ref&gt;</code> pa valab;\nnon yo pa bon (pa ekzanp, genyen trop)",
"cite_error_ref_no_input": "Etikèt <code>&lt;ref&gt;</code> pa valab;\nreferans ki pa gen non dwe gen kontni nan yo",
"cite_error_references_invalid_parameters": "Etikèt <code>&lt;references&gt;</code> pa valab;\npa gendwa mete paramèt.\nItilize <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Etikèt <code>&lt;referans&gt;</code> pa valab;\nse paramèt \"group\" sèlman ki otorize.\nItilize <code>&lt;references /&gt;</code>, oubyen <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Pa genyen etikèt pèsonalize ankò.\nPresize yon kantite ki pi gwo nan mesaj <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_references_no_text": "Etikèt <code>&lt;ref&gt;</code> pa valab;\nNou pa bay pyès tèks pou referans ki rele <code>$1</code>"
}
diff --git a/www/wiki/extensions/Cite/i18n/hu.json b/www/wiki/extensions/Cite/i18n/hu.json
index 4069d212..dfecb5a0 100644
--- a/www/wiki/extensions/Cite/i18n/hu.json
+++ b/www/wiki/extensions/Cite/i18n/hu.json
@@ -16,7 +16,6 @@
"cite_error_ref_no_input": "Érvénytelen <code>&lt;ref&gt;</code> tag; a név (name) nélküli ref-eknek adni kell valamilyen tartalmat",
"cite_error_references_duplicate_key": "Érvénytelen <code>&lt;ref&gt;</code> elem, „$1” nevű forráshivatkozás többször van definiálva eltérő tartalommal",
"cite_error_references_invalid_parameters": "Érvénytelen <code>&lt;references&gt;</code> tag; nincsenek paraméterei, használd a <code>&lt;references /&gt;</code> formát",
- "cite_error_references_invalid_parameters_group": "Érvénytelen <code>&lt;references&gt;</code> tag; csak a „group” attribútum használható. Használd a <code>&lt;references /&gt;</code>, vagy a <code>&lt;references group=\"...\" /&gt;</code> formát.",
"cite_error_references_no_backlink_label": "Elfogytak a visszahivatkozásra használt címkék, adj meg többet a <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> üzenetben",
"cite_error_no_link_label_group": "Nincs több egyedi címke a következő csoport számára: „$1”.\nAdj meg többet a <nowiki>[[MediaWiki:$2]]</nowiki> lapon.",
"cite_error_references_no_text": "Érvénytelen <code>&lt;ref&gt;</code> tag; nincs megadva szöveg a(z) <code>$1</code> nevű ref-eknek",
diff --git a/www/wiki/extensions/Cite/i18n/id.json b/www/wiki/extensions/Cite/i18n/id.json
index b92b78e9..b986a63e 100644
--- a/www/wiki/extensions/Cite/i18n/id.json
+++ b/www/wiki/extensions/Cite/i18n/id.json
@@ -5,26 +5,38 @@
"Irwangatot",
"IvanLanin",
"Iwan Novirion",
- "Rex"
+ "Rex",
+ "Gombang"
]
},
+ "apihelp-query+references-description": "Kembalikan representasi data dari referensi yang terkait dengan halaman yang diberikan.",
+ "apihelp-query+references-summary": "Kembalikan representasi data dari referensi yang terkait dengan halaman yang diberikan.",
+ "apihelp-query+references-example-1": "Referensi yang dikaitkan dengan <kbd>Albert Einstein</kbd>.",
+ "apierror-citestoragedisabled": "Penyimpanan Ekstensi pengutipan referensi tidak diaktifkan.",
"cite-desc": "Menambahkan tag <nowiki><ref[ name=id]></nowiki> dan <nowiki><references/></nowiki> untuk kutipan",
"cite_error": "Kesalahan pengutipan: $1",
"cite_error_ref_numeric_key": "Tag <code>&lt;ref&gt;</code> tidak sah; \nnama tidak boleh intejer sederhana.\nGunakan nama deskriptif",
- "cite_error_ref_no_key": "Tag <code>&lt;ref&gt;</code> tidak sah;\nreferensi tanpa isi harus memiliki nama",
+ "cite_error_ref_no_key": "Tag <code>&lt;ref&gt;</code> tidak sah atau memiliki nama yang salah.",
"cite_error_ref_too_many_keys": "Tag <code>&lt;ref&gt;</code> tidak sah;\nnama tidak sah; misalnya, terlalu banyak",
"cite_error_ref_no_input": "Tag <code>&lt;ref&gt;</code> tidak sah;\nreferensi tanpa nama harus memiliki isi",
- "cite_error_references_invalid_parameters": "Tag <code>&lt;references&gt;</code> tidak sah;\nparameter tidak diperbolehkan.\nGunakan <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tag <code>&lt;references&gt;</code> tidak sah;\nhanya parameter \"group\" yang diizinkan.\nGunakan <code>&lt;references /&gt;</code>, atau <code>&lt;references group=\"...\" /&gt;</code>",
+ "cite_error_references_duplicate_key": "Tanda <code>&lt;ref&gt;</code> tidak sah; nama \"$1\" didefinisikan berulang dengan isi berbeda",
+ "cite_error_references_invalid_parameters": "Parameter dalam tag <code>&lt;references&gt;</code> tidak sah;",
"cite_error_references_no_backlink_label": "Kehabisan label pralana balik tersuai.\nTambahkan lagi di pesan sistem <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Pranala kustom label untuk kelompok \"$1\" habis.\nTambahkan ketentuan dalam pesan <nowiki> [[MediaWiki:$2]] </nowiki> .",
"cite_error_references_no_text": "Tag <code>&lt;ref&gt;</code> tidak sah; \ntidak ditemukan teks untuk ref bernama <code>$1</code>",
"cite_error_included_ref": "Tag <code>&lt;ref&gt;</code> harus ditutup oleh <code>&lt;/ref&gt;</code>",
- "cite_error_group_refs_without_references": "Ditemukan tag <code>&lt;ref&gt;</code> untuk kelompok bernama \"$1\", tapi tidak ditemukan tag <code>&lt;references group=\"$1\"/&gt;</code> yang berkaitan",
+ "cite_error_group_refs_without_references": "Ditemukan tag <code>&lt;ref&gt;</code> untuk kelompok bernama \"$1\", tapi tidak ditemukan tag <code>&lt;references group=\"$1\"/&gt;</code> yang berkaitan, atau <code>&lt;/ref&gt;</code> penutup tidak ada",
"cite_error_references_group_mismatch": "Tag <code>&lt;ref&gt;</code> di <code>&lt;references&gt;</code> ada atribut kelompok \"$1\" yang konflik.",
"cite_error_references_missing_group": "Tag <code>&lt;ref&gt;</code> yang didefinisikan di <code>&lt;references&gt;</code> memiliki atribut kelompok \"$1\" yang tidak ditampilkan di teks sebelumnya.",
"cite_error_references_missing_key": "Tag <code>&lt;ref&gt;</code> dengan nama \"$1\" yang didefinisikan di <code>&lt;references&gt;</code> tidak digunakan pada teks sebelumnya.",
"cite_error_references_no_key": "Tag <code>&lt;ref&gt;</code> yang didefinisikan di di <code>&lt;references&gt;</code> tidak memiliki nama atribut.",
"cite_error_empty_references_define": "Tag <code>&lt;ref&gt;</code> yang didefinisikan di di <code>&lt;references&gt;</code> dengan nama \"$1\" tidak memiliki isi.",
- "cite_references_link_many_format": "<sup>[[#$1|$2]]</sup>"
+ "cite-tracking-category-cite-error": "Halaman dengan kesalahan referensi",
+ "cite-tracking-category-cite-error-desc": "Halaman dalam kategori ini memiliki kesalahan dalam penggunaan tanda referensi.",
+ "cite_references_link_many_format": "<sup>[[#$1|$2]]</sup>",
+ "cite_references_link_accessibility_label": "Ke atas",
+ "cite_references_link_many_accessibility_label": "Lompat ke:",
+ "cite_section_preview_references": "Pratayang referensi",
+ "cite_warning": "Peringatan pengutipan: $1",
+ "cite_warning_sectionpreview_no_text": "<code>&lt;ref&gt;</code> Pratayang tanda dengan nama <code>$1</code> tidak dapat ditampilkan karena didefinisikan di luar bagian saat ini atau tidak didefinisikan sama sekali."
}
diff --git a/www/wiki/extensions/Cite/i18n/ilo.json b/www/wiki/extensions/Cite/i18n/ilo.json
index 58de9236..9db5f903 100644
--- a/www/wiki/extensions/Cite/i18n/ilo.json
+++ b/www/wiki/extensions/Cite/i18n/ilo.json
@@ -12,7 +12,6 @@
"cite_error_ref_no_input": "Imbalido nga etiketa ti <code>&lt;ref&gt;</code> ;\ndagiti ref nga awan ti naganna ket masapul nga addaan iti linaon",
"cite_error_references_duplicate_key": "Imbalido nga etiketa ti <code>&lt;ref&gt;</code>; ti nagan ti \"$1\" ket naipalawag kadagiti namin adu a beses nga agraman iti sabali a linaon",
"cite_error_references_invalid_parameters": "Imbalido nga etiketa ti <code>&lt;references&gt;</code>;\nsaan a maipalubos dagiti parametro.\nUsaren ti <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Imbalido nga etiketa ti <code>&lt;references&gt;</code> ;\nmaipalubos laeng ti parametro ti \"grupo\" .\nUsaren ti <code>&lt;references /&gt;</code> , wenno<code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Naibusan kadagiti etiketa ti naisangayan a silpo ti likud.\nIpalawag pay ti adu idiay mensahe ti <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Naibusan kadagiti etiketa ti nangruna a silpo para iti grupo ti \"$1\".\nIpalawag pay ti adu idiay mensahe ti <nowiki>[[MediaWiki:$2]]</nowiki> .",
"cite_error_references_no_text": "Imbalido nga etiketa ti <code>&lt;ref&gt;</code> ;\nawan ti teksto a naited para kadagiti ref a nanaganan ti <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/io.json b/www/wiki/extensions/Cite/i18n/io.json
index 65d3157a..fadb8f9a 100644
--- a/www/wiki/extensions/Cite/i18n/io.json
+++ b/www/wiki/extensions/Cite/i18n/io.json
@@ -1,8 +1,19 @@
{
"@metadata": {
"authors": [
- "Malafaya"
+ "Malafaya",
+ "Joao Xavier"
]
},
- "cite_error": "Citala eroro: $1"
+ "cite_error": "Citala eroro: $1",
+ "cite_error_ref_numeric_key": "Etiketo <code>&lt;ref&gt;</code> nevalida;\nla nomo ne povas simple ula cifro. Uzez deskriptiva titulo",
+ "cite_error_ref_no_key": "L'etiketo dil kodexo <code>&lt;ref&gt;</code> havas nevalida nomo o kreesis nekorekte",
+ "cite_error_ref_too_many_keys": "Nevalida etiketo <code>&lt;ref&gt;</code>;\nnevalida nomi (exemple: tre multa)",
+ "cite_error_references_no_text": "Nevalida etiketo <code>&lt;ref&gt;</code>;\nnula texto furniseis por la referi nomizita <code>$1</code>",
+ "cite_error_group_refs_without_references": "Existas <code>&lt;ref&gt;</code> etiketi por la grupo nomizita \"$1\", ma nula etiketo korespondanta <code>&lt;references group=\"$1\"/&gt;</code> trovesis, o mankas la <code>&lt;/ref&gt;</code> por klozar li.",
+ "cite_error_references_group_mismatch": "Existas konflikti inter la grupala atribuo \"$1\" e <code>&lt;ref&gt;</code> pri l'etiketo <code>&lt;references&gt;</code>.",
+ "cite_error_references_missing_group": "L'etiketo <code>&lt;ref&gt;</code> definita en <code>&lt;references&gt;</code> havas atributo di grupo \"$1\", qua ne aparas en l'antea texto.",
+ "cite_error_references_missing_key": "L'etiketo <code>&lt;ref&gt;</code> nomizita \"$1\" e definita en <code>&lt;references&gt;</code> uzesis nulafoye en l'antea texto.",
+ "cite_error_empty_references_define": "Etiketo <code>&lt;ref&gt;</code> definita en la kodexo <code>&lt;references&gt;</code> e nomizita \"$1\" havas nula kontenajo.",
+ "cite_section_preview_references": "Previdado di referi"
}
diff --git a/www/wiki/extensions/Cite/i18n/is.json b/www/wiki/extensions/Cite/i18n/is.json
index 00aaa132..f2154432 100644
--- a/www/wiki/extensions/Cite/i18n/is.json
+++ b/www/wiki/extensions/Cite/i18n/is.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Snævar"
+ "Snævar",
+ "Sveinn í Felli"
]
},
"cite-desc": "Bætir <nowiki><ref[ name=id]></nowiki> og <nowiki><references/></nowiki> tögum við fyrir heimildir",
@@ -10,8 +11,7 @@
"cite_error_ref_no_key": "Opna <code>&lt;ref&gt;</code> merkið er gallað eða hefur ógilt nafn",
"cite_error_ref_too_many_keys": "Villa í <code>&lt;ref&gt;</code> tag;\nógilt nafn, t.d. of mörg",
"cite_error_ref_no_input": "Villa í <code>&lt;ref&gt;</code> tag;\ntilvísunin verður annaðhvort að hafa nafn eða innihald.",
- "cite_error_references_invalid_parameters": "Villa í <code>&lt;ref&gt;</code> tag;\nengir stikar eru leyfðir\nNotaðu <code>&lt;references /&gt;</code> í staðinn",
- "cite_error_references_invalid_parameters_group": "Villa í <code>&lt;ref&gt;</code> tag;\naðeins einn stiki er leyfður, \"group\"\nNotaðu <code>&lt;references /&gt;</code> eða <code>&lt;references group=\"...\" /&gt;</code> í staðinn.",
+ "cite_error_references_invalid_parameters": "Ógild færibreyta í <code>&lt;references&gt;</code> merkinu",
"cite_error_references_no_text": "Villa í <code>&lt;ref&gt;</code> tag;\ntilgreindu texta fyrir tilvísun með nafnið <code>$1</code>",
"cite_error_included_ref": "Loka þarf tilvísunni með <code>&lt;/ref&gt;</code> tagi",
"cite_error_group_refs_without_references": "<code>&lt;ref&gt;</code> tag er til fyrir hóp tilvísana undir nafninu \"$1\". Annaðhvort finnst ekkert sambærilegt <code>&lt;references group=\"$1\"/&gt;</code> tag, eða að það vanti að loka taginu með <code>&lt;/ref&gt;</code>.",
@@ -20,6 +20,9 @@
"cite_error_references_missing_key": "<code>&lt;ref&gt;</code> tag með nafnið \"$1\" og er skilgreint í <code>&lt;references&gt;</code> er ekki notað í textanum á undan.",
"cite_error_references_no_key": "<code>&lt;ref&gt;</code> tag skilgreint í <code>&lt;references&gt;</code> hefur engin nafna eigindi.",
"cite_error_empty_references_define": "Bæta þarf innihaldi við tilvísun með nafnið \"$1\".",
+ "cite_reference_link_key_with_num": "$1_$2",
+ "cite_references_link_many_sep": "&#32;",
+ "cite_references_link_many_and": "&#32;",
"cite_references_link_accessibility_label": "Stökkva upp",
"cite_references_link_many_accessibility_label": "Stökkva upp til:"
}
diff --git a/www/wiki/extensions/Cite/i18n/ja.json b/www/wiki/extensions/Cite/i18n/ja.json
index df34161b..bf76d9b2 100644
--- a/www/wiki/extensions/Cite/i18n/ja.json
+++ b/www/wiki/extensions/Cite/i18n/ja.json
@@ -9,10 +9,12 @@
"Sujiniku",
"2nd-player",
"Otokoume",
- "Omotecho"
+ "Omotecho",
+ "Yusuke1109"
]
},
"apihelp-query+references-description": "指定されたページに関連付けられた脚注のデータ表現を返す",
+ "apihelp-query+references-summary": "指定されたページに関連付けられた脚注のデータ表現を返す",
"apihelp-query+references-example-1": "<kbd>Albert Einstein</kbd> に関連付けられた脚注。",
"cite-desc": "引用のためのタグ <nowiki><ref[ name=id]></nowiki> および <nowiki><references/></nowiki> を追加する",
"cite_error": "引用エラー: $1",
diff --git a/www/wiki/extensions/Cite/i18n/ka.json b/www/wiki/extensions/Cite/i18n/ka.json
index 3b0c6029..6acc4f79 100644
--- a/www/wiki/extensions/Cite/i18n/ka.json
+++ b/www/wiki/extensions/Cite/i18n/ka.json
@@ -16,7 +16,6 @@
"cite_error_ref_too_many_keys": "არასწორი ტეგი <code>&lt;ref&gt;</code>;\nარასწორი სახელები, ძალიან ბევრი.",
"cite_error_ref_no_input": "არასწორი ტეგი <ref>; ელემენტი უნდა შეიცავდეს შინაარს.",
"cite_error_references_invalid_parameters": "არასწორი ტეგი <code>&lt;references&gt;</code>;\nპარამეტრები არ არის დაშვებული.\nგამოიყენეთ <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "არასწორი<code>&lt;references&gt;</code> გამოყენება: \nდაშვებულია მხოლო პარამეტრი „group“-ის გამოყენება.\nგამოიყენე <tt>&lt;references /&gt;</tt> ან <tt>&lt;references group=\"…\" /&gt;</tt>",
"cite_error_references_no_backlink_label": "არ არის საკმარისი სიმბოლო მზარდი ჰიპერბმულებისათვის.\nსაჭიროა გააფართოვოთ სისტემური შეტყობინება <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "მომხმარებელთა ბმულების მონიშვნები ჯგუფისათვის „$1“ დასრულდა.\nგანსაზღვრეთ დამატებითები შეტყობინებაში <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "არასწორი ტეგი <code>&lt;ref&gt;</code>;\nსქოლიოსათვის <code>$1</code> არ არის მითითებული ტექსტი",
diff --git a/www/wiki/extensions/Cite/i18n/kk-cyrl.json b/www/wiki/extensions/Cite/i18n/kk-cyrl.json
index 9685f552..57ade340 100644
--- a/www/wiki/extensions/Cite/i18n/kk-cyrl.json
+++ b/www/wiki/extensions/Cite/i18n/kk-cyrl.json
@@ -13,7 +13,6 @@
"cite_error_ref_too_many_keys": "Жарамсыз <code>&lt;ref&gt;</code> белгіше; \nжарамсыз атаулар, мысалы, тым көп",
"cite_error_ref_no_input": "Жарамсыз <code>&lt;ref&gt;</code> белгіше;\nатаусыз дереккөздерде мағлұматы болуы қажет",
"cite_error_references_invalid_parameters": "Жарамсыз <code>&lt;references&gt;</code> белгіше;\nеш параметр рұқсат етілмейді, \nбылай <code>&lt;references /&gt;</code> қолданыңыз",
- "cite_error_references_invalid_parameters_group": "Жарамсыз <code>&lt;references&gt;</code> тегі;\nтек \"group\" параметрін рұқсат етеді.\nКелесідей қолданыңыз: <code>&lt;references /&gt;</code>, or <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Өзгертпелі белгілердің саны бітті, одан әрі көбірек <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> жүйе хабарында белгілеңіз",
"cite_error_no_link_label_group": "\"$1\" тобы үшін өзгертпелі сілтеме белгілері бітті.\nDefine more in the <nowiki>[[MediaWiki:$2]]</nowiki> message.",
"cite_error_references_no_text": "Жарамсыз <code>&lt;ref&gt;</code> тегі;\nno text was provided for refs named <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/ksh.json b/www/wiki/extensions/Cite/i18n/ksh.json
index cbe160c5..11cb2f31 100644
--- a/www/wiki/extensions/Cite/i18n/ksh.json
+++ b/www/wiki/extensions/Cite/i18n/ksh.json
@@ -15,7 +15,6 @@
"cite_error_ref_no_input": "Fähler en <i lang=\"en\">cite</i>:\nE <code>&lt;ref&gt;</code> oohne Name moß ene Enhallt han.",
"cite_error_references_duplicate_key": "Dat es ene onjöllteje „<code lang=\"en\" xml:lang=\"en\" dir=\"ltr\">&lt;ref&gt;</code>“-Befähl, Dä Nahme „$1“ es mih wi eijmohl med enem onejahle Ennhalld belähsch.",
"cite_error_references_invalid_parameters": "Fähler en <i lang=\"en\">cite</i>:\nE <code>&lt;references&gt;</code> moß oohne Parrametere sin.\nNemm eifach <code>&lt;references /&gt;</code> un söns nix.",
- "cite_error_references_invalid_parameters_group": "Fähler en <i lang=\"en\">cite</i>:\nE <code>&lt;references&gt;</code> darf nur dä Parrameeter „<code>group</code>“ han.\nNemm eifach <code>&lt;references /&gt;</code> udder <code>&lt;references group=\"...\" /&gt;</code> un söns nix.",
"cite_error_references_no_backlink_label": "Fähler en <i lang=\"en\">cite</i>:\nNit jenoch Name för retuur-Lengks.\nDonn mieh en dä Sigg <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> enndrare.",
"cite_error_no_link_label_group": "För de Jroppe „$1“ senn_er kein Bezeichnonge för Lengks mih doh.\nDonn op <nowiki>[[MediaWiki:$2]]</nowiki> noch e paa dobei.",
"cite_error_references_no_text": "Fähler en <i lang=\"en\">cite</i>:\nEt wohr keine Tex aanjejovve för de\n<code>&lt;ref&gt;</code>s met dämm Name „<code>$1</code>“.",
diff --git a/www/wiki/extensions/Cite/i18n/kum.json b/www/wiki/extensions/Cite/i18n/kum.json
new file mode 100644
index 00000000..586fb9c5
--- /dev/null
+++ b/www/wiki/extensions/Cite/i18n/kum.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "ArslanX"
+ ]
+ },
+ "cite_error": "Ситат янгылышы $1"
+}
diff --git a/www/wiki/extensions/Cite/i18n/lb.json b/www/wiki/extensions/Cite/i18n/lb.json
index cc3b2df4..457c65e3 100644
--- a/www/wiki/extensions/Cite/i18n/lb.json
+++ b/www/wiki/extensions/Cite/i18n/lb.json
@@ -6,7 +6,7 @@
]
},
"apihelp-query+references-example-1": "Referenzen associéiert mam <kbd>Albert Einstein</kbd>.",
- "cite-desc": "Setzt <nowiki><ref[ name=id]></nowiki> an <nowiki><references/></nowiki> Taggen derbäi, fir Zitatiounen.",
+ "cite-desc": "Setzt <nowiki><ref[ name=id]></nowiki> an <nowiki><references/></nowiki> Tagge fir Referenzen derbäi.",
"cite_error": "Zitéierfeeler: $1",
"cite_error_ref_numeric_key": "Ongëltegen <code>&lt;ref&gt;</code> Tag;\nDen Numm ka keng einfach ganz Zuel sinn. Benotzt w.e.g. een Titel den eng Beschreiwung gëtt",
"cite_error_ref_no_key": "Den Ufaang <code>&lt;ref&gt;</code> Tag ass schlecht formatéiert oder huet e falschen Numm",
diff --git a/www/wiki/extensions/Cite/i18n/li.json b/www/wiki/extensions/Cite/i18n/li.json
index 0969d117..6e94adb0 100644
--- a/www/wiki/extensions/Cite/i18n/li.json
+++ b/www/wiki/extensions/Cite/i18n/li.json
@@ -8,21 +8,26 @@
"cite-desc": "Voeg <nowiki><ref[ name=id]></nowiki> en <nowiki><references/></nowiki> tags toe veur citate",
"cite_error": "Citeerfout: $1",
"cite_error_ref_numeric_key": "Ónzjuuste tag <code>&lt;ref&gt;</code>; de naam kin gein simpele integer zeen, gebroek 'ne besjrievendje titel",
- "cite_error_ref_no_key": "Ónzjuuste tag <code>&lt;ref&gt;</code>; refs zónger inhoud mótte 'ne naam höbbe",
+ "cite_error_ref_no_key": "'t Äöpeningslabel <code>&lt;ref&gt;</code> is ónjuus opgemaak of haet 'ne verkieërde naam.",
"cite_error_ref_too_many_keys": "Ónzjuuste tag <code>&lt;ref&gt;</code>; ónzjuuste name, beveurbeildj te väöl",
"cite_error_ref_no_input": "Ónzjuuste tag <code>&lt;ref&gt;</code>; refs zónger naam mótte inhoud höbbe",
- "cite_error_references_invalid_parameters": "Ónzjuuste tag <code>&lt;references&gt;</code>; paramaeters zeen neet toegestaon, gebroek <code>&lt;references /&gt;</code>",
+ "cite_error_references_duplicate_key": "Óngeldig label <code>&lt;ref&gt;</code>; de naam \"$1\" weurt mieëder kieëre mit 'nen angeren inhawd gedefinieerd",
+ "cite_error_references_invalid_parameters": "Ónjuuste <code>&lt;references&gt;</code>-tag",
"cite_error_references_no_backlink_label": "'t Aantal besjikbare backlinklabels is opgebroek. Gaef meer labels op in 't berich <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "'t Aantal aangepasde verwiezingslabels veure groep \"$1\" is oetgepöt.\nDoe kans d'r mier insjtelle in 't sysyeemberich <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Ónzjuuste tag <code>&lt;ref&gt;</code>; d'r is gein teks opgegaeve veur refs mit de naam <code>$1</code>",
"cite_error_included_ref": "Gein sjloetteike <code>&lt;/ref&gt;</code> veur de tag <code>&lt;ref&gt;</code>",
- "cite_error_group_refs_without_references": "d'r Besteit 'ne tag <code>&lt;ref&gt;</code> veure groep \"$1\", meh d'r is geine bebehuuerendje tag <code>&lt;references group=\"$1\"/&gt;</code> gevónje",
+ "cite_error_group_refs_without_references": "E label <code>&lt;ref&gt;</code> veur de groep \"$1\" besitet, meh gein biebehuuerend label <code>&lt;references group=\"$1\"/&gt;</code> is gevónje of 'n aafsloetende <code>&lt;/ref&gt;</code> is neet dao.",
"cite_error_references_group_mismatch": "De tag <code>&lt;ref&gt;</code> in <code>&lt;references&gt;</code> conflicteert mit groepseigesjap \"$1\".",
"cite_error_references_missing_group": "De tag <code>&lt;ref&gt;</code> dae is gedefinieerd in <code>&lt;references&gt;</code> haet de groepseigesjap \"$1\" neet ierder in de tekst veurkump.",
"cite_error_references_missing_key": "De tag <code>&lt;ref&gt;</code> mit de naam \"$1\" gedefiniteerd in <code>&lt;references&gt;</code> weurt neet ierder in de teks gebroek.",
"cite_error_references_no_key": "De tag <code>&lt;ref&gt;</code> dae is gedefinieerd in <code>&lt;references&gt;</code> haet geine eigesjapsnaam.",
"cite_error_empty_references_define": "De tag <code>&lt;ref&gt;</code> dae is gedefinieerd in <code>&lt;references&gt;</code> mit de naam \"$1\" haet geinen inhawd.",
+ "cite-tracking-category-cite-error": "Pagina's mit rifferensiefoute",
+ "cite-tracking-category-cite-error-desc": "Pagina's in dees categorie höbbe fouten in 't gebroek van rifferensielabels.",
"cite_references_link_accessibility_label": "Ómhoeag",
"cite_references_link_many_accessibility_label": "Ómhoeag nao:",
- "cite_warning": "Rifferensiewaorsjoewing: $1"
+ "cite_section_preview_references": "Veurvertuining van rifferensies",
+ "cite_warning": "Rifferensiewaorsjoewing: $1",
+ "cite_warning_sectionpreview_no_text": "Van <code>&lt;ref&gt;</code> mit de naam <code>$1</code> kan gein veurvertuining waere gegaeve, went dees is neet in de hujige sectie of gaaroet neet gedefinieerd wore."
}
diff --git a/www/wiki/extensions/Cite/i18n/lij.json b/www/wiki/extensions/Cite/i18n/lij.json
index 0ff0d8e4..c41af67a 100644
--- a/www/wiki/extensions/Cite/i18n/lij.json
+++ b/www/wiki/extensions/Cite/i18n/lij.json
@@ -14,7 +14,6 @@
"cite_error_ref_no_input": "Tag <code>&lt;ref&gt;</code> non vallido: i ref sença nomme no poeuan ese voeui",
"cite_error_references_duplicate_key": "Tag <code>&lt;ref&gt;</code> non vallido; o nomme \"$1\" o l'è stæto definio ciù votte con di contegnui despægi",
"cite_error_references_invalid_parameters": "Tag <code>&lt;references&gt;</code> non vallido: parametri non ammissi, adoeuvia <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tag <code>&lt;references&gt;</code> non vallido;\nsolo o parametro \"group\" o l'è permisso.\nAdoeuvia <code>&lt;references /&gt;</code> ò <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Etichette de rimando personalizæ esaorie, aomentine o nummero into messaggio <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Etichette pe inganci personalizæ do groppo \"$1\" esaorie, aomentine o nummero into messaggio <nowiki>[[MediaWiki:$2]]</nowiki>",
"cite_error_references_no_text": "Marcatî <code>&lt;ref&gt;</code> non vallido; no l'è stæto indicou nisciun testo pe-o marcatô <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/lki.json b/www/wiki/extensions/Cite/i18n/lki.json
index 5fa23af6..4f0cc191 100644
--- a/www/wiki/extensions/Cite/i18n/lki.json
+++ b/www/wiki/extensions/Cite/i18n/lki.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Hosseinblue",
- "Lakzon"
+ "Lakzon",
+ "Huji"
]
},
"cite-desc": "برچسب‌های <nowiki><ref[ name=id]></nowiki> و <nowiki><references/></nowiki> را برای یادکرد اضافه می‌کند",
@@ -12,10 +13,9 @@
"cite_error_ref_too_many_keys": "برچسب <code><ref></code> نامجاز؛ نام‌های نامجاز یا بیش از اندازه",
"cite_error_ref_no_input": "برچسب <code><ref></code> نامجاز؛ یادکردهای بدون نام باید نۆم جِک(محتوا) داشته باشند",
"cite_error_references_invalid_parameters": "برچسب <code><references></code> نامجاز؛ استفاده از پارامتر مجاز است. از <code><references /></code> استفاده کنید",
- "cite_error_references_invalid_parameters_group": "برچسب <code>&lt;references&gt;</code> نامجاز؛ تنها پارامتر «group» قابل استفاده است.\nاز <code>&lt;references /&gt;</code> یا <code>&lt;references group=\"...\" /&gt;</code> استفاده کنید",
"cite_error_references_no_backlink_label": "برچسب‌های پیوند به انتها رسید.\nموارد جدیدی را در پیغام <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> تعریف کنید",
"cite_error_no_link_label_group": "از برچسب‌های پیوند سفارشی برای گروه «$1» خارج شد.\nدر پیغام <nowiki>[[MediaWiki:$2]]</nowiki> بیشتر تعریف کنید.",
- "cite_error_references_no_text": "برچسب <code><ref></code> نامجاز؛ متنی برای یادکردهای با نام <code>$1</code> وارد نشده‌است",
+ "cite_error_references_no_text": "برچسب <code>&lt;ref&gt;</code> نامجاز؛\nمتنی برای یادکردهای با نام <code>$1</code> وارد نشده‌است",
"cite_error_included_ref": "برچسب تمام کنندهٔ <code>&lt;/ref&gt;</code> بدون برچسب <code>&lt;ref&gt;</code>",
"cite_error_group_refs_without_references": "برچسب <code>&lt;ref&gt;</code> برای گروهی به نام «$1» وجود دارد، اما برچسب متناظر با <code>&lt;references group=\"$1\"/&gt;</code> یافت نشد یا <code>&lt;/ref&gt;</code> بسته جا گذاشته شده‌است.",
"cite_error_references_no_key": "برچسپ <code>&lt;ref&gt;</code> درون <code>&lt;references&gt;</code> صفت نام را ندارد.",
diff --git a/www/wiki/extensions/Cite/i18n/lrc.json b/www/wiki/extensions/Cite/i18n/lrc.json
index db7dd90a..a196fbfb 100644
--- a/www/wiki/extensions/Cite/i18n/lrc.json
+++ b/www/wiki/extensions/Cite/i18n/lrc.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "نامعتور<code>&lt;ref&gt;</code> سردیس؛\nنومیا نامعتور، همچنو فره ئه",
"cite_error_ref_no_input": "نامعتور<code>&lt;ref&gt;</code> سردیس;\nهیچ مینونه ای که واس نومش دیار با دش نئ",
"cite_error_references_invalid_parameters": "نامعتور<code>&lt;سرچشمه یا&gt;</code> سردیس;\nهیچ پارامتری صلادار نئ.\nوه کار گرتن<code>&lt;سرچشمه یا/&gt;</code>",
- "cite_error_references_invalid_parameters_group": "نامعتور<code>&lt;سرچشمه یا&gt;</code> سردیس;\nفقط پارامتر \"دسه\" صلاداره.\nوه کار گرتن <code>&lt;references /&gt;</code>, or <code>&lt;سرچشمه یاgroup=\"...\" /&gt;</code>",
"cite_error_references_no_text": "نامعتور <code>&lt;ref&gt;</code> سردیس;\nهیچ نیسسه یی سی چیا نوم نیائه دیار نکرده<code>$1</code>",
"cite_error_included_ref": "Closing <code>&lt;/ref&gt;</code> گم بیه سی <code>&lt;ref&gt;</code> سردیس",
"cite_error_group_refs_without_references": "<code>&lt;ref&gt;</code> سردیسی سی دسه ای که د\"$1\" نوم دیاره , ولی دیاری نکرده<code>&lt;دسه سرچشمه=\"$1\"/&gt;</code> tag پیدا نبی, یا بسته بیه<code>&lt;/ref&gt;</code> گم بیه",
diff --git a/www/wiki/extensions/Cite/i18n/lt.json b/www/wiki/extensions/Cite/i18n/lt.json
index 46f0e024..1549ef23 100644
--- a/www/wiki/extensions/Cite/i18n/lt.json
+++ b/www/wiki/extensions/Cite/i18n/lt.json
@@ -6,19 +6,19 @@
"Matasg",
"Albertas",
"Zygimantus",
- "Eitvys200"
+ "Eitvys200",
+ "Manvydasz"
]
},
"apihelp-query+references-example-1": "Nuorodos, susijusios su <kbd>Albert Einstein</kbd>.",
"cite-desc": "Prideda <nowiki><ref[ name=id]></nowiki> ir <nowiki><references/></nowiki> žymes citavimui",
- "cite_error": "Citavimo klaida $1",
+ "cite_error": "Citavimo klaida: $1",
"cite_error_ref_numeric_key": "Neleistina <code>&lt;ref&gt;</code> gairė; vardas negali būti tiesiog skaičius, naudokite tekstinį pavadinimą",
"cite_error_ref_no_key": "Neleistina <code>&lt;ref&gt;</code> gairė; nuorodos be turinio turi turėti vardą",
"cite_error_ref_too_many_keys": "Neleistina <code>&lt;ref&gt;</code> gairė; neleistini vardai, pvz., per daug",
"cite_error_ref_no_input": "Neleistina <code>&lt;ref&gt;</code> gairė; nuorodos be vardo turi turėti turinį",
"cite_error_references_duplicate_key": "Netinkama <code>&lt;ref&gt;</code> žymė; vardas \"$1\" apibrėžtas keletą kartų su skirtingu turiniu",
"cite_error_references_invalid_parameters": "Neleistina <code>&lt;references&gt;</code> gairė; neleidžiami jokie parametrai, naudokite <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Netinkamas parametras <code>&lt;references&gt;</code> žymėje",
"cite_error_references_no_backlink_label": "Baigėsi antraštės.\nNurodykite daugiau <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> sisteminiame tekste",
"cite_error_no_link_label_group": "Grupei \"$1\" pasibaigė pritaikytos nuorodų žymės. Galite apibrėžti daugiau <nowiki>[[MediaWiki:$2]]</nowiki> žinutėje.",
"cite_error_references_no_text": "Netinkama <code>&lt;ref&gt;</code> žymė;\nnebuvo pateiktas tekstas nuorodoms su pavadinimu <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/lv.json b/www/wiki/extensions/Cite/i18n/lv.json
index e06431d9..ff21319b 100644
--- a/www/wiki/extensions/Cite/i18n/lv.json
+++ b/www/wiki/extensions/Cite/i18n/lv.json
@@ -7,10 +7,17 @@
"Papuass"
]
},
+ "apihelp-query+references-example-1": "Atsauces, kas saistītas ar <kbd>Albertu Einšteinu</kbd>.",
"cite-desc": "Pievieno <nowiki><ref[ name=id]></nowiki> un <nowiki><references/></nowiki> tagus, atsaucēm",
"cite_error": "Kļūda atsaucē: $1",
"cite_error_ref_numeric_key": "Nederīga <code>&lt;ref&gt;</code> iezīme;\n\"name\" vērtība nevar būt vienkāršs skaitlis. Izmanto aprakstošāku nosaukumu",
+ "cite_error_ref_no_input": "Nederīga <code>&lt;ref&gt;</code> iezīme;\natsaucēm bez nosaukuma ir jābūt saturam",
+ "cite_error_references_duplicate_key": "Nederīga <code>&lt;ref&gt;</code> iezīme; nosaukums \"$1\" definēts vairākas reizes ar atšķirīgu saturu",
+ "cite_error_references_invalid_parameters": "Nederīgs parametrs <code>&lt;references&gt;</code> iezīmē",
+ "cite_error_included_ref": "<code>&lt;ref&gt;</code> iezīmei trūkst aizverošais <code>&lt;/ref&gt;</code>",
"cite-tracking-category-cite-error": "Lapas ar atsauču kļūdām",
+ "cite_references_link_accessibility_label": "Pārlēkt uz augšu",
+ "cite_references_link_many_accessibility_label": "Pārlēkt uz augšu uz:",
"cite_section_preview_references": "Atsauču priekšskats",
"cite_warning": "Atsauces brīdinājums: $1"
}
diff --git a/www/wiki/extensions/Cite/i18n/min.json b/www/wiki/extensions/Cite/i18n/min.json
index 4535b782..203ae2f2 100644
--- a/www/wiki/extensions/Cite/i18n/min.json
+++ b/www/wiki/extensions/Cite/i18n/min.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Tag <code>&lt;ref&gt;</code> indak sah;\nparameter indak sah; mis. talampau panjang",
"cite_error_ref_no_input": "Tag <code>&lt;ref&gt;</code> indak sah;\nrujuakan indak banamo harus ado isi",
"cite_error_references_invalid_parameters": "Tag <code>&lt;references&gt;</code> indak sah;\nindak buliah ado parameter.\nGunoan <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tag <code>&lt;references&gt;</code> indak sah;\nparameter \"group\" sajo nan buliah.\nGunoan <code>&lt;references /&gt;</code>, atau <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Label pautan baliak habih.\nCubo tambahkan di <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Label pautan untuak grup \"$1\" habih.\nTantukan labiah lanjuik dalam <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Tag <code>&lt;ref&gt;</code> indak sah; \nindak ado teks untuak ref banamo <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/ml.json b/www/wiki/extensions/Cite/i18n/ml.json
index 99444e35..b7abb879 100644
--- a/www/wiki/extensions/Cite/i18n/ml.json
+++ b/www/wiki/extensions/Cite/i18n/ml.json
@@ -8,12 +8,11 @@
"cite-desc": "അവലംബം ചേർക്കുവാൻ ഉപയോഗിക്കാനുള്ള <nowiki><ref[ name=id]></nowiki>, <nowiki><references/></nowiki> എന്നീ ടാഗുകൾ ചേർക്കുന്നു",
"cite_error": "ഉദ്ധരിച്ചതിൽ പിഴവ്: $1",
"cite_error_ref_numeric_key": "അസാധുവായ <code>&lt;ref&gt;</code> ടാഗ്;\nനാമത്തിൽ സംഖ്യ മാത്രമായി അനുവദനീയമല്ല. എന്തെങ്കിലും ലഘുവിവരണം ഉപയോഗിക്കുക.",
- "cite_error_ref_no_key": "അസാധുവായ <code>&lt;ref&gt;</code> ടാഗ്;\nഉള്ളടക്കമൊന്നുമില്ലാത്ത അവലംബത്തിനും ഒരു പേരു വേണം.",
+ "cite_error_ref_no_key": "തുറക്കാനുള്ള <code>&lt;ref&gt;</code> ടാഗിൽ പിഴവുണ്ട് അല്ലെങ്കിൽ പേരിൽ കുഴപ്പമുണ്ട്",
"cite_error_ref_too_many_keys": "അസാധുവായ <code>&lt;ref&gt;</code> ടാഗ്;\nഅസാധുവായ പേരുകൾ, ഉദാ: too many",
"cite_error_ref_no_input": "അസാധുവായ <code>&lt;ref&gt;</code> ടാഗ്;\nപേരില്ലാത്ത അവലംബത്തിനു ഉള്ളടക്കമുണ്ടായിരിക്കണം.",
"cite_error_references_duplicate_key": "അസാധുവായ <code>&lt;ref&gt;</code> ടാഗ്; \"$1\" എന്ന പേര് വ്യത്യസ്തമായ ഉള്ളടക്കത്തോടെ നിരവധി തവണ നിർവ്വചിച്ചിരിക്കുന്നു",
- "cite_error_references_invalid_parameters": "അസാധുവായ <code>&lt;references&gt;</code> ടാഗ്;\nറെഫറൻസ് ടാഗിനകത്ത് ചരങ്ങൾ അനുവദനീയമല്ല. പകരം ഇങ്ങനെ <code>&lt;references /&gt;</code> ചെയ്യാവുന്നതാണ്.",
- "cite_error_references_invalid_parameters_group": "അസാധുവായ <code>&lt;references&gt;</code> ടാഗ്;\nറെഫറൻസ് ടാഗിനകത്ത് \"group\" ചരം മാത്രമേ അനുവദനീയമായുള്ളൂ. പകരം <code>&lt;references /&gt;</code> എന്ന്, അല്ലെങ്കിൽ <code>&lt;references group=\"...\" /&gt;</code> എന്ന് ചെയ്യാവുന്നതാണ്.",
+ "cite_error_references_invalid_parameters": "<code>&lt;references&gt;</code> ടാഗിൽ അസാധുവായ ചരം ഉൾപ്പെട്ടിരിക്കുന്നു.",
"cite_error_references_no_backlink_label": "പിൻകണ്ണികൾക്കായി നൽകുന്ന ഇച്ഛാനുസരണ കുറികൾ തീർന്നുപോയിരിക്കുന്നു.\nകൂടുതൽ [[MediaWiki:Cite references link many format backlink labels]] സന്ദേശത്തിൽ നിർവചിക്കുക.",
"cite_error_no_link_label_group": "\"$1\" സംഘത്തിലെ കണ്ണികൾക്കായി നൽകുന്ന ഇച്ഛാനുസരണ കുറികൾ തീർന്നുപോയിരിക്കുന്നു.\nകൂടുതൽ <nowiki>[[MediaWiki:$2]]</nowiki> സന്ദേശത്തിൽ നിർവചിക്കുക.",
"cite_error_references_no_text": "അസാധുവായ <code>&lt;ref&gt;</code> ടാഗ്;\n<code>$1</code> എന്ന അവലംബങ്ങൾക്ക് ടെക്സ്റ്റ് ഒന്നും കൊടുത്തിട്ടില്ല.",
@@ -29,5 +28,8 @@
"cite_reference_link_prefix": "ഉദ്ധരിണി_അവലംബം-",
"cite_references_link_prefix": "ഉദ്ധരിണി_കുറിപ്പ്-",
"cite_references_link_accessibility_label": "മുകളിലേയ്ക്ക്",
- "cite_references_link_many_accessibility_label": "മുകളിൽ ഇവിടേയ്ക്ക്:"
+ "cite_references_link_many_accessibility_label": "മുകളിൽ ഇവിടേയ്ക്ക്:",
+ "cite_section_preview_references": "അവലംബങ്ങൾ എങ്ങനെയുണ്ടെന്ന് കാണുക",
+ "cite_warning": "അവലംബ മുന്നറിയിപ്പ്:$1",
+ "cite_warning_sectionpreview_no_text": "നിലവിലെ വിഭാഗത്തിന്റെ പുറത്ത് നിർവ്വചിച്ചിരിക്കുന്നതിനാൽ അല്ലെങ്കിൽ നിർവചിച്ചിട്ടേയില്ലാത്തതിനാൽ <code>$1</code> എന്ന പേരിലുള്ള <code>&lt;ref&gt;</code> ടാഗ് എങ്ങനെയുണ്ടെന്ന് കാണാൻ കഴിയില്ല."
}
diff --git a/www/wiki/extensions/Cite/i18n/mr.json b/www/wiki/extensions/Cite/i18n/mr.json
index bfd4bf2d..3451fe0f 100644
--- a/www/wiki/extensions/Cite/i18n/mr.json
+++ b/www/wiki/extensions/Cite/i18n/mr.json
@@ -5,17 +5,22 @@
"Kaustubh",
"Mahitgar",
"Rahuldeshmukh101",
- "V.narsikar"
+ "V.narsikar",
+ "Sureshkhole"
]
},
- "cite-desc": "<nowiki><ref[ name=id]></nowiki> व <nowiki><references/></nowiki> हे दोन संदर्भ देण्यासाठी वापरण्यात येणारे शब्द जोडल्या जातील.",
- "cite_error": "त्रुटी उधृत करा: $1",
- "cite_error_ref_numeric_key": "<code>&lt;ref&gt;</code> चुकीचा कोड; नाव हे पूर्णांकी संख्या असू शकत नाही, कृपया माहितीपूर्ण शीर्षक द्या",
+ "apihelp-query+references-description": "दिलेल्या पानांच्या संदर्भांची सांख्यीकी दाखवा",
+ "apihelp-query+references-summary": "दिलेल्या पानांच्या संदर्भांची सांख्यीकी दाखवा",
+ "apihelp-query+references-example-1": "<kbd>अॅल्बर्ट आइन्स्टाइन</kbd> ला दिलेले संदर्भ",
+ "apierror-citestoragedisabled": "अवतरण जोडणी संदर्भ साठवून ठेवणे चालू केलेले नाही",
+ "cite-desc": "<nowiki><ref[ name=id]></nowiki> व <nowiki><references/></nowiki> येथे संदर्भ देण्यासाठी वापरण्यात येणाऱ्या टॅग्ज जोडल्या जातील.",
+ "cite_error": "चुका उधृत करा: $1",
+ "cite_error_ref_numeric_key": "<code>&lt;ref&gt;</code> चुकीचा कोड; नाव हे पूर्णांकी संख्या असू शकत नाही, कृपया वर्णनात्मक शीर्षक द्या",
"cite_error_ref_no_key": "<code>&lt;ref&gt;</code> चुकीचा कोड; रिकाम्या संदर्भांना नाव असणे गरजेचे आहे",
"cite_error_ref_too_many_keys": "<code>&lt;ref&gt;</code> चुकीचा कोड; चुकीची नावे, उदा. खूप सारी",
"cite_error_ref_no_input": "<code>&lt;ref&gt;</code> चुकीचा कोड; निनावी संदर्भांमध्ये माहिती असणे गरजेचे आहे",
- "cite_error_references_invalid_parameters": "<code>&lt;references&gt;</code> हा चुकीचा वापर आहे; यामधे पॅरामीटर्स देणे निषिद्ध आहे.,\n<code>&lt;references /&gt;</code> असा कोड वापरा",
- "cite_error_references_invalid_parameters_group": "चुकीची <code>&lt;references&gt;</code> खूण; फक्त पॅरॅमीटर चा गट वापरता येईल, <code>&lt;references /&gt;</code> किंवा <code>&lt;references group=\"...\" /&gt;</code> चा वापर करा",
+ "cite_error_references_duplicate_key": "अवैध <code>&lt;ref&gt;</code> tag; नाव \"$1\" वेगवेगळ्या मजकूराशी अनेकदा जोडलेले आहे",
+ "cite_error_references_invalid_parameters": "<code>&lt;references&gt;</code> हा चुकीचा वापर आहे; यामधे पॅरामीटर्स देणे निषिद्ध आहे,\n<code>&lt;references /&gt;</code> असा कोड वापरा",
"cite_error_references_no_backlink_label": "तयार केलेली मागीलदुवे देणारी नावे संपलेली आहेत, अधिक नावे <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> या प्रणाली संदेशात लिहा",
"cite_error_no_link_label_group": "\"$1\" करिता नमूदकेलेल्या कस्टम लिंक खूणा संपल्या .\n<nowiki>[[MediaWiki:$2]]</nowiki> संदेशात अधिक खूणा नमूद करा",
"cite_error_references_no_text": "<code>&lt;ref&gt;</code> चुकीचा कोड; <code>$1</code> नावाने दिलेल्या संदर्भांमध्ये काहीही माहिती नाही",
@@ -26,8 +31,11 @@
"cite_error_references_missing_key": "<code>&lt;references&gt;</code> ह्या मध्ये टाकलेला <code>&lt;ref&gt;</code> \"$1\" ह्या नावाची खूणपताका ह्या पूर्वी वापरण्यात आलेली नाही.",
"cite_error_references_no_key": "<code>&lt;ref&gt;</code>खूणपताकेत नमूद गोष्टींना <code>&lt;references&gt;</code> ला नाम-गुणधर्म नाहीत.",
"cite_error_empty_references_define": "<code>&lt;ref&gt;</code>खूणपताकेत नमूद गोष्टींना, <code>&lt;references&gt;</code> ज्या \"$1\" ह्या नावाने संबोधल्या आहेत, त्यात माहिती नाही.",
- "cite-tracking-category-cite-error": "संदर्भ त्रुटी असणारी पाने",
- "cite-tracking-category-cite-error-desc": "या वर्गात असणाऱ्या पानांत संदर्भ खूणपताकासंबंधी त्रुटी आहे.",
- "cite_references_link_accessibility_label": "वर उडी मारा",
- "cite_references_link_many_accessibility_label": "ला वर उडी मारा:"
+ "cite-tracking-category-cite-error": "संदर्भ चुका असणारी पाने",
+ "cite-tracking-category-cite-error-desc": "या वर्गात असणाऱ्या पानांत संदर्भ खूणपताकासंबंधी चुका आहेत.",
+ "cite_references_link_accessibility_label": "वर जा",
+ "cite_references_link_many_accessibility_label": "यावर जा",
+ "cite_section_preview_references": "संदर्भांची झलक दाखवा",
+ "cite_warning": "अवतरणाची ताकीद : $1",
+ "cite_warning_sectionpreview_no_text": "हा <code>&lt;ref&gt;</code> ह्या <code>$1</code> नावाने टॅग केला गेलेला आहे आणि त्याची झलक दाखवली जाऊ शकत नाही कारण तो ठरवलेल्या चौकटी बाहेरचा आहे किंवा त्याची चौकट ठरवली गेलेली नाहीये."
}
diff --git a/www/wiki/extensions/Cite/i18n/ms.json b/www/wiki/extensions/Cite/i18n/ms.json
index e8a0fc92..e8496cd2 100644
--- a/www/wiki/extensions/Cite/i18n/ms.json
+++ b/www/wiki/extensions/Cite/i18n/ms.json
@@ -13,7 +13,6 @@
"cite_error_ref_too_many_keys": "Tag <code>&lt;ref&gt;</code> tidak sah; nama-nama tidak sah, misalnya terlalu banyak",
"cite_error_ref_no_input": "'Tag <code>&lt;ref&gt;</code> tidak sah; rujukan tanpa nama mestilah mempunyai kandungan",
"cite_error_references_invalid_parameters": "Tag <code>&lt;references&gt;</code> tidak sah; parameter tidak dibenarkan, gunakan <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tag <code>&lt;references&gt;</code> tidak sah; hanya parameter \"group\" dibenarkan.\nGunakan <code>&lt;references /&gt;</code> atau <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Kehabisan label pautan balik tempahan. Sila tambah label dalam pesanan <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Kehabisan label pautan tempahan untuk kumpulan \"$1\".\nTentukan lagi dalam mesej <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Tag <code>&lt;ref&gt;</code> tidak sah; teks bagi rujukan <code>$1</code> tidak disediakan",
diff --git a/www/wiki/extensions/Cite/i18n/mt.json b/www/wiki/extensions/Cite/i18n/mt.json
index 0c750ce8..a6b16a6b 100644
--- a/www/wiki/extensions/Cite/i18n/mt.json
+++ b/www/wiki/extensions/Cite/i18n/mt.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Tikketta <code>&lt;ref&gt;</code> invalida;\nismijiet invalidi, e.ż. numru wisq kbir",
"cite_error_ref_no_input": "Żball fl-użu tat-tikketta <code>&lt;ref&gt;</code>; refs mingħajr isem ma jistgħux ikunu vojta",
"cite_error_references_invalid_parameters": "Żball fl-użu tat-tikketta <code>&lt;references&gt;</code>; il-parametri mhumiex permessi. Uża <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tikketta <code>&lt;references&gt;</code> invalida;\nil-paramettru \"group\" biss huwa permess.\nUża <code>&lt;references /&gt;</code> jew <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_text": "Tikketta <code>&lt;ref&gt;</code> invalida;\nl-ebda test ma ngħata għar-refs bl-isem <code>$1</code>",
"cite_error_included_ref": "<code>&lt;/ref&gt;</code> tal-għeluq hija nieqsa għat-tikketta <code>&lt;ref&gt;</code>",
"cite_error_group_refs_without_references": "It-tikketti <code>&lt;ref&gt;</code> jeżistu għal grupp bl-isem \"$1\" imma l-ebda tikketta <code>&lt;references group=\"$1\"/&gt;</code> rispettiva ma nstabet",
diff --git a/www/wiki/extensions/Cite/i18n/mwl.json b/www/wiki/extensions/Cite/i18n/mwl.json
index ff3b563d..80cc0ba0 100644
--- a/www/wiki/extensions/Cite/i18n/mwl.json
+++ b/www/wiki/extensions/Cite/i18n/mwl.json
@@ -1,8 +1,11 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
- "cite-tracking-category-cite-error": "Páiginas cun erros an refréncias"
+ "cite_error": "Erro de citaçon: $1",
+ "cite-tracking-category-cite-error": "Páiginas cun erros an refréncias",
+ "cite-tracking-category-cite-error-desc": "Las páiginas nesta catadorie cunténen erros na outelizaçon de ls eilemientos de refréncias."
}
diff --git a/www/wiki/extensions/Cite/i18n/nap.json b/www/wiki/extensions/Cite/i18n/nap.json
index f4e2b4ab..d3a8b424 100644
--- a/www/wiki/extensions/Cite/i18n/nap.json
+++ b/www/wiki/extensions/Cite/i18n/nap.json
@@ -14,7 +14,6 @@
"cite_error_ref_no_input": "Codece 'e tag <code>&lt;ref&gt;</code> invalido;\n'e riferimente c' 'o nomme abbacante hann'a tenè nu cuntenuto",
"cite_error_references_duplicate_key": "Tag <code>&lt;ref&gt;</code> nun valido; 'o nomme \"$1\" è stato definito cchiù vote cu cuntenute divierze",
"cite_error_references_invalid_parameters": "Tag <code>&lt;references&gt;</code> invalide;\nnun se pò mettere nisciuno parametro.\nAusate <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Codece 'e tag <code>&lt;references&gt;</code> invalido;\nsurtanto 'o parametro \"group\" è premmesso.\nAusate <code>&lt;references /&gt;</code>, o <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "L'etichette personalizzate p' 'e cullegamiente 'e rezza se so' fernute\nPe' piacere, definite nu poco 'e cchiu dint' 'a mmasciata <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Ll'etichette personalizzate d' 'e cullegamiente p' 'o gruppo \"$1\" se so' fernute.\nPruvate a ne definì 'e cchiù int' 'a mmasciata 'e <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Tag <code>&lt;ref&gt;</code> invalido;\nnisciuno testo era previsto p' 'e riferimiente nummenate <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/nds.json b/www/wiki/extensions/Cite/i18n/nds.json
index 615535a8..db0ea54c 100644
--- a/www/wiki/extensions/Cite/i18n/nds.json
+++ b/www/wiki/extensions/Cite/i18n/nds.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Ungülligen Tag <tt>&lt;ref&gt;</tt>: ungüllige Naams, to’n Bispeel to veel.",
"cite_error_ref_no_input": "Ungülligen Tag <tt>&lt;ref&gt;</tt>: „ref“ ahn Naam mutt en Inholt hebben.",
"cite_error_references_invalid_parameters": "Ungülligen Tag <code>&lt;references&gt;</code>: Parameters sünd nich verlöövt, bruuk <tt>&lt;references /&gt;</tt>",
- "cite_error_references_invalid_parameters_group": "Ungülligen Tag <code>&lt;references&gt;</code>: Blot de Parameter „group“ is verlöövt, bruuk <tt>&lt;references /&gt;</tt> oder <tt>&lt;references group=\"...\" /&gt;</tt>",
"cite_error_references_no_backlink_label": "De verföögboren Tekens för de Lenken op Referenzen sünd all. Dat lett sik repareren, wenn in de Systemnaricht <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> mehr Tekens angeven warrt.",
"cite_error_references_no_text": "Ungülligen Tag <tt>&lt;ref&gt;</tt>; is keen Text för Refs mit den Naam <tt>$1</tt> angeven.",
"cite_error_included_ref": "Dor fehlt en tosluten <code>&lt;/ref&gt;</code>",
diff --git a/www/wiki/extensions/Cite/i18n/nl.json b/www/wiki/extensions/Cite/i18n/nl.json
index fb4d083a..c6818942 100644
--- a/www/wiki/extensions/Cite/i18n/nl.json
+++ b/www/wiki/extensions/Cite/i18n/nl.json
@@ -5,7 +5,8 @@
"Niels",
"Romaine",
"Siebrand",
- "Dinosaur918"
+ "Dinosaur918",
+ "Mar(c)"
]
},
"cite-desc": "Voegt <nowiki><ref[ name=id]></nowiki>- en <nowiki><references/></nowiki>-labels toe voor citaten",
@@ -15,8 +16,7 @@
"cite_error_ref_too_many_keys": "Onjuist label <code>&lt;ref&gt;</code>;\nonjuiste namen, bijvoorbeeld te veel",
"cite_error_ref_no_input": "Onjuist label <code>&lt;ref&gt;</code>;\nrefs zonder naam moeten inhoud hebben",
"cite_error_references_duplicate_key": "Ongeldig label <code>&lt;ref&gt;</code>; de naam \"$1\" wordt meerdere keren met andere inhoud gedefinieerd.",
- "cite_error_references_invalid_parameters": "Onjuist label <code>&lt;references&gt;</code>;\nparameters zijn niet toegestaan.\nGebruik <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Ongeldig label <code>&lt;references&gt;</code>;\nalleen de parameter \"group\" is toegestaan.\nGebruik <code>&lt;references /&gt;</code>, of <code>&lt;references group=\"...\" /&gt;</code>",
+ "cite_error_references_invalid_parameters": "Onjuiste <code>&lt;references&gt;</code>-tag",
"cite_error_references_no_backlink_label": "Het aantal beschikbare backlinklabels is opgebruikt.\nGeef meer labels op in het bericht <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Het aantal aangepaste koppelinglabels voor de group \"$1\" is uitgeput.\nU kunt er meer instellen in het systeembericht <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Onjuist label <code>&lt;ref&gt;</code>;\ner is geen tekst opgegeven voor referenties met de naam <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/nn.json b/www/wiki/extensions/Cite/i18n/nn.json
index 89e62506..7e70883a 100644
--- a/www/wiki/extensions/Cite/i18n/nn.json
+++ b/www/wiki/extensions/Cite/i18n/nn.json
@@ -14,10 +14,12 @@
"cite_error_ref_no_input": "Ugyldig <code>&lt;ref&gt;</code>-kode; referansar uten namn må ha innhald",
"cite_error_references_duplicate_key": "Ugyldig <code>&lt;ref&gt;</code>-merke; namnet «$1» er definert flere gonger med ulikt innhald",
"cite_error_references_invalid_parameters": "Ugyldig <code>&lt;references&gt;</code>-kode; ingen parametrar er tillat, bruk <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Ugyldig <code>&lt;references&gt;</code>-tagg; berre parameteren «group» er tillatt. Bruk <code>&lt;references /&gt;</code> eller <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Gjekk tom for eigendefinerte tilbakelenketekstar.\nDefiner fleire i meldinga <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_references_no_text": "Ugyldig <code>&lt;ref&gt;</code>-merke; ingen tekst vart gjeven for referansen med namnet <code>$1</code>",
"cite_error_included_ref": "Avsluttande <code>&lt;/ref&gt;</code>-tagg manglar for <code>&lt;ref&gt;</code>",
"cite_error_group_refs_without_references": "<code>&lt;ref&gt;</code>-merke finst for gruppenamnet «$1», men inkje samsvarande <code>&lt;references group=\"$1\"/&gt;</code>-merke vart funne",
+ "cite_error_references_missing_group": "<code>&lt;ref&gt;</code>-merke definert i <code>&lt;references&gt;</code> har gruppenamnet «$1» som ikkje vert nytta i teksten føre.",
+ "cite_error_references_missing_key": "<code>&lt;ref&gt;</code>-merke med namnet «$1» definert i <code>&lt;references&gt;</code> vert ikkje nytta i teksten føre.",
+ "cite_error_references_no_key": "eit <code>&lt;ref&gt;</code>-merke definert i <code>&lt;references&gt;</code> er ikkje gjeve noko namn.",
"cite_section_preview_references": "Førehandsvising av kjelder"
}
diff --git a/www/wiki/extensions/Cite/i18n/nys.json b/www/wiki/extensions/Cite/i18n/nys.json
new file mode 100644
index 00000000..b60cd118
--- /dev/null
+++ b/www/wiki/extensions/Cite/i18n/nys.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "cite_error": "nidja warra $1"
+}
diff --git a/www/wiki/extensions/Cite/i18n/oc.json b/www/wiki/extensions/Cite/i18n/oc.json
index ecb38d29..6b159c90 100644
--- a/www/wiki/extensions/Cite/i18n/oc.json
+++ b/www/wiki/extensions/Cite/i18n/oc.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Ampèl invalid ; claus invalidas, per exemple, tròp de claus especificadas o clau erronèa",
"cite_error_ref_no_input": "Ampèl invalid ; cap de dintrada pas especificada",
"cite_error_references_invalid_parameters": "Arguments invalids ; argument esperat",
- "cite_error_references_invalid_parameters_group": "Balisa <code>&lt;references&gt;</code> incorrècta ;\n\nsol lo paramètre « group » es autorizat.\n\nUtilizatz <code>&lt;references /&gt;</code>, o alara <code>&lt;references group=\"...\" /&gt;</code>.",
"cite_error_references_no_backlink_label": "Execucion en defòra de las etiquetas personalizadas, definissetz mai dins lo messatge <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_references_no_text": "Balisa <code>&lt;ref&gt;</code> incorrècta ;\n\npas de tèxte per las referéncias nomenadas <code>$1</code>.",
"cite_error_included_ref": "Clausura <code>&lt;/ref&gt;</code> omesa per la balisa <code>&lt;ref&gt;</code>",
diff --git a/www/wiki/extensions/Cite/i18n/or.json b/www/wiki/extensions/Cite/i18n/or.json
index 63b280de..607d21ec 100644
--- a/www/wiki/extensions/Cite/i18n/or.json
+++ b/www/wiki/extensions/Cite/i18n/or.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "ଅବୈଧ <code>&lt;ref&gt;</code> ଟ୍ୟାଗ;\nଭୁଲ ନାମ (ଯଥା: ଖୁବ ଅଧିକ)",
"cite_error_ref_no_input": "ଅବୈଧ <code>&lt;ref&gt;</code> ଟ୍ୟାଗ;\nକୌଣସି ବି ନାମ ନଥିବା ଆଧାରର କିଛି ବିଷୟବସ୍ତୁ ଥିବା ଲୋଡ଼ା",
"cite_error_references_invalid_parameters": "ଅଚଳ <code>&lt;references&gt;</code> ଟ୍ୟାଗ;\nକୌଣସିଟି ପାରାମିଟର ଅନୁମୋଦିତ ନୁହେଁ ।\n<code>&lt;references /&gt;</code> ବ୍ୟବହାର କରନ୍ତୁ ।",
- "cite_error_references_invalid_parameters_group": "ତ୍ରଟିପୂର୍ଣ୍ଣ <code>&lt;references&gt;</code> ଚିହ୍ନ;\n\"group\" ପାରାମିଟରଟି କେବଳ ଅନୁମୋଦିତ ।\n<code>&lt;references /&gt;</code>, କିମ୍ବା <code>&lt;references group=\"...\" /&gt;</code> ବ୍ୟବହାର କରନ୍ତୁ",
"cite_error_references_no_backlink_label": "ନିଜ ପସନ୍ଦର ବ୍ୟାକଲିଙ୍କ ଚିହ୍ନ ସବୁ ସରିଗଲା ।\n<nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>ସୂଚନାରେ ଅଧିକ ଦେଖନ୍ତୁ ।",
"cite_error_no_link_label_group": "\"$1\" ଗୋଠ ଲାଗି ନିଜ ପସନ୍ଦର ବ୍ୟାକଲିଙ୍କ ଚିହ୍ନ ସବୁ ସରିଗଲା ।\n<nowiki>[[MediaWiki:$2]]</nowiki>ସୂଚନାରେ ଅଧିକ ଚିହ୍ନିତ କରନ୍ତୁ ।",
"cite_error_references_no_text": "ଅଚଳ <code>&lt;ref&gt;</code> ଚିହ୍ନ;\n<code>$1</code> ନାମରେ ଥିବା ଆଧାର ଭିତରେ କିଛି ଲେଖା ନାହିଁ ।",
diff --git a/www/wiki/extensions/Cite/i18n/pms.json b/www/wiki/extensions/Cite/i18n/pms.json
index d422f064..a28f9368 100644
--- a/www/wiki/extensions/Cite/i18n/pms.json
+++ b/www/wiki/extensions/Cite/i18n/pms.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "Tichëtta <code>&lt;ref&gt;</code> pa bon-a;\nnòm pa bon, për esempi tròpi",
"cite_error_ref_no_input": "Tichëtta <code>&lt;ref&gt;</code> pa bon-a;\nj'arferiment sensa nòm a devo avèj un contnù",
"cite_error_references_invalid_parameters": "Tichëtta <code>&lt;references&gt;</code> pa bon-a;\npa gnun paràmetr përmëttù.\nCh'a deuvra <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tichëtta <code>&lt;references&gt;</code> pa bon-a;\nas peul mach dovresse ël paràmetr \"group\".\nCh'a deuvra <code>&lt;references /&gt;</code>, o <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Etichëtte ëd backlink përsonalisà esaurìe.\nDefiniss-ne ëd pì ant ël messagi <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Surtì fòra dle tichëtte dij colegament utent për la partìa \"$1\".\nDefinissne ëd pi ant ël mëssagi <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Tichëtta <code>&lt;ref&gt;</code> pa bon-a;\npa gnun test a l'é stàit dàit për l'arferiment ciamà <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/pnb.json b/www/wiki/extensions/Cite/i18n/pnb.json
index 3715fa5a..c8a2f0e1 100644
--- a/www/wiki/extensions/Cite/i18n/pnb.json
+++ b/www/wiki/extensions/Cite/i18n/pnb.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "ناں منیا جان والا <code>&lt;ref&gt;</code> ٹیگ؛\nناں منے جان والے ناں",
"cite_error_ref_no_input": "ناں منیا جان والا <code>&lt;ref&gt;</code> ٹیگ؛\nاتے پتے جیدے چ کوئی شے ناں ہووے لازمی ناں ہووے۔",
"cite_error_references_invalid_parameters": "ناں منیا جان والا <code>&lt;references&gt;</code> ٹیگ؛\nکسے پیرامیٹر دی اجازت نئیں۔\n<code>&lt;references /&gt;</code> ورتو",
- "cite_error_references_invalid_parameters_group": "ناں منیا جان والا <code>&lt;references&gt;</code> ٹیگ؛\nپیرامیٹر گروپ دی اجازت صرف۔\nورتو <code>&lt;references /&gt;</code>، یا <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "کسٹم پچھلے جزڑ نئیں رۓ۔\nہور دسو <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> سنیعے چ۔",
"cite_error_no_link_label_group": "\"$1\" ٹولی لئی کسٹم لیبل جوڑ مک گۓ۔\nہور دسو <nowiki>[[MediaWiki:$2]]</nowiki> سنیعے چ۔",
"cite_error_references_no_text": "ناں منیا جان والا <code>&lt;ref&gt;</code> ٹیگ\nکوئی لکھت نئیں دتی گئی اتے پتے <code>$1</code> لئی۔",
diff --git a/www/wiki/extensions/Cite/i18n/ps.json b/www/wiki/extensions/Cite/i18n/ps.json
index f3a82f7a..4b3cb919 100644
--- a/www/wiki/extensions/Cite/i18n/ps.json
+++ b/www/wiki/extensions/Cite/i18n/ps.json
@@ -1,8 +1,11 @@
{
"@metadata": {
"authors": [
- "Ahmed-Najib-Biabani-Ibrahimkhel"
+ "Ahmed-Najib-Biabani-Ibrahimkhel",
+ "Baloch Khan"
]
},
- "cite_error": "د اخځ ستونزه: $1"
+ "cite_error": "د اخځ ستونزه: $1",
+ "cite-tracking-category-cite-error": "مخونه د غبرګونيزي تيروتنې سره",
+ "cite_section_preview_references": "د غبرګونونو وړاندېز"
}
diff --git a/www/wiki/extensions/Cite/i18n/pt.json b/www/wiki/extensions/Cite/i18n/pt.json
index 3f0a99a8..4ca895ea 100644
--- a/www/wiki/extensions/Cite/i18n/pt.json
+++ b/www/wiki/extensions/Cite/i18n/pt.json
@@ -25,7 +25,7 @@
"cite_error_references_duplicate_key": "Código <code>&lt;ref&gt;</code> inválido; o nome \"$1\" é definido mais de uma vez com conteúdos diferentes",
"cite_error_references_invalid_parameters": "Parâmetro inválido na etiqueta <code>&lt;references&gt;</code>",
"cite_error_references_no_backlink_label": "Esgotamento das legendas personalizadas para backlinks.\nDefina mais na mensagem <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
- "cite_error_no_link_label_group": "Esgotamento das legendas personalizadas para links, no grupo \"$1\".\nDefina mais na mensagem <nowiki>[[MediaWiki:$2]]</nowiki>.",
+ "cite_error_no_link_label_group": "Esgotamento das legendas personalizadas para hiperligações, no grupo \"$1\".\nDefina mais na mensagem <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Código <code>&lt;ref&gt;</code> inválido; não foi fornecido texto para as refs de nome <code>$1</code>",
"cite_error_included_ref": "Elemento de fecho <code>&lt;/ref&gt;</code> em falta para o elemento <code>&lt;ref&gt;</code>",
"cite_error_group_refs_without_references": "Existem elementos <code>&lt;ref&gt;</code> para um grupo chamado \"$1\", mas não foi encontrado nenhum <code>&lt;references group=\"$1\"/&gt;</code> correspondente (ou falta um elemento de fecho <code>&lt;/ref&gt;</code>)",
diff --git a/www/wiki/extensions/Cite/i18n/qqq.json b/www/wiki/extensions/Cite/i18n/qqq.json
index ffc09102..fa0ab69d 100644
--- a/www/wiki/extensions/Cite/i18n/qqq.json
+++ b/www/wiki/extensions/Cite/i18n/qqq.json
@@ -12,7 +12,8 @@
"Shirayuki",
"Siebrand",
"The Evil IP address",
- "Umherirrender"
+ "Umherirrender",
+ "Mar(c)"
]
},
"apihelp-query+references-description": "{{doc-apihelp-description|query+references}}",
@@ -26,7 +27,7 @@
"cite_error_ref_too_many_keys": "Cite extension. Error message shown when ref tags has parameters other than name and group. Examples that cause this error are <code><nowiki><ref name=\"name\" notname=\"value\" /></nowiki></code> or <code><nowiki><ref notname=\"value\" >input<ref></nowiki></code>",
"cite_error_ref_no_input": "Cite extension. Error message shown when ref tags without names have no content. An example that cause this error is <code><nowiki><ref></ref></nowiki></code>",
"cite_error_references_duplicate_key": "Cite extension. Error message shown when multiple refs with same name exist but with different content",
- "cite_error_references_invalid_parameters": "Cite extension. Error message shown when parmeters are used in the references tag. An example that cause this error is <code><nowiki><references someparameter=\"value\" /></nowiki></code>",
+ "cite_error_references_invalid_parameters": "Cite extension. Error message shown when parameters are used in the references tag. An example that causes this error is <code><nowiki><references someparameter=\"value\" /></nowiki></code>.",
"cite_error_references_no_backlink_label": "Cite extension. Error message shown in the references tag when the same name is used for too many ref tags. Too many in this case is more than there are backlink labels defined in [[MediaWiki:Cite references link many format backlink labels]].\n\nIt is not possible to make a clickable link to this message. \"nowiki\" is mandatory around [[MediaWiki:Cite references link many format backlink labels]].",
"cite_error_no_link_label_group": "*'''$1''' is the name of a reference group.\n*'''$2''' is <code>cite_link_label_group-<i>groupname</i></code>.",
"cite_error_references_no_text": "Cite extension. This error occurs when the tag <code><nowiki><ref name=\"something\" /></nowiki></code> is used with the name-option specified and no other tag specifies a cite-text for this name.\n\nParameters:\n* $1 - key of the ref",
@@ -43,7 +44,7 @@
"cite_reference_link_prefix": "{{optional}}",
"cite_reference_link_suffix": "{{optional}}",
"cite_references_link_prefix": "{{optional}}",
- "cite_references_link_suffix": "{{optional}}",
+ "cite_references_link_suffix": "{{ignored}}",
"cite_reference_link": "{{optional}}\nParameters:\n* $1 - ref key\n* $2 - references key\n* $3 - link label",
"cite_references_no_link": "{{notranslate}}\nParameters:\n* $1 - references key\n* $2 - reference text",
"cite_references_link_one": "{{optional}}\nParameters:\n* $1 - references key\n* $2 - ref key\n* $3 - reference text",
diff --git a/www/wiki/extensions/Cite/i18n/qu.json b/www/wiki/extensions/Cite/i18n/qu.json
index cb36515b..73b5dfb4 100644
--- a/www/wiki/extensions/Cite/i18n/qu.json
+++ b/www/wiki/extensions/Cite/i18n/qu.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "<code>&lt;ref&gt;</code> unanchachaqa manam allinchu;\nsutinkunaqa manam allinchu, nisyu sutinchá",
"cite_error_ref_no_input": "<code>&lt;ref&gt;</code> unanchachaqa manam allinchu;\nsutinnaq pukyu willana unanchachaqa ama ch'usaqchu kachun",
"cite_error_references_invalid_parameters": "<code>&lt;ref&gt;</code> unanchachaqa manam allinchu;\nama kuskanachina tupuchu kachun. <code>&lt;references /&gt;</code> unanchachata llamk'achiy",
- "cite_error_references_invalid_parameters_group": "<code>&lt;ref&gt;</code> unanchachaqa manam allinchu;\n\"group\" nisqa kuskanachina tupulla kachun. <code>&lt;references /&gt;</code> icha <code>&lt;references group=\"...\" /&gt;</code> unanchachata llamk'achiy",
"cite_error_references_no_backlink_label": "Manañam kanchu allichana kutimuy t'inki unanchakuna.\nAstawan sut'ichay <nowiki>[[MediaWiki:Cite references link many format backlink labels|Pukyumanta willaykuna achka allichana kutimuy t'inki unanchakunata t'inkin]]</nowiki> nisqa willaypi",
"cite_error_references_no_text": "<code>&lt;ref&gt;</code> unanchachaqa manam allinchu;\n<code>$1</code> nisqapaq pukyu qillqa manam kanchu",
"cite_error_included_ref": "Kichaq <code>&lt;ref&gt;</code> unanchachapaq wichq'aq <code>&lt;/ref&gt;</code> unanchachaqa manam kanchu",
diff --git a/www/wiki/extensions/Cite/i18n/ro.json b/www/wiki/extensions/Cite/i18n/ro.json
index 06c02eed..64068ff0 100644
--- a/www/wiki/extensions/Cite/i18n/ro.json
+++ b/www/wiki/extensions/Cite/i18n/ro.json
@@ -5,17 +5,21 @@
"KlaudiuMihaila",
"Mihai",
"Minisarm",
- "Marian banica"
+ "Marian banica",
+ "Strainu"
]
},
+ "apihelp-query+references-description": "Întoarce o reprezentare a referințelor asociate cu paginile date.",
+ "apihelp-query+references-summary": "Întoarce o reprezentare a referințelor asociate cu paginile date.",
+ "apihelp-query+references-example-1": "Referințe asociate cu <kbd>Albert Einstein</kbd>.",
"cite-desc": "Adaugă etichete <nowiki><ref[ name=id]></nowiki> și <nowiki><references/></nowiki>, pentru citări",
"cite_error": "Eroare la citare: $1",
"cite_error_ref_numeric_key": "Etichetă <code>&lt;ref&gt;</code> invalidă;\nnumele nu poate fi un număr. Folosește un titlu descriptiv",
- "cite_error_ref_no_key": "Etichetă <code>&lt;ref&gt;</code> invalidă;\nref-urile fără conținut trebuie să aibă un nume",
+ "cite_error_ref_no_key": "Eticheta de început <code>&lt;ref&gt;</code> este malformată sau are un nume greșit",
"cite_error_ref_too_many_keys": "Etichetă <code>&lt;ref&gt;</code> invalidă;\nnume invalid, ex. prea multe nume",
"cite_error_ref_no_input": "Etichetă <code>&lt;ref&gt;</code> invalidă;\nref-urile fără nume trebuie să aibă conținut",
- "cite_error_references_invalid_parameters": "Etichetă <code>&lt;references&gt;</code> invalidă;\nparametrii nu sunt permiși.\nFolosește eticheta <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Etichetă <code>&lt;references&gt;</code> invalidă;\ndoar parametrul „grup” este permis.\nFolosește eticheta <code>&lt;references /&gt;</code>, sau <code>&lt;references group=\"...\" /&gt;</code>",
+ "cite_error_references_duplicate_key": "Etichetă <code>&lt;ref&gt;</code> invalidă; numele \"$1\" este definit de mai multe ori cu conținut diferit",
+ "cite_error_references_invalid_parameters": "Parametru invalid în eticheta <code>&lt;references&gt;</code>",
"cite_error_references_no_backlink_label": "S-au epuizat etichetele pentru legături personalizate.\nDefiniți mai multe etichete în cadrul mesajului <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "S-au epuizat etichetele pentru legături personalizate pentru grupul „$1”. \nDefiniți mai multe etichete în cadrul mesajului <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Etichetă <code>&lt;ref&gt;</code> invalidă;\nniciun text nu a fost furnizat pentru ref-urile numite <code>$1</code>",
@@ -26,6 +30,11 @@
"cite_error_references_missing_key": "Eticheta <code>&lt;ref&gt;</code> cu numele „$1” definită în <code>&lt;references&gt;</code> nu este utilizată în textul anterior.",
"cite_error_references_no_key": "Eticheta <code>&lt;ref&gt;</code> definită în <code>&lt;references&gt;</code> nu are atributul nume.",
"cite_error_empty_references_define": "Eticheta <code>&lt;ref&gt;</code> definită în <code>&lt;references&gt;</code> cu numele „$1” nu are conținut.",
+ "cite-tracking-category-cite-error": "Pagini cu erori de citare",
+ "cite-tracking-category-cite-error-desc": "Paginile din această categorie au erori în folosirea etichetelor de referințe.",
"cite_references_link_accessibility_label": "Salt",
- "cite_references_link_many_accessibility_label": "Salt la:"
+ "cite_references_link_many_accessibility_label": "Salt la:",
+ "cite_section_preview_references": "Previzualizare a notelor",
+ "cite_warning": "Avertisment de citare: $1",
+ "cite_warning_sectionpreview_no_text": "Eitcheta <code>&lt;ref&gt;</code> cu numele <code>$1</code> nu poate fi previzualizată pentru că este definită în afara secțiunii curente sau nu este definită deloc."
}
diff --git a/www/wiki/extensions/Cite/i18n/ru.json b/www/wiki/extensions/Cite/i18n/ru.json
index 70f2337c..86ea0f79 100644
--- a/www/wiki/extensions/Cite/i18n/ru.json
+++ b/www/wiki/extensions/Cite/i18n/ru.json
@@ -14,7 +14,8 @@
"Putnik",
"Redredsonia",
"Alexandr Efremov",
- "Facenapalm"
+ "Facenapalm",
+ "Iniquity"
]
},
"apihelp-query+references-description": "Возвращает представление данных из ссылок, связанных с данной страницей.",
@@ -45,7 +46,7 @@
"cite_reference_link_prefix": "cite_ref-",
"cite_references_link_prefix": "cite_note-",
"cite_references_link_many_format": "<sup>[[#$1|$2]]</sup>",
- "cite_references_link_many_format_backlink_labels": "а б в г д е ё ж з и й к л м н о п р с т у ф х ц ч ш щ ъ ы ь э ю я аа аб ав аг ад ае ё аж аз аи ай ак ал ам ан ао ап ар ас ат ау аф ах ац ач аш ащ аъ аы аь аэ аю ая ба бб бв бг бд бе бж бз би бй бк бл бм бн бо бп бр бс бт бу бф бх бц бч бш бщ бъ бы бь бэ бю бя ва вб вв вг вд ве вж вз ви вй вк вл вм вн во вп вр вс вт ву вф вх вц вч вш вщ въ вы вь вэ вю вя га гб гв гг гд ге гж гз ги гй гк гл гм гн го гп гр гс гт гу гф гх гц гч гш гщ гъ гы гь гэ гю гя да дб дв дг дд де дж дз ди дй дк дл дм дн до дп др дс дт ду дф дх дц дч дш дщ дъ ды дь дэ дю дя еа еб ев ег ед ее еж ез еи ей ек ел ем ен ео еп ер ес ет еу еф ех ец еч еш ещ еъ еы еь еэ ею ея жа жб жв жг жд же жж жз жи жй жк жл жм жн жо жп жр жс жт жу жф жх жц жч жш жщ жъ жы жь жэ жю жя за зб зв зг зд зе зж зз зи зй зк зл зм зн зо зп зр зс зт зу зф зх зц зч зш зщ зъ зы зь зэ зю зя иа иб ив иг ид ие иж из ии ий ик ил им ин ио ип ир ис ит иу иф их иц ич иш ищ иъ иы иь иэ ию ия йа йб йв йг йд йе йж йз йи йй йк йл йм йн йо йп йр йс йт йу йф йх йц йч йш йщ йъ йы йь йэ йю йя ка кб кв кг кд ке кж кз ки кй кк кл км кн ко кп кр кс кт ку кф кх кц кч кш кщ къ кы кь кэ кю кя ла лб лв лг лд ле лж лз ли лй лк лл лм лн ло лп лр лс лт лу лф лх лц лч лш лщ лъ лы ль лэ лю ля ма мб мв мг мд ме мж мз ми мй мк мл мм мн мо мп мр мс мт му мф мх мц мч мш мщ мъ мы мь мэ мю мя на нб нв нг нд не нж нз ни нй нк нл нм нн но нп нр нс нт ну нф нх нц нч нш нщ нъ ны нь нэ ню ня оа об ов ог од ое ож оз ои ой ок ол ом он оо оп ор ос от оу оф ох оц оч ош ощ оъ оы оь оэ ою оя па пб пв пг пд пе пж пз пи пй пк пл пм пн по пп пр пс пт пу пф пх пц пч пш пщ пъ пы пь пэ пю пя ра рб рв рг рд ре рж рз ри рй рк рл рм рн ро рп рр рс рт ру рф рх рц рч рш рщ ръ ры рь рэ рю ря са сб св сг сд се сж сз си сй ск сл см сн со сп ср сс ст су сф сх сц сч сш сщ съ сы сь сэ сю ся та тб тв тг тд те тж тз ти тй тк тл тм тн то тп тр тс тт ту тф тх тц тч тш тщ тъ ты ть тэ тю тя уа уб ув уг уд уе уж уз уи уй ук ул ум ун уо уп ур ус ут уу уф ух уц уч уш ущ уъ уы уь уэ ую уя фа фб фв фг фд фе фж фз фи фй фк фл фм фн фо фп фр фс фт фу фф фх фц фч фш фщ фъ фы фь фэ фю фя ха хб хв хг хд хе хж хз хи хй хк хл хм хн хо хп хр хс хт ху хф хх хц хч хш хщ хъ хы хь хэ хю хя ца цб цв цг цд це цж цз ци цй цк цл цм цн цо цп цр цс цт цу цф цх цц цч цш цщ цъ цы ць цэ цю ця ча чб чв чг чд че чж чз чи чй чк чл чм чн чо чп чр чс чт чу чф чх чц чч чш чщ чъ чы чь чэ чю чя ша шб шв шг шд ше шж шз ши шй шк шл шм шн шо шп шр шс шт шу шф шх шц шч шш шщ шъ шы шь шэ шю шя ща щб щв щг щд ще щж щз щи щй щк щл щм щн що щп щр щс щт щу щф щх щц щч щш щщ щъ щы щь щэ щю щя ъа ъб ъв ъг ъд ъе ъж ъз ъи ъй ък ъл ъм ън ъо ъп ър ъс ът ъу ъф ъх ъц ъч ъш ъщ ъъ ъы ъь ъэ ъю ъя ыа ыб ыв ыг ыд ые ыж ыз ыи ый ык ыл ым ын ыо ып ыр ыс ыт ыу ыф ых ыц ыч ыш ыщ ыъ ыы ыь ыэ ыю ыя ьа ьб ьв ьг ьд ье ьж ьз ьи ьй ьк ьл ьм ьн ьо ьп ьр ьс ьт ьу ьф ьх ьц ьч ьш ьщ ьъ ьы ьь ьэ ью ья эа эб эв эг эд эе эж эз эи эй эк эл эм эн эо эп эр эс эт эу эф эх эц эч эш эщ эъ эы эь ээ эю эя юа юб юв юг юд юе юж юз юи юй юк юл юм юн юо юп юр юс ют юу юф юх юц юч юш ющ юъ юы юь юэ юю юя яа яб яв яг яд яе яж яз яи яй як ял ям ян яо яп яр яс ят яу яф ях яц яч яш ящ яъ яы яь яэ яю яя",
+ "cite_references_link_many_format_backlink_labels": "а б в г д е ё ж з и й к л м н о п р с т у ф х ц ч ш щ ъ ы ь э ю я аа аб ав аг ад ае аё аж аз аи ай ак ал ам ан ао ап ар ас ат ау аф ах ац ач аш ащ аъ аы аь аэ аю ая ба бб бв бг бд бе бж бз би бй бк бл бм бн бо бп бр бс бт бу бф бх бц бч бш бщ бъ бы бь бэ бю бя ва вб вв вг вд ве вж вз ви вй вк вл вм вн во вп вр вс вт ву вф вх вц вч вш вщ въ вы вь вэ вю вя га гб гв гг гд ге гж гз ги гй гк гл гм гн го гп гр гс гт гу гф гх гц гч гш гщ гъ гы гь гэ гю гя да дб дв дг дд де дж дз ди дй дк дл дм дн до дп др дс дт ду дф дх дц дч дш дщ дъ ды дь дэ дю дя еа еб ев ег ед ее еж ез еи ей ек ел ем ен ео еп ер ес ет еу еф ех ец еч еш ещ еъ еы еь еэ ею ея жа жб жв жг жд же жж жз жи жй жк жл жм жн жо жп жр жс жт жу жф жх жц жч жш жщ жъ жы жь жэ жю жя за зб зв зг зд зе зж зз зи зй зк зл зм зн зо зп зр зс зт зу зф зх зц зч зш зщ зъ зы зь зэ зю зя иа иб ив иг ид ие иж из ии ий ик ил им ин ио ип ир ис ит иу иф их иц ич иш ищ иъ иы иь иэ ию ия йа йб йв йг йд йе йж йз йи йй йк йл йм йн йо йп йр йс йт йу йф йх йц йч йш йщ йъ йы йь йэ йю йя ка кб кв кг кд ке кж кз ки кй кк кл км кн ко кп кр кс кт ку кф кх кц кч кш кщ къ кы кь кэ кю кя ла лб лв лг лд ле лж лз ли лй лк лл лм лн ло лп лр лс лт лу лф лх лц лч лш лщ лъ лы ль лэ лю ля ма мб мв мг мд ме мж мз ми мй мк мл мм мн мо мп мр мс мт му мф мх мц мч мш мщ мъ мы мь мэ мю мя на нб нв нг нд не нж нз ни нй нк нл нм нн но нп нр нс нт ну нф нх нц нч нш нщ нъ ны нь нэ ню ня оа об ов ог од ое ож оз ои ой ок ол ом он оо оп ор ос от оу оф ох оц оч ош ощ оъ оы оь оэ ою оя па пб пв пг пд пе пж пз пи пй пк пл пм пн по пп пр пс пт пу пф пх пц пч пш пщ пъ пы пь пэ пю пя ра рб рв рг рд ре рж рз ри рй рк рл рм рн ро рп рр рс рт ру рф рх рц рч рш рщ ръ ры рь рэ рю ря са сб св сг сд се сж сз си сй ск сл см сн со сп ср сс ст су сф сх сц сч сш сщ съ сы сь сэ сю ся та тб тв тг тд те тж тз ти тй тк тл тм тн то тп тр тс тт ту тф тх тц тч тш тщ тъ ты ть тэ тю тя уа уб ув уг уд уе уж уз уи уй ук ул ум ун уо уп ур ус ут уу уф ух уц уч уш ущ уъ уы уь уэ ую уя фа фб фв фг фд фе фж фз фи фй фк фл фм фн фо фп фр фс фт фу фф фх фц фч фш фщ фъ фы фь фэ фю фя ха хб хв хг хд хе хж хз хи хй хк хл хм хн хо хп хр хс хт ху хф хх хц хч хш хщ хъ хы хь хэ хю хя ца цб цв цг цд це цж цз ци цй цк цл цм цн цо цп цр цс цт цу цф цх цц цч цш цщ цъ цы ць цэ цю ця ча чб чв чг чд че чж чз чи чй чк чл чм чн чо чп чр чс чт чу чф чх чц чч чш чщ чъ чы чь чэ чю чя ша шб шв шг шд ше шж шз ши шй шк шл шм шн шо шп шр шс шт шу шф шх шц шч шш шщ шъ шы шь шэ шю шя ща щб щв щг щд ще щж щз щи щй щк щл щм щн що щп щр щс щт щу щф щх щц щч щш щщ щъ щы щь щэ щю щя ъа ъб ъв ъг ъд ъе ъж ъз ъи ъй ък ъл ъм ън ъо ъп ър ъс ът ъу ъф ъх ъц ъч ъш ъщ ъъ ъы ъь ъэ ъю ъя ыа ыб ыв ыг ыд ые ыж ыз ыи ый ык ыл ым ын ыо ып ыр ыс ыт ыу ыф ых ыц ыч ыш ыщ ыъ ыы ыь ыэ ыю ыя ьа ьб ьв ьг ьд ье ьж ьз ьи ьй ьк ьл ьм ьн ьо ьп ьр ьс ьт ьу ьф ьх ьц ьч ьш ьщ ьъ ьы ьь ьэ ью ья эа эб эв эг эд эе эж эз эи эй эк эл эм эн эо эп эр эс эт эу эф эх эц эч эш эщ эъ эы эь ээ эю эя юа юб юв юг юд юе юж юз юи юй юк юл юм юн юо юп юр юс ют юу юф юх юц юч юш ющ юъ юы юь юэ юю юя яа яб яв яг яд яе яж яз яи яй як ял ям ян яо яп яр яс ят яу яф ях яц яч яш ящ яъ яы яь яэ яю яя",
"cite_references_link_many_sep": "&#32;",
"cite_references_link_many_and": "&#32;",
"cite_references_link_accessibility_label": "Перейти",
diff --git a/www/wiki/extensions/Cite/i18n/rue.json b/www/wiki/extensions/Cite/i18n/rue.json
index 90f58613..a4774a43 100644
--- a/www/wiki/extensions/Cite/i18n/rue.json
+++ b/www/wiki/extensions/Cite/i18n/rue.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Хыба в таґу <code>&lt;ref&gt;</code>; хыбны назвы, напр. є їх дуже много",
"cite_error_ref_no_input": "Хыба в таґу <code>&lt;ref&gt;</code>; цітації без назвы мусять мати властный обсяг",
"cite_error_references_invalid_parameters": "Хыба в таґу <code>&lt;references&gt;</code>; ту не є доволеный параметер, хоснуйте <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Не платный таґ <tt>&lt;references&gt;</tt>;\nє поволеный лем параметер „group“.\nХоснуйте <tt>&lt;references /&gt;</tt> або <tt>&lt;references group=\"...\" /&gt;</tt>.",
"cite_error_references_no_backlink_label": "Дішли означіня зворотных одказів, придайте їх пару до повідомлїня <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Дішли дефінованы значкы про ґрупу „$1“.\nЗвыште їх чісло у повідомлїню <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Хыба в таґу <code>&lt;ref&gt;</code>; цітації означеной <code>$1</code> не є доданый жаден текст",
diff --git a/www/wiki/extensions/Cite/i18n/sa.json b/www/wiki/extensions/Cite/i18n/sa.json
index 9f2c02ea..07e55bff 100644
--- a/www/wiki/extensions/Cite/i18n/sa.json
+++ b/www/wiki/extensions/Cite/i18n/sa.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "<code>&lt;ref&gt;</code> दोषपूर्णा शृङ्खला; \nअमान्यं नाम, उदा. अत्यधिकम्",
"cite_error_ref_no_input": "<code>&lt;ref&gt;</code> दोषपूर्णा शृङ्खला; \nरिक्ताधाराः अपि सनामकः भवेयुः ।",
"cite_error_references_invalid_parameters": "<code>&lt;references&gt;</code> असिद्धाङ्कनम्; परिमितिः निर्देष्टुम् अशक्या, <code>&lt;references /&gt;</code> उपयुज्यताम्",
- "cite_error_references_invalid_parameters_group": "<code>&lt;references&gt;</code> अयुक्तकूटप्रणाली;\nपरिमिति''गणः'' एव अनुमतः ।\n<code>&lt;references /&gt;</code> अथवा <code>&lt;references group=\"...\" /&gt;</code> उपयुज्यताम् ।",
"cite_error_references_no_backlink_label": "सिद्धानि पूर्वतनसम्पर्कशीर्षकाणि नष्टानि ।\n<nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> इत्यस्मिन् सन्देशे अधिकविवरणं योज्यताम् ।",
"cite_error_no_link_label_group": "\"$1\" आधारसमूहस्य कस्टं-सम्पर्क-लेबेल् न्यूनानि जातानि ।\n<nowiki>[[MediaWiki:$2]]</nowiki> सन्देशे अधिकं निर्वचनं दीयताम् ।",
"cite_error_references_no_text": "अमान्या <code>&lt;ref&gt;</code> शृङ्खला;\n<code>$1</code> इत्यस्य आधारः अज्ञातः",
diff --git a/www/wiki/extensions/Cite/i18n/sah.json b/www/wiki/extensions/Cite/i18n/sah.json
index b07d3f79..533b3e68 100644
--- a/www/wiki/extensions/Cite/i18n/sah.json
+++ b/www/wiki/extensions/Cite/i18n/sah.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "<code>&lt;ref&gt;</code> тиэк алҕаһа (Неправильный вызов): аата сыыһа ыйыллыбыт, эбэтэр наһаа элбэх аат суруллубут",
"cite_error_ref_no_input": "<code>&lt;ref&gt;</code> тиэк алҕастаах (Неверный вызов): иһинээҕитэ сыыһа",
"cite_error_references_invalid_parameters": "Сыыһа параметрдар бэриллибиттэр; <code>&lt;references /&gt;</code> тиэккэ отой суох буолуохтаахтар",
- "cite_error_references_invalid_parameters_group": "Сыыһалаах <code>&lt;references&gt;</code> тиэк;\n\"group\" эрэ парааматыры туһаныахха сөп.\nМаны <code>&lt;references /&gt;</code>, эбэтэр <code>&lt;references group=\"...\" /&gt;</code> туһан.",
"cite_error_references_no_backlink_label": "Төннөрөр сигэлэргэ бэлиэлэрэ тиийбэттэр.\n<nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> диэн систиэмэ этиитин кэҥэтэн биэрэххэ наада",
"cite_error_no_link_label_group": "«$1» бөлөх кыттааччыларын сигэлэрин бэлиэлэрэ бүппүттэр.\nЭбии манна <nowiki>[[MediaWiki:$2]]</nowiki> оҥор.",
"cite_error_references_no_text": "Сыыһа <code>&lt;ref&gt;</code> тиэк (тег);\n<code>$1</code> диэн хос быһаарыыларга аналлаах тиэкис суох",
diff --git a/www/wiki/extensions/Cite/i18n/sat.json b/www/wiki/extensions/Cite/i18n/sat.json
index 77d3e202..e1b4203a 100644
--- a/www/wiki/extensions/Cite/i18n/sat.json
+++ b/www/wiki/extensions/Cite/i18n/sat.json
@@ -1,8 +1,9 @@
{
"@metadata": {
"authors": [
- "Albinus"
+ "Albinus",
+ "Manik Soren"
]
},
- "cite_error": "Kath bhul:$1"
+ "cite_error": "ᱥᱟᱭᱤᱴ ᱵᱷᱩᱞ:$1"
}
diff --git a/www/wiki/extensions/Cite/i18n/scn.json b/www/wiki/extensions/Cite/i18n/scn.json
index 7542e25e..343d7785 100644
--- a/www/wiki/extensions/Cite/i18n/scn.json
+++ b/www/wiki/extensions/Cite/i18n/scn.json
@@ -15,7 +15,6 @@
"cite_error_ref_too_many_keys": "Etichetta <code>&lt;ref&gt;</code> nun bona;\nnoma nun vàlidi, p'es. nn'havi troppu assai",
"cite_error_ref_no_input": "Etichetta <code>&lt;ref&gt;</code> nun bona;\nli ref senza nomu hannu a aviri un cuntinutu",
"cite_error_references_invalid_parameters": "Etichetta <code>&lt;references&gt;</code> nun bona;\nnun vèninu accittati paràmitri.\nAdupirari <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Etichetta <code>&lt;references&gt;</code> nun bona;\nveni accittatu sulu lu paràmitru \"group\".\nAdupirari <code>&lt;references /&gt;</code>, o puru <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Fineru l'etichetti di rimannu p'arreri pirsunalizzati.\nDifinìrinni chiossai ntô missaggiu <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_no_link_label_group": "Fineru l'etichetti pirsunalizzati pî liami dû gruppu «$1».\nDifinirinni chiossai ntô missaggiu <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Etichetta <code>&lt;ref&gt;</code> nun bona;\nnun vinni furnutu nuddu testu pî ref cu nomu <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/sco.json b/www/wiki/extensions/Cite/i18n/sco.json
index a809ec41..e2525b66 100644
--- a/www/wiki/extensions/Cite/i18n/sco.json
+++ b/www/wiki/extensions/Cite/i18n/sco.json
@@ -5,6 +5,7 @@
]
},
"cite_error": "Cite error: $1",
+ "cite_error_references_duplicate_key": "Invalid <code>&lt;ref&gt;</code> tag; name \"$1\" defined multiple times wi different content",
"cite-tracking-category-cite-error": "Pages wi reference errors",
"cite_warning_sectionpreview_no_text": "<code>&lt;ref&gt;</code> tag wi name <code>$1</code> canna be previewed acause it is defined ootside the current section or nae defined at aw."
}
diff --git a/www/wiki/extensions/Cite/i18n/si.json b/www/wiki/extensions/Cite/i18n/si.json
index 953c8fea..287c86d9 100644
--- a/www/wiki/extensions/Cite/i18n/si.json
+++ b/www/wiki/extensions/Cite/i18n/si.json
@@ -14,7 +14,6 @@
"cite_error_ref_too_many_keys": "අනීතික <code>&lt;ref&gt;</code> ටැගය;\nඅනීතික නාමයන්, නිද. පමණට වැඩි",
"cite_error_ref_no_input": "අනීතික <code>&lt;ref&gt;</code> ටැගය;\nනාමයක් නොමැති ආශ්‍රේය සඳහා පෙළක් තිබිය යුතුය",
"cite_error_references_invalid_parameters": "අනීතික <code>&lt;references&gt;</code> ටැගය;\nකිසිම පරාමිතිකයකට ඉඩ නොදෙයි.\n<code>&lt;references /&gt;</code> භාවිත කරන්න",
- "cite_error_references_invalid_parameters_group": "අනීතික <code>&lt;references&gt;</code> ටැගය;\n\"කාණ්ඩය\" පරාමිතියට පමණක් ඉඩ දෙයි.\n<code>&lt;references /&gt;</code>, හෝ <code>&lt;references group=\"...\" /&gt;</code> භාවිත කරන්න",
"cite_error_references_no_backlink_label": "උපයෝග්‍ය පසුසබැඳුම් ලේබල අවසාන විය.\n<nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> පණිවුඩයෙහි තවත් ඒවා අර්ථදක්වන්න",
"cite_error_no_link_label_group": "\"$1\" කණ්ඩායම සඳහා අභිමත සබැඳි ලේබල අවසන් විය. \n<nowiki>[[MediaWiki:$2]]</nowiki> පණිවුඩයේ තවත් වැඩිපුර සඳහන් කරන්න.",
"cite_error_references_no_text": "අනීතික <code>&lt;ref&gt;</code> ටැගය;\n<code>$1</code> නමැති ආශ්‍රේයන් සඳහා කිසිදු පෙළක් සපයා නොතිබුණි",
diff --git a/www/wiki/extensions/Cite/i18n/sk.json b/www/wiki/extensions/Cite/i18n/sk.json
index ad1396c2..a2345a79 100644
--- a/www/wiki/extensions/Cite/i18n/sk.json
+++ b/www/wiki/extensions/Cite/i18n/sk.json
@@ -13,7 +13,6 @@
"cite_error_ref_no_input": "Neplatné volanie; nebol špecifikovaný vstup",
"cite_error_references_duplicate_key": "Neplatná značka <code>&lt;ref&gt;</code>; názov „$1“ je použitý viackrát s rôznym obsahom",
"cite_error_references_invalid_parameters": "Neplatné parametre; neočakávli sa žiadne",
- "cite_error_references_invalid_parameters_group": "Neplatná značka <code>&lt;references&gt;</code>;\nje povolený iba parameter „group“.\nPoužite <code>&lt;references /&gt;</code> alebo <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Minuli sa generované návestia spätných odkazov, definujte viac v správe <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Vyčerpané prispôsobené označenia odkazov pre skupinu „$1“.\nDefinujte ďalšie v správe <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Neplatná značka <code>&lt;ref&gt;</code>; nebol zadaný text pre referencie s názvom <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/sq.json b/www/wiki/extensions/Cite/i18n/sq.json
index 2136f8d1..b1cde506 100644
--- a/www/wiki/extensions/Cite/i18n/sq.json
+++ b/www/wiki/extensions/Cite/i18n/sq.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "Etiketë <code>&lt;ref&gt;</code> e pavlefshme;\nemra të pavlefshëm, p.sh. shumë",
"cite_error_ref_no_input": "Etiketë <code>&lt;ref&gt;</code> e pavlefshme;\nrefs pa emër duhet të kenë përmbajtje",
"cite_error_references_invalid_parameters": "Etiketë <code>&lt;references&gt;</code> e pavlefshme;\nasnjë parametër nuk lejohet.\nPërdorni <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Etiketë <code>&lt;references&gt;</code> e pavlefshme;\nvetëm parametri \"group\" lejohet.\nPërdorni <code>&lt;references /&gt;</code>, ose <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Nga ran të etiketave backlink me porosi. \nPercaktoni më shumë në <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> mesazh.",
"cite_error_no_link_label_group": "Nga ran e etiketave lidhje me porosi për grupin \"$1\". \nPercaktoni më shumë në <nowiki> [[MediaWiki:$2]] </nowiki> mesazh.",
"cite_error_references_no_text": "Etiketë <code>&lt;ref&gt;</code> e pavlefshme;\nasnjë tekst nuk u dha për refs e quajtura <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/sr-ec.json b/www/wiki/extensions/Cite/i18n/sr-ec.json
index d8193032..cef2e23a 100644
--- a/www/wiki/extensions/Cite/i18n/sr-ec.json
+++ b/www/wiki/extensions/Cite/i18n/sr-ec.json
@@ -7,33 +7,43 @@
"Михајло Анђелковић",
"Srdjan m",
"Сербијана",
- "Obsuser"
+ "Obsuser",
+ "Acamicamacaraca",
+ "BadDog"
]
},
"cite-desc": "Додаје <nowiki><ref[ name=id]></nowiki> и <nowiki><references/></nowiki> ознаке за цитирање.",
- "cite_error": "Грешка цитата: $1",
- "cite_error_ref_numeric_key": "Лоша ознака <code>&lt;ref&gt;</code>; име не може бити једноставни интеџер. Користи описни наслов.",
+ "cite_error": "Грешка код цитирања: $1",
+ "cite_error_ref_numeric_key": "Невалидан таг <code>&lt;ref&gt;</code>;\nиме не може да буде једноставан цели број. Користите описни наслов.",
"cite_error_ref_no_key": "Почетка ознака <code>&lt;ref&gt;</code> није исправно обликована или садржи неисправан назив",
"cite_error_ref_too_many_keys": "Лоша ознака <code>&lt;ref&gt;</code>; лоша имена, односно много њих.",
"cite_error_ref_no_input": "Лоша ознака <code>&lt;ref&gt;</code>; ref-ови без имена морају имати садржај.",
+ "cite_error_references_duplicate_key": "Неисправна <code>&lt;ref&gt;</code> ознака; име „$1“ је дефинисано више пута с различитим садржајем",
"cite_error_references_invalid_parameters": "Невалидан параметар у тагу <code>&lt;references&gt;</code>",
"cite_error_references_no_backlink_label": "Нестале су посебне ознаке за задње везе. Одреди их више у поруци <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
+ "cite_error_no_link_label_group": "Недовољан број произвољних наслова веза за групу „$1“.\nДефинишите више путем поруке <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Лоша ознака <code>&lt;ref&gt;</code>; нема текста за ref-ове под именом <code>$1</code>.",
- "cite_error_included_ref": "Затвара <code>&lt;/ref&gt;</code> који недостаје <code>&lt;ref&gt;</code> тагу",
+ "cite_error_included_ref": "Затвара <code><code>&lt;/ref&gt;</code></code> који недостаје <code>&lt;ref&gt;</code> ознаци",
"cite_error_group_refs_without_references": "Постоје ознаке <code>&lt;ref&gt;</code> за групу с именом „$1“, али нема одговарајуће ознаке <code>&lt;references group=\"$1\"/&gt;</code>, или затварајући <code>&lt;/ref&gt;</code> недостаје",
+ "cite_error_references_group_mismatch": "<code>&lt;ref&gt;</code> ознака у <code>&lt;references&gt;</code> има сукобни групни параметар „$1“.",
+ "cite_error_references_missing_group": "<code>&lt;ref&gt;</code> ознака дефинисана у <code>&lt;references&gt;</code> има групни параметар „$1“ који се не појављује у ранијем тексту.",
"cite_error_references_missing_key": "<code>&lt;ref&gt;</code> таг са именом „$1” дефинисан у <code>&lt;references&gt;</code> није употребљен у претходном тексту.",
- "cite-tracking-category-cite-error": "Странице са грешком у референцама",
- "cite-tracking-category-cite-error-desc": "Странице које имају грешке у коришћењу ознака референци.",
+ "cite_error_references_no_key": "<code>&lt;ref&gt;</code> ознака дефинисана у <code>&lt;references&gt;</code> нема параметар „name“ (име).",
+ "cite_error_empty_references_define": "<code>&lt;ref&gt;</code> ознака дефинисана у <code>&lt;references&gt;</code> с именом „$1“ нема никаквог садржаја.",
+ "cite-tracking-category-cite-error": "Странице са грешкама у референцама",
+ "cite-tracking-category-cite-error-desc": "Странице у овој категорији имају грешке у употреби ознаке референца.",
"cite_reference_link_key_with_num": "$1_$2",
"cite_reference_link_prefix": "cite_ref-",
"cite_references_link_prefix": "cite_note-",
"cite_references_link_one": "<li id=\"$1\"><span class=\"mw-cite-backlink\">[[#$2|↑]]</span> $3</li>",
"cite_references_link_many": "<li id=\"$1\"><span class=\"mw-cite-backlink\">↑ $2</span> $3</li>",
"cite_references_link_many_format": "<sup>[[#$1|$2]]</sup>",
- "cite_references_link_many_format_backlink_labels": "а б в г д ђ е ж з и ј к л љ м н њ о п р с т ћ у ф х ц ч џ ш аа аб ав аг ад ађ ае аж аз аи ај ак ал аљ ам ан ањ ао ап ар ас ат аћ ау аф ах ац ач аџ аш ба бб бв бг бд бђ бе бж бз би бј бк бл бљ бм бн бњ бо бп бр бс бт бћ бу бф бх бц бч бџ бш ва вб вв вг вд вђ ве вж вз ви вј вк вл вљ вм вн вњ во вп вр вс вт вћ ву вф вх вц вч вџ вш га гб гв гг гд гђ ге гж гз ги гј гк гл гљ гм гн гњ го гп гр гс гт гћ гу гф гх гц гч гџ гш да дб дв дг дд дђ де дж дз ди дј дк дл дљ дм дн дњ до дп др дс дт дћ ду дф дх дц дч дџ дш ђа ђб ђв ђг ђд ]] ђе ђж ђз ђи ђј ђк ђл ђљ ђм ђн ђњ ђо ђп ђр ђс ђт ђћ ђу ђф ђх ђц ђч ђџ ђш еа еб ев ег ед еђ ее еж ез еи еј ек ел ељ ем ен ењ ео еп ер ес ет ећ еу еф ех ец еч еџ еш жа жб жв жг жд жђ же жж жз жи жј жк жл жљ жм жн жњ жо жп жр жс жт жћ жу жф жх жц жч жџ жш за зб зв зг зд зђ зе зж зз зи зј зк зл зљ зм зн зњ зо зп зр зс зт зћ зу зф зх зц зч зџ зш иа иб ив иг ид иђ ие иж из ии иј ик ил иљ им ин ињ ио ип ир ис ит ић иу иф их иц ич иџ иш ја јб јв јг јд јђ је јж јз ји јј јк јл јљ јм јн јњ јо јп јр јс јт јћ ју јф јх јц јч јџ јш ка кб кв кг кд кђ ке кж кз ки кј кк кл кљ км кн књ ко кп кр кс кт кћ ку кф кх кц кч кџ кш ла лб лв лг лд лђ ле лж лз ли лј лк лл лљ лм лн лњ ло лп лр лс лт лћ лу лф лх лц лч лџ лш ља љб љв љг љд љђ ље љж љз љи љј љк љл љљ љм љн љњ љо љп љр љс љт љћ љу љф љх љц љч љџ љш ма мб мв мг мд мђ ме мж мз ми мј мк мл мљ мм мн мњ мо мп мр мс мт мћ му мф мх мц мч мџ мш на нб нв нг нд нђ не нж нз ни нј нк нл нљ нм нн нњ но нп нр нс нт нћ ну нф нх нц нч нџ нш ња њб њв њг њд њђ ње њж њз њи њј њк њл њљ њм њн њњ њо њп њр њс њт њћ њу њф њх њц њч њџ њш оа об ов ог од ођ ое ож оз ои ој ок ол ољ ом он оњ оо оп ор ос от оћ оу оф ох оц оч оџ ош па пб пв пг пд пђ пе пж пз пи пј пк пл пљ пм пн пњ по пп пр пс пт пћ пу пф пх пц пч пџ пш ра рб рв рг рд рђ ре рж рз ри рј рк рл рљ рм рн рњ ро рп рр рс рт рћ ру рф рх рц рч рџ рш са сб св сг сд сђ се сж сз си сј ск сл сљ см сн сњ со сп ср сс ст сћ су сф сх сц сч сџ сш та тб тв тг тд тђ те тж тз ти тј тк тл тљ тм тн тњ то тп тр тс тт тћ ту тф тх тц тч тџ тш ћа ћб ћв ћг ћд ћђ ће ћж ћз ћи ћј ћк ћл ћљ ћм ћн ћњ ћо ћп ћр ћс ћт ћћ ћу ћф ћх ћц ћч ћџ ћш уа уб ув уг уд уђ уе уж уз уи уј ук ул уљ ум ун уњ уо уп ур ус ут ућ уу уф ух уц уч уџ уш фа фб фв фг фд фђ фе фж фз фи фј фк фл фљ фм фн фњ фо фп фр фс фт фћ фу фф фх фц фч фџ фш ха хб хв хг хд хђ хе хж хз хи хј хк хл хљ хм хн хњ хо хп хр хс хт хћ ху хф хх хц хч хџ хш ца цб цв цг цд цђ це цж цз ци цј цк цл цљ цм цн цњ цо цп цр цс цт цћ цу цф цх цц цч цџ цш ча чб чв чг чд чђ че чж чз чи чј чк чл чљ чм чн чњ чо чп чр чс чт чћ чу чф чх чц чч чџ чш џа џб џв џг џд џђ џе џж џз џи џј џк џл џљ џм џн џњ џо џп џр џс џт џћ џу џф џх џц џч џџ џш ша шб шв шг шд шђ ше шж шз ши шј шк шл шљ шм шн шњ шо шп шр шс шт шћ шу шф шх шц шч шџ шш",
+ "cite_references_link_many_format_backlink_labels": "а б в г д ђ е ж з и ј к л љ м н њ о п р с т ћ у ф х ц ч џ ш аа аб ав аг ад ађ ае аж аз аи ај ак ал аљ ам ан ањ ао ап ар ас ат аћ ау аф ах ац ач аџ аш ба бб бв бг бд бђ бе бж бз би бј бк бл бљ бм бн бњ бо бп бр бс бт бћ бу бф бх бц бч бџ бш ва вб вв вг вд вђ ве вж вз ви вј вк вл вљ вм вн вњ во вп вр вс вт вћ ву вф вх вц вч вџ вш га гб гв гг гд гђ ге гж гз ги гј гк гл гљ гм гн гњ го гп гр гс гт гћ гу гф гх гц гч гџ гш да дб дв дг дд дђ де дж дз ди дј дк дл дљ дм дн дњ до дп др дс дт дћ ду дф дх дц дч дџ дш ђа ђб ђв ђг ђд ђђ ђе ђж ђз ђи ђј ђк ђл ђљ ђм ђн ђњ ђо ђп ђр ђс ђт ђћ ђу ђф ђх ђц ђч ђџ ђш еа еб ев ег ед еђ ее еж ез еи еј ек ел ељ ем ен ењ ео еп ер ес ет ећ еу еф ех ец еч еџ еш жа жб жв жг жд жђ же жж жз жи жј жк жл жљ жм жн жњ жо жп жр жс жт жћ жу жф жх жц жч жџ жш за зб зв зг зд зђ зе зж зз зи зј зк зл зљ зм зн зњ зо зп зр зс зт зћ зу зф зх зц зч зџ зш иа иб ив иг ид иђ ие иж из ии иј ик ил иљ им ин ињ ио ип ир ис ит ић иу иф их иц ич иџ иш ја јб јв јг јд јђ је јж јз ји јј јк јл јљ јм јн јњ јо јп јр јс јт јћ ју јф јх јц јч јџ јш ка кб кв кг кд кђ ке кж кз ки кј кк кл кљ км кн књ ко кп кр кс кт кћ ку кф кх кц кч кџ кш ла лб лв лг лд лђ ле лж лз ли лј лк лл лљ лм лн лњ ло лп лр лс лт лћ лу лф лх лц лч лџ лш ља љб љв љг љд љђ ље љж љз љи љј љк љл љљ љм љн љњ љо љп љр љс љт љћ љу љф љх љц љч љџ љш ма мб мв мг мд мђ ме мж мз ми мј мк мл мљ мм мн мњ мо мп мр мс мт мћ му мф мх мц мч мџ мш на нб нв нг нд нђ не нж нз ни нј нк нл нљ нм нн нњ но нп нр нс нт нћ ну нф нх нц нч нџ нш ња њб њв њг њд њђ ње њж њз њи њј њк њл њљ њм њн њњ њо њп њр њс њт њћ њу њф њх њц њч њџ њш оа об ов ог од ођ ое ож оз ои ој ок ол ољ ом он оњ оо оп ор ос от оћ оу оф ох оц оч оџ ош па пб пв пг пд пђ пе пж пз пи пј пк пл пљ пм пн пњ по пп пр пс пт пћ пу пф пх пц пч пџ пш ра рб рв рг рд рђ ре рж рз ри рј рк рл рљ рм рн рњ ро рп рр рс рт рћ ру рф рх рц рч рџ рш са сб св сг сд сђ се сж сз си сј ск сл сљ см сн сњ со сп ср сс ст сћ су сф сх сц сч сџ сш та тб тв тг тд тђ те тж тз ти тј тк тл тљ тм тн тњ то тп тр тс тт тћ ту тф тх тц тч тџ тш ћа ћб ћв ћг ћд ћђ ће ћж ћз ћи ћј ћк ћл ћљ ћм ћн ћњ ћо ћп ћр ћс ћт ћћ ћу ћф ћх ћц ћч ћџ ћш уа уб ув уг уд уђ уе уж уз уи уј ук ул уљ ум ун уњ уо уп ур ус ут ућ уу уф ух уц уч уџ уш фа фб фв фг фд фђ фе фж фз фи фј фк фл фљ фм фн фњ фо фп фр фс фт фћ фу фф фх фц фч фџ фш ха хб хв хг хд хђ хе хж хз хи хј хк хл хљ хм хн хњ хо хп хр хс хт хћ ху хф хх хц хч хџ хш ца цб цв цг цд цђ це цж цз ци цј цк цл цљ цм цн цњ цо цп цр цс цт цћ цу цф цх цц цч цџ цш ча чб чв чг чд чђ че чж чз чи чј чк чл чљ чм чн чњ чо чп чр чс чт чћ чу чф чх чц чч чџ чш џа џб џв џг џд џђ џе џж џз џи џј џк џл џљ џм џн џњ џо џп џр џс џт џћ џу џф џх џц џч џџ џш ша шб шв шг шд шђ ше шж шз ши шј шк шл шљ шм шн шњ шо шп шр шс шт шћ шу шф шх шц шч шџ шш",
"cite_references_link_many_sep": "&#32;",
"cite_references_link_many_and": "&#32;",
- "cite_section_preview_references": "Преглед референци",
+ "cite_references_link_accessibility_label": "Врати се на врх",
+ "cite_references_link_many_accessibility_label": "Врати се на:",
+ "cite_section_preview_references": "Претпреглед референци",
"cite_warning": "Упозорење за референцирање: $1",
"cite_warning_sectionpreview_no_text": "<code>&lt;ref&gt;</code> таг са именом <code>$1</code> не може да се прикаже у претпрегледу јер је дефинисан ван тренутног одељка или није уопште дефинисан."
}
diff --git a/www/wiki/extensions/Cite/i18n/sr-el.json b/www/wiki/extensions/Cite/i18n/sr-el.json
index aacabd27..198baa74 100644
--- a/www/wiki/extensions/Cite/i18n/sr-el.json
+++ b/www/wiki/extensions/Cite/i18n/sr-el.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "Loša oznaka <code>&amp;lt;ref&amp;gt;</code>; loša imena, odnosno mnogo njih.",
"cite_error_ref_no_input": "Loša oznaka <code>&amp;lt;ref&amp;gt;</code>; ref-ovi bez imena moraju imati sadržaj.",
"cite_error_references_invalid_parameters": "Loša oznaka <code>&amp;lt;references&amp;gt;</code>; parametri nisu dozvoljeni. Koristi <code>&amp;lt;references /&amp;gt;</code>.",
- "cite_error_references_invalid_parameters_group": "Loša oznaka <code>&amp;lt;references&amp;gt;</code>; samo je paramtera &quot;group&quot; dozvoljen. Koristi <code>&amp;lt;references /&amp;gt;</code> ili <code>&amp;lt;references group=&quot;...&quot;&amp;gt;</code>.",
"cite_error_references_no_backlink_label": "Nestale su posebne oznake za zadnje veze. Odredi ih više u poruci <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>.",
"cite_error_references_no_text": "Loša oznaka <code>&amp;lt;ref&amp;gt;</code>; nema teksta za ref-ove pod imenom <code>$1</code>.",
"cite_error_included_ref": "Zatvara <code>&lt;/ref&gt;</code> koji nedostaje <code>&lt;ref&gt;</code> tagu",
diff --git a/www/wiki/extensions/Cite/i18n/stq.json b/www/wiki/extensions/Cite/i18n/stq.json
index 31e3d772..ace1303c 100644
--- a/www/wiki/extensions/Cite/i18n/stq.json
+++ b/www/wiki/extensions/Cite/i18n/stq.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Uungultige <code><nowiki><ref></nowiki></code>-Ferweendenge: „name“ is uungultich of tou loang.",
"cite_error_ref_no_input": "Uungultige <code><nowiki><ref></nowiki></code>-Ferweendenge: „ref“ sunner Noome mout n Inhoold hääbe.",
"cite_error_references_invalid_parameters": "Uungultige <code><nowiki><reference></nowiki></code>-Ferweendenge: Der sunt neen bietoukuumende Parametere ferlööwed, ferweend bloot <code><nowiki><reference /></nowiki></code>.",
- "cite_error_references_invalid_parameters_group": "Ungultige <code>&lt;references&gt;</code>-Ferweendenge: Bloot die Parameter „group“ is ferlööwed, ferweend <tt>&lt;references /&gt;</tt> of <tt>&lt;references group=\"...\" /&gt;</tt>",
"cite_error_references_no_backlink_label": "Ne Referenz fon ju Foarm <code><nowiki><ref name=\"...\"/></nowiki></code> wäd oafter benutsed as Bouksteeuwen deer sunt. N Administrator mout <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> uum wiedere Bouksteeuwen/Teekene ferfulständigje.",
"cite_error_references_no_text": "Uungultigen <code>&lt;ref&gt;</code>-Tag; der wuude naan Text foar dät Ref mäd dän Noome <code>$1</code> anroat.",
"cite_error_included_ref": "Der failt n sluutend <code>&lt;/ref&gt;</code>",
diff --git a/www/wiki/extensions/Cite/i18n/sv.json b/www/wiki/extensions/Cite/i18n/sv.json
index 0438ae87..9359b02c 100644
--- a/www/wiki/extensions/Cite/i18n/sv.json
+++ b/www/wiki/extensions/Cite/i18n/sv.json
@@ -40,7 +40,7 @@
"cite-tracking-category-cite-error-desc": "Sidor i denna kategori har fel i sin användning av referens-taggar.",
"cite_references_link_accessibility_label": "Hoppa upp",
"cite_references_link_many_accessibility_label": "Hoppa upp till:",
- "cite_section_preview_references": "Förhandsvisning av referenser",
+ "cite_section_preview_references": "Förhandsgranskning av referenser",
"cite_warning": "Referensvarning: $1",
- "cite_warning_sectionpreview_no_text": "<code>&lt;ref&gt;</code>-tagg med namn <code>$1</code> kan inte förhandsvisas då den definierats utanför det aktuella avsnittet eller inte har definierats alls."
+ "cite_warning_sectionpreview_no_text": "Taggen <code>&lt;ref&gt;</code> med namnet <code>$1</code> kan inte förhandsgranskas då den definieras utanför det aktuella avsnittet eller inte har definierats alls."
}
diff --git a/www/wiki/extensions/Cite/i18n/tg-cyrl.json b/www/wiki/extensions/Cite/i18n/tg-cyrl.json
index 93f37d07..ea39067b 100644
--- a/www/wiki/extensions/Cite/i18n/tg-cyrl.json
+++ b/www/wiki/extensions/Cite/i18n/tg-cyrl.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Ibrahim",
- "ToJack"
+ "ToJack",
+ "Vashgird"
]
},
"cite-desc": "Барчасбҳои <nowiki><ref[ name=id]></nowiki> ва <nowiki><references/></nowiki> барои ёд кардан, изофа мекунад",
@@ -10,7 +11,7 @@
"cite_error_ref_numeric_key": "Барчасби <code>&lt;ref&gt;</code> ғайримиҷоз; ном наметавонад як адад бошад, унвони возеҳтареро истифода кунед",
"cite_error_ref_no_key": "Барчасби <code>&lt;ref&gt;</code> ғайримиҷоз; ёдкардҳо бидуни мӯҳтаво бояд ном дошта бошанд",
"cite_error_ref_too_many_keys": "Барчасби <code>&lt;ref&gt;</code> ғайримиҷоз; номҳои ғайримиҷоз ё беш аз андоза",
- "cite_error_ref_no_input": "Барчасби <code>&lt;ref&gt;</code> ғайримиҷоз; ёдкардҳои бидуни ном бояд мӯҳтаво дошта бошанд",
+ "cite_error_ref_no_input": "Барчасби <code>&lt;ref&gt;</code> ғайримуҷоз; ёдкардҳои бидуни ном бояд муҳтаво дошта бошанд",
"cite_error_references_invalid_parameters": "Барчасби <code>&lt;references&gt;</code> ғайримиҷоз; истифода аз параметр миҷоз аст, аз <code>&lt;references /&gt;</code> истифода кунед",
"cite_error_references_no_backlink_label": "Барчасбҳои пайванд ба интиҳо расид, мавориди ҷадидро дар пайғоми <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> истифода кунед",
"cite_error_references_no_text": "Барчасби <code>&lt;ref&gt;</code> ғайримиҷоз; матне барои ёдкардҳо бо номи <code>$1</code> ворид нашудааст"
diff --git a/www/wiki/extensions/Cite/i18n/tg-latn.json b/www/wiki/extensions/Cite/i18n/tg-latn.json
index 6f286d63..0cb38e02 100644
--- a/www/wiki/extensions/Cite/i18n/tg-latn.json
+++ b/www/wiki/extensions/Cite/i18n/tg-latn.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Barcasbi <code>&lt;ref&gt;</code> ƣajrimiçoz; nomhoi ƣajrimiçoz jo beş az andoza",
"cite_error_ref_no_input": "Barcasbi <code>&lt;ref&gt;</code> ƣajrimiçoz; jodkardhoi biduni nom bojad mūhtavo doşta boşand",
"cite_error_references_invalid_parameters": "Barcasbi <code>&lt;references&gt;</code> ƣajrimiçoz; istifoda az parametr miçoz ast, az <code>&lt;references /&gt;</code> istifoda kuned",
- "cite_error_references_invalid_parameters_group": "Barcasbi <code>&lt;references&gt;</code> nomū'tabar;\nparametri \"gurūh\" tanho içozaşuda ast.\nBarcasbi <code>&lt;references /&gt;</code> jo <code>&lt;references group=\"...\" /&gt;</code> -ro istifoda bared",
"cite_error_references_no_backlink_label": "Barcasbhoi pajvand ba intiho rasid, mavoridi çadidro dar pajjom <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> istifoda kuned",
"cite_error_references_no_text": "Barcasbi <code>&lt;ref&gt;</code> ƣajrimiçoz; matne baroi jodkardho bo nomi <code>$1</code> vorid naşudaast"
}
diff --git a/www/wiki/extensions/Cite/i18n/th.json b/www/wiki/extensions/Cite/i18n/th.json
index 779255c7..b03f1ed4 100644
--- a/www/wiki/extensions/Cite/i18n/th.json
+++ b/www/wiki/extensions/Cite/i18n/th.json
@@ -13,7 +13,6 @@
"cite_error_ref_no_input": "ป้ายระบุ <code>&lt;ref&gt;</code> ไม่ถูกต้อง\nอ้างอิงที่ไม่มีชื่อต้องมีเนื้อหา",
"cite_error_references_duplicate_key": "ป้ายระบุ <code>&lt;ref&gt;</code> ไม่สมเหตุสมผล มีนิยามชื่อ \"$1\" หลายครั้งด้วยเนื้อหาต่างกัน",
"cite_error_references_invalid_parameters": "ป้ายระบุ <code>&lt;references&gt;</code> ไม่ถูกต้อง\nไม่อนุญาตให้มีพารามิเตอร์\nให้ใช้ <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "ป้ายระบุ <code>&lt;references&gt;</code> ไม่ถูกต้อง\nอนุญาตเฉพาะพารามิเตอร์ \"group\"\nให้ใช้ <code>&lt;references /&gt;</code> หรือ <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_text": "ป้ายระบุ <code>&lt;ref&gt;</code> ไม่ถูกต้อง\nไม่มีการกำหนดข้อความสำหรับอ้างอิงชื่อ <code>$1</code>",
"cite_error_included_ref": "ไม่มีการปิด <code>&lt;/ref&gt;</code> สำหรับป้ายระบุ <code>&lt;ref&gt;</code>",
"cite_error_group_refs_without_references": "มีป้ายระบุ <code>&lt;ref&gt;</code> สำหรับกลุ่มชื่อ \"$1\" แต่ไม่พบป้ายระบุ <code>&lt;references group=\"$1\"/&gt;</code> ที่สอดคล้องกัน หรือไม่มีการปิด <code>&lt;/ref&gt;</code>",
diff --git a/www/wiki/extensions/Cite/i18n/tl.json b/www/wiki/extensions/Cite/i18n/tl.json
index 178acacb..4cebf224 100644
--- a/www/wiki/extensions/Cite/i18n/tl.json
+++ b/www/wiki/extensions/Cite/i18n/tl.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Hindi tanggap ang tatak na <code>&lt;ref&gt;</code>;\nhindi tanggap na mga pangalan, ang ibig sabihin ay napakarami",
"cite_error_ref_no_input": "Hindi tanggap ang tatak na <code>&lt;ref&gt;</code>;\nkinakailangang may nilalaman ang mga sangguniang (''ref'') walang pangalan",
"cite_error_references_invalid_parameters": "Hindi tanggap na <code>&lt;references&gt;</code>;\nwalang pinapahintulutang mga parametro.\nGamitin ang <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Hindi tanggap ang tatak na <code>&lt;references&gt;</code>;\nPinapahintulutan lamang ang parametrong \"pangkat\" (''group'').\nGamitin ang <code>&lt;references /&gt;</code>, o <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Naubusan ng pasadyang mga tatak na pantukoy ng panlikod na kawing.\nDagdagan pa ng pakahulugan sa loob ng mensaheng <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Naubusan ng mga tatak ng pasadyang kawing para sa pangkat na \"$1\".\nMagbigay ng marami pang kahulugan sa loob ng mensaheng <nowiki>[[MediaWiki:$2]]</nowiki>.",
"cite_error_references_no_text": "Hindi tanggap ang tatak na <code>&lt;ref&gt;</code>;\nwalang tekstong ibinigay para sa mga sangguniang (''ref'') pinangalanang <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/ur.json b/www/wiki/extensions/Cite/i18n/ur.json
index 3b40d29f..d8c33fd1 100644
--- a/www/wiki/extensions/Cite/i18n/ur.json
+++ b/www/wiki/extensions/Cite/i18n/ur.json
@@ -3,14 +3,22 @@
"authors": [
"عثمان خان شاہ",
"Obaid Raza",
- "Muhammad Shuaib"
+ "Muhammad Shuaib",
+ "BukhariSaeed"
]
},
+ "apihelp-query+references-example-1": "<kbd>البرٹ آئنسٹائن</kbd> متعلقہ حوالہ جات",
"cite-desc": "<nowiki><ref[ name=id]></nowiki> اور <nowiki><references/></nowiki> ٹیگز، برائے حوالہ جات کا اضافہ کرتا ہے",
"cite_error": "خطا در حوالہ: $1",
+ "cite_error_ref_too_many_keys": "نادرست <code>&lt;ref&gt;</code> ٹیگ؛\nنادرست نام، مثال کے طور پر کئی",
+ "cite_error_ref_no_input": "نادرست <code>&lt;ref&gt;</code> ٹیگ;\nبے نام حوالہ جات کا مواد ہونا چاہیے",
+ "cite_error_references_duplicate_key": "نادرست <code>&lt;ref&gt;</code> ٹیگ؛ نام \"$1\" مختلف مواد کے ساتھ کئی بار استعمال ہوا ہے۔",
+ "cite_error_references_invalid_parameters": "نادرست پیرامیٹر در <code>&lt;references&gt;</code> ٹیگ",
+ "cite_error_references_no_text": "ناقص <code>&lt;ref&gt;</code> ٹیگ؛ <code>$1</code> کے نام والے حوالوں کے لیے کوئی متن نہیں دیا گیا",
"cite-tracking-category-cite-error": "صفحات مع حوالہ جاتی اغلاط",
"cite-tracking-category-cite-error-desc": "اس زمرہ میں موجود صفحات میں حوالہ جاتی ٹیگز کو غلط استعمال کیا گیا ہے۔",
"cite_references_link_accessibility_label": "اوپر جائیں",
"cite_references_link_many_accessibility_label": "اس تک اوپر جائیں:",
- "cite_section_preview_references": "حوالہ جات کی نما‏ئش"
+ "cite_section_preview_references": "حوالہ جات کی نما‏ئش",
+ "cite_warning": "انتباہ حوالہ: $1"
}
diff --git a/www/wiki/extensions/Cite/i18n/vec.json b/www/wiki/extensions/Cite/i18n/vec.json
index 6285fa7d..a703edcf 100644
--- a/www/wiki/extensions/Cite/i18n/vec.json
+++ b/www/wiki/extensions/Cite/i18n/vec.json
@@ -11,7 +11,6 @@
"cite_error_ref_too_many_keys": "Eror ne l'uso del marcator <code>&lt;ref&gt;</code>: nomi mìa validi (ad es. nùmaro massa elevà)",
"cite_error_ref_no_input": "Eror ne l'uso del marcator <code>&lt;ref&gt;</code>: i ref che no gà un nome no i pol mìa èssar vodi",
"cite_error_references_invalid_parameters": "Eror ne l'uso del marcator <code>&lt;references&gt;</code>: parametri mìa consentìi, dòpara el marcator <code>&lt;references /&gt;</code>",
- "cite_error_references_invalid_parameters_group": "Tag <code>&lt;references&gt;</code> mìa valido;\nsolo el parametro \"group\" el xe permesso.\nDòpara <code>&lt;references /&gt;</code>, o <code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "Etichete de rimando personalizàe esaurìe, auménteghen el nùmaro nel messagio <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki>",
"cite_error_no_link_label_group": "Etichete esaurìe par colegamenti personalizà del grupo \"$1\", aumentarne el numaro nel messajo <nowiki>[[MediaWiki:$2]]</nowiki>",
"cite_error_references_no_text": "Marcator <code>&lt;ref&gt;</code> mìa valido; no xe stà indicà nissun testo par el marcator <code>$1</code>",
diff --git a/www/wiki/extensions/Cite/i18n/yo.json b/www/wiki/extensions/Cite/i18n/yo.json
index c0a084ca..6c195240 100644
--- a/www/wiki/extensions/Cite/i18n/yo.json
+++ b/www/wiki/extensions/Cite/i18n/yo.json
@@ -1,8 +1,9 @@
{
"@metadata": {
"authors": [
- "Wikicology"
+ "Wikicology",
+ "Demmy"
]
},
- "cite_error": "Àṣìṣe"
+ "cite_error": "Àṣìṣe ìtọ́kasí: $1"
}
diff --git a/www/wiki/extensions/Cite/i18n/yue.json b/www/wiki/extensions/Cite/i18n/yue.json
index cbb730cb..1a1b99a1 100644
--- a/www/wiki/extensions/Cite/i18n/yue.json
+++ b/www/wiki/extensions/Cite/i18n/yue.json
@@ -12,7 +12,6 @@
"cite_error_ref_too_many_keys": "無效嘅呼叫; 無效嘅匙, 例如: 太多或者指定咗一個錯咗嘅匙",
"cite_error_ref_no_input": "無效嘅呼叫; 未指定輸入",
"cite_error_references_invalid_parameters": "無效嘅參數; 唔需要有嘢",
- "cite_error_references_invalid_parameters_group": "無效嘅<code>&lt;references&gt;</code>標籤;\n只容許 \"group\" 參數。\n用<code>&lt;references /&gt;</code>,或<code>&lt;references group=\"...\" /&gt;</code>",
"cite_error_references_no_backlink_label": "用晒啲自定返回標籤, 響 <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> 信息再整多啲",
"cite_error_references_no_text": "無效嘅<code>&lt;ref&gt;</code>標籤;\n無文字提供於名為<code>$1</code>嘅參照",
"cite_references_link_accessibility_label": "跳到",
diff --git a/www/wiki/extensions/Cite/i18n/zh-hant.json b/www/wiki/extensions/Cite/i18n/zh-hant.json
index 0529313a..e57c58db 100644
--- a/www/wiki/extensions/Cite/i18n/zh-hant.json
+++ b/www/wiki/extensions/Cite/i18n/zh-hant.json
@@ -9,9 +9,14 @@
"Cwlin0416",
"Bowleerin",
"Waihorace",
- "Wbxshiori"
+ "Wbxshiori",
+ "Kly"
]
},
+ "apihelp-query+references-description": "回傳與指定頁面關聯之參考文獻的資料描述。",
+ "apihelp-query+references-summary": "回傳與指定頁面關聯之參考文獻的資料描述。",
+ "apihelp-query+references-example-1": "與 <kbd>Albert Einstein</kbd> 關聯的參考文獻。",
+ "apierror-citestoragedisabled": "引用擴充參考文獻儲存未啟用。",
"cite-desc": "支援 <nowiki><ref[ name=id]></nowiki> 與 <nowiki><references/></nowiki> 標籤,可用來註明參考文獻",
"cite_error": "引用錯誤:$1",
"cite_error_ref_numeric_key": "無效的 <code>&lt;ref&gt;</code> 標籤,name 屬性不能使用數字,請使用可描述內容的標題",
@@ -19,7 +24,7 @@
"cite_error_ref_too_many_keys": "無效的 <code>&lt;ref&gt;</code> 標籤,無效的 name 屬性值,可能名稱過長",
"cite_error_ref_no_input": "無效的 <code>&lt;ref&gt;</code> 標籤,無 name 屬性則必須擁有標籤內容",
"cite_error_references_duplicate_key": "無效的<code>&lt;ref&gt;</code>標籤;name屬性“$1”使用不同內容定義了多次",
- "cite_error_references_invalid_parameters": "無效的 <code>&lt;references&gt;</code> 標籤,不允許使用參數。\n請使用 <code>&lt;references /&gt;</code>",
+ "cite_error_references_invalid_parameters": "在 <code>&lt;references&gt;</code> 標籤裡的無效參數",
"cite_error_references_no_backlink_label": "自訂反向連結標籤符號已用盡。\n請在 <nowiki>[[MediaWiki:Cite references link many format backlink labels]]</nowiki> 中定義更多的標籤符號。",
"cite_error_no_link_label_group": "群組 \"$1\" 的自訂連結標籤符號已用盡。\n請在 <nowiki>[[MediaWiki:$2]]</nowiki> 中定義更多的標籤符號。",
"cite_error_references_no_text": "無效的 <code>&lt;ref&gt;</code> 標籤,\n未定義名稱為 <code>$1</code> 的參考文獻內容文字。",
diff --git a/www/wiki/extensions/Cite/includes/ApiQueryReferences.php b/www/wiki/extensions/Cite/includes/ApiQueryReferences.php
index 20901597..ddde9563 100644
--- a/www/wiki/extensions/Cite/includes/ApiQueryReferences.php
+++ b/www/wiki/extensions/Cite/includes/ApiQueryReferences.php
@@ -21,6 +21,8 @@
* @see https://www.mediawiki.org/wiki/Extension:Cite#API
*/
+use MediaWiki\MediaWikiServices;
+
class ApiQueryReferences extends ApiQueryBase {
public function __construct( $query, $moduleName ) {
@@ -36,13 +38,9 @@ class ApiQueryReferences extends ApiQueryBase {
}
public function execute() {
- $config = ConfigFactory::getDefaultInstance()->makeConfig( 'cite' );
+ $config = MediaWikiServices::getInstance()->getConfigFactory()->makeConfig( 'cite' );
if ( !$config->get( 'CiteStoreReferencesData' ) ) {
- if ( is_callable( [ $this, 'dieWithError' ] ) ) {
- $this->dieWithError( 'apierror-citestoragedisabled' );
- } else {
- $this->dieUsage( 'Cite extension reference storage is not enabled', 'citestoragedisabled' );
- }
+ $this->dieWithError( 'apierror-citestoragedisabled' );
}
$params = $this->extractRequestParams();
$titles = $this->getPageSet()->getGoodTitles();
@@ -95,12 +93,19 @@ class ApiQueryReferences extends ApiQueryBase {
}
}
+ /**
+ * Get the cache mode for the data generated by this module.
+ *
+ * @param array $params
+ * @return string
+ */
public function getCacheMode( $params ) {
return 'public';
}
/**
* @see ApiBase::getExamplesMessages()
+ * @return array
*/
protected function getExamplesMessages() {
return [
diff --git a/www/wiki/extensions/Cite/includes/Cite.php b/www/wiki/extensions/Cite/includes/Cite.php
index 69a0f990..b6fbd8ef 100644
--- a/www/wiki/extensions/Cite/includes/Cite.php
+++ b/www/wiki/extensions/Cite/includes/Cite.php
@@ -19,9 +19,13 @@
*
* @author Ævar Arnfjörð Bjarmason <avarab@gmail.com>
* @copyright Copyright © 2005, Ævar Arnfjörð Bjarmason
- * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later
+ * @license GPL-2.0-or-later
*/
+use MediaWiki\MediaWikiServices;
+use Wikimedia\Rdbms\IDatabase;
+use Wikimedia\Rdbms\Database;
+
/**
* WARNING: MediaWiki core hardcodes this class name to check if the
* Cite extension is installed. See T89151.
@@ -269,12 +273,18 @@ class Cite {
if ( $group != $this->mReferencesGroup ) {
# <ref> and <references> have conflicting group attributes.
$this->mReferencesErrors[] =
- $this->error( 'cite_error_references_group_mismatch', htmlspecialchars( $group ) );
+ $this->error(
+ 'cite_error_references_group_mismatch',
+ Sanitizer::safeEncodeAttribute( $group )
+ );
} elseif ( $str !== '' ) {
if ( !$isSectionPreview && !isset( $this->mRefs[$group] ) ) {
# Called with group attribute not defined in text.
$this->mReferencesErrors[] =
- $this->error( 'cite_error_references_missing_group', htmlspecialchars( $group ) );
+ $this->error(
+ 'cite_error_references_missing_group',
+ Sanitizer::safeEncodeAttribute( $group )
+ );
} elseif ( $key === null || $key === '' ) {
# <ref> calls inside <references> must be named
$this->mReferencesErrors[] =
@@ -282,7 +292,7 @@ class Cite {
} elseif ( !$isSectionPreview && !isset( $this->mRefs[$group][$key] ) ) {
# Called with name attribute not defined in text.
$this->mReferencesErrors[] =
- $this->error( 'cite_error_references_missing_key', $key );
+ $this->error( 'cite_error_references_missing_key', Sanitizer::safeEncodeAttribute( $key ) );
} else {
if (
isset( $this->mRefs[$group][$key]['text'] ) &&
@@ -301,7 +311,7 @@ class Cite {
} else {
# <ref> called in <references> has no content.
$this->mReferencesErrors[] =
- $this->error( 'cite_error_empty_references_define', $key );
+ $this->error( 'cite_error_empty_references_define', Sanitizer::safeEncodeAttribute( $key ) );
}
return '';
}
@@ -331,7 +341,9 @@ class Cite {
return $this->error( 'cite_error_ref_no_key' );
}
- if ( preg_match( '/^[0-9]+$/', $key ) || preg_match( '/^[0-9]+$/', $follow ) ) {
+ if ( is_string( $key ) && preg_match( '/^[0-9]+$/', $key ) ||
+ is_string( $follow ) && preg_match( '/^[0-9]+$/', $follow )
+ ) {
# Numeric names mess up the resulting id's, potentially produ-
# cing duplicate id's in the XHTML. The Right Thing To Do
# would be to mangle them, but it's not really high-priority
@@ -382,7 +394,6 @@ class Cite {
* "group" : Group to which it belongs. Needs to be passed to <references /> too.
* "follow" : If the current reference is the continuation of another, key of that reference.
*
- *
* @param string[] $argv The argument vector
* @return mixed false on invalid input, a string on valid
* input and null on no input
@@ -403,13 +414,13 @@ class Cite {
}
if ( isset( $argv['name'] ) ) {
// Key given.
- $key = Sanitizer::escapeId( $argv['name'], 'noninitial' );
+ $key = trim( $argv['name'] );
unset( $argv['name'] );
--$cnt;
}
if ( isset( $argv['follow'] ) ) {
// Follow given.
- $follow = Sanitizer::escapeId( $argv['follow'], 'noninitial' );
+ $follow = trim( $argv['follow'] );
unset( $argv['follow'] );
--$cnt;
}
@@ -444,7 +455,7 @@ class Cite {
* @throws Exception
* @return string
*/
- private function stack( $str, $key = null, $group, $follow, array $call ) {
+ private function stack( $str, $key, $group, $follow, array $call ) {
if ( !isset( $this->mRefs[$group] ) ) {
$this->mRefs[$group] = [];
}
@@ -746,30 +757,8 @@ class Cite {
"\n" . implode( "\n", $ent ) . "\n"
);
- // Let's try to cache it.
- global $wgCiteCacheReferences, $wgMemc;
- $data = false;
- if ( $wgCiteCacheReferences ) {
- $cacheKey = wfMemcKey(
- 'citeref',
- md5( $parserInput ),
- $this->mParser->Title()->getArticleID()
- );
- $data = $wgMemc->get( $cacheKey );
- }
-
- if ( !$data || !$this->mParser->isValidHalfParsedText( $data ) ) {
- // Live hack: parse() adds two newlines on WM, can't reproduce it locally -ævar
- $ret = rtrim( $this->mParser->recursiveTagParse( $parserInput ), "\n" );
-
- if ( $wgCiteCacheReferences ) {
- $serData = $this->mParser->serializeHalfParsedText( $ret );
- $wgMemc->set( $cacheKey, $serData, 86400 );
- }
-
- } else {
- $ret = $this->mParser->unserializeHalfParsedText( $data );
- }
+ // Live hack: parse() adds two newlines on WM, can't reproduce it locally -ævar
+ $ret = rtrim( $this->mParser->recursiveTagParse( $parserInput ), "\n" );
if ( $responsive ) {
// Use a DIV wrap because column-count on a list directly is broken in Chrome.
@@ -806,8 +795,12 @@ class Cite {
if ( !is_array( $val ) ) {
return wfMessage(
'cite_references_link_one',
- self::getReferencesKey( $key ),
- $this->refKey( $key ),
+ $this->normalizeKey(
+ self::getReferencesKey( $key )
+ ),
+ $this->normalizeKey(
+ $this->refKey( $key )
+ ),
$this->referenceText( $key, $val )
)->inContentLanguage()->plain();
}
@@ -815,14 +808,18 @@ class Cite {
if ( isset( $val['follow'] ) ) {
return wfMessage(
'cite_references_no_link',
- self::getReferencesKey( $val['follow'] ),
+ $this->normalizeKey(
+ self::getReferencesKey( $val['follow'] )
+ ),
$text
)->inContentLanguage()->plain();
}
if ( !isset( $val['count'] ) ) {
// this handles the case of section preview for list-defined references
return wfMessage( 'cite_references_link_many',
- self::getReferencesKey( $key . "-" . ( isset( $val['key'] ) ? $val['key'] : '' ) ),
+ $this->normalizeKey(
+ self::getReferencesKey( $key . "-" . ( isset( $val['key'] ) ? $val['key'] : '' ) )
+ ),
'',
$text
)->inContentLanguage()->plain();
@@ -830,9 +827,13 @@ class Cite {
if ( $val['count'] < 0 ) {
return wfMessage(
'cite_references_link_one',
- self::getReferencesKey( $val['key'] ),
- # $this->refKey( $val['key'], $val['count'] ),
- $this->refKey( $val['key'] ),
+ $this->normalizeKey(
+ self::getReferencesKey( $val['key'] )
+ ),
+ $this->normalizeKey(
+ # $this->refKey( $val['key'], $val['count'] )
+ $this->refKey( $val['key'] )
+ ),
$text
)->inContentLanguage()->plain();
// Standalone named reference, I want to format this like an
@@ -843,9 +844,13 @@ class Cite {
if ( $val['count'] === 0 ) {
return wfMessage(
'cite_references_link_one',
- self::getReferencesKey( $key . "-" . $val['key'] ),
- # $this->refKey( $key, $val['count'] ),
- $this->refKey( $key, $val['key'] . "-" . $val['count'] ),
+ $this->normalizeKey(
+ self::getReferencesKey( $key . "-" . $val['key'] )
+ ),
+ $this->normalizeKey(
+ # $this->refKey( $key, $val['count'] ),
+ $this->refKey( $key, $val['key'] . "-" . $val['count'] )
+ ),
$text
)->inContentLanguage()->plain();
// Named references with >1 occurrences
@@ -855,7 +860,9 @@ class Cite {
for ( $i = 0; $i <= $val['count']; ++$i ) {
$links[] = wfMessage(
'cite_references_link_many_format',
- $this->refKey( $key, $val['key'] . "-$i" ),
+ $this->normalizeKey(
+ $this->refKey( $key, $val['key'] . "-$i" )
+ ),
$this->referencesFormatEntryNumericBacklinkLabel( $val['number'], $i, $val['count'] ),
$this->referencesFormatEntryAlternateBacklinkLabel( $i )
)->inContentLanguage()->plain();
@@ -864,7 +871,9 @@ class Cite {
$list = $this->listToText( $links );
return wfMessage( 'cite_references_link_many',
- self::getReferencesKey( $key . "-" . $val['key'] ),
+ $this->normalizeKey(
+ self::getReferencesKey( $key . "-" . $val['key'] )
+ ),
$list,
$text
)->inContentLanguage()->plain();
@@ -893,8 +902,8 @@ class Cite {
*
* @static
*
- * @param int $base The base
- * @param int $offset The offset
+ * @param int $base
+ * @param int $offset
* @param int $max Maximum value expected.
* @return string
*/
@@ -913,7 +922,7 @@ class Cite {
* 'b', 'c', ...]. Return an error if the offset > the # of
* array items
*
- * @param int $offset The offset
+ * @param int $offset
*
* @return string
*/
@@ -935,7 +944,7 @@ class Cite {
* [ 'a', 'b', 'c', ...].
* Return an error if the offset > the # of array items
*
- * @param int $offset The offset
+ * @param int $offset
* @param string $group The group name
* @param string $label The text to use if there's no message for them.
*
@@ -966,7 +975,7 @@ class Cite {
*
* @static
*
- * @param string $key The key
+ * @param string $key
* @param int $num The number of the key
* @return string A key for use in wikitext
*/
@@ -988,7 +997,7 @@ class Cite {
*
* @static
*
- * @param string $key The key
+ * @param string $key
* @return string A key for use in wikitext
*/
public static function getReferencesKey( $key ) {
@@ -1017,19 +1026,37 @@ class Cite {
global $wgContLang;
$label = is_null( $label ) ? ++$this->mGroupCnt[$group] : $label;
- return
- $this->mParser->recursiveTagParse(
+ return $this->mParser->recursiveTagParse(
wfMessage(
'cite_reference_link',
- $this->refKey( $key, $count ),
- self::getReferencesKey( $key . $subkey ),
- $this->getLinkLabel( $label, $group,
- ( ( $group === self::DEFAULT_GROUP ) ? '' : "$group " ) . $wgContLang->formatNum( $label ) )
+ $this->normalizeKey(
+ $this->refKey( $key, $count )
+ ),
+ $this->normalizeKey(
+ self::getReferencesKey( $key . $subkey )
+ ),
+ Sanitizer::safeEncodeAttribute(
+ $this->getLinkLabel( $label, $group,
+ ( ( $group === self::DEFAULT_GROUP ) ? '' : "$group " ) . $wgContLang->formatNum( $label ) )
+ )
)->inContentLanguage()->plain()
);
}
/**
+ * Normalizes and sanitizes a reference key
+ *
+ * @param string $key
+ * @return string
+ */
+ private function normalizeKey( $key ) {
+ $key = Sanitizer::escapeIdForAttribute( $key );
+ $key = Sanitizer::safeEncodeAttribute( $key );
+
+ return $key;
+ }
+
+ /**
* This does approximately the same thing as
* Language::listToText() but due to this being used for a
* slightly different purpose (people might not want , as the
@@ -1088,7 +1115,7 @@ class Cite {
* Gets run when Parser::clearState() gets run, since we don't
* want the counts to transcend pages and other instances
*
- * @param Parser $parser
+ * @param Parser &$parser
*
* @return bool
*/
@@ -1146,8 +1173,8 @@ class Cite {
* references tags and does not add the errors.
*
* @param bool $afterParse True if called from the ParserAfterParse hook
- * @param Parser $parser
- * @param string $text
+ * @param Parser &$parser
+ * @param string &$text
*
* @return bool
*/
@@ -1185,7 +1212,10 @@ class Cite {
$s .= $this->referencesFormat( $group, $wgCiteResponsiveReferences );
} else {
$s .= "\n<br />" .
- $this->error( 'cite_error_group_refs_without_references', htmlspecialchars( $group ) );
+ $this->error(
+ 'cite_error_group_refs_without_references',
+ Sanitizer::safeEncodeAttribute( $group )
+ );
}
}
if ( $isSectionPreview && $s !== '' ) {
@@ -1209,7 +1239,7 @@ class Cite {
* This is called by each <references/> tag, and by checkRefsNoReferences
* Assumes $this->mRefs[$group] is set
*
- * @param $group
+ * @param string $group
*/
private function saveReferencesData( $group = self::DEFAULT_GROUP ) {
global $wgCiteStoreReferencesData;
@@ -1243,7 +1273,7 @@ class Cite {
* If any ref or reference reference tag is in the text,
* the entire page should be reparsed, so we return false in that case.
*
- * @param $output
+ * @param string &$output
*
* @return bool
*/
@@ -1283,7 +1313,7 @@ class Cite {
* Return an error message based on an error ID
*
* @param string $key Message name for the error
- * @param string|null $param Parameter to pass to the message
+ * @param string[]|string|null $param Parameter to pass to the message
* @param string $parse Whether to parse the message ('parse') or not ('noparse')
* @return string XHTML or wikitext ready for output
*/
@@ -1377,7 +1407,7 @@ class Cite {
if ( !$wgCiteStoreReferencesData ) {
return false;
}
- $cache = ObjectCache::getMainWANInstance();
+ $cache = MediaWikiServices::getInstance()->getMainWANObjectCache();
$key = $cache->makeKey( self::EXT_DATA_KEY, $title->getArticleID() );
return $cache->getWithSetCallback(
$key,
@@ -1400,12 +1430,12 @@ class Cite {
* Returns json_decoded uncompressed string, with validation of json
*
* @param Title $title
- * @param DatabaseBase $dbr
+ * @param IDatabase $dbr
* @param string $string
* @param int $i
* @return array|false
*/
- private static function recursiveFetchRefsFromDB( Title $title, DatabaseBase $dbr,
+ private static function recursiveFetchRefsFromDB( Title $title, IDatabase $dbr,
$string = '', $i = 1 ) {
$id = $title->getArticleID();
$result = $dbr->selectField(
diff --git a/www/wiki/extensions/Cite/includes/CiteCSSFileModule.php b/www/wiki/extensions/Cite/includes/CiteCSSFileModule.php
index ef945e23..193fd539 100644
--- a/www/wiki/extensions/Cite/includes/CiteCSSFileModule.php
+++ b/www/wiki/extensions/Cite/includes/CiteCSSFileModule.php
@@ -1,14 +1,13 @@
<?php
+
/**
* ResourceLoaderFileModule for adding the content language Cite CSS
*
- * @file
- * @ingroup Extensions
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
-
class CiteCSSFileModule extends ResourceLoaderFileModule {
+
public function __construct(
$options = [],
$localBasePath = null,
@@ -31,4 +30,5 @@ class CiteCSSFileModule extends ResourceLoaderFileModule {
}
}
}
+
}
diff --git a/www/wiki/extensions/Cite/includes/CiteDataModule.php b/www/wiki/extensions/Cite/includes/CiteDataModule.php
index 1952ebf8..45b74d61 100644
--- a/www/wiki/extensions/Cite/includes/CiteDataModule.php
+++ b/www/wiki/extensions/Cite/includes/CiteDataModule.php
@@ -1,24 +1,19 @@
<?php
+
/**
* Resource loader module providing extra data from the server to Cite.
*
* Temporary hack for T93800
*
- * @file
- * @ingroup Extensions
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see MIT-LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
-
class CiteDataModule extends ResourceLoaderModule {
- /* Protected Members */
-
protected $origin = self::ORIGIN_USER_SITEWIDE;
protected $targets = [ 'desktop', 'mobile' ];
- /* Methods */
-
+ /** @inheritDoc */
public function getScript( ResourceLoaderContext $context ) {
$citationDefinition = json_decode(
$context->msg( 'cite-tool-definition.json' )
@@ -45,8 +40,7 @@ class CiteDataModule extends ResourceLoaderModule {
}
}
- return
- 've.init.platform.addMessages(' . FormatJson::encode(
+ return 've.init.platform.addMessages(' . FormatJson::encode(
[
'cite-tool-definition.json' => json_encode( $citationTools )
],
@@ -54,6 +48,7 @@ class CiteDataModule extends ResourceLoaderModule {
) . ');';
}
+ /** @inheritDoc */
public function getDependencies( ResourceLoaderContext $context = null ) {
return [
'ext.visualEditor.base',
@@ -61,6 +56,7 @@ class CiteDataModule extends ResourceLoaderModule {
];
}
+ /** @inheritDoc */
public function getDefinitionSummary( ResourceLoaderContext $context ) {
$summary = parent::getDefinitionSummary( $context );
$summary[] = [
@@ -68,4 +64,5 @@ class CiteDataModule extends ResourceLoaderModule {
];
return $summary;
}
+
}
diff --git a/www/wiki/extensions/Cite/includes/CiteHooks.php b/www/wiki/extensions/Cite/includes/CiteHooks.php
index f0bcc262..a55a9246 100644
--- a/www/wiki/extensions/Cite/includes/CiteHooks.php
+++ b/www/wiki/extensions/Cite/includes/CiteHooks.php
@@ -1,21 +1,20 @@
<?php
/**
- * Cite extension hooks
- *
- * @file
- * @ingroup Extensions
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see MIT-LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
+use MediaWiki\MediaWikiServices;
+
class CiteHooks {
+
/**
* Convert the content model of a message that is actually JSON to JSON. This
* only affects validation and UI when saving and editing, not loading the
* content.
*
* @param Title $title
- * @param string $model
+ * @param string &$model
* @return bool
*/
public static function onContentHandlerDefaultModelFor( Title $title, &$model ) {
@@ -36,8 +35,8 @@ class CiteHooks {
* Conditionally register the unit testing module for the ext.cite.visualEditor module
* only if that module is loaded
*
- * @param array $testModules The array of registered test modules
- * @param ResourceLoader $resourceLoader The reference to the resource loader
+ * @param array &$testModules The array of registered test modules
+ * @param ResourceLoader &$resourceLoader The reference to the resource loader
* @return true
*/
public static function onResourceLoaderTestModules(
@@ -56,6 +55,7 @@ class CiteHooks {
'modules/ve-cite/tests/ve.dm.Converter.test.js',
'modules/ve-cite/tests/ve.dm.InternalList.test.js',
'modules/ve-cite/tests/ve.dm.Transaction.test.js',
+ 'modules/ve-cite/tests/ve.ui.DiffElement.test.js',
'modules/ve-cite/tests/ve.ui.MWWikitextStringTransferHandler.test.js',
],
'dependencies' => [
@@ -74,7 +74,7 @@ class CiteHooks {
* Conditionally register resource loader modules that depends on the
* VisualEditor MediaWiki extension.
*
- * @param $resourceLoader
+ * @param ResourceLoader &$resourceLoader
* @return true
*/
public static function onResourceLoaderRegisterModules( &$resourceLoader ) {
@@ -106,6 +106,8 @@ class CiteHooks {
"cite-ve-referenceslist-isempty",
"cite-ve-referenceslist-isempty-default",
"cite-ve-referenceslist-missingref",
+ "cite-ve-referenceslist-missingref-in-list",
+ "cite-ve-referenceslist-missingreflist",
"visualeditor-internal-list-diff-default-group-name-mwreference",
"visualeditor-internal-list-diff-group-name-mwreference"
],
@@ -118,6 +120,57 @@ class CiteHooks {
$resourceLoader->register( "ext.cite.visualEditor.data",
[ "class" => "CiteDataModule" ] );
+ $resourceLoader->register( "ext.cite.visualEditor.icons", [
+ 'localBasePath' => $dir . 'modules',
+ 'remoteExtPath' => 'Cite/modules',
+ "class" => "ResourceLoaderImageModule",
+ "selectorWithoutVariant" => ".oo-ui-icon-{name}",
+ "selectorWithVariant" => ".oo-ui-image-{variant}.oo-ui-icon-{name}",
+ "variants" => [
+ "progressive" => [
+ "color" => "#36c"
+ ]
+ ],
+ "images" => [
+ "ref-cite-book" => [
+ "file" => "ve-cite/icons/ref-cite-book.svg"
+ ],
+ "ref-cite-journal" => [
+ "file" => [
+ "ltr" => "ve-cite/icons/ref-cite-journal-ltr.svg",
+ "rtl" => "ve-cite/icons/ref-cite-journal-rtl.svg"
+ ]
+ ],
+ "ref-cite-news" => [
+ "file" => [
+ "ltr" => "ve-cite/icons/ref-cite-news-ltr.svg",
+ "rtl" => "ve-cite/icons/ref-cite-news-rtl.svg"
+ ]
+ ],
+ "ref-cite-web" => [
+ "file" => "ve-cite/icons/ref-cite-web.svg"
+ ],
+ "reference" => [
+ "file" => [
+ "ltr" => "ve-cite/icons/reference-ltr.svg",
+ "rtl" => "ve-cite/icons/reference-rtl.svg"
+ ]
+ ],
+ "reference-existing" => [
+ "file" => [
+ "ltr" => "ve-cite/icons/reference-existing-ltr.svg",
+ "rtl" => "ve-cite/icons/reference-existing-rtl.svg"
+ ]
+ ],
+ "references" => [
+ "file" => [
+ "ltr" => "ve-cite/icons/references-ltr.svg",
+ "rtl" => "ve-cite/icons/references-rtl.svg"
+ ]
+ ],
+ ]
+ ] );
+
$resourceLoader->register( "ext.cite.visualEditor", [
'localBasePath' => $dir . 'modules',
'remoteExtPath' => 'Cite/modules',
@@ -140,7 +193,6 @@ class CiteHooks {
"styles" => [
"ve-cite/ve.ui.MWReferenceContextItem.css",
"ve-cite/ve.ui.MWReferenceGroupInputWidget.css",
- "ve-cite/ve.ui.MWReferenceIcons.css",
"ve-cite/ve.ui.MWReferenceResultWidget.css",
"ve-cite/ve.ui.MWReferenceSearchWidget.css"
],
@@ -149,6 +201,7 @@ class CiteHooks {
"oojs-ui.styles.icons-interactions",
"ext.cite.visualEditor.core",
"ext.cite.visualEditor.data",
+ "ext.cite.visualEditor.icons",
"ext.cite.style",
"ext.cite.styles",
"ext.visualEditor.mwtransclusion",
@@ -162,6 +215,8 @@ class CiteHooks {
"cite-ve-changedesc-reflist-group-from",
"cite-ve-changedesc-reflist-group-to",
"cite-ve-changedesc-reflist-item-id",
+ "cite-ve-changedesc-reflist-responsive-set",
+ "cite-ve-changedesc-reflist-responsive-unset",
"cite-ve-dialog-reference-editing-reused",
"cite-ve-dialog-reference-options-group-label",
"cite-ve-dialog-reference-options-group-placeholder",
@@ -199,7 +254,7 @@ class CiteHooks {
* Post-output processing of references property, for proper db storage
* Deferred to avoid performance overhead when outputting the page
*
- * @param LinksUpdate $linksUpdate
+ * @param LinksUpdate &$linksUpdate
*/
public static function onLinksUpdate( LinksUpdate &$linksUpdate ) {
global $wgCiteStoreReferencesData, $wgCiteCacheRawReferencesOnParse;
@@ -212,7 +267,7 @@ class CiteHooks {
}
if ( $wgCiteCacheRawReferencesOnParse ) {
// caching
- $cache = ObjectCache::getMainWANInstance();
+ $cache = MediaWikiServices::getInstance()->getMainWANObjectCache();
$articleID = $linksUpdate->getTitle()->getArticleID();
$key = $cache->makeKey( Cite::EXT_DATA_KEY, $articleID );
$cache->set( $key, $refData, Cite::CACHE_DURATION_ONPARSE );
@@ -235,7 +290,7 @@ class CiteHooks {
* If $wgCiteCacheRawReferencesOnParse is set to false, purges the cache
* when references are modified
*
- * @param LinksUpdate $linksUpdate
+ * @param LinksUpdate &$linksUpdate
*/
public static function onLinksUpdateComplete( LinksUpdate &$linksUpdate ) {
global $wgCiteStoreReferencesData, $wgCiteCacheRawReferencesOnParse;
@@ -254,7 +309,7 @@ class CiteHooks {
return;
}
}
- $cache = ObjectCache::getMainWANInstance();
+ $cache = MediaWikiServices::getInstance()->getMainWANObjectCache();
$articleID = $linksUpdate->getTitle()->getArticleID();
$key = $cache->makeKey( Cite::EXT_DATA_KEY, $articleID );
// delete with reduced hold off period (LinksUpdate uses a master connection)
@@ -263,9 +318,11 @@ class CiteHooks {
/**
* Adds extra variables to the global config
+ * @param array &$vars
+ * @return true
*/
public static function onResourceLoaderGetConfigVars( array &$vars ) {
- $config = ConfigFactory::getDefaultInstance()->makeConfig( 'cite' );
+ $config = MediaWikiServices::getInstance()->getConfigFactory()->makeConfig( 'cite' );
$vars['wgCiteVisualEditorOtherGroup'] = $config->get( 'CiteVisualEditorOtherGroup' );
$vars['wgCiteResponsiveReferences'] = $config->get( 'CiteResponsiveReferences' );
return true;
@@ -280,7 +337,8 @@ class CiteHooks {
* @param array &$data
*/
public static function onAPIQuerySiteInfoGeneralInfo( ApiQuerySiteInfo $api, array &$data ) {
- $config = ConfigFactory::getDefaultInstance()->makeConfig( 'cite' );
+ $config = MediaWikiServices::getInstance()->getConfigFactory()->makeConfig( 'cite' );
$data['citeresponsivereferences'] = $config->get( 'CiteResponsiveReferences' );
}
+
}
diff --git a/www/wiki/extensions/Cite/modules/ext.cite.style.css b/www/wiki/extensions/Cite/modules/ext.cite.style.css
index 0fc4f1b5..565a3a59 100644
--- a/www/wiki/extensions/Cite/modules/ext.cite.style.css
+++ b/www/wiki/extensions/Cite/modules/ext.cite.style.css
@@ -1,7 +1,7 @@
/* CSS for Parsoid Cite extension */
/* Style for <ref>s */
-span.mw-ref {
+.mw-ref {
vertical-align: super;
line-height: 1;
font-size: smaller;
@@ -13,35 +13,35 @@ span.mw-ref {
/* stylelint-disable value-keyword-case */
/* With a group set */
-span.mw-ref a[data-mw-group]:after {
+.mw-ref a[ data-mw-group ]:after {
content: '[' attr( data-mw-group ) ' ' counter( mw-Ref, decimal ) ']';
}
/* Groups with special appearance */
-span.mw-ref a[data-mw-group='decimal']:after {
+.mw-ref a[ data-mw-group='decimal' ]:after {
content: '[' counter( mw-Ref, decimal ) ']';
}
-span.mw-ref a[data-mw-group='lower-alpha']:after {
+.mw-ref a[ data-mw-group='lower-alpha' ]:after {
content: '[' counter( mw-Ref, lower-alpha ) ']';
}
-span.mw-ref a[data-mw-group='upper-alpha']:after {
+.mw-ref a[ data-mw-group='upper-alpha' ]:after {
content: '[' counter( mw-Ref, upper-alpha ) ']';
}
-span.mw-ref a[data-mw-group='lower-greek']:after {
+.mw-ref a[ data-mw-group='lower-greek' ]:after {
content: '[' counter( mw-Ref, lower-greek ) ']';
}
-span.mw-ref a[data-mw-group='lower-roman']:after {
+.mw-ref a[ data-mw-group='lower-roman' ]:after {
content: '[' counter( mw-Ref, lower-roman ) ']';
}
-span.mw-ref a[data-mw-group='upper-roman']:after {
+.mw-ref a[ data-mw-group='upper-roman' ]:after {
content: '[' counter( mw-Ref, upper-roman ) ']';
}
-span.mw-ref a[data-mw-group='error-test']:after {
+.mw-ref a[ data-mw-group='error-test' ]:after {
content: '[' counter( mw-Ref, symbols( cyclic 'first' 'second' 'last!' ) ) ']';
}
/* Without a group */
-span.mw-ref a:after {
+.mw-ref a:after {
content: '[' counter( mw-Ref, decimal ) ']';
}
@@ -62,15 +62,15 @@ ol.mw-references li {
counter-increment: mw-ref-linkback;
}
-[rel='mw:referencedBy'] {
+[ rel='mw:referencedBy' ] {
counter-reset: mw-ref-linkback -1;
}
-[rel='mw:referencedBy']:before {
+[ rel='mw:referencedBy' ]:before {
content: '↑ ';
}
-span[rel='mw:referencedBy'] a:before {
+span[ rel='mw:referencedBy' ] a:before {
counter-increment: mw-ref-linkback;
content: counters( mw-ref-linkback, '.', decimal );
vertical-align: super;
@@ -78,14 +78,14 @@ span[rel='mw:referencedBy'] a:before {
font-size: smaller;
}
-span[rel='mw:referencedBy'] a:after {
+span[ rel='mw:referencedBy' ] a:after {
content: ' ';
}
/* Hide the default rendering in browsers that support content
* generation by selecting for :after pseudo-element.*/
/* stylelint-disable-next-line selector-type-no-unknown */
-x-thereisnoelementwiththisname[rel='mw:referencedBy']:before,
+x-thereisnoelementwiththisname[ rel='mw:referencedBy' ]:before,
span.mw-linkback-text {
display: none;
}
diff --git a/www/wiki/extensions/Cite/modules/ext.cite.style.fa.css b/www/wiki/extensions/Cite/modules/ext.cite.style.fa.css
index 0ce01a00..91091d3a 100644
--- a/www/wiki/extensions/Cite/modules/ext.cite.style.fa.css
+++ b/www/wiki/extensions/Cite/modules/ext.cite.style.fa.css
@@ -4,16 +4,16 @@
/* stylelint-disable value-keyword-case */
/* <ref>s with a group */
-span.mw-ref a[data-mw-group]:after {
+.mw-ref a[ data-mw-group ]:after {
content: '[' attr( data-mw-group ) ' ' counter( mw-Ref, persian ) ']';
}
/* <ref>s without a group */
-span.mw-ref a:after {
+.mw-ref a:after {
content: '[' counter( mw-Ref, persian ) ']';
}
/* Linkbacks from <references> to <ref>s */
-span[rel='mw:referencedBy'] a:before {
+span[ rel='mw:referencedBy' ] a:before {
content: counters( mw-ref-linkback, '٫', persian );
}
diff --git a/www/wiki/extensions/Cite/modules/ext.cite.styles.css b/www/wiki/extensions/Cite/modules/ext.cite.styles.css
index 506d0db3..e70959dc 100644
--- a/www/wiki/extensions/Cite/modules/ext.cite.styles.css
+++ b/www/wiki/extensions/Cite/modules/ext.cite.styles.css
@@ -33,8 +33,7 @@ sup.reference {
/* Highlight clicked reference in blue to help navigation */
ol.references li:target,
sup.reference:target {
- background-color: #def; /* fallback */
- background-color: rgba( 0, 127, 255, 0.133 );
+ background-color: #eaf3ff;
}
/* Make cite errors "strong" */
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ace.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ace.json
index a36515ab..62785644 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ace.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ace.json
@@ -13,4 +13,4 @@
"cite-ve-dialog-referenceslist-title": "Dapeuta rèfèrènsi",
"cite-ve-dialogbutton-reference-tooltip": "Rèfèrènsi",
"cite-ve-dialogbutton-referenceslist-tooltip": "Dapeuta rèfèrènsi"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ais.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ais.json
index 2788dc9b..f50e7c6d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ais.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ais.json
@@ -10,18 +10,27 @@
"visualeditor-cite-tool-name-journal": "paydemiad-inasc-nasulitan",
"visualeditor-cite-tool-name-news": "sinbun",
"visualeditor-cite-tool-name-web": "calay-kakacawan(C-wangcan)",
+ "cite-ve-dialog-reference-editing-reused": "tina kasabelih masaungay tuway tina miazih tu tatenga’ay nasulitan $1 {{PLURAL:$1|}}.",
"cite-ve-dialog-reference-options-group-label": "pisaungay tina luyaluy",
"cite-ve-dialog-reference-options-group-placeholder": "habutud miazih tu tatenga’ay nasulitan",
+ "cite-ve-dialog-reference-options-name-label": "uyni kalungangan amipisaungay henay",
"cite-ve-dialog-reference-options-section": "mapili’ay",
+ "cite-ve-dialog-reference-useexisting-full-label": "misaliyaw pisaungay izaway itini i tina kasabelih a nicaliwan",
"cite-ve-dialog-reference-useexisting-label": "pisaungay ayzaay miazih tu tatenga’ay nasulitan",
"cite-ve-dialog-reference-useexisting-tool": "miliyaw pisaungay",
- "cite-ve-dialog-referenceslist-contextitem-description-general": "habutud miazih tu tatenga’ay nasulitan",
+ "cite-ve-dialog-referenceslist-contextitem-description-general": "habutuday a miazih tu tatenga’ay nasulitan piazihan-tu-sulit",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "luyaluy \"$1\" a miazih tu tatenga’ay nasulitan piazihan-tu-sulit",
"cite-ve-dialog-referenceslist-title": "miazih tu tatenga’ay nasulitan piazihan tu sulit",
+ "cite-ve-dialogbutton-citation-educationpopup-text": "micaliw ku micunus saangangan cesyun pasakapahan lacul nu misu, kapah tu kisu nicaliwan nay cudad, sinbung atu calay-kakacawan(wangcan).",
"cite-ve-dialogbutton-citation-educationpopup-title": "nicaliwan",
"cite-ve-dialogbutton-reference-full-label": "palana’an aazihan a cudad",
"cite-ve-dialogbutton-reference-title": "miazih tu tatenga’ay nasulitan",
"cite-ve-dialogbutton-reference-tooltip": "angangan",
"cite-ve-dialogbutton-referenceslist-tooltip": "miazih tu tatenga’ay nasulitan piazihan tu sulit",
+ "cite-ve-reference-input-placeholder": "mikilim tu ayzaay nicaliwan",
+ "cite-ve-referenceslist-isempty": "tina kasabelih inayi’ luyaluy ku \"$1\" a miazih tu tatenga’ay nasulitan kapah micunus nicaliwan piazihan tu sulit.",
+ "cite-ve-referenceslist-isempty-default": "tina kasabelih ayzasa inayi’ amahicahica miazih tu tatenga’ay nasulitan kapah micunus nicaliwan piazihan-tu-sulit.",
+ "cite-ve-referenceslist-missingref": "tina miazih tu tatenga’ay nasulitan satetek tu ku taazihan mitudung saca zuma lunuk masanga’ay a atilad ayza pisaungay dada’ yuensma-kodo muse tayni mikawaway-kalumyiti",
"cite-ve-toolbar-group-label": "nicaliwan",
"cite-ve-othergroup-item": "$1 miazih tu tatenga’ay nasulitan",
"visualeditor-internal-list-diff-default-group-name-mwreference": "miazih tu tatenga’ay saangangan"
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/am.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/am.json
index 87f13517..e4712aa6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/am.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/am.json
@@ -7,4 +7,4 @@
"cite-ve-dialog-reference-options-section": "ምርጫዎች",
"cite-ve-dialog-reference-title": "ዋቢ ምንጭ",
"cite-ve-dialogbutton-reference-tooltip": "ዋቢ ምንጭ"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ar.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ar.json
index ade02647..e2aff578 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ar.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ar.json
@@ -19,7 +19,8 @@
"Mervat Salman",
"Hiba Alshawi",
"فلورانس",
- "PhiberOptik"
+ "PhiberOptik",
+ "ديفيد"
]
},
"visualeditor-cite-tool-name-book": "كتاب",
@@ -32,11 +33,14 @@
"cite-ve-changedesc-reflist-group-both": "مجموعة قائمة المراجع تغيرت من \"$1\" إلى \"$2\"",
"cite-ve-changedesc-reflist-group-from": "مجموعة قائمة المراجع تغيرت من \"$1\" للمجموعة العامة",
"cite-ve-changedesc-reflist-group-to": "مجموعة قائمة المراجع تغيرت من المجموعة العامة إلى \"$1\"",
+ "cite-ve-changedesc-reflist-responsive-set": "قائمة المراجع تغيرت للعرض في مراجع مستجيبة",
+ "cite-ve-changedesc-reflist-responsive-unset": "قائمة المراجع تغيرت للعرض في عامود واحد فقط",
"cite-ve-changedesc-reflist-item-id": "فهرس المراجع تغير",
"cite-ve-dialog-reference-editing-reused": "هذا المرجع مستخدم {{PLURAL:$1|مرة واحدة|مرتين| $1 مرات|$1 مرة}} في هذه الصفحة.",
"cite-ve-dialog-reference-options-group-label": "استخدم هذه المجموعة",
"cite-ve-dialog-reference-options-group-placeholder": "مراجع عامة",
"cite-ve-dialog-reference-options-name-label": "أعد استخدامها بهذا الاسم",
+ "cite-ve-dialog-reference-options-responsive-label": "استخدم تهيئة العمود المستجيبة",
"cite-ve-dialog-reference-options-section": "خيارات",
"cite-ve-dialog-reference-placeholder": "اكتب أو انسخ مرجعك هنا، أو أدخل قالب استشهاد.",
"cite-ve-dialog-reference-title": "مرجع",
@@ -56,6 +60,8 @@
"cite-ve-referenceslist-isempty": "ما من مراجع من المجموعة \"$1\" في هذه الصفحة لتضمينها في هذه القائمة.",
"cite-ve-referenceslist-isempty-default": "ما من مراجع على هذه الصفحة لتضمينها في هذه القائمة.",
"cite-ve-referenceslist-missingref": "هذا المرجع موجود في قالب أو نحوه ولا يمكن تعديله حاليا إلا من المصدر.",
+ "cite-ve-referenceslist-missingref-in-list": "يتم تعريف هذا المرجع في قالب أو كتلة أخرى تم إنشاؤها، ويمكن الآن معاينته فقط في وضع المصدر.",
+ "cite-ve-referenceslist-missingreflist": "قائمة المراجع هذه مولدة بواسطة قالب، وحاليا يمكن تعديلها فقط في نمط المصدر.",
"cite-ve-toolbar-group-label": "مرجع",
"cite-ve-othergroup-item": "استشهاد $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "مراجع",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/arc.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/arc.json
index 9c6c34ff..cb30317c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/arc.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/arc.json
@@ -6,4 +6,4 @@
},
"cite-ve-dialogbutton-reference-tooltip": "ܡܒܘܥܐ",
"cite-ve-dialogbutton-referenceslist-tooltip": "ܡܟܬܒܘܬܐ ܕܡܒܘܥ̈ܐ"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/arq.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/arq.json
index 7adb10fb..0f08a946 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/arq.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/arq.json
@@ -11,4 +11,4 @@
"visualeditor-cite-tool-name-news": "الخبار",
"visualeditor-cite-tool-name-web": "موقع",
"cite-ve-dialog-reference-options-section": "خيارات"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ast.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ast.json
index ba934ed1..653612e6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ast.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ast.json
@@ -19,11 +19,14 @@
"cite-ve-changedesc-reflist-group-both": "Grupu de llista de referencies cambiáu de «$1» to «$2»",
"cite-ve-changedesc-reflist-group-from": "Grupu de llista de referencies cambiáu de «$1» al grupu xeneral",
"cite-ve-changedesc-reflist-group-to": "Grupu de llista de referencies cambiáu del grupu xeneral a «$1»",
+ "cite-ve-changedesc-reflist-responsive-set": "La llista de referencies cambió p'apaecer en columnes reactives",
+ "cite-ve-changedesc-reflist-responsive-unset": "La llista de referencies cambió p'apaecer sólo nuna columna",
"cite-ve-changedesc-reflist-item-id": "Cambió l'índiz de la referencia",
"cite-ve-dialog-reference-editing-reused": "Esta referencia úsase $1 {{PLURAL:$1|vez|veces}} nesta páxina.",
"cite-ve-dialog-reference-options-group-label": "Usar esti grupu",
"cite-ve-dialog-reference-options-group-placeholder": "Referencies xenerales",
"cite-ve-dialog-reference-options-name-label": "Reutilizar por esti nome",
+ "cite-ve-dialog-reference-options-responsive-label": "Usar diseñu de columna reactivu",
"cite-ve-dialog-reference-options-section": "Opciones",
"cite-ve-dialog-reference-placeholder": "Escribe o pega equí la referencia, o inxerta una plantía de cita.",
"cite-ve-dialog-reference-title": "Referencia",
@@ -43,6 +46,8 @@
"cite-ve-referenceslist-isempty": "Nun hai referencies col grupu \"$1\" nesta páxina pa incluir nesta llista.",
"cite-ve-referenceslist-isempty-default": "Nun hai referencies nesta páxina pa incluir nesta llista.",
"cite-ve-referenceslist-missingref": "Esta referencia ta definida nuna plantía o n'otru bloque xeneráu, y de momentu namái pue editase'n mou fonte.",
+ "cite-ve-referenceslist-missingref-in-list": "Esta referencia ta definida nuna plantía o n'otru bloque xeneráu, y de momentu namái puede entevese'n mou códigu fonte.",
+ "cite-ve-referenceslist-missingreflist": "Esta llista de referencies ta xenerada por una plantía, y de momentu sólo puede editase'n mou de códigu fonte.",
"cite-ve-toolbar-group-label": "Citar",
"cite-ve-othergroup-item": "referencia $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referencies",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ay.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ay.json
index 883b0e05..50480fb6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ay.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ay.json
@@ -21,4 +21,4 @@
"cite-ve-dialogbutton-reference-tooltip": "Jasa",
"cite-ve-dialogbutton-referenceslist-tooltip": "Yaqha lista",
"cite-ve-toolbar-group-label": "Sutinchaña"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/az.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/az.json
index 0fbcdbee..65bdda85 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/az.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/az.json
@@ -22,4 +22,4 @@
"cite-ve-dialog-referenceslist-title": "İstinadlar siyahısı",
"cite-ve-dialogbutton-reference-tooltip": "Əsas",
"cite-ve-dialogbutton-referenceslist-tooltip": "İstinad siyahısı"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bcl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bcl.json
index 125e8d1a..9182784f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bcl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bcl.json
@@ -17,4 +17,4 @@
"cite-ve-referenceslist-isempty": "Mayo tabi nin mga panultulan na kaiba sa grupong \"$1\" na yaon kaining pahina.",
"cite-ve-referenceslist-isempty-default": "Mayo nin reperensiya sa pahinang ini na maidudugang sa listahang ini.",
"cite-ve-referenceslist-missingref": "Ining panultulan pinagkahulugan sa laog nin sarong panguyog o ibang pinagpuyos na bloke, asin para sa ngunyan maliliwat sana na yaon sa gikanang kamugtakan."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/be-tarask.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/be-tarask.json
index 6683b125..e547c6ea 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/be-tarask.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/be-tarask.json
@@ -28,4 +28,4 @@
"cite-ve-referenceslist-isempty": "На гэтай старонцы н�� мае зносак з групы «$1».",
"cite-ve-referenceslist-missingref": "Гэтая зноска вызначаная ў шаблёне ці іншым згенэраваным блёку і пакуль можа быць зьмененая толькі ў крынічным рэжыме.",
"cite-ve-toolbar-group-label": "Крыніцы"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/be.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/be.json
index a76d0d4b..f0e9d927 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/be.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/be.json
@@ -21,4 +21,4 @@
"cite-ve-dialog-referenceslist-contextitem-description-general": "Спіс агульных спасылак",
"cite-ve-dialog-referenceslist-contextitem-description-named": "Спіс спасылак для групы \"$1\"",
"cite-ve-dialog-referenceslist-title": "Спіс спасылак"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bg.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bg.json
index 9cfd4231..8cdcb752 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bg.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bg.json
@@ -28,13 +28,13 @@
"cite-ve-dialog-reference-useexisting-label": "Използване на съществуващ източник",
"cite-ve-dialog-reference-useexisting-tool": "Повторно използване",
"cite-ve-dialog-referenceslist-contextitem-description-general": "Списък на общи препратки",
- "cite-ve-dialog-referenceslist-contextitem-description-named": "Списък на препратки от група \"$1\"",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "Списък на препратки от група „$1“",
"cite-ve-dialog-referenceslist-title": "Списък с източници",
"cite-ve-dialogbutton-citation-educationpopup-text": "Подобрява съдържанието, добавяйки списък с източници на информация. Може да цитирате книги, вестници и уебсайтове.",
"cite-ve-dialogbutton-citation-educationpopup-title": "Цитати",
"cite-ve-dialogbutton-reference-full-label": "Основна форма",
"cite-ve-dialogbutton-reference-title": "Източник",
- "cite-ve-dialogbutton-reference-tooltip": "Източник",
+ "cite-ve-dialogbutton-reference-tooltip": "Основен",
"cite-ve-dialogbutton-referenceslist-tooltip": "Списък с източници",
"cite-ve-reference-input-placeholder": "Търсене в текущите цитирания",
"cite-ve-toolbar-group-label": "Цитиране"
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bho.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bho.json
index b76adfd0..81d55743 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bho.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bho.json
@@ -7,4 +7,4 @@
]
},
"cite-ve-dialogbutton-reference-tooltip": "बुनियादी"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bn.json
index 25cf8236..d93ea1fc 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/bn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/bn.json
@@ -20,11 +20,16 @@
"visualeditor-cite-tool-name-news": "সংবাদ",
"visualeditor-cite-tool-name-web": "ওয়েবসাইট",
"cite-tool-definition.json": "কিছু না",
+ "cite-ve-changedesc-reflist-responsive-set": "প্রতিক্রিয়াশীল কলামে প্রদর্শিত হতে তথ্যসূত্রের তালিকাটি পরিবর্তিত করে",
+ "cite-ve-changedesc-reflist-responsive-unset": "কেবলমাত্র একটি কলামে প্রদর্শিত হতে তথ্যসূত্রের তালিকাটি পরিবর্তিত করে",
+ "cite-ve-changedesc-reflist-item-id": "তথ্যসূত্রের সূচক পরিবর্তিত হয়েছে",
"cite-ve-dialog-reference-editing-reused": "এই তথ্যসূত্রটি এই পাতায় $1 {{PLURAL:$1|বার}} ব্যবহৃত হয়েছে।",
"cite-ve-dialog-reference-options-group-label": "এই দল ব্যবহার করুন",
"cite-ve-dialog-reference-options-group-placeholder": "সাধারণ তথ্যসূত্র",
"cite-ve-dialog-reference-options-name-label": "এই নামে পুনঃব্যবহার করুন",
+ "cite-ve-dialog-reference-options-responsive-label": "প্রতিক্রিয়াশীল কলাম বিন্যাস ব্যবহার করুন",
"cite-ve-dialog-reference-options-section": "অপশন",
+ "cite-ve-dialog-reference-placeholder": "এখানে আপনার তথ্যসূত্র লিখুন বা প্রতিলেপন করুন, বা একটি উদ্ধৃতি টেমপ্লেট সন্নিবেশ করুন।",
"cite-ve-dialog-reference-title": "তথ্যসূত্র",
"cite-ve-dialog-reference-useexisting-full-label": "এই পাতায় অস্তিত্ব রয়েছে এমন একটি উদ্ধৃতি পুনঃব্যবহার করুন",
"cite-ve-dialog-reference-useexisting-label": "একটি বিদ্যমান তথ্যসূত্র ব্যবহার করুন",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/br.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/br.json
index fc8d554a..b5f93da7 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/br.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/br.json
@@ -21,4 +21,4 @@
"cite-ve-dialogbutton-reference-tooltip": "Diazez",
"cite-ve-dialogbutton-referenceslist-tooltip": "Roll an daveennoù",
"cite-ve-toolbar-group-label": "Menegiñ"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ca.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ca.json
index 4bbd0891..43053048 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ca.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ca.json
@@ -38,15 +38,16 @@
"cite-ve-dialog-referenceslist-contextitem-description-general": "Llista general de referències",
"cite-ve-dialog-referenceslist-contextitem-description-named": "Llista de referències del grip \"$1\"",
"cite-ve-dialog-referenceslist-title": "Llista de referències",
- "cite-ve-dialogbutton-citation-educationpopup-title": "Referències",
"cite-ve-dialogbutton-citation-educationpopup-text": "Milloreu el contingut afegint fonts d'informació. Podeu citar llibres, diaris i pàgines web.",
+ "cite-ve-dialogbutton-citation-educationpopup-title": "Referències",
"cite-ve-dialogbutton-reference-full-label": "Forma bàsica",
- "cite-ve-dialogbutton-reference-tooltip": "Bàsic",
"cite-ve-dialogbutton-reference-title": "Referència",
+ "cite-ve-dialogbutton-reference-tooltip": "Bàsic",
"cite-ve-dialogbutton-referenceslist-tooltip": "Llista de referències",
"cite-ve-reference-input-placeholder": "Cerca a les referències actuals",
"cite-ve-referenceslist-isempty": "No hi ha cap referència amb el grup «$1» en aquesta pàgina a incloure en aquesta llista.",
"cite-ve-referenceslist-isempty-default": "No hi ha cap referència en aquesta pàgina que incloure en la llista.",
"cite-ve-referenceslist-missingref": "Aquesta referència està definida en una plantilla o un altre tipus de bloc generat, i de moment només pot editar-se amb l'editor de codi font.",
+ "cite-ve-referenceslist-missingreflist": "Aquesta llista de referències ha estat generada per una plantilla i, per ara, només es pot modificar en mode de codi font.",
"cite-ve-toolbar-group-label": "Referència"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/co.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/co.json
index 87eeb008..7686c2ed 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/co.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/co.json
@@ -14,4 +14,4 @@
"cite-ve-dialog-referenceslist-title": "Lista di referenze",
"cite-ve-dialogbutton-reference-tooltip": "Referenza",
"cite-ve-dialogbutton-referenceslist-tooltip": "Lista di referenze"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/cs.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/cs.json
index 61b3e34e..2ccf3e13 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/cs.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/cs.json
@@ -17,7 +17,8 @@
"Aktron",
"Cvanca",
"Kusavica",
- "Dvorapa"
+ "Dvorapa",
+ "Ilimanaq29"
]
},
"visualeditor-cite-tool-definition.json": "prázdný",
@@ -32,11 +33,16 @@
"cite-ve-changedesc-reflist-group-both": "Skupina seznamu referencí změněna z „$1“ na „$2“",
"cite-ve-changedesc-reflist-group-from": "Skupina seznamu referencí změněna z „$1“ na základní",
"cite-ve-changedesc-reflist-group-to": "Skupina seznamu referencí změněna ze základní na „$1“",
+ "cite-ve-changedesc-reflist-responsive-set": "Seznam referencí se nyní zobrazuje v responzivních sloupcích",
+ "cite-ve-changedesc-reflist-responsive-unset": "Seznam referencí se nyní zobrazuje jenom v jednom sloupci",
+ "cite-ve-changedesc-reflist-item-id": "Změněno číslo reference",
"cite-ve-dialog-reference-editing-reused": "Tato reference se na této stránce používá $1{{PLURAL:$1|krát}}.",
"cite-ve-dialog-reference-options-group-label": "Použít tuto skupinu",
"cite-ve-dialog-reference-options-group-placeholder": "Obecné reference",
"cite-ve-dialog-reference-options-name-label": "Znovupoužívat pod tímto názvem",
+ "cite-ve-dialog-reference-options-responsive-label": "Použít responzivní vzhled sloupců",
"cite-ve-dialog-reference-options-section": "Možnosti",
+ "cite-ve-dialog-reference-placeholder": "Sem napište nebo vložte svou referenci nebo citační šablonu.",
"cite-ve-dialog-reference-title": "Reference",
"cite-ve-dialog-reference-useexisting-full-label": "Znovupoužít citaci, která již na stránce existuje",
"cite-ve-dialog-reference-useexisting-label": "Použít existující referenci",
@@ -54,6 +60,9 @@
"cite-ve-referenceslist-isempty": "Na této stránce nejsou žádné reference se skupinou „$1“, které by se v tomto seznamu zobrazily.",
"cite-ve-referenceslist-isempty-default": "Na této stránce nejsou žádné reference, které by se v tomto seznamu zobrazily.",
"cite-ve-referenceslist-missingref": "Tato reference je definována v šabloně nebo jiné generované části textu a zatím ji lze editovat jen v režimu zdrojového textu.",
+ "cite-ve-referenceslist-missingreflist": "Tento seznam referencí je generován šablonou a zatím ho lze editovat pouze v režimu zdrojového textu.",
"cite-ve-toolbar-group-label": "Citace",
- "cite-ve-othergroup-item": "$1 reference"
+ "cite-ve-othergroup-item": "$1 reference",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Reference",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Název skupiny referencí: „$1“"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/cu.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/cu.json
index 6fae05f8..4be219b1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/cu.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/cu.json
@@ -10,4 +10,4 @@
"visualeditor-cite-tool-name-web": "мєждоусѣтьно мѣсто",
"cite-ve-dialog-reference-options-section": "строи",
"cite-ve-dialogbutton-reference-title": "Источник"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/da.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/da.json
index 86855372..e17fa81f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/da.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/da.json
@@ -11,7 +11,8 @@
"Sarrus",
"McDutchie",
"Macofe",
- "Ribewiki"
+ "Ribewiki",
+ "Jorn Ari"
]
},
"visualeditor-cite-tool-name-book": "Bog",
@@ -29,5 +30,6 @@
"cite-ve-reference-input-placeholder": "Søg i de aktuelle referencer",
"cite-ve-referenceslist-isempty": "Der er ingen referencer med gruppen \"$1\" på denne side, som kan medtages i denne liste.",
"cite-ve-referenceslist-isempty-default": "Der er ingen referencer på denne side som kan medtages i denne liste.",
- "cite-ve-referenceslist-missingref": "Denne reference er defineret i en skabelon eller en anden genereret blok, og kan foreløbig kun redigeres i wikikode tilstand."
-} \ No newline at end of file
+ "cite-ve-referenceslist-missingref": "Denne reference er defineret i en skabelon eller en anden genereret blok, og kan foreløbig kun redigeres i wikikode tilstand.",
+ "cite-ve-referenceslist-missingreflist": "Denne referenceliste genereres af en skabelon, og kan nu kun redigeres i kildefunktion."
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/de.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/de.json
index 78caf5c0..b77a75fd 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/de.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/de.json
@@ -28,6 +28,8 @@
"cite-ve-changedesc-reflist-group-both": "Einzelnachweislistengruppe geändert von „$1“ in „$2“",
"cite-ve-changedesc-reflist-group-from": "Einzelnachweislistengruppe geändert von „$1“ in die allgemeine Gruppe",
"cite-ve-changedesc-reflist-group-to": "Einzelnachweislistengruppe geändert von der allgemeinen Gruppe in „$1“",
+ "cite-ve-changedesc-reflist-responsive-set": "Die Einzelnachweisliste wird jetzt in reagierenden Spalten angezeigt",
+ "cite-ve-changedesc-reflist-responsive-unset": "Die Einzelnachweisliste wird jetzt in nur einer Spalte angezeigt",
"cite-ve-changedesc-reflist-item-id": "Einzelnachweisindex geändert",
"cite-ve-dialog-reference-editing-reused": "Dieser Einzelnachweis wird auf dieser Seite {{PLURAL:$1|einmal|$1 Mal}} verwendet.",
"cite-ve-dialog-reference-options-group-label": "Diese Gruppe verwenden",
@@ -53,6 +55,8 @@
"cite-ve-referenceslist-isempty": "Auf dieser Seite gibt es keine Einzelnachweise mit der Gruppe „$1“ zum Anzeigen in dieser Liste.",
"cite-ve-referenceslist-isempty-default": "Auf dieser Seite gibt es keine Einzelnachweise zum Anzeigen in dieser Liste.",
"cite-ve-referenceslist-missingref": "Dieser Einzelnachweis ist in einer Vorlage oder einem anderen erzeugten Block definiert und kann derzeit nur im Quelltextmodus bearbeitet werden.",
+ "cite-ve-referenceslist-missingref-in-list": "Dieser Einzelnachweis wird in einer Vorlage oder einem anderen erzeugten Block definiert und derzeit kann eine Vorschau nur im Quelltextmodus angezeigt werden.",
+ "cite-ve-referenceslist-missingreflist": "Diese Einzelnachweisliste wurde von einer Vorlage erzeugt und kann derzeit nur im Quelltextmodus bearbeitet werden.",
"cite-ve-toolbar-group-label": "Zitat",
"cite-ve-othergroup-item": "$1-Einzelnachweis",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referenzierungen",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/dsb.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/dsb.json
index b9b54f27..d60846dd 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/dsb.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/dsb.json
@@ -21,4 +21,4 @@
"cite-ve-reference-input-placeholder": "Co coš referencěrowaś?",
"cite-ve-referenceslist-isempty": "Njejsu žedne reference z kupku \"$1\" na toś tom boku, kótarež daju se do toś teje lisćiny zapśimjeś.",
"cite-ve-referenceslist-isempty-default": "Njejsu reference na toś tom boku, kótarež daju se do toś teje lisćiny zapśimjeś."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/egl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/egl.json
index 41f5db36..4e5f7b60 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/egl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/egl.json
@@ -21,4 +21,4 @@
"cite-ve-referenceslist-isempty": "An gh'é mìa riferimèint cun al gróp \"$1\" insém a cla pàgina ché da mèter dèinter in cl'elèinch ché.",
"cite-ve-referenceslist-isempty-default": "An gh'é mìa riferimèint insém a cla pàgina ché da mèter dèinter in cl'elèinch ché.",
"cite-ve-referenceslist-missingref": "Cla nôta ché an n'é mìa dichiarêda in un mudèl o in un êter blôch fât e p'r adèsa la pōl èser mudifichêda sōl int la manēra surzéia."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/el.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/el.json
index 5d25f2d9..6ae98a81 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/el.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/el.json
@@ -13,13 +13,16 @@
"Protnet",
"Stam.nikos",
"Macofe",
- "SucreRouge"
+ "SucreRouge",
+ "Nikosgranturismogt"
]
},
+ "visualeditor-cite-tool-definition.json": "κενό",
"visualeditor-cite-tool-name-book": "Βιβλίο",
"visualeditor-cite-tool-name-journal": "Περιοδικό",
"visualeditor-cite-tool-name-news": "Ειδήσεις",
"visualeditor-cite-tool-name-web": "Ιστότοπος",
+ "cite-tool-definition.json": "κενό",
"cite-ve-dialog-reference-editing-reused": "Αυτή η παραπομπή χρησιμοποιείται $1 {{PLURAL:$1|φορά|φορές}} σε αυτή τη σελίδα.",
"cite-ve-dialog-reference-options-group-label": "Χρησιμοποιείστε αυτή την ομάδα",
"cite-ve-dialog-reference-options-group-placeholder": "Γενικές αναφορές",
@@ -38,9 +41,11 @@
"cite-ve-dialogbutton-reference-title": "Παραπομπή",
"cite-ve-dialogbutton-reference-tooltip": "Βασικό",
"cite-ve-dialogbutton-referenceslist-tooltip": "Κατάλογος παραπομπών",
- "cite-ve-reference-input-placeholder": "Αναζήτηση εντός των τρεχόντων παραπομπών",
+ "cite-ve-reference-input-placeholder": "Αναζήτηση εντός των τρεχουσών παραπομπών",
"cite-ve-referenceslist-isempty": "Δεν υπάρχουν παραπομπές με την ομάδα «$1» σε αυτήν τη σελίδα για να περιληφθούν σε αυτόν τον κατάλογο.",
"cite-ve-referenceslist-isempty-default": "Δεν υπάρχουν παραπομπές σε αυτήν τη σελίδα για να περιληφθούν σε αυτόν τον κατάλογο.",
"cite-ve-referenceslist-missingref": "Η παραπομπή αυτή έχει οριστεί μέσω προτύπου ή άλλου αυτόματα παραγόμενου μπλοκ και, προς το παρόν, δεν μπορείτε να την επεξεργαστείτε με τον VisualEditor. Χρησιμοποιήστε τον επεξεργαστή κώδικα.",
- "cite-ve-toolbar-group-label": "Παραπομπή"
+ "cite-ve-toolbar-group-label": "Παραπομπή",
+ "cite-ve-othergroup-item": "$1 παραπομπή",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Παραπομπές"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/eml.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/eml.json
index 5dccf4ff..06f81a54 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/eml.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/eml.json
@@ -23,4 +23,4 @@
"cite-ve-referenceslist-isempty-default": "In cla pagina chè an gh' è brîśa di riferimèint da mèter dèint'r a cla lìsta chè.",
"cite-ve-referenceslist-missingref": "Cla nôta ché l'é fisêda in un mudèl o in 'n êter blôch fât e per adès la pōl èser mudufichêda sôl iint al môd surzéia.",
"cite-ve-toolbar-group-label": "Sitèr"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/en.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/en.json
index a118b8aa..3e03cf78 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/en.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/en.json
@@ -28,6 +28,8 @@
"cite-ve-changedesc-reflist-group-both": "References list group changed from \"$1\" to \"$2\"",
"cite-ve-changedesc-reflist-group-from": "References list group changed from \"$1\" to the general group",
"cite-ve-changedesc-reflist-group-to": "References list group changed from the general group to \"$1\"",
+ "cite-ve-changedesc-reflist-responsive-set": "References list changed to display in responsive columns",
+ "cite-ve-changedesc-reflist-responsive-unset": "References list changed to display in only one column",
"cite-ve-changedesc-reflist-item-id": "Reference index changed",
"cite-ve-dialog-reference-editing-reused": "This reference is used $1 {{PLURAL:$1|times}} on this page.",
"cite-ve-dialog-reference-options-group-label": "Use this group",
@@ -53,6 +55,8 @@
"cite-ve-referenceslist-isempty": "There are no references with the group \"$1\" on this page to include in this list.",
"cite-ve-referenceslist-isempty-default": "There are no references on this page to include in this list.",
"cite-ve-referenceslist-missingref": "This reference is defined in a template or other generated block, and for now can only be edited in source mode.",
+ "cite-ve-referenceslist-missingref-in-list": "This reference is defined in a template or other generated block, and for now can only be previewed in source mode.",
+ "cite-ve-referenceslist-missingreflist": "This reference list is generated by a template, and for now can only be edited in source mode.",
"cite-ve-toolbar-group-label": "Cite",
"cite-ve-othergroup-item": "$1 reference",
"visualeditor-internal-list-diff-default-group-name-mwreference": "References",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/eo.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/eo.json
index afed326a..1cbd219d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/eo.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/eo.json
@@ -30,4 +30,4 @@
"cite-ve-reference-input-placeholder": "Serĉi en nuntempaj refrencoj",
"cite-ve-referenceslist-isempty": "En tiu ĉi paĝo ne estas referencoj de grupo \"$1\" por aldoni al tiu ĉi listo.",
"cite-ve-referenceslist-isempty-default": "En tiu ĉi paĝo ne estas referencoj por aldoni al tiu ĉi listo."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/es.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/es.json
index b571b46c..6a91af7e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/es.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/es.json
@@ -36,7 +36,7 @@
"visualeditor-cite-tool-name-news": "Noticias",
"visualeditor-cite-tool-name-web": "Sitio web",
"cite-tool-definition.json": "nulo",
- "cite-ve-changedesc-ref-group-both": "El grupo de referencia cambió de «$1» a «$2»",
+ "cite-ve-changedesc-ref-group-both": "El grupo de referencias cambió de «$1» a «$2»",
"cite-ve-changedesc-ref-group-from": "El grupo de referencias cambió de «$1» al grupo general",
"cite-ve-changedesc-ref-group-to": "El grupo de referencias cambió del grupo general a «$1»",
"cite-ve-changedesc-reflist-group-both": "El grupo de lista de referencias cambió de «$1» a «$2»",
@@ -46,7 +46,9 @@
"cite-ve-dialog-reference-options-group-label": "Usar este grupo",
"cite-ve-dialog-reference-options-group-placeholder": "Referencias generales",
"cite-ve-dialog-reference-options-name-label": "Reutilizar con este nombre",
+ "cite-ve-dialog-reference-options-responsive-label": "Utilizar disposición de columnas adaptable",
"cite-ve-dialog-reference-options-section": "Opciones",
+ "cite-ve-dialog-reference-placeholder": "Escribe o pega la referencia aquí, o bien, inserta una plantilla de cita.",
"cite-ve-dialog-reference-title": "Referencia",
"cite-ve-dialog-reference-useexisting-full-label": "Reutilizar una cita que ya existe en esta página",
"cite-ve-dialog-reference-useexisting-label": "Utilizar una referencia existente",
@@ -64,6 +66,8 @@
"cite-ve-referenceslist-isempty": "No hay referencias con el grupo «$1» en esta página para incluir en la lista.",
"cite-ve-referenceslist-isempty-default": "No hay referencias en esta página para incluir en esta lista.",
"cite-ve-referenceslist-missingref": "Esta referencia está definida en una plantilla u otro tipo de bloque generado, y por ahora sólo puede editarse en el editor de fuente.",
+ "cite-ve-referenceslist-missingref-in-list": "Esta referencia está definida en una plantilla u otro bloque generado y, por ahora, solo puede previsualizarse en modo código.",
+ "cite-ve-referenceslist-missingreflist": "Esta lista de referencias la generó una plantilla; por ahora solo puede modificarse en el modo de código fuente.",
"cite-ve-toolbar-group-label": "Citar",
"cite-ve-othergroup-item": "referencia $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referencias",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/et.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/et.json
index 1919c697..b6a4ddbd 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/et.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/et.json
@@ -19,10 +19,14 @@
"cite-ve-changedesc-reflist-group-both": "Vahetatud viiteloendi rühm \"$1\" rühma \"$2\" vastu",
"cite-ve-changedesc-reflist-group-from": "Vahetatud viiteloendi rühm \"$1\" üldviidete rühma vastu",
"cite-ve-changedesc-reflist-group-to": "Vahetatud viiteloendi üldviidete rühm rühma \"$1\" vastu",
+ "cite-ve-changedesc-reflist-responsive-set": "Vahetatud viiteloendi kuva isereguleeruvate veergude vastu",
+ "cite-ve-changedesc-reflist-responsive-unset": "Vahetatud viiteloendi kuva ainult ühe veeru vastu",
+ "cite-ve-changedesc-reflist-item-id": "Vahetatud viite indeks",
"cite-ve-dialog-reference-editing-reused": "Seda viidet on sellel leheküljel kasutatud {{PLURAL:$1|ühel korral|$1 korda}}.",
"cite-ve-dialog-reference-options-group-label": "Viiterühm",
"cite-ve-dialog-reference-options-group-placeholder": "Üldviited",
"cite-ve-dialog-reference-options-name-label": "Korduvkasutusnimi",
+ "cite-ve-dialog-reference-options-responsive-label": "Kasuta isereguleeruvat veergude paigutust",
"cite-ve-dialog-reference-options-section": "Suvandid",
"cite-ve-dialog-reference-placeholder": "Kirjuta või kleebi siia viide või lisa viitemall.",
"cite-ve-dialog-reference-title": "Viide",
@@ -42,6 +46,7 @@
"cite-ve-referenceslist-isempty": "Rühma \"$1\" viited, mida selles loendis näidata, puuduvad sellel leheküljel.",
"cite-ve-referenceslist-isempty-default": "Viited, mida selles loendis näidata, puuduvad sellel leheküljel.",
"cite-ve-referenceslist-missingref": "Selle viite kirjeldus on mallis või muul moel genereeritud plokis ning praegu saab seda redigeerida vaid lähteteksti režiimis.",
+ "cite-ve-referenceslist-missingreflist": "Selle viiteloendi tekitab mall ja praegu saab seda redigeerida ainult lähteteksti režiimis.",
"cite-ve-toolbar-group-label": "Viide",
"cite-ve-othergroup-item": "Viide: {{lc:$1}}",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Viited",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/eu.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/eu.json
index 740bc2be..dcb5aa57 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/eu.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/eu.json
@@ -7,7 +7,8 @@
"Subi",
"Sator",
"Macofe",
- "Mikel Ibaiba"
+ "Mikel Ibaiba",
+ "Asierog"
]
},
"visualeditor-cite-tool-definition.json": "nulu",
@@ -16,6 +17,12 @@
"visualeditor-cite-tool-name-news": "Albisteak",
"visualeditor-cite-tool-name-web": "Webgunea",
"cite-tool-definition.json": "nulu",
+ "cite-ve-changedesc-ref-group-both": "Erreferentzia taldea aldatu dute \"$1\" izatetik \"$2\" izatera",
+ "cite-ve-changedesc-ref-group-from": "Erreferentzia taldea aldatu dute \"$1\" izatetik talde orokorrera",
+ "cite-ve-changedesc-ref-group-to": "Erreferentzia taldea aldatu dute talde orokorretik \"$1\" izatera",
+ "cite-ve-changedesc-reflist-group-both": "Erreferentzia zerrendaren taldea aldatu dute \"$1\" izatetik \"$2\" izatera",
+ "cite-ve-changedesc-reflist-group-from": "Erreferentzia zerrendaren taldea aldatu dute \"$1\" izatetik talde orokorrera",
+ "cite-ve-changedesc-reflist-group-to": "Erreferentzia zerrendaren taldea aldatu dute talde orokorretik \"$1\" izatera",
"cite-ve-dialog-reference-editing-reused": "Erreferentzia hau $1{{PLURAL:$1|aldiz}} agertzen da orri honetan",
"cite-ve-dialog-reference-options-group-label": "Talde hau erabili",
"cite-ve-dialog-reference-options-group-placeholder": "Erreferentzia orokorrak",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fa.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fa.json
index 0c7099ba..bf8e51af 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fa.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fa.json
@@ -20,7 +20,8 @@
"Leyth",
"MRG90",
"الناز",
- "فلورانس"
+ "فلورانس",
+ "Huji"
]
},
"visualeditor-cite-tool-definition.json": "تهی",
@@ -29,21 +30,24 @@
"visualeditor-cite-tool-name-news": "اخبار",
"visualeditor-cite-tool-name-web": "وب‌گاه",
"cite-tool-definition.json": "تهی",
- "cite-ve-changedesc-ref-group-both": "ارجاع‌های گروهی از «$1» به «$2» تغییر یافت",
- "cite-ve-changedesc-ref-group-from": "ارجاع‌های گروهی از «$1» به گروه‌های عمومی تغییر یافت",
- "cite-ve-changedesc-ref-group-to": "ارجاع‌های گروهی از گروه‌های عمومی به «$1» تغییر یافت",
- "cite-ve-changedesc-reflist-group-both": "فهرست ارجاع‌های گروهی از «$1» به «$2» تغییر یافت",
- "cite-ve-changedesc-reflist-group-from": "فهرست ارجاع‌های گروهی از «$1» به گروه عمومی تغییر یافت",
- "cite-ve-changedesc-reflist-group-to": "فهرست ارجاع‌های گروهی از گروه عمومی به «$1» تغییر یافت",
+ "cite-ve-changedesc-ref-group-both": "گروه منبع از «$1» به «$2» تغییر یافت",
+ "cite-ve-changedesc-ref-group-from": "گروه منبع از «$1» به گروه عمومی تغییر یافت",
+ "cite-ve-changedesc-ref-group-to": "گروه منبع از گروه عمومی به «$1» تغییر یافت",
+ "cite-ve-changedesc-reflist-group-both": "فهرست منبع یادکرد از «$1» به «$2» تغییر یافت",
+ "cite-ve-changedesc-reflist-group-from": "فهرست گروه منبع از «$1» به گروه عمومی تغییر یافت",
+ "cite-ve-changedesc-reflist-group-to": "فهرست گروه منبع از گروه عمومی به «$1» تغییر یافت",
+ "cite-ve-changedesc-reflist-responsive-set": "فهرست منابع به حالت ستون‌های تعاملی تغییر یافت",
+ "cite-ve-changedesc-reflist-responsive-unset": "فهرست منابع به یک ستون تغییر یافت",
"cite-ve-changedesc-reflist-item-id": "نمایه منابع تغییریافت",
- "cite-ve-dialog-reference-editing-reused": "این یادکرد $1 {{PLURAL:$1|times}} در این صفحه استفاده شده‌است.",
+ "cite-ve-dialog-reference-editing-reused": "این منبع $1 {{PLURAL:$1|بار}} در این صفحه استفاده شده‌است.",
"cite-ve-dialog-reference-options-group-label": "استفاده از این گروه",
"cite-ve-dialog-reference-options-group-placeholder": "منابع عمومی",
"cite-ve-dialog-reference-options-name-label": "استفاده دوباره با این نام",
+ "cite-ve-dialog-reference-options-responsive-label": "از صفحه‌بندی ستون واکنشی استفاده کنید",
"cite-ve-dialog-reference-options-section": "گزینه‌ها",
- "cite-ve-dialog-reference-placeholder": "ارجاعتان را اینجا قرار دهید یا بنویسید یا از الگوی یادکرد استفاده کنید.",
+ "cite-ve-dialog-reference-placeholder": "منبع‌تان را اینجا بچسبانید یا بنویسید، یا از الگوی یادکرد استفاده کنید.",
"cite-ve-dialog-reference-title": "منبع",
- "cite-ve-dialog-reference-useexisting-full-label": "استفاده دوباره یک پانویس موجود در این صفحه",
+ "cite-ve-dialog-reference-useexisting-full-label": "استفاده دوباره یک یادکرد موجود در این صفحه",
"cite-ve-dialog-reference-useexisting-label": "استفاده از یک منبع موجود",
"cite-ve-dialog-reference-useexisting-tool": "استفادهٔ مجدد",
"cite-ve-dialog-referenceslist-contextitem-description-general": "فهرست منابع عمومی",
@@ -55,12 +59,14 @@
"cite-ve-dialogbutton-reference-title": "منبع",
"cite-ve-dialogbutton-reference-tooltip": "مقدماتی",
"cite-ve-dialogbutton-referenceslist-tooltip": "فهرست منابع",
- "cite-ve-reference-input-placeholder": "جستجو داخل ارجاع‌های کنونی",
- "cite-ve-referenceslist-isempty": "ارجاعی با گروه «$1» در این صفحه برای شامل‌کردن در این فهرست وجود ندارد.",
- "cite-ve-referenceslist-isempty-default": "ارجاعی در این صفحه برای شامل‌کردن در این فهرست وجود ندارد.",
- "cite-ve-referenceslist-missingref": "این یادکرد درون یک الگو یا قطعهٔ تولیدی دیگر تعریف شده است و هم‌اکنون تنها می‌توان در حالت متنی آن را ویرایش کرد",
+ "cite-ve-reference-input-placeholder": "جستجو داخل یادکردهای کنونی",
+ "cite-ve-referenceslist-isempty": "منبعی با گروه «$1» در این صفحه برای شامل‌کردن در این فهرست وجود ندارد.",
+ "cite-ve-referenceslist-isempty-default": "منبعی در این صفحه برای شامل‌کردن در این فهرست وجود ندارد.",
+ "cite-ve-referenceslist-missingref": "این منبع درون یک الگو یا قطعهٔ تولیدی دیگر تعریف شده است و هم‌اکنون تنها می‌توان در حالت متنی آن را ویرایش کرد",
+ "cite-ve-referenceslist-missingref-in-list": "منبع تعریف شده درون الگو یا سایر بلوک‌های شبیه‌سازی شده در حال حاضر فقط به صورت حالت متنی قابل مشاهده هست.",
+ "cite-ve-referenceslist-missingreflist": "این فهرست منابع به کمک یک الگو ایجاد شده‌است که فقط امکان ویرایش آن در حالت ویرایش متنی وجود دارد.",
"cite-ve-toolbar-group-label": "یادکرد",
- "cite-ve-othergroup-item": "$1 ارجاع",
+ "cite-ve-othergroup-item": "$1 منبع",
"visualeditor-internal-list-diff-default-group-name-mwreference": "منابع",
- "visualeditor-internal-list-diff-group-name-mwreference": "نام گروه منابع: «$1»"
+ "visualeditor-internal-list-diff-group-name-mwreference": "نام گروه منبع: «$1»"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fo.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fo.json
index 882ea7c4..73bf64e0 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fo.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fo.json
@@ -20,4 +20,4 @@
"cite-ve-referenceslist-isempty": "Tað eru ongar kelduávísingar við bólkinum \"$1\" á hesi síðu, sum kunnu takast við í henda listan.",
"cite-ve-referenceslist-isempty-default": "Tað eru ongar keldur á hesi síðu sum kunnu takast við í henda listan.",
"cite-ve-referenceslist-missingref": "Henda keldan er skrásett í einari fyrimynd ella øðrum upprættaðum blokki, og kann í løtuni bert rættast í keldustøðu (source mode)."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fr.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fr.json
index 7df890b2..42556f99 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fr.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fr.json
@@ -61,11 +61,14 @@
"cite-ve-changedesc-reflist-group-both": "Groupe de liste de référence modifié de « $1 » en « $2 »",
"cite-ve-changedesc-reflist-group-from": "Groupe de liste de référence modifié de « $1 » vers le groupe général",
"cite-ve-changedesc-reflist-group-to": "Groupe de liste de référence modifié du groupe général vers « $1 »",
+ "cite-ve-changedesc-reflist-responsive-set": "Liste des références modifiées pour affichage dans des colonnes réactives",
+ "cite-ve-changedesc-reflist-responsive-unset": "Liste des références modifiées à afficher dans une seule colonne",
"cite-ve-changedesc-reflist-item-id": "Le numéro de la source a changé",
"cite-ve-dialog-reference-editing-reused": "Cette référence est utilisée $1 {{PLURAL:$1|fois}} sur cette page.",
"cite-ve-dialog-reference-options-group-label": "Utiliser ce groupe",
"cite-ve-dialog-reference-options-group-placeholder": "Références générales",
"cite-ve-dialog-reference-options-name-label": "Réutiliser avec ce nom",
+ "cite-ve-dialog-reference-options-responsive-label": "Utiliser une disposition réactive en colonnes",
"cite-ve-dialog-reference-options-section": "Options",
"cite-ve-dialog-reference-placeholder": "Ecrire ou coller ici votre référence, ou insérer un modèle de citation.",
"cite-ve-dialog-reference-title": "Référence",
@@ -85,6 +88,8 @@
"cite-ve-referenceslist-isempty": "Il n’y a aucune référence avec le groupe « $1 » sur cette page à inclure dans cette liste.",
"cite-ve-referenceslist-isempty-default": "Il n’y a aucune référence sur cette page à inclure dans cette liste.",
"cite-ve-referenceslist-missingref": "Cette référence est définie dans un modèle ou un autre bloc généré et ne peut pour le moment être modifiée qu’avec l’éditeur de wikicode.",
+ "cite-ve-referenceslist-missingref-in-list": "Cette référence est définie dans un modèle ou un autre bloc généré, et pour le moment, il ne peut être affiché en aperçu qu’en mode source.",
+ "cite-ve-referenceslist-missingreflist": "Cette liste de référence est générée par un modèle, et actuellement, elle ne peut être modifiée qu’en mode source.",
"cite-ve-toolbar-group-label": "Source",
"cite-ve-othergroup-item": "référence $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Références",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/frr.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/frr.json
index 8e413902..fa7ca10f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/frr.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/frr.json
@@ -22,4 +22,4 @@
"cite-ve-referenceslist-isempty": "Diar san nian futnuuten mä det skööl \"$1\" üüb detdiar sidj tu uunwisin uun detdiar list.",
"cite-ve-referenceslist-isempty-default": "Üüb detdiar sidj san nian futnuuten tu uunwisin uun detdiar list.",
"cite-ve-referenceslist-missingref": "Detdiar referens as auer en föörlaag of en öödern blook fäästlaanj an koon tu tidj bluas uun a kweltekst feranert wurd."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fur.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fur.json
index 1ced795e..2b345386 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fur.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fur.json
@@ -21,4 +21,4 @@
"cite-ve-dialogbutton-referenceslist-tooltip": "Liste dai riferiments",
"cite-ve-reference-input-placeholder": "A ce vuelistu fâ riferiment?",
"cite-ve-toolbar-group-label": "Citazion"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fy.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fy.json
index 36a652c7..ae732f57 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/fy.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/fy.json
@@ -9,4 +9,4 @@
"cite-ve-dialog-referenceslist-title": "List mei referinsjes",
"cite-ve-dialogbutton-reference-tooltip": "Basis",
"cite-ve-dialogbutton-referenceslist-tooltip": "List mei referinsjes"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ga.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ga.json
index ecdb180a..d26762db 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ga.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ga.json
@@ -2,9 +2,11 @@
"@metadata": {
"authors": [
"Alison",
- "Kscanne"
+ "Kscanne",
+ "Nmacu"
]
},
"cite-ve-dialog-reference-options-section": "Roghanna",
- "cite-ve-dialog-referenceslist-title": "Liosta tagairtí"
-} \ No newline at end of file
+ "cite-ve-dialog-referenceslist-title": "Liosta tagairtí",
+ "cite-ve-toolbar-group-label": "Luaigh"
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gl.json
index 951b42d4..b83fd600 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gl.json
@@ -31,6 +31,7 @@
"cite-ve-dialog-reference-options-group-label": "Utilizar este grupo",
"cite-ve-dialog-reference-options-group-placeholder": "Referencias xerais",
"cite-ve-dialog-reference-options-name-label": "Reutilizar por este nome",
+ "cite-ve-dialog-reference-options-responsive-label": "Utilizar disposición adaptable en columnas",
"cite-ve-dialog-reference-options-section": "Opcións",
"cite-ve-dialog-reference-placeholder": "Escribe ou pega a túa referencia aquí, ou insire un modelo de cita.",
"cite-ve-dialog-reference-title": "Referencia",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/glk.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/glk.json
index e80d1b12..e6827fc8 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/glk.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/glk.json
@@ -11,4 +11,4 @@
"cite-ve-dialogbutton-reference-title": "سربس",
"cite-ve-dialogbutton-referenceslist-tooltip": "سربسؤنˇ ليست",
"cite-ve-toolbar-group-label": "نقلˇ قؤل"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-deva.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-deva.json
index 6920cb84..d25e00cb 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-deva.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-deva.json
@@ -8,4 +8,4 @@
]
},
"cite-ve-dialogbutton-reference-title": "संदर्भ"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-latn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-latn.json
index 2dec17b3..527d6ad2 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-latn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gom-latn.json
@@ -5,4 +5,4 @@
]
},
"cite-ve-dialog-reference-title": "Sondorbh"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gsw.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gsw.json
index 9c80d55b..9211cce2 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/gsw.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/gsw.json
@@ -12,4 +12,4 @@
"cite-ve-dialog-reference-title": "Fuessnote",
"cite-ve-dialog-reference-useexisting-label": "Fuessnote bruche, wo s scho git",
"cite-ve-dialog-referenceslist-title": "Lischte vo allene Fuessnote"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/he.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/he.json
index 68f40804..42d4c4ba 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/he.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/he.json
@@ -31,11 +31,14 @@
"cite-ve-changedesc-reflist-group-both": "קבוצת רשימת הערות שוליים שונתה מ{{GRAMMAR:תחילית|$1}} ל{{GRAMMAR:תחילית|$2}}",
"cite-ve-changedesc-reflist-group-from": "קבוצת רשימת הערות שוליים שונתה מ{{GRAMMAR:תחילית|$1}} לכללית",
"cite-ve-changedesc-reflist-group-to": "קבוצת הערות שוליים שונתה מכללית ל{{GRAMMAR:תחילית|$1}}",
+ "cite-ve-changedesc-reflist-responsive-set": "רשימת הערות השוליים שונתה לתצוגה בעמודות מותאמות לגודל המסך",
+ "cite-ve-changedesc-reflist-responsive-unset": "רשימת הערות השוליים שונתה לתצוגה בעמודה אחת",
"cite-ve-changedesc-reflist-item-id": "מפתח הערת השוליים השתנה",
"cite-ve-dialog-reference-editing-reused": "הערת השוליים משמשת {{PLURAL:$1|פעם אחת|פעמיים|$1 פעמים}} בדף הזה.",
"cite-ve-dialog-reference-options-group-label": "להשתמש בקבוצה הזאת",
"cite-ve-dialog-reference-options-group-placeholder": "הערות שוליים כלליות",
"cite-ve-dialog-reference-options-name-label": "שם לשימוש חוזר",
+ "cite-ve-dialog-reference-options-responsive-label": "להשתמש בעיצוב עם התאמה אוטומטית",
"cite-ve-dialog-reference-options-section": "אפשרויות",
"cite-ve-dialog-reference-placeholder": "נא לרשום או להדביק את הערת השוליים שלך כאן, או להכניס תבנית הערת שוליים.",
"cite-ve-dialog-reference-title": "הערת שוליים",
@@ -55,6 +58,7 @@
"cite-ve-referenceslist-isempty": "לא קיימים מקורות עם קבוצה בשם \"$1\" בדף הזה שאפשר לכלול ברשימה הזאת.",
"cite-ve-referenceslist-isempty-default": "בדף הזה אין הערות שוליים שאפשר לכלול ברשימה הזאת.",
"cite-ve-referenceslist-missingref": "הערת השוליים הזאת מוגדרת בתבנית או מחוללת בדרך אחרת כלשהי, ואי־אפשר לערוך אותה עדיין באמצעות העורך החזותי.",
+ "cite-ve-referenceslist-missingreflist": "רשימת הערות השוליים הזאת מחוללת באמצעות תבנית, ולעת־עתה אפשר לערוך אותה רק במצב קוד מקור.",
"cite-ve-toolbar-group-label": "הערת שוליים",
"cite-ve-othergroup-item": "הערה $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "הערות שוליים",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hi.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hi.json
index 94bbbe1c..45ace44f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hi.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hi.json
@@ -15,7 +15,8 @@
"Ankita-ks",
"Sahilrathod",
"Hindustanilanguage",
- "Sfic"
+ "Sfic",
+ "Sachinkatiyar"
]
},
"visualeditor-cite-tool-name-book": "पुस्तक",
@@ -43,6 +44,7 @@
"cite-ve-referenceslist-isempty": "इस पृष्ठ पर \"$1\" सन्दर्भ समूह में कोई सन्दर्भ नहीं हैं जो इस सूची में जोड़े जा सकें।",
"cite-ve-referenceslist-isempty-default": "इस पृष्ठ पर कोई सन्दर्भ नहीं हैं जो इस सूची में जोड़े जा सकें।",
"cite-ve-referenceslist-missingref": "ये सन्दर्भ किसी साँचे या अन्य ब्लॉक का प्रयोग करता है, और इसलिए अभी केवल स्रोत सम्पादन में सम्पादित किया जा सकता है।",
+ "cite-ve-referenceslist-missingref-in-list": "ये सन्दर्भ किसी साँचे या अन्य ब्लॉक का प्रयोग करता है, और इसलिए अभी केवल स्रोत सम्पादन में सम्पादित किया जा सकता है।",
"cite-ve-toolbar-group-label": "उद्धृत करें",
"cite-ve-othergroup-item": "$1 सन्दर्भ"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hr.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hr.json
index 9d434532..2a2f587f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hr.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hr.json
@@ -7,11 +7,12 @@
"Zeljko.filipin",
"Milicevic01",
"Teoo3",
- "Bugoslav"
+ "Bugoslav",
+ "Acamicamacaraca"
]
},
"visualeditor-cite-tool-name-book": "Knjiga",
- "visualeditor-cite-tool-name-journal": "Dnevnik",
+ "visualeditor-cite-tool-name-journal": "Časopis",
"visualeditor-cite-tool-name-news": "Vijesti",
"visualeditor-cite-tool-name-web": "Web stranice",
"cite-ve-dialog-reference-editing-reused": "Ova je referencija rabljena $1 {{PLURAL:$1|put|puta}} na ovoj stranici.",
@@ -19,6 +20,7 @@
"cite-ve-dialog-reference-options-group-placeholder": "Opće referencije",
"cite-ve-dialog-reference-options-name-label": "Ponovno koristi pod ovim imenom",
"cite-ve-dialog-reference-options-section": "Mogućnosti",
+ "cite-ve-dialog-reference-placeholder": "Ovdje napišite ili kopirajte referencu ili umetnite predložak za citiranje.",
"cite-ve-dialog-reference-title": "Izvori",
"cite-ve-dialog-reference-useexisting-full-label": "Ponovna uporaba citata koji već postoji na ovoj stranici",
"cite-ve-dialog-reference-useexisting-label": "Koristi postojeći izvor",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hsb.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hsb.json
index 0249d0e1..48db69a4 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hsb.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hsb.json
@@ -22,4 +22,4 @@
"cite-ve-reference-input-placeholder": "Što chceš referencować?",
"cite-ve-referenceslist-isempty": "Referency ze skupinu \"$1\" za zapřijimanje do tuteje lisćiny njejsu.",
"cite-ve-referenceslist-isempty-default": "Njejsu referency na tuej stronje, kotrež hodźa so do tuteje lisćiny zapřijeć."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu-formal.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu-formal.json
index b1ad5d24..40873afb 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu-formal.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu-formal.json
@@ -15,4 +15,4 @@
"cite-ve-dialog-reference-options-section": "Beállítások",
"cite-ve-dialog-reference-useexisting-tool": "Újrafelhasználás",
"cite-ve-dialogbutton-reference-full-label": "Alapvető forma"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu.json
index 2035694e..077ed0fa 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hu.json
@@ -16,11 +16,19 @@
"visualeditor-cite-tool-name-journal": "Folyóirat",
"visualeditor-cite-tool-name-news": "Hír",
"visualeditor-cite-tool-name-web": "Weboldal",
+ "cite-ve-changedesc-ref-group-both": "Forráshivatkozás-csoport megváltozott erről: „$1” erre: „$2”",
+ "cite-ve-changedesc-ref-group-from": "Forráshivatkozás-csoport megváltozott erről: „$1” az általános csoportra",
+ "cite-ve-changedesc-ref-group-to": "Forráshivatkozás-csoport megváltozott az általános csoportról erre: „$1”",
+ "cite-ve-changedesc-reflist-group-both": "Forráslista-csoport megváltozott erről: „$1” erre: „$2”",
+ "cite-ve-changedesc-reflist-group-from": "Forráslista-csoport megváltozott erről: „$1” az általános csoportra",
+ "cite-ve-changedesc-reflist-group-to": "Forráslista-csoport megváltozott az általános csoportról erre: „$1”",
"cite-ve-dialog-reference-editing-reused": "Ez a forráshivatkozás $1 helyen szerepel ezen a lapon.",
"cite-ve-dialog-reference-options-group-label": "Csoport használata",
"cite-ve-dialog-reference-options-group-placeholder": "Általános forráshivatkozások",
"cite-ve-dialog-reference-options-name-label": "Újrafelhasználás ezen a néven",
+ "cite-ve-dialog-reference-options-responsive-label": "Alkalmazkodó többoszlopos megjelenés használata",
"cite-ve-dialog-reference-options-section": "Beállítások",
+ "cite-ve-dialog-reference-placeholder": "Írd vagy másold ide a forráshivatkozásodat, vagy illessz be egy forrássablont.",
"cite-ve-dialog-reference-title": "Forráshivatkozás",
"cite-ve-dialog-reference-useexisting-full-label": "Olyan forráshivatkozás felhasználása, ami már szerepel ezen a lapon",
"cite-ve-dialog-reference-useexisting-label": "Egy létező forráshivatkozás használata",
@@ -28,15 +36,18 @@
"cite-ve-dialog-referenceslist-contextitem-description-general": "Általános forráshivatkozások listája",
"cite-ve-dialog-referenceslist-contextitem-description-named": "„$1” csoportba tartozó forráshivatkozások listája",
"cite-ve-dialog-referenceslist-title": "Forráshivatkozások listája",
- "cite-ve-dialogbutton-citation-educationpopup-title": "Forráshivatkozások",
"cite-ve-dialogbutton-citation-educationpopup-text": "Javítja a tartalmat az információk forrásokkal való ellátásával. Hivatkozhatsz könyvekre, újságokra és weblapokra.",
+ "cite-ve-dialogbutton-citation-educationpopup-title": "Forráshivatkozások",
"cite-ve-dialogbutton-reference-full-label": "Alapvető forma",
- "cite-ve-dialogbutton-reference-tooltip": "Egyszerű",
"cite-ve-dialogbutton-reference-title": "Forráshivatkozás",
+ "cite-ve-dialogbutton-reference-tooltip": "Egyszerű",
"cite-ve-dialogbutton-referenceslist-tooltip": "Forráshivatkozások listája",
"cite-ve-reference-input-placeholder": "Keresés jelenlegi forráshivatkozásokban",
"cite-ve-referenceslist-isempty": "Nincsenek megjeleníthető forráshivatkozások a(z) „$1” csoportban ezen az oldalon.",
"cite-ve-referenceslist-isempty-default": "Nincs a lapon forráshivatkozás a lapon, amit szerepelhetne ebben a listában.",
"cite-ve-referenceslist-missingref": "Ez a forráshivatkozás egy sablonban vagy más generált blokkban van definiálva, és jelenleg csak forrásnézetben szerkeszthető.",
- "cite-ve-toolbar-group-label": "Forráshivatkozás"
-} \ No newline at end of file
+ "cite-ve-referenceslist-missingreflist": "Ez a forráshivatkozás-lista egy sablonnal készült, és jelenleg csak forrásnézetben szerkeszthető.",
+ "cite-ve-toolbar-group-label": "Forráshivatkozás",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Forráshivatkozások",
+ "visualeditor-internal-list-diff-group-name-mwreference": "„$1” forráshivatkozás-csoport"
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hy.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hy.json
index dae41cbb..1f357030 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/hy.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/hy.json
@@ -5,7 +5,8 @@
"Xelgen",
"GeoO",
"Դավիթ Սարոյան",
- "Vahe Gharakhanyan"
+ "Vahe Gharakhanyan",
+ "Aram1985"
]
},
"visualeditor-cite-tool-name-book": "Գիրք",
@@ -15,7 +16,7 @@
"cite-ve-dialog-reference-editing-reused": "Այս ծանոթագրությունն այս էջում օգտագործվել է $1 {{PLURAL:$1|անգամ}}:",
"cite-ve-dialog-reference-options-group-label": "Օգտագործել այս խումբը",
"cite-ve-dialog-reference-options-group-placeholder": "Ընդհանուր ծանոթագրություններ",
- "cite-ve-dialog-reference-options-name-label": "Այլ տեղ օգտագործել հետևյալ անվամբ",
+ "cite-ve-dialog-reference-options-name-label": "Կրկնակի օգտագործել տվյալ անվամբ",
"cite-ve-dialog-reference-options-section": "Ընտրանքներ",
"cite-ve-dialog-reference-title": "Ծանոթագրություն",
"cite-ve-dialog-reference-useexisting-full-label": "Կրկին օգտագործել արդեն գոյություն ունեցող ծանոթագրությունը",
@@ -35,4 +36,4 @@
"cite-ve-referenceslist-isempty-default": "Էջում չկա ոչ մի ծանոթագրություն, որպեսզի ընդգրկվի այս ցանկում:",
"cite-ve-referenceslist-missingref": "Այս ծանոթագրությունը օգտագործվում է կաղապարում. այն կարող եք խմբագրել միայն բուն վիքիտեքստում:",
"cite-ve-toolbar-group-label": "Ծանոթագրություն"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ia.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ia.json
index 258f7b75..033a4ea6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ia.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ia.json
@@ -35,7 +35,7 @@
"cite-ve-dialogbutton-reference-title": "Referentia",
"cite-ve-dialogbutton-reference-tooltip": "Basic",
"cite-ve-dialogbutton-referenceslist-tooltip": "Lista de referentias",
- "cite-ve-reference-input-placeholder": "A que vole tu facer referentia?",
+ "cite-ve-reference-input-placeholder": "Cercar in le referentias actual",
"cite-ve-referenceslist-isempty": "Il non ha referentias con le gruppo \"$1\" in iste pagina a includer in iste lista.",
"cite-ve-referenceslist-isempty-default": "Il non ha referentias in iste pagina a includer in iste lista.",
"cite-ve-referenceslist-missingref": "Iste referentia es definite in un patrono o altere bloco generate, e pro le momento pote solmente esser modificate in modo de codice fonte.",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/id.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/id.json
index f744d1cf..f4534c62 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/id.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/id.json
@@ -18,18 +18,30 @@
"Amire80",
"Macofe",
"Mirws",
- "Presidenvolksraad"
+ "Presidenvolksraad",
+ "Gombang"
]
},
+ "visualeditor-cite-tool-definition.json": "null",
"visualeditor-cite-tool-name-book": "Buku",
"visualeditor-cite-tool-name-journal": "Jurnal",
"visualeditor-cite-tool-name-news": "Berita",
"visualeditor-cite-tool-name-web": "Situs web",
+ "cite-tool-definition.json": "null",
+ "cite-ve-changedesc-ref-group-both": "Kelompok referensi diubah dari \"$1\" ke \"$2\"",
+ "cite-ve-changedesc-ref-group-from": "Kelompok referensi diubah dari \"$1\" ke kelompok umum",
+ "cite-ve-changedesc-ref-group-to": "Kelompok referensi berubah dari kelompok umum ke \"$1\"",
+ "cite-ve-changedesc-reflist-group-both": "Kelompok daftar referensi diubah dari \"$1\" ke \"$2\"",
+ "cite-ve-changedesc-reflist-group-from": "Kelompok daftar referensi diubah dari \"$1\" ke kelompok umum",
+ "cite-ve-changedesc-reflist-group-to": "Kelompok daftar referensi berubah dari kelompok umum ke \"$1\"",
+ "cite-ve-changedesc-reflist-item-id": "Indeks referensi diubah",
"cite-ve-dialog-reference-editing-reused": "Referensi ini digunakan $1 {{PLURAL:$1|kali}} pada halaman ini.",
"cite-ve-dialog-reference-options-group-label": "Gunakan kelompok ini",
"cite-ve-dialog-reference-options-group-placeholder": "Referensi umum",
"cite-ve-dialog-reference-options-name-label": "Pakai ulang dengan nama ini",
+ "cite-ve-dialog-reference-options-responsive-label": "Gunakan tata letak kolom responsif",
"cite-ve-dialog-reference-options-section": "Opsi",
+ "cite-ve-dialog-reference-placeholder": "Tulis atau salin referensi Anda di sini, atau sisipkan templat kutipan.",
"cite-ve-dialog-reference-title": "Referensi",
"cite-ve-dialog-reference-useexisting-full-label": "Pakai ulang kutipan yang telah ada di halaman ini",
"cite-ve-dialog-reference-useexisting-label": "Gunakan referensi yang ada",
@@ -48,5 +60,7 @@
"cite-ve-referenceslist-isempty-default": "Tidak ada referensi pada halaman ini yang dapat disertakan dalam daftar ini.",
"cite-ve-referenceslist-missingref": "Referensi ini didefinisikan dalam templat atau blok lain, dan sekarang hanya dapat disunting dalam mode \"sunting sumber\".",
"cite-ve-toolbar-group-label": "Kutip",
- "cite-ve-othergroup-item": "$1 referensi"
+ "cite-ve-othergroup-item": "$1 referensi",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Referensi",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Nama kelompok referensi: \"$1\""
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ie.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ie.json
index 191911b6..9fdf2d21 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ie.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ie.json
@@ -16,4 +16,4 @@
"cite-ve-referenceslist-isempty": "Sur ti-ci págine ne existe referenties del gruppe «$1» por inclusion in ti-ci liste.",
"cite-ve-referenceslist-isempty-default": "Sur ti-ci págine ne existe referenties por inclusion in ti-ci liste.",
"cite-ve-referenceslist-missingref": "Ti-ci referentie es definit in un shablone o un altri generat bloc. Actualmen tu posse redacter it solmen in li font-modo."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ilo.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ilo.json
index 67851369..d68e31e8 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ilo.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ilo.json
@@ -21,12 +21,12 @@
"cite-ve-dialog-referenceslist-contextitem-description-named": "Listaan dagiti reperensia para iti grupo \"$1\"",
"cite-ve-dialog-referenceslist-title": "Listaan ti reperensia",
"cite-ve-dialogbutton-reference-full-label": "Batayan a porma",
- "cite-ve-dialogbutton-reference-tooltip": "Batayan",
"cite-ve-dialogbutton-reference-title": "Reperensia",
+ "cite-ve-dialogbutton-reference-tooltip": "Batayan",
"cite-ve-dialogbutton-referenceslist-tooltip": "Listaan ti reperensia",
"cite-ve-reference-input-placeholder": "Agbiruk iti kaunegan dagiti agdama a dakamat",
"cite-ve-referenceslist-isempty": "Awan dagiti reperensia iti grupo ti \"$1\" iti daytoy a panid a mairaman iti daytoy a listaan.",
"cite-ve-referenceslist-isempty-default": "Awan dagiti reperensia iti daytoy a panid a mairaman iti daytoy a listaan.",
"cite-ve-referenceslist-missingref": "Daytoy a reperensia ket nainaganan iti maysa a plantilia wenno sabali a naaramid a muton, ken iti agadama mabalin laeng a maurnos iti taudan a moda.",
"cite-ve-toolbar-group-label": "Dakamaten"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/is.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/is.json
index a2e6884b..9714c908 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/is.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/is.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Maxí",
- "Snævar"
+ "Snævar",
+ "Sveinn í Felli"
]
},
"visualeditor-cite-tool-name-book": "Bókaheimild",
@@ -31,5 +32,7 @@
"cite-ve-referenceslist-isempty": "Það eru engar tilvísanir í hópnum „$1“ á þessari síðu til að taka með í þennan lista.",
"cite-ve-referenceslist-isempty-default": "Það eru engar tilvísanir á þessari síðu til að taka með í þennan lista.",
"cite-ve-referenceslist-missingref": "Þessi tilvísun er tilgreind í sniði eða öðru tilbúnu efni, og í augnablikinu er aðeins hægt að breyta henni með frumkóðaritlinum.",
- "cite-ve-toolbar-group-label": "Tilvísun"
-} \ No newline at end of file
+ "cite-ve-toolbar-group-label": "Tilvísun",
+ "cite-ve-othergroup-item": "$1 tilvísun",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Tilvísanir"
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/it.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/it.json
index 8c2e34be..69b5526c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/it.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/it.json
@@ -39,6 +39,7 @@
"cite-ve-dialog-reference-options-group-label": "Usa questo gruppo",
"cite-ve-dialog-reference-options-group-placeholder": "Riferimenti generali",
"cite-ve-dialog-reference-options-name-label": "Riutilizza questo nome",
+ "cite-ve-dialog-reference-options-responsive-label": "Utilizza il layout della colonna adattivo",
"cite-ve-dialog-reference-options-section": "Opzioni",
"cite-ve-dialog-reference-placeholder": "Scrivi o copia la tua nota qui, oppure inserisci un template per le citazioni.",
"cite-ve-dialog-reference-title": "Riferimento",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ja.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ja.json
index 7763cede..a287c5ae 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ja.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ja.json
@@ -17,7 +17,8 @@
"Otokoume",
"Vigorous action",
"おはぐろ蜻蛉",
- "Iwai.masaharu"
+ "Iwai.masaharu",
+ "Delim"
]
},
"visualeditor-cite-tool-definition.json": "null",
@@ -26,13 +27,22 @@
"visualeditor-cite-tool-name-news": "ニュース",
"visualeditor-cite-tool-name-web": "ウェブサイト",
"cite-tool-definition.json": "null",
- "cite-ve-dialog-reference-editing-reused": "この参照はこのページ上で$1{{PLURAL:$1|回}}使用されています。",
+ "cite-ve-changedesc-ref-group-both": "脚注のグループが「$1」から「$2」に変更されました",
+ "cite-ve-changedesc-ref-group-from": "脚注のグループが「$1」から一般のグループに変更されました",
+ "cite-ve-changedesc-ref-group-to": "脚注のグループが一般のグループから「$1」に変更されました",
+ "cite-ve-changedesc-reflist-group-both": "脚注リストのグループが「$1」から「$2」に変更されました",
+ "cite-ve-changedesc-reflist-group-from": "脚注リストのグループが「$1」から一般のグループに変更されました",
+ "cite-ve-changedesc-reflist-group-to": "脚注リストのグループが一般のグループから「$1」に変更されました",
+ "cite-ve-changedesc-reflist-item-id": "注釈のインデックスが変更されました",
+ "cite-ve-dialog-reference-editing-reused": "この脚注はこのページ上で$1{{PLURAL:$1|回}}使用されています。",
"cite-ve-dialog-reference-options-group-label": "使用するグループ",
"cite-ve-dialog-reference-options-group-placeholder": "汎用の脚注",
"cite-ve-dialog-reference-options-name-label": "この名前で再使用",
+ "cite-ve-dialog-reference-options-responsive-label": "レスポンシブなコラムレイアウトを使用する",
"cite-ve-dialog-reference-options-section": "オプション",
+ "cite-ve-dialog-reference-placeholder": "ここに脚注を入力し、若しくは貼り付け、又は引用テンプレートを追加してください。",
"cite-ve-dialog-reference-title": "脚注",
- "cite-ve-dialog-reference-useexisting-full-label": "このページ内にある情報源を再利用する",
+ "cite-ve-dialog-reference-useexisting-full-label": "既にこのページにある引用を再利用する",
"cite-ve-dialog-reference-useexisting-label": "既存の情報源を使用",
"cite-ve-dialog-reference-useexisting-tool": "再利用",
"cite-ve-dialog-referenceslist-contextitem-description-general": "汎用の脚注リスト",
@@ -46,7 +56,10 @@
"cite-ve-dialogbutton-referenceslist-tooltip": "情報源一覧",
"cite-ve-reference-input-placeholder": "現在の引用内を検索",
"cite-ve-referenceslist-isempty": "このページには、この一覧に含めるためのグループ「$1」の情報源はありません。",
- "cite-ve-referenceslist-isempty-default": "このページには、この一覧に含められる情報源はありません。",
- "cite-ve-referenceslist-missingref": "この出典はテンプレート内または別途生成されたブロック内で定義されているため、現時点ではソース モードのみで編集できます。",
- "cite-ve-toolbar-group-label": "参照"
+ "cite-ve-referenceslist-isempty-default": "このページには、この一覧に含められる脚注がありません。",
+ "cite-ve-referenceslist-missingref": "この脚注はテンプレート内または別途生成されたブロック内で定義されているため、現時点ではソースモードでのみ編集できます。",
+ "cite-ve-toolbar-group-label": "引用",
+ "cite-ve-othergroup-item": "$1 脚注",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "脚注",
+ "visualeditor-internal-list-diff-group-name-mwreference": "脚注のグループ名: 「$1」"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/jbo.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/jbo.json
index 693431b4..6c8d8a65 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/jbo.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/jbo.json
@@ -6,4 +6,4 @@
]
},
"visualeditor-cite-tool-name-news": "nuzba"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/jv.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/jv.json
index 658b45cf..fa3c61a9 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/jv.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/jv.json
@@ -13,14 +13,14 @@
"visualeditor-cite-tool-name-book": "Buku",
"visualeditor-cite-tool-name-journal": "Jurnal",
"visualeditor-cite-tool-name-news": "Warta",
- "visualeditor-cite-tool-name-web": "Sana jaringan",
+ "visualeditor-cite-tool-name-web": "Situs jaringan",
"cite-tool-definition.json": "null",
"cite-ve-dialog-reference-editing-reused": "Rujukan iki dianggo {{PLURAL:$1|ping}} $1 ing kaca iki.",
"cite-ve-dialog-reference-options-group-label": "Anggo golongan iki",
"cite-ve-dialog-reference-options-group-placeholder": "Rujukan umum",
"cite-ve-dialog-reference-options-name-label": "Anggo manèh mawa jeneng iki",
"cite-ve-dialog-reference-options-section": "Pilihan",
- "cite-ve-dialog-reference-placeholder": "Tulisen utawa tèmplèken rujukané panjenengan ing kéné, utawa wuwuhen cithakan sitiran.",
+ "cite-ve-dialog-reference-placeholder": "Tulisen utawa tèmplèken réferènsiné panjenengan ing kéné, utawa wuwuhen sawijining cithakan sitiran.",
"cite-ve-dialog-reference-title": "Rujukan",
"cite-ve-dialog-reference-useexisting-full-label": "Anggo manèh sitiran sing wis ana ing kaca iki",
"cite-ve-dialog-reference-useexisting-label": "Anggo rujukan sing ana",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ka.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ka.json
index f3789273..f7ff3c70 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ka.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ka.json
@@ -40,4 +40,4 @@
"cite-ve-referenceslist-isempty-default": "ამ გვერდზე არ არის ბმულები ამ სიაში ჩასართავად.",
"cite-ve-referenceslist-missingref": "ეს სქოლიო განსაზღვრულია თარგში ან სხვა გენერირებად ბლოკში და ამჟამად მისი რედაქტირება მხოლოდ საწყისი ტექსტის რეჟიმში შეიძლება.",
"cite-ve-toolbar-group-label": "ციტირება"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/kk-cyrl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/kk-cyrl.json
index 34bc73cd..efd9b48d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/kk-cyrl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/kk-cyrl.json
@@ -22,12 +22,12 @@
"cite-ve-dialog-referenceslist-contextitem-description-named": "«$1» тобы үшін дереккөзер тізімі",
"cite-ve-dialog-referenceslist-title": "Дереккөздер тізімі",
"cite-ve-dialogbutton-reference-full-label": "Негізгі пішін",
- "cite-ve-dialogbutton-reference-tooltip": "Негізгі",
"cite-ve-dialogbutton-reference-title": "Дереккөз",
+ "cite-ve-dialogbutton-reference-tooltip": "Негізгі",
"cite-ve-dialogbutton-referenceslist-tooltip": "Дереккөздер тізімі",
"cite-ve-reference-input-placeholder": "Қазіргі дереккөз ішінде іздеу",
"cite-ve-referenceslist-isempty": "Мұнда бұл бетте бұл тізімге кірген \"$1\" тобындағы дереккөздер жоқ.",
"cite-ve-referenceslist-isempty-default": "Бұл бетте бұл тізімге кірген дереккөздер жоқ.",
"cite-ve-referenceslist-missingref": "Бұл дереккөз үлгі немесе басқа себептен құлыпталған, және тек қайнары арқылы өңдей аласыз.",
"cite-ve-toolbar-group-label": "Дереккөзін көрсету"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/km.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/km.json
index 29995823..8e4160c9 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/km.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/km.json
@@ -22,11 +22,11 @@
"cite-ve-dialog-referenceslist-contextitem-description-named": "បញ្ជីឯកសារយោងសម្រាប់ក្រុម \"$1\"",
"cite-ve-dialog-referenceslist-title": "បញ្ជី​ឯកសារ​យោង",
"cite-ve-dialogbutton-reference-full-label": "ទម្រង់បែបបទបឋម",
- "cite-ve-dialogbutton-reference-tooltip": "បែបបទបឋម",
"cite-ve-dialogbutton-reference-title": "ឯកសារ​យោង​",
+ "cite-ve-dialogbutton-reference-tooltip": "បែបបទបឋម",
"cite-ve-dialogbutton-referenceslist-tooltip": "បញ្ជី​ឯកសារ​យោង",
"cite-ve-reference-input-placeholder": "ស្វែងរកក្នុងការយោងបច្ចុប្បន្ន",
"cite-ve-referenceslist-isempty": "មិន​មាន​សេចក្ដី​យោង​ក្នុង​ក្រុម \"$1\" លើ​ទំព័រ​នេះ ដើម្បី​បញ្ចូល​ក្នុង​បញ្ជី​នេះ​ទេ។",
"cite-ve-referenceslist-isempty-default": "មិន​មាន​សេចក្ដី​យោង​លើ​ទំព័រ​នេះ ដើម្បី​បញ្ចូល​ក្នុង​បញ្ជី​នេះ​ទេ។",
"cite-ve-toolbar-group-label": "យោង"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/kn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/kn.json
index 45dcd72c..1820be4f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/kn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/kn.json
@@ -27,4 +27,4 @@
"cite-ve-dialogbutton-reference-tooltip": "ಮೂಲಭೂತ",
"cite-ve-dialogbutton-referenceslist-tooltip": "ಉಲ್ಲೇಖಗಳ ಪಟ್ಟಿ",
"cite-ve-toolbar-group-label": "ಉಲ್ಲೇಖಿಸಿ"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ko.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ko.json
index 2989bfd2..01d68a5e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ko.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ko.json
@@ -36,6 +36,8 @@
"cite-ve-changedesc-reflist-group-both": "각주 목록 그룹이 \"$1\"에서 \"$2\"(으)로 변경되었습니다",
"cite-ve-changedesc-reflist-group-from": "각주 목록 그룹이 \"$1\"에서 일반 그룹으로 변경되었습니다",
"cite-ve-changedesc-reflist-group-to": "각주 목록 그룹이 일반 그룹에서 \"$1\"(으)로 변경되었습니다",
+ "cite-ve-changedesc-reflist-responsive-set": "각주 목록은 여러 반응형 열로 표시되도록 변경되었습니다",
+ "cite-ve-changedesc-reflist-responsive-unset": "각주 목록은 하나의 열로만 표시되도록 변경되었습니다",
"cite-ve-changedesc-reflist-item-id": "참조 색인이 변경되었습니다",
"cite-ve-dialog-reference-editing-reused": "이 각주는 이 문서에서 $1{{PLURAL:$1|번}} 사용되었습니다.",
"cite-ve-dialog-reference-options-group-label": "이 그룹 사용",
@@ -59,7 +61,9 @@
"cite-ve-reference-input-placeholder": "현재 인용 안에서 검색",
"cite-ve-referenceslist-isempty": "이 문서에서 이 목록에 포함될 \"$1\" 그룹으로 된 각주가 없습니다.",
"cite-ve-referenceslist-isempty-default": "이 문서에서 이 목록에 포함될 각주가 없습니다.",
- "cite-ve-referenceslist-missingref": "이 각주는 틀이나 다른 생성된 블럭에서 정의했고, 현재는 원본 모드에서만 편집할 수 있습니다",
+ "cite-ve-referenceslist-missingref": "이 각주는 틀이나 다른 생성된 블록에서 정의되었고, 현재는 원본 모드에서만 편집할 수 있습니다.",
+ "cite-ve-referenceslist-missingref-in-list": "이 각주는 틀이나 다른 생성된 블록에서 정의되었고, 현재는 원본 모드에서만 미리 볼 수 있습니다.",
+ "cite-ve-referenceslist-missingreflist": "이 각주 목록은 틀에 의해 생성된 것이며 현재 원본 모드에서만 편집할 수 있습니다.",
"cite-ve-toolbar-group-label": "인용",
"cite-ve-othergroup-item": "$1 참조",
"visualeditor-internal-list-diff-default-group-name-mwreference": "각주",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/krc.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/krc.json
index d328b6f4..17807779 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/krc.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/krc.json
@@ -22,12 +22,12 @@
"cite-ve-dialog-referenceslist-contextitem-description-named": "\"$1\" къауум ючюн белгилени тизмеси",
"cite-ve-dialog-referenceslist-title": "Белгиле",
"cite-ve-dialogbutton-reference-full-label": "Тамал форма",
- "cite-ve-dialogbutton-reference-tooltip": "Тамал",
"cite-ve-dialogbutton-reference-title": "Белгиле",
+ "cite-ve-dialogbutton-reference-tooltip": "Тамал",
"cite-ve-dialogbutton-referenceslist-tooltip": "Белгиле",
"cite-ve-reference-input-placeholder": "Бар болгъан къайнакъланы ичинде изле",
"cite-ve-referenceslist-isempty": "Бу тизмеге къошар ючюн бу бетде «$1» къауум бла къайнакъ джокъду.",
"cite-ve-referenceslist-isempty-default": "Бу бетде бу тизмеге къошар ючюн къайнакъ джокъду.",
"cite-ve-referenceslist-missingref": "Бу къайнакъ шаблонда неда башха генерация этилген блокда салыннганды эмда бусагъатда аннга джангыз вики-текстни тюрлендириу режимде редакторлукъ этерге болады.",
"cite-ve-toolbar-group-label": "Цитата этиу"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ku-latn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ku-latn.json
index b23109c3..33554578 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ku-latn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ku-latn.json
@@ -12,18 +12,21 @@
"visualeditor-cite-tool-name-web": "Malper",
"cite-ve-dialog-reference-editing-reused": "Ev çavkanî di vê rûpelê de $1 {{PLURAL:$1|caran}} tê bikaranîn.",
"cite-ve-dialog-reference-options-group-label": "Vê komê bi kar bîne",
- "cite-ve-dialog-reference-options-group-placeholder": "Referansên giştî",
+ "cite-ve-dialog-reference-options-group-placeholder": "Çavkaniyên giştî",
"cite-ve-dialog-reference-options-name-label": "Di bin vî navî de dîsa bi kar bîne",
"cite-ve-dialog-reference-options-section": "Vebijark",
"cite-ve-dialog-reference-title": "Çavkanî",
- "cite-ve-dialog-reference-useexisting-label": "Referanseka heye bi kar bîne",
+ "cite-ve-dialog-reference-useexisting-label": "Çavkaniyeka heye bi kar bîne",
"cite-ve-dialog-reference-useexisting-tool": "Dîsa bi kar bîne",
- "cite-ve-dialog-referenceslist-contextitem-description-general": "Lîsteya referansên giştî",
- "cite-ve-dialog-referenceslist-contextitem-description-named": "Lîsteya referansên bo koma \"$1\"",
- "cite-ve-dialog-referenceslist-title": "Lîsteya referansan",
+ "cite-ve-dialog-referenceslist-contextitem-description-general": "Lîsteya çavkaniyên giştî",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "Lîsteya çavkaniyan bo koma \"$1\"",
+ "cite-ve-dialog-referenceslist-title": "Lîsteya çavkaniyan",
+ "cite-ve-dialogbutton-reference-full-label": "Forma bingehîn",
"cite-ve-dialogbutton-reference-title": "Çavkanî",
"cite-ve-dialogbutton-reference-tooltip": "Bingehîn",
- "cite-ve-dialogbutton-referenceslist-tooltip": "Lîsteya referansan",
+ "cite-ve-dialogbutton-referenceslist-tooltip": "Lîsteya çavkaniyan",
"cite-ve-reference-input-placeholder": "Di navbera gotinên rojane de bigere",
- "cite-ve-toolbar-group-label": "Jêgirtin"
+ "cite-ve-toolbar-group-label": "Çavkanî",
+ "cite-ve-othergroup-item": "$1 çavkanî",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Çavkanî"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/kw.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/kw.json
index 9c369b00..0ddcdc06 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/kw.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/kw.json
@@ -13,4 +13,4 @@
"cite-ve-dialog-referenceslist-title": "Rol a dhevynnow",
"cite-ve-dialogbutton-reference-tooltip": "Devyn",
"cite-ve-dialogbutton-referenceslist-tooltip": "Rol a dhevynnow"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ky.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ky.json
index cf0aad7f..db4db594 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ky.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ky.json
@@ -15,4 +15,4 @@
"visualeditor-cite-tool-name-news": "Жаңылыктар",
"visualeditor-cite-tool-name-web": "Веб-сайт",
"cite-ve-dialog-reference-options-section": "Ырастоолор"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lb.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lb.json
index e646fe1a..b6f0760f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lb.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lb.json
@@ -17,10 +17,12 @@
"visualeditor-cite-tool-name-news": "Neiegkeeten",
"visualeditor-cite-tool-name-web": "Internetsite",
"cite-tool-definition.json": "null",
+ "cite-ve-changedesc-reflist-responsive-unset": "D'Lëscht vun de Referenzen gouf esou geännert datt se an enger Spalt gewise gëtt",
"cite-ve-dialog-reference-editing-reused": "Dës Referenz gëtt {{PLURAL:$1|eemol|$1 Mol}} op dëser Säit benotzt.",
"cite-ve-dialog-reference-options-group-label": "Dëse Grupp benotzen",
"cite-ve-dialog-reference-options-group-placeholder": "Allgemeng Referenzen",
"cite-ve-dialog-reference-options-name-label": "Nees benotze mat dësem Numm",
+ "cite-ve-dialog-reference-options-responsive-label": "Dynamesche Kolonne-Layout benotzen",
"cite-ve-dialog-reference-options-section": "Optiounen",
"cite-ve-dialog-reference-placeholder": "Schreift oder kopéiert Är Referenz heihin oder setzt eng Schabloun fir Zitater dran.",
"cite-ve-dialog-reference-title": "Referenz",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/li.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/li.json
index 8999703f..7713368c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/li.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/li.json
@@ -1,8 +1,9 @@
{
"@metadata": {
"authors": [
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
"visualeditor-cite-tool-name-news": "Nuujs"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lki.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lki.json
index 77c5723c..ffcf6ddb 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lki.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lki.json
@@ -11,11 +11,11 @@
"visualeditor-cite-tool-name-news": "حاوواڵ",
"visualeditor-cite-tool-name-web": "وبسایت",
"cite-ve-dialog-reference-editing-reused": "این یادکرد $1 {{PLURAL:$1|times}} در این صفحه استفاده شده است.",
- "cite-ve-dialog-reference-options-group-label": "استفاده از این گروه",
+ "cite-ve-dialog-reference-options-group-label": "ئستفادە ئەژ ئێ داکووکە(گروو)",
"cite-ve-dialog-reference-options-group-placeholder": "منابع عمومی",
"cite-ve-dialog-reference-options-name-label": "استفاده دوباره با این نام",
"cite-ve-dialog-reference-options-section": "گزینۀل",
- "cite-ve-dialog-reference-title": "بن چۀک/مۀنبۀع",
+ "cite-ve-dialog-reference-title": "بنچەک(منبع)",
"cite-ve-dialog-reference-useexisting-full-label": "استفاده دوباره یک پانویس موجود در این صفحه",
"cite-ve-dialog-reference-useexisting-label": "استفاده از یک منبع موجود",
"cite-ve-dialog-reference-useexisting-tool": "استفادهٔ مجدد",
@@ -24,8 +24,8 @@
"cite-ve-dialog-referenceslist-title": "فهرست منابع",
"cite-ve-dialogbutton-citation-educationpopup-title": "یادکرد/ویرکرد",
"cite-ve-dialogbutton-reference-full-label": "فرم ابتدائی",
+ "cite-ve-dialogbutton-reference-title": "بنچەک(منبع)",
"cite-ve-dialogbutton-reference-tooltip": "مقدماتی",
- "cite-ve-dialogbutton-reference-title": "بن چۀک/مۀنبۀع",
"cite-ve-dialogbutton-referenceslist-tooltip": "فهرست منابع",
"cite-ve-toolbar-group-label": "یادکرد/ویرکرد"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lmo.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lmo.json
index 2705f389..33486e88 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lmo.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lmo.json
@@ -18,4 +18,4 @@
"cite-ve-referenceslist-isempty": "En chèsta pàgina gh'è nisü riferimènt col grùpo \"$1\" de mèter en chèsta lìsta.",
"cite-ve-referenceslist-isempty-default": "Gh'è nisü riferimèncc en chèsta pàgina de mèter dét en chèsta lìsta.",
"cite-ve-referenceslist-missingref": "Chèsto riferimènt l'è definìt endèn mudèl o 'ndèn óter blòch generàt e per adès el pöl mìa éser mudificàt apéna 'n modalità sorgènt."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lt.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lt.json
index 4152d1a5..cccd8da1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lt.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lt.json
@@ -11,7 +11,8 @@
"Hugo.arg",
"Pofka",
"Albertas",
- "Zygimantus"
+ "Zygimantus",
+ "Manvydasz"
]
},
"visualeditor-cite-tool-definition.json": "nieko",
@@ -20,6 +21,7 @@
"visualeditor-cite-tool-name-news": "Naujienos",
"visualeditor-cite-tool-name-web": "Tinklapis",
"cite-tool-definition.json": "nieko",
+ "cite-ve-changedesc-reflist-item-id": "Pakeistas išnašos indeksas",
"cite-ve-dialog-reference-editing-reused": "Ši nuoroda naudojama $1 {{PLURAL:$1|kartų}} šiame puslapyje.",
"cite-ve-dialog-reference-options-group-label": "Naudoti šią grupę",
"cite-ve-dialog-reference-options-group-placeholder": "Bendrosios nuorodos",
@@ -43,5 +45,6 @@
"cite-ve-referenceslist-isempty-default": "Šiame puslapyje nėra nuorodų, kurias būtų galima įtraukti į šį sąrašą.",
"cite-ve-referenceslist-missingref": "Ši nuoroda yra apibrėžta šablone arba kitame sugeneruotame bloke ir kol kas gali būti redaguojama tik išeities teksto režimu.",
"cite-ve-toolbar-group-label": "Cituoti",
- "cite-ve-othergroup-item": "$1 nuoroda"
+ "cite-ve-othergroup-item": "$1 nuoroda",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Išnašos"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/luz.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/luz.json
index 7dd7b034..b4f6cf8b 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/luz.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/luz.json
@@ -8,4 +8,4 @@
"visualeditor-cite-tool-name-journal": "روژنومه",
"visualeditor-cite-tool-name-news": "خه ورل",
"visualeditor-cite-tool-name-web": "وب سایت"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lv.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lv.json
index 344802b8..310e606d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lv.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lv.json
@@ -11,10 +11,18 @@
"Silraks"
]
},
+ "visualeditor-cite-tool-definition.json": "null",
"visualeditor-cite-tool-name-book": "Grāmata",
- "visualeditor-cite-tool-name-journal": "Žurnāls",
+ "visualeditor-cite-tool-name-journal": "Publikācija",
"visualeditor-cite-tool-name-news": "Ziņas",
"visualeditor-cite-tool-name-web": "Tīmekļa vietne",
+ "cite-tool-definition.json": "null",
+ "cite-ve-changedesc-ref-group-both": "Atsauču grupa nomainīta no \"$1\" uz \"$2\"",
+ "cite-ve-changedesc-ref-group-from": "Atsauču grupa nomainīta no \"$1\" uz vispārīgo grupu",
+ "cite-ve-changedesc-ref-group-to": "Atsauču grupa nomainīta no vispārīgās grupas uz \"$1\"",
+ "cite-ve-changedesc-reflist-group-both": "Atsauču saraksta grupa nomainīta no \"$1\" uz \"$2\"",
+ "cite-ve-changedesc-reflist-group-from": "Atsauču saraksta grupa nomainīta no \"$1\" uz vispārīgo grupu",
+ "cite-ve-changedesc-reflist-group-to": "Atsauču saraksta grupa nomainīta no vispārīgās grupas uz \"$1\"",
"cite-ve-dialog-reference-editing-reused": "Šī atsauce šajā lapā ir izmantota $1 {{PLURAL:$1|reizes|reizi|reizes}}.",
"cite-ve-dialog-reference-options-group-label": "Lietot šo grupu",
"cite-ve-dialog-reference-options-group-placeholder": "Vispārīgas atsauces",
@@ -25,8 +33,11 @@
"cite-ve-dialog-reference-useexisting-label": "Izmantot esošu atsauci",
"cite-ve-dialog-reference-useexisting-tool": "Atkārtota izmantošana",
"cite-ve-dialog-referenceslist-contextitem-description-general": "Vispārīgo atsauču saraksts",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "Atsauču saraksts grupai \"$1\"",
"cite-ve-dialog-referenceslist-title": "Atsauču saraksts",
"cite-ve-dialogbutton-citation-educationpopup-text": "Uzlabo savu saturu, pievienojot informācijas avotus. Atsaukties var uz grāmatām, laikrakstiem un interneta vietnēm.",
+ "cite-ve-dialogbutton-citation-educationpopup-title": "Atsauces",
+ "cite-ve-dialogbutton-reference-full-label": "Vienkāršā forma",
"cite-ve-dialogbutton-reference-title": "Atsauce",
"cite-ve-dialogbutton-reference-tooltip": "Vienkārša",
"cite-ve-dialogbutton-referenceslist-tooltip": "Atsauču saraksts",
@@ -36,5 +47,6 @@
"cite-ve-referenceslist-missingref": "Šī atsauce ir definēta veidnē vai citā automātiski ģenerētā blokā, un pagaidām var tikt labota tikai pirmkoda režīmā.",
"cite-ve-toolbar-group-label": "Atsauce",
"cite-ve-othergroup-item": "$1 atsauce",
- "visualeditor-internal-list-diff-default-group-name-mwreference": "Atsauces"
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Atsauces",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Atsauču grupas nosaukums: \"$1\""
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lzh.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lzh.json
index d9abb01b..1b3a3176 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/lzh.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/lzh.json
@@ -9,4 +9,4 @@
},
"visualeditor-cite-tool-name-book": "書",
"visualeditor-cite-tool-name-news": "事"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/min.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/min.json
index 7053cd9e..68b6d96e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/min.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/min.json
@@ -11,4 +11,4 @@
"visualeditor-cite-tool-name-web": "Situih web",
"cite-ve-dialog-reference-title": "Rujuakan",
"cite-ve-dialogbutton-reference-tooltip": "Rujuakan"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mk.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mk.json
index d8b9e046..3810c3cb 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mk.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mk.json
@@ -18,11 +18,14 @@
"cite-ve-changedesc-reflist-group-both": "Групата на списоци со наводи е сменета од „$1“ во „$2“",
"cite-ve-changedesc-reflist-group-from": "Групата на списоци со наводи е сменета од „$1“ во општата група",
"cite-ve-changedesc-reflist-group-to": "Групата на списоци со наводи е сменета од општата група во „$1“",
+ "cite-ve-changedesc-reflist-responsive-set": "Списокот на наводи е изменет за приказ во одѕивни столбови",
+ "cite-ve-changedesc-reflist-responsive-unset": "Списокот на наводи е изменет за приказ во само еден столб",
"cite-ve-changedesc-reflist-item-id": "Индексот на наводи е изменет",
"cite-ve-dialog-reference-editing-reused": "Овој навод се користи {{PLURAL:$1|еднаш|$1 пати}} во страницава.",
"cite-ve-dialog-reference-options-group-label": "Употреби ја групава",
"cite-ve-dialog-reference-options-group-placeholder": "Општи наводи",
"cite-ve-dialog-reference-options-name-label": "Преупотреби под ова име",
+ "cite-ve-dialog-reference-options-responsive-label": "Користи одѕивен распоред на столбовите",
"cite-ve-dialog-reference-options-section": "Нагодувања",
"cite-ve-dialog-reference-placeholder": "Тука напишете или прекопирајте го наводот, или пак вметнете шаблон за навод.",
"cite-ve-dialog-reference-title": "Навод",
@@ -42,6 +45,8 @@
"cite-ve-referenceslist-isempty": "На страницава нема наводи со групата „$1“ што би ги ставил во списоков.",
"cite-ve-referenceslist-isempty-default": "На страницава нема наводи што би ги ставил во списоков.",
"cite-ve-referenceslist-missingref": "Овој навод се задава во шаблон или друг самосоздаден блок. Засега може да се уредува само непосредно во изворот.",
+ "cite-ve-referenceslist-missingref-in-list": "Овој навод се задава во шаблон или друг создаден блок. Засега може да се прегледува само во изворен режим.",
+ "cite-ve-referenceslist-missingreflist": "Овој список со наводи е создаден од шаблон, и засега може да се уредува само во изворен режим.",
"cite-ve-toolbar-group-label": "Наведи",
"cite-ve-othergroup-item": "$1 навод",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Наводи",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ml.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ml.json
index 9fa414ad..5425716d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ml.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ml.json
@@ -24,15 +24,15 @@
"cite-ve-dialog-referenceslist-contextitem-description-general": "പൊതു അവലംബങ്ങളുടെ പട്ടിക",
"cite-ve-dialog-referenceslist-contextitem-description-named": "\"$1\" എന്ന ഗണത്തിനുള്ള അവലംബങ്ങളുടെ പട്ടിക",
"cite-ve-dialog-referenceslist-title": "അവലംബങ്ങളുടെ പട്ടിക",
- "cite-ve-dialogbutton-citation-educationpopup-title": "അവലംബങ്ങൾ",
"cite-ve-dialogbutton-citation-educationpopup-text": "താങ്കൾ നൽകിയ ഉള്ളടക്കത്തിന്റെ സ്രോതസ്സ് വിവരങ്ങൾ ചേർത്ത് മെച്ചപ്പെടുത്തുന്നു. താങ്കൾക്ക് പുസ്തകങ്ങളും പത്രമാദ്ധ്യമങ്ങളും വെബ്‌സൈറ്റുകളും അവലംബിക്കാവുന്നതാണ്.",
+ "cite-ve-dialogbutton-citation-educationpopup-title": "അവലംബങ്ങൾ",
"cite-ve-dialogbutton-reference-full-label": "അടിസ്ഥാന രൂപം",
- "cite-ve-dialogbutton-reference-tooltip": "അടിസ്ഥാനപരം",
"cite-ve-dialogbutton-reference-title": "അവലംബം",
+ "cite-ve-dialogbutton-reference-tooltip": "അടിസ്ഥാനപരം",
"cite-ve-dialogbutton-referenceslist-tooltip": "അവലംബങ്ങളുടെ പട്ടിക",
"cite-ve-reference-input-placeholder": "ഇപ്പോൾ ഉപയോഗിച്ചിരിക്കുന്ന അവലംബങ്ങളിൽ തിരയുക",
"cite-ve-referenceslist-isempty": "ഈ താളിൽ, \"$1\" ഗണത്തിൽ, ഈ പട്ടികയിൽ ഉൾപ്പെടുത്താവുന്ന അവലംബങ്ങളൊന്നും ഈ താളിലില്ല.",
"cite-ve-referenceslist-isempty-default": "ഈ പട്ടികയിൽ ഉൾപ്പെടുത്താവുന്ന അവലംബങ്ങളൊന്നും ഈ താളിലില്ല.",
"cite-ve-referenceslist-missingref": "ഈ അവലംബം ഫലകം ഉപയോഗിച്ചോ മറ്റേതെങ്കിലും ഘടകമുപയോഗിച്ചോ ആണ് ചേർത്തിരിക്കുന്നത്, അതിനാലിത് ഇപ്പോൾ മൂലരൂപത്തിൽ മാത്രമേ തിരുത്താനാവൂ.",
"cite-ve-toolbar-group-label": "ഉദ്ധരിക്കുക"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mn.json
index f85a534e..e9b34419 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mn.json
@@ -8,4 +8,4 @@
},
"cite-ve-dialog-referenceslist-title": "Ном зүйн жагсаалт",
"cite-ve-dialogbutton-referenceslist-tooltip": "Ном зүйн жагсаалт"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mr.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mr.json
index 81db7dc2..47ab1cac 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mr.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mr.json
@@ -8,7 +8,9 @@
"Ydyashad",
"संतोष दहिवळ",
"अभय नातू",
- "NehalDaveND"
+ "NehalDaveND",
+ "Sureshkhole",
+ "Susheelkasab"
]
},
"visualeditor-cite-tool-definition.json": "काहीही नाही",
@@ -17,11 +19,22 @@
"visualeditor-cite-tool-name-news": "बातम्या",
"visualeditor-cite-tool-name-web": "संकेतस्थळ",
"cite-tool-definition.json": "काहीही नाही",
+ "cite-ve-changedesc-ref-group-both": "संदर्भगट \"$1\" वरून \"$2\" कडे बदलला गेला आहे",
+ "cite-ve-changedesc-ref-group-from": "संदर्भ गट \"$1\" कडून आता सामान्य गटाकडे नेण्यात आलेला आहे",
+ "cite-ve-changedesc-ref-group-to": "संदर्भ गट सामान्य गटाकडून आता \"$1\" कडे नेण्यात आलेला आहे",
+ "cite-ve-changedesc-reflist-group-both": "संदर्भयादी \"$1\" कडून \"$2\" कडे नेण्यात आलेली आहे",
+ "cite-ve-changedesc-reflist-group-from": "संदर्भ यादी \"$1\" कडून सामान्य गटाकडे नेण्यात आलेली आहे",
+ "cite-ve-changedesc-reflist-group-to": "संदर्भयादी सामान्य गटाकडून \"$1\" कडे नेलेली आहे",
+ "cite-ve-changedesc-reflist-responsive-set": "संदर्भ यादी प्रतीसादिक स्तंभात दाखवता यावी अशा पद्धतीने बदलण्यात आली आहे.",
+ "cite-ve-changedesc-reflist-responsive-unset": "संदर्भ यादी फक्त एकच स्तंभात दाखवता यावी अशा पद्धतीने बदलण्यात आली आहे.",
+ "cite-ve-changedesc-reflist-item-id": "संदर्भयादी बदलली गेली आहे",
"cite-ve-dialog-reference-editing-reused": "हा संदर्भ या पानावर $1 {{PLURAL:$1|वेळा}} वापरल्या गेला.",
"cite-ve-dialog-reference-options-group-label": "हा संदर्भगट वापरा",
"cite-ve-dialog-reference-options-group-placeholder": "सामान्य संदर्भ",
"cite-ve-dialog-reference-options-name-label": "या नावाने पुन्हा-वापरा",
+ "cite-ve-dialog-reference-options-responsive-label": "प्रतिसाद देणारी सारणी वापरा",
"cite-ve-dialog-reference-options-section": "पर्याय",
+ "cite-ve-dialog-reference-placeholder": "येथे आपला संदर्भ लिहा किंवा चिटकवा, किंवा संदर्भ साचा चिटकवा",
"cite-ve-dialog-reference-title": "संदर्भ",
"cite-ve-dialog-reference-useexisting-full-label": "या पानावर असलेली अवतरणे पुन्हा वापरा",
"cite-ve-dialog-reference-useexisting-label": "सध्या उपलब्ध संदर्भातून संदर्भ वापरा",
@@ -33,12 +46,15 @@
"cite-ve-dialogbutton-citation-educationpopup-title": "संदर्भ",
"cite-ve-dialogbutton-reference-full-label": "मूळ रुप",
"cite-ve-dialogbutton-reference-title": "संदर्भ",
- "cite-ve-dialogbutton-reference-tooltip": "प्राथमिक",
+ "cite-ve-dialogbutton-reference-tooltip": "पहिल्यांदा",
"cite-ve-dialogbutton-referenceslist-tooltip": "संदर्भ यादी",
"cite-ve-reference-input-placeholder": "सध्या अवतरणातच शोधा",
"cite-ve-referenceslist-isempty": "गट \"$1\" पाशी या लेखपानावर संदर्भ उपलब्ध नाहीत.",
"cite-ve-referenceslist-isempty-default": "या यादीत अंतर्भूत करावयासाठी या पानावर कोणतेच संदर्भ नाहीत.",
"cite-ve-referenceslist-missingref": "हा संदर्भ सध्या केवळ स्रोत संपादन पद्धतीने संपादीत करता येतो कारण संबंधित संदर्भ साचातून किंवा इतर जनरेटेड ब्लॉक मधून डिफाईन केला गेला आहे.",
- "cite-ve-toolbar-group-label": "उधृत करा",
- "cite-ve-othergroup-item": "$1 संदर्भ"
+ "cite-ve-referenceslist-missingreflist": "ही संदर्भयादी साचा वापरून तयार केली गेली आहे, आणि आता फ़क्त स्त्रोत मोडमध्ये जाऊनच बदलली जाऊ शकते",
+ "cite-ve-toolbar-group-label": "संदर्भ जोडा",
+ "cite-ve-othergroup-item": "$1 संदर्भ",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "संदर्भ",
+ "visualeditor-internal-list-diff-group-name-mwreference": "संदर्भगटाचे नाव: \"$1\""
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ms.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ms.json
index 088c2151..f1a93784 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ms.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ms.json
@@ -8,15 +8,26 @@
"Macofe"
]
},
+ "visualeditor-cite-tool-definition.json": "null",
"visualeditor-cite-tool-name-book": "Buku",
"visualeditor-cite-tool-name-journal": "Jurnal",
"visualeditor-cite-tool-name-news": "Berita",
"visualeditor-cite-tool-name-web": "Laman web",
+ "cite-tool-definition.json": "null",
+ "cite-ve-changedesc-ref-group-both": "Kumpulan rujukan ditukar dari \"$1\" ke \"$2\"",
+ "cite-ve-changedesc-ref-group-from": "Kumpulan rujukan ditukar dari \"$1\" ke kumpulan am",
+ "cite-ve-changedesc-ref-group-to": "Kumpulan rujukan ditukar dari kumpulan am ke \"$1\"",
+ "cite-ve-changedesc-reflist-group-both": "Kumpulan senarai rujukan ditukar dari \"$1\" ke \"$2\"",
+ "cite-ve-changedesc-reflist-group-from": "Kumpulan senarai rujukan ditukar dari \"$1\" ke kumpulan am",
+ "cite-ve-changedesc-reflist-group-to": "Kumpulan senarai rujukan ditukar dari kumpulan am ke \"$1\"",
+ "cite-ve-changedesc-reflist-item-id": "Indeks rujukan diubah",
"cite-ve-dialog-reference-editing-reused": "Rujukan ini digunakan $1 kali di laman ini.",
"cite-ve-dialog-reference-options-group-label": "Gunakan kumpulan ini",
"cite-ve-dialog-reference-options-group-placeholder": "Rujukan umum",
"cite-ve-dialog-reference-options-name-label": "Gunakan semula dengan nama ini",
+ "cite-ve-dialog-reference-options-responsive-label": "Gunakan tatasusun lajur responsif",
"cite-ve-dialog-reference-options-section": "Pilihan",
+ "cite-ve-dialog-reference-placeholder": "Tulis atau tampalkan rujukan di sini, atau sisipkan templat petikan.",
"cite-ve-dialog-reference-title": "Rujukan",
"cite-ve-dialog-reference-useexisting-full-label": "Gunakan semula petikan yang sudah pun wujud di laman ini",
"cite-ve-dialog-reference-useexisting-label": "Gunakan rujukan yang sedia ada",
@@ -24,11 +35,19 @@
"cite-ve-dialog-referenceslist-contextitem-description-general": "Senarai rujukan am",
"cite-ve-dialog-referenceslist-contextitem-description-named": "Senarai rujukan am untuk kumpulan \"$1\"",
"cite-ve-dialog-referenceslist-title": "Senarai rujukan",
+ "cite-ve-dialogbutton-citation-educationpopup-text": "Meningkatkan mutu kandungan dengan menambah sumber maklumat. Boleh dipetik dari buku, akhbar mahupun laman web.",
+ "cite-ve-dialogbutton-citation-educationpopup-title": "Petikan",
+ "cite-ve-dialogbutton-reference-full-label": "Bentuk asas",
+ "cite-ve-dialogbutton-reference-title": "Rujukan",
"cite-ve-dialogbutton-reference-tooltip": "Asas",
"cite-ve-dialogbutton-referenceslist-tooltip": "Senarai rujukan",
"cite-ve-reference-input-placeholder": "Cari petikan sedia ada",
"cite-ve-referenceslist-isempty": "Tidak terdapat rujukan dengan kumpulan \"$1\" pada halaman ini untuk disertakan dalam senarai ini.",
"cite-ve-referenceslist-isempty-default": "Tidak terdapat rujukan pada halaman ini untuk disertakan dalam senarai ini.",
"cite-ve-referenceslist-missingref": "Rujukan ini ditakrifkan dalam templat atau seumpamanya, maka buat masa sekarang, ia boleh disunting dalam mod sumber sahaja.",
- "cite-ve-toolbar-group-label": "Petik"
-} \ No newline at end of file
+ "cite-ve-referenceslist-missingreflist": "Senarai rujukan ini dihasilkan oleh templat, oleh itu kini hanya boleh disunting dalam mod sumber.",
+ "cite-ve-toolbar-group-label": "Petik",
+ "cite-ve-othergroup-item": "Rujukan $1",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Rujukan",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Nama kumpulan rujukan: \"$1\""
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mt.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mt.json
index dde99530..88207f9c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mt.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mt.json
@@ -12,4 +12,4 @@
"visualeditor-cite-tool-name-web": "Sit tal-web",
"cite-ve-dialog-reference-title": "Referenza",
"cite-ve-dialog-referenceslist-title": "Lista ta' referenzi"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mwl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mwl.json
index 9634249f..51e90d0d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/mwl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/mwl.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
"visualeditor-cite-tool-name-book": "Lhibro"
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/my.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/my.json
index 119eb512..4c6f18b1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/my.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/my.json
@@ -6,4 +6,4 @@
]
},
"cite-ve-dialogbutton-reference-title": "ရည်ညွှန်း"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nah.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nah.json
index 37cedfe7..44884231 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nah.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nah.json
@@ -6,4 +6,4 @@
]
},
"cite-ve-toolbar-group-label": "Titlahtolcuepaz"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nap.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nap.json
index 69710006..922a7973 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nap.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nap.json
@@ -35,4 +35,4 @@
"cite-ve-referenceslist-isempty-default": "Nun ce stanno riferimente ncopp'a sta paggena pe' ll'azzeccà dint'a sta lista.",
"cite-ve-referenceslist-missingref": "Chista nota è definita int'a nu modello o dint'a n'atu blocco generato e p' 'o mumento se può cagnà sulamente cagnanno direttamente 'o codece.",
"cite-ve-toolbar-group-label": "Citaziona"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nb.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nb.json
index 49e2dfea..b84dd60c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nb.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nb.json
@@ -35,6 +35,7 @@
"cite-ve-dialog-reference-options-group-label": "Bruk denne gruppen",
"cite-ve-dialog-reference-options-group-placeholder": "Generelle referanser",
"cite-ve-dialog-reference-options-name-label": "Gjenbruk med dette navnet",
+ "cite-ve-dialog-reference-options-responsive-label": "Bruk responsivt kolonneoppsett",
"cite-ve-dialog-reference-options-section": "Valg",
"cite-ve-dialog-reference-placeholder": "Skriv eller lim inn referansen her, eller sett inn en kildemal.",
"cite-ve-dialog-reference-title": "Referanse",
@@ -54,6 +55,7 @@
"cite-ve-referenceslist-isempty": "Det finnes ingen kildehenvisninger i gruppen «$1» på denne siden som kan inkluderes i denne lista.",
"cite-ve-referenceslist-isempty-default": "Det er ingen kildehenvisninger på denne siden som kan inkluderes i denne lista.",
"cite-ve-referenceslist-missingref": "Denne kildehenvisningen er definert ved hjelp av en mal eller en annen generert blokk, og kan foreløpig kun redigeres i kildemodus.",
+ "cite-ve-referenceslist-missingreflist": "Denne referanselista genereres av en mal, og kan for tiden kun redigeres i kildemodus.",
"cite-ve-toolbar-group-label": "Angi kilde",
"cite-ve-othergroup-item": "$1 referanse",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referanser",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds-nl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds-nl.json
index 7c3a2972..f951813e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds-nl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds-nl.json
@@ -17,4 +17,4 @@
"cite-ve-referenceslist-isempty": "Der bin gien referensies mit de groep \"$1\" op disse zied um bie disse lieste te doon.",
"cite-ve-referenceslist-missingref": "Disse referensie steet in n mal of n aander soort egenereerd blok, en ku'j veurlopig allinnig mer in de bronkode bewarken.",
"cite-ve-toolbar-group-label": "Siteren"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds.json
index 36564c62..8f68def1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nds.json
@@ -12,4 +12,4 @@
"cite-ve-dialog-referenceslist-title": "Liest vun Enkelnawiesen",
"cite-ve-dialogbutton-reference-tooltip": "Enkelnawies",
"cite-ve-dialogbutton-referenceslist-tooltip": "Liest vun Enkelnawiesen"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nl.json
index 3330bca6..05e4d164 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/nl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/nl.json
@@ -32,7 +32,8 @@
"FabianRM",
"Mbch331",
"Mainframe98",
- "Effeietsanders"
+ "Effeietsanders",
+ "Patio"
]
},
"visualeditor-cite-tool-name-book": "Boek",
@@ -62,6 +63,7 @@
"cite-ve-referenceslist-isempty": "Er zijn geen referenties op deze pagina met de groep \"$1\" om toe te voegen aan deze lijst.",
"cite-ve-referenceslist-isempty-default": "Er zijn op deze pagina geen referenties die in deze lijst opgenomen kunnen worden.",
"cite-ve-referenceslist-missingref": "Deze referentie bevindt zich in een sjabloon of een ander soort gegenereerd blok en kan voorlopig alleen in de broncodemodus bewerkt worden.",
+ "cite-ve-referenceslist-missingref-in-list": "Deze referentie staat in een sjabloon of elders gemaakt blok waarvan men nu alleen broncode kan zien.",
"cite-ve-toolbar-group-label": "Citeren",
"cite-ve-othergroup-item": "$1 referentie",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referenties"
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/oc.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/oc.json
index 623c7824..1bfb85f2 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/oc.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/oc.json
@@ -4,7 +4,8 @@
"Jfblanc",
"Cedric31",
"Fitoschido",
- "McDutchie"
+ "McDutchie",
+ "Unuaiga"
]
},
"visualeditor-cite-tool-name-book": "Libre",
@@ -13,11 +14,11 @@
"visualeditor-cite-tool-name-web": "Site web",
"cite-ve-dialog-reference-options-group-label": "Utilizar aquel grop",
"cite-ve-dialog-reference-options-group-placeholder": "Referéncias generalas",
- "cite-ve-dialog-reference-options-name-label": "Reutilizar per aquel nom",
+ "cite-ve-dialog-reference-options-name-label": "Reütilizar per aquel nom",
"cite-ve-dialog-reference-options-section": "Opcions",
"cite-ve-dialog-reference-title": "Referéncia",
"cite-ve-dialog-reference-useexisting-full-label": "Reütilizar una referéncia qu'existís ja sus aquesta pagina",
- "cite-ve-dialog-reference-useexisting-label": "Reutilizar una referéncia",
+ "cite-ve-dialog-reference-useexisting-label": "Reütilizar una referéncia",
"cite-ve-dialog-reference-useexisting-tool": "Reütilizar",
"cite-ve-dialog-referenceslist-contextitem-description-general": "Lista de referéncias generalas",
"cite-ve-dialog-referenceslist-title": "Lista de referéncias",
@@ -27,5 +28,6 @@
"cite-ve-referenceslist-isempty": "I a pas de referéncia dins lo grop \"$1\" d'aquesta pagina per apondre a aquela lista.",
"cite-ve-referenceslist-isempty-default": "I a pas de referéncias dins aquela pagina a apondre a aquela lista.",
"cite-ve-referenceslist-missingref": "Aquela referéncia es definida dins un modèl o un autre blòt generat, e pòt per ara èsser modificada sonque en edicion de font.",
+ "cite-ve-referenceslist-missingref-in-list": "Aquela referéncia es definida dins un modèl o un autre blòt generat, per ara e pòt èsser previsualizada sonque en edicion de font.",
"cite-ve-toolbar-group-label": "Citar"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/or.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/or.json
index 719b7aa9..fe5bb218 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/or.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/or.json
@@ -15,4 +15,4 @@
"cite-ve-dialog-referenceslist-title": "ଆଧାର ଗୁଡ଼ିକର ତାଲିକା",
"cite-ve-dialogbutton-reference-tooltip": "ଆଧାର",
"cite-ve-dialogbutton-referenceslist-tooltip": "ଆଧାର ଗୁଡ଼ିକର ତାଲିକା"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pfl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pfl.json
index 060d6aa4..4312e7af 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pfl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pfl.json
@@ -18,4 +18,4 @@
"cite-ve-dialogbutton-reference-tooltip": "Änzlnochwees",
"cite-ve-dialogbutton-referenceslist-tooltip": "Lisch vunde Änzlnochwees",
"cite-ve-toolbar-group-label": "Zidaad"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pms.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pms.json
index d7daedc4..d81b1faa 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pms.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pms.json
@@ -20,4 +20,4 @@
"cite-ve-referenceslist-isempty": "A-i é gnun-a rëspondensa con la partìa «$1» su sta pàgina da buté an costa lista.",
"cite-ve-referenceslist-isempty-default": "A-i é gnun-a rëspondensa an costa pàgina da buté an costa lista.",
"cite-ve-referenceslist-missingref": "St'arferiment a l'é definì an në stamp o n'àutr blòch generà, e për adess a peul mach esse modificà an manera sorgiss"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt-br.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt-br.json
index 0e14ed98..05eb1a04 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt-br.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt-br.json
@@ -25,7 +25,8 @@
"TheGabrielZaum",
"!Silent",
"McDutchie",
- "Felipe L. Ewald"
+ "Felipe L. Ewald",
+ "Eduardo Addad de Oliveira"
]
},
"visualeditor-cite-tool-definition.json": "nulo",
@@ -40,10 +41,14 @@
"cite-ve-changedesc-reflist-group-both": "O grupo de lista de referências mudou de \"$1\" para \"$2\"",
"cite-ve-changedesc-reflist-group-from": "Grupo de lista de referências alterado de \"$1\" para o grupo geral",
"cite-ve-changedesc-reflist-group-to": "Grupo de lista de referências alterado do grupo geral para \"$1\"",
+ "cite-ve-changedesc-reflist-responsive-set": "Lista de referências alterada para mostrar nas colunas de resposta rápida",
+ "cite-ve-changedesc-reflist-responsive-unset": "Lista de referências alterada para mostrar numa só coluna",
+ "cite-ve-changedesc-reflist-item-id": "Índice da referência alterado",
"cite-ve-dialog-reference-editing-reused": "Esta referência foi usada $1 {{PLURAL:$1|vezes}} nesta página.",
"cite-ve-dialog-reference-options-group-label": "Usar este grupo",
"cite-ve-dialog-reference-options-group-placeholder": "Referências gerais",
"cite-ve-dialog-reference-options-name-label": "Reutilizar por este nome",
+ "cite-ve-dialog-reference-options-responsive-label": "Usar disposição de resposta rápida em colunas",
"cite-ve-dialog-reference-options-section": "Opções",
"cite-ve-dialog-reference-placeholder": "Escreva ou cole sua referência aqui, ou insira um modelo de citação.",
"cite-ve-dialog-reference-title": "Referência",
@@ -63,6 +68,8 @@
"cite-ve-referenceslist-isempty": "Não há qualquer referência com o grupo \"$1\" nesta página para incluir nesta lista.",
"cite-ve-referenceslist-isempty-default": "Não há qualquer referência nesta página para a incluir nesta lista.",
"cite-ve-referenceslist-missingref": "Esta referência está definida em uma predefinição ou em um outro bloco gerado e, por enquanto só pode ser editada no código-fonte.",
+ "cite-ve-referenceslist-missingref-in-list": "Esta referência está definida numa predefinição ou outro bloco, e de momento só pode ser antevista no modo de código-fonte.",
+ "cite-ve-referenceslist-missingreflist": "Esta lista de referências é gerada por uma predefinição, e até ao momento só pode ser editada no modo de código-fonte.",
"cite-ve-toolbar-group-label": "Citar",
"cite-ve-othergroup-item": "Referência $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referências",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt.json
index e05de9ba..b40f3fe6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/pt.json
@@ -18,14 +18,15 @@
"He7d3r",
"Amire80",
"Imperadeiro90",
- "Macofe"
+ "Macofe",
+ "Athena in Wonderland"
]
},
"visualeditor-cite-tool-definition.json": "nulo",
"visualeditor-cite-tool-name-book": "Livro",
"visualeditor-cite-tool-name-journal": "Periódico",
"visualeditor-cite-tool-name-news": "Notícias",
- "visualeditor-cite-tool-name-web": "Site",
+ "visualeditor-cite-tool-name-web": "Sítio web",
"cite-tool-definition.json": "nulo",
"cite-ve-changedesc-ref-group-both": "Grupo da referência alterado de \"$1\" para \"$2\"",
"cite-ve-changedesc-ref-group-from": "Grupo da referência alterado de \"$1\" para o grupo geral",
@@ -33,11 +34,14 @@
"cite-ve-changedesc-reflist-group-both": "Grupo da lista de referências alterado de \"$1\" para \"$2\"",
"cite-ve-changedesc-reflist-group-from": "Grupo da lista de referências alterado de \"$1\" para o grupo geral",
"cite-ve-changedesc-reflist-group-to": "Grupo da lista de referências alterado do grupo geral para \"$1\"",
+ "cite-ve-changedesc-reflist-responsive-set": "Lista de referências alterada para mostrar nas colunas de resposta rápida",
+ "cite-ve-changedesc-reflist-responsive-unset": "Lista de referências alterada para mostrar numa só coluna",
"cite-ve-changedesc-reflist-item-id": "Índice da referência alterado",
"cite-ve-dialog-reference-editing-reused": "Esta referência é usada $1 {{PLURAL:$1|vezes}} nesta página.",
"cite-ve-dialog-reference-options-group-label": "Usar este grupo",
"cite-ve-dialog-reference-options-group-placeholder": "Referências gerais",
"cite-ve-dialog-reference-options-name-label": "Reutilizar por este nome",
+ "cite-ve-dialog-reference-options-responsive-label": "Usar disposição de resposta rápida em colunas",
"cite-ve-dialog-reference-options-section": "Opções",
"cite-ve-dialog-reference-placeholder": "Escreva ou copie e insira a sua referência aqui, ou insira uma predefinição de citação.",
"cite-ve-dialog-reference-title": "Referência",
@@ -57,6 +61,8 @@
"cite-ve-referenceslist-isempty": "Não existem referências com o grupo \"$1\" nesta página para incluir nesta lista.",
"cite-ve-referenceslist-isempty-default": "Não há nenhuma referência nesta página para incluir nesta lista.",
"cite-ve-referenceslist-missingref": "Esta referência está definida numa predefinição ou noutro bloco, e de momento só pode ser editada através do código-fonte.",
+ "cite-ve-referenceslist-missingref-in-list": "Esta referência está definida numa predefinição ou noutro bloco, e de momento só pode ser antevista no modo de código-fonte.",
+ "cite-ve-referenceslist-missingreflist": "Esta lista de referências é gerada por uma predefinição e por enquanto só pode ser editada no modo de código-fonte.",
"cite-ve-toolbar-group-label": "Citar",
"cite-ve-othergroup-item": "Referência $1",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Referências",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/qqq.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/qqq.json
index 68709b46..711b99cc 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/qqq.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/qqq.json
@@ -28,18 +28,20 @@
"Pikne"
]
},
- "visualeditor-cite-tool-definition.json": "{{ignored}}\nLegacy name for cite-tool-definition.json message.\n{{Identical|Null}}",
+ "visualeditor-cite-tool-definition.json": "<!-- THE IGNORING OF THIS MESSAGE SEEMS SOMEWHAT WRONG, SEE https://phabricator.wikimedia.org/T183678 FOR DETAILS\n{{ignored}}\n-->\nLegacy name for cite-tool-definition.json message.\n{{Identical|Null}}",
"visualeditor-cite-tool-name-book": "Title of tool that inserts a citation for a book.\n{{Identical|Book}}",
"visualeditor-cite-tool-name-journal": "Title of tool that inserts a citation for a journal\n{{Identical|Journal}}",
"visualeditor-cite-tool-name-news": "Title of tool that inserts a citation for a news.\n{{Identical|News}}",
"visualeditor-cite-tool-name-web": "Title of tool that inserts a citation for a website.\n{{Identical|Website}}",
- "cite-tool-definition.json": "{{ignored}}\nJSON list of objects detailing each citation with name (key referring to a visualeditor-cite-tool-name-x message), icon ('ref-cite-book', 'ref-cite-journal', 'ref-cite-news', 'ref-cite-web'), and template name\n{{Identical|Null}}",
+ "cite-tool-definition.json": "<!-- THE IGNORING OF THIS MESSAGE SEEMS SOMEWHAT WRONG, SEE https://phabricator.wikimedia.org/T183678 FOR DETAILS\n{{ignored}}\n-->\nJSON list of objects detailing each citation with name (key referring to a visualeditor-cite-tool-name-x message), icon ('ref-cite-book', 'ref-cite-journal', 'ref-cite-news', 'ref-cite-web'), and template name\n{{Identical|Null}}",
"cite-ve-changedesc-ref-group-both": "Description of a reference changing group\n\nParameters:\n* $1 – the name of the group it was before\n* $2 – the name of the group it is now",
"cite-ve-changedesc-ref-group-from": "Description of a reference changing group to the general group\n\nParameters:\n* $1 – the name of the group it was before",
"cite-ve-changedesc-ref-group-to": "Description of a reference changing group from the general group\n\nParameters:\n* $1 – the name of the group it is now",
"cite-ve-changedesc-reflist-group-both": "Description of a references list changing group\n\nParameters:\n* $1 – the name of the group it was before\n* $2 – the name of the group it is now",
"cite-ve-changedesc-reflist-group-from": "Description of a references list changing group to the general group\n\nParameters:\n* $1 – the name of the group it was before",
"cite-ve-changedesc-reflist-group-to": "Description of a references list changing group from the general group\n\nParameters:\n* $1 – the name of the group it is now",
+ "cite-ve-changedesc-reflist-responsive-set": "Description of a references list changing responsiveness to on",
+ "cite-ve-changedesc-reflist-responsive-unset": "Description of a references list changing responsiveness to off",
"cite-ve-changedesc-reflist-item-id": "Description of the visible index of a reference changing",
"cite-ve-dialog-reference-editing-reused": "Text shown at the top of the reference dialog when editing a reference that is used multiple times.\n\nParameters:\n* $1 - Number of times used. This is always greater than 1.",
"cite-ve-dialog-reference-options-group-label": "Label for the reference group input",
@@ -64,7 +66,9 @@
"cite-ve-reference-input-placeholder": "Placeholder text for reference search field: searches existing on-page references.",
"cite-ve-referenceslist-isempty": "Message that appears in the references list when there are no references on the page of that group.\n\nParameters:\n* $1 - reference-group name",
"cite-ve-referenceslist-isempty-default": "Message that appears in the references list when there are no references on the page in the default group.",
- "cite-ve-referenceslist-missingref": "Message that appears in the references list, and as a tooltip on the reference itself, for references that are generated by a template or are otherwise uneditable.\n\nSee also:\n* {{msg-mw|visualeditor-dialog-meta-languages-readonlynote}}",
+ "cite-ve-referenceslist-missingref": "Message that appears as a tooltip on the reference, for references that are generated by a template or are otherwise uneditable.\n\nSee also:\n* {{msg-mw|visualeditor-dialog-meta-languages-readonlynote}}",
+ "cite-ve-referenceslist-missingref-in-list": "Message that appears in the references list for references that are generated by a template or are otherwise uneditable.\n\nSee also:\n* {{msg-mw|visualeditor-dialog-meta-languages-readonlynote}}",
+ "cite-ve-referenceslist-missingreflist": "Message that appears as a tooltip on the reference list for lists that are generated by a template.",
"cite-ve-toolbar-group-label": "Label text for the toolbar button for inserting customized references.\n{{Identical|Cite}}",
"cite-ve-othergroup-item": "Label text for the toolbar items under the 'Insert' (other) group if VisualEditor is configured that way.\n\nParameters:\n* $1 – citation type label\n** {{msg-mw|cite-ve-dialogbutton-reference-tooltip}}\n** {{msg-mw|cite-ve-dialog-reference-useexisting-tool}})\n{{Identical|Reference}}",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Heading in the visual diff for the default reference group.\n{{Identical|Reference}}",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/qu.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/qu.json
index 51f75a0c..f68e794e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/qu.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/qu.json
@@ -18,4 +18,4 @@
"cite-ve-dialogbutton-reference-tooltip": "Tiksi",
"cite-ve-dialogbutton-referenceslist-tooltip": "Pukyumanta willay sutisuyu",
"cite-ve-toolbar-group-label": "Qillqamanta willay"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/rm.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/rm.json
index ab69ef63..68506b5b 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/rm.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/rm.json
@@ -12,4 +12,4 @@
"cite-ve-dialog-referenceslist-title": "Glista d'annotaziuns",
"cite-ve-dialogbutton-reference-tooltip": "Annotaziun",
"cite-ve-dialogbutton-referenceslist-tooltip": "Glista d'annotaziuns"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ro.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ro.json
index edeb828f..ad6b428e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ro.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ro.json
@@ -10,18 +10,32 @@
"Amire80",
"ImGelu",
"Wintereu",
- "Reception123"
+ "Reception123",
+ "Strainu"
]
},
+ "visualeditor-cite-tool-definition.json": "nul",
"visualeditor-cite-tool-name-book": "Carte",
"visualeditor-cite-tool-name-journal": "Jurnal",
"visualeditor-cite-tool-name-news": "Știre",
"visualeditor-cite-tool-name-web": "Site web",
+ "cite-tool-definition.json": "nul",
+ "cite-ve-changedesc-ref-group-both": "Grupul referinței a fost schimbat din \"$1\" în \"$2\"",
+ "cite-ve-changedesc-ref-group-from": "Grupul referinței a fost schimbat din \"$1\" în grupul general",
+ "cite-ve-changedesc-ref-group-to": "Grupul referinței a fost schimbat din grupul general în \"$1\"",
+ "cite-ve-changedesc-reflist-group-both": "Grupul listei de referințe a fost schimbat din \"$1\" în \"$2\"",
+ "cite-ve-changedesc-reflist-group-from": "Grupul listei de referințe a fost schimbat din \"$1\" în grupul general",
+ "cite-ve-changedesc-reflist-group-to": "Grupul listei de referințe a fost schimbat din grupul general în \"$1\"",
+ "cite-ve-changedesc-reflist-responsive-set": "Lista de referințe a fost schimbată pentru a fi afișată pe coloane.",
+ "cite-ve-changedesc-reflist-responsive-unset": "Lista de referințe a fost schimbată pentru a fi afișată pe o singură coloană.",
+ "cite-ve-changedesc-reflist-item-id": "Indexul referinței a fost schimbat",
"cite-ve-dialog-reference-editing-reused": "Această referință este utilizată {{PLURAL:$1|o singură dată|de $1 ori|de $1 de ori}} în această pagină.",
"cite-ve-dialog-reference-options-group-label": "Folosește acest grup",
"cite-ve-dialog-reference-options-group-placeholder": "Referințe generale",
"cite-ve-dialog-reference-options-name-label": "Reutilizează cu acest nume",
+ "cite-ve-dialog-reference-options-responsive-label": "Folosiți afișarea pe coloane dinamice",
"cite-ve-dialog-reference-options-section": "Opțiuni",
+ "cite-ve-dialog-reference-placeholder": "Scrieți sau lipiți referința aici, sau inserați un format de citare.",
"cite-ve-dialog-reference-title": "Referință",
"cite-ve-dialog-reference-useexisting-full-label": "Reutilizează o referință deja existentă în această pagină",
"cite-ve-dialog-reference-useexisting-label": "Utilizează o referință existentă",
@@ -39,6 +53,9 @@
"cite-ve-referenceslist-isempty": "Nu există referințe cu grupul „$1” în această pagină pentru includere în această listă.",
"cite-ve-referenceslist-isempty-default": "Nu există referințe în această pagină pentru includere în această listă.",
"cite-ve-referenceslist-missingref": "Această referință este definită printr-un format sau alt cadru generat și, pentru moment, poate fi modificată doar editând codul sursă al paginii.",
+ "cite-ve-referenceslist-missingreflist": "Această listă de referințe este generată de un format și momentan nu poate fi editată decât în modul sursă.",
"cite-ve-toolbar-group-label": "Citare",
- "cite-ve-othergroup-item": "referință $1"
+ "cite-ve-othergroup-item": "referință $1",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Referințe",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Numele grupului de referințe: \"$1\""
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/roa-tara.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/roa-tara.json
index bbd4045f..0c301411 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/roa-tara.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/roa-tara.json
@@ -21,6 +21,7 @@
"cite-ve-dialog-reference-options-group-label": "Ause stu gruppe",
"cite-ve-dialog-reference-options-group-placeholder": "Refereminde generale",
"cite-ve-dialog-reference-options-name-label": "Ause arrete stu nome",
+ "cite-ve-dialog-reference-options-responsive-label": "Ause a 'u layout d'a colonne ca se adatte",
"cite-ve-dialog-reference-options-section": "Opziune",
"cite-ve-dialog-reference-placeholder": "Scrive o 'ngolle le refereminde tune aqquà, o sckaffe 'nu modelle de citazione.",
"cite-ve-dialog-reference-title": "Referimende",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ru.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ru.json
index 9640f845..44a3a069 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ru.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ru.json
@@ -27,7 +27,9 @@
"Дмитрий",
"Краснорядцева Елена",
"Mailman",
- "Facenapalm"
+ "Facenapalm",
+ "Mouse21",
+ "Happy13241"
]
},
"visualeditor-cite-tool-definition.json": "null",
@@ -42,10 +44,14 @@
"cite-ve-changedesc-reflist-group-both": "Группа списка примечаний изменена с «$1» на «$2»",
"cite-ve-changedesc-reflist-group-from": "Группа списка примечаний изменена с «$1» на общую группу",
"cite-ve-changedesc-reflist-group-to": "Группа списка примечаний изменена с общей группы на «$1»",
+ "cite-ve-changedesc-reflist-responsive-set": "Список литературы изменен для отображения в ответных столбцах",
+ "cite-ve-changedesc-reflist-responsive-unset": "Список литературы изменен для отображения только в одном столбце",
+ "cite-ve-changedesc-reflist-item-id": "Изменился индекс сноски",
"cite-ve-dialog-reference-editing-reused": "Эта ссылка используется на странице $1 раз{{PLURAL:$1|||а}}.",
"cite-ve-dialog-reference-options-group-label": "Использовать эту группу",
"cite-ve-dialog-reference-options-group-placeholder": "Общие ссылки",
"cite-ve-dialog-reference-options-name-label": "Повторно использовать под данным именем",
+ "cite-ve-dialog-reference-options-responsive-label": "Использовать адаптивный макет столбцов",
"cite-ve-dialog-reference-options-section": "Параметры",
"cite-ve-dialog-reference-placeholder": "Напишите или скопируйте вашу сноску сюда, или вставьте шаблон источника.",
"cite-ve-dialog-reference-title": "Примечание",
@@ -65,6 +71,8 @@
"cite-ve-referenceslist-isempty": "На этой странице нет ссылок с группой «$1» для включения в этот список.",
"cite-ve-referenceslist-isempty-default": "На этой странице нет ссылок для включения в этот список.",
"cite-ve-referenceslist-missingref": "Эта сноска определена в шаблоне или другом генерируемом блоке и на данный момент может быть отредактирована только в режиме правки исходного текста.",
+ "cite-ve-referenceslist-missingref-in-list": "Эта ссылка определяется в шаблоне или другом сгенерированном блоке и на данный момент может быть просмотрена только в исходном режиме.",
+ "cite-ve-referenceslist-missingreflist": "Этот список ссылок генерируется шаблоном, и теперь его можно редактировать только в режиме источника.",
"cite-ve-toolbar-group-label": "Источники",
"cite-ve-othergroup-item": "$1 примечание",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Сноски",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sa.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sa.json
index 0e6b3f57..b85533fd 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sa.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sa.json
@@ -17,4 +17,4 @@
"cite-ve-dialog-referenceslist-title": "सन्दर्भसूचिः",
"cite-ve-dialogbutton-reference-tooltip": "प्राथमिकम्",
"cite-ve-dialogbutton-referenceslist-tooltip": "सन्दर्भसूचिः"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sah.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sah.json
index 9e2b69b3..6f5e5660 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sah.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sah.json
@@ -22,11 +22,11 @@
"cite-ve-dialog-referenceslist-contextitem-description-named": "\"$1\" бөлөххө анаммыт быһаарыылар тиһиликтэрэ",
"cite-ve-dialog-referenceslist-title": "Быһаарыылар тиһиктэрэ",
"cite-ve-dialogbutton-reference-full-label": "Судургу форма",
- "cite-ve-dialogbutton-reference-tooltip": "Судургу",
"cite-ve-dialogbutton-reference-title": "Быһаарыы",
+ "cite-ve-dialogbutton-reference-tooltip": "Судургу",
"cite-ve-dialogbutton-referenceslist-tooltip": "Быһаарыылар тиһиктэрэ",
"cite-ve-referenceslist-isempty": "Бу тиһиликкэ киирэр \"$1\" бөлөх сигэлэрэ сирэйгэ көстүбэтилэр.",
"cite-ve-referenceslist-isempty-default": "Бу тиһиликкэ киирэр сигэлэр сирэйгэ көстүбэтилэр.",
"cite-ve-referenceslist-missingref": "Бу хос быһаарыы халыып иһигэр сылдьар эбит, онон төрүт тиэкиһи эрэдээксийэлээһин эрэ көмөтүнэн уларытыллар кыахтаах.",
"cite-ve-toolbar-group-label": "Хантан ылыллыбыта"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sc.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sc.json
index 18eb0a49..d9be5c9b 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sc.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sc.json
@@ -9,4 +9,4 @@
]
},
"visualeditor-cite-tool-name-news": "Noas"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/scn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/scn.json
index 76e59194..79aedf79 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/scn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/scn.json
@@ -24,4 +24,4 @@
"cite-ve-referenceslist-isempty": "Nun sunnu prisenti rifirimenti cû gruppu \"$1\" nti sta pàggina ca s'hannu a nclùdiri nti st'elencu.",
"cite-ve-referenceslist-isempty-default": "Nun sunnu prisenti rifirimenti nti sta pàggina ca s'hannu a nclùdiri nti st'elencu.",
"cite-ve-referenceslist-missingref": "Stu rifirimentu è difinutu nti nu mudellu o nti n'àutru bloccu giniratu e accamarora pò èssiri canciatu sulu n mudalità surgenti."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sco.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sco.json
index 67508c06..f54b24d7 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sco.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sco.json
@@ -30,4 +30,4 @@
"cite-ve-referenceslist-isempty-default": "Thaur's nae referances oan this page tae incluid in this leet.",
"cite-ve-referenceslist-missingref": "This referance is defined in ae template or ither generatit block, n fer nou can yinlie be eeditit in soorce mode.",
"cite-ve-toolbar-group-label": "Soorce"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sd.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sd.json
index b989aaf4..aa03a6ed 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sd.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sd.json
@@ -18,7 +18,8 @@
"cite-ve-dialog-reference-useexisting-tool": "ٻيهر استعمال ڪريو",
"cite-ve-dialog-referenceslist-contextitem-description-general": "عام حوالن جي فهرست",
"cite-ve-dialogbutton-citation-educationpopup-title": "حوالا",
- "cite-ve-dialogbutton-reference-tooltip": "بنيادي",
"cite-ve-dialogbutton-reference-title": "حوالو",
- "cite-ve-dialogbutton-referenceslist-tooltip": "حوالن جي فهرست"
-} \ No newline at end of file
+ "cite-ve-dialogbutton-reference-tooltip": "بنيادي",
+ "cite-ve-dialogbutton-referenceslist-tooltip": "حوالن جي فهرست",
+ "cite-ve-toolbar-group-label": "حوالو"
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sdc.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sdc.json
index b2fac4ce..6a219994 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sdc.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sdc.json
@@ -5,4 +5,4 @@
]
},
"cite-ve-dialog-reference-options-group-label": "Utirizà kisthu gruppu"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sh.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sh.json
index 2c833b78..d7673f5a 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sh.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sh.json
@@ -32,4 +32,4 @@
"cite-ve-referenceslist-isempty-default": "Nema referenci na ovoj stranici koje bi mogle biti uključene u ovaj popis.",
"cite-ve-referenceslist-missingref": "Ova referenca je definirana u šablonu ili drugom generiranom bloku i sada se može uređivati jedino u izvornom modu.",
"cite-ve-toolbar-group-label": "Citiraj"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/shn.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/shn.json
index d6597090..17815eaf 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/shn.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/shn.json
@@ -6,4 +6,4 @@
]
},
"cite-ve-dialogbutton-reference-title": "ၽိုၼ်ဢိင်"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/si.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/si.json
index d718353c..65bd212b 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/si.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/si.json
@@ -16,4 +16,4 @@
"cite-ve-dialog-reference-options-section": "තෝරාගැනීම්",
"cite-ve-dialogbutton-reference-tooltip": "සමුද්දේශ",
"cite-ve-dialogbutton-referenceslist-tooltip": "සමුද්දේශ ලැයිස්තුව"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sk.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sk.json
index 47c9548b..ed8839cd 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sk.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sk.json
@@ -12,11 +12,20 @@
"visualeditor-cite-tool-name-journal": "Časopis",
"visualeditor-cite-tool-name-news": "Noviny",
"visualeditor-cite-tool-name-web": "Webová stránka",
+ "cite-ve-changedesc-ref-group-both": "Skupina referencie zmenená z „$1“ na „$2“",
+ "cite-ve-changedesc-ref-group-from": "Skupina referencie zmenená z „$1“ na všeobecnú",
+ "cite-ve-changedesc-ref-group-to": "Skupina referencia zmenená zo všeobecnej na „$1“",
+ "cite-ve-changedesc-reflist-group-both": "Skupina zoznamu referencií zmenená z „$1“ na „$2“",
+ "cite-ve-changedesc-reflist-group-from": "Skupina zoznamu referencií zmenená z „$1“ na všeobecnú",
+ "cite-ve-changedesc-reflist-group-to": "Skupina zoznamu referencií zmenená zo všeobecnej na „$1“",
+ "cite-ve-changedesc-reflist-item-id": "Číslo referencie zmenené",
"cite-ve-dialog-reference-editing-reused": "Tato referencia sa na tejto stránke používa $1 {{PLURAL:$1|krát}}.",
"cite-ve-dialog-reference-options-group-label": "Použiť túto skupinu",
"cite-ve-dialog-reference-options-group-placeholder": "Všeobecné referencie",
"cite-ve-dialog-reference-options-name-label": "Opakovane používať pod týmto názvom",
+ "cite-ve-dialog-reference-options-responsive-label": "Použiť responzívny vzhľad stĺpcov",
"cite-ve-dialog-reference-options-section": "Možnosti",
+ "cite-ve-dialog-reference-placeholder": "Sem napíšte alebo vložte referenciu alebo citačnú šablónu.",
"cite-ve-dialog-reference-title": "Referencia",
"cite-ve-dialog-reference-useexisting-full-label": "Opakovane použiť citáciu, ktorá už na stránke existuje",
"cite-ve-dialog-reference-useexisting-label": "Použiť existujúcu referenciu",
@@ -34,5 +43,9 @@
"cite-ve-referenceslist-isempty": "Na tejto stránke neexistuje žiadna referencia v skupine „$1“.",
"cite-ve-referenceslist-isempty-default": "Na tejto stránke nie sú definované žiadne referencie, ktoré by bolo možné zobraziť v tomto zozname.",
"cite-ve-referenceslist-missingref": "Táto referencia je definovaná v šablóne alebo inej automaticky generovanej časti textu. Zatiľ je možné editovať ju len v režime zdrojového kódu.",
- "cite-ve-toolbar-group-label": "Citácia"
+ "cite-ve-referenceslist-missingreflist": "Tento zoznam referencií je generovaný šablónou a zatiaľ ho je možné upravovať len v režime zdrojového textu.",
+ "cite-ve-toolbar-group-label": "Citácia",
+ "cite-ve-othergroup-item": "$1 referencia",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Referencie",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Názov skupiny referencií: „$1“"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-ec.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-ec.json
index a666ffc6..227af813 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-ec.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-ec.json
@@ -8,32 +8,51 @@
"Amire80",
"Srdjan m",
"Сербијана",
- "Obsuser"
+ "Obsuser",
+ "Prevodim",
+ "Acamicamacaraca",
+ "BadDog"
]
},
+ "visualeditor-cite-tool-definition.json": "null",
"visualeditor-cite-tool-name-book": "Књига",
- "visualeditor-cite-tool-name-journal": "Журнал",
+ "visualeditor-cite-tool-name-journal": "Часопис",
"visualeditor-cite-tool-name-news": "Вести",
"visualeditor-cite-tool-name-web": "Веб-сајт",
+ "cite-tool-definition.json": "null",
"cite-ve-changedesc-ref-group-both": "Група референци је промењена из „$1” у „$2”",
"cite-ve-changedesc-ref-group-from": "Група референци промењена из „$1” у општу групу",
"cite-ve-changedesc-ref-group-to": "Група референци промењена из опште групе у „$1”",
"cite-ve-changedesc-reflist-group-both": "Група списка референци је промењена из „$1” у „$2”",
"cite-ve-changedesc-reflist-group-from": "Група списка референци промењена из „$1” у општу групу",
"cite-ve-changedesc-reflist-group-to": "Група списка референци је промењена из опште групе у „$1”",
+ "cite-ve-changedesc-reflist-item-id": "Индекс референце је промењен",
+ "cite-ve-dialog-reference-editing-reused": "Ова референца се користи $1 {{PLURAL:$1|пут|пута}} на овој страници.",
"cite-ve-dialog-reference-options-group-label": "Користи ову групу",
"cite-ve-dialog-reference-options-group-placeholder": "Опште референце",
"cite-ve-dialog-reference-options-name-label": "Поново употреби под овим именом",
+ "cite-ve-dialog-reference-options-responsive-label": "Прилагодљиви распоред колона",
"cite-ve-dialog-reference-options-section": "Опције",
+ "cite-ve-dialog-reference-placeholder": "Напишите или налепите Вашу референцу овде, или унесите шаблон за референцу.",
"cite-ve-dialog-reference-title": "Референца",
+ "cite-ve-dialog-reference-useexisting-full-label": "Поново употреби референцу која већ постоји на овој страници",
"cite-ve-dialog-reference-useexisting-label": "Користи постојећу референцу",
"cite-ve-dialog-reference-useexisting-tool": "Поновно коришћење",
+ "cite-ve-dialog-referenceslist-contextitem-description-general": "Списак општих референци",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "Списак референци за групу: „$1”",
"cite-ve-dialog-referenceslist-title": "Списак референци",
- "cite-ve-dialogbutton-citation-educationpopup-title": "Навођење",
+ "cite-ve-dialogbutton-citation-educationpopup-text": "Ваш садржај изгледа боље са додатим изворима информација. Можете додати референце из књига, новина или веб-сајтова.",
+ "cite-ve-dialogbutton-citation-educationpopup-title": "Референце",
"cite-ve-dialogbutton-reference-full-label": "Основни облик",
"cite-ve-dialogbutton-reference-title": "Референца",
- "cite-ve-dialogbutton-reference-tooltip": "Основне",
+ "cite-ve-dialogbutton-reference-tooltip": "Основна",
"cite-ve-dialogbutton-referenceslist-tooltip": "Списак референци",
- "cite-ve-reference-input-placeholder": "Претражите постојеће референце",
- "cite-ve-toolbar-group-label": "Цитирај"
+ "cite-ve-reference-input-placeholder": "Претражи постојеће референце",
+ "cite-ve-referenceslist-isempty": "Нема референци унутар групе „$1” на овој страници које можете додати у овом списку.",
+ "cite-ve-referenceslist-isempty-default": "Нема референци на овој страници које би могло да се укључе на овај списак.",
+ "cite-ve-referenceslist-missingref": "Ова референца је дефинисана у шаблону или другом генерисаном блоку и за сада може да се уређује само у изворном режиму.",
+ "cite-ve-toolbar-group-label": "Цитирај",
+ "cite-ve-othergroup-item": "$1 референца",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Референце",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Назив групе референци: „$1”"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-el.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-el.json
index cac03be4..b4ac78e3 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-el.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sr-el.json
@@ -3,26 +3,49 @@
"authors": [
"Milicevic01",
"Msannakoval",
- "Srdjan m"
+ "Srdjan m",
+ "Prevodim"
]
},
+ "visualeditor-cite-tool-definition.json": "bez vrednosti",
"visualeditor-cite-tool-name-book": "Knjiga",
"visualeditor-cite-tool-name-journal": "Žurnal",
"visualeditor-cite-tool-name-news": "Novine",
"visualeditor-cite-tool-name-web": "Veb-sajt",
+ "cite-tool-definition.json": "bez vrednosti",
+ "cite-ve-changedesc-ref-group-both": "Grupa referenci promenjena sa grupe „$1” na grupu „$2”.",
+ "cite-ve-changedesc-ref-group-from": "Grupa referenci promenjena sa grupe „$1” na opštu grupu",
+ "cite-ve-changedesc-ref-group-to": "Grupa referenci promenjana sa opšte grupe na grupu „$1”",
+ "cite-ve-changedesc-reflist-group-both": "Grupa spiska referenci je promenjena sa grupe „$1” na grupu „$2”",
+ "cite-ve-changedesc-reflist-group-from": "Grupa spiska referenci promenjena sa grupe „$1” na opštu grupu.",
+ "cite-ve-changedesc-reflist-group-to": "Grupa spiska referenci je promenjena sa opšte grupe na grupu „$1”",
+ "cite-ve-changedesc-reflist-item-id": "Indeks reference je promenjen",
+ "cite-ve-dialog-reference-editing-reused": "Referenca je upotrebljena $1 {{PLURAL:$1|put|puta}} na ovoj stranici.",
"cite-ve-dialog-reference-options-group-label": "Koristi ovu grupu",
"cite-ve-dialog-reference-options-group-placeholder": "Opšte reference",
"cite-ve-dialog-reference-options-name-label": "Ponovo upotrebi pod ovim imenom",
+ "cite-ve-dialog-reference-options-responsive-label": "Koristi prilagodljivi raspored kolona",
"cite-ve-dialog-reference-options-section": "Opcije",
+ "cite-ve-dialog-reference-placeholder": "Pišite ili nalepite vašu referencu ovde, ili unesite šablon za referencu.",
"cite-ve-dialog-reference-title": "Referenca",
+ "cite-ve-dialog-reference-useexisting-full-label": "Ponovo upotrebi referencu koja već postoji na ovoj stranici",
"cite-ve-dialog-reference-useexisting-label": "Koristi postojeću referencu",
"cite-ve-dialog-reference-useexisting-tool": "Ponovno korišćenje",
+ "cite-ve-dialog-referenceslist-contextitem-description-general": "Lista opštih referenci",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "Lista referenci za grupu „$1”",
"cite-ve-dialog-referenceslist-title": "Spisak referenci",
+ "cite-ve-dialogbutton-citation-educationpopup-text": "Vaš sadržaj izgleda bolje sa dodatim izvorima informacija. Možete dodati reference iz knjiga, novina ili veb-sajtova.",
"cite-ve-dialogbutton-citation-educationpopup-title": "Navođenje",
"cite-ve-dialogbutton-reference-full-label": "Osnovni oblik",
"cite-ve-dialogbutton-reference-title": "Referenca",
- "cite-ve-dialogbutton-reference-tooltip": "Osnovne",
+ "cite-ve-dialogbutton-reference-tooltip": "Osnovna",
"cite-ve-dialogbutton-referenceslist-tooltip": "Spisak referenci",
"cite-ve-reference-input-placeholder": "Pretražite postojeće reference",
- "cite-ve-toolbar-group-label": "Citiraj"
-} \ No newline at end of file
+ "cite-ve-referenceslist-isempty": "Nema referenci unutar grupe „$1” na ovoj strani koje možete dodati u ovu listu.",
+ "cite-ve-referenceslist-isempty-default": "Nema referenci na ovoj strani koje možete dodati u ovu listu.",
+ "cite-ve-referenceslist-missingref": "Ova referenca je definisana u šablonu ili drugom formiranom bloku i za sada može biti izmenjen samo izvor.",
+ "cite-ve-toolbar-group-label": "Referenca",
+ "cite-ve-othergroup-item": "$1 referenca",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Reference",
+ "visualeditor-internal-list-diff-group-name-mwreference": "Naziv grupe referenci: „$1”"
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sv.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sv.json
index 59481c55..f9e5251e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sv.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sv.json
@@ -18,7 +18,8 @@
"Dan Koehl",
"Rockyfelle",
"Warrakkk",
- "McDutchie"
+ "McDutchie",
+ "Bengtsson96"
]
},
"visualeditor-cite-tool-definition.json": "null",
@@ -33,10 +34,12 @@
"cite-ve-changedesc-reflist-group-both": "Referenslistgrupp ändrades från \"$1\" till \"$2\"",
"cite-ve-changedesc-reflist-group-from": "Referenslistgrupp ändrades från \"$1\" till den allmänna gruppen",
"cite-ve-changedesc-reflist-group-to": "Referenslistgrupp ändrades från den allmänna gruppen till \"$1\"",
+ "cite-ve-changedesc-reflist-item-id": "Referensindex ändrades",
"cite-ve-dialog-reference-editing-reused": "Denna referens används $1 {{PLURAL:$1|gång|gånger}} på denna sida.",
"cite-ve-dialog-reference-options-group-label": "Använd den här gruppen",
"cite-ve-dialog-reference-options-group-placeholder": "Allmänna referenser",
"cite-ve-dialog-reference-options-name-label": "Använd med detta namn igen",
+ "cite-ve-dialog-reference-options-responsive-label": "Använd responsiva kolumner",
"cite-ve-dialog-reference-options-section": "Alternativ",
"cite-ve-dialog-reference-placeholder": "Skriv eller klistra in din referens här eller infoga en referensmall.",
"cite-ve-dialog-reference-title": "Källa",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sw.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sw.json
index 33f7139c..f407c287 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/sw.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/sw.json
@@ -18,4 +18,4 @@
"cite-ve-dialogbutton-reference-tooltip": "Marejeo",
"cite-ve-dialogbutton-referenceslist-tooltip": "Orodha ya marejeo",
"cite-ve-toolbar-group-label": "Marejeo"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ta.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ta.json
index 624c550a..e4105c00 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ta.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ta.json
@@ -19,4 +19,4 @@
"cite-ve-dialog-reference-options-group-label": "இந்தக் குழுவை பாவிக்கவும்",
"cite-ve-dialog-reference-title": "மேற்கோள்",
"cite-ve-dialogbutton-reference-tooltip": "மேற்கோள்"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/tay.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/tay.json
index 6e1d9575..d15293a2 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/tay.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/tay.json
@@ -9,11 +9,15 @@
"visualeditor-cite-tool-name-journal": "Mtnaq ryax na phtgan kinbalay biru’",
"visualeditor-cite-tool-name-news": "Sinbung",
"visualeditor-cite-tool-name-web": "Wangcan",
+ "cite-ve-dialog-reference-options-group-label": "Sptzyuwaw sa chyuncu",
"cite-ve-dialog-reference-options-section": "Bbzyagan",
"cite-ve-dialog-reference-useexisting-tool": "Sptzyuwaw lawziy",
"cite-ve-dialog-referenceslist-title": "Kt’aniy sa binkgan kktan biru’ na bunkeng",
"cite-ve-dialogbutton-citation-educationpopup-title": "’nagal sa",
+ "cite-ve-dialogbutton-reference-full-label": "Spzyang ’ringan balay na binkgan biru’",
+ "cite-ve-dialogbutton-reference-title": "Kmita’ sa bungkeng",
"cite-ve-dialogbutton-reference-tooltip": "T’ringan balay na",
"cite-ve-dialogbutton-referenceslist-tooltip": "Kt’aniy sa binkgan kktan biru’ na bunkeng",
- "cite-ve-toolbar-group-label": "’nagal sa"
+ "cite-ve-toolbar-group-label": "’nagal sa",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "Kmita’ sa bungkeng"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/te.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/te.json
index 899f3b2a..be93122c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/te.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/te.json
@@ -30,4 +30,4 @@
"cite-ve-dialogbutton-referenceslist-tooltip": "మూలాల జాబితా",
"cite-ve-referenceslist-isempty": "ఈ జాబితాలో ఉన్న  పేజీలో గ్రూప్ \"$ 1\" తో ఎటువంటి సూచనలు లేవు.",
"cite-ve-referenceslist-missingref": "ఈ సూచన ఒక టెంప్లేట్ లేదా ఇతర ఉత్పత్తి బ్లాక్ లో వివరించబడింది, మరియు ఇప్పుడు  మూలం రీతిలో మాత్రమే సవరించవచ్చు."
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/tg-cyrl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/tg-cyrl.json
index 0924f817..55a36480 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/tg-cyrl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/tg-cyrl.json
@@ -10,4 +10,4 @@
"visualeditor-cite-tool-name-web": "Сомона",
"cite-ve-dialog-reference-options-group-label": "Истифодаи ин гурӯҳ",
"cite-ve-dialog-reference-options-section": "Ихтиёрот"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/th.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/th.json
index 9e9bcb83..9ff50aa6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/th.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/th.json
@@ -13,11 +13,20 @@
"visualeditor-cite-tool-name-news": "ข่าว",
"visualeditor-cite-tool-name-web": "เว็บไซต์",
"cite-tool-definition.json": "ไม่ได้กำหนด",
+ "cite-ve-changedesc-ref-group-both": "เปลี่ยนกลุ่มอ้างอิงจาก \"$1\" เป็น \"$2\"",
+ "cite-ve-changedesc-ref-group-from": "เปลี่ยนกลุ่มอ้างอิงจาก \"$1\" เป็นกลุ่มทั่วไป",
+ "cite-ve-changedesc-ref-group-to": "เปลี่ยนกลุ่มอ้างอิงจากกลุ่มทั่วไปเป็น \"$1\"",
+ "cite-ve-changedesc-reflist-group-both": "เปลี่ยนกลุ่มอ้างอิงจาก \"$1\" เป็น \"$2\"",
+ "cite-ve-changedesc-reflist-group-from": "เปลี่ยนกลุ่มอ้างอิงจาก \"$1\" เป็นกลุ่มทั่วไป",
+ "cite-ve-changedesc-reflist-group-to": "เปลี่ยนกลุ่มอ้างอิงจากกลุ่มทั่วไปเป็น \"$1\"",
+ "cite-ve-changedesc-reflist-item-id": "เปลี่ยนดัชนีอ้างอิง",
"cite-ve-dialog-reference-editing-reused": "แหล่งอ้างอิงนี้ถูกใช้แล้ว $1 {{PLURAL:$1|ครั้ง}}บนหน้านี้",
"cite-ve-dialog-reference-options-group-label": "ใช้กลุ่มนี้",
"cite-ve-dialog-reference-options-group-placeholder": "แหล่งอ้างอิงทั่วไป",
"cite-ve-dialog-reference-options-name-label": "ใช้ซ้ำโดยชื่อนี้",
+ "cite-ve-dialog-reference-options-responsive-label": "ใช้ผังแนวตั้งโต้ตอบ",
"cite-ve-dialog-reference-options-section": "ตัวเลือก",
+ "cite-ve-dialog-reference-placeholder": "เขียนหรือวางแหล่งอ้างอิงของคุณที่นี่ หรือแทรกแม่แบบอ้างอิงที่มา",
"cite-ve-dialog-reference-title": "อ้างอิง",
"cite-ve-dialog-reference-useexisting-full-label": "ใช้แหล่งอ้างอิงที่มีอยู่แล้วบนหน้านี้ซ้ำ",
"cite-ve-dialog-reference-useexisting-label": "ใช้การอ้างอิงที่มีอยู่แล้ว",
@@ -35,5 +44,8 @@
"cite-ve-referenceslist-isempty": "ไม่มีแหล่งอ้างอิงในกลุ่ม \"$1\" ในหน้านี้",
"cite-ve-referenceslist-isempty-default": "ไม่มีแหล่งอ้างอิงในหน้านี้",
"cite-ve-referenceslist-missingref": "ข้อมูลอ้างอิงนี้กำหนดไว้ในแม่แบบหรือบล็อกอื่น ๆ ที่สร้างขึ้น ในขณะนี้สามารถสามารถแก้ไขได้เฉพาะในโหมดต้นฉบับ",
- "cite-ve-toolbar-group-label": "อ้างอิง"
+ "cite-ve-toolbar-group-label": "อ้างอิง",
+ "cite-ve-othergroup-item": "$1 อ้างอิง",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "อ้างอิง",
+ "visualeditor-internal-list-diff-group-name-mwreference": "ชื่อกลุ่มอ้างอิง: \"$1\""
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/tl.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/tl.json
index 5b508541..49a4bfe5 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/tl.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/tl.json
@@ -28,4 +28,4 @@
"cite-ve-referenceslist-isempty-default": "Walang sanggunian sa pahinang ito ang maisasama sa talang ito.",
"cite-ve-referenceslist-missingref": "Binigyan ng katuturan ang sangguniang ito sa isang padron o ibang uri ng blokeng ginawa, at sa panahong ito maaari lamang itong baguhin gamit ang paraang batayan.",
"cite-ve-toolbar-group-label": "Isangguni"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ug-arab.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ug-arab.json
index 7f168701..aec96224 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ug-arab.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ug-arab.json
@@ -5,5 +5,7 @@
"Tel'et",
"Tifinaghes"
]
- }
-} \ No newline at end of file
+ },
+ "cite-ve-dialog-reference-options-section": "تاللانما",
+ "cite-ve-dialog-reference-title": "نەقىل"
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/uk.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/uk.json
index 158e9dd9..7011106b 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/uk.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/uk.json
@@ -39,6 +39,7 @@
"cite-ve-dialog-reference-options-group-label": "Використати цю групу",
"cite-ve-dialog-reference-options-group-placeholder": "Загальні посилання",
"cite-ve-dialog-reference-options-name-label": "Повторно використати з цією назвою",
+ "cite-ve-dialog-reference-options-responsive-label": "Використовувати розкладку чутливих стовпців",
"cite-ve-dialog-reference-options-section": "Параметри",
"cite-ve-dialog-reference-placeholder": "Напишіть або вставте свою примітку сюди, або ж вставте шаблон джерела.",
"cite-ve-dialog-reference-title": "Примітка",
@@ -58,6 +59,7 @@
"cite-ve-referenceslist-isempty": "На цій сторінці немає приміток групи «$1», які можна було б внести до цього списку.",
"cite-ve-referenceslist-isempty-default": "На цій сторінці немає приміток, які можна було б внести до цього списку.",
"cite-ve-referenceslist-missingref": "Ця примітка визначена у шаблоні або іншому генерованому блоці, і на даний момент її можна редагувати лише в режимі редагування коду.",
+ "cite-ve-referenceslist-missingreflist": "Список приміток генерується шаблоном, наразі його можна редагувати лише в режимі редагування вікірозмітки.",
"cite-ve-toolbar-group-label": "Цитувати",
"cite-ve-othergroup-item": "$1 посилання",
"visualeditor-internal-list-diff-default-group-name-mwreference": "Примітки",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ur.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ur.json
index 9d84c918..2d48ce14 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/ur.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/ur.json
@@ -6,7 +6,8 @@
"عثمان خان شاہ",
"Syedalinaqinaqvi",
"عرفان ارشد",
- "Obaid Raza"
+ "Obaid Raza",
+ "Muhammad Shuaib"
]
},
"visualeditor-cite-tool-definition.json": "خالی",
@@ -20,6 +21,17 @@
"cite-ve-dialog-reference-options-name-label": "اس نام کو دوبارہ استعمال کریں",
"cite-ve-dialog-reference-options-section": "اختیارات",
"cite-ve-dialog-reference-title": "حوالہ",
+ "cite-ve-dialog-reference-useexisting-full-label": "اس صفحے میں پہلے سے موجود حوالے کو دوبارہ استعمال کریں",
+ "cite-ve-dialog-reference-useexisting-tool": "دوبارہ استعمال کریں",
+ "cite-ve-dialog-referenceslist-contextitem-description-general": "عمومی حوالہ جات کی فہرست",
+ "cite-ve-dialog-referenceslist-contextitem-description-named": "گروہ «$1» کے حوالوں کی فہرست",
+ "cite-ve-dialog-referenceslist-title": "حوالہ جات کی فہرست",
+ "cite-ve-dialogbutton-citation-educationpopup-text": "معلومات کے مآخذ شامل کرکے اپنے مواد کو مزید بہتر بنائیں۔ آپ کتابوں، اخبارات اور ویب سائٹ کے حوالے درج کر سکتے ہیں۔",
+ "cite-ve-dialogbutton-reference-full-label": "ابتدائی شکل",
+ "cite-ve-dialogbutton-reference-title": "حوالہ",
+ "cite-ve-dialogbutton-reference-tooltip": "ابتدائی",
+ "cite-ve-dialogbutton-referenceslist-tooltip": "حوالہ جات کی فہرست",
"cite-ve-toolbar-group-label": "حوالہ",
- "cite-ve-othergroup-item": "$1 حوالہ"
+ "cite-ve-othergroup-item": "$1 حوالہ",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "حوالہ جات"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/uz.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/uz.json
index ba8460bc..87a58281 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/uz.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/uz.json
@@ -16,4 +16,4 @@
"cite-ve-dialogbutton-reference-tooltip": "Izoh",
"cite-ve-dialogbutton-referenceslist-tooltip": "Izohlar roʻyxati",
"cite-ve-reference-input-placeholder": "Siz qanaqa dalil keltirmoqchisiz?"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/vec.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/vec.json
index f9fa3640..02147be2 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/vec.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/vec.json
@@ -24,4 +24,4 @@
"cite-ve-referenceslist-isempty-default": "No xe prexenti riferimenti so sta pàjina da includare in sto elenco.",
"cite-ve-referenceslist-missingref": "Sto riferimento el xe definìo inte un modèl o inte 'n altro bloco xenerà e par deso el pol èsar canbià soło che in modałità sorxente.",
"cite-ve-toolbar-group-label": "Citasion"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/vo.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/vo.json
index a9c73645..de1a99db 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/vo.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/vo.json
@@ -11,4 +11,4 @@
"cite-ve-dialog-referenceslist-title": "Jonalised",
"cite-ve-dialogbutton-reference-tooltip": "Jon",
"cite-ve-dialogbutton-referenceslist-tooltip": "Jonalised"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/war.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/war.json
index a5808174..5613b6a6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/war.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/war.json
@@ -12,4 +12,4 @@
"cite-ve-dialog-reference-options-section": "Mga pagpipilian",
"cite-ve-dialog-reference-useexisting-tool": "Gamita utro",
"cite-ve-dialogbutton-reference-title": "Reperensya"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/xmf.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/xmf.json
index be6ae854..411c8de0 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/xmf.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/xmf.json
@@ -26,4 +26,4 @@
"cite-ve-dialogbutton-reference-title": "სქოლიო",
"cite-ve-dialogbutton-reference-tooltip": "ოგაჭგაფუე",
"cite-ve-dialogbutton-referenceslist-tooltip": "სქოლიოშ ერკებული"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/yi.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/yi.json
index fbaeffe7..f36b9f6a 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/yi.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/yi.json
@@ -6,22 +6,28 @@
"十弌"
]
},
+ "visualeditor-cite-tool-definition.json": "נול",
"visualeditor-cite-tool-name-book": "בוך",
"visualeditor-cite-tool-name-journal": "זשורנאל",
"visualeditor-cite-tool-name-news": "נײַעס",
"visualeditor-cite-tool-name-web": "וועבזײַטל",
+ "cite-tool-definition.json": "נול",
+ "cite-ve-changedesc-reflist-group-both": "רעפֿערענצן ליסטע גרופע געענדערט פֿון \"$1\" צו \"$2\"",
+ "cite-ve-changedesc-reflist-item-id": "רעפֿערענץ-אינדעקס געענדערט",
"cite-ve-dialog-reference-editing-reused": "דער רעפערענץ ווערט געניצט $1 {{PLURAL:$1|מאל}} אויף דעם בלאט.",
"cite-ve-dialog-reference-options-group-label": "ניצן די גרופע",
"cite-ve-dialog-reference-options-group-placeholder": "אלגעמיינע רעפערענצן",
"cite-ve-dialog-reference-options-name-label": "ווידערניצן מיט דעם נאמען",
"cite-ve-dialog-reference-options-section": "ברירות",
+ "cite-ve-dialog-reference-placeholder": "שרייבט אדער קלעבט אייער רעפֿערענץ דא, אדער לייגט אריין א ציטאט־מוסטער.",
"cite-ve-dialog-reference-title": "רעפערענץ",
"cite-ve-dialog-reference-useexisting-full-label": "ווידערניצן א ציטירונג וואס אעז שוין פאראן אויף דעם בלאט",
"cite-ve-dialog-reference-useexisting-label": "ניצן אן עקזיסטירנדן רעפערענץ",
"cite-ve-dialog-reference-useexisting-tool": "ווידערניצן",
- "cite-ve-dialog-referenceslist-contextitem-description-general": "לעסטע פון אלגעמיינע רעפערענצן",
+ "cite-ve-dialog-referenceslist-contextitem-description-general": "ליסטע פון אלגעמיינע רעפערענצן",
"cite-ve-dialog-referenceslist-contextitem-description-named": "ליסטע פון רעפערענצן פאר גרופע \"$1\"",
"cite-ve-dialog-referenceslist-title": "רעפערענצן ליסטע",
+ "cite-ve-dialogbutton-citation-educationpopup-text": "פארבעסערט אייער אינהאלט דורך צולייגן קוואלן פון אינפארמאציע. איר קענט ציטירן פון ביכער, צייטונגען און וועבזייטלעך.",
"cite-ve-dialogbutton-citation-educationpopup-title": "ציטירונגען",
"cite-ve-dialogbutton-reference-full-label": "באזיס־פארעם",
"cite-ve-dialogbutton-reference-title": "רעפערענץ",
@@ -30,6 +36,9 @@
"cite-ve-reference-input-placeholder": "זוכן אינערהאלב אקטועלע ציטירונגען",
"cite-ve-referenceslist-isempty": "נישט פֿאראן קיין רעפערענצן מיט דער גרופע \"$1\" אויף דעם בלאט אריינצושליסן אין דער דאזיקער ליסטע.",
"cite-ve-referenceslist-isempty-default": "נישט פאראן קיין רעפערענצן אויף דעם בלאט אריינצושליסן אין דער ליסטע.",
+ "cite-ve-referenceslist-missingref": "דער דאזיקער רעפֿערענצן איז דעפֿינירט אין א מוסטער אדער אנדער גענערירטן בלאק, און דערווייל קען ווערן רעדאקטירט נאר אין קוואלטעקסט מאדע.",
"cite-ve-toolbar-group-label": "ציטירן",
- "visualeditor-internal-list-diff-default-group-name-mwreference": "רעפערענצן"
+ "cite-ve-othergroup-item": "$1 רעפֿערענץ",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "רעפערענצן",
+ "visualeditor-internal-list-diff-group-name-mwreference": "רעפֿערענץ גרופע נאמען: \"$1\""
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/yue.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/yue.json
index 4c014f24..b1afb207 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/yue.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/yue.json
@@ -24,12 +24,12 @@
"cite-ve-dialog-referenceslist-contextitem-description-named": "組「$1」嘅參考一覽",
"cite-ve-dialog-referenceslist-title": "參考一覽",
"cite-ve-dialogbutton-reference-full-label": "基本表格",
- "cite-ve-dialogbutton-reference-tooltip": "基本",
"cite-ve-dialogbutton-reference-title": "參考",
+ "cite-ve-dialogbutton-reference-tooltip": "基本",
"cite-ve-dialogbutton-referenceslist-tooltip": "參考一覽",
"cite-ve-reference-input-placeholder": "你想引用啲乜?",
"cite-ve-referenceslist-isempty": "呢版冇「$1」組嘅參考資料畀你加落呢張表道。",
"cite-ve-referenceslist-isempty-default": "呢版冇參考資料畀你加落呢張表道。",
"cite-ve-referenceslist-missingref": "呢個註腳係用模或者其他組件砌成嘅,現時淨係可以喺源碼模式修改。",
"cite-ve-toolbar-group-label": "引用"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hans.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hans.json
index 9603ae6a..9d62f7c0 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hans.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hans.json
@@ -22,7 +22,8 @@
"Duolaimi",
"Byfserag",
"Linforest",
- "Cwek"
+ "Cwek",
+ "夢蝶葬花"
]
},
"visualeditor-cite-tool-definition.json": "空",
@@ -37,11 +38,14 @@
"cite-ve-changedesc-reflist-group-both": "已将参考列表组从“$1”更改为“$2”",
"cite-ve-changedesc-reflist-group-from": "已将参考列表组从“$1”更改为一般组",
"cite-ve-changedesc-reflist-group-to": "已将参考列表组从一般组更改为“$1”",
+ "cite-ve-changedesc-reflist-responsive-set": "参考列表已更改为在响应栏中显示",
+ "cite-ve-changedesc-reflist-responsive-unset": "参考列表已更改为只在一栏中显示",
"cite-ve-changedesc-reflist-item-id": "参考索引已更改",
"cite-ve-dialog-reference-editing-reused": "这个引用在此页面使用了$1{{PLURAL:$1|次}}。",
"cite-ve-dialog-reference-options-group-label": "使用该组",
"cite-ve-dialog-reference-options-group-placeholder": "一般参考文献",
"cite-ve-dialog-reference-options-name-label": "以该名称重复使用",
+ "cite-ve-dialog-reference-options-responsive-label": "使用响应列布局",
"cite-ve-dialog-reference-options-section": "选项",
"cite-ve-dialog-reference-placeholder": "在此写下或粘贴您的参考资料,或插入引用模板。",
"cite-ve-dialog-reference-title": "参考文献",
@@ -61,6 +65,8 @@
"cite-ve-referenceslist-isempty": "本页面没有可包含在该列表中的组为“$1”的参考文献。",
"cite-ve-referenceslist-isempty-default": "本页面没有可包含在该列表中的参考文献。",
"cite-ve-referenceslist-missingref": "该参考文献定义在模板或其他生成块中,目前只能在源代码模式下编辑。",
+ "cite-ve-referenceslist-missingref-in-list": "该参考文献定义在模板或其他生成块中,目前只能在源代码模式下编辑。",
+ "cite-ve-referenceslist-missingreflist": "此参考资料列表由模板生成,并且目前只能在源代码模式中编辑。",
"cite-ve-toolbar-group-label": "引用",
"cite-ve-othergroup-item": "$1参考文献",
"visualeditor-internal-list-diff-default-group-name-mwreference": "参考文献",
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hant.json b/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hant.json
index 982cd5a8..35d0331f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hant.json
+++ b/www/wiki/extensions/Cite/modules/ve-cite/i18n/zh-hant.json
@@ -19,7 +19,8 @@
"LNDDYL",
"Deryck Chan",
"Cwek",
- "Zhxy 519"
+ "Zhxy 519",
+ "Kly"
]
},
"visualeditor-cite-tool-definition.json": "空",
@@ -28,11 +29,22 @@
"visualeditor-cite-tool-name-news": "新聞",
"visualeditor-cite-tool-name-web": "網站",
"cite-tool-definition.json": "空",
+ "cite-ve-changedesc-ref-group-both": "參考文獻群組已從「$1」更改為「$2」",
+ "cite-ve-changedesc-ref-group-from": "參考文獻群組已從「$1」更改一般群組",
+ "cite-ve-changedesc-ref-group-to": "參考文獻群組已從一般群組更改為「$1」",
+ "cite-ve-changedesc-reflist-group-both": "參考文獻清單群組已從「$1」更改為「$2」",
+ "cite-ve-changedesc-reflist-group-from": "參考文獻清單群組已從「$1」更改一般群組",
+ "cite-ve-changedesc-reflist-group-to": "參考文獻清單群組已從一般群組更改為「$1」",
+ "cite-ve-changedesc-reflist-responsive-set": "僅在回應欄位裡顯示參考文獻清單的更改",
+ "cite-ve-changedesc-reflist-responsive-unset": "僅在一欄裡顯示參考文獻清單的更改",
+ "cite-ve-changedesc-reflist-item-id": "參考文獻索引已更改",
"cite-ve-dialog-reference-editing-reused": "此頁面已使用此參考文獻 $1 {{PLURAL:$1|次}}。",
"cite-ve-dialog-reference-options-group-label": "使用此群組",
"cite-ve-dialog-reference-options-group-placeholder": "一般參考文獻",
"cite-ve-dialog-reference-options-name-label": "以此名稱再使用",
+ "cite-ve-dialog-reference-options-responsive-label": "使用響應式欄位佈局",
"cite-ve-dialog-reference-options-section": "選項",
+ "cite-ve-dialog-reference-placeholder": "在此編寫或貼上您的參考文獻,或是插入引用模板。",
"cite-ve-dialog-reference-title": "參考文獻",
"cite-ve-dialog-reference-useexisting-full-label": "重複使用已經存在於此頁的引用",
"cite-ve-dialog-reference-useexisting-label": "使用現有的參考文獻",
@@ -49,7 +61,11 @@
"cite-ve-reference-input-placeholder": "搜尋目前的引用",
"cite-ve-referenceslist-isempty": "此頁面中無群組為 \"$1\" 的參考文獻可加入引用清單。",
"cite-ve-referenceslist-isempty-default": "此頁面目前無任何參考文獻可加入引用清單。",
- "cite-ve-referenceslist-missingref": "此參考文獻已定義於模板或其他自動產生的區塊上,目前只能使用原始碼模式來編輯。",
+ "cite-ve-referenceslist-missingref": "此參考文獻已定義於模板或其它產生的區塊上,目前只能使用原始碼模式來編輯。",
+ "cite-ve-referenceslist-missingref-in-list": "此參考文獻已定義於模板或其它產生的區塊上,目前只能使用原始碼模式來預覽。",
+ "cite-ve-referenceslist-missingreflist": "此參考文獻清單是由模板所產生,並僅可在原始碼模式下編輯。",
"cite-ve-toolbar-group-label": "引用",
- "cite-ve-othergroup-item": "$1 參考文獻"
+ "cite-ve-othergroup-item": "$1 參考文獻",
+ "visualeditor-internal-list-diff-default-group-name-mwreference": "參考文獻",
+ "visualeditor-internal-list-diff-group-name-mwreference": "參考文獻群組名稱:「$1」"
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-book.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-book.svg
index 9838aa62..97112dca 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-book.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-book.svg
@@ -1,6 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="cite-book">
- <path id="book" d="M14.25 4c-1.033 0-1.875 1.109-2.261 1.822-.411-.713-1.241-1.822-2.26-1.822h-7.729v15h7c.938 0 1.844 1.422 2 2h2c.203-.609.938-2 2-2h7v-15h-7.75zm-3.25 14c-.25-.469-1.203-1-2-1l-4.016.016.008-11.024 4.43-.008c.94 0 1.578 1.178 1.578 2.016v10zm8.016-.984l-4.016-.016c-.734 0-1.719.445-2 1v-10c0-.839.63-2.031 1.594-2.031l4.422.016v11.031z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path d="M14.25 4c-1.033 0-1.875 1.109-2.261 1.822C11.578 5.109 10.748 4 9.729 4H2v15h7c.938 0 1.844 1.422 2 2h2c.203-.609.938-2 2-2h7V4h-7.75zM11 18c-.25-.469-1.203-1-2-1l-4.016.016.008-11.024 4.43-.008C10.362 5.984 11 7.162 11 8v10zm8.016-.984L15 17c-.734 0-1.719.445-2 1V8c0-.839.63-2.031 1.594-2.031l4.422.016v11.031z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-ltr.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-ltr.svg
index b3ed7126..031ac3f0 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-ltr.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-ltr.svg
@@ -1,8 +1,6 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="cite-journal">
- <path id="journal" d="M5 4v17h12c1 0 2-1 2-2v-15h-14zm12 14c0 1-1 1-1 1h-8v-13h9v12z"/>
- <path id="text1" d="M10 9h5v2h-5z"/>
- <path id="text2" d="M10 12h5v2h-5z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="journal" d="M5 4v17h12c1 0 2-1 2-2V4H5zm12 14c0 1-1 1-1 1H8V6h9v12z"/>
+ <path id="text1" d="M10 9h5v2h-5z"/>
+ <path id="text2" d="M10 12h5v2h-5z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-rtl.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-rtl.svg
index 3ffbb3f3..30b74124 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-rtl.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-journal-rtl.svg
@@ -1,8 +1,6 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="cite-journal">
- <path d="M19 4v17h-12c-1 0-2-1-2-2v-15h14zm-12 14c0 1 1 1 1 1h8v-13h-9v12z" id="journal"/>
- <path id="text1" d="M14 9h-5v2h5z"/>
- <path id="text2" d="M14 12h-5v2h5z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="journal" d="M19 4v17H7c-1 0-2-1-2-2V4h14zM7 18c0 1 1 1 1 1h8V6H7v12z"/>
+ <path id="text1" d="M14 9H9v2h5z"/>
+ <path id="text2" d="M14 12H9v2h5z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-ltr.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-ltr.svg
index 24748b15..64deb4f9 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-ltr.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-ltr.svg
@@ -1,11 +1,9 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="cite-news">
- <path id="paper" d="M21 21h-17c-1 0-2-1-2-2v-15h19v17zm-17-15v12.278c0 .397.325.722.722.722h14.28l-.002-13h-15z"/>
- <path id="banner" d="M6 8h11v3h-11z"/>
- <path id="text1" d="M12 12h5v2h-5z"/>
- <path id="text2" d="M6 12h5v2h-5z"/>
- <path id="text3" d="M12 15h5v2h-5z"/>
- <path id="text4" d="M6 15h5v2h-5z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="paper" d="M21 21H4c-1 0-2-1-2-2V4h19v17zM4 6v12.278c0 .397.325.722.722.722h14.28L19 6H4z"/>
+ <path id="banner" d="M6 8h11v3H6z"/>
+ <path id="text1" d="M12 12h5v2h-5z"/>
+ <path id="text2" d="M6 12h5v2H6z"/>
+ <path id="text3" d="M12 15h5v2h-5z"/>
+ <path id="text4" d="M6 15h5v2H6z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-rtl.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-rtl.svg
index 8224a185..211343ad 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-rtl.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-news-rtl.svg
@@ -1,11 +1,9 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="cite-news">
- <path d="M2 21h17c1 0 2-1 2-2v-15h-19v17zm17-15v12.278c0 .397-.325.722-.722.722h-14.28l.002-13h15z" id="paper"/>
- <path id="banner" d="M17 8h-11v3h11z"/>
- <path id="text1" d="M11 12h-5v2h5z"/>
- <path id="text2" d="M17 12h-5v2h5z"/>
- <path id="text3" d="M11 15h-5v2h5z"/>
- <path id="text4" d="M17 15h-5v2h5z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="paper" d="M2 21h17c1 0 2-1 2-2V4H2v17zM19 6v12.278a.724.724 0 0 1-.722.722H3.998L4 6h15z"/>
+ <path id="banner" d="M17 8H6v3h11z"/>
+ <path id="text1" d="M11 12H6v2h5z"/>
+ <path id="text2" d="M17 12h-5v2h5z"/>
+ <path id="text3" d="M11 15H6v2h5z"/>
+ <path id="text4" d="M17 15h-5v2h5z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-web.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-web.svg
index c34baedd..a45256c7 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-web.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/ref-cite-web.svg
@@ -1,7 +1,5 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="cite-web">
- <path id="laptop" d="M22.78 18.46L21 16V4H3v12l-1.757 2.463c-.252.286-.314.695-.157 1.043.157.347.533.494.914.494h20c.382 0 .783-.148.94-.496.156-.348.093-.758-.16-1.044zM4 18l1-2V6h14v10l1 2H4z"/>
- <path id="window" d="M7 16h10V8H7v8zm2-2v-3h6v3H9z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="laptop" d="M22.78 18.46L21 16V4H3v12l-1.757 2.463a.974.974 0 0 0-.157 1.043c.157.347.533.494.914.494h20c.382 0 .783-.148.94-.496a.976.976 0 0 0-.16-1.044zM4 18l1-2V6h14v10l1 2H4z"/>
+ <path id="window" d="M7 16h10V8H7v8zm2-2v-3h6v3H9z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-ltr.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-ltr.svg
index 5986f03a..f0eddbd6 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-ltr.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-ltr.svg
@@ -1,7 +1,5 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="reference-existing">
- <path id="fore-reference" d="M7 5v17h12c1 0 2-1 2-2v-15h-14zm12 14c0 1-1 1-1 1h-8v-13h2v6l2-2 2 2v-6h3v12z"/>
- <path id="back-reference" d="M5 18h-.3c-1.5 0-2.7-1.2-2.7-2.7v-13.5h3v16.2zM2 1h16v2h-16z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="fore-reference" d="M7 5v17h12c1 0 2-1 2-2V5H7zm12 14c0 1-1 1-1 1h-8V7h2v6l2-2 2 2V7h3v12z"/>
+ <path id="back-reference" d="M5 18h-.3C3.2 18 2 16.8 2 15.3V1.8h3V18zM2 1h16v2H2z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-rtl.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-rtl.svg
index 869a220e..1d21f332 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-rtl.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-existing-rtl.svg
@@ -1,7 +1,5 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="reference-existing">
- <path id="fore-reference" d="M17 5v17h-12c-1 0-2-1-2-2v-15h14zm-12 14c0 1 1 1 1 1h8v-13h-2v6l-2-2-2 2v-6h-3v12z"/>
- <path id="back-reference" d="M19 18h.3c1.5 0 2.7-1.2 2.7-2.7v-13.5h-3v16.2zm3-17h-16v2h16z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path id="fore-reference" d="M17 5v17H5c-1 0-2-1-2-2V5h14zM5 19c0 1 1 1 1 1h8V7h-2v6l-2-2-2 2V7H5v12z"/>
+ <path id="back-reference" d="M19 18h.3c1.5 0 2.7-1.2 2.7-2.7V1.8h-3V18zm3-17H6v2h16z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-ltr.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-ltr.svg
index 11e1c751..ae3911df 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-ltr.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-ltr.svg
@@ -1,6 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="reference">
- <path id="bookmark" d="M5 4v17h12c1 0 2-1 2-2v-15h-14zm12 14c0 1-1 1-1 1h-8v-13h2v6l2-2 2 2v-6h3v12z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path d="M5 4v17h12c1 0 2-1 2-2V4H5zm12 14c0 1-1 1-1 1H8V6h2v6l2-2 2 2V6h3v12z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-rtl.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-rtl.svg
index b31bbac0..245bb8d1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-rtl.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/reference-rtl.svg
@@ -1,6 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="reference">
- <path id="bookmark" d="M19 4v17h-12c-1 0-2-1-2-2v-15h14zm-12 14c0 1 1 1 1 1h8v-13h-2v6l-2-2-2 2v-6h-3v12z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path d="M19 4v17H7c-1 0-2-1-2-2V4h14zM7 18c0 1 1 1 1 1h8V6h-2v6l-2-2-2 2V6H7v12z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/references-ltr.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/references-ltr.svg
index 3e0e9a16..606094f1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/references-ltr.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/references-ltr.svg
@@ -1,6 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="reference">
- <path id="books" d="M3 6v12h4v-12h-4zm3 10h-2v-1h2v1zm0-3h-2v-1h2v1zm2-7v12h4v-12h-4zm3 10h-2v-1h2v1zm0-3h-2v-1h2v1zm.934-5.353l6.066 10.353 3.449-2.021-6.065-10.354-3.45 2.022zm7.643 7.111l-1.726 1.012-.506-.862 1.725-1.012.507.862zm-1.517-2.588l-1.725 1.011-.506-.862 1.726-1.012.505.863z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path d="M3 6v12h4V6H3zm3 10H4v-1h2v1zm0-3H4v-1h2v1zm2-7v12h4V6H8zm3 10H9v-1h2v1zm0-3H9v-1h2v1zm.934-5.353L18 18l3.449-2.021-6.065-10.354-3.45 2.022zm7.643 7.111l-1.726 1.012-.506-.862 1.725-1.012.507.862zM18.06 12.17l-1.725 1.011-.506-.862 1.726-1.012.505.863z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/icons/references-rtl.svg b/www/wiki/extensions/Cite/modules/ve-cite/icons/references-rtl.svg
index b6313596..87887836 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/icons/references-rtl.svg
+++ b/www/wiki/extensions/Cite/modules/ve-cite/icons/references-rtl.svg
@@ -1,6 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
-<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
- <g id="reference">
- <path id="books" d="M21.449 6v12h-4v-12h4zm-3 10h2v-1h-2v1zm0-3h2v-1h-2v1zm-2-7v12h-4v-12h4zm-3 10h2v-1h-2v1zm0-3h2v-1h-2v1zm-.934-5.353l-6.066 10.353-3.449-2.021 6.065-10.354 3.45 2.022zm-7.643 7.111l1.726 1.012.506-.862-1.725-1.012-.507.862zm1.517-2.588l1.725 1.011.506-.862-1.726-1.012-.505.863z"/>
- </g>
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="2 2 20 20">
+ <path d="M21.449 6v12h-4V6h4zm-3 10h2v-1h-2v1zm0-3h2v-1h-2v1zm-2-7v12h-4V6h4zm-3 10h2v-1h-2v1zm0-3h2v-1h-2v1zm-.934-5.353L6.449 18 3 15.979 9.065 5.625l3.45 2.022zm-7.643 7.111l1.726 1.012.506-.862-1.725-1.012-.507.862zm1.517-2.588l1.725 1.011.506-.862-1.726-1.012-.505.863z"/>
</svg>
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Converter.test.js b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Converter.test.js
index 65fd6baf..a3410e8f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Converter.test.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Converter.test.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel Cite-specific Converter tests.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
QUnit.module( 've.dm.Converter (Cite)', ve.test.utils.mwEnvironment );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.InternalList.test.js b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.InternalList.test.js
index 52e0adfd..78d3d10f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.InternalList.test.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.InternalList.test.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel Cite-specific InternalList tests.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
QUnit.module( 've.dm.InternalList (Cite)', ve.test.utils.mwEnvironment );
@@ -202,9 +202,7 @@ QUnit.test( 'getItemInsertion', function ( assert ) {
insert: [
{ type: 'internalItem' },
{ type: '/internalItem' }
- ],
- insertedDataOffset: 0,
- insertedDataLength: 2
+ ]
},
{ type: 'retain', length: 1 }
],
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Transaction.test.js b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Transaction.test.js
index 837202ad..bf9f30bc 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Transaction.test.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.Transaction.test.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel Cite-specific Transaction tests.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
QUnit.module( 've.dm.Transaction (Cite)', ve.test.utils.mwEnvironment );
@@ -11,7 +11,6 @@ QUnit.module( 've.dm.Transaction (Cite)', ve.test.utils.mwEnvironment );
QUnit.test( 'newFromDocumentInsertion with references', function ( assert ) {
var i, j, doc2, tx, actualStoreItems, expectedStoreItems, removalOps, doc,
complexDoc = ve.dm.citeExample.createExampleDocument( 'complexInternalData' ),
- comment = { type: 'alienMeta', originalDomElements: $( '<!-- hello -->' ).toArray() },
withReference = [
{ type: 'paragraph' },
'B', 'a', 'r',
@@ -38,96 +37,6 @@ QUnit.test( 'newFromDocumentInsertion with references', function ( assert ) {
],
cases = [
{
- msg: 'metadata insertion',
- doc: 'complexInternalData',
- offset: 0,
- range: new ve.Range( 0, 7 ),
- modify: function ( newDoc ) {
- newDoc.commit( ve.dm.TransactionBuilder.static.newFromMetadataInsertion(
- newDoc, 4, 0, [ comment ]
- ) );
- },
- removalOps: [
- {
- type: 'replace',
- remove: complexDoc.getData( new ve.Range( 0, 7 ) ),
- insert: [
- { type: 'paragraph' },
- { type: '/paragraph' }
- ],
- removeMetadata: complexDoc.getMetadata( new ve.Range( 0, 7 ) ),
- insertMetadata: [ undefined, undefined ],
- insertedDataLength: 2,
- insertedDataOffset: 0
- },
- { type: 'retain', length: 26 }
- ],
- expectedOps: [
- {
- type: 'replace',
- remove: [],
- insert: complexDoc.getData( new ve.Range( 0, 4 ) )
- // Reference gets (unnecessarily) renumbered from auto/0 to auto/1
- .concat( [
- ve.extendObject( true, {}, complexDoc.data.data[ 4 ],
- { attributes: { listKey: 'auto/1' } }
- )
- ] )
- .concat( complexDoc.getData( new ve.Range( 5, 7 ) ) ),
- removeMetadata: [],
- insertMetadata: complexDoc.getMetadata( new ve.Range( 0, 4 ) )
- .concat( [ [ comment ] ] )
- .concat( complexDoc.getMetadata( new ve.Range( 5, 7 ) ) )
- },
- { type: 'retain', length: 3 },
- {
- type: 'replace',
- remove: complexDoc.getData( new ve.Range( 8, 32 ) ),
- insert: complexDoc.getData( new ve.Range( 8, 32 ) ),
- removeMetadata: complexDoc.getMetadata( new ve.Range( 8, 32 ) ),
- insertMetadata: complexDoc.getMetadata( new ve.Range( 8, 32 ) )
- },
- { type: 'retain', length: 1 }
- ]
- },
- {
- msg: 'metadata removal',
- doc: 'complexInternalData',
- offset: 24,
- range: new ve.Range( 24, 31 ),
- modify: function ( newDoc ) {
- newDoc.commit( ve.dm.TransactionBuilder.static.newFromMetadataRemoval(
- newDoc, 6, new ve.Range( 0, 1 )
- ) );
- },
- removalOps: [
- { type: 'retain', length: 24 },
- {
- type: 'replace',
- remove: complexDoc.getData( new ve.Range( 24, 31 ) ),
- insert: [],
- removeMetadata: complexDoc.getMetadata( new ve.Range( 24, 31 ) ),
- insertMetadata: []
- },
- { type: 'retain', length: 2 }
- ],
- expectedOps: [
- { type: 'retain', length: 8 },
- {
- type: 'replace',
- remove: complexDoc.getData( new ve.Range( 8, 24 ) )
- .concat( complexDoc.getData( new ve.Range( 31, 32 ) ) ),
- insert: complexDoc.getData( new ve.Range( 8, 32 ) ),
- removeMetadata: complexDoc.getMetadata( new ve.Range( 8, 24 ) )
- .concat( complexDoc.getMetadata( new ve.Range( 31, 32 ) ) ),
- insertMetadata: complexDoc.getMetadata( new ve.Range( 8, 30 ) )
- .concat( [ [] ] )
- .concat( complexDoc.getMetadata( new ve.Range( 31, 32 ) ) )
- },
- { type: 'retain', length: 1 }
- ]
- },
- {
msg: 'inserting a brand new document; internal lists are merged and items renumbered',
doc: 'complexInternalData',
offset: 7,
@@ -153,10 +62,7 @@ QUnit.test( 'newFromDocumentInsertion with references', function ( assert ) {
type: 'replace',
remove: complexDoc.getData( new ve.Range( 8, 32 ) ),
insert: complexDoc.getData( new ve.Range( 8, 32 ) )
- .concat( withReference.slice( 8, 15 ) ),
- removeMetadata: complexDoc.getMetadata( new ve.Range( 8, 32 ) ),
- insertMetadata: complexDoc.getMetadata( new ve.Range( 8, 32 ) )
- .concat( new Array( 7 ) )
+ .concat( withReference.slice( 8, 15 ) )
},
{ type: 'retain', length: 1 }
]
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.citeExample.js b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.citeExample.js
index c326e1f5..2fd8c7f4 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.citeExample.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.dm.citeExample.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel Cite-specific example data sets.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
ve.dm.citeExample = {};
@@ -18,113 +18,127 @@ ve.dm.citeExample.domToDataCases = {
// <references group="g1"><ref group="g1" name="foo">Ref in refs</ref></references>
body:
'<p>Foo' +
- '<span about="#mwt1" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" id="cite_ref-bar-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
+ '<sup about="#mwt1" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" id="cite_ref-bar-1-0" rel="dc:references" typeof="mw:Extension/ref">' +
'<a href="#cite_note-bar-1">[1]</a>' +
- '</span>' +
+ '</sup>' +
' Baz' +
- '<span about="#mwt2" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Quux&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;:0&quot;}}" id="cite_ref-quux-2-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
+ '<sup about="#mwt2" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Quux&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;:0&quot;}}" id="cite_ref-quux-2-0" rel="dc:references" typeof="mw:Extension/ref">' +
'<a href="#cite_note-.3A0-2">[g1 1]</a>' +
- '</span>' +
+ '</sup>' +
' Whee' +
- '<span about="#mwt3" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;' +
+ '<sup about="#mwt3" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;' +
'<a rel=\\&quot;mw:WikiLink\\&quot; href=\\&quot;./Bar\\&quot;>Bar' +
- '</a>&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" id="cite_ref-bar-1-1" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
+ '</a>&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" id="cite_ref-bar-1-1" rel="dc:references" typeof="mw:Extension/ref">' +
'<a href="#cite_note-bar-1">[1]</a>' +
- '</span>' +
+ '</sup>' +
' Yay' +
// This reference has .body.id instead of .body.html
- '<span about="#mwt4" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-cite-3&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
+ '<sup about="#mwt4" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-cite-3&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}" id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref">' +
'<a href="#cite_note-3">[g1 2]</a>' +
- '</span>' +
+ '</sup>' +
' Quux' +
- '<span about="#mwt5" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Different content&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" id="cite_ref-bar-1-2" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
+ '<sup about="#mwt5" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Different content&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" id="cite_ref-bar-1-2" rel="dc:references" typeof="mw:Extension/ref">' +
'<a href="#cite_note-bar-1">[1]</a>' +
- '</span>' +
+ '</sup>' +
' Foo' +
- '<span about="#mwt6" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" ' +
- 'id="cite_ref-foo-4" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
+ '<sup about="#mwt6" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" ' +
+ 'id="cite_ref-foo-4" rel="dc:references" typeof="mw:Extension/ref">' +
'<a href="#cite_ref-foo-4">[g1 3]</a>' +
- '</span>' +
+ '</sup>' +
'</p>' +
// The HTML below is enriched to wrap reference contents in <span id="mw-cite-[...]">
// which Parsoid doesn't do yet, but T88290 asks for
- '<ol class="references" typeof="mw:Extension/references" about="#mwt7" data-parsoid="{}"' +
+ '<ol class="references" typeof="mw:Extension/references" about="#mwt7"' +
'data-mw="{&quot;name&quot;:&quot;references&quot;,&quot;body&quot;:{' +
- '&quot;html&quot;:&quot;<span about=\\&quot;#mwt8\\&quot; class=\\&quot;reference\\&quot; ' +
+ '&quot;html&quot;:&quot;<sup about=\\&quot;#mwt8\\&quot; class=\\&quot;reference\\&quot; ' +
'data-mw=\\&quot;{&amp;quot;name&amp;quot;:&amp;quot;ref&amp;quot;,&amp;quot;body&amp;quot;:{&amp;quot;html&amp;quot;:&amp;quot;Ref in refs&amp;quot;},' +
'&amp;quot;attrs&amp;quot;:{&amp;quot;group&amp;quot;:&amp;quot;g1&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;foo&amp;quot;}}\\&quot; ' +
'rel=\\&quot;dc:references\\&quot; typeof=\\&quot;mw:Extension/ref\\&quot;>' +
- '<a href=\\&quot;#cite_note-foo-3\\&quot;>[3]</a></span>&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}">' +
+ '<a href=\\&quot;#cite_note-foo-3\\&quot;>[3]</a></sup>&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}">' +
'<li about="#cite_note-.3A0-2" id="cite_note-.3A0-2"><span rel="mw:referencedBy"><a href="#cite_ref-.3A0_2-0">↑</a></span> <span id="mw-cite-:0">Quux</span></li>' +
'<li about="#cite_note-3" id="cite_note-3"><span rel="mw:referencedBy"><a href="#cite_ref-3">↑</a></span> <span id="mw-cite-3">No name</span></li>' +
'<li about="#cite_note-foo-4" id="cite_note-foo-4"><span rel="mw:referencedBy"><a href="#cite_ref-foo_4-0">↑</a></span> <span id="mw-cite-foo">Ref in refs</span></li>' +
'</ol>',
fromDataBody:
'<p>Foo' +
- '<span data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" typeof="mw:Extension/ref">' +
- '</span>' +
+ '<sup data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" typeof="mw:Extension/ref">' +
+ '</sup>' +
' Baz' +
- '<span data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Quux&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;:0&quot;}}" typeof="mw:Extension/ref">' +
- '</span>' +
+ '<sup data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Quux&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;:0&quot;}}" typeof="mw:Extension/ref">' +
+ '</sup>' +
' Whee' +
- '<span data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;' +
+ '<sup data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;' +
'<a rel=\\&quot;mw:WikiLink\\&quot; href=\\&quot;./Bar\\&quot;>Bar' +
'</a>&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" typeof="mw:Extension/ref">' +
- '</span>' +
+ '</sup>' +
' Yay' +
- '<span data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-cite-3&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}" typeof="mw:Extension/ref">' +
- '</span>' +
+ '<sup data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-cite-3&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}" typeof="mw:Extension/ref">' +
+ '</sup>' +
' Quux' +
- '<span data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Different content&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" typeof="mw:Extension/ref">' +
- '</span>' +
+ '<sup data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Different content&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" typeof="mw:Extension/ref">' +
+ '</sup>' +
' Foo' +
- '<span data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" ' +
+ '<sup data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" ' +
'typeof="mw:Extension/ref">' +
- '</span>' +
+ '</sup>' +
'</p>' +
'<div typeof="mw:Extension/references" ' +
'data-mw="{&quot;name&quot;:&quot;references&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;},&quot;body&quot;:{' +
- '&quot;html&quot;:&quot;<span typeof=\\&quot;mw:Extension/ref\\&quot; ' +
+ '&quot;html&quot;:&quot;<sup typeof=\\&quot;mw:Extension/ref\\&quot; ' +
'data-mw=\\&quot;{&amp;quot;name&amp;quot;:&amp;quot;ref&amp;quot;,&amp;quot;body&amp;quot;:{&amp;quot;html&amp;quot;:&amp;quot;Ref in refs&amp;quot;},' +
'&amp;quot;attrs&amp;quot;:{&amp;quot;group&amp;quot;:&amp;quot;g1&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;foo&amp;quot;}}\\&quot;>' +
- '</span>&quot;}}">' +
+ '</sup>&quot;}}">' +
'</div>',
clipboardBody:
'<p>Foo' +
- '<span typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" class="mw-ref">' +
+ '<sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" class="mw-ref">' +
'<a style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a>' +
- '</span>' +
+ '</sup>' +
' Baz' +
- '<span typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Quux&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;:0&quot;}}" class="mw-ref">' +
+ '<sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Quux&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;:0&quot;}}" class="mw-ref">' +
'<a data-mw-group="g1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[g1 1]</span></a>' +
- '</span>' +
+ '</sup>' +
' Whee' +
- '<span typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;' +
+ '<sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;' +
'<a href=\\&quot;./Bar\\&quot; rel=\\&quot;mw:WikiLink\\&quot;>Bar' +
'</a>&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" class="mw-ref">' +
'<a style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a>' +
- '</span>' +
+ '</sup>' +
' Yay' +
// This reference has .body.id instead of .body.html
- '<span typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-cite-3&quot;,&quot;html&quot;:&quot;No name&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}" class="mw-ref">' +
+ '<sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-cite-3&quot;,&quot;html&quot;:&quot;No name&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;}}" class="mw-ref">' +
'<a data-mw-group="g1" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[g1 2]</span></a>' +
- '</span>' +
+ '</sup>' +
' Quux' +
- '<span typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Different content&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" class="mw-ref">' +
+ '<sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Different content&quot;},&quot;attrs&quot;:{&quot;name&quot;:&quot;bar&quot;}}" class="mw-ref">' +
'<a style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a>' +
- '</span>' +
+ '</sup>' +
' Foo' +
- '<span typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" class="mw-ref">' +
+ '<sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" class="mw-ref">' +
'<a data-mw-group="g1" style="counter-reset: mw-Ref 3;"><span class="mw-reflink-text">[g1 3]</span></a>' +
- '</span>' +
+ '</sup>' +
'</p>' +
// The HTML below is enriched to wrap reference contents in <span id="mw-cite-[...]">
// which Parsoid doesn't do yet, but T88290 asks for
- '<div typeof="mw:Extension/references"' +
+ '<div typeof="mw:Extension/references" ' +
'data-mw="{&quot;name&quot;:&quot;references&quot;,&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;},&quot;body&quot;:{' +
- '&quot;html&quot;:&quot;<span typeof=\\&quot;mw:Extension/ref\\&quot; ' +
+ '&quot;html&quot;:&quot;<sup typeof=\\&quot;mw:Extension/ref\\&quot; ' +
'data-mw=\\&quot;{&amp;quot;name&amp;quot;:&amp;quot;ref&amp;quot;,&amp;quot;attrs&amp;quot;:{&amp;quot;group&amp;quot;:&amp;quot;g1&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;foo&amp;quot;},&amp;quot;body&amp;quot;:{&amp;quot;html&amp;quot;:&amp;quot;Ref in refs&amp;quot;}}' +
- '\\&quot; class=\\&quot;mw-ref\\&quot;><a data-mw-group=\\&quot;g1\\&quot; style=\\&quot;counter-reset: mw-Ref 3;\\&quot;><span class=\\&quot;mw-reflink-text\\&quot;>[g1 3]</span></a></span>&quot;}}">' +
+ '\\&quot; class=\\&quot;mw-ref\\&quot;><a data-mw-group=\\&quot;g1\\&quot; style=\\&quot;counter-reset: mw-Ref 3;\\&quot;><span class=\\&quot;mw-reflink-text\\&quot;>[g1 3]</span></a></sup>&quot;}}">' +
+ '<ol class="mw-references references" data-mw-group="g1">' +
+ '<li>' +
+ '<a rel="mw:referencedBy" data-mw-group="g1"><span class="mw-linkback-text">↑ </span></a>' +
+ '<span class="reference-text"><span class="ve-ce-branchNode ve-ce-internalItemNode">Quux</span></span>' +
+ '</li>' +
+ '<li>' +
+ '<a rel="mw:referencedBy" data-mw-group="g1"><span class="mw-linkback-text">↑ </span></a>' +
+ '<span class="reference-text"><span class="ve-ce-branchNode ve-ce-internalItemNode">No name</span></span>' +
+ '</li>' +
+ '<li>' +
+ '<a rel="mw:referencedBy" data-mw-group="g1"><span class="mw-linkback-text">↑ </span></a>' +
+ '<span class="reference-text"><span class="ve-ce-branchNode ve-ce-internalItemNode">Ref in refs</span></span>' +
+ '</li>' +
+ '</ol>' +
'</div>',
head: '<base href="http://example.com" />',
data: [
@@ -222,13 +236,14 @@ ve.dm.citeExample.domToDataCases = {
name: 'references',
attrs: { group: 'g1' },
body: {
- html: '<span about="#mwt8" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Ref in refs&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-foo-3">[3]</a></span>'
+ html: '<sup about="#mwt8" class="reference" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Ref in refs&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}" rel="dc:references" typeof="mw:Extension/ref"><a href="#cite_note-foo-3">[3]</a></sup>'
}
},
- originalMw: '{"name":"references","body":{"html":"<span about=\\"#mwt8\\" class=\\"reference\\" data-mw=\\"{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Ref in refs&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}\\" rel=\\"dc:references\\" typeof=\\"mw:Extension/ref\\"><a href=\\"#cite_note-foo-3\\">[3]</a></span>"},"attrs":{"group":"g1"}}',
+ originalMw: '{"name":"references","body":{"html":"<sup about=\\"#mwt8\\" class=\\"reference\\" data-mw=\\"{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;html&quot;:&quot;Ref in refs&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;g1&quot;,&quot;name&quot;:&quot;foo&quot;}}\\" rel=\\"dc:references\\" typeof=\\"mw:Extension/ref\\"><a href=\\"#cite_note-foo-3\\">[3]</a></sup>"},"attrs":{"group":"g1"}}',
listGroup: 'mwReference/g1',
refGroup: 'g1',
- isResponsive: true
+ isResponsive: true,
+ templateGenerated: false
}
},
{ type: 'paragraph', internal: { generated: 'wrapper' } },
@@ -309,21 +324,21 @@ ve.dm.citeExample.domToDataCases = {
{ type: '/internalList' }
]
},
- 'mw:Reference with metadata': {
- body: '<p><span about="#mwt2" class="reference" ' +
+ 'mw:Reference with comment': {
+ body: '<p><sup about="#mwt2" class="reference" ' +
'data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:' +
'{&quot;html&quot;:&quot;Foo<!-- bar -->&quot;},&quot;attrs&quot;:{}}" ' +
- 'id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref" data-parsoid="{}">' +
- '<a href="#cite_note-bar-1" data-parsoid="{}">[1]</a></span></p>',
- fromDataBody: '<p><span ' +
+ 'id="cite_ref-1-0" rel="dc:references" typeof="mw:Extension/ref">' +
+ '<a href="#cite_note-bar-1">[1]</a></sup></p>',
+ fromDataBody: '<p><sup ' +
'data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:' +
'{&quot;html&quot;:&quot;Foo<!-- bar -->&quot;},&quot;attrs&quot;:{}}" ' +
- 'typeof="mw:Extension/ref"></span></p>',
- clipboardBody: '<p><span typeof="mw:Extension/ref" ' +
+ 'typeof="mw:Extension/ref"></sup></p>',
+ clipboardBody: '<p><sup typeof="mw:Extension/ref" ' +
'data-mw="{&quot;attrs&quot;:{},&quot;body&quot;:' +
'{&quot;html&quot;:&quot;Foo<span rel=\\&quot;ve:Comment\\&quot; data-ve-comment=\\&quot; bar \\&quot;>&amp;nbsp;</span>&quot;},&quot;name&quot;:&quot;ref&quot;}" ' +
' class="mw-ref">' +
- '<a style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></p>',
+ '<a style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>',
head: '<base href="http://example.com" />',
data: [
{ type: 'paragraph' },
@@ -367,6 +382,150 @@ ve.dm.citeExample.domToDataCases = {
{ type: '/internalItem' },
{ type: '/internalList' }
]
+ },
+ 'Template generated reflist': {
+ body: '<p><sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-reference-text-cite_note-1&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;notes&quot;}}"><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;" data-mw-group="notes"><span class="mw-reflink-text">[notes 1]</span></a></sup></p>' +
+ '<div class="mw-references-wrap" typeof="mw:Extension/references mw:Transclusion" about="#mwt4" data-mw="{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;<references group=\\&quot;notes\\&quot; />&quot;}},&quot;i&quot;:0}}]}">' +
+ '<ol class="mw-references references" data-mw-group="notes">' +
+ '<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" data-mw-group="notes" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">Foo</span></li>' +
+ '</ol>' +
+ '</div>',
+ fromDataBody: '<p><sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-reference-text-cite_note-1&quot;},&quot;attrs&quot;:{&quot;group&quot;:&quot;notes&quot;}}"></sup></p>' +
+ '<span typeof="mw:Transclusion" data-mw="{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;<references group=\\&quot;notes\\&quot; />&quot;}},&quot;i&quot;:0}}]}"></span>',
+ clipboardBody: '<p><sup typeof="mw:Extension/ref" data-mw="{&quot;attrs&quot;:{&quot;group&quot;:&quot;notes&quot;},&quot;body&quot;:{&quot;id&quot;:&quot;mw-reference-text-cite_note-1&quot;,&quot;html&quot;:&quot;Foo&quot;},&quot;name&quot;:&quot;ref&quot;}" class="mw-ref"><a data-mw-group="notes" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[notes 1]</span></a></sup></p>' +
+ '<div typeof="mw:Extension/references" data-mw="{&quot;parts&quot;:[{&quot;template&quot;:{&quot;params&quot;:{&quot;1&quot;:{&quot;wt&quot;:&quot;<references group=\\&quot;notes\\&quot; />&quot;}},&quot;target&quot;:{&quot;wt&quot;:&quot;echo&quot;,&quot;href&quot;:&quot;./Template:Echo&quot;},&quot;i&quot;:0}}],&quot;name&quot;:&quot;references&quot;}">' +
+ // TODO: This should list should get populated on copy
+ '<ol class="mw-references references"></ol>' +
+ '</div>',
+ data: [
+ { type: 'paragraph' },
+ {
+ type: 'mwReference',
+ attributes: {
+ contentsUsed: true,
+ listGroup: 'mwReference/notes',
+ listIndex: 0,
+ listKey: 'auto/0',
+ mw: {
+ attrs: {
+ group: 'notes'
+ },
+ body: {
+ id: 'mw-reference-text-cite_note-1'
+ },
+ name: 'ref'
+ },
+ originalMw: '{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"notes"}}',
+ refGroup: 'notes',
+ refListItemId: 'mw-reference-text-cite_note-1'
+ }
+ },
+ { type: '/mwReference' },
+ { type: '/paragraph' },
+ {
+ type: 'mwReferencesList',
+ attributes: {
+ mw: {
+ parts: [ {
+ template: {
+ params: {
+ 1: { wt: '<references group="notes" />' }
+ },
+ target: { wt: 'echo', href: './Template:Echo' },
+ i: 0
+ }
+ } ]
+ },
+ originalMw: '{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"<references group=\\"notes\\" />"}},"i":0}}]}',
+ refGroup: '',
+ listGroup: 'mwReference/',
+ isResponsive: true,
+ templateGenerated: true
+ }
+ },
+ { type: '/mwReferencesList' },
+ { type: 'internalList' },
+ { type: 'internalItem', attributes: { originalHtml: 'Foo' } },
+ {
+ internal: {
+ generated: 'wrapper'
+ },
+ type: 'paragraph'
+ },
+ 'F', 'o', 'o',
+ { type: '/paragraph' },
+ { type: '/internalItem' },
+ { type: '/internalList' }
+ ]
+ },
+ 'Template generated reflist (div wrapped)': {
+ body: '<p><sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-reference-text-cite_note-1&quot;},&quot;attrs&quot;:{}}"><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>' +
+ '<div about="#mwt3" typeof="mw:Transclusion" data-mw="{&quot;parts&quot;:[{&quot;template&quot;:{&quot;target&quot;:{&quot;wt&quot;:&quot;reflist&quot;,&quot;href&quot;:&quot;./Template:Reflist&quot;},&quot;params&quot;:{},&quot;i&quot;:0}}]}">' +
+ '<div typeof="mw:Extension/references" about="#mwt5" data-mw="{&quot;name&quot;:&quot;references&quot;,&quot;attrs&quot;:{}}">' +
+ '<ol class="mw-references references">' +
+ '<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">Foo</span></li>' +
+ '</ol>' +
+ '</div>' +
+ '</div>',
+ fromDataBody: '<p><sup typeof="mw:Extension/ref" data-mw="{&quot;name&quot;:&quot;ref&quot;,&quot;body&quot;:{&quot;id&quot;:&quot;mw-reference-text-cite_note-1&quot;},&quot;attrs&quot;:{}}"></sup></p>' +
+ '<span typeof="mw:Transclusion" data-mw="{&quot;name&quot;:&quot;references&quot;,&quot;attrs&quot;:{}}"></span>',
+ clipboardBody: '<p><sup typeof="mw:Extension/ref" data-mw="{&quot;attrs&quot;:{},&quot;body&quot;:{&quot;id&quot;:&quot;mw-reference-text-cite_note-1&quot;,&quot;html&quot;:&quot;Foo&quot;},&quot;name&quot;:&quot;ref&quot;}" class="mw-ref"><a style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>' +
+ '<div typeof="mw:Extension/references" data-mw="{&quot;name&quot;:&quot;references&quot;,&quot;attrs&quot;:{}}">' +
+ '<ol class="mw-references references">' +
+ '<li><a rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a><span class="reference-text"><span class="ve-ce-branchNode ve-ce-internalItemNode">Foo</span></span></li>' +
+ '</ol>' +
+ '</div>',
+ data: [
+ { type: 'paragraph' },
+ {
+ type: 'mwReference',
+ attributes: {
+ contentsUsed: true,
+ listGroup: 'mwReference/',
+ listIndex: 0,
+ listKey: 'auto/0',
+ mw: {
+ attrs: {},
+ body: {
+ id: 'mw-reference-text-cite_note-1'
+ },
+ name: 'ref'
+ },
+ originalMw: '{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}',
+ refGroup: '',
+ refListItemId: 'mw-reference-text-cite_note-1'
+ }
+ },
+ { type: '/mwReference' },
+ { type: '/paragraph' },
+ {
+ type: 'mwReferencesList',
+ attributes: {
+ mw: {
+ name: 'references',
+ attrs: {}
+ },
+ originalMw: '{"name":"references","attrs":{}}',
+ refGroup: '',
+ listGroup: 'mwReference/',
+ isResponsive: true,
+ templateGenerated: true
+ }
+ },
+ { type: '/mwReferencesList' },
+ { type: 'internalList' },
+ { type: 'internalItem', attributes: { originalHtml: 'Foo' } },
+ {
+ internal: {
+ generated: 'wrapper'
+ },
+ type: 'paragraph'
+ },
+ 'F', 'o', 'o',
+ { type: '/paragraph' },
+ { type: '/internalItem' },
+ { type: '/internalList' }
+ ]
}
};
@@ -493,7 +652,8 @@ ve.dm.citeExample.references = [
originalMw: '{"name":"references","attrs":{"group":"g1"}"}',
listGroup: 'mwReference/',
refGroup: '',
- isResponsive: true
+ isResponsive: true,
+ templateGenerated: false
}
},
{ type: '/mwReferencesList' },
@@ -528,8 +688,6 @@ ve.dm.citeExample.references = [
ve.dm.citeExample.complexInternalData = [
// 0
- { type: 'alienMeta', originalDomElements: $( '<!-- before -->' ).toArray() },
- { type: '/alienMeta' },
{ type: 'paragraph' },
'F', [ 'o', [ ve.dm.example.bold ] ], [ 'o', [ ve.dm.example.italic ] ],
// 4
@@ -544,8 +702,6 @@ ve.dm.citeExample.complexInternalData = [
{ type: '/mwReference' },
// 6
{ type: '/paragraph' },
- { type: 'alienMeta', originalDomElements: $( '<!-- after -->' ).toArray() },
- { type: '/alienMeta' },
// 7
{ type: 'internalList' },
// 8
@@ -554,8 +710,6 @@ ve.dm.citeExample.complexInternalData = [
{ type: 'paragraph', internal: { generated: 'wrapper' } },
'R', [ 'e', [ ve.dm.example.bold ] ], 'f',
// 13
- { type: 'alienMeta', originalDomElements: $( '<!-- reference -->' ).toArray() },
- { type: '/alienMeta' },
'e', [ 'r', [ ve.dm.example.italic ] ], [ 'e', [ ve.dm.example.italic ] ],
// 16
{ type: 'mwReference', attributes: {
@@ -576,23 +730,15 @@ ve.dm.citeExample.complexInternalData = [
{ type: '/internalItem' },
// 23
{ type: 'internalItem' },
- { type: 'alienMeta', originalDomElements: $( '<!-- beginning -->' ).toArray() },
- { type: '/alienMeta' },
// 24
{ type: 'preformatted' },
- { type: 'alienMeta', originalDomElements: $( '<!-- inside -->' ).toArray() },
- { type: '/alienMeta' },
// 25
{ type: 'mwEntity', attributes: { character: '€' } },
// 26
{ type: '/mwEntity' },
'2', '5', '0',
- { type: 'alienMeta', originalDomElements: $( '<!-- inside2 -->' ).toArray() },
- { type: '/alienMeta' },
// 30
{ type: '/preformatted' },
- { type: 'alienMeta', originalDomElements: $( '<!-- end -->' ).toArray() },
- { type: '/alienMeta' },
// 31
{ type: '/internalItem' },
// 32
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.DiffElement.test.js b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.DiffElement.test.js
new file mode 100644
index 00000000..79b4497b
--- /dev/null
+++ b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.DiffElement.test.js
@@ -0,0 +1,67 @@
+/*!
+ * VisualEditor Cite-specific DiffElement tests.
+ *
+ * @copyright 2011-2018 VisualEditor Team and others; see http://ve.mit-license.org
+ */
+
+QUnit.module( 've.ui.DiffElement (Cite)' );
+
+QUnit.test( 'Diffing', function ( assert ) {
+ var i, len,
+ // spacer = '<div class="ve-ui-diffElement-spacer">⋮</div>',
+ ref = function ( text, num, name ) {
+ var dataMw = {
+ name: 'ref',
+ body: { html: text }
+ };
+ if ( name ) {
+ dataMw.attrs = { name: name };
+ }
+ return '<sup typeof="mw:Extension/ref" data-mw="' + JSON.stringify( dataMw ).replace( /"/g, '&quot;' ) + '" class="mw-ref">' +
+ '<a style="counter-reset: mw-Ref ' + num + ';"><span class="mw-reflink-text">[' + num + ']</span></a>' +
+ '</sup>';
+ },
+ cases = [
+ {
+ msg: 'Simple ref change',
+ oldDoc:
+ '<p>' + ref( 'Foo' ) + ref( 'Bar' ) + ref( 'Baz' ) + '</p>' +
+ '<h2>Notes</h2>' +
+ '<div typeof="mw:Extension/references" data-mw="{&quot;name&quot;:&quot;references&quot;}"></div>',
+ newDoc:
+ '<p>' + ref( 'Foo' ) + ref( 'Bar ish' ) + ref( 'Baz' ) + '</p>' +
+ '<h2>Notes</h2>' +
+ '<div typeof="mw:Extension/references" data-mw="{&quot;name&quot;:&quot;references&quot;}"></div>',
+ expected:
+ '<div class="ve-ui-diffElement-doc-child-change">' +
+ '<p>' +
+ ref( 'Foo', '1' ) +
+ '<span data-diff-action="change-remove">' +
+ ref( 'Bar', '2', ':0' ) +
+ '</span>' +
+ '<span data-diff-action="change-insert">' +
+ ref( 'Bar ish', '2', ':0' ) +
+ '</span>' +
+ ref( 'Baz', '3' ) +
+ '</p>' +
+ '</div>' +
+ '<h2 data-diff-action="none">Notes</h2>' +
+ '<div class="ve-ui-diffElement-doc-child-change" data-diff-move="undefined">' +
+ '<ol start="1">' +
+ '<li><p data-diff-action="none">Foo</p></li>' +
+ '</ol>' +
+ '<ol start="2">' +
+ '<li><div class="ve-ui-diffElement-doc-child-change">Bar<ins data-diff-action="insert"> ish</ins></div></li>' +
+ '</ol>' +
+ '<ol start="3">' +
+ '<li><p data-diff-action="none">Baz</p></li>' +
+ '</ol>' +
+ '</div>'
+ }
+ ];
+
+ for ( i = 0, len = cases.length; i < len; i++ ) {
+ ve.test.utils.runDiffElementTest( assert, cases[ i ] );
+ }
+
+} );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.MWWikitextStringTransferHandler.test.js b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.MWWikitextStringTransferHandler.test.js
index 9617e6ab..210dd49c 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.MWWikitextStringTransferHandler.test.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/tests/ve.ui.MWWikitextStringTransferHandler.test.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MWWikitextStringTransferHandler tests.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
window.MWWIKITEXT_MOCK_API = true;
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.css b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.css
index 8b9fa8da..84e7470f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.css
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.css
@@ -1,8 +1,8 @@
/*!
* VisualEditor ContentEditable MediaWiki MWReferenceNode styles.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/* HACK: Hide Ref errors in templates */
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.js
index b17d13b1..9a4b471e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferenceNode.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor ContentEditable MWReferenceNode class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.css b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.css
index 886567d7..b625416f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.css
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.css
@@ -1,8 +1,8 @@
/*!
* VisualEditor ContentEditable MediaWiki MWReferencesListNode styles.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
.ve-ce-mwReferencesListNode .ve-ce-generated-wrapper {
@@ -10,6 +10,6 @@
}
.ve-ce-mwReferencesListNode-muted {
+ color: #72777d;
font-style: italic;
- color: #777;
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.js
index e4a708e7..96843abd 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ce.MWReferencesListNode.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor ContentEditable MWReferencesListNode class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -26,15 +26,17 @@ ve.ce.MWReferencesListNode = function VeCeMWReferencesListNode() {
// Properties
this.internalList = null;
this.listNode = null;
+ this.modified = false;
// DOM changes
this.$element.addClass( 've-ce-mwReferencesListNode' );
this.$reflist = $( '<ol>' ).addClass( 'mw-references references' );
+ this.$originalRefList = null;
this.$refmsg = $( '<p>' )
.addClass( 've-ce-mwReferencesListNode-muted' );
// Events
- this.model.connect( this, { attributeChange: 'onAttributeChange' } );
+ this.getModel().connect( this, { attributeChange: 'onAttributeChange' } );
this.updateDebounced = ve.debounce( this.update.bind( this ) );
@@ -73,7 +75,7 @@ ve.ce.MWReferencesListNode.static.getDescription = function ( model ) {
* @method
*/
ve.ce.MWReferencesListNode.prototype.onSetup = function () {
- this.internalList = this.model.getDocument().getInternalList();
+ this.internalList = this.getModel().getDocument().getInternalList();
this.listNode = this.internalList.getListNode();
this.internalList.connect( this, { update: 'onInternalListUpdate' } );
@@ -109,7 +111,8 @@ ve.ce.MWReferencesListNode.prototype.onTeardown = function () {
*/
ve.ce.MWReferencesListNode.prototype.onInternalListUpdate = function ( groupsChanged ) {
// Only update if this group has been changed
- if ( groupsChanged.indexOf( this.model.getAttribute( 'listGroup' ) ) !== -1 ) {
+ if ( groupsChanged.indexOf( this.getModel().getAttribute( 'listGroup' ) ) !== -1 ) {
+ this.modified = true;
this.updateDebounced();
}
};
@@ -125,6 +128,7 @@ ve.ce.MWReferencesListNode.prototype.onAttributeChange = function ( key ) {
switch ( key ) {
case 'listGroup':
this.updateDebounced();
+ this.modified = true;
break;
case 'isResponsive':
this.updateClasses();
@@ -151,11 +155,29 @@ ve.ce.MWReferencesListNode.prototype.onListNodeUpdate = function () {
*/
ve.ce.MWReferencesListNode.prototype.update = function () {
var i, j, iLen, jLen, index, firstNode, key, keyedNodes, modelNode, viewNode,
- $li, $refSpan, $link,
- internalList = this.model.getDocument().internalList,
- refGroup = this.model.getAttribute( 'refGroup' ),
- listGroup = this.model.getAttribute( 'listGroup' ),
- nodes = internalList.getNodeGroup( listGroup );
+ $li, $refSpan, $link, internalList, refGroup, listGroup, nodes,
+ model = this.getModel();
+
+ // Check the node hasn't been destroyed, as this method is debounced.
+ if ( !model ) {
+ return;
+ }
+
+ internalList = model.getDocument().internalList;
+ refGroup = model.getAttribute( 'refGroup' );
+ listGroup = model.getAttribute( 'listGroup' );
+ nodes = internalList.getNodeGroup( listGroup );
+
+ // Just use Parsoid-provided DOM for first rendering
+ // NB: Technically this.modified could be reset to false if this
+ // node is re-attached, but that is an unlikely edge case.
+ if ( !this.modified && model.getElement().originalDomElementsHash ) {
+ this.$originalRefList = $( model.getStore().value(
+ model.getElement().originalDomElementsHash
+ ) );
+ this.$element.append( this.$originalRefList );
+ return;
+ }
function updateGeneratedContent( viewNode, $li ) {
// HACK: PHP parser doesn't wrap single lines in a paragraph
@@ -179,6 +201,10 @@ ve.ce.MWReferencesListNode.prototype.update = function () {
viewNode.destroy();
}
+ if ( this.$originalRefList ) {
+ this.$originalRefList.remove();
+ this.$originalRefList = null;
+ }
this.$reflist.detach().empty();
this.$refmsg.detach();
@@ -223,10 +249,10 @@ ve.ce.MWReferencesListNode.prototype.update = function () {
$li = $( '<li>' );
if ( keyedNodes.length > 1 ) {
- $refSpan = $( '<span rel="mw:referencedBy">' );
+ $refSpan = $( '<span>' ).attr( 'rel', 'mw:referencedBy' );
for ( j = 0, jLen = keyedNodes.length; j < jLen; j++ ) {
$link = $( '<a>' ).append(
- $( '<span class="mw-linkback-text">' )
+ $( '<span>' ).addClass( 'mw-linkback-text' )
.text( ( j + 1 ) + ' ' )
);
if ( refGroup !== '' ) {
@@ -236,8 +262,9 @@ ve.ce.MWReferencesListNode.prototype.update = function () {
}
$li.append( $refSpan );
} else {
- $link = $( '<a rel="mw:referencedBy">' ).append(
- $( '<span class="mw-linkback-text">' ).text( '↑ ' )
+ $link = $( '<a>' ).attr( 'rel', 'mw:referencedBy' ).append(
+ $( '<span>' ).addClass( 'mw-linkback-text' )
+ .text( '↑ ' )
);
if ( refGroup !== '' ) {
$link.attr( 'data-mw-group', refGroup );
@@ -250,8 +277,10 @@ ve.ce.MWReferencesListNode.prototype.update = function () {
if ( modelNode && modelNode.length ) {
viewNode = new ve.ce.InternalItemNode( modelNode );
+ // Use 'done' instead of 'then' so content is updated synchronously
+ // if possible, for clipboard conversion.
ve.ce.GeneratedContentNode.static.awaitGeneratedContent( viewNode )
- .then( updateGeneratedContent.bind( this, viewNode, $li ) );
+ .done( updateGeneratedContent.bind( this, viewNode, $li ) );
// Because this update runs a number of times when using the
// basic dialog, disconnect the model here rather than waiting
@@ -263,7 +292,7 @@ ve.ce.MWReferencesListNode.prototype.update = function () {
$li.append(
$( '<span>' )
.addClass( 've-ce-mwReferencesListNode-muted' )
- .text( ve.msg( 'cite-ve-referenceslist-missingref' ) )
+ .text( ve.msg( 'cite-ve-referenceslist-missingref-in-list' ) )
);
}
@@ -280,7 +309,7 @@ ve.ce.MWReferencesListNode.prototype.update = function () {
* Currently used to set responsive layout
*/
ve.ce.MWReferencesListNode.prototype.updateClasses = function () {
- var isResponsive = this.model.getAttribute( 'isResponsive' );
+ var isResponsive = this.getModel().getAttribute( 'isResponsive' );
this.$element
.toggleClass( 'mw-references-wrap', isResponsive )
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceModel.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceModel.js
index 64404b82..fcfccfac 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceModel.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceModel.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel MWReferenceModel class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceNode.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceNode.js
index fa0d6cb0..e84d247a 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceNode.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferenceNode.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel MWReferenceNode class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -104,7 +104,7 @@ ve.dm.MWReferenceNode.static.toDomElements = function ( dataElement, doc, conver
var itemNodeHtml, originalHtml, mwData, i, iLen, keyedNodes, setContents, contentsAlreadySet,
originalMw, listKeyParts, name, group, $link,
isForClipboard = converter.isForClipboard(),
- el = doc.createElement( 'span' ),
+ el = doc.createElement( 'sup' ),
itemNodeWrapper = doc.createElement( 'div' ),
originalHtmlWrapper = doc.createElement( 'div' ),
itemNode = converter.internalList.getItemNode( dataElement.attributes.listIndex ),
@@ -216,8 +216,8 @@ ve.dm.MWReferenceNode.static.toDomElements = function ( dataElement, doc, conver
el.setAttribute( 'data-mw', originalMw );
// Return the original DOM elements if possible
- if ( dataElement.originalDomElementsIndex !== undefined ) {
- return ve.copyDomElements( converter.getStore().value( dataElement.originalDomElementsIndex ), doc );
+ if ( dataElement.originalDomElementsHash !== undefined ) {
+ return ve.copyDomElements( converter.getStore().value( dataElement.originalDomElementsHash ), doc );
}
} else {
el.setAttribute( 'data-mw', JSON.stringify( mwData ) );
@@ -330,12 +330,12 @@ ve.dm.MWReferenceNode.static.describeChange = function ( key, change ) {
if ( key === 'refGroup' ) {
if ( change.from ) {
if ( change.to ) {
- return ve.msg( 'cite-ve-changedesc-reflist-group-both', change.from, change.to );
+ return ve.msg( 'cite-ve-changedesc-ref-group-both', change.from, change.to );
} else {
- return ve.msg( 'cite-ve-changedesc-reflist-group-from', change.from );
+ return ve.msg( 'cite-ve-changedesc-ref-group-from', change.from );
}
}
- return ve.msg( 'cite-ve-changedesc-reflist-group-to', change.to );
+ return ve.msg( 'cite-ve-changedesc-ref-group-to', change.to );
}
if ( key === 'refListItemId' ) {
return ve.msg( 'cite-ve-changedesc-reflist-item-id' );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferencesListNode.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferencesListNode.js
index 415e1537..a06968a8 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferencesListNode.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.dm.MWReferencesListNode.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor DataModel MWReferencesListNode class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -30,6 +30,12 @@ OO.inheritClass( ve.dm.MWReferencesListNode, ve.dm.BranchNode );
OO.mixinClass( ve.dm.MWReferencesListNode, ve.dm.FocusableNode );
+/* Methods */
+
+ve.dm.MWReferencesListNode.prototype.isEditable = function () {
+ return !this.getAttribute( 'templateGenerated' );
+};
+
/* Static members */
ve.dm.MWReferencesListNode.static.name = 'mwReferencesList';
@@ -40,18 +46,39 @@ ve.dm.MWReferencesListNode.static.ignoreChildren = true;
ve.dm.MWReferencesListNode.static.matchTagNames = null;
-ve.dm.MWReferencesListNode.static.matchRdfaTypes = [ 'mw:Extension/references' ];
+ve.dm.MWReferencesListNode.static.matchRdfaTypes = [ 'mw:Extension/references', 'mw:Transclusion' ];
+
+ve.dm.MWReferencesListNode.static.matchFunction = function ( domElement ) {
+ function isRefList( el ) {
+ return el && el.nodeType === Node.ELEMENT_NODE && ( el.getAttribute( 'typeof' ) || '' ).indexOf( 'mw:Extension/references' ) !== -1;
+ }
+ // If the template generated only a reference list, treat it as a ref list (T52769)
+ return isRefList( domElement ) ||
+ // A div-wrapped reference list
+ ( domElement.children.length === 1 && isRefList( domElement.children[ 0 ] ) );
+};
ve.dm.MWReferencesListNode.static.preserveHtmlAttributes = false;
ve.dm.MWReferencesListNode.static.toDataElement = function ( domElements, converter ) {
- var referencesListData, contentsDiv, contentsData,
- isResponsiveDefault = mw.config.get( 'wgCiteResponsiveReferences' ),
- mwDataJSON = domElements[ 0 ].getAttribute( 'data-mw' ),
- mwData = mwDataJSON ? JSON.parse( mwDataJSON ) : {},
- refGroup = ve.getProp( mwData, 'attrs', 'group' ) || '',
- responsiveAttr = ve.getProp( mwData, 'attrs', 'responsive' ),
- listGroup = 'mwReference/' + refGroup;
+ var referencesListData, contentsDiv, contentsData, refListNode,
+ mwDataJSON, mwData, refGroup, responsiveAttr, listGroup,
+ type = domElements[ 0 ].getAttribute( 'typeof' ) || '',
+ templateGenerated = type.indexOf( 'mw:Transclusion' ) !== -1,
+ isResponsiveDefault = mw.config.get( 'wgCiteResponsiveReferences' );
+
+ // We may have matched a mw:Transclusion wrapping a reference list, so pull out the refListNode
+ if ( type.indexOf( 'mw:Extension/references' ) !== -1 ) {
+ refListNode = domElements[ 0 ];
+ } else {
+ refListNode = domElements[ 0 ].querySelectorAll( '[typeof*="mw:Extension/references"]' )[ 0 ];
+ }
+
+ mwDataJSON = refListNode.getAttribute( 'data-mw' );
+ mwData = mwDataJSON ? JSON.parse( mwDataJSON ) : {};
+ refGroup = ve.getProp( mwData, 'attrs', 'group' ) || '';
+ responsiveAttr = ve.getProp( mwData, 'attrs', 'responsive' );
+ listGroup = 'mwReference/' + refGroup;
referencesListData = {
type: this.name,
@@ -60,7 +87,8 @@ ve.dm.MWReferencesListNode.static.toDataElement = function ( domElements, conver
originalMw: mwDataJSON,
refGroup: refGroup,
listGroup: listGroup,
- isResponsive: responsiveAttr !== undefined ? responsiveAttr !== '0' : isResponsiveDefault
+ isResponsive: responsiveAttr !== undefined ? responsiveAttr !== '0' : isResponsiveDefault,
+ templateGenerated: templateGenerated
}
};
if ( mwData.body && mwData.body.html ) {
@@ -76,17 +104,36 @@ ve.dm.MWReferencesListNode.static.toDataElement = function ( domElements, conver
};
ve.dm.MWReferencesListNode.static.toDomElements = function ( data, doc, converter ) {
- var el, els, mwData, originalMw, contentsHtml, originalHtml,
+ var el, els, mwData, originalMw, contentsHtml, originalHtml, nextIndex, nextElement, modelNode, viewNode,
isResponsiveDefault = mw.config.get( 'wgCiteResponsiveReferences' ),
+ isForClipboard = converter.isForClipboard(),
wrapper = doc.createElement( 'div' ),
originalHtmlWrapper = doc.createElement( 'div' ),
dataElement = data[ 0 ],
attrs = dataElement.attributes,
contentsData = data.slice( 1, -1 );
- if ( dataElement.originalDomElementsIndex !== undefined ) {
+ // If we are sending a template generated ref back to Parsoid, output it as a template.
+ // This works because the dataElement already as mw, originalMw and originalDomIndex properties.
+ if ( attrs.templateGenerated && !isForClipboard ) {
+ return ve.dm.MWTransclusionNode.static.toDomElements.call( this, dataElement, doc, converter );
+ }
+
+ if ( isForClipboard ) {
+ // Output needs to be read so re-render
+ modelNode = new ve.dm.MWReferencesListNode( dataElement );
+ // Build from original doc's internal list to get all refs (T186407)
+ modelNode.setDocument( converter.originalDocInternalList.getDocument() );
+ viewNode = new ve.ce.MWReferencesListNode( modelNode );
+ viewNode.modified = true;
+ viewNode.update();
+ els = [ doc.createElement( 'div' ) ];
+ els[ 0 ].appendChild( viewNode.$reflist[ 0 ] );
+ // Destroy the view node so it doesn't try to update the DOM node later (e.g. updateDebounced)
+ viewNode.destroy();
+ } else if ( dataElement.originalDomElementsHash !== undefined ) {
// If there's more than 1 element, preserve entire array, not just first element
- els = ve.copyDomElements( converter.getStore().value( dataElement.originalDomElementsIndex ), doc );
+ els = ve.copyDomElements( converter.getStore().value( dataElement.originalDomElementsHash ), doc );
} else {
els = [ doc.createElement( 'div' ) ];
}
@@ -107,6 +154,26 @@ ve.dm.MWReferencesListNode.static.toDomElements = function ( data, doc, converte
delete mwData.attrs.responsive;
}
+ if ( mwData.autoGenerated ) {
+ // This was an autogenerated reflist. We need to check whether changes
+ // have been made which make that no longer true. The reflist dialog
+ // handles unsetting this if changes to the properties have been made.
+ // Here we want to work out if it has been moved away from the end of
+ // the document.
+ // TODO: it would be better to do this without needing to fish through
+ // the converter's linear data. Use the DM tree instead?
+ nextIndex = converter.documentData.indexOf( data[ data.length - 1 ] ) + 1;
+ while ( ( nextElement = converter.documentData[ nextIndex ] ) ) {
+ if ( nextElement.type[ 0 ] !== '/' ) {
+ break;
+ }
+ nextIndex++;
+ }
+ if ( nextElement && nextElement.type !== 'internalList' ) {
+ delete mwData.autoGenerated;
+ }
+ }
+
el = els[ 0 ];
el.setAttribute( 'typeof', 'mw:Extension/references' );
@@ -137,13 +204,21 @@ ve.dm.MWReferencesListNode.static.describeChange = function ( key, change ) {
if ( key === 'refGroup' ) {
if ( change.from ) {
if ( change.to ) {
- return ve.msg( 'cite-ve-changedesc-ref-group-both', change.from, change.to );
+ return ve.msg( 'cite-ve-changedesc-reflist-group-both', change.from, change.to );
} else {
- return ve.msg( 'cite-ve-changedesc-ref-group-from', change.from );
+ return ve.msg( 'cite-ve-changedesc-reflist-group-from', change.from );
}
}
- return ve.msg( 'cite-ve-changedesc-ref-group-to', change.to );
+ return ve.msg( 'cite-ve-changedesc-reflist-group-to', change.to );
+ }
+
+ if ( key === 'isResponsive' ) {
+ if ( change.from ) {
+ return ve.msg( 'cite-ve-changedesc-reflist-responsive-unset' );
+ }
+ return ve.msg( 'cite-ve-changedesc-reflist-responsive-set' );
}
+
if ( key === 'originalMw' ) {
return null;
}
@@ -151,6 +226,18 @@ ve.dm.MWReferencesListNode.static.describeChange = function ( key, change ) {
return null;
};
+ve.dm.MWReferencesListNode.static.getHashObject = function ( dataElement ) {
+ return {
+ type: dataElement.type,
+ attributes: {
+ refGroup: dataElement.attributes.refGroup,
+ listGroup: dataElement.attributes.listGroup,
+ isResponsive: dataElement.attributes.isResponsive,
+ templateGenerated: dataElement.attributes.templateGenerated
+ }
+ };
+};
+
/* Registration */
ve.dm.modelRegistry.register( ve.dm.MWReferencesListNode );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationAction.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationAction.js
index cb9ef4b9..616a9067 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationAction.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationAction.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MWCitationAction class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationContextItem.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationContextItem.js
index 515466dd..da4e1d7e 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationContextItem.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationContextItem.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor MWCitationContextItem class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialog.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialog.js
index 82c448ab..31bb6020 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialog.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialog.js
@@ -1,8 +1,8 @@
/*
* VisualEditor user interface MWCitationDialog class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialogTool.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialogTool.js
index 19883a69..b7011fca 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialogTool.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWCitationDialogTool.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor MediaWiki UserInterface citation dialog tool class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReference.init.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReference.init.js
index dff9aac0..c8a6be19 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReference.init.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReference.init.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor MediaWiki Cite initialisation code.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
( function () {
var i, j, jLen, toolGroup, toolGroups, linkIndex, target, label, group;
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.css b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.css
index f171d49f..ac2463ce 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.css
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.css
@@ -1,12 +1,12 @@
/*!
* VisualEditor MediaWiki UserInterface reference context item styles.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
.ve-ui-mwReferenceContextItem-muted {
- color: #777;
+ color: #72777d;
font-style: italic;
line-height: 1.5;
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.js
index 48464e88..99aa8921 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceContextItem.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor MWReferenceContextItem class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialog.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialog.js
index a8fcd0ca..f041784d 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialog.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialog.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MediaWiki MWReferenceDialog class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -44,7 +44,7 @@ ve.ui.MWReferenceDialog.static.actions = [
{
action: 'insert',
label: OO.ui.deferMsg( 'visualeditor-dialog-action-insert' ),
- flags: [ 'primary', 'constructive' ],
+ flags: [ 'progressive', 'primary' ],
modes: 'insert'
},
{
@@ -301,7 +301,7 @@ ve.ui.MWReferenceDialog.prototype.initialize = function () {
this.contentFieldset = new OO.ui.FieldsetLayout();
this.optionsFieldset = new OO.ui.FieldsetLayout( {
label: ve.msg( 'cite-ve-dialog-reference-options-section' ),
- icon: 'settings'
+ icon: 'advanced'
} );
this.contentFieldset.$element.append( this.referenceTarget.$element );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialogTool.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialogTool.js
index c87dc2b1..1db75909 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialogTool.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceDialogTool.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor MediaWiki Reference dialog tool classes.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.css b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.css
index 2c12eb52..227f7f01 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.css
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.css
@@ -1,10 +1,10 @@
/*!
* VisualEditor MediaWiki UserInterface MWReferenceGroupInputWidget styles.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
.ve-ui-mwReferenceGroupInputWidget .oo-ui-flaggableElement-emptyGroupPlaceholder {
- color: #888;
+ color: #72777d;
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.js
index 63fe251d..ebe72aa1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceGroupInputWidget.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MWReferenceGroupInput class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.css b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.css
index 68ae0900..85986f64 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.css
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.css
@@ -1,14 +1,14 @@
/*!
* VisualEditor MediaWiki UserInterface MWReferenceResultWidget styles.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
.ve-ui-mwReferenceResultWidget {
position: relative;
padding: 1em;
- border-bottom: solid 1px #eee;
+ border-bottom: 1px solid #eaecf0;
}
.ve-ui-mwReferenceResultWidget:last-child {
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.js
index 807e25c3..6b1034d8 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceResultWidget.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MWReferenceResultWidget class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.css b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.css
index 25e81daa..c972e270 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.css
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.css
@@ -1,8 +1,8 @@
/*!
* VisualEditor MediaWiki UserInterface MWReferenceSearchWidget styles.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
.ve-ui-mwReferenceSearchWidget-citation {
@@ -11,8 +11,8 @@
}
.ve-ui-mwReferenceSearchWidget-name {
+ color: #72777d;
float: right;
margin-left: 0.75em;
margin-bottom: 0.05em;
- color: #777;
}
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.js
index 49c5d3df..421b2bd1 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferenceSearchWidget.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MWReferenceSearchWidget class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -60,8 +60,8 @@ ve.ui.MWReferenceSearchWidget.prototype.onQueryChange = function () {
ve.ui.MWReferenceSearchWidget.prototype.setInternalList = function ( internalList ) {
var i, iLen, groupNames, groupName, groups = internalList.getNodeGroups();
- if ( this.results.getSelectedItem() ) {
- this.results.getSelectedItem().setSelected( false );
+ if ( this.results.findSelectedItem() ) {
+ this.results.findSelectedItem().setSelected( false );
}
this.internalList = internalList;
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListCommand.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListCommand.js
index eac79ea1..0ab9af85 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListCommand.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListCommand.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MediaWiki ReferencesListCommand class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListContextItem.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListContextItem.js
index 26f260ab..46c9f2fb 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListContextItem.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListContextItem.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor MWReferencesListContextItem class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -46,6 +46,22 @@ ve.ui.MWReferencesListContextItem.static.commandName = 'referencesList';
/**
* @inheritdoc
*/
+ve.ui.MWReferencesListContextItem.prototype.renderBody = function () {
+ this.$body.append(
+ $( '<div>' ).text( this.getDescription() )
+ );
+ if ( this.model.getAttribute( 'templateGenerated' ) ) {
+ this.$body.append(
+ $( '<div>' )
+ .addClass( 've-ui-mwReferenceContextItem-muted' )
+ .text( ve.msg( 'cite-ve-referenceslist-missingreflist' ) )
+ );
+ }
+};
+
+/**
+ * @inheritdoc
+ */
ve.ui.MWReferencesListContextItem.prototype.getDescription = function () {
var group = this.model.getAttribute( 'refGroup' );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListDialog.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListDialog.js
index bfaf0024..10dba30f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListDialog.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWReferencesListDialog.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor user interface MWReferencesListDialog class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
@@ -101,7 +101,7 @@ ve.ui.MWReferencesListDialog.prototype.initialize = function () {
ve.ui.MWReferencesListDialog.prototype.getActionProcess = function ( action ) {
if ( action === 'apply' ) {
return new OO.ui.Process( function () {
- var refGroup, listGroup, oldListGroup, isResponsive, oldResponsive, attrChanges, doc,
+ var refGroup, listGroup, oldListGroup, isResponsive, oldResponsive, mwData, attrChanges, doc,
surfaceModel = this.getFragment().getSurface();
// Save changes
@@ -116,10 +116,18 @@ ve.ui.MWReferencesListDialog.prototype.getActionProcess = function ( action ) {
oldResponsive = this.selectedNode.getAttribute( 'isResponsive' );
if ( listGroup !== oldListGroup || isResponsive !== oldResponsive ) {
+ // newFromAttributeChanges doesn't do the smart-replacing
+ // for nested attributes, so make a copy of the mw
+ // attribute so we can disable autoGenerated now we've
+ // changed it.
+ mwData = ve.copy( this.selectedNode.getAttribute( 'mw' ) ) || {};
+ delete mwData.autoGenerated;
+
attrChanges = {
listGroup: listGroup,
refGroup: refGroup,
- isResponsive: isResponsive
+ isResponsive: isResponsive,
+ mw: mwData
};
surfaceModel.change(
ve.dm.TransactionBuilder.static.newFromAttributeChanges(
@@ -155,6 +163,16 @@ ve.ui.MWReferencesListDialog.prototype.getSetupProcess = function ( data ) {
}, this );
};
+/**
+ * @inheritdoc
+ */
+ve.ui.MWReferencesListDialog.prototype.getReadyProcess = function ( data ) {
+ return ve.ui.MWReferencesListDialog.super.prototype.getReadyProcess.call( this, data )
+ .next( function () {
+ this.groupInput.focus();
+ }, this );
+};
+
/* Registration */
ve.ui.windowFactory.register( ve.ui.MWReferencesListDialog );
diff --git a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWUseExistingReferenceCommand.js b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWUseExistingReferenceCommand.js
index 65912bbb..0066d39f 100644
--- a/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWUseExistingReferenceCommand.js
+++ b/www/wiki/extensions/Cite/modules/ve-cite/ve.ui.MWUseExistingReferenceCommand.js
@@ -1,8 +1,8 @@
/*!
* VisualEditor UserInterface MediaWiki UseExistingReferenceCommand class.
*
- * @copyright 2011-2017 Cite VisualEditor Team and others; see AUTHORS.txt
- * @license The MIT License (MIT); see LICENSE.txt
+ * @copyright 2011-2018 VisualEditor Team's Cite sub-team and others; see AUTHORS.txt
+ * @license MIT
*/
/**
diff --git a/www/wiki/extensions/Cite/tests/parser/citeParserTests.txt b/www/wiki/extensions/Cite/tests/parser/citeParserTests.txt
index dba772dc..527b6e77 100644
--- a/www/wiki/extensions/Cite/tests/parser/citeParserTests.txt
+++ b/www/wiki/extensions/Cite/tests/parser/citeParserTests.txt
@@ -10,6 +10,12 @@ Template:echo
{{{1}}}
!! endarticle
+!! article
+Template:refinref
+!! text
+<ref>ho</ref>
+!! endarticle
+
!! test
Simple <ref>, no <references/>
!! wikitext
@@ -425,7 +431,7 @@ Wikipedia rocks!<ref group="klingon">Proceeds of Rockology, vol. XXI</ref>
<references group="klingon"/>
!! html
-<p>Wikipedia rocks!<sup id="cite_ref-1" class="reference"><a href="#cite_note-1">&#91;wa'&#93;</a></sup>
+<p>Wikipedia rocks!<sup id="cite_ref-1" class="reference"><a href="#cite_note-1">&#91;wa&#39;&#93;</a></sup>
</p>
<div class="mw-references-wrap"><ol class="references">
<li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1">↑</a></span> <span class="reference-text">Proceeds of Rockology, vol. XXI</span>
@@ -608,6 +614,48 @@ Multiple definition (inside {{#tag:references}})
!! end
+# Parsoid doesn't rt cleanly because name attribute is actually broken
+# here (<ref> tag closes at first >); see next test for a tidied version.
+!! test
+T29694 - [] in reference names in HTML5 fragment mode
+!! config
+wgFragmentMode=[ 'html5' ]
+!! options
+parsoid=wt2html
+!! wikitext
+<ref name="[#foo] {bar} <baz>">[bar]</ref>
+!! html/php
+<sup id="cite_ref-&#91;#foo&#93;_&#123;bar&#125;_&lt;baz_1-0" class="reference"><a href="#cite_note-[#foo]_{bar}_&lt;baz-1">&#91;1&#93;</a></sup><div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-&#91;#foo&#93;_&#123;bar&#125;_&lt;baz-1"><span class="mw-cite-backlink"><a href="#cite_ref-[#foo]_{bar}_&lt;baz_1-0">↑</a></span> <span class="reference-text">"&gt;[bar]</span>
+</li>
+</ol></div>
+
+!! html/parsoid
+<p><sup about="#mwt2" class="mw-ref" id="cite_ref-[#foo]_{bar}_&lt;baz_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-[#foo]_{bar}_&lt;baz-1"},"attrs":{"name":"[#foo] {bar} &lt;baz"}}'><a href="./Main_Page#cite_note-[#foo]_{bar}_&lt;baz-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><li about="#cite_note-[#foo]_{bar}_&lt;baz-1" id="cite_note-[#foo]_{bar}_&lt;baz-1"><a href="./Main_Page#cite_ref-[#foo]_{bar}_&lt;baz_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-[#foo]_{bar}_&lt;baz-1" class="mw-reference-text" data-parsoid="{}">">[bar]</span></li></ol>
+!! end
+
+!! test
+T29694 - [] in reference names in HTML5 fragment mode (tidied)
+!! config
+wgFragmentMode=[ 'html5' ]
+!! wikitext
+<ref name="[#foo] {bar} <baz&gt;">[bar]</ref>
+<references />
+!! html/php
+<p><sup id="cite_ref-&#91;#foo&#93;_&#123;bar&#125;_&lt;baz&gt;_1-0" class="reference"><a href="#cite_note-[#foo]_{bar}_&lt;baz&gt;-1">&#91;1&#93;</a></sup>
+</p>
+<div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-&#91;#foo&#93;_&#123;bar&#125;_&lt;baz&gt;-1"><span class="mw-cite-backlink"><a href="#cite_ref-[#foo]_{bar}_&lt;baz&gt;_1-0">↑</a></span> <span class="reference-text">[bar]</span>
+</li>
+</ol></div>
+
+!! html/parsoid
+<p><sup about="#mwt2" class="mw-ref" id="cite_ref-[#foo]_{bar}_&lt;baz>_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-[#foo]_{bar}_&lt;baz>-1"},"attrs":{"name":"[#foo] {bar} &lt;baz>"}}'><a href="./Main_Page#cite_note-[#foo]_{bar}_&lt;baz>-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-[#foo]_{bar}_&lt;baz>-1" id="cite_note-[#foo]_{bar}_&lt;baz>-1"><a href="./Main_Page#cite_ref-[#foo]_{bar}_&lt;baz>_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-[#foo]_{bar}_&lt;baz>-1" class="mw-reference-text" data-parsoid="{}">[bar]</span></li></ol>
+!! end
+
+
#### ----------------------------------------------------------------
#### Parsoid-only testing of Parsoid's impl of <ref> and <references>
#### tags. Parsoid's output for these tags differs from that of the
@@ -622,10 +670,10 @@ B <ref name="x">foo</ref>
C <ref name="y" />
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-x_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-2"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-2"><span class="mw-reflink-text">[2]</span></a></span>
-C <span about="#mwt6" class="mw-ref" id="cite_ref-y_3-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"y"}}'><a href="./Main_Page#cite_note-y-3"><span class="mw-reflink-text">[3]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-x_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-2"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-2"><span class="mw-reflink-text">[2]</span></a></sup>
+C <sup about="#mwt6" class="mw-ref" id="cite_ref-y_3-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"y"}}'><a href="./Main_Page#cite_note-y-3"><span class="mw-reflink-text">[3]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
<li about="#cite_note-x-2" id="cite_note-x-2"><a href="./Main_Page#cite_ref-x_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-x-2" class="mw-reference-text">foo</span></li>
<li about="#cite_note-y-3" id="cite_note-y-3"><a href="./Main_Page#cite_ref-y_3-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-y-3" class="mw-reference-text"></span></li>
@@ -639,9 +687,9 @@ A <ref name="x">foo</ref>
B <ref name="x" />
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-x_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-1"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-x_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-x_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-1"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-x_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-x-1" id="cite_note-x-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-x_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-x_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-x-1" class="mw-reference-text">foo</span></li>
</ol>
!! end
@@ -654,10 +702,10 @@ B <ref name=" x " />
C <ref name= x />
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-x_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-1"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-x_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span>
-C <span about="#mwt6" class="mw-ref" id="cite_ref-x_1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-x_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-x-1"},"attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-x_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></sup>
+C <sup about="#mwt6" class="mw-ref" id="cite_ref-x_1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"x"}}'><a href="./Main_Page#cite_note-x-1"><span class="mw-reflink-text">[1]</span></a></supn></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-x-1" id="cite_note-x-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-x_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-x_1-1"><span class="mw-linkback-text">2 </span></a><a href="./Main_Page#cite_ref-x_1-2"><span class="mw-linkback-text">3 </span></a></span> <span id="mw-reference-text-cite_note-x-1" class="mw-reference-text">foo</span></li>
</ol>
!! end
@@ -669,8 +717,8 @@ Ref: 4. 'constructor' should be accepted as a valid ref-name
A <ref name="constructor">foo</ref>
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-constructor_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-constructor-1"},"attrs":{"name":"constructor"}}'><a href="./Main_Page#cite_note-constructor-1"><span class="mw-reflink-text">[1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-constructor_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-constructor-1"},"attrs":{"name":"constructor"}}'><a href="./Main_Page#cite_note-constructor-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-constructor-1" id="cite_note-constructor-1"><a href="./Main_Page#cite_ref-constructor_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-constructor-1" class="mw-reference-text">foo</span></li>
</ol>
!! end
@@ -684,9 +732,9 @@ A <ref>
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">This is a <b><a rel="mw:WikiLink" href="./Bolded_link" title="Bolded link">bolded link</a></b> and this is a <span about="#mwt3" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"transclusion"}},"i":0}}]}'>transclusion</span>
</span></li>
</ol>
@@ -703,9 +751,9 @@ A <ref>
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo
bar
baz
@@ -731,9 +779,9 @@ booz
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo
bar
@@ -755,8 +803,8 @@ A <ref> foo {{echo|</ref> B C}}
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B C}}</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup> B C}}</p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo {{echo|</span></li>
</ol>
!! end
@@ -767,8 +815,8 @@ Ref: 9. unclosed comments should not leak out of ref-body
A <ref> foo <!--</ref> B C
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B C</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup> B C</p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo <!----></span></li>
</ol>
!! end
@@ -780,10 +828,10 @@ A <ref> <b> foo </ref> B C
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B C</p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup> B C</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text"><b data-parsoid='{"stx":"html","autoInsertedEnd":true}'> foo </b></span></li>
</ol>
!! end
@@ -795,9 +843,9 @@ A <ref>foo</ref> B
C <ref>bar</ref> D
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B
-C <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></span> D</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup> B
+C <sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></sup> D</p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
<li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
</ol>
@@ -817,11 +865,11 @@ c
<!--the newline at the end of this line moves out of the p tag--><p>a</p>
-<p>b<!--the newline at the end of this line stays inside the p tag--> <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
-<span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></span></p>
+<p>b<!--the newline at the end of this line stays inside the p tag--> <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup>
+<sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></sup></p>
<p>c</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text"></span></li>
<li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text"></span></li></ol>
!! end
@@ -834,9 +882,9 @@ Ref: 13. ref-tags are not SOL-transparent and block indent-pres
</ref> B
<references />
!! html/parsoid
-<p><span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> A
-<span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></span> B</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
+<p><sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup> A
+<sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[2]</span></a></sup> B</p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
<li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar
</span></li>
@@ -853,9 +901,9 @@ parsoid=wt2html
<references />
!! html/parsoid
-<p><span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span> baz&lt;/ref></p>
+<p><sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup> baz&lt;/ref></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo &lt;ref>bar</span></li></ol>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text" data-parsoid="{}">foo &lt;ref>bar</span></li></ol>
!! end
!! test
@@ -866,10 +914,10 @@ B1 <ref name="b" /> B2 <ref name="b">bar</ref>
<references />
!! html/parsoid
-<p>A1 <span about="#mwt3" class="mw-ref" id="cite_ref-a_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a-1"},"attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></span> A2 <span about="#mwt4" class="mw-ref" id="cite_ref-a_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></span>
-B1 <span about="#mwt7" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></span> B2 <span about="#mwt8" class="mw-ref" id="cite_ref-b_2-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-b-2"},"attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></span></p>
+<p>A1 <sup about="#mwt3" class="mw-ref" id="cite_ref-a_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a-1"},"attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></sup> A2 <sup about="#mwt4" class="mw-ref" id="cite_ref-a_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B1 <sup about="#mwt7" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></sup> B2 <sup about="#mwt8" class="mw-ref" id="cite_ref-b_2-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-b-2"},"attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-a_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-a_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-a-1" class="mw-reference-text">foo</span></li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-b_2-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-b_2-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">bar</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a-1" id="cite_note-a-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-a_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-a_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-a-1" class="mw-reference-text">foo</span></li><li about="#cite_note-b-2" id="cite_note-b-2"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-b_2-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-b_2-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">bar</span></li>
</ol>
!! end
@@ -883,8 +931,8 @@ A <ref >foo</ref >
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li></ol>
!! end
@@ -896,39 +944,63 @@ Ref: 17. Generate valid HTML5 id/about attributes
<references />
!! html/parsoid
-<p><span about="#mwt2" class="mw-ref" id="cite_ref-a_b_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a_b-1"},"attrs":{"name":"a b"}}'><a href="./Main_Page#cite_note-a_b-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span>
-<span about="#mwt4" class="mw-ref" id="cite_ref-:0_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-:0-2"},"attrs":{"name":":0"}}'><a href="./Main_Page#cite_note-:0-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></span>
+<p><sup about="#mwt2" class="mw-ref" id="cite_ref-a_b_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a_b-1"},"attrs":{"name":"a b"}}'><a href="./Main_Page#cite_note-a_b-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup>
+<sup about="#mwt4" class="mw-ref" id="cite_ref-:0_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-:0-2"},"attrs":{"name":":0"}}'><a href="./Main_Page#cite_note-:0-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a_b-1" id="cite_note-a_b-1"><a href="./Main_Page#cite_ref-a_b_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-a_b-1" class="mw-reference-text">foo</span></li><li about="#cite_note-:0-2" id="cite_note-:0-2"><a href="./Main_Page#cite_ref-:0_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-:0-2" class="mw-reference-text">ve-created name</span></li></ol>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-a_b-1" id="cite_note-a_b-1"><a href="./Main_Page#cite_ref-a_b_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-a_b-1" class="mw-reference-text">foo</span></li><li about="#cite_note-:0-2" id="cite_note-:0-2"><a href="./Main_Page#cite_ref-:0_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-:0-2" class="mw-reference-text">ve-created name</span></li></ol>
!! end
!! test
Ref: 18. T58916: Extension attributes should be parsed as plain text
+!! config
+wgFragmentMode=[ 'html5', 'legacy' ]
!! wikitext
<ref name="{{echo|a}}">foo</ref>
<references />
+!! html/php
+<p><sup id="cite_ref-&#123;&#123;echo&#124;a&#125;&#125;_1-0" class="reference"><a href="#cite_note-{{echo|a}}-1">&#91;1&#93;</a></sup>
+</p>
+<div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-&#123;&#123;echo&#124;a&#125;&#125;-1"><span class="mw-cite-backlink"><a href="#cite_ref-{{echo|a}}_1-0">↑</a></span> <span class="reference-text">foo</span>
+</li>
+</ol></div>
+
!! html/parsoid
-<p><span class="mw-ref" id="cite_ref-.7B.7Becho.7Ca.7D.7D_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-.7B.7Becho.7Ca.7D.7D-1"},"attrs":{"name":"{{echo|a}}"}}'><a href="./Main_Page#cite_note-.7B.7Becho.7Ca.7D.7D-1"><span class="mw-reflink-text">[1]</span></a></span>
+<p><sup class="mw-ref" id="cite_ref-{{echo|a}}_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-{{echo|a}}-1"},"attrs":{"name":"{{echo|a}}"}}'><a href="./Main_Page#cite_note-{{echo|a}}-1"><span class="mw-reflink-text">[1]</span></a></sup>
</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
-<li about="#cite_note-.7B.7Becho.7Ca.7D.7D-1" id="cite_note-.7B.7Becho.7Ca.7D.7D-1"><a href="./Main_Page#cite_ref-.7B.7Becho.7Ca.7D.7D_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-.7B.7Becho.7Ca.7D.7D-1" class="mw-reference-text">foo</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<li about="#cite_ref-{{echo|a}}_1-1" id="cite_note-{{echo|a}}-1"><a href="./Main_Page#cite_ref-{{echo|a}}_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-{{echo|a}}-1" class="mw-reference-text">foo</span></li>
</ol>
!! end
+# Parsoid doesn't wt2wt this cleanly because we serialize both
+# versions of the name the same way ("a & b")
!! test
Ref: 19. ref-tags with identical name encodings should get identical indexes
+!! config
+wgFragmentMode=[ 'html5', 'legacy' ]
+!! options
+parsoid=wt2html,html2html
!! wikitext
1 <ref name="a & b">foo</ref> 2 <ref name="a &amp; b" />
<references />
+!! html/php
+<p>1 <sup id="cite_ref-a_&amp;_b_1-0" class="reference"><a href="#cite_note-a_&amp;_b-1">&#91;1&#93;</a></sup> 2 <sup id="cite_ref-a_&amp;_b_1-1" class="reference"><a href="#cite_note-a_&amp;_b-1">&#91;1&#93;</a></sup>
+</p>
+<div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-a_&amp;_b-1"><span class="mw-cite-backlink">↑ <sup><a href="#cite_ref-a_&amp;_b_1-0">1.0</a></sup> <sup><a href="#cite_ref-a_&amp;_b_1-1">1.1</a></sup></span> <span class="reference-text">foo</span>
+</li>
+</ol></div>
+
!! html/parsoid
-<p>1 <span about="#mwt3" class="mw-ref" id="cite_ref-a_.26_b_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a_.26_b-1"},"attrs":{"name":"a &amp; b"}}'><a href="./Main_Page#cite_note-a_.26_b-1"><span class="mw-reflink-text">[1]</span></a></span> 2 <span about="#mwt4" class="mw-ref" id="cite_ref-a_.26_b_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a &amp;amp; b"}}'><a href="./Main_Page#cite_note-a_.26_b-1"><span class="mw-reflink-text">[1]</span></a></span>
+<p>1 <sup about="#mwt3" class="mw-ref" id="cite_ref-a_&amp;_b_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-a_&amp;_b-1"},"attrs":{"name":"a &amp; b"}}'><a href="./Main_Page#cite_note-a_&amp;_b-1"><span class="mw-reflink-text">[1]</span></a></sup> 2 <sup about="#mwt4" class="mw-ref" id="cite_ref-a_&amp;_b_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a &amp; b"}}'><a href="./Main_Page#cite_note-a_&amp;_b-1"><span class="mw-reflink-text">[1]</span></a></sup>
</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
-<li about="#cite_note-a_.26_b-1" id="cite_note-a_.26_b-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-a_.26_b_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-a_.26_b_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-a_.26_b-1" class="mw-reference-text">foo</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
+<li about="cite_note-a_&amp;_b-1" id="cite_note-a_&amp;_b-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-a_&amp;_b_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-a_&amp;_b_1-1"><span class="mw-linkback-text">2 </span></a></span> <span id="mw-reference-text-cite_note-a_&amp;_b-1" class="mw-reference-text">foo</span></li>
</ol>
!! end
@@ -941,11 +1013,11 @@ C <ref name="foo" />
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-foo_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-foo-1"},"attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-foo_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"Foo two"},"attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></span>
-C <span about="#mwt6" class="mw-ref" id="cite_ref-foo_1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-foo_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-foo-1"},"attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-foo_1-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"html":"Foo two"},"attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></sup>
+C <sup about="#mwt6" class="mw-ref" id="cite_ref-foo_1-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"foo"}}'><a href="./Main_Page#cite_note-foo-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-foo-1" id="cite_note-foo-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-foo_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-foo_1-1"><span class="mw-linkback-text">2 </span></a><a href="./Main_Page#cite_ref-foo_1-2"><span class="mw-linkback-text">3 </span></a></span> <span id="mw-reference-text-cite_note-foo-1" class="mw-reference-text">Foo one</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-foo-1" id="cite_note-foo-1"><span rel="mw:referencedBy"><a href="./Main_Page#cite_ref-foo_1-0"><span class="mw-linkback-text">1 </span></a><a href="./Main_Page#cite_ref-foo_1-1"><span class="mw-linkback-text">2 </span></a><a href="./Main_Page#cite_ref-foo_1-2"><span class="mw-linkback-text">3 </span></a></span> <span id="mw-reference-text-cite_note-foo-1" class="mw-reference-text">Foo one</span></li>
</ol>
!! end
@@ -954,7 +1026,7 @@ References: 1. references tag without any refs should be handled properly
!! wikitext
<references />
!! html/parsoid
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
!! end
!! test
@@ -968,17 +1040,17 @@ C <ref>baz</ref>
<references />
<references group="b" />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"a"}}'><a href="./Main_Page#cite_note-1" data-mw-group="a"><span class="mw-reflink-text">[a 1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{"group":"b"}}'><a href="./Main_Page#cite_note-2" data-mw-group="b"><span class="mw-reflink-text">[b 1]</span></a></span>
-C <span class="mw-ref" id="cite_ref-3" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-3"},"attrs":{}}'><a href="./Main_Page#cite_note-3"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"a"}}'><a href="./Main_Page#cite_note-1" data-mw-group="a"><span class="mw-reflink-text">[a 1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{"group":"b"}}'><a href="./Main_Page#cite_note-2" data-mw-group="b"><span class="mw-reflink-text">[b 1]</span></a></sup>
+C <sup class="mw-ref" id="cite_ref-3" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-3"},"attrs":{}}'><a href="./Main_Page#cite_note-3"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw-group="a" data-mw='{"name":"references","attrs":{"group":"a"}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt8" data-mw-group="a" data-mw='{"name":"references","attrs":{"group":"a"}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" data-mw-group="a" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
</ol>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-3" id="cite_note-3"><a href="./Main_Page#cite_ref-3" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-3" class="mw-reference-text">baz</span></li>
</ol>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt12" data-mw-group="b" data-mw='{"name":"references","attrs":{"group":"b"}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt12" data-mw-group="b" data-mw='{"name":"references","attrs":{"group":"b"}}'>
<li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" data-mw-group="b" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
</ol>
!! end
@@ -994,14 +1066,14 @@ B <ref>bar</ref>
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
</ol>
-<p>B <span about="#mwt6" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>B <sup about="#mwt6" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt8" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
</ol>
!! end
@@ -1018,15 +1090,15 @@ C <ref>cfoo</ref>
<references />
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"a"}}'><a href="./Main_Page#cite_note-1" data-mw-group="a"><span class="mw-reflink-text">[a 1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{"group":"a"}}'><a href="./Main_Page#cite_note-1" data-mw-group="a"><span class="mw-reflink-text">[a 1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2"><span class="mw-reflink-text">[1]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw-group="a" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" data-mw-group="a" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">afoo</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw-group="a" data-mw='{"name":"references","attrs":{"group":"a"}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" data-mw-group="a" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">afoo</span></li>
</ol>
-<p>C <span about="#mwt8" class="mw-ref" id="cite_ref-3" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-3"},"attrs":{}}'><a href="./Main_Page#cite_note-3"><span class="mw-reflink-text">[2]</span></a></span></p>
+<p>C <sup about="#mwt8" class="mw-ref" id="cite_ref-3" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-3"},"attrs":{}}'><a href="./Main_Page#cite_note-3"><span class="mw-reflink-text">[2]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bfoo</span></li><li about="#cite_note-3" id="cite_note-3"><a href="./Main_Page#cite_ref-3" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-3" class="mw-reference-text">cfoo</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt10" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bfoo</span></li><li about="#cite_note-3" id="cite_note-3"><a href="./Main_Page#cite_ref-3" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-3" class="mw-reference-text">cfoo</span></li>
</ol>
!! end
@@ -1044,11 +1116,11 @@ B <ref name="b">bar</ref>
This should just get lost.
</references>
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-a_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-b-2"},"attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></span></p>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-a_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"name":"a"}}'><a href="./Main_Page#cite_note-a-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-b-2"},"attrs":{"name":"b"}}'><a href="./Main_Page#cite_note-b-2"><span class="mw-reflink-text">[2]</span></a></sup></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{},"body":{"html":"\n&lt;span about=\"#mwt8\" class=\"mw-ref\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid=&#39;{\"dsr\":[59,82,14,6]}&#39; data-mw=&#39;{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-a-1\"},\"attrs\":{\"name\":\"a\"}}&#39;>&lt;a href=\"./Main_Page#cite_note-a-1\" style=\"counter-reset: mw-Ref 1;\" data-parsoid=\"{}\">&lt;span class=\"mw-reflink-text\" data-parsoid=\"{}\">[1]&lt;/span>&lt;/a>&lt;/span>\n"}}'><li about="#cite_note-a-1" id="cite_note-a-1"><a href="./Main_Page#cite_ref-a_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-a-1" class="mw-reference-text">foo</span></li><li about="#cite_note-b-2" id="cite_note-b-2"><a href="./Main_Page#cite_ref-b_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">bar</span></li>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{},"body":{"html":"\n&lt;sup about=\"#mwt8\" class=\"mw-ref\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid=&#39;{\"dsr\":[59,82,14,6]}&#39; data-mw=&#39;{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-a-1\"},\"attrs\":{\"name\":\"a\"}}&#39;>&lt;a href=\"./Main_Page#cite_note-a-1\" style=\"counter-reset: mw-Ref 1;\" data-parsoid=\"{}\">&lt;span class=\"mw-reflink-text\" data-parsoid=\"{}\">[1]&lt;/span>&lt;/a>&lt;/sup>\n"}}'><li about="#cite_note-a-1" id="cite_note-a-1"><a href="./Main_Page#cite_ref-a_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-a-1" class="mw-reference-text">foo</span></li><li about="#cite_note-b-2" id="cite_note-b-2"><a href="./Main_Page#cite_ref-b_2-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">bar</span></li>
</ol>
!! end
@@ -1057,7 +1129,7 @@ References: 6. <references /> from a transclusion
!! wikitext
<ref>Foo</ref> {{echo|<references />}}
!! html/parsoid
-<p><span about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p> <ol class="mw-references" typeof="mw:Extension/references mw:Transclusion" about="#mwt4" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&lt;references />"}},"i":0}}]}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">Foo</span></li>
+<p><sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup></p> <ol class="mw-references references" typeof="mw:Extension/references mw:Transclusion" about="#mwt4" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&lt;references />"}},"i":0}}]}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">Foo</span></li>
</ol>
!! end
@@ -1073,15 +1145,15 @@ B <ref group="X" name="b" />
<ref name="b">foo</ref>
</references>
!! html/parsoid
-<p>A <span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span>
-B <span about="#mwt4" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}'><a href="./Main_Page#cite_note-b-2" data-mw-group="X"><span class="mw-reflink-text">[X 1]</span></a></span>
+<p>A <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup>
+B <sup about="#mwt4" class="mw-ref" id="cite_ref-b_2-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","attrs":{"group":"X","name":"b"}}'><a href="./Main_Page#cite_note-b-2" data-mw-group="X"><span class="mw-reflink-text">[X 1]</span></a></sup>
</p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo bar for a</span></li>
</ol>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt8" data-mw-group="X" data-mw='{"name":"references","attrs":{"group":"X"},"body":{"html":"\n&lt;span about=\"#mwt10\" class=\"mw-ref\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid=&#39;{\"dsr\":[96,119,14,6]}&#39; data-mw=&#39;{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-b-2\"},\"attrs\":{\"name\":\"b\"}}&#39;>&lt;a href=\"./Main_Page#cite_note-b-2\" style=\"counter-reset: mw-Ref 1;\" data-mw-group=\"X\" data-parsoid=\"{}\">&lt;span class=\"mw-reflink-text\" data-parsoid=\"{}\">[X 1]&lt;/span>&lt;/a>&lt;/span>\n"}}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt8" data-mw-group="X" data-mw='{"name":"references","attrs":{"group":"X"},"body":{"html":"\n&lt;sup about=\"#mwt10\" class=\"mw-ref\" rel=\"dc:references\" typeof=\"mw:Extension/ref\" data-parsoid=&#39;{\"dsr\":[96,119,14,6]}&#39; data-mw=&#39;{\"name\":\"ref\",\"body\":{\"id\":\"mw-reference-text-cite_note-b-2\"},\"attrs\":{\"name\":\"b\"}}&#39;>&lt;a href=\"./Main_Page#cite_note-b-2\" style=\"counter-reset: mw-Ref 1;\" data-mw-group=\"X\" data-parsoid=\"{}\">&lt;span class=\"mw-reflink-text\" data-parsoid=\"{}\">[X 1]&lt;/span>&lt;/a>&lt;/sup>\n"}}'>
<li about="#cite_note-b-2" id="cite_note-b-2"><a href="./Main_Page#cite_ref-b_2-0" data-mw-group="X" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-b-2" class="mw-reference-text">foo</span></li>
</ol>
!! end
@@ -1092,32 +1164,28 @@ References: 8. T88019: Remove <meta>s from templates inside <ref> that's itself
X{{echo|<ref>foo {{echo|<b>bar</b>}} and {{echo|baz}} boo</ref>}}
<references />
!! html/parsoid
-<p>X<span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&lt;ref>foo {{echo|&lt;b>bar&lt;/b>}} and {{echo|baz}} boo&lt;/ref>"}},"i":0}}]}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt7" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo <b data-parsoid='{"stx":"html"}'>bar</b> and baz boo</span></li>
+<p>X<sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Transclusion mw:Extension/ref" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"&lt;ref>foo {{echo|&lt;b>bar&lt;/b>}} and {{echo|baz}} boo&lt;/ref>"}},"i":0}}]}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt7" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo <b data-parsoid='{"stx":"html"}'>bar</b> and baz boo</span></li>
</ol>
!! end
-# This test only works in wt2html now as the <references /> are always generated
-# unless selser is active. Once T72722 is fixed, we should add a changes test
-# here to ensure that unrelated changes don't add the new <references />
-# when selser is active.
!! test
References: 9. Generate missing references list at the end
!! wikitext
A <ref>foo</ref>
B <ref group="inexistent">bar</ref>
!! html/parsoid
-<p>A <span class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></span> B <span class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{"group":"inexistent"}}'><a href="./Main_Page#cite_note-2" data-mw-group="inexistent"><span class="mw-reflink-text">[inexistent 1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'>
+<p>A <sup class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1"><span class="mw-reflink-text">[1]</span></a></sup> B <sup class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{"group":"inexistent"}}'><a href="./Main_Page#cite_note-2" data-mw-group="inexistent"><span class="mw-reflink-text">[inexistent 1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'>
<li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li>
</ol>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt6" data-mw-group="inexistent" data-mw='{"name":"references","attrs":{"group":"inexistent"},"autoGenerated":true}'>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw-group="inexistent" data-mw='{"name":"references","attrs":{"group":"inexistent"},"autoGenerated":true}'>
<li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" data-mw-group="inexistent" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">bar</span></li>
</ol>
!! end
!! test
-References: 10. New <references/> shouldn't be added for unrelated edits.
+References: 10.1. New <references/> shouldn't be added for unrelated edits.
!! options
parsoid={
"modes": ["selser"],
@@ -1133,14 +1201,44 @@ A <ref>foo</ref>
!! end
!! test
+References: 10.2. New <references/> shouldn't be added for unrelated edits.
+!! options
+parsoid={
+ "modes": ["selser"],
+ "changes": [["#x", "remove"]],
+ "selser": "noauto",
+ "responsiveReferences": { "enabled": true, "threshold": 2 }
+}
+!! wikitext
+Unrelated text<span id="x"> that's going to disappear</span>.
+A <ref>foo</ref>
+!! wikitext/edited
+Unrelated text.
+A <ref>foo</ref>
+!! end
+
+# Doesn't wt2wt cleanly because we don't encode the &amp; in html2wt direction
+!! test
Entities in ref name
+!! config
+wgFragmentMode=[ 'html5', 'legacy' ]
+!! options
+parsoid=wt2html,html2html
!! wikitext
-<ref name="test &amp; me">hi</ref>
+<ref name="test &amp; me {{echo|foo}}">hi</ref>
<references />
+!! html/php
+<p><sup id="cite_ref-test_&amp;_me_&#123;&#123;echo&#124;foo&#125;&#125;_1-0" class="reference"><a href="#cite_note-test_&amp;_me_{{echo|foo}}-1">&#91;1&#93;</a></sup>
+</p>
+<div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-test_&amp;_me_&#123;&#123;echo&#124;foo&#125;&#125;-1"><span class="mw-cite-backlink"><a href="#cite_ref-test_&amp;_me_{{echo|foo}}_1-0">↑</a></span> <span class="reference-text">hi</span>
+</li>
+</ol></div>
+
!! html/parsoid
-<p><span about="#mwt2" class="mw-ref" id="cite_ref-test_.26_me_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-test_.26_me-1"},"attrs":{"name":"test &amp;amp; me"}}'><a href="./Main_Page#cite_note-test_.26_me-1"><span class="mw-reflink-text">[1]</span></a></span></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
-<li about="#cite_note-test_.26_me-1" id="cite_note-test_.26_me-1"><a href="./Main_Page#cite_ref-test_.26_me_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-test_.26_me-1" class="mw-reference-text">hi</span></li>
+<p><sup about="#mwt2" class="mw-ref" id="cite_ref-test_&amp;_me_{{echo|foo}}_1-0" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-test_&amp;_me_{{echo|foo}}-1"},"attrs":{"name":"test &amp; me {{echo|foo}}"}}'><a href="./Main_Page#cite_note-test_&amp;_me_{{echo|foo}}-1"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'>
+<li about="#cite_note-test_&amp;_me_{{echo|foo}}-1" id="cite_note-test_&amp;_me_{{echo|foo}}-1"><a href="./Main_Page#cite_ref-test_&amp;_me_{{echo|foo}}_1-0" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-test_&amp;_me_{{echo|foo}}-1" class="mw-reference-text">hi</span></li>
</ol>
!! end
@@ -1158,10 +1256,10 @@ a<ref>foo</ref>
<references>
!! html/parsoid
-<p>a<span about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></span></p>
+<p>a<sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>
<p>&lt;references></p>
-<ol class="mw-references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li></ol>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt3" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">foo</span></li></ol>
!! end
!! test
@@ -1172,5 +1270,195 @@ parsoid=wt2wt,html2wt
foo
<references />
!! html/parsoid
-foo<ol class="mw-references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
+foo<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>
+!! end
+
+!! test
+Ref in ref
+!! wikitext
+test <ref>hi {{refinref}}</ref>
+<references />
+!! html/php
+<p>test <sup id="cite_ref-1" class="reference"><a href="#cite_note-1">&#91;1&#93;</a></sup>
+</p>
+<div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1">↑</a></span> <span class="reference-text">hi </span>
+</li>
+</ol></div>
+<p><span class="error mw-ext-cite-error" lang="en" dir="ltr">Cite error: <code>&lt;ref&gt;</code> tag defined in <code>&lt;references&gt;</code> has no name attribute.</span>
+</p>
+!! html/parsoid
+<p>test <sup about="#mwt4" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">hi <span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"refinref","href":"./Template:Refinref"},"params":{},"i":0}}]}'></span></span></li></ol>
+!! end
+
+## Parsoid responsive references tests
+
+!! test
+Responsive references: disabled, autogenerated
+!! options
+parsoid={
+ "modes": ["wt2html"],
+ "responsiveReferences": { "enabled": false, "threshold": 2 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol>
+!! end
+
+!! test
+Responsive references: enabled, autogenerated
+!! options
+parsoid={
+ "modes": ["wt2html"],
+ "responsiveReferences": { "enabled": true, "threshold": 2 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<div class="mw-references-wrap" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol></div>
+!! end
+
+!! test
+Responsive references: enabled, autogenerated, exceed
+!! options
+parsoid={
+ "modes": ["wt2html"],
+ "responsiveReferences": { "enabled": true, "threshold": 1 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<div class="mw-references-wrap mw-references-columns" typeof="mw:Extension/references" about="#mwt5" data-mw='{"name":"references","attrs":{},"autoGenerated":true}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol></div>
+!! end
+
+!! test
+Responsive references: disabled
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": false, "threshold": 2 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+<references />
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol>
+!! end
+
+!! test
+Responsive references: enabled
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": true, "threshold": 2 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+<references />
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<div class="mw-references-wrap" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol></div>
+!! end
+
+!! test
+Responsive references: enabled, exceed
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": true, "threshold": 1 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+<references />
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<div class="mw-references-wrap mw-references-columns" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol></div>
+!! end
+
+!! test
+Responsive references: disabled, explicit
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": false, "threshold": 2 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+<references responsive="" />
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<div class="mw-references-wrap" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{"responsive":""}}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol></div>
+!! end
+
+!! test
+Responsive references: disabled, explicit, exceed
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": false, "threshold": 1 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+<references responsive="" />
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<div class="mw-references-wrap mw-references-columns" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{"responsive":""}}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol></div>
+!! end
+
+!! test
+Responsive references: enabled, explicit off
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": true, "threshold": 2 }
+}
+!! wikitext
+Test <ref>1</ref><ref>2</ref>
+<references responsive="0" />
+!! html/parsoid
+<p>Test <sup about="#mwt3" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup><sup about="#mwt4" class="mw-ref" id="cite_ref-2" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-2"},"attrs":{}}'><a href="./Main_Page#cite_note-2" style="counter-reset: mw-Ref 2;"><span class="mw-reflink-text">[2]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{"responsive":"0"}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">1</span></li><li about="#cite_note-2" id="cite_note-2"><a href="./Main_Page#cite_ref-2" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-2" class="mw-reference-text">2</span></li></ol>
+!! end
+
+!! test
+Responsive references: roundtrip templates
+!! options
+parsoid={
+ "responsiveReferences": { "enabled": true, "threshold": 2 }
+}
+!! wikitext
+test <ref>123</ref>
+
+{{echo|haha<references/>}}
+!! html/parsoid
+<p>test <sup about="#mwt2" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>
+
+<p about="#mwt4" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"echo","href":"./Template:Echo"},"params":{"1":{"wt":"haha&lt;references/>"}},"i":0}}]}'>haha</p><div class="mw-references-wrap" typeof="mw:Extension/references" about="#mwt4" data-mw='{"name":"references","attrs":{}}'><ol class="mw-references references"><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">123</span></li></ol></div>
+!! end
+
+## End Parsoid responsive references tests
+
+!! article
+Template:CircularRef
+!! text
+<ref>Hi {{CircularRef}}</ref>
+!! endarticle
+
+!! test
+CircularRef
+!! wikitext
+<ref>Hi {{CircularRef}}</ref>
+<references />
+!! html/php
+<p><sup id="cite_ref-1" class="reference"><a href="#cite_note-1">&#91;1&#93;</a></sup>
+</p>
+<div class="mw-references-wrap"><ol class="references">
+<li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1">↑</a></span> <span class="reference-text">Hi </span>
+</li>
+</ol></div>
+<p><span class="error mw-ext-cite-error" lang="en" dir="ltr">Cite error: <code>&lt;ref&gt;</code> tag defined in <code>&lt;references&gt;</code> has no name attribute.</span>
+</p>
+!! html/parsoid
+<p><sup about="#mwt4" class="mw-ref" id="cite_ref-1" rel="dc:references" typeof="mw:Extension/ref" data-mw='{"name":"ref","body":{"id":"mw-reference-text-cite_note-1"},"attrs":{}}'><a href="./Main_Page#cite_note-1" style="counter-reset: mw-Ref 1;"><span class="mw-reflink-text">[1]</span></a></sup></p>
+<ol class="mw-references references" typeof="mw:Extension/references" about="#mwt6" data-mw='{"name":"references","attrs":{}}'><li about="#cite_note-1" id="cite_note-1"><a href="./Main_Page#cite_ref-1" rel="mw:referencedBy"><span class="mw-linkback-text">↑ </span></a> <span id="mw-reference-text-cite_note-1" class="mw-reference-text">Hi <span about="#mwt2" typeof="mw:Transclusion" data-mw='{"parts":[{"template":{"target":{"wt":"CircularRef","href":"./Template:CircularRef"},"params":{},"i":0}}]}'></span></span></li></ol>
!! end
diff --git a/www/wiki/extensions/Cite/tests/phan/config.php b/www/wiki/extensions/Cite/tests/phan/config.php
new file mode 100644
index 00000000..49ddcba9
--- /dev/null
+++ b/www/wiki/extensions/Cite/tests/phan/config.php
@@ -0,0 +1,7 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+// Due to creation of Parser::$extCite property
+$cfg['suppress_issue_types'][] = 'PhanUndeclaredProperty';
+
+return $cfg;
diff --git a/www/wiki/extensions/CiteThisPage/composer.json b/www/wiki/extensions/CiteThisPage/composer.json
index 9dc2960d..ea278e4a 100644
--- a/www/wiki/extensions/CiteThisPage/composer.json
+++ b/www/wiki/extensions/CiteThisPage/composer.json
@@ -1,16 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
],
"fix": [
- "phpcbf"
+ "phpcbf",
+ "minus-x fix ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/CiteThisPage/extension.json b/www/wiki/extensions/CiteThisPage/extension.json
index 3f9bbd39..42b6f939 100644
--- a/www/wiki/extensions/CiteThisPage/extension.json
+++ b/www/wiki/extensions/CiteThisPage/extension.json
@@ -6,8 +6,11 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:CiteThisPage",
"descriptionmsg": "citethispage-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "specialpage",
+ "requires": {
+ "MediaWiki": ">= 1.30.0"
+ },
"ExtensionMessagesFiles": {
"CiteThisPageAliases": "CiteThisPage.alias.php"
},
@@ -24,7 +27,6 @@
},
"ResourceModules": {
"ext.citeThisPage": {
- "position": "top",
"styles": "ext.citeThisPage.css"
}
},
@@ -36,8 +38,8 @@
"CiteThisPage": "SpecialCiteThisPage"
},
"AutoloadClasses": {
- "SpecialCiteThisPage": "SpecialCiteThisPage.php",
- "CiteThisPageHooks": "CiteThisPage.hooks.php"
+ "SpecialCiteThisPage": "includes/SpecialCiteThisPage.php",
+ "CiteThisPageHooks": "includes/CiteThisPageHooks.php"
},
"config": {
"CiteThisPageAdditionalNamespaces": {
diff --git a/www/wiki/extensions/CiteThisPage/i18n/ce.json b/www/wiki/extensions/CiteThisPage/i18n/ce.json
index beceafa8..eb2e186f 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/ce.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/ce.json
@@ -11,5 +11,5 @@
"tooltip-citethispage": "ХӀара бу хаам агӀонах лаьцна дешнаш муха дало деза гойтуш",
"citethispage-change-submit": "Кечъе хьажоргаш",
"citethispage-change-target": "АгӀо:",
- "citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== {{FULLPAGENAME}} агӀона библиографин хаамаш ==\n\n* Яззам: {{FULLPAGENAME}}\n* Автор: {{SITENAME}} автораш\n* Кхоьллина: ''{{SITENAME}}, {{int:sitesubtitle}}''.\n* ТӀаьххьара хийцам бина: {{CURRENTYEAR}} шаран {{CURRENTDAY}} {{CURRENTMONTHNAMEGEN}} {{CURRENTTIME}} UTC\n* Чуяьккхина терахь: <citation>{{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTTIME}} UTC</citation>\n* Даиман йолу хьажорг: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* АгӀон версийн ID: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== «{{FULLPAGENAME}}» агӀона тӀе йолу хьажоргаш кечяран кепаш ==\n\n=== [http://protect.gost.ru/document.aspx?control=7&id=173511 ГОСТ 7.0.5—2008] хатӀ (библиографин хьажорг) ===\n{{FULLPAGENAME}} // {{SITENAME}}. [{{REVISIONYEAR}}—{{REVISIONYEAR}}]. Карлаяьккхина терахь: {{#time:Y.m.d|{{REVISIONTIMESTAMP}}}}. URL: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (дехар дина терахь: {{#time:Y.m.d|{{LOCALTIMESTAMP}}}}).\n<div style=\"font-size:smaller; padding-left:2.5em\">\n\n</div>\n\n=== [[ГОСТ 7.1|ГОСТ 7.1—2003]] а, [[ГОСТ 7.82|ГОСТ 7.82—2001]] а хатӀ (доца библиографин дӀаяздар) ===\n{{FULLPAGENAME}} [Электронан ресурс] : {{int:Tagline}} : Верси {{REVISIONID}}, Ӏалашйина {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAMEGEN}} UTC {{CURRENTTIME}} / Википедин автораш // {{SITENAME}}, {{int:sitesubtitle}}. — Электрон. дан. — Сан-Франциско: Викимедиан фонд, {{CURRENTYEAR}}. — ТӀекхачаран хьал: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n\n=== [[APA style|ХатӀ APA]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHNAME}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. Retrieved <citation> {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTTIME}}</citation> from {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[The MLA style manual|ХатӀ MLA]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHABBREV}}, {{CURRENTTIME}} UTC. <citation>{{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHABBREV}}, {{CURRENTTIME}}</citation> &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|ХатӀ MHRA]] ===\n{{SITENAME}} contributors, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTTIME}} UTC, &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [accessed <citation> {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}}</citation>]\n\n=== [[The Chicago Manual of Style|Чикаган хатӀ]] ===\n{{SITENAME}} contributors, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (accessed <citation>{{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}}</citation>).\n\n=== [[Council of Science Editors|ХатӀ CBE/CSE]] ===\n{{SITENAME}} contributors. {{FULLPAGENAME}} [Internet]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHABBREV}}, {{CURRENTTIME}} UTC [cited <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]. Available from: \n{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebook style]] ===\n{{FULLPAGENAME}}, {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (last visited <citation> {{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHNAME}}</citation>).\n\n=== [[BibTeX]] чура дӀаяздар ===\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Online; accessed <citation>{{CURRENTYEAR}}-{{CURRENTDAY}}-{{CURRENTMONTHNAME}}</citation>]\"\n }\n\n[[LaTeX]]-гулам лела беш url веб-адресаш дика гайта (<code>\\usepackage{url}</code>), лелайича дика хира ду:\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Online; accessed <citation>{{CURRENTYEAR}}-{{CURRENTDAY}}-{{CURRENTMONTHNAME}}</citation>]\"\n }\n\n</div> <!--closing div for \"plainlinks\"-->"
+ "citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== {{FULLPAGENAME}} агӀона библиографин хаамаш ==\n\n* Яззам: {{FULLPAGENAME}}\n* Автор: {{SITENAME}} автораш\n* Кхоьллина: ''{{SITENAME}}, {{int:sitesubtitle}}''.\n* ТӀаьххьара хийцам бина: {{CURRENTYEAR}} шаран {{CURRENTDAY}} {{CURRENTMONTHNAMEGEN}} {{CURRENTTIME}} UTC\n* Чуяьккхина терахь: <citation>{{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTTIME}} UTC</citation>\n* Цахийцалун хьажорг: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* АгӀон версийн ID: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== «{{FULLPAGENAME}}» агӀона тӀе йолу хьажоргаш кечъяран кепаш ==\n\n=== [http://protect.gost.ru/document.aspx?control=7&id=173511 ГОСТ 7.0.5—2008] хатӀ (библиографин хьажорг) ===\n{{FULLPAGENAME}} // {{SITENAME}}. [{{REVISIONYEAR}}—{{REVISIONYEAR}}]. Карлаяьккхина терахь: {{#time:Y.m.d|{{REVISIONTIMESTAMP}}}}. URL: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (дехар дина терахь: {{#time:Y.m.d|{{LOCALTIMESTAMP}}}}).\n<div style=\"font-size:smaller; padding-left:2.5em\">\n\n</div>\n\n=== [[ГОСТ 7.1|ГОСТ 7.1—2003]] а, [[ГОСТ 7.82|ГОСТ 7.82—2001]] а хатӀ (доца библиографин дӀаяздар) ===\n{{FULLPAGENAME}} [Электронан ресурс] : {{int:Tagline}} : Верси {{REVISIONID}}, Ӏалашйина {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAMEGEN}} UTC {{CURRENTTIME}} / Википедин автораш // {{SITENAME}}, {{int:sitesubtitle}}. — Электрон. дан. — Сан-Франциско: Викимедиан фонд, {{CURRENTYEAR}}. — ТӀекхачаран хьал: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n\n=== [[APA style|ХатӀ APA]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHNAME}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. Retrieved <citation> {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTTIME}}</citation> from {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[The MLA style manual|ХатӀ MLA]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHABBREV}}, {{CURRENTTIME}} UTC. <citation>{{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHABBREV}}, {{CURRENTTIME}}</citation> &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|ХатӀ MHRA]] ===\n{{SITENAME}} contributors, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTTIME}} UTC, &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [accessed <citation> {{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}}</citation>]\n\n=== [[The Chicago Manual of Style|Чикаган хатӀ]] ===\n{{SITENAME}} contributors, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (accessed <citation>{{CURRENTYEAR}} {{CURRENTDAY}} {{CURRENTMONTHNAME}}</citation>).\n\n=== [[Council of Science Editors|ХатӀ CBE/CSE]] ===\n{{SITENAME}} contributors. {{FULLPAGENAME}} [Internet]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHABBREV}}, {{CURRENTTIME}} UTC [cited <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]. Available from: \n{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebook style]] ===\n{{FULLPAGENAME}}, {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (last visited <citation> {{CURRENTYEAR}}, {{CURRENTDAY}} {{CURRENTMONTHNAME}}</citation>).\n\n=== [[BibTeX]] чура дӀаяздар ===\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Online; accessed <citation>{{CURRENTYEAR}}-{{CURRENTDAY}}-{{CURRENTMONTHNAME}}</citation>]\"\n }\n\n[[LaTeX]]-гулам лела беш url веб-адресаш дика гайта (<code>\\usepackage{url}</code>), лелайича дика хира ду:\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Online; accessed <citation>{{CURRENTYEAR}}-{{CURRENTDAY}}-{{CURRENTMONTHNAME}}</citation>]\"\n }\n\n</div> <!--closing div for \"plainlinks\"-->"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/cv.json b/www/wiki/extensions/CiteThisPage/i18n/cv.json
new file mode 100644
index 00000000..57a19a2e
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/cv.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chavash"
+ ]
+ },
+ "citethispage-link": "Ҫак эле цитатӑла",
+ "tooltip-citethispage": "Ҫак эле мӗнле цитатӑласси"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/es.json b/www/wiki/extensions/CiteThisPage/i18n/es.json
index d2d4b839..74096078 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/es.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/es.json
@@ -13,7 +13,7 @@
]
},
"citethispage": "Citar esta página",
- "citethispage-desc": "Añade una página especial para [[Special:CiteThisPage|citar una página]] y un enlace en la caja de herramientas.",
+ "citethispage-desc": "Añade una página especial para [[Special:CiteThisPage|citar las páginas]] y un enlace en el cuadro de herramientas",
"citethispage-link": "Citar esta página",
"tooltip-citethispage": "Información sobre cómo citar esta página",
"citethispage-change-submit": "Citar",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/frp.json b/www/wiki/extensions/CiteThisPage/i18n/frp.json
index c2e66258..25b684c4 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/frp.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/frp.json
@@ -7,7 +7,7 @@
"citethispage": "Citacion",
"citethispage-desc": "Apond una pâge spèciâla [[Special:Cite|citacion]] et un lim dens la bouèta d’outils.",
"citethispage-link": "Citar cela pâge",
- "tooltip-citethispage": "Enformacions dessus coment citar cela pâge",
+ "tooltip-citethispage": "Enformacions sur la façon de citar cela pâge",
"citethispage-change-submit": "Citar",
"citethispage-change-target": "Pâge :"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/fy.json b/www/wiki/extensions/CiteThisPage/i18n/fy.json
index c358fb47..6814d391 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/fy.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/fy.json
@@ -3,7 +3,8 @@
"authors": [
"SK-luuut",
"Snakesteuben",
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
"citethispage": "Sitearje",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/ga.json b/www/wiki/extensions/CiteThisPage/i18n/ga.json
index 4e6b89d3..6e5cbe34 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/ga.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/ga.json
@@ -2,11 +2,12 @@
"@metadata": {
"authors": [
"Alison",
- "Tem"
+ "Tem",
+ "Nmacu"
]
},
"citethispage": "Luaigh",
- "citethispage-desc": "Cuir [[Special:Cite|deismireacht]] leathanach speisíalta agus nasc bosca uirlisí",
+ "citethispage-desc": "Cuir isteach [[Special:CiteThisPage|deismireacht]] leathanach speisíalta agus nasc bosca uirlisí",
"citethispage-link": "Luaigh an lch seo",
"tooltip-citethispage": "Eolas maidir le conas an leathanach seo a lua",
"citethispage-change-submit": "Luaigh",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/gcr.json b/www/wiki/extensions/CiteThisPage/i18n/gcr.json
new file mode 100644
index 00000000..d61f96e4
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/gcr.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "citethispage-link": "Sité sa paj",
+ "tooltip-citethispage": "Enfòrmasyon asou mannyè di sité sa paj"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/got.json b/www/wiki/extensions/CiteThisPage/i18n/got.json
new file mode 100644
index 00000000..4b536003
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/got.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gothicspeaker"
+ ]
+ },
+ "citethispage-link": "𐌷𐌰𐌹𐍄 𐌸𐌰𐌽𐌰 𐌻𐌰𐌿𐍆",
+ "tooltip-citethispage": "𐌺𐌿𐌽𐌸𐌹 𐌱𐌹 𐍈𐌰𐌹𐍅𐌰 𐌷𐌰𐌹𐍄𐌹𐍃 𐌸𐌰𐌽𐌰 𐌻𐌰𐌿𐍆"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/hoc.json b/www/wiki/extensions/CiteThisPage/i18n/hoc.json
new file mode 100644
index 00000000..dc3a54b5
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/hoc.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Singkiring57"
+ ]
+ },
+ "tooltip-citethispage": "𑢳𑣈𑣓 𑣞𑣌𑣈𑣓 𑣏𑣂𑣚𑣂𑣌𑣈 𑣕𑣉𑣌-𑣇𑣔𑣃𑣗𑣈 𑣜𑣈𑣓𑣄 𑣏𑣂𑣜𑣋𑣈𑣓"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/hy.json b/www/wiki/extensions/CiteThisPage/i18n/hy.json
index 43dbbfb4..79fa09c7 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/hy.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/hy.json
@@ -4,13 +4,14 @@
"Chaojoker",
"Teak",
"Vadgt",
- "Դավիթ Սարոյան"
+ "Դավիթ Սարոյան",
+ "Xelgen"
]
},
- "citethispage": "Քաղվածել այս էջը",
- "citethispage-link": "Քաղվածել այս էջը",
+ "citethispage": "Հոդվածի ծանոթագրություններ",
+ "citethispage-link": "Մեջբերել այս էջը",
"tooltip-citethispage": "Տեղեկատվություն, թե ինչպես պետք է մեջբերել այս էջը",
- "citethispage-change-submit": "Քաղվածել",
+ "citethispage-change-submit": "Հղում դնել",
"citethispage-change-target": "Էջ.",
"citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== {{FULLPAGENAME}} էջի մատենագրական մանրամասներ ==\n\n* Էջանուն՝ {{FULLPAGENAME}}\n* Հեղինակ՝ {{SITENAME}} contributors\n* Հրատարակիչ՝ ''{{SITENAME}}, {{int:sitesubtitle}}''.\n* Վերջինն վերանայման թիվ՝ {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} ՀԿԺ\n* Վերստացման թիվ՝ <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} ՀԿԺ</citation>\n* Մշտական հասցե՝ {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* Էջի վարկածի թիվ՝ {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== {{FULLPAGENAME}} էջի մեջբերման ոճեր ==\n\n=== [[APA style]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}})։ ''{{SITENAME}}, {{int:sitesubtitle}}''։ Վերստացված է՝ <citation>{{CURRENTTIME}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}} թվին՝</citation> {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}-ից։\n\n=== [[The MLA style manual|MLA style]] ===\n\"{{FULLPAGENAME}}։\" ''{{SITENAME}}, {{int:sitesubtitle}}''։ {{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}} ՀԿԺ։ <citation>{{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}}</citation> &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;։\n\n=== [[MHRA Style Guide|MHRA style]] ===\n{{SITENAME}} կայքի ներդնողներ, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}, {{CURRENTTIME}} ՀԿԺ, &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [վերստացված է՝ <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}</citation>]\n\n=== [[The Chicago Manual of Style|Chicago style]] ===\n{{SITENAME}} կայքի ներդնողներ, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (վերստացված է՝ <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>)։\n\n=== [[Council of Science Editors|CBE/CSE style]] ===\n{{SITENAME}} կայքի ներդնողներ։ {{FULLPAGENAME}} [Համացանց]։ {{SITENAME}}, {{int:sitesubtitle}}․ {{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}, {{CURRENTTIME}} ՀԿԺ [մեջբերած՝ <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]։ Հասանելի է՝\n{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}։\n\n=== [[Bluebook|Bluebook style]] ===\n{{FULLPAGENAME}}, {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (վերջին այցելություն՝ <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>)։\n\n=== [[BibTeX]] entry ===\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Առցանց․ վերստացված է՝ <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n[[ԼաՏեԽ]] փաթեթային հասցեն (<code>\\usepackage{url}</code> օգտագործելիս, որը շատ ավելի գեղեցկորեն ոճավորված է ցուցադրում կայքերի հասցեները, կարելի է հետևյալը նախընտրել՝\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Առցանց․ վերստացված է՝ <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n\n</div> <!--closing div for \"plainlinks\"-->"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/ia.json b/www/wiki/extensions/CiteThisPage/i18n/ia.json
index ff4cfabd..cb49ba4b 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/ia.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/ia.json
@@ -5,7 +5,7 @@
"McDutchie"
]
},
- "citethispage": "Citation",
+ "citethispage": "Citar iste pagina",
"citethispage-desc": "Adde un pagina special de [[Special:CiteThisPage|citation]] e un ligamine verso le instrumentario",
"citethispage-link": "Citar iste pagina",
"tooltip-citethispage": "Information sur como citar iste pagina",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/ja.json b/www/wiki/extensions/CiteThisPage/i18n/ja.json
index b0ae4bed..ad22a7e8 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/ja.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/ja.json
@@ -6,7 +6,8 @@
"JtFuruhata",
"Shirayuki",
"Suisui",
- "Whym"
+ "Whym",
+ "Yusuke1109"
]
},
"citethispage": "引用",
@@ -15,5 +16,6 @@
"tooltip-citethispage": "このページの引用方法",
"citethispage-change-submit": "引用",
"citethispage-change-target": "ページ:",
+ "citethispage-badrevision": "エラー:版番号$2のページ「$1」の版が見つかりませんでした。",
"citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== 「{{FULLPAGENAME}}」の書誌情報 ==\n\n* ページ名: {{FULLPAGENAME}}\n* 著者: {{SITENAME}}への寄稿者ら\n* 発行者: {{int:sitesubtitle}}『{{SITENAME}}』\n* 更新日時: {{CURRENTYEAR}}年{{CURRENTMONTHNAME}}{{CURRENTDAY}}日 {{CURRENTTIME}} (UTC)\n* 取得日時: <citation>{{CURRENTYEAR}}年{{CURRENTMONTHNAME}}{{CURRENTDAY}}日 {{CURRENTTIME}} (UTC)</citation>\n* 恒久的なURI: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* ページの版番号: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== 各種方式による「{{FULLPAGENAME}}」の書誌表示 ==\n\n=== [[APA style|APA方式]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}年{{CURRENTMONTHNAME}}{{CURRENTDAY}}日{{CURRENTTIME}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. <citation>{{CURRENTYEAR}}年{{CURRENTMONTHNAME}}{{CURRENTDAY}}日{{CURRENTTIME}}</citation> {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} にて閲覧.\n\n=== [[The MLA style manual|MLA方式]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日{{CURRENTTIME}} (UTC). <citation>{{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日{{CURRENTTIME}}</citation> &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|MHRA方式]] ===\n{{SITENAME}}への寄稿者ら, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},''{{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日 (UTC), &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [<citation>{{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日</citation>閲覧]\n\n=== [[The Chicago Manual of Style|Chicago方式]] ===\n{{SITENAME}}への寄稿者ら, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (<citation>{{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日</citation>閲覧).\n\n=== [[Council of Science Editors|CBE/CSE方式]] ===\n{{SITENAME}}への寄稿者ら. {{FULLPAGENAME}} [Internet]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日{{CURRENTTIME}} (UTC) [<citation>{{CURRENTYEAR}}年{{CURRENTMONTHABBREV}}{{CURRENTDAY}}日</citation>現在で引用]. 入手元:\n{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebook方式]] ===\n{{FULLPAGENAME}}, {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (<citation>{{CURRENTYEAR}}年{{CURRENTMONTHNAME}}{{CURRENTDAY}}日</citation>最終訪問).\n\n=== [[BibTeX]]エントリ ===\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[オンライン; 閲覧日時 <citation>{{CURRENTYEAR}}-{{CURRENTDAY}}-{{CURRENTMONTH}}</citation>]\"\n }\n\nURIの体裁を整えるために[[LaTeX]]の url パッケージを用いる (プリアンブルのどこかに <code>\\usepackage{url}</code> と書く) 場合は、以下のようにした方がいいかもしれません。\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[オンライン; 閲覧日時 <citation>{{CURRENTYEAR}}-{{CURRENTDAY}}-{{CURRENTMONTH}}</citation>]\"\n }\n\n\n</div> <!--closing div for \"plainlinks\"-->"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/kea.json b/www/wiki/extensions/CiteThisPage/i18n/kea.json
new file mode 100644
index 00000000..c2b0aac1
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/kea.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Quintino Lopes Castro Tavares"
+ ]
+ },
+ "citethispage-link": "Sita es pájina",
+ "tooltip-citethispage": "Informason sobri modu ki bu debi sita es pájina"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/kum.json b/www/wiki/extensions/CiteThisPage/i18n/kum.json
new file mode 100644
index 00000000..d221b060
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/kum.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arsenekoumyk"
+ ]
+ },
+ "citethispage-link": "Бу сагьифаны цитатламакъ",
+ "tooltip-citethispage": "Бу сагьифаны цитатламакъ учун маълюматы"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/li.json b/www/wiki/extensions/CiteThisPage/i18n/li.json
index dd03fd57..831eea06 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/li.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/li.json
@@ -6,10 +6,11 @@
]
},
"citethispage": "Citere",
- "citethispage-desc": "Voog 'n [[Special:Cite|speciaal pagina óm te citere]] toe en 'ne link derhaer in de gereidsjapskis",
+ "citethispage-desc": "Voog 'n [[Special:CiteThisPage|speciaal pagina óm te citere]] toe en 'ne link derhaer in de gereidsjapskis",
"citethispage-link": "Citeer dees pagina",
"tooltip-citethispage": "Informatie euver wie se dees pazjena kins citere",
"citethispage-change-submit": "Citere",
"citethispage-change-target": "Pagina:",
+ "citethispage-badrevision": "Fout: kan gein versie vinje veur de pagina \"$1\" mit versie-id $2.",
"citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== Bibliografische gegaeves veur {{FULLPAGENAME}} ==\n\n* Paginanaam: {{FULLPAGENAME}}\n* Sjriever: {{SITENAME}}-biedragers\n* Oetgaever: ''{{SITENAME}}, {{int:sitesubtitle}}''.\n* Tiedstip lèste versie: {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC\n* Tiedstip geraodplieëgd: <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC</citation>\n* Permanente URL: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* Paginaversienómmer: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== Citaatstiel veur {{FULLPAGENAME}} ==\n\n=== [[APA style|APA-stiel]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. Geraodplieëg op <citation>{{CURRENTTIME}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation> van {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[The MLA style manual|MLA-stiel]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC. <citation>{{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}}</citation> &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|MHRA-stiel]] ===\n{{SITENAME}}-biedragers, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC, &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [geraodplieëg <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}</citation>]\n\n=== [[The Chicago Manual of Style|Chicagostiel]] ===\n{{SITENAME}}-biedragers, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (geraodplieëg <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[Council of Science Editors|CBE/CSE-stiel]] ===\n{{SITENAME}}-biedragers. {{FULLPAGENAME}} [Internet]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}, {{CURRENTTIME}} UTC [cetaot van <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]. Besjikbaar op:\n{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebookstiel]] ===\n{{FULLPAGENAME}}, {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (geraodplieëg op <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[BibTeX]]-gegaeves ===\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Online; geraadpleegd <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n't Volgendje kan de veurkäör höbben es de [[LaTeX]]-moduul \"url\" wuuertj gebroek (<code>\\usepackage{url}</code> örges in de inleiding), die webadresse sjónder opgemaak:\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Online; geraadpleegd <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n\n</div> <!--closing div for \"plainlinks\"-->"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/lij.json b/www/wiki/extensions/CiteThisPage/i18n/lij.json
index 635894f5..83fa485e 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/lij.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/lij.json
@@ -1,12 +1,13 @@
{
"@metadata": {
"authors": [
- "Giromin Cangiaxo"
+ "Giromin Cangiaxo",
+ "S4b1nuz E.656"
]
},
"citethispage": "Çitta sta paggina",
"citethispage-desc": "O l'azonze 'na paggina speciale pe-e [[Special:CiteThisPage|çitaçioin]] e 'n ingancio inti strumenti",
- "citethispage-link": "Çitta sta paggina",
+ "citethispage-link": "Çita quésta pàgina",
"tooltip-citethispage": "Informassioin sciu comme çitâ questa paggina",
"citethispage-change-submit": "Crea a çitaçion",
"citethispage-change-target": "Paggina:",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/lrc.json b/www/wiki/extensions/CiteThisPage/i18n/lrc.json
index 80f2918c..5e7f86a4 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/lrc.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/lrc.json
@@ -2,12 +2,13 @@
"@metadata": {
"authors": [
"Bonevarluri",
- "Mogoeilor"
+ "Mogoeilor",
+ "Beyronvan"
]
},
"citethispage": "جاگه",
- "citethispage-link": "جاگه ای بلگه",
- "tooltip-citethispage": "دونسمنیا چه جور دای بلگه جاگر بوئه",
+ "citethispage-link": "جاگٱ ای بلگٱ",
+ "tooltip-citethispage": "دۊنسمنیا چاٛ جۊر دی ای بلگٱ جاگر مۊٱن",
"citethispage-change-submit": "جاگه",
"citethispage-change-target": "بلگه"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/mk.json b/www/wiki/extensions/CiteThisPage/i18n/mk.json
index ca9c42f3..e255ae66 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/mk.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/mk.json
@@ -6,7 +6,7 @@
"Misos"
]
},
- "citethispage": "Наведување на страницата",
+ "citethispage": "Наведување на страница",
"citethispage-desc": "Додава службена страница за [[Special:CiteThisPage|наведување]] и врска кон алатникот",
"citethispage-link": "Наведи ја страницава",
"tooltip-citethispage": "Информации како да ја цитирате оваа страница",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/mo.json b/www/wiki/extensions/CiteThisPage/i18n/mo.json
new file mode 100644
index 00000000..21cbb5c0
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/mo.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "TheChampionMan1234",
+ "Cybernenea11"
+ ]
+ },
+ "citethispage-link": "Читязэ ачастэ паӂинэ",
+ "tooltip-citethispage": "Информаций ку привире ла модул де читаре а ачестей паӂинь"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/mr.json b/www/wiki/extensions/CiteThisPage/i18n/mr.json
index 4447389c..22801b17 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/mr.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/mr.json
@@ -3,13 +3,15 @@
"authors": [
"Kaustubh",
"Mahitgar",
- "V.narsikar"
+ "V.narsikar",
+ "Sureshkhole"
]
},
- "citethispage": "उधृत करा",
+ "citethispage": "या पानाचा संदर्भ जोडा",
"citethispage-desc": "एक [[Special:CiteThisPage|citation]] देणारे विशेषपान व साधनपेटीचा दुवा जोडते",
"citethispage-link": "हे पान उधृत करा",
"tooltip-citethispage": "हे पृष्ठ उद्धृत कसे करावे याची माहिती",
"citethispage-change-submit": "उधृत करा",
- "citethispage-change-target": "पान"
+ "citethispage-change-target": "पान",
+ "citethispage-badrevision": "त्रुटी: \"$1\" या पानासाठी ID $2 या बदलासाठी कोणतीही इतर आवृत्ती सापडली नाही."
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/mui.json b/www/wiki/extensions/CiteThisPage/i18n/mui.json
new file mode 100644
index 00000000..58fd9eb0
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/mui.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jawadywn"
+ ]
+ },
+ "citethispage-link": "Kutip laman niki",
+ "tooltip-citethispage": "Caro ngutip laman niki"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/mwl.json b/www/wiki/extensions/CiteThisPage/i18n/mwl.json
index 32b2f130..fab1e95f 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/mwl.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/mwl.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Malafaya",
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
"citethispage": "Citar esta páigina",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/nl.json b/www/wiki/extensions/CiteThisPage/i18n/nl.json
index 5031e2ae..7d5e336a 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/nl.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/nl.json
@@ -6,7 +6,8 @@
"Siebrand",
"Romaine",
"Paladox",
- "Sjoerddebruin"
+ "Sjoerddebruin",
+ "Mainframe98"
]
},
"citethispage": "Deze pagina citeren",
@@ -15,5 +16,6 @@
"tooltip-citethispage": "Informatie over hoe u deze pagina kunt citeren",
"citethispage-change-submit": "Citeren",
"citethispage-change-target": "Pagina:",
+ "citethispage-badrevision": "Fout: kan geen versie voor de pagina \"$1\" met versie ID $2 vinden.",
"citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== Bibliografische gegevens voor {{FULLPAGENAME}} ==\n\n* Paginanaam: {{FULLPAGENAME}}\n* Auteur: {{SITENAME}}-bijdragers\n* Uitgever: ''{{SITENAME}}, {{int:sitesubtitle}}''.\n* Tijdstip laatste versie: {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC\n* Tijdstip geraadpleegd: <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC</citation>\n* Permanente URL: {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* Paginaversienummer: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== Citaatstijlen voor {{FULLPAGENAME}} ==\n\n=== [[APA-stijl]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. Geraadpleegd op <citation>{{CURRENTTIME}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation> van {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[The MLA style manual|MLA-stijl]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC. <citation>{{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}}</citation> &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|MHRA-stijl]] ===\n{{SITENAME}}-bijdragers, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC, &lt;{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [geraadpleegd <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}</citation>]\n\n=== [[The Chicago Manual of Style|Chicago-stijl]] ===\n{{SITENAME}}-bijdragers, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (geraadpleegd <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[Council of Science Editors|CBE/CSE-stijl]] ===\n{{SITENAME}}-bijdragers. {{FULLPAGENAME}} [Internet]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}, {{CURRENTTIME}} UTC [citaat van <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]. Beschikbaar op:\n{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebook-stijl]] ===\n{{FULLPAGENAME}}, {{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (geraadpleegd op <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[BibTeX]]-gegevens ===\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Online; geraadpleegd <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\nHet volgende kan de voorkeur hebben als de [[LaTeX]]-module \"url\" wordt gebruikt (<code>\\usepackage{url}</code> ergens in de inleiding), die webadressen mooier opgemaakt:\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{canonicalurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Online; geraadpleegd <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n\n</div> <!--closing div for \"plainlinks\"-->"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/nys.json b/www/wiki/extensions/CiteThisPage/i18n/nys.json
new file mode 100644
index 00000000..60769192
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/nys.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "citethispage-link": "nidja bibol waanginy",
+ "tooltip-citethispage": "kadadjiny il yarnmen nidja bibol waanginy"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/pt.json b/www/wiki/extensions/CiteThisPage/i18n/pt.json
index 2b9afc32..fca966db 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/pt.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/pt.json
@@ -10,7 +10,7 @@
]
},
"citethispage": "Citar esta página",
- "citethispage-desc": "Página especial que produz uma [[Special:CiteThisPage|citação]] e adiciona uma ligação na barra de ferramentas",
+ "citethispage-desc": "Adiciona uma página especial que produz uma [[Special:CiteThisPage|citação]] e adiciona uma hiperligação na barra de ferramentas",
"citethispage-link": "Citar esta página",
"tooltip-citethispage": "Informação sobre como citar esta página",
"citethispage-change-submit": "Citar",
diff --git a/www/wiki/extensions/CiteThisPage/i18n/sat.json b/www/wiki/extensions/CiteThisPage/i18n/sat.json
new file mode 100644
index 00000000..c6274fd6
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/i18n/sat.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Manik Soren",
+ "Ramjit Tudu"
+ ]
+ },
+ "citethispage-link": "ᱱᱚᱶᱟ ᱥᱟᱦᱴᱟ ᱡᱚᱲᱟᱣᱢᱮ",
+ "tooltip-citethispage": "ᱱᱚᱶᱟ ᱥᱟᱦᱴᱟ ᱡᱚᱲᱟᱣ ᱨᱮᱱᱟᱜ ᱥᱩᱪᱱᱟ"
+}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/sd.json b/www/wiki/extensions/CiteThisPage/i18n/sd.json
index 2a124665..9225a4c1 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/sd.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/sd.json
@@ -8,5 +8,6 @@
},
"citethispage": "هيءُ صفحو حواليو",
"citethispage-link": "ھن صفحي جو حوالو ڏيو",
- "tooltip-citethispage": "ھن صفحي جو حوالو ڪيئن ڏجي بابت معلومات"
+ "tooltip-citethispage": "ھن صفحي جو حوالو ڪيئن ڏجي بابت معلومات",
+ "citethispage-change-submit": "حوالو"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/sr-ec.json b/www/wiki/extensions/CiteThisPage/i18n/sr-ec.json
index 0709c396..d48b1b2b 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/sr-ec.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/sr-ec.json
@@ -7,15 +7,17 @@
"Sasa Stefanovic",
"Жељко Тодоровић",
"Михајло Анђелковић",
- "Obsuser"
+ "Obsuser",
+ "Acamicamacaraca",
+ "BadDog"
]
},
- "citethispage": "Цитирање",
+ "citethispage": "Цитирање ове странице",
"citethispage-desc": "Додаје посебну страницу за [[Special:CiteThisPage|цитирање]] и везу с алаткама",
- "citethispage-link": "Цитирај ову страницу",
- "tooltip-citethispage": "Информације о томе како цитирати ову страну",
+ "citethispage-link": "Цитирање ове странице",
+ "tooltip-citethispage": "Информације о томе како цитирати ову страницу",
"citethispage-change-submit": "Цитирај",
"citethispage-change-target": "Страница:",
"citethispage-badrevision": "Грешка: није било могуће наћи измену за страницу „$1” са ID-ом измене $2.",
- "citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== Библиографски детаљи за страну {{FULLPAGENAME}} ==\n\n* Назив стране: {{FULLPAGENAME}} \n* Аутор: {{SITENAME}} сарадници\n* Издавач: ''{{SITENAME}}, {{int:sitesubtitle}}''. \n* Датум последње ревизије: {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC\n* Датум узимања: <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC</citation>\n* Стални URL: {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* ID верзије стране: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== Стилови цитирања за страну {{FULLPAGENAME}} ==\n\n=== [[APA style|APA стил]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. Узето <citation>{{CURRENTTIME}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation> од {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[The MLA style manual|MLA стил]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC. <citation>{{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}}</citation> &lt;{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|MHRA стил]] ===\nВикипедијини сарадници, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC, &lt;{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [приступљено <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}</citation>]\n\n=== [[The Chicago Manual of Style|Чикаго стил]] ===\nВикипедијини сарадници, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (приступљено <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[Council of Science Editors|CBE/CSE стил]] ===\nВикипедијини сарадници. {{FULLPAGENAME}} [Интернет]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}, {{CURRENTTIME}} UTC [цитирано <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]. Доступно са: \n{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebook стил]] ===\n{{FULLPAGENAME}}, {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (последња посета <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[BibTeX]] унос ===\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Online; accessed <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\nКада користите [[LaTeX]] пакет url (<code>\\usepackage{url}</code> негде у преамбули) који тежи да да далеко лепше форматирану адресу, следеће је можда боље:\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Online; accessed <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n\n</div><!--cerrando div para \"plainlinks\"-->"
+ "citethispage-content": "__NOTOC__\n<div class=\"mw-specialCiteThisPage-bibliographic\">\n\n== Библиографски детаљи за страну {{FULLPAGENAME}} ==\n\n* Назив стране: {{FULLPAGENAME}} \n* Аутор: Сарадници на сајту {{SITENAME}}\n* Издавач: ''{{SITENAME}}, {{int:sitesubtitle}}''. \n* Датум последње ревизије: {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC\n* Датум узимања: <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}} {{CURRENTTIME}} UTC</citation>\n* Стални URL: {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\n* ID верзије стране: {{REVISIONID}}\n\n</div>\n<div class=\"plainlinks mw-specialCiteThisPage-styles\">\n\n== Стилови цитирања за страну {{FULLPAGENAME}} ==\n\n=== [[APA style|APA стил]] ===\n{{FULLPAGENAME}}. ({{CURRENTYEAR}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}). ''{{SITENAME}}, {{int:sitesubtitle}}''. Узето <citation>{{CURRENTTIME}}, {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation> од {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[The MLA style manual|MLA стил]] ===\n\"{{FULLPAGENAME}}.\" ''{{SITENAME}}, {{int:sitesubtitle}}''. {{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC. <citation>{{CURRENTDAY}} {{CURRENTMONTHABBREV}} {{CURRENTYEAR}}, {{CURRENTTIME}}</citation> &lt;{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt;.\n\n=== [[MHRA Style Guide|MHRA стил]] ===\nВикипедијини корисници, '{{FULLPAGENAME}}', ''{{SITENAME}}, {{int:sitesubtitle}},'' {{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}, {{CURRENTTIME}} UTC, &lt;{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}&gt; [приступљено <citation>{{CURRENTDAY}} {{CURRENTMONTHNAME}} {{CURRENTYEAR}}</citation>]\n\n=== [[The Chicago Manual of Style|Чикаго стил]] ===\nВикипедијини корисници, \"{{FULLPAGENAME}},\" ''{{SITENAME}}, {{int:sitesubtitle}},'' {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (приступљено <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[Council of Science Editors|CBE/CSE стил]] ===\nВикипедијини корисници. {{FULLPAGENAME}} [Интернет]. {{SITENAME}}, {{int:sitesubtitle}}; {{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}, {{CURRENTTIME}} UTC [цитирано <citation>{{CURRENTYEAR}} {{CURRENTMONTHABBREV}} {{CURRENTDAY}}</citation>]. Доступно са: \n{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}.\n\n=== [[Bluebook|Bluebook стил]] ===\n{{FULLPAGENAME}}, {{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}} (последња посета <citation>{{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}}</citation>).\n\n=== [[BibTeX]] унос ===\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}\",\n note = \"[Online; accessed <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\nКада користите [[LaTeX]] пакет url (<code>\\usepackage{url}</code> негде у преамбули) који тежи да да далеко лепше форматирану адресу, следеће је можда боље:\n\n @misc{ wiki:xxx,\n author = \"{{SITENAME}}\",\n title = \"{{FULLPAGENAME}} --- {{SITENAME}}{,} {{int:sitesubtitle}}\",\n year = \"{{CURRENTYEAR}}\",\n url = \"'''\\url{'''{{fullurl:{{FULLPAGENAME}}|oldid={{REVISIONID}}}}'''}'''\",\n note = \"[Online; accessed <citation>{{CURRENTDAY}}-{{CURRENTMONTHNAME}}-{{CURRENTYEAR}}</citation>]\"\n }\n\n\n</div> <!--closing div for \"plainlinks\"-->"
}
diff --git a/www/wiki/extensions/CiteThisPage/i18n/zgh.json b/www/wiki/extensions/CiteThisPage/i18n/zgh.json
index 65892afe..b02efbf6 100644
--- a/www/wiki/extensions/CiteThisPage/i18n/zgh.json
+++ b/www/wiki/extensions/CiteThisPage/i18n/zgh.json
@@ -1,8 +1,10 @@
{
"@metadata": {
"authors": [
- "Amara-Amaziɣ"
+ "Amara-Amaziɣ",
+ "Mdb897"
]
},
- "citethispage-link": "ⴱⴷⵔ ⵜⴰⵙⵏⴰ ⴰ"
+ "citethispage-link": "ⴱⴷⵔ ⵜⴰⵙⵏⴰ ⴰ",
+ "tooltip-citethispage": "ⵉⵏⵖⵎⵉⵙⵏ ⵖⴼ ⵎⴰⵎⴽ ⵙ ⵔⴰⴷ ⵜⴱⴷⴰⵔⴷ ⵜⴰⵙⵏⴰ ⴰⴷ"
}
diff --git a/www/wiki/extensions/CiteThisPage/includes/CiteThisPageHooks.php b/www/wiki/extensions/CiteThisPage/includes/CiteThisPageHooks.php
new file mode 100644
index 00000000..c38c164b
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/includes/CiteThisPageHooks.php
@@ -0,0 +1,62 @@
+<?php
+
+class CiteThisPageHooks {
+
+ /**
+ * @param SkinTemplate &$skintemplate
+ * @param array &$nav_urls
+ * @param int &$oldid
+ * @param int &$revid
+ * @return bool
+ */
+ public static function onSkinTemplateBuildNavUrlsNav_urlsAfterPermalink(
+ &$skintemplate, &$nav_urls, &$oldid, &$revid
+ ) {
+ // check whether we’re in the right namespace, the $revid has the correct type and is not empty
+ // (which would mean that the current page doesn’t exist)
+ $title = $skintemplate->getTitle();
+ if ( self::shouldAddLink( $title ) && $revid !== 0 && !empty( $revid ) ) {
+ $nav_urls['citethispage'] = [
+ 'text' => $skintemplate->msg( 'citethispage-link' )->text(),
+ 'href' => SpecialPage::getTitleFor( 'CiteThisPage' )
+ ->getLocalURL( [ 'page' => $title->getPrefixedDBkey(), 'id' => $revid ] ),
+ 'id' => 't-cite',
+ # Used message keys: 'tooltip-citethispage', 'accesskey-citethispage'
+ 'single-id' => 'citethispage',
+ ];
+ }
+
+ return true;
+ }
+
+ /**
+ * Checks, if the "cite this page" link should be added. By default the link is added to all
+ * pages in the main namespace, and additionally to pages, which are in one of the namespaces
+ * named in $wgCiteThisPageAddiotionalNamespaces.
+ *
+ * @param Title $title
+ * @return bool
+ */
+ private static function shouldAddLink( Title $title ) {
+ global $wgCiteThisPageAdditionalNamespaces;
+
+ return $title->isContentPage() ||
+ (
+ isset( $wgCiteThisPageAdditionalNamespaces[$title->getNamespace()] ) &&
+ $wgCiteThisPageAdditionalNamespaces[$title->getNamespace()]
+ );
+ }
+
+ /**
+ * @param BaseTemplate $baseTemplate
+ * @param array &$toolbox
+ * @return bool
+ */
+ public static function onBaseTemplateToolbox( BaseTemplate $baseTemplate, array &$toolbox ) {
+ if ( isset( $baseTemplate->data['nav_urls']['citethispage'] ) ) {
+ $toolbox['citethispage'] = $baseTemplate->data['nav_urls']['citethispage'];
+ }
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/CiteThisPage/includes/SpecialCiteThisPage.php b/www/wiki/extensions/CiteThisPage/includes/SpecialCiteThisPage.php
new file mode 100644
index 00000000..3034f288
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/includes/SpecialCiteThisPage.php
@@ -0,0 +1,217 @@
+<?php
+
+class SpecialCiteThisPage extends FormSpecialPage {
+
+ /**
+ * @var Parser
+ */
+ private $citationParser;
+
+ /**
+ * @var Title|bool
+ */
+ protected $title = false;
+
+ public function __construct() {
+ parent::__construct( 'CiteThisPage' );
+ }
+
+ /**
+ * @param string $par
+ */
+ public function execute( $par ) {
+ $this->setHeaders();
+ parent::execute( $par );
+ if ( $this->title instanceof Title ) {
+ $id = $this->getRequest()->getInt( 'id' );
+ $this->showCitations( $this->title, $id );
+ }
+ }
+
+ protected function alterForm( HTMLForm $form ) {
+ $form->setMethod( 'get' );
+ }
+
+ protected function getFormFields() {
+ if ( isset( $this->par ) ) {
+ $default = $this->par;
+ } else {
+ $default = '';
+ }
+ return [
+ 'page' => [
+ 'name' => 'page',
+ 'type' => 'title',
+ 'default' => $default,
+ 'label-message' => 'citethispage-change-target'
+ ]
+ ];
+ }
+
+ public function onSubmit( array $data ) {
+ // GET forms are "submitted" on every view, so check
+ // that some data was put in for page, as empty string
+ // will pass validation
+ if ( strlen( $data['page'] ) ) {
+ $this->title = Title::newFromText( $data['page'] );
+ }
+ return true;
+ }
+
+ /**
+ * Return an array of subpages beginning with $search that this special page will accept.
+ *
+ * @param string $search Prefix to search for
+ * @param int $limit Maximum number of results to return (usually 10)
+ * @param int $offset Number of results to skip (usually 0)
+ * @return string[] Matching subpages
+ */
+ public function prefixSearchSubpages( $search, $limit, $offset ) {
+ $title = Title::newFromText( $search );
+ if ( !$title || !$title->canExist() ) {
+ // No prefix suggestion in special and media namespace
+ return [];
+ }
+ // Autocomplete subpage the same as a normal search
+ $result = SearchEngine::completionSearch( $search );
+ return array_map( function ( $sub ) {
+ return $sub->getSuggestedTitle();
+ }, $result->getSuggestions() );
+ }
+
+ protected function getGroupName() {
+ return 'pagetools';
+ }
+
+ private function showCitations( Title $title, $revId ) {
+ if ( !$revId ) {
+ $revId = $title->getLatestRevID();
+ }
+
+ $out = $this->getOutput();
+
+ $revision = Revision::newFromTitle( $title, $revId );
+ if ( !$revision ) {
+ $out->wrapWikiMsg( '<div class="errorbox">$1</div>',
+ [ 'citethispage-badrevision', $title->getPrefixedText(), $revId ] );
+ return;
+ }
+
+ $parserOptions = $this->getParserOptions();
+ // Set the overall timestamp to the revision's timestamp
+ $parserOptions->setTimestamp( $revision->getTimestamp() );
+
+ $parser = $this->getParser();
+ // Register our <citation> tag which just parses using a different
+ // context
+ $parser->setHook( 'citation', [ $this, 'citationTag' ] );
+ // Also hold on to a separate Parser instance for <citation> tag parsing
+ // since we can't parse in a parse using the same Parser
+ $this->citationParser = $this->getParser();
+
+ $ret = $parser->parse(
+ $this->getContentText(),
+ $title,
+ $parserOptions,
+ /* $linestart = */ false,
+ /* $clearstate = */ true,
+ $revId
+ );
+
+ $this->getOutput()->addModuleStyles( 'ext.citeThisPage' );
+ $this->getOutput()->addParserOutputContent( $ret, [
+ 'enableSectionEditLinks' => false,
+ ] );
+ }
+
+ /**
+ * @return Parser
+ */
+ private function getParser() {
+ $parserConf = $this->getConfig()->get( 'ParserConf' );
+ return new $parserConf['class']( $parserConf );
+ }
+
+ /**
+ * Get the content to parse
+ *
+ * @return string
+ */
+ private function getContentText() {
+ $msg = $this->msg( 'citethispage-content' )->inContentLanguage()->plain();
+ if ( $msg == '' ) {
+ # With MediaWiki 1.20 the plain text files were deleted
+ # and the text moved into SpecialCite.i18n.php
+ # This code is kept for b/c in case an installation has its own file "citethispage-content-xx"
+ # for a previously not supported language.
+ global $wgContLang, $wgContLanguageCode;
+ $dir = __DIR__ . '/../';
+ $code = $wgContLang->lc( $wgContLanguageCode );
+ if ( file_exists( "${dir}citethispage-content-$code" ) ) {
+ $msg = file_get_contents( "${dir}citethispage-content-$code" );
+ } elseif ( file_exists( "${dir}citethispage-content" ) ) {
+ $msg = file_get_contents( "${dir}citethispage-content" );
+ }
+ }
+
+ return $msg;
+ }
+
+ /**
+ * Get the common ParserOptions for both parses
+ *
+ * @return ParserOptions
+ */
+ private function getParserOptions() {
+ $parserOptions = ParserOptions::newFromUser( $this->getUser() );
+ $parserOptions->setDateFormat( 'default' );
+
+ // Having tidy on causes whitespace and <pre> tags to
+ // be generated around the output of the CiteThisPageOutput
+ // class TODO FIXME.
+ $parserOptions->setTidy( false );
+
+ return $parserOptions;
+ }
+
+ /**
+ * Implements the <citation> tag.
+ *
+ * This is a hack to allow content that is typically parsed
+ * using the page's timestamp/pagetitle to use the current
+ * request's time and title
+ *
+ * @param string $text
+ * @param array $params
+ * @param Parser $parser
+ * @return string
+ */
+ public function citationTag( $text, $params, Parser $parser ) {
+ $parserOptions = $this->getParserOptions();
+
+ $ret = $this->citationParser->parse(
+ $text,
+ $this->getPageTitle(),
+ $parserOptions,
+ /* $linestart = */ false
+ );
+
+ return $ret->getText( [
+ 'enableSectionEditLinks' => false,
+ // This will be inserted into the output of another parser, so there will actually be a wrapper
+ 'unwrap' => true,
+ ] );
+ }
+
+ protected function getDisplayFormat() {
+ return 'ooui';
+ }
+
+ public function requiresUnblock() {
+ return false;
+ }
+
+ public function requiresWrite() {
+ return false;
+ }
+}
diff --git a/www/wiki/extensions/CiteThisPage/tests/phan/config.php b/www/wiki/extensions/CiteThisPage/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/CiteThisPage/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/CodeEditor/CODE_OF_CONDUCT.md b/www/wiki/extensions/CodeEditor/CODE_OF_CONDUCT.md
new file mode 100644
index 00000000..d8e5d087
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/CODE_OF_CONDUCT.md
@@ -0,0 +1 @@
+The development of this software is covered by a [Code of Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
diff --git a/www/wiki/extensions/CodeEditor/COPYING b/www/wiki/extensions/CodeEditor/COPYING
new file mode 100644
index 00000000..96e292ad
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/COPYING
@@ -0,0 +1,349 @@
+The license text below "====" applies to all files within this distribution,
+other than those that are in a directory which contains files named "LICENSE"
+or "COPYING", or a subdirectory thereof. For those files, the license text
+contained in said file overrides any license information contained in
+directories of smaller depth. Alternative licenses are typically used for
+software that is provided by external parties, and merely packaged with this
+software for convenience.
+
+====
+
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/www/wiki/extensions/CodeEditor/CodeEditor.php b/www/wiki/extensions/CodeEditor/CodeEditor.php
new file mode 100644
index 00000000..3cbcc1de
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/CodeEditor.php
@@ -0,0 +1,31 @@
+<?php
+
+/**
+ * Helper to load syntax-highlighting editor for JavaScript and CSS pages
+ * on-wiki.
+ *
+ * Extends and requires WikiEditor extension.
+ *
+ * Extension code is GPLv2 following MediaWiki base.
+ * Ace editor JS code follows its own license, see in the 'ace' subdir.
+ */
+
+/**
+ * This PHP entry point is deprecated.
+ * Please use wfLoadExtension() and the extension.json file instead.
+ * See https://www.mediawiki.org/wiki/Manual:Extension_registration for more details.
+ */
+
+if ( function_exists( 'wfLoadExtension' ) ) {
+ wfLoadExtension( 'CodeEditor' );
+ // Keep i18n globals so mergeMessageFileList.php doesn't break
+ $wgMessagesDirs['CodeEditor'] = __DIR__ . '/i18n';
+ /* wfWarn(
+ 'Deprecated PHP entry point used for CodeEditor extension. ' .
+ 'Please use wfLoadExtension instead, ' .
+ 'see https://www.mediawiki.org/wiki/Extension_registration for more details.'
+ ); */
+ return;
+} else {
+ die( 'This version of the CodeEditor extension requires MediaWiki 1.25+' );
+}
diff --git a/www/wiki/extensions/CodeEditor/Gruntfile.js b/www/wiki/extensions/CodeEditor/Gruntfile.js
new file mode 100644
index 00000000..df5bdd7f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/Gruntfile.js
@@ -0,0 +1,46 @@
+/*!
+ * Grunt file
+ *
+ * @package CodeEditor
+ */
+
+/* eslint-env node */
+
+module.exports = function ( grunt ) {
+ var conf = grunt.file.readJSON( 'extension.json' );
+ grunt.loadNpmTasks( 'grunt-banana-checker' );
+ grunt.loadNpmTasks( 'grunt-eslint' );
+ grunt.loadNpmTasks( 'grunt-stylelint' );
+ grunt.loadNpmTasks( 'grunt-jsonlint' );
+
+ grunt.initConfig( {
+ eslint: {
+ all: [
+ '**/*.js',
+ '!node_modules/**',
+ '!modules/ace/**',
+ '!vendor/**'
+ ]
+ },
+ stylelint: {
+ all: [
+ '**/*.css',
+ '**/*.less',
+ '!node_modules/**',
+ '!modules/ace/**',
+ '!vendor/**'
+ ]
+ },
+ banana: conf.MessagesDirs,
+ jsonlint: {
+ all: [
+ '**/*.json',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ }
+ } );
+
+ grunt.registerTask( 'test', [ 'eslint', 'stylelint', 'jsonlint', 'banana' ] );
+ grunt.registerTask( 'default', 'test' );
+};
diff --git a/www/wiki/extensions/CodeEditor/Makefile b/www/wiki/extensions/CodeEditor/Makefile
new file mode 100644
index 00000000..c5d81be5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/Makefile
@@ -0,0 +1,19 @@
+# Helper to pull the ace goodies
+
+.PHONY: all clean refresh
+
+all: refresh
+
+clean:
+ rm -rf modules/ace ace-git
+
+refresh: ace-git
+ test -d modules/ace || mkdir modules/ace
+ (cd ace-git && git checkout master && git pull origin master)
+ (cd ace-git && npm install && node ./Makefile.dryice.js -nc)
+ rsync -av ace-git/build/src-noconflict/ modules/ace/
+ cp ace-git/LICENSE modules/ace/LICENSE
+
+ace-git:
+ git clone git://github.com/ajaxorg/ace.git ace-git
+
diff --git a/www/wiki/extensions/CodeEditor/composer.json b/www/wiki/extensions/CodeEditor/composer.json
new file mode 100644
index 00000000..69a01ec2
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/composer.json
@@ -0,0 +1,23 @@
+{
+ "require-dev": {
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
+ },
+ "scripts": {
+ "test": [
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
+ ],
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
+ }
+}
diff --git a/www/wiki/extensions/CodeEditor/extension.json b/www/wiki/extensions/CodeEditor/extension.json
new file mode 100644
index 00000000..4da29709
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/extension.json
@@ -0,0 +1,146 @@
+{
+ "name": "CodeEditor",
+ "author": [
+ "Brion Vibber",
+ "Derk-Jan Hartman",
+ "[https://ace.c9.io/ authors of Ace]"
+ ],
+ "url": "https://www.mediawiki.org/wiki/Extension:CodeEditor",
+ "descriptionmsg": "codeeditor-desc",
+ "license-name": "GPL-2.0-or-later AND BSD-3-Clause",
+ "type": "editor",
+ "requires": {
+ "MediaWiki": ">= 1.29.0",
+ "extensions": {
+ "WikiEditor": "*"
+ }
+ },
+ "Hooks": {
+ "EditPage::showEditForm:initial": [
+ "CodeEditorHooks::editPageShowEditFormInitial"
+ ],
+ "EditPage::showReadOnlyForm:initial": [
+ "CodeEditorHooks::editPageShowEditFormInitial"
+ ],
+ "GetPreferences": [
+ "CodeEditorHooks::getPreferences"
+ ]
+ },
+ "MessagesDirs": {
+ "CodeEditor": [
+ "i18n"
+ ]
+ },
+ "config": {
+ "CodeEditorEnableCore": true
+ },
+ "DefaultUserOptions": {
+ "usecodeeditor": 1
+ },
+ "ResourceModules": {
+ "ext.codeEditor": {
+ "scripts": "ext.codeEditor.js",
+ "dependencies": [
+ "jquery.codeEditor"
+ ],
+ "group": "ext.wikiEditor"
+ },
+ "jquery.codeEditor": {
+ "scripts": "jquery.codeEditor.js",
+ "styles": "jquery.codeEditor.less",
+ "dependencies": [
+ "ext.wikiEditor",
+ "ext.codeEditor.ace",
+ "jquery.ui.resizable",
+ "mediawiki.api",
+ "mediawiki.api.options",
+ "mediawiki.user",
+ "user.options",
+ "mediawiki.cookie",
+ "jquery.textSelection",
+ "oojs-ui-windows",
+ "oojs-ui.styles.icons-content",
+ "oojs-ui.styles.icons-editing-advanced",
+ "oojs-ui.styles.icons-editing-list",
+ "ext.codeEditor.icons"
+ ],
+ "messages": [
+ "codeeditor-next-annotation",
+ "codeeditor-toolbar-toggle",
+ "codeeditor-save-with-errors",
+ "codeeditor-invisibleChars-toggle",
+ "codeeditor-lineWrapping-toggle",
+ "codeeditor-searchReplace-toggle",
+ "codeeditor-gotoline",
+ "codeeditor-gotoline-placeholder",
+ "codeeditor-gotoline-prompt",
+ "codeeditor-indent",
+ "codeeditor-outdent"
+ ],
+ "group": "ext.wikiEditor"
+ },
+ "ext.codeEditor.icons": {
+ "class": "ResourceLoaderImageModule",
+ "selectorWithoutVariant": ".oo-ui-icon-{name}",
+ "selectorWithVariant": ".oo-ui-image-{variant}.oo-ui-icon-{name}",
+ "variants": {
+ "progressive": {
+ "color": "#36c"
+ }
+ },
+ "images": {
+ "gotoLine": {
+ "file": "../images/gotoLine.svg"
+ },
+ "pilcrow": {
+ "file": "../images/pilcrow.svg",
+ "variants": [ "progressive" ]
+ },
+ "wrapping": {
+ "file": "../images/wrapping.svg",
+ "variants": [ "progressive" ]
+ }
+ }
+ },
+ "ext.codeEditor.ace": {
+ "group": "ext.codeEditor.ace",
+ "scripts": [
+ "ace/ace.js",
+ "ace/mode-javascript.js",
+ "ace/mode-json.js",
+ "ace/mode-css.js",
+ "ace/mode-lua.js",
+ "ace/ext-language_tools.js",
+ "ace/ext-modelist.js"
+ ]
+ },
+ "ext.codeEditor.ace.modes": {
+ "group": "ext.codeEditor.ace",
+ "scripts": [
+ "ace/mode-c_cpp.js",
+ "ace/mode-clojure.js",
+ "ace/mode-csharp.js",
+ "ace/mode-coffee.js",
+ "ace/mode-groovy.js",
+ "ace/mode-html.js",
+ "ace/mode-java.js",
+ "ace/mode-latex.js",
+ "ace/mode-ocaml.js",
+ "ace/mode-perl.js",
+ "ace/mode-php.js",
+ "ace/mode-python.js",
+ "ace/mode-ruby.js",
+ "ace/mode-scala.js"
+ ],
+ "dependencies": "ext.codeEditor.ace"
+ }
+ },
+ "ResourceFileModulePaths": {
+ "localBasePath": "modules",
+ "remoteExtPath": "CodeEditor/modules"
+ },
+ "AutoloadClasses": {
+ "CodeEditorHooks": "includes/CodeEditorHooks.php"
+ },
+ "manifest_version": 1
+}
diff --git a/www/wiki/extensions/CodeEditor/hooks.txt b/www/wiki/extensions/CodeEditor/hooks.txt
new file mode 100644
index 00000000..531d9ebc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/hooks.txt
@@ -0,0 +1,4 @@
+== JS hooks ==
+'codeEditor.configure' is fired during the set up of the ACE editor
+Params:
+* {object} session ACE editor session
diff --git a/www/wiki/extensions/CodeEditor/i18n/af.json b/www/wiki/extensions/CodeEditor/i18n/af.json
new file mode 100644
index 00000000..4fff6b50
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/af.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Naudefj"
+ ]
+ },
+ "codeeditor-desc": "Sintaks-uitgeligde redigering vir JavaScript- en CSS-bladsye met [https://ace.c9.io/ Ace-redigeerder]",
+ "codeeditor-toolbar-toggle": "Aktiveer of deaktiveer kode-teksverwerker"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ar.json b/www/wiki/extensions/CodeEditor/i18n/ar.json
new file mode 100644
index 00000000..a231303d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ar.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "محمد أحمد عبد الفتاح",
+ "علاء",
+ "ديفيد"
+ ]
+ },
+ "codeeditor-desc": "بناء على ذلك، أبرز التحرير لصفحات جافا سكريبت وCSS باستخدام [https://ace.c9.io/ محرر Ace]",
+ "codeeditor-next-annotation": "انتقل إلى التعليق التوضيحي التالي",
+ "codeeditor-toolbar-toggle": "تبديل محرر الكود",
+ "codeeditor-save-with-errors": "الملف يحتوي على أخطاء. هل أنت متأكد من الحفظ؟",
+ "codeeditor-invisibleChars-toggle": "تبديل الأحرف غير المرئية",
+ "codeeditor-lineWrapping-toggle": "تبديل التفاف الخط",
+ "codeeditor-searchReplace-toggle": "تبديل مربع حوار البحث والاستبدال",
+ "codeeditor-gotoline": "انتقل إلى السطر رقم...",
+ "codeeditor-gotoline-placeholder": "خط [:العمود]",
+ "codeeditor-gotoline-prompt": "أدخل رقم السطر",
+ "codeeditor-indent": "إزاحة",
+ "codeeditor-outdent": "إزاحة",
+ "codeeditor-error-title": "فشلت التبعية",
+ "codeeditor-error-message": "يحتاج محرر الكود إلى تحميل محرر الويكي."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ast.json b/www/wiki/extensions/CodeEditor/i18n/ast.json
new file mode 100644
index 00000000..c522bb43
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ast.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xuacu"
+ ]
+ },
+ "codeeditor-desc": "Edición con resaltáu de sintaxis pa páxines JavaScript y CSS usando [https://ace.c9.io/ l'editor Ace]",
+ "codeeditor-next-annotation": "Dir a la siguiente anotación",
+ "codeeditor-toolbar-toggle": "Activar o desactivar l'editor de códigu",
+ "codeeditor-save-with-errors": "El documentu contien errores. ¿Tas seguru de que quies guardalu?",
+ "codeeditor-invisibleChars-toggle": "Conmutar caráuteres invisibles",
+ "codeeditor-lineWrapping-toggle": "Conmutar l'axuste de llinies",
+ "codeeditor-searchReplace-toggle": "Conmutar el cuadru de buscar y trocar",
+ "codeeditor-gotoline": "Dir a la llinia númberu...",
+ "codeeditor-gotoline-placeholder": "llinia[:columna]",
+ "codeeditor-gotoline-prompt": "Escribe un númberu de llinia",
+ "codeeditor-indent": "Aumentar sangría",
+ "codeeditor-outdent": "Amenorgar sangría",
+ "codeeditor-error-title": "Faltó una dependencia",
+ "codeeditor-error-message": "CodeEditor necesita que tea cargáu el WikiEditor."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/azb.json b/www/wiki/extensions/CodeEditor/i18n/azb.json
new file mode 100644
index 00000000..5ecfd288
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/azb.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mousa"
+ ]
+ },
+ "codeeditor-desc": "[https://ace.c9.io/ Ace editor] ایله سی‌اِس‌اِس و جاوااسکریپت صحیفه‌لرینین سنتکس رنگلندیریلمیش دَییشدیرمه‌سی.",
+ "codeeditor-toolbar-toggle": "کود دَییشدیرَنینی دؤندر"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ba.json b/www/wiki/extensions/CodeEditor/i18n/ba.json
new file mode 100644
index 00000000..6a8ee7ab
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ba.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sagan"
+ ]
+ },
+ "codeeditor-desc": "Синтаксисты JavaScript- һәм CSS-бит ярҙамында мөхәррирләү [https://ace.c9.io/ редактор Ace]",
+ "codeeditor-next-annotation": "Киләһе аннотацияға күсергә",
+ "codeeditor-toolbar-toggle": "Мөхәррир кодын алыштырырға",
+ "codeeditor-save-with-errors": "Документта хаталар бар. Һаҡларға теләйһегеҙме?",
+ "codeeditor-invisibleChars-toggle": "Күренмәй торған символдар күһәткесенә күсеү",
+ "codeeditor-lineWrapping-toggle": "Юл күсергесенә күсеү",
+ "codeeditor-searchReplace-toggle": "Диалог эҙләү һәм тексты алмаштырыу күсергесе",
+ "codeeditor-gotoline": "... номерлы юлға күсеү",
+ "codeeditor-indent": "Юл башында буш ара",
+ "codeeditor-outdent": "Һулға күсеү"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/bcl.json b/www/wiki/extensions/CodeEditor/i18n/bcl.json
new file mode 100644
index 00000000..b545ab34
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/bcl.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Geopoet"
+ ]
+ },
+ "codeeditor-desc": "An pagliliwat na sintaks ipinagpapalangkaw para sa JavaScript asin CSS na mga pahina na ginagamit an [https://ace.c9.io/ Alas na paraliwat]",
+ "codeeditor-toolbar-toggle": "Bugkuson an paraliwat nin kodigo"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/be-tarask.json b/www/wiki/extensions/CodeEditor/i18n/be-tarask.json
new file mode 100644
index 00000000..d33cf623
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/be-tarask.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "EugeneZelenko",
+ "Wizardist",
+ "Red Winged Duck"
+ ]
+ },
+ "codeeditor-desc": "Рэдагаваньне JavaScript- і CSS-коду на старонках з падсьветкай сынтаксісу ў [https://ace.c9.io/ рэдактары Ace]",
+ "codeeditor-toolbar-toggle": "Рэдактар коду"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/bn.json b/www/wiki/extensions/CodeEditor/i18n/bn.json
new file mode 100644
index 00000000..3ac0d1c5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/bn.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aftabuzzaman"
+ ]
+ },
+ "codeeditor-desc": "[https://ace.c9.io/ Ace সম্পাদক] সম্পাদক ব্যবহার করে জাভাস্ক্রিপ্ট ও সিএসএস পাতাগুলির জন্য সিনট্যাক্স-আলোকপাতসহ সম্পাদনা করতে দেয়",
+ "codeeditor-next-annotation": "পরবর্তী টীকায় যান",
+ "codeeditor-toolbar-toggle": "কোড সম্পাদক সক্রিয় বা নিষ্ক্রিয় করুন",
+ "codeeditor-save-with-errors": "নথিটিতে ত্রুটি রয়েছে। আপনি কি নিশ্চিত যে আপনি সংরক্ষণ করতে চান?",
+ "codeeditor-invisibleChars-toggle": "অদৃশ্য অক্ষর দেখান/লুকান",
+ "codeeditor-lineWrapping-toggle": "লাইন মোড়ানো সক্রিয়/নিষ্ক্রিয় করুন",
+ "codeeditor-searchReplace-toggle": "অনুসন্ধান ও প্রতিস্থাপন বাক্স দেখান/লুকান",
+ "codeeditor-gotoline": "এত নং লাইনের নম্বরে যান...",
+ "codeeditor-gotoline-placeholder": "লাইন[:কলাম]",
+ "codeeditor-gotoline-prompt": "একটি লাইন নম্বর লিখুন",
+ "codeeditor-indent": "প্রান্তিককরণ",
+ "codeeditor-outdent": "ঋণাত্মক প্রান্তিককরণ",
+ "codeeditor-error-title": "নির্ভরতা ব্যর্থ",
+ "codeeditor-error-message": "কোডসম্পাদকের উইকিসম্পাদক লোড হওয়া প্রয়োজন।"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/br.json b/www/wiki/extensions/CodeEditor/i18n/br.json
new file mode 100644
index 00000000..3a7737ab
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/br.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fohanno"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "Gweredekaat/diweredekaat an aozer kod",
+ "codeeditor-save-with-errors": "Fazioù zo en teul. Ha sur oc'h e fell deoc'h enrollañ anezhañ ?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/bs.json b/www/wiki/extensions/CodeEditor/i18n/bs.json
new file mode 100644
index 00000000..0e673b44
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/bs.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "CERminator",
+ "Srdjan m"
+ ]
+ },
+ "codeeditor-desc": "Uređivanje s istaknutom sintaksom za JavaScript i CSS stranice koristeći [https://ace.c9.io/ uređivač Ace]",
+ "codeeditor-toolbar-toggle": "Uključi/isključi uređivač kôda",
+ "codeeditor-gotoline-placeholder": "red[:kolona]",
+ "codeeditor-gotoline-prompt": "Upišite broj reda"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ca.json b/www/wiki/extensions/CodeEditor/i18n/ca.json
new file mode 100644
index 00000000..336ca349
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ca.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arnaugir",
+ "Ssola",
+ "Vriullop",
+ "Fitoschido"
+ ]
+ },
+ "codeeditor-next-annotation": "Vés a la següent anotació",
+ "codeeditor-toolbar-toggle": "Activa o desactiva l'editor de codi",
+ "codeeditor-save-with-errors": "El document conté errors. Segur que el voleu desar?",
+ "codeeditor-invisibleChars-toggle": "Mostra o oculta els caràcters invisibles",
+ "codeeditor-lineWrapping-toggle": "Alterna l'ajustament de línies",
+ "codeeditor-searchReplace-toggle": "Mostra o oculta el diàleg de cerca i substitució",
+ "codeeditor-gotoline": "Vés a la línia número..."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ce.json b/www/wiki/extensions/CodeEditor/i18n/ce.json
new file mode 100644
index 00000000..45a7c1e4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ce.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Умар"
+ ]
+ },
+ "codeeditor-desc": "Синтаксисан беснашца тадар JavaScript and CSSн [https://ace.c9.io/ Ace тадаран] гӀоьнца",
+ "codeeditor-save-with-errors": "Документан чохь гӀалаташ ду. Лаьий хьуна, и дӀаяздан?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/cs.json b/www/wiki/extensions/CodeEditor/i18n/cs.json
new file mode 100644
index 00000000..afd2d31c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/cs.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mormegil",
+ "Matěj Suchánek"
+ ]
+ },
+ "codeeditor-desc": "Editace stránek s JavaScriptem a CSS se zvýrazňováním syntaxe prostřednictvím [https://ace.c9.io/ editoru Ace]",
+ "codeeditor-next-annotation": "Přejít k další anotaci",
+ "codeeditor-toolbar-toggle": "Přepnout editor kódu",
+ "codeeditor-save-with-errors": "Tento dokument obsahuje chyby. Určitě ho chcete uložit?",
+ "codeeditor-invisibleChars-toggle": "Přepnout neviditelné znaky",
+ "codeeditor-lineWrapping-toggle": "Přepnout zalamování řádků",
+ "codeeditor-searchReplace-toggle": "Přepnout okno pro hledání a náhrady",
+ "codeeditor-gotoline": "Jít na číslo řádku…",
+ "codeeditor-gotoline-placeholder": "řádek[:sloupec]",
+ "codeeditor-gotoline-prompt": "Zadejte číslo řádku",
+ "codeeditor-indent": "Odsadit",
+ "codeeditor-outdent": "Zmenšit odsazení",
+ "codeeditor-error-title": "Nevyplněná závislost",
+ "codeeditor-error-message": "CodeEditor vyžaduje, aby byl načten WikiEditor."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/da.json b/www/wiki/extensions/CodeEditor/i18n/da.json
new file mode 100644
index 00000000..0f544c38
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/da.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Christian List",
+ "Peter Alberti",
+ "BoBrandt"
+ ]
+ },
+ "codeeditor-desc": "Syntaks-fremhævet redigering for JavaScript- og CSS-sider ved hjælp af [https://ace.c9.io/ Ace editor]",
+ "codeeditor-next-annotation": "Gå til den næste anmærkning",
+ "codeeditor-toolbar-toggle": "Slå kodeeditoren til/fra",
+ "codeeditor-save-with-errors": "Dokumentet indeholder fejl. Er du sikker på, at du vil gemme?",
+ "codeeditor-invisibleChars-toggle": "Slå usynlige tegn til eller fra",
+ "codeeditor-lineWrapping-toggle": "Slå linjeombrydning til eller fra",
+ "codeeditor-searchReplace-toggle": "Slå dialogboksen søg og erstat til eller fra",
+ "codeeditor-gotoline": "Gå til linje nummer...",
+ "codeeditor-gotoline-placeholder": "linje[:kolonne]",
+ "codeeditor-gotoline-prompt": "Angiv et linjenummer",
+ "codeeditor-indent": "Ryk ind",
+ "codeeditor-outdent": "Ryk ud",
+ "codeeditor-error-title": "Afhængighed mislykkedes",
+ "codeeditor-error-message": "CodeEditor kræver at WikiEditor indlæses."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/de.json b/www/wiki/extensions/CodeEditor/i18n/de.json
new file mode 100644
index 00000000..062f4e3c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/de.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kghbln",
+ "Metalhead64"
+ ]
+ },
+ "codeeditor-desc": "Ermöglicht das Bearbeiten von JavaScript und CSS mit Syntaxhervorhebung mithilfe des [https://ace.c9.io/ Ace-Editors]",
+ "codeeditor-next-annotation": "Zur nächsten Anmerkung gehen",
+ "codeeditor-toolbar-toggle": "Codeeditor ein- und ausschalten",
+ "codeeditor-save-with-errors": "Das Dokument enthält Fehler. Möchtest du wirklich speichern?",
+ "codeeditor-invisibleChars-toggle": "Unsichtbare Zeichen umschalten",
+ "codeeditor-lineWrapping-toggle": "Zeilenumbruch umschalten",
+ "codeeditor-searchReplace-toggle": "Suchen-und-Ersetzen-Dialog umschalten",
+ "codeeditor-gotoline": "Gehe zu Zeilennummer …",
+ "codeeditor-gotoline-placeholder": "Zeile[:Spalte]",
+ "codeeditor-gotoline-prompt": "Gib eine Zeilennummer ein",
+ "codeeditor-indent": "Einrücken",
+ "codeeditor-outdent": "Ausrücken",
+ "codeeditor-error-title": "Abhängigkeit fehlgeschlagen",
+ "codeeditor-error-message": "CodeEditor erfordert, dass der WikiEditor geladen wird."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/diq.json b/www/wiki/extensions/CodeEditor/i18n/diq.json
new file mode 100644
index 00000000..052ec145
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/diq.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Erdemaslancan",
+ "1917 Ekim Devrimi"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "Toggle kode editor",
+ "codeeditor-gotoline-placeholder": "Xet[:column]"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/dsb.json b/www/wiki/extensions/CodeEditor/i18n/dsb.json
new file mode 100644
index 00000000..49a85ecd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/dsb.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "codeeditor-desc": "Zmóžnja wobźěłowanje JavaScriptowych a CSS-bokow ze syntaksowym wuzwignjenim z pomocu [https://ace.c9.io/ editora Ace]",
+ "codeeditor-toolbar-toggle": "Kodowy editor zašaltowaś a wušaltowaś"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/el.json b/www/wiki/extensions/CodeEditor/i18n/el.json
new file mode 100644
index 00000000..7f5a5737
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/el.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Glavkos",
+ "Nikosgranturismogt"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "Επεξεργαστής κώδικα εναλλαγής",
+ "codeeditor-indent": "Οδόντωση"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/en.json b/www/wiki/extensions/CodeEditor/i18n/en.json
new file mode 100644
index 00000000..02b524aa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/en.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Brion Vibber",
+ "Derk-Jan Hartman"
+ ]
+ },
+ "codeeditor-desc": "Syntax-highlighted editing for JavaScript and CSS pages using [https://ace.c9.io/ Ace editor]",
+ "codeeditor-next-annotation": "Go to next annotation",
+ "codeeditor-toolbar-toggle": "Toggle code editor",
+ "codeeditor-save-with-errors": "The document contains errors. Are you sure you want to save?",
+ "codeeditor-invisibleChars-toggle": "Toggle invisible characters",
+ "codeeditor-lineWrapping-toggle": "Toggle line wrapping",
+ "codeeditor-searchReplace-toggle": "Toggle search and replace dialog",
+ "codeeditor-gotoline": "Go to line number...",
+ "codeeditor-gotoline-placeholder": "line[:column]",
+ "codeeditor-gotoline-prompt": "Enter a line number",
+ "codeeditor-indent": "Indent",
+ "codeeditor-outdent": "Outdent",
+ "codeeditor-error-title": "Dependency failed",
+ "codeeditor-error-message": "CodeEditor needs WikiEditor to be loaded."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/eo.json b/www/wiki/extensions/CodeEditor/i18n/eo.json
new file mode 100644
index 00000000..66f14f9f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/eo.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tlustulimu",
+ "Yekrats",
+ "KuboF"
+ ]
+ },
+ "codeeditor-desc": "Ebligas la redaktadon de JavaScript-aj kaj CSS-aj paĝoj kun sintaksa emfazo uzante [https://ace.c9.io/ Ace redaktilon]",
+ "codeeditor-toolbar-toggle": "Baskuli kodo-redaktilon",
+ "codeeditor-save-with-errors": "Tiu ĉi dokumento enhavas erarojn. Ĉu vi certas, ke vi volas konservi ĝin?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/es.json b/www/wiki/extensions/CodeEditor/i18n/es.json
new file mode 100644
index 00000000..28ec973a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/es.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armando-Martin",
+ "Fitoschido",
+ "Frammm",
+ "Macofe"
+ ]
+ },
+ "codeeditor-desc": "Edición de páginas con resaltado de sintaxis para JavaScript y CSS, usando [https://ace.c9.io el editor Ace]",
+ "codeeditor-next-annotation": "Ir a la anotación siguiente",
+ "codeeditor-toolbar-toggle": "Activar o desactivar el editor de código",
+ "codeeditor-save-with-errors": "El documento contiene errores. ¿Confirmas que quieres guardarlo?",
+ "codeeditor-invisibleChars-toggle": "Mostrar u ocultar los caracteres invisibles",
+ "codeeditor-lineWrapping-toggle": "Activar o desactivar el ajuste de renglones",
+ "codeeditor-searchReplace-toggle": "Mostrar u ocultar el cuadro de buscar y reemplazar",
+ "codeeditor-gotoline": "Ir al renglón…",
+ "codeeditor-gotoline-placeholder": "renglón[:carácter]",
+ "codeeditor-gotoline-prompt": "Digita un número de renglón",
+ "codeeditor-indent": "Añadir sangría",
+ "codeeditor-outdent": "Quitar sangría",
+ "codeeditor-error-title": "Fallo en la dependencia",
+ "codeeditor-error-message": "CodeEditor necesita que WikiEditor esté cargada."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/et.json b/www/wiki/extensions/CodeEditor/i18n/et.json
new file mode 100644
index 00000000..9fb01938
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/et.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Pikne"
+ ]
+ },
+ "codeeditor-desc": "JavaScripti ja CSSi redigeerimine süntaksi esiletõstuga, kasutades [https://ace.c9.io/ Ace-redaktorit]",
+ "codeeditor-next-annotation": "Mine järgmise märkuse juurde",
+ "codeeditor-toolbar-toggle": "Lülita koodiredaktor sisse või välja",
+ "codeeditor-save-with-errors": "Dokument sisaldab tõrkeid. Kas oled kindel, et tahad salvestada?",
+ "codeeditor-invisibleChars-toggle": "Lülita nähtamatud märgid sisse või välja",
+ "codeeditor-lineWrapping-toggle": "Lülita ridade murdmine sisse või välja",
+ "codeeditor-searchReplace-toggle": "Lülita otsimis- ja asendusdialoog sisse või välja",
+ "codeeditor-gotoline": "Mine reale number...",
+ "codeeditor-gotoline-placeholder": "rida[:veerg]",
+ "codeeditor-gotoline-prompt": "Sisesta reanumber",
+ "codeeditor-indent": "Suurenda taanet",
+ "codeeditor-outdent": "Vähenda taanet"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/fa.json b/www/wiki/extensions/CodeEditor/i18n/fa.json
new file mode 100644
index 00000000..2f03afbe
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/fa.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Reza1615",
+ "Rtemis",
+ "Ebraminio",
+ "Ladsgroup"
+ ]
+ },
+ "codeeditor-desc": "رنگی‌کنندهٔ ساختار زبانی برای جاوااسکریپت و صفحات سی‌اس‌اس از [https://ace.c9.io/ ویرایشگر آس] استفاده می‌کند",
+ "codeeditor-toolbar-toggle": "ضامن ویرایشگر کد",
+ "codeeditor-save-with-errors": "این سند دارای اشکال‌هایی است. اطمینان دارید که می‌خواهید ذخیره‌اش کنید؟",
+ "codeeditor-gotoline": "برو به خط شماره...",
+ "codeeditor-gotoline-placeholder": "شماره[:ستون]",
+ "codeeditor-gotoline-prompt": "یک شماره خط وارد کنید",
+ "codeeditor-indent": "تورفتگی",
+ "codeeditor-error-title": "وابستگی به خطا خورد"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/fi.json b/www/wiki/extensions/CodeEditor/i18n/fi.json
new file mode 100644
index 00000000..5efee0f5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/fi.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Nike"
+ ]
+ },
+ "codeeditor-desc": "Lisää syntaksinkorostuksen JavaScript ja CSS-sivuille käyttäen [https://ace.c9.io/ Ace-muokkainta]",
+ "codeeditor-toolbar-toggle": "Koodimuokkain",
+ "codeeditor-gotoline-placeholder": "rivi[:sarake]"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/fo.json b/www/wiki/extensions/CodeEditor/i18n/fo.json
new file mode 100644
index 00000000..1bb24bbd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/fo.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "EileenSanda"
+ ]
+ },
+ "codeeditor-desc": "Rætting við syntaks-hálýsing fyri JavaScript og CSS síður við at nýta [https://ace.c9.io/ Ace editor]",
+ "codeeditor-toolbar-toggle": "Slá koturættaran til ella frá",
+ "codeeditor-save-with-errors": "Skjalið inniheldur feilir. Er tað sikkurt at tú ynskir at goyma?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/fr.json b/www/wiki/extensions/CodeEditor/i18n/fr.json
new file mode 100644
index 00000000..b18f1d15
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/fr.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gomoko",
+ "Sherbrooke",
+ "Urhixidur",
+ "Wladek92",
+ "McDutchie",
+ "Thibaut120094"
+ ]
+ },
+ "codeeditor-desc": "Coloration syntaxique dans les pages écrites en JavaScript et CSS en utilisant l’[https://ace.c9.io/ Éditeur ACE]",
+ "codeeditor-next-annotation": "Allez à la prochaine annotation",
+ "codeeditor-toolbar-toggle": "Activer/désactiver l’éditeur de code",
+ "codeeditor-save-with-errors": "Le document contient des erreurs. Êtes-vous sûr de vouloir l’enregistrer ?",
+ "codeeditor-invisibleChars-toggle": "Afficher/masquer les caractères invisibles",
+ "codeeditor-lineWrapping-toggle": "Activer/désactiver le repli de ligne",
+ "codeeditor-searchReplace-toggle": "Afficher/masquer l'outil de recherche et de remplacement",
+ "codeeditor-gotoline": "Aller à la ligne numéro...",
+ "codeeditor-gotoline-placeholder": "ligne[:column]",
+ "codeeditor-gotoline-prompt": "Entrez un numéro de ligne",
+ "codeeditor-indent": "Indenter",
+ "codeeditor-outdent": "Remonter l'indentation",
+ "codeeditor-error-title": "Échec de la dépendance",
+ "codeeditor-error-message": "CodeEditor a besoin de WikiEditor pour être chargé."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/gl.json b/www/wiki/extensions/CodeEditor/i18n/gl.json
new file mode 100644
index 00000000..10679199
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/gl.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Toliño",
+ "Elisardojm",
+ "Banjo",
+ "McDutchie"
+ ]
+ },
+ "codeeditor-desc": "Edición de páxinas en JavaScript e CSS con realce sintáctico que emprega o [https://ace.c9.io/ editor Ace]",
+ "codeeditor-next-annotation": "Ir á anotación seguinte",
+ "codeeditor-toolbar-toggle": "Activar ou desactivar o editor de código",
+ "codeeditor-save-with-errors": "O documento contén varios erros. Está seguro de querer gardar o texto?",
+ "codeeditor-invisibleChars-toggle": "Amosar ou ocultar caracteres invisibles",
+ "codeeditor-lineWrapping-toggle": "Activar ou desactivar liñas envolventes",
+ "codeeditor-searchReplace-toggle": "Activar xanela de buscar e reemprazar",
+ "codeeditor-gotoline": "Ir á liña número...",
+ "codeeditor-gotoline-placeholder": "liña[:columna]",
+ "codeeditor-gotoline-prompt": "Introduce un número de liña",
+ "codeeditor-indent": "Engadir sangría",
+ "codeeditor-outdent": "Anular sangría",
+ "codeeditor-error-title": "Erro na dependencia",
+ "codeeditor-error-message": "O CodeEditor necesita o WikiEditor para cargarse."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/he.json b/www/wiki/extensions/CodeEditor/i18n/he.json
new file mode 100644
index 00000000..f7d252dc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/he.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "IKhitron",
+ "Guycn2"
+ ]
+ },
+ "codeeditor-desc": "עריכה עם צביעת קוד לדפים של JavaScript ושל CSS באמצעות [https://ace.c9.io/ עורך Ace]",
+ "codeeditor-next-annotation": "מעבר להערה הבאה",
+ "codeeditor-toolbar-toggle": "שינוי מצב עורך קוד",
+ "codeeditor-save-with-errors": "המסמך הזה מכיל שגיאות. האם ברצונך לשמור אותו?",
+ "codeeditor-invisibleChars-toggle": "הפעלת תווים בלתי־נראים",
+ "codeeditor-lineWrapping-toggle": "הפעלת גלישת שורות",
+ "codeeditor-searchReplace-toggle": "הפעלת חלונית חיפוש והחלפה",
+ "codeeditor-gotoline": "מעבר לשורה מספר...",
+ "codeeditor-gotoline-placeholder": "שורה[:עמודה]",
+ "codeeditor-gotoline-prompt": "נא להזין מספר של שורה",
+ "codeeditor-indent": "הזחה",
+ "codeeditor-outdent": "הרחקת הזחה",
+ "codeeditor-error-title": "חסר מודול תלוי",
+ "codeeditor-error-message": "ההרחבה CodeEditor דורשת ש־WikiEditor יהיה טעון."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/hi.json b/www/wiki/extensions/CodeEditor/i18n/hi.json
new file mode 100644
index 00000000..5467e0b0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/hi.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Siddhartha Ghai"
+ ]
+ },
+ "codeeditor-desc": "जावास्क्रिप्ट और सीएसएस पृष्ठों के सम्पादन के लिये सिंटेक्स-हाइलाइट करने हेतु [https://ace.c9.io/ ऐस सम्पादक]",
+ "codeeditor-toolbar-toggle": "कोड सम्पादक ऑन/ऑफ़ करें"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/hr.json b/www/wiki/extensions/CodeEditor/i18n/hr.json
new file mode 100644
index 00000000..8956face
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/hr.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "MaGa"
+ ]
+ },
+ "codeeditor-next-annotation": "Idi na sljedeću bilješku",
+ "codeeditor-toolbar-toggle": "Uključi/isključi uređivač kôda",
+ "codeeditor-save-with-errors": "Postoje pogrješke u dokumentu. Jeste li sigurni da ga želite spremiti?",
+ "codeeditor-invisibleChars-toggle": "Prikaži/sakrij nevidljive znakove",
+ "codeeditor-lineWrapping-toggle": "Uključi/isključi prijelom redova",
+ "codeeditor-searchReplace-toggle": "Uključi/isključi dijalog za pretragu i zamjenu",
+ "codeeditor-gotoline": "Idi na red broj...",
+ "codeeditor-gotoline-placeholder": "red[:stupac]",
+ "codeeditor-gotoline-prompt": "Unesite broj reda",
+ "codeeditor-indent": "Uvlaka",
+ "codeeditor-outdent": "Izvlaka"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/hsb.json b/www/wiki/extensions/CodeEditor/i18n/hsb.json
new file mode 100644
index 00000000..27c27df6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/hsb.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "codeeditor-desc": "Zmóžnja wobdźěłowanje JavaScriptowych a CSS-stronow ze syntaksowym wuzběhnjenjom z pomocu [https://ace.c9.io/ editora Ace]",
+ "codeeditor-toolbar-toggle": "Kodowy editor zapinać a wupinać"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/hu.json b/www/wiki/extensions/CodeEditor/i18n/hu.json
new file mode 100644
index 00000000..5375b64e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/hu.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dani",
+ "Misibacsi",
+ "Tacsipacsi"
+ ]
+ },
+ "codeeditor-desc": "Szintaxiskiemeléssel segített szerkesztés JavaScript- és CSS-lapok szerkesztésekor az [https://ace.c9.io/ Ace szerkesztővel]",
+ "codeeditor-next-annotation": "Következő jegyzet",
+ "codeeditor-toolbar-toggle": "A kódszerkesztő ki- vagy bekapcsolása",
+ "codeeditor-save-with-errors": "A dokumentum hibát tartalmaz. Biztosan el akarod menteni?",
+ "codeeditor-invisibleChars-toggle": "Láthatatlan karakterek",
+ "codeeditor-lineWrapping-toggle": "Hosszú sorok tördelése",
+ "codeeditor-searchReplace-toggle": "Keresés és csere",
+ "codeeditor-gotoline": "Sorszámra ugrás…",
+ "codeeditor-gotoline-placeholder": "sor[:oszlop]",
+ "codeeditor-gotoline-prompt": "Írj be egy sorszámot",
+ "codeeditor-indent": "Behúzás növelése",
+ "codeeditor-outdent": "Behúzás csökkentése"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ia.json b/www/wiki/extensions/CodeEditor/i18n/ia.json
new file mode 100644
index 00000000..097ad5fd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ia.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "McDutchie"
+ ]
+ },
+ "codeeditor-desc": "Modification con coloration syntactic pro paginas con JavaScript e CSS usante le [https://ace.c9.io/ editor Ace]",
+ "codeeditor-next-annotation": "Annotation sequente",
+ "codeeditor-toolbar-toggle": "Activar o disactivar le editor de codice",
+ "codeeditor-save-with-errors": "Le documento contine errores. Es tu secur de voler salveguardar lo?",
+ "codeeditor-invisibleChars-toggle": "Alternar characteres invisibile",
+ "codeeditor-lineWrapping-toggle": "Alternar ruptura de lineas",
+ "codeeditor-searchReplace-toggle": "Alternar dialogo cercar e reimplaciar",
+ "codeeditor-gotoline": "Vader al linea numero...",
+ "codeeditor-gotoline-placeholder": "linea[:columna]",
+ "codeeditor-gotoline-prompt": "Entra un numero de linea",
+ "codeeditor-indent": "Indentar",
+ "codeeditor-outdent": "Disindentar",
+ "codeeditor-error-title": "Dependentia fallite",
+ "codeeditor-error-message": "CodeEditor require que WikiEditor es cargate."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/id.json b/www/wiki/extensions/CodeEditor/i18n/id.json
new file mode 100644
index 00000000..1a3e3a04
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/id.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Farras",
+ "William Surya Permana"
+ ]
+ },
+ "codeeditor-desc": "Penyuntingan dengan penyorotan sintaks untuk halaman JavaScript dan CSS menggunakan [https://ace.c9.io/ penyunting Ace]",
+ "codeeditor-toolbar-toggle": "Aktifkan/Nonaktifkan penyunting kode",
+ "codeeditor-save-with-errors": "Dokumen mengandung galat. Apakah Anda yakin ingin menyimpan?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ilo.json b/www/wiki/extensions/CodeEditor/i18n/ilo.json
new file mode 100644
index 00000000..4f388749
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ilo.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lam-ang"
+ ]
+ },
+ "codeeditor-desc": "Naparaigidan a gramatika ti panagurnos para kadagiti panid ti JavaScript ken CSS nga agus-usar ti [https://ace.c9.io/ Ace editor]",
+ "codeeditor-toolbar-toggle": "Kutien ti panagurnos ti kodigo",
+ "codeeditor-save-with-errors": "Ti dokumento ket aglaon kadagiti biddut. Siguradoka kadi a kayatmo nga idulin?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/is.json b/www/wiki/extensions/CodeEditor/i18n/is.json
new file mode 100644
index 00000000..c74a2d06
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/is.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Snævar",
+ "Sveinn í Felli"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "Kveikja/slökkva á kóða ritlinum",
+ "codeeditor-save-with-errors": "Skjalið inniheldur villur. Ertu viss um að þú viljir vista ?",
+ "codeeditor-invisibleChars-toggle": "Kveikja/slökkva á ósýnilegum stöfum",
+ "codeeditor-gotoline": "Fara á línu númer...",
+ "codeeditor-gotoline-placeholder": "lína[:dálkur]",
+ "codeeditor-indent": "Inndráttur"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/it.json b/www/wiki/extensions/CodeEditor/i18n/it.json
new file mode 100644
index 00000000..012ca0e3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/it.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beta16",
+ "Alexmar983"
+ ]
+ },
+ "codeeditor-desc": "Modifiche con evidenziazione della sintassi per pagine JavaScript e CSS utilizzando [https://ace.c9.io/ l'editor Ace]",
+ "codeeditor-next-annotation": "Vai alla prossima annotazione",
+ "codeeditor-toolbar-toggle": "Attivare o disattivare l'editor di codice",
+ "codeeditor-save-with-errors": "Il documento contiene errori. Sei sicuro di voler salvare?",
+ "codeeditor-invisibleChars-toggle": "Mostra/nascondi caratteri invisibili",
+ "codeeditor-lineWrapping-toggle": "Attiva/disattiva ritorno a capo automatico",
+ "codeeditor-searchReplace-toggle": "Mostra/nascondi cerca e sostituisci",
+ "codeeditor-gotoline": "Vai alla riga numero...",
+ "codeeditor-gotoline-placeholder": "linea[:colonna]",
+ "codeeditor-indent": "Rientro",
+ "codeeditor-outdent": "rientro negativo"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ja.json b/www/wiki/extensions/CodeEditor/i18n/ja.json
new file mode 100644
index 00000000..b6a3e15e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ja.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Schu",
+ "Shirayuki",
+ "Fryed-peach",
+ "Otokoume",
+ "Yusuke1109"
+ ]
+ },
+ "codeeditor-desc": "[https://ace.c9.io/ Ace editor]を用いた、JavaScript/CSS の構文ハイライト機能付きのページ編集",
+ "codeeditor-next-annotation": "次のアノテーションに移動",
+ "codeeditor-toolbar-toggle": "コード エディターの切り替え",
+ "codeeditor-save-with-errors": "このドキュメントにはエラーが含まれています。保存してもよろしいですか?",
+ "codeeditor-lineWrapping-toggle": "改行を切り替える",
+ "codeeditor-gotoline-prompt": "行番号を入力してください",
+ "codeeditor-indent": "インデント",
+ "codeeditor-outdent": "アウトデント",
+ "codeeditor-error-message": "CodeEditorはWikiEditorを読み込む必要があります。"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ka.json b/www/wiki/extensions/CodeEditor/i18n/ka.json
new file mode 100644
index 00000000..0b3b1c43
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ka.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "David1010",
+ "Otogi"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "რედაქტორის გადამრთველის კოდი",
+ "codeeditor-save-with-errors": "დოკუმენტი შეცდომებს შეიცავს. ნამდვილად გსურთ მისი შენახვა?",
+ "codeeditor-invisibleChars-toggle": "უხილავი სიმბოლოების გამოსახულების გადართვა",
+ "codeeditor-lineWrapping-toggle": "ხაზების გადატანის გადასვლა",
+ "codeeditor-searchReplace-toggle": "ძიების დიალოგის გამოსახულების გადართვა და ტექსტის შეცვლა",
+ "codeeditor-gotoline": "გადასვლა ხაზზე ნომერი...",
+ "codeeditor-indent": "შეწევა",
+ "codeeditor-outdent": "გადაწევა მარცხნივ"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/kk-cyrl.json b/www/wiki/extensions/CodeEditor/i18n/kk-cyrl.json
new file mode 100644
index 00000000..b282d66f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/kk-cyrl.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arystanbek"
+ ]
+ },
+ "codeeditor-save-with-errors": "Құжат қателерден тұрады. Шынымен сақтағыңыз келе ме?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/km.json b/www/wiki/extensions/CodeEditor/i18n/km.json
new file mode 100644
index 00000000..47e78bab
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/km.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sovichet"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "បិទ​បើក​កម្មវិធី​កែសម្រួល​កូដ"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ko.json b/www/wiki/extensions/CodeEditor/i18n/ko.json
new file mode 100644
index 00000000..ce805e62
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ko.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "아라",
+ "IRTC1015",
+ "Alex00728",
+ "Kwj2772",
+ "Ykhwong"
+ ]
+ },
+ "codeeditor-desc": "[https://ace.c9.io/ Ace 편집기]를 사용하여 자바스크립트와 CSS 문서에 구문을 강조하는 기능의 편집",
+ "codeeditor-next-annotation": "다음 주석 보기",
+ "codeeditor-toolbar-toggle": "코드 편집기 전환",
+ "codeeditor-save-with-errors": "문서에 오류가 들어 있습니다. 저장하겠습니까?",
+ "codeeditor-gotoline": "...줄로 넘어가기",
+ "codeeditor-gotoline-prompt": "줄 번호를 입력하십시오",
+ "codeeditor-indent": "들여쓰기",
+ "codeeditor-outdent": "내어쓰기",
+ "codeeditor-error-title": "의존성 실패",
+ "codeeditor-error-message": "코드편집기를 사용하려면 위키편집기를 로드해야 합니다."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ksh.json b/www/wiki/extensions/CodeEditor/i18n/ksh.json
new file mode 100644
index 00000000..45e06a07
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ksh.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha"
+ ]
+ },
+ "codeeditor-desc": "JavaSkrep- un <i lang=\"en\">CSS</i>-Sigge mem <i lang=\"en\">[https://ace.c9.io/ Ace Editor]</i> beärbeide, woh de Syntax bunnt aanjemohld es.",
+ "codeeditor-next-annotation": "Jangk op de nähxte Aanmärkong",
+ "codeeditor-toolbar-toggle": "Et Kood-Beärbeide ömschallde",
+ "codeeditor-save-with-errors": "Heh sen Fähler dren. Wells De dat trozdämm faßjehallde han?",
+ "codeeditor-invisibleChars-toggle": "donn de jewöhnlesch onseeschbaa Zeijsche ömschallde zwesche seeschbaa jemaad un onseeschbaa",
+ "codeeditor-lineWrapping-toggle": "Donn der Ömbroch för et Aanzeije om Belldscherrem ömmschallde",
+ "codeeditor-searchReplace-toggle": "Ömschallde zwesche „Ennföhje“ un „Ußtuusche“",
+ "codeeditor-gotoline": "Jangk noh dä Reih met dä Nommer …",
+ "codeeditor-indent": "Ennröke",
+ "codeeditor-outdent": "Ußröke"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/lb.json b/www/wiki/extensions/CodeEditor/i18n/lb.json
new file mode 100644
index 00000000..b4d1d0c6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/lb.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robby"
+ ]
+ },
+ "codeeditor-desc": "Ännere vu JavaScript an CSS-Säite mam [https://ace.c9.io/ Ace editor] deen d'Syntax faarweg duerstellt",
+ "codeeditor-next-annotation": "Op déi nächst Notiz goen",
+ "codeeditor-toolbar-toggle": "Editeur vum Code an- an ausschalten",
+ "codeeditor-save-with-errors": "Et si Feeler am Dokument. Sidd Dir sécher datt dir e et späichere wëllt?",
+ "codeeditor-gotoline": "Gitt op d'Linn mat der Nummer...",
+ "codeeditor-indent": "Eraréckelen",
+ "codeeditor-outdent": "Erausréckelen",
+ "codeeditor-error-message": "Fir CodeEditor muss de WikiEditor geluede ginn."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/li.json b/www/wiki/extensions/CodeEditor/i18n/li.json
new file mode 100644
index 00000000..1c63b000
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/li.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Pahles",
+ "Ooswesthoesbes"
+ ]
+ },
+ "codeeditor-desc": "Syntaxis-gemarkeerd bewirke veur JavaScript- en CSS-pagina's mit behölp van de [https://ace.c9.io/ Ace-teksbewirker]",
+ "codeeditor-next-annotation": "Gank nao de volgende annotasie",
+ "codeeditor-toolbar-toggle": "Codeteksverwirker in- of oetsjakele",
+ "codeeditor-save-with-errors": "'t Document haet foute. Wits se zeker det se 'm wils opslaon?",
+ "codeeditor-invisibleChars-toggle": "Tuin of verstaek ónzichbaar teikes",
+ "codeeditor-lineWrapping-toggle": "Zèt regelómslaag aan of oet",
+ "codeeditor-searchReplace-toggle": "Zèt zeuk-en-vervangdialoog aan of oet",
+ "codeeditor-gotoline": "Gank nao regelnómmer...",
+ "codeeditor-gotoline-placeholder": "regel[:kolom]",
+ "codeeditor-gotoline-prompt": "Veur e regelnómmer in",
+ "codeeditor-indent": "Spring in",
+ "codeeditor-outdent": "Spring oet",
+ "codeeditor-error-title": "Aafhenkelikheid mislök",
+ "codeeditor-error-message": "Veur de CodeEditor mót de WikiEditor gelaje zeen."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/lij.json b/www/wiki/extensions/CodeEditor/i18n/lij.json
new file mode 100644
index 00000000..8be5ade9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/lij.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Giromin Cangiaxo"
+ ]
+ },
+ "codeeditor-desc": "Modiffiche con evidençiaçion da scintasci pe-e paggine JavaScript e CSS doeuviando [https://ace.c9.io/ l'editor Ace]",
+ "codeeditor-next-annotation": "Vanni a-a proscima annotaçion",
+ "codeeditor-toolbar-toggle": "Attiva ò disattiva l'editor de codiçe",
+ "codeeditor-save-with-errors": "O documento o conten di erroî. T'ê seguo de voei sarvâ?",
+ "codeeditor-invisibleChars-toggle": "Mostra/ascondi i caratteri invixibbili",
+ "codeeditor-lineWrapping-toggle": "Attiva/disattiva o ritorno a cappo aotomattico",
+ "codeeditor-searchReplace-toggle": "Mostra/ascondi o \"çerca e sostituisci\"",
+ "codeeditor-gotoline": "Vanni a-a riga nummero...",
+ "codeeditor-indent": "Indentâ",
+ "codeeditor-outdent": "Leva indentaçion"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/lt.json b/www/wiki/extensions/CodeEditor/i18n/lt.json
new file mode 100644
index 00000000..e33b51e5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/lt.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eitvys200",
+ "Manvydasz"
+ ]
+ },
+ "codeeditor-next-annotation": "Eiti prie kitos anotacijos",
+ "codeeditor-save-with-errors": "Dokumente yra klaidų. Ar tikrai norite išsaugoti?",
+ "codeeditor-gotoline": "Eiti į eilutės numerį...",
+ "codeeditor-gotoline-placeholder": "eilutė[:stulpelis]",
+ "codeeditor-gotoline-prompt": "Įvesti eilutės numerį",
+ "codeeditor-indent": "Įtrauka"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/lv.json b/www/wiki/extensions/CodeEditor/i18n/lv.json
new file mode 100644
index 00000000..d491f334
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/lv.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Papuass"
+ ]
+ },
+ "codeeditor-next-annotation": "Pāriet uz nākamo anotāciju",
+ "codeeditor-toolbar-toggle": "Pārslēgt koda redaktoru",
+ "codeeditor-invisibleChars-toggle": "Pārslēgt neredzamās rakstzīmes",
+ "codeeditor-lineWrapping-toggle": "Pārslēgt rindu aplaušanu",
+ "codeeditor-gotoline": "Doties uz rindiņas numuru..."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/mk.json b/www/wiki/extensions/CodeEditor/i18n/mk.json
new file mode 100644
index 00000000..ef269534
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/mk.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06"
+ ]
+ },
+ "codeeditor-desc": "Уредување со истакната синтакса за JavaScript и каскадни стилски страници (CSS) користејќи го уредникот [https://ace.c9.io/ Ace]",
+ "codeeditor-next-annotation": "Оди на следната прибелешка",
+ "codeeditor-toolbar-toggle": "Префрли на уредникот на кодот",
+ "codeeditor-save-with-errors": "Документот содржи грешки. Сигурно сакате да го зачувате?",
+ "codeeditor-invisibleChars-toggle": "Вкл/искл. невидливи знаци",
+ "codeeditor-lineWrapping-toggle": "Вкл/искл. прелом",
+ "codeeditor-searchReplace-toggle": "Вкл./искл. дијалог за пребарување и замена",
+ "codeeditor-gotoline": "Оди на ред број...",
+ "codeeditor-gotoline-placeholder": "ред[:столб]",
+ "codeeditor-gotoline-prompt": "Внесете број на ред",
+ "codeeditor-indent": "Отстап",
+ "codeeditor-outdent": "Истап",
+ "codeeditor-error-title": "Зависноста не успеа",
+ "codeeditor-error-message": "На Уредникот на код му треба Викиуредник за да се вчита."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ml.json b/www/wiki/extensions/CodeEditor/i18n/ml.json
new file mode 100644
index 00000000..3a6576dc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ml.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Praveenp"
+ ]
+ },
+ "codeeditor-desc": "[https://ace.c9.io/ ഏയ്സ് എഡിറ്റർ] ഉപയോഗിച്ച് ജാവാസ്ക്രിപ്റ്റ്, സി.എസ്.എസ്. താളുകൾ എഴുത്തുരീതി പ്രമുഖമാക്കി തിരുത്തുവാനുള്ള സൗകര്യം.",
+ "codeeditor-toolbar-toggle": "കോഡ് തിരുത്തലുപാധി ഉപയോഗിക്കുക / ഒഴിവാക്കുക",
+ "codeeditor-save-with-errors": "എഴുത്തിൽ പിഴവുകളുണ്ട്. സേവ് ചെയ്യണമെന്നുറപ്പാണോ?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ms.json b/www/wiki/extensions/CodeEditor/i18n/ms.json
new file mode 100644
index 00000000..8da16dfd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ms.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia",
+ "Aviator"
+ ]
+ },
+ "codeeditor-desc": "Penyuntingan tonjolan sintaks untuk laman-laman JavaScript dan CSS dengan menggunakan [https://ace.c9.io/ penyunting Ace]",
+ "codeeditor-toolbar-toggle": "Anjak penyunting kod",
+ "codeeditor-save-with-errors": "Dokumen ini mengandungi ralat. Adakah anda pasti anda mahu menyimpan?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/mt.json b/www/wiki/extensions/CodeEditor/i18n/mt.json
new file mode 100644
index 00000000..4dc4d8f2
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/mt.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chrisportelli"
+ ]
+ },
+ "codeeditor-desc": "Modifiki bis-sintassi mdawwal (''highlighted'') għall-paġni tal-JavaScript u CSS bl-użu tal-[https://ace.c9.io/ editur Ace]",
+ "codeeditor-toolbar-toggle": "Attiva jew iddiżattiva l-editur tal-kodiċi"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/nb.json b/www/wiki/extensions/CodeEditor/i18n/nb.json
new file mode 100644
index 00000000..898751d6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/nb.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Danmichaelo",
+ "Event",
+ "SuperPotato",
+ "Jon Harald Søby"
+ ]
+ },
+ "codeeditor-desc": "Syntaksfremhevet redigering av JavaScript og CSS-sider med bruk av [https://ace.c9.io/ Ace editor]",
+ "codeeditor-next-annotation": "Gå til neste annotering",
+ "codeeditor-toolbar-toggle": "Slå på/av kodeeditoren",
+ "codeeditor-save-with-errors": "Dette dokumentet inneholder feil. Er du sikker på at du vil lagre?",
+ "codeeditor-invisibleChars-toggle": "Slå av/på usynlige tegn",
+ "codeeditor-lineWrapping-toggle": "Slå av/på linjebryting",
+ "codeeditor-searchReplace-toggle": "Slå av/på søk- og erstatt-vinduet",
+ "codeeditor-gotoline": "Gå til linje nummer ...",
+ "codeeditor-gotoline-placeholder": "linje[:kolonne]",
+ "codeeditor-gotoline-prompt": "Skriv inn et linjenummer",
+ "codeeditor-indent": "Rykk inn",
+ "codeeditor-outdent": "Rykk ut",
+ "codeeditor-error-title": "Avhengighet feilet",
+ "codeeditor-error-message": "CodeEditor trenger WikiEditor for å kunne lastes."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/nl.json b/www/wiki/extensions/CodeEditor/i18n/nl.json
new file mode 100644
index 00000000..65d1791c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/nl.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "SPQRobin",
+ "Siebrand",
+ "Southparkfan",
+ "Esketti",
+ "Mainframe98",
+ "McDutchie"
+ ]
+ },
+ "codeeditor-desc": "Syntaxis-gemarkeerd bewerken voor JavaScript- en CSS-pagina's met behulp van de [https://ace.c9.io/ Ace-tekstverwerker]",
+ "codeeditor-next-annotation": "Ga naar de volgende annotatie",
+ "codeeditor-toolbar-toggle": "Codetekstverwerker in- of uitschakelen",
+ "codeeditor-save-with-errors": "Het document bevat fouten. Weet u zeker dat u het wilt opslaan?",
+ "codeeditor-invisibleChars-toggle": "Onzichtbare tekens tonen of verbergen",
+ "codeeditor-lineWrapping-toggle": "Regelomslag aan- of uitzetten",
+ "codeeditor-searchReplace-toggle": "Schakelen dialoogvenster zoeken en vervangen",
+ "codeeditor-gotoline": "Ga naar regelnummer...",
+ "codeeditor-gotoline-placeholder": "regel[:kolom]",
+ "codeeditor-gotoline-prompt": "Voer een regelnummer in",
+ "codeeditor-indent": "Inspringen",
+ "codeeditor-outdent": "Uitspringen"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/nn.json b/www/wiki/extensions/CodeEditor/i18n/nn.json
new file mode 100644
index 00000000..d3021d05
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/nn.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Njardarlogar"
+ ]
+ },
+ "codeeditor-desc": "Syntaksframheva endring for JavaScript- og CSS-sider gjennom [https://ace.c9.io/ Ace-tekstendraren]",
+ "codeeditor-next-annotation": "Gå til neste merknad",
+ "codeeditor-toolbar-toggle": "Slå av eller på kodehandsamar",
+ "codeeditor-save-with-errors": "Dokumentet inneheld feil. Er du viss på at du ynskjer å lagra?",
+ "codeeditor-invisibleChars-toggle": "Slå av eller på usynlege teikn",
+ "codeeditor-lineWrapping-toggle": "Slå av eller på lineknekking",
+ "codeeditor-searchReplace-toggle": "Slå av eller på søk-og-byt ut-dialog",
+ "codeeditor-gotoline": "Gå til line nummer …",
+ "codeeditor-gotoline-placeholder": "line[:kolonne]",
+ "codeeditor-gotoline-prompt": "Skriv inn eit linenummer",
+ "codeeditor-indent": "Innrykk",
+ "codeeditor-outdent": "Utrykk"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/pl.json b/www/wiki/extensions/CodeEditor/i18n/pl.json
new file mode 100644
index 00000000..d203e638
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/pl.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "BeginaFelicysym",
+ "Sp5uhe",
+ "Woytecr",
+ "Chrumps",
+ "WTM",
+ "Railfail536"
+ ]
+ },
+ "codeeditor-desc": "Edytowanie stron z kolorowaniem składni JavaScript oraz CSS z użyciem [https://ace.c9.io/ edytora Ace]",
+ "codeeditor-next-annotation": "Do następnej",
+ "codeeditor-toolbar-toggle": "Przełącz edytor kodu",
+ "codeeditor-save-with-errors": "Dokument zawiera błędy. Czy na pewno chcesz zapisać?",
+ "codeeditor-invisibleChars-toggle": "Przełączanie wyświetlania niewidocznych znaków",
+ "codeeditor-lineWrapping-toggle": "Przełączanie zawijania wierszy",
+ "codeeditor-searchReplace-toggle": "Okienko dialogowe wyszukiwania i zamiany tekstu",
+ "codeeditor-gotoline": "Przejdź do linii numer...",
+ "codeeditor-gotoline-placeholder": "linia[:kolumna]",
+ "codeeditor-gotoline-prompt": "Wprowadź numer wiersza",
+ "codeeditor-indent": "Zwiększ wcięcie",
+ "codeeditor-outdent": "Zmniejsz wcięcie",
+ "codeeditor-error-title": "Zależność nie powiodła się",
+ "codeeditor-error-message": "CodeEditor wymaga do działania rozszerzenia WikiEditor"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/pms.json b/www/wiki/extensions/CodeEditor/i18n/pms.json
new file mode 100644
index 00000000..146d7510
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/pms.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Borichèt",
+ "Dragonòt"
+ ]
+ },
+ "codeeditor-desc": "Colorassion sintàtica ëd le pàgine scrivùe an JavaScript e CSS an dovrand l'[https://ace.c9.io/ editor Ace]",
+ "codeeditor-toolbar-toggle": "Ativé o disativé l'editor ëd còdes"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/pt-br.json b/www/wiki/extensions/CodeEditor/i18n/pt-br.json
new file mode 100644
index 00000000..74f12e2d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/pt-br.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cainamarques",
+ "Dianakc",
+ "Felipe L. Ewald"
+ ]
+ },
+ "codeeditor-desc": "Edição de páginas JavaScript e CSS com realce de sintaxe, utilizando o [https://ace.c9.io/ editor Ace]",
+ "codeeditor-next-annotation": "Ir para a próxima anotação",
+ "codeeditor-toolbar-toggle": "Ativar/desativar editor de código",
+ "codeeditor-save-with-errors": "O documento contém erros. Tem certeza de que deseja salvar?",
+ "codeeditor-invisibleChars-toggle": "Alternar caracteres invisíveis",
+ "codeeditor-lineWrapping-toggle": "Alternar a quebra de linhas",
+ "codeeditor-searchReplace-toggle": "Recolher diálogo de pesquisa e substituir",
+ "codeeditor-gotoline": "Ir para o número de linha...",
+ "codeeditor-gotoline-placeholder": "linha[:coluna]",
+ "codeeditor-gotoline-prompt": "Insira um número de linha",
+ "codeeditor-indent": "Indentação",
+ "codeeditor-outdent": "Recuo",
+ "codeeditor-error-title": "Falha na dependência",
+ "codeeditor-error-message": "CodeEditor precisa do WikiEditor para ser carregado."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/pt.json b/www/wiki/extensions/CodeEditor/i18n/pt.json
new file mode 100644
index 00000000..00500c2f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/pt.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hamilton Abreu",
+ "Malafaya",
+ "Imperadeiro98",
+ "Fúlvio",
+ "Vitorvicentevalente"
+ ]
+ },
+ "codeeditor-desc": "Edição de páginas JavaScript ou CSS com realce sintático, usando o [https://ace.c9.io/ editor Ace]",
+ "codeeditor-next-annotation": "Ir para a próxima anotação",
+ "codeeditor-toolbar-toggle": "Ativar/desativar o editor de código",
+ "codeeditor-save-with-errors": "O documento contém erros. Tem a certeza de que quer gravar?",
+ "codeeditor-invisibleChars-toggle": "Mostrar ou ocultar caracteres invisíveis",
+ "codeeditor-lineWrapping-toggle": "Ativar ou desativar a quebra de linha",
+ "codeeditor-searchReplace-toggle": "Mostrar ou ocultar o diálogo de localizar e substituir",
+ "codeeditor-gotoline": "Ir para a linha número...",
+ "codeeditor-gotoline-placeholder": "linha[:coluna]",
+ "codeeditor-gotoline-prompt": "Introduza um número de linha",
+ "codeeditor-indent": "Adicionar indentação",
+ "codeeditor-outdent": "Eliminar indentação",
+ "codeeditor-error-title": "Erro na dependência",
+ "codeeditor-error-message": "O CodeEditor precisa que o WikiEditor seja carregado."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/qqq.json b/www/wiki/extensions/CodeEditor/i18n/qqq.json
new file mode 100644
index 00000000..234b6425
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/qqq.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha",
+ "Shirayuki",
+ "Derk-Jan Hartman",
+ "Umherirrender",
+ "Tacsipacsi"
+ ]
+ },
+ "codeeditor-desc": "{{desc|name=Code Editor|url=https://www.mediawiki.org/wiki/Extension:CodeEditor}}",
+ "codeeditor-next-annotation": "Used as a label for button to navigate to the next line in the editor that has an annotation",
+ "codeeditor-toolbar-toggle": "Used as label for toolbar button.",
+ "codeeditor-save-with-errors": "Used as message in a dialog before saving a document with errors.",
+ "codeeditor-invisibleChars-toggle": "Used as label for toolbar button to show/hide non visible characters",
+ "codeeditor-lineWrapping-toggle": "Used as label for toolbar button to enable/disable wrapping of long lines on the screen (this doesn’t modify the saved text).",
+ "codeeditor-searchReplace-toggle": "Used as label for toolbar button to show/hide the search and replace dialog",
+ "codeeditor-gotoline": "Used as a label for toolbar button to navigate to a line number in the editor",
+ "codeeditor-gotoline-placeholder": "Placeholder for goto line prompt's input",
+ "codeeditor-gotoline-prompt": "Label for goto line prompt",
+ "codeeditor-indent": "Used as a label for toolbar button to indent text in the editor",
+ "codeeditor-outdent": "Used as a label for toolbar button to outdent text in the editor",
+ "codeeditor-error-title": "Used as a title when there is a missing dependency",
+ "codeeditor-error-message": "Explains the dependency on WikiEditor"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ro.json b/www/wiki/extensions/CodeEditor/i18n/ro.json
new file mode 100644
index 00000000..b8836fb6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ro.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minisarm",
+ "Strainu"
+ ]
+ },
+ "codeeditor-desc": "Editare prin evidențierea sintaxei pentru pagini JavaScript și CSS utilizând [https://ace.c9.io/ editorul Ace]",
+ "codeeditor-next-annotation": "Mergi la următoarea adnotare",
+ "codeeditor-toolbar-toggle": "Activează/dezactivează editorul de cod",
+ "codeeditor-save-with-errors": "Documentul conține erori. Sunteți sigur că doriți să-l salvați?",
+ "codeeditor-gotoline": "Mergi la linia numărul...",
+ "codeeditor-gotoline-placeholder": "linie[:coloană]",
+ "codeeditor-gotoline-prompt": "Introduceți un număr de linie",
+ "codeeditor-indent": "Indentare",
+ "codeeditor-outdent": "Indentare exterioară",
+ "codeeditor-error-title": "Dependința nu a fost găsită",
+ "codeeditor-error-message": "CodeEditor are nevoie ca WikiEditor să fie încărcat."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/roa-tara.json b/www/wiki/extensions/CodeEditor/i18n/roa-tara.json
new file mode 100644
index 00000000..4f337a77
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/roa-tara.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras"
+ ]
+ },
+ "codeeditor-desc": "Cangiaminde cu l'evidenze d'a sindasse pe le pàggene JavaScript e CSS ca ausane [https://ace.c9.io/ l'editore Ace]",
+ "codeeditor-next-annotation": "Vèje 'a prossime annotazzione",
+ "codeeditor-toolbar-toggle": "Live e mitte 'u cangiatore de codece",
+ "codeeditor-save-with-errors": "'U documende tène errore. Sì secure ca 'u vue ccu reggistre?",
+ "codeeditor-invisibleChars-toggle": "Live e mitte le carattere invisibbile",
+ "codeeditor-lineWrapping-toggle": "Live e mitte le linèe a cape",
+ "codeeditor-searchReplace-toggle": "Live e mitte 'u module de cirche e sostituisce",
+ "codeeditor-gotoline": "Vèje a 'u numere de linèe...",
+ "codeeditor-gotoline-placeholder": "linèe[:colonne]",
+ "codeeditor-gotoline-prompt": "Sckaffe 'nu numere de linèe",
+ "codeeditor-indent": "Mitte jndre",
+ "codeeditor-outdent": "Mitte fore",
+ "codeeditor-error-title": "Dipendenze fallite",
+ "codeeditor-error-message": "CodeEditor tène abbesogne de UicchiEditor pe essere carecate."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ru.json b/www/wiki/extensions/CodeEditor/i18n/ru.json
new file mode 100644
index 00000000..4ae2fbfc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ru.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Askarmuk",
+ "Eleferen",
+ "Okras",
+ "Nitch",
+ "Facenapalm"
+ ]
+ },
+ "codeeditor-desc": "Редактирование с подсветкой синтаксиса для JavaScript- и CSS-страниц с помощью [https://ace.c9.io/ редактора Ace]",
+ "codeeditor-next-annotation": "Перейти к следующей аннотации",
+ "codeeditor-toolbar-toggle": "Переключить редактор кода",
+ "codeeditor-save-with-errors": "Документ содержит ошибки. Вы уверены, что хотите сохранить его?",
+ "codeeditor-invisibleChars-toggle": "Переключение отображения невидимых символов",
+ "codeeditor-lineWrapping-toggle": "Переключение переноса строк",
+ "codeeditor-searchReplace-toggle": "Переключение отображения диалога поиска и замены текста",
+ "codeeditor-gotoline": "Перейти к строке номер…",
+ "codeeditor-gotoline-placeholder": "строка[:столбец]",
+ "codeeditor-gotoline-prompt": "Введите номер строки",
+ "codeeditor-indent": "Отступ",
+ "codeeditor-outdent": "Смещение влево",
+ "codeeditor-error-title": "Сбой зависимости",
+ "codeeditor-error-message": "Для CodeEditor требуется чтобы был загружен WikiEditor."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sco.json b/www/wiki/extensions/CodeEditor/i18n/sco.json
new file mode 100644
index 00000000..3f0b9d3a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sco.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "John Reid"
+ ]
+ },
+ "codeeditor-save-with-errors": "This document contains mistaks. Ar ye sair that ye want tae hain?"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sd.json b/www/wiki/extensions/CodeEditor/i18n/sd.json
new file mode 100644
index 00000000..bd16275f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sd.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sindhu",
+ "Aursani",
+ "Mehtab ahmed"
+ ]
+ },
+ "codeeditor-next-annotation": "ايندڙ تشريح ڏانهن وڃو",
+ "codeeditor-invisibleChars-toggle": "نہ ڏيکارجندڙ اکرن کي ٽاگل ڪريو",
+ "codeeditor-lineWrapping-toggle": "لائين ريپڱ کي ٽاگل ڪريو",
+ "codeeditor-searchReplace-toggle": "ڳوليو ۽ مٽايو واري ڊايالاگ کي ٽاگل ڪريو",
+ "codeeditor-gotoline": "هلو سِٽَ نمبر .....",
+ "codeeditor-gotoline-placeholder": "سٽ[:ڪالم]",
+ "codeeditor-gotoline-prompt": "ڪنھن سٽ جو نمبر داخل ڪريو",
+ "codeeditor-indent": "انڊينٽ",
+ "codeeditor-outdent": "آئوٽ ڊينٽ"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/si.json b/www/wiki/extensions/CodeEditor/i18n/si.json
new file mode 100644
index 00000000..69fbdfed
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/si.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "ටොගල කේත සංස්කාරකය"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sk.json b/www/wiki/extensions/CodeEditor/i18n/sk.json
new file mode 100644
index 00000000..4f47042b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sk.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Helix84",
+ "Lexected",
+ "Teslaton"
+ ]
+ },
+ "codeeditor-desc": "Editor stránok JavaScriptu a CSS so zvýrazňovaním syntaxe pomocou [https://ace.c9.io/ editora Ace]",
+ "codeeditor-next-annotation": "Prejsť na ďalšiu anotáciu",
+ "codeeditor-toolbar-toggle": "Prepnúť editor kódu",
+ "codeeditor-save-with-errors": "Tento dokument obsahuje chyby. Skutočne ho chcete uložiť?",
+ "codeeditor-invisibleChars-toggle": "Prepnúť zobrazenie neviditeľných znakov",
+ "codeeditor-lineWrapping-toggle": "Prepnúť zalamovanie riadkov",
+ "codeeditor-searchReplace-toggle": "Prepnúť zobrazenie okna pre vyhľadávanie a náhrady",
+ "codeeditor-gotoline": "Skok na riadok číslo…",
+ "codeeditor-gotoline-placeholder": "riadok[:stĺpec]",
+ "codeeditor-gotoline-prompt": "Zadajte číslo riadku",
+ "codeeditor-indent": "Zväčšiť odsadenie",
+ "codeeditor-outdent": "Zmenšiť odsadenie",
+ "codeeditor-error-title": "Nenaplnená závislosť",
+ "codeeditor-error-message": "CodeEditor vyžaduje zavedený WikiEditor."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sl.json b/www/wiki/extensions/CodeEditor/i18n/sl.json
new file mode 100644
index 00000000..33bc7850
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sl.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "NegativeTwelveDollars"
+ ]
+ },
+ "codeeditor-gotoline-placeholder": "vrstica[:stolpec]",
+ "codeeditor-gotoline-prompt": "Vnesite številko vrstice"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sr-ec.json b/www/wiki/extensions/CodeEditor/i18n/sr-ec.json
new file mode 100644
index 00000000..1d2c8506
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sr-ec.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Obsuser"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "Укључи/искључи уређивач кода"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sr-el.json b/www/wiki/extensions/CodeEditor/i18n/sr-el.json
new file mode 100644
index 00000000..d1d98029
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sr-el.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Obsuser"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "Uključi/isključi uređivač koda"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/sv.json b/www/wiki/extensions/CodeEditor/i18n/sv.json
new file mode 100644
index 00000000..549ee597
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/sv.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Skalman",
+ "WikiPhoenix",
+ "Lokal Profil"
+ ]
+ },
+ "codeeditor-desc": "Redigering med syntaxfärgläggning för JavaScript- och CSS-sidor med [https://ace.c9.io/ Ace-redigeraren]",
+ "codeeditor-next-annotation": "Gå till nästa anteckning",
+ "codeeditor-toolbar-toggle": "Slå på/av kodredigeraren",
+ "codeeditor-save-with-errors": "Dokumentet innehåller fel. Är du säker på att du vill spara?",
+ "codeeditor-invisibleChars-toggle": "Slå på/av osynliga tecken",
+ "codeeditor-lineWrapping-toggle": "Slå på/av radbrytning",
+ "codeeditor-searchReplace-toggle": "Slå på/av sök- och ersättsdialogen",
+ "codeeditor-gotoline": "Gå till radnummer...",
+ "codeeditor-gotoline-placeholder": "rad[:kolumn]",
+ "codeeditor-gotoline-prompt": "Ange ett radnummer",
+ "codeeditor-indent": "Indentera",
+ "codeeditor-outdent": "Utdrag",
+ "codeeditor-error-title": "Beroende misslyckades",
+ "codeeditor-error-message": "CodeEditor kräver att WikiEditor är inläst."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ta.json b/www/wiki/extensions/CodeEditor/i18n/ta.json
new file mode 100644
index 00000000..43900cfc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ta.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "ElangoRamanujam"
+ ]
+ },
+ "codeeditor-gotoline-placeholder": "வரி[:column]",
+ "codeeditor-gotoline-prompt": "ஒரு வரி எண்ணை உள்ளிடுக"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/te.json b/www/wiki/extensions/CodeEditor/i18n/te.json
new file mode 100644
index 00000000..6caba2c8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/te.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jedimaster26"
+ ]
+ },
+ "codeeditor-gotoline-prompt": "వరుస సంఖ్హ్య అమర్చండి"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/tl.json b/www/wiki/extensions/CodeEditor/i18n/tl.json
new file mode 100644
index 00000000..7468801e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/tl.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "AnakngAraw"
+ ]
+ },
+ "codeeditor-desc": "Pamamatnugot na pinagliliwanag ang palaugnayan para sa mga pahina ng JavaScript at CSS na ginagamit ang [https://ace.c9.io/ patnugot ng Ace]",
+ "codeeditor-toolbar-toggle": "Patnugot ng kodigo ng paglilipat-pili"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/tr.json b/www/wiki/extensions/CodeEditor/i18n/tr.json
new file mode 100644
index 00000000..df11ba34
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/tr.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joseph",
+ "Ömer Berkay",
+ "Demircimehmed",
+ "Sayginer"
+ ]
+ },
+ "codeeditor-desc": "JavaScript ve CSS sayfaları için [https://ace.c9.io/ Ace editör] kullanarak sözdizimi-vurgulu düzenleme",
+ "codeeditor-toolbar-toggle": "Kod editörünü değiştir",
+ "codeeditor-save-with-errors": "Belge hata içermekte. Kaydetmek istediğinizden emin misiniz?",
+ "codeeditor-lineWrapping-toggle": "Satır kaydırmasına geçiş.",
+ "codeeditor-gotoline": "... numaralı satıra git"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ug-arab.json b/www/wiki/extensions/CodeEditor/i18n/ug-arab.json
new file mode 100644
index 00000000..701a3626
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ug-arab.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sahran"
+ ]
+ },
+ "codeeditor-toolbar-toggle": "كود تەھرىرلىگۈچنى ئالماشتۇر"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/uk.json b/www/wiki/extensions/CodeEditor/i18n/uk.json
new file mode 100644
index 00000000..56dba387
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/uk.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Base",
+ "Sodmy",
+ "Andriykopanytsia",
+ "Ата",
+ "Piramidion"
+ ]
+ },
+ "codeeditor-desc": "Редагування із підсвіткою синтаксису для JavaScript та CSS сторінок за допомогою [https://ace.c9.io/ редактора Ace]",
+ "codeeditor-next-annotation": "Перейти до наступної анотації",
+ "codeeditor-toolbar-toggle": "Перемкнути редактор коду",
+ "codeeditor-save-with-errors": "Документ містить помилки. Ви впевнені, що ви хочете зберегти?",
+ "codeeditor-invisibleChars-toggle": "Перемкнути невидимі символи",
+ "codeeditor-lineWrapping-toggle": "Перемкнути перенесення рядка",
+ "codeeditor-searchReplace-toggle": "Перемкнути діалог пошуку і заміни",
+ "codeeditor-gotoline": "Перейти до рядка номер…",
+ "codeeditor-gotoline-placeholder": "рядок[:стовпець]",
+ "codeeditor-gotoline-prompt": "Введіть номер рядка",
+ "codeeditor-indent": "Відступ",
+ "codeeditor-outdent": "Зменшити відступ",
+ "codeeditor-error-title": "Залежність невдала",
+ "codeeditor-error-message": "CodeEditor потребує, щоб було завантажено WikiEditor."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/ur.json b/www/wiki/extensions/CodeEditor/i18n/ur.json
new file mode 100644
index 00000000..9c53da55
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/ur.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Muhammad Shuaib"
+ ]
+ },
+ "codeeditor-gotoline": "سطر نمبر پر جائیں۔۔۔"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/vi.json b/www/wiki/extensions/CodeEditor/i18n/vi.json
new file mode 100644
index 00000000..43bb6359
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/vi.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minh Nguyen"
+ ]
+ },
+ "codeeditor-desc": "Tô màu cú pháp dùng [https://ace.c9.io/ trình soạn thảo Ace] khi sửa đổi các trang JavaScript và CSS",
+ "codeeditor-next-annotation": "Đi đến chú thích sau",
+ "codeeditor-toolbar-toggle": "Bật/tắt hộp sửa đổi mã nguồn",
+ "codeeditor-save-with-errors": "Tài liệu này có lỗi. Bạn có chắc chắn muốn lưu nó?",
+ "codeeditor-invisibleChars-toggle": "Hiện/ẩn các dấu không thấy được",
+ "codeeditor-lineWrapping-toggle": "Bật/tắt ngắt dòng",
+ "codeeditor-searchReplace-toggle": "Hiện/ẩn hộp tìm thay",
+ "codeeditor-gotoline": "Đi đến dòng số…",
+ "codeeditor-gotoline-placeholder": "dòng[:cột]",
+ "codeeditor-gotoline-prompt": "Nhập số dòng",
+ "codeeditor-indent": "Thụt lề",
+ "codeeditor-outdent": "Nhô lề",
+ "codeeditor-error-title": "Thư viện phụ thuộc bị thất bại",
+ "codeeditor-error-message": "CodeEditor cần có WikiEditor được tải."
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/zh-hans.json b/www/wiki/extensions/CodeEditor/i18n/zh-hans.json
new file mode 100644
index 00000000..6ee9735f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/zh-hans.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liangent",
+ "PhiLiP",
+ "Liuxinyu970226",
+ "Northteam"
+ ]
+ },
+ "codeeditor-desc": "使用[https://ace.c9.io/ Ace编辑器]实现编辑JavaScript和CSS页面时的语法高亮功能",
+ "codeeditor-next-annotation": "前往下一注释",
+ "codeeditor-toolbar-toggle": "切换代码编辑器",
+ "codeeditor-save-with-errors": "文档包含错误。您确定要保存吗?",
+ "codeeditor-invisibleChars-toggle": "显示或隐藏不可见字符",
+ "codeeditor-lineWrapping-toggle": "开启/关闭自动换行",
+ "codeeditor-searchReplace-toggle": "显示或隐藏搜索并替换的对话框",
+ "codeeditor-gotoline": "跳转到指定行...",
+ "codeeditor-gotoline-placeholder": "行[:列]",
+ "codeeditor-gotoline-prompt": "输入行数",
+ "codeeditor-indent": "缩进",
+ "codeeditor-outdent": "减少缩进",
+ "codeeditor-error-title": "依赖失败",
+ "codeeditor-error-message": "代码编辑器需要Wiki编辑器被加载。"
+}
diff --git a/www/wiki/extensions/CodeEditor/i18n/zh-hant.json b/www/wiki/extensions/CodeEditor/i18n/zh-hant.json
new file mode 100644
index 00000000..84be0905
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/i18n/zh-hant.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liuxinyu970226",
+ "LNDDYL",
+ "Cwlin0416",
+ "Kly"
+ ]
+ },
+ "codeeditor-desc": "支援 JavaScript 與 CSS 語法醒目標示編輯使用 [https://ace.c9.io/ Ace 編輯器]",
+ "codeeditor-next-annotation": "前往下一個註解",
+ "codeeditor-toolbar-toggle": "切換原始碼編輯器",
+ "codeeditor-save-with-errors": "該文件內有錯誤,您是否確定要儲存?",
+ "codeeditor-invisibleChars-toggle": "切換隱藏字元",
+ "codeeditor-lineWrapping-toggle": "切換自動換行",
+ "codeeditor-searchReplace-toggle": "切換搜尋與取代對話框",
+ "codeeditor-gotoline": "前往行號...",
+ "codeeditor-gotoline-placeholder": "行[:欄]",
+ "codeeditor-gotoline-prompt": "輸入行數",
+ "codeeditor-indent": "增加縮排",
+ "codeeditor-outdent": "減少縮排",
+ "codeeditor-error-title": "相依失敗",
+ "codeeditor-error-message": "代碼編輯器需要有載入 WikiEditor。"
+}
diff --git a/www/wiki/extensions/CodeEditor/images/gotoLine.svg b/www/wiki/extensions/CodeEditor/images/gotoLine.svg
new file mode 100644
index 00000000..58db79e7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/images/gotoLine.svg
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20">
+ <title>
+ go to line
+ </title>
+ <path d="M 2,6 H 3 V 1 H 1 v 1 h 1 z m -1,9 h 2 v 1 H 2 v 1 h 1 v 1 H 1 v 1 H 4 V 14 H 1 Z M 3.5,8 H 1 v 1 h 2 v 1 H 1.5 C 1.2238576,10 1,10.223858 1,10.5 V 13 H 4 V 12 H 2 V 11 H 3.5 C 3.7761424,11 4,10.776142 4,10.5 v -2 C 4,8.2238576 3.7761424,8 3.5,8 Z" />
+ <path d="M 10,7.5 6,10 10,12.5 V 11 h 9 V 9 h -9 z" />
+</svg>
diff --git a/www/wiki/extensions/CodeEditor/images/pilcrow.svg b/www/wiki/extensions/CodeEditor/images/pilcrow.svg
new file mode 100644
index 00000000..c294c18d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/images/pilcrow.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20">
+ <title>
+ pilcrow
+ </title>
+ <path d="m 7.388022,2 h 9.278109 v 2 h -2 V 18 H 12.666277 V 4.0001848 H 9.333065 V 18 H 7.333138 V 9.990386 C 5.7072798,9.883573 4.2194862,9.482099 3.3271547,8.787866 2.4423848,8.087294 2,7.156403 2,5.9949814 2,4.7959481 2.4915387,3.8302979 3.4746161,3.0981365 4.4576935,2.365975 5.7621616,2 7.388022,2 Z" />
+</svg>
diff --git a/www/wiki/extensions/CodeEditor/images/wrapping.svg b/www/wiki/extensions/CodeEditor/images/wrapping.svg
new file mode 100644
index 00000000..5860638e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/images/wrapping.svg
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20">
+ <title>
+ wrapping
+ </title>
+ <path d="m 1,5 v 2 h 14 c 1.125297,0 2,0.8747028 2,2 0,1.125297 -0.874703,2 -2,2 H 14 V 9 l -3,3 3,3 v -2 h 1 c 2.198703,0 4,-1.801297 4,-4 0,-2.1987028 -1.801297,-4 -4,-4 z" />
+ <path d="m 1,13 h 8 v 2 H 1 Z" />
+ <path d="m 1,9 h 8 v 2 H 1 Z" />
+</svg>
diff --git a/www/wiki/extensions/CodeEditor/includes/CodeEditorHooks.php b/www/wiki/extensions/CodeEditor/includes/CodeEditorHooks.php
new file mode 100644
index 00000000..5c47c596
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/includes/CodeEditorHooks.php
@@ -0,0 +1,63 @@
+<?php
+
+class CodeEditorHooks {
+ /**
+ * @param Title $title
+ * @param string $model
+ * @param string $format
+ * @return null|string
+ */
+ public static function getPageLanguage( Title $title, $model, $format ) {
+ global $wgCodeEditorEnableCore;
+
+ if ( $wgCodeEditorEnableCore ) {
+ if ( $model === CONTENT_MODEL_JAVASCRIPT ) {
+ return 'javascript';
+ } elseif ( $model === CONTENT_MODEL_CSS ) {
+ return 'css';
+ } elseif ( $model === CONTENT_MODEL_JSON ) {
+ return 'json';
+ }
+ }
+
+ // Give extensions a chance
+ // Note: $model and $format were added around the time of MediaWiki 1.28.
+ $lang = null;
+ Hooks::run( 'CodeEditorGetPageLanguage', [ $title, &$lang, $model, $format ] );
+
+ return $lang;
+ }
+
+ /**
+ * @param User $user
+ * @param array &$defaultPreferences
+ * @return bool
+ */
+ public static function getPreferences( $user, &$defaultPreferences ) {
+ $defaultPreferences['usecodeeditor'] = [
+ 'type' => 'api',
+ 'default' => '1',
+ ];
+ return true;
+ }
+
+ /**
+ * @param EditPage $editpage
+ * @param OutputPage $output
+ * @return bool
+ */
+ public static function editPageShowEditFormInitial( $editpage, $output ) {
+ $title = $editpage->getContextTitle();
+ $model = $editpage->contentModel;
+ $format = $editpage->contentFormat;
+
+ $lang = self::getPageLanguage( $title, $model, $format );
+ if ( $lang && $output->getUser()->getOption( 'usebetatoolbar' ) ) {
+ $output->addModules( 'ext.codeEditor' );
+ $output->addJsConfigVars( 'wgCodeEditorCurrentLanguage', $lang );
+ } elseif ( !ExtensionRegistry::getInstance()->isLoaded( "WikiEditor" ) ) {
+ throw new ErrorPageError( "codeeditor-error-title", "codeeditor-error-message" );
+ }
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/LICENSE b/www/wiki/extensions/CodeEditor/modules/ace/LICENSE
new file mode 100644
index 00000000..4760be2a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/LICENSE
@@ -0,0 +1,24 @@
+Copyright (c) 2010, Ajax.org B.V.
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ * Neither the name of Ajax.org B.V. nor the
+ names of its contributors may be used to endorse or promote products
+ derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ace.js b/www/wiki/extensions/CodeEditor/modules/ace/ace.js
new file mode 100644
index 00000000..068debb2
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ace.js
@@ -0,0 +1,20199 @@
+/* ***** BEGIN LICENSE BLOCK *****
+ * Distributed under the BSD license:
+ *
+ * Copyright (c) 2010, Ajax.org B.V.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of Ajax.org B.V. nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+/**
+ * Define a module along with a payload
+ * @param module a name for the payload
+ * @param payload a function to call with (require, exports, module) params
+ */
+
+(function() {
+
+var ACE_NAMESPACE = "ace";
+
+var global = (function() { return this; })();
+if (!global && typeof window != "undefined") global = window; // strict mode
+
+
+if (!ACE_NAMESPACE && typeof requirejs !== "undefined")
+ return;
+
+
+var define = function(module, deps, payload) {
+ if (typeof module !== "string") {
+ if (define.original)
+ define.original.apply(this, arguments);
+ else {
+ console.error("dropping module because define wasn\'t a string.");
+ console.trace();
+ }
+ return;
+ }
+ if (arguments.length == 2)
+ payload = deps;
+ if (!define.modules[module]) {
+ define.payloads[module] = payload;
+ define.modules[module] = null;
+ }
+};
+
+define.modules = {};
+define.payloads = {};
+
+/**
+ * Get at functionality define()ed using the function above
+ */
+var _require = function(parentId, module, callback) {
+ if (typeof module === "string") {
+ var payload = lookup(parentId, module);
+ if (payload != undefined) {
+ callback && callback();
+ return payload;
+ }
+ } else if (Object.prototype.toString.call(module) === "[object Array]") {
+ var params = [];
+ for (var i = 0, l = module.length; i < l; ++i) {
+ var dep = lookup(parentId, module[i]);
+ if (dep == undefined && require.original)
+ return;
+ params.push(dep);
+ }
+ return callback && callback.apply(null, params) || true;
+ }
+};
+
+var require = function(module, callback) {
+ var packagedModule = _require("", module, callback);
+ if (packagedModule == undefined && require.original)
+ return require.original.apply(this, arguments);
+ return packagedModule;
+};
+
+var normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return normalizeModule(parentId, chunks[0]) + "!" + normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = base + "/" + moduleName;
+
+ while(moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+ return moduleName;
+};
+
+/**
+ * Internal function to lookup moduleNames and resolve them by calling the
+ * definition function if needed.
+ */
+var lookup = function(parentId, moduleName) {
+ moduleName = normalizeModule(parentId, moduleName);
+
+ var module = define.modules[moduleName];
+ if (!module) {
+ module = define.payloads[moduleName];
+ if (typeof module === 'function') {
+ var exports = {};
+ var mod = {
+ id: moduleName,
+ uri: '',
+ exports: exports,
+ packaged: true
+ };
+
+ var req = function(module, callback) {
+ return _require(moduleName, module, callback);
+ };
+
+ var returnValue = module(req, exports, mod);
+ exports = returnValue || mod.exports;
+ define.modules[moduleName] = exports;
+ delete define.payloads[moduleName];
+ }
+ module = define.modules[moduleName] = exports || module;
+ }
+ return module;
+};
+
+function exportAce(ns) {
+ var root = global;
+ if (ns) {
+ if (!global[ns])
+ global[ns] = {};
+ root = global[ns];
+ }
+
+ if (!root.define || !root.define.packaged) {
+ define.original = root.define;
+ root.define = define;
+ root.define.packaged = true;
+ }
+
+ if (!root.require || !root.require.packaged) {
+ require.original = root.require;
+ root.require = require;
+ root.require.packaged = true;
+ }
+}
+
+exportAce(ACE_NAMESPACE);
+
+})();
+
+ace.define("ace/lib/regexp",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+ var real = {
+ exec: RegExp.prototype.exec,
+ test: RegExp.prototype.test,
+ match: String.prototype.match,
+ replace: String.prototype.replace,
+ split: String.prototype.split
+ },
+ compliantExecNpcg = real.exec.call(/()??/, "")[1] === undefined, // check `exec` handling of nonparticipating capturing groups
+ compliantLastIndexIncrement = function () {
+ var x = /^/g;
+ real.test.call(x, "");
+ return !x.lastIndex;
+ }();
+
+ if (compliantLastIndexIncrement && compliantExecNpcg)
+ return;
+ RegExp.prototype.exec = function (str) {
+ var match = real.exec.apply(this, arguments),
+ name, r2;
+ if ( typeof(str) == 'string' && match) {
+ if (!compliantExecNpcg && match.length > 1 && indexOf(match, "") > -1) {
+ r2 = RegExp(this.source, real.replace.call(getNativeFlags(this), "g", ""));
+ real.replace.call(str.slice(match.index), r2, function () {
+ for (var i = 1; i < arguments.length - 2; i++) {
+ if (arguments[i] === undefined)
+ match[i] = undefined;
+ }
+ });
+ }
+ if (this._xregexp && this._xregexp.captureNames) {
+ for (var i = 1; i < match.length; i++) {
+ name = this._xregexp.captureNames[i - 1];
+ if (name)
+ match[name] = match[i];
+ }
+ }
+ if (!compliantLastIndexIncrement && this.global && !match[0].length && (this.lastIndex > match.index))
+ this.lastIndex--;
+ }
+ return match;
+ };
+ if (!compliantLastIndexIncrement) {
+ RegExp.prototype.test = function (str) {
+ var match = real.exec.call(this, str);
+ if (match && this.global && !match[0].length && (this.lastIndex > match.index))
+ this.lastIndex--;
+ return !!match;
+ };
+ }
+
+ function getNativeFlags (regex) {
+ return (regex.global ? "g" : "") +
+ (regex.ignoreCase ? "i" : "") +
+ (regex.multiline ? "m" : "") +
+ (regex.extended ? "x" : "") + // Proposed for ES4; included in AS3
+ (regex.sticky ? "y" : "");
+ }
+
+ function indexOf (array, item, from) {
+ if (Array.prototype.indexOf) // Use the native array method if available
+ return array.indexOf(item, from);
+ for (var i = from || 0; i < array.length; i++) {
+ if (array[i] === item)
+ return i;
+ }
+ return -1;
+ }
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
+
+ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/regexp","ace/lib/es5-shim"], function(require, exports, module) {
+"use strict";
+
+require("./regexp");
+require("./es5-shim");
+
+});
+
+ace.define("ace/lib/dom",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var XHTML_NS = "http://www.w3.org/1999/xhtml";
+
+exports.getDocumentHead = function(doc) {
+ if (!doc)
+ doc = document;
+ return doc.head || doc.getElementsByTagName("head")[0] || doc.documentElement;
+}
+
+exports.createElement = function(tag, ns) {
+ return document.createElementNS ?
+ document.createElementNS(ns || XHTML_NS, tag) :
+ document.createElement(tag);
+};
+
+exports.hasCssClass = function(el, name) {
+ var classes = (el.className + "").split(/\s+/g);
+ return classes.indexOf(name) !== -1;
+};
+exports.addCssClass = function(el, name) {
+ if (!exports.hasCssClass(el, name)) {
+ el.className += " " + name;
+ }
+};
+exports.removeCssClass = function(el, name) {
+ var classes = el.className.split(/\s+/g);
+ while (true) {
+ var index = classes.indexOf(name);
+ if (index == -1) {
+ break;
+ }
+ classes.splice(index, 1);
+ }
+ el.className = classes.join(" ");
+};
+
+exports.toggleCssClass = function(el, name) {
+ var classes = el.className.split(/\s+/g), add = true;
+ while (true) {
+ var index = classes.indexOf(name);
+ if (index == -1) {
+ break;
+ }
+ add = false;
+ classes.splice(index, 1);
+ }
+ if (add)
+ classes.push(name);
+
+ el.className = classes.join(" ");
+ return add;
+};
+exports.setCssClass = function(node, className, include) {
+ if (include) {
+ exports.addCssClass(node, className);
+ } else {
+ exports.removeCssClass(node, className);
+ }
+};
+
+exports.hasCssString = function(id, doc) {
+ var index = 0, sheets;
+ doc = doc || document;
+
+ if (doc.createStyleSheet && (sheets = doc.styleSheets)) {
+ while (index < sheets.length)
+ if (sheets[index++].owningElement.id === id) return true;
+ } else if ((sheets = doc.getElementsByTagName("style"))) {
+ while (index < sheets.length)
+ if (sheets[index++].id === id) return true;
+ }
+
+ return false;
+};
+
+exports.importCssString = function importCssString(cssText, id, doc) {
+ doc = doc || document;
+ if (id && exports.hasCssString(id, doc))
+ return null;
+
+ var style;
+
+ if (id)
+ cssText += "\n/*# sourceURL=ace/css/" + id + " */";
+
+ if (doc.createStyleSheet) {
+ style = doc.createStyleSheet();
+ style.cssText = cssText;
+ if (id)
+ style.owningElement.id = id;
+ } else {
+ style = exports.createElement("style");
+ style.appendChild(doc.createTextNode(cssText));
+ if (id)
+ style.id = id;
+
+ exports.getDocumentHead(doc).appendChild(style);
+ }
+};
+
+exports.importCssStylsheet = function(uri, doc) {
+ if (doc.createStyleSheet) {
+ doc.createStyleSheet(uri);
+ } else {
+ var link = exports.createElement('link');
+ link.rel = 'stylesheet';
+ link.href = uri;
+
+ exports.getDocumentHead(doc).appendChild(link);
+ }
+};
+
+exports.getInnerWidth = function(element) {
+ return (
+ parseInt(exports.computedStyle(element, "paddingLeft"), 10) +
+ parseInt(exports.computedStyle(element, "paddingRight"), 10) +
+ element.clientWidth
+ );
+};
+
+exports.getInnerHeight = function(element) {
+ return (
+ parseInt(exports.computedStyle(element, "paddingTop"), 10) +
+ parseInt(exports.computedStyle(element, "paddingBottom"), 10) +
+ element.clientHeight
+ );
+};
+
+exports.scrollbarWidth = function(document) {
+ var inner = exports.createElement("ace_inner");
+ inner.style.width = "100%";
+ inner.style.minWidth = "0px";
+ inner.style.height = "200px";
+ inner.style.display = "block";
+
+ var outer = exports.createElement("ace_outer");
+ var style = outer.style;
+
+ style.position = "absolute";
+ style.left = "-10000px";
+ style.overflow = "hidden";
+ style.width = "200px";
+ style.minWidth = "0px";
+ style.height = "150px";
+ style.display = "block";
+
+ outer.appendChild(inner);
+
+ var body = document.documentElement;
+ body.appendChild(outer);
+
+ var noScrollbar = inner.offsetWidth;
+
+ style.overflow = "scroll";
+ var withScrollbar = inner.offsetWidth;
+
+ if (noScrollbar == withScrollbar) {
+ withScrollbar = outer.clientWidth;
+ }
+
+ body.removeChild(outer);
+
+ return noScrollbar-withScrollbar;
+};
+
+if (typeof document == "undefined") {
+ exports.importCssString = function() {};
+ return;
+}
+
+if (window.pageYOffset !== undefined) {
+ exports.getPageScrollTop = function() {
+ return window.pageYOffset;
+ };
+
+ exports.getPageScrollLeft = function() {
+ return window.pageXOffset;
+ };
+}
+else {
+ exports.getPageScrollTop = function() {
+ return document.body.scrollTop;
+ };
+
+ exports.getPageScrollLeft = function() {
+ return document.body.scrollLeft;
+ };
+}
+
+if (window.getComputedStyle)
+ exports.computedStyle = function(element, style) {
+ if (style)
+ return (window.getComputedStyle(element, "") || {})[style] || "";
+ return window.getComputedStyle(element, "") || {};
+ };
+else
+ exports.computedStyle = function(element, style) {
+ if (style)
+ return element.currentStyle[style];
+ return element.currentStyle;
+ };
+exports.setInnerHtml = function(el, innerHtml) {
+ var element = el.cloneNode(false);//document.createElement("div");
+ element.innerHTML = innerHtml;
+ el.parentNode.replaceChild(element, el);
+ return element;
+};
+
+if ("textContent" in document.documentElement) {
+ exports.setInnerText = function(el, innerText) {
+ el.textContent = innerText;
+ };
+
+ exports.getInnerText = function(el) {
+ return el.textContent;
+ };
+}
+else {
+ exports.setInnerText = function(el, innerText) {
+ el.innerText = innerText;
+ };
+
+ exports.getInnerText = function(el) {
+ return el.innerText;
+ };
+}
+
+exports.getParentWindow = function(document) {
+ return document.defaultView || document.parentWindow;
+};
+
+});
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/lib/keys",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop"], function(require, exports, module) {
+"use strict";
+
+require("./fixoldbrowsers");
+
+var oop = require("./oop");
+var Keys = (function() {
+ var ret = {
+ MODIFIER_KEYS: {
+ 16: 'Shift', 17: 'Ctrl', 18: 'Alt', 224: 'Meta'
+ },
+
+ KEY_MODS: {
+ "ctrl": 1, "alt": 2, "option" : 2, "shift": 4,
+ "super": 8, "meta": 8, "command": 8, "cmd": 8
+ },
+
+ FUNCTION_KEYS : {
+ 8 : "Backspace",
+ 9 : "Tab",
+ 13 : "Return",
+ 19 : "Pause",
+ 27 : "Esc",
+ 32 : "Space",
+ 33 : "PageUp",
+ 34 : "PageDown",
+ 35 : "End",
+ 36 : "Home",
+ 37 : "Left",
+ 38 : "Up",
+ 39 : "Right",
+ 40 : "Down",
+ 44 : "Print",
+ 45 : "Insert",
+ 46 : "Delete",
+ 96 : "Numpad0",
+ 97 : "Numpad1",
+ 98 : "Numpad2",
+ 99 : "Numpad3",
+ 100: "Numpad4",
+ 101: "Numpad5",
+ 102: "Numpad6",
+ 103: "Numpad7",
+ 104: "Numpad8",
+ 105: "Numpad9",
+ '-13': "NumpadEnter",
+ 112: "F1",
+ 113: "F2",
+ 114: "F3",
+ 115: "F4",
+ 116: "F5",
+ 117: "F6",
+ 118: "F7",
+ 119: "F8",
+ 120: "F9",
+ 121: "F10",
+ 122: "F11",
+ 123: "F12",
+ 144: "Numlock",
+ 145: "Scrolllock"
+ },
+
+ PRINTABLE_KEYS: {
+ 32: ' ', 48: '0', 49: '1', 50: '2', 51: '3', 52: '4', 53: '5',
+ 54: '6', 55: '7', 56: '8', 57: '9', 59: ';', 61: '=', 65: 'a',
+ 66: 'b', 67: 'c', 68: 'd', 69: 'e', 70: 'f', 71: 'g', 72: 'h',
+ 73: 'i', 74: 'j', 75: 'k', 76: 'l', 77: 'm', 78: 'n', 79: 'o',
+ 80: 'p', 81: 'q', 82: 'r', 83: 's', 84: 't', 85: 'u', 86: 'v',
+ 87: 'w', 88: 'x', 89: 'y', 90: 'z', 107: '+', 109: '-', 110: '.',
+ 186: ';', 187: '=', 188: ',', 189: '-', 190: '.', 191: '/', 192: '`',
+ 219: '[', 220: '\\',221: ']', 222: "'", 111: '/', 106: '*'
+ }
+ };
+ var name, i;
+ for (i in ret.FUNCTION_KEYS) {
+ name = ret.FUNCTION_KEYS[i].toLowerCase();
+ ret[name] = parseInt(i, 10);
+ }
+ for (i in ret.PRINTABLE_KEYS) {
+ name = ret.PRINTABLE_KEYS[i].toLowerCase();
+ ret[name] = parseInt(i, 10);
+ }
+ oop.mixin(ret, ret.MODIFIER_KEYS);
+ oop.mixin(ret, ret.PRINTABLE_KEYS);
+ oop.mixin(ret, ret.FUNCTION_KEYS);
+ ret.enter = ret["return"];
+ ret.escape = ret.esc;
+ ret.del = ret["delete"];
+ ret[173] = '-';
+
+ (function() {
+ var mods = ["cmd", "ctrl", "alt", "shift"];
+ for (var i = Math.pow(2, mods.length); i--;) {
+ ret.KEY_MODS[i] = mods.filter(function(x) {
+ return i & ret.KEY_MODS[x];
+ }).join("-") + "-";
+ }
+ })();
+
+ ret.KEY_MODS[0] = "";
+ ret.KEY_MODS[-1] = "input-";
+
+ return ret;
+})();
+oop.mixin(exports, Keys);
+
+exports.keyCodeToString = function(keyCode) {
+ var keyString = Keys[keyCode];
+ if (typeof keyString != "string")
+ keyString = String.fromCharCode(keyCode);
+ return keyString.toLowerCase();
+};
+
+});
+
+ace.define("ace/lib/useragent",["require","exports","module"], function(require, exports, module) {
+"use strict";
+exports.OS = {
+ LINUX: "LINUX",
+ MAC: "MAC",
+ WINDOWS: "WINDOWS"
+};
+exports.getOS = function() {
+ if (exports.isMac) {
+ return exports.OS.MAC;
+ } else if (exports.isLinux) {
+ return exports.OS.LINUX;
+ } else {
+ return exports.OS.WINDOWS;
+ }
+};
+if (typeof navigator != "object")
+ return;
+
+var os = (navigator.platform.match(/mac|win|linux/i) || ["other"])[0].toLowerCase();
+var ua = navigator.userAgent;
+exports.isWin = (os == "win");
+exports.isMac = (os == "mac");
+exports.isLinux = (os == "linux");
+exports.isIE =
+ (navigator.appName == "Microsoft Internet Explorer" || navigator.appName.indexOf("MSAppHost") >= 0)
+ ? parseFloat((ua.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1])
+ : parseFloat((ua.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]); // for ie
+
+exports.isOldIE = exports.isIE && exports.isIE < 9;
+exports.isGecko = exports.isMozilla = (window.Controllers || window.controllers) && window.navigator.product === "Gecko";
+exports.isOldGecko = exports.isGecko && parseInt((ua.match(/rv:(\d+)/)||[])[1], 10) < 4;
+exports.isOpera = window.opera && Object.prototype.toString.call(window.opera) == "[object Opera]";
+exports.isWebKit = parseFloat(ua.split("WebKit/")[1]) || undefined;
+
+exports.isChrome = parseFloat(ua.split(" Chrome/")[1]) || undefined;
+
+exports.isAIR = ua.indexOf("AdobeAIR") >= 0;
+
+exports.isIPad = ua.indexOf("iPad") >= 0;
+
+exports.isChromeOS = ua.indexOf(" CrOS ") >= 0;
+
+exports.isIOS = /iPad|iPhone|iPod/.test(ua) && !window.MSStream;
+
+if (exports.isIOS) exports.isMac = true;
+
+});
+
+ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"], function(require, exports, module) {
+"use strict";
+
+var keys = require("./keys");
+var useragent = require("./useragent");
+
+var pressedKeys = null;
+var ts = 0;
+
+exports.addListener = function(elem, type, callback) {
+ if (elem.addEventListener) {
+ return elem.addEventListener(type, callback, false);
+ }
+ if (elem.attachEvent) {
+ var wrapper = function() {
+ callback.call(elem, window.event);
+ };
+ callback._wrapper = wrapper;
+ elem.attachEvent("on" + type, wrapper);
+ }
+};
+
+exports.removeListener = function(elem, type, callback) {
+ if (elem.removeEventListener) {
+ return elem.removeEventListener(type, callback, false);
+ }
+ if (elem.detachEvent) {
+ elem.detachEvent("on" + type, callback._wrapper || callback);
+ }
+};
+exports.stopEvent = function(e) {
+ exports.stopPropagation(e);
+ exports.preventDefault(e);
+ return false;
+};
+
+exports.stopPropagation = function(e) {
+ if (e.stopPropagation)
+ e.stopPropagation();
+ else
+ e.cancelBubble = true;
+};
+
+exports.preventDefault = function(e) {
+ if (e.preventDefault)
+ e.preventDefault();
+ else
+ e.returnValue = false;
+};
+exports.getButton = function(e) {
+ if (e.type == "dblclick")
+ return 0;
+ if (e.type == "contextmenu" || (useragent.isMac && (e.ctrlKey && !e.altKey && !e.shiftKey)))
+ return 2;
+ if (e.preventDefault) {
+ return e.button;
+ }
+ else {
+ return {1:0, 2:2, 4:1}[e.button];
+ }
+};
+
+exports.capture = function(el, eventHandler, releaseCaptureHandler) {
+ function onMouseUp(e) {
+ eventHandler && eventHandler(e);
+ releaseCaptureHandler && releaseCaptureHandler(e);
+
+ exports.removeListener(document, "mousemove", eventHandler, true);
+ exports.removeListener(document, "mouseup", onMouseUp, true);
+ exports.removeListener(document, "dragstart", onMouseUp, true);
+ }
+
+ exports.addListener(document, "mousemove", eventHandler, true);
+ exports.addListener(document, "mouseup", onMouseUp, true);
+ exports.addListener(document, "dragstart", onMouseUp, true);
+
+ return onMouseUp;
+};
+
+exports.addTouchMoveListener = function (el, callback) {
+ if ("ontouchmove" in el) {
+ var startx, starty;
+ exports.addListener(el, "touchstart", function (e) {
+ var touchObj = e.changedTouches[0];
+ startx = touchObj.clientX;
+ starty = touchObj.clientY;
+ });
+ exports.addListener(el, "touchmove", function (e) {
+ var factor = 1,
+ touchObj = e.changedTouches[0];
+
+ e.wheelX = -(touchObj.clientX - startx) / factor;
+ e.wheelY = -(touchObj.clientY - starty) / factor;
+
+ startx = touchObj.clientX;
+ starty = touchObj.clientY;
+
+ callback(e);
+ });
+ }
+};
+
+exports.addMouseWheelListener = function(el, callback) {
+ if ("onmousewheel" in el) {
+ exports.addListener(el, "mousewheel", function(e) {
+ var factor = 8;
+ if (e.wheelDeltaX !== undefined) {
+ e.wheelX = -e.wheelDeltaX / factor;
+ e.wheelY = -e.wheelDeltaY / factor;
+ } else {
+ e.wheelX = 0;
+ e.wheelY = -e.wheelDelta / factor;
+ }
+ callback(e);
+ });
+ } else if ("onwheel" in el) {
+ exports.addListener(el, "wheel", function(e) {
+ var factor = 0.35;
+ switch (e.deltaMode) {
+ case e.DOM_DELTA_PIXEL:
+ e.wheelX = e.deltaX * factor || 0;
+ e.wheelY = e.deltaY * factor || 0;
+ break;
+ case e.DOM_DELTA_LINE:
+ case e.DOM_DELTA_PAGE:
+ e.wheelX = (e.deltaX || 0) * 5;
+ e.wheelY = (e.deltaY || 0) * 5;
+ break;
+ }
+
+ callback(e);
+ });
+ } else {
+ exports.addListener(el, "DOMMouseScroll", function(e) {
+ if (e.axis && e.axis == e.HORIZONTAL_AXIS) {
+ e.wheelX = (e.detail || 0) * 5;
+ e.wheelY = 0;
+ } else {
+ e.wheelX = 0;
+ e.wheelY = (e.detail || 0) * 5;
+ }
+ callback(e);
+ });
+ }
+};
+
+exports.addMultiMouseDownListener = function(elements, timeouts, eventHandler, callbackName) {
+ var clicks = 0;
+ var startX, startY, timer;
+ var eventNames = {
+ 2: "dblclick",
+ 3: "tripleclick",
+ 4: "quadclick"
+ };
+
+ function onMousedown(e) {
+ if (exports.getButton(e) !== 0) {
+ clicks = 0;
+ } else if (e.detail > 1) {
+ clicks++;
+ if (clicks > 4)
+ clicks = 1;
+ } else {
+ clicks = 1;
+ }
+ if (useragent.isIE) {
+ var isNewClick = Math.abs(e.clientX - startX) > 5 || Math.abs(e.clientY - startY) > 5;
+ if (!timer || isNewClick)
+ clicks = 1;
+ if (timer)
+ clearTimeout(timer);
+ timer = setTimeout(function() {timer = null}, timeouts[clicks - 1] || 600);
+
+ if (clicks == 1) {
+ startX = e.clientX;
+ startY = e.clientY;
+ }
+ }
+
+ e._clicks = clicks;
+
+ eventHandler[callbackName]("mousedown", e);
+
+ if (clicks > 4)
+ clicks = 0;
+ else if (clicks > 1)
+ return eventHandler[callbackName](eventNames[clicks], e);
+ }
+ function onDblclick(e) {
+ clicks = 2;
+ if (timer)
+ clearTimeout(timer);
+ timer = setTimeout(function() {timer = null}, timeouts[clicks - 1] || 600);
+ eventHandler[callbackName]("mousedown", e);
+ eventHandler[callbackName](eventNames[clicks], e);
+ }
+ if (!Array.isArray(elements))
+ elements = [elements];
+ elements.forEach(function(el) {
+ exports.addListener(el, "mousedown", onMousedown);
+ if (useragent.isOldIE)
+ exports.addListener(el, "dblclick", onDblclick);
+ });
+};
+
+var getModifierHash = useragent.isMac && useragent.isOpera && !("KeyboardEvent" in window)
+ ? function(e) {
+ return 0 | (e.metaKey ? 1 : 0) | (e.altKey ? 2 : 0) | (e.shiftKey ? 4 : 0) | (e.ctrlKey ? 8 : 0);
+ }
+ : function(e) {
+ return 0 | (e.ctrlKey ? 1 : 0) | (e.altKey ? 2 : 0) | (e.shiftKey ? 4 : 0) | (e.metaKey ? 8 : 0);
+ };
+
+exports.getModifierString = function(e) {
+ return keys.KEY_MODS[getModifierHash(e)];
+};
+
+function normalizeCommandKeys(callback, e, keyCode) {
+ var hashId = getModifierHash(e);
+
+ if (!useragent.isMac && pressedKeys) {
+ if (e.getModifierState && (e.getModifierState("OS") || e.getModifierState("Win")))
+ hashId |= 8;
+ if (pressedKeys.altGr) {
+ if ((3 & hashId) != 3)
+ pressedKeys.altGr = 0;
+ else
+ return;
+ }
+ if (keyCode === 18 || keyCode === 17) {
+ var location = "location" in e ? e.location : e.keyLocation;
+ if (keyCode === 17 && location === 1) {
+ if (pressedKeys[keyCode] == 1)
+ ts = e.timeStamp;
+ } else if (keyCode === 18 && hashId === 3 && location === 2) {
+ var dt = e.timeStamp - ts;
+ if (dt < 50)
+ pressedKeys.altGr = true;
+ }
+ }
+ }
+
+ if (keyCode in keys.MODIFIER_KEYS) {
+ keyCode = -1;
+ }
+ if (hashId & 8 && (keyCode >= 91 && keyCode <= 93)) {
+ keyCode = -1;
+ }
+
+ if (!hashId && keyCode === 13) {
+ var location = "location" in e ? e.location : e.keyLocation;
+ if (location === 3) {
+ callback(e, hashId, -keyCode);
+ if (e.defaultPrevented)
+ return;
+ }
+ }
+
+ if (useragent.isChromeOS && hashId & 8) {
+ callback(e, hashId, keyCode);
+ if (e.defaultPrevented)
+ return;
+ else
+ hashId &= ~8;
+ }
+ if (!hashId && !(keyCode in keys.FUNCTION_KEYS) && !(keyCode in keys.PRINTABLE_KEYS)) {
+ return false;
+ }
+
+ return callback(e, hashId, keyCode);
+}
+
+
+exports.addCommandKeyListener = function(el, callback) {
+ var addListener = exports.addListener;
+ if (useragent.isOldGecko || (useragent.isOpera && !("KeyboardEvent" in window))) {
+ var lastKeyDownKeyCode = null;
+ addListener(el, "keydown", function(e) {
+ lastKeyDownKeyCode = e.keyCode;
+ });
+ addListener(el, "keypress", function(e) {
+ return normalizeCommandKeys(callback, e, lastKeyDownKeyCode);
+ });
+ } else {
+ var lastDefaultPrevented = null;
+
+ addListener(el, "keydown", function(e) {
+ pressedKeys[e.keyCode] = (pressedKeys[e.keyCode] || 0) + 1;
+ var result = normalizeCommandKeys(callback, e, e.keyCode);
+ lastDefaultPrevented = e.defaultPrevented;
+ return result;
+ });
+
+ addListener(el, "keypress", function(e) {
+ if (lastDefaultPrevented && (e.ctrlKey || e.altKey || e.shiftKey || e.metaKey)) {
+ exports.stopEvent(e);
+ lastDefaultPrevented = null;
+ }
+ });
+
+ addListener(el, "keyup", function(e) {
+ pressedKeys[e.keyCode] = null;
+ });
+
+ if (!pressedKeys) {
+ resetPressedKeys();
+ addListener(window, "focus", resetPressedKeys);
+ }
+ }
+};
+function resetPressedKeys() {
+ pressedKeys = Object.create(null);
+}
+
+if (typeof window == "object" && window.postMessage && !useragent.isOldIE) {
+ var postMessageId = 1;
+ exports.nextTick = function(callback, win) {
+ win = win || window;
+ var messageName = "zero-timeout-message-" + postMessageId;
+ exports.addListener(win, "message", function listener(e) {
+ if (e.data == messageName) {
+ exports.stopPropagation(e);
+ exports.removeListener(win, "message", listener);
+ callback();
+ }
+ });
+ win.postMessage(messageName, "*");
+ };
+}
+
+
+exports.nextFrame = typeof window == "object" && (window.requestAnimationFrame
+ || window.mozRequestAnimationFrame
+ || window.webkitRequestAnimationFrame
+ || window.msRequestAnimationFrame
+ || window.oRequestAnimationFrame);
+
+if (exports.nextFrame)
+ exports.nextFrame = exports.nextFrame.bind(window);
+else
+ exports.nextFrame = function(callback) {
+ setTimeout(callback, 17);
+ };
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/keyboard/textinput_ios",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/lib/keys"], function(require, exports, module) {
+"use strict";
+
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+var dom = require("../lib/dom");
+var lang = require("../lib/lang");
+var KEYS = require("../lib/keys");
+var MODS = KEYS.KEY_MODS;
+var BROKEN_SETDATA = useragent.isChrome < 18;
+var USE_IE_MIME_TYPE = useragent.isIE;
+
+var TextInput = function(parentNode, host) {
+ var self = this;
+ var text = dom.createElement("textarea");
+ text.className = useragent.isIOS ? "ace_text-input ace_text-input-ios" : "ace_text-input";
+
+ if (useragent.isTouchPad)
+ text.setAttribute("x-palm-disable-auto-cap", true);
+
+ text.setAttribute("wrap", "off");
+ text.setAttribute("autocorrect", "off");
+ text.setAttribute("autocapitalize", "off");
+ text.setAttribute("spellcheck", false);
+
+ text.style.opacity = "0";
+ parentNode.insertBefore(text, parentNode.firstChild);
+
+ var PLACEHOLDER = "\n aaaa a\n";
+
+ var copied = false;
+ var cut = false;
+ var pasted = false;
+ var inComposition = false;
+ var tempStyle = '';
+ var isSelectionEmpty = true;
+ try { var isFocused = document.activeElement === text; } catch(e) {}
+
+ event.addListener(text, "blur", function(e) {
+ host.onBlur(e);
+ isFocused = false;
+ });
+ event.addListener(text, "focus", function(e) {
+ isFocused = true;
+ host.onFocus(e);
+ resetSelection();
+ });
+ this.focus = function() {
+ if (tempStyle) return text.focus();
+ text.style.position = "fixed";
+ text.focus();
+ };
+ this.blur = function() {
+ text.blur();
+ };
+ this.isFocused = function() {
+ return isFocused;
+ };
+ var syncSelection = lang.delayedCall(function() {
+ isFocused && resetSelection(isSelectionEmpty);
+ });
+ var syncValue = lang.delayedCall(function() {
+ if (!inComposition) {
+ text.value = PLACEHOLDER;
+ isFocused && resetSelection();
+ }
+ });
+
+ function resetSelection(isEmpty) {
+ if (inComposition)
+ return;
+ inComposition = true;
+
+ if (inputHandler) {
+ selectionStart = 0;
+ selectionEnd = isEmpty ? 0 : text.value.length - 1;
+ } else {
+ var selectionStart = 4;
+ var selectionEnd = 5;
+ }
+ try {
+ text.setSelectionRange(selectionStart, selectionEnd);
+ } catch(e) {}
+
+ inComposition = false;
+ }
+
+ function resetValue() {
+ if (inComposition)
+ return;
+ text.value = PLACEHOLDER;
+ if (useragent.isWebKit)
+ syncValue.schedule();
+ }
+
+ useragent.isWebKit || host.addEventListener('changeSelection', function() {
+ if (host.selection.isEmpty() != isSelectionEmpty) {
+ isSelectionEmpty = !isSelectionEmpty;
+ syncSelection.schedule();
+ }
+ });
+
+ resetValue();
+ if (isFocused)
+ host.onFocus();
+
+
+ var isAllSelected = function(text) {
+ return text.selectionStart === 0 && text.selectionEnd === text.value.length;
+ };
+
+ var onSelect = function(e) {
+ if (isAllSelected(text)) {
+ host.selectAll();
+ resetSelection();
+ } else if (inputHandler) {
+ resetSelection(host.selection.isEmpty());
+ }
+ };
+
+ var inputHandler = null;
+ this.setInputHandler = function(cb) {inputHandler = cb};
+ this.getInputHandler = function() {return inputHandler};
+ var afterContextMenu = false;
+
+ var sendText = function(data) {
+ if (text.selectionStart === 4 && text.selectionEnd === 5) {
+ return;
+ }
+ if (inputHandler) {
+ data = inputHandler(data);
+ inputHandler = null;
+ }
+ if (pasted) {
+ resetSelection();
+ if (data)
+ host.onPaste(data);
+ pasted = false;
+ } else if (data == PLACEHOLDER.substr(0) && text.selectionStart === 4) {
+ if (afterContextMenu)
+ host.execCommand("del", {source: "ace"});
+ else // some versions of android do not fire keydown when pressing backspace
+ host.execCommand("backspace", {source: "ace"});
+ } else if (!copied) {
+ if (data.substring(0, 9) == PLACEHOLDER && data.length > PLACEHOLDER.length)
+ data = data.substr(9);
+ else if (data.substr(0, 4) == PLACEHOLDER.substr(0, 4))
+ data = data.substr(4, data.length - PLACEHOLDER.length + 1);
+ else if (data.charAt(data.length - 1) == PLACEHOLDER.charAt(0))
+ data = data.slice(0, -1);
+ if (data == PLACEHOLDER.charAt(0)) {
+ } else if (data.charAt(data.length - 1) == PLACEHOLDER.charAt(0))
+ data = data.slice(0, -1);
+
+ if (data)
+ host.onTextInput(data);
+ }
+ if (copied) {
+ copied = false;
+ }
+ if (afterContextMenu)
+ afterContextMenu = false;
+ };
+ var onInput = function(e) {
+ if (inComposition)
+ return;
+ var data = text.value;
+ sendText(data);
+ resetValue();
+ };
+
+ var handleClipboardData = function(e, data, forceIEMime) {
+ var clipboardData = e.clipboardData || window.clipboardData;
+ if (!clipboardData || BROKEN_SETDATA)
+ return;
+ var mime = USE_IE_MIME_TYPE || forceIEMime ? "Text" : "text/plain";
+ try {
+ if (data) {
+ return clipboardData.setData(mime, data) !== false;
+ } else {
+ return clipboardData.getData(mime);
+ }
+ } catch(e) {
+ if (!forceIEMime)
+ return handleClipboardData(e, data, true);
+ }
+ };
+
+ var doCopy = function(e, isCut) {
+ var data = host.getCopyText();
+ if (!data)
+ return event.preventDefault(e);
+
+ if (handleClipboardData(e, data)) {
+ if (useragent.isIOS) {
+ cut = isCut;
+ text.value = "\n aa" + data + "a a\n";
+ text.setSelectionRange(4, 4 + data.length);
+ copied = {
+ value: data
+ };
+ }
+ isCut ? host.onCut() : host.onCopy();
+ if (!useragent.isIOS) event.preventDefault(e);
+ } else {
+ copied = true;
+ text.value = data;
+ text.select();
+ setTimeout(function(){
+ copied = false;
+ resetValue();
+ resetSelection();
+ isCut ? host.onCut() : host.onCopy();
+ });
+ }
+ };
+
+ var onCut = function(e) {
+ doCopy(e, true);
+ };
+
+ var onCopy = function(e) {
+ doCopy(e, false);
+ };
+
+ var onPaste = function(e) {
+ var data = handleClipboardData(e);
+ if (typeof data == "string") {
+ if (data)
+ host.onPaste(data, e);
+ if (useragent.isIE)
+ setTimeout(resetSelection);
+ event.preventDefault(e);
+ }
+ else {
+ text.value = "";
+ pasted = true;
+ }
+ };
+
+ event.addCommandKeyListener(text, host.onCommandKey.bind(host));
+
+ event.addListener(text, "select", onSelect);
+
+ event.addListener(text, "input", onInput);
+
+ event.addListener(text, "cut", onCut);
+ event.addListener(text, "copy", onCopy);
+ event.addListener(text, "paste", onPaste);
+ var onCompositionStart = function(e) {
+ if (inComposition || !host.onCompositionStart || host.$readOnly)
+ return;
+ inComposition = {};
+ inComposition.canUndo = host.session.$undoManager;
+ host.onCompositionStart();
+ setTimeout(onCompositionUpdate, 0);
+ host.on("mousedown", onCompositionEnd);
+ if (inComposition.canUndo && !host.selection.isEmpty()) {
+ host.insert("");
+ host.session.markUndoGroup();
+ host.selection.clearSelection();
+ }
+ host.session.markUndoGroup();
+ };
+
+ var onCompositionUpdate = function() {
+ if (!inComposition || !host.onCompositionUpdate || host.$readOnly)
+ return;
+ var val = text.value.replace(/\x01/g, "");
+ if (inComposition.lastValue === val) return;
+
+ host.onCompositionUpdate(val);
+ if (inComposition.lastValue)
+ host.undo();
+ if (inComposition.canUndo)
+ inComposition.lastValue = val;
+ if (inComposition.lastValue) {
+ var r = host.selection.getRange();
+ host.insert(inComposition.lastValue);
+ host.session.markUndoGroup();
+ inComposition.range = host.selection.getRange();
+ host.selection.setRange(r);
+ host.selection.clearSelection();
+ }
+ };
+
+ var onCompositionEnd = function(e) {
+ if (!host.onCompositionEnd || host.$readOnly) return;
+ var c = inComposition;
+ inComposition = false;
+ var timer = setTimeout(function() {
+ timer = null;
+ var str = text.value.replace(/\x01/g, "");
+ if (inComposition)
+ return;
+ else if (str == c.lastValue)
+ resetValue();
+ else if (!c.lastValue && str) {
+ resetValue();
+ sendText(str);
+ }
+ });
+ inputHandler = function compositionInputHandler(str) {
+ if (timer)
+ clearTimeout(timer);
+ str = str.replace(/\x01/g, "");
+ if (str == c.lastValue)
+ return "";
+ if (c.lastValue && timer)
+ host.undo();
+ return str;
+ };
+ host.onCompositionEnd();
+ host.removeListener("mousedown", onCompositionEnd);
+ if (e.type == "compositionend" && c.range) {
+ host.selection.setRange(c.range);
+ }
+ var needsOnInput =
+ (!!useragent.isChrome && useragent.isChrome >= 53) ||
+ (!!useragent.isWebKit && useragent.isWebKit >= 603);
+
+ if (needsOnInput) {
+ onInput();
+ }
+ };
+
+
+
+ var syncComposition = lang.delayedCall(onCompositionUpdate, 50);
+
+ event.addListener(text, "compositionstart", onCompositionStart);
+ if (useragent.isGecko) {
+ event.addListener(text, "text", function(){syncComposition.schedule()});
+ } else {
+ event.addListener(text, "keyup", function(){syncComposition.schedule()});
+ event.addListener(text, "keydown", function(){syncComposition.schedule()});
+ }
+ event.addListener(text, "compositionend", onCompositionEnd);
+
+ this.getElement = function() {
+ return text;
+ };
+
+ this.setReadOnly = function(readOnly) {
+ text.readOnly = readOnly;
+ };
+
+ this.onContextMenu = function(e) {
+ afterContextMenu = true;
+ resetSelection(host.selection.isEmpty());
+ host._emit("nativecontextmenu", {target: host, domEvent: e});
+ this.moveToMouse(e, true);
+ };
+
+ this.moveToMouse = function(e, bringToFront) {
+ if (!tempStyle)
+ tempStyle = text.style.cssText;
+ text.style.cssText = (bringToFront ? "z-index:100000;" : "")
+ + "height:" + text.style.height + ";"
+ + (useragent.isIE ? "opacity:0.1;" : "");
+
+ var rect = host.container.getBoundingClientRect();
+ var style = dom.computedStyle(host.container);
+ var top = rect.top + (parseInt(style.borderTopWidth) || 0);
+ var left = rect.left + (parseInt(rect.borderLeftWidth) || 0);
+ var maxTop = rect.bottom - top - text.clientHeight -2;
+ var move = function(e) {
+ text.style.left = e.clientX - left - 2 + "px";
+ text.style.top = Math.min(e.clientY - top - 2, maxTop) + "px";
+ };
+ move(e);
+
+ if (e.type != "mousedown")
+ return;
+
+ if (host.renderer.$keepTextAreaAtCursor)
+ host.renderer.$keepTextAreaAtCursor = null;
+
+ clearTimeout(closeTimeout);
+ if (useragent.isWin)
+ event.capture(host.container, move, onContextMenuClose);
+ };
+
+ this.onContextMenuClose = onContextMenuClose;
+ var closeTimeout;
+ function onContextMenuClose() {
+ clearTimeout(closeTimeout);
+ closeTimeout = setTimeout(function () {
+ if (tempStyle) {
+ text.style.cssText = tempStyle;
+ tempStyle = '';
+ }
+ if (host.renderer.$keepTextAreaAtCursor == null) {
+ host.renderer.$keepTextAreaAtCursor = true;
+ host.renderer.$moveTextAreaToCursor();
+ }
+ }, 0);
+ }
+
+ var onContextMenu = function(e) {
+ host.textInput.onContextMenu(e);
+ onContextMenuClose();
+ };
+ event.addListener(text, "mouseup", onContextMenu);
+ event.addListener(text, "mousedown", function(e) {
+ e.preventDefault();
+ onContextMenuClose();
+ });
+ event.addListener(host.renderer.scroller, "contextmenu", onContextMenu);
+ event.addListener(text, "contextmenu", onContextMenu);
+
+ if (useragent.isIOS) {
+ var typingResetTimeout = null;
+ var typing = false;
+
+ parentNode.addEventListener("keydown", function (e) {
+ if (typingResetTimeout) clearTimeout(typingResetTimeout);
+ typing = true;
+ });
+
+ parentNode.addEventListener("keyup", function (e) {
+ typingResetTimeout = setTimeout(function () {
+ typing = false;
+ }, 100);
+ });
+ var detectArrowKeys = function(e) {
+ if (document.activeElement !== text) return;
+ if (typing) return;
+
+ if (cut) {
+ return setTimeout(function () {
+ cut = false;
+ }, 100);
+ }
+ var selectionStart = text.selectionStart;
+ var selectionEnd = text.selectionEnd;
+ text.setSelectionRange(4, 5);
+ if (selectionStart == selectionEnd) {
+ switch (selectionStart) {
+ case 0: host.onCommandKey(null, 0, KEYS.up); break;
+ case 1: host.onCommandKey(null, 0, KEYS.home); break;
+ case 2: host.onCommandKey(null, MODS.option, KEYS.left); break;
+ case 4: host.onCommandKey(null, 0, KEYS.left); break;
+ case 5: host.onCommandKey(null, 0, KEYS.right); break;
+ case 7: host.onCommandKey(null, MODS.option, KEYS.right); break;
+ case 8: host.onCommandKey(null, 0, KEYS.end); break;
+ case 9: host.onCommandKey(null, 0, KEYS.down); break;
+ }
+ } else {
+ switch (selectionEnd) {
+ case 6: host.onCommandKey(null, MODS.shift, KEYS.right); break;
+ case 7: host.onCommandKey(null, MODS.shift | MODS.option, KEYS.right); break;
+ case 8: host.onCommandKey(null, MODS.shift, KEYS.end); break;
+ case 9: host.onCommandKey(null, MODS.shift, KEYS.down); break;
+ }
+ switch (selectionStart) {
+ case 0: host.onCommandKey(null, MODS.shift, KEYS.up); break;
+ case 1: host.onCommandKey(null, MODS.shift, KEYS.home); break;
+ case 2: host.onCommandKey(null, MODS.shift | MODS.option, KEYS.left); break;
+ case 3: host.onCommandKey(null, MODS.shift, KEYS.left); break;
+ }
+ }
+ }
+ document.addEventListener("selectionchange", detectArrowKeys);
+ host.on("destroy", function() {
+ document.removeEventListener("selectionchange", detectArrowKeys);
+ })
+ }
+};
+
+exports.TextInput = TextInput;
+});
+
+ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang","ace/keyboard/textinput_ios"], function(require, exports, module) {
+"use strict";
+
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+var dom = require("../lib/dom");
+var lang = require("../lib/lang");
+var BROKEN_SETDATA = useragent.isChrome < 18;
+var USE_IE_MIME_TYPE = useragent.isIE;
+
+var TextInputIOS = require("./textinput_ios").TextInput
+var TextInput = function(parentNode, host) {
+ if (useragent.isIOS)
+ return TextInputIOS.call(this, parentNode, host);
+
+ var text = dom.createElement("textarea");
+ text.className = "ace_text-input";
+
+ text.setAttribute("wrap", "off");
+ text.setAttribute("autocorrect", "off");
+ text.setAttribute("autocapitalize", "off");
+ text.setAttribute("spellcheck", false);
+
+ text.style.opacity = "0";
+ parentNode.insertBefore(text, parentNode.firstChild);
+
+ var PLACEHOLDER = "\u2028\u2028";
+
+ var copied = false;
+ var pasted = false;
+ var inComposition = false;
+ var tempStyle = '';
+ var isSelectionEmpty = true;
+ try { var isFocused = document.activeElement === text; } catch(e) {}
+
+ event.addListener(text, "blur", function(e) {
+ host.onBlur(e);
+ isFocused = false;
+ });
+ event.addListener(text, "focus", function(e) {
+ isFocused = true;
+ host.onFocus(e);
+ resetSelection();
+ });
+ this.focus = function() {
+ if (tempStyle) return text.focus();
+ var top = text.style.top;
+ text.style.position = "fixed";
+ text.style.top = "0px";
+ text.focus();
+ setTimeout(function() {
+ text.style.position = "";
+ if (text.style.top == "0px")
+ text.style.top = top;
+ }, 0);
+ };
+ this.blur = function() {
+ text.blur();
+ };
+ this.isFocused = function() {
+ return isFocused;
+ };
+ var syncSelection = lang.delayedCall(function() {
+ isFocused && resetSelection(isSelectionEmpty);
+ });
+ var syncValue = lang.delayedCall(function() {
+ if (!inComposition) {
+ text.value = PLACEHOLDER;
+ isFocused && resetSelection();
+ }
+ });
+
+ function resetSelection(isEmpty) {
+ if (inComposition)
+ return;
+ inComposition = true;
+
+ if (inputHandler) {
+ selectionStart = 0;
+ selectionEnd = isEmpty ? 0 : text.value.length - 1;
+ } else {
+ var selectionStart = isEmpty ? 2 : 1;
+ var selectionEnd = 2;
+ }
+ try {
+ text.setSelectionRange(selectionStart, selectionEnd);
+ } catch(e){}
+
+ inComposition = false;
+ }
+
+ function resetValue() {
+ if (inComposition)
+ return;
+ text.value = PLACEHOLDER;
+ if (useragent.isWebKit)
+ syncValue.schedule();
+ }
+
+ useragent.isWebKit || host.addEventListener('changeSelection', function() {
+ if (host.selection.isEmpty() != isSelectionEmpty) {
+ isSelectionEmpty = !isSelectionEmpty;
+ syncSelection.schedule();
+ }
+ });
+
+ resetValue();
+ if (isFocused)
+ host.onFocus();
+
+
+ var isAllSelected = function(text) {
+ return text.selectionStart === 0 && text.selectionEnd === text.value.length;
+ };
+
+ var onSelect = function(e) {
+ if (copied) {
+ copied = false;
+ } else if (isAllSelected(text)) {
+ host.selectAll();
+ resetSelection();
+ } else if (inputHandler) {
+ resetSelection(host.selection.isEmpty());
+ }
+ };
+
+ var inputHandler = null;
+ this.setInputHandler = function(cb) {inputHandler = cb};
+ this.getInputHandler = function() {return inputHandler};
+ var afterContextMenu = false;
+
+ var sendText = function(data) {
+ if (inputHandler) {
+ data = inputHandler(data);
+ inputHandler = null;
+ }
+ if (pasted) {
+ resetSelection();
+ if (data)
+ host.onPaste(data);
+ pasted = false;
+ } else if (data == PLACEHOLDER.charAt(0)) {
+ if (afterContextMenu)
+ host.execCommand("del", {source: "ace"});
+ else // some versions of android do not fire keydown when pressing backspace
+ host.execCommand("backspace", {source: "ace"});
+ } else {
+ if (data.substring(0, 2) == PLACEHOLDER)
+ data = data.substr(2);
+ else if (data.charAt(0) == PLACEHOLDER.charAt(0))
+ data = data.substr(1);
+ else if (data.charAt(data.length - 1) == PLACEHOLDER.charAt(0))
+ data = data.slice(0, -1);
+ if (data.charAt(data.length - 1) == PLACEHOLDER.charAt(0))
+ data = data.slice(0, -1);
+
+ if (data)
+ host.onTextInput(data);
+ }
+ if (afterContextMenu)
+ afterContextMenu = false;
+ };
+ var onInput = function(e) {
+ if (inComposition)
+ return;
+ var data = text.value;
+ sendText(data);
+ resetValue();
+ };
+
+ var handleClipboardData = function(e, data, forceIEMime) {
+ var clipboardData = e.clipboardData || window.clipboardData;
+ if (!clipboardData || BROKEN_SETDATA)
+ return;
+ var mime = USE_IE_MIME_TYPE || forceIEMime ? "Text" : "text/plain";
+ try {
+ if (data) {
+ return clipboardData.setData(mime, data) !== false;
+ } else {
+ return clipboardData.getData(mime);
+ }
+ } catch(e) {
+ if (!forceIEMime)
+ return handleClipboardData(e, data, true);
+ }
+ };
+
+ var doCopy = function(e, isCut) {
+ var data = host.getCopyText();
+ if (!data)
+ return event.preventDefault(e);
+
+ if (handleClipboardData(e, data)) {
+ isCut ? host.onCut() : host.onCopy();
+ event.preventDefault(e);
+ } else {
+ copied = true;
+ text.value = data;
+ text.select();
+ setTimeout(function(){
+ copied = false;
+ resetValue();
+ resetSelection();
+ isCut ? host.onCut() : host.onCopy();
+ });
+ }
+ };
+
+ var onCut = function(e) {
+ doCopy(e, true);
+ };
+
+ var onCopy = function(e) {
+ doCopy(e, false);
+ };
+
+ var onPaste = function(e) {
+ var data = handleClipboardData(e);
+ if (typeof data == "string") {
+ if (data)
+ host.onPaste(data, e);
+ if (useragent.isIE)
+ setTimeout(resetSelection);
+ event.preventDefault(e);
+ }
+ else {
+ text.value = "";
+ pasted = true;
+ }
+ };
+
+ event.addCommandKeyListener(text, host.onCommandKey.bind(host));
+
+ event.addListener(text, "select", onSelect);
+
+ event.addListener(text, "input", onInput);
+
+ event.addListener(text, "cut", onCut);
+ event.addListener(text, "copy", onCopy);
+ event.addListener(text, "paste", onPaste);
+ if (!('oncut' in text) || !('oncopy' in text) || !('onpaste' in text)) {
+ event.addListener(parentNode, "keydown", function(e) {
+ if ((useragent.isMac && !e.metaKey) || !e.ctrlKey)
+ return;
+
+ switch (e.keyCode) {
+ case 67:
+ onCopy(e);
+ break;
+ case 86:
+ onPaste(e);
+ break;
+ case 88:
+ onCut(e);
+ break;
+ }
+ });
+ }
+ var onCompositionStart = function(e) {
+ if (inComposition || !host.onCompositionStart || host.$readOnly)
+ return;
+ inComposition = {};
+ inComposition.canUndo = host.session.$undoManager;
+ host.onCompositionStart();
+ setTimeout(onCompositionUpdate, 0);
+ host.on("mousedown", onCompositionEnd);
+ if (inComposition.canUndo && !host.selection.isEmpty()) {
+ host.insert("");
+ host.session.markUndoGroup();
+ host.selection.clearSelection();
+ }
+ host.session.markUndoGroup();
+ };
+
+ var onCompositionUpdate = function() {
+ if (!inComposition || !host.onCompositionUpdate || host.$readOnly)
+ return;
+ var val = text.value.replace(/\u2028/g, "");
+ if (inComposition.lastValue === val) return;
+
+ host.onCompositionUpdate(val);
+ if (inComposition.lastValue)
+ host.undo();
+ if (inComposition.canUndo)
+ inComposition.lastValue = val;
+ if (inComposition.lastValue) {
+ var r = host.selection.getRange();
+ host.insert(inComposition.lastValue);
+ host.session.markUndoGroup();
+ inComposition.range = host.selection.getRange();
+ host.selection.setRange(r);
+ host.selection.clearSelection();
+ }
+ };
+
+ var onCompositionEnd = function(e) {
+ if (!host.onCompositionEnd || host.$readOnly) return;
+ var c = inComposition;
+ inComposition = false;
+ var timer = setTimeout(function() {
+ timer = null;
+ var str = text.value.replace(/\u2028/g, "");
+ if (inComposition)
+ return;
+ else if (str == c.lastValue)
+ resetValue();
+ else if (!c.lastValue && str) {
+ resetValue();
+ sendText(str);
+ }
+ });
+ inputHandler = function compositionInputHandler(str) {
+ if (timer)
+ clearTimeout(timer);
+ str = str.replace(/\u2028/g, "");
+ if (str == c.lastValue)
+ return "";
+ if (c.lastValue && timer)
+ host.undo();
+ return str;
+ };
+ host.onCompositionEnd();
+ host.removeListener("mousedown", onCompositionEnd);
+ if (e.type == "compositionend" && c.range) {
+ host.selection.setRange(c.range);
+ }
+ var needsOnInput =
+ (!!useragent.isChrome && useragent.isChrome >= 53) ||
+ (!!useragent.isWebKit && useragent.isWebKit >= 603);
+
+ if (needsOnInput) {
+ onInput();
+ }
+ };
+
+
+
+ var syncComposition = lang.delayedCall(onCompositionUpdate, 50);
+
+ event.addListener(text, "compositionstart", onCompositionStart);
+ if (useragent.isGecko) {
+ event.addListener(text, "text", function(){syncComposition.schedule()});
+ } else {
+ event.addListener(text, "keyup", function(){syncComposition.schedule()});
+ event.addListener(text, "keydown", function(){syncComposition.schedule()});
+ }
+ event.addListener(text, "compositionend", onCompositionEnd);
+
+ this.getElement = function() {
+ return text;
+ };
+
+ this.setReadOnly = function(readOnly) {
+ text.readOnly = readOnly;
+ };
+
+ this.onContextMenu = function(e) {
+ afterContextMenu = true;
+ resetSelection(host.selection.isEmpty());
+ host._emit("nativecontextmenu", {target: host, domEvent: e});
+ this.moveToMouse(e, true);
+ };
+
+ this.moveToMouse = function(e, bringToFront) {
+ if (!tempStyle)
+ tempStyle = text.style.cssText;
+ text.style.cssText = (bringToFront ? "z-index:100000;" : "")
+ + "height:" + text.style.height + ";"
+ + (useragent.isIE ? "opacity:0.1;" : "");
+
+ var rect = host.container.getBoundingClientRect();
+ var style = dom.computedStyle(host.container);
+ var top = rect.top + (parseInt(style.borderTopWidth) || 0);
+ var left = rect.left + (parseInt(rect.borderLeftWidth) || 0);
+ var maxTop = rect.bottom - top - text.clientHeight -2;
+ var move = function(e) {
+ text.style.left = e.clientX - left - 2 + "px";
+ text.style.top = Math.min(e.clientY - top - 2, maxTop) + "px";
+ };
+ move(e);
+
+ if (e.type != "mousedown")
+ return;
+
+ if (host.renderer.$keepTextAreaAtCursor)
+ host.renderer.$keepTextAreaAtCursor = null;
+
+ clearTimeout(closeTimeout);
+ if (useragent.isWin)
+ event.capture(host.container, move, onContextMenuClose);
+ };
+
+ this.onContextMenuClose = onContextMenuClose;
+ var closeTimeout;
+ function onContextMenuClose() {
+ clearTimeout(closeTimeout);
+ closeTimeout = setTimeout(function () {
+ if (tempStyle) {
+ text.style.cssText = tempStyle;
+ tempStyle = '';
+ }
+ if (host.renderer.$keepTextAreaAtCursor == null) {
+ host.renderer.$keepTextAreaAtCursor = true;
+ host.renderer.$moveTextAreaToCursor();
+ }
+ }, 0);
+ }
+
+ var onContextMenu = function(e) {
+ host.textInput.onContextMenu(e);
+ onContextMenuClose();
+ };
+ event.addListener(text, "mouseup", onContextMenu);
+ event.addListener(text, "mousedown", function(e) {
+ e.preventDefault();
+ onContextMenuClose();
+ });
+ event.addListener(host.renderer.scroller, "contextmenu", onContextMenu);
+ event.addListener(text, "contextmenu", onContextMenu);
+};
+
+exports.TextInput = TextInput;
+});
+
+ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"], function(require, exports, module) {
+"use strict";
+
+var dom = require("../lib/dom");
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+
+var DRAG_OFFSET = 0; // pixels
+
+function DefaultHandlers(mouseHandler) {
+ mouseHandler.$clickSelection = null;
+
+ var editor = mouseHandler.editor;
+ editor.setDefaultHandler("mousedown", this.onMouseDown.bind(mouseHandler));
+ editor.setDefaultHandler("dblclick", this.onDoubleClick.bind(mouseHandler));
+ editor.setDefaultHandler("tripleclick", this.onTripleClick.bind(mouseHandler));
+ editor.setDefaultHandler("quadclick", this.onQuadClick.bind(mouseHandler));
+ editor.setDefaultHandler("mousewheel", this.onMouseWheel.bind(mouseHandler));
+ editor.setDefaultHandler("touchmove", this.onTouchMove.bind(mouseHandler));
+
+ var exports = ["select", "startSelect", "selectEnd", "selectAllEnd", "selectByWordsEnd",
+ "selectByLinesEnd", "dragWait", "dragWaitEnd", "focusWait"];
+
+ exports.forEach(function(x) {
+ mouseHandler[x] = this[x];
+ }, this);
+
+ mouseHandler.selectByLines = this.extendSelectionBy.bind(mouseHandler, "getLineRange");
+ mouseHandler.selectByWords = this.extendSelectionBy.bind(mouseHandler, "getWordRange");
+}
+
+(function() {
+
+ this.onMouseDown = function(ev) {
+ var inSelection = ev.inSelection();
+ var pos = ev.getDocumentPosition();
+ this.mousedownEvent = ev;
+ var editor = this.editor;
+
+ var button = ev.getButton();
+ if (button !== 0) {
+ var selectionRange = editor.getSelectionRange();
+ var selectionEmpty = selectionRange.isEmpty();
+ editor.$blockScrolling++;
+ if (selectionEmpty || button == 1)
+ editor.selection.moveToPosition(pos);
+ editor.$blockScrolling--;
+ if (button == 2) {
+ editor.textInput.onContextMenu(ev.domEvent);
+ if (!useragent.isMozilla)
+ ev.preventDefault();
+ }
+ return;
+ }
+
+ this.mousedownEvent.time = Date.now();
+ if (inSelection && !editor.isFocused()) {
+ editor.focus();
+ if (this.$focusTimout && !this.$clickSelection && !editor.inMultiSelectMode) {
+ this.setState("focusWait");
+ this.captureMouse(ev);
+ return;
+ }
+ }
+
+ this.captureMouse(ev);
+ this.startSelect(pos, ev.domEvent._clicks > 1);
+ return ev.preventDefault();
+ };
+
+ this.startSelect = function(pos, waitForClickSelection) {
+ pos = pos || this.editor.renderer.screenToTextCoordinates(this.x, this.y);
+ var editor = this.editor;
+ editor.$blockScrolling++;
+ if (this.mousedownEvent.getShiftKey())
+ editor.selection.selectToPosition(pos);
+ else if (!waitForClickSelection)
+ editor.selection.moveToPosition(pos);
+ if (!waitForClickSelection)
+ this.select();
+ if (editor.renderer.scroller.setCapture) {
+ editor.renderer.scroller.setCapture();
+ }
+ editor.setStyle("ace_selecting");
+ this.setState("select");
+ editor.$blockScrolling--;
+ };
+
+ this.select = function() {
+ var anchor, editor = this.editor;
+ var cursor = editor.renderer.screenToTextCoordinates(this.x, this.y);
+ editor.$blockScrolling++;
+ if (this.$clickSelection) {
+ var cmp = this.$clickSelection.comparePoint(cursor);
+
+ if (cmp == -1) {
+ anchor = this.$clickSelection.end;
+ } else if (cmp == 1) {
+ anchor = this.$clickSelection.start;
+ } else {
+ var orientedRange = calcRangeOrientation(this.$clickSelection, cursor);
+ cursor = orientedRange.cursor;
+ anchor = orientedRange.anchor;
+ }
+ editor.selection.setSelectionAnchor(anchor.row, anchor.column);
+ }
+ editor.selection.selectToPosition(cursor);
+ editor.$blockScrolling--;
+ editor.renderer.scrollCursorIntoView();
+ };
+
+ this.extendSelectionBy = function(unitName) {
+ var anchor, editor = this.editor;
+ var cursor = editor.renderer.screenToTextCoordinates(this.x, this.y);
+ var range = editor.selection[unitName](cursor.row, cursor.column);
+ editor.$blockScrolling++;
+ if (this.$clickSelection) {
+ var cmpStart = this.$clickSelection.comparePoint(range.start);
+ var cmpEnd = this.$clickSelection.comparePoint(range.end);
+
+ if (cmpStart == -1 && cmpEnd <= 0) {
+ anchor = this.$clickSelection.end;
+ if (range.end.row != cursor.row || range.end.column != cursor.column)
+ cursor = range.start;
+ } else if (cmpEnd == 1 && cmpStart >= 0) {
+ anchor = this.$clickSelection.start;
+ if (range.start.row != cursor.row || range.start.column != cursor.column)
+ cursor = range.end;
+ } else if (cmpStart == -1 && cmpEnd == 1) {
+ cursor = range.end;
+ anchor = range.start;
+ } else {
+ var orientedRange = calcRangeOrientation(this.$clickSelection, cursor);
+ cursor = orientedRange.cursor;
+ anchor = orientedRange.anchor;
+ }
+ editor.selection.setSelectionAnchor(anchor.row, anchor.column);
+ }
+ editor.selection.selectToPosition(cursor);
+ editor.$blockScrolling--;
+ editor.renderer.scrollCursorIntoView();
+ };
+
+ this.selectEnd =
+ this.selectAllEnd =
+ this.selectByWordsEnd =
+ this.selectByLinesEnd = function() {
+ this.$clickSelection = null;
+ this.editor.unsetStyle("ace_selecting");
+ if (this.editor.renderer.scroller.releaseCapture) {
+ this.editor.renderer.scroller.releaseCapture();
+ }
+ };
+
+ this.focusWait = function() {
+ var distance = calcDistance(this.mousedownEvent.x, this.mousedownEvent.y, this.x, this.y);
+ var time = Date.now();
+
+ if (distance > DRAG_OFFSET || time - this.mousedownEvent.time > this.$focusTimout)
+ this.startSelect(this.mousedownEvent.getDocumentPosition());
+ };
+
+ this.onDoubleClick = function(ev) {
+ var pos = ev.getDocumentPosition();
+ var editor = this.editor;
+ var session = editor.session;
+
+ var range = session.getBracketRange(pos);
+ if (range) {
+ if (range.isEmpty()) {
+ range.start.column--;
+ range.end.column++;
+ }
+ this.setState("select");
+ } else {
+ range = editor.selection.getWordRange(pos.row, pos.column);
+ this.setState("selectByWords");
+ }
+ this.$clickSelection = range;
+ this.select();
+ };
+
+ this.onTripleClick = function(ev) {
+ var pos = ev.getDocumentPosition();
+ var editor = this.editor;
+
+ this.setState("selectByLines");
+ var range = editor.getSelectionRange();
+ if (range.isMultiLine() && range.contains(pos.row, pos.column)) {
+ this.$clickSelection = editor.selection.getLineRange(range.start.row);
+ this.$clickSelection.end = editor.selection.getLineRange(range.end.row).end;
+ } else {
+ this.$clickSelection = editor.selection.getLineRange(pos.row);
+ }
+ this.select();
+ };
+
+ this.onQuadClick = function(ev) {
+ var editor = this.editor;
+
+ editor.selectAll();
+ this.$clickSelection = editor.getSelectionRange();
+ this.setState("selectAll");
+ };
+
+ this.onMouseWheel = function(ev) {
+ if (ev.getAccelKey())
+ return;
+ if (ev.getShiftKey() && ev.wheelY && !ev.wheelX) {
+ ev.wheelX = ev.wheelY;
+ ev.wheelY = 0;
+ }
+
+ var t = ev.domEvent.timeStamp;
+ var dt = t - (this.$lastScrollTime||0);
+
+ var editor = this.editor;
+ var isScrolable = editor.renderer.isScrollableBy(ev.wheelX * ev.speed, ev.wheelY * ev.speed);
+ if (isScrolable || dt < 200) {
+ this.$lastScrollTime = t;
+ editor.renderer.scrollBy(ev.wheelX * ev.speed, ev.wheelY * ev.speed);
+ return ev.stop();
+ }
+ };
+
+ this.onTouchMove = function (ev) {
+ var t = ev.domEvent.timeStamp;
+ var dt = t - (this.$lastScrollTime || 0);
+
+ var editor = this.editor;
+ var isScrolable = editor.renderer.isScrollableBy(ev.wheelX * ev.speed, ev.wheelY * ev.speed);
+ if (isScrolable || dt < 200) {
+ this.$lastScrollTime = t;
+ editor.renderer.scrollBy(ev.wheelX * ev.speed, ev.wheelY * ev.speed);
+ return ev.stop();
+ }
+ };
+
+}).call(DefaultHandlers.prototype);
+
+exports.DefaultHandlers = DefaultHandlers;
+
+function calcDistance(ax, ay, bx, by) {
+ return Math.sqrt(Math.pow(bx - ax, 2) + Math.pow(by - ay, 2));
+}
+
+function calcRangeOrientation(range, cursor) {
+ if (range.start.row == range.end.row)
+ var cmp = 2 * cursor.column - range.start.column - range.end.column;
+ else if (range.start.row == range.end.row - 1 && !range.start.column && !range.end.column)
+ var cmp = cursor.column - 4;
+ else
+ var cmp = 2 * cursor.row - range.start.row - range.end.row;
+
+ if (cmp < 0)
+ return {cursor: range.start, anchor: range.end};
+ else
+ return {cursor: range.end, anchor: range.start};
+}
+
+});
+
+ace.define("ace/tooltip",["require","exports","module","ace/lib/oop","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var dom = require("./lib/dom");
+function Tooltip (parentNode) {
+ this.isOpen = false;
+ this.$element = null;
+ this.$parentNode = parentNode;
+}
+
+(function() {
+ this.$init = function() {
+ this.$element = dom.createElement("div");
+ this.$element.className = "ace_tooltip";
+ this.$element.style.display = "none";
+ this.$parentNode.appendChild(this.$element);
+ return this.$element;
+ };
+ this.getElement = function() {
+ return this.$element || this.$init();
+ };
+ this.setText = function(text) {
+ dom.setInnerText(this.getElement(), text);
+ };
+ this.setHtml = function(html) {
+ this.getElement().innerHTML = html;
+ };
+ this.setPosition = function(x, y) {
+ this.getElement().style.left = x + "px";
+ this.getElement().style.top = y + "px";
+ };
+ this.setClassName = function(className) {
+ dom.addCssClass(this.getElement(), className);
+ };
+ this.show = function(text, x, y) {
+ if (text != null)
+ this.setText(text);
+ if (x != null && y != null)
+ this.setPosition(x, y);
+ if (!this.isOpen) {
+ this.getElement().style.display = "block";
+ this.isOpen = true;
+ }
+ };
+
+ this.hide = function() {
+ if (this.isOpen) {
+ this.getElement().style.display = "none";
+ this.isOpen = false;
+ }
+ };
+ this.getHeight = function() {
+ return this.getElement().offsetHeight;
+ };
+ this.getWidth = function() {
+ return this.getElement().offsetWidth;
+ };
+
+ this.destroy = function() {
+ this.isOpen = false;
+ if (this.$element && this.$element.parentNode) {
+ this.$element.parentNode.removeChild(this.$element);
+ }
+ };
+
+}).call(Tooltip.prototype);
+
+exports.Tooltip = Tooltip;
+});
+
+ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event","ace/tooltip"], function(require, exports, module) {
+"use strict";
+var dom = require("../lib/dom");
+var oop = require("../lib/oop");
+var event = require("../lib/event");
+var Tooltip = require("../tooltip").Tooltip;
+
+function GutterHandler(mouseHandler) {
+ var editor = mouseHandler.editor;
+ var gutter = editor.renderer.$gutterLayer;
+ var tooltip = new GutterTooltip(editor.container);
+
+ mouseHandler.editor.setDefaultHandler("guttermousedown", function(e) {
+ if (!editor.isFocused() || e.getButton() != 0)
+ return;
+ var gutterRegion = gutter.getRegion(e);
+
+ if (gutterRegion == "foldWidgets")
+ return;
+
+ var row = e.getDocumentPosition().row;
+ var selection = editor.session.selection;
+
+ if (e.getShiftKey())
+ selection.selectTo(row, 0);
+ else {
+ if (e.domEvent.detail == 2) {
+ editor.selectAll();
+ return e.preventDefault();
+ }
+ mouseHandler.$clickSelection = editor.selection.getLineRange(row);
+ }
+ mouseHandler.setState("selectByLines");
+ mouseHandler.captureMouse(e);
+ return e.preventDefault();
+ });
+
+
+ var tooltipTimeout, mouseEvent, tooltipAnnotation;
+
+ function showTooltip() {
+ var row = mouseEvent.getDocumentPosition().row;
+ var annotation = gutter.$annotations[row];
+ if (!annotation)
+ return hideTooltip();
+
+ var maxRow = editor.session.getLength();
+ if (row == maxRow) {
+ var screenRow = editor.renderer.pixelToScreenCoordinates(0, mouseEvent.y).row;
+ var pos = mouseEvent.$pos;
+ if (screenRow > editor.session.documentToScreenRow(pos.row, pos.column))
+ return hideTooltip();
+ }
+
+ if (tooltipAnnotation == annotation)
+ return;
+ tooltipAnnotation = annotation.text.join("<br/>");
+
+ tooltip.setHtml(tooltipAnnotation);
+ tooltip.show();
+ editor._signal("showGutterTooltip", tooltip);
+ editor.on("mousewheel", hideTooltip);
+
+ if (mouseHandler.$tooltipFollowsMouse) {
+ moveTooltip(mouseEvent);
+ } else {
+ var gutterElement = mouseEvent.domEvent.target;
+ var rect = gutterElement.getBoundingClientRect();
+ var style = tooltip.getElement().style;
+ style.left = rect.right + "px";
+ style.top = rect.bottom + "px";
+ }
+ }
+
+ function hideTooltip() {
+ if (tooltipTimeout)
+ tooltipTimeout = clearTimeout(tooltipTimeout);
+ if (tooltipAnnotation) {
+ tooltip.hide();
+ tooltipAnnotation = null;
+ editor._signal("hideGutterTooltip", tooltip);
+ editor.removeEventListener("mousewheel", hideTooltip);
+ }
+ }
+
+ function moveTooltip(e) {
+ tooltip.setPosition(e.x, e.y);
+ }
+
+ mouseHandler.editor.setDefaultHandler("guttermousemove", function(e) {
+ var target = e.domEvent.target || e.domEvent.srcElement;
+ if (dom.hasCssClass(target, "ace_fold-widget"))
+ return hideTooltip();
+
+ if (tooltipAnnotation && mouseHandler.$tooltipFollowsMouse)
+ moveTooltip(e);
+
+ mouseEvent = e;
+ if (tooltipTimeout)
+ return;
+ tooltipTimeout = setTimeout(function() {
+ tooltipTimeout = null;
+ if (mouseEvent && !mouseHandler.isMousePressed)
+ showTooltip();
+ else
+ hideTooltip();
+ }, 50);
+ });
+
+ event.addListener(editor.renderer.$gutter, "mouseout", function(e) {
+ mouseEvent = null;
+ if (!tooltipAnnotation || tooltipTimeout)
+ return;
+
+ tooltipTimeout = setTimeout(function() {
+ tooltipTimeout = null;
+ hideTooltip();
+ }, 50);
+ });
+
+ editor.on("changeSession", hideTooltip);
+}
+
+function GutterTooltip(parentNode) {
+ Tooltip.call(this, parentNode);
+}
+
+oop.inherits(GutterTooltip, Tooltip);
+
+(function(){
+ this.setPosition = function(x, y) {
+ var windowWidth = window.innerWidth || document.documentElement.clientWidth;
+ var windowHeight = window.innerHeight || document.documentElement.clientHeight;
+ var width = this.getWidth();
+ var height = this.getHeight();
+ x += 15;
+ y += 15;
+ if (x + width > windowWidth) {
+ x -= (x + width) - windowWidth;
+ }
+ if (y + height > windowHeight) {
+ y -= 20 + height;
+ }
+ Tooltip.prototype.setPosition.call(this, x, y);
+ };
+
+}).call(GutterTooltip.prototype);
+
+
+
+exports.GutterHandler = GutterHandler;
+
+});
+
+ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"], function(require, exports, module) {
+"use strict";
+
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+var MouseEvent = exports.MouseEvent = function(domEvent, editor) {
+ this.domEvent = domEvent;
+ this.editor = editor;
+
+ this.x = this.clientX = domEvent.clientX;
+ this.y = this.clientY = domEvent.clientY;
+
+ this.$pos = null;
+ this.$inSelection = null;
+
+ this.propagationStopped = false;
+ this.defaultPrevented = false;
+};
+
+(function() {
+
+ this.stopPropagation = function() {
+ event.stopPropagation(this.domEvent);
+ this.propagationStopped = true;
+ };
+
+ this.preventDefault = function() {
+ event.preventDefault(this.domEvent);
+ this.defaultPrevented = true;
+ };
+
+ this.stop = function() {
+ this.stopPropagation();
+ this.preventDefault();
+ };
+ this.getDocumentPosition = function() {
+ if (this.$pos)
+ return this.$pos;
+
+ this.$pos = this.editor.renderer.screenToTextCoordinates(this.clientX, this.clientY);
+ return this.$pos;
+ };
+ this.inSelection = function() {
+ if (this.$inSelection !== null)
+ return this.$inSelection;
+
+ var editor = this.editor;
+
+
+ var selectionRange = editor.getSelectionRange();
+ if (selectionRange.isEmpty())
+ this.$inSelection = false;
+ else {
+ var pos = this.getDocumentPosition();
+ this.$inSelection = selectionRange.contains(pos.row, pos.column);
+ }
+
+ return this.$inSelection;
+ };
+ this.getButton = function() {
+ return event.getButton(this.domEvent);
+ };
+ this.getShiftKey = function() {
+ return this.domEvent.shiftKey;
+ };
+
+ this.getAccelKey = useragent.isMac
+ ? function() { return this.domEvent.metaKey; }
+ : function() { return this.domEvent.ctrlKey; };
+
+}).call(MouseEvent.prototype);
+
+});
+
+ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"], function(require, exports, module) {
+"use strict";
+
+var dom = require("../lib/dom");
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+
+var AUTOSCROLL_DELAY = 200;
+var SCROLL_CURSOR_DELAY = 200;
+var SCROLL_CURSOR_HYSTERESIS = 5;
+
+function DragdropHandler(mouseHandler) {
+
+ var editor = mouseHandler.editor;
+
+ var blankImage = dom.createElement("img");
+ blankImage.src = "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==";
+ if (useragent.isOpera)
+ blankImage.style.cssText = "width:1px;height:1px;position:fixed;top:0;left:0;z-index:2147483647;opacity:0;";
+
+ var exports = ["dragWait", "dragWaitEnd", "startDrag", "dragReadyEnd", "onMouseDrag"];
+
+ exports.forEach(function(x) {
+ mouseHandler[x] = this[x];
+ }, this);
+ editor.addEventListener("mousedown", this.onMouseDown.bind(mouseHandler));
+
+
+ var mouseTarget = editor.container;
+ var dragSelectionMarker, x, y;
+ var timerId, range;
+ var dragCursor, counter = 0;
+ var dragOperation;
+ var isInternal;
+ var autoScrollStartTime;
+ var cursorMovedTime;
+ var cursorPointOnCaretMoved;
+
+ this.onDragStart = function(e) {
+ if (this.cancelDrag || !mouseTarget.draggable) {
+ var self = this;
+ setTimeout(function(){
+ self.startSelect();
+ self.captureMouse(e);
+ }, 0);
+ return e.preventDefault();
+ }
+ range = editor.getSelectionRange();
+
+ var dataTransfer = e.dataTransfer;
+ dataTransfer.effectAllowed = editor.getReadOnly() ? "copy" : "copyMove";
+ if (useragent.isOpera) {
+ editor.container.appendChild(blankImage);
+ blankImage.scrollTop = 0;
+ }
+ dataTransfer.setDragImage && dataTransfer.setDragImage(blankImage, 0, 0);
+ if (useragent.isOpera) {
+ editor.container.removeChild(blankImage);
+ }
+ dataTransfer.clearData();
+ dataTransfer.setData("Text", editor.session.getTextRange());
+
+ isInternal = true;
+ this.setState("drag");
+ };
+
+ this.onDragEnd = function(e) {
+ mouseTarget.draggable = false;
+ isInternal = false;
+ this.setState(null);
+ if (!editor.getReadOnly()) {
+ var dropEffect = e.dataTransfer.dropEffect;
+ if (!dragOperation && dropEffect == "move")
+ editor.session.remove(editor.getSelectionRange());
+ editor.renderer.$cursorLayer.setBlinking(true);
+ }
+ this.editor.unsetStyle("ace_dragging");
+ this.editor.renderer.setCursorStyle("");
+ };
+
+ this.onDragEnter = function(e) {
+ if (editor.getReadOnly() || !canAccept(e.dataTransfer))
+ return;
+ x = e.clientX;
+ y = e.clientY;
+ if (!dragSelectionMarker)
+ addDragMarker();
+ counter++;
+ e.dataTransfer.dropEffect = dragOperation = getDropEffect(e);
+ return event.preventDefault(e);
+ };
+
+ this.onDragOver = function(e) {
+ if (editor.getReadOnly() || !canAccept(e.dataTransfer))
+ return;
+ x = e.clientX;
+ y = e.clientY;
+ if (!dragSelectionMarker) {
+ addDragMarker();
+ counter++;
+ }
+ if (onMouseMoveTimer !== null)
+ onMouseMoveTimer = null;
+
+ e.dataTransfer.dropEffect = dragOperation = getDropEffect(e);
+ return event.preventDefault(e);
+ };
+
+ this.onDragLeave = function(e) {
+ counter--;
+ if (counter <= 0 && dragSelectionMarker) {
+ clearDragMarker();
+ dragOperation = null;
+ return event.preventDefault(e);
+ }
+ };
+
+ this.onDrop = function(e) {
+ if (!dragCursor)
+ return;
+ var dataTransfer = e.dataTransfer;
+ if (isInternal) {
+ switch (dragOperation) {
+ case "move":
+ if (range.contains(dragCursor.row, dragCursor.column)) {
+ range = {
+ start: dragCursor,
+ end: dragCursor
+ };
+ } else {
+ range = editor.moveText(range, dragCursor);
+ }
+ break;
+ case "copy":
+ range = editor.moveText(range, dragCursor, true);
+ break;
+ }
+ } else {
+ var dropData = dataTransfer.getData('Text');
+ range = {
+ start: dragCursor,
+ end: editor.session.insert(dragCursor, dropData)
+ };
+ editor.focus();
+ dragOperation = null;
+ }
+ clearDragMarker();
+ return event.preventDefault(e);
+ };
+
+ event.addListener(mouseTarget, "dragstart", this.onDragStart.bind(mouseHandler));
+ event.addListener(mouseTarget, "dragend", this.onDragEnd.bind(mouseHandler));
+ event.addListener(mouseTarget, "dragenter", this.onDragEnter.bind(mouseHandler));
+ event.addListener(mouseTarget, "dragover", this.onDragOver.bind(mouseHandler));
+ event.addListener(mouseTarget, "dragleave", this.onDragLeave.bind(mouseHandler));
+ event.addListener(mouseTarget, "drop", this.onDrop.bind(mouseHandler));
+
+ function scrollCursorIntoView(cursor, prevCursor) {
+ var now = Date.now();
+ var vMovement = !prevCursor || cursor.row != prevCursor.row;
+ var hMovement = !prevCursor || cursor.column != prevCursor.column;
+ if (!cursorMovedTime || vMovement || hMovement) {
+ editor.$blockScrolling += 1;
+ editor.moveCursorToPosition(cursor);
+ editor.$blockScrolling -= 1;
+ cursorMovedTime = now;
+ cursorPointOnCaretMoved = {x: x, y: y};
+ } else {
+ var distance = calcDistance(cursorPointOnCaretMoved.x, cursorPointOnCaretMoved.y, x, y);
+ if (distance > SCROLL_CURSOR_HYSTERESIS) {
+ cursorMovedTime = null;
+ } else if (now - cursorMovedTime >= SCROLL_CURSOR_DELAY) {
+ editor.renderer.scrollCursorIntoView();
+ cursorMovedTime = null;
+ }
+ }
+ }
+
+ function autoScroll(cursor, prevCursor) {
+ var now = Date.now();
+ var lineHeight = editor.renderer.layerConfig.lineHeight;
+ var characterWidth = editor.renderer.layerConfig.characterWidth;
+ var editorRect = editor.renderer.scroller.getBoundingClientRect();
+ var offsets = {
+ x: {
+ left: x - editorRect.left,
+ right: editorRect.right - x
+ },
+ y: {
+ top: y - editorRect.top,
+ bottom: editorRect.bottom - y
+ }
+ };
+ var nearestXOffset = Math.min(offsets.x.left, offsets.x.right);
+ var nearestYOffset = Math.min(offsets.y.top, offsets.y.bottom);
+ var scrollCursor = {row: cursor.row, column: cursor.column};
+ if (nearestXOffset / characterWidth <= 2) {
+ scrollCursor.column += (offsets.x.left < offsets.x.right ? -3 : +2);
+ }
+ if (nearestYOffset / lineHeight <= 1) {
+ scrollCursor.row += (offsets.y.top < offsets.y.bottom ? -1 : +1);
+ }
+ var vScroll = cursor.row != scrollCursor.row;
+ var hScroll = cursor.column != scrollCursor.column;
+ var vMovement = !prevCursor || cursor.row != prevCursor.row;
+ if (vScroll || (hScroll && !vMovement)) {
+ if (!autoScrollStartTime)
+ autoScrollStartTime = now;
+ else if (now - autoScrollStartTime >= AUTOSCROLL_DELAY)
+ editor.renderer.scrollCursorIntoView(scrollCursor);
+ } else {
+ autoScrollStartTime = null;
+ }
+ }
+
+ function onDragInterval() {
+ var prevCursor = dragCursor;
+ dragCursor = editor.renderer.screenToTextCoordinates(x, y);
+ scrollCursorIntoView(dragCursor, prevCursor);
+ autoScroll(dragCursor, prevCursor);
+ }
+
+ function addDragMarker() {
+ range = editor.selection.toOrientedRange();
+ dragSelectionMarker = editor.session.addMarker(range, "ace_selection", editor.getSelectionStyle());
+ editor.clearSelection();
+ if (editor.isFocused())
+ editor.renderer.$cursorLayer.setBlinking(false);
+ clearInterval(timerId);
+ onDragInterval();
+ timerId = setInterval(onDragInterval, 20);
+ counter = 0;
+ event.addListener(document, "mousemove", onMouseMove);
+ }
+
+ function clearDragMarker() {
+ clearInterval(timerId);
+ editor.session.removeMarker(dragSelectionMarker);
+ dragSelectionMarker = null;
+ editor.$blockScrolling += 1;
+ editor.selection.fromOrientedRange(range);
+ editor.$blockScrolling -= 1;
+ if (editor.isFocused() && !isInternal)
+ editor.renderer.$cursorLayer.setBlinking(!editor.getReadOnly());
+ range = null;
+ dragCursor = null;
+ counter = 0;
+ autoScrollStartTime = null;
+ cursorMovedTime = null;
+ event.removeListener(document, "mousemove", onMouseMove);
+ }
+ var onMouseMoveTimer = null;
+ function onMouseMove() {
+ if (onMouseMoveTimer == null) {
+ onMouseMoveTimer = setTimeout(function() {
+ if (onMouseMoveTimer != null && dragSelectionMarker)
+ clearDragMarker();
+ }, 20);
+ }
+ }
+
+ function canAccept(dataTransfer) {
+ var types = dataTransfer.types;
+ return !types || Array.prototype.some.call(types, function(type) {
+ return type == 'text/plain' || type == 'Text';
+ });
+ }
+
+ function getDropEffect(e) {
+ var copyAllowed = ['copy', 'copymove', 'all', 'uninitialized'];
+ var moveAllowed = ['move', 'copymove', 'linkmove', 'all', 'uninitialized'];
+
+ var copyModifierState = useragent.isMac ? e.altKey : e.ctrlKey;
+ var effectAllowed = "uninitialized";
+ try {
+ effectAllowed = e.dataTransfer.effectAllowed.toLowerCase();
+ } catch (e) {}
+ var dropEffect = "none";
+
+ if (copyModifierState && copyAllowed.indexOf(effectAllowed) >= 0)
+ dropEffect = "copy";
+ else if (moveAllowed.indexOf(effectAllowed) >= 0)
+ dropEffect = "move";
+ else if (copyAllowed.indexOf(effectAllowed) >= 0)
+ dropEffect = "copy";
+
+ return dropEffect;
+ }
+}
+
+(function() {
+
+ this.dragWait = function() {
+ var interval = Date.now() - this.mousedownEvent.time;
+ if (interval > this.editor.getDragDelay())
+ this.startDrag();
+ };
+
+ this.dragWaitEnd = function() {
+ var target = this.editor.container;
+ target.draggable = false;
+ this.startSelect(this.mousedownEvent.getDocumentPosition());
+ this.selectEnd();
+ };
+
+ this.dragReadyEnd = function(e) {
+ this.editor.renderer.$cursorLayer.setBlinking(!this.editor.getReadOnly());
+ this.editor.unsetStyle("ace_dragging");
+ this.editor.renderer.setCursorStyle("");
+ this.dragWaitEnd();
+ };
+
+ this.startDrag = function(){
+ this.cancelDrag = false;
+ var editor = this.editor;
+ var target = editor.container;
+ target.draggable = true;
+ editor.renderer.$cursorLayer.setBlinking(false);
+ editor.setStyle("ace_dragging");
+ var cursorStyle = useragent.isWin ? "default" : "move";
+ editor.renderer.setCursorStyle(cursorStyle);
+ this.setState("dragReady");
+ };
+
+ this.onMouseDrag = function(e) {
+ var target = this.editor.container;
+ if (useragent.isIE && this.state == "dragReady") {
+ var distance = calcDistance(this.mousedownEvent.x, this.mousedownEvent.y, this.x, this.y);
+ if (distance > 3)
+ target.dragDrop();
+ }
+ if (this.state === "dragWait") {
+ var distance = calcDistance(this.mousedownEvent.x, this.mousedownEvent.y, this.x, this.y);
+ if (distance > 0) {
+ target.draggable = false;
+ this.startSelect(this.mousedownEvent.getDocumentPosition());
+ }
+ }
+ };
+
+ this.onMouseDown = function(e) {
+ if (!this.$dragEnabled)
+ return;
+ this.mousedownEvent = e;
+ var editor = this.editor;
+
+ var inSelection = e.inSelection();
+ var button = e.getButton();
+ var clickCount = e.domEvent.detail || 1;
+ if (clickCount === 1 && button === 0 && inSelection) {
+ if (e.editor.inMultiSelectMode && (e.getAccelKey() || e.getShiftKey()))
+ return;
+ this.mousedownEvent.time = Date.now();
+ var eventTarget = e.domEvent.target || e.domEvent.srcElement;
+ if ("unselectable" in eventTarget)
+ eventTarget.unselectable = "on";
+ if (editor.getDragDelay()) {
+ if (useragent.isWebKit) {
+ this.cancelDrag = true;
+ var mouseTarget = editor.container;
+ mouseTarget.draggable = true;
+ }
+ this.setState("dragWait");
+ } else {
+ this.startDrag();
+ }
+ this.captureMouse(e, this.onMouseDrag.bind(this));
+ e.defaultPrevented = true;
+ }
+ };
+
+}).call(DragdropHandler.prototype);
+
+
+function calcDistance(ax, ay, bx, by) {
+ return Math.sqrt(Math.pow(bx - ax, 2) + Math.pow(by - ay, 2));
+}
+
+exports.DragdropHandler = DragdropHandler;
+
+});
+
+ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+var dom = require("./dom");
+
+exports.get = function (url, callback) {
+ var xhr = new XMLHttpRequest();
+ xhr.open('GET', url, true);
+ xhr.onreadystatechange = function () {
+ if (xhr.readyState === 4) {
+ callback(xhr.responseText);
+ }
+ };
+ xhr.send(null);
+};
+
+exports.loadScript = function(path, callback) {
+ var head = dom.getDocumentHead();
+ var s = document.createElement('script');
+
+ s.src = path;
+ head.appendChild(s);
+
+ s.onload = s.onreadystatechange = function(_, isAbort) {
+ if (isAbort || !s.readyState || s.readyState == "loaded" || s.readyState == "complete") {
+ s = s.onload = s.onreadystatechange = null;
+ if (!isAbort)
+ callback();
+ }
+ };
+};
+exports.qualifyURL = function(url) {
+ var a = document.createElement('a');
+ a.href = url;
+ return a.href;
+}
+
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/lib/app_config",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"no use strict";
+
+var oop = require("./oop");
+var EventEmitter = require("./event_emitter").EventEmitter;
+
+var optionsProvider = {
+ setOptions: function(optList) {
+ Object.keys(optList).forEach(function(key) {
+ this.setOption(key, optList[key]);
+ }, this);
+ },
+ getOptions: function(optionNames) {
+ var result = {};
+ if (!optionNames) {
+ optionNames = Object.keys(this.$options);
+ } else if (!Array.isArray(optionNames)) {
+ result = optionNames;
+ optionNames = Object.keys(result);
+ }
+ optionNames.forEach(function(key) {
+ result[key] = this.getOption(key);
+ }, this);
+ return result;
+ },
+ setOption: function(name, value) {
+ if (this["$" + name] === value)
+ return;
+ var opt = this.$options[name];
+ if (!opt) {
+ return warn('misspelled option "' + name + '"');
+ }
+ if (opt.forwardTo)
+ return this[opt.forwardTo] && this[opt.forwardTo].setOption(name, value);
+
+ if (!opt.handlesSet)
+ this["$" + name] = value;
+ if (opt && opt.set)
+ opt.set.call(this, value);
+ },
+ getOption: function(name) {
+ var opt = this.$options[name];
+ if (!opt) {
+ return warn('misspelled option "' + name + '"');
+ }
+ if (opt.forwardTo)
+ return this[opt.forwardTo] && this[opt.forwardTo].getOption(name);
+ return opt && opt.get ? opt.get.call(this) : this["$" + name];
+ }
+};
+
+function warn(message) {
+ if (typeof console != "undefined" && console.warn)
+ console.warn.apply(console, arguments);
+}
+
+function reportError(msg, data) {
+ var e = new Error(msg);
+ e.data = data;
+ if (typeof console == "object" && console.error)
+ console.error(e);
+ setTimeout(function() { throw e; });
+}
+
+var AppConfig = function() {
+ this.$defaultOptions = {};
+};
+
+(function() {
+ oop.implement(this, EventEmitter);
+ this.defineOptions = function(obj, path, options) {
+ if (!obj.$options)
+ this.$defaultOptions[path] = obj.$options = {};
+
+ Object.keys(options).forEach(function(key) {
+ var opt = options[key];
+ if (typeof opt == "string")
+ opt = {forwardTo: opt};
+
+ opt.name || (opt.name = key);
+ obj.$options[opt.name] = opt;
+ if ("initialValue" in opt)
+ obj["$" + opt.name] = opt.initialValue;
+ });
+ oop.implement(obj, optionsProvider);
+
+ return this;
+ };
+
+ this.resetOptions = function(obj) {
+ Object.keys(obj.$options).forEach(function(key) {
+ var opt = obj.$options[key];
+ if ("value" in opt)
+ obj.setOption(key, opt.value);
+ });
+ };
+
+ this.setDefaultValue = function(path, name, value) {
+ var opts = this.$defaultOptions[path] || (this.$defaultOptions[path] = {});
+ if (opts[name]) {
+ if (opts.forwardTo)
+ this.setDefaultValue(opts.forwardTo, name, value);
+ else
+ opts[name].value = value;
+ }
+ };
+
+ this.setDefaultValues = function(path, optionHash) {
+ Object.keys(optionHash).forEach(function(key) {
+ this.setDefaultValue(path, key, optionHash[key]);
+ }, this);
+ };
+
+ this.warn = warn;
+ this.reportError = reportError;
+
+}).call(AppConfig.prototype);
+
+exports.AppConfig = AppConfig;
+
+});
+
+ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/lib/net","ace/lib/app_config"], function(require, exports, module) {
+"no use strict";
+
+var lang = require("./lib/lang");
+var oop = require("./lib/oop");
+var net = require("./lib/net");
+var AppConfig = require("./lib/app_config").AppConfig;
+
+module.exports = exports = new AppConfig();
+
+var global = (function() {
+ return this || typeof window != "undefined" && window;
+})();
+
+var options = {
+ packaged: false,
+ workerPath: null,
+ modePath: null,
+ themePath: null,
+ basePath: "",
+ suffix: ".js",
+ $moduleUrls: {}
+};
+
+exports.get = function(key) {
+ if (!options.hasOwnProperty(key))
+ throw new Error("Unknown config key: " + key);
+
+ return options[key];
+};
+
+exports.set = function(key, value) {
+ if (!options.hasOwnProperty(key))
+ throw new Error("Unknown config key: " + key);
+
+ options[key] = value;
+};
+
+exports.all = function() {
+ return lang.copyObject(options);
+};
+exports.moduleUrl = function(name, component) {
+ if (options.$moduleUrls[name])
+ return options.$moduleUrls[name];
+
+ var parts = name.split("/");
+ component = component || parts[parts.length - 2] || "";
+ var sep = component == "snippets" ? "/" : "-";
+ var base = parts[parts.length - 1];
+ if (component == "worker" && sep == "-") {
+ var re = new RegExp("^" + component + "[\\-_]|[\\-_]" + component + "$", "g");
+ base = base.replace(re, "");
+ }
+
+ if ((!base || base == component) && parts.length > 1)
+ base = parts[parts.length - 2];
+ var path = options[component + "Path"];
+ if (path == null) {
+ path = options.basePath;
+ } else if (sep == "/") {
+ component = sep = "";
+ }
+ if (path && path.slice(-1) != "/")
+ path += "/";
+ return path + component + sep + base + this.get("suffix");
+};
+
+exports.setModuleUrl = function(name, subst) {
+ return options.$moduleUrls[name] = subst;
+};
+
+exports.$loading = {};
+exports.loadModule = function(moduleName, onLoad) {
+ var module, moduleType;
+ if (Array.isArray(moduleName)) {
+ moduleType = moduleName[0];
+ moduleName = moduleName[1];
+ }
+
+ try {
+ module = require(moduleName);
+ } catch (e) {}
+ if (module && !exports.$loading[moduleName])
+ return onLoad && onLoad(module);
+
+ if (!exports.$loading[moduleName])
+ exports.$loading[moduleName] = [];
+
+ exports.$loading[moduleName].push(onLoad);
+
+ if (exports.$loading[moduleName].length > 1)
+ return;
+
+ var afterLoad = function() {
+ require([moduleName], function(module) {
+ exports._emit("load.module", {name: moduleName, module: module});
+ var listeners = exports.$loading[moduleName];
+ exports.$loading[moduleName] = null;
+ listeners.forEach(function(onLoad) {
+ onLoad && onLoad(module);
+ });
+ });
+ };
+
+ if (!exports.get("packaged"))
+ return afterLoad();
+ net.loadScript(exports.moduleUrl(moduleName, moduleType), afterLoad);
+};
+init(true);function init(packaged) {
+
+ if (!global || !global.document)
+ return;
+
+ options.packaged = packaged || require.packaged || module.packaged || (global.define && define.packaged);
+
+ var scriptOptions = {};
+ var scriptUrl = "";
+ var currentScript = (document.currentScript || document._currentScript ); // native or polyfill
+ var currentDocument = currentScript && currentScript.ownerDocument || document;
+
+ var scripts = currentDocument.getElementsByTagName("script");
+ for (var i=0; i<scripts.length; i++) {
+ var script = scripts[i];
+
+ var src = script.src || script.getAttribute("src");
+ if (!src)
+ continue;
+
+ var attributes = script.attributes;
+ for (var j=0, l=attributes.length; j < l; j++) {
+ var attr = attributes[j];
+ if (attr.name.indexOf("data-ace-") === 0) {
+ scriptOptions[deHyphenate(attr.name.replace(/^data-ace-/, ""))] = attr.value;
+ }
+ }
+
+ var m = src.match(/^(.*)\/ace(\-\w+)?\.js(\?|$)/);
+ if (m)
+ scriptUrl = m[1];
+ }
+
+ if (scriptUrl) {
+ scriptOptions.base = scriptOptions.base || scriptUrl;
+ scriptOptions.packaged = true;
+ }
+
+ scriptOptions.basePath = scriptOptions.base;
+ scriptOptions.workerPath = scriptOptions.workerPath || scriptOptions.base;
+ scriptOptions.modePath = scriptOptions.modePath || scriptOptions.base;
+ scriptOptions.themePath = scriptOptions.themePath || scriptOptions.base;
+ delete scriptOptions.base;
+
+ for (var key in scriptOptions)
+ if (typeof scriptOptions[key] !== "undefined")
+ exports.set(key, scriptOptions[key]);
+}
+
+exports.init = init;
+
+function deHyphenate(str) {
+ return str.replace(/-(.)/g, function(m, m1) { return m1.toUpperCase(); });
+}
+
+});
+
+ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/config"], function(require, exports, module) {
+"use strict";
+
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+var DefaultHandlers = require("./default_handlers").DefaultHandlers;
+var DefaultGutterHandler = require("./default_gutter_handler").GutterHandler;
+var MouseEvent = require("./mouse_event").MouseEvent;
+var DragdropHandler = require("./dragdrop_handler").DragdropHandler;
+var config = require("../config");
+
+var MouseHandler = function(editor) {
+ var _self = this;
+ this.editor = editor;
+
+ new DefaultHandlers(this);
+ new DefaultGutterHandler(this);
+ new DragdropHandler(this);
+
+ var focusEditor = function(e) {
+ var windowBlurred = !document.hasFocus || !document.hasFocus()
+ || !editor.isFocused() && document.activeElement == (editor.textInput && editor.textInput.getElement())
+ if (windowBlurred)
+ window.focus();
+ editor.focus();
+ };
+
+ var mouseTarget = editor.renderer.getMouseEventTarget();
+ event.addListener(mouseTarget, "click", this.onMouseEvent.bind(this, "click"));
+ event.addListener(mouseTarget, "mousemove", this.onMouseMove.bind(this, "mousemove"));
+ event.addMultiMouseDownListener([
+ mouseTarget,
+ editor.renderer.scrollBarV && editor.renderer.scrollBarV.inner,
+ editor.renderer.scrollBarH && editor.renderer.scrollBarH.inner,
+ editor.textInput && editor.textInput.getElement()
+ ].filter(Boolean), [400, 300, 250], this, "onMouseEvent");
+ event.addMouseWheelListener(editor.container, this.onMouseWheel.bind(this, "mousewheel"));
+ event.addTouchMoveListener(editor.container, this.onTouchMove.bind(this, "touchmove"));
+
+ var gutterEl = editor.renderer.$gutter;
+ event.addListener(gutterEl, "mousedown", this.onMouseEvent.bind(this, "guttermousedown"));
+ event.addListener(gutterEl, "click", this.onMouseEvent.bind(this, "gutterclick"));
+ event.addListener(gutterEl, "dblclick", this.onMouseEvent.bind(this, "gutterdblclick"));
+ event.addListener(gutterEl, "mousemove", this.onMouseEvent.bind(this, "guttermousemove"));
+
+ event.addListener(mouseTarget, "mousedown", focusEditor);
+ event.addListener(gutterEl, "mousedown", focusEditor);
+ if (useragent.isIE && editor.renderer.scrollBarV) {
+ event.addListener(editor.renderer.scrollBarV.element, "mousedown", focusEditor);
+ event.addListener(editor.renderer.scrollBarH.element, "mousedown", focusEditor);
+ }
+
+ editor.on("mousemove", function(e){
+ if (_self.state || _self.$dragDelay || !_self.$dragEnabled)
+ return;
+
+ var character = editor.renderer.screenToTextCoordinates(e.x, e.y);
+ var range = editor.session.selection.getRange();
+ var renderer = editor.renderer;
+
+ if (!range.isEmpty() && range.insideStart(character.row, character.column)) {
+ renderer.setCursorStyle("default");
+ } else {
+ renderer.setCursorStyle("");
+ }
+ });
+};
+
+(function() {
+ this.onMouseEvent = function(name, e) {
+ this.editor._emit(name, new MouseEvent(e, this.editor));
+ };
+
+ this.onMouseMove = function(name, e) {
+ var listeners = this.editor._eventRegistry && this.editor._eventRegistry.mousemove;
+ if (!listeners || !listeners.length)
+ return;
+
+ this.editor._emit(name, new MouseEvent(e, this.editor));
+ };
+
+ this.onMouseWheel = function(name, e) {
+ var mouseEvent = new MouseEvent(e, this.editor);
+ mouseEvent.speed = this.$scrollSpeed * 2;
+ mouseEvent.wheelX = e.wheelX;
+ mouseEvent.wheelY = e.wheelY;
+
+ this.editor._emit(name, mouseEvent);
+ };
+
+ this.onTouchMove = function (name, e) {
+ var mouseEvent = new MouseEvent(e, this.editor);
+ mouseEvent.speed = 1;//this.$scrollSpeed * 2;
+ mouseEvent.wheelX = e.wheelX;
+ mouseEvent.wheelY = e.wheelY;
+ this.editor._emit(name, mouseEvent);
+ };
+
+ this.setState = function(state) {
+ this.state = state;
+ };
+
+ this.captureMouse = function(ev, mouseMoveHandler) {
+ this.x = ev.x;
+ this.y = ev.y;
+
+ this.isMousePressed = true;
+ var renderer = this.editor.renderer;
+ if (renderer.$keepTextAreaAtCursor)
+ renderer.$keepTextAreaAtCursor = null;
+
+ var self = this;
+ var onMouseMove = function(e) {
+ if (!e) return;
+ if (useragent.isWebKit && !e.which && self.releaseMouse)
+ return self.releaseMouse();
+
+ self.x = e.clientX;
+ self.y = e.clientY;
+ mouseMoveHandler && mouseMoveHandler(e);
+ self.mouseEvent = new MouseEvent(e, self.editor);
+ self.$mouseMoved = true;
+ };
+
+ var onCaptureEnd = function(e) {
+ clearInterval(timerId);
+ onCaptureInterval();
+ self[self.state + "End"] && self[self.state + "End"](e);
+ self.state = "";
+ if (renderer.$keepTextAreaAtCursor == null) {
+ renderer.$keepTextAreaAtCursor = true;
+ renderer.$moveTextAreaToCursor();
+ }
+ self.isMousePressed = false;
+ self.$onCaptureMouseMove = self.releaseMouse = null;
+ e && self.onMouseEvent("mouseup", e);
+ };
+
+ var onCaptureInterval = function() {
+ self[self.state] && self[self.state]();
+ self.$mouseMoved = false;
+ };
+
+ if (useragent.isOldIE && ev.domEvent.type == "dblclick") {
+ return setTimeout(function() {onCaptureEnd(ev);});
+ }
+
+ self.$onCaptureMouseMove = onMouseMove;
+ self.releaseMouse = event.capture(this.editor.container, onMouseMove, onCaptureEnd);
+ var timerId = setInterval(onCaptureInterval, 20);
+ };
+ this.releaseMouse = null;
+ this.cancelContextMenu = function() {
+ var stop = function(e) {
+ if (e && e.domEvent && e.domEvent.type != "contextmenu")
+ return;
+ this.editor.off("nativecontextmenu", stop);
+ if (e && e.domEvent)
+ event.stopEvent(e.domEvent);
+ }.bind(this);
+ setTimeout(stop, 10);
+ this.editor.on("nativecontextmenu", stop);
+ };
+}).call(MouseHandler.prototype);
+
+config.defineOptions(MouseHandler.prototype, "mouseHandler", {
+ scrollSpeed: {initialValue: 2},
+ dragDelay: {initialValue: (useragent.isMac ? 150 : 0)},
+ dragEnabled: {initialValue: true},
+ focusTimout: {initialValue: 0},
+ tooltipFollowsMouse: {initialValue: true}
+});
+
+
+exports.MouseHandler = MouseHandler;
+});
+
+ace.define("ace/mouse/fold_handler",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function FoldHandler(editor) {
+
+ editor.on("click", function(e) {
+ var position = e.getDocumentPosition();
+ var session = editor.session;
+ var fold = session.getFoldAt(position.row, position.column, 1);
+ if (fold) {
+ if (e.getAccelKey())
+ session.removeFold(fold);
+ else
+ session.expandFold(fold);
+
+ e.stop();
+ }
+ });
+
+ editor.on("gutterclick", function(e) {
+ var gutterRegion = editor.renderer.$gutterLayer.getRegion(e);
+
+ if (gutterRegion == "foldWidgets") {
+ var row = e.getDocumentPosition().row;
+ var session = editor.session;
+ if (session.foldWidgets && session.foldWidgets[row])
+ editor.session.onFoldWidgetClick(row, e);
+ if (!editor.isFocused())
+ editor.focus();
+ e.stop();
+ }
+ });
+
+ editor.on("gutterdblclick", function(e) {
+ var gutterRegion = editor.renderer.$gutterLayer.getRegion(e);
+
+ if (gutterRegion == "foldWidgets") {
+ var row = e.getDocumentPosition().row;
+ var session = editor.session;
+ var data = session.getParentFoldRangeData(row, true);
+ var range = data.range || data.firstRange;
+
+ if (range) {
+ row = range.start.row;
+ var fold = session.getFoldAt(row, session.getLine(row).length, 1);
+
+ if (fold) {
+ session.removeFold(fold);
+ } else {
+ session.addFold("...", range);
+ editor.renderer.scrollCursorIntoView({row: range.start.row, column: 0});
+ }
+ }
+ e.stop();
+ }
+ });
+}
+
+exports.FoldHandler = FoldHandler;
+
+});
+
+ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"], function(require, exports, module) {
+"use strict";
+
+var keyUtil = require("../lib/keys");
+var event = require("../lib/event");
+
+var KeyBinding = function(editor) {
+ this.$editor = editor;
+ this.$data = {editor: editor};
+ this.$handlers = [];
+ this.setDefaultHandler(editor.commands);
+};
+
+(function() {
+ this.setDefaultHandler = function(kb) {
+ this.removeKeyboardHandler(this.$defaultHandler);
+ this.$defaultHandler = kb;
+ this.addKeyboardHandler(kb, 0);
+ };
+
+ this.setKeyboardHandler = function(kb) {
+ var h = this.$handlers;
+ if (h[h.length - 1] == kb)
+ return;
+
+ while (h[h.length - 1] && h[h.length - 1] != this.$defaultHandler)
+ this.removeKeyboardHandler(h[h.length - 1]);
+
+ this.addKeyboardHandler(kb, 1);
+ };
+
+ this.addKeyboardHandler = function(kb, pos) {
+ if (!kb)
+ return;
+ if (typeof kb == "function" && !kb.handleKeyboard)
+ kb.handleKeyboard = kb;
+ var i = this.$handlers.indexOf(kb);
+ if (i != -1)
+ this.$handlers.splice(i, 1);
+
+ if (pos == undefined)
+ this.$handlers.push(kb);
+ else
+ this.$handlers.splice(pos, 0, kb);
+
+ if (i == -1 && kb.attach)
+ kb.attach(this.$editor);
+ };
+
+ this.removeKeyboardHandler = function(kb) {
+ var i = this.$handlers.indexOf(kb);
+ if (i == -1)
+ return false;
+ this.$handlers.splice(i, 1);
+ kb.detach && kb.detach(this.$editor);
+ return true;
+ };
+
+ this.getKeyboardHandler = function() {
+ return this.$handlers[this.$handlers.length - 1];
+ };
+
+ this.getStatusText = function() {
+ var data = this.$data;
+ var editor = data.editor;
+ return this.$handlers.map(function(h) {
+ return h.getStatusText && h.getStatusText(editor, data) || "";
+ }).filter(Boolean).join(" ");
+ };
+
+ this.$callKeyboardHandlers = function(hashId, keyString, keyCode, e) {
+ var toExecute;
+ var success = false;
+ var commands = this.$editor.commands;
+
+ for (var i = this.$handlers.length; i--;) {
+ toExecute = this.$handlers[i].handleKeyboard(
+ this.$data, hashId, keyString, keyCode, e
+ );
+ if (!toExecute || !toExecute.command)
+ continue;
+ if (toExecute.command == "null") {
+ success = true;
+ } else {
+ success = commands.exec(toExecute.command, this.$editor, toExecute.args, e);
+ }
+ if (success && e && hashId != -1 &&
+ toExecute.passEvent != true && toExecute.command.passEvent != true
+ ) {
+ event.stopEvent(e);
+ }
+ if (success)
+ break;
+ }
+
+ if (!success && hashId == -1) {
+ toExecute = {command: "insertstring"};
+ success = commands.exec("insertstring", this.$editor, keyString);
+ }
+
+ if (success && this.$editor._signal)
+ this.$editor._signal("keyboardActivity", toExecute);
+
+ return success;
+ };
+
+ this.onCommandKey = function(e, hashId, keyCode) {
+ var keyString = keyUtil.keyCodeToString(keyCode);
+ this.$callKeyboardHandlers(hashId, keyString, keyCode, e);
+ };
+
+ this.onTextInput = function(text) {
+ this.$callKeyboardHandlers(-1, text);
+ };
+
+}).call(KeyBinding.prototype);
+
+exports.KeyBinding = KeyBinding;
+});
+
+ace.define("ace/lib/bidiutil",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var ArabicAlefBetIntervalsBegine = ['\u0621', '\u0641'];
+var ArabicAlefBetIntervalsEnd = ['\u063A', '\u064a'];
+var dir = 0, hiLevel = 0;
+var lastArabic = false, hasUBAT_AL = false, hasUBAT_B = false, hasUBAT_S = false, hasBlockSep = false, hasSegSep = false;
+
+var impTab_LTR = [ [ 0, 3, 0, 1, 0, 0, 0 ], [ 0, 3, 0, 1, 2, 2, 0 ], [ 0, 3, 0, 0x11, 2, 0, 1 ], [ 0, 3, 5, 5, 4, 1, 0 ], [ 0, 3, 0x15, 0x15, 4, 0, 1 ], [ 0, 3, 5, 5, 4, 2, 0 ]
+];
+
+var impTab_RTL = [ [ 2, 0, 1, 1, 0, 1, 0 ], [ 2, 0, 1, 1, 0, 2, 0 ], [ 2, 0, 2, 1, 3, 2, 0 ], [ 2, 0, 2, 0x21, 3, 1, 1 ]
+];
+
+var LTR = 0, RTL = 1;
+
+var L = 0;
+var R = 1;
+var EN = 2;
+var AN = 3;
+var ON = 4;
+var B = 5;
+var S = 6;
+var AL = 7;
+var WS = 8;
+var CS = 9;
+var ES = 10;
+var ET = 11;
+var NSM = 12;
+var LRE = 13;
+var RLE = 14;
+var PDF = 15;
+var LRO = 16;
+var RLO = 17;
+var BN = 18;
+
+var UnicodeTBL00 = [
+BN,BN,BN,BN,BN,BN,BN,BN,BN,S,B,S,WS,B,BN,BN,
+BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,B,B,B,S,
+WS,ON,ON,ET,ET,ET,ON,ON,ON,ON,ON,ES,CS,ES,CS,CS,
+EN,EN,EN,EN,EN,EN,EN,EN,EN,EN,CS,ON,ON,ON,ON,ON,
+ON,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,
+L,L,L,L,L,L,L,L,L,L,L,ON,ON,ON,ON,ON,
+ON,L,L,L,L,L,L,L,L,L,L,L,L,L,L,L,
+L,L,L,L,L,L,L,L,L,L,L,ON,ON,ON,ON,BN,
+BN,BN,BN,BN,BN,B,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,
+BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,BN,
+CS,ON,ET,ET,ET,ET,ON,ON,ON,ON,L,ON,ON,BN,ON,ON,
+ET,ET,EN,EN,ON,L,ON,ON,ON,EN,L,ON,ON,ON,ON,ON
+];
+
+var UnicodeTBL20 = [
+WS,WS,WS,WS,WS,WS,WS,WS,WS,WS,WS,BN,BN,BN,L,R ,
+ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,
+ON,ON,ON,ON,ON,ON,ON,ON,WS,B,LRE,RLE,PDF,LRO,RLO,CS,
+ET,ET,ET,ET,ET,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,
+ON,ON,ON,ON,CS,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,
+ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,ON,WS
+];
+
+function _computeLevels(chars, levels, len, charTypes) {
+ var impTab = dir ? impTab_RTL : impTab_LTR
+ , prevState = null, newClass = null, newLevel = null, newState = 0
+ , action = null, cond = null, condPos = -1, i = null, ix = null, classes = [];
+
+ if (!charTypes) {
+ for (i = 0, charTypes = []; i < len; i++) {
+ charTypes[i] = _getCharacterType(chars[i]);
+ }
+ }
+ hiLevel = dir;
+ lastArabic = false;
+ hasUBAT_AL = false;
+ hasUBAT_B = false;
+ hasUBAT_S = false;
+ for (ix = 0; ix < len; ix++){
+ prevState = newState;
+ classes[ix] = newClass = _getCharClass(chars, charTypes, classes, ix);
+ newState = impTab[prevState][newClass];
+ action = newState & 0xF0;
+ newState &= 0x0F;
+ levels[ix] = newLevel = impTab[newState][5];
+ if (action > 0){
+ if (action == 0x10){
+ for(i = condPos; i < ix; i++){
+ levels[i] = 1;
+ }
+ condPos = -1;
+ } else {
+ condPos = -1;
+ }
+ }
+ cond = impTab[newState][6];
+ if (cond){
+ if(condPos == -1){
+ condPos = ix;
+ }
+ }else{
+ if (condPos > -1){
+ for(i = condPos; i < ix; i++){
+ levels[i] = newLevel;
+ }
+ condPos = -1;
+ }
+ }
+ if (charTypes[ix] == B){
+ levels[ix] = 0;
+ }
+ hiLevel |= newLevel;
+ }
+ if (hasUBAT_S){
+ for(i = 0; i < len; i++){
+ if(charTypes[i] == S){
+ levels[i] = dir;
+ for(var j = i - 1; j >= 0; j--){
+ if(charTypes[j] == WS){
+ levels[j] = dir;
+ }else{
+ break;
+ }
+ }
+ }
+ }
+ }
+}
+
+function _invertLevel(lev, levels, _array) {
+ if (hiLevel < lev){
+ return;
+ }
+ if (lev == 1 && dir == RTL && !hasUBAT_B){
+ _array.reverse();
+ return;
+ }
+ var len = _array.length, start = 0, end, lo, hi, tmp;
+ while(start < len){
+ if (levels[start] >= lev){
+ end = start + 1;
+ while(end < len && levels[end] >= lev){
+ end++;
+ }
+ for(lo = start, hi = end - 1 ; lo < hi; lo++, hi--){
+ tmp = _array[lo];
+ _array[lo] = _array[hi];
+ _array[hi] = tmp;
+ }
+ start = end;
+ }
+ start++;
+ }
+}
+
+function _getCharClass(chars, types, classes, ix) {
+ var cType = types[ix], wType, nType, len, i;
+ switch(cType){
+ case L:
+ case R:
+ lastArabic = false;
+ case ON:
+ case AN:
+ return cType;
+ case EN:
+ return lastArabic ? AN : EN;
+ case AL:
+ lastArabic = true;
+ hasUBAT_AL = true;
+ return R;
+ case WS:
+ return ON;
+ case CS:
+ if (ix < 1 || (ix + 1) >= types.length ||
+ ((wType = classes[ix - 1]) != EN && wType != AN) ||
+ ((nType = types[ix + 1]) != EN && nType != AN)){
+ return ON;
+ }
+ if (lastArabic){nType = AN;}
+ return nType == wType ? nType : ON;
+ case ES:
+ wType = ix > 0 ? classes[ix - 1] : B;
+ if (wType == EN && (ix + 1) < types.length && types[ix + 1] == EN){
+ return EN;
+ }
+ return ON;
+ case ET:
+ if (ix > 0 && classes[ix - 1] == EN){
+ return EN;
+ }
+ if (lastArabic){
+ return ON;
+ }
+ i = ix + 1;
+ len = types.length;
+ while (i < len && types[i] == ET){
+ i++;
+ }
+ if (i < len && types[i] == EN){
+ return EN;
+ }
+ return ON;
+ case NSM:
+ len = types.length;
+ i = ix + 1;
+ while (i < len && types[i] == NSM){
+ i++;
+ }
+ if (i < len){
+ var c = chars[ix], rtlCandidate = (c >= 0x0591 && c <= 0x08FF) || c == 0xFB1E;
+
+ wType = types[i];
+ if (rtlCandidate && (wType == R || wType == AL)){
+ return R;
+ }
+ }
+
+ if (ix < 1 || (wType = types[ix - 1]) == B){
+ return ON;
+ }
+ return classes[ix - 1];
+ case B:
+ lastArabic = false;
+ hasUBAT_B = true;
+ return dir;
+ case S:
+ hasUBAT_S = true;
+ return ON;
+ case LRE:
+ case RLE:
+ case LRO:
+ case RLO:
+ case PDF:
+ lastArabic = false;
+ case BN:
+ return ON;
+ }
+}
+
+function _getCharacterType( ch ) {
+ var uc = ch.charCodeAt(0), hi = uc >> 8;
+
+ if (hi == 0) {
+ return ((uc > 0x00BF) ? L : UnicodeTBL00[uc]);
+ } else if (hi == 5) {
+ return (/[\u0591-\u05f4]/.test(ch) ? R : L);
+ } else if (hi == 6) {
+ if (/[\u0610-\u061a\u064b-\u065f\u06d6-\u06e4\u06e7-\u06ed]/.test(ch))
+ return NSM;
+ else if (/[\u0660-\u0669\u066b-\u066c]/.test(ch))
+ return AN;
+ else if (uc == 0x066A)
+ return ET;
+ else if (/[\u06f0-\u06f9]/.test(ch))
+ return EN;
+ else
+ return AL;
+ } else if (hi == 0x20 && uc <= 0x205F) {
+ return UnicodeTBL20[uc & 0xFF];
+ } else if (hi == 0xFE) {
+ return (uc >= 0xFE70 ? AL : ON);
+ }
+ return ON;
+}
+
+function _isArabicDiacritics( ch ) {
+ return (ch >= '\u064b' && ch <= '\u0655');
+}
+exports.L = L;
+exports.R = R;
+exports.EN = EN;
+exports.ON_R = 3;
+exports.AN = 4;
+exports.R_H = 5;
+exports.B = 6;
+
+exports.DOT = "\xB7";
+exports.doBidiReorder = function(text, textCharTypes, isRtl) {
+ if (text.length < 2)
+ return {};
+
+ var chars = text.split(""), logicalFromVisual = new Array(chars.length),
+ bidiLevels = new Array(chars.length), levels = [];
+
+ dir = isRtl ? RTL : LTR;
+
+ _computeLevels(chars, levels, chars.length, textCharTypes);
+
+ for (var i = 0; i < logicalFromVisual.length; logicalFromVisual[i] = i, i++);
+
+ _invertLevel(2, levels, logicalFromVisual);
+ _invertLevel(1, levels, logicalFromVisual);
+
+ for (var i = 0; i < logicalFromVisual.length - 1; i++) { //fix levels to reflect character width
+ if (textCharTypes[i] === AN) {
+ levels[i] = exports.AN;
+ } else if (levels[i] === R && ((textCharTypes[i] > AL && textCharTypes[i] < LRE)
+ || textCharTypes[i] === ON || textCharTypes[i] === BN)) {
+ levels[i] = exports.ON_R;
+ } else if ((i > 0 && chars[i - 1] === '\u0644') && /\u0622|\u0623|\u0625|\u0627/.test(chars[i])) {
+ levels[i - 1] = levels[i] = exports.R_H;
+ i++;
+ }
+ }
+ if (chars[chars.length - 1] === exports.DOT)
+ levels[chars.length - 1] = exports.B;
+
+ for (var i = 0; i < logicalFromVisual.length; i++) {
+ bidiLevels[i] = levels[logicalFromVisual[i]];
+ }
+
+ return {'logicalFromVisual': logicalFromVisual, 'bidiLevels': bidiLevels};
+};
+exports.hasBidiCharacters = function(text, textCharTypes){
+ var ret = false;
+ for (var i = 0; i < text.length; i++){
+ textCharTypes[i] = _getCharacterType(text.charAt(i));
+ if (!ret && (textCharTypes[i] == R || textCharTypes[i] == AL))
+ ret = true;
+ }
+ return ret;
+};
+exports.getVisualFromLogicalIdx = function(logIdx, rowMap) {
+ for (var i = 0; i < rowMap.logicalFromVisual.length; i++) {
+ if (rowMap.logicalFromVisual[i] == logIdx)
+ return i;
+ }
+ return 0;
+};
+
+});
+
+ace.define("ace/bidihandler",["require","exports","module","ace/lib/bidiutil","ace/lib/lang","ace/lib/useragent"], function(require, exports, module) {
+"use strict";
+
+var bidiUtil = require("./lib/bidiutil");
+var lang = require("./lib/lang");
+var useragent = require("./lib/useragent");
+var BidiHandler = function(session) {
+ this.session = session;
+ this.bidiMap = {};
+ this.currentRow = null;
+ this.bidiUtil = bidiUtil;
+ this.charWidths = [];
+ this.EOL = "\xAC";
+ this.showInvisibles = true;
+ this.isRtlDir = false;
+ this.line = "";
+ this.wrapIndent = 0;
+ this.isLastRow = false;
+ this.EOF = "\xB6";
+};
+
+(function() {
+ this.isBidiRow = function(screenRow, docRow, splitIndex) {
+ if (screenRow !== this.currentRow) {
+ this.currentRow = screenRow;
+ this.updateRowLine(docRow, splitIndex);
+ this.updateBidiMap();
+ }
+ return this.bidiMap.bidiLevels;
+ };
+
+ this.getDocumentRow = function() {
+ var docRow = 0;
+ var rowCache = this.session.$screenRowCache;
+ if (rowCache.length) {
+ var index = this.session.$getRowCacheIndex(rowCache, this.currentRow);
+ if (index >= 0)
+ docRow = this.session.$docRowCache[index];
+ }
+
+ return docRow;
+ };
+
+ this.getSplitIndex = function() {
+ var splitIndex = 0;
+ var rowCache = this.session.$screenRowCache;
+ if (rowCache.length) {
+ var currentIndex, prevIndex = this.session.$getRowCacheIndex(rowCache, this.currentRow);
+ while (this.currentRow - splitIndex > 0) {
+ currentIndex = this.session.$getRowCacheIndex(rowCache, this.currentRow - splitIndex - 1);
+ if (currentIndex !== prevIndex)
+ break;
+
+ prevIndex = currentIndex;
+ splitIndex++;
+ }
+ }
+
+ return splitIndex;
+ };
+
+ this.updateRowLine = function(docRow, splitIndex) {
+ if (docRow === undefined)
+ docRow = this.getDocumentRow();
+
+ this.wrapIndent = 0;
+ this.isLastRow = (docRow === this.session.getLength() - 1);
+ this.line = this.session.getLine(docRow);
+ if (this.session.$useWrapMode) {
+ var splits = this.session.$wrapData[docRow];
+ if (splits) {
+ if (splitIndex === undefined)
+ splitIndex = this.getSplitIndex();
+
+ if(splitIndex > 0 && splits.length) {
+ this.wrapIndent = splits.indent;
+ this.line = (splitIndex < splits.length) ?
+ this.line.substring(splits[splitIndex - 1], splits[splits.length - 1]) :
+ this.line.substring(splits[splits.length - 1]);
+ } else {
+ this.line = this.line.substring(0, splits[splitIndex]);
+ }
+ }
+ }
+ var session = this.session, shift = 0, size;
+ this.line = this.line.replace(/\t|[\u1100-\u2029, \u202F-\uFFE6]/g, function(ch, i){
+ if (ch === '\t' || session.isFullWidth(ch.charCodeAt(0))) {
+ size = (ch === '\t') ? session.getScreenTabSize(i + shift) : 2;
+ shift += size - 1;
+ return lang.stringRepeat(bidiUtil.DOT, size);
+ }
+ return ch;
+ });
+ };
+
+ this.updateBidiMap = function() {
+ var textCharTypes = [], endOfLine = this.isLastRow ? this.EOF : this.EOL;
+ var line = this.line + (this.showInvisibles ? endOfLine : bidiUtil.DOT);
+ if (bidiUtil.hasBidiCharacters(line, textCharTypes)) {
+ this.bidiMap = bidiUtil.doBidiReorder(line, textCharTypes, this.isRtlDir);
+ } else {
+ this.bidiMap = {};
+ }
+ };
+ this.markAsDirty = function() {
+ this.currentRow = null;
+ };
+ this.updateCharacterWidths = function($fontMetrics) {
+ var _regularCharWidth = $fontMetrics.$measureCharWidth('a'), _bidiCharWidth = $fontMetrics.$measureCharWidth('\u05d4');
+
+ this.charWidths[bidiUtil.L] = this.charWidths[bidiUtil.EN] = this.charWidths[bidiUtil.ON_R] = _regularCharWidth;
+ this.charWidths[bidiUtil.R] = this.charWidths[bidiUtil.AN] = _bidiCharWidth;
+ this.charWidths[bidiUtil.R_H] = useragent.isChrome ? _bidiCharWidth : _bidiCharWidth * 0.45;
+ this.charWidths[bidiUtil.B] = 0;
+
+ if (this.currentRow !== null) {
+ this.updateBidiMap();
+ }
+ };
+
+ this.getShowInvisibles = function() {
+ return this.showInvisibles;
+ };
+
+ this.setShowInvisibles = function(showInvisibles) {
+ this.showInvisibles = showInvisibles;
+ if (this.currentRow !== null) {
+ this.updateBidiMap();
+ }
+ };
+
+ this.setEolChar = function(eolChar) {
+ this.EOL = eolChar;
+ };
+
+ this.setTextDir = function(isRtlDir) {
+ this.isRtlDir = isRtlDir;
+ };
+ this.getPosLeft = function(col) {
+ col -= this.wrapIndent;
+ var visualIdx = bidiUtil.getVisualFromLogicalIdx(col > 0 ? col - 1 : 0, this.bidiMap),
+ levels = this.bidiMap.bidiLevels, left = 0;
+
+ if (col === 0 && levels[visualIdx] % 2 !== 0)
+ visualIdx++;
+
+ for (var i = 0; i < visualIdx; i++) {
+ left += this.charWidths[levels[i]];
+ }
+
+ if (col !== 0 && levels[visualIdx] % 2 === 0)
+ left += this.charWidths[levels[visualIdx]];
+
+ if (this.wrapIndent)
+ left += this.wrapIndent * this.charWidths[bidiUtil.L];
+
+ return left;
+ };
+ this.getSelections = function(startCol, endCol) {
+ var map = this.bidiMap, levels = map.bidiLevels, level, offset = this.wrapIndent * this.charWidths[bidiUtil.L], selections = [],
+ selColMin = Math.min(startCol, endCol) - this.wrapIndent, selColMax = Math.max(startCol, endCol) - this.wrapIndent,
+ isSelected = false, isSelectedPrev = false, selectionStart = 0;
+
+ for (var logIdx, visIdx = 0; visIdx < levels.length; visIdx++) {
+ logIdx = map.logicalFromVisual[visIdx];
+ level = levels[visIdx];
+ isSelected = (logIdx >= selColMin) && (logIdx < selColMax);
+ if (isSelected && !isSelectedPrev) {
+ selectionStart = offset;
+ } else if (!isSelected && isSelectedPrev) {
+ selections.push({left: selectionStart, width: offset - selectionStart});
+ }
+ offset += this.charWidths[level];
+ isSelectedPrev = isSelected;
+ }
+
+ if (isSelected && (visIdx === levels.length)) {
+ selections.push({left: selectionStart, width: offset - selectionStart});
+ }
+
+ return selections;
+ };
+ this.offsetToCol = function(posX) {
+ var logicalIdx = 0, posX = Math.max(posX, 0),
+ offset = 0, visualIdx = 0, levels = this.bidiMap.bidiLevels,
+ charWidth = this.charWidths[levels[visualIdx]];
+
+ if (this.wrapIndent) {
+ posX -= this.wrapIndent * this.charWidths[bidiUtil.L];
+ }
+
+ while(posX > offset + charWidth/2) {
+ offset += charWidth;
+ if(visualIdx === levels.length - 1) {
+ charWidth = 0;
+ break;
+ }
+ charWidth = this.charWidths[levels[++visualIdx]];
+ }
+
+ if (visualIdx > 0 && (levels[visualIdx - 1] % 2 !== 0) && (levels[visualIdx] % 2 === 0)){
+ if(posX < offset)
+ visualIdx--;
+ logicalIdx = this.bidiMap.logicalFromVisual[visualIdx];
+
+ } else if (visualIdx > 0 && (levels[visualIdx - 1] % 2 === 0) && (levels[visualIdx] % 2 !== 0)){
+ logicalIdx = 1 + ((posX > offset) ? this.bidiMap.logicalFromVisual[visualIdx]
+ : this.bidiMap.logicalFromVisual[visualIdx - 1]);
+
+ } else if ((this.isRtlDir && visualIdx === levels.length - 1 && charWidth === 0 && (levels[visualIdx - 1] % 2 === 0))
+ || (!this.isRtlDir && visualIdx === 0 && (levels[visualIdx] % 2 !== 0))){
+ logicalIdx = 1 + this.bidiMap.logicalFromVisual[visualIdx];
+ } else {
+ if (visualIdx > 0 && (levels[visualIdx - 1] % 2 !== 0) && charWidth !== 0)
+ visualIdx--;
+ logicalIdx = this.bidiMap.logicalFromVisual[visualIdx];
+ }
+
+ return (logicalIdx + this.wrapIndent);
+ };
+
+}).call(BidiHandler.prototype);
+
+exports.BidiHandler = BidiHandler;
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var lang = require("./lib/lang");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Selection = function(session) {
+ this.session = session;
+ this.doc = session.getDocument();
+
+ this.clearSelection();
+ this.lead = this.selectionLead = this.doc.createAnchor(0, 0);
+ this.anchor = this.selectionAnchor = this.doc.createAnchor(0, 0);
+
+ var self = this;
+ this.lead.on("change", function(e) {
+ self._emit("changeCursor");
+ if (!self.$isEmpty)
+ self._emit("changeSelection");
+ if (!self.$keepDesiredColumnOnChange && e.old.column != e.value.column)
+ self.$desiredColumn = null;
+ });
+
+ this.selectionAnchor.on("change", function() {
+ if (!self.$isEmpty)
+ self._emit("changeSelection");
+ });
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.isEmpty = function() {
+ return (this.$isEmpty || (
+ this.anchor.row == this.lead.row &&
+ this.anchor.column == this.lead.column
+ ));
+ };
+ this.isMultiLine = function() {
+ if (this.isEmpty()) {
+ return false;
+ }
+
+ return this.getRange().isMultiLine();
+ };
+ this.getCursor = function() {
+ return this.lead.getPosition();
+ };
+ this.setSelectionAnchor = function(row, column) {
+ this.anchor.setPosition(row, column);
+
+ if (this.$isEmpty) {
+ this.$isEmpty = false;
+ this._emit("changeSelection");
+ }
+ };
+ this.getSelectionAnchor = function() {
+ if (this.$isEmpty)
+ return this.getSelectionLead();
+ else
+ return this.anchor.getPosition();
+ };
+ this.getSelectionLead = function() {
+ return this.lead.getPosition();
+ };
+ this.shiftSelection = function(columns) {
+ if (this.$isEmpty) {
+ this.moveCursorTo(this.lead.row, this.lead.column + columns);
+ return;
+ }
+
+ var anchor = this.getSelectionAnchor();
+ var lead = this.getSelectionLead();
+
+ var isBackwards = this.isBackwards();
+
+ if (!isBackwards || anchor.column !== 0)
+ this.setSelectionAnchor(anchor.row, anchor.column + columns);
+
+ if (isBackwards || lead.column !== 0) {
+ this.$moveSelection(function() {
+ this.moveCursorTo(lead.row, lead.column + columns);
+ });
+ }
+ };
+ this.isBackwards = function() {
+ var anchor = this.anchor;
+ var lead = this.lead;
+ return (anchor.row > lead.row || (anchor.row == lead.row && anchor.column > lead.column));
+ };
+ this.getRange = function() {
+ var anchor = this.anchor;
+ var lead = this.lead;
+
+ if (this.isEmpty())
+ return Range.fromPoints(lead, lead);
+
+ if (this.isBackwards()) {
+ return Range.fromPoints(lead, anchor);
+ }
+ else {
+ return Range.fromPoints(anchor, lead);
+ }
+ };
+ this.clearSelection = function() {
+ if (!this.$isEmpty) {
+ this.$isEmpty = true;
+ this._emit("changeSelection");
+ }
+ };
+ this.selectAll = function() {
+ var lastRow = this.doc.getLength() - 1;
+ this.setSelectionAnchor(0, 0);
+ this.moveCursorTo(lastRow, this.doc.getLine(lastRow).length);
+ };
+ this.setRange =
+ this.setSelectionRange = function(range, reverse) {
+ if (reverse) {
+ this.setSelectionAnchor(range.end.row, range.end.column);
+ this.selectTo(range.start.row, range.start.column);
+ } else {
+ this.setSelectionAnchor(range.start.row, range.start.column);
+ this.selectTo(range.end.row, range.end.column);
+ }
+ if (this.getRange().isEmpty())
+ this.$isEmpty = true;
+ this.$desiredColumn = null;
+ };
+
+ this.$moveSelection = function(mover) {
+ var lead = this.lead;
+ if (this.$isEmpty)
+ this.setSelectionAnchor(lead.row, lead.column);
+
+ mover.call(this);
+ };
+ this.selectTo = function(row, column) {
+ this.$moveSelection(function() {
+ this.moveCursorTo(row, column);
+ });
+ };
+ this.selectToPosition = function(pos) {
+ this.$moveSelection(function() {
+ this.moveCursorToPosition(pos);
+ });
+ };
+ this.moveTo = function(row, column) {
+ this.clearSelection();
+ this.moveCursorTo(row, column);
+ };
+ this.moveToPosition = function(pos) {
+ this.clearSelection();
+ this.moveCursorToPosition(pos);
+ };
+ this.selectUp = function() {
+ this.$moveSelection(this.moveCursorUp);
+ };
+ this.selectDown = function() {
+ this.$moveSelection(this.moveCursorDown);
+ };
+ this.selectRight = function() {
+ this.$moveSelection(this.moveCursorRight);
+ };
+ this.selectLeft = function() {
+ this.$moveSelection(this.moveCursorLeft);
+ };
+ this.selectLineStart = function() {
+ this.$moveSelection(this.moveCursorLineStart);
+ };
+ this.selectLineEnd = function() {
+ this.$moveSelection(this.moveCursorLineEnd);
+ };
+ this.selectFileEnd = function() {
+ this.$moveSelection(this.moveCursorFileEnd);
+ };
+ this.selectFileStart = function() {
+ this.$moveSelection(this.moveCursorFileStart);
+ };
+ this.selectWordRight = function() {
+ this.$moveSelection(this.moveCursorWordRight);
+ };
+ this.selectWordLeft = function() {
+ this.$moveSelection(this.moveCursorWordLeft);
+ };
+ this.getWordRange = function(row, column) {
+ if (typeof column == "undefined") {
+ var cursor = row || this.lead;
+ row = cursor.row;
+ column = cursor.column;
+ }
+ return this.session.getWordRange(row, column);
+ };
+ this.selectWord = function() {
+ this.setSelectionRange(this.getWordRange());
+ };
+ this.selectAWord = function() {
+ var cursor = this.getCursor();
+ var range = this.session.getAWordRange(cursor.row, cursor.column);
+ this.setSelectionRange(range);
+ };
+
+ this.getLineRange = function(row, excludeLastChar) {
+ var rowStart = typeof row == "number" ? row : this.lead.row;
+ var rowEnd;
+
+ var foldLine = this.session.getFoldLine(rowStart);
+ if (foldLine) {
+ rowStart = foldLine.start.row;
+ rowEnd = foldLine.end.row;
+ } else {
+ rowEnd = rowStart;
+ }
+ if (excludeLastChar === true)
+ return new Range(rowStart, 0, rowEnd, this.session.getLine(rowEnd).length);
+ else
+ return new Range(rowStart, 0, rowEnd + 1, 0);
+ };
+ this.selectLine = function() {
+ this.setSelectionRange(this.getLineRange());
+ };
+ this.moveCursorUp = function() {
+ this.moveCursorBy(-1, 0);
+ };
+ this.moveCursorDown = function() {
+ this.moveCursorBy(1, 0);
+ };
+ this.wouldMoveIntoSoftTab = function(cursor, tabSize, direction) {
+ var start = cursor.column;
+ var end = cursor.column + tabSize;
+
+ if (direction < 0) {
+ start = cursor.column - tabSize;
+ end = cursor.column;
+ }
+ return this.session.isTabStop(cursor) && this.doc.getLine(cursor.row).slice(start, end).split(" ").length-1 == tabSize
+ }
+ this.moveCursorLeft = function() {
+ var cursor = this.lead.getPosition(),
+ fold;
+
+ if (fold = this.session.getFoldAt(cursor.row, cursor.column, -1)) {
+ this.moveCursorTo(fold.start.row, fold.start.column);
+ } else if (cursor.column === 0) {
+ if (cursor.row > 0) {
+ this.moveCursorTo(cursor.row - 1, this.doc.getLine(cursor.row - 1).length);
+ }
+ }
+ else {
+ var tabSize = this.session.getTabSize();
+ if (this.wouldMoveIntoSoftTab(cursor, tabSize, -1) && !this.session.getNavigateWithinSoftTabs()) {
+ this.moveCursorBy(0, -tabSize);
+ } else {
+ this.moveCursorBy(0, -1);
+ }
+ }
+ };
+ this.moveCursorRight = function() {
+ var cursor = this.lead.getPosition(),
+ fold;
+ if (fold = this.session.getFoldAt(cursor.row, cursor.column, 1)) {
+ this.moveCursorTo(fold.end.row, fold.end.column);
+ }
+ else if (this.lead.column == this.doc.getLine(this.lead.row).length) {
+ if (this.lead.row < this.doc.getLength() - 1) {
+ this.moveCursorTo(this.lead.row + 1, 0);
+ }
+ }
+ else {
+ var tabSize = this.session.getTabSize();
+ var cursor = this.lead;
+ if (this.wouldMoveIntoSoftTab(cursor, tabSize, 1) && !this.session.getNavigateWithinSoftTabs()) {
+ this.moveCursorBy(0, tabSize);
+ } else {
+ this.moveCursorBy(0, 1);
+ }
+ }
+ };
+ this.moveCursorLineStart = function() {
+ var row = this.lead.row;
+ var column = this.lead.column;
+ var screenRow = this.session.documentToScreenRow(row, column);
+ var firstColumnPosition = this.session.screenToDocumentPosition(screenRow, 0);
+ var beforeCursor = this.session.getDisplayLine(
+ row, null, firstColumnPosition.row,
+ firstColumnPosition.column
+ );
+
+ var leadingSpace = beforeCursor.match(/^\s*/);
+ if (leadingSpace[0].length != column && !this.session.$useEmacsStyleLineStart)
+ firstColumnPosition.column += leadingSpace[0].length;
+ this.moveCursorToPosition(firstColumnPosition);
+ };
+ this.moveCursorLineEnd = function() {
+ var lead = this.lead;
+ var lineEnd = this.session.getDocumentLastRowColumnPosition(lead.row, lead.column);
+ if (this.lead.column == lineEnd.column) {
+ var line = this.session.getLine(lineEnd.row);
+ if (lineEnd.column == line.length) {
+ var textEnd = line.search(/\s+$/);
+ if (textEnd > 0)
+ lineEnd.column = textEnd;
+ }
+ }
+
+ this.moveCursorTo(lineEnd.row, lineEnd.column);
+ };
+ this.moveCursorFileEnd = function() {
+ var row = this.doc.getLength() - 1;
+ var column = this.doc.getLine(row).length;
+ this.moveCursorTo(row, column);
+ };
+ this.moveCursorFileStart = function() {
+ this.moveCursorTo(0, 0);
+ };
+ this.moveCursorLongWordRight = function() {
+ var row = this.lead.row;
+ var column = this.lead.column;
+ var line = this.doc.getLine(row);
+ var rightOfCursor = line.substring(column);
+
+ var match;
+ this.session.nonTokenRe.lastIndex = 0;
+ this.session.tokenRe.lastIndex = 0;
+ var fold = this.session.getFoldAt(row, column, 1);
+ if (fold) {
+ this.moveCursorTo(fold.end.row, fold.end.column);
+ return;
+ }
+ if (match = this.session.nonTokenRe.exec(rightOfCursor)) {
+ column += this.session.nonTokenRe.lastIndex;
+ this.session.nonTokenRe.lastIndex = 0;
+ rightOfCursor = line.substring(column);
+ }
+ if (column >= line.length) {
+ this.moveCursorTo(row, line.length);
+ this.moveCursorRight();
+ if (row < this.doc.getLength() - 1)
+ this.moveCursorWordRight();
+ return;
+ }
+ if (match = this.session.tokenRe.exec(rightOfCursor)) {
+ column += this.session.tokenRe.lastIndex;
+ this.session.tokenRe.lastIndex = 0;
+ }
+
+ this.moveCursorTo(row, column);
+ };
+ this.moveCursorLongWordLeft = function() {
+ var row = this.lead.row;
+ var column = this.lead.column;
+ var fold;
+ if (fold = this.session.getFoldAt(row, column, -1)) {
+ this.moveCursorTo(fold.start.row, fold.start.column);
+ return;
+ }
+
+ var str = this.session.getFoldStringAt(row, column, -1);
+ if (str == null) {
+ str = this.doc.getLine(row).substring(0, column);
+ }
+
+ var leftOfCursor = lang.stringReverse(str);
+ var match;
+ this.session.nonTokenRe.lastIndex = 0;
+ this.session.tokenRe.lastIndex = 0;
+ if (match = this.session.nonTokenRe.exec(leftOfCursor)) {
+ column -= this.session.nonTokenRe.lastIndex;
+ leftOfCursor = leftOfCursor.slice(this.session.nonTokenRe.lastIndex);
+ this.session.nonTokenRe.lastIndex = 0;
+ }
+ if (column <= 0) {
+ this.moveCursorTo(row, 0);
+ this.moveCursorLeft();
+ if (row > 0)
+ this.moveCursorWordLeft();
+ return;
+ }
+ if (match = this.session.tokenRe.exec(leftOfCursor)) {
+ column -= this.session.tokenRe.lastIndex;
+ this.session.tokenRe.lastIndex = 0;
+ }
+
+ this.moveCursorTo(row, column);
+ };
+
+ this.$shortWordEndIndex = function(rightOfCursor) {
+ var match, index = 0, ch;
+ var whitespaceRe = /\s/;
+ var tokenRe = this.session.tokenRe;
+
+ tokenRe.lastIndex = 0;
+ if (match = this.session.tokenRe.exec(rightOfCursor)) {
+ index = this.session.tokenRe.lastIndex;
+ } else {
+ while ((ch = rightOfCursor[index]) && whitespaceRe.test(ch))
+ index ++;
+
+ if (index < 1) {
+ tokenRe.lastIndex = 0;
+ while ((ch = rightOfCursor[index]) && !tokenRe.test(ch)) {
+ tokenRe.lastIndex = 0;
+ index ++;
+ if (whitespaceRe.test(ch)) {
+ if (index > 2) {
+ index--;
+ break;
+ } else {
+ while ((ch = rightOfCursor[index]) && whitespaceRe.test(ch))
+ index ++;
+ if (index > 2)
+ break;
+ }
+ }
+ }
+ }
+ }
+ tokenRe.lastIndex = 0;
+
+ return index;
+ };
+
+ this.moveCursorShortWordRight = function() {
+ var row = this.lead.row;
+ var column = this.lead.column;
+ var line = this.doc.getLine(row);
+ var rightOfCursor = line.substring(column);
+
+ var fold = this.session.getFoldAt(row, column, 1);
+ if (fold)
+ return this.moveCursorTo(fold.end.row, fold.end.column);
+
+ if (column == line.length) {
+ var l = this.doc.getLength();
+ do {
+ row++;
+ rightOfCursor = this.doc.getLine(row);
+ } while (row < l && /^\s*$/.test(rightOfCursor));
+
+ if (!/^\s+/.test(rightOfCursor))
+ rightOfCursor = "";
+ column = 0;
+ }
+
+ var index = this.$shortWordEndIndex(rightOfCursor);
+
+ this.moveCursorTo(row, column + index);
+ };
+
+ this.moveCursorShortWordLeft = function() {
+ var row = this.lead.row;
+ var column = this.lead.column;
+
+ var fold;
+ if (fold = this.session.getFoldAt(row, column, -1))
+ return this.moveCursorTo(fold.start.row, fold.start.column);
+
+ var line = this.session.getLine(row).substring(0, column);
+ if (column === 0) {
+ do {
+ row--;
+ line = this.doc.getLine(row);
+ } while (row > 0 && /^\s*$/.test(line));
+
+ column = line.length;
+ if (!/\s+$/.test(line))
+ line = "";
+ }
+
+ var leftOfCursor = lang.stringReverse(line);
+ var index = this.$shortWordEndIndex(leftOfCursor);
+
+ return this.moveCursorTo(row, column - index);
+ };
+
+ this.moveCursorWordRight = function() {
+ if (this.session.$selectLongWords)
+ this.moveCursorLongWordRight();
+ else
+ this.moveCursorShortWordRight();
+ };
+
+ this.moveCursorWordLeft = function() {
+ if (this.session.$selectLongWords)
+ this.moveCursorLongWordLeft();
+ else
+ this.moveCursorShortWordLeft();
+ };
+ this.moveCursorBy = function(rows, chars) {
+ var screenPos = this.session.documentToScreenPosition(
+ this.lead.row,
+ this.lead.column
+ );
+
+ var offsetX;
+
+ if (chars === 0) {
+ if (rows !== 0) {
+ if (this.session.$bidiHandler.isBidiRow(screenPos.row, this.lead.row)) {
+ offsetX = this.session.$bidiHandler.getPosLeft(screenPos.column);
+ screenPos.column = Math.round(offsetX / this.session.$bidiHandler.charWidths[0]);
+ } else {
+ offsetX = screenPos.column * this.session.$bidiHandler.charWidths[0];
+ }
+ }
+
+ if (this.$desiredColumn)
+ screenPos.column = this.$desiredColumn;
+ else
+ this.$desiredColumn = screenPos.column;
+ }
+
+ var docPos = this.session.screenToDocumentPosition(screenPos.row + rows, screenPos.column, offsetX);
+
+ if (rows !== 0 && chars === 0 && docPos.row === this.lead.row && docPos.column === this.lead.column) {
+ if (this.session.lineWidgets && this.session.lineWidgets[docPos.row]) {
+ if (docPos.row > 0 || rows > 0)
+ docPos.row++;
+ }
+ }
+ this.moveCursorTo(docPos.row, docPos.column + chars, chars === 0);
+ };
+ this.moveCursorToPosition = function(position) {
+ this.moveCursorTo(position.row, position.column);
+ };
+ this.moveCursorTo = function(row, column, keepDesiredColumn) {
+ var fold = this.session.getFoldAt(row, column, 1);
+ if (fold) {
+ row = fold.start.row;
+ column = fold.start.column;
+ }
+
+ this.$keepDesiredColumnOnChange = true;
+ this.lead.setPosition(row, column);
+ this.$keepDesiredColumnOnChange = false;
+
+ if (!keepDesiredColumn)
+ this.$desiredColumn = null;
+ };
+ this.moveCursorToScreen = function(row, column, keepDesiredColumn) {
+ var pos = this.session.screenToDocumentPosition(row, column);
+ this.moveCursorTo(pos.row, pos.column, keepDesiredColumn);
+ };
+ this.detach = function() {
+ this.lead.detach();
+ this.anchor.detach();
+ this.session = this.doc = null;
+ };
+
+ this.fromOrientedRange = function(range) {
+ this.setSelectionRange(range, range.cursor == range.start);
+ this.$desiredColumn = range.desiredColumn || this.$desiredColumn;
+ };
+
+ this.toOrientedRange = function(range) {
+ var r = this.getRange();
+ if (range) {
+ range.start.column = r.start.column;
+ range.start.row = r.start.row;
+ range.end.column = r.end.column;
+ range.end.row = r.end.row;
+ } else {
+ range = r;
+ }
+
+ range.cursor = this.isBackwards() ? range.start : range.end;
+ range.desiredColumn = this.$desiredColumn;
+ return range;
+ };
+ this.getRangeOfMovements = function(func) {
+ var start = this.getCursor();
+ try {
+ func(this);
+ var end = this.getCursor();
+ return Range.fromPoints(start,end);
+ } catch(e) {
+ return Range.fromPoints(start,start);
+ } finally {
+ this.moveCursorToPosition(start);
+ }
+ };
+
+ this.toJSON = function() {
+ if (this.rangeCount) {
+ var data = this.ranges.map(function(r) {
+ var r1 = r.clone();
+ r1.isBackwards = r.cursor == r.start;
+ return r1;
+ });
+ } else {
+ var data = this.getRange();
+ data.isBackwards = this.isBackwards();
+ }
+ return data;
+ };
+
+ this.fromJSON = function(data) {
+ if (data.start == undefined) {
+ if (this.rangeList) {
+ this.toSingleRange(data[0]);
+ for (var i = data.length; i--; ) {
+ var r = Range.fromPoints(data[i].start, data[i].end);
+ if (data[i].isBackwards)
+ r.cursor = r.start;
+ this.addRange(r, true);
+ }
+ return;
+ } else
+ data = data[0];
+ }
+ if (this.rangeList)
+ this.toSingleRange(data);
+ this.setSelectionRange(data, data.isBackwards);
+ };
+
+ this.isEqual = function(data) {
+ if ((data.length || this.rangeCount) && data.length != this.rangeCount)
+ return false;
+ if (!data.length || !this.ranges)
+ return this.getRange().isEqual(data);
+
+ for (var i = this.ranges.length; i--; ) {
+ if (!this.ranges[i].isEqual(data[i]))
+ return false;
+ }
+ return true;
+ };
+
+}).call(Selection.prototype);
+
+exports.Selection = Selection;
+});
+
+ace.define("ace/tokenizer",["require","exports","module","ace/config"], function(require, exports, module) {
+"use strict";
+
+var config = require("./config");
+var MAX_TOKEN_COUNT = 2000;
+var Tokenizer = function(rules) {
+ this.states = rules;
+
+ this.regExps = {};
+ this.matchMappings = {};
+ for (var key in this.states) {
+ var state = this.states[key];
+ var ruleRegExps = [];
+ var matchTotal = 0;
+ var mapping = this.matchMappings[key] = {defaultToken: "text"};
+ var flag = "g";
+
+ var splitterRurles = [];
+ for (var i = 0; i < state.length; i++) {
+ var rule = state[i];
+ if (rule.defaultToken)
+ mapping.defaultToken = rule.defaultToken;
+ if (rule.caseInsensitive)
+ flag = "gi";
+ if (rule.regex == null)
+ continue;
+
+ if (rule.regex instanceof RegExp)
+ rule.regex = rule.regex.toString().slice(1, -1);
+ var adjustedregex = rule.regex;
+ var matchcount = new RegExp("(?:(" + adjustedregex + ")|(.))").exec("a").length - 2;
+ if (Array.isArray(rule.token)) {
+ if (rule.token.length == 1 || matchcount == 1) {
+ rule.token = rule.token[0];
+ } else if (matchcount - 1 != rule.token.length) {
+ this.reportError("number of classes and regexp groups doesn't match", {
+ rule: rule,
+ groupCount: matchcount - 1
+ });
+ rule.token = rule.token[0];
+ } else {
+ rule.tokenArray = rule.token;
+ rule.token = null;
+ rule.onMatch = this.$arrayTokens;
+ }
+ } else if (typeof rule.token == "function" && !rule.onMatch) {
+ if (matchcount > 1)
+ rule.onMatch = this.$applyToken;
+ else
+ rule.onMatch = rule.token;
+ }
+
+ if (matchcount > 1) {
+ if (/\\\d/.test(rule.regex)) {
+ adjustedregex = rule.regex.replace(/\\([0-9]+)/g, function(match, digit) {
+ return "\\" + (parseInt(digit, 10) + matchTotal + 1);
+ });
+ } else {
+ matchcount = 1;
+ adjustedregex = this.removeCapturingGroups(rule.regex);
+ }
+ if (!rule.splitRegex && typeof rule.token != "string")
+ splitterRurles.push(rule); // flag will be known only at the very end
+ }
+
+ mapping[matchTotal] = i;
+ matchTotal += matchcount;
+
+ ruleRegExps.push(adjustedregex);
+ if (!rule.onMatch)
+ rule.onMatch = null;
+ }
+
+ if (!ruleRegExps.length) {
+ mapping[0] = 0;
+ ruleRegExps.push("$");
+ }
+
+ splitterRurles.forEach(function(rule) {
+ rule.splitRegex = this.createSplitterRegexp(rule.regex, flag);
+ }, this);
+
+ this.regExps[key] = new RegExp("(" + ruleRegExps.join(")|(") + ")|($)", flag);
+ }
+};
+
+(function() {
+ this.$setMaxTokenCount = function(m) {
+ MAX_TOKEN_COUNT = m | 0;
+ };
+
+ this.$applyToken = function(str) {
+ var values = this.splitRegex.exec(str).slice(1);
+ var types = this.token.apply(this, values);
+ if (typeof types === "string")
+ return [{type: types, value: str}];
+
+ var tokens = [];
+ for (var i = 0, l = types.length; i < l; i++) {
+ if (values[i])
+ tokens[tokens.length] = {
+ type: types[i],
+ value: values[i]
+ };
+ }
+ return tokens;
+ };
+
+ this.$arrayTokens = function(str) {
+ if (!str)
+ return [];
+ var values = this.splitRegex.exec(str);
+ if (!values)
+ return "text";
+ var tokens = [];
+ var types = this.tokenArray;
+ for (var i = 0, l = types.length; i < l; i++) {
+ if (values[i + 1])
+ tokens[tokens.length] = {
+ type: types[i],
+ value: values[i + 1]
+ };
+ }
+ return tokens;
+ };
+
+ this.removeCapturingGroups = function(src) {
+ var r = src.replace(
+ /\[(?:\\.|[^\]])*?\]|\\.|\(\?[:=!]|(\()/g,
+ function(x, y) {return y ? "(?:" : x;}
+ );
+ return r;
+ };
+
+ this.createSplitterRegexp = function(src, flag) {
+ if (src.indexOf("(?=") != -1) {
+ var stack = 0;
+ var inChClass = false;
+ var lastCapture = {};
+ src.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g, function(
+ m, esc, parenOpen, parenClose, square, index
+ ) {
+ if (inChClass) {
+ inChClass = square != "]";
+ } else if (square) {
+ inChClass = true;
+ } else if (parenClose) {
+ if (stack == lastCapture.stack) {
+ lastCapture.end = index+1;
+ lastCapture.stack = -1;
+ }
+ stack--;
+ } else if (parenOpen) {
+ stack++;
+ if (parenOpen.length != 1) {
+ lastCapture.stack = stack
+ lastCapture.start = index;
+ }
+ }
+ return m;
+ });
+
+ if (lastCapture.end != null && /^\)*$/.test(src.substr(lastCapture.end)))
+ src = src.substring(0, lastCapture.start) + src.substr(lastCapture.end);
+ }
+ if (src.charAt(0) != "^") src = "^" + src;
+ if (src.charAt(src.length - 1) != "$") src += "$";
+
+ return new RegExp(src, (flag||"").replace("g", ""));
+ };
+ this.getLineTokens = function(line, startState) {
+ if (startState && typeof startState != "string") {
+ var stack = startState.slice(0);
+ startState = stack[0];
+ if (startState === "#tmp") {
+ stack.shift()
+ startState = stack.shift()
+ }
+ } else
+ var stack = [];
+
+ var currentState = startState || "start";
+ var state = this.states[currentState];
+ if (!state) {
+ currentState = "start";
+ state = this.states[currentState];
+ }
+ var mapping = this.matchMappings[currentState];
+ var re = this.regExps[currentState];
+ re.lastIndex = 0;
+
+ var match, tokens = [];
+ var lastIndex = 0;
+ var matchAttempts = 0;
+
+ var token = {type: null, value: ""};
+
+ while (match = re.exec(line)) {
+ var type = mapping.defaultToken;
+ var rule = null;
+ var value = match[0];
+ var index = re.lastIndex;
+
+ if (index - value.length > lastIndex) {
+ var skipped = line.substring(lastIndex, index - value.length);
+ if (token.type == type) {
+ token.value += skipped;
+ } else {
+ if (token.type)
+ tokens.push(token);
+ token = {type: type, value: skipped};
+ }
+ }
+
+ for (var i = 0; i < match.length-2; i++) {
+ if (match[i + 1] === undefined)
+ continue;
+
+ rule = state[mapping[i]];
+
+ if (rule.onMatch)
+ type = rule.onMatch(value, currentState, stack, line);
+ else
+ type = rule.token;
+
+ if (rule.next) {
+ if (typeof rule.next == "string") {
+ currentState = rule.next;
+ } else {
+ currentState = rule.next(currentState, stack);
+ }
+
+ state = this.states[currentState];
+ if (!state) {
+ this.reportError("state doesn't exist", currentState);
+ currentState = "start";
+ state = this.states[currentState];
+ }
+ mapping = this.matchMappings[currentState];
+ lastIndex = index;
+ re = this.regExps[currentState];
+ re.lastIndex = index;
+ }
+ if (rule.consumeLineEnd)
+ lastIndex = index;
+ break;
+ }
+
+ if (value) {
+ if (typeof type === "string") {
+ if ((!rule || rule.merge !== false) && token.type === type) {
+ token.value += value;
+ } else {
+ if (token.type)
+ tokens.push(token);
+ token = {type: type, value: value};
+ }
+ } else if (type) {
+ if (token.type)
+ tokens.push(token);
+ token = {type: null, value: ""};
+ for (var i = 0; i < type.length; i++)
+ tokens.push(type[i]);
+ }
+ }
+
+ if (lastIndex == line.length)
+ break;
+
+ lastIndex = index;
+
+ if (matchAttempts++ > MAX_TOKEN_COUNT) {
+ if (matchAttempts > 2 * line.length) {
+ this.reportError("infinite loop with in ace tokenizer", {
+ startState: startState,
+ line: line
+ });
+ }
+ while (lastIndex < line.length) {
+ if (token.type)
+ tokens.push(token);
+ token = {
+ value: line.substring(lastIndex, lastIndex += 2000),
+ type: "overflow"
+ };
+ }
+ currentState = "start";
+ stack = [];
+ break;
+ }
+ }
+
+ if (token.type)
+ tokens.push(token);
+
+ if (stack.length > 1) {
+ if (stack[0] !== currentState)
+ stack.unshift("#tmp", currentState);
+ }
+ return {
+ tokens : tokens,
+ state : stack.length ? stack : currentState
+ };
+ };
+
+ this.reportError = config.reportError;
+
+}).call(Tokenizer.prototype);
+
+exports.Tokenizer = Tokenizer;
+});
+
+ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var lang = require("../lib/lang");
+
+var TextHighlightRules = function() {
+
+ this.$rules = {
+ "start" : [{
+ token : "empty_line",
+ regex : '^$'
+ }, {
+ defaultToken : "text"
+ }]
+ };
+};
+
+(function() {
+
+ this.addRules = function(rules, prefix) {
+ if (!prefix) {
+ for (var key in rules)
+ this.$rules[key] = rules[key];
+ return;
+ }
+ for (var key in rules) {
+ var state = rules[key];
+ for (var i = 0; i < state.length; i++) {
+ var rule = state[i];
+ if (rule.next || rule.onMatch) {
+ if (typeof rule.next == "string") {
+ if (rule.next.indexOf(prefix) !== 0)
+ rule.next = prefix + rule.next;
+ }
+ if (rule.nextState && rule.nextState.indexOf(prefix) !== 0)
+ rule.nextState = prefix + rule.nextState;
+ }
+ }
+ this.$rules[prefix + key] = state;
+ }
+ };
+
+ this.getRules = function() {
+ return this.$rules;
+ };
+
+ this.embedRules = function (HighlightRules, prefix, escapeRules, states, append) {
+ var embedRules = typeof HighlightRules == "function"
+ ? new HighlightRules().getRules()
+ : HighlightRules;
+ if (states) {
+ for (var i = 0; i < states.length; i++)
+ states[i] = prefix + states[i];
+ } else {
+ states = [];
+ for (var key in embedRules)
+ states.push(prefix + key);
+ }
+
+ this.addRules(embedRules, prefix);
+
+ if (escapeRules) {
+ var addRules = Array.prototype[append ? "push" : "unshift"];
+ for (var i = 0; i < states.length; i++)
+ addRules.apply(this.$rules[states[i]], lang.deepCopy(escapeRules));
+ }
+
+ if (!this.$embeds)
+ this.$embeds = [];
+ this.$embeds.push(prefix);
+ };
+
+ this.getEmbeds = function() {
+ return this.$embeds;
+ };
+
+ var pushState = function(currentState, stack) {
+ if (currentState != "start" || stack.length)
+ stack.unshift(this.nextState, currentState);
+ return this.nextState;
+ };
+ var popState = function(currentState, stack) {
+ stack.shift();
+ return stack.shift() || "start";
+ };
+
+ this.normalizeRules = function() {
+ var id = 0;
+ var rules = this.$rules;
+ function processState(key) {
+ var state = rules[key];
+ state.processed = true;
+ for (var i = 0; i < state.length; i++) {
+ var rule = state[i];
+ var toInsert = null;
+ if (Array.isArray(rule)) {
+ toInsert = rule;
+ rule = {};
+ }
+ if (!rule.regex && rule.start) {
+ rule.regex = rule.start;
+ if (!rule.next)
+ rule.next = [];
+ rule.next.push({
+ defaultToken: rule.token
+ }, {
+ token: rule.token + ".end",
+ regex: rule.end || rule.start,
+ next: "pop"
+ });
+ rule.token = rule.token + ".start";
+ rule.push = true;
+ }
+ var next = rule.next || rule.push;
+ if (next && Array.isArray(next)) {
+ var stateName = rule.stateName;
+ if (!stateName) {
+ stateName = rule.token;
+ if (typeof stateName != "string")
+ stateName = stateName[0] || "";
+ if (rules[stateName])
+ stateName += id++;
+ }
+ rules[stateName] = next;
+ rule.next = stateName;
+ processState(stateName);
+ } else if (next == "pop") {
+ rule.next = popState;
+ }
+
+ if (rule.push) {
+ rule.nextState = rule.next || rule.push;
+ rule.next = pushState;
+ delete rule.push;
+ }
+
+ if (rule.rules) {
+ for (var r in rule.rules) {
+ if (rules[r]) {
+ if (rules[r].push)
+ rules[r].push.apply(rules[r], rule.rules[r]);
+ } else {
+ rules[r] = rule.rules[r];
+ }
+ }
+ }
+ var includeName = typeof rule == "string" ? rule : rule.include;
+ if (includeName) {
+ if (Array.isArray(includeName))
+ toInsert = includeName.map(function(x) { return rules[x]; });
+ else
+ toInsert = rules[includeName];
+ }
+
+ if (toInsert) {
+ var args = [i, 1].concat(toInsert);
+ if (rule.noEscape)
+ args = args.filter(function(x) {return !x.next;});
+ state.splice.apply(state, args);
+ i--;
+ }
+
+ if (rule.keywordMap) {
+ rule.token = this.createKeywordMapper(
+ rule.keywordMap, rule.defaultToken || "text", rule.caseInsensitive
+ );
+ delete rule.defaultToken;
+ }
+ }
+ }
+ Object.keys(rules).forEach(processState, this);
+ };
+
+ this.createKeywordMapper = function(map, defaultToken, ignoreCase, splitChar) {
+ var keywords = Object.create(null);
+ Object.keys(map).forEach(function(className) {
+ var a = map[className];
+ if (ignoreCase)
+ a = a.toLowerCase();
+ var list = a.split(splitChar || "|");
+ for (var i = list.length; i--; )
+ keywords[list[i]] = className;
+ });
+ if (Object.getPrototypeOf(keywords)) {
+ keywords.__proto__ = null;
+ }
+ this.$keywordList = Object.keys(keywords);
+ map = null;
+ return ignoreCase
+ ? function(value) {return keywords[value.toLowerCase()] || defaultToken }
+ : function(value) {return keywords[value] || defaultToken };
+ };
+
+ this.getKeywords = function() {
+ return this.$keywords;
+ };
+
+}).call(TextHighlightRules.prototype);
+
+exports.TextHighlightRules = TextHighlightRules;
+});
+
+ace.define("ace/mode/behaviour",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var Behaviour = function() {
+ this.$behaviours = {};
+};
+
+(function () {
+
+ this.add = function (name, action, callback) {
+ switch (undefined) {
+ case this.$behaviours:
+ this.$behaviours = {};
+ case this.$behaviours[name]:
+ this.$behaviours[name] = {};
+ }
+ this.$behaviours[name][action] = callback;
+ }
+
+ this.addBehaviours = function (behaviours) {
+ for (var key in behaviours) {
+ for (var action in behaviours[key]) {
+ this.add(key, action, behaviours[key][action]);
+ }
+ }
+ }
+
+ this.remove = function (name) {
+ if (this.$behaviours && this.$behaviours[name]) {
+ delete this.$behaviours[name];
+ }
+ }
+
+ this.inherit = function (mode, filter) {
+ if (typeof mode === "function") {
+ var behaviours = new mode().getBehaviours(filter);
+ } else {
+ var behaviours = mode.getBehaviours(filter);
+ }
+ this.addBehaviours(behaviours);
+ }
+
+ this.getBehaviours = function (filter) {
+ if (!filter) {
+ return this.$behaviours;
+ } else {
+ var ret = {}
+ for (var i = 0; i < filter.length; i++) {
+ if (this.$behaviours[filter[i]]) {
+ ret[filter[i]] = this.$behaviours[filter[i]];
+ }
+ }
+ return ret;
+ }
+ }
+
+}).call(Behaviour.prototype);
+
+exports.Behaviour = Behaviour;
+});
+
+ace.define("ace/token_iterator",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("./range").Range;
+var TokenIterator = function(session, initialRow, initialColumn) {
+ this.$session = session;
+ this.$row = initialRow;
+ this.$rowTokens = session.getTokens(initialRow);
+
+ var token = session.getTokenAt(initialRow, initialColumn);
+ this.$tokenIndex = token ? token.index : -1;
+};
+
+(function() {
+ this.stepBackward = function() {
+ this.$tokenIndex -= 1;
+
+ while (this.$tokenIndex < 0) {
+ this.$row -= 1;
+ if (this.$row < 0) {
+ this.$row = 0;
+ return null;
+ }
+
+ this.$rowTokens = this.$session.getTokens(this.$row);
+ this.$tokenIndex = this.$rowTokens.length - 1;
+ }
+
+ return this.$rowTokens[this.$tokenIndex];
+ };
+ this.stepForward = function() {
+ this.$tokenIndex += 1;
+ var rowCount;
+ while (this.$tokenIndex >= this.$rowTokens.length) {
+ this.$row += 1;
+ if (!rowCount)
+ rowCount = this.$session.getLength();
+ if (this.$row >= rowCount) {
+ this.$row = rowCount - 1;
+ return null;
+ }
+
+ this.$rowTokens = this.$session.getTokens(this.$row);
+ this.$tokenIndex = 0;
+ }
+
+ return this.$rowTokens[this.$tokenIndex];
+ };
+ this.getCurrentToken = function () {
+ return this.$rowTokens[this.$tokenIndex];
+ };
+ this.getCurrentTokenRow = function () {
+ return this.$row;
+ };
+ this.getCurrentTokenColumn = function() {
+ var rowTokens = this.$rowTokens;
+ var tokenIndex = this.$tokenIndex;
+ var column = rowTokens[tokenIndex].start;
+ if (column !== undefined)
+ return column;
+
+ column = 0;
+ while (tokenIndex > 0) {
+ tokenIndex -= 1;
+ column += rowTokens[tokenIndex].value.length;
+ }
+
+ return column;
+ };
+ this.getCurrentTokenPosition = function() {
+ return {row: this.$row, column: this.getCurrentTokenColumn()};
+ };
+ this.getCurrentTokenRange = function() {
+ var token = this.$rowTokens[this.$tokenIndex];
+ var column = this.getCurrentTokenColumn();
+ return new Range(this.$row, column, this.$row, column + token.value.length);
+ };
+
+}).call(TokenIterator.prototype);
+
+exports.TokenIterator = TokenIterator;
+});
+
+ace.define("ace/mode/behaviour/cstyle",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+var SAFE_INSERT_IN_TOKENS =
+ ["text", "paren.rparen", "punctuation.operator"];
+var SAFE_INSERT_BEFORE_TOKENS =
+ ["text", "paren.rparen", "punctuation.operator", "comment"];
+
+var context;
+var contextCache = {};
+var defaultQuotes = {'"' : '"', "'" : "'"};
+
+var initContext = function(editor) {
+ var id = -1;
+ if (editor.multiSelect) {
+ id = editor.selection.index;
+ if (contextCache.rangeCount != editor.multiSelect.rangeCount)
+ contextCache = {rangeCount: editor.multiSelect.rangeCount};
+ }
+ if (contextCache[id])
+ return context = contextCache[id];
+ context = contextCache[id] = {
+ autoInsertedBrackets: 0,
+ autoInsertedRow: -1,
+ autoInsertedLineEnd: "",
+ maybeInsertedBrackets: 0,
+ maybeInsertedRow: -1,
+ maybeInsertedLineStart: "",
+ maybeInsertedLineEnd: ""
+ };
+};
+
+var getWrapped = function(selection, selected, opening, closing) {
+ var rowDiff = selection.end.row - selection.start.row;
+ return {
+ text: opening + selected + closing,
+ selection: [
+ 0,
+ selection.start.column + 1,
+ rowDiff,
+ selection.end.column + (rowDiff ? 0 : 1)
+ ]
+ };
+};
+
+var CstyleBehaviour = function(options) {
+ this.add("braces", "insertion", function(state, action, editor, session, text) {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ if (text == '{') {
+ initContext(editor);
+ var selection = editor.getSelectionRange();
+ var selected = session.doc.getTextRange(selection);
+ if (selected !== "" && selected !== "{" && editor.getWrapBehavioursEnabled()) {
+ return getWrapped(selection, selected, '{', '}');
+ } else if (CstyleBehaviour.isSaneInsertion(editor, session)) {
+ if (/[\]\}\)]/.test(line[cursor.column]) || editor.inMultiSelectMode || options && options.braces) {
+ CstyleBehaviour.recordAutoInsert(editor, session, "}");
+ return {
+ text: '{}',
+ selection: [1, 1]
+ };
+ } else {
+ CstyleBehaviour.recordMaybeInsert(editor, session, "{");
+ return {
+ text: '{',
+ selection: [1, 1]
+ };
+ }
+ }
+ } else if (text == '}') {
+ initContext(editor);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar == '}') {
+ var matching = session.$findOpeningBracket('}', {column: cursor.column + 1, row: cursor.row});
+ if (matching !== null && CstyleBehaviour.isAutoInsertedClosing(cursor, line, text)) {
+ CstyleBehaviour.popAutoInsertedClosing();
+ return {
+ text: '',
+ selection: [1, 1]
+ };
+ }
+ }
+ } else if (text == "\n" || text == "\r\n") {
+ initContext(editor);
+ var closing = "";
+ if (CstyleBehaviour.isMaybeInsertedClosing(cursor, line)) {
+ closing = lang.stringRepeat("}", context.maybeInsertedBrackets);
+ CstyleBehaviour.clearMaybeInsertedClosing();
+ }
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === '}') {
+ var openBracePos = session.findMatchingBracket({row: cursor.row, column: cursor.column+1}, '}');
+ if (!openBracePos)
+ return null;
+ var next_indent = this.$getIndent(session.getLine(openBracePos.row));
+ } else if (closing) {
+ var next_indent = this.$getIndent(line);
+ } else {
+ CstyleBehaviour.clearMaybeInsertedClosing();
+ return;
+ }
+ var indent = next_indent + session.getTabString();
+
+ return {
+ text: '\n' + indent + '\n' + next_indent + closing,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ CstyleBehaviour.clearMaybeInsertedClosing();
+ }
+ });
+
+ this.add("braces", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected == '{') {
+ initContext(editor);
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar == '}') {
+ range.end.column++;
+ return range;
+ } else {
+ context.maybeInsertedBrackets--;
+ }
+ }
+ });
+
+ this.add("parens", "insertion", function(state, action, editor, session, text) {
+ if (text == '(') {
+ initContext(editor);
+ var selection = editor.getSelectionRange();
+ var selected = session.doc.getTextRange(selection);
+ if (selected !== "" && editor.getWrapBehavioursEnabled()) {
+ return getWrapped(selection, selected, '(', ')');
+ } else if (CstyleBehaviour.isSaneInsertion(editor, session)) {
+ CstyleBehaviour.recordAutoInsert(editor, session, ")");
+ return {
+ text: '()',
+ selection: [1, 1]
+ };
+ }
+ } else if (text == ')') {
+ initContext(editor);
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar == ')') {
+ var matching = session.$findOpeningBracket(')', {column: cursor.column + 1, row: cursor.row});
+ if (matching !== null && CstyleBehaviour.isAutoInsertedClosing(cursor, line, text)) {
+ CstyleBehaviour.popAutoInsertedClosing();
+ return {
+ text: '',
+ selection: [1, 1]
+ };
+ }
+ }
+ }
+ });
+
+ this.add("parens", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected == '(') {
+ initContext(editor);
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == ')') {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("brackets", "insertion", function(state, action, editor, session, text) {
+ if (text == '[') {
+ initContext(editor);
+ var selection = editor.getSelectionRange();
+ var selected = session.doc.getTextRange(selection);
+ if (selected !== "" && editor.getWrapBehavioursEnabled()) {
+ return getWrapped(selection, selected, '[', ']');
+ } else if (CstyleBehaviour.isSaneInsertion(editor, session)) {
+ CstyleBehaviour.recordAutoInsert(editor, session, "]");
+ return {
+ text: '[]',
+ selection: [1, 1]
+ };
+ }
+ } else if (text == ']') {
+ initContext(editor);
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar == ']') {
+ var matching = session.$findOpeningBracket(']', {column: cursor.column + 1, row: cursor.row});
+ if (matching !== null && CstyleBehaviour.isAutoInsertedClosing(cursor, line, text)) {
+ CstyleBehaviour.popAutoInsertedClosing();
+ return {
+ text: '',
+ selection: [1, 1]
+ };
+ }
+ }
+ }
+ });
+
+ this.add("brackets", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected == '[') {
+ initContext(editor);
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == ']') {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("string_dquotes", "insertion", function(state, action, editor, session, text) {
+ var quotes = session.$mode.$quotes || defaultQuotes;
+ if (text.length == 1 && quotes[text]) {
+ if (this.lineCommentStart && this.lineCommentStart.indexOf(text) != -1)
+ return;
+ initContext(editor);
+ var quote = text;
+ var selection = editor.getSelectionRange();
+ var selected = session.doc.getTextRange(selection);
+ if (selected !== "" && (selected.length != 1 || !quotes[selected]) && editor.getWrapBehavioursEnabled()) {
+ return getWrapped(selection, selected, quote, quote);
+ } else if (!selected) {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var leftChar = line.substring(cursor.column-1, cursor.column);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+
+ var token = session.getTokenAt(cursor.row, cursor.column);
+ var rightToken = session.getTokenAt(cursor.row, cursor.column + 1);
+ if (leftChar == "\\" && token && /escape/.test(token.type))
+ return null;
+
+ var stringBefore = token && /string|escape/.test(token.type);
+ var stringAfter = !rightToken || /string|escape/.test(rightToken.type);
+
+ var pair;
+ if (rightChar == quote) {
+ pair = stringBefore !== stringAfter;
+ if (pair && /string\.end/.test(rightToken.type))
+ pair = false;
+ } else {
+ if (stringBefore && !stringAfter)
+ return null; // wrap string with different quote
+ if (stringBefore && stringAfter)
+ return null; // do not pair quotes inside strings
+ var wordRe = session.$mode.tokenRe;
+ wordRe.lastIndex = 0;
+ var isWordBefore = wordRe.test(leftChar);
+ wordRe.lastIndex = 0;
+ var isWordAfter = wordRe.test(leftChar);
+ if (isWordBefore || isWordAfter)
+ return null; // before or after alphanumeric
+ if (rightChar && !/[\s;,.})\]\\]/.test(rightChar))
+ return null; // there is rightChar and it isn't closing
+ pair = true;
+ }
+ return {
+ text: pair ? quote + quote : "",
+ selection: [1,1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ initContext(editor);
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+};
+
+
+CstyleBehaviour.isSaneInsertion = function(editor, session) {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ if (!this.$matchTokenType(iterator.getCurrentToken() || "text", SAFE_INSERT_IN_TOKENS)) {
+ var iterator2 = new TokenIterator(session, cursor.row, cursor.column + 1);
+ if (!this.$matchTokenType(iterator2.getCurrentToken() || "text", SAFE_INSERT_IN_TOKENS))
+ return false;
+ }
+ iterator.stepForward();
+ return iterator.getCurrentTokenRow() !== cursor.row ||
+ this.$matchTokenType(iterator.getCurrentToken() || "text", SAFE_INSERT_BEFORE_TOKENS);
+};
+
+CstyleBehaviour.$matchTokenType = function(token, types) {
+ return types.indexOf(token.type || token) > -1;
+};
+
+CstyleBehaviour.recordAutoInsert = function(editor, session, bracket) {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ if (!this.isAutoInsertedClosing(cursor, line, context.autoInsertedLineEnd[0]))
+ context.autoInsertedBrackets = 0;
+ context.autoInsertedRow = cursor.row;
+ context.autoInsertedLineEnd = bracket + line.substr(cursor.column);
+ context.autoInsertedBrackets++;
+};
+
+CstyleBehaviour.recordMaybeInsert = function(editor, session, bracket) {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ if (!this.isMaybeInsertedClosing(cursor, line))
+ context.maybeInsertedBrackets = 0;
+ context.maybeInsertedRow = cursor.row;
+ context.maybeInsertedLineStart = line.substr(0, cursor.column) + bracket;
+ context.maybeInsertedLineEnd = line.substr(cursor.column);
+ context.maybeInsertedBrackets++;
+};
+
+CstyleBehaviour.isAutoInsertedClosing = function(cursor, line, bracket) {
+ return context.autoInsertedBrackets > 0 &&
+ cursor.row === context.autoInsertedRow &&
+ bracket === context.autoInsertedLineEnd[0] &&
+ line.substr(cursor.column) === context.autoInsertedLineEnd;
+};
+
+CstyleBehaviour.isMaybeInsertedClosing = function(cursor, line) {
+ return context.maybeInsertedBrackets > 0 &&
+ cursor.row === context.maybeInsertedRow &&
+ line.substr(cursor.column) === context.maybeInsertedLineEnd &&
+ line.substr(0, cursor.column) == context.maybeInsertedLineStart;
+};
+
+CstyleBehaviour.popAutoInsertedClosing = function() {
+ context.autoInsertedLineEnd = context.autoInsertedLineEnd.substr(1);
+ context.autoInsertedBrackets--;
+};
+
+CstyleBehaviour.clearMaybeInsertedClosing = function() {
+ if (context) {
+ context.maybeInsertedBrackets = 0;
+ context.maybeInsertedRow = -1;
+ }
+};
+
+
+
+oop.inherits(CstyleBehaviour, Behaviour);
+
+exports.CstyleBehaviour = CstyleBehaviour;
+});
+
+ace.define("ace/unicode",["require","exports","module"], function(require, exports, module) {
+"use strict";
+exports.packages = {};
+
+addUnicodePackage({
+ L: "0041-005A0061-007A00AA00B500BA00C0-00D600D8-00F600F8-02C102C6-02D102E0-02E402EC02EE0370-037403760377037A-037D03860388-038A038C038E-03A103A3-03F503F7-0481048A-05250531-055605590561-058705D0-05EA05F0-05F20621-064A066E066F0671-06D306D506E506E606EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA07F407F507FA0800-0815081A082408280904-0939093D09500958-0961097109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E460E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EC60EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10A0-10C510D0-10FA10FC1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317D717DC1820-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541AA71B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C7D1CE9-1CEC1CEE-1CF11D00-1DBF1E00-1F151F18-1F1D1F20-1F451F48-1F4D1F50-1F571F591F5B1F5D1F5F-1F7D1F80-1FB41FB6-1FBC1FBE1FC2-1FC41FC6-1FCC1FD0-1FD31FD6-1FDB1FE0-1FEC1FF2-1FF41FF6-1FFC2071207F2090-209421022107210A-211321152119-211D212421262128212A-212D212F-2139213C-213F2145-2149214E218321842C00-2C2E2C30-2C5E2C60-2CE42CEB-2CEE2D00-2D252D30-2D652D6F2D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE2E2F300530063031-3035303B303C3041-3096309D-309F30A1-30FA30FC-30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A48CA4D0-A4FDA500-A60CA610-A61FA62AA62BA640-A65FA662-A66EA67F-A697A6A0-A6E5A717-A71FA722-A788A78BA78CA7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2A9CFAA00-AA28AA40-AA42AA44-AA4BAA60-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADB-AADDABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB00-FB06FB13-FB17FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF21-FF3AFF41-FF5AFF66-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",
+ Ll: "0061-007A00AA00B500BA00DF-00F600F8-00FF01010103010501070109010B010D010F01110113011501170119011B011D011F01210123012501270129012B012D012F01310133013501370138013A013C013E014001420144014601480149014B014D014F01510153015501570159015B015D015F01610163016501670169016B016D016F0171017301750177017A017C017E-0180018301850188018C018D019201950199-019B019E01A101A301A501A801AA01AB01AD01B001B401B601B901BA01BD-01BF01C601C901CC01CE01D001D201D401D601D801DA01DC01DD01DF01E101E301E501E701E901EB01ED01EF01F001F301F501F901FB01FD01FF02010203020502070209020B020D020F02110213021502170219021B021D021F02210223022502270229022B022D022F02310233-0239023C023F0240024202470249024B024D024F-02930295-02AF037103730377037B-037D039003AC-03CE03D003D103D5-03D703D903DB03DD03DF03E103E303E503E703E903EB03ED03EF-03F303F503F803FB03FC0430-045F04610463046504670469046B046D046F04710473047504770479047B047D047F0481048B048D048F04910493049504970499049B049D049F04A104A304A504A704A904AB04AD04AF04B104B304B504B704B904BB04BD04BF04C204C404C604C804CA04CC04CE04CF04D104D304D504D704D904DB04DD04DF04E104E304E504E704E904EB04ED04EF04F104F304F504F704F904FB04FD04FF05010503050505070509050B050D050F05110513051505170519051B051D051F0521052305250561-05871D00-1D2B1D62-1D771D79-1D9A1E011E031E051E071E091E0B1E0D1E0F1E111E131E151E171E191E1B1E1D1E1F1E211E231E251E271E291E2B1E2D1E2F1E311E331E351E371E391E3B1E3D1E3F1E411E431E451E471E491E4B1E4D1E4F1E511E531E551E571E591E5B1E5D1E5F1E611E631E651E671E691E6B1E6D1E6F1E711E731E751E771E791E7B1E7D1E7F1E811E831E851E871E891E8B1E8D1E8F1E911E931E95-1E9D1E9F1EA11EA31EA51EA71EA91EAB1EAD1EAF1EB11EB31EB51EB71EB91EBB1EBD1EBF1EC11EC31EC51EC71EC91ECB1ECD1ECF1ED11ED31ED51ED71ED91EDB1EDD1EDF1EE11EE31EE51EE71EE91EEB1EED1EEF1EF11EF31EF51EF71EF91EFB1EFD1EFF-1F071F10-1F151F20-1F271F30-1F371F40-1F451F50-1F571F60-1F671F70-1F7D1F80-1F871F90-1F971FA0-1FA71FB0-1FB41FB61FB71FBE1FC2-1FC41FC61FC71FD0-1FD31FD61FD71FE0-1FE71FF2-1FF41FF61FF7210A210E210F2113212F21342139213C213D2146-2149214E21842C30-2C5E2C612C652C662C682C6A2C6C2C712C732C742C76-2C7C2C812C832C852C872C892C8B2C8D2C8F2C912C932C952C972C992C9B2C9D2C9F2CA12CA32CA52CA72CA92CAB2CAD2CAF2CB12CB32CB52CB72CB92CBB2CBD2CBF2CC12CC32CC52CC72CC92CCB2CCD2CCF2CD12CD32CD52CD72CD92CDB2CDD2CDF2CE12CE32CE42CEC2CEE2D00-2D25A641A643A645A647A649A64BA64DA64FA651A653A655A657A659A65BA65DA65FA663A665A667A669A66BA66DA681A683A685A687A689A68BA68DA68FA691A693A695A697A723A725A727A729A72BA72DA72F-A731A733A735A737A739A73BA73DA73FA741A743A745A747A749A74BA74DA74FA751A753A755A757A759A75BA75DA75FA761A763A765A767A769A76BA76DA76FA771-A778A77AA77CA77FA781A783A785A787A78CFB00-FB06FB13-FB17FF41-FF5A",
+ Lu: "0041-005A00C0-00D600D8-00DE01000102010401060108010A010C010E01100112011401160118011A011C011E01200122012401260128012A012C012E01300132013401360139013B013D013F0141014301450147014A014C014E01500152015401560158015A015C015E01600162016401660168016A016C016E017001720174017601780179017B017D018101820184018601870189-018B018E-0191019301940196-0198019C019D019F01A001A201A401A601A701A901AC01AE01AF01B1-01B301B501B701B801BC01C401C701CA01CD01CF01D101D301D501D701D901DB01DE01E001E201E401E601E801EA01EC01EE01F101F401F6-01F801FA01FC01FE02000202020402060208020A020C020E02100212021402160218021A021C021E02200222022402260228022A022C022E02300232023A023B023D023E02410243-02460248024A024C024E03700372037603860388-038A038C038E038F0391-03A103A3-03AB03CF03D2-03D403D803DA03DC03DE03E003E203E403E603E803EA03EC03EE03F403F703F903FA03FD-042F04600462046404660468046A046C046E04700472047404760478047A047C047E0480048A048C048E04900492049404960498049A049C049E04A004A204A404A604A804AA04AC04AE04B004B204B404B604B804BA04BC04BE04C004C104C304C504C704C904CB04CD04D004D204D404D604D804DA04DC04DE04E004E204E404E604E804EA04EC04EE04F004F204F404F604F804FA04FC04FE05000502050405060508050A050C050E05100512051405160518051A051C051E0520052205240531-055610A0-10C51E001E021E041E061E081E0A1E0C1E0E1E101E121E141E161E181E1A1E1C1E1E1E201E221E241E261E281E2A1E2C1E2E1E301E321E341E361E381E3A1E3C1E3E1E401E421E441E461E481E4A1E4C1E4E1E501E521E541E561E581E5A1E5C1E5E1E601E621E641E661E681E6A1E6C1E6E1E701E721E741E761E781E7A1E7C1E7E1E801E821E841E861E881E8A1E8C1E8E1E901E921E941E9E1EA01EA21EA41EA61EA81EAA1EAC1EAE1EB01EB21EB41EB61EB81EBA1EBC1EBE1EC01EC21EC41EC61EC81ECA1ECC1ECE1ED01ED21ED41ED61ED81EDA1EDC1EDE1EE01EE21EE41EE61EE81EEA1EEC1EEE1EF01EF21EF41EF61EF81EFA1EFC1EFE1F08-1F0F1F18-1F1D1F28-1F2F1F38-1F3F1F48-1F4D1F591F5B1F5D1F5F1F68-1F6F1FB8-1FBB1FC8-1FCB1FD8-1FDB1FE8-1FEC1FF8-1FFB21022107210B-210D2110-211221152119-211D212421262128212A-212D2130-2133213E213F214521832C00-2C2E2C602C62-2C642C672C692C6B2C6D-2C702C722C752C7E-2C802C822C842C862C882C8A2C8C2C8E2C902C922C942C962C982C9A2C9C2C9E2CA02CA22CA42CA62CA82CAA2CAC2CAE2CB02CB22CB42CB62CB82CBA2CBC2CBE2CC02CC22CC42CC62CC82CCA2CCC2CCE2CD02CD22CD42CD62CD82CDA2CDC2CDE2CE02CE22CEB2CEDA640A642A644A646A648A64AA64CA64EA650A652A654A656A658A65AA65CA65EA662A664A666A668A66AA66CA680A682A684A686A688A68AA68CA68EA690A692A694A696A722A724A726A728A72AA72CA72EA732A734A736A738A73AA73CA73EA740A742A744A746A748A74AA74CA74EA750A752A754A756A758A75AA75CA75EA760A762A764A766A768A76AA76CA76EA779A77BA77DA77EA780A782A784A786A78BFF21-FF3A",
+ Lt: "01C501C801CB01F21F88-1F8F1F98-1F9F1FA8-1FAF1FBC1FCC1FFC",
+ Lm: "02B0-02C102C6-02D102E0-02E402EC02EE0374037A0559064006E506E607F407F507FA081A0824082809710E460EC610FC17D718431AA71C78-1C7D1D2C-1D611D781D9B-1DBF2071207F2090-20942C7D2D6F2E2F30053031-3035303B309D309E30FC-30FEA015A4F8-A4FDA60CA67FA717-A71FA770A788A9CFAA70AADDFF70FF9EFF9F",
+ Lo: "01BB01C0-01C3029405D0-05EA05F0-05F20621-063F0641-064A066E066F0671-06D306D506EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA0800-08150904-0939093D09500958-096109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E450E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10D0-10FA1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317DC1820-18421844-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C771CE9-1CEC1CEE-1CF12135-21382D30-2D652D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE3006303C3041-3096309F30A1-30FA30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A014A016-A48CA4D0-A4F7A500-A60BA610-A61FA62AA62BA66EA6A0-A6E5A7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2AA00-AA28AA40-AA42AA44-AA4BAA60-AA6FAA71-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADBAADCABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF66-FF6FFF71-FF9DFFA0-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",
+ M: "0300-036F0483-04890591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DE-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0903093C093E-094E0951-0955096209630981-098309BC09BE-09C409C709C809CB-09CD09D709E209E30A01-0A030A3C0A3E-0A420A470A480A4B-0A4D0A510A700A710A750A81-0A830ABC0ABE-0AC50AC7-0AC90ACB-0ACD0AE20AE30B01-0B030B3C0B3E-0B440B470B480B4B-0B4D0B560B570B620B630B820BBE-0BC20BC6-0BC80BCA-0BCD0BD70C01-0C030C3E-0C440C46-0C480C4A-0C4D0C550C560C620C630C820C830CBC0CBE-0CC40CC6-0CC80CCA-0CCD0CD50CD60CE20CE30D020D030D3E-0D440D46-0D480D4A-0D4D0D570D620D630D820D830DCA0DCF-0DD40DD60DD8-0DDF0DF20DF30E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F3E0F3F0F71-0F840F860F870F90-0F970F99-0FBC0FC6102B-103E1056-1059105E-10601062-10641067-106D1071-10741082-108D108F109A-109D135F1712-17141732-1734175217531772177317B6-17D317DD180B-180D18A91920-192B1930-193B19B0-19C019C819C91A17-1A1B1A55-1A5E1A60-1A7C1A7F1B00-1B041B34-1B441B6B-1B731B80-1B821BA1-1BAA1C24-1C371CD0-1CD21CD4-1CE81CED1CF21DC0-1DE61DFD-1DFF20D0-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66F-A672A67CA67DA6F0A6F1A802A806A80BA823-A827A880A881A8B4-A8C4A8E0-A8F1A926-A92DA947-A953A980-A983A9B3-A9C0AA29-AA36AA43AA4CAA4DAA7BAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE3-ABEAABECABEDFB1EFE00-FE0FFE20-FE26",
+ Mn: "0300-036F0483-04870591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DF-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0902093C0941-0948094D0951-095509620963098109BC09C1-09C409CD09E209E30A010A020A3C0A410A420A470A480A4B-0A4D0A510A700A710A750A810A820ABC0AC1-0AC50AC70AC80ACD0AE20AE30B010B3C0B3F0B41-0B440B4D0B560B620B630B820BC00BCD0C3E-0C400C46-0C480C4A-0C4D0C550C560C620C630CBC0CBF0CC60CCC0CCD0CE20CE30D41-0D440D4D0D620D630DCA0DD2-0DD40DD60E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F71-0F7E0F80-0F840F860F870F90-0F970F99-0FBC0FC6102D-10301032-10371039103A103D103E10581059105E-10601071-1074108210851086108D109D135F1712-17141732-1734175217531772177317B7-17BD17C617C9-17D317DD180B-180D18A91920-19221927192819321939-193B1A171A181A561A58-1A5E1A601A621A65-1A6C1A73-1A7C1A7F1B00-1B031B341B36-1B3A1B3C1B421B6B-1B731B801B811BA2-1BA51BA81BA91C2C-1C331C361C371CD0-1CD21CD4-1CE01CE2-1CE81CED1DC0-1DE61DFD-1DFF20D0-20DC20E120E5-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66FA67CA67DA6F0A6F1A802A806A80BA825A826A8C4A8E0-A8F1A926-A92DA947-A951A980-A982A9B3A9B6-A9B9A9BCAA29-AA2EAA31AA32AA35AA36AA43AA4CAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE5ABE8ABEDFB1EFE00-FE0FFE20-FE26",
+ Mc: "0903093E-09400949-094C094E0982098309BE-09C009C709C809CB09CC09D70A030A3E-0A400A830ABE-0AC00AC90ACB0ACC0B020B030B3E0B400B470B480B4B0B4C0B570BBE0BBF0BC10BC20BC6-0BC80BCA-0BCC0BD70C01-0C030C41-0C440C820C830CBE0CC0-0CC40CC70CC80CCA0CCB0CD50CD60D020D030D3E-0D400D46-0D480D4A-0D4C0D570D820D830DCF-0DD10DD8-0DDF0DF20DF30F3E0F3F0F7F102B102C10311038103B103C105610571062-10641067-106D108310841087-108C108F109A-109C17B617BE-17C517C717C81923-19261929-192B193019311933-193819B0-19C019C819C91A19-1A1B1A551A571A611A631A641A6D-1A721B041B351B3B1B3D-1B411B431B441B821BA11BA61BA71BAA1C24-1C2B1C341C351CE11CF2A823A824A827A880A881A8B4-A8C3A952A953A983A9B4A9B5A9BAA9BBA9BD-A9C0AA2FAA30AA33AA34AA4DAA7BABE3ABE4ABE6ABE7ABE9ABEAABEC",
+ Me: "0488048906DE20DD-20E020E2-20E4A670-A672",
+ N: "0030-003900B200B300B900BC-00BE0660-066906F0-06F907C0-07C90966-096F09E6-09EF09F4-09F90A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BF20C66-0C6F0C78-0C7E0CE6-0CEF0D66-0D750E50-0E590ED0-0ED90F20-0F331040-10491090-10991369-137C16EE-16F017E0-17E917F0-17F91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C5920702074-20792080-20892150-21822185-21892460-249B24EA-24FF2776-27932CFD30073021-30293038-303A3192-31953220-32293251-325F3280-328932B1-32BFA620-A629A6E6-A6EFA830-A835A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",
+ Nd: "0030-00390660-066906F0-06F907C0-07C90966-096F09E6-09EF0A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BEF0C66-0C6F0CE6-0CEF0D66-0D6F0E50-0E590ED0-0ED90F20-0F291040-10491090-109917E0-17E91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C59A620-A629A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",
+ Nl: "16EE-16F02160-21822185-218830073021-30293038-303AA6E6-A6EF",
+ No: "00B200B300B900BC-00BE09F4-09F90BF0-0BF20C78-0C7E0D70-0D750F2A-0F331369-137C17F0-17F920702074-20792080-20892150-215F21892460-249B24EA-24FF2776-27932CFD3192-31953220-32293251-325F3280-328932B1-32BFA830-A835",
+ P: "0021-00230025-002A002C-002F003A003B003F0040005B-005D005F007B007D00A100AB00B700BB00BF037E0387055A-055F0589058A05BE05C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F3A-0F3D0F850FD0-0FD4104A-104F10FB1361-13681400166D166E169B169C16EB-16ED1735173617D4-17D617D8-17DA1800-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD32010-20272030-20432045-20512053-205E207D207E208D208E2329232A2768-277527C527C627E6-27EF2983-299829D8-29DB29FC29FD2CF9-2CFC2CFE2CFF2E00-2E2E2E302E313001-30033008-30113014-301F3030303D30A030FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFD3EFD3FFE10-FE19FE30-FE52FE54-FE61FE63FE68FE6AFE6BFF01-FF03FF05-FF0AFF0C-FF0FFF1AFF1BFF1FFF20FF3B-FF3DFF3FFF5BFF5DFF5F-FF65",
+ Pd: "002D058A05BE140018062010-20152E172E1A301C303030A0FE31FE32FE58FE63FF0D",
+ Ps: "0028005B007B0F3A0F3C169B201A201E2045207D208D23292768276A276C276E27702772277427C527E627E827EA27EC27EE2983298529872989298B298D298F299129932995299729D829DA29FC2E222E242E262E283008300A300C300E3010301430163018301A301DFD3EFE17FE35FE37FE39FE3BFE3DFE3FFE41FE43FE47FE59FE5BFE5DFF08FF3BFF5BFF5FFF62",
+ Pe: "0029005D007D0F3B0F3D169C2046207E208E232A2769276B276D276F27712773277527C627E727E927EB27ED27EF298429862988298A298C298E2990299229942996299829D929DB29FD2E232E252E272E293009300B300D300F3011301530173019301B301E301FFD3FFE18FE36FE38FE3AFE3CFE3EFE40FE42FE44FE48FE5AFE5CFE5EFF09FF3DFF5DFF60FF63",
+ Pi: "00AB2018201B201C201F20392E022E042E092E0C2E1C2E20",
+ Pf: "00BB2019201D203A2E032E052E0A2E0D2E1D2E21",
+ Pc: "005F203F20402054FE33FE34FE4D-FE4FFF3F",
+ Po: "0021-00230025-0027002A002C002E002F003A003B003F0040005C00A100B700BF037E0387055A-055F058905C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F850FD0-0FD4104A-104F10FB1361-1368166D166E16EB-16ED1735173617D4-17D617D8-17DA1800-18051807-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD3201620172020-20272030-2038203B-203E2041-20432047-205120532055-205E2CF9-2CFC2CFE2CFF2E002E012E06-2E082E0B2E0E-2E162E182E192E1B2E1E2E1F2E2A-2E2E2E302E313001-3003303D30FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFE10-FE16FE19FE30FE45FE46FE49-FE4CFE50-FE52FE54-FE57FE5F-FE61FE68FE6AFE6BFF01-FF03FF05-FF07FF0AFF0CFF0EFF0FFF1AFF1BFF1FFF20FF3CFF61FF64FF65",
+ S: "0024002B003C-003E005E0060007C007E00A2-00A900AC00AE-00B100B400B600B800D700F702C2-02C502D2-02DF02E5-02EB02ED02EF-02FF03750384038503F604820606-0608060B060E060F06E906FD06FE07F609F209F309FA09FB0AF10B700BF3-0BFA0C7F0CF10CF20D790E3F0F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-139917DB194019E0-19FF1B61-1B6A1B74-1B7C1FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE20442052207A-207C208A-208C20A0-20B8210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B2140-2144214A-214D214F2190-2328232B-23E82400-24262440-244A249C-24E92500-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE27C0-27C427C7-27CA27CC27D0-27E527F0-29822999-29D729DC-29FB29FE-2B4C2B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F309B309C319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A700-A716A720A721A789A78AA828-A82BA836-A839AA77-AA79FB29FDFCFDFDFE62FE64-FE66FE69FF04FF0BFF1C-FF1EFF3EFF40FF5CFF5EFFE0-FFE6FFE8-FFEEFFFCFFFD",
+ Sm: "002B003C-003E007C007E00AC00B100D700F703F60606-060820442052207A-207C208A-208C2140-2144214B2190-2194219A219B21A021A321A621AE21CE21CF21D221D421F4-22FF2308-230B23202321237C239B-23B323DC-23E125B725C125F8-25FF266F27C0-27C427C7-27CA27CC27D0-27E527F0-27FF2900-29822999-29D729DC-29FB29FE-2AFF2B30-2B442B47-2B4CFB29FE62FE64-FE66FF0BFF1C-FF1EFF5CFF5EFFE2FFE9-FFEC",
+ Sc: "002400A2-00A5060B09F209F309FB0AF10BF90E3F17DB20A0-20B8A838FDFCFE69FF04FFE0FFE1FFE5FFE6",
+ Sk: "005E006000A800AF00B400B802C2-02C502D2-02DF02E5-02EB02ED02EF-02FF0375038403851FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE309B309CA700-A716A720A721A789A78AFF3EFF40FFE3",
+ So: "00A600A700A900AE00B000B60482060E060F06E906FD06FE07F609FA0B700BF3-0BF80BFA0C7F0CF10CF20D790F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-1399194019E0-19FF1B61-1B6A1B74-1B7C210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B214A214C214D214F2195-2199219C-219F21A121A221A421A521A7-21AD21AF-21CD21D021D121D321D5-21F32300-2307230C-231F2322-2328232B-237B237D-239A23B4-23DB23E2-23E82400-24262440-244A249C-24E92500-25B625B8-25C025C2-25F72600-266E2670-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE2800-28FF2B00-2B2F2B452B462B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A828-A82BA836A837A839AA77-AA79FDFDFFE4FFE8FFEDFFEEFFFCFFFD",
+ Z: "002000A01680180E2000-200A20282029202F205F3000",
+ Zs: "002000A01680180E2000-200A202F205F3000",
+ Zl: "2028",
+ Zp: "2029",
+ C: "0000-001F007F-009F00AD03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-0605061C061D0620065F06DD070E070F074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17B417B517DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF200B-200F202A-202E2060-206F20722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-F8FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFD-FF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFFBFFFEFFFF",
+ Cc: "0000-001F007F-009F",
+ Cf: "00AD0600-060306DD070F17B417B5200B-200F202A-202E2060-2064206A-206FFEFFFFF9-FFFB",
+ Co: "E000-F8FF",
+ Cs: "D800-DFFF",
+ Cn: "03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-05FF06040605061C061D0620065F070E074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF2065-206920722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-D7FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFDFEFEFF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFF8FFFEFFFF"
+});
+
+function addUnicodePackage (pack) {
+ var codePoint = /\w{4}/g;
+ for (var name in pack)
+ exports.packages[name] = pack[name].replace(codePoint, "\\u$&");
+}
+
+});
+
+ace.define("ace/mode/text",["require","exports","module","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour/cstyle","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Tokenizer = require("../tokenizer").Tokenizer;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var unicode = require("../unicode");
+var lang = require("../lib/lang");
+var TokenIterator = require("../token_iterator").TokenIterator;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = TextHighlightRules;
+};
+
+(function() {
+ this.$defaultBehaviour = new CstyleBehaviour();
+
+ this.tokenRe = new RegExp("^["
+ + unicode.packages.L
+ + unicode.packages.Mn + unicode.packages.Mc
+ + unicode.packages.Nd
+ + unicode.packages.Pc + "\\$_]+", "g"
+ );
+
+ this.nonTokenRe = new RegExp("^(?:[^"
+ + unicode.packages.L
+ + unicode.packages.Mn + unicode.packages.Mc
+ + unicode.packages.Nd
+ + unicode.packages.Pc + "\\$_]|\\s])+", "g"
+ );
+
+ this.getTokenizer = function() {
+ if (!this.$tokenizer) {
+ this.$highlightRules = this.$highlightRules || new this.HighlightRules(this.$highlightRuleConfig);
+ this.$tokenizer = new Tokenizer(this.$highlightRules.getRules());
+ }
+ return this.$tokenizer;
+ };
+
+ this.lineCommentStart = "";
+ this.blockComment = "";
+
+ this.toggleCommentLines = function(state, session, startRow, endRow) {
+ var doc = session.doc;
+
+ var ignoreBlankLines = true;
+ var shouldRemove = true;
+ var minIndent = Infinity;
+ var tabSize = session.getTabSize();
+ var insertAtTabStop = false;
+
+ if (!this.lineCommentStart) {
+ if (!this.blockComment)
+ return false;
+ var lineCommentStart = this.blockComment.start;
+ var lineCommentEnd = this.blockComment.end;
+ var regexpStart = new RegExp("^(\\s*)(?:" + lang.escapeRegExp(lineCommentStart) + ")");
+ var regexpEnd = new RegExp("(?:" + lang.escapeRegExp(lineCommentEnd) + ")\\s*$");
+
+ var comment = function(line, i) {
+ if (testRemove(line, i))
+ return;
+ if (!ignoreBlankLines || /\S/.test(line)) {
+ doc.insertInLine({row: i, column: line.length}, lineCommentEnd);
+ doc.insertInLine({row: i, column: minIndent}, lineCommentStart);
+ }
+ };
+
+ var uncomment = function(line, i) {
+ var m;
+ if (m = line.match(regexpEnd))
+ doc.removeInLine(i, line.length - m[0].length, line.length);
+ if (m = line.match(regexpStart))
+ doc.removeInLine(i, m[1].length, m[0].length);
+ };
+
+ var testRemove = function(line, row) {
+ if (regexpStart.test(line))
+ return true;
+ var tokens = session.getTokens(row);
+ for (var i = 0; i < tokens.length; i++) {
+ if (tokens[i].type === "comment")
+ return true;
+ }
+ };
+ } else {
+ if (Array.isArray(this.lineCommentStart)) {
+ var regexpStart = this.lineCommentStart.map(lang.escapeRegExp).join("|");
+ var lineCommentStart = this.lineCommentStart[0];
+ } else {
+ var regexpStart = lang.escapeRegExp(this.lineCommentStart);
+ var lineCommentStart = this.lineCommentStart;
+ }
+ regexpStart = new RegExp("^(\\s*)(?:" + regexpStart + ") ?");
+
+ insertAtTabStop = session.getUseSoftTabs();
+
+ var uncomment = function(line, i) {
+ var m = line.match(regexpStart);
+ if (!m) return;
+ var start = m[1].length, end = m[0].length;
+ if (!shouldInsertSpace(line, start, end) && m[0][end - 1] == " ")
+ end--;
+ doc.removeInLine(i, start, end);
+ };
+ var commentWithSpace = lineCommentStart + " ";
+ var comment = function(line, i) {
+ if (!ignoreBlankLines || /\S/.test(line)) {
+ if (shouldInsertSpace(line, minIndent, minIndent))
+ doc.insertInLine({row: i, column: minIndent}, commentWithSpace);
+ else
+ doc.insertInLine({row: i, column: minIndent}, lineCommentStart);
+ }
+ };
+ var testRemove = function(line, i) {
+ return regexpStart.test(line);
+ };
+
+ var shouldInsertSpace = function(line, before, after) {
+ var spaces = 0;
+ while (before-- && line.charAt(before) == " ")
+ spaces++;
+ if (spaces % tabSize != 0)
+ return false;
+ var spaces = 0;
+ while (line.charAt(after++) == " ")
+ spaces++;
+ if (tabSize > 2)
+ return spaces % tabSize != tabSize - 1;
+ else
+ return spaces % tabSize == 0;
+ return true;
+ };
+ }
+
+ function iter(fun) {
+ for (var i = startRow; i <= endRow; i++)
+ fun(doc.getLine(i), i);
+ }
+
+
+ var minEmptyLength = Infinity;
+ iter(function(line, i) {
+ var indent = line.search(/\S/);
+ if (indent !== -1) {
+ if (indent < minIndent)
+ minIndent = indent;
+ if (shouldRemove && !testRemove(line, i))
+ shouldRemove = false;
+ } else if (minEmptyLength > line.length) {
+ minEmptyLength = line.length;
+ }
+ });
+
+ if (minIndent == Infinity) {
+ minIndent = minEmptyLength;
+ ignoreBlankLines = false;
+ shouldRemove = false;
+ }
+
+ if (insertAtTabStop && minIndent % tabSize != 0)
+ minIndent = Math.floor(minIndent / tabSize) * tabSize;
+
+ iter(shouldRemove ? uncomment : comment);
+ };
+
+ this.toggleBlockComment = function(state, session, range, cursor) {
+ var comment = this.blockComment;
+ if (!comment)
+ return;
+ if (!comment.start && comment[0])
+ comment = comment[0];
+
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ var sel = session.selection;
+ var initialRange = session.selection.toOrientedRange();
+ var startRow, colDiff;
+
+ if (token && /comment/.test(token.type)) {
+ var startRange, endRange;
+ while (token && /comment/.test(token.type)) {
+ var i = token.value.indexOf(comment.start);
+ if (i != -1) {
+ var row = iterator.getCurrentTokenRow();
+ var column = iterator.getCurrentTokenColumn() + i;
+ startRange = new Range(row, column, row, column + comment.start.length);
+ break;
+ }
+ token = iterator.stepBackward();
+ }
+
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ while (token && /comment/.test(token.type)) {
+ var i = token.value.indexOf(comment.end);
+ if (i != -1) {
+ var row = iterator.getCurrentTokenRow();
+ var column = iterator.getCurrentTokenColumn() + i;
+ endRange = new Range(row, column, row, column + comment.end.length);
+ break;
+ }
+ token = iterator.stepForward();
+ }
+ if (endRange)
+ session.remove(endRange);
+ if (startRange) {
+ session.remove(startRange);
+ startRow = startRange.start.row;
+ colDiff = -comment.start.length;
+ }
+ } else {
+ colDiff = comment.start.length;
+ startRow = range.start.row;
+ session.insert(range.end, comment.end);
+ session.insert(range.start, comment.start);
+ }
+ if (initialRange.start.row == startRow)
+ initialRange.start.column += colDiff;
+ if (initialRange.end.row == startRow)
+ initialRange.end.column += colDiff;
+ session.selection.fromOrientedRange(initialRange);
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.createModeDelegates = function (mapping) {
+ this.$embeds = [];
+ this.$modes = {};
+ for (var i in mapping) {
+ if (mapping[i]) {
+ this.$embeds.push(i);
+ this.$modes[i] = new mapping[i]();
+ }
+ }
+
+ var delegations = ["toggleBlockComment", "toggleCommentLines", "getNextLineIndent",
+ "checkOutdent", "autoOutdent", "transformAction", "getCompletions"];
+
+ for (var i = 0; i < delegations.length; i++) {
+ (function(scope) {
+ var functionName = delegations[i];
+ var defaultHandler = scope[functionName];
+ scope[delegations[i]] = function() {
+ return this.$delegator(functionName, arguments, defaultHandler);
+ };
+ }(this));
+ }
+ };
+
+ this.$delegator = function(method, args, defaultHandler) {
+ var state = args[0];
+ if (typeof state != "string")
+ state = state[0];
+ for (var i = 0; i < this.$embeds.length; i++) {
+ if (!this.$modes[this.$embeds[i]]) continue;
+
+ var split = state.split(this.$embeds[i]);
+ if (!split[0] && split[1]) {
+ args[0] = split[1];
+ var mode = this.$modes[this.$embeds[i]];
+ return mode[method].apply(mode, args);
+ }
+ }
+ var ret = defaultHandler.apply(this, args);
+ return defaultHandler ? ret : undefined;
+ };
+
+ this.transformAction = function(state, action, editor, session, param) {
+ if (this.$behaviour) {
+ var behaviours = this.$behaviour.getBehaviours();
+ for (var key in behaviours) {
+ if (behaviours[key][action]) {
+ var ret = behaviours[key][action].apply(this, arguments);
+ if (ret) {
+ return ret;
+ }
+ }
+ }
+ }
+ };
+
+ this.getKeywords = function(append) {
+ if (!this.completionKeywords) {
+ var rules = this.$tokenizer.rules;
+ var completionKeywords = [];
+ for (var rule in rules) {
+ var ruleItr = rules[rule];
+ for (var r = 0, l = ruleItr.length; r < l; r++) {
+ if (typeof ruleItr[r].token === "string") {
+ if (/keyword|support|storage/.test(ruleItr[r].token))
+ completionKeywords.push(ruleItr[r].regex);
+ }
+ else if (typeof ruleItr[r].token === "object") {
+ for (var a = 0, aLength = ruleItr[r].token.length; a < aLength; a++) {
+ if (/keyword|support|storage/.test(ruleItr[r].token[a])) {
+ var rule = ruleItr[r].regex.match(/\(.+?\)/g)[a];
+ completionKeywords.push(rule.substr(1, rule.length - 2));
+ }
+ }
+ }
+ }
+ }
+ this.completionKeywords = completionKeywords;
+ }
+ if (!append)
+ return this.$keywordList;
+ return completionKeywords.concat(this.$keywordList || []);
+ };
+
+ this.$createKeywordList = function() {
+ if (!this.$highlightRules)
+ this.getTokenizer();
+ return this.$keywordList = this.$highlightRules.$keywordList || [];
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var keywords = this.$keywordList || this.$createKeywordList();
+ return keywords.map(function(word) {
+ return {
+ name: word,
+ value: word,
+ score: 0,
+ meta: "keyword"
+ };
+ });
+ };
+
+ this.$id = "ace/mode/text";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var BackgroundTokenizer = function(tokenizer, editor) {
+ this.running = false;
+ this.lines = [];
+ this.states = [];
+ this.currentLine = 0;
+ this.tokenizer = tokenizer;
+
+ var self = this;
+
+ this.$worker = function() {
+ if (!self.running) { return; }
+
+ var workerStart = new Date();
+ var currentLine = self.currentLine;
+ var endLine = -1;
+ var doc = self.doc;
+
+ var startLine = currentLine;
+ while (self.lines[currentLine])
+ currentLine++;
+
+ var len = doc.getLength();
+ var processedLines = 0;
+ self.running = false;
+ while (currentLine < len) {
+ self.$tokenizeRow(currentLine);
+ endLine = currentLine;
+ do {
+ currentLine++;
+ } while (self.lines[currentLine]);
+ processedLines ++;
+ if ((processedLines % 5 === 0) && (new Date() - workerStart) > 20) {
+ self.running = setTimeout(self.$worker, 20);
+ break;
+ }
+ }
+ self.currentLine = currentLine;
+
+ if (endLine == -1)
+ endLine = currentLine;
+
+ if (startLine <= endLine)
+ self.fireUpdateEvent(startLine, endLine);
+ };
+};
+
+(function(){
+
+ oop.implement(this, EventEmitter);
+ this.setTokenizer = function(tokenizer) {
+ this.tokenizer = tokenizer;
+ this.lines = [];
+ this.states = [];
+
+ this.start(0);
+ };
+ this.setDocument = function(doc) {
+ this.doc = doc;
+ this.lines = [];
+ this.states = [];
+
+ this.stop();
+ };
+ this.fireUpdateEvent = function(firstRow, lastRow) {
+ var data = {
+ first: firstRow,
+ last: lastRow
+ };
+ this._signal("update", {data: data});
+ };
+ this.start = function(startRow) {
+ this.currentLine = Math.min(startRow || 0, this.currentLine, this.doc.getLength());
+ this.lines.splice(this.currentLine, this.lines.length);
+ this.states.splice(this.currentLine, this.states.length);
+
+ this.stop();
+ this.running = setTimeout(this.$worker, 700);
+ };
+
+ this.scheduleStart = function() {
+ if (!this.running)
+ this.running = setTimeout(this.$worker, 700);
+ }
+
+ this.$updateOnChange = function(delta) {
+ var startRow = delta.start.row;
+ var len = delta.end.row - startRow;
+
+ if (len === 0) {
+ this.lines[startRow] = null;
+ } else if (delta.action == "remove") {
+ this.lines.splice(startRow, len + 1, null);
+ this.states.splice(startRow, len + 1, null);
+ } else {
+ var args = Array(len + 1);
+ args.unshift(startRow, 1);
+ this.lines.splice.apply(this.lines, args);
+ this.states.splice.apply(this.states, args);
+ }
+
+ this.currentLine = Math.min(startRow, this.currentLine, this.doc.getLength());
+
+ this.stop();
+ };
+ this.stop = function() {
+ if (this.running)
+ clearTimeout(this.running);
+ this.running = false;
+ };
+ this.getTokens = function(row) {
+ return this.lines[row] || this.$tokenizeRow(row);
+ };
+ this.getState = function(row) {
+ if (this.currentLine == row)
+ this.$tokenizeRow(row);
+ return this.states[row] || "start";
+ };
+
+ this.$tokenizeRow = function(row) {
+ var line = this.doc.getLine(row);
+ var state = this.states[row - 1];
+
+ var data = this.tokenizer.getLineTokens(line, state, row);
+
+ if (this.states[row] + "" !== data.state + "") {
+ this.states[row] = data.state;
+ this.lines[row + 1] = null;
+ if (this.currentLine > row + 1)
+ this.currentLine = row + 1;
+ } else if (this.currentLine == row) {
+ this.currentLine = row + 1;
+ }
+
+ return this.lines[row] = data.tokens;
+ };
+
+}).call(BackgroundTokenizer.prototype);
+
+exports.BackgroundTokenizer = BackgroundTokenizer;
+});
+
+ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"], function(require, exports, module) {
+"use strict";
+
+var lang = require("./lib/lang");
+var oop = require("./lib/oop");
+var Range = require("./range").Range;
+
+var SearchHighlight = function(regExp, clazz, type) {
+ this.setRegexp(regExp);
+ this.clazz = clazz;
+ this.type = type || "text";
+};
+
+(function() {
+ this.MAX_RANGES = 500;
+
+ this.setRegexp = function(regExp) {
+ if (this.regExp+"" == regExp+"")
+ return;
+ this.regExp = regExp;
+ this.cache = [];
+ };
+
+ this.update = function(html, markerLayer, session, config) {
+ if (!this.regExp)
+ return;
+ var start = config.firstRow, end = config.lastRow;
+
+ for (var i = start; i <= end; i++) {
+ var ranges = this.cache[i];
+ if (ranges == null) {
+ ranges = lang.getMatchOffsets(session.getLine(i), this.regExp);
+ if (ranges.length > this.MAX_RANGES)
+ ranges = ranges.slice(0, this.MAX_RANGES);
+ ranges = ranges.map(function(match) {
+ return new Range(i, match.offset, i, match.offset + match.length);
+ });
+ this.cache[i] = ranges.length ? ranges : "";
+ }
+
+ for (var j = ranges.length; j --; ) {
+ markerLayer.drawSingleLineMarker(
+ html, ranges[j].toScreenRange(session), this.clazz, config);
+ }
+ }
+ };
+
+}).call(SearchHighlight.prototype);
+
+exports.SearchHighlight = SearchHighlight;
+});
+
+ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+function FoldLine(foldData, folds) {
+ this.foldData = foldData;
+ if (Array.isArray(folds)) {
+ this.folds = folds;
+ } else {
+ folds = this.folds = [ folds ];
+ }
+
+ var last = folds[folds.length - 1];
+ this.range = new Range(folds[0].start.row, folds[0].start.column,
+ last.end.row, last.end.column);
+ this.start = this.range.start;
+ this.end = this.range.end;
+
+ this.folds.forEach(function(fold) {
+ fold.setFoldLine(this);
+ }, this);
+}
+
+(function() {
+ this.shiftRow = function(shift) {
+ this.start.row += shift;
+ this.end.row += shift;
+ this.folds.forEach(function(fold) {
+ fold.start.row += shift;
+ fold.end.row += shift;
+ });
+ };
+
+ this.addFold = function(fold) {
+ if (fold.sameRow) {
+ if (fold.start.row < this.startRow || fold.endRow > this.endRow) {
+ throw new Error("Can't add a fold to this FoldLine as it has no connection");
+ }
+ this.folds.push(fold);
+ this.folds.sort(function(a, b) {
+ return -a.range.compareEnd(b.start.row, b.start.column);
+ });
+ if (this.range.compareEnd(fold.start.row, fold.start.column) > 0) {
+ this.end.row = fold.end.row;
+ this.end.column = fold.end.column;
+ } else if (this.range.compareStart(fold.end.row, fold.end.column) < 0) {
+ this.start.row = fold.start.row;
+ this.start.column = fold.start.column;
+ }
+ } else if (fold.start.row == this.end.row) {
+ this.folds.push(fold);
+ this.end.row = fold.end.row;
+ this.end.column = fold.end.column;
+ } else if (fold.end.row == this.start.row) {
+ this.folds.unshift(fold);
+ this.start.row = fold.start.row;
+ this.start.column = fold.start.column;
+ } else {
+ throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");
+ }
+ fold.foldLine = this;
+ };
+
+ this.containsRow = function(row) {
+ return row >= this.start.row && row <= this.end.row;
+ };
+
+ this.walk = function(callback, endRow, endColumn) {
+ var lastEnd = 0,
+ folds = this.folds,
+ fold,
+ cmp, stop, isNewRow = true;
+
+ if (endRow == null) {
+ endRow = this.end.row;
+ endColumn = this.end.column;
+ }
+
+ for (var i = 0; i < folds.length; i++) {
+ fold = folds[i];
+
+ cmp = fold.range.compareStart(endRow, endColumn);
+ if (cmp == -1) {
+ callback(null, endRow, endColumn, lastEnd, isNewRow);
+ return;
+ }
+
+ stop = callback(null, fold.start.row, fold.start.column, lastEnd, isNewRow);
+ stop = !stop && callback(fold.placeholder, fold.start.row, fold.start.column, lastEnd);
+ if (stop || cmp === 0) {
+ return;
+ }
+ isNewRow = !fold.sameRow;
+ lastEnd = fold.end.column;
+ }
+ callback(null, endRow, endColumn, lastEnd, isNewRow);
+ };
+
+ this.getNextFoldTo = function(row, column) {
+ var fold, cmp;
+ for (var i = 0; i < this.folds.length; i++) {
+ fold = this.folds[i];
+ cmp = fold.range.compareEnd(row, column);
+ if (cmp == -1) {
+ return {
+ fold: fold,
+ kind: "after"
+ };
+ } else if (cmp === 0) {
+ return {
+ fold: fold,
+ kind: "inside"
+ };
+ }
+ }
+ return null;
+ };
+
+ this.addRemoveChars = function(row, column, len) {
+ var ret = this.getNextFoldTo(row, column),
+ fold, folds;
+ if (ret) {
+ fold = ret.fold;
+ if (ret.kind == "inside"
+ && fold.start.column != column
+ && fold.start.row != row)
+ {
+ window.console && window.console.log(row, column, fold);
+ } else if (fold.start.row == row) {
+ folds = this.folds;
+ var i = folds.indexOf(fold);
+ if (i === 0) {
+ this.start.column += len;
+ }
+ for (i; i < folds.length; i++) {
+ fold = folds[i];
+ fold.start.column += len;
+ if (!fold.sameRow) {
+ return;
+ }
+ fold.end.column += len;
+ }
+ this.end.column += len;
+ }
+ }
+ };
+
+ this.split = function(row, column) {
+ var pos = this.getNextFoldTo(row, column);
+
+ if (!pos || pos.kind == "inside")
+ return null;
+
+ var fold = pos.fold;
+ var folds = this.folds;
+ var foldData = this.foldData;
+
+ var i = folds.indexOf(fold);
+ var foldBefore = folds[i - 1];
+ this.end.row = foldBefore.end.row;
+ this.end.column = foldBefore.end.column;
+ folds = folds.splice(i, folds.length - i);
+
+ var newFoldLine = new FoldLine(foldData, folds);
+ foldData.splice(foldData.indexOf(this) + 1, 0, newFoldLine);
+ return newFoldLine;
+ };
+
+ this.merge = function(foldLineNext) {
+ var folds = foldLineNext.folds;
+ for (var i = 0; i < folds.length; i++) {
+ this.addFold(folds[i]);
+ }
+ var foldData = this.foldData;
+ foldData.splice(foldData.indexOf(foldLineNext), 1);
+ };
+
+ this.toString = function() {
+ var ret = [this.range.toString() + ": [" ];
+
+ this.folds.forEach(function(fold) {
+ ret.push(" " + fold.toString());
+ });
+ ret.push("]");
+ return ret.join("\n");
+ };
+
+ this.idxToPosition = function(idx) {
+ var lastFoldEndColumn = 0;
+
+ for (var i = 0; i < this.folds.length; i++) {
+ var fold = this.folds[i];
+
+ idx -= fold.start.column - lastFoldEndColumn;
+ if (idx < 0) {
+ return {
+ row: fold.start.row,
+ column: fold.start.column + idx
+ };
+ }
+
+ idx -= fold.placeholder.length;
+ if (idx < 0) {
+ return fold.start;
+ }
+
+ lastFoldEndColumn = fold.end.column;
+ }
+
+ return {
+ row: this.end.row,
+ column: this.end.column + idx
+ };
+ };
+}).call(FoldLine.prototype);
+
+exports.FoldLine = FoldLine;
+});
+
+ace.define("ace/range_list",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+var Range = require("./range").Range;
+var comparePoints = Range.comparePoints;
+
+var RangeList = function() {
+ this.ranges = [];
+};
+
+(function() {
+ this.comparePoints = comparePoints;
+
+ this.pointIndex = function(pos, excludeEdges, startIndex) {
+ var list = this.ranges;
+
+ for (var i = startIndex || 0; i < list.length; i++) {
+ var range = list[i];
+ var cmpEnd = comparePoints(pos, range.end);
+ if (cmpEnd > 0)
+ continue;
+ var cmpStart = comparePoints(pos, range.start);
+ if (cmpEnd === 0)
+ return excludeEdges && cmpStart !== 0 ? -i-2 : i;
+ if (cmpStart > 0 || (cmpStart === 0 && !excludeEdges))
+ return i;
+
+ return -i-1;
+ }
+ return -i - 1;
+ };
+
+ this.add = function(range) {
+ var excludeEdges = !range.isEmpty();
+ var startIndex = this.pointIndex(range.start, excludeEdges);
+ if (startIndex < 0)
+ startIndex = -startIndex - 1;
+
+ var endIndex = this.pointIndex(range.end, excludeEdges, startIndex);
+
+ if (endIndex < 0)
+ endIndex = -endIndex - 1;
+ else
+ endIndex++;
+ return this.ranges.splice(startIndex, endIndex - startIndex, range);
+ };
+
+ this.addList = function(list) {
+ var removed = [];
+ for (var i = list.length; i--; ) {
+ removed.push.apply(removed, this.add(list[i]));
+ }
+ return removed;
+ };
+
+ this.substractPoint = function(pos) {
+ var i = this.pointIndex(pos);
+
+ if (i >= 0)
+ return this.ranges.splice(i, 1);
+ };
+ this.merge = function() {
+ var removed = [];
+ var list = this.ranges;
+
+ list = list.sort(function(a, b) {
+ return comparePoints(a.start, b.start);
+ });
+
+ var next = list[0], range;
+ for (var i = 1; i < list.length; i++) {
+ range = next;
+ next = list[i];
+ var cmp = comparePoints(range.end, next.start);
+ if (cmp < 0)
+ continue;
+
+ if (cmp == 0 && !range.isEmpty() && !next.isEmpty())
+ continue;
+
+ if (comparePoints(range.end, next.end) < 0) {
+ range.end.row = next.end.row;
+ range.end.column = next.end.column;
+ }
+
+ list.splice(i, 1);
+ removed.push(next);
+ next = range;
+ i--;
+ }
+
+ this.ranges = list;
+
+ return removed;
+ };
+
+ this.contains = function(row, column) {
+ return this.pointIndex({row: row, column: column}) >= 0;
+ };
+
+ this.containsPoint = function(pos) {
+ return this.pointIndex(pos) >= 0;
+ };
+
+ this.rangeAtPoint = function(pos) {
+ var i = this.pointIndex(pos);
+ if (i >= 0)
+ return this.ranges[i];
+ };
+
+
+ this.clipRows = function(startRow, endRow) {
+ var list = this.ranges;
+ if (list[0].start.row > endRow || list[list.length - 1].start.row < startRow)
+ return [];
+
+ var startIndex = this.pointIndex({row: startRow, column: 0});
+ if (startIndex < 0)
+ startIndex = -startIndex - 1;
+ var endIndex = this.pointIndex({row: endRow, column: 0}, startIndex);
+ if (endIndex < 0)
+ endIndex = -endIndex - 1;
+
+ var clipped = [];
+ for (var i = startIndex; i < endIndex; i++) {
+ clipped.push(list[i]);
+ }
+ return clipped;
+ };
+
+ this.removeAll = function() {
+ return this.ranges.splice(0, this.ranges.length);
+ };
+
+ this.attach = function(session) {
+ if (this.session)
+ this.detach();
+
+ this.session = session;
+ this.onChange = this.$onChange.bind(this);
+
+ this.session.on('change', this.onChange);
+ };
+
+ this.detach = function() {
+ if (!this.session)
+ return;
+ this.session.removeListener('change', this.onChange);
+ this.session = null;
+ };
+
+ this.$onChange = function(delta) {
+ if (delta.action == "insert"){
+ var start = delta.start;
+ var end = delta.end;
+ } else {
+ var end = delta.start;
+ var start = delta.end;
+ }
+ var startRow = start.row;
+ var endRow = end.row;
+ var lineDif = endRow - startRow;
+
+ var colDiff = -start.column + end.column;
+ var ranges = this.ranges;
+
+ for (var i = 0, n = ranges.length; i < n; i++) {
+ var r = ranges[i];
+ if (r.end.row < startRow)
+ continue;
+ if (r.start.row > startRow)
+ break;
+
+ if (r.start.row == startRow && r.start.column >= start.column ) {
+ if (r.start.column == start.column && this.$insertRight) {
+ } else {
+ r.start.column += colDiff;
+ r.start.row += lineDif;
+ }
+ }
+ if (r.end.row == startRow && r.end.column >= start.column) {
+ if (r.end.column == start.column && this.$insertRight) {
+ continue;
+ }
+ if (r.end.column == start.column && colDiff > 0 && i < n - 1) {
+ if (r.end.column > r.start.column && r.end.column == ranges[i+1].start.column)
+ r.end.column -= colDiff;
+ }
+ r.end.column += colDiff;
+ r.end.row += lineDif;
+ }
+ }
+
+ if (lineDif != 0 && i < n) {
+ for (; i < n; i++) {
+ var r = ranges[i];
+ r.start.row += lineDif;
+ r.end.row += lineDif;
+ }
+ }
+ };
+
+}).call(RangeList.prototype);
+
+exports.RangeList = RangeList;
+});
+
+ace.define("ace/edit_session/fold",["require","exports","module","ace/range","ace/range_list","ace/lib/oop"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var RangeList = require("../range_list").RangeList;
+var oop = require("../lib/oop")
+var Fold = exports.Fold = function(range, placeholder) {
+ this.foldLine = null;
+ this.placeholder = placeholder;
+ this.range = range;
+ this.start = range.start;
+ this.end = range.end;
+
+ this.sameRow = range.start.row == range.end.row;
+ this.subFolds = this.ranges = [];
+};
+
+oop.inherits(Fold, RangeList);
+
+(function() {
+
+ this.toString = function() {
+ return '"' + this.placeholder + '" ' + this.range.toString();
+ };
+
+ this.setFoldLine = function(foldLine) {
+ this.foldLine = foldLine;
+ this.subFolds.forEach(function(fold) {
+ fold.setFoldLine(foldLine);
+ });
+ };
+
+ this.clone = function() {
+ var range = this.range.clone();
+ var fold = new Fold(range, this.placeholder);
+ this.subFolds.forEach(function(subFold) {
+ fold.subFolds.push(subFold.clone());
+ });
+ fold.collapseChildren = this.collapseChildren;
+ return fold;
+ };
+
+ this.addSubFold = function(fold) {
+ if (this.range.isEqual(fold))
+ return;
+
+ if (!this.range.containsRange(fold))
+ throw new Error("A fold can't intersect already existing fold" + fold.range + this.range);
+ consumeRange(fold, this.start);
+
+ var row = fold.start.row, column = fold.start.column;
+ for (var i = 0, cmp = -1; i < this.subFolds.length; i++) {
+ cmp = this.subFolds[i].range.compare(row, column);
+ if (cmp != 1)
+ break;
+ }
+ var afterStart = this.subFolds[i];
+
+ if (cmp == 0)
+ return afterStart.addSubFold(fold);
+ var row = fold.range.end.row, column = fold.range.end.column;
+ for (var j = i, cmp = -1; j < this.subFolds.length; j++) {
+ cmp = this.subFolds[j].range.compare(row, column);
+ if (cmp != 1)
+ break;
+ }
+ var afterEnd = this.subFolds[j];
+
+ if (cmp == 0)
+ throw new Error("A fold can't intersect already existing fold" + fold.range + this.range);
+
+ var consumedFolds = this.subFolds.splice(i, j - i, fold);
+ fold.setFoldLine(this.foldLine);
+
+ return fold;
+ };
+
+ this.restoreRange = function(range) {
+ return restoreRange(range, this.start);
+ };
+
+}).call(Fold.prototype);
+
+function consumePoint(point, anchor) {
+ point.row -= anchor.row;
+ if (point.row == 0)
+ point.column -= anchor.column;
+}
+function consumeRange(range, anchor) {
+ consumePoint(range.start, anchor);
+ consumePoint(range.end, anchor);
+}
+function restorePoint(point, anchor) {
+ if (point.row == 0)
+ point.column += anchor.column;
+ point.row += anchor.row;
+}
+function restoreRange(range, anchor) {
+ restorePoint(range.start, anchor);
+ restorePoint(range.end, anchor);
+}
+
+});
+
+ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var FoldLine = require("./fold_line").FoldLine;
+var Fold = require("./fold").Fold;
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+function Folding() {
+ this.getFoldAt = function(row, column, side) {
+ var foldLine = this.getFoldLine(row);
+ if (!foldLine)
+ return null;
+
+ var folds = foldLine.folds;
+ for (var i = 0; i < folds.length; i++) {
+ var fold = folds[i];
+ if (fold.range.contains(row, column)) {
+ if (side == 1 && fold.range.isEnd(row, column)) {
+ continue;
+ } else if (side == -1 && fold.range.isStart(row, column)) {
+ continue;
+ }
+ return fold;
+ }
+ }
+ };
+ this.getFoldsInRange = function(range) {
+ var start = range.start;
+ var end = range.end;
+ var foldLines = this.$foldData;
+ var foundFolds = [];
+
+ start.column += 1;
+ end.column -= 1;
+
+ for (var i = 0; i < foldLines.length; i++) {
+ var cmp = foldLines[i].range.compareRange(range);
+ if (cmp == 2) {
+ continue;
+ }
+ else if (cmp == -2) {
+ break;
+ }
+
+ var folds = foldLines[i].folds;
+ for (var j = 0; j < folds.length; j++) {
+ var fold = folds[j];
+ cmp = fold.range.compareRange(range);
+ if (cmp == -2) {
+ break;
+ } else if (cmp == 2) {
+ continue;
+ } else
+ if (cmp == 42) {
+ break;
+ }
+ foundFolds.push(fold);
+ }
+ }
+ start.column -= 1;
+ end.column += 1;
+
+ return foundFolds;
+ };
+
+ this.getFoldsInRangeList = function(ranges) {
+ if (Array.isArray(ranges)) {
+ var folds = [];
+ ranges.forEach(function(range) {
+ folds = folds.concat(this.getFoldsInRange(range));
+ }, this);
+ } else {
+ var folds = this.getFoldsInRange(ranges);
+ }
+ return folds;
+ };
+ this.getAllFolds = function() {
+ var folds = [];
+ var foldLines = this.$foldData;
+
+ for (var i = 0; i < foldLines.length; i++)
+ for (var j = 0; j < foldLines[i].folds.length; j++)
+ folds.push(foldLines[i].folds[j]);
+
+ return folds;
+ };
+ this.getFoldStringAt = function(row, column, trim, foldLine) {
+ foldLine = foldLine || this.getFoldLine(row);
+ if (!foldLine)
+ return null;
+
+ var lastFold = {
+ end: { column: 0 }
+ };
+ var str, fold;
+ for (var i = 0; i < foldLine.folds.length; i++) {
+ fold = foldLine.folds[i];
+ var cmp = fold.range.compareEnd(row, column);
+ if (cmp == -1) {
+ str = this
+ .getLine(fold.start.row)
+ .substring(lastFold.end.column, fold.start.column);
+ break;
+ }
+ else if (cmp === 0) {
+ return null;
+ }
+ lastFold = fold;
+ }
+ if (!str)
+ str = this.getLine(fold.start.row).substring(lastFold.end.column);
+
+ if (trim == -1)
+ return str.substring(0, column - lastFold.end.column);
+ else if (trim == 1)
+ return str.substring(column - lastFold.end.column);
+ else
+ return str;
+ };
+
+ this.getFoldLine = function(docRow, startFoldLine) {
+ var foldData = this.$foldData;
+ var i = 0;
+ if (startFoldLine)
+ i = foldData.indexOf(startFoldLine);
+ if (i == -1)
+ i = 0;
+ for (i; i < foldData.length; i++) {
+ var foldLine = foldData[i];
+ if (foldLine.start.row <= docRow && foldLine.end.row >= docRow) {
+ return foldLine;
+ } else if (foldLine.end.row > docRow) {
+ return null;
+ }
+ }
+ return null;
+ };
+ this.getNextFoldLine = function(docRow, startFoldLine) {
+ var foldData = this.$foldData;
+ var i = 0;
+ if (startFoldLine)
+ i = foldData.indexOf(startFoldLine);
+ if (i == -1)
+ i = 0;
+ for (i; i < foldData.length; i++) {
+ var foldLine = foldData[i];
+ if (foldLine.end.row >= docRow) {
+ return foldLine;
+ }
+ }
+ return null;
+ };
+
+ this.getFoldedRowCount = function(first, last) {
+ var foldData = this.$foldData, rowCount = last-first+1;
+ for (var i = 0; i < foldData.length; i++) {
+ var foldLine = foldData[i],
+ end = foldLine.end.row,
+ start = foldLine.start.row;
+ if (end >= last) {
+ if (start < last) {
+ if (start >= first)
+ rowCount -= last-start;
+ else
+ rowCount = 0; // in one fold
+ }
+ break;
+ } else if (end >= first){
+ if (start >= first) // fold inside range
+ rowCount -= end-start;
+ else
+ rowCount -= end-first+1;
+ }
+ }
+ return rowCount;
+ };
+
+ this.$addFoldLine = function(foldLine) {
+ this.$foldData.push(foldLine);
+ this.$foldData.sort(function(a, b) {
+ return a.start.row - b.start.row;
+ });
+ return foldLine;
+ };
+ this.addFold = function(placeholder, range) {
+ var foldData = this.$foldData;
+ var added = false;
+ var fold;
+
+ if (placeholder instanceof Fold)
+ fold = placeholder;
+ else {
+ fold = new Fold(range, placeholder);
+ fold.collapseChildren = range.collapseChildren;
+ }
+ this.$clipRangeToDocument(fold.range);
+
+ var startRow = fold.start.row;
+ var startColumn = fold.start.column;
+ var endRow = fold.end.row;
+ var endColumn = fold.end.column;
+ if (!(startRow < endRow ||
+ startRow == endRow && startColumn <= endColumn - 2))
+ throw new Error("The range has to be at least 2 characters width");
+
+ var startFold = this.getFoldAt(startRow, startColumn, 1);
+ var endFold = this.getFoldAt(endRow, endColumn, -1);
+ if (startFold && endFold == startFold)
+ return startFold.addSubFold(fold);
+
+ if (startFold && !startFold.range.isStart(startRow, startColumn))
+ this.removeFold(startFold);
+
+ if (endFold && !endFold.range.isEnd(endRow, endColumn))
+ this.removeFold(endFold);
+ var folds = this.getFoldsInRange(fold.range);
+ if (folds.length > 0) {
+ this.removeFolds(folds);
+ folds.forEach(function(subFold) {
+ fold.addSubFold(subFold);
+ });
+ }
+
+ for (var i = 0; i < foldData.length; i++) {
+ var foldLine = foldData[i];
+ if (endRow == foldLine.start.row) {
+ foldLine.addFold(fold);
+ added = true;
+ break;
+ } else if (startRow == foldLine.end.row) {
+ foldLine.addFold(fold);
+ added = true;
+ if (!fold.sameRow) {
+ var foldLineNext = foldData[i + 1];
+ if (foldLineNext && foldLineNext.start.row == endRow) {
+ foldLine.merge(foldLineNext);
+ break;
+ }
+ }
+ break;
+ } else if (endRow <= foldLine.start.row) {
+ break;
+ }
+ }
+
+ if (!added)
+ foldLine = this.$addFoldLine(new FoldLine(this.$foldData, fold));
+
+ if (this.$useWrapMode)
+ this.$updateWrapData(foldLine.start.row, foldLine.start.row);
+ else
+ this.$updateRowLengthCache(foldLine.start.row, foldLine.start.row);
+ this.$modified = true;
+ this._signal("changeFold", { data: fold, action: "add" });
+
+ return fold;
+ };
+
+ this.addFolds = function(folds) {
+ folds.forEach(function(fold) {
+ this.addFold(fold);
+ }, this);
+ };
+
+ this.removeFold = function(fold) {
+ var foldLine = fold.foldLine;
+ var startRow = foldLine.start.row;
+ var endRow = foldLine.end.row;
+
+ var foldLines = this.$foldData;
+ var folds = foldLine.folds;
+ if (folds.length == 1) {
+ foldLines.splice(foldLines.indexOf(foldLine), 1);
+ } else
+ if (foldLine.range.isEnd(fold.end.row, fold.end.column)) {
+ folds.pop();
+ foldLine.end.row = folds[folds.length - 1].end.row;
+ foldLine.end.column = folds[folds.length - 1].end.column;
+ } else
+ if (foldLine.range.isStart(fold.start.row, fold.start.column)) {
+ folds.shift();
+ foldLine.start.row = folds[0].start.row;
+ foldLine.start.column = folds[0].start.column;
+ } else
+ if (fold.sameRow) {
+ folds.splice(folds.indexOf(fold), 1);
+ } else
+ {
+ var newFoldLine = foldLine.split(fold.start.row, fold.start.column);
+ folds = newFoldLine.folds;
+ folds.shift();
+ newFoldLine.start.row = folds[0].start.row;
+ newFoldLine.start.column = folds[0].start.column;
+ }
+
+ if (!this.$updating) {
+ if (this.$useWrapMode)
+ this.$updateWrapData(startRow, endRow);
+ else
+ this.$updateRowLengthCache(startRow, endRow);
+ }
+ this.$modified = true;
+ this._signal("changeFold", { data: fold, action: "remove" });
+ };
+
+ this.removeFolds = function(folds) {
+ var cloneFolds = [];
+ for (var i = 0; i < folds.length; i++) {
+ cloneFolds.push(folds[i]);
+ }
+
+ cloneFolds.forEach(function(fold) {
+ this.removeFold(fold);
+ }, this);
+ this.$modified = true;
+ };
+
+ this.expandFold = function(fold) {
+ this.removeFold(fold);
+ fold.subFolds.forEach(function(subFold) {
+ fold.restoreRange(subFold);
+ this.addFold(subFold);
+ }, this);
+ if (fold.collapseChildren > 0) {
+ this.foldAll(fold.start.row+1, fold.end.row, fold.collapseChildren-1);
+ }
+ fold.subFolds = [];
+ };
+
+ this.expandFolds = function(folds) {
+ folds.forEach(function(fold) {
+ this.expandFold(fold);
+ }, this);
+ };
+
+ this.unfold = function(location, expandInner) {
+ var range, folds;
+ if (location == null) {
+ range = new Range(0, 0, this.getLength(), 0);
+ expandInner = true;
+ } else if (typeof location == "number")
+ range = new Range(location, 0, location, this.getLine(location).length);
+ else if ("row" in location)
+ range = Range.fromPoints(location, location);
+ else
+ range = location;
+
+ folds = this.getFoldsInRangeList(range);
+ if (expandInner) {
+ this.removeFolds(folds);
+ } else {
+ var subFolds = folds;
+ while (subFolds.length) {
+ this.expandFolds(subFolds);
+ subFolds = this.getFoldsInRangeList(range);
+ }
+ }
+ if (folds.length)
+ return folds;
+ };
+ this.isRowFolded = function(docRow, startFoldRow) {
+ return !!this.getFoldLine(docRow, startFoldRow);
+ };
+
+ this.getRowFoldEnd = function(docRow, startFoldRow) {
+ var foldLine = this.getFoldLine(docRow, startFoldRow);
+ return foldLine ? foldLine.end.row : docRow;
+ };
+
+ this.getRowFoldStart = function(docRow, startFoldRow) {
+ var foldLine = this.getFoldLine(docRow, startFoldRow);
+ return foldLine ? foldLine.start.row : docRow;
+ };
+
+ this.getFoldDisplayLine = function(foldLine, endRow, endColumn, startRow, startColumn) {
+ if (startRow == null)
+ startRow = foldLine.start.row;
+ if (startColumn == null)
+ startColumn = 0;
+ if (endRow == null)
+ endRow = foldLine.end.row;
+ if (endColumn == null)
+ endColumn = this.getLine(endRow).length;
+ var doc = this.doc;
+ var textLine = "";
+
+ foldLine.walk(function(placeholder, row, column, lastColumn) {
+ if (row < startRow)
+ return;
+ if (row == startRow) {
+ if (column < startColumn)
+ return;
+ lastColumn = Math.max(startColumn, lastColumn);
+ }
+
+ if (placeholder != null) {
+ textLine += placeholder;
+ } else {
+ textLine += doc.getLine(row).substring(lastColumn, column);
+ }
+ }, endRow, endColumn);
+ return textLine;
+ };
+
+ this.getDisplayLine = function(row, endColumn, startRow, startColumn) {
+ var foldLine = this.getFoldLine(row);
+
+ if (!foldLine) {
+ var line;
+ line = this.doc.getLine(row);
+ return line.substring(startColumn || 0, endColumn || line.length);
+ } else {
+ return this.getFoldDisplayLine(
+ foldLine, row, endColumn, startRow, startColumn);
+ }
+ };
+
+ this.$cloneFoldData = function() {
+ var fd = [];
+ fd = this.$foldData.map(function(foldLine) {
+ var folds = foldLine.folds.map(function(fold) {
+ return fold.clone();
+ });
+ return new FoldLine(fd, folds);
+ });
+
+ return fd;
+ };
+
+ this.toggleFold = function(tryToUnfold) {
+ var selection = this.selection;
+ var range = selection.getRange();
+ var fold;
+ var bracketPos;
+
+ if (range.isEmpty()) {
+ var cursor = range.start;
+ fold = this.getFoldAt(cursor.row, cursor.column);
+
+ if (fold) {
+ this.expandFold(fold);
+ return;
+ } else if (bracketPos = this.findMatchingBracket(cursor)) {
+ if (range.comparePoint(bracketPos) == 1) {
+ range.end = bracketPos;
+ } else {
+ range.start = bracketPos;
+ range.start.column++;
+ range.end.column--;
+ }
+ } else if (bracketPos = this.findMatchingBracket({row: cursor.row, column: cursor.column + 1})) {
+ if (range.comparePoint(bracketPos) == 1)
+ range.end = bracketPos;
+ else
+ range.start = bracketPos;
+
+ range.start.column++;
+ } else {
+ range = this.getCommentFoldRange(cursor.row, cursor.column) || range;
+ }
+ } else {
+ var folds = this.getFoldsInRange(range);
+ if (tryToUnfold && folds.length) {
+ this.expandFolds(folds);
+ return;
+ } else if (folds.length == 1 ) {
+ fold = folds[0];
+ }
+ }
+
+ if (!fold)
+ fold = this.getFoldAt(range.start.row, range.start.column);
+
+ if (fold && fold.range.toString() == range.toString()) {
+ this.expandFold(fold);
+ return;
+ }
+
+ var placeholder = "...";
+ if (!range.isMultiLine()) {
+ placeholder = this.getTextRange(range);
+ if (placeholder.length < 4)
+ return;
+ placeholder = placeholder.trim().substring(0, 2) + "..";
+ }
+
+ this.addFold(placeholder, range);
+ };
+
+ this.getCommentFoldRange = function(row, column, dir) {
+ var iterator = new TokenIterator(this, row, column);
+ var token = iterator.getCurrentToken();
+ var type = token.type;
+ if (token && /^comment|string/.test(type)) {
+ type = type.match(/comment|string/)[0];
+ if (type == "comment")
+ type += "|doc-start";
+ var re = new RegExp(type);
+ var range = new Range();
+ if (dir != 1) {
+ do {
+ token = iterator.stepBackward();
+ } while (token && re.test(token.type));
+ iterator.stepForward();
+ }
+
+ range.start.row = iterator.getCurrentTokenRow();
+ range.start.column = iterator.getCurrentTokenColumn() + 2;
+
+ iterator = new TokenIterator(this, row, column);
+
+ if (dir != -1) {
+ var lastRow = -1;
+ do {
+ token = iterator.stepForward();
+ if (lastRow == -1) {
+ var state = this.getState(iterator.$row);
+ if (!re.test(state))
+ lastRow = iterator.$row;
+ } else if (iterator.$row > lastRow) {
+ break;
+ }
+ } while (token && re.test(token.type));
+ token = iterator.stepBackward();
+ } else
+ token = iterator.getCurrentToken();
+
+ range.end.row = iterator.getCurrentTokenRow();
+ range.end.column = iterator.getCurrentTokenColumn() + token.value.length - 2;
+ return range;
+ }
+ };
+
+ this.foldAll = function(startRow, endRow, depth) {
+ if (depth == undefined)
+ depth = 100000; // JSON.stringify doesn't hanle Infinity
+ var foldWidgets = this.foldWidgets;
+ if (!foldWidgets)
+ return; // mode doesn't support folding
+ endRow = endRow || this.getLength();
+ startRow = startRow || 0;
+ for (var row = startRow; row < endRow; row++) {
+ if (foldWidgets[row] == null)
+ foldWidgets[row] = this.getFoldWidget(row);
+ if (foldWidgets[row] != "start")
+ continue;
+
+ var range = this.getFoldWidgetRange(row);
+ if (range && range.isMultiLine()
+ && range.end.row <= endRow
+ && range.start.row >= startRow
+ ) {
+ row = range.end.row;
+ try {
+ var fold = this.addFold("...", range);
+ if (fold)
+ fold.collapseChildren = depth;
+ } catch(e) {}
+ }
+ }
+ };
+ this.$foldStyles = {
+ "manual": 1,
+ "markbegin": 1,
+ "markbeginend": 1
+ };
+ this.$foldStyle = "markbegin";
+ this.setFoldStyle = function(style) {
+ if (!this.$foldStyles[style])
+ throw new Error("invalid fold style: " + style + "[" + Object.keys(this.$foldStyles).join(", ") + "]");
+
+ if (this.$foldStyle == style)
+ return;
+
+ this.$foldStyle = style;
+
+ if (style == "manual")
+ this.unfold();
+ var mode = this.$foldMode;
+ this.$setFolding(null);
+ this.$setFolding(mode);
+ };
+
+ this.$setFolding = function(foldMode) {
+ if (this.$foldMode == foldMode)
+ return;
+
+ this.$foldMode = foldMode;
+
+ this.off('change', this.$updateFoldWidgets);
+ this.off('tokenizerUpdate', this.$tokenizerUpdateFoldWidgets);
+ this._signal("changeAnnotation");
+
+ if (!foldMode || this.$foldStyle == "manual") {
+ this.foldWidgets = null;
+ return;
+ }
+
+ this.foldWidgets = [];
+ this.getFoldWidget = foldMode.getFoldWidget.bind(foldMode, this, this.$foldStyle);
+ this.getFoldWidgetRange = foldMode.getFoldWidgetRange.bind(foldMode, this, this.$foldStyle);
+
+ this.$updateFoldWidgets = this.updateFoldWidgets.bind(this);
+ this.$tokenizerUpdateFoldWidgets = this.tokenizerUpdateFoldWidgets.bind(this);
+ this.on('change', this.$updateFoldWidgets);
+ this.on('tokenizerUpdate', this.$tokenizerUpdateFoldWidgets);
+ };
+
+ this.getParentFoldRangeData = function (row, ignoreCurrent) {
+ var fw = this.foldWidgets;
+ if (!fw || (ignoreCurrent && fw[row]))
+ return {};
+
+ var i = row - 1, firstRange;
+ while (i >= 0) {
+ var c = fw[i];
+ if (c == null)
+ c = fw[i] = this.getFoldWidget(i);
+
+ if (c == "start") {
+ var range = this.getFoldWidgetRange(i);
+ if (!firstRange)
+ firstRange = range;
+ if (range && range.end.row >= row)
+ break;
+ }
+ i--;
+ }
+
+ return {
+ range: i !== -1 && range,
+ firstRange: firstRange
+ };
+ };
+
+ this.onFoldWidgetClick = function(row, e) {
+ e = e.domEvent;
+ var options = {
+ children: e.shiftKey,
+ all: e.ctrlKey || e.metaKey,
+ siblings: e.altKey
+ };
+
+ var range = this.$toggleFoldWidget(row, options);
+ if (!range) {
+ var el = (e.target || e.srcElement);
+ if (el && /ace_fold-widget/.test(el.className))
+ el.className += " ace_invalid";
+ }
+ };
+
+ this.$toggleFoldWidget = function(row, options) {
+ if (!this.getFoldWidget)
+ return;
+ var type = this.getFoldWidget(row);
+ var line = this.getLine(row);
+
+ var dir = type === "end" ? -1 : 1;
+ var fold = this.getFoldAt(row, dir === -1 ? 0 : line.length, dir);
+
+ if (fold) {
+ if (options.children || options.all)
+ this.removeFold(fold);
+ else
+ this.expandFold(fold);
+ return fold;
+ }
+
+ var range = this.getFoldWidgetRange(row, true);
+ if (range && !range.isMultiLine()) {
+ fold = this.getFoldAt(range.start.row, range.start.column, 1);
+ if (fold && range.isEqual(fold.range)) {
+ this.removeFold(fold);
+ return fold;
+ }
+ }
+
+ if (options.siblings) {
+ var data = this.getParentFoldRangeData(row);
+ if (data.range) {
+ var startRow = data.range.start.row + 1;
+ var endRow = data.range.end.row;
+ }
+ this.foldAll(startRow, endRow, options.all ? 10000 : 0);
+ } else if (options.children) {
+ endRow = range ? range.end.row : this.getLength();
+ this.foldAll(row + 1, endRow, options.all ? 10000 : 0);
+ } else if (range) {
+ if (options.all)
+ range.collapseChildren = 10000;
+ this.addFold("...", range);
+ }
+
+ return range;
+ };
+
+
+
+ this.toggleFoldWidget = function(toggleParent) {
+ var row = this.selection.getCursor().row;
+ row = this.getRowFoldStart(row);
+ var range = this.$toggleFoldWidget(row, {});
+
+ if (range)
+ return;
+ var data = this.getParentFoldRangeData(row, true);
+ range = data.range || data.firstRange;
+
+ if (range) {
+ row = range.start.row;
+ var fold = this.getFoldAt(row, this.getLine(row).length, 1);
+
+ if (fold) {
+ this.removeFold(fold);
+ } else {
+ this.addFold("...", range);
+ }
+ }
+ };
+
+ this.updateFoldWidgets = function(delta) {
+ var firstRow = delta.start.row;
+ var len = delta.end.row - firstRow;
+
+ if (len === 0) {
+ this.foldWidgets[firstRow] = null;
+ } else if (delta.action == 'remove') {
+ this.foldWidgets.splice(firstRow, len + 1, null);
+ } else {
+ var args = Array(len + 1);
+ args.unshift(firstRow, 1);
+ this.foldWidgets.splice.apply(this.foldWidgets, args);
+ }
+ };
+ this.tokenizerUpdateFoldWidgets = function(e) {
+ var rows = e.data;
+ if (rows.first != rows.last) {
+ if (this.foldWidgets.length > rows.first)
+ this.foldWidgets.splice(rows.first, this.foldWidgets.length);
+ }
+ };
+}
+
+exports.Folding = Folding;
+
+});
+
+ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+var Range = require("../range").Range;
+
+
+function BracketMatch() {
+
+ this.findMatchingBracket = function(position, chr) {
+ if (position.column == 0) return null;
+
+ var charBeforeCursor = chr || this.getLine(position.row).charAt(position.column-1);
+ if (charBeforeCursor == "") return null;
+
+ var match = charBeforeCursor.match(/([\(\[\{])|([\)\]\}])/);
+ if (!match)
+ return null;
+
+ if (match[1])
+ return this.$findClosingBracket(match[1], position);
+ else
+ return this.$findOpeningBracket(match[2], position);
+ };
+
+ this.getBracketRange = function(pos) {
+ var line = this.getLine(pos.row);
+ var before = true, range;
+
+ var chr = line.charAt(pos.column-1);
+ var match = chr && chr.match(/([\(\[\{])|([\)\]\}])/);
+ if (!match) {
+ chr = line.charAt(pos.column);
+ pos = {row: pos.row, column: pos.column + 1};
+ match = chr && chr.match(/([\(\[\{])|([\)\]\}])/);
+ before = false;
+ }
+ if (!match)
+ return null;
+
+ if (match[1]) {
+ var bracketPos = this.$findClosingBracket(match[1], pos);
+ if (!bracketPos)
+ return null;
+ range = Range.fromPoints(pos, bracketPos);
+ if (!before) {
+ range.end.column++;
+ range.start.column--;
+ }
+ range.cursor = range.end;
+ } else {
+ var bracketPos = this.$findOpeningBracket(match[2], pos);
+ if (!bracketPos)
+ return null;
+ range = Range.fromPoints(bracketPos, pos);
+ if (!before) {
+ range.start.column++;
+ range.end.column--;
+ }
+ range.cursor = range.start;
+ }
+
+ return range;
+ };
+
+ this.$brackets = {
+ ")": "(",
+ "(": ")",
+ "]": "[",
+ "[": "]",
+ "{": "}",
+ "}": "{"
+ };
+
+ this.$findOpeningBracket = function(bracket, position, typeRe) {
+ var openBracket = this.$brackets[bracket];
+ var depth = 1;
+
+ var iterator = new TokenIterator(this, position.row, position.column);
+ var token = iterator.getCurrentToken();
+ if (!token)
+ token = iterator.stepForward();
+ if (!token)
+ return;
+
+ if (!typeRe){
+ typeRe = new RegExp(
+ "(\\.?" +
+ token.type.replace(".", "\\.").replace("rparen", ".paren")
+ .replace(/\b(?:end)\b/, "(?:start|begin|end)")
+ + ")+"
+ );
+ }
+ var valueIndex = position.column - iterator.getCurrentTokenColumn() - 2;
+ var value = token.value;
+
+ while (true) {
+
+ while (valueIndex >= 0) {
+ var chr = value.charAt(valueIndex);
+ if (chr == openBracket) {
+ depth -= 1;
+ if (depth == 0) {
+ return {row: iterator.getCurrentTokenRow(),
+ column: valueIndex + iterator.getCurrentTokenColumn()};
+ }
+ }
+ else if (chr == bracket) {
+ depth += 1;
+ }
+ valueIndex -= 1;
+ }
+ do {
+ token = iterator.stepBackward();
+ } while (token && !typeRe.test(token.type));
+
+ if (token == null)
+ break;
+
+ value = token.value;
+ valueIndex = value.length - 1;
+ }
+
+ return null;
+ };
+
+ this.$findClosingBracket = function(bracket, position, typeRe) {
+ var closingBracket = this.$brackets[bracket];
+ var depth = 1;
+
+ var iterator = new TokenIterator(this, position.row, position.column);
+ var token = iterator.getCurrentToken();
+ if (!token)
+ token = iterator.stepForward();
+ if (!token)
+ return;
+
+ if (!typeRe){
+ typeRe = new RegExp(
+ "(\\.?" +
+ token.type.replace(".", "\\.").replace("lparen", ".paren")
+ .replace(/\b(?:start|begin)\b/, "(?:start|begin|end)")
+ + ")+"
+ );
+ }
+ var valueIndex = position.column - iterator.getCurrentTokenColumn();
+
+ while (true) {
+
+ var value = token.value;
+ var valueLength = value.length;
+ while (valueIndex < valueLength) {
+ var chr = value.charAt(valueIndex);
+ if (chr == closingBracket) {
+ depth -= 1;
+ if (depth == 0) {
+ return {row: iterator.getCurrentTokenRow(),
+ column: valueIndex + iterator.getCurrentTokenColumn()};
+ }
+ }
+ else if (chr == bracket) {
+ depth += 1;
+ }
+ valueIndex += 1;
+ }
+ do {
+ token = iterator.stepForward();
+ } while (token && !typeRe.test(token.type));
+
+ if (token == null)
+ break;
+
+ valueIndex = 0;
+ }
+
+ return null;
+ };
+}
+exports.BracketMatch = BracketMatch;
+
+});
+
+ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/bidihandler","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/document","ace/background_tokenizer","ace/search_highlight","ace/edit_session/folding","ace/edit_session/bracket_match"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var lang = require("./lib/lang");
+var BidiHandler = require("./bidihandler").BidiHandler;
+var config = require("./config");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Selection = require("./selection").Selection;
+var TextMode = require("./mode/text").Mode;
+var Range = require("./range").Range;
+var Document = require("./document").Document;
+var BackgroundTokenizer = require("./background_tokenizer").BackgroundTokenizer;
+var SearchHighlight = require("./search_highlight").SearchHighlight;
+
+var EditSession = function(text, mode) {
+ this.$breakpoints = [];
+ this.$decorations = [];
+ this.$frontMarkers = {};
+ this.$backMarkers = {};
+ this.$markerId = 1;
+ this.$undoSelect = true;
+
+ this.$foldData = [];
+ this.id = "session" + (++EditSession.$uid);
+ this.$foldData.toString = function() {
+ return this.join("\n");
+ };
+ this.on("changeFold", this.onChangeFold.bind(this));
+ this.$onChange = this.onChange.bind(this);
+
+ if (typeof text != "object" || !text.getLine)
+ text = new Document(text);
+
+ this.$bidiHandler = new BidiHandler(this);
+ this.setDocument(text);
+ this.selection = new Selection(this);
+
+ config.resetOptions(this);
+ this.setMode(mode);
+ config._signal("session", this);
+};
+
+
+EditSession.$uid = 0;
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setDocument = function(doc) {
+ if (this.doc)
+ this.doc.removeListener("change", this.$onChange);
+
+ this.doc = doc;
+ doc.on("change", this.$onChange);
+
+ if (this.bgTokenizer)
+ this.bgTokenizer.setDocument(this.getDocument());
+
+ this.resetCaches();
+ };
+ this.getDocument = function() {
+ return this.doc;
+ };
+ this.$resetRowCache = function(docRow) {
+ if (!docRow) {
+ this.$docRowCache = [];
+ this.$screenRowCache = [];
+ return;
+ }
+ var l = this.$docRowCache.length;
+ var i = this.$getRowCacheIndex(this.$docRowCache, docRow) + 1;
+ if (l > i) {
+ this.$docRowCache.splice(i, l);
+ this.$screenRowCache.splice(i, l);
+ }
+ };
+
+ this.$getRowCacheIndex = function(cacheArray, val) {
+ var low = 0;
+ var hi = cacheArray.length - 1;
+
+ while (low <= hi) {
+ var mid = (low + hi) >> 1;
+ var c = cacheArray[mid];
+
+ if (val > c)
+ low = mid + 1;
+ else if (val < c)
+ hi = mid - 1;
+ else
+ return mid;
+ }
+
+ return low -1;
+ };
+
+ this.resetCaches = function() {
+ this.$modified = true;
+ this.$wrapData = [];
+ this.$rowLengthCache = [];
+ this.$resetRowCache(0);
+ if (this.bgTokenizer)
+ this.bgTokenizer.start(0);
+ };
+
+ this.onChangeFold = function(e) {
+ var fold = e.data;
+ this.$resetRowCache(fold.start.row);
+ };
+
+ this.onChange = function(delta) {
+ this.$modified = true;
+ this.$bidiHandler.markAsDirty();
+ this.$resetRowCache(delta.start.row);
+
+ var removedFolds = this.$updateInternalDataOnChange(delta);
+ if (!this.$fromUndo && this.$undoManager && !delta.ignore) {
+ this.$deltasDoc.push(delta);
+ if (removedFolds && removedFolds.length != 0) {
+ this.$deltasFold.push({
+ action: "removeFolds",
+ folds: removedFolds
+ });
+ }
+
+ this.$informUndoManager.schedule();
+ }
+
+ this.bgTokenizer && this.bgTokenizer.$updateOnChange(delta);
+ this._signal("change", delta);
+ };
+ this.setValue = function(text) {
+ this.doc.setValue(text);
+ this.selection.moveTo(0, 0);
+
+ this.$resetRowCache(0);
+ this.$deltas = [];
+ this.$deltasDoc = [];
+ this.$deltasFold = [];
+ this.setUndoManager(this.$undoManager);
+ this.getUndoManager().reset();
+ };
+ this.getValue =
+ this.toString = function() {
+ return this.doc.getValue();
+ };
+ this.getSelection = function() {
+ return this.selection;
+ };
+ this.getState = function(row) {
+ return this.bgTokenizer.getState(row);
+ };
+ this.getTokens = function(row) {
+ return this.bgTokenizer.getTokens(row);
+ };
+ this.getTokenAt = function(row, column) {
+ var tokens = this.bgTokenizer.getTokens(row);
+ var token, c = 0;
+ if (column == null) {
+ i = tokens.length - 1;
+ c = this.getLine(row).length;
+ } else {
+ for (var i = 0; i < tokens.length; i++) {
+ c += tokens[i].value.length;
+ if (c >= column)
+ break;
+ }
+ }
+ token = tokens[i];
+ if (!token)
+ return null;
+ token.index = i;
+ token.start = c - token.value.length;
+ return token;
+ };
+ this.setUndoManager = function(undoManager) {
+ this.$undoManager = undoManager;
+ this.$deltas = [];
+ this.$deltasDoc = [];
+ this.$deltasFold = [];
+
+ if (this.$informUndoManager)
+ this.$informUndoManager.cancel();
+
+ if (undoManager) {
+ var self = this;
+
+ this.$syncInformUndoManager = function() {
+ self.$informUndoManager.cancel();
+
+ if (self.$deltasFold.length) {
+ self.$deltas.push({
+ group: "fold",
+ deltas: self.$deltasFold
+ });
+ self.$deltasFold = [];
+ }
+
+ if (self.$deltasDoc.length) {
+ self.$deltas.push({
+ group: "doc",
+ deltas: self.$deltasDoc
+ });
+ self.$deltasDoc = [];
+ }
+
+ if (self.$deltas.length > 0) {
+ undoManager.execute({
+ action: "aceupdate",
+ args: [self.$deltas, self],
+ merge: self.mergeUndoDeltas
+ });
+ }
+ self.mergeUndoDeltas = false;
+ self.$deltas = [];
+ };
+ this.$informUndoManager = lang.delayedCall(this.$syncInformUndoManager);
+ }
+ };
+ this.markUndoGroup = function() {
+ if (this.$syncInformUndoManager)
+ this.$syncInformUndoManager();
+ };
+
+ this.$defaultUndoManager = {
+ undo: function() {},
+ redo: function() {},
+ reset: function() {}
+ };
+ this.getUndoManager = function() {
+ return this.$undoManager || this.$defaultUndoManager;
+ };
+ this.getTabString = function() {
+ if (this.getUseSoftTabs()) {
+ return lang.stringRepeat(" ", this.getTabSize());
+ } else {
+ return "\t";
+ }
+ };
+ this.setUseSoftTabs = function(val) {
+ this.setOption("useSoftTabs", val);
+ };
+ this.getUseSoftTabs = function() {
+ return this.$useSoftTabs && !this.$mode.$indentWithTabs;
+ };
+ this.setTabSize = function(tabSize) {
+ this.setOption("tabSize", tabSize);
+ };
+ this.getTabSize = function() {
+ return this.$tabSize;
+ };
+ this.isTabStop = function(position) {
+ return this.$useSoftTabs && (position.column % this.$tabSize === 0);
+ };
+ this.setNavigateWithinSoftTabs = function (navigateWithinSoftTabs) {
+ this.setOption("navigateWithinSoftTabs", navigateWithinSoftTabs)
+ }
+ this.getNavigateWithinSoftTabs = function() {
+ return this.$navigateWithinSoftTabs;
+ }
+
+ this.$overwrite = false;
+ this.setOverwrite = function(overwrite) {
+ this.setOption("overwrite", overwrite);
+ };
+ this.getOverwrite = function() {
+ return this.$overwrite;
+ };
+ this.toggleOverwrite = function() {
+ this.setOverwrite(!this.$overwrite);
+ };
+ this.addGutterDecoration = function(row, className) {
+ if (!this.$decorations[row])
+ this.$decorations[row] = "";
+ this.$decorations[row] += " " + className;
+ this._signal("changeBreakpoint", {});
+ };
+ this.removeGutterDecoration = function(row, className) {
+ this.$decorations[row] = (this.$decorations[row] || "").replace(" " + className, "");
+ this._signal("changeBreakpoint", {});
+ };
+ this.getBreakpoints = function() {
+ return this.$breakpoints;
+ };
+ this.setBreakpoints = function(rows) {
+ this.$breakpoints = [];
+ for (var i=0; i<rows.length; i++) {
+ this.$breakpoints[rows[i]] = "ace_breakpoint";
+ }
+ this._signal("changeBreakpoint", {});
+ };
+ this.clearBreakpoints = function() {
+ this.$breakpoints = [];
+ this._signal("changeBreakpoint", {});
+ };
+ this.setBreakpoint = function(row, className) {
+ if (className === undefined)
+ className = "ace_breakpoint";
+ if (className)
+ this.$breakpoints[row] = className;
+ else
+ delete this.$breakpoints[row];
+ this._signal("changeBreakpoint", {});
+ };
+ this.clearBreakpoint = function(row) {
+ delete this.$breakpoints[row];
+ this._signal("changeBreakpoint", {});
+ };
+ this.addMarker = function(range, clazz, type, inFront) {
+ var id = this.$markerId++;
+
+ var marker = {
+ range : range,
+ type : type || "line",
+ renderer: typeof type == "function" ? type : null,
+ clazz : clazz,
+ inFront: !!inFront,
+ id: id
+ };
+
+ if (inFront) {
+ this.$frontMarkers[id] = marker;
+ this._signal("changeFrontMarker");
+ } else {
+ this.$backMarkers[id] = marker;
+ this._signal("changeBackMarker");
+ }
+
+ return id;
+ };
+ this.addDynamicMarker = function(marker, inFront) {
+ if (!marker.update)
+ return;
+ var id = this.$markerId++;
+ marker.id = id;
+ marker.inFront = !!inFront;
+
+ if (inFront) {
+ this.$frontMarkers[id] = marker;
+ this._signal("changeFrontMarker");
+ } else {
+ this.$backMarkers[id] = marker;
+ this._signal("changeBackMarker");
+ }
+
+ return marker;
+ };
+ this.removeMarker = function(markerId) {
+ var marker = this.$frontMarkers[markerId] || this.$backMarkers[markerId];
+ if (!marker)
+ return;
+
+ var markers = marker.inFront ? this.$frontMarkers : this.$backMarkers;
+ if (marker) {
+ delete (markers[markerId]);
+ this._signal(marker.inFront ? "changeFrontMarker" : "changeBackMarker");
+ }
+ };
+ this.getMarkers = function(inFront) {
+ return inFront ? this.$frontMarkers : this.$backMarkers;
+ };
+
+ this.highlight = function(re) {
+ if (!this.$searchHighlight) {
+ var highlight = new SearchHighlight(null, "ace_selected-word", "text");
+ this.$searchHighlight = this.addDynamicMarker(highlight);
+ }
+ this.$searchHighlight.setRegexp(re);
+ };
+ this.highlightLines = function(startRow, endRow, clazz, inFront) {
+ if (typeof endRow != "number") {
+ clazz = endRow;
+ endRow = startRow;
+ }
+ if (!clazz)
+ clazz = "ace_step";
+
+ var range = new Range(startRow, 0, endRow, Infinity);
+ range.id = this.addMarker(range, clazz, "fullLine", inFront);
+ return range;
+ };
+ this.setAnnotations = function(annotations) {
+ this.$annotations = annotations;
+ this._signal("changeAnnotation", {});
+ };
+ this.getAnnotations = function() {
+ return this.$annotations || [];
+ };
+ this.clearAnnotations = function() {
+ this.setAnnotations([]);
+ };
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r?\n)/m);
+ if (match) {
+ this.$autoNewLine = match[1];
+ } else {
+ this.$autoNewLine = "\n";
+ }
+ };
+ this.getWordRange = function(row, column) {
+ var line = this.getLine(row);
+
+ var inToken = false;
+ if (column > 0)
+ inToken = !!line.charAt(column - 1).match(this.tokenRe);
+
+ if (!inToken)
+ inToken = !!line.charAt(column).match(this.tokenRe);
+
+ if (inToken)
+ var re = this.tokenRe;
+ else if (/^\s+$/.test(line.slice(column-1, column+1)))
+ var re = /\s/;
+ else
+ var re = this.nonTokenRe;
+
+ var start = column;
+ if (start > 0) {
+ do {
+ start--;
+ }
+ while (start >= 0 && line.charAt(start).match(re));
+ start++;
+ }
+
+ var end = column;
+ while (end < line.length && line.charAt(end).match(re)) {
+ end++;
+ }
+
+ return new Range(row, start, row, end);
+ };
+ this.getAWordRange = function(row, column) {
+ var wordRange = this.getWordRange(row, column);
+ var line = this.getLine(wordRange.end.row);
+
+ while (line.charAt(wordRange.end.column).match(/[ \t]/)) {
+ wordRange.end.column += 1;
+ }
+ return wordRange;
+ };
+ this.setNewLineMode = function(newLineMode) {
+ this.doc.setNewLineMode(newLineMode);
+ };
+ this.getNewLineMode = function() {
+ return this.doc.getNewLineMode();
+ };
+ this.setUseWorker = function(useWorker) { this.setOption("useWorker", useWorker); };
+ this.getUseWorker = function() { return this.$useWorker; };
+ this.onReloadTokenizer = function(e) {
+ var rows = e.data;
+ this.bgTokenizer.start(rows.first);
+ this._signal("tokenizerUpdate", e);
+ };
+
+ this.$modes = {};
+ this.$mode = null;
+ this.$modeId = null;
+ this.setMode = function(mode, cb) {
+ if (mode && typeof mode === "object") {
+ if (mode.getTokenizer)
+ return this.$onChangeMode(mode);
+ var options = mode;
+ var path = options.path;
+ } else {
+ path = mode || "ace/mode/text";
+ }
+ if (!this.$modes["ace/mode/text"])
+ this.$modes["ace/mode/text"] = new TextMode();
+
+ if (this.$modes[path] && !options) {
+ this.$onChangeMode(this.$modes[path]);
+ cb && cb();
+ return;
+ }
+ this.$modeId = path;
+ config.loadModule(["mode", path], function(m) {
+ if (this.$modeId !== path)
+ return cb && cb();
+ if (this.$modes[path] && !options) {
+ this.$onChangeMode(this.$modes[path]);
+ } else if (m && m.Mode) {
+ m = new m.Mode(options);
+ if (!options) {
+ this.$modes[path] = m;
+ m.$id = path;
+ }
+ this.$onChangeMode(m);
+ }
+ cb && cb();
+ }.bind(this));
+ if (!this.$mode)
+ this.$onChangeMode(this.$modes["ace/mode/text"], true);
+ };
+
+ this.$onChangeMode = function(mode, $isPlaceholder) {
+ if (!$isPlaceholder)
+ this.$modeId = mode.$id;
+ if (this.$mode === mode)
+ return;
+
+ this.$mode = mode;
+
+ this.$stopWorker();
+
+ if (this.$useWorker)
+ this.$startWorker();
+
+ var tokenizer = mode.getTokenizer();
+
+ if(tokenizer.addEventListener !== undefined) {
+ var onReloadTokenizer = this.onReloadTokenizer.bind(this);
+ tokenizer.addEventListener("update", onReloadTokenizer);
+ }
+
+ if (!this.bgTokenizer) {
+ this.bgTokenizer = new BackgroundTokenizer(tokenizer);
+ var _self = this;
+ this.bgTokenizer.addEventListener("update", function(e) {
+ _self._signal("tokenizerUpdate", e);
+ });
+ } else {
+ this.bgTokenizer.setTokenizer(tokenizer);
+ }
+
+ this.bgTokenizer.setDocument(this.getDocument());
+
+ this.tokenRe = mode.tokenRe;
+ this.nonTokenRe = mode.nonTokenRe;
+
+
+ if (!$isPlaceholder) {
+ if (mode.attachToSession)
+ mode.attachToSession(this);
+ this.$options.wrapMethod.set.call(this, this.$wrapMethod);
+ this.$setFolding(mode.foldingRules);
+ this.bgTokenizer.start(0);
+ this._emit("changeMode");
+ }
+ };
+
+ this.$stopWorker = function() {
+ if (this.$worker) {
+ this.$worker.terminate();
+ this.$worker = null;
+ }
+ };
+
+ this.$startWorker = function() {
+ try {
+ this.$worker = this.$mode.createWorker(this);
+ } catch (e) {
+ config.warn("Could not load worker", e);
+ this.$worker = null;
+ }
+ };
+ this.getMode = function() {
+ return this.$mode;
+ };
+
+ this.$scrollTop = 0;
+ this.setScrollTop = function(scrollTop) {
+ if (this.$scrollTop === scrollTop || isNaN(scrollTop))
+ return;
+
+ this.$scrollTop = scrollTop;
+ this._signal("changeScrollTop", scrollTop);
+ };
+ this.getScrollTop = function() {
+ return this.$scrollTop;
+ };
+
+ this.$scrollLeft = 0;
+ this.setScrollLeft = function(scrollLeft) {
+ if (this.$scrollLeft === scrollLeft || isNaN(scrollLeft))
+ return;
+
+ this.$scrollLeft = scrollLeft;
+ this._signal("changeScrollLeft", scrollLeft);
+ };
+ this.getScrollLeft = function() {
+ return this.$scrollLeft;
+ };
+ this.getScreenWidth = function() {
+ this.$computeWidth();
+ if (this.lineWidgets)
+ return Math.max(this.getLineWidgetMaxWidth(), this.screenWidth);
+ return this.screenWidth;
+ };
+
+ this.getLineWidgetMaxWidth = function() {
+ if (this.lineWidgetsWidth != null) return this.lineWidgetsWidth;
+ var width = 0;
+ this.lineWidgets.forEach(function(w) {
+ if (w && w.screenWidth > width)
+ width = w.screenWidth;
+ });
+ return this.lineWidgetWidth = width;
+ };
+
+ this.$computeWidth = function(force) {
+ if (this.$modified || force) {
+ this.$modified = false;
+
+ if (this.$useWrapMode)
+ return this.screenWidth = this.$wrapLimit;
+
+ var lines = this.doc.getAllLines();
+ var cache = this.$rowLengthCache;
+ var longestScreenLine = 0;
+ var foldIndex = 0;
+ var foldLine = this.$foldData[foldIndex];
+ var foldStart = foldLine ? foldLine.start.row : Infinity;
+ var len = lines.length;
+
+ for (var i = 0; i < len; i++) {
+ if (i > foldStart) {
+ i = foldLine.end.row + 1;
+ if (i >= len)
+ break;
+ foldLine = this.$foldData[foldIndex++];
+ foldStart = foldLine ? foldLine.start.row : Infinity;
+ }
+
+ if (cache[i] == null)
+ cache[i] = this.$getStringScreenWidth(lines[i])[0];
+
+ if (cache[i] > longestScreenLine)
+ longestScreenLine = cache[i];
+ }
+ this.screenWidth = longestScreenLine;
+ }
+ };
+ this.getLine = function(row) {
+ return this.doc.getLine(row);
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.doc.getLines(firstRow, lastRow);
+ };
+ this.getLength = function() {
+ return this.doc.getLength();
+ };
+ this.getTextRange = function(range) {
+ return this.doc.getTextRange(range || this.selection.getRange());
+ };
+ this.insert = function(position, text) {
+ return this.doc.insert(position, text);
+ };
+ this.remove = function(range) {
+ return this.doc.remove(range);
+ };
+ this.removeFullLines = function(firstRow, lastRow){
+ return this.doc.removeFullLines(firstRow, lastRow);
+ };
+ this.undoChanges = function(deltas, dontSelect) {
+ if (!deltas.length)
+ return;
+
+ this.$fromUndo = true;
+ var lastUndoRange = null;
+ for (var i = deltas.length - 1; i != -1; i--) {
+ var delta = deltas[i];
+ if (delta.group == "doc") {
+ this.doc.revertDeltas(delta.deltas);
+ lastUndoRange =
+ this.$getUndoSelection(delta.deltas, true, lastUndoRange);
+ } else {
+ delta.deltas.forEach(function(foldDelta) {
+ this.addFolds(foldDelta.folds);
+ }, this);
+ }
+ }
+ this.$fromUndo = false;
+ lastUndoRange &&
+ this.$undoSelect &&
+ !dontSelect &&
+ this.selection.setSelectionRange(lastUndoRange);
+ return lastUndoRange;
+ };
+ this.redoChanges = function(deltas, dontSelect) {
+ if (!deltas.length)
+ return;
+
+ this.$fromUndo = true;
+ var lastUndoRange = null;
+ for (var i = 0; i < deltas.length; i++) {
+ var delta = deltas[i];
+ if (delta.group == "doc") {
+ this.doc.applyDeltas(delta.deltas);
+ lastUndoRange =
+ this.$getUndoSelection(delta.deltas, false, lastUndoRange);
+ }
+ }
+ this.$fromUndo = false;
+ lastUndoRange &&
+ this.$undoSelect &&
+ !dontSelect &&
+ this.selection.setSelectionRange(lastUndoRange);
+ return lastUndoRange;
+ };
+ this.setUndoSelect = function(enable) {
+ this.$undoSelect = enable;
+ };
+
+ this.$getUndoSelection = function(deltas, isUndo, lastUndoRange) {
+ function isInsert(delta) {
+ return isUndo ? delta.action !== "insert" : delta.action === "insert";
+ }
+
+ var delta = deltas[0];
+ var range, point;
+ var lastDeltaIsInsert = false;
+ if (isInsert(delta)) {
+ range = Range.fromPoints(delta.start, delta.end);
+ lastDeltaIsInsert = true;
+ } else {
+ range = Range.fromPoints(delta.start, delta.start);
+ lastDeltaIsInsert = false;
+ }
+
+ for (var i = 1; i < deltas.length; i++) {
+ delta = deltas[i];
+ if (isInsert(delta)) {
+ point = delta.start;
+ if (range.compare(point.row, point.column) == -1) {
+ range.setStart(point);
+ }
+ point = delta.end;
+ if (range.compare(point.row, point.column) == 1) {
+ range.setEnd(point);
+ }
+ lastDeltaIsInsert = true;
+ } else {
+ point = delta.start;
+ if (range.compare(point.row, point.column) == -1) {
+ range = Range.fromPoints(delta.start, delta.start);
+ }
+ lastDeltaIsInsert = false;
+ }
+ }
+ if (lastUndoRange != null) {
+ if (Range.comparePoints(lastUndoRange.start, range.start) === 0) {
+ lastUndoRange.start.column += range.end.column - range.start.column;
+ lastUndoRange.end.column += range.end.column - range.start.column;
+ }
+
+ var cmp = lastUndoRange.compareRange(range);
+ if (cmp == 1) {
+ range.setStart(lastUndoRange.start);
+ } else if (cmp == -1) {
+ range.setEnd(lastUndoRange.end);
+ }
+ }
+
+ return range;
+ };
+ this.replace = function(range, text) {
+ return this.doc.replace(range, text);
+ };
+ this.moveText = function(fromRange, toPosition, copy) {
+ var text = this.getTextRange(fromRange);
+ var folds = this.getFoldsInRange(fromRange);
+
+ var toRange = Range.fromPoints(toPosition, toPosition);
+ if (!copy) {
+ this.remove(fromRange);
+ var rowDiff = fromRange.start.row - fromRange.end.row;
+ var collDiff = rowDiff ? -fromRange.end.column : fromRange.start.column - fromRange.end.column;
+ if (collDiff) {
+ if (toRange.start.row == fromRange.end.row && toRange.start.column > fromRange.end.column)
+ toRange.start.column += collDiff;
+ if (toRange.end.row == fromRange.end.row && toRange.end.column > fromRange.end.column)
+ toRange.end.column += collDiff;
+ }
+ if (rowDiff && toRange.start.row >= fromRange.end.row) {
+ toRange.start.row += rowDiff;
+ toRange.end.row += rowDiff;
+ }
+ }
+
+ toRange.end = this.insert(toRange.start, text);
+ if (folds.length) {
+ var oldStart = fromRange.start;
+ var newStart = toRange.start;
+ var rowDiff = newStart.row - oldStart.row;
+ var collDiff = newStart.column - oldStart.column;
+ this.addFolds(folds.map(function(x) {
+ x = x.clone();
+ if (x.start.row == oldStart.row)
+ x.start.column += collDiff;
+ if (x.end.row == oldStart.row)
+ x.end.column += collDiff;
+ x.start.row += rowDiff;
+ x.end.row += rowDiff;
+ return x;
+ }));
+ }
+
+ return toRange;
+ };
+ this.indentRows = function(startRow, endRow, indentString) {
+ indentString = indentString.replace(/\t/g, this.getTabString());
+ for (var row=startRow; row<=endRow; row++)
+ this.doc.insertInLine({row: row, column: 0}, indentString);
+ };
+ this.outdentRows = function (range) {
+ var rowRange = range.collapseRows();
+ var deleteRange = new Range(0, 0, 0, 0);
+ var size = this.getTabSize();
+
+ for (var i = rowRange.start.row; i <= rowRange.end.row; ++i) {
+ var line = this.getLine(i);
+
+ deleteRange.start.row = i;
+ deleteRange.end.row = i;
+ for (var j = 0; j < size; ++j)
+ if (line.charAt(j) != ' ')
+ break;
+ if (j < size && line.charAt(j) == '\t') {
+ deleteRange.start.column = j;
+ deleteRange.end.column = j + 1;
+ } else {
+ deleteRange.start.column = 0;
+ deleteRange.end.column = j;
+ }
+ this.remove(deleteRange);
+ }
+ };
+
+ this.$moveLines = function(firstRow, lastRow, dir) {
+ firstRow = this.getRowFoldStart(firstRow);
+ lastRow = this.getRowFoldEnd(lastRow);
+ if (dir < 0) {
+ var row = this.getRowFoldStart(firstRow + dir);
+ if (row < 0) return 0;
+ var diff = row-firstRow;
+ } else if (dir > 0) {
+ var row = this.getRowFoldEnd(lastRow + dir);
+ if (row > this.doc.getLength()-1) return 0;
+ var diff = row-lastRow;
+ } else {
+ firstRow = this.$clipRowToDocument(firstRow);
+ lastRow = this.$clipRowToDocument(lastRow);
+ var diff = lastRow - firstRow + 1;
+ }
+
+ var range = new Range(firstRow, 0, lastRow, Number.MAX_VALUE);
+ var folds = this.getFoldsInRange(range).map(function(x){
+ x = x.clone();
+ x.start.row += diff;
+ x.end.row += diff;
+ return x;
+ });
+
+ var lines = dir == 0
+ ? this.doc.getLines(firstRow, lastRow)
+ : this.doc.removeFullLines(firstRow, lastRow);
+ this.doc.insertFullLines(firstRow+diff, lines);
+ folds.length && this.addFolds(folds);
+ return diff;
+ };
+ this.moveLinesUp = function(firstRow, lastRow) {
+ return this.$moveLines(firstRow, lastRow, -1);
+ };
+ this.moveLinesDown = function(firstRow, lastRow) {
+ return this.$moveLines(firstRow, lastRow, 1);
+ };
+ this.duplicateLines = function(firstRow, lastRow) {
+ return this.$moveLines(firstRow, lastRow, 0);
+ };
+
+
+ this.$clipRowToDocument = function(row) {
+ return Math.max(0, Math.min(row, this.doc.getLength()-1));
+ };
+
+ this.$clipColumnToRow = function(row, column) {
+ if (column < 0)
+ return 0;
+ return Math.min(this.doc.getLine(row).length, column);
+ };
+
+
+ this.$clipPositionToDocument = function(row, column) {
+ column = Math.max(0, column);
+
+ if (row < 0) {
+ row = 0;
+ column = 0;
+ } else {
+ var len = this.doc.getLength();
+ if (row >= len) {
+ row = len - 1;
+ column = this.doc.getLine(len-1).length;
+ } else {
+ column = Math.min(this.doc.getLine(row).length, column);
+ }
+ }
+
+ return {
+ row: row,
+ column: column
+ };
+ };
+
+ this.$clipRangeToDocument = function(range) {
+ if (range.start.row < 0) {
+ range.start.row = 0;
+ range.start.column = 0;
+ } else {
+ range.start.column = this.$clipColumnToRow(
+ range.start.row,
+ range.start.column
+ );
+ }
+
+ var len = this.doc.getLength() - 1;
+ if (range.end.row > len) {
+ range.end.row = len;
+ range.end.column = this.doc.getLine(len).length;
+ } else {
+ range.end.column = this.$clipColumnToRow(
+ range.end.row,
+ range.end.column
+ );
+ }
+ return range;
+ };
+ this.$wrapLimit = 80;
+ this.$useWrapMode = false;
+ this.$wrapLimitRange = {
+ min : null,
+ max : null
+ };
+ this.setUseWrapMode = function(useWrapMode) {
+ if (useWrapMode != this.$useWrapMode) {
+ this.$useWrapMode = useWrapMode;
+ this.$modified = true;
+ this.$resetRowCache(0);
+ if (useWrapMode) {
+ var len = this.getLength();
+ this.$wrapData = Array(len);
+ this.$updateWrapData(0, len - 1);
+ }
+
+ this._signal("changeWrapMode");
+ }
+ };
+ this.getUseWrapMode = function() {
+ return this.$useWrapMode;
+ };
+ this.setWrapLimitRange = function(min, max) {
+ if (this.$wrapLimitRange.min !== min || this.$wrapLimitRange.max !== max) {
+ this.$wrapLimitRange = { min: min, max: max };
+ this.$modified = true;
+ this.$bidiHandler.markAsDirty();
+ if (this.$useWrapMode)
+ this._signal("changeWrapMode");
+ }
+ };
+ this.adjustWrapLimit = function(desiredLimit, $printMargin) {
+ var limits = this.$wrapLimitRange;
+ if (limits.max < 0)
+ limits = {min: $printMargin, max: $printMargin};
+ var wrapLimit = this.$constrainWrapLimit(desiredLimit, limits.min, limits.max);
+ if (wrapLimit != this.$wrapLimit && wrapLimit > 1) {
+ this.$wrapLimit = wrapLimit;
+ this.$modified = true;
+ if (this.$useWrapMode) {
+ this.$updateWrapData(0, this.getLength() - 1);
+ this.$resetRowCache(0);
+ this._signal("changeWrapLimit");
+ }
+ return true;
+ }
+ return false;
+ };
+
+ this.$constrainWrapLimit = function(wrapLimit, min, max) {
+ if (min)
+ wrapLimit = Math.max(min, wrapLimit);
+
+ if (max)
+ wrapLimit = Math.min(max, wrapLimit);
+
+ return wrapLimit;
+ };
+ this.getWrapLimit = function() {
+ return this.$wrapLimit;
+ };
+ this.setWrapLimit = function (limit) {
+ this.setWrapLimitRange(limit, limit);
+ };
+ this.getWrapLimitRange = function() {
+ return {
+ min : this.$wrapLimitRange.min,
+ max : this.$wrapLimitRange.max
+ };
+ };
+
+ this.$updateInternalDataOnChange = function(delta) {
+ var useWrapMode = this.$useWrapMode;
+ var action = delta.action;
+ var start = delta.start;
+ var end = delta.end;
+ var firstRow = start.row;
+ var lastRow = end.row;
+ var len = lastRow - firstRow;
+ var removedFolds = null;
+
+ this.$updating = true;
+ if (len != 0) {
+ if (action === "remove") {
+ this[useWrapMode ? "$wrapData" : "$rowLengthCache"].splice(firstRow, len);
+
+ var foldLines = this.$foldData;
+ removedFolds = this.getFoldsInRange(delta);
+ this.removeFolds(removedFolds);
+
+ var foldLine = this.getFoldLine(end.row);
+ var idx = 0;
+ if (foldLine) {
+ foldLine.addRemoveChars(end.row, end.column, start.column - end.column);
+ foldLine.shiftRow(-len);
+
+ var foldLineBefore = this.getFoldLine(firstRow);
+ if (foldLineBefore && foldLineBefore !== foldLine) {
+ foldLineBefore.merge(foldLine);
+ foldLine = foldLineBefore;
+ }
+ idx = foldLines.indexOf(foldLine) + 1;
+ }
+
+ for (idx; idx < foldLines.length; idx++) {
+ var foldLine = foldLines[idx];
+ if (foldLine.start.row >= end.row) {
+ foldLine.shiftRow(-len);
+ }
+ }
+
+ lastRow = firstRow;
+ } else {
+ var args = Array(len);
+ args.unshift(firstRow, 0);
+ var arr = useWrapMode ? this.$wrapData : this.$rowLengthCache
+ arr.splice.apply(arr, args);
+ var foldLines = this.$foldData;
+ var foldLine = this.getFoldLine(firstRow);
+ var idx = 0;
+ if (foldLine) {
+ var cmp = foldLine.range.compareInside(start.row, start.column);
+ if (cmp == 0) {
+ foldLine = foldLine.split(start.row, start.column);
+ if (foldLine) {
+ foldLine.shiftRow(len);
+ foldLine.addRemoveChars(lastRow, 0, end.column - start.column);
+ }
+ } else
+ if (cmp == -1) {
+ foldLine.addRemoveChars(firstRow, 0, end.column - start.column);
+ foldLine.shiftRow(len);
+ }
+ idx = foldLines.indexOf(foldLine) + 1;
+ }
+
+ for (idx; idx < foldLines.length; idx++) {
+ var foldLine = foldLines[idx];
+ if (foldLine.start.row >= firstRow) {
+ foldLine.shiftRow(len);
+ }
+ }
+ }
+ } else {
+ len = Math.abs(delta.start.column - delta.end.column);
+ if (action === "remove") {
+ removedFolds = this.getFoldsInRange(delta);
+ this.removeFolds(removedFolds);
+
+ len = -len;
+ }
+ var foldLine = this.getFoldLine(firstRow);
+ if (foldLine) {
+ foldLine.addRemoveChars(firstRow, start.column, len);
+ }
+ }
+
+ if (useWrapMode && this.$wrapData.length != this.doc.getLength()) {
+ console.error("doc.getLength() and $wrapData.length have to be the same!");
+ }
+ this.$updating = false;
+
+ if (useWrapMode)
+ this.$updateWrapData(firstRow, lastRow);
+ else
+ this.$updateRowLengthCache(firstRow, lastRow);
+
+ return removedFolds;
+ };
+
+ this.$updateRowLengthCache = function(firstRow, lastRow, b) {
+ this.$rowLengthCache[firstRow] = null;
+ this.$rowLengthCache[lastRow] = null;
+ };
+
+ this.$updateWrapData = function(firstRow, lastRow) {
+ var lines = this.doc.getAllLines();
+ var tabSize = this.getTabSize();
+ var wrapData = this.$wrapData;
+ var wrapLimit = this.$wrapLimit;
+ var tokens;
+ var foldLine;
+
+ var row = firstRow;
+ lastRow = Math.min(lastRow, lines.length - 1);
+ while (row <= lastRow) {
+ foldLine = this.getFoldLine(row, foldLine);
+ if (!foldLine) {
+ tokens = this.$getDisplayTokens(lines[row]);
+ wrapData[row] = this.$computeWrapSplits(tokens, wrapLimit, tabSize);
+ row ++;
+ } else {
+ tokens = [];
+ foldLine.walk(function(placeholder, row, column, lastColumn) {
+ var walkTokens;
+ if (placeholder != null) {
+ walkTokens = this.$getDisplayTokens(
+ placeholder, tokens.length);
+ walkTokens[0] = PLACEHOLDER_START;
+ for (var i = 1; i < walkTokens.length; i++) {
+ walkTokens[i] = PLACEHOLDER_BODY;
+ }
+ } else {
+ walkTokens = this.$getDisplayTokens(
+ lines[row].substring(lastColumn, column),
+ tokens.length);
+ }
+ tokens = tokens.concat(walkTokens);
+ }.bind(this),
+ foldLine.end.row,
+ lines[foldLine.end.row].length + 1
+ );
+
+ wrapData[foldLine.start.row] = this.$computeWrapSplits(tokens, wrapLimit, tabSize);
+ row = foldLine.end.row + 1;
+ }
+ }
+ };
+ var CHAR = 1,
+ CHAR_EXT = 2,
+ PLACEHOLDER_START = 3,
+ PLACEHOLDER_BODY = 4,
+ PUNCTUATION = 9,
+ SPACE = 10,
+ TAB = 11,
+ TAB_SPACE = 12;
+
+
+ this.$computeWrapSplits = function(tokens, wrapLimit, tabSize) {
+ if (tokens.length == 0) {
+ return [];
+ }
+
+ var splits = [];
+ var displayLength = tokens.length;
+ var lastSplit = 0, lastDocSplit = 0;
+
+ var isCode = this.$wrapAsCode;
+
+ var indentedSoftWrap = this.$indentedSoftWrap;
+ var maxIndent = wrapLimit <= Math.max(2 * tabSize, 8)
+ || indentedSoftWrap === false ? 0 : Math.floor(wrapLimit / 2);
+
+ function getWrapIndent() {
+ var indentation = 0;
+ if (maxIndent === 0)
+ return indentation;
+ if (indentedSoftWrap) {
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (token == SPACE)
+ indentation += 1;
+ else if (token == TAB)
+ indentation += tabSize;
+ else if (token == TAB_SPACE)
+ continue;
+ else
+ break;
+ }
+ }
+ if (isCode && indentedSoftWrap !== false)
+ indentation += tabSize;
+ return Math.min(indentation, maxIndent);
+ }
+ function addSplit(screenPos) {
+ var displayed = tokens.slice(lastSplit, screenPos);
+ var len = displayed.length;
+ displayed.join("")
+ .replace(/12/g, function() {
+ len -= 1;
+ })
+ .replace(/2/g, function() {
+ len -= 1;
+ });
+
+ if (!splits.length) {
+ indent = getWrapIndent();
+ splits.indent = indent;
+ }
+ lastDocSplit += len;
+ splits.push(lastDocSplit);
+ lastSplit = screenPos;
+ }
+ var indent = 0;
+ while (displayLength - lastSplit > wrapLimit - indent) {
+ var split = lastSplit + wrapLimit - indent;
+ if (tokens[split - 1] >= SPACE && tokens[split] >= SPACE) {
+ addSplit(split);
+ continue;
+ }
+ if (tokens[split] == PLACEHOLDER_START || tokens[split] == PLACEHOLDER_BODY) {
+ for (split; split != lastSplit - 1; split--) {
+ if (tokens[split] == PLACEHOLDER_START) {
+ break;
+ }
+ }
+ if (split > lastSplit) {
+ addSplit(split);
+ continue;
+ }
+ split = lastSplit + wrapLimit;
+ for (split; split < tokens.length; split++) {
+ if (tokens[split] != PLACEHOLDER_BODY) {
+ break;
+ }
+ }
+ if (split == tokens.length) {
+ break; // Breaks the while-loop.
+ }
+ addSplit(split);
+ continue;
+ }
+ var minSplit = Math.max(split - (wrapLimit -(wrapLimit>>2)), lastSplit - 1);
+ while (split > minSplit && tokens[split] < PLACEHOLDER_START) {
+ split --;
+ }
+ if (isCode) {
+ while (split > minSplit && tokens[split] < PLACEHOLDER_START) {
+ split --;
+ }
+ while (split > minSplit && tokens[split] == PUNCTUATION) {
+ split --;
+ }
+ } else {
+ while (split > minSplit && tokens[split] < SPACE) {
+ split --;
+ }
+ }
+ if (split > minSplit) {
+ addSplit(++split);
+ continue;
+ }
+ split = lastSplit + wrapLimit;
+ if (tokens[split] == CHAR_EXT)
+ split--;
+ addSplit(split - indent);
+ }
+ return splits;
+ };
+ this.$getDisplayTokens = function(str, offset) {
+ var arr = [];
+ var tabSize;
+ offset = offset || 0;
+
+ for (var i = 0; i < str.length; i++) {
+ var c = str.charCodeAt(i);
+ if (c == 9) {
+ tabSize = this.getScreenTabSize(arr.length + offset);
+ arr.push(TAB);
+ for (var n = 1; n < tabSize; n++) {
+ arr.push(TAB_SPACE);
+ }
+ }
+ else if (c == 32) {
+ arr.push(SPACE);
+ } else if((c > 39 && c < 48) || (c > 57 && c < 64)) {
+ arr.push(PUNCTUATION);
+ }
+ else if (c >= 0x1100 && isFullWidth(c)) {
+ arr.push(CHAR, CHAR_EXT);
+ } else {
+ arr.push(CHAR);
+ }
+ }
+ return arr;
+ };
+ this.$getStringScreenWidth = function(str, maxScreenColumn, screenColumn) {
+ if (maxScreenColumn == 0)
+ return [0, 0];
+ if (maxScreenColumn == null)
+ maxScreenColumn = Infinity;
+ screenColumn = screenColumn || 0;
+
+ var c, column;
+ for (column = 0; column < str.length; column++) {
+ c = str.charCodeAt(column);
+ if (c == 9) {
+ screenColumn += this.getScreenTabSize(screenColumn);
+ }
+ else if (c >= 0x1100 && isFullWidth(c)) {
+ screenColumn += 2;
+ } else {
+ screenColumn += 1;
+ }
+ if (screenColumn > maxScreenColumn) {
+ break;
+ }
+ }
+
+ return [screenColumn, column];
+ };
+
+ this.lineWidgets = null;
+ this.getRowLength = function(row) {
+ if (this.lineWidgets)
+ var h = this.lineWidgets[row] && this.lineWidgets[row].rowCount || 0;
+ else
+ h = 0
+ if (!this.$useWrapMode || !this.$wrapData[row]) {
+ return 1 + h;
+ } else {
+ return this.$wrapData[row].length + 1 + h;
+ }
+ };
+ this.getRowLineCount = function(row) {
+ if (!this.$useWrapMode || !this.$wrapData[row]) {
+ return 1;
+ } else {
+ return this.$wrapData[row].length + 1;
+ }
+ };
+
+ this.getRowWrapIndent = function(screenRow) {
+ if (this.$useWrapMode) {
+ var pos = this.screenToDocumentPosition(screenRow, Number.MAX_VALUE);
+ var splits = this.$wrapData[pos.row];
+ return splits.length && splits[0] < pos.column ? splits.indent : 0;
+ } else {
+ return 0;
+ }
+ }
+ this.getScreenLastRowColumn = function(screenRow) {
+ var pos = this.screenToDocumentPosition(screenRow, Number.MAX_VALUE);
+ return this.documentToScreenColumn(pos.row, pos.column);
+ };
+ this.getDocumentLastRowColumn = function(docRow, docColumn) {
+ var screenRow = this.documentToScreenRow(docRow, docColumn);
+ return this.getScreenLastRowColumn(screenRow);
+ };
+ this.getDocumentLastRowColumnPosition = function(docRow, docColumn) {
+ var screenRow = this.documentToScreenRow(docRow, docColumn);
+ return this.screenToDocumentPosition(screenRow, Number.MAX_VALUE / 10);
+ };
+ this.getRowSplitData = function(row) {
+ if (!this.$useWrapMode) {
+ return undefined;
+ } else {
+ return this.$wrapData[row];
+ }
+ };
+ this.getScreenTabSize = function(screenColumn) {
+ return this.$tabSize - screenColumn % this.$tabSize;
+ };
+
+
+ this.screenToDocumentRow = function(screenRow, screenColumn) {
+ return this.screenToDocumentPosition(screenRow, screenColumn).row;
+ };
+
+
+ this.screenToDocumentColumn = function(screenRow, screenColumn) {
+ return this.screenToDocumentPosition(screenRow, screenColumn).column;
+ };
+ this.screenToDocumentPosition = function(screenRow, screenColumn, offsetX) {
+ if (screenRow < 0)
+ return {row: 0, column: 0};
+
+ var line;
+ var docRow = 0;
+ var docColumn = 0;
+ var column;
+ var row = 0;
+ var rowLength = 0;
+
+ var rowCache = this.$screenRowCache;
+ var i = this.$getRowCacheIndex(rowCache, screenRow);
+ var l = rowCache.length;
+ if (l && i >= 0) {
+ var row = rowCache[i];
+ var docRow = this.$docRowCache[i];
+ var doCache = screenRow > rowCache[l - 1];
+ } else {
+ var doCache = !l;
+ }
+
+ var maxRow = this.getLength() - 1;
+ var foldLine = this.getNextFoldLine(docRow);
+ var foldStart = foldLine ? foldLine.start.row : Infinity;
+
+ while (row <= screenRow) {
+ rowLength = this.getRowLength(docRow);
+ if (row + rowLength > screenRow || docRow >= maxRow) {
+ break;
+ } else {
+ row += rowLength;
+ docRow++;
+ if (docRow > foldStart) {
+ docRow = foldLine.end.row+1;
+ foldLine = this.getNextFoldLine(docRow, foldLine);
+ foldStart = foldLine ? foldLine.start.row : Infinity;
+ }
+ }
+
+ if (doCache) {
+ this.$docRowCache.push(docRow);
+ this.$screenRowCache.push(row);
+ }
+ }
+
+ if (foldLine && foldLine.start.row <= docRow) {
+ line = this.getFoldDisplayLine(foldLine);
+ docRow = foldLine.start.row;
+ } else if (row + rowLength <= screenRow || docRow > maxRow) {
+ return {
+ row: maxRow,
+ column: this.getLine(maxRow).length
+ };
+ } else {
+ line = this.getLine(docRow);
+ foldLine = null;
+ }
+ var wrapIndent = 0, splitIndex = Math.floor(screenRow - row);
+ if (this.$useWrapMode) {
+ var splits = this.$wrapData[docRow];
+ if (splits) {
+ column = splits[splitIndex];
+ if(splitIndex > 0 && splits.length) {
+ wrapIndent = splits.indent;
+ docColumn = splits[splitIndex - 1] || splits[splits.length - 1];
+ line = line.substring(docColumn);
+ }
+ }
+ }
+
+ if (offsetX !== undefined && this.$bidiHandler.isBidiRow(row + splitIndex, docRow, splitIndex))
+ screenColumn = this.$bidiHandler.offsetToCol(offsetX);
+
+ docColumn += this.$getStringScreenWidth(line, screenColumn - wrapIndent)[1];
+ if (this.$useWrapMode && docColumn >= column)
+ docColumn = column - 1;
+
+ if (foldLine)
+ return foldLine.idxToPosition(docColumn);
+
+ return {row: docRow, column: docColumn};
+ };
+ this.documentToScreenPosition = function(docRow, docColumn) {
+ if (typeof docColumn === "undefined")
+ var pos = this.$clipPositionToDocument(docRow.row, docRow.column);
+ else
+ pos = this.$clipPositionToDocument(docRow, docColumn);
+
+ docRow = pos.row;
+ docColumn = pos.column;
+
+ var screenRow = 0;
+ var foldStartRow = null;
+ var fold = null;
+ fold = this.getFoldAt(docRow, docColumn, 1);
+ if (fold) {
+ docRow = fold.start.row;
+ docColumn = fold.start.column;
+ }
+
+ var rowEnd, row = 0;
+
+
+ var rowCache = this.$docRowCache;
+ var i = this.$getRowCacheIndex(rowCache, docRow);
+ var l = rowCache.length;
+ if (l && i >= 0) {
+ var row = rowCache[i];
+ var screenRow = this.$screenRowCache[i];
+ var doCache = docRow > rowCache[l - 1];
+ } else {
+ var doCache = !l;
+ }
+
+ var foldLine = this.getNextFoldLine(row);
+ var foldStart = foldLine ?foldLine.start.row :Infinity;
+
+ while (row < docRow) {
+ if (row >= foldStart) {
+ rowEnd = foldLine.end.row + 1;
+ if (rowEnd > docRow)
+ break;
+ foldLine = this.getNextFoldLine(rowEnd, foldLine);
+ foldStart = foldLine ?foldLine.start.row :Infinity;
+ }
+ else {
+ rowEnd = row + 1;
+ }
+
+ screenRow += this.getRowLength(row);
+ row = rowEnd;
+
+ if (doCache) {
+ this.$docRowCache.push(row);
+ this.$screenRowCache.push(screenRow);
+ }
+ }
+ var textLine = "";
+ if (foldLine && row >= foldStart) {
+ textLine = this.getFoldDisplayLine(foldLine, docRow, docColumn);
+ foldStartRow = foldLine.start.row;
+ } else {
+ textLine = this.getLine(docRow).substring(0, docColumn);
+ foldStartRow = docRow;
+ }
+ var wrapIndent = 0;
+ if (this.$useWrapMode) {
+ var wrapRow = this.$wrapData[foldStartRow];
+ if (wrapRow) {
+ var screenRowOffset = 0;
+ while (textLine.length >= wrapRow[screenRowOffset]) {
+ screenRow ++;
+ screenRowOffset++;
+ }
+ textLine = textLine.substring(
+ wrapRow[screenRowOffset - 1] || 0, textLine.length
+ );
+ wrapIndent = screenRowOffset > 0 ? wrapRow.indent : 0;
+ }
+ }
+
+ return {
+ row: screenRow,
+ column: wrapIndent + this.$getStringScreenWidth(textLine)[0]
+ };
+ };
+ this.documentToScreenColumn = function(row, docColumn) {
+ return this.documentToScreenPosition(row, docColumn).column;
+ };
+ this.documentToScreenRow = function(docRow, docColumn) {
+ return this.documentToScreenPosition(docRow, docColumn).row;
+ };
+ this.getScreenLength = function() {
+ var screenRows = 0;
+ var fold = null;
+ if (!this.$useWrapMode) {
+ screenRows = this.getLength();
+ var foldData = this.$foldData;
+ for (var i = 0; i < foldData.length; i++) {
+ fold = foldData[i];
+ screenRows -= fold.end.row - fold.start.row;
+ }
+ } else {
+ var lastRow = this.$wrapData.length;
+ var row = 0, i = 0;
+ var fold = this.$foldData[i++];
+ var foldStart = fold ? fold.start.row :Infinity;
+
+ while (row < lastRow) {
+ var splits = this.$wrapData[row];
+ screenRows += splits ? splits.length + 1 : 1;
+ row ++;
+ if (row > foldStart) {
+ row = fold.end.row+1;
+ fold = this.$foldData[i++];
+ foldStart = fold ?fold.start.row :Infinity;
+ }
+ }
+ }
+ if (this.lineWidgets)
+ screenRows += this.$getWidgetScreenLength();
+
+ return screenRows;
+ };
+ this.$setFontMetrics = function(fm) {
+ if (!this.$enableVarChar) return;
+ this.$getStringScreenWidth = function(str, maxScreenColumn, screenColumn) {
+ if (maxScreenColumn === 0)
+ return [0, 0];
+ if (!maxScreenColumn)
+ maxScreenColumn = Infinity;
+ screenColumn = screenColumn || 0;
+
+ var c, column;
+ for (column = 0; column < str.length; column++) {
+ c = str.charAt(column);
+ if (c === "\t") {
+ screenColumn += this.getScreenTabSize(screenColumn);
+ } else {
+ screenColumn += fm.getCharacterWidth(c);
+ }
+ if (screenColumn > maxScreenColumn) {
+ break;
+ }
+ }
+
+ return [screenColumn, column];
+ };
+ };
+
+ this.destroy = function() {
+ if (this.bgTokenizer) {
+ this.bgTokenizer.setDocument(null);
+ this.bgTokenizer = null;
+ }
+ this.$stopWorker();
+ };
+
+ this.isFullWidth = isFullWidth;
+ function isFullWidth(c) {
+ if (c < 0x1100)
+ return false;
+ return c >= 0x1100 && c <= 0x115F ||
+ c >= 0x11A3 && c <= 0x11A7 ||
+ c >= 0x11FA && c <= 0x11FF ||
+ c >= 0x2329 && c <= 0x232A ||
+ c >= 0x2E80 && c <= 0x2E99 ||
+ c >= 0x2E9B && c <= 0x2EF3 ||
+ c >= 0x2F00 && c <= 0x2FD5 ||
+ c >= 0x2FF0 && c <= 0x2FFB ||
+ c >= 0x3000 && c <= 0x303E ||
+ c >= 0x3041 && c <= 0x3096 ||
+ c >= 0x3099 && c <= 0x30FF ||
+ c >= 0x3105 && c <= 0x312D ||
+ c >= 0x3131 && c <= 0x318E ||
+ c >= 0x3190 && c <= 0x31BA ||
+ c >= 0x31C0 && c <= 0x31E3 ||
+ c >= 0x31F0 && c <= 0x321E ||
+ c >= 0x3220 && c <= 0x3247 ||
+ c >= 0x3250 && c <= 0x32FE ||
+ c >= 0x3300 && c <= 0x4DBF ||
+ c >= 0x4E00 && c <= 0xA48C ||
+ c >= 0xA490 && c <= 0xA4C6 ||
+ c >= 0xA960 && c <= 0xA97C ||
+ c >= 0xAC00 && c <= 0xD7A3 ||
+ c >= 0xD7B0 && c <= 0xD7C6 ||
+ c >= 0xD7CB && c <= 0xD7FB ||
+ c >= 0xF900 && c <= 0xFAFF ||
+ c >= 0xFE10 && c <= 0xFE19 ||
+ c >= 0xFE30 && c <= 0xFE52 ||
+ c >= 0xFE54 && c <= 0xFE66 ||
+ c >= 0xFE68 && c <= 0xFE6B ||
+ c >= 0xFF01 && c <= 0xFF60 ||
+ c >= 0xFFE0 && c <= 0xFFE6;
+ }
+
+}).call(EditSession.prototype);
+
+require("./edit_session/folding").Folding.call(EditSession.prototype);
+require("./edit_session/bracket_match").BracketMatch.call(EditSession.prototype);
+
+
+config.defineOptions(EditSession.prototype, "session", {
+ wrap: {
+ set: function(value) {
+ if (!value || value == "off")
+ value = false;
+ else if (value == "free")
+ value = true;
+ else if (value == "printMargin")
+ value = -1;
+ else if (typeof value == "string")
+ value = parseInt(value, 10) || false;
+
+ if (this.$wrap == value)
+ return;
+ this.$wrap = value;
+ if (!value) {
+ this.setUseWrapMode(false);
+ } else {
+ var col = typeof value == "number" ? value : null;
+ this.setWrapLimitRange(col, col);
+ this.setUseWrapMode(true);
+ }
+ },
+ get: function() {
+ if (this.getUseWrapMode()) {
+ if (this.$wrap == -1)
+ return "printMargin";
+ if (!this.getWrapLimitRange().min)
+ return "free";
+ return this.$wrap;
+ }
+ return "off";
+ },
+ handlesSet: true
+ },
+ wrapMethod: {
+ set: function(val) {
+ val = val == "auto"
+ ? this.$mode.type != "text"
+ : val != "text";
+ if (val != this.$wrapAsCode) {
+ this.$wrapAsCode = val;
+ if (this.$useWrapMode) {
+ this.$modified = true;
+ this.$resetRowCache(0);
+ this.$updateWrapData(0, this.getLength() - 1);
+ }
+ }
+ },
+ initialValue: "auto"
+ },
+ indentedSoftWrap: { initialValue: true },
+ firstLineNumber: {
+ set: function() {this._signal("changeBreakpoint");},
+ initialValue: 1
+ },
+ useWorker: {
+ set: function(useWorker) {
+ this.$useWorker = useWorker;
+
+ this.$stopWorker();
+ if (useWorker)
+ this.$startWorker();
+ },
+ initialValue: true
+ },
+ useSoftTabs: {initialValue: true},
+ tabSize: {
+ set: function(tabSize) {
+ if (isNaN(tabSize) || this.$tabSize === tabSize) return;
+
+ this.$modified = true;
+ this.$rowLengthCache = [];
+ this.$tabSize = tabSize;
+ this._signal("changeTabSize");
+ },
+ initialValue: 4,
+ handlesSet: true
+ },
+ navigateWithinSoftTabs: {initialValue: false},
+ overwrite: {
+ set: function(val) {this._signal("changeOverwrite");},
+ initialValue: false
+ },
+ newLineMode: {
+ set: function(val) {this.doc.setNewLineMode(val)},
+ get: function() {return this.doc.getNewLineMode()},
+ handlesSet: true
+ },
+ mode: {
+ set: function(val) { this.setMode(val) },
+ get: function() { return this.$modeId }
+ }
+});
+
+exports.EditSession = EditSession;
+});
+
+ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"], function(require, exports, module) {
+"use strict";
+
+var lang = require("./lib/lang");
+var oop = require("./lib/oop");
+var Range = require("./range").Range;
+
+var Search = function() {
+ this.$options = {};
+};
+
+(function() {
+ this.set = function(options) {
+ oop.mixin(this.$options, options);
+ return this;
+ };
+ this.getOptions = function() {
+ return lang.copyObject(this.$options);
+ };
+ this.setOptions = function(options) {
+ this.$options = options;
+ };
+ this.find = function(session) {
+ var options = this.$options;
+ var iterator = this.$matchIterator(session, options);
+ if (!iterator)
+ return false;
+
+ var firstRange = null;
+ iterator.forEach(function(sr, sc, er, ec) {
+ firstRange = new Range(sr, sc, er, ec);
+ if (sc == ec && options.start && options.start.start
+ && options.skipCurrent != false && firstRange.isEqual(options.start)
+ ) {
+ firstRange = null;
+ return false;
+ }
+
+ return true;
+ });
+
+ return firstRange;
+ };
+ this.findAll = function(session) {
+ var options = this.$options;
+ if (!options.needle)
+ return [];
+ this.$assembleRegExp(options);
+
+ var range = options.range;
+ var lines = range
+ ? session.getLines(range.start.row, range.end.row)
+ : session.doc.getAllLines();
+
+ var ranges = [];
+ var re = options.re;
+ if (options.$isMultiLine) {
+ var len = re.length;
+ var maxRow = lines.length - len;
+ var prevRange;
+ outer: for (var row = re.offset || 0; row <= maxRow; row++) {
+ for (var j = 0; j < len; j++)
+ if (lines[row + j].search(re[j]) == -1)
+ continue outer;
+
+ var startLine = lines[row];
+ var line = lines[row + len - 1];
+ var startIndex = startLine.length - startLine.match(re[0])[0].length;
+ var endIndex = line.match(re[len - 1])[0].length;
+
+ if (prevRange && prevRange.end.row === row &&
+ prevRange.end.column > startIndex
+ ) {
+ continue;
+ }
+ ranges.push(prevRange = new Range(
+ row, startIndex, row + len - 1, endIndex
+ ));
+ if (len > 2)
+ row = row + len - 2;
+ }
+ } else {
+ for (var i = 0; i < lines.length; i++) {
+ var matches = lang.getMatchOffsets(lines[i], re);
+ for (var j = 0; j < matches.length; j++) {
+ var match = matches[j];
+ ranges.push(new Range(i, match.offset, i, match.offset + match.length));
+ }
+ }
+ }
+
+ if (range) {
+ var startColumn = range.start.column;
+ var endColumn = range.start.column;
+ var i = 0, j = ranges.length - 1;
+ while (i < j && ranges[i].start.column < startColumn && ranges[i].start.row == range.start.row)
+ i++;
+
+ while (i < j && ranges[j].end.column > endColumn && ranges[j].end.row == range.end.row)
+ j--;
+
+ ranges = ranges.slice(i, j + 1);
+ for (i = 0, j = ranges.length; i < j; i++) {
+ ranges[i].start.row += range.start.row;
+ ranges[i].end.row += range.start.row;
+ }
+ }
+
+ return ranges;
+ };
+ this.replace = function(input, replacement) {
+ var options = this.$options;
+
+ var re = this.$assembleRegExp(options);
+ if (options.$isMultiLine)
+ return replacement;
+
+ if (!re)
+ return;
+
+ var match = re.exec(input);
+ if (!match || match[0].length != input.length)
+ return null;
+
+ replacement = input.replace(re, replacement);
+ if (options.preserveCase) {
+ replacement = replacement.split("");
+ for (var i = Math.min(input.length, input.length); i--; ) {
+ var ch = input[i];
+ if (ch && ch.toLowerCase() != ch)
+ replacement[i] = replacement[i].toUpperCase();
+ else
+ replacement[i] = replacement[i].toLowerCase();
+ }
+ replacement = replacement.join("");
+ }
+
+ return replacement;
+ };
+
+ this.$assembleRegExp = function(options, $disableFakeMultiline) {
+ if (options.needle instanceof RegExp)
+ return options.re = options.needle;
+
+ var needle = options.needle;
+
+ if (!options.needle)
+ return options.re = false;
+
+ if (!options.regExp)
+ needle = lang.escapeRegExp(needle);
+
+ if (options.wholeWord)
+ needle = addWordBoundary(needle, options);
+
+ var modifier = options.caseSensitive ? "gm" : "gmi";
+
+ options.$isMultiLine = !$disableFakeMultiline && /[\n\r]/.test(needle);
+ if (options.$isMultiLine)
+ return options.re = this.$assembleMultilineRegExp(needle, modifier);
+
+ try {
+ var re = new RegExp(needle, modifier);
+ } catch(e) {
+ re = false;
+ }
+ return options.re = re;
+ };
+
+ this.$assembleMultilineRegExp = function(needle, modifier) {
+ var parts = needle.replace(/\r\n|\r|\n/g, "$\n^").split("\n");
+ var re = [];
+ for (var i = 0; i < parts.length; i++) try {
+ re.push(new RegExp(parts[i], modifier));
+ } catch(e) {
+ return false;
+ }
+ return re;
+ };
+
+ this.$matchIterator = function(session, options) {
+ var re = this.$assembleRegExp(options);
+ if (!re)
+ return false;
+ var backwards = options.backwards == true;
+ var skipCurrent = options.skipCurrent != false;
+
+ var range = options.range;
+ var start = options.start;
+ if (!start)
+ start = range ? range[backwards ? "end" : "start"] : session.selection.getRange();
+
+ if (start.start)
+ start = start[skipCurrent != backwards ? "end" : "start"];
+
+ var firstRow = range ? range.start.row : 0;
+ var lastRow = range ? range.end.row : session.getLength() - 1;
+
+ if (backwards) {
+ var forEach = function(callback) {
+ var row = start.row;
+ if (forEachInLine(row, start.column, callback))
+ return;
+ for (row--; row >= firstRow; row--)
+ if (forEachInLine(row, Number.MAX_VALUE, callback))
+ return;
+ if (options.wrap == false)
+ return;
+ for (row = lastRow, firstRow = start.row; row >= firstRow; row--)
+ if (forEachInLine(row, Number.MAX_VALUE, callback))
+ return;
+ };
+ }
+ else {
+ var forEach = function(callback) {
+ var row = start.row;
+ if (forEachInLine(row, start.column, callback))
+ return;
+ for (row = row + 1; row <= lastRow; row++)
+ if (forEachInLine(row, 0, callback))
+ return;
+ if (options.wrap == false)
+ return;
+ for (row = firstRow, lastRow = start.row; row <= lastRow; row++)
+ if (forEachInLine(row, 0, callback))
+ return;
+ };
+ }
+
+ if (options.$isMultiLine) {
+ var len = re.length;
+ var forEachInLine = function(row, offset, callback) {
+ var startRow = backwards ? row - len + 1 : row;
+ if (startRow < 0) return;
+ var line = session.getLine(startRow);
+ var startIndex = line.search(re[0])
+ if (!backwards && startIndex < offset || startIndex === -1) return;
+ for (var i = 1; i < len; i++) {
+ line = session.getLine(startRow + i);
+ if (line.search(re[i]) == -1)
+ return;
+ }
+ var endIndex = line.match(re[len - 1])[0].length;
+ if (backwards && endIndex > offset) return;
+ if (callback(startRow, startIndex, startRow + len - 1, endIndex))
+ return true;
+ };
+ }
+ else if (backwards) {
+ var forEachInLine = function(row, endIndex, callback) {
+ var line = session.getLine(row);
+ var matches = [];
+ var m, last = 0;
+ re.lastIndex = 0;
+ while((m = re.exec(line))) {
+ var length = m[0].length;
+ last = m.index;
+ if (!length) {
+ if (last >= line.length) break;
+ re.lastIndex = last += 1;
+ }
+ if (m.index + length > endIndex)
+ break;
+ matches.push(m.index, length)
+ }
+ for (var i = matches.length - 1; i >= 0; i -= 2) {
+ var column = matches[i - 1];
+ var length = matches[i];
+ if (callback(row, column, row, column + length))
+ return true;
+ }
+ };
+ }
+ else {
+ var forEachInLine = function(row, startIndex, callback) {
+ var line = session.getLine(row);
+ var m;
+ var last = startIndex;
+ re.lastIndex = startIndex;
+ while((m = re.exec(line))) {
+ var length = m[0].length;
+ last = m.index;
+ if (callback(row, last, row,last + length))
+ return true;
+ if (!length) {
+ re.lastIndex = last += 1;
+ if (last >= line.length) return false;
+ }
+ }
+ };
+ }
+ return {forEach: forEach};
+ };
+
+}).call(Search.prototype);
+
+function addWordBoundary(needle, options) {
+ function wordBoundary(c) {
+ if (/\w/.test(c) || options.regExp) return "\\b";
+ return "";
+ }
+ return wordBoundary(needle[0]) + needle
+ + wordBoundary(needle[needle.length - 1]);
+}
+
+exports.Search = Search;
+});
+
+ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"], function(require, exports, module) {
+"use strict";
+
+var keyUtil = require("../lib/keys");
+var useragent = require("../lib/useragent");
+var KEY_MODS = keyUtil.KEY_MODS;
+
+function HashHandler(config, platform) {
+ this.platform = platform || (useragent.isMac ? "mac" : "win");
+ this.commands = {};
+ this.commandKeyBinding = {};
+ this.addCommands(config);
+ this.$singleCommand = true;
+}
+
+function MultiHashHandler(config, platform) {
+ HashHandler.call(this, config, platform);
+ this.$singleCommand = false;
+}
+
+MultiHashHandler.prototype = HashHandler.prototype;
+
+(function() {
+
+
+ this.addCommand = function(command) {
+ if (this.commands[command.name])
+ this.removeCommand(command);
+
+ this.commands[command.name] = command;
+
+ if (command.bindKey)
+ this._buildKeyHash(command);
+ };
+
+ this.removeCommand = function(command, keepCommand) {
+ var name = command && (typeof command === 'string' ? command : command.name);
+ command = this.commands[name];
+ if (!keepCommand)
+ delete this.commands[name];
+ var ckb = this.commandKeyBinding;
+ for (var keyId in ckb) {
+ var cmdGroup = ckb[keyId];
+ if (cmdGroup == command) {
+ delete ckb[keyId];
+ } else if (Array.isArray(cmdGroup)) {
+ var i = cmdGroup.indexOf(command);
+ if (i != -1) {
+ cmdGroup.splice(i, 1);
+ if (cmdGroup.length == 1)
+ ckb[keyId] = cmdGroup[0];
+ }
+ }
+ }
+ };
+
+ this.bindKey = function(key, command, position) {
+ if (typeof key == "object" && key) {
+ if (position == undefined)
+ position = key.position;
+ key = key[this.platform];
+ }
+ if (!key)
+ return;
+ if (typeof command == "function")
+ return this.addCommand({exec: command, bindKey: key, name: command.name || key});
+
+ key.split("|").forEach(function(keyPart) {
+ var chain = "";
+ if (keyPart.indexOf(" ") != -1) {
+ var parts = keyPart.split(/\s+/);
+ keyPart = parts.pop();
+ parts.forEach(function(keyPart) {
+ var binding = this.parseKeys(keyPart);
+ var id = KEY_MODS[binding.hashId] + binding.key;
+ chain += (chain ? " " : "") + id;
+ this._addCommandToBinding(chain, "chainKeys");
+ }, this);
+ chain += " ";
+ }
+ var binding = this.parseKeys(keyPart);
+ var id = KEY_MODS[binding.hashId] + binding.key;
+ this._addCommandToBinding(chain + id, command, position);
+ }, this);
+ };
+
+ function getPosition(command) {
+ return typeof command == "object" && command.bindKey
+ && command.bindKey.position
+ || (command.isDefault ? -100 : 0);
+ }
+ this._addCommandToBinding = function(keyId, command, position) {
+ var ckb = this.commandKeyBinding, i;
+ if (!command) {
+ delete ckb[keyId];
+ } else if (!ckb[keyId] || this.$singleCommand) {
+ ckb[keyId] = command;
+ } else {
+ if (!Array.isArray(ckb[keyId])) {
+ ckb[keyId] = [ckb[keyId]];
+ } else if ((i = ckb[keyId].indexOf(command)) != -1) {
+ ckb[keyId].splice(i, 1);
+ }
+
+ if (typeof position != "number") {
+ position = getPosition(command);
+ }
+
+ var commands = ckb[keyId];
+ for (i = 0; i < commands.length; i++) {
+ var other = commands[i];
+ var otherPos = getPosition(other);
+ if (otherPos > position)
+ break;
+ }
+ commands.splice(i, 0, command);
+ }
+ };
+
+ this.addCommands = function(commands) {
+ commands && Object.keys(commands).forEach(function(name) {
+ var command = commands[name];
+ if (!command)
+ return;
+
+ if (typeof command === "string")
+ return this.bindKey(command, name);
+
+ if (typeof command === "function")
+ command = { exec: command };
+
+ if (typeof command !== "object")
+ return;
+
+ if (!command.name)
+ command.name = name;
+
+ this.addCommand(command);
+ }, this);
+ };
+
+ this.removeCommands = function(commands) {
+ Object.keys(commands).forEach(function(name) {
+ this.removeCommand(commands[name]);
+ }, this);
+ };
+
+ this.bindKeys = function(keyList) {
+ Object.keys(keyList).forEach(function(key) {
+ this.bindKey(key, keyList[key]);
+ }, this);
+ };
+
+ this._buildKeyHash = function(command) {
+ this.bindKey(command.bindKey, command);
+ };
+ this.parseKeys = function(keys) {
+ var parts = keys.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(x){return x});
+ var key = parts.pop();
+
+ var keyCode = keyUtil[key];
+ if (keyUtil.FUNCTION_KEYS[keyCode])
+ key = keyUtil.FUNCTION_KEYS[keyCode].toLowerCase();
+ else if (!parts.length)
+ return {key: key, hashId: -1};
+ else if (parts.length == 1 && parts[0] == "shift")
+ return {key: key.toUpperCase(), hashId: -1};
+
+ var hashId = 0;
+ for (var i = parts.length; i--;) {
+ var modifier = keyUtil.KEY_MODS[parts[i]];
+ if (modifier == null) {
+ if (typeof console != "undefined")
+ console.error("invalid modifier " + parts[i] + " in " + keys);
+ return false;
+ }
+ hashId |= modifier;
+ }
+ return {key: key, hashId: hashId};
+ };
+
+ this.findKeyCommand = function findKeyCommand(hashId, keyString) {
+ var key = KEY_MODS[hashId] + keyString;
+ return this.commandKeyBinding[key];
+ };
+
+ this.handleKeyboard = function(data, hashId, keyString, keyCode) {
+ if (keyCode < 0) return;
+ var key = KEY_MODS[hashId] + keyString;
+ var command = this.commandKeyBinding[key];
+ if (data.$keyChain) {
+ data.$keyChain += " " + key;
+ command = this.commandKeyBinding[data.$keyChain] || command;
+ }
+
+ if (command) {
+ if (command == "chainKeys" || command[command.length - 1] == "chainKeys") {
+ data.$keyChain = data.$keyChain || key;
+ return {command: "null"};
+ }
+ }
+
+ if (data.$keyChain) {
+ if ((!hashId || hashId == 4) && keyString.length == 1)
+ data.$keyChain = data.$keyChain.slice(0, -key.length - 1); // wait for input
+ else if (hashId == -1 || keyCode > 0)
+ data.$keyChain = ""; // reset keyChain
+ }
+ return {command: command};
+ };
+
+ this.getStatusText = function(editor, data) {
+ return data.$keyChain || "";
+ };
+
+}).call(HashHandler.prototype);
+
+exports.HashHandler = HashHandler;
+exports.MultiHashHandler = MultiHashHandler;
+});
+
+ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var MultiHashHandler = require("../keyboard/hash_handler").MultiHashHandler;
+var EventEmitter = require("../lib/event_emitter").EventEmitter;
+
+var CommandManager = function(platform, commands) {
+ MultiHashHandler.call(this, commands, platform);
+ this.byName = this.commands;
+ this.setDefaultHandler("exec", function(e) {
+ return e.command.exec(e.editor, e.args || {});
+ });
+};
+
+oop.inherits(CommandManager, MultiHashHandler);
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.exec = function(command, editor, args) {
+ if (Array.isArray(command)) {
+ for (var i = command.length; i--; ) {
+ if (this.exec(command[i], editor, args)) return true;
+ }
+ return false;
+ }
+
+ if (typeof command === "string")
+ command = this.commands[command];
+
+ if (!command)
+ return false;
+
+ if (editor && editor.$readOnly && !command.readOnly)
+ return false;
+
+ if (command.isAvailable && !command.isAvailable(editor))
+ return false;
+
+ var e = {editor: editor, command: command, args: args};
+ e.returnValue = this._emit("exec", e);
+ this._signal("afterExec", e);
+
+ return e.returnValue === false ? false : true;
+ };
+
+ this.toggleRecording = function(editor) {
+ if (this.$inReplay)
+ return;
+
+ editor && editor._emit("changeStatus");
+ if (this.recording) {
+ this.macro.pop();
+ this.removeEventListener("exec", this.$addCommandToMacro);
+
+ if (!this.macro.length)
+ this.macro = this.oldMacro;
+
+ return this.recording = false;
+ }
+ if (!this.$addCommandToMacro) {
+ this.$addCommandToMacro = function(e) {
+ this.macro.push([e.command, e.args]);
+ }.bind(this);
+ }
+
+ this.oldMacro = this.macro;
+ this.macro = [];
+ this.on("exec", this.$addCommandToMacro);
+ return this.recording = true;
+ };
+
+ this.replay = function(editor) {
+ if (this.$inReplay || !this.macro)
+ return;
+
+ if (this.recording)
+ return this.toggleRecording(editor);
+
+ try {
+ this.$inReplay = true;
+ this.macro.forEach(function(x) {
+ if (typeof x == "string")
+ this.exec(x, editor);
+ else
+ this.exec(x[0], editor, x[1]);
+ }, this);
+ } finally {
+ this.$inReplay = false;
+ }
+ };
+
+ this.trimMacro = function(m) {
+ return m.map(function(x){
+ if (typeof x[0] != "string")
+ x[0] = x[0].name;
+ if (!x[1])
+ x = x[0];
+ return x;
+ });
+ };
+
+}).call(CommandManager.prototype);
+
+exports.CommandManager = CommandManager;
+
+});
+
+ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"], function(require, exports, module) {
+"use strict";
+
+var lang = require("../lib/lang");
+var config = require("../config");
+var Range = require("../range").Range;
+
+function bindKey(win, mac) {
+ return {win: win, mac: mac};
+}
+exports.commands = [{
+ name: "showSettingsMenu",
+ bindKey: bindKey("Ctrl-,", "Command-,"),
+ exec: function(editor) {
+ config.loadModule("ace/ext/settings_menu", function(module) {
+ module.init(editor);
+ editor.showSettingsMenu();
+ });
+ },
+ readOnly: true
+}, {
+ name: "goToNextError",
+ bindKey: bindKey("Alt-E", "F4"),
+ exec: function(editor) {
+ config.loadModule("ace/ext/error_marker", function(module) {
+ module.showErrorMarker(editor, 1);
+ });
+ },
+ scrollIntoView: "animate",
+ readOnly: true
+}, {
+ name: "goToPreviousError",
+ bindKey: bindKey("Alt-Shift-E", "Shift-F4"),
+ exec: function(editor) {
+ config.loadModule("ace/ext/error_marker", function(module) {
+ module.showErrorMarker(editor, -1);
+ });
+ },
+ scrollIntoView: "animate",
+ readOnly: true
+}, {
+ name: "selectall",
+ bindKey: bindKey("Ctrl-A", "Command-A"),
+ exec: function(editor) { editor.selectAll(); },
+ readOnly: true
+}, {
+ name: "centerselection",
+ bindKey: bindKey(null, "Ctrl-L"),
+ exec: function(editor) { editor.centerSelection(); },
+ readOnly: true
+}, {
+ name: "gotoline",
+ bindKey: bindKey("Ctrl-L", "Command-L"),
+ exec: function(editor) {
+ var line = parseInt(prompt("Enter line number:"), 10);
+ if (!isNaN(line)) {
+ editor.gotoLine(line);
+ }
+ },
+ readOnly: true
+}, {
+ name: "fold",
+ bindKey: bindKey("Alt-L|Ctrl-F1", "Command-Alt-L|Command-F1"),
+ exec: function(editor) { editor.session.toggleFold(false); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "unfold",
+ bindKey: bindKey("Alt-Shift-L|Ctrl-Shift-F1", "Command-Alt-Shift-L|Command-Shift-F1"),
+ exec: function(editor) { editor.session.toggleFold(true); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "toggleFoldWidget",
+ bindKey: bindKey("F2", "F2"),
+ exec: function(editor) { editor.session.toggleFoldWidget(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "toggleParentFoldWidget",
+ bindKey: bindKey("Alt-F2", "Alt-F2"),
+ exec: function(editor) { editor.session.toggleFoldWidget(true); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "foldall",
+ bindKey: bindKey(null, "Ctrl-Command-Option-0"),
+ exec: function(editor) { editor.session.foldAll(); },
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "foldOther",
+ bindKey: bindKey("Alt-0", "Command-Option-0"),
+ exec: function(editor) {
+ editor.session.foldAll();
+ editor.session.unfold(editor.selection.getAllRanges());
+ },
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "unfoldall",
+ bindKey: bindKey("Alt-Shift-0", "Command-Option-Shift-0"),
+ exec: function(editor) { editor.session.unfold(); },
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "findnext",
+ bindKey: bindKey("Ctrl-K", "Command-G"),
+ exec: function(editor) { editor.findNext(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "findprevious",
+ bindKey: bindKey("Ctrl-Shift-K", "Command-Shift-G"),
+ exec: function(editor) { editor.findPrevious(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "center",
+ readOnly: true
+}, {
+ name: "selectOrFindNext",
+ bindKey: bindKey("Alt-K", "Ctrl-G"),
+ exec: function(editor) {
+ if (editor.selection.isEmpty())
+ editor.selection.selectWord();
+ else
+ editor.findNext();
+ },
+ readOnly: true
+}, {
+ name: "selectOrFindPrevious",
+ bindKey: bindKey("Alt-Shift-K", "Ctrl-Shift-G"),
+ exec: function(editor) {
+ if (editor.selection.isEmpty())
+ editor.selection.selectWord();
+ else
+ editor.findPrevious();
+ },
+ readOnly: true
+}, {
+ name: "find",
+ bindKey: bindKey("Ctrl-F", "Command-F"),
+ exec: function(editor) {
+ config.loadModule("ace/ext/searchbox", function(e) {e.Search(editor)});
+ },
+ readOnly: true
+}, {
+ name: "overwrite",
+ bindKey: "Insert",
+ exec: function(editor) { editor.toggleOverwrite(); },
+ readOnly: true
+}, {
+ name: "selecttostart",
+ bindKey: bindKey("Ctrl-Shift-Home", "Command-Shift-Home|Command-Shift-Up"),
+ exec: function(editor) { editor.getSelection().selectFileStart(); },
+ multiSelectAction: "forEach",
+ readOnly: true,
+ scrollIntoView: "animate",
+ aceCommandGroup: "fileJump"
+}, {
+ name: "gotostart",
+ bindKey: bindKey("Ctrl-Home", "Command-Home|Command-Up"),
+ exec: function(editor) { editor.navigateFileStart(); },
+ multiSelectAction: "forEach",
+ readOnly: true,
+ scrollIntoView: "animate",
+ aceCommandGroup: "fileJump"
+}, {
+ name: "selectup",
+ bindKey: bindKey("Shift-Up", "Shift-Up|Ctrl-Shift-P"),
+ exec: function(editor) { editor.getSelection().selectUp(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "golineup",
+ bindKey: bindKey("Up", "Up|Ctrl-P"),
+ exec: function(editor, args) { editor.navigateUp(args.times); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selecttoend",
+ bindKey: bindKey("Ctrl-Shift-End", "Command-Shift-End|Command-Shift-Down"),
+ exec: function(editor) { editor.getSelection().selectFileEnd(); },
+ multiSelectAction: "forEach",
+ readOnly: true,
+ scrollIntoView: "animate",
+ aceCommandGroup: "fileJump"
+}, {
+ name: "gotoend",
+ bindKey: bindKey("Ctrl-End", "Command-End|Command-Down"),
+ exec: function(editor) { editor.navigateFileEnd(); },
+ multiSelectAction: "forEach",
+ readOnly: true,
+ scrollIntoView: "animate",
+ aceCommandGroup: "fileJump"
+}, {
+ name: "selectdown",
+ bindKey: bindKey("Shift-Down", "Shift-Down|Ctrl-Shift-N"),
+ exec: function(editor) { editor.getSelection().selectDown(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "golinedown",
+ bindKey: bindKey("Down", "Down|Ctrl-N"),
+ exec: function(editor, args) { editor.navigateDown(args.times); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectwordleft",
+ bindKey: bindKey("Ctrl-Shift-Left", "Option-Shift-Left"),
+ exec: function(editor) { editor.getSelection().selectWordLeft(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "gotowordleft",
+ bindKey: bindKey("Ctrl-Left", "Option-Left"),
+ exec: function(editor) { editor.navigateWordLeft(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selecttolinestart",
+ bindKey: bindKey("Alt-Shift-Left", "Command-Shift-Left|Ctrl-Shift-A"),
+ exec: function(editor) { editor.getSelection().selectLineStart(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "gotolinestart",
+ bindKey: bindKey("Alt-Left|Home", "Command-Left|Home|Ctrl-A"),
+ exec: function(editor) { editor.navigateLineStart(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectleft",
+ bindKey: bindKey("Shift-Left", "Shift-Left|Ctrl-Shift-B"),
+ exec: function(editor) { editor.getSelection().selectLeft(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "gotoleft",
+ bindKey: bindKey("Left", "Left|Ctrl-B"),
+ exec: function(editor, args) { editor.navigateLeft(args.times); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectwordright",
+ bindKey: bindKey("Ctrl-Shift-Right", "Option-Shift-Right"),
+ exec: function(editor) { editor.getSelection().selectWordRight(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "gotowordright",
+ bindKey: bindKey("Ctrl-Right", "Option-Right"),
+ exec: function(editor) { editor.navigateWordRight(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selecttolineend",
+ bindKey: bindKey("Alt-Shift-Right", "Command-Shift-Right|Shift-End|Ctrl-Shift-E"),
+ exec: function(editor) { editor.getSelection().selectLineEnd(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "gotolineend",
+ bindKey: bindKey("Alt-Right|End", "Command-Right|End|Ctrl-E"),
+ exec: function(editor) { editor.navigateLineEnd(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectright",
+ bindKey: bindKey("Shift-Right", "Shift-Right"),
+ exec: function(editor) { editor.getSelection().selectRight(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "gotoright",
+ bindKey: bindKey("Right", "Right|Ctrl-F"),
+ exec: function(editor, args) { editor.navigateRight(args.times); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectpagedown",
+ bindKey: "Shift-PageDown",
+ exec: function(editor) { editor.selectPageDown(); },
+ readOnly: true
+}, {
+ name: "pagedown",
+ bindKey: bindKey(null, "Option-PageDown"),
+ exec: function(editor) { editor.scrollPageDown(); },
+ readOnly: true
+}, {
+ name: "gotopagedown",
+ bindKey: bindKey("PageDown", "PageDown|Ctrl-V"),
+ exec: function(editor) { editor.gotoPageDown(); },
+ readOnly: true
+}, {
+ name: "selectpageup",
+ bindKey: "Shift-PageUp",
+ exec: function(editor) { editor.selectPageUp(); },
+ readOnly: true
+}, {
+ name: "pageup",
+ bindKey: bindKey(null, "Option-PageUp"),
+ exec: function(editor) { editor.scrollPageUp(); },
+ readOnly: true
+}, {
+ name: "gotopageup",
+ bindKey: "PageUp",
+ exec: function(editor) { editor.gotoPageUp(); },
+ readOnly: true
+}, {
+ name: "scrollup",
+ bindKey: bindKey("Ctrl-Up", null),
+ exec: function(e) { e.renderer.scrollBy(0, -2 * e.renderer.layerConfig.lineHeight); },
+ readOnly: true
+}, {
+ name: "scrolldown",
+ bindKey: bindKey("Ctrl-Down", null),
+ exec: function(e) { e.renderer.scrollBy(0, 2 * e.renderer.layerConfig.lineHeight); },
+ readOnly: true
+}, {
+ name: "selectlinestart",
+ bindKey: "Shift-Home",
+ exec: function(editor) { editor.getSelection().selectLineStart(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectlineend",
+ bindKey: "Shift-End",
+ exec: function(editor) { editor.getSelection().selectLineEnd(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "togglerecording",
+ bindKey: bindKey("Ctrl-Alt-E", "Command-Option-E"),
+ exec: function(editor) { editor.commands.toggleRecording(editor); },
+ readOnly: true
+}, {
+ name: "replaymacro",
+ bindKey: bindKey("Ctrl-Shift-E", "Command-Shift-E"),
+ exec: function(editor) { editor.commands.replay(editor); },
+ readOnly: true
+}, {
+ name: "jumptomatching",
+ bindKey: bindKey("Ctrl-P", "Ctrl-P"),
+ exec: function(editor) { editor.jumpToMatching(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "animate",
+ readOnly: true
+}, {
+ name: "selecttomatching",
+ bindKey: bindKey("Ctrl-Shift-P", "Ctrl-Shift-P"),
+ exec: function(editor) { editor.jumpToMatching(true); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "animate",
+ readOnly: true
+}, {
+ name: "expandToMatching",
+ bindKey: bindKey("Ctrl-Shift-M", "Ctrl-Shift-M"),
+ exec: function(editor) { editor.jumpToMatching(true, true); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "animate",
+ readOnly: true
+}, {
+ name: "passKeysToBrowser",
+ bindKey: bindKey(null, null),
+ exec: function() {},
+ passEvent: true,
+ readOnly: true
+}, {
+ name: "copy",
+ exec: function(editor) {
+ },
+ readOnly: true
+},
+{
+ name: "cut",
+ exec: function(editor) {
+ var range = editor.getSelectionRange();
+ editor._emit("cut", range);
+
+ if (!editor.selection.isEmpty()) {
+ editor.session.remove(range);
+ editor.clearSelection();
+ }
+ },
+ scrollIntoView: "cursor",
+ multiSelectAction: "forEach"
+}, {
+ name: "paste",
+ exec: function(editor, args) {
+ editor.$handlePaste(args);
+ },
+ scrollIntoView: "cursor"
+}, {
+ name: "removeline",
+ bindKey: bindKey("Ctrl-D", "Command-D"),
+ exec: function(editor) { editor.removeLines(); },
+ scrollIntoView: "cursor",
+ multiSelectAction: "forEachLine"
+}, {
+ name: "duplicateSelection",
+ bindKey: bindKey("Ctrl-Shift-D", "Command-Shift-D"),
+ exec: function(editor) { editor.duplicateSelection(); },
+ scrollIntoView: "cursor",
+ multiSelectAction: "forEach"
+}, {
+ name: "sortlines",
+ bindKey: bindKey("Ctrl-Alt-S", "Command-Alt-S"),
+ exec: function(editor) { editor.sortLines(); },
+ scrollIntoView: "selection",
+ multiSelectAction: "forEachLine"
+}, {
+ name: "togglecomment",
+ bindKey: bindKey("Ctrl-/", "Command-/"),
+ exec: function(editor) { editor.toggleCommentLines(); },
+ multiSelectAction: "forEachLine",
+ scrollIntoView: "selectionPart"
+}, {
+ name: "toggleBlockComment",
+ bindKey: bindKey("Ctrl-Shift-/", "Command-Shift-/"),
+ exec: function(editor) { editor.toggleBlockComment(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "selectionPart"
+}, {
+ name: "modifyNumberUp",
+ bindKey: bindKey("Ctrl-Shift-Up", "Alt-Shift-Up"),
+ exec: function(editor) { editor.modifyNumber(1); },
+ scrollIntoView: "cursor",
+ multiSelectAction: "forEach"
+}, {
+ name: "modifyNumberDown",
+ bindKey: bindKey("Ctrl-Shift-Down", "Alt-Shift-Down"),
+ exec: function(editor) { editor.modifyNumber(-1); },
+ scrollIntoView: "cursor",
+ multiSelectAction: "forEach"
+}, {
+ name: "replace",
+ bindKey: bindKey("Ctrl-H", "Command-Option-F"),
+ exec: function(editor) {
+ config.loadModule("ace/ext/searchbox", function(e) {e.Search(editor, true)});
+ }
+}, {
+ name: "undo",
+ bindKey: bindKey("Ctrl-Z", "Command-Z"),
+ exec: function(editor) { editor.undo(); }
+}, {
+ name: "redo",
+ bindKey: bindKey("Ctrl-Shift-Z|Ctrl-Y", "Command-Shift-Z|Command-Y"),
+ exec: function(editor) { editor.redo(); }
+}, {
+ name: "copylinesup",
+ bindKey: bindKey("Alt-Shift-Up", "Command-Option-Up"),
+ exec: function(editor) { editor.copyLinesUp(); },
+ scrollIntoView: "cursor"
+}, {
+ name: "movelinesup",
+ bindKey: bindKey("Alt-Up", "Option-Up"),
+ exec: function(editor) { editor.moveLinesUp(); },
+ scrollIntoView: "cursor"
+}, {
+ name: "copylinesdown",
+ bindKey: bindKey("Alt-Shift-Down", "Command-Option-Down"),
+ exec: function(editor) { editor.copyLinesDown(); },
+ scrollIntoView: "cursor"
+}, {
+ name: "movelinesdown",
+ bindKey: bindKey("Alt-Down", "Option-Down"),
+ exec: function(editor) { editor.moveLinesDown(); },
+ scrollIntoView: "cursor"
+}, {
+ name: "del",
+ bindKey: bindKey("Delete", "Delete|Ctrl-D|Shift-Delete"),
+ exec: function(editor) { editor.remove("right"); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "backspace",
+ bindKey: bindKey(
+ "Shift-Backspace|Backspace",
+ "Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"
+ ),
+ exec: function(editor) { editor.remove("left"); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "cut_or_delete",
+ bindKey: bindKey("Shift-Delete", null),
+ exec: function(editor) {
+ if (editor.selection.isEmpty()) {
+ editor.remove("left");
+ } else {
+ return false;
+ }
+ },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "removetolinestart",
+ bindKey: bindKey("Alt-Backspace", "Command-Backspace"),
+ exec: function(editor) { editor.removeToLineStart(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "removetolineend",
+ bindKey: bindKey("Alt-Delete", "Ctrl-K"),
+ exec: function(editor) { editor.removeToLineEnd(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "removewordleft",
+ bindKey: bindKey("Ctrl-Backspace", "Alt-Backspace|Ctrl-Alt-Backspace"),
+ exec: function(editor) { editor.removeWordLeft(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "removewordright",
+ bindKey: bindKey("Ctrl-Delete", "Alt-Delete"),
+ exec: function(editor) { editor.removeWordRight(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "outdent",
+ bindKey: bindKey("Shift-Tab", "Shift-Tab"),
+ exec: function(editor) { editor.blockOutdent(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "selectionPart"
+}, {
+ name: "indent",
+ bindKey: bindKey("Tab", "Tab"),
+ exec: function(editor) { editor.indent(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "selectionPart"
+}, {
+ name: "blockoutdent",
+ bindKey: bindKey("Ctrl-[", "Ctrl-["),
+ exec: function(editor) { editor.blockOutdent(); },
+ multiSelectAction: "forEachLine",
+ scrollIntoView: "selectionPart"
+}, {
+ name: "blockindent",
+ bindKey: bindKey("Ctrl-]", "Ctrl-]"),
+ exec: function(editor) { editor.blockIndent(); },
+ multiSelectAction: "forEachLine",
+ scrollIntoView: "selectionPart"
+}, {
+ name: "insertstring",
+ exec: function(editor, str) { editor.insert(str); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "inserttext",
+ exec: function(editor, args) {
+ editor.insert(lang.stringRepeat(args.text || "", args.times || 1));
+ },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "splitline",
+ bindKey: bindKey(null, "Ctrl-O"),
+ exec: function(editor) { editor.splitLine(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "transposeletters",
+ bindKey: bindKey("Alt-Shift-X", "Ctrl-T"),
+ exec: function(editor) { editor.transposeLetters(); },
+ multiSelectAction: function(editor) {editor.transposeSelections(1); },
+ scrollIntoView: "cursor"
+}, {
+ name: "touppercase",
+ bindKey: bindKey("Ctrl-U", "Ctrl-U"),
+ exec: function(editor) { editor.toUpperCase(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "tolowercase",
+ bindKey: bindKey("Ctrl-Shift-U", "Ctrl-Shift-U"),
+ exec: function(editor) { editor.toLowerCase(); },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor"
+}, {
+ name: "expandtoline",
+ bindKey: bindKey("Ctrl-Shift-L", "Command-Shift-L"),
+ exec: function(editor) {
+ var range = editor.selection.getRange();
+
+ range.start.column = range.end.column = 0;
+ range.end.row++;
+ editor.selection.setRange(range, false);
+ },
+ multiSelectAction: "forEach",
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "joinlines",
+ bindKey: bindKey(null, null),
+ exec: function(editor) {
+ var isBackwards = editor.selection.isBackwards();
+ var selectionStart = isBackwards ? editor.selection.getSelectionLead() : editor.selection.getSelectionAnchor();
+ var selectionEnd = isBackwards ? editor.selection.getSelectionAnchor() : editor.selection.getSelectionLead();
+ var firstLineEndCol = editor.session.doc.getLine(selectionStart.row).length;
+ var selectedText = editor.session.doc.getTextRange(editor.selection.getRange());
+ var selectedCount = selectedText.replace(/\n\s*/, " ").length;
+ var insertLine = editor.session.doc.getLine(selectionStart.row);
+
+ for (var i = selectionStart.row + 1; i <= selectionEnd.row + 1; i++) {
+ var curLine = lang.stringTrimLeft(lang.stringTrimRight(editor.session.doc.getLine(i)));
+ if (curLine.length !== 0) {
+ curLine = " " + curLine;
+ }
+ insertLine += curLine;
+ }
+
+ if (selectionEnd.row + 1 < (editor.session.doc.getLength() - 1)) {
+ insertLine += editor.session.doc.getNewLineCharacter();
+ }
+
+ editor.clearSelection();
+ editor.session.doc.replace(new Range(selectionStart.row, 0, selectionEnd.row + 2, 0), insertLine);
+
+ if (selectedCount > 0) {
+ editor.selection.moveCursorTo(selectionStart.row, selectionStart.column);
+ editor.selection.selectTo(selectionStart.row, selectionStart.column + selectedCount);
+ } else {
+ firstLineEndCol = editor.session.doc.getLine(selectionStart.row).length > firstLineEndCol ? (firstLineEndCol + 1) : firstLineEndCol;
+ editor.selection.moveCursorTo(selectionStart.row, firstLineEndCol);
+ }
+ },
+ multiSelectAction: "forEach",
+ readOnly: true
+}, {
+ name: "invertSelection",
+ bindKey: bindKey(null, null),
+ exec: function(editor) {
+ var endRow = editor.session.doc.getLength() - 1;
+ var endCol = editor.session.doc.getLine(endRow).length;
+ var ranges = editor.selection.rangeList.ranges;
+ var newRanges = [];
+ if (ranges.length < 1) {
+ ranges = [editor.selection.getRange()];
+ }
+
+ for (var i = 0; i < ranges.length; i++) {
+ if (i == (ranges.length - 1)) {
+ if (!(ranges[i].end.row === endRow && ranges[i].end.column === endCol)) {
+ newRanges.push(new Range(ranges[i].end.row, ranges[i].end.column, endRow, endCol));
+ }
+ }
+
+ if (i === 0) {
+ if (!(ranges[i].start.row === 0 && ranges[i].start.column === 0)) {
+ newRanges.push(new Range(0, 0, ranges[i].start.row, ranges[i].start.column));
+ }
+ } else {
+ newRanges.push(new Range(ranges[i-1].end.row, ranges[i-1].end.column, ranges[i].start.row, ranges[i].start.column));
+ }
+ }
+
+ editor.exitMultiSelectMode();
+ editor.clearSelection();
+
+ for(var i = 0; i < newRanges.length; i++) {
+ editor.selection.addRange(newRanges[i], false);
+ }
+ },
+ readOnly: true,
+ scrollIntoView: "none"
+}];
+
+});
+
+ace.define("ace/editor",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+require("./lib/fixoldbrowsers");
+
+var oop = require("./lib/oop");
+var dom = require("./lib/dom");
+var lang = require("./lib/lang");
+var useragent = require("./lib/useragent");
+var TextInput = require("./keyboard/textinput").TextInput;
+var MouseHandler = require("./mouse/mouse_handler").MouseHandler;
+var FoldHandler = require("./mouse/fold_handler").FoldHandler;
+var KeyBinding = require("./keyboard/keybinding").KeyBinding;
+var EditSession = require("./edit_session").EditSession;
+var Search = require("./search").Search;
+var Range = require("./range").Range;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var CommandManager = require("./commands/command_manager").CommandManager;
+var defaultCommands = require("./commands/default_commands").commands;
+var config = require("./config");
+var TokenIterator = require("./token_iterator").TokenIterator;
+var Editor = function(renderer, session) {
+ var container = renderer.getContainerElement();
+ this.container = container;
+ this.renderer = renderer;
+ this.id = "editor" + (++Editor.$uid);
+
+ this.commands = new CommandManager(useragent.isMac ? "mac" : "win", defaultCommands);
+ if (typeof document == "object") {
+ this.textInput = new TextInput(renderer.getTextAreaContainer(), this);
+ this.renderer.textarea = this.textInput.getElement();
+ this.$mouseHandler = new MouseHandler(this);
+ new FoldHandler(this);
+ }
+
+ this.keyBinding = new KeyBinding(this);
+
+ this.$blockScrolling = 0;
+ this.$search = new Search().set({
+ wrap: true
+ });
+
+ this.$historyTracker = this.$historyTracker.bind(this);
+ this.commands.on("exec", this.$historyTracker);
+
+ this.$initOperationListeners();
+
+ this._$emitInputEvent = lang.delayedCall(function() {
+ this._signal("input", {});
+ if (this.session && this.session.bgTokenizer)
+ this.session.bgTokenizer.scheduleStart();
+ }.bind(this));
+
+ this.on("change", function(_, _self) {
+ _self._$emitInputEvent.schedule(31);
+ });
+
+ this.setSession(session || new EditSession(""));
+ config.resetOptions(this);
+ config._signal("editor", this);
+};
+
+Editor.$uid = 0;
+
+(function(){
+
+ oop.implement(this, EventEmitter);
+
+ this.$initOperationListeners = function() {
+ function last(a) {return a[a.length - 1]}
+
+ this.selections = [];
+ this.commands.on("exec", this.startOperation.bind(this), true);
+ this.commands.on("afterExec", this.endOperation.bind(this), true);
+
+ this.$opResetTimer = lang.delayedCall(this.endOperation.bind(this));
+
+ this.on("change", function() {
+ this.curOp || this.startOperation();
+ this.curOp.docChanged = true;
+ }.bind(this), true);
+
+ this.on("changeSelection", function() {
+ this.curOp || this.startOperation();
+ this.curOp.selectionChanged = true;
+ }.bind(this), true);
+ };
+
+ this.curOp = null;
+ this.prevOp = {};
+ this.startOperation = function(commadEvent) {
+ if (this.curOp) {
+ if (!commadEvent || this.curOp.command)
+ return;
+ this.prevOp = this.curOp;
+ }
+ if (!commadEvent) {
+ this.previousCommand = null;
+ commadEvent = {};
+ }
+
+ this.$opResetTimer.schedule();
+ this.curOp = {
+ command: commadEvent.command || {},
+ args: commadEvent.args,
+ scrollTop: this.renderer.scrollTop
+ };
+ if (this.curOp.command.name && this.curOp.command.scrollIntoView !== undefined)
+ this.$blockScrolling++;
+ };
+
+ this.endOperation = function(e) {
+ if (this.curOp) {
+ if (e && e.returnValue === false)
+ return this.curOp = null;
+ this._signal("beforeEndOperation");
+ var command = this.curOp.command;
+ if (command.name && this.$blockScrolling > 0)
+ this.$blockScrolling--;
+ var scrollIntoView = command && command.scrollIntoView;
+ if (scrollIntoView) {
+ switch (scrollIntoView) {
+ case "center-animate":
+ scrollIntoView = "animate";
+ case "center":
+ this.renderer.scrollCursorIntoView(null, 0.5);
+ break;
+ case "animate":
+ case "cursor":
+ this.renderer.scrollCursorIntoView();
+ break;
+ case "selectionPart":
+ var range = this.selection.getRange();
+ var config = this.renderer.layerConfig;
+ if (range.start.row >= config.lastRow || range.end.row <= config.firstRow) {
+ this.renderer.scrollSelectionIntoView(this.selection.anchor, this.selection.lead);
+ }
+ break;
+ default:
+ break;
+ }
+ if (scrollIntoView == "animate")
+ this.renderer.animateScrolling(this.curOp.scrollTop);
+ }
+
+ this.prevOp = this.curOp;
+ this.curOp = null;
+ }
+ };
+ this.$mergeableCommands = ["backspace", "del", "insertstring"];
+ this.$historyTracker = function(e) {
+ if (!this.$mergeUndoDeltas)
+ return;
+
+ var prev = this.prevOp;
+ var mergeableCommands = this.$mergeableCommands;
+ var shouldMerge = prev.command && (e.command.name == prev.command.name);
+ if (e.command.name == "insertstring") {
+ var text = e.args;
+ if (this.mergeNextCommand === undefined)
+ this.mergeNextCommand = true;
+
+ shouldMerge = shouldMerge
+ && this.mergeNextCommand // previous command allows to coalesce with
+ && (!/\s/.test(text) || /\s/.test(prev.args)); // previous insertion was of same type
+
+ this.mergeNextCommand = true;
+ } else {
+ shouldMerge = shouldMerge
+ && mergeableCommands.indexOf(e.command.name) !== -1; // the command is mergeable
+ }
+
+ if (
+ this.$mergeUndoDeltas != "always"
+ && Date.now() - this.sequenceStartTime > 2000
+ ) {
+ shouldMerge = false; // the sequence is too long
+ }
+
+ if (shouldMerge)
+ this.session.mergeUndoDeltas = true;
+ else if (mergeableCommands.indexOf(e.command.name) !== -1)
+ this.sequenceStartTime = Date.now();
+ };
+ this.setKeyboardHandler = function(keyboardHandler, cb) {
+ if (keyboardHandler && typeof keyboardHandler === "string") {
+ this.$keybindingId = keyboardHandler;
+ var _self = this;
+ config.loadModule(["keybinding", keyboardHandler], function(module) {
+ if (_self.$keybindingId == keyboardHandler)
+ _self.keyBinding.setKeyboardHandler(module && module.handler);
+ cb && cb();
+ });
+ } else {
+ this.$keybindingId = null;
+ this.keyBinding.setKeyboardHandler(keyboardHandler);
+ cb && cb();
+ }
+ };
+ this.getKeyboardHandler = function() {
+ return this.keyBinding.getKeyboardHandler();
+ };
+ this.setSession = function(session) {
+ if (this.session == session)
+ return;
+ if (this.curOp) this.endOperation();
+ this.curOp = {};
+
+ var oldSession = this.session;
+ if (oldSession) {
+ this.session.off("change", this.$onDocumentChange);
+ this.session.off("changeMode", this.$onChangeMode);
+ this.session.off("tokenizerUpdate", this.$onTokenizerUpdate);
+ this.session.off("changeTabSize", this.$onChangeTabSize);
+ this.session.off("changeWrapLimit", this.$onChangeWrapLimit);
+ this.session.off("changeWrapMode", this.$onChangeWrapMode);
+ this.session.off("changeFold", this.$onChangeFold);
+ this.session.off("changeFrontMarker", this.$onChangeFrontMarker);
+ this.session.off("changeBackMarker", this.$onChangeBackMarker);
+ this.session.off("changeBreakpoint", this.$onChangeBreakpoint);
+ this.session.off("changeAnnotation", this.$onChangeAnnotation);
+ this.session.off("changeOverwrite", this.$onCursorChange);
+ this.session.off("changeScrollTop", this.$onScrollTopChange);
+ this.session.off("changeScrollLeft", this.$onScrollLeftChange);
+
+ var selection = this.session.getSelection();
+ selection.off("changeCursor", this.$onCursorChange);
+ selection.off("changeSelection", this.$onSelectionChange);
+ }
+
+ this.session = session;
+ if (session) {
+ this.$onDocumentChange = this.onDocumentChange.bind(this);
+ session.on("change", this.$onDocumentChange);
+ this.renderer.setSession(session);
+
+ this.$onChangeMode = this.onChangeMode.bind(this);
+ session.on("changeMode", this.$onChangeMode);
+
+ this.$onTokenizerUpdate = this.onTokenizerUpdate.bind(this);
+ session.on("tokenizerUpdate", this.$onTokenizerUpdate);
+
+ this.$onChangeTabSize = this.renderer.onChangeTabSize.bind(this.renderer);
+ session.on("changeTabSize", this.$onChangeTabSize);
+
+ this.$onChangeWrapLimit = this.onChangeWrapLimit.bind(this);
+ session.on("changeWrapLimit", this.$onChangeWrapLimit);
+
+ this.$onChangeWrapMode = this.onChangeWrapMode.bind(this);
+ session.on("changeWrapMode", this.$onChangeWrapMode);
+
+ this.$onChangeFold = this.onChangeFold.bind(this);
+ session.on("changeFold", this.$onChangeFold);
+
+ this.$onChangeFrontMarker = this.onChangeFrontMarker.bind(this);
+ this.session.on("changeFrontMarker", this.$onChangeFrontMarker);
+
+ this.$onChangeBackMarker = this.onChangeBackMarker.bind(this);
+ this.session.on("changeBackMarker", this.$onChangeBackMarker);
+
+ this.$onChangeBreakpoint = this.onChangeBreakpoint.bind(this);
+ this.session.on("changeBreakpoint", this.$onChangeBreakpoint);
+
+ this.$onChangeAnnotation = this.onChangeAnnotation.bind(this);
+ this.session.on("changeAnnotation", this.$onChangeAnnotation);
+
+ this.$onCursorChange = this.onCursorChange.bind(this);
+ this.session.on("changeOverwrite", this.$onCursorChange);
+
+ this.$onScrollTopChange = this.onScrollTopChange.bind(this);
+ this.session.on("changeScrollTop", this.$onScrollTopChange);
+
+ this.$onScrollLeftChange = this.onScrollLeftChange.bind(this);
+ this.session.on("changeScrollLeft", this.$onScrollLeftChange);
+
+ this.selection = session.getSelection();
+ this.selection.on("changeCursor", this.$onCursorChange);
+
+ this.$onSelectionChange = this.onSelectionChange.bind(this);
+ this.selection.on("changeSelection", this.$onSelectionChange);
+
+ this.onChangeMode();
+
+ this.$blockScrolling += 1;
+ this.onCursorChange();
+ this.$blockScrolling -= 1;
+
+ this.onScrollTopChange();
+ this.onScrollLeftChange();
+ this.onSelectionChange();
+ this.onChangeFrontMarker();
+ this.onChangeBackMarker();
+ this.onChangeBreakpoint();
+ this.onChangeAnnotation();
+ this.session.getUseWrapMode() && this.renderer.adjustWrapLimit();
+ this.renderer.updateFull();
+ } else {
+ this.selection = null;
+ this.renderer.setSession(session);
+ }
+
+ this._signal("changeSession", {
+ session: session,
+ oldSession: oldSession
+ });
+
+ this.curOp = null;
+
+ oldSession && oldSession._signal("changeEditor", {oldEditor: this});
+ session && session._signal("changeEditor", {editor: this});
+
+ if (session && session.bgTokenizer)
+ session.bgTokenizer.scheduleStart();
+ };
+ this.getSession = function() {
+ return this.session;
+ };
+ this.setValue = function(val, cursorPos) {
+ this.session.doc.setValue(val);
+
+ if (!cursorPos)
+ this.selectAll();
+ else if (cursorPos == 1)
+ this.navigateFileEnd();
+ else if (cursorPos == -1)
+ this.navigateFileStart();
+
+ return val;
+ };
+ this.getValue = function() {
+ return this.session.getValue();
+ };
+ this.getSelection = function() {
+ return this.selection;
+ };
+ this.resize = function(force) {
+ this.renderer.onResize(force);
+ };
+ this.setTheme = function(theme, cb) {
+ this.renderer.setTheme(theme, cb);
+ };
+ this.getTheme = function() {
+ return this.renderer.getTheme();
+ };
+ this.setStyle = function(style) {
+ this.renderer.setStyle(style);
+ };
+ this.unsetStyle = function(style) {
+ this.renderer.unsetStyle(style);
+ };
+ this.getFontSize = function () {
+ return this.getOption("fontSize") ||
+ dom.computedStyle(this.container, "fontSize");
+ };
+ this.setFontSize = function(size) {
+ this.setOption("fontSize", size);
+ };
+
+ this.$highlightBrackets = function() {
+ if (this.session.$bracketHighlight) {
+ this.session.removeMarker(this.session.$bracketHighlight);
+ this.session.$bracketHighlight = null;
+ }
+
+ if (this.$highlightPending) {
+ return;
+ }
+ var self = this;
+ this.$highlightPending = true;
+ setTimeout(function() {
+ self.$highlightPending = false;
+ var session = self.session;
+ if (!session || !session.bgTokenizer) return;
+ var pos = session.findMatchingBracket(self.getCursorPosition());
+ if (pos) {
+ var range = new Range(pos.row, pos.column, pos.row, pos.column + 1);
+ } else if (session.$mode.getMatching) {
+ var range = session.$mode.getMatching(self.session);
+ }
+ if (range)
+ session.$bracketHighlight = session.addMarker(range, "ace_bracket", "text");
+ }, 50);
+ };
+ this.$highlightTags = function() {
+ if (this.$highlightTagPending)
+ return;
+ var self = this;
+ this.$highlightTagPending = true;
+ setTimeout(function() {
+ self.$highlightTagPending = false;
+
+ var session = self.session;
+ if (!session || !session.bgTokenizer) return;
+
+ var pos = self.getCursorPosition();
+ var iterator = new TokenIterator(self.session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+
+ if (!token || !/\b(?:tag-open|tag-name)/.test(token.type)) {
+ session.removeMarker(session.$tagHighlight);
+ session.$tagHighlight = null;
+ return;
+ }
+
+ if (token.type.indexOf("tag-open") != -1) {
+ token = iterator.stepForward();
+ if (!token)
+ return;
+ }
+
+ var tag = token.value;
+ var depth = 0;
+ var prevToken = iterator.stepBackward();
+
+ if (prevToken.value == '<'){
+ do {
+ prevToken = token;
+ token = iterator.stepForward();
+
+ if (token && token.value === tag && token.type.indexOf('tag-name') !== -1) {
+ if (prevToken.value === '<'){
+ depth++;
+ } else if (prevToken.value === '</'){
+ depth--;
+ }
+ }
+
+ } while (token && depth >= 0);
+ } else {
+ do {
+ token = prevToken;
+ prevToken = iterator.stepBackward();
+
+ if (token && token.value === tag && token.type.indexOf('tag-name') !== -1) {
+ if (prevToken.value === '<') {
+ depth++;
+ } else if (prevToken.value === '</') {
+ depth--;
+ }
+ }
+ } while (prevToken && depth <= 0);
+ iterator.stepForward();
+ }
+
+ if (!token) {
+ session.removeMarker(session.$tagHighlight);
+ session.$tagHighlight = null;
+ return;
+ }
+
+ var row = iterator.getCurrentTokenRow();
+ var column = iterator.getCurrentTokenColumn();
+ var range = new Range(row, column, row, column+token.value.length);
+ var sbm = session.$backMarkers[session.$tagHighlight];
+ if (session.$tagHighlight && sbm != undefined && range.compareRange(sbm.range) !== 0) {
+ session.removeMarker(session.$tagHighlight);
+ session.$tagHighlight = null;
+ }
+
+ if (range && !session.$tagHighlight)
+ session.$tagHighlight = session.addMarker(range, "ace_bracket", "text");
+ }, 50);
+ };
+ this.focus = function() {
+ var _self = this;
+ setTimeout(function() {
+ _self.textInput.focus();
+ });
+ this.textInput.focus();
+ };
+ this.isFocused = function() {
+ return this.textInput.isFocused();
+ };
+ this.blur = function() {
+ this.textInput.blur();
+ };
+ this.onFocus = function(e) {
+ if (this.$isFocused)
+ return;
+ this.$isFocused = true;
+ this.renderer.showCursor();
+ this.renderer.visualizeFocus();
+ this._emit("focus", e);
+ };
+ this.onBlur = function(e) {
+ if (!this.$isFocused)
+ return;
+ this.$isFocused = false;
+ this.renderer.hideCursor();
+ this.renderer.visualizeBlur();
+ this._emit("blur", e);
+ };
+
+ this.$cursorChange = function() {
+ this.renderer.updateCursor();
+ };
+ this.onDocumentChange = function(delta) {
+ var wrap = this.session.$useWrapMode;
+ var lastRow = (delta.start.row == delta.end.row ? delta.end.row : Infinity);
+ this.renderer.updateLines(delta.start.row, lastRow, wrap);
+
+ this._signal("change", delta);
+ this.$cursorChange();
+ this.$updateHighlightActiveLine();
+ };
+
+ this.onTokenizerUpdate = function(e) {
+ var rows = e.data;
+ this.renderer.updateLines(rows.first, rows.last);
+ };
+
+
+ this.onScrollTopChange = function() {
+ this.renderer.scrollToY(this.session.getScrollTop());
+ };
+
+ this.onScrollLeftChange = function() {
+ this.renderer.scrollToX(this.session.getScrollLeft());
+ };
+ this.onCursorChange = function() {
+ this.$cursorChange();
+
+ if (!this.$blockScrolling) {
+ config.warn("Automatically scrolling cursor into view after selection change",
+ "this will be disabled in the next version",
+ "set editor.$blockScrolling = Infinity to disable this message"
+ );
+ this.renderer.scrollCursorIntoView();
+ }
+
+ this.$highlightBrackets();
+ this.$highlightTags();
+ this.$updateHighlightActiveLine();
+ this._signal("changeSelection");
+ };
+
+ this.$updateHighlightActiveLine = function() {
+ var session = this.getSession();
+
+ var highlight;
+ if (this.$highlightActiveLine) {
+ if ((this.$selectionStyle != "line" || !this.selection.isMultiLine()))
+ highlight = this.getCursorPosition();
+ if (this.renderer.$maxLines && this.session.getLength() === 1 && !(this.renderer.$minLines > 1))
+ highlight = false;
+ }
+
+ if (session.$highlightLineMarker && !highlight) {
+ session.removeMarker(session.$highlightLineMarker.id);
+ session.$highlightLineMarker = null;
+ } else if (!session.$highlightLineMarker && highlight) {
+ var range = new Range(highlight.row, highlight.column, highlight.row, Infinity);
+ range.id = session.addMarker(range, "ace_active-line", "screenLine");
+ session.$highlightLineMarker = range;
+ } else if (highlight) {
+ session.$highlightLineMarker.start.row = highlight.row;
+ session.$highlightLineMarker.end.row = highlight.row;
+ session.$highlightLineMarker.start.column = highlight.column;
+ session._signal("changeBackMarker");
+ }
+ };
+
+ this.onSelectionChange = function(e) {
+ var session = this.session;
+
+ if (session.$selectionMarker) {
+ session.removeMarker(session.$selectionMarker);
+ }
+ session.$selectionMarker = null;
+
+ if (!this.selection.isEmpty()) {
+ var range = this.selection.getRange();
+ var style = this.getSelectionStyle();
+ session.$selectionMarker = session.addMarker(range, "ace_selection", style);
+ } else {
+ this.$updateHighlightActiveLine();
+ }
+
+ var re = this.$highlightSelectedWord && this.$getSelectionHighLightRegexp();
+ this.session.highlight(re);
+
+ this._signal("changeSelection");
+ };
+
+ this.$getSelectionHighLightRegexp = function() {
+ var session = this.session;
+
+ var selection = this.getSelectionRange();
+ if (selection.isEmpty() || selection.isMultiLine())
+ return;
+
+ var startOuter = selection.start.column - 1;
+ var endOuter = selection.end.column + 1;
+ var line = session.getLine(selection.start.row);
+ var lineCols = line.length;
+ var needle = line.substring(Math.max(startOuter, 0),
+ Math.min(endOuter, lineCols));
+ if ((startOuter >= 0 && /^[\w\d]/.test(needle)) ||
+ (endOuter <= lineCols && /[\w\d]$/.test(needle)))
+ return;
+
+ needle = line.substring(selection.start.column, selection.end.column);
+ if (!/^[\w\d]+$/.test(needle))
+ return;
+
+ var re = this.$search.$assembleRegExp({
+ wholeWord: true,
+ caseSensitive: true,
+ needle: needle
+ });
+
+ return re;
+ };
+
+
+ this.onChangeFrontMarker = function() {
+ this.renderer.updateFrontMarkers();
+ };
+
+ this.onChangeBackMarker = function() {
+ this.renderer.updateBackMarkers();
+ };
+
+
+ this.onChangeBreakpoint = function() {
+ this.renderer.updateBreakpoints();
+ };
+
+ this.onChangeAnnotation = function() {
+ this.renderer.setAnnotations(this.session.getAnnotations());
+ };
+
+
+ this.onChangeMode = function(e) {
+ this.renderer.updateText();
+ this._emit("changeMode", e);
+ };
+
+
+ this.onChangeWrapLimit = function() {
+ this.renderer.updateFull();
+ };
+
+ this.onChangeWrapMode = function() {
+ this.renderer.onResize(true);
+ };
+
+
+ this.onChangeFold = function() {
+ this.$updateHighlightActiveLine();
+ this.renderer.updateFull();
+ };
+ this.getSelectedText = function() {
+ return this.session.getTextRange(this.getSelectionRange());
+ };
+ this.getCopyText = function() {
+ var text = this.getSelectedText();
+ this._signal("copy", text);
+ return text;
+ };
+ this.onCopy = function() {
+ this.commands.exec("copy", this);
+ };
+ this.onCut = function() {
+ this.commands.exec("cut", this);
+ };
+ this.onPaste = function(text, event) {
+ var e = {text: text, event: event};
+ this.commands.exec("paste", this, e);
+ };
+
+ this.$handlePaste = function(e) {
+ if (typeof e == "string")
+ e = {text: e};
+ this._signal("paste", e);
+ var text = e.text;
+ if (!this.inMultiSelectMode || this.inVirtualSelectionMode) {
+ this.insert(text);
+ } else {
+ var lines = text.split(/\r\n|\r|\n/);
+ var ranges = this.selection.rangeList.ranges;
+
+ if (lines.length > ranges.length || lines.length < 2 || !lines[1])
+ return this.commands.exec("insertstring", this, text);
+
+ for (var i = ranges.length; i--;) {
+ var range = ranges[i];
+ if (!range.isEmpty())
+ this.session.remove(range);
+
+ this.session.insert(range.start, lines[i]);
+ }
+ }
+ };
+
+ this.execCommand = function(command, args) {
+ return this.commands.exec(command, this, args);
+ };
+ this.insert = function(text, pasted) {
+ var session = this.session;
+ var mode = session.getMode();
+ var cursor = this.getCursorPosition();
+
+ if (this.getBehavioursEnabled() && !pasted) {
+ var transform = mode.transformAction(session.getState(cursor.row), 'insertion', this, session, text);
+ if (transform) {
+ if (text !== transform.text) {
+ this.session.mergeUndoDeltas = false;
+ this.$mergeNextCommand = false;
+ }
+ text = transform.text;
+
+ }
+ }
+
+ if (text == "\t")
+ text = this.session.getTabString();
+ if (!this.selection.isEmpty()) {
+ var range = this.getSelectionRange();
+ cursor = this.session.remove(range);
+ this.clearSelection();
+ }
+ else if (this.session.getOverwrite() && text.indexOf("\n") == -1) {
+ var range = new Range.fromPoints(cursor, cursor);
+ range.end.column += text.length;
+ this.session.remove(range);
+ }
+
+ if (text == "\n" || text == "\r\n") {
+ var line = session.getLine(cursor.row);
+ if (cursor.column > line.search(/\S|$/)) {
+ var d = line.substr(cursor.column).search(/\S|$/);
+ session.doc.removeInLine(cursor.row, cursor.column, cursor.column + d);
+ }
+ }
+ this.clearSelection();
+
+ var start = cursor.column;
+ var lineState = session.getState(cursor.row);
+ var line = session.getLine(cursor.row);
+ var shouldOutdent = mode.checkOutdent(lineState, line, text);
+ var end = session.insert(cursor, text);
+
+ if (transform && transform.selection) {
+ if (transform.selection.length == 2) { // Transform relative to the current column
+ this.selection.setSelectionRange(
+ new Range(cursor.row, start + transform.selection[0],
+ cursor.row, start + transform.selection[1]));
+ } else { // Transform relative to the current row.
+ this.selection.setSelectionRange(
+ new Range(cursor.row + transform.selection[0],
+ transform.selection[1],
+ cursor.row + transform.selection[2],
+ transform.selection[3]));
+ }
+ }
+
+ if (session.getDocument().isNewLine(text)) {
+ var lineIndent = mode.getNextLineIndent(lineState, line.slice(0, cursor.column), session.getTabString());
+
+ session.insert({row: cursor.row+1, column: 0}, lineIndent);
+ }
+ if (shouldOutdent)
+ mode.autoOutdent(lineState, session, cursor.row);
+ };
+
+ this.onTextInput = function(text) {
+ this.keyBinding.onTextInput(text);
+ };
+
+ this.onCommandKey = function(e, hashId, keyCode) {
+ this.keyBinding.onCommandKey(e, hashId, keyCode);
+ };
+ this.setOverwrite = function(overwrite) {
+ this.session.setOverwrite(overwrite);
+ };
+ this.getOverwrite = function() {
+ return this.session.getOverwrite();
+ };
+ this.toggleOverwrite = function() {
+ this.session.toggleOverwrite();
+ };
+ this.setScrollSpeed = function(speed) {
+ this.setOption("scrollSpeed", speed);
+ };
+ this.getScrollSpeed = function() {
+ return this.getOption("scrollSpeed");
+ };
+ this.setDragDelay = function(dragDelay) {
+ this.setOption("dragDelay", dragDelay);
+ };
+ this.getDragDelay = function() {
+ return this.getOption("dragDelay");
+ };
+ this.setSelectionStyle = function(val) {
+ this.setOption("selectionStyle", val);
+ };
+ this.getSelectionStyle = function() {
+ return this.getOption("selectionStyle");
+ };
+ this.setHighlightActiveLine = function(shouldHighlight) {
+ this.setOption("highlightActiveLine", shouldHighlight);
+ };
+ this.getHighlightActiveLine = function() {
+ return this.getOption("highlightActiveLine");
+ };
+ this.setHighlightGutterLine = function(shouldHighlight) {
+ this.setOption("highlightGutterLine", shouldHighlight);
+ };
+
+ this.getHighlightGutterLine = function() {
+ return this.getOption("highlightGutterLine");
+ };
+ this.setHighlightSelectedWord = function(shouldHighlight) {
+ this.setOption("highlightSelectedWord", shouldHighlight);
+ };
+ this.getHighlightSelectedWord = function() {
+ return this.$highlightSelectedWord;
+ };
+
+ this.setAnimatedScroll = function(shouldAnimate){
+ this.renderer.setAnimatedScroll(shouldAnimate);
+ };
+
+ this.getAnimatedScroll = function(){
+ return this.renderer.getAnimatedScroll();
+ };
+ this.setShowInvisibles = function(showInvisibles) {
+ this.renderer.setShowInvisibles(showInvisibles);
+ };
+ this.getShowInvisibles = function() {
+ return this.renderer.getShowInvisibles();
+ };
+
+ this.setDisplayIndentGuides = function(display) {
+ this.renderer.setDisplayIndentGuides(display);
+ };
+
+ this.getDisplayIndentGuides = function() {
+ return this.renderer.getDisplayIndentGuides();
+ };
+ this.setShowPrintMargin = function(showPrintMargin) {
+ this.renderer.setShowPrintMargin(showPrintMargin);
+ };
+ this.getShowPrintMargin = function() {
+ return this.renderer.getShowPrintMargin();
+ };
+ this.setPrintMarginColumn = function(showPrintMargin) {
+ this.renderer.setPrintMarginColumn(showPrintMargin);
+ };
+ this.getPrintMarginColumn = function() {
+ return this.renderer.getPrintMarginColumn();
+ };
+ this.setReadOnly = function(readOnly) {
+ this.setOption("readOnly", readOnly);
+ };
+ this.getReadOnly = function() {
+ return this.getOption("readOnly");
+ };
+ this.setBehavioursEnabled = function (enabled) {
+ this.setOption("behavioursEnabled", enabled);
+ };
+ this.getBehavioursEnabled = function () {
+ return this.getOption("behavioursEnabled");
+ };
+ this.setWrapBehavioursEnabled = function (enabled) {
+ this.setOption("wrapBehavioursEnabled", enabled);
+ };
+ this.getWrapBehavioursEnabled = function () {
+ return this.getOption("wrapBehavioursEnabled");
+ };
+ this.setShowFoldWidgets = function(show) {
+ this.setOption("showFoldWidgets", show);
+
+ };
+ this.getShowFoldWidgets = function() {
+ return this.getOption("showFoldWidgets");
+ };
+
+ this.setFadeFoldWidgets = function(fade) {
+ this.setOption("fadeFoldWidgets", fade);
+ };
+
+ this.getFadeFoldWidgets = function() {
+ return this.getOption("fadeFoldWidgets");
+ };
+ this.remove = function(dir) {
+ if (this.selection.isEmpty()){
+ if (dir == "left")
+ this.selection.selectLeft();
+ else
+ this.selection.selectRight();
+ }
+
+ var range = this.getSelectionRange();
+ if (this.getBehavioursEnabled()) {
+ var session = this.session;
+ var state = session.getState(range.start.row);
+ var new_range = session.getMode().transformAction(state, 'deletion', this, session, range);
+
+ if (range.end.column === 0) {
+ var text = session.getTextRange(range);
+ if (text[text.length - 1] == "\n") {
+ var line = session.getLine(range.end.row);
+ if (/^\s+$/.test(line)) {
+ range.end.column = line.length;
+ }
+ }
+ }
+ if (new_range)
+ range = new_range;
+ }
+
+ this.session.remove(range);
+ this.clearSelection();
+ };
+ this.removeWordRight = function() {
+ if (this.selection.isEmpty())
+ this.selection.selectWordRight();
+
+ this.session.remove(this.getSelectionRange());
+ this.clearSelection();
+ };
+ this.removeWordLeft = function() {
+ if (this.selection.isEmpty())
+ this.selection.selectWordLeft();
+
+ this.session.remove(this.getSelectionRange());
+ this.clearSelection();
+ };
+ this.removeToLineStart = function() {
+ if (this.selection.isEmpty())
+ this.selection.selectLineStart();
+
+ this.session.remove(this.getSelectionRange());
+ this.clearSelection();
+ };
+ this.removeToLineEnd = function() {
+ if (this.selection.isEmpty())
+ this.selection.selectLineEnd();
+
+ var range = this.getSelectionRange();
+ if (range.start.column == range.end.column && range.start.row == range.end.row) {
+ range.end.column = 0;
+ range.end.row++;
+ }
+
+ this.session.remove(range);
+ this.clearSelection();
+ };
+ this.splitLine = function() {
+ if (!this.selection.isEmpty()) {
+ this.session.remove(this.getSelectionRange());
+ this.clearSelection();
+ }
+
+ var cursor = this.getCursorPosition();
+ this.insert("\n");
+ this.moveCursorToPosition(cursor);
+ };
+ this.transposeLetters = function() {
+ if (!this.selection.isEmpty()) {
+ return;
+ }
+
+ var cursor = this.getCursorPosition();
+ var column = cursor.column;
+ if (column === 0)
+ return;
+
+ var line = this.session.getLine(cursor.row);
+ var swap, range;
+ if (column < line.length) {
+ swap = line.charAt(column) + line.charAt(column-1);
+ range = new Range(cursor.row, column-1, cursor.row, column+1);
+ }
+ else {
+ swap = line.charAt(column-1) + line.charAt(column-2);
+ range = new Range(cursor.row, column-2, cursor.row, column);
+ }
+ this.session.replace(range, swap);
+ this.session.selection.moveToPosition(range.end);
+ };
+ this.toLowerCase = function() {
+ var originalRange = this.getSelectionRange();
+ if (this.selection.isEmpty()) {
+ this.selection.selectWord();
+ }
+
+ var range = this.getSelectionRange();
+ var text = this.session.getTextRange(range);
+ this.session.replace(range, text.toLowerCase());
+ this.selection.setSelectionRange(originalRange);
+ };
+ this.toUpperCase = function() {
+ var originalRange = this.getSelectionRange();
+ if (this.selection.isEmpty()) {
+ this.selection.selectWord();
+ }
+
+ var range = this.getSelectionRange();
+ var text = this.session.getTextRange(range);
+ this.session.replace(range, text.toUpperCase());
+ this.selection.setSelectionRange(originalRange);
+ };
+ this.indent = function() {
+ var session = this.session;
+ var range = this.getSelectionRange();
+
+ if (range.start.row < range.end.row) {
+ var rows = this.$getSelectedRows();
+ session.indentRows(rows.first, rows.last, "\t");
+ return;
+ } else if (range.start.column < range.end.column) {
+ var text = session.getTextRange(range);
+ if (!/^\s+$/.test(text)) {
+ var rows = this.$getSelectedRows();
+ session.indentRows(rows.first, rows.last, "\t");
+ return;
+ }
+ }
+
+ var line = session.getLine(range.start.row);
+ var position = range.start;
+ var size = session.getTabSize();
+ var column = session.documentToScreenColumn(position.row, position.column);
+
+ if (this.session.getUseSoftTabs()) {
+ var count = (size - column % size);
+ var indentString = lang.stringRepeat(" ", count);
+ } else {
+ var count = column % size;
+ while (line[range.start.column - 1] == " " && count) {
+ range.start.column--;
+ count--;
+ }
+ this.selection.setSelectionRange(range);
+ indentString = "\t";
+ }
+ return this.insert(indentString);
+ };
+ this.blockIndent = function() {
+ var rows = this.$getSelectedRows();
+ this.session.indentRows(rows.first, rows.last, "\t");
+ };
+ this.blockOutdent = function() {
+ var selection = this.session.getSelection();
+ this.session.outdentRows(selection.getRange());
+ };
+ this.sortLines = function() {
+ var rows = this.$getSelectedRows();
+ var session = this.session;
+
+ var lines = [];
+ for (i = rows.first; i <= rows.last; i++)
+ lines.push(session.getLine(i));
+
+ lines.sort(function(a, b) {
+ if (a.toLowerCase() < b.toLowerCase()) return -1;
+ if (a.toLowerCase() > b.toLowerCase()) return 1;
+ return 0;
+ });
+
+ var deleteRange = new Range(0, 0, 0, 0);
+ for (var i = rows.first; i <= rows.last; i++) {
+ var line = session.getLine(i);
+ deleteRange.start.row = i;
+ deleteRange.end.row = i;
+ deleteRange.end.column = line.length;
+ session.replace(deleteRange, lines[i-rows.first]);
+ }
+ };
+ this.toggleCommentLines = function() {
+ var state = this.session.getState(this.getCursorPosition().row);
+ var rows = this.$getSelectedRows();
+ this.session.getMode().toggleCommentLines(state, this.session, rows.first, rows.last);
+ };
+
+ this.toggleBlockComment = function() {
+ var cursor = this.getCursorPosition();
+ var state = this.session.getState(cursor.row);
+ var range = this.getSelectionRange();
+ this.session.getMode().toggleBlockComment(state, this.session, range, cursor);
+ };
+ this.getNumberAt = function(row, column) {
+ var _numberRx = /[\-]?[0-9]+(?:\.[0-9]+)?/g;
+ _numberRx.lastIndex = 0;
+
+ var s = this.session.getLine(row);
+ while (_numberRx.lastIndex < column) {
+ var m = _numberRx.exec(s);
+ if(m.index <= column && m.index+m[0].length >= column){
+ var number = {
+ value: m[0],
+ start: m.index,
+ end: m.index+m[0].length
+ };
+ return number;
+ }
+ }
+ return null;
+ };
+ this.modifyNumber = function(amount) {
+ var row = this.selection.getCursor().row;
+ var column = this.selection.getCursor().column;
+ var charRange = new Range(row, column-1, row, column);
+
+ var c = this.session.getTextRange(charRange);
+ if (!isNaN(parseFloat(c)) && isFinite(c)) {
+ var nr = this.getNumberAt(row, column);
+ if (nr) {
+ var fp = nr.value.indexOf(".") >= 0 ? nr.start + nr.value.indexOf(".") + 1 : nr.end;
+ var decimals = nr.start + nr.value.length - fp;
+
+ var t = parseFloat(nr.value);
+ t *= Math.pow(10, decimals);
+
+
+ if(fp !== nr.end && column < fp){
+ amount *= Math.pow(10, nr.end - column - 1);
+ } else {
+ amount *= Math.pow(10, nr.end - column);
+ }
+
+ t += amount;
+ t /= Math.pow(10, decimals);
+ var nnr = t.toFixed(decimals);
+ var replaceRange = new Range(row, nr.start, row, nr.end);
+ this.session.replace(replaceRange, nnr);
+ this.moveCursorTo(row, Math.max(nr.start +1, column + nnr.length - nr.value.length));
+
+ }
+ }
+ };
+ this.removeLines = function() {
+ var rows = this.$getSelectedRows();
+ this.session.removeFullLines(rows.first, rows.last);
+ this.clearSelection();
+ };
+
+ this.duplicateSelection = function() {
+ var sel = this.selection;
+ var doc = this.session;
+ var range = sel.getRange();
+ var reverse = sel.isBackwards();
+ if (range.isEmpty()) {
+ var row = range.start.row;
+ doc.duplicateLines(row, row);
+ } else {
+ var point = reverse ? range.start : range.end;
+ var endPoint = doc.insert(point, doc.getTextRange(range), false);
+ range.start = point;
+ range.end = endPoint;
+
+ sel.setSelectionRange(range, reverse);
+ }
+ };
+ this.moveLinesDown = function() {
+ this.$moveLines(1, false);
+ };
+ this.moveLinesUp = function() {
+ this.$moveLines(-1, false);
+ };
+ this.moveText = function(range, toPosition, copy) {
+ return this.session.moveText(range, toPosition, copy);
+ };
+ this.copyLinesUp = function() {
+ this.$moveLines(-1, true);
+ };
+ this.copyLinesDown = function() {
+ this.$moveLines(1, true);
+ };
+ this.$moveLines = function(dir, copy) {
+ var rows, moved;
+ var selection = this.selection;
+ if (!selection.inMultiSelectMode || this.inVirtualSelectionMode) {
+ var range = selection.toOrientedRange();
+ rows = this.$getSelectedRows(range);
+ moved = this.session.$moveLines(rows.first, rows.last, copy ? 0 : dir);
+ if (copy && dir == -1) moved = 0;
+ range.moveBy(moved, 0);
+ selection.fromOrientedRange(range);
+ } else {
+ var ranges = selection.rangeList.ranges;
+ selection.rangeList.detach(this.session);
+ this.inVirtualSelectionMode = true;
+
+ var diff = 0;
+ var totalDiff = 0;
+ var l = ranges.length;
+ for (var i = 0; i < l; i++) {
+ var rangeIndex = i;
+ ranges[i].moveBy(diff, 0);
+ rows = this.$getSelectedRows(ranges[i]);
+ var first = rows.first;
+ var last = rows.last;
+ while (++i < l) {
+ if (totalDiff) ranges[i].moveBy(totalDiff, 0);
+ var subRows = this.$getSelectedRows(ranges[i]);
+ if (copy && subRows.first != last)
+ break;
+ else if (!copy && subRows.first > last + 1)
+ break;
+ last = subRows.last;
+ }
+ i--;
+ diff = this.session.$moveLines(first, last, copy ? 0 : dir);
+ if (copy && dir == -1) rangeIndex = i + 1;
+ while (rangeIndex <= i) {
+ ranges[rangeIndex].moveBy(diff, 0);
+ rangeIndex++;
+ }
+ if (!copy) diff = 0;
+ totalDiff += diff;
+ }
+
+ selection.fromOrientedRange(selection.ranges[0]);
+ selection.rangeList.attach(this.session);
+ this.inVirtualSelectionMode = false;
+ }
+ };
+ this.$getSelectedRows = function(range) {
+ range = (range || this.getSelectionRange()).collapseRows();
+
+ return {
+ first: this.session.getRowFoldStart(range.start.row),
+ last: this.session.getRowFoldEnd(range.end.row)
+ };
+ };
+
+ this.onCompositionStart = function(text) {
+ this.renderer.showComposition(this.getCursorPosition());
+ };
+
+ this.onCompositionUpdate = function(text) {
+ this.renderer.setCompositionText(text);
+ };
+
+ this.onCompositionEnd = function() {
+ this.renderer.hideComposition();
+ };
+ this.getFirstVisibleRow = function() {
+ return this.renderer.getFirstVisibleRow();
+ };
+ this.getLastVisibleRow = function() {
+ return this.renderer.getLastVisibleRow();
+ };
+ this.isRowVisible = function(row) {
+ return (row >= this.getFirstVisibleRow() && row <= this.getLastVisibleRow());
+ };
+ this.isRowFullyVisible = function(row) {
+ return (row >= this.renderer.getFirstFullyVisibleRow() && row <= this.renderer.getLastFullyVisibleRow());
+ };
+ this.$getVisibleRowCount = function() {
+ return this.renderer.getScrollBottomRow() - this.renderer.getScrollTopRow() + 1;
+ };
+
+ this.$moveByPage = function(dir, select) {
+ var renderer = this.renderer;
+ var config = this.renderer.layerConfig;
+ var rows = dir * Math.floor(config.height / config.lineHeight);
+
+ this.$blockScrolling++;
+ if (select === true) {
+ this.selection.$moveSelection(function(){
+ this.moveCursorBy(rows, 0);
+ });
+ } else if (select === false) {
+ this.selection.moveCursorBy(rows, 0);
+ this.selection.clearSelection();
+ }
+ this.$blockScrolling--;
+
+ var scrollTop = renderer.scrollTop;
+
+ renderer.scrollBy(0, rows * config.lineHeight);
+ if (select != null)
+ renderer.scrollCursorIntoView(null, 0.5);
+
+ renderer.animateScrolling(scrollTop);
+ };
+ this.selectPageDown = function() {
+ this.$moveByPage(1, true);
+ };
+ this.selectPageUp = function() {
+ this.$moveByPage(-1, true);
+ };
+ this.gotoPageDown = function() {
+ this.$moveByPage(1, false);
+ };
+ this.gotoPageUp = function() {
+ this.$moveByPage(-1, false);
+ };
+ this.scrollPageDown = function() {
+ this.$moveByPage(1);
+ };
+ this.scrollPageUp = function() {
+ this.$moveByPage(-1);
+ };
+ this.scrollToRow = function(row) {
+ this.renderer.scrollToRow(row);
+ };
+ this.scrollToLine = function(line, center, animate, callback) {
+ this.renderer.scrollToLine(line, center, animate, callback);
+ };
+ this.centerSelection = function() {
+ var range = this.getSelectionRange();
+ var pos = {
+ row: Math.floor(range.start.row + (range.end.row - range.start.row) / 2),
+ column: Math.floor(range.start.column + (range.end.column - range.start.column) / 2)
+ };
+ this.renderer.alignCursor(pos, 0.5);
+ };
+ this.getCursorPosition = function() {
+ return this.selection.getCursor();
+ };
+ this.getCursorPositionScreen = function() {
+ return this.session.documentToScreenPosition(this.getCursorPosition());
+ };
+ this.getSelectionRange = function() {
+ return this.selection.getRange();
+ };
+ this.selectAll = function() {
+ this.$blockScrolling += 1;
+ this.selection.selectAll();
+ this.$blockScrolling -= 1;
+ };
+ this.clearSelection = function() {
+ this.selection.clearSelection();
+ };
+ this.moveCursorTo = function(row, column) {
+ this.selection.moveCursorTo(row, column);
+ };
+ this.moveCursorToPosition = function(pos) {
+ this.selection.moveCursorToPosition(pos);
+ };
+ this.jumpToMatching = function(select, expand) {
+ var cursor = this.getCursorPosition();
+ var iterator = new TokenIterator(this.session, cursor.row, cursor.column);
+ var prevToken = iterator.getCurrentToken();
+ var token = prevToken || iterator.stepForward();
+
+ if (!token) return;
+ var matchType;
+ var found = false;
+ var depth = {};
+ var i = cursor.column - token.start;
+ var bracketType;
+ var brackets = {
+ ")": "(",
+ "(": "(",
+ "]": "[",
+ "[": "[",
+ "{": "{",
+ "}": "{"
+ };
+
+ do {
+ if (token.value.match(/[{}()\[\]]/g)) {
+ for (; i < token.value.length && !found; i++) {
+ if (!brackets[token.value[i]]) {
+ continue;
+ }
+
+ bracketType = brackets[token.value[i]] + '.' + token.type.replace("rparen", "lparen");
+
+ if (isNaN(depth[bracketType])) {
+ depth[bracketType] = 0;
+ }
+
+ switch (token.value[i]) {
+ case '(':
+ case '[':
+ case '{':
+ depth[bracketType]++;
+ break;
+ case ')':
+ case ']':
+ case '}':
+ depth[bracketType]--;
+
+ if (depth[bracketType] === -1) {
+ matchType = 'bracket';
+ found = true;
+ }
+ break;
+ }
+ }
+ }
+ else if (token && token.type.indexOf('tag-name') !== -1) {
+ if (isNaN(depth[token.value])) {
+ depth[token.value] = 0;
+ }
+
+ if (prevToken.value === '<') {
+ depth[token.value]++;
+ }
+ else if (prevToken.value === '</') {
+ depth[token.value]--;
+ }
+
+ if (depth[token.value] === -1) {
+ matchType = 'tag';
+ found = true;
+ }
+ }
+
+ if (!found) {
+ prevToken = token;
+ token = iterator.stepForward();
+ i = 0;
+ }
+ } while (token && !found);
+ if (!matchType)
+ return;
+
+ var range, pos;
+ if (matchType === 'bracket') {
+ range = this.session.getBracketRange(cursor);
+ if (!range) {
+ range = new Range(
+ iterator.getCurrentTokenRow(),
+ iterator.getCurrentTokenColumn() + i - 1,
+ iterator.getCurrentTokenRow(),
+ iterator.getCurrentTokenColumn() + i - 1
+ );
+ pos = range.start;
+ if (expand || pos.row === cursor.row && Math.abs(pos.column - cursor.column) < 2)
+ range = this.session.getBracketRange(pos);
+ }
+ }
+ else if (matchType === 'tag') {
+ if (token && token.type.indexOf('tag-name') !== -1)
+ var tag = token.value;
+ else
+ return;
+
+ range = new Range(
+ iterator.getCurrentTokenRow(),
+ iterator.getCurrentTokenColumn() - 2,
+ iterator.getCurrentTokenRow(),
+ iterator.getCurrentTokenColumn() - 2
+ );
+ if (range.compare(cursor.row, cursor.column) === 0) {
+ found = false;
+ do {
+ token = prevToken;
+ prevToken = iterator.stepBackward();
+
+ if (prevToken) {
+ if (prevToken.type.indexOf('tag-close') !== -1) {
+ range.setEnd(iterator.getCurrentTokenRow(), iterator.getCurrentTokenColumn() + 1);
+ }
+
+ if (token.value === tag && token.type.indexOf('tag-name') !== -1) {
+ if (prevToken.value === '<') {
+ depth[tag]++;
+ }
+ else if (prevToken.value === '</') {
+ depth[tag]--;
+ }
+
+ if (depth[tag] === 0)
+ found = true;
+ }
+ }
+ } while (prevToken && !found);
+ }
+ if (token && token.type.indexOf('tag-name')) {
+ pos = range.start;
+ if (pos.row == cursor.row && Math.abs(pos.column - cursor.column) < 2)
+ pos = range.end;
+ }
+ }
+
+ pos = range && range.cursor || pos;
+ if (pos) {
+ if (select) {
+ if (range && expand) {
+ this.selection.setRange(range);
+ } else if (range && range.isEqual(this.getSelectionRange())) {
+ this.clearSelection();
+ } else {
+ this.selection.selectTo(pos.row, pos.column);
+ }
+ } else {
+ this.selection.moveTo(pos.row, pos.column);
+ }
+ }
+ };
+ this.gotoLine = function(lineNumber, column, animate) {
+ this.selection.clearSelection();
+ this.session.unfold({row: lineNumber - 1, column: column || 0});
+
+ this.$blockScrolling += 1;
+ this.exitMultiSelectMode && this.exitMultiSelectMode();
+ this.moveCursorTo(lineNumber - 1, column || 0);
+ this.$blockScrolling -= 1;
+
+ if (!this.isRowFullyVisible(lineNumber - 1))
+ this.scrollToLine(lineNumber - 1, true, animate);
+ };
+ this.navigateTo = function(row, column) {
+ this.selection.moveTo(row, column);
+ };
+ this.navigateUp = function(times) {
+ if (this.selection.isMultiLine() && !this.selection.isBackwards()) {
+ var selectionStart = this.selection.anchor.getPosition();
+ return this.moveCursorToPosition(selectionStart);
+ }
+ this.selection.clearSelection();
+ this.selection.moveCursorBy(-times || -1, 0);
+ };
+ this.navigateDown = function(times) {
+ if (this.selection.isMultiLine() && this.selection.isBackwards()) {
+ var selectionEnd = this.selection.anchor.getPosition();
+ return this.moveCursorToPosition(selectionEnd);
+ }
+ this.selection.clearSelection();
+ this.selection.moveCursorBy(times || 1, 0);
+ };
+ this.navigateLeft = function(times) {
+ if (!this.selection.isEmpty()) {
+ var selectionStart = this.getSelectionRange().start;
+ this.moveCursorToPosition(selectionStart);
+ }
+ else {
+ times = times || 1;
+ while (times--) {
+ this.selection.moveCursorLeft();
+ }
+ }
+ this.clearSelection();
+ };
+ this.navigateRight = function(times) {
+ if (!this.selection.isEmpty()) {
+ var selectionEnd = this.getSelectionRange().end;
+ this.moveCursorToPosition(selectionEnd);
+ }
+ else {
+ times = times || 1;
+ while (times--) {
+ this.selection.moveCursorRight();
+ }
+ }
+ this.clearSelection();
+ };
+ this.navigateLineStart = function() {
+ this.selection.moveCursorLineStart();
+ this.clearSelection();
+ };
+ this.navigateLineEnd = function() {
+ this.selection.moveCursorLineEnd();
+ this.clearSelection();
+ };
+ this.navigateFileEnd = function() {
+ this.selection.moveCursorFileEnd();
+ this.clearSelection();
+ };
+ this.navigateFileStart = function() {
+ this.selection.moveCursorFileStart();
+ this.clearSelection();
+ };
+ this.navigateWordRight = function() {
+ this.selection.moveCursorWordRight();
+ this.clearSelection();
+ };
+ this.navigateWordLeft = function() {
+ this.selection.moveCursorWordLeft();
+ this.clearSelection();
+ };
+ this.replace = function(replacement, options) {
+ if (options)
+ this.$search.set(options);
+
+ var range = this.$search.find(this.session);
+ var replaced = 0;
+ if (!range)
+ return replaced;
+
+ if (this.$tryReplace(range, replacement)) {
+ replaced = 1;
+ }
+ if (range !== null) {
+ this.selection.setSelectionRange(range);
+ this.renderer.scrollSelectionIntoView(range.start, range.end);
+ }
+
+ return replaced;
+ };
+ this.replaceAll = function(replacement, options) {
+ if (options) {
+ this.$search.set(options);
+ }
+
+ var ranges = this.$search.findAll(this.session);
+ var replaced = 0;
+ if (!ranges.length)
+ return replaced;
+
+ this.$blockScrolling += 1;
+
+ var selection = this.getSelectionRange();
+ this.selection.moveTo(0, 0);
+
+ for (var i = ranges.length - 1; i >= 0; --i) {
+ if(this.$tryReplace(ranges[i], replacement)) {
+ replaced++;
+ }
+ }
+
+ this.selection.setSelectionRange(selection);
+ this.$blockScrolling -= 1;
+
+ return replaced;
+ };
+
+ this.$tryReplace = function(range, replacement) {
+ var input = this.session.getTextRange(range);
+ replacement = this.$search.replace(input, replacement);
+ if (replacement !== null) {
+ range.end = this.session.replace(range, replacement);
+ return range;
+ } else {
+ return null;
+ }
+ };
+ this.getLastSearchOptions = function() {
+ return this.$search.getOptions();
+ };
+ this.find = function(needle, options, animate) {
+ if (!options)
+ options = {};
+
+ if (typeof needle == "string" || needle instanceof RegExp)
+ options.needle = needle;
+ else if (typeof needle == "object")
+ oop.mixin(options, needle);
+
+ var range = this.selection.getRange();
+ if (options.needle == null) {
+ needle = this.session.getTextRange(range)
+ || this.$search.$options.needle;
+ if (!needle) {
+ range = this.session.getWordRange(range.start.row, range.start.column);
+ needle = this.session.getTextRange(range);
+ }
+ this.$search.set({needle: needle});
+ }
+
+ this.$search.set(options);
+ if (!options.start)
+ this.$search.set({start: range});
+
+ var newRange = this.$search.find(this.session);
+ if (options.preventScroll)
+ return newRange;
+ if (newRange) {
+ this.revealRange(newRange, animate);
+ return newRange;
+ }
+ if (options.backwards)
+ range.start = range.end;
+ else
+ range.end = range.start;
+ this.selection.setRange(range);
+ };
+ this.findNext = function(options, animate) {
+ this.find({skipCurrent: true, backwards: false}, options, animate);
+ };
+ this.findPrevious = function(options, animate) {
+ this.find(options, {skipCurrent: true, backwards: true}, animate);
+ };
+
+ this.revealRange = function(range, animate) {
+ this.$blockScrolling += 1;
+ this.session.unfold(range);
+ this.selection.setSelectionRange(range);
+ this.$blockScrolling -= 1;
+
+ var scrollTop = this.renderer.scrollTop;
+ this.renderer.scrollSelectionIntoView(range.start, range.end, 0.5);
+ if (animate !== false)
+ this.renderer.animateScrolling(scrollTop);
+ };
+ this.undo = function() {
+ this.$blockScrolling++;
+ this.session.getUndoManager().undo();
+ this.$blockScrolling--;
+ this.renderer.scrollCursorIntoView(null, 0.5);
+ };
+ this.redo = function() {
+ this.$blockScrolling++;
+ this.session.getUndoManager().redo();
+ this.$blockScrolling--;
+ this.renderer.scrollCursorIntoView(null, 0.5);
+ };
+ this.destroy = function() {
+ this.renderer.destroy();
+ this._signal("destroy", this);
+ if (this.session) {
+ this.session.destroy();
+ }
+ };
+ this.setAutoScrollEditorIntoView = function(enable) {
+ if (!enable)
+ return;
+ var rect;
+ var self = this;
+ var shouldScroll = false;
+ if (!this.$scrollAnchor)
+ this.$scrollAnchor = document.createElement("div");
+ var scrollAnchor = this.$scrollAnchor;
+ scrollAnchor.style.cssText = "position:absolute";
+ this.container.insertBefore(scrollAnchor, this.container.firstChild);
+ var onChangeSelection = this.on("changeSelection", function() {
+ shouldScroll = true;
+ });
+ var onBeforeRender = this.renderer.on("beforeRender", function() {
+ if (shouldScroll)
+ rect = self.renderer.container.getBoundingClientRect();
+ });
+ var onAfterRender = this.renderer.on("afterRender", function() {
+ if (shouldScroll && rect && (self.isFocused()
+ || self.searchBox && self.searchBox.isFocused())
+ ) {
+ var renderer = self.renderer;
+ var pos = renderer.$cursorLayer.$pixelPos;
+ var config = renderer.layerConfig;
+ var top = pos.top - config.offset;
+ if (pos.top >= 0 && top + rect.top < 0) {
+ shouldScroll = true;
+ } else if (pos.top < config.height &&
+ pos.top + rect.top + config.lineHeight > window.innerHeight) {
+ shouldScroll = false;
+ } else {
+ shouldScroll = null;
+ }
+ if (shouldScroll != null) {
+ scrollAnchor.style.top = top + "px";
+ scrollAnchor.style.left = pos.left + "px";
+ scrollAnchor.style.height = config.lineHeight + "px";
+ scrollAnchor.scrollIntoView(shouldScroll);
+ }
+ shouldScroll = rect = null;
+ }
+ });
+ this.setAutoScrollEditorIntoView = function(enable) {
+ if (enable)
+ return;
+ delete this.setAutoScrollEditorIntoView;
+ this.off("changeSelection", onChangeSelection);
+ this.renderer.off("afterRender", onAfterRender);
+ this.renderer.off("beforeRender", onBeforeRender);
+ };
+ };
+
+
+ this.$resetCursorStyle = function() {
+ var style = this.$cursorStyle || "ace";
+ var cursorLayer = this.renderer.$cursorLayer;
+ if (!cursorLayer)
+ return;
+ cursorLayer.setSmoothBlinking(/smooth/.test(style));
+ cursorLayer.isBlinking = !this.$readOnly && style != "wide";
+ dom.setCssClass(cursorLayer.element, "ace_slim-cursors", /slim/.test(style));
+ };
+
+}).call(Editor.prototype);
+
+
+
+config.defineOptions(Editor.prototype, "editor", {
+ selectionStyle: {
+ set: function(style) {
+ this.onSelectionChange();
+ this._signal("changeSelectionStyle", {data: style});
+ },
+ initialValue: "line"
+ },
+ highlightActiveLine: {
+ set: function() {this.$updateHighlightActiveLine();},
+ initialValue: true
+ },
+ highlightSelectedWord: {
+ set: function(shouldHighlight) {this.$onSelectionChange();},
+ initialValue: true
+ },
+ readOnly: {
+ set: function(readOnly) {
+ this.$resetCursorStyle();
+ },
+ initialValue: false
+ },
+ cursorStyle: {
+ set: function(val) { this.$resetCursorStyle(); },
+ values: ["ace", "slim", "smooth", "wide"],
+ initialValue: "ace"
+ },
+ mergeUndoDeltas: {
+ values: [false, true, "always"],
+ initialValue: true
+ },
+ behavioursEnabled: {initialValue: true},
+ wrapBehavioursEnabled: {initialValue: true},
+ autoScrollEditorIntoView: {
+ set: function(val) {this.setAutoScrollEditorIntoView(val)}
+ },
+ keyboardHandler: {
+ set: function(val) { this.setKeyboardHandler(val); },
+ get: function() { return this.keybindingId; },
+ handlesSet: true
+ },
+
+ hScrollBarAlwaysVisible: "renderer",
+ vScrollBarAlwaysVisible: "renderer",
+ highlightGutterLine: "renderer",
+ animatedScroll: "renderer",
+ showInvisibles: "renderer",
+ showPrintMargin: "renderer",
+ printMarginColumn: "renderer",
+ printMargin: "renderer",
+ fadeFoldWidgets: "renderer",
+ showFoldWidgets: "renderer",
+ showLineNumbers: "renderer",
+ showGutter: "renderer",
+ displayIndentGuides: "renderer",
+ fontSize: "renderer",
+ fontFamily: "renderer",
+ maxLines: "renderer",
+ minLines: "renderer",
+ scrollPastEnd: "renderer",
+ fixedWidthGutter: "renderer",
+ theme: "renderer",
+
+ scrollSpeed: "$mouseHandler",
+ dragDelay: "$mouseHandler",
+ dragEnabled: "$mouseHandler",
+ focusTimout: "$mouseHandler",
+ tooltipFollowsMouse: "$mouseHandler",
+
+ firstLineNumber: "session",
+ overwrite: "session",
+ newLineMode: "session",
+ useWorker: "session",
+ useSoftTabs: "session",
+ tabSize: "session",
+ wrap: "session",
+ indentedSoftWrap: "session",
+ foldStyle: "session",
+ mode: "session"
+});
+
+exports.Editor = Editor;
+});
+
+ace.define("ace/undomanager",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var UndoManager = function() {
+ this.reset();
+};
+
+(function() {
+ this.execute = function(options) {
+ var deltaSets = options.args[0];
+ this.$doc = options.args[1];
+ if (options.merge && this.hasUndo()){
+ this.dirtyCounter--;
+ deltaSets = this.$undoStack.pop().concat(deltaSets);
+ }
+ this.$undoStack.push(deltaSets);
+ this.$redoStack = [];
+ if (this.dirtyCounter < 0) {
+ this.dirtyCounter = NaN;
+ }
+ this.dirtyCounter++;
+ };
+ this.undo = function(dontSelect) {
+ var deltaSets = this.$undoStack.pop();
+ var undoSelectionRange = null;
+ if (deltaSets) {
+ undoSelectionRange = this.$doc.undoChanges(deltaSets, dontSelect);
+ this.$redoStack.push(deltaSets);
+ this.dirtyCounter--;
+ }
+
+ return undoSelectionRange;
+ };
+ this.redo = function(dontSelect) {
+ var deltaSets = this.$redoStack.pop();
+ var redoSelectionRange = null;
+ if (deltaSets) {
+ redoSelectionRange =
+ this.$doc.redoChanges(this.$deserializeDeltas(deltaSets), dontSelect);
+ this.$undoStack.push(deltaSets);
+ this.dirtyCounter++;
+ }
+ return redoSelectionRange;
+ };
+ this.reset = function() {
+ this.$undoStack = [];
+ this.$redoStack = [];
+ this.dirtyCounter = 0;
+ };
+ this.hasUndo = function() {
+ return this.$undoStack.length > 0;
+ };
+ this.hasRedo = function() {
+ return this.$redoStack.length > 0;
+ };
+ this.markClean = function() {
+ this.dirtyCounter = 0;
+ };
+ this.isClean = function() {
+ return this.dirtyCounter === 0;
+ };
+ this.$serializeDeltas = function(deltaSets) {
+ return cloneDeltaSetsObj(deltaSets, $serializeDelta);
+ };
+ this.$deserializeDeltas = function(deltaSets) {
+ return cloneDeltaSetsObj(deltaSets, $deserializeDelta);
+ };
+
+ function $serializeDelta(delta){
+ return {
+ action: delta.action,
+ start: delta.start,
+ end: delta.end,
+ lines: delta.lines.length == 1 ? null : delta.lines,
+ text: delta.lines.length == 1 ? delta.lines[0] : null
+ };
+ }
+
+ function $deserializeDelta(delta) {
+ return {
+ action: delta.action,
+ start: delta.start,
+ end: delta.end,
+ lines: delta.lines || [delta.text]
+ };
+ }
+
+ function cloneDeltaSetsObj(deltaSets_old, fnGetModifiedDelta) {
+ var deltaSets_new = new Array(deltaSets_old.length);
+ for (var i = 0; i < deltaSets_old.length; i++) {
+ var deltaSet_old = deltaSets_old[i];
+ var deltaSet_new = { group: deltaSet_old.group, deltas: new Array(deltaSet_old.length)};
+
+ for (var j = 0; j < deltaSet_old.deltas.length; j++) {
+ var delta_old = deltaSet_old.deltas[j];
+ deltaSet_new.deltas[j] = fnGetModifiedDelta(delta_old);
+ }
+
+ deltaSets_new[i] = deltaSet_new;
+ }
+ return deltaSets_new;
+ }
+
+}).call(UndoManager.prototype);
+
+exports.UndoManager = UndoManager;
+});
+
+ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var dom = require("../lib/dom");
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var EventEmitter = require("../lib/event_emitter").EventEmitter;
+
+var Gutter = function(parentEl) {
+ this.element = dom.createElement("div");
+ this.element.className = "ace_layer ace_gutter-layer";
+ parentEl.appendChild(this.element);
+ this.setShowFoldWidgets(this.$showFoldWidgets);
+
+ this.gutterWidth = 0;
+
+ this.$annotations = [];
+ this.$updateAnnotations = this.$updateAnnotations.bind(this);
+
+ this.$cells = [];
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.setSession = function(session) {
+ if (this.session)
+ this.session.removeEventListener("change", this.$updateAnnotations);
+ this.session = session;
+ if (session)
+ session.on("change", this.$updateAnnotations);
+ };
+
+ this.addGutterDecoration = function(row, className){
+ if (window.console)
+ console.warn && console.warn("deprecated use session.addGutterDecoration");
+ this.session.addGutterDecoration(row, className);
+ };
+
+ this.removeGutterDecoration = function(row, className){
+ if (window.console)
+ console.warn && console.warn("deprecated use session.removeGutterDecoration");
+ this.session.removeGutterDecoration(row, className);
+ };
+
+ this.setAnnotations = function(annotations) {
+ this.$annotations = [];
+ for (var i = 0; i < annotations.length; i++) {
+ var annotation = annotations[i];
+ var row = annotation.row;
+ var rowInfo = this.$annotations[row];
+ if (!rowInfo)
+ rowInfo = this.$annotations[row] = {text: []};
+
+ var annoText = annotation.text;
+ annoText = annoText ? lang.escapeHTML(annoText) : annotation.html || "";
+
+ if (rowInfo.text.indexOf(annoText) === -1)
+ rowInfo.text.push(annoText);
+
+ var type = annotation.type;
+ if (type == "error")
+ rowInfo.className = " ace_error";
+ else if (type == "warning" && rowInfo.className != " ace_error")
+ rowInfo.className = " ace_warning";
+ else if (type == "info" && (!rowInfo.className))
+ rowInfo.className = " ace_info";
+ }
+ };
+
+ this.$updateAnnotations = function (delta) {
+ if (!this.$annotations.length)
+ return;
+ var firstRow = delta.start.row;
+ var len = delta.end.row - firstRow;
+ if (len === 0) {
+ } else if (delta.action == 'remove') {
+ this.$annotations.splice(firstRow, len + 1, null);
+ } else {
+ var args = new Array(len + 1);
+ args.unshift(firstRow, 1);
+ this.$annotations.splice.apply(this.$annotations, args);
+ }
+ };
+
+ this.update = function(config) {
+ var session = this.session;
+ var firstRow = config.firstRow;
+ var lastRow = Math.min(config.lastRow + config.gutterOffset, // needed to compensate for hor scollbar
+ session.getLength() - 1);
+ var fold = session.getNextFoldLine(firstRow);
+ var foldStart = fold ? fold.start.row : Infinity;
+ var foldWidgets = this.$showFoldWidgets && session.foldWidgets;
+ var breakpoints = session.$breakpoints;
+ var decorations = session.$decorations;
+ var firstLineNumber = session.$firstLineNumber;
+ var lastLineNumber = 0;
+
+ var gutterRenderer = session.gutterRenderer || this.$renderer;
+
+ var cell = null;
+ var index = -1;
+ var row = firstRow;
+ while (true) {
+ if (row > foldStart) {
+ row = fold.end.row + 1;
+ fold = session.getNextFoldLine(row, fold);
+ foldStart = fold ? fold.start.row : Infinity;
+ }
+ if (row > lastRow) {
+ while (this.$cells.length > index + 1) {
+ cell = this.$cells.pop();
+ this.element.removeChild(cell.element);
+ }
+ break;
+ }
+
+ cell = this.$cells[++index];
+ if (!cell) {
+ cell = {element: null, textNode: null, foldWidget: null};
+ cell.element = dom.createElement("div");
+ cell.textNode = document.createTextNode('');
+ cell.element.appendChild(cell.textNode);
+ this.element.appendChild(cell.element);
+ this.$cells[index] = cell;
+ }
+
+ var className = "ace_gutter-cell ";
+ if (breakpoints[row])
+ className += breakpoints[row];
+ if (decorations[row])
+ className += decorations[row];
+ if (this.$annotations[row])
+ className += this.$annotations[row].className;
+ if (cell.element.className != className)
+ cell.element.className = className;
+
+ var height = session.getRowLength(row) * config.lineHeight + "px";
+ if (height != cell.element.style.height)
+ cell.element.style.height = height;
+
+ if (foldWidgets) {
+ var c = foldWidgets[row];
+ if (c == null)
+ c = foldWidgets[row] = session.getFoldWidget(row);
+ }
+
+ if (c) {
+ if (!cell.foldWidget) {
+ cell.foldWidget = dom.createElement("span");
+ cell.element.appendChild(cell.foldWidget);
+ }
+ var className = "ace_fold-widget ace_" + c;
+ if (c == "start" && row == foldStart && row < fold.end.row)
+ className += " ace_closed";
+ else
+ className += " ace_open";
+ if (cell.foldWidget.className != className)
+ cell.foldWidget.className = className;
+
+ var height = config.lineHeight + "px";
+ if (cell.foldWidget.style.height != height)
+ cell.foldWidget.style.height = height;
+ } else {
+ if (cell.foldWidget) {
+ cell.element.removeChild(cell.foldWidget);
+ cell.foldWidget = null;
+ }
+ }
+
+ var text = lastLineNumber = gutterRenderer
+ ? gutterRenderer.getText(session, row)
+ : row + firstLineNumber;
+ if (text !== cell.textNode.data)
+ cell.textNode.data = text;
+
+ row++;
+ }
+
+ this.element.style.height = config.minHeight + "px";
+
+ if (this.$fixedWidth || session.$useWrapMode)
+ lastLineNumber = session.getLength() + firstLineNumber;
+
+ var gutterWidth = gutterRenderer
+ ? gutterRenderer.getWidth(session, lastLineNumber, config)
+ : lastLineNumber.toString().length * config.characterWidth;
+
+ var padding = this.$padding || this.$computePadding();
+ gutterWidth += padding.left + padding.right;
+ if (gutterWidth !== this.gutterWidth && !isNaN(gutterWidth)) {
+ this.gutterWidth = gutterWidth;
+ this.element.style.width = Math.ceil(this.gutterWidth) + "px";
+ this._emit("changeGutterWidth", gutterWidth);
+ }
+ };
+
+ this.$fixedWidth = false;
+
+ this.$showLineNumbers = true;
+ this.$renderer = "";
+ this.setShowLineNumbers = function(show) {
+ this.$renderer = !show && {
+ getWidth: function() {return ""},
+ getText: function() {return ""}
+ };
+ };
+
+ this.getShowLineNumbers = function() {
+ return this.$showLineNumbers;
+ };
+
+ this.$showFoldWidgets = true;
+ this.setShowFoldWidgets = function(show) {
+ if (show)
+ dom.addCssClass(this.element, "ace_folding-enabled");
+ else
+ dom.removeCssClass(this.element, "ace_folding-enabled");
+
+ this.$showFoldWidgets = show;
+ this.$padding = null;
+ };
+
+ this.getShowFoldWidgets = function() {
+ return this.$showFoldWidgets;
+ };
+
+ this.$computePadding = function() {
+ if (!this.element.firstChild)
+ return {left: 0, right: 0};
+ var style = dom.computedStyle(this.element.firstChild);
+ this.$padding = {};
+ this.$padding.left = parseInt(style.paddingLeft) + 1 || 0;
+ this.$padding.right = parseInt(style.paddingRight) || 0;
+ return this.$padding;
+ };
+
+ this.getRegion = function(point) {
+ var padding = this.$padding || this.$computePadding();
+ var rect = this.element.getBoundingClientRect();
+ if (point.x < padding.left + rect.left)
+ return "markers";
+ if (this.$showFoldWidgets && point.x > rect.right - padding.right)
+ return "foldWidgets";
+ };
+
+}).call(Gutter.prototype);
+
+exports.Gutter = Gutter;
+
+});
+
+ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var dom = require("../lib/dom");
+
+var Marker = function(parentEl) {
+ this.element = dom.createElement("div");
+ this.element.className = "ace_layer ace_marker-layer";
+ parentEl.appendChild(this.element);
+};
+
+(function() {
+
+ this.$padding = 0;
+
+ this.setPadding = function(padding) {
+ this.$padding = padding;
+ };
+ this.setSession = function(session) {
+ this.session = session;
+ };
+
+ this.setMarkers = function(markers) {
+ this.markers = markers;
+ };
+
+ this.update = function(config) {
+ if (!config) return;
+
+ this.config = config;
+
+
+ var html = [];
+ for (var key in this.markers) {
+ var marker = this.markers[key];
+
+ if (!marker.range) {
+ marker.update(html, this, this.session, config);
+ continue;
+ }
+
+ var range = marker.range.clipRows(config.firstRow, config.lastRow);
+ if (range.isEmpty()) continue;
+
+ range = range.toScreenRange(this.session);
+ if (marker.renderer) {
+ var top = this.$getTop(range.start.row, config);
+ var left = this.$padding + (this.session.$bidiHandler.isBidiRow(range.start.row)
+ ? this.session.$bidiHandler.getPosLeft(range.start.column)
+ : range.start.column * config.characterWidth);
+ marker.renderer(html, range, left, top, config);
+ } else if (marker.type == "fullLine") {
+ this.drawFullLineMarker(html, range, marker.clazz, config);
+ } else if (marker.type == "screenLine") {
+ this.drawScreenLineMarker(html, range, marker.clazz, config);
+ } else if (range.isMultiLine()) {
+ if (marker.type == "text")
+ this.drawTextMarker(html, range, marker.clazz, config);
+ else
+ this.drawMultiLineMarker(html, range, marker.clazz, config);
+ } else {
+ if (this.session.$bidiHandler.isBidiRow(range.start.row)) {
+ this.drawBidiSingleLineMarker(html, range, marker.clazz + " ace_start" + " ace_br15", config);
+ } else {
+ this.drawSingleLineMarker(html, range, marker.clazz + " ace_start" + " ace_br15", config);
+ }
+ }
+ }
+ this.element.innerHTML = html.join("");
+ };
+
+ this.$getTop = function(row, layerConfig) {
+ return (row - layerConfig.firstRowScreen) * layerConfig.lineHeight;
+ };
+
+ function getBorderClass(tl, tr, br, bl) {
+ return (tl ? 1 : 0) | (tr ? 2 : 0) | (br ? 4 : 0) | (bl ? 8 : 0);
+ }
+ this.drawTextMarker = function(stringBuilder, range, clazz, layerConfig, extraStyle) {
+ var session = this.session;
+ var start = range.start.row;
+ var end = range.end.row;
+ var row = start;
+ var prev = 0;
+ var curr = 0;
+ var next = session.getScreenLastRowColumn(row);
+ var clazzModified = null;
+ var lineRange = new Range(row, range.start.column, row, curr);
+ for (; row <= end; row++) {
+ lineRange.start.row = lineRange.end.row = row;
+ lineRange.start.column = row == start ? range.start.column : session.getRowWrapIndent(row);
+ lineRange.end.column = next;
+ prev = curr;
+ curr = next;
+ next = row + 1 < end ? session.getScreenLastRowColumn(row + 1) : row == end ? 0 : range.end.column;
+ clazzModified = clazz + (row == start ? " ace_start" : "") + " ace_br"
+ + getBorderClass(row == start || row == start + 1 && range.start.column, prev < curr, curr > next, row == end);
+
+ if (this.session.$bidiHandler.isBidiRow(row)) {
+ this.drawBidiSingleLineMarker(stringBuilder, lineRange, clazzModified,
+ layerConfig, row == end ? 0 : 1, extraStyle);
+ } else {
+ this.drawSingleLineMarker(stringBuilder, lineRange, clazzModified,
+ layerConfig, row == end ? 0 : 1, extraStyle);
+ }
+ }
+ };
+ this.drawMultiLineMarker = function(stringBuilder, range, clazz, config, extraStyle) {
+ var padding = this.$padding;
+ var height, top, left;
+ extraStyle = extraStyle || "";
+ if (this.session.$bidiHandler.isBidiRow(range.start.row)) {
+ var range1 = range.clone();
+ range1.end.row = range1.start.row;
+ range1.end.column = this.session.getLine(range1.start.row).length;
+ this.drawBidiSingleLineMarker(stringBuilder, range1, clazz + " ace_br1 ace_start", config, null, extraStyle);
+ } else {
+ height = config.lineHeight;
+ top = this.$getTop(range.start.row, config);
+ left = padding + range.start.column * config.characterWidth;
+ stringBuilder.push(
+ "<div class='", clazz, " ace_br1 ace_start' style='",
+ "height:", height, "px;",
+ "right:0;",
+ "top:", top, "px;",
+ "left:", left, "px;", extraStyle, "'></div>"
+ );
+ }
+ if (this.session.$bidiHandler.isBidiRow(range.end.row)) {
+ var range1 = range.clone();
+ range1.start.row = range1.end.row;
+ range1.start.column = 0;
+ this.drawBidiSingleLineMarker(stringBuilder, range1, clazz + " ace_br12", config, null, extraStyle);
+ } else {
+ var width = range.end.column * config.characterWidth;
+ height = config.lineHeight;
+ top = this.$getTop(range.end.row, config);
+ stringBuilder.push(
+ "<div class='", clazz, " ace_br12' style='",
+ "height:", height, "px;",
+ "width:", width, "px;",
+ "top:", top, "px;",
+ "left:", padding, "px;", extraStyle, "'></div>"
+ );
+ }
+ height = (range.end.row - range.start.row - 1) * config.lineHeight;
+ if (height <= 0)
+ return;
+ top = this.$getTop(range.start.row + 1, config);
+
+ var radiusClass = (range.start.column ? 1 : 0) | (range.end.column ? 0 : 8);
+
+ stringBuilder.push(
+ "<div class='", clazz, (radiusClass ? " ace_br" + radiusClass : ""), "' style='",
+ "height:", height, "px;",
+ "right:0;",
+ "top:", top, "px;",
+ "left:", padding, "px;", extraStyle, "'></div>"
+ );
+ };
+ this.drawSingleLineMarker = function(stringBuilder, range, clazz, config, extraLength, extraStyle) {
+ var height = config.lineHeight;
+ var width = (range.end.column + (extraLength || 0) - range.start.column) * config.characterWidth;
+
+ var top = this.$getTop(range.start.row, config);
+ var left = this.$padding + range.start.column * config.characterWidth;
+
+ stringBuilder.push(
+ "<div class='", clazz, "' style='",
+ "height:", height, "px;",
+ "width:", width, "px;",
+ "top:", top, "px;",
+ "left:", left, "px;", extraStyle || "", "'></div>"
+ );
+ };
+ this.drawBidiSingleLineMarker = function(stringBuilder, range, clazz, config, extraLength, extraStyle) {
+ var height = config.lineHeight, top = this.$getTop(range.start.row, config), padding = this.$padding;
+ var selections = this.session.$bidiHandler.getSelections(range.start.column, range.end.column);
+
+ selections.forEach(function(selection) {
+ stringBuilder.push(
+ "<div class='", clazz, "' style='",
+ "height:", height, "px;",
+ "width:", selection.width + (extraLength || 0), "px;",
+ "top:", top, "px;",
+ "left:", padding + selection.left, "px;", extraStyle || "", "'></div>"
+ );
+ });
+ };
+
+ this.drawFullLineMarker = function(stringBuilder, range, clazz, config, extraStyle) {
+ var top = this.$getTop(range.start.row, config);
+ var height = config.lineHeight;
+ if (range.start.row != range.end.row)
+ height += this.$getTop(range.end.row, config) - top;
+
+ stringBuilder.push(
+ "<div class='", clazz, "' style='",
+ "height:", height, "px;",
+ "top:", top, "px;",
+ "left:0;right:0;", extraStyle || "", "'></div>"
+ );
+ };
+
+ this.drawScreenLineMarker = function(stringBuilder, range, clazz, config, extraStyle) {
+ var top = this.$getTop(range.start.row, config);
+ var height = config.lineHeight;
+
+ stringBuilder.push(
+ "<div class='", clazz, "' style='",
+ "height:", height, "px;",
+ "top:", top, "px;",
+ "left:0;right:0;", extraStyle || "", "'></div>"
+ );
+ };
+
+}).call(Marker.prototype);
+
+exports.Marker = Marker;
+
+});
+
+ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var dom = require("../lib/dom");
+var lang = require("../lib/lang");
+var useragent = require("../lib/useragent");
+var EventEmitter = require("../lib/event_emitter").EventEmitter;
+
+var Text = function(parentEl) {
+ this.element = dom.createElement("div");
+ this.element.className = "ace_layer ace_text-layer";
+ parentEl.appendChild(this.element);
+ this.$updateEolChar = this.$updateEolChar.bind(this);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.EOF_CHAR = "\xB6";
+ this.EOL_CHAR_LF = "\xAC";
+ this.EOL_CHAR_CRLF = "\xa4";
+ this.EOL_CHAR = this.EOL_CHAR_LF;
+ this.TAB_CHAR = "\u2014"; //"\u21E5";
+ this.SPACE_CHAR = "\xB7";
+ this.$padding = 0;
+
+ this.$updateEolChar = function() {
+ var EOL_CHAR = this.session.doc.getNewLineCharacter() == "\n"
+ ? this.EOL_CHAR_LF
+ : this.EOL_CHAR_CRLF;
+ if (this.EOL_CHAR != EOL_CHAR) {
+ this.EOL_CHAR = EOL_CHAR;
+ return true;
+ }
+ }
+
+ this.setPadding = function(padding) {
+ this.$padding = padding;
+ this.element.style.padding = "0 " + padding + "px";
+ };
+
+ this.getLineHeight = function() {
+ return this.$fontMetrics.$characterSize.height || 0;
+ };
+
+ this.getCharacterWidth = function() {
+ return this.$fontMetrics.$characterSize.width || 0;
+ };
+
+ this.$setFontMetrics = function(measure) {
+ this.$fontMetrics = measure;
+ this.$fontMetrics.on("changeCharacterSize", function(e) {
+ this._signal("changeCharacterSize", e);
+ }.bind(this));
+ this.$pollSizeChanges();
+ }
+
+ this.checkForSizeChanges = function() {
+ this.$fontMetrics.checkForSizeChanges();
+ };
+ this.$pollSizeChanges = function() {
+ return this.$pollSizeChangesTimer = this.$fontMetrics.$pollSizeChanges();
+ };
+ this.setSession = function(session) {
+ this.session = session;
+ if (session)
+ this.$computeTabString();
+ };
+
+ this.showInvisibles = false;
+ this.setShowInvisibles = function(showInvisibles) {
+ if (this.showInvisibles == showInvisibles)
+ return false;
+
+ this.showInvisibles = showInvisibles;
+ this.$computeTabString();
+ return true;
+ };
+
+ this.displayIndentGuides = true;
+ this.setDisplayIndentGuides = function(display) {
+ if (this.displayIndentGuides == display)
+ return false;
+
+ this.displayIndentGuides = display;
+ this.$computeTabString();
+ return true;
+ };
+
+ this.$tabStrings = [];
+ this.onChangeTabSize =
+ this.$computeTabString = function() {
+ var tabSize = this.session.getTabSize();
+ this.tabSize = tabSize;
+ var tabStr = this.$tabStrings = [0];
+ for (var i = 1; i < tabSize + 1; i++) {
+ if (this.showInvisibles) {
+ tabStr.push("<span class='ace_invisible ace_invisible_tab'>"
+ + lang.stringRepeat(this.TAB_CHAR, i)
+ + "</span>");
+ } else {
+ tabStr.push(lang.stringRepeat(" ", i));
+ }
+ }
+ if (this.displayIndentGuides) {
+ this.$indentGuideRe = /\s\S| \t|\t |\s$/;
+ var className = "ace_indent-guide";
+ var spaceClass = "";
+ var tabClass = "";
+ if (this.showInvisibles) {
+ className += " ace_invisible";
+ spaceClass = " ace_invisible_space";
+ tabClass = " ace_invisible_tab";
+ var spaceContent = lang.stringRepeat(this.SPACE_CHAR, this.tabSize);
+ var tabContent = lang.stringRepeat(this.TAB_CHAR, this.tabSize);
+ } else{
+ var spaceContent = lang.stringRepeat(" ", this.tabSize);
+ var tabContent = spaceContent;
+ }
+
+ this.$tabStrings[" "] = "<span class='" + className + spaceClass + "'>" + spaceContent + "</span>";
+ this.$tabStrings["\t"] = "<span class='" + className + tabClass + "'>" + tabContent + "</span>";
+ }
+ };
+
+ this.updateLines = function(config, firstRow, lastRow) {
+ if (this.config.lastRow != config.lastRow ||
+ this.config.firstRow != config.firstRow) {
+ this.scrollLines(config);
+ }
+ this.config = config;
+
+ var first = Math.max(firstRow, config.firstRow);
+ var last = Math.min(lastRow, config.lastRow);
+
+ var lineElements = this.element.childNodes;
+ var lineElementsIdx = 0;
+
+ for (var row = config.firstRow; row < first; row++) {
+ var foldLine = this.session.getFoldLine(row);
+ if (foldLine) {
+ if (foldLine.containsRow(first)) {
+ first = foldLine.start.row;
+ break;
+ } else {
+ row = foldLine.end.row;
+ }
+ }
+ lineElementsIdx ++;
+ }
+
+ var row = first;
+ var foldLine = this.session.getNextFoldLine(row);
+ var foldStart = foldLine ? foldLine.start.row : Infinity;
+
+ while (true) {
+ if (row > foldStart) {
+ row = foldLine.end.row+1;
+ foldLine = this.session.getNextFoldLine(row, foldLine);
+ foldStart = foldLine ? foldLine.start.row :Infinity;
+ }
+ if (row > last)
+ break;
+
+ var lineElement = lineElements[lineElementsIdx++];
+ if (lineElement) {
+ var html = [];
+ this.$renderLine(
+ html, row, !this.$useLineGroups(), row == foldStart ? foldLine : false
+ );
+ lineElement.style.height = config.lineHeight * this.session.getRowLength(row) + "px";
+ lineElement.innerHTML = html.join("");
+ }
+ row++;
+ }
+ };
+
+ this.scrollLines = function(config) {
+ var oldConfig = this.config;
+ this.config = config;
+
+ if (!oldConfig || oldConfig.lastRow < config.firstRow)
+ return this.update(config);
+
+ if (config.lastRow < oldConfig.firstRow)
+ return this.update(config);
+
+ var el = this.element;
+ if (oldConfig.firstRow < config.firstRow)
+ for (var row=this.session.getFoldedRowCount(oldConfig.firstRow, config.firstRow - 1); row>0; row--)
+ el.removeChild(el.firstChild);
+
+ if (oldConfig.lastRow > config.lastRow)
+ for (var row=this.session.getFoldedRowCount(config.lastRow + 1, oldConfig.lastRow); row>0; row--)
+ el.removeChild(el.lastChild);
+
+ if (config.firstRow < oldConfig.firstRow) {
+ var fragment = this.$renderLinesFragment(config, config.firstRow, oldConfig.firstRow - 1);
+ if (el.firstChild)
+ el.insertBefore(fragment, el.firstChild);
+ else
+ el.appendChild(fragment);
+ }
+
+ if (config.lastRow > oldConfig.lastRow) {
+ var fragment = this.$renderLinesFragment(config, oldConfig.lastRow + 1, config.lastRow);
+ el.appendChild(fragment);
+ }
+ };
+
+ this.$renderLinesFragment = function(config, firstRow, lastRow) {
+ var fragment = this.element.ownerDocument.createDocumentFragment();
+ var row = firstRow;
+ var foldLine = this.session.getNextFoldLine(row);
+ var foldStart = foldLine ? foldLine.start.row : Infinity;
+
+ while (true) {
+ if (row > foldStart) {
+ row = foldLine.end.row+1;
+ foldLine = this.session.getNextFoldLine(row, foldLine);
+ foldStart = foldLine ? foldLine.start.row : Infinity;
+ }
+ if (row > lastRow)
+ break;
+
+ var container = dom.createElement("div");
+
+ var html = [];
+ this.$renderLine(html, row, false, row == foldStart ? foldLine : false);
+ container.innerHTML = html.join("");
+ if (this.$useLineGroups()) {
+ container.className = 'ace_line_group';
+ fragment.appendChild(container);
+ container.style.height = config.lineHeight * this.session.getRowLength(row) + "px";
+
+ } else {
+ while(container.firstChild)
+ fragment.appendChild(container.firstChild);
+ }
+
+ row++;
+ }
+ return fragment;
+ };
+
+ this.update = function(config) {
+ this.config = config;
+
+ var html = [];
+ var firstRow = config.firstRow, lastRow = config.lastRow;
+
+ var row = firstRow;
+ var foldLine = this.session.getNextFoldLine(row);
+ var foldStart = foldLine ? foldLine.start.row : Infinity;
+
+ while (true) {
+ if (row > foldStart) {
+ row = foldLine.end.row+1;
+ foldLine = this.session.getNextFoldLine(row, foldLine);
+ foldStart = foldLine ? foldLine.start.row :Infinity;
+ }
+ if (row > lastRow)
+ break;
+
+ if (this.$useLineGroups())
+ html.push("<div class='ace_line_group' style='height:", config.lineHeight*this.session.getRowLength(row), "px'>")
+
+ this.$renderLine(html, row, false, row == foldStart ? foldLine : false);
+
+ if (this.$useLineGroups())
+ html.push("</div>"); // end the line group
+
+ row++;
+ }
+ this.element.innerHTML = html.join("");
+ };
+
+ this.$textToken = {
+ "text": true,
+ "rparen": true,
+ "lparen": true
+ };
+
+ this.$renderToken = function(stringBuilder, screenColumn, token, value) {
+ var self = this;
+ var replaceReg = /\t|&|<|>|( +)|([\x00-\x1f\x80-\xa0\xad\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\u3000\uFEFF\uFFF9-\uFFFC])|[\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3000-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]/g;
+ var replaceFunc = function(c, a, b, tabIdx, idx4) {
+ if (a) {
+ return self.showInvisibles
+ ? "<span class='ace_invisible ace_invisible_space'>" + lang.stringRepeat(self.SPACE_CHAR, c.length) + "</span>"
+ : c;
+ } else if (c == "&") {
+ return "&#38;";
+ } else if (c == "<") {
+ return "&#60;";
+ } else if (c == ">") {
+ return "&#62;";
+ } else if (c == "\t") {
+ var tabSize = self.session.getScreenTabSize(screenColumn + tabIdx);
+ screenColumn += tabSize - 1;
+ return self.$tabStrings[tabSize];
+ } else if (c == "\u3000") {
+ var classToUse = self.showInvisibles ? "ace_cjk ace_invisible ace_invisible_space" : "ace_cjk";
+ var space = self.showInvisibles ? self.SPACE_CHAR : "";
+ screenColumn += 1;
+ return "<span class='" + classToUse + "' style='width:" +
+ (self.config.characterWidth * 2) +
+ "px'>" + space + "</span>";
+ } else if (b) {
+ return "<span class='ace_invisible ace_invisible_space ace_invalid'>" + self.SPACE_CHAR + "</span>";
+ } else {
+ screenColumn += 1;
+ return "<span class='ace_cjk' style='width:" +
+ (self.config.characterWidth * 2) +
+ "px'>" + c + "</span>";
+ }
+ };
+
+ var output = value.replace(replaceReg, replaceFunc);
+
+ if (!this.$textToken[token.type]) {
+ var classes = "ace_" + token.type.replace(/\./g, " ace_");
+ var style = "";
+ if (token.type == "fold")
+ style = " style='width:" + (token.value.length * this.config.characterWidth) + "px;' ";
+ stringBuilder.push("<span class='", classes, "'", style, ">", output, "</span>");
+ }
+ else {
+ stringBuilder.push(output);
+ }
+ return screenColumn + value.length;
+ };
+
+ this.renderIndentGuide = function(stringBuilder, value, max) {
+ var cols = value.search(this.$indentGuideRe);
+ if (cols <= 0 || cols >= max)
+ return value;
+ if (value[0] == " ") {
+ cols -= cols % this.tabSize;
+ stringBuilder.push(lang.stringRepeat(this.$tabStrings[" "], cols/this.tabSize));
+ return value.substr(cols);
+ } else if (value[0] == "\t") {
+ stringBuilder.push(lang.stringRepeat(this.$tabStrings["\t"], cols));
+ return value.substr(cols);
+ }
+ return value;
+ };
+
+ this.$renderWrappedLine = function(stringBuilder, tokens, splits, onlyContents) {
+ var chars = 0;
+ var split = 0;
+ var splitChars = splits[0];
+ var screenColumn = 0;
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ var value = token.value;
+ if (i == 0 && this.displayIndentGuides) {
+ chars = value.length;
+ value = this.renderIndentGuide(stringBuilder, value, splitChars);
+ if (!value)
+ continue;
+ chars -= value.length;
+ }
+
+ if (chars + value.length < splitChars) {
+ screenColumn = this.$renderToken(stringBuilder, screenColumn, token, value);
+ chars += value.length;
+ } else {
+ while (chars + value.length >= splitChars) {
+ screenColumn = this.$renderToken(
+ stringBuilder, screenColumn,
+ token, value.substring(0, splitChars - chars)
+ );
+ value = value.substring(splitChars - chars);
+ chars = splitChars;
+
+ if (!onlyContents) {
+ stringBuilder.push("</div>",
+ "<div class='ace_line' style='height:",
+ this.config.lineHeight, "px'>"
+ );
+ }
+
+ stringBuilder.push(lang.stringRepeat("\xa0", splits.indent));
+
+ split ++;
+ screenColumn = 0;
+ splitChars = splits[split] || Number.MAX_VALUE;
+ }
+ if (value.length != 0) {
+ chars += value.length;
+ screenColumn = this.$renderToken(
+ stringBuilder, screenColumn, token, value
+ );
+ }
+ }
+ }
+ };
+
+ this.$renderSimpleLine = function(stringBuilder, tokens) {
+ var screenColumn = 0;
+ var token = tokens[0];
+ var value = token.value;
+ if (this.displayIndentGuides)
+ value = this.renderIndentGuide(stringBuilder, value);
+ if (value)
+ screenColumn = this.$renderToken(stringBuilder, screenColumn, token, value);
+ for (var i = 1; i < tokens.length; i++) {
+ token = tokens[i];
+ value = token.value;
+ screenColumn = this.$renderToken(stringBuilder, screenColumn, token, value);
+ }
+ };
+ this.$renderLine = function(stringBuilder, row, onlyContents, foldLine) {
+ if (!foldLine && foldLine != false)
+ foldLine = this.session.getFoldLine(row);
+
+ if (foldLine)
+ var tokens = this.$getFoldLineTokens(row, foldLine);
+ else
+ var tokens = this.session.getTokens(row);
+
+
+ if (!onlyContents) {
+ stringBuilder.push(
+ "<div class='ace_line' style='height:",
+ this.config.lineHeight * (
+ this.$useLineGroups() ? 1 :this.session.getRowLength(row)
+ ), "px'>"
+ );
+ }
+
+ if (tokens.length) {
+ var splits = this.session.getRowSplitData(row);
+ if (splits && splits.length)
+ this.$renderWrappedLine(stringBuilder, tokens, splits, onlyContents);
+ else
+ this.$renderSimpleLine(stringBuilder, tokens);
+ }
+
+ if (this.showInvisibles) {
+ if (foldLine)
+ row = foldLine.end.row
+
+ stringBuilder.push(
+ "<span class='ace_invisible ace_invisible_eol'>",
+ row == this.session.getLength() - 1 ? this.EOF_CHAR : this.EOL_CHAR,
+ "</span>"
+ );
+ }
+ if (!onlyContents)
+ stringBuilder.push("</div>");
+ };
+
+ this.$getFoldLineTokens = function(row, foldLine) {
+ var session = this.session;
+ var renderTokens = [];
+
+ function addTokens(tokens, from, to) {
+ var idx = 0, col = 0;
+ while ((col + tokens[idx].value.length) < from) {
+ col += tokens[idx].value.length;
+ idx++;
+
+ if (idx == tokens.length)
+ return;
+ }
+ if (col != from) {
+ var value = tokens[idx].value.substring(from - col);
+ if (value.length > (to - from))
+ value = value.substring(0, to - from);
+
+ renderTokens.push({
+ type: tokens[idx].type,
+ value: value
+ });
+
+ col = from + value.length;
+ idx += 1;
+ }
+
+ while (col < to && idx < tokens.length) {
+ var value = tokens[idx].value;
+ if (value.length + col > to) {
+ renderTokens.push({
+ type: tokens[idx].type,
+ value: value.substring(0, to - col)
+ });
+ } else
+ renderTokens.push(tokens[idx]);
+ col += value.length;
+ idx += 1;
+ }
+ }
+
+ var tokens = session.getTokens(row);
+ foldLine.walk(function(placeholder, row, column, lastColumn, isNewRow) {
+ if (placeholder != null) {
+ renderTokens.push({
+ type: "fold",
+ value: placeholder
+ });
+ } else {
+ if (isNewRow)
+ tokens = session.getTokens(row);
+
+ if (tokens.length)
+ addTokens(tokens, lastColumn, column);
+ }
+ }, foldLine.end.row, this.session.getLine(foldLine.end.row).length);
+
+ return renderTokens;
+ };
+
+ this.$useLineGroups = function() {
+ return this.session.getUseWrapMode();
+ };
+
+ this.destroy = function() {
+ clearInterval(this.$pollSizeChangesTimer);
+ if (this.$measureNode)
+ this.$measureNode.parentNode.removeChild(this.$measureNode);
+ delete this.$measureNode;
+ };
+
+}).call(Text.prototype);
+
+exports.Text = Text;
+
+});
+
+ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+var dom = require("../lib/dom");
+var isIE8;
+
+var Cursor = function(parentEl) {
+ this.element = dom.createElement("div");
+ this.element.className = "ace_layer ace_cursor-layer";
+ parentEl.appendChild(this.element);
+
+ if (isIE8 === undefined)
+ isIE8 = !("opacity" in this.element.style);
+
+ this.isVisible = false;
+ this.isBlinking = true;
+ this.blinkInterval = 1000;
+ this.smoothBlinking = false;
+
+ this.cursors = [];
+ this.cursor = this.addCursor();
+ dom.addCssClass(this.element, "ace_hidden-cursors");
+ this.$updateCursors = (isIE8
+ ? this.$updateVisibility
+ : this.$updateOpacity).bind(this);
+};
+
+(function() {
+
+ this.$updateVisibility = function(val) {
+ var cursors = this.cursors;
+ for (var i = cursors.length; i--; )
+ cursors[i].style.visibility = val ? "" : "hidden";
+ };
+ this.$updateOpacity = function(val) {
+ var cursors = this.cursors;
+ for (var i = cursors.length; i--; )
+ cursors[i].style.opacity = val ? "" : "0";
+ };
+
+
+ this.$padding = 0;
+ this.setPadding = function(padding) {
+ this.$padding = padding;
+ };
+
+ this.setSession = function(session) {
+ this.session = session;
+ };
+
+ this.setBlinking = function(blinking) {
+ if (blinking != this.isBlinking){
+ this.isBlinking = blinking;
+ this.restartTimer();
+ }
+ };
+
+ this.setBlinkInterval = function(blinkInterval) {
+ if (blinkInterval != this.blinkInterval){
+ this.blinkInterval = blinkInterval;
+ this.restartTimer();
+ }
+ };
+
+ this.setSmoothBlinking = function(smoothBlinking) {
+ if (smoothBlinking != this.smoothBlinking && !isIE8) {
+ this.smoothBlinking = smoothBlinking;
+ dom.setCssClass(this.element, "ace_smooth-blinking", smoothBlinking);
+ this.$updateCursors(true);
+ this.$updateCursors = (this.$updateOpacity).bind(this);
+ this.restartTimer();
+ }
+ };
+
+ this.addCursor = function() {
+ var el = dom.createElement("div");
+ el.className = "ace_cursor";
+ this.element.appendChild(el);
+ this.cursors.push(el);
+ return el;
+ };
+
+ this.removeCursor = function() {
+ if (this.cursors.length > 1) {
+ var el = this.cursors.pop();
+ el.parentNode.removeChild(el);
+ return el;
+ }
+ };
+
+ this.hideCursor = function() {
+ this.isVisible = false;
+ dom.addCssClass(this.element, "ace_hidden-cursors");
+ this.restartTimer();
+ };
+
+ this.showCursor = function() {
+ this.isVisible = true;
+ dom.removeCssClass(this.element, "ace_hidden-cursors");
+ this.restartTimer();
+ };
+
+ this.restartTimer = function() {
+ var update = this.$updateCursors;
+ clearInterval(this.intervalId);
+ clearTimeout(this.timeoutId);
+ if (this.smoothBlinking) {
+ dom.removeCssClass(this.element, "ace_smooth-blinking");
+ }
+
+ update(true);
+
+ if (!this.isBlinking || !this.blinkInterval || !this.isVisible)
+ return;
+
+ if (this.smoothBlinking) {
+ setTimeout(function(){
+ dom.addCssClass(this.element, "ace_smooth-blinking");
+ }.bind(this));
+ }
+
+ var blink = function(){
+ this.timeoutId = setTimeout(function() {
+ update(false);
+ }, 0.6 * this.blinkInterval);
+ }.bind(this);
+
+ this.intervalId = setInterval(function() {
+ update(true);
+ blink();
+ }, this.blinkInterval);
+
+ blink();
+ };
+
+ this.getPixelPosition = function(position, onScreen) {
+ if (!this.config || !this.session)
+ return {left : 0, top : 0};
+
+ if (!position)
+ position = this.session.selection.getCursor();
+ var pos = this.session.documentToScreenPosition(position);
+ var cursorLeft = this.$padding + (this.session.$bidiHandler.isBidiRow(pos.row, position.row)
+ ? this.session.$bidiHandler.getPosLeft(pos.column)
+ : pos.column * this.config.characterWidth);
+
+ var cursorTop = (pos.row - (onScreen ? this.config.firstRowScreen : 0)) *
+ this.config.lineHeight;
+
+ return {left : cursorLeft, top : cursorTop};
+ };
+
+ this.update = function(config) {
+ this.config = config;
+
+ var selections = this.session.$selectionMarkers;
+ var i = 0, cursorIndex = 0;
+
+ if (selections === undefined || selections.length === 0){
+ selections = [{cursor: null}];
+ }
+
+ for (var i = 0, n = selections.length; i < n; i++) {
+ var pixelPos = this.getPixelPosition(selections[i].cursor, true);
+ if ((pixelPos.top > config.height + config.offset ||
+ pixelPos.top < 0) && i > 1) {
+ continue;
+ }
+
+ var style = (this.cursors[cursorIndex++] || this.addCursor()).style;
+
+ if (!this.drawCursor) {
+ style.left = pixelPos.left + "px";
+ style.top = pixelPos.top + "px";
+ style.width = config.characterWidth + "px";
+ style.height = config.lineHeight + "px";
+ } else {
+ this.drawCursor(style, pixelPos, config, selections[i], this.session);
+ }
+ }
+ while (this.cursors.length > cursorIndex)
+ this.removeCursor();
+
+ var overwrite = this.session.getOverwrite();
+ this.$setOverwrite(overwrite);
+ this.$pixelPos = pixelPos;
+ this.restartTimer();
+ };
+
+ this.drawCursor = null;
+
+ this.$setOverwrite = function(overwrite) {
+ if (overwrite != this.overwrite) {
+ this.overwrite = overwrite;
+ if (overwrite)
+ dom.addCssClass(this.element, "ace_overwrite-cursors");
+ else
+ dom.removeCssClass(this.element, "ace_overwrite-cursors");
+ }
+ };
+
+ this.destroy = function() {
+ clearInterval(this.intervalId);
+ clearTimeout(this.timeoutId);
+ };
+
+}).call(Cursor.prototype);
+
+exports.Cursor = Cursor;
+
+});
+
+ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var dom = require("./lib/dom");
+var event = require("./lib/event");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var MAX_SCROLL_H = 0x8000;
+var ScrollBar = function(parent) {
+ this.element = dom.createElement("div");
+ this.element.className = "ace_scrollbar ace_scrollbar" + this.classSuffix;
+
+ this.inner = dom.createElement("div");
+ this.inner.className = "ace_scrollbar-inner";
+ this.element.appendChild(this.inner);
+
+ parent.appendChild(this.element);
+
+ this.setVisible(false);
+ this.skipEvent = false;
+
+ event.addListener(this.element, "scroll", this.onScroll.bind(this));
+ event.addListener(this.element, "mousedown", event.preventDefault);
+};
+
+(function() {
+ oop.implement(this, EventEmitter);
+
+ this.setVisible = function(isVisible) {
+ this.element.style.display = isVisible ? "" : "none";
+ this.isVisible = isVisible;
+ this.coeff = 1;
+ };
+}).call(ScrollBar.prototype);
+var VScrollBar = function(parent, renderer) {
+ ScrollBar.call(this, parent);
+ this.scrollTop = 0;
+ this.scrollHeight = 0;
+ renderer.$scrollbarWidth =
+ this.width = dom.scrollbarWidth(parent.ownerDocument);
+ this.inner.style.width =
+ this.element.style.width = (this.width || 15) + 5 + "px";
+ this.$minWidth = 0;
+};
+
+oop.inherits(VScrollBar, ScrollBar);
+
+(function() {
+
+ this.classSuffix = '-v';
+ this.onScroll = function() {
+ if (!this.skipEvent) {
+ this.scrollTop = this.element.scrollTop;
+ if (this.coeff != 1) {
+ var h = this.element.clientHeight / this.scrollHeight;
+ this.scrollTop = this.scrollTop * (1 - h) / (this.coeff - h);
+ }
+ this._emit("scroll", {data: this.scrollTop});
+ }
+ this.skipEvent = false;
+ };
+ this.getWidth = function() {
+ return Math.max(this.isVisible ? this.width : 0, this.$minWidth || 0);
+ };
+ this.setHeight = function(height) {
+ this.element.style.height = height + "px";
+ };
+ this.setInnerHeight =
+ this.setScrollHeight = function(height) {
+ this.scrollHeight = height;
+ if (height > MAX_SCROLL_H) {
+ this.coeff = MAX_SCROLL_H / height;
+ height = MAX_SCROLL_H;
+ } else if (this.coeff != 1) {
+ this.coeff = 1
+ }
+ this.inner.style.height = height + "px";
+ };
+ this.setScrollTop = function(scrollTop) {
+ if (this.scrollTop != scrollTop) {
+ this.skipEvent = true;
+ this.scrollTop = scrollTop;
+ this.element.scrollTop = scrollTop * this.coeff;
+ }
+ };
+
+}).call(VScrollBar.prototype);
+var HScrollBar = function(parent, renderer) {
+ ScrollBar.call(this, parent);
+ this.scrollLeft = 0;
+ this.height = renderer.$scrollbarWidth;
+ this.inner.style.height =
+ this.element.style.height = (this.height || 15) + 5 + "px";
+};
+
+oop.inherits(HScrollBar, ScrollBar);
+
+(function() {
+
+ this.classSuffix = '-h';
+ this.onScroll = function() {
+ if (!this.skipEvent) {
+ this.scrollLeft = this.element.scrollLeft;
+ this._emit("scroll", {data: this.scrollLeft});
+ }
+ this.skipEvent = false;
+ };
+ this.getHeight = function() {
+ return this.isVisible ? this.height : 0;
+ };
+ this.setWidth = function(width) {
+ this.element.style.width = width + "px";
+ };
+ this.setInnerWidth = function(width) {
+ this.inner.style.width = width + "px";
+ };
+ this.setScrollWidth = function(width) {
+ this.inner.style.width = width + "px";
+ };
+ this.setScrollLeft = function(scrollLeft) {
+ if (this.scrollLeft != scrollLeft) {
+ this.skipEvent = true;
+ this.scrollLeft = this.element.scrollLeft = scrollLeft;
+ }
+ };
+
+}).call(HScrollBar.prototype);
+
+
+exports.ScrollBar = VScrollBar; // backward compatibility
+exports.ScrollBarV = VScrollBar; // backward compatibility
+exports.ScrollBarH = HScrollBar; // backward compatibility
+
+exports.VScrollBar = VScrollBar;
+exports.HScrollBar = HScrollBar;
+});
+
+ace.define("ace/renderloop",["require","exports","module","ace/lib/event"], function(require, exports, module) {
+"use strict";
+
+var event = require("./lib/event");
+
+
+var RenderLoop = function(onRender, win) {
+ this.onRender = onRender;
+ this.pending = false;
+ this.changes = 0;
+ this.window = win || window;
+};
+
+(function() {
+
+
+ this.schedule = function(change) {
+ this.changes = this.changes | change;
+ if (!this.pending && this.changes) {
+ this.pending = true;
+ var _self = this;
+ event.nextFrame(function() {
+ _self.pending = false;
+ var changes;
+ while (changes = _self.changes) {
+ _self.changes = 0;
+ _self.onRender(changes);
+ }
+ }, this.window);
+ }
+ };
+
+}).call(RenderLoop.prototype);
+
+exports.RenderLoop = RenderLoop;
+});
+
+ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/lib/event_emitter"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var dom = require("../lib/dom");
+var lang = require("../lib/lang");
+var useragent = require("../lib/useragent");
+var EventEmitter = require("../lib/event_emitter").EventEmitter;
+
+var CHAR_COUNT = 0;
+
+var FontMetrics = exports.FontMetrics = function(parentEl) {
+ this.el = dom.createElement("div");
+ this.$setMeasureNodeStyles(this.el.style, true);
+
+ this.$main = dom.createElement("div");
+ this.$setMeasureNodeStyles(this.$main.style);
+
+ this.$measureNode = dom.createElement("div");
+ this.$setMeasureNodeStyles(this.$measureNode.style);
+
+
+ this.el.appendChild(this.$main);
+ this.el.appendChild(this.$measureNode);
+ parentEl.appendChild(this.el);
+
+ if (!CHAR_COUNT)
+ this.$testFractionalRect();
+ this.$measureNode.innerHTML = lang.stringRepeat("X", CHAR_COUNT);
+
+ this.$characterSize = {width: 0, height: 0};
+ this.checkForSizeChanges();
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.$characterSize = {width: 0, height: 0};
+
+ this.$testFractionalRect = function() {
+ var el = dom.createElement("div");
+ this.$setMeasureNodeStyles(el.style);
+ el.style.width = "0.2px";
+ document.documentElement.appendChild(el);
+ var w = el.getBoundingClientRect().width;
+ if (w > 0 && w < 1)
+ CHAR_COUNT = 50;
+ else
+ CHAR_COUNT = 100;
+ el.parentNode.removeChild(el);
+ };
+
+ this.$setMeasureNodeStyles = function(style, isRoot) {
+ style.width = style.height = "auto";
+ style.left = style.top = "0px";
+ style.visibility = "hidden";
+ style.position = "absolute";
+ style.whiteSpace = "pre";
+
+ if (useragent.isIE < 8) {
+ style["font-family"] = "inherit";
+ } else {
+ style.font = "inherit";
+ }
+ style.overflow = isRoot ? "hidden" : "visible";
+ };
+
+ this.checkForSizeChanges = function() {
+ var size = this.$measureSizes();
+ if (size && (this.$characterSize.width !== size.width || this.$characterSize.height !== size.height)) {
+ this.$measureNode.style.fontWeight = "bold";
+ var boldSize = this.$measureSizes();
+ this.$measureNode.style.fontWeight = "";
+ this.$characterSize = size;
+ this.charSizes = Object.create(null);
+ this.allowBoldFonts = boldSize && boldSize.width === size.width && boldSize.height === size.height;
+ this._emit("changeCharacterSize", {data: size});
+ }
+ };
+
+ this.$pollSizeChanges = function() {
+ if (this.$pollSizeChangesTimer)
+ return this.$pollSizeChangesTimer;
+ var self = this;
+ return this.$pollSizeChangesTimer = setInterval(function() {
+ self.checkForSizeChanges();
+ }, 500);
+ };
+
+ this.setPolling = function(val) {
+ if (val) {
+ this.$pollSizeChanges();
+ } else if (this.$pollSizeChangesTimer) {
+ clearInterval(this.$pollSizeChangesTimer);
+ this.$pollSizeChangesTimer = 0;
+ }
+ };
+
+ this.$measureSizes = function() {
+ if (CHAR_COUNT === 50) {
+ var rect = null;
+ try {
+ rect = this.$measureNode.getBoundingClientRect();
+ } catch(e) {
+ rect = {width: 0, height:0 };
+ }
+ var size = {
+ height: rect.height,
+ width: rect.width / CHAR_COUNT
+ };
+ } else {
+ var size = {
+ height: this.$measureNode.clientHeight,
+ width: this.$measureNode.clientWidth / CHAR_COUNT
+ };
+ }
+ if (size.width === 0 || size.height === 0)
+ return null;
+ return size;
+ };
+
+ this.$measureCharWidth = function(ch) {
+ this.$main.innerHTML = lang.stringRepeat(ch, CHAR_COUNT);
+ var rect = this.$main.getBoundingClientRect();
+ return rect.width / CHAR_COUNT;
+ };
+
+ this.getCharacterWidth = function(ch) {
+ var w = this.charSizes[ch];
+ if (w === undefined) {
+ w = this.charSizes[ch] = this.$measureCharWidth(ch) / this.$characterSize.width;
+ }
+ return w;
+ };
+
+ this.destroy = function() {
+ clearInterval(this.$pollSizeChangesTimer);
+ if (this.el && this.el.parentNode)
+ this.el.parentNode.removeChild(this.el);
+ };
+
+}).call(FontMetrics.prototype);
+
+});
+
+ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/config","ace/lib/useragent","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var dom = require("./lib/dom");
+var config = require("./config");
+var useragent = require("./lib/useragent");
+var GutterLayer = require("./layer/gutter").Gutter;
+var MarkerLayer = require("./layer/marker").Marker;
+var TextLayer = require("./layer/text").Text;
+var CursorLayer = require("./layer/cursor").Cursor;
+var HScrollBar = require("./scrollbar").HScrollBar;
+var VScrollBar = require("./scrollbar").VScrollBar;
+var RenderLoop = require("./renderloop").RenderLoop;
+var FontMetrics = require("./layer/font_metrics").FontMetrics;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var editorCss = ".ace_editor {\
+position: relative;\
+overflow: hidden;\
+font: 12px/normal 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', monospace;\
+direction: ltr;\
+text-align: left;\
+-webkit-tap-highlight-color: rgba(0, 0, 0, 0);\
+}\
+.ace_scroller {\
+position: absolute;\
+overflow: hidden;\
+top: 0;\
+bottom: 0;\
+background-color: inherit;\
+-ms-user-select: none;\
+-moz-user-select: none;\
+-webkit-user-select: none;\
+user-select: none;\
+cursor: text;\
+}\
+.ace_content {\
+position: absolute;\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+min-width: 100%;\
+}\
+.ace_dragging .ace_scroller:before{\
+position: absolute;\
+top: 0;\
+left: 0;\
+right: 0;\
+bottom: 0;\
+content: '';\
+background: rgba(250, 250, 250, 0.01);\
+z-index: 1000;\
+}\
+.ace_dragging.ace_dark .ace_scroller:before{\
+background: rgba(0, 0, 0, 0.01);\
+}\
+.ace_selecting, .ace_selecting * {\
+cursor: text !important;\
+}\
+.ace_gutter {\
+position: absolute;\
+overflow : hidden;\
+width: auto;\
+top: 0;\
+bottom: 0;\
+left: 0;\
+cursor: default;\
+z-index: 4;\
+-ms-user-select: none;\
+-moz-user-select: none;\
+-webkit-user-select: none;\
+user-select: none;\
+}\
+.ace_gutter-active-line {\
+position: absolute;\
+left: 0;\
+right: 0;\
+}\
+.ace_scroller.ace_scroll-left {\
+box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;\
+}\
+.ace_gutter-cell {\
+padding-left: 19px;\
+padding-right: 6px;\
+background-repeat: no-repeat;\
+}\
+.ace_gutter-cell.ace_error {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==\");\
+background-repeat: no-repeat;\
+background-position: 2px center;\
+}\
+.ace_gutter-cell.ace_warning {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==\");\
+background-position: 2px center;\
+}\
+.ace_gutter-cell.ace_info {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=\");\
+background-position: 2px center;\
+}\
+.ace_dark .ace_gutter-cell.ace_info {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC\");\
+}\
+.ace_scrollbar {\
+position: absolute;\
+right: 0;\
+bottom: 0;\
+z-index: 6;\
+}\
+.ace_scrollbar-inner {\
+position: absolute;\
+cursor: text;\
+left: 0;\
+top: 0;\
+}\
+.ace_scrollbar-v{\
+overflow-x: hidden;\
+overflow-y: scroll;\
+top: 0;\
+}\
+.ace_scrollbar-h {\
+overflow-x: scroll;\
+overflow-y: hidden;\
+left: 0;\
+}\
+.ace_print-margin {\
+position: absolute;\
+height: 100%;\
+}\
+.ace_text-input {\
+position: absolute;\
+z-index: 0;\
+width: 0.5em;\
+height: 1em;\
+opacity: 0;\
+background: transparent;\
+-moz-appearance: none;\
+appearance: none;\
+border: none;\
+resize: none;\
+outline: none;\
+overflow: hidden;\
+font: inherit;\
+padding: 0 1px;\
+margin: 0 -1px;\
+text-indent: -1em;\
+-ms-user-select: text;\
+-moz-user-select: text;\
+-webkit-user-select: text;\
+user-select: text;\
+white-space: pre!important;\
+}\
+.ace_text-input.ace_composition {\
+background: inherit;\
+color: inherit;\
+z-index: 1000;\
+opacity: 1;\
+text-indent: 0;\
+}\
+.ace_layer {\
+z-index: 1;\
+position: absolute;\
+overflow: hidden;\
+word-wrap: normal;\
+white-space: pre;\
+height: 100%;\
+width: 100%;\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+pointer-events: none;\
+}\
+.ace_gutter-layer {\
+position: relative;\
+width: auto;\
+text-align: right;\
+pointer-events: auto;\
+}\
+.ace_text-layer {\
+font: inherit !important;\
+}\
+.ace_cjk {\
+display: inline-block;\
+text-align: center;\
+}\
+.ace_cursor-layer {\
+z-index: 4;\
+}\
+.ace_cursor {\
+z-index: 4;\
+position: absolute;\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+border-left: 2px solid;\
+transform: translatez(0);\
+}\
+.ace_multiselect .ace_cursor {\
+border-left-width: 1px;\
+}\
+.ace_slim-cursors .ace_cursor {\
+border-left-width: 1px;\
+}\
+.ace_overwrite-cursors .ace_cursor {\
+border-left-width: 0;\
+border-bottom: 1px solid;\
+}\
+.ace_hidden-cursors .ace_cursor {\
+opacity: 0.2;\
+}\
+.ace_smooth-blinking .ace_cursor {\
+-webkit-transition: opacity 0.18s;\
+transition: opacity 0.18s;\
+}\
+.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {\
+position: absolute;\
+z-index: 3;\
+}\
+.ace_marker-layer .ace_selection {\
+position: absolute;\
+z-index: 5;\
+}\
+.ace_marker-layer .ace_bracket {\
+position: absolute;\
+z-index: 6;\
+}\
+.ace_marker-layer .ace_active-line {\
+position: absolute;\
+z-index: 2;\
+}\
+.ace_marker-layer .ace_selected-word {\
+position: absolute;\
+z-index: 4;\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+}\
+.ace_line .ace_fold {\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+display: inline-block;\
+height: 11px;\
+margin-top: -2px;\
+vertical-align: middle;\
+background-image:\
+url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII=\"),\
+url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=\");\
+background-repeat: no-repeat, repeat-x;\
+background-position: center center, top left;\
+color: transparent;\
+border: 1px solid black;\
+border-radius: 2px;\
+cursor: pointer;\
+pointer-events: auto;\
+}\
+.ace_dark .ace_fold {\
+}\
+.ace_fold:hover{\
+background-image:\
+url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII=\"),\
+url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC\");\
+}\
+.ace_tooltip {\
+background-color: #FFF;\
+background-image: -webkit-linear-gradient(top, transparent, rgba(0, 0, 0, 0.1));\
+background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));\
+border: 1px solid gray;\
+border-radius: 1px;\
+box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);\
+color: black;\
+max-width: 100%;\
+padding: 3px 4px;\
+position: fixed;\
+z-index: 999999;\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+cursor: default;\
+white-space: pre;\
+word-wrap: break-word;\
+line-height: normal;\
+font-style: normal;\
+font-weight: normal;\
+letter-spacing: normal;\
+pointer-events: none;\
+}\
+.ace_folding-enabled > .ace_gutter-cell {\
+padding-right: 13px;\
+}\
+.ace_fold-widget {\
+-moz-box-sizing: border-box;\
+-webkit-box-sizing: border-box;\
+box-sizing: border-box;\
+margin: 0 -12px 0 1px;\
+display: none;\
+width: 11px;\
+vertical-align: top;\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==\");\
+background-repeat: no-repeat;\
+background-position: center;\
+border-radius: 3px;\
+border: 1px solid transparent;\
+cursor: pointer;\
+}\
+.ace_folding-enabled .ace_fold-widget {\
+display: inline-block; \
+}\
+.ace_fold-widget.ace_end {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==\");\
+}\
+.ace_fold-widget.ace_closed {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==\");\
+}\
+.ace_fold-widget:hover {\
+border: 1px solid rgba(0, 0, 0, 0.3);\
+background-color: rgba(255, 255, 255, 0.2);\
+box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);\
+}\
+.ace_fold-widget:active {\
+border: 1px solid rgba(0, 0, 0, 0.4);\
+background-color: rgba(0, 0, 0, 0.05);\
+box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);\
+}\
+.ace_dark .ace_fold-widget {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC\");\
+}\
+.ace_dark .ace_fold-widget.ace_end {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==\");\
+}\
+.ace_dark .ace_fold-widget.ace_closed {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==\");\
+}\
+.ace_dark .ace_fold-widget:hover {\
+box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\
+background-color: rgba(255, 255, 255, 0.1);\
+}\
+.ace_dark .ace_fold-widget:active {\
+box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);\
+}\
+.ace_fold-widget.ace_invalid {\
+background-color: #FFB4B4;\
+border-color: #DE5555;\
+}\
+.ace_fade-fold-widgets .ace_fold-widget {\
+-webkit-transition: opacity 0.4s ease 0.05s;\
+transition: opacity 0.4s ease 0.05s;\
+opacity: 0;\
+}\
+.ace_fade-fold-widgets:hover .ace_fold-widget {\
+-webkit-transition: opacity 0.05s ease 0.05s;\
+transition: opacity 0.05s ease 0.05s;\
+opacity:1;\
+}\
+.ace_underline {\
+text-decoration: underline;\
+}\
+.ace_bold {\
+font-weight: bold;\
+}\
+.ace_nobold .ace_bold {\
+font-weight: normal;\
+}\
+.ace_italic {\
+font-style: italic;\
+}\
+.ace_error-marker {\
+background-color: rgba(255, 0, 0,0.2);\
+position: absolute;\
+z-index: 9;\
+}\
+.ace_highlight-marker {\
+background-color: rgba(255, 255, 0,0.2);\
+position: absolute;\
+z-index: 8;\
+}\
+.ace_br1 {border-top-left-radius : 3px;}\
+.ace_br2 {border-top-right-radius : 3px;}\
+.ace_br3 {border-top-left-radius : 3px; border-top-right-radius: 3px;}\
+.ace_br4 {border-bottom-right-radius: 3px;}\
+.ace_br5 {border-top-left-radius : 3px; border-bottom-right-radius: 3px;}\
+.ace_br6 {border-top-right-radius : 3px; border-bottom-right-radius: 3px;}\
+.ace_br7 {border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px;}\
+.ace_br8 {border-bottom-left-radius : 3px;}\
+.ace_br9 {border-top-left-radius : 3px; border-bottom-left-radius: 3px;}\
+.ace_br10{border-top-right-radius : 3px; border-bottom-left-radius: 3px;}\
+.ace_br11{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-left-radius: 3px;}\
+.ace_br12{border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\
+.ace_br13{border-top-left-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\
+.ace_br14{border-top-right-radius : 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\
+.ace_br15{border-top-left-radius : 3px; border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-bottom-left-radius: 3px;}\
+.ace_text-input-ios {\
+position: absolute !important;\
+top: -100000px !important;\
+left: -100000px !important;\
+}\
+";
+
+dom.importCssString(editorCss, "ace_editor.css");
+
+var VirtualRenderer = function(container, theme) {
+ var _self = this;
+
+ this.container = container || dom.createElement("div");
+ this.$keepTextAreaAtCursor = !useragent.isOldIE;
+
+ dom.addCssClass(this.container, "ace_editor");
+
+ this.setTheme(theme);
+
+ this.$gutter = dom.createElement("div");
+ this.$gutter.className = "ace_gutter";
+ this.container.appendChild(this.$gutter);
+ this.$gutter.setAttribute("aria-hidden", true);
+
+ this.scroller = dom.createElement("div");
+ this.scroller.className = "ace_scroller";
+ this.container.appendChild(this.scroller);
+
+ this.content = dom.createElement("div");
+ this.content.className = "ace_content";
+ this.scroller.appendChild(this.content);
+
+ this.$gutterLayer = new GutterLayer(this.$gutter);
+ this.$gutterLayer.on("changeGutterWidth", this.onGutterResize.bind(this));
+
+ this.$markerBack = new MarkerLayer(this.content);
+
+ var textLayer = this.$textLayer = new TextLayer(this.content);
+ this.canvas = textLayer.element;
+
+ this.$markerFront = new MarkerLayer(this.content);
+
+ this.$cursorLayer = new CursorLayer(this.content);
+ this.$horizScroll = false;
+ this.$vScroll = false;
+
+ this.scrollBar =
+ this.scrollBarV = new VScrollBar(this.container, this);
+ this.scrollBarH = new HScrollBar(this.container, this);
+ this.scrollBarV.addEventListener("scroll", function(e) {
+ if (!_self.$scrollAnimation)
+ _self.session.setScrollTop(e.data - _self.scrollMargin.top);
+ });
+ this.scrollBarH.addEventListener("scroll", function(e) {
+ if (!_self.$scrollAnimation)
+ _self.session.setScrollLeft(e.data - _self.scrollMargin.left);
+ });
+
+ this.scrollTop = 0;
+ this.scrollLeft = 0;
+
+ this.cursorPos = {
+ row : 0,
+ column : 0
+ };
+
+ this.$fontMetrics = new FontMetrics(this.container);
+ this.$textLayer.$setFontMetrics(this.$fontMetrics);
+ this.$textLayer.addEventListener("changeCharacterSize", function(e) {
+ _self.updateCharacterSize();
+ _self.onResize(true, _self.gutterWidth, _self.$size.width, _self.$size.height);
+ _self._signal("changeCharacterSize", e);
+ });
+
+ this.$size = {
+ width: 0,
+ height: 0,
+ scrollerHeight: 0,
+ scrollerWidth: 0,
+ $dirty: true
+ };
+
+ this.layerConfig = {
+ width : 1,
+ padding : 0,
+ firstRow : 0,
+ firstRowScreen: 0,
+ lastRow : 0,
+ lineHeight : 0,
+ characterWidth : 0,
+ minHeight : 1,
+ maxHeight : 1,
+ offset : 0,
+ height : 1,
+ gutterOffset: 1
+ };
+
+ this.scrollMargin = {
+ left: 0,
+ right: 0,
+ top: 0,
+ bottom: 0,
+ v: 0,
+ h: 0
+ };
+
+ this.$loop = new RenderLoop(
+ this.$renderChanges.bind(this),
+ this.container.ownerDocument.defaultView
+ );
+ this.$loop.schedule(this.CHANGE_FULL);
+
+ this.updateCharacterSize();
+ this.setPadding(4);
+ config.resetOptions(this);
+ config._emit("renderer", this);
+};
+
+(function() {
+
+ this.CHANGE_CURSOR = 1;
+ this.CHANGE_MARKER = 2;
+ this.CHANGE_GUTTER = 4;
+ this.CHANGE_SCROLL = 8;
+ this.CHANGE_LINES = 16;
+ this.CHANGE_TEXT = 32;
+ this.CHANGE_SIZE = 64;
+ this.CHANGE_MARKER_BACK = 128;
+ this.CHANGE_MARKER_FRONT = 256;
+ this.CHANGE_FULL = 512;
+ this.CHANGE_H_SCROLL = 1024;
+
+ oop.implement(this, EventEmitter);
+
+ this.updateCharacterSize = function() {
+ if (this.$textLayer.allowBoldFonts != this.$allowBoldFonts) {
+ this.$allowBoldFonts = this.$textLayer.allowBoldFonts;
+ this.setStyle("ace_nobold", !this.$allowBoldFonts);
+ }
+
+ this.layerConfig.characterWidth =
+ this.characterWidth = this.$textLayer.getCharacterWidth();
+ this.layerConfig.lineHeight =
+ this.lineHeight = this.$textLayer.getLineHeight();
+ this.$updatePrintMargin();
+ };
+ this.setSession = function(session) {
+ if (this.session)
+ this.session.doc.off("changeNewLineMode", this.onChangeNewLineMode);
+
+ this.session = session;
+ if (session && this.scrollMargin.top && session.getScrollTop() <= 0)
+ session.setScrollTop(-this.scrollMargin.top);
+
+ this.$cursorLayer.setSession(session);
+ this.$markerBack.setSession(session);
+ this.$markerFront.setSession(session);
+ this.$gutterLayer.setSession(session);
+ this.$textLayer.setSession(session);
+ if (!session)
+ return;
+
+ this.$loop.schedule(this.CHANGE_FULL);
+ this.session.$setFontMetrics(this.$fontMetrics);
+ this.scrollBarH.scrollLeft = this.scrollBarV.scrollTop = null;
+
+ this.onChangeNewLineMode = this.onChangeNewLineMode.bind(this);
+ this.onChangeNewLineMode()
+ this.session.doc.on("changeNewLineMode", this.onChangeNewLineMode);
+ };
+ this.updateLines = function(firstRow, lastRow, force) {
+ if (lastRow === undefined)
+ lastRow = Infinity;
+
+ if (!this.$changedLines) {
+ this.$changedLines = {
+ firstRow: firstRow,
+ lastRow: lastRow
+ };
+ }
+ else {
+ if (this.$changedLines.firstRow > firstRow)
+ this.$changedLines.firstRow = firstRow;
+
+ if (this.$changedLines.lastRow < lastRow)
+ this.$changedLines.lastRow = lastRow;
+ }
+ if (this.$changedLines.lastRow < this.layerConfig.firstRow) {
+ if (force)
+ this.$changedLines.lastRow = this.layerConfig.lastRow;
+ else
+ return;
+ }
+ if (this.$changedLines.firstRow > this.layerConfig.lastRow)
+ return;
+ this.$loop.schedule(this.CHANGE_LINES);
+ };
+
+ this.onChangeNewLineMode = function() {
+ this.$loop.schedule(this.CHANGE_TEXT);
+ this.$textLayer.$updateEolChar();
+ this.session.$bidiHandler.setEolChar(this.$textLayer.EOL_CHAR);
+ };
+
+ this.onChangeTabSize = function() {
+ this.$loop.schedule(this.CHANGE_TEXT | this.CHANGE_MARKER);
+ this.$textLayer.onChangeTabSize();
+ };
+ this.updateText = function() {
+ this.$loop.schedule(this.CHANGE_TEXT);
+ };
+ this.updateFull = function(force) {
+ if (force)
+ this.$renderChanges(this.CHANGE_FULL, true);
+ else
+ this.$loop.schedule(this.CHANGE_FULL);
+ };
+ this.updateFontSize = function() {
+ this.$textLayer.checkForSizeChanges();
+ };
+
+ this.$changes = 0;
+ this.$updateSizeAsync = function() {
+ if (this.$loop.pending)
+ this.$size.$dirty = true;
+ else
+ this.onResize();
+ };
+ this.onResize = function(force, gutterWidth, width, height) {
+ if (this.resizing > 2)
+ return;
+ else if (this.resizing > 0)
+ this.resizing++;
+ else
+ this.resizing = force ? 1 : 0;
+ var el = this.container;
+ if (!height)
+ height = el.clientHeight || el.scrollHeight;
+ if (!width)
+ width = el.clientWidth || el.scrollWidth;
+ var changes = this.$updateCachedSize(force, gutterWidth, width, height);
+
+
+ if (!this.$size.scrollerHeight || (!width && !height))
+ return this.resizing = 0;
+
+ if (force)
+ this.$gutterLayer.$padding = null;
+
+ if (force)
+ this.$renderChanges(changes | this.$changes, true);
+ else
+ this.$loop.schedule(changes | this.$changes);
+
+ if (this.resizing)
+ this.resizing = 0;
+ this.scrollBarV.scrollLeft = this.scrollBarV.scrollTop = null;
+ };
+
+ this.$updateCachedSize = function(force, gutterWidth, width, height) {
+ height -= (this.$extraHeight || 0);
+ var changes = 0;
+ var size = this.$size;
+ var oldSize = {
+ width: size.width,
+ height: size.height,
+ scrollerHeight: size.scrollerHeight,
+ scrollerWidth: size.scrollerWidth
+ };
+ if (height && (force || size.height != height)) {
+ size.height = height;
+ changes |= this.CHANGE_SIZE;
+
+ size.scrollerHeight = size.height;
+ if (this.$horizScroll)
+ size.scrollerHeight -= this.scrollBarH.getHeight();
+ this.scrollBarV.element.style.bottom = this.scrollBarH.getHeight() + "px";
+
+ changes = changes | this.CHANGE_SCROLL;
+ }
+
+ if (width && (force || size.width != width)) {
+ changes |= this.CHANGE_SIZE;
+ size.width = width;
+
+ if (gutterWidth == null)
+ gutterWidth = this.$showGutter ? this.$gutter.offsetWidth : 0;
+
+ this.gutterWidth = gutterWidth;
+
+ this.scrollBarH.element.style.left =
+ this.scroller.style.left = gutterWidth + "px";
+ size.scrollerWidth = Math.max(0, width - gutterWidth - this.scrollBarV.getWidth());
+
+ this.scrollBarH.element.style.right =
+ this.scroller.style.right = this.scrollBarV.getWidth() + "px";
+ this.scroller.style.bottom = this.scrollBarH.getHeight() + "px";
+
+ if (this.session && this.session.getUseWrapMode() && this.adjustWrapLimit() || force)
+ changes |= this.CHANGE_FULL;
+ }
+
+ size.$dirty = !width || !height;
+
+ if (changes)
+ this._signal("resize", oldSize);
+
+ return changes;
+ };
+
+ this.onGutterResize = function() {
+ var gutterWidth = this.$showGutter ? this.$gutter.offsetWidth : 0;
+ if (gutterWidth != this.gutterWidth)
+ this.$changes |= this.$updateCachedSize(true, gutterWidth, this.$size.width, this.$size.height);
+
+ if (this.session.getUseWrapMode() && this.adjustWrapLimit()) {
+ this.$loop.schedule(this.CHANGE_FULL);
+ } else if (this.$size.$dirty) {
+ this.$loop.schedule(this.CHANGE_FULL);
+ } else {
+ this.$computeLayerConfig();
+ this.$loop.schedule(this.CHANGE_MARKER);
+ }
+ };
+ this.adjustWrapLimit = function() {
+ var availableWidth = this.$size.scrollerWidth - this.$padding * 2;
+ var limit = Math.floor(availableWidth / this.characterWidth);
+ return this.session.adjustWrapLimit(limit, this.$showPrintMargin && this.$printMarginColumn);
+ };
+ this.setAnimatedScroll = function(shouldAnimate){
+ this.setOption("animatedScroll", shouldAnimate);
+ };
+ this.getAnimatedScroll = function() {
+ return this.$animatedScroll;
+ };
+ this.setShowInvisibles = function(showInvisibles) {
+ this.setOption("showInvisibles", showInvisibles);
+ this.session.$bidiHandler.setShowInvisibles(showInvisibles);
+ };
+ this.getShowInvisibles = function() {
+ return this.getOption("showInvisibles");
+ };
+ this.getDisplayIndentGuides = function() {
+ return this.getOption("displayIndentGuides");
+ };
+
+ this.setDisplayIndentGuides = function(display) {
+ this.setOption("displayIndentGuides", display);
+ };
+ this.setShowPrintMargin = function(showPrintMargin) {
+ this.setOption("showPrintMargin", showPrintMargin);
+ };
+ this.getShowPrintMargin = function() {
+ return this.getOption("showPrintMargin");
+ };
+ this.setPrintMarginColumn = function(showPrintMargin) {
+ this.setOption("printMarginColumn", showPrintMargin);
+ };
+ this.getPrintMarginColumn = function() {
+ return this.getOption("printMarginColumn");
+ };
+ this.getShowGutter = function(){
+ return this.getOption("showGutter");
+ };
+ this.setShowGutter = function(show){
+ return this.setOption("showGutter", show);
+ };
+
+ this.getFadeFoldWidgets = function(){
+ return this.getOption("fadeFoldWidgets")
+ };
+
+ this.setFadeFoldWidgets = function(show) {
+ this.setOption("fadeFoldWidgets", show);
+ };
+
+ this.setHighlightGutterLine = function(shouldHighlight) {
+ this.setOption("highlightGutterLine", shouldHighlight);
+ };
+
+ this.getHighlightGutterLine = function() {
+ return this.getOption("highlightGutterLine");
+ };
+
+ this.$updateGutterLineHighlight = function() {
+ var pos = this.$cursorLayer.$pixelPos;
+ var height = this.layerConfig.lineHeight;
+ if (this.session.getUseWrapMode()) {
+ var cursor = this.session.selection.getCursor();
+ cursor.column = 0;
+ pos = this.$cursorLayer.getPixelPosition(cursor, true);
+ height *= this.session.getRowLength(cursor.row);
+ }
+ this.$gutterLineHighlight.style.top = pos.top - this.layerConfig.offset + "px";
+ this.$gutterLineHighlight.style.height = height + "px";
+ };
+
+ this.$updatePrintMargin = function() {
+ if (!this.$showPrintMargin && !this.$printMarginEl)
+ return;
+
+ if (!this.$printMarginEl) {
+ var containerEl = dom.createElement("div");
+ containerEl.className = "ace_layer ace_print-margin-layer";
+ this.$printMarginEl = dom.createElement("div");
+ this.$printMarginEl.className = "ace_print-margin";
+ containerEl.appendChild(this.$printMarginEl);
+ this.content.insertBefore(containerEl, this.content.firstChild);
+ }
+
+ var style = this.$printMarginEl.style;
+ style.left = ((this.characterWidth * this.$printMarginColumn) + this.$padding) + "px";
+ style.visibility = this.$showPrintMargin ? "visible" : "hidden";
+
+ if (this.session && this.session.$wrap == -1)
+ this.adjustWrapLimit();
+ };
+ this.getContainerElement = function() {
+ return this.container;
+ };
+ this.getMouseEventTarget = function() {
+ return this.scroller;
+ };
+ this.getTextAreaContainer = function() {
+ return this.container;
+ };
+ this.$moveTextAreaToCursor = function() {
+ if (!this.$keepTextAreaAtCursor)
+ return;
+ var config = this.layerConfig;
+ var posTop = this.$cursorLayer.$pixelPos.top;
+ var posLeft = this.$cursorLayer.$pixelPos.left;
+ posTop -= config.offset;
+
+ var style = this.textarea.style;
+ var h = this.lineHeight;
+ if (posTop < 0 || posTop > config.height - h) {
+ style.top = style.left = "0";
+ return;
+ }
+
+ var w = this.characterWidth;
+ if (this.$composition) {
+ var val = this.textarea.value.replace(/^\x01+/, "");
+ w *= (this.session.$getStringScreenWidth(val)[0]+2);
+ h += 2;
+ }
+ posLeft -= this.scrollLeft;
+ if (posLeft > this.$size.scrollerWidth - w)
+ posLeft = this.$size.scrollerWidth - w;
+
+ posLeft += this.gutterWidth;
+ style.height = h + "px";
+ style.width = w + "px";
+ style.left = Math.min(posLeft, this.$size.scrollerWidth - w) + "px";
+ style.top = Math.min(posTop, this.$size.height - h) + "px";
+ };
+ this.getFirstVisibleRow = function() {
+ return this.layerConfig.firstRow;
+ };
+ this.getFirstFullyVisibleRow = function() {
+ return this.layerConfig.firstRow + (this.layerConfig.offset === 0 ? 0 : 1);
+ };
+ this.getLastFullyVisibleRow = function() {
+ var config = this.layerConfig;
+ var lastRow = config.lastRow
+ var top = this.session.documentToScreenRow(lastRow, 0) * config.lineHeight;
+ if (top - this.session.getScrollTop() > config.height - config.lineHeight)
+ return lastRow - 1;
+ return lastRow;
+ };
+ this.getLastVisibleRow = function() {
+ return this.layerConfig.lastRow;
+ };
+
+ this.$padding = null;
+ this.setPadding = function(padding) {
+ this.$padding = padding;
+ this.$textLayer.setPadding(padding);
+ this.$cursorLayer.setPadding(padding);
+ this.$markerFront.setPadding(padding);
+ this.$markerBack.setPadding(padding);
+ this.$loop.schedule(this.CHANGE_FULL);
+ this.$updatePrintMargin();
+ };
+
+ this.setScrollMargin = function(top, bottom, left, right) {
+ var sm = this.scrollMargin;
+ sm.top = top|0;
+ sm.bottom = bottom|0;
+ sm.right = right|0;
+ sm.left = left|0;
+ sm.v = sm.top + sm.bottom;
+ sm.h = sm.left + sm.right;
+ if (sm.top && this.scrollTop <= 0 && this.session)
+ this.session.setScrollTop(-sm.top);
+ this.updateFull();
+ };
+ this.getHScrollBarAlwaysVisible = function() {
+ return this.$hScrollBarAlwaysVisible;
+ };
+ this.setHScrollBarAlwaysVisible = function(alwaysVisible) {
+ this.setOption("hScrollBarAlwaysVisible", alwaysVisible);
+ };
+ this.getVScrollBarAlwaysVisible = function() {
+ return this.$vScrollBarAlwaysVisible;
+ };
+ this.setVScrollBarAlwaysVisible = function(alwaysVisible) {
+ this.setOption("vScrollBarAlwaysVisible", alwaysVisible);
+ };
+
+ this.$updateScrollBarV = function() {
+ var scrollHeight = this.layerConfig.maxHeight;
+ var scrollerHeight = this.$size.scrollerHeight;
+ if (!this.$maxLines && this.$scrollPastEnd) {
+ scrollHeight -= (scrollerHeight - this.lineHeight) * this.$scrollPastEnd;
+ if (this.scrollTop > scrollHeight - scrollerHeight) {
+ scrollHeight = this.scrollTop + scrollerHeight;
+ this.scrollBarV.scrollTop = null;
+ }
+ }
+ this.scrollBarV.setScrollHeight(scrollHeight + this.scrollMargin.v);
+ this.scrollBarV.setScrollTop(this.scrollTop + this.scrollMargin.top);
+ };
+ this.$updateScrollBarH = function() {
+ this.scrollBarH.setScrollWidth(this.layerConfig.width + 2 * this.$padding + this.scrollMargin.h);
+ this.scrollBarH.setScrollLeft(this.scrollLeft + this.scrollMargin.left);
+ };
+
+ this.$frozen = false;
+ this.freeze = function() {
+ this.$frozen = true;
+ };
+
+ this.unfreeze = function() {
+ this.$frozen = false;
+ };
+
+ this.$renderChanges = function(changes, force) {
+ if (this.$changes) {
+ changes |= this.$changes;
+ this.$changes = 0;
+ }
+ if ((!this.session || !this.container.offsetWidth || this.$frozen) || (!changes && !force)) {
+ this.$changes |= changes;
+ return;
+ }
+ if (this.$size.$dirty) {
+ this.$changes |= changes;
+ return this.onResize(true);
+ }
+ if (!this.lineHeight) {
+ this.$textLayer.checkForSizeChanges();
+ }
+
+ this._signal("beforeRender");
+ var config = this.layerConfig;
+ if (changes & this.CHANGE_FULL ||
+ changes & this.CHANGE_SIZE ||
+ changes & this.CHANGE_TEXT ||
+ changes & this.CHANGE_LINES ||
+ changes & this.CHANGE_SCROLL ||
+ changes & this.CHANGE_H_SCROLL
+ ) {
+ changes |= this.$computeLayerConfig();
+ if (config.firstRow != this.layerConfig.firstRow && config.firstRowScreen == this.layerConfig.firstRowScreen) {
+ var st = this.scrollTop + (config.firstRow - this.layerConfig.firstRow) * this.lineHeight;
+ if (st > 0) {
+ this.scrollTop = st;
+ changes = changes | this.CHANGE_SCROLL;
+ changes |= this.$computeLayerConfig();
+ }
+ }
+ config = this.layerConfig;
+ this.$updateScrollBarV();
+ if (changes & this.CHANGE_H_SCROLL)
+ this.$updateScrollBarH();
+ this.$gutterLayer.element.style.marginTop = (-config.offset) + "px";
+ this.content.style.marginTop = (-config.offset) + "px";
+ this.content.style.width = config.width + 2 * this.$padding + "px";
+ this.content.style.height = config.minHeight + "px";
+ }
+ if (changes & this.CHANGE_H_SCROLL) {
+ this.content.style.marginLeft = -this.scrollLeft + "px";
+ this.scroller.className = this.scrollLeft <= 0 ? "ace_scroller" : "ace_scroller ace_scroll-left";
+ }
+ if (changes & this.CHANGE_FULL) {
+ this.$textLayer.update(config);
+ if (this.$showGutter)
+ this.$gutterLayer.update(config);
+ this.$markerBack.update(config);
+ this.$markerFront.update(config);
+ this.$cursorLayer.update(config);
+
+ this.session.$bidiHandler.updateCharacterWidths(this.$fontMetrics);
+ if (this.session.$bidiHandler.getShowInvisibles() === undefined)
+ this.session.$bidiHandler.setShowInvisibles(this.getShowInvisibles());
+
+ this.$moveTextAreaToCursor();
+ this.$highlightGutterLine && this.$updateGutterLineHighlight();
+ this._signal("afterRender");
+ return;
+ }
+ if (changes & this.CHANGE_SCROLL) {
+ if (changes & this.CHANGE_TEXT || changes & this.CHANGE_LINES)
+ this.$textLayer.update(config);
+ else
+ this.$textLayer.scrollLines(config);
+
+ if (this.$showGutter)
+ this.$gutterLayer.update(config);
+ this.$markerBack.update(config);
+ this.$markerFront.update(config);
+ this.$cursorLayer.update(config);
+ this.$highlightGutterLine && this.$updateGutterLineHighlight();
+ this.$moveTextAreaToCursor();
+ this._signal("afterRender");
+ return;
+ }
+
+ if (changes & this.CHANGE_TEXT) {
+ this.$textLayer.update(config);
+ if (this.$showGutter)
+ this.$gutterLayer.update(config);
+ }
+ else if (changes & this.CHANGE_LINES) {
+ if (this.$updateLines() || (changes & this.CHANGE_GUTTER) && this.$showGutter)
+ this.$gutterLayer.update(config);
+ }
+ else if (changes & this.CHANGE_TEXT || changes & this.CHANGE_GUTTER) {
+ if (this.$showGutter)
+ this.$gutterLayer.update(config);
+ }
+
+ if (changes & this.CHANGE_CURSOR) {
+ this.$cursorLayer.update(config);
+ this.$moveTextAreaToCursor();
+ this.$highlightGutterLine && this.$updateGutterLineHighlight();
+ }
+
+ if (changes & (this.CHANGE_MARKER | this.CHANGE_MARKER_FRONT)) {
+ this.$markerFront.update(config);
+ }
+
+ if (changes & (this.CHANGE_MARKER | this.CHANGE_MARKER_BACK)) {
+ this.$markerBack.update(config);
+ }
+
+ this._signal("afterRender");
+ };
+
+
+ this.$autosize = function() {
+ var height = this.session.getScreenLength() * this.lineHeight;
+ var maxHeight = this.$maxLines * this.lineHeight;
+ var desiredHeight = Math.min(maxHeight,
+ Math.max((this.$minLines || 1) * this.lineHeight, height)
+ ) + this.scrollMargin.v + (this.$extraHeight || 0);
+ if (this.$horizScroll)
+ desiredHeight += this.scrollBarH.getHeight();
+ if (this.$maxPixelHeight && desiredHeight > this.$maxPixelHeight)
+ desiredHeight = this.$maxPixelHeight;
+ var vScroll = height > maxHeight;
+
+ if (desiredHeight != this.desiredHeight ||
+ this.$size.height != this.desiredHeight || vScroll != this.$vScroll) {
+ if (vScroll != this.$vScroll) {
+ this.$vScroll = vScroll;
+ this.scrollBarV.setVisible(vScroll);
+ }
+
+ var w = this.container.clientWidth;
+ this.container.style.height = desiredHeight + "px";
+ this.$updateCachedSize(true, this.$gutterWidth, w, desiredHeight);
+ this.desiredHeight = desiredHeight;
+
+ this._signal("autosize");
+ }
+ };
+
+ this.$computeLayerConfig = function() {
+ var session = this.session;
+ var size = this.$size;
+
+ var hideScrollbars = size.height <= 2 * this.lineHeight;
+ var screenLines = this.session.getScreenLength();
+ var maxHeight = screenLines * this.lineHeight;
+
+ var longestLine = this.$getLongestLine();
+
+ var horizScroll = !hideScrollbars && (this.$hScrollBarAlwaysVisible ||
+ size.scrollerWidth - longestLine - 2 * this.$padding < 0);
+
+ var hScrollChanged = this.$horizScroll !== horizScroll;
+ if (hScrollChanged) {
+ this.$horizScroll = horizScroll;
+ this.scrollBarH.setVisible(horizScroll);
+ }
+ var vScrollBefore = this.$vScroll; // autosize can change vscroll value in which case we need to update longestLine
+ if (this.$maxLines && this.lineHeight > 1)
+ this.$autosize();
+
+ var offset = this.scrollTop % this.lineHeight;
+ var minHeight = size.scrollerHeight + this.lineHeight;
+
+ var scrollPastEnd = !this.$maxLines && this.$scrollPastEnd
+ ? (size.scrollerHeight - this.lineHeight) * this.$scrollPastEnd
+ : 0;
+ maxHeight += scrollPastEnd;
+
+ var sm = this.scrollMargin;
+ this.session.setScrollTop(Math.max(-sm.top,
+ Math.min(this.scrollTop, maxHeight - size.scrollerHeight + sm.bottom)));
+
+ this.session.setScrollLeft(Math.max(-sm.left, Math.min(this.scrollLeft,
+ longestLine + 2 * this.$padding - size.scrollerWidth + sm.right)));
+
+ var vScroll = !hideScrollbars && (this.$vScrollBarAlwaysVisible ||
+ size.scrollerHeight - maxHeight + scrollPastEnd < 0 || this.scrollTop > sm.top);
+ var vScrollChanged = vScrollBefore !== vScroll;
+ if (vScrollChanged) {
+ this.$vScroll = vScroll;
+ this.scrollBarV.setVisible(vScroll);
+ }
+
+ var lineCount = Math.ceil(minHeight / this.lineHeight) - 1;
+ var firstRow = Math.max(0, Math.round((this.scrollTop - offset) / this.lineHeight));
+ var lastRow = firstRow + lineCount;
+ var firstRowScreen, firstRowHeight;
+ var lineHeight = this.lineHeight;
+ firstRow = session.screenToDocumentRow(firstRow, 0);
+ var foldLine = session.getFoldLine(firstRow);
+ if (foldLine) {
+ firstRow = foldLine.start.row;
+ }
+
+ firstRowScreen = session.documentToScreenRow(firstRow, 0);
+ firstRowHeight = session.getRowLength(firstRow) * lineHeight;
+
+ lastRow = Math.min(session.screenToDocumentRow(lastRow, 0), session.getLength() - 1);
+ minHeight = size.scrollerHeight + session.getRowLength(lastRow) * lineHeight +
+ firstRowHeight;
+
+ offset = this.scrollTop - firstRowScreen * lineHeight;
+
+ var changes = 0;
+ if (this.layerConfig.width != longestLine)
+ changes = this.CHANGE_H_SCROLL;
+ if (hScrollChanged || vScrollChanged) {
+ changes = this.$updateCachedSize(true, this.gutterWidth, size.width, size.height);
+ this._signal("scrollbarVisibilityChanged");
+ if (vScrollChanged)
+ longestLine = this.$getLongestLine();
+ }
+
+ this.layerConfig = {
+ width : longestLine,
+ padding : this.$padding,
+ firstRow : firstRow,
+ firstRowScreen: firstRowScreen,
+ lastRow : lastRow,
+ lineHeight : lineHeight,
+ characterWidth : this.characterWidth,
+ minHeight : minHeight,
+ maxHeight : maxHeight,
+ offset : offset,
+ gutterOffset : lineHeight ? Math.max(0, Math.ceil((offset + size.height - size.scrollerHeight) / lineHeight)) : 0,
+ height : this.$size.scrollerHeight
+ };
+
+ return changes;
+ };
+
+ this.$updateLines = function() {
+ if (!this.$changedLines) return;
+ var firstRow = this.$changedLines.firstRow;
+ var lastRow = this.$changedLines.lastRow;
+ this.$changedLines = null;
+
+ var layerConfig = this.layerConfig;
+
+ if (firstRow > layerConfig.lastRow + 1) { return; }
+ if (lastRow < layerConfig.firstRow) { return; }
+ if (lastRow === Infinity) {
+ if (this.$showGutter)
+ this.$gutterLayer.update(layerConfig);
+ this.$textLayer.update(layerConfig);
+ return;
+ }
+ this.$textLayer.updateLines(layerConfig, firstRow, lastRow);
+ return true;
+ };
+
+ this.$getLongestLine = function() {
+ var charCount = this.session.getScreenWidth();
+ if (this.showInvisibles && !this.session.$useWrapMode)
+ charCount += 1;
+
+ return Math.max(this.$size.scrollerWidth - 2 * this.$padding, Math.round(charCount * this.characterWidth));
+ };
+ this.updateFrontMarkers = function() {
+ this.$markerFront.setMarkers(this.session.getMarkers(true));
+ this.$loop.schedule(this.CHANGE_MARKER_FRONT);
+ };
+ this.updateBackMarkers = function() {
+ this.$markerBack.setMarkers(this.session.getMarkers());
+ this.$loop.schedule(this.CHANGE_MARKER_BACK);
+ };
+ this.addGutterDecoration = function(row, className){
+ this.$gutterLayer.addGutterDecoration(row, className);
+ };
+ this.removeGutterDecoration = function(row, className){
+ this.$gutterLayer.removeGutterDecoration(row, className);
+ };
+ this.updateBreakpoints = function(rows) {
+ this.$loop.schedule(this.CHANGE_GUTTER);
+ };
+ this.setAnnotations = function(annotations) {
+ this.$gutterLayer.setAnnotations(annotations);
+ this.$loop.schedule(this.CHANGE_GUTTER);
+ };
+ this.updateCursor = function() {
+ this.$loop.schedule(this.CHANGE_CURSOR);
+ };
+ this.hideCursor = function() {
+ this.$cursorLayer.hideCursor();
+ };
+ this.showCursor = function() {
+ this.$cursorLayer.showCursor();
+ };
+
+ this.scrollSelectionIntoView = function(anchor, lead, offset) {
+ this.scrollCursorIntoView(anchor, offset);
+ this.scrollCursorIntoView(lead, offset);
+ };
+ this.scrollCursorIntoView = function(cursor, offset, $viewMargin) {
+ if (this.$size.scrollerHeight === 0)
+ return;
+
+ var pos = this.$cursorLayer.getPixelPosition(cursor);
+
+ var left = pos.left;
+ var top = pos.top;
+
+ var topMargin = $viewMargin && $viewMargin.top || 0;
+ var bottomMargin = $viewMargin && $viewMargin.bottom || 0;
+
+ var scrollTop = this.$scrollAnimation ? this.session.getScrollTop() : this.scrollTop;
+
+ if (scrollTop + topMargin > top) {
+ if (offset && scrollTop + topMargin > top + this.lineHeight)
+ top -= offset * this.$size.scrollerHeight;
+ if (top === 0)
+ top = -this.scrollMargin.top;
+ this.session.setScrollTop(top);
+ } else if (scrollTop + this.$size.scrollerHeight - bottomMargin < top + this.lineHeight) {
+ if (offset && scrollTop + this.$size.scrollerHeight - bottomMargin < top - this.lineHeight)
+ top += offset * this.$size.scrollerHeight;
+ this.session.setScrollTop(top + this.lineHeight - this.$size.scrollerHeight);
+ }
+
+ var scrollLeft = this.scrollLeft;
+
+ if (scrollLeft > left) {
+ if (left < this.$padding + 2 * this.layerConfig.characterWidth)
+ left = -this.scrollMargin.left;
+ this.session.setScrollLeft(left);
+ } else if (scrollLeft + this.$size.scrollerWidth < left + this.characterWidth) {
+ this.session.setScrollLeft(Math.round(left + this.characterWidth - this.$size.scrollerWidth));
+ } else if (scrollLeft <= this.$padding && left - scrollLeft < this.characterWidth) {
+ this.session.setScrollLeft(0);
+ }
+ };
+ this.getScrollTop = function() {
+ return this.session.getScrollTop();
+ };
+ this.getScrollLeft = function() {
+ return this.session.getScrollLeft();
+ };
+ this.getScrollTopRow = function() {
+ return this.scrollTop / this.lineHeight;
+ };
+ this.getScrollBottomRow = function() {
+ return Math.max(0, Math.floor((this.scrollTop + this.$size.scrollerHeight) / this.lineHeight) - 1);
+ };
+ this.scrollToRow = function(row) {
+ this.session.setScrollTop(row * this.lineHeight);
+ };
+
+ this.alignCursor = function(cursor, alignment) {
+ if (typeof cursor == "number")
+ cursor = {row: cursor, column: 0};
+
+ var pos = this.$cursorLayer.getPixelPosition(cursor);
+ var h = this.$size.scrollerHeight - this.lineHeight;
+ var offset = pos.top - h * (alignment || 0);
+
+ this.session.setScrollTop(offset);
+ return offset;
+ };
+
+ this.STEPS = 8;
+ this.$calcSteps = function(fromValue, toValue){
+ var i = 0;
+ var l = this.STEPS;
+ var steps = [];
+
+ var func = function(t, x_min, dx) {
+ return dx * (Math.pow(t - 1, 3) + 1) + x_min;
+ };
+
+ for (i = 0; i < l; ++i)
+ steps.push(func(i / this.STEPS, fromValue, toValue - fromValue));
+
+ return steps;
+ };
+ this.scrollToLine = function(line, center, animate, callback) {
+ var pos = this.$cursorLayer.getPixelPosition({row: line, column: 0});
+ var offset = pos.top;
+ if (center)
+ offset -= this.$size.scrollerHeight / 2;
+
+ var initialScroll = this.scrollTop;
+ this.session.setScrollTop(offset);
+ if (animate !== false)
+ this.animateScrolling(initialScroll, callback);
+ };
+
+ this.animateScrolling = function(fromValue, callback) {
+ var toValue = this.scrollTop;
+ if (!this.$animatedScroll)
+ return;
+ var _self = this;
+
+ if (fromValue == toValue)
+ return;
+
+ if (this.$scrollAnimation) {
+ var oldSteps = this.$scrollAnimation.steps;
+ if (oldSteps.length) {
+ fromValue = oldSteps[0];
+ if (fromValue == toValue)
+ return;
+ }
+ }
+
+ var steps = _self.$calcSteps(fromValue, toValue);
+ this.$scrollAnimation = {from: fromValue, to: toValue, steps: steps};
+
+ clearInterval(this.$timer);
+
+ _self.session.setScrollTop(steps.shift());
+ _self.session.$scrollTop = toValue;
+ this.$timer = setInterval(function() {
+ if (steps.length) {
+ _self.session.setScrollTop(steps.shift());
+ _self.session.$scrollTop = toValue;
+ } else if (toValue != null) {
+ _self.session.$scrollTop = -1;
+ _self.session.setScrollTop(toValue);
+ toValue = null;
+ } else {
+ _self.$timer = clearInterval(_self.$timer);
+ _self.$scrollAnimation = null;
+ callback && callback();
+ }
+ }, 10);
+ };
+ this.scrollToY = function(scrollTop) {
+ if (this.scrollTop !== scrollTop) {
+ this.$loop.schedule(this.CHANGE_SCROLL);
+ this.scrollTop = scrollTop;
+ }
+ };
+ this.scrollToX = function(scrollLeft) {
+ if (this.scrollLeft !== scrollLeft)
+ this.scrollLeft = scrollLeft;
+ this.$loop.schedule(this.CHANGE_H_SCROLL);
+ };
+ this.scrollTo = function(x, y) {
+ this.session.setScrollTop(y);
+ this.session.setScrollLeft(y);
+ };
+ this.scrollBy = function(deltaX, deltaY) {
+ deltaY && this.session.setScrollTop(this.session.getScrollTop() + deltaY);
+ deltaX && this.session.setScrollLeft(this.session.getScrollLeft() + deltaX);
+ };
+ this.isScrollableBy = function(deltaX, deltaY) {
+ if (deltaY < 0 && this.session.getScrollTop() >= 1 - this.scrollMargin.top)
+ return true;
+ if (deltaY > 0 && this.session.getScrollTop() + this.$size.scrollerHeight
+ - this.layerConfig.maxHeight < -1 + this.scrollMargin.bottom)
+ return true;
+ if (deltaX < 0 && this.session.getScrollLeft() >= 1 - this.scrollMargin.left)
+ return true;
+ if (deltaX > 0 && this.session.getScrollLeft() + this.$size.scrollerWidth
+ - this.layerConfig.width < -1 + this.scrollMargin.right)
+ return true;
+ };
+
+ this.pixelToScreenCoordinates = function(x, y) {
+ var canvasPos = this.scroller.getBoundingClientRect();
+
+ var offsetX = x + this.scrollLeft - canvasPos.left - this.$padding;
+ var offset = offsetX / this.characterWidth;
+ var row = Math.floor((y + this.scrollTop - canvasPos.top) / this.lineHeight);
+ var col = Math.round(offset);
+
+ return {row: row, column: col, side: offset - col > 0 ? 1 : -1, offsetX: offsetX};
+ };
+
+ this.screenToTextCoordinates = function(x, y) {
+ var canvasPos = this.scroller.getBoundingClientRect();
+ var offsetX = x + this.scrollLeft - canvasPos.left - this.$padding;
+
+ var col = Math.round(offsetX / this.characterWidth);
+
+ var row = (y + this.scrollTop - canvasPos.top) / this.lineHeight;
+
+ return this.session.screenToDocumentPosition(row, Math.max(col, 0), offsetX);
+ };
+ this.textToScreenCoordinates = function(row, column) {
+ var canvasPos = this.scroller.getBoundingClientRect();
+ var pos = this.session.documentToScreenPosition(row, column);
+
+ var x = this.$padding + (this.session.$bidiHandler.isBidiRow(pos.row, row)
+ ? this.session.$bidiHandler.getPosLeft(pos.column)
+ : Math.round(pos.column * this.characterWidth));
+
+ var y = pos.row * this.lineHeight;
+
+ return {
+ pageX: canvasPos.left + x - this.scrollLeft,
+ pageY: canvasPos.top + y - this.scrollTop
+ };
+ };
+ this.visualizeFocus = function() {
+ dom.addCssClass(this.container, "ace_focus");
+ };
+ this.visualizeBlur = function() {
+ dom.removeCssClass(this.container, "ace_focus");
+ };
+ this.showComposition = function(position) {
+ if (!this.$composition)
+ this.$composition = {
+ keepTextAreaAtCursor: this.$keepTextAreaAtCursor,
+ cssText: this.textarea.style.cssText
+ };
+
+ this.$keepTextAreaAtCursor = true;
+ dom.addCssClass(this.textarea, "ace_composition");
+ this.textarea.style.cssText = "";
+ this.$moveTextAreaToCursor();
+ };
+ this.setCompositionText = function(text) {
+ this.$moveTextAreaToCursor();
+ };
+ this.hideComposition = function() {
+ if (!this.$composition)
+ return;
+
+ dom.removeCssClass(this.textarea, "ace_composition");
+ this.$keepTextAreaAtCursor = this.$composition.keepTextAreaAtCursor;
+ this.textarea.style.cssText = this.$composition.cssText;
+ this.$composition = null;
+ };
+ this.setTheme = function(theme, cb) {
+ var _self = this;
+ this.$themeId = theme;
+ _self._dispatchEvent('themeChange',{theme:theme});
+
+ if (!theme || typeof theme == "string") {
+ var moduleName = theme || this.$options.theme.initialValue;
+ config.loadModule(["theme", moduleName], afterLoad);
+ } else {
+ afterLoad(theme);
+ }
+
+ function afterLoad(module) {
+ if (_self.$themeId != theme)
+ return cb && cb();
+ if (!module || !module.cssClass)
+ throw new Error("couldn't load module " + theme + " or it didn't call define");
+ dom.importCssString(
+ module.cssText,
+ module.cssClass,
+ _self.container.ownerDocument
+ );
+
+ if (_self.theme)
+ dom.removeCssClass(_self.container, _self.theme.cssClass);
+
+ var padding = "padding" in module ? module.padding
+ : "padding" in (_self.theme || {}) ? 4 : _self.$padding;
+ if (_self.$padding && padding != _self.$padding)
+ _self.setPadding(padding);
+ _self.$theme = module.cssClass;
+
+ _self.theme = module;
+ dom.addCssClass(_self.container, module.cssClass);
+ dom.setCssClass(_self.container, "ace_dark", module.isDark);
+ if (_self.$size) {
+ _self.$size.width = 0;
+ _self.$updateSizeAsync();
+ }
+
+ _self._dispatchEvent('themeLoaded', {theme:module});
+ cb && cb();
+ }
+ };
+ this.getTheme = function() {
+ return this.$themeId;
+ };
+ this.setStyle = function(style, include) {
+ dom.setCssClass(this.container, style, include !== false);
+ };
+ this.unsetStyle = function(style) {
+ dom.removeCssClass(this.container, style);
+ };
+
+ this.setCursorStyle = function(style) {
+ if (this.scroller.style.cursor != style)
+ this.scroller.style.cursor = style;
+ };
+ this.setMouseCursor = function(cursorStyle) {
+ this.scroller.style.cursor = cursorStyle;
+ };
+ this.destroy = function() {
+ this.$textLayer.destroy();
+ this.$cursorLayer.destroy();
+ };
+
+}).call(VirtualRenderer.prototype);
+
+
+config.defineOptions(VirtualRenderer.prototype, "renderer", {
+ animatedScroll: {initialValue: false},
+ showInvisibles: {
+ set: function(value) {
+ if (this.$textLayer.setShowInvisibles(value))
+ this.$loop.schedule(this.CHANGE_TEXT);
+ },
+ initialValue: false
+ },
+ showPrintMargin: {
+ set: function() { this.$updatePrintMargin(); },
+ initialValue: true
+ },
+ printMarginColumn: {
+ set: function() { this.$updatePrintMargin(); },
+ initialValue: 80
+ },
+ printMargin: {
+ set: function(val) {
+ if (typeof val == "number")
+ this.$printMarginColumn = val;
+ this.$showPrintMargin = !!val;
+ this.$updatePrintMargin();
+ },
+ get: function() {
+ return this.$showPrintMargin && this.$printMarginColumn;
+ }
+ },
+ showGutter: {
+ set: function(show){
+ this.$gutter.style.display = show ? "block" : "none";
+ this.$loop.schedule(this.CHANGE_FULL);
+ this.onGutterResize();
+ },
+ initialValue: true
+ },
+ fadeFoldWidgets: {
+ set: function(show) {
+ dom.setCssClass(this.$gutter, "ace_fade-fold-widgets", show);
+ },
+ initialValue: false
+ },
+ showFoldWidgets: {
+ set: function(show) {this.$gutterLayer.setShowFoldWidgets(show)},
+ initialValue: true
+ },
+ showLineNumbers: {
+ set: function(show) {
+ this.$gutterLayer.setShowLineNumbers(show);
+ this.$loop.schedule(this.CHANGE_GUTTER);
+ },
+ initialValue: true
+ },
+ displayIndentGuides: {
+ set: function(show) {
+ if (this.$textLayer.setDisplayIndentGuides(show))
+ this.$loop.schedule(this.CHANGE_TEXT);
+ },
+ initialValue: true
+ },
+ highlightGutterLine: {
+ set: function(shouldHighlight) {
+ if (!this.$gutterLineHighlight) {
+ this.$gutterLineHighlight = dom.createElement("div");
+ this.$gutterLineHighlight.className = "ace_gutter-active-line";
+ this.$gutter.appendChild(this.$gutterLineHighlight);
+ return;
+ }
+
+ this.$gutterLineHighlight.style.display = shouldHighlight ? "" : "none";
+ if (this.$cursorLayer.$pixelPos)
+ this.$updateGutterLineHighlight();
+ },
+ initialValue: false,
+ value: true
+ },
+ hScrollBarAlwaysVisible: {
+ set: function(val) {
+ if (!this.$hScrollBarAlwaysVisible || !this.$horizScroll)
+ this.$loop.schedule(this.CHANGE_SCROLL);
+ },
+ initialValue: false
+ },
+ vScrollBarAlwaysVisible: {
+ set: function(val) {
+ if (!this.$vScrollBarAlwaysVisible || !this.$vScroll)
+ this.$loop.schedule(this.CHANGE_SCROLL);
+ },
+ initialValue: false
+ },
+ fontSize: {
+ set: function(size) {
+ if (typeof size == "number")
+ size = size + "px";
+ this.container.style.fontSize = size;
+ this.updateFontSize();
+ },
+ initialValue: 12
+ },
+ fontFamily: {
+ set: function(name) {
+ this.container.style.fontFamily = name;
+ this.updateFontSize();
+ }
+ },
+ maxLines: {
+ set: function(val) {
+ this.updateFull();
+ }
+ },
+ minLines: {
+ set: function(val) {
+ this.updateFull();
+ }
+ },
+ maxPixelHeight: {
+ set: function(val) {
+ this.updateFull();
+ },
+ initialValue: 0
+ },
+ scrollPastEnd: {
+ set: function(val) {
+ val = +val || 0;
+ if (this.$scrollPastEnd == val)
+ return;
+ this.$scrollPastEnd = val;
+ this.$loop.schedule(this.CHANGE_SCROLL);
+ },
+ initialValue: 0,
+ handlesSet: true
+ },
+ fixedWidthGutter: {
+ set: function(val) {
+ this.$gutterLayer.$fixedWidth = !!val;
+ this.$loop.schedule(this.CHANGE_GUTTER);
+ }
+ },
+ theme: {
+ set: function(val) { this.setTheme(val) },
+ get: function() { return this.$themeId || this.theme; },
+ initialValue: "./theme/textmate",
+ handlesSet: true
+ }
+});
+
+exports.VirtualRenderer = VirtualRenderer;
+});
+
+ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var net = require("../lib/net");
+var EventEmitter = require("../lib/event_emitter").EventEmitter;
+var config = require("../config");
+
+function $workerBlob(workerUrl) {
+ var script = "importScripts('" + net.qualifyURL(workerUrl) + "');";
+ try {
+ return new Blob([script], {"type": "application/javascript"});
+ } catch (e) { // Backwards-compatibility
+ var BlobBuilder = window.BlobBuilder || window.WebKitBlobBuilder || window.MozBlobBuilder;
+ var blobBuilder = new BlobBuilder();
+ blobBuilder.append(script);
+ return blobBuilder.getBlob("application/javascript");
+ }
+}
+
+function createWorker(workerUrl) {
+ var blob = $workerBlob(workerUrl);
+ var URL = window.URL || window.webkitURL;
+ var blobURL = URL.createObjectURL(blob);
+ return new Worker(blobURL);
+}
+
+var WorkerClient = function(topLevelNamespaces, mod, classname, workerUrl, importScripts) {
+ this.$sendDeltaQueue = this.$sendDeltaQueue.bind(this);
+ this.changeListener = this.changeListener.bind(this);
+ this.onMessage = this.onMessage.bind(this);
+ if (require.nameToUrl && !require.toUrl)
+ require.toUrl = require.nameToUrl;
+
+ if (config.get("packaged") || !require.toUrl) {
+ workerUrl = workerUrl || config.moduleUrl(mod, "worker");
+ } else {
+ var normalizePath = this.$normalizePath;
+ workerUrl = workerUrl || normalizePath(require.toUrl("ace/worker/worker.js", null, "_"));
+
+ var tlns = {};
+ topLevelNamespaces.forEach(function(ns) {
+ tlns[ns] = normalizePath(require.toUrl(ns, null, "_").replace(/(\.js)?(\?.*)?$/, ""));
+ });
+ }
+
+ this.$worker = createWorker(workerUrl);
+ if (importScripts) {
+ this.send("importScripts", importScripts);
+ }
+ this.$worker.postMessage({
+ init : true,
+ tlns : tlns,
+ module : mod,
+ classname : classname
+ });
+
+ this.callbackId = 1;
+ this.callbacks = {};
+
+ this.$worker.onmessage = this.onMessage;
+};
+
+(function(){
+
+ oop.implement(this, EventEmitter);
+
+ this.onMessage = function(e) {
+ var msg = e.data;
+ switch (msg.type) {
+ case "event":
+ this._signal(msg.name, {data: msg.data});
+ break;
+ case "call":
+ var callback = this.callbacks[msg.id];
+ if (callback) {
+ callback(msg.data);
+ delete this.callbacks[msg.id];
+ }
+ break;
+ case "error":
+ this.reportError(msg.data);
+ break;
+ case "log":
+ window.console && console.log && console.log.apply(console, msg.data);
+ break;
+ }
+ };
+
+ this.reportError = function(err) {
+ window.console && console.error && console.error(err);
+ };
+
+ this.$normalizePath = function(path) {
+ return net.qualifyURL(path);
+ };
+
+ this.terminate = function() {
+ this._signal("terminate", {});
+ this.deltaQueue = null;
+ this.$worker.terminate();
+ this.$worker = null;
+ if (this.$doc)
+ this.$doc.off("change", this.changeListener);
+ this.$doc = null;
+ };
+
+ this.send = function(cmd, args) {
+ this.$worker.postMessage({command: cmd, args: args});
+ };
+
+ this.call = function(cmd, args, callback) {
+ if (callback) {
+ var id = this.callbackId++;
+ this.callbacks[id] = callback;
+ args.push(id);
+ }
+ this.send(cmd, args);
+ };
+
+ this.emit = function(event, data) {
+ try {
+ this.$worker.postMessage({event: event, data: {data: data.data}});
+ }
+ catch(ex) {
+ console.error(ex.stack);
+ }
+ };
+
+ this.attachToDocument = function(doc) {
+ if (this.$doc)
+ this.terminate();
+
+ this.$doc = doc;
+ this.call("setValue", [doc.getValue()]);
+ doc.on("change", this.changeListener);
+ };
+
+ this.changeListener = function(delta) {
+ if (!this.deltaQueue) {
+ this.deltaQueue = [];
+ setTimeout(this.$sendDeltaQueue, 0);
+ }
+ if (delta.action == "insert")
+ this.deltaQueue.push(delta.start, delta.lines);
+ else
+ this.deltaQueue.push(delta.start, delta.end);
+ };
+
+ this.$sendDeltaQueue = function() {
+ var q = this.deltaQueue;
+ if (!q) return;
+ this.deltaQueue = null;
+ if (q.length > 50 && q.length > this.$doc.getLength() >> 1) {
+ this.call("setValue", [this.$doc.getValue()]);
+ } else
+ this.emit("change", {data: q});
+ };
+
+}).call(WorkerClient.prototype);
+
+
+var UIWorkerClient = function(topLevelNamespaces, mod, classname) {
+ this.$sendDeltaQueue = this.$sendDeltaQueue.bind(this);
+ this.changeListener = this.changeListener.bind(this);
+ this.callbackId = 1;
+ this.callbacks = {};
+ this.messageBuffer = [];
+
+ var main = null;
+ var emitSync = false;
+ var sender = Object.create(EventEmitter);
+ var _self = this;
+
+ this.$worker = {};
+ this.$worker.terminate = function() {};
+ this.$worker.postMessage = function(e) {
+ _self.messageBuffer.push(e);
+ if (main) {
+ if (emitSync)
+ setTimeout(processNext);
+ else
+ processNext();
+ }
+ };
+ this.setEmitSync = function(val) { emitSync = val };
+
+ var processNext = function() {
+ var msg = _self.messageBuffer.shift();
+ if (msg.command)
+ main[msg.command].apply(main, msg.args);
+ else if (msg.event)
+ sender._signal(msg.event, msg.data);
+ };
+
+ sender.postMessage = function(msg) {
+ _self.onMessage({data: msg});
+ };
+ sender.callback = function(data, callbackId) {
+ this.postMessage({type: "call", id: callbackId, data: data});
+ };
+ sender.emit = function(name, data) {
+ this.postMessage({type: "event", name: name, data: data});
+ };
+
+ config.loadModule(["worker", mod], function(Main) {
+ main = new Main[classname](sender);
+ while (_self.messageBuffer.length)
+ processNext();
+ });
+};
+
+UIWorkerClient.prototype = WorkerClient.prototype;
+
+exports.UIWorkerClient = UIWorkerClient;
+exports.WorkerClient = WorkerClient;
+exports.createWorker = createWorker;
+
+
+});
+
+ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"], function(require, exports, module) {
+"use strict";
+
+var Range = require("./range").Range;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var oop = require("./lib/oop");
+
+var PlaceHolder = function(session, length, pos, others, mainClass, othersClass) {
+ var _self = this;
+ this.length = length;
+ this.session = session;
+ this.doc = session.getDocument();
+ this.mainClass = mainClass;
+ this.othersClass = othersClass;
+ this.$onUpdate = this.onUpdate.bind(this);
+ this.doc.on("change", this.$onUpdate);
+ this.$others = others;
+
+ this.$onCursorChange = function() {
+ setTimeout(function() {
+ _self.onCursorChange();
+ });
+ };
+
+ this.$pos = pos;
+ var undoStack = session.getUndoManager().$undoStack || session.getUndoManager().$undostack || {length: -1};
+ this.$undoStackDepth = undoStack.length;
+ this.setup();
+
+ session.selection.on("changeCursor", this.$onCursorChange);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setup = function() {
+ var _self = this;
+ var doc = this.doc;
+ var session = this.session;
+
+ this.selectionBefore = session.selection.toJSON();
+ if (session.selection.inMultiSelectMode)
+ session.selection.toSingleRange();
+
+ this.pos = doc.createAnchor(this.$pos.row, this.$pos.column);
+ var pos = this.pos;
+ pos.$insertRight = true;
+ pos.detach();
+ pos.markerId = session.addMarker(new Range(pos.row, pos.column, pos.row, pos.column + this.length), this.mainClass, null, false);
+ this.others = [];
+ this.$others.forEach(function(other) {
+ var anchor = doc.createAnchor(other.row, other.column);
+ anchor.$insertRight = true;
+ anchor.detach();
+ _self.others.push(anchor);
+ });
+ session.setUndoSelect(false);
+ };
+ this.showOtherMarkers = function() {
+ if (this.othersActive) return;
+ var session = this.session;
+ var _self = this;
+ this.othersActive = true;
+ this.others.forEach(function(anchor) {
+ anchor.markerId = session.addMarker(new Range(anchor.row, anchor.column, anchor.row, anchor.column+_self.length), _self.othersClass, null, false);
+ });
+ };
+ this.hideOtherMarkers = function() {
+ if (!this.othersActive) return;
+ this.othersActive = false;
+ for (var i = 0; i < this.others.length; i++) {
+ this.session.removeMarker(this.others[i].markerId);
+ }
+ };
+ this.onUpdate = function(delta) {
+ if (this.$updating)
+ return this.updateAnchors(delta);
+
+ var range = delta;
+ if (range.start.row !== range.end.row) return;
+ if (range.start.row !== this.pos.row) return;
+ this.$updating = true;
+ var lengthDiff = delta.action === "insert" ? range.end.column - range.start.column : range.start.column - range.end.column;
+ var inMainRange = range.start.column >= this.pos.column && range.start.column <= this.pos.column + this.length + 1;
+ var distanceFromStart = range.start.column - this.pos.column;
+
+ this.updateAnchors(delta);
+
+ if (inMainRange)
+ this.length += lengthDiff;
+
+ if (inMainRange && !this.session.$fromUndo) {
+ if (delta.action === 'insert') {
+ for (var i = this.others.length - 1; i >= 0; i--) {
+ var otherPos = this.others[i];
+ var newPos = {row: otherPos.row, column: otherPos.column + distanceFromStart};
+ this.doc.insertMergedLines(newPos, delta.lines);
+ }
+ } else if (delta.action === 'remove') {
+ for (var i = this.others.length - 1; i >= 0; i--) {
+ var otherPos = this.others[i];
+ var newPos = {row: otherPos.row, column: otherPos.column + distanceFromStart};
+ this.doc.remove(new Range(newPos.row, newPos.column, newPos.row, newPos.column - lengthDiff));
+ }
+ }
+ }
+
+ this.$updating = false;
+ this.updateMarkers();
+ };
+
+ this.updateAnchors = function(delta) {
+ this.pos.onChange(delta);
+ for (var i = this.others.length; i--;)
+ this.others[i].onChange(delta);
+ this.updateMarkers();
+ };
+
+ this.updateMarkers = function() {
+ if (this.$updating)
+ return;
+ var _self = this;
+ var session = this.session;
+ var updateMarker = function(pos, className) {
+ session.removeMarker(pos.markerId);
+ pos.markerId = session.addMarker(new Range(pos.row, pos.column, pos.row, pos.column+_self.length), className, null, false);
+ };
+ updateMarker(this.pos, this.mainClass);
+ for (var i = this.others.length; i--;)
+ updateMarker(this.others[i], this.othersClass);
+ };
+
+ this.onCursorChange = function(event) {
+ if (this.$updating || !this.session) return;
+ var pos = this.session.selection.getCursor();
+ if (pos.row === this.pos.row && pos.column >= this.pos.column && pos.column <= this.pos.column + this.length) {
+ this.showOtherMarkers();
+ this._emit("cursorEnter", event);
+ } else {
+ this.hideOtherMarkers();
+ this._emit("cursorLeave", event);
+ }
+ };
+ this.detach = function() {
+ this.session.removeMarker(this.pos && this.pos.markerId);
+ this.hideOtherMarkers();
+ this.doc.removeEventListener("change", this.$onUpdate);
+ this.session.selection.removeEventListener("changeCursor", this.$onCursorChange);
+ this.session.setUndoSelect(true);
+ this.session = null;
+ };
+ this.cancel = function() {
+ if (this.$undoStackDepth === -1)
+ return;
+ var undoManager = this.session.getUndoManager();
+ var undosRequired = (undoManager.$undoStack || undoManager.$undostack).length - this.$undoStackDepth;
+ for (var i = 0; i < undosRequired; i++) {
+ undoManager.undo(true);
+ }
+ if (this.selectionBefore)
+ this.session.selection.fromJSON(this.selectionBefore);
+ };
+}).call(PlaceHolder.prototype);
+
+
+exports.PlaceHolder = PlaceHolder;
+});
+
+ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"], function(require, exports, module) {
+
+var event = require("../lib/event");
+var useragent = require("../lib/useragent");
+function isSamePoint(p1, p2) {
+ return p1.row == p2.row && p1.column == p2.column;
+}
+
+function onMouseDown(e) {
+ var ev = e.domEvent;
+ var alt = ev.altKey;
+ var shift = ev.shiftKey;
+ var ctrl = ev.ctrlKey;
+ var accel = e.getAccelKey();
+ var button = e.getButton();
+
+ if (ctrl && useragent.isMac)
+ button = ev.button;
+
+ if (e.editor.inMultiSelectMode && button == 2) {
+ e.editor.textInput.onContextMenu(e.domEvent);
+ return;
+ }
+
+ if (!ctrl && !alt && !accel) {
+ if (button === 0 && e.editor.inMultiSelectMode)
+ e.editor.exitMultiSelectMode();
+ return;
+ }
+
+ if (button !== 0)
+ return;
+
+ var editor = e.editor;
+ var selection = editor.selection;
+ var isMultiSelect = editor.inMultiSelectMode;
+ var pos = e.getDocumentPosition();
+ var cursor = selection.getCursor();
+ var inSelection = e.inSelection() || (selection.isEmpty() && isSamePoint(pos, cursor));
+
+ var mouseX = e.x, mouseY = e.y;
+ var onMouseSelection = function(e) {
+ mouseX = e.clientX;
+ mouseY = e.clientY;
+ };
+
+ var session = editor.session;
+ var screenAnchor = editor.renderer.pixelToScreenCoordinates(mouseX, mouseY);
+ var screenCursor = screenAnchor;
+
+ var selectionMode;
+ if (editor.$mouseHandler.$enableJumpToDef) {
+ if (ctrl && alt || accel && alt)
+ selectionMode = shift ? "block" : "add";
+ else if (alt && editor.$blockSelectEnabled)
+ selectionMode = "block";
+ } else {
+ if (accel && !alt) {
+ selectionMode = "add";
+ if (!isMultiSelect && shift)
+ return;
+ } else if (alt && editor.$blockSelectEnabled) {
+ selectionMode = "block";
+ }
+ }
+
+ if (selectionMode && useragent.isMac && ev.ctrlKey) {
+ editor.$mouseHandler.cancelContextMenu();
+ }
+
+ if (selectionMode == "add") {
+ if (!isMultiSelect && inSelection)
+ return; // dragging
+
+ if (!isMultiSelect) {
+ var range = selection.toOrientedRange();
+ editor.addSelectionMarker(range);
+ }
+
+ var oldRange = selection.rangeList.rangeAtPoint(pos);
+
+
+ editor.$blockScrolling++;
+ editor.inVirtualSelectionMode = true;
+
+ if (shift) {
+ oldRange = null;
+ range = selection.ranges[0] || range;
+ editor.removeSelectionMarker(range);
+ }
+ editor.once("mouseup", function() {
+ var tmpSel = selection.toOrientedRange();
+
+ if (oldRange && tmpSel.isEmpty() && isSamePoint(oldRange.cursor, tmpSel.cursor))
+ selection.substractPoint(tmpSel.cursor);
+ else {
+ if (shift) {
+ selection.substractPoint(range.cursor);
+ } else if (range) {
+ editor.removeSelectionMarker(range);
+ selection.addRange(range);
+ }
+ selection.addRange(tmpSel);
+ }
+ editor.$blockScrolling--;
+ editor.inVirtualSelectionMode = false;
+ });
+
+ } else if (selectionMode == "block") {
+ e.stop();
+ editor.inVirtualSelectionMode = true;
+ var initialRange;
+ var rectSel = [];
+ var blockSelect = function() {
+ var newCursor = editor.renderer.pixelToScreenCoordinates(mouseX, mouseY);
+ var cursor = session.screenToDocumentPosition(newCursor.row, newCursor.column, newCursor.offsetX);
+
+ if (isSamePoint(screenCursor, newCursor) && isSamePoint(cursor, selection.lead))
+ return;
+ screenCursor = newCursor;
+
+ editor.$blockScrolling++;
+ editor.selection.moveToPosition(cursor);
+ editor.renderer.scrollCursorIntoView();
+
+ editor.removeSelectionMarkers(rectSel);
+ rectSel = selection.rectangularRangeBlock(screenCursor, screenAnchor);
+ if (editor.$mouseHandler.$clickSelection && rectSel.length == 1 && rectSel[0].isEmpty())
+ rectSel[0] = editor.$mouseHandler.$clickSelection.clone();
+ rectSel.forEach(editor.addSelectionMarker, editor);
+ editor.updateSelectionMarkers();
+ editor.$blockScrolling--;
+ };
+ editor.$blockScrolling++;
+ if (isMultiSelect && !accel) {
+ selection.toSingleRange();
+ } else if (!isMultiSelect && accel) {
+ initialRange = selection.toOrientedRange();
+ editor.addSelectionMarker(initialRange);
+ }
+
+ if (shift)
+ screenAnchor = session.documentToScreenPosition(selection.lead);
+ else
+ selection.moveToPosition(pos);
+ editor.$blockScrolling--;
+
+ screenCursor = {row: -1, column: -1};
+
+ var onMouseSelectionEnd = function(e) {
+ clearInterval(timerId);
+ editor.removeSelectionMarkers(rectSel);
+ if (!rectSel.length)
+ rectSel = [selection.toOrientedRange()];
+ editor.$blockScrolling++;
+ if (initialRange) {
+ editor.removeSelectionMarker(initialRange);
+ selection.toSingleRange(initialRange);
+ }
+ for (var i = 0; i < rectSel.length; i++)
+ selection.addRange(rectSel[i]);
+ editor.inVirtualSelectionMode = false;
+ editor.$mouseHandler.$clickSelection = null;
+ editor.$blockScrolling--;
+ };
+
+ var onSelectionInterval = blockSelect;
+
+ event.capture(editor.container, onMouseSelection, onMouseSelectionEnd);
+ var timerId = setInterval(function() {onSelectionInterval();}, 20);
+
+ return e.preventDefault();
+ }
+}
+
+
+exports.onMouseDown = onMouseDown;
+
+});
+
+ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"], function(require, exports, module) {
+exports.defaultCommands = [{
+ name: "addCursorAbove",
+ exec: function(editor) { editor.selectMoreLines(-1); },
+ bindKey: {win: "Ctrl-Alt-Up", mac: "Ctrl-Alt-Up"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "addCursorBelow",
+ exec: function(editor) { editor.selectMoreLines(1); },
+ bindKey: {win: "Ctrl-Alt-Down", mac: "Ctrl-Alt-Down"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "addCursorAboveSkipCurrent",
+ exec: function(editor) { editor.selectMoreLines(-1, true); },
+ bindKey: {win: "Ctrl-Alt-Shift-Up", mac: "Ctrl-Alt-Shift-Up"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "addCursorBelowSkipCurrent",
+ exec: function(editor) { editor.selectMoreLines(1, true); },
+ bindKey: {win: "Ctrl-Alt-Shift-Down", mac: "Ctrl-Alt-Shift-Down"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectMoreBefore",
+ exec: function(editor) { editor.selectMore(-1); },
+ bindKey: {win: "Ctrl-Alt-Left", mac: "Ctrl-Alt-Left"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectMoreAfter",
+ exec: function(editor) { editor.selectMore(1); },
+ bindKey: {win: "Ctrl-Alt-Right", mac: "Ctrl-Alt-Right"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectNextBefore",
+ exec: function(editor) { editor.selectMore(-1, true); },
+ bindKey: {win: "Ctrl-Alt-Shift-Left", mac: "Ctrl-Alt-Shift-Left"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "selectNextAfter",
+ exec: function(editor) { editor.selectMore(1, true); },
+ bindKey: {win: "Ctrl-Alt-Shift-Right", mac: "Ctrl-Alt-Shift-Right"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}, {
+ name: "splitIntoLines",
+ exec: function(editor) { editor.multiSelect.splitIntoLines(); },
+ bindKey: {win: "Ctrl-Alt-L", mac: "Ctrl-Alt-L"},
+ readOnly: true
+}, {
+ name: "alignCursors",
+ exec: function(editor) { editor.alignCursors(); },
+ bindKey: {win: "Ctrl-Alt-A", mac: "Ctrl-Alt-A"},
+ scrollIntoView: "cursor"
+}, {
+ name: "findAll",
+ exec: function(editor) { editor.findAll(); },
+ bindKey: {win: "Ctrl-Alt-K", mac: "Ctrl-Alt-G"},
+ scrollIntoView: "cursor",
+ readOnly: true
+}];
+exports.multiSelectCommands = [{
+ name: "singleSelection",
+ bindKey: "esc",
+ exec: function(editor) { editor.exitMultiSelectMode(); },
+ scrollIntoView: "cursor",
+ readOnly: true,
+ isAvailable: function(editor) {return editor && editor.inMultiSelectMode}
+}];
+
+var HashHandler = require("../keyboard/hash_handler").HashHandler;
+exports.keyboardHandler = new HashHandler(exports.multiSelectCommands);
+
+});
+
+ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"], function(require, exports, module) {
+
+var RangeList = require("./range_list").RangeList;
+var Range = require("./range").Range;
+var Selection = require("./selection").Selection;
+var onMouseDown = require("./mouse/multi_select_handler").onMouseDown;
+var event = require("./lib/event");
+var lang = require("./lib/lang");
+var commands = require("./commands/multi_select_commands");
+exports.commands = commands.defaultCommands.concat(commands.multiSelectCommands);
+var Search = require("./search").Search;
+var search = new Search();
+
+function find(session, needle, dir) {
+ search.$options.wrap = true;
+ search.$options.needle = needle;
+ search.$options.backwards = dir == -1;
+ return search.find(session);
+}
+var EditSession = require("./edit_session").EditSession;
+(function() {
+ this.getSelectionMarkers = function() {
+ return this.$selectionMarkers;
+ };
+}).call(EditSession.prototype);
+(function() {
+ this.ranges = null;
+ this.rangeList = null;
+ this.addRange = function(range, $blockChangeEvents) {
+ if (!range)
+ return;
+
+ if (!this.inMultiSelectMode && this.rangeCount === 0) {
+ var oldRange = this.toOrientedRange();
+ this.rangeList.add(oldRange);
+ this.rangeList.add(range);
+ if (this.rangeList.ranges.length != 2) {
+ this.rangeList.removeAll();
+ return $blockChangeEvents || this.fromOrientedRange(range);
+ }
+ this.rangeList.removeAll();
+ this.rangeList.add(oldRange);
+ this.$onAddRange(oldRange);
+ }
+
+ if (!range.cursor)
+ range.cursor = range.end;
+
+ var removed = this.rangeList.add(range);
+
+ this.$onAddRange(range);
+
+ if (removed.length)
+ this.$onRemoveRange(removed);
+
+ if (this.rangeCount > 1 && !this.inMultiSelectMode) {
+ this._signal("multiSelect");
+ this.inMultiSelectMode = true;
+ this.session.$undoSelect = false;
+ this.rangeList.attach(this.session);
+ }
+
+ return $blockChangeEvents || this.fromOrientedRange(range);
+ };
+
+ this.toSingleRange = function(range) {
+ range = range || this.ranges[0];
+ var removed = this.rangeList.removeAll();
+ if (removed.length)
+ this.$onRemoveRange(removed);
+
+ range && this.fromOrientedRange(range);
+ };
+ this.substractPoint = function(pos) {
+ var removed = this.rangeList.substractPoint(pos);
+ if (removed) {
+ this.$onRemoveRange(removed);
+ return removed[0];
+ }
+ };
+ this.mergeOverlappingRanges = function() {
+ var removed = this.rangeList.merge();
+ if (removed.length)
+ this.$onRemoveRange(removed);
+ else if(this.ranges[0])
+ this.fromOrientedRange(this.ranges[0]);
+ };
+
+ this.$onAddRange = function(range) {
+ this.rangeCount = this.rangeList.ranges.length;
+ this.ranges.unshift(range);
+ this._signal("addRange", {range: range});
+ };
+
+ this.$onRemoveRange = function(removed) {
+ this.rangeCount = this.rangeList.ranges.length;
+ if (this.rangeCount == 1 && this.inMultiSelectMode) {
+ var lastRange = this.rangeList.ranges.pop();
+ removed.push(lastRange);
+ this.rangeCount = 0;
+ }
+
+ for (var i = removed.length; i--; ) {
+ var index = this.ranges.indexOf(removed[i]);
+ this.ranges.splice(index, 1);
+ }
+
+ this._signal("removeRange", {ranges: removed});
+
+ if (this.rangeCount === 0 && this.inMultiSelectMode) {
+ this.inMultiSelectMode = false;
+ this._signal("singleSelect");
+ this.session.$undoSelect = true;
+ this.rangeList.detach(this.session);
+ }
+
+ lastRange = lastRange || this.ranges[0];
+ if (lastRange && !lastRange.isEqual(this.getRange()))
+ this.fromOrientedRange(lastRange);
+ };
+ this.$initRangeList = function() {
+ if (this.rangeList)
+ return;
+
+ this.rangeList = new RangeList();
+ this.ranges = [];
+ this.rangeCount = 0;
+ };
+ this.getAllRanges = function() {
+ return this.rangeCount ? this.rangeList.ranges.concat() : [this.getRange()];
+ };
+
+ this.splitIntoLines = function () {
+ if (this.rangeCount > 1) {
+ var ranges = this.rangeList.ranges;
+ var lastRange = ranges[ranges.length - 1];
+ var range = Range.fromPoints(ranges[0].start, lastRange.end);
+
+ this.toSingleRange();
+ this.setSelectionRange(range, lastRange.cursor == lastRange.start);
+ } else {
+ var range = this.getRange();
+ var isBackwards = this.isBackwards();
+ var startRow = range.start.row;
+ var endRow = range.end.row;
+ if (startRow == endRow) {
+ if (isBackwards)
+ var start = range.end, end = range.start;
+ else
+ var start = range.start, end = range.end;
+
+ this.addRange(Range.fromPoints(end, end));
+ this.addRange(Range.fromPoints(start, start));
+ return;
+ }
+
+ var rectSel = [];
+ var r = this.getLineRange(startRow, true);
+ r.start.column = range.start.column;
+ rectSel.push(r);
+
+ for (var i = startRow + 1; i < endRow; i++)
+ rectSel.push(this.getLineRange(i, true));
+
+ r = this.getLineRange(endRow, true);
+ r.end.column = range.end.column;
+ rectSel.push(r);
+
+ rectSel.forEach(this.addRange, this);
+ }
+ };
+ this.toggleBlockSelection = function () {
+ if (this.rangeCount > 1) {
+ var ranges = this.rangeList.ranges;
+ var lastRange = ranges[ranges.length - 1];
+ var range = Range.fromPoints(ranges[0].start, lastRange.end);
+
+ this.toSingleRange();
+ this.setSelectionRange(range, lastRange.cursor == lastRange.start);
+ } else {
+ var cursor = this.session.documentToScreenPosition(this.selectionLead);
+ var anchor = this.session.documentToScreenPosition(this.selectionAnchor);
+
+ var rectSel = this.rectangularRangeBlock(cursor, anchor);
+ rectSel.forEach(this.addRange, this);
+ }
+ };
+ this.rectangularRangeBlock = function(screenCursor, screenAnchor, includeEmptyLines) {
+ var rectSel = [];
+
+ var xBackwards = screenCursor.column < screenAnchor.column;
+ if (xBackwards) {
+ var startColumn = screenCursor.column;
+ var endColumn = screenAnchor.column;
+ var startOffsetX = screenCursor.offsetX;
+ var endOffsetX = screenAnchor.offsetX;
+ } else {
+ var startColumn = screenAnchor.column;
+ var endColumn = screenCursor.column;
+ var startOffsetX = screenAnchor.offsetX;
+ var endOffsetX = screenCursor.offsetX;
+ }
+
+ var yBackwards = screenCursor.row < screenAnchor.row;
+ if (yBackwards) {
+ var startRow = screenCursor.row;
+ var endRow = screenAnchor.row;
+ } else {
+ var startRow = screenAnchor.row;
+ var endRow = screenCursor.row;
+ }
+
+ if (startColumn < 0)
+ startColumn = 0;
+ if (startRow < 0)
+ startRow = 0;
+
+ if (startRow == endRow)
+ includeEmptyLines = true;
+
+ for (var row = startRow; row <= endRow; row++) {
+ var range = Range.fromPoints(
+ this.session.screenToDocumentPosition(row, startColumn, startOffsetX),
+ this.session.screenToDocumentPosition(row, endColumn, endOffsetX)
+ );
+ if (range.isEmpty()) {
+ if (docEnd && isSamePoint(range.end, docEnd))
+ break;
+ var docEnd = range.end;
+ }
+ range.cursor = xBackwards ? range.start : range.end;
+ rectSel.push(range);
+ }
+
+ if (yBackwards)
+ rectSel.reverse();
+
+ if (!includeEmptyLines) {
+ var end = rectSel.length - 1;
+ while (rectSel[end].isEmpty() && end > 0)
+ end--;
+ if (end > 0) {
+ var start = 0;
+ while (rectSel[start].isEmpty())
+ start++;
+ }
+ for (var i = end; i >= start; i--) {
+ if (rectSel[i].isEmpty())
+ rectSel.splice(i, 1);
+ }
+ }
+
+ return rectSel;
+ };
+}).call(Selection.prototype);
+var Editor = require("./editor").Editor;
+(function() {
+ this.updateSelectionMarkers = function() {
+ this.renderer.updateCursor();
+ this.renderer.updateBackMarkers();
+ };
+ this.addSelectionMarker = function(orientedRange) {
+ if (!orientedRange.cursor)
+ orientedRange.cursor = orientedRange.end;
+
+ var style = this.getSelectionStyle();
+ orientedRange.marker = this.session.addMarker(orientedRange, "ace_selection", style);
+
+ this.session.$selectionMarkers.push(orientedRange);
+ this.session.selectionMarkerCount = this.session.$selectionMarkers.length;
+ return orientedRange;
+ };
+ this.removeSelectionMarker = function(range) {
+ if (!range.marker)
+ return;
+ this.session.removeMarker(range.marker);
+ var index = this.session.$selectionMarkers.indexOf(range);
+ if (index != -1)
+ this.session.$selectionMarkers.splice(index, 1);
+ this.session.selectionMarkerCount = this.session.$selectionMarkers.length;
+ };
+
+ this.removeSelectionMarkers = function(ranges) {
+ var markerList = this.session.$selectionMarkers;
+ for (var i = ranges.length; i--; ) {
+ var range = ranges[i];
+ if (!range.marker)
+ continue;
+ this.session.removeMarker(range.marker);
+ var index = markerList.indexOf(range);
+ if (index != -1)
+ markerList.splice(index, 1);
+ }
+ this.session.selectionMarkerCount = markerList.length;
+ };
+
+ this.$onAddRange = function(e) {
+ this.addSelectionMarker(e.range);
+ this.renderer.updateCursor();
+ this.renderer.updateBackMarkers();
+ };
+
+ this.$onRemoveRange = function(e) {
+ this.removeSelectionMarkers(e.ranges);
+ this.renderer.updateCursor();
+ this.renderer.updateBackMarkers();
+ };
+
+ this.$onMultiSelect = function(e) {
+ if (this.inMultiSelectMode)
+ return;
+ this.inMultiSelectMode = true;
+
+ this.setStyle("ace_multiselect");
+ this.keyBinding.addKeyboardHandler(commands.keyboardHandler);
+ this.commands.setDefaultHandler("exec", this.$onMultiSelectExec);
+
+ this.renderer.updateCursor();
+ this.renderer.updateBackMarkers();
+ };
+
+ this.$onSingleSelect = function(e) {
+ if (this.session.multiSelect.inVirtualMode)
+ return;
+ this.inMultiSelectMode = false;
+
+ this.unsetStyle("ace_multiselect");
+ this.keyBinding.removeKeyboardHandler(commands.keyboardHandler);
+
+ this.commands.removeDefaultHandler("exec", this.$onMultiSelectExec);
+ this.renderer.updateCursor();
+ this.renderer.updateBackMarkers();
+ this._emit("changeSelection");
+ };
+
+ this.$onMultiSelectExec = function(e) {
+ var command = e.command;
+ var editor = e.editor;
+ if (!editor.multiSelect)
+ return;
+ if (!command.multiSelectAction) {
+ var result = command.exec(editor, e.args || {});
+ editor.multiSelect.addRange(editor.multiSelect.toOrientedRange());
+ editor.multiSelect.mergeOverlappingRanges();
+ } else if (command.multiSelectAction == "forEach") {
+ result = editor.forEachSelection(command, e.args);
+ } else if (command.multiSelectAction == "forEachLine") {
+ result = editor.forEachSelection(command, e.args, true);
+ } else if (command.multiSelectAction == "single") {
+ editor.exitMultiSelectMode();
+ result = command.exec(editor, e.args || {});
+ } else {
+ result = command.multiSelectAction(editor, e.args || {});
+ }
+ return result;
+ };
+ this.forEachSelection = function(cmd, args, options) {
+ if (this.inVirtualSelectionMode)
+ return;
+ var keepOrder = options && options.keepOrder;
+ var $byLines = options == true || options && options.$byLines
+ var session = this.session;
+ var selection = this.selection;
+ var rangeList = selection.rangeList;
+ var ranges = (keepOrder ? selection : rangeList).ranges;
+ var result;
+
+ if (!ranges.length)
+ return cmd.exec ? cmd.exec(this, args || {}) : cmd(this, args || {});
+
+ var reg = selection._eventRegistry;
+ selection._eventRegistry = {};
+
+ var tmpSel = new Selection(session);
+ this.inVirtualSelectionMode = true;
+ for (var i = ranges.length; i--;) {
+ if ($byLines) {
+ while (i > 0 && ranges[i].start.row == ranges[i - 1].end.row)
+ i--;
+ }
+ tmpSel.fromOrientedRange(ranges[i]);
+ tmpSel.index = i;
+ this.selection = session.selection = tmpSel;
+ var cmdResult = cmd.exec ? cmd.exec(this, args || {}) : cmd(this, args || {});
+ if (!result && cmdResult !== undefined)
+ result = cmdResult;
+ tmpSel.toOrientedRange(ranges[i]);
+ }
+ tmpSel.detach();
+
+ this.selection = session.selection = selection;
+ this.inVirtualSelectionMode = false;
+ selection._eventRegistry = reg;
+ selection.mergeOverlappingRanges();
+
+ var anim = this.renderer.$scrollAnimation;
+ this.onCursorChange();
+ this.onSelectionChange();
+ if (anim && anim.from == anim.to)
+ this.renderer.animateScrolling(anim.from);
+
+ return result;
+ };
+ this.exitMultiSelectMode = function() {
+ if (!this.inMultiSelectMode || this.inVirtualSelectionMode)
+ return;
+ this.multiSelect.toSingleRange();
+ };
+
+ this.getSelectedText = function() {
+ var text = "";
+ if (this.inMultiSelectMode && !this.inVirtualSelectionMode) {
+ var ranges = this.multiSelect.rangeList.ranges;
+ var buf = [];
+ for (var i = 0; i < ranges.length; i++) {
+ buf.push(this.session.getTextRange(ranges[i]));
+ }
+ var nl = this.session.getDocument().getNewLineCharacter();
+ text = buf.join(nl);
+ if (text.length == (buf.length - 1) * nl.length)
+ text = "";
+ } else if (!this.selection.isEmpty()) {
+ text = this.session.getTextRange(this.getSelectionRange());
+ }
+ return text;
+ };
+
+ this.$checkMultiselectChange = function(e, anchor) {
+ if (this.inMultiSelectMode && !this.inVirtualSelectionMode) {
+ var range = this.multiSelect.ranges[0];
+ if (this.multiSelect.isEmpty() && anchor == this.multiSelect.anchor)
+ return;
+ var pos = anchor == this.multiSelect.anchor
+ ? range.cursor == range.start ? range.end : range.start
+ : range.cursor;
+ if (pos.row != anchor.row
+ || this.session.$clipPositionToDocument(pos.row, pos.column).column != anchor.column)
+ this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange());
+ }
+ };
+ this.findAll = function(needle, options, additive) {
+ options = options || {};
+ options.needle = needle || options.needle;
+ if (options.needle == undefined) {
+ var range = this.selection.isEmpty()
+ ? this.selection.getWordRange()
+ : this.selection.getRange();
+ options.needle = this.session.getTextRange(range);
+ }
+ this.$search.set(options);
+
+ var ranges = this.$search.findAll(this.session);
+ if (!ranges.length)
+ return 0;
+
+ this.$blockScrolling += 1;
+ var selection = this.multiSelect;
+
+ if (!additive)
+ selection.toSingleRange(ranges[0]);
+
+ for (var i = ranges.length; i--; )
+ selection.addRange(ranges[i], true);
+ if (range && selection.rangeList.rangeAtPoint(range.start))
+ selection.addRange(range, true);
+
+ this.$blockScrolling -= 1;
+
+ return ranges.length;
+ };
+ this.selectMoreLines = function(dir, skip) {
+ var range = this.selection.toOrientedRange();
+ var isBackwards = range.cursor == range.end;
+
+ var screenLead = this.session.documentToScreenPosition(range.cursor);
+ if (this.selection.$desiredColumn)
+ screenLead.column = this.selection.$desiredColumn;
+
+ var lead = this.session.screenToDocumentPosition(screenLead.row + dir, screenLead.column);
+
+ if (!range.isEmpty()) {
+ var screenAnchor = this.session.documentToScreenPosition(isBackwards ? range.end : range.start);
+ var anchor = this.session.screenToDocumentPosition(screenAnchor.row + dir, screenAnchor.column);
+ } else {
+ var anchor = lead;
+ }
+
+ if (isBackwards) {
+ var newRange = Range.fromPoints(lead, anchor);
+ newRange.cursor = newRange.start;
+ } else {
+ var newRange = Range.fromPoints(anchor, lead);
+ newRange.cursor = newRange.end;
+ }
+
+ newRange.desiredColumn = screenLead.column;
+ if (!this.selection.inMultiSelectMode) {
+ this.selection.addRange(range);
+ } else {
+ if (skip)
+ var toRemove = range.cursor;
+ }
+
+ this.selection.addRange(newRange);
+ if (toRemove)
+ this.selection.substractPoint(toRemove);
+ };
+ this.transposeSelections = function(dir) {
+ var session = this.session;
+ var sel = session.multiSelect;
+ var all = sel.ranges;
+
+ for (var i = all.length; i--; ) {
+ var range = all[i];
+ if (range.isEmpty()) {
+ var tmp = session.getWordRange(range.start.row, range.start.column);
+ range.start.row = tmp.start.row;
+ range.start.column = tmp.start.column;
+ range.end.row = tmp.end.row;
+ range.end.column = tmp.end.column;
+ }
+ }
+ sel.mergeOverlappingRanges();
+
+ var words = [];
+ for (var i = all.length; i--; ) {
+ var range = all[i];
+ words.unshift(session.getTextRange(range));
+ }
+
+ if (dir < 0)
+ words.unshift(words.pop());
+ else
+ words.push(words.shift());
+
+ for (var i = all.length; i--; ) {
+ var range = all[i];
+ var tmp = range.clone();
+ session.replace(range, words[i]);
+ range.start.row = tmp.start.row;
+ range.start.column = tmp.start.column;
+ }
+ };
+ this.selectMore = function(dir, skip, stopAtFirst) {
+ var session = this.session;
+ var sel = session.multiSelect;
+
+ var range = sel.toOrientedRange();
+ if (range.isEmpty()) {
+ range = session.getWordRange(range.start.row, range.start.column);
+ range.cursor = dir == -1 ? range.start : range.end;
+ this.multiSelect.addRange(range);
+ if (stopAtFirst)
+ return;
+ }
+ var needle = session.getTextRange(range);
+
+ var newRange = find(session, needle, dir);
+ if (newRange) {
+ newRange.cursor = dir == -1 ? newRange.start : newRange.end;
+ this.$blockScrolling += 1;
+ this.session.unfold(newRange);
+ this.multiSelect.addRange(newRange);
+ this.$blockScrolling -= 1;
+ this.renderer.scrollCursorIntoView(null, 0.5);
+ }
+ if (skip)
+ this.multiSelect.substractPoint(range.cursor);
+ };
+ this.alignCursors = function() {
+ var session = this.session;
+ var sel = session.multiSelect;
+ var ranges = sel.ranges;
+ var row = -1;
+ var sameRowRanges = ranges.filter(function(r) {
+ if (r.cursor.row == row)
+ return true;
+ row = r.cursor.row;
+ });
+
+ if (!ranges.length || sameRowRanges.length == ranges.length - 1) {
+ var range = this.selection.getRange();
+ var fr = range.start.row, lr = range.end.row;
+ var guessRange = fr == lr;
+ if (guessRange) {
+ var max = this.session.getLength();
+ var line;
+ do {
+ line = this.session.getLine(lr);
+ } while (/[=:]/.test(line) && ++lr < max);
+ do {
+ line = this.session.getLine(fr);
+ } while (/[=:]/.test(line) && --fr > 0);
+
+ if (fr < 0) fr = 0;
+ if (lr >= max) lr = max - 1;
+ }
+ var lines = this.session.removeFullLines(fr, lr);
+ lines = this.$reAlignText(lines, guessRange);
+ this.session.insert({row: fr, column: 0}, lines.join("\n") + "\n");
+ if (!guessRange) {
+ range.start.column = 0;
+ range.end.column = lines[lines.length - 1].length;
+ }
+ this.selection.setRange(range);
+ } else {
+ sameRowRanges.forEach(function(r) {
+ sel.substractPoint(r.cursor);
+ });
+
+ var maxCol = 0;
+ var minSpace = Infinity;
+ var spaceOffsets = ranges.map(function(r) {
+ var p = r.cursor;
+ var line = session.getLine(p.row);
+ var spaceOffset = line.substr(p.column).search(/\S/g);
+ if (spaceOffset == -1)
+ spaceOffset = 0;
+
+ if (p.column > maxCol)
+ maxCol = p.column;
+ if (spaceOffset < minSpace)
+ minSpace = spaceOffset;
+ return spaceOffset;
+ });
+ ranges.forEach(function(r, i) {
+ var p = r.cursor;
+ var l = maxCol - p.column;
+ var d = spaceOffsets[i] - minSpace;
+ if (l > d)
+ session.insert(p, lang.stringRepeat(" ", l - d));
+ else
+ session.remove(new Range(p.row, p.column, p.row, p.column - l + d));
+
+ r.start.column = r.end.column = maxCol;
+ r.start.row = r.end.row = p.row;
+ r.cursor = r.end;
+ });
+ sel.fromOrientedRange(ranges[0]);
+ this.renderer.updateCursor();
+ this.renderer.updateBackMarkers();
+ }
+ };
+
+ this.$reAlignText = function(lines, forceLeft) {
+ var isLeftAligned = true, isRightAligned = true;
+ var startW, textW, endW;
+
+ return lines.map(function(line) {
+ var m = line.match(/(\s*)(.*?)(\s*)([=:].*)/);
+ if (!m)
+ return [line];
+
+ if (startW == null) {
+ startW = m[1].length;
+ textW = m[2].length;
+ endW = m[3].length;
+ return m;
+ }
+
+ if (startW + textW + endW != m[1].length + m[2].length + m[3].length)
+ isRightAligned = false;
+ if (startW != m[1].length)
+ isLeftAligned = false;
+
+ if (startW > m[1].length)
+ startW = m[1].length;
+ if (textW < m[2].length)
+ textW = m[2].length;
+ if (endW > m[3].length)
+ endW = m[3].length;
+
+ return m;
+ }).map(forceLeft ? alignLeft :
+ isLeftAligned ? isRightAligned ? alignRight : alignLeft : unAlign);
+
+ function spaces(n) {
+ return lang.stringRepeat(" ", n);
+ }
+
+ function alignLeft(m) {
+ return !m[2] ? m[0] : spaces(startW) + m[2]
+ + spaces(textW - m[2].length + endW)
+ + m[4].replace(/^([=:])\s+/, "$1 ");
+ }
+ function alignRight(m) {
+ return !m[2] ? m[0] : spaces(startW + textW - m[2].length) + m[2]
+ + spaces(endW, " ")
+ + m[4].replace(/^([=:])\s+/, "$1 ");
+ }
+ function unAlign(m) {
+ return !m[2] ? m[0] : spaces(startW) + m[2]
+ + spaces(endW)
+ + m[4].replace(/^([=:])\s+/, "$1 ");
+ }
+ };
+}).call(Editor.prototype);
+
+
+function isSamePoint(p1, p2) {
+ return p1.row == p2.row && p1.column == p2.column;
+}
+exports.onSessionChange = function(e) {
+ var session = e.session;
+ if (session && !session.multiSelect) {
+ session.$selectionMarkers = [];
+ session.selection.$initRangeList();
+ session.multiSelect = session.selection;
+ }
+ this.multiSelect = session && session.multiSelect;
+
+ var oldSession = e.oldSession;
+ if (oldSession) {
+ oldSession.multiSelect.off("addRange", this.$onAddRange);
+ oldSession.multiSelect.off("removeRange", this.$onRemoveRange);
+ oldSession.multiSelect.off("multiSelect", this.$onMultiSelect);
+ oldSession.multiSelect.off("singleSelect", this.$onSingleSelect);
+ oldSession.multiSelect.lead.off("change", this.$checkMultiselectChange);
+ oldSession.multiSelect.anchor.off("change", this.$checkMultiselectChange);
+ }
+
+ if (session) {
+ session.multiSelect.on("addRange", this.$onAddRange);
+ session.multiSelect.on("removeRange", this.$onRemoveRange);
+ session.multiSelect.on("multiSelect", this.$onMultiSelect);
+ session.multiSelect.on("singleSelect", this.$onSingleSelect);
+ session.multiSelect.lead.on("change", this.$checkMultiselectChange);
+ session.multiSelect.anchor.on("change", this.$checkMultiselectChange);
+ }
+
+ if (session && this.inMultiSelectMode != session.selection.inMultiSelectMode) {
+ if (session.selection.inMultiSelectMode)
+ this.$onMultiSelect();
+ else
+ this.$onSingleSelect();
+ }
+};
+function MultiSelect(editor) {
+ if (editor.$multiselectOnSessionChange)
+ return;
+ editor.$onAddRange = editor.$onAddRange.bind(editor);
+ editor.$onRemoveRange = editor.$onRemoveRange.bind(editor);
+ editor.$onMultiSelect = editor.$onMultiSelect.bind(editor);
+ editor.$onSingleSelect = editor.$onSingleSelect.bind(editor);
+ editor.$multiselectOnSessionChange = exports.onSessionChange.bind(editor);
+ editor.$checkMultiselectChange = editor.$checkMultiselectChange.bind(editor);
+
+ editor.$multiselectOnSessionChange(editor);
+ editor.on("changeSession", editor.$multiselectOnSessionChange);
+
+ editor.on("mousedown", onMouseDown);
+ editor.commands.addCommands(commands.defaultCommands);
+
+ addAltCursorListeners(editor);
+}
+
+function addAltCursorListeners(editor){
+ var el = editor.textInput.getElement();
+ var altCursor = false;
+ event.addListener(el, "keydown", function(e) {
+ var altDown = e.keyCode == 18 && !(e.ctrlKey || e.shiftKey || e.metaKey);
+ if (editor.$blockSelectEnabled && altDown) {
+ if (!altCursor) {
+ editor.renderer.setMouseCursor("crosshair");
+ altCursor = true;
+ }
+ } else if (altCursor) {
+ reset();
+ }
+ });
+
+ event.addListener(el, "keyup", reset);
+ event.addListener(el, "blur", reset);
+ function reset(e) {
+ if (altCursor) {
+ editor.renderer.setMouseCursor("");
+ altCursor = false;
+ }
+ }
+}
+
+exports.MultiSelect = MultiSelect;
+
+
+require("./config").defineOptions(Editor.prototype, "editor", {
+ enableMultiselect: {
+ set: function(val) {
+ MultiSelect(this);
+ if (val) {
+ this.on("changeSession", this.$multiselectOnSessionChange);
+ this.on("mousedown", onMouseDown);
+ } else {
+ this.off("changeSession", this.$multiselectOnSessionChange);
+ this.off("mousedown", onMouseDown);
+ }
+ },
+ value: true
+ },
+ enableBlockSelect: {
+ set: function(val) {
+ this.$blockSelectEnabled = val;
+ },
+ value: true
+ }
+});
+
+
+
+});
+
+ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+
+(function() {
+
+ this.foldingStartMarker = null;
+ this.foldingStopMarker = null;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ if (this.foldingStartMarker.test(line))
+ return "start";
+ if (foldStyle == "markbeginend"
+ && this.foldingStopMarker
+ && this.foldingStopMarker.test(line))
+ return "end";
+ return "";
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ return null;
+ };
+
+ this.indentationBlock = function(session, row, column) {
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1)
+ return;
+
+ var startColumn = column || line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ var level = session.getLine(row).search(re);
+
+ if (level == -1)
+ continue;
+
+ if (level <= startLevel)
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+
+ this.openingBracketBlock = function(session, bracket, row, column, typeRe) {
+ var start = {row: row, column: column + 1};
+ var end = session.$findClosingBracket(bracket, start, typeRe);
+ if (!end)
+ return;
+
+ var fw = session.foldWidgets[end.row];
+ if (fw == null)
+ fw = session.getFoldWidget(end.row);
+
+ if (fw == "start" && end.row > start.row) {
+ end.row --;
+ end.column = session.getLine(end.row).length;
+ }
+ return Range.fromPoints(start, end);
+ };
+
+ this.closingBracketBlock = function(session, bracket, row, column, typeRe) {
+ var end = {row: row, column: column};
+ var start = session.$findOpeningBracket(bracket, end);
+
+ if (!start)
+ return;
+
+ start.column++;
+ end.column--;
+
+ return Range.fromPoints(start, end);
+ };
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+exports.isDark = false;
+exports.cssClass = "ace-tm";
+exports.cssText = ".ace-tm .ace_gutter {\
+background: #f0f0f0;\
+color: #333;\
+}\
+.ace-tm .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-tm .ace_fold {\
+background-color: #6B72E6;\
+}\
+.ace-tm {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-tm .ace_cursor {\
+color: black;\
+}\
+.ace-tm .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-tm .ace_storage,\
+.ace-tm .ace_keyword {\
+color: blue;\
+}\
+.ace-tm .ace_constant {\
+color: rgb(197, 6, 11);\
+}\
+.ace-tm .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-tm .ace_constant.ace_language {\
+color: rgb(88, 92, 246);\
+}\
+.ace-tm .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-tm .ace_invalid {\
+background-color: rgba(255, 0, 0, 0.1);\
+color: red;\
+}\
+.ace-tm .ace_support.ace_function {\
+color: rgb(60, 76, 114);\
+}\
+.ace-tm .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-tm .ace_support.ace_type,\
+.ace-tm .ace_support.ace_class {\
+color: rgb(109, 121, 222);\
+}\
+.ace-tm .ace_keyword.ace_operator {\
+color: rgb(104, 118, 135);\
+}\
+.ace-tm .ace_string {\
+color: rgb(3, 106, 7);\
+}\
+.ace-tm .ace_comment {\
+color: rgb(76, 136, 107);\
+}\
+.ace-tm .ace_comment.ace_doc {\
+color: rgb(0, 102, 255);\
+}\
+.ace-tm .ace_comment.ace_doc.ace_tag {\
+color: rgb(128, 159, 191);\
+}\
+.ace-tm .ace_constant.ace_numeric {\
+color: rgb(0, 0, 205);\
+}\
+.ace-tm .ace_variable {\
+color: rgb(49, 132, 149);\
+}\
+.ace-tm .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-tm .ace_entity.ace_name.ace_function {\
+color: #0000A2;\
+}\
+.ace-tm .ace_heading {\
+color: rgb(12, 7, 255);\
+}\
+.ace-tm .ace_list {\
+color:rgb(185, 6, 144);\
+}\
+.ace-tm .ace_meta.ace_tag {\
+color:rgb(0, 22, 142);\
+}\
+.ace-tm .ace_string.ace_regex {\
+color: rgb(255, 0, 0)\
+}\
+.ace-tm .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-tm.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px white;\
+}\
+.ace-tm .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-tm .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-tm .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-tm .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.07);\
+}\
+.ace-tm .ace_gutter-active-line {\
+background-color : #dcdcdc;\
+}\
+.ace-tm .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-tm .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
+
+ace.define("ace/line_widgets",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var dom = require("./lib/dom");
+var Range = require("./range").Range;
+
+
+function LineWidgets(session) {
+ this.session = session;
+ this.session.widgetManager = this;
+ this.session.getRowLength = this.getRowLength;
+ this.session.$getWidgetScreenLength = this.$getWidgetScreenLength;
+ this.updateOnChange = this.updateOnChange.bind(this);
+ this.renderWidgets = this.renderWidgets.bind(this);
+ this.measureWidgets = this.measureWidgets.bind(this);
+ this.session._changedWidgets = [];
+ this.$onChangeEditor = this.$onChangeEditor.bind(this);
+
+ this.session.on("change", this.updateOnChange);
+ this.session.on("changeFold", this.updateOnFold);
+ this.session.on("changeEditor", this.$onChangeEditor);
+}
+
+(function() {
+ this.getRowLength = function(row) {
+ var h;
+ if (this.lineWidgets)
+ h = this.lineWidgets[row] && this.lineWidgets[row].rowCount || 0;
+ else
+ h = 0;
+ if (!this.$useWrapMode || !this.$wrapData[row]) {
+ return 1 + h;
+ } else {
+ return this.$wrapData[row].length + 1 + h;
+ }
+ };
+
+ this.$getWidgetScreenLength = function() {
+ var screenRows = 0;
+ this.lineWidgets.forEach(function(w){
+ if (w && w.rowCount && !w.hidden)
+ screenRows += w.rowCount;
+ });
+ return screenRows;
+ };
+
+ this.$onChangeEditor = function(e) {
+ this.attach(e.editor);
+ };
+
+ this.attach = function(editor) {
+ if (editor && editor.widgetManager && editor.widgetManager != this)
+ editor.widgetManager.detach();
+
+ if (this.editor == editor)
+ return;
+
+ this.detach();
+ this.editor = editor;
+
+ if (editor) {
+ editor.widgetManager = this;
+ editor.renderer.on("beforeRender", this.measureWidgets);
+ editor.renderer.on("afterRender", this.renderWidgets);
+ }
+ };
+ this.detach = function(e) {
+ var editor = this.editor;
+ if (!editor)
+ return;
+
+ this.editor = null;
+ editor.widgetManager = null;
+
+ editor.renderer.off("beforeRender", this.measureWidgets);
+ editor.renderer.off("afterRender", this.renderWidgets);
+ var lineWidgets = this.session.lineWidgets;
+ lineWidgets && lineWidgets.forEach(function(w) {
+ if (w && w.el && w.el.parentNode) {
+ w._inDocument = false;
+ w.el.parentNode.removeChild(w.el);
+ }
+ });
+ };
+
+ this.updateOnFold = function(e, session) {
+ var lineWidgets = session.lineWidgets;
+ if (!lineWidgets || !e.action)
+ return;
+ var fold = e.data;
+ var start = fold.start.row;
+ var end = fold.end.row;
+ var hide = e.action == "add";
+ for (var i = start + 1; i < end; i++) {
+ if (lineWidgets[i])
+ lineWidgets[i].hidden = hide;
+ }
+ if (lineWidgets[end]) {
+ if (hide) {
+ if (!lineWidgets[start])
+ lineWidgets[start] = lineWidgets[end];
+ else
+ lineWidgets[end].hidden = hide;
+ } else {
+ if (lineWidgets[start] == lineWidgets[end])
+ lineWidgets[start] = undefined;
+ lineWidgets[end].hidden = hide;
+ }
+ }
+ };
+
+ this.updateOnChange = function(delta) {
+ var lineWidgets = this.session.lineWidgets;
+ if (!lineWidgets) return;
+
+ var startRow = delta.start.row;
+ var len = delta.end.row - startRow;
+
+ if (len === 0) {
+ } else if (delta.action == 'remove') {
+ var removed = lineWidgets.splice(startRow + 1, len);
+ removed.forEach(function(w) {
+ w && this.removeLineWidget(w);
+ }, this);
+ this.$updateRows();
+ } else {
+ var args = new Array(len);
+ args.unshift(startRow, 0);
+ lineWidgets.splice.apply(lineWidgets, args);
+ this.$updateRows();
+ }
+ };
+
+ this.$updateRows = function() {
+ var lineWidgets = this.session.lineWidgets;
+ if (!lineWidgets) return;
+ var noWidgets = true;
+ lineWidgets.forEach(function(w, i) {
+ if (w) {
+ noWidgets = false;
+ w.row = i;
+ while (w.$oldWidget) {
+ w.$oldWidget.row = i;
+ w = w.$oldWidget;
+ }
+ }
+ });
+ if (noWidgets)
+ this.session.lineWidgets = null;
+ };
+
+ this.addLineWidget = function(w) {
+ if (!this.session.lineWidgets)
+ this.session.lineWidgets = new Array(this.session.getLength());
+
+ var old = this.session.lineWidgets[w.row];
+ if (old) {
+ w.$oldWidget = old;
+ if (old.el && old.el.parentNode) {
+ old.el.parentNode.removeChild(old.el);
+ old._inDocument = false;
+ }
+ }
+
+ this.session.lineWidgets[w.row] = w;
+
+ w.session = this.session;
+
+ var renderer = this.editor.renderer;
+ if (w.html && !w.el) {
+ w.el = dom.createElement("div");
+ w.el.innerHTML = w.html;
+ }
+ if (w.el) {
+ dom.addCssClass(w.el, "ace_lineWidgetContainer");
+ w.el.style.position = "absolute";
+ w.el.style.zIndex = 5;
+ renderer.container.appendChild(w.el);
+ w._inDocument = true;
+ }
+
+ if (!w.coverGutter) {
+ w.el.style.zIndex = 3;
+ }
+ if (w.pixelHeight == null) {
+ w.pixelHeight = w.el.offsetHeight;
+ }
+ if (w.rowCount == null) {
+ w.rowCount = w.pixelHeight / renderer.layerConfig.lineHeight;
+ }
+
+ var fold = this.session.getFoldAt(w.row, 0);
+ w.$fold = fold;
+ if (fold) {
+ var lineWidgets = this.session.lineWidgets;
+ if (w.row == fold.end.row && !lineWidgets[fold.start.row])
+ lineWidgets[fold.start.row] = w;
+ else
+ w.hidden = true;
+ }
+
+ this.session._emit("changeFold", {data:{start:{row: w.row}}});
+
+ this.$updateRows();
+ this.renderWidgets(null, renderer);
+ this.onWidgetChanged(w);
+ return w;
+ };
+
+ this.removeLineWidget = function(w) {
+ w._inDocument = false;
+ w.session = null;
+ if (w.el && w.el.parentNode)
+ w.el.parentNode.removeChild(w.el);
+ if (w.editor && w.editor.destroy) try {
+ w.editor.destroy();
+ } catch(e){}
+ if (this.session.lineWidgets) {
+ var w1 = this.session.lineWidgets[w.row]
+ if (w1 == w) {
+ this.session.lineWidgets[w.row] = w.$oldWidget;
+ if (w.$oldWidget)
+ this.onWidgetChanged(w.$oldWidget);
+ } else {
+ while (w1) {
+ if (w1.$oldWidget == w) {
+ w1.$oldWidget = w.$oldWidget;
+ break;
+ }
+ w1 = w1.$oldWidget;
+ }
+ }
+ }
+ this.session._emit("changeFold", {data:{start:{row: w.row}}});
+ this.$updateRows();
+ };
+
+ this.getWidgetsAtRow = function(row) {
+ var lineWidgets = this.session.lineWidgets;
+ var w = lineWidgets && lineWidgets[row];
+ var list = [];
+ while (w) {
+ list.push(w);
+ w = w.$oldWidget;
+ }
+ return list;
+ };
+
+ this.onWidgetChanged = function(w) {
+ this.session._changedWidgets.push(w);
+ this.editor && this.editor.renderer.updateFull();
+ };
+
+ this.measureWidgets = function(e, renderer) {
+ var changedWidgets = this.session._changedWidgets;
+ var config = renderer.layerConfig;
+
+ if (!changedWidgets || !changedWidgets.length) return;
+ var min = Infinity;
+ for (var i = 0; i < changedWidgets.length; i++) {
+ var w = changedWidgets[i];
+ if (!w || !w.el) continue;
+ if (w.session != this.session) continue;
+ if (!w._inDocument) {
+ if (this.session.lineWidgets[w.row] != w)
+ continue;
+ w._inDocument = true;
+ renderer.container.appendChild(w.el);
+ }
+
+ w.h = w.el.offsetHeight;
+
+ if (!w.fixedWidth) {
+ w.w = w.el.offsetWidth;
+ w.screenWidth = Math.ceil(w.w / config.characterWidth);
+ }
+
+ var rowCount = w.h / config.lineHeight;
+ if (w.coverLine) {
+ rowCount -= this.session.getRowLineCount(w.row);
+ if (rowCount < 0)
+ rowCount = 0;
+ }
+ if (w.rowCount != rowCount) {
+ w.rowCount = rowCount;
+ if (w.row < min)
+ min = w.row;
+ }
+ }
+ if (min != Infinity) {
+ this.session._emit("changeFold", {data:{start:{row: min}}});
+ this.session.lineWidgetWidth = null;
+ }
+ this.session._changedWidgets = [];
+ };
+
+ this.renderWidgets = function(e, renderer) {
+ var config = renderer.layerConfig;
+ var lineWidgets = this.session.lineWidgets;
+ if (!lineWidgets)
+ return;
+ var first = Math.min(this.firstRow, config.firstRow);
+ var last = Math.max(this.lastRow, config.lastRow, lineWidgets.length);
+
+ while (first > 0 && !lineWidgets[first])
+ first--;
+
+ this.firstRow = config.firstRow;
+ this.lastRow = config.lastRow;
+
+ renderer.$cursorLayer.config = config;
+ for (var i = first; i <= last; i++) {
+ var w = lineWidgets[i];
+ if (!w || !w.el) continue;
+ if (w.hidden) {
+ w.el.style.top = -100 - (w.pixelHeight || 0) + "px";
+ continue;
+ }
+ if (!w._inDocument) {
+ w._inDocument = true;
+ renderer.container.appendChild(w.el);
+ }
+ var top = renderer.$cursorLayer.getPixelPosition({row: i, column:0}, true).top;
+ if (!w.coverLine)
+ top += config.lineHeight * this.session.getRowLineCount(w.row);
+ w.el.style.top = top - config.offset + "px";
+
+ var left = w.coverGutter ? 0 : renderer.gutterWidth;
+ if (!w.fixedWidth)
+ left -= renderer.scrollLeft;
+ w.el.style.left = left + "px";
+
+ if (w.fullWidth && w.screenWidth) {
+ w.el.style.minWidth = config.width + 2 * config.padding + "px";
+ }
+
+ if (w.fixedWidth) {
+ w.el.style.right = renderer.scrollBar.getWidth() + "px";
+ } else {
+ w.el.style.right = "";
+ }
+ }
+ };
+
+}).call(LineWidgets.prototype);
+
+
+exports.LineWidgets = LineWidgets;
+
+});
+
+ace.define("ace/ext/error_marker",["require","exports","module","ace/line_widgets","ace/lib/dom","ace/range"], function(require, exports, module) {
+"use strict";
+var LineWidgets = require("../line_widgets").LineWidgets;
+var dom = require("../lib/dom");
+var Range = require("../range").Range;
+
+function binarySearch(array, needle, comparator) {
+ var first = 0;
+ var last = array.length - 1;
+
+ while (first <= last) {
+ var mid = (first + last) >> 1;
+ var c = comparator(needle, array[mid]);
+ if (c > 0)
+ first = mid + 1;
+ else if (c < 0)
+ last = mid - 1;
+ else
+ return mid;
+ }
+ return -(first + 1);
+}
+
+function findAnnotations(session, row, dir) {
+ var annotations = session.getAnnotations().sort(Range.comparePoints);
+ if (!annotations.length)
+ return;
+
+ var i = binarySearch(annotations, {row: row, column: -1}, Range.comparePoints);
+ if (i < 0)
+ i = -i - 1;
+
+ if (i >= annotations.length)
+ i = dir > 0 ? 0 : annotations.length - 1;
+ else if (i === 0 && dir < 0)
+ i = annotations.length - 1;
+
+ var annotation = annotations[i];
+ if (!annotation || !dir)
+ return;
+
+ if (annotation.row === row) {
+ do {
+ annotation = annotations[i += dir];
+ } while (annotation && annotation.row === row);
+ if (!annotation)
+ return annotations.slice();
+ }
+
+
+ var matched = [];
+ row = annotation.row;
+ do {
+ matched[dir < 0 ? "unshift" : "push"](annotation);
+ annotation = annotations[i += dir];
+ } while (annotation && annotation.row == row);
+ return matched.length && matched;
+}
+
+exports.showErrorMarker = function(editor, dir) {
+ var session = editor.session;
+ if (!session.widgetManager) {
+ session.widgetManager = new LineWidgets(session);
+ session.widgetManager.attach(editor);
+ }
+
+ var pos = editor.getCursorPosition();
+ var row = pos.row;
+ var oldWidget = session.widgetManager.getWidgetsAtRow(row).filter(function(w) {
+ return w.type == "errorMarker";
+ })[0];
+ if (oldWidget) {
+ oldWidget.destroy();
+ } else {
+ row -= dir;
+ }
+ var annotations = findAnnotations(session, row, dir);
+ var gutterAnno;
+ if (annotations) {
+ var annotation = annotations[0];
+ pos.column = (annotation.pos && typeof annotation.column != "number"
+ ? annotation.pos.sc
+ : annotation.column) || 0;
+ pos.row = annotation.row;
+ gutterAnno = editor.renderer.$gutterLayer.$annotations[pos.row];
+ } else if (oldWidget) {
+ return;
+ } else {
+ gutterAnno = {
+ text: ["Looks good!"],
+ className: "ace_ok"
+ };
+ }
+ editor.session.unfold(pos.row);
+ editor.selection.moveToPosition(pos);
+
+ var w = {
+ row: pos.row,
+ fixedWidth: true,
+ coverGutter: true,
+ el: dom.createElement("div"),
+ type: "errorMarker"
+ };
+ var el = w.el.appendChild(dom.createElement("div"));
+ var arrow = w.el.appendChild(dom.createElement("div"));
+ arrow.className = "error_widget_arrow " + gutterAnno.className;
+
+ var left = editor.renderer.$cursorLayer
+ .getPixelPosition(pos).left;
+ arrow.style.left = left + editor.renderer.gutterWidth - 5 + "px";
+
+ w.el.className = "error_widget_wrapper";
+ el.className = "error_widget " + gutterAnno.className;
+ el.innerHTML = gutterAnno.text.join("<br>");
+
+ el.appendChild(dom.createElement("div"));
+
+ var kb = function(_, hashId, keyString) {
+ if (hashId === 0 && (keyString === "esc" || keyString === "return")) {
+ w.destroy();
+ return {command: "null"};
+ }
+ };
+
+ w.destroy = function() {
+ if (editor.$mouseHandler.isMousePressed)
+ return;
+ editor.keyBinding.removeKeyboardHandler(kb);
+ session.widgetManager.removeLineWidget(w);
+ editor.off("changeSelection", w.destroy);
+ editor.off("changeSession", w.destroy);
+ editor.off("mouseup", w.destroy);
+ editor.off("change", w.destroy);
+ };
+
+ editor.keyBinding.addKeyboardHandler(kb);
+ editor.on("changeSelection", w.destroy);
+ editor.on("changeSession", w.destroy);
+ editor.on("mouseup", w.destroy);
+ editor.on("change", w.destroy);
+
+ editor.session.widgetManager.addLineWidget(w);
+
+ w.el.onmousedown = editor.focus.bind(editor);
+
+ editor.renderer.scrollCursorIntoView(null, 0.5, {bottom: w.el.offsetHeight});
+};
+
+
+dom.importCssString("\
+ .error_widget_wrapper {\
+ background: inherit;\
+ color: inherit;\
+ border:none\
+ }\
+ .error_widget {\
+ border-top: solid 2px;\
+ border-bottom: solid 2px;\
+ margin: 5px 0;\
+ padding: 10px 40px;\
+ white-space: pre-wrap;\
+ }\
+ .error_widget.ace_error, .error_widget_arrow.ace_error{\
+ border-color: #ff5a5a\
+ }\
+ .error_widget.ace_warning, .error_widget_arrow.ace_warning{\
+ border-color: #F1D817\
+ }\
+ .error_widget.ace_info, .error_widget_arrow.ace_info{\
+ border-color: #5a5a5a\
+ }\
+ .error_widget.ace_ok, .error_widget_arrow.ace_ok{\
+ border-color: #5aaa5a\
+ }\
+ .error_widget_arrow {\
+ position: absolute;\
+ border: solid 5px;\
+ border-top-color: transparent!important;\
+ border-right-color: transparent!important;\
+ border-left-color: transparent!important;\
+ top: -5px;\
+ }\
+", "");
+
+});
+
+ace.define("ace/ace",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/dom","ace/lib/event","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config"], function(require, exports, module) {
+"use strict";
+
+require("./lib/fixoldbrowsers");
+
+var dom = require("./lib/dom");
+var event = require("./lib/event");
+
+var Editor = require("./editor").Editor;
+var EditSession = require("./edit_session").EditSession;
+var UndoManager = require("./undomanager").UndoManager;
+var Renderer = require("./virtual_renderer").VirtualRenderer;
+require("./worker/worker_client");
+require("./keyboard/hash_handler");
+require("./placeholder");
+require("./multi_select");
+require("./mode/folding/fold_mode");
+require("./theme/textmate");
+require("./ext/error_marker");
+
+exports.config = require("./config");
+exports.require = require;
+
+if (typeof define === "function")
+ exports.define = define;
+exports.edit = function(el) {
+ if (typeof el == "string") {
+ var _id = el;
+ el = document.getElementById(_id);
+ if (!el)
+ throw new Error("ace.edit can't find div #" + _id);
+ }
+
+ if (el && el.env && el.env.editor instanceof Editor)
+ return el.env.editor;
+
+ var value = "";
+ if (el && /input|textarea/i.test(el.tagName)) {
+ var oldNode = el;
+ value = oldNode.value;
+ el = dom.createElement("pre");
+ oldNode.parentNode.replaceChild(el, oldNode);
+ } else if (el) {
+ value = dom.getInnerText(el);
+ el.innerHTML = "";
+ }
+
+ var doc = exports.createEditSession(value);
+
+ var editor = new Editor(new Renderer(el));
+ editor.setSession(doc);
+
+ var env = {
+ document: doc,
+ editor: editor,
+ onResize: editor.resize.bind(editor, null)
+ };
+ if (oldNode) env.textarea = oldNode;
+ event.addListener(window, "resize", env.onResize);
+ editor.on("destroy", function() {
+ event.removeListener(window, "resize", env.onResize);
+ env.editor.container.env = null; // prevent memory leak on old ie
+ });
+ editor.container.env = editor.env = env;
+ return editor;
+};
+exports.createEditSession = function(text, mode) {
+ var doc = new EditSession(text, mode);
+ doc.setUndoManager(new UndoManager());
+ return doc;
+}
+exports.EditSession = EditSession;
+exports.UndoManager = UndoManager;
+exports.version = "1.2.8";
+});
+ (function() {
+ ace.require(["ace/ace"], function(a) {
+ if (a) {
+ a.config.init(true);
+ a.define = ace.define;
+ }
+ if (!window.ace)
+ window.ace = a;
+ for (var key in a) if (a.hasOwnProperty(key))
+ window.ace[key] = a[key];
+ });
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-beautify.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-beautify.js
new file mode 100644
index 00000000..ba499b77
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-beautify.js
@@ -0,0 +1,334 @@
+ace.define("ace/ext/beautify/php_rules",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+var TokenIterator = require("ace/token_iterator").TokenIterator;
+exports.newLines = [{
+ type: 'support.php_tag',
+ value: '<?php'
+}, {
+ type: 'support.php_tag',
+ value: '<?'
+}, {
+ type: 'support.php_tag',
+ value: '?>'
+}, {
+ type: 'paren.lparen',
+ value: '{',
+ indent: true
+}, {
+ type: 'paren.rparen',
+ breakBefore: true,
+ value: '}',
+ indent: false
+}, {
+ type: 'paren.rparen',
+ breakBefore: true,
+ value: '})',
+ indent: false,
+ dontBreak: true
+}, {
+ type: 'comment'
+}, {
+ type: 'text',
+ value: ';'
+}, {
+ type: 'text',
+ value: ':',
+ context: 'php'
+}, {
+ type: 'keyword',
+ value: 'case',
+ indent: true,
+ dontBreak: true
+}, {
+ type: 'keyword',
+ value: 'default',
+ indent: true,
+ dontBreak: true
+}, {
+ type: 'keyword',
+ value: 'break',
+ indent: false,
+ dontBreak: true
+}, {
+ type: 'punctuation.doctype.end',
+ value: '>'
+}, {
+ type: 'meta.tag.punctuation.end',
+ value: '>'
+}, {
+ type: 'meta.tag.punctuation.begin',
+ value: '<',
+ blockTag: true,
+ indent: true,
+ dontBreak: true
+}, {
+ type: 'meta.tag.punctuation.begin',
+ value: '</',
+ indent: false,
+ breakBefore: true,
+ dontBreak: true
+}, {
+ type: 'punctuation.operator',
+ value: ';'
+}];
+
+exports.spaces = [{
+ type: 'xml-pe',
+ prepend: true
+},{
+ type: 'entity.other.attribute-name',
+ prepend: true
+}, {
+ type: 'storage.type',
+ value: 'var',
+ append: true
+}, {
+ type: 'storage.type',
+ value: 'function',
+ append: true
+}, {
+ type: 'keyword.operator',
+ value: '='
+}, {
+ type: 'keyword',
+ value: 'as',
+ prepend: true,
+ append: true
+}, {
+ type: 'keyword',
+ value: 'function',
+ append: true
+}, {
+ type: 'support.function',
+ next: /[^\(]/,
+ append: true
+}, {
+ type: 'keyword',
+ value: 'or',
+ append: true,
+ prepend: true
+}, {
+ type: 'keyword',
+ value: 'and',
+ append: true,
+ prepend: true
+}, {
+ type: 'keyword',
+ value: 'case',
+ append: true
+}, {
+ type: 'keyword.operator',
+ value: '||',
+ append: true,
+ prepend: true
+}, {
+ type: 'keyword.operator',
+ value: '&&',
+ append: true,
+ prepend: true
+}];
+exports.singleTags = ['!doctype','area','base','br','hr','input','img','link','meta'];
+
+exports.transform = function(iterator, maxPos, context) {
+ var token = iterator.getCurrentToken();
+
+ var newLines = exports.newLines;
+ var spaces = exports.spaces;
+ var singleTags = exports.singleTags;
+
+ var code = '';
+
+ var indentation = 0;
+ var dontBreak = false;
+ var tag;
+ var lastTag;
+ var lastToken = {};
+ var nextTag;
+ var nextToken = {};
+ var breakAdded = false;
+ var value = '';
+
+ while (token!==null) {
+ console.log(token);
+
+ if( !token ){
+ token = iterator.stepForward();
+ continue;
+ }
+ if( token.type == 'support.php_tag' && token.value != '?>' ){
+ context = 'php';
+ }
+ else if( token.type == 'support.php_tag' && token.value == '?>' ){
+ context = 'html';
+ }
+ else if( token.type == 'meta.tag.name.style' && context != 'css' ){
+ context = 'css';
+ }
+ else if( token.type == 'meta.tag.name.style' && context == 'css' ){
+ context = 'html';
+ }
+ else if( token.type == 'meta.tag.name.script' && context != 'js' ){
+ context = 'js';
+ }
+ else if( token.type == 'meta.tag.name.script' && context == 'js' ){
+ context = 'html';
+ }
+
+ nextToken = iterator.stepForward();
+ if (nextToken && nextToken.type.indexOf('meta.tag.name') == 0) {
+ nextTag = nextToken.value;
+ }
+ if ( lastToken.type == 'support.php_tag' && lastToken.value == '<?=') {
+ dontBreak = true;
+ }
+ if (token.type == 'meta.tag.name') {
+ token.value = token.value.toLowerCase();
+ }
+ if (token.type == 'text') {
+ token.value = token.value.trim();
+ }
+ if (!token.value) {
+ token = nextToken;
+ continue;
+ }
+ value = token.value;
+ for (var i in spaces) {
+ if (
+ token.type == spaces[i].type &&
+ (!spaces[i].value || token.value == spaces[i].value) &&
+ (
+ nextToken &&
+ (!spaces[i].next || spaces[i].next.test(nextToken.value))
+ )
+ ) {
+ if (spaces[i].prepend) {
+ value = ' ' + token.value;
+ }
+
+ if (spaces[i].append) {
+ value += ' ';
+ }
+ }
+ }
+ if (token.type.indexOf('meta.tag.name') == 0) {
+ tag = token.value;
+ }
+ breakAdded = false;
+ for (i in newLines) {
+ if (
+ token.type == newLines[i].type &&
+ (
+ !newLines[i].value ||
+ token.value == newLines[i].value
+ ) &&
+ (
+ !newLines[i].blockTag ||
+ singleTags.indexOf(nextTag) === -1
+ ) &&
+ (
+ !newLines[i].context ||
+ newLines[i].context === context
+ )
+ ) {
+ if (newLines[i].indent === false) {
+ indentation--;
+ }
+
+ if (
+ newLines[i].breakBefore &&
+ ( !newLines[i].prev || newLines[i].prev.test(lastToken.value) )
+ ) {
+ code += "\n";
+ breakAdded = true;
+ for (i = 0; i < indentation; i++) {
+ code += "\t";
+ }
+ }
+
+ break;
+ }
+ }
+
+ if (dontBreak===false) {
+ for (i in newLines) {
+ if (
+ lastToken.type == newLines[i].type &&
+ (
+ !newLines[i].value || lastToken.value == newLines[i].value
+ ) &&
+ (
+ !newLines[i].blockTag ||
+ singleTags.indexOf(tag) === -1
+ ) &&
+ (
+ !newLines[i].context ||
+ newLines[i].context === context
+ )
+ ) {
+ if (newLines[i].indent === true) {
+ indentation++;
+ }
+
+ if (!newLines[i].dontBreak && !breakAdded) {
+ code += "\n";
+ for (i = 0; i < indentation; i++) {
+ code += "\t";
+ }
+ }
+
+ break;
+ }
+ }
+ }
+
+ code += value;
+ if ( lastToken.type == 'support.php_tag' && lastToken.value == '?>' ) {
+ dontBreak = false;
+ }
+ lastTag = tag;
+
+ lastToken = token;
+
+ token = nextToken;
+
+ if (token===null) {
+ break;
+ }
+ }
+
+ return code;
+};
+
+
+
+});
+
+ace.define("ace/ext/beautify",["require","exports","module","ace/token_iterator","ace/ext/beautify/php_rules"], function(require, exports, module) {
+"use strict";
+var TokenIterator = require("ace/token_iterator").TokenIterator;
+
+var phpTransform = require("./beautify/php_rules").transform;
+
+exports.beautify = function(session) {
+ var iterator = new TokenIterator(session, 0, 0);
+ var token = iterator.getCurrentToken();
+
+ var context = session.$modeId.split("/").pop();
+
+ var code = phpTransform(iterator, context);
+ session.doc.setValue(code);
+};
+
+exports.commands = [{
+ name: "beautify",
+ exec: function(editor) {
+ exports.beautify(editor.session);
+ },
+ bindKey: "Ctrl-Shift-B"
+}]
+
+});
+ (function() {
+ ace.require(["ace/ext/beautify"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-elastic_tabstops_lite.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-elastic_tabstops_lite.js
new file mode 100644
index 00000000..14e8855f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-elastic_tabstops_lite.js
@@ -0,0 +1,274 @@
+ace.define("ace/ext/elastic_tabstops_lite",["require","exports","module","ace/editor","ace/config"], function(require, exports, module) {
+"use strict";
+
+var ElasticTabstopsLite = function(editor) {
+ this.$editor = editor;
+ var self = this;
+ var changedRows = [];
+ var recordChanges = false;
+ this.onAfterExec = function() {
+ recordChanges = false;
+ self.processRows(changedRows);
+ changedRows = [];
+ };
+ this.onExec = function() {
+ recordChanges = true;
+ };
+ this.onChange = function(delta) {
+ if (recordChanges) {
+ if (changedRows.indexOf(delta.start.row) == -1)
+ changedRows.push(delta.start.row);
+ if (delta.end.row != delta.start.row)
+ changedRows.push(delta.end.row);
+ }
+ };
+};
+
+(function() {
+ this.processRows = function(rows) {
+ this.$inChange = true;
+ var checkedRows = [];
+
+ for (var r = 0, rowCount = rows.length; r < rowCount; r++) {
+ var row = rows[r];
+
+ if (checkedRows.indexOf(row) > -1)
+ continue;
+
+ var cellWidthObj = this.$findCellWidthsForBlock(row);
+ var cellWidths = this.$setBlockCellWidthsToMax(cellWidthObj.cellWidths);
+ var rowIndex = cellWidthObj.firstRow;
+
+ for (var w = 0, l = cellWidths.length; w < l; w++) {
+ var widths = cellWidths[w];
+ checkedRows.push(rowIndex);
+ this.$adjustRow(rowIndex, widths);
+ rowIndex++;
+ }
+ }
+ this.$inChange = false;
+ };
+
+ this.$findCellWidthsForBlock = function(row) {
+ var cellWidths = [], widths;
+ var rowIter = row;
+ while (rowIter >= 0) {
+ widths = this.$cellWidthsForRow(rowIter);
+ if (widths.length == 0)
+ break;
+
+ cellWidths.unshift(widths);
+ rowIter--;
+ }
+ var firstRow = rowIter + 1;
+ rowIter = row;
+ var numRows = this.$editor.session.getLength();
+
+ while (rowIter < numRows - 1) {
+ rowIter++;
+
+ widths = this.$cellWidthsForRow(rowIter);
+ if (widths.length == 0)
+ break;
+
+ cellWidths.push(widths);
+ }
+
+ return { cellWidths: cellWidths, firstRow: firstRow };
+ };
+
+ this.$cellWidthsForRow = function(row) {
+ var selectionColumns = this.$selectionColumnsForRow(row);
+
+ var tabs = [-1].concat(this.$tabsForRow(row));
+ var widths = tabs.map(function(el) { return 0; } ).slice(1);
+ var line = this.$editor.session.getLine(row);
+
+ for (var i = 0, len = tabs.length - 1; i < len; i++) {
+ var leftEdge = tabs[i]+1;
+ var rightEdge = tabs[i+1];
+
+ var rightmostSelection = this.$rightmostSelectionInCell(selectionColumns, rightEdge);
+ var cell = line.substring(leftEdge, rightEdge);
+ widths[i] = Math.max(cell.replace(/\s+$/g,'').length, rightmostSelection - leftEdge);
+ }
+
+ return widths;
+ };
+
+ this.$selectionColumnsForRow = function(row) {
+ var selections = [], cursor = this.$editor.getCursorPosition();
+ if (this.$editor.session.getSelection().isEmpty()) {
+ if (row == cursor.row)
+ selections.push(cursor.column);
+ }
+
+ return selections;
+ };
+
+ this.$setBlockCellWidthsToMax = function(cellWidths) {
+ var startingNewBlock = true, blockStartRow, blockEndRow, maxWidth;
+ var columnInfo = this.$izip_longest(cellWidths);
+
+ for (var c = 0, l = columnInfo.length; c < l; c++) {
+ var column = columnInfo[c];
+ if (!column.push) {
+ console.error(column);
+ continue;
+ }
+ column.push(NaN);
+
+ for (var r = 0, s = column.length; r < s; r++) {
+ var width = column[r];
+ if (startingNewBlock) {
+ blockStartRow = r;
+ maxWidth = 0;
+ startingNewBlock = false;
+ }
+ if (isNaN(width)) {
+ blockEndRow = r;
+
+ for (var j = blockStartRow; j < blockEndRow; j++) {
+ cellWidths[j][c] = maxWidth;
+ }
+ startingNewBlock = true;
+ }
+
+ maxWidth = Math.max(maxWidth, width);
+ }
+ }
+
+ return cellWidths;
+ };
+
+ this.$rightmostSelectionInCell = function(selectionColumns, cellRightEdge) {
+ var rightmost = 0;
+
+ if (selectionColumns.length) {
+ var lengths = [];
+ for (var s = 0, length = selectionColumns.length; s < length; s++) {
+ if (selectionColumns[s] <= cellRightEdge)
+ lengths.push(s);
+ else
+ lengths.push(0);
+ }
+ rightmost = Math.max.apply(Math, lengths);
+ }
+
+ return rightmost;
+ };
+
+ this.$tabsForRow = function(row) {
+ var rowTabs = [], line = this.$editor.session.getLine(row),
+ re = /\t/g, match;
+
+ while ((match = re.exec(line)) != null) {
+ rowTabs.push(match.index);
+ }
+
+ return rowTabs;
+ };
+
+ this.$adjustRow = function(row, widths) {
+ var rowTabs = this.$tabsForRow(row);
+
+ if (rowTabs.length == 0)
+ return;
+
+ var bias = 0, location = -1;
+ var expandedSet = this.$izip(widths, rowTabs);
+
+ for (var i = 0, l = expandedSet.length; i < l; i++) {
+ var w = expandedSet[i][0], it = expandedSet[i][1];
+ location += 1 + w;
+ it += bias;
+ var difference = location - it;
+
+ if (difference == 0)
+ continue;
+
+ var partialLine = this.$editor.session.getLine(row).substr(0, it );
+ var strippedPartialLine = partialLine.replace(/\s*$/g, "");
+ var ispaces = partialLine.length - strippedPartialLine.length;
+
+ if (difference > 0) {
+ this.$editor.session.getDocument().insertInLine({row: row, column: it + 1}, Array(difference + 1).join(" ") + "\t");
+ this.$editor.session.getDocument().removeInLine(row, it, it + 1);
+
+ bias += difference;
+ }
+
+ if (difference < 0 && ispaces >= -difference) {
+ this.$editor.session.getDocument().removeInLine(row, it + difference, it);
+ bias += difference;
+ }
+ }
+ };
+ this.$izip_longest = function(iterables) {
+ if (!iterables[0])
+ return [];
+ var longest = iterables[0].length;
+ var iterablesLength = iterables.length;
+
+ for (var i = 1; i < iterablesLength; i++) {
+ var iLength = iterables[i].length;
+ if (iLength > longest)
+ longest = iLength;
+ }
+
+ var expandedSet = [];
+
+ for (var l = 0; l < longest; l++) {
+ var set = [];
+ for (var i = 0; i < iterablesLength; i++) {
+ if (iterables[i][l] === "")
+ set.push(NaN);
+ else
+ set.push(iterables[i][l]);
+ }
+
+ expandedSet.push(set);
+ }
+
+
+ return expandedSet;
+ };
+ this.$izip = function(widths, tabs) {
+ var size = widths.length >= tabs.length ? tabs.length : widths.length;
+
+ var expandedSet = [];
+ for (var i = 0; i < size; i++) {
+ var set = [ widths[i], tabs[i] ];
+ expandedSet.push(set);
+ }
+ return expandedSet;
+ };
+
+}).call(ElasticTabstopsLite.prototype);
+
+exports.ElasticTabstopsLite = ElasticTabstopsLite;
+
+var Editor = require("../editor").Editor;
+require("../config").defineOptions(Editor.prototype, "editor", {
+ useElasticTabstops: {
+ set: function(val) {
+ if (val) {
+ if (!this.elasticTabstops)
+ this.elasticTabstops = new ElasticTabstopsLite(this);
+ this.commands.on("afterExec", this.elasticTabstops.onAfterExec);
+ this.commands.on("exec", this.elasticTabstops.onExec);
+ this.on("change", this.elasticTabstops.onChange);
+ } else if (this.elasticTabstops) {
+ this.commands.removeListener("afterExec", this.elasticTabstops.onAfterExec);
+ this.commands.removeListener("exec", this.elasticTabstops.onExec);
+ this.removeListener("change", this.elasticTabstops.onChange);
+ }
+ }
+ }
+});
+
+});
+ (function() {
+ ace.require(["ace/ext/elastic_tabstops_lite"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-emmet.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-emmet.js
new file mode 100644
index 00000000..c2f2d1a1
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-emmet.js
@@ -0,0 +1,1223 @@
+ace.define("ace/snippets",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/anchor","ace/keyboard/hash_handler","ace/tokenizer","ace/lib/dom","ace/editor"], function(require, exports, module) {
+"use strict";
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var lang = require("./lib/lang");
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+var HashHandler = require("./keyboard/hash_handler").HashHandler;
+var Tokenizer = require("./tokenizer").Tokenizer;
+var comparePoints = Range.comparePoints;
+
+var SnippetManager = function() {
+ this.snippetMap = {};
+ this.snippetNameMap = {};
+};
+
+(function() {
+ oop.implement(this, EventEmitter);
+
+ this.getTokenizer = function() {
+ function TabstopToken(str, _, stack) {
+ str = str.substr(1);
+ if (/^\d+$/.test(str) && !stack.inFormatString)
+ return [{tabstopId: parseInt(str, 10)}];
+ return [{text: str}];
+ }
+ function escape(ch) {
+ return "(?:[^\\\\" + ch + "]|\\\\.)";
+ }
+ SnippetManager.$tokenizer = new Tokenizer({
+ start: [
+ {regex: /:/, onMatch: function(val, state, stack) {
+ if (stack.length && stack[0].expectIf) {
+ stack[0].expectIf = false;
+ stack[0].elseBranch = stack[0];
+ return [stack[0]];
+ }
+ return ":";
+ }},
+ {regex: /\\./, onMatch: function(val, state, stack) {
+ var ch = val[1];
+ if (ch == "}" && stack.length) {
+ val = ch;
+ }else if ("`$\\".indexOf(ch) != -1) {
+ val = ch;
+ } else if (stack.inFormatString) {
+ if (ch == "n")
+ val = "\n";
+ else if (ch == "t")
+ val = "\n";
+ else if ("ulULE".indexOf(ch) != -1) {
+ val = {changeCase: ch, local: ch > "a"};
+ }
+ }
+
+ return [val];
+ }},
+ {regex: /}/, onMatch: function(val, state, stack) {
+ return [stack.length ? stack.shift() : val];
+ }},
+ {regex: /\$(?:\d+|\w+)/, onMatch: TabstopToken},
+ {regex: /\$\{[\dA-Z_a-z]+/, onMatch: function(str, state, stack) {
+ var t = TabstopToken(str.substr(1), state, stack);
+ stack.unshift(t[0]);
+ return t;
+ }, next: "snippetVar"},
+ {regex: /\n/, token: "newline", merge: false}
+ ],
+ snippetVar: [
+ {regex: "\\|" + escape("\\|") + "*\\|", onMatch: function(val, state, stack) {
+ stack[0].choices = val.slice(1, -1).split(",");
+ }, next: "start"},
+ {regex: "/(" + escape("/") + "+)/(?:(" + escape("/") + "*)/)(\\w*):?",
+ onMatch: function(val, state, stack) {
+ var ts = stack[0];
+ ts.fmtString = val;
+
+ val = this.splitRegex.exec(val);
+ ts.guard = val[1];
+ ts.fmt = val[2];
+ ts.flag = val[3];
+ return "";
+ }, next: "start"},
+ {regex: "`" + escape("`") + "*`", onMatch: function(val, state, stack) {
+ stack[0].code = val.splice(1, -1);
+ return "";
+ }, next: "start"},
+ {regex: "\\?", onMatch: function(val, state, stack) {
+ if (stack[0])
+ stack[0].expectIf = true;
+ }, next: "start"},
+ {regex: "([^:}\\\\]|\\\\.)*:?", token: "", next: "start"}
+ ],
+ formatString: [
+ {regex: "/(" + escape("/") + "+)/", token: "regex"},
+ {regex: "", onMatch: function(val, state, stack) {
+ stack.inFormatString = true;
+ }, next: "start"}
+ ]
+ });
+ SnippetManager.prototype.getTokenizer = function() {
+ return SnippetManager.$tokenizer;
+ };
+ return SnippetManager.$tokenizer;
+ };
+
+ this.tokenizeTmSnippet = function(str, startState) {
+ return this.getTokenizer().getLineTokens(str, startState).tokens.map(function(x) {
+ return x.value || x;
+ });
+ };
+
+ this.$getDefaultValue = function(editor, name) {
+ if (/^[A-Z]\d+$/.test(name)) {
+ var i = name.substr(1);
+ return (this.variables[name[0] + "__"] || {})[i];
+ }
+ if (/^\d+$/.test(name)) {
+ return (this.variables.__ || {})[name];
+ }
+ name = name.replace(/^TM_/, "");
+
+ if (!editor)
+ return;
+ var s = editor.session;
+ switch(name) {
+ case "CURRENT_WORD":
+ var r = s.getWordRange();
+ case "SELECTION":
+ case "SELECTED_TEXT":
+ return s.getTextRange(r);
+ case "CURRENT_LINE":
+ return s.getLine(editor.getCursorPosition().row);
+ case "PREV_LINE": // not possible in textmate
+ return s.getLine(editor.getCursorPosition().row - 1);
+ case "LINE_INDEX":
+ return editor.getCursorPosition().column;
+ case "LINE_NUMBER":
+ return editor.getCursorPosition().row + 1;
+ case "SOFT_TABS":
+ return s.getUseSoftTabs() ? "YES" : "NO";
+ case "TAB_SIZE":
+ return s.getTabSize();
+ case "FILENAME":
+ case "FILEPATH":
+ return "";
+ case "FULLNAME":
+ return "Ace";
+ }
+ };
+ this.variables = {};
+ this.getVariableValue = function(editor, varName) {
+ if (this.variables.hasOwnProperty(varName))
+ return this.variables[varName](editor, varName) || "";
+ return this.$getDefaultValue(editor, varName) || "";
+ };
+ this.tmStrFormat = function(str, ch, editor) {
+ var flag = ch.flag || "";
+ var re = ch.guard;
+ re = new RegExp(re, flag.replace(/[^gi]/, ""));
+ var fmtTokens = this.tokenizeTmSnippet(ch.fmt, "formatString");
+ var _self = this;
+ var formatted = str.replace(re, function() {
+ _self.variables.__ = arguments;
+ var fmtParts = _self.resolveVariables(fmtTokens, editor);
+ var gChangeCase = "E";
+ for (var i = 0; i < fmtParts.length; i++) {
+ var ch = fmtParts[i];
+ if (typeof ch == "object") {
+ fmtParts[i] = "";
+ if (ch.changeCase && ch.local) {
+ var next = fmtParts[i + 1];
+ if (next && typeof next == "string") {
+ if (ch.changeCase == "u")
+ fmtParts[i] = next[0].toUpperCase();
+ else
+ fmtParts[i] = next[0].toLowerCase();
+ fmtParts[i + 1] = next.substr(1);
+ }
+ } else if (ch.changeCase) {
+ gChangeCase = ch.changeCase;
+ }
+ } else if (gChangeCase == "U") {
+ fmtParts[i] = ch.toUpperCase();
+ } else if (gChangeCase == "L") {
+ fmtParts[i] = ch.toLowerCase();
+ }
+ }
+ return fmtParts.join("");
+ });
+ this.variables.__ = null;
+ return formatted;
+ };
+
+ this.resolveVariables = function(snippet, editor) {
+ var result = [];
+ for (var i = 0; i < snippet.length; i++) {
+ var ch = snippet[i];
+ if (typeof ch == "string") {
+ result.push(ch);
+ } else if (typeof ch != "object") {
+ continue;
+ } else if (ch.skip) {
+ gotoNext(ch);
+ } else if (ch.processed < i) {
+ continue;
+ } else if (ch.text) {
+ var value = this.getVariableValue(editor, ch.text);
+ if (value && ch.fmtString)
+ value = this.tmStrFormat(value, ch);
+ ch.processed = i;
+ if (ch.expectIf == null) {
+ if (value) {
+ result.push(value);
+ gotoNext(ch);
+ }
+ } else {
+ if (value) {
+ ch.skip = ch.elseBranch;
+ } else
+ gotoNext(ch);
+ }
+ } else if (ch.tabstopId != null) {
+ result.push(ch);
+ } else if (ch.changeCase != null) {
+ result.push(ch);
+ }
+ }
+ function gotoNext(ch) {
+ var i1 = snippet.indexOf(ch, i + 1);
+ if (i1 != -1)
+ i = i1;
+ }
+ return result;
+ };
+
+ this.insertSnippetForSelection = function(editor, snippetText) {
+ var cursor = editor.getCursorPosition();
+ var line = editor.session.getLine(cursor.row);
+ var tabString = editor.session.getTabString();
+ var indentString = line.match(/^\s*/)[0];
+
+ if (cursor.column < indentString.length)
+ indentString = indentString.slice(0, cursor.column);
+
+ snippetText = snippetText.replace(/\r/g, "");
+ var tokens = this.tokenizeTmSnippet(snippetText);
+ tokens = this.resolveVariables(tokens, editor);
+ tokens = tokens.map(function(x) {
+ if (x == "\n")
+ return x + indentString;
+ if (typeof x == "string")
+ return x.replace(/\t/g, tabString);
+ return x;
+ });
+ var tabstops = [];
+ tokens.forEach(function(p, i) {
+ if (typeof p != "object")
+ return;
+ var id = p.tabstopId;
+ var ts = tabstops[id];
+ if (!ts) {
+ ts = tabstops[id] = [];
+ ts.index = id;
+ ts.value = "";
+ }
+ if (ts.indexOf(p) !== -1)
+ return;
+ ts.push(p);
+ var i1 = tokens.indexOf(p, i + 1);
+ if (i1 === -1)
+ return;
+
+ var value = tokens.slice(i + 1, i1);
+ var isNested = value.some(function(t) {return typeof t === "object"});
+ if (isNested && !ts.value) {
+ ts.value = value;
+ } else if (value.length && (!ts.value || typeof ts.value !== "string")) {
+ ts.value = value.join("");
+ }
+ });
+ tabstops.forEach(function(ts) {ts.length = 0});
+ var expanding = {};
+ function copyValue(val) {
+ var copy = [];
+ for (var i = 0; i < val.length; i++) {
+ var p = val[i];
+ if (typeof p == "object") {
+ if (expanding[p.tabstopId])
+ continue;
+ var j = val.lastIndexOf(p, i - 1);
+ p = copy[j] || {tabstopId: p.tabstopId};
+ }
+ copy[i] = p;
+ }
+ return copy;
+ }
+ for (var i = 0; i < tokens.length; i++) {
+ var p = tokens[i];
+ if (typeof p != "object")
+ continue;
+ var id = p.tabstopId;
+ var i1 = tokens.indexOf(p, i + 1);
+ if (expanding[id]) {
+ if (expanding[id] === p)
+ expanding[id] = null;
+ continue;
+ }
+
+ var ts = tabstops[id];
+ var arg = typeof ts.value == "string" ? [ts.value] : copyValue(ts.value);
+ arg.unshift(i + 1, Math.max(0, i1 - i));
+ arg.push(p);
+ expanding[id] = p;
+ tokens.splice.apply(tokens, arg);
+
+ if (ts.indexOf(p) === -1)
+ ts.push(p);
+ }
+ var row = 0, column = 0;
+ var text = "";
+ tokens.forEach(function(t) {
+ if (typeof t === "string") {
+ var lines = t.split("\n");
+ if (lines.length > 1){
+ column = lines[lines.length - 1].length;
+ row += lines.length - 1;
+ } else
+ column += t.length;
+ text += t;
+ } else {
+ if (!t.start)
+ t.start = {row: row, column: column};
+ else
+ t.end = {row: row, column: column};
+ }
+ });
+ var range = editor.getSelectionRange();
+ var end = editor.session.replace(range, text);
+
+ var tabstopManager = new TabstopManager(editor);
+ var selectionId = editor.inVirtualSelectionMode && editor.selection.index;
+ tabstopManager.addTabstops(tabstops, range.start, end, selectionId);
+ };
+
+ this.insertSnippet = function(editor, snippetText) {
+ var self = this;
+ if (editor.inVirtualSelectionMode)
+ return self.insertSnippetForSelection(editor, snippetText);
+
+ editor.forEachSelection(function() {
+ self.insertSnippetForSelection(editor, snippetText);
+ }, null, {keepOrder: true});
+
+ if (editor.tabstopManager)
+ editor.tabstopManager.tabNext();
+ };
+
+ this.$getScope = function(editor) {
+ var scope = editor.session.$mode.$id || "";
+ scope = scope.split("/").pop();
+ if (scope === "html" || scope === "php") {
+ if (scope === "php" && !editor.session.$mode.inlinePhp)
+ scope = "html";
+ var c = editor.getCursorPosition();
+ var state = editor.session.getState(c.row);
+ if (typeof state === "object") {
+ state = state[0];
+ }
+ if (state.substring) {
+ if (state.substring(0, 3) == "js-")
+ scope = "javascript";
+ else if (state.substring(0, 4) == "css-")
+ scope = "css";
+ else if (state.substring(0, 4) == "php-")
+ scope = "php";
+ }
+ }
+
+ return scope;
+ };
+
+ this.getActiveScopes = function(editor) {
+ var scope = this.$getScope(editor);
+ var scopes = [scope];
+ var snippetMap = this.snippetMap;
+ if (snippetMap[scope] && snippetMap[scope].includeScopes) {
+ scopes.push.apply(scopes, snippetMap[scope].includeScopes);
+ }
+ scopes.push("_");
+ return scopes;
+ };
+
+ this.expandWithTab = function(editor, options) {
+ var self = this;
+ var result = editor.forEachSelection(function() {
+ return self.expandSnippetForSelection(editor, options);
+ }, null, {keepOrder: true});
+ if (result && editor.tabstopManager)
+ editor.tabstopManager.tabNext();
+ return result;
+ };
+
+ this.expandSnippetForSelection = function(editor, options) {
+ var cursor = editor.getCursorPosition();
+ var line = editor.session.getLine(cursor.row);
+ var before = line.substring(0, cursor.column);
+ var after = line.substr(cursor.column);
+
+ var snippetMap = this.snippetMap;
+ var snippet;
+ this.getActiveScopes(editor).some(function(scope) {
+ var snippets = snippetMap[scope];
+ if (snippets)
+ snippet = this.findMatchingSnippet(snippets, before, after);
+ return !!snippet;
+ }, this);
+ if (!snippet)
+ return false;
+ if (options && options.dryRun)
+ return true;
+ editor.session.doc.removeInLine(cursor.row,
+ cursor.column - snippet.replaceBefore.length,
+ cursor.column + snippet.replaceAfter.length
+ );
+
+ this.variables.M__ = snippet.matchBefore;
+ this.variables.T__ = snippet.matchAfter;
+ this.insertSnippetForSelection(editor, snippet.content);
+
+ this.variables.M__ = this.variables.T__ = null;
+ return true;
+ };
+
+ this.findMatchingSnippet = function(snippetList, before, after) {
+ for (var i = snippetList.length; i--;) {
+ var s = snippetList[i];
+ if (s.startRe && !s.startRe.test(before))
+ continue;
+ if (s.endRe && !s.endRe.test(after))
+ continue;
+ if (!s.startRe && !s.endRe)
+ continue;
+
+ s.matchBefore = s.startRe ? s.startRe.exec(before) : [""];
+ s.matchAfter = s.endRe ? s.endRe.exec(after) : [""];
+ s.replaceBefore = s.triggerRe ? s.triggerRe.exec(before)[0] : "";
+ s.replaceAfter = s.endTriggerRe ? s.endTriggerRe.exec(after)[0] : "";
+ return s;
+ }
+ };
+
+ this.snippetMap = {};
+ this.snippetNameMap = {};
+ this.register = function(snippets, scope) {
+ var snippetMap = this.snippetMap;
+ var snippetNameMap = this.snippetNameMap;
+ var self = this;
+
+ if (!snippets)
+ snippets = [];
+
+ function wrapRegexp(src) {
+ if (src && !/^\^?\(.*\)\$?$|^\\b$/.test(src))
+ src = "(?:" + src + ")";
+
+ return src || "";
+ }
+ function guardedRegexp(re, guard, opening) {
+ re = wrapRegexp(re);
+ guard = wrapRegexp(guard);
+ if (opening) {
+ re = guard + re;
+ if (re && re[re.length - 1] != "$")
+ re = re + "$";
+ } else {
+ re = re + guard;
+ if (re && re[0] != "^")
+ re = "^" + re;
+ }
+ return new RegExp(re);
+ }
+
+ function addSnippet(s) {
+ if (!s.scope)
+ s.scope = scope || "_";
+ scope = s.scope;
+ if (!snippetMap[scope]) {
+ snippetMap[scope] = [];
+ snippetNameMap[scope] = {};
+ }
+
+ var map = snippetNameMap[scope];
+ if (s.name) {
+ var old = map[s.name];
+ if (old)
+ self.unregister(old);
+ map[s.name] = s;
+ }
+ snippetMap[scope].push(s);
+
+ if (s.tabTrigger && !s.trigger) {
+ if (!s.guard && /^\w/.test(s.tabTrigger))
+ s.guard = "\\b";
+ s.trigger = lang.escapeRegExp(s.tabTrigger);
+ }
+
+ if (!s.trigger && !s.guard && !s.endTrigger && !s.endGuard)
+ return;
+
+ s.startRe = guardedRegexp(s.trigger, s.guard, true);
+ s.triggerRe = new RegExp(s.trigger, "", true);
+
+ s.endRe = guardedRegexp(s.endTrigger, s.endGuard, true);
+ s.endTriggerRe = new RegExp(s.endTrigger, "", true);
+ }
+
+ if (snippets && snippets.content)
+ addSnippet(snippets);
+ else if (Array.isArray(snippets))
+ snippets.forEach(addSnippet);
+
+ this._signal("registerSnippets", {scope: scope});
+ };
+ this.unregister = function(snippets, scope) {
+ var snippetMap = this.snippetMap;
+ var snippetNameMap = this.snippetNameMap;
+
+ function removeSnippet(s) {
+ var nameMap = snippetNameMap[s.scope||scope];
+ if (nameMap && nameMap[s.name]) {
+ delete nameMap[s.name];
+ var map = snippetMap[s.scope||scope];
+ var i = map && map.indexOf(s);
+ if (i >= 0)
+ map.splice(i, 1);
+ }
+ }
+ if (snippets.content)
+ removeSnippet(snippets);
+ else if (Array.isArray(snippets))
+ snippets.forEach(removeSnippet);
+ };
+ this.parseSnippetFile = function(str) {
+ str = str.replace(/\r/g, "");
+ var list = [], snippet = {};
+ var re = /^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm;
+ var m;
+ while (m = re.exec(str)) {
+ if (m[1]) {
+ try {
+ snippet = JSON.parse(m[1]);
+ list.push(snippet);
+ } catch (e) {}
+ } if (m[4]) {
+ snippet.content = m[4].replace(/^\t/gm, "");
+ list.push(snippet);
+ snippet = {};
+ } else {
+ var key = m[2], val = m[3];
+ if (key == "regex") {
+ var guardRe = /\/((?:[^\/\\]|\\.)*)|$/g;
+ snippet.guard = guardRe.exec(val)[1];
+ snippet.trigger = guardRe.exec(val)[1];
+ snippet.endTrigger = guardRe.exec(val)[1];
+ snippet.endGuard = guardRe.exec(val)[1];
+ } else if (key == "snippet") {
+ snippet.tabTrigger = val.match(/^\S*/)[0];
+ if (!snippet.name)
+ snippet.name = val;
+ } else {
+ snippet[key] = val;
+ }
+ }
+ }
+ return list;
+ };
+ this.getSnippetByName = function(name, editor) {
+ var snippetMap = this.snippetNameMap;
+ var snippet;
+ this.getActiveScopes(editor).some(function(scope) {
+ var snippets = snippetMap[scope];
+ if (snippets)
+ snippet = snippets[name];
+ return !!snippet;
+ }, this);
+ return snippet;
+ };
+
+}).call(SnippetManager.prototype);
+
+
+var TabstopManager = function(editor) {
+ if (editor.tabstopManager)
+ return editor.tabstopManager;
+ editor.tabstopManager = this;
+ this.$onChange = this.onChange.bind(this);
+ this.$onChangeSelection = lang.delayedCall(this.onChangeSelection.bind(this)).schedule;
+ this.$onChangeSession = this.onChangeSession.bind(this);
+ this.$onAfterExec = this.onAfterExec.bind(this);
+ this.attach(editor);
+};
+(function() {
+ this.attach = function(editor) {
+ this.index = 0;
+ this.ranges = [];
+ this.tabstops = [];
+ this.$openTabstops = null;
+ this.selectedTabstop = null;
+
+ this.editor = editor;
+ this.editor.on("change", this.$onChange);
+ this.editor.on("changeSelection", this.$onChangeSelection);
+ this.editor.on("changeSession", this.$onChangeSession);
+ this.editor.commands.on("afterExec", this.$onAfterExec);
+ this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);
+ };
+ this.detach = function() {
+ this.tabstops.forEach(this.removeTabstopMarkers, this);
+ this.ranges = null;
+ this.tabstops = null;
+ this.selectedTabstop = null;
+ this.editor.removeListener("change", this.$onChange);
+ this.editor.removeListener("changeSelection", this.$onChangeSelection);
+ this.editor.removeListener("changeSession", this.$onChangeSession);
+ this.editor.commands.removeListener("afterExec", this.$onAfterExec);
+ this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler);
+ this.editor.tabstopManager = null;
+ this.editor = null;
+ };
+
+ this.onChange = function(delta) {
+ var changeRange = delta;
+ var isRemove = delta.action[0] == "r";
+ var start = delta.start;
+ var end = delta.end;
+ var startRow = start.row;
+ var endRow = end.row;
+ var lineDif = endRow - startRow;
+ var colDiff = end.column - start.column;
+
+ if (isRemove) {
+ lineDif = -lineDif;
+ colDiff = -colDiff;
+ }
+ if (!this.$inChange && isRemove) {
+ var ts = this.selectedTabstop;
+ var changedOutside = ts && !ts.some(function(r) {
+ return comparePoints(r.start, start) <= 0 && comparePoints(r.end, end) >= 0;
+ });
+ if (changedOutside)
+ return this.detach();
+ }
+ var ranges = this.ranges;
+ for (var i = 0; i < ranges.length; i++) {
+ var r = ranges[i];
+ if (r.end.row < start.row)
+ continue;
+
+ if (isRemove && comparePoints(start, r.start) < 0 && comparePoints(end, r.end) > 0) {
+ this.removeRange(r);
+ i--;
+ continue;
+ }
+
+ if (r.start.row == startRow && r.start.column > start.column)
+ r.start.column += colDiff;
+ if (r.end.row == startRow && r.end.column >= start.column)
+ r.end.column += colDiff;
+ if (r.start.row >= startRow)
+ r.start.row += lineDif;
+ if (r.end.row >= startRow)
+ r.end.row += lineDif;
+
+ if (comparePoints(r.start, r.end) > 0)
+ this.removeRange(r);
+ }
+ if (!ranges.length)
+ this.detach();
+ };
+ this.updateLinkedFields = function() {
+ var ts = this.selectedTabstop;
+ if (!ts || !ts.hasLinkedRanges)
+ return;
+ this.$inChange = true;
+ var session = this.editor.session;
+ var text = session.getTextRange(ts.firstNonLinked);
+ for (var i = ts.length; i--;) {
+ var range = ts[i];
+ if (!range.linked)
+ continue;
+ var fmt = exports.snippetManager.tmStrFormat(text, range.original);
+ session.replace(range, fmt);
+ }
+ this.$inChange = false;
+ };
+ this.onAfterExec = function(e) {
+ if (e.command && !e.command.readOnly)
+ this.updateLinkedFields();
+ };
+ this.onChangeSelection = function() {
+ if (!this.editor)
+ return;
+ var lead = this.editor.selection.lead;
+ var anchor = this.editor.selection.anchor;
+ var isEmpty = this.editor.selection.isEmpty();
+ for (var i = this.ranges.length; i--;) {
+ if (this.ranges[i].linked)
+ continue;
+ var containsLead = this.ranges[i].contains(lead.row, lead.column);
+ var containsAnchor = isEmpty || this.ranges[i].contains(anchor.row, anchor.column);
+ if (containsLead && containsAnchor)
+ return;
+ }
+ this.detach();
+ };
+ this.onChangeSession = function() {
+ this.detach();
+ };
+ this.tabNext = function(dir) {
+ var max = this.tabstops.length;
+ var index = this.index + (dir || 1);
+ index = Math.min(Math.max(index, 1), max);
+ if (index == max)
+ index = 0;
+ this.selectTabstop(index);
+ if (index === 0)
+ this.detach();
+ };
+ this.selectTabstop = function(index) {
+ this.$openTabstops = null;
+ var ts = this.tabstops[this.index];
+ if (ts)
+ this.addTabstopMarkers(ts);
+ this.index = index;
+ ts = this.tabstops[this.index];
+ if (!ts || !ts.length)
+ return;
+
+ this.selectedTabstop = ts;
+ if (!this.editor.inVirtualSelectionMode) {
+ var sel = this.editor.multiSelect;
+ sel.toSingleRange(ts.firstNonLinked.clone());
+ for (var i = ts.length; i--;) {
+ if (ts.hasLinkedRanges && ts[i].linked)
+ continue;
+ sel.addRange(ts[i].clone(), true);
+ }
+ if (sel.ranges[0])
+ sel.addRange(sel.ranges[0].clone());
+ } else {
+ this.editor.selection.setRange(ts.firstNonLinked);
+ }
+
+ this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);
+ };
+ this.addTabstops = function(tabstops, start, end) {
+ if (!this.$openTabstops)
+ this.$openTabstops = [];
+ if (!tabstops[0]) {
+ var p = Range.fromPoints(end, end);
+ moveRelative(p.start, start);
+ moveRelative(p.end, start);
+ tabstops[0] = [p];
+ tabstops[0].index = 0;
+ }
+
+ var i = this.index;
+ var arg = [i + 1, 0];
+ var ranges = this.ranges;
+ tabstops.forEach(function(ts, index) {
+ var dest = this.$openTabstops[index] || ts;
+
+ for (var i = ts.length; i--;) {
+ var p = ts[i];
+ var range = Range.fromPoints(p.start, p.end || p.start);
+ movePoint(range.start, start);
+ movePoint(range.end, start);
+ range.original = p;
+ range.tabstop = dest;
+ ranges.push(range);
+ if (dest != ts)
+ dest.unshift(range);
+ else
+ dest[i] = range;
+ if (p.fmtString) {
+ range.linked = true;
+ dest.hasLinkedRanges = true;
+ } else if (!dest.firstNonLinked)
+ dest.firstNonLinked = range;
+ }
+ if (!dest.firstNonLinked)
+ dest.hasLinkedRanges = false;
+ if (dest === ts) {
+ arg.push(dest);
+ this.$openTabstops[index] = dest;
+ }
+ this.addTabstopMarkers(dest);
+ }, this);
+
+ if (arg.length > 2) {
+ if (this.tabstops.length)
+ arg.push(arg.splice(2, 1)[0]);
+ this.tabstops.splice.apply(this.tabstops, arg);
+ }
+ };
+
+ this.addTabstopMarkers = function(ts) {
+ var session = this.editor.session;
+ ts.forEach(function(range) {
+ if (!range.markerId)
+ range.markerId = session.addMarker(range, "ace_snippet-marker", "text");
+ });
+ };
+ this.removeTabstopMarkers = function(ts) {
+ var session = this.editor.session;
+ ts.forEach(function(range) {
+ session.removeMarker(range.markerId);
+ range.markerId = null;
+ });
+ };
+ this.removeRange = function(range) {
+ var i = range.tabstop.indexOf(range);
+ range.tabstop.splice(i, 1);
+ i = this.ranges.indexOf(range);
+ this.ranges.splice(i, 1);
+ this.editor.session.removeMarker(range.markerId);
+ if (!range.tabstop.length) {
+ i = this.tabstops.indexOf(range.tabstop);
+ if (i != -1)
+ this.tabstops.splice(i, 1);
+ if (!this.tabstops.length)
+ this.detach();
+ }
+ };
+
+ this.keyboardHandler = new HashHandler();
+ this.keyboardHandler.bindKeys({
+ "Tab": function(ed) {
+ if (exports.snippetManager && exports.snippetManager.expandWithTab(ed)) {
+ return;
+ }
+
+ ed.tabstopManager.tabNext(1);
+ },
+ "Shift-Tab": function(ed) {
+ ed.tabstopManager.tabNext(-1);
+ },
+ "Esc": function(ed) {
+ ed.tabstopManager.detach();
+ },
+ "Return": function(ed) {
+ return false;
+ }
+ });
+}).call(TabstopManager.prototype);
+
+
+
+var changeTracker = {};
+changeTracker.onChange = Anchor.prototype.onChange;
+changeTracker.setPosition = function(row, column) {
+ this.pos.row = row;
+ this.pos.column = column;
+};
+changeTracker.update = function(pos, delta, $insertRight) {
+ this.$insertRight = $insertRight;
+ this.pos = pos;
+ this.onChange(delta);
+};
+
+var movePoint = function(point, diff) {
+ if (point.row == 0)
+ point.column += diff.column;
+ point.row += diff.row;
+};
+
+var moveRelative = function(point, start) {
+ if (point.row == start.row)
+ point.column -= start.column;
+ point.row -= start.row;
+};
+
+
+require("./lib/dom").importCssString("\
+.ace_snippet-marker {\
+ -moz-box-sizing: border-box;\
+ box-sizing: border-box;\
+ background: rgba(194, 193, 208, 0.09);\
+ border: 1px dotted rgba(211, 208, 235, 0.62);\
+ position: absolute;\
+}");
+
+exports.snippetManager = new SnippetManager();
+
+
+var Editor = require("./editor").Editor;
+(function() {
+ this.insertSnippet = function(content, options) {
+ return exports.snippetManager.insertSnippet(this, content, options);
+ };
+ this.expandSnippet = function(options) {
+ return exports.snippetManager.expandWithTab(this, options);
+ };
+}).call(Editor.prototype);
+
+});
+
+ace.define("ace/ext/emmet",["require","exports","module","ace/keyboard/hash_handler","ace/editor","ace/snippets","ace/range","resources","resources","tabStops","resources","utils","actions","ace/config","ace/config"], function(require, exports, module) {
+"use strict";
+var HashHandler = require("ace/keyboard/hash_handler").HashHandler;
+var Editor = require("ace/editor").Editor;
+var snippetManager = require("ace/snippets").snippetManager;
+var Range = require("ace/range").Range;
+var emmet, emmetPath;
+function AceEmmetEditor() {}
+
+AceEmmetEditor.prototype = {
+ setupContext: function(editor) {
+ this.ace = editor;
+ this.indentation = editor.session.getTabString();
+ if (!emmet)
+ emmet = window.emmet;
+ var resources = emmet.resources || emmet.require("resources");
+ resources.setVariable("indentation", this.indentation);
+ this.$syntax = null;
+ this.$syntax = this.getSyntax();
+ },
+ getSelectionRange: function() {
+ var range = this.ace.getSelectionRange();
+ var doc = this.ace.session.doc;
+ return {
+ start: doc.positionToIndex(range.start),
+ end: doc.positionToIndex(range.end)
+ };
+ },
+ createSelection: function(start, end) {
+ var doc = this.ace.session.doc;
+ this.ace.selection.setRange({
+ start: doc.indexToPosition(start),
+ end: doc.indexToPosition(end)
+ });
+ },
+ getCurrentLineRange: function() {
+ var ace = this.ace;
+ var row = ace.getCursorPosition().row;
+ var lineLength = ace.session.getLine(row).length;
+ var index = ace.session.doc.positionToIndex({row: row, column: 0});
+ return {
+ start: index,
+ end: index + lineLength
+ };
+ },
+ getCaretPos: function(){
+ var pos = this.ace.getCursorPosition();
+ return this.ace.session.doc.positionToIndex(pos);
+ },
+ setCaretPos: function(index){
+ var pos = this.ace.session.doc.indexToPosition(index);
+ this.ace.selection.moveToPosition(pos);
+ },
+ getCurrentLine: function() {
+ var row = this.ace.getCursorPosition().row;
+ return this.ace.session.getLine(row);
+ },
+ replaceContent: function(value, start, end, noIndent) {
+ if (end == null)
+ end = start == null ? this.getContent().length : start;
+ if (start == null)
+ start = 0;
+
+ var editor = this.ace;
+ var doc = editor.session.doc;
+ var range = Range.fromPoints(doc.indexToPosition(start), doc.indexToPosition(end));
+ editor.session.remove(range);
+
+ range.end = range.start;
+
+ value = this.$updateTabstops(value);
+ snippetManager.insertSnippet(editor, value);
+ },
+ getContent: function(){
+ return this.ace.getValue();
+ },
+ getSyntax: function() {
+ if (this.$syntax)
+ return this.$syntax;
+ var syntax = this.ace.session.$modeId.split("/").pop();
+ if (syntax == "html" || syntax == "php") {
+ var cursor = this.ace.getCursorPosition();
+ var state = this.ace.session.getState(cursor.row);
+ if (typeof state != "string")
+ state = state[0];
+ if (state) {
+ state = state.split("-");
+ if (state.length > 1)
+ syntax = state[0];
+ else if (syntax == "php")
+ syntax = "html";
+ }
+ }
+ return syntax;
+ },
+ getProfileName: function() {
+ var resources = emmet.resources || emmet.require("resources");
+ switch (this.getSyntax()) {
+ case "css": return "css";
+ case "xml":
+ case "xsl":
+ return "xml";
+ case "html":
+ var profile = resources.getVariable("profile");
+ if (!profile)
+ profile = this.ace.session.getLines(0,2).join("").search(/<!DOCTYPE[^>]+XHTML/i) != -1 ? "xhtml": "html";
+ return profile;
+ default:
+ var mode = this.ace.session.$mode;
+ return mode.emmetConfig && mode.emmetConfig.profile || "xhtml";
+ }
+ },
+ prompt: function(title) {
+ return prompt(title);
+ },
+ getSelection: function() {
+ return this.ace.session.getTextRange();
+ },
+ getFilePath: function() {
+ return "";
+ },
+ $updateTabstops: function(value) {
+ var base = 1000;
+ var zeroBase = 0;
+ var lastZero = null;
+ var ts = emmet.tabStops || emmet.require('tabStops');
+ var resources = emmet.resources || emmet.require("resources");
+ var settings = resources.getVocabulary("user");
+ var tabstopOptions = {
+ tabstop: function(data) {
+ var group = parseInt(data.group, 10);
+ var isZero = group === 0;
+ if (isZero)
+ group = ++zeroBase;
+ else
+ group += base;
+
+ var placeholder = data.placeholder;
+ if (placeholder) {
+ placeholder = ts.processText(placeholder, tabstopOptions);
+ }
+
+ var result = '${' + group + (placeholder ? ':' + placeholder : '') + '}';
+
+ if (isZero) {
+ lastZero = [data.start, result];
+ }
+
+ return result;
+ },
+ escape: function(ch) {
+ if (ch == '$') return '\\$';
+ if (ch == '\\') return '\\\\';
+ return ch;
+ }
+ };
+
+ value = ts.processText(value, tabstopOptions);
+
+ if (settings.variables['insert_final_tabstop'] && !/\$\{0\}$/.test(value)) {
+ value += '${0}';
+ } else if (lastZero) {
+ var common = emmet.utils ? emmet.utils.common : emmet.require('utils');
+ value = common.replaceSubstring(value, '${0}', lastZero[0], lastZero[1]);
+ }
+
+ return value;
+ }
+};
+
+
+var keymap = {
+ expand_abbreviation: {"mac": "ctrl+alt+e", "win": "alt+e"},
+ match_pair_outward: {"mac": "ctrl+d", "win": "ctrl+,"},
+ match_pair_inward: {"mac": "ctrl+j", "win": "ctrl+shift+0"},
+ matching_pair: {"mac": "ctrl+alt+j", "win": "alt+j"},
+ next_edit_point: "alt+right",
+ prev_edit_point: "alt+left",
+ toggle_comment: {"mac": "command+/", "win": "ctrl+/"},
+ split_join_tag: {"mac": "shift+command+'", "win": "shift+ctrl+`"},
+ remove_tag: {"mac": "command+'", "win": "shift+ctrl+;"},
+ evaluate_math_expression: {"mac": "shift+command+y", "win": "shift+ctrl+y"},
+ increment_number_by_1: "ctrl+up",
+ decrement_number_by_1: "ctrl+down",
+ increment_number_by_01: "alt+up",
+ decrement_number_by_01: "alt+down",
+ increment_number_by_10: {"mac": "alt+command+up", "win": "shift+alt+up"},
+ decrement_number_by_10: {"mac": "alt+command+down", "win": "shift+alt+down"},
+ select_next_item: {"mac": "shift+command+.", "win": "shift+ctrl+."},
+ select_previous_item: {"mac": "shift+command+,", "win": "shift+ctrl+,"},
+ reflect_css_value: {"mac": "shift+command+r", "win": "shift+ctrl+r"},
+
+ encode_decode_data_url: {"mac": "shift+ctrl+d", "win": "ctrl+'"},
+ expand_abbreviation_with_tab: "Tab",
+ wrap_with_abbreviation: {"mac": "shift+ctrl+a", "win": "shift+ctrl+a"}
+};
+
+var editorProxy = new AceEmmetEditor();
+exports.commands = new HashHandler();
+exports.runEmmetCommand = function runEmmetCommand(editor) {
+ try {
+ editorProxy.setupContext(editor);
+ var actions = emmet.actions || emmet.require("actions");
+
+ if (this.action == "expand_abbreviation_with_tab") {
+ if (!editor.selection.isEmpty())
+ return false;
+ var pos = editor.selection.lead;
+ var token = editor.session.getTokenAt(pos.row, pos.column);
+ if (token && /\btag\b/.test(token.type))
+ return false;
+ }
+
+ if (this.action == "wrap_with_abbreviation") {
+ return setTimeout(function() {
+ actions.run("wrap_with_abbreviation", editorProxy);
+ }, 0);
+ }
+
+ var result = actions.run(this.action, editorProxy);
+ } catch(e) {
+ if (!emmet) {
+ load(runEmmetCommand.bind(this, editor));
+ return true;
+ }
+ editor._signal("changeStatus", typeof e == "string" ? e : e.message);
+ console.log(e);
+ result = false;
+ }
+ return result;
+};
+
+for (var command in keymap) {
+ exports.commands.addCommand({
+ name: "emmet:" + command,
+ action: command,
+ bindKey: keymap[command],
+ exec: exports.runEmmetCommand,
+ multiSelectAction: "forEach"
+ });
+}
+
+exports.updateCommands = function(editor, enabled) {
+ if (enabled) {
+ editor.keyBinding.addKeyboardHandler(exports.commands);
+ } else {
+ editor.keyBinding.removeKeyboardHandler(exports.commands);
+ }
+};
+
+exports.isSupportedMode = function(mode) {
+ if (!mode) return false;
+ if (mode.emmetConfig) return true;
+ var id = mode.$id || mode;
+ return /css|less|scss|sass|stylus|html|php|twig|ejs|handlebars/.test(id);
+};
+
+exports.isAvailable = function(editor, command) {
+ if (/(evaluate_math_expression|expand_abbreviation)$/.test(command))
+ return true;
+ var mode = editor.session.$mode;
+ var isSupported = exports.isSupportedMode(mode);
+ if (isSupported && mode.$modes) {
+ try {
+ editorProxy.setupContext(editor);
+ if (/js|php/.test(editorProxy.getSyntax()))
+ isSupported = false;
+ } catch(e) {}
+ }
+ return isSupported;
+}
+
+var onChangeMode = function(e, target) {
+ var editor = target;
+ if (!editor)
+ return;
+ var enabled = exports.isSupportedMode(editor.session.$mode);
+ if (e.enableEmmet === false)
+ enabled = false;
+ if (enabled)
+ load();
+ exports.updateCommands(editor, enabled);
+};
+
+var load = function(cb) {
+ if (typeof emmetPath == "string") {
+ require("ace/config").loadModule(emmetPath, function() {
+ emmetPath = null;
+ cb && cb();
+ });
+ }
+};
+
+exports.AceEmmetEditor = AceEmmetEditor;
+require("ace/config").defineOptions(Editor.prototype, "editor", {
+ enableEmmet: {
+ set: function(val) {
+ this[val ? "on" : "removeListener"]("changeMode", onChangeMode);
+ onChangeMode({enableEmmet: !!val}, this);
+ },
+ value: true
+ }
+});
+
+exports.setCore = function(e) {
+ if (typeof e == "string")
+ emmetPath = e;
+ else
+ emmet = e;
+};
+});
+ (function() {
+ ace.require(["ace/ext/emmet"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-error_marker.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-error_marker.js
new file mode 100644
index 00000000..d4c9eb91
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-error_marker.js
@@ -0,0 +1,6 @@
+
+;
+ (function() {
+ ace.require(["ace/ext/error_marker"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-keybinding_menu.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-keybinding_menu.js
new file mode 100644
index 00000000..ede7d8db
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-keybinding_menu.js
@@ -0,0 +1,170 @@
+ace.define("ace/ext/menu_tools/overlay_page",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+'use strict';
+var dom = require("../../lib/dom");
+var cssText = "#ace_settingsmenu, #kbshortcutmenu {\
+background-color: #F7F7F7;\
+color: black;\
+box-shadow: -5px 4px 5px rgba(126, 126, 126, 0.55);\
+padding: 1em 0.5em 2em 1em;\
+overflow: auto;\
+position: absolute;\
+margin: 0;\
+bottom: 0;\
+right: 0;\
+top: 0;\
+z-index: 9991;\
+cursor: default;\
+}\
+.ace_dark #ace_settingsmenu, .ace_dark #kbshortcutmenu {\
+box-shadow: -20px 10px 25px rgba(126, 126, 126, 0.25);\
+background-color: rgba(255, 255, 255, 0.6);\
+color: black;\
+}\
+.ace_optionsMenuEntry:hover {\
+background-color: rgba(100, 100, 100, 0.1);\
+-webkit-transition: all 0.5s;\
+transition: all 0.3s\
+}\
+.ace_closeButton {\
+background: rgba(245, 146, 146, 0.5);\
+border: 1px solid #F48A8A;\
+border-radius: 50%;\
+padding: 7px;\
+position: absolute;\
+right: -8px;\
+top: -8px;\
+z-index: 1000;\
+}\
+.ace_closeButton{\
+background: rgba(245, 146, 146, 0.9);\
+}\
+.ace_optionsMenuKey {\
+color: darkslateblue;\
+font-weight: bold;\
+}\
+.ace_optionsMenuCommand {\
+color: darkcyan;\
+font-weight: normal;\
+}";
+dom.importCssString(cssText);
+module.exports.overlayPage = function overlayPage(editor, contentElement, top, right, bottom, left) {
+ top = top ? 'top: ' + top + ';' : '';
+ bottom = bottom ? 'bottom: ' + bottom + ';' : '';
+ right = right ? 'right: ' + right + ';' : '';
+ left = left ? 'left: ' + left + ';' : '';
+
+ var closer = document.createElement('div');
+ var contentContainer = document.createElement('div');
+
+ function documentEscListener(e) {
+ if (e.keyCode === 27) {
+ closer.click();
+ }
+ }
+
+ closer.style.cssText = 'margin: 0; padding: 0; ' +
+ 'position: fixed; top:0; bottom:0; left:0; right:0;' +
+ 'z-index: 9990; ' +
+ 'background-color: rgba(0, 0, 0, 0.3);';
+ closer.addEventListener('click', function() {
+ document.removeEventListener('keydown', documentEscListener);
+ closer.parentNode.removeChild(closer);
+ editor.focus();
+ closer = null;
+ });
+ document.addEventListener('keydown', documentEscListener);
+
+ contentContainer.style.cssText = top + right + bottom + left;
+ contentContainer.addEventListener('click', function(e) {
+ e.stopPropagation();
+ });
+
+ var wrapper = dom.createElement("div");
+ wrapper.style.position = "relative";
+
+ var closeButton = dom.createElement("div");
+ closeButton.className = "ace_closeButton";
+ closeButton.addEventListener('click', function() {
+ closer.click();
+ });
+
+ wrapper.appendChild(closeButton);
+ contentContainer.appendChild(wrapper);
+
+ contentContainer.appendChild(contentElement);
+ closer.appendChild(contentContainer);
+ document.body.appendChild(closer);
+ editor.blur();
+};
+
+});
+
+ace.define("ace/ext/menu_tools/get_editor_keyboard_shortcuts",["require","exports","module","ace/lib/keys"], function(require, exports, module) {
+"use strict";
+var keys = require("../../lib/keys");
+module.exports.getEditorKeybordShortcuts = function(editor) {
+ var KEY_MODS = keys.KEY_MODS;
+ var keybindings = [];
+ var commandMap = {};
+ editor.keyBinding.$handlers.forEach(function(handler) {
+ var ckb = handler.commandKeyBinding;
+ for (var i in ckb) {
+ var key = i.replace(/(^|-)\w/g, function(x) { return x.toUpperCase(); });
+ var commands = ckb[i];
+ if (!Array.isArray(commands))
+ commands = [commands];
+ commands.forEach(function(command) {
+ if (typeof command != "string")
+ command = command.name
+ if (commandMap[command]) {
+ commandMap[command].key += "|" + key;
+ } else {
+ commandMap[command] = {key: key, command: command};
+ keybindings.push(commandMap[command]);
+ }
+ });
+ }
+ });
+ return keybindings;
+};
+
+});
+
+ace.define("ace/ext/keybinding_menu",["require","exports","module","ace/editor","ace/ext/menu_tools/overlay_page","ace/ext/menu_tools/get_editor_keyboard_shortcuts"], function(require, exports, module) {
+ "use strict";
+ var Editor = require("ace/editor").Editor;
+ function showKeyboardShortcuts (editor) {
+ if(!document.getElementById('kbshortcutmenu')) {
+ var overlayPage = require('./menu_tools/overlay_page').overlayPage;
+ var getEditorKeybordShortcuts = require('./menu_tools/get_editor_keyboard_shortcuts').getEditorKeybordShortcuts;
+ var kb = getEditorKeybordShortcuts(editor);
+ var el = document.createElement('div');
+ var commands = kb.reduce(function(previous, current) {
+ return previous + '<div class="ace_optionsMenuEntry"><span class="ace_optionsMenuCommand">'
+ + current.command + '</span> : '
+ + '<span class="ace_optionsMenuKey">' + current.key + '</span></div>';
+ }, '');
+
+ el.id = 'kbshortcutmenu';
+ el.innerHTML = '<h1>Keyboard Shortcuts</h1>' + commands + '</div>';
+ overlayPage(editor, el, '0', '0', '0', null);
+ }
+ }
+ module.exports.init = function(editor) {
+ Editor.prototype.showKeyboardShortcuts = function() {
+ showKeyboardShortcuts(this);
+ };
+ editor.commands.addCommands([{
+ name: "showKeyboardShortcuts",
+ bindKey: {win: "Ctrl-Alt-h", mac: "Command-Alt-h"},
+ exec: function(editor, line) {
+ editor.showKeyboardShortcuts();
+ }
+ }]);
+ };
+
+});
+ (function() {
+ ace.require(["ace/ext/keybinding_menu"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-language_tools.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-language_tools.js
new file mode 100644
index 00000000..13366951
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-language_tools.js
@@ -0,0 +1,1956 @@
+ace.define("ace/snippets",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/anchor","ace/keyboard/hash_handler","ace/tokenizer","ace/lib/dom","ace/editor"], function(require, exports, module) {
+"use strict";
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var lang = require("./lib/lang");
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+var HashHandler = require("./keyboard/hash_handler").HashHandler;
+var Tokenizer = require("./tokenizer").Tokenizer;
+var comparePoints = Range.comparePoints;
+
+var SnippetManager = function() {
+ this.snippetMap = {};
+ this.snippetNameMap = {};
+};
+
+(function() {
+ oop.implement(this, EventEmitter);
+
+ this.getTokenizer = function() {
+ function TabstopToken(str, _, stack) {
+ str = str.substr(1);
+ if (/^\d+$/.test(str) && !stack.inFormatString)
+ return [{tabstopId: parseInt(str, 10)}];
+ return [{text: str}];
+ }
+ function escape(ch) {
+ return "(?:[^\\\\" + ch + "]|\\\\.)";
+ }
+ SnippetManager.$tokenizer = new Tokenizer({
+ start: [
+ {regex: /:/, onMatch: function(val, state, stack) {
+ if (stack.length && stack[0].expectIf) {
+ stack[0].expectIf = false;
+ stack[0].elseBranch = stack[0];
+ return [stack[0]];
+ }
+ return ":";
+ }},
+ {regex: /\\./, onMatch: function(val, state, stack) {
+ var ch = val[1];
+ if (ch == "}" && stack.length) {
+ val = ch;
+ }else if ("`$\\".indexOf(ch) != -1) {
+ val = ch;
+ } else if (stack.inFormatString) {
+ if (ch == "n")
+ val = "\n";
+ else if (ch == "t")
+ val = "\n";
+ else if ("ulULE".indexOf(ch) != -1) {
+ val = {changeCase: ch, local: ch > "a"};
+ }
+ }
+
+ return [val];
+ }},
+ {regex: /}/, onMatch: function(val, state, stack) {
+ return [stack.length ? stack.shift() : val];
+ }},
+ {regex: /\$(?:\d+|\w+)/, onMatch: TabstopToken},
+ {regex: /\$\{[\dA-Z_a-z]+/, onMatch: function(str, state, stack) {
+ var t = TabstopToken(str.substr(1), state, stack);
+ stack.unshift(t[0]);
+ return t;
+ }, next: "snippetVar"},
+ {regex: /\n/, token: "newline", merge: false}
+ ],
+ snippetVar: [
+ {regex: "\\|" + escape("\\|") + "*\\|", onMatch: function(val, state, stack) {
+ stack[0].choices = val.slice(1, -1).split(",");
+ }, next: "start"},
+ {regex: "/(" + escape("/") + "+)/(?:(" + escape("/") + "*)/)(\\w*):?",
+ onMatch: function(val, state, stack) {
+ var ts = stack[0];
+ ts.fmtString = val;
+
+ val = this.splitRegex.exec(val);
+ ts.guard = val[1];
+ ts.fmt = val[2];
+ ts.flag = val[3];
+ return "";
+ }, next: "start"},
+ {regex: "`" + escape("`") + "*`", onMatch: function(val, state, stack) {
+ stack[0].code = val.splice(1, -1);
+ return "";
+ }, next: "start"},
+ {regex: "\\?", onMatch: function(val, state, stack) {
+ if (stack[0])
+ stack[0].expectIf = true;
+ }, next: "start"},
+ {regex: "([^:}\\\\]|\\\\.)*:?", token: "", next: "start"}
+ ],
+ formatString: [
+ {regex: "/(" + escape("/") + "+)/", token: "regex"},
+ {regex: "", onMatch: function(val, state, stack) {
+ stack.inFormatString = true;
+ }, next: "start"}
+ ]
+ });
+ SnippetManager.prototype.getTokenizer = function() {
+ return SnippetManager.$tokenizer;
+ };
+ return SnippetManager.$tokenizer;
+ };
+
+ this.tokenizeTmSnippet = function(str, startState) {
+ return this.getTokenizer().getLineTokens(str, startState).tokens.map(function(x) {
+ return x.value || x;
+ });
+ };
+
+ this.$getDefaultValue = function(editor, name) {
+ if (/^[A-Z]\d+$/.test(name)) {
+ var i = name.substr(1);
+ return (this.variables[name[0] + "__"] || {})[i];
+ }
+ if (/^\d+$/.test(name)) {
+ return (this.variables.__ || {})[name];
+ }
+ name = name.replace(/^TM_/, "");
+
+ if (!editor)
+ return;
+ var s = editor.session;
+ switch(name) {
+ case "CURRENT_WORD":
+ var r = s.getWordRange();
+ case "SELECTION":
+ case "SELECTED_TEXT":
+ return s.getTextRange(r);
+ case "CURRENT_LINE":
+ return s.getLine(editor.getCursorPosition().row);
+ case "PREV_LINE": // not possible in textmate
+ return s.getLine(editor.getCursorPosition().row - 1);
+ case "LINE_INDEX":
+ return editor.getCursorPosition().column;
+ case "LINE_NUMBER":
+ return editor.getCursorPosition().row + 1;
+ case "SOFT_TABS":
+ return s.getUseSoftTabs() ? "YES" : "NO";
+ case "TAB_SIZE":
+ return s.getTabSize();
+ case "FILENAME":
+ case "FILEPATH":
+ return "";
+ case "FULLNAME":
+ return "Ace";
+ }
+ };
+ this.variables = {};
+ this.getVariableValue = function(editor, varName) {
+ if (this.variables.hasOwnProperty(varName))
+ return this.variables[varName](editor, varName) || "";
+ return this.$getDefaultValue(editor, varName) || "";
+ };
+ this.tmStrFormat = function(str, ch, editor) {
+ var flag = ch.flag || "";
+ var re = ch.guard;
+ re = new RegExp(re, flag.replace(/[^gi]/, ""));
+ var fmtTokens = this.tokenizeTmSnippet(ch.fmt, "formatString");
+ var _self = this;
+ var formatted = str.replace(re, function() {
+ _self.variables.__ = arguments;
+ var fmtParts = _self.resolveVariables(fmtTokens, editor);
+ var gChangeCase = "E";
+ for (var i = 0; i < fmtParts.length; i++) {
+ var ch = fmtParts[i];
+ if (typeof ch == "object") {
+ fmtParts[i] = "";
+ if (ch.changeCase && ch.local) {
+ var next = fmtParts[i + 1];
+ if (next && typeof next == "string") {
+ if (ch.changeCase == "u")
+ fmtParts[i] = next[0].toUpperCase();
+ else
+ fmtParts[i] = next[0].toLowerCase();
+ fmtParts[i + 1] = next.substr(1);
+ }
+ } else if (ch.changeCase) {
+ gChangeCase = ch.changeCase;
+ }
+ } else if (gChangeCase == "U") {
+ fmtParts[i] = ch.toUpperCase();
+ } else if (gChangeCase == "L") {
+ fmtParts[i] = ch.toLowerCase();
+ }
+ }
+ return fmtParts.join("");
+ });
+ this.variables.__ = null;
+ return formatted;
+ };
+
+ this.resolveVariables = function(snippet, editor) {
+ var result = [];
+ for (var i = 0; i < snippet.length; i++) {
+ var ch = snippet[i];
+ if (typeof ch == "string") {
+ result.push(ch);
+ } else if (typeof ch != "object") {
+ continue;
+ } else if (ch.skip) {
+ gotoNext(ch);
+ } else if (ch.processed < i) {
+ continue;
+ } else if (ch.text) {
+ var value = this.getVariableValue(editor, ch.text);
+ if (value && ch.fmtString)
+ value = this.tmStrFormat(value, ch);
+ ch.processed = i;
+ if (ch.expectIf == null) {
+ if (value) {
+ result.push(value);
+ gotoNext(ch);
+ }
+ } else {
+ if (value) {
+ ch.skip = ch.elseBranch;
+ } else
+ gotoNext(ch);
+ }
+ } else if (ch.tabstopId != null) {
+ result.push(ch);
+ } else if (ch.changeCase != null) {
+ result.push(ch);
+ }
+ }
+ function gotoNext(ch) {
+ var i1 = snippet.indexOf(ch, i + 1);
+ if (i1 != -1)
+ i = i1;
+ }
+ return result;
+ };
+
+ this.insertSnippetForSelection = function(editor, snippetText) {
+ var cursor = editor.getCursorPosition();
+ var line = editor.session.getLine(cursor.row);
+ var tabString = editor.session.getTabString();
+ var indentString = line.match(/^\s*/)[0];
+
+ if (cursor.column < indentString.length)
+ indentString = indentString.slice(0, cursor.column);
+
+ snippetText = snippetText.replace(/\r/g, "");
+ var tokens = this.tokenizeTmSnippet(snippetText);
+ tokens = this.resolveVariables(tokens, editor);
+ tokens = tokens.map(function(x) {
+ if (x == "\n")
+ return x + indentString;
+ if (typeof x == "string")
+ return x.replace(/\t/g, tabString);
+ return x;
+ });
+ var tabstops = [];
+ tokens.forEach(function(p, i) {
+ if (typeof p != "object")
+ return;
+ var id = p.tabstopId;
+ var ts = tabstops[id];
+ if (!ts) {
+ ts = tabstops[id] = [];
+ ts.index = id;
+ ts.value = "";
+ }
+ if (ts.indexOf(p) !== -1)
+ return;
+ ts.push(p);
+ var i1 = tokens.indexOf(p, i + 1);
+ if (i1 === -1)
+ return;
+
+ var value = tokens.slice(i + 1, i1);
+ var isNested = value.some(function(t) {return typeof t === "object"});
+ if (isNested && !ts.value) {
+ ts.value = value;
+ } else if (value.length && (!ts.value || typeof ts.value !== "string")) {
+ ts.value = value.join("");
+ }
+ });
+ tabstops.forEach(function(ts) {ts.length = 0});
+ var expanding = {};
+ function copyValue(val) {
+ var copy = [];
+ for (var i = 0; i < val.length; i++) {
+ var p = val[i];
+ if (typeof p == "object") {
+ if (expanding[p.tabstopId])
+ continue;
+ var j = val.lastIndexOf(p, i - 1);
+ p = copy[j] || {tabstopId: p.tabstopId};
+ }
+ copy[i] = p;
+ }
+ return copy;
+ }
+ for (var i = 0; i < tokens.length; i++) {
+ var p = tokens[i];
+ if (typeof p != "object")
+ continue;
+ var id = p.tabstopId;
+ var i1 = tokens.indexOf(p, i + 1);
+ if (expanding[id]) {
+ if (expanding[id] === p)
+ expanding[id] = null;
+ continue;
+ }
+
+ var ts = tabstops[id];
+ var arg = typeof ts.value == "string" ? [ts.value] : copyValue(ts.value);
+ arg.unshift(i + 1, Math.max(0, i1 - i));
+ arg.push(p);
+ expanding[id] = p;
+ tokens.splice.apply(tokens, arg);
+
+ if (ts.indexOf(p) === -1)
+ ts.push(p);
+ }
+ var row = 0, column = 0;
+ var text = "";
+ tokens.forEach(function(t) {
+ if (typeof t === "string") {
+ var lines = t.split("\n");
+ if (lines.length > 1){
+ column = lines[lines.length - 1].length;
+ row += lines.length - 1;
+ } else
+ column += t.length;
+ text += t;
+ } else {
+ if (!t.start)
+ t.start = {row: row, column: column};
+ else
+ t.end = {row: row, column: column};
+ }
+ });
+ var range = editor.getSelectionRange();
+ var end = editor.session.replace(range, text);
+
+ var tabstopManager = new TabstopManager(editor);
+ var selectionId = editor.inVirtualSelectionMode && editor.selection.index;
+ tabstopManager.addTabstops(tabstops, range.start, end, selectionId);
+ };
+
+ this.insertSnippet = function(editor, snippetText) {
+ var self = this;
+ if (editor.inVirtualSelectionMode)
+ return self.insertSnippetForSelection(editor, snippetText);
+
+ editor.forEachSelection(function() {
+ self.insertSnippetForSelection(editor, snippetText);
+ }, null, {keepOrder: true});
+
+ if (editor.tabstopManager)
+ editor.tabstopManager.tabNext();
+ };
+
+ this.$getScope = function(editor) {
+ var scope = editor.session.$mode.$id || "";
+ scope = scope.split("/").pop();
+ if (scope === "html" || scope === "php") {
+ if (scope === "php" && !editor.session.$mode.inlinePhp)
+ scope = "html";
+ var c = editor.getCursorPosition();
+ var state = editor.session.getState(c.row);
+ if (typeof state === "object") {
+ state = state[0];
+ }
+ if (state.substring) {
+ if (state.substring(0, 3) == "js-")
+ scope = "javascript";
+ else if (state.substring(0, 4) == "css-")
+ scope = "css";
+ else if (state.substring(0, 4) == "php-")
+ scope = "php";
+ }
+ }
+
+ return scope;
+ };
+
+ this.getActiveScopes = function(editor) {
+ var scope = this.$getScope(editor);
+ var scopes = [scope];
+ var snippetMap = this.snippetMap;
+ if (snippetMap[scope] && snippetMap[scope].includeScopes) {
+ scopes.push.apply(scopes, snippetMap[scope].includeScopes);
+ }
+ scopes.push("_");
+ return scopes;
+ };
+
+ this.expandWithTab = function(editor, options) {
+ var self = this;
+ var result = editor.forEachSelection(function() {
+ return self.expandSnippetForSelection(editor, options);
+ }, null, {keepOrder: true});
+ if (result && editor.tabstopManager)
+ editor.tabstopManager.tabNext();
+ return result;
+ };
+
+ this.expandSnippetForSelection = function(editor, options) {
+ var cursor = editor.getCursorPosition();
+ var line = editor.session.getLine(cursor.row);
+ var before = line.substring(0, cursor.column);
+ var after = line.substr(cursor.column);
+
+ var snippetMap = this.snippetMap;
+ var snippet;
+ this.getActiveScopes(editor).some(function(scope) {
+ var snippets = snippetMap[scope];
+ if (snippets)
+ snippet = this.findMatchingSnippet(snippets, before, after);
+ return !!snippet;
+ }, this);
+ if (!snippet)
+ return false;
+ if (options && options.dryRun)
+ return true;
+ editor.session.doc.removeInLine(cursor.row,
+ cursor.column - snippet.replaceBefore.length,
+ cursor.column + snippet.replaceAfter.length
+ );
+
+ this.variables.M__ = snippet.matchBefore;
+ this.variables.T__ = snippet.matchAfter;
+ this.insertSnippetForSelection(editor, snippet.content);
+
+ this.variables.M__ = this.variables.T__ = null;
+ return true;
+ };
+
+ this.findMatchingSnippet = function(snippetList, before, after) {
+ for (var i = snippetList.length; i--;) {
+ var s = snippetList[i];
+ if (s.startRe && !s.startRe.test(before))
+ continue;
+ if (s.endRe && !s.endRe.test(after))
+ continue;
+ if (!s.startRe && !s.endRe)
+ continue;
+
+ s.matchBefore = s.startRe ? s.startRe.exec(before) : [""];
+ s.matchAfter = s.endRe ? s.endRe.exec(after) : [""];
+ s.replaceBefore = s.triggerRe ? s.triggerRe.exec(before)[0] : "";
+ s.replaceAfter = s.endTriggerRe ? s.endTriggerRe.exec(after)[0] : "";
+ return s;
+ }
+ };
+
+ this.snippetMap = {};
+ this.snippetNameMap = {};
+ this.register = function(snippets, scope) {
+ var snippetMap = this.snippetMap;
+ var snippetNameMap = this.snippetNameMap;
+ var self = this;
+
+ if (!snippets)
+ snippets = [];
+
+ function wrapRegexp(src) {
+ if (src && !/^\^?\(.*\)\$?$|^\\b$/.test(src))
+ src = "(?:" + src + ")";
+
+ return src || "";
+ }
+ function guardedRegexp(re, guard, opening) {
+ re = wrapRegexp(re);
+ guard = wrapRegexp(guard);
+ if (opening) {
+ re = guard + re;
+ if (re && re[re.length - 1] != "$")
+ re = re + "$";
+ } else {
+ re = re + guard;
+ if (re && re[0] != "^")
+ re = "^" + re;
+ }
+ return new RegExp(re);
+ }
+
+ function addSnippet(s) {
+ if (!s.scope)
+ s.scope = scope || "_";
+ scope = s.scope;
+ if (!snippetMap[scope]) {
+ snippetMap[scope] = [];
+ snippetNameMap[scope] = {};
+ }
+
+ var map = snippetNameMap[scope];
+ if (s.name) {
+ var old = map[s.name];
+ if (old)
+ self.unregister(old);
+ map[s.name] = s;
+ }
+ snippetMap[scope].push(s);
+
+ if (s.tabTrigger && !s.trigger) {
+ if (!s.guard && /^\w/.test(s.tabTrigger))
+ s.guard = "\\b";
+ s.trigger = lang.escapeRegExp(s.tabTrigger);
+ }
+
+ if (!s.trigger && !s.guard && !s.endTrigger && !s.endGuard)
+ return;
+
+ s.startRe = guardedRegexp(s.trigger, s.guard, true);
+ s.triggerRe = new RegExp(s.trigger, "", true);
+
+ s.endRe = guardedRegexp(s.endTrigger, s.endGuard, true);
+ s.endTriggerRe = new RegExp(s.endTrigger, "", true);
+ }
+
+ if (snippets && snippets.content)
+ addSnippet(snippets);
+ else if (Array.isArray(snippets))
+ snippets.forEach(addSnippet);
+
+ this._signal("registerSnippets", {scope: scope});
+ };
+ this.unregister = function(snippets, scope) {
+ var snippetMap = this.snippetMap;
+ var snippetNameMap = this.snippetNameMap;
+
+ function removeSnippet(s) {
+ var nameMap = snippetNameMap[s.scope||scope];
+ if (nameMap && nameMap[s.name]) {
+ delete nameMap[s.name];
+ var map = snippetMap[s.scope||scope];
+ var i = map && map.indexOf(s);
+ if (i >= 0)
+ map.splice(i, 1);
+ }
+ }
+ if (snippets.content)
+ removeSnippet(snippets);
+ else if (Array.isArray(snippets))
+ snippets.forEach(removeSnippet);
+ };
+ this.parseSnippetFile = function(str) {
+ str = str.replace(/\r/g, "");
+ var list = [], snippet = {};
+ var re = /^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm;
+ var m;
+ while (m = re.exec(str)) {
+ if (m[1]) {
+ try {
+ snippet = JSON.parse(m[1]);
+ list.push(snippet);
+ } catch (e) {}
+ } if (m[4]) {
+ snippet.content = m[4].replace(/^\t/gm, "");
+ list.push(snippet);
+ snippet = {};
+ } else {
+ var key = m[2], val = m[3];
+ if (key == "regex") {
+ var guardRe = /\/((?:[^\/\\]|\\.)*)|$/g;
+ snippet.guard = guardRe.exec(val)[1];
+ snippet.trigger = guardRe.exec(val)[1];
+ snippet.endTrigger = guardRe.exec(val)[1];
+ snippet.endGuard = guardRe.exec(val)[1];
+ } else if (key == "snippet") {
+ snippet.tabTrigger = val.match(/^\S*/)[0];
+ if (!snippet.name)
+ snippet.name = val;
+ } else {
+ snippet[key] = val;
+ }
+ }
+ }
+ return list;
+ };
+ this.getSnippetByName = function(name, editor) {
+ var snippetMap = this.snippetNameMap;
+ var snippet;
+ this.getActiveScopes(editor).some(function(scope) {
+ var snippets = snippetMap[scope];
+ if (snippets)
+ snippet = snippets[name];
+ return !!snippet;
+ }, this);
+ return snippet;
+ };
+
+}).call(SnippetManager.prototype);
+
+
+var TabstopManager = function(editor) {
+ if (editor.tabstopManager)
+ return editor.tabstopManager;
+ editor.tabstopManager = this;
+ this.$onChange = this.onChange.bind(this);
+ this.$onChangeSelection = lang.delayedCall(this.onChangeSelection.bind(this)).schedule;
+ this.$onChangeSession = this.onChangeSession.bind(this);
+ this.$onAfterExec = this.onAfterExec.bind(this);
+ this.attach(editor);
+};
+(function() {
+ this.attach = function(editor) {
+ this.index = 0;
+ this.ranges = [];
+ this.tabstops = [];
+ this.$openTabstops = null;
+ this.selectedTabstop = null;
+
+ this.editor = editor;
+ this.editor.on("change", this.$onChange);
+ this.editor.on("changeSelection", this.$onChangeSelection);
+ this.editor.on("changeSession", this.$onChangeSession);
+ this.editor.commands.on("afterExec", this.$onAfterExec);
+ this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);
+ };
+ this.detach = function() {
+ this.tabstops.forEach(this.removeTabstopMarkers, this);
+ this.ranges = null;
+ this.tabstops = null;
+ this.selectedTabstop = null;
+ this.editor.removeListener("change", this.$onChange);
+ this.editor.removeListener("changeSelection", this.$onChangeSelection);
+ this.editor.removeListener("changeSession", this.$onChangeSession);
+ this.editor.commands.removeListener("afterExec", this.$onAfterExec);
+ this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler);
+ this.editor.tabstopManager = null;
+ this.editor = null;
+ };
+
+ this.onChange = function(delta) {
+ var changeRange = delta;
+ var isRemove = delta.action[0] == "r";
+ var start = delta.start;
+ var end = delta.end;
+ var startRow = start.row;
+ var endRow = end.row;
+ var lineDif = endRow - startRow;
+ var colDiff = end.column - start.column;
+
+ if (isRemove) {
+ lineDif = -lineDif;
+ colDiff = -colDiff;
+ }
+ if (!this.$inChange && isRemove) {
+ var ts = this.selectedTabstop;
+ var changedOutside = ts && !ts.some(function(r) {
+ return comparePoints(r.start, start) <= 0 && comparePoints(r.end, end) >= 0;
+ });
+ if (changedOutside)
+ return this.detach();
+ }
+ var ranges = this.ranges;
+ for (var i = 0; i < ranges.length; i++) {
+ var r = ranges[i];
+ if (r.end.row < start.row)
+ continue;
+
+ if (isRemove && comparePoints(start, r.start) < 0 && comparePoints(end, r.end) > 0) {
+ this.removeRange(r);
+ i--;
+ continue;
+ }
+
+ if (r.start.row == startRow && r.start.column > start.column)
+ r.start.column += colDiff;
+ if (r.end.row == startRow && r.end.column >= start.column)
+ r.end.column += colDiff;
+ if (r.start.row >= startRow)
+ r.start.row += lineDif;
+ if (r.end.row >= startRow)
+ r.end.row += lineDif;
+
+ if (comparePoints(r.start, r.end) > 0)
+ this.removeRange(r);
+ }
+ if (!ranges.length)
+ this.detach();
+ };
+ this.updateLinkedFields = function() {
+ var ts = this.selectedTabstop;
+ if (!ts || !ts.hasLinkedRanges)
+ return;
+ this.$inChange = true;
+ var session = this.editor.session;
+ var text = session.getTextRange(ts.firstNonLinked);
+ for (var i = ts.length; i--;) {
+ var range = ts[i];
+ if (!range.linked)
+ continue;
+ var fmt = exports.snippetManager.tmStrFormat(text, range.original);
+ session.replace(range, fmt);
+ }
+ this.$inChange = false;
+ };
+ this.onAfterExec = function(e) {
+ if (e.command && !e.command.readOnly)
+ this.updateLinkedFields();
+ };
+ this.onChangeSelection = function() {
+ if (!this.editor)
+ return;
+ var lead = this.editor.selection.lead;
+ var anchor = this.editor.selection.anchor;
+ var isEmpty = this.editor.selection.isEmpty();
+ for (var i = this.ranges.length; i--;) {
+ if (this.ranges[i].linked)
+ continue;
+ var containsLead = this.ranges[i].contains(lead.row, lead.column);
+ var containsAnchor = isEmpty || this.ranges[i].contains(anchor.row, anchor.column);
+ if (containsLead && containsAnchor)
+ return;
+ }
+ this.detach();
+ };
+ this.onChangeSession = function() {
+ this.detach();
+ };
+ this.tabNext = function(dir) {
+ var max = this.tabstops.length;
+ var index = this.index + (dir || 1);
+ index = Math.min(Math.max(index, 1), max);
+ if (index == max)
+ index = 0;
+ this.selectTabstop(index);
+ if (index === 0)
+ this.detach();
+ };
+ this.selectTabstop = function(index) {
+ this.$openTabstops = null;
+ var ts = this.tabstops[this.index];
+ if (ts)
+ this.addTabstopMarkers(ts);
+ this.index = index;
+ ts = this.tabstops[this.index];
+ if (!ts || !ts.length)
+ return;
+
+ this.selectedTabstop = ts;
+ if (!this.editor.inVirtualSelectionMode) {
+ var sel = this.editor.multiSelect;
+ sel.toSingleRange(ts.firstNonLinked.clone());
+ for (var i = ts.length; i--;) {
+ if (ts.hasLinkedRanges && ts[i].linked)
+ continue;
+ sel.addRange(ts[i].clone(), true);
+ }
+ if (sel.ranges[0])
+ sel.addRange(sel.ranges[0].clone());
+ } else {
+ this.editor.selection.setRange(ts.firstNonLinked);
+ }
+
+ this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler);
+ };
+ this.addTabstops = function(tabstops, start, end) {
+ if (!this.$openTabstops)
+ this.$openTabstops = [];
+ if (!tabstops[0]) {
+ var p = Range.fromPoints(end, end);
+ moveRelative(p.start, start);
+ moveRelative(p.end, start);
+ tabstops[0] = [p];
+ tabstops[0].index = 0;
+ }
+
+ var i = this.index;
+ var arg = [i + 1, 0];
+ var ranges = this.ranges;
+ tabstops.forEach(function(ts, index) {
+ var dest = this.$openTabstops[index] || ts;
+
+ for (var i = ts.length; i--;) {
+ var p = ts[i];
+ var range = Range.fromPoints(p.start, p.end || p.start);
+ movePoint(range.start, start);
+ movePoint(range.end, start);
+ range.original = p;
+ range.tabstop = dest;
+ ranges.push(range);
+ if (dest != ts)
+ dest.unshift(range);
+ else
+ dest[i] = range;
+ if (p.fmtString) {
+ range.linked = true;
+ dest.hasLinkedRanges = true;
+ } else if (!dest.firstNonLinked)
+ dest.firstNonLinked = range;
+ }
+ if (!dest.firstNonLinked)
+ dest.hasLinkedRanges = false;
+ if (dest === ts) {
+ arg.push(dest);
+ this.$openTabstops[index] = dest;
+ }
+ this.addTabstopMarkers(dest);
+ }, this);
+
+ if (arg.length > 2) {
+ if (this.tabstops.length)
+ arg.push(arg.splice(2, 1)[0]);
+ this.tabstops.splice.apply(this.tabstops, arg);
+ }
+ };
+
+ this.addTabstopMarkers = function(ts) {
+ var session = this.editor.session;
+ ts.forEach(function(range) {
+ if (!range.markerId)
+ range.markerId = session.addMarker(range, "ace_snippet-marker", "text");
+ });
+ };
+ this.removeTabstopMarkers = function(ts) {
+ var session = this.editor.session;
+ ts.forEach(function(range) {
+ session.removeMarker(range.markerId);
+ range.markerId = null;
+ });
+ };
+ this.removeRange = function(range) {
+ var i = range.tabstop.indexOf(range);
+ range.tabstop.splice(i, 1);
+ i = this.ranges.indexOf(range);
+ this.ranges.splice(i, 1);
+ this.editor.session.removeMarker(range.markerId);
+ if (!range.tabstop.length) {
+ i = this.tabstops.indexOf(range.tabstop);
+ if (i != -1)
+ this.tabstops.splice(i, 1);
+ if (!this.tabstops.length)
+ this.detach();
+ }
+ };
+
+ this.keyboardHandler = new HashHandler();
+ this.keyboardHandler.bindKeys({
+ "Tab": function(ed) {
+ if (exports.snippetManager && exports.snippetManager.expandWithTab(ed)) {
+ return;
+ }
+
+ ed.tabstopManager.tabNext(1);
+ },
+ "Shift-Tab": function(ed) {
+ ed.tabstopManager.tabNext(-1);
+ },
+ "Esc": function(ed) {
+ ed.tabstopManager.detach();
+ },
+ "Return": function(ed) {
+ return false;
+ }
+ });
+}).call(TabstopManager.prototype);
+
+
+
+var changeTracker = {};
+changeTracker.onChange = Anchor.prototype.onChange;
+changeTracker.setPosition = function(row, column) {
+ this.pos.row = row;
+ this.pos.column = column;
+};
+changeTracker.update = function(pos, delta, $insertRight) {
+ this.$insertRight = $insertRight;
+ this.pos = pos;
+ this.onChange(delta);
+};
+
+var movePoint = function(point, diff) {
+ if (point.row == 0)
+ point.column += diff.column;
+ point.row += diff.row;
+};
+
+var moveRelative = function(point, start) {
+ if (point.row == start.row)
+ point.column -= start.column;
+ point.row -= start.row;
+};
+
+
+require("./lib/dom").importCssString("\
+.ace_snippet-marker {\
+ -moz-box-sizing: border-box;\
+ box-sizing: border-box;\
+ background: rgba(194, 193, 208, 0.09);\
+ border: 1px dotted rgba(211, 208, 235, 0.62);\
+ position: absolute;\
+}");
+
+exports.snippetManager = new SnippetManager();
+
+
+var Editor = require("./editor").Editor;
+(function() {
+ this.insertSnippet = function(content, options) {
+ return exports.snippetManager.insertSnippet(this, content, options);
+ };
+ this.expandSnippet = function(options) {
+ return exports.snippetManager.expandWithTab(this, options);
+ };
+}).call(Editor.prototype);
+
+});
+
+ace.define("ace/autocomplete/popup",["require","exports","module","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+var Renderer = require("../virtual_renderer").VirtualRenderer;
+var Editor = require("../editor").Editor;
+var Range = require("../range").Range;
+var event = require("../lib/event");
+var lang = require("../lib/lang");
+var dom = require("../lib/dom");
+
+var $singleLineEditor = function(el) {
+ var renderer = new Renderer(el);
+
+ renderer.$maxLines = 4;
+
+ var editor = new Editor(renderer);
+
+ editor.setHighlightActiveLine(false);
+ editor.setShowPrintMargin(false);
+ editor.renderer.setShowGutter(false);
+ editor.renderer.setHighlightGutterLine(false);
+
+ editor.$mouseHandler.$focusWaitTimout = 0;
+ editor.$highlightTagPending = true;
+
+ return editor;
+};
+
+var AcePopup = function(parentNode) {
+ var el = dom.createElement("div");
+ var popup = new $singleLineEditor(el);
+
+ if (parentNode)
+ parentNode.appendChild(el);
+ el.style.display = "none";
+ popup.renderer.content.style.cursor = "default";
+ popup.renderer.setStyle("ace_autocomplete");
+
+ popup.setOption("displayIndentGuides", false);
+ popup.setOption("dragDelay", 150);
+
+ var noop = function(){};
+
+ popup.focus = noop;
+ popup.$isFocused = true;
+
+ popup.renderer.$cursorLayer.restartTimer = noop;
+ popup.renderer.$cursorLayer.element.style.opacity = 0;
+
+ popup.renderer.$maxLines = 8;
+ popup.renderer.$keepTextAreaAtCursor = false;
+
+ popup.setHighlightActiveLine(false);
+ popup.session.highlight("");
+ popup.session.$searchHighlight.clazz = "ace_highlight-marker";
+
+ popup.on("mousedown", function(e) {
+ var pos = e.getDocumentPosition();
+ popup.selection.moveToPosition(pos);
+ selectionMarker.start.row = selectionMarker.end.row = pos.row;
+ e.stop();
+ });
+
+ var lastMouseEvent;
+ var hoverMarker = new Range(-1,0,-1,Infinity);
+ var selectionMarker = new Range(-1,0,-1,Infinity);
+ selectionMarker.id = popup.session.addMarker(selectionMarker, "ace_active-line", "fullLine");
+ popup.setSelectOnHover = function(val) {
+ if (!val) {
+ hoverMarker.id = popup.session.addMarker(hoverMarker, "ace_line-hover", "fullLine");
+ } else if (hoverMarker.id) {
+ popup.session.removeMarker(hoverMarker.id);
+ hoverMarker.id = null;
+ }
+ };
+ popup.setSelectOnHover(false);
+ popup.on("mousemove", function(e) {
+ if (!lastMouseEvent) {
+ lastMouseEvent = e;
+ return;
+ }
+ if (lastMouseEvent.x == e.x && lastMouseEvent.y == e.y) {
+ return;
+ }
+ lastMouseEvent = e;
+ lastMouseEvent.scrollTop = popup.renderer.scrollTop;
+ var row = lastMouseEvent.getDocumentPosition().row;
+ if (hoverMarker.start.row != row) {
+ if (!hoverMarker.id)
+ popup.setRow(row);
+ setHoverMarker(row);
+ }
+ });
+ popup.renderer.on("beforeRender", function() {
+ if (lastMouseEvent && hoverMarker.start.row != -1) {
+ lastMouseEvent.$pos = null;
+ var row = lastMouseEvent.getDocumentPosition().row;
+ if (!hoverMarker.id)
+ popup.setRow(row);
+ setHoverMarker(row, true);
+ }
+ });
+ popup.renderer.on("afterRender", function() {
+ var row = popup.getRow();
+ var t = popup.renderer.$textLayer;
+ var selected = t.element.childNodes[row - t.config.firstRow];
+ if (selected == t.selectedNode)
+ return;
+ if (t.selectedNode)
+ dom.removeCssClass(t.selectedNode, "ace_selected");
+ t.selectedNode = selected;
+ if (selected)
+ dom.addCssClass(selected, "ace_selected");
+ });
+ var hideHoverMarker = function() { setHoverMarker(-1) };
+ var setHoverMarker = function(row, suppressRedraw) {
+ if (row !== hoverMarker.start.row) {
+ hoverMarker.start.row = hoverMarker.end.row = row;
+ if (!suppressRedraw)
+ popup.session._emit("changeBackMarker");
+ popup._emit("changeHoverMarker");
+ }
+ };
+ popup.getHoveredRow = function() {
+ return hoverMarker.start.row;
+ };
+
+ event.addListener(popup.container, "mouseout", hideHoverMarker);
+ popup.on("hide", hideHoverMarker);
+ popup.on("changeSelection", hideHoverMarker);
+
+ popup.session.doc.getLength = function() {
+ return popup.data.length;
+ };
+ popup.session.doc.getLine = function(i) {
+ var data = popup.data[i];
+ if (typeof data == "string")
+ return data;
+ return (data && data.value) || "";
+ };
+
+ var bgTokenizer = popup.session.bgTokenizer;
+ bgTokenizer.$tokenizeRow = function(row) {
+ var data = popup.data[row];
+ var tokens = [];
+ if (!data)
+ return tokens;
+ if (typeof data == "string")
+ data = {value: data};
+ if (!data.caption)
+ data.caption = data.value || data.name;
+
+ var last = -1;
+ var flag, c;
+ for (var i = 0; i < data.caption.length; i++) {
+ c = data.caption[i];
+ flag = data.matchMask & (1 << i) ? 1 : 0;
+ if (last !== flag) {
+ tokens.push({type: data.className || "" + ( flag ? "completion-highlight" : ""), value: c});
+ last = flag;
+ } else {
+ tokens[tokens.length - 1].value += c;
+ }
+ }
+
+ if (data.meta) {
+ var maxW = popup.renderer.$size.scrollerWidth / popup.renderer.layerConfig.characterWidth;
+ var metaData = data.meta;
+ if (metaData.length + data.caption.length > maxW - 2) {
+ metaData = metaData.substr(0, maxW - data.caption.length - 3) + "\u2026"
+ }
+ tokens.push({type: "rightAlignedText", value: metaData});
+ }
+ return tokens;
+ };
+ bgTokenizer.$updateOnChange = noop;
+ bgTokenizer.start = noop;
+
+ popup.session.$computeWidth = function() {
+ return this.screenWidth = 0;
+ };
+
+ popup.$blockScrolling = Infinity;
+ popup.isOpen = false;
+ popup.isTopdown = false;
+ popup.autoSelect = true;
+
+ popup.data = [];
+ popup.setData = function(list) {
+ popup.setValue(lang.stringRepeat("\n", list.length), -1);
+ popup.data = list || [];
+ popup.setRow(0);
+ };
+ popup.getData = function(row) {
+ return popup.data[row];
+ };
+
+ popup.getRow = function() {
+ return selectionMarker.start.row;
+ };
+ popup.setRow = function(line) {
+ line = Math.max(this.autoSelect ? 0 : -1, Math.min(this.data.length, line));
+ if (selectionMarker.start.row != line) {
+ popup.selection.clearSelection();
+ selectionMarker.start.row = selectionMarker.end.row = line || 0;
+ popup.session._emit("changeBackMarker");
+ popup.moveCursorTo(line || 0, 0);
+ if (popup.isOpen)
+ popup._signal("select");
+ }
+ };
+
+ popup.on("changeSelection", function() {
+ if (popup.isOpen)
+ popup.setRow(popup.selection.lead.row);
+ popup.renderer.scrollCursorIntoView();
+ });
+
+ popup.hide = function() {
+ this.container.style.display = "none";
+ this._signal("hide");
+ popup.isOpen = false;
+ };
+ popup.show = function(pos, lineHeight, topdownOnly) {
+ var el = this.container;
+ var screenHeight = window.innerHeight;
+ var screenWidth = window.innerWidth;
+ var renderer = this.renderer;
+ var maxH = renderer.$maxLines * lineHeight * 1.4;
+ var top = pos.top + this.$borderSize;
+ var allowTopdown = top > screenHeight / 2 && !topdownOnly;
+ if (allowTopdown && top + lineHeight + maxH > screenHeight) {
+ renderer.$maxPixelHeight = top - 2 * this.$borderSize;
+ el.style.top = "";
+ el.style.bottom = screenHeight - top + "px";
+ popup.isTopdown = false;
+ } else {
+ top += lineHeight;
+ renderer.$maxPixelHeight = screenHeight - top - 0.2 * lineHeight;
+ el.style.top = top + "px";
+ el.style.bottom = "";
+ popup.isTopdown = true;
+ }
+
+ el.style.display = "";
+ this.renderer.$textLayer.checkForSizeChanges();
+
+ var left = pos.left;
+ if (left + el.offsetWidth > screenWidth)
+ left = screenWidth - el.offsetWidth;
+
+ el.style.left = left + "px";
+
+ this._signal("show");
+ lastMouseEvent = null;
+ popup.isOpen = true;
+ };
+
+ popup.getTextLeftOffset = function() {
+ return this.$borderSize + this.renderer.$padding + this.$imageSize;
+ };
+
+ popup.$imageSize = 0;
+ popup.$borderSize = 1;
+
+ return popup;
+};
+
+dom.importCssString("\
+.ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line {\
+ background-color: #CAD6FA;\
+ z-index: 1;\
+}\
+.ace_editor.ace_autocomplete .ace_line-hover {\
+ border: 1px solid #abbffe;\
+ margin-top: -1px;\
+ background: rgba(233,233,253,0.4);\
+}\
+.ace_editor.ace_autocomplete .ace_line-hover {\
+ position: absolute;\
+ z-index: 2;\
+}\
+.ace_editor.ace_autocomplete .ace_scroller {\
+ background: none;\
+ border: none;\
+ box-shadow: none;\
+}\
+.ace_rightAlignedText {\
+ color: gray;\
+ display: inline-block;\
+ position: absolute;\
+ right: 4px;\
+ text-align: right;\
+ z-index: -1;\
+}\
+.ace_editor.ace_autocomplete .ace_completion-highlight{\
+ color: #000;\
+ text-shadow: 0 0 0.01em;\
+}\
+.ace_editor.ace_autocomplete {\
+ width: 280px;\
+ z-index: 200000;\
+ background: #fbfbfb;\
+ color: #444;\
+ border: 1px lightgray solid;\
+ position: fixed;\
+ box-shadow: 2px 3px 5px rgba(0,0,0,.2);\
+ line-height: 1.4;\
+}");
+
+exports.AcePopup = AcePopup;
+
+});
+
+ace.define("ace/autocomplete/util",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.parForEach = function(array, fn, callback) {
+ var completed = 0;
+ var arLength = array.length;
+ if (arLength === 0)
+ callback();
+ for (var i = 0; i < arLength; i++) {
+ fn(array[i], function(result, err) {
+ completed++;
+ if (completed === arLength)
+ callback(result, err);
+ });
+ }
+};
+
+var ID_REGEX = /[a-zA-Z_0-9\$\-\u00A2-\uFFFF]/;
+
+exports.retrievePrecedingIdentifier = function(text, pos, regex) {
+ regex = regex || ID_REGEX;
+ var buf = [];
+ for (var i = pos-1; i >= 0; i--) {
+ if (regex.test(text[i]))
+ buf.push(text[i]);
+ else
+ break;
+ }
+ return buf.reverse().join("");
+};
+
+exports.retrieveFollowingIdentifier = function(text, pos, regex) {
+ regex = regex || ID_REGEX;
+ var buf = [];
+ for (var i = pos; i < text.length; i++) {
+ if (regex.test(text[i]))
+ buf.push(text[i]);
+ else
+ break;
+ }
+ return buf;
+};
+
+exports.getCompletionPrefix = function (editor) {
+ var pos = editor.getCursorPosition();
+ var line = editor.session.getLine(pos.row);
+ var prefix;
+ editor.completers.forEach(function(completer) {
+ if (completer.identifierRegexps) {
+ completer.identifierRegexps.forEach(function(identifierRegex) {
+ if (!prefix && identifierRegex)
+ prefix = this.retrievePrecedingIdentifier(line, pos.column, identifierRegex);
+ }.bind(this));
+ }
+ }.bind(this));
+ return prefix || this.retrievePrecedingIdentifier(line, pos.column);
+};
+
+});
+
+ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/event","ace/lib/lang","ace/lib/dom","ace/snippets"], function(require, exports, module) {
+"use strict";
+
+var HashHandler = require("./keyboard/hash_handler").HashHandler;
+var AcePopup = require("./autocomplete/popup").AcePopup;
+var util = require("./autocomplete/util");
+var event = require("./lib/event");
+var lang = require("./lib/lang");
+var dom = require("./lib/dom");
+var snippetManager = require("./snippets").snippetManager;
+
+var Autocomplete = function() {
+ this.autoInsert = false;
+ this.autoSelect = true;
+ this.exactMatch = false;
+ this.gatherCompletionsId = 0;
+ this.keyboardHandler = new HashHandler();
+ this.keyboardHandler.bindKeys(this.commands);
+
+ this.blurListener = this.blurListener.bind(this);
+ this.changeListener = this.changeListener.bind(this);
+ this.mousedownListener = this.mousedownListener.bind(this);
+ this.mousewheelListener = this.mousewheelListener.bind(this);
+
+ this.changeTimer = lang.delayedCall(function() {
+ this.updateCompletions(true);
+ }.bind(this));
+
+ this.tooltipTimer = lang.delayedCall(this.updateDocTooltip.bind(this), 50);
+};
+
+(function() {
+
+ this.$init = function() {
+ this.popup = new AcePopup(document.body || document.documentElement);
+ this.popup.on("click", function(e) {
+ this.insertMatch();
+ e.stop();
+ }.bind(this));
+ this.popup.focus = this.editor.focus.bind(this.editor);
+ this.popup.on("show", this.tooltipTimer.bind(null, null));
+ this.popup.on("select", this.tooltipTimer.bind(null, null));
+ this.popup.on("changeHoverMarker", this.tooltipTimer.bind(null, null));
+ return this.popup;
+ };
+
+ this.getPopup = function() {
+ return this.popup || this.$init();
+ };
+
+ this.openPopup = function(editor, prefix, keepPopupPosition) {
+ if (!this.popup)
+ this.$init();
+
+ this.popup.autoSelect = this.autoSelect;
+
+ this.popup.setData(this.completions.filtered);
+
+ editor.keyBinding.addKeyboardHandler(this.keyboardHandler);
+
+ var renderer = editor.renderer;
+ this.popup.setRow(this.autoSelect ? 0 : -1);
+ if (!keepPopupPosition) {
+ this.popup.setTheme(editor.getTheme());
+ this.popup.setFontSize(editor.getFontSize());
+
+ var lineHeight = renderer.layerConfig.lineHeight;
+
+ var pos = renderer.$cursorLayer.getPixelPosition(this.base, true);
+ pos.left -= this.popup.getTextLeftOffset();
+
+ var rect = editor.container.getBoundingClientRect();
+ pos.top += rect.top - renderer.layerConfig.offset;
+ pos.left += rect.left - editor.renderer.scrollLeft;
+ pos.left += renderer.gutterWidth;
+
+ this.popup.show(pos, lineHeight);
+ } else if (keepPopupPosition && !prefix) {
+ this.detach();
+ }
+ };
+
+ this.detach = function() {
+ this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler);
+ this.editor.off("changeSelection", this.changeListener);
+ this.editor.off("blur", this.blurListener);
+ this.editor.off("mousedown", this.mousedownListener);
+ this.editor.off("mousewheel", this.mousewheelListener);
+ this.changeTimer.cancel();
+ this.hideDocTooltip();
+
+ this.gatherCompletionsId += 1;
+ if (this.popup && this.popup.isOpen)
+ this.popup.hide();
+
+ if (this.base)
+ this.base.detach();
+ this.activated = false;
+ this.completions = this.base = null;
+ };
+
+ this.changeListener = function(e) {
+ var cursor = this.editor.selection.lead;
+ if (cursor.row != this.base.row || cursor.column < this.base.column) {
+ this.detach();
+ }
+ if (this.activated)
+ this.changeTimer.schedule();
+ else
+ this.detach();
+ };
+
+ this.blurListener = function(e) {
+ var el = document.activeElement;
+ var text = this.editor.textInput.getElement();
+ var fromTooltip = e.relatedTarget && this.tooltipNode && this.tooltipNode.contains(e.relatedTarget);
+ var container = this.popup && this.popup.container;
+ if (el != text && el.parentNode != container && !fromTooltip
+ && el != this.tooltipNode && e.relatedTarget != text
+ ) {
+ this.detach();
+ }
+ };
+
+ this.mousedownListener = function(e) {
+ this.detach();
+ };
+
+ this.mousewheelListener = function(e) {
+ this.detach();
+ };
+
+ this.goTo = function(where) {
+ var row = this.popup.getRow();
+ var max = this.popup.session.getLength() - 1;
+
+ switch(where) {
+ case "up": row = row <= 0 ? max : row - 1; break;
+ case "down": row = row >= max ? -1 : row + 1; break;
+ case "start": row = 0; break;
+ case "end": row = max; break;
+ }
+
+ this.popup.setRow(row);
+ };
+
+ this.insertMatch = function(data, options) {
+ if (!data)
+ data = this.popup.getData(this.popup.getRow());
+ if (!data)
+ return false;
+
+ if (data.completer && data.completer.insertMatch) {
+ data.completer.insertMatch(this.editor, data);
+ } else {
+ if (this.completions.filterText) {
+ var ranges = this.editor.selection.getAllRanges();
+ for (var i = 0, range; range = ranges[i]; i++) {
+ range.start.column -= this.completions.filterText.length;
+ this.editor.session.remove(range);
+ }
+ }
+ if (data.snippet)
+ snippetManager.insertSnippet(this.editor, data.snippet);
+ else
+ this.editor.execCommand("insertstring", data.value || data);
+ }
+ this.detach();
+ };
+
+
+ this.commands = {
+ "Up": function(editor) { editor.completer.goTo("up"); },
+ "Down": function(editor) { editor.completer.goTo("down"); },
+ "Ctrl-Up|Ctrl-Home": function(editor) { editor.completer.goTo("start"); },
+ "Ctrl-Down|Ctrl-End": function(editor) { editor.completer.goTo("end"); },
+
+ "Esc": function(editor) { editor.completer.detach(); },
+ "Return": function(editor) { return editor.completer.insertMatch(); },
+ "Shift-Return": function(editor) { editor.completer.insertMatch(null, {deleteSuffix: true}); },
+ "Tab": function(editor) {
+ var result = editor.completer.insertMatch();
+ if (!result && !editor.tabstopManager)
+ editor.completer.goTo("down");
+ else
+ return result;
+ },
+
+ "PageUp": function(editor) { editor.completer.popup.gotoPageUp(); },
+ "PageDown": function(editor) { editor.completer.popup.gotoPageDown(); }
+ };
+
+ this.gatherCompletions = function(editor, callback) {
+ var session = editor.getSession();
+ var pos = editor.getCursorPosition();
+
+ var prefix = util.getCompletionPrefix(editor);
+
+ this.base = session.doc.createAnchor(pos.row, pos.column - prefix.length);
+ this.base.$insertRight = true;
+
+ var matches = [];
+ var total = editor.completers.length;
+ editor.completers.forEach(function(completer, i) {
+ completer.getCompletions(editor, session, pos, prefix, function(err, results) {
+ if (!err && results)
+ matches = matches.concat(results);
+ callback(null, {
+ prefix: util.getCompletionPrefix(editor),
+ matches: matches,
+ finished: (--total === 0)
+ });
+ });
+ });
+ return true;
+ };
+
+ this.showPopup = function(editor) {
+ if (this.editor)
+ this.detach();
+
+ this.activated = true;
+
+ this.editor = editor;
+ if (editor.completer != this) {
+ if (editor.completer)
+ editor.completer.detach();
+ editor.completer = this;
+ }
+
+ editor.on("changeSelection", this.changeListener);
+ editor.on("blur", this.blurListener);
+ editor.on("mousedown", this.mousedownListener);
+ editor.on("mousewheel", this.mousewheelListener);
+
+ this.updateCompletions();
+ };
+
+ this.updateCompletions = function(keepPopupPosition) {
+ if (keepPopupPosition && this.base && this.completions) {
+ var pos = this.editor.getCursorPosition();
+ var prefix = this.editor.session.getTextRange({start: this.base, end: pos});
+ if (prefix == this.completions.filterText)
+ return;
+ this.completions.setFilter(prefix);
+ if (!this.completions.filtered.length)
+ return this.detach();
+ if (this.completions.filtered.length == 1
+ && this.completions.filtered[0].value == prefix
+ && !this.completions.filtered[0].snippet)
+ return this.detach();
+ this.openPopup(this.editor, prefix, keepPopupPosition);
+ return;
+ }
+ var _id = this.gatherCompletionsId;
+ this.gatherCompletions(this.editor, function(err, results) {
+ var detachIfFinished = function() {
+ if (!results.finished) return;
+ return this.detach();
+ }.bind(this);
+
+ var prefix = results.prefix;
+ var matches = results && results.matches;
+
+ if (!matches || !matches.length)
+ return detachIfFinished();
+ if (prefix.indexOf(results.prefix) !== 0 || _id != this.gatherCompletionsId)
+ return;
+
+ this.completions = new FilteredList(matches);
+
+ if (this.exactMatch)
+ this.completions.exactMatch = true;
+
+ this.completions.setFilter(prefix);
+ var filtered = this.completions.filtered;
+ if (!filtered.length)
+ return detachIfFinished();
+ if (filtered.length == 1 && filtered[0].value == prefix && !filtered[0].snippet)
+ return detachIfFinished();
+ if (this.autoInsert && filtered.length == 1 && results.finished)
+ return this.insertMatch(filtered[0]);
+
+ this.openPopup(this.editor, prefix, keepPopupPosition);
+ }.bind(this));
+ };
+
+ this.cancelContextMenu = function() {
+ this.editor.$mouseHandler.cancelContextMenu();
+ };
+
+ this.updateDocTooltip = function() {
+ var popup = this.popup;
+ var all = popup.data;
+ var selected = all && (all[popup.getHoveredRow()] || all[popup.getRow()]);
+ var doc = null;
+ if (!selected || !this.editor || !this.popup.isOpen)
+ return this.hideDocTooltip();
+ this.editor.completers.some(function(completer) {
+ if (completer.getDocTooltip)
+ doc = completer.getDocTooltip(selected);
+ return doc;
+ });
+ if (!doc)
+ doc = selected;
+
+ if (typeof doc == "string")
+ doc = {docText: doc};
+ if (!doc || !(doc.docHTML || doc.docText))
+ return this.hideDocTooltip();
+ this.showDocTooltip(doc);
+ };
+
+ this.showDocTooltip = function(item) {
+ if (!this.tooltipNode) {
+ this.tooltipNode = dom.createElement("div");
+ this.tooltipNode.className = "ace_tooltip ace_doc-tooltip";
+ this.tooltipNode.style.margin = 0;
+ this.tooltipNode.style.pointerEvents = "auto";
+ this.tooltipNode.tabIndex = -1;
+ this.tooltipNode.onblur = this.blurListener.bind(this);
+ this.tooltipNode.onclick = this.onTooltipClick.bind(this);
+ }
+
+ var tooltipNode = this.tooltipNode;
+ if (item.docHTML) {
+ tooltipNode.innerHTML = item.docHTML;
+ } else if (item.docText) {
+ tooltipNode.textContent = item.docText;
+ }
+
+ if (!tooltipNode.parentNode)
+ document.body.appendChild(tooltipNode);
+ var popup = this.popup;
+ var rect = popup.container.getBoundingClientRect();
+ tooltipNode.style.top = popup.container.style.top;
+ tooltipNode.style.bottom = popup.container.style.bottom;
+
+ if (window.innerWidth - rect.right < 320) {
+ tooltipNode.style.right = window.innerWidth - rect.left + "px";
+ tooltipNode.style.left = "";
+ } else {
+ tooltipNode.style.left = (rect.right + 1) + "px";
+ tooltipNode.style.right = "";
+ }
+ tooltipNode.style.display = "block";
+ };
+
+ this.hideDocTooltip = function() {
+ this.tooltipTimer.cancel();
+ if (!this.tooltipNode) return;
+ var el = this.tooltipNode;
+ if (!this.editor.isFocused() && document.activeElement == el)
+ this.editor.focus();
+ this.tooltipNode = null;
+ if (el.parentNode)
+ el.parentNode.removeChild(el);
+ };
+
+ this.onTooltipClick = function(e) {
+ var a = e.target;
+ while (a && a != this.tooltipNode) {
+ if (a.nodeName == "A" && a.href) {
+ a.rel = "noreferrer";
+ a.target = "_blank";
+ break;
+ }
+ a = a.parentNode;
+ }
+ }
+
+}).call(Autocomplete.prototype);
+
+Autocomplete.startCommand = {
+ name: "startAutocomplete",
+ exec: function(editor) {
+ if (!editor.completer)
+ editor.completer = new Autocomplete();
+ editor.completer.autoInsert = false;
+ editor.completer.autoSelect = true;
+ editor.completer.showPopup(editor);
+ editor.completer.cancelContextMenu();
+ },
+ bindKey: "Ctrl-Space|Ctrl-Shift-Space|Alt-Space"
+};
+
+var FilteredList = function(array, filterText) {
+ this.all = array;
+ this.filtered = array;
+ this.filterText = filterText || "";
+ this.exactMatch = false;
+};
+(function(){
+ this.setFilter = function(str) {
+ if (str.length > this.filterText && str.lastIndexOf(this.filterText, 0) === 0)
+ var matches = this.filtered;
+ else
+ var matches = this.all;
+
+ this.filterText = str;
+ matches = this.filterCompletions(matches, this.filterText);
+ matches = matches.sort(function(a, b) {
+ return b.exactMatch - a.exactMatch || b.score - a.score;
+ });
+ var prev = null;
+ matches = matches.filter(function(item){
+ var caption = item.snippet || item.caption || item.value;
+ if (caption === prev) return false;
+ prev = caption;
+ return true;
+ });
+
+ this.filtered = matches;
+ };
+ this.filterCompletions = function(items, needle) {
+ var results = [];
+ var upper = needle.toUpperCase();
+ var lower = needle.toLowerCase();
+ loop: for (var i = 0, item; item = items[i]; i++) {
+ var caption = item.value || item.caption || item.snippet;
+ if (!caption) continue;
+ var lastIndex = -1;
+ var matchMask = 0;
+ var penalty = 0;
+ var index, distance;
+
+ if (this.exactMatch) {
+ if (needle !== caption.substr(0, needle.length))
+ continue loop;
+ }else{
+ for (var j = 0; j < needle.length; j++) {
+ var i1 = caption.indexOf(lower[j], lastIndex + 1);
+ var i2 = caption.indexOf(upper[j], lastIndex + 1);
+ index = (i1 >= 0) ? ((i2 < 0 || i1 < i2) ? i1 : i2) : i2;
+ if (index < 0)
+ continue loop;
+ distance = index - lastIndex - 1;
+ if (distance > 0) {
+ if (lastIndex === -1)
+ penalty += 10;
+ penalty += distance;
+ }
+ matchMask = matchMask | (1 << index);
+ lastIndex = index;
+ }
+ }
+ item.matchMask = matchMask;
+ item.exactMatch = penalty ? 0 : 1;
+ item.score = (item.score || 0) - penalty;
+ results.push(item);
+ }
+ return results;
+ };
+}).call(FilteredList.prototype);
+
+exports.Autocomplete = Autocomplete;
+exports.FilteredList = FilteredList;
+
+});
+
+ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"], function(require, exports, module) {
+ var Range = require("../range").Range;
+
+ var splitRegex = /[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;
+
+ function getWordIndex(doc, pos) {
+ var textBefore = doc.getTextRange(Range.fromPoints({row: 0, column:0}, pos));
+ return textBefore.split(splitRegex).length - 1;
+ }
+ function wordDistance(doc, pos) {
+ var prefixPos = getWordIndex(doc, pos);
+ var words = doc.getValue().split(splitRegex);
+ var wordScores = Object.create(null);
+
+ var currentWord = words[prefixPos];
+
+ words.forEach(function(word, idx) {
+ if (!word || word === currentWord) return;
+
+ var distance = Math.abs(prefixPos - idx);
+ var score = words.length - distance;
+ if (wordScores[word]) {
+ wordScores[word] = Math.max(score, wordScores[word]);
+ } else {
+ wordScores[word] = score;
+ }
+ });
+ return wordScores;
+ }
+
+ exports.getCompletions = function(editor, session, pos, prefix, callback) {
+ var wordScore = wordDistance(session, pos, prefix);
+ var wordList = Object.keys(wordScore);
+ callback(null, wordList.map(function(word) {
+ return {
+ caption: word,
+ value: word,
+ score: wordScore[word],
+ meta: "local"
+ };
+ }));
+ };
+});
+
+ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/lib/lang","ace/autocomplete/util","ace/autocomplete/text_completer","ace/editor","ace/config"], function(require, exports, module) {
+"use strict";
+
+var snippetManager = require("../snippets").snippetManager;
+var Autocomplete = require("../autocomplete").Autocomplete;
+var config = require("../config");
+var lang = require("../lib/lang");
+var util = require("../autocomplete/util");
+
+var textCompleter = require("../autocomplete/text_completer");
+var keyWordCompleter = {
+ getCompletions: function(editor, session, pos, prefix, callback) {
+ if (session.$mode.completer) {
+ return session.$mode.completer.getCompletions(editor, session, pos, prefix, callback);
+ }
+ var state = editor.session.getState(pos.row);
+ var completions = session.$mode.getCompletions(state, session, pos, prefix);
+ callback(null, completions);
+ }
+};
+
+var snippetCompleter = {
+ getCompletions: function(editor, session, pos, prefix, callback) {
+ var snippetMap = snippetManager.snippetMap;
+ var completions = [];
+ snippetManager.getActiveScopes(editor).forEach(function(scope) {
+ var snippets = snippetMap[scope] || [];
+ for (var i = snippets.length; i--;) {
+ var s = snippets[i];
+ var caption = s.name || s.tabTrigger;
+ if (!caption)
+ continue;
+ completions.push({
+ caption: caption,
+ snippet: s.content,
+ meta: s.tabTrigger && !s.name ? s.tabTrigger + "\u21E5 " : "snippet",
+ type: "snippet"
+ });
+ }
+ }, this);
+ callback(null, completions);
+ },
+ getDocTooltip: function(item) {
+ if (item.type == "snippet" && !item.docHTML) {
+ item.docHTML = [
+ "<b>", lang.escapeHTML(item.caption), "</b>", "<hr></hr>",
+ lang.escapeHTML(item.snippet)
+ ].join("");
+ }
+ }
+};
+
+var completers = [snippetCompleter, textCompleter, keyWordCompleter];
+exports.setCompleters = function(val) {
+ completers.length = 0;
+ if (val) completers.push.apply(completers, val);
+};
+exports.addCompleter = function(completer) {
+ completers.push(completer);
+};
+exports.textCompleter = textCompleter;
+exports.keyWordCompleter = keyWordCompleter;
+exports.snippetCompleter = snippetCompleter;
+
+var expandSnippet = {
+ name: "expandSnippet",
+ exec: function(editor) {
+ return snippetManager.expandWithTab(editor);
+ },
+ bindKey: "Tab"
+};
+
+var onChangeMode = function(e, editor) {
+ loadSnippetsForMode(editor.session.$mode);
+};
+
+var loadSnippetsForMode = function(mode) {
+ var id = mode.$id;
+ if (!snippetManager.files)
+ snippetManager.files = {};
+ loadSnippetFile(id);
+ if (mode.modes)
+ mode.modes.forEach(loadSnippetsForMode);
+};
+
+var loadSnippetFile = function(id) {
+ if (!id || snippetManager.files[id])
+ return;
+ var snippetFilePath = id.replace("mode", "snippets");
+ snippetManager.files[id] = {};
+ config.loadModule(snippetFilePath, function(m) {
+ if (m) {
+ snippetManager.files[id] = m;
+ if (!m.snippets && m.snippetText)
+ m.snippets = snippetManager.parseSnippetFile(m.snippetText);
+ snippetManager.register(m.snippets || [], m.scope);
+ if (m.includeScopes) {
+ snippetManager.snippetMap[m.scope].includeScopes = m.includeScopes;
+ m.includeScopes.forEach(function(x) {
+ loadSnippetFile("ace/mode/" + x);
+ });
+ }
+ }
+ });
+};
+
+var doLiveAutocomplete = function(e) {
+ var editor = e.editor;
+ var hasCompleter = editor.completer && editor.completer.activated;
+ if (e.command.name === "backspace") {
+ if (hasCompleter && !util.getCompletionPrefix(editor))
+ editor.completer.detach();
+ }
+ else if (e.command.name === "insertstring") {
+ var prefix = util.getCompletionPrefix(editor);
+ if (prefix && !hasCompleter) {
+ if (!editor.completer) {
+ editor.completer = new Autocomplete();
+ }
+ editor.completer.autoInsert = false;
+ editor.completer.showPopup(editor);
+ }
+ }
+};
+
+var Editor = require("../editor").Editor;
+require("../config").defineOptions(Editor.prototype, "editor", {
+ enableBasicAutocompletion: {
+ set: function(val) {
+ if (val) {
+ if (!this.completers)
+ this.completers = Array.isArray(val)? val: completers;
+ this.commands.addCommand(Autocomplete.startCommand);
+ } else {
+ this.commands.removeCommand(Autocomplete.startCommand);
+ }
+ },
+ value: false
+ },
+ enableLiveAutocompletion: {
+ set: function(val) {
+ if (val) {
+ if (!this.completers)
+ this.completers = Array.isArray(val)? val: completers;
+ this.commands.on('afterExec', doLiveAutocomplete);
+ } else {
+ this.commands.removeListener('afterExec', doLiveAutocomplete);
+ }
+ },
+ value: false
+ },
+ enableSnippets: {
+ set: function(val) {
+ if (val) {
+ this.commands.addCommand(expandSnippet);
+ this.on("changeMode", onChangeMode);
+ onChangeMode(null, this);
+ } else {
+ this.commands.removeCommand(expandSnippet);
+ this.off("changeMode", onChangeMode);
+ }
+ },
+ value: false
+ }
+});
+});
+ (function() {
+ ace.require(["ace/ext/language_tools"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-linking.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-linking.js
new file mode 100644
index 00000000..baa75702
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-linking.js
@@ -0,0 +1,61 @@
+ace.define("ace/ext/linking",["require","exports","module","ace/editor","ace/config"], function(require, exports, module) {
+
+var Editor = require("ace/editor").Editor;
+
+require("../config").defineOptions(Editor.prototype, "editor", {
+ enableLinking: {
+ set: function(val) {
+ if (val) {
+ this.on("click", onClick);
+ this.on("mousemove", onMouseMove);
+ } else {
+ this.off("click", onClick);
+ this.off("mousemove", onMouseMove);
+ }
+ },
+ value: false
+ }
+})
+
+exports.previousLinkingHover = false;
+
+function onMouseMove(e) {
+ var editor = e.editor;
+ var ctrl = e.getAccelKey();
+
+ if (ctrl) {
+ var editor = e.editor;
+ var docPos = e.getDocumentPosition();
+ var session = editor.session;
+ var token = session.getTokenAt(docPos.row, docPos.column);
+
+ if (exports.previousLinkingHover && exports.previousLinkingHover != token) {
+ editor._emit("linkHoverOut");
+ }
+ editor._emit("linkHover", {position: docPos, token: token});
+ exports.previousLinkingHover = token;
+ } else if (exports.previousLinkingHover) {
+ editor._emit("linkHoverOut");
+ exports.previousLinkingHover = false;
+ }
+}
+
+function onClick(e) {
+ var ctrl = e.getAccelKey();
+ var button = e.getButton();
+
+ if (button == 0 && ctrl) {
+ var editor = e.editor;
+ var docPos = e.getDocumentPosition();
+ var session = editor.session;
+ var token = session.getTokenAt(docPos.row, docPos.column);
+
+ editor._emit("linkClick", {position: docPos, token: token});
+ }
+}
+
+});
+ (function() {
+ ace.require(["ace/ext/linking"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-modelist.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-modelist.js
new file mode 100644
index 00000000..b0c7fd0d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-modelist.js
@@ -0,0 +1,209 @@
+ace.define("ace/ext/modelist",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var modes = [];
+function getModeForPath(path) {
+ var mode = modesByName.text;
+ var fileName = path.split(/[\/\\]/).pop();
+ for (var i = 0; i < modes.length; i++) {
+ if (modes[i].supportsFile(fileName)) {
+ mode = modes[i];
+ break;
+ }
+ }
+ return mode;
+}
+
+var Mode = function(name, caption, extensions) {
+ this.name = name;
+ this.caption = caption;
+ this.mode = "ace/mode/" + name;
+ this.extensions = extensions;
+ var re;
+ if (/\^/.test(extensions)) {
+ re = extensions.replace(/\|(\^)?/g, function(a, b){
+ return "$|" + (b ? "^" : "^.*\\.");
+ }) + "$";
+ } else {
+ re = "^.*\\.(" + extensions + ")$";
+ }
+
+ this.extRe = new RegExp(re, "gi");
+};
+
+Mode.prototype.supportsFile = function(filename) {
+ return filename.match(this.extRe);
+};
+var supportedModes = {
+ ABAP: ["abap"],
+ ABC: ["abc"],
+ ActionScript:["as"],
+ ADA: ["ada|adb"],
+ Apache_Conf: ["^htaccess|^htgroups|^htpasswd|^conf|htaccess|htgroups|htpasswd"],
+ AsciiDoc: ["asciidoc|adoc"],
+ Assembly_x86:["asm|a"],
+ AutoHotKey: ["ahk"],
+ BatchFile: ["bat|cmd"],
+ Bro: ["bro"],
+ C_Cpp: ["cpp|c|cc|cxx|h|hh|hpp|ino"],
+ C9Search: ["c9search_results"],
+ Cirru: ["cirru|cr"],
+ Clojure: ["clj|cljs"],
+ Cobol: ["CBL|COB"],
+ coffee: ["coffee|cf|cson|^Cakefile"],
+ ColdFusion: ["cfm"],
+ CSharp: ["cs"],
+ CSS: ["css"],
+ Curly: ["curly"],
+ D: ["d|di"],
+ Dart: ["dart"],
+ Diff: ["diff|patch"],
+ Dockerfile: ["^Dockerfile"],
+ Dot: ["dot"],
+ Drools: ["drl"],
+ Dummy: ["dummy"],
+ DummySyntax: ["dummy"],
+ Eiffel: ["e|ge"],
+ EJS: ["ejs"],
+ Elixir: ["ex|exs"],
+ Elm: ["elm"],
+ Erlang: ["erl|hrl"],
+ Forth: ["frt|fs|ldr|fth|4th"],
+ Fortran: ["f|f90"],
+ FTL: ["ftl"],
+ Gcode: ["gcode"],
+ Gherkin: ["feature"],
+ Gitignore: ["^.gitignore"],
+ Glsl: ["glsl|frag|vert"],
+ Gobstones: ["gbs"],
+ golang: ["go"],
+ GraphQLSchema: ["gql"],
+ Groovy: ["groovy"],
+ HAML: ["haml"],
+ Handlebars: ["hbs|handlebars|tpl|mustache"],
+ Haskell: ["hs"],
+ Haskell_Cabal: ["cabal"],
+ haXe: ["hx"],
+ Hjson: ["hjson"],
+ HTML: ["html|htm|xhtml"],
+ HTML_Elixir: ["eex|html.eex"],
+ HTML_Ruby: ["erb|rhtml|html.erb"],
+ INI: ["ini|conf|cfg|prefs"],
+ Io: ["io"],
+ Jack: ["jack"],
+ Jade: ["jade|pug"],
+ Java: ["java"],
+ JavaScript: ["js|jsm|jsx"],
+ JSON: ["json"],
+ JSONiq: ["jq"],
+ JSP: ["jsp"],
+ JSX: ["jsx"],
+ Julia: ["jl"],
+ Kotlin: ["kt|kts"],
+ LaTeX: ["tex|latex|ltx|bib"],
+ LESS: ["less"],
+ Liquid: ["liquid"],
+ Lisp: ["lisp"],
+ LiveScript: ["ls"],
+ LogiQL: ["logic|lql"],
+ LSL: ["lsl"],
+ Lua: ["lua"],
+ LuaPage: ["lp"],
+ Lucene: ["lucene"],
+ Makefile: ["^Makefile|^GNUmakefile|^makefile|^OCamlMakefile|make"],
+ Markdown: ["md|markdown"],
+ Mask: ["mask"],
+ MATLAB: ["matlab"],
+ Maze: ["mz"],
+ MEL: ["mel"],
+ MUSHCode: ["mc|mush"],
+ MySQL: ["mysql"],
+ Nix: ["nix"],
+ NSIS: ["nsi|nsh"],
+ ObjectiveC: ["m|mm"],
+ OCaml: ["ml|mli"],
+ Pascal: ["pas|p"],
+ Perl: ["pl|pm"],
+ pgSQL: ["pgsql"],
+ PHP: ["php|phtml|shtml|php3|php4|php5|phps|phpt|aw|ctp|module"],
+ Pig: ["pig"],
+ Powershell: ["ps1"],
+ Praat: ["praat|praatscript|psc|proc"],
+ Prolog: ["plg|prolog"],
+ Properties: ["properties"],
+ Protobuf: ["proto"],
+ Python: ["py"],
+ R: ["r"],
+ Razor: ["cshtml|asp"],
+ RDoc: ["Rd"],
+ RHTML: ["Rhtml"],
+ RST: ["rst"],
+ Ruby: ["rb|ru|gemspec|rake|^Guardfile|^Rakefile|^Gemfile"],
+ Rust: ["rs"],
+ SASS: ["sass"],
+ SCAD: ["scad"],
+ Scala: ["scala"],
+ Scheme: ["scm|sm|rkt|oak|scheme"],
+ SCSS: ["scss"],
+ SH: ["sh|bash|^.bashrc"],
+ SJS: ["sjs"],
+ Smarty: ["smarty|tpl"],
+ snippets: ["snippets"],
+ Soy_Template:["soy"],
+ Space: ["space"],
+ SQL: ["sql"],
+ SQLServer: ["sqlserver"],
+ Stylus: ["styl|stylus"],
+ SVG: ["svg"],
+ Swift: ["swift"],
+ Tcl: ["tcl"],
+ Tex: ["tex"],
+ Text: ["txt"],
+ Textile: ["textile"],
+ Toml: ["toml"],
+ TSX: ["tsx"],
+ Twig: ["twig|swig"],
+ Typescript: ["ts|typescript|str"],
+ Vala: ["vala"],
+ VBScript: ["vbs|vb"],
+ Velocity: ["vm"],
+ Verilog: ["v|vh|sv|svh"],
+ VHDL: ["vhd|vhdl"],
+ Wollok: ["wlk|wpgm|wtest"],
+ XML: ["xml|rdf|rss|wsdl|xslt|atom|mathml|mml|xul|xbl|xaml"],
+ XQuery: ["xq"],
+ YAML: ["yaml|yml"],
+ Django: ["html"]
+};
+
+var nameOverrides = {
+ ObjectiveC: "Objective-C",
+ CSharp: "C#",
+ golang: "Go",
+ C_Cpp: "C and C++",
+ coffee: "CoffeeScript",
+ HTML_Ruby: "HTML (Ruby)",
+ HTML_Elixir: "HTML (Elixir)",
+ FTL: "FreeMarker"
+};
+var modesByName = {};
+for (var name in supportedModes) {
+ var data = supportedModes[name];
+ var displayName = (nameOverrides[name] || name).replace(/_/g, " ");
+ var filename = name.toLowerCase();
+ var mode = new Mode(filename, displayName, data[0]);
+ modesByName[filename] = mode;
+ modes.push(mode);
+}
+
+module.exports = {
+ getModeForPath: getModeForPath,
+ modes: modes,
+ modesByName: modesByName
+};
+
+});
+ (function() {
+ ace.require(["ace/ext/modelist"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-searchbox.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-searchbox.js
new file mode 100644
index 00000000..41eabb15
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-searchbox.js
@@ -0,0 +1,508 @@
+ace.define("ace/ext/searchbox",["require","exports","module","ace/lib/dom","ace/lib/lang","ace/lib/event","ace/keyboard/hash_handler","ace/lib/keys"], function(require, exports, module) {
+"use strict";
+
+var dom = require("../lib/dom");
+var lang = require("../lib/lang");
+var event = require("../lib/event");
+var searchboxCss = "\
+.ace_search {\
+background-color: #ddd;\
+color: #666;\
+border: 1px solid #cbcbcb;\
+border-top: 0 none;\
+overflow: hidden;\
+margin: 0;\
+padding: 4px 6px 0 4px;\
+position: absolute;\
+top: 0;\
+z-index: 99;\
+white-space: normal;\
+}\
+.ace_search.left {\
+border-left: 0 none;\
+border-radius: 0px 0px 5px 0px;\
+left: 0;\
+}\
+.ace_search.right {\
+border-radius: 0px 0px 0px 5px;\
+border-right: 0 none;\
+right: 0;\
+}\
+.ace_search_form, .ace_replace_form {\
+margin: 0 20px 4px 0;\
+overflow: hidden;\
+line-height: 1.9;\
+}\
+.ace_replace_form {\
+margin-right: 0;\
+}\
+.ace_search_form.ace_nomatch {\
+outline: 1px solid red;\
+}\
+.ace_search_field {\
+border-radius: 3px 0 0 3px;\
+background-color: white;\
+color: black;\
+border: 1px solid #cbcbcb;\
+border-right: 0 none;\
+box-sizing: border-box!important;\
+outline: 0;\
+padding: 0;\
+font-size: inherit;\
+margin: 0;\
+line-height: inherit;\
+padding: 0 6px;\
+min-width: 17em;\
+vertical-align: top;\
+}\
+.ace_searchbtn {\
+border: 1px solid #cbcbcb;\
+line-height: inherit;\
+display: inline-block;\
+padding: 0 6px;\
+background: #fff;\
+border-right: 0 none;\
+border-left: 1px solid #dcdcdc;\
+cursor: pointer;\
+margin: 0;\
+position: relative;\
+box-sizing: content-box!important;\
+color: #666;\
+}\
+.ace_searchbtn:last-child {\
+border-radius: 0 3px 3px 0;\
+border-right: 1px solid #cbcbcb;\
+}\
+.ace_searchbtn:disabled {\
+background: none;\
+cursor: default;\
+}\
+.ace_searchbtn:hover {\
+background-color: #eef1f6;\
+}\
+.ace_searchbtn.prev, .ace_searchbtn.next {\
+padding: 0px 0.7em\
+}\
+.ace_searchbtn.prev:after, .ace_searchbtn.next:after {\
+content: \"\";\
+border: solid 2px #888;\
+width: 0.5em;\
+height: 0.5em;\
+border-width: 2px 0 0 2px;\
+display:inline-block;\
+transform: rotate(-45deg);\
+}\
+.ace_searchbtn.next:after {\
+border-width: 0 2px 2px 0 ;\
+}\
+.ace_searchbtn_close {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAcCAYAAABRVo5BAAAAZ0lEQVR42u2SUQrAMAhDvazn8OjZBilCkYVVxiis8H4CT0VrAJb4WHT3C5xU2a2IQZXJjiQIRMdkEoJ5Q2yMqpfDIo+XY4k6h+YXOyKqTIj5REaxloNAd0xiKmAtsTHqW8sR2W5f7gCu5nWFUpVjZwAAAABJRU5ErkJggg==) no-repeat 50% 0;\
+border-radius: 50%;\
+border: 0 none;\
+color: #656565;\
+cursor: pointer;\
+font: 16px/16px Arial;\
+padding: 0;\
+height: 14px;\
+width: 14px;\
+top: 9px;\
+right: 7px;\
+position: absolute;\
+}\
+.ace_searchbtn_close:hover {\
+background-color: #656565;\
+background-position: 50% 100%;\
+color: white;\
+}\
+.ace_button {\
+margin-left: 2px;\
+cursor: pointer;\
+-webkit-user-select: none;\
+-moz-user-select: none;\
+-o-user-select: none;\
+-ms-user-select: none;\
+user-select: none;\
+overflow: hidden;\
+opacity: 0.7;\
+border: 1px solid rgba(100,100,100,0.23);\
+padding: 1px;\
+box-sizing: border-box!important;\
+color: black;\
+}\
+.ace_button:hover {\
+background-color: #eee;\
+opacity:1;\
+}\
+.ace_button:active {\
+background-color: #ddd;\
+}\
+.ace_button.checked {\
+border-color: #3399ff;\
+opacity:1;\
+}\
+.ace_search_options{\
+margin-bottom: 3px;\
+text-align: right;\
+-webkit-user-select: none;\
+-moz-user-select: none;\
+-o-user-select: none;\
+-ms-user-select: none;\
+user-select: none;\
+clear: both;\
+}\
+.ace_search_counter {\
+float: left;\
+font-family: arial;\
+padding: 0 8px;\
+}";
+var HashHandler = require("../keyboard/hash_handler").HashHandler;
+var keyUtil = require("../lib/keys");
+
+var MAX_COUNT = 999;
+
+dom.importCssString(searchboxCss, "ace_searchbox");
+
+var html = '<div class="ace_search right">\
+ <span action="hide" class="ace_searchbtn_close"></span>\
+ <div class="ace_search_form">\
+ <input class="ace_search_field" placeholder="Search for" spellcheck="false"></input>\
+ <span action="findPrev" class="ace_searchbtn prev"></span>\
+ <span action="findNext" class="ace_searchbtn next"></span>\
+ <span action="findAll" class="ace_searchbtn" title="Alt-Enter">All</span>\
+ </div>\
+ <div class="ace_replace_form">\
+ <input class="ace_search_field" placeholder="Replace with" spellcheck="false"></input>\
+ <span action="replaceAndFindNext" class="ace_searchbtn">Replace</span>\
+ <span action="replaceAll" class="ace_searchbtn">All</span>\
+ </div>\
+ <div class="ace_search_options">\
+ <span action="toggleReplace" class="ace_button" title="Toggel Replace mode"\
+ style="float:left;margin-top:-2px;padding:0 5px;">+</span>\
+ <span class="ace_search_counter"></span>\
+ <span action="toggleRegexpMode" class="ace_button" title="RegExp Search">.*</span>\
+ <span action="toggleCaseSensitive" class="ace_button" title="CaseSensitive Search">Aa</span>\
+ <span action="toggleWholeWords" class="ace_button" title="Whole Word Search">\\b</span>\
+ <span action="searchInSelection" class="ace_button" title="Search In Selection">S</span>\
+ </div>\
+</div>'.replace(/> +/g, ">");
+
+var SearchBox = function(editor, range, showReplaceForm) {
+ var div = dom.createElement("div");
+ div.innerHTML = html;
+ this.element = div.firstChild;
+
+ this.setSession = this.setSession.bind(this);
+
+ this.$init();
+ this.setEditor(editor);
+};
+
+(function() {
+ this.setEditor = function(editor) {
+ editor.searchBox = this;
+ editor.renderer.scroller.appendChild(this.element);
+ this.editor = editor;
+ };
+
+ this.setSession = function(e) {
+ this.searchRange = null;
+ this.$syncOptions(true);
+ }
+
+ this.$initElements = function(sb) {
+ this.searchBox = sb.querySelector(".ace_search_form");
+ this.replaceBox = sb.querySelector(".ace_replace_form");
+ this.searchOption = sb.querySelector("[action=searchInSelection]");
+ this.replaceOption = sb.querySelector("[action=toggleReplace]");
+ this.regExpOption = sb.querySelector("[action=toggleRegexpMode]");
+ this.caseSensitiveOption = sb.querySelector("[action=toggleCaseSensitive]");
+ this.wholeWordOption = sb.querySelector("[action=toggleWholeWords]");
+ this.searchInput = this.searchBox.querySelector(".ace_search_field");
+ this.replaceInput = this.replaceBox.querySelector(".ace_search_field");
+ this.searchCounter = sb.querySelector(".ace_search_counter");
+ };
+
+ this.$init = function() {
+ var sb = this.element;
+
+ this.$initElements(sb);
+
+ var _this = this;
+ event.addListener(sb, "mousedown", function(e) {
+ setTimeout(function(){
+ _this.activeInput.focus();
+ }, 0);
+ event.stopPropagation(e);
+ });
+ event.addListener(sb, "click", function(e) {
+ var t = e.target || e.srcElement;
+ var action = t.getAttribute("action");
+ if (action && _this[action])
+ _this[action]();
+ else if (_this.$searchBarKb.commands[action])
+ _this.$searchBarKb.commands[action].exec(_this);
+ event.stopPropagation(e);
+ });
+
+ event.addCommandKeyListener(sb, function(e, hashId, keyCode) {
+ var keyString = keyUtil.keyCodeToString(keyCode);
+ var command = _this.$searchBarKb.findKeyCommand(hashId, keyString);
+ if (command && command.exec) {
+ command.exec(_this);
+ event.stopEvent(e);
+ }
+ });
+
+ this.$onChange = lang.delayedCall(function() {
+ _this.find(false, false);
+ });
+
+ event.addListener(this.searchInput, "input", function() {
+ _this.$onChange.schedule(20);
+ });
+ event.addListener(this.searchInput, "focus", function() {
+ _this.activeInput = _this.searchInput;
+ _this.searchInput.value && _this.highlight();
+ });
+ event.addListener(this.replaceInput, "focus", function() {
+ _this.activeInput = _this.replaceInput;
+ _this.searchInput.value && _this.highlight();
+ });
+ };
+ this.$closeSearchBarKb = new HashHandler([{
+ bindKey: "Esc",
+ name: "closeSearchBar",
+ exec: function(editor) {
+ editor.searchBox.hide();
+ }
+ }]);
+ this.$searchBarKb = new HashHandler();
+ this.$searchBarKb.bindKeys({
+ "Ctrl-f|Command-f": function(sb) {
+ var isReplace = sb.isReplace = !sb.isReplace;
+ sb.replaceBox.style.display = isReplace ? "" : "none";
+ sb.replaceOption.checked = false;
+ sb.$syncOptions();
+ sb.searchInput.focus();
+ },
+ "Ctrl-H|Command-Option-F": function(sb) {
+ sb.replaceOption.checked = true;
+ sb.$syncOptions();
+ sb.replaceInput.focus();
+ },
+ "Ctrl-G|Command-G": function(sb) {
+ sb.findNext();
+ },
+ "Ctrl-Shift-G|Command-Shift-G": function(sb) {
+ sb.findPrev();
+ },
+ "esc": function(sb) {
+ setTimeout(function() { sb.hide();});
+ },
+ "Return": function(sb) {
+ if (sb.activeInput == sb.replaceInput)
+ sb.replace();
+ sb.findNext();
+ },
+ "Shift-Return": function(sb) {
+ if (sb.activeInput == sb.replaceInput)
+ sb.replace();
+ sb.findPrev();
+ },
+ "Alt-Return": function(sb) {
+ if (sb.activeInput == sb.replaceInput)
+ sb.replaceAll();
+ sb.findAll();
+ },
+ "Tab": function(sb) {
+ (sb.activeInput == sb.replaceInput ? sb.searchInput : sb.replaceInput).focus();
+ }
+ });
+
+ this.$searchBarKb.addCommands([{
+ name: "toggleRegexpMode",
+ bindKey: {win: "Alt-R|Alt-/", mac: "Ctrl-Alt-R|Ctrl-Alt-/"},
+ exec: function(sb) {
+ sb.regExpOption.checked = !sb.regExpOption.checked;
+ sb.$syncOptions();
+ }
+ }, {
+ name: "toggleCaseSensitive",
+ bindKey: {win: "Alt-C|Alt-I", mac: "Ctrl-Alt-R|Ctrl-Alt-I"},
+ exec: function(sb) {
+ sb.caseSensitiveOption.checked = !sb.caseSensitiveOption.checked;
+ sb.$syncOptions();
+ }
+ }, {
+ name: "toggleWholeWords",
+ bindKey: {win: "Alt-B|Alt-W", mac: "Ctrl-Alt-B|Ctrl-Alt-W"},
+ exec: function(sb) {
+ sb.wholeWordOption.checked = !sb.wholeWordOption.checked;
+ sb.$syncOptions();
+ }
+ }, {
+ name: "toggleReplace",
+ exec: function(sb) {
+ sb.replaceOption.checked = !sb.replaceOption.checked;
+ sb.$syncOptions();
+ }
+ }, {
+ name: "searchInSelection",
+ exec: function(sb) {
+ sb.searchOption.checked = !sb.searchRange;
+ sb.setSearchRange(sb.searchOption.checked && sb.editor.getSelectionRange());
+ sb.$syncOptions();
+ }
+ }]);
+
+ this.setSearchRange = function(range) {
+ this.searchRange = range;
+ if (range) {
+ this.searchRangeMarker = this.editor.session.addMarker(range, "ace_active-line");
+ } else if (this.searchRangeMarker) {
+ this.editor.session.removeMarker(this.searchRangeMarker);
+ this.searchRangeMarker = null;
+ }
+ }
+
+ this.$syncOptions = function(preventScroll) {
+ dom.setCssClass(this.replaceOption, "checked", this.searchRange);
+ dom.setCssClass(this.searchOption, "checked", this.searchOption.checked);
+ this.replaceOption.textContent = this.replaceOption.checked ? "-" : "+";
+ dom.setCssClass(this.regExpOption, "checked", this.regExpOption.checked);
+ dom.setCssClass(this.wholeWordOption, "checked", this.wholeWordOption.checked);
+ dom.setCssClass(this.caseSensitiveOption, "checked", this.caseSensitiveOption.checked);
+ this.replaceBox.style.display = this.replaceOption.checked ? "" : "none";
+ this.find(false, false, preventScroll);
+ };
+
+ this.highlight = function(re) {
+ this.editor.session.highlight(re || this.editor.$search.$options.re);
+ this.editor.renderer.updateBackMarkers()
+ };
+ this.find = function(skipCurrent, backwards, preventScroll) {
+ var range = this.editor.find(this.searchInput.value, {
+ skipCurrent: skipCurrent,
+ backwards: backwards,
+ wrap: true,
+ regExp: this.regExpOption.checked,
+ caseSensitive: this.caseSensitiveOption.checked,
+ wholeWord: this.wholeWordOption.checked,
+ preventScroll: preventScroll,
+ range: this.searchRange
+ });
+ var noMatch = !range && this.searchInput.value;
+ dom.setCssClass(this.searchBox, "ace_nomatch", noMatch);
+ this.editor._emit("findSearchBox", { match: !noMatch });
+ this.highlight();
+ this.updateCounter();
+ };
+ this.updateCounter = function() {
+ var editor = this.editor;
+ var regex = editor.$search.$options.re;
+ var all = 0;
+ var before = 0
+ if (regex) {
+ var value = this.searchRange
+ ? editor.session.getTextRange(this.searchRange)
+ : editor.getValue();
+
+ var offset = editor.session.doc.positionToIndex(editor.selection.anchor);
+ if (this.searchRange)
+ offset -= editor.session.doc.positionToIndex(this.searchRange.start);
+
+ var last = regex.lastIndex = 0;
+ var m;
+ while ((m = regex.exec(value))) {
+ all++;
+ last = m.index;
+ if (last <= offset)
+ before++;
+ if (all > MAX_COUNT)
+ break
+ if (!m[0]) {
+ regex.lastIndex = last += 1;
+ if (last >= value.length)
+ break;
+ }
+ }
+ }
+ this.searchCounter.textContent = before + " of " + (all > MAX_COUNT ? MAX_COUNT + "+" : all);
+ };
+ this.findNext = function() {
+ this.find(true, false);
+ };
+ this.findPrev = function() {
+ this.find(true, true);
+ };
+ this.findAll = function(){
+ var range = this.editor.findAll(this.searchInput.value, {
+ regExp: this.regExpOption.checked,
+ caseSensitive: this.caseSensitiveOption.checked,
+ wholeWord: this.wholeWordOption.checked
+ });
+ var noMatch = !range && this.searchInput.value;
+ dom.setCssClass(this.searchBox, "ace_nomatch", noMatch);
+ this.editor._emit("findSearchBox", { match: !noMatch });
+ this.highlight();
+ this.hide();
+ };
+ this.replace = function() {
+ if (!this.editor.getReadOnly())
+ this.editor.replace(this.replaceInput.value);
+ };
+ this.replaceAndFindNext = function() {
+ if (!this.editor.getReadOnly()) {
+ this.editor.replace(this.replaceInput.value);
+ this.findNext()
+ }
+ };
+ this.replaceAll = function() {
+ if (!this.editor.getReadOnly())
+ this.editor.replaceAll(this.replaceInput.value);
+ };
+
+ this.hide = function() {
+ this.active = false;
+ this.setSearchRange(null)
+ this.editor.off("changeSession", this.setSession);
+
+ this.element.style.display = "none";
+ this.editor.keyBinding.removeKeyboardHandler(this.$closeSearchBarKb);
+ this.editor.focus();
+ };
+ this.show = function(value, isReplace) {
+ this.active = true;
+ this.editor.on("changeSession", this.setSession);
+ this.element.style.display = "";
+ this.replaceOption.checked = isReplace;
+
+ if (value)
+ this.searchInput.value = value;
+
+ this.searchInput.focus();
+ this.searchInput.select();
+
+ this.editor.keyBinding.addKeyboardHandler(this.$closeSearchBarKb);
+
+ this.$syncOptions(true);
+ };
+
+ this.isFocused = function() {
+ var el = document.activeElement;
+ return el == this.searchInput || el == this.replaceInput;
+ }
+}).call(SearchBox.prototype);
+
+exports.SearchBox = SearchBox;
+
+exports.Search = function(editor, isReplace) {
+ var sb = editor.searchBox || new SearchBox(editor);
+ sb.show(editor.session.getTextRange(), isReplace);
+};
+
+});
+ (function() {
+ ace.require(["ace/ext/searchbox"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-settings_menu.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-settings_menu.js
new file mode 100644
index 00000000..a00b28f8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-settings_menu.js
@@ -0,0 +1,663 @@
+ace.define("ace/ext/menu_tools/element_generator",["require","exports","module"], function(require, exports, module) {
+'use strict';
+module.exports.createOption = function createOption (obj) {
+ var attribute;
+ var el = document.createElement('option');
+ for(attribute in obj) {
+ if(obj.hasOwnProperty(attribute)) {
+ if(attribute === 'selected') {
+ el.setAttribute(attribute, obj[attribute]);
+ } else {
+ el[attribute] = obj[attribute];
+ }
+ }
+ }
+ return el;
+};
+module.exports.createCheckbox = function createCheckbox (id, checked, clss) {
+ var el = document.createElement('input');
+ el.setAttribute('type', 'checkbox');
+ el.setAttribute('id', id);
+ el.setAttribute('name', id);
+ el.setAttribute('value', checked);
+ el.setAttribute('class', clss);
+ if(checked) {
+ el.setAttribute('checked', 'checked');
+ }
+ return el;
+};
+module.exports.createInput = function createInput (id, value, clss) {
+ var el = document.createElement('input');
+ el.setAttribute('type', 'text');
+ el.setAttribute('id', id);
+ el.setAttribute('name', id);
+ el.setAttribute('value', value);
+ el.setAttribute('class', clss);
+ return el;
+};
+module.exports.createLabel = function createLabel (text, labelFor) {
+ var el = document.createElement('label');
+ el.setAttribute('for', labelFor);
+ el.textContent = text;
+ return el;
+};
+module.exports.createSelection = function createSelection (id, values, clss) {
+ var el = document.createElement('select');
+ el.setAttribute('id', id);
+ el.setAttribute('name', id);
+ el.setAttribute('class', clss);
+ values.forEach(function(item) {
+ el.appendChild(module.exports.createOption(item));
+ });
+ return el;
+};
+
+});
+
+ace.define("ace/ext/modelist",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var modes = [];
+function getModeForPath(path) {
+ var mode = modesByName.text;
+ var fileName = path.split(/[\/\\]/).pop();
+ for (var i = 0; i < modes.length; i++) {
+ if (modes[i].supportsFile(fileName)) {
+ mode = modes[i];
+ break;
+ }
+ }
+ return mode;
+}
+
+var Mode = function(name, caption, extensions) {
+ this.name = name;
+ this.caption = caption;
+ this.mode = "ace/mode/" + name;
+ this.extensions = extensions;
+ var re;
+ if (/\^/.test(extensions)) {
+ re = extensions.replace(/\|(\^)?/g, function(a, b){
+ return "$|" + (b ? "^" : "^.*\\.");
+ }) + "$";
+ } else {
+ re = "^.*\\.(" + extensions + ")$";
+ }
+
+ this.extRe = new RegExp(re, "gi");
+};
+
+Mode.prototype.supportsFile = function(filename) {
+ return filename.match(this.extRe);
+};
+var supportedModes = {
+ ABAP: ["abap"],
+ ABC: ["abc"],
+ ActionScript:["as"],
+ ADA: ["ada|adb"],
+ Apache_Conf: ["^htaccess|^htgroups|^htpasswd|^conf|htaccess|htgroups|htpasswd"],
+ AsciiDoc: ["asciidoc|adoc"],
+ Assembly_x86:["asm|a"],
+ AutoHotKey: ["ahk"],
+ BatchFile: ["bat|cmd"],
+ Bro: ["bro"],
+ C_Cpp: ["cpp|c|cc|cxx|h|hh|hpp|ino"],
+ C9Search: ["c9search_results"],
+ Cirru: ["cirru|cr"],
+ Clojure: ["clj|cljs"],
+ Cobol: ["CBL|COB"],
+ coffee: ["coffee|cf|cson|^Cakefile"],
+ ColdFusion: ["cfm"],
+ CSharp: ["cs"],
+ CSS: ["css"],
+ Curly: ["curly"],
+ D: ["d|di"],
+ Dart: ["dart"],
+ Diff: ["diff|patch"],
+ Dockerfile: ["^Dockerfile"],
+ Dot: ["dot"],
+ Drools: ["drl"],
+ Dummy: ["dummy"],
+ DummySyntax: ["dummy"],
+ Eiffel: ["e|ge"],
+ EJS: ["ejs"],
+ Elixir: ["ex|exs"],
+ Elm: ["elm"],
+ Erlang: ["erl|hrl"],
+ Forth: ["frt|fs|ldr|fth|4th"],
+ Fortran: ["f|f90"],
+ FTL: ["ftl"],
+ Gcode: ["gcode"],
+ Gherkin: ["feature"],
+ Gitignore: ["^.gitignore"],
+ Glsl: ["glsl|frag|vert"],
+ Gobstones: ["gbs"],
+ golang: ["go"],
+ GraphQLSchema: ["gql"],
+ Groovy: ["groovy"],
+ HAML: ["haml"],
+ Handlebars: ["hbs|handlebars|tpl|mustache"],
+ Haskell: ["hs"],
+ Haskell_Cabal: ["cabal"],
+ haXe: ["hx"],
+ Hjson: ["hjson"],
+ HTML: ["html|htm|xhtml"],
+ HTML_Elixir: ["eex|html.eex"],
+ HTML_Ruby: ["erb|rhtml|html.erb"],
+ INI: ["ini|conf|cfg|prefs"],
+ Io: ["io"],
+ Jack: ["jack"],
+ Jade: ["jade|pug"],
+ Java: ["java"],
+ JavaScript: ["js|jsm|jsx"],
+ JSON: ["json"],
+ JSONiq: ["jq"],
+ JSP: ["jsp"],
+ JSX: ["jsx"],
+ Julia: ["jl"],
+ Kotlin: ["kt|kts"],
+ LaTeX: ["tex|latex|ltx|bib"],
+ LESS: ["less"],
+ Liquid: ["liquid"],
+ Lisp: ["lisp"],
+ LiveScript: ["ls"],
+ LogiQL: ["logic|lql"],
+ LSL: ["lsl"],
+ Lua: ["lua"],
+ LuaPage: ["lp"],
+ Lucene: ["lucene"],
+ Makefile: ["^Makefile|^GNUmakefile|^makefile|^OCamlMakefile|make"],
+ Markdown: ["md|markdown"],
+ Mask: ["mask"],
+ MATLAB: ["matlab"],
+ Maze: ["mz"],
+ MEL: ["mel"],
+ MUSHCode: ["mc|mush"],
+ MySQL: ["mysql"],
+ Nix: ["nix"],
+ NSIS: ["nsi|nsh"],
+ ObjectiveC: ["m|mm"],
+ OCaml: ["ml|mli"],
+ Pascal: ["pas|p"],
+ Perl: ["pl|pm"],
+ pgSQL: ["pgsql"],
+ PHP: ["php|phtml|shtml|php3|php4|php5|phps|phpt|aw|ctp|module"],
+ Pig: ["pig"],
+ Powershell: ["ps1"],
+ Praat: ["praat|praatscript|psc|proc"],
+ Prolog: ["plg|prolog"],
+ Properties: ["properties"],
+ Protobuf: ["proto"],
+ Python: ["py"],
+ R: ["r"],
+ Razor: ["cshtml|asp"],
+ RDoc: ["Rd"],
+ RHTML: ["Rhtml"],
+ RST: ["rst"],
+ Ruby: ["rb|ru|gemspec|rake|^Guardfile|^Rakefile|^Gemfile"],
+ Rust: ["rs"],
+ SASS: ["sass"],
+ SCAD: ["scad"],
+ Scala: ["scala"],
+ Scheme: ["scm|sm|rkt|oak|scheme"],
+ SCSS: ["scss"],
+ SH: ["sh|bash|^.bashrc"],
+ SJS: ["sjs"],
+ Smarty: ["smarty|tpl"],
+ snippets: ["snippets"],
+ Soy_Template:["soy"],
+ Space: ["space"],
+ SQL: ["sql"],
+ SQLServer: ["sqlserver"],
+ Stylus: ["styl|stylus"],
+ SVG: ["svg"],
+ Swift: ["swift"],
+ Tcl: ["tcl"],
+ Tex: ["tex"],
+ Text: ["txt"],
+ Textile: ["textile"],
+ Toml: ["toml"],
+ TSX: ["tsx"],
+ Twig: ["twig|swig"],
+ Typescript: ["ts|typescript|str"],
+ Vala: ["vala"],
+ VBScript: ["vbs|vb"],
+ Velocity: ["vm"],
+ Verilog: ["v|vh|sv|svh"],
+ VHDL: ["vhd|vhdl"],
+ Wollok: ["wlk|wpgm|wtest"],
+ XML: ["xml|rdf|rss|wsdl|xslt|atom|mathml|mml|xul|xbl|xaml"],
+ XQuery: ["xq"],
+ YAML: ["yaml|yml"],
+ Django: ["html"]
+};
+
+var nameOverrides = {
+ ObjectiveC: "Objective-C",
+ CSharp: "C#",
+ golang: "Go",
+ C_Cpp: "C and C++",
+ coffee: "CoffeeScript",
+ HTML_Ruby: "HTML (Ruby)",
+ HTML_Elixir: "HTML (Elixir)",
+ FTL: "FreeMarker"
+};
+var modesByName = {};
+for (var name in supportedModes) {
+ var data = supportedModes[name];
+ var displayName = (nameOverrides[name] || name).replace(/_/g, " ");
+ var filename = name.toLowerCase();
+ var mode = new Mode(filename, displayName, data[0]);
+ modesByName[filename] = mode;
+ modes.push(mode);
+}
+
+module.exports = {
+ getModeForPath: getModeForPath,
+ modes: modes,
+ modesByName: modesByName
+};
+
+});
+
+ace.define("ace/ext/themelist",["require","exports","module","ace/lib/fixoldbrowsers"], function(require, exports, module) {
+"use strict";
+require("ace/lib/fixoldbrowsers");
+
+var themeData = [
+ ["Chrome" ],
+ ["Clouds" ],
+ ["Crimson Editor" ],
+ ["Dawn" ],
+ ["Dreamweaver" ],
+ ["Eclipse" ],
+ ["GitHub" ],
+ ["IPlastic" ],
+ ["Solarized Light"],
+ ["TextMate" ],
+ ["Tomorrow" ],
+ ["XCode" ],
+ ["Kuroir"],
+ ["KatzenMilch"],
+ ["SQL Server" ,"sqlserver" , "light"],
+ ["Ambiance" ,"ambiance" , "dark"],
+ ["Chaos" ,"chaos" , "dark"],
+ ["Clouds Midnight" ,"clouds_midnight" , "dark"],
+ ["Cobalt" ,"cobalt" , "dark"],
+ ["Gruvbox" ,"gruvbox" , "dark"],
+ ["Green on Black" ,"gob" , "dark"],
+ ["idle Fingers" ,"idle_fingers" , "dark"],
+ ["krTheme" ,"kr_theme" , "dark"],
+ ["Merbivore" ,"merbivore" , "dark"],
+ ["Merbivore Soft" ,"merbivore_soft" , "dark"],
+ ["Mono Industrial" ,"mono_industrial" , "dark"],
+ ["Monokai" ,"monokai" , "dark"],
+ ["Pastel on dark" ,"pastel_on_dark" , "dark"],
+ ["Solarized Dark" ,"solarized_dark" , "dark"],
+ ["Terminal" ,"terminal" , "dark"],
+ ["Tomorrow Night" ,"tomorrow_night" , "dark"],
+ ["Tomorrow Night Blue" ,"tomorrow_night_blue" , "dark"],
+ ["Tomorrow Night Bright","tomorrow_night_bright" , "dark"],
+ ["Tomorrow Night 80s" ,"tomorrow_night_eighties" , "dark"],
+ ["Twilight" ,"twilight" , "dark"],
+ ["Vibrant Ink" ,"vibrant_ink" , "dark"]
+];
+
+
+exports.themesByName = {};
+exports.themes = themeData.map(function(data) {
+ var name = data[1] || data[0].replace(/ /g, "_").toLowerCase();
+ var theme = {
+ caption: data[0],
+ theme: "ace/theme/" + name,
+ isDark: data[2] == "dark",
+ name: name
+ };
+ exports.themesByName[name] = theme;
+ return theme;
+});
+
+});
+
+ace.define("ace/ext/menu_tools/add_editor_menu_options",["require","exports","module","ace/ext/modelist","ace/ext/themelist"], function(require, exports, module) {
+'use strict';
+module.exports.addEditorMenuOptions = function addEditorMenuOptions (editor) {
+ var modelist = require('../modelist');
+ var themelist = require('../themelist');
+ editor.menuOptions = {
+ setNewLineMode: [{
+ textContent: "unix",
+ value: "unix"
+ }, {
+ textContent: "windows",
+ value: "windows"
+ }, {
+ textContent: "auto",
+ value: "auto"
+ }],
+ setTheme: [],
+ setMode: [],
+ setKeyboardHandler: [{
+ textContent: "ace",
+ value: ""
+ }, {
+ textContent: "vim",
+ value: "ace/keyboard/vim"
+ }, {
+ textContent: "emacs",
+ value: "ace/keyboard/emacs"
+ }, {
+ textContent: "textarea",
+ value: "ace/keyboard/textarea"
+ }, {
+ textContent: "sublime",
+ value: "ace/keyboard/sublime"
+ }]
+ };
+
+ editor.menuOptions.setTheme = themelist.themes.map(function(theme) {
+ return {
+ textContent: theme.caption,
+ value: theme.theme
+ };
+ });
+
+ editor.menuOptions.setMode = modelist.modes.map(function(mode) {
+ return {
+ textContent: mode.name,
+ value: mode.mode
+ };
+ });
+};
+
+
+});
+
+ace.define("ace/ext/menu_tools/get_set_functions",["require","exports","module"], function(require, exports, module) {
+'use strict';
+module.exports.getSetFunctions = function getSetFunctions (editor) {
+ var out = [];
+ var my = {
+ 'editor' : editor,
+ 'session' : editor.session,
+ 'renderer' : editor.renderer
+ };
+ var opts = [];
+ var skip = [
+ 'setOption',
+ 'setUndoManager',
+ 'setDocument',
+ 'setValue',
+ 'setBreakpoints',
+ 'setScrollTop',
+ 'setScrollLeft',
+ 'setSelectionStyle',
+ 'setWrapLimitRange'
+ ];
+ ['renderer', 'session', 'editor'].forEach(function(esra) {
+ var esr = my[esra];
+ var clss = esra;
+ for(var fn in esr) {
+ if(skip.indexOf(fn) === -1) {
+ if(/^set/.test(fn) && opts.indexOf(fn) === -1) {
+ opts.push(fn);
+ out.push({
+ 'functionName' : fn,
+ 'parentObj' : esr,
+ 'parentName' : clss
+ });
+ }
+ }
+ }
+ });
+ return out;
+};
+
+});
+
+ace.define("ace/ext/menu_tools/generate_settings_menu",["require","exports","module","ace/ext/menu_tools/element_generator","ace/ext/menu_tools/add_editor_menu_options","ace/ext/menu_tools/get_set_functions","ace/ace"], function(require, exports, module) {
+'use strict';
+var egen = require('./element_generator');
+var addEditorMenuOptions = require('./add_editor_menu_options').addEditorMenuOptions;
+var getSetFunctions = require('./get_set_functions').getSetFunctions;
+module.exports.generateSettingsMenu = function generateSettingsMenu (editor) {
+ var elements = [];
+ function cleanupElementsList() {
+ elements.sort(function(a, b) {
+ var x = a.getAttribute('contains');
+ var y = b.getAttribute('contains');
+ return x.localeCompare(y);
+ });
+ }
+ function wrapElements() {
+ var topmenu = document.createElement('div');
+ topmenu.setAttribute('id', 'ace_settingsmenu');
+ elements.forEach(function(element) {
+ topmenu.appendChild(element);
+ });
+
+ var el = topmenu.appendChild(document.createElement('div'));
+ var version = require("../../ace").version;
+ el.style.padding = "1em";
+ el.textContent = "Ace version " + version;
+
+ return topmenu;
+ }
+ function createNewEntry(obj, clss, item, val) {
+ var el;
+ var div = document.createElement('div');
+ div.setAttribute('contains', item);
+ div.setAttribute('class', 'ace_optionsMenuEntry');
+ div.setAttribute('style', 'clear: both;');
+
+ div.appendChild(egen.createLabel(
+ item.replace(/^set/, '').replace(/([A-Z])/g, ' $1').trim(),
+ item
+ ));
+
+ if (Array.isArray(val)) {
+ el = egen.createSelection(item, val, clss);
+ el.addEventListener('change', function(e) {
+ try{
+ editor.menuOptions[e.target.id].forEach(function(x) {
+ if(x.textContent !== e.target.textContent) {
+ delete x.selected;
+ }
+ });
+ obj[e.target.id](e.target.value);
+ } catch (err) {
+ throw new Error(err);
+ }
+ });
+ } else if(typeof val === 'boolean') {
+ el = egen.createCheckbox(item, val, clss);
+ el.addEventListener('change', function(e) {
+ try{
+ obj[e.target.id](!!e.target.checked);
+ } catch (err) {
+ throw new Error(err);
+ }
+ });
+ } else {
+ el = egen.createInput(item, val, clss);
+ el.addEventListener('change', function(e) {
+ try{
+ if(e.target.value === 'true') {
+ obj[e.target.id](true);
+ } else if(e.target.value === 'false') {
+ obj[e.target.id](false);
+ } else {
+ obj[e.target.id](e.target.value);
+ }
+ } catch (err) {
+ throw new Error(err);
+ }
+ });
+ }
+ el.style.cssText = 'float:right;';
+ div.appendChild(el);
+ return div;
+ }
+ function makeDropdown(item, esr, clss, fn) {
+ var val = editor.menuOptions[item];
+ var currentVal = esr[fn]();
+ if (typeof currentVal == 'object')
+ currentVal = currentVal.$id;
+ val.forEach(function(valuex) {
+ if (valuex.value === currentVal)
+ valuex.selected = 'selected';
+ });
+ return createNewEntry(esr, clss, item, val);
+ }
+ function handleSet(setObj) {
+ var item = setObj.functionName;
+ var esr = setObj.parentObj;
+ var clss = setObj.parentName;
+ var val;
+ var fn = item.replace(/^set/, 'get');
+ if(editor.menuOptions[item] !== undefined) {
+ elements.push(makeDropdown(item, esr, clss, fn));
+ } else if(typeof esr[fn] === 'function') {
+ try {
+ val = esr[fn]();
+ if(typeof val === 'object') {
+ val = val.$id;
+ }
+ elements.push(
+ createNewEntry(esr, clss, item, val)
+ );
+ } catch (e) {
+ }
+ }
+ }
+ addEditorMenuOptions(editor);
+ getSetFunctions(editor).forEach(function(setObj) {
+ handleSet(setObj);
+ });
+ cleanupElementsList();
+ return wrapElements();
+};
+
+});
+
+ace.define("ace/ext/menu_tools/overlay_page",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+'use strict';
+var dom = require("../../lib/dom");
+var cssText = "#ace_settingsmenu, #kbshortcutmenu {\
+background-color: #F7F7F7;\
+color: black;\
+box-shadow: -5px 4px 5px rgba(126, 126, 126, 0.55);\
+padding: 1em 0.5em 2em 1em;\
+overflow: auto;\
+position: absolute;\
+margin: 0;\
+bottom: 0;\
+right: 0;\
+top: 0;\
+z-index: 9991;\
+cursor: default;\
+}\
+.ace_dark #ace_settingsmenu, .ace_dark #kbshortcutmenu {\
+box-shadow: -20px 10px 25px rgba(126, 126, 126, 0.25);\
+background-color: rgba(255, 255, 255, 0.6);\
+color: black;\
+}\
+.ace_optionsMenuEntry:hover {\
+background-color: rgba(100, 100, 100, 0.1);\
+-webkit-transition: all 0.5s;\
+transition: all 0.3s\
+}\
+.ace_closeButton {\
+background: rgba(245, 146, 146, 0.5);\
+border: 1px solid #F48A8A;\
+border-radius: 50%;\
+padding: 7px;\
+position: absolute;\
+right: -8px;\
+top: -8px;\
+z-index: 1000;\
+}\
+.ace_closeButton{\
+background: rgba(245, 146, 146, 0.9);\
+}\
+.ace_optionsMenuKey {\
+color: darkslateblue;\
+font-weight: bold;\
+}\
+.ace_optionsMenuCommand {\
+color: darkcyan;\
+font-weight: normal;\
+}";
+dom.importCssString(cssText);
+module.exports.overlayPage = function overlayPage(editor, contentElement, top, right, bottom, left) {
+ top = top ? 'top: ' + top + ';' : '';
+ bottom = bottom ? 'bottom: ' + bottom + ';' : '';
+ right = right ? 'right: ' + right + ';' : '';
+ left = left ? 'left: ' + left + ';' : '';
+
+ var closer = document.createElement('div');
+ var contentContainer = document.createElement('div');
+
+ function documentEscListener(e) {
+ if (e.keyCode === 27) {
+ closer.click();
+ }
+ }
+
+ closer.style.cssText = 'margin: 0; padding: 0; ' +
+ 'position: fixed; top:0; bottom:0; left:0; right:0;' +
+ 'z-index: 9990; ' +
+ 'background-color: rgba(0, 0, 0, 0.3);';
+ closer.addEventListener('click', function() {
+ document.removeEventListener('keydown', documentEscListener);
+ closer.parentNode.removeChild(closer);
+ editor.focus();
+ closer = null;
+ });
+ document.addEventListener('keydown', documentEscListener);
+
+ contentContainer.style.cssText = top + right + bottom + left;
+ contentContainer.addEventListener('click', function(e) {
+ e.stopPropagation();
+ });
+
+ var wrapper = dom.createElement("div");
+ wrapper.style.position = "relative";
+
+ var closeButton = dom.createElement("div");
+ closeButton.className = "ace_closeButton";
+ closeButton.addEventListener('click', function() {
+ closer.click();
+ });
+
+ wrapper.appendChild(closeButton);
+ contentContainer.appendChild(wrapper);
+
+ contentContainer.appendChild(contentElement);
+ closer.appendChild(contentContainer);
+ document.body.appendChild(closer);
+ editor.blur();
+};
+
+});
+
+ace.define("ace/ext/settings_menu",["require","exports","module","ace/ext/menu_tools/generate_settings_menu","ace/ext/menu_tools/overlay_page","ace/editor"], function(require, exports, module) {
+"use strict";
+var generateSettingsMenu = require('./menu_tools/generate_settings_menu').generateSettingsMenu;
+var overlayPage = require('./menu_tools/overlay_page').overlayPage;
+function showSettingsMenu(editor) {
+ var sm = document.getElementById('ace_settingsmenu');
+ if (!sm)
+ overlayPage(editor, generateSettingsMenu(editor), '0', '0', '0');
+}
+module.exports.init = function(editor) {
+ var Editor = require("ace/editor").Editor;
+ Editor.prototype.showSettingsMenu = function() {
+ showSettingsMenu(this);
+ };
+};
+});
+ (function() {
+ ace.require(["ace/ext/settings_menu"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-spellcheck.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-spellcheck.js
new file mode 100644
index 00000000..8d3b5f6c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-spellcheck.js
@@ -0,0 +1,71 @@
+ace.define("ace/ext/spellcheck",["require","exports","module","ace/lib/event","ace/editor","ace/config"], function(require, exports, module) {
+"use strict";
+var event = require("../lib/event");
+
+exports.contextMenuHandler = function(e){
+ var host = e.target;
+ var text = host.textInput.getElement();
+ if (!host.selection.isEmpty())
+ return;
+ var c = host.getCursorPosition();
+ var r = host.session.getWordRange(c.row, c.column);
+ var w = host.session.getTextRange(r);
+
+ host.session.tokenRe.lastIndex = 0;
+ if (!host.session.tokenRe.test(w))
+ return;
+ var PLACEHOLDER = "\x01\x01";
+ var value = w + " " + PLACEHOLDER;
+ text.value = value;
+ text.setSelectionRange(w.length, w.length + 1);
+ text.setSelectionRange(0, 0);
+ text.setSelectionRange(0, w.length);
+
+ var afterKeydown = false;
+ event.addListener(text, "keydown", function onKeydown() {
+ event.removeListener(text, "keydown", onKeydown);
+ afterKeydown = true;
+ });
+
+ host.textInput.setInputHandler(function(newVal) {
+ console.log(newVal , value, text.selectionStart, text.selectionEnd)
+ if (newVal == value)
+ return '';
+ if (newVal.lastIndexOf(value, 0) === 0)
+ return newVal.slice(value.length);
+ if (newVal.substr(text.selectionEnd) == value)
+ return newVal.slice(0, -value.length);
+ if (newVal.slice(-2) == PLACEHOLDER) {
+ var val = newVal.slice(0, -2);
+ if (val.slice(-1) == " ") {
+ if (afterKeydown)
+ return val.substring(0, text.selectionEnd);
+ val = val.slice(0, -1);
+ host.session.replace(r, val);
+ return "";
+ }
+ }
+
+ return newVal;
+ });
+};
+var Editor = require("../editor").Editor;
+require("../config").defineOptions(Editor.prototype, "editor", {
+ spellcheck: {
+ set: function(val) {
+ var text = this.textInput.getElement();
+ text.spellcheck = !!val;
+ if (!val)
+ this.removeListener("nativecontextmenu", exports.contextMenuHandler);
+ else
+ this.on("nativecontextmenu", exports.contextMenuHandler);
+ },
+ value: true
+ }
+});
+
+});
+ (function() {
+ ace.require(["ace/ext/spellcheck"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-split.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-split.js
new file mode 100644
index 00000000..29dd20ef
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-split.js
@@ -0,0 +1,246 @@
+ace.define("ace/split",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/editor","ace/virtual_renderer","ace/edit_session"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var lang = require("./lib/lang");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Editor = require("./editor").Editor;
+var Renderer = require("./virtual_renderer").VirtualRenderer;
+var EditSession = require("./edit_session").EditSession;
+
+
+var Split = function(container, theme, splits) {
+ this.BELOW = 1;
+ this.BESIDE = 0;
+
+ this.$container = container;
+ this.$theme = theme;
+ this.$splits = 0;
+ this.$editorCSS = "";
+ this.$editors = [];
+ this.$orientation = this.BESIDE;
+
+ this.setSplits(splits || 1);
+ this.$cEditor = this.$editors[0];
+
+
+ this.on("focus", function(editor) {
+ this.$cEditor = editor;
+ }.bind(this));
+};
+
+(function(){
+
+ oop.implement(this, EventEmitter);
+
+ this.$createEditor = function() {
+ var el = document.createElement("div");
+ el.className = this.$editorCSS;
+ el.style.cssText = "position: absolute; top:0px; bottom:0px";
+ this.$container.appendChild(el);
+ var editor = new Editor(new Renderer(el, this.$theme));
+
+ editor.on("focus", function() {
+ this._emit("focus", editor);
+ }.bind(this));
+
+ this.$editors.push(editor);
+ editor.setFontSize(this.$fontSize);
+ return editor;
+ };
+
+ this.setSplits = function(splits) {
+ var editor;
+ if (splits < 1) {
+ throw "The number of splits have to be > 0!";
+ }
+
+ if (splits == this.$splits) {
+ return;
+ } else if (splits > this.$splits) {
+ while (this.$splits < this.$editors.length && this.$splits < splits) {
+ editor = this.$editors[this.$splits];
+ this.$container.appendChild(editor.container);
+ editor.setFontSize(this.$fontSize);
+ this.$splits ++;
+ }
+ while (this.$splits < splits) {
+ this.$createEditor();
+ this.$splits ++;
+ }
+ } else {
+ while (this.$splits > splits) {
+ editor = this.$editors[this.$splits - 1];
+ this.$container.removeChild(editor.container);
+ this.$splits --;
+ }
+ }
+ this.resize();
+ };
+ this.getSplits = function() {
+ return this.$splits;
+ };
+ this.getEditor = function(idx) {
+ return this.$editors[idx];
+ };
+ this.getCurrentEditor = function() {
+ return this.$cEditor;
+ };
+ this.focus = function() {
+ this.$cEditor.focus();
+ };
+ this.blur = function() {
+ this.$cEditor.blur();
+ };
+ this.setTheme = function(theme) {
+ this.$editors.forEach(function(editor) {
+ editor.setTheme(theme);
+ });
+ };
+ this.setKeyboardHandler = function(keybinding) {
+ this.$editors.forEach(function(editor) {
+ editor.setKeyboardHandler(keybinding);
+ });
+ };
+ this.forEach = function(callback, scope) {
+ this.$editors.forEach(callback, scope);
+ };
+
+
+ this.$fontSize = "";
+ this.setFontSize = function(size) {
+ this.$fontSize = size;
+ this.forEach(function(editor) {
+ editor.setFontSize(size);
+ });
+ };
+
+ this.$cloneSession = function(session) {
+ var s = new EditSession(session.getDocument(), session.getMode());
+
+ var undoManager = session.getUndoManager();
+ if (undoManager) {
+ var undoManagerProxy = new UndoManagerProxy(undoManager, s);
+ s.setUndoManager(undoManagerProxy);
+ }
+ s.$informUndoManager = lang.delayedCall(function() { s.$deltas = []; });
+ s.setTabSize(session.getTabSize());
+ s.setUseSoftTabs(session.getUseSoftTabs());
+ s.setOverwrite(session.getOverwrite());
+ s.setBreakpoints(session.getBreakpoints());
+ s.setUseWrapMode(session.getUseWrapMode());
+ s.setUseWorker(session.getUseWorker());
+ s.setWrapLimitRange(session.$wrapLimitRange.min,
+ session.$wrapLimitRange.max);
+ s.$foldData = session.$cloneFoldData();
+
+ return s;
+ };
+ this.setSession = function(session, idx) {
+ var editor;
+ if (idx == null) {
+ editor = this.$cEditor;
+ } else {
+ editor = this.$editors[idx];
+ }
+ var isUsed = this.$editors.some(function(editor) {
+ return editor.session === session;
+ });
+
+ if (isUsed) {
+ session = this.$cloneSession(session);
+ }
+ editor.setSession(session);
+ return session;
+ };
+ this.getOrientation = function() {
+ return this.$orientation;
+ };
+ this.setOrientation = function(orientation) {
+ if (this.$orientation == orientation) {
+ return;
+ }
+ this.$orientation = orientation;
+ this.resize();
+ };
+ this.resize = function() {
+ var width = this.$container.clientWidth;
+ var height = this.$container.clientHeight;
+ var editor;
+
+ if (this.$orientation == this.BESIDE) {
+ var editorWidth = width / this.$splits;
+ for (var i = 0; i < this.$splits; i++) {
+ editor = this.$editors[i];
+ editor.container.style.width = editorWidth + "px";
+ editor.container.style.top = "0px";
+ editor.container.style.left = i * editorWidth + "px";
+ editor.container.style.height = height + "px";
+ editor.resize();
+ }
+ } else {
+ var editorHeight = height / this.$splits;
+ for (var i = 0; i < this.$splits; i++) {
+ editor = this.$editors[i];
+ editor.container.style.width = width + "px";
+ editor.container.style.top = i * editorHeight + "px";
+ editor.container.style.left = "0px";
+ editor.container.style.height = editorHeight + "px";
+ editor.resize();
+ }
+ }
+ };
+
+}).call(Split.prototype);
+
+
+function UndoManagerProxy(undoManager, session) {
+ this.$u = undoManager;
+ this.$doc = session;
+}
+
+(function() {
+ this.execute = function(options) {
+ this.$u.execute(options);
+ };
+
+ this.undo = function() {
+ var selectionRange = this.$u.undo(true);
+ if (selectionRange) {
+ this.$doc.selection.setSelectionRange(selectionRange);
+ }
+ };
+
+ this.redo = function() {
+ var selectionRange = this.$u.redo(true);
+ if (selectionRange) {
+ this.$doc.selection.setSelectionRange(selectionRange);
+ }
+ };
+
+ this.reset = function() {
+ this.$u.reset();
+ };
+
+ this.hasUndo = function() {
+ return this.$u.hasUndo();
+ };
+
+ this.hasRedo = function() {
+ return this.$u.hasRedo();
+ };
+}).call(UndoManagerProxy.prototype);
+
+exports.Split = Split;
+});
+
+ace.define("ace/ext/split",["require","exports","module","ace/split"], function(require, exports, module) {
+"use strict";
+module.exports = require("../split");
+
+});
+ (function() {
+ ace.require(["ace/ext/split"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-static_highlight.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-static_highlight.js
new file mode 100644
index 00000000..a875f9d7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-static_highlight.js
@@ -0,0 +1,161 @@
+ace.define("ace/ext/static_highlight",["require","exports","module","ace/edit_session","ace/layer/text","ace/config","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+var EditSession = require("../edit_session").EditSession;
+var TextLayer = require("../layer/text").Text;
+var baseStyles = ".ace_static_highlight {\
+font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source-code-pro', 'Droid Sans Mono', monospace;\
+font-size: 12px;\
+white-space: pre-wrap\
+}\
+.ace_static_highlight .ace_gutter {\
+width: 2em;\
+text-align: right;\
+padding: 0 3px 0 0;\
+margin-right: 3px;\
+}\
+.ace_static_highlight.ace_show_gutter .ace_line {\
+padding-left: 2.6em;\
+}\
+.ace_static_highlight .ace_line { position: relative; }\
+.ace_static_highlight .ace_gutter-cell {\
+-moz-user-select: -moz-none;\
+-khtml-user-select: none;\
+-webkit-user-select: none;\
+user-select: none;\
+top: 0;\
+bottom: 0;\
+left: 0;\
+position: absolute;\
+}\
+.ace_static_highlight .ace_gutter-cell:before {\
+content: counter(ace_line, decimal);\
+counter-increment: ace_line;\
+}\
+.ace_static_highlight {\
+counter-reset: ace_line;\
+}\
+";
+var config = require("../config");
+var dom = require("../lib/dom");
+
+var SimpleTextLayer = function() {
+ this.config = {};
+};
+SimpleTextLayer.prototype = TextLayer.prototype;
+
+var highlight = function(el, opts, callback) {
+ var m = el.className.match(/lang-(\w+)/);
+ var mode = opts.mode || m && ("ace/mode/" + m[1]);
+ if (!mode)
+ return false;
+ var theme = opts.theme || "ace/theme/textmate";
+
+ var data = "";
+ var nodes = [];
+
+ if (el.firstElementChild) {
+ var textLen = 0;
+ for (var i = 0; i < el.childNodes.length; i++) {
+ var ch = el.childNodes[i];
+ if (ch.nodeType == 3) {
+ textLen += ch.data.length;
+ data += ch.data;
+ } else {
+ nodes.push(textLen, ch);
+ }
+ }
+ } else {
+ data = dom.getInnerText(el);
+ if (opts.trim)
+ data = data.trim();
+ }
+
+ highlight.render(data, mode, theme, opts.firstLineNumber, !opts.showGutter, function (highlighted) {
+ dom.importCssString(highlighted.css, "ace_highlight");
+ el.innerHTML = highlighted.html;
+ var container = el.firstChild.firstChild;
+ for (var i = 0; i < nodes.length; i += 2) {
+ var pos = highlighted.session.doc.indexToPosition(nodes[i]);
+ var node = nodes[i + 1];
+ var lineEl = container.children[pos.row];
+ lineEl && lineEl.appendChild(node);
+ }
+ callback && callback();
+ });
+};
+highlight.render = function(input, mode, theme, lineStart, disableGutter, callback) {
+ var waiting = 1;
+ var modeCache = EditSession.prototype.$modes;
+ if (typeof theme == "string") {
+ waiting++;
+ config.loadModule(['theme', theme], function(m) {
+ theme = m;
+ --waiting || done();
+ });
+ }
+ var modeOptions;
+ if (mode && typeof mode === "object" && !mode.getTokenizer) {
+ modeOptions = mode;
+ mode = modeOptions.path;
+ }
+ if (typeof mode == "string") {
+ waiting++;
+ config.loadModule(['mode', mode], function(m) {
+ if (!modeCache[mode] || modeOptions)
+ modeCache[mode] = new m.Mode(modeOptions);
+ mode = modeCache[mode];
+ --waiting || done();
+ });
+ }
+ function done() {
+ var result = highlight.renderSync(input, mode, theme, lineStart, disableGutter);
+ return callback ? callback(result) : result;
+ }
+ return --waiting || done();
+};
+highlight.renderSync = function(input, mode, theme, lineStart, disableGutter) {
+ lineStart = parseInt(lineStart || 1, 10);
+
+ var session = new EditSession("");
+ session.setUseWorker(false);
+ session.setMode(mode);
+
+ var textLayer = new SimpleTextLayer();
+ textLayer.setSession(session);
+
+ session.setValue(input);
+
+ var stringBuilder = [];
+ var length = session.getLength();
+
+ for(var ix = 0; ix < length; ix++) {
+ stringBuilder.push("<div class='ace_line'>");
+ if (!disableGutter)
+ stringBuilder.push("<span class='ace_gutter ace_gutter-cell' unselectable='on'>" + /*(ix + lineStart) + */ "</span>");
+ textLayer.$renderLine(stringBuilder, ix, true, false);
+ stringBuilder.push("\n</div>");
+ }
+ var html = "<div class='" + theme.cssClass + "'>" +
+ "<div class='ace_static_highlight" + (disableGutter ? "" : " ace_show_gutter") +
+ "' style='counter-reset:ace_line " + (lineStart - 1) + "'>" +
+ stringBuilder.join("") +
+ "</div>" +
+ "</div>";
+
+ textLayer.destroy();
+
+ return {
+ css: baseStyles + theme.cssText,
+ html: html,
+ session: session
+ };
+};
+
+module.exports = highlight;
+module.exports.highlight = highlight;
+});
+ (function() {
+ ace.require(["ace/ext/static_highlight"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-statusbar.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-statusbar.js
new file mode 100644
index 00000000..0c46b381
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-statusbar.js
@@ -0,0 +1,53 @@
+ace.define("ace/ext/statusbar",["require","exports","module","ace/lib/dom","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+var dom = require("ace/lib/dom");
+var lang = require("ace/lib/lang");
+
+var StatusBar = function(editor, parentNode) {
+ this.element = dom.createElement("div");
+ this.element.className = "ace_status-indicator";
+ this.element.style.cssText = "display: inline-block;";
+ parentNode.appendChild(this.element);
+
+ var statusUpdate = lang.delayedCall(function(){
+ this.updateStatus(editor)
+ }.bind(this)).schedule.bind(null, 100);
+
+ editor.on("changeStatus", statusUpdate);
+ editor.on("changeSelection", statusUpdate);
+ editor.on("keyboardActivity", statusUpdate);
+};
+
+(function(){
+ this.updateStatus = function(editor) {
+ var status = [];
+ function add(str, separator) {
+ str && status.push(str, separator || "|");
+ }
+
+ add(editor.keyBinding.getStatusText(editor));
+ if (editor.commands.recording)
+ add("REC");
+
+ var sel = editor.selection;
+ var c = sel.lead;
+
+ if (!sel.isEmpty()) {
+ var r = editor.getSelectionRange();
+ add("(" + (r.end.row - r.start.row) + ":" +(r.end.column - r.start.column) + ")", " ");
+ }
+ add(c.row + ":" + c.column, " ");
+ if (sel.rangeCount)
+ add("[" + sel.rangeCount + "]", " ");
+ status.pop();
+ this.element.textContent = status.join("");
+ };
+}).call(StatusBar.prototype);
+
+exports.StatusBar = StatusBar;
+
+});
+ (function() {
+ ace.require(["ace/ext/statusbar"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-textarea.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-textarea.js
new file mode 100644
index 00000000..f3bc70af
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-textarea.js
@@ -0,0 +1,560 @@
+ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+exports.isDark = false;
+exports.cssClass = "ace-tm";
+exports.cssText = ".ace-tm .ace_gutter {\
+background: #f0f0f0;\
+color: #333;\
+}\
+.ace-tm .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-tm .ace_fold {\
+background-color: #6B72E6;\
+}\
+.ace-tm {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-tm .ace_cursor {\
+color: black;\
+}\
+.ace-tm .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-tm .ace_storage,\
+.ace-tm .ace_keyword {\
+color: blue;\
+}\
+.ace-tm .ace_constant {\
+color: rgb(197, 6, 11);\
+}\
+.ace-tm .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-tm .ace_constant.ace_language {\
+color: rgb(88, 92, 246);\
+}\
+.ace-tm .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-tm .ace_invalid {\
+background-color: rgba(255, 0, 0, 0.1);\
+color: red;\
+}\
+.ace-tm .ace_support.ace_function {\
+color: rgb(60, 76, 114);\
+}\
+.ace-tm .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-tm .ace_support.ace_type,\
+.ace-tm .ace_support.ace_class {\
+color: rgb(109, 121, 222);\
+}\
+.ace-tm .ace_keyword.ace_operator {\
+color: rgb(104, 118, 135);\
+}\
+.ace-tm .ace_string {\
+color: rgb(3, 106, 7);\
+}\
+.ace-tm .ace_comment {\
+color: rgb(76, 136, 107);\
+}\
+.ace-tm .ace_comment.ace_doc {\
+color: rgb(0, 102, 255);\
+}\
+.ace-tm .ace_comment.ace_doc.ace_tag {\
+color: rgb(128, 159, 191);\
+}\
+.ace-tm .ace_constant.ace_numeric {\
+color: rgb(0, 0, 205);\
+}\
+.ace-tm .ace_variable {\
+color: rgb(49, 132, 149);\
+}\
+.ace-tm .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-tm .ace_entity.ace_name.ace_function {\
+color: #0000A2;\
+}\
+.ace-tm .ace_heading {\
+color: rgb(12, 7, 255);\
+}\
+.ace-tm .ace_list {\
+color:rgb(185, 6, 144);\
+}\
+.ace-tm .ace_meta.ace_tag {\
+color:rgb(0, 22, 142);\
+}\
+.ace-tm .ace_string.ace_regex {\
+color: rgb(255, 0, 0)\
+}\
+.ace-tm .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-tm.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px white;\
+}\
+.ace-tm .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-tm .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-tm .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-tm .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.07);\
+}\
+.ace-tm .ace_gutter-active-line {\
+background-color : #dcdcdc;\
+}\
+.ace-tm .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-tm .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
+
+ace.define("ace/ext/textarea",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/net","ace/ace","ace/theme/textmate"], function(require, exports, module) {
+"use strict";
+
+var event = require("../lib/event");
+var UA = require("../lib/useragent");
+var net = require("../lib/net");
+var ace = require("../ace");
+
+require("../theme/textmate");
+
+module.exports = exports = ace;
+var getCSSProperty = function(element, container, property) {
+ var ret = element.style[property];
+
+ if (!ret) {
+ if (window.getComputedStyle) {
+ ret = window.getComputedStyle(element, '').getPropertyValue(property);
+ } else {
+ ret = element.currentStyle[property];
+ }
+ }
+
+ if (!ret || ret == 'auto' || ret == 'intrinsic') {
+ ret = container.style[property];
+ }
+ return ret;
+};
+
+function applyStyles(elm, styles) {
+ for (var style in styles) {
+ elm.style[style] = styles[style];
+ }
+}
+
+function setupContainer(element, getValue) {
+ if (element.type != 'textarea') {
+ throw new Error("Textarea required!");
+ }
+
+ var parentNode = element.parentNode;
+ var container = document.createElement('div');
+ var resizeEvent = function() {
+ var style = 'position:relative;';
+ [
+ 'margin-top', 'margin-left', 'margin-right', 'margin-bottom'
+ ].forEach(function(item) {
+ style += item + ':' +
+ getCSSProperty(element, container, item) + ';';
+ });
+ var width = getCSSProperty(element, container, 'width') || (element.clientWidth + "px");
+ var height = getCSSProperty(element, container, 'height') || (element.clientHeight + "px");
+ style += 'height:' + height + ';width:' + width + ';';
+ style += 'display:inline-block;';
+ container.setAttribute('style', style);
+ };
+ event.addListener(window, 'resize', resizeEvent);
+ resizeEvent();
+ parentNode.insertBefore(container, element.nextSibling);
+ while (parentNode !== document) {
+ if (parentNode.tagName.toUpperCase() === 'FORM') {
+ var oldSumit = parentNode.onsubmit;
+ parentNode.onsubmit = function(evt) {
+ element.value = getValue();
+ if (oldSumit) {
+ oldSumit.call(this, evt);
+ }
+ };
+ break;
+ }
+ parentNode = parentNode.parentNode;
+ }
+ return container;
+}
+
+exports.transformTextarea = function(element, options) {
+ var session;
+ var container = setupContainer(element, function() {
+ return session.getValue();
+ });
+ element.style.display = 'none';
+ container.style.background = 'white';
+ var editorDiv = document.createElement("div");
+ applyStyles(editorDiv, {
+ top: "0px",
+ left: "0px",
+ right: "0px",
+ bottom: "0px",
+ border: "1px solid gray",
+ position: "absolute"
+ });
+ container.appendChild(editorDiv);
+
+ var settingOpener = document.createElement("div");
+ applyStyles(settingOpener, {
+ position: "absolute",
+ right: "0px",
+ bottom: "0px",
+ background: "red",
+ cursor: "nw-resize",
+ borderStyle: "solid",
+ borderWidth: "9px 8px 10px 9px",
+ width: "2px",
+ borderColor: "lightblue gray gray lightblue",
+ zIndex: 101
+ });
+
+ var settingDiv = document.createElement("div");
+ var settingDivStyles = {
+ top: "0px",
+ left: "20%",
+ right: "0px",
+ bottom: "0px",
+ position: "absolute",
+ padding: "5px",
+ zIndex: 100,
+ color: "white",
+ display: "none",
+ overflow: "auto",
+ fontSize: "14px",
+ boxShadow: "-5px 2px 3px gray"
+ };
+ if (!UA.isOldIE) {
+ settingDivStyles.backgroundColor = "rgba(0, 0, 0, 0.6)";
+ } else {
+ settingDivStyles.backgroundColor = "#333";
+ }
+
+ applyStyles(settingDiv, settingDivStyles);
+ container.appendChild(settingDiv);
+
+ options = options || exports.defaultOptions;
+ var editor = ace.edit(editorDiv);
+ session = editor.getSession();
+
+ session.setValue(element.value || element.innerHTML);
+ editor.focus();
+ container.appendChild(settingOpener);
+ setupApi(editor, editorDiv, settingDiv, ace, options, load);
+ setupSettingPanel(settingDiv, settingOpener, editor);
+
+ var state = "";
+ event.addListener(settingOpener, "mousemove", function(e) {
+ var rect = this.getBoundingClientRect();
+ var x = e.clientX - rect.left, y = e.clientY - rect.top;
+ if (x + y < (rect.width + rect.height)/2) {
+ this.style.cursor = "pointer";
+ state = "toggle";
+ } else {
+ state = "resize";
+ this.style.cursor = "nw-resize";
+ }
+ });
+
+ event.addListener(settingOpener, "mousedown", function(e) {
+ if (state == "toggle") {
+ editor.setDisplaySettings();
+ return;
+ }
+ container.style.zIndex = 100000;
+ var rect = container.getBoundingClientRect();
+ var startX = rect.width + rect.left - e.clientX;
+ var startY = rect.height + rect.top - e.clientY;
+ event.capture(settingOpener, function(e) {
+ container.style.width = e.clientX - rect.left + startX + "px";
+ container.style.height = e.clientY - rect.top + startY + "px";
+ editor.resize();
+ }, function() {});
+ });
+
+ return editor;
+};
+
+function load(url, module, callback) {
+ net.loadScript(url, function() {
+ require([module], callback);
+ });
+}
+
+function setupApi(editor, editorDiv, settingDiv, ace, options, loader) {
+ var session = editor.getSession();
+ var renderer = editor.renderer;
+ loader = loader || load;
+
+ function toBool(value) {
+ return value === "true" || value == true;
+ }
+
+ editor.setDisplaySettings = function(display) {
+ if (display == null)
+ display = settingDiv.style.display == "none";
+ if (display) {
+ settingDiv.style.display = "block";
+ settingDiv.hideButton.focus();
+ editor.on("focus", function onFocus() {
+ editor.removeListener("focus", onFocus);
+ settingDiv.style.display = "none";
+ });
+ } else {
+ editor.focus();
+ }
+ };
+
+ editor.$setOption = editor.setOption;
+ editor.$getOption = editor.getOption;
+ editor.setOption = function(key, value) {
+ switch (key) {
+ case "mode":
+ editor.$setOption("mode", "ace/mode/" + value)
+ break;
+ case "theme":
+ editor.$setOption("theme", "ace/theme/" + value)
+ break;
+ case "keybindings":
+ switch (value) {
+ case "vim":
+ editor.setKeyboardHandler("ace/keyboard/vim");
+ break;
+ case "emacs":
+ editor.setKeyboardHandler("ace/keyboard/emacs");
+ break;
+ default:
+ editor.setKeyboardHandler(null);
+ }
+ break;
+
+ case "softWrap":
+ case "fontSize":
+ editor.$setOption(key, value);
+ break;
+
+ default:
+ editor.$setOption(key, toBool(value));
+ }
+ };
+
+ editor.getOption = function(key) {
+ switch (key) {
+ case "mode":
+ return editor.$getOption("mode").substr("ace/mode/".length)
+ break;
+
+ case "theme":
+ return editor.$getOption("theme").substr("ace/theme/".length)
+ break;
+
+ case "keybindings":
+ var value = editor.getKeyboardHandler()
+ switch (value && value.$id) {
+ case "ace/keyboard/vim":
+ return "vim";
+ case "ace/keyboard/emacs":
+ return "emacs";
+ default:
+ return "ace";
+ }
+ break;
+
+ default:
+ return editor.$getOption(key);
+ }
+ };
+
+ editor.setOptions(options);
+ return editor;
+}
+
+function setupSettingPanel(settingDiv, settingOpener, editor) {
+ var BOOL = null;
+
+ var desc = {
+ mode: "Mode:",
+ wrap: "Soft Wrap:",
+ theme: "Theme:",
+ fontSize: "Font Size:",
+ showGutter: "Display Gutter:",
+ keybindings: "Keyboard",
+ showPrintMargin: "Show Print Margin:",
+ useSoftTabs: "Use Soft Tabs:",
+ showInvisibles: "Show Invisibles"
+ };
+
+ var optionValues = {
+ mode: {
+ text: "Plain",
+ javascript: "JavaScript",
+ xml: "XML",
+ html: "HTML",
+ css: "CSS",
+ scss: "SCSS",
+ python: "Python",
+ php: "PHP",
+ java: "Java",
+ ruby: "Ruby",
+ c_cpp: "C/C++",
+ coffee: "CoffeeScript",
+ json: "json",
+ perl: "Perl",
+ clojure: "Clojure",
+ ocaml: "OCaml",
+ csharp: "C#",
+ haxe: "haXe",
+ svg: "SVG",
+ textile: "Textile",
+ groovy: "Groovy",
+ liquid: "Liquid",
+ Scala: "Scala"
+ },
+ theme: {
+ clouds: "Clouds",
+ clouds_midnight: "Clouds Midnight",
+ cobalt: "Cobalt",
+ crimson_editor: "Crimson Editor",
+ dawn: "Dawn",
+ gob: "Green on Black",
+ eclipse: "Eclipse",
+ idle_fingers: "Idle Fingers",
+ kr_theme: "Kr Theme",
+ merbivore: "Merbivore",
+ merbivore_soft: "Merbivore Soft",
+ mono_industrial: "Mono Industrial",
+ monokai: "Monokai",
+ pastel_on_dark: "Pastel On Dark",
+ solarized_dark: "Solarized Dark",
+ solarized_light: "Solarized Light",
+ textmate: "Textmate",
+ twilight: "Twilight",
+ vibrant_ink: "Vibrant Ink"
+ },
+ showGutter: BOOL,
+ fontSize: {
+ "10px": "10px",
+ "11px": "11px",
+ "12px": "12px",
+ "14px": "14px",
+ "16px": "16px"
+ },
+ wrap: {
+ off: "Off",
+ 40: "40",
+ 80: "80",
+ free: "Free"
+ },
+ keybindings: {
+ ace: "ace",
+ vim: "vim",
+ emacs: "emacs"
+ },
+ showPrintMargin: BOOL,
+ useSoftTabs: BOOL,
+ showInvisibles: BOOL
+ };
+
+ var table = [];
+ table.push("<table><tr><th>Setting</th><th>Value</th></tr>");
+
+ function renderOption(builder, option, obj, cValue) {
+ if (!obj) {
+ builder.push(
+ "<input type='checkbox' title='", option, "' ",
+ cValue + "" == "true" ? "checked='true'" : "",
+ "'></input>"
+ );
+ return;
+ }
+ builder.push("<select title='" + option + "'>");
+ for (var value in obj) {
+ builder.push("<option value='" + value + "' ");
+
+ if (cValue == value) {
+ builder.push(" selected ");
+ }
+
+ builder.push(">",
+ obj[value],
+ "</option>");
+ }
+ builder.push("</select>");
+ }
+
+ for (var option in exports.defaultOptions) {
+ table.push("<tr><td>", desc[option], "</td>");
+ table.push("<td>");
+ renderOption(table, option, optionValues[option], editor.getOption(option));
+ table.push("</td></tr>");
+ }
+ table.push("</table>");
+ settingDiv.innerHTML = table.join("");
+
+ var onChange = function(e) {
+ var select = e.currentTarget;
+ editor.setOption(select.title, select.value);
+ };
+ var onClick = function(e) {
+ var cb = e.currentTarget;
+ editor.setOption(cb.title, cb.checked);
+ };
+ var selects = settingDiv.getElementsByTagName("select");
+ for (var i = 0; i < selects.length; i++)
+ selects[i].onchange = onChange;
+ var cbs = settingDiv.getElementsByTagName("input");
+ for (var i = 0; i < cbs.length; i++)
+ cbs[i].onclick = onClick;
+
+
+ var button = document.createElement("input");
+ button.type = "button";
+ button.value = "Hide";
+ event.addListener(button, "click", function() {
+ editor.setDisplaySettings(false);
+ });
+ settingDiv.appendChild(button);
+ settingDiv.hideButton = button;
+}
+exports.defaultOptions = {
+ mode: "javascript",
+ theme: "textmate",
+ wrap: "off",
+ fontSize: "12px",
+ showGutter: "false",
+ keybindings: "ace",
+ showPrintMargin: "false",
+ useSoftTabs: "true",
+ showInvisibles: "false"
+};
+
+});
+ (function() {
+ ace.require(["ace/ext/textarea"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-themelist.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-themelist.js
new file mode 100644
index 00000000..53225ada
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-themelist.js
@@ -0,0 +1,62 @@
+ace.define("ace/ext/themelist",["require","exports","module","ace/lib/fixoldbrowsers"], function(require, exports, module) {
+"use strict";
+require("ace/lib/fixoldbrowsers");
+
+var themeData = [
+ ["Chrome" ],
+ ["Clouds" ],
+ ["Crimson Editor" ],
+ ["Dawn" ],
+ ["Dreamweaver" ],
+ ["Eclipse" ],
+ ["GitHub" ],
+ ["IPlastic" ],
+ ["Solarized Light"],
+ ["TextMate" ],
+ ["Tomorrow" ],
+ ["XCode" ],
+ ["Kuroir"],
+ ["KatzenMilch"],
+ ["SQL Server" ,"sqlserver" , "light"],
+ ["Ambiance" ,"ambiance" , "dark"],
+ ["Chaos" ,"chaos" , "dark"],
+ ["Clouds Midnight" ,"clouds_midnight" , "dark"],
+ ["Cobalt" ,"cobalt" , "dark"],
+ ["Gruvbox" ,"gruvbox" , "dark"],
+ ["Green on Black" ,"gob" , "dark"],
+ ["idle Fingers" ,"idle_fingers" , "dark"],
+ ["krTheme" ,"kr_theme" , "dark"],
+ ["Merbivore" ,"merbivore" , "dark"],
+ ["Merbivore Soft" ,"merbivore_soft" , "dark"],
+ ["Mono Industrial" ,"mono_industrial" , "dark"],
+ ["Monokai" ,"monokai" , "dark"],
+ ["Pastel on dark" ,"pastel_on_dark" , "dark"],
+ ["Solarized Dark" ,"solarized_dark" , "dark"],
+ ["Terminal" ,"terminal" , "dark"],
+ ["Tomorrow Night" ,"tomorrow_night" , "dark"],
+ ["Tomorrow Night Blue" ,"tomorrow_night_blue" , "dark"],
+ ["Tomorrow Night Bright","tomorrow_night_bright" , "dark"],
+ ["Tomorrow Night 80s" ,"tomorrow_night_eighties" , "dark"],
+ ["Twilight" ,"twilight" , "dark"],
+ ["Vibrant Ink" ,"vibrant_ink" , "dark"]
+];
+
+
+exports.themesByName = {};
+exports.themes = themeData.map(function(data) {
+ var name = data[1] || data[0].replace(/ /g, "_").toLowerCase();
+ var theme = {
+ caption: data[0],
+ theme: "ace/theme/" + name,
+ isDark: data[2] == "dark",
+ name: name
+ };
+ exports.themesByName[name] = theme;
+ return theme;
+});
+
+});
+ (function() {
+ ace.require(["ace/ext/themelist"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/ext-whitespace.js b/www/wiki/extensions/CodeEditor/modules/ace/ext-whitespace.js
new file mode 100644
index 00000000..8f4af96c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/ext-whitespace.js
@@ -0,0 +1,206 @@
+ace.define("ace/ext/whitespace",["require","exports","module","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var lang = require("../lib/lang");
+exports.$detectIndentation = function(lines, fallback) {
+ var stats = [];
+ var changes = [];
+ var tabIndents = 0;
+ var prevSpaces = 0;
+ var max = Math.min(lines.length, 1000);
+ for (var i = 0; i < max; i++) {
+ var line = lines[i];
+ if (!/^\s*[^*+\-\s]/.test(line))
+ continue;
+
+ if (line[0] == "\t") {
+ tabIndents++;
+ prevSpaces = -Number.MAX_VALUE;
+ } else {
+ var spaces = line.match(/^ */)[0].length;
+ if (spaces && line[spaces] != "\t") {
+ var diff = spaces - prevSpaces;
+ if (diff > 0 && !(prevSpaces%diff) && !(spaces%diff))
+ changes[diff] = (changes[diff] || 0) + 1;
+
+ stats[spaces] = (stats[spaces] || 0) + 1;
+ }
+ prevSpaces = spaces;
+ }
+ while (i < max && line[line.length - 1] == "\\")
+ line = lines[i++];
+ }
+
+ function getScore(indent) {
+ var score = 0;
+ for (var i = indent; i < stats.length; i += indent)
+ score += stats[i] || 0;
+ return score;
+ }
+
+ var changesTotal = changes.reduce(function(a,b){return a+b}, 0);
+
+ var first = {score: 0, length: 0};
+ var spaceIndents = 0;
+ for (var i = 1; i < 12; i++) {
+ var score = getScore(i);
+ if (i == 1) {
+ spaceIndents = score;
+ score = stats[1] ? 0.9 : 0.8;
+ if (!stats.length)
+ score = 0;
+ } else
+ score /= spaceIndents;
+
+ if (changes[i])
+ score += changes[i] / changesTotal;
+
+ if (score > first.score)
+ first = {score: score, length: i};
+ }
+
+ if (first.score && first.score > 1.4)
+ var tabLength = first.length;
+
+ if (tabIndents > spaceIndents + 1) {
+ if (tabLength == 1 || spaceIndents < tabIndents / 4 || first.score < 1.8)
+ tabLength = undefined;
+ return {ch: "\t", length: tabLength};
+ }
+ if (spaceIndents > tabIndents + 1)
+ return {ch: " ", length: tabLength};
+};
+
+exports.detectIndentation = function(session) {
+ var lines = session.getLines(0, 1000);
+ var indent = exports.$detectIndentation(lines) || {};
+
+ if (indent.ch)
+ session.setUseSoftTabs(indent.ch == " ");
+
+ if (indent.length)
+ session.setTabSize(indent.length);
+ return indent;
+};
+exports.trimTrailingSpace = function(session, options) {
+ var doc = session.getDocument();
+ var lines = doc.getAllLines();
+
+ var min = options && options.trimEmpty ? -1 : 0;
+ var cursors = [], ci = -1;
+ if (options && options.keepCursorPosition) {
+ if (session.selection.rangeCount) {
+ session.selection.rangeList.ranges.forEach(function(x, i, ranges) {
+ var next = ranges[i + 1];
+ if (next && next.cursor.row == x.cursor.row)
+ return;
+ cursors.push(x.cursor);
+ });
+ } else {
+ cursors.push(session.selection.getCursor());
+ }
+ ci = 0;
+ }
+ var cursorRow = cursors[ci] && cursors[ci].row;
+
+ for (var i = 0, l=lines.length; i < l; i++) {
+ var line = lines[i];
+ var index = line.search(/\s+$/);
+
+ if (i == cursorRow) {
+ if (index < cursors[ci].column && index > min)
+ index = cursors[ci].column;
+ ci++;
+ cursorRow = cursors[ci] ? cursors[ci].row : -1;
+ }
+
+ if (index > min)
+ doc.removeInLine(i, index, line.length);
+ }
+};
+
+exports.convertIndentation = function(session, ch, len) {
+ var oldCh = session.getTabString()[0];
+ var oldLen = session.getTabSize();
+ if (!len) len = oldLen;
+ if (!ch) ch = oldCh;
+
+ var tab = ch == "\t" ? ch: lang.stringRepeat(ch, len);
+
+ var doc = session.doc;
+ var lines = doc.getAllLines();
+
+ var cache = {};
+ var spaceCache = {};
+ for (var i = 0, l=lines.length; i < l; i++) {
+ var line = lines[i];
+ var match = line.match(/^\s*/)[0];
+ if (match) {
+ var w = session.$getStringScreenWidth(match)[0];
+ var tabCount = Math.floor(w/oldLen);
+ var reminder = w%oldLen;
+ var toInsert = cache[tabCount] || (cache[tabCount] = lang.stringRepeat(tab, tabCount));
+ toInsert += spaceCache[reminder] || (spaceCache[reminder] = lang.stringRepeat(" ", reminder));
+
+ if (toInsert != match) {
+ doc.removeInLine(i, 0, match.length);
+ doc.insertInLine({row: i, column: 0}, toInsert);
+ }
+ }
+ }
+ session.setTabSize(len);
+ session.setUseSoftTabs(ch == " ");
+};
+
+exports.$parseStringArg = function(text) {
+ var indent = {};
+ if (/t/.test(text))
+ indent.ch = "\t";
+ else if (/s/.test(text))
+ indent.ch = " ";
+ var m = text.match(/\d+/);
+ if (m)
+ indent.length = parseInt(m[0], 10);
+ return indent;
+};
+
+exports.$parseArg = function(arg) {
+ if (!arg)
+ return {};
+ if (typeof arg == "string")
+ return exports.$parseStringArg(arg);
+ if (typeof arg.text == "string")
+ return exports.$parseStringArg(arg.text);
+ return arg;
+};
+
+exports.commands = [{
+ name: "detectIndentation",
+ exec: function(editor) {
+ exports.detectIndentation(editor.session);
+ }
+}, {
+ name: "trimTrailingSpace",
+ exec: function(editor) {
+ exports.trimTrailingSpace(editor.session);
+ }
+}, {
+ name: "convertIndentation",
+ exec: function(editor, arg) {
+ var indent = exports.$parseArg(arg);
+ exports.convertIndentation(editor.session, indent.ch, indent.length);
+ }
+}, {
+ name: "setIndentation",
+ exec: function(editor, arg) {
+ var indent = exports.$parseArg(arg);
+ indent.length && editor.session.setTabSize(indent.length);
+ indent.ch && editor.session.setUseSoftTabs(indent.ch == " ");
+ }
+}];
+
+});
+ (function() {
+ ace.require(["ace/ext/whitespace"], function() {});
+ })();
+ \ No newline at end of file
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/keybinding-emacs.js b/www/wiki/extensions/CodeEditor/modules/ace/keybinding-emacs.js
new file mode 100644
index 00000000..8816abad
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/keybinding-emacs.js
@@ -0,0 +1,1181 @@
+ace.define("ace/occur",["require","exports","module","ace/lib/oop","ace/range","ace/search","ace/edit_session","ace/search_highlight","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var Range = require("./range").Range;
+var Search = require("./search").Search;
+var EditSession = require("./edit_session").EditSession;
+var SearchHighlight = require("./search_highlight").SearchHighlight;
+function Occur() {}
+
+oop.inherits(Occur, Search);
+
+(function() {
+ this.enter = function(editor, options) {
+ if (!options.needle) return false;
+ var pos = editor.getCursorPosition();
+ this.displayOccurContent(editor, options);
+ var translatedPos = this.originalToOccurPosition(editor.session, pos);
+ editor.moveCursorToPosition(translatedPos);
+ return true;
+ }
+ this.exit = function(editor, options) {
+ var pos = options.translatePosition && editor.getCursorPosition();
+ var translatedPos = pos && this.occurToOriginalPosition(editor.session, pos);
+ this.displayOriginalContent(editor);
+ if (translatedPos)
+ editor.moveCursorToPosition(translatedPos);
+ return true;
+ }
+
+ this.highlight = function(sess, regexp) {
+ var hl = sess.$occurHighlight = sess.$occurHighlight || sess.addDynamicMarker(
+ new SearchHighlight(null, "ace_occur-highlight", "text"));
+ hl.setRegexp(regexp);
+ sess._emit("changeBackMarker"); // force highlight layer redraw
+ }
+
+ this.displayOccurContent = function(editor, options) {
+ this.$originalSession = editor.session;
+ var found = this.matchingLines(editor.session, options);
+ var lines = found.map(function(foundLine) { return foundLine.content; });
+ var occurSession = new EditSession(lines.join('\n'));
+ occurSession.$occur = this;
+ occurSession.$occurMatchingLines = found;
+ editor.setSession(occurSession);
+ this.$useEmacsStyleLineStart = this.$originalSession.$useEmacsStyleLineStart;
+ occurSession.$useEmacsStyleLineStart = this.$useEmacsStyleLineStart;
+ this.highlight(occurSession, options.re);
+ occurSession._emit('changeBackMarker');
+ }
+
+ this.displayOriginalContent = function(editor) {
+ editor.setSession(this.$originalSession);
+ this.$originalSession.$useEmacsStyleLineStart = this.$useEmacsStyleLineStart;
+ }
+ this.originalToOccurPosition = function(session, pos) {
+ var lines = session.$occurMatchingLines;
+ var nullPos = {row: 0, column: 0};
+ if (!lines) return nullPos;
+ for (var i = 0; i < lines.length; i++) {
+ if (lines[i].row === pos.row)
+ return {row: i, column: pos.column};
+ }
+ return nullPos;
+ }
+ this.occurToOriginalPosition = function(session, pos) {
+ var lines = session.$occurMatchingLines;
+ if (!lines || !lines[pos.row])
+ return pos;
+ return {row: lines[pos.row].row, column: pos.column};
+ }
+
+ this.matchingLines = function(session, options) {
+ options = oop.mixin({}, options);
+ if (!session || !options.needle) return [];
+ var search = new Search();
+ search.set(options);
+ return search.findAll(session).reduce(function(lines, range) {
+ var row = range.start.row;
+ var last = lines[lines.length-1];
+ return last && last.row === row ?
+ lines :
+ lines.concat({row: row, content: session.getLine(row)});
+ }, []);
+ }
+
+}).call(Occur.prototype);
+
+var dom = require('./lib/dom');
+dom.importCssString(".ace_occur-highlight {\n\
+ border-radius: 4px;\n\
+ background-color: rgba(87, 255, 8, 0.25);\n\
+ position: absolute;\n\
+ z-index: 4;\n\
+ -moz-box-sizing: border-box;\n\
+ -webkit-box-sizing: border-box;\n\
+ box-sizing: border-box;\n\
+ box-shadow: 0 0 4px rgb(91, 255, 50);\n\
+}\n\
+.ace_dark .ace_occur-highlight {\n\
+ background-color: rgb(80, 140, 85);\n\
+ box-shadow: 0 0 4px rgb(60, 120, 70);\n\
+}\n", "incremental-occur-highlighting");
+
+exports.Occur = Occur;
+
+});
+
+ace.define("ace/commands/occur_commands",["require","exports","module","ace/config","ace/occur","ace/keyboard/hash_handler","ace/lib/oop"], function(require, exports, module) {
+
+var config = require("../config"),
+ Occur = require("../occur").Occur;
+var occurStartCommand = {
+ name: "occur",
+ exec: function(editor, options) {
+ var alreadyInOccur = !!editor.session.$occur;
+ var occurSessionActive = new Occur().enter(editor, options);
+ if (occurSessionActive && !alreadyInOccur)
+ OccurKeyboardHandler.installIn(editor);
+ },
+ readOnly: true
+};
+
+var occurCommands = [{
+ name: "occurexit",
+ bindKey: 'esc|Ctrl-G',
+ exec: function(editor) {
+ var occur = editor.session.$occur;
+ if (!occur) return;
+ occur.exit(editor, {});
+ if (!editor.session.$occur) OccurKeyboardHandler.uninstallFrom(editor);
+ },
+ readOnly: true
+}, {
+ name: "occuraccept",
+ bindKey: 'enter',
+ exec: function(editor) {
+ var occur = editor.session.$occur;
+ if (!occur) return;
+ occur.exit(editor, {translatePosition: true});
+ if (!editor.session.$occur) OccurKeyboardHandler.uninstallFrom(editor);
+ },
+ readOnly: true
+}];
+
+var HashHandler = require("../keyboard/hash_handler").HashHandler;
+var oop = require("../lib/oop");
+
+
+function OccurKeyboardHandler() {}
+
+oop.inherits(OccurKeyboardHandler, HashHandler);
+
+(function() {
+
+ this.isOccurHandler = true;
+
+ this.attach = function(editor) {
+ HashHandler.call(this, occurCommands, editor.commands.platform);
+ this.$editor = editor;
+ }
+
+ var handleKeyboard$super = this.handleKeyboard;
+ this.handleKeyboard = function(data, hashId, key, keyCode) {
+ var cmd = handleKeyboard$super.call(this, data, hashId, key, keyCode);
+ return (cmd && cmd.command) ? cmd : undefined;
+ }
+
+}).call(OccurKeyboardHandler.prototype);
+
+OccurKeyboardHandler.installIn = function(editor) {
+ var handler = new this();
+ editor.keyBinding.addKeyboardHandler(handler);
+ editor.commands.addCommands(occurCommands);
+}
+
+OccurKeyboardHandler.uninstallFrom = function(editor) {
+ editor.commands.removeCommands(occurCommands);
+ var handler = editor.getKeyboardHandler();
+ if (handler.isOccurHandler)
+ editor.keyBinding.removeKeyboardHandler(handler);
+}
+
+exports.occurStartCommand = occurStartCommand;
+
+});
+
+ace.define("ace/commands/incremental_search_commands",["require","exports","module","ace/config","ace/lib/oop","ace/keyboard/hash_handler","ace/commands/occur_commands"], function(require, exports, module) {
+
+var config = require("../config");
+var oop = require("../lib/oop");
+var HashHandler = require("../keyboard/hash_handler").HashHandler;
+var occurStartCommand = require("./occur_commands").occurStartCommand;
+exports.iSearchStartCommands = [{
+ name: "iSearch",
+ bindKey: {win: "Ctrl-F", mac: "Command-F"},
+ exec: function(editor, options) {
+ config.loadModule(["core", "ace/incremental_search"], function(e) {
+ var iSearch = e.iSearch = e.iSearch || new e.IncrementalSearch();
+ iSearch.activate(editor, options.backwards);
+ if (options.jumpToFirstMatch) iSearch.next(options);
+ });
+ },
+ readOnly: true
+}, {
+ name: "iSearchBackwards",
+ exec: function(editor, jumpToNext) { editor.execCommand('iSearch', {backwards: true}); },
+ readOnly: true
+}, {
+ name: "iSearchAndGo",
+ bindKey: {win: "Ctrl-K", mac: "Command-G"},
+ exec: function(editor, jumpToNext) { editor.execCommand('iSearch', {jumpToFirstMatch: true, useCurrentOrPrevSearch: true}); },
+ readOnly: true
+}, {
+ name: "iSearchBackwardsAndGo",
+ bindKey: {win: "Ctrl-Shift-K", mac: "Command-Shift-G"},
+ exec: function(editor) { editor.execCommand('iSearch', {jumpToFirstMatch: true, backwards: true, useCurrentOrPrevSearch: true}); },
+ readOnly: true
+}];
+exports.iSearchCommands = [{
+ name: "restartSearch",
+ bindKey: {win: "Ctrl-F", mac: "Command-F"},
+ exec: function(iSearch) {
+ iSearch.cancelSearch(true);
+ }
+}, {
+ name: "searchForward",
+ bindKey: {win: "Ctrl-S|Ctrl-K", mac: "Ctrl-S|Command-G"},
+ exec: function(iSearch, options) {
+ options.useCurrentOrPrevSearch = true;
+ iSearch.next(options);
+ }
+}, {
+ name: "searchBackward",
+ bindKey: {win: "Ctrl-R|Ctrl-Shift-K", mac: "Ctrl-R|Command-Shift-G"},
+ exec: function(iSearch, options) {
+ options.useCurrentOrPrevSearch = true;
+ options.backwards = true;
+ iSearch.next(options);
+ }
+}, {
+ name: "extendSearchTerm",
+ exec: function(iSearch, string) {
+ iSearch.addString(string);
+ }
+}, {
+ name: "extendSearchTermSpace",
+ bindKey: "space",
+ exec: function(iSearch) { iSearch.addString(' '); }
+}, {
+ name: "shrinkSearchTerm",
+ bindKey: "backspace",
+ exec: function(iSearch) {
+ iSearch.removeChar();
+ }
+}, {
+ name: 'confirmSearch',
+ bindKey: 'return',
+ exec: function(iSearch) { iSearch.deactivate(); }
+}, {
+ name: 'cancelSearch',
+ bindKey: 'esc|Ctrl-G',
+ exec: function(iSearch) { iSearch.deactivate(true); }
+}, {
+ name: 'occurisearch',
+ bindKey: 'Ctrl-O',
+ exec: function(iSearch) {
+ var options = oop.mixin({}, iSearch.$options);
+ iSearch.deactivate();
+ occurStartCommand.exec(iSearch.$editor, options);
+ }
+}, {
+ name: "yankNextWord",
+ bindKey: "Ctrl-w",
+ exec: function(iSearch) {
+ var ed = iSearch.$editor,
+ range = ed.selection.getRangeOfMovements(function(sel) { sel.moveCursorWordRight(); }),
+ string = ed.session.getTextRange(range);
+ iSearch.addString(string);
+ }
+}, {
+ name: "yankNextChar",
+ bindKey: "Ctrl-Alt-y",
+ exec: function(iSearch) {
+ var ed = iSearch.$editor,
+ range = ed.selection.getRangeOfMovements(function(sel) { sel.moveCursorRight(); }),
+ string = ed.session.getTextRange(range);
+ iSearch.addString(string);
+ }
+}, {
+ name: 'recenterTopBottom',
+ bindKey: 'Ctrl-l',
+ exec: function(iSearch) { iSearch.$editor.execCommand('recenterTopBottom'); }
+}, {
+ name: 'selectAllMatches',
+ bindKey: 'Ctrl-space',
+ exec: function(iSearch) {
+ var ed = iSearch.$editor,
+ hl = ed.session.$isearchHighlight,
+ ranges = hl && hl.cache ? hl.cache
+ .reduce(function(ranges, ea) {
+ return ranges.concat(ea ? ea : []); }, []) : [];
+ iSearch.deactivate(false);
+ ranges.forEach(ed.selection.addRange.bind(ed.selection));
+ }
+}, {
+ name: 'searchAsRegExp',
+ bindKey: 'Alt-r',
+ exec: function(iSearch) {
+ iSearch.convertNeedleToRegExp();
+ }
+}].map(function(cmd) {
+ cmd.readOnly = true;
+ cmd.isIncrementalSearchCommand = true;
+ cmd.scrollIntoView = "animate-cursor";
+ return cmd;
+});
+
+function IncrementalSearchKeyboardHandler(iSearch) {
+ this.$iSearch = iSearch;
+}
+
+oop.inherits(IncrementalSearchKeyboardHandler, HashHandler);
+
+(function() {
+
+ this.attach = function(editor) {
+ var iSearch = this.$iSearch;
+ HashHandler.call(this, exports.iSearchCommands, editor.commands.platform);
+ this.$commandExecHandler = editor.commands.addEventListener('exec', function(e) {
+ if (!e.command.isIncrementalSearchCommand)
+ return iSearch.deactivate();
+ e.stopPropagation();
+ e.preventDefault();
+ var scrollTop = editor.session.getScrollTop();
+ var result = e.command.exec(iSearch, e.args || {});
+ editor.renderer.scrollCursorIntoView(null, 0.5);
+ editor.renderer.animateScrolling(scrollTop);
+ return result;
+ });
+ };
+
+ this.detach = function(editor) {
+ if (!this.$commandExecHandler) return;
+ editor.commands.removeEventListener('exec', this.$commandExecHandler);
+ delete this.$commandExecHandler;
+ };
+
+ var handleKeyboard$super = this.handleKeyboard;
+ this.handleKeyboard = function(data, hashId, key, keyCode) {
+ if (((hashId === 1/*ctrl*/ || hashId === 8/*command*/) && key === 'v')
+ || (hashId === 1/*ctrl*/ && key === 'y')) return null;
+ var cmd = handleKeyboard$super.call(this, data, hashId, key, keyCode);
+ if (cmd.command) { return cmd; }
+ if (hashId == -1) {
+ var extendCmd = this.commands.extendSearchTerm;
+ if (extendCmd) { return {command: extendCmd, args: key}; }
+ }
+ return false;
+ };
+
+}).call(IncrementalSearchKeyboardHandler.prototype);
+
+
+exports.IncrementalSearchKeyboardHandler = IncrementalSearchKeyboardHandler;
+
+});
+
+ace.define("ace/incremental_search",["require","exports","module","ace/lib/oop","ace/range","ace/search","ace/search_highlight","ace/commands/incremental_search_commands","ace/lib/dom","ace/commands/command_manager","ace/editor","ace/config"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var Range = require("./range").Range;
+var Search = require("./search").Search;
+var SearchHighlight = require("./search_highlight").SearchHighlight;
+var iSearchCommandModule = require("./commands/incremental_search_commands");
+var ISearchKbd = iSearchCommandModule.IncrementalSearchKeyboardHandler;
+function IncrementalSearch() {
+ this.$options = {wrap: false, skipCurrent: false};
+ this.$keyboardHandler = new ISearchKbd(this);
+}
+
+oop.inherits(IncrementalSearch, Search);
+
+function isRegExp(obj) {
+ return obj instanceof RegExp;
+}
+
+function regExpToObject(re) {
+ var string = String(re),
+ start = string.indexOf('/'),
+ flagStart = string.lastIndexOf('/');
+ return {
+ expression: string.slice(start+1, flagStart),
+ flags: string.slice(flagStart+1)
+ }
+}
+
+function stringToRegExp(string, flags) {
+ try {
+ return new RegExp(string, flags);
+ } catch (e) { return string; }
+}
+
+function objectToRegExp(obj) {
+ return stringToRegExp(obj.expression, obj.flags);
+}
+
+(function() {
+
+ this.activate = function(ed, backwards) {
+ this.$editor = ed;
+ this.$startPos = this.$currentPos = ed.getCursorPosition();
+ this.$options.needle = '';
+ this.$options.backwards = backwards;
+ ed.keyBinding.addKeyboardHandler(this.$keyboardHandler);
+ this.$originalEditorOnPaste = ed.onPaste; ed.onPaste = this.onPaste.bind(this);
+ this.$mousedownHandler = ed.addEventListener('mousedown', this.onMouseDown.bind(this));
+ this.selectionFix(ed);
+ this.statusMessage(true);
+ };
+
+ this.deactivate = function(reset) {
+ this.cancelSearch(reset);
+ var ed = this.$editor;
+ ed.keyBinding.removeKeyboardHandler(this.$keyboardHandler);
+ if (this.$mousedownHandler) {
+ ed.removeEventListener('mousedown', this.$mousedownHandler);
+ delete this.$mousedownHandler;
+ }
+ ed.onPaste = this.$originalEditorOnPaste;
+ this.message('');
+ };
+
+ this.selectionFix = function(editor) {
+ if (editor.selection.isEmpty() && !editor.session.$emacsMark) {
+ editor.clearSelection();
+ }
+ };
+
+ this.highlight = function(regexp) {
+ var sess = this.$editor.session,
+ hl = sess.$isearchHighlight = sess.$isearchHighlight || sess.addDynamicMarker(
+ new SearchHighlight(null, "ace_isearch-result", "text"));
+ hl.setRegexp(regexp);
+ sess._emit("changeBackMarker"); // force highlight layer redraw
+ };
+
+ this.cancelSearch = function(reset) {
+ var e = this.$editor;
+ this.$prevNeedle = this.$options.needle;
+ this.$options.needle = '';
+ if (reset) {
+ e.moveCursorToPosition(this.$startPos);
+ this.$currentPos = this.$startPos;
+ } else {
+ e.pushEmacsMark && e.pushEmacsMark(this.$startPos, false);
+ }
+ this.highlight(null);
+ return Range.fromPoints(this.$currentPos, this.$currentPos);
+ };
+
+ this.highlightAndFindWithNeedle = function(moveToNext, needleUpdateFunc) {
+ if (!this.$editor) return null;
+ var options = this.$options;
+ if (needleUpdateFunc) {
+ options.needle = needleUpdateFunc.call(this, options.needle || '') || '';
+ }
+ if (options.needle.length === 0) {
+ this.statusMessage(true);
+ return this.cancelSearch(true);
+ }
+ options.start = this.$currentPos;
+ var session = this.$editor.session,
+ found = this.find(session),
+ shouldSelect = this.$editor.emacsMark ?
+ !!this.$editor.emacsMark() : !this.$editor.selection.isEmpty();
+ if (found) {
+ if (options.backwards) found = Range.fromPoints(found.end, found.start);
+ this.$editor.selection.setRange(Range.fromPoints(shouldSelect ? this.$startPos : found.end, found.end));
+ if (moveToNext) this.$currentPos = found.end;
+ this.highlight(options.re);
+ }
+
+ this.statusMessage(found);
+
+ return found;
+ };
+
+ this.addString = function(s) {
+ return this.highlightAndFindWithNeedle(false, function(needle) {
+ if (!isRegExp(needle))
+ return needle + s;
+ var reObj = regExpToObject(needle);
+ reObj.expression += s;
+ return objectToRegExp(reObj);
+ });
+ };
+
+ this.removeChar = function(c) {
+ return this.highlightAndFindWithNeedle(false, function(needle) {
+ if (!isRegExp(needle))
+ return needle.substring(0, needle.length-1);
+ var reObj = regExpToObject(needle);
+ reObj.expression = reObj.expression.substring(0, reObj.expression.length-1);
+ return objectToRegExp(reObj);
+ });
+ };
+
+ this.next = function(options) {
+ options = options || {};
+ this.$options.backwards = !!options.backwards;
+ this.$currentPos = this.$editor.getCursorPosition();
+ return this.highlightAndFindWithNeedle(true, function(needle) {
+ return options.useCurrentOrPrevSearch && needle.length === 0 ?
+ this.$prevNeedle || '' : needle;
+ });
+ };
+
+ this.onMouseDown = function(evt) {
+ this.deactivate();
+ return true;
+ };
+
+ this.onPaste = function(text) {
+ this.addString(text);
+ };
+
+ this.convertNeedleToRegExp = function() {
+ return this.highlightAndFindWithNeedle(false, function(needle) {
+ return isRegExp(needle) ? needle : stringToRegExp(needle, 'ig');
+ });
+ };
+
+ this.convertNeedleToString = function() {
+ return this.highlightAndFindWithNeedle(false, function(needle) {
+ return isRegExp(needle) ? regExpToObject(needle).expression : needle;
+ });
+ };
+
+ this.statusMessage = function(found) {
+ var options = this.$options, msg = '';
+ msg += options.backwards ? 'reverse-' : '';
+ msg += 'isearch: ' + options.needle;
+ msg += found ? '' : ' (not found)';
+ this.message(msg);
+ };
+
+ this.message = function(msg) {
+ if (this.$editor.showCommandLine) {
+ this.$editor.showCommandLine(msg);
+ this.$editor.focus();
+ } else {
+ console.log(msg);
+ }
+ };
+
+}).call(IncrementalSearch.prototype);
+
+
+exports.IncrementalSearch = IncrementalSearch;
+
+var dom = require('./lib/dom');
+dom.importCssString && dom.importCssString("\
+.ace_marker-layer .ace_isearch-result {\
+ position: absolute;\
+ z-index: 6;\
+ -moz-box-sizing: border-box;\
+ -webkit-box-sizing: border-box;\
+ box-sizing: border-box;\
+}\
+div.ace_isearch-result {\
+ border-radius: 4px;\
+ background-color: rgba(255, 200, 0, 0.5);\
+ box-shadow: 0 0 4px rgb(255, 200, 0);\
+}\
+.ace_dark div.ace_isearch-result {\
+ background-color: rgb(100, 110, 160);\
+ box-shadow: 0 0 4px rgb(80, 90, 140);\
+}", "incremental-search-highlighting");
+var commands = require("./commands/command_manager");
+(function() {
+ this.setupIncrementalSearch = function(editor, val) {
+ if (this.usesIncrementalSearch == val) return;
+ this.usesIncrementalSearch = val;
+ var iSearchCommands = iSearchCommandModule.iSearchStartCommands;
+ var method = val ? 'addCommands' : 'removeCommands';
+ this[method](iSearchCommands);
+ };
+}).call(commands.CommandManager.prototype);
+var Editor = require("./editor").Editor;
+require("./config").defineOptions(Editor.prototype, "editor", {
+ useIncrementalSearch: {
+ set: function(val) {
+ this.keyBinding.$handlers.forEach(function(handler) {
+ if (handler.setupIncrementalSearch) {
+ handler.setupIncrementalSearch(this, val);
+ }
+ });
+ this._emit('incrementalSearchSettingChanged', {isEnabled: val});
+ }
+ }
+});
+
+});
+
+ace.define("ace/keyboard/emacs",["require","exports","module","ace/lib/dom","ace/incremental_search","ace/commands/incremental_search_commands","ace/keyboard/hash_handler","ace/lib/keys"], function(require, exports, module) {
+"use strict";
+
+var dom = require("../lib/dom");
+require("../incremental_search");
+var iSearchCommandModule = require("../commands/incremental_search_commands");
+
+
+var screenToTextBlockCoordinates = function(x, y) {
+ var canvasPos = this.scroller.getBoundingClientRect();
+ var offsetX = x + this.scrollLeft - canvasPos.left - this.$padding;
+
+ var col = Math.floor(offsetX / this.characterWidth);
+
+ var row = Math.floor(
+ (y + this.scrollTop - canvasPos.top) / this.lineHeight
+ );
+
+ return this.session.screenToDocumentPosition(row, col, offsetX);
+};
+
+var HashHandler = require("./hash_handler").HashHandler;
+exports.handler = new HashHandler();
+
+exports.handler.isEmacs = true;
+exports.handler.$id = "ace/keyboard/emacs";
+
+var initialized = false;
+var $formerLongWords;
+var $formerLineStart;
+
+exports.handler.attach = function(editor) {
+ if (!initialized) {
+ initialized = true;
+ dom.importCssString('\
+ .emacs-mode .ace_cursor{\
+ border: 1px rgba(50,250,50,0.8) solid!important;\
+ -moz-box-sizing: border-box!important;\
+ -webkit-box-sizing: border-box!important;\
+ box-sizing: border-box!important;\
+ background-color: rgba(0,250,0,0.9);\
+ opacity: 0.5;\
+ }\
+ .emacs-mode .ace_hidden-cursors .ace_cursor{\
+ opacity: 1;\
+ background-color: transparent;\
+ }\
+ .emacs-mode .ace_overwrite-cursors .ace_cursor {\
+ opacity: 1;\
+ background-color: transparent;\
+ border-width: 0 0 2px 2px !important;\
+ }\
+ .emacs-mode .ace_text-layer {\
+ z-index: 4\
+ }\
+ .emacs-mode .ace_cursor-layer {\
+ z-index: 2\
+ }', 'emacsMode'
+ );
+ }
+ $formerLongWords = editor.session.$selectLongWords;
+ editor.session.$selectLongWords = true;
+ $formerLineStart = editor.session.$useEmacsStyleLineStart;
+ editor.session.$useEmacsStyleLineStart = true;
+
+ editor.session.$emacsMark = null; // the active mark
+ editor.session.$emacsMarkRing = editor.session.$emacsMarkRing || [];
+
+ editor.emacsMark = function() {
+ return this.session.$emacsMark;
+ };
+
+ editor.setEmacsMark = function(p) {
+ this.session.$emacsMark = p;
+ };
+
+ editor.pushEmacsMark = function(p, activate) {
+ var prevMark = this.session.$emacsMark;
+ if (prevMark)
+ this.session.$emacsMarkRing.push(prevMark);
+ if (!p || activate) this.setEmacsMark(p);
+ else this.session.$emacsMarkRing.push(p);
+ };
+
+ editor.popEmacsMark = function() {
+ var mark = this.emacsMark();
+ if (mark) { this.setEmacsMark(null); return mark; }
+ return this.session.$emacsMarkRing.pop();
+ };
+
+ editor.getLastEmacsMark = function(p) {
+ return this.session.$emacsMark || this.session.$emacsMarkRing.slice(-1)[0];
+ };
+
+ editor.emacsMarkForSelection = function(replacement) {
+ var sel = this.selection,
+ multiRangeLength = this.multiSelect ?
+ this.multiSelect.getAllRanges().length : 1,
+ selIndex = sel.index || 0,
+ markRing = this.session.$emacsMarkRing,
+ markIndex = markRing.length - (multiRangeLength - selIndex),
+ lastMark = markRing[markIndex] || sel.anchor;
+ if (replacement) {
+ markRing.splice(markIndex, 1,
+ "row" in replacement && "column" in replacement ?
+ replacement : undefined);
+ }
+ return lastMark;
+ }
+
+ editor.on("click", $resetMarkMode);
+ editor.on("changeSession", $kbSessionChange);
+ editor.renderer.screenToTextCoordinates = screenToTextBlockCoordinates;
+ editor.setStyle("emacs-mode");
+ editor.commands.addCommands(commands);
+ exports.handler.platform = editor.commands.platform;
+ editor.$emacsModeHandler = this;
+ editor.addEventListener('copy', this.onCopy);
+ editor.addEventListener('paste', this.onPaste);
+};
+
+exports.handler.detach = function(editor) {
+ delete editor.renderer.screenToTextCoordinates;
+ editor.session.$selectLongWords = $formerLongWords;
+ editor.session.$useEmacsStyleLineStart = $formerLineStart;
+ editor.removeEventListener("click", $resetMarkMode);
+ editor.removeEventListener("changeSession", $kbSessionChange);
+ editor.unsetStyle("emacs-mode");
+ editor.commands.removeCommands(commands);
+ editor.removeEventListener('copy', this.onCopy);
+ editor.removeEventListener('paste', this.onPaste);
+ editor.$emacsModeHandler = null;
+};
+
+var $kbSessionChange = function(e) {
+ if (e.oldSession) {
+ e.oldSession.$selectLongWords = $formerLongWords;
+ e.oldSession.$useEmacsStyleLineStart = $formerLineStart;
+ }
+
+ $formerLongWords = e.session.$selectLongWords;
+ e.session.$selectLongWords = true;
+ $formerLineStart = e.session.$useEmacsStyleLineStart;
+ e.session.$useEmacsStyleLineStart = true;
+
+ if (!e.session.hasOwnProperty('$emacsMark'))
+ e.session.$emacsMark = null;
+ if (!e.session.hasOwnProperty('$emacsMarkRing'))
+ e.session.$emacsMarkRing = [];
+};
+
+var $resetMarkMode = function(e) {
+ e.editor.session.$emacsMark = null;
+};
+
+var keys = require("../lib/keys").KEY_MODS;
+var eMods = {C: "ctrl", S: "shift", M: "alt", CMD: "command"};
+var combinations = ["C-S-M-CMD",
+ "S-M-CMD", "C-M-CMD", "C-S-CMD", "C-S-M",
+ "M-CMD", "S-CMD", "S-M", "C-CMD", "C-M", "C-S",
+ "CMD", "M", "S", "C"];
+combinations.forEach(function(c) {
+ var hashId = 0;
+ c.split("-").forEach(function(c) {
+ hashId = hashId | keys[eMods[c]];
+ });
+ eMods[hashId] = c.toLowerCase() + "-";
+});
+
+exports.handler.onCopy = function(e, editor) {
+ if (editor.$handlesEmacsOnCopy) return;
+ editor.$handlesEmacsOnCopy = true;
+ exports.handler.commands.killRingSave.exec(editor);
+ editor.$handlesEmacsOnCopy = false;
+};
+
+exports.handler.onPaste = function(e, editor) {
+ editor.pushEmacsMark(editor.getCursorPosition());
+};
+
+exports.handler.bindKey = function(key, command) {
+ if (typeof key == "object")
+ key = key[this.platform];
+ if (!key)
+ return;
+
+ var ckb = this.commandKeyBinding;
+ key.split("|").forEach(function(keyPart) {
+ keyPart = keyPart.toLowerCase();
+ ckb[keyPart] = command;
+ var keyParts = keyPart.split(" ").slice(0,-1);
+ keyParts.reduce(function(keyMapKeys, keyPart, i) {
+ var prefix = keyMapKeys[i-1] ? keyMapKeys[i-1] + ' ' : '';
+ return keyMapKeys.concat([prefix + keyPart]);
+ }, []).forEach(function(keyPart) {
+ if (!ckb[keyPart]) ckb[keyPart] = "null";
+ });
+ }, this);
+};
+
+exports.handler.getStatusText = function(editor, data) {
+ var str = "";
+ if (data.count)
+ str += data.count;
+ if (data.keyChain)
+ str += " " + data.keyChain
+ return str;
+};
+
+exports.handler.handleKeyboard = function(data, hashId, key, keyCode) {
+ if (keyCode === -1) return undefined;
+
+ var editor = data.editor;
+ editor._signal("changeStatus");
+ if (hashId == -1) {
+ editor.pushEmacsMark();
+ if (data.count) {
+ var str = new Array(data.count + 1).join(key);
+ data.count = null;
+ return {command: "insertstring", args: str};
+ }
+ }
+
+ var modifier = eMods[hashId];
+ if (modifier == "c-" || data.count) {
+ var count = parseInt(key[key.length - 1]);
+ if (typeof count === 'number' && !isNaN(count)) {
+ data.count = Math.max(data.count, 0) || 0;
+ data.count = 10 * data.count + count;
+ return {command: "null"};
+ }
+ }
+ if (modifier) key = modifier + key;
+ if (data.keyChain) key = data.keyChain += " " + key;
+ var command = this.commandKeyBinding[key];
+ data.keyChain = command == "null" ? key : "";
+ if (!command) return undefined;
+ if (command === "null") return {command: "null"};
+
+ if (command === "universalArgument") {
+ data.count = -4;
+ return {command: "null"};
+ }
+ var args;
+ if (typeof command !== "string") {
+ args = command.args;
+ if (command.command) command = command.command;
+ if (command === "goorselect") {
+ command = editor.emacsMark() ? args[1] : args[0];
+ args = null;
+ }
+ }
+
+ if (typeof command === "string") {
+ if (command === "insertstring" ||
+ command === "splitline" ||
+ command === "togglecomment") {
+ editor.pushEmacsMark();
+ }
+ command = this.commands[command] || editor.commands.commands[command];
+ if (!command) return undefined;
+ }
+
+ if (!command.readOnly && !command.isYank)
+ data.lastCommand = null;
+
+ if (!command.readOnly && editor.emacsMark())
+ editor.setEmacsMark(null)
+
+ if (data.count) {
+ var count = data.count;
+ data.count = 0;
+ if (!command || !command.handlesCount) {
+ return {
+ args: args,
+ command: {
+ exec: function(editor, args) {
+ for (var i = 0; i < count; i++)
+ command.exec(editor, args);
+ },
+ multiSelectAction: command.multiSelectAction
+ }
+ };
+ } else {
+ if (!args) args = {};
+ if (typeof args === 'object') args.count = count;
+ }
+ }
+
+ return {command: command, args: args};
+};
+
+exports.emacsKeys = {
+ "Up|C-p" : {command: "goorselect", args: ["golineup","selectup"]},
+ "Down|C-n" : {command: "goorselect", args: ["golinedown","selectdown"]},
+ "Left|C-b" : {command: "goorselect", args: ["gotoleft","selectleft"]},
+ "Right|C-f" : {command: "goorselect", args: ["gotoright","selectright"]},
+ "C-Left|M-b" : {command: "goorselect", args: ["gotowordleft","selectwordleft"]},
+ "C-Right|M-f" : {command: "goorselect", args: ["gotowordright","selectwordright"]},
+ "Home|C-a" : {command: "goorselect", args: ["gotolinestart","selecttolinestart"]},
+ "End|C-e" : {command: "goorselect", args: ["gotolineend","selecttolineend"]},
+ "C-Home|S-M-,": {command: "goorselect", args: ["gotostart","selecttostart"]},
+ "C-End|S-M-." : {command: "goorselect", args: ["gotoend","selecttoend"]},
+ "S-Up|S-C-p" : "selectup",
+ "S-Down|S-C-n" : "selectdown",
+ "S-Left|S-C-b" : "selectleft",
+ "S-Right|S-C-f" : "selectright",
+ "S-C-Left|S-M-b" : "selectwordleft",
+ "S-C-Right|S-M-f" : "selectwordright",
+ "S-Home|S-C-a" : "selecttolinestart",
+ "S-End|S-C-e" : "selecttolineend",
+ "S-C-Home" : "selecttostart",
+ "S-C-End" : "selecttoend",
+
+ "C-l" : "recenterTopBottom",
+ "M-s" : "centerselection",
+ "M-g": "gotoline",
+ "C-x C-p": "selectall",
+ "C-Down": {command: "goorselect", args: ["gotopagedown","selectpagedown"]},
+ "C-Up": {command: "goorselect", args: ["gotopageup","selectpageup"]},
+ "PageDown|C-v": {command: "goorselect", args: ["gotopagedown","selectpagedown"]},
+ "PageUp|M-v": {command: "goorselect", args: ["gotopageup","selectpageup"]},
+ "S-C-Down": "selectpagedown",
+ "S-C-Up": "selectpageup",
+
+ "C-s": "iSearch",
+ "C-r": "iSearchBackwards",
+
+ "M-C-s": "findnext",
+ "M-C-r": "findprevious",
+ "S-M-5": "replace",
+ "Backspace": "backspace",
+ "Delete|C-d": "del",
+ "Return|C-m": {command: "insertstring", args: "\n"}, // "newline"
+ "C-o": "splitline",
+
+ "M-d|C-Delete": {command: "killWord", args: "right"},
+ "C-Backspace|M-Backspace|M-Delete": {command: "killWord", args: "left"},
+ "C-k": "killLine",
+
+ "C-y|S-Delete": "yank",
+ "M-y": "yankRotate",
+ "C-g": "keyboardQuit",
+
+ "C-w|C-S-W": "killRegion",
+ "M-w": "killRingSave",
+ "C-Space": "setMark",
+ "C-x C-x": "exchangePointAndMark",
+
+ "C-t": "transposeletters",
+ "M-u": "touppercase", // Doesn't work
+ "M-l": "tolowercase",
+ "M-/": "autocomplete", // Doesn't work
+ "C-u": "universalArgument",
+
+ "M-;": "togglecomment",
+
+ "C-/|C-x u|S-C--|C-z": "undo",
+ "S-C-/|S-C-x u|C--|S-C-z": "redo", // infinite undo?
+ "C-x r": "selectRectangularRegion",
+ "M-x": {command: "focusCommandLine", args: "M-x "}
+};
+
+
+exports.handler.bindKeys(exports.emacsKeys);
+
+exports.handler.addCommands({
+ recenterTopBottom: function(editor) {
+ var renderer = editor.renderer;
+ var pos = renderer.$cursorLayer.getPixelPosition();
+ var h = renderer.$size.scrollerHeight - renderer.lineHeight;
+ var scrollTop = renderer.scrollTop;
+ if (Math.abs(pos.top - scrollTop) < 2) {
+ scrollTop = pos.top - h;
+ } else if (Math.abs(pos.top - scrollTop - h * 0.5) < 2) {
+ scrollTop = pos.top;
+ } else {
+ scrollTop = pos.top - h * 0.5;
+ }
+ editor.session.setScrollTop(scrollTop);
+ },
+ selectRectangularRegion: function(editor) {
+ editor.multiSelect.toggleBlockSelection();
+ },
+ setMark: {
+ exec: function(editor, args) {
+
+ if (args && args.count) {
+ if (editor.inMultiSelectMode) editor.forEachSelection(moveToMark);
+ else moveToMark();
+ moveToMark();
+ return;
+ }
+
+ var mark = editor.emacsMark(),
+ ranges = editor.selection.getAllRanges(),
+ rangePositions = ranges.map(function(r) { return {row: r.start.row, column: r.start.column}; }),
+ transientMarkModeActive = true,
+ hasNoSelection = ranges.every(function(range) { return range.isEmpty(); });
+ if (transientMarkModeActive && (mark || !hasNoSelection)) {
+ if (editor.inMultiSelectMode) editor.forEachSelection({exec: editor.clearSelection.bind(editor)});
+ else editor.clearSelection();
+ if (mark) editor.pushEmacsMark(null);
+ return;
+ }
+
+ if (!mark) {
+ rangePositions.forEach(function(pos) { editor.pushEmacsMark(pos); });
+ editor.setEmacsMark(rangePositions[rangePositions.length-1]);
+ return;
+ }
+
+ function moveToMark() {
+ var mark = editor.popEmacsMark();
+ mark && editor.moveCursorToPosition(mark);
+ }
+
+ },
+ readOnly: true,
+ handlesCount: true
+ },
+ exchangePointAndMark: {
+ exec: function exchangePointAndMark$exec(editor, args) {
+ var sel = editor.selection;
+ if (!args.count && !sel.isEmpty()) { // just invert selection
+ sel.setSelectionRange(sel.getRange(), !sel.isBackwards());
+ return;
+ }
+
+ if (args.count) { // replace mark and point
+ var pos = {row: sel.lead.row, column: sel.lead.column};
+ sel.clearSelection();
+ sel.moveCursorToPosition(editor.emacsMarkForSelection(pos));
+ } else { // create selection to last mark
+ sel.selectToPosition(editor.emacsMarkForSelection());
+ }
+ },
+ readOnly: true,
+ handlesCount: true,
+ multiSelectAction: "forEach"
+ },
+ killWord: {
+ exec: function(editor, dir) {
+ editor.clearSelection();
+ if (dir == "left")
+ editor.selection.selectWordLeft();
+ else
+ editor.selection.selectWordRight();
+
+ var range = editor.getSelectionRange();
+ var text = editor.session.getTextRange(range);
+ exports.killRing.add(text);
+
+ editor.session.remove(range);
+ editor.clearSelection();
+ },
+ multiSelectAction: "forEach"
+ },
+ killLine: function(editor) {
+ editor.pushEmacsMark(null);
+ editor.clearSelection();
+ var range = editor.getSelectionRange();
+ var line = editor.session.getLine(range.start.row);
+ range.end.column = line.length;
+ line = line.substr(range.start.column)
+
+ var foldLine = editor.session.getFoldLine(range.start.row);
+ if (foldLine && range.end.row != foldLine.end.row) {
+ range.end.row = foldLine.end.row;
+ line = "x";
+ }
+ if (/^\s*$/.test(line)) {
+ range.end.row++;
+ line = editor.session.getLine(range.end.row);
+ range.end.column = /^\s*$/.test(line) ? line.length : 0;
+ }
+ var text = editor.session.getTextRange(range);
+ if (editor.prevOp.command == this)
+ exports.killRing.append(text);
+ else
+ exports.killRing.add(text);
+
+ editor.session.remove(range);
+ editor.clearSelection();
+ },
+ yank: function(editor) {
+ editor.onPaste(exports.killRing.get() || '');
+ editor.keyBinding.$data.lastCommand = "yank";
+ },
+ yankRotate: function(editor) {
+ if (editor.keyBinding.$data.lastCommand != "yank")
+ return;
+ editor.undo();
+ editor.session.$emacsMarkRing.pop(); // also undo recording mark
+ editor.onPaste(exports.killRing.rotate());
+ editor.keyBinding.$data.lastCommand = "yank";
+ },
+ killRegion: {
+ exec: function(editor) {
+ exports.killRing.add(editor.getCopyText());
+ editor.commands.byName.cut.exec(editor);
+ editor.setEmacsMark(null);
+ },
+ readOnly: true,
+ multiSelectAction: "forEach"
+ },
+ killRingSave: {
+ exec: function(editor) {
+
+ editor.$handlesEmacsOnCopy = true;
+ var marks = editor.session.$emacsMarkRing.slice(),
+ deselectedMarks = [];
+ exports.killRing.add(editor.getCopyText());
+
+ setTimeout(function() {
+ function deselect() {
+ var sel = editor.selection, range = sel.getRange(),
+ pos = sel.isBackwards() ? range.end : range.start;
+ deselectedMarks.push({row: pos.row, column: pos.column});
+ sel.clearSelection();
+ }
+ editor.$handlesEmacsOnCopy = false;
+ if (editor.inMultiSelectMode) editor.forEachSelection({exec: deselect});
+ else deselect();
+ editor.session.$emacsMarkRing = marks.concat(deselectedMarks.reverse());
+ }, 0);
+ },
+ readOnly: true
+ },
+ keyboardQuit: function(editor) {
+ editor.selection.clearSelection();
+ editor.setEmacsMark(null);
+ editor.keyBinding.$data.count = null;
+ },
+ focusCommandLine: function(editor, arg) {
+ if (editor.showCommandLine)
+ editor.showCommandLine(arg);
+ }
+});
+
+exports.handler.addCommands(iSearchCommandModule.iSearchStartCommands);
+
+var commands = exports.handler.commands;
+commands.yank.isYank = true;
+commands.yankRotate.isYank = true;
+
+exports.killRing = {
+ $data: [],
+ add: function(str) {
+ str && this.$data.push(str);
+ if (this.$data.length > 30)
+ this.$data.shift();
+ },
+ append: function(str) {
+ var idx = this.$data.length - 1;
+ var text = this.$data[idx] || "";
+ if (str) text += str;
+ if (text) this.$data[idx] = text;
+ },
+ get: function(n) {
+ n = n || 1;
+ return this.$data.slice(this.$data.length-n, this.$data.length).reverse().join('\n');
+ },
+ pop: function() {
+ if (this.$data.length > 1)
+ this.$data.pop();
+ return this.get();
+ },
+ rotate: function() {
+ this.$data.unshift(this.$data.pop());
+ return this.get();
+ }
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/keybinding-vim.js b/www/wiki/extensions/CodeEditor/modules/ace/keybinding-vim.js
new file mode 100644
index 00000000..5b0f378e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/keybinding-vim.js
@@ -0,0 +1,5598 @@
+ace.define("ace/keyboard/vim",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/dom","ace/lib/oop","ace/lib/keys","ace/lib/event","ace/search","ace/lib/useragent","ace/search_highlight","ace/commands/multi_select_commands","ace/mode/text","ace/multi_select"], function(require, exports, module) {
+ 'use strict';
+
+ function log() {
+ var d = "";
+ function format(p) {
+ if (typeof p != "object")
+ return p + "";
+ if ("line" in p) {
+ return p.line + ":" + p.ch;
+ }
+ if ("anchor" in p) {
+ return format(p.anchor) + "->" + format(p.head);
+ }
+ if (Array.isArray(p))
+ return "[" + p.map(function(x) {
+ return format(x);
+ }) + "]";
+ return JSON.stringify(p);
+ }
+ for (var i = 0; i < arguments.length; i++) {
+ var p = arguments[i];
+ var f = format(p);
+ d += f + " ";
+ }
+ console.log(d);
+ }
+ var Range = require("../range").Range;
+ var EventEmitter = require("../lib/event_emitter").EventEmitter;
+ var dom = require("../lib/dom");
+ var oop = require("../lib/oop");
+ var KEYS = require("../lib/keys");
+ var event = require("../lib/event");
+ var Search = require("../search").Search;
+ var useragent = require("../lib/useragent");
+ var SearchHighlight = require("../search_highlight").SearchHighlight;
+ var multiSelectCommands = require("../commands/multi_select_commands");
+ var TextModeTokenRe = require("../mode/text").Mode.prototype.tokenRe;
+ require("../multi_select");
+
+ var CodeMirror = function(ace) {
+ this.ace = ace;
+ this.state = {};
+ this.marks = {};
+ this.$uid = 0;
+ this.onChange = this.onChange.bind(this);
+ this.onSelectionChange = this.onSelectionChange.bind(this);
+ this.onBeforeEndOperation = this.onBeforeEndOperation.bind(this);
+ this.ace.on('change', this.onChange);
+ this.ace.on('changeSelection', this.onSelectionChange);
+ this.ace.on('beforeEndOperation', this.onBeforeEndOperation);
+ };
+ CodeMirror.Pos = function(line, ch) {
+ if (!(this instanceof Pos)) return new Pos(line, ch);
+ this.line = line; this.ch = ch;
+ };
+ CodeMirror.defineOption = function(name, val, setter) {};
+ CodeMirror.commands = {
+ redo: function(cm) { cm.ace.redo(); },
+ undo: function(cm) { cm.ace.undo(); },
+ newlineAndIndent: function(cm) { cm.ace.insert("\n"); }
+ };
+ CodeMirror.keyMap = {};
+ CodeMirror.addClass = CodeMirror.rmClass =
+ CodeMirror.e_stop = function() {};
+ CodeMirror.keyName = function(e) {
+ if (e.key) return e.key;
+ var key = (KEYS[e.keyCode] || "");
+ if (key.length == 1) key = key.toUpperCase();
+ key = event.getModifierString(e).replace(/(^|-)\w/g, function(m) {
+ return m.toUpperCase();
+ }) + key;
+ return key;
+ };
+ CodeMirror.keyMap['default'] = function(key) {
+ return function(cm) {
+ var cmd = cm.ace.commands.commandKeyBinding[key.toLowerCase()];
+ return cmd && cm.ace.execCommand(cmd) !== false;
+ };
+ };
+ CodeMirror.lookupKey = function lookupKey(key, map, handle) {
+ if (typeof map == "string")
+ map = CodeMirror.keyMap[map];
+ var found = typeof map == "function" ? map(key) : map[key];
+ if (found === false) return "nothing";
+ if (found === "...") return "multi";
+ if (found != null && handle(found)) return "handled";
+
+ if (map.fallthrough) {
+ if (!Array.isArray(map.fallthrough))
+ return lookupKey(key, map.fallthrough, handle);
+ for (var i = 0; i < map.fallthrough.length; i++) {
+ var result = lookupKey(key, map.fallthrough[i], handle);
+ if (result) return result;
+ }
+ }
+ };
+
+ CodeMirror.signal = function(o, name, e) { return o._signal(name, e) };
+ CodeMirror.on = event.addListener;
+ CodeMirror.off = event.removeListener;
+ CodeMirror.isWordChar = function(ch) {
+ if (ch < "\x7f") return /^\w$/.test(ch);
+ TextModeTokenRe.lastIndex = 0;
+ return TextModeTokenRe.test(ch);
+ };
+
+(function() {
+ oop.implement(CodeMirror.prototype, EventEmitter);
+
+ this.destroy = function() {
+ this.ace.off('change', this.onChange);
+ this.ace.off('changeSelection', this.onSelectionChange);
+ this.ace.off('beforeEndOperation', this.onBeforeEndOperation);
+ this.removeOverlay();
+ };
+ this.virtualSelectionMode = function() {
+ return this.ace.inVirtualSelectionMode && this.ace.selection.index;
+ };
+ this.onChange = function(delta) {
+ var change = { text: delta.action[0] == 'i' ? delta.lines : [] };
+ var curOp = this.curOp = this.curOp || {};
+ if (!curOp.changeHandlers)
+ curOp.changeHandlers = this._eventRegistry["change"] && this._eventRegistry["change"].slice();
+ if (this.virtualSelectionMode()) return;
+ if (!curOp.lastChange) {
+ curOp.lastChange = curOp.change = change;
+ } else {
+ curOp.lastChange.next = curOp.lastChange = change;
+ }
+ this.$updateMarkers(delta);
+ };
+ this.onSelectionChange = function() {
+ var curOp = this.curOp = this.curOp || {};
+ if (!curOp.cursorActivityHandlers)
+ curOp.cursorActivityHandlers = this._eventRegistry["cursorActivity"] && this._eventRegistry["cursorActivity"].slice();
+ this.curOp.cursorActivity = true;
+ if (this.ace.inMultiSelectMode) {
+ this.ace.keyBinding.removeKeyboardHandler(multiSelectCommands.keyboardHandler);
+ }
+ };
+ this.operation = function(fn, force) {
+ if (!force && this.curOp || force && this.curOp && this.curOp.force) {
+ return fn();
+ }
+ if (force || !this.ace.curOp) {
+ if (this.curOp)
+ this.onBeforeEndOperation();
+ }
+ if (!this.ace.curOp) {
+ var prevOp = this.ace.prevOp;
+ this.ace.startOperation({
+ command: { name: "vim", scrollIntoView: "cursor" }
+ });
+ }
+ var curOp = this.curOp = this.curOp || {};
+ this.curOp.force = force;
+ var result = fn();
+ if (this.ace.curOp && this.ace.curOp.command.name == "vim") {
+ this.ace.endOperation();
+ if (!curOp.cursorActivity && !curOp.lastChange && prevOp)
+ this.ace.prevOp = prevOp;
+ }
+ if (force || !this.ace.curOp) {
+ if (this.curOp)
+ this.onBeforeEndOperation();
+ }
+ return result;
+ };
+ this.onBeforeEndOperation = function() {
+ var op = this.curOp;
+ if (op) {
+ if (op.change) { this.signal("change", op.change, op); }
+ if (op && op.cursorActivity) { this.signal("cursorActivity", null, op); }
+ this.curOp = null;
+ }
+ };
+
+ this.signal = function(eventName, e, handlers) {
+ var listeners = handlers ? handlers[eventName + "Handlers"]
+ : (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](this, e);
+ };
+ this.firstLine = function() { return 0; };
+ this.lastLine = function() { return this.ace.session.getLength() - 1; };
+ this.lineCount = function() { return this.ace.session.getLength(); };
+ this.setCursor = function(line, ch) {
+ if (typeof line === 'object') {
+ ch = line.ch;
+ line = line.line;
+ }
+ if (!this.ace.inVirtualSelectionMode)
+ this.ace.exitMultiSelectMode();
+ this.ace.session.unfold({row: line, column: ch});
+ this.ace.selection.moveTo(line, ch);
+ };
+ this.getCursor = function(p) {
+ var sel = this.ace.selection;
+ var pos = p == 'anchor' ? (sel.isEmpty() ? sel.lead : sel.anchor) :
+ p == 'head' || !p ? sel.lead : sel.getRange()[p];
+ return toCmPos(pos);
+ };
+ this.listSelections = function(p) {
+ var ranges = this.ace.multiSelect.rangeList.ranges;
+ if (!ranges.length || this.ace.inVirtualSelectionMode)
+ return [{anchor: this.getCursor('anchor'), head: this.getCursor('head')}];
+ return ranges.map(function(r) {
+ return {
+ anchor: this.clipPos(toCmPos(r.cursor == r.end ? r.start : r.end)),
+ head: this.clipPos(toCmPos(r.cursor))
+ };
+ }, this);
+ };
+ this.setSelections = function(p, primIndex) {
+ var sel = this.ace.multiSelect;
+ var ranges = p.map(function(x) {
+ var anchor = toAcePos(x.anchor);
+ var head = toAcePos(x.head);
+ var r = Range.comparePoints(anchor, head) < 0
+ ? new Range.fromPoints(anchor, head)
+ : new Range.fromPoints(head, anchor);
+ r.cursor = Range.comparePoints(r.start, head) ? r.end : r.start;
+ return r;
+ });
+
+ if (this.ace.inVirtualSelectionMode) {
+ this.ace.selection.fromOrientedRange(ranges[0]);
+ return;
+ }
+ if (!primIndex) {
+ ranges = ranges.reverse();
+ } else if (ranges[primIndex]) {
+ ranges.push(ranges.splice(primIndex, 1)[0]);
+ }
+ sel.toSingleRange(ranges[0].clone());
+ var session = this.ace.session;
+ for (var i = 0; i < ranges.length; i++) {
+ var range = session.$clipRangeToDocument(ranges[i]); // todo why ace doesn't do this?
+ sel.addRange(range);
+ }
+ };
+ this.setSelection = function(a, h, options) {
+ var sel = this.ace.selection;
+ sel.moveTo(a.line, a.ch);
+ sel.selectTo(h.line, h.ch);
+ if (options && options.origin == '*mouse') {
+ this.onBeforeEndOperation();
+ }
+ };
+ this.somethingSelected = function(p) {
+ return !this.ace.selection.isEmpty();
+ };
+ this.clipPos = function(p) {
+ var pos = this.ace.session.$clipPositionToDocument(p.line, p.ch);
+ return toCmPos(pos);
+ };
+ this.markText = function(cursor) {
+ return {clear: function() {}, find: function() {}};
+ };
+ this.$updateMarkers = function(delta) {
+ var isInsert = delta.action == "insert";
+ var start = delta.start;
+ var end = delta.end;
+ var rowShift = (end.row - start.row) * (isInsert ? 1 : -1);
+ var colShift = (end.column - start.column) * (isInsert ? 1 : -1);
+ if (isInsert) end = start;
+
+ for (var i in this.marks) {
+ var point = this.marks[i];
+ var cmp = Range.comparePoints(point, start);
+ if (cmp < 0) {
+ continue; // delta starts after the range
+ }
+ if (cmp === 0) {
+ if (isInsert) {
+ if (point.bias == 1) {
+ cmp = 1;
+ } else {
+ point.bias == -1;
+ continue;
+ }
+ }
+ }
+ var cmp2 = isInsert ? cmp : Range.comparePoints(point, end);
+ if (cmp2 > 0) {
+ point.row += rowShift;
+ point.column += point.row == end.row ? colShift : 0;
+ continue;
+ }
+ if (!isInsert && cmp2 <= 0) {
+ point.row = start.row;
+ point.column = start.column;
+ if (cmp2 === 0)
+ point.bias = 1;
+ }
+ }
+ };
+ var Marker = function(cm, id, row, column) {
+ this.cm = cm;
+ this.id = id;
+ this.row = row;
+ this.column = column;
+ cm.marks[this.id] = this;
+ };
+ Marker.prototype.clear = function() { delete this.cm.marks[this.id] };
+ Marker.prototype.find = function() { return toCmPos(this) };
+ this.setBookmark = function(cursor, options) {
+ var bm = new Marker(this, this.$uid++, cursor.line, cursor.ch);
+ if (!options || !options.insertLeft)
+ bm.$insertRight = true;
+ this.marks[bm.id] = bm;
+ return bm;
+ };
+ this.moveH = function(increment, unit) {
+ if (unit == 'char') {
+ var sel = this.ace.selection;
+ sel.clearSelection();
+ sel.moveCursorBy(0, increment);
+ }
+ };
+ this.findPosV = function(start, amount, unit, goalColumn) {
+ if (unit == 'page') {
+ var renderer = this.ace.renderer;
+ var config = renderer.layerConfig;
+ amount = amount * Math.floor(config.height / config.lineHeight);
+ unit = 'line';
+ }
+ if (unit == 'line') {
+ var screenPos = this.ace.session.documentToScreenPosition(start.line, start.ch);
+ if (goalColumn != null)
+ screenPos.column = goalColumn;
+ screenPos.row += amount;
+ screenPos.row = Math.min(Math.max(0, screenPos.row), this.ace.session.getScreenLength() - 1);
+ var pos = this.ace.session.screenToDocumentPosition(screenPos.row, screenPos.column);
+ return toCmPos(pos);
+ } else {
+ debugger;
+ }
+ };
+ this.charCoords = function(pos, mode) {
+ if (mode == 'div' || !mode) {
+ var sc = this.ace.session.documentToScreenPosition(pos.line, pos.ch);
+ return {left: sc.column, top: sc.row};
+ }if (mode == 'local') {
+ var renderer = this.ace.renderer;
+ var sc = this.ace.session.documentToScreenPosition(pos.line, pos.ch);
+ var lh = renderer.layerConfig.lineHeight;
+ var cw = renderer.layerConfig.characterWidth;
+ var top = lh * sc.row;
+ return {left: sc.column * cw, top: top, bottom: top + lh};
+ }
+ };
+ this.coordsChar = function(pos, mode) {
+ var renderer = this.ace.renderer;
+ if (mode == 'local') {
+ var row = Math.max(0, Math.floor(pos.top / renderer.lineHeight));
+ var col = Math.max(0, Math.floor(pos.left / renderer.characterWidth));
+ var ch = renderer.session.screenToDocumentPosition(row, col);
+ return toCmPos(ch);
+ } else if (mode == 'div') {
+ throw "not implemented";
+ }
+ };
+ this.getSearchCursor = function(query, pos, caseFold) {
+ var caseSensitive = false;
+ var isRegexp = false;
+ if (query instanceof RegExp && !query.global) {
+ caseSensitive = !query.ignoreCase;
+ query = query.source;
+ isRegexp = true;
+ }
+ var search = new Search();
+ if (pos.ch == undefined) pos.ch = Number.MAX_VALUE;
+ var acePos = {row: pos.line, column: pos.ch};
+ var cm = this;
+ var last = null;
+ return {
+ findNext: function() { return this.find(false) },
+ findPrevious: function() {return this.find(true) },
+ find: function(back) {
+ search.setOptions({
+ needle: query,
+ caseSensitive: caseSensitive,
+ wrap: false,
+ backwards: back,
+ regExp: isRegexp,
+ start: last || acePos
+ });
+ var range = search.find(cm.ace.session);
+ if (range && range.isEmpty()) {
+ if (cm.getLine(range.start.row).length == range.start.column) {
+ search.$options.start = range;
+ range = search.find(cm.ace.session);
+ }
+ }
+ last = range;
+ return last;
+ },
+ from: function() { return last && toCmPos(last.start) },
+ to: function() { return last && toCmPos(last.end) },
+ replace: function(text) {
+ if (last) {
+ last.end = cm.ace.session.doc.replace(last, text);
+ }
+ }
+ };
+ };
+ this.scrollTo = function(x, y) {
+ var renderer = this.ace.renderer;
+ var config = renderer.layerConfig;
+ var maxHeight = config.maxHeight;
+ maxHeight -= (renderer.$size.scrollerHeight - renderer.lineHeight) * renderer.$scrollPastEnd;
+ if (y != null) this.ace.session.setScrollTop(Math.max(0, Math.min(y, maxHeight)));
+ if (x != null) this.ace.session.setScrollLeft(Math.max(0, Math.min(x, config.width)));
+ };
+ this.scrollInfo = function() { return 0; };
+ this.scrollIntoView = function(pos, margin) {
+ if (pos) {
+ var renderer = this.ace.renderer;
+ var viewMargin = { "top": 0, "bottom": margin };
+ renderer.scrollCursorIntoView(toAcePos(pos),
+ (renderer.lineHeight * 2) / renderer.$size.scrollerHeight, viewMargin);
+ }
+ };
+ this.getLine = function(row) { return this.ace.session.getLine(row) };
+ this.getRange = function(s, e) {
+ return this.ace.session.getTextRange(new Range(s.line, s.ch, e.line, e.ch));
+ };
+ this.replaceRange = function(text, s, e) {
+ if (!e) e = s;
+ return this.ace.session.replace(new Range(s.line, s.ch, e.line, e.ch), text);
+ };
+ this.replaceSelections = function(p) {
+ var sel = this.ace.selection;
+ if (this.ace.inVirtualSelectionMode) {
+ this.ace.session.replace(sel.getRange(), p[0] || "");
+ return;
+ }
+ sel.inVirtualSelectionMode = true;
+ var ranges = sel.rangeList.ranges;
+ if (!ranges.length) ranges = [this.ace.multiSelect.getRange()];
+ for (var i = ranges.length; i--;)
+ this.ace.session.replace(ranges[i], p[i] || "");
+ sel.inVirtualSelectionMode = false;
+ };
+ this.getSelection = function() {
+ return this.ace.getSelectedText();
+ };
+ this.getSelections = function() {
+ return this.listSelections().map(function(x) {
+ return this.getRange(x.anchor, x.head);
+ }, this);
+ };
+ this.getInputField = function() {
+ return this.ace.textInput.getElement();
+ };
+ this.getWrapperElement = function() {
+ return this.ace.containter;
+ };
+ var optMap = {
+ indentWithTabs: "useSoftTabs",
+ indentUnit: "tabSize",
+ tabSize: "tabSize",
+ firstLineNumber: "firstLineNumber",
+ readOnly: "readOnly"
+ };
+ this.setOption = function(name, val) {
+ this.state[name] = val;
+ switch (name) {
+ case 'indentWithTabs':
+ name = optMap[name];
+ val = !val;
+ break;
+ default:
+ name = optMap[name];
+ }
+ if (name)
+ this.ace.setOption(name, val);
+ };
+ this.getOption = function(name, val) {
+ var aceOpt = optMap[name];
+ if (aceOpt)
+ val = this.ace.getOption(aceOpt);
+ switch (name) {
+ case 'indentWithTabs':
+ name = optMap[name];
+ return !val;
+ }
+ return aceOpt ? val : this.state[name];
+ };
+ this.toggleOverwrite = function(on) {
+ this.state.overwrite = on;
+ return this.ace.setOverwrite(on);
+ };
+ this.addOverlay = function(o) {
+ if (!this.$searchHighlight || !this.$searchHighlight.session) {
+ var highlight = new SearchHighlight(null, "ace_highlight-marker", "text");
+ var marker = this.ace.session.addDynamicMarker(highlight);
+ highlight.id = marker.id;
+ highlight.session = this.ace.session;
+ highlight.destroy = function(o) {
+ highlight.session.off("change", highlight.updateOnChange);
+ highlight.session.off("changeEditor", highlight.destroy);
+ highlight.session.removeMarker(highlight.id);
+ highlight.session = null;
+ };
+ highlight.updateOnChange = function(delta) {
+ var row = delta.start.row;
+ if (row == delta.end.row) highlight.cache[row] = undefined;
+ else highlight.cache.splice(row, highlight.cache.length);
+ };
+ highlight.session.on("changeEditor", highlight.destroy);
+ highlight.session.on("change", highlight.updateOnChange);
+ }
+ var re = new RegExp(o.query.source, "gmi");
+ this.$searchHighlight = o.highlight = highlight;
+ this.$searchHighlight.setRegexp(re);
+ this.ace.renderer.updateBackMarkers();
+ };
+ this.removeOverlay = function(o) {
+ if (this.$searchHighlight && this.$searchHighlight.session) {
+ this.$searchHighlight.destroy();
+ }
+ };
+ this.getScrollInfo = function() {
+ var renderer = this.ace.renderer;
+ var config = renderer.layerConfig;
+ return {
+ left: renderer.scrollLeft,
+ top: renderer.scrollTop,
+ height: config.maxHeight,
+ width: config.width,
+ clientHeight: config.height,
+ clientWidth: config.width
+ };
+ };
+ this.getValue = function() {
+ return this.ace.getValue();
+ };
+ this.setValue = function(v) {
+ return this.ace.setValue(v);
+ };
+ this.getTokenTypeAt = function(pos) {
+ var token = this.ace.session.getTokenAt(pos.line, pos.ch);
+ return token && /comment|string/.test(token.type) ? "string" : "";
+ };
+ this.findMatchingBracket = function(pos) {
+ var m = this.ace.session.findMatchingBracket(toAcePos(pos));
+ return {to: m && toCmPos(m)};
+ };
+ this.indentLine = function(line, method) {
+ if (method === true)
+ this.ace.session.indentRows(line, line, "\t");
+ else if (method === false)
+ this.ace.session.outdentRows(new Range(line, 0, line, 0));
+ };
+ this.indexFromPos = function(pos) {
+ return this.ace.session.doc.positionToIndex(toAcePos(pos));
+ };
+ this.posFromIndex = function(index) {
+ return toCmPos(this.ace.session.doc.indexToPosition(index));
+ };
+ this.focus = function(index) {
+ return this.ace.focus();
+ };
+ this.blur = function(index) {
+ return this.ace.blur();
+ };
+ this.defaultTextHeight = function(index) {
+ return this.ace.renderer.layerConfig.lineHeight;
+ };
+ this.scanForBracket = function(pos, dir, _, options) {
+ var re = options.bracketRegex.source;
+ if (dir == 1) {
+ var m = this.ace.session.$findClosingBracket(re.slice(1, 2), toAcePos(pos), /paren|text/);
+ } else {
+ var m = this.ace.session.$findOpeningBracket(re.slice(-2, -1), {row: pos.line, column: pos.ch + 1}, /paren|text/);
+ }
+ return m && {pos: toCmPos(m)};
+ };
+ this.refresh = function() {
+ return this.ace.resize(true);
+ };
+ this.getMode = function() {
+ return { name : this.getOption("mode") };
+ }
+}).call(CodeMirror.prototype);
+ function toAcePos(cmPos) {
+ return {row: cmPos.line, column: cmPos.ch};
+ }
+ function toCmPos(acePos) {
+ return new Pos(acePos.row, acePos.column);
+ }
+
+ var StringStream = CodeMirror.StringStream = function(string, tabSize) {
+ this.pos = this.start = 0;
+ this.string = string;
+ this.tabSize = tabSize || 8;
+ this.lastColumnPos = this.lastColumnValue = 0;
+ this.lineStart = 0;
+ };
+
+ StringStream.prototype = {
+ eol: function() {return this.pos >= this.string.length;},
+ sol: function() {return this.pos == this.lineStart;},
+ peek: function() {return this.string.charAt(this.pos) || undefined;},
+ next: function() {
+ if (this.pos < this.string.length)
+ return this.string.charAt(this.pos++);
+ },
+ eat: function(match) {
+ var ch = this.string.charAt(this.pos);
+ if (typeof match == "string") var ok = ch == match;
+ else var ok = ch && (match.test ? match.test(ch) : match(ch));
+ if (ok) {++this.pos; return ch;}
+ },
+ eatWhile: function(match) {
+ var start = this.pos;
+ while (this.eat(match)){}
+ return this.pos > start;
+ },
+ eatSpace: function() {
+ var start = this.pos;
+ while (/[\s\u00a0]/.test(this.string.charAt(this.pos))) ++this.pos;
+ return this.pos > start;
+ },
+ skipToEnd: function() {this.pos = this.string.length;},
+ skipTo: function(ch) {
+ var found = this.string.indexOf(ch, this.pos);
+ if (found > -1) {this.pos = found; return true;}
+ },
+ backUp: function(n) {this.pos -= n;},
+ column: function() {
+ throw "not implemented";
+ },
+ indentation: function() {
+ throw "not implemented";
+ },
+ match: function(pattern, consume, caseInsensitive) {
+ if (typeof pattern == "string") {
+ var cased = function(str) {return caseInsensitive ? str.toLowerCase() : str;};
+ var substr = this.string.substr(this.pos, pattern.length);
+ if (cased(substr) == cased(pattern)) {
+ if (consume !== false) this.pos += pattern.length;
+ return true;
+ }
+ } else {
+ var match = this.string.slice(this.pos).match(pattern);
+ if (match && match.index > 0) return null;
+ if (match && consume !== false) this.pos += match[0].length;
+ return match;
+ }
+ },
+ current: function(){return this.string.slice(this.start, this.pos);},
+ hideFirstChars: function(n, inner) {
+ this.lineStart += n;
+ try { return inner(); }
+ finally { this.lineStart -= n; }
+ }
+ };
+CodeMirror.defineExtension = function(name, fn) {
+ CodeMirror.prototype[name] = fn;
+};
+dom.importCssString(".normal-mode .ace_cursor{\
+ border: 1px solid red;\
+ background-color: red;\
+ opacity: 0.5;\
+}\
+.normal-mode .ace_hidden-cursors .ace_cursor{\
+ background-color: transparent;\
+}\
+.ace_dialog {\
+ position: absolute;\
+ left: 0; right: 0;\
+ background: white;\
+ z-index: 15;\
+ padding: .1em .8em;\
+ overflow: hidden;\
+ color: #333;\
+}\
+.ace_dialog-top {\
+ border-bottom: 1px solid #eee;\
+ top: 0;\
+}\
+.ace_dialog-bottom {\
+ border-top: 1px solid #eee;\
+ bottom: 0;\
+}\
+.ace_dialog input {\
+ border: none;\
+ outline: none;\
+ background: transparent;\
+ width: 20em;\
+ color: inherit;\
+ font-family: monospace;\
+}", "vimMode");
+(function() {
+ function dialogDiv(cm, template, bottom) {
+ var wrap = cm.ace.container;
+ var dialog;
+ dialog = wrap.appendChild(document.createElement("div"));
+ if (bottom)
+ dialog.className = "ace_dialog ace_dialog-bottom";
+ else
+ dialog.className = "ace_dialog ace_dialog-top";
+
+ if (typeof template == "string") {
+ dialog.innerHTML = template;
+ } else { // Assuming it's a detached DOM element.
+ dialog.appendChild(template);
+ }
+ return dialog;
+ }
+
+ function closeNotification(cm, newVal) {
+ if (cm.state.currentNotificationClose)
+ cm.state.currentNotificationClose();
+ cm.state.currentNotificationClose = newVal;
+ }
+
+ CodeMirror.defineExtension("openDialog", function(template, callback, options) {
+ if (this.virtualSelectionMode()) return;
+ if (!options) options = {};
+
+ closeNotification(this, null);
+
+ var dialog = dialogDiv(this, template, options.bottom);
+ var closed = false, me = this;
+ function close(newVal) {
+ if (typeof newVal == 'string') {
+ inp.value = newVal;
+ } else {
+ if (closed) return;
+ closed = true;
+ dialog.parentNode.removeChild(dialog);
+ me.focus();
+
+ if (options.onClose) options.onClose(dialog);
+ }
+ }
+
+ var inp = dialog.getElementsByTagName("input")[0], button;
+ if (inp) {
+ if (options.value) {
+ inp.value = options.value;
+ if (options.select !== false) inp.select();
+ }
+
+ if (options.onInput)
+ CodeMirror.on(inp, "input", function(e) { options.onInput(e, inp.value, close);});
+ if (options.onKeyUp)
+ CodeMirror.on(inp, "keyup", function(e) {options.onKeyUp(e, inp.value, close);});
+
+ CodeMirror.on(inp, "keydown", function(e) {
+ if (options && options.onKeyDown && options.onKeyDown(e, inp.value, close)) { return; }
+ if (e.keyCode == 27 || (options.closeOnEnter !== false && e.keyCode == 13)) {
+ inp.blur();
+ CodeMirror.e_stop(e);
+ close();
+ }
+ if (e.keyCode == 13) callback(inp.value);
+ });
+
+ if (options.closeOnBlur !== false) CodeMirror.on(inp, "blur", close);
+
+ inp.focus();
+ } else if (button = dialog.getElementsByTagName("button")[0]) {
+ CodeMirror.on(button, "click", function() {
+ close();
+ me.focus();
+ });
+
+ if (options.closeOnBlur !== false) CodeMirror.on(button, "blur", close);
+
+ button.focus();
+ }
+ return close;
+ });
+
+ CodeMirror.defineExtension("openNotification", function(template, options) {
+ if (this.virtualSelectionMode()) return;
+ closeNotification(this, close);
+ var dialog = dialogDiv(this, template, options && options.bottom);
+ var closed = false, doneTimer;
+ var duration = options && typeof options.duration !== "undefined" ? options.duration : 5000;
+
+ function close() {
+ if (closed) return;
+ closed = true;
+ clearTimeout(doneTimer);
+ dialog.parentNode.removeChild(dialog);
+ }
+
+ CodeMirror.on(dialog, 'click', function(e) {
+ CodeMirror.e_preventDefault(e);
+ close();
+ });
+
+ if (duration)
+ doneTimer = setTimeout(close, duration);
+
+ return close;
+ });
+})();
+
+
+ var defaultKeymap = [
+ { keys: '<Left>', type: 'keyToKey', toKeys: 'h' },
+ { keys: '<Right>', type: 'keyToKey', toKeys: 'l' },
+ { keys: '<Up>', type: 'keyToKey', toKeys: 'k' },
+ { keys: '<Down>', type: 'keyToKey', toKeys: 'j' },
+ { keys: '<Space>', type: 'keyToKey', toKeys: 'l' },
+ { keys: '<BS>', type: 'keyToKey', toKeys: 'h', context: 'normal'},
+ { keys: '<C-Space>', type: 'keyToKey', toKeys: 'W' },
+ { keys: '<C-BS>', type: 'keyToKey', toKeys: 'B', context: 'normal' },
+ { keys: '<S-Space>', type: 'keyToKey', toKeys: 'w' },
+ { keys: '<S-BS>', type: 'keyToKey', toKeys: 'b', context: 'normal' },
+ { keys: '<C-n>', type: 'keyToKey', toKeys: 'j' },
+ { keys: '<C-p>', type: 'keyToKey', toKeys: 'k' },
+ { keys: '<C-[>', type: 'keyToKey', toKeys: '<Esc>' },
+ { keys: '<C-c>', type: 'keyToKey', toKeys: '<Esc>' },
+ { keys: '<C-[>', type: 'keyToKey', toKeys: '<Esc>', context: 'insert' },
+ { keys: '<C-c>', type: 'keyToKey', toKeys: '<Esc>', context: 'insert' },
+ { keys: 's', type: 'keyToKey', toKeys: 'cl', context: 'normal' },
+ { keys: 's', type: 'keyToKey', toKeys: 'c', context: 'visual'},
+ { keys: 'S', type: 'keyToKey', toKeys: 'cc', context: 'normal' },
+ { keys: 'S', type: 'keyToKey', toKeys: 'VdO', context: 'visual' },
+ { keys: '<Home>', type: 'keyToKey', toKeys: '0' },
+ { keys: '<End>', type: 'keyToKey', toKeys: '$' },
+ { keys: '<PageUp>', type: 'keyToKey', toKeys: '<C-b>' },
+ { keys: '<PageDown>', type: 'keyToKey', toKeys: '<C-f>' },
+ { keys: '<CR>', type: 'keyToKey', toKeys: 'j^', context: 'normal' },
+ { keys: 'H', type: 'motion', motion: 'moveToTopLine', motionArgs: { linewise: true, toJumplist: true }},
+ { keys: 'M', type: 'motion', motion: 'moveToMiddleLine', motionArgs: { linewise: true, toJumplist: true }},
+ { keys: 'L', type: 'motion', motion: 'moveToBottomLine', motionArgs: { linewise: true, toJumplist: true }},
+ { keys: 'h', type: 'motion', motion: 'moveByCharacters', motionArgs: { forward: false }},
+ { keys: 'l', type: 'motion', motion: 'moveByCharacters', motionArgs: { forward: true }},
+ { keys: 'j', type: 'motion', motion: 'moveByLines', motionArgs: { forward: true, linewise: true }},
+ { keys: 'k', type: 'motion', motion: 'moveByLines', motionArgs: { forward: false, linewise: true }},
+ { keys: 'gj', type: 'motion', motion: 'moveByDisplayLines', motionArgs: { forward: true }},
+ { keys: 'gk', type: 'motion', motion: 'moveByDisplayLines', motionArgs: { forward: false }},
+ { keys: 'w', type: 'motion', motion: 'moveByWords', motionArgs: { forward: true, wordEnd: false }},
+ { keys: 'W', type: 'motion', motion: 'moveByWords', motionArgs: { forward: true, wordEnd: false, bigWord: true }},
+ { keys: 'e', type: 'motion', motion: 'moveByWords', motionArgs: { forward: true, wordEnd: true, inclusive: true }},
+ { keys: 'E', type: 'motion', motion: 'moveByWords', motionArgs: { forward: true, wordEnd: true, bigWord: true, inclusive: true }},
+ { keys: 'b', type: 'motion', motion: 'moveByWords', motionArgs: { forward: false, wordEnd: false }},
+ { keys: 'B', type: 'motion', motion: 'moveByWords', motionArgs: { forward: false, wordEnd: false, bigWord: true }},
+ { keys: 'ge', type: 'motion', motion: 'moveByWords', motionArgs: { forward: false, wordEnd: true, inclusive: true }},
+ { keys: 'gE', type: 'motion', motion: 'moveByWords', motionArgs: { forward: false, wordEnd: true, bigWord: true, inclusive: true }},
+ { keys: '{', type: 'motion', motion: 'moveByParagraph', motionArgs: { forward: false, toJumplist: true }},
+ { keys: '}', type: 'motion', motion: 'moveByParagraph', motionArgs: { forward: true, toJumplist: true }},
+ { keys: '<C-f>', type: 'motion', motion: 'moveByPage', motionArgs: { forward: true }},
+ { keys: '<C-b>', type: 'motion', motion: 'moveByPage', motionArgs: { forward: false }},
+ { keys: '<C-d>', type: 'motion', motion: 'moveByScroll', motionArgs: { forward: true, explicitRepeat: true }},
+ { keys: '<C-u>', type: 'motion', motion: 'moveByScroll', motionArgs: { forward: false, explicitRepeat: true }},
+ { keys: 'gg', type: 'motion', motion: 'moveToLineOrEdgeOfDocument', motionArgs: { forward: false, explicitRepeat: true, linewise: true, toJumplist: true }},
+ { keys: 'G', type: 'motion', motion: 'moveToLineOrEdgeOfDocument', motionArgs: { forward: true, explicitRepeat: true, linewise: true, toJumplist: true }},
+ { keys: '0', type: 'motion', motion: 'moveToStartOfLine' },
+ { keys: '^', type: 'motion', motion: 'moveToFirstNonWhiteSpaceCharacter' },
+ { keys: '+', type: 'motion', motion: 'moveByLines', motionArgs: { forward: true, toFirstChar:true }},
+ { keys: '-', type: 'motion', motion: 'moveByLines', motionArgs: { forward: false, toFirstChar:true }},
+ { keys: '_', type: 'motion', motion: 'moveByLines', motionArgs: { forward: true, toFirstChar:true, repeatOffset:-1 }},
+ { keys: '$', type: 'motion', motion: 'moveToEol', motionArgs: { inclusive: true }},
+ { keys: '%', type: 'motion', motion: 'moveToMatchedSymbol', motionArgs: { inclusive: true, toJumplist: true }},
+ { keys: 'f<character>', type: 'motion', motion: 'moveToCharacter', motionArgs: { forward: true , inclusive: true }},
+ { keys: 'F<character>', type: 'motion', motion: 'moveToCharacter', motionArgs: { forward: false }},
+ { keys: 't<character>', type: 'motion', motion: 'moveTillCharacter', motionArgs: { forward: true, inclusive: true }},
+ { keys: 'T<character>', type: 'motion', motion: 'moveTillCharacter', motionArgs: { forward: false }},
+ { keys: ';', type: 'motion', motion: 'repeatLastCharacterSearch', motionArgs: { forward: true }},
+ { keys: ',', type: 'motion', motion: 'repeatLastCharacterSearch', motionArgs: { forward: false }},
+ { keys: '\'<character>', type: 'motion', motion: 'goToMark', motionArgs: {toJumplist: true, linewise: true}},
+ { keys: '`<character>', type: 'motion', motion: 'goToMark', motionArgs: {toJumplist: true}},
+ { keys: ']`', type: 'motion', motion: 'jumpToMark', motionArgs: { forward: true } },
+ { keys: '[`', type: 'motion', motion: 'jumpToMark', motionArgs: { forward: false } },
+ { keys: ']\'', type: 'motion', motion: 'jumpToMark', motionArgs: { forward: true, linewise: true } },
+ { keys: '[\'', type: 'motion', motion: 'jumpToMark', motionArgs: { forward: false, linewise: true } },
+ { keys: ']p', type: 'action', action: 'paste', isEdit: true, actionArgs: { after: true, isEdit: true, matchIndent: true}},
+ { keys: '[p', type: 'action', action: 'paste', isEdit: true, actionArgs: { after: false, isEdit: true, matchIndent: true}},
+ { keys: ']<character>', type: 'motion', motion: 'moveToSymbol', motionArgs: { forward: true, toJumplist: true}},
+ { keys: '[<character>', type: 'motion', motion: 'moveToSymbol', motionArgs: { forward: false, toJumplist: true}},
+ { keys: '|', type: 'motion', motion: 'moveToColumn'},
+ { keys: 'o', type: 'motion', motion: 'moveToOtherHighlightedEnd', context:'visual'},
+ { keys: 'O', type: 'motion', motion: 'moveToOtherHighlightedEnd', motionArgs: {sameLine: true}, context:'visual'},
+ { keys: 'd', type: 'operator', operator: 'delete' },
+ { keys: 'y', type: 'operator', operator: 'yank' },
+ { keys: 'c', type: 'operator', operator: 'change' },
+ { keys: '>', type: 'operator', operator: 'indent', operatorArgs: { indentRight: true }},
+ { keys: '<', type: 'operator', operator: 'indent', operatorArgs: { indentRight: false }},
+ { keys: 'g~', type: 'operator', operator: 'changeCase' },
+ { keys: 'gu', type: 'operator', operator: 'changeCase', operatorArgs: {toLower: true}, isEdit: true },
+ { keys: 'gU', type: 'operator', operator: 'changeCase', operatorArgs: {toLower: false}, isEdit: true },
+ { keys: 'n', type: 'motion', motion: 'findNext', motionArgs: { forward: true, toJumplist: true }},
+ { keys: 'N', type: 'motion', motion: 'findNext', motionArgs: { forward: false, toJumplist: true }},
+ { keys: 'x', type: 'operatorMotion', operator: 'delete', motion: 'moveByCharacters', motionArgs: { forward: true }, operatorMotionArgs: { visualLine: false }},
+ { keys: 'X', type: 'operatorMotion', operator: 'delete', motion: 'moveByCharacters', motionArgs: { forward: false }, operatorMotionArgs: { visualLine: true }},
+ { keys: 'D', type: 'operatorMotion', operator: 'delete', motion: 'moveToEol', motionArgs: { inclusive: true }, context: 'normal'},
+ { keys: 'D', type: 'operator', operator: 'delete', operatorArgs: { linewise: true }, context: 'visual'},
+ { keys: 'Y', type: 'operatorMotion', operator: 'yank', motion: 'moveToEol', motionArgs: { inclusive: true }, context: 'normal'},
+ { keys: 'Y', type: 'operator', operator: 'yank', operatorArgs: { linewise: true }, context: 'visual'},
+ { keys: 'C', type: 'operatorMotion', operator: 'change', motion: 'moveToEol', motionArgs: { inclusive: true }, context: 'normal'},
+ { keys: 'C', type: 'operator', operator: 'change', operatorArgs: { linewise: true }, context: 'visual'},
+ { keys: '~', type: 'operatorMotion', operator: 'changeCase', motion: 'moveByCharacters', motionArgs: { forward: true }, operatorArgs: { shouldMoveCursor: true }, context: 'normal'},
+ { keys: '~', type: 'operator', operator: 'changeCase', context: 'visual'},
+ { keys: '<C-w>', type: 'operatorMotion', operator: 'delete', motion: 'moveByWords', motionArgs: { forward: false, wordEnd: false }, context: 'insert' },
+ { keys: '<C-i>', type: 'action', action: 'jumpListWalk', actionArgs: { forward: true }},
+ { keys: '<C-o>', type: 'action', action: 'jumpListWalk', actionArgs: { forward: false }},
+ { keys: '<C-e>', type: 'action', action: 'scroll', actionArgs: { forward: true, linewise: true }},
+ { keys: '<C-y>', type: 'action', action: 'scroll', actionArgs: { forward: false, linewise: true }},
+ { keys: 'a', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { insertAt: 'charAfter' }, context: 'normal' },
+ { keys: 'A', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { insertAt: 'eol' }, context: 'normal' },
+ { keys: 'A', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { insertAt: 'endOfSelectedArea' }, context: 'visual' },
+ { keys: 'i', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { insertAt: 'inplace' }, context: 'normal' },
+ { keys: 'I', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { insertAt: 'firstNonBlank'}, context: 'normal' },
+ { keys: 'I', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { insertAt: 'startOfSelectedArea' }, context: 'visual' },
+ { keys: 'o', type: 'action', action: 'newLineAndEnterInsertMode', isEdit: true, interlaceInsertRepeat: true, actionArgs: { after: true }, context: 'normal' },
+ { keys: 'O', type: 'action', action: 'newLineAndEnterInsertMode', isEdit: true, interlaceInsertRepeat: true, actionArgs: { after: false }, context: 'normal' },
+ { keys: 'v', type: 'action', action: 'toggleVisualMode' },
+ { keys: 'V', type: 'action', action: 'toggleVisualMode', actionArgs: { linewise: true }},
+ { keys: '<C-v>', type: 'action', action: 'toggleVisualMode', actionArgs: { blockwise: true }},
+ { keys: '<C-q>', type: 'action', action: 'toggleVisualMode', actionArgs: { blockwise: true }},
+ { keys: 'gv', type: 'action', action: 'reselectLastSelection' },
+ { keys: 'J', type: 'action', action: 'joinLines', isEdit: true },
+ { keys: 'p', type: 'action', action: 'paste', isEdit: true, actionArgs: { after: true, isEdit: true }},
+ { keys: 'P', type: 'action', action: 'paste', isEdit: true, actionArgs: { after: false, isEdit: true }},
+ { keys: 'r<character>', type: 'action', action: 'replace', isEdit: true },
+ { keys: '@<character>', type: 'action', action: 'replayMacro' },
+ { keys: 'q<character>', type: 'action', action: 'enterMacroRecordMode' },
+ { keys: 'R', type: 'action', action: 'enterInsertMode', isEdit: true, actionArgs: { replace: true }},
+ { keys: 'u', type: 'action', action: 'undo', context: 'normal' },
+ { keys: 'u', type: 'operator', operator: 'changeCase', operatorArgs: {toLower: true}, context: 'visual', isEdit: true },
+ { keys: 'U', type: 'operator', operator: 'changeCase', operatorArgs: {toLower: false}, context: 'visual', isEdit: true },
+ { keys: '<C-r>', type: 'action', action: 'redo' },
+ { keys: 'm<character>', type: 'action', action: 'setMark' },
+ { keys: '"<character>', type: 'action', action: 'setRegister' },
+ { keys: 'zz', type: 'action', action: 'scrollToCursor', actionArgs: { position: 'center' }},
+ { keys: 'z.', type: 'action', action: 'scrollToCursor', actionArgs: { position: 'center' }, motion: 'moveToFirstNonWhiteSpaceCharacter' },
+ { keys: 'zt', type: 'action', action: 'scrollToCursor', actionArgs: { position: 'top' }},
+ { keys: 'z<CR>', type: 'action', action: 'scrollToCursor', actionArgs: { position: 'top' }, motion: 'moveToFirstNonWhiteSpaceCharacter' },
+ { keys: 'z-', type: 'action', action: 'scrollToCursor', actionArgs: { position: 'bottom' }},
+ { keys: 'zb', type: 'action', action: 'scrollToCursor', actionArgs: { position: 'bottom' }, motion: 'moveToFirstNonWhiteSpaceCharacter' },
+ { keys: '.', type: 'action', action: 'repeatLastEdit' },
+ { keys: '<C-a>', type: 'action', action: 'incrementNumberToken', isEdit: true, actionArgs: {increase: true, backtrack: false}},
+ { keys: '<C-x>', type: 'action', action: 'incrementNumberToken', isEdit: true, actionArgs: {increase: false, backtrack: false}},
+ { keys: 'a<character>', type: 'motion', motion: 'textObjectManipulation' },
+ { keys: 'i<character>', type: 'motion', motion: 'textObjectManipulation', motionArgs: { textObjectInner: true }},
+ { keys: '/', type: 'search', searchArgs: { forward: true, querySrc: 'prompt', toJumplist: true }},
+ { keys: '?', type: 'search', searchArgs: { forward: false, querySrc: 'prompt', toJumplist: true }},
+ { keys: '*', type: 'search', searchArgs: { forward: true, querySrc: 'wordUnderCursor', wholeWordOnly: true, toJumplist: true }},
+ { keys: '#', type: 'search', searchArgs: { forward: false, querySrc: 'wordUnderCursor', wholeWordOnly: true, toJumplist: true }},
+ { keys: 'g*', type: 'search', searchArgs: { forward: true, querySrc: 'wordUnderCursor', toJumplist: true }},
+ { keys: 'g#', type: 'search', searchArgs: { forward: false, querySrc: 'wordUnderCursor', toJumplist: true }},
+ { keys: ':', type: 'ex' }
+ ];
+ var defaultExCommandMap = [
+ { name: 'colorscheme', shortName: 'colo' },
+ { name: 'map' },
+ { name: 'imap', shortName: 'im' },
+ { name: 'nmap', shortName: 'nm' },
+ { name: 'vmap', shortName: 'vm' },
+ { name: 'unmap' },
+ { name: 'write', shortName: 'w' },
+ { name: 'undo', shortName: 'u' },
+ { name: 'redo', shortName: 'red' },
+ { name: 'set', shortName: 'se' },
+ { name: 'set', shortName: 'se' },
+ { name: 'setlocal', shortName: 'setl' },
+ { name: 'setglobal', shortName: 'setg' },
+ { name: 'sort', shortName: 'sor' },
+ { name: 'substitute', shortName: 's', possiblyAsync: true },
+ { name: 'nohlsearch', shortName: 'noh' },
+ { name: 'delmarks', shortName: 'delm' },
+ { name: 'registers', shortName: 'reg', excludeFromCommandHistory: true },
+ { name: 'global', shortName: 'g' }
+ ];
+
+ var Pos = CodeMirror.Pos;
+
+ var Vim = function() { return vimApi; } //{
+ function enterVimMode(cm) {
+ cm.setOption('disableInput', true);
+ cm.setOption('showCursorWhenSelecting', false);
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "normal"});
+ cm.on('cursorActivity', onCursorActivity);
+ maybeInitVimState(cm);
+ CodeMirror.on(cm.getInputField(), 'paste', getOnPasteFn(cm));
+ }
+
+ function leaveVimMode(cm) {
+ cm.setOption('disableInput', false);
+ cm.off('cursorActivity', onCursorActivity);
+ CodeMirror.off(cm.getInputField(), 'paste', getOnPasteFn(cm));
+ cm.state.vim = null;
+ }
+
+ function detachVimMap(cm, next) {
+ if (this == CodeMirror.keyMap.vim)
+ CodeMirror.rmClass(cm.getWrapperElement(), "cm-fat-cursor");
+
+ if (!next || next.attach != attachVimMap)
+ leaveVimMode(cm, false);
+ }
+ function attachVimMap(cm, prev) {
+ if (this == CodeMirror.keyMap.vim)
+ CodeMirror.addClass(cm.getWrapperElement(), "cm-fat-cursor");
+
+ if (!prev || prev.attach != attachVimMap)
+ enterVimMode(cm);
+ }
+ CodeMirror.defineOption('vimMode', false, function(cm, val, prev) {
+ if (val && cm.getOption("keyMap") != "vim")
+ cm.setOption("keyMap", "vim");
+ else if (!val && prev != CodeMirror.Init && /^vim/.test(cm.getOption("keyMap")))
+ cm.setOption("keyMap", "default");
+ });
+
+ function cmKey(key, cm) {
+ if (!cm) { return undefined; }
+ var vimKey = cmKeyToVimKey(key);
+ if (!vimKey) {
+ return false;
+ }
+ var cmd = CodeMirror.Vim.findKey(cm, vimKey);
+ if (typeof cmd == 'function') {
+ CodeMirror.signal(cm, 'vim-keypress', vimKey);
+ }
+ return cmd;
+ }
+
+ var modifiers = {'Shift': 'S', 'Ctrl': 'C', 'Alt': 'A', 'Cmd': 'D', 'Mod': 'A'};
+ var specialKeys = {Enter:'CR',Backspace:'BS',Delete:'Del'};
+ function cmKeyToVimKey(key) {
+ if (key.charAt(0) == '\'') {
+ return key.charAt(1);
+ }
+ var pieces = key.split(/-(?!$)/);
+ var lastPiece = pieces[pieces.length - 1];
+ if (pieces.length == 1 && pieces[0].length == 1) {
+ return false;
+ } else if (pieces.length == 2 && pieces[0] == 'Shift' && lastPiece.length == 1) {
+ return false;
+ }
+ var hasCharacter = false;
+ for (var i = 0; i < pieces.length; i++) {
+ var piece = pieces[i];
+ if (piece in modifiers) { pieces[i] = modifiers[piece]; }
+ else { hasCharacter = true; }
+ if (piece in specialKeys) { pieces[i] = specialKeys[piece]; }
+ }
+ if (!hasCharacter) {
+ return false;
+ }
+ if (isUpperCase(lastPiece)) {
+ pieces[pieces.length - 1] = lastPiece.toLowerCase();
+ }
+ return '<' + pieces.join('-') + '>';
+ }
+
+ function getOnPasteFn(cm) {
+ var vim = cm.state.vim;
+ if (!vim.onPasteFn) {
+ vim.onPasteFn = function() {
+ if (!vim.insertMode) {
+ cm.setCursor(offsetCursor(cm.getCursor(), 0, 1));
+ actions.enterInsertMode(cm, {}, vim);
+ }
+ };
+ }
+ return vim.onPasteFn;
+ }
+
+ var numberRegex = /[\d]/;
+ var wordCharTest = [CodeMirror.isWordChar, function(ch) {
+ return ch && !CodeMirror.isWordChar(ch) && !/\s/.test(ch);
+ }], bigWordCharTest = [function(ch) {
+ return /\S/.test(ch);
+ }];
+ function makeKeyRange(start, size) {
+ var keys = [];
+ for (var i = start; i < start + size; i++) {
+ keys.push(String.fromCharCode(i));
+ }
+ return keys;
+ }
+ var upperCaseAlphabet = makeKeyRange(65, 26);
+ var lowerCaseAlphabet = makeKeyRange(97, 26);
+ var numbers = makeKeyRange(48, 10);
+ var validMarks = [].concat(upperCaseAlphabet, lowerCaseAlphabet, numbers, ['<', '>']);
+ var validRegisters = [].concat(upperCaseAlphabet, lowerCaseAlphabet, numbers, ['-', '"', '.', ':', '/']);
+
+ function isLine(cm, line) {
+ return line >= cm.firstLine() && line <= cm.lastLine();
+ }
+ function isLowerCase(k) {
+ return (/^[a-z]$/).test(k);
+ }
+ function isMatchableSymbol(k) {
+ return '()[]{}'.indexOf(k) != -1;
+ }
+ function isNumber(k) {
+ return numberRegex.test(k);
+ }
+ function isUpperCase(k) {
+ return (/^[A-Z]$/).test(k);
+ }
+ function isWhiteSpaceString(k) {
+ return (/^\s*$/).test(k);
+ }
+ function inArray(val, arr) {
+ for (var i = 0; i < arr.length; i++) {
+ if (arr[i] == val) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ var options = {};
+ function defineOption(name, defaultValue, type, aliases, callback) {
+ if (defaultValue === undefined && !callback) {
+ throw Error('defaultValue is required unless callback is provided');
+ }
+ if (!type) { type = 'string'; }
+ options[name] = {
+ type: type,
+ defaultValue: defaultValue,
+ callback: callback
+ };
+ if (aliases) {
+ for (var i = 0; i < aliases.length; i++) {
+ options[aliases[i]] = options[name];
+ }
+ }
+ if (defaultValue) {
+ setOption(name, defaultValue);
+ }
+ }
+
+ function setOption(name, value, cm, cfg) {
+ var option = options[name];
+ cfg = cfg || {};
+ var scope = cfg.scope;
+ if (!option) {
+ throw Error('Unknown option: ' + name);
+ }
+ if (option.type == 'boolean') {
+ if (value && value !== true) {
+ throw Error('Invalid argument: ' + name + '=' + value);
+ } else if (value !== false) {
+ value = true;
+ }
+ }
+ if (option.callback) {
+ if (scope !== 'local') {
+ option.callback(value, undefined);
+ }
+ if (scope !== 'global' && cm) {
+ option.callback(value, cm);
+ }
+ } else {
+ if (scope !== 'local') {
+ option.value = option.type == 'boolean' ? !!value : value;
+ }
+ if (scope !== 'global' && cm) {
+ cm.state.vim.options[name] = {value: value};
+ }
+ }
+ }
+
+ function getOption(name, cm, cfg) {
+ var option = options[name];
+ cfg = cfg || {};
+ var scope = cfg.scope;
+ if (!option) {
+ throw Error('Unknown option: ' + name);
+ }
+ if (option.callback) {
+ var local = cm && option.callback(undefined, cm);
+ if (scope !== 'global' && local !== undefined) {
+ return local;
+ }
+ if (scope !== 'local') {
+ return option.callback();
+ }
+ return;
+ } else {
+ var local = (scope !== 'global') && (cm && cm.state.vim.options[name]);
+ return (local || (scope !== 'local') && option || {}).value;
+ }
+ }
+
+ defineOption('filetype', undefined, 'string', ['ft'], function(name, cm) {
+ if (cm === undefined) {
+ return;
+ }
+ if (name === undefined) {
+ var mode = cm.getOption('mode');
+ return mode == 'null' ? '' : mode;
+ } else {
+ var mode = name == '' ? 'null' : name;
+ cm.setOption('mode', mode);
+ }
+ });
+
+ var createCircularJumpList = function() {
+ var size = 100;
+ var pointer = -1;
+ var head = 0;
+ var tail = 0;
+ var buffer = new Array(size);
+ function add(cm, oldCur, newCur) {
+ var current = pointer % size;
+ var curMark = buffer[current];
+ function useNextSlot(cursor) {
+ var next = ++pointer % size;
+ var trashMark = buffer[next];
+ if (trashMark) {
+ trashMark.clear();
+ }
+ buffer[next] = cm.setBookmark(cursor);
+ }
+ if (curMark) {
+ var markPos = curMark.find();
+ if (markPos && !cursorEqual(markPos, oldCur)) {
+ useNextSlot(oldCur);
+ }
+ } else {
+ useNextSlot(oldCur);
+ }
+ useNextSlot(newCur);
+ head = pointer;
+ tail = pointer - size + 1;
+ if (tail < 0) {
+ tail = 0;
+ }
+ }
+ function move(cm, offset) {
+ pointer += offset;
+ if (pointer > head) {
+ pointer = head;
+ } else if (pointer < tail) {
+ pointer = tail;
+ }
+ var mark = buffer[(size + pointer) % size];
+ if (mark && !mark.find()) {
+ var inc = offset > 0 ? 1 : -1;
+ var newCur;
+ var oldCur = cm.getCursor();
+ do {
+ pointer += inc;
+ mark = buffer[(size + pointer) % size];
+ if (mark &&
+ (newCur = mark.find()) &&
+ !cursorEqual(oldCur, newCur)) {
+ break;
+ }
+ } while (pointer < head && pointer > tail);
+ }
+ return mark;
+ }
+ return {
+ cachedCursor: undefined, //used for # and * jumps
+ add: add,
+ move: move
+ };
+ };
+ var createInsertModeChanges = function(c) {
+ if (c) {
+ return {
+ changes: c.changes,
+ expectCursorActivityForChange: c.expectCursorActivityForChange
+ };
+ }
+ return {
+ changes: [],
+ expectCursorActivityForChange: false
+ };
+ };
+
+ function MacroModeState() {
+ this.latestRegister = undefined;
+ this.isPlaying = false;
+ this.isRecording = false;
+ this.replaySearchQueries = [];
+ this.onRecordingDone = undefined;
+ this.lastInsertModeChanges = createInsertModeChanges();
+ }
+ MacroModeState.prototype = {
+ exitMacroRecordMode: function() {
+ var macroModeState = vimGlobalState.macroModeState;
+ if (macroModeState.onRecordingDone) {
+ macroModeState.onRecordingDone(); // close dialog
+ }
+ macroModeState.onRecordingDone = undefined;
+ macroModeState.isRecording = false;
+ },
+ enterMacroRecordMode: function(cm, registerName) {
+ var register =
+ vimGlobalState.registerController.getRegister(registerName);
+ if (register) {
+ register.clear();
+ this.latestRegister = registerName;
+ if (cm.openDialog) {
+ this.onRecordingDone = cm.openDialog(
+ '(recording)['+registerName+']', null, {bottom:true});
+ }
+ this.isRecording = true;
+ }
+ }
+ };
+
+ function maybeInitVimState(cm) {
+ if (!cm.state.vim) {
+ cm.state.vim = {
+ inputState: new InputState(),
+ lastEditInputState: undefined,
+ lastEditActionCommand: undefined,
+ lastHPos: -1,
+ lastHSPos: -1,
+ lastMotion: null,
+ marks: {},
+ fakeCursor: null,
+ insertMode: false,
+ insertModeRepeat: undefined,
+ visualMode: false,
+ visualLine: false,
+ visualBlock: false,
+ lastSelection: null,
+ lastPastedText: null,
+ sel: {},
+ options: {}
+ };
+ }
+ return cm.state.vim;
+ }
+ var vimGlobalState;
+ function resetVimGlobalState() {
+ vimGlobalState = {
+ searchQuery: null,
+ searchIsReversed: false,
+ lastSubstituteReplacePart: undefined,
+ jumpList: createCircularJumpList(),
+ macroModeState: new MacroModeState,
+ lastChararacterSearch: {increment:0, forward:true, selectedCharacter:''},
+ registerController: new RegisterController({}),
+ searchHistoryController: new HistoryController({}),
+ exCommandHistoryController : new HistoryController({})
+ };
+ for (var optionName in options) {
+ var option = options[optionName];
+ option.value = option.defaultValue;
+ }
+ }
+
+ var lastInsertModeKeyTimer;
+ var vimApi= {
+ buildKeyMap: function() {
+ },
+ getRegisterController: function() {
+ return vimGlobalState.registerController;
+ },
+ resetVimGlobalState_: resetVimGlobalState,
+ getVimGlobalState_: function() {
+ return vimGlobalState;
+ },
+ maybeInitVimState_: maybeInitVimState,
+
+ suppressErrorLogging: false,
+
+ InsertModeKey: InsertModeKey,
+ map: function(lhs, rhs, ctx) {
+ exCommandDispatcher.map(lhs, rhs, ctx);
+ },
+ unmap: function(lhs, ctx) {
+ exCommandDispatcher.unmap(lhs, ctx);
+ },
+ setOption: setOption,
+ getOption: getOption,
+ defineOption: defineOption,
+ defineEx: function(name, prefix, func){
+ if (!prefix) {
+ prefix = name;
+ } else if (name.indexOf(prefix) !== 0) {
+ throw new Error('(Vim.defineEx) "'+prefix+'" is not a prefix of "'+name+'", command not registered');
+ }
+ exCommands[name]=func;
+ exCommandDispatcher.commandMap_[prefix]={name:name, shortName:prefix, type:'api'};
+ },
+ handleKey: function (cm, key, origin) {
+ var command = this.findKey(cm, key, origin);
+ if (typeof command === 'function') {
+ return command();
+ }
+ },
+ findKey: function(cm, key, origin) {
+ var vim = maybeInitVimState(cm);
+ function handleMacroRecording() {
+ var macroModeState = vimGlobalState.macroModeState;
+ if (macroModeState.isRecording) {
+ if (key == 'q') {
+ macroModeState.exitMacroRecordMode();
+ clearInputState(cm);
+ return true;
+ }
+ if (origin != 'mapping') {
+ logKey(macroModeState, key);
+ }
+ }
+ }
+ function handleEsc() {
+ if (key == '<Esc>') {
+ clearInputState(cm);
+ if (vim.visualMode) {
+ exitVisualMode(cm);
+ } else if (vim.insertMode) {
+ exitInsertMode(cm);
+ }
+ return true;
+ }
+ }
+ function doKeyToKey(keys) {
+ var match;
+ while (keys) {
+ match = (/<\w+-.+?>|<\w+>|./).exec(keys);
+ key = match[0];
+ keys = keys.substring(match.index + key.length);
+ CodeMirror.Vim.handleKey(cm, key, 'mapping');
+ }
+ }
+
+ function handleKeyInsertMode() {
+ if (handleEsc()) { return true; }
+ var keys = vim.inputState.keyBuffer = vim.inputState.keyBuffer + key;
+ var keysAreChars = key.length == 1;
+ var match = commandDispatcher.matchCommand(keys, defaultKeymap, vim.inputState, 'insert');
+ while (keys.length > 1 && match.type != 'full') {
+ var keys = vim.inputState.keyBuffer = keys.slice(1);
+ var thisMatch = commandDispatcher.matchCommand(keys, defaultKeymap, vim.inputState, 'insert');
+ if (thisMatch.type != 'none') { match = thisMatch; }
+ }
+ if (match.type == 'none') { clearInputState(cm); return false; }
+ else if (match.type == 'partial') {
+ if (lastInsertModeKeyTimer) { window.clearTimeout(lastInsertModeKeyTimer); }
+ lastInsertModeKeyTimer = window.setTimeout(
+ function() { if (vim.insertMode && vim.inputState.keyBuffer) { clearInputState(cm); } },
+ getOption('insertModeEscKeysTimeout'));
+ return !keysAreChars;
+ }
+
+ if (lastInsertModeKeyTimer) { window.clearTimeout(lastInsertModeKeyTimer); }
+ if (keysAreChars) {
+ var selections = cm.listSelections();
+ for (var i = 0; i < selections.length; i++) {
+ var here = selections[i].head;
+ cm.replaceRange('', offsetCursor(here, 0, -(keys.length - 1)), here, '+input');
+ }
+ vimGlobalState.macroModeState.lastInsertModeChanges.changes.pop();
+ }
+ clearInputState(cm);
+ return match.command;
+ }
+
+ function handleKeyNonInsertMode() {
+ if (handleMacroRecording() || handleEsc()) { return true; }
+
+ var keys = vim.inputState.keyBuffer = vim.inputState.keyBuffer + key;
+ if (/^[1-9]\d*$/.test(keys)) { return true; }
+
+ var keysMatcher = /^(\d*)(.*)$/.exec(keys);
+ if (!keysMatcher) { clearInputState(cm); return false; }
+ var context = vim.visualMode ? 'visual' :
+ 'normal';
+ var match = commandDispatcher.matchCommand(keysMatcher[2] || keysMatcher[1], defaultKeymap, vim.inputState, context);
+ if (match.type == 'none') { clearInputState(cm); return false; }
+ else if (match.type == 'partial') { return true; }
+
+ vim.inputState.keyBuffer = '';
+ var keysMatcher = /^(\d*)(.*)$/.exec(keys);
+ if (keysMatcher[1] && keysMatcher[1] != '0') {
+ vim.inputState.pushRepeatDigit(keysMatcher[1]);
+ }
+ return match.command;
+ }
+
+ var command;
+ if (vim.insertMode) { command = handleKeyInsertMode(); }
+ else { command = handleKeyNonInsertMode(); }
+ if (command === false) {
+ return undefined;
+ } else if (command === true) {
+ return function() { return true; };
+ } else {
+ return function() {
+ if ((command.operator || command.isEdit) && cm.getOption('readOnly'))
+ return; // ace_patch
+ return cm.operation(function() {
+ cm.curOp.isVimOp = true;
+ try {
+ if (command.type == 'keyToKey') {
+ doKeyToKey(command.toKeys);
+ } else {
+ commandDispatcher.processCommand(cm, vim, command);
+ }
+ } catch (e) {
+ cm.state.vim = undefined;
+ maybeInitVimState(cm);
+ if (!CodeMirror.Vim.suppressErrorLogging) {
+ console['log'](e);
+ }
+ throw e;
+ }
+ return true;
+ });
+ };
+ }
+ },
+ handleEx: function(cm, input) {
+ exCommandDispatcher.processCommand(cm, input);
+ },
+
+ defineMotion: defineMotion,
+ defineAction: defineAction,
+ defineOperator: defineOperator,
+ mapCommand: mapCommand,
+ _mapCommand: _mapCommand,
+
+ defineRegister: defineRegister,
+
+ exitVisualMode: exitVisualMode,
+ exitInsertMode: exitInsertMode
+ };
+ function InputState() {
+ this.prefixRepeat = [];
+ this.motionRepeat = [];
+
+ this.operator = null;
+ this.operatorArgs = null;
+ this.motion = null;
+ this.motionArgs = null;
+ this.keyBuffer = []; // For matching multi-key commands.
+ this.registerName = null; // Defaults to the unnamed register.
+ }
+ InputState.prototype.pushRepeatDigit = function(n) {
+ if (!this.operator) {
+ this.prefixRepeat = this.prefixRepeat.concat(n);
+ } else {
+ this.motionRepeat = this.motionRepeat.concat(n);
+ }
+ };
+ InputState.prototype.getRepeat = function() {
+ var repeat = 0;
+ if (this.prefixRepeat.length > 0 || this.motionRepeat.length > 0) {
+ repeat = 1;
+ if (this.prefixRepeat.length > 0) {
+ repeat *= parseInt(this.prefixRepeat.join(''), 10);
+ }
+ if (this.motionRepeat.length > 0) {
+ repeat *= parseInt(this.motionRepeat.join(''), 10);
+ }
+ }
+ return repeat;
+ };
+
+ function clearInputState(cm, reason) {
+ cm.state.vim.inputState = new InputState();
+ CodeMirror.signal(cm, 'vim-command-done', reason);
+ }
+ function Register(text, linewise, blockwise) {
+ this.clear();
+ this.keyBuffer = [text || ''];
+ this.insertModeChanges = [];
+ this.searchQueries = [];
+ this.linewise = !!linewise;
+ this.blockwise = !!blockwise;
+ }
+ Register.prototype = {
+ setText: function(text, linewise, blockwise) {
+ this.keyBuffer = [text || ''];
+ this.linewise = !!linewise;
+ this.blockwise = !!blockwise;
+ },
+ pushText: function(text, linewise) {
+ if (linewise) {
+ if (!this.linewise) {
+ this.keyBuffer.push('\n');
+ }
+ this.linewise = true;
+ }
+ this.keyBuffer.push(text);
+ },
+ pushInsertModeChanges: function(changes) {
+ this.insertModeChanges.push(createInsertModeChanges(changes));
+ },
+ pushSearchQuery: function(query) {
+ this.searchQueries.push(query);
+ },
+ clear: function() {
+ this.keyBuffer = [];
+ this.insertModeChanges = [];
+ this.searchQueries = [];
+ this.linewise = false;
+ },
+ toString: function() {
+ return this.keyBuffer.join('');
+ }
+ };
+ function defineRegister(name, register) {
+ var registers = vimGlobalState.registerController.registers[name];
+ if (!name || name.length != 1) {
+ throw Error('Register name must be 1 character');
+ }
+ registers[name] = register;
+ validRegisters.push(name);
+ }
+ function RegisterController(registers) {
+ this.registers = registers;
+ this.unnamedRegister = registers['"'] = new Register();
+ registers['.'] = new Register();
+ registers[':'] = new Register();
+ registers['/'] = new Register();
+ }
+ RegisterController.prototype = {
+ pushText: function(registerName, operator, text, linewise, blockwise) {
+ if (linewise && text.charAt(0) == '\n') {
+ text = text.slice(1) + '\n';
+ }
+ if (linewise && text.charAt(text.length - 1) !== '\n'){
+ text += '\n';
+ }
+ var register = this.isValidRegister(registerName) ?
+ this.getRegister(registerName) : null;
+ if (!register) {
+ switch (operator) {
+ case 'yank':
+ this.registers['0'] = new Register(text, linewise, blockwise);
+ break;
+ case 'delete':
+ case 'change':
+ if (text.indexOf('\n') == -1) {
+ this.registers['-'] = new Register(text, linewise);
+ } else {
+ this.shiftNumericRegisters_();
+ this.registers['1'] = new Register(text, linewise);
+ }
+ break;
+ }
+ this.unnamedRegister.setText(text, linewise, blockwise);
+ return;
+ }
+ var append = isUpperCase(registerName);
+ if (append) {
+ register.pushText(text, linewise);
+ } else {
+ register.setText(text, linewise, blockwise);
+ }
+ this.unnamedRegister.setText(register.toString(), linewise);
+ },
+ getRegister: function(name) {
+ if (!this.isValidRegister(name)) {
+ return this.unnamedRegister;
+ }
+ name = name.toLowerCase();
+ if (!this.registers[name]) {
+ this.registers[name] = new Register();
+ }
+ return this.registers[name];
+ },
+ isValidRegister: function(name) {
+ return name && inArray(name, validRegisters);
+ },
+ shiftNumericRegisters_: function() {
+ for (var i = 9; i >= 2; i--) {
+ this.registers[i] = this.getRegister('' + (i - 1));
+ }
+ }
+ };
+ function HistoryController() {
+ this.historyBuffer = [];
+ this.iterator;
+ this.initialPrefix = null;
+ }
+ HistoryController.prototype = {
+ nextMatch: function (input, up) {
+ var historyBuffer = this.historyBuffer;
+ var dir = up ? -1 : 1;
+ if (this.initialPrefix === null) this.initialPrefix = input;
+ for (var i = this.iterator + dir; up ? i >= 0 : i < historyBuffer.length; i+= dir) {
+ var element = historyBuffer[i];
+ for (var j = 0; j <= element.length; j++) {
+ if (this.initialPrefix == element.substring(0, j)) {
+ this.iterator = i;
+ return element;
+ }
+ }
+ }
+ if (i >= historyBuffer.length) {
+ this.iterator = historyBuffer.length;
+ return this.initialPrefix;
+ }
+ if (i < 0 ) return input;
+ },
+ pushInput: function(input) {
+ var index = this.historyBuffer.indexOf(input);
+ if (index > -1) this.historyBuffer.splice(index, 1);
+ if (input.length) this.historyBuffer.push(input);
+ },
+ reset: function() {
+ this.initialPrefix = null;
+ this.iterator = this.historyBuffer.length;
+ }
+ };
+ var commandDispatcher = {
+ matchCommand: function(keys, keyMap, inputState, context) {
+ var matches = commandMatches(keys, keyMap, context, inputState);
+ if (!matches.full && !matches.partial) {
+ return {type: 'none'};
+ } else if (!matches.full && matches.partial) {
+ return {type: 'partial'};
+ }
+
+ var bestMatch;
+ for (var i = 0; i < matches.full.length; i++) {
+ var match = matches.full[i];
+ if (!bestMatch) {
+ bestMatch = match;
+ }
+ }
+ if (bestMatch.keys.slice(-11) == '<character>') {
+ var character = lastChar(keys);
+ if (/<C-.>/.test(character)) return {type: 'none'};
+ inputState.selectedCharacter = character;
+ }
+ return {type: 'full', command: bestMatch};
+ },
+ processCommand: function(cm, vim, command) {
+ vim.inputState.repeatOverride = command.repeatOverride;
+ switch (command.type) {
+ case 'motion':
+ this.processMotion(cm, vim, command);
+ break;
+ case 'operator':
+ this.processOperator(cm, vim, command);
+ break;
+ case 'operatorMotion':
+ this.processOperatorMotion(cm, vim, command);
+ break;
+ case 'action':
+ this.processAction(cm, vim, command);
+ break;
+ case 'search':
+ this.processSearch(cm, vim, command);
+ break;
+ case 'ex':
+ case 'keyToEx':
+ this.processEx(cm, vim, command);
+ break;
+ default:
+ break;
+ }
+ },
+ processMotion: function(cm, vim, command) {
+ vim.inputState.motion = command.motion;
+ vim.inputState.motionArgs = copyArgs(command.motionArgs);
+ this.evalInput(cm, vim);
+ },
+ processOperator: function(cm, vim, command) {
+ var inputState = vim.inputState;
+ if (inputState.operator) {
+ if (inputState.operator == command.operator) {
+ inputState.motion = 'expandToLine';
+ inputState.motionArgs = { linewise: true };
+ this.evalInput(cm, vim);
+ return;
+ } else {
+ clearInputState(cm);
+ }
+ }
+ inputState.operator = command.operator;
+ inputState.operatorArgs = copyArgs(command.operatorArgs);
+ if (vim.visualMode) {
+ this.evalInput(cm, vim);
+ }
+ },
+ processOperatorMotion: function(cm, vim, command) {
+ var visualMode = vim.visualMode;
+ var operatorMotionArgs = copyArgs(command.operatorMotionArgs);
+ if (operatorMotionArgs) {
+ if (visualMode && operatorMotionArgs.visualLine) {
+ vim.visualLine = true;
+ }
+ }
+ this.processOperator(cm, vim, command);
+ if (!visualMode) {
+ this.processMotion(cm, vim, command);
+ }
+ },
+ processAction: function(cm, vim, command) {
+ var inputState = vim.inputState;
+ var repeat = inputState.getRepeat();
+ var repeatIsExplicit = !!repeat;
+ var actionArgs = copyArgs(command.actionArgs) || {};
+ if (inputState.selectedCharacter) {
+ actionArgs.selectedCharacter = inputState.selectedCharacter;
+ }
+ if (command.operator) {
+ this.processOperator(cm, vim, command);
+ }
+ if (command.motion) {
+ this.processMotion(cm, vim, command);
+ }
+ if (command.motion || command.operator) {
+ this.evalInput(cm, vim);
+ }
+ actionArgs.repeat = repeat || 1;
+ actionArgs.repeatIsExplicit = repeatIsExplicit;
+ actionArgs.registerName = inputState.registerName;
+ clearInputState(cm);
+ vim.lastMotion = null;
+ if (command.isEdit) {
+ this.recordLastEdit(vim, inputState, command);
+ }
+ actions[command.action](cm, actionArgs, vim);
+ },
+ processSearch: function(cm, vim, command) {
+ if (!cm.getSearchCursor) {
+ return;
+ }
+ var forward = command.searchArgs.forward;
+ var wholeWordOnly = command.searchArgs.wholeWordOnly;
+ getSearchState(cm).setReversed(!forward);
+ var promptPrefix = (forward) ? '/' : '?';
+ var originalQuery = getSearchState(cm).getQuery();
+ var originalScrollPos = cm.getScrollInfo();
+ function handleQuery(query, ignoreCase, smartCase) {
+ vimGlobalState.searchHistoryController.pushInput(query);
+ vimGlobalState.searchHistoryController.reset();
+ try {
+ updateSearchQuery(cm, query, ignoreCase, smartCase);
+ } catch (e) {
+ showConfirm(cm, 'Invalid regex: ' + query);
+ clearInputState(cm);
+ return;
+ }
+ commandDispatcher.processMotion(cm, vim, {
+ type: 'motion',
+ motion: 'findNext',
+ motionArgs: { forward: true, toJumplist: command.searchArgs.toJumplist }
+ });
+ }
+ function onPromptClose(query) {
+ cm.scrollTo(originalScrollPos.left, originalScrollPos.top);
+ handleQuery(query, true /** ignoreCase */, true /** smartCase */);
+ var macroModeState = vimGlobalState.macroModeState;
+ if (macroModeState.isRecording) {
+ logSearchQuery(macroModeState, query);
+ }
+ }
+ function onPromptKeyUp(e, query, close) {
+ var keyName = CodeMirror.keyName(e), up;
+ if (keyName == 'Up' || keyName == 'Down') {
+ up = keyName == 'Up' ? true : false;
+ query = vimGlobalState.searchHistoryController.nextMatch(query, up) || '';
+ close(query);
+ } else {
+ if ( keyName != 'Left' && keyName != 'Right' && keyName != 'Ctrl' && keyName != 'Alt' && keyName != 'Shift')
+ vimGlobalState.searchHistoryController.reset();
+ }
+ var parsedQuery;
+ try {
+ parsedQuery = updateSearchQuery(cm, query,
+ true /** ignoreCase */, true /** smartCase */);
+ } catch (e) {
+ }
+ if (parsedQuery) {
+ cm.scrollIntoView(findNext(cm, !forward, parsedQuery), 30);
+ } else {
+ clearSearchHighlight(cm);
+ cm.scrollTo(originalScrollPos.left, originalScrollPos.top);
+ }
+ }
+ function onPromptKeyDown(e, query, close) {
+ var keyName = CodeMirror.keyName(e);
+ if (keyName == 'Esc' || keyName == 'Ctrl-C' || keyName == 'Ctrl-[' ||
+ (keyName == 'Backspace' && query == '')) {
+ vimGlobalState.searchHistoryController.pushInput(query);
+ vimGlobalState.searchHistoryController.reset();
+ updateSearchQuery(cm, originalQuery);
+ clearSearchHighlight(cm);
+ cm.scrollTo(originalScrollPos.left, originalScrollPos.top);
+ CodeMirror.e_stop(e);
+ clearInputState(cm);
+ close();
+ cm.focus();
+ } else if (keyName == 'Ctrl-U') {
+ CodeMirror.e_stop(e);
+ close('');
+ }
+ }
+ switch (command.searchArgs.querySrc) {
+ case 'prompt':
+ var macroModeState = vimGlobalState.macroModeState;
+ if (macroModeState.isPlaying) {
+ var query = macroModeState.replaySearchQueries.shift();
+ handleQuery(query, true /** ignoreCase */, false /** smartCase */);
+ } else {
+ showPrompt(cm, {
+ onClose: onPromptClose,
+ prefix: promptPrefix,
+ desc: searchPromptDesc,
+ onKeyUp: onPromptKeyUp,
+ onKeyDown: onPromptKeyDown
+ });
+ }
+ break;
+ case 'wordUnderCursor':
+ var word = expandWordUnderCursor(cm, false /** inclusive */,
+ true /** forward */, false /** bigWord */,
+ true /** noSymbol */);
+ var isKeyword = true;
+ if (!word) {
+ word = expandWordUnderCursor(cm, false /** inclusive */,
+ true /** forward */, false /** bigWord */,
+ false /** noSymbol */);
+ isKeyword = false;
+ }
+ if (!word) {
+ return;
+ }
+ var query = cm.getLine(word.start.line).substring(word.start.ch,
+ word.end.ch);
+ if (isKeyword && wholeWordOnly) {
+ query = '\\b' + query + '\\b';
+ } else {
+ query = escapeRegex(query);
+ }
+ vimGlobalState.jumpList.cachedCursor = cm.getCursor();
+ cm.setCursor(word.start);
+
+ handleQuery(query, true /** ignoreCase */, false /** smartCase */);
+ break;
+ }
+ },
+ processEx: function(cm, vim, command) {
+ function onPromptClose(input) {
+ vimGlobalState.exCommandHistoryController.pushInput(input);
+ vimGlobalState.exCommandHistoryController.reset();
+ exCommandDispatcher.processCommand(cm, input);
+ }
+ function onPromptKeyDown(e, input, close) {
+ var keyName = CodeMirror.keyName(e), up;
+ if (keyName == 'Esc' || keyName == 'Ctrl-C' || keyName == 'Ctrl-[' ||
+ (keyName == 'Backspace' && input == '')) {
+ vimGlobalState.exCommandHistoryController.pushInput(input);
+ vimGlobalState.exCommandHistoryController.reset();
+ CodeMirror.e_stop(e);
+ clearInputState(cm);
+ close();
+ cm.focus();
+ }
+ if (keyName == 'Up' || keyName == 'Down') {
+ up = keyName == 'Up' ? true : false;
+ input = vimGlobalState.exCommandHistoryController.nextMatch(input, up) || '';
+ close(input);
+ } else if (keyName == 'Ctrl-U') {
+ CodeMirror.e_stop(e);
+ close('');
+ } else {
+ if ( keyName != 'Left' && keyName != 'Right' && keyName != 'Ctrl' && keyName != 'Alt' && keyName != 'Shift')
+ vimGlobalState.exCommandHistoryController.reset();
+ }
+ }
+ if (command.type == 'keyToEx') {
+ exCommandDispatcher.processCommand(cm, command.exArgs.input);
+ } else {
+ if (vim.visualMode) {
+ showPrompt(cm, { onClose: onPromptClose, prefix: ':', value: '\'<,\'>',
+ onKeyDown: onPromptKeyDown});
+ } else {
+ showPrompt(cm, { onClose: onPromptClose, prefix: ':',
+ onKeyDown: onPromptKeyDown});
+ }
+ }
+ },
+ evalInput: function(cm, vim) {
+ var inputState = vim.inputState;
+ var motion = inputState.motion;
+ var motionArgs = inputState.motionArgs || {};
+ var operator = inputState.operator;
+ var operatorArgs = inputState.operatorArgs || {};
+ var registerName = inputState.registerName;
+ var sel = vim.sel;
+ var origHead = copyCursor(vim.visualMode ? clipCursorToContent(cm, sel.head): cm.getCursor('head'));
+ var origAnchor = copyCursor(vim.visualMode ? clipCursorToContent(cm, sel.anchor) : cm.getCursor('anchor'));
+ var oldHead = copyCursor(origHead);
+ var oldAnchor = copyCursor(origAnchor);
+ var newHead, newAnchor;
+ var repeat;
+ if (operator) {
+ this.recordLastEdit(vim, inputState);
+ }
+ if (inputState.repeatOverride !== undefined) {
+ repeat = inputState.repeatOverride;
+ } else {
+ repeat = inputState.getRepeat();
+ }
+ if (repeat > 0 && motionArgs.explicitRepeat) {
+ motionArgs.repeatIsExplicit = true;
+ } else if (motionArgs.noRepeat ||
+ (!motionArgs.explicitRepeat && repeat === 0)) {
+ repeat = 1;
+ motionArgs.repeatIsExplicit = false;
+ }
+ if (inputState.selectedCharacter) {
+ motionArgs.selectedCharacter = operatorArgs.selectedCharacter =
+ inputState.selectedCharacter;
+ }
+ motionArgs.repeat = repeat;
+ clearInputState(cm);
+ if (motion) {
+ var motionResult = motions[motion](cm, origHead, motionArgs, vim);
+ vim.lastMotion = motions[motion];
+ if (!motionResult) {
+ return;
+ }
+ if (motionArgs.toJumplist) {
+ if (!operator && cm.ace.curOp != null)
+ cm.ace.curOp.command.scrollIntoView = "center-animate"; // ace_patch
+ var jumpList = vimGlobalState.jumpList;
+ var cachedCursor = jumpList.cachedCursor;
+ if (cachedCursor) {
+ recordJumpPosition(cm, cachedCursor, motionResult);
+ delete jumpList.cachedCursor;
+ } else {
+ recordJumpPosition(cm, origHead, motionResult);
+ }
+ }
+ if (motionResult instanceof Array) {
+ newAnchor = motionResult[0];
+ newHead = motionResult[1];
+ } else {
+ newHead = motionResult;
+ }
+ if (!newHead) {
+ newHead = copyCursor(origHead);
+ }
+ if (vim.visualMode) {
+ if (!(vim.visualBlock && newHead.ch === Infinity)) {
+ newHead = clipCursorToContent(cm, newHead, vim.visualBlock);
+ }
+ if (newAnchor) {
+ newAnchor = clipCursorToContent(cm, newAnchor, true);
+ }
+ newAnchor = newAnchor || oldAnchor;
+ sel.anchor = newAnchor;
+ sel.head = newHead;
+ updateCmSelection(cm);
+ updateMark(cm, vim, '<',
+ cursorIsBefore(newAnchor, newHead) ? newAnchor
+ : newHead);
+ updateMark(cm, vim, '>',
+ cursorIsBefore(newAnchor, newHead) ? newHead
+ : newAnchor);
+ } else if (!operator) {
+ newHead = clipCursorToContent(cm, newHead);
+ cm.setCursor(newHead.line, newHead.ch);
+ }
+ }
+ if (operator) {
+ if (operatorArgs.lastSel) {
+ newAnchor = oldAnchor;
+ var lastSel = operatorArgs.lastSel;
+ var lineOffset = Math.abs(lastSel.head.line - lastSel.anchor.line);
+ var chOffset = Math.abs(lastSel.head.ch - lastSel.anchor.ch);
+ if (lastSel.visualLine) {
+ newHead = Pos(oldAnchor.line + lineOffset, oldAnchor.ch);
+ } else if (lastSel.visualBlock) {
+ newHead = Pos(oldAnchor.line + lineOffset, oldAnchor.ch + chOffset);
+ } else if (lastSel.head.line == lastSel.anchor.line) {
+ newHead = Pos(oldAnchor.line, oldAnchor.ch + chOffset);
+ } else {
+ newHead = Pos(oldAnchor.line + lineOffset, oldAnchor.ch);
+ }
+ vim.visualMode = true;
+ vim.visualLine = lastSel.visualLine;
+ vim.visualBlock = lastSel.visualBlock;
+ sel = vim.sel = {
+ anchor: newAnchor,
+ head: newHead
+ };
+ updateCmSelection(cm);
+ } else if (vim.visualMode) {
+ operatorArgs.lastSel = {
+ anchor: copyCursor(sel.anchor),
+ head: copyCursor(sel.head),
+ visualBlock: vim.visualBlock,
+ visualLine: vim.visualLine
+ };
+ }
+ var curStart, curEnd, linewise, mode;
+ var cmSel;
+ if (vim.visualMode) {
+ curStart = cursorMin(sel.head, sel.anchor);
+ curEnd = cursorMax(sel.head, sel.anchor);
+ linewise = vim.visualLine || operatorArgs.linewise;
+ mode = vim.visualBlock ? 'block' :
+ linewise ? 'line' :
+ 'char';
+ cmSel = makeCmSelection(cm, {
+ anchor: curStart,
+ head: curEnd
+ }, mode);
+ if (linewise) {
+ var ranges = cmSel.ranges;
+ if (mode == 'block') {
+ for (var i = 0; i < ranges.length; i++) {
+ ranges[i].head.ch = lineLength(cm, ranges[i].head.line);
+ }
+ } else if (mode == 'line') {
+ ranges[0].head = Pos(ranges[0].head.line + 1, 0);
+ }
+ }
+ } else {
+ curStart = copyCursor(newAnchor || oldAnchor);
+ curEnd = copyCursor(newHead || oldHead);
+ if (cursorIsBefore(curEnd, curStart)) {
+ var tmp = curStart;
+ curStart = curEnd;
+ curEnd = tmp;
+ }
+ linewise = motionArgs.linewise || operatorArgs.linewise;
+ if (linewise) {
+ expandSelectionToLine(cm, curStart, curEnd);
+ } else if (motionArgs.forward) {
+ clipToLine(cm, curStart, curEnd);
+ }
+ mode = 'char';
+ var exclusive = !motionArgs.inclusive || linewise;
+ cmSel = makeCmSelection(cm, {
+ anchor: curStart,
+ head: curEnd
+ }, mode, exclusive);
+ }
+ cm.setSelections(cmSel.ranges, cmSel.primary);
+ vim.lastMotion = null;
+ operatorArgs.repeat = repeat; // For indent in visual mode.
+ operatorArgs.registerName = registerName;
+ operatorArgs.linewise = linewise;
+ var operatorMoveTo = operators[operator](
+ cm, operatorArgs, cmSel.ranges, oldAnchor, newHead);
+ if (vim.visualMode) {
+ exitVisualMode(cm, operatorMoveTo != null);
+ }
+ if (operatorMoveTo) {
+ cm.setCursor(operatorMoveTo);
+ }
+ }
+ },
+ recordLastEdit: function(vim, inputState, actionCommand) {
+ var macroModeState = vimGlobalState.macroModeState;
+ if (macroModeState.isPlaying) { return; }
+ vim.lastEditInputState = inputState;
+ vim.lastEditActionCommand = actionCommand;
+ macroModeState.lastInsertModeChanges.changes = [];
+ macroModeState.lastInsertModeChanges.expectCursorActivityForChange = false;
+ }
+ };
+ var motions = {
+ moveToTopLine: function(cm, _head, motionArgs) {
+ var line = getUserVisibleLines(cm).top + motionArgs.repeat -1;
+ return Pos(line, findFirstNonWhiteSpaceCharacter(cm.getLine(line)));
+ },
+ moveToMiddleLine: function(cm) {
+ var range = getUserVisibleLines(cm);
+ var line = Math.floor((range.top + range.bottom) * 0.5);
+ return Pos(line, findFirstNonWhiteSpaceCharacter(cm.getLine(line)));
+ },
+ moveToBottomLine: function(cm, _head, motionArgs) {
+ var line = getUserVisibleLines(cm).bottom - motionArgs.repeat +1;
+ return Pos(line, findFirstNonWhiteSpaceCharacter(cm.getLine(line)));
+ },
+ expandToLine: function(_cm, head, motionArgs) {
+ var cur = head;
+ return Pos(cur.line + motionArgs.repeat - 1, Infinity);
+ },
+ findNext: function(cm, _head, motionArgs) {
+ var state = getSearchState(cm);
+ var query = state.getQuery();
+ if (!query) {
+ return;
+ }
+ var prev = !motionArgs.forward;
+ prev = (state.isReversed()) ? !prev : prev;
+ highlightSearchMatches(cm, query);
+ return findNext(cm, prev/** prev */, query, motionArgs.repeat);
+ },
+ goToMark: function(cm, _head, motionArgs, vim) {
+ var mark = vim.marks[motionArgs.selectedCharacter];
+ if (mark) {
+ var pos = mark.find();
+ return motionArgs.linewise ? { line: pos.line, ch: findFirstNonWhiteSpaceCharacter(cm.getLine(pos.line)) } : pos;
+ }
+ return null;
+ },
+ moveToOtherHighlightedEnd: function(cm, _head, motionArgs, vim) {
+ if (vim.visualBlock && motionArgs.sameLine) {
+ var sel = vim.sel;
+ return [
+ clipCursorToContent(cm, Pos(sel.anchor.line, sel.head.ch)),
+ clipCursorToContent(cm, Pos(sel.head.line, sel.anchor.ch))
+ ];
+ } else {
+ return ([vim.sel.head, vim.sel.anchor]);
+ }
+ },
+ jumpToMark: function(cm, head, motionArgs, vim) {
+ var best = head;
+ for (var i = 0; i < motionArgs.repeat; i++) {
+ var cursor = best;
+ for (var key in vim.marks) {
+ if (!isLowerCase(key)) {
+ continue;
+ }
+ var mark = vim.marks[key].find();
+ var isWrongDirection = (motionArgs.forward) ?
+ cursorIsBefore(mark, cursor) : cursorIsBefore(cursor, mark);
+
+ if (isWrongDirection) {
+ continue;
+ }
+ if (motionArgs.linewise && (mark.line == cursor.line)) {
+ continue;
+ }
+
+ var equal = cursorEqual(cursor, best);
+ var between = (motionArgs.forward) ?
+ cursorIsBetween(cursor, mark, best) :
+ cursorIsBetween(best, mark, cursor);
+
+ if (equal || between) {
+ best = mark;
+ }
+ }
+ }
+
+ if (motionArgs.linewise) {
+ best = Pos(best.line, findFirstNonWhiteSpaceCharacter(cm.getLine(best.line)));
+ }
+ return best;
+ },
+ moveByCharacters: function(_cm, head, motionArgs) {
+ var cur = head;
+ var repeat = motionArgs.repeat;
+ var ch = motionArgs.forward ? cur.ch + repeat : cur.ch - repeat;
+ return Pos(cur.line, ch);
+ },
+ moveByLines: function(cm, head, motionArgs, vim) {
+ var cur = head;
+ var endCh = cur.ch;
+ switch (vim.lastMotion) {
+ case this.moveByLines:
+ case this.moveByDisplayLines:
+ case this.moveByScroll:
+ case this.moveToColumn:
+ case this.moveToEol:
+ endCh = vim.lastHPos;
+ break;
+ default:
+ vim.lastHPos = endCh;
+ }
+ var repeat = motionArgs.repeat+(motionArgs.repeatOffset||0);
+ var line = motionArgs.forward ? cur.line + repeat : cur.line - repeat;
+ var first = cm.firstLine();
+ var last = cm.lastLine();
+ if ((line < first && cur.line == first) ||
+ (line > last && cur.line == last)) {
+ return;
+ }
+ var fold = cm.ace.session.getFoldLine(line);
+ if (fold) {
+ if (motionArgs.forward) {
+ if (line > fold.start.row)
+ line = fold.end.row + 1;
+ } else {
+ line = fold.start.row;
+ }
+ }
+ if (motionArgs.toFirstChar){
+ endCh=findFirstNonWhiteSpaceCharacter(cm.getLine(line));
+ vim.lastHPos = endCh;
+ }
+ vim.lastHSPos = cm.charCoords(Pos(line, endCh),'div').left;
+ return Pos(line, endCh);
+ },
+ moveByDisplayLines: function(cm, head, motionArgs, vim) {
+ var cur = head;
+ switch (vim.lastMotion) {
+ case this.moveByDisplayLines:
+ case this.moveByScroll:
+ case this.moveByLines:
+ case this.moveToColumn:
+ case this.moveToEol:
+ break;
+ default:
+ vim.lastHSPos = cm.charCoords(cur,'div').left;
+ }
+ var repeat = motionArgs.repeat;
+ var res=cm.findPosV(cur,(motionArgs.forward ? repeat : -repeat),'line',vim.lastHSPos);
+ if (res.hitSide) {
+ if (motionArgs.forward) {
+ var lastCharCoords = cm.charCoords(res, 'div');
+ var goalCoords = { top: lastCharCoords.top + 8, left: vim.lastHSPos };
+ var res = cm.coordsChar(goalCoords, 'div');
+ } else {
+ var resCoords = cm.charCoords(Pos(cm.firstLine(), 0), 'div');
+ resCoords.left = vim.lastHSPos;
+ res = cm.coordsChar(resCoords, 'div');
+ }
+ }
+ vim.lastHPos = res.ch;
+ return res;
+ },
+ moveByPage: function(cm, head, motionArgs) {
+ var curStart = head;
+ var repeat = motionArgs.repeat;
+ return cm.findPosV(curStart, (motionArgs.forward ? repeat : -repeat), 'page');
+ },
+ moveByParagraph: function(cm, head, motionArgs) {
+ var dir = motionArgs.forward ? 1 : -1;
+ return findParagraph(cm, head, motionArgs.repeat, dir);
+ },
+ moveByScroll: function(cm, head, motionArgs, vim) {
+ var scrollbox = cm.getScrollInfo();
+ var curEnd = null;
+ var repeat = motionArgs.repeat;
+ if (!repeat) {
+ repeat = scrollbox.clientHeight / (2 * cm.defaultTextHeight());
+ }
+ var orig = cm.charCoords(head, 'local');
+ motionArgs.repeat = repeat;
+ var curEnd = motions.moveByDisplayLines(cm, head, motionArgs, vim);
+ if (!curEnd) {
+ return null;
+ }
+ var dest = cm.charCoords(curEnd, 'local');
+ cm.scrollTo(null, scrollbox.top + dest.top - orig.top);
+ return curEnd;
+ },
+ moveByWords: function(cm, head, motionArgs) {
+ return moveToWord(cm, head, motionArgs.repeat, !!motionArgs.forward,
+ !!motionArgs.wordEnd, !!motionArgs.bigWord);
+ },
+ moveTillCharacter: function(cm, _head, motionArgs) {
+ var repeat = motionArgs.repeat;
+ var curEnd = moveToCharacter(cm, repeat, motionArgs.forward,
+ motionArgs.selectedCharacter);
+ var increment = motionArgs.forward ? -1 : 1;
+ recordLastCharacterSearch(increment, motionArgs);
+ if (!curEnd) return null;
+ curEnd.ch += increment;
+ return curEnd;
+ },
+ moveToCharacter: function(cm, head, motionArgs) {
+ var repeat = motionArgs.repeat;
+ recordLastCharacterSearch(0, motionArgs);
+ return moveToCharacter(cm, repeat, motionArgs.forward,
+ motionArgs.selectedCharacter) || head;
+ },
+ moveToSymbol: function(cm, head, motionArgs) {
+ var repeat = motionArgs.repeat;
+ return findSymbol(cm, repeat, motionArgs.forward,
+ motionArgs.selectedCharacter) || head;
+ },
+ moveToColumn: function(cm, head, motionArgs, vim) {
+ var repeat = motionArgs.repeat;
+ vim.lastHPos = repeat - 1;
+ vim.lastHSPos = cm.charCoords(head,'div').left;
+ return moveToColumn(cm, repeat);
+ },
+ moveToEol: function(cm, head, motionArgs, vim) {
+ var cur = head;
+ vim.lastHPos = Infinity;
+ var retval= Pos(cur.line + motionArgs.repeat - 1, Infinity);
+ var end=cm.clipPos(retval);
+ end.ch--;
+ vim.lastHSPos = cm.charCoords(end,'div').left;
+ return retval;
+ },
+ moveToFirstNonWhiteSpaceCharacter: function(cm, head) {
+ var cursor = head;
+ return Pos(cursor.line,
+ findFirstNonWhiteSpaceCharacter(cm.getLine(cursor.line)));
+ },
+ moveToMatchedSymbol: function(cm, head) {
+ var cursor = head;
+ var line = cursor.line;
+ var ch = cursor.ch;
+ var lineText = cm.getLine(line);
+ var symbol;
+ do {
+ symbol = lineText.charAt(ch++);
+ if (symbol && isMatchableSymbol(symbol)) {
+ var style = cm.getTokenTypeAt(Pos(line, ch));
+ if (style !== "string" && style !== "comment") {
+ break;
+ }
+ }
+ } while (symbol);
+ if (symbol) {
+ var matched = cm.findMatchingBracket(Pos(line, ch));
+ return matched.to;
+ } else {
+ return cursor;
+ }
+ },
+ moveToStartOfLine: function(_cm, head) {
+ return Pos(head.line, 0);
+ },
+ moveToLineOrEdgeOfDocument: function(cm, _head, motionArgs) {
+ var lineNum = motionArgs.forward ? cm.lastLine() : cm.firstLine();
+ if (motionArgs.repeatIsExplicit) {
+ lineNum = motionArgs.repeat - cm.getOption('firstLineNumber');
+ }
+ return Pos(lineNum,
+ findFirstNonWhiteSpaceCharacter(cm.getLine(lineNum)));
+ },
+ textObjectManipulation: function(cm, head, motionArgs, vim) {
+ var mirroredPairs = {'(': ')', ')': '(',
+ '{': '}', '}': '{',
+ '[': ']', ']': '['};
+ var selfPaired = {'\'': true, '"': true};
+
+ var character = motionArgs.selectedCharacter;
+ if (character == 'b') {
+ character = '(';
+ } else if (character == 'B') {
+ character = '{';
+ }
+ var inclusive = !motionArgs.textObjectInner;
+
+ var tmp;
+ if (mirroredPairs[character]) {
+ tmp = selectCompanionObject(cm, head, character, inclusive);
+ } else if (selfPaired[character]) {
+ tmp = findBeginningAndEnd(cm, head, character, inclusive);
+ } else if (character === 'W') {
+ tmp = expandWordUnderCursor(cm, inclusive, true /** forward */,
+ true /** bigWord */);
+ } else if (character === 'w') {
+ tmp = expandWordUnderCursor(cm, inclusive, true /** forward */,
+ false /** bigWord */);
+ } else if (character === 'p') {
+ tmp = findParagraph(cm, head, motionArgs.repeat, 0, inclusive);
+ motionArgs.linewise = true;
+ if (vim.visualMode) {
+ if (!vim.visualLine) { vim.visualLine = true; }
+ } else {
+ var operatorArgs = vim.inputState.operatorArgs;
+ if (operatorArgs) { operatorArgs.linewise = true; }
+ tmp.end.line--;
+ }
+ } else {
+ return null;
+ }
+
+ if (!cm.state.vim.visualMode) {
+ return [tmp.start, tmp.end];
+ } else {
+ return expandSelection(cm, tmp.start, tmp.end);
+ }
+ },
+
+ repeatLastCharacterSearch: function(cm, head, motionArgs) {
+ var lastSearch = vimGlobalState.lastChararacterSearch;
+ var repeat = motionArgs.repeat;
+ var forward = motionArgs.forward === lastSearch.forward;
+ var increment = (lastSearch.increment ? 1 : 0) * (forward ? -1 : 1);
+ cm.moveH(-increment, 'char');
+ motionArgs.inclusive = forward ? true : false;
+ var curEnd = moveToCharacter(cm, repeat, forward, lastSearch.selectedCharacter);
+ if (!curEnd) {
+ cm.moveH(increment, 'char');
+ return head;
+ }
+ curEnd.ch += increment;
+ return curEnd;
+ }
+ };
+
+ function defineMotion(name, fn) {
+ motions[name] = fn;
+ }
+
+ function fillArray(val, times) {
+ var arr = [];
+ for (var i = 0; i < times; i++) {
+ arr.push(val);
+ }
+ return arr;
+ }
+ var operators = {
+ change: function(cm, args, ranges) {
+ var finalHead, text;
+ var vim = cm.state.vim;
+ vimGlobalState.macroModeState.lastInsertModeChanges.inVisualBlock = vim.visualBlock;
+ if (!vim.visualMode) {
+ var anchor = ranges[0].anchor,
+ head = ranges[0].head;
+ text = cm.getRange(anchor, head);
+ var lastState = vim.lastEditInputState || {};
+ if (lastState.motion == "moveByWords" && !isWhiteSpaceString(text)) {
+ var match = (/\s+$/).exec(text);
+ if (match && lastState.motionArgs && lastState.motionArgs.forward) {
+ head = offsetCursor(head, 0, - match[0].length);
+ text = text.slice(0, - match[0].length);
+ }
+ }
+ var prevLineEnd = new Pos(anchor.line - 1, Number.MAX_VALUE);
+ var wasLastLine = cm.firstLine() == cm.lastLine();
+ if (head.line > cm.lastLine() && args.linewise && !wasLastLine) {
+ cm.replaceRange('', prevLineEnd, head);
+ } else {
+ cm.replaceRange('', anchor, head);
+ }
+ if (args.linewise) {
+ if (!wasLastLine) {
+ cm.setCursor(prevLineEnd);
+ CodeMirror.commands.newlineAndIndent(cm);
+ }
+ anchor.ch = Number.MAX_VALUE;
+ }
+ finalHead = anchor;
+ } else {
+ text = cm.getSelection();
+ var replacement = fillArray('', ranges.length);
+ cm.replaceSelections(replacement);
+ finalHead = cursorMin(ranges[0].head, ranges[0].anchor);
+ }
+ vimGlobalState.registerController.pushText(
+ args.registerName, 'change', text,
+ args.linewise, ranges.length > 1);
+ actions.enterInsertMode(cm, {head: finalHead}, cm.state.vim);
+ },
+ 'delete': function(cm, args, ranges) {
+ var finalHead, text;
+ var vim = cm.state.vim;
+ if (!vim.visualBlock) {
+ var anchor = ranges[0].anchor,
+ head = ranges[0].head;
+ if (args.linewise &&
+ head.line != cm.firstLine() &&
+ anchor.line == cm.lastLine() &&
+ anchor.line == head.line - 1) {
+ if (anchor.line == cm.firstLine()) {
+ anchor.ch = 0;
+ } else {
+ anchor = Pos(anchor.line - 1, lineLength(cm, anchor.line - 1));
+ }
+ }
+ text = cm.getRange(anchor, head);
+ cm.replaceRange('', anchor, head);
+ finalHead = anchor;
+ if (args.linewise) {
+ finalHead = motions.moveToFirstNonWhiteSpaceCharacter(cm, anchor);
+ }
+ } else {
+ text = cm.getSelection();
+ var replacement = fillArray('', ranges.length);
+ cm.replaceSelections(replacement);
+ finalHead = ranges[0].anchor;
+ }
+ vimGlobalState.registerController.pushText(
+ args.registerName, 'delete', text,
+ args.linewise, vim.visualBlock);
+ return clipCursorToContent(cm, finalHead);
+ },
+ indent: function(cm, args, ranges) {
+ var vim = cm.state.vim;
+ var startLine = ranges[0].anchor.line;
+ var endLine = vim.visualBlock ?
+ ranges[ranges.length - 1].anchor.line :
+ ranges[0].head.line;
+ var repeat = (vim.visualMode) ? args.repeat : 1;
+ if (args.linewise) {
+ endLine--;
+ }
+ for (var i = startLine; i <= endLine; i++) {
+ for (var j = 0; j < repeat; j++) {
+ cm.indentLine(i, args.indentRight);
+ }
+ }
+ return motions.moveToFirstNonWhiteSpaceCharacter(cm, ranges[0].anchor);
+ },
+ changeCase: function(cm, args, ranges, oldAnchor, newHead) {
+ var selections = cm.getSelections();
+ var swapped = [];
+ var toLower = args.toLower;
+ for (var j = 0; j < selections.length; j++) {
+ var toSwap = selections[j];
+ var text = '';
+ if (toLower === true) {
+ text = toSwap.toLowerCase();
+ } else if (toLower === false) {
+ text = toSwap.toUpperCase();
+ } else {
+ for (var i = 0; i < toSwap.length; i++) {
+ var character = toSwap.charAt(i);
+ text += isUpperCase(character) ? character.toLowerCase() :
+ character.toUpperCase();
+ }
+ }
+ swapped.push(text);
+ }
+ cm.replaceSelections(swapped);
+ if (args.shouldMoveCursor){
+ return newHead;
+ } else if (!cm.state.vim.visualMode && args.linewise && ranges[0].anchor.line + 1 == ranges[0].head.line) {
+ return motions.moveToFirstNonWhiteSpaceCharacter(cm, oldAnchor);
+ } else if (args.linewise){
+ return oldAnchor;
+ } else {
+ return cursorMin(ranges[0].anchor, ranges[0].head);
+ }
+ },
+ yank: function(cm, args, ranges, oldAnchor) {
+ var vim = cm.state.vim;
+ var text = cm.getSelection();
+ var endPos = vim.visualMode
+ ? cursorMin(vim.sel.anchor, vim.sel.head, ranges[0].head, ranges[0].anchor)
+ : oldAnchor;
+ vimGlobalState.registerController.pushText(
+ args.registerName, 'yank',
+ text, args.linewise, vim.visualBlock);
+ return endPos;
+ }
+ };
+
+ function defineOperator(name, fn) {
+ operators[name] = fn;
+ }
+
+ var actions = {
+ jumpListWalk: function(cm, actionArgs, vim) {
+ if (vim.visualMode) {
+ return;
+ }
+ var repeat = actionArgs.repeat;
+ var forward = actionArgs.forward;
+ var jumpList = vimGlobalState.jumpList;
+
+ var mark = jumpList.move(cm, forward ? repeat : -repeat);
+ var markPos = mark ? mark.find() : undefined;
+ markPos = markPos ? markPos : cm.getCursor();
+ cm.setCursor(markPos);
+ cm.ace.curOp.command.scrollIntoView = "center-animate"; // ace_patch
+ },
+ scroll: function(cm, actionArgs, vim) {
+ if (vim.visualMode) {
+ return;
+ }
+ var repeat = actionArgs.repeat || 1;
+ var lineHeight = cm.defaultTextHeight();
+ var top = cm.getScrollInfo().top;
+ var delta = lineHeight * repeat;
+ var newPos = actionArgs.forward ? top + delta : top - delta;
+ var cursor = copyCursor(cm.getCursor());
+ var cursorCoords = cm.charCoords(cursor, 'local');
+ if (actionArgs.forward) {
+ if (newPos > cursorCoords.top) {
+ cursor.line += (newPos - cursorCoords.top) / lineHeight;
+ cursor.line = Math.ceil(cursor.line);
+ cm.setCursor(cursor);
+ cursorCoords = cm.charCoords(cursor, 'local');
+ cm.scrollTo(null, cursorCoords.top);
+ } else {
+ cm.scrollTo(null, newPos);
+ }
+ } else {
+ var newBottom = newPos + cm.getScrollInfo().clientHeight;
+ if (newBottom < cursorCoords.bottom) {
+ cursor.line -= (cursorCoords.bottom - newBottom) / lineHeight;
+ cursor.line = Math.floor(cursor.line);
+ cm.setCursor(cursor);
+ cursorCoords = cm.charCoords(cursor, 'local');
+ cm.scrollTo(
+ null, cursorCoords.bottom - cm.getScrollInfo().clientHeight);
+ } else {
+ cm.scrollTo(null, newPos);
+ }
+ }
+ },
+ scrollToCursor: function(cm, actionArgs) {
+ var lineNum = cm.getCursor().line;
+ var charCoords = cm.charCoords(Pos(lineNum, 0), 'local');
+ var height = cm.getScrollInfo().clientHeight;
+ var y = charCoords.top;
+ var lineHeight = charCoords.bottom - y;
+ switch (actionArgs.position) {
+ case 'center': y = y - (height / 2) + lineHeight;
+ break;
+ case 'bottom': y = y - height + lineHeight*1.4;
+ break;
+ case 'top': y = y + lineHeight*0.4;
+ break;
+ }
+ cm.scrollTo(null, y);
+ },
+ replayMacro: function(cm, actionArgs, vim) {
+ var registerName = actionArgs.selectedCharacter;
+ var repeat = actionArgs.repeat;
+ var macroModeState = vimGlobalState.macroModeState;
+ if (registerName == '@') {
+ registerName = macroModeState.latestRegister;
+ }
+ while(repeat--){
+ executeMacroRegister(cm, vim, macroModeState, registerName);
+ }
+ },
+ enterMacroRecordMode: function(cm, actionArgs) {
+ var macroModeState = vimGlobalState.macroModeState;
+ var registerName = actionArgs.selectedCharacter;
+ macroModeState.enterMacroRecordMode(cm, registerName);
+ },
+ enterInsertMode: function(cm, actionArgs, vim) {
+ if (cm.getOption('readOnly')) { return; }
+ vim.insertMode = true;
+ vim.insertModeRepeat = actionArgs && actionArgs.repeat || 1;
+ var insertAt = (actionArgs) ? actionArgs.insertAt : null;
+ var sel = vim.sel;
+ var head = actionArgs.head || cm.getCursor('head');
+ var height = cm.listSelections().length;
+ if (insertAt == 'eol') {
+ head = Pos(head.line, lineLength(cm, head.line));
+ } else if (insertAt == 'charAfter') {
+ head = offsetCursor(head, 0, 1);
+ } else if (insertAt == 'firstNonBlank') {
+ head = motions.moveToFirstNonWhiteSpaceCharacter(cm, head);
+ } else if (insertAt == 'startOfSelectedArea') {
+ if (!vim.visualBlock) {
+ if (sel.head.line < sel.anchor.line) {
+ head = sel.head;
+ } else {
+ head = Pos(sel.anchor.line, 0);
+ }
+ } else {
+ head = Pos(
+ Math.min(sel.head.line, sel.anchor.line),
+ Math.min(sel.head.ch, sel.anchor.ch));
+ height = Math.abs(sel.head.line - sel.anchor.line) + 1;
+ }
+ } else if (insertAt == 'endOfSelectedArea') {
+ if (!vim.visualBlock) {
+ if (sel.head.line >= sel.anchor.line) {
+ head = offsetCursor(sel.head, 0, 1);
+ } else {
+ head = Pos(sel.anchor.line, 0);
+ }
+ } else {
+ head = Pos(
+ Math.min(sel.head.line, sel.anchor.line),
+ Math.max(sel.head.ch + 1, sel.anchor.ch));
+ height = Math.abs(sel.head.line - sel.anchor.line) + 1;
+ }
+ } else if (insertAt == 'inplace') {
+ if (vim.visualMode){
+ return;
+ }
+ }
+ cm.setOption('keyMap', 'vim-insert');
+ cm.setOption('disableInput', false);
+ if (actionArgs && actionArgs.replace) {
+ cm.toggleOverwrite(true);
+ cm.setOption('keyMap', 'vim-replace');
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "replace"});
+ } else {
+ cm.setOption('keyMap', 'vim-insert');
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "insert"});
+ }
+ if (!vimGlobalState.macroModeState.isPlaying) {
+ cm.on('change', onChange);
+ CodeMirror.on(cm.getInputField(), 'keydown', onKeyEventTargetKeyDown);
+ }
+ if (vim.visualMode) {
+ exitVisualMode(cm);
+ }
+ selectForInsert(cm, head, height);
+ },
+ toggleVisualMode: function(cm, actionArgs, vim) {
+ var repeat = actionArgs.repeat;
+ var anchor = cm.getCursor();
+ var head;
+ if (!vim.visualMode) {
+ vim.visualMode = true;
+ vim.visualLine = !!actionArgs.linewise;
+ vim.visualBlock = !!actionArgs.blockwise;
+ head = clipCursorToContent(
+ cm, Pos(anchor.line, anchor.ch + repeat - 1),
+ true /** includeLineBreak */);
+ vim.sel = {
+ anchor: anchor,
+ head: head
+ };
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "visual", subMode: vim.visualLine ? "linewise" : vim.visualBlock ? "blockwise" : ""});
+ updateCmSelection(cm);
+ updateMark(cm, vim, '<', cursorMin(anchor, head));
+ updateMark(cm, vim, '>', cursorMax(anchor, head));
+ } else if (vim.visualLine ^ actionArgs.linewise ||
+ vim.visualBlock ^ actionArgs.blockwise) {
+ vim.visualLine = !!actionArgs.linewise;
+ vim.visualBlock = !!actionArgs.blockwise;
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "visual", subMode: vim.visualLine ? "linewise" : vim.visualBlock ? "blockwise" : ""});
+ updateCmSelection(cm);
+ } else {
+ exitVisualMode(cm);
+ }
+ },
+ reselectLastSelection: function(cm, _actionArgs, vim) {
+ var lastSelection = vim.lastSelection;
+ if (vim.visualMode) {
+ updateLastSelection(cm, vim);
+ }
+ if (lastSelection) {
+ var anchor = lastSelection.anchorMark.find();
+ var head = lastSelection.headMark.find();
+ if (!anchor || !head) {
+ return;
+ }
+ vim.sel = {
+ anchor: anchor,
+ head: head
+ };
+ vim.visualMode = true;
+ vim.visualLine = lastSelection.visualLine;
+ vim.visualBlock = lastSelection.visualBlock;
+ updateCmSelection(cm);
+ updateMark(cm, vim, '<', cursorMin(anchor, head));
+ updateMark(cm, vim, '>', cursorMax(anchor, head));
+ CodeMirror.signal(cm, 'vim-mode-change', {
+ mode: 'visual',
+ subMode: vim.visualLine ? 'linewise' :
+ vim.visualBlock ? 'blockwise' : ''});
+ }
+ },
+ joinLines: function(cm, actionArgs, vim) {
+ var curStart, curEnd;
+ if (vim.visualMode) {
+ curStart = cm.getCursor('anchor');
+ curEnd = cm.getCursor('head');
+ if (cursorIsBefore(curEnd, curStart)) {
+ var tmp = curEnd;
+ curEnd = curStart;
+ curStart = tmp;
+ }
+ curEnd.ch = lineLength(cm, curEnd.line) - 1;
+ } else {
+ var repeat = Math.max(actionArgs.repeat, 2);
+ curStart = cm.getCursor();
+ curEnd = clipCursorToContent(cm, Pos(curStart.line + repeat - 1,
+ Infinity));
+ }
+ var finalCh = 0;
+ for (var i = curStart.line; i < curEnd.line; i++) {
+ finalCh = lineLength(cm, curStart.line);
+ var tmp = Pos(curStart.line + 1,
+ lineLength(cm, curStart.line + 1));
+ var text = cm.getRange(curStart, tmp);
+ text = text.replace(/\n\s*/g, ' ');
+ cm.replaceRange(text, curStart, tmp);
+ }
+ var curFinalPos = Pos(curStart.line, finalCh);
+ if (vim.visualMode) {
+ exitVisualMode(cm, false);
+ }
+ cm.setCursor(curFinalPos);
+ },
+ newLineAndEnterInsertMode: function(cm, actionArgs, vim) {
+ vim.insertMode = true;
+ var insertAt = copyCursor(cm.getCursor());
+ if (insertAt.line === cm.firstLine() && !actionArgs.after) {
+ cm.replaceRange('\n', Pos(cm.firstLine(), 0));
+ cm.setCursor(cm.firstLine(), 0);
+ } else {
+ insertAt.line = (actionArgs.after) ? insertAt.line :
+ insertAt.line - 1;
+ insertAt.ch = lineLength(cm, insertAt.line);
+ cm.setCursor(insertAt);
+ var newlineFn = CodeMirror.commands.newlineAndIndentContinueComment ||
+ CodeMirror.commands.newlineAndIndent;
+ newlineFn(cm);
+ }
+ this.enterInsertMode(cm, { repeat: actionArgs.repeat }, vim);
+ },
+ paste: function(cm, actionArgs, vim) {
+ var cur = copyCursor(cm.getCursor());
+ var register = vimGlobalState.registerController.getRegister(
+ actionArgs.registerName);
+ var text = register.toString();
+ if (!text) {
+ return;
+ }
+ if (actionArgs.matchIndent) {
+ var tabSize = cm.getOption("tabSize");
+ var whitespaceLength = function(str) {
+ var tabs = (str.split("\t").length - 1);
+ var spaces = (str.split(" ").length - 1);
+ return tabs * tabSize + spaces * 1;
+ };
+ var currentLine = cm.getLine(cm.getCursor().line);
+ var indent = whitespaceLength(currentLine.match(/^\s*/)[0]);
+ var chompedText = text.replace(/\n$/, '');
+ var wasChomped = text !== chompedText;
+ var firstIndent = whitespaceLength(text.match(/^\s*/)[0]);
+ var text = chompedText.replace(/^\s*/gm, function(wspace) {
+ var newIndent = indent + (whitespaceLength(wspace) - firstIndent);
+ if (newIndent < 0) {
+ return "";
+ }
+ else if (cm.getOption("indentWithTabs")) {
+ var quotient = Math.floor(newIndent / tabSize);
+ return Array(quotient + 1).join('\t');
+ }
+ else {
+ return Array(newIndent + 1).join(' ');
+ }
+ });
+ text += wasChomped ? "\n" : "";
+ }
+ if (actionArgs.repeat > 1) {
+ var text = Array(actionArgs.repeat + 1).join(text);
+ }
+ var linewise = register.linewise;
+ var blockwise = register.blockwise;
+ if (linewise && !blockwise) {
+ if(vim.visualMode) {
+ text = vim.visualLine ? text.slice(0, -1) : '\n' + text.slice(0, text.length - 1) + '\n';
+ } else if (actionArgs.after) {
+ text = '\n' + text.slice(0, text.length - 1);
+ cur.ch = lineLength(cm, cur.line);
+ } else {
+ cur.ch = 0;
+ }
+ } else {
+ if (blockwise) {
+ text = text.split('\n');
+ for (var i = 0; i < text.length; i++) {
+ text[i] = (text[i] == '') ? ' ' : text[i];
+ }
+ }
+ cur.ch += actionArgs.after ? 1 : 0;
+ }
+ var curPosFinal;
+ var idx;
+ if (vim.visualMode) {
+ vim.lastPastedText = text;
+ var lastSelectionCurEnd;
+ var selectedArea = getSelectedAreaRange(cm, vim);
+ var selectionStart = selectedArea[0];
+ var selectionEnd = selectedArea[1];
+ var selectedText = cm.getSelection();
+ var selections = cm.listSelections();
+ var emptyStrings = new Array(selections.length).join('1').split('1');
+ if (vim.lastSelection) {
+ lastSelectionCurEnd = vim.lastSelection.headMark.find();
+ }
+ vimGlobalState.registerController.unnamedRegister.setText(selectedText);
+ if (blockwise) {
+ cm.replaceSelections(emptyStrings);
+ selectionEnd = Pos(selectionStart.line + text.length-1, selectionStart.ch);
+ cm.setCursor(selectionStart);
+ selectBlock(cm, selectionEnd);
+ cm.replaceSelections(text);
+ curPosFinal = selectionStart;
+ } else if (vim.visualBlock) {
+ cm.replaceSelections(emptyStrings);
+ cm.setCursor(selectionStart);
+ cm.replaceRange(text, selectionStart, selectionStart);
+ curPosFinal = selectionStart;
+ } else {
+ cm.replaceRange(text, selectionStart, selectionEnd);
+ curPosFinal = cm.posFromIndex(cm.indexFromPos(selectionStart) + text.length - 1);
+ }
+ if(lastSelectionCurEnd) {
+ vim.lastSelection.headMark = cm.setBookmark(lastSelectionCurEnd);
+ }
+ if (linewise) {
+ curPosFinal.ch=0;
+ }
+ } else {
+ if (blockwise) {
+ cm.setCursor(cur);
+ for (var i = 0; i < text.length; i++) {
+ var line = cur.line+i;
+ if (line > cm.lastLine()) {
+ cm.replaceRange('\n', Pos(line, 0));
+ }
+ var lastCh = lineLength(cm, line);
+ if (lastCh < cur.ch) {
+ extendLineToColumn(cm, line, cur.ch);
+ }
+ }
+ cm.setCursor(cur);
+ selectBlock(cm, Pos(cur.line + text.length-1, cur.ch));
+ cm.replaceSelections(text);
+ curPosFinal = cur;
+ } else {
+ cm.replaceRange(text, cur);
+ if (linewise && actionArgs.after) {
+ curPosFinal = Pos(
+ cur.line + 1,
+ findFirstNonWhiteSpaceCharacter(cm.getLine(cur.line + 1)));
+ } else if (linewise && !actionArgs.after) {
+ curPosFinal = Pos(
+ cur.line,
+ findFirstNonWhiteSpaceCharacter(cm.getLine(cur.line)));
+ } else if (!linewise && actionArgs.after) {
+ idx = cm.indexFromPos(cur);
+ curPosFinal = cm.posFromIndex(idx + text.length - 1);
+ } else {
+ idx = cm.indexFromPos(cur);
+ curPosFinal = cm.posFromIndex(idx + text.length);
+ }
+ }
+ }
+ if (vim.visualMode) {
+ exitVisualMode(cm, false);
+ }
+ cm.setCursor(curPosFinal);
+ },
+ undo: function(cm, actionArgs) {
+ cm.operation(function() {
+ repeatFn(cm, CodeMirror.commands.undo, actionArgs.repeat)();
+ cm.setCursor(cm.getCursor('anchor'));
+ });
+ },
+ redo: function(cm, actionArgs) {
+ repeatFn(cm, CodeMirror.commands.redo, actionArgs.repeat)();
+ },
+ setRegister: function(_cm, actionArgs, vim) {
+ vim.inputState.registerName = actionArgs.selectedCharacter;
+ },
+ setMark: function(cm, actionArgs, vim) {
+ var markName = actionArgs.selectedCharacter;
+ updateMark(cm, vim, markName, cm.getCursor());
+ },
+ replace: function(cm, actionArgs, vim) {
+ var replaceWith = actionArgs.selectedCharacter;
+ var curStart = cm.getCursor();
+ var replaceTo;
+ var curEnd;
+ var selections = cm.listSelections();
+ if (vim.visualMode) {
+ curStart = cm.getCursor('start');
+ curEnd = cm.getCursor('end');
+ } else {
+ var line = cm.getLine(curStart.line);
+ replaceTo = curStart.ch + actionArgs.repeat;
+ if (replaceTo > line.length) {
+ replaceTo=line.length;
+ }
+ curEnd = Pos(curStart.line, replaceTo);
+ }
+ if (replaceWith=='\n') {
+ if (!vim.visualMode) cm.replaceRange('', curStart, curEnd);
+ (CodeMirror.commands.newlineAndIndentContinueComment || CodeMirror.commands.newlineAndIndent)(cm);
+ } else {
+ var replaceWithStr = cm.getRange(curStart, curEnd);
+ replaceWithStr = replaceWithStr.replace(/[^\n]/g, replaceWith);
+ if (vim.visualBlock) {
+ var spaces = new Array(cm.getOption("tabSize")+1).join(' ');
+ replaceWithStr = cm.getSelection();
+ replaceWithStr = replaceWithStr.replace(/\t/g, spaces).replace(/[^\n]/g, replaceWith).split('\n');
+ cm.replaceSelections(replaceWithStr);
+ } else {
+ cm.replaceRange(replaceWithStr, curStart, curEnd);
+ }
+ if (vim.visualMode) {
+ curStart = cursorIsBefore(selections[0].anchor, selections[0].head) ?
+ selections[0].anchor : selections[0].head;
+ cm.setCursor(curStart);
+ exitVisualMode(cm, false);
+ } else {
+ cm.setCursor(offsetCursor(curEnd, 0, -1));
+ }
+ }
+ },
+ incrementNumberToken: function(cm, actionArgs) {
+ var cur = cm.getCursor();
+ var lineStr = cm.getLine(cur.line);
+ var re = /-?\d+/g;
+ var match;
+ var start;
+ var end;
+ var numberStr;
+ var token;
+ while ((match = re.exec(lineStr)) !== null) {
+ token = match[0];
+ start = match.index;
+ end = start + token.length;
+ if (cur.ch < end)break;
+ }
+ if (!actionArgs.backtrack && (end <= cur.ch))return;
+ if (token) {
+ var increment = actionArgs.increase ? 1 : -1;
+ var number = parseInt(token) + (increment * actionArgs.repeat);
+ var from = Pos(cur.line, start);
+ var to = Pos(cur.line, end);
+ numberStr = number.toString();
+ cm.replaceRange(numberStr, from, to);
+ } else {
+ return;
+ }
+ cm.setCursor(Pos(cur.line, start + numberStr.length - 1));
+ },
+ repeatLastEdit: function(cm, actionArgs, vim) {
+ var lastEditInputState = vim.lastEditInputState;
+ if (!lastEditInputState) { return; }
+ var repeat = actionArgs.repeat;
+ if (repeat && actionArgs.repeatIsExplicit) {
+ vim.lastEditInputState.repeatOverride = repeat;
+ } else {
+ repeat = vim.lastEditInputState.repeatOverride || repeat;
+ }
+ repeatLastEdit(cm, vim, repeat, false /** repeatForInsert */);
+ },
+ exitInsertMode: exitInsertMode
+ };
+
+ function defineAction(name, fn) {
+ actions[name] = fn;
+ }
+ function clipCursorToContent(cm, cur, includeLineBreak) {
+ var line = Math.min(Math.max(cm.firstLine(), cur.line), cm.lastLine() );
+ var maxCh = lineLength(cm, line) - 1;
+ maxCh = (includeLineBreak) ? maxCh + 1 : maxCh;
+ var ch = Math.min(Math.max(0, cur.ch), maxCh);
+ return Pos(line, ch);
+ }
+ function copyArgs(args) {
+ var ret = {};
+ for (var prop in args) {
+ if (args.hasOwnProperty(prop)) {
+ ret[prop] = args[prop];
+ }
+ }
+ return ret;
+ }
+ function offsetCursor(cur, offsetLine, offsetCh) {
+ if (typeof offsetLine === 'object') {
+ offsetCh = offsetLine.ch;
+ offsetLine = offsetLine.line;
+ }
+ return Pos(cur.line + offsetLine, cur.ch + offsetCh);
+ }
+ function getOffset(anchor, head) {
+ return {
+ line: head.line - anchor.line,
+ ch: head.line - anchor.line
+ };
+ }
+ function commandMatches(keys, keyMap, context, inputState) {
+ var match, partial = [], full = [];
+ for (var i = 0; i < keyMap.length; i++) {
+ var command = keyMap[i];
+ if (context == 'insert' && command.context != 'insert' ||
+ command.context && command.context != context ||
+ inputState.operator && command.type == 'action' ||
+ !(match = commandMatch(keys, command.keys))) { continue; }
+ if (match == 'partial') { partial.push(command); }
+ if (match == 'full') { full.push(command); }
+ }
+ return {
+ partial: partial.length && partial,
+ full: full.length && full
+ };
+ }
+ function commandMatch(pressed, mapped) {
+ if (mapped.slice(-11) == '<character>') {
+ var prefixLen = mapped.length - 11;
+ var pressedPrefix = pressed.slice(0, prefixLen);
+ var mappedPrefix = mapped.slice(0, prefixLen);
+ return pressedPrefix == mappedPrefix && pressed.length > prefixLen ? 'full' :
+ mappedPrefix.indexOf(pressedPrefix) == 0 ? 'partial' : false;
+ } else {
+ return pressed == mapped ? 'full' :
+ mapped.indexOf(pressed) == 0 ? 'partial' : false;
+ }
+ }
+ function lastChar(keys) {
+ var match = /^.*(<[\w\-]+>)$/.exec(keys);
+ var selectedCharacter = match ? match[1] : keys.slice(-1);
+ if (selectedCharacter.length > 1){
+ switch(selectedCharacter){
+ case '<CR>':
+ selectedCharacter='\n';
+ break;
+ case '<Space>':
+ selectedCharacter=' ';
+ break;
+ default:
+ break;
+ }
+ }
+ return selectedCharacter;
+ }
+ function repeatFn(cm, fn, repeat) {
+ return function() {
+ for (var i = 0; i < repeat; i++) {
+ fn(cm);
+ }
+ };
+ }
+ function copyCursor(cur) {
+ return Pos(cur.line, cur.ch);
+ }
+ function cursorEqual(cur1, cur2) {
+ return cur1.ch == cur2.ch && cur1.line == cur2.line;
+ }
+ function cursorIsBefore(cur1, cur2) {
+ if (cur1.line < cur2.line) {
+ return true;
+ }
+ if (cur1.line == cur2.line && cur1.ch < cur2.ch) {
+ return true;
+ }
+ return false;
+ }
+ function cursorMin(cur1, cur2) {
+ if (arguments.length > 2) {
+ cur2 = cursorMin.apply(undefined, Array.prototype.slice.call(arguments, 1));
+ }
+ return cursorIsBefore(cur1, cur2) ? cur1 : cur2;
+ }
+ function cursorMax(cur1, cur2) {
+ if (arguments.length > 2) {
+ cur2 = cursorMax.apply(undefined, Array.prototype.slice.call(arguments, 1));
+ }
+ return cursorIsBefore(cur1, cur2) ? cur2 : cur1;
+ }
+ function cursorIsBetween(cur1, cur2, cur3) {
+ var cur1before2 = cursorIsBefore(cur1, cur2);
+ var cur2before3 = cursorIsBefore(cur2, cur3);
+ return cur1before2 && cur2before3;
+ }
+ function lineLength(cm, lineNum) {
+ return cm.getLine(lineNum).length;
+ }
+ function trim(s) {
+ if (s.trim) {
+ return s.trim();
+ }
+ return s.replace(/^\s+|\s+$/g, '');
+ }
+ function escapeRegex(s) {
+ return s.replace(/([.?*+$\[\]\/\\(){}|\-])/g, '\\$1');
+ }
+ function extendLineToColumn(cm, lineNum, column) {
+ var endCh = lineLength(cm, lineNum);
+ var spaces = new Array(column-endCh+1).join(' ');
+ cm.setCursor(Pos(lineNum, endCh));
+ cm.replaceRange(spaces, cm.getCursor());
+ }
+ function selectBlock(cm, selectionEnd) {
+ var selections = [], ranges = cm.listSelections();
+ var head = copyCursor(cm.clipPos(selectionEnd));
+ var isClipped = !cursorEqual(selectionEnd, head);
+ var curHead = cm.getCursor('head');
+ var primIndex = getIndex(ranges, curHead);
+ var wasClipped = cursorEqual(ranges[primIndex].head, ranges[primIndex].anchor);
+ var max = ranges.length - 1;
+ var index = max - primIndex > primIndex ? max : 0;
+ var base = ranges[index].anchor;
+
+ var firstLine = Math.min(base.line, head.line);
+ var lastLine = Math.max(base.line, head.line);
+ var baseCh = base.ch, headCh = head.ch;
+
+ var dir = ranges[index].head.ch - baseCh;
+ var newDir = headCh - baseCh;
+ if (dir > 0 && newDir <= 0) {
+ baseCh++;
+ if (!isClipped) { headCh--; }
+ } else if (dir < 0 && newDir >= 0) {
+ baseCh--;
+ if (!wasClipped) { headCh++; }
+ } else if (dir < 0 && newDir == -1) {
+ baseCh--;
+ headCh++;
+ }
+ for (var line = firstLine; line <= lastLine; line++) {
+ var range = {anchor: new Pos(line, baseCh), head: new Pos(line, headCh)};
+ selections.push(range);
+ }
+ primIndex = head.line == lastLine ? selections.length - 1 : 0;
+ cm.setSelections(selections);
+ selectionEnd.ch = headCh;
+ base.ch = baseCh;
+ return base;
+ }
+ function selectForInsert(cm, head, height) {
+ var sel = [];
+ for (var i = 0; i < height; i++) {
+ var lineHead = offsetCursor(head, i, 0);
+ sel.push({anchor: lineHead, head: lineHead});
+ }
+ cm.setSelections(sel, 0);
+ }
+ function getIndex(ranges, cursor, end) {
+ for (var i = 0; i < ranges.length; i++) {
+ var atAnchor = end != 'head' && cursorEqual(ranges[i].anchor, cursor);
+ var atHead = end != 'anchor' && cursorEqual(ranges[i].head, cursor);
+ if (atAnchor || atHead) {
+ return i;
+ }
+ }
+ return -1;
+ }
+ function getSelectedAreaRange(cm, vim) {
+ var lastSelection = vim.lastSelection;
+ var getCurrentSelectedAreaRange = function() {
+ var selections = cm.listSelections();
+ var start = selections[0];
+ var end = selections[selections.length-1];
+ var selectionStart = cursorIsBefore(start.anchor, start.head) ? start.anchor : start.head;
+ var selectionEnd = cursorIsBefore(end.anchor, end.head) ? end.head : end.anchor;
+ return [selectionStart, selectionEnd];
+ };
+ var getLastSelectedAreaRange = function() {
+ var selectionStart = cm.getCursor();
+ var selectionEnd = cm.getCursor();
+ var block = lastSelection.visualBlock;
+ if (block) {
+ var width = block.width;
+ var height = block.height;
+ selectionEnd = Pos(selectionStart.line + height, selectionStart.ch + width);
+ var selections = [];
+ for (var i = selectionStart.line; i < selectionEnd.line; i++) {
+ var anchor = Pos(i, selectionStart.ch);
+ var head = Pos(i, selectionEnd.ch);
+ var range = {anchor: anchor, head: head};
+ selections.push(range);
+ }
+ cm.setSelections(selections);
+ } else {
+ var start = lastSelection.anchorMark.find();
+ var end = lastSelection.headMark.find();
+ var line = end.line - start.line;
+ var ch = end.ch - start.ch;
+ selectionEnd = {line: selectionEnd.line + line, ch: line ? selectionEnd.ch : ch + selectionEnd.ch};
+ if (lastSelection.visualLine) {
+ selectionStart = Pos(selectionStart.line, 0);
+ selectionEnd = Pos(selectionEnd.line, lineLength(cm, selectionEnd.line));
+ }
+ cm.setSelection(selectionStart, selectionEnd);
+ }
+ return [selectionStart, selectionEnd];
+ };
+ if (!vim.visualMode) {
+ return getLastSelectedAreaRange();
+ } else {
+ return getCurrentSelectedAreaRange();
+ }
+ }
+ function updateLastSelection(cm, vim) {
+ var anchor = vim.sel.anchor;
+ var head = vim.sel.head;
+ if (vim.lastPastedText) {
+ head = cm.posFromIndex(cm.indexFromPos(anchor) + vim.lastPastedText.length);
+ vim.lastPastedText = null;
+ }
+ vim.lastSelection = {'anchorMark': cm.setBookmark(anchor),
+ 'headMark': cm.setBookmark(head),
+ 'anchor': copyCursor(anchor),
+ 'head': copyCursor(head),
+ 'visualMode': vim.visualMode,
+ 'visualLine': vim.visualLine,
+ 'visualBlock': vim.visualBlock};
+ }
+ function expandSelection(cm, start, end) {
+ var sel = cm.state.vim.sel;
+ var head = sel.head;
+ var anchor = sel.anchor;
+ var tmp;
+ if (cursorIsBefore(end, start)) {
+ tmp = end;
+ end = start;
+ start = tmp;
+ }
+ if (cursorIsBefore(head, anchor)) {
+ head = cursorMin(start, head);
+ anchor = cursorMax(anchor, end);
+ } else {
+ anchor = cursorMin(start, anchor);
+ head = cursorMax(head, end);
+ head = offsetCursor(head, 0, -1);
+ if (head.ch == -1 && head.line != cm.firstLine()) {
+ head = Pos(head.line - 1, lineLength(cm, head.line - 1));
+ }
+ }
+ return [anchor, head];
+ }
+ function updateCmSelection(cm, sel, mode) {
+ var vim = cm.state.vim;
+ sel = sel || vim.sel;
+ var mode = mode ||
+ vim.visualLine ? 'line' : vim.visualBlock ? 'block' : 'char';
+ var cmSel = makeCmSelection(cm, sel, mode);
+ cm.setSelections(cmSel.ranges, cmSel.primary);
+ updateFakeCursor(cm);
+ }
+ function makeCmSelection(cm, sel, mode, exclusive) {
+ var head = copyCursor(sel.head);
+ var anchor = copyCursor(sel.anchor);
+ if (mode == 'char') {
+ var headOffset = !exclusive && !cursorIsBefore(sel.head, sel.anchor) ? 1 : 0;
+ var anchorOffset = cursorIsBefore(sel.head, sel.anchor) ? 1 : 0;
+ head = offsetCursor(sel.head, 0, headOffset);
+ anchor = offsetCursor(sel.anchor, 0, anchorOffset);
+ return {
+ ranges: [{anchor: anchor, head: head}],
+ primary: 0
+ };
+ } else if (mode == 'line') {
+ if (!cursorIsBefore(sel.head, sel.anchor)) {
+ anchor.ch = 0;
+
+ var lastLine = cm.lastLine();
+ if (head.line > lastLine) {
+ head.line = lastLine;
+ }
+ head.ch = lineLength(cm, head.line);
+ } else {
+ head.ch = 0;
+ anchor.ch = lineLength(cm, anchor.line);
+ }
+ return {
+ ranges: [{anchor: anchor, head: head}],
+ primary: 0
+ };
+ } else if (mode == 'block') {
+ var top = Math.min(anchor.line, head.line),
+ left = Math.min(anchor.ch, head.ch),
+ bottom = Math.max(anchor.line, head.line),
+ right = Math.max(anchor.ch, head.ch) + 1;
+ var height = bottom - top + 1;
+ var primary = head.line == top ? 0 : height - 1;
+ var ranges = [];
+ for (var i = 0; i < height; i++) {
+ ranges.push({
+ anchor: Pos(top + i, left),
+ head: Pos(top + i, right)
+ });
+ }
+ return {
+ ranges: ranges,
+ primary: primary
+ };
+ }
+ }
+ function getHead(cm) {
+ var cur = cm.getCursor('head');
+ if (cm.getSelection().length == 1) {
+ cur = cursorMin(cur, cm.getCursor('anchor'));
+ }
+ return cur;
+ }
+ function exitVisualMode(cm, moveHead) {
+ var vim = cm.state.vim;
+ if (moveHead !== false) {
+ cm.setCursor(clipCursorToContent(cm, vim.sel.head));
+ }
+ updateLastSelection(cm, vim);
+ vim.visualMode = false;
+ vim.visualLine = false;
+ vim.visualBlock = false;
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "normal"});
+ if (vim.fakeCursor) {
+ vim.fakeCursor.clear();
+ }
+ }
+ function clipToLine(cm, curStart, curEnd) {
+ var selection = cm.getRange(curStart, curEnd);
+ if (/\n\s*$/.test(selection)) {
+ var lines = selection.split('\n');
+ lines.pop();
+ var line;
+ for (var line = lines.pop(); lines.length > 0 && line && isWhiteSpaceString(line); line = lines.pop()) {
+ curEnd.line--;
+ curEnd.ch = 0;
+ }
+ if (line) {
+ curEnd.line--;
+ curEnd.ch = lineLength(cm, curEnd.line);
+ } else {
+ curEnd.ch = 0;
+ }
+ }
+ }
+ function expandSelectionToLine(_cm, curStart, curEnd) {
+ curStart.ch = 0;
+ curEnd.ch = 0;
+ curEnd.line++;
+ }
+
+ function findFirstNonWhiteSpaceCharacter(text) {
+ if (!text) {
+ return 0;
+ }
+ var firstNonWS = text.search(/\S/);
+ return firstNonWS == -1 ? text.length : firstNonWS;
+ }
+
+ function expandWordUnderCursor(cm, inclusive, _forward, bigWord, noSymbol) {
+ var cur = getHead(cm);
+ var line = cm.getLine(cur.line);
+ var idx = cur.ch;
+ var test = noSymbol ? wordCharTest[0] : bigWordCharTest [0];
+ while (!test(line.charAt(idx))) {
+ idx++;
+ if (idx >= line.length) { return null; }
+ }
+
+ if (bigWord) {
+ test = bigWordCharTest[0];
+ } else {
+ test = wordCharTest[0];
+ if (!test(line.charAt(idx))) {
+ test = wordCharTest[1];
+ }
+ }
+
+ var end = idx, start = idx;
+ while (test(line.charAt(end)) && end < line.length) { end++; }
+ while (test(line.charAt(start)) && start >= 0) { start--; }
+ start++;
+
+ if (inclusive) {
+ var wordEnd = end;
+ while (/\s/.test(line.charAt(end)) && end < line.length) { end++; }
+ if (wordEnd == end) {
+ var wordStart = start;
+ while (/\s/.test(line.charAt(start - 1)) && start > 0) { start--; }
+ if (!start) { start = wordStart; }
+ }
+ }
+ return { start: Pos(cur.line, start), end: Pos(cur.line, end) };
+ }
+
+ function recordJumpPosition(cm, oldCur, newCur) {
+ if (!cursorEqual(oldCur, newCur)) {
+ vimGlobalState.jumpList.add(cm, oldCur, newCur);
+ }
+ }
+
+ function recordLastCharacterSearch(increment, args) {
+ vimGlobalState.lastChararacterSearch.increment = increment;
+ vimGlobalState.lastChararacterSearch.forward = args.forward;
+ vimGlobalState.lastChararacterSearch.selectedCharacter = args.selectedCharacter;
+ }
+
+ var symbolToMode = {
+ '(': 'bracket', ')': 'bracket', '{': 'bracket', '}': 'bracket',
+ '[': 'section', ']': 'section',
+ '*': 'comment', '/': 'comment',
+ 'm': 'method', 'M': 'method',
+ '#': 'preprocess'
+ };
+ var findSymbolModes = {
+ bracket: {
+ isComplete: function(state) {
+ if (state.nextCh === state.symb) {
+ state.depth++;
+ if (state.depth >= 1)return true;
+ } else if (state.nextCh === state.reverseSymb) {
+ state.depth--;
+ }
+ return false;
+ }
+ },
+ section: {
+ init: function(state) {
+ state.curMoveThrough = true;
+ state.symb = (state.forward ? ']' : '[') === state.symb ? '{' : '}';
+ },
+ isComplete: function(state) {
+ return state.index === 0 && state.nextCh === state.symb;
+ }
+ },
+ comment: {
+ isComplete: function(state) {
+ var found = state.lastCh === '*' && state.nextCh === '/';
+ state.lastCh = state.nextCh;
+ return found;
+ }
+ },
+ method: {
+ init: function(state) {
+ state.symb = (state.symb === 'm' ? '{' : '}');
+ state.reverseSymb = state.symb === '{' ? '}' : '{';
+ },
+ isComplete: function(state) {
+ if (state.nextCh === state.symb)return true;
+ return false;
+ }
+ },
+ preprocess: {
+ init: function(state) {
+ state.index = 0;
+ },
+ isComplete: function(state) {
+ if (state.nextCh === '#') {
+ var token = state.lineText.match(/#(\w+)/)[1];
+ if (token === 'endif') {
+ if (state.forward && state.depth === 0) {
+ return true;
+ }
+ state.depth++;
+ } else if (token === 'if') {
+ if (!state.forward && state.depth === 0) {
+ return true;
+ }
+ state.depth--;
+ }
+ if (token === 'else' && state.depth === 0)return true;
+ }
+ return false;
+ }
+ }
+ };
+ function findSymbol(cm, repeat, forward, symb) {
+ var cur = copyCursor(cm.getCursor());
+ var increment = forward ? 1 : -1;
+ var endLine = forward ? cm.lineCount() : -1;
+ var curCh = cur.ch;
+ var line = cur.line;
+ var lineText = cm.getLine(line);
+ var state = {
+ lineText: lineText,
+ nextCh: lineText.charAt(curCh),
+ lastCh: null,
+ index: curCh,
+ symb: symb,
+ reverseSymb: (forward ? { ')': '(', '}': '{' } : { '(': ')', '{': '}' })[symb],
+ forward: forward,
+ depth: 0,
+ curMoveThrough: false
+ };
+ var mode = symbolToMode[symb];
+ if (!mode)return cur;
+ var init = findSymbolModes[mode].init;
+ var isComplete = findSymbolModes[mode].isComplete;
+ if (init) { init(state); }
+ while (line !== endLine && repeat) {
+ state.index += increment;
+ state.nextCh = state.lineText.charAt(state.index);
+ if (!state.nextCh) {
+ line += increment;
+ state.lineText = cm.getLine(line) || '';
+ if (increment > 0) {
+ state.index = 0;
+ } else {
+ var lineLen = state.lineText.length;
+ state.index = (lineLen > 0) ? (lineLen-1) : 0;
+ }
+ state.nextCh = state.lineText.charAt(state.index);
+ }
+ if (isComplete(state)) {
+ cur.line = line;
+ cur.ch = state.index;
+ repeat--;
+ }
+ }
+ if (state.nextCh || state.curMoveThrough) {
+ return Pos(line, state.index);
+ }
+ return cur;
+ }
+ function findWord(cm, cur, forward, bigWord, emptyLineIsWord) {
+ var lineNum = cur.line;
+ var pos = cur.ch;
+ var line = cm.getLine(lineNum);
+ var dir = forward ? 1 : -1;
+ var charTests = bigWord ? bigWordCharTest: wordCharTest;
+
+ if (emptyLineIsWord && line == '') {
+ lineNum += dir;
+ line = cm.getLine(lineNum);
+ if (!isLine(cm, lineNum)) {
+ return null;
+ }
+ pos = (forward) ? 0 : line.length;
+ }
+
+ while (true) {
+ if (emptyLineIsWord && line == '') {
+ return { from: 0, to: 0, line: lineNum };
+ }
+ var stop = (dir > 0) ? line.length : -1;
+ var wordStart = stop, wordEnd = stop;
+ while (pos != stop) {
+ var foundWord = false;
+ for (var i = 0; i < charTests.length && !foundWord; ++i) {
+ if (charTests[i](line.charAt(pos))) {
+ wordStart = pos;
+ while (pos != stop && charTests[i](line.charAt(pos))) {
+ pos += dir;
+ }
+ wordEnd = pos;
+ foundWord = wordStart != wordEnd;
+ if (wordStart == cur.ch && lineNum == cur.line &&
+ wordEnd == wordStart + dir) {
+ continue;
+ } else {
+ return {
+ from: Math.min(wordStart, wordEnd + 1),
+ to: Math.max(wordStart, wordEnd),
+ line: lineNum };
+ }
+ }
+ }
+ if (!foundWord) {
+ pos += dir;
+ }
+ }
+ lineNum += dir;
+ if (!isLine(cm, lineNum)) {
+ return null;
+ }
+ line = cm.getLine(lineNum);
+ pos = (dir > 0) ? 0 : line.length;
+ }
+ throw new Error('The impossible happened.');
+ }
+ function moveToWord(cm, cur, repeat, forward, wordEnd, bigWord) {
+ var curStart = copyCursor(cur);
+ var words = [];
+ if (forward && !wordEnd || !forward && wordEnd) {
+ repeat++;
+ }
+ var emptyLineIsWord = !(forward && wordEnd);
+ for (var i = 0; i < repeat; i++) {
+ var word = findWord(cm, cur, forward, bigWord, emptyLineIsWord);
+ if (!word) {
+ var eodCh = lineLength(cm, cm.lastLine());
+ words.push(forward
+ ? {line: cm.lastLine(), from: eodCh, to: eodCh}
+ : {line: 0, from: 0, to: 0});
+ break;
+ }
+ words.push(word);
+ cur = Pos(word.line, forward ? (word.to - 1) : word.from);
+ }
+ var shortCircuit = words.length != repeat;
+ var firstWord = words[0];
+ var lastWord = words.pop();
+ if (forward && !wordEnd) {
+ if (!shortCircuit && (firstWord.from != curStart.ch || firstWord.line != curStart.line)) {
+ lastWord = words.pop();
+ }
+ return Pos(lastWord.line, lastWord.from);
+ } else if (forward && wordEnd) {
+ return Pos(lastWord.line, lastWord.to - 1);
+ } else if (!forward && wordEnd) {
+ if (!shortCircuit && (firstWord.to != curStart.ch || firstWord.line != curStart.line)) {
+ lastWord = words.pop();
+ }
+ return Pos(lastWord.line, lastWord.to);
+ } else {
+ return Pos(lastWord.line, lastWord.from);
+ }
+ }
+
+ function moveToCharacter(cm, repeat, forward, character) {
+ var cur = cm.getCursor();
+ var start = cur.ch;
+ var idx;
+ for (var i = 0; i < repeat; i ++) {
+ var line = cm.getLine(cur.line);
+ idx = charIdxInLine(start, line, character, forward, true);
+ if (idx == -1) {
+ return null;
+ }
+ start = idx;
+ }
+ return Pos(cm.getCursor().line, idx);
+ }
+
+ function moveToColumn(cm, repeat) {
+ var line = cm.getCursor().line;
+ return clipCursorToContent(cm, Pos(line, repeat - 1));
+ }
+
+ function updateMark(cm, vim, markName, pos) {
+ if (!inArray(markName, validMarks)) {
+ return;
+ }
+ if (vim.marks[markName]) {
+ vim.marks[markName].clear();
+ }
+ vim.marks[markName] = cm.setBookmark(pos);
+ }
+
+ function charIdxInLine(start, line, character, forward, includeChar) {
+ var idx;
+ if (forward) {
+ idx = line.indexOf(character, start + 1);
+ if (idx != -1 && !includeChar) {
+ idx -= 1;
+ }
+ } else {
+ idx = line.lastIndexOf(character, start - 1);
+ if (idx != -1 && !includeChar) {
+ idx += 1;
+ }
+ }
+ return idx;
+ }
+
+ function findParagraph(cm, head, repeat, dir, inclusive) {
+ var line = head.line;
+ var min = cm.firstLine();
+ var max = cm.lastLine();
+ var start, end, i = line;
+ function isEmpty(i) { return !/\S/.test(cm.getLine(i)); } // ace_patch
+ function isBoundary(i, dir, any) {
+ if (any) { return isEmpty(i) != isEmpty(i + dir); }
+ return !isEmpty(i) && isEmpty(i + dir);
+ }
+ function skipFold(i) {
+ dir = dir > 0 ? 1 : -1;
+ var foldLine = cm.ace.session.getFoldLine(i);
+ if (foldLine) {
+ if (i + dir > foldLine.start.row && i + dir < foldLine.end.row)
+ dir = (dir > 0 ? foldLine.end.row : foldLine.start.row) - i;
+ }
+ }
+ if (dir) {
+ while (min <= i && i <= max && repeat > 0) {
+ skipFold(i);
+ if (isBoundary(i, dir)) { repeat--; }
+ i += dir;
+ }
+ return new Pos(i, 0);
+ }
+
+ var vim = cm.state.vim;
+ if (vim.visualLine && isBoundary(line, 1, true)) {
+ var anchor = vim.sel.anchor;
+ if (isBoundary(anchor.line, -1, true)) {
+ if (!inclusive || anchor.line != line) {
+ line += 1;
+ }
+ }
+ }
+ var startState = isEmpty(line);
+ for (i = line; i <= max && repeat; i++) {
+ if (isBoundary(i, 1, true)) {
+ if (!inclusive || isEmpty(i) != startState) {
+ repeat--;
+ }
+ }
+ }
+ end = new Pos(i, 0);
+ if (i > max && !startState) { startState = true; }
+ else { inclusive = false; }
+ for (i = line; i > min; i--) {
+ if (!inclusive || isEmpty(i) == startState || i == line) {
+ if (isBoundary(i, -1, true)) { break; }
+ }
+ }
+ start = new Pos(i, 0);
+ return { start: start, end: end };
+ }
+ function selectCompanionObject(cm, head, symb, inclusive) {
+ var cur = head, start, end;
+
+ var bracketRegexp = ({
+ '(': /[()]/, ')': /[()]/,
+ '[': /[[\]]/, ']': /[[\]]/,
+ '{': /[{}]/, '}': /[{}]/})[symb];
+ var openSym = ({
+ '(': '(', ')': '(',
+ '[': '[', ']': '[',
+ '{': '{', '}': '{'})[symb];
+ var curChar = cm.getLine(cur.line).charAt(cur.ch);
+ var offset = curChar === openSym ? 1 : 0;
+
+ start = cm.scanForBracket(Pos(cur.line, cur.ch + offset), -1, null, {'bracketRegex': bracketRegexp});
+ end = cm.scanForBracket(Pos(cur.line, cur.ch + offset), 1, null, {'bracketRegex': bracketRegexp});
+
+ if (!start || !end) {
+ return { start: cur, end: cur };
+ }
+
+ start = start.pos;
+ end = end.pos;
+
+ if ((start.line == end.line && start.ch > end.ch)
+ || (start.line > end.line)) {
+ var tmp = start;
+ start = end;
+ end = tmp;
+ }
+
+ if (inclusive) {
+ end.ch += 1;
+ } else {
+ start.ch += 1;
+ }
+
+ return { start: start, end: end };
+ }
+ function findBeginningAndEnd(cm, head, symb, inclusive) {
+ var cur = copyCursor(head);
+ var line = cm.getLine(cur.line);
+ var chars = line.split('');
+ var start, end, i, len;
+ var firstIndex = chars.indexOf(symb);
+ if (cur.ch < firstIndex) {
+ cur.ch = firstIndex;
+ }
+ else if (firstIndex < cur.ch && chars[cur.ch] == symb) {
+ end = cur.ch; // assign end to the current cursor
+ --cur.ch; // make sure to look backwards
+ }
+ if (chars[cur.ch] == symb && !end) {
+ start = cur.ch + 1; // assign start to ahead of the cursor
+ } else {
+ for (i = cur.ch; i > -1 && !start; i--) {
+ if (chars[i] == symb) {
+ start = i + 1;
+ }
+ }
+ }
+ if (start && !end) {
+ for (i = start, len = chars.length; i < len && !end; i++) {
+ if (chars[i] == symb) {
+ end = i;
+ }
+ }
+ }
+ if (!start || !end) {
+ return { start: cur, end: cur };
+ }
+ if (inclusive) {
+ --start; ++end;
+ }
+
+ return {
+ start: Pos(cur.line, start),
+ end: Pos(cur.line, end)
+ };
+ }
+ defineOption('pcre', true, 'boolean');
+ function SearchState() {}
+ SearchState.prototype = {
+ getQuery: function() {
+ return vimGlobalState.query;
+ },
+ setQuery: function(query) {
+ vimGlobalState.query = query;
+ },
+ getOverlay: function() {
+ return this.searchOverlay;
+ },
+ setOverlay: function(overlay) {
+ this.searchOverlay = overlay;
+ },
+ isReversed: function() {
+ return vimGlobalState.isReversed;
+ },
+ setReversed: function(reversed) {
+ vimGlobalState.isReversed = reversed;
+ },
+ getScrollbarAnnotate: function() {
+ return this.annotate;
+ },
+ setScrollbarAnnotate: function(annotate) {
+ this.annotate = annotate;
+ }
+ };
+ function getSearchState(cm) {
+ var vim = cm.state.vim;
+ return vim.searchState_ || (vim.searchState_ = new SearchState());
+ }
+ function dialog(cm, template, shortText, onClose, options) {
+ if (cm.openDialog) {
+ cm.openDialog(template, onClose, { bottom: true, value: options.value,
+ onKeyDown: options.onKeyDown, onKeyUp: options.onKeyUp,
+ selectValueOnOpen: false});
+ }
+ else {
+ onClose(prompt(shortText, ''));
+ }
+ }
+ function splitBySlash(argString) {
+ var slashes = findUnescapedSlashes(argString) || [];
+ if (!slashes.length) return [];
+ var tokens = [];
+ if (slashes[0] !== 0) return;
+ for (var i = 0; i < slashes.length; i++) {
+ if (typeof slashes[i] == 'number')
+ tokens.push(argString.substring(slashes[i] + 1, slashes[i+1]));
+ }
+ return tokens;
+ }
+
+ function findUnescapedSlashes(str) {
+ var escapeNextChar = false;
+ var slashes = [];
+ for (var i = 0; i < str.length; i++) {
+ var c = str.charAt(i);
+ if (!escapeNextChar && c == '/') {
+ slashes.push(i);
+ }
+ escapeNextChar = !escapeNextChar && (c == '\\');
+ }
+ return slashes;
+ }
+ function translateRegex(str) {
+ var specials = '|(){';
+ var unescape = '}';
+ var escapeNextChar = false;
+ var out = [];
+ for (var i = -1; i < str.length; i++) {
+ var c = str.charAt(i) || '';
+ var n = str.charAt(i+1) || '';
+ var specialComesNext = (n && specials.indexOf(n) != -1);
+ if (escapeNextChar) {
+ if (c !== '\\' || !specialComesNext) {
+ out.push(c);
+ }
+ escapeNextChar = false;
+ } else {
+ if (c === '\\') {
+ escapeNextChar = true;
+ if (n && unescape.indexOf(n) != -1) {
+ specialComesNext = true;
+ }
+ if (!specialComesNext || n === '\\') {
+ out.push(c);
+ }
+ } else {
+ out.push(c);
+ if (specialComesNext && n !== '\\') {
+ out.push('\\');
+ }
+ }
+ }
+ }
+ return out.join('');
+ }
+ var charUnescapes = {'\\n': '\n', '\\r': '\r', '\\t': '\t'};
+ function translateRegexReplace(str) {
+ var escapeNextChar = false;
+ var out = [];
+ for (var i = -1; i < str.length; i++) {
+ var c = str.charAt(i) || '';
+ var n = str.charAt(i+1) || '';
+ if (charUnescapes[c + n]) {
+ out.push(charUnescapes[c+n]);
+ i++;
+ } else if (escapeNextChar) {
+ out.push(c);
+ escapeNextChar = false;
+ } else {
+ if (c === '\\') {
+ escapeNextChar = true;
+ if ((isNumber(n) || n === '$')) {
+ out.push('$');
+ } else if (n !== '/' && n !== '\\') {
+ out.push('\\');
+ }
+ } else {
+ if (c === '$') {
+ out.push('$');
+ }
+ out.push(c);
+ if (n === '/') {
+ out.push('\\');
+ }
+ }
+ }
+ }
+ return out.join('');
+ }
+ var unescapes = {'\\/': '/', '\\\\': '\\', '\\n': '\n', '\\r': '\r', '\\t': '\t'};
+ function unescapeRegexReplace(str) {
+ var stream = new CodeMirror.StringStream(str);
+ var output = [];
+ while (!stream.eol()) {
+ while (stream.peek() && stream.peek() != '\\') {
+ output.push(stream.next());
+ }
+ var matched = false;
+ for (var matcher in unescapes) {
+ if (stream.match(matcher, true)) {
+ matched = true;
+ output.push(unescapes[matcher]);
+ break;
+ }
+ }
+ if (!matched) {
+ output.push(stream.next());
+ }
+ }
+ return output.join('');
+ }
+ function parseQuery(query, ignoreCase, smartCase) {
+ var lastSearchRegister = vimGlobalState.registerController.getRegister('/');
+ lastSearchRegister.setText(query);
+ if (query instanceof RegExp) { return query; }
+ var slashes = findUnescapedSlashes(query);
+ var regexPart;
+ var forceIgnoreCase;
+ if (!slashes.length) {
+ regexPart = query;
+ } else {
+ regexPart = query.substring(0, slashes[0]);
+ var flagsPart = query.substring(slashes[0]);
+ forceIgnoreCase = (flagsPart.indexOf('i') != -1);
+ }
+ if (!regexPart) {
+ return null;
+ }
+ if (!getOption('pcre')) {
+ regexPart = translateRegex(regexPart);
+ }
+ if (smartCase) {
+ ignoreCase = (/^[^A-Z]*$/).test(regexPart);
+ }
+ var regexp = new RegExp(regexPart,
+ (ignoreCase || forceIgnoreCase) ? 'i' : undefined);
+ return regexp;
+ }
+ function showConfirm(cm, text) {
+ if (cm.openNotification) {
+ cm.openNotification('<span style="color: red">' + text + '</span>',
+ {bottom: true, duration: 5000});
+ } else {
+ alert(text);
+ }
+ }
+ function makePrompt(prefix, desc) {
+ var raw = '';
+ if (prefix) {
+ raw += '<span style="font-family: monospace">' + prefix + '</span>';
+ }
+ raw += '<input type="text"/> ' +
+ '<span style="color: #888">';
+ if (desc) {
+ raw += '<span style="color: #888">';
+ raw += desc;
+ raw += '</span>';
+ }
+ return raw;
+ }
+ var searchPromptDesc = '(Javascript regexp)';
+ function showPrompt(cm, options) {
+ var shortText = (options.prefix || '') + ' ' + (options.desc || '');
+ var prompt = makePrompt(options.prefix, options.desc);
+ dialog(cm, prompt, shortText, options.onClose, options);
+ }
+ function regexEqual(r1, r2) {
+ if (r1 instanceof RegExp && r2 instanceof RegExp) {
+ var props = ['global', 'multiline', 'ignoreCase', 'source'];
+ for (var i = 0; i < props.length; i++) {
+ var prop = props[i];
+ if (r1[prop] !== r2[prop]) {
+ return false;
+ }
+ }
+ return true;
+ }
+ return false;
+ }
+ function updateSearchQuery(cm, rawQuery, ignoreCase, smartCase) {
+ if (!rawQuery) {
+ return;
+ }
+ var state = getSearchState(cm);
+ var query = parseQuery(rawQuery, !!ignoreCase, !!smartCase);
+ if (!query) {
+ return;
+ }
+ highlightSearchMatches(cm, query);
+ if (regexEqual(query, state.getQuery())) {
+ return query;
+ }
+ state.setQuery(query);
+ return query;
+ }
+ function searchOverlay(query) {
+ if (query.source.charAt(0) == '^') {
+ var matchSol = true;
+ }
+ return {
+ token: function(stream) {
+ if (matchSol && !stream.sol()) {
+ stream.skipToEnd();
+ return;
+ }
+ var match = stream.match(query, false);
+ if (match) {
+ if (match[0].length == 0) {
+ stream.next();
+ return 'searching';
+ }
+ if (!stream.sol()) {
+ stream.backUp(1);
+ if (!query.exec(stream.next() + match[0])) {
+ stream.next();
+ return null;
+ }
+ }
+ stream.match(query);
+ return 'searching';
+ }
+ while (!stream.eol()) {
+ stream.next();
+ if (stream.match(query, false)) break;
+ }
+ },
+ query: query
+ };
+ }
+ function highlightSearchMatches(cm, query) {
+ var searchState = getSearchState(cm);
+ var overlay = searchState.getOverlay();
+ if (!overlay || query != overlay.query) {
+ if (overlay) {
+ cm.removeOverlay(overlay);
+ }
+ overlay = searchOverlay(query);
+ cm.addOverlay(overlay);
+ if (cm.showMatchesOnScrollbar) {
+ if (searchState.getScrollbarAnnotate()) {
+ searchState.getScrollbarAnnotate().clear();
+ }
+ searchState.setScrollbarAnnotate(cm.showMatchesOnScrollbar(query));
+ }
+ searchState.setOverlay(overlay);
+ }
+ }
+ function findNext(cm, prev, query, repeat) {
+ if (repeat === undefined) { repeat = 1; }
+ return cm.operation(function() {
+ var pos = cm.getCursor();
+ var cursor = cm.getSearchCursor(query, pos);
+ for (var i = 0; i < repeat; i++) {
+ var found = cursor.find(prev);
+ if (i == 0 && found && cursorEqual(cursor.from(), pos)) { found = cursor.find(prev); }
+ if (!found) {
+ cursor = cm.getSearchCursor(query,
+ (prev) ? Pos(cm.lastLine()) : Pos(cm.firstLine(), 0) );
+ if (!cursor.find(prev)) {
+ return;
+ }
+ }
+ }
+ return cursor.from();
+ });
+ }
+ function clearSearchHighlight(cm) {
+ var state = getSearchState(cm);
+ cm.removeOverlay(getSearchState(cm).getOverlay());
+ state.setOverlay(null);
+ if (state.getScrollbarAnnotate()) {
+ state.getScrollbarAnnotate().clear();
+ state.setScrollbarAnnotate(null);
+ }
+ }
+ function isInRange(pos, start, end) {
+ if (typeof pos != 'number') {
+ pos = pos.line;
+ }
+ if (start instanceof Array) {
+ return inArray(pos, start);
+ } else {
+ if (end) {
+ return (pos >= start && pos <= end);
+ } else {
+ return pos == start;
+ }
+ }
+ }
+ function getUserVisibleLines(cm) {
+ var renderer = cm.ace.renderer;
+ return {
+ top: renderer.getFirstFullyVisibleRow(),
+ bottom: renderer.getLastFullyVisibleRow()
+ }
+ }
+
+ var ExCommandDispatcher = function() {
+ this.buildCommandMap_();
+ };
+ ExCommandDispatcher.prototype = {
+ processCommand: function(cm, input, opt_params) {
+ var that = this;
+ cm.operation(function () {
+ cm.curOp.isVimOp = true;
+ that._processCommand(cm, input, opt_params);
+ });
+ },
+ _processCommand: function(cm, input, opt_params) {
+ var vim = cm.state.vim;
+ var commandHistoryRegister = vimGlobalState.registerController.getRegister(':');
+ var previousCommand = commandHistoryRegister.toString();
+ if (vim.visualMode) {
+ exitVisualMode(cm);
+ }
+ var inputStream = new CodeMirror.StringStream(input);
+ commandHistoryRegister.setText(input);
+ var params = opt_params || {};
+ params.input = input;
+ try {
+ this.parseInput_(cm, inputStream, params);
+ } catch(e) {
+ showConfirm(cm, e);
+ throw e;
+ }
+ var command;
+ var commandName;
+ if (!params.commandName) {
+ if (params.line !== undefined) {
+ commandName = 'move';
+ }
+ } else {
+ command = this.matchCommand_(params.commandName);
+ if (command) {
+ commandName = command.name;
+ if (command.excludeFromCommandHistory) {
+ commandHistoryRegister.setText(previousCommand);
+ }
+ this.parseCommandArgs_(inputStream, params, command);
+ if (command.type == 'exToKey') {
+ for (var i = 0; i < command.toKeys.length; i++) {
+ CodeMirror.Vim.handleKey(cm, command.toKeys[i], 'mapping');
+ }
+ return;
+ } else if (command.type == 'exToEx') {
+ this.processCommand(cm, command.toInput);
+ return;
+ }
+ }
+ }
+ if (!commandName) {
+ showConfirm(cm, 'Not an editor command ":' + input + '"');
+ return;
+ }
+ try {
+ exCommands[commandName](cm, params);
+ if ((!command || !command.possiblyAsync) && params.callback) {
+ params.callback();
+ }
+ } catch(e) {
+ showConfirm(cm, e);
+ throw e;
+ }
+ },
+ parseInput_: function(cm, inputStream, result) {
+ inputStream.eatWhile(':');
+ if (inputStream.eat('%')) {
+ result.line = cm.firstLine();
+ result.lineEnd = cm.lastLine();
+ } else {
+ result.line = this.parseLineSpec_(cm, inputStream);
+ if (result.line !== undefined && inputStream.eat(',')) {
+ result.lineEnd = this.parseLineSpec_(cm, inputStream);
+ }
+ }
+ var commandMatch = inputStream.match(/^(\w+)/);
+ if (commandMatch) {
+ result.commandName = commandMatch[1];
+ } else {
+ result.commandName = inputStream.match(/.*/)[0];
+ }
+
+ return result;
+ },
+ parseLineSpec_: function(cm, inputStream) {
+ var numberMatch = inputStream.match(/^(\d+)/);
+ if (numberMatch) {
+ return parseInt(numberMatch[1], 10) - 1;
+ }
+ switch (inputStream.next()) {
+ case '.':
+ return cm.getCursor().line;
+ case '$':
+ return cm.lastLine();
+ case '\'':
+ var mark = cm.state.vim.marks[inputStream.next()];
+ if (mark && mark.find()) {
+ return mark.find().line;
+ }
+ throw new Error('Mark not set');
+ default:
+ inputStream.backUp(1);
+ return undefined;
+ }
+ },
+ parseCommandArgs_: function(inputStream, params, command) {
+ if (inputStream.eol()) {
+ return;
+ }
+ params.argString = inputStream.match(/.*/)[0];
+ var delim = command.argDelimiter || /\s+/;
+ var args = trim(params.argString).split(delim);
+ if (args.length && args[0]) {
+ params.args = args;
+ }
+ },
+ matchCommand_: function(commandName) {
+ for (var i = commandName.length; i > 0; i--) {
+ var prefix = commandName.substring(0, i);
+ if (this.commandMap_[prefix]) {
+ var command = this.commandMap_[prefix];
+ if (command.name.indexOf(commandName) === 0) {
+ return command;
+ }
+ }
+ }
+ return null;
+ },
+ buildCommandMap_: function() {
+ this.commandMap_ = {};
+ for (var i = 0; i < defaultExCommandMap.length; i++) {
+ var command = defaultExCommandMap[i];
+ var key = command.shortName || command.name;
+ this.commandMap_[key] = command;
+ }
+ },
+ map: function(lhs, rhs, ctx) {
+ if (lhs != ':' && lhs.charAt(0) == ':') {
+ if (ctx) { throw Error('Mode not supported for ex mappings'); }
+ var commandName = lhs.substring(1);
+ if (rhs != ':' && rhs.charAt(0) == ':') {
+ this.commandMap_[commandName] = {
+ name: commandName,
+ type: 'exToEx',
+ toInput: rhs.substring(1),
+ user: true
+ };
+ } else {
+ this.commandMap_[commandName] = {
+ name: commandName,
+ type: 'exToKey',
+ toKeys: rhs,
+ user: true
+ };
+ }
+ } else {
+ if (rhs != ':' && rhs.charAt(0) == ':') {
+ var mapping = {
+ keys: lhs,
+ type: 'keyToEx',
+ exArgs: { input: rhs.substring(1) },
+ user: true};
+ if (ctx) { mapping.context = ctx; }
+ defaultKeymap.unshift(mapping);
+ } else {
+ var mapping = {
+ keys: lhs,
+ type: 'keyToKey',
+ toKeys: rhs,
+ user: true
+ };
+ if (ctx) { mapping.context = ctx; }
+ defaultKeymap.unshift(mapping);
+ }
+ }
+ },
+ unmap: function(lhs, ctx) {
+ if (lhs != ':' && lhs.charAt(0) == ':') {
+ if (ctx) { throw Error('Mode not supported for ex mappings'); }
+ var commandName = lhs.substring(1);
+ if (this.commandMap_[commandName] && this.commandMap_[commandName].user) {
+ delete this.commandMap_[commandName];
+ return;
+ }
+ } else {
+ var keys = lhs;
+ for (var i = 0; i < defaultKeymap.length; i++) {
+ if (keys == defaultKeymap[i].keys
+ && defaultKeymap[i].context === ctx
+ && defaultKeymap[i].user) {
+ defaultKeymap.splice(i, 1);
+ return;
+ }
+ }
+ }
+ }
+ };
+
+ var exCommands = {
+ colorscheme: function(cm, params) {
+ if (!params.args || params.args.length < 1) {
+ showConfirm(cm, cm.getOption('theme'));
+ return;
+ }
+ cm.setOption('theme', params.args[0]);
+ },
+ map: function(cm, params, ctx) {
+ var mapArgs = params.args;
+ if (!mapArgs || mapArgs.length < 2) {
+ if (cm) {
+ showConfirm(cm, 'Invalid mapping: ' + params.input);
+ }
+ return;
+ }
+ exCommandDispatcher.map(mapArgs[0], mapArgs[1], ctx);
+ },
+ imap: function(cm, params) { this.map(cm, params, 'insert'); },
+ nmap: function(cm, params) { this.map(cm, params, 'normal'); },
+ vmap: function(cm, params) { this.map(cm, params, 'visual'); },
+ unmap: function(cm, params, ctx) {
+ var mapArgs = params.args;
+ if (!mapArgs || mapArgs.length < 1) {
+ if (cm) {
+ showConfirm(cm, 'No such mapping: ' + params.input);
+ }
+ return;
+ }
+ exCommandDispatcher.unmap(mapArgs[0], ctx);
+ },
+ move: function(cm, params) {
+ commandDispatcher.processCommand(cm, cm.state.vim, {
+ type: 'motion',
+ motion: 'moveToLineOrEdgeOfDocument',
+ motionArgs: { forward: false, explicitRepeat: true,
+ linewise: true },
+ repeatOverride: params.line+1});
+ },
+ set: function(cm, params) {
+ var setArgs = params.args;
+ var setCfg = params.setCfg || {};
+ if (!setArgs || setArgs.length < 1) {
+ if (cm) {
+ showConfirm(cm, 'Invalid mapping: ' + params.input);
+ }
+ return;
+ }
+ var expr = setArgs[0].split('=');
+ var optionName = expr[0];
+ var value = expr[1];
+ var forceGet = false;
+
+ if (optionName.charAt(optionName.length - 1) == '?') {
+ if (value) { throw Error('Trailing characters: ' + params.argString); }
+ optionName = optionName.substring(0, optionName.length - 1);
+ forceGet = true;
+ }
+ if (value === undefined && optionName.substring(0, 2) == 'no') {
+ optionName = optionName.substring(2);
+ value = false;
+ }
+
+ var optionIsBoolean = options[optionName] && options[optionName].type == 'boolean';
+ if (optionIsBoolean && value == undefined) {
+ value = true;
+ }
+ if (!optionIsBoolean && value === undefined || forceGet) {
+ var oldValue = getOption(optionName, cm, setCfg);
+ if (oldValue === true || oldValue === false) {
+ showConfirm(cm, ' ' + (oldValue ? '' : 'no') + optionName);
+ } else {
+ showConfirm(cm, ' ' + optionName + '=' + oldValue);
+ }
+ } else {
+ setOption(optionName, value, cm, setCfg);
+ }
+ },
+ setlocal: function (cm, params) {
+ params.setCfg = {scope: 'local'};
+ this.set(cm, params);
+ },
+ setglobal: function (cm, params) {
+ params.setCfg = {scope: 'global'};
+ this.set(cm, params);
+ },
+ registers: function(cm, params) {
+ var regArgs = params.args;
+ var registers = vimGlobalState.registerController.registers;
+ var regInfo = '----------Registers----------<br><br>';
+ if (!regArgs) {
+ for (var registerName in registers) {
+ var text = registers[registerName].toString();
+ if (text.length) {
+ regInfo += '"' + registerName + ' ' + text + '<br>';
+ }
+ }
+ } else {
+ var registerName;
+ regArgs = regArgs.join('');
+ for (var i = 0; i < regArgs.length; i++) {
+ registerName = regArgs.charAt(i);
+ if (!vimGlobalState.registerController.isValidRegister(registerName)) {
+ continue;
+ }
+ var register = registers[registerName] || new Register();
+ regInfo += '"' + registerName + ' ' + register.toString() + '<br>';
+ }
+ }
+ showConfirm(cm, regInfo);
+ },
+ sort: function(cm, params) {
+ var reverse, ignoreCase, unique, number;
+ function parseArgs() {
+ if (params.argString) {
+ var args = new CodeMirror.StringStream(params.argString);
+ if (args.eat('!')) { reverse = true; }
+ if (args.eol()) { return; }
+ if (!args.eatSpace()) { return 'Invalid arguments'; }
+ var opts = args.match(/[a-z]+/);
+ if (opts) {
+ opts = opts[0];
+ ignoreCase = opts.indexOf('i') != -1;
+ unique = opts.indexOf('u') != -1;
+ var decimal = opts.indexOf('d') != -1 && 1;
+ var hex = opts.indexOf('x') != -1 && 1;
+ var octal = opts.indexOf('o') != -1 && 1;
+ if (decimal + hex + octal > 1) { return 'Invalid arguments'; }
+ number = decimal && 'decimal' || hex && 'hex' || octal && 'octal';
+ }
+ if (args.match(/\/.*\//)) { return 'patterns not supported'; }
+ }
+ }
+ var err = parseArgs();
+ if (err) {
+ showConfirm(cm, err + ': ' + params.argString);
+ return;
+ }
+ var lineStart = params.line || cm.firstLine();
+ var lineEnd = params.lineEnd || params.line || cm.lastLine();
+ if (lineStart == lineEnd) { return; }
+ var curStart = Pos(lineStart, 0);
+ var curEnd = Pos(lineEnd, lineLength(cm, lineEnd));
+ var text = cm.getRange(curStart, curEnd).split('\n');
+ var numberRegex = (number == 'decimal') ? /(-?)([\d]+)/ :
+ (number == 'hex') ? /(-?)(?:0x)?([0-9a-f]+)/i :
+ (number == 'octal') ? /([0-7]+)/ : null;
+ var radix = (number == 'decimal') ? 10 : (number == 'hex') ? 16 : (number == 'octal') ? 8 : null;
+ var numPart = [], textPart = [];
+ if (number) {
+ for (var i = 0; i < text.length; i++) {
+ if (numberRegex.exec(text[i])) {
+ numPart.push(text[i]);
+ } else {
+ textPart.push(text[i]);
+ }
+ }
+ } else {
+ textPart = text;
+ }
+ function compareFn(a, b) {
+ if (reverse) { var tmp; tmp = a; a = b; b = tmp; }
+ if (ignoreCase) { a = a.toLowerCase(); b = b.toLowerCase(); }
+ var anum = number && numberRegex.exec(a);
+ var bnum = number && numberRegex.exec(b);
+ if (!anum) { return a < b ? -1 : 1; }
+ anum = parseInt((anum[1] + anum[2]).toLowerCase(), radix);
+ bnum = parseInt((bnum[1] + bnum[2]).toLowerCase(), radix);
+ return anum - bnum;
+ }
+ numPart.sort(compareFn);
+ textPart.sort(compareFn);
+ text = (!reverse) ? textPart.concat(numPart) : numPart.concat(textPart);
+ if (unique) { // Remove duplicate lines
+ var textOld = text;
+ var lastLine;
+ text = [];
+ for (var i = 0; i < textOld.length; i++) {
+ if (textOld[i] != lastLine) {
+ text.push(textOld[i]);
+ }
+ lastLine = textOld[i];
+ }
+ }
+ cm.replaceRange(text.join('\n'), curStart, curEnd);
+ },
+ global: function(cm, params) {
+ var argString = params.argString;
+ if (!argString) {
+ showConfirm(cm, 'Regular Expression missing from global');
+ return;
+ }
+ var lineStart = (params.line !== undefined) ? params.line : cm.firstLine();
+ var lineEnd = params.lineEnd || params.line || cm.lastLine();
+ var tokens = splitBySlash(argString);
+ var regexPart = argString, cmd;
+ if (tokens.length) {
+ regexPart = tokens[0];
+ cmd = tokens.slice(1, tokens.length).join('/');
+ }
+ if (regexPart) {
+ try {
+ updateSearchQuery(cm, regexPart, true /** ignoreCase */,
+ true /** smartCase */);
+ } catch (e) {
+ showConfirm(cm, 'Invalid regex: ' + regexPart);
+ return;
+ }
+ }
+ var query = getSearchState(cm).getQuery();
+ var matchedLines = [], content = '';
+ for (var i = lineStart; i <= lineEnd; i++) {
+ var matched = query.test(cm.getLine(i));
+ if (matched) {
+ matchedLines.push(i+1);
+ content+= cm.getLine(i) + '<br>';
+ }
+ }
+ if (!cmd) {
+ showConfirm(cm, content);
+ return;
+ }
+ var index = 0;
+ var nextCommand = function() {
+ if (index < matchedLines.length) {
+ var command = matchedLines[index] + cmd;
+ exCommandDispatcher.processCommand(cm, command, {
+ callback: nextCommand
+ });
+ }
+ index++;
+ };
+ nextCommand();
+ },
+ substitute: function(cm, params) {
+ if (!cm.getSearchCursor) {
+ throw new Error('Search feature not available. Requires searchcursor.js or ' +
+ 'any other getSearchCursor implementation.');
+ }
+ var argString = params.argString;
+ var tokens = argString ? splitBySlash(argString) : [];
+ var regexPart, replacePart = '', trailing, flagsPart, count;
+ var confirm = false; // Whether to confirm each replace.
+ var global = false; // True to replace all instances on a line, false to replace only 1.
+ if (tokens.length) {
+ regexPart = tokens[0];
+ replacePart = tokens[1];
+ if (replacePart !== undefined) {
+ if (getOption('pcre')) {
+ replacePart = unescapeRegexReplace(replacePart);
+ } else {
+ replacePart = translateRegexReplace(replacePart);
+ }
+ vimGlobalState.lastSubstituteReplacePart = replacePart;
+ }
+ trailing = tokens[2] ? tokens[2].split(' ') : [];
+ } else {
+ if (argString && argString.length) {
+ showConfirm(cm, 'Substitutions should be of the form ' +
+ ':s/pattern/replace/');
+ return;
+ }
+ }
+ if (trailing) {
+ flagsPart = trailing[0];
+ count = parseInt(trailing[1]);
+ if (flagsPart) {
+ if (flagsPart.indexOf('c') != -1) {
+ confirm = true;
+ flagsPart.replace('c', '');
+ }
+ if (flagsPart.indexOf('g') != -1) {
+ global = true;
+ flagsPart.replace('g', '');
+ }
+ regexPart = regexPart + '/' + flagsPart;
+ }
+ }
+ if (regexPart) {
+ try {
+ updateSearchQuery(cm, regexPart, true /** ignoreCase */,
+ true /** smartCase */);
+ } catch (e) {
+ showConfirm(cm, 'Invalid regex: ' + regexPart);
+ return;
+ }
+ }
+ replacePart = replacePart || vimGlobalState.lastSubstituteReplacePart;
+ if (replacePart === undefined) {
+ showConfirm(cm, 'No previous substitute regular expression');
+ return;
+ }
+ var state = getSearchState(cm);
+ var query = state.getQuery();
+ var lineStart = (params.line !== undefined) ? params.line : cm.getCursor().line;
+ var lineEnd = params.lineEnd || lineStart;
+ if (lineStart == cm.firstLine() && lineEnd == cm.lastLine()) {
+ lineEnd = Infinity;
+ }
+ if (count) {
+ lineStart = lineEnd;
+ lineEnd = lineStart + count - 1;
+ }
+ var startPos = clipCursorToContent(cm, Pos(lineStart, 0));
+ var cursor = cm.getSearchCursor(query, startPos);
+ doReplace(cm, confirm, global, lineStart, lineEnd, cursor, query, replacePart, params.callback);
+ },
+ redo: CodeMirror.commands.redo,
+ undo: CodeMirror.commands.undo,
+ write: function(cm) {
+ if (CodeMirror.commands.save) {
+ CodeMirror.commands.save(cm);
+ } else {
+ cm.save();
+ }
+ },
+ nohlsearch: function(cm) {
+ clearSearchHighlight(cm);
+ },
+ delmarks: function(cm, params) {
+ if (!params.argString || !trim(params.argString)) {
+ showConfirm(cm, 'Argument required');
+ return;
+ }
+
+ var state = cm.state.vim;
+ var stream = new CodeMirror.StringStream(trim(params.argString));
+ while (!stream.eol()) {
+ stream.eatSpace();
+ var count = stream.pos;
+
+ if (!stream.match(/[a-zA-Z]/, false)) {
+ showConfirm(cm, 'Invalid argument: ' + params.argString.substring(count));
+ return;
+ }
+
+ var sym = stream.next();
+ if (stream.match('-', true)) {
+ if (!stream.match(/[a-zA-Z]/, false)) {
+ showConfirm(cm, 'Invalid argument: ' + params.argString.substring(count));
+ return;
+ }
+
+ var startMark = sym;
+ var finishMark = stream.next();
+ if (isLowerCase(startMark) && isLowerCase(finishMark) ||
+ isUpperCase(startMark) && isUpperCase(finishMark)) {
+ var start = startMark.charCodeAt(0);
+ var finish = finishMark.charCodeAt(0);
+ if (start >= finish) {
+ showConfirm(cm, 'Invalid argument: ' + params.argString.substring(count));
+ return;
+ }
+ for (var j = 0; j <= finish - start; j++) {
+ var mark = String.fromCharCode(start + j);
+ delete state.marks[mark];
+ }
+ } else {
+ showConfirm(cm, 'Invalid argument: ' + startMark + '-');
+ return;
+ }
+ } else {
+ delete state.marks[sym];
+ }
+ }
+ }
+ };
+
+ var exCommandDispatcher = new ExCommandDispatcher();
+ function doReplace(cm, confirm, global, lineStart, lineEnd, searchCursor, query,
+ replaceWith, callback) {
+ cm.state.vim.exMode = true;
+ var done = false;
+ var lastPos = searchCursor.from();
+ function replaceAll() {
+ cm.operation(function() {
+ while (!done) {
+ replace();
+ next();
+ }
+ stop();
+ });
+ }
+ function replace() {
+ var text = cm.getRange(searchCursor.from(), searchCursor.to());
+ var newText = text.replace(query, replaceWith);
+ searchCursor.replace(newText);
+ }
+ function next() {
+ while(searchCursor.findNext() &&
+ isInRange(searchCursor.from(), lineStart, lineEnd)) {
+ if (!global && lastPos && searchCursor.from().line == lastPos.line) {
+ continue;
+ }
+ cm.scrollIntoView(searchCursor.from(), 30);
+ cm.setSelection(searchCursor.from(), searchCursor.to());
+ lastPos = searchCursor.from();
+ done = false;
+ return;
+ }
+ done = true;
+ }
+ function stop(close) {
+ if (close) { close(); }
+ cm.focus();
+ if (lastPos) {
+ cm.setCursor(lastPos);
+ var vim = cm.state.vim;
+ vim.exMode = false;
+ vim.lastHPos = vim.lastHSPos = lastPos.ch;
+ }
+ if (callback) { callback(); }
+ }
+ function onPromptKeyDown(e, _value, close) {
+ CodeMirror.e_stop(e);
+ var keyName = CodeMirror.keyName(e);
+ switch (keyName) {
+ case 'Y':
+ replace(); next(); break;
+ case 'N':
+ next(); break;
+ case 'A':
+ var savedCallback = callback;
+ callback = undefined;
+ cm.operation(replaceAll);
+ callback = savedCallback;
+ break;
+ case 'L':
+ replace();
+ case 'Q':
+ case 'Esc':
+ case 'Ctrl-C':
+ case 'Ctrl-[':
+ stop(close);
+ break;
+ }
+ if (done) { stop(close); }
+ return true;
+ }
+ next();
+ if (done) {
+ showConfirm(cm, 'No matches for ' + query.source);
+ return;
+ }
+ if (!confirm) {
+ replaceAll();
+ if (callback) { callback(); }
+ return;
+ }
+ showPrompt(cm, {
+ prefix: 'replace with <strong>' + replaceWith + '</strong> (y/n/a/q/l)',
+ onKeyDown: onPromptKeyDown
+ });
+ }
+
+ CodeMirror.keyMap.vim = {
+ attach: attachVimMap,
+ detach: detachVimMap,
+ call: cmKey
+ };
+
+ function exitInsertMode(cm) {
+ var vim = cm.state.vim;
+ var macroModeState = vimGlobalState.macroModeState;
+ var insertModeChangeRegister = vimGlobalState.registerController.getRegister('.');
+ var isPlaying = macroModeState.isPlaying;
+ var lastChange = macroModeState.lastInsertModeChanges;
+ var text = [];
+ if (!isPlaying) {
+ var selLength = lastChange.inVisualBlock ? vim.lastSelection.visualBlock.height : 1;
+ var changes = lastChange.changes;
+ var text = [];
+ var i = 0;
+ while (i < changes.length) {
+ text.push(changes[i]);
+ if (changes[i] instanceof InsertModeKey) {
+ i++;
+ } else {
+ i+= selLength;
+ }
+ }
+ lastChange.changes = text;
+ cm.off('change', onChange);
+ CodeMirror.off(cm.getInputField(), 'keydown', onKeyEventTargetKeyDown);
+ }
+ if (!isPlaying && vim.insertModeRepeat > 1) {
+ repeatLastEdit(cm, vim, vim.insertModeRepeat - 1,
+ true /** repeatForInsert */);
+ vim.lastEditInputState.repeatOverride = vim.insertModeRepeat;
+ }
+ delete vim.insertModeRepeat;
+ vim.insertMode = false;
+ cm.setCursor(cm.getCursor().line, cm.getCursor().ch-1);
+ cm.setOption('keyMap', 'vim');
+ cm.setOption('disableInput', true);
+
+ lastChange.overwrite = cm.state.overwrite;
+ cm.toggleOverwrite(false); // exit replace mode if we were in it.
+ insertModeChangeRegister.setText(lastChange.changes.join(''));
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "normal"});
+ if (macroModeState.isRecording) {
+ logInsertModeChange(macroModeState);
+ }
+ }
+
+ function _mapCommand(command) {
+ defaultKeymap.unshift(command);
+ }
+
+ function mapCommand(keys, type, name, args, extra) {
+ var command = {keys: keys, type: type};
+ command[type] = name;
+ command[type + "Args"] = args;
+ for (var key in extra)
+ command[key] = extra[key];
+ _mapCommand(command);
+ }
+ defineOption('insertModeEscKeysTimeout', 200, 'number');
+
+ CodeMirror.keyMap['vim-insert'] = {
+ 'Ctrl-N': 'autocomplete',
+ 'Ctrl-P': 'autocomplete',
+ 'Enter': function(cm) {
+ var fn = CodeMirror.commands.newlineAndIndentContinueComment ||
+ CodeMirror.commands.newlineAndIndent;
+ fn(cm);
+ },
+ fallthrough: ['default'],
+ attach: attachVimMap,
+ detach: detachVimMap,
+ call: cmKey
+ };
+
+ CodeMirror.keyMap['vim-replace'] = {
+ 'Backspace': 'goCharLeft',
+ fallthrough: ['vim-insert'],
+ attach: attachVimMap,
+ detach: detachVimMap,
+ call: cmKey
+ };
+
+ function executeMacroRegister(cm, vim, macroModeState, registerName) {
+ var register = vimGlobalState.registerController.getRegister(registerName);
+ if (registerName == ':') {
+ if (register.keyBuffer[0]) {
+ exCommandDispatcher.processCommand(cm, register.keyBuffer[0]);
+ }
+ macroModeState.isPlaying = false;
+ return;
+ }
+ var keyBuffer = register.keyBuffer;
+ var imc = 0;
+ macroModeState.isPlaying = true;
+ macroModeState.replaySearchQueries = register.searchQueries.slice(0);
+ for (var i = 0; i < keyBuffer.length; i++) {
+ var text = keyBuffer[i];
+ var match, key;
+ while (text) {
+ match = (/<\w+-.+?>|<\w+>|./).exec(text);
+ key = match[0];
+ text = text.substring(match.index + key.length);
+ CodeMirror.Vim.handleKey(cm, key, 'macro');
+ if (vim.insertMode) {
+ var changes = register.insertModeChanges[imc++].changes;
+ vimGlobalState.macroModeState.lastInsertModeChanges.changes =
+ changes;
+ repeatInsertModeChanges(cm, changes, 1);
+ exitInsertMode(cm);
+ }
+ }
+ }
+ macroModeState.isPlaying = false;
+ }
+
+ function logKey(macroModeState, key) {
+ if (macroModeState.isPlaying) { return; }
+ var registerName = macroModeState.latestRegister;
+ var register = vimGlobalState.registerController.getRegister(registerName);
+ if (register) {
+ register.pushText(key);
+ }
+ }
+
+ function logInsertModeChange(macroModeState) {
+ if (macroModeState.isPlaying) { return; }
+ var registerName = macroModeState.latestRegister;
+ var register = vimGlobalState.registerController.getRegister(registerName);
+ if (register && register.pushInsertModeChanges) {
+ register.pushInsertModeChanges(macroModeState.lastInsertModeChanges);
+ }
+ }
+
+ function logSearchQuery(macroModeState, query) {
+ if (macroModeState.isPlaying) { return; }
+ var registerName = macroModeState.latestRegister;
+ var register = vimGlobalState.registerController.getRegister(registerName);
+ if (register && register.pushSearchQuery) {
+ register.pushSearchQuery(query);
+ }
+ }
+ function onChange(_cm, changeObj) {
+ var macroModeState = vimGlobalState.macroModeState;
+ var lastChange = macroModeState.lastInsertModeChanges;
+ if (!macroModeState.isPlaying) {
+ while(changeObj) {
+ lastChange.expectCursorActivityForChange = true;
+ if (changeObj.origin == '+input' || changeObj.origin == 'paste'
+ || changeObj.origin === undefined /* only in testing */) {
+ var text = changeObj.text.join('\n');
+ if (lastChange.maybeReset) {
+ lastChange.changes = [];
+ lastChange.maybeReset = false;
+ }
+ lastChange.changes.push(text);
+ }
+ changeObj = changeObj.next;
+ }
+ }
+ }
+ function onCursorActivity(cm) {
+ var vim = cm.state.vim;
+ if (vim.insertMode) {
+ var macroModeState = vimGlobalState.macroModeState;
+ if (macroModeState.isPlaying) { return; }
+ var lastChange = macroModeState.lastInsertModeChanges;
+ if (lastChange.expectCursorActivityForChange) {
+ lastChange.expectCursorActivityForChange = false;
+ } else {
+ lastChange.maybeReset = true;
+ }
+ } else if (!cm.curOp.isVimOp) {
+ handleExternalSelection(cm, vim);
+ }
+ if (vim.visualMode) {
+ updateFakeCursor(cm);
+ }
+ }
+ function updateFakeCursor(cm) {
+ var vim = cm.state.vim;
+ var from = clipCursorToContent(cm, copyCursor(vim.sel.head));
+ var to = offsetCursor(from, 0, 1);
+ if (vim.fakeCursor) {
+ vim.fakeCursor.clear();
+ }
+ vim.fakeCursor = cm.markText(from, to, {className: 'cm-animate-fat-cursor'});
+ }
+ function handleExternalSelection(cm, vim) {
+ var anchor = cm.getCursor('anchor');
+ var head = cm.getCursor('head');
+ if (vim.visualMode && !cm.somethingSelected()) {
+ exitVisualMode(cm, false);
+ } else if (!vim.visualMode && !vim.insertMode && cm.somethingSelected()) {
+ vim.visualMode = true;
+ vim.visualLine = false;
+ CodeMirror.signal(cm, "vim-mode-change", {mode: "visual"});
+ }
+ if (vim.visualMode) {
+ var headOffset = !cursorIsBefore(head, anchor) ? -1 : 0;
+ var anchorOffset = cursorIsBefore(head, anchor) ? -1 : 0;
+ head = offsetCursor(head, 0, headOffset);
+ anchor = offsetCursor(anchor, 0, anchorOffset);
+ vim.sel = {
+ anchor: anchor,
+ head: head
+ };
+ updateMark(cm, vim, '<', cursorMin(head, anchor));
+ updateMark(cm, vim, '>', cursorMax(head, anchor));
+ } else if (!vim.insertMode) {
+ vim.lastHPos = cm.getCursor().ch;
+ }
+ }
+ function InsertModeKey(keyName) {
+ this.keyName = keyName;
+ }
+ function onKeyEventTargetKeyDown(e) {
+ var macroModeState = vimGlobalState.macroModeState;
+ var lastChange = macroModeState.lastInsertModeChanges;
+ var keyName = CodeMirror.keyName(e);
+ if (!keyName) { return; }
+ function onKeyFound() {
+ if (lastChange.maybeReset) {
+ lastChange.changes = [];
+ lastChange.maybeReset = false;
+ }
+ lastChange.changes.push(new InsertModeKey(keyName));
+ return true;
+ }
+ if (keyName.indexOf('Delete') != -1 || keyName.indexOf('Backspace') != -1) {
+ CodeMirror.lookupKey(keyName, 'vim-insert', onKeyFound);
+ }
+ }
+ function repeatLastEdit(cm, vim, repeat, repeatForInsert) {
+ var macroModeState = vimGlobalState.macroModeState;
+ macroModeState.isPlaying = true;
+ var isAction = !!vim.lastEditActionCommand;
+ var cachedInputState = vim.inputState;
+ function repeatCommand() {
+ if (isAction) {
+ commandDispatcher.processAction(cm, vim, vim.lastEditActionCommand);
+ } else {
+ commandDispatcher.evalInput(cm, vim);
+ }
+ }
+ function repeatInsert(repeat) {
+ if (macroModeState.lastInsertModeChanges.changes.length > 0) {
+ repeat = !vim.lastEditActionCommand ? 1 : repeat;
+ var changeObject = macroModeState.lastInsertModeChanges;
+ repeatInsertModeChanges(cm, changeObject.changes, repeat, changeObject.overwrite);
+ }
+ }
+ vim.inputState = vim.lastEditInputState;
+ if (isAction && vim.lastEditActionCommand.interlaceInsertRepeat) {
+ for (var i = 0; i < repeat; i++) {
+ repeatCommand();
+ repeatInsert(1);
+ }
+ } else {
+ if (!repeatForInsert) {
+ repeatCommand();
+ }
+ repeatInsert(repeat);
+ }
+ vim.inputState = cachedInputState;
+ if (vim.insertMode && !repeatForInsert) {
+ exitInsertMode(cm);
+ }
+ macroModeState.isPlaying = false;
+ }
+
+ function repeatInsertModeChanges(cm, changes, repeat, overwrite) {
+ function keyHandler(binding) {
+ if (typeof binding == 'string') {
+ CodeMirror.commands[binding](cm);
+ } else {
+ binding(cm);
+ }
+ return true;
+ }
+ var head = cm.getCursor('head');
+ var inVisualBlock = vimGlobalState.macroModeState.lastInsertModeChanges.inVisualBlock;
+ if (inVisualBlock) {
+ var vim = cm.state.vim;
+ var lastSel = vim.lastSelection;
+ var offset = getOffset(lastSel.anchor, lastSel.head);
+ selectForInsert(cm, head, offset.line + 1);
+ repeat = cm.listSelections().length;
+ cm.setCursor(head);
+ }
+ for (var i = 0; i < repeat; i++) {
+ if (inVisualBlock) {
+ cm.setCursor(offsetCursor(head, i, 0));
+ }
+ for (var j = 0; j < changes.length; j++) {
+ var change = changes[j];
+ if (change instanceof InsertModeKey) {
+ CodeMirror.lookupKey(change.keyName, 'vim-insert', keyHandler);
+ } else {
+ var cur = cm.getCursor();
+ var end = cur;
+ if (overwrite && !/\n/.test(change)) {
+ end = offsetCursor(cur, 0, change.length);
+ }
+ cm.replaceRange(change, cur, end);
+ }
+ }
+ }
+ if (inVisualBlock) {
+ cm.setCursor(offsetCursor(head, 0, 1));
+ }
+ }
+
+ resetVimGlobalState();
+ CodeMirror.Vim = Vim();
+
+ Vim = CodeMirror.Vim;
+
+ var specialKey = {'return':'CR',backspace:'BS','delete':'Del',esc:'Esc',
+ left:'Left',right:'Right',up:'Up',down:'Down',space: 'Space',
+ home:'Home',end:'End',pageup:'PageUp',pagedown:'PageDown', enter: 'CR'
+ };
+ function lookupKey(hashId, key, e) {
+ if (key.length > 1 && key[0] == "n") {
+ key = key.replace("numpad", "");
+ }
+ key = specialKey[key] || key;
+ var name = '';
+ if (e.ctrlKey) { name += 'C-'; }
+ if (e.altKey) { name += 'A-'; }
+ if (e.shiftKey) { name += 'S-'; }
+
+ name += key;
+ if (name.length > 1) { name = '<' + name + '>'; }
+ return name;
+ }
+ var handleKey = Vim.handleKey.bind(Vim);
+ Vim.handleKey = function(cm, key, origin) {
+ return cm.operation(function() {
+ return handleKey(cm, key, origin);
+ }, true);
+ }
+ function cloneVimState(state) {
+ var n = new state.constructor();
+ Object.keys(state).forEach(function(key) {
+ var o = state[key];
+ if (Array.isArray(o))
+ o = o.slice();
+ else if (o && typeof o == "object" && o.constructor != Object)
+ o = cloneVimState(o);
+ n[key] = o;
+ });
+ if (state.sel) {
+ n.sel = {
+ head: state.sel.head && copyCursor(state.sel.head),
+ anchor: state.sel.anchor && copyCursor(state.sel.anchor)
+ };
+ }
+ return n;
+ }
+ function multiSelectHandleKey(cm, key, origin) {
+ var isHandled = false;
+ var vim = Vim.maybeInitVimState_(cm);
+ var visualBlock = vim.visualBlock || vim.wasInVisualBlock;
+ if (vim.wasInVisualBlock && !cm.ace.inMultiSelectMode) {
+ vim.wasInVisualBlock = false;
+ } else if (cm.ace.inMultiSelectMode && vim.visualBlock) {
+ vim.wasInVisualBlock = true;
+ }
+
+ if (key == '<Esc>' && !vim.insertMode && !vim.visualMode && cm.ace.inMultiSelectMode) {
+ cm.ace.exitMultiSelectMode();
+ } else if (visualBlock || !cm.ace.inMultiSelectMode || cm.ace.inVirtualSelectionMode) {
+ isHandled = Vim.handleKey(cm, key, origin);
+ } else {
+ var old = cloneVimState(vim);
+ cm.operation(function() {
+ cm.ace.forEachSelection(function() {
+ var sel = cm.ace.selection;
+ cm.state.vim.lastHPos = sel.$desiredColumn == null ? sel.lead.column : sel.$desiredColumn;
+ var head = cm.getCursor("head");
+ var anchor = cm.getCursor("anchor");
+ var headOffset = !cursorIsBefore(head, anchor) ? -1 : 0;
+ var anchorOffset = cursorIsBefore(head, anchor) ? -1 : 0;
+ head = offsetCursor(head, 0, headOffset);
+ anchor = offsetCursor(anchor, 0, anchorOffset);
+ cm.state.vim.sel.head = head;
+ cm.state.vim.sel.anchor = anchor;
+
+ isHandled = handleKey(cm, key, origin);
+ sel.$desiredColumn = cm.state.vim.lastHPos == -1 ? null : cm.state.vim.lastHPos;
+ if (cm.virtualSelectionMode()) {
+ cm.state.vim = cloneVimState(old);
+ }
+ });
+ if (cm.curOp.cursorActivity && !isHandled)
+ cm.curOp.cursorActivity = false;
+ }, true);
+ }
+ return isHandled;
+ }
+ exports.CodeMirror = CodeMirror;
+ var getVim = Vim.maybeInitVimState_;
+ exports.handler = {
+ $id: "ace/keyboard/vim",
+ drawCursor: function(style, pixelPos, config, sel, session) {
+ var vim = this.state.vim || {};
+ var w = config.characterWidth;
+ var h = config.lineHeight;
+ var top = pixelPos.top;
+ var left = pixelPos.left;
+ if (!vim.insertMode) {
+ var isbackwards = !sel.cursor
+ ? session.selection.isBackwards() || session.selection.isEmpty()
+ : Range.comparePoints(sel.cursor, sel.start) <= 0;
+ if (!isbackwards && left > w)
+ left -= w;
+ }
+ if (!vim.insertMode && vim.status) {
+ h = h / 2;
+ top += h;
+ }
+ style.left = left + "px";
+ style.top = top + "px";
+ style.width = w + "px";
+ style.height = h + "px";
+ },
+ handleKeyboard: function(data, hashId, key, keyCode, e) {
+ var editor = data.editor;
+ var cm = editor.state.cm;
+ var vim = getVim(cm);
+ if (keyCode == -1) return;
+
+ if (key == "c" && hashId == 1) { // key == "ctrl-c"
+ if (!useragent.isMac && editor.getCopyText()) {
+ editor.once("copy", function() {
+ editor.selection.clearSelection();
+ });
+ return {command: "null", passEvent: true};
+ }
+ } else if (!vim.insertMode) {
+ if (useragent.isMac && this.handleMacRepeat(data, hashId, key)) {
+ hashId = -1;
+ key = data.inputChar;
+ }
+ }
+
+ if (hashId == -1 || hashId & 1 || hashId === 0 && key.length > 1) {
+ var insertMode = vim.insertMode;
+ var name = lookupKey(hashId, key, e || {});
+ if (vim.status == null)
+ vim.status = "";
+ var isHandled = multiSelectHandleKey(cm, name, 'user');
+ vim = getVim(cm); // may be changed by multiSelectHandleKey
+ if (isHandled && vim.status != null)
+ vim.status += name;
+ else if (vim.status == null)
+ vim.status = "";
+ cm._signal("changeStatus");
+ if (!isHandled && (hashId != -1 || insertMode))
+ return;
+ return {command: "null", passEvent: !isHandled};
+ }
+ },
+ attach: function(editor) {
+ if (!editor.state) editor.state = {};
+ var cm = new CodeMirror(editor);
+ editor.state.cm = cm;
+ editor.$vimModeHandler = this;
+ CodeMirror.keyMap.vim.attach(cm);
+ getVim(cm).status = null;
+ cm.on('vim-command-done', function() {
+ if (cm.virtualSelectionMode()) return;
+ getVim(cm).status = null;
+ cm.ace._signal("changeStatus");
+ cm.ace.session.markUndoGroup();
+ });
+ cm.on("changeStatus", function() {
+ cm.ace.renderer.updateCursor();
+ cm.ace._signal("changeStatus");
+ });
+ cm.on("vim-mode-change", function() {
+ if (cm.virtualSelectionMode()) return;
+ cm.ace.renderer.setStyle("normal-mode", !getVim(cm).insertMode);
+ cm._signal("changeStatus");
+ });
+ cm.ace.renderer.setStyle("normal-mode", !getVim(cm).insertMode);
+ editor.renderer.$cursorLayer.drawCursor = this.drawCursor.bind(cm);
+ this.updateMacCompositionHandlers(editor, true);
+ },
+ detach: function(editor) {
+ var cm = editor.state.cm;
+ CodeMirror.keyMap.vim.detach(cm);
+ cm.destroy();
+ editor.state.cm = null;
+ editor.$vimModeHandler = null;
+ editor.renderer.$cursorLayer.drawCursor = null;
+ editor.renderer.setStyle("normal-mode", false);
+ this.updateMacCompositionHandlers(editor, false);
+ },
+ getStatusText: function(editor) {
+ var cm = editor.state.cm;
+ var vim = getVim(cm);
+ if (vim.insertMode)
+ return "INSERT";
+ var status = "";
+ if (vim.visualMode) {
+ status += "VISUAL";
+ if (vim.visualLine)
+ status += " LINE";
+ if (vim.visualBlock)
+ status += " BLOCK";
+ }
+ if (vim.status)
+ status += (status ? " " : "") + vim.status;
+ return status;
+ },
+ handleMacRepeat: function(data, hashId, key) {
+ if (hashId == -1) {
+ data.inputChar = key;
+ data.lastEvent = "input";
+ } else if (data.inputChar && data.$lastHash == hashId && data.$lastKey == key) {
+ if (data.lastEvent == "input") {
+ data.lastEvent = "input1";
+ } else if (data.lastEvent == "input1") {
+ return true;
+ }
+ } else {
+ data.$lastHash = hashId;
+ data.$lastKey = key;
+ data.lastEvent = "keypress";
+ }
+ },
+ updateMacCompositionHandlers: function(editor, enable) {
+ var onCompositionUpdateOverride = function(text) {
+ var cm = editor.state.cm;
+ var vim = getVim(cm);
+ if (!vim.insertMode) {
+ var el = this.textInput.getElement();
+ el.blur();
+ el.focus();
+ el.value = text;
+ } else {
+ this.onCompositionUpdateOrig(text);
+ }
+ };
+ var onCompositionStartOverride = function(text) {
+ var cm = editor.state.cm;
+ var vim = getVim(cm);
+ if (!vim.insertMode) {
+ this.onCompositionStartOrig(text);
+ }
+ };
+ if (enable) {
+ if (!editor.onCompositionUpdateOrig) {
+ editor.onCompositionUpdateOrig = editor.onCompositionUpdate;
+ editor.onCompositionUpdate = onCompositionUpdateOverride;
+ editor.onCompositionStartOrig = editor.onCompositionStart;
+ editor.onCompositionStart = onCompositionStartOverride;
+ }
+ } else {
+ if (editor.onCompositionUpdateOrig) {
+ editor.onCompositionUpdate = editor.onCompositionUpdateOrig;
+ editor.onCompositionUpdateOrig = null;
+ editor.onCompositionStart = editor.onCompositionStartOrig;
+ editor.onCompositionStartOrig = null;
+ }
+ }
+ }
+ };
+ var renderVirtualNumbers = {
+ getText: function(session, row) {
+ return (Math.abs(session.selection.lead.row - row) || (row + 1 + (row < 9? "\xb7" : "" ))) + "";
+ },
+ getWidth: function(session, lastLineNumber, config) {
+ return session.getLength().toString().length * config.characterWidth;
+ },
+ update: function(e, editor) {
+ editor.renderer.$loop.schedule(editor.renderer.CHANGE_GUTTER);
+ },
+ attach: function(editor) {
+ editor.renderer.$gutterLayer.$renderer = this;
+ editor.on("changeSelection", this.update);
+ },
+ detach: function(editor) {
+ editor.renderer.$gutterLayer.$renderer = null;
+ editor.off("changeSelection", this.update);
+ }
+ };
+ Vim.defineOption({
+ name: "wrap",
+ set: function(value, cm) {
+ if (cm) {cm.ace.setOption("wrap", value)}
+ },
+ type: "boolean"
+ }, false);
+ Vim.defineEx('write', 'w', function() {
+ console.log(':write is not implemented')
+ });
+ defaultKeymap.push(
+ { keys: 'zc', type: 'action', action: 'fold', actionArgs: { open: false } },
+ { keys: 'zC', type: 'action', action: 'fold', actionArgs: { open: false, all: true } },
+ { keys: 'zo', type: 'action', action: 'fold', actionArgs: { open: true } },
+ { keys: 'zO', type: 'action', action: 'fold', actionArgs: { open: true, all: true } },
+ { keys: 'za', type: 'action', action: 'fold', actionArgs: { toggle: true } },
+ { keys: 'zA', type: 'action', action: 'fold', actionArgs: { toggle: true, all: true } },
+ { keys: 'zf', type: 'action', action: 'fold', actionArgs: { open: true, all: true } },
+ { keys: 'zd', type: 'action', action: 'fold', actionArgs: { open: true, all: true } },
+
+ { keys: '<C-A-k>', type: 'action', action: 'aceCommand', actionArgs: { name: "addCursorAbove" } },
+ { keys: '<C-A-j>', type: 'action', action: 'aceCommand', actionArgs: { name: "addCursorBelow" } },
+ { keys: '<C-A-S-k>', type: 'action', action: 'aceCommand', actionArgs: { name: "addCursorAboveSkipCurrent" } },
+ { keys: '<C-A-S-j>', type: 'action', action: 'aceCommand', actionArgs: { name: "addCursorBelowSkipCurrent" } },
+ { keys: '<C-A-h>', type: 'action', action: 'aceCommand', actionArgs: { name: "selectMoreBefore" } },
+ { keys: '<C-A-l>', type: 'action', action: 'aceCommand', actionArgs: { name: "selectMoreAfter" } },
+ { keys: '<C-A-S-h>', type: 'action', action: 'aceCommand', actionArgs: { name: "selectNextBefore" } },
+ { keys: '<C-A-S-l>', type: 'action', action: 'aceCommand', actionArgs: { name: "selectNextAfter" } }
+ );
+ actions.aceCommand = function(cm, actionArgs, vim) {
+ cm.vimCmd = actionArgs;
+ if (cm.ace.inVirtualSelectionMode)
+ cm.ace.on("beforeEndOperation", delayedExecAceCommand);
+ else
+ delayedExecAceCommand(null, cm.ace);
+ };
+ function delayedExecAceCommand(op, ace) {
+ ace.off("beforeEndOperation", delayedExecAceCommand);
+ var cmd = ace.state.cm.vimCmd;
+ if (cmd) {
+ ace.execCommand(cmd.exec ? cmd : cmd.name, cmd.args);
+ }
+ ace.curOp = ace.prevOp;
+ }
+ actions.fold = function(cm, actionArgs, vim) {
+ cm.ace.execCommand(['toggleFoldWidget', 'toggleFoldWidget', 'foldOther', 'unfoldall'
+ ][(actionArgs.all ? 2 : 0) + (actionArgs.open ? 1 : 0)]);
+ };
+
+ exports.handler.defaultKeymap = defaultKeymap;
+ exports.handler.actions = actions;
+ exports.Vim = Vim;
+
+ Vim.map("Y", "yy", "normal");
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-abap.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-abap.js
new file mode 100644
index 00000000..343481fe
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-abap.js
@@ -0,0 +1,214 @@
+ace.define("ace/mode/abap_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var AbapHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword":
+ "ADD ALIAS ALIASES ASCENDING ASSERT ASSIGN ASSIGNING AT BACK" +
+ " CALL CASE CATCH CHECK CLASS CLEAR CLOSE CNT COLLECT COMMIT COMMUNICATION COMPUTE CONCATENATE CONDENSE CONSTANTS CONTINUE CONTROLS CONVERT CREATE CURRENCY" +
+ " DATA DEFINE DEFINITION DEFERRED DELETE DESCENDING DESCRIBE DETAIL DIVIDE DO" +
+ " ELSE ELSEIF ENDAT ENDCASE ENDCLASS ENDDO ENDEXEC ENDFORM ENDFUNCTION ENDIF ENDIFEND ENDINTERFACE ENDLOOP ENDMETHOD ENDMODULE ENDON ENDPROVIDE ENDSELECT ENDTRY ENDWHILE EVENT EVENTS EXEC EXIT EXPORT EXPORTING EXTRACT" +
+ " FETCH FIELDS FORM FORMAT FREE FROM FUNCTION" +
+ " GENERATE GET" +
+ " HIDE" +
+ " IF IMPORT IMPORTING INDEX INFOTYPES INITIALIZATION INTERFACE INTERFACES INPUT INSERT IMPLEMENTATION" +
+ " LEAVE LIKE LINE LOAD LOCAL LOOP" +
+ " MESSAGE METHOD METHODS MODIFY MODULE MOVE MULTIPLY" +
+ " ON OVERLAY OPTIONAL OTHERS" +
+ " PACK PARAMETERS PERFORM POSITION PROGRAM PROVIDE PUT" +
+ " RAISE RANGES READ RECEIVE RECEIVING REDEFINITION REFERENCE REFRESH REJECT REPLACE REPORT RESERVE RESTORE RETURN RETURNING ROLLBACK" +
+ " SCAN SCROLL SEARCH SELECT SET SHIFT SKIP SORT SORTED SPLIT STANDARD STATICS STEP STOP SUBMIT SUBTRACT SUM SUMMARY SUPPRESS" +
+ " TABLES TIMES TRANSFER TRANSLATE TRY TYPE TYPES" +
+ " UNASSIGN ULINE UNPACK UPDATE" +
+ " WHEN WHILE WINDOW WRITE" +
+ " OCCURS STRUCTURE OBJECT PROPERTY" +
+ " CASTING APPEND RAISING VALUE COLOR" +
+ " CHANGING EXCEPTION EXCEPTIONS DEFAULT CHECKBOX COMMENT" +
+ " ID NUMBER FOR TITLE OUTPUT" +
+ " WITH EXIT USING" +
+ " INTO WHERE GROUP BY HAVING ORDER BY SINGLE" +
+ " APPENDING CORRESPONDING FIELDS OF TABLE" +
+ " LEFT RIGHT OUTER INNER JOIN AS CLIENT SPECIFIED BYPASSING BUFFER UP TO ROWS CONNECTING" +
+ " EQ NE LT LE GT GE NOT AND OR XOR IN LIKE BETWEEN",
+ "constant.language":
+ "TRUE FALSE NULL SPACE",
+ "support.type":
+ "c n i p f d t x string xstring decfloat16 decfloat34",
+ "keyword.operator":
+ "abs sign ceil floor trunc frac acos asin atan cos sin tan" +
+ " abapOperator cosh sinh tanh exp log log10 sqrt" +
+ " strlen xstrlen charlen numofchar dbmaxlen lines"
+ }, "text", true, " ");
+
+ var compoundKeywords = "WITH\\W+(?:HEADER\\W+LINE|FRAME|KEY)|NO\\W+STANDARD\\W+PAGE\\W+HEADING|"+
+ "EXIT\\W+FROM\\W+STEP\\W+LOOP|BEGIN\\W+OF\\W+(?:BLOCK|LINE)|BEGIN\\W+OF|"+
+ "END\\W+OF\\W+(?:BLOCK|LINE)|END\\W+OF|NO\\W+INTERVALS|"+
+ "RESPECTING\\W+BLANKS|SEPARATED\\W+BY|USING\\W+(?:EDIT\\W+MASK)|"+
+ "WHERE\\W+(?:LINE)|RADIOBUTTON\\W+GROUP|REF\\W+TO|"+
+ "(?:PUBLIC|PRIVATE|PROTECTED)(?:\\W+SECTION)?|DELETING\\W+(?:TRAILING|LEADING)"+
+ "(?:ALL\\W+OCCURRENCES)|(?:FIRST|LAST)\\W+OCCURRENCE|INHERITING\\W+FROM|"+
+ "LINE-COUNT|ADD-CORRESPONDING|AUTHORITY-CHECK|BREAK-POINT|CLASS-DATA|CLASS-METHODS|"+
+ "CLASS-METHOD|DIVIDE-CORRESPONDING|EDITOR-CALL|END-OF-DEFINITION|END-OF-PAGE|END-OF-SELECTION|"+
+ "FIELD-GROUPS|FIELD-SYMBOLS|FUNCTION-POOL|MOVE-CORRESPONDING|MULTIPLY-CORRESPONDING|NEW-LINE|"+
+ "NEW-PAGE|NEW-SECTION|PRINT-CONTROL|RP-PROVIDE-FROM-LAST|SELECT-OPTIONS|SELECTION-SCREEN|"+
+ "START-OF-SELECTION|SUBTRACT-CORRESPONDING|SYNTAX-CHECK|SYNTAX-TRACE|TOP-OF-PAGE|TYPE-POOL|"+
+ "TYPE-POOLS|LINE-SIZE|LINE-COUNT|MESSAGE-ID|DISPLAY-MODE|READ(?:-ONLY)?|"+
+ "IS\\W+(?:NOT\\W+)?(?:ASSIGNED|BOUND|INITIAL|SUPPLIED)";
+
+ this.$rules = {
+ "start" : [
+ {token : "string", regex : "`", next : "string"},
+ {token : "string", regex : "'", next : "qstring"},
+ {token : "doc.comment", regex : /^\*.+/},
+ {token : "comment", regex : /".+$/},
+ {token : "invalid", regex: "\\.{2,}"},
+ {token : "keyword.operator", regex: /\W[\-+%=<>*]\W|\*\*|[~:,\.&$]|->*?|=>/},
+ {token : "paren.lparen", regex : "[\\[({]"},
+ {token : "paren.rparen", regex : "[\\])}]"},
+ {token : "constant.numeric", regex: "[+-]?\\d+\\b"},
+ {token : "variable.parameter", regex : /sy|pa?\d\d\d\d\|t\d\d\d\.|innnn/},
+ {token : "keyword", regex : compoundKeywords},
+ {token : "variable.parameter", regex : /\w+-\w+(?:-\w+)*/},
+ {token : keywordMapper, regex : "\\b\\w+\\b"},
+ {caseInsensitive: true}
+ ],
+ "qstring" : [
+ {token : "constant.language.escape", regex : "''"},
+ {token : "string", regex : "'", next : "start"},
+ {defaultToken : "string"}
+ ],
+ "string" : [
+ {token : "constant.language.escape", regex : "``"},
+ {token : "string", regex : "`", next : "start"},
+ {defaultToken : "string"}
+ ]
+ };
+};
+oop.inherits(AbapHighlightRules, TextHighlightRules);
+
+exports.AbapHighlightRules = AbapHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/abap",["require","exports","module","ace/mode/abap_highlight_rules","ace/mode/folding/coffee","ace/range","ace/mode/text","ace/lib/oop"], function(require, exports, module) {
+"use strict";
+
+var Rules = require("./abap_highlight_rules").AbapHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+var Range = require("../range").Range;
+var TextMode = require("./text").Mode;
+var oop = require("../lib/oop");
+
+function Mode() {
+ this.HighlightRules = Rules;
+ this.foldingRules = new FoldMode();
+}
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = '"'
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ return indent;
+ };
+
+ this.$id = "ace/mode/abap";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-abc.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-abc.js
new file mode 100644
index 00000000..c03859db
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-abc.js
@@ -0,0 +1,261 @@
+ace.define("ace/mode/abc_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function (require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ var ABCHighlightRules = function () {
+
+ this.$rules = {
+ start: [
+ {
+ token: ['zupfnoter.information.comment.line.percentage', 'information.keyword', 'in formation.keyword.embedded'],
+ regex: '(%%%%)(hn\\.[a-z]*)(.*)',
+ comment: 'Instruction Comment'
+ },
+ {
+ token: ['information.comment.line.percentage', 'information.keyword.embedded'],
+ regex: '(%%)(.*)',
+ comment: 'Instruction Comment'
+ },
+
+ {
+ token: 'comment.line.percentage',
+ regex: '%.*',
+ comment: 'Comments'
+ },
+
+ {
+ token: 'barline.keyword.operator',
+ regex: '[\\[:]*[|:][|\\]:]*(?:\\[?[0-9]+)?|\\[[0-9]+',
+ comment: 'Bar lines'
+ },
+ {
+ token: ['information.keyword.embedded', 'information.argument.string.unquoted'],
+ regex: '(\\[[A-Za-z]:)([^\\]]*\\])',
+ comment: 'embedded Header lines'
+ },
+ {
+ token: ['information.keyword', 'information.argument.string.unquoted'],
+ regex: '^([A-Za-z]:)([^%\\\\]*)',
+ comment: 'Header lines'
+ },
+ {
+ token: ['text', 'entity.name.function', 'string.unquoted', 'text'],
+ regex: '(\\[)([A-Z]:)(.*?)(\\])',
+ comment: 'Inline fields'
+ },
+ {
+ token: ['accent.constant.language', 'pitch.constant.numeric', 'duration.constant.numeric'],
+ regex: '([\\^=_]*)([A-Ga-gz][,\']*)([0-9]*/*[><0-9]*)',
+ comment: 'Notes'
+ },
+ {
+ token: 'zupfnoter.jumptarget.string.quoted',
+ regex: '[\\"!]\\^\\:.*?[\\"!]',
+ comment: 'Zupfnoter jumptarget'
+ }, {
+ token: 'zupfnoter.goto.string.quoted',
+ regex: '[\\"!]\\^\\@.*?[\\"!]',
+ comment: 'Zupfnoter goto'
+ },
+ {
+ token: 'zupfnoter.annotation.string.quoted',
+ regex: '[\\"!]\\^\\!.*?[\\"!]',
+ comment: 'Zupfnoter annoation'
+ },
+ {
+ token: 'zupfnoter.annotationref.string.quoted',
+ regex: '[\\"!]\\^\\#.*?[\\"!]',
+ comment: 'Zupfnoter annotation reference'
+ },
+ {
+ token: 'chordname.string.quoted',
+ regex: '[\\"!]\\^.*?[\\"!]',
+ comment: 'abc chord'
+ },
+ {
+ token: 'string.quoted',
+ regex: '[\\"!].*?[\\"!]',
+ comment: 'abc annotation'
+ }
+
+ ]
+ };
+
+ this.normalizeRules();
+ };
+
+ ABCHighlightRules.metaData = {
+ fileTypes: ['abc'],
+ name: 'ABC',
+ scopeName: 'text.abcnotation'
+ };
+
+
+ oop.inherits(ABCHighlightRules, TextHighlightRules);
+
+ exports.ABCHighlightRules = ABCHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/abc",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/abc_highlight_rules","ace/mode/folding/cstyle"], function (require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var TextMode = require("./text").Mode;
+ var ABCHighlightRules = require("./abc_highlight_rules").ABCHighlightRules;
+ var FoldMode = require("./folding/cstyle").FoldMode;
+
+ var Mode = function () {
+ this.HighlightRules = ABCHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+ };
+ oop.inherits(Mode, TextMode);
+
+ (function () {
+ this.$id = "ace/mode/abc"
+ }).call(Mode.prototype);
+
+ exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-actionscript.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-actionscript.js
new file mode 100644
index 00000000..c1af1637
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-actionscript.js
@@ -0,0 +1,267 @@
+ace.define("ace/mode/actionscript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ActionScriptHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token: 'support.class.actionscript.2',
+ regex: '\\b(?:R(?:ecordset|DBMSResolver|adioButton(?:Group)?)|X(?:ML(?:Socket|Node|Connector)?|UpdateResolverDataHolder)|M(?:M(?:Save|Execute)|icrophoneMicrophone|o(?:use|vieClip(?:Loader)?)|e(?:nu(?:Bar)?|dia(?:Controller|Display|Playback))|ath)|B(?:yName|inding|utton)|S(?:haredObject|ystem|crollPane|t(?:yleSheet|age|ream)|ound|e(?:ndEvent|rviceObject)|OAPCall|lide)|N(?:umericStepper|et(?:stream|S(?:tream|ervices)|Connection|Debug(?:Config)?))|C(?:heckBox|o(?:ntextMenu(?:Item)?|okie|lor|m(?:ponentMixins|boBox))|ustomActions|lient|amera)|T(?:ypedValue|ext(?:Snapshot|Input|F(?:ield|ormat)|Area)|ree|AB)|Object|D(?:ownload|elta(?:Item|Packet)?|at(?:e(?:Chooser|Field)?|a(?:G(?:lue|rid)|Set|Type)))|U(?:RL|TC|IScrollBar)|P(?:opUpManager|endingCall|r(?:intJob|o(?:duct|gressBar)))|E(?:ndPoint|rror)|Video|Key|F(?:RadioButton|GridColumn|MessageBox|BarChart|S(?:croll(?:Bar|Pane)|tyleFormat|plitView)|orm|C(?:heckbox|omboBox|alendar)|unction|T(?:icker|ooltip(?:Lite)?|ree(?:Node)?)|IconButton|D(?:ataGrid|raggablePane)|P(?:ieChart|ushButton|ro(?:gressBar|mptBox))|L(?:i(?:stBox|neChart)|oadingBox)|AdvancedMessageBox)|W(?:indow|SDLURL|ebService(?:Connector)?)|L(?:ist|o(?:calConnection|ad(?:er|Vars)|g)|a(?:unch|bel))|A(?:sBroadcaster|cc(?:ordion|essibility)|S(?:Set(?:Native|PropFlags)|N(?:ew|ative)|C(?:onstructor|lamp(?:2)?)|InstanceOf)|pplication|lert|rray))\\b' },
+ { token: 'support.function.actionscript.2',
+ regex: '\\b(?:s(?:h(?:ift|ow(?:GridLines|Menu|Border|Settings|Headers|ColumnHeaders|Today|Preferences)?|ad(?:ow|ePane))|c(?:hema|ale(?:X|Mode|Y|Content)|r(?:oll(?:Track|Drag)?|een(?:Resolution|Color|DPI)))|t(?:yleSheet|op(?:Drag|A(?:nimation|llSounds|gent))?|epSize|a(?:tus|rt(?:Drag|A(?:nimation|gent))?))|i(?:n|ze|lence(?:TimeOut|Level))|o(?:ngname|urce|rt(?:Items(?:By)?|On(?:HeaderRelease)?|able(?:Columns)?)?)|u(?:ppressInvalidCalls|bstr(?:ing)?)|p(?:li(?:ce|t)|aceCol(?:umnsEqually|lumnsEqually))|e(?:nd(?:DefaultPushButtonEvent|AndLoad)?|curity|t(?:R(?:GB|o(?:otNode|w(?:Height|Count))|esizable(?:Columns)?|a(?:nge|te))|G(?:ain|roupName)|X(?:AxisTitle)?|M(?:i(?:n(?:imum|utes)|lliseconds)|o(?:nth(?:Names)?|tionLevel|de)|ultilineMode|e(?:ssage|nu(?:ItemEnabled(?:At)?|EnabledAt)|dia)|a(?:sk|ximum))|B(?:u(?:tton(?:s|Width)|fferTime)|a(?:seTabIndex|ndwidthLimit|ckground))|S(?:howAsDisabled|croll(?:ing|Speed|Content|Target|P(?:osition|roperties)|barState|Location)|t(?:yle(?:Property)?|opOnFocus|at(?:us|e))|i(?:ze|lenceLevel)|ort(?:able(?:Columns)?|Function)|p(?:litterBarPosition|acing)|e(?:conds|lect(?:Multiple|ion(?:Required|Type)?|Style|Color|ed(?:Node(?:s)?|Cell|I(?:nd(?:ices|ex)|tem(?:s)?))?|able))|kin|m(?:oothness|allScroll))|H(?:ighlight(?:s|Color)|Scroll|o(?:urs|rizontal)|eader(?:Symbol|Height|Text|Property|Format|Width|Location)?|as(?:Shader|CloseBox))|Y(?:ear|AxisTitle)?|N(?:ode(?:Properties|ExpansionHandler)|ewTextFormat)|C(?:h(?:ildNodes|a(?:ngeHandler|rt(?:Title|EventHandler)))|o(?:ntent(?:Size)?|okie|lumns)|ell(?:Symbol|Data)|l(?:i(?:ckHandler|pboard)|oseHandler)|redentials)|T(?:ype(?:dVaule)?|i(?:tle(?:barHeight)?|p(?:Target|Offset)?|me(?:out(?:Handler)?)?)|oggle|extFormat|ransform)|I(?:s(?:Branch|Open)|n(?:terval|putProperty)|con(?:SymbolName)?|te(?:rator|m(?:ByKey|Symbol)))|Orientation|D(?:i(?:splay(?:Range|Graphics|Mode|Clip|Text|edMonth)|rection)|uration|e(?:pth(?:Below|To|Above)|fault(?:GatewayURL|Mappings|NodeIconSymbolName)|l(?:iveryMode|ay)|bug(?:ID)?)|a(?:yOfWeekNames|t(?:e(?:Filter)?|a(?:Mapping(?:s)?|Item(?:Text|Property|Format)|Provider|All(?:Height|Property|Format|Width))?))|ra(?:wConnectors|gContent))|U(?:se(?:Shadow|HandCursor|EchoSuppression|rInput|Fade)|TC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear))|P(?:osition|ercentComplete|an(?:e(?:M(?:inimumSize|aximumSize)|Size|Title))?|ro(?:pert(?:y(?:Data)?|iesAt)|gress))|E(?:nabled|dit(?:Handler|able)|xpand(?:NodeTrigger|erSymbolName))|V(?:Scroll|olume|alue(?:Source)?)|KeyFrameInterval|Quality|F(?:i(?:eld|rst(?:DayOfWeek|VisibleNode))|ocus|ullYear|ps|ade(?:InLength|OutLength)|rame(?:Color|Width))|Width|L(?:ine(?:Color|Weight)|o(?:opback|adTarget)|a(?:rgeScroll|bel(?:Source|Placement)?))|A(?:s(?:Boolean|String|Number)|n(?:yTypedValue|imation)|ctiv(?:e(?:State(?:Handler)?|Handler)|ateHandler)|utoH(?:ideScrollBar|eight)))?|paratorBefore|ek|lect(?:ion(?:Disabled|Unfocused)?|ed(?:Node(?:s)?|Child|I(?:nd(?:ices|ex)|tem(?:s)?)|Dat(?:e|a))?|able(?:Ranges)?)|rver(?:String)?)|kip|qrt|wapDepths|lice|aveToSharedObj|moothing)|h(?:scroll(?:Policy)?|tml(?:Text)?|i(?:t(?:Test(?:TextNearPos)?|Area)|de(?:BuiltInItems|Child)?|ghlight(?:2D|3D)?)|orizontal|e(?:ight|ader(?:Re(?:nderer|lease)|Height|Text))|P(?:osition|ageScrollSize)|a(?:s(?:childNodes|MP3|S(?:creen(?:Broadcast|Playback)|treaming(?:Video|Audio)|ort)|Next|OwnProperty|Pr(?:inting|evious)|EmbeddedVideo|VideoEncoder|A(?:ccesibility|udio(?:Encoder)?))|ndlerName)|LineScrollSize)|ye(?:sLabel|ar)|n(?:o(?:t|de(?:Name|Close|Type|Open|Value)|Label)|u(?:llValue|mChild(?:S(?:creens|lides)|ren|Forms))|e(?:w(?:Item|line|Value|LocationDialog)|xt(?:S(?:cene|ibling|lide)|TabIndex|Value|Frame)?)?|ame(?:s)?)|c(?:h(?:ildNodes|eck|a(?:nge(?:sPending)?|r(?:CodeAt|At))|r)|o(?:s|n(?:st(?:ant|ructor)|nect|c(?:urrency|at)|t(?:ent(?:Type|Path)?|ains|rol(?:Placement|lerPolicy))|denseWhite|version)|py|l(?:or|umn(?:Stretch|Name(?:s)?|Count))|m(?:p(?:onent|lete)|ment))|u(?:stomItems|ePoint(?:s)?|r(?:veTo|Value|rent(?:Slide|ChildSlide|Item|F(?:ocused(?:S(?:creen|lide)|Form)|ps))))|e(?:il|ll(?:Renderer|Press|Edit|Focus(?:In|Out)))|l(?:i(?:ck|ents)|o(?:se(?:Button|Pane)?|ne(?:Node)?)|ear(?:S(?:haredObjects|treams)|Timeout|Interval)?)|a(?:ncelLabel|tch|p(?:tion|abilities)|l(?:cFields|l(?:e(?:e|r))?))|reate(?:GatewayConnection|Menu|Se(?:rver|gment)|C(?:hild(?:AtDepth)?|l(?:ient|ass(?:ChildAtDepth|Object(?:AtDepth)?))|all)|Text(?:Node|Field)|Item|Object(?:AtDepth)?|PopUp|E(?:lement|mptyMovieClip)))|t(?:h(?:is|row)|ype(?:of|Name)?|i(?:tle(?:StyleDeclaration)?|me(?:out)?)|o(?:talTime|String|olTipText|p|UpperCase|ggle(?:HighQuality)?|Lo(?:caleString|werCase))|e(?:st|llTarget|xt(?:RightMargin|Bold|S(?:ize|elected)|Height|Color|I(?:ndent|talic)|Disabled|Underline|F(?:ield|ont)|Width|LeftMargin|Align)?)|a(?:n|rget(?:Path)?|b(?:Stops|Children|Index|Enabled|leName))|r(?:y|igger|ac(?:e|k(?:AsMenu)?)))|i(?:s(?:Running|Branch|NaN|Con(?:soleOpen|nected)|Toggled|Installed|Open|D(?:own|ebugger)|P(?:urchased|ro(?:totypeOf|pertyEnumerable))|Empty|F(?:inite|ullyPopulated)|Local|Active)|n(?:s(?:tall|ertBefore)|cludeDeltaPacketInfo|t|it(?:ialize|Component|Pod|A(?:pplication|gent))?|de(?:nt|terminate|x(?:InParent(?:Slide|Form)?|Of)?)|put|validate|finity|LocalInternetCache)?|con(?:F(?:ield|unction))?|t(?:e(?:ratorScrolled|m(?:s|RollO(?:ut|ver)|ClassName))|alic)|d3|p|fFrameLoaded|gnore(?:Case|White))|o(?:s|n(?:R(?:ollO(?:ut|ver)|e(?:s(?:ize|ult)|l(?:ease(?:Outside)?|aseOutside)))|XML|Mouse(?:Move|Down|Up|Wheel)|S(?:ync|croller|tatus|oundComplete|e(?:tFocus|lect(?:edItem)?))|N(?:oticeEvent|etworkChange)|C(?:hanged|onnect|l(?:ipEvent|ose))|ID3|D(?:isconnect|eactivate|ata|ragO(?:ut|ver))|Un(?:install|load)|P(?:aymentResult|ress)|EnterFrame|K(?:illFocus|ey(?:Down|Up))|Fault|Lo(?:ad|g)|A(?:ctiv(?:ity|ate)|ppSt(?:op|art)))?|pe(?:n|ration)|verLayChildren|kLabel|ldValue|r(?:d)?)|d(?:i(?:s(?:connect|play(?:Normal|ed(?:Month|Year)|Full)|able(?:Shader|d(?:Ranges|Days)|CloseBox|Events))|rection)|o(?:cTypeDecl|tall|Decoding|main|LazyDecoding)|u(?:plicateMovieClip|ration)|e(?:stroy(?:ChildAt|Object)|code|fault(?:PushButton(?:Enabled)?|KeydownHandler)?|l(?:ta(?:Packet(?:Changed)?)?|ete(?:PopUp|All)?)|blocking)|a(?:shBoardSave|yNames|ta(?:Provider)?|rkshadow)|r(?:opdown(?:Width)?|a(?:w|gO(?:ut|ver))))|u(?:se(?:Sort|HandCursor|Codepage|EchoSuppression)|n(?:shift|install|derline|escape|format|watch|lo(?:ck|ad(?:Movie(?:Num)?)?))|pdate(?:Results|Mode|I(?:nputProperties|tem(?:ByIndex)?)|P(?:acket|roperties)|View|AfterEvent)|rl)|join|p(?:ixelAspectRatio|o(?:sition|p|w)|u(?:sh|rge|blish)|ercen(?:tComplete|Loaded)|lay(?:head(?:Change|Time)|ing|Hidden|erType)?|a(?:ssword|use|r(?:se(?:XML|CSS|Int|Float)|ent(?:Node|Is(?:S(?:creen|lide)|Form))|ams))|r(?:int(?:Num|AsBitmap(?:Num)?)?|o(?:to(?:type)?|pert(?:y|ies)|gress)|e(?:ss|v(?:ious(?:S(?:ibling|lide)|Value)?|Scene|Frame)|ferred(?:Height|Width))))|e(?:scape|n(?:code(?:r)?|ter(?:Frame)?|dFill|able(?:Shader|d|CloseBox|Events))|dit(?:able|Field|LocationDialog)|v(?:ent|al(?:uate)?)|q|x(?:tended|p|ec(?:ute)?|actSettings)|m(?:phasized(?:StyleDeclaration)?|bedFonts))|v(?:i(?:sible|ewPod)|ScrollPolicy|o(?:id|lume)|ersion|P(?:osition|ageScrollSize)|a(?:l(?:idat(?:ionError|e(?:Property|ActivationKey)?)|ue(?:Of)?)|riable)|LineScrollSize)|k(?:ind|ey(?:Down|Up|Press|FrameInterval))|q(?:sort|uality)|f(?:scommand|i(?:n(?:d(?:Text|First|Last)?|ally)|eldInfo|lter(?:ed|Func)?|rst(?:Slide|Child|DayOfWeek|VisibleNode)?)|o(?:nt|cus(?:In|edCell|Out|Enabled)|r(?:egroundDisabled|mat(?:ter)?))|unctionName|ps|l(?:oor|ush)|ace|romCharCode)|w(?:i(?:th|dth)|ordWrap|atch|riteAccess)|l(?:t|i(?:st(?:Owner)?|ne(?:Style|To))|o(?:c(?:k|a(?:t(?:ion|eByld)|l(?:ToGlobal|FileReadDisable)))|opback|ad(?:Movie(?:Num)?|S(?:crollContent|ound)|ed|Variables(?:Num)?|Application)?|g(?:Changes)?)|e(?:ngth|ft(?:Margin)?|ading)?|a(?:st(?:Slide|Child|Index(?:Of)?)?|nguage|b(?:el(?:Placement|F(?:ield|unction))?|leField)))|a(?:s(?:scociate(?:Controller|Display)|in|pectRatio|function)|nd|c(?:ceptConnection|tiv(?:ityLevel|ePlayControl)|os)|t(?:t(?:ach(?:Movie|Sound|Video|Audio)|ributes)|an(?:2)?)|dd(?:header|RequestHeader|Menu(?:Item(?:At)?|At)?|Sort|Header|No(?:tice|de(?:At)?)|C(?:olumn(?:At)?|uePoint)|T(?:oLocalInternetCache|reeNode(?:At)?)|I(?:con|tem(?:s(?:At)?|At)?)|DeltaItem|P(?:od|age|roperty)|EventListener|View|FieldInfo|Listener|Animation)?|uto(?:Size|Play|KeyNav|Load)|pp(?:endChild|ly(?:Changes|Updates)?)|vHardwareDisable|fterLoaded|l(?:ternateRowColors|ign|l(?:ow(?:InsecureDomain|Domain)|Transitions(?:InDone|OutDone))|bum)|r(?:tist|row|g(?:uments|List))|gent|bs)|r(?:ight(?:Margin)?|o(?:ot(?:S(?:creen|lide)|Form)|und|w(?:Height|Count)|llO(?:ut|ver))|e(?:s(?:yncDepth|t(?:orePane|artAnimation|rict)|iz(?:e|able(?:Columns)?)|olveDelta|ult(?:s)?|ponse)|c(?:o(?:ncile(?:Results|Updates)|rd)|eive(?:Video|Audio))|draw|jectConnection|place(?:Sel|ItemAt|AllItems)?|ve(?:al(?:Child)?|rse)|quest(?:SizeChange|Payment)?|f(?:errer|resh(?:ScrollContent|Destinations|Pane|FromSources)?)|lease(?:Outside)?|ad(?:Only|Access)|gister(?:SkinElement|C(?:olor(?:Style|Name)|lass)|InheritingStyle|Proxy)|move(?:Range|M(?:ovieClip|enu(?:Item(?:At)?|At))|Background|Sort|No(?:tice|de(?:sAt|At)?)|C(?:olum(?:nAt|At)|uePoints)|T(?:extField|reeNode(?:At)?)|Item(?:At)?|Pod|EventListener|FromLocalInternetCache|Listener|All(?:C(?:olumns|uePoints)|Items)?))|a(?:ndom|te|dioDot))|g(?:t|oto(?:Slide|NextSlide|PreviousSlide|FirstSlide|LastSlide|And(?:Stop|Play))|e(?:nre|t(?:R(?:GB|o(?:otNode|wCount)|e(?:sizable|mote))|X(?:AxisTitle)?|M(?:i(?:n(?:imum(?:Size)?|utes)|lliseconds)|onth(?:Names)?|ultilineMode|e(?:ssage|nu(?:ItemAt|EnabledAt|At))|aximum(?:Size)?)|B(?:ytes(?:Total|Loaded)|ounds|utton(?:s|Width)|eginIndex|a(?:ndwidthLimit|ckground))|S(?:howAsDisabled|croll(?:ing|Speed|Content|Position|barState|Location)|t(?:yle(?:Names)?|opOnFocus|ate)|ize|o(?:urce|rtState)|p(?:litterBarPosition|acing)|e(?:conds|lect(?:Multiple|ion(?:Required|Type)|Style|ed(?:Node(?:s)?|Cell|Text|I(?:nd(?:ices|ex)|tem(?:s)?))?)|rvice)|moothness|WFVersion)|H(?:ighlight(?:s|Color)|ours|e(?:ight|ader(?:Height|Text|Property|Format|Width|Location)?)|as(?:Shader|CloseBox))|Y(?:ear|AxisTitle)?|N(?:o(?:tices|de(?:DisplayedAt|At))|um(?:Children|berAvailable)|e(?:wTextFormat|xtHighestDepth))|C(?:h(?:ild(?:S(?:creen|lide)|Nodes|Form|At)|artTitle)|o(?:n(?:tent|figInfo)|okie|de|unt|lumn(?:Names|Count|Index|At))|uePoint|ellIndex|loseHandler|a(?:ll|retIndex))|T(?:ypedValue|i(?:tle(?:barHeight)?|p(?:Target|Offset)?|me(?:stamp|zoneOffset|out(?:State|Handler)|r)?)|oggle|ext(?:Extent|Format)?|r(?:ee(?:NodeAt|Length)|ans(?:form|actionId)))|I(?:s(?:Branch|Open)|n(?:stanceAtDepth|d(?:icesByKey|exByKey))|con(?:SymbolName)?|te(?:rator|m(?:sByKey|By(?:Name|Key)|id|ID|At))|d)|O(?:utput(?:Parameter(?:s|ByName)?|Value(?:s)?)|peration|ri(?:entation|ginalCellData))|D(?:i(?:s(?:play(?:Range|Mode|Clip|Index|edMonth)|kUsage)|rection)|uration|e(?:pth|faultNodeIconSymbolName|l(?:taPacket|ay)|bug(?:Config|ID)?)|a(?:y(?:OfWeekNames)?|t(?:e|a(?:Mapping(?:s)?|Item(?:Text|Property|Format)|Label|All(?:Height|Property|Format|Width))?))|rawConnectors)|U(?:se(?:Shadow|HandCursor|rInput|Fade)|RL|TC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear))|P(?:o(?:sition|ds)|ercentComplete|a(?:n(?:e(?:M(?:inimums|aximums)|Height|Title|Width))?|rentNode)|r(?:operty(?:Name|Data)?|efer(?:ences|red(?:Height|Width))))|E(?:n(?:dIndex|abled)|ditingData|x(?:panderSymbolName|andNodeTrigger))|V(?:iewed(?:Pods|Applications)|olume|ersion|alue(?:Source)?)|F(?:i(?:eld|rst(?:DayOfWeek|VisibleNode))|o(?:ntList|cus)|ullYear|ade(?:InLength|OutLength)|rame(?:Color|Width))|Width|L(?:ine(?:Color|Weight)|o(?:cal|adTarget)|ength|a(?:stTabIndex|bel(?:Source)?))|A(?:s(?:cii|Boolean|String|Number)|n(?:yTypedValue|imation)|ctiv(?:eState(?:Handler)?|ateHandler)|utoH(?:ideScrollBar|eight)|llItems|gent))?)?|lobal(?:StyleFormat|ToLocal)?|ain|roupName)|x(?:updatePackety|mlDecl)?|m(?:y(?:MethodName|Call)|in(?:imum)?|o(?:nthNames|tion(?:TimeOut|Level)|de(?:lChanged)?|use(?:Move|O(?:ut|ver)|Down(?:Somewhere|Outside)?|Up(?:Somewhere)?|WheelEnabled)|ve(?:To)?)|u(?:ted|lti(?:pleS(?:imultaneousAllowed|elections)|line))|e(?:ssage|nu(?:Show|Hide)?|th(?:od)?|diaType)|a(?:nufacturer|tch|x(?:scroll|hscroll|imum|HPosition|Chars|VPosition)?)|b(?:substring|chr|ord|length))|b(?:ytes(?:Total|Loaded)|indFormat(?:Strings|Function)|o(?:ttom(?:Scroll)?|ld|rder(?:Color)?)|u(?:tton(?:Height|Width)|iltInItems|ffer(?:Time|Length)|llet)|e(?:foreApplyUpdates|gin(?:GradientFill|Fill))|lockIndent|a(?:ndwidth|ckground(?:Style|Color|Disabled)?)|roadcastMessage)|onHTTPStatus)\\b' },
+ { token: 'support.constant.actionscript.2',
+ regex: '\\b(?:__proto__|__resolve|_accProps|_alpha|_changed|_currentframe|_droptarget|_flash|_focusrect|_framesloaded|_global|_height|_highquality|_level|_listeners|_lockroot|_name|_parent|_quality|_root|_rotation|_soundbuftime|_target|_totalframes|_url|_visible|_width|_x|_xmouse|_xscale|_y|_ymouse|_yscale)\\b' },
+ { token: 'keyword.control.actionscript.2',
+ regex: '\\b(?:dynamic|extends|import|implements|interface|public|private|new|static|super|var|for|in|break|continue|while|do|return|if|else|case|switch)\\b' },
+ { token: 'storage.type.actionscript.2',
+ regex: '\\b(?:Boolean|Number|String|Void)\\b' },
+ { token: 'constant.language.actionscript.2',
+ regex: '\\b(?:null|undefined|true|false)\\b' },
+ { token: 'constant.numeric.actionscript.2',
+ regex: '\\b(?:0(?:x|X)[0-9a-fA-F]*|(?:[0-9]+\\.?[0-9]*|\\.[0-9]+)(?:(?:e|E)(?:\\+|-)?[0-9]+)?)(?:L|l|UL|ul|u|U|F|f)?\\b' },
+ { token: 'punctuation.definition.string.begin.actionscript.2',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.actionscript.2',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.actionscript.2',
+ regex: '\\\\.' },
+ { defaultToken: 'string.quoted.double.actionscript.2' } ] },
+ { token: 'punctuation.definition.string.begin.actionscript.2',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.actionscript.2',
+ regex: '\'',
+ next: 'pop' },
+ { token: 'constant.character.escape.actionscript.2',
+ regex: '\\\\.' },
+ { defaultToken: 'string.quoted.single.actionscript.2' } ] },
+ { token: 'support.constant.actionscript.2',
+ regex: '\\b(?:BACKSPACE|CAPSLOCK|CONTROL|DELETEKEY|DOWN|END|ENTER|HOME|INSERT|LEFT|LN10|LN2|LOG10E|LOG2E|MAX_VALUE|MIN_VALUE|NEGATIVE_INFINITY|NaN|PGDN|PGUP|PI|POSITIVE_INFINITY|RIGHT|SPACE|SQRT1_2|SQRT2|UP)\\b' },
+ { token: 'punctuation.definition.comment.actionscript.2',
+ regex: '/\\*',
+ push:
+ [ { token: 'punctuation.definition.comment.actionscript.2',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.actionscript.2' } ] },
+ { token: 'punctuation.definition.comment.actionscript.2',
+ regex: '//.*$',
+ push_:
+ [ { token: 'comment.line.double-slash.actionscript.2',
+ regex: '$',
+ next: 'pop' },
+ { defaultToken: 'comment.line.double-slash.actionscript.2' } ] },
+ { token: 'keyword.operator.actionscript.2',
+ regex: '\\binstanceof\\b' },
+ { token: 'keyword.operator.symbolic.actionscript.2',
+ regex: '[-!%&*+=/?:]' },
+ { token:
+ [ 'meta.preprocessor.actionscript.2',
+ 'punctuation.definition.preprocessor.actionscript.2',
+ 'meta.preprocessor.actionscript.2' ],
+ regex: '^([ \\t]*)(#)([a-zA-Z]+)' },
+ { token:
+ [ 'storage.type.function.actionscript.2',
+ 'meta.function.actionscript.2',
+ 'entity.name.function.actionscript.2',
+ 'meta.function.actionscript.2',
+ 'punctuation.definition.parameters.begin.actionscript.2' ],
+ regex: '\\b(function)(\\s+)([a-zA-Z_]\\w*)(\\s*)(\\()',
+ push:
+ [ { token: 'punctuation.definition.parameters.end.actionscript.2',
+ regex: '\\)',
+ next: 'pop' },
+ { token: 'variable.parameter.function.actionscript.2',
+ regex: '[^,)$]+' },
+ { defaultToken: 'meta.function.actionscript.2' } ] },
+ { token:
+ [ 'storage.type.class.actionscript.2',
+ 'meta.class.actionscript.2',
+ 'entity.name.type.class.actionscript.2',
+ 'meta.class.actionscript.2',
+ 'storage.modifier.extends.actionscript.2',
+ 'meta.class.actionscript.2',
+ 'entity.other.inherited-class.actionscript.2' ],
+ regex: '\\b(class)(\\s+)([a-zA-Z_](?:\\w|\\.)*)(?:(\\s+)(extends)(\\s+)([a-zA-Z_](?:\\w|\\.)*))?' } ] }
+
+ this.normalizeRules();
+};
+
+ActionScriptHighlightRules.metaData = { fileTypes: [ 'as' ],
+ keyEquivalent: '^~A',
+ name: 'ActionScript',
+ scopeName: 'source.actionscript.2' }
+
+
+oop.inherits(ActionScriptHighlightRules, TextHighlightRules);
+
+exports.ActionScriptHighlightRules = ActionScriptHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/actionscript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/actionscript_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ActionScriptHighlightRules = require("./actionscript_highlight_rules").ActionScriptHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ActionScriptHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/actionscript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-ada.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-ada.js
new file mode 100644
index 00000000..da059886
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-ada.js
@@ -0,0 +1,87 @@
+ace.define("ace/mode/ada_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var AdaHighlightRules = function() {
+var keywords = "abort|else|new|return|abs|elsif|not|reverse|abstract|end|null|accept|entry|select|" +
+"access|exception|of|separate|aliased|exit|or|some|all|others|subtype|and|for|out|synchronized|" +
+"array|function|overriding|at|tagged|generic|package|task|begin|goto|pragma|terminate|" +
+"body|private|then|if|procedure|type|case|in|protected|constant|interface|until|" +
+"|is|raise|use|declare|range|delay|limited|record|when|delta|loop|rem|while|digits|renames|with|do|mod|requeue|xor";
+
+ var builtinConstants = (
+ "true|false|null"
+ );
+
+ var builtinFunctions = (
+ "count|min|max|avg|sum|rank|now|coalesce|main"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords,
+ "constant.language": builtinConstants
+ }, "identifier", true);
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "--.*$"
+ }, {
+ token : "string", // " string
+ regex : '".*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'.*?'"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+ };
+};
+
+oop.inherits(AdaHighlightRules, TextHighlightRules);
+
+exports.AdaHighlightRules = AdaHighlightRules;
+});
+
+ace.define("ace/mode/ada",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ada_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var AdaHighlightRules = require("./ada_highlight_rules").AdaHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = AdaHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "--";
+
+ this.$id = "ace/mode/ada";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-apache_conf.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-apache_conf.js
new file mode 100644
index 00000000..bb6566a9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-apache_conf.js
@@ -0,0 +1,356 @@
+ace.define("ace/mode/apache_conf_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ApacheConfHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token:
+ [ 'punctuation.definition.comment.apacheconf',
+ 'comment.line.hash.ini',
+ 'comment.line.hash.ini' ],
+ regex: '^((?:\\s)*)(#)(.*$)' },
+ { token:
+ [ 'punctuation.definition.tag.apacheconf',
+ 'entity.tag.apacheconf',
+ 'text',
+ 'string.value.apacheconf',
+ 'punctuation.definition.tag.apacheconf' ],
+ regex: '(<)(Proxy|ProxyMatch|IfVersion|Directory|DirectoryMatch|Files|FilesMatch|IfDefine|IfModule|Limit|LimitExcept|Location|LocationMatch|VirtualHost)(?:(\\s)(.+?))?(>)' },
+ { token:
+ [ 'punctuation.definition.tag.apacheconf',
+ 'entity.tag.apacheconf',
+ 'punctuation.definition.tag.apacheconf' ],
+ regex: '(</)(Proxy|ProxyMatch|IfVersion|Directory|DirectoryMatch|Files|FilesMatch|IfDefine|IfModule|Limit|LimitExcept|Location|LocationMatch|VirtualHost)(>)' },
+ { token:
+ [ 'keyword.alias.apacheconf', 'text',
+ 'string.regexp.apacheconf', 'text',
+ 'string.replacement.apacheconf', 'text' ],
+ regex: '(Rewrite(?:Rule|Cond))(\\s+)(.+?)(\\s+)(.+?)($|\\s)' },
+ { token:
+ [ 'keyword.alias.apacheconf', 'text',
+ 'entity.status.apacheconf', 'text',
+ 'string.regexp.apacheconf', 'text',
+ 'string.path.apacheconf', 'text' ],
+ regex: '(RedirectMatch)(?:(\\s+)(\\d\\d\\d|permanent|temp|seeother|gone))?(\\s+)(.+?)(\\s+)(?:(.+?)($|\\s))?' },
+ { token:
+ [ 'keyword.alias.apacheconf', 'text',
+ 'entity.status.apacheconf', 'text',
+ 'string.path.apacheconf', 'text',
+ 'string.path.apacheconf', 'text' ],
+ regex: '(Redirect)(?:(\\s+)(\\d\\d\\d|permanent|temp|seeother|gone))?(\\s+)(.+?)(\\s+)(?:(.+?)($|\\s))?' },
+ { token:
+ [ 'keyword.alias.apacheconf', 'text',
+ 'string.regexp.apacheconf', 'text',
+ 'string.path.apacheconf', 'text' ],
+ regex: '(ScriptAliasMatch|AliasMatch)(\\s+)(.+?)(\\s+)(?:(.+?)(\\s))?' },
+ { token:
+ [ 'keyword.alias.apacheconf', 'text',
+ 'string.path.apacheconf', 'text',
+ 'string.path.apacheconf', 'text' ],
+ regex: '(RedirectPermanent|RedirectTemp|ScriptAlias|Alias)(\\s+)(.+?)(\\s+)(?:(.+?)($|\\s))?' },
+ { token: 'keyword.core.apacheconf',
+ regex: '\\b(?:AcceptPathInfo|AccessFileName|AddDefaultCharset|AddOutputFilterByType|AllowEncodedSlashes|AllowOverride|AuthName|AuthType|CGIMapExtension|ContentDigest|DefaultType|DocumentRoot|EnableMMAP|EnableSendfile|ErrorDocument|ErrorLog|FileETag|ForceType|HostnameLookups|IdentityCheck|Include|KeepAlive|KeepAliveTimeout|LimitInternalRecursion|LimitRequestBody|LimitRequestFields|LimitRequestFieldSize|LimitRequestLine|LimitXMLRequestBody|LogLevel|MaxKeepAliveRequests|NameVirtualHost|Options|Require|RLimitCPU|RLimitMEM|RLimitNPROC|Satisfy|ScriptInterpreterSource|ServerAdmin|ServerAlias|ServerName|ServerPath|ServerRoot|ServerSignature|ServerTokens|SetHandler|SetInputFilter|SetOutputFilter|TimeOut|TraceEnable|UseCanonicalName)\\b' },
+ { token: 'keyword.mpm.apacheconf',
+ regex: '\\b(?:AcceptMutex|AssignUserID|BS2000Account|ChildPerUserID|CoreDumpDirectory|EnableExceptionHook|Group|Listen|ListenBacklog|LockFile|MaxClients|MaxMemFree|MaxRequestsPerChild|MaxRequestsPerThread|MaxSpareServers|MaxSpareThreads|MaxThreads|MaxThreadsPerChild|MinSpareServers|MinSpareThreads|NumServers|PidFile|ReceiveBufferSize|ScoreBoardFile|SendBufferSize|ServerLimit|StartServers|StartThreads|ThreadLimit|ThreadsPerChild|ThreadStackSize|User|Win32DisableAcceptEx)\\b' },
+ { token: 'keyword.access.apacheconf',
+ regex: '\\b(?:Allow|Deny|Order)\\b' },
+ { token: 'keyword.actions.apacheconf',
+ regex: '\\b(?:Action|Script)\\b' },
+ { token: 'keyword.alias.apacheconf',
+ regex: '\\b(?:Alias|AliasMatch|Redirect|RedirectMatch|RedirectPermanent|RedirectTemp|ScriptAlias|ScriptAliasMatch)\\b' },
+ { token: 'keyword.auth.apacheconf',
+ regex: '\\b(?:AuthAuthoritative|AuthGroupFile|AuthUserFile)\\b' },
+ { token: 'keyword.auth_anon.apacheconf',
+ regex: '\\b(?:Anonymous|Anonymous_Authoritative|Anonymous_LogEmail|Anonymous_MustGiveEmail|Anonymous_NoUserID|Anonymous_VerifyEmail)\\b' },
+ { token: 'keyword.auth_dbm.apacheconf',
+ regex: '\\b(?:AuthDBMAuthoritative|AuthDBMGroupFile|AuthDBMType|AuthDBMUserFile)\\b' },
+ { token: 'keyword.auth_digest.apacheconf',
+ regex: '\\b(?:AuthDigestAlgorithm|AuthDigestDomain|AuthDigestFile|AuthDigestGroupFile|AuthDigestNcCheck|AuthDigestNonceFormat|AuthDigestNonceLifetime|AuthDigestQop|AuthDigestShmemSize)\\b' },
+ { token: 'keyword.auth_ldap.apacheconf',
+ regex: '\\b(?:AuthLDAPAuthoritative|AuthLDAPBindDN|AuthLDAPBindPassword|AuthLDAPCharsetConfig|AuthLDAPCompareDNOnServer|AuthLDAPDereferenceAliases|AuthLDAPEnabled|AuthLDAPFrontPageHack|AuthLDAPGroupAttribute|AuthLDAPGroupAttributeIsDN|AuthLDAPRemoteUserIsDN|AuthLDAPUrl)\\b' },
+ { token: 'keyword.autoindex.apacheconf',
+ regex: '\\b(?:AddAlt|AddAltByEncoding|AddAltByType|AddDescription|AddIcon|AddIconByEncoding|AddIconByType|DefaultIcon|HeaderName|IndexIgnore|IndexOptions|IndexOrderDefault|ReadmeName)\\b' },
+ { token: 'keyword.cache.apacheconf',
+ regex: '\\b(?:CacheDefaultExpire|CacheDisable|CacheEnable|CacheForceCompletion|CacheIgnoreCacheControl|CacheIgnoreHeaders|CacheIgnoreNoLastMod|CacheLastModifiedFactor|CacheMaxExpire)\\b' },
+ { token: 'keyword.cern_meta.apacheconf',
+ regex: '\\b(?:MetaDir|MetaFiles|MetaSuffix)\\b' },
+ { token: 'keyword.cgi.apacheconf',
+ regex: '\\b(?:ScriptLog|ScriptLogBuffer|ScriptLogLength)\\b' },
+ { token: 'keyword.cgid.apacheconf',
+ regex: '\\b(?:ScriptLog|ScriptLogBuffer|ScriptLogLength|ScriptSock)\\b' },
+ { token: 'keyword.charset_lite.apacheconf',
+ regex: '\\b(?:CharsetDefault|CharsetOptions|CharsetSourceEnc)\\b' },
+ { token: 'keyword.dav.apacheconf',
+ regex: '\\b(?:Dav|DavDepthInfinity|DavMinTimeout|DavLockDB)\\b' },
+ { token: 'keyword.deflate.apacheconf',
+ regex: '\\b(?:DeflateBufferSize|DeflateCompressionLevel|DeflateFilterNote|DeflateMemLevel|DeflateWindowSize)\\b' },
+ { token: 'keyword.dir.apacheconf',
+ regex: '\\b(?:DirectoryIndex|DirectorySlash)\\b' },
+ { token: 'keyword.disk_cache.apacheconf',
+ regex: '\\b(?:CacheDirLength|CacheDirLevels|CacheExpiryCheck|CacheGcClean|CacheGcDaily|CacheGcInterval|CacheGcMemUsage|CacheGcUnused|CacheMaxFileSize|CacheMinFileSize|CacheRoot|CacheSize|CacheTimeMargin)\\b' },
+ { token: 'keyword.dumpio.apacheconf',
+ regex: '\\b(?:DumpIOInput|DumpIOOutput)\\b' },
+ { token: 'keyword.env.apacheconf',
+ regex: '\\b(?:PassEnv|SetEnv|UnsetEnv)\\b' },
+ { token: 'keyword.expires.apacheconf',
+ regex: '\\b(?:ExpiresActive|ExpiresByType|ExpiresDefault)\\b' },
+ { token: 'keyword.ext_filter.apacheconf',
+ regex: '\\b(?:ExtFilterDefine|ExtFilterOptions)\\b' },
+ { token: 'keyword.file_cache.apacheconf',
+ regex: '\\b(?:CacheFile|MMapFile)\\b' },
+ { token: 'keyword.headers.apacheconf',
+ regex: '\\b(?:Header|RequestHeader)\\b' },
+ { token: 'keyword.imap.apacheconf',
+ regex: '\\b(?:ImapBase|ImapDefault|ImapMenu)\\b' },
+ { token: 'keyword.include.apacheconf',
+ regex: '\\b(?:SSIEndTag|SSIErrorMsg|SSIStartTag|SSITimeFormat|SSIUndefinedEcho|XBitHack)\\b' },
+ { token: 'keyword.isapi.apacheconf',
+ regex: '\\b(?:ISAPIAppendLogToErrors|ISAPIAppendLogToQuery|ISAPICacheFile|ISAPIFakeAsync|ISAPILogNotSupported|ISAPIReadAheadBuffer)\\b' },
+ { token: 'keyword.ldap.apacheconf',
+ regex: '\\b(?:LDAPCacheEntries|LDAPCacheTTL|LDAPConnectionTimeout|LDAPOpCacheEntries|LDAPOpCacheTTL|LDAPSharedCacheFile|LDAPSharedCacheSize|LDAPTrustedCA|LDAPTrustedCAType)\\b' },
+ { token: 'keyword.log.apacheconf',
+ regex: '\\b(?:BufferedLogs|CookieLog|CustomLog|LogFormat|TransferLog|ForensicLog)\\b' },
+ { token: 'keyword.mem_cache.apacheconf',
+ regex: '\\b(?:MCacheMaxObjectCount|MCacheMaxObjectSize|MCacheMaxStreamingBuffer|MCacheMinObjectSize|MCacheRemovalAlgorithm|MCacheSize)\\b' },
+ { token: 'keyword.mime.apacheconf',
+ regex: '\\b(?:AddCharset|AddEncoding|AddHandler|AddInputFilter|AddLanguage|AddOutputFilter|AddType|DefaultLanguage|ModMimeUsePathInfo|MultiviewsMatch|RemoveCharset|RemoveEncoding|RemoveHandler|RemoveInputFilter|RemoveLanguage|RemoveOutputFilter|RemoveType|TypesConfig)\\b' },
+ { token: 'keyword.misc.apacheconf',
+ regex: '\\b(?:ProtocolEcho|Example|AddModuleInfo|MimeMagicFile|CheckSpelling|ExtendedStatus|SuexecUserGroup|UserDir)\\b' },
+ { token: 'keyword.negotiation.apacheconf',
+ regex: '\\b(?:CacheNegotiatedDocs|ForceLanguagePriority|LanguagePriority)\\b' },
+ { token: 'keyword.nw_ssl.apacheconf',
+ regex: '\\b(?:NWSSLTrustedCerts|NWSSLUpgradeable|SecureListen)\\b' },
+ { token: 'keyword.proxy.apacheconf',
+ regex: '\\b(?:AllowCONNECT|NoProxy|ProxyBadHeader|ProxyBlock|ProxyDomain|ProxyErrorOverride|ProxyFtpDirCharset|ProxyIOBufferSize|ProxyMaxForwards|ProxyPass|ProxyPassReverse|ProxyPreserveHost|ProxyReceiveBufferSize|ProxyRemote|ProxyRemoteMatch|ProxyRequests|ProxyTimeout|ProxyVia)\\b' },
+ { token: 'keyword.rewrite.apacheconf',
+ regex: '\\b(?:RewriteBase|RewriteCond|RewriteEngine|RewriteLock|RewriteLog|RewriteLogLevel|RewriteMap|RewriteOptions|RewriteRule)\\b' },
+ { token: 'keyword.setenvif.apacheconf',
+ regex: '\\b(?:BrowserMatch|BrowserMatchNoCase|SetEnvIf|SetEnvIfNoCase)\\b' },
+ { token: 'keyword.so.apacheconf',
+ regex: '\\b(?:LoadFile|LoadModule)\\b' },
+ { token: 'keyword.ssl.apacheconf',
+ regex: '\\b(?:SSLCACertificateFile|SSLCACertificatePath|SSLCARevocationFile|SSLCARevocationPath|SSLCertificateChainFile|SSLCertificateFile|SSLCertificateKeyFile|SSLCipherSuite|SSLEngine|SSLMutex|SSLOptions|SSLPassPhraseDialog|SSLProtocol|SSLProxyCACertificateFile|SSLProxyCACertificatePath|SSLProxyCARevocationFile|SSLProxyCARevocationPath|SSLProxyCipherSuite|SSLProxyEngine|SSLProxyMachineCertificateFile|SSLProxyMachineCertificatePath|SSLProxyProtocol|SSLProxyVerify|SSLProxyVerifyDepth|SSLRandomSeed|SSLRequire|SSLRequireSSL|SSLSessionCache|SSLSessionCacheTimeout|SSLUserName|SSLVerifyClient|SSLVerifyDepth)\\b' },
+ { token: 'keyword.usertrack.apacheconf',
+ regex: '\\b(?:CookieDomain|CookieExpires|CookieName|CookieStyle|CookieTracking)\\b' },
+ { token: 'keyword.vhost_alias.apacheconf',
+ regex: '\\b(?:VirtualDocumentRoot|VirtualDocumentRootIP|VirtualScriptAlias|VirtualScriptAliasIP)\\b' },
+ { token:
+ [ 'keyword.php.apacheconf',
+ 'text',
+ 'entity.property.apacheconf',
+ 'text',
+ 'string.value.apacheconf',
+ 'text' ],
+ regex: '\\b(php_value|php_flag)\\b(?:(\\s+)(.+?)(?:(\\s+)(.+?))?)?(\\s)' },
+ { token:
+ [ 'punctuation.variable.apacheconf',
+ 'variable.env.apacheconf',
+ 'variable.misc.apacheconf',
+ 'punctuation.variable.apacheconf' ],
+ regex: '(%\\{)(?:(HTTP_USER_AGENT|HTTP_REFERER|HTTP_COOKIE|HTTP_FORWARDED|HTTP_HOST|HTTP_PROXY_CONNECTION|HTTP_ACCEPT|REMOTE_ADDR|REMOTE_HOST|REMOTE_PORT|REMOTE_USER|REMOTE_IDENT|REQUEST_METHOD|SCRIPT_FILENAME|PATH_INFO|QUERY_STRING|AUTH_TYPE|DOCUMENT_ROOT|SERVER_ADMIN|SERVER_NAME|SERVER_ADDR|SERVER_PORT|SERVER_PROTOCOL|SERVER_SOFTWARE|TIME_YEAR|TIME_MON|TIME_DAY|TIME_HOUR|TIME_MIN|TIME_SEC|TIME_WDAY|TIME|API_VERSION|THE_REQUEST|REQUEST_URI|REQUEST_FILENAME|IS_SUBREQ|HTTPS)|(.*?))(\\})' },
+ { token: [ 'entity.mime-type.apacheconf', 'text' ],
+ regex: '\\b((?:text|image|application|video|audio)/.+?)(\\s)' },
+ { token: 'entity.helper.apacheconf',
+ regex: '\\b(?:from|unset|set|on|off)\\b',
+ caseInsensitive: true },
+ { token: 'constant.integer.apacheconf', regex: '\\b\\d+\\b' },
+ { token:
+ [ 'text',
+ 'punctuation.definition.flag.apacheconf',
+ 'string.flag.apacheconf',
+ 'punctuation.definition.flag.apacheconf',
+ 'text' ],
+ regex: '(\\s)(\\[)(.*?)(\\])(\\s)' } ] }
+
+ this.normalizeRules();
+};
+
+ApacheConfHighlightRules.metaData = { fileTypes:
+ [ 'conf',
+ 'CONF',
+ 'htaccess',
+ 'HTACCESS',
+ 'htgroups',
+ 'HTGROUPS',
+ 'htpasswd',
+ 'HTPASSWD',
+ '.htaccess',
+ '.HTACCESS',
+ '.htgroups',
+ '.HTGROUPS',
+ '.htpasswd',
+ '.HTPASSWD' ],
+ name: 'Apache Conf',
+ scopeName: 'source.apacheconf' }
+
+
+oop.inherits(ApacheConfHighlightRules, TextHighlightRules);
+
+exports.ApacheConfHighlightRules = ApacheConfHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/apache_conf",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/apache_conf_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ApacheConfHighlightRules = require("./apache_conf_highlight_rules").ApacheConfHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ApacheConfHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/apache_conf";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-applescript.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-applescript.js
new file mode 100644
index 00000000..936ce2f7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-applescript.js
@@ -0,0 +1,271 @@
+ace.define("ace/mode/applescript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var AppleScriptHighlightRules = function() {
+ var keywords = (
+ "about|above|after|against|and|around|as|at|back|before|beginning|" +
+ "behind|below|beneath|beside|between|but|by|considering|" +
+ "contain|contains|continue|copy|div|does|eighth|else|end|equal|" +
+ "equals|error|every|exit|fifth|first|for|fourth|from|front|" +
+ "get|given|global|if|ignoring|in|into|is|it|its|last|local|me|" +
+ "middle|mod|my|ninth|not|of|on|onto|or|over|prop|property|put|ref|" +
+ "reference|repeat|returning|script|second|set|seventh|since|" +
+ "sixth|some|tell|tenth|that|the|then|third|through|thru|" +
+ "timeout|times|to|transaction|try|until|where|while|whose|with|without"
+ );
+
+ var builtinConstants = (
+ "AppleScript|false|linefeed|return|pi|quote|result|space|tab|true"
+ );
+
+ var builtinFunctions = (
+ "activate|beep|count|delay|launch|log|offset|read|round|run|say|" +
+ "summarize|write"
+ );
+
+ var builtinTypes = (
+ "alias|application|boolean|class|constant|date|file|integer|list|" +
+ "number|real|record|string|text|character|characters|contents|day|" +
+ "frontmost|id|item|length|month|name|paragraph|paragraphs|rest|" +
+ "reverse|running|time|version|weekday|word|words|year"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "constant.language": builtinConstants,
+ "support.type": builtinTypes,
+ "keyword": keywords
+ }, "identifier");
+
+ this.$rules = {
+ "start": [
+ {
+ token: "comment",
+ regex: "--.*$"
+ },
+ {
+ token : "comment", // multi line comment
+ regex : "\\(\\*",
+ next : "comment"
+ },
+ {
+ token: "string", // " string
+ regex: '".*?"'
+ },
+ {
+ token: "support.type",
+ regex: '\\b(POSIX file|POSIX path|(date|time) string|quoted form)\\b'
+ },
+ {
+ token: "support.function",
+ regex: '\\b(clipboard info|the clipboard|info for|list (disks|folder)|' +
+ 'mount volume|path to|(close|open for) access|(get|set) eof|' +
+ 'current date|do shell script|get volume settings|random number|' +
+ 'set volume|system attribute|system info|time to GMT|' +
+ '(load|run|store) script|scripting components|' +
+ 'ASCII (character|number)|localized string|' +
+ 'choose (application|color|file|file name|' +
+ 'folder|from list|remote application|URL)|' +
+ 'display (alert|dialog))\\b|^\\s*return\\b'
+ },
+ {
+ token: "constant.language",
+ regex: '\\b(text item delimiters|current application|missing value)\\b'
+ },
+ {
+ token: "keyword",
+ regex: '\\b(apart from|aside from|instead of|out of|greater than|' +
+ "isn't|(doesn't|does not) (equal|come before|come after|contain)|" +
+ '(greater|less) than( or equal)?|(starts?|ends|begins?) with|' +
+ 'contained by|comes (before|after)|a (ref|reference))\\b'
+ },
+ {
+ token: keywordMapper,
+ regex: "[a-zA-Z][a-zA-Z0-9_]*\\b"
+ }
+ ],
+ "comment": [
+ {
+ token: "comment", // closing comment
+ regex: "\\*\\)",
+ next: "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ]
+ }
+
+ this.normalizeRules();
+};
+
+oop.inherits(AppleScriptHighlightRules, TextHighlightRules);
+
+exports.AppleScriptHighlightRules = AppleScriptHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/applescript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/applescript_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var AppleScriptHighlightRules = require("./applescript_highlight_rules").AppleScriptHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = AppleScriptHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "(*", end: "*)"};
+ this.$id = "ace/mode/applescript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-asciidoc.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-asciidoc.js
new file mode 100644
index 00000000..f112cec3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-asciidoc.js
@@ -0,0 +1,342 @@
+ace.define("ace/mode/asciidoc_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var AsciidocHighlightRules = function() {
+ var identifierRe = "[a-zA-Z\u00a1-\uffff]+\\b";
+
+ this.$rules = {
+ "start": [
+ {token: "empty", regex: /$/},
+ {token: "literal", regex: /^\.{4,}\s*$/, next: "listingBlock"},
+ {token: "literal", regex: /^-{4,}\s*$/, next: "literalBlock"},
+ {token: "string", regex: /^\+{4,}\s*$/, next: "passthroughBlock"},
+ {token: "keyword", regex: /^={4,}\s*$/},
+ {token: "text", regex: /^\s*$/},
+ {token: "empty", regex: "", next: "dissallowDelimitedBlock"}
+ ],
+
+ "dissallowDelimitedBlock": [
+ {include: "paragraphEnd"},
+ {token: "comment", regex: '^//.+$'},
+ {token: "keyword", regex: "^(?:NOTE|TIP|IMPORTANT|WARNING|CAUTION):"},
+
+ {include: "listStart"},
+ {token: "literal", regex: /^\s+.+$/, next: "indentedBlock"},
+ {token: "empty", regex: "", next: "text"}
+ ],
+
+ "paragraphEnd": [
+ {token: "doc.comment", regex: /^\/{4,}\s*$/, next: "commentBlock"},
+ {token: "tableBlock", regex: /^\s*[|!]=+\s*$/, next: "tableBlock"},
+ {token: "keyword", regex: /^(?:--|''')\s*$/, next: "start"},
+ {token: "option", regex: /^\[.*\]\s*$/, next: "start"},
+ {token: "pageBreak", regex: /^>{3,}$/, next: "start"},
+ {token: "literal", regex: /^\.{4,}\s*$/, next: "listingBlock"},
+ {token: "titleUnderline", regex: /^(?:={2,}|-{2,}|~{2,}|\^{2,}|\+{2,})\s*$/, next: "start"},
+ {token: "singleLineTitle", regex: /^={1,5}\s+\S.*$/, next: "start"},
+
+ {token: "otherBlock", regex: /^(?:\*{2,}|_{2,})\s*$/, next: "start"},
+ {token: "optionalTitle", regex: /^\.[^.\s].+$/, next: "start"}
+ ],
+
+ "listStart": [
+ {token: "keyword", regex: /^\s*(?:\d+\.|[a-zA-Z]\.|[ixvmIXVM]+\)|\*{1,5}|-|\.{1,5})\s/, next: "listText"},
+ {token: "meta.tag", regex: /^.+(?::{2,4}|;;)(?: |$)/, next: "listText"},
+ {token: "support.function.list.callout", regex: /^(?:<\d+>|\d+>|>) /, next: "text"},
+ {token: "keyword", regex: /^\+\s*$/, next: "start"}
+ ],
+
+ "text": [
+ {token: ["link", "variable.language"], regex: /((?:https?:\/\/|ftp:\/\/|file:\/\/|mailto:|callto:)[^\s\[]+)(\[.*?\])/},
+ {token: "link", regex: /(?:https?:\/\/|ftp:\/\/|file:\/\/|mailto:|callto:)[^\s\[]+/},
+ {token: "link", regex: /\b[\w\.\/\-]+@[\w\.\/\-]+\b/},
+ {include: "macros"},
+ {include: "paragraphEnd"},
+ {token: "literal", regex:/\+{3,}/, next:"smallPassthrough"},
+ {token: "escape", regex: /\((?:C|TM|R)\)|\.{3}|->|<-|=>|<=|&#(?:\d+|x[a-fA-F\d]+);|(?: |^)--(?=\s+\S)/},
+ {token: "escape", regex: /\\[_*'`+#]|\\{2}[_*'`+#]{2}/},
+ {token: "keyword", regex: /\s\+$/},
+ {token: "text", regex: identifierRe},
+ {token: ["keyword", "string", "keyword"],
+ regex: /(<<[\w\d\-$]+,)(.*?)(>>|$)/},
+ {token: "keyword", regex: /<<[\w\d\-$]+,?|>>/},
+ {token: "constant.character", regex: /\({2,3}.*?\){2,3}/},
+ {token: "keyword", regex: /\[\[.+?\]\]/},
+ {token: "support", regex: /^\[{3}[\w\d =\-]+\]{3}/},
+
+ {include: "quotes"},
+ {token: "empty", regex: /^\s*$/, next: "start"}
+ ],
+
+ "listText": [
+ {include: "listStart"},
+ {include: "text"}
+ ],
+
+ "indentedBlock": [
+ {token: "literal", regex: /^[\s\w].+$/, next: "indentedBlock"},
+ {token: "literal", regex: "", next: "start"}
+ ],
+
+ "listingBlock": [
+ {token: "literal", regex: /^\.{4,}\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "constant.numeric", regex: '<\\d+>'},
+ {token: "literal", regex: '[^<]+'},
+ {token: "literal", regex: '<'}
+ ],
+ "literalBlock": [
+ {token: "literal", regex: /^-{4,}\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "constant.numeric", regex: '<\\d+>'},
+ {token: "literal", regex: '[^<]+'},
+ {token: "literal", regex: '<'}
+ ],
+ "passthroughBlock": [
+ {token: "literal", regex: /^\+{4,}\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "literal", regex: identifierRe + "|\\d+"},
+ {include: "macros"},
+ {token: "literal", regex: "."}
+ ],
+
+ "smallPassthrough": [
+ {token: "literal", regex: /[+]{3,}/, next: "dissallowDelimitedBlock"},
+ {token: "literal", regex: /^\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "literal", regex: identifierRe + "|\\d+"},
+ {include: "macros"}
+ ],
+
+ "commentBlock": [
+ {token: "doc.comment", regex: /^\/{4,}\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "doc.comment", regex: '^.*$'}
+ ],
+ "tableBlock": [
+ {token: "tableBlock", regex: /^\s*\|={3,}\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "tableBlock", regex: /^\s*!={3,}\s*$/, next: "innerTableBlock"},
+ {token: "tableBlock", regex: /\|/},
+ {include: "text", noEscape: true}
+ ],
+ "innerTableBlock": [
+ {token: "tableBlock", regex: /^\s*!={3,}\s*$/, next: "tableBlock"},
+ {token: "tableBlock", regex: /^\s*|={3,}\s*$/, next: "dissallowDelimitedBlock"},
+ {token: "tableBlock", regex: /!/}
+ ],
+ "macros": [
+ {token: "macro", regex: /{[\w\-$]+}/},
+ {token: ["text", "string", "text", "constant.character", "text"], regex: /({)([\w\-$]+)(:)?(.+)?(})/},
+ {token: ["text", "markup.list.macro", "keyword", "string"], regex: /(\w+)(footnote(?:ref)?::?)([^\s\[]+)?(\[.*?\])?/},
+ {token: ["markup.list.macro", "keyword", "string"], regex: /([a-zA-Z\-][\w\.\/\-]*::?)([^\s\[]+)(\[.*?\])?/},
+ {token: ["markup.list.macro", "keyword"], regex: /([a-zA-Z\-][\w\.\/\-]+::?)(\[.*?\])/},
+ {token: "keyword", regex: /^:.+?:(?= |$)/}
+ ],
+
+ "quotes": [
+ {token: "string.italic", regex: /__[^_\s].*?__/},
+ {token: "string.italic", regex: quoteRule("_")},
+
+ {token: "keyword.bold", regex: /\*\*[^*\s].*?\*\*/},
+ {token: "keyword.bold", regex: quoteRule("\\*")},
+
+ {token: "literal", regex: quoteRule("\\+")},
+ {token: "literal", regex: /\+\+[^+\s].*?\+\+/},
+ {token: "literal", regex: /\$\$.+?\$\$/},
+ {token: "literal", regex: quoteRule("`")},
+
+ {token: "keyword", regex: quoteRule("^")},
+ {token: "keyword", regex: quoteRule("~")},
+ {token: "keyword", regex: /##?/},
+ {token: "keyword", regex: /(?:\B|^)``|\b''/}
+ ]
+
+ };
+
+ function quoteRule(ch) {
+ var prefix = /\w/.test(ch) ? "\\b" : "(?:\\B|^)";
+ return prefix + ch + "[^" + ch + "].*?" + ch + "(?![\\w*])";
+ }
+
+ var tokenMap = {
+ macro: "constant.character",
+ tableBlock: "doc.comment",
+ titleUnderline: "markup.heading",
+ singleLineTitle: "markup.heading",
+ pageBreak: "string",
+ option: "string.regexp",
+ otherBlock: "markup.list",
+ literal: "support.function",
+ optionalTitle: "constant.numeric",
+ escape: "constant.language.escape",
+ link: "markup.underline.list"
+ };
+
+ for (var state in this.$rules) {
+ var stateRules = this.$rules[state];
+ for (var i = stateRules.length; i--; ) {
+ var rule = stateRules[i];
+ if (rule.include || typeof rule == "string") {
+ var args = [i, 1].concat(this.$rules[rule.include || rule]);
+ if (rule.noEscape) {
+ args = args.filter(function(x) {
+ return !x.next;
+ });
+ }
+ stateRules.splice.apply(stateRules, args);
+ } else if (rule.token in tokenMap) {
+ rule.token = tokenMap[rule.token];
+ }
+ }
+ }
+};
+oop.inherits(AsciidocHighlightRules, TextHighlightRules);
+
+exports.AsciidocHighlightRules = AsciidocHighlightRules;
+});
+
+ace.define("ace/mode/folding/asciidoc",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+ this.foldingStartMarker = /^(?:\|={10,}|[\.\/=\-~^+]{4,}\s*$|={1,5} )/;
+ this.singleLineHeadingRe = /^={1,5}(?=\s+\S)/;
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ if (!this.foldingStartMarker.test(line))
+ return ""
+
+ if (line[0] == "=") {
+ if (this.singleLineHeadingRe.test(line))
+ return "start";
+ if (session.getLine(row - 1).length != session.getLine(row).length)
+ return "";
+ return "start";
+ }
+ if (session.bgTokenizer.getState(row) == "dissallowDelimitedBlock")
+ return "end";
+ return "start";
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+ if (!line.match(this.foldingStartMarker))
+ return;
+
+ var token;
+ function getTokenType(row) {
+ token = session.getTokens(row)[0];
+ return token && token.type;
+ }
+
+ var levels = ["=","-","~","^","+"];
+ var heading = "markup.heading";
+ var singleLineHeadingRe = this.singleLineHeadingRe;
+ function getLevel() {
+ var match = token.value.match(singleLineHeadingRe);
+ if (match)
+ return match[0].length;
+ var level = levels.indexOf(token.value[0]) + 1;
+ if (level == 1) {
+ if (session.getLine(row - 1).length != session.getLine(row).length)
+ return Infinity;
+ }
+ return level;
+ }
+
+ if (getTokenType(row) == heading) {
+ var startHeadingLevel = getLevel();
+ while (++row < maxRow) {
+ if (getTokenType(row) != heading)
+ continue;
+ var level = getLevel();
+ if (level <= startHeadingLevel)
+ break;
+ }
+
+ var isSingleLineHeading = token && token.value.match(this.singleLineHeadingRe);
+ endRow = isSingleLineHeading ? row - 1 : row - 2;
+
+ if (endRow > startRow) {
+ while (endRow > startRow && (!getTokenType(endRow) || token.value[0] == "["))
+ endRow--;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ } else {
+ var state = session.bgTokenizer.getState(row);
+ if (state == "dissallowDelimitedBlock") {
+ while (row -- > 0) {
+ if (session.bgTokenizer.getState(row).lastIndexOf("Block") == -1)
+ break;
+ }
+ endRow = row + 1;
+ if (endRow < startRow) {
+ var endColumn = session.getLine(row).length;
+ return new Range(endRow, 5, startRow, startColumn - 5);
+ }
+ } else {
+ while (++row < maxRow) {
+ if (session.bgTokenizer.getState(row) == "dissallowDelimitedBlock")
+ break;
+ }
+ endRow = row;
+ if (endRow > startRow) {
+ var endColumn = session.getLine(row).length;
+ return new Range(startRow, 5, endRow, endColumn - 5);
+ }
+ }
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/asciidoc",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/asciidoc_highlight_rules","ace/mode/folding/asciidoc"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var AsciidocHighlightRules = require("./asciidoc_highlight_rules").AsciidocHighlightRules;
+var AsciidocFoldMode = require("./folding/asciidoc").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = AsciidocHighlightRules;
+
+ this.foldingRules = new AsciidocFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.type = "text";
+ this.getNextLineIndent = function(state, line, tab) {
+ if (state == "listblock") {
+ var match = /^((?:.+)?)([-+*][ ]+)/.exec(line);
+ if (match) {
+ return new Array(match[1].length + 1).join(" ") + match[2];
+ } else {
+ return "";
+ }
+ } else {
+ return this.$getIndent(line);
+ }
+ };
+ this.$id = "ace/mode/asciidoc";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-assembly_x86.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-assembly_x86.js
new file mode 100644
index 00000000..f6a56f1b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-assembly_x86.js
@@ -0,0 +1,186 @@
+ace.define("ace/mode/assembly_x86_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var AssemblyX86HighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token: 'keyword.control.assembly',
+ regex: '\\b(?:aaa|aad|aam|aas|adc|add|addpd|addps|addsd|addss|addsubpd|addsubps|aesdec|aesdeclast|aesenc|aesenclast|aesimc|aeskeygenassist|and|andpd|andps|andnpd|andnps|arpl|blendpd|blendps|blendvpd|blendvps|bound|bsf|bsr|bswap|bt|btc|btr|bts|cbw|cwde|cdqe|clc|cld|cflush|clts|cmc|cmov(?:n?e|ge?|ae?|le?|be?|n?o|n?z)|cmp|cmppd|cmpps|cmps|cnpsb|cmpsw|cmpsd|cmpsq|cmpss|cmpxchg|cmpxchg8b|cmpxchg16b|comisd|comiss|cpuid|crc32|cvtdq2pd|cvtdq2ps|cvtpd2dq|cvtpd2pi|cvtpd2ps|cvtpi2pd|cvtpi2ps|cvtps2dq|cvtps2pd|cvtps2pi|cvtsd2si|cvtsd2ss|cvts2sd|cvtsi2ss|cvtss2sd|cvtss2si|cvttpd2dq|cvtpd2pi|cvttps2dq|cvttps2pi|cvttps2dq|cvttps2pi|cvttsd2si|cvttss2si|cwd|cdq|cqo|daa|das|dec|div|divpd|divps|divsd|divss|dppd|dpps|emms|enter|extractps|f2xm1|fabs|fadd|faddp|fiadd|fbld|fbstp|fchs|fclex|fnclex|fcmov(?:n?e|ge?|ae?|le?|be?|n?o|n?z)|fcom|fcmop|fcompp|fcomi|fcomip|fucomi|fucomip|fcos|fdecstp|fdiv|fdivp|fidiv|fdivr|fdivrp|fidivr|ffree|ficom|ficomp|fild|fincstp|finit|fnint|fist|fistp|fisttp|fld|fld1|fldl2t|fldl2e|fldpi|fldlg2|fldln2|fldz|fldcw|fldenv|fmul|fmulp|fimul|fnop|fpatan|fprem|fprem1|fptan|frndint|frstor|fsave|fnsave|fscale|fsin|fsincos|fsqrt|fst|fstp|fstcw|fnstcw|fstenv|fnstenv|fsts|fnstsw|fsub|fsubp|fisub|fsubr|fsubrp|fisubr|ftst|fucom|fucomp|fucompp|fxam|fxch|fxrstor|fxsave|fxtract|fyl2x|fyl2xp1|haddpd|haddps|husbpd|hsubps|idiv|imul|in|inc|ins|insb|insw|insd|insertps|int|into|invd|invplg|invpcid|iret|iretd|iretq|lahf|lar|lddqu|ldmxcsr|lds|les|lfs|lgs|lss|lea|leave|lfence|lgdt|lidt|llgdt|lmsw|lock|lods|lodsb|lodsw|lodsd|lodsq|lsl|ltr|maskmovdqu|maskmovq|maxpd|maxps|maxsd|maxss|mfence|minpd|minps|minsd|minss|monitor|mov|movapd|movaps|movbe|movd|movq|movddup|movdqa|movdqu|movq2q|movhlps|movhpd|movhps|movlhps|movlpd|movlps|movmskpd|movmskps|movntdqa|movntdq|movnti|movntpd|movntps|movntq|movq|movq2dq|movs|movsb|movsw|movsd|movsq|movsd|movshdup|movsldup|movss|movsx|movsxd|movupd|movups|movzx|mpsadbw|mul|mulpd|mulps|mulsd|mulss|mwait|neg|not|or|orpd|orps|out|outs|outsb|outsw|outsd|pabsb|pabsw|pabsd|packsswb|packssdw|packusdw|packuswbpaddb|paddw|paddd|paddq|paddsb|paddsw|paddusb|paddusw|palignr|pand|pandn|pause|pavgb|pavgw|pblendvb|pblendw|pclmulqdq|pcmpeqb|pcmpeqw|pcmpeqd|pcmpeqq|pcmpestri|pcmpestrm|pcmptb|pcmptgw|pcmpgtd|pcmpgtq|pcmpistri|pcmpisrm|pextrb|pextrd|pextrq|pextrw|phaddw|phaddd|phaddsw|phinposuw|phsubw|phsubd|phsubsw|pinsrb|pinsrd|pinsrq|pinsrw|pmaddubsw|pmadddwd|pmaxsb|pmaxsd|pmaxsw|pmaxsw|pmaxub|pmaxud|pmaxuw|pminsb|pminsd|pminsw|pminub|pminud|pminuw|pmovmskb|pmovsx|pmovzx|pmuldq|pmulhrsw|pmulhuw|pmulhw|pmulld|pmullw|pmuludw|pop|popa|popad|popcnt|popf|popfd|popfq|por|prefetch|psadbw|pshufb|pshufd|pshufhw|pshuflw|pshufw|psignb|psignw|psignd|pslldq|psllw|pslld|psllq|psraw|psrad|psrldq|psrlw|psrld|psrlq|psubb|psubw|psubd|psubq|psubsb|psubsw|psubusb|psubusw|test|ptest|punpckhbw|punpckhwd|punpckhdq|punpckhddq|punpcklbw|punpcklwd|punpckldq|punpckldqd|push|pusha|pushad|pushf|pushfd|pxor|prcl|rcr|rol|ror|rcpps|rcpss|rdfsbase|rdgsbase|rdmsr|rdpmc|rdrand|rdtsc|rdtscp|rep|repe|repz|repne|repnz|roundpd|roundps|roundsd|roundss|rsm|rsqrps|rsqrtss|sahf|sal|sar|shl|shr|sbb|scas|scasb|scasw|scasd|set(?:n?e|ge?|ae?|le?|be?|n?o|n?z)|sfence|sgdt|shld|shrd|shufpd|shufps|sidt|sldt|smsw|sqrtpd|sqrtps|sqrtsd|sqrtss|stc|std|stmxcsr|stos|stosb|stosw|stosd|stosq|str|sub|subpd|subps|subsd|subss|swapgs|syscall|sysenter|sysexit|sysret|teset|ucomisd|ucomiss|ud2|unpckhpd|unpckhps|unpcklpd|unpcklps|vbroadcast|vcvtph2ps|vcvtp2sph|verr|verw|vextractf128|vinsertf128|vmaskmov|vpermilpd|vpermilps|vperm2f128|vtestpd|vtestps|vzeroall|vzeroupper|wait|fwait|wbinvd|wrfsbase|wrgsbase|wrmsr|xadd|xchg|xgetbv|xlat|xlatb|xor|xorpd|xorps|xrstor|xsave|xsaveopt|xsetbv|lzcnt|extrq|insertq|movntsd|movntss|vfmaddpd|vfmaddps|vfmaddsd|vfmaddss|vfmaddsubbpd|vfmaddsubps|vfmsubaddpd|vfmsubaddps|vfmsubpd|vfmsubps|vfmsubsd|vfnmaddpd|vfnmaddps|vfnmaddsd|vfnmaddss|vfnmsubpd|vfnmusbps|vfnmusbsd|vfnmusbss|cvt|xor|cli|sti|hlt|nop|lock|wait|enter|leave|ret|loop(?:n?e|n?z)?|call|j(?:mp|n?e|ge?|ae?|le?|be?|n?o|n?z))\\b',
+ caseInsensitive: true },
+ { token: 'variable.parameter.register.assembly',
+ regex: '\\b(?:CS|DS|ES|FS|GS|SS|RAX|EAX|RBX|EBX|RCX|ECX|RDX|EDX|RCX|RIP|EIP|IP|RSP|ESP|SP|RSI|ESI|SI|RDI|EDI|DI|RFLAGS|EFLAGS|FLAGS|R8-15|(?:Y|X)MM(?:[0-9]|10|11|12|13|14|15)|(?:A|B|C|D)(?:X|H|L)|CR(?:[0-4]|DR(?:[0-7]|TR6|TR7|EFER)))\\b',
+ caseInsensitive: true },
+ { token: 'constant.character.decimal.assembly',
+ regex: '\\b[0-9]+\\b' },
+ { token: 'constant.character.hexadecimal.assembly',
+ regex: '\\b0x[A-F0-9]+\\b',
+ caseInsensitive: true },
+ { token: 'constant.character.hexadecimal.assembly',
+ regex: '\\b[A-F0-9]+h\\b',
+ caseInsensitive: true },
+ { token: 'string.assembly', regex: /'([^\\']|\\.)*'/ },
+ { token: 'string.assembly', regex: /"([^\\"]|\\.)*"/ },
+ { token: 'support.function.directive.assembly',
+ regex: '^\\[',
+ push:
+ [ { token: 'support.function.directive.assembly',
+ regex: '\\]$',
+ next: 'pop' },
+ { defaultToken: 'support.function.directive.assembly' } ] },
+ { token:
+ [ 'support.function.directive.assembly',
+ 'support.function.directive.assembly',
+ 'entity.name.function.assembly' ],
+ regex: '(^struc)( )([_a-zA-Z][_a-zA-Z0-9]*)' },
+ { token: 'support.function.directive.assembly',
+ regex: '^endstruc\\b' },
+ { token:
+ [ 'support.function.directive.assembly',
+ 'entity.name.function.assembly',
+ 'support.function.directive.assembly',
+ 'constant.character.assembly' ],
+ regex: '^(%macro )([_a-zA-Z][_a-zA-Z0-9]*)( )([0-9]+)' },
+ { token: 'support.function.directive.assembly',
+ regex: '^%endmacro' },
+ { token:
+ [ 'text',
+ 'support.function.directive.assembly',
+ 'text',
+ 'entity.name.function.assembly' ],
+ regex: '(\\s*)(%define|%xdefine|%idefine|%undef|%assign|%defstr|%strcat|%strlen|%substr|%00|%0|%rotate|%rep|%endrep|%include|\\$\\$|\\$|%unmacro|%if|%elif|%else|%endif|%(?:el)?ifdef|%(?:el)?ifmacro|%(?:el)?ifctx|%(?:el)?ifidn|%(?:el)?ifidni|%(?:el)?ifid|%(?:el)?ifnum|%(?:el)?ifstr|%(?:el)?iftoken|%(?:el)?ifempty|%(?:el)?ifenv|%pathsearch|%depend|%use|%push|%pop|%repl|%arg|%stacksize|%local|%error|%warning|%fatal|%line|%!|%comment|%endcomment|__NASM_VERSION_ID__|__NASM_VER__|__FILE__|__LINE__|__BITS__|__OUTPUT_FORMAT__|__DATE__|__TIME__|__DATE_NUM__|_TIME__NUM__|__UTC_DATE__|__UTC_TIME__|__UTC_DATE_NUM__|__UTC_TIME_NUM__|__POSIX_TIME__|__PASS__|ISTRUC|AT|IEND|BITS 16|BITS 32|BITS 64|USE16|USE32|__SECT__|ABSOLUTE|EXTERN|GLOBAL|COMMON|CPU|FLOAT)\\b( ?)((?:[_a-zA-Z][_a-zA-Z0-9]*)?)',
+ caseInsensitive: true },
+ { token: 'support.function.directive.assembly',
+ regex: '\\b(?:d[bwdqtoy]|res[bwdqto]|equ|times|align|alignb|sectalign|section|ptr|byte|word|dword|qword|incbin)\\b',
+ caseInsensitive: true },
+ { token: 'entity.name.function.assembly', regex: '^\\s*%%[\\w.]+?:$' },
+ { token: 'entity.name.function.assembly', regex: '^\\s*%\\$[\\w.]+?:$' },
+ { token: 'entity.name.function.assembly', regex: '^[\\w.]+?:' },
+ { token: 'entity.name.function.assembly', regex: '^[\\w.]+?\\b' },
+ { token: 'comment.assembly', regex: ';.*$' } ]
+ }
+
+ this.normalizeRules();
+};
+
+AssemblyX86HighlightRules.metaData = { fileTypes: [ 'asm' ],
+ name: 'Assembly x86',
+ scopeName: 'source.assembly' }
+
+
+oop.inherits(AssemblyX86HighlightRules, TextHighlightRules);
+
+exports.AssemblyX86HighlightRules = AssemblyX86HighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/assembly_x86",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/assembly_x86_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var AssemblyX86HighlightRules = require("./assembly_x86_highlight_rules").AssemblyX86HighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = AssemblyX86HighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = ";";
+ this.$id = "ace/mode/assembly_x86";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-autohotkey.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-autohotkey.js
new file mode 100644
index 00000000..538e6fd7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-autohotkey.js
@@ -0,0 +1,235 @@
+ace.define("ace/mode/autohotkey_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var AutoHotKeyHighlightRules = function() {
+ var autoItKeywords = 'And|ByRef|Case|Const|ContinueCase|ContinueLoop|Default|Dim|Do|Else|ElseIf|EndFunc|EndIf|EndSelect|EndSwitch|EndWith|Enum|Exit|ExitLoop|False|For|Func|Global|If|In|Local|Next|Not|Or|ReDim|Return|Select|Step|Switch|Then|To|True|Until|WEnd|While|With|' +
+ 'Abs|ACos|AdlibDisable|AdlibEnable|Asc|AscW|ASin|Assign|ATan|AutoItSetOption|AutoItWinGetTitle|AutoItWinSetTitle|Beep|Binary|BinaryLen|BinaryMid|BinaryToString|BitAND|BitNOT|BitOR|BitRotate|BitShift|BitXOR|BlockInput|Break|Call|CDTray|Ceiling|Chr|ChrW|ClipGet|ClipPut|ConsoleRead|ConsoleWrite|ConsoleWriteError|ControlClick|ControlCommand|ControlDisable|ControlEnable|ControlFocus|ControlGetFocus|ControlGetHandle|ControlGetPos|ControlGetText|ControlHide|ControlListView|ControlMove|ControlSend|ControlSetText|ControlShow|ControlTreeView|Cos|Dec|DirCopy|DirCreate|DirGetSize|DirMove|DirRemove|DllCall|DllCallbackFree|DllCallbackGetPtr|DllCallbackRegister|DllClose|DllOpen|DllStructCreate|DllStructGetData|DllStructGetPtr|DllStructGetSize|DllStructSetData|DriveGetDrive|DriveGetFileSystem|DriveGetLabel|DriveGetSerial|DriveGetType|DriveMapAdd|DriveMapDel|DriveMapGet|DriveSetLabel|DriveSpaceFree|DriveSpaceTotal|DriveStatus|EnvGet|EnvSet|EnvUpdate|Eval|Execute|Exp|FileChangeDir|FileClose|FileCopy|FileCreateNTFSLink|FileCreateShortcut|FileDelete|FileExists|FileFindFirstFile|FileFindNextFile|FileGetAttrib|FileGetLongName|FileGetShortcut|FileGetShortName|FileGetSize|FileGetTime|FileGetVersion|FileInstall|FileMove|FileOpen|FileOpenDialog|FileRead|FileReadLine|FileRecycle|FileRecycleEmpty|FileSaveDialog|FileSelectFolder|FileSetAttrib|FileSetTime|FileWrite|FileWriteLine|Floor|FtpSetProxy|GUICreate|GUICtrlCreateAvi|GUICtrlCreateButton|GUICtrlCreateCheckbox|GUICtrlCreateCombo|GUICtrlCreateContextMenu|GUICtrlCreateDate|GUICtrlCreateDummy|GUICtrlCreateEdit|GUICtrlCreateGraphic|GUICtrlCreateGroup|GUICtrlCreateIcon|GUICtrlCreateInput|GUICtrlCreateLabel|GUICtrlCreateList|GUICtrlCreateListView|GUICtrlCreateListViewItem|GUICtrlCreateMenu|GUICtrlCreateMenuItem|GUICtrlCreateMonthCal|GUICtrlCreateObj|GUICtrlCreatePic|GUICtrlCreateProgress|GUICtrlCreateRadio|GUICtrlCreateSlider|GUICtrlCreateTab|GUICtrlCreateTabItem|GUICtrlCreateTreeView|GUICtrlCreateTreeViewItem|GUICtrlCreateUpdown|GUICtrlDelete|GUICtrlGetHandle|GUICtrlGetState|GUICtrlRead|GUICtrlRecvMsg|GUICtrlRegisterListViewSort|GUICtrlSendMsg|GUICtrlSendToDummy|GUICtrlSetBkColor|GUICtrlSetColor|GUICtrlSetCursor|GUICtrlSetData|GUICtrlSetFont|GUICtrlSetDefColor|GUICtrlSetDefBkColor|GUICtrlSetGraphic|GUICtrlSetImage|GUICtrlSetLimit|GUICtrlSetOnEvent|GUICtrlSetPos|GUICtrlSetResizing|GUICtrlSetState|GUICtrlSetStyle|GUICtrlSetTip|GUIDelete|GUIGetCursorInfo|GUIGetMsg|GUIGetStyle|GUIRegisterMsg|GUISetAccelerators()|GUISetBkColor|GUISetCoord|GUISetCursor|GUISetFont|GUISetHelp|GUISetIcon|GUISetOnEvent|GUISetState|GUISetStyle|GUIStartGroup|GUISwitch|Hex|HotKeySet|HttpSetProxy|HWnd|InetGet|InetGetSize|IniDelete|IniRead|IniReadSection|IniReadSectionNames|IniRenameSection|IniWrite|IniWriteSection|InputBox|Int|IsAdmin|IsArray|IsBinary|IsBool|IsDeclared|IsDllStruct|IsFloat|IsHWnd|IsInt|IsKeyword|IsNumber|IsObj|IsPtr|IsString|Log|MemGetStats|Mod|MouseClick|MouseClickDrag|MouseDown|MouseGetCursor|MouseGetPos|MouseMove|MouseUp|MouseWheel|MsgBox|Number|ObjCreate|ObjEvent|ObjGet|ObjName|Opt|Ping|PixelChecksum|PixelGetColor|PixelSearch|PluginClose|PluginOpen|ProcessClose|ProcessExists|ProcessGetStats|ProcessList|ProcessSetPriority|ProcessWait|ProcessWaitClose|ProgressOff|ProgressOn|ProgressSet|Ptr|Random|RegDelete|RegEnumKey|RegEnumVal|RegRead|RegWrite|Round|Run|RunAs|RunAsWait|RunWait|Send|SendKeepActive|SetError|SetExtended|ShellExecute|ShellExecuteWait|Shutdown|Sin|Sleep|SoundPlay|SoundSetWaveVolume|SplashImageOn|SplashOff|SplashTextOn|Sqrt|SRandom|StatusbarGetText|StderrRead|StdinWrite|StdioClose|StdoutRead|String|StringAddCR|StringCompare|StringFormat|StringInStr|StringIsAlNum|StringIsAlpha|StringIsASCII|StringIsDigit|StringIsFloat|StringIsInt|StringIsLower|StringIsSpace|StringIsUpper|StringIsXDigit|StringLeft|StringLen|StringLower|StringMid|StringRegExp|StringRegExpReplace|StringReplace|StringRight|StringSplit|StringStripCR|StringStripWS|StringToBinary|StringTrimLeft|StringTrimRight|StringUpper|Tan|TCPAccept|TCPCloseSocket|TCPConnect|TCPListen|TCPNameToIP|TCPRecv|TCPSend|TCPShutdown|TCPStartup|TimerDiff|TimerInit|ToolTip|TrayCreateItem|TrayCreateMenu|TrayGetMsg|TrayItemDelete|TrayItemGetHandle|TrayItemGetState|TrayItemGetText|TrayItemSetOnEvent|TrayItemSetState|TrayItemSetText|TraySetClick|TraySetIcon|TraySetOnEvent|TraySetPauseIcon|TraySetState|TraySetToolTip|TrayTip|UBound|UDPBind|UDPCloseSocket|UDPOpen|UDPRecv|UDPSend|UDPShutdown|UDPStartup|VarGetType|WinActivate|WinActive|WinClose|WinExists|WinFlash|WinGetCaretPos|WinGetClassList|WinGetClientSize|WinGetHandle|WinGetPos|WinGetProcess|WinGetState|WinGetText|WinGetTitle|WinKill|WinList|WinMenuSelectItem|WinMinimizeAll|WinMinimizeAllUndo|WinMove|WinSetOnTop|WinSetState|WinSetTitle|WinSetTrans|WinWait|WinWaitActive|WinWaitClose|WinWaitNotActive|' +
+ 'ArrayAdd|ArrayBinarySearch|ArrayConcatenate|ArrayDelete|ArrayDisplay|ArrayFindAll|ArrayInsert|ArrayMax|ArrayMaxIndex|ArrayMin|ArrayMinIndex|ArrayPop|ArrayPush|ArrayReverse|ArraySearch|ArraySort|ArraySwap|ArrayToClip|ArrayToString|ArrayTrim|ChooseColor|ChooseFont|ClipBoard_ChangeChain|ClipBoard_Close|ClipBoard_CountFormats|ClipBoard_Empty|ClipBoard_EnumFormats|ClipBoard_FormatStr|ClipBoard_GetData|ClipBoard_GetDataEx|ClipBoard_GetFormatName|ClipBoard_GetOpenWindow|ClipBoard_GetOwner|ClipBoard_GetPriorityFormat|ClipBoard_GetSequenceNumber|ClipBoard_GetViewer|ClipBoard_IsFormatAvailable|ClipBoard_Open|ClipBoard_RegisterFormat|ClipBoard_SetData|ClipBoard_SetDataEx|ClipBoard_SetViewer|ClipPutFile|ColorConvertHSLtoRGB|ColorConvertRGBtoHSL|ColorGetBlue|ColorGetGreen|ColorGetRed|Date_Time_CompareFileTime|Date_Time_DOSDateTimeToArray|Date_Time_DOSDateTimeToFileTime|Date_Time_DOSDateTimeToStr|Date_Time_DOSDateToArray|Date_Time_DOSDateToStr|Date_Time_DOSTimeToArray|Date_Time_DOSTimeToStr|Date_Time_EncodeFileTime|Date_Time_EncodeSystemTime|Date_Time_FileTimeToArray|Date_Time_FileTimeToDOSDateTime|Date_Time_FileTimeToLocalFileTime|Date_Time_FileTimeToStr|Date_Time_FileTimeToSystemTime|Date_Time_GetFileTime|Date_Time_GetLocalTime|Date_Time_GetSystemTime|Date_Time_GetSystemTimeAdjustment|Date_Time_GetSystemTimeAsFileTime|Date_Time_GetSystemTimes|Date_Time_GetTickCount|Date_Time_GetTimeZoneInformation|Date_Time_LocalFileTimeToFileTime|Date_Time_SetFileTime|Date_Time_SetLocalTime|Date_Time_SetSystemTime|Date_Time_SetSystemTimeAdjustment|Date_Time_SetTimeZoneInformation|Date_Time_SystemTimeToArray|Date_Time_SystemTimeToDateStr|Date_Time_SystemTimeToDateTimeStr|Date_Time_SystemTimeToFileTime|Date_Time_SystemTimeToTimeStr|Date_Time_SystemTimeToTzSpecificLocalTime|Date_Time_TzSpecificLocalTimeToSystemTime|DateAdd|DateDayOfWeek|DateDaysInMonth|DateDiff|DateIsLeapYear|DateIsValid|DateTimeFormat|DateTimeSplit|DateToDayOfWeek|DateToDayOfWeekISO|DateToDayValue|DateToMonth|DayValueToDate|DebugBugReportEnv|DebugOut|DebugSetup|Degree|EventLog__Backup|EventLog__Clear|EventLog__Close|EventLog__Count|EventLog__DeregisterSource|EventLog__Full|EventLog__Notify|EventLog__Oldest|EventLog__Open|EventLog__OpenBackup|EventLog__Read|EventLog__RegisterSource|EventLog__Report|FileCountLines|FileCreate|FileListToArray|FilePrint|FileReadToArray|FileWriteFromArray|FileWriteLog|FileWriteToLine|GDIPlus_ArrowCapCreate|GDIPlus_ArrowCapDispose|GDIPlus_ArrowCapGetFillState|GDIPlus_ArrowCapGetHeight|GDIPlus_ArrowCapGetMiddleInset|GDIPlus_ArrowCapGetWidth|GDIPlus_ArrowCapSetFillState|GDIPlus_ArrowCapSetHeight|GDIPlus_ArrowCapSetMiddleInset|GDIPlus_ArrowCapSetWidth|GDIPlus_BitmapCloneArea|GDIPlus_BitmapCreateFromFile|GDIPlus_BitmapCreateFromGraphics|GDIPlus_BitmapCreateFromHBITMAP|GDIPlus_BitmapCreateHBITMAPFromBitmap|GDIPlus_BitmapDispose|GDIPlus_BitmapLockBits|GDIPlus_BitmapUnlockBits|GDIPlus_BrushClone|GDIPlus_BrushCreateSolid|GDIPlus_BrushDispose|GDIPlus_BrushGetType|GDIPlus_CustomLineCapDispose|GDIPlus_Decoders|GDIPlus_DecodersGetCount|GDIPlus_DecodersGetSize|GDIPlus_Encoders|GDIPlus_EncodersGetCLSID|GDIPlus_EncodersGetCount|GDIPlus_EncodersGetParamList|GDIPlus_EncodersGetParamListSize|GDIPlus_EncodersGetSize|GDIPlus_FontCreate|GDIPlus_FontDispose|GDIPlus_FontFamilyCreate|GDIPlus_FontFamilyDispose|GDIPlus_GraphicsClear|GDIPlus_GraphicsCreateFromHDC|GDIPlus_GraphicsCreateFromHWND|GDIPlus_GraphicsDispose|GDIPlus_GraphicsDrawArc|GDIPlus_GraphicsDrawBezier|GDIPlus_GraphicsDrawClosedCurve|GDIPlus_GraphicsDrawCurve|GDIPlus_GraphicsDrawEllipse|GDIPlus_GraphicsDrawImage|GDIPlus_GraphicsDrawImageRect|GDIPlus_GraphicsDrawImageRectRect|GDIPlus_GraphicsDrawLine|GDIPlus_GraphicsDrawPie|GDIPlus_GraphicsDrawPolygon|GDIPlus_GraphicsDrawRect|GDIPlus_GraphicsDrawString|GDIPlus_GraphicsDrawStringEx|GDIPlus_GraphicsFillClosedCurve|GDIPlus_GraphicsFillEllipse|GDIPlus_GraphicsFillPie|GDIPlus_GraphicsFillRect|GDIPlus_GraphicsGetDC|GDIPlus_GraphicsGetSmoothingMode|GDIPlus_GraphicsMeasureString|GDIPlus_GraphicsReleaseDC|GDIPlus_GraphicsSetSmoothingMode|GDIPlus_GraphicsSetTransform|GDIPlus_ImageDispose|GDIPlus_ImageGetGraphicsContext|GDIPlus_ImageGetHeight|GDIPlus_ImageGetWidth|GDIPlus_ImageLoadFromFile|GDIPlus_ImageSaveToFile|GDIPlus_ImageSaveToFileEx|GDIPlus_MatrixCreate|GDIPlus_MatrixDispose|GDIPlus_MatrixRotate|GDIPlus_ParamAdd|GDIPlus_ParamInit|GDIPlus_PenCreate|GDIPlus_PenDispose|GDIPlus_PenGetAlignment|GDIPlus_PenGetColor|GDIPlus_PenGetCustomEndCap|GDIPlus_PenGetDashCap|GDIPlus_PenGetDashStyle|GDIPlus_PenGetEndCap|GDIPlus_PenGetWidth|GDIPlus_PenSetAlignment|GDIPlus_PenSetColor|GDIPlus_PenSetCustomEndCap|GDIPlus_PenSetDashCap|GDIPlus_PenSetDashStyle|GDIPlus_PenSetEndCap|GDIPlus_PenSetWidth|GDIPlus_RectFCreate|GDIPlus_Shutdown|GDIPlus_Startup|GDIPlus_StringFormatCreate|GDIPlus_StringFormatDispose|GetIP|GUICtrlAVI_Close|GUICtrlAVI_Create|GUICtrlAVI_Destroy|GUICtrlAVI_Open|GUICtrlAVI_OpenEx|GUICtrlAVI_Play|GUICtrlAVI_Seek|GUICtrlAVI_Show|GUICtrlAVI_Stop|GUICtrlButton_Click|GUICtrlButton_Create|GUICtrlButton_Destroy|GUICtrlButton_Enable|GUICtrlButton_GetCheck|GUICtrlButton_GetFocus|GUICtrlButton_GetIdealSize|GUICtrlButton_GetImage|GUICtrlButton_GetImageList|GUICtrlButton_GetState|GUICtrlButton_GetText|GUICtrlButton_GetTextMargin|GUICtrlButton_SetCheck|GUICtrlButton_SetFocus|GUICtrlButton_SetImage|GUICtrlButton_SetImageList|GUICtrlButton_SetSize|GUICtrlButton_SetState|GUICtrlButton_SetStyle|GUICtrlButton_SetText|GUICtrlButton_SetTextMargin|GUICtrlButton_Show|GUICtrlComboBox_AddDir|GUICtrlComboBox_AddString|GUICtrlComboBox_AutoComplete|GUICtrlComboBox_BeginUpdate|GUICtrlComboBox_Create|GUICtrlComboBox_DeleteString|GUICtrlComboBox_Destroy|GUICtrlComboBox_EndUpdate|GUICtrlComboBox_FindString|GUICtrlComboBox_FindStringExact|GUICtrlComboBox_GetComboBoxInfo|GUICtrlComboBox_GetCount|GUICtrlComboBox_GetCurSel|GUICtrlComboBox_GetDroppedControlRect|GUICtrlComboBox_GetDroppedControlRectEx|GUICtrlComboBox_GetDroppedState|GUICtrlComboBox_GetDroppedWidth|GUICtrlComboBox_GetEditSel|GUICtrlComboBox_GetEditText|GUICtrlComboBox_GetExtendedUI|GUICtrlComboBox_GetHorizontalExtent|GUICtrlComboBox_GetItemHeight|GUICtrlComboBox_GetLBText|GUICtrlComboBox_GetLBTextLen|GUICtrlComboBox_GetList|GUICtrlComboBox_GetListArray|GUICtrlComboBox_GetLocale|GUICtrlComboBox_GetLocaleCountry|GUICtrlComboBox_GetLocaleLang|GUICtrlComboBox_GetLocalePrimLang|GUICtrlComboBox_GetLocaleSubLang|GUICtrlComboBox_GetMinVisible|GUICtrlComboBox_GetTopIndex|GUICtrlComboBox_InitStorage|GUICtrlComboBox_InsertString|GUICtrlComboBox_LimitText|GUICtrlComboBox_ReplaceEditSel|GUICtrlComboBox_ResetContent|GUICtrlComboBox_SelectString|GUICtrlComboBox_SetCurSel|GUICtrlComboBox_SetDroppedWidth|GUICtrlComboBox_SetEditSel|GUICtrlComboBox_SetEditText|GUICtrlComboBox_SetExtendedUI|GUICtrlComboBox_SetHorizontalExtent|GUICtrlComboBox_SetItemHeight|GUICtrlComboBox_SetMinVisible|GUICtrlComboBox_SetTopIndex|GUICtrlComboBox_ShowDropDown|GUICtrlComboBoxEx_AddDir|GUICtrlComboBoxEx_AddString|GUICtrlComboBoxEx_BeginUpdate|GUICtrlComboBoxEx_Create|GUICtrlComboBoxEx_CreateSolidBitMap|GUICtrlComboBoxEx_DeleteString|GUICtrlComboBoxEx_Destroy|GUICtrlComboBoxEx_EndUpdate|GUICtrlComboBoxEx_FindStringExact|GUICtrlComboBoxEx_GetComboBoxInfo|GUICtrlComboBoxEx_GetComboControl|GUICtrlComboBoxEx_GetCount|GUICtrlComboBoxEx_GetCurSel|GUICtrlComboBoxEx_GetDroppedControlRect|GUICtrlComboBoxEx_GetDroppedControlRectEx|GUICtrlComboBoxEx_GetDroppedState|GUICtrlComboBoxEx_GetDroppedWidth|GUICtrlComboBoxEx_GetEditControl|GUICtrlComboBoxEx_GetEditSel|GUICtrlComboBoxEx_GetEditText|GUICtrlComboBoxEx_GetExtendedStyle|GUICtrlComboBoxEx_GetExtendedUI|GUICtrlComboBoxEx_GetImageList|GUICtrlComboBoxEx_GetItem|GUICtrlComboBoxEx_GetItemEx|GUICtrlComboBoxEx_GetItemHeight|GUICtrlComboBoxEx_GetItemImage|GUICtrlComboBoxEx_GetItemIndent|GUICtrlComboBoxEx_GetItemOverlayImage|GUICtrlComboBoxEx_GetItemParam|GUICtrlComboBoxEx_GetItemSelectedImage|GUICtrlComboBoxEx_GetItemText|GUICtrlComboBoxEx_GetItemTextLen|GUICtrlComboBoxEx_GetList|GUICtrlComboBoxEx_GetListArray|GUICtrlComboBoxEx_GetLocale|GUICtrlComboBoxEx_GetLocaleCountry|GUICtrlComboBoxEx_GetLocaleLang|GUICtrlComboBoxEx_GetLocalePrimLang|GUICtrlComboBoxEx_GetLocaleSubLang|GUICtrlComboBoxEx_GetMinVisible|GUICtrlComboBoxEx_GetTopIndex|GUICtrlComboBoxEx_InitStorage|GUICtrlComboBoxEx_InsertString|GUICtrlComboBoxEx_LimitText|GUICtrlComboBoxEx_ReplaceEditSel|GUICtrlComboBoxEx_ResetContent|GUICtrlComboBoxEx_SetCurSel|GUICtrlComboBoxEx_SetDroppedWidth|GUICtrlComboBoxEx_SetEditSel|GUICtrlComboBoxEx_SetEditText|GUICtrlComboBoxEx_SetExtendedStyle|GUICtrlComboBoxEx_SetExtendedUI|GUICtrlComboBoxEx_SetImageList|GUICtrlComboBoxEx_SetItem|GUICtrlComboBoxEx_SetItemEx|GUICtrlComboBoxEx_SetItemHeight|GUICtrlComboBoxEx_SetItemImage|GUICtrlComboBoxEx_SetItemIndent|GUICtrlComboBoxEx_SetItemOverlayImage|GUICtrlComboBoxEx_SetItemParam|GUICtrlComboBoxEx_SetItemSelectedImage|GUICtrlComboBoxEx_SetMinVisible|GUICtrlComboBoxEx_SetTopIndex|GUICtrlComboBoxEx_ShowDropDown|GUICtrlDTP_Create|GUICtrlDTP_Destroy|GUICtrlDTP_GetMCColor|GUICtrlDTP_GetMCFont|GUICtrlDTP_GetMonthCal|GUICtrlDTP_GetRange|GUICtrlDTP_GetRangeEx|GUICtrlDTP_GetSystemTime|GUICtrlDTP_GetSystemTimeEx|GUICtrlDTP_SetFormat|GUICtrlDTP_SetMCColor|GUICtrlDTP_SetMCFont|GUICtrlDTP_SetRange|GUICtrlDTP_SetRangeEx|GUICtrlDTP_SetSystemTime|GUICtrlDTP_SetSystemTimeEx|GUICtrlEdit_AppendText|GUICtrlEdit_BeginUpdate|GUICtrlEdit_CanUndo|GUICtrlEdit_CharFromPos|GUICtrlEdit_Create|GUICtrlEdit_Destroy|GUICtrlEdit_EmptyUndoBuffer|GUICtrlEdit_EndUpdate|GUICtrlEdit_Find|GUICtrlEdit_FmtLines|GUICtrlEdit_GetFirstVisibleLine|GUICtrlEdit_GetLimitText|GUICtrlEdit_GetLine|GUICtrlEdit_GetLineCount|GUICtrlEdit_GetMargins|GUICtrlEdit_GetModify|GUICtrlEdit_GetPasswordChar|GUICtrlEdit_GetRECT|GUICtrlEdit_GetRECTEx|GUICtrlEdit_GetSel|GUICtrlEdit_GetText|GUICtrlEdit_GetTextLen|GUICtrlEdit_HideBalloonTip|GUICtrlEdit_InsertText|GUICtrlEdit_LineFromChar|GUICtrlEdit_LineIndex|GUICtrlEdit_LineLength|GUICtrlEdit_LineScroll|GUICtrlEdit_PosFromChar|GUICtrlEdit_ReplaceSel|GUICtrlEdit_Scroll|GUICtrlEdit_SetLimitText|GUICtrlEdit_SetMargins|GUICtrlEdit_SetModify|GUICtrlEdit_SetPasswordChar|GUICtrlEdit_SetReadOnly|GUICtrlEdit_SetRECT|GUICtrlEdit_SetRECTEx|GUICtrlEdit_SetRECTNP|GUICtrlEdit_SetRectNPEx|GUICtrlEdit_SetSel|GUICtrlEdit_SetTabStops|GUICtrlEdit_SetText|GUICtrlEdit_ShowBalloonTip|GUICtrlEdit_Undo|GUICtrlHeader_AddItem|GUICtrlHeader_ClearFilter|GUICtrlHeader_ClearFilterAll|GUICtrlHeader_Create|GUICtrlHeader_CreateDragImage|GUICtrlHeader_DeleteItem|GUICtrlHeader_Destroy|GUICtrlHeader_EditFilter|GUICtrlHeader_GetBitmapMargin|GUICtrlHeader_GetImageList|GUICtrlHeader_GetItem|GUICtrlHeader_GetItemAlign|GUICtrlHeader_GetItemBitmap|GUICtrlHeader_GetItemCount|GUICtrlHeader_GetItemDisplay|GUICtrlHeader_GetItemFlags|GUICtrlHeader_GetItemFormat|GUICtrlHeader_GetItemImage|GUICtrlHeader_GetItemOrder|GUICtrlHeader_GetItemParam|GUICtrlHeader_GetItemRect|GUICtrlHeader_GetItemRectEx|GUICtrlHeader_GetItemText|GUICtrlHeader_GetItemWidth|GUICtrlHeader_GetOrderArray|GUICtrlHeader_GetUnicodeFormat|GUICtrlHeader_HitTest|GUICtrlHeader_InsertItem|GUICtrlHeader_Layout|GUICtrlHeader_OrderToIndex|GUICtrlHeader_SetBitmapMargin|GUICtrlHeader_SetFilterChangeTimeout|GUICtrlHeader_SetHotDivider|GUICtrlHeader_SetImageList|GUICtrlHeader_SetItem|GUICtrlHeader_SetItemAlign|GUICtrlHeader_SetItemBitmap|GUICtrlHeader_SetItemDisplay|GUICtrlHeader_SetItemFlags|GUICtrlHeader_SetItemFormat|GUICtrlHeader_SetItemImage|GUICtrlHeader_SetItemOrder|GUICtrlHeader_SetItemParam|GUICtrlHeader_SetItemText|GUICtrlHeader_SetItemWidth|GUICtrlHeader_SetOrderArray|GUICtrlHeader_SetUnicodeFormat|GUICtrlIpAddress_ClearAddress|GUICtrlIpAddress_Create|GUICtrlIpAddress_Destroy|GUICtrlIpAddress_Get|GUICtrlIpAddress_GetArray|GUICtrlIpAddress_GetEx|GUICtrlIpAddress_IsBlank|GUICtrlIpAddress_Set|GUICtrlIpAddress_SetArray|GUICtrlIpAddress_SetEx|GUICtrlIpAddress_SetFocus|GUICtrlIpAddress_SetFont|GUICtrlIpAddress_SetRange|GUICtrlIpAddress_ShowHide|GUICtrlListBox_AddFile|GUICtrlListBox_AddString|GUICtrlListBox_BeginUpdate|GUICtrlListBox_Create|GUICtrlListBox_DeleteString|GUICtrlListBox_Destroy|GUICtrlListBox_Dir|GUICtrlListBox_EndUpdate|GUICtrlListBox_FindInText|GUICtrlListBox_FindString|GUICtrlListBox_GetAnchorIndex|GUICtrlListBox_GetCaretIndex|GUICtrlListBox_GetCount|GUICtrlListBox_GetCurSel|GUICtrlListBox_GetHorizontalExtent|GUICtrlListBox_GetItemData|GUICtrlListBox_GetItemHeight|GUICtrlListBox_GetItemRect|GUICtrlListBox_GetItemRectEx|GUICtrlListBox_GetListBoxInfo|GUICtrlListBox_GetLocale|GUICtrlListBox_GetLocaleCountry|GUICtrlListBox_GetLocaleLang|GUICtrlListBox_GetLocalePrimLang|GUICtrlListBox_GetLocaleSubLang|GUICtrlListBox_GetSel|GUICtrlListBox_GetSelCount|GUICtrlListBox_GetSelItems|GUICtrlListBox_GetSelItemsText|GUICtrlListBox_GetText|GUICtrlListBox_GetTextLen|GUICtrlListBox_GetTopIndex|GUICtrlListBox_InitStorage|GUICtrlListBox_InsertString|GUICtrlListBox_ItemFromPoint|GUICtrlListBox_ReplaceString|GUICtrlListBox_ResetContent|GUICtrlListBox_SelectString|GUICtrlListBox_SelItemRange|GUICtrlListBox_SelItemRangeEx|GUICtrlListBox_SetAnchorIndex|GUICtrlListBox_SetCaretIndex|GUICtrlListBox_SetColumnWidth|GUICtrlListBox_SetCurSel|GUICtrlListBox_SetHorizontalExtent|GUICtrlListBox_SetItemData|GUICtrlListBox_SetItemHeight|GUICtrlListBox_SetLocale|GUICtrlListBox_SetSel|GUICtrlListBox_SetTabStops|GUICtrlListBox_SetTopIndex|GUICtrlListBox_Sort|GUICtrlListBox_SwapString|GUICtrlListBox_UpdateHScroll|GUICtrlListView_AddArray|GUICtrlListView_AddColumn|GUICtrlListView_AddItem|GUICtrlListView_AddSubItem|GUICtrlListView_ApproximateViewHeight|GUICtrlListView_ApproximateViewRect|GUICtrlListView_ApproximateViewWidth|GUICtrlListView_Arrange|GUICtrlListView_BeginUpdate|GUICtrlListView_CancelEditLabel|GUICtrlListView_ClickItem|GUICtrlListView_CopyItems|GUICtrlListView_Create|GUICtrlListView_CreateDragImage|GUICtrlListView_CreateSolidBitMap|GUICtrlListView_DeleteAllItems|GUICtrlListView_DeleteColumn|GUICtrlListView_DeleteItem|GUICtrlListView_DeleteItemsSelected|GUICtrlListView_Destroy|GUICtrlListView_DrawDragImage|GUICtrlListView_EditLabel|GUICtrlListView_EnableGroupView|GUICtrlListView_EndUpdate|GUICtrlListView_EnsureVisible|GUICtrlListView_FindInText|GUICtrlListView_FindItem|GUICtrlListView_FindNearest|GUICtrlListView_FindParam|GUICtrlListView_FindText|GUICtrlListView_GetBkColor|GUICtrlListView_GetBkImage|GUICtrlListView_GetCallbackMask|GUICtrlListView_GetColumn|GUICtrlListView_GetColumnCount|GUICtrlListView_GetColumnOrder|GUICtrlListView_GetColumnOrderArray|GUICtrlListView_GetColumnWidth|GUICtrlListView_GetCounterPage|GUICtrlListView_GetEditControl|GUICtrlListView_GetExtendedListViewStyle|GUICtrlListView_GetGroupInfo|GUICtrlListView_GetGroupViewEnabled|GUICtrlListView_GetHeader|GUICtrlListView_GetHotCursor|GUICtrlListView_GetHotItem|GUICtrlListView_GetHoverTime|GUICtrlListView_GetImageList|GUICtrlListView_GetISearchString|GUICtrlListView_GetItem|GUICtrlListView_GetItemChecked|GUICtrlListView_GetItemCount|GUICtrlListView_GetItemCut|GUICtrlListView_GetItemDropHilited|GUICtrlListView_GetItemEx|GUICtrlListView_GetItemFocused|GUICtrlListView_GetItemGroupID|GUICtrlListView_GetItemImage|GUICtrlListView_GetItemIndent|GUICtrlListView_GetItemParam|GUICtrlListView_GetItemPosition|GUICtrlListView_GetItemPositionX|GUICtrlListView_GetItemPositionY|GUICtrlListView_GetItemRect|GUICtrlListView_GetItemRectEx|GUICtrlListView_GetItemSelected|GUICtrlListView_GetItemSpacing|GUICtrlListView_GetItemSpacingX|GUICtrlListView_GetItemSpacingY|GUICtrlListView_GetItemState|GUICtrlListView_GetItemStateImage|GUICtrlListView_GetItemText|GUICtrlListView_GetItemTextArray|GUICtrlListView_GetItemTextString|GUICtrlListView_GetNextItem|GUICtrlListView_GetNumberOfWorkAreas|GUICtrlListView_GetOrigin|GUICtrlListView_GetOriginX|GUICtrlListView_GetOriginY|GUICtrlListView_GetOutlineColor|GUICtrlListView_GetSelectedColumn|GUICtrlListView_GetSelectedCount|GUICtrlListView_GetSelectedIndices|GUICtrlListView_GetSelectionMark|GUICtrlListView_GetStringWidth|GUICtrlListView_GetSubItemRect|GUICtrlListView_GetTextBkColor|GUICtrlListView_GetTextColor|GUICtrlListView_GetToolTips|GUICtrlListView_GetTopIndex|GUICtrlListView_GetUnicodeFormat|GUICtrlListView_GetView|GUICtrlListView_GetViewDetails|GUICtrlListView_GetViewLarge|GUICtrlListView_GetViewList|GUICtrlListView_GetViewRect|GUICtrlListView_GetViewSmall|GUICtrlListView_GetViewTile|GUICtrlListView_HideColumn|GUICtrlListView_HitTest|GUICtrlListView_InsertColumn|GUICtrlListView_InsertGroup|GUICtrlListView_InsertItem|GUICtrlListView_JustifyColumn|GUICtrlListView_MapIDToIndex|GUICtrlListView_MapIndexToID|GUICtrlListView_RedrawItems|GUICtrlListView_RegisterSortCallBack|GUICtrlListView_RemoveAllGroups|GUICtrlListView_RemoveGroup|GUICtrlListView_Scroll|GUICtrlListView_SetBkColor|GUICtrlListView_SetBkImage|GUICtrlListView_SetCallBackMask|GUICtrlListView_SetColumn|GUICtrlListView_SetColumnOrder|GUICtrlListView_SetColumnOrderArray|GUICtrlListView_SetColumnWidth|GUICtrlListView_SetExtendedListViewStyle|GUICtrlListView_SetGroupInfo|GUICtrlListView_SetHotItem|GUICtrlListView_SetHoverTime|GUICtrlListView_SetIconSpacing|GUICtrlListView_SetImageList|GUICtrlListView_SetItem|GUICtrlListView_SetItemChecked|GUICtrlListView_SetItemCount|GUICtrlListView_SetItemCut|GUICtrlListView_SetItemDropHilited|GUICtrlListView_SetItemEx|GUICtrlListView_SetItemFocused|GUICtrlListView_SetItemGroupID|GUICtrlListView_SetItemImage|GUICtrlListView_SetItemIndent|GUICtrlListView_SetItemParam|GUICtrlListView_SetItemPosition|GUICtrlListView_SetItemPosition32|GUICtrlListView_SetItemSelected|GUICtrlListView_SetItemState|GUICtrlListView_SetItemStateImage|GUICtrlListView_SetItemText|GUICtrlListView_SetOutlineColor|GUICtrlListView_SetSelectedColumn|GUICtrlListView_SetSelectionMark|GUICtrlListView_SetTextBkColor|GUICtrlListView_SetTextColor|GUICtrlListView_SetToolTips|GUICtrlListView_SetUnicodeFormat|GUICtrlListView_SetView|GUICtrlListView_SetWorkAreas|GUICtrlListView_SimpleSort|GUICtrlListView_SortItems|GUICtrlListView_SubItemHitTest|GUICtrlListView_UnRegisterSortCallBack|GUICtrlMenu_AddMenuItem|GUICtrlMenu_AppendMenu|GUICtrlMenu_CheckMenuItem|GUICtrlMenu_CheckRadioItem|GUICtrlMenu_CreateMenu|GUICtrlMenu_CreatePopup|GUICtrlMenu_DeleteMenu|GUICtrlMenu_DestroyMenu|GUICtrlMenu_DrawMenuBar|GUICtrlMenu_EnableMenuItem|GUICtrlMenu_FindItem|GUICtrlMenu_FindParent|GUICtrlMenu_GetItemBmp|GUICtrlMenu_GetItemBmpChecked|GUICtrlMenu_GetItemBmpUnchecked|GUICtrlMenu_GetItemChecked|GUICtrlMenu_GetItemCount|GUICtrlMenu_GetItemData|GUICtrlMenu_GetItemDefault|GUICtrlMenu_GetItemDisabled|GUICtrlMenu_GetItemEnabled|GUICtrlMenu_GetItemGrayed|GUICtrlMenu_GetItemHighlighted|GUICtrlMenu_GetItemID|GUICtrlMenu_GetItemInfo|GUICtrlMenu_GetItemRect|GUICtrlMenu_GetItemRectEx|GUICtrlMenu_GetItemState|GUICtrlMenu_GetItemStateEx|GUICtrlMenu_GetItemSubMenu|GUICtrlMenu_GetItemText|GUICtrlMenu_GetItemType|GUICtrlMenu_GetMenu|GUICtrlMenu_GetMenuBackground|GUICtrlMenu_GetMenuBarInfo|GUICtrlMenu_GetMenuContextHelpID|GUICtrlMenu_GetMenuData|GUICtrlMenu_GetMenuDefaultItem|GUICtrlMenu_GetMenuHeight|GUICtrlMenu_GetMenuInfo|GUICtrlMenu_GetMenuStyle|GUICtrlMenu_GetSystemMenu|GUICtrlMenu_InsertMenuItem|GUICtrlMenu_InsertMenuItemEx|GUICtrlMenu_IsMenu|GUICtrlMenu_LoadMenu|GUICtrlMenu_MapAccelerator|GUICtrlMenu_MenuItemFromPoint|GUICtrlMenu_RemoveMenu|GUICtrlMenu_SetItemBitmaps|GUICtrlMenu_SetItemBmp|GUICtrlMenu_SetItemBmpChecked|GUICtrlMenu_SetItemBmpUnchecked|GUICtrlMenu_SetItemChecked|GUICtrlMenu_SetItemData|GUICtrlMenu_SetItemDefault|GUICtrlMenu_SetItemDisabled|GUICtrlMenu_SetItemEnabled|GUICtrlMenu_SetItemGrayed|GUICtrlMenu_SetItemHighlighted|GUICtrlMenu_SetItemID|GUICtrlMenu_SetItemInfo|GUICtrlMenu_SetItemState|GUICtrlMenu_SetItemSubMenu|GUICtrlMenu_SetItemText|GUICtrlMenu_SetItemType|GUICtrlMenu_SetMenu|GUICtrlMenu_SetMenuBackground|GUICtrlMenu_SetMenuContextHelpID|GUICtrlMenu_SetMenuData|GUICtrlMenu_SetMenuDefaultItem|GUICtrlMenu_SetMenuHeight|GUICtrlMenu_SetMenuInfo|GUICtrlMenu_SetMenuStyle|GUICtrlMenu_TrackPopupMenu|GUICtrlMonthCal_Create|GUICtrlMonthCal_Destroy|GUICtrlMonthCal_GetColor|GUICtrlMonthCal_GetColorArray|GUICtrlMonthCal_GetCurSel|GUICtrlMonthCal_GetCurSelStr|GUICtrlMonthCal_GetFirstDOW|GUICtrlMonthCal_GetFirstDOWStr|GUICtrlMonthCal_GetMaxSelCount|GUICtrlMonthCal_GetMaxTodayWidth|GUICtrlMonthCal_GetMinReqHeight|GUICtrlMonthCal_GetMinReqRect|GUICtrlMonthCal_GetMinReqRectArray|GUICtrlMonthCal_GetMinReqWidth|GUICtrlMonthCal_GetMonthDelta|GUICtrlMonthCal_GetMonthRange|GUICtrlMonthCal_GetMonthRangeMax|GUICtrlMonthCal_GetMonthRangeMaxStr|GUICtrlMonthCal_GetMonthRangeMin|GUICtrlMonthCal_GetMonthRangeMinStr|GUICtrlMonthCal_GetMonthRangeSpan|GUICtrlMonthCal_GetRange|GUICtrlMonthCal_GetRangeMax|GUICtrlMonthCal_GetRangeMaxStr|GUICtrlMonthCal_GetRangeMin|GUICtrlMonthCal_GetRangeMinStr|GUICtrlMonthCal_GetSelRange|GUICtrlMonthCal_GetSelRangeMax|GUICtrlMonthCal_GetSelRangeMaxStr|GUICtrlMonthCal_GetSelRangeMin|GUICtrlMonthCal_GetSelRangeMinStr|GUICtrlMonthCal_GetToday|GUICtrlMonthCal_GetTodayStr|GUICtrlMonthCal_GetUnicodeFormat|GUICtrlMonthCal_HitTest|GUICtrlMonthCal_SetColor|GUICtrlMonthCal_SetCurSel|GUICtrlMonthCal_SetDayState|GUICtrlMonthCal_SetFirstDOW|GUICtrlMonthCal_SetMaxSelCount|GUICtrlMonthCal_SetMonthDelta|GUICtrlMonthCal_SetRange|GUICtrlMonthCal_SetSelRange|GUICtrlMonthCal_SetToday|GUICtrlMonthCal_SetUnicodeFormat|GUICtrlRebar_AddBand|GUICtrlRebar_AddToolBarBand|GUICtrlRebar_BeginDrag|GUICtrlRebar_Create|GUICtrlRebar_DeleteBand|GUICtrlRebar_Destroy|GUICtrlRebar_DragMove|GUICtrlRebar_EndDrag|GUICtrlRebar_GetBandBackColor|GUICtrlRebar_GetBandBorders|GUICtrlRebar_GetBandBordersEx|GUICtrlRebar_GetBandChildHandle|GUICtrlRebar_GetBandChildSize|GUICtrlRebar_GetBandCount|GUICtrlRebar_GetBandForeColor|GUICtrlRebar_GetBandHeaderSize|GUICtrlRebar_GetBandID|GUICtrlRebar_GetBandIdealSize|GUICtrlRebar_GetBandLength|GUICtrlRebar_GetBandLParam|GUICtrlRebar_GetBandMargins|GUICtrlRebar_GetBandMarginsEx|GUICtrlRebar_GetBandRect|GUICtrlRebar_GetBandRectEx|GUICtrlRebar_GetBandStyle|GUICtrlRebar_GetBandStyleBreak|GUICtrlRebar_GetBandStyleChildEdge|GUICtrlRebar_GetBandStyleFixedBMP|GUICtrlRebar_GetBandStyleFixedSize|GUICtrlRebar_GetBandStyleGripperAlways|GUICtrlRebar_GetBandStyleHidden|GUICtrlRebar_GetBandStyleHideTitle|GUICtrlRebar_GetBandStyleNoGripper|GUICtrlRebar_GetBandStyleTopAlign|GUICtrlRebar_GetBandStyleUseChevron|GUICtrlRebar_GetBandStyleVariableHeight|GUICtrlRebar_GetBandText|GUICtrlRebar_GetBarHeight|GUICtrlRebar_GetBKColor|GUICtrlRebar_GetColorScheme|GUICtrlRebar_GetRowCount|GUICtrlRebar_GetRowHeight|GUICtrlRebar_GetTextColor|GUICtrlRebar_GetToolTips|GUICtrlRebar_GetUnicodeFormat|GUICtrlRebar_HitTest|GUICtrlRebar_IDToIndex|GUICtrlRebar_MaximizeBand|GUICtrlRebar_MinimizeBand|GUICtrlRebar_MoveBand|GUICtrlRebar_SetBandBackColor|GUICtrlRebar_SetBandForeColor|GUICtrlRebar_SetBandHeaderSize|GUICtrlRebar_SetBandID|GUICtrlRebar_SetBandIdealSize|GUICtrlRebar_SetBandLength|GUICtrlRebar_SetBandLParam|GUICtrlRebar_SetBandStyle|GUICtrlRebar_SetBandStyleBreak|GUICtrlRebar_SetBandStyleChildEdge|GUICtrlRebar_SetBandStyleFixedBMP|GUICtrlRebar_SetBandStyleFixedSize|GUICtrlRebar_SetBandStyleGripperAlways|GUICtrlRebar_SetBandStyleHidden|GUICtrlRebar_SetBandStyleHideTitle|GUICtrlRebar_SetBandStyleNoGripper|GUICtrlRebar_SetBandStyleTopAlign|GUICtrlRebar_SetBandStyleUseChevron|GUICtrlRebar_SetBandStyleVariableHeight|GUICtrlRebar_SetBandText|GUICtrlRebar_SetBKColor|GUICtrlRebar_SetColorScheme|GUICtrlRebar_SetTextColor|GUICtrlRebar_SetToolTips|GUICtrlRebar_SetUnicodeFormat|GUICtrlRebar_ShowBand|GUICtrlSlider_ClearSel|GUICtrlSlider_ClearTics|GUICtrlSlider_Create|GUICtrlSlider_Destroy|GUICtrlSlider_GetBuddy|GUICtrlSlider_GetChannelRect|GUICtrlSlider_GetLineSize|GUICtrlSlider_GetNumTics|GUICtrlSlider_GetPageSize|GUICtrlSlider_GetPos|GUICtrlSlider_GetPTics|GUICtrlSlider_GetRange|GUICtrlSlider_GetRangeMax|GUICtrlSlider_GetRangeMin|GUICtrlSlider_GetSel|GUICtrlSlider_GetSelEnd|GUICtrlSlider_GetSelStart|GUICtrlSlider_GetThumbLength|GUICtrlSlider_GetThumbRect|GUICtrlSlider_GetThumbRectEx|GUICtrlSlider_GetTic|GUICtrlSlider_GetTicPos|GUICtrlSlider_GetToolTips|GUICtrlSlider_GetUnicodeFormat|GUICtrlSlider_SetBuddy|GUICtrlSlider_SetLineSize|GUICtrlSlider_SetPageSize|GUICtrlSlider_SetPos|GUICtrlSlider_SetRange|GUICtrlSlider_SetRangeMax|GUICtrlSlider_SetRangeMin|GUICtrlSlider_SetSel|GUICtrlSlider_SetSelEnd|GUICtrlSlider_SetSelStart|GUICtrlSlider_SetThumbLength|GUICtrlSlider_SetTic|GUICtrlSlider_SetTicFreq|GUICtrlSlider_SetTipSide|GUICtrlSlider_SetToolTips|GUICtrlSlider_SetUnicodeFormat|GUICtrlStatusBar_Create|GUICtrlStatusBar_Destroy|GUICtrlStatusBar_EmbedControl|GUICtrlStatusBar_GetBorders|GUICtrlStatusBar_GetBordersHorz|GUICtrlStatusBar_GetBordersRect|GUICtrlStatusBar_GetBordersVert|GUICtrlStatusBar_GetCount|GUICtrlStatusBar_GetHeight|GUICtrlStatusBar_GetIcon|GUICtrlStatusBar_GetParts|GUICtrlStatusBar_GetRect|GUICtrlStatusBar_GetRectEx|GUICtrlStatusBar_GetText|GUICtrlStatusBar_GetTextFlags|GUICtrlStatusBar_GetTextLength|GUICtrlStatusBar_GetTextLengthEx|GUICtrlStatusBar_GetTipText|GUICtrlStatusBar_GetUnicodeFormat|GUICtrlStatusBar_GetWidth|GUICtrlStatusBar_IsSimple|GUICtrlStatusBar_Resize|GUICtrlStatusBar_SetBkColor|GUICtrlStatusBar_SetIcon|GUICtrlStatusBar_SetMinHeight|GUICtrlStatusBar_SetParts|GUICtrlStatusBar_SetSimple|GUICtrlStatusBar_SetText|GUICtrlStatusBar_SetTipText|GUICtrlStatusBar_SetUnicodeFormat|GUICtrlStatusBar_ShowHide|GUICtrlTab_Create|GUICtrlTab_DeleteAllItems|GUICtrlTab_DeleteItem|GUICtrlTab_DeselectAll|GUICtrlTab_Destroy|GUICtrlTab_FindTab|GUICtrlTab_GetCurFocus|GUICtrlTab_GetCurSel|GUICtrlTab_GetDisplayRect|GUICtrlTab_GetDisplayRectEx|GUICtrlTab_GetExtendedStyle|GUICtrlTab_GetImageList|GUICtrlTab_GetItem|GUICtrlTab_GetItemCount|GUICtrlTab_GetItemImage|GUICtrlTab_GetItemParam|GUICtrlTab_GetItemRect|GUICtrlTab_GetItemRectEx|GUICtrlTab_GetItemState|GUICtrlTab_GetItemText|GUICtrlTab_GetRowCount|GUICtrlTab_GetToolTips|GUICtrlTab_GetUnicodeFormat|GUICtrlTab_HighlightItem|GUICtrlTab_HitTest|GUICtrlTab_InsertItem|GUICtrlTab_RemoveImage|GUICtrlTab_SetCurFocus|GUICtrlTab_SetCurSel|GUICtrlTab_SetExtendedStyle|GUICtrlTab_SetImageList|GUICtrlTab_SetItem|GUICtrlTab_SetItemImage|GUICtrlTab_SetItemParam|GUICtrlTab_SetItemSize|GUICtrlTab_SetItemState|GUICtrlTab_SetItemText|GUICtrlTab_SetMinTabWidth|GUICtrlTab_SetPadding|GUICtrlTab_SetToolTips|GUICtrlTab_SetUnicodeFormat|GUICtrlToolbar_AddBitmap|GUICtrlToolbar_AddButton|GUICtrlToolbar_AddButtonSep|GUICtrlToolbar_AddString|GUICtrlToolbar_ButtonCount|GUICtrlToolbar_CheckButton|GUICtrlToolbar_ClickAccel|GUICtrlToolbar_ClickButton|GUICtrlToolbar_ClickIndex|GUICtrlToolbar_CommandToIndex|GUICtrlToolbar_Create|GUICtrlToolbar_Customize|GUICtrlToolbar_DeleteButton|GUICtrlToolbar_Destroy|GUICtrlToolbar_EnableButton|GUICtrlToolbar_FindToolbar|GUICtrlToolbar_GetAnchorHighlight|GUICtrlToolbar_GetBitmapFlags|GUICtrlToolbar_GetButtonBitmap|GUICtrlToolbar_GetButtonInfo|GUICtrlToolbar_GetButtonInfoEx|GUICtrlToolbar_GetButtonParam|GUICtrlToolbar_GetButtonRect|GUICtrlToolbar_GetButtonRectEx|GUICtrlToolbar_GetButtonSize|GUICtrlToolbar_GetButtonState|GUICtrlToolbar_GetButtonStyle|GUICtrlToolbar_GetButtonText|GUICtrlToolbar_GetColorScheme|GUICtrlToolbar_GetDisabledImageList|GUICtrlToolbar_GetExtendedStyle|GUICtrlToolbar_GetHotImageList|GUICtrlToolbar_GetHotItem|GUICtrlToolbar_GetImageList|GUICtrlToolbar_GetInsertMark|GUICtrlToolbar_GetInsertMarkColor|GUICtrlToolbar_GetMaxSize|GUICtrlToolbar_GetMetrics|GUICtrlToolbar_GetPadding|GUICtrlToolbar_GetRows|GUICtrlToolbar_GetString|GUICtrlToolbar_GetStyle|GUICtrlToolbar_GetStyleAltDrag|GUICtrlToolbar_GetStyleCustomErase|GUICtrlToolbar_GetStyleFlat|GUICtrlToolbar_GetStyleList|GUICtrlToolbar_GetStyleRegisterDrop|GUICtrlToolbar_GetStyleToolTips|GUICtrlToolbar_GetStyleTransparent|GUICtrlToolbar_GetStyleWrapable|GUICtrlToolbar_GetTextRows|GUICtrlToolbar_GetToolTips|GUICtrlToolbar_GetUnicodeFormat|GUICtrlToolbar_HideButton|GUICtrlToolbar_HighlightButton|GUICtrlToolbar_HitTest|GUICtrlToolbar_IndexToCommand|GUICtrlToolbar_InsertButton|GUICtrlToolbar_InsertMarkHitTest|GUICtrlToolbar_IsButtonChecked|GUICtrlToolbar_IsButtonEnabled|GUICtrlToolbar_IsButtonHidden|GUICtrlToolbar_IsButtonHighlighted|GUICtrlToolbar_IsButtonIndeterminate|GUICtrlToolbar_IsButtonPressed|GUICtrlToolbar_LoadBitmap|GUICtrlToolbar_LoadImages|GUICtrlToolbar_MapAccelerator|GUICtrlToolbar_MoveButton|GUICtrlToolbar_PressButton|GUICtrlToolbar_SetAnchorHighlight|GUICtrlToolbar_SetBitmapSize|GUICtrlToolbar_SetButtonBitMap|GUICtrlToolbar_SetButtonInfo|GUICtrlToolbar_SetButtonInfoEx|GUICtrlToolbar_SetButtonParam|GUICtrlToolbar_SetButtonSize|GUICtrlToolbar_SetButtonState|GUICtrlToolbar_SetButtonStyle|GUICtrlToolbar_SetButtonText|GUICtrlToolbar_SetButtonWidth|GUICtrlToolbar_SetCmdID|GUICtrlToolbar_SetColorScheme|GUICtrlToolbar_SetDisabledImageList|GUICtrlToolbar_SetDrawTextFlags|GUICtrlToolbar_SetExtendedStyle|GUICtrlToolbar_SetHotImageList|GUICtrlToolbar_SetHotItem|GUICtrlToolbar_SetImageList|GUICtrlToolbar_SetIndent|GUICtrlToolbar_SetIndeterminate|GUICtrlToolbar_SetInsertMark|GUICtrlToolbar_SetInsertMarkColor|GUICtrlToolbar_SetMaxTextRows|GUICtrlToolbar_SetMetrics|GUICtrlToolbar_SetPadding|GUICtrlToolbar_SetParent|GUICtrlToolbar_SetRows|GUICtrlToolbar_SetStyle|GUICtrlToolbar_SetStyleAltDrag|GUICtrlToolbar_SetStyleCustomErase|GUICtrlToolbar_SetStyleFlat|GUICtrlToolbar_SetStyleList|GUICtrlToolbar_SetStyleRegisterDrop|GUICtrlToolbar_SetStyleToolTips|GUICtrlToolbar_SetStyleTransparent|GUICtrlToolbar_SetStyleWrapable|GUICtrlToolbar_SetToolTips|GUICtrlToolbar_SetUnicodeFormat|GUICtrlToolbar_SetWindowTheme|GUICtrlTreeView_Add|GUICtrlTreeView_AddChild|GUICtrlTreeView_AddChildFirst|GUICtrlTreeView_AddFirst|GUICtrlTreeView_BeginUpdate|GUICtrlTreeView_ClickItem|GUICtrlTreeView_Create|GUICtrlTreeView_CreateDragImage|GUICtrlTreeView_CreateSolidBitMap|GUICtrlTreeView_Delete|GUICtrlTreeView_DeleteAll|GUICtrlTreeView_DeleteChildren|GUICtrlTreeView_Destroy|GUICtrlTreeView_DisplayRect|GUICtrlTreeView_DisplayRectEx|GUICtrlTreeView_EditText|GUICtrlTreeView_EndEdit|GUICtrlTreeView_EndUpdate|GUICtrlTreeView_EnsureVisible|GUICtrlTreeView_Expand|GUICtrlTreeView_ExpandedOnce|GUICtrlTreeView_FindItem|GUICtrlTreeView_FindItemEx|GUICtrlTreeView_GetBkColor|GUICtrlTreeView_GetBold|GUICtrlTreeView_GetChecked|GUICtrlTreeView_GetChildCount|GUICtrlTreeView_GetChildren|GUICtrlTreeView_GetCount|GUICtrlTreeView_GetCut|GUICtrlTreeView_GetDropTarget|GUICtrlTreeView_GetEditControl|GUICtrlTreeView_GetExpanded|GUICtrlTreeView_GetFirstChild|GUICtrlTreeView_GetFirstItem|GUICtrlTreeView_GetFirstVisible|GUICtrlTreeView_GetFocused|GUICtrlTreeView_GetHeight|GUICtrlTreeView_GetImageIndex|GUICtrlTreeView_GetImageListIconHandle|GUICtrlTreeView_GetIndent|GUICtrlTreeView_GetInsertMarkColor|GUICtrlTreeView_GetISearchString|GUICtrlTreeView_GetItemByIndex|GUICtrlTreeView_GetItemHandle|GUICtrlTreeView_GetItemParam|GUICtrlTreeView_GetLastChild|GUICtrlTreeView_GetLineColor|GUICtrlTreeView_GetNext|GUICtrlTreeView_GetNextChild|GUICtrlTreeView_GetNextSibling|GUICtrlTreeView_GetNextVisible|GUICtrlTreeView_GetNormalImageList|GUICtrlTreeView_GetParentHandle|GUICtrlTreeView_GetParentParam|GUICtrlTreeView_GetPrev|GUICtrlTreeView_GetPrevChild|GUICtrlTreeView_GetPrevSibling|GUICtrlTreeView_GetPrevVisible|GUICtrlTreeView_GetScrollTime|GUICtrlTreeView_GetSelected|GUICtrlTreeView_GetSelectedImageIndex|GUICtrlTreeView_GetSelection|GUICtrlTreeView_GetSiblingCount|GUICtrlTreeView_GetState|GUICtrlTreeView_GetStateImageIndex|GUICtrlTreeView_GetStateImageList|GUICtrlTreeView_GetText|GUICtrlTreeView_GetTextColor|GUICtrlTreeView_GetToolTips|GUICtrlTreeView_GetTree|GUICtrlTreeView_GetUnicodeFormat|GUICtrlTreeView_GetVisible|GUICtrlTreeView_GetVisibleCount|GUICtrlTreeView_HitTest|GUICtrlTreeView_HitTestEx|GUICtrlTreeView_HitTestItem|GUICtrlTreeView_Index|GUICtrlTreeView_InsertItem|GUICtrlTreeView_IsFirstItem|GUICtrlTreeView_IsParent|GUICtrlTreeView_Level|GUICtrlTreeView_SelectItem|GUICtrlTreeView_SelectItemByIndex|GUICtrlTreeView_SetBkColor|GUICtrlTreeView_SetBold|GUICtrlTreeView_SetChecked|GUICtrlTreeView_SetCheckedByIndex|GUICtrlTreeView_SetChildren|GUICtrlTreeView_SetCut|GUICtrlTreeView_SetDropTarget|GUICtrlTreeView_SetFocused|GUICtrlTreeView_SetHeight|GUICtrlTreeView_SetIcon|GUICtrlTreeView_SetImageIndex|GUICtrlTreeView_SetIndent|GUICtrlTreeView_SetInsertMark|GUICtrlTreeView_SetInsertMarkColor|GUICtrlTreeView_SetItemHeight|GUICtrlTreeView_SetItemParam|GUICtrlTreeView_SetLineColor|GUICtrlTreeView_SetNormalImageList|GUICtrlTreeView_SetScrollTime|GUICtrlTreeView_SetSelected|GUICtrlTreeView_SetSelectedImageIndex|GUICtrlTreeView_SetState|GUICtrlTreeView_SetStateImageIndex|GUICtrlTreeView_SetStateImageList|GUICtrlTreeView_SetText|GUICtrlTreeView_SetTextColor|GUICtrlTreeView_SetToolTips|GUICtrlTreeView_SetUnicodeFormat|GUICtrlTreeView_Sort|GUIImageList_Add|GUIImageList_AddBitmap|GUIImageList_AddIcon|GUIImageList_AddMasked|GUIImageList_BeginDrag|GUIImageList_Copy|GUIImageList_Create|GUIImageList_Destroy|GUIImageList_DestroyIcon|GUIImageList_DragEnter|GUIImageList_DragLeave|GUIImageList_DragMove|GUIImageList_Draw|GUIImageList_DrawEx|GUIImageList_Duplicate|GUIImageList_EndDrag|GUIImageList_GetBkColor|GUIImageList_GetIcon|GUIImageList_GetIconHeight|GUIImageList_GetIconSize|GUIImageList_GetIconSizeEx|GUIImageList_GetIconWidth|GUIImageList_GetImageCount|GUIImageList_GetImageInfoEx|GUIImageList_Remove|GUIImageList_ReplaceIcon|GUIImageList_SetBkColor|GUIImageList_SetIconSize|GUIImageList_SetImageCount|GUIImageList_Swap|GUIScrollBars_EnableScrollBar|GUIScrollBars_GetScrollBarInfoEx|GUIScrollBars_GetScrollBarRect|GUIScrollBars_GetScrollBarRGState|GUIScrollBars_GetScrollBarXYLineButton|GUIScrollBars_GetScrollBarXYThumbBottom|GUIScrollBars_GetScrollBarXYThumbTop|GUIScrollBars_GetScrollInfo|GUIScrollBars_GetScrollInfoEx|GUIScrollBars_GetScrollInfoMax|GUIScrollBars_GetScrollInfoMin|GUIScrollBars_GetScrollInfoPage|GUIScrollBars_GetScrollInfoPos|GUIScrollBars_GetScrollInfoTrackPos|GUIScrollBars_GetScrollPos|GUIScrollBars_GetScrollRange|GUIScrollBars_Init|GUIScrollBars_ScrollWindow|GUIScrollBars_SetScrollInfo|GUIScrollBars_SetScrollInfoMax|GUIScrollBars_SetScrollInfoMin|GUIScrollBars_SetScrollInfoPage|GUIScrollBars_SetScrollInfoPos|GUIScrollBars_SetScrollRange|GUIScrollBars_ShowScrollBar|GUIToolTip_Activate|GUIToolTip_AddTool|GUIToolTip_AdjustRect|GUIToolTip_BitsToTTF|GUIToolTip_Create|GUIToolTip_DelTool|GUIToolTip_Destroy|GUIToolTip_EnumTools|GUIToolTip_GetBubbleHeight|GUIToolTip_GetBubbleSize|GUIToolTip_GetBubbleWidth|GUIToolTip_GetCurrentTool|GUIToolTip_GetDelayTime|GUIToolTip_GetMargin|GUIToolTip_GetMarginEx|GUIToolTip_GetMaxTipWidth|GUIToolTip_GetText|GUIToolTip_GetTipBkColor|GUIToolTip_GetTipTextColor|GUIToolTip_GetTitleBitMap|GUIToolTip_GetTitleText|GUIToolTip_GetToolCount|GUIToolTip_GetToolInfo|GUIToolTip_HitTest|GUIToolTip_NewToolRect|GUIToolTip_Pop|GUIToolTip_PopUp|GUIToolTip_SetDelayTime|GUIToolTip_SetMargin|GUIToolTip_SetMaxTipWidth|GUIToolTip_SetTipBkColor|GUIToolTip_SetTipTextColor|GUIToolTip_SetTitle|GUIToolTip_SetToolInfo|GUIToolTip_SetWindowTheme|GUIToolTip_ToolExists|GUIToolTip_ToolToArray|GUIToolTip_TrackActivate|GUIToolTip_TrackPosition|GUIToolTip_TTFToBits|GUIToolTip_Update|GUIToolTip_UpdateTipText|HexToString|IE_Example|IE_Introduction|IE_VersionInfo|IEAction|IEAttach|IEBodyReadHTML|IEBodyReadText|IEBodyWriteHTML|IECreate|IECreateEmbedded|IEDocGetObj|IEDocInsertHTML|IEDocInsertText|IEDocReadHTML|IEDocWriteHTML|IEErrorHandlerDeRegister|IEErrorHandlerRegister|IEErrorNotify|IEFormElementCheckBoxSelect|IEFormElementGetCollection|IEFormElementGetObjByName|IEFormElementGetValue|IEFormElementOptionSelect|IEFormElementRadioSelect|IEFormElementSetValue|IEFormGetCollection|IEFormGetObjByName|IEFormImageClick|IEFormReset|IEFormSubmit|IEFrameGetCollection|IEFrameGetObjByName|IEGetObjById|IEGetObjByName|IEHeadInsertEventScript|IEImgClick|IEImgGetCollection|IEIsFrameSet|IELinkClickByIndex|IELinkClickByText|IELinkGetCollection|IELoadWait|IELoadWaitTimeout|IENavigate|IEPropertyGet|IEPropertySet|IEQuit|IETableGetCollection|IETableWriteToArray|IETagNameAllGetCollection|IETagNameGetCollection|Iif|INetExplorerCapable|INetGetSource|INetMail|INetSmtpMail|IsPressed|MathCheckDiv|Max|MemGlobalAlloc|MemGlobalFree|MemGlobalLock|MemGlobalSize|MemGlobalUnlock|MemMoveMemory|MemMsgBox|MemShowError|MemVirtualAlloc|MemVirtualAllocEx|MemVirtualFree|MemVirtualFreeEx|Min|MouseTrap|NamedPipes_CallNamedPipe|NamedPipes_ConnectNamedPipe|NamedPipes_CreateNamedPipe|NamedPipes_CreatePipe|NamedPipes_DisconnectNamedPipe|NamedPipes_GetNamedPipeHandleState|NamedPipes_GetNamedPipeInfo|NamedPipes_PeekNamedPipe|NamedPipes_SetNamedPipeHandleState|NamedPipes_TransactNamedPipe|NamedPipes_WaitNamedPipe|Net_Share_ConnectionEnum|Net_Share_FileClose|Net_Share_FileEnum|Net_Share_FileGetInfo|Net_Share_PermStr|Net_Share_ResourceStr|Net_Share_SessionDel|Net_Share_SessionEnum|Net_Share_SessionGetInfo|Net_Share_ShareAdd|Net_Share_ShareCheck|Net_Share_ShareDel|Net_Share_ShareEnum|Net_Share_ShareGetInfo|Net_Share_ShareSetInfo|Net_Share_StatisticsGetSvr|Net_Share_StatisticsGetWrk|Now|NowCalc|NowCalcDate|NowDate|NowTime|PathFull|PathMake|PathSplit|ProcessGetName|ProcessGetPriority|Radian|ReplaceStringInFile|RunDOS|ScreenCapture_Capture|ScreenCapture_CaptureWnd|ScreenCapture_SaveImage|ScreenCapture_SetBMPFormat|ScreenCapture_SetJPGQuality|ScreenCapture_SetTIFColorDepth|ScreenCapture_SetTIFCompression|Security__AdjustTokenPrivileges|Security__GetAccountSid|Security__GetLengthSid|Security__GetTokenInformation|Security__ImpersonateSelf|Security__IsValidSid|Security__LookupAccountName|Security__LookupAccountSid|Security__LookupPrivilegeValue|Security__OpenProcessToken|Security__OpenThreadToken|Security__OpenThreadTokenEx|Security__SetPrivilege|Security__SidToStringSid|Security__SidTypeStr|Security__StringSidToSid|SendMessage|SendMessageA|SetDate|SetTime|Singleton|SoundClose|SoundLength|SoundOpen|SoundPause|SoundPlay|SoundPos|SoundResume|SoundSeek|SoundStatus|SoundStop|SQLite_Changes|SQLite_Close|SQLite_Display2DResult|SQLite_Encode|SQLite_ErrCode|SQLite_ErrMsg|SQLite_Escape|SQLite_Exec|SQLite_FetchData|SQLite_FetchNames|SQLite_GetTable|SQLite_GetTable2d|SQLite_LastInsertRowID|SQLite_LibVersion|SQLite_Open|SQLite_Query|SQLite_QueryFinalize|SQLite_QueryReset|SQLite_QuerySingleRow|SQLite_SaveMode|SQLite_SetTimeout|SQLite_Shutdown|SQLite_SQLiteExe|SQLite_Startup|SQLite_TotalChanges|StringAddComma|StringBetween|StringEncrypt|StringInsert|StringProper|StringRepeat|StringReverse|StringSplit|StringToHex|TCPIpToName|TempFile|TicksToTime|Timer_Diff|Timer_GetTimerID|Timer_Init|Timer_KillAllTimers|Timer_KillTimer|Timer_SetTimer|TimeToTicks|VersionCompare|viClose|viExecCommand|viFindGpib|viGpibBusReset|viGTL|viOpen|viSetAttribute|viSetTimeout|WeekNumberISO|WinAPI_AttachConsole|WinAPI_AttachThreadInput|WinAPI_Beep|WinAPI_BitBlt|WinAPI_CallNextHookEx|WinAPI_Check|WinAPI_ClientToScreen|WinAPI_CloseHandle|WinAPI_CommDlgExtendedError|WinAPI_CopyIcon|WinAPI_CreateBitmap|WinAPI_CreateCompatibleBitmap|WinAPI_CreateCompatibleDC|WinAPI_CreateEvent|WinAPI_CreateFile|WinAPI_CreateFont|WinAPI_CreateFontIndirect|WinAPI_CreateProcess|WinAPI_CreateSolidBitmap|WinAPI_CreateSolidBrush|WinAPI_CreateWindowEx|WinAPI_DefWindowProc|WinAPI_DeleteDC|WinAPI_DeleteObject|WinAPI_DestroyIcon|WinAPI_DestroyWindow|WinAPI_DrawEdge|WinAPI_DrawFrameControl|WinAPI_DrawIcon|WinAPI_DrawIconEx|WinAPI_DrawText|WinAPI_EnableWindow|WinAPI_EnumDisplayDevices|WinAPI_EnumWindows|WinAPI_EnumWindowsPopup|WinAPI_EnumWindowsTop|WinAPI_ExpandEnvironmentStrings|WinAPI_ExtractIconEx|WinAPI_FatalAppExit|WinAPI_FillRect|WinAPI_FindExecutable|WinAPI_FindWindow|WinAPI_FlashWindow|WinAPI_FlashWindowEx|WinAPI_FloatToInt|WinAPI_FlushFileBuffers|WinAPI_FormatMessage|WinAPI_FrameRect|WinAPI_FreeLibrary|WinAPI_GetAncestor|WinAPI_GetAsyncKeyState|WinAPI_GetClassName|WinAPI_GetClientHeight|WinAPI_GetClientRect|WinAPI_GetClientWidth|WinAPI_GetCurrentProcess|WinAPI_GetCurrentProcessID|WinAPI_GetCurrentThread|WinAPI_GetCurrentThreadId|WinAPI_GetCursorInfo|WinAPI_GetDC|WinAPI_GetDesktopWindow|WinAPI_GetDeviceCaps|WinAPI_GetDIBits|WinAPI_GetDlgCtrlID|WinAPI_GetDlgItem|WinAPI_GetFileSizeEx|WinAPI_GetFocus|WinAPI_GetForegroundWindow|WinAPI_GetIconInfo|WinAPI_GetLastError|WinAPI_GetLastErrorMessage|WinAPI_GetModuleHandle|WinAPI_GetMousePos|WinAPI_GetMousePosX|WinAPI_GetMousePosY|WinAPI_GetObject|WinAPI_GetOpenFileName|WinAPI_GetOverlappedResult|WinAPI_GetParent|WinAPI_GetProcessAffinityMask|WinAPI_GetSaveFileName|WinAPI_GetStdHandle|WinAPI_GetStockObject|WinAPI_GetSysColor|WinAPI_GetSysColorBrush|WinAPI_GetSystemMetrics|WinAPI_GetTextExtentPoint32|WinAPI_GetWindow|WinAPI_GetWindowDC|WinAPI_GetWindowHeight|WinAPI_GetWindowLong|WinAPI_GetWindowRect|WinAPI_GetWindowText|WinAPI_GetWindowThreadProcessId|WinAPI_GetWindowWidth|WinAPI_GetXYFromPoint|WinAPI_GlobalMemStatus|WinAPI_GUIDFromString|WinAPI_GUIDFromStringEx|WinAPI_HiWord|WinAPI_InProcess|WinAPI_IntToFloat|WinAPI_InvalidateRect|WinAPI_IsClassName|WinAPI_IsWindow|WinAPI_IsWindowVisible|WinAPI_LoadBitmap|WinAPI_LoadImage|WinAPI_LoadLibrary|WinAPI_LoadLibraryEx|WinAPI_LoadShell32Icon|WinAPI_LoadString|WinAPI_LocalFree|WinAPI_LoWord|WinAPI_MakeDWord|WinAPI_MAKELANGID|WinAPI_MAKELCID|WinAPI_MakeLong|WinAPI_MessageBeep|WinAPI_Mouse_Event|WinAPI_MoveWindow|WinAPI_MsgBox|WinAPI_MulDiv|WinAPI_MultiByteToWideChar|WinAPI_MultiByteToWideCharEx|WinAPI_OpenProcess|WinAPI_PointFromRect|WinAPI_PostMessage|WinAPI_PrimaryLangId|WinAPI_PtInRect|WinAPI_ReadFile|WinAPI_ReadProcessMemory|WinAPI_RectIsEmpty|WinAPI_RedrawWindow|WinAPI_RegisterWindowMessage|WinAPI_ReleaseCapture|WinAPI_ReleaseDC|WinAPI_ScreenToClient|WinAPI_SelectObject|WinAPI_SetBkColor|WinAPI_SetCapture|WinAPI_SetCursor|WinAPI_SetDefaultPrinter|WinAPI_SetDIBits|WinAPI_SetEvent|WinAPI_SetFocus|WinAPI_SetFont|WinAPI_SetHandleInformation|WinAPI_SetLastError|WinAPI_SetParent|WinAPI_SetProcessAffinityMask|WinAPI_SetSysColors|WinAPI_SetTextColor|WinAPI_SetWindowLong|WinAPI_SetWindowPos|WinAPI_SetWindowsHookEx|WinAPI_SetWindowText|WinAPI_ShowCursor|WinAPI_ShowError|WinAPI_ShowMsg|WinAPI_ShowWindow|WinAPI_StringFromGUID|WinAPI_SubLangId|WinAPI_SystemParametersInfo|WinAPI_TwipsPerPixelX|WinAPI_TwipsPerPixelY|WinAPI_UnhookWindowsHookEx|WinAPI_UpdateLayeredWindow|WinAPI_UpdateWindow|WinAPI_ValidateClassName|WinAPI_WaitForInputIdle|WinAPI_WaitForMultipleObjects|WinAPI_WaitForSingleObject|WinAPI_WideCharToMultiByte|WinAPI_WindowFromPoint|WinAPI_WriteConsole|WinAPI_WriteFile|WinAPI_WriteProcessMemory|WinNet_AddConnection|WinNet_AddConnection2|WinNet_AddConnection3|WinNet_CancelConnection|WinNet_CancelConnection2|WinNet_CloseEnum|WinNet_ConnectionDialog|WinNet_ConnectionDialog1|WinNet_DisconnectDialog|WinNet_DisconnectDialog1|WinNet_EnumResource|WinNet_GetConnection|WinNet_GetConnectionPerformance|WinNet_GetLastError|WinNet_GetNetworkInformation|WinNet_GetProviderName|WinNet_GetResourceInformation|WinNet_GetResourceParent|WinNet_GetUniversalName|WinNet_GetUser|WinNet_OpenEnum|WinNet_RestoreConnection|WinNet_UseConnection|Word_VersionInfo|WordAttach|WordCreate|WordDocAdd|WordDocAddLink|WordDocAddPicture|WordDocClose|WordDocFindReplace|WordDocGetCollection|WordDocLinkGetCollection|WordDocOpen|WordDocPrint|WordDocPropertyGet|WordDocPropertySet|WordDocSave|WordDocSaveAs|WordErrorHandlerDeRegister|WordErrorHandlerRegister|WordErrorNotify|WordMacroRun|WordPropertyGet|WordPropertySet|WordQuit|' +
+ 'ce|comments-end|comments-start|cs|include|include-once|NoTrayIcon|RequireAdmin|' +
+ 'AutoIt3Wrapper_Au3Check_Parameters|AutoIt3Wrapper_Au3Check_Stop_OnWarning|AutoIt3Wrapper_Change2CUI|AutoIt3Wrapper_Compression|AutoIt3Wrapper_cvsWrapper_Parameters|AutoIt3Wrapper_Icon|AutoIt3Wrapper_Outfile|AutoIt3Wrapper_Outfile_Type|AutoIt3Wrapper_Plugin_Funcs|AutoIt3Wrapper_Res_Comment|AutoIt3Wrapper_Res_Description|AutoIt3Wrapper_Res_Field|AutoIt3Wrapper_Res_File_Add|AutoIt3Wrapper_Res_Fileversion|AutoIt3Wrapper_Res_FileVersion_AutoIncrement|AutoIt3Wrapper_Res_Icon_Add|AutoIt3Wrapper_Res_Language|AutoIt3Wrapper_Res_LegalCopyright|AutoIt3Wrapper_res_requestedExecutionLevel|AutoIt3Wrapper_Res_SaveSource|AutoIt3Wrapper_Run_After|AutoIt3Wrapper_Run_Au3check|AutoIt3Wrapper_Run_Before|AutoIt3Wrapper_Run_cvsWrapper|AutoIt3Wrapper_Run_Debug_Mode|AutoIt3Wrapper_Run_Obfuscator|AutoIt3Wrapper_Run_Tidy|AutoIt3Wrapper_Tidy_Stop_OnError|AutoIt3Wrapper_UseAnsi|AutoIt3Wrapper_UseUpx|AutoIt3Wrapper_UseX64|AutoIt3Wrapper_Version|EndRegion|forceref|Obfuscator_Ignore_Funcs|Obfuscator_Ignore_Variables|Obfuscator_Parameters|Region|Tidy_Parameters'
+ var atKeywords = 'AppDataCommonDir|AppDataDir|AutoItExe|AutoItPID|AutoItUnicode|AutoItVersion|AutoItX64|COM_EventObj|CommonFilesDir|Compiled|ComputerName|ComSpec|CR|CRLF|DesktopCommonDir|DesktopDepth|DesktopDir|DesktopHeight|DesktopRefresh|DesktopWidth|DocumentsCommonDir|error|exitCode|exitMethod|extended|FavoritesCommonDir|FavoritesDir|GUI_CtrlHandle|GUI_CtrlId|GUI_DragFile|GUI_DragId|GUI_DropId|GUI_WinHandle|HomeDrive|HomePath|HomeShare|HotKeyPressed|HOUR|InetGetActive|InetGetBytesRead|IPAddress1|IPAddress2|IPAddress3|IPAddress4|KBLayout|LF|LogonDNSDomain|LogonDomain|LogonServer|MDAY|MIN|MON|MyDocumentsDir|NumParams|OSBuild|OSLang|OSServicePack|OSTYPE|OSVersion|ProcessorArch|ProgramFilesDir|ProgramsCommonDir|ProgramsDir|ScriptDir|ScriptFullPath|ScriptLineNumber|ScriptName|SEC|StartMenuCommonDir|StartMenuDir|StartupCommonDir|StartupDir|SW_DISABLE|SW_ENABLE|SW_HIDE|SW_LOCK|SW_MAXIMIZE|SW_MINIMIZE|SW_RESTORE|SW_SHOW|SW_SHOWDEFAULT|SW_SHOWMAXIMIZED|SW_SHOWMINIMIZED|SW_SHOWMINNOACTIVE|SW_SHOWNA|SW_SHOWNOACTIVATE|SW_SHOWNORMAL|SW_UNLOCK|SystemDir|TAB|TempDir|TRAY_ID|TrayIconFlashing|TrayIconVisible|UserName|UserProfileDir|WDAY|WindowsDir|WorkingDir|YDAY|YEAR'
+
+ this.$rules = { start:
+ [ { token: 'comment.line.ahk', regex: '(?:^| );.*$' },
+ { token: 'comment.block.ahk',
+ regex: '/\\*', push:
+ [ { token: 'comment.block.ahk', regex: '\\*/', next: 'pop' },
+ { defaultToken: 'comment.block.ahk' } ] },
+ { token: 'doc.comment.ahk',
+ regex: '#cs', push:
+ [ { token: 'doc.comment.ahk', regex: '#ce', next: 'pop' },
+ { defaultToken: 'doc.comment.ahk' } ] },
+ { token: 'keyword.command.ahk',
+ regex: '(?:\\b|^)(?:allowsamelinecomments|clipboardtimeout|commentflag|errorstdout|escapechar|hotkeyinterval|hotkeymodifiertimeout|hotstring|include|includeagain|installkeybdhook|installmousehook|keyhistory|ltrim|maxhotkeysperinterval|maxmem|maxthreads|maxthreadsbuffer|maxthreadsperhotkey|noenv|notrayicon|persistent|singleinstance|usehook|winactivateforce|autotrim|blockinput|click|clipwait|continue|control|controlclick|controlfocus|controlget|controlgetfocus|controlgetpos|controlgettext|controlmove|controlsend|controlsendraw|controlsettext|coordmode|critical|detecthiddentext|detecthiddenwindows|drive|driveget|drivespacefree|edit|endrepeat|envadd|envdiv|envget|envmult|envset|envsub|envupdate|exit|exitapp|fileappend|filecopy|filecopydir|filecreatedir|filecreateshortcut|filedelete|filegetattrib|filegetshortcut|filegetsize|filegettime|filegetversion|fileinstall|filemove|filemovedir|fileread|filereadline|filerecycle|filerecycleempty|fileremovedir|fileselectfile|fileselectfolder|filesetattrib|filesettime|formattime|getkeystate|gosub|goto|groupactivate|groupadd|groupclose|groupdeactivate|gui|guicontrol|guicontrolget|hideautoitwin|hotkey|ifequal|ifexist|ifgreater|ifgreaterorequal|ifinstring|ifless|iflessorequal|ifmsgbox|ifnotequal|ifnotexist|ifnotinstring|ifwinactive|ifwinexist|ifwinnotactive|ifwinnotexist|imagesearch|inidelete|iniread|iniwrite|input|inputbox|keyhistory|keywait|listhotkeys|listlines|listvars|menu|mouseclick|mouseclickdrag|mousegetpos|mousemove|msgbox|onexit|outputdebug|pause|pixelgetcolor|pixelsearch|postmessage|process|progress|random|regdelete|regread|regwrite|reload|repeat|run|runas|runwait|send|sendevent|sendinput|sendmode|sendplay|sendmessage|sendraw|setbatchlines|setcapslockstate|setcontroldelay|setdefaultmousespeed|setenv|setformat|setkeydelay|setmousedelay|setnumlockstate|setscrolllockstate|setstorecapslockmode|settimer|settitlematchmode|setwindelay|setworkingdir|shutdown|sleep|sort|soundbeep|soundget|soundgetwavevolume|soundplay|soundset|soundsetwavevolume|splashimage|splashtextoff|splashtexton|splitpath|statusbargettext|statusbarwait|stringcasesense|stringgetpos|stringleft|stringlen|stringlower|stringmid|stringreplace|stringright|stringsplit|stringtrimleft|stringtrimright|stringupper|suspend|sysget|thread|tooltip|transform|traytip|urldownloadtofile|while|winactivate|winactivatebottom|winclose|winget|wingetactivestats|wingetactivetitle|wingetclass|wingetpos|wingettext|wingettitle|winhide|winkill|winmaximize|winmenuselectitem|winminimize|winminimizeall|winminimizeallundo|winmove|winrestore|winset|winsettitle|winshow|winwait|winwaitactive|winwaitclose|winwaitnotactive)\\b',
+ caseInsensitive: true },
+ { token: 'keyword.control.ahk',
+ regex: '(?:\\b|^)(?:if|else|return|loop|break|for|while|global|local|byref)\\b',
+ caseInsensitive: true },
+ { token: 'support.function.ahk',
+ regex: '(?:\\b|^)(?:abs|acos|asc|asin|atan|ceil|chr|cos|dllcall|exp|fileexist|floor|getkeystate|il_add|il_create|il_destroy|instr|substr|isfunc|islabel|ln|log|lv_add|lv_delete|lv_deletecol|lv_getcount|lv_getnext|lv_gettext|lv_insert|lv_insertcol|lv_modify|lv_modifycol|lv_setimagelist|mod|onmessage|numget|numput|registercallback|regexmatch|regexreplace|round|sin|tan|sqrt|strlen|sb_seticon|sb_setparts|sb_settext|tv_add|tv_delete|tv_getchild|tv_getcount|tv_getnext|tv_get|tv_getparent|tv_getprev|tv_getselection|tv_gettext|tv_modify|varsetcapacity|winactive|winexist)\\b',
+ caseInsensitive: true },
+ { token: 'variable.predefined.ahk',
+ regex: '(?:\\b|^)(?:a_ahkpath|a_ahkversion|a_appdata|a_appdatacommon|a_autotrim|a_batchlines|a_caretx|a_carety|a_computername|a_controldelay|a_cursor|a_dd|a_ddd|a_dddd|a_defaultmousespeed|a_desktop|a_desktopcommon|a_detecthiddentext|a_detecthiddenwindows|a_endchar|a_eventinfo|a_exitreason|a_formatfloat|a_formatinteger|a_gui|a_guievent|a_guicontrol|a_guicontrolevent|a_guiheight|a_guiwidth|a_guix|a_guiy|a_hour|a_iconfile|a_iconhidden|a_iconnumber|a_icontip|a_index|a_ipaddress1|a_ipaddress2|a_ipaddress3|a_ipaddress4|a_isadmin|a_iscompiled|a_iscritical|a_ispaused|a_issuspended|a_keydelay|a_language|a_lasterror|a_linefile|a_linenumber|a_loopfield|a_loopfileattrib|a_loopfiledir|a_loopfileext|a_loopfilefullpath|a_loopfilelongpath|a_loopfilename|a_loopfileshortname|a_loopfileshortpath|a_loopfilesize|a_loopfilesizekb|a_loopfilesizemb|a_loopfiletimeaccessed|a_loopfiletimecreated|a_loopfiletimemodified|a_loopreadline|a_loopregkey|a_loopregname|a_loopregsubkey|a_loopregtimemodified|a_loopregtype|a_mday|a_min|a_mm|a_mmm|a_mmmm|a_mon|a_mousedelay|a_msec|a_mydocuments|a_now|a_nowutc|a_numbatchlines|a_ostype|a_osversion|a_priorhotkey|programfiles|a_programfiles|a_programs|a_programscommon|a_screenheight|a_screenwidth|a_scriptdir|a_scriptfullpath|a_scriptname|a_sec|a_space|a_startmenu|a_startmenucommon|a_startup|a_startupcommon|a_stringcasesense|a_tab|a_temp|a_thisfunc|a_thishotkey|a_thislabel|a_thismenu|a_thismenuitem|a_thismenuitempos|a_tickcount|a_timeidle|a_timeidlephysical|a_timesincepriorhotkey|a_timesincethishotkey|a_titlematchmode|a_titlematchmodespeed|a_username|a_wday|a_windelay|a_windir|a_workingdir|a_yday|a_year|a_yweek|a_yyyy|clipboard|clipboardall|comspec|errorlevel)\\b',
+ caseInsensitive: true },
+ { token: 'support.constant.ahk',
+ regex: '(?:\\b|^)(?:shift|lshift|rshift|alt|lalt|ralt|control|lcontrol|rcontrol|ctrl|lctrl|rctrl|lwin|rwin|appskey|altdown|altup|shiftdown|shiftup|ctrldown|ctrlup|lwindown|lwinup|rwindown|rwinup|lbutton|rbutton|mbutton|wheelup|wheelleft|wheelright|wheeldown|xbutton1|xbutton2|joy1|joy2|joy3|joy4|joy5|joy6|joy7|joy8|joy9|joy10|joy11|joy12|joy13|joy14|joy15|joy16|joy17|joy18|joy19|joy20|joy21|joy22|joy23|joy24|joy25|joy26|joy27|joy28|joy29|joy30|joy31|joy32|joyx|joyy|joyz|joyr|joyu|joyv|joypov|joyname|joybuttons|joyaxes|joyinfo|space|tab|enter|escape|esc|backspace|bs|delete|del|insert|ins|pgup|pgdn|home|end|up|down|left|right|printscreen|ctrlbreak|pause|scrolllock|capslock|numlock|numpad0|numpad1|numpad2|numpad3|numpad4|numpad5|numpad6|numpad7|numpad8|numpad9|numpadmult|numpadadd|numpadsub|numpaddiv|numpaddot|numpaddel|numpadins|numpadclear|numpadup|numpaddown|numpadleft|numpadright|numpadhome|numpadend|numpadpgup|numpadpgdn|numpadenter|f1|f2|f3|f4|f5|f6|f7|f8|f9|f10|f11|f12|f13|f14|f15|f16|f17|f18|f19|f20|f21|f22|f23|f24|browser_back|browser_forward|browser_refresh|browser_stop|browser_search|browser_favorites|browser_home|volume_mute|volume_down|volume_up|media_next|media_prev|media_stop|media_play_pause|launch_mail|launch_media|launch_app1|launch_app2)\\b',
+ caseInsensitive: true },
+ { token: 'variable.parameter',
+ regex: '(?:\\b|^)(?:pixel|mouse|screen|relative|rgb|ltrim|rtrim|join|low|belownormal|normal|abovenormal|high|realtime|ahk_id|ahk_pid|ahk_class|ahk_group|between|contains|in|is|integer|float|integerfast|floatfast|number|digit|xdigit|alpha|upper|lower|alnum|time|date|not|or|and|alwaysontop|topmost|top|bottom|transparent|transcolor|redraw|region|id|idlast|processname|minmax|controllist|count|list|capacity|statuscd|eject|lock|unlock|label|filesystem|label|setlabel|serial|type|status|static|seconds|minutes|hours|days|read|parse|logoff|close|error|single|tray|add|rename|check|uncheck|togglecheck|enable|disable|toggleenable|default|nodefault|standard|nostandard|color|delete|deleteall|icon|noicon|tip|click|show|mainwindow|nomainwindow|useerrorlevel|text|picture|pic|groupbox|button|checkbox|radio|dropdownlist|ddl|combobox|listbox|listview|datetime|monthcal|updown|slider|tab|tab2|statusbar|treeview|iconsmall|tile|report|sortdesc|nosort|nosorthdr|grid|hdr|autosize|range|xm|ym|ys|xs|xp|yp|font|resize|owner|submit|nohide|minimize|maximize|restore|noactivate|na|cancel|destroy|center|margin|maxsize|minsize|owndialogs|guiescape|guiclose|guisize|guicontextmenu|guidropfiles|tabstop|section|altsubmit|wrap|hscroll|vscroll|border|top|bottom|buttons|expand|first|imagelist|lines|wantctrla|wantf2|vis|visfirst|number|uppercase|lowercase|limit|password|multi|wantreturn|group|background|bold|italic|strike|underline|norm|backgroundtrans|theme|caption|delimiter|minimizebox|maximizebox|sysmenu|toolwindow|flash|style|exstyle|check3|checked|checkedgray|readonly|password|hidden|left|right|center|notab|section|move|focus|hide|choose|choosestring|text|pos|enabled|disabled|visible|lastfound|lastfoundexist|alttab|shiftalttab|alttabmenu|alttabandmenu|alttabmenudismiss|notimers|interrupt|priority|waitclose|blind|raw|unicode|deref|pow|bitnot|bitand|bitor|bitxor|bitshiftleft|bitshiftright|yes|no|ok|cancel|abort|retry|ignore|tryagain|on|off|all|hkey_local_machine|hkey_users|hkey_current_user|hkey_classes_root|hkey_current_config|hklm|hku|hkcu|hkcr|hkcc|reg_sz|reg_expand_sz|reg_multi_sz|reg_dword|reg_qword|reg_binary|reg_link|reg_resource_list|reg_full_resource_descriptor|reg_resource_requirements_list|reg_dword_big_endian)\\b',
+ caseInsensitive: true },
+ { keywordMap: {"constant.language": autoItKeywords}, regex: '\\w+\\b'},
+ { keywordMap: {"variable.function": atKeywords}, regex: '@\\w+\\b'},
+ { token : "constant.numeric", regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},
+ { token: 'keyword.operator.ahk',
+ regex: '=|==|<>|:=|<|>|\\*|\\/|\\+|:|\\?|\\-' },
+ { token: 'punctuation.ahk',
+ regex: '#|`|::|,|\\{|\\}|\\(|\\)|\\%' },
+ { token:
+ [ 'punctuation.quote.double',
+ 'string.quoted.ahk',
+ 'punctuation.quote.double' ],
+ regex: '(")((?:[^"]|"")*)(")' },
+ { token: [ 'label.ahk', 'punctuation.definition.label.ahk' ],
+ regex: '^([^: ]+)(:)(?!:)' } ] }
+
+ this.normalizeRules();
+};
+
+AutoHotKeyHighlightRules.metaData = { name: 'AutoHotKey',
+ scopeName: 'source.ahk',
+ fileTypes: [ 'ahk' ],
+ foldingStartMarker: '^\\s*/\\*|^(?![^{]*?;|[^{]*?/\\*(?!.*?\\*/.*?\\{)).*?\\{\\s*($|;|/\\*(?!.*?\\*/.*\\S))',
+ foldingStopMarker: '^\\s*\\*/|^\\s*\\}' }
+
+
+oop.inherits(AutoHotKeyHighlightRules, TextHighlightRules);
+
+exports.AutoHotKeyHighlightRules = AutoHotKeyHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/autohotkey",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/autohotkey_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var AutoHotKeyHighlightRules = require("./autohotkey_highlight_rules").AutoHotKeyHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = AutoHotKeyHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = ";";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/autohotkey";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-batchfile.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-batchfile.js
new file mode 100644
index 00000000..3f31ce12
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-batchfile.js
@@ -0,0 +1,223 @@
+ace.define("ace/mode/batchfile_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var BatchFileHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token: 'keyword.command.dosbatch',
+ regex: '\\b(?:append|assoc|at|attrib|break|cacls|cd|chcp|chdir|chkdsk|chkntfs|cls|cmd|color|comp|compact|convert|copy|date|del|dir|diskcomp|diskcopy|doskey|echo|endlocal|erase|fc|find|findstr|format|ftype|graftabl|help|keyb|label|md|mkdir|mode|more|move|path|pause|popd|print|prompt|pushd|rd|recover|ren|rename|replace|restore|rmdir|set|setlocal|shift|sort|start|subst|time|title|tree|type|ver|verify|vol|xcopy)\\b',
+ caseInsensitive: true },
+ { token: 'keyword.control.statement.dosbatch',
+ regex: '\\b(?:goto|call|exit)\\b',
+ caseInsensitive: true },
+ { token: 'keyword.control.conditional.if.dosbatch',
+ regex: '\\bif\\s+not\\s+(?:exist|defined|errorlevel|cmdextversion)\\b',
+ caseInsensitive: true },
+ { token: 'keyword.control.conditional.dosbatch',
+ regex: '\\b(?:if|else)\\b',
+ caseInsensitive: true },
+ { token: 'keyword.control.repeat.dosbatch',
+ regex: '\\bfor\\b',
+ caseInsensitive: true },
+ { token: 'keyword.operator.dosbatch',
+ regex: '\\b(?:EQU|NEQ|LSS|LEQ|GTR|GEQ)\\b' },
+ { token: ['doc.comment', 'comment'],
+ regex: '(?:^|\\b)(rem)($|\\s.*$)',
+ caseInsensitive: true },
+ { token: 'comment.line.colons.dosbatch',
+ regex: '::.*$' },
+ { include: 'variable' },
+ { token: 'punctuation.definition.string.begin.shell',
+ regex: '"',
+ push: [
+ { token: 'punctuation.definition.string.end.shell', regex: '"', next: 'pop' },
+ { include: 'variable' },
+ { defaultToken: 'string.quoted.double.dosbatch' } ] },
+ { token: 'keyword.operator.pipe.dosbatch', regex: '[|]' },
+ { token: 'keyword.operator.redirect.shell',
+ regex: '&>|\\d*>&\\d*|\\d*(?:>>|>|<)|\\d*<&|\\d*<>' } ],
+ variable: [
+ { token: 'constant.numeric', regex: '%%\\w+|%[*\\d]|%\\w+%'},
+ { token: 'constant.numeric', regex: '%~\\d+'},
+ { token: ['markup.list', 'constant.other', 'markup.list'],
+ regex: '(%)(\\w+)(%?)' }]}
+
+ this.normalizeRules();
+};
+
+BatchFileHighlightRules.metaData = { name: 'Batch File',
+ scopeName: 'source.dosbatch',
+ fileTypes: [ 'bat' ] }
+
+
+oop.inherits(BatchFileHighlightRules, TextHighlightRules);
+
+exports.BatchFileHighlightRules = BatchFileHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/batchfile",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/batchfile_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var BatchFileHighlightRules = require("./batchfile_highlight_rules").BatchFileHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = BatchFileHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "::";
+ this.blockComment = "";
+ this.$id = "ace/mode/batchfile";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-bro.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-bro.js
new file mode 100644
index 00000000..dd259ebe
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-bro.js
@@ -0,0 +1,327 @@
+ace.define("ace/mode/bro_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var BroHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ token: "punctuation.definition.comment.bro",
+ regex: /#/,
+ push: [{
+ token: "comment.line.number-sign.bro",
+ regex: /$/,
+ next: "pop"
+ }, {
+ defaultToken: "comment.line.number-sign.bro"
+ }]
+ }, {
+ token: "keyword.control.bro",
+ regex: /\b(?:break|case|continue|else|for|if|return|switch|next|when|timeout|schedule)\b/
+ }, {
+ token: [
+ "meta.function.bro",
+ "meta.function.bro",
+ "storage.type.bro",
+ "meta.function.bro",
+ "entity.name.function.bro",
+ "meta.function.bro"
+ ],
+ regex: /^(\s*)(?:function|hook|event)(\s*)(.*)(\s*\()(.*)(\).*$)/
+ }, {
+ token: "storage.type.bro",
+ regex: /\b(?:bool|enum|double|int|count|port|addr|subnet|any|file|interval|time|string|table|vector|set|record|pattern|hook)\b/
+ }, {
+ token: "storage.modifier.bro",
+ regex: /\b(?:global|const|redef|local|&(?:optional|rotate_interval|rotate_size|add_func|del_func|expire_func|expire_create|expire_read|expire_write|persistent|synchronized|encrypt|mergeable|priority|group|type_column|log|error_handler))\b/
+ }, {
+ token: "keyword.operator.bro",
+ regex: /\s*(?:\||&&|(?:>|<|!)=?|==)\s*|\b!?in\b/
+ }, {
+ token: "constant.language.bro",
+ regex: /\b(?:T|F)\b/
+ }, {
+ token: "constant.numeric.bro",
+ regex: /\b(?:0(?:x|X)[0-9a-fA-F]*|(?:[0-9]+\.?[0-9]*|\.[0-9]+)(?:(?:e|E)(?:\+|-)?[0-9]+)?)(?:\/(?:tcp|udp|icmp)|\s*(?:u?sec|min|hr|day)s?)?\b/
+ }, {
+ token: "punctuation.definition.string.begin.bro",
+ regex: /"/,
+ push: [{
+ token: "punctuation.definition.string.end.bro",
+ regex: /"/,
+ next: "pop"
+ }, {
+ include: "#string_escaped_char"
+ }, {
+ include: "#string_placeholder"
+ }, {
+ defaultToken: "string.quoted.double.bro"
+ }]
+ }, {
+ token: "punctuation.definition.string.begin.bro",
+ regex: /\//,
+ push: [{
+ token: "punctuation.definition.string.end.bro",
+ regex: /\//,
+ next: "pop"
+ }, {
+ include: "#string_escaped_char"
+ }, {
+ include: "#string_placeholder"
+ }, {
+ defaultToken: "string.quoted.regex.bro"
+ }]
+ }, {
+ token: [
+ "meta.preprocessor.bro.load",
+ "keyword.other.special-method.bro"
+ ],
+ regex: /^(\s*)(\@load(?:-sigs)?)\b/,
+ push: [{
+ token: [],
+ regex: /(?=\#)|$/,
+ next: "pop"
+ }, {
+ defaultToken: "meta.preprocessor.bro.load"
+ }]
+ }, {
+ token: [
+ "meta.preprocessor.bro.if",
+ "keyword.other.special-method.bro",
+ "meta.preprocessor.bro.if"
+ ],
+ regex: /^(\s*)(\@endif|\@if(?:n?def)?)(.*$)/,
+ push: [{
+ token: [],
+ regex: /$/,
+ next: "pop"
+ }, {
+ defaultToken: "meta.preprocessor.bro.if"
+ }]
+ }],
+ "#disabled": [{
+ token: "text",
+ regex: /^\s*\@if(?:n?def)?\b.*$/,
+ push: [{
+ token: "text",
+ regex: /^\s*\@endif\b.*$/,
+ next: "pop"
+ }, {
+ include: "#disabled"
+ }, {
+ include: "#pragma-mark"
+ }],
+ comment: "eat nested preprocessor ifdefs"
+ }],
+ "#preprocessor-rule-other": [{
+ token: [
+ "text",
+ "meta.preprocessor.bro",
+ "meta.preprocessor.bro",
+ "text"
+ ],
+ regex: /^(\s*)(@if)((?:n?def)?)\b(.*?)(?:(?=)|$)/,
+ push: [{
+ token: ["text", "meta.preprocessor.bro", "text"],
+ regex: /^(\s*)(@endif)\b(.*$)/,
+ next: "pop"
+ }, {
+ include: "$base"
+ }]
+ }],
+ "#string_escaped_char": [{
+ token: "constant.character.escape.bro",
+ regex: /\\(?:\\|[abefnprtv'"?]|[0-3]\d{,2}|[4-7]\d?|x[a-fA-F0-9]{,2})/
+ }, {
+ token: "invalid.illegal.unknown-escape.bro",
+ regex: /\\./
+ }],
+ "#string_placeholder": [{
+ token: "constant.other.placeholder.bro",
+ regex: /%(?:\d+\$)?[#0\- +']*[,;:_]?(?:-?\d+|\*(?:-?\d+\$)?)?(?:\.(?:-?\d+|\*(?:-?\d+\$)?)?)?(?:hh|h|ll|l|j|t|z|q|L|vh|vl|v|hv|hl)?[diouxXDOUeEfFgGaACcSspn%]/
+ }, {
+ token: "invalid.illegal.placeholder.bro",
+ regex: /%/
+ }]
+ }
+
+ this.normalizeRules();
+};
+
+BroHighlightRules.metaData = {
+ fileTypes: ["bro"],
+ foldingStartMarker: "^(\\@if(n?def)?)",
+ foldingStopMarker: "^\\@endif",
+ keyEquivalent: "@B",
+ name: "Bro",
+ scopeName: "source.bro"
+}
+
+
+oop.inherits(BroHighlightRules, TextHighlightRules);
+
+exports.BroHighlightRules = BroHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/bro",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/bro_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var BroHighlightRules = require("./bro_highlight_rules").BroHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = BroHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$id = "ace/mode/bro"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-c9search.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-c9search.js
new file mode 100644
index 00000000..aad3dc19
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-c9search.js
@@ -0,0 +1,287 @@
+ace.define("ace/mode/c9search_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+function safeCreateRegexp(source, flag) {
+ try {
+ return new RegExp(source, flag);
+ } catch(e) {}
+}
+
+var C9SearchHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ tokenNames : ["c9searchresults.constant.numeric", "c9searchresults.text", "c9searchresults.text", "c9searchresults.keyword"],
+ regex : /(^\s+[0-9]+)(:)(\d*\s?)([^\r\n]+)/,
+ onMatch : function(val, state, stack) {
+ var values = this.splitRegex.exec(val);
+ var types = this.tokenNames;
+ var tokens = [{
+ type: types[0],
+ value: values[1]
+ }, {
+ type: types[1],
+ value: values[2]
+ }];
+
+ if (values[3]) {
+ if (values[3] == " ")
+ tokens[1] = { type: types[1], value: values[2] + " " };
+ else
+ tokens.push({ type: types[1], value: values[3] });
+ }
+ var regex = stack[1];
+ var str = values[4];
+
+ var m;
+ var last = 0;
+ if (regex && regex.exec) {
+ regex.lastIndex = 0;
+ while (m = regex.exec(str)) {
+ var skipped = str.substring(last, m.index);
+ last = regex.lastIndex;
+ if (skipped)
+ tokens.push({type: types[2], value: skipped});
+ if (m[0])
+ tokens.push({type: types[3], value: m[0]});
+ else if (!skipped)
+ break;
+ }
+ }
+ if (last < str.length)
+ tokens.push({type: types[2], value: str.substr(last)});
+ return tokens;
+ }
+ },
+ {
+ regex : "^Searching for [^\\r\\n]*$",
+ onMatch: function(val, state, stack) {
+ var parts = val.split("\x01");
+ if (parts.length < 3)
+ return "text";
+
+ var options, search, replace;
+
+ var i = 0;
+ var tokens = [{
+ value: parts[i++] + "'",
+ type: "text"
+ }, {
+ value: search = parts[i++],
+ type: "text" // "c9searchresults.keyword"
+ }, {
+ value: "'" + parts[i++],
+ type: "text"
+ }];
+ if (parts[2] !== " in") {
+ replace = parts[i];
+ tokens.push({
+ value: "'" + parts[i++] + "'",
+ type: "text"
+ }, {
+ value: parts[i++],
+ type: "text"
+ });
+ }
+ tokens.push({
+ value: " " + parts[i++] + " ",
+ type: "text"
+ });
+ if (parts[i+1]) {
+ options = parts[i+1];
+ tokens.push({
+ value: "(" + parts[i+1] + ")",
+ type: "text"
+ });
+ i += 1;
+ } else {
+ i -= 1;
+ }
+ while (i++ < parts.length) {
+ parts[i] && tokens.push({
+ value: parts[i],
+ type: "text"
+ });
+ }
+
+ if (search) {
+ if (!/regex/.test(options))
+ search = lang.escapeRegExp(search);
+ if (/whole/.test(options))
+ search = "\\b" + search + "\\b";
+ }
+
+ var regex = search && safeCreateRegexp(
+ "(" + search + ")",
+ / sensitive/.test(options) ? "g" : "ig"
+ );
+ if (regex) {
+ stack[0] = state;
+ stack[1] = regex;
+ }
+
+ return tokens;
+ }
+ },
+ {
+ regex : "^(?=Found \\d+ matches)",
+ token : "text",
+ next : "numbers"
+ },
+ {
+ token : "string", // single line
+ regex : "^\\S:?[^:]+",
+ next : "numbers"
+ }
+ ],
+ numbers:[{
+ regex : "\\d+",
+ token : "constant.numeric"
+ }, {
+ regex : "$",
+ token : "text",
+ next : "start"
+ }]
+ };
+ this.normalizeRules();
+};
+
+oop.inherits(C9SearchHighlightRules, TextHighlightRules);
+
+exports.C9SearchHighlightRules = C9SearchHighlightRules;
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/c9search",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /^(\S.*:|Searching for.*)$/;
+ this.foldingStopMarker = /^(\s+|Found.*)$/;
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var lines = session.doc.getAllLines(row);
+ var line = lines[row];
+ var level1 = /^(Found.*|Searching for.*)$/;
+ var level2 = /^(\S.*:|\s*)$/;
+ var re = level1.test(line) ? level1 : level2;
+
+ var startRow = row;
+ var endRow = row;
+
+ if (this.foldingStartMarker.test(line)) {
+ for (var i = row + 1, l = session.getLength(); i < l; i++) {
+ if (re.test(lines[i]))
+ break;
+ }
+ endRow = i;
+ }
+ else if (this.foldingStopMarker.test(line)) {
+ for (var i = row - 1; i >= 0; i--) {
+ line = lines[i];
+ if (re.test(line))
+ break;
+ }
+ startRow = i;
+ }
+ if (startRow != endRow) {
+ var col = line.length;
+ if (re === level1)
+ col = line.search(/\(Found[^)]+\)$|$/);
+ return new Range(startRow, col, endRow, 0);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/c9search",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c9search_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/c9search"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var C9SearchHighlightRules = require("./c9search_highlight_rules").C9SearchHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var C9StyleFoldMode = require("./folding/c9search").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = C9SearchHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new C9StyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/c9search";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-c_cpp.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-c_cpp.js
new file mode 100644
index 00000000..ea6d2229
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-c_cpp.js
@@ -0,0 +1,487 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/c_cpp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var cFunctions = exports.cFunctions = "\\b(?:hypot(?:f|l)?|s(?:scanf|ystem|nprintf|ca(?:nf|lb(?:n(?:f|l)?|ln(?:f|l)?))|i(?:n(?:h(?:f|l)?|f|l)?|gn(?:al|bit))|tr(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?)|error|pbrk|ftime|len|rchr|xfrm)|printf|et(?:jmp|vbuf|locale|buf)|qrt(?:f|l)?|w(?:scanf|printf)|rand)|n(?:e(?:arbyint(?:f|l)?|xt(?:toward(?:f|l)?|after(?:f|l)?))|an(?:f|l)?)|c(?:s(?:in(?:h(?:f|l)?|f|l)?|qrt(?:f|l)?)|cos(?:h(?:f)?|f|l)?|imag(?:f|l)?|t(?:ime|an(?:h(?:f|l)?|f|l)?)|o(?:s(?:h(?:f|l)?|f|l)?|nj(?:f|l)?|pysign(?:f|l)?)|p(?:ow(?:f|l)?|roj(?:f|l)?)|e(?:il(?:f|l)?|xp(?:f|l)?)|l(?:o(?:ck|g(?:f|l)?)|earerr)|a(?:sin(?:h(?:f|l)?|f|l)?|cos(?:h(?:f|l)?|f|l)?|tan(?:h(?:f|l)?|f|l)?|lloc|rg(?:f|l)?|bs(?:f|l)?)|real(?:f|l)?|brt(?:f|l)?)|t(?:ime|o(?:upper|lower)|an(?:h(?:f|l)?|f|l)?|runc(?:f|l)?|gamma(?:f|l)?|mp(?:nam|file))|i(?:s(?:space|n(?:ormal|an)|cntrl|inf|digit|u(?:nordered|pper)|p(?:unct|rint)|finite|w(?:space|c(?:ntrl|type)|digit|upper|p(?:unct|rint)|lower|al(?:num|pha)|graph|xdigit|blank)|l(?:ower|ess(?:equal|greater)?)|al(?:num|pha)|gr(?:eater(?:equal)?|aph)|xdigit|blank)|logb(?:f|l)?|max(?:div|abs))|di(?:v|fftime)|_Exit|unget(?:c|wc)|p(?:ow(?:f|l)?|ut(?:s|c(?:har)?|wc(?:har)?)|error|rintf)|e(?:rf(?:c(?:f|l)?|f|l)?|x(?:it|p(?:2(?:f|l)?|f|l|m1(?:f|l)?)?))|v(?:s(?:scanf|nprintf|canf|printf|w(?:scanf|printf))|printf|f(?:scanf|printf|w(?:scanf|printf))|w(?:scanf|printf)|a_(?:start|copy|end|arg))|qsort|f(?:s(?:canf|e(?:tpos|ek))|close|tell|open|dim(?:f|l)?|p(?:classify|ut(?:s|c|w(?:s|c))|rintf)|e(?:holdexcept|set(?:e(?:nv|xceptflag)|round)|clearexcept|testexcept|of|updateenv|r(?:aiseexcept|ror)|get(?:e(?:nv|xceptflag)|round))|flush|w(?:scanf|ide|printf|rite)|loor(?:f|l)?|abs(?:f|l)?|get(?:s|c|pos|w(?:s|c))|re(?:open|e|ad|xp(?:f|l)?)|m(?:in(?:f|l)?|od(?:f|l)?|a(?:f|l|x(?:f|l)?)?))|l(?:d(?:iv|exp(?:f|l)?)|o(?:ngjmp|cal(?:time|econv)|g(?:1(?:p(?:f|l)?|0(?:f|l)?)|2(?:f|l)?|f|l|b(?:f|l)?)?)|abs|l(?:div|abs|r(?:int(?:f|l)?|ound(?:f|l)?))|r(?:int(?:f|l)?|ound(?:f|l)?)|gamma(?:f|l)?)|w(?:scanf|c(?:s(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?|mbs)|pbrk|ftime|len|r(?:chr|tombs)|xfrm)|to(?:b|mb)|rtomb)|printf|mem(?:set|c(?:hr|py|mp)|move))|a(?:s(?:sert|ctime|in(?:h(?:f|l)?|f|l)?)|cos(?:h(?:f|l)?|f|l)?|t(?:o(?:i|f|l(?:l)?)|exit|an(?:h(?:f|l)?|2(?:f|l)?|f|l)?)|b(?:s|ort))|g(?:et(?:s|c(?:har)?|env|wc(?:har)?)|mtime)|r(?:int(?:f|l)?|ound(?:f|l)?|e(?:name|alloc|wind|m(?:ove|quo(?:f|l)?|ainder(?:f|l)?))|a(?:nd|ise))|b(?:search|towc)|m(?:odf(?:f|l)?|em(?:set|c(?:hr|py|mp)|move)|ktime|alloc|b(?:s(?:init|towcs|rtowcs)|towc|len|r(?:towc|len))))\\b"
+
+var c_cppHighlightRules = function() {
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|goto|if|_Pragma|" +
+ "return|switch|while|catch|operator|try|throw|using"
+ );
+
+ var storageType = (
+ "asm|__asm__|auto|bool|_Bool|char|_Complex|double|enum|float|" +
+ "_Imaginary|int|long|short|signed|struct|typedef|union|unsigned|void|" +
+ "class|wchar_t|template|char16_t|char32_t"
+ );
+
+ var storageModifiers = (
+ "const|extern|register|restrict|static|volatile|inline|private|" +
+ "protected|public|friend|explicit|virtual|export|mutable|typename|" +
+ "constexpr|new|delete|alignas|alignof|decltype|noexcept|thread_local"
+ );
+
+ var keywordOperators = (
+ "and|and_eq|bitand|bitor|compl|not|not_eq|or|or_eq|typeid|xor|xor_eq" +
+ "const_cast|dynamic_cast|reinterpret_cast|static_cast|sizeof|namespace"
+ );
+
+ var builtinConstants = (
+ "NULL|true|false|TRUE|FALSE|nullptr"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.control" : keywordControls,
+ "storage.type" : storageType,
+ "storage.modifier" : storageModifiers,
+ "keyword.operator" : keywordOperators,
+ "variable.language": "this",
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+ var escapeRe = /\\(?:['"?\\abfnrtv]|[0-7]{1,3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}U[a-fA-F\d]{8}|.)/.source;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "//$",
+ next : "start"
+ }, {
+ token : "comment",
+ regex : "//",
+ next : "singleLineComment"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : "'(?:" + escapeRe + "|.)?'"
+ }, {
+ token : "string.start",
+ regex : '"',
+ stateName: "qqstring",
+ next: [
+ { token: "string", regex: /\\\s*$/, next: "qqstring" },
+ { token: "constant.language.escape", regex: escapeRe },
+ { token: "constant.language.escape", regex: /%[^'"\\]/ },
+ { token: "string.end", regex: '"|$', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "string.start",
+ regex : 'R"\\(',
+ stateName: "rawString",
+ next: [
+ { token: "string.end", regex: '\\)"', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|pragma|line|define|undef)\\b",
+ next : "directive"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|if|ifdef|else|elif|ifndef)\\b"
+ }, {
+ token : "support.function.C99.c",
+ regex : cFunctions
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|<<=|>>=|>>>=|<>|&&|\|\||\?:|[*%\/+\-&\^|~!<>=]=?/
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "singleLineComment" : [
+ {
+ token : "comment",
+ regex : /\\$/,
+ next : "singleLineComment"
+ }, {
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ],
+ "directive" : [
+ {
+ token : "constant.other.multiline",
+ regex : /\\/
+ },
+ {
+ token : "constant.other.multiline",
+ regex : /.*\\/
+ },
+ {
+ token : "constant.other",
+ regex : "\\s*<.+?>",
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : '\\s*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]',
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
+ next : "start"
+ },
+ {
+ token : "constant.other",
+ regex : /[^\\\/]+/,
+ next : "start"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(c_cppHighlightRules, TextHighlightRules);
+
+exports.c_cppHighlightRules = c_cppHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/c_cpp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c_cpp_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var c_cppHighlightRules = require("./c_cpp_highlight_rules").c_cppHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = c_cppHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/c_cpp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-cirru.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-cirru.js
new file mode 100644
index 00000000..9d3bab85
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-cirru.js
@@ -0,0 +1,203 @@
+ace.define("ace/mode/cirru_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var CirruHighlightRules = function() {
+ this.$rules = {
+ start: [{
+ token: 'constant.numeric',
+ regex: /[\d\.]+/
+ }, {
+ token: 'comment.line.double-dash',
+ regex: /--/,
+ next: 'comment'
+ }, {
+ token: 'storage.modifier',
+ regex: /\(/
+ }, {
+ token: 'storage.modifier',
+ regex: /,/,
+ next: 'line'
+ }, {
+ token: 'support.function',
+ regex: /[^\(\)"\s]+/,
+ next: 'line'
+ }, {
+ token: 'string.quoted.double',
+ regex: /"/,
+ next: 'string'
+ }, {
+ token: 'storage.modifier',
+ regex: /\)/
+ }],
+ comment: [{
+ token: 'comment.line.double-dash',
+ regex: / +[^\n]+/,
+ next: 'start'
+ }],
+ string: [{
+ token: 'string.quoted.double',
+ regex: /"/,
+ next: 'line'
+ }, {
+ token: 'constant.character.escape',
+ regex: /\\/,
+ next: 'escape'
+ }, {
+ token: 'string.quoted.double',
+ regex: /[^\\"]+/
+ }],
+ escape: [{
+ token: 'constant.character.escape',
+ regex: /./,
+ next: 'string'
+ }],
+ line: [{
+ token: 'constant.numeric',
+ regex: /[\d\.]+/
+ }, {
+ token: 'markup.raw',
+ regex: /^\s*/,
+ next: 'start'
+ }, {
+ token: 'storage.modifier',
+ regex: /\$/,
+ next: 'start'
+ }, {
+ token: 'variable.parameter',
+ regex: /[^\(\)"\s]+/
+ }, {
+ token: 'storage.modifier',
+ regex: /\(/,
+ next: 'start'
+ }, {
+ token: 'storage.modifier',
+ regex: /\)/
+ }, {
+ token: 'markup.raw',
+ regex: /^ */,
+ next: 'start'
+ }, {
+ token: 'string.quoted.double',
+ regex: /"/,
+ next: 'string'
+ }]
+ }
+
+};
+
+oop.inherits(CirruHighlightRules, TextHighlightRules);
+
+exports.CirruHighlightRules = CirruHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/cirru",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/cirru_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CirruHighlightRules = require("./cirru_highlight_rules").CirruHighlightRules;
+var CoffeeFoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CirruHighlightRules;
+ this.foldingRules = new CoffeeFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.$id = "ace/mode/cirru";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-clojure.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-clojure.js
new file mode 100644
index 00000000..c8f7a0d5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-clojure.js
@@ -0,0 +1,307 @@
+ace.define("ace/mode/clojure_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+
+
+var ClojureHighlightRules = function() {
+
+ var builtinFunctions = (
+ '* *1 *2 *3 *agent* *allow-unresolved-vars* *assert* *clojure-version* ' +
+ '*command-line-args* *compile-files* *compile-path* *e *err* *file* ' +
+ '*flush-on-newline* *in* *macro-meta* *math-context* *ns* *out* ' +
+ '*print-dup* *print-length* *print-level* *print-meta* *print-readably* ' +
+ '*read-eval* *source-path* *use-context-classloader* ' +
+ '*warn-on-reflection* + - -> ->> .. / < <= = ' +
+ '== > &gt; >= &gt;= accessor aclone ' +
+ 'add-classpath add-watch agent agent-errors aget alength alias all-ns ' +
+ 'alter alter-meta! alter-var-root amap ancestors and apply areduce ' +
+ 'array-map aset aset-boolean aset-byte aset-char aset-double aset-float ' +
+ 'aset-int aset-long aset-short assert assoc assoc! assoc-in associative? ' +
+ 'atom await await-for await1 bases bean bigdec bigint binding bit-and ' +
+ 'bit-and-not bit-clear bit-flip bit-not bit-or bit-set bit-shift-left ' +
+ 'bit-shift-right bit-test bit-xor boolean boolean-array booleans ' +
+ 'bound-fn bound-fn* butlast byte byte-array bytes cast char char-array ' +
+ 'char-escape-string char-name-string char? chars chunk chunk-append ' +
+ 'chunk-buffer chunk-cons chunk-first chunk-next chunk-rest chunked-seq? ' +
+ 'class class? clear-agent-errors clojure-version coll? comment commute ' +
+ 'comp comparator compare compare-and-set! compile complement concat cond ' +
+ 'condp conj conj! cons constantly construct-proxy contains? count ' +
+ 'counted? create-ns create-struct cycle dec decimal? declare definline ' +
+ 'defmacro defmethod defmulti defn defn- defonce defstruct delay delay? ' +
+ 'deliver deref derive descendants destructure disj disj! dissoc dissoc! ' +
+ 'distinct distinct? doall doc dorun doseq dosync dotimes doto double ' +
+ 'double-array doubles drop drop-last drop-while empty empty? ensure ' +
+ 'enumeration-seq eval even? every? false? ffirst file-seq filter find ' +
+ 'find-doc find-ns find-var first float float-array float? floats flush ' +
+ 'fn fn? fnext for force format future future-call future-cancel ' +
+ 'future-cancelled? future-done? future? gen-class gen-interface gensym ' +
+ 'get get-in get-method get-proxy-class get-thread-bindings get-validator ' +
+ 'hash hash-map hash-set identical? identity if-let if-not ifn? import ' +
+ 'in-ns inc init-proxy instance? int int-array integer? interleave intern ' +
+ 'interpose into into-array ints io! isa? iterate iterator-seq juxt key ' +
+ 'keys keyword keyword? last lazy-cat lazy-seq let letfn line-seq list ' +
+ 'list* list? load load-file load-reader load-string loaded-libs locking ' +
+ 'long long-array longs loop macroexpand macroexpand-1 make-array ' +
+ 'make-hierarchy map map? mapcat max max-key memfn memoize merge ' +
+ 'merge-with meta method-sig methods min min-key mod name namespace neg? ' +
+ 'newline next nfirst nil? nnext not not-any? not-empty not-every? not= ' +
+ 'ns ns-aliases ns-imports ns-interns ns-map ns-name ns-publics ' +
+ 'ns-refers ns-resolve ns-unalias ns-unmap nth nthnext num number? odd? ' +
+ 'or parents partial partition pcalls peek persistent! pmap pop pop! ' +
+ 'pop-thread-bindings pos? pr pr-str prefer-method prefers ' +
+ 'primitives-classnames print print-ctor print-doc print-dup print-method ' +
+ 'print-namespace-doc print-simple print-special-doc print-str printf ' +
+ 'println println-str prn prn-str promise proxy proxy-call-with-super ' +
+ 'proxy-mappings proxy-name proxy-super push-thread-bindings pvalues quot ' +
+ 'rand rand-int range ratio? rational? rationalize re-find re-groups ' +
+ 're-matcher re-matches re-pattern re-seq read read-line read-string ' +
+ 'reduce ref ref-history-count ref-max-history ref-min-history ref-set ' +
+ 'refer refer-clojure release-pending-sends rem remove remove-method ' +
+ 'remove-ns remove-watch repeat repeatedly replace replicate require ' +
+ 'reset! reset-meta! resolve rest resultset-seq reverse reversible? rseq ' +
+ 'rsubseq second select-keys send send-off seq seq? seque sequence ' +
+ 'sequential? set set-validator! set? short short-array shorts ' +
+ 'shutdown-agents slurp some sort sort-by sorted-map sorted-map-by ' +
+ 'sorted-set sorted-set-by sorted? special-form-anchor special-symbol? ' +
+ 'split-at split-with str stream? string? struct struct-map subs subseq ' +
+ 'subvec supers swap! symbol symbol? sync syntax-symbol-anchor take ' +
+ 'take-last take-nth take-while test the-ns time to-array to-array-2d ' +
+ 'trampoline transient tree-seq true? type unchecked-add unchecked-dec ' +
+ 'unchecked-divide unchecked-inc unchecked-multiply unchecked-negate ' +
+ 'unchecked-remainder unchecked-subtract underive unquote ' +
+ 'unquote-splicing update-in update-proxy use val vals var-get var-set ' +
+ 'var? vary-meta vec vector vector? when when-first when-let when-not ' +
+ 'while with-bindings with-bindings* with-in-str with-loading-context ' +
+ 'with-local-vars with-meta with-open with-out-str with-precision xml-seq ' +
+ 'zero? zipmap'
+ );
+
+ var keywords = ('throw try var ' +
+ 'def do fn if let loop monitor-enter monitor-exit new quote recur set!'
+ );
+
+ var buildinConstants = ("true false nil");
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": builtinFunctions
+ }, "identifier", false, " ");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : ";.*$"
+ }, {
+ token : "keyword", //parens
+ regex : "[\\(|\\)]"
+ }, {
+ token : "keyword", //lists
+ regex : "[\\'\\(]"
+ }, {
+ token : "keyword", //vectors
+ regex : "[\\[|\\]]"
+ }, {
+ token : "keyword", //sets and maps
+ regex : "[\\{|\\}|\\#\\{|\\#\\}]"
+ }, {
+ token : "keyword", // ampersands
+ regex : '[\\&]'
+ }, {
+ token : "keyword", // metadata
+ regex : '[\\#\\^\\{]'
+ }, {
+ token : "keyword", // anonymous fn syntactic sugar
+ regex : '[\\%]'
+ }, {
+ token : "keyword", // deref reader macro
+ regex : '[@]'
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language",
+ regex : '[!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+||=|!=|<=|>=|<>|<|>|!|&&]'
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$\\-]*\\b"
+ }, {
+ token : "string", // single line
+ regex : '"',
+ next: "string"
+ }, {
+ token : "constant", // symbol
+ regex : /:[^()\[\]{}'"\^%`,;\s]+/
+ }, {
+ token : "string.regexp", //Regular Expressions
+ regex : '/#"(?:\\.|(?:\\")|[^""\n])*"/g'
+ }
+
+ ],
+ "string" : [
+ {
+ token : "constant.language.escape",
+ regex : "\\\\.|\\\\$"
+ }, {
+ token : "string",
+ regex : '[^"\\\\]+'
+ }, {
+ token : "string",
+ regex : '"',
+ next : "start"
+ }
+ ]
+ };
+};
+
+oop.inherits(ClojureHighlightRules, TextHighlightRules);
+
+exports.ClojureHighlightRules = ClojureHighlightRules;
+});
+
+ace.define("ace/mode/matching_parens_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingParensOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\)/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\))/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ var match = line.match(/^(\s+)/);
+ if (match) {
+ return match[1];
+ }
+
+ return "";
+ };
+
+}).call(MatchingParensOutdent.prototype);
+
+exports.MatchingParensOutdent = MatchingParensOutdent;
+});
+
+ace.define("ace/mode/clojure",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/clojure_highlight_rules","ace/mode/matching_parens_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ClojureHighlightRules = require("./clojure_highlight_rules").ClojureHighlightRules;
+var MatchingParensOutdent = require("./matching_parens_outdent").MatchingParensOutdent;
+
+var Mode = function() {
+ this.HighlightRules = ClojureHighlightRules;
+ this.$outdent = new MatchingParensOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ";";
+ this.minorIndentFunctions = ["defn", "defn-", "defmacro", "def", "deftest", "testing"];
+
+ this.$toIndent = function(str) {
+ return str.split('').map(function(ch) {
+ if (/\s/.exec(ch)) {
+ return ch;
+ } else {
+ return ' ';
+ }
+ }).join('');
+ };
+
+ this.$calculateIndent = function(line, tab) {
+ var baseIndent = this.$getIndent(line);
+ var delta = 0;
+ var isParen, ch;
+ for (var i = line.length - 1; i >= 0; i--) {
+ ch = line[i];
+ if (ch === '(') {
+ delta--;
+ isParen = true;
+ } else if (ch === '(' || ch === '[' || ch === '{') {
+ delta--;
+ isParen = false;
+ } else if (ch === ')' || ch === ']' || ch === '}') {
+ delta++;
+ }
+ if (delta < 0) {
+ break;
+ }
+ }
+ if (delta < 0 && isParen) {
+ i += 1;
+ var iBefore = i;
+ var fn = '';
+ while (true) {
+ ch = line[i];
+ if (ch === ' ' || ch === '\t') {
+ if(this.minorIndentFunctions.indexOf(fn) !== -1) {
+ return this.$toIndent(line.substring(0, iBefore - 1) + tab);
+ } else {
+ return this.$toIndent(line.substring(0, i + 1));
+ }
+ } else if (ch === undefined) {
+ return this.$toIndent(line.substring(0, iBefore - 1) + tab);
+ }
+ fn += line[i];
+ i++;
+ }
+ } else if(delta < 0 && !isParen) {
+ return this.$toIndent(line.substring(0, i+1));
+ } else if(delta > 0) {
+ baseIndent = baseIndent.substring(0, baseIndent.length - tab.length);
+ return baseIndent;
+ } else {
+ return baseIndent;
+ }
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$calculateIndent(line, tab);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/clojure";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-cobol.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-cobol.js
new file mode 100644
index 00000000..89367e00
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-cobol.js
@@ -0,0 +1,94 @@
+ace.define("ace/mode/cobol_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var CobolHighlightRules = function() {
+var keywords = "ACCEPT|MERGE|SUM|ADD||MESSAGE|TABLE|ADVANCING|MODE|TAPE|" +
+"AFTER|MULTIPLY|TEST|ALL|NEGATIVE|TEXT|ALPHABET|NEXT|THAN|" +
+"ALSO|NO|THEN|ALTERNATE|NOT|THROUGH|AND|NUMBER|THRU|ANY|OCCURS|" +
+"TIME|ARE|OF|TO|AREA|OFF|TOP||ASCENDING|OMITTED|TRUE|ASSIGN|ON|TYPE|AT|OPEN|" +
+"UNIT|AUTHOR|OR|UNTIL|BEFORE|OTHER|UP|BLANK|OUTPUT|USE|BLOCK|PAGE|USING|BOTTOM|" +
+"PERFORM|VALUE|BY|PIC|VALUES|CALL|PICTURE|WHEN|CANCEL|PLUS|WITH|CD|POINTER|WRITE|" +
+"CHARACTER|POSITION||ZERO|CLOSE|POSITIVE|ZEROS|COLUMN|PROCEDURE|ZEROES|COMMA|PROGRAM|" +
+"COMMON|PROGRAM-ID|COMMUNICATION|QUOTE|COMP|RANDOM|COMPUTE|READ|CONTAINS|RECEIVE|CONFIGURATION|" +
+"RECORD|CONTINUE|REDEFINES|CONTROL|REFERENCE|COPY|REMAINDER|COUNT|REPLACE|DATA|REPORT|DATE|RESERVE|" +
+"DAY|RESET|DELETE|RETURN|DESTINATION|REWIND|DISABLE|REWRITE|DISPLAY|RIGHT|DIVIDE|RUN|DOWN|SAME|" +
+"ELSE|SEARCH|ENABLE|SECTION|END|SELECT|ENVIRONMENT|SENTENCE|EQUAL|SET|ERROR|SIGN|EXIT|SEQUENTIAL|" +
+"EXTERNAL|SIZE|FLASE|SORT|FILE|SOURCE|LENGTH|SPACE|LESS|STANDARD|LIMIT|START|LINE|STOP|LOCK|STRING|LOW-VALUE|SUBTRACT";
+
+ var builtinConstants = (
+ "true|false|null"
+ );
+
+ var builtinFunctions = (
+ "count|min|max|avg|sum|rank|now|coalesce|main"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords,
+ "constant.language": builtinConstants
+ }, "identifier", true);
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "\\*.*$"
+ }, {
+ token : "string", // " string
+ regex : '".*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'.*?'"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+ };
+};
+
+oop.inherits(CobolHighlightRules, TextHighlightRules);
+
+exports.CobolHighlightRules = CobolHighlightRules;
+});
+
+ace.define("ace/mode/cobol",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/cobol_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CobolHighlightRules = require("./cobol_highlight_rules").CobolHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = CobolHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "*";
+
+ this.$id = "ace/mode/cobol";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-coffee.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-coffee.js
new file mode 100644
index 00000000..5ba85894
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-coffee.js
@@ -0,0 +1,392 @@
+ace.define("ace/mode/coffee_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+ var oop = require("../lib/oop");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ oop.inherits(CoffeeHighlightRules, TextHighlightRules);
+
+ function CoffeeHighlightRules() {
+ var identifier = "[$A-Za-z_\\x7f-\\uffff][$\\w\\x7f-\\uffff]*";
+
+ var keywords = (
+ "this|throw|then|try|typeof|super|switch|return|break|by|continue|" +
+ "catch|class|in|instanceof|is|isnt|if|else|extends|for|own|" +
+ "finally|function|while|when|new|no|not|delete|debugger|do|loop|of|off|" +
+ "or|on|unless|until|and|yes"
+ );
+
+ var langConstant = (
+ "true|false|null|undefined|NaN|Infinity"
+ );
+
+ var illegal = (
+ "case|const|default|function|var|void|with|enum|export|implements|" +
+ "interface|let|package|private|protected|public|static|yield"
+ );
+
+ var supportClass = (
+ "Array|Boolean|Date|Function|Number|Object|RegExp|ReferenceError|String|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" +
+ "SyntaxError|TypeError|URIError|" +
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray"
+ );
+
+ var supportFunction = (
+ "Math|JSON|isNaN|isFinite|parseInt|parseFloat|encodeURI|" +
+ "encodeURIComponent|decodeURI|decodeURIComponent|String|"
+ );
+
+ var variableLanguage = (
+ "window|arguments|prototype|document"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": langConstant,
+ "invalid.illegal": illegal,
+ "language.support.class": supportClass,
+ "language.support.function": supportFunction,
+ "variable.language": variableLanguage
+ }, "identifier");
+
+ var functionRule = {
+ token: ["paren.lparen", "variable.parameter", "paren.rparen", "text", "storage.type"],
+ regex: /(?:(\()((?:"[^")]*?"|'[^')]*?'|\/[^\/)]*?\/|[^()"'\/])*?)(\))(\s*))?([\-=]>)/.source
+ };
+
+ var stringEscape = /\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|[0-2][0-7]{0,2}|3[0-6][0-7]?|37[0-7]?|[4-7][0-7]?|.)/;
+
+ this.$rules = {
+ start : [
+ {
+ token : "constant.numeric",
+ regex : "(?:0x[\\da-fA-F]+|(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[eE][+-]?\\d+)?)"
+ }, {
+ stateName: "qdoc",
+ token : "string", regex : "'''", next : [
+ {token : "string", regex : "'''", next : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "qqdoc",
+ token : "string",
+ regex : '"""',
+ next : [
+ {token : "string", regex : '"""', next : "start"},
+ {token : "paren.string", regex : '#{', push : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "qstring",
+ token : "string", regex : "'", next : [
+ {token : "string", regex : "'", next : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "qqstring",
+ token : "string.start", regex : '"', next : [
+ {token : "string.end", regex : '"', next : "start"},
+ {token : "paren.string", regex : '#{', push : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "js",
+ token : "string", regex : "`", next : [
+ {token : "string", regex : "`", next : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ return "paren";
+ }
+ if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift() || "";
+ if (this.next.indexOf("string") != -1)
+ return "paren.string";
+ }
+ return "paren";
+ }
+ }, {
+ token : "string.regex",
+ regex : "///",
+ next : "heregex"
+ }, {
+ token : "string.regex",
+ regex : /(?:\/(?![\s=])[^[\/\n\\]*(?:(?:\\[\s\S]|\[[^\]\n\\]*(?:\\[\s\S][^\]\n\\]*)*])[^[\/\n\\]*)*\/)(?:[imgy]{0,4})(?!\w)/
+ }, {
+ token : "comment",
+ regex : "###(?!#)",
+ next : "comment"
+ }, {
+ token : "comment",
+ regex : "#.*"
+ }, {
+ token : ["punctuation.operator", "text", "identifier"],
+ regex : "(\\.)(\\s*)(" + illegal + ")"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\.{1,3}"
+ }, {
+ token : ["keyword", "text", "language.support.class",
+ "text", "keyword", "text", "language.support.class"],
+ regex : "(class)(\\s+)(" + identifier + ")(?:(\\s+)(extends)(\\s+)(" + identifier + "))?"
+ }, {
+ token : ["entity.name.function", "text", "keyword.operator", "text"].concat(functionRule.token),
+ regex : "(" + identifier + ")(\\s*)([=:])(\\s*)" + functionRule.regex
+ },
+ functionRule,
+ {
+ token : "variable",
+ regex : "@(?:" + identifier + ")?"
+ }, {
+ token: keywordMapper,
+ regex : identifier
+ }, {
+ token : "punctuation.operator",
+ regex : "\\,|\\."
+ }, {
+ token : "storage.type",
+ regex : "[\\-=]>"
+ }, {
+ token : "keyword.operator",
+ regex : "(?:[-+*/%<>&|^!?=]=|>>>=?|\\-\\-|\\+\\+|::|&&=|\\|\\|=|<<=|>>=|\\?\\.|\\.{2,3}|[!*+-=><])"
+ }, {
+ token : "paren.lparen",
+ regex : "[({[]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]})]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }],
+
+
+ heregex : [{
+ token : "string.regex",
+ regex : '.*?///[imgy]{0,4}',
+ next : "start"
+ }, {
+ token : "comment.regex",
+ regex : "\\s+(?:#.*)?"
+ }, {
+ token : "string.regex",
+ regex : "\\S+"
+ }],
+
+ comment : [{
+ token : "comment",
+ regex : '###',
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }]
+ };
+ this.normalizeRules();
+ }
+
+ exports.CoffeeHighlightRules = CoffeeHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/coffee",["require","exports","module","ace/mode/coffee_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/coffee","ace/range","ace/mode/text","ace/worker/worker_client","ace/lib/oop"], function(require, exports, module) {
+"use strict";
+
+var Rules = require("./coffee_highlight_rules").CoffeeHighlightRules;
+var Outdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var FoldMode = require("./folding/coffee").FoldMode;
+var Range = require("../range").Range;
+var TextMode = require("./text").Mode;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var oop = require("../lib/oop");
+
+function Mode() {
+ this.HighlightRules = Rules;
+ this.$outdent = new Outdent();
+ this.foldingRules = new FoldMode();
+}
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+ var indenter = /(?:[({[=:]|[-=]>|\b(?:else|try|(?:swi|ca)tch(?:\s+[$A-Za-z_\x7f-\uffff][$\w\x7f-\uffff]*)?|finally))\s*$|^\s*(else\b\s*)?(?:if|for|while|loop)\b(?!.*\bthen\b)/;
+
+ this.lineCommentStart = "#";
+ this.blockComment = {start: "###", end: "###"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+
+ if (!(tokens.length && tokens[tokens.length - 1].type === 'comment') &&
+ state === 'start' && indenter.test(line))
+ indent += tab;
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/coffee_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/coffee";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-coldfusion.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-coldfusion.js
new file mode 100644
index 00000000..edbdb5b4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-coldfusion.js
@@ -0,0 +1,2567 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/coldfusion_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/javascript_highlight_rules","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var ColdfusionHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+ this.$rules.tag[2].token = function (start, tag) {
+ var group = tag.slice(0,2) == "cf" ? "keyword" : "meta.tag";
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ group + ".tag-name.xml"];
+ }
+
+ var jsAndCss = Object.keys(this.$rules).filter(function(x) {
+ return /^(js|css)-/.test(x);
+ });
+ this.embedRules({
+ cfmlComment: [
+ { regex: "<!---", token: "comment.start", push: "cfmlComment"},
+ { regex: "--->", token: "comment.end", next: "pop"},
+ { defaultToken: "comment"}
+ ]
+ }, "", [
+ { regex: "<!---", token: "comment.start", push: "cfmlComment"}
+ ], [
+ "comment", "start", "tag_whitespace", "cdata"
+ ].concat(jsAndCss));
+
+
+ this.$rules.cfTag = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "pop"}
+ ];
+ var cfTag = {
+ token : function(start, tag) {
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "keyword.tag-name.xml"];
+ },
+ regex : "(</?)(cf[-_a-zA-Z0-9:.]+)",
+ push: "cfTag"
+ };
+ jsAndCss.forEach(function(s) {
+ this.$rules[s].unshift(cfTag);
+ }, this);
+
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "cfjs-", "cfscript");
+
+ this.normalizeRules();
+};
+
+oop.inherits(ColdfusionHighlightRules, HtmlHighlightRules);
+
+exports.ColdfusionHighlightRules = ColdfusionHighlightRules;
+});
+
+ace.define("ace/mode/coldfusion",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/html","ace/mode/coldfusion_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var HtmlMode = require("./html").Mode;
+var ColdfusionHighlightRules = require("./coldfusion_highlight_rules").ColdfusionHighlightRules;
+
+var voidElements = "cfabort|cfapplication|cfargument|cfassociate|cfbreak|cfcache|cfcollection|cfcookie|cfdbinfo|cfdirectory|cfdump|cfelse|cfelseif|cferror|cfexchangecalendar|cfexchangeconnection|cfexchangecontact|cfexchangefilter|cfexchangetask|cfexit|cffeed|cffile|cfflush|cfftp|cfheader|cfhtmlhead|cfhttpparam|cfimage|cfimport|cfinclude|cfindex|cfinsert|cfinvokeargument|cflocation|cflog|cfmailparam|cfNTauthenticate|cfobject|cfobjectcache|cfparam|cfpdfformparam|cfprint|cfprocparam|cfprocresult|cfproperty|cfqueryparam|cfregistry|cfreportparam|cfrethrow|cfreturn|cfschedule|cfsearch|cfset|cfsetting|cfthrow|cfzipparam)".split("|");
+
+var Mode = function() {
+ HtmlMode.call(this);
+
+ this.HighlightRules = ColdfusionHighlightRules;
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.voidElements = oop.mixin(lang.arrayToMap(voidElements), this.voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.$id = "ace/mode/coldfusion";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-csharp.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-csharp.js
new file mode 100644
index 00000000..d91e9985
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-csharp.js
@@ -0,0 +1,495 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/csharp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var CSharpHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": "abstract|event|new|struct|as|explicit|null|switch|base|extern|object|this|bool|false|operator|throw|break|finally|out|true|byte|fixed|override|try|case|float|params|typeof|catch|for|private|uint|char|foreach|protected|ulong|checked|goto|public|unchecked|class|if|readonly|unsafe|const|implicit|ref|ushort|continue|in|return|using|decimal|int|sbyte|virtual|default|interface|sealed|volatile|delegate|internal|short|void|do|is|sizeof|while|double|lock|stackalloc|else|long|static|enum|namespace|string|var|dynamic",
+ "constant.language": "null|true|false"
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : /'(?:.|\\(:?u[\da-fA-F]+|x[\da-fA-F]+|[tbrf'"n]))?'/
+ }, {
+ token : "string", start : '"', end : '"|$', next: [
+ {token: "constant.language.escape", regex: /\\(:?u[\da-fA-F]+|x[\da-fA-F]+|[tbrf'"n])/},
+ {token: "invalid", regex: /\\./}
+ ]
+ }, {
+ token : "string", start : '@"', end : '"', next:[
+ {token: "constant.language.escape", regex: '""'}
+ ]
+ }, {
+ token : "string", start : /\$"/, end : '"|$', next: [
+ {token: "constant.language.escape", regex: /\\(:?$)|{{/},
+ {token: "constant.language.escape", regex: /\\(:?u[\da-fA-F]+|x[\da-fA-F]+|[tbrf'"n])/},
+ {token: "invalid", regex: /\\./}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "keyword",
+ regex : "^\\s*#(if|else|elif|endif|define|undef|warning|error|line|region|endregion|pragma)"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(CSharpHighlightRules, TextHighlightRules);
+
+exports.CSharpHighlightRules = CSharpHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/csharp",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var CFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, CFoldMode);
+
+(function() {
+ this.usingRe = /^\s*using \S/;
+
+ this.getFoldWidgetRangeBase = this.getFoldWidgetRange;
+ this.getFoldWidgetBase = this.getFoldWidget;
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var fw = this.getFoldWidgetBase(session, foldStyle, row);
+ if (!fw) {
+ var line = session.getLine(row);
+ if (/^\s*#region\b/.test(line))
+ return "start";
+ var usingRe = this.usingRe;
+ if (usingRe.test(line)) {
+ var prev = session.getLine(row - 1);
+ var next = session.getLine(row + 1);
+ if (!usingRe.test(prev) && usingRe.test(next))
+ return "start"
+ }
+ }
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.getFoldWidgetRangeBase(session, foldStyle, row);
+ if (range)
+ return range;
+
+ var line = session.getLine(row);
+ if (this.usingRe.test(line))
+ return this.getUsingStatementBlock(session, line, row);
+
+ if (/^\s*#region\b/.test(line))
+ return this.getRegionBlock(session, line, row);
+ };
+
+ this.getUsingStatementBlock = function(session, line, row) {
+ var startColumn = line.match(this.usingRe)[0].length - 1;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ if (/^\s*$/.test(line))
+ continue;
+ if (!this.usingRe.test(line))
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+
+ this.getRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*#(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m)
+ continue;
+ if (m[1])
+ depth--;
+ else
+ depth++;
+
+ if (!depth)
+ break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/csharp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/csharp_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/csharp"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CSharpHighlightRules = require("./csharp_highlight_rules").CSharpHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/csharp").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CSharpHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/csharp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-css.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-css.js
new file mode 100644
index 00000000..b7a41850
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-css.js
@@ -0,0 +1,699 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-curly.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-curly.js
new file mode 100644
index 00000000..d6d9d1cb
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-curly.js
@@ -0,0 +1,2535 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/curly_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+
+var CurlyHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ this.$rules["start"].unshift({
+ token: "variable",
+ regex: "{{",
+ push: "curly-start"
+ });
+
+ this.$rules["curly-start"] = [{
+ token: "variable",
+ regex: "}}",
+ next: "pop"
+ }];
+
+ this.normalizeRules();
+};
+
+oop.inherits(CurlyHighlightRules, HtmlHighlightRules);
+
+exports.CurlyHighlightRules = CurlyHighlightRules;
+
+});
+
+ace.define("ace/mode/curly",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/matching_brace_outdent","ace/mode/folding/html","ace/mode/curly_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var CurlyHighlightRules = require("./curly_highlight_rules").CurlyHighlightRules;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = CurlyHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new HtmlFoldMode();
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.$id = "ace/mode/curly";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-d.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-d.js
new file mode 100644
index 00000000..672411a0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-d.js
@@ -0,0 +1,513 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/d_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DHighlightRules = function() {
+
+ var keywords = (
+ "this|super|import|module|body|mixin|__traits|invariant|alias|asm|delete|"+
+ "typeof|typeid|sizeof|cast|new|in|is|typedef|__vector|__parameters"
+ );
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|foreach|foreach_reverse|goto|if|" +
+ "return|switch|while|catch|try|throw|finally|version|assert|unittest|with"
+ );
+
+ var types = (
+ "auto|bool|char|dchar|wchar|byte|ubyte|float|double|real|" +
+ "cfloat|creal|cdouble|cent|ifloat|ireal|idouble|" +
+ "int|long|short|void|uint|ulong|ushort|ucent|" +
+ "function|delegate|string|wstring|dstring|size_t|ptrdiff_t|hash_t|Object"
+ );
+
+ var modifiers = (
+ "abstract|align|debug|deprecated|export|extern|const|final|in|inout|out|" +
+ "ref|immutable|lazy|nothrow|override|package|pragma|private|protected|" +
+ "public|pure|scope|shared|__gshared|synchronized|static|volatile"
+ );
+
+ var storages = (
+ "class|struct|union|template|interface|enum|macro"
+ );
+
+ var stringEscapesSeq = {
+ token: "constant.language.escape",
+ regex: "\\\\(?:(?:x[0-9A-F]{2})|(?:[0-7]{1,3})|(?:['\"\\?0abfnrtv\\\\])|" +
+ "(?:u[0-9a-fA-F]{4})|(?:U[0-9a-fA-F]{8}))"
+ };
+
+ var builtinConstants = (
+ "null|true|false|"+
+ "__DATE__|__EOF__|__TIME__|__TIMESTAMP__|__VENDOR__|__VERSION__|"+
+ "__FILE__|__MODULE__|__LINE__|__FUNCTION__|__PRETTY_FUNCTION__"
+ );
+
+ var operators = (
+ "/|/\\=|&|&\\=|&&|\\|\\|\\=|\\|\\||\\-|\\-\\=|\\-\\-|\\+|" +
+ "\\+\\=|\\+\\+|\\<|\\<\\=|\\<\\<|\\<\\<\\=|\\<\\>|\\<\\>\\=|\\>|\\>\\=|\\>\\>\\=|" +
+ "\\>\\>\\>\\=|\\>\\>|\\>\\>\\>|\\!|\\!\\=|\\!\\<\\>|\\!\\<\\>\\=|\\!\\<|\\!\\<\\=|" +
+ "\\!\\>|\\!\\>\\=|\\?|\\$|\\=|\\=\\=|\\*|\\*\\=|%|%\\=|" +
+ "\\^|\\^\\=|\\^\\^|\\^\\^\\=|~|~\\=|\\=\\>|#"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.modifier" : modifiers,
+ "keyword.control" : keywordControls,
+ "keyword.type" : types,
+ "keyword": keywords,
+ "keyword.storage": storages,
+ "punctation": "\\.|\\,|;|\\.\\.|\\.\\.\\.",
+ "keyword.operator" : operators,
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z_\u00a1-\uffff][a-zA-Z\\d_\u00a1-\uffff]*\\b";
+
+ this.$rules = {
+ "start" : [
+ { //-------------------------------------------------------- COMMENTS
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "star-comment"
+ }, {
+ token: "comment.shebang",
+ regex: "^\\s*#!.*"
+ }, {
+ token : "comment",
+ regex : "\\/\\+",
+ next: "plus-comment"
+ }, { //-------------------------------------------------------- STRINGS
+ onMatch: function(value, currentState, state) {
+ state.unshift(this.next, value.substr(2));
+ return "string";
+ },
+ regex: 'q"(?:[\\[\\(\\{\\<]+)',
+ next: 'operator-heredoc-string'
+ }, {
+ onMatch: function(value, currentState, state) {
+ state.unshift(this.next, value.substr(2));
+ return "string";
+ },
+ regex: 'q"(?:[a-zA-Z_]+)$',
+ next: 'identifier-heredoc-string'
+ }, {
+ token : "string", // multi line string start
+ regex : '[xr]?"',
+ next : "quote-string"
+ }, {
+ token : "string", // multi line string start
+ regex : '[xr]?`',
+ next : "backtick-string"
+ }, {
+ token : "string", // single line
+ regex : "[xr]?['](?:(?:\\\\.)|(?:[^'\\\\]))*?['][cdw]?"
+ }, { //-------------------------------------------------------- RULES
+ token: ["keyword", "text", "paren.lparen"],
+ regex: /(asm)(\s*)({)/,
+ next: "d-asm"
+ }, {
+ token: ["keyword", "text", "paren.lparen", "constant.language"],
+ regex: "(__traits)(\\s*)(\\()("+identifierRe+")"
+ }, { // import|module abc
+ token: ["keyword", "text", "variable.module"],
+ regex: "(import|module)(\\s+)((?:"+identifierRe+"\\.?)*)"
+ }, { // storage Name
+ token: ["keyword.storage", "text", "entity.name.type"],
+ regex: "("+storages+")(\\s*)("+identifierRe+")"
+ }, { // alias|typedef foo bar;
+ token: ["keyword", "text", "variable.storage", "text"],
+ regex: "(alias|typedef)(\\s*)("+identifierRe+")(\\s*)"
+ }, { //-------------------------------------------------------- OTHERS
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F_]+(l|ul|u|f|F|L|U|UL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d[\\d_]*(?:(?:\\.[\\d_]*)?(?:[eE][+-]?[\\d_]+)?)?(l|ul|u|f|F|L|U|UL)?\\b"
+ }, {
+ token: "entity.other.attribute-name",
+ regex: "@"+identifierRe
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_][a-zA-Z0-9_]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : operators
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\.|\\:"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "star-comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken: 'comment'
+ }
+ ],
+ "plus-comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\+\\/",
+ next : "start"
+ }, {
+ defaultToken: 'comment'
+ }
+ ],
+
+ "quote-string" : [
+ stringEscapesSeq,
+ {
+ token : "string",
+ regex : '"[cdw]?',
+ next : "start"
+ }, {
+ defaultToken: 'string'
+ }
+ ],
+
+ "backtick-string" : [
+ stringEscapesSeq,
+ {
+ token : "string",
+ regex : '`[cdw]?',
+ next : "start"
+ }, {
+ defaultToken: 'string'
+ }
+ ],
+
+ "operator-heredoc-string": [
+ {
+ onMatch: function(value, currentState, state) {
+ value = value.substring(value.length-2, value.length-1);
+ var map = {'>':'<',']':'[',')':'(','}':'{'};
+ if(Object.keys(map).indexOf(value) != -1)
+ value = map[value];
+ if(value != state[1]) return "string";
+ state.shift();
+ state.shift();
+
+ return "string";
+ },
+ regex: '(?:[\\]\\)}>]+)"',
+ next: 'start'
+ }, {
+ token: 'string',
+ regex: '[^\\]\\)}>]+'
+ }
+ ],
+
+ "identifier-heredoc-string": [
+ {
+ onMatch: function(value, currentState, state) {
+ value = value.substring(0, value.length-1);
+ if(value != state[1]) return "string";
+ state.shift();
+ state.shift();
+
+ return "string";
+ },
+ regex: '^(?:[A-Za-z_][a-zA-Z0-9]+)"',
+ next: 'start'
+ }, {
+ token: 'string',
+ regex: '[^\\]\\)}>]+'
+ }
+ ],
+
+ "d-asm": [
+ {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: 'keyword.instruction',
+ regex: '[a-zA-Z]+',
+ next: 'd-asm-instruction'
+ }, {
+ token: "text",
+ regex: "\\s+"
+ }
+ ],
+ 'd-asm-instruction': [
+ {
+ token: 'constant.language',
+ regex: /AL|AH|AX|EAX|BL|BH|BX|EBX|CL|CH|CX|ECX|DL|DH|DX|EDX|BP|EBP|SP|ESP|DI|EDI|SI|ESI/i
+ }, {
+ token: 'identifier',
+ regex: '[a-zA-Z]+'
+ }, {
+ token: 'string',
+ regex: '".*"'
+ }, {
+ token: 'comment',
+ regex: '//.*$'
+ }, {
+ token: 'constant.numeric',
+ regex: '[0-9.xA-F]+'
+ }, {
+ token: 'punctuation.operator',
+ regex: '\\,'
+ }, {
+ token: 'punctuation.operator',
+ regex: ';',
+ next: 'd-asm'
+ }, {
+ token: 'text',
+ regex: '\\s+'
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+DHighlightRules.metaData = {
+ comment: 'D language',
+ fileTypes: [ 'd', 'di' ],
+ firstLineMatch: '^#!.*\\b[glr]?dmd\\b.',
+ foldingStartMarker: '(?x)/\\*\\*(?!\\*)|^(?![^{]*?//|[^{]*?/\\*(?!.*?\\*/.*?\\{)).*?\\{\\s*($|//|/\\*(?!.*?\\*/.*\\S))',
+ foldingStopMarker: '(?<!\\*)\\*\\*/|^\\s*\\}',
+ keyEquivalent: '^~D',
+ name: 'D',
+ scopeName: 'source.d'
+};
+oop.inherits(DHighlightRules, TextHighlightRules);
+
+exports.DHighlightRules = DHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/d",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/d_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var DHighlightRules = require("./d_highlight_rules").DHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = DHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/d";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-dart.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-dart.js
new file mode 100644
index 00000000..c7042342
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-dart.js
@@ -0,0 +1,689 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/c_cpp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var cFunctions = exports.cFunctions = "\\b(?:hypot(?:f|l)?|s(?:scanf|ystem|nprintf|ca(?:nf|lb(?:n(?:f|l)?|ln(?:f|l)?))|i(?:n(?:h(?:f|l)?|f|l)?|gn(?:al|bit))|tr(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?)|error|pbrk|ftime|len|rchr|xfrm)|printf|et(?:jmp|vbuf|locale|buf)|qrt(?:f|l)?|w(?:scanf|printf)|rand)|n(?:e(?:arbyint(?:f|l)?|xt(?:toward(?:f|l)?|after(?:f|l)?))|an(?:f|l)?)|c(?:s(?:in(?:h(?:f|l)?|f|l)?|qrt(?:f|l)?)|cos(?:h(?:f)?|f|l)?|imag(?:f|l)?|t(?:ime|an(?:h(?:f|l)?|f|l)?)|o(?:s(?:h(?:f|l)?|f|l)?|nj(?:f|l)?|pysign(?:f|l)?)|p(?:ow(?:f|l)?|roj(?:f|l)?)|e(?:il(?:f|l)?|xp(?:f|l)?)|l(?:o(?:ck|g(?:f|l)?)|earerr)|a(?:sin(?:h(?:f|l)?|f|l)?|cos(?:h(?:f|l)?|f|l)?|tan(?:h(?:f|l)?|f|l)?|lloc|rg(?:f|l)?|bs(?:f|l)?)|real(?:f|l)?|brt(?:f|l)?)|t(?:ime|o(?:upper|lower)|an(?:h(?:f|l)?|f|l)?|runc(?:f|l)?|gamma(?:f|l)?|mp(?:nam|file))|i(?:s(?:space|n(?:ormal|an)|cntrl|inf|digit|u(?:nordered|pper)|p(?:unct|rint)|finite|w(?:space|c(?:ntrl|type)|digit|upper|p(?:unct|rint)|lower|al(?:num|pha)|graph|xdigit|blank)|l(?:ower|ess(?:equal|greater)?)|al(?:num|pha)|gr(?:eater(?:equal)?|aph)|xdigit|blank)|logb(?:f|l)?|max(?:div|abs))|di(?:v|fftime)|_Exit|unget(?:c|wc)|p(?:ow(?:f|l)?|ut(?:s|c(?:har)?|wc(?:har)?)|error|rintf)|e(?:rf(?:c(?:f|l)?|f|l)?|x(?:it|p(?:2(?:f|l)?|f|l|m1(?:f|l)?)?))|v(?:s(?:scanf|nprintf|canf|printf|w(?:scanf|printf))|printf|f(?:scanf|printf|w(?:scanf|printf))|w(?:scanf|printf)|a_(?:start|copy|end|arg))|qsort|f(?:s(?:canf|e(?:tpos|ek))|close|tell|open|dim(?:f|l)?|p(?:classify|ut(?:s|c|w(?:s|c))|rintf)|e(?:holdexcept|set(?:e(?:nv|xceptflag)|round)|clearexcept|testexcept|of|updateenv|r(?:aiseexcept|ror)|get(?:e(?:nv|xceptflag)|round))|flush|w(?:scanf|ide|printf|rite)|loor(?:f|l)?|abs(?:f|l)?|get(?:s|c|pos|w(?:s|c))|re(?:open|e|ad|xp(?:f|l)?)|m(?:in(?:f|l)?|od(?:f|l)?|a(?:f|l|x(?:f|l)?)?))|l(?:d(?:iv|exp(?:f|l)?)|o(?:ngjmp|cal(?:time|econv)|g(?:1(?:p(?:f|l)?|0(?:f|l)?)|2(?:f|l)?|f|l|b(?:f|l)?)?)|abs|l(?:div|abs|r(?:int(?:f|l)?|ound(?:f|l)?))|r(?:int(?:f|l)?|ound(?:f|l)?)|gamma(?:f|l)?)|w(?:scanf|c(?:s(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?|mbs)|pbrk|ftime|len|r(?:chr|tombs)|xfrm)|to(?:b|mb)|rtomb)|printf|mem(?:set|c(?:hr|py|mp)|move))|a(?:s(?:sert|ctime|in(?:h(?:f|l)?|f|l)?)|cos(?:h(?:f|l)?|f|l)?|t(?:o(?:i|f|l(?:l)?)|exit|an(?:h(?:f|l)?|2(?:f|l)?|f|l)?)|b(?:s|ort))|g(?:et(?:s|c(?:har)?|env|wc(?:har)?)|mtime)|r(?:int(?:f|l)?|ound(?:f|l)?|e(?:name|alloc|wind|m(?:ove|quo(?:f|l)?|ainder(?:f|l)?))|a(?:nd|ise))|b(?:search|towc)|m(?:odf(?:f|l)?|em(?:set|c(?:hr|py|mp)|move)|ktime|alloc|b(?:s(?:init|towcs|rtowcs)|towc|len|r(?:towc|len))))\\b"
+
+var c_cppHighlightRules = function() {
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|goto|if|_Pragma|" +
+ "return|switch|while|catch|operator|try|throw|using"
+ );
+
+ var storageType = (
+ "asm|__asm__|auto|bool|_Bool|char|_Complex|double|enum|float|" +
+ "_Imaginary|int|long|short|signed|struct|typedef|union|unsigned|void|" +
+ "class|wchar_t|template|char16_t|char32_t"
+ );
+
+ var storageModifiers = (
+ "const|extern|register|restrict|static|volatile|inline|private|" +
+ "protected|public|friend|explicit|virtual|export|mutable|typename|" +
+ "constexpr|new|delete|alignas|alignof|decltype|noexcept|thread_local"
+ );
+
+ var keywordOperators = (
+ "and|and_eq|bitand|bitor|compl|not|not_eq|or|or_eq|typeid|xor|xor_eq" +
+ "const_cast|dynamic_cast|reinterpret_cast|static_cast|sizeof|namespace"
+ );
+
+ var builtinConstants = (
+ "NULL|true|false|TRUE|FALSE|nullptr"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.control" : keywordControls,
+ "storage.type" : storageType,
+ "storage.modifier" : storageModifiers,
+ "keyword.operator" : keywordOperators,
+ "variable.language": "this",
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+ var escapeRe = /\\(?:['"?\\abfnrtv]|[0-7]{1,3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}U[a-fA-F\d]{8}|.)/.source;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "//$",
+ next : "start"
+ }, {
+ token : "comment",
+ regex : "//",
+ next : "singleLineComment"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : "'(?:" + escapeRe + "|.)?'"
+ }, {
+ token : "string.start",
+ regex : '"',
+ stateName: "qqstring",
+ next: [
+ { token: "string", regex: /\\\s*$/, next: "qqstring" },
+ { token: "constant.language.escape", regex: escapeRe },
+ { token: "constant.language.escape", regex: /%[^'"\\]/ },
+ { token: "string.end", regex: '"|$', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "string.start",
+ regex : 'R"\\(',
+ stateName: "rawString",
+ next: [
+ { token: "string.end", regex: '\\)"', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|pragma|line|define|undef)\\b",
+ next : "directive"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|if|ifdef|else|elif|ifndef)\\b"
+ }, {
+ token : "support.function.C99.c",
+ regex : cFunctions
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|<<=|>>=|>>>=|<>|&&|\|\||\?:|[*%\/+\-&\^|~!<>=]=?/
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "singleLineComment" : [
+ {
+ token : "comment",
+ regex : /\\$/,
+ next : "singleLineComment"
+ }, {
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ],
+ "directive" : [
+ {
+ token : "constant.other.multiline",
+ regex : /\\/
+ },
+ {
+ token : "constant.other.multiline",
+ regex : /.*\\/
+ },
+ {
+ token : "constant.other",
+ regex : "\\s*<.+?>",
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : '\\s*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]',
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
+ next : "start"
+ },
+ {
+ token : "constant.other",
+ regex : /[^\\\/]+/,
+ next : "start"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(c_cppHighlightRules, TextHighlightRules);
+
+exports.c_cppHighlightRules = c_cppHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/c_cpp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c_cpp_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var c_cppHighlightRules = require("./c_cpp_highlight_rules").c_cppHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = c_cppHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/c_cpp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/dart_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DartHighlightRules = function() {
+
+ var constantLanguage = "true|false|null";
+ var variableLanguage = "this|super";
+ var keywordControl = "try|catch|finally|throw|rethrow|assert|break|case|continue|default|do|else|for|if|in|return|switch|while|new|deferred|async|await";
+ var keywordDeclaration = "abstract|class|extends|external|factory|implements|get|native|operator|set|typedef|with|enum";
+ var storageModifier = "static|final|const";
+ var storageType = "void|bool|num|int|double|dynamic|var|String";
+
+ var keywordMapper = this.createKeywordMapper({
+ "constant.language.dart": constantLanguage,
+ "variable.language.dart": variableLanguage,
+ "keyword.control.dart": keywordControl,
+ "keyword.declaration.dart": keywordDeclaration,
+ "storage.modifier.dart": storageModifier,
+ "storage.type.primitive.dart": storageType
+ }, "identifier");
+
+ var stringfill = {
+ defaultToken : "string"
+ };
+
+ this.$rules =
+ {
+ "start": [
+ {
+ token : "comment",
+ regex : /\/\/.*$/
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next : "comment"
+ },
+ {
+ token: ["meta.preprocessor.script.dart"],
+ regex: "^(#!.*)$"
+ },
+ {
+ token: "keyword.other.import.dart",
+ regex: "(?:\\b)(?:library|import|export|part|of|show|hide)(?:\\b)"
+ },
+ {
+ token : ["keyword.other.import.dart", "text"],
+ regex : "(?:\\b)(prefix)(\\s*:)"
+ },
+ {
+ regex: "\\bas\\b",
+ token: "keyword.cast.dart"
+ },
+ {
+ regex: "\\?|:",
+ token: "keyword.control.ternary.dart"
+ },
+ {
+ regex: "(?:\\b)(is\\!?)(?:\\b)",
+ token: ["keyword.operator.dart"]
+ },
+ {
+ regex: "(<<|>>>?|~|\\^|\\||&)",
+ token: ["keyword.operator.bitwise.dart"]
+ },
+ {
+ regex: "((?:&|\\^|\\||<<|>>>?)=)",
+ token: ["keyword.operator.assignment.bitwise.dart"]
+ },
+ {
+ regex: "(===?|!==?|<=?|>=?)",
+ token: ["keyword.operator.comparison.dart"]
+ },
+ {
+ regex: "((?:[+*/%-]|\\~)=)",
+ token: ["keyword.operator.assignment.arithmetic.dart"]
+ },
+ {
+ regex: "=",
+ token: "keyword.operator.assignment.dart"
+ },
+ {
+ token : "string",
+ regex : "'''",
+ next : "qdoc"
+ },
+ {
+ token : "string",
+ regex : '"""',
+ next : "qqdoc"
+ },
+ {
+ token : "string",
+ regex : "'",
+ next : "qstring"
+ },
+ {
+ token : "string",
+ regex : '"',
+ next : "qqstring"
+ },
+ {
+ regex: "(\\-\\-|\\+\\+)",
+ token: ["keyword.operator.increment-decrement.dart"]
+ },
+ {
+ regex: "(\\-|\\+|\\*|\\/|\\~\\/|%)",
+ token: ["keyword.operator.arithmetic.dart"]
+ },
+ {
+ regex: "(!|&&|\\|\\|)",
+ token: ["keyword.operator.logical.dart"]
+ },
+ {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ },
+ {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ },
+ {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qdoc" : [
+ {
+ token : "string",
+ regex : ".*?'''",
+ next : "start"
+ }, stringfill],
+
+ "qqdoc" : [
+ {
+ token : "string",
+ regex : '.*?"""',
+ next : "start"
+ }, stringfill],
+
+ "qstring" : [
+ {
+ token : "string",
+ regex : "[^\\\\']*(?:\\\\.[^\\\\']*)*'",
+ next : "start"
+ }, stringfill],
+
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '[^\\\\"]*(?:\\\\.[^\\\\"]*)*"',
+ next : "start"
+ }, stringfill]
+}
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(DartHighlightRules, TextHighlightRules);
+
+exports.DartHighlightRules = DartHighlightRules;
+});
+
+ace.define("ace/mode/dart",["require","exports","module","ace/lib/oop","ace/mode/c_cpp","ace/mode/dart_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var CMode = require("./c_cpp").Mode;
+var DartHighlightRules = require("./dart_highlight_rules").DartHighlightRules;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ CMode.call(this);
+ this.HighlightRules = DartHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, CMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/dart";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-diff.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-diff.js
new file mode 100644
index 00000000..ae878dbe
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-diff.js
@@ -0,0 +1,139 @@
+ace.define("ace/mode/diff_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DiffHighlightRules = function() {
+
+ this.$rules = {
+ "start" : [{
+ regex: "^(?:\\*{15}|={67}|-{3}|\\+{3})$",
+ token: "punctuation.definition.separator.diff",
+ "name": "keyword"
+ }, { //diff.range.unified
+ regex: "^(@@)(\\s*.+?\\s*)(@@)(.*)$",
+ token: [
+ "constant",
+ "constant.numeric",
+ "constant",
+ "comment.doc.tag"
+ ]
+ }, { //diff.range.normal
+ regex: "^(\\d+)([,\\d]+)(a|d|c)(\\d+)([,\\d]+)(.*)$",
+ token: [
+ "constant.numeric",
+ "punctuation.definition.range.diff",
+ "constant.function",
+ "constant.numeric",
+ "punctuation.definition.range.diff",
+ "invalid"
+ ],
+ "name": "meta."
+ }, {
+ regex: "^(\\-{3}|\\+{3}|\\*{3})( .+)$",
+ token: [
+ "constant.numeric",
+ "meta.tag"
+ ]
+ }, { // added
+ regex: "^([!+>])(.*?)(\\s*)$",
+ token: [
+ "support.constant",
+ "text",
+ "invalid"
+ ]
+ }, { // removed
+ regex: "^([<\\-])(.*?)(\\s*)$",
+ token: [
+ "support.function",
+ "string",
+ "invalid"
+ ]
+ }, {
+ regex: "^(diff)(\\s+--\\w+)?(.+?)( .+)?$",
+ token: ["variable", "variable", "keyword", "variable"]
+ }, {
+ regex: "^Index.+$",
+ token: "variable"
+ }, {
+ regex: "^\\s+$",
+ token: "text"
+ }, {
+ regex: "\\s*$",
+ token: "invalid"
+ }, {
+ defaultToken: "invisible",
+ caseInsensitive: true
+ }
+ ]
+ };
+};
+
+oop.inherits(DiffHighlightRules, TextHighlightRules);
+
+exports.DiffHighlightRules = DiffHighlightRules;
+});
+
+ace.define("ace/mode/folding/diff",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function(levels, flag) {
+ this.regExpList = levels;
+ this.flag = flag;
+ this.foldingStartMarker = RegExp("^(" + levels.join("|") + ")", this.flag);
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var start = {row: row, column: line.length};
+
+ var regList = this.regExpList;
+ for (var i = 1; i <= regList.length; i++) {
+ var re = RegExp("^(" + regList.slice(0, i).join("|") + ")", this.flag);
+ if (re.test(line))
+ break;
+ }
+
+ for (var l = session.getLength(); ++row < l; ) {
+ line = session.getLine(row);
+ if (re.test(line))
+ break;
+ }
+ if (row == start.row + 1)
+ return;
+ return Range.fromPoints(start, {row: row - 1, column: line.length});
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/diff",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/diff_highlight_rules","ace/mode/folding/diff"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HighlightRules = require("./diff_highlight_rules").DiffHighlightRules;
+var FoldMode = require("./folding/diff").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HighlightRules;
+ this.foldingRules = new FoldMode(["diff", "index", "\\+{3}", "@@|\\*{5}"], "i");
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.$id = "ace/mode/diff";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-django.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-django.js
new file mode 100644
index 00000000..b681d992
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-django.js
@@ -0,0 +1,2565 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/django",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/html_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DjangoHighlightRules = function(){
+ this.$rules = {
+ 'start': [{
+ token: "string",
+ regex: '".*?"'
+ }, {
+ token: "string",
+ regex: "'.*?'"
+ }, {
+ token: "constant",
+ regex: '[0-9]+'
+ }, {
+ token: "variable",
+ regex: "[-_a-zA-Z0-9:]+"
+ }],
+ 'tag': [{
+ token: "entity.name.function",
+ regex: "[a-zA-Z][_a-zA-Z0-9]*",
+ next: "start"
+ }]
+ };
+};
+
+oop.inherits(DjangoHighlightRules, TextHighlightRules)
+
+var DjangoHtmlHighlightRules = function() {
+ this.$rules = new HtmlHighlightRules().getRules();
+
+ for (var i in this.$rules) {
+ this.$rules[i].unshift({
+ token: "comment.line",
+ regex: "\\{#.*?#\\}"
+ }, {
+ token: "comment.block",
+ regex: "\\{\\%\\s*comment\\s*\\%\\}",
+ merge: true,
+ next: "django-comment"
+ }, {
+ token: "constant.language",
+ regex: "\\{\\{",
+ next: "django-start"
+ }, {
+ token: "constant.language",
+ regex: "\\{\\%",
+ next: "django-tag"
+ });
+ this.embedRules(DjangoHighlightRules, "django-", [{
+ token: "comment.block",
+ regex: "\\{\\%\\s*endcomment\\s*\\%\\}",
+ merge: true,
+ next: "start"
+ }, {
+ token: "constant.language",
+ regex: "\\%\\}",
+ next: "start"
+ }, {
+ token: "constant.language",
+ regex: "\\}\\}",
+ next: "start"
+ }]);
+ }
+};
+
+oop.inherits(DjangoHtmlHighlightRules, HtmlHighlightRules);
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = DjangoHtmlHighlightRules;
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.$id = "ace/mode/django";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-dockerfile.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-dockerfile.js
new file mode 100644
index 00000000..f19df224
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-dockerfile.js
@@ -0,0 +1,492 @@
+ace.define("ace/mode/sh_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var reservedKeywords = exports.reservedKeywords = (
+ '!|{|}|case|do|done|elif|else|'+
+ 'esac|fi|for|if|in|then|until|while|'+
+ '&|;|export|local|read|typeset|unset|'+
+ 'elif|select|set|function|declare|readonly'
+ );
+
+var languageConstructs = exports.languageConstructs = (
+ '[|]|alias|bg|bind|break|builtin|'+
+ 'cd|command|compgen|complete|continue|'+
+ 'dirs|disown|echo|enable|eval|exec|'+
+ 'exit|fc|fg|getopts|hash|help|history|'+
+ 'jobs|kill|let|logout|popd|printf|pushd|'+
+ 'pwd|return|set|shift|shopt|source|'+
+ 'suspend|test|times|trap|type|ulimit|'+
+ 'umask|unalias|wait'
+);
+
+var ShHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": reservedKeywords,
+ "support.function.builtin": languageConstructs,
+ "invalid.deprecated": "debugger"
+ }, "identifier");
+
+ var integer = "(?:(?:[1-9]\\d*)|(?:0))";
+
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+ var fileDescriptor = "(?:&" + intPart + ")";
+
+ var variableName = "[a-zA-Z_][a-zA-Z0-9_]*";
+ var variable = "(?:" + variableName + "(?==))";
+
+ var builtinVariable = "(?:\\$(?:SHLVL|\\$|\\!|\\?))";
+
+ var func = "(?:" + variableName + "\\s*\\(\\))";
+
+ this.$rules = {
+ "start" : [{
+ token : "constant",
+ regex : /\\./
+ }, {
+ token : ["text", "comment"],
+ regex : /(^|\s)(#.*)$/
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[$`"\\]|$)/
+ }, {
+ include : "variables"
+ }, {
+ token : "keyword.operator",
+ regex : /`/ // TODO highlight `
+ }, {
+ token : "string.end",
+ regex : '"',
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string",
+ regex : "\\$'",
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[abeEfnrtv\\'"]|x[a-fA-F\d]{1,2}|u[a-fA-F\d]{4}([a-fA-F\d]{4})?|c.|\d{1,3})/
+ }, {
+ token : "string",
+ regex : "'",
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ regex : "<<<",
+ token : "keyword.operator"
+ }, {
+ stateName: "heredoc",
+ regex : "(<<-?)(\\s*)(['\"`]?)([\\w\\-]+)(['\"`]?)",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[4]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"text", value: tokens[2]},
+ {type:"string", value: tokens[3]},
+ {type:"support.class", value: tokens[4]},
+ {type:"string", value: tokens[5]}
+ ];
+ },
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^\t+"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : ["keyword", "text", "text", "text", "variable"],
+ regex : /(declare|local|readonly)(\s+)(?:(-[fixar]+)(\s+))?([a-zA-Z_][a-zA-Z0-9_]*\b)/
+ }, {
+ token : "variable.language",
+ regex : builtinVariable
+ }, {
+ token : "variable",
+ regex : variable
+ }, {
+ include : "variables"
+ }, {
+ token : "support.function",
+ regex : func
+ }, {
+ token : "support.function",
+ regex : fileDescriptor
+ }, {
+ token : "string", // ' string
+ start : "'", end : "'"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_][a-zA-Z0-9_]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|~|<|>|<=|=>|=|!=|[%&|`]"
+ }, {
+ token : "punctuation.operator",
+ regex : ";"
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)\\}]",
+ next : "pop"
+ }],
+ variables: [{
+ token : "variable",
+ regex : /(\$)(\w+)/
+ }, {
+ token : ["variable", "paren.lparen"],
+ regex : /(\$)(\()/,
+ push : "start"
+ }, {
+ token : ["variable", "paren.lparen", "keyword.operator", "variable", "keyword.operator"],
+ regex : /(\$)(\{)([#!]?)(\w+|[*@#?\-$!0_])(:[?+\-=]?|##?|%%?|,,?\/|\^\^?)?/,
+ push : "start"
+ }, {
+ token : "variable",
+ regex : /\$[*@#?\-$!0_]/
+ }, {
+ token : ["variable", "paren.lparen"],
+ regex : /(\$)(\{)/,
+ push : "start"
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(ShHighlightRules, TextHighlightRules);
+
+exports.ShHighlightRules = ShHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/sh",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sh_highlight_rules","ace/range","ace/mode/folding/cstyle","ace/mode/behaviour/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ShHighlightRules = require("./sh_highlight_rules").ShHighlightRules;
+var Range = require("../range").Range;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+
+var Mode = function() {
+ this.HighlightRules = ShHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = new CstyleBehaviour();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ var outdents = {
+ "pass": 1,
+ "return": 1,
+ "raise": 1,
+ "break": 1,
+ "continue": 1
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input !== "\r\n" && input !== "\r" && input !== "\n")
+ return false;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens)
+ return false;
+ do {
+ var last = tokens.pop();
+ } while (last && (last.type == "comment" || (last.type == "text" && last.value.match(/^\s+$/))));
+
+ if (!last)
+ return false;
+
+ return (last.type == "keyword" && outdents[last.value]);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+
+ row += 1;
+ var indent = this.$getIndent(doc.getLine(row));
+ var tab = doc.getTabString();
+ if (indent.slice(-tab.length) == tab)
+ doc.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ };
+
+ this.$id = "ace/mode/sh";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/dockerfile_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/sh_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var ShHighlightRules = require("./sh_highlight_rules").ShHighlightRules;
+
+var DockerfileHighlightRules = function() {
+ ShHighlightRules.call(this);
+
+ var startRules = this.$rules.start;
+ for (var i = 0; i < startRules.length; i++) {
+ if (startRules[i].token == "variable.language") {
+ startRules.splice(i, 0, {
+ token: "constant.language",
+ regex: "(?:^(?:FROM|MAINTAINER|RUN|CMD|EXPOSE|ENV|ADD|ENTRYPOINT|VOLUME|USER|WORKDIR|ONBUILD|COPY|LABEL)\\b)",
+ caseInsensitive: true
+ });
+ break;
+ }
+ }
+
+};
+
+oop.inherits(DockerfileHighlightRules, ShHighlightRules);
+
+exports.DockerfileHighlightRules = DockerfileHighlightRules;
+});
+
+ace.define("ace/mode/dockerfile",["require","exports","module","ace/lib/oop","ace/mode/sh","ace/mode/dockerfile_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var ShMode = require("./sh").Mode;
+var DockerfileHighlightRules = require("./dockerfile_highlight_rules").DockerfileHighlightRules;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ ShMode.call(this);
+
+ this.HighlightRules = DockerfileHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, ShMode);
+
+(function() {
+ this.$id = "ace/mode/dockerfile";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-dot.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-dot.js
new file mode 100644
index 00000000..72914768
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-dot.js
@@ -0,0 +1,410 @@
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/dot_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/doc_comment_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+
+var DotHighlightRules = function() {
+
+ var keywords = lang.arrayToMap(
+ ("strict|node|edge|graph|digraph|subgraph").split("|")
+ );
+
+ var attributes = lang.arrayToMap(
+ ("damping|k|url|area|arrowhead|arrowsize|arrowtail|aspect|bb|bgcolor|center|charset|clusterrank|color|colorscheme|comment|compound|concentrate|constraint|decorate|defaultdist|dim|dimen|dir|diredgeconstraints|distortion|dpi|edgeurl|edgehref|edgetarget|edgetooltip|epsilon|esep|fillcolor|fixedsize|fontcolor|fontname|fontnames|fontpath|fontsize|forcelabels|gradientangle|group|headurl|head_lp|headclip|headhref|headlabel|headport|headtarget|headtooltip|height|href|id|image|imagepath|imagescale|label|labelurl|label_scheme|labelangle|labeldistance|labelfloat|labelfontcolor|labelfontname|labelfontsize|labelhref|labeljust|labelloc|labeltarget|labeltooltip|landscape|layer|layerlistsep|layers|layerselect|layersep|layout|len|levels|levelsgap|lhead|lheight|lp|ltail|lwidth|margin|maxiter|mclimit|mindist|minlen|mode|model|mosek|nodesep|nojustify|normalize|nslimit|nslimit1|ordering|orientation|outputorder|overlap|overlap_scaling|pack|packmode|pad|page|pagedir|pencolor|penwidth|peripheries|pin|pos|quadtree|quantum|rank|rankdir|ranksep|ratio|rects|regular|remincross|repulsiveforce|resolution|root|rotate|rotation|samehead|sametail|samplepoints|scale|searchsize|sep|shape|shapefile|showboxes|sides|size|skew|smoothing|sortv|splines|start|style|stylesheet|tailurl|tail_lp|tailclip|tailhref|taillabel|tailport|tailtarget|tailtooltip|target|tooltip|truecolor|vertices|viewport|voro_margin|weight|width|xlabel|xlp|z").split("|")
+ );
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : /\/\/.*$/
+ }, {
+ token : "comment",
+ regex : /#.*$/
+ }, {
+ token : "comment", // multi line comment
+ merge : true,
+ regex : /\/\*/,
+ next : "comment"
+ }, {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric",
+ regex : /[+\-]?\d+(?:(?:\.\d*)?(?:[eE][+\-]?\d+)?)?\b/
+ }, {
+ token : "keyword.operator",
+ regex : /\+|=|\->/
+ }, {
+ token : "punctuation.operator",
+ regex : /,|;/
+ }, {
+ token : "paren.lparen",
+ regex : /[\[{]/
+ }, {
+ token : "paren.rparen",
+ regex : /[\]}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }, {
+ token: function(value) {
+ if (keywords.hasOwnProperty(value.toLowerCase())) {
+ return "keyword";
+ }
+ else if (attributes.hasOwnProperty(value.toLowerCase())) {
+ return "variable";
+ }
+ else {
+ return "text";
+ }
+ },
+ regex: "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '[^"\\\\]+',
+ merge : true
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring",
+ merge : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start",
+ merge : true
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "[^'\\\\]+",
+ merge : true
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qstring",
+ merge : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "start",
+ merge : true
+ }
+ ]
+ };
+};
+
+oop.inherits(DotHighlightRules, TextHighlightRules);
+
+exports.DotHighlightRules = DotHighlightRules;
+
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/dot",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/matching_brace_outdent","ace/mode/dot_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var DotHighlightRules = require("./dot_highlight_rules").DotHighlightRules;
+var DotFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = DotHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new DotFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ["//", "#"];
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/dot";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-drools.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-drools.js
new file mode 100644
index 00000000..5863afe0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-drools.js
@@ -0,0 +1,457 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/java_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JavaHighlightRules = function() {
+ var keywords = (
+ "abstract|continue|for|new|switch|" +
+ "assert|default|goto|package|synchronized|" +
+ "boolean|do|if|private|this|" +
+ "break|double|implements|protected|throw|" +
+ "byte|else|import|public|throws|" +
+ "case|enum|instanceof|return|transient|" +
+ "catch|extends|int|short|try|" +
+ "char|final|interface|static|void|" +
+ "class|finally|long|strictfp|volatile|" +
+ "const|float|native|super|while"
+ );
+
+ var buildinConstants = ("null|Infinity|NaN|undefined");
+
+
+ var langClasses = (
+ "AbstractMethodError|AssertionError|ClassCircularityError|"+
+ "ClassFormatError|Deprecated|EnumConstantNotPresentException|"+
+ "ExceptionInInitializerError|IllegalAccessError|"+
+ "IllegalThreadStateException|InstantiationError|InternalError|"+
+ "NegativeArraySizeException|NoSuchFieldError|Override|Process|"+
+ "ProcessBuilder|SecurityManager|StringIndexOutOfBoundsException|"+
+ "SuppressWarnings|TypeNotPresentException|UnknownError|"+
+ "UnsatisfiedLinkError|UnsupportedClassVersionError|VerifyError|"+
+ "InstantiationException|IndexOutOfBoundsException|"+
+ "ArrayIndexOutOfBoundsException|CloneNotSupportedException|"+
+ "NoSuchFieldException|IllegalArgumentException|NumberFormatException|"+
+ "SecurityException|Void|InheritableThreadLocal|IllegalStateException|"+
+ "InterruptedException|NoSuchMethodException|IllegalAccessException|"+
+ "UnsupportedOperationException|Enum|StrictMath|Package|Compiler|"+
+ "Readable|Runtime|StringBuilder|Math|IncompatibleClassChangeError|"+
+ "NoSuchMethodError|ThreadLocal|RuntimePermission|ArithmeticException|"+
+ "NullPointerException|Long|Integer|Short|Byte|Double|Number|Float|"+
+ "Character|Boolean|StackTraceElement|Appendable|StringBuffer|"+
+ "Iterable|ThreadGroup|Runnable|Thread|IllegalMonitorStateException|"+
+ "StackOverflowError|OutOfMemoryError|VirtualMachineError|"+
+ "ArrayStoreException|ClassCastException|LinkageError|"+
+ "NoClassDefFoundError|ClassNotFoundException|RuntimeException|"+
+ "Exception|ThreadDeath|Error|Throwable|System|ClassLoader|"+
+ "Cloneable|Class|CharSequence|Comparable|String|Object"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": langClasses
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : /0(?:[xX][0-9a-fA-F][0-9a-fA-F_]*|[bB][01][01_]*)[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.numeric", // float
+ regex : /[+-]?\d[\d_]*(?:(?:\.[\d_]*)?(?:[eE][+-]?[\d_]+)?)?[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(JavaHighlightRules, TextHighlightRules);
+
+exports.JavaHighlightRules = JavaHighlightRules;
+});
+
+ace.define("ace/mode/drools_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/java_highlight_rules","ace/mode/doc_comment_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var JavaHighlightRules = require("./java_highlight_rules").JavaHighlightRules;
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+var packageIdentifierRe = "[a-zA-Z\\$_\u00a1-\uffff][\\.a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var DroolsHighlightRules = function() {
+
+ var keywords = ("date|effective|expires|lock|on|active|no|loop|auto|focus" +
+ "|activation|group|agenda|ruleflow|duration|timer|calendars|refract|direct" +
+ "|dialect|salience|enabled|attributes|extends|template" +
+ "|function|contains|matches|eval|excludes|soundslike" +
+ "|memberof|not|in|or|and|exists|forall|over|from|entry|point|accumulate|acc|collect" +
+ "|action|reverse|result|end|init|instanceof|extends|super|boolean|char|byte|short" +
+ "|int|long|float|double|this|void|class|new|case|final|if|else|for|while|do" +
+ "|default|try|catch|finally|switch|synchronized|return|throw|break|continue|assert" +
+ "|modify|static|public|protected|private|abstract|native|transient|volatile" +
+ "|strictfp|throws|interface|enum|implements|type|window|trait|no-loop|str"
+ );
+
+ var langClasses = (
+ "AbstractMethodError|AssertionError|ClassCircularityError|"+
+ "ClassFormatError|Deprecated|EnumConstantNotPresentException|"+
+ "ExceptionInInitializerError|IllegalAccessError|"+
+ "IllegalThreadStateException|InstantiationError|InternalError|"+
+ "NegativeArraySizeException|NoSuchFieldError|Override|Process|"+
+ "ProcessBuilder|SecurityManager|StringIndexOutOfBoundsException|"+
+ "SuppressWarnings|TypeNotPresentException|UnknownError|"+
+ "UnsatisfiedLinkError|UnsupportedClassVersionError|VerifyError|"+
+ "InstantiationException|IndexOutOfBoundsException|"+
+ "ArrayIndexOutOfBoundsException|CloneNotSupportedException|"+
+ "NoSuchFieldException|IllegalArgumentException|NumberFormatException|"+
+ "SecurityException|Void|InheritableThreadLocal|IllegalStateException|"+
+ "InterruptedException|NoSuchMethodException|IllegalAccessException|"+
+ "UnsupportedOperationException|Enum|StrictMath|Package|Compiler|"+
+ "Readable|Runtime|StringBuilder|Math|IncompatibleClassChangeError|"+
+ "NoSuchMethodError|ThreadLocal|RuntimePermission|ArithmeticException|"+
+ "NullPointerException|Long|Integer|Short|Byte|Double|Number|Float|"+
+ "Character|Boolean|StackTraceElement|Appendable|StringBuffer|"+
+ "Iterable|ThreadGroup|Runnable|Thread|IllegalMonitorStateException|"+
+ "StackOverflowError|OutOfMemoryError|VirtualMachineError|"+
+ "ArrayStoreException|ClassCastException|LinkageError|"+
+ "NoClassDefFoundError|ClassNotFoundException|RuntimeException|"+
+ "Exception|ThreadDeath|Error|Throwable|System|ClassLoader|"+
+ "Cloneable|Class|CharSequence|Comparable|String|Object"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": "null",
+ "support.class" : langClasses,
+ "support.function" : "retract|update|modify|insert"
+ }, "identifier");
+
+ var stringRules = function() {
+ return [{
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }];
+ };
+
+
+ var basicPreRules = function(blockCommentRules) {
+ return [{
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : blockCommentRules
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }];
+ };
+
+ var blockCommentRules = function(returnRule) {
+ return [
+ {
+ token : "comment.block", // closing comment
+ regex : "\\*\\/",
+ next : returnRule
+ }, {
+ defaultToken : "comment.block"
+ }
+ ];
+ }
+
+ var basicPostRules = function() {
+ return [{
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }];
+ };
+
+
+ this.$rules = {
+ "start" : [].concat(basicPreRules("block.comment"), [
+ {
+ token : "entity.name.type",
+ regex : "@[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : ["keyword","text","entity.name.type"],
+ regex : "(package)(\\s+)(" + packageIdentifierRe +")"
+ }, {
+ token : ["keyword","text","keyword","text","entity.name.type"],
+ regex : "(import)(\\s+)(function)(\\s+)(" + packageIdentifierRe +")"
+ }, {
+ token : ["keyword","text","entity.name.type"],
+ regex : "(import)(\\s+)(" + packageIdentifierRe +")"
+ }, {
+ token : ["keyword","text","entity.name.type","text","variable"],
+ regex : "(global)(\\s+)(" + packageIdentifierRe +")(\\s+)(" + identifierRe +")"
+ }, {
+ token : ["keyword","text","keyword","text","entity.name.type"],
+ regex : "(declare)(\\s+)(trait)(\\s+)(" + identifierRe +")"
+ }, {
+ token : ["keyword","text","entity.name.type"],
+ regex : "(declare)(\\s+)(" + identifierRe +")"
+ }, {
+ token : ["keyword","text","entity.name.type"],
+ regex : "(extends)(\\s+)(" + packageIdentifierRe +")"
+ }, {
+ token : ["keyword","text"],
+ regex : "(rule)(\\s+)",
+ next : "asset.name"
+ }],
+ stringRules(),
+ [{
+ token : ["variable.other","text","text"],
+ regex : "(" + identifierRe + ")(\\s*)(:)"
+ }, {
+ token : ["keyword","text"],
+ regex : "(query)(\\s+)",
+ next : "asset.name"
+ }, {
+ token : ["keyword","text"],
+ regex : "(when)(\\s*)"
+ }, {
+ token : ["keyword","text"],
+ regex : "(then)(\\s*)",
+ next : "java-start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }], basicPostRules()),
+ "block.comment" : blockCommentRules("start"),
+ "asset.name" : [
+ {
+ token : "entity.name",
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "entity.name",
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "entity.name",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "start"
+ }]
+ };
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+
+ this.embedRules(JavaHighlightRules, "java-", [
+ {
+ token : "support.function",
+ regex: "\\b(insert|modify|retract|update)\\b"
+ }, {
+ token : "keyword",
+ regex: "\\bend\\b",
+ next : "start"
+ }]);
+
+};
+
+oop.inherits(DroolsHighlightRules, TextHighlightRules);
+
+exports.DroolsHighlightRules = DroolsHighlightRules;
+});
+
+ace.define("ace/mode/folding/drools",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+ this.foldingStartMarker = /\b(rule|declare|query|when|then)\b/;
+ this.foldingStopMarker = /\bend\b/;
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1]) {
+ var position = {row: row, column: line.length};
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var seek = "end";
+ var token = iterator.getCurrentToken();
+ if (token.value == "when") {
+ seek = "then";
+ }
+ while (token) {
+ if (token.value == seek) {
+ return Range.fromPoints(position ,{
+ row: iterator.getCurrentTokenRow(),
+ column: iterator.getCurrentTokenColumn()
+ });
+ }
+ token = iterator.stepForward();
+ }
+ }
+
+ }
+ }
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/drools",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/drools_highlight_rules","ace/mode/folding/drools"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var DroolsHighlightRules = require("./drools_highlight_rules").DroolsHighlightRules;
+var DroolsFoldMode = require("./folding/drools").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = DroolsHighlightRules;
+ this.foldingRules = new DroolsFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.$id = "ace/mode/drools";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-eiffel.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-eiffel.js
new file mode 100644
index 00000000..decf61d1
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-eiffel.js
@@ -0,0 +1,128 @@
+ace.define("ace/mode/eiffel_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var EiffelHighlightRules = function() {
+ var keywords = "across|agent|alias|all|attached|as|assign|attribute|check|" +
+ "class|convert|create|debug|deferred|detachable|do|else|elseif|end|" +
+ "ensure|expanded|export|external|feature|from|frozen|if|inherit|" +
+ "inspect|invariant|like|local|loop|not|note|obsolete|old|once|" +
+ "Precursor|redefine|rename|require|rescue|retry|select|separate|" +
+ "some|then|undefine|until|variant|when";
+
+ var operatorKeywords = "and|implies|or|xor";
+
+ var languageConstants = "Void";
+
+ var booleanConstants = "True|False";
+
+ var languageVariables = "Current|Result";
+
+ var keywordMapper = this.createKeywordMapper({
+ "constant.language": languageConstants,
+ "constant.language.boolean": booleanConstants,
+ "variable.language": languageVariables,
+ "keyword.operator": operatorKeywords,
+ "keyword": keywords
+ }, "identifier", true);
+
+ var simpleString = /(?:[^"%\b\f\v]|%[A-DFHLNQR-V%'"()<>]|%\/(?:0[xX][\da-fA-F](?:_*[\da-fA-F])*|0[cC][0-7](?:_*[0-7])*|0[bB][01](?:_*[01])*|\d(?:_*\d)*)\/)+?/;
+
+ this.$rules = {
+ "start": [{
+ token : "string.quoted.other", // Aligned-verbatim-strings (verbatim option not supported)
+ regex : /"\[/,
+ next: "aligned_verbatim_string"
+ }, {
+ token : "string.quoted.other", // Non-aligned-verbatim-strings (verbatim option not supported)
+ regex : /"\{/,
+ next: "non-aligned_verbatim_string"
+ }, {
+ token : "string.quoted.double",
+ regex : /"(?:[^%\b\f\n\r\v]|%[A-DFHLNQR-V%'"()<>]|%\/(?:0[xX][\da-fA-F](?:_*[\da-fA-F])*|0[cC][0-7](?:_*[0-7])*|0[bB][01](?:_*[01])*|\d(?:_*\d)*)\/)*?"/
+ }, {
+ token : "comment.line.double-dash",
+ regex : /--.*/
+ }, {
+ token : "constant.character",
+ regex : /'(?:[^%\b\f\n\r\t\v]|%[A-DFHLNQR-V%'"()<>]|%\/(?:0[xX][\da-fA-F](?:_*[\da-fA-F])*|0[cC][0-7](?:_*[0-7])*|0[bB][01](?:_*[01])*|\d(?:_*\d)*)\/)'/
+ }, {
+ token : "constant.numeric", // hexa | octal | bin
+ regex : /\b0(?:[xX][\da-fA-F](?:_*[\da-fA-F])*|[cC][0-7](?:_*[0-7])*|[bB][01](?:_*[01])*)\b/
+ }, {
+ token : "constant.numeric",
+ regex : /(?:\d(?:_*\d)*)?\.(?:(?:\d(?:_*\d)*)?[eE][+-]?)?\d(?:_*\d)*|\d(?:_*\d)*\.?/
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]|<<|\|\(/
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]|>>|\|\)/
+ }, {
+ token : "keyword.operator", // punctuation
+ regex : /:=|->|\.(?=\w)|[;,:?]/
+ }, {
+ token : "keyword.operator",
+ regex : /\\\\|\|\.\.\||\.\.|\/[~\/]?|[><\/]=?|[-+*^=~]/
+ }, {
+ token : function (v) {
+ var result = keywordMapper(v);
+ if (result === "identifier" && v === v.toUpperCase()) {
+ result = "entity.name.type";
+ }
+ return result;
+ },
+ regex : /[a-zA-Z][a-zA-Z\d_]*\b/
+ }, {
+ token : "text",
+ regex : /\s+/
+ }
+ ],
+ "aligned_verbatim_string" : [{
+ token : "string",
+ regex : /]"/,
+ next : "start"
+ }, {
+ token : "string",
+ regex : simpleString
+ }
+ ],
+ "non-aligned_verbatim_string" : [{
+ token : "string.quoted.other",
+ regex : /}"/,
+ next : "start"
+ }, {
+ token : "string.quoted.other",
+ regex : simpleString
+ }
+ ]};
+};
+
+oop.inherits(EiffelHighlightRules, TextHighlightRules);
+
+exports.EiffelHighlightRules = EiffelHighlightRules;
+});
+
+ace.define("ace/mode/eiffel",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/eiffel_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var EiffelHighlightRules = require("./eiffel_highlight_rules").EiffelHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = EiffelHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.$id = "ace/mode/eiffel";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-ejs.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-ejs.js
new file mode 100644
index 00000000..4309c8b8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-ejs.js
@@ -0,0 +1,2999 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var constantOtherSymbol = exports.constantOtherSymbol = {
+ token : "constant.other.symbol.ruby", // symbol
+ regex : "[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"
+};
+
+var qString = exports.qString = {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+};
+
+var qqString = exports.qqString = {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+};
+
+var tString = exports.tString = {
+ token : "string", // backtick string
+ regex : "[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"
+};
+
+var constantNumericHex = exports.constantNumericHex = {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"
+};
+
+var constantNumericFloat = exports.constantNumericFloat = {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?\\b"
+};
+
+var instanceVariable = exports.instanceVariable = {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+};
+
+var RubyHighlightRules = function() {
+
+ var builtinFunctions = (
+ "abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|" +
+ "assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|" +
+ "assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|" +
+ "assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|" +
+ "assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|" +
+ "assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|" +
+ "attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|" +
+ "caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|" +
+ "exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|" +
+ "gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|" +
+ "link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|" +
+ "p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|" +
+ "raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|" +
+ "set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|" +
+ "throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|" +
+ "render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|" +
+ "content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|" +
+ "fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|" +
+ "time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|" +
+ "select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|" +
+ "file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|" +
+ "protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|" +
+ "send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|" +
+ "validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|" +
+ "validates_inclusion_of|validates_numericality_of|validates_with|validates_each|" +
+ "authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|" +
+ "filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|" +
+ "translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|" +
+ "cache|expire_fragment|expire_cache_for|observe|cache_sweeper|" +
+ "has_many|has_one|belongs_to|has_and_belongs_to_many"
+ );
+
+ var keywords = (
+ "alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|" +
+ "__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|" +
+ "redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield"
+ );
+
+ var buildinConstants = (
+ "true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|" +
+ "RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING"
+ );
+
+ var builtinVariables = (
+ "$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|" +
+ "$!|root_url|flash|session|cookies|params|request|response|logger|self"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "variable.language": builtinVariables,
+ "support.function": builtinFunctions,
+ "invalid.deprecated": "debugger" // TODO is this a remnant from js mode?
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "comment", // multi line comment
+ regex : "^=begin(?:$|\\s.*$)",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ },
+
+ [{
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ return "paren.lparen";
+ }
+ if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1)
+ return "paren.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.start",
+ regex : /"/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /"/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /'/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\['\\]/
+ }, {
+ token : "string.end",
+ regex : /'/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ {
+ token : "text", // namespaces aren't symbols
+ regex : "::"
+ }, {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+ }, {
+ token : "support.class", // class name
+ regex : "[A-Z][a-zA-Z_\\d]+"
+ },
+
+ constantOtherSymbol,
+ constantNumericHex,
+ constantNumericFloat,
+
+ {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "punctuation.separator.key-value",
+ regex : "=>"
+ }, {
+ stateName: "heredoc",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[3]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"string", value: tokens[2]},
+ {type:"support.class", value: tokens[3]},
+ {type:"string", value: tokens[4]}
+ ];
+ },
+ regex : "(<<-?)(['\"`]?)([\\w]+)(['\"`]?)",
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^ +"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : "string.character",
+ regex : "\\B\\?."
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "^=end(?:$|\\s.*$)",
+ next : "start"
+ }, {
+ token : "comment", // comment spanning whole line
+ regex : ".+"
+ }
+ ]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(RubyHighlightRules, TextHighlightRules);
+
+exports.RubyHighlightRules = RubyHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var RubyHighlightRules = require("./ruby_highlight_rules").RubyHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = RubyHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ var startingClassOrMethod = line.match(/^\s*(class|def|module)\s.*$/);
+ var startingDoBlock = line.match(/.*do(\s*|\s+\|.*\|\s*)$/);
+ var startingConditional = line.match(/^\s*(if|else|when)\s*/)
+ if (match || startingClassOrMethod || startingDoBlock || startingConditional) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return /^\s+(end|else)$/.test(line + input) || this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, session, row) {
+ var line = session.getLine(row);
+ if (/}/.test(line))
+ return this.$outdent.autoOutdent(session, row);
+ var indent = this.$getIndent(line);
+ var prevLine = session.getLine(row - 1);
+ var prevIndent = this.$getIndent(prevLine);
+ var tab = session.getTabString();
+ if (prevIndent.length <= indent.length) {
+ if (indent.slice(-tab.length) == tab)
+ session.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ }
+ };
+
+ this.$id = "ace/mode/ruby";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/ejs",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/javascript_highlight_rules","ace/lib/oop","ace/mode/html","ace/mode/javascript","ace/mode/css","ace/mode/ruby"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+
+var EjsHighlightRules = function(start, end) {
+ HtmlHighlightRules.call(this);
+
+ if (!start)
+ start = "(?:<%|<\\?|{{)";
+ if (!end)
+ end = "(?:%>|\\?>|}})";
+
+ for (var i in this.$rules) {
+ this.$rules[i].unshift({
+ token : "markup.list.meta.tag",
+ regex : start + "(?![>}])[-=]?",
+ push : "ejs-start"
+ });
+ }
+
+ this.embedRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "ejs-", [{
+ token : "markup.list.meta.tag",
+ regex : "-?" + end,
+ next : "pop"
+ }, {
+ token: "comment",
+ regex: "//.*?" + end,
+ next: "pop"
+ }]);
+
+ this.normalizeRules();
+};
+
+
+oop.inherits(EjsHighlightRules, HtmlHighlightRules);
+
+exports.EjsHighlightRules = EjsHighlightRules;
+
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var RubyMode = require("./ruby").Mode;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = EjsHighlightRules;
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode,
+ "ejs-": JavaScriptMode
+ });
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+
+ this.$id = "ace/mode/ejs";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-elixir.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-elixir.js
new file mode 100644
index 00000000..d8931b98
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-elixir.js
@@ -0,0 +1,494 @@
+ace.define("ace/mode/elixir_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ElixirHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token:
+ [ 'meta.module.elixir',
+ 'keyword.control.module.elixir',
+ 'meta.module.elixir',
+ 'entity.name.type.module.elixir' ],
+ regex: '^(\\s*)(defmodule)(\\s+)((?:[A-Z]\\w*\\s*\\.\\s*)*[A-Z]\\w*)' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc (?:~[a-z])?"""',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*"""',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc ~[A-Z]"""',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*"""',
+ next: 'pop' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc (?:~[a-z])?\'\'\'',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*\'\'\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc ~[A-Z]\'\'\'',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*\'\'\'',
+ next: 'pop' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.false',
+ regex: '@(?:module|type)?doc false',
+ comment: '@doc false is treated as documentation' },
+ { token: 'comment.documentation.string',
+ regex: '@(?:module|type)?doc "',
+ push:
+ [ { token: 'comment.documentation.string',
+ regex: '"',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'comment.documentation.string' } ],
+ comment: '@doc with string is treated as documentation' },
+ { token: 'keyword.control.elixir',
+ regex: '\\b(?:do|end|case|bc|lc|for|if|cond|unless|try|receive|fn|defmodule|defp?|defprotocol|defimpl|defrecord|defstruct|defmacrop?|defdelegate|defcallback|defmacrocallback|defexception|defoverridable|exit|after|rescue|catch|else|raise|throw|import|require|alias|use|quote|unquote|super)\\b(?![?!])',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!\\.)\\b(do|end|case|bc|lc|for|if|cond|unless|try|receive|fn|defmodule|defp?|defprotocol|defimpl|defrecord|defstruct|defmacrop?|defdelegate|defcallback|defmacrocallback|defexception|defoverridable|exit|after|rescue|catch|else|raise|throw|import|require|alias|use|quote|unquote|super)\\b(?![?!])' },
+ { token: 'keyword.operator.elixir',
+ regex: '\\b(?:and|not|or|when|xor|in|inlist|inbits)\\b',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!\\.)\\b(and|not|or|when|xor|in|inlist|inbits)\\b',
+ comment: ' as above, just doesn\'t need a \'end\' and does a logic operation' },
+ { token: 'constant.language.elixir',
+ regex: '\\b(?:nil|true|false)\\b(?![?!])' },
+ { token: 'variable.language.elixir',
+ regex: '\\b__(?:CALLER|ENV|MODULE|DIR)__\\b(?![?!])' },
+ { token:
+ [ 'punctuation.definition.variable.elixir',
+ 'variable.other.readwrite.module.elixir' ],
+ regex: '(@)([a-zA-Z_]\\w*)' },
+ { token:
+ [ 'punctuation.definition.variable.elixir',
+ 'variable.other.anonymous.elixir' ],
+ regex: '(&)(\\d*)' },
+ { token: 'variable.other.constant.elixir',
+ regex: '\\b[A-Z]\\w*\\b' },
+ { token: 'constant.numeric.elixir',
+ regex: '\\b(?:0x[\\da-fA-F](?:_?[\\da-fA-F])*|\\d(?:_?\\d)*(?:\\.(?![^[:space:][:digit:]])(?:_?\\d)*)?(?:[eE][-+]?\\d(?:_?\\d)*)?|0b[01]+|0o[0-7]+)\\b',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '\\b(0x\\h(?>_?\\h)*|\\d(?>_?\\d)*(\\.(?![^[:space:][:digit:]])(?>_?\\d)*)?([eE][-+]?\\d(?>_?\\d)*)?|0b[01]+|0o[0-7]+)\\b' },
+ { token: 'punctuation.definition.constant.elixir',
+ regex: ':\'',
+ push:
+ [ { token: 'punctuation.definition.constant.elixir',
+ regex: '\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'constant.other.symbol.single-quoted.elixir' } ] },
+ { token: 'punctuation.definition.constant.elixir',
+ regex: ':"',
+ push:
+ [ { token: 'punctuation.definition.constant.elixir',
+ regex: '"',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'constant.other.symbol.double-quoted.elixir' } ] },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '(?:\'\'\')',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?>\'\'\')',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*\'\'\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'support.function.variable.quoted.single.heredoc.elixir' } ],
+ comment: 'Single-quoted heredocs' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'support.function.variable.quoted.single.elixir' } ],
+ comment: 'single quoted string (allows for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '(?:""")',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?>""")',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*"""',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.quoted.double.heredoc.elixir' } ],
+ comment: 'Double-quoted heredocs' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '"',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.quoted.double.elixir' } ],
+ comment: 'double quoted string (allows for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z](?:""")',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '~[a-z](?>""")',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*"""',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.quoted.double.heredoc.elixir' } ],
+ comment: 'Double-quoted heredocs sigils' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\{',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\}[a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\[',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\][a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\<',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\>[a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\(',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\)[a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z][^\\w]',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '[^\\w][a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z](?:""")',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '~[A-Z](?>""")',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*"""',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'Double-quoted heredocs sigils' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\{',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\}[a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\[',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\][a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\<',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\>[a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\(',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\)[a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z][^\\w]',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '[^\\w][a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: ['punctuation.definition.constant.elixir', 'constant.other.symbol.elixir'],
+ regex: '(:)([a-zA-Z_][\\w@]*(?:[?!]|=(?![>=]))?|\\<\\>|===?|!==?|<<>>|<<<|>>>|~~~|::|<\\-|\\|>|=>|~|~=|=|/|\\\\\\\\|\\*\\*?|\\.\\.?\\.?|>=?|<=?|&&?&?|\\+\\+?|\\-\\-?|\\|\\|?\\|?|\\!|@|\\%?\\{\\}|%|\\[\\]|\\^(?:\\^\\^)?)',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!:)(:)(?>[a-zA-Z_][\\w@]*(?>[?!]|=(?![>=]))?|\\<\\>|===?|!==?|<<>>|<<<|>>>|~~~|::|<\\-|\\|>|=>|~|~=|=|/|\\\\\\\\|\\*\\*?|\\.\\.?\\.?|>=?|<=?|&&?&?|\\+\\+?|\\-\\-?|\\|\\|?\\|?|\\!|@|\\%?\\{\\}|%|\\[\\]|\\^(\\^\\^)?)',
+ comment: 'symbols' },
+ { token: 'punctuation.definition.constant.elixir',
+ regex: '(?:[a-zA-Z_][\\w@]*(?:[?!])?):(?!:)',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?>[a-zA-Z_][\\w@]*(?>[?!])?)(:)(?!:)',
+ comment: 'symbols' },
+ { token:
+ [ 'punctuation.definition.comment.elixir',
+ 'comment.line.number-sign.elixir' ],
+ regex: '(#)(.*)' },
+ { token: 'constant.numeric.elixir',
+ regex: '\\?(?:\\\\(?:x[\\da-fA-F]{1,2}(?![\\da-fA-F])\\b|[^xMC])|[^\\s\\\\])',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!\\w)\\?(\\\\(x\\h{1,2}(?!\\h)\\b|[^xMC])|[^\\s\\\\])',
+ comment: '\n\t\t\tmatches questionmark-letters.\n\n\t\t\texamples (1st alternation = hex):\n\t\t\t?\\x1 ?\\x61\n\n\t\t\texamples (2rd alternation = escaped):\n\t\t\t?\\n ?\\b\n\n\t\t\texamples (3rd alternation = normal):\n\t\t\t?a ?A ?0 \n\t\t\t?* ?" ?( \n\t\t\t?. ?#\n\t\t\t\n\t\t\tthe negative lookbehind prevents against matching\n\t\t\tp(42.tainted?)\n\t\t\t' },
+ { token: 'keyword.operator.assignment.augmented.elixir',
+ regex: '\\+=|\\-=|\\|\\|=|~=|&&=' },
+ { token: 'keyword.operator.comparison.elixir',
+ regex: '===?|!==?|<=?|>=?' },
+ { token: 'keyword.operator.bitwise.elixir',
+ regex: '\\|{3}|&{3}|\\^{3}|<{3}|>{3}|~{3}' },
+ { token: 'keyword.operator.logical.elixir',
+ regex: '!+|\\bnot\\b|&&|\\band\\b|\\|\\||\\bor\\b|\\bxor\\b',
+ originalRegex: '(?<=[ \\t])!+|\\bnot\\b|&&|\\band\\b|\\|\\||\\bor\\b|\\bxor\\b' },
+ { token: 'keyword.operator.arithmetic.elixir',
+ regex: '\\*|\\+|\\-|/' },
+ { token: 'keyword.operator.other.elixir',
+ regex: '\\||\\+\\+|\\-\\-|\\*\\*|\\\\\\\\|\\<\\-|\\<\\>|\\<\\<|\\>\\>|\\:\\:|\\.\\.|\\|>|~|=>' },
+ { token: 'keyword.operator.assignment.elixir', regex: '=' },
+ { token: 'punctuation.separator.other.elixir', regex: ':' },
+ { token: 'punctuation.separator.statement.elixir',
+ regex: '\\;' },
+ { token: 'punctuation.separator.object.elixir', regex: ',' },
+ { token: 'punctuation.separator.method.elixir', regex: '\\.' },
+ { token: 'punctuation.section.scope.elixir', regex: '\\{|\\}' },
+ { token: 'punctuation.section.array.elixir', regex: '\\[|\\]' },
+ { token: 'punctuation.section.function.elixir',
+ regex: '\\(|\\)' } ],
+ '#escaped_char':
+ [ { token: 'constant.character.escape.elixir',
+ regex: '\\\\(?:x[\\da-fA-F]{1,2}|.)' } ],
+ '#interpolated_elixir':
+ [ { token:
+ [ 'source.elixir.embedded.source',
+ 'source.elixir.embedded.source.empty' ],
+ regex: '(#\\{)(\\})' },
+ { todo:
+ { token: 'punctuation.section.embedded.elixir',
+ regex: '#\\{',
+ push:
+ [ { token: 'punctuation.section.embedded.elixir',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#nest_curly_and_self' },
+ { include: '$self' },
+ { defaultToken: 'source.elixir.embedded.source' } ] } } ],
+ '#nest_curly_and_self':
+ [ { token: 'punctuation.section.scope.elixir',
+ regex: '\\{',
+ push:
+ [ { token: 'punctuation.section.scope.elixir',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#nest_curly_and_self' } ] },
+ { include: '$self' } ],
+ '#regex_sub':
+ [ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { token:
+ [ 'punctuation.definition.arbitrary-repitition.elixir',
+ 'string.regexp.arbitrary-repitition.elixir',
+ 'string.regexp.arbitrary-repitition.elixir',
+ 'punctuation.definition.arbitrary-repitition.elixir' ],
+ regex: '(\\{)(\\d+)((?:,\\d+)?)(\\})' },
+ { token: 'punctuation.definition.character-class.elixir',
+ regex: '\\[(?:\\^?\\])?',
+ push:
+ [ { token: 'punctuation.definition.character-class.elixir',
+ regex: '\\]',
+ next: 'pop' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.regexp.character-class.elixir' } ] },
+ { token: 'punctuation.definition.group.elixir',
+ regex: '\\(',
+ push:
+ [ { token: 'punctuation.definition.group.elixir',
+ regex: '\\)',
+ next: 'pop' },
+ { include: '#regex_sub' },
+ { defaultToken: 'string.regexp.group.elixir' } ] },
+ { token:
+ [ 'punctuation.definition.comment.elixir',
+ 'comment.line.number-sign.elixir' ],
+ regex: '(?:^|\\s)(#)(\\s[[a-zA-Z0-9,. \\t?!-][^\\x00-\\x7F]]*$)',
+ originalRegex: '(?<=^|\\s)(#)\\s[[a-zA-Z0-9,. \\t?!-][^\\x{00}-\\x{7F}]]*$',
+ comment: 'We are restrictive in what we allow to go after the comment character to avoid false positives, since the availability of comments depend on regexp flags.' } ] }
+
+ this.normalizeRules();
+};
+
+ElixirHighlightRules.metaData = { comment: 'Textmate bundle for Elixir Programming Language.',
+ fileTypes: [ 'ex', 'exs' ],
+ firstLineMatch: '^#!/.*\\belixir',
+ foldingStartMarker: '(after|else|catch|rescue|\\-\\>|\\{|\\[|do)\\s*$',
+ foldingStopMarker: '^\\s*((\\}|\\]|after|else|catch|rescue)\\s*$|end\\b)',
+ keyEquivalent: '^~E',
+ name: 'Elixir',
+ scopeName: 'source.elixir' }
+
+
+oop.inherits(ElixirHighlightRules, TextHighlightRules);
+
+exports.ElixirHighlightRules = ElixirHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/elixir",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/elixir_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ElixirHighlightRules = require("./elixir_highlight_rules").ElixirHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ElixirHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/elixir"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-elm.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-elm.js
new file mode 100644
index 00000000..24406af9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-elm.js
@@ -0,0 +1,299 @@
+ace.define("ace/mode/elm_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ElmHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": "as|case|class|data|default|deriving|do|else|export|foreign|" +
+ "hiding|jsevent|if|import|in|infix|infixl|infixr|instance|let|" +
+ "module|newtype|of|open|then|type|where|_|port|\u03BB"
+ }, "identifier");
+
+ var escapeRe = /\\(\d+|['"\\&trnbvf])/;
+
+ var smallRe = /[a-z_]/.source;
+ var largeRe = /[A-Z]/.source;
+ var idRe = /[a-z_A-Z0-9']/.source;
+
+ this.$rules = {
+ start: [{
+ token: "string.start",
+ regex: '"',
+ next: "string"
+ }, {
+ token: "string.character",
+ regex: "'(?:" + escapeRe.source + "|.)'?"
+ }, {
+ regex: /0(?:[xX][0-9A-Fa-f]+|[oO][0-7]+)|\d+(\.\d+)?([eE][-+]?\d*)?/,
+ token: "constant.numeric"
+ }, {
+ token: "comment",
+ regex: "--.*"
+ }, {
+ token : "keyword",
+ regex : /\.\.|\||:|=|\\|"|->|<-|\u2192/
+ }, {
+ token : "keyword.operator",
+ regex : /[-!#$%&*+.\/<=>?@\\^|~:\u03BB\u2192]+/
+ }, {
+ token : "operator.punctuation",
+ regex : /[,;`]/
+ }, {
+ regex : largeRe + idRe + "+\\.?",
+ token : function(value) {
+ if (value[value.length - 1] == ".")
+ return "entity.name.function";
+ return "constant.language";
+ }
+ }, {
+ regex : "^" + smallRe + idRe + "+",
+ token : function(value) {
+ return "constant.language";
+ }
+ }, {
+ token : keywordMapper,
+ regex : "[\\w\\xff-\\u218e\\u2455-\\uffff]+\\b"
+ }, {
+ regex: "{-#?",
+ token: "comment.start",
+ onMatch: function(value, currentState, stack) {
+ this.next = value.length == 2 ? "blockComment" : "docComment";
+ return this.token;
+ }
+ }, {
+ token: "variable.language",
+ regex: /\[markdown\|/,
+ next: "markdown"
+ }, {
+ token: "paren.lparen",
+ regex: /[\[({]/
+ }, {
+ token: "paren.rparen",
+ regex: /[\])}]/
+ } ],
+ markdown: [{
+ regex: /\|\]/,
+ next: "start"
+ }, {
+ defaultToken : "string"
+ }],
+ blockComment: [{
+ regex: "{-",
+ token: "comment.start",
+ push: "blockComment"
+ }, {
+ regex: "-}",
+ token: "comment.end",
+ next: "pop"
+ }, {
+ defaultToken: "comment"
+ }],
+ docComment: [{
+ regex: "{-",
+ token: "comment.start",
+ push: "docComment"
+ }, {
+ regex: "-}",
+ token: "comment.end",
+ next: "pop"
+ }, {
+ defaultToken: "doc.comment"
+ }],
+ string: [{
+ token: "constant.language.escape",
+ regex: escapeRe
+ }, {
+ token: "text",
+ regex: /\\(\s|$)/,
+ next: "stringGap"
+ }, {
+ token: "string.end",
+ regex: '"',
+ next: "start"
+ }, {
+ defaultToken: "string"
+ }],
+ stringGap: [{
+ token: "text",
+ regex: /\\/,
+ next: "string"
+ }, {
+ token: "error",
+ regex: "",
+ next: "start"
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(ElmHighlightRules, TextHighlightRules);
+
+exports.ElmHighlightRules = ElmHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/elm",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/elm_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HighlightRules = require("./elm_highlight_rules").ElmHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "{-", end: "-}", nestable: true};
+ this.$id = "ace/mode/elm";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-erlang.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-erlang.js
new file mode 100644
index 00000000..3554bf7e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-erlang.js
@@ -0,0 +1,1002 @@
+ace.define("ace/mode/erlang_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ErlangHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { include: '#module-directive' },
+ { include: '#import-export-directive' },
+ { include: '#behaviour-directive' },
+ { include: '#record-directive' },
+ { include: '#define-directive' },
+ { include: '#macro-directive' },
+ { include: '#directive' },
+ { include: '#function' },
+ { include: '#everything-else' } ],
+ '#atom':
+ [ { token: 'punctuation.definition.symbol.begin.erlang',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.symbol.end.erlang',
+ regex: '\'',
+ next: 'pop' },
+ { token:
+ [ 'punctuation.definition.escape.erlang',
+ 'constant.other.symbol.escape.erlang',
+ 'punctuation.definition.escape.erlang',
+ 'constant.other.symbol.escape.erlang',
+ 'constant.other.symbol.escape.erlang' ],
+ regex: '(\\\\)(?:([bdefnrstv\\\\\'"])|(\\^)([@-_])|([0-7]{1,3}))' },
+ { token: 'invalid.illegal.atom.erlang', regex: '\\\\\\^?.?' },
+ { defaultToken: 'constant.other.symbol.quoted.single.erlang' } ] },
+ { token: 'constant.other.symbol.unquoted.erlang',
+ regex: '[a-z][a-zA-Z\\d@_]*' } ],
+ '#behaviour-directive':
+ [ { token:
+ [ 'meta.directive.behaviour.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.behaviour.erlang',
+ 'keyword.control.directive.behaviour.erlang',
+ 'meta.directive.behaviour.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.behaviour.erlang',
+ 'entity.name.type.class.behaviour.definition.erlang',
+ 'meta.directive.behaviour.erlang',
+ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.behaviour.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(behaviour)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\))(\\s*)(\\.)' } ],
+ '#binary':
+ [ { token: 'punctuation.definition.binary.begin.erlang',
+ regex: '<<',
+ push:
+ [ { token: 'punctuation.definition.binary.end.erlang',
+ regex: '>>',
+ next: 'pop' },
+ { token:
+ [ 'punctuation.separator.binary.erlang',
+ 'punctuation.separator.value-size.erlang' ],
+ regex: '(,)|(:)' },
+ { include: '#internal-type-specifiers' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.structure.binary.erlang' } ] } ],
+ '#character':
+ [ { token:
+ [ 'punctuation.definition.character.erlang',
+ 'punctuation.definition.escape.erlang',
+ 'constant.character.escape.erlang',
+ 'punctuation.definition.escape.erlang',
+ 'constant.character.escape.erlang',
+ 'constant.character.escape.erlang' ],
+ regex: '(\\$)(\\\\)(?:([bdefnrstv\\\\\'"])|(\\^)([@-_])|([0-7]{1,3}))' },
+ { token: 'invalid.illegal.character.erlang',
+ regex: '\\$\\\\\\^?.?' },
+ { token:
+ [ 'punctuation.definition.character.erlang',
+ 'constant.character.erlang' ],
+ regex: '(\\$)(\\S)' },
+ { token: 'invalid.illegal.character.erlang', regex: '\\$.?' } ],
+ '#comment':
+ [ { token: 'punctuation.definition.comment.erlang',
+ regex: '%.*$',
+ push_:
+ [ { token: 'comment.line.percentage.erlang',
+ regex: '$',
+ next: 'pop' },
+ { defaultToken: 'comment.line.percentage.erlang' } ] } ],
+ '#define-directive':
+ [ { token:
+ [ 'meta.directive.define.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.define.erlang',
+ 'keyword.control.directive.define.erlang',
+ 'meta.directive.define.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.define.erlang',
+ 'entity.name.function.macro.definition.erlang',
+ 'meta.directive.define.erlang',
+ 'punctuation.separator.parameters.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(define)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(,)',
+ push:
+ [ { token:
+ [ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.define.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '(\\))(\\s*)(\\.)',
+ next: 'pop' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.directive.define.erlang' } ] },
+ { token: 'meta.directive.define.erlang',
+ regex: '(?=^\\s*-\\s*define\\s*\\(\\s*[a-zA-Z\\d@_]+\\s*\\()',
+ push:
+ [ { token:
+ [ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.define.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '(\\))(\\s*)(\\.)',
+ next: 'pop' },
+ { token:
+ [ 'text',
+ 'punctuation.section.directive.begin.erlang',
+ 'text',
+ 'keyword.control.directive.define.erlang',
+ 'text',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'text',
+ 'entity.name.function.macro.definition.erlang',
+ 'text',
+ 'punctuation.definition.parameters.begin.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(define)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\()',
+ push:
+ [ { token:
+ [ 'punctuation.definition.parameters.end.erlang',
+ 'text',
+ 'punctuation.separator.parameters.erlang' ],
+ regex: '(\\))(\\s*)(,)',
+ next: 'pop' },
+ { token: 'punctuation.separator.parameters.erlang', regex: ',' },
+ { include: '#everything-else' } ] },
+ { token: 'punctuation.separator.define.erlang',
+ regex: '\\|\\||\\||:|;|,|\\.|->' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.directive.define.erlang' } ] } ],
+ '#directive':
+ [ { token:
+ [ 'meta.directive.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.erlang',
+ 'keyword.control.directive.erlang',
+ 'meta.directive.erlang',
+ 'punctuation.definition.parameters.begin.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\(?)',
+ push:
+ [ { token:
+ [ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '(\\)?)(\\s*)(\\.)',
+ next: 'pop' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.directive.erlang' } ] },
+ { token:
+ [ 'meta.directive.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.erlang',
+ 'keyword.control.directive.erlang',
+ 'meta.directive.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\.)' } ],
+ '#everything-else':
+ [ { include: '#comment' },
+ { include: '#record-usage' },
+ { include: '#macro-usage' },
+ { include: '#expression' },
+ { include: '#keyword' },
+ { include: '#textual-operator' },
+ { include: '#function-call' },
+ { include: '#tuple' },
+ { include: '#list' },
+ { include: '#binary' },
+ { include: '#parenthesized-expression' },
+ { include: '#character' },
+ { include: '#number' },
+ { include: '#atom' },
+ { include: '#string' },
+ { include: '#symbolic-operator' },
+ { include: '#variable' } ],
+ '#expression':
+ [ { token: 'keyword.control.if.erlang',
+ regex: '\\bif\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { include: '#internal-expression-punctuation' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.if.erlang' } ] },
+ { token: 'keyword.control.case.erlang',
+ regex: '\\bcase\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { include: '#internal-expression-punctuation' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.case.erlang' } ] },
+ { token: 'keyword.control.receive.erlang',
+ regex: '\\breceive\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { include: '#internal-expression-punctuation' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.receive.erlang' } ] },
+ { token:
+ [ 'keyword.control.fun.erlang',
+ 'text',
+ 'entity.name.type.class.module.erlang',
+ 'text',
+ 'punctuation.separator.module-function.erlang',
+ 'text',
+ 'entity.name.function.erlang',
+ 'text',
+ 'punctuation.separator.function-arity.erlang' ],
+ regex: '\\b(fun)(\\s*)(?:([a-z][a-zA-Z\\d@_]*)(\\s*)(:)(\\s*))?([a-z][a-zA-Z\\d@_]*)(\\s*)(/)' },
+ { token: 'keyword.control.fun.erlang',
+ regex: '\\bfun\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { token: 'text',
+ regex: '(?=\\()',
+ push:
+ [ { token: 'punctuation.separator.clauses.erlang',
+ regex: ';|(?=\\bend\\b)',
+ next: 'pop' },
+ { include: '#internal-function-parts' } ] },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.fun.erlang' } ] },
+ { token: 'keyword.control.try.erlang',
+ regex: '\\btry\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { include: '#internal-expression-punctuation' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.try.erlang' } ] },
+ { token: 'keyword.control.begin.erlang',
+ regex: '\\bbegin\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { include: '#internal-expression-punctuation' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.begin.erlang' } ] },
+ { token: 'keyword.control.query.erlang',
+ regex: '\\bquery\\b',
+ push:
+ [ { token: 'keyword.control.end.erlang',
+ regex: '\\bend\\b',
+ next: 'pop' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.query.erlang' } ] } ],
+ '#function':
+ [ { token:
+ [ 'meta.function.erlang',
+ 'entity.name.function.definition.erlang',
+ 'meta.function.erlang' ],
+ regex: '^(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(?=\\()',
+ push:
+ [ { token: 'punctuation.terminator.function.erlang',
+ regex: '\\.',
+ next: 'pop' },
+ { token: [ 'text', 'entity.name.function.erlang', 'text' ],
+ regex: '^(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(?=\\()' },
+ { token: 'text',
+ regex: '(?=\\()',
+ push:
+ [ { token: 'punctuation.separator.clauses.erlang',
+ regex: ';|(?=\\.)',
+ next: 'pop' },
+ { include: '#parenthesized-expression' },
+ { include: '#internal-function-parts' } ] },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.function.erlang' } ] } ],
+ '#function-call':
+ [ { token: 'meta.function-call.erlang',
+ regex: '(?=(?:[a-z][a-zA-Z\\d@_]*|\'[^\']*\')\\s*(?:\\(|:\\s*(?:[a-z][a-zA-Z\\d@_]*|\'[^\']*\')\\s*\\())',
+ push:
+ [ { token: 'punctuation.definition.parameters.end.erlang',
+ regex: '\\)',
+ next: 'pop' },
+ { token:
+ [ 'entity.name.type.class.module.erlang',
+ 'text',
+ 'punctuation.separator.module-function.erlang',
+ 'text',
+ 'entity.name.function.guard.erlang',
+ 'text',
+ 'punctuation.definition.parameters.begin.erlang' ],
+ regex: '(?:(erlang)(\\s*)(:)(\\s*))?(is_atom|is_binary|is_constant|is_float|is_function|is_integer|is_list|is_number|is_pid|is_port|is_reference|is_tuple|is_record|abs|element|hd|length|node|round|self|size|tl|trunc)(\\s*)(\\()',
+ push:
+ [ { token: 'text', regex: '(?=\\))', next: 'pop' },
+ { token: 'punctuation.separator.parameters.erlang', regex: ',' },
+ { include: '#everything-else' } ] },
+ { token:
+ [ 'entity.name.type.class.module.erlang',
+ 'text',
+ 'punctuation.separator.module-function.erlang',
+ 'text',
+ 'entity.name.function.erlang',
+ 'text',
+ 'punctuation.definition.parameters.begin.erlang' ],
+ regex: '(?:([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(:)(\\s*))?([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(\\()',
+ push:
+ [ { token: 'text', regex: '(?=\\))', next: 'pop' },
+ { token: 'punctuation.separator.parameters.erlang', regex: ',' },
+ { include: '#everything-else' } ] },
+ { defaultToken: 'meta.function-call.erlang' } ] } ],
+ '#import-export-directive':
+ [ { token:
+ [ 'meta.directive.import.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.import.erlang',
+ 'keyword.control.directive.import.erlang',
+ 'meta.directive.import.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.import.erlang',
+ 'entity.name.type.class.module.erlang',
+ 'meta.directive.import.erlang',
+ 'punctuation.separator.parameters.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(import)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(,)',
+ push:
+ [ { token:
+ [ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.import.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '(\\))(\\s*)(\\.)',
+ next: 'pop' },
+ { include: '#internal-function-list' },
+ { defaultToken: 'meta.directive.import.erlang' } ] },
+ { token:
+ [ 'meta.directive.export.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.export.erlang',
+ 'keyword.control.directive.export.erlang',
+ 'meta.directive.export.erlang',
+ 'punctuation.definition.parameters.begin.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(export)(\\s*)(\\()',
+ push:
+ [ { token:
+ [ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.export.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '(\\))(\\s*)(\\.)',
+ next: 'pop' },
+ { include: '#internal-function-list' },
+ { defaultToken: 'meta.directive.export.erlang' } ] } ],
+ '#internal-expression-punctuation':
+ [ { token:
+ [ 'punctuation.separator.clause-head-body.erlang',
+ 'punctuation.separator.clauses.erlang',
+ 'punctuation.separator.expressions.erlang' ],
+ regex: '(->)|(;)|(,)' } ],
+ '#internal-function-list':
+ [ { token: 'punctuation.definition.list.begin.erlang',
+ regex: '\\[',
+ push:
+ [ { token: 'punctuation.definition.list.end.erlang',
+ regex: '\\]',
+ next: 'pop' },
+ { token:
+ [ 'entity.name.function.erlang',
+ 'text',
+ 'punctuation.separator.function-arity.erlang' ],
+ regex: '([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(/)',
+ push:
+ [ { token: 'punctuation.separator.list.erlang',
+ regex: ',|(?=\\])',
+ next: 'pop' },
+ { include: '#everything-else' } ] },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.structure.list.function.erlang' } ] } ],
+ '#internal-function-parts':
+ [ { token: 'text',
+ regex: '(?=\\()',
+ push:
+ [ { token: 'punctuation.separator.clause-head-body.erlang',
+ regex: '->',
+ next: 'pop' },
+ { token: 'punctuation.definition.parameters.begin.erlang',
+ regex: '\\(',
+ push:
+ [ { token: 'punctuation.definition.parameters.end.erlang',
+ regex: '\\)',
+ next: 'pop' },
+ { token: 'punctuation.separator.parameters.erlang', regex: ',' },
+ { include: '#everything-else' } ] },
+ { token: 'punctuation.separator.guards.erlang', regex: ',|;' },
+ { include: '#everything-else' } ] },
+ { token: 'punctuation.separator.expressions.erlang',
+ regex: ',' },
+ { include: '#everything-else' } ],
+ '#internal-record-body':
+ [ { token: 'punctuation.definition.class.record.begin.erlang',
+ regex: '\\{',
+ push:
+ [ { token: 'meta.structure.record.erlang',
+ regex: '(?=\\})',
+ next: 'pop' },
+ { token:
+ [ 'variable.other.field.erlang',
+ 'variable.language.omitted.field.erlang',
+ 'text',
+ 'keyword.operator.assignment.erlang' ],
+ regex: '(?:([a-z][a-zA-Z\\d@_]*|\'[^\']*\')|(_))(\\s*)(=|::)',
+ push:
+ [ { token: 'punctuation.separator.class.record.erlang',
+ regex: ',|(?=\\})',
+ next: 'pop' },
+ { include: '#everything-else' } ] },
+ { token:
+ [ 'variable.other.field.erlang',
+ 'text',
+ 'punctuation.separator.class.record.erlang' ],
+ regex: '([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)((?:,)?)' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.structure.record.erlang' } ] } ],
+ '#internal-type-specifiers':
+ [ { token: 'punctuation.separator.value-type.erlang',
+ regex: '/',
+ push:
+ [ { token: 'text', regex: '(?=,|:|>>)', next: 'pop' },
+ { token:
+ [ 'storage.type.erlang',
+ 'storage.modifier.signedness.erlang',
+ 'storage.modifier.endianness.erlang',
+ 'storage.modifier.unit.erlang',
+ 'punctuation.separator.type-specifiers.erlang' ],
+ regex: '(integer|float|binary|bytes|bitstring|bits)|(signed|unsigned)|(big|little|native)|(unit)|(-)' } ] } ],
+ '#keyword':
+ [ { token: 'keyword.control.erlang',
+ regex: '\\b(?:after|begin|case|catch|cond|end|fun|if|let|of|query|try|receive|when)\\b' } ],
+ '#list':
+ [ { token: 'punctuation.definition.list.begin.erlang',
+ regex: '\\[',
+ push:
+ [ { token: 'punctuation.definition.list.end.erlang',
+ regex: '\\]',
+ next: 'pop' },
+ { token: 'punctuation.separator.list.erlang',
+ regex: '\\||\\|\\||,' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.structure.list.erlang' } ] } ],
+ '#macro-directive':
+ [ { token:
+ [ 'meta.directive.ifdef.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.ifdef.erlang',
+ 'keyword.control.directive.ifdef.erlang',
+ 'meta.directive.ifdef.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.ifdef.erlang',
+ 'entity.name.function.macro.erlang',
+ 'meta.directive.ifdef.erlang',
+ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.ifdef.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(ifdef)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\))(\\s*)(\\.)' },
+ { token:
+ [ 'meta.directive.ifndef.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.ifndef.erlang',
+ 'keyword.control.directive.ifndef.erlang',
+ 'meta.directive.ifndef.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.ifndef.erlang',
+ 'entity.name.function.macro.erlang',
+ 'meta.directive.ifndef.erlang',
+ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.ifndef.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(ifndef)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\))(\\s*)(\\.)' },
+ { token:
+ [ 'meta.directive.undef.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.undef.erlang',
+ 'keyword.control.directive.undef.erlang',
+ 'meta.directive.undef.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.undef.erlang',
+ 'entity.name.function.macro.erlang',
+ 'meta.directive.undef.erlang',
+ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.undef.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(undef)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\))(\\s*)(\\.)' } ],
+ '#macro-usage':
+ [ { token:
+ [ 'keyword.operator.macro.erlang',
+ 'meta.macro-usage.erlang',
+ 'entity.name.function.macro.erlang' ],
+ regex: '(\\?\\??)(\\s*)([a-zA-Z\\d@_]+)' } ],
+ '#module-directive':
+ [ { token:
+ [ 'meta.directive.module.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.module.erlang',
+ 'keyword.control.directive.module.erlang',
+ 'meta.directive.module.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.module.erlang',
+ 'entity.name.type.class.module.definition.erlang',
+ 'meta.directive.module.erlang',
+ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.module.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(module)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\))(\\s*)(\\.)' } ],
+ '#number':
+ [ { token: 'text',
+ regex: '(?=\\d)',
+ push:
+ [ { token: 'text', regex: '(?!\\d)', next: 'pop' },
+ { token:
+ [ 'constant.numeric.float.erlang',
+ 'punctuation.separator.integer-float.erlang',
+ 'constant.numeric.float.erlang',
+ 'punctuation.separator.float-exponent.erlang' ],
+ regex: '(\\d+)(\\.)(\\d+)((?:[eE][\\+\\-]?\\d+)?)' },
+ { token:
+ [ 'constant.numeric.integer.binary.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.binary.erlang' ],
+ regex: '(2)(#)([0-1]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-3.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-3.erlang' ],
+ regex: '(3)(#)([0-2]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-4.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-4.erlang' ],
+ regex: '(4)(#)([0-3]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-5.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-5.erlang' ],
+ regex: '(5)(#)([0-4]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-6.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-6.erlang' ],
+ regex: '(6)(#)([0-5]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-7.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-7.erlang' ],
+ regex: '(7)(#)([0-6]+)' },
+ { token:
+ [ 'constant.numeric.integer.octal.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.octal.erlang' ],
+ regex: '(8)(#)([0-7]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-9.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-9.erlang' ],
+ regex: '(9)(#)([0-8]+)' },
+ { token:
+ [ 'constant.numeric.integer.decimal.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.decimal.erlang' ],
+ regex: '(10)(#)(\\d+)' },
+ { token:
+ [ 'constant.numeric.integer.base-11.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-11.erlang' ],
+ regex: '(11)(#)([\\daA]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-12.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-12.erlang' ],
+ regex: '(12)(#)([\\da-bA-B]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-13.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-13.erlang' ],
+ regex: '(13)(#)([\\da-cA-C]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-14.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-14.erlang' ],
+ regex: '(14)(#)([\\da-dA-D]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-15.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-15.erlang' ],
+ regex: '(15)(#)([\\da-eA-E]+)' },
+ { token:
+ [ 'constant.numeric.integer.hexadecimal.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.hexadecimal.erlang' ],
+ regex: '(16)(#)([\\da-fA-F]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-17.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-17.erlang' ],
+ regex: '(17)(#)([\\da-gA-G]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-18.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-18.erlang' ],
+ regex: '(18)(#)([\\da-hA-H]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-19.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-19.erlang' ],
+ regex: '(19)(#)([\\da-iA-I]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-20.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-20.erlang' ],
+ regex: '(20)(#)([\\da-jA-J]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-21.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-21.erlang' ],
+ regex: '(21)(#)([\\da-kA-K]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-22.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-22.erlang' ],
+ regex: '(22)(#)([\\da-lA-L]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-23.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-23.erlang' ],
+ regex: '(23)(#)([\\da-mA-M]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-24.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-24.erlang' ],
+ regex: '(24)(#)([\\da-nA-N]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-25.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-25.erlang' ],
+ regex: '(25)(#)([\\da-oA-O]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-26.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-26.erlang' ],
+ regex: '(26)(#)([\\da-pA-P]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-27.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-27.erlang' ],
+ regex: '(27)(#)([\\da-qA-Q]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-28.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-28.erlang' ],
+ regex: '(28)(#)([\\da-rA-R]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-29.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-29.erlang' ],
+ regex: '(29)(#)([\\da-sA-S]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-30.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-30.erlang' ],
+ regex: '(30)(#)([\\da-tA-T]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-31.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-31.erlang' ],
+ regex: '(31)(#)([\\da-uA-U]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-32.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-32.erlang' ],
+ regex: '(32)(#)([\\da-vA-V]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-33.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-33.erlang' ],
+ regex: '(33)(#)([\\da-wA-W]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-34.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-34.erlang' ],
+ regex: '(34)(#)([\\da-xA-X]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-35.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-35.erlang' ],
+ regex: '(35)(#)([\\da-yA-Y]+)' },
+ { token:
+ [ 'constant.numeric.integer.base-36.erlang',
+ 'punctuation.separator.base-integer.erlang',
+ 'constant.numeric.integer.base-36.erlang' ],
+ regex: '(36)(#)([\\da-zA-Z]+)' },
+ { token: 'invalid.illegal.integer.erlang',
+ regex: '\\d+#[\\da-zA-Z]+' },
+ { token: 'constant.numeric.integer.decimal.erlang',
+ regex: '\\d+' } ] } ],
+ '#parenthesized-expression':
+ [ { token: 'punctuation.section.expression.begin.erlang',
+ regex: '\\(',
+ push:
+ [ { token: 'punctuation.section.expression.end.erlang',
+ regex: '\\)',
+ next: 'pop' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.expression.parenthesized' } ] } ],
+ '#record-directive':
+ [ { token:
+ [ 'meta.directive.record.erlang',
+ 'punctuation.section.directive.begin.erlang',
+ 'meta.directive.record.erlang',
+ 'keyword.control.directive.import.erlang',
+ 'meta.directive.record.erlang',
+ 'punctuation.definition.parameters.begin.erlang',
+ 'meta.directive.record.erlang',
+ 'entity.name.type.class.record.definition.erlang',
+ 'meta.directive.record.erlang',
+ 'punctuation.separator.parameters.erlang' ],
+ regex: '^(\\s*)(-)(\\s*)(record)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(,)',
+ push:
+ [ { token:
+ [ 'punctuation.definition.class.record.end.erlang',
+ 'meta.directive.record.erlang',
+ 'punctuation.definition.parameters.end.erlang',
+ 'meta.directive.record.erlang',
+ 'punctuation.section.directive.end.erlang' ],
+ regex: '(\\})(\\s*)(\\))(\\s*)(\\.)',
+ next: 'pop' },
+ { include: '#internal-record-body' },
+ { defaultToken: 'meta.directive.record.erlang' } ] } ],
+ '#record-usage':
+ [ { token:
+ [ 'keyword.operator.record.erlang',
+ 'meta.record-usage.erlang',
+ 'entity.name.type.class.record.erlang',
+ 'meta.record-usage.erlang',
+ 'punctuation.separator.record-field.erlang',
+ 'meta.record-usage.erlang',
+ 'variable.other.field.erlang' ],
+ regex: '(#)(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(\\.)(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')' },
+ { token:
+ [ 'keyword.operator.record.erlang',
+ 'meta.record-usage.erlang',
+ 'entity.name.type.class.record.erlang' ],
+ regex: '(#)(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')',
+ push:
+ [ { token: 'punctuation.definition.class.record.end.erlang',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#internal-record-body' },
+ { defaultToken: 'meta.record-usage.erlang' } ] } ],
+ '#string':
+ [ { token: 'punctuation.definition.string.begin.erlang',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.erlang',
+ regex: '"',
+ next: 'pop' },
+ { token:
+ [ 'punctuation.definition.escape.erlang',
+ 'constant.character.escape.erlang',
+ 'punctuation.definition.escape.erlang',
+ 'constant.character.escape.erlang',
+ 'constant.character.escape.erlang' ],
+ regex: '(\\\\)(?:([bdefnrstv\\\\\'"])|(\\^)([@-_])|([0-7]{1,3}))' },
+ { token: 'invalid.illegal.string.erlang', regex: '\\\\\\^?.?' },
+ { token:
+ [ 'punctuation.definition.placeholder.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'constant.other.placeholder.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'constant.other.placeholder.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'constant.other.placeholder.erlang',
+ 'constant.other.placeholder.erlang' ],
+ regex: '(~)(?:((?:\\-)?)(\\d+)|(\\*))?(?:(\\.)(?:(\\d+)|(\\*)))?(?:(\\.)(?:(\\*)|(.)))?([~cfegswpWPBX#bx\\+ni])' },
+ { token:
+ [ 'punctuation.definition.placeholder.erlang',
+ 'punctuation.separator.placeholder-parts.erlang',
+ 'constant.other.placeholder.erlang',
+ 'constant.other.placeholder.erlang' ],
+ regex: '(~)((?:\\*)?)((?:\\d+)?)([~du\\-#fsacl])' },
+ { token: 'invalid.illegal.string.erlang', regex: '~.?' },
+ { defaultToken: 'string.quoted.double.erlang' } ] } ],
+ '#symbolic-operator':
+ [ { token: 'keyword.operator.symbolic.erlang',
+ regex: '\\+\\+|\\+|--|-|\\*|/=|/|=/=|=:=|==|=<|=|<-|<|>=|>|!|::' } ],
+ '#textual-operator':
+ [ { token: 'keyword.operator.textual.erlang',
+ regex: '\\b(?:andalso|band|and|bxor|xor|bor|orelse|or|bnot|not|bsl|bsr|div|rem)\\b' } ],
+ '#tuple':
+ [ { token: 'punctuation.definition.tuple.begin.erlang',
+ regex: '\\{',
+ push:
+ [ { token: 'punctuation.definition.tuple.end.erlang',
+ regex: '\\}',
+ next: 'pop' },
+ { token: 'punctuation.separator.tuple.erlang', regex: ',' },
+ { include: '#everything-else' },
+ { defaultToken: 'meta.structure.tuple.erlang' } ] } ],
+ '#variable':
+ [ { token: [ 'variable.other.erlang', 'variable.language.omitted.erlang' ],
+ regex: '(_[a-zA-Z\\d@_]+|[A-Z][a-zA-Z\\d@_]*)|(_)' } ] }
+
+ this.normalizeRules();
+};
+
+ErlangHighlightRules.metaData = { comment: 'The recognition of function definitions and compiler directives (such as module, record and macro definitions) requires that each of the aforementioned constructs must be the first string inside a line (except for whitespace). Also, the function/module/record/macro names must be given unquoted. -- desp',
+ fileTypes: [ 'erl', 'hrl' ],
+ keyEquivalent: '^~E',
+ name: 'Erlang',
+ scopeName: 'source.erlang' }
+
+
+oop.inherits(ErlangHighlightRules, TextHighlightRules);
+
+exports.ErlangHighlightRules = ErlangHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/erlang",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/erlang_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ErlangHighlightRules = require("./erlang_highlight_rules").ErlangHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ErlangHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "%";
+ this.blockComment = null;
+ this.$id = "ace/mode/erlang";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-forth.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-forth.js
new file mode 100644
index 00000000..f960fd6a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-forth.js
@@ -0,0 +1,290 @@
+ace.define("ace/mode/forth_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ForthHighlightRules = function() {
+
+ this.$rules = { start: [ { include: '#forth' } ],
+ '#comment':
+ [ { token: 'comment.line.double-dash.forth',
+ regex: '(?:^|\\s)--\\s.*$',
+ comment: 'line comments for iForth' },
+ { token: 'comment.line.backslash.forth',
+ regex: '(?:^|\\s)\\\\[\\s\\S]*$',
+ comment: 'ANSI line comment' },
+ { token: 'comment.line.backslash-g.forth',
+ regex: '(?:^|\\s)\\\\[Gg] .*$',
+ comment: 'gForth line comment' },
+ { token: 'comment.block.forth',
+ regex: '(?:^|\\s)\\(\\*(?=\\s|$)',
+ push:
+ [ { token: 'comment.block.forth',
+ regex: '(?:^|\\s)\\*\\)(?=\\s|$)',
+ next: 'pop' },
+ { defaultToken: 'comment.block.forth' } ],
+ comment: 'multiline comments for iForth' },
+ { token: 'comment.block.documentation.forth',
+ regex: '\\bDOC\\b',
+ caseInsensitive: true,
+ push:
+ [ { token: 'comment.block.documentation.forth',
+ regex: '\\bENDDOC\\b',
+ caseInsensitive: true,
+ next: 'pop' },
+ { defaultToken: 'comment.block.documentation.forth' } ],
+ comment: 'documentation comments for iForth' },
+ { token: 'comment.line.parentheses.forth',
+ regex: '(?:^|\\s)\\.?\\( [^)]*\\)',
+ comment: 'ANSI line comment' } ],
+ '#constant':
+ [ { token: 'constant.language.forth',
+ regex: '(?:^|\\s)(?:TRUE|FALSE|BL|PI|CELL|C/L|R/O|W/O|R/W)(?=\\s|$)',
+ caseInsensitive: true},
+ { token: 'constant.numeric.forth',
+ regex: '(?:^|\\s)[$#%]?[-+]?[0-9]+(?:\\.[0-9]*e-?[0-9]+|\\.?[0-9a-fA-F]*)(?=\\s|$)'},
+ { token: 'constant.character.forth',
+ regex: '(?:^|\\s)(?:[&^]\\S|(?:"|\')\\S(?:"|\'))(?=\\s|$)'}],
+ '#forth':
+ [ { include: '#constant' },
+ { include: '#comment' },
+ { include: '#string' },
+ { include: '#word' },
+ { include: '#variable' },
+ { include: '#storage' },
+ { include: '#word-def' } ],
+ '#storage':
+ [ { token: 'storage.type.forth',
+ regex: '(?:^|\\s)(?:2CONSTANT|2VARIABLE|ALIAS|CONSTANT|CREATE-INTERPRET/COMPILE[:]?|CREATE|DEFER|FCONSTANT|FIELD|FVARIABLE|USER|VALUE|VARIABLE|VOCABULARY)(?=\\s|$)',
+ caseInsensitive: true}],
+ '#string':
+ [ { token: 'string.quoted.double.forth',
+ regex: '(ABORT" |BREAK" |\\." |C" |0"|S\\\\?" )([^"]+")',
+ caseInsensitive: true},
+ { token: 'string.unquoted.forth',
+ regex: '(?:INCLUDE|NEEDS|REQUIRE|USE)[ ]\\S+(?=\\s|$)',
+ caseInsensitive: true}],
+ '#variable':
+ [ { token: 'variable.language.forth',
+ regex: '\\b(?:I|J)\\b',
+ caseInsensitive: true } ],
+ '#word':
+ [ { token: 'keyword.control.immediate.forth',
+ regex: '(?:^|\\s)\\[(?:\\?DO|\\+LOOP|AGAIN|BEGIN|DEFINED|DO|ELSE|ENDIF|FOR|IF|IFDEF|IFUNDEF|LOOP|NEXT|REPEAT|THEN|UNTIL|WHILE)\\](?=\\s|$)',
+ caseInsensitive: true},
+ { token: 'keyword.other.immediate.forth',
+ regex: '(?:^|\\s)(?:COMPILE-ONLY|IMMEDIATE|IS|RESTRICT|TO|WHAT\'S|])(?=\\s|$)',
+ caseInsensitive: true},
+ { token: 'keyword.control.compile-only.forth',
+ regex: '(?:^|\\s)(?:-DO|\\-LOOP|\\?DO|\\?LEAVE|\\+DO|\\+LOOP|ABORT\\"|AGAIN|AHEAD|BEGIN|CASE|DO|ELSE|ENDCASE|ENDIF|ENDOF|ENDTRY\\-IFERROR|ENDTRY|FOR|IF|IFERROR|LEAVE|LOOP|NEXT|RECOVER|REPEAT|RESTORE|THEN|TRY|U\\-DO|U\\+DO|UNTIL|WHILE)(?=\\s|$)',
+ caseInsensitive: true},
+ { token: 'keyword.other.compile-only.forth',
+ regex: '(?:^|\\s)(?:\\?DUP-0=-IF|\\?DUP-IF|\\)|\\[|\\[\'\\]|\\[CHAR\\]|\\[COMPILE\\]|\\[IS\\]|\\[TO\\]|<COMPILATION|<INTERPRETATION|ASSERT\\(|ASSERT0\\(|ASSERT1\\(|ASSERT2\\(|ASSERT3\\(|COMPILATION>|DEFERS|DOES>|INTERPRETATION>|OF|POSTPONE)(?=\\s|$)',
+ caseInsensitive: true},
+ { token: 'keyword.other.non-immediate.forth',
+ regex: '(?:^|\\s)(?:\'|<IS>|<TO>|CHAR|END-STRUCT|INCLUDE[D]?|LOAD|NEEDS|REQUIRE[D]?|REVISION|SEE|STRUCT|THRU|USE)(?=\\s|$)',
+ caseInsensitive: true},
+ { token: 'keyword.other.warning.forth',
+ regex: '(?:^|\\s)(?:~~|BREAK:|BREAK"|DBG)(?=\\s|$)',
+ caseInsensitive: true}],
+ '#word-def':
+ [ { token:
+ [ 'keyword.other.compile-only.forth',
+ 'keyword.other.compile-only.forth',
+ 'meta.block.forth',
+ 'entity.name.function.forth' ],
+ regex: '(:NONAME)|(^:|\\s:)(\\s)(\\S+)(?=\\s|$)',
+ caseInsensitive: true,
+ push:
+ [ { token: 'keyword.other.compile-only.forth',
+ regex: ';(?:CODE)?',
+ caseInsensitive: true,
+ next: 'pop' },
+ { include: '#constant' },
+ { include: '#comment' },
+ { include: '#string' },
+ { include: '#word' },
+ { include: '#variable' },
+ { include: '#storage' },
+ { defaultToken: 'meta.block.forth' } ] } ] }
+
+ this.normalizeRules();
+};
+
+ForthHighlightRules.metaData = { fileTypes: [ 'frt', 'fs', 'ldr', 'fth', '4th' ],
+ foldingStartMarker: '/\\*\\*|\\{\\s*$',
+ foldingStopMarker: '\\*\\*/|^\\s*\\}',
+ keyEquivalent: '^~F',
+ name: 'Forth',
+ scopeName: 'source.forth' }
+
+
+oop.inherits(ForthHighlightRules, TextHighlightRules);
+
+exports.ForthHighlightRules = ForthHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/forth",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/forth_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ForthHighlightRules = require("./forth_highlight_rules").ForthHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ForthHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = null;
+ this.$id = "ace/mode/forth";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-fortran.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-fortran.js
new file mode 100644
index 00000000..3f2c5bdb
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-fortran.js
@@ -0,0 +1,423 @@
+ace.define("ace/mode/fortran_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var FortranHighlightRules = function() {
+
+ var keywords = (
+ "call|case|contains|continue|cycle|do|else|elseif|end|enddo|endif|function|"+
+ "if|implicit|in|include|inout|intent|module|none|only|out|print|program|return|"+
+ "select|status|stop|subroutine|" +
+ "return|then|use|while|write|"+
+ "CALL|CASE|CONTAINS|CONTINUE|CYCLE|DO|ELSE|ELSEIF|END|ENDDO|ENDIF|FUNCTION|"+
+ "IF|IMPLICIT|IN|INCLUDE|INOUT|INTENT|MODULE|NONE|ONLY|OUT|PRINT|PROGRAM|RETURN|"+
+ "SELECT|STATUS|STOP|SUBROUTINE|" +
+ "RETURN|THEN|USE|WHILE|WRITE"
+ );
+
+ var keywordOperators = (
+ "and|or|not|eq|ne|gt|ge|lt|le|" +
+ "AND|OR|NOT|EQ|NE|GT|GE|LT|LE"
+ );
+
+ var builtinConstants = (
+ "true|false|TRUE|FALSE"
+ );
+
+ var builtinFunctions = (
+ "abs|achar|acos|acosh|adjustl|adjustr|aimag|aint|all|allocate|"+
+ "anint|any|asin|asinh|associated|atan|atan2|atanh|"+
+ "bessel_j0|bessel_j1|bessel_jn|bessel_y0|bessel_y1|bessel_yn|"+
+ "bge|bgt|bit_size|ble|blt|btest|ceiling|char|cmplx|conjg|cos|cosh|"+
+ "count|cpu_time|cshift|date_and_time|dble|deallocate|digits|dim|dot_product|dprod|"+
+ "dshiftl|dshiftr|dsqrt|eoshift|epsilon|erf|erfc|erfc_scaled|exp|float|floor|"+
+ "format|fraction|gamma|input|len|lge|lgt|lle|llt|log|log10|maskl|maskr|matmul|max|maxloc|maxval|"+
+ "merge|min|minloc|minval|mod|modulo|nint|not|norm2|null|nullify|pack|parity|popcnt|poppar|"+
+ "precision|present|product|radix|random_number|random_seed|range|repeat|reshape|round|"+
+ "rrspacing|same_type_as|scale|scan|selected_char_kind|selected_int_kind|selected_real_kind|"+
+ "set_exponent|shape|shifta|shiftl|shiftr|sign|sin|sinh|size|sngl|spacing|spread|"+
+ "sqrt|sum|system_clock|tan|tanh|tiny|trailz|transfer|transpose|trim|ubound|unpack|verify|" +
+ "ABS|ACHAR|ACOS|ACOSH|ADJUSTL|ADJUSTR|AIMAG|AINT|ALL|ALLOCATE|"+
+ "ANINT|ANY|ASIN|ASINH|ASSOCIATED|ATAN|ATAN2|ATANH|"+
+ "BESSEL_J0|BESSEL_J1|BESSEL_JN|BESSEL_Y0|BESSEL_Y1|BESSEL_YN|"+
+ "BGE|BGT|BIT_SIZE|BLE|BLT|BTEST|CEILING|CHAR|CMPLX|CONJG|COS|COSH|"+
+ "COUNT|CPU_TIME|CSHIFT|DATE_AND_TIME|DBLE|DEALLOCATE|DIGITS|DIM|DOT_PRODUCT|DPROD|"+
+ "DSHIFTL|DSHIFTR|DSQRT|EOSHIFT|EPSILON|ERF|ERFC|ERFC_SCALED|EXP|FLOAT|FLOOR|"+
+ "FORMAT|FRACTION|GAMMA|INPUT|LEN|LGE|LGT|LLE|LLT|LOG|LOG10|MASKL|MASKR|MATMUL|MAX|MAXLOC|MAXVAL|"+
+ "MERGE|MIN|MINLOC|MINVAL|MOD|MODULO|NINT|NOT|NORM2|NULL|NULLIFY|PACK|PARITY|POPCNT|POPPAR|"+
+ "PRECISION|PRESENT|PRODUCT|RADIX|RANDOM_NUMBER|RANDOM_SEED|RANGE|REPEAT|RESHAPE|ROUND|"+
+ "RRSPACING|SAME_TYPE_AS|SCALE|SCAN|SELECTED_CHAR_KIND|SELECTED_INT_KIND|SELECTED_REAL_KIND|"+
+ "SET_EXPONENT|SHAPE|SHIFTA|SHIFTL|SHIFTR|SIGN|SIN|SINH|SIZE|SNGL|SPACING|SPREAD|"+
+ "SQRT|SUM|SYSTEM_CLOCK|TAN|TANH|TINY|TRAILZ|TRANSFER|TRANSPOSE|TRIM|UBOUND|UNPACK|VERIFY"
+ );
+
+ var storageType = (
+ "logical|character|integer|real|type|" +
+ "LOGICAL|CHARACTER|INTEGER|REAL|TYPE"
+ );
+
+ var storageModifiers = (
+ "allocatable|dimension|intent|parameter|pointer|target|private|public|" +
+ "ALLOCATABLE|DIMENSION|INTENT|PARAMETER|POINTER|TARGET|PRIVATE|PUBLIC"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "invalid.deprecated": "debugger",
+ "support.function": builtinFunctions,
+ "constant.language": builtinConstants,
+ "keyword": keywords,
+ "keyword.operator": keywordOperators,
+ "storage.type": storageType,
+ "storage.modifier" : storageModifiers
+ }, "identifier");
+
+ var strPre = "(?:r|u|ur|R|U|UR|Ur|uR)?";
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var octInteger = "(?:0[oO]?[0-7]+)";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var binInteger = "(?:0[bB][01]+)";
+ var integer = "(?:" + decimalInteger + "|" + octInteger + "|" + hexInteger + "|" + binInteger + ")";
+
+ var exponent = "(?:[eE][+-]?\\d+)";
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + exponent + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+
+ var stringEscape = "\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'\"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})";
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "!.*$"
+ }, {
+ token : "string", // multi line """ string start
+ regex : strPre + '"{3}',
+ next : "qqstring3"
+ }, {
+ token : "string", // " string
+ regex : strPre + '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "string", // multi line ''' string start
+ regex : strPre + "'{3}",
+ next : "qstring3"
+ }, {
+ token : "string", // ' string
+ regex : strPre + "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // imaginary
+ regex : "(?:" + floatNumber + "|\\d+)[jJ]\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // long integer
+ regex : integer + "[lL]\\b"
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|define|undef|INCLUDE|IMPORT|DEFINE|UNDEF)\\b"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|ifdef|else|elseif|ifndef|ENDIF|IFDEF|ELSE|ELSEIF|IFNDEF)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|%|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ],
+ "qqstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line """ string end
+ regex : '"{3}',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ } ],
+ "qstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line """ string end
+ regex : '"{3}',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ } ],
+ "qqstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }],
+ "qstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }]
+ };
+};
+
+oop.inherits(FortranHighlightRules, TextHighlightRules);
+
+exports.FortranHighlightRules = FortranHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/fortran",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/fortran_highlight_rules","ace/mode/folding/cstyle","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var FortranHighlightRules = require("./fortran_highlight_rules").FortranHighlightRules;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = FortranHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "!";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ var outdents = {
+ "return": 1,
+ "break": 1,
+ "continue": 1,
+ "RETURN": 1,
+ "BREAK": 1,
+ "CONTINUE": 1
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input !== "\r\n" && input !== "\r" && input !== "\n")
+ return false;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens)
+ return false;
+ do {
+ var last = tokens.pop();
+ } while (last && (last.type == "comment" || (last.type == "text" && last.value.match(/^\s+$/))));
+
+ if (!last)
+ return false;
+
+ return (last.type == "keyword" && outdents[last.value]);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+
+ row += 1;
+ var indent = this.$getIndent(doc.getLine(row));
+ var tab = doc.getTabString();
+ if (indent.slice(-tab.length) == tab)
+ doc.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ };
+
+ this.$id = "ace/mode/fortran";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-ftl.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-ftl.js
new file mode 100644
index 00000000..dbca4fd1
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-ftl.js
@@ -0,0 +1,1182 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/ftl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var FtlLangHighlightRules = function () {
+
+ var stringBuiltIns = "\\?|substring|cap_first|uncap_first|capitalize|chop_linebreak|date|time|datetime|"
+ + "ends_with|html|groups|index_of|j_string|js_string|json_string|last_index_of|length|lower_case|"
+ + "left_pad|right_pad|contains|matches|number|replace|rtf|url|split|starts_with|string|trim|"
+ + "upper_case|word_list|xhtml|xml";
+ var numberBuiltIns = "c|round|floor|ceiling";
+ var dateBuiltIns = "iso_[a-z_]+";
+ var seqBuiltIns = "first|last|seq_contains|seq_index_of|seq_last_index_of|reverse|size|sort|sort_by|chunk";
+ var hashBuiltIns = "keys|values";
+ var xmlBuiltIns = "children|parent|root|ancestors|node_name|node_type|node_namespace";
+ var expertBuiltIns = "byte|double|float|int|long|short|number_to_date|number_to_time|number_to_datetime|"
+ + "eval|has_content|interpret|is_[a-z_]+|namespacenew";
+ var allBuiltIns = stringBuiltIns + numberBuiltIns + dateBuiltIns + seqBuiltIns + hashBuiltIns
+ + xmlBuiltIns + expertBuiltIns;
+
+ var deprecatedBuiltIns = "default|exists|if_exists|web_safe";
+
+ var variables = "data_model|error|globals|lang|locale|locals|main|namespace|node|current_node|"
+ + "now|output_encoding|template_name|url_escaping_charset|vars|version";
+
+ var operators = "gt|gte|lt|lte|as|in|using";
+
+ var reserved = "true|false";
+
+ var attributes = "encoding|parse|locale|number_format|date_format|time_format|datetime_format|time_zone|"
+ + "url_escaping_charset|classic_compatible|strip_whitespace|strip_text|strict_syntax|ns_prefixes|"
+ + "attributes";
+
+ this.$rules = {
+ "start" : [{
+ token : "constant.character.entity",
+ regex : /&[^;]+;/
+ }, {
+ token : "support.function",
+ regex : "\\?("+allBuiltIns+")"
+ }, {
+ token : "support.function.deprecated",
+ regex : "\\?("+deprecatedBuiltIns+")"
+ }, {
+ token : "language.variable",
+ regex : "\\.(?:"+variables+")"
+ }, {
+ token : "constant.language",
+ regex : "\\b("+reserved+")\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\b(?:"+operators+")\\b"
+ }, {
+ token : "entity.other.attribute-name",
+ regex : attributes
+ }, {
+ token : "string", //
+ regex : /['"]/,
+ next : "qstring"
+ }, {
+ token : function(value) {
+ if (value.match("^[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?$")) {
+ return "constant.numeric";
+ } else {
+ return "variable";
+ }
+ },
+ regex : /[\w.+\-]+/
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\.|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^="
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }],
+
+ "qstring" : [{
+ token : "constant.character.escape",
+ regex : '\\\\[nrtvef\\\\"$]'
+ }, {
+ token : "string",
+ regex : /['"]/,
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }]
+ };
+};
+
+oop.inherits(FtlLangHighlightRules, TextHighlightRules);
+
+var FtlHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var directives = "assign|attempt|break|case|compress|default|elseif|else|escape|fallback|function|flush|"
+ + "ftl|global|if|import|include|list|local|lt|macro|nested|noescape|noparse|nt|recover|recurse|return|rt|"
+ + "setting|stop|switch|t|visit";
+
+ var startRules = [
+ {
+ token : "comment",
+ regex : "<#--",
+ next : "ftl-dcomment"
+ }, {
+ token : "string.interpolated",
+ regex : "\\${",
+ push : "ftl-start"
+ }, {
+ token : "keyword.function",
+ regex : "</?#("+directives+")",
+ push : "ftl-start"
+ }, {
+ token : "keyword.other",
+ regex : "</?@[a-zA-Z\\.]+",
+ push : "ftl-start"
+ }
+ ];
+
+ var endRules = [
+ {
+ token : "keyword",
+ regex : "/?>",
+ next : "pop"
+ }, {
+ token : "string.interpolated",
+ regex : "}",
+ next : "pop"
+ }
+ ];
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], startRules);
+
+ this.embedRules(FtlLangHighlightRules, "ftl-", endRules, ["start"]);
+
+ this.addRules({
+ "ftl-dcomment" : [{
+ token : "comment",
+ regex : "-->",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ });
+
+ this.normalizeRules();
+};
+
+oop.inherits(FtlHighlightRules, HtmlHighlightRules);
+
+exports.FtlHighlightRules = FtlHighlightRules;
+});
+
+ace.define("ace/mode/ftl",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ftl_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var FtlHighlightRules = require("./ftl_highlight_rules").FtlHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = FtlHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.$id = "ace/mode/ftl";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-gcode.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-gcode.js
new file mode 100644
index 00000000..a648426c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-gcode.js
@@ -0,0 +1,86 @@
+ace.define("ace/mode/gcode_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ var GcodeHighlightRules = function() {
+
+ var keywords = (
+ "IF|DO|WHILE|ENDWHILE|CALL|ENDIF|SUB|ENDSUB|GOTO|REPEAT|ENDREPEAT|CALL"
+ );
+
+ var builtinConstants = (
+ "PI"
+ );
+
+ var builtinFunctions = (
+ "ATAN|ABS|ACOS|ASIN|SIN|COS|EXP|FIX|FUP|ROUND|LN|TAN"
+ );
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords,
+ "constant.language": builtinConstants
+ }, "identifier", true);
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "\\(.*\\)"
+ }, {
+ token : "comment", // block number
+ regex : "([N])([0-9]+)"
+ }, {
+ token : "string", // " string
+ regex : "([G])([0-9]+\\.?[0-9]?)"
+ }, {
+ token : "string", // ' string
+ regex : "([M])([0-9]+\\.?[0-9]?)"
+ }, {
+ token : "constant.numeric", // float
+ regex : "([-+]?([0-9]*\\.?[0-9]+\\.?))|(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)"
+ }, {
+ token : keywordMapper,
+ regex : "[A-Z]"
+ }, {
+ token : "keyword.operator",
+ regex : "EQ|LT|GT|NE|GE|LE|OR|XOR"
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+ };
+ };
+
+ oop.inherits(GcodeHighlightRules, TextHighlightRules);
+
+ exports.GcodeHighlightRules = GcodeHighlightRules;
+});
+
+ace.define("ace/mode/gcode",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/gcode_highlight_rules","ace/range"], function(require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var TextMode = require("./text").Mode;
+ var GcodeHighlightRules = require("./gcode_highlight_rules").GcodeHighlightRules;
+ var Range = require("../range").Range;
+
+ var Mode = function() {
+ this.HighlightRules = GcodeHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+ };
+ oop.inherits(Mode, TextMode);
+
+ (function() {
+ this.$id = "ace/mode/gcode";
+ }).call(Mode.prototype);
+
+ exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-gherkin.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-gherkin.js
new file mode 100644
index 00000000..322dbe40
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-gherkin.js
@@ -0,0 +1,163 @@
+ace.define("ace/mode/gherkin_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var stringEscape = "\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'\"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})";
+
+var GherkinHighlightRules = function() {
+ var languages = [{
+ name: "en",
+ labels: "Feature|Background|Scenario(?: Outline)?|Examples",
+ keywords: "Given|When|Then|And|But"
+ }];
+
+ var labels = languages.map(function(l) {
+ return l.labels;
+ }).join("|");
+ var keywords = languages.map(function(l) {
+ return l.keywords;
+ }).join("|");
+ this.$rules = {
+ start : [{
+ token: "constant.numeric",
+ regex: "(?:(?:[1-9]\\d*)|(?:0))"
+ }, {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "keyword",
+ regex : "(?:" + labels + "):|(?:" + keywords + ")\\b"
+ }, {
+ token : "keyword",
+ regex : "\\*"
+ }, {
+ token : "string", // multi line """ string start
+ regex : '"{3}',
+ next : "qqstring3"
+ }, {
+ token : "string", // " string
+ regex : '"',
+ next : "qqstring"
+ }, {
+ token : "text",
+ regex : "^\\s*(?=@[\\w])",
+ next : [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : "variable.parameter",
+ regex : "@[\\w]+"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "start"
+ }]
+ }, {
+ token : "comment",
+ regex : "<[^>]+>"
+ }, {
+ token : "comment",
+ regex : "\\|(?=.)",
+ next : "table-item"
+ }, {
+ token : "comment",
+ regex : "\\|$",
+ next : "start"
+ }],
+ "qqstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line """ string end
+ regex : '"{3}',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }],
+ "qqstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }],
+ "table-item" : [{
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ token : "comment",
+ regex : /\|/
+ }, {
+ token : "string",
+ regex : /\\./
+ }, {
+ defaultToken : "string"
+ }]
+ };
+ this.normalizeRules();
+}
+
+oop.inherits(GherkinHighlightRules, TextHighlightRules);
+
+exports.GherkinHighlightRules = GherkinHighlightRules;
+});
+
+ace.define("ace/mode/gherkin",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/gherkin_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var GherkinHighlightRules = require("./gherkin_highlight_rules").GherkinHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = GherkinHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/gherkin";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var space2 = " ";
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ console.log(state)
+
+ if(line.match("[ ]*\\|")) {
+ indent += "| ";
+ }
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+
+ if (state == "start") {
+ if (line.match("Scenario:|Feature:|Scenario Outline:|Background:")) {
+ indent += space2;
+ } else if(line.match("(Given|Then).+(:)$|Examples:")) {
+ indent += space2;
+ } else if(line.match("\\*.+")) {
+ indent += "* ";
+ }
+ }
+
+
+ return indent;
+ };
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-gitignore.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-gitignore.js
new file mode 100644
index 00000000..c3eac559
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-gitignore.js
@@ -0,0 +1,52 @@
+ace.define("ace/mode/gitignore_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var GitignoreHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : /^\s*#.*$/
+ }, {
+ token : "keyword", // negated patterns
+ regex : /^\s*!.*$/
+ }
+ ]
+ };
+
+ this.normalizeRules();
+};
+
+GitignoreHighlightRules.metaData = {
+ fileTypes: ['gitignore'],
+ name: 'Gitignore'
+};
+
+oop.inherits(GitignoreHighlightRules, TextHighlightRules);
+
+exports.GitignoreHighlightRules = GitignoreHighlightRules;
+});
+
+ace.define("ace/mode/gitignore",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/gitignore_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var GitignoreHighlightRules = require("./gitignore_highlight_rules").GitignoreHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = GitignoreHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/gitignore";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-glsl.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-glsl.js
new file mode 100644
index 00000000..ee95feea
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-glsl.js
@@ -0,0 +1,564 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/c_cpp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var cFunctions = exports.cFunctions = "\\b(?:hypot(?:f|l)?|s(?:scanf|ystem|nprintf|ca(?:nf|lb(?:n(?:f|l)?|ln(?:f|l)?))|i(?:n(?:h(?:f|l)?|f|l)?|gn(?:al|bit))|tr(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?)|error|pbrk|ftime|len|rchr|xfrm)|printf|et(?:jmp|vbuf|locale|buf)|qrt(?:f|l)?|w(?:scanf|printf)|rand)|n(?:e(?:arbyint(?:f|l)?|xt(?:toward(?:f|l)?|after(?:f|l)?))|an(?:f|l)?)|c(?:s(?:in(?:h(?:f|l)?|f|l)?|qrt(?:f|l)?)|cos(?:h(?:f)?|f|l)?|imag(?:f|l)?|t(?:ime|an(?:h(?:f|l)?|f|l)?)|o(?:s(?:h(?:f|l)?|f|l)?|nj(?:f|l)?|pysign(?:f|l)?)|p(?:ow(?:f|l)?|roj(?:f|l)?)|e(?:il(?:f|l)?|xp(?:f|l)?)|l(?:o(?:ck|g(?:f|l)?)|earerr)|a(?:sin(?:h(?:f|l)?|f|l)?|cos(?:h(?:f|l)?|f|l)?|tan(?:h(?:f|l)?|f|l)?|lloc|rg(?:f|l)?|bs(?:f|l)?)|real(?:f|l)?|brt(?:f|l)?)|t(?:ime|o(?:upper|lower)|an(?:h(?:f|l)?|f|l)?|runc(?:f|l)?|gamma(?:f|l)?|mp(?:nam|file))|i(?:s(?:space|n(?:ormal|an)|cntrl|inf|digit|u(?:nordered|pper)|p(?:unct|rint)|finite|w(?:space|c(?:ntrl|type)|digit|upper|p(?:unct|rint)|lower|al(?:num|pha)|graph|xdigit|blank)|l(?:ower|ess(?:equal|greater)?)|al(?:num|pha)|gr(?:eater(?:equal)?|aph)|xdigit|blank)|logb(?:f|l)?|max(?:div|abs))|di(?:v|fftime)|_Exit|unget(?:c|wc)|p(?:ow(?:f|l)?|ut(?:s|c(?:har)?|wc(?:har)?)|error|rintf)|e(?:rf(?:c(?:f|l)?|f|l)?|x(?:it|p(?:2(?:f|l)?|f|l|m1(?:f|l)?)?))|v(?:s(?:scanf|nprintf|canf|printf|w(?:scanf|printf))|printf|f(?:scanf|printf|w(?:scanf|printf))|w(?:scanf|printf)|a_(?:start|copy|end|arg))|qsort|f(?:s(?:canf|e(?:tpos|ek))|close|tell|open|dim(?:f|l)?|p(?:classify|ut(?:s|c|w(?:s|c))|rintf)|e(?:holdexcept|set(?:e(?:nv|xceptflag)|round)|clearexcept|testexcept|of|updateenv|r(?:aiseexcept|ror)|get(?:e(?:nv|xceptflag)|round))|flush|w(?:scanf|ide|printf|rite)|loor(?:f|l)?|abs(?:f|l)?|get(?:s|c|pos|w(?:s|c))|re(?:open|e|ad|xp(?:f|l)?)|m(?:in(?:f|l)?|od(?:f|l)?|a(?:f|l|x(?:f|l)?)?))|l(?:d(?:iv|exp(?:f|l)?)|o(?:ngjmp|cal(?:time|econv)|g(?:1(?:p(?:f|l)?|0(?:f|l)?)|2(?:f|l)?|f|l|b(?:f|l)?)?)|abs|l(?:div|abs|r(?:int(?:f|l)?|ound(?:f|l)?))|r(?:int(?:f|l)?|ound(?:f|l)?)|gamma(?:f|l)?)|w(?:scanf|c(?:s(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?|mbs)|pbrk|ftime|len|r(?:chr|tombs)|xfrm)|to(?:b|mb)|rtomb)|printf|mem(?:set|c(?:hr|py|mp)|move))|a(?:s(?:sert|ctime|in(?:h(?:f|l)?|f|l)?)|cos(?:h(?:f|l)?|f|l)?|t(?:o(?:i|f|l(?:l)?)|exit|an(?:h(?:f|l)?|2(?:f|l)?|f|l)?)|b(?:s|ort))|g(?:et(?:s|c(?:har)?|env|wc(?:har)?)|mtime)|r(?:int(?:f|l)?|ound(?:f|l)?|e(?:name|alloc|wind|m(?:ove|quo(?:f|l)?|ainder(?:f|l)?))|a(?:nd|ise))|b(?:search|towc)|m(?:odf(?:f|l)?|em(?:set|c(?:hr|py|mp)|move)|ktime|alloc|b(?:s(?:init|towcs|rtowcs)|towc|len|r(?:towc|len))))\\b"
+
+var c_cppHighlightRules = function() {
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|goto|if|_Pragma|" +
+ "return|switch|while|catch|operator|try|throw|using"
+ );
+
+ var storageType = (
+ "asm|__asm__|auto|bool|_Bool|char|_Complex|double|enum|float|" +
+ "_Imaginary|int|long|short|signed|struct|typedef|union|unsigned|void|" +
+ "class|wchar_t|template|char16_t|char32_t"
+ );
+
+ var storageModifiers = (
+ "const|extern|register|restrict|static|volatile|inline|private|" +
+ "protected|public|friend|explicit|virtual|export|mutable|typename|" +
+ "constexpr|new|delete|alignas|alignof|decltype|noexcept|thread_local"
+ );
+
+ var keywordOperators = (
+ "and|and_eq|bitand|bitor|compl|not|not_eq|or|or_eq|typeid|xor|xor_eq" +
+ "const_cast|dynamic_cast|reinterpret_cast|static_cast|sizeof|namespace"
+ );
+
+ var builtinConstants = (
+ "NULL|true|false|TRUE|FALSE|nullptr"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.control" : keywordControls,
+ "storage.type" : storageType,
+ "storage.modifier" : storageModifiers,
+ "keyword.operator" : keywordOperators,
+ "variable.language": "this",
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+ var escapeRe = /\\(?:['"?\\abfnrtv]|[0-7]{1,3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}U[a-fA-F\d]{8}|.)/.source;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "//$",
+ next : "start"
+ }, {
+ token : "comment",
+ regex : "//",
+ next : "singleLineComment"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : "'(?:" + escapeRe + "|.)?'"
+ }, {
+ token : "string.start",
+ regex : '"',
+ stateName: "qqstring",
+ next: [
+ { token: "string", regex: /\\\s*$/, next: "qqstring" },
+ { token: "constant.language.escape", regex: escapeRe },
+ { token: "constant.language.escape", regex: /%[^'"\\]/ },
+ { token: "string.end", regex: '"|$', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "string.start",
+ regex : 'R"\\(',
+ stateName: "rawString",
+ next: [
+ { token: "string.end", regex: '\\)"', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|pragma|line|define|undef)\\b",
+ next : "directive"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|if|ifdef|else|elif|ifndef)\\b"
+ }, {
+ token : "support.function.C99.c",
+ regex : cFunctions
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|<<=|>>=|>>>=|<>|&&|\|\||\?:|[*%\/+\-&\^|~!<>=]=?/
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "singleLineComment" : [
+ {
+ token : "comment",
+ regex : /\\$/,
+ next : "singleLineComment"
+ }, {
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ],
+ "directive" : [
+ {
+ token : "constant.other.multiline",
+ regex : /\\/
+ },
+ {
+ token : "constant.other.multiline",
+ regex : /.*\\/
+ },
+ {
+ token : "constant.other",
+ regex : "\\s*<.+?>",
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : '\\s*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]',
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
+ next : "start"
+ },
+ {
+ token : "constant.other",
+ regex : /[^\\\/]+/,
+ next : "start"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(c_cppHighlightRules, TextHighlightRules);
+
+exports.c_cppHighlightRules = c_cppHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/c_cpp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c_cpp_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var c_cppHighlightRules = require("./c_cpp_highlight_rules").c_cppHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = c_cppHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/c_cpp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/glsl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/c_cpp_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var c_cppHighlightRules = require("./c_cpp_highlight_rules").c_cppHighlightRules;
+
+var glslHighlightRules = function() {
+
+ var keywords = (
+ "attribute|const|uniform|varying|break|continue|do|for|while|" +
+ "if|else|in|out|inout|float|int|void|bool|true|false|" +
+ "lowp|mediump|highp|precision|invariant|discard|return|mat2|mat3|" +
+ "mat4|vec2|vec3|vec4|ivec2|ivec3|ivec4|bvec2|bvec3|bvec4|sampler2D|" +
+ "samplerCube|struct"
+ );
+
+ var buildinConstants = (
+ "radians|degrees|sin|cos|tan|asin|acos|atan|pow|" +
+ "exp|log|exp2|log2|sqrt|inversesqrt|abs|sign|floor|ceil|fract|mod|" +
+ "min|max|clamp|mix|step|smoothstep|length|distance|dot|cross|" +
+ "normalize|faceforward|reflect|refract|matrixCompMult|lessThan|" +
+ "lessThanEqual|greaterThan|greaterThanEqual|equal|notEqual|any|all|" +
+ "not|dFdx|dFdy|fwidth|texture2D|texture2DProj|texture2DLod|" +
+ "texture2DProjLod|textureCube|textureCubeLod|" +
+ "gl_MaxVertexAttribs|gl_MaxVertexUniformVectors|gl_MaxVaryingVectors|" +
+ "gl_MaxVertexTextureImageUnits|gl_MaxCombinedTextureImageUnits|" +
+ "gl_MaxTextureImageUnits|gl_MaxFragmentUniformVectors|gl_MaxDrawBuffers|" +
+ "gl_DepthRangeParameters|gl_DepthRange|" +
+ "gl_Position|gl_PointSize|" +
+ "gl_FragCoord|gl_FrontFacing|gl_PointCoord|gl_FragColor|gl_FragData"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": buildinConstants
+ }, "identifier");
+
+ this.$rules = new c_cppHighlightRules().$rules;
+ this.$rules.start.forEach(function(rule) {
+ if (typeof rule.token == "function")
+ rule.token = keywordMapper;
+ })
+};
+
+oop.inherits(glslHighlightRules, c_cppHighlightRules);
+
+exports.glslHighlightRules = glslHighlightRules;
+});
+
+ace.define("ace/mode/glsl",["require","exports","module","ace/lib/oop","ace/mode/c_cpp","ace/mode/glsl_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var CMode = require("./c_cpp").Mode;
+var glslHighlightRules = require("./glsl_highlight_rules").glslHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = glslHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, CMode);
+
+(function() {
+ this.$id = "ace/mode/glsl";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-gobstones.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-gobstones.js
new file mode 100644
index 00000000..746b3413
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-gobstones.js
@@ -0,0 +1,922 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/gobstones_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var GobstonesHighlightRules = function() {
+
+ var keywords = (
+ "program|procedure|function|interactive|if|then|else|switch|repeat|while|foreach|in|not|div|mod|Skip|return"
+ );
+
+ var buildinConstants = (
+ "False|True"
+ );
+
+
+ var langClasses = (
+ "Poner|Sacar|Mover|IrAlBorde|VaciarTablero|" +
+ "nroBolitas|hayBolitas|puedeMover|siguiente|previo|opuesto|minBool|maxBool|" +
+ "minDir|maxDir|minColor|maxColor"
+ );
+
+ var supportType = (
+ "Verde|Rojo|Azul|Negro|Norte|Sur|Este|Oeste"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": langClasses,
+ "support.type": supportType
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ {
+ token : "comment",
+ regex : "\\-\\-.*$"
+ },
+ {
+ token : "comment",
+ regex : "#.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : /0(?:[xX][0-9a-fA-F][0-9a-fA-F_]*|[bB][01][01_]*)[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.numeric", // float
+ regex : /[+-]?\d[\d_]*(?:(?:\.[\d_]*)?(?:[eE][+-]?[\d_]+)?)?[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:True|False)\\b"
+ }, {
+ token : "keyword.operator",
+ regex : ":=|\\.\\.|,|;|\\|\\||\\/\\/|\\+|\\-|\\^|\\*|>|<|>=|=>|==|&&"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(GobstonesHighlightRules, TextHighlightRules);
+
+exports.GobstonesHighlightRules = GobstonesHighlightRules;
+});
+
+ace.define("ace/mode/gobstones",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/gobstones_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptMode = require("./javascript").Mode;
+var GobstonesHighlightRules = require("./gobstones_highlight_rules").GobstonesHighlightRules;
+
+var Mode = function() {
+ JavaScriptMode.call(this);
+ this.HighlightRules = GobstonesHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, JavaScriptMode);
+
+(function() {
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/gobstones";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-golang.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-golang.js
new file mode 100644
index 00000000..cb81eafa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-golang.js
@@ -0,0 +1,406 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/golang_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+ var oop = require("../lib/oop");
+ var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ var GolangHighlightRules = function() {
+ var keywords = (
+ "else|break|case|return|goto|if|const|select|" +
+ "continue|struct|default|switch|for|range|" +
+ "func|import|package|chan|defer|fallthrough|go|interface|map|range|" +
+ "select|type|var"
+ );
+ var builtinTypes = (
+ "string|uint8|uint16|uint32|uint64|int8|int16|int32|int64|float32|" +
+ "float64|complex64|complex128|byte|rune|uint|int|uintptr|bool|error"
+ );
+ var builtinFunctions = (
+ "new|close|cap|copy|panic|panicln|print|println|len|make|delete|real|recover|imag|append"
+ );
+ var builtinConstants = ("nil|true|false|iota");
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": builtinConstants,
+ "support.function": builtinFunctions,
+ "support.type": builtinTypes
+ }, "");
+
+ var stringEscapeRe = "\\\\(?:[0-7]{3}|x\\h{2}|u{4}|U\\h{6}|[abfnrtv'\"\\\\])".replace(/\\h/g, "[a-fA-F\\d]");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment.start", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : /"(?:[^"\\]|\\.)*?"/
+ }, {
+ token : "string", // raw
+ regex : '`',
+ next : "bqstring"
+ }, {
+ token : "constant.numeric", // rune
+ regex : "'(?:[^\\'\uD800-\uDBFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|" + stringEscapeRe.replace('"', '') + ")'"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : ["keyword", "text", "entity.name.function"],
+ regex : "(func)(\\s+)([a-zA-Z_$][a-zA-Z0-9_$]*)\\b"
+ }, {
+ token : function(val) {
+ if (val[val.length - 1] == "(") {
+ return [{
+ type: keywordMapper(val.slice(0, -1)) || "support.function",
+ value: val.slice(0, -1)
+ }, {
+ type: "paren.lparen",
+ value: val.slice(-1)
+ }];
+ }
+
+ return keywordMapper(val) || "identifier";
+ },
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b\\(?"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|==|=|!=|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^="
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment.end",
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "bqstring" : [
+ {
+ token : "string",
+ regex : '`',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ };
+ oop.inherits(GolangHighlightRules, TextHighlightRules);
+
+ exports.GolangHighlightRules = GolangHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/golang",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/golang_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var GolangHighlightRules = require("./golang_highlight_rules").GolangHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = GolangHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = new CstyleBehaviour();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };//end getNextLineIndent
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/golang";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-graphqlschema.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-graphqlschema.js
new file mode 100644
index 00000000..9d2833dd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-graphqlschema.js
@@ -0,0 +1,206 @@
+ace.define("ace/mode/graphqlschema_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var GraphQLSchemaHighlightRules = function() {
+
+ var keywords = (
+ "type|interface|union|enum|schema|input|implements|extends|scalar"
+ );
+
+ var dataTypes = (
+ "Int|Float|String|ID|Boolean"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "storage.type": dataTypes
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ } ]
+ };
+ this.normalizeRules();
+};
+
+oop.inherits(GraphQLSchemaHighlightRules, TextHighlightRules);
+
+exports.GraphQLSchemaHighlightRules = GraphQLSchemaHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/graphqlschema",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/graphqlschema_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var GraphQLSchemaHighlightRules = require("./graphqlschema_highlight_rules").GraphQLSchemaHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = GraphQLSchemaHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/graphqlschema";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-groovy.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-groovy.js
new file mode 100644
index 00000000..b04ffd9b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-groovy.js
@@ -0,0 +1,980 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/groovy_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var GroovyHighlightRules = function() {
+
+ var keywords = (
+ "assert|with|abstract|continue|for|new|switch|" +
+ "assert|default|goto|package|synchronized|" +
+ "boolean|do|if|private|this|" +
+ "break|double|implements|protected|throw|" +
+ "byte|else|import|public|throws|" +
+ "case|enum|instanceof|return|transient|" +
+ "catch|extends|int|short|try|" +
+ "char|final|interface|static|void|" +
+ "class|finally|long|strictfp|volatile|" +
+ "def|float|native|super|while"
+ );
+
+ var buildinConstants = (
+ "null|Infinity|NaN|undefined"
+ );
+
+ var langClasses = (
+ "AbstractMethodError|AssertionError|ClassCircularityError|"+
+ "ClassFormatError|Deprecated|EnumConstantNotPresentException|"+
+ "ExceptionInInitializerError|IllegalAccessError|"+
+ "IllegalThreadStateException|InstantiationError|InternalError|"+
+ "NegativeArraySizeException|NoSuchFieldError|Override|Process|"+
+ "ProcessBuilder|SecurityManager|StringIndexOutOfBoundsException|"+
+ "SuppressWarnings|TypeNotPresentException|UnknownError|"+
+ "UnsatisfiedLinkError|UnsupportedClassVersionError|VerifyError|"+
+ "InstantiationException|IndexOutOfBoundsException|"+
+ "ArrayIndexOutOfBoundsException|CloneNotSupportedException|"+
+ "NoSuchFieldException|IllegalArgumentException|NumberFormatException|"+
+ "SecurityException|Void|InheritableThreadLocal|IllegalStateException|"+
+ "InterruptedException|NoSuchMethodException|IllegalAccessException|"+
+ "UnsupportedOperationException|Enum|StrictMath|Package|Compiler|"+
+ "Readable|Runtime|StringBuilder|Math|IncompatibleClassChangeError|"+
+ "NoSuchMethodError|ThreadLocal|RuntimePermission|ArithmeticException|"+
+ "NullPointerException|Long|Integer|Short|Byte|Double|Number|Float|"+
+ "Character|Boolean|StackTraceElement|Appendable|StringBuffer|"+
+ "Iterable|ThreadGroup|Runnable|Thread|IllegalMonitorStateException|"+
+ "StackOverflowError|OutOfMemoryError|VirtualMachineError|"+
+ "ArrayStoreException|ClassCastException|LinkageError|"+
+ "NoClassDefFoundError|ClassNotFoundException|RuntimeException|"+
+ "Exception|ThreadDeath|Error|Throwable|System|ClassLoader|"+
+ "Cloneable|Class|CharSequence|Comparable|String|Object"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "support.function": langClasses,
+ "constant.language": buildinConstants
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string",
+ regex : '"""',
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : "'''",
+ next : "qstring"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\?:|\\?\\.|\\*\\.|<=>|=~|==~|\\.@|\\*\\.@|\\.&|as|in|is|!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : /\\(?:u[0-9A-Fa-f]{4}|.|$)/
+ }, {
+ token : "constant.language.escape",
+ regex : /\$[\w\d]+/
+ }, {
+ token : "constant.language.escape",
+ regex : /\$\{[^"\}]+\}?/
+ }, {
+ token : "string",
+ regex : '"{3,5}',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+?'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : /\\(?:u[0-9A-Fa-f]{4}|.|$)/
+ }, {
+ token : "string",
+ regex : "'{3,5}",
+ next : "start"
+ }, {
+ token : "string",
+ regex : ".+?"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(GroovyHighlightRules, TextHighlightRules);
+
+exports.GroovyHighlightRules = GroovyHighlightRules;
+});
+
+ace.define("ace/mode/groovy",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/groovy_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptMode = require("./javascript").Mode;
+var GroovyHighlightRules = require("./groovy_highlight_rules").GroovyHighlightRules;
+
+var Mode = function() {
+ JavaScriptMode.call(this);
+ this.HighlightRules = GroovyHighlightRules;
+};
+oop.inherits(Mode, JavaScriptMode);
+
+(function() {
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/groovy";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-haml.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-haml.js
new file mode 100644
index 00000000..c4255c54
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-haml.js
@@ -0,0 +1,1547 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var constantOtherSymbol = exports.constantOtherSymbol = {
+ token : "constant.other.symbol.ruby", // symbol
+ regex : "[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"
+};
+
+var qString = exports.qString = {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+};
+
+var qqString = exports.qqString = {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+};
+
+var tString = exports.tString = {
+ token : "string", // backtick string
+ regex : "[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"
+};
+
+var constantNumericHex = exports.constantNumericHex = {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"
+};
+
+var constantNumericFloat = exports.constantNumericFloat = {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?\\b"
+};
+
+var instanceVariable = exports.instanceVariable = {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+};
+
+var RubyHighlightRules = function() {
+
+ var builtinFunctions = (
+ "abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|" +
+ "assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|" +
+ "assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|" +
+ "assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|" +
+ "assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|" +
+ "assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|" +
+ "attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|" +
+ "caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|" +
+ "exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|" +
+ "gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|" +
+ "link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|" +
+ "p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|" +
+ "raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|" +
+ "set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|" +
+ "throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|" +
+ "render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|" +
+ "content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|" +
+ "fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|" +
+ "time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|" +
+ "select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|" +
+ "file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|" +
+ "protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|" +
+ "send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|" +
+ "validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|" +
+ "validates_inclusion_of|validates_numericality_of|validates_with|validates_each|" +
+ "authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|" +
+ "filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|" +
+ "translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|" +
+ "cache|expire_fragment|expire_cache_for|observe|cache_sweeper|" +
+ "has_many|has_one|belongs_to|has_and_belongs_to_many"
+ );
+
+ var keywords = (
+ "alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|" +
+ "__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|" +
+ "redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield"
+ );
+
+ var buildinConstants = (
+ "true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|" +
+ "RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING"
+ );
+
+ var builtinVariables = (
+ "$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|" +
+ "$!|root_url|flash|session|cookies|params|request|response|logger|self"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "variable.language": builtinVariables,
+ "support.function": builtinFunctions,
+ "invalid.deprecated": "debugger" // TODO is this a remnant from js mode?
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "comment", // multi line comment
+ regex : "^=begin(?:$|\\s.*$)",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ },
+
+ [{
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ return "paren.lparen";
+ }
+ if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1)
+ return "paren.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.start",
+ regex : /"/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /"/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /'/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\['\\]/
+ }, {
+ token : "string.end",
+ regex : /'/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ {
+ token : "text", // namespaces aren't symbols
+ regex : "::"
+ }, {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+ }, {
+ token : "support.class", // class name
+ regex : "[A-Z][a-zA-Z_\\d]+"
+ },
+
+ constantOtherSymbol,
+ constantNumericHex,
+ constantNumericFloat,
+
+ {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "punctuation.separator.key-value",
+ regex : "=>"
+ }, {
+ stateName: "heredoc",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[3]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"string", value: tokens[2]},
+ {type:"support.class", value: tokens[3]},
+ {type:"string", value: tokens[4]}
+ ];
+ },
+ regex : "(<<-?)(['\"`]?)([\\w]+)(['\"`]?)",
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^ +"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : "string.character",
+ regex : "\\B\\?."
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "^=end(?:$|\\s.*$)",
+ next : "start"
+ }, {
+ token : "comment", // comment spanning whole line
+ regex : ".+"
+ }
+ ]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(RubyHighlightRules, TextHighlightRules);
+
+exports.RubyHighlightRules = RubyHighlightRules;
+});
+
+ace.define("ace/mode/haml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/ruby_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var RubyExports = require("./ruby_highlight_rules");
+var RubyHighlightRules = RubyExports.RubyHighlightRules;
+
+var HamlHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ this.$rules = {
+ "start": [
+ {
+ token: "comment.block", // multiline HTML comment
+ regex: /^\/$/,
+ next: "comment"
+ },
+ {
+ token: "comment.block", // multiline HAML comment
+ regex: /^\-#$/,
+ next: "comment"
+ },
+ {
+ token: "comment.line", // HTML comment
+ regex: /\/\s*.*/
+ },
+ {
+ token: "comment.line", // HAML comment
+ regex: /-#\s*.*/
+ },
+ {
+ token: "keyword.other.doctype",
+ regex: "^!!!\\s*(?:[a-zA-Z0-9-_]+)?"
+ },
+ RubyExports.qString,
+ RubyExports.qqString,
+ RubyExports.tString,
+ {
+ token: "meta.tag.haml",
+ regex: /(%[\w:\-]+)/
+ },
+ {
+ token: "keyword.attribute-name.class.haml",
+ regex: /\.[\w-]+/
+ },
+ {
+ token: "keyword.attribute-name.id.haml",
+ regex: /#[\w-]+/,
+ next: "element_class"
+ },
+ RubyExports.constantNumericHex,
+ RubyExports.constantNumericFloat,
+ RubyExports.constantOtherSymbol,
+ {
+ token: "text",
+ regex: /=|-|~/,
+ next: "embedded_ruby"
+ }
+ ],
+ "element_class": [
+ {
+ token: "keyword.attribute-name.class.haml",
+ regex: /\.[\w-]+/
+ },
+ {
+ token: "punctuation.section",
+ regex: /\{/,
+ next: "element_attributes"
+ },
+ RubyExports.constantOtherSymbol,
+ {
+ token: "empty",
+ regex: "$|(?!\\.|#|\\{|\\[|=|-|~|\\/])",
+ next: "start"
+ }
+ ],
+ "element_attributes": [
+ RubyExports.constantOtherSymbol,
+ RubyExports.qString,
+ RubyExports.qqString,
+ RubyExports.tString,
+ RubyExports.constantNumericHex,
+ RubyExports.constantNumericFloat,
+ {
+ token: "punctuation.section",
+ regex: /$|\}/,
+ next: "start"
+ }
+ ],
+ "embedded_ruby": [
+ RubyExports.constantNumericHex,
+ RubyExports.constantNumericFloat,
+ RubyExports.instanceVariable,
+ RubyExports.qString,
+ RubyExports.qqString,
+ RubyExports.tString,
+ {
+ token : "support.class", // class name
+ regex : "[A-Z][a-zA-Z_\\d]+"
+ },
+ {
+ token : new RubyHighlightRules().getKeywords(),
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ },
+ {
+ token : ["keyword", "text", "text"],
+ regex : "(?:do|\\{)(?: \\|[^|]+\\|)?$",
+ next : "start"
+ },
+ {
+ token : ["text"],
+ regex : "^$",
+ next : "start"
+ },
+ {
+ token : ["text"],
+ regex : "^(?!.*\\|\\s*$)",
+ next : "start"
+ }
+ ],
+ "comment": [
+ {
+ token: "comment.block",
+ regex: /^$/,
+ next: "start"
+ },
+ {
+ token: "comment.block", // comment spanning the whole line
+ regex: /\s+.*/
+ }
+ ]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(HamlHighlightRules, HtmlHighlightRules);
+
+exports.HamlHighlightRules = HamlHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/haml",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/haml_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HamlHighlightRules = require("./haml_highlight_rules").HamlHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HamlHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+
+ this.$id = "ace/mode/haml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-handlebars.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-handlebars.js
new file mode 100644
index 00000000..c970820e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-handlebars.js
@@ -0,0 +1,2593 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/handlebars_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+function pop2(currentState, stack) {
+ stack.splice(0, 3);
+ return stack.shift() || "start";
+}
+var HandlebarsHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+ var hbs = {
+ regex : "(?={{)",
+ push : "handlebars"
+ };
+ for (var key in this.$rules) {
+ this.$rules[key].unshift(hbs);
+ }
+ this.$rules.handlebars = [{
+ token : "comment.start",
+ regex : "{{!--",
+ push : [{
+ token : "comment.end",
+ regex : "--}}",
+ next : pop2
+ }, {
+ defaultToken : "comment"
+ }]
+ }, {
+ token : "comment.start",
+ regex : "{{!",
+ push : [{
+ token : "comment.end",
+ regex : "}}",
+ next : pop2
+ }, {
+ defaultToken : "comment"
+ }]
+ }, {
+ token : "support.function", // unescaped variable
+ regex : "{{{",
+ push : [{
+ token : "support.function",
+ regex : "}}}",
+ next : pop2
+ }, {
+ token : "variable.parameter",
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }]
+ }, {
+ token : "storage.type.start", // begin section
+ regex : "{{[#\\^/&]?",
+ push : [{
+ token : "storage.type.end",
+ regex : "}}",
+ next : pop2
+ }, {
+ token : "variable.parameter",
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }]
+ }];
+
+ this.normalizeRules();
+};
+
+oop.inherits(HandlebarsHighlightRules, HtmlHighlightRules);
+
+exports.HandlebarsHighlightRules = HandlebarsHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/html",["require","exports","module","ace/lib/oop","ace/mode/behaviour/xml"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var XmlBehaviour = require("../behaviour/xml").XmlBehaviour;
+
+var HtmlBehaviour = function () {
+
+ XmlBehaviour.call(this);
+
+};
+
+oop.inherits(HtmlBehaviour, XmlBehaviour);
+
+exports.HtmlBehaviour = HtmlBehaviour;
+});
+
+ace.define("ace/mode/handlebars",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/handlebars_highlight_rules","ace/mode/behaviour/html","ace/mode/folding/html"], function(require, exports, module) {
+ "use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var HandlebarsHighlightRules = require("./handlebars_highlight_rules").HandlebarsHighlightRules;
+var HtmlBehaviour = require("./behaviour/html").HtmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = HandlebarsHighlightRules;
+ this.$behaviour = new HtmlBehaviour();
+};
+
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.blockComment = {start: "{{!--", end: "--}}"};
+ this.$id = "ace/mode/handlebars";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-haskell.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-haskell.js
new file mode 100644
index 00000000..51a54454
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-haskell.js
@@ -0,0 +1,372 @@
+ace.define("ace/mode/haskell_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var HaskellHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token:
+ [ 'punctuation.definition.entity.haskell',
+ 'keyword.operator.function.infix.haskell',
+ 'punctuation.definition.entity.haskell' ],
+ regex: '(`)([a-zA-Z_\']*?)(`)',
+ comment: 'In case this regex seems unusual for an infix operator, note that Haskell allows any ordinary function application (elem 4 [1..10]) to be rewritten as an infix expression (4 `elem` [1..10]).' },
+ { token: 'constant.language.unit.haskell', regex: '\\(\\)' },
+ { token: 'constant.language.empty-list.haskell',
+ regex: '\\[\\]' },
+ { token: 'keyword.other.haskell',
+ regex: '\\bmodule\\b',
+ push:
+ [ { token: 'keyword.other.haskell', regex: '\\bwhere\\b', next: 'pop' },
+ { include: '#module_name' },
+ { include: '#module_exports' },
+ { token: 'invalid', regex: '[a-z]+' },
+ { defaultToken: 'meta.declaration.module.haskell' } ] },
+ { token: 'keyword.other.haskell',
+ regex: '\\bclass\\b',
+ push:
+ [ { token: 'keyword.other.haskell',
+ regex: '\\bwhere\\b',
+ next: 'pop' },
+ { token: 'support.class.prelude.haskell',
+ regex: '\\b(?:Monad|Functor|Eq|Ord|Read|Show|Num|(?:Frac|Ra)tional|Enum|Bounded|Real(?:Frac|Float)?|Integral|Floating)\\b' },
+ { token: 'entity.other.inherited-class.haskell',
+ regex: '[A-Z][A-Za-z_\']*' },
+ { token: 'variable.other.generic-type.haskell',
+ regex: '\\b[a-z][a-zA-Z0-9_\']*\\b' },
+ { defaultToken: 'meta.declaration.class.haskell' } ] },
+ { token: 'keyword.other.haskell',
+ regex: '\\binstance\\b',
+ push:
+ [ { token: 'keyword.other.haskell',
+ regex: '\\bwhere\\b|$',
+ next: 'pop' },
+ { include: '#type_signature' },
+ { defaultToken: 'meta.declaration.instance.haskell' } ] },
+ { token: 'keyword.other.haskell',
+ regex: 'import',
+ push:
+ [ { token: 'meta.import.haskell', regex: '$|;|^', next: 'pop' },
+ { token: 'keyword.other.haskell', regex: 'qualified|as|hiding' },
+ { include: '#module_name' },
+ { include: '#module_exports' },
+ { defaultToken: 'meta.import.haskell' } ] },
+ { token: [ 'keyword.other.haskell', 'meta.deriving.haskell' ],
+ regex: '(deriving)(\\s*\\()',
+ push:
+ [ { token: 'meta.deriving.haskell', regex: '\\)', next: 'pop' },
+ { token: 'entity.other.inherited-class.haskell',
+ regex: '\\b[A-Z][a-zA-Z_\']*' },
+ { defaultToken: 'meta.deriving.haskell' } ] },
+ { token: 'keyword.other.haskell',
+ regex: '\\b(?:deriving|where|data|type|case|of|let|in|newtype|default)\\b' },
+ { token: 'keyword.operator.haskell', regex: '\\binfix[lr]?\\b' },
+ { token: 'keyword.control.haskell',
+ regex: '\\b(?:do|if|then|else)\\b' },
+ { token: 'constant.numeric.float.haskell',
+ regex: '\\b(?:[0-9]+\\.[0-9]+(?:[eE][+-]?[0-9]+)?|[0-9]+[eE][+-]?[0-9]+)\\b',
+ comment: 'Floats are always decimal' },
+ { token: 'constant.numeric.haskell',
+ regex: '\\b(?:[0-9]+|0(?:[xX][0-9a-fA-F]+|[oO][0-7]+))\\b' },
+ { token:
+ [ 'meta.preprocessor.c',
+ 'punctuation.definition.preprocessor.c',
+ 'meta.preprocessor.c' ],
+ regex: '^(\\s*)(#)(\\s*\\w+)',
+ comment: 'In addition to Haskell\'s "native" syntax, GHC permits the C preprocessor to be run on a source file.' },
+ { include: '#pragma' },
+ { token: 'punctuation.definition.string.begin.haskell',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.haskell',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.haskell',
+ regex: '\\\\(?:NUL|SOH|STX|ETX|EOT|ENQ|ACK|BEL|BS|HT|LF|VT|FF|CR|SO|SI|DLE|DC1|DC2|DC3|DC4|NAK|SYN|ETB|CAN|EM|SUB|ESC|FS|GS|RS|US|SP|DEL|[abfnrtv\\\\\\"\'\\&])' },
+ { token: 'constant.character.escape.octal.haskell',
+ regex: '\\\\o[0-7]+|\\\\x[0-9A-Fa-f]+|\\\\[0-9]+' },
+ { token: 'constant.character.escape.control.haskell',
+ regex: '\\^[A-Z@\\[\\]\\\\\\^_]' },
+ { defaultToken: 'string.quoted.double.haskell' } ] },
+ { token:
+ [ 'punctuation.definition.string.begin.haskell',
+ 'string.quoted.single.haskell',
+ 'constant.character.escape.haskell',
+ 'constant.character.escape.octal.haskell',
+ 'constant.character.escape.hexadecimal.haskell',
+ 'constant.character.escape.control.haskell',
+ 'punctuation.definition.string.end.haskell' ],
+ regex: '(\')(?:([\\ -\\[\\]-~])|(\\\\(?:NUL|SOH|STX|ETX|EOT|ENQ|ACK|BEL|BS|HT|LF|VT|FF|CR|SO|SI|DLE|DC1|DC2|DC3|DC4|NAK|SYN|ETB|CAN|EM|SUB|ESC|FS|GS|RS|US|SP|DEL|[abfnrtv\\\\\\"\'\\&]))|(\\\\o[0-7]+)|(\\\\x[0-9A-Fa-f]+)|(\\^[A-Z@\\[\\]\\\\\\^_]))(\')' },
+ { token:
+ [ 'meta.function.type-declaration.haskell',
+ 'entity.name.function.haskell',
+ 'meta.function.type-declaration.haskell',
+ 'keyword.other.double-colon.haskell' ],
+ regex: '^(\\s*)([a-z_][a-zA-Z0-9_\']*|\\([|!%$+\\-.,=</>]+\\))(\\s*)(::)',
+ push:
+ [ { token: 'meta.function.type-declaration.haskell',
+ regex: '$',
+ next: 'pop' },
+ { include: '#type_signature' },
+ { defaultToken: 'meta.function.type-declaration.haskell' } ] },
+ { token: 'support.constant.haskell',
+ regex: '\\b(?:Just|Nothing|Left|Right|True|False|LT|EQ|GT|\\(\\)|\\[\\])\\b' },
+ { token: 'constant.other.haskell', regex: '\\b[A-Z]\\w*\\b' },
+ { include: '#comments' },
+ { token: 'support.function.prelude.haskell',
+ regex: '\\b(?:abs|acos|acosh|all|and|any|appendFile|applyM|asTypeOf|asin|asinh|atan|atan2|atanh|break|catch|ceiling|compare|concat|concatMap|const|cos|cosh|curry|cycle|decodeFloat|div|divMod|drop|dropWhile|elem|encodeFloat|enumFrom|enumFromThen|enumFromThenTo|enumFromTo|error|even|exp|exponent|fail|filter|flip|floatDigits|floatRadix|floatRange|floor|fmap|foldl|foldl1|foldr|foldr1|fromEnum|fromInteger|fromIntegral|fromRational|fst|gcd|getChar|getContents|getLine|head|id|init|interact|ioError|isDenormalized|isIEEE|isInfinite|isNaN|isNegativeZero|iterate|last|lcm|length|lex|lines|log|logBase|lookup|map|mapM|mapM_|max|maxBound|maximum|maybe|min|minBound|minimum|mod|negate|not|notElem|null|odd|or|otherwise|pi|pred|print|product|properFraction|putChar|putStr|putStrLn|quot|quotRem|read|readFile|readIO|readList|readLn|readParen|reads|readsPrec|realToFrac|recip|rem|repeat|replicate|return|reverse|round|scaleFloat|scanl|scanl1|scanr|scanr1|seq|sequence|sequence_|show|showChar|showList|showParen|showString|shows|showsPrec|significand|signum|sin|sinh|snd|span|splitAt|sqrt|subtract|succ|sum|tail|take|takeWhile|tan|tanh|toEnum|toInteger|toRational|truncate|uncurry|undefined|unlines|until|unwords|unzip|unzip3|userError|words|writeFile|zip|zip3|zipWith|zipWith3)\\b' },
+ { include: '#infix_op' },
+ { token: 'keyword.operator.haskell',
+ regex: '[|!%$?~+:\\-.=</>\\\\]+',
+ comment: 'In case this regex seems overly general, note that Haskell permits the definition of new operators which can be nearly any string of punctuation characters, such as $%^&*.' },
+ { token: 'punctuation.separator.comma.haskell', regex: ',' } ],
+ '#block_comment':
+ [ { token: 'punctuation.definition.comment.haskell',
+ regex: '\\{-(?!#)',
+ push:
+ [ { include: '#block_comment' },
+ { token: 'punctuation.definition.comment.haskell',
+ regex: '-\\}',
+ next: 'pop' },
+ { defaultToken: 'comment.block.haskell' } ] } ],
+ '#comments':
+ [ { token: 'punctuation.definition.comment.haskell',
+ regex: '--.*',
+ push_:
+ [ { token: 'comment.line.double-dash.haskell',
+ regex: '$',
+ next: 'pop' },
+ { defaultToken: 'comment.line.double-dash.haskell' } ] },
+ { include: '#block_comment' } ],
+ '#infix_op':
+ [ { token: 'entity.name.function.infix.haskell',
+ regex: '\\([|!%$+:\\-.=</>]+\\)|\\(,+\\)' } ],
+ '#module_exports':
+ [ { token: 'meta.declaration.exports.haskell',
+ regex: '\\(',
+ push:
+ [ { token: 'meta.declaration.exports.haskell.end',
+ regex: '\\)',
+ next: 'pop' },
+ { token: 'entity.name.function.haskell',
+ regex: '\\b[a-z][a-zA-Z_\']*' },
+ { token: 'storage.type.haskell', regex: '\\b[A-Z][A-Za-z_\']*' },
+ { token: 'punctuation.separator.comma.haskell', regex: ',' },
+ { include: '#infix_op' },
+ { token: 'meta.other.unknown.haskell',
+ regex: '\\(.*?\\)',
+ comment: 'So named because I don\'t know what to call this.' },
+ { defaultToken: 'meta.declaration.exports.haskell.end' } ] } ],
+ '#module_name':
+ [ { token: 'support.other.module.haskell',
+ regex: '[A-Z][A-Za-z._\']*' } ],
+ '#pragma':
+ [ { token: 'meta.preprocessor.haskell',
+ regex: '\\{-#',
+ push:
+ [ { token: 'meta.preprocessor.haskell',
+ regex: '#-\\}',
+ next: 'pop' },
+ { token: 'keyword.other.preprocessor.haskell',
+ regex: '\\b(?:LANGUAGE|UNPACK|INLINE)\\b' },
+ { defaultToken: 'meta.preprocessor.haskell' } ] } ],
+ '#type_signature':
+ [ { token:
+ [ 'meta.class-constraint.haskell',
+ 'entity.other.inherited-class.haskell',
+ 'meta.class-constraint.haskell',
+ 'variable.other.generic-type.haskell',
+ 'meta.class-constraint.haskell',
+ 'keyword.other.big-arrow.haskell' ],
+ regex: '(\\(\\s*)([A-Z][A-Za-z]*)(\\s+)([a-z][A-Za-z_\']*)(\\)\\s*)(=>)' },
+ { include: '#pragma' },
+ { token: 'keyword.other.arrow.haskell', regex: '->' },
+ { token: 'keyword.other.big-arrow.haskell', regex: '=>' },
+ { token: 'support.type.prelude.haskell',
+ regex: '\\b(?:Int(?:eger)?|Maybe|Either|Bool|Float|Double|Char|String|Ordering|ShowS|ReadS|FilePath|IO(?:Error)?)\\b' },
+ { token: 'variable.other.generic-type.haskell',
+ regex: '\\b[a-z][a-zA-Z0-9_\']*\\b' },
+ { token: 'storage.type.haskell',
+ regex: '\\b[A-Z][a-zA-Z0-9_\']*\\b' },
+ { token: 'support.constant.unit.haskell', regex: '\\(\\)' },
+ { include: '#comments' } ] }
+
+ this.normalizeRules();
+};
+
+HaskellHighlightRules.metaData = { fileTypes: [ 'hs' ],
+ keyEquivalent: '^~H',
+ name: 'Haskell',
+ scopeName: 'source.haskell' }
+
+
+oop.inherits(HaskellHighlightRules, TextHighlightRules);
+
+exports.HaskellHighlightRules = HaskellHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/haskell",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/haskell_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HaskellHighlightRules = require("./haskell_highlight_rules").HaskellHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HaskellHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = null;
+ this.$id = "ace/mode/haskell";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-haskell_cabal.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-haskell_cabal.js
new file mode 100644
index 00000000..5b69e04c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-haskell_cabal.js
@@ -0,0 +1,134 @@
+ace.define("ace/mode/haskell_cabal_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var CabalHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "^\\s*--.*$"
+ }, {
+ token: ["keyword"],
+ regex: /^(\s*\w.*?)(:(?:\s+|$))/
+ }, {
+ token : "constant.numeric", // float
+ regex : /[\d_]+(?:(?:[\.\d_]*)?)/
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false|TRUE|FALSE|True|False|yes|no)\\b"
+ }, {
+ token : "markup.heading",
+ regex : /^(\w.*)$/
+ }
+ ]};
+
+};
+
+oop.inherits(CabalHighlightRules, TextHighlightRules);
+
+exports.CabalHighlightRules = CabalHighlightRules;
+});
+
+ace.define("ace/mode/folding/haskell_cabal",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+ this.isHeading = function (session,row) {
+ var heading = "markup.heading";
+ var token = session.getTokens(row)[0];
+ return row==0 || (token && token.type.lastIndexOf(heading, 0) === 0);
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ if (this.isHeading(session,row)){
+ return "start";
+ } else if (foldStyle === "markbeginend" && !(/^\s*$/.test(session.getLine(row)))){
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ if (!(/^\s*$/.test(session.getLine(row)))){
+ break;
+ }
+ }
+ if (row==maxRow || this.isHeading(session,row)){
+ return "end";
+ }
+ }
+ return "";
+ };
+
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+ if (this.isHeading(session,row)) {
+ while (++row < maxRow) {
+ if (this.isHeading(session,row)){
+ row--;
+ break;
+ }
+ }
+
+ endRow = row;
+ if (endRow > startRow) {
+ while (endRow > startRow && /^\s*$/.test(session.getLine(endRow)))
+ endRow--;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ } else if (this.getFoldWidget(session, foldStyle, row)==="end"){
+ var endRow = row;
+ var endColumn = session.getLine(endRow).length;
+ while (--row>=0){
+ if (this.isHeading(session,row)){
+ break;
+ }
+ }
+ var line = session.getLine(row);
+ var startColumn = line.length;
+ return new Range(row, startColumn, endRow, endColumn);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/haskell_cabal",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/haskell_cabal_highlight_rules","ace/mode/folding/haskell_cabal"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CabalHighlightRules = require("./haskell_cabal_highlight_rules").CabalHighlightRules;
+var FoldMode = require("./folding/haskell_cabal").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CabalHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = null;
+ this.$id = "ace/mode/haskell_cabal";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-haxe.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-haxe.js
new file mode 100644
index 00000000..694b9b80
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-haxe.js
@@ -0,0 +1,379 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/haxe_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var HaxeHighlightRules = function() {
+
+ var keywords = (
+ "break|case|cast|catch|class|continue|default|else|enum|extends|for|function|if|implements|import|in|inline|interface|new|override|package|private|public|return|static|super|switch|this|throw|trace|try|typedef|untyped|var|while|Array|Void|Bool|Int|UInt|Float|Dynamic|String|List|Hash|IntHash|Error|Unknown|Type|Std"
+ );
+
+ var buildinConstants = (
+ "null|true|false"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": buildinConstants
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({<]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}>]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(HaxeHighlightRules, TextHighlightRules);
+
+exports.HaxeHighlightRules = HaxeHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/haxe",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/haxe_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HaxeHighlightRules = require("./haxe_highlight_rules").HaxeHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HaxeHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/haxe";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-hjson.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-hjson.js
new file mode 100644
index 00000000..85758765
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-hjson.js
@@ -0,0 +1,346 @@
+ace.define("ace/mode/hjson_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var HjsonHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ include: "#comments"
+ }, {
+ include: "#rootObject"
+ }, {
+ include: "#value"
+ }],
+ "#array": [{
+ token: "paren.lparen",
+ regex: /\[/,
+ push: [{
+ token: "paren.rparen",
+ regex: /\]/,
+ next: "pop"
+ }, {
+ include: "#value"
+ }, {
+ include: "#comments"
+ }, {
+ token: "text",
+ regex: /,|$/
+ }, {
+ token: "invalid.illegal",
+ regex: /[^\s\]]/
+ }, {
+ defaultToken: "array"
+ }]
+ }],
+ "#comments": [{
+ token: [
+ "comment.punctuation",
+ "comment.line"
+ ],
+ regex: /(#)(.*$)/
+ }, {
+ token: "comment.punctuation",
+ regex: /\/\*/,
+ push: [{
+ token: "comment.punctuation",
+ regex: /\*\//,
+ next: "pop"
+ }, {
+ defaultToken: "comment.block"
+ }]
+ }, {
+ token: [
+ "comment.punctuation",
+ "comment.line"
+ ],
+ regex: /(\/\/)(.*$)/
+ }],
+ "#constant": [{
+ token: "constant",
+ regex: /\b(?:true|false|null)\b/
+ }],
+ "#keyname": [{
+ token: "keyword",
+ regex: /(?:[^,\{\[\}\]\s]+|"(?:[^"\\]|\\.)*")\s*(?=:)/
+ }],
+ "#mstring": [{
+ token: "string",
+ regex: /'''/,
+ push: [{
+ token: "string",
+ regex: /'''/,
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ "#number": [{
+ token: "constant.numeric",
+ regex: /-?(?:0|[1-9]\d*)(?:(?:\.\d+)?(?:[eE][+-]?\d+)?)?/,
+ comment: "handles integer and decimal numbers"
+ }],
+ "#object": [{
+ token: "paren.lparen",
+ regex: /\{/,
+ push: [{
+ token: "paren.rparen",
+ regex: /\}/,
+ next: "pop"
+ }, {
+ include: "#keyname"
+ }, {
+ include: "#value"
+ }, {
+ token: "text",
+ regex: /:/
+ }, {
+ token: "text",
+ regex: /,/
+ }, {
+ defaultToken: "paren"
+ }]
+ }],
+ "#rootObject": [{
+ token: "paren",
+ regex: /(?=\s*(?:[^,\{\[\}\]\s]+|"(?:[^"\\]|\\.)*")\s*:)/,
+ push: [{
+ token: "paren.rparen",
+ regex: /---none---/,
+ next: "pop"
+ }, {
+ include: "#keyname"
+ }, {
+ include: "#value"
+ }, {
+ token: "text",
+ regex: /:/
+ }, {
+ token: "text",
+ regex: /,/
+ }, {
+ defaultToken: "paren"
+ }]
+ }],
+ "#string": [{
+ token: "string",
+ regex: /"/,
+ push: [{
+ token: "string",
+ regex: /"/,
+ next: "pop"
+ }, {
+ token: "constant.language.escape",
+ regex: /\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/
+ }, {
+ token: "invalid.illegal",
+ regex: /\\./
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ "#ustring": [{
+ token: "string",
+ regex: /\b[^:,0-9\-\{\[\}\]\s].*$/
+ }],
+ "#value": [{
+ include: "#constant"
+ }, {
+ include: "#number"
+ }, {
+ include: "#string"
+ }, {
+ include: "#array"
+ }, {
+ include: "#object"
+ }, {
+ include: "#comments"
+ }, {
+ include: "#mstring"
+ }, {
+ include: "#ustring"
+ }]
+ }
+
+ this.normalizeRules();
+};
+
+HjsonHighlightRules.metaData = {
+ fileTypes: ["hjson"],
+ foldingStartMarker: "(?x: # turn on extended mode\n ^ # a line beginning with\n \\s* # some optional space\n [{\\[] # the start of an object or array\n (?! # but not followed by\n .* # whatever\n [}\\]] # and the close of an object or array\n ,? # an optional comma\n \\s* # some optional space\n $ # at the end of the line\n )\n | # ...or...\n [{\\[] # the start of an object or array\n \\s* # some optional space\n $ # at the end of the line\n )",
+ foldingStopMarker: "(?x: # turn on extended mode\n ^ # a line beginning with\n \\s* # some optional space\n [}\\]] # and the close of an object or array\n )",
+ keyEquivalent: "^~J",
+ name: "Hjson",
+ scopeName: "source.hjson"
+}
+
+
+oop.inherits(HjsonHighlightRules, TextHighlightRules);
+
+exports.HjsonHighlightRules = HjsonHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/hjson",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/hjson_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HjsonHighlightRules = require("./hjson_highlight_rules").HjsonHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HjsonHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = { start: "/*", end: "*/" };
+ this.$id = "ace/mode/hjson"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-html.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-html.js
new file mode 100644
index 00000000..35aa2cc3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-html.js
@@ -0,0 +1,2480 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-html_elixir.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-html_elixir.js
new file mode 100644
index 00000000..207e4899
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-html_elixir.js
@@ -0,0 +1,3059 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/elixir_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ElixirHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token:
+ [ 'meta.module.elixir',
+ 'keyword.control.module.elixir',
+ 'meta.module.elixir',
+ 'entity.name.type.module.elixir' ],
+ regex: '^(\\s*)(defmodule)(\\s+)((?:[A-Z]\\w*\\s*\\.\\s*)*[A-Z]\\w*)' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc (?:~[a-z])?"""',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*"""',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc ~[A-Z]"""',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*"""',
+ next: 'pop' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc (?:~[a-z])?\'\'\'',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*\'\'\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.heredoc',
+ regex: '@(?:module|type)?doc ~[A-Z]\'\'\'',
+ push:
+ [ { token: 'comment.documentation.heredoc',
+ regex: '\\s*\'\'\'',
+ next: 'pop' },
+ { defaultToken: 'comment.documentation.heredoc' } ],
+ comment: '@doc with heredocs is treated as documentation' },
+ { token: 'comment.documentation.false',
+ regex: '@(?:module|type)?doc false',
+ comment: '@doc false is treated as documentation' },
+ { token: 'comment.documentation.string',
+ regex: '@(?:module|type)?doc "',
+ push:
+ [ { token: 'comment.documentation.string',
+ regex: '"',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'comment.documentation.string' } ],
+ comment: '@doc with string is treated as documentation' },
+ { token: 'keyword.control.elixir',
+ regex: '\\b(?:do|end|case|bc|lc|for|if|cond|unless|try|receive|fn|defmodule|defp?|defprotocol|defimpl|defrecord|defstruct|defmacrop?|defdelegate|defcallback|defmacrocallback|defexception|defoverridable|exit|after|rescue|catch|else|raise|throw|import|require|alias|use|quote|unquote|super)\\b(?![?!])',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!\\.)\\b(do|end|case|bc|lc|for|if|cond|unless|try|receive|fn|defmodule|defp?|defprotocol|defimpl|defrecord|defstruct|defmacrop?|defdelegate|defcallback|defmacrocallback|defexception|defoverridable|exit|after|rescue|catch|else|raise|throw|import|require|alias|use|quote|unquote|super)\\b(?![?!])' },
+ { token: 'keyword.operator.elixir',
+ regex: '\\b(?:and|not|or|when|xor|in|inlist|inbits)\\b',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!\\.)\\b(and|not|or|when|xor|in|inlist|inbits)\\b',
+ comment: ' as above, just doesn\'t need a \'end\' and does a logic operation' },
+ { token: 'constant.language.elixir',
+ regex: '\\b(?:nil|true|false)\\b(?![?!])' },
+ { token: 'variable.language.elixir',
+ regex: '\\b__(?:CALLER|ENV|MODULE|DIR)__\\b(?![?!])' },
+ { token:
+ [ 'punctuation.definition.variable.elixir',
+ 'variable.other.readwrite.module.elixir' ],
+ regex: '(@)([a-zA-Z_]\\w*)' },
+ { token:
+ [ 'punctuation.definition.variable.elixir',
+ 'variable.other.anonymous.elixir' ],
+ regex: '(&)(\\d*)' },
+ { token: 'variable.other.constant.elixir',
+ regex: '\\b[A-Z]\\w*\\b' },
+ { token: 'constant.numeric.elixir',
+ regex: '\\b(?:0x[\\da-fA-F](?:_?[\\da-fA-F])*|\\d(?:_?\\d)*(?:\\.(?![^[:space:][:digit:]])(?:_?\\d)*)?(?:[eE][-+]?\\d(?:_?\\d)*)?|0b[01]+|0o[0-7]+)\\b',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '\\b(0x\\h(?>_?\\h)*|\\d(?>_?\\d)*(\\.(?![^[:space:][:digit:]])(?>_?\\d)*)?([eE][-+]?\\d(?>_?\\d)*)?|0b[01]+|0o[0-7]+)\\b' },
+ { token: 'punctuation.definition.constant.elixir',
+ regex: ':\'',
+ push:
+ [ { token: 'punctuation.definition.constant.elixir',
+ regex: '\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'constant.other.symbol.single-quoted.elixir' } ] },
+ { token: 'punctuation.definition.constant.elixir',
+ regex: ':"',
+ push:
+ [ { token: 'punctuation.definition.constant.elixir',
+ regex: '"',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'constant.other.symbol.double-quoted.elixir' } ] },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '(?:\'\'\')',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?>\'\'\')',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*\'\'\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'support.function.variable.quoted.single.heredoc.elixir' } ],
+ comment: 'Single-quoted heredocs' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\'',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'support.function.variable.quoted.single.elixir' } ],
+ comment: 'single quoted string (allows for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '(?:""")',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?>""")',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*"""',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.quoted.double.heredoc.elixir' } ],
+ comment: 'Double-quoted heredocs' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '"',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.quoted.double.elixir' } ],
+ comment: 'double quoted string (allows for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z](?:""")',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '~[a-z](?>""")',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*"""',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.quoted.double.heredoc.elixir' } ],
+ comment: 'Double-quoted heredocs sigils' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\{',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\}[a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\[',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\][a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\<',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\>[a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z]\\(',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\)[a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[a-z][^\\w]',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '[^\\w][a-z]*',
+ next: 'pop' },
+ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.interpolated.elixir' } ],
+ comment: 'sigil (allow for interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z](?:""")',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '~[A-Z](?>""")',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '^\\s*"""',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'Double-quoted heredocs sigils' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\{',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\}[a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\[',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\][a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\<',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\>[a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z]\\(',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '\\)[a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: 'punctuation.definition.string.begin.elixir',
+ regex: '~[A-Z][^\\w]',
+ push:
+ [ { token: 'punctuation.definition.string.end.elixir',
+ regex: '[^\\w][a-z]*',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
+ comment: 'sigil (without interpolation)' },
+ { token: ['punctuation.definition.constant.elixir', 'constant.other.symbol.elixir'],
+ regex: '(:)([a-zA-Z_][\\w@]*(?:[?!]|=(?![>=]))?|\\<\\>|===?|!==?|<<>>|<<<|>>>|~~~|::|<\\-|\\|>|=>|~|~=|=|/|\\\\\\\\|\\*\\*?|\\.\\.?\\.?|>=?|<=?|&&?&?|\\+\\+?|\\-\\-?|\\|\\|?\\|?|\\!|@|\\%?\\{\\}|%|\\[\\]|\\^(?:\\^\\^)?)',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!:)(:)(?>[a-zA-Z_][\\w@]*(?>[?!]|=(?![>=]))?|\\<\\>|===?|!==?|<<>>|<<<|>>>|~~~|::|<\\-|\\|>|=>|~|~=|=|/|\\\\\\\\|\\*\\*?|\\.\\.?\\.?|>=?|<=?|&&?&?|\\+\\+?|\\-\\-?|\\|\\|?\\|?|\\!|@|\\%?\\{\\}|%|\\[\\]|\\^(\\^\\^)?)',
+ comment: 'symbols' },
+ { token: 'punctuation.definition.constant.elixir',
+ regex: '(?:[a-zA-Z_][\\w@]*(?:[?!])?):(?!:)',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?>[a-zA-Z_][\\w@]*(?>[?!])?)(:)(?!:)',
+ comment: 'symbols' },
+ { token:
+ [ 'punctuation.definition.comment.elixir',
+ 'comment.line.number-sign.elixir' ],
+ regex: '(#)(.*)' },
+ { token: 'constant.numeric.elixir',
+ regex: '\\?(?:\\\\(?:x[\\da-fA-F]{1,2}(?![\\da-fA-F])\\b|[^xMC])|[^\\s\\\\])',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<!\\w)\\?(\\\\(x\\h{1,2}(?!\\h)\\b|[^xMC])|[^\\s\\\\])',
+ comment: '\n\t\t\tmatches questionmark-letters.\n\n\t\t\texamples (1st alternation = hex):\n\t\t\t?\\x1 ?\\x61\n\n\t\t\texamples (2rd alternation = escaped):\n\t\t\t?\\n ?\\b\n\n\t\t\texamples (3rd alternation = normal):\n\t\t\t?a ?A ?0 \n\t\t\t?* ?" ?( \n\t\t\t?. ?#\n\t\t\t\n\t\t\tthe negative lookbehind prevents against matching\n\t\t\tp(42.tainted?)\n\t\t\t' },
+ { token: 'keyword.operator.assignment.augmented.elixir',
+ regex: '\\+=|\\-=|\\|\\|=|~=|&&=' },
+ { token: 'keyword.operator.comparison.elixir',
+ regex: '===?|!==?|<=?|>=?' },
+ { token: 'keyword.operator.bitwise.elixir',
+ regex: '\\|{3}|&{3}|\\^{3}|<{3}|>{3}|~{3}' },
+ { token: 'keyword.operator.logical.elixir',
+ regex: '!+|\\bnot\\b|&&|\\band\\b|\\|\\||\\bor\\b|\\bxor\\b',
+ originalRegex: '(?<=[ \\t])!+|\\bnot\\b|&&|\\band\\b|\\|\\||\\bor\\b|\\bxor\\b' },
+ { token: 'keyword.operator.arithmetic.elixir',
+ regex: '\\*|\\+|\\-|/' },
+ { token: 'keyword.operator.other.elixir',
+ regex: '\\||\\+\\+|\\-\\-|\\*\\*|\\\\\\\\|\\<\\-|\\<\\>|\\<\\<|\\>\\>|\\:\\:|\\.\\.|\\|>|~|=>' },
+ { token: 'keyword.operator.assignment.elixir', regex: '=' },
+ { token: 'punctuation.separator.other.elixir', regex: ':' },
+ { token: 'punctuation.separator.statement.elixir',
+ regex: '\\;' },
+ { token: 'punctuation.separator.object.elixir', regex: ',' },
+ { token: 'punctuation.separator.method.elixir', regex: '\\.' },
+ { token: 'punctuation.section.scope.elixir', regex: '\\{|\\}' },
+ { token: 'punctuation.section.array.elixir', regex: '\\[|\\]' },
+ { token: 'punctuation.section.function.elixir',
+ regex: '\\(|\\)' } ],
+ '#escaped_char':
+ [ { token: 'constant.character.escape.elixir',
+ regex: '\\\\(?:x[\\da-fA-F]{1,2}|.)' } ],
+ '#interpolated_elixir':
+ [ { token:
+ [ 'source.elixir.embedded.source',
+ 'source.elixir.embedded.source.empty' ],
+ regex: '(#\\{)(\\})' },
+ { todo:
+ { token: 'punctuation.section.embedded.elixir',
+ regex: '#\\{',
+ push:
+ [ { token: 'punctuation.section.embedded.elixir',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#nest_curly_and_self' },
+ { include: '$self' },
+ { defaultToken: 'source.elixir.embedded.source' } ] } } ],
+ '#nest_curly_and_self':
+ [ { token: 'punctuation.section.scope.elixir',
+ regex: '\\{',
+ push:
+ [ { token: 'punctuation.section.scope.elixir',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#nest_curly_and_self' } ] },
+ { include: '$self' } ],
+ '#regex_sub':
+ [ { include: '#interpolated_elixir' },
+ { include: '#escaped_char' },
+ { token:
+ [ 'punctuation.definition.arbitrary-repitition.elixir',
+ 'string.regexp.arbitrary-repitition.elixir',
+ 'string.regexp.arbitrary-repitition.elixir',
+ 'punctuation.definition.arbitrary-repitition.elixir' ],
+ regex: '(\\{)(\\d+)((?:,\\d+)?)(\\})' },
+ { token: 'punctuation.definition.character-class.elixir',
+ regex: '\\[(?:\\^?\\])?',
+ push:
+ [ { token: 'punctuation.definition.character-class.elixir',
+ regex: '\\]',
+ next: 'pop' },
+ { include: '#escaped_char' },
+ { defaultToken: 'string.regexp.character-class.elixir' } ] },
+ { token: 'punctuation.definition.group.elixir',
+ regex: '\\(',
+ push:
+ [ { token: 'punctuation.definition.group.elixir',
+ regex: '\\)',
+ next: 'pop' },
+ { include: '#regex_sub' },
+ { defaultToken: 'string.regexp.group.elixir' } ] },
+ { token:
+ [ 'punctuation.definition.comment.elixir',
+ 'comment.line.number-sign.elixir' ],
+ regex: '(?:^|\\s)(#)(\\s[[a-zA-Z0-9,. \\t?!-][^\\x00-\\x7F]]*$)',
+ originalRegex: '(?<=^|\\s)(#)\\s[[a-zA-Z0-9,. \\t?!-][^\\x{00}-\\x{7F}]]*$',
+ comment: 'We are restrictive in what we allow to go after the comment character to avoid false positives, since the availability of comments depend on regexp flags.' } ] }
+
+ this.normalizeRules();
+};
+
+ElixirHighlightRules.metaData = { comment: 'Textmate bundle for Elixir Programming Language.',
+ fileTypes: [ 'ex', 'exs' ],
+ firstLineMatch: '^#!/.*\\belixir',
+ foldingStartMarker: '(after|else|catch|rescue|\\-\\>|\\{|\\[|do)\\s*$',
+ foldingStopMarker: '^\\s*((\\}|\\]|after|else|catch|rescue)\\s*$|end\\b)',
+ keyEquivalent: '^~E',
+ name: 'Elixir',
+ scopeName: 'source.elixir' }
+
+
+oop.inherits(ElixirHighlightRules, TextHighlightRules);
+
+exports.ElixirHighlightRules = ElixirHighlightRules;
+});
+
+ace.define("ace/mode/html_elixir_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/elixir_highlight_rules"], function(require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+ var ElixirHighlightRules = require("./elixir_highlight_rules").ElixirHighlightRules;
+
+ var HtmlElixirHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var startRules = [
+ {
+ regex: "<%%|%%>",
+ token: "constant.language.escape"
+ }, {
+ token : "comment.start.eex",
+ regex : "<%#",
+ push : [{
+ token : "comment.end.eex",
+ regex: "%>",
+ next: "pop",
+ defaultToken:"comment"
+ }]
+ }, {
+ token : "support.elixir_tag",
+ regex : "<%+(?!>)[-=]?",
+ push : "elixir-start"
+ }
+ ];
+
+ var endRules = [
+ {
+ token : "support.elixir_tag",
+ regex : "%>",
+ next : "pop"
+ }, {
+ token: "comment",
+ regex: "#(?:[^%]|%[^>])*"
+ }
+ ];
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], startRules);
+
+ this.embedRules(ElixirHighlightRules, "elixir-", endRules, ["start"]);
+
+ this.normalizeRules();
+ };
+
+
+ oop.inherits(HtmlElixirHighlightRules, HtmlHighlightRules);
+
+ exports.HtmlElixirHighlightRules = HtmlElixirHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/elixir",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/elixir_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ElixirHighlightRules = require("./elixir_highlight_rules").ElixirHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ElixirHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/elixir"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/html_elixir",["require","exports","module","ace/lib/oop","ace/mode/html_elixir_highlight_rules","ace/mode/html","ace/mode/javascript","ace/mode/css","ace/mode/elixir"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlElixirHighlightRules = require("./html_elixir_highlight_rules").HtmlElixirHighlightRules;
+var HtmlMode = require("./html").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var ElixirMode = require("./elixir").Mode;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = HtmlElixirHighlightRules;
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode,
+ "elixir-": ElixirMode
+ });
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+
+ this.$id = "ace/mode/html_elixir";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-html_ruby.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-html_ruby.js
new file mode 100644
index 00000000..593e9552
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-html_ruby.js
@@ -0,0 +1,3016 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var constantOtherSymbol = exports.constantOtherSymbol = {
+ token : "constant.other.symbol.ruby", // symbol
+ regex : "[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"
+};
+
+var qString = exports.qString = {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+};
+
+var qqString = exports.qqString = {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+};
+
+var tString = exports.tString = {
+ token : "string", // backtick string
+ regex : "[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"
+};
+
+var constantNumericHex = exports.constantNumericHex = {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"
+};
+
+var constantNumericFloat = exports.constantNumericFloat = {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?\\b"
+};
+
+var instanceVariable = exports.instanceVariable = {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+};
+
+var RubyHighlightRules = function() {
+
+ var builtinFunctions = (
+ "abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|" +
+ "assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|" +
+ "assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|" +
+ "assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|" +
+ "assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|" +
+ "assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|" +
+ "attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|" +
+ "caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|" +
+ "exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|" +
+ "gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|" +
+ "link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|" +
+ "p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|" +
+ "raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|" +
+ "set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|" +
+ "throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|" +
+ "render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|" +
+ "content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|" +
+ "fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|" +
+ "time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|" +
+ "select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|" +
+ "file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|" +
+ "protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|" +
+ "send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|" +
+ "validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|" +
+ "validates_inclusion_of|validates_numericality_of|validates_with|validates_each|" +
+ "authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|" +
+ "filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|" +
+ "translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|" +
+ "cache|expire_fragment|expire_cache_for|observe|cache_sweeper|" +
+ "has_many|has_one|belongs_to|has_and_belongs_to_many"
+ );
+
+ var keywords = (
+ "alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|" +
+ "__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|" +
+ "redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield"
+ );
+
+ var buildinConstants = (
+ "true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|" +
+ "RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING"
+ );
+
+ var builtinVariables = (
+ "$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|" +
+ "$!|root_url|flash|session|cookies|params|request|response|logger|self"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "variable.language": builtinVariables,
+ "support.function": builtinFunctions,
+ "invalid.deprecated": "debugger" // TODO is this a remnant from js mode?
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "comment", // multi line comment
+ regex : "^=begin(?:$|\\s.*$)",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ },
+
+ [{
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ return "paren.lparen";
+ }
+ if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1)
+ return "paren.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.start",
+ regex : /"/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /"/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /'/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\['\\]/
+ }, {
+ token : "string.end",
+ regex : /'/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ {
+ token : "text", // namespaces aren't symbols
+ regex : "::"
+ }, {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+ }, {
+ token : "support.class", // class name
+ regex : "[A-Z][a-zA-Z_\\d]+"
+ },
+
+ constantOtherSymbol,
+ constantNumericHex,
+ constantNumericFloat,
+
+ {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "punctuation.separator.key-value",
+ regex : "=>"
+ }, {
+ stateName: "heredoc",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[3]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"string", value: tokens[2]},
+ {type:"support.class", value: tokens[3]},
+ {type:"string", value: tokens[4]}
+ ];
+ },
+ regex : "(<<-?)(['\"`]?)([\\w]+)(['\"`]?)",
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^ +"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : "string.character",
+ regex : "\\B\\?."
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "^=end(?:$|\\s.*$)",
+ next : "start"
+ }, {
+ token : "comment", // comment spanning whole line
+ regex : ".+"
+ }
+ ]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(RubyHighlightRules, TextHighlightRules);
+
+exports.RubyHighlightRules = RubyHighlightRules;
+});
+
+ace.define("ace/mode/html_ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/ruby_highlight_rules"], function(require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+ var RubyHighlightRules = require("./ruby_highlight_rules").RubyHighlightRules;
+
+ var HtmlRubyHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var startRules = [
+ {
+ regex: "<%%|%%>",
+ token: "constant.language.escape"
+ }, {
+ token : "comment.start.erb",
+ regex : "<%#",
+ push : [{
+ token : "comment.end.erb",
+ regex: "%>",
+ next: "pop",
+ defaultToken:"comment"
+ }]
+ }, {
+ token : "support.ruby_tag",
+ regex : "<%+(?!>)[-=]?",
+ push : "ruby-start"
+ }
+ ];
+
+ var endRules = [
+ {
+ token : "support.ruby_tag",
+ regex : "%>",
+ next : "pop"
+ }, {
+ token: "comment",
+ regex: "#(?:[^%]|%[^>])*"
+ }
+ ];
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], startRules);
+
+ this.embedRules(RubyHighlightRules, "ruby-", endRules, ["start"]);
+
+ this.normalizeRules();
+ };
+
+
+ oop.inherits(HtmlRubyHighlightRules, HtmlHighlightRules);
+
+ exports.HtmlRubyHighlightRules = HtmlRubyHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var RubyHighlightRules = require("./ruby_highlight_rules").RubyHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = RubyHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ var startingClassOrMethod = line.match(/^\s*(class|def|module)\s.*$/);
+ var startingDoBlock = line.match(/.*do(\s*|\s+\|.*\|\s*)$/);
+ var startingConditional = line.match(/^\s*(if|else|when)\s*/)
+ if (match || startingClassOrMethod || startingDoBlock || startingConditional) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return /^\s+(end|else)$/.test(line + input) || this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, session, row) {
+ var line = session.getLine(row);
+ if (/}/.test(line))
+ return this.$outdent.autoOutdent(session, row);
+ var indent = this.$getIndent(line);
+ var prevLine = session.getLine(row - 1);
+ var prevIndent = this.$getIndent(prevLine);
+ var tab = session.getTabString();
+ if (prevIndent.length <= indent.length) {
+ if (indent.slice(-tab.length) == tab)
+ session.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ }
+ };
+
+ this.$id = "ace/mode/ruby";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/html_ruby",["require","exports","module","ace/lib/oop","ace/mode/html_ruby_highlight_rules","ace/mode/html","ace/mode/javascript","ace/mode/css","ace/mode/ruby"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlRubyHighlightRules = require("./html_ruby_highlight_rules").HtmlRubyHighlightRules;
+var HtmlMode = require("./html").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var RubyMode = require("./ruby").Mode;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = HtmlRubyHighlightRules;
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode,
+ "ruby-": RubyMode
+ });
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+
+ this.$id = "ace/mode/html_ruby";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-ini.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-ini.js
new file mode 100644
index 00000000..f53e87f7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-ini.js
@@ -0,0 +1,155 @@
+ace.define("ace/mode/ini_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var escapeRe = "\\\\(?:[\\\\0abtrn;#=:]|x[a-fA-F\\d]{4})";
+
+var IniHighlightRules = function() {
+ this.$rules = {
+ start: [{
+ token: 'punctuation.definition.comment.ini',
+ regex: '#.*',
+ push_: [{
+ token: 'comment.line.number-sign.ini',
+ regex: '$|^',
+ next: 'pop'
+ }, {
+ defaultToken: 'comment.line.number-sign.ini'
+ }]
+ }, {
+ token: 'punctuation.definition.comment.ini',
+ regex: ';.*',
+ push_: [{
+ token: 'comment.line.semicolon.ini',
+ regex: '$|^',
+ next: 'pop'
+ }, {
+ defaultToken: 'comment.line.semicolon.ini'
+ }]
+ }, {
+ token: ['keyword.other.definition.ini', 'text', 'punctuation.separator.key-value.ini'],
+ regex: '\\b([a-zA-Z0-9_.-]+)\\b(\\s*)(=)'
+ }, {
+ token: ['punctuation.definition.entity.ini', 'constant.section.group-title.ini', 'punctuation.definition.entity.ini'],
+ regex: '^(\\[)(.*?)(\\])'
+ }, {
+ token: 'punctuation.definition.string.begin.ini',
+ regex: "'",
+ push: [{
+ token: 'punctuation.definition.string.end.ini',
+ regex: "'",
+ next: 'pop'
+ }, {
+ token: "constant.language.escape",
+ regex: escapeRe
+ }, {
+ defaultToken: 'string.quoted.single.ini'
+ }]
+ }, {
+ token: 'punctuation.definition.string.begin.ini',
+ regex: '"',
+ push: [{
+ token: "constant.language.escape",
+ regex: escapeRe
+ }, {
+ token: 'punctuation.definition.string.end.ini',
+ regex: '"',
+ next: 'pop'
+ }, {
+ defaultToken: 'string.quoted.double.ini'
+ }]
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+IniHighlightRules.metaData = {
+ fileTypes: ['ini', 'conf'],
+ keyEquivalent: '^~I',
+ name: 'Ini',
+ scopeName: 'source.ini'
+};
+
+
+oop.inherits(IniHighlightRules, TextHighlightRules);
+
+exports.IniHighlightRules = IniHighlightRules;
+});
+
+ace.define("ace/mode/folding/ini",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function() {
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /^\s*\[([^\])]*)]\s*(?:$|[;#])/;
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var re = this.foldingStartMarker;
+ var line = session.getLine(row);
+
+ var m = line.match(re);
+
+ if (!m) return;
+
+ var startName = m[1] + ".";
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ if (/^\s*$/.test(line))
+ continue;
+ m = line.match(re);
+ if (m && m[1].lastIndexOf(startName, 0) !== 0)
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/ini",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ini_highlight_rules","ace/mode/folding/ini"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var IniHighlightRules = require("./ini_highlight_rules").IniHighlightRules;
+var FoldMode = require("./folding/ini").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = IniHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = ";";
+ this.blockComment = null;
+ this.$id = "ace/mode/ini";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-io.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-io.js
new file mode 100644
index 00000000..93d53e2c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-io.js
@@ -0,0 +1,246 @@
+ace.define("ace/mode/io_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var IoHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token: [ 'text', 'meta.empty-parenthesis.io' ],
+ regex: '(\\()(\\))',
+ comment: 'we match this to overload return inside () --Allan; scoping rules for what gets the scope have changed, so we now group the ) instead of the ( -- Rob' },
+ { token: [ 'text', 'meta.comma-parenthesis.io' ],
+ regex: '(\\,)(\\))',
+ comment: 'We want to do the same for ,) -- Seckar; same as above -- Rob' },
+ { token: 'keyword.control.io',
+ regex: '\\b(?:if|ifTrue|ifFalse|ifTrueIfFalse|for|loop|reverseForeach|foreach|map|continue|break|while|do|return)\\b' },
+ { token: 'punctuation.definition.comment.io',
+ regex: '/\\*',
+ push:
+ [ { token: 'punctuation.definition.comment.io',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.io' } ] },
+ { token: 'punctuation.definition.comment.io',
+ regex: '//',
+ push:
+ [ { token: 'comment.line.double-slash.io',
+ regex: '$',
+ next: 'pop' },
+ { defaultToken: 'comment.line.double-slash.io' } ] },
+ { token: 'punctuation.definition.comment.io',
+ regex: '#',
+ push:
+ [ { token: 'comment.line.number-sign.io', regex: '$', next: 'pop' },
+ { defaultToken: 'comment.line.number-sign.io' } ] },
+ { token: 'variable.language.io',
+ regex: '\\b(?:self|sender|target|proto|protos|parent)\\b',
+ comment: 'I wonder if some of this isn\'t variable.other.language? --Allan; scoping this as variable.language to match Objective-C\'s handling of \'self\', which is inconsistent with C++\'s handling of \'this\' but perhaps intentionally so -- Rob' },
+ { token: 'keyword.operator.io',
+ regex: '<=|>=|=|:=|\\*|\\||\\|\\||\\+|-|/|&|&&|>|<|\\?|@|@@|\\b(?:and|or)\\b' },
+ { token: 'constant.other.io', regex: '\\bGL[\\w_]+\\b' },
+ { token: 'support.class.io', regex: '\\b[A-Z](?:\\w+)?\\b' },
+ { token: 'support.function.io',
+ regex: '\\b(?:clone|call|init|method|list|vector|block|\\w+(?=\\s*\\())\\b' },
+ { token: 'support.function.open-gl.io',
+ regex: '\\bgl(?:u|ut)?[A-Z]\\w+\\b' },
+ { token: 'punctuation.definition.string.begin.io',
+ regex: '"""',
+ push:
+ [ { token: 'punctuation.definition.string.end.io',
+ regex: '"""',
+ next: 'pop' },
+ { token: 'constant.character.escape.io', regex: '\\\\.' },
+ { defaultToken: 'string.quoted.triple.io' } ] },
+ { token: 'punctuation.definition.string.begin.io',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.io',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.io', regex: '\\\\.' },
+ { defaultToken: 'string.quoted.double.io' } ] },
+ { token: 'constant.numeric.io',
+ regex: '\\b(?:0(?:x|X)[0-9a-fA-F]*|(?:[0-9]+\\.?[0-9]*|\\.[0-9]+)(?:(?:e|E)(?:\\+|-)?[0-9]+)?)(?:L|l|UL|ul|u|U|F|f)?\\b' },
+ { token: 'variable.other.global.io', regex: 'Lobby\\b' },
+ { token: 'constant.language.io',
+ regex: '\\b(?:TRUE|true|FALSE|false|NULL|null|Null|Nil|nil|YES|NO)\\b' } ] }
+
+ this.normalizeRules();
+};
+
+IoHighlightRules.metaData = { fileTypes: [ 'io' ],
+ keyEquivalent: '^~I',
+ name: 'Io',
+ scopeName: 'source.io' }
+
+
+oop.inherits(IoHighlightRules, TextHighlightRules);
+
+exports.IoHighlightRules = IoHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/io",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/io_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var IoHighlightRules = require("./io_highlight_rules").IoHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = IoHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/io";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-jack.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-jack.js
new file mode 100644
index 00000000..ceaf1351
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-jack.js
@@ -0,0 +1,339 @@
+ace.define("ace/mode/jack_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JackHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "string",
+ regex : '"',
+ next : "string2"
+ }, {
+ token : "string",
+ regex : "'",
+ next : "string1"
+ }, {
+ token : "constant.numeric", // hex
+ regex: "-?0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "(?:0|[-+]?[1-9][0-9]*)\\b"
+ }, {
+ token : "constant.binary",
+ regex : "<[0-9A-Fa-f][0-9A-Fa-f](\\s+[0-9A-Fa-f][0-9A-Fa-f])*>"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : "constant.language.null",
+ regex : "null\\b"
+ }, {
+ token : "storage.type",
+ regex: "(?:Integer|Boolean|Null|String|Buffer|Tuple|List|Object|Function|Coroutine|Form)\\b"
+ }, {
+ token : "keyword",
+ regex : "(?:return|abort|vars|for|delete|in|is|escape|exec|split|and|if|elif|else|while)\\b"
+ }, {
+ token : "language.builtin",
+ regex : "(?:lines|source|parse|read-stream|interval|substr|parseint|write|print|range|rand|inspect|bind|i-values|i-pairs|i-map|i-filter|i-chunk|i-all\\?|i-any\\?|i-collect|i-zip|i-merge|i-each)\\b"
+ }, {
+ token : "comment",
+ regex : "--.*$"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "storage.form",
+ regex : "@[a-z]+"
+ }, {
+ token : "constant.other.symbol",
+ regex : ':+[a-zA-Z_]([-]?[a-zA-Z0-9_])*[?!]?'
+ }, {
+ token : "variable",
+ regex : '[a-zA-Z_]([-]?[a-zA-Z0-9_])*[?!]?'
+ }, {
+ token : "keyword.operator",
+ regex : "\\|\\||\\^\\^|&&|!=|==|<=|<|>=|>|\\+|-|\\*|\\/|\\^|\\%|\\#|\\!"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "string1" : [
+ {
+ token : "constant.language.escape",
+ regex : /\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|['"\\\/bfnrt])/
+ }, {
+ token : "string",
+ regex : "[^'\\\\]+"
+ }, {
+ token : "string",
+ regex : "'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : "",
+ next : "start"
+ }
+ ],
+ "string2" : [
+ {
+ token : "constant.language.escape",
+ regex : /\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|['"\\\/bfnrt])/
+ }, {
+ token : "string",
+ regex : '[^"\\\\]+'
+ }, {
+ token : "string",
+ regex : '"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : "",
+ next : "start"
+ }
+ ]
+ };
+
+};
+
+oop.inherits(JackHighlightRules, TextHighlightRules);
+
+exports.JackHighlightRules = JackHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/jack",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/jack_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HighlightRules = require("./jack_highlight_rules").JackHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "--";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+
+ this.$id = "ace/mode/jack";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-jade.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-jade.js
new file mode 100644
index 00000000..bfbe9c88
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-jade.js
@@ -0,0 +1,2129 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/markdown_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules","ace/mode/html_highlight_rules","ace/mode/css_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+
+var escaped = function(ch) {
+ return "(?:[^" + lang.escapeRegExp(ch) + "\\\\]|\\\\.)*";
+}
+
+function github_embed(tag, prefix) {
+ return { // Github style block
+ token : "support.function",
+ regex : "^\\s*```" + tag + "\\s*$",
+ push : prefix + "start"
+ };
+}
+
+var MarkdownHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ this.$rules["start"].unshift({
+ token : "empty_line",
+ regex : '^$',
+ next: "allowBlock"
+ }, { // h1
+ token: "markup.heading.1",
+ regex: "^=+(?=\\s*$)"
+ }, { // h2
+ token: "markup.heading.2",
+ regex: "^\\-+(?=\\s*$)"
+ }, {
+ token : function(value) {
+ return "markup.heading." + value.length;
+ },
+ regex : /^#{1,6}(?=\s*[^ #]|\s+#.)/,
+ next : "header"
+ },
+ github_embed("(?:javascript|js)", "jscode-"),
+ github_embed("xml", "xmlcode-"),
+ github_embed("html", "htmlcode-"),
+ github_embed("css", "csscode-"),
+ { // Github style block
+ token : "support.function",
+ regex : "^\\s*```\\s*\\S*(?:{.*?\\})?\\s*$",
+ next : "githubblock"
+ }, { // block quote
+ token : "string.blockquote",
+ regex : "^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",
+ next : "blockquote"
+ }, { // HR * - _
+ token : "constant",
+ regex : "^ {0,2}(?:(?: ?\\* ?){3,}|(?: ?\\- ?){3,}|(?: ?\\_ ?){3,})\\s*$",
+ next: "allowBlock"
+ }, { // list
+ token : "markup.list",
+ regex : "^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",
+ next : "listblock-start"
+ }, {
+ include : "basic"
+ });
+
+ this.addRules({
+ "basic" : [{
+ token : "constant.language.escape",
+ regex : /\\[\\`*_{}\[\]()#+\-.!]/
+ }, { // code span `
+ token : "support.function",
+ regex : "(`+)(.*?[^`])(\\1)"
+ }, { // reference
+ token : ["text", "constant", "text", "url", "string", "text"],
+ regex : "^([ ]{0,3}\\[)([^\\]]+)(\\]:\\s*)([^ ]+)(\\s*(?:[\"][^\"]+[\"])?(\\s*))$"
+ }, { // link by reference
+ token : ["text", "string", "text", "constant", "text"],
+ regex : "(\\[)(" + escaped("]") + ")(\\]\\s*\\[)("+ escaped("]") + ")(\\])"
+ }, { // link by url
+ token : ["text", "string", "text", "markup.underline", "string", "text"],
+ regex : "(\\[)(" + // [
+ escaped("]") + // link text
+ ")(\\]\\()"+ // ](
+ '((?:[^\\)\\s\\\\]|\\\\.|\\s(?=[^"]))*)' + // href
+ '(\\s*"' + escaped('"') + '"\\s*)?' + // "title"
+ "(\\))" // )
+ }, { // strong ** __
+ token : "string.strong",
+ regex : "([*]{2}|[_]{2}(?=\\S))(.*?\\S[*_]*)(\\1)"
+ }, { // emphasis * _
+ token : "string.emphasis",
+ regex : "([*]|[_](?=\\S))(.*?\\S[*_]*)(\\1)"
+ }, { //
+ token : ["text", "url", "text"],
+ regex : "(<)("+
+ "(?:https?|ftp|dict):[^'\">\\s]+"+
+ "|"+
+ "(?:mailto:)?[-.\\w]+\\@[-a-z0-9]+(?:\\.[-a-z0-9]+)*\\.[a-z]+"+
+ ")(>)"
+ }],
+ "allowBlock": [
+ {token : "support.function", regex : "^ {4}.+", next : "allowBlock"},
+ {token : "empty_line", regex : '^$', next: "allowBlock"},
+ {token : "empty", regex : "", next : "start"}
+ ],
+
+ "header" : [{
+ regex: "$",
+ next : "start"
+ }, {
+ include: "basic"
+ }, {
+ defaultToken : "heading"
+ } ],
+
+ "listblock-start" : [{
+ token : "support.variable",
+ regex : /(?:\[[ x]\])?/,
+ next : "listblock"
+ }],
+
+ "listblock" : [ { // Lists only escape on completely blank lines.
+ token : "empty_line",
+ regex : "^$",
+ next : "start"
+ }, { // list
+ token : "markup.list",
+ regex : "^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",
+ next : "listblock-start"
+ }, {
+ include : "basic", noEscape: true
+ }, { // Github style block
+ token : "support.function",
+ regex : "^\\s*```\\s*[a-zA-Z]*(?:{.*?\\})?\\s*$",
+ next : "githubblock"
+ }, {
+ defaultToken : "list" //do not use markup.list to allow stling leading `*` differntly
+ } ],
+
+ "blockquote" : [ { // Blockquotes only escape on blank lines.
+ token : "empty_line",
+ regex : "^\\s*$",
+ next : "start"
+ }, { // block quote
+ token : "string.blockquote",
+ regex : "^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",
+ next : "blockquote"
+ }, {
+ include : "basic", noEscape: true
+ }, {
+ defaultToken : "string.blockquote"
+ } ],
+
+ "githubblock" : [ {
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "start"
+ }, {
+ defaultToken : "support.function"
+ } ]
+ });
+
+ this.embedRules(JavaScriptHighlightRules, "jscode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(HtmlHighlightRules, "htmlcode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(CssHighlightRules, "csscode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(XmlHighlightRules, "xmlcode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.normalizeRules();
+};
+oop.inherits(MarkdownHighlightRules, TextHighlightRules);
+
+exports.MarkdownHighlightRules = MarkdownHighlightRules;
+});
+
+ace.define("ace/mode/scss_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ScssHighlightRules = function() {
+
+ var properties = lang.arrayToMap( (function () {
+
+ var browserPrefix = ("-webkit-|-moz-|-o-|-ms-|-svg-|-pie-|-khtml-").split("|");
+
+ var prefixProperties = ("appearance|background-clip|background-inline-policy|background-origin|" +
+ "background-size|binding|border-bottom-colors|border-left-colors|" +
+ "border-right-colors|border-top-colors|border-end|border-end-color|" +
+ "border-end-style|border-end-width|border-image|border-start|" +
+ "border-start-color|border-start-style|border-start-width|box-align|" +
+ "box-direction|box-flex|box-flexgroup|box-ordinal-group|box-orient|" +
+ "box-pack|box-sizing|column-count|column-gap|column-width|column-rule|" +
+ "column-rule-width|column-rule-style|column-rule-color|float-edge|" +
+ "font-feature-settings|font-language-override|force-broken-image-icon|" +
+ "image-region|margin-end|margin-start|opacity|outline|outline-color|" +
+ "outline-offset|outline-radius|outline-radius-bottomleft|" +
+ "outline-radius-bottomright|outline-radius-topleft|outline-radius-topright|" +
+ "outline-style|outline-width|padding-end|padding-start|stack-sizing|" +
+ "tab-size|text-blink|text-decoration-color|text-decoration-line|" +
+ "text-decoration-style|transform|transform-origin|transition|" +
+ "transition-delay|transition-duration|transition-property|" +
+ "transition-timing-function|user-focus|user-input|user-modify|user-select|" +
+ "window-shadow|border-radius").split("|");
+
+ var properties = ("azimuth|background-attachment|background-color|background-image|" +
+ "background-position|background-repeat|background|border-bottom-color|" +
+ "border-bottom-style|border-bottom-width|border-bottom|border-collapse|" +
+ "border-color|border-left-color|border-left-style|border-left-width|" +
+ "border-left|border-right-color|border-right-style|border-right-width|" +
+ "border-right|border-spacing|border-style|border-top-color|" +
+ "border-top-style|border-top-width|border-top|border-width|border|bottom|" +
+ "box-shadow|box-sizing|caption-side|clear|clip|color|content|counter-increment|" +
+ "counter-reset|cue-after|cue-before|cue|cursor|direction|display|" +
+ "elevation|empty-cells|float|font-family|font-size-adjust|font-size|" +
+ "font-stretch|font-style|font-variant|font-weight|font|height|left|" +
+ "letter-spacing|line-height|list-style-image|list-style-position|" +
+ "list-style-type|list-style|margin-bottom|margin-left|margin-right|" +
+ "margin-top|marker-offset|margin|marks|max-height|max-width|min-height|" +
+ "min-width|opacity|orphans|outline-color|" +
+ "outline-style|outline-width|outline|overflow|overflow-x|overflow-y|padding-bottom|" +
+ "padding-left|padding-right|padding-top|padding|page-break-after|" +
+ "page-break-before|page-break-inside|page|pause-after|pause-before|" +
+ "pause|pitch-range|pitch|play-during|position|quotes|richness|right|" +
+ "size|speak-header|speak-numeral|speak-punctuation|speech-rate|speak|" +
+ "stress|table-layout|text-align|text-decoration|text-indent|" +
+ "text-shadow|text-transform|top|unicode-bidi|vertical-align|" +
+ "visibility|voice-family|volume|white-space|widows|width|word-spacing|" +
+ "z-index").split("|");
+ var ret = [];
+ for (var i=0, ln=browserPrefix.length; i<ln; i++) {
+ Array.prototype.push.apply(
+ ret,
+ (( browserPrefix[i] + prefixProperties.join("|" + browserPrefix[i]) ).split("|"))
+ );
+ }
+ Array.prototype.push.apply(ret, prefixProperties);
+ Array.prototype.push.apply(ret, properties);
+
+ return ret;
+
+ })() );
+
+
+
+ var functions = lang.arrayToMap(
+ ("hsl|hsla|rgb|rgba|url|attr|counter|counters|abs|adjust_color|adjust_hue|" +
+ "alpha|join|blue|ceil|change_color|comparable|complement|darken|desaturate|" +
+ "floor|grayscale|green|hue|if|invert|join|length|lighten|lightness|mix|" +
+ "nth|opacify|opacity|percentage|quote|red|round|saturate|saturation|" +
+ "scale_color|transparentize|type_of|unit|unitless|unquote").split("|")
+ );
+
+ var constants = lang.arrayToMap(
+ ("absolute|all-scroll|always|armenian|auto|baseline|below|bidi-override|" +
+ "block|bold|bolder|border-box|both|bottom|break-all|break-word|capitalize|center|" +
+ "char|circle|cjk-ideographic|col-resize|collapse|content-box|crosshair|dashed|" +
+ "decimal-leading-zero|decimal|default|disabled|disc|" +
+ "distribute-all-lines|distribute-letter|distribute-space|" +
+ "distribute|dotted|double|e-resize|ellipsis|fixed|georgian|groove|" +
+ "hand|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|" +
+ "ideograph-alpha|ideograph-numeric|ideograph-parenthesis|" +
+ "ideograph-space|inactive|inherit|inline-block|inline|inset|inside|" +
+ "inter-ideograph|inter-word|italic|justify|katakana-iroha|katakana|" +
+ "keep-all|left|lighter|line-edge|line-through|line|list-item|loose|" +
+ "lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|" +
+ "medium|middle|move|n-resize|ne-resize|newspaper|no-drop|no-repeat|" +
+ "nw-resize|none|normal|not-allowed|nowrap|oblique|outset|outside|" +
+ "overline|pointer|progress|relative|repeat-x|repeat-y|repeat|right|" +
+ "ridge|row-resize|rtl|s-resize|scroll|se-resize|separate|small-caps|" +
+ "solid|square|static|strict|super|sw-resize|table-footer-group|" +
+ "table-header-group|tb-rl|text-bottom|text-top|text|thick|thin|top|" +
+ "transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|" +
+ "vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|" +
+ "zero").split("|")
+ );
+
+ var colors = lang.arrayToMap(
+ ("aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|" +
+ "blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|" +
+ "chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|" +
+ "darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|" +
+ "darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|" +
+ "darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|" +
+ "darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|" +
+ "dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|" +
+ "ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|" +
+ "hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|" +
+ "lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|" +
+ "lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|" +
+ "lightsalmon|lightseagreen|lightskyblue|lightslategray|" +
+ "lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|" +
+ "magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|" +
+ "mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|" +
+ "mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|" +
+ "moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|" +
+ "orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|" +
+ "papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|" +
+ "red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|" +
+ "seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|" +
+ "springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|" +
+ "wheat|white|whitesmoke|yellow|yellowgreen").split("|")
+ );
+
+ var keywords = lang.arrayToMap(
+ ("@mixin|@extend|@include|@import|@media|@debug|@warn|@if|@for|@each|@while|@else|@font-face|@-webkit-keyframes|if|and|!default|module|def|end|declare").split("|")
+ )
+
+ var tags = lang.arrayToMap(
+ ("a|abbr|acronym|address|applet|area|article|aside|audio|b|base|basefont|bdo|" +
+ "big|blockquote|body|br|button|canvas|caption|center|cite|code|col|colgroup|" +
+ "command|datalist|dd|del|details|dfn|dir|div|dl|dt|em|embed|fieldset|" +
+ "figcaption|figure|font|footer|form|frame|frameset|h1|h2|h3|h4|h5|h6|head|" +
+ "header|hgroup|hr|html|i|iframe|img|input|ins|keygen|kbd|label|legend|li|" +
+ "link|map|mark|menu|meta|meter|nav|noframes|noscript|object|ol|optgroup|" +
+ "option|output|p|param|pre|progress|q|rp|rt|ruby|s|samp|script|section|select|" +
+ "small|source|span|strike|strong|style|sub|summary|sup|table|tbody|td|" +
+ "textarea|tfoot|th|thead|time|title|tr|tt|u|ul|var|video|wbr|xmp").split("|")
+ );
+
+ var numRe = "\\-?(?:(?:[0-9]+)|(?:[0-9]*\\.[0-9]+))";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : '["].*\\\\$',
+ next : "qqstring"
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "string", // multi line string start
+ regex : "['].*\\\\$",
+ next : "qstring"
+ }, {
+ token : "constant.numeric",
+ regex : numRe + "(?:em|ex|px|cm|mm|in|pt|pc|deg|rad|grad|ms|s|hz|khz|%)"
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : ["support.function", "string", "support.function"],
+ regex : "(url\\()(.*)(\\))"
+ }, {
+ token : function(value) {
+ if (properties.hasOwnProperty(value.toLowerCase()))
+ return "support.type";
+ if (keywords.hasOwnProperty(value))
+ return "keyword";
+ else if (constants.hasOwnProperty(value))
+ return "constant.language";
+ else if (functions.hasOwnProperty(value))
+ return "support.function";
+ else if (colors.hasOwnProperty(value.toLowerCase()))
+ return "support.constant.color";
+ else if (tags.hasOwnProperty(value.toLowerCase()))
+ return "variable.language";
+ else
+ return "text";
+ },
+ regex : "\\-?[@a-z_][@a-z0-9_\\-]*"
+ }, {
+ token : "variable",
+ regex : "[a-z_\\-$][a-z0-9_\\-$]*\\b"
+ }, {
+ token: "variable.language",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ token : "keyword.operator",
+ regex : "<|>|<=|>=|==|!=|-|%|#|\\+|\\$|\\+|\\*"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ caseInsensitive: true
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+};
+
+oop.inherits(ScssHighlightRules, TextHighlightRules);
+
+exports.ScssHighlightRules = ScssHighlightRules;
+
+});
+
+ace.define("ace/mode/less_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/css_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var CssHighlightRules = require('./css_highlight_rules');
+
+var LessHighlightRules = function() {
+
+
+ var keywordList = "@import|@media|@font-face|@keyframes|@-webkit-keyframes|@supports|" +
+ "@charset|@plugin|@namespace|@document|@page|@viewport|@-ms-viewport|" +
+ "or|and|when|not";
+
+ var keywords = keywordList.split('|');
+
+ var properties = CssHighlightRules.supportType.split('|');
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.constant": CssHighlightRules.supportConstant,
+ "keyword": keywordList,
+ "support.constant.color": CssHighlightRules.supportConstantColor,
+ "support.constant.fonts": CssHighlightRules.supportConstantFonts
+ }, "identifier", true);
+
+ var numRe = "\\-?(?:(?:[0-9]+)|(?:[0-9]*\\.[0-9]+))";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : ["support.function", "paren.lparen", "string", "paren.rparen"],
+ regex : "(url)(\\()(.*)(\\))"
+ }, {
+ token : ["support.function", "paren.lparen"],
+ regex : "(:extend|[a-z0-9_\\-]+)(\\()"
+ }, {
+ token : function(value) {
+ if (keywords.indexOf(value.toLowerCase()) > -1)
+ return "keyword";
+ else
+ return "variable";
+ },
+ regex : "[@\\$][a-z0-9_\\-@\\$]*\\b"
+ }, {
+ token : "variable",
+ regex : "[@\\$]\\{[a-z0-9_\\-@\\$]*\\}"
+ }, {
+ token : function(first, second) {
+ if(properties.indexOf(first.toLowerCase()) > -1) {
+ return ["support.type.property", "text"];
+ }
+ else {
+ return ["support.type.unknownProperty", "text"];
+ }
+ },
+ regex : "([a-z0-9-_]+)(\\s*:)"
+ }, {
+ token : "keyword",
+ regex : "&" // special case - always treat as keyword
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[@a-z_][@a-z0-9_\\-]*"
+ }, {
+ token: "variable.language",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: ":[a-z_][a-z0-9-_]*"
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ token : "keyword.operator",
+ regex : "<|>|<=|>=|=|!=|-|%|\\+|\\*"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ caseInsensitive: true
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+ this.normalizeRules();
+};
+
+oop.inherits(LessHighlightRules, TextHighlightRules);
+
+exports.LessHighlightRules = LessHighlightRules;
+
+});
+
+ace.define("ace/mode/coffee_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+ var oop = require("../lib/oop");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ oop.inherits(CoffeeHighlightRules, TextHighlightRules);
+
+ function CoffeeHighlightRules() {
+ var identifier = "[$A-Za-z_\\x7f-\\uffff][$\\w\\x7f-\\uffff]*";
+
+ var keywords = (
+ "this|throw|then|try|typeof|super|switch|return|break|by|continue|" +
+ "catch|class|in|instanceof|is|isnt|if|else|extends|for|own|" +
+ "finally|function|while|when|new|no|not|delete|debugger|do|loop|of|off|" +
+ "or|on|unless|until|and|yes"
+ );
+
+ var langConstant = (
+ "true|false|null|undefined|NaN|Infinity"
+ );
+
+ var illegal = (
+ "case|const|default|function|var|void|with|enum|export|implements|" +
+ "interface|let|package|private|protected|public|static|yield"
+ );
+
+ var supportClass = (
+ "Array|Boolean|Date|Function|Number|Object|RegExp|ReferenceError|String|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" +
+ "SyntaxError|TypeError|URIError|" +
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray"
+ );
+
+ var supportFunction = (
+ "Math|JSON|isNaN|isFinite|parseInt|parseFloat|encodeURI|" +
+ "encodeURIComponent|decodeURI|decodeURIComponent|String|"
+ );
+
+ var variableLanguage = (
+ "window|arguments|prototype|document"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": langConstant,
+ "invalid.illegal": illegal,
+ "language.support.class": supportClass,
+ "language.support.function": supportFunction,
+ "variable.language": variableLanguage
+ }, "identifier");
+
+ var functionRule = {
+ token: ["paren.lparen", "variable.parameter", "paren.rparen", "text", "storage.type"],
+ regex: /(?:(\()((?:"[^")]*?"|'[^')]*?'|\/[^\/)]*?\/|[^()"'\/])*?)(\))(\s*))?([\-=]>)/.source
+ };
+
+ var stringEscape = /\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|[0-2][0-7]{0,2}|3[0-6][0-7]?|37[0-7]?|[4-7][0-7]?|.)/;
+
+ this.$rules = {
+ start : [
+ {
+ token : "constant.numeric",
+ regex : "(?:0x[\\da-fA-F]+|(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?:[eE][+-]?\\d+)?)"
+ }, {
+ stateName: "qdoc",
+ token : "string", regex : "'''", next : [
+ {token : "string", regex : "'''", next : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "qqdoc",
+ token : "string",
+ regex : '"""',
+ next : [
+ {token : "string", regex : '"""', next : "start"},
+ {token : "paren.string", regex : '#{', push : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "qstring",
+ token : "string", regex : "'", next : [
+ {token : "string", regex : "'", next : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "qqstring",
+ token : "string.start", regex : '"', next : [
+ {token : "string.end", regex : '"', next : "start"},
+ {token : "paren.string", regex : '#{', push : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ stateName: "js",
+ token : "string", regex : "`", next : [
+ {token : "string", regex : "`", next : "start"},
+ {token : "constant.language.escape", regex : stringEscape},
+ {defaultToken: "string"}
+ ]
+ }, {
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ return "paren";
+ }
+ if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift() || "";
+ if (this.next.indexOf("string") != -1)
+ return "paren.string";
+ }
+ return "paren";
+ }
+ }, {
+ token : "string.regex",
+ regex : "///",
+ next : "heregex"
+ }, {
+ token : "string.regex",
+ regex : /(?:\/(?![\s=])[^[\/\n\\]*(?:(?:\\[\s\S]|\[[^\]\n\\]*(?:\\[\s\S][^\]\n\\]*)*])[^[\/\n\\]*)*\/)(?:[imgy]{0,4})(?!\w)/
+ }, {
+ token : "comment",
+ regex : "###(?!#)",
+ next : "comment"
+ }, {
+ token : "comment",
+ regex : "#.*"
+ }, {
+ token : ["punctuation.operator", "text", "identifier"],
+ regex : "(\\.)(\\s*)(" + illegal + ")"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\.{1,3}"
+ }, {
+ token : ["keyword", "text", "language.support.class",
+ "text", "keyword", "text", "language.support.class"],
+ regex : "(class)(\\s+)(" + identifier + ")(?:(\\s+)(extends)(\\s+)(" + identifier + "))?"
+ }, {
+ token : ["entity.name.function", "text", "keyword.operator", "text"].concat(functionRule.token),
+ regex : "(" + identifier + ")(\\s*)([=:])(\\s*)" + functionRule.regex
+ },
+ functionRule,
+ {
+ token : "variable",
+ regex : "@(?:" + identifier + ")?"
+ }, {
+ token: keywordMapper,
+ regex : identifier
+ }, {
+ token : "punctuation.operator",
+ regex : "\\,|\\."
+ }, {
+ token : "storage.type",
+ regex : "[\\-=]>"
+ }, {
+ token : "keyword.operator",
+ regex : "(?:[-+*/%<>&|^!?=]=|>>>=?|\\-\\-|\\+\\+|::|&&=|\\|\\|=|<<=|>>=|\\?\\.|\\.{2,3}|[!*+-=><])"
+ }, {
+ token : "paren.lparen",
+ regex : "[({[]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]})]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }],
+
+
+ heregex : [{
+ token : "string.regex",
+ regex : '.*?///[imgy]{0,4}',
+ next : "start"
+ }, {
+ token : "comment.regex",
+ regex : "\\s+(?:#.*)?"
+ }, {
+ token : "string.regex",
+ regex : "\\S+"
+ }],
+
+ comment : [{
+ token : "comment",
+ regex : '###',
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }]
+ };
+ this.normalizeRules();
+ }
+
+ exports.CoffeeHighlightRules = CoffeeHighlightRules;
+});
+
+ace.define("ace/mode/jade_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/markdown_highlight_rules","ace/mode/scss_highlight_rules","ace/mode/less_highlight_rules","ace/mode/coffee_highlight_rules","ace/mode/javascript_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var MarkdownHighlightRules = require("./markdown_highlight_rules").MarkdownHighlightRules;
+var SassHighlightRules = require("./scss_highlight_rules").ScssHighlightRules;
+var LessHighlightRules = require("./less_highlight_rules").LessHighlightRules;
+var CoffeeHighlightRules = require("./coffee_highlight_rules").CoffeeHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+
+function mixin_embed(tag, prefix) {
+ return {
+ token : "entity.name.function.jade",
+ regex : "^\\s*\\:" + tag,
+ next : prefix + "start"
+ };
+}
+
+var JadeHighlightRules = function() {
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-6][0-7]?|" + // oct
+ "37[0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules =
+ {
+ "start": [
+ {
+ token: "keyword.control.import.include.jade",
+ regex: "\\s*\\binclude\\b"
+ },
+ {
+ token: "keyword.other.doctype.jade",
+ regex: "^!!!\\s*(?:[a-zA-Z0-9-_]+)?"
+ },
+ {
+ onMatch: function(value, currentState, stack) {
+ stack.unshift(this.next, value.length - 2, currentState);
+ return "comment";
+ },
+ regex: /^\s*\/\//,
+ next: "comment_block"
+ },
+ mixin_embed("markdown", "markdown-"),
+ mixin_embed("sass", "sass-"),
+ mixin_embed("less", "less-"),
+ mixin_embed("coffee", "coffee-"),
+ {
+ token: [ "storage.type.function.jade",
+ "entity.name.function.jade",
+ "punctuation.definition.parameters.begin.jade",
+ "variable.parameter.function.jade",
+ "punctuation.definition.parameters.end.jade"
+ ],
+ regex: "^(\\s*mixin)( [\\w\\-]+)(\\s*\\()(.*?)(\\))"
+ },
+ {
+ token: [ "storage.type.function.jade", "entity.name.function.jade"],
+ regex: "^(\\s*mixin)( [\\w\\-]+)"
+ },
+ {
+ token: "source.js.embedded.jade",
+ regex: "^\\s*(?:-|=|!=)",
+ next: "js-start"
+ },
+ {
+ token: "string.interpolated.jade",
+ regex: "[#!]\\{[^\\}]+\\}"
+ },
+ {
+ token: "meta.tag.any.jade",
+ regex: /^\s*(?!\w+:)(?:[\w-]+|(?=\.|#)])/,
+ next: "tag_single"
+ },
+ {
+ token: "suport.type.attribute.id.jade",
+ regex: "#\\w+"
+ },
+ {
+ token: "suport.type.attribute.class.jade",
+ regex: "\\.\\w+"
+ },
+ {
+ token: "punctuation",
+ regex: "\\s*(?:\\()",
+ next: "tag_attributes"
+ }
+ ],
+ "comment_block": [
+ {regex: /^\s*(?:\/\/)?/, onMatch: function(value, currentState, stack) {
+ if (value.length <= stack[1]) {
+ if (value.slice(-1) == "/") {
+ stack[1] = value.length - 2;
+ this.next = "";
+ return "comment";
+ }
+ stack.shift();
+ stack.shift();
+ this.next = stack.shift();
+ return "text";
+ } else {
+ this.next = "";
+ return "comment";
+ }
+ }, next: "start"},
+ {defaultToken: "comment"}
+ ],
+ "tag_single": [
+ {
+ token: "entity.other.attribute-name.class.jade",
+ regex: "\\.[\\w-]+"
+ },
+ {
+ token: "entity.other.attribute-name.id.jade",
+ regex: "#[\\w-]+"
+ },
+ {
+ token: ["text", "punctuation"],
+ regex: "($)|((?!\\.|#|=|-))",
+ next: "start"
+ }
+ ],
+ "tag_attributes": [
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ },
+ {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ },
+ {
+ token: ["entity.other.attribute-name.jade", "punctuation"],
+ regex: "([a-zA-Z:\\.-]+)(=)?",
+ next: "attribute_strings"
+ },
+ {
+ token: "punctuation",
+ regex: "\\)",
+ next: "start"
+ }
+ ],
+ "attribute_strings": [
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ },
+ {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ },
+ {
+ token : "string",
+ regex : '(?=\\S)',
+ next : "tag_attributes"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : '[^"\\\\]+'
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "tag_attributes"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "[^'\\\\]+"
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "tag_attributes"
+ }
+ ]
+};
+
+ this.embedRules(JavaScriptHighlightRules, "js-", [{
+ token: "text",
+ regex: ".$",
+ next: "start"
+ }]);
+};
+
+oop.inherits(JadeHighlightRules, TextHighlightRules);
+
+exports.JadeHighlightRules = JadeHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/jade",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/jade_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JadeHighlightRules = require("./jade_highlight_rules").JadeHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JadeHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.$id = "ace/mode/jade";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-java.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-java.js
new file mode 100644
index 00000000..8fac1ebd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-java.js
@@ -0,0 +1,935 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/java_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JavaHighlightRules = function() {
+ var keywords = (
+ "abstract|continue|for|new|switch|" +
+ "assert|default|goto|package|synchronized|" +
+ "boolean|do|if|private|this|" +
+ "break|double|implements|protected|throw|" +
+ "byte|else|import|public|throws|" +
+ "case|enum|instanceof|return|transient|" +
+ "catch|extends|int|short|try|" +
+ "char|final|interface|static|void|" +
+ "class|finally|long|strictfp|volatile|" +
+ "const|float|native|super|while"
+ );
+
+ var buildinConstants = ("null|Infinity|NaN|undefined");
+
+
+ var langClasses = (
+ "AbstractMethodError|AssertionError|ClassCircularityError|"+
+ "ClassFormatError|Deprecated|EnumConstantNotPresentException|"+
+ "ExceptionInInitializerError|IllegalAccessError|"+
+ "IllegalThreadStateException|InstantiationError|InternalError|"+
+ "NegativeArraySizeException|NoSuchFieldError|Override|Process|"+
+ "ProcessBuilder|SecurityManager|StringIndexOutOfBoundsException|"+
+ "SuppressWarnings|TypeNotPresentException|UnknownError|"+
+ "UnsatisfiedLinkError|UnsupportedClassVersionError|VerifyError|"+
+ "InstantiationException|IndexOutOfBoundsException|"+
+ "ArrayIndexOutOfBoundsException|CloneNotSupportedException|"+
+ "NoSuchFieldException|IllegalArgumentException|NumberFormatException|"+
+ "SecurityException|Void|InheritableThreadLocal|IllegalStateException|"+
+ "InterruptedException|NoSuchMethodException|IllegalAccessException|"+
+ "UnsupportedOperationException|Enum|StrictMath|Package|Compiler|"+
+ "Readable|Runtime|StringBuilder|Math|IncompatibleClassChangeError|"+
+ "NoSuchMethodError|ThreadLocal|RuntimePermission|ArithmeticException|"+
+ "NullPointerException|Long|Integer|Short|Byte|Double|Number|Float|"+
+ "Character|Boolean|StackTraceElement|Appendable|StringBuffer|"+
+ "Iterable|ThreadGroup|Runnable|Thread|IllegalMonitorStateException|"+
+ "StackOverflowError|OutOfMemoryError|VirtualMachineError|"+
+ "ArrayStoreException|ClassCastException|LinkageError|"+
+ "NoClassDefFoundError|ClassNotFoundException|RuntimeException|"+
+ "Exception|ThreadDeath|Error|Throwable|System|ClassLoader|"+
+ "Cloneable|Class|CharSequence|Comparable|String|Object"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": langClasses
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : /0(?:[xX][0-9a-fA-F][0-9a-fA-F_]*|[bB][01][01_]*)[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.numeric", // float
+ regex : /[+-]?\d[\d_]*(?:(?:\.[\d_]*)?(?:[eE][+-]?[\d_]+)?)?[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(JavaHighlightRules, TextHighlightRules);
+
+exports.JavaHighlightRules = JavaHighlightRules;
+});
+
+ace.define("ace/mode/java",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/java_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptMode = require("./javascript").Mode;
+var JavaHighlightRules = require("./java_highlight_rules").JavaHighlightRules;
+
+var Mode = function() {
+ JavaScriptMode.call(this);
+ this.HighlightRules = JavaHighlightRules;
+};
+oop.inherits(Mode, JavaScriptMode);
+
+(function() {
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/java";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-javascript.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-javascript.js
new file mode 100644
index 00000000..0e4a81ac
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-javascript.js
@@ -0,0 +1,789 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-json.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-json.js
new file mode 100644
index 00000000..6be2035e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-json.js
@@ -0,0 +1,319 @@
+ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JsonHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "variable", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'
+ }, {
+ token : "string", // single line
+ regex : '"',
+ next : "string"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : "text", // single quoted strings are not allowed
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "comment", // comments are not allowed, but who cares?
+ regex : "\\/\\/.*$"
+ }, {
+ token : "comment.start", // comments are not allowed, but who cares?
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "string" : [
+ {
+ token : "constant.language.escape",
+ regex : /\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment.end", // comments are not allowed, but who cares?
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ]
+ };
+
+};
+
+oop.inherits(JsonHighlightRules, TextHighlightRules);
+
+exports.JsonHighlightRules = JsonHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/json",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/json_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HighlightRules = require("./json_highlight_rules").JsonHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+
+var Mode = function() {
+ this.HighlightRules = HighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/json_worker", "JsonWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+
+ this.$id = "ace/mode/json";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-jsoniq.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-jsoniq.js
new file mode 100644
index 00000000..c533c916
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-jsoniq.js
@@ -0,0 +1,2619 @@
+ace.define("ace/mode/xquery/jsoniq_lexer",["require","exports","module"], function(require, exports, module) {
+module.exports = (function outer (modules, cache, entry) {
+ var previousRequire = typeof require == "function" && require;
+ function newRequire(name, jumped){
+ if(!cache[name]) {
+ if(!modules[name]) {
+ var currentRequire = typeof require == "function" && require;
+ if (!jumped && currentRequire) return currentRequire(name, true);
+ if (previousRequire) return previousRequire(name, true);
+ var err = new Error('Cannot find module \'' + name + '\'');
+ err.code = 'MODULE_NOT_FOUND';
+ throw err;
+ }
+ var m = cache[name] = {exports:{}};
+ modules[name][0].call(m.exports, function(x){
+ var id = modules[name][1][x];
+ return newRequire(id ? id : x);
+ },m,m.exports,outer,modules,cache,entry);
+ }
+ return cache[name].exports;
+ }
+ for(var i=0;i<entry.length;i++) newRequire(entry[i]);
+ return newRequire(entry[0]);
+})
+({"/node_modules/xqlint/lib/lexers/JSONiqTokenizer.js":[function(_dereq_,module,exports){
+ var JSONiqTokenizer = exports.JSONiqTokenizer = function JSONiqTokenizer(string, parsingEventHandler)
+ {
+ init(string, parsingEventHandler);
+ var self = this;
+
+ this.ParseException = function(b, e, s, o, x)
+ {
+ var
+ begin = b,
+ end = e,
+ state = s,
+ offending = o,
+ expected = x;
+
+ this.getBegin = function() {return begin;};
+ this.getEnd = function() {return end;};
+ this.getState = function() {return state;};
+ this.getExpected = function() {return expected;};
+ this.getOffending = function() {return offending;};
+
+ this.getMessage = function()
+ {
+ return offending < 0 ? "lexical analysis failed" : "syntax error";
+ };
+ };
+
+ function init(string, parsingEventHandler)
+ {
+ eventHandler = parsingEventHandler;
+ input = string;
+ size = string.length;
+ reset(0, 0, 0);
+ }
+
+ this.getInput = function()
+ {
+ return input;
+ };
+
+ function reset(l, b, e)
+ {
+ b0 = b; e0 = b;
+ l1 = l; b1 = b; e1 = e;
+ end = e;
+ eventHandler.reset(input);
+ }
+
+ this.getOffendingToken = function(e)
+ {
+ var o = e.getOffending();
+ return o >= 0 ? JSONiqTokenizer.TOKEN[o] : null;
+ };
+
+ this.getExpectedTokenSet = function(e)
+ {
+ var expected;
+ if (e.getExpected() < 0)
+ {
+ expected = JSONiqTokenizer.getTokenSet(- e.getState());
+ }
+ else
+ {
+ expected = [JSONiqTokenizer.TOKEN[e.getExpected()]];
+ }
+ return expected;
+ };
+
+ this.getErrorMessage = function(e)
+ {
+ var tokenSet = this.getExpectedTokenSet(e);
+ var found = this.getOffendingToken(e);
+ var prefix = input.substring(0, e.getBegin());
+ var lines = prefix.split("\n");
+ var line = lines.length;
+ var column = lines[line - 1].length + 1;
+ var size = e.getEnd() - e.getBegin();
+ return e.getMessage()
+ + (found == null ? "" : ", found " + found)
+ + "\nwhile expecting "
+ + (tokenSet.length == 1 ? tokenSet[0] : ("[" + tokenSet.join(", ") + "]"))
+ + "\n"
+ + (size == 0 || found != null ? "" : "after successfully scanning " + size + " characters beginning ")
+ + "at line " + line + ", column " + column + ":\n..."
+ + input.substring(e.getBegin(), Math.min(input.length, e.getBegin() + 64))
+ + "...";
+ };
+
+ this.parse_start = function()
+ {
+ eventHandler.startNonterminal("start", e0);
+ lookahead1W(14); // ModuleDecl | Annotation | OptionDecl | Operator | Variable | Tag | AttrTest |
+ switch (l1)
+ {
+ case 58: // '<![CDATA['
+ shift(58); // '<![CDATA['
+ break;
+ case 57: // '<!--'
+ shift(57); // '<!--'
+ break;
+ case 59: // '<?'
+ shift(59); // '<?'
+ break;
+ case 43: // '(#'
+ shift(43); // '(#'
+ break;
+ case 45: // '(:~'
+ shift(45); // '(:~'
+ break;
+ case 44: // '(:'
+ shift(44); // '(:'
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ case 277: // '}'
+ shift(277); // '}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ case 42: // '('
+ shift(42); // '('
+ break;
+ case 46: // ')'
+ shift(46); // ')'
+ break;
+ case 52: // '/'
+ shift(52); // '/'
+ break;
+ case 65: // '['
+ shift(65); // '['
+ break;
+ case 66: // ']'
+ shift(66); // ']'
+ break;
+ case 49: // ','
+ shift(49); // ','
+ break;
+ case 51: // '.'
+ shift(51); // '.'
+ break;
+ case 56: // ';'
+ shift(56); // ';'
+ break;
+ case 54: // ':'
+ shift(54); // ':'
+ break;
+ case 36: // '!'
+ shift(36); // '!'
+ break;
+ case 276: // '|'
+ shift(276); // '|'
+ break;
+ case 40: // '$$'
+ shift(40); // '$$'
+ break;
+ case 5: // Annotation
+ shift(5); // Annotation
+ break;
+ case 4: // ModuleDecl
+ shift(4); // ModuleDecl
+ break;
+ case 6: // OptionDecl
+ shift(6); // OptionDecl
+ break;
+ case 15: // AttrTest
+ shift(15); // AttrTest
+ break;
+ case 16: // Wildcard
+ shift(16); // Wildcard
+ break;
+ case 18: // IntegerLiteral
+ shift(18); // IntegerLiteral
+ break;
+ case 19: // DecimalLiteral
+ shift(19); // DecimalLiteral
+ break;
+ case 20: // DoubleLiteral
+ shift(20); // DoubleLiteral
+ break;
+ case 8: // Variable
+ shift(8); // Variable
+ break;
+ case 9: // Tag
+ shift(9); // Tag
+ break;
+ case 7: // Operator
+ shift(7); // Operator
+ break;
+ case 35: // EOF
+ shift(35); // EOF
+ break;
+ default:
+ parse_EQName();
+ }
+ eventHandler.endNonterminal("start", e0);
+ };
+
+ this.parse_StartTag = function()
+ {
+ eventHandler.startNonterminal("StartTag", e0);
+ lookahead1W(8); // QName | S^WS | EOF | '"' | "'" | '/>' | '=' | '>'
+ switch (l1)
+ {
+ case 61: // '>'
+ shift(61); // '>'
+ break;
+ case 53: // '/>'
+ shift(53); // '/>'
+ break;
+ case 29: // QName
+ shift(29); // QName
+ break;
+ case 60: // '='
+ shift(60); // '='
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("StartTag", e0);
+ };
+
+ this.parse_TagContent = function()
+ {
+ eventHandler.startNonterminal("TagContent", e0);
+ lookahead1(11); // Tag | EndTag | PredefinedEntityRef | ElementContentChar | CharRef | EOF |
+ switch (l1)
+ {
+ case 25: // ElementContentChar
+ shift(25); // ElementContentChar
+ break;
+ case 9: // Tag
+ shift(9); // Tag
+ break;
+ case 10: // EndTag
+ shift(10); // EndTag
+ break;
+ case 58: // '<![CDATA['
+ shift(58); // '<![CDATA['
+ break;
+ case 57: // '<!--'
+ shift(57); // '<!--'
+ break;
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 275: // '{{'
+ shift(275); // '{{'
+ break;
+ case 278: // '}}'
+ shift(278); // '}}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("TagContent", e0);
+ };
+
+ this.parse_AposAttr = function()
+ {
+ eventHandler.startNonterminal("AposAttr", e0);
+ lookahead1(10); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | EOF | "'" |
+ switch (l1)
+ {
+ case 23: // EscapeApos
+ shift(23); // EscapeApos
+ break;
+ case 27: // AposAttrContentChar
+ shift(27); // AposAttrContentChar
+ break;
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 275: // '{{'
+ shift(275); // '{{'
+ break;
+ case 278: // '}}'
+ shift(278); // '}}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("AposAttr", e0);
+ };
+
+ this.parse_QuotAttr = function()
+ {
+ eventHandler.startNonterminal("QuotAttr", e0);
+ lookahead1(9); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | EOF | '"' |
+ switch (l1)
+ {
+ case 22: // EscapeQuot
+ shift(22); // EscapeQuot
+ break;
+ case 26: // QuotAttrContentChar
+ shift(26); // QuotAttrContentChar
+ break;
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 275: // '{{'
+ shift(275); // '{{'
+ break;
+ case 278: // '}}'
+ shift(278); // '}}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("QuotAttr", e0);
+ };
+
+ this.parse_CData = function()
+ {
+ eventHandler.startNonterminal("CData", e0);
+ lookahead1(1); // CDataSectionContents | EOF | ']]>'
+ switch (l1)
+ {
+ case 14: // CDataSectionContents
+ shift(14); // CDataSectionContents
+ break;
+ case 67: // ']]>'
+ shift(67); // ']]>'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("CData", e0);
+ };
+
+ this.parse_XMLComment = function()
+ {
+ eventHandler.startNonterminal("XMLComment", e0);
+ lookahead1(0); // DirCommentContents | EOF | '-->'
+ switch (l1)
+ {
+ case 12: // DirCommentContents
+ shift(12); // DirCommentContents
+ break;
+ case 50: // '-->'
+ shift(50); // '-->'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("XMLComment", e0);
+ };
+
+ this.parse_PI = function()
+ {
+ eventHandler.startNonterminal("PI", e0);
+ lookahead1(3); // DirPIContents | EOF | '?' | '?>'
+ switch (l1)
+ {
+ case 13: // DirPIContents
+ shift(13); // DirPIContents
+ break;
+ case 62: // '?'
+ shift(62); // '?'
+ break;
+ case 63: // '?>'
+ shift(63); // '?>'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("PI", e0);
+ };
+
+ this.parse_Pragma = function()
+ {
+ eventHandler.startNonterminal("Pragma", e0);
+ lookahead1(2); // PragmaContents | EOF | '#' | '#)'
+ switch (l1)
+ {
+ case 11: // PragmaContents
+ shift(11); // PragmaContents
+ break;
+ case 38: // '#'
+ shift(38); // '#'
+ break;
+ case 39: // '#)'
+ shift(39); // '#)'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("Pragma", e0);
+ };
+
+ this.parse_Comment = function()
+ {
+ eventHandler.startNonterminal("Comment", e0);
+ lookahead1(4); // CommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 55: // ':)'
+ shift(55); // ':)'
+ break;
+ case 44: // '(:'
+ shift(44); // '(:'
+ break;
+ case 32: // CommentContents
+ shift(32); // CommentContents
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("Comment", e0);
+ };
+
+ this.parse_CommentDoc = function()
+ {
+ eventHandler.startNonterminal("CommentDoc", e0);
+ lookahead1(6); // DocTag | DocCommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 33: // DocTag
+ shift(33); // DocTag
+ break;
+ case 34: // DocCommentContents
+ shift(34); // DocCommentContents
+ break;
+ case 55: // ':)'
+ shift(55); // ':)'
+ break;
+ case 44: // '(:'
+ shift(44); // '(:'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("CommentDoc", e0);
+ };
+
+ this.parse_QuotString = function()
+ {
+ eventHandler.startNonterminal("QuotString", e0);
+ lookahead1(5); // JSONChar | JSONCharRef | JSONPredefinedCharRef | EOF | '"'
+ switch (l1)
+ {
+ case 3: // JSONPredefinedCharRef
+ shift(3); // JSONPredefinedCharRef
+ break;
+ case 2: // JSONCharRef
+ shift(2); // JSONCharRef
+ break;
+ case 1: // JSONChar
+ shift(1); // JSONChar
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("QuotString", e0);
+ };
+
+ this.parse_AposString = function()
+ {
+ eventHandler.startNonterminal("AposString", e0);
+ lookahead1(7); // PredefinedEntityRef | EscapeApos | AposChar | CharRef | EOF | "'"
+ switch (l1)
+ {
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 23: // EscapeApos
+ shift(23); // EscapeApos
+ break;
+ case 24: // AposChar
+ shift(24); // AposChar
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("AposString", e0);
+ };
+
+ this.parse_Prefix = function()
+ {
+ eventHandler.startNonterminal("Prefix", e0);
+ lookahead1W(13); // NCName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_NCName();
+ eventHandler.endNonterminal("Prefix", e0);
+ };
+
+ this.parse__EQName = function()
+ {
+ eventHandler.startNonterminal("_EQName", e0);
+ lookahead1W(12); // EQName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_EQName();
+ eventHandler.endNonterminal("_EQName", e0);
+ };
+
+ function parse_EQName()
+ {
+ eventHandler.startNonterminal("EQName", e0);
+ switch (l1)
+ {
+ case 80: // 'attribute'
+ shift(80); // 'attribute'
+ break;
+ case 94: // 'comment'
+ shift(94); // 'comment'
+ break;
+ case 118: // 'document-node'
+ shift(118); // 'document-node'
+ break;
+ case 119: // 'element'
+ shift(119); // 'element'
+ break;
+ case 122: // 'empty-sequence'
+ shift(122); // 'empty-sequence'
+ break;
+ case 143: // 'function'
+ shift(143); // 'function'
+ break;
+ case 150: // 'if'
+ shift(150); // 'if'
+ break;
+ case 163: // 'item'
+ shift(163); // 'item'
+ break;
+ case 183: // 'namespace-node'
+ shift(183); // 'namespace-node'
+ break;
+ case 189: // 'node'
+ shift(189); // 'node'
+ break;
+ case 214: // 'processing-instruction'
+ shift(214); // 'processing-instruction'
+ break;
+ case 224: // 'schema-attribute'
+ shift(224); // 'schema-attribute'
+ break;
+ case 225: // 'schema-element'
+ shift(225); // 'schema-element'
+ break;
+ case 241: // 'switch'
+ shift(241); // 'switch'
+ break;
+ case 242: // 'text'
+ shift(242); // 'text'
+ break;
+ case 251: // 'typeswitch'
+ shift(251); // 'typeswitch'
+ break;
+ default:
+ parse_FunctionName();
+ }
+ eventHandler.endNonterminal("EQName", e0);
+ }
+
+ function parse_FunctionName()
+ {
+ eventHandler.startNonterminal("FunctionName", e0);
+ switch (l1)
+ {
+ case 17: // EQName^Token
+ shift(17); // EQName^Token
+ break;
+ case 68: // 'after'
+ shift(68); // 'after'
+ break;
+ case 71: // 'ancestor'
+ shift(71); // 'ancestor'
+ break;
+ case 72: // 'ancestor-or-self'
+ shift(72); // 'ancestor-or-self'
+ break;
+ case 73: // 'and'
+ shift(73); // 'and'
+ break;
+ case 77: // 'as'
+ shift(77); // 'as'
+ break;
+ case 78: // 'ascending'
+ shift(78); // 'ascending'
+ break;
+ case 82: // 'before'
+ shift(82); // 'before'
+ break;
+ case 86: // 'case'
+ shift(86); // 'case'
+ break;
+ case 87: // 'cast'
+ shift(87); // 'cast'
+ break;
+ case 88: // 'castable'
+ shift(88); // 'castable'
+ break;
+ case 91: // 'child'
+ shift(91); // 'child'
+ break;
+ case 92: // 'collation'
+ shift(92); // 'collation'
+ break;
+ case 101: // 'copy'
+ shift(101); // 'copy'
+ break;
+ case 103: // 'count'
+ shift(103); // 'count'
+ break;
+ case 106: // 'declare'
+ shift(106); // 'declare'
+ break;
+ case 107: // 'default'
+ shift(107); // 'default'
+ break;
+ case 108: // 'delete'
+ shift(108); // 'delete'
+ break;
+ case 109: // 'descendant'
+ shift(109); // 'descendant'
+ break;
+ case 110: // 'descendant-or-self'
+ shift(110); // 'descendant-or-self'
+ break;
+ case 111: // 'descending'
+ shift(111); // 'descending'
+ break;
+ case 116: // 'div'
+ shift(116); // 'div'
+ break;
+ case 117: // 'document'
+ shift(117); // 'document'
+ break;
+ case 120: // 'else'
+ shift(120); // 'else'
+ break;
+ case 121: // 'empty'
+ shift(121); // 'empty'
+ break;
+ case 124: // 'end'
+ shift(124); // 'end'
+ break;
+ case 126: // 'eq'
+ shift(126); // 'eq'
+ break;
+ case 127: // 'every'
+ shift(127); // 'every'
+ break;
+ case 129: // 'except'
+ shift(129); // 'except'
+ break;
+ case 132: // 'first'
+ shift(132); // 'first'
+ break;
+ case 133: // 'following'
+ shift(133); // 'following'
+ break;
+ case 134: // 'following-sibling'
+ shift(134); // 'following-sibling'
+ break;
+ case 135: // 'for'
+ shift(135); // 'for'
+ break;
+ case 144: // 'ge'
+ shift(144); // 'ge'
+ break;
+ case 146: // 'group'
+ shift(146); // 'group'
+ break;
+ case 148: // 'gt'
+ shift(148); // 'gt'
+ break;
+ case 149: // 'idiv'
+ shift(149); // 'idiv'
+ break;
+ case 151: // 'import'
+ shift(151); // 'import'
+ break;
+ case 157: // 'insert'
+ shift(157); // 'insert'
+ break;
+ case 158: // 'instance'
+ shift(158); // 'instance'
+ break;
+ case 160: // 'intersect'
+ shift(160); // 'intersect'
+ break;
+ case 161: // 'into'
+ shift(161); // 'into'
+ break;
+ case 162: // 'is'
+ shift(162); // 'is'
+ break;
+ case 168: // 'last'
+ shift(168); // 'last'
+ break;
+ case 170: // 'le'
+ shift(170); // 'le'
+ break;
+ case 172: // 'let'
+ shift(172); // 'let'
+ break;
+ case 176: // 'lt'
+ shift(176); // 'lt'
+ break;
+ case 178: // 'mod'
+ shift(178); // 'mod'
+ break;
+ case 179: // 'modify'
+ shift(179); // 'modify'
+ break;
+ case 180: // 'module'
+ shift(180); // 'module'
+ break;
+ case 182: // 'namespace'
+ shift(182); // 'namespace'
+ break;
+ case 184: // 'ne'
+ shift(184); // 'ne'
+ break;
+ case 196: // 'only'
+ shift(196); // 'only'
+ break;
+ case 198: // 'or'
+ shift(198); // 'or'
+ break;
+ case 199: // 'order'
+ shift(199); // 'order'
+ break;
+ case 200: // 'ordered'
+ shift(200); // 'ordered'
+ break;
+ case 204: // 'parent'
+ shift(204); // 'parent'
+ break;
+ case 210: // 'preceding'
+ shift(210); // 'preceding'
+ break;
+ case 211: // 'preceding-sibling'
+ shift(211); // 'preceding-sibling'
+ break;
+ case 216: // 'rename'
+ shift(216); // 'rename'
+ break;
+ case 217: // 'replace'
+ shift(217); // 'replace'
+ break;
+ case 218: // 'return'
+ shift(218); // 'return'
+ break;
+ case 222: // 'satisfies'
+ shift(222); // 'satisfies'
+ break;
+ case 227: // 'self'
+ shift(227); // 'self'
+ break;
+ case 233: // 'some'
+ shift(233); // 'some'
+ break;
+ case 234: // 'stable'
+ shift(234); // 'stable'
+ break;
+ case 235: // 'start'
+ shift(235); // 'start'
+ break;
+ case 246: // 'to'
+ shift(246); // 'to'
+ break;
+ case 247: // 'treat'
+ shift(247); // 'treat'
+ break;
+ case 248: // 'try'
+ shift(248); // 'try'
+ break;
+ case 252: // 'union'
+ shift(252); // 'union'
+ break;
+ case 254: // 'unordered'
+ shift(254); // 'unordered'
+ break;
+ case 258: // 'validate'
+ shift(258); // 'validate'
+ break;
+ case 264: // 'where'
+ shift(264); // 'where'
+ break;
+ case 268: // 'with'
+ shift(268); // 'with'
+ break;
+ case 272: // 'xquery'
+ shift(272); // 'xquery'
+ break;
+ case 70: // 'allowing'
+ shift(70); // 'allowing'
+ break;
+ case 79: // 'at'
+ shift(79); // 'at'
+ break;
+ case 81: // 'base-uri'
+ shift(81); // 'base-uri'
+ break;
+ case 83: // 'boundary-space'
+ shift(83); // 'boundary-space'
+ break;
+ case 84: // 'break'
+ shift(84); // 'break'
+ break;
+ case 89: // 'catch'
+ shift(89); // 'catch'
+ break;
+ case 96: // 'construction'
+ shift(96); // 'construction'
+ break;
+ case 99: // 'context'
+ shift(99); // 'context'
+ break;
+ case 100: // 'continue'
+ shift(100); // 'continue'
+ break;
+ case 102: // 'copy-namespaces'
+ shift(102); // 'copy-namespaces'
+ break;
+ case 104: // 'decimal-format'
+ shift(104); // 'decimal-format'
+ break;
+ case 123: // 'encoding'
+ shift(123); // 'encoding'
+ break;
+ case 130: // 'exit'
+ shift(130); // 'exit'
+ break;
+ case 131: // 'external'
+ shift(131); // 'external'
+ break;
+ case 139: // 'ft-option'
+ shift(139); // 'ft-option'
+ break;
+ case 152: // 'in'
+ shift(152); // 'in'
+ break;
+ case 153: // 'index'
+ shift(153); // 'index'
+ break;
+ case 159: // 'integrity'
+ shift(159); // 'integrity'
+ break;
+ case 169: // 'lax'
+ shift(169); // 'lax'
+ break;
+ case 190: // 'nodes'
+ shift(190); // 'nodes'
+ break;
+ case 197: // 'option'
+ shift(197); // 'option'
+ break;
+ case 201: // 'ordering'
+ shift(201); // 'ordering'
+ break;
+ case 220: // 'revalidation'
+ shift(220); // 'revalidation'
+ break;
+ case 223: // 'schema'
+ shift(223); // 'schema'
+ break;
+ case 226: // 'score'
+ shift(226); // 'score'
+ break;
+ case 232: // 'sliding'
+ shift(232); // 'sliding'
+ break;
+ case 238: // 'strict'
+ shift(238); // 'strict'
+ break;
+ case 249: // 'tumbling'
+ shift(249); // 'tumbling'
+ break;
+ case 250: // 'type'
+ shift(250); // 'type'
+ break;
+ case 255: // 'updating'
+ shift(255); // 'updating'
+ break;
+ case 259: // 'value'
+ shift(259); // 'value'
+ break;
+ case 260: // 'variable'
+ shift(260); // 'variable'
+ break;
+ case 261: // 'version'
+ shift(261); // 'version'
+ break;
+ case 265: // 'while'
+ shift(265); // 'while'
+ break;
+ case 95: // 'constraint'
+ shift(95); // 'constraint'
+ break;
+ case 174: // 'loop'
+ shift(174); // 'loop'
+ break;
+ default:
+ shift(219); // 'returning'
+ }
+ eventHandler.endNonterminal("FunctionName", e0);
+ }
+
+ function parse_NCName()
+ {
+ eventHandler.startNonterminal("NCName", e0);
+ switch (l1)
+ {
+ case 28: // NCName^Token
+ shift(28); // NCName^Token
+ break;
+ case 68: // 'after'
+ shift(68); // 'after'
+ break;
+ case 73: // 'and'
+ shift(73); // 'and'
+ break;
+ case 77: // 'as'
+ shift(77); // 'as'
+ break;
+ case 78: // 'ascending'
+ shift(78); // 'ascending'
+ break;
+ case 82: // 'before'
+ shift(82); // 'before'
+ break;
+ case 86: // 'case'
+ shift(86); // 'case'
+ break;
+ case 87: // 'cast'
+ shift(87); // 'cast'
+ break;
+ case 88: // 'castable'
+ shift(88); // 'castable'
+ break;
+ case 92: // 'collation'
+ shift(92); // 'collation'
+ break;
+ case 103: // 'count'
+ shift(103); // 'count'
+ break;
+ case 107: // 'default'
+ shift(107); // 'default'
+ break;
+ case 111: // 'descending'
+ shift(111); // 'descending'
+ break;
+ case 116: // 'div'
+ shift(116); // 'div'
+ break;
+ case 120: // 'else'
+ shift(120); // 'else'
+ break;
+ case 121: // 'empty'
+ shift(121); // 'empty'
+ break;
+ case 124: // 'end'
+ shift(124); // 'end'
+ break;
+ case 126: // 'eq'
+ shift(126); // 'eq'
+ break;
+ case 129: // 'except'
+ shift(129); // 'except'
+ break;
+ case 135: // 'for'
+ shift(135); // 'for'
+ break;
+ case 144: // 'ge'
+ shift(144); // 'ge'
+ break;
+ case 146: // 'group'
+ shift(146); // 'group'
+ break;
+ case 148: // 'gt'
+ shift(148); // 'gt'
+ break;
+ case 149: // 'idiv'
+ shift(149); // 'idiv'
+ break;
+ case 158: // 'instance'
+ shift(158); // 'instance'
+ break;
+ case 160: // 'intersect'
+ shift(160); // 'intersect'
+ break;
+ case 161: // 'into'
+ shift(161); // 'into'
+ break;
+ case 162: // 'is'
+ shift(162); // 'is'
+ break;
+ case 170: // 'le'
+ shift(170); // 'le'
+ break;
+ case 172: // 'let'
+ shift(172); // 'let'
+ break;
+ case 176: // 'lt'
+ shift(176); // 'lt'
+ break;
+ case 178: // 'mod'
+ shift(178); // 'mod'
+ break;
+ case 179: // 'modify'
+ shift(179); // 'modify'
+ break;
+ case 184: // 'ne'
+ shift(184); // 'ne'
+ break;
+ case 196: // 'only'
+ shift(196); // 'only'
+ break;
+ case 198: // 'or'
+ shift(198); // 'or'
+ break;
+ case 199: // 'order'
+ shift(199); // 'order'
+ break;
+ case 218: // 'return'
+ shift(218); // 'return'
+ break;
+ case 222: // 'satisfies'
+ shift(222); // 'satisfies'
+ break;
+ case 234: // 'stable'
+ shift(234); // 'stable'
+ break;
+ case 235: // 'start'
+ shift(235); // 'start'
+ break;
+ case 246: // 'to'
+ shift(246); // 'to'
+ break;
+ case 247: // 'treat'
+ shift(247); // 'treat'
+ break;
+ case 252: // 'union'
+ shift(252); // 'union'
+ break;
+ case 264: // 'where'
+ shift(264); // 'where'
+ break;
+ case 268: // 'with'
+ shift(268); // 'with'
+ break;
+ case 71: // 'ancestor'
+ shift(71); // 'ancestor'
+ break;
+ case 72: // 'ancestor-or-self'
+ shift(72); // 'ancestor-or-self'
+ break;
+ case 80: // 'attribute'
+ shift(80); // 'attribute'
+ break;
+ case 91: // 'child'
+ shift(91); // 'child'
+ break;
+ case 94: // 'comment'
+ shift(94); // 'comment'
+ break;
+ case 101: // 'copy'
+ shift(101); // 'copy'
+ break;
+ case 106: // 'declare'
+ shift(106); // 'declare'
+ break;
+ case 108: // 'delete'
+ shift(108); // 'delete'
+ break;
+ case 109: // 'descendant'
+ shift(109); // 'descendant'
+ break;
+ case 110: // 'descendant-or-self'
+ shift(110); // 'descendant-or-self'
+ break;
+ case 117: // 'document'
+ shift(117); // 'document'
+ break;
+ case 118: // 'document-node'
+ shift(118); // 'document-node'
+ break;
+ case 119: // 'element'
+ shift(119); // 'element'
+ break;
+ case 122: // 'empty-sequence'
+ shift(122); // 'empty-sequence'
+ break;
+ case 127: // 'every'
+ shift(127); // 'every'
+ break;
+ case 132: // 'first'
+ shift(132); // 'first'
+ break;
+ case 133: // 'following'
+ shift(133); // 'following'
+ break;
+ case 134: // 'following-sibling'
+ shift(134); // 'following-sibling'
+ break;
+ case 143: // 'function'
+ shift(143); // 'function'
+ break;
+ case 150: // 'if'
+ shift(150); // 'if'
+ break;
+ case 151: // 'import'
+ shift(151); // 'import'
+ break;
+ case 157: // 'insert'
+ shift(157); // 'insert'
+ break;
+ case 163: // 'item'
+ shift(163); // 'item'
+ break;
+ case 168: // 'last'
+ shift(168); // 'last'
+ break;
+ case 180: // 'module'
+ shift(180); // 'module'
+ break;
+ case 182: // 'namespace'
+ shift(182); // 'namespace'
+ break;
+ case 183: // 'namespace-node'
+ shift(183); // 'namespace-node'
+ break;
+ case 189: // 'node'
+ shift(189); // 'node'
+ break;
+ case 200: // 'ordered'
+ shift(200); // 'ordered'
+ break;
+ case 204: // 'parent'
+ shift(204); // 'parent'
+ break;
+ case 210: // 'preceding'
+ shift(210); // 'preceding'
+ break;
+ case 211: // 'preceding-sibling'
+ shift(211); // 'preceding-sibling'
+ break;
+ case 214: // 'processing-instruction'
+ shift(214); // 'processing-instruction'
+ break;
+ case 216: // 'rename'
+ shift(216); // 'rename'
+ break;
+ case 217: // 'replace'
+ shift(217); // 'replace'
+ break;
+ case 224: // 'schema-attribute'
+ shift(224); // 'schema-attribute'
+ break;
+ case 225: // 'schema-element'
+ shift(225); // 'schema-element'
+ break;
+ case 227: // 'self'
+ shift(227); // 'self'
+ break;
+ case 233: // 'some'
+ shift(233); // 'some'
+ break;
+ case 241: // 'switch'
+ shift(241); // 'switch'
+ break;
+ case 242: // 'text'
+ shift(242); // 'text'
+ break;
+ case 248: // 'try'
+ shift(248); // 'try'
+ break;
+ case 251: // 'typeswitch'
+ shift(251); // 'typeswitch'
+ break;
+ case 254: // 'unordered'
+ shift(254); // 'unordered'
+ break;
+ case 258: // 'validate'
+ shift(258); // 'validate'
+ break;
+ case 260: // 'variable'
+ shift(260); // 'variable'
+ break;
+ case 272: // 'xquery'
+ shift(272); // 'xquery'
+ break;
+ case 70: // 'allowing'
+ shift(70); // 'allowing'
+ break;
+ case 79: // 'at'
+ shift(79); // 'at'
+ break;
+ case 81: // 'base-uri'
+ shift(81); // 'base-uri'
+ break;
+ case 83: // 'boundary-space'
+ shift(83); // 'boundary-space'
+ break;
+ case 84: // 'break'
+ shift(84); // 'break'
+ break;
+ case 89: // 'catch'
+ shift(89); // 'catch'
+ break;
+ case 96: // 'construction'
+ shift(96); // 'construction'
+ break;
+ case 99: // 'context'
+ shift(99); // 'context'
+ break;
+ case 100: // 'continue'
+ shift(100); // 'continue'
+ break;
+ case 102: // 'copy-namespaces'
+ shift(102); // 'copy-namespaces'
+ break;
+ case 104: // 'decimal-format'
+ shift(104); // 'decimal-format'
+ break;
+ case 123: // 'encoding'
+ shift(123); // 'encoding'
+ break;
+ case 130: // 'exit'
+ shift(130); // 'exit'
+ break;
+ case 131: // 'external'
+ shift(131); // 'external'
+ break;
+ case 139: // 'ft-option'
+ shift(139); // 'ft-option'
+ break;
+ case 152: // 'in'
+ shift(152); // 'in'
+ break;
+ case 153: // 'index'
+ shift(153); // 'index'
+ break;
+ case 159: // 'integrity'
+ shift(159); // 'integrity'
+ break;
+ case 169: // 'lax'
+ shift(169); // 'lax'
+ break;
+ case 190: // 'nodes'
+ shift(190); // 'nodes'
+ break;
+ case 197: // 'option'
+ shift(197); // 'option'
+ break;
+ case 201: // 'ordering'
+ shift(201); // 'ordering'
+ break;
+ case 220: // 'revalidation'
+ shift(220); // 'revalidation'
+ break;
+ case 223: // 'schema'
+ shift(223); // 'schema'
+ break;
+ case 226: // 'score'
+ shift(226); // 'score'
+ break;
+ case 232: // 'sliding'
+ shift(232); // 'sliding'
+ break;
+ case 238: // 'strict'
+ shift(238); // 'strict'
+ break;
+ case 249: // 'tumbling'
+ shift(249); // 'tumbling'
+ break;
+ case 250: // 'type'
+ shift(250); // 'type'
+ break;
+ case 255: // 'updating'
+ shift(255); // 'updating'
+ break;
+ case 259: // 'value'
+ shift(259); // 'value'
+ break;
+ case 261: // 'version'
+ shift(261); // 'version'
+ break;
+ case 265: // 'while'
+ shift(265); // 'while'
+ break;
+ case 95: // 'constraint'
+ shift(95); // 'constraint'
+ break;
+ case 174: // 'loop'
+ shift(174); // 'loop'
+ break;
+ default:
+ shift(219); // 'returning'
+ }
+ eventHandler.endNonterminal("NCName", e0);
+ }
+
+ function shift(t)
+ {
+ if (l1 == t)
+ {
+ whitespace();
+ eventHandler.terminal(JSONiqTokenizer.TOKEN[l1], b1, e1 > size ? size : e1);
+ b0 = b1; e0 = e1; l1 = 0;
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function whitespace()
+ {
+ if (e0 != b1)
+ {
+ b0 = e0;
+ e0 = b1;
+ eventHandler.whitespace(b0, e0);
+ }
+ }
+
+ function matchW(set)
+ {
+ var code;
+ for (;;)
+ {
+ code = match(set);
+ if (code != 30) // S^WS
+ {
+ break;
+ }
+ }
+ return code;
+ }
+
+ function lookahead1W(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = matchW(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead1(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = match(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function error(b, e, s, l, t)
+ {
+ throw new self.ParseException(b, e, s, l, t);
+ }
+
+ var lk, b0, e0;
+ var l1, b1, e1;
+ var eventHandler;
+
+ var input;
+ var size;
+ var begin;
+ var end;
+
+ function match(tokenSetId)
+ {
+ var nonbmp = false;
+ begin = end;
+ var current = end;
+ var result = JSONiqTokenizer.INITIAL[tokenSetId];
+ var state = 0;
+
+ for (var code = result & 4095; code != 0; )
+ {
+ var charclass;
+ var c0 = current < size ? input.charCodeAt(current) : 0;
+ ++current;
+ if (c0 < 0x80)
+ {
+ charclass = JSONiqTokenizer.MAP0[c0];
+ }
+ else if (c0 < 0xd800)
+ {
+ var c1 = c0 >> 4;
+ charclass = JSONiqTokenizer.MAP1[(c0 & 15) + JSONiqTokenizer.MAP1[(c1 & 31) + JSONiqTokenizer.MAP1[c1 >> 5]]];
+ }
+ else
+ {
+ if (c0 < 0xdc00)
+ {
+ var c1 = current < size ? input.charCodeAt(current) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000)
+ {
+ ++current;
+ c0 = ((c0 & 0x3ff) << 10) + (c1 & 0x3ff) + 0x10000;
+ nonbmp = true;
+ }
+ }
+ var lo = 0, hi = 5;
+ for (var m = 3; ; m = (hi + lo) >> 1)
+ {
+ if (JSONiqTokenizer.MAP2[m] > c0) hi = m - 1;
+ else if (JSONiqTokenizer.MAP2[6 + m] < c0) lo = m + 1;
+ else {charclass = JSONiqTokenizer.MAP2[12 + m]; break;}
+ if (lo > hi) {charclass = 0; break;}
+ }
+ }
+
+ state = code;
+ var i0 = (charclass << 12) + code - 1;
+ code = JSONiqTokenizer.TRANSITION[(i0 & 15) + JSONiqTokenizer.TRANSITION[i0 >> 4]];
+
+ if (code > 4095)
+ {
+ result = code;
+ code &= 4095;
+ end = current;
+ }
+ }
+
+ result >>= 12;
+ if (result == 0)
+ {
+ end = current - 1;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ return error(begin, end, state, -1, -1);
+ }
+
+ if (nonbmp)
+ {
+ for (var i = result >> 9; i > 0; --i)
+ {
+ --end;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ }
+ }
+ else
+ {
+ end -= result >> 9;
+ }
+
+ return (result & 511) - 1;
+ }
+}
+
+JSONiqTokenizer.getTokenSet = function(tokenSetId)
+{
+ var set = [];
+ var s = tokenSetId < 0 ? - tokenSetId : INITIAL[tokenSetId] & 4095;
+ for (var i = 0; i < 279; i += 32)
+ {
+ var j = i;
+ var i0 = (i >> 5) * 2066 + s - 1;
+ var i1 = i0 >> 2;
+ var i2 = i1 >> 2;
+ var f = JSONiqTokenizer.EXPECTED[(i0 & 3) + JSONiqTokenizer.EXPECTED[(i1 & 3) + JSONiqTokenizer.EXPECTED[(i2 & 3) + JSONiqTokenizer.EXPECTED[i2 >> 2]]]];
+ for ( ; f != 0; f >>>= 1, ++j)
+ {
+ if ((f & 1) != 0)
+ {
+ set.push(JSONiqTokenizer.TOKEN[j]);
+ }
+ }
+ }
+ return set;
+};
+
+JSONiqTokenizer.MAP0 =
+[ 67, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 37, 31, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 31, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 31, 62, 63, 64, 65, 37
+];
+
+JSONiqTokenizer.MAP1 =
+[ 108, 124, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 156, 181, 181, 181, 181, 181, 214, 215, 213, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 247, 261, 277, 293, 309, 347, 363, 379, 416, 416, 416, 408, 331, 323, 331, 323, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 433, 433, 433, 433, 433, 433, 433, 316, 331, 331, 331, 331, 331, 331, 331, 331, 394, 416, 416, 417, 415, 416, 416, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 330, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 67, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 37, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 37, 31, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 31, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 31, 62, 63, 64, 65, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 31, 31, 37, 37, 37, 37, 37, 37, 37, 66, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66
+];
+
+JSONiqTokenizer.MAP2 =
+[ 57344, 63744, 64976, 65008, 65536, 983040, 63743, 64975, 65007, 65533, 983039, 1114111, 37, 31, 37, 31, 31, 37
+];
+
+JSONiqTokenizer.INITIAL =
+[ 1, 2, 49155, 57348, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
+];
+
+JSONiqTokenizer.TRANSITION =
+[ 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 17408, 19288, 17439, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 22126, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17672, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 19469, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 36919, 18234, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18419, 18432, 18304, 18448, 18485, 18523, 18553, 18583, 18599, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 18825, 18841, 18871, 18906, 18944, 18960, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19074, 36169, 17439, 36866, 17466, 36890, 36866, 22314, 19105, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 22126, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17672, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 19469, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 36919, 18234, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18419, 18432, 18304, 18448, 18485, 18523, 18553, 18583, 18599, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 18825, 18841, 18871, 18906, 18944, 18960, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22182, 19288, 19121, 36866, 17466, 18345, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19273, 19552, 19304, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19332, 17423, 19363, 36866, 17466, 17537, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 18614, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 19391, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 19427, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36154, 19288, 19457, 36866, 17466, 17740, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22780, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22375, 22197, 18469, 36866, 17466, 36890, 36866, 21991, 24018, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 21331, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 19485, 19501, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19537, 22390, 19568, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19596, 19611, 19457, 36866, 17466, 36890, 36866, 18246, 19627, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22242, 20553, 19457, 36866, 17466, 36890, 36866, 18648, 30477, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36472, 19288, 19457, 36866, 17466, 17809, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 21770, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 19643, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 19672, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 20538, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 17975, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22345, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19726, 19742, 21529, 24035, 23112, 26225, 23511, 27749, 27397, 24035, 34360, 24035, 24036, 23114, 35166, 23114, 23114, 19758, 23511, 35247, 23511, 23511, 28447, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 24254, 19821, 23511, 23511, 23511, 23511, 23512, 19441, 36539, 24035, 24035, 24035, 24035, 19846, 19869, 23114, 23114, 23114, 28618, 32187, 19892, 23511, 23511, 23511, 34585, 20402, 36647, 24035, 24035, 24036, 23114, 33757, 23114, 23114, 23029, 20271, 23511, 27070, 23511, 23511, 30562, 24035, 24035, 29274, 26576, 23114, 23114, 31118, 23036, 29695, 23511, 23511, 32431, 23634, 30821, 24035, 23110, 19913, 23114, 23467, 31261, 23261, 34299, 19932, 24035, 32609, 19965, 35389, 19984, 27689, 19830, 29391, 29337, 20041, 22643, 35619, 33728, 20062, 20121, 20166, 35100, 26145, 20211, 23008, 19876, 20208, 20227, 25670, 20132, 26578, 27685, 20141, 20243, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36094, 19288, 19457, 36866, 17466, 21724, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22735, 19552, 20287, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22750, 19288, 21529, 24035, 23112, 28056, 23511, 29483, 28756, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 20327, 23511, 23511, 23511, 23511, 31156, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 24254, 20371, 23511, 23511, 23511, 23511, 27443, 20395, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 29457, 29700, 23511, 23511, 23511, 23511, 33444, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 28350, 20421, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 20447, 20475, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 20523, 22257, 20569, 20783, 21715, 17603, 20699, 20837, 20614, 20630, 21149, 20670, 21405, 17486, 17509, 17525, 18373, 19179, 20695, 20716, 20732, 20755, 19194, 18042, 21641, 20592, 20779, 20598, 21412, 17470, 17591, 20896, 17468, 17619, 20799, 20700, 21031, 20744, 20699, 20828, 18075, 21259, 20581, 20853, 18048, 20868, 20884, 17756, 17784, 17800, 17825, 17854, 21171, 21200, 20931, 20947, 21378, 20955, 20971, 18086, 20645, 21002, 20986, 18178, 17960, 18012, 18381, 18064, 29176, 21044, 21438, 21018, 21122, 21393, 21060, 21844, 21094, 20654, 17493, 18150, 18166, 18214, 25967, 20763, 21799, 21110, 21830, 21138, 21246, 21301, 18336, 18361, 21165, 21187, 20812, 21216, 21232, 21287, 21317, 18553, 21347, 21363, 21428, 21454, 21271, 21483, 21499, 21515, 21575, 21467, 18712, 21591, 21633, 21078, 18189, 18198, 20679, 21657, 21701, 21074, 21687, 21740, 21756, 21786, 21815, 21860, 21876, 21892, 21946, 21962, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36457, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 36813, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 21981, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 22151, 22007, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 27898, 17884, 18890, 17906, 17928, 22042, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 22070, 22112, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 22142, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36109, 19288, 18469, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22167, 19288, 19457, 36866, 17466, 17768, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22227, 36487, 22273, 36866, 17466, 36890, 36866, 19316, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18749, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 22304, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 19580, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22330, 19089, 19457, 36866, 17466, 18721, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22765, 19347, 19457, 36866, 17466, 36890, 36866, 18114, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34541, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 22540, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29908, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22561, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 23837, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22584, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36442, 19288, 21605, 24035, 23112, 28137, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 31568, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22690, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 27584, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 22659, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22360, 19552, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22675, 22811, 19457, 36866, 17466, 36890, 36866, 19133, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 22827, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36139, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36064, 19288, 22865, 22881, 32031, 22897, 22913, 22956, 29939, 24035, 24035, 24035, 23003, 23114, 23114, 23114, 23024, 22420, 23511, 23511, 23511, 23052, 29116, 23073, 29268, 24035, 25563, 26915, 23106, 23131, 23114, 23114, 23159, 23181, 23197, 23248, 23511, 23511, 23282, 23305, 22493, 32364, 24035, 33472, 30138, 26325, 31770, 33508, 27345, 33667, 23114, 23321, 23473, 23351, 35793, 36576, 23511, 23375, 22500, 24145, 24035, 29197, 20192, 24533, 23440, 23114, 19017, 23459, 22839, 23489, 23510, 23511, 33563, 23528, 32076, 25389, 24035, 26576, 23561, 23583, 23114, 32683, 22516, 23622, 23655, 23511, 23634, 35456, 37144, 23110, 23683, 34153, 20499, 32513, 25824, 23705, 24035, 24035, 23111, 23114, 19874, 27078, 33263, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 20507, 32241, 20150, 31862, 27464, 35108, 23727, 23007, 35895, 34953, 26578, 27685, 20141, 24569, 31691, 19787, 33967, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36427, 19552, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 27027, 26576, 23114, 23114, 23114, 31471, 23756, 22468, 23511, 23511, 23511, 34687, 23772, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 23788, 24035, 24035, 24035, 21559, 23828, 23114, 23114, 23114, 25086, 22839, 23853, 23511, 23511, 23511, 23876, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 31761, 23909, 23953, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36049, 19288, 21605, 30825, 23112, 23987, 23511, 24003, 31001, 27617, 24034, 24035, 24036, 24052, 24089, 23114, 23114, 22420, 24109, 24168, 23511, 23511, 29116, 24188, 27609, 20017, 29516, 24035, 26576, 24222, 19968, 23114, 24252, 33811, 22468, 24270, 33587, 23511, 24320, 27443, 22493, 24035, 24035, 24035, 24035, 24339, 23113, 23114, 23114, 23114, 28128, 28618, 29700, 23511, 23511, 23511, 28276, 34564, 20402, 24035, 24035, 32929, 24036, 23114, 23114, 23114, 24357, 23029, 22839, 23511, 23511, 23511, 24377, 25645, 24035, 34112, 24035, 26576, 23114, 26643, 23114, 32683, 22516, 23511, 25638, 23511, 23711, 24035, 24395, 27809, 23114, 24414, 20499, 24432, 30917, 23628, 24035, 30680, 23111, 23114, 30233, 27078, 25748, 24452, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 24475, 19829, 26577, 26597, 26154, 24519, 24556, 24596, 23007, 20046, 20132, 26578, 24634, 20141, 24569, 31691, 24679, 24727, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36412, 19288, 21605, 19943, 34861, 32618, 26027, 29483, 32016, 32050, 36233, 24776, 35574, 24801, 24819, 32671, 31289, 22420, 24868, 24886, 20087, 26849, 29116, 19803, 24035, 24035, 24035, 36228, 26576, 23114, 23114, 23114, 24981, 33811, 22468, 23511, 23511, 23511, 29028, 27443, 22493, 24923, 27965, 24035, 24035, 32797, 24946, 23443, 23114, 23114, 29636, 24997, 22849, 28252, 23511, 23511, 23511, 25042, 25110, 24035, 24035, 34085, 24036, 25133, 23114, 23114, 25152, 23029, 22839, 25169, 23511, 36764, 23511, 25645, 30403, 24035, 25186, 26576, 31806, 24093, 25212, 32683, 22516, 32713, 26245, 34293, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 32406, 23111, 23114, 28676, 30944, 27689, 25234, 24035, 23112, 19872, 37063, 23266, 24036, 23114, 30243, 20379, 26100, 29218, 20211, 30105, 25257, 25284, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 24834, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36034, 19288, 21671, 25314, 25072, 25330, 25346, 25362, 29939, 29951, 35288, 29984, 23812, 27216, 25405, 25424, 30456, 22584, 26292, 25461, 25480, 31592, 29116, 25516, 34963, 25545, 27007, 25579, 33937, 25614, 25661, 25686, 34872, 25702, 25718, 25734, 25769, 25795, 25811, 25840, 22493, 26533, 25856, 24035, 25876, 30763, 27481, 25909, 23114, 28987, 25936, 25954, 29700, 25983, 23511, 31412, 26043, 26063, 22568, 29241, 29592, 26116, 31216, 35383, 26170, 34783, 26194, 26221, 22839, 26241, 26261, 22477, 26283, 26308, 27306, 31035, 24655, 26576, 29854, 33386, 26341, 32683, 22516, 32153, 30926, 26361, 19996, 26381, 35463, 26397, 26424, 34646, 26478, 35605, 31386, 26494, 35567, 31964, 22940, 23689, 25218, 30309, 32289, 19830, 33605, 23112, 32109, 27733, 27084, 24496, 35886, 35221, 26525, 36602, 26549, 26558, 26574, 26594, 26613, 26629, 26666, 26700, 26578, 27685, 23740, 24285, 31691, 26733, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36397, 19552, 18991, 25887, 28117, 32618, 26776, 29483, 29939, 26802, 24035, 24035, 24036, 28664, 23114, 23114, 23114, 22420, 30297, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 25559, 26576, 23114, 23114, 23114, 30525, 33811, 22468, 23511, 23511, 23511, 28725, 27443, 22493, 24035, 24035, 27249, 24035, 24035, 23113, 23114, 23114, 26827, 23114, 28618, 29700, 23511, 23511, 26845, 23511, 34564, 20402, 24035, 24035, 26979, 24036, 23114, 23114, 23114, 24974, 23029, 22839, 23511, 23511, 23511, 26865, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 33305, 24035, 25598, 23114, 19874, 34253, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 26886, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 26931, 24569, 26439, 26947, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36019, 19288, 26995, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 27043, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 27061, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 29978, 24035, 24035, 23113, 23114, 33114, 23114, 23114, 30010, 29700, 23511, 35913, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 27155, 26576, 23114, 23114, 30447, 23036, 29695, 23511, 23511, 30935, 20099, 24152, 25529, 27100, 34461, 27121, 22625, 29156, 26009, 27137, 30422, 31903, 31655, 28870, 27171, 32439, 31731, 19830, 27232, 22612, 27265, 26786, 25494, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 20342, 27288, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 27322, 27339, 28020, 27361, 27382, 29939, 24035, 24035, 32581, 24036, 23114, 23114, 23114, 27425, 22420, 23511, 23511, 23511, 27442, 28306, 19803, 24035, 24035, 24035, 24035, 26710, 23114, 23114, 23114, 23114, 32261, 22468, 23511, 23511, 23511, 23511, 35719, 24694, 29510, 24035, 24035, 24035, 24035, 26717, 23114, 23114, 23114, 23114, 28618, 32217, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 27459, 23114, 23114, 23114, 36252, 23029, 20271, 23511, 23511, 23511, 28840, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 27480, 34483, 28401, 29761, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36382, 19288, 21605, 27497, 27517, 28504, 28898, 27569, 29939, 29401, 27600, 27323, 27633, 19025, 27662, 23114, 27705, 22420, 20483, 27721, 23511, 27765, 28306, 19803, 23540, 24035, 24610, 27781, 27805, 26650, 23114, 28573, 32990, 25920, 22468, 26870, 23511, 26684, 34262, 34737, 25057, 34622, 24035, 24035, 23971, 24206, 27825, 27847, 23114, 23114, 27865, 27885, 35766, 27914, 23511, 23511, 32766, 32844, 27934, 28795, 26909, 27955, 26092, 27988, 25445, 28005, 28036, 28052, 21965, 23511, 32196, 19897, 28072, 28102, 36534, 21541, 23801, 28153, 28180, 28197, 28221, 23036, 32695, 28251, 28268, 28292, 23667, 34825, 23930, 24580, 28322, 28344, 31627, 28366, 25996, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 35625, 33477, 33359, 27674, 28393, 33992, 24036, 23114, 30243, 19829, 28417, 28433, 28463, 23008, 19876, 20208, 23007, 20046, 20132, 28489, 28520, 20141, 24569, 31691, 19787, 28550, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 28589, 24035, 24035, 24035, 24035, 28608, 23114, 23114, 23114, 23114, 28618, 20431, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36004, 19288, 28634, 31951, 28565, 28702, 28718, 28741, 32544, 20175, 28792, 32086, 20105, 28811, 29059, 29862, 28856, 22420, 28886, 30354, 23359, 28922, 28306, 28952, 23888, 26320, 36506, 24035, 29331, 28968, 36609, 23114, 29003, 31661, 27061, 30649, 27366, 23511, 29023, 27918, 24694, 24035, 24035, 23893, 33094, 30867, 23113, 23114, 23114, 29044, 34184, 30010, 29700, 23511, 23511, 29081, 29102, 34585, 20402, 27789, 24035, 24035, 24036, 23114, 29132, 23114, 23114, 23029, 20271, 23511, 29153, 23511, 23511, 30562, 30174, 24035, 24035, 27409, 25438, 23114, 23114, 29172, 36668, 31332, 23511, 23511, 29192, 30144, 24035, 23110, 30203, 23114, 23467, 31544, 23261, 23628, 24035, 22545, 23111, 23114, 29213, 27078, 27689, 29234, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 29257, 23008, 19876, 20208, 28768, 29290, 29320, 34776, 29353, 20141, 22435, 29378, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36367, 19288, 21605, 34616, 19006, 32618, 31497, 31507, 36216, 20184, 24035, 34393, 29424, 34668, 23114, 34900, 29447, 22420, 30360, 23511, 37089, 29473, 28306, 19803, 29499, 24398, 24035, 24035, 26576, 31799, 29532, 29550, 23114, 33811, 22468, 32298, 29571, 31184, 23511, 23512, 37127, 36628, 29589, 24035, 24135, 24035, 23113, 29608, 23114, 27831, 29634, 28618, 29652, 30037, 23511, 24172, 29671, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 29555, 29690, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 29719, 24035, 23110, 29738, 23114, 23467, 34035, 29756, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 29777, 34364, 28181, 30243, 29799, 31920, 27272, 27185, 23008, 31126, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29828, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35989, 19552, 19687, 35139, 28649, 29878, 29894, 29924, 29939, 23224, 23085, 31969, 24036, 35173, 24752, 24803, 23114, 22420, 31190, 30318, 24870, 23511, 28306, 29967, 23967, 24035, 24035, 24035, 26576, 30000, 23114, 23114, 23114, 33811, 22468, 30026, 23511, 23511, 23511, 23512, 26078, 24035, 24035, 24035, 30053, 37137, 30071, 23114, 23114, 33368, 25136, 28618, 30723, 23511, 23511, 37096, 31356, 34585, 20402, 30092, 30127, 30160, 24036, 35740, 30219, 24960, 30259, 23029, 20271, 34042, 30285, 30342, 30376, 23289, 30055, 30400, 30419, 30438, 32640, 33532, 33514, 30472, 18792, 26267, 24323, 23057, 30493, 23639, 20008, 30196, 33188, 30517, 20075, 23511, 30541, 23628, 30578, 33928, 28776, 30594, 19874, 30610, 30637, 19830, 30677, 27646, 19872, 25779, 23266, 23232, 35016, 30243, 30696, 29812, 30712, 30746, 27206, 30779, 30807, 23007, 33395, 20132, 26578, 27685, 31703, 22928, 31691, 19787, 31079, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36352, 19288, 23335, 30841, 26131, 30888, 30904, 30986, 29939, 24035, 24704, 31017, 20025, 23114, 26178, 31051, 31095, 22420, 23511, 22524, 31142, 31172, 28534, 31206, 35497, 25196, 24035, 28592, 24503, 23114, 31239, 31285, 23114, 31305, 31321, 31355, 31372, 31407, 23511, 30556, 24694, 24035, 27501, 19805, 24035, 24035, 23113, 23114, 31428, 24066, 23114, 28618, 29700, 23511, 31837, 18809, 23511, 34585, 31448, 24035, 24035, 24035, 23090, 23114, 23114, 23114, 23114, 31619, 35038, 23511, 23511, 23511, 23511, 33714, 24035, 33085, 24035, 29431, 23114, 31467, 23114, 23143, 31487, 23511, 31523, 23511, 35195, 36783, 24035, 30111, 23567, 23114, 23467, 31543, 31560, 23628, 24035, 24035, 23111, 23114, 19874, 30953, 31584, 34508, 24035, 31608, 26345, 37055, 23266, 31643, 31677, 31719, 31747, 31786, 31822, 26898, 23008, 19876, 31859, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 31878, 31936, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35974, 19288, 21605, 27972, 35663, 31985, 29655, 32001, 36715, 24785, 25893, 23545, 31912, 19853, 19916, 25938, 24540, 22420, 31843, 29674, 29573, 32735, 28936, 19803, 24035, 24035, 32047, 24035, 26576, 23114, 23114, 27544, 23114, 33811, 22468, 23511, 23511, 32161, 23511, 23512, 32066, 24035, 33313, 24035, 24035, 24035, 23113, 27426, 32102, 23114, 23114, 28618, 32125, 23511, 32144, 23511, 23511, 33569, 20402, 24035, 27045, 24035, 24036, 23114, 23114, 28328, 23114, 30076, 32177, 23511, 23511, 30384, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23595, 32212, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 22635, 25753, 32233, 32257, 32277, 19829, 26577, 26597, 20211, 23008, 19876, 32322, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 32352, 35285, 32380, 34196, 33016, 30661, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 32404, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 32422, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 30269, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 19949, 24035, 23111, 32455, 19874, 31269, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36337, 19552, 19209, 21617, 26509, 32475, 32491, 32529, 29939, 24035, 32578, 25241, 32597, 23114, 32634, 29007, 32656, 22420, 23511, 32729, 26365, 32751, 28306, 32788, 32882, 24035, 24035, 32813, 36727, 23114, 33182, 23114, 27553, 33235, 32829, 23511, 32706, 23511, 28906, 28377, 26962, 32881, 32904, 32898, 32920, 24035, 32953, 23114, 32977, 26408, 23114, 28164, 33006, 23511, 33039, 35774, 23511, 32306, 20402, 33076, 30872, 24035, 24036, 25408, 33110, 28979, 23114, 23029, 20271, 35835, 33130, 33054, 23511, 30562, 33148, 24035, 24035, 33167, 23114, 23114, 33775, 23036, 20459, 23511, 23511, 25464, 24646, 24035, 24035, 22446, 23114, 23114, 25627, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 31391, 33204, 33220, 33251, 33287, 26577, 26597, 20211, 33329, 19876, 33345, 23007, 20046, 20132, 26578, 27685, 28473, 22599, 31691, 33411, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35959, 19288, 21907, 27243, 29843, 32618, 33427, 31507, 29939, 33460, 34090, 24035, 24036, 33493, 24416, 33530, 23114, 22420, 33548, 24379, 33585, 23511, 28306, 19803, 33603, 24202, 24035, 24035, 25593, 33749, 28205, 23114, 23114, 32388, 22468, 33853, 33060, 23511, 23511, 31339, 33621, 24035, 24035, 34397, 24618, 30757, 33663, 23114, 23114, 33683, 35684, 28618, 26678, 23511, 23511, 32506, 33699, 34585, 20402, 24035, 32562, 26973, 24036, 23114, 23114, 33377, 33773, 23029, 20271, 23511, 23511, 30621, 23511, 23860, 24035, 33791, 21553, 26576, 36558, 23114, 33809, 23036, 32857, 26047, 23511, 33827, 23634, 24035, 24035, 23110, 23114, 23114, 31252, 23511, 33845, 23628, 24035, 24459, 23111, 23114, 33869, 27078, 30791, 29783, 24035, 24742, 19872, 33895, 23266, 26462, 19710, 33879, 33919, 26577, 26597, 24123, 24930, 21930, 20208, 30501, 33953, 25268, 20252, 33983, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36322, 19552, 23390, 33634, 35154, 34008, 34024, 34058, 35544, 34106, 34128, 26811, 33151, 34144, 34169, 34212, 23114, 34228, 34244, 34278, 34315, 23511, 34331, 34347, 34380, 34413, 24035, 24663, 26576, 34429, 34453, 34477, 29534, 33811, 22468, 34499, 34524, 34557, 25170, 34580, 35436, 23937, 34601, 24035, 24341, 26453, 23113, 34638, 34662, 23114, 24236, 28618, 34684, 34703, 34729, 23511, 35352, 34753, 34799, 24035, 34815, 32558, 34848, 34888, 35814, 34923, 23165, 29137, 23606, 30326, 30730, 34939, 33023, 30562, 36848, 34979, 24035, 24847, 34996, 23114, 23114, 35032, 29695, 35054, 23511, 23511, 35091, 33296, 35124, 24296, 28235, 24361, 36276, 32772, 35067, 35189, 27301, 30855, 24852, 22452, 35211, 35237, 35316, 25500, 35270, 23405, 24304, 35304, 29362, 24036, 23114, 35332, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 35368, 28823, 23920, 32336, 35405, 20141, 24569, 31691, 35421, 35479, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35944, 22795, 21605, 33647, 35877, 35513, 30962, 35529, 34073, 35557, 24035, 24035, 20405, 31107, 23114, 23114, 23114, 35590, 34713, 23511, 23511, 23511, 35641, 19803, 29408, 32937, 25298, 24035, 35657, 23115, 27849, 24760, 35679, 26205, 22468, 23511, 35700, 24907, 24901, 35075, 31893, 34980, 24035, 24035, 24035, 24035, 23113, 35009, 23114, 23114, 23114, 28618, 35716, 30970, 23511, 23511, 23511, 34585, 23215, 24035, 24035, 24035, 24036, 35735, 23114, 23114, 23114, 27105, 35756, 35790, 23511, 23511, 23511, 35254, 35446, 24035, 24035, 31223, 35809, 23114, 23114, 23036, 36825, 35830, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 31031, 20355, 19872, 33903, 23266, 24036, 23114, 28686, 19829, 26577, 26597, 20211, 23008, 23424, 20208, 24711, 31065, 24486, 26578, 27685, 20141, 19773, 35851, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36307, 19288, 21605, 35494, 19702, 32618, 33437, 31507, 29939, 25117, 24035, 27939, 24036, 27869, 23114, 26829, 23114, 22420, 23494, 23511, 33132, 23511, 28306, 19803, 24035, 34832, 24035, 24035, 26576, 23114, 25153, 23114, 23114, 33811, 22468, 23511, 23511, 35911, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35929, 19288, 21605, 25860, 23112, 36185, 23511, 36201, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 26748, 24035, 24035, 24035, 24035, 24035, 36249, 23114, 23114, 23114, 23114, 28618, 28835, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 27151, 24035, 26760, 23114, 27989, 23114, 23114, 36268, 20271, 23511, 24436, 23511, 29703, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36292, 19288, 21605, 36503, 21922, 32618, 34534, 31507, 36522, 24035, 33793, 24035, 35864, 23114, 23114, 36555, 23417, 22420, 23511, 23511, 36574, 26020, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 36592, 24035, 24035, 36625, 24035, 24035, 23113, 23114, 32961, 23114, 23114, 29618, 29700, 23511, 29086, 23511, 23511, 34585, 20402, 36644, 24035, 24035, 24036, 29740, 23114, 23114, 23114, 29065, 36663, 31527, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 31451, 23112, 36684, 23511, 36700, 29939, 24035, 24035, 24035, 30185, 23114, 23114, 23114, 27526, 22420, 23511, 23511, 23511, 32865, 28306, 19803, 36743, 24035, 27017, 24035, 26576, 27535, 23114, 31432, 23114, 33811, 22468, 33271, 23511, 32128, 23511, 23512, 24694, 24035, 27196, 24035, 24035, 24035, 23113, 32459, 23114, 23114, 23114, 28618, 29700, 33829, 36762, 23511, 23511, 34585, 20402, 24035, 36746, 24035, 29722, 23114, 23114, 34437, 23114, 34907, 20271, 23511, 23511, 18801, 23511, 23206, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 36837, 24035, 24035, 33739, 23114, 23114, 25094, 23511, 23261, 23628, 24035, 36780, 23111, 24073, 19874, 27078, 35344, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22720, 19288, 36799, 36866, 17466, 36890, 36864, 21991, 22211, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 17631, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 36883, 36906, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22705, 19288, 19457, 36866, 17466, 36890, 36866, 19375, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36124, 19288, 36951, 36866, 17466, 36890, 36866, 21991, 22404, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18567, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 36979, 36995, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36139, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18027, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36139, 19288, 21529, 24035, 23112, 23033, 23511, 31507, 25377, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 37040, 23511, 23511, 23511, 23511, 28086, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 24254, 37079, 23511, 23511, 23511, 23511, 23512, 34766, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 37112, 37160, 18469, 36866, 17466, 36890, 36866, 17656, 37174, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18537, 22984, 17553, 17572, 22285, 18780, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 36883, 36906, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 127011, 110630, 114730, 106539, 127011, 127011, 127011, 53264, 18, 18, 0, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 0, 0, 127011, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2170880, 2170880, 2170880, 3002368, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2576384, 2215936, 2215936, 2215936, 2416640, 2424832, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2543616, 2215936, 2215936, 2215936, 2215936, 2215936, 2629632, 2215936, 2617344, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2691072, 2215936, 2707456, 2215936, 2715648, 2215936, 2723840, 2764800, 2215936, 2215936, 2797568, 2215936, 2822144, 2215936, 2215936, 2854912, 2215936, 2215936, 2215936, 2912256, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 180224, 0, 0, 2174976, 0, 0, 2170880, 2617344, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2691072, 2170880, 2707456, 2170880, 2715648, 2170880, 2723840, 2764800, 2170880, 2170880, 2797568, 2170880, 2170880, 2797568, 2170880, 2822144, 2170880, 2170880, 2854912, 2170880, 2170880, 2170880, 2912256, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2609152, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2654208, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 184599, 280, 0, 2174976, 0, 0, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 544, 0, 546, 0, 0, 2179072, 0, 0, 0, 552, 0, 0, 2170880, 2170880, 2170880, 3117056, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2158592, 2158592, 2232320, 2232320, 0, 2240512, 2240512, 0, 0, 0, 644, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3129344, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2400256, 2215936, 2215936, 2215936, 2215936, 2711552, 2170880, 2170880, 2170880, 2170880, 2170880, 2760704, 2768896, 2789376, 2813952, 2170880, 2170880, 2170880, 2875392, 2904064, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2453504, 2457600, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 167936, 0, 0, 0, 0, 2174976, 0, 0, 2215936, 2215936, 2514944, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2592768, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 32768, 0, 0, 0, 0, 0, 2174976, 32768, 0, 2633728, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2711552, 2215936, 2215936, 2215936, 2215936, 2215936, 2760704, 2768896, 2789376, 2813952, 2215936, 2215936, 2215936, 2875392, 2904064, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 0, 65819, 2215936, 2215936, 3031040, 2215936, 3055616, 2215936, 2215936, 2215936, 2215936, 3092480, 2215936, 2215936, 3125248, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3002368, 2215936, 2215936, 2170880, 2170880, 2494464, 2170880, 2170880, 0, 0, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3198976, 2215936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2379776, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2445312, 2170880, 2465792, 2473984, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2523136, 2170880, 2170880, 2641920, 2170880, 2170880, 2170880, 2699264, 2170880, 2727936, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2879488, 2170880, 2916352, 2170880, 2170880, 2170880, 2879488, 2170880, 2916352, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3026944, 2170880, 2170880, 3063808, 2170880, 2170880, 3112960, 2170880, 2170880, 3133440, 2170880, 2170880, 3112960, 2170880, 2170880, 3133440, 2170880, 2170880, 2170880, 3162112, 2170880, 2170880, 3182592, 3186688, 2170880, 2379776, 2215936, 2523136, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2596864, 2215936, 2621440, 2215936, 2215936, 2641920, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 548, 0, 0, 0, 0, 287, 2170880, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3117056, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2699264, 2215936, 2727936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2879488, 2215936, 2916352, 2215936, 2215936, 0, 0, 0, 0, 188416, 0, 2179072, 0, 0, 0, 0, 0, 287, 2170880, 0, 2171019, 2171019, 2171019, 2400395, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3031179, 2171019, 3055755, 2171019, 2171019, 2215936, 3133440, 2215936, 2215936, 2215936, 3162112, 2215936, 2215936, 3182592, 3186688, 2215936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2523275, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2597003, 2171019, 2621579, 2170880, 2170880, 2170880, 3162112, 2170880, 2170880, 3182592, 3186688, 2170880, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 24, 0, 4337664, 28, 2170880, 2170880, 2170880, 2629632, 2170880, 2170880, 2170880, 2170880, 2719744, 2744320, 2170880, 2170880, 2170880, 2834432, 2838528, 2170880, 2908160, 2170880, 2170880, 2936832, 2215936, 2215936, 2215936, 2215936, 2719744, 2744320, 2215936, 2215936, 2215936, 2834432, 2838528, 2215936, 2908160, 2215936, 2215936, 2936832, 2215936, 2215936, 2985984, 2215936, 2994176, 2215936, 2215936, 3014656, 2215936, 3059712, 3076096, 3088384, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2445312, 2215936, 2465792, 2473984, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2171166, 2171166, 2171166, 2171166, 2171166, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171019, 2171019, 2494603, 2171019, 2171019, 2215936, 2215936, 2215936, 3215360, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2379776, 2170880, 2170880, 2170880, 2170880, 2985984, 2170880, 2994176, 2170880, 2170880, 3016168, 2170880, 3059712, 3076096, 3088384, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 124, 124, 0, 128, 128, 2170880, 2170880, 2170880, 3215360, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2486272, 2170880, 2170880, 2506752, 2170880, 2170880, 2170880, 2535424, 2539520, 2170880, 2170880, 2588672, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2920448, 2170880, 2170880, 2170880, 2990080, 2170880, 2170880, 2170880, 2170880, 3051520, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3170304, 0, 2387968, 2392064, 2170880, 2170880, 2433024, 2170880, 2170880, 2170880, 3170304, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2486272, 2215936, 2215936, 2506752, 2215936, 2215936, 2215936, 2535424, 2539520, 2215936, 2215936, 2588672, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 136, 0, 2215936, 2215936, 2920448, 2215936, 2215936, 2215936, 2990080, 2215936, 2215936, 2215936, 2215936, 3051520, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3108864, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3026944, 2215936, 2215936, 3063808, 2215936, 2215936, 3112960, 2215936, 2215936, 2215936, 3170304, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2453504, 2457600, 2170880, 2170880, 2170880, 2486272, 2170880, 2170880, 2506752, 2170880, 2170880, 2170880, 2537049, 2539520, 2170880, 2170880, 2588672, 2170880, 2170880, 2170880, 1508, 2170880, 2170880, 2170880, 1512, 2170880, 2920448, 2170880, 2170880, 2170880, 2990080, 2170880, 2170880, 2170880, 2461696, 2170880, 2170880, 2170880, 2510848, 2170880, 2170880, 2170880, 2170880, 2580480, 2170880, 2605056, 2637824, 2170880, 2170880, 18, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2686976, 2748416, 2170880, 2170880, 2170880, 2924544, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3121152, 2170880, 2170880, 3145728, 3158016, 3166208, 2170880, 2420736, 2428928, 2170880, 2478080, 2170880, 2170880, 2170880, 2170880, 0, 0, 2170880, 2170880, 2170880, 2170880, 2646016, 2670592, 0, 0, 3145728, 3158016, 3166208, 2387968, 2392064, 2215936, 2215936, 2433024, 2215936, 2461696, 2215936, 2215936, 2215936, 2510848, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 0, 2170880, 2215936, 2215936, 2580480, 2215936, 2605056, 2637824, 2215936, 2215936, 2686976, 2748416, 2215936, 2215936, 2215936, 2924544, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 286, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 3121152, 2215936, 2215936, 3145728, 3158016, 3166208, 2387968, 2392064, 2170880, 2170880, 2433024, 2170880, 2461696, 2170880, 2170880, 2170880, 2510848, 2170880, 2170880, 1625, 2170880, 2170880, 2580480, 2170880, 2605056, 2637824, 2170880, 647, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2576384, 2170880, 2170880, 2170880, 2170880, 2170880, 2609152, 2170880, 2170880, 2686976, 0, 0, 2748416, 2170880, 2170880, 0, 2170880, 2924544, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 0, 0, 28, 28, 2170880, 3141632, 2215936, 2420736, 2428928, 2215936, 2478080, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2646016, 2670592, 2752512, 2756608, 2846720, 2961408, 2215936, 2998272, 2215936, 3010560, 2215936, 2215936, 2215936, 3141632, 2170880, 2420736, 2428928, 2752512, 2756608, 0, 2846720, 2961408, 2170880, 2998272, 2170880, 3010560, 2170880, 2170880, 2170880, 3141632, 2170880, 2170880, 2490368, 2215936, 2490368, 2215936, 2215936, 2215936, 2547712, 2555904, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 245760, 0, 3129344, 2170880, 2170880, 2490368, 2170880, 2170880, 2170880, 0, 0, 2547712, 2555904, 2170880, 2170880, 2170880, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 45056, 0, 2584576, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2170880, 2170880, 2158592, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 0, 1482, 97, 97, 97, 97, 97, 97, 97, 1354, 97, 97, 97, 97, 97, 97, 97, 97, 1148, 97, 97, 97, 97, 97, 97, 97, 2584576, 2170880, 2170880, 1512, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2441216, 2170880, 2527232, 2170880, 2600960, 2170880, 2850816, 2170880, 2170880, 2170880, 3022848, 2215936, 2441216, 2215936, 2527232, 2215936, 2600960, 2215936, 2850816, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 287, 2170880, 2215936, 3022848, 2170880, 2441216, 2170880, 2527232, 0, 0, 2170880, 2600960, 2170880, 0, 2850816, 2170880, 2170880, 2170880, 2170880, 2170880, 2523136, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2596864, 2170880, 2621440, 2170880, 2170880, 2641920, 2170880, 2170880, 2170880, 3022848, 2170880, 2519040, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2519040, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 2453504, 2457600, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2514944, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2592768, 2170880, 2170880, 2519040, 0, 2024, 2170880, 2170880, 0, 2170880, 2170880, 2170880, 2396160, 2170880, 2170880, 2170880, 2170880, 3018752, 2396160, 2215936, 2215936, 2215936, 2215936, 3018752, 2396160, 0, 2024, 2170880, 2170880, 2170880, 2170880, 3018752, 2170880, 2650112, 2965504, 2170880, 2215936, 2650112, 2965504, 2215936, 0, 0, 2170880, 2650112, 2965504, 2170880, 2551808, 2170880, 2551808, 2215936, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 141, 45, 45, 67, 67, 67, 67, 67, 224, 67, 67, 238, 67, 67, 67, 67, 67, 67, 67, 1288, 67, 67, 67, 67, 67, 67, 67, 67, 67, 469, 67, 67, 67, 67, 67, 67, 0, 2551808, 2170880, 2170880, 2215936, 0, 2170880, 2170880, 2215936, 0, 2170880, 2170880, 2215936, 0, 2170880, 2977792, 2977792, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 29, 102432, 127011, 110630, 114730, 106539, 127011, 127011, 127011, 53264, 18, 18, 49172, 0, 0, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 0, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 136, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 4256099, 4256099, 24, 24, 0, 28, 28, 2170880, 2461696, 2170880, 2170880, 2170880, 2510848, 2170880, 2170880, 0, 2170880, 2170880, 2580480, 2170880, 2605056, 2637824, 2170880, 2170880, 2170880, 2547712, 2555904, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3129344, 2215936, 2215936, 543, 543, 545, 545, 0, 0, 2179072, 0, 550, 551, 551, 0, 287, 2171166, 2171166, 18, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 645, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 149, 2584576, 2170880, 2170880, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2441216, 2170880, 2527232, 2170880, 2600960, 2519040, 0, 0, 2170880, 2170880, 0, 2170880, 2170880, 2170880, 2396160, 2170880, 2170880, 2170880, 2170880, 3018752, 2396160, 2215936, 2215936, 2215936, 2215936, 3018752, 2396160, 0, 0, 2170880, 2170880, 2170880, 2170880, 3018752, 2170880, 2650112, 2965504, 53264, 18, 49172, 57366, 24, 155648, 28, 102432, 155648, 155687, 114730, 106539, 0, 0, 155648, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 0, 0, 0, 0, 2220032, 0, 94208, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 208896, 18, 278528, 24, 24, 0, 28, 28, 53264, 18, 159765, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 0, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 139394, 28, 28, 102432, 131, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 32768, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 546, 0, 0, 2183168, 0, 0, 552, 832, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2170880, 2609152, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2654208, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3198976, 2215936, 0, 1084, 0, 1088, 0, 1092, 0, 0, 0, 0, 0, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 937, 0, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 644, 0, 0, 0, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 826, 0, 828, 0, 0, 2183168, 0, 0, 830, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2592768, 2170880, 2170880, 2170880, 2170880, 2633728, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2711552, 2170880, 2170880, 2170880, 2170880, 2170880, 2760704, 53264, 18, 49172, 57366, 24, 8192, 28, 172066, 172032, 110630, 172066, 106539, 0, 0, 172032, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 16384, 28, 28, 28, 28, 102432, 0, 98304, 0, 0, 2220032, 110630, 0, 0, 0, 0, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 45056, 0, 0, 0, 53264, 18, 49172, 57366, 25, 8192, 30, 102432, 0, 110630, 114730, 106539, 0, 0, 176219, 53264, 18, 18, 49172, 0, 57366, 0, 124, 124, 124, 0, 128, 128, 128, 128, 102432, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 0, 546, 0, 0, 2183168, 0, 65536, 552, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2646016, 2670592, 2752512, 2756608, 2846720, 2961408, 2170880, 2998272, 2170880, 3010560, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3198976, 2215936, 0, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 143, 45, 45, 67, 67, 67, 67, 67, 227, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1824, 67, 1826, 67, 67, 67, 67, 17, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 32768, 120, 121, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 67, 67, 37139, 37139, 24853, 24853, 0, 0, 2179072, 548, 0, 65820, 65820, 0, 287, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 2033, 45, 67, 67, 67, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 978, 0, 546, 70179, 0, 2183168, 0, 0, 552, 0, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1013, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 473, 67, 67, 67, 67, 483, 67, 67, 1025, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1119, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1359, 97, 97, 97, 67, 67, 1584, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 497, 67, 67, 1659, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1667, 45, 45, 45, 45, 45, 169, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1668, 45, 45, 45, 45, 67, 67, 1694, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 774, 67, 67, 1713, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 1723, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 1538, 45, 45, 45, 45, 45, 1559, 45, 45, 1561, 45, 45, 45, 45, 45, 45, 45, 687, 45, 45, 45, 45, 45, 45, 45, 45, 448, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1771, 1772, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 67, 67, 67, 67, 67, 1821, 67, 67, 67, 67, 67, 67, 1827, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 1614, 97, 97, 97, 97, 97, 603, 97, 97, 605, 97, 97, 608, 97, 97, 97, 97, 0, 1532, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 450, 45, 45, 45, 45, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 1839, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 97, 1883, 97, 1885, 97, 0, 1888, 0, 97, 97, 0, 97, 97, 1848, 97, 97, 97, 97, 1852, 45, 45, 45, 45, 45, 45, 45, 384, 391, 45, 45, 45, 45, 45, 45, 45, 385, 45, 45, 45, 45, 45, 45, 45, 45, 1237, 45, 45, 45, 45, 45, 45, 67, 0, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 1951, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1963, 97, 2023, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 1994, 67, 1995, 67, 67, 67, 67, 67, 67, 97, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 0, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 137, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2793472, 2805760, 2170880, 2830336, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3031040, 2170880, 3055616, 2170880, 2170880, 67, 67, 37139, 37139, 24853, 24853, 0, 0, 281, 549, 0, 65820, 65820, 0, 287, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 2031, 2032, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1769, 67, 0, 546, 70179, 549, 549, 0, 0, 552, 0, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1858, 45, 641, 0, 0, 0, 0, 41606, 926, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 456, 67, 0, 0, 0, 1313, 0, 0, 0, 1096, 1319, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1110, 97, 97, 97, 97, 67, 67, 67, 67, 1301, 1476, 0, 0, 0, 0, 1307, 1478, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1486, 97, 1487, 97, 1313, 1480, 0, 0, 0, 0, 1319, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 566, 97, 97, 97, 97, 97, 97, 67, 67, 67, 1476, 0, 1478, 0, 1480, 0, 97, 97, 97, 97, 97, 97, 97, 45, 1853, 45, 1855, 45, 45, 45, 45, 53264, 18, 49172, 57366, 26, 8192, 31, 102432, 0, 110630, 114730, 106539, 0, 0, 225368, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 32768, 53264, 18, 18, 49172, 163840, 57366, 0, 24, 24, 229376, 0, 28, 28, 28, 229376, 102432, 0, 0, 0, 0, 2220167, 110630, 0, 0, 0, 114730, 106539, 0, 2171019, 2171019, 2171019, 2171019, 2592907, 2171019, 2171019, 2171019, 2171019, 2633867, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2654347, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3117195, 2171019, 2171019, 2171019, 2171019, 2240641, 0, 0, 0, 0, 0, 0, 0, 0, 368, 0, 140, 2171019, 2171019, 2171019, 2416779, 2424971, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2617483, 2171019, 2171019, 2642059, 2171019, 2171019, 2171019, 2699403, 2171019, 2728075, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3215499, 2215936, 2215936, 2215936, 2215936, 2215936, 2437120, 2215936, 2215936, 2171019, 2822283, 2171019, 2171019, 2855051, 2171019, 2171019, 2171019, 2912395, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3002507, 2171019, 2171019, 2215936, 2215936, 2494464, 2215936, 2215936, 2215936, 2171166, 2171166, 2416926, 2425118, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2576670, 2171166, 2617630, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2691358, 2171166, 2707742, 2171166, 2715934, 2171166, 2724126, 2765086, 2171166, 2171166, 2797854, 2171166, 2822430, 2171166, 2171166, 2855198, 2171166, 2171166, 2171166, 2912542, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2793758, 2806046, 2171166, 2830622, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3109150, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2543902, 2171166, 2171166, 2171166, 2171166, 2171166, 2629918, 2793611, 2805899, 2171019, 2830475, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 0, 546, 0, 0, 2183168, 0, 0, 552, 0, 2171166, 2171166, 2171166, 2400542, 2171166, 2171166, 2171166, 0, 2171166, 2171166, 2171166, 0, 2171166, 2920734, 2171166, 2171166, 2171166, 2990366, 2171166, 2171166, 2171166, 2171166, 3117342, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 0, 53264, 0, 18, 18, 4329472, 2232445, 0, 2240641, 4337664, 2711691, 2171019, 2171019, 2171019, 2171019, 2171019, 2760843, 2769035, 2789515, 2814091, 2171019, 2171019, 2171019, 2875531, 2904203, 2171019, 2171019, 3092619, 2171019, 2171019, 3125387, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3199115, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2453504, 2457600, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2793472, 2805760, 2215936, 2830336, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2494464, 2170880, 2170880, 2171166, 2171166, 2634014, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2711838, 2171166, 2171166, 2171166, 2171166, 2171166, 2760990, 2769182, 2789662, 2814238, 2171166, 2171166, 2171166, 2875678, 2904350, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3199262, 2171166, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2379915, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2445451, 2171019, 2465931, 2474123, 2171019, 2171019, 3113099, 2171019, 2171019, 3133579, 2171019, 2171019, 2171019, 3162251, 2171019, 2171019, 3182731, 3186827, 2171019, 2379776, 2879627, 2171019, 2916491, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3027083, 2171019, 2171019, 3063947, 2699550, 2171166, 2728222, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2879774, 2171166, 2916638, 2171166, 2171166, 2171166, 2171166, 2171166, 2609438, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2654494, 2171166, 2171166, 2171166, 2171166, 2171166, 2445598, 2171166, 2466078, 2474270, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2523422, 2171019, 2437259, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2543755, 2171019, 2171019, 2171019, 2584715, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2908299, 2171019, 2171019, 2936971, 2171019, 2171019, 2986123, 2171019, 2994315, 2171019, 2171019, 3014795, 2171019, 3059851, 3076235, 3088523, 2171166, 2171166, 2986270, 2171166, 2994462, 2171166, 2171166, 3014942, 2171166, 3059998, 3076382, 3088670, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3027230, 2171166, 2171166, 3064094, 2171166, 2171166, 3113246, 2171166, 2171166, 3133726, 2506891, 2171019, 2171019, 2171019, 2535563, 2539659, 2171019, 2171019, 2588811, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2691211, 2171019, 2707595, 2171019, 2715787, 2171019, 2723979, 2764939, 2171019, 2171019, 2797707, 2215936, 2215936, 3170304, 0, 0, 0, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2453790, 2457886, 2171166, 2171166, 2171166, 2486558, 2171166, 2171166, 2507038, 2171166, 2171166, 2171166, 2535710, 2539806, 2171166, 2171166, 2588958, 2171166, 2171166, 2171166, 2171166, 2515230, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2593054, 2171166, 2171166, 2171166, 2171166, 3051806, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3170590, 0, 2388107, 2392203, 2171019, 2171019, 2433163, 2171019, 2461835, 2171019, 2171019, 2171019, 2510987, 2171019, 2171019, 2171019, 2171019, 2580619, 2171019, 2605195, 2637963, 2171019, 2171019, 2171019, 2920587, 2171019, 2171019, 2171019, 2990219, 2171019, 2171019, 2171019, 2171019, 3051659, 2171019, 2171019, 2171019, 2453643, 2457739, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2515083, 2171019, 2171019, 2171019, 2171019, 2646155, 2670731, 2752651, 2756747, 2846859, 2961547, 2171019, 2998411, 2171019, 3010699, 2171019, 2171019, 2687115, 2748555, 2171019, 2171019, 2171019, 2924683, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3121291, 2171019, 2171019, 2171019, 3170443, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2486272, 2215936, 2215936, 2506752, 3145867, 3158155, 3166347, 2387968, 2392064, 2215936, 2215936, 2433024, 2215936, 2461696, 2215936, 2215936, 2215936, 2510848, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 553, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 3121152, 2215936, 2215936, 3145728, 3158016, 3166208, 2388254, 2392350, 2171166, 2171166, 2433310, 2171166, 2461982, 2171166, 2171166, 2171166, 2511134, 2171166, 2171166, 0, 2171166, 2171166, 2580766, 2171166, 2605342, 2638110, 2171166, 2171166, 2171166, 2171166, 3031326, 2171166, 3055902, 2171166, 2171166, 2171166, 2171166, 3092766, 2171166, 2171166, 3125534, 2171166, 2171166, 2171166, 3162398, 2171166, 2171166, 3182878, 3186974, 2171166, 0, 0, 0, 2171019, 2171019, 2171019, 2171019, 3109003, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2215936, 2215936, 2215936, 2400256, 2215936, 2215936, 2215936, 2215936, 2171166, 2687262, 0, 0, 2748702, 2171166, 2171166, 0, 2171166, 2924830, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2597150, 2171166, 2621726, 2171166, 2171166, 2642206, 2171166, 2171166, 2171166, 2171166, 3121438, 2171166, 2171166, 3146014, 3158302, 3166494, 2171019, 2420875, 2429067, 2171019, 2478219, 2171019, 2171019, 2171019, 2171019, 2547851, 2556043, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3129483, 2215936, 2171019, 3141771, 2215936, 2420736, 2428928, 2215936, 2478080, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2646016, 2670592, 2752512, 2756608, 2846720, 2961408, 2215936, 2998272, 2215936, 3010560, 2215936, 2215936, 2215936, 3141632, 2171166, 2421022, 2429214, 2171166, 2478366, 2171166, 2171166, 2171166, 2171166, 0, 0, 2171166, 2171166, 2171166, 2171166, 2646302, 2670878, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 0, 45, 45, 45, 45, 45, 1405, 1406, 45, 45, 45, 45, 1409, 45, 45, 45, 45, 45, 1415, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1238, 45, 45, 45, 45, 67, 2752798, 2756894, 0, 2847006, 2961694, 2171166, 2998558, 2171166, 3010846, 2171166, 2171166, 2171166, 3141918, 2171019, 2171019, 2490507, 3129344, 2171166, 2171166, 2490654, 2171166, 2171166, 2171166, 0, 0, 2547998, 2556190, 2171166, 2171166, 2171166, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 45, 167, 45, 45, 45, 45, 185, 187, 45, 45, 198, 45, 45, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3129630, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2576523, 2171019, 2171019, 2171019, 2171019, 2171019, 2609291, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3002368, 2215936, 2215936, 2171166, 2171166, 2494750, 2171166, 2171166, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 147, 2584576, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2171166, 2171166, 2171166, 2171166, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 0, 0, 0, 2171166, 2171166, 2171166, 3002654, 2171166, 2171166, 2171019, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2175257, 0, 0, 2584862, 2171166, 2171166, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171019, 2441355, 2171019, 2527371, 2171019, 2601099, 2171019, 2850955, 2171019, 2171019, 2171019, 3022987, 2215936, 2441216, 2215936, 2527232, 2215936, 2600960, 2215936, 2850816, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 69632, 287, 2170880, 2215936, 3022848, 2171166, 2441502, 2171166, 2527518, 0, 0, 2171166, 2601246, 2171166, 0, 2851102, 2171166, 2171166, 2171166, 2171166, 2720030, 2744606, 2171166, 2171166, 2171166, 2834718, 2838814, 2171166, 2908446, 2171166, 2171166, 2937118, 3023134, 2171019, 2519179, 2171019, 2171019, 2171019, 2171019, 2171019, 2215936, 2519040, 2215936, 2215936, 2215936, 2215936, 2215936, 2171166, 2171166, 2171166, 3215646, 0, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2486411, 2171019, 2171019, 2171019, 2629771, 2171019, 2171019, 2171019, 2171019, 2719883, 2744459, 2171019, 2171019, 2171019, 2834571, 2838667, 2171019, 2519326, 0, 0, 2171166, 2171166, 0, 2171166, 2171166, 2171166, 2396299, 2171019, 2171019, 2171019, 2171019, 3018891, 2396160, 2215936, 2215936, 2215936, 2215936, 3018752, 2396446, 0, 0, 2171166, 2171166, 2171166, 2171166, 3019038, 2171019, 2650251, 2965643, 2171019, 2215936, 2650112, 2965504, 2215936, 0, 0, 2171166, 2650398, 2965790, 2171166, 2551947, 2171019, 2551808, 2215936, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 144, 45, 45, 67, 67, 67, 67, 67, 228, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1929, 97, 97, 97, 97, 0, 0, 0, 2552094, 2171166, 2171019, 2215936, 0, 2171166, 2171019, 2215936, 0, 2171166, 2171019, 2215936, 0, 2171166, 2977931, 2977792, 2978078, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 1321, 97, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 140, 0, 2379776, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2445312, 2170880, 2465792, 2473984, 2170880, 2170880, 2170880, 2584576, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 3162112, 2170880, 2170880, 3182592, 3186688, 2170880, 0, 140, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3002368, 2170880, 2170880, 2215936, 2215936, 2494464, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3215360, 544, 0, 0, 0, 544, 0, 546, 0, 0, 0, 546, 0, 0, 2183168, 0, 0, 552, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 0, 2170880, 2170880, 2170880, 0, 2170880, 2920448, 2170880, 2170880, 2170880, 2990080, 2170880, 2170880, 552, 0, 0, 0, 552, 0, 287, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2437120, 2170880, 2170880, 18, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 644, 0, 2215936, 2215936, 3170304, 544, 0, 546, 0, 552, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 0, 140, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 249856, 110630, 114730, 106539, 0, 0, 32768, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 151640, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2416640, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 253952, 110630, 114730, 106539, 0, 0, 32856, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 192512, 53264, 18, 18, 49172, 0, 57366, 0, 2232445, 184320, 2232445, 0, 2240641, 2240641, 184320, 2240641, 102432, 0, 0, 0, 221184, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3108864, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 0, 0, 0, 45056, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 24, 0, 127, 127, 53264, 18, 49172, 258071, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 32768, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 204800, 53264, 18, 49172, 57366, 24, 27, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 28, 33, 0, 33, 33, 33, 0, 0, 0, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 16384, 28, 28, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139, 2170880, 2170880, 2170880, 2416640, 67, 67, 37139, 37139, 24853, 24853, 0, 70179, 0, 0, 0, 65820, 65820, 369, 287, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 2030, 45, 45, 45, 45, 67, 1573, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1699, 67, 67, 67, 67, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1355, 97, 97, 97, 1358, 97, 97, 97, 641, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 1187, 45, 45, 45, 45, 45, 0, 1480, 0, 0, 0, 0, 1319, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 592, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1531, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1680, 45, 45, 45, 641, 0, 924, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1186, 45, 45, 45, 45, 45, 45, 67, 67, 37139, 37139, 24853, 24853, 0, 70179, 282, 0, 0, 65820, 65820, 369, 287, 97, 0, 0, 97, 97, 0, 97, 2028, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1767, 67, 67, 67, 0, 0, 0, 0, 0, 0, 1612, 97, 97, 97, 97, 97, 97, 0, 1785, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1790, 97, 0, 0, 2170880, 2170880, 3051520, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3170304, 241664, 2387968, 2392064, 2170880, 2170880, 2433024, 53264, 19, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 274432, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 270336, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 1134711, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 1126440, 1126440, 1126440, 0, 0, 1126400, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 36, 110630, 114730, 106539, 0, 0, 217088, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 94, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 96, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 24666, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 126, 28, 28, 28, 28, 102432, 53264, 122, 123, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 2170880, 2170880, 4256099, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 0, 1319, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1109, 97, 97, 97, 97, 1113, 132, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 146, 150, 45, 45, 45, 45, 45, 175, 45, 180, 45, 186, 45, 189, 45, 45, 203, 67, 256, 67, 67, 270, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 97, 293, 297, 97, 97, 97, 97, 97, 322, 97, 327, 97, 333, 97, 0, 0, 97, 2026, 0, 2027, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1685, 67, 67, 67, 67, 67, 67, 67, 1690, 67, 336, 97, 97, 350, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 2424832, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2617344, 2170880, 45, 439, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 525, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 622, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1524, 97, 97, 1527, 369, 648, 45, 45, 45, 45, 45, 45, 45, 45, 45, 659, 45, 45, 45, 45, 408, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1239, 45, 45, 45, 67, 729, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 762, 67, 746, 67, 67, 67, 67, 67, 67, 67, 67, 67, 759, 67, 67, 67, 67, 0, 0, 0, 1477, 0, 1086, 0, 0, 0, 1479, 0, 1090, 67, 67, 796, 67, 67, 799, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1291, 67, 67, 67, 811, 67, 67, 67, 67, 67, 816, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 833, 97, 97, 97, 97, 97, 97, 97, 97, 1380, 0, 0, 0, 45, 45, 45, 45, 45, 1185, 45, 45, 45, 45, 45, 45, 45, 386, 45, 45, 45, 45, 45, 45, 45, 45, 1810, 45, 45, 45, 45, 45, 45, 67, 97, 97, 844, 97, 97, 97, 97, 97, 97, 97, 97, 97, 857, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 97, 97, 97, 894, 97, 97, 897, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 1382, 45, 45, 45, 97, 909, 97, 97, 97, 97, 97, 914, 97, 97, 97, 97, 97, 97, 97, 923, 67, 67, 1079, 67, 67, 67, 67, 67, 37689, 1085, 25403, 1089, 66365, 1093, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 148, 1114, 97, 97, 97, 97, 97, 97, 1122, 97, 97, 97, 97, 97, 97, 97, 97, 97, 606, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1173, 97, 97, 97, 97, 97, 12288, 0, 925, 0, 1179, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 145, 45, 45, 67, 67, 67, 67, 67, 1762, 67, 67, 67, 1766, 67, 67, 67, 67, 67, 67, 528, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 1934, 67, 67, 1255, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1035, 67, 67, 67, 67, 67, 67, 1297, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1111, 97, 97, 97, 97, 97, 97, 1327, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 33344, 97, 97, 97, 1335, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 1377, 97, 97, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 670, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 430, 45, 45, 45, 45, 67, 67, 1438, 67, 67, 1442, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1592, 67, 67, 67, 1451, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1458, 67, 67, 67, 67, 0, 0, 1305, 0, 0, 0, 0, 0, 1311, 0, 0, 0, 1317, 0, 0, 0, 0, 0, 0, 0, 97, 97, 1322, 97, 97, 1491, 97, 97, 1495, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1551, 45, 1553, 45, 1504, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1513, 97, 97, 97, 97, 0, 45, 45, 45, 45, 1536, 45, 45, 45, 45, 1540, 45, 67, 67, 67, 67, 67, 1585, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1700, 67, 67, 67, 97, 1648, 97, 97, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1541, 0, 97, 97, 97, 97, 0, 1940, 0, 97, 97, 97, 97, 97, 97, 45, 45, 2011, 45, 45, 45, 2015, 67, 67, 2017, 67, 67, 67, 2021, 97, 67, 67, 812, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 97, 97, 97, 910, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 923, 0, 0, 0, 45, 45, 45, 45, 1184, 45, 45, 45, 45, 1188, 45, 45, 45, 45, 1414, 45, 45, 45, 1417, 45, 1419, 45, 45, 45, 45, 45, 443, 45, 45, 45, 45, 45, 45, 453, 45, 45, 67, 67, 67, 67, 1244, 67, 67, 67, 67, 1248, 67, 67, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 282, 41098, 65820, 97, 1324, 97, 97, 97, 97, 1328, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 930, 45, 45, 45, 45, 97, 97, 97, 97, 1378, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 975, 45, 45, 45, 45, 67, 67, 1923, 67, 1925, 67, 67, 1927, 67, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1985, 45, 45, 45, 45, 45, 45, 1560, 45, 45, 45, 45, 45, 45, 45, 45, 45, 946, 45, 45, 950, 45, 45, 45, 0, 97, 97, 97, 1939, 0, 0, 0, 97, 1943, 97, 97, 1945, 97, 45, 45, 45, 669, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 990, 45, 45, 45, 67, 257, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 337, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 370, 2170880, 2170880, 2170880, 2416640, 401, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 459, 461, 67, 67, 67, 67, 67, 67, 67, 67, 475, 67, 480, 67, 67, 67, 67, 67, 67, 1054, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1698, 67, 67, 67, 67, 67, 484, 67, 67, 487, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1459, 67, 67, 97, 556, 558, 97, 97, 97, 97, 97, 97, 97, 97, 572, 97, 577, 97, 97, 0, 0, 1896, 97, 97, 97, 97, 97, 97, 1903, 45, 45, 45, 45, 983, 45, 45, 45, 45, 988, 45, 45, 45, 45, 45, 45, 1195, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1549, 45, 45, 45, 45, 45, 581, 97, 97, 584, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1153, 97, 97, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 662, 45, 45, 45, 684, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1004, 45, 45, 45, 67, 67, 67, 749, 67, 67, 67, 67, 67, 67, 67, 67, 67, 761, 67, 67, 67, 67, 67, 67, 1068, 67, 67, 67, 1071, 67, 67, 67, 67, 1076, 794, 795, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 544, 97, 97, 97, 97, 847, 97, 97, 97, 97, 97, 97, 97, 97, 97, 859, 97, 0, 0, 2025, 97, 20480, 97, 97, 2029, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1575, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1775, 67, 67, 67, 97, 97, 97, 97, 892, 893, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1515, 97, 993, 994, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 992, 67, 67, 67, 1284, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1607, 67, 67, 97, 1364, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 596, 97, 45, 1556, 1557, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 696, 45, 1596, 1597, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 499, 67, 97, 97, 97, 1621, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1346, 97, 97, 97, 97, 1740, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1678, 45, 45, 45, 45, 45, 67, 97, 97, 97, 97, 97, 97, 1836, 0, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1984, 97, 45, 45, 45, 45, 45, 45, 1808, 45, 45, 45, 45, 45, 45, 45, 45, 67, 739, 67, 67, 67, 67, 67, 744, 45, 45, 1909, 45, 45, 45, 45, 45, 45, 45, 67, 1917, 67, 1918, 67, 67, 67, 67, 67, 67, 1247, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 532, 67, 67, 67, 67, 67, 67, 1922, 67, 67, 67, 67, 67, 67, 67, 97, 1930, 97, 1931, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1576, 67, 67, 67, 67, 1580, 67, 67, 0, 97, 97, 1938, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 699, 45, 45, 45, 704, 45, 45, 45, 45, 45, 45, 45, 45, 987, 45, 45, 45, 45, 45, 45, 45, 67, 67, 97, 97, 97, 97, 0, 0, 97, 97, 97, 2006, 97, 97, 97, 97, 0, 45, 1533, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1416, 45, 45, 45, 45, 45, 45, 45, 45, 722, 723, 45, 45, 45, 45, 45, 45, 2045, 67, 67, 67, 2047, 0, 0, 97, 97, 97, 2051, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 409, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1957, 45, 67, 67, 67, 67, 67, 1836, 97, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 45, 67, 67, 67, 1761, 67, 67, 67, 1764, 67, 67, 67, 67, 67, 67, 67, 494, 67, 67, 67, 67, 67, 67, 67, 67, 67, 787, 67, 67, 67, 67, 67, 67, 45, 45, 420, 45, 45, 422, 45, 45, 425, 45, 45, 45, 45, 45, 45, 45, 387, 45, 45, 45, 45, 397, 45, 45, 45, 67, 460, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 515, 67, 485, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 498, 67, 67, 67, 67, 67, 97, 0, 2039, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1426, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1689, 67, 67, 67, 97, 557, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 612, 97, 582, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 595, 97, 97, 97, 97, 97, 896, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 885, 97, 97, 97, 97, 97, 45, 939, 45, 45, 45, 45, 943, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1916, 67, 67, 67, 67, 67, 45, 67, 67, 67, 67, 67, 67, 67, 1015, 67, 67, 67, 67, 1019, 67, 67, 67, 67, 67, 67, 1271, 67, 67, 67, 67, 67, 67, 1277, 67, 67, 67, 67, 67, 67, 1287, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 804, 67, 67, 67, 67, 67, 1077, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2437120, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2543616, 2170880, 2170880, 2170880, 2170880, 2170880, 2629632, 1169, 97, 1171, 97, 97, 97, 97, 97, 97, 97, 12288, 0, 925, 0, 1179, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 936, 45, 45, 67, 67, 214, 67, 220, 67, 67, 233, 67, 243, 67, 248, 67, 67, 67, 67, 67, 67, 1298, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 1617, 97, 0, 0, 0, 45, 45, 45, 1183, 45, 45, 45, 45, 45, 45, 45, 45, 45, 393, 45, 45, 45, 45, 45, 45, 67, 67, 1243, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1074, 67, 67, 1281, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 776, 1323, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 907, 45, 1412, 45, 45, 45, 45, 45, 45, 45, 1418, 45, 45, 45, 45, 45, 45, 686, 45, 45, 45, 690, 45, 45, 695, 45, 45, 67, 67, 67, 67, 67, 1465, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1712, 97, 97, 97, 97, 1741, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 426, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1924, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1983, 97, 97, 45, 45, 1987, 45, 1988, 45, 0, 97, 97, 97, 97, 0, 0, 0, 1942, 97, 97, 97, 97, 97, 45, 45, 45, 700, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 711, 45, 45, 153, 45, 45, 166, 45, 176, 45, 181, 45, 45, 188, 191, 196, 45, 204, 255, 258, 263, 67, 271, 67, 67, 0, 37139, 24853, 0, 0, 0, 282, 41098, 65820, 97, 97, 97, 294, 97, 300, 97, 97, 313, 97, 323, 97, 328, 97, 97, 335, 338, 343, 97, 351, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 41098, 0, 140, 45, 45, 45, 45, 1404, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1411, 67, 67, 486, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1251, 67, 67, 501, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 513, 67, 67, 67, 67, 67, 67, 1443, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1263, 67, 67, 67, 67, 67, 97, 97, 583, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1526, 97, 598, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 610, 97, 97, 0, 97, 97, 1796, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1744, 45, 45, 45, 369, 0, 651, 45, 653, 45, 654, 45, 656, 45, 45, 45, 660, 45, 45, 45, 45, 1558, 45, 45, 45, 45, 45, 45, 45, 45, 1566, 45, 45, 681, 45, 683, 45, 45, 45, 45, 45, 45, 45, 45, 691, 692, 694, 45, 45, 45, 716, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 709, 45, 45, 712, 45, 714, 45, 45, 45, 718, 45, 45, 45, 45, 45, 45, 45, 726, 45, 45, 45, 733, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1691, 67, 67, 747, 67, 67, 67, 67, 67, 67, 67, 67, 67, 760, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 1613, 97, 97, 97, 97, 97, 97, 1509, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 67, 764, 67, 67, 67, 67, 768, 67, 770, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 1977, 67, 778, 779, 781, 67, 67, 67, 67, 67, 67, 788, 789, 67, 67, 792, 793, 67, 67, 67, 813, 67, 67, 67, 67, 67, 67, 67, 67, 67, 824, 37689, 544, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 836, 97, 838, 97, 839, 97, 841, 97, 97, 97, 845, 97, 97, 97, 97, 97, 97, 97, 97, 97, 858, 97, 97, 0, 1728, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 1802, 45, 97, 97, 862, 97, 97, 97, 97, 866, 97, 868, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1788, 97, 97, 97, 0, 0, 97, 97, 876, 877, 879, 97, 97, 97, 97, 97, 97, 886, 887, 97, 97, 890, 891, 97, 97, 97, 97, 97, 97, 97, 899, 97, 97, 97, 903, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 1646, 97, 97, 97, 97, 911, 97, 97, 97, 97, 97, 97, 97, 97, 97, 922, 923, 45, 955, 45, 957, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 195, 45, 45, 45, 45, 45, 981, 982, 45, 45, 45, 45, 45, 45, 989, 45, 45, 45, 45, 45, 170, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 411, 45, 45, 45, 45, 45, 67, 1023, 67, 67, 67, 67, 67, 67, 1031, 67, 1033, 67, 67, 67, 67, 67, 67, 67, 817, 819, 67, 67, 67, 67, 67, 37689, 544, 67, 1065, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 516, 67, 67, 1078, 67, 67, 1081, 1082, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 0, 0, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2437406, 2171166, 2171166, 97, 1115, 97, 1117, 97, 97, 97, 97, 97, 97, 1125, 97, 1127, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 1644, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 1642, 97, 97, 97, 97, 97, 97, 625, 97, 97, 97, 97, 97, 97, 97, 97, 97, 316, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1159, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1502, 97, 97, 97, 97, 97, 1172, 97, 97, 1175, 1176, 97, 97, 12288, 0, 925, 0, 1179, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 935, 45, 45, 45, 1233, 45, 45, 45, 1236, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1873, 67, 67, 45, 45, 1218, 45, 45, 45, 1223, 45, 45, 45, 45, 45, 45, 45, 1230, 45, 45, 67, 67, 215, 219, 222, 67, 230, 67, 67, 244, 246, 249, 67, 67, 67, 67, 67, 67, 1882, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 1904, 45, 1905, 45, 67, 67, 67, 67, 67, 1258, 67, 1260, 67, 67, 67, 67, 67, 67, 67, 67, 67, 495, 67, 67, 67, 67, 67, 67, 67, 67, 1283, 67, 67, 67, 67, 67, 67, 67, 1290, 67, 67, 67, 67, 67, 67, 67, 818, 67, 67, 67, 67, 67, 67, 37689, 544, 67, 67, 1295, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 2174976, 0, 0, 97, 97, 97, 1326, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1514, 97, 97, 97, 97, 97, 1338, 97, 1340, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1500, 97, 97, 1503, 97, 1363, 97, 97, 97, 97, 97, 97, 97, 1370, 97, 97, 97, 97, 97, 97, 97, 563, 97, 97, 97, 97, 97, 97, 578, 97, 1375, 97, 97, 97, 97, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 685, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1003, 45, 45, 45, 45, 67, 67, 67, 1463, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1778, 97, 97, 97, 97, 97, 1518, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 609, 97, 97, 97, 45, 1542, 45, 45, 45, 45, 45, 45, 45, 1548, 45, 45, 45, 45, 45, 1554, 45, 1570, 1571, 45, 67, 67, 67, 67, 67, 67, 1578, 67, 67, 67, 67, 67, 67, 67, 1055, 67, 67, 67, 67, 67, 1061, 67, 67, 1582, 67, 67, 67, 67, 67, 67, 67, 1588, 67, 67, 67, 67, 67, 1594, 67, 67, 67, 67, 67, 97, 2038, 0, 97, 97, 97, 97, 97, 2044, 45, 45, 45, 995, 45, 45, 45, 45, 1000, 45, 45, 45, 45, 45, 45, 45, 1809, 45, 1811, 45, 45, 45, 45, 45, 67, 1610, 1611, 67, 1476, 0, 1478, 0, 1480, 0, 97, 97, 97, 97, 97, 97, 1618, 1647, 1649, 97, 97, 97, 1652, 97, 1654, 1655, 97, 0, 45, 45, 45, 1658, 45, 45, 67, 67, 216, 67, 67, 67, 67, 234, 67, 67, 67, 67, 252, 254, 1845, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 945, 45, 947, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1881, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 1902, 45, 45, 45, 45, 45, 45, 1908, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1921, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 0, 97, 1937, 97, 97, 1940, 0, 0, 97, 97, 97, 97, 97, 97, 1947, 1948, 1949, 45, 45, 45, 1952, 45, 1954, 45, 45, 45, 45, 1959, 1960, 1961, 67, 67, 67, 67, 67, 67, 1455, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 757, 67, 67, 67, 67, 67, 67, 1964, 67, 1966, 67, 67, 67, 67, 1971, 1972, 1973, 97, 0, 0, 0, 97, 97, 1104, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 884, 97, 97, 97, 889, 97, 97, 1978, 97, 0, 0, 1981, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 736, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1018, 67, 67, 67, 45, 67, 67, 67, 67, 0, 2049, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 933, 45, 45, 45, 45, 1234, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 97, 97, 288, 97, 97, 97, 97, 97, 97, 317, 97, 97, 97, 97, 97, 97, 0, 0, 97, 1787, 97, 97, 97, 97, 0, 0, 45, 45, 378, 45, 45, 45, 45, 45, 390, 45, 45, 45, 45, 45, 45, 45, 424, 45, 45, 45, 431, 433, 45, 45, 45, 67, 1050, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 518, 67, 97, 97, 97, 1144, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 632, 97, 97, 97, 97, 97, 97, 97, 1367, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 855, 97, 97, 97, 97, 67, 97, 97, 97, 97, 97, 97, 1837, 0, 97, 97, 97, 97, 97, 0, 0, 0, 1897, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1208, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 724, 45, 45, 45, 45, 45, 97, 2010, 45, 45, 45, 45, 45, 45, 2016, 67, 67, 67, 67, 67, 67, 2022, 45, 2046, 67, 67, 67, 0, 0, 2050, 97, 97, 97, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 932, 45, 45, 45, 45, 45, 1222, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1227, 45, 45, 45, 45, 45, 133, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 45, 701, 702, 45, 45, 705, 706, 45, 45, 45, 45, 45, 45, 703, 45, 45, 45, 45, 45, 45, 45, 45, 45, 719, 45, 45, 45, 45, 45, 725, 45, 45, 45, 369, 649, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1216, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 834, 97, 97, 97, 97, 97, 97, 97, 1342, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 1799, 97, 97, 45, 45, 45, 1569, 45, 45, 45, 1572, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 1306, 0, 67, 67, 67, 1598, 67, 67, 67, 67, 67, 67, 67, 67, 1606, 67, 67, 1609, 97, 97, 97, 1650, 97, 97, 1653, 97, 97, 97, 0, 45, 45, 1657, 45, 45, 45, 1206, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1421, 45, 45, 45, 1703, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 1711, 97, 97, 0, 1895, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 958, 45, 960, 45, 45, 45, 45, 45, 45, 45, 45, 1913, 45, 45, 1915, 67, 67, 67, 67, 67, 67, 67, 466, 67, 67, 67, 67, 67, 67, 481, 67, 45, 1749, 45, 45, 45, 45, 45, 45, 45, 45, 1755, 45, 45, 45, 45, 45, 173, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 974, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1773, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1886, 0, 0, 0, 97, 97, 67, 2035, 2036, 67, 67, 97, 0, 0, 97, 2041, 2042, 97, 97, 45, 45, 45, 45, 1662, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1397, 45, 45, 45, 45, 151, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 437, 205, 45, 67, 67, 67, 218, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1047, 67, 67, 67, 67, 97, 97, 97, 97, 298, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 870, 97, 97, 97, 97, 97, 97, 97, 97, 352, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 0, 0, 0, 0, 0, 365, 0, 41098, 0, 140, 45, 45, 45, 45, 45, 1427, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1435, 520, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1037, 617, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 923, 45, 1232, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1919, 67, 1759, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1021, 45, 154, 45, 162, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 964, 45, 45, 45, 206, 45, 67, 67, 67, 67, 221, 67, 229, 67, 67, 67, 67, 67, 67, 67, 67, 530, 67, 67, 67, 67, 67, 67, 67, 67, 755, 67, 67, 67, 67, 67, 67, 67, 67, 785, 67, 67, 67, 67, 67, 67, 67, 67, 802, 67, 67, 67, 807, 67, 67, 67, 97, 97, 97, 97, 353, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 0, 0, 0, 0, 0, 366, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 402, 45, 45, 45, 45, 45, 45, 45, 410, 45, 45, 45, 45, 45, 45, 45, 674, 45, 45, 45, 45, 45, 45, 45, 45, 389, 45, 394, 45, 45, 398, 45, 45, 45, 45, 441, 45, 45, 45, 45, 45, 447, 45, 45, 45, 454, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1768, 67, 67, 67, 67, 67, 488, 67, 67, 67, 67, 67, 67, 67, 496, 67, 67, 67, 67, 67, 67, 67, 1774, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 67, 67, 523, 67, 67, 527, 67, 67, 67, 67, 67, 533, 67, 67, 67, 540, 97, 97, 97, 585, 97, 97, 97, 97, 97, 97, 97, 593, 97, 97, 97, 97, 97, 97, 1784, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 0, 18, 18, 24, 24, 0, 28, 28, 97, 97, 620, 97, 97, 624, 97, 97, 97, 97, 97, 630, 97, 97, 97, 637, 713, 45, 45, 45, 45, 45, 45, 721, 45, 45, 45, 45, 45, 45, 45, 45, 1197, 45, 45, 45, 45, 45, 45, 45, 45, 730, 732, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1581, 67, 45, 67, 67, 67, 67, 1012, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1059, 67, 67, 67, 67, 67, 1024, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 775, 67, 67, 67, 67, 1066, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 479, 67, 67, 67, 67, 67, 67, 1080, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 0, 0, 0, 0, 287, 0, 0, 0, 287, 0, 2379776, 2170880, 2170880, 97, 97, 97, 1118, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 920, 97, 97, 0, 0, 0, 0, 45, 1181, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 432, 45, 45, 45, 45, 45, 45, 1219, 45, 45, 45, 45, 45, 45, 1226, 45, 45, 45, 45, 45, 45, 959, 45, 45, 45, 45, 45, 45, 45, 45, 45, 184, 45, 45, 45, 45, 202, 45, 1241, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1266, 67, 1268, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1279, 67, 67, 67, 67, 67, 272, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 67, 67, 67, 1286, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1293, 67, 67, 67, 1296, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 281, 94, 0, 0, 97, 97, 97, 1366, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1373, 97, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 0, 97, 1376, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 1384, 45, 45, 67, 208, 67, 67, 67, 67, 67, 67, 237, 67, 67, 67, 67, 67, 67, 67, 1069, 1070, 67, 67, 67, 67, 67, 67, 67, 0, 37140, 24854, 0, 0, 0, 0, 41098, 65821, 45, 1423, 45, 45, 45, 45, 45, 45, 67, 67, 1431, 67, 67, 67, 67, 67, 67, 67, 1083, 37689, 0, 25403, 0, 66365, 0, 0, 0, 1436, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1830, 67, 1452, 1453, 67, 67, 67, 67, 1456, 67, 67, 67, 67, 67, 67, 67, 67, 67, 771, 67, 67, 67, 67, 67, 67, 1461, 67, 67, 67, 1464, 67, 1466, 67, 67, 67, 67, 67, 67, 1470, 67, 67, 67, 67, 67, 67, 1587, 67, 67, 67, 67, 67, 67, 67, 67, 1595, 1489, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1129, 97, 1505, 1506, 97, 97, 97, 97, 1510, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1163, 1164, 97, 97, 97, 97, 97, 1516, 97, 97, 97, 1519, 97, 1521, 97, 97, 97, 97, 97, 97, 1525, 97, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 67, 67, 67, 67, 67, 1586, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1276, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1600, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1301, 0, 0, 0, 1307, 97, 97, 1620, 97, 97, 97, 97, 97, 97, 97, 1627, 97, 97, 97, 97, 97, 97, 913, 97, 97, 97, 97, 919, 97, 97, 97, 0, 97, 97, 97, 1781, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 1792, 1860, 45, 1862, 1863, 45, 1865, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1875, 67, 1877, 1878, 67, 1880, 67, 97, 97, 97, 97, 97, 1887, 0, 1889, 97, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 237568, 0, 367, 0, 97, 1893, 0, 0, 0, 97, 1898, 1899, 97, 1901, 97, 45, 45, 45, 45, 45, 2014, 45, 67, 67, 67, 67, 67, 2020, 67, 97, 1989, 45, 1990, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1996, 67, 1997, 67, 67, 67, 67, 67, 273, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 97, 97, 97, 97, 0, 0, 97, 97, 2005, 0, 97, 2007, 97, 97, 18, 0, 139621, 0, 0, 0, 642, 0, 133, 364, 0, 0, 367, 41606, 0, 97, 97, 2056, 2057, 0, 2059, 45, 67, 0, 97, 45, 67, 0, 97, 45, 45, 67, 209, 67, 67, 67, 223, 67, 67, 67, 67, 67, 67, 67, 67, 67, 786, 67, 67, 67, 791, 67, 67, 45, 45, 940, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 727, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1016, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 133, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 142, 45, 45, 67, 210, 67, 67, 67, 225, 67, 67, 239, 67, 67, 67, 250, 67, 67, 67, 67, 67, 464, 67, 67, 67, 67, 67, 476, 67, 67, 67, 67, 67, 67, 67, 1709, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 1843, 0, 67, 259, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 289, 97, 97, 97, 303, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 901, 97, 97, 97, 97, 97, 339, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 358, 0, 0, 0, 0, 0, 0, 41098, 0, 140, 45, 45, 45, 45, 45, 1953, 45, 1955, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1687, 1688, 67, 67, 67, 67, 45, 45, 405, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1203, 45, 458, 67, 67, 67, 67, 67, 67, 67, 67, 67, 470, 477, 67, 67, 67, 67, 67, 67, 67, 1970, 97, 97, 97, 1974, 0, 0, 0, 97, 1103, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1372, 97, 97, 97, 97, 67, 522, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 536, 67, 67, 67, 67, 67, 67, 1696, 67, 67, 67, 67, 67, 67, 67, 1701, 67, 555, 97, 97, 97, 97, 97, 97, 97, 97, 97, 567, 574, 97, 97, 97, 97, 97, 301, 97, 309, 97, 97, 97, 97, 97, 97, 97, 97, 97, 900, 97, 97, 97, 905, 97, 97, 97, 619, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 633, 97, 97, 18, 0, 139621, 0, 0, 362, 0, 0, 0, 364, 0, 0, 367, 41606, 369, 649, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 663, 664, 67, 67, 67, 67, 750, 751, 67, 67, 67, 67, 758, 67, 67, 67, 67, 67, 67, 67, 1272, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1057, 1058, 67, 67, 67, 67, 67, 67, 67, 67, 797, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 512, 67, 67, 67, 97, 97, 97, 97, 895, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 902, 97, 97, 97, 97, 67, 67, 1051, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1062, 67, 67, 67, 67, 67, 491, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1302, 0, 0, 0, 1308, 97, 97, 97, 97, 1145, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1139, 97, 97, 97, 97, 1156, 97, 97, 97, 97, 97, 97, 1161, 97, 97, 97, 97, 97, 1166, 97, 97, 18, 640, 139621, 0, 641, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 67, 67, 67, 67, 1257, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 1305, 0, 0, 97, 97, 1337, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1630, 97, 67, 1474, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2380062, 2171166, 2171166, 97, 1529, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1228, 45, 45, 45, 45, 67, 67, 67, 67, 1707, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 1891, 1739, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1198, 45, 1200, 45, 45, 45, 45, 97, 97, 1894, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 672, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1420, 45, 45, 45, 45, 67, 67, 1965, 67, 1967, 67, 67, 67, 97, 97, 97, 97, 0, 1976, 0, 97, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 97, 97, 1979, 0, 0, 97, 1982, 97, 97, 97, 1986, 45, 45, 45, 45, 45, 735, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1770, 67, 67, 2000, 97, 97, 97, 2002, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1798, 97, 97, 97, 45, 45, 45, 2034, 67, 67, 67, 67, 97, 0, 0, 2040, 97, 97, 97, 97, 45, 45, 45, 45, 1752, 45, 45, 45, 1753, 1754, 45, 45, 45, 45, 45, 45, 383, 45, 45, 45, 45, 45, 45, 45, 45, 45, 675, 45, 45, 45, 45, 45, 45, 438, 45, 45, 45, 45, 45, 445, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1430, 67, 67, 67, 67, 67, 67, 67, 67, 67, 524, 67, 67, 67, 67, 67, 531, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 1096, 97, 97, 97, 621, 97, 97, 97, 97, 97, 628, 97, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 665, 45, 45, 45, 45, 45, 45, 45, 45, 45, 676, 45, 45, 45, 45, 45, 942, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 707, 708, 45, 45, 45, 45, 763, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 809, 810, 67, 67, 67, 67, 783, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 1303, 0, 0, 0, 97, 861, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 613, 97, 45, 45, 956, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1215, 45, 67, 67, 67, 67, 1027, 67, 67, 67, 67, 1032, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 1097, 1064, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1075, 67, 1098, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 331, 97, 97, 97, 97, 1158, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 594, 97, 97, 1309, 0, 0, 0, 1315, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1374, 97, 45, 45, 1543, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1240, 67, 67, 1583, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1252, 67, 97, 97, 97, 1635, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1800, 97, 45, 45, 45, 97, 97, 1793, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1743, 45, 45, 45, 1746, 45, 0, 97, 97, 97, 97, 97, 1851, 97, 45, 45, 45, 45, 1856, 45, 45, 45, 45, 1864, 45, 45, 67, 67, 1869, 67, 67, 67, 67, 1874, 67, 0, 97, 97, 45, 67, 2058, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 45, 67, 211, 67, 67, 67, 67, 67, 67, 240, 67, 67, 67, 67, 67, 67, 67, 1444, 67, 67, 67, 67, 67, 67, 67, 67, 67, 509, 67, 67, 67, 67, 67, 67, 67, 67, 67, 268, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 290, 97, 97, 97, 305, 97, 97, 319, 97, 97, 97, 330, 97, 97, 18, 640, 139621, 0, 641, 0, 0, 0, 0, 364, 0, 643, 367, 41606, 97, 97, 348, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 380, 45, 45, 45, 45, 45, 45, 395, 45, 45, 45, 400, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 658, 45, 45, 45, 45, 45, 972, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 427, 45, 45, 45, 45, 45, 745, 67, 67, 67, 67, 67, 67, 67, 67, 756, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 1086, 25403, 1090, 66365, 1094, 0, 0, 97, 843, 97, 97, 97, 97, 97, 97, 97, 97, 854, 97, 97, 97, 97, 97, 97, 1121, 97, 97, 97, 97, 1126, 97, 97, 97, 97, 45, 980, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1400, 45, 67, 67, 67, 1011, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 1304, 0, 0, 0, 1190, 45, 45, 1193, 1194, 45, 45, 45, 45, 45, 1199, 45, 1201, 45, 45, 45, 45, 1911, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1579, 67, 67, 67, 67, 45, 1205, 45, 45, 45, 45, 45, 45, 45, 45, 1211, 45, 45, 45, 45, 45, 984, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1550, 45, 45, 45, 45, 45, 1217, 45, 45, 45, 45, 45, 45, 1225, 45, 45, 45, 45, 1229, 45, 45, 45, 1388, 45, 45, 45, 45, 45, 45, 1396, 45, 45, 45, 45, 45, 444, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1574, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1590, 67, 67, 67, 67, 67, 1254, 67, 67, 67, 67, 67, 1259, 67, 1261, 67, 67, 67, 67, 1265, 67, 67, 67, 67, 67, 67, 1708, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 67, 67, 67, 67, 1285, 67, 67, 67, 67, 1289, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 1087, 25403, 1091, 66365, 1095, 0, 0, 97, 97, 97, 97, 1339, 97, 1341, 97, 97, 97, 97, 1345, 97, 97, 97, 97, 97, 561, 97, 97, 97, 97, 97, 573, 97, 97, 97, 97, 97, 97, 1717, 97, 0, 97, 97, 97, 97, 97, 97, 97, 591, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1329, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1351, 97, 97, 97, 97, 97, 97, 1357, 97, 97, 97, 97, 97, 588, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 568, 97, 97, 97, 97, 97, 97, 97, 1365, 97, 97, 97, 97, 1369, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1356, 97, 97, 97, 97, 97, 97, 45, 45, 1403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1399, 45, 45, 45, 1413, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1669, 45, 1422, 45, 45, 1425, 45, 45, 1428, 45, 1429, 67, 67, 67, 67, 67, 67, 67, 67, 1468, 67, 67, 67, 67, 67, 67, 67, 67, 529, 67, 67, 67, 67, 67, 67, 539, 67, 67, 1475, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 97, 97, 1530, 97, 0, 45, 45, 1534, 45, 45, 45, 45, 45, 45, 45, 45, 1956, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1599, 67, 67, 1601, 67, 67, 67, 67, 67, 67, 67, 67, 67, 803, 67, 67, 67, 67, 67, 67, 1632, 97, 1634, 0, 97, 97, 97, 1640, 97, 97, 97, 1643, 97, 97, 1645, 97, 97, 97, 97, 97, 912, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1660, 1661, 45, 45, 45, 45, 1665, 1666, 45, 45, 45, 45, 45, 1670, 1692, 1693, 67, 67, 67, 67, 67, 1697, 67, 67, 67, 67, 67, 67, 67, 1702, 97, 97, 1714, 1715, 97, 97, 97, 97, 0, 1721, 1722, 97, 97, 97, 97, 97, 97, 1353, 97, 97, 97, 97, 97, 97, 97, 97, 1362, 1726, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 1734, 97, 97, 97, 97, 97, 848, 849, 97, 97, 97, 97, 856, 97, 97, 97, 97, 97, 354, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 45, 45, 1750, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1681, 45, 0, 1846, 97, 97, 97, 97, 97, 97, 45, 45, 1854, 45, 45, 45, 45, 1859, 67, 67, 67, 1879, 67, 67, 97, 97, 1884, 97, 97, 0, 0, 0, 97, 97, 97, 1105, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1344, 97, 97, 97, 1347, 97, 1892, 97, 0, 0, 0, 97, 97, 97, 1900, 97, 97, 45, 45, 45, 45, 45, 997, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1002, 45, 45, 1005, 1006, 45, 67, 67, 67, 67, 67, 1926, 67, 67, 1928, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1737, 97, 0, 97, 97, 97, 97, 0, 0, 0, 97, 97, 1944, 97, 97, 1946, 45, 45, 45, 1544, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 190, 45, 45, 45, 152, 155, 45, 163, 45, 45, 177, 179, 182, 45, 45, 45, 193, 197, 45, 45, 45, 1672, 45, 45, 45, 45, 45, 1677, 45, 1679, 45, 45, 45, 45, 996, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1212, 45, 45, 45, 45, 67, 260, 264, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 97, 295, 299, 302, 97, 310, 97, 97, 324, 326, 329, 97, 97, 97, 0, 97, 97, 1639, 0, 1641, 97, 97, 97, 97, 97, 97, 97, 97, 1511, 97, 97, 97, 97, 97, 97, 97, 97, 1523, 97, 97, 97, 97, 97, 97, 97, 97, 1719, 97, 97, 97, 97, 97, 97, 97, 97, 1720, 97, 97, 97, 97, 97, 97, 97, 312, 97, 97, 97, 97, 97, 97, 97, 97, 1123, 97, 97, 97, 97, 97, 97, 97, 340, 344, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 373, 375, 419, 45, 45, 45, 45, 45, 45, 45, 45, 45, 428, 45, 45, 435, 45, 45, 45, 1751, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1410, 45, 45, 45, 67, 67, 67, 505, 67, 67, 67, 67, 67, 67, 67, 67, 67, 514, 67, 67, 67, 67, 67, 67, 1969, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 45, 67, 0, 97, 45, 67, 0, 97, 2064, 2065, 0, 2066, 45, 521, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 534, 67, 67, 67, 67, 67, 67, 465, 67, 67, 67, 474, 67, 67, 67, 67, 67, 67, 67, 1467, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 1933, 0, 97, 97, 97, 602, 97, 97, 97, 97, 97, 97, 97, 97, 97, 611, 97, 97, 18, 640, 139621, 358, 641, 0, 0, 0, 0, 364, 0, 0, 367, 0, 618, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 631, 97, 97, 97, 97, 97, 881, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 569, 97, 97, 97, 97, 97, 369, 0, 45, 652, 45, 45, 45, 45, 45, 657, 45, 45, 45, 45, 45, 45, 1235, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1432, 67, 67, 67, 67, 67, 67, 67, 766, 67, 67, 67, 67, 67, 67, 67, 67, 773, 67, 67, 67, 0, 1305, 0, 1311, 0, 1317, 97, 97, 97, 97, 97, 97, 97, 1624, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 1724, 97, 97, 97, 777, 67, 67, 782, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 535, 67, 67, 67, 67, 67, 67, 67, 814, 67, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 97, 837, 97, 97, 97, 97, 97, 97, 1496, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 918, 97, 97, 97, 97, 0, 842, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1168, 97, 97, 97, 97, 864, 97, 97, 97, 97, 97, 97, 97, 97, 871, 97, 97, 97, 0, 1637, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1801, 45, 45, 97, 875, 97, 97, 880, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1151, 1152, 97, 97, 97, 67, 67, 67, 1040, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 790, 67, 67, 67, 1180, 0, 649, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 200, 45, 45, 67, 67, 67, 1454, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 806, 67, 67, 67, 0, 0, 0, 1481, 0, 1094, 0, 0, 97, 1483, 97, 97, 97, 97, 97, 97, 304, 97, 97, 318, 97, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 97, 97, 97, 1507, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1332, 97, 97, 97, 1619, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1631, 97, 1633, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1381, 0, 0, 45, 45, 45, 45, 97, 97, 1727, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 626, 97, 97, 97, 97, 97, 97, 636, 45, 45, 1760, 67, 67, 67, 67, 67, 67, 67, 1765, 67, 67, 67, 67, 67, 67, 67, 1299, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1616, 97, 97, 1803, 45, 45, 45, 45, 1807, 45, 45, 45, 45, 45, 1813, 45, 45, 45, 67, 67, 1684, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 822, 67, 67, 37689, 544, 67, 67, 1818, 67, 67, 67, 67, 1822, 67, 67, 67, 67, 67, 1828, 67, 67, 67, 67, 67, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 2012, 2013, 45, 45, 67, 67, 67, 2018, 2019, 67, 67, 97, 67, 97, 97, 97, 1833, 97, 97, 0, 0, 97, 97, 1840, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 1733, 97, 1735, 97, 97, 97, 0, 97, 97, 97, 1849, 97, 97, 97, 45, 45, 45, 45, 45, 1857, 45, 45, 45, 1910, 45, 1912, 45, 45, 1914, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1017, 67, 67, 1020, 67, 45, 1861, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1872, 67, 67, 67, 67, 67, 67, 752, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1446, 67, 67, 67, 67, 67, 1876, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 1890, 97, 97, 97, 97, 97, 1134, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 570, 97, 97, 97, 97, 580, 1935, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1906, 45, 67, 67, 67, 67, 2048, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 931, 45, 45, 45, 45, 45, 45, 1674, 45, 1676, 45, 45, 45, 45, 45, 45, 45, 446, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1871, 67, 67, 67, 67, 0, 97, 97, 45, 67, 0, 97, 2060, 2061, 0, 2063, 45, 67, 0, 97, 45, 45, 156, 45, 45, 45, 45, 45, 45, 45, 45, 45, 192, 45, 45, 45, 45, 1673, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 429, 45, 45, 45, 45, 67, 67, 67, 269, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 349, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 374, 45, 45, 67, 67, 213, 217, 67, 67, 67, 67, 67, 242, 67, 247, 67, 253, 45, 45, 698, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 399, 45, 45, 0, 0, 0, 0, 925, 41606, 0, 929, 0, 0, 45, 45, 45, 45, 45, 45, 1391, 45, 45, 1395, 45, 45, 45, 45, 45, 45, 423, 45, 45, 45, 45, 45, 45, 45, 436, 45, 67, 67, 67, 67, 1041, 67, 1043, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1776, 67, 67, 97, 97, 97, 1099, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 888, 97, 97, 97, 1131, 97, 97, 97, 97, 1135, 97, 1137, 97, 97, 97, 97, 97, 97, 97, 1497, 97, 97, 97, 97, 97, 97, 97, 97, 97, 883, 97, 97, 97, 97, 97, 97, 1310, 0, 0, 0, 1316, 0, 0, 0, 0, 1100, 0, 0, 0, 97, 97, 97, 97, 97, 1107, 97, 97, 97, 97, 97, 97, 97, 97, 1343, 97, 97, 97, 97, 97, 97, 1348, 0, 0, 1317, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1112, 97, 45, 1804, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1868, 67, 1870, 67, 67, 67, 67, 67, 1817, 67, 67, 1819, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 823, 67, 37689, 544, 67, 97, 1832, 97, 97, 1834, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 0, 1732, 97, 97, 97, 97, 97, 97, 97, 850, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1177, 0, 0, 925, 0, 0, 0, 0, 97, 97, 97, 97, 0, 0, 1941, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1991, 1992, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1998, 134, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 45, 941, 45, 45, 944, 45, 45, 45, 45, 45, 45, 952, 45, 45, 207, 67, 67, 67, 67, 67, 226, 67, 67, 67, 67, 67, 67, 67, 67, 67, 820, 67, 67, 67, 67, 37689, 544, 369, 650, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1682, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 835, 97, 97, 97, 97, 97, 97, 97, 1522, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1725, 67, 67, 67, 1695, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1034, 67, 1036, 67, 67, 67, 265, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 97, 296, 97, 97, 97, 97, 314, 97, 97, 97, 97, 332, 334, 97, 97, 97, 97, 97, 1146, 1147, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1626, 97, 97, 97, 97, 97, 97, 345, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 372, 45, 45, 45, 1220, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1213, 45, 45, 45, 45, 404, 406, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 434, 45, 45, 45, 440, 45, 45, 45, 45, 45, 45, 45, 45, 451, 452, 45, 45, 45, 67, 1683, 67, 67, 67, 1686, 67, 67, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 67, 67, 490, 492, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1447, 67, 67, 1450, 67, 67, 67, 67, 67, 526, 67, 67, 67, 67, 67, 67, 67, 67, 537, 538, 67, 67, 67, 67, 67, 506, 67, 67, 508, 67, 67, 511, 67, 67, 67, 67, 0, 1476, 0, 0, 0, 0, 0, 1478, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 1484, 97, 97, 97, 97, 97, 97, 865, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1499, 97, 97, 97, 97, 97, 97, 97, 97, 97, 587, 589, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 629, 97, 97, 97, 97, 97, 97, 97, 97, 97, 623, 97, 97, 97, 97, 97, 97, 97, 97, 634, 635, 97, 97, 97, 97, 97, 1160, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1628, 97, 97, 97, 97, 369, 0, 45, 45, 45, 45, 45, 655, 45, 45, 45, 45, 45, 45, 45, 45, 999, 45, 1001, 45, 45, 45, 45, 45, 45, 45, 45, 715, 45, 45, 45, 720, 45, 45, 45, 45, 45, 45, 45, 45, 728, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 97, 97, 97, 97, 97, 840, 97, 97, 97, 97, 97, 1174, 97, 97, 97, 97, 0, 0, 925, 0, 0, 0, 0, 0, 0, 0, 1100, 97, 97, 97, 97, 97, 97, 97, 97, 627, 97, 97, 97, 97, 97, 97, 97, 938, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 680, 45, 968, 45, 970, 45, 973, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 962, 45, 45, 45, 45, 45, 979, 45, 45, 45, 45, 45, 985, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1224, 45, 45, 45, 45, 45, 45, 45, 45, 688, 45, 45, 45, 45, 45, 45, 45, 1007, 1008, 67, 67, 67, 67, 67, 1014, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1045, 67, 67, 67, 67, 67, 67, 67, 1038, 67, 67, 67, 67, 67, 67, 1044, 67, 1046, 67, 1049, 67, 67, 67, 67, 67, 67, 800, 67, 67, 67, 67, 67, 67, 808, 67, 67, 0, 0, 0, 1102, 97, 97, 97, 97, 97, 1108, 97, 97, 97, 97, 97, 97, 306, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1371, 97, 97, 97, 97, 97, 97, 97, 97, 1132, 97, 97, 97, 97, 97, 97, 1138, 97, 1140, 97, 1143, 97, 97, 97, 97, 97, 1352, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 869, 97, 97, 97, 97, 97, 45, 1191, 45, 45, 45, 45, 45, 1196, 45, 45, 45, 45, 45, 45, 45, 45, 1407, 45, 45, 45, 45, 45, 45, 45, 45, 986, 45, 45, 45, 45, 45, 45, 991, 45, 67, 67, 67, 1256, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1048, 67, 67, 67, 97, 1336, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 615, 97, 1386, 45, 1387, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 455, 45, 457, 45, 45, 1424, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1433, 67, 1434, 67, 67, 67, 67, 67, 767, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1591, 67, 1593, 67, 67, 45, 45, 1805, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1814, 45, 45, 1816, 67, 67, 67, 67, 1820, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1829, 67, 67, 67, 67, 67, 815, 67, 67, 67, 67, 821, 67, 67, 67, 37689, 544, 67, 1831, 97, 97, 97, 97, 1835, 0, 0, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1731, 97, 97, 97, 97, 97, 97, 97, 97, 97, 853, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 97, 1850, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1547, 45, 45, 45, 45, 45, 45, 45, 45, 1664, 45, 45, 45, 45, 45, 45, 45, 45, 961, 45, 45, 45, 45, 965, 45, 967, 1907, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1920, 0, 1936, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 67, 67, 67, 67, 67, 67, 1763, 67, 67, 67, 67, 67, 67, 67, 67, 1056, 67, 67, 67, 67, 67, 67, 67, 67, 1273, 67, 67, 67, 67, 67, 67, 67, 67, 1457, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 28672, 97, 45, 67, 67, 67, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 2054, 97, 97, 291, 97, 97, 97, 97, 97, 97, 320, 97, 97, 97, 97, 97, 97, 307, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 12288, 0, 925, 926, 1179, 0, 45, 377, 45, 45, 45, 381, 45, 45, 392, 45, 45, 396, 45, 45, 45, 45, 971, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1756, 45, 45, 45, 67, 67, 67, 67, 463, 67, 67, 67, 467, 67, 67, 478, 67, 67, 482, 67, 67, 67, 67, 67, 1028, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1469, 67, 67, 1472, 67, 502, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1460, 67, 97, 97, 97, 97, 560, 97, 97, 97, 564, 97, 97, 575, 97, 97, 579, 97, 97, 97, 97, 97, 1368, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 925, 0, 0, 930, 97, 599, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 872, 97, 45, 666, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1758, 0, 362, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 934, 45, 45, 45, 164, 168, 174, 178, 45, 45, 45, 45, 45, 194, 45, 45, 45, 165, 45, 45, 45, 45, 45, 45, 45, 45, 45, 199, 45, 45, 45, 67, 67, 1010, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1060, 67, 67, 67, 67, 67, 67, 1052, 1053, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1063, 97, 1157, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1167, 97, 97, 97, 97, 97, 1379, 97, 97, 97, 0, 0, 0, 45, 1383, 45, 45, 45, 1806, 45, 45, 45, 45, 45, 45, 1812, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1577, 67, 67, 67, 67, 67, 67, 67, 753, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1262, 67, 67, 67, 67, 67, 67, 67, 1282, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1471, 67, 45, 1402, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 417, 45, 67, 1462, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 97, 1517, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1128, 97, 97, 97, 97, 1636, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 851, 97, 97, 97, 97, 97, 97, 97, 67, 67, 1705, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1842, 0, 0, 1779, 97, 97, 97, 1782, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1789, 97, 97, 0, 0, 0, 97, 1847, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1675, 45, 45, 45, 45, 45, 45, 45, 45, 737, 738, 67, 740, 67, 741, 67, 743, 67, 67, 67, 67, 67, 67, 1968, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 45, 67, 0, 97, 45, 67, 2062, 97, 45, 67, 0, 97, 45, 67, 67, 97, 97, 2001, 97, 0, 0, 2004, 97, 97, 0, 97, 97, 97, 97, 1797, 97, 97, 97, 97, 97, 45, 45, 45, 67, 261, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 292, 97, 97, 97, 97, 311, 315, 321, 325, 97, 97, 97, 97, 97, 97, 1623, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1330, 97, 97, 1333, 1334, 97, 341, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 363, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 1221, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 413, 45, 45, 416, 45, 376, 45, 45, 45, 45, 382, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1408, 45, 45, 45, 45, 45, 403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 414, 45, 45, 45, 418, 67, 67, 67, 462, 67, 67, 67, 67, 468, 67, 67, 67, 67, 67, 67, 67, 67, 1602, 67, 1604, 67, 67, 67, 67, 67, 67, 67, 67, 489, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 500, 67, 67, 67, 67, 67, 1067, 67, 67, 67, 67, 67, 1072, 67, 67, 67, 67, 67, 67, 274, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 504, 67, 67, 67, 67, 67, 67, 67, 510, 67, 67, 67, 517, 519, 541, 67, 37139, 37139, 24853, 24853, 0, 70179, 0, 0, 0, 65820, 65820, 369, 287, 554, 97, 97, 97, 559, 97, 97, 97, 97, 565, 97, 97, 97, 97, 97, 97, 97, 1718, 0, 97, 97, 97, 97, 97, 97, 97, 898, 97, 97, 97, 97, 97, 97, 906, 97, 97, 97, 97, 586, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 597, 97, 97, 97, 97, 97, 1520, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 45, 1656, 45, 45, 45, 97, 97, 601, 97, 97, 97, 97, 97, 97, 97, 607, 97, 97, 97, 614, 616, 638, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 661, 45, 45, 45, 407, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1815, 45, 67, 45, 667, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 678, 45, 45, 45, 421, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 976, 977, 45, 45, 45, 682, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 693, 45, 45, 697, 67, 67, 748, 67, 67, 67, 67, 754, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1274, 67, 67, 67, 67, 67, 67, 67, 67, 765, 67, 67, 67, 67, 769, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1589, 67, 67, 67, 67, 67, 67, 67, 67, 780, 67, 67, 784, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1777, 67, 97, 97, 97, 97, 97, 97, 846, 97, 97, 97, 97, 852, 97, 97, 97, 97, 97, 97, 97, 1742, 45, 45, 45, 45, 45, 45, 45, 1747, 97, 97, 97, 863, 97, 97, 97, 97, 867, 97, 97, 97, 97, 97, 97, 97, 308, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 12288, 1178, 925, 0, 1179, 0, 97, 97, 97, 878, 97, 97, 882, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 12288, 0, 925, 0, 1179, 0, 908, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 925, 0, 0, 0, 954, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 963, 45, 45, 966, 45, 45, 157, 45, 45, 171, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 948, 45, 45, 45, 45, 45, 1022, 67, 67, 1026, 67, 67, 67, 1030, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1603, 1605, 67, 67, 67, 1608, 67, 67, 67, 1039, 67, 67, 1042, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 471, 67, 67, 67, 67, 67, 0, 1100, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 904, 97, 97, 97, 97, 1116, 97, 97, 1120, 97, 97, 97, 1124, 97, 97, 97, 97, 97, 97, 562, 97, 97, 97, 571, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1133, 97, 97, 1136, 97, 97, 97, 97, 97, 97, 97, 97, 915, 917, 97, 97, 97, 97, 97, 0, 97, 1170, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 925, 0, 0, 0, 0, 0, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1993, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1275, 67, 67, 67, 1278, 67, 0, 0, 0, 45, 45, 1182, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1189, 1204, 45, 45, 45, 1207, 45, 45, 1209, 45, 1210, 45, 45, 45, 45, 45, 45, 1546, 45, 45, 45, 45, 45, 45, 45, 45, 45, 689, 45, 45, 45, 45, 45, 45, 1231, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 236, 67, 67, 67, 67, 67, 67, 67, 801, 67, 67, 67, 805, 67, 67, 67, 67, 67, 1242, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1249, 67, 67, 67, 67, 67, 67, 507, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1300, 0, 0, 0, 0, 0, 1267, 67, 67, 1269, 67, 1270, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1280, 97, 1349, 97, 1350, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1360, 97, 97, 97, 0, 1980, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 673, 45, 45, 45, 45, 677, 45, 45, 45, 45, 1401, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 953, 67, 1437, 67, 1440, 67, 67, 67, 67, 1445, 67, 67, 67, 1448, 67, 67, 67, 67, 67, 67, 1029, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1825, 67, 67, 67, 67, 67, 1473, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1320, 0, 834, 97, 97, 97, 97, 1490, 97, 1493, 97, 97, 97, 97, 1498, 97, 97, 97, 1501, 97, 97, 97, 0, 97, 1638, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 916, 97, 97, 97, 97, 97, 97, 0, 1528, 97, 97, 97, 0, 45, 45, 45, 1535, 45, 45, 45, 45, 45, 45, 45, 1867, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1932, 0, 0, 1555, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1567, 45, 45, 158, 45, 45, 172, 45, 45, 45, 183, 45, 45, 45, 45, 201, 45, 45, 67, 212, 67, 67, 67, 67, 231, 235, 241, 245, 67, 67, 67, 67, 67, 67, 493, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 472, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1651, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 1539, 45, 45, 45, 67, 1704, 67, 1706, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1841, 97, 0, 1844, 97, 97, 97, 97, 1716, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 590, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 1385, 1748, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1757, 45, 45, 159, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 415, 45, 45, 97, 97, 1780, 97, 97, 97, 0, 0, 1786, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1730, 0, 97, 97, 97, 97, 97, 1736, 97, 1738, 67, 97, 97, 97, 97, 97, 97, 0, 1838, 97, 97, 97, 97, 97, 0, 0, 97, 1729, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1162, 97, 97, 97, 1165, 97, 97, 97, 45, 1950, 45, 45, 45, 45, 45, 45, 45, 45, 1958, 67, 67, 67, 1962, 67, 67, 67, 67, 67, 1246, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 1710, 97, 97, 97, 1999, 67, 97, 97, 97, 97, 0, 2003, 97, 97, 97, 0, 97, 97, 2008, 2009, 45, 67, 67, 67, 67, 0, 0, 97, 97, 97, 97, 45, 2052, 67, 2053, 0, 0, 0, 0, 925, 41606, 0, 0, 930, 0, 45, 45, 45, 45, 45, 45, 1392, 45, 1394, 45, 45, 45, 45, 45, 45, 45, 1545, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1563, 1565, 45, 45, 45, 1568, 0, 97, 2055, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 28672, 97, 45, 45, 160, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 679, 45, 45, 67, 67, 266, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 346, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 362, 0, 364, 0, 367, 41098, 369, 140, 371, 45, 45, 45, 379, 45, 45, 45, 388, 45, 45, 45, 45, 45, 45, 45, 45, 1663, 45, 45, 45, 45, 45, 45, 45, 45, 45, 449, 45, 45, 45, 45, 45, 67, 67, 542, 37139, 37139, 24853, 24853, 0, 70179, 0, 0, 0, 65820, 65820, 369, 287, 97, 97, 97, 97, 97, 1622, 97, 97, 97, 97, 97, 97, 97, 1629, 97, 97, 0, 1794, 1795, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1745, 45, 45, 97, 639, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 45, 731, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 251, 67, 67, 67, 67, 67, 798, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1073, 67, 67, 67, 860, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 873, 0, 0, 1101, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 921, 97, 0, 67, 67, 67, 67, 1245, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1250, 67, 67, 1253, 0, 0, 1312, 0, 0, 0, 1318, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1106, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1149, 97, 97, 97, 97, 97, 1155, 97, 97, 1325, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1141, 97, 97, 67, 67, 1439, 67, 1441, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1264, 67, 67, 67, 97, 97, 1492, 97, 1494, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1331, 97, 97, 97, 97, 67, 67, 67, 2037, 67, 97, 0, 0, 97, 97, 97, 2043, 97, 45, 45, 45, 442, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 232, 67, 67, 67, 67, 67, 67, 67, 67, 1823, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1975, 0, 0, 97, 874, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1142, 97, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 65, 86, 117, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 63, 84, 115, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 61, 82, 113, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 59, 80, 111, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 57, 78, 109, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 55, 76, 107, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 53, 74, 105, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 51, 72, 103, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 49, 70, 101, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 47, 68, 99, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 45, 67, 97, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 213085, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 0, 0, 44, 0, 0, 32863, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 41, 41, 41, 0, 0, 1138688, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 89, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 127, 127, 127, 127, 102432, 67, 262, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 342, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 360, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 717, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 412, 45, 45, 45, 45, 45, 67, 1009, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1292, 67, 67, 1294, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 1615, 97, 97, 97, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 66, 87, 118, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 64, 85, 116, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 62, 83, 114, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 60, 81, 112, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 58, 79, 110, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 56, 77, 108, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 54, 75, 106, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 52, 73, 104, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 50, 71, 102, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 48, 69, 100, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 46, 67, 98, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 233472, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 69724, 53264, 18, 18, 49172, 0, 57366, 262144, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 45, 45, 161, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 710, 45, 45, 28, 139621, 359, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 1389, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 949, 45, 45, 45, 45, 67, 503, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1449, 67, 67, 97, 600, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1154, 97, 0, 0, 0, 0, 925, 41606, 927, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1866, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 772, 67, 67, 67, 67, 67, 45, 45, 969, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 951, 45, 45, 45, 45, 1192, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1202, 45, 45, 0, 0, 0, 1314, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1488, 67, 67, 267, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 347, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 361, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 734, 45, 45, 45, 67, 67, 67, 67, 67, 742, 67, 67, 45, 45, 668, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1214, 45, 45, 1130, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1361, 97, 45, 45, 1671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1552, 45, 45, 0, 0, 0, 0, 2220032, 0, 0, 1130496, 0, 0, 0, 0, 2170880, 2171020, 2170880, 2170880, 18, 0, 0, 131072, 0, 0, 0, 90112, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 1485, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 1537, 45, 45, 45, 45, 45, 1390, 45, 1393, 45, 45, 45, 45, 1398, 45, 45, 45, 2170880, 2171167, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2576384, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 0, 0, 0, 0, 0, 0, 2183168, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2721252, 2744320, 2170880, 2170880, 2170880, 2834432, 2840040, 2170880, 2908160, 2170880, 2170880, 2936832, 2170880, 2170880, 2985984, 2170880, 2994176, 2170880, 2170880, 3014656, 2170880, 3059712, 3076096, 3088384, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 0, 2220032, 0, 0, 0, 1142784, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3215360, 2215936, 2215936, 2215936, 2215936, 2215936, 2437120, 2215936, 2215936, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 543, 0, 545, 0, 0, 2183168, 0, 0, 831, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 3031040, 2170880, 3055616, 2170880, 2170880, 2170880, 2170880, 3092480, 2170880, 2170880, 3125248, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 0, 0, 0, 0, 67, 67, 37139, 37139, 24853, 24853, 0, 0, 0, 0, 0, 65820, 65820, 0, 287, 97, 97, 97, 97, 97, 1783, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 1791, 0, 0, 546, 70179, 0, 0, 0, 0, 552, 0, 97, 97, 97, 97, 97, 97, 97, 604, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1150, 97, 97, 97, 97, 97, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 0, 0, 147456, 0, 0, 0, 0, 925, 41606, 0, 928, 0, 0, 45, 45, 45, 45, 45, 45, 998, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1562, 45, 1564, 45, 45, 45, 45, 0, 2158592, 2158592, 0, 0, 0, 0, 2232320, 2232320, 2232320, 0, 2240512, 2240512, 2240512, 2240512, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2416640
+];
+
+JSONiqTokenizer.EXPECTED =
+[ 291, 300, 304, 341, 315, 309, 305, 295, 319, 323, 327, 329, 296, 333, 337, 339, 342, 346, 350, 294, 356, 360, 312, 367, 352, 371, 363, 375, 379, 383, 387, 391, 395, 726, 399, 405, 518, 684, 405, 405, 405, 405, 808, 405, 405, 405, 512, 405, 405, 405, 431, 405, 405, 406, 405, 405, 404, 405, 405, 405, 405, 405, 405, 405, 908, 631, 410, 415, 405, 414, 419, 608, 405, 429, 602, 405, 435, 443, 405, 441, 641, 478, 405, 447, 451, 450, 456, 643, 461, 460, 762, 679, 465, 469, 741, 473, 477, 482, 486, 492, 932, 931, 523, 498, 504, 720, 405, 510, 596, 405, 516, 941, 580, 522, 929, 527, 590, 589, 897, 939, 534, 538, 547, 551, 555, 559, 563, 567, 571, 969, 575, 708, 690, 689, 579, 584, 634, 405, 594, 731, 405, 600, 882, 405, 606, 895, 786, 452, 612, 405, 615, 620, 876, 624, 628, 638, 647, 651, 655, 659, 663, 667, 676, 683, 688, 695, 694, 791, 405, 699, 437, 405, 706, 714, 405, 712, 825, 870, 405, 718, 724, 769, 768, 823, 730, 735, 745, 751, 422, 755, 759, 425, 766, 902, 810, 587, 775, 888, 887, 405, 773, 992, 405, 779, 962, 405, 785, 781, 986, 790, 795, 797, 506, 500, 499, 801, 805, 814, 820, 829, 833, 837, 841, 845, 849, 853, 857, 861, 616, 865, 869, 868, 488, 405, 874, 816, 405, 880, 738, 405, 886, 892, 543, 405, 901, 906, 913, 912, 918, 494, 541, 922, 926, 936, 945, 949, 953, 957, 530, 966, 973, 960, 702, 701, 405, 979, 981, 405, 985, 747, 405, 990, 998, 914, 405, 996, 1004, 672, 975, 974, 1014, 1002, 1008, 670, 1012, 405, 405, 405, 405, 405, 401, 1018, 1022, 1026, 1106, 1071, 1111, 1111, 1111, 1082, 1145, 1030, 1101, 1034, 1038, 1106, 1106, 1106, 1106, 1046, 1206, 1052, 1106, 1072, 1111, 1111, 1042, 1134, 1065, 1111, 1112, 1056, 1160, 1207, 1062, 1204, 1208, 1069, 1106, 1106, 1106, 1076, 1111, 1207, 1161, 1122, 1205, 1064, 1094, 1106, 1106, 1107, 1111, 1111, 1111, 1078, 1086, 1207, 1092, 1098, 1046, 1058, 1106, 1106, 1110, 1111, 1111, 1116, 1120, 1161, 1126, 1202, 1104, 1106, 1145, 1146, 1129, 1138, 1088, 1151, 1048, 1157, 1153, 1132, 1141, 1165, 1107, 1111, 1172, 1179, 1109, 1183, 1175, 1143, 1147, 1187, 1108, 1191, 1195, 1144, 1199, 1168, 1212, 1216, 1220, 1224, 1228, 1232, 1236, 1557, 1247, 1241, 1241, 1038, 1434, 1241, 1241, 1241, 1241, 1254, 1275, 1617, 1241, 1280, 1287, 1241, 1241, 1241, 1287, 1241, 2114, 1291, 1241, 1243, 1241, 2049, 1824, 2094, 2095, 1520, 1309, 1241, 1241, 1302, 1241, 1321, 1311, 1241, 1241, 1313, 1778, 1325, 1336, 1241, 1241, 1325, 1330, 1353, 1241, 1241, 1695, 1354, 1241, 1241, 1241, 1294, 1686, 1331, 1241, 1696, 1368, 1241, 1338, 1370, 1241, 1392, 1399, 1364, 2017, 1406, 2016, 1405, 1716, 1406, 1407, 1422, 1417, 1421, 1241, 1241, 1241, 1349, 1426, 1241, 1774, 1756, 1241, 1773, 1241, 1241, 1345, 1964, 1812, 1432, 1241, 1241, 1345, 1993, 1459, 1241, 1241, 1241, 1395, 1848, 1767, 1465, 1241, 1241, 1394, 1847, 1242, 1477, 1241, 1241, 1428, 1241, 1445, 1492, 1241, 1241, 1438, 1241, 1499, 1241, 1241, 1241, 1455, 1241, 1818, 1448, 1241, 1250, 1241, 2026, 1623, 1449, 1241, 1612, 1616, 1241, 1614, 1241, 1257, 1241, 1241, 1985, 1292, 1586, 1512, 1241, 1517, 2050, 1526, 1674, 1519, 1524, 1647, 2051, 1532, 1537, 1551, 1544, 1550, 1555, 1561, 1571, 1578, 1584, 1590, 1591, 1653, 1595, 1602, 1606, 1610, 1634, 1628, 1640, 1633, 1645, 1241, 1241, 1241, 1469, 1241, 1970, 1651, 1241, 1270, 1241, 1241, 1819, 1449, 1241, 1293, 1664, 1241, 1241, 1481, 1485, 1574, 1672, 1241, 1241, 1513, 1317, 1487, 1684, 1241, 1241, 1533, 1299, 1694, 1241, 1241, 1295, 1241, 1241, 1241, 1546, 1700, 1241, 1241, 1707, 1241, 1713, 1241, 1849, 1715, 1241, 1720, 1241, 1276, 1267, 1241, 1241, 2107, 1657, 1864, 1241, 1881, 1241, 1326, 1292, 1241, 1685, 1358, 1724, 1338, 1241, 1363, 1362, 1342, 1340, 1361, 1339, 1833, 1372, 1360, 1833, 1833, 1342, 1343, 1835, 1341, 1731, 1738, 1344, 1241, 1745, 1241, 1379, 1241, 1241, 2092, 1241, 1388, 1761, 1754, 1241, 1386, 1241, 1400, 1760, 1241, 1241, 1241, 1598, 1734, 1241, 1241, 1241, 1635, 1645, 1241, 1780, 1766, 1241, 1241, 1332, 1771, 1241, 1241, 1629, 2079, 1241, 1242, 1784, 1241, 1241, 1680, 1639, 2063, 1790, 1241, 1241, 1741, 1241, 1241, 1800, 1241, 1241, 1762, 1473, 1241, 1806, 1241, 1241, 1786, 1240, 1709, 1241, 1241, 1241, 1668, 1811, 1241, 1940, 1241, 1401, 1974, 1241, 1408, 1413, 1382, 1241, 1816, 1241, 1241, 1802, 2086, 1811, 1241, 1817, 1945, 1823, 2095, 2095, 2047, 2094, 2046, 2080, 1241, 1409, 1312, 1376, 2096, 2048, 1241, 1241, 1807, 1241, 1241, 1241, 2035, 1241, 1241, 1828, 1241, 2057, 2061, 1241, 1241, 1843, 1241, 2059, 1241, 1241, 1241, 1690, 1847, 1241, 1241, 1241, 1703, 2102, 1848, 1241, 1241, 1853, 1292, 1848, 1241, 2016, 1857, 1241, 2002, 1868, 1241, 1436, 1241, 1241, 1271, 1305, 1241, 1874, 1241, 1241, 1884, 2037, 1892, 1241, 1890, 1241, 1461, 1241, 1241, 1795, 1241, 1241, 1891, 1241, 1878, 1241, 1888, 1241, 1888, 1905, 1896, 2087, 1912, 1903, 1241, 1911, 1906, 1916, 1905, 2027, 1863, 1925, 2088, 1859, 1861, 1922, 1927, 1931, 1935, 1494, 1241, 1241, 1918, 1907, 1939, 1917, 1944, 1949, 1241, 1241, 1451, 1955, 1241, 1241, 1241, 1796, 1727, 2061, 1241, 1241, 1899, 1241, 1660, 1968, 1241, 1241, 1951, 1678, 1978, 1241, 1241, 1241, 1839, 1241, 1241, 1984, 1982, 1241, 1488, 1241, 1241, 1624, 1450, 1989, 1241, 1241, 1241, 1870, 1995, 1292, 1241, 1241, 1958, 1261, 1241, 1996, 1241, 1241, 1241, 2039, 2008, 1241, 1241, 1750, 2000, 1241, 1256, 2001, 1960, 1241, 1564, 1241, 1504, 1241, 1241, 1442, 1241, 1241, 1564, 1528, 1263, 1241, 1508, 1241, 1241, 1468, 1498, 2006, 1540, 2015, 1539, 2014, 1748, 2013, 1539, 1831, 2014, 2012, 1500, 1567, 2022, 2021, 1241, 1580, 1241, 1241, 2033, 2037, 1791, 2045, 2031, 1241, 1621, 1241, 1641, 2044, 1241, 1241, 1241, 2093, 1241, 1241, 2055, 1241, 1241, 2067, 1241, 1283, 1241, 1241, 1241, 2101, 2071, 1241, 1241, 1241, 2073, 1848, 2040, 1241, 1241, 1241, 2077, 1241, 1241, 2106, 1241, 1241, 2084, 1241, 2111, 1241, 1241, 1381, 1380, 1241, 1241, 1241, 2100, 1241, 2129, 2118, 2122, 2126, 2197, 2133, 3010, 2825, 2145, 2698, 2156, 2226, 2160, 2161, 2165, 2174, 2293, 2194, 2630, 2201, 2203, 2152, 3019, 2226, 2263, 2209, 2213, 2218, 2269, 2292, 2269, 2269, 2184, 2226, 2238, 2148, 2151, 3017, 2245, 2214, 2269, 2269, 2185, 2226, 2292, 2269, 2291, 2269, 2269, 2269, 2292, 2205, 3019, 2226, 2226, 2160, 2160, 2160, 2261, 2160, 2160, 2160, 2262, 2276, 2160, 2160, 2277, 2216, 2283, 2216, 2269, 2269, 2268, 2269, 2267, 2269, 2269, 2269, 2271, 2568, 2292, 2269, 2293, 2269, 2182, 2190, 2269, 2186, 2226, 2226, 2226, 2226, 2227, 2160, 2160, 2160, 2160, 2263, 2160, 2275, 2277, 2282, 2215, 2217, 2269, 2269, 2291, 2269, 2269, 2293, 2291, 2269, 2220, 2269, 2295, 2294, 2269, 2269, 2305, 2233, 2262, 2278, 2218, 2269, 2234, 2226, 2226, 2228, 2160, 2160, 2160, 2289, 2220, 2294, 2294, 2269, 2269, 2304, 2269, 2160, 2160, 2287, 2269, 2269, 2305, 2269, 2269, 2312, 2269, 2269, 2225, 2226, 2160, 2287, 2289, 2219, 2304, 2295, 2314, 2234, 2226, 2314, 2269, 2226, 2226, 2160, 2288, 2219, 2222, 2304, 2296, 2269, 2224, 2160, 2160, 2269, 2302, 2294, 2314, 2224, 2226, 2288, 2220, 2294, 2269, 2290, 2269, 2269, 2293, 2269, 2269, 2269, 2269, 2270, 2221, 2313, 2225, 2227, 2160, 2300, 2269, 2225, 2261, 2309, 2234, 2229, 2223, 2318, 2318, 2318, 2328, 2336, 2340, 2344, 2350, 2637, 2712, 2358, 2362, 2372, 2135, 2378, 2398, 2135, 2135, 2135, 2135, 2136, 2417, 2241, 2135, 2378, 2135, 2135, 2980, 2984, 2135, 3006, 2135, 2135, 2135, 2945, 2931, 2425, 2400, 2135, 2135, 2135, 2954, 2135, 2481, 2433, 2135, 2135, 2988, 2824, 2135, 2135, 2482, 2434, 2135, 2135, 2440, 2445, 2452, 2135, 2135, 2998, 3002, 2961, 2441, 2446, 2453, 2463, 2974, 2135, 2135, 2135, 2140, 2642, 2709, 2459, 2470, 2465, 2135, 2135, 3005, 2135, 2135, 2987, 2823, 2458, 2469, 2464, 2975, 2135, 2135, 2135, 2353, 2488, 2447, 2324, 2974, 2135, 2409, 2459, 2448, 2135, 2961, 2487, 2446, 2476, 2323, 2973, 2135, 2135, 2135, 2354, 2476, 2974, 2135, 2135, 2135, 2957, 2135, 2135, 2960, 2135, 2135, 2135, 2363, 2409, 2459, 2474, 2465, 2487, 2571, 2973, 2135, 2135, 2168, 2973, 2135, 2135, 2135, 2959, 2135, 2135, 2135, 2506, 2135, 2957, 2488, 2170, 2135, 2135, 2135, 2960, 2135, 2818, 2493, 2135, 2135, 3033, 2135, 2135, 2135, 2934, 2819, 2494, 2135, 2135, 2135, 2976, 2780, 2499, 2135, 2135, 2135, 3000, 2968, 2135, 2935, 2135, 2135, 2135, 2364, 2507, 2135, 2135, 2934, 2135, 2135, 2780, 2492, 2507, 2135, 2135, 2506, 2780, 2135, 2135, 2782, 2780, 2135, 2782, 2135, 2783, 2374, 2514, 2135, 2135, 2135, 3007, 2530, 2974, 2135, 2135, 2135, 3008, 2135, 2135, 2134, 2135, 2526, 2531, 2975, 2135, 2135, 3042, 2581, 2575, 2956, 2135, 2135, 2135, 2394, 2135, 2508, 2535, 2840, 2844, 2495, 2135, 2135, 2136, 2684, 2537, 2842, 2846, 2135, 2136, 2561, 2581, 2551, 2536, 2841, 2845, 2975, 3043, 2582, 2843, 2555, 2135, 3040, 3044, 2538, 2844, 2975, 2135, 2135, 2253, 2644, 2672, 2542, 2554, 2135, 2135, 2346, 2873, 2551, 2555, 2135, 2135, 2135, 2381, 2559, 2565, 2538, 2553, 2135, 2560, 2914, 2576, 2590, 2135, 2135, 2135, 2408, 2136, 2596, 2624, 2135, 2135, 2135, 2409, 2135, 2618, 2597, 3008, 2135, 2135, 2380, 2956, 2601, 2135, 2135, 2135, 2410, 2620, 2624, 2135, 2136, 2383, 2135, 2135, 2783, 2623, 2135, 2135, 2393, 2888, 2136, 2621, 3008, 2135, 2618, 2618, 2622, 2135, 2135, 2405, 2414, 2619, 2384, 2624, 2135, 2136, 2950, 2135, 2138, 2135, 2139, 2135, 2604, 2623, 2135, 2140, 2878, 2665, 2957, 2622, 2135, 2135, 2428, 2762, 2606, 2612, 2135, 2135, 2501, 2586, 2604, 3038, 2135, 2604, 3036, 2387, 2958, 2386, 2135, 2141, 2135, 2421, 2387, 2385, 2135, 2385, 2384, 2384, 2135, 2386, 2628, 2384, 2135, 2135, 2501, 2596, 2591, 2135, 2135, 2135, 2400, 2135, 2634, 2135, 2135, 2559, 2580, 2575, 2648, 2135, 2135, 2135, 2429, 2649, 2135, 2135, 2135, 2435, 2654, 2658, 2135, 2135, 2135, 2436, 2649, 2178, 2659, 2135, 2135, 2595, 2601, 2669, 2677, 2135, 2135, 2616, 2957, 2879, 2665, 2691, 2135, 2363, 2367, 2900, 2878, 2664, 2690, 2975, 2877, 2643, 2670, 2974, 2671, 2975, 2135, 2135, 2619, 2608, 2669, 2673, 2135, 2135, 2653, 2177, 2672, 2135, 2135, 2135, 2486, 2168, 2251, 2255, 2695, 2974, 2709, 2135, 2135, 2135, 2487, 2169, 2399, 2716, 2975, 2135, 2363, 2770, 2776, 2640, 2717, 2135, 2135, 2729, 2135, 2135, 2641, 2718, 2135, 2135, 2135, 2505, 2135, 2640, 2257, 2974, 2135, 2727, 2975, 2135, 2365, 2332, 2895, 2957, 2135, 2959, 2135, 2365, 2749, 2754, 2959, 2958, 2958, 2135, 2380, 2793, 2799, 2135, 2735, 2738, 2135, 2381, 2135, 2135, 2940, 2974, 2135, 2744, 2135, 2135, 2739, 2519, 2976, 2745, 2135, 2135, 2135, 2509, 2755, 2135, 2135, 2135, 2510, 2772, 2778, 2135, 2135, 2740, 2520, 2135, 2771, 2777, 2135, 2135, 2759, 2750, 2792, 2798, 2135, 2135, 2781, 2392, 2779, 2135, 2135, 2135, 2521, 2135, 2679, 2248, 2135, 2135, 2681, 2480, 2135, 2135, 2786, 3000, 2135, 2679, 2683, 2135, 2135, 2416, 2135, 2135, 2135, 2525, 2135, 2730, 2135, 2135, 2135, 2560, 2581, 2135, 2805, 2135, 2135, 2804, 2962, 2832, 2974, 2135, 2382, 2135, 2135, 2958, 2135, 2135, 2960, 2135, 2829, 2833, 2975, 2961, 2965, 2969, 2973, 2968, 2972, 2135, 2135, 2135, 2641, 2135, 2515, 2966, 2970, 2851, 2478, 2135, 2135, 2808, 2135, 2809, 2135, 2135, 2135, 2722, 2852, 2479, 2135, 2135, 2815, 2135, 2135, 2766, 2853, 2480, 2135, 2857, 2479, 2135, 2388, 2723, 2135, 2364, 2331, 2894, 2858, 2480, 2135, 2135, 2850, 2478, 2135, 2135, 2135, 2806, 2864, 2135, 2399, 2256, 2974, 2865, 2135, 2135, 2862, 2135, 2135, 2135, 2685, 2807, 2865, 2135, 2135, 2807, 2863, 2135, 2135, 2135, 2686, 2884, 2807, 2135, 2809, 2807, 2135, 2135, 2807, 2806, 2705, 2810, 2808, 2700, 2869, 2702, 2702, 2702, 2704, 2883, 2135, 2135, 2135, 2730, 2884, 2135, 2135, 2135, 2731, 2321, 2546, 2135, 2135, 2876, 2255, 2889, 2322, 2547, 2135, 2401, 2135, 2135, 2135, 2949, 2367, 2893, 2544, 2973, 2906, 2973, 2135, 2135, 2877, 2663, 2368, 2901, 2907, 2974, 2366, 2899, 2905, 2972, 2920, 2974, 2135, 2135, 2911, 2900, 2920, 2363, 2913, 2918, 2465, 2941, 2975, 2135, 2135, 2924, 2928, 2974, 2945, 2931, 2135, 2135, 2135, 2765, 2136, 2955, 2135, 2135, 2939, 2931, 2380, 2135, 2135, 2380, 2135, 2135, 2135, 2780, 2507, 2137, 2135, 2137, 2135, 2139, 2135, 2806, 2810, 2135, 2135, 2135, 2992, 2135, 2135, 2962, 2966, 2970, 2974, 2135, 2135, 2787, 3014, 2135, 2521, 2993, 2135, 2135, 2135, 2803, 2135, 2135, 2135, 2618, 2607, 2997, 3001, 2135, 2135, 2963, 2967, 2971, 2975, 2135, 2135, 2791, 2797, 2135, 3009, 2999, 3003, 2787, 3001, 2135, 2135, 2964, 2968, 2785, 2999, 3003, 2135, 2135, 2135, 2804, 2785, 2999, 3004, 2135, 2135, 2135, 2807, 2135, 2135, 3023, 2135, 2135, 2135, 2811, 2135, 2135, 3027, 2135, 2135, 2135, 2837, 2968, 3028, 2135, 2135, 2135, 2875, 2135, 2784, 3029, 2135, 2408, 2457, 2446, 0, 14, 0, -2120220672, 1610612736, -2074083328, -2002780160, -2111830528, 1073872896, 1342177280, 1075807216, 4096, 16384, 2048, 8192, 0, 8192, 0, 0, 0, 0, 1, 0, 0, 0, 2, 0, -2145386496, 8388608, 1073741824, 0, 0x80000000, 0x80000000, 2097152, 2097152, 2097152, 536870912, 0, 0, 134217728, 33554432, 1536, 268435456, 268435456, 268435456, 268435456, 128, 256, 32, 0, 65536, 131072, 524288, 16777216, 268435456, 0x80000000, 1572864, 1835008, 640, 32768, 65536, 262144, 1048576, 2097152, 196608, 196800, 196608, 196608, 0, 131072, 131072, 131072, 196608, 196624, 196608, 196624, 196608, 196608, 128, 4096, 16384, 16384, 2048, 0, 4, 0, 0, 0x80000000, 2097152, 0, 1024, 32, 32, 0, 65536, 1572864, 1048576, 32768, 32768, 32768, 32768, 196608, 196608, 196608, 64, 64, 196608, 196608, 131072, 131072, 131072, 131072, 268435456, 268435456, 64, 196736, 196608, 196608, 196608, 131072, 196608, 196608, 16384, 4, 4, 4, 2, 32, 32, 65536, 1048576, 12582912, 1073741824, 0, 0, 2, 8, 16, 96, 2048, 32768, 0, 0, 131072, 268435456, 268435456, 268435456, 256, 256, 196608, 196672, 196608, 196608, 196608, 196608, 4, 0, 256, 256, 256, 256, 32, 32, 32768, 32, 32, 32, 32, 32768, 268435456, 268435456, 268435456, 196608, 196608, 196608, 196624, 196608, 196608, 196608, 16, 16, 16, 268435456, 196608, 64, 64, 64, 196608, 196608, 196608, 196672, 268435456, 64, 64, 196608, 196608, 16, 196608, 196608, 196608, 268435456, 64, 196608, 131072, 262144, 4194304, 25165824, 33554432, 134217728, 268435456, 268435456, 196608, 262152, 8, 256, 512, 3072, 16384, 200, -1073741816, 8392713, 40, 8392718, 520, 807404072, 40, 520, 100663304, 0, 0, -540651761, -540651761, 257589048, 0, 262144, 0, 0, 3, 8, 256, 0, 4, 6, 4100, 8388612, 0, 0, 0, 3, 4, 8, 256, 512, 1024, 0, 2097152, 0, 0, -537854471, -537854471, 0, 100663296, 0, 0, 1, 2, 0, 0, 0, 16384, 0, 0, 0, 96, 14336, 0, 0, 0, 7, 8, 234881024, 0, 0, 0, 8, 0, 0, 0, 0, 262144, 0, 0, 16, 64, 384, 512, 0, 1, 1, 0, 12582912, 0, 0, 0, 0, 33554432, 67108864, -606084144, -606084144, -606084138, 0, 0, 28, 32, 768, 1966080, -608174080, 0, 0, 0, 14, 35056, 16, 64, 896, 24576, 98304, 98304, 131072, 262144, 524288, 1048576, 4194304, 25165824, 1048576, 62914560, 134217728, -805306368, 0, 384, 512, 16384, 65536, 131072, 262144, 29360128, 33554432, 134217728, 268435456, 1073741824, 0x80000000, 262144, 524288, 1048576, 29360128, 33554432, 524288, 1048576, 16777216, 33554432, 134217728, 268435456, 1073741824, 0, 0, 0, 123856, 1966080, 0, 64, 384, 16384, 65536, 131072, 16384, 65536, 524288, 268435456, 0x80000000, 0, 0, 524288, 0x80000000, 0, 0, 1, 16, 0, 256, 524288, 0, 0, 0, 25, 96, 128, -537854471, 0, 0, 0, 32, 7404800, -545259520, 0, 0, 0, 60, 0, 249, 64768, 1048576, 6291456, 6291456, 25165824, 100663296, 402653184, 1073741824, 96, 128, 1280, 2048, 4096, 57344, 6291456, 57344, 6291456, 8388608, 16777216, 33554432, 201326592, 1342177280, 0x80000000, 0, 57344, 6291456, 8388608, 100663296, 134217728, 0x80000000, 0, 0, 0, 1, 8, 16, 64, 128, 64, 128, 256, 1024, 131072, 131072, 131072, 262144, 524288, 16777216, 57344, 6291456, 8388608, 67108864, 134217728, 64, 256, 1024, 2048, 4096, 57344, 64, 256, 0, 24576, 32768, 6291456, 67108864, 134217728, 0, 1, 64, 256, 24576, 32768, 4194304, 32768, 4194304, 67108864, 0, 0, 64, 256, 0, 0, 24576, 32768, 0, 16384, 4194304, 67108864, 64, 16384, 0, 0, 1, 64, 256, 16384, 4194304, 67108864, 0, 0, 0, 16384, 0, 16384, 16384, 0, -470447874, -470447874, -470447874, 0, 0, 128, 0, 0, 8, 96, 2048, 32768, 262144, 8388608, 35056, 1376256, -471859200, 0, 0, 14, 16, 224, 2048, 32768, 2097152, 4194304, 8388608, -486539264, 0, 96, 128, 2048, 32768, 262144, 2097152, 262144, 2097152, 8388608, 33554432, 536870912, 1073741824, 0x80000000, 0, 1610612736, 0x80000000, 0, 0, 1, 524288, 1048576, 12582912, 0, 0, 0, 151311, 264503296, 2097152, 8388608, 33554432, 1610612736, 0x80000000, 262144, 8388608, 33554432, 536870912, 67108864, 4194304, 0, 4194304, 0, 4194304, 4194304, 0, 0, 524288, 8388608, 536870912, 1073741824, 0x80000000, 1, 4097, 8388609, 96, 2048, 32768, 1073741824, 0x80000000, 0, 96, 2048, 0x80000000, 0, 0, 96, 2048, 0, 0, 1, 12582912, 0, 0, 0, 0, 1641895695, 1641895695, 0, 0, 0, 249, 7404800, 15, 87808, 1835008, 1639972864, 0, 768, 5120, 16384, 65536, 1835008, 1835008, 12582912, 16777216, 1610612736, 0, 3, 4, 8, 768, 4096, 65536, 0, 0, 256, 512, 786432, 8, 256, 512, 4096, 16384, 1835008, 16384, 1835008, 12582912, 1610612736, 0, 0, 0, 256, 0, 0, 0, 4, 8, 16, 32, 1, 2, 8, 256, 16384, 524288, 16384, 524288, 1048576, 12582912, 1610612736, 0, 0, 0, 8388608, 0, 0, 0, 524288, 4194304, 0, 0, 0, 8388608, -548662288, -548662288, -548662288, 0, 0, 256, 16384, 65536, 520093696, -1073741824, 0, 0, 0, 16777216, 0, 16, 32, 960, 4096, 4980736, 520093696, 1073741824, 0, 32, 896, 4096, 57344, 1048576, 6291456, 8388608, 16777216, 100663296, 134217728, 268435456, 0x80000000, 0, 512, 786432, 4194304, 33554432, 134217728, 268435456, 0, 786432, 4194304, 134217728, 268435456, 0, 524288, 4194304, 268435456, 0, 0, 0, 0, 0, 4194304, 4194304, -540651761, 0, 0, 0, 2, 4, 8, 16, 96, 128, 264503296, -805306368, 0, 0, 0, 8, 256, 512, 19456, 131072, 3072, 16384, 131072, 262144, 8388608, 16777216, 512, 1024, 2048, 16384, 131072, 262144, 131072, 262144, 8388608, 33554432, 201326592, 268435456, 0, 3, 4, 256, 1024, 2048, 57344, 16384, 131072, 8388608, 33554432, 134217728, 268435456, 0, 3, 256, 1024, 16384, 131072, 33554432, 134217728, 1073741824, 0x80000000, 0, 0, 256, 524288, 0x80000000, 0, 3, 256, 33554432, 134217728, 1073741824, 0, 1, 2, 33554432, 1, 2, 134217728, 1073741824, 0, 1, 2, 134217728, 0, 0, 0, 64, 0, 0, 0, 16, 32, 896, 4096, 786432, 4194304, 16777216, 33554432, 201326592, 268435456, 1073741824, 0x80000000, 0, 0, 0, 15, 0, 4980736, 4980736, 4980736, 70460, 70460, 3478332, 0, 0, 1008, 4984832, 520093696, 60, 4864, 65536, 0, 0, 0, 12, 16, 32, 256, 512, 4096, 65536, 0, 0, 0, 67108864, 0, 0, 0, 12, 0, 256, 512, 65536, 0, 0, 1024, 512, 131072, 131072, 4, 16, 32, 65536, 0, 4, 16, 32, 0, 0, 0, 4, 16, 0, 0, 16384, 67108864, 0, 0, 1, 24, 96, 128, 256, 1024
+];
+
+JSONiqTokenizer.TOKEN =
+[
+ "(0)",
+ "JSONChar",
+ "JSONCharRef",
+ "JSONPredefinedCharRef",
+ "ModuleDecl",
+ "Annotation",
+ "OptionDecl",
+ "Operator",
+ "Variable",
+ "Tag",
+ "EndTag",
+ "PragmaContents",
+ "DirCommentContents",
+ "DirPIContents",
+ "CDataSectionContents",
+ "AttrTest",
+ "Wildcard",
+ "EQName",
+ "IntegerLiteral",
+ "DecimalLiteral",
+ "DoubleLiteral",
+ "PredefinedEntityRef",
+ "'\"\"'",
+ "EscapeApos",
+ "AposChar",
+ "ElementContentChar",
+ "QuotAttrContentChar",
+ "AposAttrContentChar",
+ "NCName",
+ "QName",
+ "S",
+ "CharRef",
+ "CommentContents",
+ "DocTag",
+ "DocCommentContents",
+ "EOF",
+ "'!'",
+ "'\"'",
+ "'#'",
+ "'#)'",
+ "'$$'",
+ "''''",
+ "'('",
+ "'(#'",
+ "'(:'",
+ "'(:~'",
+ "')'",
+ "'*'",
+ "'*'",
+ "','",
+ "'-->'",
+ "'.'",
+ "'/'",
+ "'/>'",
+ "':'",
+ "':)'",
+ "';'",
+ "'<!--'",
+ "'<![CDATA['",
+ "'<?'",
+ "'='",
+ "'>'",
+ "'?'",
+ "'?>'",
+ "'NaN'",
+ "'['",
+ "']'",
+ "']]>'",
+ "'after'",
+ "'all'",
+ "'allowing'",
+ "'ancestor'",
+ "'ancestor-or-self'",
+ "'and'",
+ "'any'",
+ "'append'",
+ "'array'",
+ "'as'",
+ "'ascending'",
+ "'at'",
+ "'attribute'",
+ "'base-uri'",
+ "'before'",
+ "'boundary-space'",
+ "'break'",
+ "'by'",
+ "'case'",
+ "'cast'",
+ "'castable'",
+ "'catch'",
+ "'check'",
+ "'child'",
+ "'collation'",
+ "'collection'",
+ "'comment'",
+ "'constraint'",
+ "'construction'",
+ "'contains'",
+ "'content'",
+ "'context'",
+ "'continue'",
+ "'copy'",
+ "'copy-namespaces'",
+ "'count'",
+ "'decimal-format'",
+ "'decimal-separator'",
+ "'declare'",
+ "'default'",
+ "'delete'",
+ "'descendant'",
+ "'descendant-or-self'",
+ "'descending'",
+ "'diacritics'",
+ "'different'",
+ "'digit'",
+ "'distance'",
+ "'div'",
+ "'document'",
+ "'document-node'",
+ "'element'",
+ "'else'",
+ "'empty'",
+ "'empty-sequence'",
+ "'encoding'",
+ "'end'",
+ "'entire'",
+ "'eq'",
+ "'every'",
+ "'exactly'",
+ "'except'",
+ "'exit'",
+ "'external'",
+ "'first'",
+ "'following'",
+ "'following-sibling'",
+ "'for'",
+ "'foreach'",
+ "'foreign'",
+ "'from'",
+ "'ft-option'",
+ "'ftand'",
+ "'ftnot'",
+ "'ftor'",
+ "'function'",
+ "'ge'",
+ "'greatest'",
+ "'group'",
+ "'grouping-separator'",
+ "'gt'",
+ "'idiv'",
+ "'if'",
+ "'import'",
+ "'in'",
+ "'index'",
+ "'infinity'",
+ "'inherit'",
+ "'insensitive'",
+ "'insert'",
+ "'instance'",
+ "'integrity'",
+ "'intersect'",
+ "'into'",
+ "'is'",
+ "'item'",
+ "'json'",
+ "'json-item'",
+ "'key'",
+ "'language'",
+ "'last'",
+ "'lax'",
+ "'le'",
+ "'least'",
+ "'let'",
+ "'levels'",
+ "'loop'",
+ "'lowercase'",
+ "'lt'",
+ "'minus-sign'",
+ "'mod'",
+ "'modify'",
+ "'module'",
+ "'most'",
+ "'namespace'",
+ "'namespace-node'",
+ "'ne'",
+ "'next'",
+ "'no'",
+ "'no-inherit'",
+ "'no-preserve'",
+ "'node'",
+ "'nodes'",
+ "'not'",
+ "'object'",
+ "'occurs'",
+ "'of'",
+ "'on'",
+ "'only'",
+ "'option'",
+ "'or'",
+ "'order'",
+ "'ordered'",
+ "'ordering'",
+ "'paragraph'",
+ "'paragraphs'",
+ "'parent'",
+ "'pattern-separator'",
+ "'per-mille'",
+ "'percent'",
+ "'phrase'",
+ "'position'",
+ "'preceding'",
+ "'preceding-sibling'",
+ "'preserve'",
+ "'previous'",
+ "'processing-instruction'",
+ "'relationship'",
+ "'rename'",
+ "'replace'",
+ "'return'",
+ "'returning'",
+ "'revalidation'",
+ "'same'",
+ "'satisfies'",
+ "'schema'",
+ "'schema-attribute'",
+ "'schema-element'",
+ "'score'",
+ "'self'",
+ "'sensitive'",
+ "'sentence'",
+ "'sentences'",
+ "'skip'",
+ "'sliding'",
+ "'some'",
+ "'stable'",
+ "'start'",
+ "'stemming'",
+ "'stop'",
+ "'strict'",
+ "'strip'",
+ "'structured-item'",
+ "'switch'",
+ "'text'",
+ "'then'",
+ "'thesaurus'",
+ "'times'",
+ "'to'",
+ "'treat'",
+ "'try'",
+ "'tumbling'",
+ "'type'",
+ "'typeswitch'",
+ "'union'",
+ "'unique'",
+ "'unordered'",
+ "'updating'",
+ "'uppercase'",
+ "'using'",
+ "'validate'",
+ "'value'",
+ "'variable'",
+ "'version'",
+ "'weight'",
+ "'when'",
+ "'where'",
+ "'while'",
+ "'wildcards'",
+ "'window'",
+ "'with'",
+ "'without'",
+ "'word'",
+ "'words'",
+ "'xquery'",
+ "'zero-digit'",
+ "'{'",
+ "'{{'",
+ "'|'",
+ "'}'",
+ "'}}'"
+];
+
+},{}],"/node_modules/xqlint/lib/lexers/jsoniq_lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var JSONiqTokenizer = _dereq_('./JSONiqTokenizer').JSONiqTokenizer;
+var Lexer = _dereq_('./lexer').Lexer;
+
+var keys = 'NaN|after|allowing|ancestor|ancestor-or-self|and|append|array|as|ascending|at|attribute|base-uri|before|boundary-space|break|by|case|cast|castable|catch|child|collation|comment|constraint|construction|contains|context|continue|copy|copy-namespaces|count|decimal-format|decimal-separator|declare|default|delete|descendant|descendant-or-self|descending|digit|div|document|document-node|element|else|empty|empty-sequence|encoding|end|eq|every|except|exit|external|false|first|following|following-sibling|for|from|ft-option|function|ge|greatest|group|grouping-separator|gt|idiv|if|import|in|index|infinity|insert|instance|integrity|intersect|into|is|item|json|json-item|jsoniq|last|lax|le|least|let|loop|lt|minus-sign|mod|modify|module|namespace|namespace-node|ne|next|node|nodes|not|null|object|of|only|option|or|order|ordered|ordering|paragraphs|parent|pattern-separator|per-mille|percent|preceding|preceding-sibling|previous|processing-instruction|rename|replace|return|returning|revalidation|satisfies|schema|schema-attribute|schema-element|score|select|self|sentences|sliding|some|stable|start|strict|switch|text|then|times|to|treat|true|try|tumbling|type|typeswitch|union|unordered|updating|validate|value|variable|version|when|where|while|window|with|words|xquery|zero-digit'.split('|');
+var keywords = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'keyword' }; });
+var ncnames = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'text', next: function(stack){ stack.pop(); } }; });
+
+var cdata = 'constant.language';
+var number = 'constant';
+var xmlcomment = 'comment';
+var pi = 'xml-pe';
+var pragma = 'constant.buildin';
+var n = function(name){
+ return '\'' + name + '\'';
+};
+var Rules = {
+ start: [
+ { name: n('(#'), token: pragma, next: function(stack){ stack.push('Pragma'); } },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n('(:~'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: n('<?'), token: pi, next: function(stack) { stack.push('PI'); } },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposString'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotString'); } },
+ { name: 'Annotation', token: 'support.function' },
+ { name: 'ModuleDecl', token: 'keyword', next: function(stack){ stack.push('Prefix'); } },
+ { name: 'OptionDecl', token: 'keyword', next: function(stack){ stack.push('_EQName'); } },
+ { name: 'AttrTest', token: 'support.type' },
+ { name: 'Variable', token: 'variable' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: 'IntegerLiteral', token: number },
+ { name: 'DecimalLiteral', token: number },
+ { name: 'DoubleLiteral', token: number },
+ { name: 'Operator', token: 'keyword.operator' },
+ { name: 'EQName', token: function(val) { return keys.indexOf(val) !== -1 ? 'keyword' : 'support.function'; } },
+ { name: n('('), token: 'lparen' },
+ { name: n(')'), token: 'rparen' },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: n('}'), token: 'text', next: function(stack){ if(stack.length > 1) { stack.pop(); } } },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } } //, next: function(stack){ if(stack.length > 1) { stack.pop(); } } }
+ ].concat(keywords),
+ _EQName: [
+ { name: 'EQName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ Prefix: [
+ { name: 'NCName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ StartTag: [
+ { name: n('>'), token: 'meta.tag', next: function(stack){ stack.push('TagContent'); } },
+ { name: 'QName', token: 'entity.other.attribute-name' },
+ { name: n('='), token: 'text' },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposAttr'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotAttr'); } },
+ { name: n('/>'), token: 'meta.tag.r', next: function(stack){ stack.pop(); } }
+ ],
+ TagContent: [
+ { name: 'ElementContentChar', token: 'text' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'text' },
+ { name: n('}}'), token: 'text' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } },
+ { name: 'EndTag', token: 'meta.tag', next: function(stack){ stack.pop(); stack.pop(); } }
+ ],
+ AposAttr: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ QuotAttr: [
+ { name: n('\"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeQuot', token: 'constant.language.escape' },
+ { name: 'QuotAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ Pragma: [
+ { name: 'PragmaContents', token: pragma },
+ { name: n('#'), token: pragma },
+ { name: n('#)'), token: pragma, next: function(stack){ stack.pop(); } }
+ ],
+ Comment: [
+ { name: 'CommentContents', token: 'comment' },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n(':)'), token: 'comment', next: function(stack){ stack.pop(); } }
+ ],
+ CommentDoc: [
+ { name: 'DocCommentContents', token: 'comment.doc' },
+ { name: 'DocTag', token: 'comment.doc.tag' },
+ { name: n('(:'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n(':)'), token: 'comment.doc', next: function(stack){ stack.pop(); } }
+ ],
+ XMLComment: [
+ { name: 'DirCommentContents', token: xmlcomment },
+ { name: n('-->'), token: xmlcomment, next: function(stack){ stack.pop(); } }
+ ],
+ CData: [
+ { name: 'CDataSectionContents', token: cdata },
+ { name: n(']]>'), token: cdata, next: function(stack){ stack.pop(); } }
+ ],
+ PI: [
+ { name: 'DirPIContents', token: pi },
+ { name: n('?'), token: pi },
+ { name: n('?>'), token: pi, next: function(stack){ stack.pop(); } }
+ ],
+ AposString: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposChar', token: 'string' }
+ ],
+ QuotString: [
+ { name: n('"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'JSONPredefinedCharRef', token: 'constant.language.escape' },
+ { name: 'JSONCharRef', token: 'constant.language.escape' },
+ { name: 'JSONChar', token: 'string' }
+ ]
+};
+
+exports.JSONiqLexer = function(){ return new Lexer(JSONiqTokenizer, Rules); };
+},{"./JSONiqTokenizer":"/node_modules/xqlint/lib/lexers/JSONiqTokenizer.js","./lexer":"/node_modules/xqlint/lib/lexers/lexer.js"}],"/node_modules/xqlint/lib/lexers/lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var TokenHandler = function(code) {
+ var input = code;
+ this.tokens = [];
+
+ this.reset = function() {
+ input = input;
+ this.tokens = [];
+ };
+
+ this.startNonterminal = function() {};
+ this.endNonterminal = function() {};
+
+ this.terminal = function(name, begin, end) {
+ this.tokens.push({
+ name: name,
+ value: input.substring(begin, end)
+ });
+ };
+
+ this.whitespace = function(begin, end) {
+ this.tokens.push({
+ name: 'WS',
+ value: input.substring(begin, end)
+ });
+ };
+};
+
+exports.Lexer = function(Tokenizer, Rules) {
+
+ this.tokens = [];
+
+ this.getLineTokens = function(line, state) {
+ state = (state === 'start' || !state) ? '["start"]' : state;
+ var stack = JSON.parse(state);
+ var h = new TokenHandler(line);
+ var tokenizer = new Tokenizer(line, h);
+ var tokens = [];
+
+ while(true) {
+ var currentState = stack[stack.length - 1];
+ try {
+ h.tokens = [];
+ tokenizer['parse_' + currentState]();
+ var info = null;
+
+ if(h.tokens.length > 1 && h.tokens[0].name === 'WS') {
+ tokens.push({
+ type: 'text',
+ value: h.tokens[0].value
+ });
+ h.tokens.splice(0, 1);
+ }
+
+ var token = h.tokens[0];
+ var rules = Rules[currentState];
+ for(var k = 0; k < rules.length; k++) {
+ var rule = Rules[currentState][k];
+ if((typeof(rule.name) === 'function' && rule.name(token)) || rule.name === token.name) {
+ info = rule;
+ break;
+ }
+ }
+
+ if(token.name === 'EOF') { break; }
+ if(token.value === '') { throw 'Encountered empty string lexical rule.'; }
+
+ tokens.push({
+ type: info === null ? 'text' : (typeof(info.token) === 'function' ? info.token(token.value) : info.token),
+ value: token.value
+ });
+
+ if(info && info.next) {
+ info.next(stack);
+ }
+
+ } catch(e) {
+ if(e instanceof tokenizer.ParseException) {
+ var index = 0;
+ for(var i=0; i < tokens.length; i++) {
+ index += tokens[i].value.length;
+ }
+ tokens.push({ type: 'text', value: line.substring(index) });
+ return {
+ tokens: tokens,
+ state: JSON.stringify(['start'])
+ };
+ } else {
+ throw e;
+ }
+ }
+ }
+
+ return {
+ tokens: tokens,
+ state: JSON.stringify(stack)
+ };
+ };
+};
+},{}]},{},["/node_modules/xqlint/lib/lexers/jsoniq_lexer.js"]);
+
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/behaviour/xquery",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/mode/behaviour/xml","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+ var oop = require("../../lib/oop");
+ var Behaviour = require('../behaviour').Behaviour;
+ var CstyleBehaviour = require('./cstyle').CstyleBehaviour;
+ var XmlBehaviour = require("../behaviour/xml").XmlBehaviour;
+ var TokenIterator = require("../../token_iterator").TokenIterator;
+
+function hasType(token, type) {
+ var hasType = true;
+ var typeList = token.type.split('.');
+ var needleList = type.split('.');
+ needleList.forEach(function(needle){
+ if (typeList.indexOf(needle) == -1) {
+ hasType = false;
+ return false;
+ }
+ });
+ return hasType;
+}
+
+ var XQueryBehaviour = function () {
+
+ this.inherit(CstyleBehaviour, ["braces", "parens", "string_dquotes"]); // Get string behaviour
+ this.inherit(XmlBehaviour); // Get xml behaviour
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken();
+ var atCursor = false;
+ var state = JSON.parse(state).pop();
+ if ((token && token.value === '>') || state !== "StartTag") return;
+ if (!token || !hasType(token, 'meta.tag') && !(hasType(token, 'text') && token.value.match('/'))){
+ do {
+ token = iterator.stepBackward();
+ } while (token && (hasType(token, 'string') || hasType(token, 'keyword.operator') || hasType(token, 'entity.attribute-name') || hasType(token, 'text')));
+ } else {
+ atCursor = true;
+ }
+ var previous = iterator.stepBackward();
+ if (!token || !hasType(token, 'meta.tag') || (previous !== null && previous.value.match('/'))) {
+ return
+ }
+ var tag = token.value.substring(1);
+ if (atCursor){
+ var tag = tag.substring(0, position.column - token.start);
+ }
+
+ return {
+ text: '>' + '</' + tag + '>',
+ selection: [1, 1]
+ }
+ }
+ });
+
+ }
+ oop.inherits(XQueryBehaviour, Behaviour);
+
+ exports.XQueryBehaviour = XQueryBehaviour;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/jsoniq",["require","exports","module","ace/worker/worker_client","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/xquery/jsoniq_lexer","ace/range","ace/mode/behaviour/xquery","ace/mode/folding/cstyle","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var JSONiqLexer = require("./xquery/jsoniq_lexer").JSONiqLexer;
+var Range = require("../range").Range;
+var XQueryBehaviour = require("./behaviour/xquery").XQueryBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var Anchor = require("../anchor").Anchor;
+
+var Mode = function() {
+ this.$tokenizer = new JSONiqLexer();
+ this.$behaviour = new XQueryBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+ this.$highlightRules = new TextHighlightRules();
+};
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.completer = {
+ getCompletions: function(editor, session, pos, prefix, callback) {
+ if (!session.$worker)
+ return callback();
+ session.$worker.emit("complete", { data: { pos: pos, prefix: prefix } });
+ session.$worker.on("complete", function(e){
+ callback(null, e.data);
+ });
+ }
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var match = line.match(/\s*(?:then|else|return|[{\(]|<\w+>)\s*$/);
+ if (match)
+ indent += tab;
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*[\}\)]/.test(input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*[\}\)])/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.toggleCommentLines = function(state, doc, startRow, endRow) {
+ var i, line;
+ var outdent = true;
+ var re = /^\s*\(:(.*):\)/;
+
+ for (i=startRow; i<= endRow; i++) {
+ if (!re.test(doc.getLine(i))) {
+ outdent = false;
+ break;
+ }
+ }
+
+ var range = new Range(0, 0, 0, 0);
+ for (i=startRow; i<= endRow; i++) {
+ line = doc.getLine(i);
+ range.start.row = i;
+ range.end.row = i;
+ range.end.column = line.length;
+
+ doc.replace(range, outdent ? line.match(re)[1] : "(:" + line + ":)");
+ }
+ };
+ this.createWorker = function(session) {
+
+ var worker = new WorkerClient(["ace"], "ace/mode/xquery_worker", "XQueryWorker");
+ var that = this;
+
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("ok", function(e) {
+ session.clearAnnotations();
+ });
+
+ worker.on("markers", function(e) {
+ session.clearAnnotations();
+ that.addMarkers(e.data, session);
+ });
+
+ return worker;
+ };
+
+ this.removeMarkers = function(session) {
+ var markers = session.getMarkers(false);
+ for (var id in markers) {
+ if (markers[id].clazz.indexOf('language_highlight_') === 0) {
+ session.removeMarker(id);
+ }
+ }
+ for (var i = 0; i < session.markerAnchors.length; i++) {
+ session.markerAnchors[i].detach();
+ }
+ session.markerAnchors = [];
+ };
+
+ this.addMarkers = function(annos, mySession) {
+ var _self = this;
+
+ if (!mySession.markerAnchors) mySession.markerAnchors = [];
+ this.removeMarkers(mySession);
+ mySession.languageAnnos = [];
+ annos.forEach(function(anno) {
+ var anchor = new Anchor(mySession.getDocument(), anno.pos.sl, anno.pos.sc || 0);
+ mySession.markerAnchors.push(anchor);
+ var markerId;
+ var colDiff = anno.pos.ec - anno.pos.sc;
+ var rowDiff = anno.pos.el - anno.pos.sl;
+ var gutterAnno = {
+ guttertext: anno.message,
+ type: anno.level || "warning",
+ text: anno.message
+ };
+
+ function updateFloat(single) {
+ if (markerId)
+ mySession.removeMarker(markerId);
+ gutterAnno.row = anchor.row;
+ if (anno.pos.sc !== undefined && anno.pos.ec !== undefined) {
+ var range = new Range(anno.pos.sl, anno.pos.sc, anno.pos.el, anno.pos.ec);
+ markerId = mySession.addMarker(range, "language_highlight_" + (anno.type ? anno.type : "default"));
+ }
+ if (single) mySession.setAnnotations(mySession.languageAnnos);
+ }
+ updateFloat();
+ anchor.on("change", function() {
+ updateFloat(true);
+ });
+ if (anno.message) mySession.languageAnnos.push(gutterAnno);
+ });
+ mySession.setAnnotations(mySession.languageAnnos);
+ };
+
+ this.$id = "ace/mode/jsoniq";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-jsp.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-jsp.js
new file mode 100644
index 00000000..ad13aed5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-jsp.js
@@ -0,0 +1,1388 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/java_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JavaHighlightRules = function() {
+ var keywords = (
+ "abstract|continue|for|new|switch|" +
+ "assert|default|goto|package|synchronized|" +
+ "boolean|do|if|private|this|" +
+ "break|double|implements|protected|throw|" +
+ "byte|else|import|public|throws|" +
+ "case|enum|instanceof|return|transient|" +
+ "catch|extends|int|short|try|" +
+ "char|final|interface|static|void|" +
+ "class|finally|long|strictfp|volatile|" +
+ "const|float|native|super|while"
+ );
+
+ var buildinConstants = ("null|Infinity|NaN|undefined");
+
+
+ var langClasses = (
+ "AbstractMethodError|AssertionError|ClassCircularityError|"+
+ "ClassFormatError|Deprecated|EnumConstantNotPresentException|"+
+ "ExceptionInInitializerError|IllegalAccessError|"+
+ "IllegalThreadStateException|InstantiationError|InternalError|"+
+ "NegativeArraySizeException|NoSuchFieldError|Override|Process|"+
+ "ProcessBuilder|SecurityManager|StringIndexOutOfBoundsException|"+
+ "SuppressWarnings|TypeNotPresentException|UnknownError|"+
+ "UnsatisfiedLinkError|UnsupportedClassVersionError|VerifyError|"+
+ "InstantiationException|IndexOutOfBoundsException|"+
+ "ArrayIndexOutOfBoundsException|CloneNotSupportedException|"+
+ "NoSuchFieldException|IllegalArgumentException|NumberFormatException|"+
+ "SecurityException|Void|InheritableThreadLocal|IllegalStateException|"+
+ "InterruptedException|NoSuchMethodException|IllegalAccessException|"+
+ "UnsupportedOperationException|Enum|StrictMath|Package|Compiler|"+
+ "Readable|Runtime|StringBuilder|Math|IncompatibleClassChangeError|"+
+ "NoSuchMethodError|ThreadLocal|RuntimePermission|ArithmeticException|"+
+ "NullPointerException|Long|Integer|Short|Byte|Double|Number|Float|"+
+ "Character|Boolean|StackTraceElement|Appendable|StringBuffer|"+
+ "Iterable|ThreadGroup|Runnable|Thread|IllegalMonitorStateException|"+
+ "StackOverflowError|OutOfMemoryError|VirtualMachineError|"+
+ "ArrayStoreException|ClassCastException|LinkageError|"+
+ "NoClassDefFoundError|ClassNotFoundException|RuntimeException|"+
+ "Exception|ThreadDeath|Error|Throwable|System|ClassLoader|"+
+ "Cloneable|Class|CharSequence|Comparable|String|Object"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": langClasses
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : /0(?:[xX][0-9a-fA-F][0-9a-fA-F_]*|[bB][01][01_]*)[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.numeric", // float
+ regex : /[+-]?\d[\d_]*(?:(?:\.[\d_]*)?(?:[eE][+-]?[\d_]+)?)?[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(JavaHighlightRules, TextHighlightRules);
+
+exports.JavaHighlightRules = JavaHighlightRules;
+});
+
+ace.define("ace/mode/jsp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/java_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var JavaHighlightRules = require("./java_highlight_rules").JavaHighlightRules;
+
+var JspHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var builtinVariables = 'request|response|out|session|' +
+ 'application|config|pageContext|page|Exception';
+
+ var keywords = 'page|include|taglib';
+
+ var startRules = [
+ {
+ token : "comment",
+ regex : "<%--",
+ push : "jsp-dcomment"
+ }, {
+ token : "meta.tag", // jsp open tag
+ regex : "<%@?|<%=?|<%!?|<jsp:[^>]+>",
+ push : "jsp-start"
+ }
+ ];
+
+ var endRules = [
+ {
+ token : "meta.tag", // jsp close tag
+ regex : "%>|<\\/jsp:[^>]+>",
+ next : "pop"
+ }, {
+ token: "variable.language",
+ regex : builtinVariables
+ }, {
+ token: "keyword",
+ regex : keywords
+ }
+ ];
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], startRules);
+
+ this.embedRules(JavaHighlightRules, "jsp-", endRules, ["start"]);
+
+ this.addRules({
+ "jsp-dcomment" : [{
+ token : "comment",
+ regex : ".*?--%>",
+ next : "pop"
+ }]
+ });
+
+ this.normalizeRules();
+};
+
+oop.inherits(JspHighlightRules, HtmlHighlightRules);
+
+exports.JspHighlightRules = JspHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/jsp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/jsp_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JspHighlightRules = require("./jsp_highlight_rules").JspHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JspHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.$id = "ace/mode/jsp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-jsx.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-jsx.js
new file mode 100644
index 00000000..3f3d3e4b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-jsx.js
@@ -0,0 +1,404 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/jsx_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JsxHighlightRules = function() {
+ var keywords = lang.arrayToMap(
+ ("break|do|instanceof|typeof|case|else|new|var|catch|finally|return|void|continue|for|switch|default|while|function|this|" +
+ "if|throw|" +
+ "delete|in|try|" +
+ "class|extends|super|import|from|into|implements|interface|static|mixin|override|abstract|final|" +
+ "number|int|string|boolean|variant|" +
+ "log|assert").split("|")
+ );
+
+ var buildinConstants = lang.arrayToMap(
+ ("null|true|false|NaN|Infinity|__FILE__|__LINE__|undefined").split("|")
+ );
+
+ var reserved = lang.arrayToMap(
+ ("debugger|with|" +
+ "const|export|" +
+ "let|private|public|yield|protected|" +
+ "extern|native|as|operator|__fake__|__readonly__").split("|")
+ );
+
+ var identifierRe = "[a-zA-Z_][a-zA-Z0-9_]*\\b";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : [
+ "storage.type",
+ "text",
+ "entity.name.function"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")"
+ }, {
+ token : function(value) {
+ if (value == "this")
+ return "variable.language";
+ else if (value == "function")
+ return "storage.type";
+ else if (keywords.hasOwnProperty(value) || reserved.hasOwnProperty(value))
+ return "keyword";
+ else if (buildinConstants.hasOwnProperty(value))
+ return "constant.language";
+ else if (/^_?[A-Z][a-zA-Z0-9_]*$/.test(value))
+ return "language.support.class";
+ else
+ return "identifier";
+ },
+ regex : identifierRe
+ }, {
+ token : "keyword.operator",
+ regex : "!|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|==|=|!=|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({<]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}>]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(JsxHighlightRules, TextHighlightRules);
+
+exports.JsxHighlightRules = JsxHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/jsx",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/jsx_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JsxHighlightRules = require("./jsx_highlight_rules").JsxHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+function Mode() {
+ this.HighlightRules = JsxHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+}
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/jsx";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-julia.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-julia.js
new file mode 100644
index 00000000..ee1e88ab
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-julia.js
@@ -0,0 +1,296 @@
+ace.define("ace/mode/julia_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JuliaHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { include: '#function_decl' },
+ { include: '#function_call' },
+ { include: '#type_decl' },
+ { include: '#keyword' },
+ { include: '#operator' },
+ { include: '#number' },
+ { include: '#string' },
+ { include: '#comment' } ],
+ '#bracket':
+ [ { token: 'keyword.bracket.julia',
+ regex: '\\(|\\)|\\[|\\]|\\{|\\}|,' } ],
+ '#comment':
+ [ { token:
+ [ 'punctuation.definition.comment.julia',
+ 'comment.line.number-sign.julia' ],
+ regex: '(#)(?!\\{)(.*$)'} ],
+ '#function_call':
+ [ { token: [ 'support.function.julia', 'text' ],
+ regex: '([a-zA-Z0-9_]+!?)([\\w\\xff-\\u218e\\u2455-\\uffff]*\\()'} ],
+ '#function_decl':
+ [ { token: [ 'keyword.other.julia', 'meta.function.julia',
+ 'entity.name.function.julia', 'meta.function.julia','text' ],
+ regex: '(function|macro)(\\s*)([a-zA-Z0-9_\\{]+!?)([\\w\\xff-\\u218e\\u2455-\\uffff]*)([(\\\\{])'} ],
+ '#keyword':
+ [ { token: 'keyword.other.julia',
+ regex: '\\b(?:function|type|immutable|macro|quote|abstract|bitstype|typealias|module|baremodule|new)\\b' },
+ { token: 'keyword.control.julia',
+ regex: '\\b(?:if|else|elseif|while|for|in|begin|let|end|do|try|catch|finally|return|break|continue)\\b' },
+ { token: 'storage.modifier.variable.julia',
+ regex: '\\b(?:global|local|const|export|import|importall|using)\\b' },
+ { token: 'variable.macro.julia', regex: '@[\\w\\xff-\\u218e\\u2455-\\uffff]+\\b' } ],
+ '#number':
+ [ { token: 'constant.numeric.julia',
+ regex: '\\b0(?:x|X)[0-9a-fA-F]*|(?:\\b[0-9]+\\.?[0-9]*|\\.[0-9]+)(?:(?:e|E)(?:\\+|-)?[0-9]*)?(?:im)?|\\bInf(?:32)?\\b|\\bNaN(?:32)?\\b|\\btrue\\b|\\bfalse\\b' } ],
+ '#operator':
+ [ { token: 'keyword.operator.update.julia',
+ regex: '=|:=|\\+=|-=|\\*=|/=|//=|\\.//=|\\.\\*=|\\\\=|\\.\\\\=|^=|\\.^=|%=|\\|=|&=|\\$=|<<=|>>=' },
+ { token: 'keyword.operator.ternary.julia', regex: '\\?|:' },
+ { token: 'keyword.operator.boolean.julia',
+ regex: '\\|\\||&&|!' },
+ { token: 'keyword.operator.arrow.julia', regex: '->|<-|-->' },
+ { token: 'keyword.operator.relation.julia',
+ regex: '>|<|>=|<=|==|!=|\\.>|\\.<|\\.>=|\\.>=|\\.==|\\.!=|\\.=|\\.!|<:|:>' },
+ { token: 'keyword.operator.range.julia', regex: ':' },
+ { token: 'keyword.operator.shift.julia', regex: '<<|>>' },
+ { token: 'keyword.operator.bitwise.julia', regex: '\\||\\&|~' },
+ { token: 'keyword.operator.arithmetic.julia',
+ regex: '\\+|-|\\*|\\.\\*|/|\\./|//|\\.//|%|\\.%|\\\\|\\.\\\\|\\^|\\.\\^' },
+ { token: 'keyword.operator.isa.julia', regex: '::' },
+ { token: 'keyword.operator.dots.julia',
+ regex: '\\.(?=[a-zA-Z])|\\.\\.+' },
+ { token: 'keyword.operator.interpolation.julia',
+ regex: '\\$#?(?=.)' },
+ { token: [ 'variable', 'keyword.operator.transposed-variable.julia' ],
+ regex: '([\\w\\xff-\\u218e\\u2455-\\uffff]+)((?:\'|\\.\')*\\.?\')' },
+ { token: 'text',
+ regex: '\\[|\\('},
+ { token: [ 'text', 'keyword.operator.transposed-matrix.julia' ],
+ regex: "([\\]\\)])((?:'|\\.')*\\.?')"} ],
+ '#string':
+ [ { token: 'punctuation.definition.string.begin.julia',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.julia',
+ regex: '\'',
+ next: 'pop' },
+ { include: '#string_escaped_char' },
+ { defaultToken: 'string.quoted.single.julia' } ] },
+ { token: 'punctuation.definition.string.begin.julia',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.julia',
+ regex: '"',
+ next: 'pop' },
+ { include: '#string_escaped_char' },
+ { defaultToken: 'string.quoted.double.julia' } ] },
+ { token: 'punctuation.definition.string.begin.julia',
+ regex: '\\b[\\w\\xff-\\u218e\\u2455-\\uffff]+"',
+ push:
+ [ { token: 'punctuation.definition.string.end.julia',
+ regex: '"[\\w\\xff-\\u218e\\u2455-\\uffff]*',
+ next: 'pop' },
+ { include: '#string_custom_escaped_char' },
+ { defaultToken: 'string.quoted.custom-double.julia' } ] },
+ { token: 'punctuation.definition.string.begin.julia',
+ regex: '`',
+ push:
+ [ { token: 'punctuation.definition.string.end.julia',
+ regex: '`',
+ next: 'pop' },
+ { include: '#string_escaped_char' },
+ { defaultToken: 'string.quoted.backtick.julia' } ] } ],
+ '#string_custom_escaped_char': [ { token: 'constant.character.escape.julia', regex: '\\\\"' } ],
+ '#string_escaped_char':
+ [ { token: 'constant.character.escape.julia',
+ regex: '\\\\(?:\\\\|[0-3]\\d{,2}|[4-7]\\d?|x[a-fA-F0-9]{,2}|u[a-fA-F0-9]{,4}|U[a-fA-F0-9]{,8}|.)' } ],
+ '#type_decl':
+ [ { token:
+ [ 'keyword.control.type.julia',
+ 'meta.type.julia',
+ 'entity.name.type.julia',
+ 'entity.other.inherited-class.julia',
+ 'punctuation.separator.inheritance.julia',
+ 'entity.other.inherited-class.julia' ],
+ regex: '(type|immutable)(\\s+)([a-zA-Z0-9_]+)(?:(\\s*)(<:)(\\s*[.a-zA-Z0-9_:]+))?' },
+ { token: [ 'other.typed-variable.julia', 'support.type.julia' ],
+ regex: '([a-zA-Z0-9_]+)(::[a-zA-Z0-9_{}]+)' } ] }
+
+ this.normalizeRules();
+};
+
+JuliaHighlightRules.metaData = { fileTypes: [ 'jl' ],
+ firstLineMatch: '^#!.*\\bjulia\\s*$',
+ foldingStartMarker: '^\\s*(?:if|while|for|begin|function|macro|module|baremodule|type|immutable|let)\\b(?!.*\\bend\\b).*$',
+ foldingStopMarker: '^\\s*(?:end)\\b.*$',
+ name: 'Julia',
+ scopeName: 'source.julia' }
+
+
+oop.inherits(JuliaHighlightRules, TextHighlightRules);
+
+exports.JuliaHighlightRules = JuliaHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/julia",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/julia_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JuliaHighlightRules = require("./julia_highlight_rules").JuliaHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JuliaHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.blockComment = "";
+ this.$id = "ace/mode/julia";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-kotlin.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-kotlin.js
new file mode 100644
index 00000000..2621bae8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-kotlin.js
@@ -0,0 +1,786 @@
+ace.define("ace/mode/kotlin_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var KotlinHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ include: "#comments"
+ }, {
+ token: [
+ "text",
+ "keyword.other.kotlin",
+ "text",
+ "entity.name.package.kotlin",
+ "text"
+ ],
+ regex: /^(\s*)(package)\b(?:(\s*)([^ ;$]+)(\s*))?/
+ }, {
+ include: "#imports"
+ }, {
+ include: "#statements"
+ }],
+ "#classes": [{
+ token: "text",
+ regex: /(?=\s*(?:companion|class|object|interface))/,
+ push: [{
+ token: "text",
+ regex: /}|(?=$)/,
+ next: "pop"
+ }, {
+ token: ["keyword.other.kotlin", "text"],
+ regex: /\b((?:companion\s*)?)(class|object|interface)\b/,
+ push: [{
+ token: "text",
+ regex: /(?=<|{|\(|:)/,
+ next: "pop"
+ }, {
+ token: "keyword.other.kotlin",
+ regex: /\bobject\b/
+ }, {
+ token: "entity.name.type.class.kotlin",
+ regex: /\w+/
+ }]
+ }, {
+ token: "text",
+ regex: /</,
+ push: [{
+ token: "text",
+ regex: />/,
+ next: "pop"
+ }, {
+ include: "#generics"
+ }]
+ }, {
+ token: "text",
+ regex: /\(/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#parameters"
+ }]
+ }, {
+ token: "keyword.operator.declaration.kotlin",
+ regex: /:/,
+ push: [{
+ token: "text",
+ regex: /(?={|$)/,
+ next: "pop"
+ }, {
+ token: "entity.other.inherited-class.kotlin",
+ regex: /\w+/
+ }, {
+ token: "text",
+ regex: /\(/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }]
+ }, {
+ token: "text",
+ regex: /\{/,
+ push: [{
+ token: "text",
+ regex: /\}/,
+ next: "pop"
+ }, {
+ include: "#statements"
+ }]
+ }]
+ }],
+ "#comments": [{
+ token: "punctuation.definition.comment.kotlin",
+ regex: /\/\*/,
+ push: [{
+ token: "punctuation.definition.comment.kotlin",
+ regex: /\*\//,
+ next: "pop"
+ }, {
+ defaultToken: "comment.block.kotlin"
+ }]
+ }, {
+ token: [
+ "text",
+ "punctuation.definition.comment.kotlin",
+ "comment.line.double-slash.kotlin"
+ ],
+ regex: /(\s*)(\/\/)(.*$)/
+ }],
+ "#constants": [{
+ token: "constant.language.kotlin",
+ regex: /\b(?:true|false|null|this|super)\b/
+ }, {
+ token: "constant.numeric.kotlin",
+ regex: /\b(?:0(?:x|X)[0-9a-fA-F]*|(?:[0-9]+\.?[0-9]*|\.[0-9]+)(?:(?:e|E)(?:\+|-)?[0-9]+)?)(?:[LlFfUuDd]|UL|ul)?\b/
+ }, {
+ token: "constant.other.kotlin",
+ regex: /\b[A-Z][A-Z0-9_]+\b/
+ }],
+ "#expressions": [{
+ token: "text",
+ regex: /\(/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }, {
+ include: "#types"
+ }, {
+ include: "#strings"
+ }, {
+ include: "#constants"
+ }, {
+ include: "#comments"
+ }, {
+ include: "#keywords"
+ }],
+ "#functions": [{
+ token: "text",
+ regex: /(?=\s*fun)/,
+ push: [{
+ token: "text",
+ regex: /}|(?=$)/,
+ next: "pop"
+ }, {
+ token: "keyword.other.kotlin",
+ regex: /\bfun\b/,
+ push: [{
+ token: "text",
+ regex: /(?=\()/,
+ next: "pop"
+ }, {
+ token: "text",
+ regex: /</,
+ push: [{
+ token: "text",
+ regex: />/,
+ next: "pop"
+ }, {
+ include: "#generics"
+ }]
+ }, {
+ token: ["text", "entity.name.function.kotlin"],
+ regex: /((?:[\.<\?>\w]+\.)?)(\w+)/
+ }]
+ }, {
+ token: "text",
+ regex: /\(/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#parameters"
+ }]
+ }, {
+ token: "keyword.operator.declaration.kotlin",
+ regex: /:/,
+ push: [{
+ token: "text",
+ regex: /(?={|=|$)/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }]
+ }, {
+ token: "text",
+ regex: /\{/,
+ push: [{
+ token: "text",
+ regex: /(?=\})/,
+ next: "pop"
+ }, {
+ include: "#statements"
+ }]
+ }, {
+ token: "keyword.operator.assignment.kotlin",
+ regex: /=/,
+ push: [{
+ token: "text",
+ regex: /(?=$)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }]
+ }],
+ "#generics": [{
+ token: "keyword.operator.declaration.kotlin",
+ regex: /:/,
+ push: [{
+ token: "text",
+ regex: /(?=,|>)/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }]
+ }, {
+ include: "#keywords"
+ }, {
+ token: "storage.type.generic.kotlin",
+ regex: /\w+/
+ }],
+ "#getters-and-setters": [{
+ token: ["entity.name.function.kotlin", "text"],
+ regex: /\b(get)\b(\s*\(\s*\))/,
+ push: [{
+ token: "text",
+ regex: /\}|(?=\bset\b)|$/,
+ next: "pop"
+ }, {
+ token: "keyword.operator.assignment.kotlin",
+ regex: /=/,
+ push: [{
+ token: "text",
+ regex: /(?=$|\bset\b)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }, {
+ token: "text",
+ regex: /\{/,
+ push: [{
+ token: "text",
+ regex: /\}/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }]
+ }, {
+ token: ["entity.name.function.kotlin", "text"],
+ regex: /\b(set)\b(\s*)(?=\()/,
+ push: [{
+ token: "text",
+ regex: /\}|(?=\bget\b)|$/,
+ next: "pop"
+ }, {
+ token: "text",
+ regex: /\(/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#parameters"
+ }]
+ }, {
+ token: "keyword.operator.assignment.kotlin",
+ regex: /=/,
+ push: [{
+ token: "text",
+ regex: /(?=$|\bset\b)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }, {
+ token: "text",
+ regex: /\{/,
+ push: [{
+ token: "text",
+ regex: /\}/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }]
+ }],
+ "#imports": [{
+ token: [
+ "text",
+ "keyword.other.kotlin",
+ "text",
+ "keyword.other.kotlin"
+ ],
+ regex: /^(\s*)(import)(\s+[^ $]+\s+)((?:as)?)/
+ }],
+ "#keywords": [{
+ token: "storage.modifier.kotlin",
+ regex: /\b(?:var|val|public|private|protected|abstract|final|enum|open|attribute|annotation|override|inline|var|val|vararg|lazy|in|out|internal|data|tailrec|operator|infix|const|yield|typealias|typeof)\b/
+ }, {
+ token: "keyword.control.catch-exception.kotlin",
+ regex: /\b(?:try|catch|finally|throw)\b/
+ }, {
+ token: "keyword.control.kotlin",
+ regex: /\b(?:if|else|while|for|do|return|when|where|break|continue)\b/
+ }, {
+ token: "keyword.operator.kotlin",
+ regex: /\b(?:in|is|as|assert)\b/
+ }, {
+ token: "keyword.operator.comparison.kotlin",
+ regex: /==|!=|===|!==|<=|>=|<|>/
+ }, {
+ token: "keyword.operator.assignment.kotlin",
+ regex: /=/
+ }, {
+ token: "keyword.operator.declaration.kotlin",
+ regex: /:/
+ }, {
+ token: "keyword.operator.dot.kotlin",
+ regex: /\./
+ }, {
+ token: "keyword.operator.increment-decrement.kotlin",
+ regex: /\-\-|\+\+/
+ }, {
+ token: "keyword.operator.arithmetic.kotlin",
+ regex: /\-|\+|\*|\/|%/
+ }, {
+ token: "keyword.operator.arithmetic.assign.kotlin",
+ regex: /\+=|\-=|\*=|\/=/
+ }, {
+ token: "keyword.operator.logical.kotlin",
+ regex: /!|&&|\|\|/
+ }, {
+ token: "keyword.operator.range.kotlin",
+ regex: /\.\./
+ }, {
+ token: "punctuation.terminator.kotlin",
+ regex: /;/
+ }],
+ "#namespaces": [{
+ token: "keyword.other.kotlin",
+ regex: /\bnamespace\b/
+ }, {
+ token: "text",
+ regex: /\{/,
+ push: [{
+ token: "text",
+ regex: /\}/,
+ next: "pop"
+ }, {
+ include: "#statements"
+ }]
+ }],
+ "#parameters": [{
+ token: "keyword.operator.declaration.kotlin",
+ regex: /:/,
+ push: [{
+ token: "text",
+ regex: /(?=,|\)|=)/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }]
+ }, {
+ token: "keyword.operator.declaration.kotlin",
+ regex: /=/,
+ push: [{
+ token: "text",
+ regex: /(?=,|\))/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }, {
+ include: "#keywords"
+ }, {
+ token: "variable.parameter.function.kotlin",
+ regex: /\w+/
+ }],
+ "#statements": [{
+ include: "#namespaces"
+ }, {
+ include: "#typedefs"
+ }, {
+ include: "#classes"
+ }, {
+ include: "#functions"
+ }, {
+ include: "#variables"
+ }, {
+ include: "#getters-and-setters"
+ }, {
+ include: "#expressions"
+ }],
+ "#strings": [{
+ token: "punctuation.definition.string.begin.kotlin",
+ regex: /"""/,
+ push: [{
+ token: "punctuation.definition.string.end.kotlin",
+ regex: /"""/,
+ next: "pop"
+ }, {
+ token: "variable.parameter.template.kotlin",
+ regex: /\$\w+|\$\{[^\}]+\}/
+ }, {
+ token: "constant.character.escape.kotlin",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.third.kotlin"
+ }]
+ }, {
+ token: "punctuation.definition.string.begin.kotlin",
+ regex: /"/,
+ push: [{
+ token: "punctuation.definition.string.end.kotlin",
+ regex: /"/,
+ next: "pop"
+ }, {
+ token: "variable.parameter.template.kotlin",
+ regex: /\$\w+|\$\{[^\}]+\}/
+ }, {
+ token: "constant.character.escape.kotlin",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.double.kotlin"
+ }]
+ }, {
+ token: "punctuation.definition.string.begin.kotlin",
+ regex: /'/,
+ push: [{
+ token: "punctuation.definition.string.end.kotlin",
+ regex: /'/,
+ next: "pop"
+ }, {
+ token: "constant.character.escape.kotlin",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.single.kotlin"
+ }]
+ }, {
+ token: "punctuation.definition.string.begin.kotlin",
+ regex: /`/,
+ push: [{
+ token: "punctuation.definition.string.end.kotlin",
+ regex: /`/,
+ next: "pop"
+ }, {
+ defaultToken: "string.quoted.single.kotlin"
+ }]
+ }],
+ "#typedefs": [{
+ token: "text",
+ regex: /(?=\s*type)/,
+ push: [{
+ token: "text",
+ regex: /(?=$)/,
+ next: "pop"
+ }, {
+ token: "keyword.other.kotlin",
+ regex: /\btype\b/
+ }, {
+ token: "text",
+ regex: /</,
+ push: [{
+ token: "text",
+ regex: />/,
+ next: "pop"
+ }, {
+ include: "#generics"
+ }]
+ }, {
+ include: "#expressions"
+ }]
+ }],
+ "#types": [{
+ token: "storage.type.buildin.kotlin",
+ regex: /\b(?:Any|Unit|String|Int|Boolean|Char|Long|Double|Float|Short|Byte|dynamic)\b/
+ }, {
+ token: "storage.type.buildin.array.kotlin",
+ regex: /\b(?:IntArray|BooleanArray|CharArray|LongArray|DoubleArray|FloatArray|ShortArray|ByteArray)\b/
+ }, {
+ token: [
+ "storage.type.buildin.collection.kotlin",
+ "text"
+ ],
+ regex: /\b(Array|List|Map)(<\b)/,
+ push: [{
+ token: "text",
+ regex: />/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }, {
+ include: "#keywords"
+ }]
+ }, {
+ token: "text",
+ regex: /\w+</,
+ push: [{
+ token: "text",
+ regex: />/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }, {
+ include: "#keywords"
+ }]
+ }, {
+ token: ["keyword.operator.tuple.kotlin", "text"],
+ regex: /(#)(\()/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }]
+ }, {
+ token: "text",
+ regex: /\{/,
+ push: [{
+ token: "text",
+ regex: /\}/,
+ next: "pop"
+ }, {
+ include: "#statements"
+ }]
+ }, {
+ token: "text",
+ regex: /\(/,
+ push: [{
+ token: "text",
+ regex: /\)/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }]
+ }, {
+ token: "keyword.operator.declaration.kotlin",
+ regex: /->/
+ }],
+ "#variables": [{
+ token: "text",
+ regex: /(?=\s*(?:var|val))/,
+ push: [{
+ token: "text",
+ regex: /(?=:|=|$)/,
+ next: "pop"
+ }, {
+ token: "keyword.other.kotlin",
+ regex: /\b(?:var|val)\b/,
+ push: [{
+ token: "text",
+ regex: /(?=:|=|$)/,
+ next: "pop"
+ }, {
+ token: "text",
+ regex: /</,
+ push: [{
+ token: "text",
+ regex: />/,
+ next: "pop"
+ }, {
+ include: "#generics"
+ }]
+ }, {
+ token: ["text", "entity.name.variable.kotlin"],
+ regex: /((?:[\.<\?>\w]+\.)?)(\w+)/
+ }]
+ }, {
+ token: "keyword.operator.declaration.kotlin",
+ regex: /:/,
+ push: [{
+ token: "text",
+ regex: /(?==|$)/,
+ next: "pop"
+ }, {
+ include: "#types"
+ }, {
+ include: "#getters-and-setters"
+ }]
+ }, {
+ token: "keyword.operator.assignment.kotlin",
+ regex: /=/,
+ push: [{
+ token: "text",
+ regex: /(?=$)/,
+ next: "pop"
+ }, {
+ include: "#expressions"
+ }, {
+ include: "#getters-and-setters"
+ }]
+ }]
+ }]
+ }
+
+ this.normalizeRules();
+};
+
+KotlinHighlightRules.metaData = {
+ fileTypes: ["kt", "kts"],
+ name: "Kotlin",
+ scopeName: "source.Kotlin"
+}
+
+
+oop.inherits(KotlinHighlightRules, TextHighlightRules);
+
+exports.KotlinHighlightRules = KotlinHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/kotlin",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/kotlin_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var KotlinHighlightRules = require("./kotlin_highlight_rules").KotlinHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = KotlinHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$id = "ace/mode/kotlin"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-latex.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-latex.js
new file mode 100644
index 00000000..db79d0a5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-latex.js
@@ -0,0 +1,289 @@
+ace.define("ace/mode/latex_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LatexHighlightRules = function() {
+
+ this.$rules = {
+ "start" : [{
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : ["keyword", "lparen", "variable.parameter", "rparen", "lparen", "storage.type", "rparen"],
+ regex : "(\\\\(?:documentclass|usepackage|input))(?:(\\[)([^\\]]*)(\\]))?({)([^}]*)(})"
+ }, {
+ token : ["keyword","lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\(?:label|v?ref|cite(?:[^{]*)))(?:({)([^}]*)(}))?"
+ }, {
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\begin)({)(verbatim)(})",
+ next : "verbatim"
+ }, {
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\begin)({)(lstlisting)(})",
+ next : "lstlisting"
+ }, {
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\(?:begin|end))({)([\\w*]*)(})"
+ }, {
+ token : "storage.type",
+ regex : /\\verb\b\*?/,
+ next : [{
+ token : ["keyword.operator", "string", "keyword.operator"],
+ regex : "(.)(.*?)(\\1|$)|",
+ next : "start"
+ }]
+ }, {
+ token : "storage.type",
+ regex : "\\\\[a-zA-Z]+"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "constant.character.escape",
+ regex : "\\\\[^a-zA-Z]?"
+ }, {
+ token : "string",
+ regex : "\\${1,2}",
+ next : "equation"
+ }],
+ "equation" : [{
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : "string",
+ regex : "\\${1,2}",
+ next : "start"
+ }, {
+ token : "constant.character.escape",
+ regex : "\\\\(?:[^a-zA-Z]|[a-zA-Z]+)"
+ }, {
+ token : "error",
+ regex : "^\\s*$",
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }],
+ "verbatim": [{
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\end)({)(verbatim)(})",
+ next : "start"
+ }, {
+ defaultToken : "text"
+ }],
+ "lstlisting": [{
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\end)({)(lstlisting)(})",
+ next : "start"
+ }, {
+ defaultToken : "text"
+ }]
+ };
+
+ this.normalizeRules();
+};
+oop.inherits(LatexHighlightRules, TextHighlightRules);
+
+exports.LatexHighlightRules = LatexHighlightRules;
+
+});
+
+ace.define("ace/mode/folding/latex",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var keywordLevels = {
+ "\\subparagraph": 1,
+ "\\paragraph": 2,
+ "\\subsubsubsection": 3,
+ "\\subsubsection": 4,
+ "\\subsection": 5,
+ "\\section": 6,
+ "\\chapter": 7,
+ "\\part": 8,
+ "\\begin": 9,
+ "\\end": 10
+};
+
+var FoldMode = exports.FoldMode = function() {};
+
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /^\s*\\(begin)|\s*\\(part|chapter|(?:sub)*(?:section|paragraph))\b|{\s*$/;
+ this.foldingStopMarker = /^\s*\\(end)\b|^\s*}/;
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.doc.getLine(row);
+ var match = this.foldingStartMarker.exec(line);
+ if (match) {
+ if (match[1])
+ return this.latexBlock(session, row, match[0].length - 1);
+ if (match[2])
+ return this.latexSection(session, row, match[0].length - 1);
+
+ return this.openingBracketBlock(session, "{", row, match.index);
+ }
+
+ var match = this.foldingStopMarker.exec(line);
+ if (match) {
+ if (match[1])
+ return this.latexBlock(session, row, match[0].length - 1);
+
+ return this.closingBracketBlock(session, "}", row, match.index + match[0].length);
+ }
+ };
+
+ this.latexBlock = function(session, row, column, returnRange) {
+ var keywords = {
+ "\\begin": 1,
+ "\\end": -1
+ };
+
+ var stream = new TokenIterator(session, row, column);
+ var token = stream.getCurrentToken();
+ if (!token || !(token.type == "storage.type" || token.type == "constant.character.escape"))
+ return;
+
+ var val = token.value;
+ var dir = keywords[val];
+
+ var getType = function() {
+ var token = stream.stepForward();
+ var type = token.type == "lparen" ?stream.stepForward().value : "";
+ if (dir === -1) {
+ stream.stepBackward();
+ if (type)
+ stream.stepBackward();
+ }
+ return type;
+ };
+ var stack = [getType()];
+ var startColumn = dir === -1 ? stream.getCurrentTokenColumn() : session.getLine(row).length;
+ var startRow = row;
+
+ stream.step = dir === -1 ? stream.stepBackward : stream.stepForward;
+ while(token = stream.step()) {
+ if (!token || !(token.type == "storage.type" || token.type == "constant.character.escape"))
+ continue;
+ var level = keywords[token.value];
+ if (!level)
+ continue;
+ var type = getType();
+ if (level === dir)
+ stack.unshift(type);
+ else if (stack.shift() !== type || !stack.length)
+ break;
+ }
+
+ if (stack.length)
+ return;
+
+ if (dir == 1) {
+ stream.stepBackward();
+ stream.stepBackward();
+ }
+
+ if (returnRange)
+ return stream.getCurrentTokenRange();
+
+ var row = stream.getCurrentTokenRow();
+ if (dir === -1)
+ return new Range(row, session.getLine(row).length, startRow, startColumn);
+ else
+ return new Range(startRow, startColumn, row, stream.getCurrentTokenColumn());
+ };
+
+ this.latexSection = function(session, row, column) {
+ var stream = new TokenIterator(session, row, column);
+ var token = stream.getCurrentToken();
+ if (!token || token.type != "storage.type")
+ return;
+
+ var startLevel = keywordLevels[token.value] || 0;
+ var stackDepth = 0
+ var endRow = row;
+
+ while(token = stream.stepForward()) {
+ if (token.type !== "storage.type")
+ continue;
+ var level = keywordLevels[token.value] || 0;
+
+ if (level >= 9) {
+ if (!stackDepth)
+ endRow = stream.getCurrentTokenRow() - 1;
+ stackDepth += level == 9 ? 1 : - 1;
+ if (stackDepth < 0)
+ break
+ } else if (level >= startLevel)
+ break;
+ }
+
+ if (!stackDepth)
+ endRow = stream.getCurrentTokenRow() - 1;
+
+ while (endRow > row && !/\S/.test(session.getLine(endRow)))
+ endRow--;
+
+ return new Range(
+ row, session.getLine(row).length,
+ endRow, session.getLine(endRow).length
+ );
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/latex",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/latex_highlight_rules","ace/mode/behaviour/cstyle","ace/mode/folding/latex"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LatexHighlightRules = require("./latex_highlight_rules").LatexHighlightRules;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var LatexFoldMode = require("./folding/latex").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = LatexHighlightRules;
+ this.foldingRules = new LatexFoldMode();
+ this.$behaviour = new CstyleBehaviour({ braces: true });
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.type = "text";
+
+ this.lineCommentStart = "%";
+
+ this.$id = "ace/mode/latex";
+
+ this.getMatching = function(session, row, column) {
+ if (row == undefined)
+ row = session.selection.lead
+ if (typeof row == "object") {
+ column = row.column;
+ row = row.row;
+ }
+
+ var startToken = session.getTokenAt(row, column);
+ if (!startToken)
+ return;
+ if (startToken.value == "\\begin" || startToken.value == "\\end") {
+ return this.foldingRules.latexBlock(session, row, column, true);
+ }
+ };
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-less.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-less.js
new file mode 100644
index 00000000..c407a097
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-less.js
@@ -0,0 +1,819 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/less_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/css_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var CssHighlightRules = require('./css_highlight_rules');
+
+var LessHighlightRules = function() {
+
+
+ var keywordList = "@import|@media|@font-face|@keyframes|@-webkit-keyframes|@supports|" +
+ "@charset|@plugin|@namespace|@document|@page|@viewport|@-ms-viewport|" +
+ "or|and|when|not";
+
+ var keywords = keywordList.split('|');
+
+ var properties = CssHighlightRules.supportType.split('|');
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.constant": CssHighlightRules.supportConstant,
+ "keyword": keywordList,
+ "support.constant.color": CssHighlightRules.supportConstantColor,
+ "support.constant.fonts": CssHighlightRules.supportConstantFonts
+ }, "identifier", true);
+
+ var numRe = "\\-?(?:(?:[0-9]+)|(?:[0-9]*\\.[0-9]+))";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : ["support.function", "paren.lparen", "string", "paren.rparen"],
+ regex : "(url)(\\()(.*)(\\))"
+ }, {
+ token : ["support.function", "paren.lparen"],
+ regex : "(:extend|[a-z0-9_\\-]+)(\\()"
+ }, {
+ token : function(value) {
+ if (keywords.indexOf(value.toLowerCase()) > -1)
+ return "keyword";
+ else
+ return "variable";
+ },
+ regex : "[@\\$][a-z0-9_\\-@\\$]*\\b"
+ }, {
+ token : "variable",
+ regex : "[@\\$]\\{[a-z0-9_\\-@\\$]*\\}"
+ }, {
+ token : function(first, second) {
+ if(properties.indexOf(first.toLowerCase()) > -1) {
+ return ["support.type.property", "text"];
+ }
+ else {
+ return ["support.type.unknownProperty", "text"];
+ }
+ },
+ regex : "([a-z0-9-_]+)(\\s*:)"
+ }, {
+ token : "keyword",
+ regex : "&" // special case - always treat as keyword
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[@a-z_][@a-z0-9_\\-]*"
+ }, {
+ token: "variable.language",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: ":[a-z_][a-z0-9-_]*"
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ token : "keyword.operator",
+ regex : "<|>|<=|>=|=|!=|-|%|\\+|\\*"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ caseInsensitive: true
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+ this.normalizeRules();
+};
+
+oop.inherits(LessHighlightRules, TextHighlightRules);
+
+exports.LessHighlightRules = LessHighlightRules;
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/less",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/less_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/css","ace/mode/css_completions","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LessHighlightRules = require("./less_highlight_rules").LessHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CssCompletions = require("./css_completions").CssCompletions;
+
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = LessHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions("ruleset", session, pos, prefix);
+ };
+
+ this.$id = "ace/mode/less";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-liquid.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-liquid.js
new file mode 100644
index 00000000..925ef305
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-liquid.js
@@ -0,0 +1,1184 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/liquid_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var LiquidHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+ var functions = (
+ "date|capitalize|downcase|upcase|first|last|join|sort|map|size|escape|" +
+ "escape_once|strip_html|strip_newlines|newline_to_br|replace|replace_first|" +
+ "truncate|truncatewords|prepend|append|minus|plus|times|divided_by|split"
+ );
+
+ var keywords = (
+ "capture|endcapture|case|endcase|when|comment|endcomment|" +
+ "cycle|for|endfor|in|reversed|if|endif|else|elsif|include|endinclude|unless|endunless|" +
+ "style|text|image|widget|plugin|marker|endmarker|tablerow|endtablerow"
+ );
+
+ var builtinVariables = 'forloop|tablerowloop';
+
+ var definitions = ("assign");
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": builtinVariables,
+ "keyword": keywords,
+ "support.function": functions,
+ "keyword.definition": definitions
+ }, "identifier");
+ for (var rule in this.$rules) {
+ this.$rules[rule].unshift({
+ token : "variable",
+ regex : "{%",
+ push : "liquid-start"
+ }, {
+ token : "variable",
+ regex : "{{",
+ push : "liquid-start"
+ });
+ }
+
+ this.addRules({
+ "liquid-start" : [{
+ token: "variable",
+ regex: "}}",
+ next: "pop"
+ }, {
+ token: "variable",
+ regex: "%}",
+ next: "pop"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "/|\\*|\\-|\\+|=|!=|\\?\\:"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[\({]/
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }]
+ });
+
+ this.normalizeRules();
+};
+oop.inherits(LiquidHighlightRules, TextHighlightRules);
+
+exports.LiquidHighlightRules = LiquidHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/liquid",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/liquid_highlight_rules","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LiquidHighlightRules = require("./liquid_highlight_rules").LiquidHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ this.HighlightRules = LiquidHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/liquid";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-lisp.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-lisp.js
new file mode 100644
index 00000000..fb0897d9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-lisp.js
@@ -0,0 +1,105 @@
+ace.define("ace/mode/lisp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LispHighlightRules = function() {
+ var keywordControl = "case|do|let|loop|if|else|when";
+ var keywordOperator = "eq|neq|and|or";
+ var constantLanguage = "null|nil";
+ var supportFunctions = "cons|car|cdr|cond|lambda|format|setq|setf|quote|eval|append|list|listp|memberp|t|load|progn";
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword.control": keywordControl,
+ "keyword.operator": keywordOperator,
+ "constant.language": constantLanguage,
+ "support.function": supportFunctions
+ }, "identifier", true);
+
+ this.$rules =
+ {
+ "start": [
+ {
+ token : "comment",
+ regex : ";.*$"
+ },
+ {
+ token: ["storage.type.function-type.lisp", "text", "entity.name.function.lisp"],
+ regex: "(?:\\b(?:(defun|defmethod|defmacro))\\b)(\\s+)((?:\\w|\\-|\\!|\\?)*)"
+ },
+ {
+ token: ["punctuation.definition.constant.character.lisp", "constant.character.lisp"],
+ regex: "(#)((?:\\w|[\\\\+-=<>'\"&#])+)"
+ },
+ {
+ token: ["punctuation.definition.variable.lisp", "variable.other.global.lisp", "punctuation.definition.variable.lisp"],
+ regex: "(\\*)(\\S*)(\\*)"
+ },
+ {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(?:L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ },
+ {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(?:L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ },
+ {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ },
+ {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }
+ ],
+ "qqstring": [
+ {
+ token: "constant.character.escape.lisp",
+ regex: "\\\\."
+ },
+ {
+ token : "string",
+ regex : '[^"\\\\]+'
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }
+ ]
+}
+
+};
+
+oop.inherits(LispHighlightRules, TextHighlightRules);
+
+exports.LispHighlightRules = LispHighlightRules;
+});
+
+ace.define("ace/mode/lisp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/lisp_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LispHighlightRules = require("./lisp_highlight_rules").LispHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = LispHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ";";
+
+ this.$id = "ace/mode/lisp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-livescript.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-livescript.js
new file mode 100644
index 00000000..0e480a91
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-livescript.js
@@ -0,0 +1,271 @@
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/livescript",["require","exports","module","ace/tokenizer","ace/mode/matching_brace_outdent","ace/mode/text"], function(require, exports, module){
+ var identifier, LiveScriptMode, keywordend, stringfill;
+ identifier = '(?![\\d\\s])[$\\w\\xAA-\\uFFDC](?:(?!\\s)[$\\w\\xAA-\\uFFDC]|-[A-Za-z])*';
+ exports.Mode = LiveScriptMode = (function(superclass){
+ var indenter, prototype = extend$((import$(LiveScriptMode, superclass).displayName = 'LiveScriptMode', LiveScriptMode), superclass).prototype, constructor = LiveScriptMode;
+ function LiveScriptMode(){
+ var that;
+ this.$tokenizer = new (require('../tokenizer')).Tokenizer(LiveScriptMode.Rules);
+ if (that = require('../mode/matching_brace_outdent')) {
+ this.$outdent = new that.MatchingBraceOutdent;
+ }
+ this.$id = "ace/mode/livescript";
+ }
+ indenter = RegExp('(?:[({[=:]|[-~]>|\\b(?:e(?:lse|xport)|d(?:o|efault)|t(?:ry|hen)|finally|import(?:\\s*all)?|const|var|let|new|catch(?:\\s*' + identifier + ')?))\\s*$');
+ prototype.getNextLineIndent = function(state, line, tab){
+ var indent, tokens;
+ indent = this.$getIndent(line);
+ tokens = this.$tokenizer.getLineTokens(line, state).tokens;
+ if (!(tokens.length && tokens[tokens.length - 1].type === 'comment')) {
+ if (state === 'start' && indenter.test(line)) {
+ indent += tab;
+ }
+ }
+ return indent;
+ };
+ prototype.lineCommentStart = "#";
+ prototype.blockComment = {start: "###", end: "###"};
+ prototype.checkOutdent = function(state, line, input){
+ var ref$;
+ return (ref$ = this.$outdent) != null ? ref$.checkOutdent(line, input) : void 8;
+ };
+ prototype.autoOutdent = function(state, doc, row){
+ var ref$;
+ return (ref$ = this.$outdent) != null ? ref$.autoOutdent(doc, row) : void 8;
+ };
+ return LiveScriptMode;
+ }(require('../mode/text').Mode));
+ keywordend = '(?![$\\w]|-[A-Za-z]|\\s*:(?![:=]))';
+ stringfill = {
+ defaultToken: 'string'
+ };
+ LiveScriptMode.Rules = {
+ start: [
+ {
+ token: 'keyword',
+ regex: '(?:t(?:h(?:is|row|en)|ry|ypeof!?)|c(?:on(?:tinue|st)|a(?:se|tch)|lass)|i(?:n(?:stanceof)?|mp(?:ort(?:\\s+all)?|lements)|[fs])|d(?:e(?:fault|lete|bugger)|o)|f(?:or(?:\\s+own)?|inally|unction)|s(?:uper|witch)|e(?:lse|x(?:tends|port)|val)|a(?:nd|rguments)|n(?:ew|ot)|un(?:less|til)|w(?:hile|ith)|o[fr]|return|break|let|var|loop)' + keywordend
+ }, {
+ token: 'constant.language',
+ regex: '(?:true|false|yes|no|on|off|null|void|undefined)' + keywordend
+ }, {
+ token: 'invalid.illegal',
+ regex: '(?:p(?:ackage|r(?:ivate|otected)|ublic)|i(?:mplements|nterface)|enum|static|yield)' + keywordend
+ }, {
+ token: 'language.support.class',
+ regex: '(?:R(?:e(?:gExp|ferenceError)|angeError)|S(?:tring|yntaxError)|E(?:rror|valError)|Array|Boolean|Date|Function|Number|Object|TypeError|URIError)' + keywordend
+ }, {
+ token: 'language.support.function',
+ regex: '(?:is(?:NaN|Finite)|parse(?:Int|Float)|Math|JSON|(?:en|de)codeURI(?:Component)?)' + keywordend
+ }, {
+ token: 'variable.language',
+ regex: '(?:t(?:hat|il|o)|f(?:rom|allthrough)|it|by|e)' + keywordend
+ }, {
+ token: 'identifier',
+ regex: identifier + '\\s*:(?![:=])'
+ }, {
+ token: 'variable',
+ regex: identifier
+ }, {
+ token: 'keyword.operator',
+ regex: '(?:\\.{3}|\\s+\\?)'
+ }, {
+ token: 'keyword.variable',
+ regex: '(?:@+|::|\\.\\.)',
+ next: 'key'
+ }, {
+ token: 'keyword.operator',
+ regex: '\\.\\s*',
+ next: 'key'
+ }, {
+ token: 'string',
+ regex: '\\\\\\S[^\\s,;)}\\]]*'
+ }, {
+ token: 'string.doc',
+ regex: '\'\'\'',
+ next: 'qdoc'
+ }, {
+ token: 'string.doc',
+ regex: '"""',
+ next: 'qqdoc'
+ }, {
+ token: 'string',
+ regex: '\'',
+ next: 'qstring'
+ }, {
+ token: 'string',
+ regex: '"',
+ next: 'qqstring'
+ }, {
+ token: 'string',
+ regex: '`',
+ next: 'js'
+ }, {
+ token: 'string',
+ regex: '<\\[',
+ next: 'words'
+ }, {
+ token: 'string.regex',
+ regex: '//',
+ next: 'heregex'
+ }, {
+ token: 'comment.doc',
+ regex: '/\\*',
+ next: 'comment'
+ }, {
+ token: 'comment',
+ regex: '#.*'
+ }, {
+ token: 'string.regex',
+ regex: '\\/(?:[^[\\/\\n\\\\]*(?:(?:\\\\.|\\[[^\\]\\n\\\\]*(?:\\\\.[^\\]\\n\\\\]*)*\\])[^[\\/\\n\\\\]*)*)\\/[gimy$]{0,4}',
+ next: 'key'
+ }, {
+ token: 'constant.numeric',
+ regex: '(?:0x[\\da-fA-F][\\da-fA-F_]*|(?:[2-9]|[12]\\d|3[0-6])r[\\da-zA-Z][\\da-zA-Z_]*|(?:\\d[\\d_]*(?:\\.\\d[\\d_]*)?|\\.\\d[\\d_]*)(?:e[+-]?\\d[\\d_]*)?[\\w$]*)'
+ }, {
+ token: 'lparen',
+ regex: '[({[]'
+ }, {
+ token: 'rparen',
+ regex: '[)}\\]]',
+ next: 'key'
+ }, {
+ token: 'keyword.operator',
+ regex: '[\\^!|&%+\\-]+'
+ }, {
+ token: 'text',
+ regex: '\\s+'
+ }
+ ],
+ heregex: [
+ {
+ token: 'string.regex',
+ regex: '.*?//[gimy$?]{0,4}',
+ next: 'start'
+ }, {
+ token: 'string.regex',
+ regex: '\\s*#{'
+ }, {
+ token: 'comment.regex',
+ regex: '\\s+(?:#.*)?'
+ }, {
+ defaultToken: 'string.regex'
+ }
+ ],
+ key: [
+ {
+ token: 'keyword.operator',
+ regex: '[.?@!]+'
+ }, {
+ token: 'identifier',
+ regex: identifier,
+ next: 'start'
+ }, {
+ token: 'text',
+ regex: '',
+ next: 'start'
+ }
+ ],
+ comment: [
+ {
+ token: 'comment.doc',
+ regex: '.*?\\*/',
+ next: 'start'
+ }, {
+ defaultToken: 'comment.doc'
+ }
+ ],
+ qdoc: [
+ {
+ token: 'string',
+ regex: ".*?'''",
+ next: 'key'
+ }, stringfill
+ ],
+ qqdoc: [
+ {
+ token: 'string',
+ regex: '.*?"""',
+ next: 'key'
+ }, stringfill
+ ],
+ qstring: [
+ {
+ token: 'string',
+ regex: '[^\\\\\']*(?:\\\\.[^\\\\\']*)*\'',
+ next: 'key'
+ }, stringfill
+ ],
+ qqstring: [
+ {
+ token: 'string',
+ regex: '[^\\\\"]*(?:\\\\.[^\\\\"]*)*"',
+ next: 'key'
+ }, stringfill
+ ],
+ js: [
+ {
+ token: 'string',
+ regex: '[^\\\\`]*(?:\\\\.[^\\\\`]*)*`',
+ next: 'key'
+ }, stringfill
+ ],
+ words: [
+ {
+ token: 'string',
+ regex: '.*?\\]>',
+ next: 'key'
+ }, stringfill
+ ]
+ };
+function extend$(sub, sup){
+ function fun(){} fun.prototype = (sub.superclass = sup).prototype;
+ (sub.prototype = new fun).constructor = sub;
+ if (typeof sup.extended == 'function') sup.extended(sub);
+ return sub;
+}
+function import$(obj, src){
+ var own = {}.hasOwnProperty;
+ for (var key in src) if (own.call(src, key)) obj[key] = src[key];
+ return obj;
+}
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-logiql.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-logiql.js
new file mode 100644
index 00000000..f4ea30d0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-logiql.js
@@ -0,0 +1,310 @@
+ace.define("ace/mode/logiql_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LogiQLHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token: 'comment.block',
+ regex: '/\\*',
+ push:
+ [ { token: 'comment.block', regex: '\\*/', next: 'pop' },
+ { defaultToken: 'comment.block' } ]
+ },
+ { token: 'comment.single',
+ regex: '//.*'
+ },
+ { token: 'constant.numeric',
+ regex: '\\d+(?:\\.\\d+)?(?:[eE][+-]?\\d+)?[fd]?'
+ },
+ { token: 'string',
+ regex: '"',
+ push:
+ [ { token: 'string', regex: '"', next: 'pop' },
+ { defaultToken: 'string' } ]
+ },
+ { token: 'constant.language',
+ regex: '\\b(true|false)\\b'
+ },
+ { token: 'entity.name.type.logicblox',
+ regex: '`[a-zA-Z_:]+(\\d|\\a)*\\b'
+ },
+ { token: 'keyword.start', regex: '->', comment: 'Constraint' },
+ { token: 'keyword.start', regex: '-->', comment: 'Level 1 Constraint'},
+ { token: 'keyword.start', regex: '<-', comment: 'Rule' },
+ { token: 'keyword.start', regex: '<--', comment: 'Level 1 Rule' },
+ { token: 'keyword.end', regex: '\\.', comment: 'Terminator' },
+ { token: 'keyword.other', regex: '!', comment: 'Negation' },
+ { token: 'keyword.other', regex: ',', comment: 'Conjunction' },
+ { token: 'keyword.other', regex: ';', comment: 'Disjunction' },
+ { token: 'keyword.operator', regex: '<=|>=|!=|<|>', comment: 'Equality'},
+ { token: 'keyword.other', regex: '@', comment: 'Equality' },
+ { token: 'keyword.operator', regex: '\\+|-|\\*|/', comment: 'Arithmetic operations'},
+ { token: 'keyword', regex: '::', comment: 'Colon colon' },
+ { token: 'support.function',
+ regex: '\\b(agg\\s*<<)',
+ push:
+ [ { include: '$self' },
+ { token: 'support.function',
+ regex: '>>',
+ next: 'pop' } ]
+ },
+ { token: 'storage.modifier',
+ regex: '\\b(lang:[\\w:]*)'
+ },
+ { token: [ 'storage.type', 'text' ],
+ regex: '(export|sealed|clauses|block|alias|alias_all)(\\s*\\()(?=`)'
+ },
+ { token: 'entity.name',
+ regex: '[a-zA-Z_][a-zA-Z_0-9:]*(@prev|@init|@final)?(?=(\\(|\\[))'
+ },
+ { token: 'variable.parameter',
+ regex: '([a-zA-Z][a-zA-Z_0-9]*|_)\\s*(?=(,|\\.|<-|->|\\)|\\]|=))'
+ } ] }
+
+ this.normalizeRules();
+};
+
+oop.inherits(LogiQLHighlightRules, TextHighlightRules);
+
+exports.LogiQLHighlightRules = LogiQLHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/logiql",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/logiql_highlight_rules","ace/mode/folding/coffee","ace/token_iterator","ace/range","ace/mode/behaviour/cstyle","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LogiQLHighlightRules = require("./logiql_highlight_rules").LogiQLHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+var TokenIterator = require("../token_iterator").TokenIterator;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ this.HighlightRules = LogiQLHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+ if (/comment|string/.test(endState))
+ return indent;
+ if (tokens.length && tokens[tokens.length - 1].type == "comment.single")
+ return indent;
+
+ var match = line.match();
+ if (/(-->|<--|<-|->|{)\s*$/.test(line))
+ indent += tab;
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (this.$outdent.checkOutdent(line, input))
+ return true;
+
+ if (input !== "\n" && input !== "\r\n")
+ return false;
+
+ if (!/^\s+/.test(line))
+ return false;
+
+ return true;
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ if (this.$outdent.autoOutdent(doc, row))
+ return;
+ var prevLine = doc.getLine(row);
+ var match = prevLine.match(/^\s+/);
+ var column = prevLine.lastIndexOf(".") + 1;
+ if (!match || !row || !column) return 0;
+
+ var line = doc.getLine(row + 1);
+ var startRange = this.getMatching(doc, {row: row, column: column});
+ if (!startRange || startRange.start.row == row) return 0;
+
+ column = match[0].length;
+ var indent = this.$getIndent(doc.getLine(startRange.start.row));
+ doc.replace(new Range(row + 1, 0, row + 1, column), indent);
+ };
+
+ this.getMatching = function(session, row, column) {
+ if (row == undefined)
+ row = session.selection.lead
+ if (typeof row == "object") {
+ column = row.column;
+ row = row.row;
+ }
+
+ var startToken = session.getTokenAt(row, column);
+ var KW_START = "keyword.start", KW_END = "keyword.end";
+ var tok;
+ if (!startToken)
+ return;
+ if (startToken.type == KW_START) {
+ var it = new TokenIterator(session, row, column);
+ it.step = it.stepForward;
+ } else if (startToken.type == KW_END) {
+ var it = new TokenIterator(session, row, column);
+ it.step = it.stepBackward;
+ } else
+ return;
+
+ while (tok = it.step()) {
+ if (tok.type == KW_START || tok.type == KW_END)
+ break;
+ }
+ if (!tok || tok.type == startToken.type)
+ return;
+
+ var col = it.getCurrentTokenColumn();
+ var row = it.getCurrentTokenRow();
+ return new Range(row, col, row, col + tok.value.length);
+ };
+ this.$id = "ace/mode/logiql";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-lsl.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-lsl.js
new file mode 100644
index 00000000..2531f6e1
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-lsl.js
@@ -0,0 +1,335 @@
+ace.define("ace/mode/lsl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+oop.inherits(LSLHighlightRules, TextHighlightRules);
+
+function LSLHighlightRules() {
+ var keywordMapper = this.createKeywordMapper({
+ "constant.language.float.lsl" : "DEG_TO_RAD|PI|PI_BY_TWO|RAD_TO_DEG|SQRT2|TWO_PI",
+ "constant.language.integer.lsl": "ACTIVE|AGENT|AGENT_ALWAYS_RUN|AGENT_ATTACHMENTS|AGENT_AUTOPILOT|AGENT_AWAY|AGENT_BUSY|AGENT_BY_LEGACY_NAME|AGENT_BY_USERNAME|AGENT_CROUCHING|AGENT_FLYING|AGENT_IN_AIR|AGENT_LIST_PARCEL|AGENT_LIST_PARCEL_OWNER|AGENT_LIST_REGION|AGENT_MOUSELOOK|AGENT_ON_OBJECT|AGENT_SCRIPTED|AGENT_SITTING|AGENT_TYPING|AGENT_WALKING|ALL_SIDES|ANIM_ON|ATTACH_AVATAR_CENTER|ATTACH_BACK|ATTACH_BELLY|ATTACH_CHEST|ATTACH_CHIN|ATTACH_HEAD|ATTACH_HUD_BOTTOM|ATTACH_HUD_BOTTOM_LEFT|ATTACH_HUD_BOTTOM_RIGHT|ATTACH_HUD_CENTER_1|ATTACH_HUD_CENTER_2|ATTACH_HUD_TOP_CENTER|ATTACH_HUD_TOP_LEFT|ATTACH_HUD_TOP_RIGHT|ATTACH_LEAR|ATTACH_LEFT_PEC|ATTACH_LEYE|ATTACH_LFOOT|ATTACH_LHAND|ATTACH_LHIP|ATTACH_LLARM|ATTACH_LLLEG|ATTACH_LSHOULDER|ATTACH_LUARM|ATTACH_LULEG|ATTACH_MOUTH|ATTACH_NECK|ATTACH_NOSE|ATTACH_PELVIS|ATTACH_REAR|ATTACH_REYE|ATTACH_RFOOT|ATTACH_RHAND|ATTACH_RHIP|ATTACH_RIGHT_PEC|ATTACH_RLARM|ATTACH_RLLEG|ATTACH_RSHOULDER|ATTACH_RUARM|ATTACH_RULEG|AVOID_CHARACTERS|AVOID_DYNAMIC_OBSTACLES|AVOID_NONE|CAMERA_ACTIVE|CAMERA_BEHINDNESS_ANGLE|CAMERA_BEHINDNESS_LAG|CAMERA_DISTANCE|CAMERA_FOCUS|CAMERA_FOCUS_LAG|CAMERA_FOCUS_LOCKED|CAMERA_FOCUS_OFFSET|CAMERA_FOCUS_THRESHOLD|CAMERA_PITCH|CAMERA_POSITION|CAMERA_POSITION_LAG|CAMERA_POSITION_LOCKED|CAMERA_POSITION_THRESHOLD|CHANGED_ALLOWED_DROP|CHANGED_COLOR|CHANGED_INVENTORY|CHANGED_LINK|CHANGED_MEDIA|CHANGED_OWNER|CHANGED_REGION|CHANGED_REGION_START|CHANGED_SCALE|CHANGED_SHAPE|CHANGED_TELEPORT|CHANGED_TEXTURE|CHARACTER_ACCOUNT_FOR_SKIPPED_FRAMES|CHARACTER_AVOIDANCE_MODE|CHARACTER_CMD_JUMP|CHARACTER_CMD_SMOOTH_STOP|CHARACTER_CMD_STOP|CHARACTER_DESIRED_SPEED|CHARACTER_DESIRED_TURN_SPEED|CHARACTER_LENGTH|CHARACTER_MAX_ACCEL|CHARACTER_MAX_DECEL|CHARACTER_MAX_SPEED|CHARACTER_MAX_TURN_RADIUS|CHARACTER_ORIENTATION|CHARACTER_RADIUS|CHARACTER_STAY_WITHIN_PARCEL|CHARACTER_TYPE|CHARACTER_TYPE_A|CHARACTER_TYPE_B|CHARACTER_TYPE_C|CHARACTER_TYPE_D|CHARACTER_TYPE_NONE|CLICK_ACTION_BUY|CLICK_ACTION_NONE|CLICK_ACTION_OPEN|CLICK_ACTION_OPEN_MEDIA|CLICK_ACTION_PAY|CLICK_ACTION_PLAY|CLICK_ACTION_SIT|CLICK_ACTION_TOUCH|CONTENT_TYPE_ATOM|CONTENT_TYPE_FORM|CONTENT_TYPE_HTML|CONTENT_TYPE_JSON|CONTENT_TYPE_LLSD|CONTENT_TYPE_RSS|CONTENT_TYPE_TEXT|CONTENT_TYPE_XHTML|CONTENT_TYPE_XML|CONTROL_BACK|CONTROL_DOWN|CONTROL_FWD|CONTROL_LBUTTON|CONTROL_LEFT|CONTROL_ML_LBUTTON|CONTROL_RIGHT|CONTROL_ROT_LEFT|CONTROL_ROT_RIGHT|CONTROL_UP|DATA_BORN|DATA_NAME|DATA_ONLINE|DATA_PAYINFO|DATA_SIM_POS|DATA_SIM_RATING|DATA_SIM_STATUS|DEBUG_CHANNEL|DENSITY|ERR_GENERIC|ERR_MALFORMED_PARAMS|ERR_PARCEL_PERMISSIONS|ERR_RUNTIME_PERMISSIONS|ERR_THROTTLED|ESTATE_ACCESS_ALLOWED_AGENT_ADD|ESTATE_ACCESS_ALLOWED_AGENT_REMOVE|ESTATE_ACCESS_ALLOWED_GROUP_ADD|ESTATE_ACCESS_ALLOWED_GROUP_REMOVE|ESTATE_ACCESS_BANNED_AGENT_ADD|ESTATE_ACCESS_BANNED_AGENT_REMOVE|FALSE|FORCE_DIRECT_PATH|FRICTION|GCNP_RADIUS|GCNP_STATIC|GRAVITY_MULTIPLIER|HORIZONTAL|HTTP_BODY_MAXLENGTH|HTTP_BODY_TRUNCATED|HTTP_CUSTOM_HEADER|HTTP_METHOD|HTTP_MIMETYPE|HTTP_PRAGMA_NO_CACHE|HTTP_VERBOSE_THROTTLE|HTTP_VERIFY_CERT|INVENTORY_ALL|INVENTORY_ANIMATION|INVENTORY_BODYPART|INVENTORY_CLOTHING|INVENTORY_GESTURE|INVENTORY_LANDMARK|INVENTORY_NONE|INVENTORY_NOTECARD|INVENTORY_OBJECT|INVENTORY_SCRIPT|INVENTORY_SOUND|INVENTORY_TEXTURE|JSON_APPEND|KFM_CMD_PAUSE|KFM_CMD_PLAY|KFM_CMD_SET_MODE|KFM_CMD_STOP|KFM_COMMAND|KFM_DATA|KFM_FORWARD|KFM_LOOP|KFM_MODE|KFM_PING_PONG|KFM_REVERSE|KFM_ROTATION|KFM_TRANSLATION|LAND_LEVEL|LAND_LOWER|LAND_NOISE|LAND_RAISE|LAND_REVERT|LAND_SMOOTH|LINK_ALL_CHILDREN|LINK_ALL_OTHERS|LINK_ROOT|LINK_SET|LINK_THIS|LIST_STAT_GEOMETRIC_MEAN|LIST_STAT_MAX|LIST_STAT_MEAN|LIST_STAT_MEDIAN|LIST_STAT_MIN|LIST_STAT_NUM_COUNT|LIST_STAT_RANGE|LIST_STAT_STD_DEV|LIST_STAT_SUM|LIST_STAT_SUM_SQUARES|LOOP|MASK_BASE|MASK_EVERYONE|MASK_GROUP|MASK_NEXT|MASK_OWNER|OBJECT_ATTACHED_POINT|OBJECT_BODY_SHAPE_TYPE|OBJECT_CHARACTER_TIME|OBJECT_CLICK_ACTION|OBJECT_CREATOR|OBJECT_DESC|OBJECT_GROUP|OBJECT_HOVER_HEIGHT|OBJECT_LAST_OWNER_ID|OBJECT_NAME|OBJECT_OWNER|OBJECT_PATHFINDING_TYPE|OBJECT_PHANTOM|OBJECT_PHYSICS|OBJECT_PHYSICS_COST|OBJECT_POS|OBJECT_PRIM_EQUIVALENCE|OBJECT_RENDER_WEIGHT|OBJECT_RETURN_PARCEL|OBJECT_RETURN_PARCEL_OWNER|OBJECT_RETURN_REGION|OBJECT_ROOT|OBJECT_ROT|OBJECT_RUNNING_SCRIPT_COUNT|OBJECT_SCRIPT_MEMORY|OBJECT_SCRIPT_TIME|OBJECT_SERVER_COST|OBJECT_STREAMING_COST|OBJECT_TEMP_ON_REZ|OBJECT_TOTAL_SCRIPT_COUNT|OBJECT_UNKNOWN_DETAIL|OBJECT_VELOCITY|OPT_AVATAR|OPT_CHARACTER|OPT_EXCLUSION_VOLUME|OPT_LEGACY_LINKSET|OPT_MATERIAL_VOLUME|OPT_OTHER|OPT_STATIC_OBSTACLE|OPT_WALKABLE|PARCEL_COUNT_GROUP|PARCEL_COUNT_OTHER|PARCEL_COUNT_OWNER|PARCEL_COUNT_SELECTED|PARCEL_COUNT_TEMP|PARCEL_COUNT_TOTAL|PARCEL_DETAILS_AREA|PARCEL_DETAILS_DESC|PARCEL_DETAILS_GROUP|PARCEL_DETAILS_ID|PARCEL_DETAILS_NAME|PARCEL_DETAILS_OWNER|PARCEL_DETAILS_SEE_AVATARS|PARCEL_FLAG_ALLOW_ALL_OBJECT_ENTRY|PARCEL_FLAG_ALLOW_CREATE_GROUP_OBJECTS|PARCEL_FLAG_ALLOW_CREATE_OBJECTS|PARCEL_FLAG_ALLOW_DAMAGE|PARCEL_FLAG_ALLOW_FLY|PARCEL_FLAG_ALLOW_GROUP_OBJECT_ENTRY|PARCEL_FLAG_ALLOW_GROUP_SCRIPTS|PARCEL_FLAG_ALLOW_LANDMARK|PARCEL_FLAG_ALLOW_SCRIPTS|PARCEL_FLAG_ALLOW_TERRAFORM|PARCEL_FLAG_LOCAL_SOUND_ONLY|PARCEL_FLAG_RESTRICT_PUSHOBJECT|PARCEL_FLAG_USE_ACCESS_GROUP|PARCEL_FLAG_USE_ACCESS_LIST|PARCEL_FLAG_USE_BAN_LIST|PARCEL_FLAG_USE_LAND_PASS_LIST|PARCEL_MEDIA_COMMAND_AGENT|PARCEL_MEDIA_COMMAND_AUTO_ALIGN|PARCEL_MEDIA_COMMAND_DESC|PARCEL_MEDIA_COMMAND_LOOP|PARCEL_MEDIA_COMMAND_LOOP_SET|PARCEL_MEDIA_COMMAND_PAUSE|PARCEL_MEDIA_COMMAND_PLAY|PARCEL_MEDIA_COMMAND_SIZE|PARCEL_MEDIA_COMMAND_STOP|PARCEL_MEDIA_COMMAND_TEXTURE|PARCEL_MEDIA_COMMAND_TIME|PARCEL_MEDIA_COMMAND_TYPE|PARCEL_MEDIA_COMMAND_UNLOAD|PARCEL_MEDIA_COMMAND_URL|PASS_ALWAYS|PASS_IF_NOT_HANDLED|PASS_NEVER|PASSIVE|PATROL_PAUSE_AT_WAYPOINTS|PAYMENT_INFO_ON_FILE|PAYMENT_INFO_USED|PAY_DEFAULT|PAY_HIDE|PERMISSION_ATTACH|PERMISSION_CHANGE_LINKS|PERMISSION_CONTROL_CAMERA|PERMISSION_DEBIT|PERMISSION_OVERRIDE_ANIMATIONS|PERMISSION_RETURN_OBJECTS|PERMISSION_SILENT_ESTATE_MANAGEMENT|PERMISSION_TAKE_CONTROLS|PERMISSION_TELEPORT|PERMISSION_TRACK_CAMERA|PERMISSION_TRIGGER_ANIMATION|PERM_ALL|PERM_COPY|PERM_MODIFY|PERM_MOVE|PERM_TRANSFER|PING_PONG|PRIM_ALPHA_MODE|PRIM_ALPHA_MODE_BLEND|PRIM_ALPHA_MODE_EMISSIVE|PRIM_ALPHA_MODE_MASK|PRIM_ALPHA_MODE_NONE|PRIM_BUMP_BARK|PRIM_BUMP_BLOBS|PRIM_BUMP_BRICKS|PRIM_BUMP_BRIGHT|PRIM_BUMP_CHECKER|PRIM_BUMP_CONCRETE|PRIM_BUMP_DARK|PRIM_BUMP_DISKS|PRIM_BUMP_GRAVEL|PRIM_BUMP_LARGETILE|PRIM_BUMP_NONE|PRIM_BUMP_SHINY|PRIM_BUMP_SIDING|PRIM_BUMP_STONE|PRIM_BUMP_STUCCO|PRIM_BUMP_SUCTION|PRIM_BUMP_TILE|PRIM_BUMP_WEAVE|PRIM_BUMP_WOOD|PRIM_COLOR|PRIM_DESC|PRIM_FLEXIBLE|PRIM_FULLBRIGHT|PRIM_GLOW|PRIM_HOLE_CIRCLE|PRIM_HOLE_DEFAULT|PRIM_HOLE_SQUARE|PRIM_HOLE_TRIANGLE|PRIM_LINK_TARGET|PRIM_MATERIAL|PRIM_MATERIAL_FLESH|PRIM_MATERIAL_GLASS|PRIM_MATERIAL_METAL|PRIM_MATERIAL_PLASTIC|PRIM_MATERIAL_RUBBER|PRIM_MATERIAL_STONE|PRIM_MATERIAL_WOOD|PRIM_MEDIA_ALT_IMAGE_ENABLE|PRIM_MEDIA_AUTO_LOOP|PRIM_MEDIA_AUTO_PLAY|PRIM_MEDIA_AUTO_SCALE|PRIM_MEDIA_AUTO_ZOOM|PRIM_MEDIA_CONTROLS|PRIM_MEDIA_CONTROLS_MINI|PRIM_MEDIA_CONTROLS_STANDARD|PRIM_MEDIA_CURRENT_URL|PRIM_MEDIA_FIRST_CLICK_INTERACT|PRIM_MEDIA_HEIGHT_PIXELS|PRIM_MEDIA_HOME_URL|PRIM_MEDIA_MAX_HEIGHT_PIXELS|PRIM_MEDIA_MAX_URL_LENGTH|PRIM_MEDIA_MAX_WHITELIST_COUNT|PRIM_MEDIA_MAX_WHITELIST_SIZE|PRIM_MEDIA_MAX_WIDTH_PIXELS|PRIM_MEDIA_PARAM_MAX|PRIM_MEDIA_PERMS_CONTROL|PRIM_MEDIA_PERMS_INTERACT|PRIM_MEDIA_PERM_ANYONE|PRIM_MEDIA_PERM_GROUP|PRIM_MEDIA_PERM_NONE|PRIM_MEDIA_PERM_OWNER|PRIM_MEDIA_WHITELIST|PRIM_MEDIA_WHITELIST_ENABLE|PRIM_MEDIA_WIDTH_PIXELS|PRIM_NAME|PRIM_NORMAL|PRIM_OMEGA|PRIM_PHANTOM|PRIM_PHYSICS|PRIM_PHYSICS_SHAPE_CONVEX|PRIM_PHYSICS_SHAPE_NONE|PRIM_PHYSICS_SHAPE_PRIM|PRIM_PHYSICS_SHAPE_TYPE|PRIM_POINT_LIGHT|PRIM_POSITION|PRIM_POS_LOCAL|PRIM_ROTATION|PRIM_ROT_LOCAL|PRIM_SCULPT_FLAG_INVERT|PRIM_SCULPT_FLAG_MIRROR|PRIM_SCULPT_TYPE_CYLINDER|PRIM_SCULPT_TYPE_MASK|PRIM_SCULPT_TYPE_PLANE|PRIM_SCULPT_TYPE_SPHERE|PRIM_SCULPT_TYPE_TORUS|PRIM_SHINY_HIGH|PRIM_SHINY_LOW|PRIM_SHINY_MEDIUM|PRIM_SHINY_NONE|PRIM_SIZE|PRIM_SLICE|PRIM_SPECULAR|PRIM_TEMP_ON_REZ|PRIM_TEXGEN|PRIM_TEXGEN_DEFAULT|PRIM_TEXGEN_PLANAR|PRIM_TEXT|PRIM_TEXTURE|PRIM_TYPE|PRIM_TYPE_BOX|PRIM_TYPE_CYLINDER|PRIM_TYPE_PRISM|PRIM_TYPE_RING|PRIM_TYPE_SCULPT|PRIM_TYPE_SPHERE|PRIM_TYPE_TORUS|PRIM_TYPE_TUBE|PROFILE_NONE|PROFILE_SCRIPT_MEMORY|PSYS_PART_BF_DEST_COLOR|PSYS_PART_BF_ONE|PSYS_PART_BF_ONE_MINUS_DEST_COLOR|PSYS_PART_BF_ONE_MINUS_SOURCE_ALPHA|PSYS_PART_BF_ONE_MINUS_SOURCE_COLOR|PSYS_PART_BF_SOURCE_ALPHA|PSYS_PART_BF_SOURCE_COLOR|PSYS_PART_BF_ZERO|PSYS_PART_BLEND_FUNC_DEST|PSYS_PART_BLEND_FUNC_SOURCE|PSYS_PART_BOUNCE_MASK|PSYS_PART_EMISSIVE_MASK|PSYS_PART_END_ALPHA|PSYS_PART_END_COLOR|PSYS_PART_END_GLOW|PSYS_PART_END_SCALE|PSYS_PART_FLAGS|PSYS_PART_FOLLOW_SRC_MASK|PSYS_PART_FOLLOW_VELOCITY_MASK|PSYS_PART_INTERP_COLOR_MASK|PSYS_PART_INTERP_SCALE_MASK|PSYS_PART_MAX_AGE|PSYS_PART_RIBBON_MASK|PSYS_PART_START_ALPHA|PSYS_PART_START_COLOR|PSYS_PART_START_GLOW|PSYS_PART_START_SCALE|PSYS_PART_TARGET_LINEAR_MASK|PSYS_PART_TARGET_POS_MASK|PSYS_PART_WIND_MASK|PSYS_SRC_ACCEL|PSYS_SRC_ANGLE_BEGIN|PSYS_SRC_ANGLE_END|PSYS_SRC_BURST_PART_COUNT|PSYS_SRC_BURST_RADIUS|PSYS_SRC_BURST_RATE|PSYS_SRC_BURST_SPEED_MAX|PSYS_SRC_BURST_SPEED_MIN|PSYS_SRC_MAX_AGE|PSYS_SRC_OMEGA|PSYS_SRC_PATTERN|PSYS_SRC_PATTERN_ANGLE|PSYS_SRC_PATTERN_ANGLE_CONE|PSYS_SRC_PATTERN_ANGLE_CONE_EMPTY|PSYS_SRC_PATTERN_DROP|PSYS_SRC_PATTERN_EXPLODE|PSYS_SRC_TARGET_KEY|PSYS_SRC_TEXTURE|PUBLIC_CHANNEL|PURSUIT_FUZZ_FACTOR|PURSUIT_GOAL_TOLERANCE|PURSUIT_INTERCEPT|PURSUIT_OFFSET|PU_EVADE_HIDDEN|PU_EVADE_SPOTTED|PU_FAILURE_DYNAMIC_PATHFINDING_DISABLED|PU_FAILURE_INVALID_GOAL|PU_FAILURE_INVALID_START|PU_FAILURE_NO_NAVMESH|PU_FAILURE_NO_VALID_DESTINATION|PU_FAILURE_OTHER|PU_FAILURE_PARCEL_UNREACHABLE|PU_FAILURE_TARGET_GONE|PU_FAILURE_UNREACHABLE|PU_GOAL_REACHED|PU_SLOWDOWN_DISTANCE_REACHED|RCERR_CAST_TIME_EXCEEDED|RCERR_SIM_PERF_LOW|RCERR_UNKNOWN|RC_DATA_FLAGS|RC_DETECT_PHANTOM|RC_GET_LINK_NUM|RC_GET_NORMAL|RC_GET_ROOT_KEY|RC_MAX_HITS|RC_REJECT_AGENTS|RC_REJECT_LAND|RC_REJECT_NONPHYSICAL|RC_REJECT_PHYSICAL|RC_REJECT_TYPES|REGION_FLAG_ALLOW_DAMAGE|REGION_FLAG_ALLOW_DIRECT_TELEPORT|REGION_FLAG_BLOCK_FLY|REGION_FLAG_BLOCK_TERRAFORM|REGION_FLAG_DISABLE_COLLISIONS|REGION_FLAG_DISABLE_PHYSICS|REGION_FLAG_FIXED_SUN|REGION_FLAG_RESTRICT_PUSHOBJECT|REGION_FLAG_SANDBOX|REMOTE_DATA_CHANNEL|REMOTE_DATA_REPLY|REMOTE_DATA_REQUEST|REQUIRE_LINE_OF_SIGHT|RESTITUTION|REVERSE|ROTATE|SCALE|SCRIPTED|SIM_STAT_PCT_CHARS_STEPPED|SMOOTH|STATUS_BLOCK_GRAB|STATUS_BLOCK_GRAB_OBJECT|STATUS_BOUNDS_ERROR|STATUS_CAST_SHADOWS|STATUS_DIE_AT_EDGE|STATUS_INTERNAL_ERROR|STATUS_MALFORMED_PARAMS|STATUS_NOT_FOUND|STATUS_NOT_SUPPORTED|STATUS_OK|STATUS_PHANTOM|STATUS_PHYSICS|STATUS_RETURN_AT_EDGE|STATUS_ROTATE_X|STATUS_ROTATE_Y|STATUS_ROTATE_Z|STATUS_SANDBOX|STATUS_TYPE_MISMATCH|STATUS_WHITELIST_FAILED|STRING_TRIM|STRING_TRIM_HEAD|STRING_TRIM_TAIL|TOUCH_INVALID_FACE|TRAVERSAL_TYPE|TRAVERSAL_TYPE_FAST|TRAVERSAL_TYPE_NONE|TRAVERSAL_TYPE_SLOW|TRUE|TYPE_FLOAT|TYPE_INTEGER|TYPE_INVALID|TYPE_KEY|TYPE_ROTATION|TYPE_STRING|TYPE_VECTOR|VEHICLE_ANGULAR_DEFLECTION_EFFICIENCY|VEHICLE_ANGULAR_DEFLECTION_TIMESCALE|VEHICLE_ANGULAR_FRICTION_TIMESCALE|VEHICLE_ANGULAR_MOTOR_DECAY_TIMESCALE|VEHICLE_ANGULAR_MOTOR_DIRECTION|VEHICLE_ANGULAR_MOTOR_TIMESCALE|VEHICLE_BANKING_EFFICIENCY|VEHICLE_BANKING_MIX|VEHICLE_BANKING_TIMESCALE|VEHICLE_BUOYANCY|VEHICLE_FLAG_CAMERA_DECOUPLED|VEHICLE_FLAG_HOVER_GLOBAL_HEIGHT|VEHICLE_FLAG_HOVER_TERRAIN_ONLY|VEHICLE_FLAG_HOVER_UP_ONLY|VEHICLE_FLAG_HOVER_WATER_ONLY|VEHICLE_FLAG_LIMIT_MOTOR_UP|VEHICLE_FLAG_LIMIT_ROLL_ONLY|VEHICLE_FLAG_MOUSELOOK_BANK|VEHICLE_FLAG_MOUSELOOK_STEER|VEHICLE_FLAG_NO_DEFLECTION_UP|VEHICLE_HOVER_EFFICIENCY|VEHICLE_HOVER_HEIGHT|VEHICLE_HOVER_TIMESCALE|VEHICLE_LINEAR_DEFLECTION_EFFICIENCY|VEHICLE_LINEAR_DEFLECTION_TIMESCALE|VEHICLE_LINEAR_FRICTION_TIMESCALE|VEHICLE_LINEAR_MOTOR_DECAY_TIMESCALE|VEHICLE_LINEAR_MOTOR_DIRECTION|VEHICLE_LINEAR_MOTOR_OFFSET|VEHICLE_LINEAR_MOTOR_TIMESCALE|VEHICLE_REFERENCE_FRAME|VEHICLE_TYPE_AIRPLANE|VEHICLE_TYPE_BALLOON|VEHICLE_TYPE_BOAT|VEHICLE_TYPE_CAR|VEHICLE_TYPE_NONE|VEHICLE_TYPE_SLED|VEHICLE_VERTICAL_ATTRACTION_EFFICIENCY|VEHICLE_VERTICAL_ATTRACTION_TIMESCALE|VERTICAL|WANDER_PAUSE_AT_WAYPOINTS|XP_ERROR_EXPERIENCES_DISABLED|XP_ERROR_EXPERIENCE_DISABLED|XP_ERROR_EXPERIENCE_SUSPENDED|XP_ERROR_INVALID_EXPERIENCE|XP_ERROR_INVALID_PARAMETERS|XP_ERROR_KEY_NOT_FOUND|XP_ERROR_MATURITY_EXCEEDED|XP_ERROR_NONE|XP_ERROR_NOT_FOUND|XP_ERROR_NOT_PERMITTED|XP_ERROR_NO_EXPERIENCE|XP_ERROR_QUOTA_EXCEEDED|XP_ERROR_RETRY_UPDATE|XP_ERROR_STORAGE_EXCEPTION|XP_ERROR_STORE_DISABLED|XP_ERROR_THROTTLED|XP_ERROR_UNKNOWN_ERROR",
+ "constant.language.integer.boolean.lsl" : "FALSE|TRUE",
+ "constant.language.quaternion.lsl" : "ZERO_ROTATION",
+ "constant.language.string.lsl" : "EOF|JSON_ARRAY|JSON_DELETE|JSON_FALSE|JSON_INVALID|JSON_NULL|JSON_NUMBER|JSON_OBJECT|JSON_STRING|JSON_TRUE|NULL_KEY|TEXTURE_BLANK|TEXTURE_DEFAULT|TEXTURE_MEDIA|TEXTURE_PLYWOOD|TEXTURE_TRANSPARENT|URL_REQUEST_DENIED|URL_REQUEST_GRANTED",
+ "constant.language.vector.lsl" : "TOUCH_INVALID_TEXCOORD|TOUCH_INVALID_VECTOR|ZERO_VECTOR",
+ "invalid.broken.lsl": "LAND_LARGE_BRUSH|LAND_MEDIUM_BRUSH|LAND_SMALL_BRUSH",
+ "invalid.deprecated.lsl" : "ATTACH_LPEC|ATTACH_RPEC|DATA_RATING|OBJECT_ATTACHMENT_GEOMETRY_BYTES|OBJECT_ATTACHMENT_SURFACE_AREA|PRIM_CAST_SHADOWS|PRIM_MATERIAL_LIGHT|PRIM_TYPE_LEGACY|PSYS_SRC_INNERANGLE|PSYS_SRC_OUTERANGLE|VEHICLE_FLAG_NO_FLY_UP|llClearExperiencePermissions|llCloud|llGetExperienceList|llMakeExplosion|llMakeFire|llMakeFountain|llMakeSmoke|llRemoteDataSetRegion|llSound|llSoundPreload|llXorBase64Strings|llXorBase64StringsCorrect",
+ "invalid.illegal.lsl": "event",
+ "invalid.unimplemented.lsl": "CHARACTER_MAX_ANGULAR_ACCEL|CHARACTER_MAX_ANGULAR_SPEED|CHARACTER_TURN_SPEED_MULTIPLIER|PERMISSION_CHANGE_JOINTS|PERMISSION_CHANGE_PERMISSIONS|PERMISSION_EXPERIENCE|PERMISSION_RELEASE_OWNERSHIP|PERMISSION_REMAP_CONTROLS|PRIM_PHYSICS_MATERIAL|PSYS_SRC_OBJ_REL_MASK|llCollisionSprite|llPointAt|llRefreshPrimURL|llReleaseCamera|llRemoteLoadScript|llSetPrimURL|llStopPointAt|llTakeCamera",
+ "reserved.godmode.lsl": "llGodLikeRezObject|llSetInventoryPermMask|llSetObjectPermMask",
+ "reserved.log.lsl" : "print",
+ "keyword.control.lsl" : "do|else|for|if|jump|return|while",
+ "storage.type.lsl" : "float|integer|key|list|quaternion|rotation|string|vector",
+ "support.function.lsl": "llAbs|llAcos|llAddToLandBanList|llAddToLandPassList|llAdjustSoundVolume|llAgentInExperience|llAllowInventoryDrop|llAngleBetween|llApplyImpulse|llApplyRotationalImpulse|llAsin|llAtan2|llAttachToAvatar|llAttachToAvatarTemp|llAvatarOnLinkSitTarget|llAvatarOnSitTarget|llAxes2Rot|llAxisAngle2Rot|llBase64ToInteger|llBase64ToString|llBreakAllLinks|llBreakLink|llCSV2List|llCastRay|llCeil|llClearCameraParams|llClearLinkMedia|llClearPrimMedia|llCloseRemoteDataChannel|llCollisionFilter|llCollisionSound|llCos|llCreateCharacter|llCreateKeyValue|llCreateLink|llDataSizeKeyValue|llDeleteCharacter|llDeleteKeyValue|llDeleteSubList|llDeleteSubString|llDetachFromAvatar|llDetectedGrab|llDetectedGroup|llDetectedKey|llDetectedLinkNumber|llDetectedName|llDetectedOwner|llDetectedPos|llDetectedRot|llDetectedTouchBinormal|llDetectedTouchFace|llDetectedTouchNormal|llDetectedTouchPos|llDetectedTouchST|llDetectedTouchUV|llDetectedType|llDetectedVel|llDialog|llDie|llDumpList2String|llEdgeOfWorld|llEjectFromLand|llEmail|llEscapeURL|llEuler2Rot|llEvade|llExecCharacterCmd|llFabs|llFleeFrom|llFloor|llForceMouselook|llFrand|llGenerateKey|llGetAccel|llGetAgentInfo|llGetAgentLanguage|llGetAgentList|llGetAgentSize|llGetAlpha|llGetAndResetTime|llGetAnimation|llGetAnimationList|llGetAnimationOverride|llGetAttached|llGetAttachedList|llGetBoundingBox|llGetCameraPos|llGetCameraRot|llGetCenterOfMass|llGetClosestNavPoint|llGetColor|llGetCreator|llGetDate|llGetDisplayName|llGetEnergy|llGetEnv|llGetExperienceDetails|llGetExperienceErrorMessage|llGetForce|llGetFreeMemory|llGetFreeURLs|llGetGMTclock|llGetGeometricCenter|llGetHTTPHeader|llGetInventoryCreator|llGetInventoryKey|llGetInventoryName|llGetInventoryNumber|llGetInventoryPermMask|llGetInventoryType|llGetKey|llGetLandOwnerAt|llGetLinkKey|llGetLinkMedia|llGetLinkName|llGetLinkNumber|llGetLinkNumberOfSides|llGetLinkPrimitiveParams|llGetListEntryType|llGetListLength|llGetLocalPos|llGetLocalRot|llGetMass|llGetMassMKS|llGetMaxScaleFactor|llGetMemoryLimit|llGetMinScaleFactor|llGetNextEmail|llGetNotecardLine|llGetNumberOfNotecardLines|llGetNumberOfPrims|llGetNumberOfSides|llGetObjectDesc|llGetObjectDetails|llGetObjectMass|llGetObjectName|llGetObjectPermMask|llGetObjectPrimCount|llGetOmega|llGetOwner|llGetOwnerKey|llGetParcelDetails|llGetParcelFlags|llGetParcelMaxPrims|llGetParcelMusicURL|llGetParcelPrimCount|llGetParcelPrimOwners|llGetPermissions|llGetPermissionsKey|llGetPhysicsMaterial|llGetPos|llGetPrimMediaParams|llGetPrimitiveParams|llGetRegionAgentCount|llGetRegionCorner|llGetRegionFPS|llGetRegionFlags|llGetRegionName|llGetRegionTimeDilation|llGetRootPosition|llGetRootRotation|llGetRot|llGetSPMaxMemory|llGetScale|llGetScriptName|llGetScriptState|llGetSimStats|llGetSimulatorHostname|llGetStartParameter|llGetStaticPath|llGetStatus|llGetSubString|llGetSunDirection|llGetTexture|llGetTextureOffset|llGetTextureRot|llGetTextureScale|llGetTime|llGetTimeOfDay|llGetTimestamp|llGetTorque|llGetUnixTime|llGetUsedMemory|llGetUsername|llGetVel|llGetWallclock|llGiveInventory|llGiveInventoryList|llGiveMoney|llGround|llGroundContour|llGroundNormal|llGroundRepel|llGroundSlope|llHTTPRequest|llHTTPResponse|llInsertString|llInstantMessage|llIntegerToBase64|llJson2List|llJsonGetValue|llJsonSetValue|llJsonValueType|llKey2Name|llKeyCountKeyValue|llKeysKeyValue|llLinkParticleSystem|llLinkSitTarget|llList2CSV|llList2Float|llList2Integer|llList2Json|llList2Key|llList2List|llList2ListStrided|llList2Rot|llList2String|llList2Vector|llListFindList|llListInsertList|llListRandomize|llListReplaceList|llListSort|llListStatistics|llListen|llListenControl|llListenRemove|llLoadURL|llLog|llLog10|llLookAt|llLoopSound|llLoopSoundMaster|llLoopSoundSlave|llMD5String|llManageEstateAccess|llMapDestination|llMessageLinked|llMinEventDelay|llModPow|llModifyLand|llMoveToTarget|llNavigateTo|llOffsetTexture|llOpenRemoteDataChannel|llOverMyLand|llOwnerSay|llParcelMediaCommandList|llParcelMediaQuery|llParseString2List|llParseStringKeepNulls|llParticleSystem|llPassCollisions|llPassTouches|llPatrolPoints|llPlaySound|llPlaySoundSlave|llPow|llPreloadSound|llPursue|llPushObject|llReadKeyValue|llRegionSay|llRegionSayTo|llReleaseControls|llReleaseURL|llRemoteDataReply|llRemoteLoadScriptPin|llRemoveFromLandBanList|llRemoveFromLandPassList|llRemoveInventory|llRemoveVehicleFlags|llRequestAgentData|llRequestDisplayName|llRequestExperiencePermissions|llRequestInventoryData|llRequestPermissions|llRequestSecureURL|llRequestSimulatorData|llRequestURL|llRequestUsername|llResetAnimationOverride|llResetLandBanList|llResetLandPassList|llResetOtherScript|llResetScript|llResetTime|llReturnObjectsByID|llReturnObjectsByOwner|llRezAtRoot|llRezObject|llRot2Angle|llRot2Axis|llRot2Euler|llRot2Fwd|llRot2Left|llRot2Up|llRotBetween|llRotLookAt|llRotTarget|llRotTargetRemove|llRotateTexture|llRound|llSHA1String|llSameGroup|llSay|llScaleByFactor|llScaleTexture|llScriptDanger|llScriptProfiler|llSendRemoteData|llSensor|llSensorRemove|llSensorRepeat|llSetAlpha|llSetAngularVelocity|llSetAnimationOverride|llSetBuoyancy|llSetCameraAtOffset|llSetCameraEyeOffset|llSetCameraParams|llSetClickAction|llSetColor|llSetContentType|llSetDamage|llSetForce|llSetForceAndTorque|llSetHoverHeight|llSetKeyframedMotion|llSetLinkAlpha|llSetLinkCamera|llSetLinkColor|llSetLinkMedia|llSetLinkPrimitiveParams|llSetLinkPrimitiveParamsFast|llSetLinkTexture|llSetLinkTextureAnim|llSetLocalRot|llSetMemoryLimit|llSetObjectDesc|llSetObjectName|llSetParcelMusicURL|llSetPayPrice|llSetPhysicsMaterial|llSetPos|llSetPrimMediaParams|llSetPrimitiveParams|llSetRegionPos|llSetRemoteScriptAccessPin|llSetRot|llSetScale|llSetScriptState|llSetSitText|llSetSoundQueueing|llSetSoundRadius|llSetStatus|llSetText|llSetTexture|llSetTextureAnim|llSetTimerEvent|llSetTorque|llSetTouchText|llSetVehicleFlags|llSetVehicleFloatParam|llSetVehicleRotationParam|llSetVehicleType|llSetVehicleVectorParam|llSetVelocity|llShout|llSin|llSitTarget|llSleep|llSqrt|llStartAnimation|llStopAnimation|llStopHover|llStopLookAt|llStopMoveToTarget|llStopSound|llStringLength|llStringToBase64|llStringTrim|llSubStringIndex|llTakeControls|llTan|llTarget|llTargetOmega|llTargetRemove|llTeleportAgent|llTeleportAgentGlobalCoords|llTeleportAgentHome|llTextBox|llToLower|llToUpper|llTransferLindenDollars|llTriggerSound|llTriggerSoundLimited|llUnSit|llUnescapeURL|llUpdateCharacter|llUpdateKeyValue|llVecDist|llVecMag|llVecNorm|llVolumeDetect|llWanderWithin|llWater|llWhisper|llWind|llXorBase64",
+ "support.function.event.lsl" : "at_rot_target|at_target|attach|changed|collision|collision_end|collision_start|control|dataserver|email|experience_permissions|experience_permissions_denied|http_request|http_response|land_collision|land_collision_end|land_collision_start|link_message|listen|money|moving_end|moving_start|no_sensor|not_at_rot_target|not_at_target|object_rez|on_rez|path_update|remote_data|run_time_permissions|sensor|state_entry|state_exit|timer|touch|touch_end|touch_start|transaction_result"
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment.line.double-slash.lsl",
+ regex : "\\/\\/.*$"
+ }, {
+ token : "comment.block.begin.lsl",
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string.quoted.double.lsl",
+ start : '"',
+ end : '"',
+ next : [{
+ token : "constant.character.escape.lsl",
+ regex : /\\[tn"\\]/
+ }]
+ }, {
+ token : "constant.numeric.lsl",
+ regex : "(0[xX][0-9a-fA-F]+|[+-]?[0-9]+(?:(?:\\.[0-9]*)?(?:[eE][+-]?[0-9]+)?)?)\\b"
+ }, {
+ token : "entity.name.state.lsl",
+ regex : "\\b((state)\\s+[A-Za-z_]\\w*|default)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "\\b[a-zA-Z_][a-zA-Z0-9_]*\\b"
+ }, {
+ token : "support.function.user-defined.lsl",
+ regex : /\b([a-zA-Z_]\w*)(?=\(.*?\))/
+ }, {
+ token : "keyword.operator.lsl",
+ regex : "\\+\\+|\\-\\-|<<|>>|&&?|\\|\\|?|\\^|~|[!%<>=*+\\-\\/]=?"
+ }, {
+ token : "invalid.illegal.keyword.operator.lsl",
+ regex : ":=?"
+ }, {
+ token : "punctuation.operator.lsl",
+ regex : "\\,|\\;"
+ }, {
+ token : "paren.lparen.lsl",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen.lsl",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text.lsl",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment.block.end.lsl",
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment.block.lsl"
+ }
+ ]
+ };
+ this.normalizeRules();
+}
+
+exports.LSLHighlightRules = LSLHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/lsl",["require","exports","module","ace/mode/lsl_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/text","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/lib/oop"], function(require, exports, module) {
+"use strict";
+
+var Rules = require("./lsl_highlight_rules").LSLHighlightRules;
+var Outdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var TextMode = require("./text").Mode;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var oop = require("../lib/oop");
+
+var Mode = function() {
+ this.HighlightRules = Rules;
+ this.$outdent = new Outdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ["//"];
+
+ this.blockComment = {
+ start: "/*",
+ end: "*/"
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type === "comment.block.lsl") {
+ return indent;
+ }
+
+ if (state === "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/lsl";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-lua.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-lua.js
new file mode 100644
index 00000000..bcf4daa5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-lua.js
@@ -0,0 +1,424 @@
+ace.define("ace/mode/lua_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LuaHighlightRules = function() {
+
+ var keywords = (
+ "break|do|else|elseif|end|for|function|if|in|local|repeat|"+
+ "return|then|until|while|or|and|not"
+ );
+
+ var builtinConstants = ("true|false|nil|_G|_VERSION");
+
+ var functions = (
+ "string|xpcall|package|tostring|print|os|unpack|require|"+
+ "getfenv|setmetatable|next|assert|tonumber|io|rawequal|"+
+ "collectgarbage|getmetatable|module|rawset|math|debug|"+
+ "pcall|table|newproxy|type|coroutine|_G|select|gcinfo|"+
+ "pairs|rawget|loadstring|ipairs|_VERSION|dofile|setfenv|"+
+ "load|error|loadfile|"+
+
+ "sub|upper|len|gfind|rep|find|match|char|dump|gmatch|"+
+ "reverse|byte|format|gsub|lower|preload|loadlib|loaded|"+
+ "loaders|cpath|config|path|seeall|exit|setlocale|date|"+
+ "getenv|difftime|remove|time|clock|tmpname|rename|execute|"+
+ "lines|write|close|flush|open|output|type|read|stderr|"+
+ "stdin|input|stdout|popen|tmpfile|log|max|acos|huge|"+
+ "ldexp|pi|cos|tanh|pow|deg|tan|cosh|sinh|random|randomseed|"+
+ "frexp|ceil|floor|rad|abs|sqrt|modf|asin|min|mod|fmod|log10|"+
+ "atan2|exp|sin|atan|getupvalue|debug|sethook|getmetatable|"+
+ "gethook|setmetatable|setlocal|traceback|setfenv|getinfo|"+
+ "setupvalue|getlocal|getregistry|getfenv|setn|insert|getn|"+
+ "foreachi|maxn|foreach|concat|sort|remove|resume|yield|"+
+ "status|wrap|create|running|"+
+ "__add|__sub|__mod|__unm|__concat|__lt|__index|__call|__gc|__metatable|"+
+ "__mul|__div|__pow|__len|__eq|__le|__newindex|__tostring|__mode|__tonumber"
+ );
+
+ var stdLibaries = ("string|package|os|io|math|debug|table|coroutine");
+
+ var deprecatedIn5152 = ("setn|foreach|foreachi|gcinfo|log10|maxn");
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "support.function": functions,
+ "keyword.deprecated": deprecatedIn5152,
+ "constant.library": stdLibaries,
+ "constant.language": builtinConstants,
+ "variable.language": "self"
+ }, "identifier");
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var integer = "(?:" + decimalInteger + "|" + hexInteger + ")";
+
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var floatNumber = "(?:" + pointFloat + ")";
+
+ this.$rules = {
+ "start" : [{
+ stateName: "bracketedComment",
+ onMatch : function(value, currentState, stack){
+ stack.unshift(this.next, value.length - 2, currentState);
+ return "comment";
+ },
+ regex : /\-\-\[=*\[/,
+ next : [
+ {
+ onMatch : function(value, currentState, stack) {
+ if (value.length == stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack.shift();
+ } else {
+ this.next = "";
+ }
+ return "comment";
+ },
+ regex : /\]=*\]/,
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ },
+
+ {
+ token : "comment",
+ regex : "\\-\\-.*$"
+ },
+ {
+ stateName: "bracketedString",
+ onMatch : function(value, currentState, stack){
+ stack.unshift(this.next, value.length, currentState);
+ return "string.start";
+ },
+ regex : /\[=*\[/,
+ next : [
+ {
+ onMatch : function(value, currentState, stack) {
+ if (value.length == stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack.shift();
+ } else {
+ this.next = "";
+ }
+ return "string.end";
+ },
+
+ regex : /\]=*\]/,
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }
+ ]
+ },
+ {
+ token : "string", // " string
+ regex : '"(?:[^\\\\]|\\\\.)*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'(?:[^\\\\]|\\\\.)*?'"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\/|%|\\#|\\^|~|<|>|<=|=>|==|~=|=|\\:|\\.\\.\\.|\\.\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text",
+ regex : "\\s+|\\w+"
+ } ]
+ };
+
+ this.normalizeRules();
+}
+
+oop.inherits(LuaHighlightRules, TextHighlightRules);
+
+exports.LuaHighlightRules = LuaHighlightRules;
+});
+
+ace.define("ace/mode/folding/lua",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+
+var FoldMode = exports.FoldMode = function() {};
+
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /\b(function|then|do|repeat)\b|{\s*$|(\[=*\[)/;
+ this.foldingStopMarker = /\bend\b|^\s*}|\]=*\]/;
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var isStart = this.foldingStartMarker.test(line);
+ var isEnd = this.foldingStopMarker.test(line);
+
+ if (isStart && !isEnd) {
+ var match = line.match(this.foldingStartMarker);
+ if (match[1] == "then" && /\belseif\b/.test(line))
+ return;
+ if (match[1]) {
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
+ return "start";
+ } else if (match[2]) {
+ var type = session.bgTokenizer.getState(row) || "";
+ if (type[0] == "bracketedComment" || type[0] == "bracketedString")
+ return "start";
+ } else {
+ return "start";
+ }
+ }
+ if (foldStyle != "markbeginend" || !isEnd || isStart && isEnd)
+ return "";
+
+ var match = line.match(this.foldingStopMarker);
+ if (match[0] === "end") {
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
+ return "end";
+ } else if (match[0][0] === "]") {
+ var type = session.bgTokenizer.getState(row - 1) || "";
+ if (type[0] == "bracketedComment" || type[0] == "bracketedString")
+ return "end";
+ } else
+ return "end";
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.doc.getLine(row);
+ var match = this.foldingStartMarker.exec(line);
+ if (match) {
+ if (match[1])
+ return this.luaBlock(session, row, match.index + 1);
+
+ if (match[2])
+ return session.getCommentFoldRange(row, match.index + 1);
+
+ return this.openingBracketBlock(session, "{", row, match.index);
+ }
+
+ var match = this.foldingStopMarker.exec(line);
+ if (match) {
+ if (match[0] === "end") {
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
+ return this.luaBlock(session, row, match.index + 1);
+ }
+
+ if (match[0][0] === "]")
+ return session.getCommentFoldRange(row, match.index + 1);
+
+ return this.closingBracketBlock(session, "}", row, match.index + match[0].length);
+ }
+ };
+
+ this.luaBlock = function(session, row, column) {
+ var stream = new TokenIterator(session, row, column);
+ var indentKeywords = {
+ "function": 1,
+ "do": 1,
+ "then": 1,
+ "elseif": -1,
+ "end": -1,
+ "repeat": 1,
+ "until": -1
+ };
+
+ var token = stream.getCurrentToken();
+ if (!token || token.type != "keyword")
+ return;
+
+ var val = token.value;
+ var stack = [val];
+ var dir = indentKeywords[val];
+
+ if (!dir)
+ return;
+
+ var startColumn = dir === -1 ? stream.getCurrentTokenColumn() : session.getLine(row).length;
+ var startRow = row;
+
+ stream.step = dir === -1 ? stream.stepBackward : stream.stepForward;
+ while(token = stream.step()) {
+ if (token.type !== "keyword")
+ continue;
+ var level = dir * indentKeywords[token.value];
+
+ if (level > 0) {
+ stack.unshift(token.value);
+ } else if (level <= 0) {
+ stack.shift();
+ if (!stack.length && token.value != "elseif")
+ break;
+ if (level === 0)
+ stack.unshift(token.value);
+ }
+ }
+
+ var row = stream.getCurrentTokenRow();
+ if (dir === -1)
+ return new Range(row, session.getLine(row).length, startRow, startColumn);
+ else
+ return new Range(startRow, startColumn, row, stream.getCurrentTokenColumn());
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/lua",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/lua_highlight_rules","ace/mode/folding/lua","ace/range","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LuaHighlightRules = require("./lua_highlight_rules").LuaHighlightRules;
+var LuaFoldMode = require("./folding/lua").FoldMode;
+var Range = require("../range").Range;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+
+var Mode = function() {
+ this.HighlightRules = LuaHighlightRules;
+
+ this.foldingRules = new LuaFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "--[", end: "]--"};
+
+ var indentKeywords = {
+ "function": 1,
+ "then": 1,
+ "do": 1,
+ "else": 1,
+ "elseif": 1,
+ "repeat": 1,
+ "end": -1,
+ "until": -1
+ };
+ var outdentKeywords = [
+ "else",
+ "elseif",
+ "end",
+ "until"
+ ];
+
+ function getNetIndentLevel(tokens) {
+ var level = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (token.type == "keyword") {
+ if (token.value in indentKeywords) {
+ level += indentKeywords[token.value];
+ }
+ } else if (token.type == "paren.lparen") {
+ level += token.value.length;
+ } else if (token.type == "paren.rparen") {
+ level -= token.value.length;
+ }
+ }
+ if (level < 0) {
+ return -1;
+ } else if (level > 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ }
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var level = 0;
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (state == "start") {
+ level = getNetIndentLevel(tokens);
+ }
+ if (level > 0) {
+ return indent + tab;
+ } else if (level < 0 && indent.substr(indent.length - tab.length) == tab) {
+ if (!this.checkOutdent(state, line, "\n")) {
+ return indent.substr(0, indent.length - tab.length);
+ }
+ }
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input != "\n" && input != "\r" && input != "\r\n")
+ return false;
+
+ if (line.match(/^\s*[\)\}\]]$/))
+ return true;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens || !tokens.length)
+ return false;
+
+ return (tokens[0].type == "keyword" && outdentKeywords.indexOf(tokens[0].value) != -1);
+ };
+
+ this.autoOutdent = function(state, session, row) {
+ var prevLine = session.getLine(row - 1);
+ var prevIndent = this.$getIndent(prevLine).length;
+ var prevTokens = this.getTokenizer().getLineTokens(prevLine, "start").tokens;
+ var tabLength = session.getTabString().length;
+ var expectedIndent = prevIndent + tabLength * getNetIndentLevel(prevTokens);
+ var curIndent = this.$getIndent(session.getLine(row)).length;
+ if (curIndent <= expectedIndent) {
+ return;
+ }
+ session.outdentRows(new Range(row, 0, row + 2, 0));
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/lua_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/lua";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-luapage.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-luapage.js
new file mode 100644
index 00000000..be6b0922
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-luapage.js
@@ -0,0 +1,2978 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/lua_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LuaHighlightRules = function() {
+
+ var keywords = (
+ "break|do|else|elseif|end|for|function|if|in|local|repeat|"+
+ "return|then|until|while|or|and|not"
+ );
+
+ var builtinConstants = ("true|false|nil|_G|_VERSION");
+
+ var functions = (
+ "string|xpcall|package|tostring|print|os|unpack|require|"+
+ "getfenv|setmetatable|next|assert|tonumber|io|rawequal|"+
+ "collectgarbage|getmetatable|module|rawset|math|debug|"+
+ "pcall|table|newproxy|type|coroutine|_G|select|gcinfo|"+
+ "pairs|rawget|loadstring|ipairs|_VERSION|dofile|setfenv|"+
+ "load|error|loadfile|"+
+
+ "sub|upper|len|gfind|rep|find|match|char|dump|gmatch|"+
+ "reverse|byte|format|gsub|lower|preload|loadlib|loaded|"+
+ "loaders|cpath|config|path|seeall|exit|setlocale|date|"+
+ "getenv|difftime|remove|time|clock|tmpname|rename|execute|"+
+ "lines|write|close|flush|open|output|type|read|stderr|"+
+ "stdin|input|stdout|popen|tmpfile|log|max|acos|huge|"+
+ "ldexp|pi|cos|tanh|pow|deg|tan|cosh|sinh|random|randomseed|"+
+ "frexp|ceil|floor|rad|abs|sqrt|modf|asin|min|mod|fmod|log10|"+
+ "atan2|exp|sin|atan|getupvalue|debug|sethook|getmetatable|"+
+ "gethook|setmetatable|setlocal|traceback|setfenv|getinfo|"+
+ "setupvalue|getlocal|getregistry|getfenv|setn|insert|getn|"+
+ "foreachi|maxn|foreach|concat|sort|remove|resume|yield|"+
+ "status|wrap|create|running|"+
+ "__add|__sub|__mod|__unm|__concat|__lt|__index|__call|__gc|__metatable|"+
+ "__mul|__div|__pow|__len|__eq|__le|__newindex|__tostring|__mode|__tonumber"
+ );
+
+ var stdLibaries = ("string|package|os|io|math|debug|table|coroutine");
+
+ var deprecatedIn5152 = ("setn|foreach|foreachi|gcinfo|log10|maxn");
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "support.function": functions,
+ "keyword.deprecated": deprecatedIn5152,
+ "constant.library": stdLibaries,
+ "constant.language": builtinConstants,
+ "variable.language": "self"
+ }, "identifier");
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var integer = "(?:" + decimalInteger + "|" + hexInteger + ")";
+
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var floatNumber = "(?:" + pointFloat + ")";
+
+ this.$rules = {
+ "start" : [{
+ stateName: "bracketedComment",
+ onMatch : function(value, currentState, stack){
+ stack.unshift(this.next, value.length - 2, currentState);
+ return "comment";
+ },
+ regex : /\-\-\[=*\[/,
+ next : [
+ {
+ onMatch : function(value, currentState, stack) {
+ if (value.length == stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack.shift();
+ } else {
+ this.next = "";
+ }
+ return "comment";
+ },
+ regex : /\]=*\]/,
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ },
+
+ {
+ token : "comment",
+ regex : "\\-\\-.*$"
+ },
+ {
+ stateName: "bracketedString",
+ onMatch : function(value, currentState, stack){
+ stack.unshift(this.next, value.length, currentState);
+ return "string.start";
+ },
+ regex : /\[=*\[/,
+ next : [
+ {
+ onMatch : function(value, currentState, stack) {
+ if (value.length == stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack.shift();
+ } else {
+ this.next = "";
+ }
+ return "string.end";
+ },
+
+ regex : /\]=*\]/,
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }
+ ]
+ },
+ {
+ token : "string", // " string
+ regex : '"(?:[^\\\\]|\\\\.)*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'(?:[^\\\\]|\\\\.)*?'"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\/|%|\\#|\\^|~|<|>|<=|=>|==|~=|=|\\:|\\.\\.\\.|\\.\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text",
+ regex : "\\s+|\\w+"
+ } ]
+ };
+
+ this.normalizeRules();
+}
+
+oop.inherits(LuaHighlightRules, TextHighlightRules);
+
+exports.LuaHighlightRules = LuaHighlightRules;
+});
+
+ace.define("ace/mode/folding/lua",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+
+var FoldMode = exports.FoldMode = function() {};
+
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /\b(function|then|do|repeat)\b|{\s*$|(\[=*\[)/;
+ this.foldingStopMarker = /\bend\b|^\s*}|\]=*\]/;
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var isStart = this.foldingStartMarker.test(line);
+ var isEnd = this.foldingStopMarker.test(line);
+
+ if (isStart && !isEnd) {
+ var match = line.match(this.foldingStartMarker);
+ if (match[1] == "then" && /\belseif\b/.test(line))
+ return;
+ if (match[1]) {
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
+ return "start";
+ } else if (match[2]) {
+ var type = session.bgTokenizer.getState(row) || "";
+ if (type[0] == "bracketedComment" || type[0] == "bracketedString")
+ return "start";
+ } else {
+ return "start";
+ }
+ }
+ if (foldStyle != "markbeginend" || !isEnd || isStart && isEnd)
+ return "";
+
+ var match = line.match(this.foldingStopMarker);
+ if (match[0] === "end") {
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
+ return "end";
+ } else if (match[0][0] === "]") {
+ var type = session.bgTokenizer.getState(row - 1) || "";
+ if (type[0] == "bracketedComment" || type[0] == "bracketedString")
+ return "end";
+ } else
+ return "end";
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.doc.getLine(row);
+ var match = this.foldingStartMarker.exec(line);
+ if (match) {
+ if (match[1])
+ return this.luaBlock(session, row, match.index + 1);
+
+ if (match[2])
+ return session.getCommentFoldRange(row, match.index + 1);
+
+ return this.openingBracketBlock(session, "{", row, match.index);
+ }
+
+ var match = this.foldingStopMarker.exec(line);
+ if (match) {
+ if (match[0] === "end") {
+ if (session.getTokenAt(row, match.index + 1).type === "keyword")
+ return this.luaBlock(session, row, match.index + 1);
+ }
+
+ if (match[0][0] === "]")
+ return session.getCommentFoldRange(row, match.index + 1);
+
+ return this.closingBracketBlock(session, "}", row, match.index + match[0].length);
+ }
+ };
+
+ this.luaBlock = function(session, row, column) {
+ var stream = new TokenIterator(session, row, column);
+ var indentKeywords = {
+ "function": 1,
+ "do": 1,
+ "then": 1,
+ "elseif": -1,
+ "end": -1,
+ "repeat": 1,
+ "until": -1
+ };
+
+ var token = stream.getCurrentToken();
+ if (!token || token.type != "keyword")
+ return;
+
+ var val = token.value;
+ var stack = [val];
+ var dir = indentKeywords[val];
+
+ if (!dir)
+ return;
+
+ var startColumn = dir === -1 ? stream.getCurrentTokenColumn() : session.getLine(row).length;
+ var startRow = row;
+
+ stream.step = dir === -1 ? stream.stepBackward : stream.stepForward;
+ while(token = stream.step()) {
+ if (token.type !== "keyword")
+ continue;
+ var level = dir * indentKeywords[token.value];
+
+ if (level > 0) {
+ stack.unshift(token.value);
+ } else if (level <= 0) {
+ stack.shift();
+ if (!stack.length && token.value != "elseif")
+ break;
+ if (level === 0)
+ stack.unshift(token.value);
+ }
+ }
+
+ var row = stream.getCurrentTokenRow();
+ if (dir === -1)
+ return new Range(row, session.getLine(row).length, startRow, startColumn);
+ else
+ return new Range(startRow, startColumn, row, stream.getCurrentTokenColumn());
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/lua",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/lua_highlight_rules","ace/mode/folding/lua","ace/range","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LuaHighlightRules = require("./lua_highlight_rules").LuaHighlightRules;
+var LuaFoldMode = require("./folding/lua").FoldMode;
+var Range = require("../range").Range;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+
+var Mode = function() {
+ this.HighlightRules = LuaHighlightRules;
+
+ this.foldingRules = new LuaFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "--[", end: "]--"};
+
+ var indentKeywords = {
+ "function": 1,
+ "then": 1,
+ "do": 1,
+ "else": 1,
+ "elseif": 1,
+ "repeat": 1,
+ "end": -1,
+ "until": -1
+ };
+ var outdentKeywords = [
+ "else",
+ "elseif",
+ "end",
+ "until"
+ ];
+
+ function getNetIndentLevel(tokens) {
+ var level = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (token.type == "keyword") {
+ if (token.value in indentKeywords) {
+ level += indentKeywords[token.value];
+ }
+ } else if (token.type == "paren.lparen") {
+ level += token.value.length;
+ } else if (token.type == "paren.rparen") {
+ level -= token.value.length;
+ }
+ }
+ if (level < 0) {
+ return -1;
+ } else if (level > 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ }
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var level = 0;
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (state == "start") {
+ level = getNetIndentLevel(tokens);
+ }
+ if (level > 0) {
+ return indent + tab;
+ } else if (level < 0 && indent.substr(indent.length - tab.length) == tab) {
+ if (!this.checkOutdent(state, line, "\n")) {
+ return indent.substr(0, indent.length - tab.length);
+ }
+ }
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input != "\n" && input != "\r" && input != "\r\n")
+ return false;
+
+ if (line.match(/^\s*[\)\}\]]$/))
+ return true;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens || !tokens.length)
+ return false;
+
+ return (tokens[0].type == "keyword" && outdentKeywords.indexOf(tokens[0].value) != -1);
+ };
+
+ this.autoOutdent = function(state, session, row) {
+ var prevLine = session.getLine(row - 1);
+ var prevIndent = this.$getIndent(prevLine).length;
+ var prevTokens = this.getTokenizer().getLineTokens(prevLine, "start").tokens;
+ var tabLength = session.getTabString().length;
+ var expectedIndent = prevIndent + tabLength * getNetIndentLevel(prevTokens);
+ var curIndent = this.$getIndent(session.getLine(row)).length;
+ if (curIndent <= expectedIndent) {
+ return;
+ }
+ session.outdentRows(new Range(row, 0, row + 2, 0));
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/lua_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/lua";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/luapage_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules","ace/mode/lua_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var LuaHighlightRules = require("./lua_highlight_rules").LuaHighlightRules;
+
+var LuaPageHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var startRules = [
+ {
+ token: "keyword",
+ regex: "<\\%\\=?",
+ push: "lua-start"
+ }, {
+ token: "keyword",
+ regex: "<\\?lua\\=?",
+ push: "lua-start"
+ }
+ ];
+
+ var endRules = [
+ {
+ token: "keyword",
+ regex: "\\%>",
+ next: "pop"
+ }, {
+ token: "keyword",
+ regex: "\\?>",
+ next: "pop"
+ }
+ ];
+
+ this.embedRules(LuaHighlightRules, "lua-", endRules, ["start"]);
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], startRules);
+
+ this.normalizeRules();
+};
+
+oop.inherits(LuaPageHighlightRules, HtmlHighlightRules);
+
+exports.LuaPageHighlightRules = LuaPageHighlightRules;
+
+});
+
+ace.define("ace/mode/luapage",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/lua","ace/mode/luapage_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var LuaMode = require("./lua").Mode;
+var LuaPageHighlightRules = require("./luapage_highlight_rules").LuaPageHighlightRules;
+
+var Mode = function() {
+ HtmlMode.call(this);
+
+ this.HighlightRules = LuaPageHighlightRules;
+ this.createModeDelegates({
+ "lua-": LuaMode
+ });
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.$id = "ace/mode/luapage";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-lucene.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-lucene.js
new file mode 100644
index 00000000..b830b7ae
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-lucene.js
@@ -0,0 +1,70 @@
+ace.define("ace/mode/lucene_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LuceneHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "constant.character.negation",
+ regex : "[\\-]"
+ }, {
+ token : "constant.character.interro",
+ regex : "[\\?]"
+ }, {
+ token : "constant.character.asterisk",
+ regex : "[\\*]"
+ }, {
+ token: 'constant.character.proximity',
+ regex: '~[0-9]+\\b'
+ }, {
+ token : 'keyword.operator',
+ regex: '(?:AND|OR|NOT)\\b'
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "keyword",
+ regex : "[\\S]+:"
+ }, {
+ token : "string", // " string
+ regex : '".*?"'
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ]
+ };
+};
+
+oop.inherits(LuceneHighlightRules, TextHighlightRules);
+
+exports.LuceneHighlightRules = LuceneHighlightRules;
+});
+
+ace.define("ace/mode/lucene",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/lucene_highlight_rules"], function(require, exports, module) {
+'use strict';
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var LuceneHighlightRules = require("./lucene_highlight_rules").LuceneHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = LuceneHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$id = "ace/mode/lucene";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-makefile.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-makefile.js
new file mode 100644
index 00000000..e59bd3e7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-makefile.js
@@ -0,0 +1,404 @@
+ace.define("ace/mode/sh_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var reservedKeywords = exports.reservedKeywords = (
+ '!|{|}|case|do|done|elif|else|'+
+ 'esac|fi|for|if|in|then|until|while|'+
+ '&|;|export|local|read|typeset|unset|'+
+ 'elif|select|set|function|declare|readonly'
+ );
+
+var languageConstructs = exports.languageConstructs = (
+ '[|]|alias|bg|bind|break|builtin|'+
+ 'cd|command|compgen|complete|continue|'+
+ 'dirs|disown|echo|enable|eval|exec|'+
+ 'exit|fc|fg|getopts|hash|help|history|'+
+ 'jobs|kill|let|logout|popd|printf|pushd|'+
+ 'pwd|return|set|shift|shopt|source|'+
+ 'suspend|test|times|trap|type|ulimit|'+
+ 'umask|unalias|wait'
+);
+
+var ShHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": reservedKeywords,
+ "support.function.builtin": languageConstructs,
+ "invalid.deprecated": "debugger"
+ }, "identifier");
+
+ var integer = "(?:(?:[1-9]\\d*)|(?:0))";
+
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+ var fileDescriptor = "(?:&" + intPart + ")";
+
+ var variableName = "[a-zA-Z_][a-zA-Z0-9_]*";
+ var variable = "(?:" + variableName + "(?==))";
+
+ var builtinVariable = "(?:\\$(?:SHLVL|\\$|\\!|\\?))";
+
+ var func = "(?:" + variableName + "\\s*\\(\\))";
+
+ this.$rules = {
+ "start" : [{
+ token : "constant",
+ regex : /\\./
+ }, {
+ token : ["text", "comment"],
+ regex : /(^|\s)(#.*)$/
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[$`"\\]|$)/
+ }, {
+ include : "variables"
+ }, {
+ token : "keyword.operator",
+ regex : /`/ // TODO highlight `
+ }, {
+ token : "string.end",
+ regex : '"',
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string",
+ regex : "\\$'",
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[abeEfnrtv\\'"]|x[a-fA-F\d]{1,2}|u[a-fA-F\d]{4}([a-fA-F\d]{4})?|c.|\d{1,3})/
+ }, {
+ token : "string",
+ regex : "'",
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ regex : "<<<",
+ token : "keyword.operator"
+ }, {
+ stateName: "heredoc",
+ regex : "(<<-?)(\\s*)(['\"`]?)([\\w\\-]+)(['\"`]?)",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[4]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"text", value: tokens[2]},
+ {type:"string", value: tokens[3]},
+ {type:"support.class", value: tokens[4]},
+ {type:"string", value: tokens[5]}
+ ];
+ },
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^\t+"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : ["keyword", "text", "text", "text", "variable"],
+ regex : /(declare|local|readonly)(\s+)(?:(-[fixar]+)(\s+))?([a-zA-Z_][a-zA-Z0-9_]*\b)/
+ }, {
+ token : "variable.language",
+ regex : builtinVariable
+ }, {
+ token : "variable",
+ regex : variable
+ }, {
+ include : "variables"
+ }, {
+ token : "support.function",
+ regex : func
+ }, {
+ token : "support.function",
+ regex : fileDescriptor
+ }, {
+ token : "string", // ' string
+ start : "'", end : "'"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_][a-zA-Z0-9_]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|~|<|>|<=|=>|=|!=|[%&|`]"
+ }, {
+ token : "punctuation.operator",
+ regex : ";"
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)\\}]",
+ next : "pop"
+ }],
+ variables: [{
+ token : "variable",
+ regex : /(\$)(\w+)/
+ }, {
+ token : ["variable", "paren.lparen"],
+ regex : /(\$)(\()/,
+ push : "start"
+ }, {
+ token : ["variable", "paren.lparen", "keyword.operator", "variable", "keyword.operator"],
+ regex : /(\$)(\{)([#!]?)(\w+|[*@#?\-$!0_])(:[?+\-=]?|##?|%%?|,,?\/|\^\^?)?/,
+ push : "start"
+ }, {
+ token : "variable",
+ regex : /\$[*@#?\-$!0_]/
+ }, {
+ token : ["variable", "paren.lparen"],
+ regex : /(\$)(\{)/,
+ push : "start"
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(ShHighlightRules, TextHighlightRules);
+
+exports.ShHighlightRules = ShHighlightRules;
+});
+
+ace.define("ace/mode/makefile_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/sh_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ShHighlightFile = require("./sh_highlight_rules");
+
+var MakefileHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": ShHighlightFile.reservedKeywords,
+ "support.function.builtin": ShHighlightFile.languageConstructs,
+ "invalid.deprecated": "debugger"
+ }, "string");
+
+ this.$rules =
+ {
+ "start": [
+ {
+ token: "string.interpolated.backtick.makefile",
+ regex: "`",
+ next: "shell-start"
+ },
+ {
+ token: "punctuation.definition.comment.makefile",
+ regex: /#(?=.)/,
+ next: "comment"
+ },
+ {
+ token: [ "keyword.control.makefile"],
+ regex: "^(?:\\s*\\b)(\\-??include|ifeq|ifneq|ifdef|ifndef|else|endif|vpath|export|unexport|define|endef|override)(?:\\b)"
+ },
+ {// ^([^\t ]+(\s[^\t ]+)*:(?!\=))\s*.*
+ token: ["entity.name.function.makefile", "text"],
+ regex: "^([^\\t ]+(?:\\s[^\\t ]+)*:)(\\s*.*)"
+ }
+ ],
+ "comment": [
+ {
+ token : "punctuation.definition.comment.makefile",
+ regex : /.+\\/
+ },
+ {
+ token : "punctuation.definition.comment.makefile",
+ regex : ".+",
+ next : "start"
+ }
+ ],
+ "shell-start": [
+ {
+ token: keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ },
+ {
+ token: "string",
+ regex : "\\w+"
+ },
+ {
+ token : "string.interpolated.backtick.makefile",
+ regex : "`",
+ next : "start"
+ }
+ ]
+}
+
+};
+
+oop.inherits(MakefileHighlightRules, TextHighlightRules);
+
+exports.MakefileHighlightRules = MakefileHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/makefile",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/makefile_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MakefileHighlightRules = require("./makefile_highlight_rules").MakefileHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = MakefileHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+ this.$indentWithTabs = true;
+
+ this.$id = "ace/mode/makefile";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-markdown.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-markdown.js
new file mode 100644
index 00000000..51df9be7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-markdown.js
@@ -0,0 +1,2865 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/xml_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/xml","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var XmlFoldMode = require("./folding/xml").FoldMode;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+
+var Mode = function() {
+ this.HighlightRules = XmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.foldingRules = new XmlFoldMode();
+};
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.voidElements = lang.arrayToMap([]);
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/xml_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/xml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/markdown_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules","ace/mode/html_highlight_rules","ace/mode/css_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+
+var escaped = function(ch) {
+ return "(?:[^" + lang.escapeRegExp(ch) + "\\\\]|\\\\.)*";
+}
+
+function github_embed(tag, prefix) {
+ return { // Github style block
+ token : "support.function",
+ regex : "^\\s*```" + tag + "\\s*$",
+ push : prefix + "start"
+ };
+}
+
+var MarkdownHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ this.$rules["start"].unshift({
+ token : "empty_line",
+ regex : '^$',
+ next: "allowBlock"
+ }, { // h1
+ token: "markup.heading.1",
+ regex: "^=+(?=\\s*$)"
+ }, { // h2
+ token: "markup.heading.2",
+ regex: "^\\-+(?=\\s*$)"
+ }, {
+ token : function(value) {
+ return "markup.heading." + value.length;
+ },
+ regex : /^#{1,6}(?=\s*[^ #]|\s+#.)/,
+ next : "header"
+ },
+ github_embed("(?:javascript|js)", "jscode-"),
+ github_embed("xml", "xmlcode-"),
+ github_embed("html", "htmlcode-"),
+ github_embed("css", "csscode-"),
+ { // Github style block
+ token : "support.function",
+ regex : "^\\s*```\\s*\\S*(?:{.*?\\})?\\s*$",
+ next : "githubblock"
+ }, { // block quote
+ token : "string.blockquote",
+ regex : "^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",
+ next : "blockquote"
+ }, { // HR * - _
+ token : "constant",
+ regex : "^ {0,2}(?:(?: ?\\* ?){3,}|(?: ?\\- ?){3,}|(?: ?\\_ ?){3,})\\s*$",
+ next: "allowBlock"
+ }, { // list
+ token : "markup.list",
+ regex : "^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",
+ next : "listblock-start"
+ }, {
+ include : "basic"
+ });
+
+ this.addRules({
+ "basic" : [{
+ token : "constant.language.escape",
+ regex : /\\[\\`*_{}\[\]()#+\-.!]/
+ }, { // code span `
+ token : "support.function",
+ regex : "(`+)(.*?[^`])(\\1)"
+ }, { // reference
+ token : ["text", "constant", "text", "url", "string", "text"],
+ regex : "^([ ]{0,3}\\[)([^\\]]+)(\\]:\\s*)([^ ]+)(\\s*(?:[\"][^\"]+[\"])?(\\s*))$"
+ }, { // link by reference
+ token : ["text", "string", "text", "constant", "text"],
+ regex : "(\\[)(" + escaped("]") + ")(\\]\\s*\\[)("+ escaped("]") + ")(\\])"
+ }, { // link by url
+ token : ["text", "string", "text", "markup.underline", "string", "text"],
+ regex : "(\\[)(" + // [
+ escaped("]") + // link text
+ ")(\\]\\()"+ // ](
+ '((?:[^\\)\\s\\\\]|\\\\.|\\s(?=[^"]))*)' + // href
+ '(\\s*"' + escaped('"') + '"\\s*)?' + // "title"
+ "(\\))" // )
+ }, { // strong ** __
+ token : "string.strong",
+ regex : "([*]{2}|[_]{2}(?=\\S))(.*?\\S[*_]*)(\\1)"
+ }, { // emphasis * _
+ token : "string.emphasis",
+ regex : "([*]|[_](?=\\S))(.*?\\S[*_]*)(\\1)"
+ }, { //
+ token : ["text", "url", "text"],
+ regex : "(<)("+
+ "(?:https?|ftp|dict):[^'\">\\s]+"+
+ "|"+
+ "(?:mailto:)?[-.\\w]+\\@[-a-z0-9]+(?:\\.[-a-z0-9]+)*\\.[a-z]+"+
+ ")(>)"
+ }],
+ "allowBlock": [
+ {token : "support.function", regex : "^ {4}.+", next : "allowBlock"},
+ {token : "empty_line", regex : '^$', next: "allowBlock"},
+ {token : "empty", regex : "", next : "start"}
+ ],
+
+ "header" : [{
+ regex: "$",
+ next : "start"
+ }, {
+ include: "basic"
+ }, {
+ defaultToken : "heading"
+ } ],
+
+ "listblock-start" : [{
+ token : "support.variable",
+ regex : /(?:\[[ x]\])?/,
+ next : "listblock"
+ }],
+
+ "listblock" : [ { // Lists only escape on completely blank lines.
+ token : "empty_line",
+ regex : "^$",
+ next : "start"
+ }, { // list
+ token : "markup.list",
+ regex : "^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",
+ next : "listblock-start"
+ }, {
+ include : "basic", noEscape: true
+ }, { // Github style block
+ token : "support.function",
+ regex : "^\\s*```\\s*[a-zA-Z]*(?:{.*?\\})?\\s*$",
+ next : "githubblock"
+ }, {
+ defaultToken : "list" //do not use markup.list to allow stling leading `*` differntly
+ } ],
+
+ "blockquote" : [ { // Blockquotes only escape on blank lines.
+ token : "empty_line",
+ regex : "^\\s*$",
+ next : "start"
+ }, { // block quote
+ token : "string.blockquote",
+ regex : "^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",
+ next : "blockquote"
+ }, {
+ include : "basic", noEscape: true
+ }, {
+ defaultToken : "string.blockquote"
+ } ],
+
+ "githubblock" : [ {
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "start"
+ }, {
+ defaultToken : "support.function"
+ } ]
+ });
+
+ this.embedRules(JavaScriptHighlightRules, "jscode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(HtmlHighlightRules, "htmlcode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(CssHighlightRules, "csscode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(XmlHighlightRules, "xmlcode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.normalizeRules();
+};
+oop.inherits(MarkdownHighlightRules, TextHighlightRules);
+
+exports.MarkdownHighlightRules = MarkdownHighlightRules;
+});
+
+ace.define("ace/mode/folding/markdown",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+ this.foldingStartMarker = /^(?:[=-]+\s*$|#{1,6} |`{3})/;
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ if (!this.foldingStartMarker.test(line))
+ return "";
+
+ if (line[0] == "`") {
+ if (session.bgTokenizer.getState(row) == "start")
+ return "end";
+ return "start";
+ }
+
+ return "start";
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+ if (!line.match(this.foldingStartMarker))
+ return;
+
+ if (line[0] == "`") {
+ if (session.bgTokenizer.getState(row) !== "start") {
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ if (line[0] == "`" & line.substring(0, 3) == "```")
+ break;
+ }
+ return new Range(startRow, startColumn, row, 0);
+ } else {
+ while (row -- > 0) {
+ line = session.getLine(row);
+ if (line[0] == "`" & line.substring(0, 3) == "```")
+ break;
+ }
+ return new Range(row, line.length, startRow, 0);
+ }
+ }
+
+ var token;
+ function isHeading(row) {
+ token = session.getTokens(row)[0];
+ return token && token.type.lastIndexOf(heading, 0) === 0;
+ }
+
+ var heading = "markup.heading";
+ function getLevel() {
+ var ch = token.value[0];
+ if (ch == "=") return 6;
+ if (ch == "-") return 5;
+ return 7 - token.value.search(/[^#]/);
+ }
+
+ if (isHeading(row)) {
+ var startHeadingLevel = getLevel();
+ while (++row < maxRow) {
+ if (!isHeading(row))
+ continue;
+ var level = getLevel();
+ if (level >= startHeadingLevel)
+ break;
+ }
+
+ endRow = row - (!token || ["=", "-"].indexOf(token.value[0]) == -1 ? 1 : 2);
+
+ if (endRow > startRow) {
+ while (endRow > startRow && /^\s*$/.test(session.getLine(endRow)))
+ endRow--;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/markdown",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript","ace/mode/xml","ace/mode/html","ace/mode/markdown_highlight_rules","ace/mode/folding/markdown"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var XmlMode = require("./xml").Mode;
+var HtmlMode = require("./html").Mode;
+var MarkdownHighlightRules = require("./markdown_highlight_rules").MarkdownHighlightRules;
+var MarkdownFoldMode = require("./folding/markdown").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = MarkdownHighlightRules;
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "xml-": XmlMode,
+ "html-": HtmlMode
+ });
+
+ this.foldingRules = new MarkdownFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.type = "text";
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ if (state == "listblock") {
+ var match = /^(\s*)(?:([-+*])|(\d+)\.)(\s+)/.exec(line);
+ if (!match)
+ return "";
+ var marker = match[2];
+ if (!marker)
+ marker = parseInt(match[3], 10) + 1 + ".";
+ return match[1] + marker + match[4];
+ } else {
+ return this.$getIndent(line);
+ }
+ };
+ this.$id = "ace/mode/markdown";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-mask.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-mask.js
new file mode 100644
index 00000000..983d02f8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-mask.js
@@ -0,0 +1,1786 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/markdown_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules","ace/mode/html_highlight_rules","ace/mode/css_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+
+var escaped = function(ch) {
+ return "(?:[^" + lang.escapeRegExp(ch) + "\\\\]|\\\\.)*";
+}
+
+function github_embed(tag, prefix) {
+ return { // Github style block
+ token : "support.function",
+ regex : "^\\s*```" + tag + "\\s*$",
+ push : prefix + "start"
+ };
+}
+
+var MarkdownHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ this.$rules["start"].unshift({
+ token : "empty_line",
+ regex : '^$',
+ next: "allowBlock"
+ }, { // h1
+ token: "markup.heading.1",
+ regex: "^=+(?=\\s*$)"
+ }, { // h2
+ token: "markup.heading.2",
+ regex: "^\\-+(?=\\s*$)"
+ }, {
+ token : function(value) {
+ return "markup.heading." + value.length;
+ },
+ regex : /^#{1,6}(?=\s*[^ #]|\s+#.)/,
+ next : "header"
+ },
+ github_embed("(?:javascript|js)", "jscode-"),
+ github_embed("xml", "xmlcode-"),
+ github_embed("html", "htmlcode-"),
+ github_embed("css", "csscode-"),
+ { // Github style block
+ token : "support.function",
+ regex : "^\\s*```\\s*\\S*(?:{.*?\\})?\\s*$",
+ next : "githubblock"
+ }, { // block quote
+ token : "string.blockquote",
+ regex : "^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",
+ next : "blockquote"
+ }, { // HR * - _
+ token : "constant",
+ regex : "^ {0,2}(?:(?: ?\\* ?){3,}|(?: ?\\- ?){3,}|(?: ?\\_ ?){3,})\\s*$",
+ next: "allowBlock"
+ }, { // list
+ token : "markup.list",
+ regex : "^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",
+ next : "listblock-start"
+ }, {
+ include : "basic"
+ });
+
+ this.addRules({
+ "basic" : [{
+ token : "constant.language.escape",
+ regex : /\\[\\`*_{}\[\]()#+\-.!]/
+ }, { // code span `
+ token : "support.function",
+ regex : "(`+)(.*?[^`])(\\1)"
+ }, { // reference
+ token : ["text", "constant", "text", "url", "string", "text"],
+ regex : "^([ ]{0,3}\\[)([^\\]]+)(\\]:\\s*)([^ ]+)(\\s*(?:[\"][^\"]+[\"])?(\\s*))$"
+ }, { // link by reference
+ token : ["text", "string", "text", "constant", "text"],
+ regex : "(\\[)(" + escaped("]") + ")(\\]\\s*\\[)("+ escaped("]") + ")(\\])"
+ }, { // link by url
+ token : ["text", "string", "text", "markup.underline", "string", "text"],
+ regex : "(\\[)(" + // [
+ escaped("]") + // link text
+ ")(\\]\\()"+ // ](
+ '((?:[^\\)\\s\\\\]|\\\\.|\\s(?=[^"]))*)' + // href
+ '(\\s*"' + escaped('"') + '"\\s*)?' + // "title"
+ "(\\))" // )
+ }, { // strong ** __
+ token : "string.strong",
+ regex : "([*]{2}|[_]{2}(?=\\S))(.*?\\S[*_]*)(\\1)"
+ }, { // emphasis * _
+ token : "string.emphasis",
+ regex : "([*]|[_](?=\\S))(.*?\\S[*_]*)(\\1)"
+ }, { //
+ token : ["text", "url", "text"],
+ regex : "(<)("+
+ "(?:https?|ftp|dict):[^'\">\\s]+"+
+ "|"+
+ "(?:mailto:)?[-.\\w]+\\@[-a-z0-9]+(?:\\.[-a-z0-9]+)*\\.[a-z]+"+
+ ")(>)"
+ }],
+ "allowBlock": [
+ {token : "support.function", regex : "^ {4}.+", next : "allowBlock"},
+ {token : "empty_line", regex : '^$', next: "allowBlock"},
+ {token : "empty", regex : "", next : "start"}
+ ],
+
+ "header" : [{
+ regex: "$",
+ next : "start"
+ }, {
+ include: "basic"
+ }, {
+ defaultToken : "heading"
+ } ],
+
+ "listblock-start" : [{
+ token : "support.variable",
+ regex : /(?:\[[ x]\])?/,
+ next : "listblock"
+ }],
+
+ "listblock" : [ { // Lists only escape on completely blank lines.
+ token : "empty_line",
+ regex : "^$",
+ next : "start"
+ }, { // list
+ token : "markup.list",
+ regex : "^\\s{0,3}(?:[*+-]|\\d+\\.)\\s+",
+ next : "listblock-start"
+ }, {
+ include : "basic", noEscape: true
+ }, { // Github style block
+ token : "support.function",
+ regex : "^\\s*```\\s*[a-zA-Z]*(?:{.*?\\})?\\s*$",
+ next : "githubblock"
+ }, {
+ defaultToken : "list" //do not use markup.list to allow stling leading `*` differntly
+ } ],
+
+ "blockquote" : [ { // Blockquotes only escape on blank lines.
+ token : "empty_line",
+ regex : "^\\s*$",
+ next : "start"
+ }, { // block quote
+ token : "string.blockquote",
+ regex : "^\\s*>\\s*(?:[*+-]|\\d+\\.)?\\s+",
+ next : "blockquote"
+ }, {
+ include : "basic", noEscape: true
+ }, {
+ defaultToken : "string.blockquote"
+ } ],
+
+ "githubblock" : [ {
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "start"
+ }, {
+ defaultToken : "support.function"
+ } ]
+ });
+
+ this.embedRules(JavaScriptHighlightRules, "jscode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(HtmlHighlightRules, "htmlcode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(CssHighlightRules, "csscode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.embedRules(XmlHighlightRules, "xmlcode-", [{
+ token : "support.function",
+ regex : "^\\s*```",
+ next : "pop"
+ }]);
+
+ this.normalizeRules();
+};
+oop.inherits(MarkdownHighlightRules, TextHighlightRules);
+
+exports.MarkdownHighlightRules = MarkdownHighlightRules;
+});
+
+ace.define("ace/mode/mask_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/css_highlight_rules","ace/mode/markdown_highlight_rules","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+exports.MaskHighlightRules = MaskHighlightRules;
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextRules = require("./text_highlight_rules").TextHighlightRules;
+var JSRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var CssRules = require("./css_highlight_rules").CssHighlightRules;
+var MDRules = require("./markdown_highlight_rules").MarkdownHighlightRules;
+var HTMLRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var token_TAG = "keyword.support.constant.language",
+ token_COMPO = "support.function.markup.bold",
+ token_KEYWORD = "keyword",
+ token_LANG = "constant.language",
+ token_UTIL = "keyword.control.markup.italic",
+ token_ATTR = "support.variable.class",
+ token_PUNKT = "keyword.operator",
+ token_ITALIC = "markup.italic",
+ token_BOLD = "markup.bold",
+ token_LPARE = "paren.lparen",
+ token_RPARE = "paren.rparen";
+
+var const_FUNCTIONS,
+ const_KEYWORDS,
+ const_CONST,
+ const_TAGS;
+(function(){
+ const_FUNCTIONS = lang.arrayToMap(
+ ("log").split("|")
+ );
+ const_CONST = lang.arrayToMap(
+ (":dualbind|:bind|:import|slot|event|style|html|markdown|md").split("|")
+ );
+ const_KEYWORDS = lang.arrayToMap(
+ ("debugger|define|var|if|each|for|of|else|switch|case|with|visible|+if|+each|+for|+switch|+with|+visible|include|import").split("|")
+ );
+ const_TAGS = lang.arrayToMap(
+ ("a|abbr|acronym|address|applet|area|article|aside|audio|b|base|basefont|bdo|" +
+ "big|blockquote|body|br|button|canvas|caption|center|cite|code|col|colgroup|" +
+ "command|datalist|dd|del|details|dfn|dir|div|dl|dt|em|embed|fieldset|" +
+ "figcaption|figure|font|footer|form|frame|frameset|h1|h2|h3|h4|h5|h6|head|" +
+ "header|hgroup|hr|html|i|iframe|img|input|ins|keygen|kbd|label|legend|li|" +
+ "link|map|mark|menu|meta|meter|nav|noframes|noscript|object|ol|optgroup|" +
+ "option|output|p|param|pre|progress|q|rp|rt|ruby|s|samp|script|section|select|" +
+ "small|source|span|strike|strong|style|sub|summary|sup|table|tbody|td|" +
+ "textarea|tfoot|th|thead|time|title|tr|tt|u|ul|var|video|wbr|xmp").split("|")
+ );
+}());
+
+function MaskHighlightRules () {
+
+ this.$rules = {
+ "start" : [
+ Token("comment", "\\/\\/.*$"),
+ Token("comment", "\\/\\*", [
+ Token("comment", ".*?\\*\\/", "start"),
+ Token("comment", ".+")
+ ]),
+
+ Blocks.string("'''"),
+ Blocks.string('"""'),
+ Blocks.string('"'),
+ Blocks.string("'"),
+
+ Blocks.syntax(/(markdown|md)\b/, "md-multiline", "multiline"),
+ Blocks.syntax(/html\b/, "html-multiline", "multiline"),
+ Blocks.syntax(/(slot|event)\b/, "js-block", "block"),
+ Blocks.syntax(/style\b/, "css-block", "block"),
+ Blocks.syntax(/var\b/, "js-statement", "attr"),
+
+ Blocks.tag(),
+
+ Token(token_LPARE, "[[({>]"),
+ Token(token_RPARE, "[\\])};]", "start"),
+ {
+ caseInsensitive: true
+ }
+ ]
+ };
+ var rules = this;
+
+ addJavaScript("interpolation", /\]/, token_RPARE + "." + token_ITALIC);
+ addJavaScript("statement", /\)|}|;/);
+ addJavaScript("block", /\}/);
+ addCss();
+ addMarkdown();
+ addHtml();
+
+ function addJavaScript(name, escape, closeType) {
+ var prfx = "js-" + name + "-",
+ rootTokens = name === "block" ? ["start"] : ["start", "no_regex"];
+ add(
+ JSRules
+ , prfx
+ , escape
+ , rootTokens
+ , closeType
+ );
+ }
+ function addCss() {
+ add(CssRules, "css-block-", /\}/);
+ }
+ function addMarkdown() {
+ add(MDRules, "md-multiline-", /("""|''')/, []);
+ }
+ function addHtml() {
+ add(HTMLRules, "html-multiline-", /("""|''')/);
+ }
+ function add(Rules, strPrfx, rgxEnd, rootTokens, closeType) {
+ var next = "pop";
+ var tokens = rootTokens || [ "start" ];
+ if (tokens.length === 0) {
+ tokens = null;
+ }
+ if (/block|multiline/.test(strPrfx)) {
+ next = strPrfx + "end";
+ rules.$rules[next] = [
+ Token("empty", "", "start")
+ ];
+ }
+ rules.embedRules(
+ Rules
+ , strPrfx
+ , [ Token(closeType || token_RPARE, rgxEnd, next) ]
+ , tokens
+ , tokens == null ? true : false
+ );
+ }
+
+ this.normalizeRules();
+}
+oop.inherits(MaskHighlightRules, TextRules);
+
+var Blocks = {
+ string: function(str, next){
+ var token = Token(
+ "string.start"
+ , str
+ , [
+ Token(token_LPARE + "." + token_ITALIC, /~\[/, Blocks.interpolation()),
+ Token("string.end", str, "pop"),
+ {
+ defaultToken: "string"
+ }
+ ]
+ , next
+ );
+ if (str.length === 1){
+ var escaped = Token("string.escape", "\\\\" + str);
+ token.push.unshift(escaped);
+ }
+ return token;
+ },
+ interpolation: function(){
+ return [
+ Token(token_UTIL, /\s*\w*\s*:/),
+ "js-interpolation-start"
+ ];
+ },
+ tagHead: function (rgx) {
+ return Token(token_ATTR, rgx, [
+ Token(token_ATTR, /[\w\-_]+/),
+ Token(token_LPARE + "." + token_ITALIC, /~\[/, Blocks.interpolation()),
+ Blocks.goUp()
+ ]);
+ },
+ tag: function () {
+ return {
+ token: 'tag',
+ onMatch : function(value) {
+ if (void 0 !== const_KEYWORDS[value])
+ return token_KEYWORD;
+ if (void 0 !== const_CONST[value])
+ return token_LANG;
+ if (void 0 !== const_FUNCTIONS[value])
+ return "support.function";
+ if (void 0 !== const_TAGS[value.toLowerCase()])
+ return token_TAG;
+
+ return token_COMPO;
+ },
+ regex : /([@\w\-_:+]+)|((^|\s)(?=\s*(\.|#)))/,
+ push: [
+ Blocks.tagHead(/\./) ,
+ Blocks.tagHead(/#/) ,
+ Blocks.expression(),
+ Blocks.attribute(),
+
+ Token(token_LPARE, /[;>{]/, "pop")
+ ]
+ };
+ },
+ syntax: function(rgx, next, type){
+ return {
+ token: token_LANG,
+ regex : rgx,
+ push: ({
+ "attr": [
+ next + "-start",
+ Token(token_PUNKT, /;/, "start")
+ ],
+ "multiline": [
+ Blocks.tagHead(/\./) ,
+ Blocks.tagHead(/#/) ,
+ Blocks.attribute(),
+ Blocks.expression(),
+ Token(token_LPARE, /[>\{]/),
+ Token(token_PUNKT, /;/, "start"),
+ Token(token_LPARE, /'''|"""/, [ next + "-start" ])
+ ],
+ "block": [
+ Blocks.tagHead(/\./) ,
+ Blocks.tagHead(/#/) ,
+ Blocks.attribute(),
+ Blocks.expression(),
+ Token(token_LPARE, /\{/, [ next + "-start" ])
+ ]
+ })[type]
+ };
+ },
+ attribute: function(){
+ return Token(function(value){
+ return /^x\-/.test(value)
+ ? token_ATTR + "." + token_BOLD
+ : token_ATTR;
+ }, /[\w_-]+/, [
+ Token(token_PUNKT, /\s*=\s*/, [
+ Blocks.string('"'),
+ Blocks.string("'"),
+ Blocks.word(),
+ Blocks.goUp()
+ ]),
+ Blocks.goUp()
+ ]);
+ },
+ expression: function(){
+ return Token(token_LPARE, /\(/, [ "js-statement-start" ]);
+ },
+ word: function(){
+ return Token("string", /[\w-_]+/);
+ },
+ goUp: function(){
+ return Token("text", "", "pop");
+ },
+ goStart: function(){
+ return Token("text", "", "start");
+ }
+};
+
+
+function Token(token, rgx, mix) {
+ var push, next, onMatch;
+ if (arguments.length === 4) {
+ push = mix;
+ next = arguments[3];
+ }
+ else if (typeof mix === "string") {
+ next = mix;
+ }
+ else {
+ push = mix;
+ }
+ if (typeof token === "function") {
+ onMatch = token;
+ token = "empty";
+ }
+ return {
+ token: token,
+ regex: rgx,
+ push: push,
+ next: next,
+ onMatch: onMatch
+ };
+}
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/mask",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/mask_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MaskHighlightRules = require("./mask_highlight_rules").MaskHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = MaskHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/mask";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-matlab.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-matlab.js
new file mode 100644
index 00000000..b8870403
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-matlab.js
@@ -0,0 +1,256 @@
+ace.define("ace/mode/matlab_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var MatlabHighlightRules = function() {
+
+var keywords = (
+ "break|case|catch|classdef|continue|else|elseif|end|for|function|global|if|otherwise|parfor|persistent|return|spmd|switch|try|while"
+ );
+
+ var builtinConstants = (
+ "true|false|inf|Inf|nan|NaN|eps|pi|ans|nargin|nargout|varargin|varargout"
+ );
+
+ var builtinFunctions = (
+ "abs|accumarray|acos(?:d|h)?|acot(?:d|h)?|acsc(?:d|h)?|actxcontrol(?:list|select)?|actxGetRunningServer|actxserver|addlistener|addpath|addpref|addtodate|"+
+ "airy|align|alim|all|allchild|alpha|alphamap|amd|ancestor|and|angle|annotation|any|area|arrayfun|asec(?:d|h)?|asin(?:d|h)?|assert|assignin|atan(?:2|d|h)?|" +
+ "audiodevinfo|audioplayer|audiorecorder|aufinfo|auread|autumn|auwrite|avifile|aviinfo|aviread|axes|axis|balance|bar(?:3|3h|h)?|base2dec|beep|BeginInvoke|bench|"+
+ "bessel(?:h|i|j|k|y)|beta|betainc|betaincinv|betaln|bicg|bicgstab|bicgstabl|bin2dec|bitand|bitcmp|bitget|bitmax|bitnot|bitor|bitset|bitshift|bitxor|blanks|blkdiag|"+
+ "bone|box|brighten|brush|bsxfun|builddocsearchdb|builtin|bvp4c|bvp5c|bvpget|bvpinit|bvpset|bvpxtend|calendar|calllib|callSoapService|camdolly|cameratoolbar|camlight|"+
+ "camlookat|camorbit|campan|campos|camproj|camroll|camtarget|camup|camva|camzoom|cart2pol|cart2sph|cast|cat|caxis|cd|cdf2rdf|cdfepoch|cdfinfo|cdflib(?:.(?:close|closeVar|"+
+ "computeEpoch|computeEpoch16|create|createAttr|createVar|delete|deleteAttr|deleteAttrEntry|deleteAttrgEntry|deleteVar|deleteVarRecords|epoch16Breakdown|epochBreakdown|getAttrEntry|"+
+ "getAttrgEntry|getAttrMaxEntry|getAttrMaxgEntry|getAttrName|getAttrNum|getAttrScope|getCacheSize|getChecksum|getCompression|getCompressionCacheSize|getConstantNames|"+
+ "getConstantValue|getCopyright|getFileBackward|getFormat|getLibraryCopyright|getLibraryVersion|getMajority|getName|getNumAttrEntries|getNumAttrgEntries|getNumAttributes|"+
+ "getNumgAttributes|getReadOnlyMode|getStageCacheSize|getValidate|getVarAllocRecords|getVarBlockingFactor|getVarCacheSize|getVarCompression|getVarData|getVarMaxAllocRecNum|"+
+ "getVarMaxWrittenRecNum|getVarName|getVarNum|getVarNumRecsWritten|getVarPadValue|getVarRecordData|getVarReservePercent|getVarsMaxWrittenRecNum|getVarSparseRecords|getVersion|"+
+ "hyperGetVarData|hyperPutVarData|inquire|inquireAttr|inquireAttrEntry|inquireAttrgEntry|inquireVar|open|putAttrEntry|putAttrgEntry|putVarData|putVarRecordData|renameAttr|"+
+ "renameVar|setCacheSize|setChecksum|setCompression|setCompressionCacheSize|setFileBackward|setFormat|setMajority|setReadOnlyMode|setStageCacheSize|setValidate|"+
+ "setVarAllocBlockRecords|setVarBlockingFactor|setVarCacheSize|setVarCompression|setVarInitialRecs|setVarPadValue|SetVarReservePercent|setVarsCacheSize|setVarSparseRecords))?|"+
+ "cdfread|cdfwrite|ceil|cell2mat|cell2struct|celldisp|cellfun|cellplot|cellstr|cgs|checkcode|checkin|checkout|chol|cholinc|cholupdate|circshift|cla|clabel|class|clc|clear|"+
+ "clearvars|clf|clipboard|clock|close|closereq|cmopts|cmpermute|cmunique|colamd|colon|colorbar|colordef|colormap|colormapeditor|colperm|Combine|comet|comet3|commandhistory|"+
+ "commandwindow|compan|compass|complex|computer|cond|condeig|condest|coneplot|conj|containers.Map|contour(?:3|c|f|slice)?|contrast|conv|conv2|convhull|convhulln|convn|cool|"+
+ "copper|copyfile|copyobj|corrcoef|cos(?:d|h)?|cot(?:d|h)?|cov|cplxpair|cputime|createClassFromWsdl|createSoapMessage|cross|csc(?:d|h)?|csvread|csvwrite|ctranspose|cumprod|"+
+ "cumsum|cumtrapz|curl|customverctrl|cylinder|daqread|daspect|datacursormode|datatipinfo|date|datenum|datestr|datetick|datevec|dbclear|dbcont|dbdown|dblquad|dbmex|dbquit|"+
+ "dbstack|dbstatus|dbstep|dbstop|dbtype|dbup|dde23|ddeget|ddesd|ddeset|deal|deblank|dec2base|dec2bin|dec2hex|decic|deconv|del2|delaunay|delaunay3|delaunayn|DelaunayTri|delete|"+
+ "demo|depdir|depfun|det|detrend|deval|diag|dialog|diary|diff|diffuse|dir|disp|display|dither|divergence|dlmread|dlmwrite|dmperm|doc|docsearch|dos|dot|dragrect|drawnow|dsearch|"+
+ "dsearchn|dynamicprops|echo|echodemo|edit|eig|eigs|ellipj|ellipke|ellipsoid|empty|enableNETfromNetworkDrive|enableservice|EndInvoke|enumeration|eomday|eq|erf|erfc|erfcinv|"+
+ "erfcx|erfinv|error|errorbar|errordlg|etime|etree|etreeplot|eval|evalc|evalin|event.(?:EventData|listener|PropertyEvent|proplistener)|exifread|exist|exit|exp|expint|expm|"+
+ "expm1|export2wsdlg|eye|ezcontour|ezcontourf|ezmesh|ezmeshc|ezplot|ezplot3|ezpolar|ezsurf|ezsurfc|factor|factorial|fclose|feather|feature|feof|ferror|feval|fft|fft2|fftn|"+
+ "fftshift|fftw|fgetl|fgets|fieldnames|figure|figurepalette|fileattrib|filebrowser|filemarker|fileparts|fileread|filesep|fill|fill3|filter|filter2|find|findall|findfigs|"+
+ "findobj|findstr|finish|fitsdisp|fitsinfo|fitsread|fitswrite|fix|flag|flipdim|fliplr|flipud|floor|flow|fminbnd|fminsearch|fopen|format|fplot|fprintf|frame2im|fread|freqspace|"+
+ "frewind|fscanf|fseek|ftell|FTP|full|fullfile|func2str|functions|funm|fwrite|fzero|gallery|gamma|gammainc|gammaincinv|gammaln|gca|gcbf|gcbo|gcd|gcf|gco|ge|genpath|genvarname|"+
+ "get|getappdata|getenv|getfield|getframe|getpixelposition|getpref|ginput|gmres|gplot|grabcode|gradient|gray|graymon|grid|griddata(?:3|n)?|griddedInterpolant|gsvd|gt|gtext|"+
+ "guidata|guide|guihandles|gunzip|gzip|h5create|h5disp|h5info|h5read|h5readatt|h5write|h5writeatt|hadamard|handle|hankel|hdf|hdf5|hdf5info|hdf5read|hdf5write|hdfinfo|"+
+ "hdfread|hdftool|help|helpbrowser|helpdesk|helpdlg|helpwin|hess|hex2dec|hex2num|hgexport|hggroup|hgload|hgsave|hgsetget|hgtransform|hidden|hilb|hist|histc|hold|home|horzcat|"+
+ "hostid|hot|hsv|hsv2rgb|hypot|ichol|idivide|ifft|ifft2|ifftn|ifftshift|ilu|im2frame|im2java|imag|image|imagesc|imapprox|imfinfo|imformats|import|importdata|imread|imwrite|"+
+ "ind2rgb|ind2sub|inferiorto|info|inline|inmem|inpolygon|input|inputdlg|inputname|inputParser|inspect|instrcallback|instrfind|instrfindall|int2str|integral(?:2|3)?|interp(?:1|"+
+ "1q|2|3|ft|n)|interpstreamspeed|intersect|intmax|intmin|inv|invhilb|ipermute|isa|isappdata|iscell|iscellstr|ischar|iscolumn|isdir|isempty|isequal|isequaln|isequalwithequalnans|"+
+ "isfield|isfinite|isfloat|isglobal|ishandle|ishghandle|ishold|isinf|isinteger|isjava|iskeyword|isletter|islogical|ismac|ismatrix|ismember|ismethod|isnan|isnumeric|isobject|"+
+ "isocaps|isocolors|isonormals|isosurface|ispc|ispref|isprime|isprop|isreal|isrow|isscalar|issorted|isspace|issparse|isstr|isstrprop|isstruct|isstudent|isunix|isvarname|"+
+ "isvector|javaaddpath|javaArray|javachk|javaclasspath|javacomponent|javaMethod|javaMethodEDT|javaObject|javaObjectEDT|javarmpath|jet|keyboard|kron|lasterr|lasterror|"+
+ "lastwarn|lcm|ldivide|ldl|le|legend|legendre|length|libfunctions|libfunctionsview|libisloaded|libpointer|libstruct|license|light|lightangle|lighting|lin2mu|line|lines|"+
+ "linkaxes|linkdata|linkprop|linsolve|linspace|listdlg|listfonts|load|loadlibrary|loadobj|log|log10|log1p|log2|loglog|logm|logspace|lookfor|lower|ls|lscov|lsqnonneg|lsqr|"+
+ "lt|lu|luinc|magic|makehgtform|mat2cell|mat2str|material|matfile|matlab.io.MatFile|matlab.mixin.(?:Copyable|Heterogeneous(?:.getDefaultScalarElement)?)|matlabrc|"+
+ "matlabroot|max|maxNumCompThreads|mean|median|membrane|memmapfile|memory|menu|mesh|meshc|meshgrid|meshz|meta.(?:class(?:.fromName)?|DynamicProperty|EnumeratedValue|event|"+
+ "MetaData|method|package(?:.(?:fromName|getAllPackages))?|property)|metaclass|methods|methodsview|mex(?:.getCompilerConfigurations)?|MException|mexext|mfilename|min|minres|"+
+ "minus|mislocked|mkdir|mkpp|mldivide|mlint|mlintrpt|mlock|mmfileinfo|mmreader|mod|mode|more|move|movefile|movegui|movie|movie2avi|mpower|mrdivide|msgbox|mtimes|mu2lin|"+
+ "multibandread|multibandwrite|munlock|namelengthmax|nargchk|narginchk|nargoutchk|native2unicode|nccreate|ncdisp|nchoosek|ncinfo|ncread|ncreadatt|ncwrite|ncwriteatt|"+
+ "ncwriteschema|ndgrid|ndims|ne|NET(?:.(?:addAssembly|Assembly|convertArray|createArray|createGeneric|disableAutoRelease|enableAutoRelease|GenericClass|invokeGenericMethod|"+
+ "NetException|setStaticProperty))?|netcdf.(?:abort|close|copyAtt|create|defDim|defGrp|defVar|defVarChunking|defVarDeflate|defVarFill|defVarFletcher32|delAtt|endDef|getAtt|"+
+ "getChunkCache|getConstant|getConstantNames|getVar|inq|inqAtt|inqAttID|inqAttName|inqDim|inqDimID|inqDimIDs|inqFormat|inqGrpName|inqGrpNameFull|inqGrpParent|inqGrps|"+
+ "inqLibVers|inqNcid|inqUnlimDims|inqVar|inqVarChunking|inqVarDeflate|inqVarFill|inqVarFletcher32|inqVarID|inqVarIDs|open|putAtt|putVar|reDef|renameAtt|renameDim|renameVar|"+
+ "setChunkCache|setDefaultFormat|setFill|sync)|newplot|nextpow2|nnz|noanimate|nonzeros|norm|normest|not|notebook|now|nthroot|null|num2cell|num2hex|num2str|numel|nzmax|"+
+ "ode(?:113|15i|15s|23|23s|23t|23tb|45)|odeget|odeset|odextend|onCleanup|ones|open|openfig|opengl|openvar|optimget|optimset|or|ordeig|orderfields|ordqz|ordschur|orient|"+
+ "orth|pack|padecoef|pagesetupdlg|pan|pareto|parseSoapResponse|pascal|patch|path|path2rc|pathsep|pathtool|pause|pbaspect|pcg|pchip|pcode|pcolor|pdepe|pdeval|peaks|perl|perms|"+
+ "permute|pie|pink|pinv|planerot|playshow|plot|plot3|plotbrowser|plotedit|plotmatrix|plottools|plotyy|plus|pol2cart|polar|poly|polyarea|polyder|polyeig|polyfit|polyint|polyval|"+
+ "polyvalm|pow2|power|ppval|prefdir|preferences|primes|print|printdlg|printopt|printpreview|prod|profile|profsave|propedit|propertyeditor|psi|publish|PutCharArray|PutFullMatrix|"+
+ "PutWorkspaceData|pwd|qhull|qmr|qr|qrdelete|qrinsert|qrupdate|quad|quad2d|quadgk|quadl|quadv|questdlg|quit|quiver|quiver3|qz|rand|randi|randn|randperm|RandStream(?:.(?:create|"+
+ "getDefaultStream|getGlobalStream|list|setDefaultStream|setGlobalStream))?|rank|rat|rats|rbbox|rcond|rdivide|readasync|real|reallog|realmax|realmin|realpow|realsqrt|record|"+
+ "rectangle|rectint|recycle|reducepatch|reducevolume|refresh|refreshdata|regexp|regexpi|regexprep|regexptranslate|rehash|rem|Remove|RemoveAll|repmat|reset|reshape|residue|"+
+ "restoredefaultpath|rethrow|rgb2hsv|rgb2ind|rgbplot|ribbon|rmappdata|rmdir|rmfield|rmpath|rmpref|rng|roots|rose|rosser|rot90|rotate|rotate3d|round|rref|rsf2csf|run|save|saveas|"+
+ "saveobj|savepath|scatter|scatter3|schur|sec|secd|sech|selectmoveresize|semilogx|semilogy|sendmail|serial|set|setappdata|setdiff|setenv|setfield|setpixelposition|setpref|setstr|"+
+ "setxor|shading|shg|shiftdim|showplottool|shrinkfaces|sign|sin(?:d|h)?|size|slice|smooth3|snapnow|sort|sortrows|sound|soundsc|spalloc|spaugment|spconvert|spdiags|specular|speye|"+
+ "spfun|sph2cart|sphere|spinmap|spline|spones|spparms|sprand|sprandn|sprandsym|sprank|spring|sprintf|spy|sqrt|sqrtm|squeeze|ss2tf|sscanf|stairs|startup|std|stem|stem3|stopasync|"+
+ "str2double|str2func|str2mat|str2num|strcat|strcmp|strcmpi|stream2|stream3|streamline|streamparticles|streamribbon|streamslice|streamtube|strfind|strjust|strmatch|strncmp|"+
+ "strncmpi|strread|strrep|strtok|strtrim|struct2cell|structfun|strvcat|sub2ind|subplot|subsasgn|subsindex|subspace|subsref|substruct|subvolume|sum|summer|superclasses|superiorto|"+
+ "support|surf|surf2patch|surface|surfc|surfl|surfnorm|svd|svds|swapbytes|symamd|symbfact|symmlq|symrcm|symvar|system|tan(?:d|h)?|tar|tempdir|tempname|tetramesh|texlabel|text|"+
+ "textread|textscan|textwrap|tfqmr|throw|tic|Tiff(?:.(?:getTagNames|getVersion))?|timer|timerfind|timerfindall|times|timeseries|title|toc|todatenum|toeplitz|toolboxdir|trace|"+
+ "transpose|trapz|treelayout|treeplot|tril|trimesh|triplequad|triplot|TriRep|TriScatteredInterp|trisurf|triu|tscollection|tsearch|tsearchn|tstool|type|typecast|uibuttongroup|"+
+ "uicontextmenu|uicontrol|uigetdir|uigetfile|uigetpref|uiimport|uimenu|uiopen|uipanel|uipushtool|uiputfile|uiresume|uisave|uisetcolor|uisetfont|uisetpref|uistack|uitable|"+
+ "uitoggletool|uitoolbar|uiwait|uminus|undocheckout|unicode2native|union|unique|unix|unloadlibrary|unmesh|unmkpp|untar|unwrap|unzip|uplus|upper|urlread|urlwrite|usejava|"+
+ "userpath|validateattributes|validatestring|vander|var|vectorize|ver|verctrl|verLessThan|version|vertcat|VideoReader(?:.isPlatformSupported)?|VideoWriter(?:.getProfiles)?|"+
+ "view|viewmtx|visdiff|volumebounds|voronoi|voronoin|wait|waitbar|waitfor|waitforbuttonpress|warndlg|warning|waterfall|wavfinfo|wavplay|wavread|wavrecord|wavwrite|web|weekday|"+
+ "what|whatsnew|which|whitebg|who|whos|wilkinson|winopen|winqueryreg|winter|wk1finfo|wk1read|wk1write|workspace|xlabel|xlim|xlsfinfo|xlsread|xlswrite|xmlread|xmlwrite|xor|xslt|"+
+ "ylabel|ylim|zeros|zip|zlabel|zlim|zoom|addedvarplot|andrewsplot|anova(?:1|2|n)|ansaribradley|aoctool|barttest|bbdesign|beta(?:cdf|fit|inv|like|pdf|rnd|stat)|bino(?:cdf|fit|inv|"+
+ "pdf|rnd|stat)|biplot|bootci|bootstrp|boxplot|candexch|candgen|canoncorr|capability|capaplot|caseread|casewrite|categorical|ccdesign|cdfplot|chi2(?:cdf|gof|inv|pdf|rnd|stat)|"+
+ "cholcov|Classification(?:BaggedEnsemble|Discriminant(?:.(?:fit|make|template))?|Ensemble|KNN(?:.(?:fit|template))?|PartitionedEnsemble|PartitionedModel|Tree(?:.(?:fit|"+
+ "template))?)|classify|classregtree|cluster|clusterdata|cmdscale|combnk|Compact(?:Classification(?:Discriminant|Ensemble|Tree)|Regression(?:Ensemble|Tree)|TreeBagger)|confusionmat|"+
+ "controlchart|controlrules|cophenet|copula(?:cdf|fit|param|pdf|rnd|stat)|cordexch|corr|corrcov|coxphfit|createns|crosstab|crossval|cvpartition|datasample|dataset|daugment|dcovary|"+
+ "dendrogram|dfittool|disttool|dummyvar|dwtest|ecdf|ecdfhist|ev(?:cdf|fit|inv|like|pdf|rnd|stat)|ExhaustiveSearcher|exp(?:cdf|fit|inv|like|pdf|rnd|stat)|factoran|fcdf|ff2n|finv|"+
+ "fitdist|fitensemble|fpdf|fracfact|fracfactgen|friedman|frnd|fstat|fsurfht|fullfact|gagerr|gam(?:cdf|fit|inv|like|pdf|rnd|stat)|GeneralizedLinearModel(?:.fit)?|geo(?:cdf|inv|mean|"+
+ "pdf|rnd|stat)|gev(?:cdf|fit|inv|like|pdf|rnd|stat)|gline|glmfit|glmval|glyphplot|gmdistribution(?:.fit)?|gname|gp(?:cdf|fit|inv|like|pdf|rnd|stat)|gplotmatrix|grp2idx|grpstats|"+
+ "gscatter|haltonset|harmmean|hist3|histfit|hmm(?:decode|estimate|generate|train|viterbi)|hougen|hyge(?:cdf|inv|pdf|rnd|stat)|icdf|inconsistent|interactionplot|invpred|iqr|iwishrnd|"+
+ "jackknife|jbtest|johnsrnd|KDTreeSearcher|kmeans|knnsearch|kruskalwallis|ksdensity|kstest|kstest2|kurtosis|lasso|lassoglm|lassoPlot|leverage|lhsdesign|lhsnorm|lillietest|"+
+ "LinearModel(?:.fit)?|linhyptest|linkage|logn(?:cdf|fit|inv|like|pdf|rnd|stat)|lsline|mad|mahal|maineffectsplot|manova1|manovacluster|mdscale|mhsample|mle|mlecov|mnpdf|"+
+ "mnrfit|mnrnd|mnrval|moment|multcompare|multivarichart|mvn(?:cdf|pdf|rnd)|mvregress|mvregresslike|mvt(?:cdf|pdf|rnd)|NaiveBayes(?:.fit)?|nan(?:cov|max|mean|median|min|std|"+
+ "sum|var)|nbin(?:cdf|fit|inv|pdf|rnd|stat)|ncf(?:cdf|inv|pdf|rnd|stat)|nct(?:cdf|inv|pdf|rnd|stat)|ncx2(?:cdf|inv|pdf|rnd|stat)|NeighborSearcher|nlinfit|nlintool|nlmefit|nlmefitsa|"+
+ "nlparci|nlpredci|nnmf|nominal|NonLinearModel(?:.fit)?|norm(?:cdf|fit|inv|like|pdf|rnd|stat)|normplot|normspec|ordinal|outlierMeasure|parallelcoords|paretotails|partialcorr|"+
+ "pcacov|pcares|pdf|pdist|pdist2|pearsrnd|perfcurve|perms|piecewisedistribution|plsregress|poiss(?:cdf|fit|inv|pdf|rnd|tat)|polyconf|polytool|prctile|princomp|ProbDist(?:Kernel|"+
+ "Parametric|UnivKernel|UnivParam)?|probplot|procrustes|qqplot|qrandset|qrandstream|quantile|randg|random|randsample|randtool|range|rangesearch|ranksum|rayl(?:cdf|fit|inv|pdf|"+
+ "rnd|stat)|rcoplot|refcurve|refline|regress|Regression(?:BaggedEnsemble|Ensemble|PartitionedEnsemble|PartitionedModel|Tree(?:.(?:fit|template))?)|regstats|relieff|ridge|"+
+ "robustdemo|robustfit|rotatefactors|rowexch|rsmdemo|rstool|runstest|sampsizepwr|scatterhist|sequentialfs|signrank|signtest|silhouette|skewness|slicesample|sobolset|squareform|"+
+ "statget|statset|stepwise|stepwisefit|surfht|tabulate|tblread|tblwrite|tcdf|tdfread|tiedrank|tinv|tpdf|TreeBagger|treedisp|treefit|treeprune|treetest|treeval|trimmean|trnd|tstat|"+
+ "ttest|ttest2|unid(?:cdf|inv|pdf|rnd|stat)|unif(?:cdf|inv|it|pdf|rnd|stat)|vartest(?:2|n)?|wbl(?:cdf|fit|inv|like|pdf|rnd|stat)|wblplot|wishrnd|x2fx|xptread|zscore|ztest"+
+ "adapthisteq|analyze75info|analyze75read|applycform|applylut|axes2pix|bestblk|blockproc|bwarea|bwareaopen|bwboundaries|bwconncomp|bwconvhull|bwdist|bwdistgeodesic|bweuler|"+
+ "bwhitmiss|bwlabel|bwlabeln|bwmorph|bwpack|bwperim|bwselect|bwtraceboundary|bwulterode|bwunpack|checkerboard|col2im|colfilt|conndef|convmtx2|corner|cornermetric|corr2|cp2tform|"+
+ "cpcorr|cpselect|cpstruct2pairs|dct2|dctmtx|deconvblind|deconvlucy|deconvreg|deconvwnr|decorrstretch|demosaic|dicom(?:anon|dict|info|lookup|read|uid|write)|edge|edgetaper|entropy|"+
+ "entropyfilt|fan2para|fanbeam|findbounds|fliptform|freqz2|fsamp2|fspecial|ftrans2|fwind1|fwind2|getheight|getimage|getimagemodel|getline|getneighbors|getnhood|getpts|"+
+ "getrangefromclass|getrect|getsequence|gray2ind|graycomatrix|graycoprops|graydist|grayslice|graythresh|hdrread|hdrwrite|histeq|hough|houghlines|houghpeaks|iccfind|iccread|"+
+ "iccroot|iccwrite|idct2|ifanbeam|im2bw|im2col|im2double|im2int16|im2java2d|im2single|im2uint16|im2uint8|imabsdiff|imadd|imadjust|ImageAdapter|imageinfo|imagemodel|imapplymatrix|"+
+ "imattributes|imbothat|imclearborder|imclose|imcolormaptool|imcomplement|imcontour|imcontrast|imcrop|imdilate|imdisplayrange|imdistline|imdivide|imellipse|imerode|imextendedmax|"+
+ "imextendedmin|imfill|imfilter|imfindcircles|imfreehand|imfuse|imgca|imgcf|imgetfile|imhandles|imhist|imhmax|imhmin|imimposemin|imlincomb|imline|immagbox|immovie|immultiply|imnoise|"+
+ "imopen|imoverview|imoverviewpanel|impixel|impixelinfo|impixelinfoval|impixelregion|impixelregionpanel|implay|impoint|impoly|impositionrect|improfile|imputfile|impyramid|"+
+ "imreconstruct|imrect|imregconfig|imregionalmax|imregionalmin|imregister|imresize|imroi|imrotate|imsave|imscrollpanel|imshow|imshowpair|imsubtract|imtool|imtophat|imtransform|"+
+ "imview|ind2gray|ind2rgb|interfileinfo|interfileread|intlut|ippl|iptaddcallback|iptcheckconn|iptcheckhandle|iptcheckinput|iptcheckmap|iptchecknargin|iptcheckstrs|iptdemos|iptgetapi|"+
+ "iptGetPointerBehavior|iptgetpref|ipticondir|iptnum2ordinal|iptPointerManager|iptprefs|iptremovecallback|iptSetPointerBehavior|iptsetpref|iptwindowalign|iradon|isbw|isflat|isgray|"+
+ "isicc|isind|isnitf|isrgb|isrset|lab2double|lab2uint16|lab2uint8|label2rgb|labelmatrix|makecform|makeConstrainToRectFcn|makehdr|makelut|makeresampler|maketform|mat2gray|mean2|"+
+ "medfilt2|montage|nitfinfo|nitfread|nlfilter|normxcorr2|ntsc2rgb|openrset|ordfilt2|otf2psf|padarray|para2fan|phantom|poly2mask|psf2otf|qtdecomp|qtgetblk|qtsetblk|radon|rangefilt|"+
+ "reflect|regionprops|registration.metric.(?:MattesMutualInformation|MeanSquares)|registration.optimizer.(?:OnePlusOneEvolutionary|RegularStepGradientDescent)|rgb2gray|"+
+ "rgb2ntsc|rgb2ycbcr|roicolor|roifill|roifilt2|roipoly|rsetwrite|std2|stdfilt|strel|stretchlim|subimage|tformarray|tformfwd|tforminv|tonemap|translate|truesize|uintlut|viscircles|"+
+ "warp|watershed|whitepoint|wiener2|xyz2double|xyz2uint16|ycbcr2rgb|bintprog|color|fgoalattain|fminbnd|fmincon|fminimax|fminsearch|fminunc|fseminf|fsolve|fzero|fzmult|gangstr|ktrlink|"+
+ "linprog|lsqcurvefit|lsqlin|lsqnonlin|lsqnonneg|optimget|optimset|optimtool|quadprog"
+ );
+ var storageType = (
+ "cell|struct|char|double|single|logical|u?int(?:8|16|32|64)|sparse"
+ );
+ var keywordMapper = this.createKeywordMapper({
+ "storage.type": storageType,
+ "support.function": builtinFunctions,
+ "keyword": keywords,
+ "constant.language": builtinConstants
+ }, "identifier", true);
+
+ this.$rules = {
+ start: [{
+ token : "string",
+ regex : "'",
+ stateName : "qstring",
+ next : [{
+ token : "constant.language.escape",
+ regex : "''"
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ regex: "",
+ next: "noQstring"
+ }],
+ noQstring : [{
+ regex: "^\\s*%{\\s*$",
+ token: "comment.start",
+ push: "blockComment"
+ }, {
+ token : "comment",
+ regex : "%[^\r\n]*"
+ }, {
+ token : "string",
+ regex : '"',
+ stateName : "qqstring",
+ next : [{
+ token : "constant.language.escape",
+ regex : /\\./
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\/|\\/\\/|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|=",
+ next: "start"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\.",
+ next: "start"
+ }, {
+ token : "paren.lparen",
+ regex : "[({\\[]",
+ next: "start"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]})]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : "text",
+ regex : "$",
+ next : "start"
+ }],
+ blockComment: [{
+ regex: "^\\s*%{\\s*$",
+ token: "comment.start",
+ push: "blockComment"
+ }, {
+ regex: "^\\s*%}\\s*$",
+ token: "comment.end",
+ next: "pop"
+ }, {
+ defaultToken: "comment"
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(MatlabHighlightRules, TextHighlightRules);
+
+exports.MatlabHighlightRules = MatlabHighlightRules;
+});
+
+ace.define("ace/mode/matlab",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/matlab_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MatlabHighlightRules = require("./matlab_highlight_rules").MatlabHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = MatlabHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "%";
+ this.blockComment = {start: "%{", end: "%}"};
+
+ this.$id = "ace/mode/matlab";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-maze.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-maze.js
new file mode 100644
index 00000000..cdc8d221
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-maze.js
@@ -0,0 +1,284 @@
+ace.define("ace/mode/maze_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var MazeHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ token: "keyword.control",
+ regex: /##|``/,
+ comment: "Wall"
+ }, {
+ token: "entity.name.tag",
+ regex: /\.\./,
+ comment: "Path"
+ }, {
+ token: "keyword.control",
+ regex: /<>/,
+ comment: "Splitter"
+ }, {
+ token: "entity.name.tag",
+ regex: /\*[\*A-Za-z0-9]/,
+ comment: "Signal"
+ }, {
+ token: "constant.numeric",
+ regex: /[0-9]{2}/,
+ comment: "Pause"
+ }, {
+ token: "keyword.control",
+ regex: /\^\^/,
+ comment: "Start"
+ }, {
+ token: "keyword.control",
+ regex: /\(\)/,
+ comment: "Hole"
+ }, {
+ token: "support.function",
+ regex: />>/,
+ comment: "Out"
+ }, {
+ token: "support.function",
+ regex: />\//,
+ comment: "Ln Out"
+ }, {
+ token: "support.function",
+ regex: /<</,
+ comment: "In"
+ }, {
+ token: "keyword.control",
+ regex: /--/,
+ comment: "One use"
+ }, {
+ token: "constant.language",
+ regex: /%[LRUDNlrudn]/,
+ comment: "Direction"
+ }, {
+ token: [
+ "entity.name.function",
+ "keyword.other",
+ "keyword.operator",
+ "keyword.other",
+ "keyword.operator",
+ "constant.numeric",
+ "keyword.operator",
+ "keyword.other",
+ "keyword.operator",
+ "constant.numeric",
+ "string.quoted.double",
+ "string.quoted.single"
+ ],
+ regex: /([A-Za-z][A-Za-z0-9])( *-> *)(?:([-+*\/]=)( *)((?:-)?)([0-9]+)|(=)( *)(?:((?:-)?)([0-9]+)|("[^"]*")|('[^']*')))/,
+ comment: "Assignment function"
+ }, {
+ token: [
+ "entity.name.function",
+ "keyword.other",
+ "keyword.control",
+ "keyword.other",
+ "keyword.operator",
+ "keyword.other",
+ "keyword.operator",
+ "constant.numeric",
+ "entity.name.tag",
+ "keyword.other",
+ "keyword.control",
+ "keyword.other",
+ "constant.language",
+ "keyword.other",
+ "keyword.control",
+ "keyword.other",
+ "constant.language"
+ ],
+ regex: /([A-Za-z][A-Za-z0-9])( *-> *)(IF|if)( *)(?:([<>]=?|==)( *)((?:-)?)([0-9]+)|(\*[\*A-Za-z0-9]))( *)(THEN|then)( *)(%[LRUDNlrudn])(?:( *)(ELSE|else)( *)(%[LRUDNlrudn]))?/,
+ comment: "Equality Function"
+ }, {
+ token: "entity.name.function",
+ regex: /[A-Za-z][A-Za-z0-9]/,
+ comment: "Function cell"
+ }, {
+ token: "comment.line.double-slash",
+ regex: / *\/\/.*/,
+ comment: "Comment"
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+MazeHighlightRules.metaData = {
+ fileTypes: ["mz"],
+ name: "Maze",
+ scopeName: "source.maze"
+};
+
+
+oop.inherits(MazeHighlightRules, TextHighlightRules);
+
+exports.MazeHighlightRules = MazeHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/maze",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/maze_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MazeHighlightRules = require("./maze_highlight_rules").MazeHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = MazeHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.$id = "ace/mode/maze";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-mel.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-mel.js
new file mode 100644
index 00000000..20de249b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-mel.js
@@ -0,0 +1,256 @@
+ace.define("ace/mode/mel_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var MELHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { caseInsensitive: true,
+ token: 'storage.type.mel',
+ regex: '\\b(matrix|string|vector|float|int|void)\\b' },
+ { caseInsensitive: true,
+ token: 'support.function.mel',
+ regex: '\\b((s(h(ow(ManipCtx|S(hadingGroupAttrEditor|electionInTitle)|H(idden|elp)|Window)|el(f(Button|TabLayout|Layout)|lField)|ading(GeometryRelCtx|Node|Connection|LightRelCtx))|y(s(tem|File)|mbol(Button|CheckBox))|nap(shot|Mode|2to2 |TogetherCtx|Key)|c(ulpt|ene(UIReplacement|Editor)|ale(BrushBrightness |Constraint|Key(Ctx)?)?|r(ipt(Node|Ctx|Table|edPanel(Type)?|Job|EditorInfo)|oll(Field|Layout))|mh)|t(itch(Surface(Points)?|AndExplodeShell )|a(ckTrace|rt(sWith |String ))|r(cmp|i(ng(ToStringArray |Array(Remove(Duplicates | )|C(ount |atenate )|ToString |Intersector))|p )|oke))|i(n(gleProfileBirailSurface)?|ze|gn|mplify)|o(u(nd(Control)?|rce)|ft(Mod(Ctx)?)?|rt)|u(perCtx|rface(S(haderList|ampler))?|b(st(itute(Geometry|AllString )?|ring)|d(M(irror|a(tchTopology|p(SewMove|Cut)))|iv(Crease|DisplaySmoothness)?|C(ollapse|leanTopology)|T(o(Blind|Poly)|ransferUVsToCache)|DuplicateAndConnect|EditUV|ListComponentConversion|AutoProjection)))|p(h(ere|rand)|otLight(PreviewPort)?|aceLocator|r(ing|eadSheetEditor))|e(t(s|MenuMode|Sta(te |rtupMessage|mpDensity )|NodeTypeFlag|ConstraintRestPosition |ToolTo|In(putDeviceMapping|finity)|D(ynamic|efaultShadingGroup|rivenKeyframe)|UITemplate|P(ar(ticleAttr|ent)|roject )|E(scapeCtx|dit(or|Ctx))|Key(Ctx|frame|Path)|F(ocus|luidAttr)|Attr(Mapping)?)|parator|ed|l(ect(Mode|ionConnection|Context|Type|edNodes|Pr(iority|ef)|Key(Ctx)?)?|LoadSettings)|archPathArray )|kin(Cluster|Percent)|q(uareSurface|rt)|w(itchTable|atchDisplayPort)|a(ve(Menu|Shelf|ToolSettings|I(nitialState|mage)|Pref(s|Objects)|Fluid|A(ttrPreset |llShelves))|mpleImage)|rtContext|mooth(step|Curve|TangentSurface))|h(sv_to_rgb|yp(ot|er(Graph|Shade|Panel))|i(tTest|de|lite)|ot(Box|key(Check)?)|ud(Button|Slider(Button)?)|e(lp(Line)?|adsUpDisplay|rmite)|wRe(nder(Load)?|flectionMap)|ard(enPointCurve|ware(RenderPanel)?))|n(o(nLinear|ise|de(Type|IconButton|Outliner|Preset)|rmal(ize |Constraint))|urbs(Boolean|S(elect|quare)|C(opyUVSet|ube)|To(Subdiv|Poly(gonsPref)?)|Plane|ViewDirectionVector )|ew(ton|PanelItems)|ame(space(Info)?|Command|Field))|c(h(oice|dir|eck(Box(Grp)?|DefaultRenderGlobals)|a(n(nelBox|geSubdiv(Region|ComponentDisplayLevel))|racter(Map|OutlineEditor)?))|y(cleCheck|linder)|tx(Completion|Traverse|EditMode|Abort)|irc(ularFillet|le)|o(s|n(str(uctionHistory|ain(Value)?)|nect(ionInfo|Control|Dynamic|Joint|Attr)|t(extInfo|rol)|dition|e|vert(SolidTx|Tessellation|Unit|FromOldLayers |Lightmap)|firmDialog)|py(SkinWeights|Key|Flexor|Array )|l(or(Slider(Grp|ButtonGrp)|Index(SliderGrp)?|Editor|AtPoint)?|umnLayout|lision)|arsenSubdivSelectionList|m(p(onentEditor|utePolysetVolume |actHairSystem )|mand(Port|Echo|Line)))|u(tKey|r(ve(MoveEPCtx|SketchCtx|CVCtx|Intersect|OnSurface|E(ditorCtx|PCtx)|AddPtCtx)?|rent(Ctx|Time(Ctx)?|Unit)))|p(GetSolverAttr|Button|S(olver(Types)?|e(t(SolverAttr|Edit)|am))|C(o(nstraint|llision)|ache)|Tool|P(anel|roperty))|eil|l(ip(Schedule(rOutliner)?|TrimBefore |Editor(CurrentTimeCtx)?)?|ose(Surface|Curve)|uster|ear(Cache)?|amp)|a(n(CreateManip|vas)|tch(Quiet)?|pitalizeString |mera(View)?)|r(oss(Product )?|eate(RenderLayer|MotionField |SubdivRegion|N(ode|ewShelf )|D(isplayLayer|rawCtx)|Editor))|md(Shell|FileOutput))|M(R(ender(ShadowData|Callback|Data|Util|View|Line(Array)?)|ampAttribute)|G(eometryData|lobal)|M(odelMessage|essage|a(nipData|t(erial|rix)))|BoundingBox|S(yntax|ceneMessage|t(atus|ring(Array)?)|imple|pace|elect(ion(Mask|List)|Info)|watchRender(Register|Base))|H(ardwareRenderer|WShaderSwatchGenerator)|NodeMessage|C(o(nditionMessage|lor(Array)?|m(putation|mand(Result|Message)))|ursor|loth(Material|S(ystem|olverRegister)|Con(straint|trol)|Triangle|Particle|Edge|Force)|allbackIdArray)|T(ypeId|ime(r(Message)?|Array)?|oolsInfo|esselationParams|r(imBoundaryArray|ansformationMatrix))|I(ntArray|t(Geometry|Mesh(Polygon|Edge|Vertex|FaceVertex)|S(urfaceCV|electionList)|CurveCV|Instancer|eratorType|D(ependency(Graph|Nodes)|ag)|Keyframe)|k(System|HandleGroup)|mage)|3dView|Object(SetMessage|Handle|Array)?|D(G(M(odifier|essage)|Context)|ynSwept(Triangle|Line)|istance|oubleArray|evice(State|Channel)|a(ta(Block|Handle)|g(M(odifier|essage)|Path(Array)?))|raw(Request(Queue)?|Info|Data|ProcedureBase))|U(serEventMessage|i(nt(Array|64Array)|Message))|P(o(int(Array)?|lyMessage)|lug(Array)?|rogressWindow|x(G(eometry(Iterator|Data)|lBuffer)|M(idiInputDevice|odelEditorCommand|anipContainer)|S(urfaceShape(UI)?|pringNode|electionContext)|HwShaderNode|Node|Co(ntext(Command)?|m(ponentShape|mand))|T(oolCommand|ransform(ationMatrix)?)|IkSolver(Node)?|3dModelView|ObjectSet|D(eformerNode|ata|ragAndDropBehavior)|PolyT(weakUVCommand|rg)|EmitterNode|F(i(eldNode|leTranslator)|luidEmitterNode)|LocatorNode))|E(ulerRotation|vent(Message)?)|ayatomr|Vector(Array)?|Quaternion|F(n(R(otateManip|eflectShader|adialField)|G(e(nericAttribute|ometry(Data|Filter))|ravityField)|M(otionPath|es(sageAttribute|h(Data)?)|a(nip3D|trix(Data|Attribute)))|B(l(innShader|endShapeDeformer)|ase)|S(caleManip|t(ateManip|ring(Data|ArrayData))|ingleIndexedComponent|ubd(Names|Data)?|p(hereData|otLight)|et|kinCluster)|HikEffector|N(on(ExtendedLight|AmbientLight)|u(rbs(Surface(Data)?|Curve(Data)?)|meric(Data|Attribute))|ewtonField)|C(haracter|ircleSweepManip|ompo(nent(ListData)?|undAttribute)|urveSegmentManip|lip|amera)|T(ypedAttribute|oggleManip|urbulenceField|r(ipleIndexedComponent|ansform))|I(ntArrayData|k(Solver|Handle|Joint|Effector))|D(ynSweptGeometryData|i(s(cManip|tanceManip)|rection(Manip|alLight))|ouble(IndexedComponent|ArrayData)|ependencyNode|a(ta|gNode)|ragField)|U(ni(tAttribute|formField)|Int64ArrayData)|P(hong(Shader|EShader)|oint(On(SurfaceManip|CurveManip)|Light|ArrayData)|fxGeometry|lugin(Data)?|arti(cleSystem|tion))|E(numAttribute|xpression)|V(o(lume(Light|AxisField)|rtexField)|ectorArrayData)|KeyframeDelta(Move|B(lockAddRemove|reakdown)|Scale|Tangent|InfType|Weighted|AddRemove)?|F(ield|luid|reePointTriadManip)|W(ireDeformer|eightGeometryFilter)|L(ight(DataAttribute)?|a(yeredShader|ttice(D(eformer|ata))?|mbertShader))|A(ni(sotropyShader|mCurve)|ttribute|irField|r(eaLight|rayAttrsData)|mbientLight))?|ile(IO|Object)|eedbackLine|loat(Matrix|Point(Array)?|Vector(Array)?|Array))|L(i(ghtLinks|brary)|ockMessage)|A(n(im(Message|C(ontrol|urveC(hange|lipboard(Item(Array)?)?))|Util)|gle)|ttribute(Spec(Array)?|Index)|r(rayData(Builder|Handle)|g(Database|Parser|List))))|t(hreePointArcCtx|ime(Control|Port|rX)|o(ol(Button|HasOptions|Collection|Dropped|PropertyWindow)|NativePath |upper|kenize(List )?|l(ower|erance)|rus|ggle(WindowVisibility|Axis)?)|u(rbulence|mble(Ctx)?)|ex(RotateContext|M(oveContext|anipContext)|t(ScrollList|Curves|ure(HairColor |DisplacePlane |PlacementContext|Window)|ToShelf |Field(Grp|ButtonGrp)?)?|S(caleContext|electContext|mudgeUVContext)|WinToolCtx)|woPointArcCtx|a(n(gentConstraint)?|bLayout)|r(im|unc(ate(HairCache|FluidCache))?|a(ns(formLimits|lator)|c(e|k(Ctx)?))))|i(s(olateSelect|Connected|True|Dirty|ParentOf |Valid(String |ObjectName |UiName )|AnimCurve )|n(s(tance(r)?|ert(Joint(Ctx)?|K(not(Surface|Curve)|eyCtx)))|heritTransform|t(S(crollBar|lider(Grp)?)|er(sect|nalVar|ToUI )|Field(Grp)?))|conText(Radio(Button|Collection)|Button|StaticLabel|CheckBox)|temFilter(Render|Type|Attr)?|prEngine|k(S(ystem(Info)?|olver|plineHandleCtx)|Handle(Ctx|DisplayScale)?|fkDisplayMethod)|m(portComposerCurves |fPlugins|age))|o(ceanNurbsPreviewPlane |utliner(Panel|Editor)|p(tion(Menu(Grp)?|Var)|en(GLExtension|MayaPref))|verrideModifier|ffset(Surface|Curve(OnSurface)?)|r(ientConstraint|bit(Ctx)?)|b(soleteProc |j(ect(Center|Type(UI)?|Layer )|Exists)))|d(yn(RelEd(itor|Panel)|Globals|C(ontrol|ache)|P(a(intEditor|rticleCtx)|ref)|Exp(ort|ression)|amicLoad)|i(s(connect(Joint|Attr)|tanceDim(Context|ension)|pla(y(RGBColor|S(tats|urface|moothness)|C(olor|ull)|Pref|LevelOfDetail|Affected)|cementToPoly)|kCache|able)|r(name |ect(ionalLight|KeyCtx)|map)|mWhen)|o(cServer|Blur|t(Product )?|ubleProfileBirailSurface|peSheetEditor|lly(Ctx)?)|uplicate(Surface|Curve)?|e(tach(Surface|Curve|DeviceAttr)|vice(Panel|Editor)|f(ine(DataServer|VirtualDevice)|ormer|ault(Navigation|LightListCheckBox))|l(ete(Sh(elfTab |adingGroupsAndMaterials )|U(nusedBrushes |I)|Attr)?|randstr)|g_to_rad)|agPose|r(opoffLocator|ag(gerContext)?)|g(timer|dirty|Info|eval))|CBG |u(serCtx|n(t(angleUV|rim)|i(t|form)|do(Info)?|loadPlugin|assignInputDevice|group)|iTemplate|p(dateAE |Axis)|v(Snapshot|Link))|joint(C(tx|luster)|DisplayScale|Lattice)?|p(sd(ChannelOutliner|TextureFile|E(ditTextureFile|xport))|close|i(c(ture|kWalk)|xelMove)|o(se|int(MatrixMult |C(onstraint|urveConstraint)|On(Surface|Curve)|Position|Light)|p(upMenu|en)|w|l(y(Reduce|GeoSampler|M(irrorFace|ove(UV|Edge|Vertex|Facet(UV)?)|erge(UV|Edge(Ctx)?|Vertex|Facet(Ctx)?)|ap(Sew(Move)?|Cut|Del))|B(oolOp|evel|l(indData|endColor))|S(traightenUVBorder|oftEdge|u(perCtx|bdivide(Edge|Facet))|p(her(icalProjection|e)|lit(Ring|Ctx|Edge|Vertex)?)|e(tToFaceNormal|parate|wEdge|lect(Constraint(Monitor)?|EditCtx))|mooth)|Normal(izeUV|PerVertex)?|C(hipOff|ylind(er|ricalProjection)|o(ne|pyUV|l(or(BlindData|Set|PerVertex)|lapse(Edge|Facet)))|u(t(Ctx)?|be)|l(ipboard|oseBorder)|acheMonitor|rea(seEdge|teFacet(Ctx)?))|T(o(Subdiv|rus)|r(iangulate|ansfer))|In(stallAction|fo)|Options|D(uplicate(Edge|AndConnect)|el(Edge|Vertex|Facet))|U(nite|VSet)|P(yramid|oke|lan(e|arProjection)|r(ism|ojection))|E(ditUV|valuate|xtrude(Edge|Facet))|Qu(eryBlindData|ad)|F(orceUV|lip(UV|Edge))|WedgeFace|L(istComponentConversion|ayoutUV)|A(utoProjection|ppend(Vertex|FacetCtx)?|verage(Normal|Vertex)))|eVectorConstraint))|utenv|er(cent|formanceOptions)|fxstrokes|wd|l(uginInfo|a(y(b(last|ackOptions))?|n(e|arSrf)))|a(steKey|ne(l(History|Configuration)?|Layout)|thAnimation|irBlend|use|lettePort|r(ti(cle(RenderInfo|Instancer|Exists)?|tion)|ent(Constraint)?|am(Dim(Context|ension)|Locator)))|r(int|o(j(ect(ion(Manip|Context)|Curve|Tangent)|FileViewer)|pMo(dCtx|ve)|gress(Bar|Window)|mptDialog)|eloadRefEd))|e(n(codeString|d(sWith |String )|v|ableDevice)|dit(RenderLayer(Globals|Members)|or(Template)?|DisplayLayer(Globals|Members)|AttrLimits )|v(ent|al(Deferred|Echo)?)|quivalent(Tol | )|ffector|r(f|ror)|x(clusiveLightCheckBox|t(end(Surface|Curve)|rude)|ists|p(ortComposerCurves |ression(EditorListen)?)?|ec(uteForEachObject )?|actWorldBoundingBox)|mit(ter)?)|v(i(sor|ew(Set|HeadOn|2dToolCtx|C(lipPlane|amera)|Place|Fit|LookAt))|o(lumeAxis|rtex)|e(ctorize|rifyCmd )|alidateShelfName )|key(Tangent|frame(Region(MoveKeyCtx|S(caleKeyCtx|e(tKeyCtx|lectKeyCtx))|CurrentTimeCtx|TrackCtx|InsertKeyCtx|D(irectKeyCtx|ollyCtx))|Stats|Outliner)?)|qu(it|erySubdiv)|f(c(heck|lose)|i(nd(RelatedSkinCluster |MenuItem |er|Keyframe|AllIntersections )|tBspline|l(ter(StudioImport|Curve|Expand)?|e(BrowserDialog|test|Info|Dialog|Extension )?|letCurve)|rstParentOf )|o(ntDialog|pen|rmLayout)|print|eof|flush|write|l(o(or|w|at(S(crollBar|lider(Grp|ButtonGrp|2)?)|Eq |Field(Grp)?))|u(shUndo|id(CacheInfo|Emitter|VoxelInfo))|exor)|r(omNativePath |e(eFormFillet|wind|ad)|ameLayout)|get(word|line)|mod)|w(hatIs|i(ndow(Pref)?|re(Context)?)|orkspace|ebBrowser(Prefs)?|a(itCursor|rning)|ri(nkle(Context)?|teTake))|l(s(T(hroughFilter|ype )|UI)?|i(st(Relatives|MenuAnnotation |Sets|History|NodeTypes|C(onnections|ameras)|Transforms |InputDevice(s|Buttons|Axes)|erEditor|DeviceAttachments|Unselected |A(nimatable|ttr))|n(step|eIntersection )|ght(link|List(Panel|Editor)?))|o(ckNode|okThru|ft|ad(NewShelf |P(lugin|refObjects)|Fluid)|g)|a(ssoContext|y(out|er(Button|ed(ShaderPort|TexturePort)))|ttice(DeformKeyCtx)?|unch(ImageEditor)?))|a(ssign(Command|InputDevice)|n(notate|im(C(one|urveEditor)|Display|View)|gle(Between)?)|tt(ach(Surface|Curve|DeviceAttr)|r(ibute(Menu|Info|Exists|Query)|NavigationControlGrp|Co(ntrolGrp|lorSliderGrp|mpatibility)|PresetEditWin|EnumOptionMenu(Grp)?|Field(Grp|SliderGrp)))|i(r|mConstraint)|d(d(NewShelfTab|Dynamic|PP|Attr(ibuteEditorNodeHelp)?)|vanceToNextDrivenKey)|uto(Place|Keyframe)|pp(endStringArray|l(y(Take|AttrPreset)|icationName))|ffect(s|edNet)|l(i(as(Attr)?|gn(Surface|C(tx|urve))?)|lViewFit)|r(c(len|Len(DimContext|gthDimension))|t(BuildPaintMenu|Se(tPaintCtx|lectCtx)|3dPaintCtx|UserPaintCtx|PuttyCtx|FluidAttrCtx|Attr(SkinPaintCtx|Ctx|PaintVertexCtx))|rayMapper)|mbientLight|b(s|out))|r(igid(Body|Solver)|o(t(at(ionInterpolation|e))?|otOf |undConstantRadius|w(ColumnLayout|Layout)|ll(Ctx)?)|un(up|TimeCommand)|e(s(olutionNode|et(Tool|AE )|ampleFluid)|hash|n(der(GlobalsNode|Manip|ThumbnailUpdate|Info|er|Partition|QualityNode|Window(SelectContext|Editor)|LayerButton)?|ame(SelectionList |UI|Attr)?)|cord(Device|Attr)|target|order(Deformers)?|do|v(olve|erse(Surface|Curve))|quires|f(ineSubdivSelectionList|erence(Edit|Query)?|resh(AE )?)|loadImage|adTake|root|move(MultiInstance|Joint)|build(Surface|Curve))|a(n(d(state|omizeFollicles )?|geControl)|d(i(o(MenuItemCollection|Button(Grp)?|Collection)|al)|_to_deg)|mpColorPort)|gb_to_hsv)|g(o(toBindPose |al)|e(t(M(odifiers|ayaPanelTypes )|Classification|InputDeviceRange|pid|env|DefaultBrush|Pa(nel|rticleAttr)|F(ileList|luidAttr)|A(ttr|pplicationVersionAsFloat ))|ometryConstraint)|l(Render(Editor)?|obalStitch)|a(uss|mma)|r(id(Layout)?|oup(ObjectsByName )?|a(dientControl(NoAttr)?|ph(SelectContext|TrackCtx|DollyCtx)|vity|bColor))|match)|x(pmPicker|form|bmLangPathList )|m(i(n(imizeApp)?|rrorJoint)|o(del(CurrentTimeCtx|Panel|Editor)|use|v(In|e(IKtoFK |VertexAlongDirection|KeyCtx)?|Out))|u(te|ltiProfileBirailSurface)|e(ssageLine|nu(BarLayout|Item(ToShelf )?|Editor)?|mory)|a(nip(Rotate(Context|LimitsCtx)|Move(Context|LimitsCtx)|Scale(Context|LimitsCtx)|Options)|tch|ke(Roll |SingleSurface|TubeOn |Identity|Paintable|bot|Live)|rker|g|x))|b(in(Membership|d(Skin|Pose))|o(neLattice|undary|x(ZoomCtx|DollyCtx))|u(tton(Manip)?|ild(BookmarkMenu|KeyframeMenu)|fferCurve)|e(ssel|vel(Plus)?)|l(indDataType|end(Shape(Panel|Editor)?|2|TwoAttr))|a(sename(Ex | )|tchRender|ke(Results|Simulation|Clip|PartialHistory|FluidShading )))))\\b' },
+ { caseInsensitive: true,
+ token: 'support.constant.mel',
+ regex: '\\b(s(h(ellTessellate|a(d(ing(Map|Engine)|erGlow)|pe))|n(ow|apshot(Shape)?)|c(ulpt|aleConstraint|ript)|t(yleCurve|itch(Srf|AsNurbsShell)|u(cco|dioClearCoat)|encil|roke(Globals)?)|i(ngleShadingSwitch|mpleVolumeShader)|o(ftMod(Manip|Handle)?|lidFractal)|u(rface(Sha(der|pe)|Info|EdManip|VarGroup|Luminance)|b(Surface|d(M(odifier(UV|World)?|ap(SewMove|Cut|pingManip))|B(lindData|ase)|iv(ReverseFaces|SurfaceVarGroup|Co(llapse|mponentId)|To(Nurbs|Poly))?|HierBlind|CleanTopology|Tweak(UV)?|P(lanarProj|rojManip)|LayoutUV|A(ddTopology|utoProj))|Curve))|p(BirailSrf|otLight|ring)|e(tRange|lectionListOperator)|k(inCluster|etchPlane)|quareSrf|ampler(Info)?|m(ooth(Curve|TangentSrf)|ear))|h(svToRgb|yper(GraphInfo|View|Layout)|ik(Solver|Handle|Effector)|oldMatrix|eightField|w(Re(nderGlobals|flectionMap)|Shader)|a(ir(System|Constraint|TubeShader)|rd(enPoint|wareRenderGlobals)))|n(o(n(ExtendedLightShapeNode|Linear|AmbientLightShapeNode)|ise|rmalConstraint)|urbs(Surface|Curve|T(oSubdiv(Proc)?|essellate)|DimShape)|e(twork|wtonField))|c(h(o(ice|oser)|ecker|aracter(Map|Offset)?)|o(n(straint|tr(olPoint|ast)|dition)|py(ColorSet|UVSet))|urve(Range|Shape|Normalizer(Linear|Angle)?|In(tersect|fo)|VarGroup|From(Mesh(CoM|Edge)?|Su(rface(Bnd|CoS|Iso)?|bdiv(Edge|Face)?)))|l(ip(Scheduler|Library)|o(se(stPointOnSurface|Surface|Curve)|th|ud)|uster(Handle)?|amp)|amera(View)?|r(eate(BPManip|ColorSet|UVSet)|ater))|t(ime(ToUnitConversion|Function)?|oo(nLineAttributes|lDrawManip)|urbulenceField|ex(BaseDeformManip|ture(BakeSet|2d|ToGeom|3d|Env)|SmudgeUVManip|LatticeDeformManip)|weak|angentConstraint|r(i(pleShadingSwitch|m(WithBoundaries)?)|ansform(Geometry)?))|i(n(s(tancer|ertKnot(Surface|Curve))|tersectSurface)|k(RPsolver|MCsolver|S(ystem|olver|Csolver|plineSolver)|Handle|PASolver|Effector)|m(plicit(Box|Sphere|Cone)|agePlane))|o(cean(Shader)?|pticalFX|ffset(Surface|C(os|urve))|ldBlindDataBase|rient(Constraint|ationMarker)|bject(RenderFilter|MultiFilter|BinFilter|S(criptFilter|et)|NameFilter|TypeFilter|Filter|AttrFilter))|d(yn(Globals|Base)|i(s(tance(Between|DimShape)|pla(yLayer(Manager)?|cementShader)|kCache)|rect(ionalLight|edDisc)|mensionShape)|o(ubleShadingSwitch|f)|pBirailSrf|e(tach(Surface|Curve)|pendNode|f(orm(Bend|S(ine|quash)|Twist|ableShape|F(unc|lare)|Wave)|ault(RenderUtilityList|ShaderList|TextureList|LightList))|lete(Co(lorSet|mponent)|UVSet))|ag(Node|Pose)|r(opoffLocator|agField))|u(seBackground|n(trim|i(t(Conversion|ToTimeConversion)|formField)|known(Transform|Dag)?)|vChooser)|j(iggle|oint(Cluster|Ffd|Lattice)?)|p(sdFileTex|hong(E)?|o(s(tProcessList|itionMarker)|int(MatrixMult|Constraint|On(SurfaceInfo|CurveInfo)|Emitter|Light)|l(y(Reduce|M(irror|o(difier(UV|World)?|ve(UV|Edge|Vertex|Face(tUV)?))|erge(UV|Edge|Vert|Face)|ap(Sew(Move)?|Cut|Del))|B(oolOp|evel|lindData|ase)|S(traightenUVBorder|oftEdge|ubd(Edge|Face)|p(h(ere|Proj)|lit(Ring|Edge|Vert)?)|e(parate|wEdge)|mooth(Proxy|Face)?)|Normal(izeUV|PerVertex)?|C(hipOff|yl(inder|Proj)|o(ne|pyUV|l(orPerVertex|lapse(Edge|F)))|u(t(Manip(Container)?)?|be)|loseBorder|rea(seEdge|t(or|eFace)))|T(o(Subdiv|rus)|weak(UV)?|r(iangulate|ansfer))|OptUvs|D(uplicateEdge|el(Edge|Vertex|Facet))|Unite|P(yramid|oke(Manip)?|lan(e|arProj)|r(i(sm|mitive)|oj))|Extrude(Edge|Vertex|Face)|VertexNormalManip|Quad|Flip(UV|Edge)|WedgeFace|LayoutUV|A(utoProj|ppend(Vertex)?|verageVertex))|eVectorConstraint))|fx(Geometry|Hair|Toon)|l(usMinusAverage|a(n(e|arTrimSurface)|ce(2dTexture|3dTexture)))|a(ssMatrix|irBlend|r(ti(cle(SamplerInfo|C(olorMapper|loud)|TranspMapper|IncandMapper|AgeMapper)?|tion)|ent(Constraint|Tessellate)|amDimension))|r(imitive|o(ject(ion|Curve|Tangent)|xyManager)))|e(n(tity|v(Ball|ironmentFog|S(phere|ky)|C(hrome|ube)|Fog))|x(t(end(Surface|Curve)|rude)|p(lodeNurbsShell|ression)))|v(iewManip|o(lume(Shader|Noise|Fog|Light|AxisField)|rtexField)|e(ctor(RenderGlobals|Product)|rtexBakeSet))|quadShadingSwitch|f(i(tBspline|eld|l(ter(Resample|Simplify|ClosestSample|Euler)?|e|letCurve))|o(urByFourMatrix|llicle)|urPointOn(MeshInfo|Subd)|f(BlendSrf(Obsolete)?|d|FilletSrf)|l(ow|uid(S(hape|liceManip)|Texture(2D|3D)|Emitter)|exorShape)|ra(ctal|meCache))|w(tAddMatrix|ire|ood|eightGeometryFilter|ater|rap)|l(ight(Info|Fog|Li(st|nker))?|o(cator|okAt|d(Group|Thresholds)|ft)|uminance|ea(stSquaresModifier|ther)|a(yered(Shader|Texture)|ttice|mbert))|a(n(notationShape|i(sotropic|m(Blend(InOut)?|C(urve(T(T|U|L|A)|U(T|U|L|A))?|lip)))|gleBetween)|tt(ach(Surface|Curve)|rHierarchyTest)|i(rField|mConstraint)|dd(Matrix|DoubleLinear)|udio|vg(SurfacePoints|NurbsSurfacePoints|Curves)|lign(Manip|Surface|Curve)|r(cLengthDimension|tAttrPaintTest|eaLight|rayMapper)|mbientLight|bstractBase(NurbsConversion|Create))|r(igid(Body|Solver|Constraint)|o(ck|undConstantRadius)|e(s(olution|ultCurve(TimeTo(Time|Unitless|Linear|Angular))?)|nder(Rect|Globals(List)?|Box|Sphere|Cone|Quality|L(ight|ayer(Manager)?))|cord|v(olve(dPrimitive)?|erse(Surface|Curve)?)|f(erence|lect)|map(Hsv|Color|Value)|build(Surface|Curve))|a(dialField|mp(Shader)?)|gbToHsv|bfSrf)|g(uide|eo(Connect(or|able)|metry(Shape|Constraint|VarGroup|Filter))|lobal(Stitch|CacheControl)|ammaCorrect|r(id|oup(Id|Parts)|a(nite|vityField)))|Fur(Globals|Description|Feedback|Attractors)|xformManip|m(o(tionPath|untain|vie)|u(te|lt(Matrix|i(plyDivide|listerLight)|DoubleLinear))|pBirailSrf|e(sh(VarGroup)?|ntalray(Texture|IblShape))|a(terialInfo|ke(Group|Nurb(sSquare|Sphere|C(ylinder|ircle|one|ube)|Torus|Plane)|CircularArc|T(hreePointCircularArc|extCurves|woPointCircularArc))|rble))|b(irailSrf|o(neLattice|olean|undary(Base)?)|u(lge|mp(2d|3d))|evel(Plus)?|l(in(n|dDataTemplate)|end(Shape|Color(s|Sets)|TwoAttr|Device|Weighted)?)|a(se(GeometryVarGroup|ShadingSwitch|Lattice)|keSet)|r(ownian|ush)))\\b' },
+ { caseInsensitive: true,
+ token: 'keyword.control.mel',
+ regex: '\\b(if|in|else|for|while|break|continue|case|default|do|switch|return|switch|case|source|catch|alias)\\b' },
+ { token: 'keyword.other.mel', regex: '\\b(global)\\b' },
+ { caseInsensitive: true,
+ token: 'constant.language.mel',
+ regex: '\\b(null|undefined)\\b' },
+ { token: 'constant.numeric.mel',
+ regex: '\\b((0(x|X)[0-9a-fA-F]*)|(([0-9]+\\.?[0-9]*)|(\\.[0-9]+))((e|E)(\\+|-)?[0-9]+)?)(L|l|UL|ul|u|U|F|f)?\\b' },
+ { token: 'punctuation.definition.string.begin.mel',
+ regex: '"',
+ push:
+ [ { token: 'constant.character.escape.mel', regex: '\\\\.' },
+ { token: 'punctuation.definition.string.end.mel',
+ regex: '"',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.double.mel' } ] },
+
+ { token: [ 'variable.other.mel', 'punctuation.definition.variable.mel' ],
+ regex: '(\\$)([a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*?\\b)' },
+
+ { token: 'punctuation.definition.string.begin.mel',
+ regex: '\'',
+ push:
+ [ { token: 'constant.character.escape.mel', regex: '\\\\.' },
+ { token: 'punctuation.definition.string.end.mel',
+ regex: '\'',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.single.mel' } ] },
+
+ { token: 'constant.language.mel',
+ regex: '\\b(false|true|yes|no|on|off)\\b' },
+
+ { token: 'punctuation.definition.comment.mel',
+ regex: '/\\*',
+ push:
+ [ { token: 'punctuation.definition.comment.mel',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.mel' } ] },
+
+ { token: [ 'comment.line.double-slash.mel', 'punctuation.definition.comment.mel' ],
+ regex: '(//)(.*$\\n?)' },
+
+ { caseInsensitive: true,
+ token: 'keyword.operator.mel',
+ regex: '\\b(instanceof)\\b' },
+ { token: 'keyword.operator.symbolic.mel',
+ regex: '[-\\!\\%\\&\\*\\+\\=\\/\\?\\:]' },
+
+ { token: [ 'meta.preprocessor.mel', 'punctuation.definition.preprocessor.mel' ],
+ regex: '(^[ \\t]*)((?:#)[a-zA-Z]+)' },
+
+ { token: [ 'meta.function.mel', 'keyword.other.mel', 'storage.type.mel', 'entity.name.function.mel', 'punctuation.section.function.mel' ],
+ regex: '(global\\s*)?(proc\\s*)(\\w+\\s*\\[?\\]?\\s+|\\s+)([A-Za-z_][A-Za-z0-9_\\.]*)(\\s*\\()',
+ push:
+ [ { include: '$self' },
+ { token: 'punctuation.section.function.mel',
+ regex: '\\)',
+ next: 'pop' },
+ { defaultToken: 'meta.function.mel' } ] }
+
+ ] }
+
+ this.normalizeRules();
+};
+
+oop.inherits(MELHighlightRules, TextHighlightRules);
+
+exports.MELHighlightRules = MELHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/mel",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/mel_highlight_rules","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MELHighlightRules = require("./mel_highlight_rules").MELHighlightRules;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = MELHighlightRules;
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/mel";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-mushcode.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-mushcode.js
new file mode 100644
index 00000000..5e6b7eaf
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-mushcode.js
@@ -0,0 +1,674 @@
+ace.define("ace/mode/mushcode_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var MushCodeRules = function() {
+
+
+ var keywords = (
+ "@if|"+
+ "@ifelse|"+
+ "@switch|"+
+ "@halt|"+
+ "@dolist|"+
+ "@create|"+
+ "@scent|"+
+ "@sound|"+
+ "@touch|"+
+ "@ataste|"+
+ "@osound|"+
+ "@ahear|"+
+ "@aahear|"+
+ "@amhear|"+
+ "@otouch|"+
+ "@otaste|"+
+ "@drop|"+
+ "@odrop|"+
+ "@adrop|"+
+ "@dropfail|"+
+ "@odropfail|"+
+ "@smell|"+
+ "@oemit|"+
+ "@emit|"+
+ "@pemit|"+
+ "@parent|"+
+ "@clone|"+
+ "@taste|"+
+ "whisper|"+
+ "page|"+
+ "say|"+
+ "pose|"+
+ "semipose|"+
+ "teach|"+
+ "touch|"+
+ "taste|"+
+ "smell|"+
+ "listen|"+
+ "look|"+
+ "move|"+
+ "go|"+
+ "home|"+
+ "follow|"+
+ "unfollow|"+
+ "desert|"+
+ "dismiss|"+
+ "@tel"
+ );
+
+ var builtinConstants = (
+ "=#0"
+ );
+
+ var builtinFunctions = (
+ "default|"+
+ "edefault|"+
+ "eval|"+
+ "get_eval|"+
+ "get|"+
+ "grep|"+
+ "grepi|"+
+ "hasattr|"+
+ "hasattrp|"+
+ "hasattrval|"+
+ "hasattrpval|"+
+ "lattr|"+
+ "nattr|"+
+ "poss|"+
+ "udefault|"+
+ "ufun|"+
+ "u|"+
+ "v|"+
+ "uldefault|"+
+ "xget|"+
+ "zfun|"+
+ "band|"+
+ "bnand|"+
+ "bnot|"+
+ "bor|"+
+ "bxor|"+
+ "shl|"+
+ "shr|"+
+ "and|"+
+ "cand|"+
+ "cor|"+
+ "eq|"+
+ "gt|"+
+ "gte|"+
+ "lt|"+
+ "lte|"+
+ "nand|"+
+ "neq|"+
+ "nor|"+
+ "not|"+
+ "or|"+
+ "t|"+
+ "xor|"+
+ "con|"+
+ "entrances|"+
+ "exit|"+
+ "followers|"+
+ "home|"+
+ "lcon|"+
+ "lexits|"+
+ "loc|"+
+ "locate|"+
+ "lparent|"+
+ "lsearch|"+
+ "next|"+
+ "num|"+
+ "owner|"+
+ "parent|"+
+ "pmatch|"+
+ "rloc|"+
+ "rnum|"+
+ "room|"+
+ "where|"+
+ "zone|"+
+ "worn|"+
+ "held|"+
+ "carried|"+
+ "acos|"+
+ "asin|"+
+ "atan|"+
+ "ceil|"+
+ "cos|"+
+ "e|"+
+ "exp|"+
+ "fdiv|"+
+ "fmod|"+
+ "floor|"+
+ "log|"+
+ "ln|"+
+ "pi|"+
+ "power|"+
+ "round|"+
+ "sin|"+
+ "sqrt|"+
+ "tan|"+
+ "aposs|"+
+ "andflags|"+
+ "conn|"+
+ "commandssent|"+
+ "controls|"+
+ "doing|"+
+ "elock|"+
+ "findable|"+
+ "flags|"+
+ "fullname|"+
+ "hasflag|"+
+ "haspower|"+
+ "hastype|"+
+ "hidden|"+
+ "idle|"+
+ "isbaker|"+
+ "lock|"+
+ "lstats|"+
+ "money|"+
+ "who|"+
+ "name|"+
+ "nearby|"+
+ "obj|"+
+ "objflags|"+
+ "photo|"+
+ "poll|"+
+ "powers|"+
+ "pendingtext|"+
+ "receivedtext|"+
+ "restarts|"+
+ "restarttime|"+
+ "subj|"+
+ "shortestpath|"+
+ "tmoney|"+
+ "type|"+
+ "visible|"+
+ "cat|"+
+ "element|"+
+ "elements|"+
+ "extract|"+
+ "filter|"+
+ "filterbool|"+
+ "first|"+
+ "foreach|"+
+ "fold|"+
+ "grab|"+
+ "graball|"+
+ "index|"+
+ "insert|"+
+ "itemize|"+
+ "items|"+
+ "iter|"+
+ "last|"+
+ "ldelete|"+
+ "map|"+
+ "match|"+
+ "matchall|"+
+ "member|"+
+ "mix|"+
+ "munge|"+
+ "pick|"+
+ "remove|"+
+ "replace|"+
+ "rest|"+
+ "revwords|"+
+ "setdiff|"+
+ "setinter|"+
+ "setunion|"+
+ "shuffle|"+
+ "sort|"+
+ "sortby|"+
+ "splice|"+
+ "step|"+
+ "wordpos|"+
+ "words|"+
+ "add|"+
+ "lmath|"+
+ "max|"+
+ "mean|"+
+ "median|"+
+ "min|"+
+ "mul|"+
+ "percent|"+
+ "sign|"+
+ "stddev|"+
+ "sub|"+
+ "val|"+
+ "bound|"+
+ "abs|"+
+ "inc|"+
+ "dec|"+
+ "dist2d|"+
+ "dist3d|"+
+ "div|"+
+ "floordiv|"+
+ "mod|"+
+ "modulo|"+
+ "remainder|"+
+ "vadd|"+
+ "vdim|"+
+ "vdot|"+
+ "vmag|"+
+ "vmax|"+
+ "vmin|"+
+ "vmul|"+
+ "vsub|"+
+ "vunit|"+
+ "regedit|"+
+ "regeditall|"+
+ "regeditalli|"+
+ "regediti|"+
+ "regmatch|"+
+ "regmatchi|"+
+ "regrab|"+
+ "regraball|"+
+ "regraballi|"+
+ "regrabi|"+
+ "regrep|"+
+ "regrepi|"+
+ "after|"+
+ "alphamin|"+
+ "alphamax|"+
+ "art|"+
+ "before|"+
+ "brackets|"+
+ "capstr|"+
+ "case|"+
+ "caseall|"+
+ "center|"+
+ "containsfansi|"+
+ "comp|"+
+ "decompose|"+
+ "decrypt|"+
+ "delete|"+
+ "edit|"+
+ "encrypt|"+
+ "escape|"+
+ "if|"+
+ "ifelse|"+
+ "lcstr|"+
+ "left|"+
+ "lit|"+
+ "ljust|"+
+ "merge|"+
+ "mid|"+
+ "ostrlen|"+
+ "pos|"+
+ "repeat|"+
+ "reverse|"+
+ "right|"+
+ "rjust|"+
+ "scramble|"+
+ "secure|"+
+ "space|"+
+ "spellnum|"+
+ "squish|"+
+ "strcat|"+
+ "strmatch|"+
+ "strinsert|"+
+ "stripansi|"+
+ "stripfansi|"+
+ "strlen|"+
+ "switch|"+
+ "switchall|"+
+ "table|"+
+ "tr|"+
+ "trim|"+
+ "ucstr|"+
+ "unsafe|"+
+ "wrap|"+
+ "ctitle|"+
+ "cwho|"+
+ "channels|"+
+ "clock|"+
+ "cflags|"+
+ "ilev|"+
+ "itext|"+
+ "inum|"+
+ "convsecs|"+
+ "convutcsecs|"+
+ "convtime|"+
+ "ctime|"+
+ "etimefmt|"+
+ "isdaylight|"+
+ "mtime|"+
+ "secs|"+
+ "msecs|"+
+ "starttime|"+
+ "time|"+
+ "timefmt|"+
+ "timestring|"+
+ "utctime|"+
+ "atrlock|"+
+ "clone|"+
+ "create|"+
+ "cook|"+
+ "dig|"+
+ "emit|"+
+ "lemit|"+
+ "link|"+
+ "oemit|"+
+ "open|"+
+ "pemit|"+
+ "remit|"+
+ "set|"+
+ "tel|"+
+ "wipe|"+
+ "zemit|"+
+ "fbcreate|"+
+ "fbdestroy|"+
+ "fbwrite|"+
+ "fbclear|"+
+ "fbcopy|"+
+ "fbcopyto|"+
+ "fbclip|"+
+ "fbdump|"+
+ "fbflush|"+
+ "fbhset|"+
+ "fblist|"+
+ "fbstats|"+
+ "qentries|"+
+ "qentry|"+
+ "play|"+
+ "ansi|"+
+ "break|"+
+ "c|"+
+ "asc|"+
+ "die|"+
+ "isdbref|"+
+ "isint|"+
+ "isnum|"+
+ "isletters|"+
+ "linecoords|"+
+ "localize|"+
+ "lnum|"+
+ "nameshort|"+
+ "null|"+
+ "objeval|"+
+ "r|"+
+ "rand|"+
+ "s|"+
+ "setq|"+
+ "setr|"+
+ "soundex|"+
+ "soundslike|"+
+ "valid|"+
+ "vchart|"+
+ "vchart2|"+
+ "vlabel|"+
+ "@@|"+
+ "bakerdays|"+
+ "bodybuild|"+
+ "box|"+
+ "capall|"+
+ "catalog|"+
+ "children|"+
+ "ctrailer|"+
+ "darttime|"+
+ "debt|"+
+ "detailbar|"+
+ "exploredroom|"+
+ "fansitoansi|"+
+ "fansitoxansi|"+
+ "fullbar|"+
+ "halfbar|"+
+ "isdarted|"+
+ "isnewbie|"+
+ "isword|"+
+ "lambda|"+
+ "lobjects|"+
+ "lplayers|"+
+ "lthings|"+
+ "lvexits|"+
+ "lvobjects|"+
+ "lvplayers|"+
+ "lvthings|"+
+ "newswrap|"+
+ "numsuffix|"+
+ "playerson|"+
+ "playersthisweek|"+
+ "randomad|"+
+ "randword|"+
+ "realrandword|"+
+ "replacechr|"+
+ "second|"+
+ "splitamount|"+
+ "strlenall|"+
+ "text|"+
+ "third|"+
+ "tofansi|"+
+ "totalac|"+
+ "unique|"+
+ "getaddressroom|"+
+ "listpropertycomm|"+
+ "listpropertyres|"+
+ "lotowner|"+
+ "lotrating|"+
+ "lotratingcount|"+
+ "lotvalue|"+
+ "boughtproduct|"+
+ "companyabb|"+
+ "companyicon|"+
+ "companylist|"+
+ "companyname|"+
+ "companyowners|"+
+ "companyvalue|"+
+ "employees|"+
+ "invested|"+
+ "productlist|"+
+ "productname|"+
+ "productowners|"+
+ "productrating|"+
+ "productratingcount|"+
+ "productsoldat|"+
+ "producttype|"+
+ "ratedproduct|"+
+ "soldproduct|"+
+ "topproducts|"+
+ "totalspentonproduct|"+
+ "totalstock|"+
+ "transfermoney|"+
+ "uniquebuyercount|"+
+ "uniqueproductsbought|"+
+ "validcompany|"+
+ "deletepicture|"+
+ "fbsave|"+
+ "getpicturesecurity|"+
+ "haspicture|"+
+ "listpictures|"+
+ "picturesize|"+
+ "replacecolor|"+
+ "rgbtocolor|"+
+ "savepicture|"+
+ "setpicturesecurity|"+
+ "showpicture|"+
+ "piechart|"+
+ "piechartlabel|"+
+ "createmaze|"+
+ "drawmaze|"+
+ "drawwireframe"
+ );
+ var keywordMapper = this.createKeywordMapper({
+ "invalid.deprecated": "debugger",
+ "support.function": builtinFunctions,
+ "constant.language": builtinConstants,
+ "keyword": keywords
+ }, "identifier");
+
+ var strPre = "(?:r|u|ur|R|U|UR|Ur|uR)?";
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var octInteger = "(?:0[oO]?[0-7]+)";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var binInteger = "(?:0[bB][01]+)";
+ var integer = "(?:" + decimalInteger + "|" + octInteger + "|" + hexInteger + "|" + binInteger + ")";
+
+ var exponent = "(?:[eE][+-]?\\d+)";
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + exponent + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "variable", // mush substitution register
+ regex : "%[0-9]{1}"
+ },
+ {
+ token : "variable", // mush substitution register
+ regex : "%q[0-9A-Za-z]{1}"
+ },
+ {
+ token : "variable", // mush special character register
+ regex : "%[a-zA-Z]{1}"
+ },
+ {
+ token: "variable.language",
+ regex: "%[a-z0-9-_]+"
+ },
+ {
+ token : "constant.numeric", // imaginary
+ regex : "(?:" + floatNumber + "|\\d+)[jJ]\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // long integer
+ regex : integer + "[lL]\\b"
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|#|%|<<|>>|\\||\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+ };
+};
+
+oop.inherits(MushCodeRules, TextHighlightRules);
+
+exports.MushCodeRules = MushCodeRules;
+});
+
+ace.define("ace/mode/folding/pythonic",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(markers) {
+ this.foldingStartMarker = new RegExp("([\\[{])(?:\\s*)$|(" + markers + ")(?:\\s*)(?:#.*)?$");
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, match.index);
+ if (match[2])
+ return this.indentationBlock(session, row, match.index + match[2].length);
+ return this.indentationBlock(session, row);
+ }
+ }
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/mushcode",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/mushcode_highlight_rules","ace/mode/folding/pythonic","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var MushCodeRules = require("./mushcode_highlight_rules").MushCodeRules;
+var PythonFoldMode = require("./folding/pythonic").FoldMode;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = MushCodeRules;
+ this.foldingRules = new PythonFoldMode("\\:");
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ var outdents = {
+ "pass": 1,
+ "return": 1,
+ "raise": 1,
+ "break": 1,
+ "continue": 1
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input !== "\r\n" && input !== "\r" && input !== "\n")
+ return false;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens)
+ return false;
+ do {
+ var last = tokens.pop();
+ } while (last && (last.type == "comment" || (last.type == "text" && last.value.match(/^\s+$/))));
+
+ if (!last)
+ return false;
+
+ return (last.type == "keyword" && outdents[last.value]);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+
+ row += 1;
+ var indent = this.$getIndent(doc.getLine(row));
+ var tab = doc.getTabString();
+ if (indent.slice(-tab.length) == tab)
+ doc.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ };
+
+ this.$id = "ace/mode/mushcode";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-mysql.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-mysql.js
new file mode 100644
index 00000000..7abe675c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-mysql.js
@@ -0,0 +1,160 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/mysql_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var MysqlHighlightRules = function() {
+
+ var mySqlKeywords = /*sql*/ "alter|and|as|asc|between|count|create|delete|desc|distinct|drop|from|having|in|insert|into|is|join|like|not|on|or|order|select|set|table|union|update|values|where" + "|accessible|action|add|after|algorithm|all|analyze|asensitive|at|authors|auto_increment|autocommit|avg|avg_row_length|before|binary|binlog|both|btree|cache|call|cascade|cascaded|case|catalog_name|chain|change|changed|character|check|checkpoint|checksum|class_origin|client_statistics|close|coalesce|code|collate|collation|collations|column|columns|comment|commit|committed|completion|concurrent|condition|connection|consistent|constraint|contains|continue|contributors|convert|cross|current_date|current_time|current_timestamp|current_user|cursor|data|database|databases|day_hour|day_microsecond|day_minute|day_second|deallocate|dec|declare|default|delay_key_write|delayed|delimiter|des_key_file|describe|deterministic|dev_pop|dev_samp|deviance|directory|disable|discard|distinctrow|div|dual|dumpfile|each|elseif|enable|enclosed|end|ends|engine|engines|enum|errors|escape|escaped|even|event|events|every|execute|exists|exit|explain|extended|fast|fetch|field|fields|first|flush|for|force|foreign|found_rows|full|fulltext|function|general|global|grant|grants|group|groupby_concat|handler|hash|help|high_priority|hosts|hour_microsecond|hour_minute|hour_second|if|ignore|ignore_server_ids|import|index|index_statistics|infile|inner|innodb|inout|insensitive|insert_method|install|interval|invoker|isolation|iterate|key|keys|kill|language|last|leading|leave|left|level|limit|linear|lines|list|load|local|localtime|localtimestamp|lock|logs|low_priority|master|master_heartbeat_period|master_ssl_verify_server_cert|masters|match|max|max_rows|maxvalue|message_text|middleint|migrate|min|min_rows|minute_microsecond|minute_second|mod|mode|modifies|modify|mutex|mysql_errno|natural|next|no|no_write_to_binlog|offline|offset|one|online|open|optimize|option|optionally|out|outer|outfile|pack_keys|parser|partition|partitions|password|phase|plugin|plugins|prepare|preserve|prev|primary|privileges|procedure|processlist|profile|profiles|purge|query|quick|range|read|read_write|reads|real|rebuild|recover|references|regexp|relaylog|release|remove|rename|reorganize|repair|repeatable|replace|require|resignal|restrict|resume|return|returns|revoke|right|rlike|rollback|rollup|row|row_format|rtree|savepoint|schedule|schema|schema_name|schemas|second_microsecond|security|sensitive|separator|serializable|server|session|share|show|signal|slave|slow|smallint|snapshot|soname|spatial|specific|sql|sql_big_result|sql_buffer_result|sql_cache|sql_calc_found_rows|sql_no_cache|sql_small_result|sqlexception|sqlstate|sqlwarning|ssl|start|starting|starts|status|std|stddev|stddev_pop|stddev_samp|storage|straight_join|subclass_origin|sum|suspend|table_name|table_statistics|tables|tablespace|temporary|terminated|to|trailing|transaction|trigger|triggers|truncate|uncommitted|undo|uninstall|unique|unlock|upgrade|usage|use|use_frm|user|user_resources|user_statistics|using|utc_date|utc_time|utc_timestamp|value|variables|varying|view|views|warnings|when|while|with|work|write|xa|xor|year_month|zerofill|begin|do|then|else|loop|repeat";
+ var builtins = "by|bool|boolean|bit|blob|decimal|double|enum|float|long|longblob|longtext|medium|mediumblob|mediumint|mediumtext|time|timestamp|tinyblob|tinyint|tinytext|text|bigint|int|int1|int2|int3|int4|int8|integer|float|float4|float8|double|char|varbinary|varchar|varcharacter|precision|date|datetime|year|unsigned|signed|numeric|ucase|lcase|mid|len|round|rank|now|format|coalesce|ifnull|isnull|nvl"
+ var variable = "charset|clear|connect|edit|ego|exit|go|help|nopager|notee|nowarning|pager|print|prompt|quit|rehash|source|status|system|tee"
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtins,
+ "keyword": mySqlKeywords,
+ "constant": "false|true|null|unknown|date|time|timestamp|ODBCdotTable|zerolessFloat",
+ "variable.language": variable
+ }, "identifier", true);
+
+
+ function string(rule) {
+ var start = rule.start;
+ var escapeSeq = rule.escape;
+ return {
+ token: "string.start",
+ regex: start,
+ next: [
+ {token: "constant.language.escape", regex: escapeSeq},
+ {token: "string.end", next: "start", regex: start},
+ {defaultToken: "string"}
+ ]
+ };
+ }
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment", regex : "(?:-- |#).*$"
+ },
+ string({start: '"', escape: /\\[0'"bnrtZ\\%_]?/}),
+ string({start: "'", escape: /\\[0'"bnrtZ\\%_]?/}),
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next : "comment"
+ }, {
+ token : "constant.numeric", // hex
+ regex : /0[xX][0-9a-fA-F]+|[xX]'[0-9a-fA-F]+'|0[bB][01]+|[bB]'[01]+'/
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "constant.class",
+ regex : "@@?[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "constant.buildin",
+ regex : "`[^`]*`"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ],
+ "comment" : [
+ {token : "comment", regex : "\\*\\/", next : "start"},
+ {defaultToken : "comment"}
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-", [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(MysqlHighlightRules, TextHighlightRules);
+
+exports.MysqlHighlightRules = MysqlHighlightRules;
+});
+
+ace.define("ace/mode/mysql",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/mysql_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var TextMode = require("../mode/text").Mode;
+var MysqlHighlightRules = require("./mysql_highlight_rules").MysqlHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = MysqlHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = ["--", "#"]; // todo space
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.$id = "ace/mode/mysql";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-nix.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-nix.js
new file mode 100644
index 00000000..3424beaf
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-nix.js
@@ -0,0 +1,631 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/c_cpp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var cFunctions = exports.cFunctions = "\\b(?:hypot(?:f|l)?|s(?:scanf|ystem|nprintf|ca(?:nf|lb(?:n(?:f|l)?|ln(?:f|l)?))|i(?:n(?:h(?:f|l)?|f|l)?|gn(?:al|bit))|tr(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?)|error|pbrk|ftime|len|rchr|xfrm)|printf|et(?:jmp|vbuf|locale|buf)|qrt(?:f|l)?|w(?:scanf|printf)|rand)|n(?:e(?:arbyint(?:f|l)?|xt(?:toward(?:f|l)?|after(?:f|l)?))|an(?:f|l)?)|c(?:s(?:in(?:h(?:f|l)?|f|l)?|qrt(?:f|l)?)|cos(?:h(?:f)?|f|l)?|imag(?:f|l)?|t(?:ime|an(?:h(?:f|l)?|f|l)?)|o(?:s(?:h(?:f|l)?|f|l)?|nj(?:f|l)?|pysign(?:f|l)?)|p(?:ow(?:f|l)?|roj(?:f|l)?)|e(?:il(?:f|l)?|xp(?:f|l)?)|l(?:o(?:ck|g(?:f|l)?)|earerr)|a(?:sin(?:h(?:f|l)?|f|l)?|cos(?:h(?:f|l)?|f|l)?|tan(?:h(?:f|l)?|f|l)?|lloc|rg(?:f|l)?|bs(?:f|l)?)|real(?:f|l)?|brt(?:f|l)?)|t(?:ime|o(?:upper|lower)|an(?:h(?:f|l)?|f|l)?|runc(?:f|l)?|gamma(?:f|l)?|mp(?:nam|file))|i(?:s(?:space|n(?:ormal|an)|cntrl|inf|digit|u(?:nordered|pper)|p(?:unct|rint)|finite|w(?:space|c(?:ntrl|type)|digit|upper|p(?:unct|rint)|lower|al(?:num|pha)|graph|xdigit|blank)|l(?:ower|ess(?:equal|greater)?)|al(?:num|pha)|gr(?:eater(?:equal)?|aph)|xdigit|blank)|logb(?:f|l)?|max(?:div|abs))|di(?:v|fftime)|_Exit|unget(?:c|wc)|p(?:ow(?:f|l)?|ut(?:s|c(?:har)?|wc(?:har)?)|error|rintf)|e(?:rf(?:c(?:f|l)?|f|l)?|x(?:it|p(?:2(?:f|l)?|f|l|m1(?:f|l)?)?))|v(?:s(?:scanf|nprintf|canf|printf|w(?:scanf|printf))|printf|f(?:scanf|printf|w(?:scanf|printf))|w(?:scanf|printf)|a_(?:start|copy|end|arg))|qsort|f(?:s(?:canf|e(?:tpos|ek))|close|tell|open|dim(?:f|l)?|p(?:classify|ut(?:s|c|w(?:s|c))|rintf)|e(?:holdexcept|set(?:e(?:nv|xceptflag)|round)|clearexcept|testexcept|of|updateenv|r(?:aiseexcept|ror)|get(?:e(?:nv|xceptflag)|round))|flush|w(?:scanf|ide|printf|rite)|loor(?:f|l)?|abs(?:f|l)?|get(?:s|c|pos|w(?:s|c))|re(?:open|e|ad|xp(?:f|l)?)|m(?:in(?:f|l)?|od(?:f|l)?|a(?:f|l|x(?:f|l)?)?))|l(?:d(?:iv|exp(?:f|l)?)|o(?:ngjmp|cal(?:time|econv)|g(?:1(?:p(?:f|l)?|0(?:f|l)?)|2(?:f|l)?|f|l|b(?:f|l)?)?)|abs|l(?:div|abs|r(?:int(?:f|l)?|ound(?:f|l)?))|r(?:int(?:f|l)?|ound(?:f|l)?)|gamma(?:f|l)?)|w(?:scanf|c(?:s(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?|mbs)|pbrk|ftime|len|r(?:chr|tombs)|xfrm)|to(?:b|mb)|rtomb)|printf|mem(?:set|c(?:hr|py|mp)|move))|a(?:s(?:sert|ctime|in(?:h(?:f|l)?|f|l)?)|cos(?:h(?:f|l)?|f|l)?|t(?:o(?:i|f|l(?:l)?)|exit|an(?:h(?:f|l)?|2(?:f|l)?|f|l)?)|b(?:s|ort))|g(?:et(?:s|c(?:har)?|env|wc(?:har)?)|mtime)|r(?:int(?:f|l)?|ound(?:f|l)?|e(?:name|alloc|wind|m(?:ove|quo(?:f|l)?|ainder(?:f|l)?))|a(?:nd|ise))|b(?:search|towc)|m(?:odf(?:f|l)?|em(?:set|c(?:hr|py|mp)|move)|ktime|alloc|b(?:s(?:init|towcs|rtowcs)|towc|len|r(?:towc|len))))\\b"
+
+var c_cppHighlightRules = function() {
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|goto|if|_Pragma|" +
+ "return|switch|while|catch|operator|try|throw|using"
+ );
+
+ var storageType = (
+ "asm|__asm__|auto|bool|_Bool|char|_Complex|double|enum|float|" +
+ "_Imaginary|int|long|short|signed|struct|typedef|union|unsigned|void|" +
+ "class|wchar_t|template|char16_t|char32_t"
+ );
+
+ var storageModifiers = (
+ "const|extern|register|restrict|static|volatile|inline|private|" +
+ "protected|public|friend|explicit|virtual|export|mutable|typename|" +
+ "constexpr|new|delete|alignas|alignof|decltype|noexcept|thread_local"
+ );
+
+ var keywordOperators = (
+ "and|and_eq|bitand|bitor|compl|not|not_eq|or|or_eq|typeid|xor|xor_eq" +
+ "const_cast|dynamic_cast|reinterpret_cast|static_cast|sizeof|namespace"
+ );
+
+ var builtinConstants = (
+ "NULL|true|false|TRUE|FALSE|nullptr"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.control" : keywordControls,
+ "storage.type" : storageType,
+ "storage.modifier" : storageModifiers,
+ "keyword.operator" : keywordOperators,
+ "variable.language": "this",
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+ var escapeRe = /\\(?:['"?\\abfnrtv]|[0-7]{1,3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}U[a-fA-F\d]{8}|.)/.source;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "//$",
+ next : "start"
+ }, {
+ token : "comment",
+ regex : "//",
+ next : "singleLineComment"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : "'(?:" + escapeRe + "|.)?'"
+ }, {
+ token : "string.start",
+ regex : '"',
+ stateName: "qqstring",
+ next: [
+ { token: "string", regex: /\\\s*$/, next: "qqstring" },
+ { token: "constant.language.escape", regex: escapeRe },
+ { token: "constant.language.escape", regex: /%[^'"\\]/ },
+ { token: "string.end", regex: '"|$', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "string.start",
+ regex : 'R"\\(',
+ stateName: "rawString",
+ next: [
+ { token: "string.end", regex: '\\)"', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|pragma|line|define|undef)\\b",
+ next : "directive"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|if|ifdef|else|elif|ifndef)\\b"
+ }, {
+ token : "support.function.C99.c",
+ regex : cFunctions
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|<<=|>>=|>>>=|<>|&&|\|\||\?:|[*%\/+\-&\^|~!<>=]=?/
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "singleLineComment" : [
+ {
+ token : "comment",
+ regex : /\\$/,
+ next : "singleLineComment"
+ }, {
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ],
+ "directive" : [
+ {
+ token : "constant.other.multiline",
+ regex : /\\/
+ },
+ {
+ token : "constant.other.multiline",
+ regex : /.*\\/
+ },
+ {
+ token : "constant.other",
+ regex : "\\s*<.+?>",
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : '\\s*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]',
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
+ next : "start"
+ },
+ {
+ token : "constant.other",
+ regex : /[^\\\/]+/,
+ next : "start"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(c_cppHighlightRules, TextHighlightRules);
+
+exports.c_cppHighlightRules = c_cppHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/c_cpp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c_cpp_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var c_cppHighlightRules = require("./c_cpp_highlight_rules").c_cppHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = c_cppHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/c_cpp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/nix_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ var NixHighlightRules = function() {
+
+ var constantLanguage = "true|false";
+ var keywordControl = "with|import|if|else|then|inherit";
+ var keywordDeclaration = "let|in|rec";
+
+ var keywordMapper = this.createKeywordMapper({
+ "constant.language.nix": constantLanguage,
+ "keyword.control.nix": keywordControl,
+ "keyword.declaration.nix": keywordDeclaration
+ }, "identifier");
+
+ this.$rules = {
+ "start": [{
+ token: "comment",
+ regex: /#.*$/
+ }, {
+ token: "comment",
+ regex: /\/\*/,
+ next: "comment"
+ }, {
+ token: "constant",
+ regex: "<[^>]+>"
+ }, {
+ regex: "(==|!=|<=?|>=?)",
+ token: ["keyword.operator.comparison.nix"]
+ }, {
+ regex: "((?:[+*/%-]|\\~)=)",
+ token: ["keyword.operator.assignment.arithmetic.nix"]
+ }, {
+ regex: "=",
+ token: "keyword.operator.assignment.nix"
+ }, {
+ token: "string",
+ regex: "''",
+ next: "qqdoc"
+ }, {
+ token: "string",
+ regex: "'",
+ next: "qstring"
+ }, {
+ token: "string",
+ regex: '"',
+ push: "qqstring"
+ }, {
+ token: "constant.numeric", // hex
+ regex: "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token: "constant.numeric", // float
+ regex: "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token: keywordMapper,
+ regex: "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ regex: "}",
+ token: function(val, start, stack) {
+ return stack[1] && stack[1].charAt(0) == "q" ? "constant.language.escape" : "text";
+ },
+ next: "pop"
+ }],
+ "comment": [{
+ token: "comment", // closing comment
+ regex: "\\*\\/",
+ next: "start"
+ }, {
+ defaultToken: "comment"
+ }],
+ "qqdoc": [
+ {
+ token: "constant.language.escape",
+ regex: /\$\{/,
+ push: "start"
+ }, {
+ token: "string",
+ regex: "''",
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }],
+ "qqstring": [
+ {
+ token: "constant.language.escape",
+ regex: /\$\{/,
+ push: "start"
+ }, {
+ token: "string",
+ regex: '"',
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }],
+ "qstring": [
+ {
+ token: "constant.language.escape",
+ regex: /\$\{/,
+ push: "start"
+ }, {
+ token: "string",
+ regex: "'",
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ };
+
+ this.normalizeRules();
+ };
+
+ oop.inherits(NixHighlightRules, TextHighlightRules);
+
+ exports.NixHighlightRules = NixHighlightRules;
+});
+
+ace.define("ace/mode/nix",["require","exports","module","ace/lib/oop","ace/mode/c_cpp","ace/mode/nix_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var CMode = require("./c_cpp").Mode;
+var NixHighlightRules = require("./nix_highlight_rules").NixHighlightRules;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ CMode.call(this);
+ this.HighlightRules = NixHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, CMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/nix";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-nsis.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-nsis.js
new file mode 100644
index 00000000..087bd2b5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-nsis.js
@@ -0,0 +1,305 @@
+ace.define("ace/mode/nsis_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var NSISHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ token: "keyword.compiler.nsis",
+ regex: /^\s*!(?:include|addincludedir|addplugindir|appendfile|cd|delfile|echo|error|execute|packhdr|pragma|finalize|getdllversion|system|tempfile|warning|verbose|define|undef|insertmacro|macro|macroend|makensis|searchparse|searchreplace)\b/,
+ caseInsensitive: true
+ }, {
+ token: "keyword.command.nsis",
+ regex: /^\s*(?:Abort|AddBrandingImage|AddSize|AllowRootDirInstall|AllowSkipFiles|AutoCloseWindow|BGFont|BGGradient|BrandingText|BringToFront|Call|CallInstDLL|Caption|ChangeUI|CheckBitmap|ClearErrors|CompletedText|ComponentText|CopyFiles|CRCCheck|CreateDirectory|CreateFont|CreateShortCut|Delete|DeleteINISec|DeleteINIStr|DeleteRegKey|DeleteRegValue|DetailPrint|DetailsButtonText|DirText|DirVar|DirVerify|EnableWindow|EnumRegKey|EnumRegValue|Exch|Exec|ExecShell|ExecShellWait|ExecWait|ExpandEnvStrings|File|FileBufSize|FileClose|FileErrorText|FileOpen|FileRead|FileReadByte|FileReadUTF16LE|FileReadWord|FileWriteUTF16LE|FileSeek|FileWrite|FileWriteByte|FileWriteWord|FindClose|FindFirst|FindNext|FindWindow|FlushINI|GetCurInstType|GetCurrentAddress|GetDlgItem|GetDLLVersion|GetDLLVersionLocal|GetErrorLevel|GetFileTime|GetFileTimeLocal|GetFullPathName|GetFunctionAddress|GetInstDirError|GetLabelAddress|GetTempFileName|Goto|HideWindow|Icon|IfAbort|IfErrors|IfFileExists|IfRebootFlag|IfSilent|InitPluginsDir|InstallButtonText|InstallColors|InstallDir|InstallDirRegKey|InstProgressFlags|InstType|InstTypeGetText|InstTypeSetText|IntCmp|IntCmpU|IntFmt|IntOp|IsWindow|LangString|LicenseBkColor|LicenseData|LicenseForceSelection|LicenseLangString|LicenseText|LoadLanguageFile|LockWindow|LogSet|LogText|ManifestDPIAware|ManifestSupportedOS|MessageBox|MiscButtonText|Name|Nop|OutFile|Page|PageCallbacks|Pop|Push|Quit|ReadEnvStr|ReadINIStr|ReadRegDWORD|ReadRegStr|Reboot|RegDLL|Rename|RequestExecutionLevel|ReserveFile|Return|RMDir|SearchPath|SectionGetFlags|SectionGetInstTypes|SectionGetSize|SectionGetText|SectionIn|SectionSetFlags|SectionSetInstTypes|SectionSetSize|SectionSetText|SendMessage|SetAutoClose|SetBrandingImage|SetCompress|SetCompressor|SetCompressorDictSize|SetCtlColors|SetCurInstType|SetDatablockOptimize|SetDateSave|SetDetailsPrint|SetDetailsView|SetErrorLevel|SetErrors|SetFileAttributes|SetFont|SetOutPath|SetOverwrite|SetRebootFlag|SetRegView|SetShellVarContext|SetSilent|ShowInstDetails|ShowUninstDetails|ShowWindow|SilentInstall|SilentUnInstall|Sleep|SpaceTexts|StrCmp|StrCmpS|StrCpy|StrLen|SubCaption|Unicode|UninstallButtonText|UninstallCaption|UninstallIcon|UninstallSubCaption|UninstallText|UninstPage|UnRegDLL|Var|VIAddVersionKey|VIFileVersion|VIProductVersion|WindowIcon|WriteINIStr|WriteRegBin|WriteRegDWORD|WriteRegExpandStr|WriteRegMultiStr|WriteRegNone|WriteRegStr|WriteUninstaller|XPStyle)\b/,
+ caseInsensitive: true
+ }, {
+ token: "keyword.control.nsis",
+ regex: /^\s*!(?:ifdef|ifndef|if|ifmacrodef|ifmacrondef|else|endif)\b/,
+ caseInsensitive: true
+ }, {
+ token: "keyword.plugin.nsis",
+ regex: /^\s*\w+::\w+/,
+ caseInsensitive: true
+ }, {
+ token: "keyword.operator.comparison.nsis",
+ regex: /[!<>]?=|<>|<|>/
+ }, {
+ token: "support.function.nsis",
+ regex: /(?:\b|^\s*)(?:Function|FunctionEnd|Section|SectionEnd|SectionGroup|SectionGroupEnd|PageEx|PageExEnd)\b/,
+ caseInsensitive: true
+ }, {
+ token: "support.library.nsis",
+ regex: /\${[\w\.:-]+}/
+ }, {
+ token: "constant.nsis",
+ regex: /\b(?:ARCHIVE|FILE_ATTRIBUTE_ARCHIVE|FILE_ATTRIBUTE_HIDDEN|FILE_ATTRIBUTE_NORMAL|FILE_ATTRIBUTE_OFFLINE|FILE_ATTRIBUTE_READONLY|FILE_ATTRIBUTE_SYSTEM|FILE_ATTRIBUTE_TEMPORARY|HIDDEN|HKCC|HKCR(32|64)?|HKCU(32|64)?|HKDD|HKEY_CLASSES_ROOT|HKEY_CURRENT_CONFIG|HKEY_CURRENT_USER|HKEY_DYN_DATA|HKEY_LOCAL_MACHINE|HKEY_PERFORMANCE_DATA|HKEY_USERS|HKLM(32|64)?|HKPD|HKU|IDABORT|IDCANCEL|IDD_DIR|IDD_INST|IDD_INSTFILES|IDD_LICENSE|IDD_SELCOM|IDD_UNINST|IDD_VERIFY|IDIGNORE|IDNO|IDOK|IDRETRY|IDYES|MB_ABORTRETRYIGNORE|MB_DEFBUTTON1|MB_DEFBUTTON2|MB_DEFBUTTON3|MB_DEFBUTTON4|MB_ICONEXCLAMATION|MB_ICONINFORMATION|MB_ICONQUESTION|MB_ICONSTOP|MB_OK|MB_OKCANCEL|MB_RETRYCANCEL|MB_RIGHT|MB_RTLREADING|MB_SETFOREGROUND|MB_TOPMOST|MB_USERICON|MB_YESNO|MB_YESNOCANCEL|NORMAL|OFFLINE|READONLY|SHCTX|SHELL_CONTEXT|SW_HIDE|SW_SHOWDEFAULT|SW_SHOWMAXIMIZED|SW_SHOWMINIMIZED|SW_SHOWNORMAL|SYSTEM|TEMPORARY)\b/,
+ caseInsensitive: true
+ }, {
+ token: "constant.library.nsis",
+ regex: /\${(?:AtLeastServicePack|AtLeastWin7|AtLeastWin8|AtLeastWin10|AtLeastWin95|AtLeastWin98|AtLeastWin2000|AtLeastWin2003|AtLeastWin2008|AtLeastWin2008R2|AtLeastWinME|AtLeastWinNT4|AtLeastWinVista|AtLeastWinXP|AtMostServicePack|AtMostWin7|AtMostWin8|AtMostWin10|AtMostWin95|AtMostWin98|AtMostWin2000|AtMostWin2003|AtMostWin2008|AtMostWin2008R2|AtMostWinME|AtMostWinNT4|AtMostWinVista|AtMostWinXP|IsNT|IsServer|IsServicePack|IsWin7|IsWin8|IsWin10|IsWin95|IsWin98|IsWin2000|IsWin2003|IsWin2008|IsWin2008R2|IsWinME|IsWinNT4|IsWinVista|IsWinXP)}/
+ }, {
+ token: "constant.language.boolean.true.nsis",
+ regex: /\b(?:true|on)\b/
+ }, {
+ token: "constant.language.boolean.false.nsis",
+ regex: /\b(?:false|off)\b/
+ }, {
+ token: "constant.language.option.nsis",
+ regex: /(?:\b|^\s*)(?:(?:un\.)?components|(?:un\.)?custom|(?:un\.)?directory|(?:un\.)?instfiles|(?:un\.)?license|uninstConfirm|admin|all|auto|both|bottom|bzip2|current|force|hide|highest|ifdiff|ifnewer|lastused|leave|left|listonly|lzma|nevershow|none|normal|notset|right|show|silent|silentlog|textonly|top|try|user|Win10|Win7|Win8|WinVista|zlib)\b/,
+ caseInsensitive: true
+ }, {
+ token: "constant.language.slash-option.nsis",
+ regex: /\b\/(?:a|BRANDING|CENTER|COMPONENTSONLYONCUSTOM|CUSTOMSTRING=|date|e|ENABLECANCEL|FILESONLY|file|FINAL|GLOBAL|gray|ifempty|ifndef|ignorecase|IMGID=|ITALIC|LANG=|NOCUSTOM|noerrors|NONFATAL|nonfatal|oname=|o|REBOOTOK|redef|RESIZETOFIT|r|SHORT|SILENT|SOLID|STRIKE|TRIM|UNDERLINE|utcdate|windows|x)\b/,
+ caseInsensitive: true
+ }, {
+ token: "constant.numeric.nsis",
+ regex: /\b(?:0(?:x|X)[0-9a-fA-F]+|[0-9]+(?:\.[0-9]+)?)\b/
+ }, {
+ token: "entity.name.function.nsis",
+ regex: /\$\([\w\.:-]+\)/
+ }, {
+ token: "storage.type.function.nsis",
+ regex: /\$\w+/
+ }, {
+ token: "punctuation.definition.string.begin.nsis",
+ regex: /`/,
+ push: [{
+ token: "punctuation.definition.string.end.nsis",
+ regex: /`/,
+ next: "pop"
+ }, {
+ token: "constant.character.escape.nsis",
+ regex: /\$\\./
+ }, {
+ defaultToken: "string.quoted.back.nsis"
+ }]
+ }, {
+ token: "punctuation.definition.string.begin.nsis",
+ regex: /"/,
+ push: [{
+ token: "punctuation.definition.string.end.nsis",
+ regex: /"/,
+ next: "pop"
+ }, {
+ token: "constant.character.escape.nsis",
+ regex: /\$\\./
+ }, {
+ defaultToken: "string.quoted.double.nsis"
+ }]
+ }, {
+ token: "punctuation.definition.string.begin.nsis",
+ regex: /'/,
+ push: [{
+ token: "punctuation.definition.string.end.nsis",
+ regex: /'/,
+ next: "pop"
+ }, {
+ token: "constant.character.escape.nsis",
+ regex: /\$\\./
+ }, {
+ defaultToken: "string.quoted.single.nsis"
+ }]
+ }, {
+ token: [
+ "punctuation.definition.comment.nsis",
+ "comment.line.nsis"
+ ],
+ regex: /(;|#)(.*$)/
+ }, {
+ token: "punctuation.definition.comment.nsis",
+ regex: /\/\*/,
+ push: [{
+ token: "punctuation.definition.comment.nsis",
+ regex: /\*\//,
+ next: "pop"
+ }, {
+ defaultToken: "comment.block.nsis"
+ }]
+ }, {
+ token: "text",
+ regex: /(?:!include|!insertmacro)\b/
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+NSISHighlightRules.metaData = {
+ comment: "\n\ttodo: - highlight functions\n\t",
+ fileTypes: ["nsi", "nsh"],
+ name: "NSIS",
+ scopeName: "source.nsis"
+};
+
+
+oop.inherits(NSISHighlightRules, TextHighlightRules);
+
+exports.NSISHighlightRules = NSISHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/nsis",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/nsis_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var NSISHighlightRules = require("./nsis_highlight_rules").NSISHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = NSISHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = [";", "#"];
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/nsis";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-objectivec.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-objectivec.js
new file mode 100644
index 00000000..1dd0cb58
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-objectivec.js
@@ -0,0 +1,725 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/c_cpp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var cFunctions = exports.cFunctions = "\\b(?:hypot(?:f|l)?|s(?:scanf|ystem|nprintf|ca(?:nf|lb(?:n(?:f|l)?|ln(?:f|l)?))|i(?:n(?:h(?:f|l)?|f|l)?|gn(?:al|bit))|tr(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?)|error|pbrk|ftime|len|rchr|xfrm)|printf|et(?:jmp|vbuf|locale|buf)|qrt(?:f|l)?|w(?:scanf|printf)|rand)|n(?:e(?:arbyint(?:f|l)?|xt(?:toward(?:f|l)?|after(?:f|l)?))|an(?:f|l)?)|c(?:s(?:in(?:h(?:f|l)?|f|l)?|qrt(?:f|l)?)|cos(?:h(?:f)?|f|l)?|imag(?:f|l)?|t(?:ime|an(?:h(?:f|l)?|f|l)?)|o(?:s(?:h(?:f|l)?|f|l)?|nj(?:f|l)?|pysign(?:f|l)?)|p(?:ow(?:f|l)?|roj(?:f|l)?)|e(?:il(?:f|l)?|xp(?:f|l)?)|l(?:o(?:ck|g(?:f|l)?)|earerr)|a(?:sin(?:h(?:f|l)?|f|l)?|cos(?:h(?:f|l)?|f|l)?|tan(?:h(?:f|l)?|f|l)?|lloc|rg(?:f|l)?|bs(?:f|l)?)|real(?:f|l)?|brt(?:f|l)?)|t(?:ime|o(?:upper|lower)|an(?:h(?:f|l)?|f|l)?|runc(?:f|l)?|gamma(?:f|l)?|mp(?:nam|file))|i(?:s(?:space|n(?:ormal|an)|cntrl|inf|digit|u(?:nordered|pper)|p(?:unct|rint)|finite|w(?:space|c(?:ntrl|type)|digit|upper|p(?:unct|rint)|lower|al(?:num|pha)|graph|xdigit|blank)|l(?:ower|ess(?:equal|greater)?)|al(?:num|pha)|gr(?:eater(?:equal)?|aph)|xdigit|blank)|logb(?:f|l)?|max(?:div|abs))|di(?:v|fftime)|_Exit|unget(?:c|wc)|p(?:ow(?:f|l)?|ut(?:s|c(?:har)?|wc(?:har)?)|error|rintf)|e(?:rf(?:c(?:f|l)?|f|l)?|x(?:it|p(?:2(?:f|l)?|f|l|m1(?:f|l)?)?))|v(?:s(?:scanf|nprintf|canf|printf|w(?:scanf|printf))|printf|f(?:scanf|printf|w(?:scanf|printf))|w(?:scanf|printf)|a_(?:start|copy|end|arg))|qsort|f(?:s(?:canf|e(?:tpos|ek))|close|tell|open|dim(?:f|l)?|p(?:classify|ut(?:s|c|w(?:s|c))|rintf)|e(?:holdexcept|set(?:e(?:nv|xceptflag)|round)|clearexcept|testexcept|of|updateenv|r(?:aiseexcept|ror)|get(?:e(?:nv|xceptflag)|round))|flush|w(?:scanf|ide|printf|rite)|loor(?:f|l)?|abs(?:f|l)?|get(?:s|c|pos|w(?:s|c))|re(?:open|e|ad|xp(?:f|l)?)|m(?:in(?:f|l)?|od(?:f|l)?|a(?:f|l|x(?:f|l)?)?))|l(?:d(?:iv|exp(?:f|l)?)|o(?:ngjmp|cal(?:time|econv)|g(?:1(?:p(?:f|l)?|0(?:f|l)?)|2(?:f|l)?|f|l|b(?:f|l)?)?)|abs|l(?:div|abs|r(?:int(?:f|l)?|ound(?:f|l)?))|r(?:int(?:f|l)?|ound(?:f|l)?)|gamma(?:f|l)?)|w(?:scanf|c(?:s(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?|mbs)|pbrk|ftime|len|r(?:chr|tombs)|xfrm)|to(?:b|mb)|rtomb)|printf|mem(?:set|c(?:hr|py|mp)|move))|a(?:s(?:sert|ctime|in(?:h(?:f|l)?|f|l)?)|cos(?:h(?:f|l)?|f|l)?|t(?:o(?:i|f|l(?:l)?)|exit|an(?:h(?:f|l)?|2(?:f|l)?|f|l)?)|b(?:s|ort))|g(?:et(?:s|c(?:har)?|env|wc(?:har)?)|mtime)|r(?:int(?:f|l)?|ound(?:f|l)?|e(?:name|alloc|wind|m(?:ove|quo(?:f|l)?|ainder(?:f|l)?))|a(?:nd|ise))|b(?:search|towc)|m(?:odf(?:f|l)?|em(?:set|c(?:hr|py|mp)|move)|ktime|alloc|b(?:s(?:init|towcs|rtowcs)|towc|len|r(?:towc|len))))\\b"
+
+var c_cppHighlightRules = function() {
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|goto|if|_Pragma|" +
+ "return|switch|while|catch|operator|try|throw|using"
+ );
+
+ var storageType = (
+ "asm|__asm__|auto|bool|_Bool|char|_Complex|double|enum|float|" +
+ "_Imaginary|int|long|short|signed|struct|typedef|union|unsigned|void|" +
+ "class|wchar_t|template|char16_t|char32_t"
+ );
+
+ var storageModifiers = (
+ "const|extern|register|restrict|static|volatile|inline|private|" +
+ "protected|public|friend|explicit|virtual|export|mutable|typename|" +
+ "constexpr|new|delete|alignas|alignof|decltype|noexcept|thread_local"
+ );
+
+ var keywordOperators = (
+ "and|and_eq|bitand|bitor|compl|not|not_eq|or|or_eq|typeid|xor|xor_eq" +
+ "const_cast|dynamic_cast|reinterpret_cast|static_cast|sizeof|namespace"
+ );
+
+ var builtinConstants = (
+ "NULL|true|false|TRUE|FALSE|nullptr"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.control" : keywordControls,
+ "storage.type" : storageType,
+ "storage.modifier" : storageModifiers,
+ "keyword.operator" : keywordOperators,
+ "variable.language": "this",
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+ var escapeRe = /\\(?:['"?\\abfnrtv]|[0-7]{1,3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}U[a-fA-F\d]{8}|.)/.source;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "//$",
+ next : "start"
+ }, {
+ token : "comment",
+ regex : "//",
+ next : "singleLineComment"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : "'(?:" + escapeRe + "|.)?'"
+ }, {
+ token : "string.start",
+ regex : '"',
+ stateName: "qqstring",
+ next: [
+ { token: "string", regex: /\\\s*$/, next: "qqstring" },
+ { token: "constant.language.escape", regex: escapeRe },
+ { token: "constant.language.escape", regex: /%[^'"\\]/ },
+ { token: "string.end", regex: '"|$', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "string.start",
+ regex : 'R"\\(',
+ stateName: "rawString",
+ next: [
+ { token: "string.end", regex: '\\)"', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|pragma|line|define|undef)\\b",
+ next : "directive"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|if|ifdef|else|elif|ifndef)\\b"
+ }, {
+ token : "support.function.C99.c",
+ regex : cFunctions
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|<<=|>>=|>>>=|<>|&&|\|\||\?:|[*%\/+\-&\^|~!<>=]=?/
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "singleLineComment" : [
+ {
+ token : "comment",
+ regex : /\\$/,
+ next : "singleLineComment"
+ }, {
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ],
+ "directive" : [
+ {
+ token : "constant.other.multiline",
+ regex : /\\/
+ },
+ {
+ token : "constant.other.multiline",
+ regex : /.*\\/
+ },
+ {
+ token : "constant.other",
+ regex : "\\s*<.+?>",
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : '\\s*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]',
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
+ next : "start"
+ },
+ {
+ token : "constant.other",
+ regex : /[^\\\/]+/,
+ next : "start"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(c_cppHighlightRules, TextHighlightRules);
+
+exports.c_cppHighlightRules = c_cppHighlightRules;
+});
+
+ace.define("ace/mode/objectivec_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/c_cpp_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var C_Highlight_File = require("./c_cpp_highlight_rules");
+var CHighlightRules = C_Highlight_File.c_cppHighlightRules;
+
+var ObjectiveCHighlightRules = function() {
+
+ var escapedConstRe = "\\\\(?:[abefnrtv'\"?\\\\]|" +
+ "[0-3]\\d{1,2}|" +
+ "[4-7]\\d?|" +
+ "222|" +
+ "x[a-zA-Z0-9]+)";
+
+ var specialVariables = [{
+ regex: "\\b_cmd\\b",
+ token: "variable.other.selector.objc"
+ }, {
+ regex: "\\b(?:self|super)\\b",
+ token: "variable.language.objc"
+ }
+ ];
+
+ var cObj = new CHighlightRules();
+ var cRules = cObj.getRules();
+
+ this.$rules = {
+ "start": [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ },
+ {
+ token: [ "storage.type.objc", "punctuation.definition.storage.type.objc",
+ "entity.name.type.objc", "text", "entity.other.inherited-class.objc"
+ ],
+ regex: "(@)(interface|protocol)(?!.+;)(\\s+[A-Za-z_][A-Za-z0-9_]*)(\\s*:\\s*)([A-Za-z]+)"
+ },
+ {
+ token: [ "storage.type.objc" ],
+ regex: "(@end)"
+ },
+ {
+ token: [ "storage.type.objc", "entity.name.type.objc",
+ "entity.other.inherited-class.objc"
+ ],
+ regex: "(@implementation)(\\s+[A-Za-z_][A-Za-z0-9_]*)(\\s*?::\\s*(?:[A-Za-z][A-Za-z0-9]*))?"
+ },
+ {
+ token: "string.begin.objc",
+ regex: '@"',
+ next: "constant_NSString"
+ },
+ {
+ token: "storage.type.objc",
+ regex: "\\bid\\s*<",
+ next: "protocol_list"
+ },
+ {
+ token: "keyword.control.macro.objc",
+ regex: "\\bNS_DURING|NS_HANDLER|NS_ENDHANDLER\\b"
+ },
+ {
+ token: ["punctuation.definition.keyword.objc", "keyword.control.exception.objc"],
+ regex: "(@)(try|catch|finally|throw)\\b"
+ },
+ {
+ token: ["punctuation.definition.keyword.objc", "keyword.other.objc"],
+ regex: "(@)(defs|encode)\\b"
+ },
+ {
+ token: ["storage.type.id.objc", "text"],
+ regex: "(\\bid\\b)(\\s|\\n)?"
+ },
+ {
+ token: "storage.type.objc",
+ regex: "\\bIBOutlet|IBAction|BOOL|SEL|id|unichar|IMP|Class\\b"
+ },
+ {
+ token: [ "punctuation.definition.storage.type.objc", "storage.type.objc"],
+ regex: "(@)(class|protocol)\\b"
+ },
+ {
+ token: [ "punctuation.definition.storage.type.objc", "punctuation"],
+ regex: "(@selector)(\\s*\\()",
+ next: "selectors"
+ },
+ {
+ token: [ "punctuation.definition.storage.modifier.objc", "storage.modifier.objc"],
+ regex: "(@)(synchronized|public|private|protected|package)\\b"
+ },
+ {
+ token: "constant.language.objc",
+ regex: "\\bYES|NO|Nil|nil\\b"
+ },
+ {
+ token: "support.variable.foundation",
+ regex: "\\bNSApp\\b"
+ },
+ {
+ token: [ "support.function.cocoa.leopard"],
+ regex: "(?:\\b)(NS(?:Rect(?:ToCGRect|FromCGRect)|MakeCollectable|S(?:tringFromProtocol|ize(?:ToCGSize|FromCGSize))|Draw(?:NinePartImage|ThreePartImage)|P(?:oint(?:ToCGPoint|FromCGPoint)|rotocolFromString)|EventMaskFromType|Value))(?:\\b)"
+ },
+ {
+ token: ["support.function.cocoa"],
+ regex: "(?:\\b)(NS(?:R(?:ound(?:DownToMultipleOfPageSize|UpToMultipleOfPageSize)|un(?:CriticalAlertPanel(?:RelativeToWindow)?|InformationalAlertPanel(?:RelativeToWindow)?|AlertPanel(?:RelativeToWindow)?)|e(?:set(?:MapTable|HashTable)|c(?:ycleZone|t(?:Clip(?:List)?|F(?:ill(?:UsingOperation|List(?:UsingOperation|With(?:Grays|Colors(?:UsingOperation)?))?)?|romString))|ordAllocationEvent)|turnAddress|leaseAlertPanel|a(?:dPixel|l(?:MemoryAvailable|locateCollectable))|gisterServicesProvider)|angeFromString)|Get(?:SizeAndAlignment|CriticalAlertPanel|InformationalAlertPanel|UncaughtExceptionHandler|FileType(?:s)?|WindowServerMemory|AlertPanel)|M(?:i(?:n(?:X|Y)|d(?:X|Y))|ouseInRect|a(?:p(?:Remove|Get|Member|Insert(?:IfAbsent|KnownAbsent)?)|ke(?:R(?:ect|ange)|Size|Point)|x(?:Range|X|Y)))|B(?:itsPer(?:SampleFromDepth|PixelFromDepth)|e(?:stDepth|ep|gin(?:CriticalAlertSheet|InformationalAlertSheet|AlertSheet)))|S(?:ho(?:uldRetainWithZone|w(?:sServicesMenuItem|AnimationEffect))|tringFrom(?:R(?:ect|ange)|MapTable|S(?:ize|elector)|HashTable|Class|Point)|izeFromString|e(?:t(?:ShowsServicesMenuItem|ZoneName|UncaughtExceptionHandler|FocusRingStyle)|lectorFromString|archPathForDirectoriesInDomains)|wap(?:Big(?:ShortToHost|IntToHost|DoubleToHost|FloatToHost|Long(?:ToHost|LongToHost))|Short|Host(?:ShortTo(?:Big|Little)|IntTo(?:Big|Little)|DoubleTo(?:Big|Little)|FloatTo(?:Big|Little)|Long(?:To(?:Big|Little)|LongTo(?:Big|Little)))|Int|Double|Float|L(?:ittle(?:ShortToHost|IntToHost|DoubleToHost|FloatToHost|Long(?:ToHost|LongToHost))|ong(?:Long)?)))|H(?:ighlightRect|o(?:stByteOrder|meDirectory(?:ForUser)?)|eight|ash(?:Remove|Get|Insert(?:IfAbsent|KnownAbsent)?)|FSType(?:CodeFromFileType|OfFile))|N(?:umberOfColorComponents|ext(?:MapEnumeratorPair|HashEnumeratorItem))|C(?:o(?:n(?:tainsRect|vert(?:GlyphsToPackedGlyphs|Swapped(?:DoubleToHost|FloatToHost)|Host(?:DoubleToSwapped|FloatToSwapped)))|unt(?:MapTable|HashTable|Frames|Windows(?:ForContext)?)|py(?:M(?:emoryPages|apTableWithZone)|Bits|HashTableWithZone|Object)|lorSpaceFromDepth|mpare(?:MapTables|HashTables))|lassFromString|reate(?:MapTable(?:WithZone)?|HashTable(?:WithZone)?|Zone|File(?:namePboardType|ContentsPboardType)))|TemporaryDirectory|I(?:s(?:ControllerMarker|EmptyRect|FreedObject)|n(?:setRect|crementExtraRefCount|te(?:r(?:sect(?:sRect|ionR(?:ect|ange))|faceStyleForKey)|gralRect)))|Zone(?:Realloc|Malloc|Name|Calloc|Fr(?:omPointer|ee))|O(?:penStepRootDirectory|ffsetRect)|D(?:i(?:sableScreenUpdates|videRect)|ottedFrameRect|e(?:c(?:imal(?:Round|Multiply|S(?:tring|ubtract)|Normalize|Co(?:py|mpa(?:ct|re))|IsNotANumber|Divide|Power|Add)|rementExtraRefCountWasZero)|faultMallocZone|allocate(?:MemoryPages|Object))|raw(?:Gr(?:oove|ayBezel)|B(?:itmap|utton)|ColorTiledRects|TiledRects|DarkBezel|W(?:hiteBezel|indowBackground)|LightBezel))|U(?:serName|n(?:ionR(?:ect|ange)|registerServicesProvider)|pdateDynamicServices)|Java(?:Bundle(?:Setup|Cleanup)|Setup(?:VirtualMachine)?|Needs(?:ToLoadClasses|VirtualMachine)|ClassesF(?:orBundle|romPath)|ObjectNamedInPath|ProvidesClasses)|P(?:oint(?:InRect|FromString)|erformService|lanarFromDepth|ageSize)|E(?:n(?:d(?:MapTableEnumeration|HashTableEnumeration)|umerate(?:MapTable|HashTable)|ableScreenUpdates)|qual(?:R(?:ects|anges)|Sizes|Points)|raseRect|xtraRefCount)|F(?:ileTypeForHFSTypeCode|ullUserName|r(?:ee(?:MapTable|HashTable)|ame(?:Rect(?:WithWidth(?:UsingOperation)?)?|Address)))|Wi(?:ndowList(?:ForContext)?|dth)|Lo(?:cationInRange|g(?:v|PageSize)?)|A(?:ccessibility(?:R(?:oleDescription(?:ForUIElement)?|aiseBadArgumentException)|Unignored(?:Children(?:ForOnlyChild)?|Descendant|Ancestor)|PostNotification|ActionDescription)|pplication(?:Main|Load)|vailableWindowDepths|ll(?:MapTable(?:Values|Keys)|HashTableObjects|ocate(?:MemoryPages|Collectable|Object)))))(?:\\b)"
+ },
+ {
+ token: ["support.class.cocoa.leopard"],
+ regex: "(?:\\b)(NS(?:RuleEditor|G(?:arbageCollector|radient)|MapTable|HashTable|Co(?:ndition|llectionView(?:Item)?)|T(?:oolbarItemGroup|extInputClient|r(?:eeNode|ackingArea))|InvocationOperation|Operation(?:Queue)?|D(?:ictionaryController|ockTile)|P(?:ointer(?:Functions|Array)|athC(?:o(?:ntrol(?:Delegate)?|mponentCell)|ell(?:Delegate)?)|r(?:intPanelAccessorizing|edicateEditor(?:RowTemplate)?))|ViewController|FastEnumeration|Animat(?:ionContext|ablePropertyContainer)))(?:\\b)"
+ },
+ {
+ token: ["support.class.cocoa"],
+ regex: "(?:\\b)(NS(?:R(?:u(?:nLoop|ler(?:Marker|View))|e(?:sponder|cursiveLock|lativeSpecifier)|an(?:domSpecifier|geSpecifier))|G(?:etCommand|lyph(?:Generator|Storage|Info)|raphicsContext)|XML(?:Node|D(?:ocument|TD(?:Node)?)|Parser|Element)|M(?:iddleSpecifier|ov(?:ie(?:View)?|eCommand)|utable(?:S(?:tring|et)|C(?:haracterSet|opying)|IndexSet|D(?:ictionary|ata)|URLRequest|ParagraphStyle|A(?:ttributedString|rray))|e(?:ssagePort(?:NameServer)?|nu(?:Item(?:Cell)?|View)?|t(?:hodSignature|adata(?:Item|Query(?:ResultGroup|AttributeValueTuple)?)))|a(?:ch(?:BootstrapServer|Port)|trix))|B(?:itmapImageRep|ox|u(?:ndle|tton(?:Cell)?)|ezierPath|rowser(?:Cell)?)|S(?:hadow|c(?:anner|r(?:ipt(?:SuiteRegistry|C(?:o(?:ercionHandler|mmand(?:Description)?)|lassDescription)|ObjectSpecifier|ExecutionContext|WhoseTest)|oll(?:er|View)|een))|t(?:epper(?:Cell)?|atus(?:Bar|Item)|r(?:ing|eam))|imple(?:HorizontalTypesetter|CString)|o(?:cketPort(?:NameServer)?|und|rtDescriptor)|p(?:e(?:cifierTest|ech(?:Recognizer|Synthesizer)|ll(?:Server|Checker))|litView)|e(?:cureTextField(?:Cell)?|t(?:Command)?|archField(?:Cell)?|rializer|gmentedC(?:ontrol|ell))|lider(?:Cell)?|avePanel)|H(?:ost|TTP(?:Cookie(?:Storage)?|URLResponse)|elpManager)|N(?:ib(?:Con(?:nector|trolConnector)|OutletConnector)?|otification(?:Center|Queue)?|u(?:ll|mber(?:Formatter)?)|etService(?:Browser)?|ameSpecifier)|C(?:ha(?:ngeSpelling|racterSet)|o(?:n(?:stantString|nection|trol(?:ler)?|ditionLock)|d(?:ing|er)|unt(?:Command|edSet)|pying|lor(?:Space|P(?:ick(?:ing(?:Custom|Default)|er)|anel)|Well|List)?|m(?:p(?:oundPredicate|arisonPredicate)|boBox(?:Cell)?))|u(?:stomImageRep|rsor)|IImageRep|ell|l(?:ipView|o(?:seCommand|neCommand)|assDescription)|a(?:ched(?:ImageRep|URLResponse)|lendar(?:Date)?)|reateCommand)|T(?:hread|ypesetter|ime(?:Zone|r)|o(?:olbar(?:Item(?:Validations)?)?|kenField(?:Cell)?)|ext(?:Block|Storage|Container|Tab(?:le(?:Block)?)?|Input|View|Field(?:Cell)?|List|Attachment(?:Cell)?)?|a(?:sk|b(?:le(?:Header(?:Cell|View)|Column|View)|View(?:Item)?))|reeController)|I(?:n(?:dex(?:S(?:pecifier|et)|Path)|put(?:Manager|S(?:tream|erv(?:iceProvider|er(?:MouseTracker)?)))|vocation)|gnoreMisspelledWords|mage(?:Rep|Cell|View)?)|O(?:ut(?:putStream|lineView)|pen(?:GL(?:Context|Pixel(?:Buffer|Format)|View)|Panel)|bj(?:CTypeSerializationCallBack|ect(?:Controller)?))|D(?:i(?:st(?:antObject(?:Request)?|ributed(?:NotificationCenter|Lock))|ctionary|rectoryEnumerator)|ocument(?:Controller)?|e(?:serializer|cimalNumber(?:Behaviors|Handler)?|leteCommand)|at(?:e(?:Components|Picker(?:Cell)?|Formatter)?|a)|ra(?:wer|ggingInfo))|U(?:ser(?:InterfaceValidations|Defaults(?:Controller)?)|RL(?:Re(?:sponse|quest)|Handle(?:Client)?|C(?:onnection|ache|redential(?:Storage)?)|Download(?:Delegate)?|Prot(?:ocol(?:Client)?|ectionSpace)|AuthenticationChallenge(?:Sender)?)?|n(?:iqueIDSpecifier|doManager|archiver))|P(?:ipe|o(?:sitionalSpecifier|pUpButton(?:Cell)?|rt(?:Message|NameServer|Coder)?)|ICTImageRep|ersistentDocument|DFImageRep|a(?:steboard|nel|ragraphStyle|geLayout)|r(?:int(?:Info|er|Operation|Panel)|o(?:cessInfo|tocolChecker|perty(?:Specifier|ListSerialization)|gressIndicator|xy)|edicate))|E(?:numerator|vent|PSImageRep|rror|x(?:ception|istsCommand|pression))|V(?:iew(?:Animation)?|al(?:idated(?:ToobarItem|UserInterfaceItem)|ue(?:Transformer)?))|Keyed(?:Unarchiver|Archiver)|Qui(?:ckDrawView|tCommand)|F(?:ile(?:Manager|Handle|Wrapper)|o(?:nt(?:Manager|Descriptor|Panel)?|rm(?:Cell|atter)))|W(?:hoseSpecifier|indow(?:Controller)?|orkspace)|L(?:o(?:c(?:k(?:ing)?|ale)|gicalTest)|evelIndicator(?:Cell)?|ayoutManager)|A(?:ssertionHandler|nimation|ctionCell|ttributedString|utoreleasePool|TSTypesetter|ppl(?:ication|e(?:Script|Event(?:Manager|Descriptor)))|ffineTransform|lert|r(?:chiver|ray(?:Controller)?))))(?:\\b)"
+ },
+ {
+ token: ["support.type.cocoa.leopard"],
+ regex: "(?:\\b)(NS(?:R(?:u(?:nLoop|ler(?:Marker|View))|e(?:sponder|cursiveLock|lativeSpecifier)|an(?:domSpecifier|geSpecifier))|G(?:etCommand|lyph(?:Generator|Storage|Info)|raphicsContext)|XML(?:Node|D(?:ocument|TD(?:Node)?)|Parser|Element)|M(?:iddleSpecifier|ov(?:ie(?:View)?|eCommand)|utable(?:S(?:tring|et)|C(?:haracterSet|opying)|IndexSet|D(?:ictionary|ata)|URLRequest|ParagraphStyle|A(?:ttributedString|rray))|e(?:ssagePort(?:NameServer)?|nu(?:Item(?:Cell)?|View)?|t(?:hodSignature|adata(?:Item|Query(?:ResultGroup|AttributeValueTuple)?)))|a(?:ch(?:BootstrapServer|Port)|trix))|B(?:itmapImageRep|ox|u(?:ndle|tton(?:Cell)?)|ezierPath|rowser(?:Cell)?)|S(?:hadow|c(?:anner|r(?:ipt(?:SuiteRegistry|C(?:o(?:ercionHandler|mmand(?:Description)?)|lassDescription)|ObjectSpecifier|ExecutionContext|WhoseTest)|oll(?:er|View)|een))|t(?:epper(?:Cell)?|atus(?:Bar|Item)|r(?:ing|eam))|imple(?:HorizontalTypesetter|CString)|o(?:cketPort(?:NameServer)?|und|rtDescriptor)|p(?:e(?:cifierTest|ech(?:Recognizer|Synthesizer)|ll(?:Server|Checker))|litView)|e(?:cureTextField(?:Cell)?|t(?:Command)?|archField(?:Cell)?|rializer|gmentedC(?:ontrol|ell))|lider(?:Cell)?|avePanel)|H(?:ost|TTP(?:Cookie(?:Storage)?|URLResponse)|elpManager)|N(?:ib(?:Con(?:nector|trolConnector)|OutletConnector)?|otification(?:Center|Queue)?|u(?:ll|mber(?:Formatter)?)|etService(?:Browser)?|ameSpecifier)|C(?:ha(?:ngeSpelling|racterSet)|o(?:n(?:stantString|nection|trol(?:ler)?|ditionLock)|d(?:ing|er)|unt(?:Command|edSet)|pying|lor(?:Space|P(?:ick(?:ing(?:Custom|Default)|er)|anel)|Well|List)?|m(?:p(?:oundPredicate|arisonPredicate)|boBox(?:Cell)?))|u(?:stomImageRep|rsor)|IImageRep|ell|l(?:ipView|o(?:seCommand|neCommand)|assDescription)|a(?:ched(?:ImageRep|URLResponse)|lendar(?:Date)?)|reateCommand)|T(?:hread|ypesetter|ime(?:Zone|r)|o(?:olbar(?:Item(?:Validations)?)?|kenField(?:Cell)?)|ext(?:Block|Storage|Container|Tab(?:le(?:Block)?)?|Input|View|Field(?:Cell)?|List|Attachment(?:Cell)?)?|a(?:sk|b(?:le(?:Header(?:Cell|View)|Column|View)|View(?:Item)?))|reeController)|I(?:n(?:dex(?:S(?:pecifier|et)|Path)|put(?:Manager|S(?:tream|erv(?:iceProvider|er(?:MouseTracker)?)))|vocation)|gnoreMisspelledWords|mage(?:Rep|Cell|View)?)|O(?:ut(?:putStream|lineView)|pen(?:GL(?:Context|Pixel(?:Buffer|Format)|View)|Panel)|bj(?:CTypeSerializationCallBack|ect(?:Controller)?))|D(?:i(?:st(?:antObject(?:Request)?|ributed(?:NotificationCenter|Lock))|ctionary|rectoryEnumerator)|ocument(?:Controller)?|e(?:serializer|cimalNumber(?:Behaviors|Handler)?|leteCommand)|at(?:e(?:Components|Picker(?:Cell)?|Formatter)?|a)|ra(?:wer|ggingInfo))|U(?:ser(?:InterfaceValidations|Defaults(?:Controller)?)|RL(?:Re(?:sponse|quest)|Handle(?:Client)?|C(?:onnection|ache|redential(?:Storage)?)|Download(?:Delegate)?|Prot(?:ocol(?:Client)?|ectionSpace)|AuthenticationChallenge(?:Sender)?)?|n(?:iqueIDSpecifier|doManager|archiver))|P(?:ipe|o(?:sitionalSpecifier|pUpButton(?:Cell)?|rt(?:Message|NameServer|Coder)?)|ICTImageRep|ersistentDocument|DFImageRep|a(?:steboard|nel|ragraphStyle|geLayout)|r(?:int(?:Info|er|Operation|Panel)|o(?:cessInfo|tocolChecker|perty(?:Specifier|ListSerialization)|gressIndicator|xy)|edicate))|E(?:numerator|vent|PSImageRep|rror|x(?:ception|istsCommand|pression))|V(?:iew(?:Animation)?|al(?:idated(?:ToobarItem|UserInterfaceItem)|ue(?:Transformer)?))|Keyed(?:Unarchiver|Archiver)|Qui(?:ckDrawView|tCommand)|F(?:ile(?:Manager|Handle|Wrapper)|o(?:nt(?:Manager|Descriptor|Panel)?|rm(?:Cell|atter)))|W(?:hoseSpecifier|indow(?:Controller)?|orkspace)|L(?:o(?:c(?:k(?:ing)?|ale)|gicalTest)|evelIndicator(?:Cell)?|ayoutManager)|A(?:ssertionHandler|nimation|ctionCell|ttributedString|utoreleasePool|TSTypesetter|ppl(?:ication|e(?:Script|Event(?:Manager|Descriptor)))|ffineTransform|lert|r(?:chiver|ray(?:Controller)?))))(?:\\b)"
+ },
+ {
+ token: ["support.class.quartz"],
+ regex: "(?:\\b)(C(?:I(?:Sampler|Co(?:ntext|lor)|Image(?:Accumulator)?|PlugIn(?:Registration)?|Vector|Kernel|Filter(?:Generator|Shape)?)|A(?:Renderer|MediaTiming(?:Function)?|BasicAnimation|ScrollLayer|Constraint(?:LayoutManager)?|T(?:iledLayer|extLayer|rans(?:ition|action))|OpenGLLayer|PropertyAnimation|KeyframeAnimation|Layer|A(?:nimation(?:Group)?|ction))))(?:\\b)"
+ },
+ {
+ token: ["support.type.quartz"],
+ regex: "(?:\\b)(C(?:G(?:Float|Point|Size|Rect)|IFormat|AConstraintAttribute))(?:\\b)"
+ },
+ {
+ token: ["support.type.cocoa"],
+ regex: "(?:\\b)(NS(?:R(?:ect(?:Edge)?|ange)|G(?:lyph(?:Relation|LayoutMode)?|radientType)|M(?:odalSession|a(?:trixMode|p(?:Table|Enumerator)))|B(?:itmapImageFileType|orderType|uttonType|ezelStyle|ackingStoreType|rowserColumnResizingType)|S(?:cr(?:oll(?:er(?:Part|Arrow)|ArrowPosition)|eenAuxiliaryOpaque)|tringEncoding|ize|ocketNativeHandle|election(?:Granularity|Direction|Affinity)|wapped(?:Double|Float)|aveOperationType)|Ha(?:sh(?:Table|Enumerator)|ndler(?:2)?)|C(?:o(?:ntrol(?:Size|Tint)|mp(?:ositingOperation|arisonResult))|ell(?:State|Type|ImagePosition|Attribute))|T(?:hreadPrivate|ypesetterGlyphInfo|i(?:ckMarkPosition|tlePosition|meInterval)|o(?:ol(?:TipTag|bar(?:SizeMode|DisplayMode))|kenStyle)|IFFCompression|ext(?:TabType|Alignment)|ab(?:State|leViewDropOperation|ViewType)|rackingRectTag)|ImageInterpolation|Zone|OpenGL(?:ContextAuxiliary|PixelFormatAuxiliary)|D(?:ocumentChangeType|atePickerElementFlags|ra(?:werState|gOperation))|UsableScrollerParts|P(?:oint|r(?:intingPageOrder|ogressIndicator(?:Style|Th(?:ickness|readInfo))))|EventType|KeyValueObservingOptions|Fo(?:nt(?:SymbolicTraits|TraitMask|Action)|cusRingType)|W(?:indow(?:OrderingMode|Depth)|orkspace(?:IconCreationOptions|LaunchOptions)|ritingDirection)|L(?:ineBreakMode|ayout(?:Status|Direction))|A(?:nimation(?:Progress|Effect)|ppl(?:ication(?:TerminateReply|DelegateReply|PrintReply)|eEventManagerSuspensionID)|ffineTransformStruct|lertStyle)))(?:\\b)"
+ },
+ {
+ token: ["support.constant.cocoa"],
+ regex: "(?:\\b)(NS(?:NotFound|Ordered(?:Ascending|Descending|Same)))(?:\\b)"
+ },
+ {
+ token: ["support.constant.notification.cocoa.leopard"],
+ regex: "(?:\\b)(NS(?:MenuDidBeginTracking|ViewDidUpdateTrackingAreas)?Notification)(?:\\b)"
+ },
+ {
+ token: ["support.constant.notification.cocoa"],
+ regex: "(?:\\b)(NS(?:Menu(?:Did(?:RemoveItem|SendAction|ChangeItem|EndTracking|AddItem)|WillSendAction)|S(?:ystemColorsDidChange|plitView(?:DidResizeSubviews|WillResizeSubviews))|C(?:o(?:nt(?:extHelpModeDid(?:Deactivate|Activate)|rolT(?:intDidChange|extDid(?:BeginEditing|Change|EndEditing)))|lor(?:PanelColorDidChange|ListDidChange)|mboBox(?:Selection(?:IsChanging|DidChange)|Will(?:Dismiss|PopUp)))|lassDescriptionNeededForClass)|T(?:oolbar(?:DidRemoveItem|WillAddItem)|ext(?:Storage(?:DidProcessEditing|WillProcessEditing)|Did(?:BeginEditing|Change|EndEditing)|View(?:DidChange(?:Selection|TypingAttributes)|WillChangeNotifyingTextView))|ableView(?:Selection(?:IsChanging|DidChange)|ColumnDid(?:Resize|Move)))|ImageRepRegistryDidChange|OutlineView(?:Selection(?:IsChanging|DidChange)|ColumnDid(?:Resize|Move)|Item(?:Did(?:Collapse|Expand)|Will(?:Collapse|Expand)))|Drawer(?:Did(?:Close|Open)|Will(?:Close|Open))|PopUpButton(?:CellWillPopUp|WillPopUp)|View(?:GlobalFrameDidChange|BoundsDidChange|F(?:ocusDidChange|rameDidChange))|FontSetChanged|W(?:indow(?:Did(?:Resi(?:ze|gn(?:Main|Key))|M(?:iniaturize|ove)|Become(?:Main|Key)|ChangeScreen(?:|Profile)|Deminiaturize|Update|E(?:ndSheet|xpose))|Will(?:M(?:iniaturize|ove)|BeginSheet|Close))|orkspace(?:SessionDid(?:ResignActive|BecomeActive)|Did(?:Mount|TerminateApplication|Unmount|PerformFileOperation|Wake|LaunchApplication)|Will(?:Sleep|Unmount|PowerOff|LaunchApplication)))|A(?:ntialiasThresholdChanged|ppl(?:ication(?:Did(?:ResignActive|BecomeActive|Hide|ChangeScreenParameters|U(?:nhide|pdate)|FinishLaunching)|Will(?:ResignActive|BecomeActive|Hide|Terminate|U(?:nhide|pdate)|FinishLaunching))|eEventManagerWillProcessFirstEvent)))Notification)(?:\\b)"
+ },
+ {
+ token: ["support.constant.cocoa.leopard"],
+ regex: "(?:\\b)(NS(?:RuleEditor(?:RowType(?:Simple|Compound)|NestingMode(?:Si(?:ngle|mple)|Compound|List))|GradientDraws(?:BeforeStartingLocation|AfterEndingLocation)|M(?:inusSetExpressionType|a(?:chPortDeallocate(?:ReceiveRight|SendRight|None)|pTable(?:StrongMemory|CopyIn|ZeroingWeakMemory|ObjectPointerPersonality)))|B(?:oxCustom|undleExecutableArchitecture(?:X86|I386|PPC(?:64)?)|etweenPredicateOperatorType|ackgroundStyle(?:Raised|Dark|L(?:ight|owered)))|S(?:tring(?:DrawingTruncatesLastVisibleLine|EncodingConversion(?:ExternalRepresentation|AllowLossy))|ubqueryExpressionType|p(?:e(?:ech(?:SentenceBoundary|ImmediateBoundary|WordBoundary)|llingState(?:GrammarFlag|SpellingFlag))|litViewDividerStyleThi(?:n|ck))|e(?:rvice(?:RequestTimedOutError|M(?:iscellaneousError|alformedServiceDictionaryError)|InvalidPasteboardDataError|ErrorM(?:inimum|aximum)|Application(?:NotFoundError|LaunchFailedError))|gmentStyle(?:Round(?:Rect|ed)|SmallSquare|Capsule|Textured(?:Rounded|Square)|Automatic)))|H(?:UDWindowMask|ashTable(?:StrongMemory|CopyIn|ZeroingWeakMemory|ObjectPointerPersonality))|N(?:oModeColorPanel|etServiceNoAutoRename)|C(?:hangeRedone|o(?:ntainsPredicateOperatorType|l(?:orRenderingIntent(?:RelativeColorimetric|Saturation|Default|Perceptual|AbsoluteColorimetric)|lectorDisabledOption))|ellHit(?:None|ContentArea|TrackableArea|EditableTextArea))|T(?:imeZoneNameStyle(?:S(?:hort(?:Standard|DaylightSaving)|tandard)|DaylightSaving)|extFieldDatePickerStyle|ableViewSelectionHighlightStyle(?:Regular|SourceList)|racking(?:Mouse(?:Moved|EnteredAndExited)|CursorUpdate|InVisibleRect|EnabledDuringMouseDrag|A(?:ssumeInside|ctive(?:In(?:KeyWindow|ActiveApp)|WhenFirstResponder|Always))))|I(?:n(?:tersectSetExpressionType|dexedColorSpaceModel)|mageScale(?:None|Proportionally(?:Down|UpOrDown)|AxesIndependently))|Ope(?:nGLPFAAllowOfflineRenderers|rationQueue(?:DefaultMaxConcurrentOperationCount|Priority(?:High|Normal|Very(?:High|Low)|Low)))|D(?:iacriticInsensitiveSearch|ownloadsDirectory)|U(?:nionSetExpressionType|TF(?:16(?:BigEndianStringEncoding|StringEncoding|LittleEndianStringEncoding)|32(?:BigEndianStringEncoding|StringEncoding|LittleEndianStringEncoding)))|P(?:ointerFunctions(?:Ma(?:chVirtualMemory|llocMemory)|Str(?:ongMemory|uctPersonality)|C(?:StringPersonality|opyIn)|IntegerPersonality|ZeroingWeakMemory|O(?:paque(?:Memory|Personality)|bjectP(?:ointerPersonality|ersonality)))|at(?:hStyle(?:Standard|NavigationBar|PopUp)|ternColorSpaceModel)|rintPanelShows(?:Scaling|Copies|Orientation|P(?:a(?:perSize|ge(?:Range|SetupAccessory))|review)))|Executable(?:RuntimeMismatchError|NotLoadableError|ErrorM(?:inimum|aximum)|L(?:inkError|oadError)|ArchitectureMismatchError)|KeyValueObservingOption(?:Initial|Prior)|F(?:i(?:ndPanelSubstringMatchType(?:StartsWith|Contains|EndsWith|FullWord)|leRead(?:TooLargeError|UnknownStringEncodingError))|orcedOrderingSearch)|Wi(?:ndow(?:BackingLocation(?:MainMemory|Default|VideoMemory)|Sharing(?:Read(?:Only|Write)|None)|CollectionBehavior(?:MoveToActiveSpace|CanJoinAllSpaces|Default))|dthInsensitiveSearch)|AggregateExpressionType))(?:\\b)"
+ },
+ {
+ token: ["support.constant.cocoa"],
+ regex: "(?:\\b)(NS(?:R(?:GB(?:ModeColorPanel|ColorSpaceModel)|ight(?:Mouse(?:D(?:own(?:Mask)?|ragged(?:Mask)?)|Up(?:Mask)?)|T(?:ext(?:Movement|Alignment)|ab(?:sBezelBorder|StopType))|ArrowFunctionKey)|ound(?:RectBezelStyle|Bankers|ed(?:BezelStyle|TokenStyle|DisclosureBezelStyle)|Down|Up|Plain|Line(?:CapStyle|JoinStyle))|un(?:StoppedResponse|ContinuesResponse|AbortedResponse)|e(?:s(?:izableWindowMask|et(?:CursorRectsRunLoopOrdering|FunctionKey))|ce(?:ssedBezelStyle|iver(?:sCantHandleCommandScriptError|EvaluationScriptError))|turnTextMovement|doFunctionKey|quiredArgumentsMissingScriptError|l(?:evancyLevelIndicatorStyle|ative(?:Before|After))|gular(?:SquareBezelStyle|ControlSize)|moveTraitFontAction)|a(?:n(?:domSubelement|geDateMode)|tingLevelIndicatorStyle|dio(?:ModeMatrix|Button)))|G(?:IFFileType|lyph(?:Below|Inscribe(?:B(?:elow|ase)|Over(?:strike|Below)|Above)|Layout(?:WithPrevious|A(?:tAPoint|gainstAPoint))|A(?:ttribute(?:BidiLevel|Soft|Inscribe|Elastic)|bove))|r(?:ooveBorder|eaterThan(?:Comparison|OrEqualTo(?:Comparison|PredicateOperatorType)|PredicateOperatorType)|a(?:y(?:ModeColorPanel|ColorSpaceModel)|dient(?:None|Con(?:cave(?:Strong|Weak)|vex(?:Strong|Weak)))|phiteControlTint)))|XML(?:N(?:o(?:tationDeclarationKind|de(?:CompactEmptyElement|IsCDATA|OptionsNone|Use(?:SingleQuotes|DoubleQuotes)|Pre(?:serve(?:NamespaceOrder|C(?:haracterReferences|DATA)|DTD|Prefixes|E(?:ntities|mptyElements)|Quotes|Whitespace|A(?:ttributeOrder|ll))|ttyPrint)|ExpandEmptyElement))|amespaceKind)|CommentKind|TextKind|InvalidKind|D(?:ocument(?:X(?:MLKind|HTMLKind|Include)|HTMLKind|T(?:idy(?:XML|HTML)|extKind)|IncludeContentTypeDeclaration|Validate|Kind)|TDKind)|P(?:arser(?:GTRequiredError|XMLDeclNot(?:StartedError|FinishedError)|Mi(?:splaced(?:XMLDeclarationError|CDATAEndStringError)|xedContentDeclNot(?:StartedError|FinishedError))|S(?:t(?:andaloneValueError|ringNot(?:StartedError|ClosedError))|paceRequiredError|eparatorRequiredError)|N(?:MTOKENRequiredError|o(?:t(?:ationNot(?:StartedError|FinishedError)|WellBalancedError)|DTDError)|amespaceDeclarationError|AMERequiredError)|C(?:haracterRef(?:In(?:DTDError|PrologError|EpilogError)|AtEOFError)|o(?:nditionalSectionNot(?:StartedError|FinishedError)|mment(?:NotFinishedError|ContainsDoubleHyphenError))|DATANotFinishedError)|TagNameMismatchError|In(?:ternalError|valid(?:HexCharacterRefError|C(?:haracter(?:RefError|InEntityError|Error)|onditionalSectionError)|DecimalCharacterRefError|URIError|Encoding(?:NameError|Error)))|OutOfMemoryError|D(?:ocumentStartError|elegateAbortedParseError|OCTYPEDeclNotFinishedError)|U(?:RI(?:RequiredError|FragmentError)|n(?:declaredEntityError|parsedEntityError|knownEncodingError|finishedTagError))|P(?:CDATARequiredError|ublicIdentifierRequiredError|arsedEntityRef(?:MissingSemiError|NoNameError|In(?:Internal(?:SubsetError|Error)|PrologError|EpilogError)|AtEOFError)|r(?:ocessingInstructionNot(?:StartedError|FinishedError)|ematureDocumentEndError))|E(?:n(?:codingNotSupportedError|tity(?:Ref(?:In(?:DTDError|PrologError|EpilogError)|erence(?:MissingSemiError|WithoutNameError)|LoopError|AtEOFError)|BoundaryError|Not(?:StartedError|FinishedError)|Is(?:ParameterError|ExternalError)|ValueRequiredError))|qualExpectedError|lementContentDeclNot(?:StartedError|FinishedError)|xt(?:ernalS(?:tandaloneEntityError|ubsetNotFinishedError)|raContentError)|mptyDocumentError)|L(?:iteralNot(?:StartedError|FinishedError)|T(?:RequiredError|SlashRequiredError)|essThanSymbolInAttributeError)|Attribute(?:RedefinedError|HasNoValueError|Not(?:StartedError|FinishedError)|ListNot(?:StartedError|FinishedError)))|rocessingInstructionKind)|E(?:ntity(?:GeneralKind|DeclarationKind|UnparsedKind|P(?:ar(?:sedKind|ameterKind)|redefined))|lement(?:Declaration(?:MixedKind|UndefinedKind|E(?:lementKind|mptyKind)|Kind|AnyKind)|Kind))|Attribute(?:N(?:MToken(?:sKind|Kind)|otationKind)|CDATAKind|ID(?:Ref(?:sKind|Kind)|Kind)|DeclarationKind|En(?:tit(?:yKind|iesKind)|umerationKind)|Kind))|M(?:i(?:n(?:XEdge|iaturizableWindowMask|YEdge|uteCalendarUnit)|terLineJoinStyle|ddleSubelement|xedState)|o(?:nthCalendarUnit|deSwitchFunctionKey|use(?:Moved(?:Mask)?|E(?:ntered(?:Mask)?|ventSubtype|xited(?:Mask)?))|veToBezierPathElement|mentary(?:ChangeButton|Push(?:Button|InButton)|Light(?:Button)?))|enuFunctionKey|a(?:c(?:intoshInterfaceStyle|OSRomanStringEncoding)|tchesPredicateOperatorType|ppedRead|x(?:XEdge|YEdge))|ACHOperatingSystem)|B(?:MPFileType|o(?:ttomTabsBezelBorder|ldFontMask|rderlessWindowMask|x(?:Se(?:condary|parator)|OldStyle|Primary))|uttLineCapStyle|e(?:zelBorder|velLineJoinStyle|low(?:Bottom|Top)|gin(?:sWith(?:Comparison|PredicateOperatorType)|FunctionKey))|lueControlTint|ack(?:spaceCharacter|tabTextMovement|ingStore(?:Retained|Buffered|Nonretained)|TabCharacter|wardsSearch|groundTab)|r(?:owser(?:NoColumnResizing|UserColumnResizing|AutoColumnResizing)|eakFunctionKey))|S(?:h(?:ift(?:JISStringEncoding|KeyMask)|ow(?:ControlGlyphs|InvisibleGlyphs)|adowlessSquareBezelStyle)|y(?:s(?:ReqFunctionKey|tem(?:D(?:omainMask|efined(?:Mask)?)|FunctionKey))|mbolStringEncoding)|c(?:a(?:nnedOption|le(?:None|ToFit|Proportionally))|r(?:oll(?:er(?:NoPart|Increment(?:Page|Line|Arrow)|Decrement(?:Page|Line|Arrow)|Knob(?:Slot)?|Arrows(?:M(?:inEnd|axEnd)|None|DefaultSetting))|Wheel(?:Mask)?|LockFunctionKey)|eenChangedEventType))|t(?:opFunctionKey|r(?:ingDrawing(?:OneShot|DisableScreenFontSubstitution|Uses(?:DeviceMetrics|FontLeading|LineFragmentOrigin))|eam(?:Status(?:Reading|NotOpen|Closed|Open(?:ing)?|Error|Writing|AtEnd)|Event(?:Has(?:BytesAvailable|SpaceAvailable)|None|OpenCompleted|E(?:ndEncountered|rrorOccurred)))))|i(?:ngle(?:DateMode|UnderlineStyle)|ze(?:DownFontAction|UpFontAction))|olarisOperatingSystem|unOSOperatingSystem|pecialPageOrder|e(?:condCalendarUnit|lect(?:By(?:Character|Paragraph|Word)|i(?:ng(?:Next|Previous)|onAffinity(?:Downstream|Upstream))|edTab|FunctionKey)|gmentSwitchTracking(?:Momentary|Select(?:One|Any)))|quareLineCapStyle|witchButton|ave(?:ToOperation|Op(?:tions(?:Yes|No|Ask)|eration)|AsOperation)|mall(?:SquareBezelStyle|C(?:ontrolSize|apsFontMask)|IconButtonBezelStyle))|H(?:ighlightModeMatrix|SBModeColorPanel|o(?:ur(?:Minute(?:SecondDatePickerElementFlag|DatePickerElementFlag)|CalendarUnit)|rizontalRuler|meFunctionKey)|TTPCookieAcceptPolicy(?:Never|OnlyFromMainDocumentDomain|Always)|e(?:lp(?:ButtonBezelStyle|KeyMask|FunctionKey)|avierFontAction)|PUXOperatingSystem)|Year(?:MonthDa(?:yDatePickerElementFlag|tePickerElementFlag)|CalendarUnit)|N(?:o(?:n(?:StandardCharacterSetFontMask|ZeroWindingRule|activatingPanelMask|LossyASCIIStringEncoding)|Border|t(?:ification(?:SuspensionBehavior(?:Hold|Coalesce|D(?:eliverImmediately|rop))|NoCoalescing|CoalescingOn(?:Sender|Name)|DeliverImmediately|PostToAllSessions)|PredicateType|EqualToPredicateOperatorType)|S(?:cr(?:iptError|ollerParts)|ubelement|pecifierError)|CellMask|T(?:itle|opLevelContainersSpecifierError|abs(?:BezelBorder|NoBorder|LineBorder))|I(?:nterfaceStyle|mage)|UnderlineStyle|FontChangeAction)|u(?:ll(?:Glyph|CellType)|m(?:eric(?:Search|PadKeyMask)|berFormatter(?:Round(?:Half(?:Down|Up|Even)|Ceiling|Down|Up|Floor)|Behavior(?:10|Default)|S(?:cientificStyle|pellOutStyle)|NoStyle|CurrencyStyle|DecimalStyle|P(?:ercentStyle|ad(?:Before(?:Suffix|Prefix)|After(?:Suffix|Prefix))))))|e(?:t(?:Services(?:BadArgumentError|NotFoundError|C(?:ollisionError|ancelledError)|TimeoutError|InvalidError|UnknownError|ActivityInProgress)|workDomainMask)|wlineCharacter|xt(?:StepInterfaceStyle|FunctionKey))|EXTSTEPStringEncoding|a(?:t(?:iveShortGlyphPacking|uralTextAlignment)|rrowFontMask))|C(?:hange(?:ReadOtherContents|GrayCell(?:Mask)?|BackgroundCell(?:Mask)?|Cleared|Done|Undone|Autosaved)|MYK(?:ModeColorPanel|ColorSpaceModel)|ircular(?:BezelStyle|Slider)|o(?:n(?:stantValueExpressionType|t(?:inuousCapacityLevelIndicatorStyle|entsCellMask|ain(?:sComparison|erSpecifierError)|rol(?:Glyph|KeyMask))|densedFontMask)|lor(?:Panel(?:RGBModeMask|GrayModeMask|HSBModeMask|C(?:MYKModeMask|olorListModeMask|ustomPaletteModeMask|rayonModeMask)|WheelModeMask|AllModesMask)|ListModeColorPanel)|reServiceDirectory|m(?:p(?:osite(?:XOR|Source(?:In|O(?:ut|ver)|Atop)|Highlight|C(?:opy|lear)|Destination(?:In|O(?:ut|ver)|Atop)|Plus(?:Darker|Lighter))|ressedFontMask)|mandKeyMask))|u(?:stom(?:SelectorPredicateOperatorType|PaletteModeColorPanel)|r(?:sor(?:Update(?:Mask)?|PointingDevice)|veToBezierPathElement))|e(?:nterT(?:extAlignment|abStopType)|ll(?:State|H(?:ighlighted|as(?:Image(?:Horizontal|OnLeftOrBottom)|OverlappingImage))|ChangesContents|Is(?:Bordered|InsetButton)|Disabled|Editable|LightsBy(?:Gray|Background|Contents)|AllowsMixedState))|l(?:ipPagination|o(?:s(?:ePathBezierPathElement|ableWindowMask)|ckAndCalendarDatePickerStyle)|ear(?:ControlTint|DisplayFunctionKey|LineFunctionKey))|a(?:seInsensitive(?:Search|PredicateOption)|n(?:notCreateScriptCommandError|cel(?:Button|TextMovement))|chesDirectory|lculation(?:NoError|Overflow|DivideByZero|Underflow|LossOfPrecision)|rriageReturnCharacter)|r(?:itical(?:Request|AlertStyle)|ayonModeColorPanel))|T(?:hick(?:SquareBezelStyle|erSquareBezelStyle)|ypesetter(?:Behavior|HorizontalTabAction|ContainerBreakAction|ZeroAdvancementAction|OriginalBehavior|ParagraphBreakAction|WhitespaceAction|L(?:ineBreakAction|atestBehavior))|i(?:ckMark(?:Right|Below|Left|Above)|tledWindowMask|meZoneDatePickerElementFlag)|o(?:olbarItemVisibilityPriority(?:Standard|High|User|Low)|pTabsBezelBorder|ggleButton)|IFF(?:Compression(?:N(?:one|EXT)|CCITTFAX(?:3|4)|OldJPEG|JPEG|PackBits|LZW)|FileType)|e(?:rminate(?:Now|Cancel|Later)|xt(?:Read(?:InapplicableDocumentTypeError|WriteErrorM(?:inimum|aximum))|Block(?:M(?:i(?:nimum(?:Height|Width)|ddleAlignment)|a(?:rgin|ximum(?:Height|Width)))|B(?:o(?:ttomAlignment|rder)|aselineAlignment)|Height|TopAlignment|P(?:ercentageValueType|adding)|Width|AbsoluteValueType)|StorageEdited(?:Characters|Attributes)|CellType|ured(?:RoundedBezelStyle|BackgroundWindowMask|SquareBezelStyle)|Table(?:FixedLayoutAlgorithm|AutomaticLayoutAlgorithm)|Field(?:RoundedBezel|SquareBezel|AndStepperDatePickerStyle)|WriteInapplicableDocumentTypeError|ListPrependEnclosingMarker))|woByteGlyphPacking|ab(?:Character|TextMovement|le(?:tP(?:oint(?:Mask|EventSubtype)?|roximity(?:Mask|EventSubtype)?)|Column(?:NoResizing|UserResizingMask|AutoresizingMask)|View(?:ReverseSequentialColumnAutoresizingStyle|GridNone|S(?:olid(?:HorizontalGridLineMask|VerticalGridLineMask)|equentialColumnAutoresizingStyle)|NoColumnAutoresizing|UniformColumnAutoresizingStyle|FirstColumnOnlyAutoresizingStyle|LastColumnOnlyAutoresizingStyle)))|rackModeMatrix)|I(?:n(?:sert(?:CharFunctionKey|FunctionKey|LineFunctionKey)|t(?:Type|ernalS(?:criptError|pecifierError))|dexSubelement|validIndexSpecifierError|formational(?:Request|AlertStyle)|PredicateOperatorType)|talicFontMask|SO(?:2022JPStringEncoding|Latin(?:1StringEncoding|2StringEncoding))|dentityMappingCharacterCollection|llegalTextMovement|mage(?:R(?:ight|ep(?:MatchesDevice|LoadStatus(?:ReadingHeader|Completed|InvalidData|Un(?:expectedEOF|knownType)|WillNeedAllData)))|Below|C(?:ellType|ache(?:BySize|Never|Default|Always))|Interpolation(?:High|None|Default|Low)|O(?:nly|verlaps)|Frame(?:Gr(?:oove|ayBezel)|Button|None|Photo)|L(?:oadStatus(?:ReadError|C(?:ompleted|ancelled)|InvalidData|UnexpectedEOF)|eft)|A(?:lign(?:Right|Bottom(?:Right|Left)?|Center|Top(?:Right|Left)?|Left)|bove)))|O(?:n(?:State|eByteGlyphPacking|OffButton|lyScrollerArrows)|ther(?:Mouse(?:D(?:own(?:Mask)?|ragged(?:Mask)?)|Up(?:Mask)?)|TextMovement)|SF1OperatingSystem|pe(?:n(?:GL(?:GO(?:Re(?:setLibrary|tainRenderers)|ClearFormatCache|FormatCacheSize)|PFA(?:R(?:obust|endererID)|M(?:inimumPolicy|ulti(?:sample|Screen)|PSafe|aximumPolicy)|BackingStore|S(?:creenMask|te(?:ncilSize|reo)|ingleRenderer|upersample|ample(?:s|Buffers|Alpha))|NoRecovery|C(?:o(?:lor(?:Size|Float)|mpliant)|losestPolicy)|OffScreen|D(?:oubleBuffer|epthSize)|PixelBuffer|VirtualScreenCount|FullScreen|Window|A(?:cc(?:umSize|elerated)|ux(?:Buffers|DepthStencil)|l(?:phaSize|lRenderers))))|StepUnicodeReservedBase)|rationNotSupportedForKeyS(?:criptError|pecifierError))|ffState|KButton|rPredicateType|bjC(?:B(?:itfield|oolType)|S(?:hortType|tr(?:ingType|uctType)|electorType)|NoType|CharType|ObjectType|DoubleType|UnionType|PointerType|VoidType|FloatType|Long(?:Type|longType)|ArrayType))|D(?:i(?:s(?:c(?:losureBezelStyle|reteCapacityLevelIndicatorStyle)|playWindowRunLoopOrdering)|acriticInsensitivePredicateOption|rect(?:Selection|PredicateModifier))|o(?:c(?:ModalWindowMask|ument(?:Directory|ationDirectory))|ubleType|wn(?:TextMovement|ArrowFunctionKey))|e(?:s(?:cendingPageOrder|ktopDirectory)|cimalTabStopType|v(?:ice(?:NColorSpaceModel|IndependentModifierFlagsMask)|eloper(?:Directory|ApplicationDirectory))|fault(?:ControlTint|TokenStyle)|lete(?:Char(?:acter|FunctionKey)|FunctionKey|LineFunctionKey)|moApplicationDirectory)|a(?:yCalendarUnit|teFormatter(?:MediumStyle|Behavior(?:10|Default)|ShortStyle|NoStyle|FullStyle|LongStyle))|ra(?:wer(?:Clos(?:ingState|edState)|Open(?:ingState|State))|gOperation(?:Generic|Move|None|Copy|Delete|Private|Every|Link|All)))|U(?:ser(?:CancelledError|D(?:irectory|omainMask)|FunctionKey)|RL(?:Handle(?:NotLoaded|Load(?:Succeeded|InProgress|Failed))|CredentialPersistence(?:None|Permanent|ForSession))|n(?:scaledWindowMask|cachedRead|i(?:codeStringEncoding|talicFontMask|fiedTitleAndToolbarWindowMask)|d(?:o(?:CloseGroupingRunLoopOrdering|FunctionKey)|e(?:finedDateComponent|rline(?:Style(?:Single|None|Thick|Double)|Pattern(?:Solid|D(?:ot|ash(?:Dot(?:Dot)?)?)))))|known(?:ColorSpaceModel|P(?:ointingDevice|ageOrder)|KeyS(?:criptError|pecifierError))|boldFontMask)|tilityWindowMask|TF8StringEncoding|p(?:dateWindowsRunLoopOrdering|TextMovement|ArrowFunctionKey))|J(?:ustifiedTextAlignment|PEG(?:2000FileType|FileType)|apaneseEUC(?:GlyphPacking|StringEncoding))|P(?:o(?:s(?:t(?:Now|erFontMask|WhenIdle|ASAP)|iti(?:on(?:Replace|Be(?:fore|ginning)|End|After)|ve(?:IntType|DoubleType|FloatType)))|pUp(?:NoArrow|ArrowAt(?:Bottom|Center))|werOffEventType|rtraitOrientation)|NGFileType|ush(?:InCell(?:Mask)?|OnPushOffButton)|e(?:n(?:TipMask|UpperSideMask|PointingDevice|LowerSideMask)|riodic(?:Mask)?)|P(?:S(?:caleField|tatus(?:Title|Field)|aveButton)|N(?:ote(?:Title|Field)|ame(?:Title|Field))|CopiesField|TitleField|ImageButton|OptionsButton|P(?:a(?:perFeedButton|ge(?:Range(?:To|From)|ChoiceMatrix))|reviewButton)|LayoutButton)|lainTextTokenStyle|a(?:useFunctionKey|ragraphSeparatorCharacter|ge(?:DownFunctionKey|UpFunctionKey))|r(?:int(?:ing(?:ReplyLater|Success|Cancelled|Failure)|ScreenFunctionKey|erTable(?:NotFound|OK|Error)|FunctionKey)|o(?:p(?:ertyList(?:XMLFormat|MutableContainers(?:AndLeaves)?|BinaryFormat|Immutable|OpenStepFormat)|rietaryStringEncoding)|gressIndicator(?:BarStyle|SpinningStyle|Preferred(?:SmallThickness|Thickness|LargeThickness|AquaThickness)))|e(?:ssedTab|vFunctionKey))|L(?:HeightForm|CancelButton|TitleField|ImageButton|O(?:KButton|rientationMatrix)|UnitsButton|PaperNameButton|WidthForm))|E(?:n(?:terCharacter|d(?:sWith(?:Comparison|PredicateOperatorType)|FunctionKey))|v(?:e(?:nOddWindingRule|rySubelement)|aluatedObjectExpressionType)|qualTo(?:Comparison|PredicateOperatorType)|ra(?:serPointingDevice|CalendarUnit|DatePickerElementFlag)|x(?:clude(?:10|QuickDrawElementsIconCreationOption)|pandedFontMask|ecuteFunctionKey))|V(?:i(?:ew(?:M(?:in(?:XMargin|YMargin)|ax(?:XMargin|YMargin))|HeightSizable|NotSizable|WidthSizable)|aPanelFontAction)|erticalRuler|a(?:lidationErrorM(?:inimum|aximum)|riableExpressionType))|Key(?:SpecifierEvaluationScriptError|Down(?:Mask)?|Up(?:Mask)?|PathExpressionType|Value(?:MinusSetMutation|SetSetMutation|Change(?:Re(?:placement|moval)|Setting|Insertion)|IntersectSetMutation|ObservingOption(?:New|Old)|UnionSetMutation|ValidationError))|QTMovie(?:NormalPlayback|Looping(?:BackAndForthPlayback|Playback))|F(?:1(?:1FunctionKey|7FunctionKey|2FunctionKey|8FunctionKey|3FunctionKey|9FunctionKey|4FunctionKey|5FunctionKey|FunctionKey|0FunctionKey|6FunctionKey)|7FunctionKey|i(?:nd(?:PanelAction(?:Replace(?:A(?:ndFind|ll(?:InSelection)?))?|S(?:howFindPanel|e(?:tFindString|lectAll(?:InSelection)?))|Next|Previous)|FunctionKey)|tPagination|le(?:Read(?:No(?:SuchFileError|PermissionError)|CorruptFileError|In(?:validFileNameError|applicableStringEncodingError)|Un(?:supportedSchemeError|knownError))|HandlingPanel(?:CancelButton|OKButton)|NoSuchFileError|ErrorM(?:inimum|aximum)|Write(?:NoPermissionError|In(?:validFileNameError|applicableStringEncodingError)|OutOfSpaceError|Un(?:supportedSchemeError|knownError))|LockingError)|xedPitchFontMask)|2(?:1FunctionKey|7FunctionKey|2FunctionKey|8FunctionKey|3FunctionKey|9FunctionKey|4FunctionKey|5FunctionKey|FunctionKey|0FunctionKey|6FunctionKey)|o(?:nt(?:Mo(?:noSpaceTrait|dernSerifsClass)|BoldTrait|S(?:ymbolicClass|criptsClass|labSerifsClass|ansSerifClass)|C(?:o(?:ndensedTrait|llectionApplicationOnlyMask)|larendonSerifsClass)|TransitionalSerifsClass|I(?:ntegerAdvancementsRenderingMode|talicTrait)|O(?:ldStyleSerifsClass|rnamentalsClass)|DefaultRenderingMode|U(?:nknownClass|IOptimizedTrait)|Panel(?:S(?:hadowEffectModeMask|t(?:andardModesMask|rikethroughEffectModeMask)|izeModeMask)|CollectionModeMask|TextColorEffectModeMask|DocumentColorEffectModeMask|UnderlineEffectModeMask|FaceModeMask|All(?:ModesMask|EffectsModeMask))|ExpandedTrait|VerticalTrait|F(?:amilyClassMask|reeformSerifsClass)|Antialiased(?:RenderingMode|IntegerAdvancementsRenderingMode))|cusRing(?:Below|Type(?:None|Default|Exterior)|Only|Above)|urByteGlyphPacking|rm(?:attingError(?:M(?:inimum|aximum))?|FeedCharacter))|8FunctionKey|unction(?:ExpressionType|KeyMask)|3(?:1FunctionKey|2FunctionKey|3FunctionKey|4FunctionKey|5FunctionKey|FunctionKey|0FunctionKey)|9FunctionKey|4FunctionKey|P(?:RevertButton|S(?:ize(?:Title|Field)|etButton)|CurrentField|Preview(?:Button|Field))|l(?:oat(?:ingPointSamplesBitmapFormat|Type)|agsChanged(?:Mask)?)|axButton|5FunctionKey|6FunctionKey)|W(?:heelModeColorPanel|indow(?:s(?:NTOperatingSystem|CP125(?:1StringEncoding|2StringEncoding|3StringEncoding|4StringEncoding|0StringEncoding)|95(?:InterfaceStyle|OperatingSystem))|M(?:iniaturizeButton|ovedEventType)|Below|CloseButton|ToolbarButton|ZoomButton|Out|DocumentIconButton|ExposedEventType|Above)|orkspaceLaunch(?:NewInstance|InhibitingBackgroundOnly|Default|PreferringClassic|WithoutA(?:ctivation|ddingToRecents)|A(?:sync|nd(?:Hide(?:Others)?|Print)|llowingClassicStartup))|eek(?:day(?:CalendarUnit|OrdinalCalendarUnit)|CalendarUnit)|a(?:ntsBidiLevels|rningAlertStyle)|r(?:itingDirection(?:RightToLeft|Natural|LeftToRight)|apCalendarComponents))|L(?:i(?:stModeMatrix|ne(?:Moves(?:Right|Down|Up|Left)|B(?:order|reakBy(?:C(?:harWrapping|lipping)|Truncating(?:Middle|Head|Tail)|WordWrapping))|S(?:eparatorCharacter|weep(?:Right|Down|Up|Left))|ToBezierPathElement|DoesntMove|arSlider)|teralSearch|kePredicateOperatorType|ghterFontAction|braryDirectory)|ocalDomainMask|e(?:ssThan(?:Comparison|OrEqualTo(?:Comparison|PredicateOperatorType)|PredicateOperatorType)|ft(?:Mouse(?:D(?:own(?:Mask)?|ragged(?:Mask)?)|Up(?:Mask)?)|T(?:ext(?:Movement|Alignment)|ab(?:sBezelBorder|StopType))|ArrowFunctionKey))|a(?:yout(?:RightToLeft|NotDone|CantFit|OutOfGlyphs|Done|LeftToRight)|ndscapeOrientation)|ABColorSpaceModel)|A(?:sc(?:iiWithDoubleByteEUCGlyphPacking|endingPageOrder)|n(?:y(?:Type|PredicateModifier|EventMask)|choredSearch|imation(?:Blocking|Nonblocking(?:Threaded)?|E(?:ffect(?:DisappearingItemDefault|Poof)|ase(?:In(?:Out)?|Out))|Linear)|dPredicateType)|t(?:Bottom|tachmentCharacter|omicWrite|Top)|SCIIStringEncoding|d(?:obe(?:GB1CharacterCollection|CNS1CharacterCollection|Japan(?:1CharacterCollection|2CharacterCollection)|Korea1CharacterCollection)|dTraitFontAction|minApplicationDirectory)|uto(?:saveOperation|Pagination)|pp(?:lication(?:SupportDirectory|D(?:irectory|e(?:fined(?:Mask)?|legateReply(?:Success|Cancel|Failure)|activatedEventType))|ActivatedEventType)|KitDefined(?:Mask)?)|l(?:ternateKeyMask|pha(?:ShiftKeyMask|NonpremultipliedBitmapFormat|FirstBitmapFormat)|ert(?:SecondButtonReturn|ThirdButtonReturn|OtherReturn|DefaultReturn|ErrorReturn|FirstButtonReturn|AlternateReturn)|l(?:ScrollerParts|DomainsMask|PredicateModifier|LibrariesDirectory|ApplicationsDirectory))|rgument(?:sWrongScriptError|EvaluationScriptError)|bove(?:Bottom|Top)|WTEventType)))(?:\\b)"
+ },
+ {
+ token: "support.function.C99.c",
+ regex: C_Highlight_File.cFunctions
+ },
+ {
+ token : cObj.getKeywords(),
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ },
+ {
+ token: "punctuation.section.scope.begin.objc",
+ regex: "\\[",
+ next: "bracketed_content"
+ },
+ {
+ token: "meta.function.objc",
+ regex: "^(?:-|\\+)\\s*"
+ }
+ ],
+ "constant_NSString": [
+ {
+ token: "constant.character.escape.objc",
+ regex: escapedConstRe
+ },
+ {
+ token: "invalid.illegal.unknown-escape.objc",
+ regex: "\\\\."
+ },
+ {
+ token: "string",
+ regex: '[^"\\\\]+'
+ },
+ {
+ token: "punctuation.definition.string.end",
+ regex: "\"",
+ next: "start"
+ }
+ ],
+ "protocol_list": [
+ {
+ token: "punctuation.section.scope.end.objc",
+ regex: ">",
+ next: "start"
+ },
+ {
+ token: "support.other.protocol.objc",
+ regex: "\bNS(?:GlyphStorage|M(?:utableCopying|enuItem)|C(?:hangeSpelling|o(?:ding|pying|lorPicking(?:Custom|Default)))|T(?:oolbarItemValidations|ext(?:Input|AttachmentCell))|I(?:nputServ(?:iceProvider|erMouseTracker)|gnoreMisspelledWords)|Obj(?:CTypeSerializationCallBack|ect)|D(?:ecimalNumberBehaviors|raggingInfo)|U(?:serInterfaceValidations|RL(?:HandleClient|DownloadDelegate|ProtocolClient|AuthenticationChallengeSender))|Validated(?:ToobarItem|UserInterfaceItem)|Locking)\b"
+ }
+ ],
+ "selectors": [
+ {
+ token: "support.function.any-method.name-of-parameter.objc",
+ regex: "\\b(?:[a-zA-Z_:][\\w]*)+"
+ },
+ {
+ token: "punctuation",
+ regex: "\\)",
+ next: "start"
+ }
+ ],
+ "bracketed_content": [
+ {
+ token: "punctuation.section.scope.end.objc",
+ regex: "]",
+ next: "start"
+ },
+ {
+ token: ["support.function.any-method.objc"],
+ regex: "(?:predicateWithFormat:| NSPredicate predicateWithFormat:)",
+ next: "start"
+ },
+ {
+ token: "support.function.any-method.objc",
+ regex: "\\w+(?::|(?=]))",
+ next: "start"
+ }
+ ],
+ "bracketed_strings": [
+ {
+ token: "punctuation.section.scope.end.objc",
+ regex: "]",
+ next: "start"
+ },
+ {
+ token: "keyword.operator.logical.predicate.cocoa",
+ regex: "\\b(?:AND|OR|NOT|IN)\\b"
+ },
+ {
+ token: ["invalid.illegal.unknown-method.objc", "punctuation.separator.arguments.objc"],
+ regex: "\\b(\\w+)(:)"
+ },
+ {
+ regex: "\\b(?:ALL|ANY|SOME|NONE)\\b",
+ token: "constant.language.predicate.cocoa"
+ },
+ {
+ regex: "\\b(?:NULL|NIL|SELF|TRUE|YES|FALSE|NO|FIRST|LAST|SIZE)\\b",
+ token: "constant.language.predicate.cocoa"
+ },
+ {
+ regex: "\\b(?:MATCHES|CONTAINS|BEGINSWITH|ENDSWITH|BETWEEN)\\b",
+ token: "keyword.operator.comparison.predicate.cocoa"
+ },
+ {
+ regex: "\\bC(?:ASEINSENSITIVE|I)\\b",
+ token: "keyword.other.modifier.predicate.cocoa"
+ },
+ {
+ regex: "\\b(?:ANYKEY|SUBQUERY|CAST|TRUEPREDICATE|FALSEPREDICATE)\\b",
+ token: "keyword.other.predicate.cocoa"
+ },
+ {
+ regex: escapedConstRe,
+ token: "constant.character.escape.objc"
+ },
+ {
+ regex: "\\\\.",
+ token: "invalid.illegal.unknown-escape.objc"
+ },
+ {
+ token: "string",
+ regex: '[^"\\\\]'
+ },
+ {
+ token: "punctuation.definition.string.end.objc",
+ regex: "\"",
+ next: "predicates"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : ".*?\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "methods" : [
+ {
+ token : "meta.function.objc",
+ regex : "(?=\\{|#)|;",
+ next : "start"
+ }
+ ]
+}
+ for (var r in cRules) {
+ if (this.$rules[r]) {
+ if (this.$rules[r].push)
+ this.$rules[r].push.apply(this.$rules[r], cRules[r]);
+ } else {
+ this.$rules[r] = cRules[r];
+ }
+ }
+
+ this.$rules.bracketed_content = this.$rules.bracketed_content.concat(
+ this.$rules.start, specialVariables
+ );
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(ObjectiveCHighlightRules, CHighlightRules);
+
+exports.ObjectiveCHighlightRules = ObjectiveCHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/objectivec",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/objectivec_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ObjectiveCHighlightRules = require("./objectivec_highlight_rules").ObjectiveCHighlightRules;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ObjectiveCHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/objectivec";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-ocaml.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-ocaml.js
new file mode 100644
index 00000000..29f26cc4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-ocaml.js
@@ -0,0 +1,414 @@
+ace.define("ace/mode/ocaml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var OcamlHighlightRules = function() {
+
+ var keywords = (
+ "and|as|assert|begin|class|constraint|do|done|downto|else|end|" +
+ "exception|external|for|fun|function|functor|if|in|include|" +
+ "inherit|initializer|lazy|let|match|method|module|mutable|new|" +
+ "object|of|open|or|private|rec|sig|struct|then|to|try|type|val|" +
+ "virtual|when|while|with"
+ );
+
+ var builtinConstants = ("true|false");
+
+ var builtinFunctions = (
+ "abs|abs_big_int|abs_float|abs_num|abstract_tag|accept|access|acos|add|" +
+ "add_available_units|add_big_int|add_buffer|add_channel|add_char|" +
+ "add_initializer|add_int_big_int|add_interfaces|add_num|add_string|" +
+ "add_substitute|add_substring|alarm|allocated_bytes|allow_only|" +
+ "allow_unsafe_modules|always|append|appname_get|appname_set|" +
+ "approx_num_exp|approx_num_fix|arg|argv|arith_status|array|" +
+ "array1_of_genarray|array2_of_genarray|array3_of_genarray|asin|asr|" +
+ "assoc|assq|at_exit|atan|atan2|auto_synchronize|background|basename|" +
+ "beginning_of_input|big_int_of_int|big_int_of_num|big_int_of_string|bind|" +
+ "bind_class|bind_tag|bits|bits_of_float|black|blit|blit_image|blue|bool|" +
+ "bool_of_string|bounded_full_split|bounded_split|bounded_split_delim|" +
+ "bprintf|break|broadcast|bscanf|button_down|c_layout|capitalize|cardinal|" +
+ "cardinal|catch|catch_break|ceil|ceiling_num|channel|char|char_of_int|" +
+ "chdir|check|check_suffix|chmod|choose|chop_extension|chop_suffix|chown|" +
+ "chown|chr|chroot|classify_float|clear|clear_available_units|" +
+ "clear_close_on_exec|clear_graph|clear_nonblock|clear_parser|" +
+ "close|close|closeTk|close_box|close_graph|close_in|close_in_noerr|" +
+ "close_out|close_out_noerr|close_process|close_process|" +
+ "close_process_full|close_process_in|close_process_out|close_subwindow|" +
+ "close_tag|close_tbox|closedir|closedir|closure_tag|code|combine|" +
+ "combine|combine|command|compact|compare|compare_big_int|compare_num|" +
+ "complex32|complex64|concat|conj|connect|contains|contains_from|contents|" +
+ "copy|cos|cosh|count|count|counters|create|create_alarm|create_image|" +
+ "create_matrix|create_matrix|create_matrix|create_object|" +
+ "create_object_and_run_initializers|create_object_opt|create_process|" +
+ "create_process|create_process_env|create_process_env|create_table|" +
+ "current|current_dir_name|current_point|current_x|current_y|curveto|" +
+ "custom_tag|cyan|data_size|decr|decr_num|default_available_units|delay|" +
+ "delete_alarm|descr_of_in_channel|descr_of_out_channel|destroy|diff|dim|" +
+ "dim1|dim2|dim3|dims|dirname|display_mode|div|div_big_int|div_num|" +
+ "double_array_tag|double_tag|draw_arc|draw_char|draw_circle|draw_ellipse|" +
+ "draw_image|draw_poly|draw_poly_line|draw_rect|draw_segments|draw_string|" +
+ "dummy_pos|dummy_table|dump_image|dup|dup2|elements|empty|end_of_input|" +
+ "environment|eprintf|epsilon_float|eq_big_int|eq_num|equal|err_formatter|" +
+ "error_message|escaped|establish_server|executable_name|execv|execve|execvp|" +
+ "execvpe|exists|exists2|exit|exp|failwith|fast_sort|fchmod|fchown|field|" +
+ "file|file_exists|fill|fill_arc|fill_circle|fill_ellipse|fill_poly|fill_rect|" +
+ "filter|final_tag|finalise|find|find_all|first_chars|firstkey|flatten|" +
+ "float|float32|float64|float_of_big_int|float_of_bits|float_of_int|" +
+ "float_of_num|float_of_string|floor|floor_num|flush|flush_all|flush_input|" +
+ "flush_str_formatter|fold|fold_left|fold_left2|fold_right|fold_right2|" +
+ "for_all|for_all2|force|force_newline|force_val|foreground|fork|" +
+ "format_of_string|formatter_of_buffer|formatter_of_out_channel|" +
+ "fortran_layout|forward_tag|fprintf|frexp|from|from_channel|from_file|" +
+ "from_file_bin|from_function|from_string|fscanf|fst|fstat|ftruncate|" +
+ "full_init|full_major|full_split|gcd_big_int|ge_big_int|ge_num|" +
+ "genarray_of_array1|genarray_of_array2|genarray_of_array3|get|" +
+ "get_all_formatter_output_functions|get_approx_printing|get_copy|" +
+ "get_ellipsis_text|get_error_when_null_denominator|get_floating_precision|" +
+ "get_formatter_output_functions|get_formatter_tag_functions|get_image|" +
+ "get_margin|get_mark_tags|get_max_boxes|get_max_indent|get_method|" +
+ "get_method_label|get_normalize_ratio|get_normalize_ratio_when_printing|" +
+ "get_print_tags|get_state|get_variable|getcwd|getegid|getegid|getenv|" +
+ "getenv|getenv|geteuid|geteuid|getgid|getgid|getgrgid|getgrgid|getgrnam|" +
+ "getgrnam|getgroups|gethostbyaddr|gethostbyname|gethostname|getitimer|" +
+ "getlogin|getpeername|getpid|getppid|getprotobyname|getprotobynumber|" +
+ "getpwnam|getpwuid|getservbyname|getservbyport|getsockname|getsockopt|" +
+ "getsockopt_float|getsockopt_int|getsockopt_optint|gettimeofday|getuid|" +
+ "global_replace|global_substitute|gmtime|green|grid|group_beginning|" +
+ "group_end|gt_big_int|gt_num|guard|handle_unix_error|hash|hash_param|" +
+ "hd|header_size|i|id|ignore|in_channel_length|in_channel_of_descr|incr|" +
+ "incr_num|index|index_from|inet_addr_any|inet_addr_of_string|infinity|" +
+ "infix_tag|init|init_class|input|input_binary_int|input_byte|input_char|" +
+ "input_line|input_value|int|int16_signed|int16_unsigned|int32|int64|" +
+ "int8_signed|int8_unsigned|int_of_big_int|int_of_char|int_of_float|" +
+ "int_of_num|int_of_string|integer_num|inter|interactive|inv|invalid_arg|" +
+ "is_block|is_empty|is_implicit|is_int|is_int_big_int|is_integer_num|" +
+ "is_relative|iter|iter2|iteri|join|junk|key_pressed|kill|kind|kprintf|" +
+ "kscanf|land|last_chars|layout|lazy_from_fun|lazy_from_val|lazy_is_val|" +
+ "lazy_tag|ldexp|le_big_int|le_num|length|lexeme|lexeme_char|lexeme_end|" +
+ "lexeme_end_p|lexeme_start|lexeme_start_p|lineto|link|list|listen|lnot|" +
+ "loadfile|loadfile_private|localtime|lock|lockf|log|log10|logand|lognot|" +
+ "logor|logxor|lor|lower_window|lowercase|lseek|lsl|lsr|lstat|lt_big_int|" +
+ "lt_num|lxor|magenta|magic|mainLoop|major|major_slice|make|make_formatter|" +
+ "make_image|make_lexer|make_matrix|make_self_init|map|map2|map_file|mapi|" +
+ "marshal|match_beginning|match_end|matched_group|matched_string|max|" +
+ "max_array_length|max_big_int|max_elt|max_float|max_int|max_num|" +
+ "max_string_length|mem|mem_assoc|mem_assq|memq|merge|min|min_big_int|" +
+ "min_elt|min_float|min_int|min_num|minor|minus_big_int|minus_num|" +
+ "minus_one|mkdir|mkfifo|mktime|mod|mod_big_int|mod_float|mod_num|modf|" +
+ "mouse_pos|moveto|mul|mult_big_int|mult_int_big_int|mult_num|nan|narrow|" +
+ "nat_of_num|nativeint|neg|neg_infinity|new_block|new_channel|new_method|" +
+ "new_variable|next|nextkey|nice|nice|no_scan_tag|norm|norm2|not|npeek|" +
+ "nth|nth_dim|num_digits_big_int|num_dims|num_of_big_int|num_of_int|" +
+ "num_of_nat|num_of_ratio|num_of_string|O|obj|object_tag|ocaml_version|" +
+ "of_array|of_channel|of_float|of_int|of_int32|of_list|of_nativeint|" +
+ "of_string|one|openTk|open_box|open_connection|open_graph|open_hbox|" +
+ "open_hovbox|open_hvbox|open_in|open_in_bin|open_in_gen|open_out|" +
+ "open_out_bin|open_out_gen|open_process|open_process_full|open_process_in|" +
+ "open_process_out|open_subwindow|open_tag|open_tbox|open_temp_file|" +
+ "open_vbox|opendbm|opendir|openfile|or|os_type|out_channel_length|" +
+ "out_channel_of_descr|output|output_binary_int|output_buffer|output_byte|" +
+ "output_char|output_string|output_value|over_max_boxes|pack|params|" +
+ "parent_dir_name|parse|parse_argv|partition|pause|peek|pipe|pixels|" +
+ "place|plot|plots|point_color|polar|poll|pop|pos_in|pos_out|pow|" +
+ "power_big_int_positive_big_int|power_big_int_positive_int|" +
+ "power_int_positive_big_int|power_int_positive_int|power_num|" +
+ "pp_close_box|pp_close_tag|pp_close_tbox|pp_force_newline|" +
+ "pp_get_all_formatter_output_functions|pp_get_ellipsis_text|" +
+ "pp_get_formatter_output_functions|pp_get_formatter_tag_functions|" +
+ "pp_get_margin|pp_get_mark_tags|pp_get_max_boxes|pp_get_max_indent|" +
+ "pp_get_print_tags|pp_open_box|pp_open_hbox|pp_open_hovbox|pp_open_hvbox|" +
+ "pp_open_tag|pp_open_tbox|pp_open_vbox|pp_over_max_boxes|pp_print_as|" +
+ "pp_print_bool|pp_print_break|pp_print_char|pp_print_cut|pp_print_float|" +
+ "pp_print_flush|pp_print_if_newline|pp_print_int|pp_print_newline|" +
+ "pp_print_space|pp_print_string|pp_print_tab|pp_print_tbreak|" +
+ "pp_set_all_formatter_output_functions|pp_set_ellipsis_text|" +
+ "pp_set_formatter_out_channel|pp_set_formatter_output_functions|" +
+ "pp_set_formatter_tag_functions|pp_set_margin|pp_set_mark_tags|" +
+ "pp_set_max_boxes|pp_set_max_indent|pp_set_print_tags|pp_set_tab|" +
+ "pp_set_tags|pred|pred_big_int|pred_num|prerr_char|prerr_endline|" +
+ "prerr_float|prerr_int|prerr_newline|prerr_string|print|print_as|" +
+ "print_bool|print_break|print_char|print_cut|print_endline|print_float|" +
+ "print_flush|print_if_newline|print_int|print_newline|print_space|" +
+ "print_stat|print_string|print_tab|print_tbreak|printf|prohibit|" +
+ "public_method_label|push|putenv|quo_num|quomod_big_int|quote|raise|" +
+ "raise_window|ratio_of_num|rcontains_from|read|read_float|read_int|" +
+ "read_key|read_line|readdir|readdir|readlink|really_input|receive|recv|" +
+ "recvfrom|red|ref|regexp|regexp_case_fold|regexp_string|" +
+ "regexp_string_case_fold|register|register_exception|rem|remember_mode|" +
+ "remove|remove_assoc|remove_assq|rename|replace|replace_first|" +
+ "replace_matched|repr|reset|reshape|reshape_1|reshape_2|reshape_3|rev|" +
+ "rev_append|rev_map|rev_map2|rewinddir|rgb|rhs_end|rhs_end_pos|rhs_start|" +
+ "rhs_start_pos|rindex|rindex_from|rlineto|rmdir|rmoveto|round_num|" +
+ "run_initializers|run_initializers_opt|scanf|search_backward|" +
+ "search_forward|seek_in|seek_out|select|self|self_init|send|sendto|set|" +
+ "set_all_formatter_output_functions|set_approx_printing|" +
+ "set_binary_mode_in|set_binary_mode_out|set_close_on_exec|" +
+ "set_close_on_exec|set_color|set_ellipsis_text|" +
+ "set_error_when_null_denominator|set_field|set_floating_precision|" +
+ "set_font|set_formatter_out_channel|set_formatter_output_functions|" +
+ "set_formatter_tag_functions|set_line_width|set_margin|set_mark_tags|" +
+ "set_max_boxes|set_max_indent|set_method|set_nonblock|set_nonblock|" +
+ "set_normalize_ratio|set_normalize_ratio_when_printing|set_print_tags|" +
+ "set_signal|set_state|set_tab|set_tag|set_tags|set_text_size|" +
+ "set_window_title|setgid|setgid|setitimer|setitimer|setsid|setsid|" +
+ "setsockopt|setsockopt|setsockopt_float|setsockopt_float|setsockopt_int|" +
+ "setsockopt_int|setsockopt_optint|setsockopt_optint|setuid|setuid|" +
+ "shift_left|shift_left|shift_left|shift_right|shift_right|shift_right|" +
+ "shift_right_logical|shift_right_logical|shift_right_logical|show_buckets|" +
+ "shutdown|shutdown|shutdown_connection|shutdown_connection|sigabrt|" +
+ "sigalrm|sigchld|sigcont|sigfpe|sighup|sigill|sigint|sigkill|sign_big_int|" +
+ "sign_num|signal|signal|sigpending|sigpending|sigpipe|sigprocmask|" +
+ "sigprocmask|sigprof|sigquit|sigsegv|sigstop|sigsuspend|sigsuspend|" +
+ "sigterm|sigtstp|sigttin|sigttou|sigusr1|sigusr2|sigvtalrm|sin|singleton|" +
+ "sinh|size|size|size_x|size_y|sleep|sleep|sleep|slice_left|slice_left|" +
+ "slice_left_1|slice_left_2|slice_right|slice_right|slice_right_1|" +
+ "slice_right_2|snd|socket|socket|socket|socketpair|socketpair|sort|sound|" +
+ "split|split_delim|sprintf|sprintf|sqrt|sqrt|sqrt_big_int|square_big_int|" +
+ "square_num|sscanf|stable_sort|stable_sort|stable_sort|stable_sort|stable_sort|" +
+ "stable_sort|stat|stat|stat|stat|stat|stats|stats|std_formatter|stdbuf|" +
+ "stderr|stderr|stderr|stdib|stdin|stdin|stdin|stdout|stdout|stdout|" +
+ "str_formatter|string|string_after|string_before|string_match|" +
+ "string_of_big_int|string_of_bool|string_of_float|string_of_format|" +
+ "string_of_inet_addr|string_of_inet_addr|string_of_int|string_of_num|" +
+ "string_partial_match|string_tag|sub|sub|sub_big_int|sub_left|sub_num|" +
+ "sub_right|subset|subset|substitute_first|substring|succ|succ|" +
+ "succ|succ|succ_big_int|succ_num|symbol_end|symbol_end_pos|symbol_start|" +
+ "symbol_start_pos|symlink|symlink|sync|synchronize|system|system|system|" +
+ "tag|take|tan|tanh|tcdrain|tcdrain|tcflow|tcflow|tcflush|tcflush|" +
+ "tcgetattr|tcgetattr|tcsendbreak|tcsendbreak|tcsetattr|tcsetattr|" +
+ "temp_file|text_size|time|time|time|timed_read|timed_write|times|times|" +
+ "tl|tl|tl|to_buffer|to_channel|to_float|to_hex|to_int|to_int32|to_list|" +
+ "to_list|to_list|to_nativeint|to_string|to_string|to_string|to_string|" +
+ "to_string|top|top|total_size|transfer|transp|truncate|truncate|truncate|" +
+ "truncate|truncate|truncate|try_lock|umask|umask|uncapitalize|uncapitalize|" +
+ "uncapitalize|union|union|unit_big_int|unlink|unlink|unlock|unmarshal|" +
+ "unsafe_blit|unsafe_fill|unsafe_get|unsafe_get|unsafe_set|unsafe_set|" +
+ "update|uppercase|uppercase|uppercase|uppercase|usage|utimes|utimes|wait|" +
+ "wait|wait|wait|wait_next_event|wait_pid|wait_read|wait_signal|" +
+ "wait_timed_read|wait_timed_write|wait_write|waitpid|white|" +
+ "widen|window_id|word_size|wrap|wrap_abort|write|yellow|yield|zero|zero_big_int|" +
+
+ "Arg|Arith_status|Array|Array1|Array2|Array3|ArrayLabels|Big_int|Bigarray|" +
+ "Buffer|Callback|CamlinternalOO|Char|Complex|Condition|Dbm|Digest|Dynlink|" +
+ "Event|Filename|Format|Gc|Genarray|Genlex|Graphics|GraphicsX11|Hashtbl|" +
+ "Int32|Int64|LargeFile|Lazy|Lexing|List|ListLabels|Make|Map|Marshal|" +
+ "MoreLabels|Mutex|Nativeint|Num|Obj|Oo|Parsing|Pervasives|Printexc|" +
+ "Printf|Queue|Random|Scanf|Scanning|Set|Sort|Stack|State|StdLabels|Str|" +
+ "Stream|String|StringLabels|Sys|Thread|ThreadUnix|Tk|Unix|UnixLabels|Weak"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": builtinConstants,
+ "support.function": builtinFunctions
+ }, "identifier");
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var octInteger = "(?:0[oO]?[0-7]+)";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var binInteger = "(?:0[bB][01]+)";
+ var integer = "(?:" + decimalInteger + "|" + octInteger + "|" + hexInteger + "|" + binInteger + ")";
+
+ var exponent = "(?:[eE][+-]?\\d+)";
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + exponent + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : '\\(\\*.*?\\*\\)\\s*?$'
+ },
+ {
+ token : "comment",
+ regex : '\\(\\*.*',
+ next : "comment"
+ },
+ {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ },
+ {
+ token : "string", // single char
+ regex : "'.'"
+ },
+ {
+ token : "string", // " string
+ regex : '"',
+ next : "qstring"
+ },
+ {
+ token : "constant.numeric", // imaginary
+ regex : "(?:" + floatNumber + "|\\d+)[jJ]\\b"
+ },
+ {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ },
+ {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ },
+ {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ },
+ {
+ token : "keyword.operator",
+ regex : "\\+\\.|\\-\\.|\\*\\.|\\/\\.|#|;;|\\+|\\-|\\*|\\*\\*\\/|\\/\\/|%|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|<-|="
+ },
+ {
+ token : "paren.lparen",
+ regex : "[[({]"
+ },
+ {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ },
+ {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\)",
+ next : "start"
+ },
+ {
+ defaultToken : "comment"
+ }
+ ],
+
+ "qstring" : [
+ {
+ token : "string",
+ regex : '"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+};
+
+oop.inherits(OcamlHighlightRules, TextHighlightRules);
+
+exports.OcamlHighlightRules = OcamlHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/ocaml",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ocaml_highlight_rules","ace/mode/matching_brace_outdent","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var OcamlHighlightRules = require("./ocaml_highlight_rules").OcamlHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = OcamlHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+
+ this.$outdent = new MatchingBraceOutdent();
+};
+oop.inherits(Mode, TextMode);
+
+var indenter = /(?:[({[=:]|[-=]>|\b(?:else|try|with))\s*$/;
+
+(function() {
+
+ this.toggleCommentLines = function(state, doc, startRow, endRow) {
+ var i, line;
+ var outdent = true;
+ var re = /^\s*\(\*(.*)\*\)/;
+
+ for (i=startRow; i<= endRow; i++) {
+ if (!re.test(doc.getLine(i))) {
+ outdent = false;
+ break;
+ }
+ }
+
+ var range = new Range(0, 0, 0, 0);
+ for (i=startRow; i<= endRow; i++) {
+ line = doc.getLine(i);
+ range.start.row = i;
+ range.end.row = i;
+ range.end.column = line.length;
+
+ doc.replace(range, outdent ? line.match(re)[1] : "(*" + line + "*)");
+ }
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+
+ if (!(tokens.length && tokens[tokens.length - 1].type === 'comment') &&
+ state === 'start' && indenter.test(line))
+ indent += tab;
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/ocaml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-pascal.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-pascal.js
new file mode 100644
index 00000000..9ccd1ed5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-pascal.js
@@ -0,0 +1,198 @@
+ace.define("ace/mode/pascal_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PascalHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { caseInsensitive: true,
+ token: 'keyword.control.pascal',
+ regex: '\\b(?:(absolute|abstract|all|and|and_then|array|as|asm|attribute|begin|bindable|case|class|const|constructor|destructor|div|do|do|else|end|except|export|exports|external|far|file|finalization|finally|for|forward|goto|if|implementation|import|in|inherited|initialization|interface|interrupt|is|label|library|mod|module|name|near|nil|not|object|of|only|operator|or|or_else|otherwise|packed|pow|private|program|property|protected|public|published|qualified|record|repeat|resident|restricted|segment|set|shl|shr|then|to|try|type|unit|until|uses|value|var|view|virtual|while|with|xor))\\b' },
+ { caseInsensitive: true,
+ token:
+ [ 'variable.pascal', "text",
+ 'storage.type.prototype.pascal',
+ 'entity.name.function.prototype.pascal' ],
+ regex: '\\b(function|procedure)(\\s+)(\\w+)(\\.\\w+)?(?=(?:\\(.*?\\))?;\\s*(?:attribute|forward|external))' },
+ { caseInsensitive: true,
+ token:
+ [ 'variable.pascal', "text",
+ 'storage.type.function.pascal',
+ 'entity.name.function.pascal' ],
+ regex: '\\b(function|procedure)(\\s+)(\\w+)(\\.\\w+)?' },
+ { token: 'constant.numeric.pascal',
+ regex: '\\b((0(x|X)[0-9a-fA-F]*)|(([0-9]+\\.?[0-9]*)|(\\.[0-9]+))((e|E)(\\+|-)?[0-9]+)?)(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b' },
+ { token: 'punctuation.definition.comment.pascal',
+ regex: '--.*$',
+ push_:
+ [ { token: 'comment.line.double-dash.pascal.one',
+ regex: '$',
+ next: 'pop' },
+ { defaultToken: 'comment.line.double-dash.pascal.one' } ] },
+ { token: 'punctuation.definition.comment.pascal',
+ regex: '//.*$',
+ push_:
+ [ { token: 'comment.line.double-slash.pascal.two',
+ regex: '$',
+ next: 'pop' },
+ { defaultToken: 'comment.line.double-slash.pascal.two' } ] },
+ { token: 'punctuation.definition.comment.pascal',
+ regex: '\\(\\*',
+ push:
+ [ { token: 'punctuation.definition.comment.pascal',
+ regex: '\\*\\)',
+ next: 'pop' },
+ { defaultToken: 'comment.block.pascal.one' } ] },
+ { token: 'punctuation.definition.comment.pascal',
+ regex: '\\{',
+ push:
+ [ { token: 'punctuation.definition.comment.pascal',
+ regex: '\\}',
+ next: 'pop' },
+ { defaultToken: 'comment.block.pascal.two' } ] },
+ { token: 'punctuation.definition.string.begin.pascal',
+ regex: '"',
+ push:
+ [ { token: 'constant.character.escape.pascal', regex: '\\\\.' },
+ { token: 'punctuation.definition.string.end.pascal',
+ regex: '"',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.double.pascal' } ]
+ },
+ { token: 'punctuation.definition.string.begin.pascal',
+ regex: '\'',
+ push:
+ [ { token: 'constant.character.escape.apostrophe.pascal',
+ regex: '\'\'' },
+ { token: 'punctuation.definition.string.end.pascal',
+ regex: '\'',
+ next: 'pop' },
+ { defaultToken: 'string.quoted.single.pascal' } ] },
+ { token: 'keyword.operator',
+ regex: '[+\\-;,/*%]|:=|=' } ] }
+
+ this.normalizeRules();
+};
+
+oop.inherits(PascalHighlightRules, TextHighlightRules);
+
+exports.PascalHighlightRules = PascalHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/pascal",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/pascal_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PascalHighlightRules = require("./pascal_highlight_rules").PascalHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = PascalHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ["--", "//"];
+ this.blockComment = [
+ {start: "(*", end: "*)"},
+ {start: "{", end: "}"}
+ ];
+
+ this.$id = "ace/mode/pascal";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-perl.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-perl.js
new file mode 100644
index 00000000..768c5383
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-perl.js
@@ -0,0 +1,373 @@
+ace.define("ace/mode/perl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PerlHighlightRules = function() {
+
+ var keywords = (
+ "base|constant|continue|else|elsif|for|foreach|format|goto|if|last|local|my|next|" +
+ "no|package|parent|redo|require|scalar|sub|unless|until|while|use|vars"
+ );
+
+ var buildinConstants = ("ARGV|ENV|INC|SIG");
+
+ var builtinFunctions = (
+ "getprotobynumber|getprotobyname|getservbyname|gethostbyaddr|" +
+ "gethostbyname|getservbyport|getnetbyaddr|getnetbyname|getsockname|" +
+ "getpeername|setpriority|getprotoent|setprotoent|getpriority|" +
+ "endprotoent|getservent|setservent|endservent|sethostent|socketpair|" +
+ "getsockopt|gethostent|endhostent|setsockopt|setnetent|quotemeta|" +
+ "localtime|prototype|getnetent|endnetent|rewinddir|wantarray|getpwuid|" +
+ "closedir|getlogin|readlink|endgrent|getgrgid|getgrnam|shmwrite|" +
+ "shutdown|readline|endpwent|setgrent|readpipe|formline|truncate|" +
+ "dbmclose|syswrite|setpwent|getpwnam|getgrent|getpwent|ucfirst|sysread|" +
+ "setpgrp|shmread|sysseek|sysopen|telldir|defined|opendir|connect|" +
+ "lcfirst|getppid|binmode|syscall|sprintf|getpgrp|readdir|seekdir|" +
+ "waitpid|reverse|unshift|symlink|dbmopen|semget|msgrcv|rename|listen|" +
+ "chroot|msgsnd|shmctl|accept|unpack|exists|fileno|shmget|system|" +
+ "unlink|printf|gmtime|msgctl|semctl|values|rindex|substr|splice|" +
+ "length|msgget|select|socket|return|caller|delete|alarm|ioctl|index|" +
+ "undef|lstat|times|srand|chown|fcntl|close|write|umask|rmdir|study|" +
+ "sleep|chomp|untie|print|utime|mkdir|atan2|split|crypt|flock|chmod|" +
+ "BEGIN|bless|chdir|semop|shift|reset|link|stat|chop|grep|fork|dump|" +
+ "join|open|tell|pipe|exit|glob|warn|each|bind|sort|pack|eval|push|" +
+ "keys|getc|kill|seek|sqrt|send|wait|rand|tied|read|time|exec|recv|" +
+ "eof|chr|int|ord|exp|pos|pop|sin|log|abs|oct|hex|tie|cos|vec|END|ref|" +
+ "map|die|uc|lc|do"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": builtinFunctions
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment.doc",
+ regex : "^=(?:begin|item)\\b",
+ next : "block_comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : '["].*\\\\$',
+ next : "qqstring"
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "string", // multi line string start
+ regex : "['].*\\\\$",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0x[0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "%#|\\$#|\\.\\.\\.|\\|\\|=|>>=|<<=|<=>|&&=|=>|!~|\\^=|&=|\\|=|\\.=|x=|%=|\\/=|\\*=|\\-=|\\+=|=~|\\*\\*|\\-\\-|\\.\\.|\\|\\||&&|\\+\\+|\\->|!=|==|>=|<=|>>|<<|,|=|\\?\\:|\\^|\\||x|%|\\/|\\*|<|&|\\\\|~|!|>|\\.|\\-|\\+|\\-C|\\-b|\\-S|\\-u|\\-t|\\-p|\\-l|\\-d|\\-f|\\-g|\\-s|\\-z|\\-k|\\-e|\\-O|\\-T|\\-B|\\-M|\\-A|\\-X|\\-W|\\-c|\\-R|\\-o|\\-x|\\-w|\\-r|\\b(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|xor)"
+ }, {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "block_comment": [
+ {
+ token: "comment.doc",
+ regex: "^=cut\\b",
+ next: "start"
+ },
+ {
+ defaultToken: "comment.doc"
+ }
+ ]
+ };
+};
+
+oop.inherits(PerlHighlightRules, TextHighlightRules);
+
+exports.PerlHighlightRules = PerlHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/perl",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/perl_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PerlHighlightRules = require("./perl_highlight_rules").PerlHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = PerlHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new CStyleFoldMode({start: "^=(begin|item)\\b", end: "^=(cut)\\b"});
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+ this.blockComment = [
+ {start: "=begin", end: "=cut", lineStartOnly: true},
+ {start: "=item", end: "=cut", lineStartOnly: true}
+ ];
+
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/perl";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-pgsql.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-pgsql.js
new file mode 100644
index 00000000..189f17a5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-pgsql.js
@@ -0,0 +1,1500 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/perl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PerlHighlightRules = function() {
+
+ var keywords = (
+ "base|constant|continue|else|elsif|for|foreach|format|goto|if|last|local|my|next|" +
+ "no|package|parent|redo|require|scalar|sub|unless|until|while|use|vars"
+ );
+
+ var buildinConstants = ("ARGV|ENV|INC|SIG");
+
+ var builtinFunctions = (
+ "getprotobynumber|getprotobyname|getservbyname|gethostbyaddr|" +
+ "gethostbyname|getservbyport|getnetbyaddr|getnetbyname|getsockname|" +
+ "getpeername|setpriority|getprotoent|setprotoent|getpriority|" +
+ "endprotoent|getservent|setservent|endservent|sethostent|socketpair|" +
+ "getsockopt|gethostent|endhostent|setsockopt|setnetent|quotemeta|" +
+ "localtime|prototype|getnetent|endnetent|rewinddir|wantarray|getpwuid|" +
+ "closedir|getlogin|readlink|endgrent|getgrgid|getgrnam|shmwrite|" +
+ "shutdown|readline|endpwent|setgrent|readpipe|formline|truncate|" +
+ "dbmclose|syswrite|setpwent|getpwnam|getgrent|getpwent|ucfirst|sysread|" +
+ "setpgrp|shmread|sysseek|sysopen|telldir|defined|opendir|connect|" +
+ "lcfirst|getppid|binmode|syscall|sprintf|getpgrp|readdir|seekdir|" +
+ "waitpid|reverse|unshift|symlink|dbmopen|semget|msgrcv|rename|listen|" +
+ "chroot|msgsnd|shmctl|accept|unpack|exists|fileno|shmget|system|" +
+ "unlink|printf|gmtime|msgctl|semctl|values|rindex|substr|splice|" +
+ "length|msgget|select|socket|return|caller|delete|alarm|ioctl|index|" +
+ "undef|lstat|times|srand|chown|fcntl|close|write|umask|rmdir|study|" +
+ "sleep|chomp|untie|print|utime|mkdir|atan2|split|crypt|flock|chmod|" +
+ "BEGIN|bless|chdir|semop|shift|reset|link|stat|chop|grep|fork|dump|" +
+ "join|open|tell|pipe|exit|glob|warn|each|bind|sort|pack|eval|push|" +
+ "keys|getc|kill|seek|sqrt|send|wait|rand|tied|read|time|exec|recv|" +
+ "eof|chr|int|ord|exp|pos|pop|sin|log|abs|oct|hex|tie|cos|vec|END|ref|" +
+ "map|die|uc|lc|do"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": builtinFunctions
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment.doc",
+ regex : "^=(?:begin|item)\\b",
+ next : "block_comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : '["].*\\\\$',
+ next : "qqstring"
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "string", // multi line string start
+ regex : "['].*\\\\$",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0x[0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "%#|\\$#|\\.\\.\\.|\\|\\|=|>>=|<<=|<=>|&&=|=>|!~|\\^=|&=|\\|=|\\.=|x=|%=|\\/=|\\*=|\\-=|\\+=|=~|\\*\\*|\\-\\-|\\.\\.|\\|\\||&&|\\+\\+|\\->|!=|==|>=|<=|>>|<<|,|=|\\?\\:|\\^|\\||x|%|\\/|\\*|<|&|\\\\|~|!|>|\\.|\\-|\\+|\\-C|\\-b|\\-S|\\-u|\\-t|\\-p|\\-l|\\-d|\\-f|\\-g|\\-s|\\-z|\\-k|\\-e|\\-O|\\-T|\\-B|\\-M|\\-A|\\-X|\\-W|\\-c|\\-R|\\-o|\\-x|\\-w|\\-r|\\b(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|xor)"
+ }, {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "block_comment": [
+ {
+ token: "comment.doc",
+ regex: "^=cut\\b",
+ next: "start"
+ },
+ {
+ defaultToken: "comment.doc"
+ }
+ ]
+ };
+};
+
+oop.inherits(PerlHighlightRules, TextHighlightRules);
+
+exports.PerlHighlightRules = PerlHighlightRules;
+});
+
+ace.define("ace/mode/python_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PythonHighlightRules = function() {
+
+ var keywords = (
+ "and|as|assert|break|class|continue|def|del|elif|else|except|exec|" +
+ "finally|for|from|global|if|import|in|is|lambda|not|or|pass|print|" +
+ "raise|return|try|while|with|yield"
+ );
+
+ var builtinConstants = (
+ "True|False|None|NotImplemented|Ellipsis|__debug__"
+ );
+
+ var builtinFunctions = (
+ "abs|divmod|input|open|staticmethod|all|enumerate|int|ord|str|any|" +
+ "eval|isinstance|pow|sum|basestring|execfile|issubclass|print|super|" +
+ "binfile|iter|property|tuple|bool|filter|len|range|type|bytearray|" +
+ "float|list|raw_input|unichr|callable|format|locals|reduce|unicode|" +
+ "chr|frozenset|long|reload|vars|classmethod|getattr|map|repr|xrange|" +
+ "cmp|globals|max|reversed|zip|compile|hasattr|memoryview|round|" +
+ "__import__|complex|hash|min|set|apply|delattr|help|next|setattr|" +
+ "buffer|dict|hex|object|slice|coerce|dir|id|oct|sorted|intern"
+ );
+ var keywordMapper = this.createKeywordMapper({
+ "invalid.deprecated": "debugger",
+ "support.function": builtinFunctions,
+ "constant.language": builtinConstants,
+ "keyword": keywords
+ }, "identifier");
+
+ var strPre = "(?:r|u|ur|R|U|UR|Ur|uR)?";
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var octInteger = "(?:0[oO]?[0-7]+)";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var binInteger = "(?:0[bB][01]+)";
+ var integer = "(?:" + decimalInteger + "|" + octInteger + "|" + hexInteger + "|" + binInteger + ")";
+
+ var exponent = "(?:[eE][+-]?\\d+)";
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + exponent + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+
+ var stringEscape = "\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'\"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})";
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "string", // multi line """ string start
+ regex : strPre + '"{3}',
+ next : "qqstring3"
+ }, {
+ token : "string", // " string
+ regex : strPre + '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "string", // multi line ''' string start
+ regex : strPre + "'{3}",
+ next : "qstring3"
+ }, {
+ token : "string", // ' string
+ regex : strPre + "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // imaginary
+ regex : "(?:" + floatNumber + "|\\d+)[jJ]\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // long integer
+ regex : integer + "[lL]\\b"
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|%|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ],
+ "qqstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line """ string end
+ regex : '"{3}',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ } ],
+ "qstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line ''' string end
+ regex : "'{3}",
+ next : "start"
+ }, {
+ defaultToken : "string"
+ } ],
+ "qqstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }],
+ "qstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }]
+ };
+};
+
+oop.inherits(PythonHighlightRules, TextHighlightRules);
+
+exports.PythonHighlightRules = PythonHighlightRules;
+});
+
+ace.define("ace/mode/json_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var JsonHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "variable", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]\\s*(?=:)'
+ }, {
+ token : "string", // single line
+ regex : '"',
+ next : "string"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : "text", // single quoted strings are not allowed
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "comment", // comments are not allowed, but who cares?
+ regex : "\\/\\/.*$"
+ }, {
+ token : "comment.start", // comments are not allowed, but who cares?
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "string" : [
+ {
+ token : "constant.language.escape",
+ regex : /\\(?:x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|["\\\/bfnrt])/
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment.end", // comments are not allowed, but who cares?
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ]
+ };
+
+};
+
+oop.inherits(JsonHighlightRules, TextHighlightRules);
+
+exports.JsonHighlightRules = JsonHighlightRules;
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/pgsql_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules","ace/mode/perl_highlight_rules","ace/mode/python_highlight_rules","ace/mode/json_highlight_rules","ace/mode/javascript_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var PerlHighlightRules = require("./perl_highlight_rules").PerlHighlightRules;
+var PythonHighlightRules = require("./python_highlight_rules").PythonHighlightRules;
+var JsonHighlightRules = require("./json_highlight_rules").JsonHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+
+var PgsqlHighlightRules = function() {
+ var keywords = (
+ "abort|absolute|abstime|access|aclitem|action|add|admin|after|aggregate|all|also|alter|always|" +
+ "analyse|analyze|and|any|anyarray|anyelement|anyenum|anynonarray|anyrange|array|as|asc|" +
+ "assertion|assignment|asymmetric|at|attribute|authorization|backward|before|begin|between|" +
+ "bigint|binary|bit|bool|boolean|both|box|bpchar|by|bytea|cache|called|cascade|cascaded|case|cast|" +
+ "catalog|chain|char|character|characteristics|check|checkpoint|cid|cidr|circle|class|close|" +
+ "cluster|coalesce|collate|collation|column|comment|comments|commit|committed|concurrently|" +
+ "configuration|connection|constraint|constraints|content|continue|conversion|copy|cost|" +
+ "create|cross|cstring|csv|current|current_catalog|current_date|current_role|" +
+ "current_schema|current_time|current_timestamp|current_user|cursor|cycle|data|database|" +
+ "date|daterange|day|deallocate|dec|decimal|declare|default|defaults|deferrable|deferred|" +
+ "definer|delete|delimiter|delimiters|desc|dictionary|disable|discard|distinct|do|document|" +
+ "domain|double|drop|each|else|enable|encoding|encrypted|end|enum|escape|event|event_trigger|" +
+ "except|exclude|excluding|exclusive|execute|exists|explain|extension|external|extract|false|" +
+ "family|fdw_handler|fetch|first|float|float4|float8|following|for|force|foreign|forward|" +
+ "freeze|from|full|function|functions|global|grant|granted|greatest|group|gtsvector|handler|" +
+ "having|header|hold|hour|identity|if|ilike|immediate|immutable|implicit|in|including|" +
+ "increment|index|indexes|inet|inherit|inherits|initially|inline|inner|inout|input|" +
+ "insensitive|insert|instead|int|int2|int2vector|int4|int4range|int8|int8range|integer|" +
+ "internal|intersect|interval|into|invoker|is|isnull|isolation|join|json|key|label|language|" +
+ "language_handler|large|last|lateral|lc_collate|lc_ctype|leading|leakproof|least|left|level|" +
+ "like|limit|line|listen|load|local|localtime|localtimestamp|location|lock|lseg|macaddr|" +
+ "mapping|match|materialized|maxvalue|minute|minvalue|mode|money|month|move|name|names|" +
+ "national|natural|nchar|next|no|none|not|nothing|notify|notnull|nowait|null|nullif|nulls|" +
+ "numeric|numrange|object|of|off|offset|oid|oids|oidvector|on|only|opaque|operator|option|" +
+ "options|or|order|out|outer|over|overlaps|overlay|owned|owner|parser|partial|partition|passing|" +
+ "password|path|pg_attribute|pg_auth_members|pg_authid|pg_class|pg_database|pg_node_tree|" +
+ "pg_proc|pg_type|placing|plans|point|polygon|position|preceding|precision|prepare|prepared|" +
+ "preserve|primary|prior|privileges|procedural|procedure|program|quote|range|read|real|" +
+ "reassign|recheck|record|recursive|ref|refcursor|references|refresh|regclass|regconfig|" +
+ "regdictionary|regoper|regoperator|regproc|regprocedure|regtype|reindex|relative|release|" +
+ "reltime|rename|repeatable|replace|replica|reset|restart|restrict|returning|returns|revoke|" +
+ "right|role|rollback|row|rows|rule|savepoint|schema|scroll|search|second|security|select|" +
+ "sequence|sequences|serializable|server|session|session_user|set|setof|share|show|similar|" +
+ "simple|smallint|smgr|snapshot|some|stable|standalone|start|statement|statistics|stdin|" +
+ "stdout|storage|strict|strip|substring|symmetric|sysid|system|table|tables|tablespace|temp|" +
+ "template|temporary|text|then|tid|time|timestamp|timestamptz|timetz|tinterval|to|trailing|" +
+ "transaction|treat|trigger|trim|true|truncate|trusted|tsquery|tsrange|tstzrange|tsvector|" +
+ "txid_snapshot|type|types|unbounded|uncommitted|unencrypted|union|unique|unknown|unlisten|" +
+ "unlogged|until|update|user|using|uuid|vacuum|valid|validate|validator|value|values|varbit|" +
+ "varchar|variadic|varying|verbose|version|view|void|volatile|when|where|whitespace|window|" +
+ "with|without|work|wrapper|write|xid|xml|xmlattributes|xmlconcat|xmlelement|xmlexists|" +
+ "xmlforest|xmlparse|xmlpi|xmlroot|xmlserialize|year|yes|zone"
+ );
+
+
+ var builtinFunctions = (
+ "RI_FKey_cascade_del|RI_FKey_cascade_upd|RI_FKey_check_ins|RI_FKey_check_upd|" +
+ "RI_FKey_noaction_del|RI_FKey_noaction_upd|RI_FKey_restrict_del|RI_FKey_restrict_upd|" +
+ "RI_FKey_setdefault_del|RI_FKey_setdefault_upd|RI_FKey_setnull_del|" +
+ "RI_FKey_setnull_upd|abbrev|abs|abstime|abstimeeq|abstimege|abstimegt|abstimein|abstimele|" +
+ "abstimelt|abstimene|abstimeout|abstimerecv|abstimesend|aclcontains|acldefault|" +
+ "aclexplode|aclinsert|aclitemeq|aclitemin|aclitemout|aclremove|acos|age|any_in|any_out|" +
+ "anyarray_in|anyarray_out|anyarray_recv|anyarray_send|anyelement_in|anyelement_out|" +
+ "anyenum_in|anyenum_out|anynonarray_in|anynonarray_out|anyrange_in|anyrange_out|" +
+ "anytextcat|area|areajoinsel|areasel|array_agg|array_agg_finalfn|array_agg_transfn|" +
+ "array_append|array_cat|array_dims|array_eq|array_fill|array_ge|array_gt|array_in|" +
+ "array_larger|array_le|array_length|array_lower|array_lt|array_ndims|array_ne|array_out|" +
+ "array_prepend|array_recv|array_remove|array_replace|array_send|array_smaller|" +
+ "array_to_json|array_to_string|array_typanalyze|array_upper|arraycontained|" +
+ "arraycontains|arraycontjoinsel|arraycontsel|arrayoverlap|ascii|ascii_to_mic|" +
+ "ascii_to_utf8|asin|atan|atan2|avg|big5_to_euc_tw|big5_to_mic|big5_to_utf8|bit_and|bit_in|" +
+ "bit_length|bit_or|bit_out|bit_recv|bit_send|bitand|bitcat|bitcmp|biteq|bitge|bitgt|bitle|" +
+ "bitlt|bitne|bitnot|bitor|bitshiftleft|bitshiftright|bittypmodin|bittypmodout|bitxor|bool|" +
+ "bool_and|bool_or|booland_statefunc|booleq|boolge|boolgt|boolin|boolle|boollt|boolne|" +
+ "boolor_statefunc|boolout|boolrecv|boolsend|box|box_above|box_above_eq|box_add|box_below|" +
+ "box_below_eq|box_center|box_contain|box_contain_pt|box_contained|box_distance|box_div|" +
+ "box_eq|box_ge|box_gt|box_in|box_intersect|box_le|box_left|box_lt|box_mul|box_out|" +
+ "box_overabove|box_overbelow|box_overlap|box_overleft|box_overright|box_recv|box_right|" +
+ "box_same|box_send|box_sub|bpchar_larger|bpchar_pattern_ge|bpchar_pattern_gt|" +
+ "bpchar_pattern_le|bpchar_pattern_lt|bpchar_smaller|bpcharcmp|bpchareq|bpcharge|" +
+ "bpchargt|bpchariclike|bpcharicnlike|bpcharicregexeq|bpcharicregexne|bpcharin|bpcharle|" +
+ "bpcharlike|bpcharlt|bpcharne|bpcharnlike|bpcharout|bpcharrecv|bpcharregexeq|" +
+ "bpcharregexne|bpcharsend|bpchartypmodin|bpchartypmodout|broadcast|btabstimecmp|" +
+ "btarraycmp|btbeginscan|btboolcmp|btbpchar_pattern_cmp|btbuild|btbuildempty|" +
+ "btbulkdelete|btcanreturn|btcharcmp|btcostestimate|btendscan|btfloat48cmp|btfloat4cmp|" +
+ "btfloat4sortsupport|btfloat84cmp|btfloat8cmp|btfloat8sortsupport|btgetbitmap|" +
+ "btgettuple|btinsert|btint24cmp|btint28cmp|btint2cmp|btint2sortsupport|btint42cmp|" +
+ "btint48cmp|btint4cmp|btint4sortsupport|btint82cmp|btint84cmp|btint8cmp|" +
+ "btint8sortsupport|btmarkpos|btnamecmp|btnamesortsupport|btoidcmp|btoidsortsupport|" +
+ "btoidvectorcmp|btoptions|btrecordcmp|btreltimecmp|btrescan|btrestrpos|btrim|" +
+ "bttext_pattern_cmp|bttextcmp|bttidcmp|bttintervalcmp|btvacuumcleanup|" +
+ "bytea_string_agg_finalfn|bytea_string_agg_transfn|byteacat|byteacmp|byteaeq|byteage|" +
+ "byteagt|byteain|byteale|bytealike|bytealt|byteane|byteanlike|byteaout|bytearecv|byteasend|" +
+ "cash_cmp|cash_div_cash|cash_div_flt4|cash_div_flt8|cash_div_int2|cash_div_int4|cash_eq|" +
+ "cash_ge|cash_gt|cash_in|cash_le|cash_lt|cash_mi|cash_mul_flt4|cash_mul_flt8|" +
+ "cash_mul_int2|cash_mul_int4|cash_ne|cash_out|cash_pl|cash_recv|cash_send|cash_words|" +
+ "cashlarger|cashsmaller|cbrt|ceil|ceiling|center|char|char_length|character_length|chareq|" +
+ "charge|chargt|charin|charle|charlt|charne|charout|charrecv|charsend|chr|cideq|cidin|cidout|" +
+ "cidr|cidr_in|cidr_out|cidr_recv|cidr_send|cidrecv|cidsend|circle|circle_above|" +
+ "circle_add_pt|circle_below|circle_center|circle_contain|circle_contain_pt|" +
+ "circle_contained|circle_distance|circle_div_pt|circle_eq|circle_ge|circle_gt|circle_in|" +
+ "circle_le|circle_left|circle_lt|circle_mul_pt|circle_ne|circle_out|circle_overabove|" +
+ "circle_overbelow|circle_overlap|circle_overleft|circle_overright|circle_recv|" +
+ "circle_right|circle_same|circle_send|circle_sub_pt|clock_timestamp|close_lb|close_ls|" +
+ "close_lseg|close_pb|close_pl|close_ps|close_sb|close_sl|col_description|concat|concat_ws|" +
+ "contjoinsel|contsel|convert|convert_from|convert_to|corr|cos|cot|count|covar_pop|" +
+ "covar_samp|cstring_in|cstring_out|cstring_recv|cstring_send|cume_dist|current_database|" +
+ "current_query|current_schema|current_schemas|current_setting|current_user|currtid|" +
+ "currtid2|currval|cursor_to_xml|cursor_to_xmlschema|database_to_xml|" +
+ "database_to_xml_and_xmlschema|database_to_xmlschema|date|date_cmp|date_cmp_timestamp|" +
+ "date_cmp_timestamptz|date_eq|date_eq_timestamp|date_eq_timestamptz|date_ge|" +
+ "date_ge_timestamp|date_ge_timestamptz|date_gt|date_gt_timestamp|date_gt_timestamptz|" +
+ "date_in|date_larger|date_le|date_le_timestamp|date_le_timestamptz|date_lt|" +
+ "date_lt_timestamp|date_lt_timestamptz|date_mi|date_mi_interval|date_mii|date_ne|" +
+ "date_ne_timestamp|date_ne_timestamptz|date_out|date_part|date_pl_interval|date_pli|" +
+ "date_recv|date_send|date_smaller|date_sortsupport|date_trunc|daterange|" +
+ "daterange_canonical|daterange_subdiff|datetime_pl|datetimetz_pl|dcbrt|decode|degrees|" +
+ "dense_rank|dexp|diagonal|diameter|dispell_init|dispell_lexize|dist_cpoly|dist_lb|dist_pb|" +
+ "dist_pc|dist_pl|dist_ppath|dist_ps|dist_sb|dist_sl|div|dlog1|dlog10|domain_in|domain_recv|" +
+ "dpow|dround|dsimple_init|dsimple_lexize|dsnowball_init|dsnowball_lexize|dsqrt|" +
+ "dsynonym_init|dsynonym_lexize|dtrunc|elem_contained_by_range|encode|enum_cmp|enum_eq|" +
+ "enum_first|enum_ge|enum_gt|enum_in|enum_larger|enum_last|enum_le|enum_lt|enum_ne|enum_out|" +
+ "enum_range|enum_recv|enum_send|enum_smaller|eqjoinsel|eqsel|euc_cn_to_mic|" +
+ "euc_cn_to_utf8|euc_jis_2004_to_shift_jis_2004|euc_jis_2004_to_utf8|euc_jp_to_mic|" +
+ "euc_jp_to_sjis|euc_jp_to_utf8|euc_kr_to_mic|euc_kr_to_utf8|euc_tw_to_big5|" +
+ "euc_tw_to_mic|euc_tw_to_utf8|event_trigger_in|event_trigger_out|every|exp|factorial|" +
+ "family|fdw_handler_in|fdw_handler_out|first_value|float4|float48div|float48eq|float48ge|" +
+ "float48gt|float48le|float48lt|float48mi|float48mul|float48ne|float48pl|float4_accum|" +
+ "float4abs|float4div|float4eq|float4ge|float4gt|float4in|float4larger|float4le|float4lt|" +
+ "float4mi|float4mul|float4ne|float4out|float4pl|float4recv|float4send|float4smaller|" +
+ "float4um|float4up|float8|float84div|float84eq|float84ge|float84gt|float84le|float84lt|" +
+ "float84mi|float84mul|float84ne|float84pl|float8_accum|float8_avg|float8_corr|" +
+ "float8_covar_pop|float8_covar_samp|float8_regr_accum|float8_regr_avgx|" +
+ "float8_regr_avgy|float8_regr_intercept|float8_regr_r2|float8_regr_slope|" +
+ "float8_regr_sxx|float8_regr_sxy|float8_regr_syy|float8_stddev_pop|float8_stddev_samp|" +
+ "float8_var_pop|float8_var_samp|float8abs|float8div|float8eq|float8ge|float8gt|float8in|" +
+ "float8larger|float8le|float8lt|float8mi|float8mul|float8ne|float8out|float8pl|float8recv|" +
+ "float8send|float8smaller|float8um|float8up|floor|flt4_mul_cash|flt8_mul_cash|" +
+ "fmgr_c_validator|fmgr_internal_validator|fmgr_sql_validator|format|format_type|" +
+ "gb18030_to_utf8|gbk_to_utf8|generate_series|generate_subscripts|get_bit|get_byte|" +
+ "get_current_ts_config|getdatabaseencoding|getpgusername|gin_cmp_prefix|" +
+ "gin_cmp_tslexeme|gin_extract_tsquery|gin_extract_tsvector|gin_tsquery_consistent|" +
+ "ginarrayconsistent|ginarrayextract|ginbeginscan|ginbuild|ginbuildempty|ginbulkdelete|" +
+ "gincostestimate|ginendscan|gingetbitmap|gininsert|ginmarkpos|ginoptions|" +
+ "ginqueryarrayextract|ginrescan|ginrestrpos|ginvacuumcleanup|gist_box_compress|" +
+ "gist_box_consistent|gist_box_decompress|gist_box_penalty|gist_box_picksplit|" +
+ "gist_box_same|gist_box_union|gist_circle_compress|gist_circle_consistent|" +
+ "gist_point_compress|gist_point_consistent|gist_point_distance|gist_poly_compress|" +
+ "gist_poly_consistent|gistbeginscan|gistbuild|gistbuildempty|gistbulkdelete|" +
+ "gistcostestimate|gistendscan|gistgetbitmap|gistgettuple|gistinsert|gistmarkpos|" +
+ "gistoptions|gistrescan|gistrestrpos|gistvacuumcleanup|gtsquery_compress|" +
+ "gtsquery_consistent|gtsquery_decompress|gtsquery_penalty|gtsquery_picksplit|" +
+ "gtsquery_same|gtsquery_union|gtsvector_compress|gtsvector_consistent|" +
+ "gtsvector_decompress|gtsvector_penalty|gtsvector_picksplit|gtsvector_same|" +
+ "gtsvector_union|gtsvectorin|gtsvectorout|has_any_column_privilege|" +
+ "has_column_privilege|has_database_privilege|has_foreign_data_wrapper_privilege|" +
+ "has_function_privilege|has_language_privilege|has_schema_privilege|" +
+ "has_sequence_privilege|has_server_privilege|has_table_privilege|" +
+ "has_tablespace_privilege|has_type_privilege|hash_aclitem|hash_array|hash_numeric|" +
+ "hash_range|hashbeginscan|hashbpchar|hashbuild|hashbuildempty|hashbulkdelete|hashchar|" +
+ "hashcostestimate|hashendscan|hashenum|hashfloat4|hashfloat8|hashgetbitmap|hashgettuple|" +
+ "hashinet|hashinsert|hashint2|hashint2vector|hashint4|hashint8|hashmacaddr|hashmarkpos|" +
+ "hashname|hashoid|hashoidvector|hashoptions|hashrescan|hashrestrpos|hashtext|" +
+ "hashvacuumcleanup|hashvarlena|height|host|hostmask|iclikejoinsel|iclikesel|" +
+ "icnlikejoinsel|icnlikesel|icregexeqjoinsel|icregexeqsel|icregexnejoinsel|icregexnesel|" +
+ "inet_client_addr|inet_client_port|inet_in|inet_out|inet_recv|inet_send|" +
+ "inet_server_addr|inet_server_port|inetand|inetmi|inetmi_int8|inetnot|inetor|inetpl|" +
+ "initcap|int2|int24div|int24eq|int24ge|int24gt|int24le|int24lt|int24mi|int24mul|int24ne|" +
+ "int24pl|int28div|int28eq|int28ge|int28gt|int28le|int28lt|int28mi|int28mul|int28ne|int28pl|" +
+ "int2_accum|int2_avg_accum|int2_mul_cash|int2_sum|int2abs|int2and|int2div|int2eq|int2ge|" +
+ "int2gt|int2in|int2larger|int2le|int2lt|int2mi|int2mod|int2mul|int2ne|int2not|int2or|int2out|" +
+ "int2pl|int2recv|int2send|int2shl|int2shr|int2smaller|int2um|int2up|int2vectoreq|" +
+ "int2vectorin|int2vectorout|int2vectorrecv|int2vectorsend|int2xor|int4|int42div|int42eq|" +
+ "int42ge|int42gt|int42le|int42lt|int42mi|int42mul|int42ne|int42pl|int48div|int48eq|int48ge|" +
+ "int48gt|int48le|int48lt|int48mi|int48mul|int48ne|int48pl|int4_accum|int4_avg_accum|" +
+ "int4_mul_cash|int4_sum|int4abs|int4and|int4div|int4eq|int4ge|int4gt|int4in|int4inc|" +
+ "int4larger|int4le|int4lt|int4mi|int4mod|int4mul|int4ne|int4not|int4or|int4out|int4pl|" +
+ "int4range|int4range_canonical|int4range_subdiff|int4recv|int4send|int4shl|int4shr|" +
+ "int4smaller|int4um|int4up|int4xor|int8|int82div|int82eq|int82ge|int82gt|int82le|int82lt|" +
+ "int82mi|int82mul|int82ne|int82pl|int84div|int84eq|int84ge|int84gt|int84le|int84lt|int84mi|" +
+ "int84mul|int84ne|int84pl|int8_accum|int8_avg|int8_avg_accum|int8_sum|int8abs|int8and|" +
+ "int8div|int8eq|int8ge|int8gt|int8in|int8inc|int8inc_any|int8inc_float8_float8|int8larger|" +
+ "int8le|int8lt|int8mi|int8mod|int8mul|int8ne|int8not|int8or|int8out|int8pl|int8pl_inet|" +
+ "int8range|int8range_canonical|int8range_subdiff|int8recv|int8send|int8shl|int8shr|" +
+ "int8smaller|int8um|int8up|int8xor|integer_pl_date|inter_lb|inter_sb|inter_sl|internal_in|" +
+ "internal_out|interval_accum|interval_avg|interval_cmp|interval_div|interval_eq|" +
+ "interval_ge|interval_gt|interval_hash|interval_in|interval_larger|interval_le|" +
+ "interval_lt|interval_mi|interval_mul|interval_ne|interval_out|interval_pl|" +
+ "interval_pl_date|interval_pl_time|interval_pl_timestamp|interval_pl_timestamptz|" +
+ "interval_pl_timetz|interval_recv|interval_send|interval_smaller|interval_transform|" +
+ "interval_um|intervaltypmodin|intervaltypmodout|intinterval|isclosed|isempty|isfinite|" +
+ "ishorizontal|iso8859_1_to_utf8|iso8859_to_utf8|iso_to_koi8r|iso_to_mic|iso_to_win1251|" +
+ "iso_to_win866|isopen|isparallel|isperp|isvertical|johab_to_utf8|json_agg|" +
+ "json_agg_finalfn|json_agg_transfn|json_array_element|json_array_element_text|" +
+ "json_array_elements|json_array_length|json_each|json_each_text|json_extract_path|" +
+ "json_extract_path_op|json_extract_path_text|json_extract_path_text_op|json_in|" +
+ "json_object_field|json_object_field_text|json_object_keys|json_out|" +
+ "json_populate_record|json_populate_recordset|json_recv|json_send|justify_days|" +
+ "justify_hours|justify_interval|koi8r_to_iso|koi8r_to_mic|koi8r_to_utf8|" +
+ "koi8r_to_win1251|koi8r_to_win866|koi8u_to_utf8|lag|language_handler_in|" +
+ "language_handler_out|last_value|lastval|latin1_to_mic|latin2_to_mic|latin2_to_win1250|" +
+ "latin3_to_mic|latin4_to_mic|lead|left|length|like|like_escape|likejoinsel|likesel|line|" +
+ "line_distance|line_eq|line_horizontal|line_in|line_interpt|line_intersect|line_out|" +
+ "line_parallel|line_perp|line_recv|line_send|line_vertical|ln|lo_close|lo_creat|lo_create|" +
+ "lo_export|lo_import|lo_lseek|lo_lseek64|lo_open|lo_tell|lo_tell64|lo_truncate|" +
+ "lo_truncate64|lo_unlink|log|loread|lower|lower_inc|lower_inf|lowrite|lpad|lseg|lseg_center|" +
+ "lseg_distance|lseg_eq|lseg_ge|lseg_gt|lseg_horizontal|lseg_in|lseg_interpt|" +
+ "lseg_intersect|lseg_le|lseg_length|lseg_lt|lseg_ne|lseg_out|lseg_parallel|lseg_perp|" +
+ "lseg_recv|lseg_send|lseg_vertical|ltrim|macaddr_and|macaddr_cmp|macaddr_eq|macaddr_ge|" +
+ "macaddr_gt|macaddr_in|macaddr_le|macaddr_lt|macaddr_ne|macaddr_not|macaddr_or|" +
+ "macaddr_out|macaddr_recv|macaddr_send|makeaclitem|masklen|max|md5|mic_to_ascii|" +
+ "mic_to_big5|mic_to_euc_cn|mic_to_euc_jp|mic_to_euc_kr|mic_to_euc_tw|mic_to_iso|" +
+ "mic_to_koi8r|mic_to_latin1|mic_to_latin2|mic_to_latin3|mic_to_latin4|mic_to_sjis|" +
+ "mic_to_win1250|mic_to_win1251|mic_to_win866|min|mktinterval|mod|money|mul_d_interval|" +
+ "name|nameeq|namege|namegt|nameiclike|nameicnlike|nameicregexeq|nameicregexne|namein|" +
+ "namele|namelike|namelt|namene|namenlike|nameout|namerecv|nameregexeq|nameregexne|namesend|" +
+ "neqjoinsel|neqsel|netmask|network|network_cmp|network_eq|network_ge|network_gt|" +
+ "network_le|network_lt|network_ne|network_sub|network_subeq|network_sup|network_supeq|" +
+ "nextval|nlikejoinsel|nlikesel|notlike|now|npoints|nth_value|ntile|numeric_abs|" +
+ "numeric_accum|numeric_add|numeric_avg|numeric_avg_accum|numeric_cmp|numeric_div|" +
+ "numeric_div_trunc|numeric_eq|numeric_exp|numeric_fac|numeric_ge|numeric_gt|numeric_in|" +
+ "numeric_inc|numeric_larger|numeric_le|numeric_ln|numeric_log|numeric_lt|numeric_mod|" +
+ "numeric_mul|numeric_ne|numeric_out|numeric_power|numeric_recv|numeric_send|" +
+ "numeric_smaller|numeric_sqrt|numeric_stddev_pop|numeric_stddev_samp|numeric_sub|" +
+ "numeric_transform|numeric_uminus|numeric_uplus|numeric_var_pop|numeric_var_samp|" +
+ "numerictypmodin|numerictypmodout|numnode|numrange|numrange_subdiff|obj_description|" +
+ "octet_length|oid|oideq|oidge|oidgt|oidin|oidlarger|oidle|oidlt|oidne|oidout|oidrecv|oidsend|" +
+ "oidsmaller|oidvectoreq|oidvectorge|oidvectorgt|oidvectorin|oidvectorle|oidvectorlt|" +
+ "oidvectorne|oidvectorout|oidvectorrecv|oidvectorsend|oidvectortypes|on_pb|on_pl|" +
+ "on_ppath|on_ps|on_sb|on_sl|opaque_in|opaque_out|overlaps|overlay|path|path_add|path_add_pt|" +
+ "path_center|path_contain_pt|path_distance|path_div_pt|path_in|path_inter|path_length|" +
+ "path_mul_pt|path_n_eq|path_n_ge|path_n_gt|path_n_le|path_n_lt|path_npoints|path_out|" +
+ "path_recv|path_send|path_sub_pt|pclose|percent_rank|pg_advisory_lock|" +
+ "pg_advisory_lock_shared|pg_advisory_unlock|pg_advisory_unlock_all|" +
+ "pg_advisory_unlock_shared|pg_advisory_xact_lock|pg_advisory_xact_lock_shared|" +
+ "pg_available_extension_versions|pg_available_extensions|pg_backend_pid|" +
+ "pg_backup_start_time|pg_cancel_backend|pg_char_to_encoding|pg_client_encoding|" +
+ "pg_collation_for|pg_collation_is_visible|pg_column_is_updatable|pg_column_size|" +
+ "pg_conf_load_time|pg_conversion_is_visible|pg_create_restore_point|" +
+ "pg_current_xlog_insert_location|pg_current_xlog_location|pg_cursor|pg_database_size|" +
+ "pg_describe_object|pg_encoding_max_length|pg_encoding_to_char|" +
+ "pg_event_trigger_dropped_objects|pg_export_snapshot|pg_extension_config_dump|" +
+ "pg_extension_update_paths|pg_function_is_visible|pg_get_constraintdef|pg_get_expr|" +
+ "pg_get_function_arguments|pg_get_function_identity_arguments|" +
+ "pg_get_function_result|pg_get_functiondef|pg_get_indexdef|pg_get_keywords|" +
+ "pg_get_multixact_members|pg_get_ruledef|pg_get_serial_sequence|pg_get_triggerdef|" +
+ "pg_get_userbyid|pg_get_viewdef|pg_has_role|pg_identify_object|pg_indexes_size|" +
+ "pg_is_in_backup|pg_is_in_recovery|pg_is_other_temp_schema|pg_is_xlog_replay_paused|" +
+ "pg_last_xact_replay_timestamp|pg_last_xlog_receive_location|" +
+ "pg_last_xlog_replay_location|pg_listening_channels|pg_lock_status|pg_ls_dir|" +
+ "pg_my_temp_schema|pg_node_tree_in|pg_node_tree_out|pg_node_tree_recv|" +
+ "pg_node_tree_send|pg_notify|pg_opclass_is_visible|pg_operator_is_visible|" +
+ "pg_opfamily_is_visible|pg_options_to_table|pg_postmaster_start_time|" +
+ "pg_prepared_statement|pg_prepared_xact|pg_read_binary_file|pg_read_file|" +
+ "pg_relation_filenode|pg_relation_filepath|pg_relation_is_updatable|pg_relation_size|" +
+ "pg_reload_conf|pg_rotate_logfile|pg_sequence_parameters|pg_show_all_settings|" +
+ "pg_size_pretty|pg_sleep|pg_start_backup|pg_stat_clear_snapshot|pg_stat_file|" +
+ "pg_stat_get_activity|pg_stat_get_analyze_count|pg_stat_get_autoanalyze_count|" +
+ "pg_stat_get_autovacuum_count|pg_stat_get_backend_activity|" +
+ "pg_stat_get_backend_activity_start|pg_stat_get_backend_client_addr|" +
+ "pg_stat_get_backend_client_port|pg_stat_get_backend_dbid|pg_stat_get_backend_idset|" +
+ "pg_stat_get_backend_pid|pg_stat_get_backend_start|pg_stat_get_backend_userid|" +
+ "pg_stat_get_backend_waiting|pg_stat_get_backend_xact_start|" +
+ "pg_stat_get_bgwriter_buf_written_checkpoints|" +
+ "pg_stat_get_bgwriter_buf_written_clean|pg_stat_get_bgwriter_maxwritten_clean|" +
+ "pg_stat_get_bgwriter_requested_checkpoints|pg_stat_get_bgwriter_stat_reset_time|" +
+ "pg_stat_get_bgwriter_timed_checkpoints|pg_stat_get_blocks_fetched|" +
+ "pg_stat_get_blocks_hit|pg_stat_get_buf_alloc|pg_stat_get_buf_fsync_backend|" +
+ "pg_stat_get_buf_written_backend|pg_stat_get_checkpoint_sync_time|" +
+ "pg_stat_get_checkpoint_write_time|pg_stat_get_db_blk_read_time|" +
+ "pg_stat_get_db_blk_write_time|pg_stat_get_db_blocks_fetched|" +
+ "pg_stat_get_db_blocks_hit|pg_stat_get_db_conflict_all|" +
+ "pg_stat_get_db_conflict_bufferpin|pg_stat_get_db_conflict_lock|" +
+ "pg_stat_get_db_conflict_snapshot|pg_stat_get_db_conflict_startup_deadlock|" +
+ "pg_stat_get_db_conflict_tablespace|pg_stat_get_db_deadlocks|" +
+ "pg_stat_get_db_numbackends|pg_stat_get_db_stat_reset_time|" +
+ "pg_stat_get_db_temp_bytes|pg_stat_get_db_temp_files|pg_stat_get_db_tuples_deleted|" +
+ "pg_stat_get_db_tuples_fetched|pg_stat_get_db_tuples_inserted|" +
+ "pg_stat_get_db_tuples_returned|pg_stat_get_db_tuples_updated|" +
+ "pg_stat_get_db_xact_commit|pg_stat_get_db_xact_rollback|pg_stat_get_dead_tuples|" +
+ "pg_stat_get_function_calls|pg_stat_get_function_self_time|" +
+ "pg_stat_get_function_total_time|pg_stat_get_last_analyze_time|" +
+ "pg_stat_get_last_autoanalyze_time|pg_stat_get_last_autovacuum_time|" +
+ "pg_stat_get_last_vacuum_time|pg_stat_get_live_tuples|pg_stat_get_numscans|" +
+ "pg_stat_get_tuples_deleted|pg_stat_get_tuples_fetched|" +
+ "pg_stat_get_tuples_hot_updated|pg_stat_get_tuples_inserted|" +
+ "pg_stat_get_tuples_returned|pg_stat_get_tuples_updated|pg_stat_get_vacuum_count|" +
+ "pg_stat_get_wal_senders|pg_stat_get_xact_blocks_fetched|" +
+ "pg_stat_get_xact_blocks_hit|pg_stat_get_xact_function_calls|" +
+ "pg_stat_get_xact_function_self_time|pg_stat_get_xact_function_total_time|" +
+ "pg_stat_get_xact_numscans|pg_stat_get_xact_tuples_deleted|" +
+ "pg_stat_get_xact_tuples_fetched|pg_stat_get_xact_tuples_hot_updated|" +
+ "pg_stat_get_xact_tuples_inserted|pg_stat_get_xact_tuples_returned|" +
+ "pg_stat_get_xact_tuples_updated|pg_stat_reset|pg_stat_reset_shared|" +
+ "pg_stat_reset_single_function_counters|pg_stat_reset_single_table_counters|" +
+ "pg_stop_backup|pg_switch_xlog|pg_table_is_visible|pg_table_size|" +
+ "pg_tablespace_databases|pg_tablespace_location|pg_tablespace_size|" +
+ "pg_terminate_backend|pg_timezone_abbrevs|pg_timezone_names|pg_total_relation_size|" +
+ "pg_trigger_depth|pg_try_advisory_lock|pg_try_advisory_lock_shared|" +
+ "pg_try_advisory_xact_lock|pg_try_advisory_xact_lock_shared|pg_ts_config_is_visible|" +
+ "pg_ts_dict_is_visible|pg_ts_parser_is_visible|pg_ts_template_is_visible|" +
+ "pg_type_is_visible|pg_typeof|pg_xlog_location_diff|pg_xlog_replay_pause|" +
+ "pg_xlog_replay_resume|pg_xlogfile_name|pg_xlogfile_name_offset|pi|plainto_tsquery|" +
+ "plpgsql_call_handler|plpgsql_inline_handler|plpgsql_validator|point|point_above|" +
+ "point_add|point_below|point_distance|point_div|point_eq|point_horiz|point_in|point_left|" +
+ "point_mul|point_ne|point_out|point_recv|point_right|point_send|point_sub|point_vert|" +
+ "poly_above|poly_below|poly_center|poly_contain|poly_contain_pt|poly_contained|" +
+ "poly_distance|poly_in|poly_left|poly_npoints|poly_out|poly_overabove|poly_overbelow|" +
+ "poly_overlap|poly_overleft|poly_overright|poly_recv|poly_right|poly_same|poly_send|" +
+ "polygon|popen|position|positionjoinsel|positionsel|postgresql_fdw_validator|pow|power|" +
+ "prsd_end|prsd_headline|prsd_lextype|prsd_nexttoken|prsd_start|pt_contained_circle|" +
+ "pt_contained_poly|query_to_xml|query_to_xml_and_xmlschema|query_to_xmlschema|" +
+ "querytree|quote_ident|quote_literal|quote_nullable|radians|radius|random|range_adjacent|" +
+ "range_after|range_before|range_cmp|range_contained_by|range_contains|" +
+ "range_contains_elem|range_eq|range_ge|range_gist_compress|range_gist_consistent|" +
+ "range_gist_decompress|range_gist_penalty|range_gist_picksplit|range_gist_same|" +
+ "range_gist_union|range_gt|range_in|range_intersect|range_le|range_lt|range_minus|" +
+ "range_ne|range_out|range_overlaps|range_overleft|range_overright|range_recv|range_send|" +
+ "range_typanalyze|range_union|rangesel|rank|record_eq|record_ge|record_gt|record_in|" +
+ "record_le|record_lt|record_ne|record_out|record_recv|record_send|regclass|regclassin|" +
+ "regclassout|regclassrecv|regclasssend|regconfigin|regconfigout|regconfigrecv|" +
+ "regconfigsend|regdictionaryin|regdictionaryout|regdictionaryrecv|regdictionarysend|" +
+ "regexeqjoinsel|regexeqsel|regexnejoinsel|regexnesel|regexp_matches|regexp_replace|" +
+ "regexp_split_to_array|regexp_split_to_table|regoperatorin|regoperatorout|" +
+ "regoperatorrecv|regoperatorsend|regoperin|regoperout|regoperrecv|regopersend|" +
+ "regprocedurein|regprocedureout|regprocedurerecv|regproceduresend|regprocin|regprocout|" +
+ "regprocrecv|regprocsend|regr_avgx|regr_avgy|regr_count|regr_intercept|regr_r2|" +
+ "regr_slope|regr_sxx|regr_sxy|regr_syy|regtypein|regtypeout|regtyperecv|regtypesend|" +
+ "reltime|reltimeeq|reltimege|reltimegt|reltimein|reltimele|reltimelt|reltimene|reltimeout|" +
+ "reltimerecv|reltimesend|repeat|replace|reverse|right|round|row_number|row_to_json|rpad|" +
+ "rtrim|scalargtjoinsel|scalargtsel|scalarltjoinsel|scalarltsel|schema_to_xml|" +
+ "schema_to_xml_and_xmlschema|schema_to_xmlschema|session_user|set_bit|set_byte|" +
+ "set_config|set_masklen|setseed|setval|setweight|shell_in|shell_out|" +
+ "shift_jis_2004_to_euc_jis_2004|shift_jis_2004_to_utf8|shobj_description|sign|" +
+ "similar_escape|sin|sjis_to_euc_jp|sjis_to_mic|sjis_to_utf8|slope|smgreq|smgrin|smgrne|" +
+ "smgrout|spg_kd_choose|spg_kd_config|spg_kd_inner_consistent|spg_kd_picksplit|" +
+ "spg_quad_choose|spg_quad_config|spg_quad_inner_consistent|spg_quad_leaf_consistent|" +
+ "spg_quad_picksplit|spg_range_quad_choose|spg_range_quad_config|" +
+ "spg_range_quad_inner_consistent|spg_range_quad_leaf_consistent|" +
+ "spg_range_quad_picksplit|spg_text_choose|spg_text_config|spg_text_inner_consistent|" +
+ "spg_text_leaf_consistent|spg_text_picksplit|spgbeginscan|spgbuild|spgbuildempty|" +
+ "spgbulkdelete|spgcanreturn|spgcostestimate|spgendscan|spggetbitmap|spggettuple|" +
+ "spginsert|spgmarkpos|spgoptions|spgrescan|spgrestrpos|spgvacuumcleanup|split_part|sqrt|" +
+ "statement_timestamp|stddev|stddev_pop|stddev_samp|string_agg|string_agg_finalfn|" +
+ "string_agg_transfn|string_to_array|strip|strpos|substr|substring|sum|" +
+ "suppress_redundant_updates_trigger|table_to_xml|table_to_xml_and_xmlschema|" +
+ "table_to_xmlschema|tan|text|text_ge|text_gt|text_larger|text_le|text_lt|text_pattern_ge|" +
+ "text_pattern_gt|text_pattern_le|text_pattern_lt|text_smaller|textanycat|textcat|texteq|" +
+ "texticlike|texticnlike|texticregexeq|texticregexne|textin|textlen|textlike|textne|" +
+ "textnlike|textout|textrecv|textregexeq|textregexne|textsend|thesaurus_init|" +
+ "thesaurus_lexize|tideq|tidge|tidgt|tidin|tidlarger|tidle|tidlt|tidne|tidout|tidrecv|tidsend|" +
+ "tidsmaller|time_cmp|time_eq|time_ge|time_gt|time_hash|time_in|time_larger|time_le|time_lt|" +
+ "time_mi_interval|time_mi_time|time_ne|time_out|time_pl_interval|time_recv|time_send|" +
+ "time_smaller|time_transform|timedate_pl|timemi|timenow|timeofday|timepl|timestamp_cmp|" +
+ "timestamp_cmp_date|timestamp_cmp_timestamptz|timestamp_eq|timestamp_eq_date|" +
+ "timestamp_eq_timestamptz|timestamp_ge|timestamp_ge_date|timestamp_ge_timestamptz|" +
+ "timestamp_gt|timestamp_gt_date|timestamp_gt_timestamptz|timestamp_hash|timestamp_in|" +
+ "timestamp_larger|timestamp_le|timestamp_le_date|timestamp_le_timestamptz|" +
+ "timestamp_lt|timestamp_lt_date|timestamp_lt_timestamptz|timestamp_mi|" +
+ "timestamp_mi_interval|timestamp_ne|timestamp_ne_date|timestamp_ne_timestamptz|" +
+ "timestamp_out|timestamp_pl_interval|timestamp_recv|timestamp_send|timestamp_smaller|" +
+ "timestamp_sortsupport|timestamp_transform|timestamptypmodin|timestamptypmodout|" +
+ "timestamptz_cmp|timestamptz_cmp_date|timestamptz_cmp_timestamp|timestamptz_eq|" +
+ "timestamptz_eq_date|timestamptz_eq_timestamp|timestamptz_ge|timestamptz_ge_date|" +
+ "timestamptz_ge_timestamp|timestamptz_gt|timestamptz_gt_date|" +
+ "timestamptz_gt_timestamp|timestamptz_in|timestamptz_larger|timestamptz_le|" +
+ "timestamptz_le_date|timestamptz_le_timestamp|timestamptz_lt|timestamptz_lt_date|" +
+ "timestamptz_lt_timestamp|timestamptz_mi|timestamptz_mi_interval|timestamptz_ne|" +
+ "timestamptz_ne_date|timestamptz_ne_timestamp|timestamptz_out|" +
+ "timestamptz_pl_interval|timestamptz_recv|timestamptz_send|timestamptz_smaller|" +
+ "timestamptztypmodin|timestamptztypmodout|timetypmodin|timetypmodout|timetz_cmp|" +
+ "timetz_eq|timetz_ge|timetz_gt|timetz_hash|timetz_in|timetz_larger|timetz_le|timetz_lt|" +
+ "timetz_mi_interval|timetz_ne|timetz_out|timetz_pl_interval|timetz_recv|timetz_send|" +
+ "timetz_smaller|timetzdate_pl|timetztypmodin|timetztypmodout|timezone|tinterval|" +
+ "tintervalct|tintervalend|tintervaleq|tintervalge|tintervalgt|tintervalin|tintervalle|" +
+ "tintervalleneq|tintervallenge|tintervallengt|tintervallenle|tintervallenlt|" +
+ "tintervallenne|tintervallt|tintervalne|tintervalout|tintervalov|tintervalrecv|" +
+ "tintervalrel|tintervalsame|tintervalsend|tintervalstart|to_ascii|to_char|to_date|to_hex|" +
+ "to_json|to_number|to_timestamp|to_tsquery|to_tsvector|transaction_timestamp|translate|" +
+ "trigger_in|trigger_out|trunc|ts_debug|ts_headline|ts_lexize|ts_match_qv|ts_match_tq|" +
+ "ts_match_tt|ts_match_vq|ts_parse|ts_rank|ts_rank_cd|ts_rewrite|ts_stat|ts_token_type|" +
+ "ts_typanalyze|tsmatchjoinsel|tsmatchsel|tsq_mcontained|tsq_mcontains|tsquery_and|" +
+ "tsquery_cmp|tsquery_eq|tsquery_ge|tsquery_gt|tsquery_le|tsquery_lt|tsquery_ne|" +
+ "tsquery_not|tsquery_or|tsqueryin|tsqueryout|tsqueryrecv|tsquerysend|tsrange|" +
+ "tsrange_subdiff|tstzrange|tstzrange_subdiff|tsvector_cmp|tsvector_concat|tsvector_eq|" +
+ "tsvector_ge|tsvector_gt|tsvector_le|tsvector_lt|tsvector_ne|tsvector_update_trigger|" +
+ "tsvector_update_trigger_column|tsvectorin|tsvectorout|tsvectorrecv|tsvectorsend|" +
+ "txid_current|txid_current_snapshot|txid_snapshot_in|txid_snapshot_out|" +
+ "txid_snapshot_recv|txid_snapshot_send|txid_snapshot_xip|txid_snapshot_xmax|" +
+ "txid_snapshot_xmin|txid_visible_in_snapshot|uhc_to_utf8|unique_key_recheck|unknownin|" +
+ "unknownout|unknownrecv|unknownsend|unnest|upper|upper_inc|upper_inf|utf8_to_ascii|" +
+ "utf8_to_big5|utf8_to_euc_cn|utf8_to_euc_jis_2004|utf8_to_euc_jp|utf8_to_euc_kr|" +
+ "utf8_to_euc_tw|utf8_to_gb18030|utf8_to_gbk|utf8_to_iso8859|utf8_to_iso8859_1|" +
+ "utf8_to_johab|utf8_to_koi8r|utf8_to_koi8u|utf8_to_shift_jis_2004|utf8_to_sjis|" +
+ "utf8_to_uhc|utf8_to_win|uuid_cmp|uuid_eq|uuid_ge|uuid_gt|uuid_hash|uuid_in|uuid_le|" +
+ "uuid_lt|uuid_ne|uuid_out|uuid_recv|uuid_send|var_pop|var_samp|varbit_in|varbit_out|" +
+ "varbit_recv|varbit_send|varbit_transform|varbitcmp|varbiteq|varbitge|varbitgt|varbitle|" +
+ "varbitlt|varbitne|varbittypmodin|varbittypmodout|varchar_transform|varcharin|" +
+ "varcharout|varcharrecv|varcharsend|varchartypmodin|varchartypmodout|variance|version|" +
+ "void_in|void_out|void_recv|void_send|width|width_bucket|win1250_to_latin2|" +
+ "win1250_to_mic|win1251_to_iso|win1251_to_koi8r|win1251_to_mic|win1251_to_win866|" +
+ "win866_to_iso|win866_to_koi8r|win866_to_mic|win866_to_win1251|win_to_utf8|xideq|" +
+ "xideqint4|xidin|xidout|xidrecv|xidsend|xml|xml_in|xml_is_well_formed|" +
+ "xml_is_well_formed_content|xml_is_well_formed_document|xml_out|xml_recv|xml_send|" +
+ "xmlagg|xmlcomment|xmlconcat2|xmlexists|xmlvalidate|xpath|xpath_exists"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords
+ }, "identifier", true);
+
+
+ var sqlRules = [{
+ token : "string", // single line string -- assume dollar strings if multi-line for now
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "variable.language", // pg identifier
+ regex : '".*?"'
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_][a-zA-Z0-9_$]*\\b" // TODO - Unicode in identifiers
+ }, {
+ token : "keyword.operator",
+ regex : "!|!!|!~|!~\\*|!~~|!~~\\*|#|##|#<|#<=|#<>|#=|#>|#>=|%|\\&|\\&\\&|\\&<|\\&<\\||\\&>|\\*|\\+|" +
+ "\\-|/|<|<#>|<\\->|<<|<<=|<<\\||<=|<>|<\\?>|<@|<\\^|=|>|>=|>>|>>=|>\\^|\\?#|\\?\\-|\\?\\-\\||" +
+ "\\?\\||\\?\\|\\||@|@\\-@|@>|@@|@@@|\\^|\\||\\|\\&>|\\|/|\\|>>|\\|\\||\\|\\|/|~|~\\*|~<=~|~<~|" +
+ "~=|~>=~|~>~|~~|~~\\*"
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ];
+
+
+ this.$rules = {
+ "start" : [{
+ token : "comment",
+ regex : "--.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi-line comment
+ regex : "\\/\\*",
+ next : "comment"
+ },{
+ token : "keyword.statementBegin",
+ regex : "^[a-zA-Z]+", // Could enumerate starting keywords but this allows things to work when new statements are added.
+ next : "statement"
+ },{
+ token : "support.buildin", // psql directive
+ regex : "^\\\\[\\S]+.*$"
+ }
+ ],
+
+ "statement" : [{
+ token : "comment",
+ regex : "--.*$"
+ }, {
+ token : "comment", // multi-line comment
+ regex : "\\/\\*",
+ next : "commentStatement"
+ }, {
+ token : "statementEnd",
+ regex : ";",
+ next : "start"
+ }, {
+ token : "string",
+ regex : "\\$perl\\$",
+ next : "perl-start"
+ }, {
+ token : "string",
+ regex : "\\$python\\$",
+ next : "python-start"
+ }, {
+ token : "string",
+ regex : "\\$json\\$",
+ next : "json-start"
+ }, {
+ token : "string",
+ regex : "\\$(js|javascript)\\$",
+ next : "javascript-start"
+ }, {
+ token : "string",
+ regex : "\\$[\\w_0-9]*\\$$", // dollar quote at the end of a line
+ next : "dollarSql"
+ }, {
+ token : "string",
+ regex : "\\$[\\w_0-9]*\\$",
+ next : "dollarStatementString"
+ }
+ ].concat(sqlRules),
+
+ "dollarSql" : [{
+ token : "comment",
+ regex : "--.*$"
+ }, {
+ token : "comment", // multi-line comment
+ regex : "\\/\\*",
+ next : "commentDollarSql"
+ }, {
+ token : "string", // end quoting with dollar at the start of a line
+ regex : "^\\$[\\w_0-9]*\\$",
+ next : "statement"
+ }, {
+ token : "string",
+ regex : "\\$[\\w_0-9]*\\$",
+ next : "dollarSqlString"
+ }
+ ].concat(sqlRules),
+
+ "comment" : [{
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+
+ "commentStatement" : [{
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "statement"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+
+ "commentDollarSql" : [{
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "dollarSql"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+
+ "dollarStatementString" : [{
+ token : "string", // closing dollarstring
+ regex : ".*?\\$[\\w_0-9]*\\$",
+ next : "statement"
+ }, {
+ token : "string", // dollarstring spanning whole line
+ regex : ".+"
+ }
+ ],
+
+ "dollarSqlString" : [{
+ token : "string", // closing dollarstring
+ regex : ".*?\\$[\\w_0-9]*\\$",
+ next : "dollarSql"
+ }, {
+ token : "string", // dollarstring spanning whole line
+ regex : ".+"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-", [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.embedRules(PerlHighlightRules, "perl-", [{token : "string", regex : "\\$perl\\$", next : "statement"}]);
+ this.embedRules(PythonHighlightRules, "python-", [{token : "string", regex : "\\$python\\$", next : "statement"}]);
+ this.embedRules(JsonHighlightRules, "json-", [{token : "string", regex : "\\$json\\$", next : "statement"}]);
+ this.embedRules(JavaScriptHighlightRules, "javascript-", [{token : "string", regex : "\\$(js|javascript)\\$", next : "statement"}]);
+};
+
+oop.inherits(PgsqlHighlightRules, TextHighlightRules);
+
+exports.PgsqlHighlightRules = PgsqlHighlightRules;
+});
+
+ace.define("ace/mode/pgsql",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/pgsql_highlight_rules"], function(require, exports, module) {
+
+var oop = require("../lib/oop");
+var TextMode = require("../mode/text").Mode;
+var PgsqlHighlightRules = require("./pgsql_highlight_rules").PgsqlHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = PgsqlHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ if (state == "start" || state == "keyword.statementEnd") {
+ return "";
+ } else {
+ return this.$getIndent(line); // Keep whatever indent the previous line has
+ }
+ };
+
+ this.$id = "ace/mode/pgsql";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-php.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-php.js
new file mode 100644
index 00000000..b4d55de8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-php.js
@@ -0,0 +1,12856 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/php_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var PhpLangHighlightRules = function() {
+ var docComment = DocCommentHighlightRules;
+ var builtinFunctions = lang.arrayToMap(
+ ('abs|acos|acosh|addcslashes|addslashes|aggregate|aggregate_info|aggregate_methods|aggregate_methods_by_list|aggregate_methods_by_regexp|' +
+ 'aggregate_properties|aggregate_properties_by_list|aggregate_properties_by_regexp|aggregation_info|amqpconnection|amqpexchange|amqpqueue|' +
+ 'apache_child_terminate|apache_get_modules|apache_get_version|apache_getenv|apache_lookup_uri|apache_note|apache_request_headers|' +
+ 'apache_reset_timeout|apache_response_headers|apache_setenv|apc_add|apc_bin_dump|apc_bin_dumpfile|apc_bin_load|apc_bin_loadfile|' +
+ 'apc_cache_info|apc_cas|apc_clear_cache|apc_compile_file|apc_dec|apc_define_constants|apc_delete|apc_delete_file|apc_exists|apc_fetch|' +
+ 'apc_inc|apc_load_constants|apc_sma_info|apc_store|apciterator|apd_breakpoint|apd_callstack|apd_clunk|apd_continue|apd_croak|' +
+ 'apd_dump_function_table|apd_dump_persistent_resources|apd_dump_regular_resources|apd_echo|apd_get_active_symbols|apd_set_pprof_trace|' +
+ 'apd_set_session|apd_set_session_trace|apd_set_session_trace_socket|appenditerator|array|array_change_key_case|array_chunk|array_combine|' +
+ 'array_count_values|array_diff|array_diff_assoc|array_diff_key|array_diff_uassoc|array_diff_ukey|array_fill|array_fill_keys|array_filter|' +
+ 'array_flip|array_intersect|array_intersect_assoc|array_intersect_key|array_intersect_uassoc|array_intersect_ukey|array_key_exists|' +
+ 'array_keys|array_map|array_merge|array_merge_recursive|array_multisort|array_pad|array_pop|array_product|array_push|array_rand|' +
+ 'array_reduce|array_replace|array_replace_recursive|array_reverse|array_search|array_shift|array_slice|array_splice|array_sum|array_udiff|' +
+ 'array_udiff_assoc|array_udiff_uassoc|array_uintersect|array_uintersect_assoc|array_uintersect_uassoc|array_unique|array_unshift|' +
+ 'array_values|array_walk|array_walk_recursive|arrayaccess|arrayiterator|arrayobject|arsort|asin|asinh|asort|assert|assert_options|atan|' +
+ 'atan2|atanh|audioproperties|badfunctioncallexception|badmethodcallexception|base64_decode|base64_encode|base_convert|basename|' +
+ 'bbcode_add_element|bbcode_add_smiley|bbcode_create|bbcode_destroy|bbcode_parse|bbcode_set_arg_parser|bbcode_set_flags|bcadd|bccomp|bcdiv|' +
+ 'bcmod|bcmul|bcompiler_load|bcompiler_load_exe|bcompiler_parse_class|bcompiler_read|bcompiler_write_class|bcompiler_write_constant|' +
+ 'bcompiler_write_exe_footer|bcompiler_write_file|bcompiler_write_footer|bcompiler_write_function|bcompiler_write_functions_from_file|' +
+ 'bcompiler_write_header|bcompiler_write_included_filename|bcpow|bcpowmod|bcscale|bcsqrt|bcsub|bin2hex|bind_textdomain_codeset|bindec|' +
+ 'bindtextdomain|bson_decode|bson_encode|bumpValue|bzclose|bzcompress|bzdecompress|bzerrno|bzerror|bzerrstr|bzflush|bzopen|bzread|bzwrite|' +
+ 'cachingiterator|cairo|cairo_create|cairo_font_face_get_type|cairo_font_face_status|cairo_font_options_create|cairo_font_options_equal|' +
+ 'cairo_font_options_get_antialias|cairo_font_options_get_hint_metrics|cairo_font_options_get_hint_style|' +
+ 'cairo_font_options_get_subpixel_order|cairo_font_options_hash|cairo_font_options_merge|cairo_font_options_set_antialias|' +
+ 'cairo_font_options_set_hint_metrics|cairo_font_options_set_hint_style|cairo_font_options_set_subpixel_order|cairo_font_options_status|' +
+ 'cairo_format_stride_for_width|cairo_image_surface_create|cairo_image_surface_create_for_data|cairo_image_surface_create_from_png|' +
+ 'cairo_image_surface_get_data|cairo_image_surface_get_format|cairo_image_surface_get_height|cairo_image_surface_get_stride|' +
+ 'cairo_image_surface_get_width|cairo_matrix_create_scale|cairo_matrix_create_translate|cairo_matrix_invert|cairo_matrix_multiply|' +
+ 'cairo_matrix_rotate|cairo_matrix_transform_distance|cairo_matrix_transform_point|cairo_matrix_translate|cairo_pattern_add_color_stop_rgb|' +
+ 'cairo_pattern_add_color_stop_rgba|cairo_pattern_create_for_surface|cairo_pattern_create_linear|cairo_pattern_create_radial|' +
+ 'cairo_pattern_create_rgb|cairo_pattern_create_rgba|cairo_pattern_get_color_stop_count|cairo_pattern_get_color_stop_rgba|' +
+ 'cairo_pattern_get_extend|cairo_pattern_get_filter|cairo_pattern_get_linear_points|cairo_pattern_get_matrix|' +
+ 'cairo_pattern_get_radial_circles|cairo_pattern_get_rgba|cairo_pattern_get_surface|cairo_pattern_get_type|cairo_pattern_set_extend|' +
+ 'cairo_pattern_set_filter|cairo_pattern_set_matrix|cairo_pattern_status|cairo_pdf_surface_create|cairo_pdf_surface_set_size|' +
+ 'cairo_ps_get_levels|cairo_ps_level_to_string|cairo_ps_surface_create|cairo_ps_surface_dsc_begin_page_setup|' +
+ 'cairo_ps_surface_dsc_begin_setup|cairo_ps_surface_dsc_comment|cairo_ps_surface_get_eps|cairo_ps_surface_restrict_to_level|' +
+ 'cairo_ps_surface_set_eps|cairo_ps_surface_set_size|cairo_scaled_font_create|cairo_scaled_font_extents|cairo_scaled_font_get_ctm|' +
+ 'cairo_scaled_font_get_font_face|cairo_scaled_font_get_font_matrix|cairo_scaled_font_get_font_options|cairo_scaled_font_get_scale_matrix|' +
+ 'cairo_scaled_font_get_type|cairo_scaled_font_glyph_extents|cairo_scaled_font_status|cairo_scaled_font_text_extents|' +
+ 'cairo_surface_copy_page|cairo_surface_create_similar|cairo_surface_finish|cairo_surface_flush|cairo_surface_get_content|' +
+ 'cairo_surface_get_device_offset|cairo_surface_get_font_options|cairo_surface_get_type|cairo_surface_mark_dirty|' +
+ 'cairo_surface_mark_dirty_rectangle|cairo_surface_set_device_offset|cairo_surface_set_fallback_resolution|cairo_surface_show_page|' +
+ 'cairo_surface_status|cairo_surface_write_to_png|cairo_svg_surface_create|cairo_svg_surface_restrict_to_version|' +
+ 'cairo_svg_version_to_string|cairoantialias|cairocontent|cairocontext|cairoexception|cairoextend|cairofillrule|cairofilter|cairofontface|' +
+ 'cairofontoptions|cairofontslant|cairofonttype|cairofontweight|cairoformat|cairogradientpattern|cairohintmetrics|cairohintstyle|' +
+ 'cairoimagesurface|cairolineargradient|cairolinecap|cairolinejoin|cairomatrix|cairooperator|cairopath|cairopattern|cairopatterntype|' +
+ 'cairopdfsurface|cairopslevel|cairopssurface|cairoradialgradient|cairoscaledfont|cairosolidpattern|cairostatus|cairosubpixelorder|' +
+ 'cairosurface|cairosurfacepattern|cairosurfacetype|cairosvgsurface|cairosvgversion|cairotoyfontface|cal_days_in_month|cal_from_jd|cal_info|' +
+ 'cal_to_jd|calcul_hmac|calculhmac|call_user_func|call_user_func_array|call_user_method|call_user_method_array|callbackfilteriterator|ceil|' +
+ 'chdb|chdb_create|chdir|checkdate|checkdnsrr|chgrp|chmod|chop|chown|chr|chroot|chunk_split|class_alias|class_exists|class_implements|' +
+ 'class_parents|class_uses|classkit_import|classkit_method_add|classkit_method_copy|classkit_method_redefine|classkit_method_remove|' +
+ 'classkit_method_rename|clearstatcache|clone|closedir|closelog|collator|com|com_addref|com_create_guid|com_event_sink|com_get|' +
+ 'com_get_active_object|com_invoke|com_isenum|com_load|com_load_typelib|com_message_pump|com_print_typeinfo|com_propget|com_propput|' +
+ 'com_propset|com_release|com_set|compact|connection_aborted|connection_status|connection_timeout|constant|construct|construct|construct|' +
+ 'convert_cyr_string|convert_uudecode|convert_uuencode|copy|cos|cosh|count|count_chars|countable|counter_bump|counter_bump_value|' +
+ 'counter_create|counter_get|counter_get_meta|counter_get_named|counter_get_value|counter_reset|counter_reset_value|crack_check|' +
+ 'crack_closedict|crack_getlastmessage|crack_opendict|crc32|create_function|crypt|ctype_alnum|ctype_alpha|ctype_cntrl|ctype_digit|' +
+ 'ctype_graph|ctype_lower|ctype_print|ctype_punct|ctype_space|ctype_upper|ctype_xdigit|cubrid_affected_rows|cubrid_bind|' +
+ 'cubrid_client_encoding|cubrid_close|cubrid_close_prepare|cubrid_close_request|cubrid_col_get|cubrid_col_size|cubrid_column_names|' +
+ 'cubrid_column_types|cubrid_commit|cubrid_connect|cubrid_connect_with_url|cubrid_current_oid|cubrid_data_seek|cubrid_db_name|' +
+ 'cubrid_disconnect|cubrid_drop|cubrid_errno|cubrid_error|cubrid_error_code|cubrid_error_code_facility|cubrid_error_msg|cubrid_execute|' +
+ 'cubrid_fetch|cubrid_fetch_array|cubrid_fetch_assoc|cubrid_fetch_field|cubrid_fetch_lengths|cubrid_fetch_object|cubrid_fetch_row|' +
+ 'cubrid_field_flags|cubrid_field_len|cubrid_field_name|cubrid_field_seek|cubrid_field_table|cubrid_field_type|cubrid_free_result|' +
+ 'cubrid_get|cubrid_get_autocommit|cubrid_get_charset|cubrid_get_class_name|cubrid_get_client_info|cubrid_get_db_parameter|' +
+ 'cubrid_get_server_info|cubrid_insert_id|cubrid_is_instance|cubrid_list_dbs|cubrid_load_from_glo|cubrid_lob_close|cubrid_lob_export|' +
+ 'cubrid_lob_get|cubrid_lob_send|cubrid_lob_size|cubrid_lock_read|cubrid_lock_write|cubrid_move_cursor|cubrid_new_glo|cubrid_next_result|' +
+ 'cubrid_num_cols|cubrid_num_fields|cubrid_num_rows|cubrid_ping|cubrid_prepare|cubrid_put|cubrid_query|cubrid_real_escape_string|' +
+ 'cubrid_result|cubrid_rollback|cubrid_save_to_glo|cubrid_schema|cubrid_send_glo|cubrid_seq_drop|cubrid_seq_insert|cubrid_seq_put|' +
+ 'cubrid_set_add|cubrid_set_autocommit|cubrid_set_db_parameter|cubrid_set_drop|cubrid_unbuffered_query|cubrid_version|curl_close|' +
+ 'curl_copy_handle|curl_errno|curl_error|curl_exec|curl_getinfo|curl_init|curl_multi_add_handle|curl_multi_close|curl_multi_exec|' +
+ 'curl_multi_getcontent|curl_multi_info_read|curl_multi_init|curl_multi_remove_handle|curl_multi_select|curl_setopt|curl_setopt_array|' +
+ 'curl_version|current|cyrus_authenticate|cyrus_bind|cyrus_close|cyrus_connect|cyrus_query|cyrus_unbind|date|date_add|date_create|' +
+ 'date_create_from_format|date_date_set|date_default_timezone_get|date_default_timezone_set|date_diff|date_format|date_get_last_errors|' +
+ 'date_interval_create_from_date_string|date_interval_format|date_isodate_set|date_modify|date_offset_get|date_parse|date_parse_from_format|' +
+ 'date_sub|date_sun_info|date_sunrise|date_sunset|date_time_set|date_timestamp_get|date_timestamp_set|date_timezone_get|date_timezone_set|' +
+ 'dateinterval|dateperiod|datetime|datetimezone|db2_autocommit|db2_bind_param|db2_client_info|db2_close|db2_column_privileges|db2_columns|' +
+ 'db2_commit|db2_conn_error|db2_conn_errormsg|db2_connect|db2_cursor_type|db2_escape_string|db2_exec|db2_execute|db2_fetch_array|' +
+ 'db2_fetch_assoc|db2_fetch_both|db2_fetch_object|db2_fetch_row|db2_field_display_size|db2_field_name|db2_field_num|db2_field_precision|' +
+ 'db2_field_scale|db2_field_type|db2_field_width|db2_foreign_keys|db2_free_result|db2_free_stmt|db2_get_option|db2_last_insert_id|' +
+ 'db2_lob_read|db2_next_result|db2_num_fields|db2_num_rows|db2_pclose|db2_pconnect|db2_prepare|db2_primary_keys|db2_procedure_columns|' +
+ 'db2_procedures|db2_result|db2_rollback|db2_server_info|db2_set_option|db2_special_columns|db2_statistics|db2_stmt_error|db2_stmt_errormsg|' +
+ 'db2_table_privileges|db2_tables|dba_close|dba_delete|dba_exists|dba_fetch|dba_firstkey|dba_handlers|dba_insert|dba_key_split|dba_list|' +
+ 'dba_nextkey|dba_open|dba_optimize|dba_popen|dba_replace|dba_sync|dbase_add_record|dbase_close|dbase_create|dbase_delete_record|' +
+ 'dbase_get_header_info|dbase_get_record|dbase_get_record_with_names|dbase_numfields|dbase_numrecords|dbase_open|dbase_pack|' +
+ 'dbase_replace_record|dbplus_add|dbplus_aql|dbplus_chdir|dbplus_close|dbplus_curr|dbplus_errcode|dbplus_errno|dbplus_find|dbplus_first|' +
+ 'dbplus_flush|dbplus_freealllocks|dbplus_freelock|dbplus_freerlocks|dbplus_getlock|dbplus_getunique|dbplus_info|dbplus_last|dbplus_lockrel|' +
+ 'dbplus_next|dbplus_open|dbplus_prev|dbplus_rchperm|dbplus_rcreate|dbplus_rcrtexact|dbplus_rcrtlike|dbplus_resolve|dbplus_restorepos|' +
+ 'dbplus_rkeys|dbplus_ropen|dbplus_rquery|dbplus_rrename|dbplus_rsecindex|dbplus_runlink|dbplus_rzap|dbplus_savepos|dbplus_setindex|' +
+ 'dbplus_setindexbynumber|dbplus_sql|dbplus_tcl|dbplus_tremove|dbplus_undo|dbplus_undoprepare|dbplus_unlockrel|dbplus_unselect|' +
+ 'dbplus_update|dbplus_xlockrel|dbplus_xunlockrel|dbx_close|dbx_compare|dbx_connect|dbx_error|dbx_escape_string|dbx_fetch_row|dbx_query|' +
+ 'dbx_sort|dcgettext|dcngettext|deaggregate|debug_backtrace|debug_print_backtrace|debug_zval_dump|decbin|dechex|decoct|define|' +
+ 'define_syslog_variables|defined|deg2rad|delete|dgettext|die|dio_close|dio_fcntl|dio_open|dio_read|dio_seek|dio_stat|dio_tcsetattr|' +
+ 'dio_truncate|dio_write|dir|directoryiterator|dirname|disk_free_space|disk_total_space|diskfreespace|dl|dngettext|dns_check_record|' +
+ 'dns_get_mx|dns_get_record|dom_import_simplexml|domainexception|domattr|domattribute_name|domattribute_set_value|domattribute_specified|' +
+ 'domattribute_value|domcharacterdata|domcomment|domdocument|domdocument_add_root|domdocument_create_attribute|' +
+ 'domdocument_create_cdata_section|domdocument_create_comment|domdocument_create_element|domdocument_create_element_ns|' +
+ 'domdocument_create_entity_reference|domdocument_create_processing_instruction|domdocument_create_text_node|domdocument_doctype|' +
+ 'domdocument_document_element|domdocument_dump_file|domdocument_dump_mem|domdocument_get_element_by_id|domdocument_get_elements_by_tagname|' +
+ 'domdocument_html_dump_mem|domdocument_xinclude|domdocumentfragment|domdocumenttype|domdocumenttype_entities|' +
+ 'domdocumenttype_internal_subset|domdocumenttype_name|domdocumenttype_notations|domdocumenttype_public_id|domdocumenttype_system_id|' +
+ 'domelement|domelement_get_attribute|domelement_get_attribute_node|domelement_get_elements_by_tagname|domelement_has_attribute|' +
+ 'domelement_remove_attribute|domelement_set_attribute|domelement_set_attribute_node|domelement_tagname|domentity|domentityreference|' +
+ 'domexception|domimplementation|domnamednodemap|domnode|domnode_add_namespace|domnode_append_child|domnode_append_sibling|' +
+ 'domnode_attributes|domnode_child_nodes|domnode_clone_node|domnode_dump_node|domnode_first_child|domnode_get_content|' +
+ 'domnode_has_attributes|domnode_has_child_nodes|domnode_insert_before|domnode_is_blank_node|domnode_last_child|domnode_next_sibling|' +
+ 'domnode_node_name|domnode_node_type|domnode_node_value|domnode_owner_document|domnode_parent_node|domnode_prefix|domnode_previous_sibling|' +
+ 'domnode_remove_child|domnode_replace_child|domnode_replace_node|domnode_set_content|domnode_set_name|domnode_set_namespace|' +
+ 'domnode_unlink_node|domnodelist|domnotation|domprocessinginstruction|domprocessinginstruction_data|domprocessinginstruction_target|' +
+ 'domtext|domxml_new_doc|domxml_open_file|domxml_open_mem|domxml_version|domxml_xmltree|domxml_xslt_stylesheet|domxml_xslt_stylesheet_doc|' +
+ 'domxml_xslt_stylesheet_file|domxml_xslt_version|domxpath|domxsltstylesheet_process|domxsltstylesheet_result_dump_file|' +
+ 'domxsltstylesheet_result_dump_mem|dotnet|dotnet_load|doubleval|each|easter_date|easter_days|echo|empty|emptyiterator|' +
+ 'enchant_broker_describe|enchant_broker_dict_exists|enchant_broker_free|enchant_broker_free_dict|enchant_broker_get_error|' +
+ 'enchant_broker_init|enchant_broker_list_dicts|enchant_broker_request_dict|enchant_broker_request_pwl_dict|enchant_broker_set_ordering|' +
+ 'enchant_dict_add_to_personal|enchant_dict_add_to_session|enchant_dict_check|enchant_dict_describe|enchant_dict_get_error|' +
+ 'enchant_dict_is_in_session|enchant_dict_quick_check|enchant_dict_store_replacement|enchant_dict_suggest|end|ereg|ereg_replace|eregi|' +
+ 'eregi_replace|error_get_last|error_log|error_reporting|errorexception|escapeshellarg|escapeshellcmd|eval|event_add|event_base_free|' +
+ 'event_base_loop|event_base_loopbreak|event_base_loopexit|event_base_new|event_base_priority_init|event_base_set|event_buffer_base_set|' +
+ 'event_buffer_disable|event_buffer_enable|event_buffer_fd_set|event_buffer_free|event_buffer_new|event_buffer_priority_set|' +
+ 'event_buffer_read|event_buffer_set_callback|event_buffer_timeout_set|event_buffer_watermark_set|event_buffer_write|event_del|event_free|' +
+ 'event_new|event_set|exception|exec|exif_imagetype|exif_read_data|exif_tagname|exif_thumbnail|exit|exp|expect_expectl|expect_popen|explode|' +
+ 'expm1|export|export|extension_loaded|extract|ezmlm_hash|fam_cancel_monitor|fam_close|fam_monitor_collection|fam_monitor_directory|' +
+ 'fam_monitor_file|fam_next_event|fam_open|fam_pending|fam_resume_monitor|fam_suspend_monitor|fbsql_affected_rows|fbsql_autocommit|' +
+ 'fbsql_blob_size|fbsql_change_user|fbsql_clob_size|fbsql_close|fbsql_commit|fbsql_connect|fbsql_create_blob|fbsql_create_clob|' +
+ 'fbsql_create_db|fbsql_data_seek|fbsql_database|fbsql_database_password|fbsql_db_query|fbsql_db_status|fbsql_drop_db|fbsql_errno|' +
+ 'fbsql_error|fbsql_fetch_array|fbsql_fetch_assoc|fbsql_fetch_field|fbsql_fetch_lengths|fbsql_fetch_object|fbsql_fetch_row|' +
+ 'fbsql_field_flags|fbsql_field_len|fbsql_field_name|fbsql_field_seek|fbsql_field_table|fbsql_field_type|fbsql_free_result|' +
+ 'fbsql_get_autostart_info|fbsql_hostname|fbsql_insert_id|fbsql_list_dbs|fbsql_list_fields|fbsql_list_tables|fbsql_next_result|' +
+ 'fbsql_num_fields|fbsql_num_rows|fbsql_password|fbsql_pconnect|fbsql_query|fbsql_read_blob|fbsql_read_clob|fbsql_result|fbsql_rollback|' +
+ 'fbsql_rows_fetched|fbsql_select_db|fbsql_set_characterset|fbsql_set_lob_mode|fbsql_set_password|fbsql_set_transaction|fbsql_start_db|' +
+ 'fbsql_stop_db|fbsql_table_name|fbsql_tablename|fbsql_username|fbsql_warnings|fclose|fdf_add_doc_javascript|fdf_add_template|fdf_close|' +
+ 'fdf_create|fdf_enum_values|fdf_errno|fdf_error|fdf_get_ap|fdf_get_attachment|fdf_get_encoding|fdf_get_file|fdf_get_flags|fdf_get_opt|' +
+ 'fdf_get_status|fdf_get_value|fdf_get_version|fdf_header|fdf_next_field_name|fdf_open|fdf_open_string|fdf_remove_item|fdf_save|' +
+ 'fdf_save_string|fdf_set_ap|fdf_set_encoding|fdf_set_file|fdf_set_flags|fdf_set_javascript_action|fdf_set_on_import_javascript|fdf_set_opt|' +
+ 'fdf_set_status|fdf_set_submit_form_action|fdf_set_target_frame|fdf_set_value|fdf_set_version|feof|fflush|fgetc|fgetcsv|fgets|fgetss|file|' +
+ 'file_exists|file_get_contents|file_put_contents|fileatime|filectime|filegroup|fileinode|filemtime|fileowner|fileperms|filepro|' +
+ 'filepro_fieldcount|filepro_fieldname|filepro_fieldtype|filepro_fieldwidth|filepro_retrieve|filepro_rowcount|filesize|filesystemiterator|' +
+ 'filetype|filter_has_var|filter_id|filter_input|filter_input_array|filter_list|filter_var|filter_var_array|filteriterator|finfo_buffer|' +
+ 'finfo_close|finfo_file|finfo_open|finfo_set_flags|floatval|flock|floor|flush|fmod|fnmatch|fopen|forward_static_call|' +
+ 'forward_static_call_array|fpassthru|fprintf|fputcsv|fputs|fread|frenchtojd|fribidi_log2vis|fscanf|fseek|fsockopen|fstat|ftell|ftok|' +
+ 'ftp_alloc|ftp_cdup|ftp_chdir|ftp_chmod|ftp_close|ftp_connect|ftp_delete|ftp_exec|ftp_fget|ftp_fput|ftp_get|ftp_get_option|ftp_login|' +
+ 'ftp_mdtm|ftp_mkdir|ftp_nb_continue|ftp_nb_fget|ftp_nb_fput|ftp_nb_get|ftp_nb_put|ftp_nlist|ftp_pasv|ftp_put|ftp_pwd|ftp_quit|ftp_raw|' +
+ 'ftp_rawlist|ftp_rename|ftp_rmdir|ftp_set_option|ftp_site|ftp_size|ftp_ssl_connect|ftp_systype|ftruncate|func_get_arg|func_get_args|' +
+ 'func_num_args|function_exists|fwrite|gc_collect_cycles|gc_disable|gc_enable|gc_enabled|gd_info|gearmanclient|gearmanjob|gearmantask|' +
+ 'gearmanworker|geoip_continent_code_by_name|geoip_country_code3_by_name|geoip_country_code_by_name|geoip_country_name_by_name|' +
+ 'geoip_database_info|geoip_db_avail|geoip_db_filename|geoip_db_get_all_info|geoip_id_by_name|geoip_isp_by_name|geoip_org_by_name|' +
+ 'geoip_record_by_name|geoip_region_by_name|geoip_region_name_by_code|geoip_time_zone_by_country_and_region|getMeta|getNamed|getValue|' +
+ 'get_browser|get_called_class|get_cfg_var|get_class|get_class_methods|get_class_vars|get_current_user|get_declared_classes|' +
+ 'get_declared_interfaces|get_declared_traits|get_defined_constants|get_defined_functions|get_defined_vars|get_extension_funcs|get_headers|' +
+ 'get_html_translation_table|get_include_path|get_included_files|get_loaded_extensions|get_magic_quotes_gpc|get_magic_quotes_runtime|' +
+ 'get_meta_tags|get_object_vars|get_parent_class|get_required_files|get_resource_type|getallheaders|getconstant|getconstants|getconstructor|' +
+ 'getcwd|getdate|getdefaultproperties|getdoccomment|getendline|getenv|getextension|getextensionname|getfilename|gethostbyaddr|gethostbyname|' +
+ 'gethostbynamel|gethostname|getimagesize|getinterfacenames|getinterfaces|getlastmod|getmethod|getmethods|getmodifiers|getmxrr|getmygid|' +
+ 'getmyinode|getmypid|getmyuid|getname|getnamespacename|getopt|getparentclass|getproperties|getproperty|getprotobyname|getprotobynumber|' +
+ 'getrandmax|getrusage|getservbyname|getservbyport|getshortname|getstartline|getstaticproperties|getstaticpropertyvalue|gettext|' +
+ 'gettimeofday|gettype|glob|globiterator|gmagick|gmagickdraw|gmagickpixel|gmdate|gmmktime|gmp_abs|gmp_add|gmp_and|gmp_clrbit|gmp_cmp|' +
+ 'gmp_com|gmp_div|gmp_div_q|gmp_div_qr|gmp_div_r|gmp_divexact|gmp_fact|gmp_gcd|gmp_gcdext|gmp_hamdist|gmp_init|gmp_intval|gmp_invert|' +
+ 'gmp_jacobi|gmp_legendre|gmp_mod|gmp_mul|gmp_neg|gmp_nextprime|gmp_or|gmp_perfect_square|gmp_popcount|gmp_pow|gmp_powm|gmp_prob_prime|' +
+ 'gmp_random|gmp_scan0|gmp_scan1|gmp_setbit|gmp_sign|gmp_sqrt|gmp_sqrtrem|gmp_strval|gmp_sub|gmp_testbit|gmp_xor|gmstrftime|' +
+ 'gnupg_adddecryptkey|gnupg_addencryptkey|gnupg_addsignkey|gnupg_cleardecryptkeys|gnupg_clearencryptkeys|gnupg_clearsignkeys|gnupg_decrypt|' +
+ 'gnupg_decryptverify|gnupg_encrypt|gnupg_encryptsign|gnupg_export|gnupg_geterror|gnupg_getprotocol|gnupg_import|gnupg_init|gnupg_keyinfo|' +
+ 'gnupg_setarmor|gnupg_seterrormode|gnupg_setsignmode|gnupg_sign|gnupg_verify|gopher_parsedir|grapheme_extract|grapheme_stripos|' +
+ 'grapheme_stristr|grapheme_strlen|grapheme_strpos|grapheme_strripos|grapheme_strrpos|grapheme_strstr|grapheme_substr|gregoriantojd|' +
+ 'gupnp_context_get_host_ip|gupnp_context_get_port|gupnp_context_get_subscription_timeout|gupnp_context_host_path|gupnp_context_new|' +
+ 'gupnp_context_set_subscription_timeout|gupnp_context_timeout_add|gupnp_context_unhost_path|gupnp_control_point_browse_start|' +
+ 'gupnp_control_point_browse_stop|gupnp_control_point_callback_set|gupnp_control_point_new|gupnp_device_action_callback_set|' +
+ 'gupnp_device_info_get|gupnp_device_info_get_service|gupnp_root_device_get_available|gupnp_root_device_get_relative_location|' +
+ 'gupnp_root_device_new|gupnp_root_device_set_available|gupnp_root_device_start|gupnp_root_device_stop|gupnp_service_action_get|' +
+ 'gupnp_service_action_return|gupnp_service_action_return_error|gupnp_service_action_set|gupnp_service_freeze_notify|gupnp_service_info_get|' +
+ 'gupnp_service_info_get_introspection|gupnp_service_introspection_get_state_variable|gupnp_service_notify|gupnp_service_proxy_action_get|' +
+ 'gupnp_service_proxy_action_set|gupnp_service_proxy_add_notify|gupnp_service_proxy_callback_set|gupnp_service_proxy_get_subscribed|' +
+ 'gupnp_service_proxy_remove_notify|gupnp_service_proxy_set_subscribed|gupnp_service_thaw_notify|gzclose|gzcompress|gzdecode|gzdeflate|' +
+ 'gzencode|gzeof|gzfile|gzgetc|gzgets|gzgetss|gzinflate|gzopen|gzpassthru|gzputs|gzread|gzrewind|gzseek|gztell|gzuncompress|gzwrite|' +
+ 'halt_compiler|haruannotation|haruannotation_setborderstyle|haruannotation_sethighlightmode|haruannotation_seticon|' +
+ 'haruannotation_setopened|harudestination|harudestination_setfit|harudestination_setfitb|harudestination_setfitbh|harudestination_setfitbv|' +
+ 'harudestination_setfith|harudestination_setfitr|harudestination_setfitv|harudestination_setxyz|harudoc|harudoc_addpage|' +
+ 'harudoc_addpagelabel|harudoc_construct|harudoc_createoutline|harudoc_getcurrentencoder|harudoc_getcurrentpage|harudoc_getencoder|' +
+ 'harudoc_getfont|harudoc_getinfoattr|harudoc_getpagelayout|harudoc_getpagemode|harudoc_getstreamsize|harudoc_insertpage|harudoc_loadjpeg|' +
+ 'harudoc_loadpng|harudoc_loadraw|harudoc_loadttc|harudoc_loadttf|harudoc_loadtype1|harudoc_output|harudoc_readfromstream|' +
+ 'harudoc_reseterror|harudoc_resetstream|harudoc_save|harudoc_savetostream|harudoc_setcompressionmode|harudoc_setcurrentencoder|' +
+ 'harudoc_setencryptionmode|harudoc_setinfoattr|harudoc_setinfodateattr|harudoc_setopenaction|harudoc_setpagelayout|harudoc_setpagemode|' +
+ 'harudoc_setpagesconfiguration|harudoc_setpassword|harudoc_setpermission|harudoc_usecnsencodings|harudoc_usecnsfonts|' +
+ 'harudoc_usecntencodings|harudoc_usecntfonts|harudoc_usejpencodings|harudoc_usejpfonts|harudoc_usekrencodings|harudoc_usekrfonts|' +
+ 'haruencoder|haruencoder_getbytetype|haruencoder_gettype|haruencoder_getunicode|haruencoder_getwritingmode|haruexception|harufont|' +
+ 'harufont_getascent|harufont_getcapheight|harufont_getdescent|harufont_getencodingname|harufont_getfontname|harufont_gettextwidth|' +
+ 'harufont_getunicodewidth|harufont_getxheight|harufont_measuretext|haruimage|haruimage_getbitspercomponent|haruimage_getcolorspace|' +
+ 'haruimage_getheight|haruimage_getsize|haruimage_getwidth|haruimage_setcolormask|haruimage_setmaskimage|haruoutline|' +
+ 'haruoutline_setdestination|haruoutline_setopened|harupage|harupage_arc|harupage_begintext|harupage_circle|harupage_closepath|' +
+ 'harupage_concat|harupage_createdestination|harupage_createlinkannotation|harupage_createtextannotation|harupage_createurlannotation|' +
+ 'harupage_curveto|harupage_curveto2|harupage_curveto3|harupage_drawimage|harupage_ellipse|harupage_endpath|harupage_endtext|' +
+ 'harupage_eofill|harupage_eofillstroke|harupage_fill|harupage_fillstroke|harupage_getcharspace|harupage_getcmykfill|harupage_getcmykstroke|' +
+ 'harupage_getcurrentfont|harupage_getcurrentfontsize|harupage_getcurrentpos|harupage_getcurrenttextpos|harupage_getdash|' +
+ 'harupage_getfillingcolorspace|harupage_getflatness|harupage_getgmode|harupage_getgrayfill|harupage_getgraystroke|harupage_getheight|' +
+ 'harupage_gethorizontalscaling|harupage_getlinecap|harupage_getlinejoin|harupage_getlinewidth|harupage_getmiterlimit|harupage_getrgbfill|' +
+ 'harupage_getrgbstroke|harupage_getstrokingcolorspace|harupage_gettextleading|harupage_gettextmatrix|harupage_gettextrenderingmode|' +
+ 'harupage_gettextrise|harupage_gettextwidth|harupage_gettransmatrix|harupage_getwidth|harupage_getwordspace|harupage_lineto|' +
+ 'harupage_measuretext|harupage_movetextpos|harupage_moveto|harupage_movetonextline|harupage_rectangle|harupage_setcharspace|' +
+ 'harupage_setcmykfill|harupage_setcmykstroke|harupage_setdash|harupage_setflatness|harupage_setfontandsize|harupage_setgrayfill|' +
+ 'harupage_setgraystroke|harupage_setheight|harupage_sethorizontalscaling|harupage_setlinecap|harupage_setlinejoin|harupage_setlinewidth|' +
+ 'harupage_setmiterlimit|harupage_setrgbfill|harupage_setrgbstroke|harupage_setrotate|harupage_setsize|harupage_setslideshow|' +
+ 'harupage_settextleading|harupage_settextmatrix|harupage_settextrenderingmode|harupage_settextrise|harupage_setwidth|harupage_setwordspace|' +
+ 'harupage_showtext|harupage_showtextnextline|harupage_stroke|harupage_textout|harupage_textrect|hasconstant|hash|hash_algos|hash_copy|' +
+ 'hash_file|hash_final|hash_hmac|hash_hmac_file|hash_init|hash_update|hash_update_file|hash_update_stream|hasmethod|hasproperty|header|' +
+ 'header_register_callback|header_remove|headers_list|headers_sent|hebrev|hebrevc|hex2bin|hexdec|highlight_file|highlight_string|' +
+ 'html_entity_decode|htmlentities|htmlspecialchars|htmlspecialchars_decode|http_build_cookie|http_build_query|http_build_str|http_build_url|' +
+ 'http_cache_etag|http_cache_last_modified|http_chunked_decode|http_date|http_deflate|http_get|http_get_request_body|' +
+ 'http_get_request_body_stream|http_get_request_headers|http_head|http_inflate|http_match_etag|http_match_modified|' +
+ 'http_match_request_header|http_negotiate_charset|http_negotiate_content_type|http_negotiate_language|http_parse_cookie|http_parse_headers|' +
+ 'http_parse_message|http_parse_params|http_persistent_handles_clean|http_persistent_handles_count|http_persistent_handles_ident|' +
+ 'http_post_data|http_post_fields|http_put_data|http_put_file|http_put_stream|http_redirect|http_request|http_request_body_encode|' +
+ 'http_request_method_exists|http_request_method_name|http_request_method_register|http_request_method_unregister|http_response_code|' +
+ 'http_send_content_disposition|http_send_content_type|http_send_data|http_send_file|http_send_last_modified|http_send_status|' +
+ 'http_send_stream|http_support|http_throttle|httpdeflatestream|httpdeflatestream_construct|httpdeflatestream_factory|' +
+ 'httpdeflatestream_finish|httpdeflatestream_flush|httpdeflatestream_update|httpinflatestream|httpinflatestream_construct|' +
+ 'httpinflatestream_factory|httpinflatestream_finish|httpinflatestream_flush|httpinflatestream_update|httpmessage|httpmessage_addheaders|' +
+ 'httpmessage_construct|httpmessage_detach|httpmessage_factory|httpmessage_fromenv|httpmessage_fromstring|httpmessage_getbody|' +
+ 'httpmessage_getheader|httpmessage_getheaders|httpmessage_gethttpversion|httpmessage_getparentmessage|httpmessage_getrequestmethod|' +
+ 'httpmessage_getrequesturl|httpmessage_getresponsecode|httpmessage_getresponsestatus|httpmessage_gettype|httpmessage_guesscontenttype|' +
+ 'httpmessage_prepend|httpmessage_reverse|httpmessage_send|httpmessage_setbody|httpmessage_setheaders|httpmessage_sethttpversion|' +
+ 'httpmessage_setrequestmethod|httpmessage_setrequesturl|httpmessage_setresponsecode|httpmessage_setresponsestatus|httpmessage_settype|' +
+ 'httpmessage_tomessagetypeobject|httpmessage_tostring|httpquerystring|httpquerystring_construct|httpquerystring_get|httpquerystring_mod|' +
+ 'httpquerystring_set|httpquerystring_singleton|httpquerystring_toarray|httpquerystring_tostring|httpquerystring_xlate|httprequest|' +
+ 'httprequest_addcookies|httprequest_addheaders|httprequest_addpostfields|httprequest_addpostfile|httprequest_addputdata|' +
+ 'httprequest_addquerydata|httprequest_addrawpostdata|httprequest_addssloptions|httprequest_clearhistory|httprequest_construct|' +
+ 'httprequest_enablecookies|httprequest_getcontenttype|httprequest_getcookies|httprequest_getheaders|httprequest_gethistory|' +
+ 'httprequest_getmethod|httprequest_getoptions|httprequest_getpostfields|httprequest_getpostfiles|httprequest_getputdata|' +
+ 'httprequest_getputfile|httprequest_getquerydata|httprequest_getrawpostdata|httprequest_getrawrequestmessage|' +
+ 'httprequest_getrawresponsemessage|httprequest_getrequestmessage|httprequest_getresponsebody|httprequest_getresponsecode|' +
+ 'httprequest_getresponsecookies|httprequest_getresponsedata|httprequest_getresponseheader|httprequest_getresponseinfo|' +
+ 'httprequest_getresponsemessage|httprequest_getresponsestatus|httprequest_getssloptions|httprequest_geturl|httprequest_resetcookies|' +
+ 'httprequest_send|httprequest_setcontenttype|httprequest_setcookies|httprequest_setheaders|httprequest_setmethod|httprequest_setoptions|' +
+ 'httprequest_setpostfields|httprequest_setpostfiles|httprequest_setputdata|httprequest_setputfile|httprequest_setquerydata|' +
+ 'httprequest_setrawpostdata|httprequest_setssloptions|httprequest_seturl|httprequestpool|httprequestpool_attach|httprequestpool_construct|' +
+ 'httprequestpool_destruct|httprequestpool_detach|httprequestpool_getattachedrequests|httprequestpool_getfinishedrequests|' +
+ 'httprequestpool_reset|httprequestpool_send|httprequestpool_socketperform|httprequestpool_socketselect|httpresponse|httpresponse_capture|' +
+ 'httpresponse_getbuffersize|httpresponse_getcache|httpresponse_getcachecontrol|httpresponse_getcontentdisposition|' +
+ 'httpresponse_getcontenttype|httpresponse_getdata|httpresponse_getetag|httpresponse_getfile|httpresponse_getgzip|httpresponse_getheader|' +
+ 'httpresponse_getlastmodified|httpresponse_getrequestbody|httpresponse_getrequestbodystream|httpresponse_getrequestheaders|' +
+ 'httpresponse_getstream|httpresponse_getthrottledelay|httpresponse_guesscontenttype|httpresponse_redirect|httpresponse_send|' +
+ 'httpresponse_setbuffersize|httpresponse_setcache|httpresponse_setcachecontrol|httpresponse_setcontentdisposition|' +
+ 'httpresponse_setcontenttype|httpresponse_setdata|httpresponse_setetag|httpresponse_setfile|httpresponse_setgzip|httpresponse_setheader|' +
+ 'httpresponse_setlastmodified|httpresponse_setstream|httpresponse_setthrottledelay|httpresponse_status|hw_array2objrec|hw_changeobject|' +
+ 'hw_children|hw_childrenobj|hw_close|hw_connect|hw_connection_info|hw_cp|hw_deleteobject|hw_docbyanchor|hw_docbyanchorobj|' +
+ 'hw_document_attributes|hw_document_bodytag|hw_document_content|hw_document_setcontent|hw_document_size|hw_dummy|hw_edittext|hw_error|' +
+ 'hw_errormsg|hw_free_document|hw_getanchors|hw_getanchorsobj|hw_getandlock|hw_getchildcoll|hw_getchildcollobj|hw_getchilddoccoll|' +
+ 'hw_getchilddoccollobj|hw_getobject|hw_getobjectbyquery|hw_getobjectbyquerycoll|hw_getobjectbyquerycollobj|hw_getobjectbyqueryobj|' +
+ 'hw_getparents|hw_getparentsobj|hw_getrellink|hw_getremote|hw_getremotechildren|hw_getsrcbydestobj|hw_gettext|hw_getusername|hw_identify|' +
+ 'hw_incollections|hw_info|hw_inscoll|hw_insdoc|hw_insertanchors|hw_insertdocument|hw_insertobject|hw_mapid|hw_modifyobject|hw_mv|' +
+ 'hw_new_document|hw_objrec2array|hw_output_document|hw_pconnect|hw_pipedocument|hw_root|hw_setlinkroot|hw_stat|hw_unlock|hw_who|' +
+ 'hwapi_attribute|hwapi_attribute_key|hwapi_attribute_langdepvalue|hwapi_attribute_value|hwapi_attribute_values|hwapi_checkin|' +
+ 'hwapi_checkout|hwapi_children|hwapi_content|hwapi_content_mimetype|hwapi_content_read|hwapi_copy|hwapi_dbstat|hwapi_dcstat|' +
+ 'hwapi_dstanchors|hwapi_dstofsrcanchor|hwapi_error_count|hwapi_error_reason|hwapi_find|hwapi_ftstat|hwapi_hgcsp|hwapi_hwstat|' +
+ 'hwapi_identify|hwapi_info|hwapi_insert|hwapi_insertanchor|hwapi_insertcollection|hwapi_insertdocument|hwapi_link|hwapi_lock|hwapi_move|' +
+ 'hwapi_new_content|hwapi_object|hwapi_object_assign|hwapi_object_attreditable|hwapi_object_count|hwapi_object_insert|hwapi_object_new|' +
+ 'hwapi_object_remove|hwapi_object_title|hwapi_object_value|hwapi_objectbyanchor|hwapi_parents|hwapi_reason_description|hwapi_reason_type|' +
+ 'hwapi_remove|hwapi_replace|hwapi_setcommittedversion|hwapi_srcanchors|hwapi_srcsofdst|hwapi_unlock|hwapi_user|hwapi_userlist|hypot|' +
+ 'ibase_add_user|ibase_affected_rows|ibase_backup|ibase_blob_add|ibase_blob_cancel|ibase_blob_close|ibase_blob_create|ibase_blob_echo|' +
+ 'ibase_blob_get|ibase_blob_import|ibase_blob_info|ibase_blob_open|ibase_close|ibase_commit|ibase_commit_ret|ibase_connect|ibase_db_info|' +
+ 'ibase_delete_user|ibase_drop_db|ibase_errcode|ibase_errmsg|ibase_execute|ibase_fetch_assoc|ibase_fetch_object|ibase_fetch_row|' +
+ 'ibase_field_info|ibase_free_event_handler|ibase_free_query|ibase_free_result|ibase_gen_id|ibase_maintain_db|ibase_modify_user|' +
+ 'ibase_name_result|ibase_num_fields|ibase_num_params|ibase_param_info|ibase_pconnect|ibase_prepare|ibase_query|ibase_restore|' +
+ 'ibase_rollback|ibase_rollback_ret|ibase_server_info|ibase_service_attach|ibase_service_detach|ibase_set_event_handler|ibase_timefmt|' +
+ 'ibase_trans|ibase_wait_event|iconv|iconv_get_encoding|iconv_mime_decode|iconv_mime_decode_headers|iconv_mime_encode|iconv_set_encoding|' +
+ 'iconv_strlen|iconv_strpos|iconv_strrpos|iconv_substr|id3_get_frame_long_name|id3_get_frame_short_name|id3_get_genre_id|id3_get_genre_list|' +
+ 'id3_get_genre_name|id3_get_tag|id3_get_version|id3_remove_tag|id3_set_tag|id3v2attachedpictureframe|id3v2frame|id3v2tag|idate|' +
+ 'idn_to_ascii|idn_to_unicode|idn_to_utf8|ifx_affected_rows|ifx_blobinfile_mode|ifx_byteasvarchar|ifx_close|ifx_connect|ifx_copy_blob|' +
+ 'ifx_create_blob|ifx_create_char|ifx_do|ifx_error|ifx_errormsg|ifx_fetch_row|ifx_fieldproperties|ifx_fieldtypes|ifx_free_blob|' +
+ 'ifx_free_char|ifx_free_result|ifx_get_blob|ifx_get_char|ifx_getsqlca|ifx_htmltbl_result|ifx_nullformat|ifx_num_fields|ifx_num_rows|' +
+ 'ifx_pconnect|ifx_prepare|ifx_query|ifx_textasvarchar|ifx_update_blob|ifx_update_char|ifxus_close_slob|ifxus_create_slob|ifxus_free_slob|' +
+ 'ifxus_open_slob|ifxus_read_slob|ifxus_seek_slob|ifxus_tell_slob|ifxus_write_slob|ignore_user_abort|iis_add_server|iis_get_dir_security|' +
+ 'iis_get_script_map|iis_get_server_by_comment|iis_get_server_by_path|iis_get_server_rights|iis_get_service_state|iis_remove_server|' +
+ 'iis_set_app_settings|iis_set_dir_security|iis_set_script_map|iis_set_server_rights|iis_start_server|iis_start_service|iis_stop_server|' +
+ 'iis_stop_service|image2wbmp|image_type_to_extension|image_type_to_mime_type|imagealphablending|imageantialias|imagearc|imagechar|' +
+ 'imagecharup|imagecolorallocate|imagecolorallocatealpha|imagecolorat|imagecolorclosest|imagecolorclosestalpha|imagecolorclosesthwb|' +
+ 'imagecolordeallocate|imagecolorexact|imagecolorexactalpha|imagecolormatch|imagecolorresolve|imagecolorresolvealpha|imagecolorset|' +
+ 'imagecolorsforindex|imagecolorstotal|imagecolortransparent|imageconvolution|imagecopy|imagecopymerge|imagecopymergegray|' +
+ 'imagecopyresampled|imagecopyresized|imagecreate|imagecreatefromgd|imagecreatefromgd2|imagecreatefromgd2part|imagecreatefromgif|' +
+ 'imagecreatefromjpeg|imagecreatefrompng|imagecreatefromstring|imagecreatefromwbmp|imagecreatefromxbm|imagecreatefromxpm|' +
+ 'imagecreatetruecolor|imagedashedline|imagedestroy|imageellipse|imagefill|imagefilledarc|imagefilledellipse|imagefilledpolygon|' +
+ 'imagefilledrectangle|imagefilltoborder|imagefilter|imagefontheight|imagefontwidth|imageftbbox|imagefttext|imagegammacorrect|imagegd|' +
+ 'imagegd2|imagegif|imagegrabscreen|imagegrabwindow|imageinterlace|imageistruecolor|imagejpeg|imagelayereffect|imageline|imageloadfont|' +
+ 'imagepalettecopy|imagepng|imagepolygon|imagepsbbox|imagepsencodefont|imagepsextendfont|imagepsfreefont|imagepsloadfont|imagepsslantfont|' +
+ 'imagepstext|imagerectangle|imagerotate|imagesavealpha|imagesetbrush|imagesetpixel|imagesetstyle|imagesetthickness|imagesettile|' +
+ 'imagestring|imagestringup|imagesx|imagesy|imagetruecolortopalette|imagettfbbox|imagettftext|imagetypes|imagewbmp|imagexbm|imagick|' +
+ 'imagick_adaptiveblurimage|imagick_adaptiveresizeimage|imagick_adaptivesharpenimage|imagick_adaptivethresholdimage|imagick_addimage|' +
+ 'imagick_addnoiseimage|imagick_affinetransformimage|imagick_animateimages|imagick_annotateimage|imagick_appendimages|imagick_averageimages|' +
+ 'imagick_blackthresholdimage|imagick_blurimage|imagick_borderimage|imagick_charcoalimage|imagick_chopimage|imagick_clear|imagick_clipimage|' +
+ 'imagick_clippathimage|imagick_clone|imagick_clutimage|imagick_coalesceimages|imagick_colorfloodfillimage|imagick_colorizeimage|' +
+ 'imagick_combineimages|imagick_commentimage|imagick_compareimagechannels|imagick_compareimagelayers|imagick_compareimages|' +
+ 'imagick_compositeimage|imagick_construct|imagick_contrastimage|imagick_contraststretchimage|imagick_convolveimage|imagick_cropimage|' +
+ 'imagick_cropthumbnailimage|imagick_current|imagick_cyclecolormapimage|imagick_decipherimage|imagick_deconstructimages|' +
+ 'imagick_deleteimageartifact|imagick_despeckleimage|imagick_destroy|imagick_displayimage|imagick_displayimages|imagick_distortimage|' +
+ 'imagick_drawimage|imagick_edgeimage|imagick_embossimage|imagick_encipherimage|imagick_enhanceimage|imagick_equalizeimage|' +
+ 'imagick_evaluateimage|imagick_extentimage|imagick_flattenimages|imagick_flipimage|imagick_floodfillpaintimage|imagick_flopimage|' +
+ 'imagick_frameimage|imagick_fximage|imagick_gammaimage|imagick_gaussianblurimage|imagick_getcolorspace|imagick_getcompression|' +
+ 'imagick_getcompressionquality|imagick_getcopyright|imagick_getfilename|imagick_getfont|imagick_getformat|imagick_getgravity|' +
+ 'imagick_gethomeurl|imagick_getimage|imagick_getimagealphachannel|imagick_getimageartifact|imagick_getimagebackgroundcolor|' +
+ 'imagick_getimageblob|imagick_getimageblueprimary|imagick_getimagebordercolor|imagick_getimagechanneldepth|' +
+ 'imagick_getimagechanneldistortion|imagick_getimagechanneldistortions|imagick_getimagechannelextrema|imagick_getimagechannelmean|' +
+ 'imagick_getimagechannelrange|imagick_getimagechannelstatistics|imagick_getimageclipmask|imagick_getimagecolormapcolor|' +
+ 'imagick_getimagecolors|imagick_getimagecolorspace|imagick_getimagecompose|imagick_getimagecompression|imagick_getimagecompressionquality|' +
+ 'imagick_getimagedelay|imagick_getimagedepth|imagick_getimagedispose|imagick_getimagedistortion|imagick_getimageextrema|' +
+ 'imagick_getimagefilename|imagick_getimageformat|imagick_getimagegamma|imagick_getimagegeometry|imagick_getimagegravity|' +
+ 'imagick_getimagegreenprimary|imagick_getimageheight|imagick_getimagehistogram|imagick_getimageindex|imagick_getimageinterlacescheme|' +
+ 'imagick_getimageinterpolatemethod|imagick_getimageiterations|imagick_getimagelength|imagick_getimagemagicklicense|imagick_getimagematte|' +
+ 'imagick_getimagemattecolor|imagick_getimageorientation|imagick_getimagepage|imagick_getimagepixelcolor|imagick_getimageprofile|' +
+ 'imagick_getimageprofiles|imagick_getimageproperties|imagick_getimageproperty|imagick_getimageredprimary|imagick_getimageregion|' +
+ 'imagick_getimagerenderingintent|imagick_getimageresolution|imagick_getimagesblob|imagick_getimagescene|imagick_getimagesignature|' +
+ 'imagick_getimagesize|imagick_getimagetickspersecond|imagick_getimagetotalinkdensity|imagick_getimagetype|imagick_getimageunits|' +
+ 'imagick_getimagevirtualpixelmethod|imagick_getimagewhitepoint|imagick_getimagewidth|imagick_getinterlacescheme|imagick_getiteratorindex|' +
+ 'imagick_getnumberimages|imagick_getoption|imagick_getpackagename|imagick_getpage|imagick_getpixeliterator|imagick_getpixelregioniterator|' +
+ 'imagick_getpointsize|imagick_getquantumdepth|imagick_getquantumrange|imagick_getreleasedate|imagick_getresource|imagick_getresourcelimit|' +
+ 'imagick_getsamplingfactors|imagick_getsize|imagick_getsizeoffset|imagick_getversion|imagick_hasnextimage|imagick_haspreviousimage|' +
+ 'imagick_identifyimage|imagick_implodeimage|imagick_labelimage|imagick_levelimage|imagick_linearstretchimage|imagick_liquidrescaleimage|' +
+ 'imagick_magnifyimage|imagick_mapimage|imagick_mattefloodfillimage|imagick_medianfilterimage|imagick_mergeimagelayers|imagick_minifyimage|' +
+ 'imagick_modulateimage|imagick_montageimage|imagick_morphimages|imagick_mosaicimages|imagick_motionblurimage|imagick_negateimage|' +
+ 'imagick_newimage|imagick_newpseudoimage|imagick_nextimage|imagick_normalizeimage|imagick_oilpaintimage|imagick_opaquepaintimage|' +
+ 'imagick_optimizeimagelayers|imagick_orderedposterizeimage|imagick_paintfloodfillimage|imagick_paintopaqueimage|' +
+ 'imagick_painttransparentimage|imagick_pingimage|imagick_pingimageblob|imagick_pingimagefile|imagick_polaroidimage|imagick_posterizeimage|' +
+ 'imagick_previewimages|imagick_previousimage|imagick_profileimage|imagick_quantizeimage|imagick_quantizeimages|imagick_queryfontmetrics|' +
+ 'imagick_queryfonts|imagick_queryformats|imagick_radialblurimage|imagick_raiseimage|imagick_randomthresholdimage|imagick_readimage|' +
+ 'imagick_readimageblob|imagick_readimagefile|imagick_recolorimage|imagick_reducenoiseimage|imagick_removeimage|imagick_removeimageprofile|' +
+ 'imagick_render|imagick_resampleimage|imagick_resetimagepage|imagick_resizeimage|imagick_rollimage|imagick_rotateimage|' +
+ 'imagick_roundcorners|imagick_sampleimage|imagick_scaleimage|imagick_separateimagechannel|imagick_sepiatoneimage|' +
+ 'imagick_setbackgroundcolor|imagick_setcolorspace|imagick_setcompression|imagick_setcompressionquality|imagick_setfilename|' +
+ 'imagick_setfirstiterator|imagick_setfont|imagick_setformat|imagick_setgravity|imagick_setimage|imagick_setimagealphachannel|' +
+ 'imagick_setimageartifact|imagick_setimagebackgroundcolor|imagick_setimagebias|imagick_setimageblueprimary|imagick_setimagebordercolor|' +
+ 'imagick_setimagechanneldepth|imagick_setimageclipmask|imagick_setimagecolormapcolor|imagick_setimagecolorspace|imagick_setimagecompose|' +
+ 'imagick_setimagecompression|imagick_setimagecompressionquality|imagick_setimagedelay|imagick_setimagedepth|imagick_setimagedispose|' +
+ 'imagick_setimageextent|imagick_setimagefilename|imagick_setimageformat|imagick_setimagegamma|imagick_setimagegravity|' +
+ 'imagick_setimagegreenprimary|imagick_setimageindex|imagick_setimageinterlacescheme|imagick_setimageinterpolatemethod|' +
+ 'imagick_setimageiterations|imagick_setimagematte|imagick_setimagemattecolor|imagick_setimageopacity|imagick_setimageorientation|' +
+ 'imagick_setimagepage|imagick_setimageprofile|imagick_setimageproperty|imagick_setimageredprimary|imagick_setimagerenderingintent|' +
+ 'imagick_setimageresolution|imagick_setimagescene|imagick_setimagetickspersecond|imagick_setimagetype|imagick_setimageunits|' +
+ 'imagick_setimagevirtualpixelmethod|imagick_setimagewhitepoint|imagick_setinterlacescheme|imagick_setiteratorindex|imagick_setlastiterator|' +
+ 'imagick_setoption|imagick_setpage|imagick_setpointsize|imagick_setresolution|imagick_setresourcelimit|imagick_setsamplingfactors|' +
+ 'imagick_setsize|imagick_setsizeoffset|imagick_settype|imagick_shadeimage|imagick_shadowimage|imagick_sharpenimage|imagick_shaveimage|' +
+ 'imagick_shearimage|imagick_sigmoidalcontrastimage|imagick_sketchimage|imagick_solarizeimage|imagick_spliceimage|imagick_spreadimage|' +
+ 'imagick_steganoimage|imagick_stereoimage|imagick_stripimage|imagick_swirlimage|imagick_textureimage|imagick_thresholdimage|' +
+ 'imagick_thumbnailimage|imagick_tintimage|imagick_transformimage|imagick_transparentpaintimage|imagick_transposeimage|' +
+ 'imagick_transverseimage|imagick_trimimage|imagick_uniqueimagecolors|imagick_unsharpmaskimage|imagick_valid|imagick_vignetteimage|' +
+ 'imagick_waveimage|imagick_whitethresholdimage|imagick_writeimage|imagick_writeimagefile|imagick_writeimages|imagick_writeimagesfile|' +
+ 'imagickdraw|imagickdraw_affine|imagickdraw_annotation|imagickdraw_arc|imagickdraw_bezier|imagickdraw_circle|imagickdraw_clear|' +
+ 'imagickdraw_clone|imagickdraw_color|imagickdraw_comment|imagickdraw_composite|imagickdraw_construct|imagickdraw_destroy|' +
+ 'imagickdraw_ellipse|imagickdraw_getclippath|imagickdraw_getcliprule|imagickdraw_getclipunits|imagickdraw_getfillcolor|' +
+ 'imagickdraw_getfillopacity|imagickdraw_getfillrule|imagickdraw_getfont|imagickdraw_getfontfamily|imagickdraw_getfontsize|' +
+ 'imagickdraw_getfontstyle|imagickdraw_getfontweight|imagickdraw_getgravity|imagickdraw_getstrokeantialias|imagickdraw_getstrokecolor|' +
+ 'imagickdraw_getstrokedasharray|imagickdraw_getstrokedashoffset|imagickdraw_getstrokelinecap|imagickdraw_getstrokelinejoin|' +
+ 'imagickdraw_getstrokemiterlimit|imagickdraw_getstrokeopacity|imagickdraw_getstrokewidth|imagickdraw_gettextalignment|' +
+ 'imagickdraw_gettextantialias|imagickdraw_gettextdecoration|imagickdraw_gettextencoding|imagickdraw_gettextundercolor|' +
+ 'imagickdraw_getvectorgraphics|imagickdraw_line|imagickdraw_matte|imagickdraw_pathclose|imagickdraw_pathcurvetoabsolute|' +
+ 'imagickdraw_pathcurvetoquadraticbezierabsolute|imagickdraw_pathcurvetoquadraticbezierrelative|' +
+ 'imagickdraw_pathcurvetoquadraticbeziersmoothabsolute|imagickdraw_pathcurvetoquadraticbeziersmoothrelative|imagickdraw_pathcurvetorelative|' +
+ 'imagickdraw_pathcurvetosmoothabsolute|imagickdraw_pathcurvetosmoothrelative|imagickdraw_pathellipticarcabsolute|' +
+ 'imagickdraw_pathellipticarcrelative|imagickdraw_pathfinish|imagickdraw_pathlinetoabsolute|imagickdraw_pathlinetohorizontalabsolute|' +
+ 'imagickdraw_pathlinetohorizontalrelative|imagickdraw_pathlinetorelative|imagickdraw_pathlinetoverticalabsolute|' +
+ 'imagickdraw_pathlinetoverticalrelative|imagickdraw_pathmovetoabsolute|imagickdraw_pathmovetorelative|imagickdraw_pathstart|' +
+ 'imagickdraw_point|imagickdraw_polygon|imagickdraw_polyline|imagickdraw_pop|imagickdraw_popclippath|imagickdraw_popdefs|' +
+ 'imagickdraw_poppattern|imagickdraw_push|imagickdraw_pushclippath|imagickdraw_pushdefs|imagickdraw_pushpattern|imagickdraw_rectangle|' +
+ 'imagickdraw_render|imagickdraw_rotate|imagickdraw_roundrectangle|imagickdraw_scale|imagickdraw_setclippath|imagickdraw_setcliprule|' +
+ 'imagickdraw_setclipunits|imagickdraw_setfillalpha|imagickdraw_setfillcolor|imagickdraw_setfillopacity|imagickdraw_setfillpatternurl|' +
+ 'imagickdraw_setfillrule|imagickdraw_setfont|imagickdraw_setfontfamily|imagickdraw_setfontsize|imagickdraw_setfontstretch|' +
+ 'imagickdraw_setfontstyle|imagickdraw_setfontweight|imagickdraw_setgravity|imagickdraw_setstrokealpha|imagickdraw_setstrokeantialias|' +
+ 'imagickdraw_setstrokecolor|imagickdraw_setstrokedasharray|imagickdraw_setstrokedashoffset|imagickdraw_setstrokelinecap|' +
+ 'imagickdraw_setstrokelinejoin|imagickdraw_setstrokemiterlimit|imagickdraw_setstrokeopacity|imagickdraw_setstrokepatternurl|' +
+ 'imagickdraw_setstrokewidth|imagickdraw_settextalignment|imagickdraw_settextantialias|imagickdraw_settextdecoration|' +
+ 'imagickdraw_settextencoding|imagickdraw_settextundercolor|imagickdraw_setvectorgraphics|imagickdraw_setviewbox|imagickdraw_skewx|' +
+ 'imagickdraw_skewy|imagickdraw_translate|imagickpixel|imagickpixel_clear|imagickpixel_construct|imagickpixel_destroy|imagickpixel_getcolor|' +
+ 'imagickpixel_getcolorasstring|imagickpixel_getcolorcount|imagickpixel_getcolorvalue|imagickpixel_gethsl|imagickpixel_issimilar|' +
+ 'imagickpixel_setcolor|imagickpixel_setcolorvalue|imagickpixel_sethsl|imagickpixeliterator|imagickpixeliterator_clear|' +
+ 'imagickpixeliterator_construct|imagickpixeliterator_destroy|imagickpixeliterator_getcurrentiteratorrow|' +
+ 'imagickpixeliterator_getiteratorrow|imagickpixeliterator_getnextiteratorrow|imagickpixeliterator_getpreviousiteratorrow|' +
+ 'imagickpixeliterator_newpixeliterator|imagickpixeliterator_newpixelregioniterator|imagickpixeliterator_resetiterator|' +
+ 'imagickpixeliterator_setiteratorfirstrow|imagickpixeliterator_setiteratorlastrow|imagickpixeliterator_setiteratorrow|' +
+ 'imagickpixeliterator_synciterator|imap_8bit|imap_alerts|imap_append|imap_base64|imap_binary|imap_body|imap_bodystruct|imap_check|' +
+ 'imap_clearflag_full|imap_close|imap_create|imap_createmailbox|imap_delete|imap_deletemailbox|imap_errors|imap_expunge|imap_fetch_overview|' +
+ 'imap_fetchbody|imap_fetchheader|imap_fetchmime|imap_fetchstructure|imap_fetchtext|imap_gc|imap_get_quota|imap_get_quotaroot|imap_getacl|' +
+ 'imap_getmailboxes|imap_getsubscribed|imap_header|imap_headerinfo|imap_headers|imap_last_error|imap_list|imap_listmailbox|imap_listscan|' +
+ 'imap_listsubscribed|imap_lsub|imap_mail|imap_mail_compose|imap_mail_copy|imap_mail_move|imap_mailboxmsginfo|imap_mime_header_decode|' +
+ 'imap_msgno|imap_num_msg|imap_num_recent|imap_open|imap_ping|imap_qprint|imap_rename|imap_renamemailbox|imap_reopen|' +
+ 'imap_rfc822_parse_adrlist|imap_rfc822_parse_headers|imap_rfc822_write_address|imap_savebody|imap_scan|imap_scanmailbox|imap_search|' +
+ 'imap_set_quota|imap_setacl|imap_setflag_full|imap_sort|imap_status|imap_subscribe|imap_thread|imap_timeout|imap_uid|imap_undelete|' +
+ 'imap_unsubscribe|imap_utf7_decode|imap_utf7_encode|imap_utf8|implementsinterface|implode|import_request_variables|in_array|include|' +
+ 'include_once|inclued_get_data|inet_ntop|inet_pton|infiniteiterator|ingres_autocommit|ingres_autocommit_state|ingres_charset|ingres_close|' +
+ 'ingres_commit|ingres_connect|ingres_cursor|ingres_errno|ingres_error|ingres_errsqlstate|ingres_escape_string|ingres_execute|' +
+ 'ingres_fetch_array|ingres_fetch_assoc|ingres_fetch_object|ingres_fetch_proc_return|ingres_fetch_row|ingres_field_length|ingres_field_name|' +
+ 'ingres_field_nullable|ingres_field_precision|ingres_field_scale|ingres_field_type|ingres_free_result|ingres_next_error|ingres_num_fields|' +
+ 'ingres_num_rows|ingres_pconnect|ingres_prepare|ingres_query|ingres_result_seek|ingres_rollback|ingres_set_environment|' +
+ 'ingres_unbuffered_query|ini_alter|ini_get|ini_get_all|ini_restore|ini_set|innamespace|inotify_add_watch|inotify_init|inotify_queue_len|' +
+ 'inotify_read|inotify_rm_watch|interface_exists|intl_error_name|intl_get_error_code|intl_get_error_message|intl_is_failure|' +
+ 'intldateformatter|intval|invalidargumentexception|invoke|invokeargs|ip2long|iptcembed|iptcparse|is_a|is_array|is_bool|is_callable|is_dir|' +
+ 'is_double|is_executable|is_file|is_finite|is_float|is_infinite|is_int|is_integer|is_link|is_long|is_nan|is_null|is_numeric|is_object|' +
+ 'is_readable|is_real|is_resource|is_scalar|is_soap_fault|is_string|is_subclass_of|is_uploaded_file|is_writable|is_writeable|isabstract|' +
+ 'iscloneable|isdisabled|isfinal|isinstance|isinstantiable|isinterface|isinternal|isiterateable|isset|issubclassof|isuserdefined|iterator|' +
+ 'iterator_apply|iterator_count|iterator_to_array|iteratoraggregate|iteratoriterator|java_last_exception_clear|java_last_exception_get|' +
+ 'jddayofweek|jdmonthname|jdtofrench|jdtogregorian|jdtojewish|jdtojulian|jdtounix|jewishtojd|join|jpeg2wbmp|json_decode|json_encode|' +
+ 'json_last_error|jsonserializable|judy|judy_type|judy_version|juliantojd|kadm5_chpass_principal|kadm5_create_principal|' +
+ 'kadm5_delete_principal|kadm5_destroy|kadm5_flush|kadm5_get_policies|kadm5_get_principal|kadm5_get_principals|kadm5_init_with_password|' +
+ 'kadm5_modify_principal|key|krsort|ksort|lcfirst|lcg_value|lchgrp|lchown|ldap_8859_to_t61|ldap_add|ldap_bind|ldap_close|ldap_compare|' +
+ 'ldap_connect|ldap_count_entries|ldap_delete|ldap_dn2ufn|ldap_err2str|ldap_errno|ldap_error|ldap_explode_dn|ldap_first_attribute|' +
+ 'ldap_first_entry|ldap_first_reference|ldap_free_result|ldap_get_attributes|ldap_get_dn|ldap_get_entries|ldap_get_option|ldap_get_values|' +
+ 'ldap_get_values_len|ldap_list|ldap_mod_add|ldap_mod_del|ldap_mod_replace|ldap_modify|ldap_next_attribute|ldap_next_entry|' +
+ 'ldap_next_reference|ldap_parse_reference|ldap_parse_result|ldap_read|ldap_rename|ldap_sasl_bind|ldap_search|ldap_set_option|' +
+ 'ldap_set_rebind_proc|ldap_sort|ldap_start_tls|ldap_t61_to_8859|ldap_unbind|lengthexception|levenshtein|libxml_clear_errors|' +
+ 'libxml_disable_entity_loader|libxml_get_errors|libxml_get_last_error|libxml_set_streams_context|libxml_use_internal_errors|libxmlerror|' +
+ 'limititerator|link|linkinfo|list|locale|localeconv|localtime|log|log10|log1p|logicexception|long2ip|lstat|ltrim|lzf_compress|' +
+ 'lzf_decompress|lzf_optimized_for|m_checkstatus|m_completeauthorizations|m_connect|m_connectionerror|m_deletetrans|m_destroyconn|' +
+ 'm_destroyengine|m_getcell|m_getcellbynum|m_getcommadelimited|m_getheader|m_initconn|m_initengine|m_iscommadelimited|m_maxconntimeout|' +
+ 'm_monitor|m_numcolumns|m_numrows|m_parsecommadelimited|m_responsekeys|m_responseparam|m_returnstatus|m_setblocking|m_setdropfile|m_setip|' +
+ 'm_setssl|m_setssl_cafile|m_setssl_files|m_settimeout|m_sslcert_gen_hash|m_transactionssent|m_transinqueue|m_transkeyval|m_transnew|' +
+ 'm_transsend|m_uwait|m_validateidentifier|m_verifyconnection|m_verifysslcert|magic_quotes_runtime|mail|' +
+ 'mailparse_determine_best_xfer_encoding|mailparse_msg_create|mailparse_msg_extract_part|mailparse_msg_extract_part_file|' +
+ 'mailparse_msg_extract_whole_part_file|mailparse_msg_free|mailparse_msg_get_part|mailparse_msg_get_part_data|mailparse_msg_get_structure|' +
+ 'mailparse_msg_parse|mailparse_msg_parse_file|mailparse_rfc822_parse_addresses|mailparse_stream_encode|mailparse_uudecode_all|main|max|' +
+ 'maxdb_affected_rows|maxdb_autocommit|maxdb_bind_param|maxdb_bind_result|maxdb_change_user|maxdb_character_set_name|maxdb_client_encoding|' +
+ 'maxdb_close|maxdb_close_long_data|maxdb_commit|maxdb_connect|maxdb_connect_errno|maxdb_connect_error|maxdb_data_seek|maxdb_debug|' +
+ 'maxdb_disable_reads_from_master|maxdb_disable_rpl_parse|maxdb_dump_debug_info|maxdb_embedded_connect|maxdb_enable_reads_from_master|' +
+ 'maxdb_enable_rpl_parse|maxdb_errno|maxdb_error|maxdb_escape_string|maxdb_execute|maxdb_fetch|maxdb_fetch_array|maxdb_fetch_assoc|' +
+ 'maxdb_fetch_field|maxdb_fetch_field_direct|maxdb_fetch_fields|maxdb_fetch_lengths|maxdb_fetch_object|maxdb_fetch_row|maxdb_field_count|' +
+ 'maxdb_field_seek|maxdb_field_tell|maxdb_free_result|maxdb_get_client_info|maxdb_get_client_version|maxdb_get_host_info|maxdb_get_metadata|' +
+ 'maxdb_get_proto_info|maxdb_get_server_info|maxdb_get_server_version|maxdb_info|maxdb_init|maxdb_insert_id|maxdb_kill|maxdb_master_query|' +
+ 'maxdb_more_results|maxdb_multi_query|maxdb_next_result|maxdb_num_fields|maxdb_num_rows|maxdb_options|maxdb_param_count|maxdb_ping|' +
+ 'maxdb_prepare|maxdb_query|maxdb_real_connect|maxdb_real_escape_string|maxdb_real_query|maxdb_report|maxdb_rollback|' +
+ 'maxdb_rpl_parse_enabled|maxdb_rpl_probe|maxdb_rpl_query_type|maxdb_select_db|maxdb_send_long_data|maxdb_send_query|maxdb_server_end|' +
+ 'maxdb_server_init|maxdb_set_opt|maxdb_sqlstate|maxdb_ssl_set|maxdb_stat|maxdb_stmt_affected_rows|maxdb_stmt_bind_param|' +
+ 'maxdb_stmt_bind_result|maxdb_stmt_close|maxdb_stmt_close_long_data|maxdb_stmt_data_seek|maxdb_stmt_errno|maxdb_stmt_error|' +
+ 'maxdb_stmt_execute|maxdb_stmt_fetch|maxdb_stmt_free_result|maxdb_stmt_init|maxdb_stmt_num_rows|maxdb_stmt_param_count|maxdb_stmt_prepare|' +
+ 'maxdb_stmt_reset|maxdb_stmt_result_metadata|maxdb_stmt_send_long_data|maxdb_stmt_sqlstate|maxdb_stmt_store_result|maxdb_store_result|' +
+ 'maxdb_thread_id|maxdb_thread_safe|maxdb_use_result|maxdb_warning_count|mb_check_encoding|mb_convert_case|mb_convert_encoding|' +
+ 'mb_convert_kana|mb_convert_variables|mb_decode_mimeheader|mb_decode_numericentity|mb_detect_encoding|mb_detect_order|mb_encode_mimeheader|' +
+ 'mb_encode_numericentity|mb_encoding_aliases|mb_ereg|mb_ereg_match|mb_ereg_replace|mb_ereg_search|mb_ereg_search_getpos|' +
+ 'mb_ereg_search_getregs|mb_ereg_search_init|mb_ereg_search_pos|mb_ereg_search_regs|mb_ereg_search_setpos|mb_eregi|mb_eregi_replace|' +
+ 'mb_get_info|mb_http_input|mb_http_output|mb_internal_encoding|mb_language|mb_list_encodings|mb_output_handler|mb_parse_str|' +
+ 'mb_preferred_mime_name|mb_regex_encoding|mb_regex_set_options|mb_send_mail|mb_split|mb_strcut|mb_strimwidth|mb_stripos|mb_stristr|' +
+ 'mb_strlen|mb_strpos|mb_strrchr|mb_strrichr|mb_strripos|mb_strrpos|mb_strstr|mb_strtolower|mb_strtoupper|mb_strwidth|' +
+ 'mb_substitute_character|mb_substr|mb_substr_count|mcrypt_cbc|mcrypt_cfb|mcrypt_create_iv|mcrypt_decrypt|mcrypt_ecb|' +
+ 'mcrypt_enc_get_algorithms_name|mcrypt_enc_get_block_size|mcrypt_enc_get_iv_size|mcrypt_enc_get_key_size|mcrypt_enc_get_modes_name|' +
+ 'mcrypt_enc_get_supported_key_sizes|mcrypt_enc_is_block_algorithm|mcrypt_enc_is_block_algorithm_mode|mcrypt_enc_is_block_mode|' +
+ 'mcrypt_enc_self_test|mcrypt_encrypt|mcrypt_generic|mcrypt_generic_deinit|mcrypt_generic_end|mcrypt_generic_init|mcrypt_get_block_size|' +
+ 'mcrypt_get_cipher_name|mcrypt_get_iv_size|mcrypt_get_key_size|mcrypt_list_algorithms|mcrypt_list_modes|mcrypt_module_close|' +
+ 'mcrypt_module_get_algo_block_size|mcrypt_module_get_algo_key_size|mcrypt_module_get_supported_key_sizes|mcrypt_module_is_block_algorithm|' +
+ 'mcrypt_module_is_block_algorithm_mode|mcrypt_module_is_block_mode|mcrypt_module_open|mcrypt_module_self_test|mcrypt_ofb|md5|md5_file|' +
+ 'mdecrypt_generic|memcache|memcache_debug|memcached|memory_get_peak_usage|memory_get_usage|messageformatter|metaphone|method_exists|mhash|' +
+ 'mhash_count|mhash_get_block_size|mhash_get_hash_name|mhash_keygen_s2k|microtime|mime_content_type|min|ming_keypress|' +
+ 'ming_setcubicthreshold|ming_setscale|ming_setswfcompression|ming_useconstants|ming_useswfversion|mkdir|mktime|money_format|mongo|' +
+ 'mongobindata|mongocode|mongocollection|mongoconnectionexception|mongocursor|mongocursorexception|mongocursortimeoutexception|mongodate|' +
+ 'mongodb|mongodbref|mongoexception|mongogridfs|mongogridfscursor|mongogridfsexception|mongogridfsfile|mongoid|mongoint32|mongoint64|' +
+ 'mongomaxkey|mongominkey|mongoregex|mongotimestamp|move_uploaded_file|mpegfile|mqseries_back|mqseries_begin|mqseries_close|mqseries_cmit|' +
+ 'mqseries_conn|mqseries_connx|mqseries_disc|mqseries_get|mqseries_inq|mqseries_open|mqseries_put|mqseries_put1|mqseries_set|' +
+ 'mqseries_strerror|msession_connect|msession_count|msession_create|msession_destroy|msession_disconnect|msession_find|msession_get|' +
+ 'msession_get_array|msession_get_data|msession_inc|msession_list|msession_listvar|msession_lock|msession_plugin|msession_randstr|' +
+ 'msession_set|msession_set_array|msession_set_data|msession_timeout|msession_uniq|msession_unlock|msg_get_queue|msg_queue_exists|' +
+ 'msg_receive|msg_remove_queue|msg_send|msg_set_queue|msg_stat_queue|msql|msql_affected_rows|msql_close|msql_connect|msql_create_db|' +
+ 'msql_createdb|msql_data_seek|msql_db_query|msql_dbname|msql_drop_db|msql_error|msql_fetch_array|msql_fetch_field|msql_fetch_object|' +
+ 'msql_fetch_row|msql_field_flags|msql_field_len|msql_field_name|msql_field_seek|msql_field_table|msql_field_type|msql_fieldflags|' +
+ 'msql_fieldlen|msql_fieldname|msql_fieldtable|msql_fieldtype|msql_free_result|msql_list_dbs|msql_list_fields|msql_list_tables|' +
+ 'msql_num_fields|msql_num_rows|msql_numfields|msql_numrows|msql_pconnect|msql_query|msql_regcase|msql_result|msql_select_db|msql_tablename|' +
+ 'mssql_bind|mssql_close|mssql_connect|mssql_data_seek|mssql_execute|mssql_fetch_array|mssql_fetch_assoc|mssql_fetch_batch|' +
+ 'mssql_fetch_field|mssql_fetch_object|mssql_fetch_row|mssql_field_length|mssql_field_name|mssql_field_seek|mssql_field_type|' +
+ 'mssql_free_result|mssql_free_statement|mssql_get_last_message|mssql_guid_string|mssql_init|mssql_min_error_severity|' +
+ 'mssql_min_message_severity|mssql_next_result|mssql_num_fields|mssql_num_rows|mssql_pconnect|mssql_query|mssql_result|mssql_rows_affected|' +
+ 'mssql_select_db|mt_getrandmax|mt_rand|mt_srand|multipleiterator|mysql_affected_rows|mysql_client_encoding|mysql_close|mysql_connect|' +
+ 'mysql_create_db|mysql_data_seek|mysql_db_name|mysql_db_query|mysql_drop_db|mysql_errno|mysql_error|mysql_escape_string|mysql_fetch_array|' +
+ 'mysql_fetch_assoc|mysql_fetch_field|mysql_fetch_lengths|mysql_fetch_object|mysql_fetch_row|mysql_field_flags|mysql_field_len|' +
+ 'mysql_field_name|mysql_field_seek|mysql_field_table|mysql_field_type|mysql_free_result|mysql_get_client_info|mysql_get_host_info|' +
+ 'mysql_get_proto_info|mysql_get_server_info|mysql_info|mysql_insert_id|mysql_list_dbs|mysql_list_fields|mysql_list_processes|' +
+ 'mysql_list_tables|mysql_num_fields|mysql_num_rows|mysql_pconnect|mysql_ping|mysql_query|mysql_real_escape_string|mysql_result|' +
+ 'mysql_select_db|mysql_set_charset|mysql_stat|mysql_tablename|mysql_thread_id|mysql_unbuffered_query|mysqli|mysqli_affected_rows|' +
+ 'mysqli_autocommit|mysqli_bind_param|mysqli_bind_result|mysqli_cache_stats|mysqli_change_user|mysqli_character_set_name|' +
+ 'mysqli_client_encoding|mysqli_close|mysqli_commit|mysqli_connect|mysqli_connect_errno|mysqli_connect_error|mysqli_data_seek|' +
+ 'mysqli_debug|mysqli_disable_reads_from_master|mysqli_disable_rpl_parse|mysqli_driver|mysqli_dump_debug_info|mysqli_embedded_server_end|' +
+ 'mysqli_embedded_server_start|mysqli_enable_reads_from_master|mysqli_enable_rpl_parse|mysqli_errno|mysqli_error|mysqli_escape_string|' +
+ 'mysqli_execute|mysqli_fetch|mysqli_fetch_all|mysqli_fetch_array|mysqli_fetch_assoc|mysqli_fetch_field|mysqli_fetch_field_direct|' +
+ 'mysqli_fetch_fields|mysqli_fetch_lengths|mysqli_fetch_object|mysqli_fetch_row|mysqli_field_count|mysqli_field_seek|mysqli_field_tell|' +
+ 'mysqli_free_result|mysqli_get_charset|mysqli_get_client_info|mysqli_get_client_stats|mysqli_get_client_version|mysqli_get_connection_stats|' +
+ 'mysqli_get_host_info|mysqli_get_metadata|mysqli_get_proto_info|mysqli_get_server_info|mysqli_get_server_version|mysqli_get_warnings|' +
+ 'mysqli_info|mysqli_init|mysqli_insert_id|mysqli_kill|mysqli_link_construct|mysqli_master_query|mysqli_more_results|mysqli_multi_query|' +
+ 'mysqli_next_result|mysqli_num_fields|mysqli_num_rows|mysqli_options|mysqli_param_count|mysqli_ping|mysqli_poll|mysqli_prepare|' +
+ 'mysqli_query|mysqli_real_connect|mysqli_real_escape_string|mysqli_real_query|mysqli_reap_async_query|mysqli_refresh|mysqli_report|' +
+ 'mysqli_result|mysqli_rollback|mysqli_rpl_parse_enabled|mysqli_rpl_probe|mysqli_rpl_query_type|mysqli_select_db|mysqli_send_long_data|' +
+ 'mysqli_send_query|mysqli_set_charset|mysqli_set_local_infile_default|mysqli_set_local_infile_handler|mysqli_set_opt|mysqli_slave_query|' +
+ 'mysqli_sqlstate|mysqli_ssl_set|mysqli_stat|mysqli_stmt|mysqli_stmt_affected_rows|mysqli_stmt_attr_get|mysqli_stmt_attr_set|' +
+ 'mysqli_stmt_bind_param|mysqli_stmt_bind_result|mysqli_stmt_close|mysqli_stmt_data_seek|mysqli_stmt_errno|mysqli_stmt_error|' +
+ 'mysqli_stmt_execute|mysqli_stmt_fetch|mysqli_stmt_field_count|mysqli_stmt_free_result|mysqli_stmt_get_result|mysqli_stmt_get_warnings|' +
+ 'mysqli_stmt_init|mysqli_stmt_insert_id|mysqli_stmt_next_result|mysqli_stmt_num_rows|mysqli_stmt_param_count|mysqli_stmt_prepare|' +
+ 'mysqli_stmt_reset|mysqli_stmt_result_metadata|mysqli_stmt_send_long_data|mysqli_stmt_sqlstate|mysqli_stmt_store_result|mysqli_store_result|' +
+ 'mysqli_thread_id|mysqli_thread_safe|mysqli_use_result|mysqli_warning|mysqli_warning_count|mysqlnd_ms_get_stats|' +
+ 'mysqlnd_ms_query_is_select|mysqlnd_ms_set_user_pick_server|mysqlnd_qc_change_handler|mysqlnd_qc_clear_cache|mysqlnd_qc_get_cache_info|' +
+ 'mysqlnd_qc_get_core_stats|mysqlnd_qc_get_handler|mysqlnd_qc_get_query_trace_log|mysqlnd_qc_set_user_handlers|natcasesort|natsort|' +
+ 'ncurses_addch|ncurses_addchnstr|ncurses_addchstr|ncurses_addnstr|ncurses_addstr|ncurses_assume_default_colors|ncurses_attroff|' +
+ 'ncurses_attron|ncurses_attrset|ncurses_baudrate|ncurses_beep|ncurses_bkgd|ncurses_bkgdset|ncurses_border|ncurses_bottom_panel|' +
+ 'ncurses_can_change_color|ncurses_cbreak|ncurses_clear|ncurses_clrtobot|ncurses_clrtoeol|ncurses_color_content|ncurses_color_set|' +
+ 'ncurses_curs_set|ncurses_def_prog_mode|ncurses_def_shell_mode|ncurses_define_key|ncurses_del_panel|ncurses_delay_output|ncurses_delch|' +
+ 'ncurses_deleteln|ncurses_delwin|ncurses_doupdate|ncurses_echo|ncurses_echochar|ncurses_end|ncurses_erase|ncurses_erasechar|ncurses_filter|' +
+ 'ncurses_flash|ncurses_flushinp|ncurses_getch|ncurses_getmaxyx|ncurses_getmouse|ncurses_getyx|ncurses_halfdelay|ncurses_has_colors|' +
+ 'ncurses_has_ic|ncurses_has_il|ncurses_has_key|ncurses_hide_panel|ncurses_hline|ncurses_inch|ncurses_init|ncurses_init_color|' +
+ 'ncurses_init_pair|ncurses_insch|ncurses_insdelln|ncurses_insertln|ncurses_insstr|ncurses_instr|ncurses_isendwin|ncurses_keyok|' +
+ 'ncurses_keypad|ncurses_killchar|ncurses_longname|ncurses_meta|ncurses_mouse_trafo|ncurses_mouseinterval|ncurses_mousemask|ncurses_move|' +
+ 'ncurses_move_panel|ncurses_mvaddch|ncurses_mvaddchnstr|ncurses_mvaddchstr|ncurses_mvaddnstr|ncurses_mvaddstr|ncurses_mvcur|' +
+ 'ncurses_mvdelch|ncurses_mvgetch|ncurses_mvhline|ncurses_mvinch|ncurses_mvvline|ncurses_mvwaddstr|ncurses_napms|ncurses_new_panel|' +
+ 'ncurses_newpad|ncurses_newwin|ncurses_nl|ncurses_nocbreak|ncurses_noecho|ncurses_nonl|ncurses_noqiflush|ncurses_noraw|' +
+ 'ncurses_pair_content|ncurses_panel_above|ncurses_panel_below|ncurses_panel_window|ncurses_pnoutrefresh|ncurses_prefresh|ncurses_putp|' +
+ 'ncurses_qiflush|ncurses_raw|ncurses_refresh|ncurses_replace_panel|ncurses_reset_prog_mode|ncurses_reset_shell_mode|ncurses_resetty|' +
+ 'ncurses_savetty|ncurses_scr_dump|ncurses_scr_init|ncurses_scr_restore|ncurses_scr_set|ncurses_scrl|ncurses_show_panel|ncurses_slk_attr|' +
+ 'ncurses_slk_attroff|ncurses_slk_attron|ncurses_slk_attrset|ncurses_slk_clear|ncurses_slk_color|ncurses_slk_init|ncurses_slk_noutrefresh|' +
+ 'ncurses_slk_refresh|ncurses_slk_restore|ncurses_slk_set|ncurses_slk_touch|ncurses_standend|ncurses_standout|ncurses_start_color|' +
+ 'ncurses_termattrs|ncurses_termname|ncurses_timeout|ncurses_top_panel|ncurses_typeahead|ncurses_ungetch|ncurses_ungetmouse|' +
+ 'ncurses_update_panels|ncurses_use_default_colors|ncurses_use_env|ncurses_use_extended_names|ncurses_vidattr|ncurses_vline|ncurses_waddch|' +
+ 'ncurses_waddstr|ncurses_wattroff|ncurses_wattron|ncurses_wattrset|ncurses_wborder|ncurses_wclear|ncurses_wcolor_set|ncurses_werase|' +
+ 'ncurses_wgetch|ncurses_whline|ncurses_wmouse_trafo|ncurses_wmove|ncurses_wnoutrefresh|ncurses_wrefresh|ncurses_wstandend|' +
+ 'ncurses_wstandout|ncurses_wvline|newinstance|newinstanceargs|newt_bell|newt_button|newt_button_bar|newt_centered_window|newt_checkbox|' +
+ 'newt_checkbox_get_value|newt_checkbox_set_flags|newt_checkbox_set_value|newt_checkbox_tree|newt_checkbox_tree_add_item|' +
+ 'newt_checkbox_tree_find_item|newt_checkbox_tree_get_current|newt_checkbox_tree_get_entry_value|newt_checkbox_tree_get_multi_selection|' +
+ 'newt_checkbox_tree_get_selection|newt_checkbox_tree_multi|newt_checkbox_tree_set_current|newt_checkbox_tree_set_entry|' +
+ 'newt_checkbox_tree_set_entry_value|newt_checkbox_tree_set_width|newt_clear_key_buffer|newt_cls|newt_compact_button|' +
+ 'newt_component_add_callback|newt_component_takes_focus|newt_create_grid|newt_cursor_off|newt_cursor_on|newt_delay|newt_draw_form|' +
+ 'newt_draw_root_text|newt_entry|newt_entry_get_value|newt_entry_set|newt_entry_set_filter|newt_entry_set_flags|newt_finished|newt_form|' +
+ 'newt_form_add_component|newt_form_add_components|newt_form_add_hot_key|newt_form_destroy|newt_form_get_current|newt_form_run|' +
+ 'newt_form_set_background|newt_form_set_height|newt_form_set_size|newt_form_set_timer|newt_form_set_width|newt_form_watch_fd|' +
+ 'newt_get_screen_size|newt_grid_add_components_to_form|newt_grid_basic_window|newt_grid_free|newt_grid_get_size|newt_grid_h_close_stacked|' +
+ 'newt_grid_h_stacked|newt_grid_place|newt_grid_set_field|newt_grid_simple_window|newt_grid_v_close_stacked|newt_grid_v_stacked|' +
+ 'newt_grid_wrapped_window|newt_grid_wrapped_window_at|newt_init|newt_label|newt_label_set_text|newt_listbox|newt_listbox_append_entry|' +
+ 'newt_listbox_clear|newt_listbox_clear_selection|newt_listbox_delete_entry|newt_listbox_get_current|newt_listbox_get_selection|' +
+ 'newt_listbox_insert_entry|newt_listbox_item_count|newt_listbox_select_item|newt_listbox_set_current|newt_listbox_set_current_by_key|' +
+ 'newt_listbox_set_data|newt_listbox_set_entry|newt_listbox_set_width|newt_listitem|newt_listitem_get_data|newt_listitem_set|' +
+ 'newt_open_window|newt_pop_help_line|newt_pop_window|newt_push_help_line|newt_radio_get_current|newt_radiobutton|newt_redraw_help_line|' +
+ 'newt_reflow_text|newt_refresh|newt_resize_screen|newt_resume|newt_run_form|newt_scale|newt_scale_set|newt_scrollbar_set|' +
+ 'newt_set_help_callback|newt_set_suspend_callback|newt_suspend|newt_textbox|newt_textbox_get_num_lines|newt_textbox_reflowed|' +
+ 'newt_textbox_set_height|newt_textbox_set_text|newt_vertical_scrollbar|newt_wait_for_key|newt_win_choice|newt_win_entries|newt_win_menu|' +
+ 'newt_win_message|newt_win_messagev|newt_win_ternary|next|ngettext|nl2br|nl_langinfo|norewinditerator|normalizer|notes_body|notes_copy_db|' +
+ 'notes_create_db|notes_create_note|notes_drop_db|notes_find_note|notes_header_info|notes_list_msgs|notes_mark_read|notes_mark_unread|' +
+ 'notes_nav_create|notes_search|notes_unread|notes_version|nsapi_request_headers|nsapi_response_headers|nsapi_virtual|nthmac|number_format|' +
+ 'numberformatter|oauth|oauth_get_sbs|oauth_urlencode|oauthexception|oauthprovider|ob_clean|ob_deflatehandler|ob_end_clean|ob_end_flush|' +
+ 'ob_etaghandler|ob_flush|ob_get_clean|ob_get_contents|ob_get_flush|ob_get_length|ob_get_level|ob_get_status|ob_gzhandler|ob_iconv_handler|' +
+ 'ob_implicit_flush|ob_inflatehandler|ob_list_handlers|ob_start|ob_tidyhandler|oci_bind_array_by_name|oci_bind_by_name|oci_cancel|' +
+ 'oci_client_version|oci_close|oci_collection_append|oci_collection_assign|oci_collection_element_assign|oci_collection_element_get|' +
+ 'oci_collection_free|oci_collection_max|oci_collection_size|oci_collection_trim|oci_commit|oci_connect|oci_define_by_name|oci_error|' +
+ 'oci_execute|oci_fetch|oci_fetch_all|oci_fetch_array|oci_fetch_assoc|oci_fetch_object|oci_fetch_row|oci_field_is_null|oci_field_name|' +
+ 'oci_field_precision|oci_field_scale|oci_field_size|oci_field_type|oci_field_type_raw|oci_free_statement|oci_internal_debug|oci_lob_append|' +
+ 'oci_lob_close|oci_lob_copy|oci_lob_eof|oci_lob_erase|oci_lob_export|oci_lob_flush|oci_lob_free|oci_lob_getbuffering|oci_lob_import|' +
+ 'oci_lob_is_equal|oci_lob_load|oci_lob_read|oci_lob_rewind|oci_lob_save|oci_lob_savefile|oci_lob_seek|oci_lob_setbuffering|oci_lob_size|' +
+ 'oci_lob_tell|oci_lob_truncate|oci_lob_write|oci_lob_writetemporary|oci_lob_writetofile|oci_new_collection|oci_new_connect|oci_new_cursor|' +
+ 'oci_new_descriptor|oci_num_fields|oci_num_rows|oci_parse|oci_password_change|oci_pconnect|oci_result|oci_rollback|oci_server_version|' +
+ 'oci_set_action|oci_set_client_identifier|oci_set_client_info|oci_set_edition|oci_set_module_name|oci_set_prefetch|oci_statement_type|' +
+ 'ocibindbyname|ocicancel|ocicloselob|ocicollappend|ocicollassign|ocicollassignelem|ocicollgetelem|ocicollmax|ocicollsize|ocicolltrim|' +
+ 'ocicolumnisnull|ocicolumnname|ocicolumnprecision|ocicolumnscale|ocicolumnsize|ocicolumntype|ocicolumntyperaw|ocicommit|ocidefinebyname|' +
+ 'ocierror|ociexecute|ocifetch|ocifetchinto|ocifetchstatement|ocifreecollection|ocifreecursor|ocifreedesc|ocifreestatement|ociinternaldebug|' +
+ 'ociloadlob|ocilogoff|ocilogon|ocinewcollection|ocinewcursor|ocinewdescriptor|ocinlogon|ocinumcols|ociparse|ociplogon|ociresult|' +
+ 'ocirollback|ocirowcount|ocisavelob|ocisavelobfile|ociserverversion|ocisetprefetch|ocistatementtype|ociwritelobtofile|ociwritetemporarylob|' +
+ 'octdec|odbc_autocommit|odbc_binmode|odbc_close|odbc_close_all|odbc_columnprivileges|odbc_columns|odbc_commit|odbc_connect|odbc_cursor|' +
+ 'odbc_data_source|odbc_do|odbc_error|odbc_errormsg|odbc_exec|odbc_execute|odbc_fetch_array|odbc_fetch_into|odbc_fetch_object|' +
+ 'odbc_fetch_row|odbc_field_len|odbc_field_name|odbc_field_num|odbc_field_precision|odbc_field_scale|odbc_field_type|odbc_foreignkeys|' +
+ 'odbc_free_result|odbc_gettypeinfo|odbc_longreadlen|odbc_next_result|odbc_num_fields|odbc_num_rows|odbc_pconnect|odbc_prepare|' +
+ 'odbc_primarykeys|odbc_procedurecolumns|odbc_procedures|odbc_result|odbc_result_all|odbc_rollback|odbc_setoption|odbc_specialcolumns|' +
+ 'odbc_statistics|odbc_tableprivileges|odbc_tables|openal_buffer_create|openal_buffer_data|openal_buffer_destroy|openal_buffer_get|' +
+ 'openal_buffer_loadwav|openal_context_create|openal_context_current|openal_context_destroy|openal_context_process|openal_context_suspend|' +
+ 'openal_device_close|openal_device_open|openal_listener_get|openal_listener_set|openal_source_create|openal_source_destroy|' +
+ 'openal_source_get|openal_source_pause|openal_source_play|openal_source_rewind|openal_source_set|openal_source_stop|openal_stream|opendir|' +
+ 'openlog|openssl_cipher_iv_length|openssl_csr_export|openssl_csr_export_to_file|openssl_csr_get_public_key|openssl_csr_get_subject|' +
+ 'openssl_csr_new|openssl_csr_sign|openssl_decrypt|openssl_dh_compute_key|openssl_digest|openssl_encrypt|openssl_error_string|' +
+ 'openssl_free_key|openssl_get_cipher_methods|openssl_get_md_methods|openssl_get_privatekey|openssl_get_publickey|openssl_open|' +
+ 'openssl_pkcs12_export|openssl_pkcs12_export_to_file|openssl_pkcs12_read|openssl_pkcs7_decrypt|openssl_pkcs7_encrypt|openssl_pkcs7_sign|' +
+ 'openssl_pkcs7_verify|openssl_pkey_export|openssl_pkey_export_to_file|openssl_pkey_free|openssl_pkey_get_details|openssl_pkey_get_private|' +
+ 'openssl_pkey_get_public|openssl_pkey_new|openssl_private_decrypt|openssl_private_encrypt|openssl_public_decrypt|openssl_public_encrypt|' +
+ 'openssl_random_pseudo_bytes|openssl_seal|openssl_sign|openssl_verify|openssl_x509_check_private_key|openssl_x509_checkpurpose|' +
+ 'openssl_x509_export|openssl_x509_export_to_file|openssl_x509_free|openssl_x509_parse|openssl_x509_read|ord|outeriterator|' +
+ 'outofboundsexception|outofrangeexception|output_add_rewrite_var|output_reset_rewrite_vars|overflowexception|overload|override_function|' +
+ 'ovrimos_close|ovrimos_commit|ovrimos_connect|ovrimos_cursor|ovrimos_exec|ovrimos_execute|ovrimos_fetch_into|ovrimos_fetch_row|' +
+ 'ovrimos_field_len|ovrimos_field_name|ovrimos_field_num|ovrimos_field_type|ovrimos_free_result|ovrimos_longreadlen|ovrimos_num_fields|' +
+ 'ovrimos_num_rows|ovrimos_prepare|ovrimos_result|ovrimos_result_all|ovrimos_rollback|pack|parentiterator|parse_ini_file|parse_ini_string|' +
+ 'parse_str|parse_url|parsekit_compile_file|parsekit_compile_string|parsekit_func_arginfo|passthru|pathinfo|pclose|pcntl_alarm|pcntl_exec|' +
+ 'pcntl_fork|pcntl_getpriority|pcntl_setpriority|pcntl_signal|pcntl_signal_dispatch|pcntl_sigprocmask|pcntl_sigtimedwait|pcntl_sigwaitinfo|' +
+ 'pcntl_wait|pcntl_waitpid|pcntl_wexitstatus|pcntl_wifexited|pcntl_wifsignaled|pcntl_wifstopped|pcntl_wstopsig|pcntl_wtermsig|' +
+ 'pdf_activate_item|pdf_add_annotation|pdf_add_bookmark|pdf_add_launchlink|pdf_add_locallink|pdf_add_nameddest|pdf_add_note|pdf_add_outline|' +
+ 'pdf_add_pdflink|pdf_add_table_cell|pdf_add_textflow|pdf_add_thumbnail|pdf_add_weblink|pdf_arc|pdf_arcn|pdf_attach_file|pdf_begin_document|' +
+ 'pdf_begin_font|pdf_begin_glyph|pdf_begin_item|pdf_begin_layer|pdf_begin_page|pdf_begin_page_ext|pdf_begin_pattern|pdf_begin_template|' +
+ 'pdf_begin_template_ext|pdf_circle|pdf_clip|pdf_close|pdf_close_image|pdf_close_pdi|pdf_close_pdi_page|pdf_closepath|' +
+ 'pdf_closepath_fill_stroke|pdf_closepath_stroke|pdf_concat|pdf_continue_text|pdf_create_3dview|pdf_create_action|pdf_create_annotation|' +
+ 'pdf_create_bookmark|pdf_create_field|pdf_create_fieldgroup|pdf_create_gstate|pdf_create_pvf|pdf_create_textflow|pdf_curveto|' +
+ 'pdf_define_layer|pdf_delete|pdf_delete_pvf|pdf_delete_table|pdf_delete_textflow|pdf_encoding_set_char|pdf_end_document|pdf_end_font|' +
+ 'pdf_end_glyph|pdf_end_item|pdf_end_layer|pdf_end_page|pdf_end_page_ext|pdf_end_pattern|pdf_end_template|pdf_endpath|pdf_fill|' +
+ 'pdf_fill_imageblock|pdf_fill_pdfblock|pdf_fill_stroke|pdf_fill_textblock|pdf_findfont|pdf_fit_image|pdf_fit_pdi_page|pdf_fit_table|' +
+ 'pdf_fit_textflow|pdf_fit_textline|pdf_get_apiname|pdf_get_buffer|pdf_get_errmsg|pdf_get_errnum|pdf_get_font|pdf_get_fontname|' +
+ 'pdf_get_fontsize|pdf_get_image_height|pdf_get_image_width|pdf_get_majorversion|pdf_get_minorversion|pdf_get_parameter|' +
+ 'pdf_get_pdi_parameter|pdf_get_pdi_value|pdf_get_value|pdf_info_font|pdf_info_matchbox|pdf_info_table|pdf_info_textflow|pdf_info_textline|' +
+ 'pdf_initgraphics|pdf_lineto|pdf_load_3ddata|pdf_load_font|pdf_load_iccprofile|pdf_load_image|pdf_makespotcolor|pdf_moveto|pdf_new|' +
+ 'pdf_open_ccitt|pdf_open_file|pdf_open_gif|pdf_open_image|pdf_open_image_file|pdf_open_jpeg|pdf_open_memory_image|pdf_open_pdi|' +
+ 'pdf_open_pdi_document|pdf_open_pdi_page|pdf_open_tiff|pdf_pcos_get_number|pdf_pcos_get_stream|pdf_pcos_get_string|pdf_place_image|' +
+ 'pdf_place_pdi_page|pdf_process_pdi|pdf_rect|pdf_restore|pdf_resume_page|pdf_rotate|pdf_save|pdf_scale|pdf_set_border_color|' +
+ 'pdf_set_border_dash|pdf_set_border_style|pdf_set_char_spacing|pdf_set_duration|pdf_set_gstate|pdf_set_horiz_scaling|pdf_set_info|' +
+ 'pdf_set_info_author|pdf_set_info_creator|pdf_set_info_keywords|pdf_set_info_subject|pdf_set_info_title|pdf_set_layer_dependency|' +
+ 'pdf_set_leading|pdf_set_parameter|pdf_set_text_matrix|pdf_set_text_pos|pdf_set_text_rendering|pdf_set_text_rise|pdf_set_value|' +
+ 'pdf_set_word_spacing|pdf_setcolor|pdf_setdash|pdf_setdashpattern|pdf_setflat|pdf_setfont|pdf_setgray|pdf_setgray_fill|pdf_setgray_stroke|' +
+ 'pdf_setlinecap|pdf_setlinejoin|pdf_setlinewidth|pdf_setmatrix|pdf_setmiterlimit|pdf_setpolydash|pdf_setrgbcolor|pdf_setrgbcolor_fill|' +
+ 'pdf_setrgbcolor_stroke|pdf_shading|pdf_shading_pattern|pdf_shfill|pdf_show|pdf_show_boxed|pdf_show_xy|pdf_skew|pdf_stringwidth|pdf_stroke|' +
+ 'pdf_suspend_page|pdf_translate|pdf_utf16_to_utf8|pdf_utf32_to_utf16|pdf_utf8_to_utf16|pdo|pdo_cubrid_schema|pdo_pgsqllobcreate|' +
+ 'pdo_pgsqllobopen|pdo_pgsqllobunlink|pdo_sqlitecreateaggregate|pdo_sqlitecreatefunction|pdoexception|pdostatement|pfsockopen|' +
+ 'pg_affected_rows|pg_cancel_query|pg_client_encoding|pg_close|pg_connect|pg_connection_busy|pg_connection_reset|pg_connection_status|' +
+ 'pg_convert|pg_copy_from|pg_copy_to|pg_dbname|pg_delete|pg_end_copy|pg_escape_bytea|pg_escape_string|pg_execute|pg_fetch_all|' +
+ 'pg_fetch_all_columns|pg_fetch_array|pg_fetch_assoc|pg_fetch_object|pg_fetch_result|pg_fetch_row|pg_field_is_null|pg_field_name|' +
+ 'pg_field_num|pg_field_prtlen|pg_field_size|pg_field_table|pg_field_type|pg_field_type_oid|pg_free_result|pg_get_notify|pg_get_pid|' +
+ 'pg_get_result|pg_host|pg_insert|pg_last_error|pg_last_notice|pg_last_oid|pg_lo_close|pg_lo_create|pg_lo_export|pg_lo_import|pg_lo_open|' +
+ 'pg_lo_read|pg_lo_read_all|pg_lo_seek|pg_lo_tell|pg_lo_unlink|pg_lo_write|pg_meta_data|pg_num_fields|pg_num_rows|pg_options|' +
+ 'pg_parameter_status|pg_pconnect|pg_ping|pg_port|pg_prepare|pg_put_line|pg_query|pg_query_params|pg_result_error|pg_result_error_field|' +
+ 'pg_result_seek|pg_result_status|pg_select|pg_send_execute|pg_send_prepare|pg_send_query|pg_send_query_params|pg_set_client_encoding|' +
+ 'pg_set_error_verbosity|pg_trace|pg_transaction_status|pg_tty|pg_unescape_bytea|pg_untrace|pg_update|pg_version|php_check_syntax|' +
+ 'php_ini_loaded_file|php_ini_scanned_files|php_logo_guid|php_sapi_name|php_strip_whitespace|php_uname|phpcredits|phpinfo|phpversion|pi|' +
+ 'png2wbmp|popen|pos|posix_access|posix_ctermid|posix_errno|posix_get_last_error|posix_getcwd|posix_getegid|posix_geteuid|posix_getgid|' +
+ 'posix_getgrgid|posix_getgrnam|posix_getgroups|posix_getlogin|posix_getpgid|posix_getpgrp|posix_getpid|posix_getppid|posix_getpwnam|' +
+ 'posix_getpwuid|posix_getrlimit|posix_getsid|posix_getuid|posix_initgroups|posix_isatty|posix_kill|posix_mkfifo|posix_mknod|posix_setegid|' +
+ 'posix_seteuid|posix_setgid|posix_setpgid|posix_setsid|posix_setuid|posix_strerror|posix_times|posix_ttyname|posix_uname|pow|preg_filter|' +
+ 'preg_grep|preg_last_error|preg_match|preg_match_all|preg_quote|preg_replace|preg_replace_callback|preg_split|prev|print|print_r|' +
+ 'printer_abort|printer_close|printer_create_brush|printer_create_dc|printer_create_font|printer_create_pen|printer_delete_brush|' +
+ 'printer_delete_dc|printer_delete_font|printer_delete_pen|printer_draw_bmp|printer_draw_chord|printer_draw_elipse|printer_draw_line|' +
+ 'printer_draw_pie|printer_draw_rectangle|printer_draw_roundrect|printer_draw_text|printer_end_doc|printer_end_page|printer_get_option|' +
+ 'printer_list|printer_logical_fontheight|printer_open|printer_select_brush|printer_select_font|printer_select_pen|printer_set_option|' +
+ 'printer_start_doc|printer_start_page|printer_write|printf|proc_close|proc_get_status|proc_nice|proc_open|proc_terminate|property_exists|' +
+ 'ps_add_bookmark|ps_add_launchlink|ps_add_locallink|ps_add_note|ps_add_pdflink|ps_add_weblink|ps_arc|ps_arcn|ps_begin_page|' +
+ 'ps_begin_pattern|ps_begin_template|ps_circle|ps_clip|ps_close|ps_close_image|ps_closepath|ps_closepath_stroke|ps_continue_text|ps_curveto|' +
+ 'ps_delete|ps_end_page|ps_end_pattern|ps_end_template|ps_fill|ps_fill_stroke|ps_findfont|ps_get_buffer|ps_get_parameter|ps_get_value|' +
+ 'ps_hyphenate|ps_include_file|ps_lineto|ps_makespotcolor|ps_moveto|ps_new|ps_open_file|ps_open_image|ps_open_image_file|' +
+ 'ps_open_memory_image|ps_place_image|ps_rect|ps_restore|ps_rotate|ps_save|ps_scale|ps_set_border_color|ps_set_border_dash|' +
+ 'ps_set_border_style|ps_set_info|ps_set_parameter|ps_set_text_pos|ps_set_value|ps_setcolor|ps_setdash|ps_setflat|ps_setfont|ps_setgray|' +
+ 'ps_setlinecap|ps_setlinejoin|ps_setlinewidth|ps_setmiterlimit|ps_setoverprintmode|ps_setpolydash|ps_shading|ps_shading_pattern|ps_shfill|' +
+ 'ps_show|ps_show2|ps_show_boxed|ps_show_xy|ps_show_xy2|ps_string_geometry|ps_stringwidth|ps_stroke|ps_symbol|ps_symbol_name|' +
+ 'ps_symbol_width|ps_translate|pspell_add_to_personal|pspell_add_to_session|pspell_check|pspell_clear_session|pspell_config_create|' +
+ 'pspell_config_data_dir|pspell_config_dict_dir|pspell_config_ignore|pspell_config_mode|pspell_config_personal|pspell_config_repl|' +
+ 'pspell_config_runtogether|pspell_config_save_repl|pspell_new|pspell_new_config|pspell_new_personal|pspell_save_wordlist|' +
+ 'pspell_store_replacement|pspell_suggest|putenv|px_close|px_create_fp|px_date2string|px_delete|px_delete_record|px_get_field|px_get_info|' +
+ 'px_get_parameter|px_get_record|px_get_schema|px_get_value|px_insert_record|px_new|px_numfields|px_numrecords|px_open_fp|px_put_record|' +
+ 'px_retrieve_record|px_set_blob_file|px_set_parameter|px_set_tablename|px_set_targetencoding|px_set_value|px_timestamp2string|' +
+ 'px_update_record|qdom_error|qdom_tree|quoted_printable_decode|quoted_printable_encode|quotemeta|rad2deg|radius_acct_open|' +
+ 'radius_add_server|radius_auth_open|radius_close|radius_config|radius_create_request|radius_cvt_addr|radius_cvt_int|radius_cvt_string|' +
+ 'radius_demangle|radius_demangle_mppe_key|radius_get_attr|radius_get_vendor_attr|radius_put_addr|radius_put_attr|radius_put_int|' +
+ 'radius_put_string|radius_put_vendor_addr|radius_put_vendor_attr|radius_put_vendor_int|radius_put_vendor_string|' +
+ 'radius_request_authenticator|radius_send_request|radius_server_secret|radius_strerror|rand|range|rangeexception|rar_wrapper_cache_stats|' +
+ 'rararchive|rarentry|rarexception|rawurldecode|rawurlencode|read_exif_data|readdir|readfile|readgzfile|readline|readline_add_history|' +
+ 'readline_callback_handler_install|readline_callback_handler_remove|readline_callback_read_char|readline_clear_history|' +
+ 'readline_completion_function|readline_info|readline_list_history|readline_on_new_line|readline_read_history|readline_redisplay|' +
+ 'readline_write_history|readlink|realpath|realpath_cache_get|realpath_cache_size|recode|recode_file|recode_string|recursivearrayiterator|' +
+ 'recursivecachingiterator|recursivecallbackfilteriterator|recursivedirectoryiterator|recursivefilteriterator|recursiveiterator|' +
+ 'recursiveiteratoriterator|recursiveregexiterator|recursivetreeiterator|reflection|reflectionclass|reflectionexception|reflectionextension|' +
+ 'reflectionfunction|reflectionfunctionabstract|reflectionmethod|reflectionobject|reflectionparameter|reflectionproperty|reflector|' +
+ 'regexiterator|register_shutdown_function|register_tick_function|rename|rename_function|require|require_once|reset|resetValue|' +
+ 'resourcebundle|restore_error_handler|restore_exception_handler|restore_include_path|return|rewind|rewinddir|rmdir|round|rpm_close|' +
+ 'rpm_get_tag|rpm_is_valid|rpm_open|rpm_version|rrd_create|rrd_error|rrd_fetch|rrd_first|rrd_graph|rrd_info|rrd_last|rrd_lastupdate|' +
+ 'rrd_restore|rrd_tune|rrd_update|rrd_xport|rrdcreator|rrdgraph|rrdupdater|rsort|rtrim|runkit_class_adopt|runkit_class_emancipate|' +
+ 'runkit_constant_add|runkit_constant_redefine|runkit_constant_remove|runkit_function_add|runkit_function_copy|runkit_function_redefine|' +
+ 'runkit_function_remove|runkit_function_rename|runkit_import|runkit_lint|runkit_lint_file|runkit_method_add|runkit_method_copy|' +
+ 'runkit_method_redefine|runkit_method_remove|runkit_method_rename|runkit_return_value_used|runkit_sandbox_output_handler|' +
+ 'runkit_superglobals|runtimeexception|samconnection_commit|samconnection_connect|samconnection_constructor|samconnection_disconnect|' +
+ 'samconnection_errno|samconnection_error|samconnection_isconnected|samconnection_peek|samconnection_peekall|samconnection_receive|' +
+ 'samconnection_remove|samconnection_rollback|samconnection_send|samconnection_setDebug|samconnection_subscribe|samconnection_unsubscribe|' +
+ 'sammessage_body|sammessage_constructor|sammessage_header|sca_createdataobject|sca_getservice|sca_localproxy_createdataobject|' +
+ 'sca_soapproxy_createdataobject|scandir|sdo_das_changesummary_beginlogging|sdo_das_changesummary_endlogging|' +
+ 'sdo_das_changesummary_getchangeddataobjects|sdo_das_changesummary_getchangetype|sdo_das_changesummary_getoldcontainer|' +
+ 'sdo_das_changesummary_getoldvalues|sdo_das_changesummary_islogging|sdo_das_datafactory_addpropertytotype|sdo_das_datafactory_addtype|' +
+ 'sdo_das_datafactory_getdatafactory|sdo_das_dataobject_getchangesummary|sdo_das_relational_applychanges|sdo_das_relational_construct|' +
+ 'sdo_das_relational_createrootdataobject|sdo_das_relational_executepreparedquery|sdo_das_relational_executequery|' +
+ 'sdo_das_setting_getlistindex|sdo_das_setting_getpropertyindex|sdo_das_setting_getpropertyname|sdo_das_setting_getvalue|' +
+ 'sdo_das_setting_isset|sdo_das_xml_addtypes|sdo_das_xml_create|sdo_das_xml_createdataobject|sdo_das_xml_createdocument|' +
+ 'sdo_das_xml_document_getrootdataobject|sdo_das_xml_document_getrootelementname|sdo_das_xml_document_getrootelementuri|' +
+ 'sdo_das_xml_document_setencoding|sdo_das_xml_document_setxmldeclaration|sdo_das_xml_document_setxmlversion|sdo_das_xml_loadfile|' +
+ 'sdo_das_xml_loadstring|sdo_das_xml_savefile|sdo_das_xml_savestring|sdo_datafactory_create|sdo_dataobject_clear|' +
+ 'sdo_dataobject_createdataobject|sdo_dataobject_getcontainer|sdo_dataobject_getsequence|sdo_dataobject_gettypename|' +
+ 'sdo_dataobject_gettypenamespaceuri|sdo_exception_getcause|sdo_list_insert|sdo_model_property_getcontainingtype|' +
+ 'sdo_model_property_getdefault|sdo_model_property_getname|sdo_model_property_gettype|sdo_model_property_iscontainment|' +
+ 'sdo_model_property_ismany|sdo_model_reflectiondataobject_construct|sdo_model_reflectiondataobject_export|' +
+ 'sdo_model_reflectiondataobject_getcontainmentproperty|sdo_model_reflectiondataobject_getinstanceproperties|' +
+ 'sdo_model_reflectiondataobject_gettype|sdo_model_type_getbasetype|sdo_model_type_getname|sdo_model_type_getnamespaceuri|' +
+ 'sdo_model_type_getproperties|sdo_model_type_getproperty|sdo_model_type_isabstracttype|sdo_model_type_isdatatype|sdo_model_type_isinstance|' +
+ 'sdo_model_type_isopentype|sdo_model_type_issequencedtype|sdo_sequence_getproperty|sdo_sequence_insert|sdo_sequence_move|seekableiterator|' +
+ 'sem_acquire|sem_get|sem_release|sem_remove|serializable|serialize|session_cache_expire|session_cache_limiter|session_commit|' +
+ 'session_decode|session_destroy|session_encode|session_get_cookie_params|session_id|session_is_registered|session_module_name|session_name|' +
+ 'session_pgsql_add_error|session_pgsql_get_error|session_pgsql_get_field|session_pgsql_reset|session_pgsql_set_field|session_pgsql_status|' +
+ 'session_regenerate_id|session_register|session_save_path|session_set_cookie_params|session_set_save_handler|session_start|' +
+ 'session_unregister|session_unset|session_write_close|setCounterClass|set_error_handler|set_exception_handler|set_file_buffer|' +
+ 'set_include_path|set_magic_quotes_runtime|set_socket_blocking|set_time_limit|setcookie|setlocale|setproctitle|setrawcookie|' +
+ 'setstaticpropertyvalue|setthreadtitle|settype|sha1|sha1_file|shell_exec|shm_attach|shm_detach|shm_get_var|shm_has_var|shm_put_var|' +
+ 'shm_remove|shm_remove_var|shmop_close|shmop_delete|shmop_open|shmop_read|shmop_size|shmop_write|show_source|shuffle|signeurlpaiement|' +
+ 'similar_text|simplexml_import_dom|simplexml_load_file|simplexml_load_string|simplexmlelement|simplexmliterator|sin|sinh|sizeof|sleep|snmp|' +
+ 'snmp2_get|snmp2_getnext|snmp2_real_walk|snmp2_set|snmp2_walk|snmp3_get|snmp3_getnext|snmp3_real_walk|snmp3_set|snmp3_walk|' +
+ 'snmp_get_quick_print|snmp_get_valueretrieval|snmp_read_mib|snmp_set_enum_print|snmp_set_oid_numeric_print|snmp_set_oid_output_format|' +
+ 'snmp_set_quick_print|snmp_set_valueretrieval|snmpget|snmpgetnext|snmprealwalk|snmpset|snmpwalk|snmpwalkoid|soapclient|soapfault|' +
+ 'soapheader|soapparam|soapserver|soapvar|socket_accept|socket_bind|socket_clear_error|socket_close|socket_connect|socket_create|' +
+ 'socket_create_listen|socket_create_pair|socket_get_option|socket_get_status|socket_getpeername|socket_getsockname|socket_last_error|' +
+ 'socket_listen|socket_read|socket_recv|socket_recvfrom|socket_select|socket_send|socket_sendto|socket_set_block|socket_set_blocking|' +
+ 'socket_set_nonblock|socket_set_option|socket_set_timeout|socket_shutdown|socket_strerror|socket_write|solr_get_version|solrclient|' +
+ 'solrclientexception|solrdocument|solrdocumentfield|solrexception|solrgenericresponse|solrillegalargumentexception|' +
+ 'solrillegaloperationexception|solrinputdocument|solrmodifiableparams|solrobject|solrparams|solrpingresponse|solrquery|solrqueryresponse|' +
+ 'solrresponse|solrupdateresponse|solrutils|sort|soundex|sphinxclient|spl_autoload|spl_autoload_call|spl_autoload_extensions|' +
+ 'spl_autoload_functions|spl_autoload_register|spl_autoload_unregister|spl_classes|spl_object_hash|splbool|spldoublylinkedlist|splenum|' +
+ 'splfileinfo|splfileobject|splfixedarray|splfloat|splheap|splint|split|spliti|splmaxheap|splminheap|splobjectstorage|splobserver|' +
+ 'splpriorityqueue|splqueue|splstack|splstring|splsubject|spltempfileobject|spoofchecker|sprintf|sql_regcase|sqlite3|sqlite3result|' +
+ 'sqlite3stmt|sqlite_array_query|sqlite_busy_timeout|sqlite_changes|sqlite_close|sqlite_column|sqlite_create_aggregate|' +
+ 'sqlite_create_function|sqlite_current|sqlite_error_string|sqlite_escape_string|sqlite_exec|sqlite_factory|sqlite_fetch_all|' +
+ 'sqlite_fetch_array|sqlite_fetch_column_types|sqlite_fetch_object|sqlite_fetch_single|sqlite_fetch_string|sqlite_field_name|' +
+ 'sqlite_has_more|sqlite_has_prev|sqlite_key|sqlite_last_error|sqlite_last_insert_rowid|sqlite_libencoding|sqlite_libversion|sqlite_next|' +
+ 'sqlite_num_fields|sqlite_num_rows|sqlite_open|sqlite_popen|sqlite_prev|sqlite_query|sqlite_rewind|sqlite_seek|sqlite_single_query|' +
+ 'sqlite_udf_decode_binary|sqlite_udf_encode_binary|sqlite_unbuffered_query|sqlite_valid|sqrt|srand|sscanf|ssdeep_fuzzy_compare|' +
+ 'ssdeep_fuzzy_hash|ssdeep_fuzzy_hash_filename|ssh2_auth_hostbased_file|ssh2_auth_none|ssh2_auth_password|ssh2_auth_pubkey_file|' +
+ 'ssh2_connect|ssh2_exec|ssh2_fetch_stream|ssh2_fingerprint|ssh2_methods_negotiated|ssh2_publickey_add|ssh2_publickey_init|' +
+ 'ssh2_publickey_list|ssh2_publickey_remove|ssh2_scp_recv|ssh2_scp_send|ssh2_sftp|ssh2_sftp_lstat|ssh2_sftp_mkdir|ssh2_sftp_readlink|' +
+ 'ssh2_sftp_realpath|ssh2_sftp_rename|ssh2_sftp_rmdir|ssh2_sftp_stat|ssh2_sftp_symlink|ssh2_sftp_unlink|ssh2_shell|ssh2_tunnel|stat|' +
+ 'stats_absolute_deviation|stats_cdf_beta|stats_cdf_binomial|stats_cdf_cauchy|stats_cdf_chisquare|stats_cdf_exponential|stats_cdf_f|' +
+ 'stats_cdf_gamma|stats_cdf_laplace|stats_cdf_logistic|stats_cdf_negative_binomial|stats_cdf_noncentral_chisquare|stats_cdf_noncentral_f|' +
+ 'stats_cdf_poisson|stats_cdf_t|stats_cdf_uniform|stats_cdf_weibull|stats_covariance|stats_den_uniform|stats_dens_beta|stats_dens_cauchy|' +
+ 'stats_dens_chisquare|stats_dens_exponential|stats_dens_f|stats_dens_gamma|stats_dens_laplace|stats_dens_logistic|' +
+ 'stats_dens_negative_binomial|stats_dens_normal|stats_dens_pmf_binomial|stats_dens_pmf_hypergeometric|stats_dens_pmf_poisson|stats_dens_t|' +
+ 'stats_dens_weibull|stats_harmonic_mean|stats_kurtosis|stats_rand_gen_beta|stats_rand_gen_chisquare|stats_rand_gen_exponential|' +
+ 'stats_rand_gen_f|stats_rand_gen_funiform|stats_rand_gen_gamma|stats_rand_gen_ibinomial|stats_rand_gen_ibinomial_negative|' +
+ 'stats_rand_gen_int|stats_rand_gen_ipoisson|stats_rand_gen_iuniform|stats_rand_gen_noncenral_chisquare|stats_rand_gen_noncentral_f|' +
+ 'stats_rand_gen_noncentral_t|stats_rand_gen_normal|stats_rand_gen_t|stats_rand_get_seeds|stats_rand_phrase_to_seeds|stats_rand_ranf|' +
+ 'stats_rand_setall|stats_skew|stats_standard_deviation|stats_stat_binomial_coef|stats_stat_correlation|stats_stat_gennch|' +
+ 'stats_stat_independent_t|stats_stat_innerproduct|stats_stat_noncentral_t|stats_stat_paired_t|stats_stat_percentile|stats_stat_powersum|' +
+ 'stats_variance|stomp|stomp_connect_error|stomp_version|stompexception|stompframe|str_getcsv|str_ireplace|str_pad|str_repeat|str_replace|' +
+ 'str_rot13|str_shuffle|str_split|str_word_count|strcasecmp|strchr|strcmp|strcoll|strcspn|stream_bucket_append|stream_bucket_make_writeable|' +
+ 'stream_bucket_new|stream_bucket_prepend|stream_context_create|stream_context_get_default|stream_context_get_options|' +
+ 'stream_context_get_params|stream_context_set_default|stream_context_set_option|stream_context_set_params|stream_copy_to_stream|' +
+ 'stream_encoding|stream_filter_append|stream_filter_prepend|stream_filter_register|stream_filter_remove|stream_get_contents|' +
+ 'stream_get_filters|stream_get_line|stream_get_meta_data|stream_get_transports|stream_get_wrappers|stream_is_local|' +
+ 'stream_notification_callback|stream_register_wrapper|stream_resolve_include_path|stream_select|stream_set_blocking|stream_set_read_buffer|' +
+ 'stream_set_timeout|stream_set_write_buffer|stream_socket_accept|stream_socket_client|stream_socket_enable_crypto|stream_socket_get_name|' +
+ 'stream_socket_pair|stream_socket_recvfrom|stream_socket_sendto|stream_socket_server|stream_socket_shutdown|stream_supports_lock|' +
+ 'stream_wrapper_register|stream_wrapper_restore|stream_wrapper_unregister|streamwrapper|strftime|strip_tags|stripcslashes|stripos|' +
+ 'stripslashes|stristr|strlen|strnatcasecmp|strnatcmp|strncasecmp|strncmp|strpbrk|strpos|strptime|strrchr|strrev|strripos|strrpos|strspn|' +
+ 'strstr|strtok|strtolower|strtotime|strtoupper|strtr|strval|substr|substr_compare|substr_count|substr_replace|svm|svmmodel|svn_add|' +
+ 'svn_auth_get_parameter|svn_auth_set_parameter|svn_blame|svn_cat|svn_checkout|svn_cleanup|svn_client_version|svn_commit|svn_delete|' +
+ 'svn_diff|svn_export|svn_fs_abort_txn|svn_fs_apply_text|svn_fs_begin_txn2|svn_fs_change_node_prop|svn_fs_check_path|' +
+ 'svn_fs_contents_changed|svn_fs_copy|svn_fs_delete|svn_fs_dir_entries|svn_fs_file_contents|svn_fs_file_length|svn_fs_is_dir|svn_fs_is_file|' +
+ 'svn_fs_make_dir|svn_fs_make_file|svn_fs_node_created_rev|svn_fs_node_prop|svn_fs_props_changed|svn_fs_revision_prop|svn_fs_revision_root|' +
+ 'svn_fs_txn_root|svn_fs_youngest_rev|svn_import|svn_log|svn_ls|svn_mkdir|svn_repos_create|svn_repos_fs|svn_repos_fs_begin_txn_for_commit|' +
+ 'svn_repos_fs_commit_txn|svn_repos_hotcopy|svn_repos_open|svn_repos_recover|svn_revert|svn_status|svn_update|swf_actiongeturl|' +
+ 'swf_actiongotoframe|swf_actiongotolabel|swf_actionnextframe|swf_actionplay|swf_actionprevframe|swf_actionsettarget|swf_actionstop|' +
+ 'swf_actiontogglequality|swf_actionwaitforframe|swf_addbuttonrecord|swf_addcolor|swf_closefile|swf_definebitmap|swf_definefont|' +
+ 'swf_defineline|swf_definepoly|swf_definerect|swf_definetext|swf_endbutton|swf_enddoaction|swf_endshape|swf_endsymbol|swf_fontsize|' +
+ 'swf_fontslant|swf_fonttracking|swf_getbitmapinfo|swf_getfontinfo|swf_getframe|swf_labelframe|swf_lookat|swf_modifyobject|swf_mulcolor|' +
+ 'swf_nextid|swf_oncondition|swf_openfile|swf_ortho|swf_ortho2|swf_perspective|swf_placeobject|swf_polarview|swf_popmatrix|swf_posround|' +
+ 'swf_pushmatrix|swf_removeobject|swf_rotate|swf_scale|swf_setfont|swf_setframe|swf_shapearc|swf_shapecurveto|swf_shapecurveto3|' +
+ 'swf_shapefillbitmapclip|swf_shapefillbitmaptile|swf_shapefilloff|swf_shapefillsolid|swf_shapelinesolid|swf_shapelineto|swf_shapemoveto|' +
+ 'swf_showframe|swf_startbutton|swf_startdoaction|swf_startshape|swf_startsymbol|swf_textwidth|swf_translate|swf_viewport|swfaction|' +
+ 'swfbitmap|swfbutton|swfdisplayitem|swffill|swffont|swffontchar|swfgradient|swfmorph|swfmovie|swfprebuiltclip|swfshape|swfsound|' +
+ 'swfsoundinstance|swfsprite|swftext|swftextfield|swfvideostream|swish_construct|swish_getmetalist|swish_getpropertylist|swish_prepare|' +
+ 'swish_query|swishresult_getmetalist|swishresult_stem|swishresults_getparsedwords|swishresults_getremovedstopwords|swishresults_nextresult|' +
+ 'swishresults_seekresult|swishsearch_execute|swishsearch_resetlimit|swishsearch_setlimit|swishsearch_setphrasedelimiter|' +
+ 'swishsearch_setsort|swishsearch_setstructure|sybase_affected_rows|sybase_close|sybase_connect|sybase_data_seek|' +
+ 'sybase_deadlock_retry_count|sybase_fetch_array|sybase_fetch_assoc|sybase_fetch_field|sybase_fetch_object|sybase_fetch_row|' +
+ 'sybase_field_seek|sybase_free_result|sybase_get_last_message|sybase_min_client_severity|sybase_min_error_severity|' +
+ 'sybase_min_message_severity|sybase_min_server_severity|sybase_num_fields|sybase_num_rows|sybase_pconnect|sybase_query|sybase_result|' +
+ 'sybase_select_db|sybase_set_message_handler|sybase_unbuffered_query|symlink|sys_get_temp_dir|sys_getloadavg|syslog|system|tag|tan|tanh|' +
+ 'tcpwrap_check|tempnam|textdomain|tidy|tidy_access_count|tidy_config_count|tidy_diagnose|tidy_error_count|tidy_get_error_buffer|' +
+ 'tidy_get_output|tidy_load_config|tidy_reset_config|tidy_save_config|tidy_set_encoding|tidy_setopt|tidy_warning_count|tidynode|time|' +
+ 'time_nanosleep|time_sleep_until|timezone_abbreviations_list|timezone_identifiers_list|timezone_location_get|timezone_name_from_abbr|' +
+ 'timezone_name_get|timezone_offset_get|timezone_open|timezone_transitions_get|timezone_version_get|tmpfile|token_get_all|token_name|' +
+ 'tokyotyrant|tokyotyrantquery|tokyotyranttable|tostring|tostring|touch|trait_exists|transliterator|traversable|trigger_error|trim|uasort|ucfirst|' +
+ 'ucwords|udm_add_search_limit|udm_alloc_agent|udm_alloc_agent_array|udm_api_version|udm_cat_list|udm_cat_path|udm_check_charset|' +
+ 'udm_check_stored|udm_clear_search_limits|udm_close_stored|udm_crc32|udm_errno|udm_error|udm_find|udm_free_agent|udm_free_ispell_data|' +
+ 'udm_free_res|udm_get_doc_count|udm_get_res_field|udm_get_res_param|udm_hash32|udm_load_ispell_data|udm_open_stored|udm_set_agent_param|' +
+ 'uksort|umask|underflowexception|unexpectedvalueexception|uniqid|unixtojd|unlink|unpack|unregister_tick_function|unserialize|unset|' +
+ 'urldecode|urlencode|use_soap_error_handler|user_error|usleep|usort|utf8_decode|utf8_encode|v8js|v8jsexception|var_dump|var_export|variant|' +
+ 'variant_abs|variant_add|variant_and|variant_cast|variant_cat|variant_cmp|variant_date_from_timestamp|variant_date_to_timestamp|' +
+ 'variant_div|variant_eqv|variant_fix|variant_get_type|variant_idiv|variant_imp|variant_int|variant_mod|variant_mul|variant_neg|variant_not|' +
+ 'variant_or|variant_pow|variant_round|variant_set|variant_set_type|variant_sub|variant_xor|version_compare|vfprintf|virtual|' +
+ 'vpopmail_add_alias_domain|vpopmail_add_alias_domain_ex|vpopmail_add_domain|vpopmail_add_domain_ex|vpopmail_add_user|vpopmail_alias_add|' +
+ 'vpopmail_alias_del|vpopmail_alias_del_domain|vpopmail_alias_get|vpopmail_alias_get_all|vpopmail_auth_user|vpopmail_del_domain|' +
+ 'vpopmail_del_domain_ex|vpopmail_del_user|vpopmail_error|vpopmail_passwd|vpopmail_set_user_quota|vprintf|vsprintf|w32api_deftype|' +
+ 'w32api_init_dtype|w32api_invoke_function|w32api_register_function|w32api_set_call_method|wddx_add_vars|wddx_deserialize|wddx_packet_end|' +
+ 'wddx_packet_start|wddx_serialize_value|wddx_serialize_vars|win32_continue_service|win32_create_service|win32_delete_service|' +
+ 'win32_get_last_control_message|win32_pause_service|win32_ps_list_procs|win32_ps_stat_mem|win32_ps_stat_proc|win32_query_service_status|' +
+ 'win32_set_service_status|win32_start_service|win32_start_service_ctrl_dispatcher|win32_stop_service|wincache_fcache_fileinfo|' +
+ 'wincache_fcache_meminfo|wincache_lock|wincache_ocache_fileinfo|wincache_ocache_meminfo|wincache_refresh_if_changed|' +
+ 'wincache_rplist_fileinfo|wincache_rplist_meminfo|wincache_scache_info|wincache_scache_meminfo|wincache_ucache_add|wincache_ucache_cas|' +
+ 'wincache_ucache_clear|wincache_ucache_dec|wincache_ucache_delete|wincache_ucache_exists|wincache_ucache_get|wincache_ucache_inc|' +
+ 'wincache_ucache_info|wincache_ucache_meminfo|wincache_ucache_set|wincache_unlock|wordwrap|xattr_get|xattr_list|xattr_remove|xattr_set|' +
+ 'xattr_supported|xdiff_file_bdiff|xdiff_file_bdiff_size|xdiff_file_bpatch|xdiff_file_diff|xdiff_file_diff_binary|xdiff_file_merge3|' +
+ 'xdiff_file_patch|xdiff_file_patch_binary|xdiff_file_rabdiff|xdiff_string_bdiff|xdiff_string_bdiff_size|xdiff_string_bpatch|' +
+ 'xdiff_string_diff|xdiff_string_diff_binary|xdiff_string_merge3|xdiff_string_patch|xdiff_string_patch_binary|xdiff_string_rabdiff|' +
+ 'xhprof_disable|xhprof_enable|xhprof_sample_disable|xhprof_sample_enable|xml_error_string|xml_get_current_byte_index|' +
+ 'xml_get_current_column_number|xml_get_current_line_number|xml_get_error_code|xml_parse|xml_parse_into_struct|xml_parser_create|' +
+ 'xml_parser_create_ns|xml_parser_free|xml_parser_get_option|xml_parser_set_option|xml_set_character_data_handler|xml_set_default_handler|' +
+ 'xml_set_element_handler|xml_set_end_namespace_decl_handler|xml_set_external_entity_ref_handler|xml_set_notation_decl_handler|' +
+ 'xml_set_object|xml_set_processing_instruction_handler|xml_set_start_namespace_decl_handler|xml_set_unparsed_entity_decl_handler|xmlreader|' +
+ 'xmlrpc_decode|xmlrpc_decode_request|xmlrpc_encode|xmlrpc_encode_request|xmlrpc_get_type|xmlrpc_is_fault|xmlrpc_parse_method_descriptions|' +
+ 'xmlrpc_server_add_introspection_data|xmlrpc_server_call_method|xmlrpc_server_create|xmlrpc_server_destroy|' +
+ 'xmlrpc_server_register_introspection_callback|xmlrpc_server_register_method|xmlrpc_set_type|xmlwriter_end_attribute|xmlwriter_end_cdata|' +
+ 'xmlwriter_end_comment|xmlwriter_end_document|xmlwriter_end_dtd|xmlwriter_end_dtd_attlist|xmlwriter_end_dtd_element|' +
+ 'xmlwriter_end_dtd_entity|xmlwriter_end_element|xmlwriter_end_pi|xmlwriter_flush|xmlwriter_full_end_element|xmlwriter_open_memory|' +
+ 'xmlwriter_open_uri|xmlwriter_output_memory|xmlwriter_set_indent|xmlwriter_set_indent_string|xmlwriter_start_attribute|' +
+ 'xmlwriter_start_attribute_ns|xmlwriter_start_cdata|xmlwriter_start_comment|xmlwriter_start_document|xmlwriter_start_dtd|' +
+ 'xmlwriter_start_dtd_attlist|xmlwriter_start_dtd_element|xmlwriter_start_dtd_entity|xmlwriter_start_element|xmlwriter_start_element_ns|' +
+ 'xmlwriter_start_pi|xmlwriter_text|xmlwriter_write_attribute|xmlwriter_write_attribute_ns|xmlwriter_write_cdata|xmlwriter_write_comment|' +
+ 'xmlwriter_write_dtd|xmlwriter_write_dtd_attlist|xmlwriter_write_dtd_element|xmlwriter_write_dtd_entity|xmlwriter_write_element|' +
+ 'xmlwriter_write_element_ns|xmlwriter_write_pi|xmlwriter_write_raw|xpath_eval|xpath_eval_expression|xpath_new_context|xpath_register_ns|' +
+ 'xpath_register_ns_auto|xptr_eval|xptr_new_context|xslt_backend_info|xslt_backend_name|xslt_backend_version|xslt_create|xslt_errno|' +
+ 'xslt_error|xslt_free|xslt_getopt|xslt_process|xslt_set_base|xslt_set_encoding|xslt_set_error_handler|xslt_set_log|xslt_set_object|' +
+ 'xslt_set_sax_handler|xslt_set_sax_handlers|xslt_set_scheme_handler|xslt_set_scheme_handlers|xslt_setopt|xsltprocessor|yaml_emit|' +
+ 'yaml_emit_file|yaml_parse|yaml_parse_file|yaml_parse_url|yaz_addinfo|yaz_ccl_conf|yaz_ccl_parse|yaz_close|yaz_connect|yaz_database|' +
+ 'yaz_element|yaz_errno|yaz_error|yaz_es|yaz_es_result|yaz_get_option|yaz_hits|yaz_itemorder|yaz_present|yaz_range|yaz_record|yaz_scan|' +
+ 'yaz_scan_result|yaz_schema|yaz_search|yaz_set_option|yaz_sort|yaz_syntax|yaz_wait|yp_all|yp_cat|yp_err_string|yp_errno|yp_first|' +
+ 'yp_get_default_domain|yp_master|yp_match|yp_next|yp_order|zend_logo_guid|zend_thread_id|zend_version|zip_close|zip_entry_close|' +
+ 'zip_entry_compressedsize|zip_entry_compressionmethod|zip_entry_filesize|zip_entry_name|zip_entry_open|zip_entry_read|zip_open|zip_read|' +
+ 'ziparchive|ziparchive_addemptydir|ziparchive_addfile|ziparchive_addfromstring|ziparchive_close|ziparchive_deleteindex|' +
+ 'ziparchive_deletename|ziparchive_extractto|ziparchive_getarchivecomment|ziparchive_getcommentindex|ziparchive_getcommentname|' +
+ 'ziparchive_getfromindex|ziparchive_getfromname|ziparchive_getnameindex|ziparchive_getstatusstring|ziparchive_getstream|' +
+ 'ziparchive_locatename|ziparchive_open|ziparchive_renameindex|ziparchive_renamename|ziparchive_setCommentName|ziparchive_setarchivecomment|' +
+ 'ziparchive_setcommentindex|ziparchive_statindex|ziparchive_statname|ziparchive_unchangeall|ziparchive_unchangearchive|' +
+ 'ziparchive_unchangeindex|ziparchive_unchangename|zlib_get_coding_type').split('|')
+ );
+ var keywords = lang.arrayToMap(
+ ('abstract|and|array|as|break|case|catch|class|clone|const|continue|declare|default|do|else|elseif|enddeclare|endfor|endforeach|endif|' +
+ 'endswitch|endwhile|extends|final|for|foreach|function|global|goto|if|implements|interface|instanceof|namespace|new|or|private|protected|' +
+ 'public|static|switch|throw|trait|try|use|var|while|xor').split('|')
+ );
+ var languageConstructs = lang.arrayToMap(
+ ('die|echo|empty|exit|eval|include|include_once|isset|list|require|require_once|return|print|unset').split('|')
+ );
+
+ var builtinConstants = lang.arrayToMap(
+ ('true|TRUE|false|FALSE|null|NULL|__CLASS__|__DIR__|__FILE__|__LINE__|__METHOD__|__FUNCTION__|__NAMESPACE__').split('|')
+ );
+
+ var builtinVariables = lang.arrayToMap(
+ ('$GLOBALS|$_SERVER|$_GET|$_POST|$_FILES|$_REQUEST|$_SESSION|$_ENV|$_COOKIE|$php_errormsg|$HTTP_RAW_POST_DATA|' +
+ '$http_response_header|$argc|$argv').split('|')
+ );
+ var builtinFunctionsDeprecated = lang.arrayToMap(
+ ('key_exists|cairo_matrix_create_scale|cairo_matrix_create_translate|call_user_method|call_user_method_array|com_addref|com_get|' +
+ 'com_invoke|com_isenum|com_load|com_release|com_set|connection_timeout|cubrid_load_from_glo|cubrid_new_glo|cubrid_save_to_glo|' +
+ 'cubrid_send_glo|define_syslog_variables|dl|ereg|ereg_replace|eregi|eregi_replace|hw_documentattributes|hw_documentbodytag|' +
+ 'hw_documentsize|hw_outputdocument|imagedashedline|maxdb_bind_param|maxdb_bind_result|maxdb_client_encoding|maxdb_close_long_data|' +
+ 'maxdb_execute|maxdb_fetch|maxdb_get_metadata|maxdb_param_count|maxdb_send_long_data|mcrypt_ecb|mcrypt_generic_end|mime_content_type|' +
+ 'mysql_createdb|mysql_dbname|mysql_db_query|mysql_drop_db|mysql_dropdb|mysql_escape_string|mysql_fieldflags|mysql_fieldflags|' +
+ 'mysql_fieldname|mysql_fieldtable|mysql_fieldtype|mysql_freeresult|mysql_listdbs|mysql_list_fields|mysql_listfields|mysql_list_tables|' +
+ 'mysql_listtables|mysql_numfields|mysql_numrows|mysql_selectdb|mysql_tablename|mysqli_bind_param|mysqli_bind_result|' +
+ 'mysqli_disable_reads_from_master|mysqli_disable_rpl_parse|mysqli_enable_reads_from_master|mysqli_enable_rpl_parse|mysqli_execute|' +
+ 'mysqli_fetch|mysqli_get_metadata|mysqli_master_query|mysqli_param_count|mysqli_rpl_parse_enabled|mysqli_rpl_probe|mysqli_rpl_query_type|' +
+ 'mysqli_send_long_data|mysqli_send_query|mysqli_slave_query|ocibindbyname|ocicancel|ocicloselob|ocicollappend|ocicollassign|' +
+ 'ocicollassignelem|ocicollgetelem|ocicollmax|ocicollsize|ocicolltrim|ocicolumnisnull|ocicolumnname|ocicolumnprecision|ocicolumnscale|' +
+ 'ocicolumnsize|ocicolumntype|ocicolumntyperaw|ocicommit|ocidefinebyname|ocierror|ociexecute|ocifetch|ocifetchinto|ocifetchstatement|' +
+ 'ocifreecollection|ocifreecursor|ocifreedesc|ocifreestatement|ociinternaldebug|ociloadlob|ocilogoff|ocilogon|ocinewcollection|' +
+ 'ocinewcursor|ocinewdescriptor|ocinlogon|ocinumcols|ociparse|ociplogon|ociresult|ocirollback|ocirowcount|ocisavelob|ocisavelobfile|' +
+ 'ociserverversion|ocisetprefetch|ocistatementtype|ociwritelobtofile|ociwritetemporarylob|PDF_add_annotation|PDF_add_bookmark|' +
+ 'PDF_add_launchlink|PDF_add_locallink|PDF_add_note|PDF_add_outline|PDF_add_pdflink|PDF_add_weblink|PDF_attach_file|PDF_begin_page|' +
+ 'PDF_begin_template|PDF_close_pdi|PDF_close|PDF_findfont|PDF_get_font|PDF_get_fontname|PDF_get_fontsize|PDF_get_image_height|' +
+ 'PDF_get_image_width|PDF_get_majorversion|PDF_get_minorversion|PDF_get_pdi_parameter|PDF_get_pdi_value|PDF_open_ccitt|PDF_open_file|' +
+ 'PDF_open_gif|PDF_open_image_file|PDF_open_image|PDF_open_jpeg|PDF_open_pdi|PDF_open_tiff|PDF_place_image|PDF_place_pdi_page|' +
+ 'PDF_set_border_color|PDF_set_border_dash|PDF_set_border_style|PDF_set_char_spacing|PDF_set_duration|PDF_set_horiz_scaling|' +
+ 'PDF_set_info_author|PDF_set_info_creator|PDF_set_info_keywords|PDF_set_info_subject|PDF_set_info_title|PDF_set_leading|' +
+ 'PDF_set_text_matrix|PDF_set_text_rendering|PDF_set_text_rise|PDF_set_word_spacing|PDF_setgray_fill|PDF_setgray_stroke|PDF_setgray|' +
+ 'PDF_setpolydash|PDF_setrgbcolor_fill|PDF_setrgbcolor_stroke|PDF_setrgbcolor|PDF_show_boxed|php_check_syntax|px_set_tablename|' +
+ 'px_set_targetencoding|runkit_sandbox_output_handler|session_is_registered|session_register|session_unregister' +
+ 'set_magic_quotes_runtime|magic_quotes_runtime|set_socket_blocking|socket_set_blocking|set_socket_timeout|socket_set_timeout|split|spliti|' +
+ 'sql_regcase').split('|')
+ );
+
+ var keywordsDeprecated = lang.arrayToMap(
+ ('cfunction|old_function').split('|')
+ );
+
+ var futureReserved = lang.arrayToMap([]);
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : /(?:#|\/\/)(?:[^?]|\?[^>])*/
+ },
+ docComment.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/][gimy]*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // " string start
+ regex : '"',
+ next : "qqstring"
+ }, {
+ token : "string", // ' string start
+ regex : "'",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language", // constants
+ regex : "\\b(?:DEFAULT_INCLUDE_PATH|E_(?:ALL|CO(?:MPILE_(?:ERROR|WARNING)|RE_(?:ERROR|WARNING))|" +
+ "ERROR|NOTICE|PARSE|STRICT|USER_(?:ERROR|NOTICE|WARNING)|WARNING)|P(?:EAR_(?:EXTENSION_DIR|INSTALL_DIR)|" +
+ "HP_(?:BINDIR|CONFIG_FILE_(?:PATH|SCAN_DIR)|DATADIR|E(?:OL|XTENSION_DIR)|INT_(?:MAX|SIZE)|" +
+ "L(?:IBDIR|OCALSTATEDIR)|O(?:S|UTPUT_HANDLER_(?:CONT|END|START))|PREFIX|S(?:API|HLIB_SUFFIX|YSCONFDIR)|" +
+ "VERSION))|__COMPILER_HALT_OFFSET__)\\b"
+ }, {
+ token : ["keyword", "text", "support.class"],
+ regex : "\\b(new)(\\s+)(\\w+)"
+ }, {
+ token : ["support.class", "keyword.operator"],
+ regex : "\\b(\\w+)(::)"
+ }, {
+ token : "constant.language", // constants
+ regex : "\\b(?:A(?:B(?:DAY_(?:1|2|3|4|5|6|7)|MON_(?:1(?:0|1|2|)|2|3|4|5|6|7|8|9))|LT_DIGITS|M_STR|" +
+ "SSERT_(?:ACTIVE|BAIL|CALLBACK|QUIET_EVAL|WARNING))|C(?:ASE_(?:LOWER|UPPER)|HAR_MAX|" +
+ "O(?:DESET|NNECTION_(?:ABORTED|NORMAL|TIMEOUT)|UNT_(?:NORMAL|RECURSIVE))|" +
+ "R(?:EDITS_(?:ALL|DOCS|FULLPAGE|G(?:ENERAL|ROUP)|MODULES|QA|SAPI)|NCYSTR|" +
+ "YPT_(?:BLOWFISH|EXT_DES|MD5|S(?:ALT_LENGTH|TD_DES)))|URRENCY_SYMBOL)|D(?:AY_(?:1|2|3|4|5|6|7)|" +
+ "ECIMAL_POINT|IRECTORY_SEPARATOR|_(?:FMT|T_FMT))|E(?:NT_(?:COMPAT|NOQUOTES|QUOTES)|RA(?:_(?:D_(?:FMT|T_FMT)|" +
+ "T_FMT|YEAR)|)|XTR_(?:IF_EXISTS|OVERWRITE|PREFIX_(?:ALL|I(?:F_EXISTS|NVALID)|SAME)|SKIP))|FRAC_DIGITS|GROUPING|" +
+ "HTML_(?:ENTITIES|SPECIALCHARS)|IN(?:FO_(?:ALL|C(?:ONFIGURATION|REDITS)|ENVIRONMENT|GENERAL|LICENSE|MODULES|VARIABLES)|" +
+ "I_(?:ALL|PERDIR|SYSTEM|USER)|T_(?:CURR_SYMBOL|FRAC_DIGITS))|L(?:C_(?:ALL|C(?:OLLATE|TYPE)|M(?:ESSAGES|ONETARY)|NUMERIC|TIME)|" +
+ "O(?:CK_(?:EX|NB|SH|UN)|G_(?:A(?:LERT|UTH(?:PRIV|))|C(?:ONS|R(?:IT|ON))|D(?:AEMON|EBUG)|E(?:MERG|RR)|INFO|KERN|" +
+ "L(?:OCAL(?:0|1|2|3|4|5|6|7)|PR)|MAIL|N(?:DELAY|EWS|O(?:TICE|WAIT))|ODELAY|P(?:ERROR|ID)|SYSLOG|U(?:SER|UCP)|WARNING)))|" +
+ "M(?:ON_(?:1(?:0|1|2|)|2|3|4|5|6|7|8|9|DECIMAL_POINT|GROUPING|THOUSANDS_SEP)|_(?:1_PI|2_(?:PI|SQRTPI)|E|L(?:N(?:10|2)|" +
+ "OG(?:10E|2E))|PI(?:_(?:2|4)|)|SQRT(?:1_2|2)))|N(?:EGATIVE_SIGN|O(?:EXPR|STR)|_(?:CS_PRECEDES|S(?:EP_BY_SPACE|IGN_POSN)))|" +
+ "P(?:ATH(?:INFO_(?:BASENAME|DIRNAME|EXTENSION)|_SEPARATOR)|M_STR|OSITIVE_SIGN|_(?:CS_PRECEDES|S(?:EP_BY_SPACE|IGN_POSN)))|" +
+ "RADIXCHAR|S(?:EEK_(?:CUR|END|SET)|ORT_(?:ASC|DESC|NUMERIC|REGULAR|STRING)|TR_PAD_(?:BOTH|LEFT|RIGHT))|" +
+ "T(?:HOUS(?:ANDS_SEP|EP)|_FMT(?:_AMPM|))|YES(?:EXPR|STR)|STD(?:IN|OUT|ERR))\\b"
+ }, {
+ token : function(value) {
+ if (keywords.hasOwnProperty(value))
+ return "keyword";
+ else if (builtinConstants.hasOwnProperty(value))
+ return "constant.language";
+ else if (builtinVariables.hasOwnProperty(value))
+ return "variable.language";
+ else if (futureReserved.hasOwnProperty(value))
+ return "invalid.illegal";
+ else if (builtinFunctions.hasOwnProperty(value))
+ return "support.function";
+ else if (value == "debugger")
+ return "invalid.deprecated";
+ else
+ if(value.match(/^(\$[a-zA-Z_\x7f-\uffff][a-zA-Z0-9_\x7f-\uffff]*|self|parent)$/))
+ return "variable";
+ return "identifier";
+ },
+ regex : /[a-zA-Z_$\x7f-\uffff][a-zA-Z0-9_\x7f-\uffff]*/
+ }, {
+ onMatch : function(value, currentSate, state) {
+ value = value.substr(3);
+ if (value[0] == "'" || value[0] == '"')
+ value = value.slice(1, -1);
+ state.unshift(this.next, value);
+ return "markup.list";
+ },
+ regex : /<<<(?:\w+|'\w+'|"\w+")$/,
+ next: "heredoc"
+ }, {
+ token : "keyword.operator",
+ regex : "::|!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|!=|!==|<=|>=|=>|<<=|>>=|>>>=|<>|<|>|=|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "heredoc" : [
+ {
+ onMatch : function(value, currentSate, stack) {
+ if (stack[1] != value)
+ return "string";
+ stack.shift();
+ stack.shift();
+ return "markup.list";
+ },
+ regex : "^\\w+(?=;?$)",
+ next: "start"
+ }, {
+ token: "string",
+ regex : ".*"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment",
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : '\\\\(?:[nrtvef\\\\"$]|[0-7]{1,3}|x[0-9A-Fa-f]{1,2})'
+ }, {
+ token : "variable",
+ regex : /\$[\w]+(?:\[[\w\]+]|[=\-]>\w+)?/
+ }, {
+ token : "variable",
+ regex : /\$\{[^"\}]+\}?/ // this is wrong but ok for now
+ },
+ {token : "string", regex : '"', next : "start"},
+ {defaultToken : "string"}
+ ],
+ "qstring" : [
+ {token : "constant.language.escape", regex : /\\['\\]/},
+ {token : "string", regex : "'", next : "start"},
+ {defaultToken : "string"}
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(PhpLangHighlightRules, TextHighlightRules);
+
+
+var PhpHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var startRules = [
+ {
+ token : "support.php_tag", // php open tag
+ regex : "<\\?(?:php|=)?",
+ push : "php-start"
+ }
+ ];
+
+ var endRules = [
+ {
+ token : "support.php_tag", // php close tag
+ regex : "\\?>",
+ next : "pop"
+ }
+ ];
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], startRules);
+
+ this.embedRules(PhpLangHighlightRules, "php-", endRules, ["start"]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(PhpHighlightRules, HtmlHighlightRules);
+
+exports.PhpHighlightRules = PhpHighlightRules;
+exports.PhpLangHighlightRules = PhpLangHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/php_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var functionMap = {
+ "abs": [
+ "int abs(int number)",
+ "Return the absolute value of the number"
+ ],
+ "acos": [
+ "float acos(float number)",
+ "Return the arc cosine of the number in radians"
+ ],
+ "acosh": [
+ "float acosh(float number)",
+ "Returns the inverse hyperbolic cosine of the number, i.e. the value whose hyperbolic cosine is number"
+ ],
+ "addGlob": [
+ "bool addGlob(string pattern[,int flags [, array options]])",
+ "Add files matching the glob pattern. See php's glob for the pattern syntax."
+ ],
+ "addPattern": [
+ "bool addPattern(string pattern[, string path [, array options]])",
+ "Add files matching the pcre pattern. See php's pcre for the pattern syntax."
+ ],
+ "addcslashes": [
+ "string addcslashes(string str, string charlist)",
+ "Escapes all chars mentioned in charlist with backslash. It creates octal representations if asked to backslash characters with 8th bit set or with ASCII<32 (except '\\n', '\\r', '\\t' etc...)"
+ ],
+ "addslashes": [
+ "string addslashes(string str)",
+ "Escapes single quote, double quotes and backslash characters in a string with backslashes"
+ ],
+ "apache_child_terminate": [
+ "bool apache_child_terminate(void)",
+ "Terminate apache process after this request"
+ ],
+ "apache_get_modules": [
+ "array apache_get_modules(void)",
+ "Get a list of loaded Apache modules"
+ ],
+ "apache_get_version": [
+ "string apache_get_version(void)",
+ "Fetch Apache version"
+ ],
+ "apache_getenv": [
+ "bool apache_getenv(string variable [, bool walk_to_top])",
+ "Get an Apache subprocess_env variable"
+ ],
+ "apache_lookup_uri": [
+ "object apache_lookup_uri(string URI)",
+ "Perform a partial request of the given URI to obtain information about it"
+ ],
+ "apache_note": [
+ "string apache_note(string note_name [, string note_value])",
+ "Get and set Apache request notes"
+ ],
+ "apache_request_auth_name": [
+ "string apache_request_auth_name()",
+ ""
+ ],
+ "apache_request_auth_type": [
+ "string apache_request_auth_type()",
+ ""
+ ],
+ "apache_request_discard_request_body": [
+ "long apache_request_discard_request_body()",
+ ""
+ ],
+ "apache_request_err_headers_out": [
+ "array apache_request_err_headers_out([{string name|array list} [, string value [, bool replace = false]]])",
+ "* fetch all headers that go out in case of an error or a subrequest"
+ ],
+ "apache_request_headers": [
+ "array apache_request_headers(void)",
+ "Fetch all HTTP request headers"
+ ],
+ "apache_request_headers_in": [
+ "array apache_request_headers_in()",
+ "* fetch all incoming request headers"
+ ],
+ "apache_request_headers_out": [
+ "array apache_request_headers_out([{string name|array list} [, string value [, bool replace = false]]])",
+ "* fetch all outgoing request headers"
+ ],
+ "apache_request_is_initial_req": [
+ "bool apache_request_is_initial_req()",
+ ""
+ ],
+ "apache_request_log_error": [
+ "boolean apache_request_log_error(string message, [long facility])",
+ ""
+ ],
+ "apache_request_meets_conditions": [
+ "long apache_request_meets_conditions()",
+ ""
+ ],
+ "apache_request_remote_host": [
+ "int apache_request_remote_host([int type])",
+ ""
+ ],
+ "apache_request_run": [
+ "long apache_request_run()",
+ "This is a wrapper for ap_sub_run_req and ap_destory_sub_req. It takes sub_request, runs it, destroys it, and returns it's status."
+ ],
+ "apache_request_satisfies": [
+ "long apache_request_satisfies()",
+ ""
+ ],
+ "apache_request_server_port": [
+ "int apache_request_server_port()",
+ ""
+ ],
+ "apache_request_set_etag": [
+ "void apache_request_set_etag()",
+ ""
+ ],
+ "apache_request_set_last_modified": [
+ "void apache_request_set_last_modified()",
+ ""
+ ],
+ "apache_request_some_auth_required": [
+ "bool apache_request_some_auth_required()",
+ ""
+ ],
+ "apache_request_sub_req_lookup_file": [
+ "object apache_request_sub_req_lookup_file(string file)",
+ "Returns sub-request for the specified file. You would need to run it yourself with run()."
+ ],
+ "apache_request_sub_req_lookup_uri": [
+ "object apache_request_sub_req_lookup_uri(string uri)",
+ "Returns sub-request for the specified uri. You would need to run it yourself with run()"
+ ],
+ "apache_request_sub_req_method_uri": [
+ "object apache_request_sub_req_method_uri(string method, string uri)",
+ "Returns sub-request for the specified file. You would need to run it yourself with run()."
+ ],
+ "apache_request_update_mtime": [
+ "long apache_request_update_mtime([int dependency_mtime])",
+ ""
+ ],
+ "apache_reset_timeout": [
+ "bool apache_reset_timeout(void)",
+ "Reset the Apache write timer"
+ ],
+ "apache_response_headers": [
+ "array apache_response_headers(void)",
+ "Fetch all HTTP response headers"
+ ],
+ "apache_setenv": [
+ "bool apache_setenv(string variable, string value [, bool walk_to_top])",
+ "Set an Apache subprocess_env variable"
+ ],
+ "array_change_key_case": [
+ "array array_change_key_case(array input [, int case=CASE_LOWER])",
+ "Retuns an array with all string keys lowercased [or uppercased]"
+ ],
+ "array_chunk": [
+ "array array_chunk(array input, int size [, bool preserve_keys])",
+ "Split array into chunks"
+ ],
+ "array_combine": [
+ "array array_combine(array keys, array values)",
+ "Creates an array by using the elements of the first parameter as keys and the elements of the second as the corresponding values"
+ ],
+ "array_count_values": [
+ "array array_count_values(array input)",
+ "Return the value as key and the frequency of that value in input as value"
+ ],
+ "array_diff": [
+ "array array_diff(array arr1, array arr2 [, array ...])",
+ "Returns the entries of arr1 that have values which are not present in any of the others arguments."
+ ],
+ "array_diff_assoc": [
+ "array array_diff_assoc(array arr1, array arr2 [, array ...])",
+ "Returns the entries of arr1 that have values which are not present in any of the others arguments but do additional checks whether the keys are equal"
+ ],
+ "array_diff_key": [
+ "array array_diff_key(array arr1, array arr2 [, array ...])",
+ "Returns the entries of arr1 that have keys which are not present in any of the others arguments. This function is like array_diff() but works on the keys instead of the values. The associativity is preserved."
+ ],
+ "array_diff_uassoc": [
+ "array array_diff_uassoc(array arr1, array arr2 [, array ...], callback data_comp_func)",
+ "Returns the entries of arr1 that have values which are not present in any of the others arguments but do additional checks whether the keys are equal. Elements are compared by user supplied function."
+ ],
+ "array_diff_ukey": [
+ "array array_diff_ukey(array arr1, array arr2 [, array ...], callback key_comp_func)",
+ "Returns the entries of arr1 that have keys which are not present in any of the others arguments. User supplied function is used for comparing the keys. This function is like array_udiff() but works on the keys instead of the values. The associativity is preserved."
+ ],
+ "array_fill": [
+ "array array_fill(int start_key, int num, mixed val)",
+ "Create an array containing num elements starting with index start_key each initialized to val"
+ ],
+ "array_fill_keys": [
+ "array array_fill_keys(array keys, mixed val)",
+ "Create an array using the elements of the first parameter as keys each initialized to val"
+ ],
+ "array_filter": [
+ "array array_filter(array input [, mixed callback])",
+ "Filters elements from the array via the callback."
+ ],
+ "array_flip": [
+ "array array_flip(array input)",
+ "Return array with key <-> value flipped"
+ ],
+ "array_intersect": [
+ "array array_intersect(array arr1, array arr2 [, array ...])",
+ "Returns the entries of arr1 that have values which are present in all the other arguments"
+ ],
+ "array_intersect_assoc": [
+ "array array_intersect_assoc(array arr1, array arr2 [, array ...])",
+ "Returns the entries of arr1 that have values which are present in all the other arguments. Keys are used to do more restrictive check"
+ ],
+ "array_intersect_key": [
+ "array array_intersect_key(array arr1, array arr2 [, array ...])",
+ "Returns the entries of arr1 that have keys which are present in all the other arguments. Kind of equivalent to array_diff(array_keys($arr1), array_keys($arr2)[,array_keys(...)]). Equivalent of array_intersect_assoc() but does not do compare of the data."
+ ],
+ "array_intersect_uassoc": [
+ "array array_intersect_uassoc(array arr1, array arr2 [, array ...], callback key_compare_func)",
+ "Returns the entries of arr1 that have values which are present in all the other arguments. Keys are used to do more restrictive check and they are compared by using an user-supplied callback."
+ ],
+ "array_intersect_ukey": [
+ "array array_intersect_ukey(array arr1, array arr2 [, array ...], callback key_compare_func)",
+ "Returns the entries of arr1 that have keys which are present in all the other arguments. Kind of equivalent to array_diff(array_keys($arr1), array_keys($arr2)[,array_keys(...)]). The comparison of the keys is performed by a user supplied function. Equivalent of array_intersect_uassoc() but does not do compare of the data."
+ ],
+ "array_key_exists": [
+ "bool array_key_exists(mixed key, array search)",
+ "Checks if the given key or index exists in the array"
+ ],
+ "array_keys": [
+ "array array_keys(array input [, mixed search_value[, bool strict]])",
+ "Return just the keys from the input array, optionally only for the specified search_value"
+ ],
+ "array_map": [
+ "array array_map(mixed callback, array input1 [, array input2 ,...])",
+ "Applies the callback to the elements in given arrays."
+ ],
+ "array_merge": [
+ "array array_merge(array arr1, array arr2 [, array ...])",
+ "Merges elements from passed arrays into one array"
+ ],
+ "array_merge_recursive": [
+ "array array_merge_recursive(array arr1, array arr2 [, array ...])",
+ "Recursively merges elements from passed arrays into one array"
+ ],
+ "array_multisort": [
+ "bool array_multisort(array ar1 [, SORT_ASC|SORT_DESC [, SORT_REGULAR|SORT_NUMERIC|SORT_STRING]] [, array ar2 [, SORT_ASC|SORT_DESC [, SORT_REGULAR|SORT_NUMERIC|SORT_STRING]], ...])",
+ "Sort multiple arrays at once similar to how ORDER BY clause works in SQL"
+ ],
+ "array_pad": [
+ "array array_pad(array input, int pad_size, mixed pad_value)",
+ "Returns a copy of input array padded with pad_value to size pad_size"
+ ],
+ "array_pop": [
+ "mixed array_pop(array stack)",
+ "Pops an element off the end of the array"
+ ],
+ "array_product": [
+ "mixed array_product(array input)",
+ "Returns the product of the array entries"
+ ],
+ "array_push": [
+ "int array_push(array stack, mixed var [, mixed ...])",
+ "Pushes elements onto the end of the array"
+ ],
+ "array_rand": [
+ "mixed array_rand(array input [, int num_req])",
+ "Return key/keys for random entry/entries in the array"
+ ],
+ "array_reduce": [
+ "mixed array_reduce(array input, mixed callback [, mixed initial])",
+ "Iteratively reduce the array to a single value via the callback."
+ ],
+ "array_replace": [
+ "array array_replace(array arr1, array arr2 [, array ...])",
+ "Replaces elements from passed arrays into one array"
+ ],
+ "array_replace_recursive": [
+ "array array_replace_recursive(array arr1, array arr2 [, array ...])",
+ "Recursively replaces elements from passed arrays into one array"
+ ],
+ "array_reverse": [
+ "array array_reverse(array input [, bool preserve keys])",
+ "Return input as a new array with the order of the entries reversed"
+ ],
+ "array_search": [
+ "mixed array_search(mixed needle, array haystack [, bool strict])",
+ "Searches the array for a given value and returns the corresponding key if successful"
+ ],
+ "array_shift": [
+ "mixed array_shift(array stack)",
+ "Pops an element off the beginning of the array"
+ ],
+ "array_slice": [
+ "array array_slice(array input, int offset [, int length [, bool preserve_keys]])",
+ "Returns elements specified by offset and length"
+ ],
+ "array_splice": [
+ "array array_splice(array input, int offset [, int length [, array replacement]])",
+ "Removes the elements designated by offset and length and replace them with supplied array"
+ ],
+ "array_sum": [
+ "mixed array_sum(array input)",
+ "Returns the sum of the array entries"
+ ],
+ "array_udiff": [
+ "array array_udiff(array arr1, array arr2 [, array ...], callback data_comp_func)",
+ "Returns the entries of arr1 that have values which are not present in any of the others arguments. Elements are compared by user supplied function."
+ ],
+ "array_udiff_assoc": [
+ "array array_udiff_assoc(array arr1, array arr2 [, array ...], callback key_comp_func)",
+ "Returns the entries of arr1 that have values which are not present in any of the others arguments but do additional checks whether the keys are equal. Keys are compared by user supplied function."
+ ],
+ "array_udiff_uassoc": [
+ "array array_udiff_uassoc(array arr1, array arr2 [, array ...], callback data_comp_func, callback key_comp_func)",
+ "Returns the entries of arr1 that have values which are not present in any of the others arguments but do additional checks whether the keys are equal. Keys and elements are compared by user supplied functions."
+ ],
+ "array_uintersect": [
+ "array array_uintersect(array arr1, array arr2 [, array ...], callback data_compare_func)",
+ "Returns the entries of arr1 that have values which are present in all the other arguments. Data is compared by using an user-supplied callback."
+ ],
+ "array_uintersect_assoc": [
+ "array array_uintersect_assoc(array arr1, array arr2 [, array ...], callback data_compare_func)",
+ "Returns the entries of arr1 that have values which are present in all the other arguments. Keys are used to do more restrictive check. Data is compared by using an user-supplied callback."
+ ],
+ "array_uintersect_uassoc": [
+ "array array_uintersect_uassoc(array arr1, array arr2 [, array ...], callback data_compare_func, callback key_compare_func)",
+ "Returns the entries of arr1 that have values which are present in all the other arguments. Keys are used to do more restrictive check. Both data and keys are compared by using user-supplied callbacks."
+ ],
+ "array_unique": [
+ "array array_unique(array input [, int sort_flags])",
+ "Removes duplicate values from array"
+ ],
+ "array_unshift": [
+ "int array_unshift(array stack, mixed var [, mixed ...])",
+ "Pushes elements onto the beginning of the array"
+ ],
+ "array_values": [
+ "array array_values(array input)",
+ "Return just the values from the input array"
+ ],
+ "array_walk": [
+ "bool array_walk(array input, string funcname [, mixed userdata])",
+ "Apply a user function to every member of an array"
+ ],
+ "array_walk_recursive": [
+ "bool array_walk_recursive(array input, string funcname [, mixed userdata])",
+ "Apply a user function recursively to every member of an array"
+ ],
+ "arsort": [
+ "bool arsort(array &array_arg [, int sort_flags])",
+ "Sort an array in reverse order and maintain index association"
+ ],
+ "asin": [
+ "float asin(float number)",
+ "Returns the arc sine of the number in radians"
+ ],
+ "asinh": [
+ "float asinh(float number)",
+ "Returns the inverse hyperbolic sine of the number, i.e. the value whose hyperbolic sine is number"
+ ],
+ "asort": [
+ "bool asort(array &array_arg [, int sort_flags])",
+ "Sort an array and maintain index association"
+ ],
+ "assert": [
+ "int assert(string|bool assertion)",
+ "Checks if assertion is false"
+ ],
+ "assert_options": [
+ "mixed assert_options(int what [, mixed value])",
+ "Set/get the various assert flags"
+ ],
+ "atan": [
+ "float atan(float number)",
+ "Returns the arc tangent of the number in radians"
+ ],
+ "atan2": [
+ "float atan2(float y, float x)",
+ "Returns the arc tangent of y/x, with the resulting quadrant determined by the signs of y and x"
+ ],
+ "atanh": [
+ "float atanh(float number)",
+ "Returns the inverse hyperbolic tangent of the number, i.e. the value whose hyperbolic tangent is number"
+ ],
+ "attachIterator": [
+ "void attachIterator(Iterator iterator[, mixed info])",
+ "Attach a new iterator"
+ ],
+ "base64_decode": [
+ "string base64_decode(string str[, bool strict])",
+ "Decodes string using MIME base64 algorithm"
+ ],
+ "base64_encode": [
+ "string base64_encode(string str)",
+ "Encodes string using MIME base64 algorithm"
+ ],
+ "base_convert": [
+ "string base_convert(string number, int frombase, int tobase)",
+ "Converts a number in a string from any base <= 36 to any base <= 36"
+ ],
+ "basename": [
+ "string basename(string path [, string suffix])",
+ "Returns the filename component of the path"
+ ],
+ "bcadd": [
+ "string bcadd(string left_operand, string right_operand [, int scale])",
+ "Returns the sum of two arbitrary precision numbers"
+ ],
+ "bccomp": [
+ "int bccomp(string left_operand, string right_operand [, int scale])",
+ "Compares two arbitrary precision numbers"
+ ],
+ "bcdiv": [
+ "string bcdiv(string left_operand, string right_operand [, int scale])",
+ "Returns the quotient of two arbitrary precision numbers (division)"
+ ],
+ "bcmod": [
+ "string bcmod(string left_operand, string right_operand)",
+ "Returns the modulus of the two arbitrary precision operands"
+ ],
+ "bcmul": [
+ "string bcmul(string left_operand, string right_operand [, int scale])",
+ "Returns the multiplication of two arbitrary precision numbers"
+ ],
+ "bcpow": [
+ "string bcpow(string x, string y [, int scale])",
+ "Returns the value of an arbitrary precision number raised to the power of another"
+ ],
+ "bcpowmod": [
+ "string bcpowmod(string x, string y, string mod [, int scale])",
+ "Returns the value of an arbitrary precision number raised to the power of another reduced by a modulous"
+ ],
+ "bcscale": [
+ "bool bcscale(int scale)",
+ "Sets default scale parameter for all bc math functions"
+ ],
+ "bcsqrt": [
+ "string bcsqrt(string operand [, int scale])",
+ "Returns the square root of an arbitray precision number"
+ ],
+ "bcsub": [
+ "string bcsub(string left_operand, string right_operand [, int scale])",
+ "Returns the difference between two arbitrary precision numbers"
+ ],
+ "bin2hex": [
+ "string bin2hex(string data)",
+ "Converts the binary representation of data to hex"
+ ],
+ "bind_textdomain_codeset": [
+ "string bind_textdomain_codeset (string domain, string codeset)",
+ "Specify the character encoding in which the messages from the DOMAIN message catalog will be returned."
+ ],
+ "bindec": [
+ "int bindec(string binary_number)",
+ "Returns the decimal equivalent of the binary number"
+ ],
+ "bindtextdomain": [
+ "string bindtextdomain(string domain_name, string dir)",
+ "Bind to the text domain domain_name, looking for translations in dir. Returns the current domain"
+ ],
+ "birdstep_autocommit": [
+ "bool birdstep_autocommit(int index)",
+ ""
+ ],
+ "birdstep_close": [
+ "bool birdstep_close(int id)",
+ ""
+ ],
+ "birdstep_commit": [
+ "bool birdstep_commit(int index)",
+ ""
+ ],
+ "birdstep_connect": [
+ "int birdstep_connect(string server, string user, string pass)",
+ ""
+ ],
+ "birdstep_exec": [
+ "int birdstep_exec(int index, string exec_str)",
+ ""
+ ],
+ "birdstep_fetch": [
+ "bool birdstep_fetch(int index)",
+ ""
+ ],
+ "birdstep_fieldname": [
+ "string birdstep_fieldname(int index, int col)",
+ ""
+ ],
+ "birdstep_fieldnum": [
+ "int birdstep_fieldnum(int index)",
+ ""
+ ],
+ "birdstep_freeresult": [
+ "bool birdstep_freeresult(int index)",
+ ""
+ ],
+ "birdstep_off_autocommit": [
+ "bool birdstep_off_autocommit(int index)",
+ ""
+ ],
+ "birdstep_result": [
+ "mixed birdstep_result(int index, mixed col)",
+ ""
+ ],
+ "birdstep_rollback": [
+ "bool birdstep_rollback(int index)",
+ ""
+ ],
+ "bzcompress": [
+ "string bzcompress(string source [, int blocksize100k [, int workfactor]])",
+ "Compresses a string into BZip2 encoded data"
+ ],
+ "bzdecompress": [
+ "string bzdecompress(string source [, int small])",
+ "Decompresses BZip2 compressed data"
+ ],
+ "bzerrno": [
+ "int bzerrno(resource bz)",
+ "Returns the error number"
+ ],
+ "bzerror": [
+ "array bzerror(resource bz)",
+ "Returns the error number and error string in an associative array"
+ ],
+ "bzerrstr": [
+ "string bzerrstr(resource bz)",
+ "Returns the error string"
+ ],
+ "bzopen": [
+ "resource bzopen(string|int file|fp, string mode)",
+ "Opens a new BZip2 stream"
+ ],
+ "bzread": [
+ "string bzread(resource bz[, int length])",
+ "Reads up to length bytes from a BZip2 stream, or 1024 bytes if length is not specified"
+ ],
+ "cal_days_in_month": [
+ "int cal_days_in_month(int calendar, int month, int year)",
+ "Returns the number of days in a month for a given year and calendar"
+ ],
+ "cal_from_jd": [
+ "array cal_from_jd(int jd, int calendar)",
+ "Converts from Julian Day Count to a supported calendar and return extended information"
+ ],
+ "cal_info": [
+ "array cal_info([int calendar])",
+ "Returns information about a particular calendar"
+ ],
+ "cal_to_jd": [
+ "int cal_to_jd(int calendar, int month, int day, int year)",
+ "Converts from a supported calendar to Julian Day Count"
+ ],
+ "call_user_func": [
+ "mixed call_user_func(mixed function_name [, mixed parmeter] [, mixed ...])",
+ "Call a user function which is the first parameter"
+ ],
+ "call_user_func_array": [
+ "mixed call_user_func_array(string function_name, array parameters)",
+ "Call a user function which is the first parameter with the arguments contained in array"
+ ],
+ "call_user_method": [
+ "mixed call_user_method(string method_name, mixed object [, mixed parameter] [, mixed ...])",
+ "Call a user method on a specific object or class"
+ ],
+ "call_user_method_array": [
+ "mixed call_user_method_array(string method_name, mixed object, array params)",
+ "Call a user method on a specific object or class using a parameter array"
+ ],
+ "ceil": [
+ "float ceil(float number)",
+ "Returns the next highest integer value of the number"
+ ],
+ "chdir": [
+ "bool chdir(string directory)",
+ "Change the current directory"
+ ],
+ "checkdate": [
+ "bool checkdate(int month, int day, int year)",
+ "Returns true(1) if it is a valid date in gregorian calendar"
+ ],
+ "chgrp": [
+ "bool chgrp(string filename, mixed group)",
+ "Change file group"
+ ],
+ "chmod": [
+ "bool chmod(string filename, int mode)",
+ "Change file mode"
+ ],
+ "chown": [
+ "bool chown (string filename, mixed user)",
+ "Change file owner"
+ ],
+ "chr": [
+ "string chr(int ascii)",
+ "Converts ASCII code to a character"
+ ],
+ "chroot": [
+ "bool chroot(string directory)",
+ "Change root directory"
+ ],
+ "chunk_split": [
+ "string chunk_split(string str [, int chunklen [, string ending]])",
+ "Returns split line"
+ ],
+ "class_alias": [
+ "bool class_alias(string user_class_name , string alias_name [, bool autoload])",
+ "Creates an alias for user defined class"
+ ],
+ "class_exists": [
+ "bool class_exists(string classname [, bool autoload])",
+ "Checks if the class exists"
+ ],
+ "class_implements": [
+ "array class_implements(mixed what [, bool autoload ])",
+ "Return all classes and interfaces implemented by SPL"
+ ],
+ "class_parents": [
+ "array class_parents(object instance [, boolean autoload = true])",
+ "Return an array containing the names of all parent classes"
+ ],
+ "clearstatcache": [
+ "void clearstatcache([bool clear_realpath_cache[, string filename]])",
+ "Clear file stat cache"
+ ],
+ "closedir": [
+ "void closedir([resource dir_handle])",
+ "Close directory connection identified by the dir_handle"
+ ],
+ "closelog": [
+ "bool closelog(void)",
+ "Close connection to system logger"
+ ],
+ "collator_asort": [
+ "bool collator_asort( Collator $coll, array(string) $arr )",
+ "* Sort array using specified collator, maintaining index association."
+ ],
+ "collator_compare": [
+ "int collator_compare( Collator $coll, string $str1, string $str2 )",
+ "* Compare two strings."
+ ],
+ "collator_create": [
+ "Collator collator_create( string $locale )",
+ "* Create collator."
+ ],
+ "collator_get_attribute": [
+ "int collator_get_attribute( Collator $coll, int $attr )",
+ "* Get collation attribute value."
+ ],
+ "collator_get_error_code": [
+ "int collator_get_error_code( Collator $coll )",
+ "* Get collator's last error code."
+ ],
+ "collator_get_error_message": [
+ "string collator_get_error_message( Collator $coll )",
+ "* Get text description for collator's last error code."
+ ],
+ "collator_get_locale": [
+ "string collator_get_locale( Collator $coll, int $type )",
+ "* Gets the locale name of the collator."
+ ],
+ "collator_get_sort_key": [
+ "bool collator_get_sort_key( Collator $coll, string $str )",
+ "* Get a sort key for a string from a Collator. }}}"
+ ],
+ "collator_get_strength": [
+ "int collator_get_strength(Collator coll)",
+ "* Returns the current collation strength."
+ ],
+ "collator_set_attribute": [
+ "bool collator_set_attribute( Collator $coll, int $attr, int $val )",
+ "* Set collation attribute."
+ ],
+ "collator_set_strength": [
+ "bool collator_set_strength(Collator coll, int strength)",
+ "* Set the collation strength."
+ ],
+ "collator_sort": [
+ "bool collator_sort( Collator $coll, array(string) $arr [, int $sort_flags] )",
+ "* Sort array using specified collator."
+ ],
+ "collator_sort_with_sort_keys": [
+ "bool collator_sort_with_sort_keys( Collator $coll, array(string) $arr )",
+ "* Equivalent to standard PHP sort using Collator. * Uses ICU ucol_getSortKey for performance."
+ ],
+ "com_create_guid": [
+ "string com_create_guid()",
+ "Generate a globally unique identifier (GUID)"
+ ],
+ "com_event_sink": [
+ "bool com_event_sink(object comobject, object sinkobject [, mixed sinkinterface])",
+ "Connect events from a COM object to a PHP object"
+ ],
+ "com_get_active_object": [
+ "object com_get_active_object(string progid [, int code_page ])",
+ "Returns a handle to an already running instance of a COM object"
+ ],
+ "com_load_typelib": [
+ "bool com_load_typelib(string typelib_name [, int case_insensitive])",
+ "Loads a Typelibrary and registers its constants"
+ ],
+ "com_message_pump": [
+ "bool com_message_pump([int timeoutms])",
+ "Process COM messages, sleeping for up to timeoutms milliseconds"
+ ],
+ "com_print_typeinfo": [
+ "bool com_print_typeinfo(object comobject | string typelib, string dispinterface, bool wantsink)",
+ "Print out a PHP class definition for a dispatchable interface"
+ ],
+ "compact": [
+ "array compact(mixed var_names [, mixed ...])",
+ "Creates a hash containing variables and their values"
+ ],
+ "compose_locale": [
+ "static string compose_locale($array)",
+ "* Creates a locale by combining the parts of locale-ID passed * }}}"
+ ],
+ "confirm_extname_compiled": [
+ "string confirm_extname_compiled(string arg)",
+ "Return a string to confirm that the module is compiled in"
+ ],
+ "connection_aborted": [
+ "int connection_aborted(void)",
+ "Returns true if client disconnected"
+ ],
+ "connection_status": [
+ "int connection_status(void)",
+ "Returns the connection status bitfield"
+ ],
+ "constant": [
+ "mixed constant(string const_name)",
+ "Given the name of a constant this function will return the constant's associated value"
+ ],
+ "convert_cyr_string": [
+ "string convert_cyr_string(string str, string from, string to)",
+ "Convert from one Cyrillic character set to another"
+ ],
+ "convert_uudecode": [
+ "string convert_uudecode(string data)",
+ "decode a uuencoded string"
+ ],
+ "convert_uuencode": [
+ "string convert_uuencode(string data)",
+ "uuencode a string"
+ ],
+ "copy": [
+ "bool copy(string source_file, string destination_file [, resource context])",
+ "Copy a file"
+ ],
+ "cos": [
+ "float cos(float number)",
+ "Returns the cosine of the number in radians"
+ ],
+ "cosh": [
+ "float cosh(float number)",
+ "Returns the hyperbolic cosine of the number, defined as (exp(number) + exp(-number))/2"
+ ],
+ "count": [
+ "int count(mixed var [, int mode])",
+ "Count the number of elements in a variable (usually an array)"
+ ],
+ "count_chars": [
+ "mixed count_chars(string input [, int mode])",
+ "Returns info about what characters are used in input"
+ ],
+ "crc32": [
+ "string crc32(string str)",
+ "Calculate the crc32 polynomial of a string"
+ ],
+ "create_function": [
+ "string create_function(string args, string code)",
+ "Creates an anonymous function, and returns its name (funny, eh?)"
+ ],
+ "crypt": [
+ "string crypt(string str [, string salt])",
+ "Hash a string"
+ ],
+ "ctype_alnum": [
+ "bool ctype_alnum(mixed c)",
+ "Checks for alphanumeric character(s)"
+ ],
+ "ctype_alpha": [
+ "bool ctype_alpha(mixed c)",
+ "Checks for alphabetic character(s)"
+ ],
+ "ctype_cntrl": [
+ "bool ctype_cntrl(mixed c)",
+ "Checks for control character(s)"
+ ],
+ "ctype_digit": [
+ "bool ctype_digit(mixed c)",
+ "Checks for numeric character(s)"
+ ],
+ "ctype_graph": [
+ "bool ctype_graph(mixed c)",
+ "Checks for any printable character(s) except space"
+ ],
+ "ctype_lower": [
+ "bool ctype_lower(mixed c)",
+ "Checks for lowercase character(s)"
+ ],
+ "ctype_print": [
+ "bool ctype_print(mixed c)",
+ "Checks for printable character(s)"
+ ],
+ "ctype_punct": [
+ "bool ctype_punct(mixed c)",
+ "Checks for any printable character which is not whitespace or an alphanumeric character"
+ ],
+ "ctype_space": [
+ "bool ctype_space(mixed c)",
+ "Checks for whitespace character(s)"
+ ],
+ "ctype_upper": [
+ "bool ctype_upper(mixed c)",
+ "Checks for uppercase character(s)"
+ ],
+ "ctype_xdigit": [
+ "bool ctype_xdigit(mixed c)",
+ "Checks for character(s) representing a hexadecimal digit"
+ ],
+ "curl_close": [
+ "void curl_close(resource ch)",
+ "Close a cURL session"
+ ],
+ "curl_copy_handle": [
+ "resource curl_copy_handle(resource ch)",
+ "Copy a cURL handle along with all of it's preferences"
+ ],
+ "curl_errno": [
+ "int curl_errno(resource ch)",
+ "Return an integer containing the last error number"
+ ],
+ "curl_error": [
+ "string curl_error(resource ch)",
+ "Return a string contain the last error for the current session"
+ ],
+ "curl_exec": [
+ "bool curl_exec(resource ch)",
+ "Perform a cURL session"
+ ],
+ "curl_getinfo": [
+ "mixed curl_getinfo(resource ch [, int option])",
+ "Get information regarding a specific transfer"
+ ],
+ "curl_init": [
+ "resource curl_init([string url])",
+ "Initialize a cURL session"
+ ],
+ "curl_multi_add_handle": [
+ "int curl_multi_add_handle(resource mh, resource ch)",
+ "Add a normal cURL handle to a cURL multi handle"
+ ],
+ "curl_multi_close": [
+ "void curl_multi_close(resource mh)",
+ "Close a set of cURL handles"
+ ],
+ "curl_multi_exec": [
+ "int curl_multi_exec(resource mh, int &still_running)",
+ "Run the sub-connections of the current cURL handle"
+ ],
+ "curl_multi_getcontent": [
+ "string curl_multi_getcontent(resource ch)",
+ "Return the content of a cURL handle if CURLOPT_RETURNTRANSFER is set"
+ ],
+ "curl_multi_info_read": [
+ "array curl_multi_info_read(resource mh [, long msgs_in_queue])",
+ "Get information about the current transfers"
+ ],
+ "curl_multi_init": [
+ "resource curl_multi_init(void)",
+ "Returns a new cURL multi handle"
+ ],
+ "curl_multi_remove_handle": [
+ "int curl_multi_remove_handle(resource mh, resource ch)",
+ "Remove a multi handle from a set of cURL handles"
+ ],
+ "curl_multi_select": [
+ "int curl_multi_select(resource mh[, double timeout])",
+ "Get all the sockets associated with the cURL extension, which can then be \"selected\""
+ ],
+ "curl_setopt": [
+ "bool curl_setopt(resource ch, int option, mixed value)",
+ "Set an option for a cURL transfer"
+ ],
+ "curl_setopt_array": [
+ "bool curl_setopt_array(resource ch, array options)",
+ "Set an array of option for a cURL transfer"
+ ],
+ "curl_version": [
+ "array curl_version([int version])",
+ "Return cURL version information."
+ ],
+ "current": [
+ "mixed current(array array_arg)",
+ "Return the element currently pointed to by the internal array pointer"
+ ],
+ "date": [
+ "string date(string format [, long timestamp])",
+ "Format a local date/time"
+ ],
+ "date_add": [
+ "DateTime date_add(DateTime object, DateInterval interval)",
+ "Adds an interval to the current date in object."
+ ],
+ "date_create": [
+ "DateTime date_create([string time[, DateTimeZone object]])",
+ "Returns new DateTime object"
+ ],
+ "date_create_from_format": [
+ "DateTime date_create_from_format(string format, string time[, DateTimeZone object])",
+ "Returns new DateTime object formatted according to the specified format"
+ ],
+ "date_date_set": [
+ "DateTime date_date_set(DateTime object, long year, long month, long day)",
+ "Sets the date."
+ ],
+ "date_default_timezone_get": [
+ "string date_default_timezone_get()",
+ "Gets the default timezone used by all date/time functions in a script"
+ ],
+ "date_default_timezone_set": [
+ "bool date_default_timezone_set(string timezone_identifier)",
+ "Sets the default timezone used by all date/time functions in a script"
+ ],
+ "date_diff": [
+ "DateInterval date_diff(DateTime object [, bool absolute])",
+ "Returns the difference between two DateTime objects."
+ ],
+ "date_format": [
+ "string date_format(DateTime object, string format)",
+ "Returns date formatted according to given format"
+ ],
+ "date_get_last_errors": [
+ "array date_get_last_errors()",
+ "Returns the warnings and errors found while parsing a date/time string."
+ ],
+ "date_interval_create_from_date_string": [
+ "DateInterval date_interval_create_from_date_string(string time)",
+ "Uses the normal date parsers and sets up a DateInterval from the relative parts of the parsed string"
+ ],
+ "date_interval_format": [
+ "string date_interval_format(DateInterval object, string format)",
+ "Formats the interval."
+ ],
+ "date_isodate_set": [
+ "DateTime date_isodate_set(DateTime object, long year, long week[, long day])",
+ "Sets the ISO date."
+ ],
+ "date_modify": [
+ "DateTime date_modify(DateTime object, string modify)",
+ "Alters the timestamp."
+ ],
+ "date_offset_get": [
+ "long date_offset_get(DateTime object)",
+ "Returns the DST offset."
+ ],
+ "date_parse": [
+ "array date_parse(string date)",
+ "Returns associative array with detailed info about given date"
+ ],
+ "date_parse_from_format": [
+ "array date_parse_from_format(string format, string date)",
+ "Returns associative array with detailed info about given date"
+ ],
+ "date_sub": [
+ "DateTime date_sub(DateTime object, DateInterval interval)",
+ "Subtracts an interval to the current date in object."
+ ],
+ "date_sun_info": [
+ "array date_sun_info(long time, float latitude, float longitude)",
+ "Returns an array with information about sun set/rise and twilight begin/end"
+ ],
+ "date_sunrise": [
+ "mixed date_sunrise(mixed time [, int format [, float latitude [, float longitude [, float zenith [, float gmt_offset]]]]])",
+ "Returns time of sunrise for a given day and location"
+ ],
+ "date_sunset": [
+ "mixed date_sunset(mixed time [, int format [, float latitude [, float longitude [, float zenith [, float gmt_offset]]]]])",
+ "Returns time of sunset for a given day and location"
+ ],
+ "date_time_set": [
+ "DateTime date_time_set(DateTime object, long hour, long minute[, long second])",
+ "Sets the time."
+ ],
+ "date_timestamp_get": [
+ "long date_timestamp_get(DateTime object)",
+ "Gets the Unix timestamp."
+ ],
+ "date_timestamp_set": [
+ "DateTime date_timestamp_set(DateTime object, long unixTimestamp)",
+ "Sets the date and time based on an Unix timestamp."
+ ],
+ "date_timezone_get": [
+ "DateTimeZone date_timezone_get(DateTime object)",
+ "Return new DateTimeZone object relative to give DateTime"
+ ],
+ "date_timezone_set": [
+ "DateTime date_timezone_set(DateTime object, DateTimeZone object)",
+ "Sets the timezone for the DateTime object."
+ ],
+ "datefmt_create": [
+ "IntlDateFormatter datefmt_create(string $locale, long date_type, long time_type[, string $timezone_str, long $calendar, string $pattern] )",
+ "* Create formatter."
+ ],
+ "datefmt_format": [
+ "string datefmt_format( [mixed]int $args or array $args )",
+ "* Format the time value as a string. }}}"
+ ],
+ "datefmt_get_calendar": [
+ "string datefmt_get_calendar( IntlDateFormatter $mf )",
+ "* Get formatter calendar."
+ ],
+ "datefmt_get_datetype": [
+ "string datefmt_get_datetype( IntlDateFormatter $mf )",
+ "* Get formatter datetype."
+ ],
+ "datefmt_get_error_code": [
+ "int datefmt_get_error_code( IntlDateFormatter $nf )",
+ "* Get formatter's last error code."
+ ],
+ "datefmt_get_error_message": [
+ "string datefmt_get_error_message( IntlDateFormatter $coll )",
+ "* Get text description for formatter's last error code."
+ ],
+ "datefmt_get_locale": [
+ "string datefmt_get_locale(IntlDateFormatter $mf)",
+ "* Get formatter locale."
+ ],
+ "datefmt_get_pattern": [
+ "string datefmt_get_pattern( IntlDateFormatter $mf )",
+ "* Get formatter pattern."
+ ],
+ "datefmt_get_timetype": [
+ "string datefmt_get_timetype( IntlDateFormatter $mf )",
+ "* Get formatter timetype."
+ ],
+ "datefmt_get_timezone_id": [
+ "string datefmt_get_timezone_id( IntlDateFormatter $mf )",
+ "* Get formatter timezone_id."
+ ],
+ "datefmt_isLenient": [
+ "string datefmt_isLenient(IntlDateFormatter $mf)",
+ "* Get formatter locale."
+ ],
+ "datefmt_localtime": [
+ "integer datefmt_localtime( IntlDateFormatter $fmt, string $text_to_parse[, int $parse_pos ])",
+ "* Parse the string $value to a localtime array }}}"
+ ],
+ "datefmt_parse": [
+ "integer datefmt_parse( IntlDateFormatter $fmt, string $text_to_parse [, int $parse_pos] )",
+ "* Parse the string $value starting at parse_pos to a Unix timestamp -int }}}"
+ ],
+ "datefmt_setLenient": [
+ "string datefmt_setLenient(IntlDateFormatter $mf)",
+ "* Set formatter lenient."
+ ],
+ "datefmt_set_calendar": [
+ "bool datefmt_set_calendar( IntlDateFormatter $mf, int $calendar )",
+ "* Set formatter calendar."
+ ],
+ "datefmt_set_pattern": [
+ "bool datefmt_set_pattern( IntlDateFormatter $mf, string $pattern )",
+ "* Set formatter pattern."
+ ],
+ "datefmt_set_timezone_id": [
+ "boolean datefmt_set_timezone_id( IntlDateFormatter $mf,$timezone_id)",
+ "* Set formatter timezone_id."
+ ],
+ "dba_close": [
+ "void dba_close(resource handle)",
+ "Closes database"
+ ],
+ "dba_delete": [
+ "bool dba_delete(string key, resource handle)",
+ "Deletes the entry associated with key If inifile: remove all other key lines"
+ ],
+ "dba_exists": [
+ "bool dba_exists(string key, resource handle)",
+ "Checks, if the specified key exists"
+ ],
+ "dba_fetch": [
+ "string dba_fetch(string key, [int skip ,] resource handle)",
+ "Fetches the data associated with key"
+ ],
+ "dba_firstkey": [
+ "string dba_firstkey(resource handle)",
+ "Resets the internal key pointer and returns the first key"
+ ],
+ "dba_handlers": [
+ "array dba_handlers([bool full_info])",
+ "List configured database handlers"
+ ],
+ "dba_insert": [
+ "bool dba_insert(string key, string value, resource handle)",
+ "If not inifile: Insert value as key, return false, if key exists already If inifile: Add vakue as key (next instance of key)"
+ ],
+ "dba_key_split": [
+ "array|false dba_key_split(string key)",
+ "Splits an inifile key into an array of the form array(0=>group,1=>value_name) but returns false if input is false or null"
+ ],
+ "dba_list": [
+ "array dba_list()",
+ "List opened databases"
+ ],
+ "dba_nextkey": [
+ "string dba_nextkey(resource handle)",
+ "Returns the next key"
+ ],
+ "dba_open": [
+ "resource dba_open(string path, string mode [, string handlername, string ...])",
+ "Opens path using the specified handler in mode"
+ ],
+ "dba_optimize": [
+ "bool dba_optimize(resource handle)",
+ "Optimizes (e.g. clean up, vacuum) database"
+ ],
+ "dba_popen": [
+ "resource dba_popen(string path, string mode [, string handlername, string ...])",
+ "Opens path using the specified handler in mode persistently"
+ ],
+ "dba_replace": [
+ "bool dba_replace(string key, string value, resource handle)",
+ "Inserts value as key, replaces key, if key exists already If inifile: remove all other key lines"
+ ],
+ "dba_sync": [
+ "bool dba_sync(resource handle)",
+ "Synchronizes database"
+ ],
+ "dcgettext": [
+ "string dcgettext(string domain_name, string msgid, long category)",
+ "Return the translation of msgid for domain_name and category, or msgid unaltered if a translation does not exist"
+ ],
+ "dcngettext": [
+ "string dcngettext (string domain, string msgid1, string msgid2, int n, int category)",
+ "Plural version of dcgettext()"
+ ],
+ "debug_backtrace": [
+ "array debug_backtrace([bool provide_object])",
+ "Return backtrace as array"
+ ],
+ "debug_print_backtrace": [
+ "void debug_print_backtrace(void) */",
+ "ZEND_FUNCTION(debug_print_backtrace) { zend_execute_data *ptr, *skip; int lineno; char *function_name; char *filename; char *class_name = NULL; char *call_type; char *include_filename = NULL; zval *arg_array = NULL; int indent = 0; if (zend_parse_parameters_none() == FAILURE) { return; } ptr = EG(current_execute_data);",
+ "PHP_FUNCTION(dom_document_relaxNG_validate_file) { _dom_document_relaxNG_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_FILE); } /* }}} end dom_document_relaxNG_validate_file"
+ ],
+ "dom_document_relaxNG_validate_xml": [
+ "boolean dom_document_relaxNG_validate_xml(string source); */",
+ "PHP_FUNCTION(dom_document_relaxNG_validate_xml) { _dom_document_relaxNG_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_STRING); } /* }}} end dom_document_relaxNG_validate_xml"
+ ],
+ "dom_document_rename_node": [
+ "DOMNode dom_document_rename_node(node n, string namespaceURI, string qualifiedName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Document3-renameNode Since: DOM Level 3"
+ ],
+ "dom_document_save": [
+ "int dom_document_save(string file);",
+ "Convenience method to save to file"
+ ],
+ "dom_document_save_html": [
+ "string dom_document_save_html();",
+ "Convenience method to output as html"
+ ],
+ "dom_document_save_html_file": [
+ "int dom_document_save_html_file(string file);",
+ "Convenience method to save to file as html"
+ ],
+ "dom_document_savexml": [
+ "string dom_document_savexml([node n]);",
+ "URL: http://www.w3.org/TR/DOM-Level-3-LS/load-save.html#LS-DocumentLS-saveXML Since: DOM Level 3"
+ ],
+ "dom_document_schema_validate": [
+ "boolean dom_document_schema_validate(string source); */",
+ "PHP_FUNCTION(dom_document_schema_validate_xml) { _dom_document_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_STRING); } /* }}} end dom_document_schema_validate"
+ ],
+ "dom_document_schema_validate_file": [
+ "boolean dom_document_schema_validate_file(string filename); */",
+ "PHP_FUNCTION(dom_document_schema_validate_file) { _dom_document_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, DOM_LOAD_FILE); } /* }}} end dom_document_schema_validate_file"
+ ],
+ "dom_document_validate": [
+ "boolean dom_document_validate();",
+ "Since: DOM extended"
+ ],
+ "dom_document_xinclude": [
+ "int dom_document_xinclude([int options])",
+ "Substitutues xincludes in a DomDocument"
+ ],
+ "dom_domconfiguration_can_set_parameter": [
+ "boolean dom_domconfiguration_can_set_parameter(string name, domuserdata value);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMConfiguration-canSetParameter Since:"
+ ],
+ "dom_domconfiguration_get_parameter": [
+ "domdomuserdata dom_domconfiguration_get_parameter(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMConfiguration-getParameter Since:"
+ ],
+ "dom_domconfiguration_set_parameter": [
+ "dom_void dom_domconfiguration_set_parameter(string name, domuserdata value);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMConfiguration-property Since:"
+ ],
+ "dom_domerrorhandler_handle_error": [
+ "dom_boolean dom_domerrorhandler_handle_error(domerror error);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-ERRORS-DOMErrorHandler-handleError Since:"
+ ],
+ "dom_domimplementation_create_document": [
+ "DOMDocument dom_domimplementation_create_document(string namespaceURI, string qualifiedName, DOMDocumentType doctype);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Level-2-Core-DOM-createDocument Since: DOM Level 2"
+ ],
+ "dom_domimplementation_create_document_type": [
+ "DOMDocumentType dom_domimplementation_create_document_type(string qualifiedName, string publicId, string systemId);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Level-2-Core-DOM-createDocType Since: DOM Level 2"
+ ],
+ "dom_domimplementation_get_feature": [
+ "DOMNode dom_domimplementation_get_feature(string feature, string version);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMImplementation3-getFeature Since: DOM Level 3"
+ ],
+ "dom_domimplementation_has_feature": [
+ "boolean dom_domimplementation_has_feature(string feature, string version);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-5CED94D7 Since:"
+ ],
+ "dom_domimplementationlist_item": [
+ "domdomimplementation dom_domimplementationlist_item(int index);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMImplementationList-item Since:"
+ ],
+ "dom_domimplementationsource_get_domimplementation": [
+ "domdomimplementation dom_domimplementationsource_get_domimplementation(string features);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-getDOMImpl Since:"
+ ],
+ "dom_domimplementationsource_get_domimplementations": [
+ "domimplementationlist dom_domimplementationsource_get_domimplementations(string features);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-getDOMImpls Since:"
+ ],
+ "dom_domstringlist_item": [
+ "domstring dom_domstringlist_item(int index);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#DOMStringList-item Since:"
+ ],
+ "dom_element_get_attribute": [
+ "string dom_element_get_attribute(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-666EE0F9 Since:"
+ ],
+ "dom_element_get_attribute_node": [
+ "DOMAttr dom_element_get_attribute_node(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-217A91B8 Since:"
+ ],
+ "dom_element_get_attribute_node_ns": [
+ "DOMAttr dom_element_get_attribute_node_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElGetAtNodeNS Since: DOM Level 2"
+ ],
+ "dom_element_get_attribute_ns": [
+ "string dom_element_get_attribute_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElGetAttrNS Since: DOM Level 2"
+ ],
+ "dom_element_get_elements_by_tag_name": [
+ "DOMNodeList dom_element_get_elements_by_tag_name(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1938918D Since:"
+ ],
+ "dom_element_get_elements_by_tag_name_ns": [
+ "DOMNodeList dom_element_get_elements_by_tag_name_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-A6C90942 Since: DOM Level 2"
+ ],
+ "dom_element_has_attribute": [
+ "boolean dom_element_has_attribute(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElHasAttr Since: DOM Level 2"
+ ],
+ "dom_element_has_attribute_ns": [
+ "boolean dom_element_has_attribute_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElHasAttrNS Since: DOM Level 2"
+ ],
+ "dom_element_remove_attribute": [
+ "void dom_element_remove_attribute(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-6D6AC0F9 Since:"
+ ],
+ "dom_element_remove_attribute_node": [
+ "DOMAttr dom_element_remove_attribute_node(DOMAttr oldAttr);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-D589198 Since:"
+ ],
+ "dom_element_remove_attribute_ns": [
+ "void dom_element_remove_attribute_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElRemAtNS Since: DOM Level 2"
+ ],
+ "dom_element_set_attribute": [
+ "void dom_element_set_attribute(string name, string value);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-F68F082 Since:"
+ ],
+ "dom_element_set_attribute_node": [
+ "DOMAttr dom_element_set_attribute_node(DOMAttr newAttr);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-887236154 Since:"
+ ],
+ "dom_element_set_attribute_node_ns": [
+ "DOMAttr dom_element_set_attribute_node_ns(DOMAttr newAttr);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetAtNodeNS Since: DOM Level 2"
+ ],
+ "dom_element_set_attribute_ns": [
+ "void dom_element_set_attribute_ns(string namespaceURI, string qualifiedName, string value);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetAttrNS Since: DOM Level 2"
+ ],
+ "dom_element_set_id_attribute": [
+ "void dom_element_set_id_attribute(string name, boolean isId);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetIdAttr Since: DOM Level 3"
+ ],
+ "dom_element_set_id_attribute_node": [
+ "void dom_element_set_id_attribute_node(attr idAttr, boolean isId);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetIdAttrNode Since: DOM Level 3"
+ ],
+ "dom_element_set_id_attribute_ns": [
+ "void dom_element_set_id_attribute_ns(string namespaceURI, string localName, boolean isId);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-ElSetIdAttrNS Since: DOM Level 3"
+ ],
+ "dom_import_simplexml": [
+ "somNode dom_import_simplexml(sxeobject node)",
+ "Get a simplexml_element object from dom to allow for processing"
+ ],
+ "dom_namednodemap_get_named_item": [
+ "DOMNode dom_namednodemap_get_named_item(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1074577549 Since:"
+ ],
+ "dom_namednodemap_get_named_item_ns": [
+ "DOMNode dom_namednodemap_get_named_item_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-getNamedItemNS Since: DOM Level 2"
+ ],
+ "dom_namednodemap_item": [
+ "DOMNode dom_namednodemap_item(int index);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-349467F9 Since:"
+ ],
+ "dom_namednodemap_remove_named_item": [
+ "DOMNode dom_namednodemap_remove_named_item(string name);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-D58B193 Since:"
+ ],
+ "dom_namednodemap_remove_named_item_ns": [
+ "DOMNode dom_namednodemap_remove_named_item_ns(string namespaceURI, string localName);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-removeNamedItemNS Since: DOM Level 2"
+ ],
+ "dom_namednodemap_set_named_item": [
+ "DOMNode dom_namednodemap_set_named_item(DOMNode arg);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1025163788 Since:"
+ ],
+ "dom_namednodemap_set_named_item_ns": [
+ "DOMNode dom_namednodemap_set_named_item_ns(DOMNode arg);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-setNamedItemNS Since: DOM Level 2"
+ ],
+ "dom_namelist_get_name": [
+ "string dom_namelist_get_name(int index);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#NameList-getName Since:"
+ ],
+ "dom_namelist_get_namespace_uri": [
+ "string dom_namelist_get_namespace_uri(int index);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#NameList-getNamespaceURI Since:"
+ ],
+ "dom_node_append_child": [
+ "DomNode dom_node_append_child(DomNode newChild);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-184E7107 Since:"
+ ],
+ "dom_node_clone_node": [
+ "DomNode dom_node_clone_node(boolean deep);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-3A0ED0A4 Since:"
+ ],
+ "dom_node_compare_document_position": [
+ "short dom_node_compare_document_position(DomNode other);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-compareDocumentPosition Since: DOM Level 3"
+ ],
+ "dom_node_get_feature": [
+ "DomNode dom_node_get_feature(string feature, string version);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-getFeature Since: DOM Level 3"
+ ],
+ "dom_node_get_user_data": [
+ "mixed dom_node_get_user_data(string key);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-getUserData Since: DOM Level 3"
+ ],
+ "dom_node_has_attributes": [
+ "boolean dom_node_has_attributes();",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-NodeHasAttrs Since: DOM Level 2"
+ ],
+ "dom_node_has_child_nodes": [
+ "boolean dom_node_has_child_nodes();",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-810594187 Since:"
+ ],
+ "dom_node_insert_before": [
+ "domnode dom_node_insert_before(DomNode newChild, DomNode refChild);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-952280727 Since:"
+ ],
+ "dom_node_is_default_namespace": [
+ "boolean dom_node_is_default_namespace(string namespaceURI);",
+ "URL: http://www.w3.org/TR/DOM-Level-3-Core/core.html#Node3-isDefaultNamespace Since: DOM Level 3"
+ ],
+ "dom_node_is_equal_node": [
+ "boolean dom_node_is_equal_node(DomNode arg);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-isEqualNode Since: DOM Level 3"
+ ],
+ "dom_node_is_same_node": [
+ "boolean dom_node_is_same_node(DomNode other);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-isSameNode Since: DOM Level 3"
+ ],
+ "dom_node_is_supported": [
+ "boolean dom_node_is_supported(string feature, string version);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Level-2-Core-Node-supports Since: DOM Level 2"
+ ],
+ "dom_node_lookup_namespace_uri": [
+ "string dom_node_lookup_namespace_uri(string prefix);",
+ "URL: http://www.w3.org/TR/DOM-Level-3-Core/core.html#Node3-lookupNamespaceURI Since: DOM Level 3"
+ ],
+ "dom_node_lookup_prefix": [
+ "string dom_node_lookup_prefix(string namespaceURI);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-lookupNamespacePrefix Since: DOM Level 3"
+ ],
+ "dom_node_normalize": [
+ "void dom_node_normalize();",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-normalize Since:"
+ ],
+ "dom_node_remove_child": [
+ "DomNode dom_node_remove_child(DomNode oldChild);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-1734834066 Since:"
+ ],
+ "dom_node_replace_child": [
+ "DomNode dom_node_replace_child(DomNode newChild, DomNode oldChild);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-785887307 Since:"
+ ],
+ "dom_node_set_user_data": [
+ "mixed dom_node_set_user_data(string key, mixed data, userdatahandler handler);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-setUserData Since: DOM Level 3"
+ ],
+ "dom_nodelist_item": [
+ "DOMNode dom_nodelist_item(int index);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-844377136 Since:"
+ ],
+ "dom_string_extend_find_offset16": [
+ "int dom_string_extend_find_offset16(int offset32);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#i18n-methods-StringExtend-findOffset16 Since:"
+ ],
+ "dom_string_extend_find_offset32": [
+ "int dom_string_extend_find_offset32(int offset16);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#i18n-methods-StringExtend-findOffset32 Since:"
+ ],
+ "dom_text_is_whitespace_in_element_content": [
+ "boolean dom_text_is_whitespace_in_element_content();",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Text3-isWhitespaceInElementContent Since: DOM Level 3"
+ ],
+ "dom_text_replace_whole_text": [
+ "DOMText dom_text_replace_whole_text(string content);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-Text3-replaceWholeText Since: DOM Level 3"
+ ],
+ "dom_text_split_text": [
+ "DOMText dom_text_split_text(int offset);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#core-ID-38853C1D Since:"
+ ],
+ "dom_userdatahandler_handle": [
+ "dom_void dom_userdatahandler_handle(short operation, string key, domobject data, node src, node dst);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#ID-handleUserDataEvent Since:"
+ ],
+ "dom_xpath_evaluate": [
+ "mixed dom_xpath_evaluate(string expr [,DOMNode context]); */",
+ "PHP_FUNCTION(dom_xpath_evaluate) { php_xpath_eval(INTERNAL_FUNCTION_PARAM_PASSTHRU, PHP_DOM_XPATH_EVALUATE); } /* }}} end dom_xpath_evaluate"
+ ],
+ "dom_xpath_query": [
+ "DOMNodeList dom_xpath_query(string expr [,DOMNode context]); */",
+ "PHP_FUNCTION(dom_xpath_query) { php_xpath_eval(INTERNAL_FUNCTION_PARAM_PASSTHRU, PHP_DOM_XPATH_QUERY); } /* }}} end dom_xpath_query"
+ ],
+ "dom_xpath_register_ns": [
+ "boolean dom_xpath_register_ns(string prefix, string uri); */",
+ "PHP_FUNCTION(dom_xpath_register_ns) { zval *id; xmlXPathContextPtr ctxp; int prefix_len, ns_uri_len; dom_xpath_object *intern; unsigned char *prefix, *ns_uri; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), \"Oss\", &id, dom_xpath_class_entry, &prefix, &prefix_len, &ns_uri, &ns_uri_len) == FAILURE) { return; } intern = (dom_xpath_object *)zend_object_store_get_object(id TSRMLS_CC); ctxp = (xmlXPathContextPtr) intern->ptr; if (ctxp == NULL) { php_error_docref(NULL TSRMLS_CC, E_WARNING, \"Invalid XPath Context\"); RETURN_FALSE; } if (xmlXPathRegisterNs(ctxp, prefix, ns_uri) != 0) { RETURN_FALSE } RETURN_TRUE; } /* }}}"
+ ],
+ "dom_xpath_register_php_functions": [
+ "void dom_xpath_register_php_functions() */",
+ "PHP_FUNCTION(dom_xpath_register_php_functions) { zval *id; dom_xpath_object *intern; zval *array_value, **entry, *new_string; int name_len = 0; char *name; DOM_GET_THIS(id); if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, \"a\", &array_value) == SUCCESS) { intern = (dom_xpath_object *)zend_object_store_get_object(id TSRMLS_CC); zend_hash_internal_pointer_reset(Z_ARRVAL_P(array_value)); while (zend_hash_get_current_data(Z_ARRVAL_P(array_value), (void **)&entry) == SUCCESS) { SEPARATE_ZVAL(entry); convert_to_string_ex(entry); MAKE_STD_ZVAL(new_string); ZVAL_LONG(new_string,1); zend_hash_update(intern->registered_phpfunctions, Z_STRVAL_PP(entry), Z_STRLEN_PP(entry) + 1, &new_string, sizeof(zval*), NULL); zend_hash_move_forward(Z_ARRVAL_P(array_value)); } intern->registerPhpFunctions = 2; RETURN_TRUE; } else if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, \"s\", &name, &name_len) == SUCCESS) { intern = (dom_xpath_object *)zend_object_store_get_object(id TSRMLS_CC); MAKE_STD_ZVAL(new_string); ZVAL_LONG(new_string,1); zend_hash_update(intern->registered_phpfunctions, name, name_len + 1, &new_string, sizeof(zval*), NULL); intern->registerPhpFunctions = 2; } else { intern = (dom_xpath_object *)zend_object_store_get_object(id TSRMLS_CC); intern->registerPhpFunctions = 1; } } /* }}} end dom_xpath_register_php_functions"
+ ],
+ "each": [
+ "array each(array arr)",
+ "Return the currently pointed key..value pair in the passed array, and advance the pointer to the next element"
+ ],
+ "easter_date": [
+ "int easter_date([int year])",
+ "Return the timestamp of midnight on Easter of a given year (defaults to current year)"
+ ],
+ "easter_days": [
+ "int easter_days([int year, [int method]])",
+ "Return the number of days after March 21 that Easter falls on for a given year (defaults to current year)"
+ ],
+ "echo": [
+ "void echo(string arg1 [, string ...])",
+ "Output one or more strings"
+ ],
+ "empty": [
+ "bool empty( mixed var )",
+ "Determine whether a variable is empty"
+ ],
+ "enchant_broker_describe": [
+ "array enchant_broker_describe(resource broker)",
+ "Enumerates the Enchant providers and tells you some rudimentary information about them. The same info is provided through phpinfo()"
+ ],
+ "enchant_broker_dict_exists": [
+ "bool enchant_broker_dict_exists(resource broker, string tag)",
+ "Wether a dictionary exists or not. Using non-empty tag"
+ ],
+ "enchant_broker_free": [
+ "boolean enchant_broker_free(resource broker)",
+ "Destroys the broker object and its dictionnaries"
+ ],
+ "enchant_broker_free_dict": [
+ "resource enchant_broker_free_dict(resource dict)",
+ "Free the dictionary resource"
+ ],
+ "enchant_broker_get_dict_path": [
+ "string enchant_broker_get_dict_path(resource broker, int dict_type)",
+ "Get the directory path for a given backend, works with ispell and myspell"
+ ],
+ "enchant_broker_get_error": [
+ "string enchant_broker_get_error(resource broker)",
+ "Returns the last error of the broker"
+ ],
+ "enchant_broker_init": [
+ "resource enchant_broker_init()",
+ "create a new broker object capable of requesting"
+ ],
+ "enchant_broker_list_dicts": [
+ "string enchant_broker_list_dicts(resource broker)",
+ "Lists the dictionaries available for the given broker"
+ ],
+ "enchant_broker_request_dict": [
+ "resource enchant_broker_request_dict(resource broker, string tag)",
+ "create a new dictionary using tag, the non-empty language tag you wish to request a dictionary for (\"en_US\", \"de_DE\", ...)"
+ ],
+ "enchant_broker_request_pwl_dict": [
+ "resource enchant_broker_request_pwl_dict(resource broker, string filename)",
+ "creates a dictionary using a PWL file. A PWL file is personal word file one word per line. It must exist before the call."
+ ],
+ "enchant_broker_set_dict_path": [
+ "bool enchant_broker_set_dict_path(resource broker, int dict_type, string value)",
+ "Set the directory path for a given backend, works with ispell and myspell"
+ ],
+ "enchant_broker_set_ordering": [
+ "bool enchant_broker_set_ordering(resource broker, string tag, string ordering)",
+ "Declares a preference of dictionaries to use for the language described/referred to by 'tag'. The ordering is a comma delimited list of provider names. As a special exception, the \"*\" tag can be used as a language tag to declare a default ordering for any language that does not explictly declare an ordering."
+ ],
+ "enchant_dict_add_to_personal": [
+ "void enchant_dict_add_to_personal(resource dict, string word)",
+ "add 'word' to personal word list"
+ ],
+ "enchant_dict_add_to_session": [
+ "void enchant_dict_add_to_session(resource dict, string word)",
+ "add 'word' to this spell-checking session"
+ ],
+ "enchant_dict_check": [
+ "bool enchant_dict_check(resource dict, string word)",
+ "If the word is correctly spelled return true, otherwise return false"
+ ],
+ "enchant_dict_describe": [
+ "array enchant_dict_describe(resource dict)",
+ "Describes an individual dictionary 'dict'"
+ ],
+ "enchant_dict_get_error": [
+ "string enchant_dict_get_error(resource dict)",
+ "Returns the last error of the current spelling-session"
+ ],
+ "enchant_dict_is_in_session": [
+ "bool enchant_dict_is_in_session(resource dict, string word)",
+ "whether or not 'word' exists in this spelling-session"
+ ],
+ "enchant_dict_quick_check": [
+ "bool enchant_dict_quick_check(resource dict, string word [, array &suggestions])",
+ "If the word is correctly spelled return true, otherwise return false, if suggestions variable is provided, fill it with spelling alternatives."
+ ],
+ "enchant_dict_store_replacement": [
+ "void enchant_dict_store_replacement(resource dict, string mis, string cor)",
+ "add a correction for 'mis' using 'cor'. Notes that you replaced @mis with @cor, so it's possibly more likely that future occurrences of @mis will be replaced with @cor. So it might bump @cor up in the suggestion list."
+ ],
+ "enchant_dict_suggest": [
+ "array enchant_dict_suggest(resource dict, string word)",
+ "Will return a list of values if any of those pre-conditions are not met."
+ ],
+ "end": [
+ "mixed end(array array_arg)",
+ "Advances array argument's internal pointer to the last element and return it"
+ ],
+ "ereg": [
+ "int ereg(string pattern, string string [, array registers])",
+ "Regular expression match"
+ ],
+ "ereg_replace": [
+ "string ereg_replace(string pattern, string replacement, string string)",
+ "Replace regular expression"
+ ],
+ "eregi": [
+ "int eregi(string pattern, string string [, array registers])",
+ "Case-insensitive regular expression match"
+ ],
+ "eregi_replace": [
+ "string eregi_replace(string pattern, string replacement, string string)",
+ "Case insensitive replace regular expression"
+ ],
+ "error_get_last": [
+ "array error_get_last()",
+ "Get the last occurred error as associative array. Returns NULL if there hasn't been an error yet."
+ ],
+ "error_log": [
+ "bool error_log(string message [, int message_type [, string destination [, string extra_headers]]])",
+ "Send an error message somewhere"
+ ],
+ "error_reporting": [
+ "int error_reporting([int new_error_level])",
+ "Return the current error_reporting level, and if an argument was passed - change to the new level"
+ ],
+ "escapeshellarg": [
+ "string escapeshellarg(string arg)",
+ "Quote and escape an argument for use in a shell command"
+ ],
+ "escapeshellcmd": [
+ "string escapeshellcmd(string command)",
+ "Escape shell metacharacters"
+ ],
+ "exec": [
+ "string exec(string command [, array &output [, int &return_value]])",
+ "Execute an external program"
+ ],
+ "exif_imagetype": [
+ "int exif_imagetype(string imagefile)",
+ "Get the type of an image"
+ ],
+ "exif_read_data": [
+ "array exif_read_data(string filename [, sections_needed [, sub_arrays[, read_thumbnail]]])",
+ "Reads header data from the JPEG/TIFF image filename and optionally reads the internal thumbnails"
+ ],
+ "exif_tagname": [
+ "string exif_tagname(index)",
+ "Get headername for index or false if not defined"
+ ],
+ "exif_thumbnail": [
+ "string exif_thumbnail(string filename [, &width, &height [, &imagetype]])",
+ "Reads the embedded thumbnail"
+ ],
+ "exit": [
+ "void exit([mixed status])",
+ "Output a message and terminate the current script"
+ ],
+ "exp": [
+ "float exp(float number)",
+ "Returns e raised to the power of the number"
+ ],
+ "explode": [
+ "array explode(string separator, string str [, int limit])",
+ "Splits a string on string separator and return array of components. If limit is positive only limit number of components is returned. If limit is negative all components except the last abs(limit) are returned."
+ ],
+ "expm1": [
+ "float expm1(float number)",
+ "Returns exp(number) - 1, computed in a way that accurate even when the value of number is close to zero"
+ ],
+ "extension_loaded": [
+ "bool extension_loaded(string extension_name)",
+ "Returns true if the named extension is loaded"
+ ],
+ "extract": [
+ "int extract(array var_array [, int extract_type [, string prefix]])",
+ "Imports variables into symbol table from an array"
+ ],
+ "ezmlm_hash": [
+ "int ezmlm_hash(string addr)",
+ "Calculate EZMLM list hash value."
+ ],
+ "fclose": [
+ "bool fclose(resource fp)",
+ "Close an open file pointer"
+ ],
+ "feof": [
+ "bool feof(resource fp)",
+ "Test for end-of-file on a file pointer"
+ ],
+ "fflush": [
+ "bool fflush(resource fp)",
+ "Flushes output"
+ ],
+ "fgetc": [
+ "string fgetc(resource fp)",
+ "Get a character from file pointer"
+ ],
+ "fgetcsv": [
+ "array fgetcsv(resource fp [,int length [, string delimiter [, string enclosure [, string escape]]]])",
+ "Get line from file pointer and parse for CSV fields"
+ ],
+ "fgets": [
+ "string fgets(resource fp[, int length])",
+ "Get a line from file pointer"
+ ],
+ "fgetss": [
+ "string fgetss(resource fp [, int length [, string allowable_tags]])",
+ "Get a line from file pointer and strip HTML tags"
+ ],
+ "file": [
+ "array file(string filename [, int flags[, resource context]])",
+ "Read entire file into an array"
+ ],
+ "file_exists": [
+ "bool file_exists(string filename)",
+ "Returns true if filename exists"
+ ],
+ "file_get_contents": [
+ "string file_get_contents(string filename [, bool use_include_path [, resource context [, long offset [, long maxlen]]]])",
+ "Read the entire file into a string"
+ ],
+ "file_put_contents": [
+ "int file_put_contents(string file, mixed data [, int flags [, resource context]])",
+ "Write/Create a file with contents data and return the number of bytes written"
+ ],
+ "fileatime": [
+ "int fileatime(string filename)",
+ "Get last access time of file"
+ ],
+ "filectime": [
+ "int filectime(string filename)",
+ "Get inode modification time of file"
+ ],
+ "filegroup": [
+ "int filegroup(string filename)",
+ "Get file group"
+ ],
+ "fileinode": [
+ "int fileinode(string filename)",
+ "Get file inode"
+ ],
+ "filemtime": [
+ "int filemtime(string filename)",
+ "Get last modification time of file"
+ ],
+ "fileowner": [
+ "int fileowner(string filename)",
+ "Get file owner"
+ ],
+ "fileperms": [
+ "int fileperms(string filename)",
+ "Get file permissions"
+ ],
+ "filesize": [
+ "int filesize(string filename)",
+ "Get file size"
+ ],
+ "filetype": [
+ "string filetype(string filename)",
+ "Get file type"
+ ],
+ "filter_has_var": [
+ "mixed filter_has_var(constant type, string variable_name)",
+ "* Returns true if the variable with the name 'name' exists in source."
+ ],
+ "filter_input": [
+ "mixed filter_input(constant type, string variable_name [, long filter [, mixed options]])",
+ "* Returns the filtered variable 'name'* from source `type`."
+ ],
+ "filter_input_array": [
+ "mixed filter_input_array(constant type, [, mixed options]])",
+ "* Returns an array with all arguments defined in 'definition'."
+ ],
+ "filter_var": [
+ "mixed filter_var(mixed variable [, long filter [, mixed options]])",
+ "* Returns the filtered version of the vriable."
+ ],
+ "filter_var_array": [
+ "mixed filter_var_array(array data, [, mixed options]])",
+ "* Returns an array with all arguments defined in 'definition'."
+ ],
+ "finfo_buffer": [
+ "string finfo_buffer(resource finfo, char *string [, int options [, resource context]])",
+ "Return infromation about a string buffer."
+ ],
+ "finfo_close": [
+ "resource finfo_close(resource finfo)",
+ "Close fileinfo resource."
+ ],
+ "finfo_file": [
+ "string finfo_file(resource finfo, char *file_name [, int options [, resource context]])",
+ "Return information about a file."
+ ],
+ "finfo_open": [
+ "resource finfo_open([int options [, string arg]])",
+ "Create a new fileinfo resource."
+ ],
+ "finfo_set_flags": [
+ "bool finfo_set_flags(resource finfo, int options)",
+ "Set libmagic configuration options."
+ ],
+ "floatval": [
+ "float floatval(mixed var)",
+ "Get the float value of a variable"
+ ],
+ "flock": [
+ "bool flock(resource fp, int operation [, int &wouldblock])",
+ "Portable file locking"
+ ],
+ "floor": [
+ "float floor(float number)",
+ "Returns the next lowest integer value from the number"
+ ],
+ "flush": [
+ "void flush(void)",
+ "Flush the output buffer"
+ ],
+ "fmod": [
+ "float fmod(float x, float y)",
+ "Returns the remainder of dividing x by y as a float"
+ ],
+ "fnmatch": [
+ "bool fnmatch(string pattern, string filename [, int flags])",
+ "Match filename against pattern"
+ ],
+ "fopen": [
+ "resource fopen(string filename, string mode [, bool use_include_path [, resource context]])",
+ "Open a file or a URL and return a file pointer"
+ ],
+ "forward_static_call": [
+ "mixed forward_static_call(mixed function_name [, mixed parmeter] [, mixed ...])",
+ "Call a user function which is the first parameter"
+ ],
+ "fpassthru": [
+ "int fpassthru(resource fp)",
+ "Output all remaining data from a file pointer"
+ ],
+ "fprintf": [
+ "int fprintf(resource stream, string format [, mixed arg1 [, mixed ...]])",
+ "Output a formatted string into a stream"
+ ],
+ "fputcsv": [
+ "int fputcsv(resource fp, array fields [, string delimiter [, string enclosure]])",
+ "Format line as CSV and write to file pointer"
+ ],
+ "fread": [
+ "string fread(resource fp, int length)",
+ "Binary-safe file read"
+ ],
+ "frenchtojd": [
+ "int frenchtojd(int month, int day, int year)",
+ "Converts a french republic calendar date to julian day count"
+ ],
+ "fscanf": [
+ "mixed fscanf(resource stream, string format [, string ...])",
+ "Implements a mostly ANSI compatible fscanf()"
+ ],
+ "fseek": [
+ "int fseek(resource fp, int offset [, int whence])",
+ "Seek on a file pointer"
+ ],
+ "fsockopen": [
+ "resource fsockopen(string hostname, int port [, int errno [, string errstr [, float timeout]]])",
+ "Open Internet or Unix domain socket connection"
+ ],
+ "fstat": [
+ "array fstat(resource fp)",
+ "Stat() on a filehandle"
+ ],
+ "ftell": [
+ "int ftell(resource fp)",
+ "Get file pointer's read/write position"
+ ],
+ "ftok": [
+ "int ftok(string pathname, string proj)",
+ "Convert a pathname and a project identifier to a System V IPC key"
+ ],
+ "ftp_alloc": [
+ "bool ftp_alloc(resource stream, int size[, &response])",
+ "Attempt to allocate space on the remote FTP server"
+ ],
+ "ftp_cdup": [
+ "bool ftp_cdup(resource stream)",
+ "Changes to the parent directory"
+ ],
+ "ftp_chdir": [
+ "bool ftp_chdir(resource stream, string directory)",
+ "Changes directories"
+ ],
+ "ftp_chmod": [
+ "int ftp_chmod(resource stream, int mode, string filename)",
+ "Sets permissions on a file"
+ ],
+ "ftp_close": [
+ "bool ftp_close(resource stream)",
+ "Closes the FTP stream"
+ ],
+ "ftp_connect": [
+ "resource ftp_connect(string host [, int port [, int timeout]])",
+ "Opens a FTP stream"
+ ],
+ "ftp_delete": [
+ "bool ftp_delete(resource stream, string file)",
+ "Deletes a file"
+ ],
+ "ftp_exec": [
+ "bool ftp_exec(resource stream, string command)",
+ "Requests execution of a program on the FTP server"
+ ],
+ "ftp_fget": [
+ "bool ftp_fget(resource stream, resource fp, string remote_file, int mode[, int resumepos])",
+ "Retrieves a file from the FTP server and writes it to an open file"
+ ],
+ "ftp_fput": [
+ "bool ftp_fput(resource stream, string remote_file, resource fp, int mode[, int startpos])",
+ "Stores a file from an open file to the FTP server"
+ ],
+ "ftp_get": [
+ "bool ftp_get(resource stream, string local_file, string remote_file, int mode[, int resume_pos])",
+ "Retrieves a file from the FTP server and writes it to a local file"
+ ],
+ "ftp_get_option": [
+ "mixed ftp_get_option(resource stream, int option)",
+ "Gets an FTP option"
+ ],
+ "ftp_login": [
+ "bool ftp_login(resource stream, string username, string password)",
+ "Logs into the FTP server"
+ ],
+ "ftp_mdtm": [
+ "int ftp_mdtm(resource stream, string filename)",
+ "Returns the last modification time of the file, or -1 on error"
+ ],
+ "ftp_mkdir": [
+ "string ftp_mkdir(resource stream, string directory)",
+ "Creates a directory and returns the absolute path for the new directory or false on error"
+ ],
+ "ftp_nb_continue": [
+ "int ftp_nb_continue(resource stream)",
+ "Continues retrieving/sending a file nbronously"
+ ],
+ "ftp_nb_fget": [
+ "int ftp_nb_fget(resource stream, resource fp, string remote_file, int mode[, int resumepos])",
+ "Retrieves a file from the FTP server asynchronly and writes it to an open file"
+ ],
+ "ftp_nb_fput": [
+ "int ftp_nb_fput(resource stream, string remote_file, resource fp, int mode[, int startpos])",
+ "Stores a file from an open file to the FTP server nbronly"
+ ],
+ "ftp_nb_get": [
+ "int ftp_nb_get(resource stream, string local_file, string remote_file, int mode[, int resume_pos])",
+ "Retrieves a file from the FTP server nbhronly and writes it to a local file"
+ ],
+ "ftp_nb_put": [
+ "int ftp_nb_put(resource stream, string remote_file, string local_file, int mode[, int startpos])",
+ "Stores a file on the FTP server"
+ ],
+ "ftp_nlist": [
+ "array ftp_nlist(resource stream, string directory)",
+ "Returns an array of filenames in the given directory"
+ ],
+ "ftp_pasv": [
+ "bool ftp_pasv(resource stream, bool pasv)",
+ "Turns passive mode on or off"
+ ],
+ "ftp_put": [
+ "bool ftp_put(resource stream, string remote_file, string local_file, int mode[, int startpos])",
+ "Stores a file on the FTP server"
+ ],
+ "ftp_pwd": [
+ "string ftp_pwd(resource stream)",
+ "Returns the present working directory"
+ ],
+ "ftp_raw": [
+ "array ftp_raw(resource stream, string command)",
+ "Sends a literal command to the FTP server"
+ ],
+ "ftp_rawlist": [
+ "array ftp_rawlist(resource stream, string directory [, bool recursive])",
+ "Returns a detailed listing of a directory as an array of output lines"
+ ],
+ "ftp_rename": [
+ "bool ftp_rename(resource stream, string src, string dest)",
+ "Renames the given file to a new path"
+ ],
+ "ftp_rmdir": [
+ "bool ftp_rmdir(resource stream, string directory)",
+ "Removes a directory"
+ ],
+ "ftp_set_option": [
+ "bool ftp_set_option(resource stream, int option, mixed value)",
+ "Sets an FTP option"
+ ],
+ "ftp_site": [
+ "bool ftp_site(resource stream, string cmd)",
+ "Sends a SITE command to the server"
+ ],
+ "ftp_size": [
+ "int ftp_size(resource stream, string filename)",
+ "Returns the size of the file, or -1 on error"
+ ],
+ "ftp_ssl_connect": [
+ "resource ftp_ssl_connect(string host [, int port [, int timeout]])",
+ "Opens a FTP-SSL stream"
+ ],
+ "ftp_systype": [
+ "string ftp_systype(resource stream)",
+ "Returns the system type identifier"
+ ],
+ "ftruncate": [
+ "bool ftruncate(resource fp, int size)",
+ "Truncate file to 'size' length"
+ ],
+ "func_get_arg": [
+ "mixed func_get_arg(int arg_num)",
+ "Get the $arg_num'th argument that was passed to the function"
+ ],
+ "func_get_args": [
+ "array func_get_args()",
+ "Get an array of the arguments that were passed to the function"
+ ],
+ "func_num_args": [
+ "int func_num_args(void)",
+ "Get the number of arguments that were passed to the function"
+ ],
+ "function_exists": [
+ "bool function_exists(string function_name)",
+ "Checks if the function exists"
+ ],
+ "fwrite": [
+ "int fwrite(resource fp, string str [, int length])",
+ "Binary-safe file write"
+ ],
+ "gc_collect_cycles": [
+ "int gc_collect_cycles(void)",
+ "Forces collection of any existing garbage cycles. Returns number of freed zvals"
+ ],
+ "gc_disable": [
+ "void gc_disable(void)",
+ "Deactivates the circular reference collector"
+ ],
+ "gc_enable": [
+ "void gc_enable(void)",
+ "Activates the circular reference collector"
+ ],
+ "gc_enabled": [
+ "void gc_enabled(void)",
+ "Returns status of the circular reference collector"
+ ],
+ "gd_info": [
+ "array gd_info()",
+ ""
+ ],
+ "getKeywords": [
+ "static array getKeywords(string $locale) {",
+ "* return an associative array containing keyword-value * pairs for this locale. The keys are keys to the array (doh!) * }}}"
+ ],
+ "get_browser": [
+ "mixed get_browser([string browser_name [, bool return_array]])",
+ "Get information about the capabilities of a browser. If browser_name is omitted or null, HTTP_USER_AGENT is used. Returns an object by default; if return_array is true, returns an array."
+ ],
+ "get_called_class": [
+ "string get_called_class()",
+ "Retrieves the \"Late Static Binding\" class name"
+ ],
+ "get_cfg_var": [
+ "mixed get_cfg_var(string option_name)",
+ "Get the value of a PHP configuration option"
+ ],
+ "get_class": [
+ "string get_class([object object])",
+ "Retrieves the class name"
+ ],
+ "get_class_methods": [
+ "array get_class_methods(mixed class)",
+ "Returns an array of method names for class or class instance."
+ ],
+ "get_class_vars": [
+ "array get_class_vars(string class_name)",
+ "Returns an array of default properties of the class."
+ ],
+ "get_current_user": [
+ "string get_current_user(void)",
+ "Get the name of the owner of the current PHP script"
+ ],
+ "get_declared_classes": [
+ "array get_declared_classes()",
+ "Returns an array of all declared classes."
+ ],
+ "get_declared_interfaces": [
+ "array get_declared_interfaces()",
+ "Returns an array of all declared interfaces."
+ ],
+ "get_defined_constants": [
+ "array get_defined_constants([bool categorize])",
+ "Return an array containing the names and values of all defined constants"
+ ],
+ "get_defined_functions": [
+ "array get_defined_functions(void)",
+ "Returns an array of all defined functions"
+ ],
+ "get_defined_vars": [
+ "array get_defined_vars(void)",
+ "Returns an associative array of names and values of all currently defined variable names (variables in the current scope)"
+ ],
+ "get_display_language": [
+ "static string get_display_language($locale[, $in_locale = null])",
+ "* gets the language for the $locale in $in_locale or default_locale"
+ ],
+ "get_display_name": [
+ "static string get_display_name($locale[, $in_locale = null])",
+ "* gets the name for the $locale in $in_locale or default_locale"
+ ],
+ "get_display_region": [
+ "static string get_display_region($locale, $in_locale = null)",
+ "* gets the region for the $locale in $in_locale or default_locale"
+ ],
+ "get_display_script": [
+ "static string get_display_script($locale, $in_locale = null)",
+ "* gets the script for the $locale in $in_locale or default_locale"
+ ],
+ "get_extension_funcs": [
+ "array get_extension_funcs(string extension_name)",
+ "Returns an array with the names of functions belonging to the named extension"
+ ],
+ "get_headers": [
+ "array get_headers(string url[, int format])",
+ "fetches all the headers sent by the server in response to a HTTP request"
+ ],
+ "get_html_translation_table": [
+ "array get_html_translation_table([int table [, int quote_style]])",
+ "Returns the internal translation table used by htmlspecialchars and htmlentities"
+ ],
+ "get_include_path": [
+ "string get_include_path()",
+ "Get the current include_path configuration option"
+ ],
+ "get_included_files": [
+ "array get_included_files(void)",
+ "Returns an array with the file names that were include_once()'d"
+ ],
+ "get_loaded_extensions": [
+ "array get_loaded_extensions([bool zend_extensions])",
+ "Return an array containing names of loaded extensions"
+ ],
+ "get_magic_quotes_gpc": [
+ "int get_magic_quotes_gpc(void)",
+ "Get the current active configuration setting of magic_quotes_gpc"
+ ],
+ "get_magic_quotes_runtime": [
+ "int get_magic_quotes_runtime(void)",
+ "Get the current active configuration setting of magic_quotes_runtime"
+ ],
+ "get_meta_tags": [
+ "array get_meta_tags(string filename [, bool use_include_path])",
+ "Extracts all meta tag content attributes from a file and returns an array"
+ ],
+ "get_object_vars": [
+ "array get_object_vars(object obj)",
+ "Returns an array of object properties"
+ ],
+ "get_parent_class": [
+ "string get_parent_class([mixed object])",
+ "Retrieves the parent class name for object or class or current scope."
+ ],
+ "get_resource_type": [
+ "string get_resource_type(resource res)",
+ "Get the resource type name for a given resource"
+ ],
+ "getallheaders": [
+ "array getallheaders(void)",
+ ""
+ ],
+ "getcwd": [
+ "mixed getcwd(void)",
+ "Gets the current directory"
+ ],
+ "getdate": [
+ "array getdate([int timestamp])",
+ "Get date/time information"
+ ],
+ "getenv": [
+ "string getenv(string varname)",
+ "Get the value of an environment variable"
+ ],
+ "gethostbyaddr": [
+ "string gethostbyaddr(string ip_address)",
+ "Get the Internet host name corresponding to a given IP address"
+ ],
+ "gethostbyname": [
+ "string gethostbyname(string hostname)",
+ "Get the IP address corresponding to a given Internet host name"
+ ],
+ "gethostbynamel": [
+ "array gethostbynamel(string hostname)",
+ "Return a list of IP addresses that a given hostname resolves to."
+ ],
+ "gethostname": [
+ "string gethostname()",
+ "Get the host name of the current machine"
+ ],
+ "getimagesize": [
+ "array getimagesize(string imagefile [, array info])",
+ "Get the size of an image as 4-element array"
+ ],
+ "getlastmod": [
+ "int getlastmod(void)",
+ "Get time of last page modification"
+ ],
+ "getmygid": [
+ "int getmygid(void)",
+ "Get PHP script owner's GID"
+ ],
+ "getmyinode": [
+ "int getmyinode(void)",
+ "Get the inode of the current script being parsed"
+ ],
+ "getmypid": [
+ "int getmypid(void)",
+ "Get current process ID"
+ ],
+ "getmyuid": [
+ "int getmyuid(void)",
+ "Get PHP script owner's UID"
+ ],
+ "getopt": [
+ "array getopt(string options [, array longopts])",
+ "Get options from the command line argument list"
+ ],
+ "getprotobyname": [
+ "int getprotobyname(string name)",
+ "Returns protocol number associated with name as per /etc/protocols"
+ ],
+ "getprotobynumber": [
+ "string getprotobynumber(int proto)",
+ "Returns protocol name associated with protocol number proto"
+ ],
+ "getrandmax": [
+ "int getrandmax(void)",
+ "Returns the maximum value a random number can have"
+ ],
+ "getrusage": [
+ "array getrusage([int who])",
+ "Returns an array of usage statistics"
+ ],
+ "getservbyname": [
+ "int getservbyname(string service, string protocol)",
+ "Returns port associated with service. Protocol must be \"tcp\" or \"udp\""
+ ],
+ "getservbyport": [
+ "string getservbyport(int port, string protocol)",
+ "Returns service name associated with port. Protocol must be \"tcp\" or \"udp\""
+ ],
+ "gettext": [
+ "string gettext(string msgid)",
+ "Return the translation of msgid for the current domain, or msgid unaltered if a translation does not exist"
+ ],
+ "gettimeofday": [
+ "array gettimeofday([bool get_as_float])",
+ "Returns the current time as array"
+ ],
+ "gettype": [
+ "string gettype(mixed var)",
+ "Returns the type of the variable"
+ ],
+ "glob": [
+ "array glob(string pattern [, int flags])",
+ "Find pathnames matching a pattern"
+ ],
+ "gmdate": [
+ "string gmdate(string format [, long timestamp])",
+ "Format a GMT date/time"
+ ],
+ "gmmktime": [
+ "int gmmktime([int hour [, int min [, int sec [, int mon [, int day [, int year]]]]]])",
+ "Get UNIX timestamp for a GMT date"
+ ],
+ "gmp_abs": [
+ "resource gmp_abs(resource a)",
+ "Calculates absolute value"
+ ],
+ "gmp_add": [
+ "resource gmp_add(resource a, resource b)",
+ "Add a and b"
+ ],
+ "gmp_and": [
+ "resource gmp_and(resource a, resource b)",
+ "Calculates logical AND of a and b"
+ ],
+ "gmp_clrbit": [
+ "void gmp_clrbit(resource &a, int index)",
+ "Clears bit in a"
+ ],
+ "gmp_cmp": [
+ "int gmp_cmp(resource a, resource b)",
+ "Compares two numbers"
+ ],
+ "gmp_com": [
+ "resource gmp_com(resource a)",
+ "Calculates one's complement of a"
+ ],
+ "gmp_div_q": [
+ "resource gmp_div_q(resource a, resource b [, int round])",
+ "Divide a by b, returns quotient only"
+ ],
+ "gmp_div_qr": [
+ "array gmp_div_qr(resource a, resource b [, int round])",
+ "Divide a by b, returns quotient and reminder"
+ ],
+ "gmp_div_r": [
+ "resource gmp_div_r(resource a, resource b [, int round])",
+ "Divide a by b, returns reminder only"
+ ],
+ "gmp_divexact": [
+ "resource gmp_divexact(resource a, resource b)",
+ "Divide a by b using exact division algorithm"
+ ],
+ "gmp_fact": [
+ "resource gmp_fact(int a)",
+ "Calculates factorial function"
+ ],
+ "gmp_gcd": [
+ "resource gmp_gcd(resource a, resource b)",
+ "Computes greatest common denominator (gcd) of a and b"
+ ],
+ "gmp_gcdext": [
+ "array gmp_gcdext(resource a, resource b)",
+ "Computes G, S, and T, such that AS + BT = G = `gcd' (A, B)"
+ ],
+ "gmp_hamdist": [
+ "int gmp_hamdist(resource a, resource b)",
+ "Calculates hamming distance between a and b"
+ ],
+ "gmp_init": [
+ "resource gmp_init(mixed number [, int base])",
+ "Initializes GMP number"
+ ],
+ "gmp_intval": [
+ "int gmp_intval(resource gmpnumber)",
+ "Gets signed long value of GMP number"
+ ],
+ "gmp_invert": [
+ "resource gmp_invert(resource a, resource b)",
+ "Computes the inverse of a modulo b"
+ ],
+ "gmp_jacobi": [
+ "int gmp_jacobi(resource a, resource b)",
+ "Computes Jacobi symbol"
+ ],
+ "gmp_legendre": [
+ "int gmp_legendre(resource a, resource b)",
+ "Computes Legendre symbol"
+ ],
+ "gmp_mod": [
+ "resource gmp_mod(resource a, resource b)",
+ "Computes a modulo b"
+ ],
+ "gmp_mul": [
+ "resource gmp_mul(resource a, resource b)",
+ "Multiply a and b"
+ ],
+ "gmp_neg": [
+ "resource gmp_neg(resource a)",
+ "Negates a number"
+ ],
+ "gmp_nextprime": [
+ "resource gmp_nextprime(resource a)",
+ "Finds next prime of a"
+ ],
+ "gmp_or": [
+ "resource gmp_or(resource a, resource b)",
+ "Calculates logical OR of a and b"
+ ],
+ "gmp_perfect_square": [
+ "bool gmp_perfect_square(resource a)",
+ "Checks if a is an exact square"
+ ],
+ "gmp_popcount": [
+ "int gmp_popcount(resource a)",
+ "Calculates the population count of a"
+ ],
+ "gmp_pow": [
+ "resource gmp_pow(resource base, int exp)",
+ "Raise base to power exp"
+ ],
+ "gmp_powm": [
+ "resource gmp_powm(resource base, resource exp, resource mod)",
+ "Raise base to power exp and take result modulo mod"
+ ],
+ "gmp_prob_prime": [
+ "int gmp_prob_prime(resource a[, int reps])",
+ "Checks if a is \"probably prime\""
+ ],
+ "gmp_random": [
+ "resource gmp_random([int limiter])",
+ "Gets random number"
+ ],
+ "gmp_scan0": [
+ "int gmp_scan0(resource a, int start)",
+ "Finds first zero bit"
+ ],
+ "gmp_scan1": [
+ "int gmp_scan1(resource a, int start)",
+ "Finds first non-zero bit"
+ ],
+ "gmp_setbit": [
+ "void gmp_setbit(resource &a, int index[, bool set_clear])",
+ "Sets or clear bit in a"
+ ],
+ "gmp_sign": [
+ "int gmp_sign(resource a)",
+ "Gets the sign of the number"
+ ],
+ "gmp_sqrt": [
+ "resource gmp_sqrt(resource a)",
+ "Takes integer part of square root of a"
+ ],
+ "gmp_sqrtrem": [
+ "array gmp_sqrtrem(resource a)",
+ "Square root with remainder"
+ ],
+ "gmp_strval": [
+ "string gmp_strval(resource gmpnumber [, int base])",
+ "Gets string representation of GMP number"
+ ],
+ "gmp_sub": [
+ "resource gmp_sub(resource a, resource b)",
+ "Subtract b from a"
+ ],
+ "gmp_testbit": [
+ "bool gmp_testbit(resource a, int index)",
+ "Tests if bit is set in a"
+ ],
+ "gmp_xor": [
+ "resource gmp_xor(resource a, resource b)",
+ "Calculates logical exclusive OR of a and b"
+ ],
+ "gmstrftime": [
+ "string gmstrftime(string format [, int timestamp])",
+ "Format a GMT/UCT time/date according to locale settings"
+ ],
+ "grapheme_extract": [
+ "string grapheme_extract(string str, int size[, int extract_type[, int start[, int next]]])",
+ "Function to extract a sequence of default grapheme clusters"
+ ],
+ "grapheme_stripos": [
+ "int grapheme_stripos(string haystack, string needle [, int offset ])",
+ "Find position of first occurrence of a string within another, ignoring case differences"
+ ],
+ "grapheme_stristr": [
+ "string grapheme_stristr(string haystack, string needle[, bool part])",
+ "Finds first occurrence of a string within another"
+ ],
+ "grapheme_strlen": [
+ "int grapheme_strlen(string str)",
+ "Get number of graphemes in a string"
+ ],
+ "grapheme_strpos": [
+ "int grapheme_strpos(string haystack, string needle [, int offset ])",
+ "Find position of first occurrence of a string within another"
+ ],
+ "grapheme_strripos": [
+ "int grapheme_strripos(string haystack, string needle [, int offset])",
+ "Find position of last occurrence of a string within another, ignoring case"
+ ],
+ "grapheme_strrpos": [
+ "int grapheme_strrpos(string haystack, string needle [, int offset])",
+ "Find position of last occurrence of a string within another"
+ ],
+ "grapheme_strstr": [
+ "string grapheme_strstr(string haystack, string needle[, bool part])",
+ "Finds first occurrence of a string within another"
+ ],
+ "grapheme_substr": [
+ "string grapheme_substr(string str, int start [, int length])",
+ "Returns part of a string"
+ ],
+ "gregoriantojd": [
+ "int gregoriantojd(int month, int day, int year)",
+ "Converts a gregorian calendar date to julian day count"
+ ],
+ "gzcompress": [
+ "string gzcompress(string data [, int level])",
+ "Gzip-compress a string"
+ ],
+ "gzdeflate": [
+ "string gzdeflate(string data [, int level])",
+ "Gzip-compress a string"
+ ],
+ "gzencode": [
+ "string gzencode(string data [, int level [, int encoding_mode]])",
+ "GZ encode a string"
+ ],
+ "gzfile": [
+ "array gzfile(string filename [, int use_include_path])",
+ "Read und uncompress entire .gz-file into an array"
+ ],
+ "gzinflate": [
+ "string gzinflate(string data [, int length])",
+ "Unzip a gzip-compressed string"
+ ],
+ "gzopen": [
+ "resource gzopen(string filename, string mode [, int use_include_path])",
+ "Open a .gz-file and return a .gz-file pointer"
+ ],
+ "gzuncompress": [
+ "string gzuncompress(string data [, int length])",
+ "Unzip a gzip-compressed string"
+ ],
+ "hash": [
+ "string hash(string algo, string data[, bool raw_output = false])",
+ "Generate a hash of a given input string Returns lowercase hexits by default"
+ ],
+ "hash_algos": [
+ "array hash_algos(void)",
+ "Return a list of registered hashing algorithms"
+ ],
+ "hash_copy": [
+ "resource hash_copy(resource context)",
+ "Copy hash resource"
+ ],
+ "hash_file": [
+ "string hash_file(string algo, string filename[, bool raw_output = false])",
+ "Generate a hash of a given file Returns lowercase hexits by default"
+ ],
+ "hash_final": [
+ "string hash_final(resource context[, bool raw_output=false])",
+ "Output resulting digest"
+ ],
+ "hash_hmac": [
+ "string hash_hmac(string algo, string data, string key[, bool raw_output = false])",
+ "Generate a hash of a given input string with a key using HMAC Returns lowercase hexits by default"
+ ],
+ "hash_hmac_file": [
+ "string hash_hmac_file(string algo, string filename, string key[, bool raw_output = false])",
+ "Generate a hash of a given file with a key using HMAC Returns lowercase hexits by default"
+ ],
+ "hash_init": [
+ "resource hash_init(string algo[, int options, string key])",
+ "Initialize a hashing context"
+ ],
+ "hash_update": [
+ "bool hash_update(resource context, string data)",
+ "Pump data into the hashing algorithm"
+ ],
+ "hash_update_file": [
+ "bool hash_update_file(resource context, string filename[, resource context])",
+ "Pump data into the hashing algorithm from a file"
+ ],
+ "hash_update_stream": [
+ "int hash_update_stream(resource context, resource handle[, integer length])",
+ "Pump data into the hashing algorithm from an open stream"
+ ],
+ "header": [
+ "void header(string header [, bool replace, [int http_response_code]])",
+ "Sends a raw HTTP header"
+ ],
+ "header_remove": [
+ "void header_remove([string name])",
+ "Removes an HTTP header previously set using header()"
+ ],
+ "headers_list": [
+ "array headers_list(void)",
+ "Return list of headers to be sent / already sent"
+ ],
+ "headers_sent": [
+ "bool headers_sent([string &$file [, int &$line]])",
+ "Returns true if headers have already been sent, false otherwise"
+ ],
+ "hebrev": [
+ "string hebrev(string str [, int max_chars_per_line])",
+ "Converts logical Hebrew text to visual text"
+ ],
+ "hebrevc": [
+ "string hebrevc(string str [, int max_chars_per_line])",
+ "Converts logical Hebrew text to visual text with newline conversion"
+ ],
+ "hexdec": [
+ "int hexdec(string hexadecimal_number)",
+ "Returns the decimal equivalent of the hexadecimal number"
+ ],
+ "highlight_file": [
+ "bool highlight_file(string file_name [, bool return] )",
+ "Syntax highlight a source file"
+ ],
+ "highlight_string": [
+ "bool highlight_string(string string [, bool return] )",
+ "Syntax highlight a string or optionally return it"
+ ],
+ "html_entity_decode": [
+ "string html_entity_decode(string string [, int quote_style][, string charset])",
+ "Convert all HTML entities to their applicable characters"
+ ],
+ "htmlentities": [
+ "string htmlentities(string string [, int quote_style[, string charset[, bool double_encode]]])",
+ "Convert all applicable characters to HTML entities"
+ ],
+ "htmlspecialchars": [
+ "string htmlspecialchars(string string [, int quote_style[, string charset[, bool double_encode]]])",
+ "Convert special characters to HTML entities"
+ ],
+ "htmlspecialchars_decode": [
+ "string htmlspecialchars_decode(string string [, int quote_style])",
+ "Convert special HTML entities back to characters"
+ ],
+ "http_build_query": [
+ "string http_build_query(mixed formdata [, string prefix [, string arg_separator]])",
+ "Generates a form-encoded query string from an associative array or object."
+ ],
+ "hypot": [
+ "float hypot(float num1, float num2)",
+ "Returns sqrt(num1*num1 + num2*num2)"
+ ],
+ "ibase_add_user": [
+ "bool ibase_add_user(resource service_handle, string user_name, string password [, string first_name [, string middle_name [, string last_name]]])",
+ "Add a user to security database"
+ ],
+ "ibase_affected_rows": [
+ "int ibase_affected_rows( [ resource link_identifier ] )",
+ "Returns the number of rows affected by the previous INSERT, UPDATE or DELETE statement"
+ ],
+ "ibase_backup": [
+ "mixed ibase_backup(resource service_handle, string source_db, string dest_file [, int options [, bool verbose]])",
+ "Initiates a backup task in the service manager and returns immediately"
+ ],
+ "ibase_blob_add": [
+ "bool ibase_blob_add(resource blob_handle, string data)",
+ "Add data into created blob"
+ ],
+ "ibase_blob_cancel": [
+ "bool ibase_blob_cancel(resource blob_handle)",
+ "Cancel creating blob"
+ ],
+ "ibase_blob_close": [
+ "string ibase_blob_close(resource blob_handle)",
+ "Close blob"
+ ],
+ "ibase_blob_create": [
+ "resource ibase_blob_create([resource link_identifier])",
+ "Create blob for adding data"
+ ],
+ "ibase_blob_echo": [
+ "bool ibase_blob_echo([ resource link_identifier, ] string blob_id)",
+ "Output blob contents to browser"
+ ],
+ "ibase_blob_get": [
+ "string ibase_blob_get(resource blob_handle, int len)",
+ "Get len bytes data from open blob"
+ ],
+ "ibase_blob_import": [
+ "string ibase_blob_import([ resource link_identifier, ] resource file)",
+ "Create blob, copy file in it, and close it"
+ ],
+ "ibase_blob_info": [
+ "array ibase_blob_info([ resource link_identifier, ] string blob_id)",
+ "Return blob length and other useful info"
+ ],
+ "ibase_blob_open": [
+ "resource ibase_blob_open([ resource link_identifier, ] string blob_id)",
+ "Open blob for retrieving data parts"
+ ],
+ "ibase_close": [
+ "bool ibase_close([resource link_identifier])",
+ "Close an InterBase connection"
+ ],
+ "ibase_commit": [
+ "bool ibase_commit( resource link_identifier )",
+ "Commit transaction"
+ ],
+ "ibase_commit_ret": [
+ "bool ibase_commit_ret( resource link_identifier )",
+ "Commit transaction and retain the transaction context"
+ ],
+ "ibase_connect": [
+ "resource ibase_connect(string database [, string username [, string password [, string charset [, int buffers [, int dialect [, string role]]]]]])",
+ "Open a connection to an InterBase database"
+ ],
+ "ibase_db_info": [
+ "string ibase_db_info(resource service_handle, string db, int action [, int argument])",
+ "Request statistics about a database"
+ ],
+ "ibase_delete_user": [
+ "bool ibase_delete_user(resource service_handle, string user_name, string password [, string first_name [, string middle_name [, string last_name]]])",
+ "Delete a user from security database"
+ ],
+ "ibase_drop_db": [
+ "bool ibase_drop_db([resource link_identifier])",
+ "Drop an InterBase database"
+ ],
+ "ibase_errcode": [
+ "int ibase_errcode(void)",
+ "Return error code"
+ ],
+ "ibase_errmsg": [
+ "string ibase_errmsg(void)",
+ "Return error message"
+ ],
+ "ibase_execute": [
+ "mixed ibase_execute(resource query [, mixed bind_arg [, mixed bind_arg [, ...]]])",
+ "Execute a previously prepared query"
+ ],
+ "ibase_fetch_assoc": [
+ "array ibase_fetch_assoc(resource result [, int fetch_flags])",
+ "Fetch a row from the results of a query"
+ ],
+ "ibase_fetch_object": [
+ "object ibase_fetch_object(resource result [, int fetch_flags])",
+ "Fetch a object from the results of a query"
+ ],
+ "ibase_fetch_row": [
+ "array ibase_fetch_row(resource result [, int fetch_flags])",
+ "Fetch a row from the results of a query"
+ ],
+ "ibase_field_info": [
+ "array ibase_field_info(resource query_result, int field_number)",
+ "Get information about a field"
+ ],
+ "ibase_free_event_handler": [
+ "bool ibase_free_event_handler(resource event)",
+ "Frees the event handler set by ibase_set_event_handler()"
+ ],
+ "ibase_free_query": [
+ "bool ibase_free_query(resource query)",
+ "Free memory used by a query"
+ ],
+ "ibase_free_result": [
+ "bool ibase_free_result(resource result)",
+ "Free the memory used by a result"
+ ],
+ "ibase_gen_id": [
+ "int ibase_gen_id(string generator [, int increment [, resource link_identifier ]])",
+ "Increments the named generator and returns its new value"
+ ],
+ "ibase_maintain_db": [
+ "bool ibase_maintain_db(resource service_handle, string db, int action [, int argument])",
+ "Execute a maintenance command on the database server"
+ ],
+ "ibase_modify_user": [
+ "bool ibase_modify_user(resource service_handle, string user_name, string password [, string first_name [, string middle_name [, string last_name]]])",
+ "Modify a user in security database"
+ ],
+ "ibase_name_result": [
+ "bool ibase_name_result(resource result, string name)",
+ "Assign a name to a result for use with ... WHERE CURRENT OF <name> statements"
+ ],
+ "ibase_num_fields": [
+ "int ibase_num_fields(resource query_result)",
+ "Get the number of fields in result"
+ ],
+ "ibase_num_params": [
+ "int ibase_num_params(resource query)",
+ "Get the number of params in a prepared query"
+ ],
+ "ibase_num_rows": [
+ "int ibase_num_rows( resource result_identifier )",
+ "Return the number of rows that are available in a result"
+ ],
+ "ibase_param_info": [
+ "array ibase_param_info(resource query, int field_number)",
+ "Get information about a parameter"
+ ],
+ "ibase_pconnect": [
+ "resource ibase_pconnect(string database [, string username [, string password [, string charset [, int buffers [, int dialect [, string role]]]]]])",
+ "Open a persistent connection to an InterBase database"
+ ],
+ "ibase_prepare": [
+ "resource ibase_prepare(resource link_identifier[, string query [, resource trans_identifier ]])",
+ "Prepare a query for later execution"
+ ],
+ "ibase_query": [
+ "mixed ibase_query([resource link_identifier, [ resource link_identifier, ]] string query [, mixed bind_arg [, mixed bind_arg [, ...]]])",
+ "Execute a query"
+ ],
+ "ibase_restore": [
+ "mixed ibase_restore(resource service_handle, string source_file, string dest_db [, int options [, bool verbose]])",
+ "Initiates a restore task in the service manager and returns immediately"
+ ],
+ "ibase_rollback": [
+ "bool ibase_rollback( resource link_identifier )",
+ "Rollback transaction"
+ ],
+ "ibase_rollback_ret": [
+ "bool ibase_rollback_ret( resource link_identifier )",
+ "Rollback transaction and retain the transaction context"
+ ],
+ "ibase_server_info": [
+ "string ibase_server_info(resource service_handle, int action)",
+ "Request information about a database server"
+ ],
+ "ibase_service_attach": [
+ "resource ibase_service_attach(string host, string dba_username, string dba_password)",
+ "Connect to the service manager"
+ ],
+ "ibase_service_detach": [
+ "bool ibase_service_detach(resource service_handle)",
+ "Disconnect from the service manager"
+ ],
+ "ibase_set_event_handler": [
+ "resource ibase_set_event_handler([resource link_identifier,] callback handler, string event [, string event [, ...]])",
+ "Register the callback for handling each of the named events"
+ ],
+ "ibase_trans": [
+ "resource ibase_trans([int trans_args [, resource link_identifier [, ... ], int trans_args [, resource link_identifier [, ... ]] [, ...]]])",
+ "Start a transaction over one or several databases"
+ ],
+ "ibase_wait_event": [
+ "string ibase_wait_event([resource link_identifier,] string event [, string event [, ...]])",
+ "Waits for any one of the passed Interbase events to be posted by the database, and returns its name"
+ ],
+ "iconv": [
+ "string iconv(string in_charset, string out_charset, string str)",
+ "Returns str converted to the out_charset character set"
+ ],
+ "iconv_get_encoding": [
+ "mixed iconv_get_encoding([string type])",
+ "Get internal encoding and output encoding for ob_iconv_handler()"
+ ],
+ "iconv_mime_decode": [
+ "string iconv_mime_decode(string encoded_string [, int mode, string charset])",
+ "Decodes a mime header field"
+ ],
+ "iconv_mime_decode_headers": [
+ "array iconv_mime_decode_headers(string headers [, int mode, string charset])",
+ "Decodes multiple mime header fields"
+ ],
+ "iconv_mime_encode": [
+ "string iconv_mime_encode(string field_name, string field_value [, array preference])",
+ "Composes a mime header field with field_name and field_value in a specified scheme"
+ ],
+ "iconv_set_encoding": [
+ "bool iconv_set_encoding(string type, string charset)",
+ "Sets internal encoding and output encoding for ob_iconv_handler()"
+ ],
+ "iconv_strlen": [
+ "int iconv_strlen(string str [, string charset])",
+ "Returns the character count of str"
+ ],
+ "iconv_strpos": [
+ "int iconv_strpos(string haystack, string needle [, int offset [, string charset]])",
+ "Finds position of first occurrence of needle within part of haystack beginning with offset"
+ ],
+ "iconv_strrpos": [
+ "int iconv_strrpos(string haystack, string needle [, string charset])",
+ "Finds position of last occurrence of needle within part of haystack beginning with offset"
+ ],
+ "iconv_substr": [
+ "string iconv_substr(string str, int offset, [int length, string charset])",
+ "Returns specified part of a string"
+ ],
+ "idate": [
+ "int idate(string format [, int timestamp])",
+ "Format a local time/date as integer"
+ ],
+ "idn_to_ascii": [
+ "int idn_to_ascii(string domain[, int options])",
+ "Converts an Unicode domain to ASCII representation, as defined in the IDNA RFC"
+ ],
+ "idn_to_utf8": [
+ "int idn_to_utf8(string domain[, int options])",
+ "Converts an ASCII representation of the domain to Unicode (UTF-8), as defined in the IDNA RFC"
+ ],
+ "ignore_user_abort": [
+ "int ignore_user_abort([string value])",
+ "Set whether we want to ignore a user abort event or not"
+ ],
+ "image2wbmp": [
+ "bool image2wbmp(resource im [, string filename [, int threshold]])",
+ "Output WBMP image to browser or file"
+ ],
+ "image_type_to_extension": [
+ "string image_type_to_extension(int imagetype [, bool include_dot])",
+ "Get file extension for image-type returned by getimagesize, exif_read_data, exif_thumbnail, exif_imagetype"
+ ],
+ "image_type_to_mime_type": [
+ "string image_type_to_mime_type(int imagetype)",
+ "Get Mime-Type for image-type returned by getimagesize, exif_read_data, exif_thumbnail, exif_imagetype"
+ ],
+ "imagealphablending": [
+ "bool imagealphablending(resource im, bool on)",
+ "Turn alpha blending mode on or off for the given image"
+ ],
+ "imageantialias": [
+ "bool imageantialias(resource im, bool on)",
+ "Should antialiased functions used or not"
+ ],
+ "imagearc": [
+ "bool imagearc(resource im, int cx, int cy, int w, int h, int s, int e, int col)",
+ "Draw a partial ellipse"
+ ],
+ "imagechar": [
+ "bool imagechar(resource im, int font, int x, int y, string c, int col)",
+ "Draw a character"
+ ],
+ "imagecharup": [
+ "bool imagecharup(resource im, int font, int x, int y, string c, int col)",
+ "Draw a character rotated 90 degrees counter-clockwise"
+ ],
+ "imagecolorallocate": [
+ "int imagecolorallocate(resource im, int red, int green, int blue)",
+ "Allocate a color for an image"
+ ],
+ "imagecolorallocatealpha": [
+ "int imagecolorallocatealpha(resource im, int red, int green, int blue, int alpha)",
+ "Allocate a color with an alpha level. Works for true color and palette based images"
+ ],
+ "imagecolorat": [
+ "int imagecolorat(resource im, int x, int y)",
+ "Get the index of the color of a pixel"
+ ],
+ "imagecolorclosest": [
+ "int imagecolorclosest(resource im, int red, int green, int blue)",
+ "Get the index of the closest color to the specified color"
+ ],
+ "imagecolorclosestalpha": [
+ "int imagecolorclosestalpha(resource im, int red, int green, int blue, int alpha)",
+ "Find the closest matching colour with alpha transparency"
+ ],
+ "imagecolorclosesthwb": [
+ "int imagecolorclosesthwb(resource im, int red, int green, int blue)",
+ "Get the index of the color which has the hue, white and blackness nearest to the given color"
+ ],
+ "imagecolordeallocate": [
+ "bool imagecolordeallocate(resource im, int index)",
+ "De-allocate a color for an image"
+ ],
+ "imagecolorexact": [
+ "int imagecolorexact(resource im, int red, int green, int blue)",
+ "Get the index of the specified color"
+ ],
+ "imagecolorexactalpha": [
+ "int imagecolorexactalpha(resource im, int red, int green, int blue, int alpha)",
+ "Find exact match for colour with transparency"
+ ],
+ "imagecolormatch": [
+ "bool imagecolormatch(resource im1, resource im2)",
+ "Makes the colors of the palette version of an image more closely match the true color version"
+ ],
+ "imagecolorresolve": [
+ "int imagecolorresolve(resource im, int red, int green, int blue)",
+ "Get the index of the specified color or its closest possible alternative"
+ ],
+ "imagecolorresolvealpha": [
+ "int imagecolorresolvealpha(resource im, int red, int green, int blue, int alpha)",
+ "Resolve/Allocate a colour with an alpha level. Works for true colour and palette based images"
+ ],
+ "imagecolorset": [
+ "void imagecolorset(resource im, int col, int red, int green, int blue)",
+ "Set the color for the specified palette index"
+ ],
+ "imagecolorsforindex": [
+ "array imagecolorsforindex(resource im, int col)",
+ "Get the colors for an index"
+ ],
+ "imagecolorstotal": [
+ "int imagecolorstotal(resource im)",
+ "Find out the number of colors in an image's palette"
+ ],
+ "imagecolortransparent": [
+ "int imagecolortransparent(resource im [, int col])",
+ "Define a color as transparent"
+ ],
+ "imageconvolution": [
+ "resource imageconvolution(resource src_im, array matrix3x3, double div, double offset)",
+ "Apply a 3x3 convolution matrix, using coefficient div and offset"
+ ],
+ "imagecopy": [
+ "bool imagecopy(resource dst_im, resource src_im, int dst_x, int dst_y, int src_x, int src_y, int src_w, int src_h)",
+ "Copy part of an image"
+ ],
+ "imagecopymerge": [
+ "bool imagecopymerge(resource src_im, resource dst_im, int dst_x, int dst_y, int src_x, int src_y, int src_w, int src_h, int pct)",
+ "Merge one part of an image with another"
+ ],
+ "imagecopymergegray": [
+ "bool imagecopymergegray(resource src_im, resource dst_im, int dst_x, int dst_y, int src_x, int src_y, int src_w, int src_h, int pct)",
+ "Merge one part of an image with another"
+ ],
+ "imagecopyresampled": [
+ "bool imagecopyresampled(resource dst_im, resource src_im, int dst_x, int dst_y, int src_x, int src_y, int dst_w, int dst_h, int src_w, int src_h)",
+ "Copy and resize part of an image using resampling to help ensure clarity"
+ ],
+ "imagecopyresized": [
+ "bool imagecopyresized(resource dst_im, resource src_im, int dst_x, int dst_y, int src_x, int src_y, int dst_w, int dst_h, int src_w, int src_h)",
+ "Copy and resize part of an image"
+ ],
+ "imagecreate": [
+ "resource imagecreate(int x_size, int y_size)",
+ "Create a new image"
+ ],
+ "imagecreatefromgd": [
+ "resource imagecreatefromgd(string filename)",
+ "Create a new image from GD file or URL"
+ ],
+ "imagecreatefromgd2": [
+ "resource imagecreatefromgd2(string filename)",
+ "Create a new image from GD2 file or URL"
+ ],
+ "imagecreatefromgd2part": [
+ "resource imagecreatefromgd2part(string filename, int srcX, int srcY, int width, int height)",
+ "Create a new image from a given part of GD2 file or URL"
+ ],
+ "imagecreatefromgif": [
+ "resource imagecreatefromgif(string filename)",
+ "Create a new image from GIF file or URL"
+ ],
+ "imagecreatefromjpeg": [
+ "resource imagecreatefromjpeg(string filename)",
+ "Create a new image from JPEG file or URL"
+ ],
+ "imagecreatefrompng": [
+ "resource imagecreatefrompng(string filename)",
+ "Create a new image from PNG file or URL"
+ ],
+ "imagecreatefromstring": [
+ "resource imagecreatefromstring(string image)",
+ "Create a new image from the image stream in the string"
+ ],
+ "imagecreatefromwbmp": [
+ "resource imagecreatefromwbmp(string filename)",
+ "Create a new image from WBMP file or URL"
+ ],
+ "imagecreatefromxbm": [
+ "resource imagecreatefromxbm(string filename)",
+ "Create a new image from XBM file or URL"
+ ],
+ "imagecreatefromxpm": [
+ "resource imagecreatefromxpm(string filename)",
+ "Create a new image from XPM file or URL"
+ ],
+ "imagecreatetruecolor": [
+ "resource imagecreatetruecolor(int x_size, int y_size)",
+ "Create a new true color image"
+ ],
+ "imagedashedline": [
+ "bool imagedashedline(resource im, int x1, int y1, int x2, int y2, int col)",
+ "Draw a dashed line"
+ ],
+ "imagedestroy": [
+ "bool imagedestroy(resource im)",
+ "Destroy an image"
+ ],
+ "imageellipse": [
+ "bool imageellipse(resource im, int cx, int cy, int w, int h, int color)",
+ "Draw an ellipse"
+ ],
+ "imagefill": [
+ "bool imagefill(resource im, int x, int y, int col)",
+ "Flood fill"
+ ],
+ "imagefilledarc": [
+ "bool imagefilledarc(resource im, int cx, int cy, int w, int h, int s, int e, int col, int style)",
+ "Draw a filled partial ellipse"
+ ],
+ "imagefilledellipse": [
+ "bool imagefilledellipse(resource im, int cx, int cy, int w, int h, int color)",
+ "Draw an ellipse"
+ ],
+ "imagefilledpolygon": [
+ "bool imagefilledpolygon(resource im, array point, int num_points, int col)",
+ "Draw a filled polygon"
+ ],
+ "imagefilledrectangle": [
+ "bool imagefilledrectangle(resource im, int x1, int y1, int x2, int y2, int col)",
+ "Draw a filled rectangle"
+ ],
+ "imagefilltoborder": [
+ "bool imagefilltoborder(resource im, int x, int y, int border, int col)",
+ "Flood fill to specific color"
+ ],
+ "imagefilter": [
+ "bool imagefilter(resource src_im, int filtertype, [args] )",
+ "Applies Filter an image using a custom angle"
+ ],
+ "imagefontheight": [
+ "int imagefontheight(int font)",
+ "Get font height"
+ ],
+ "imagefontwidth": [
+ "int imagefontwidth(int font)",
+ "Get font width"
+ ],
+ "imageftbbox": [
+ "array imageftbbox(float size, float angle, string font_file, string text [, array extrainfo])",
+ "Give the bounding box of a text using fonts via freetype2"
+ ],
+ "imagefttext": [
+ "array imagefttext(resource im, float size, float angle, int x, int y, int col, string font_file, string text [, array extrainfo])",
+ "Write text to the image using fonts via freetype2"
+ ],
+ "imagegammacorrect": [
+ "bool imagegammacorrect(resource im, float inputgamma, float outputgamma)",
+ "Apply a gamma correction to a GD image"
+ ],
+ "imagegd": [
+ "bool imagegd(resource im [, string filename])",
+ "Output GD image to browser or file"
+ ],
+ "imagegd2": [
+ "bool imagegd2(resource im [, string filename, [, int chunk_size, [, int type]]])",
+ "Output GD2 image to browser or file"
+ ],
+ "imagegif": [
+ "bool imagegif(resource im [, string filename])",
+ "Output GIF image to browser or file"
+ ],
+ "imagegrabscreen": [
+ "resource imagegrabscreen()",
+ "Grab a screenshot"
+ ],
+ "imagegrabwindow": [
+ "resource imagegrabwindow(int window_handle [, int client_area])",
+ "Grab a window or its client area using a windows handle (HWND property in COM instance)"
+ ],
+ "imageinterlace": [
+ "int imageinterlace(resource im [, int interlace])",
+ "Enable or disable interlace"
+ ],
+ "imageistruecolor": [
+ "bool imageistruecolor(resource im)",
+ "return true if the image uses truecolor"
+ ],
+ "imagejpeg": [
+ "bool imagejpeg(resource im [, string filename [, int quality]])",
+ "Output JPEG image to browser or file"
+ ],
+ "imagelayereffect": [
+ "bool imagelayereffect(resource im, int effect)",
+ "Set the alpha blending flag to use the bundled libgd layering effects"
+ ],
+ "imageline": [
+ "bool imageline(resource im, int x1, int y1, int x2, int y2, int col)",
+ "Draw a line"
+ ],
+ "imageloadfont": [
+ "int imageloadfont(string filename)",
+ "Load a new font"
+ ],
+ "imagepalettecopy": [
+ "void imagepalettecopy(resource dst, resource src)",
+ "Copy the palette from the src image onto the dst image"
+ ],
+ "imagepng": [
+ "bool imagepng(resource im [, string filename])",
+ "Output PNG image to browser or file"
+ ],
+ "imagepolygon": [
+ "bool imagepolygon(resource im, array point, int num_points, int col)",
+ "Draw a polygon"
+ ],
+ "imagepsbbox": [
+ "array imagepsbbox(string text, resource font, int size [, int space, int tightness, float angle])",
+ "Return the bounding box needed by a string if rasterized"
+ ],
+ "imagepscopyfont": [
+ "int imagepscopyfont(int font_index)",
+ "Make a copy of a font for purposes like extending or reenconding"
+ ],
+ "imagepsencodefont": [
+ "bool imagepsencodefont(resource font_index, string filename)",
+ "To change a fonts character encoding vector"
+ ],
+ "imagepsextendfont": [
+ "bool imagepsextendfont(resource font_index, float extend)",
+ "Extend or or condense (if extend < 1) a font"
+ ],
+ "imagepsfreefont": [
+ "bool imagepsfreefont(resource font_index)",
+ "Free memory used by a font"
+ ],
+ "imagepsloadfont": [
+ "resource imagepsloadfont(string pathname)",
+ "Load a new font from specified file"
+ ],
+ "imagepsslantfont": [
+ "bool imagepsslantfont(resource font_index, float slant)",
+ "Slant a font"
+ ],
+ "imagepstext": [
+ "array imagepstext(resource image, string text, resource font, int size, int foreground, int background, int xcoord, int ycoord [, int space [, int tightness [, float angle [, int antialias])",
+ "Rasterize a string over an image"
+ ],
+ "imagerectangle": [
+ "bool imagerectangle(resource im, int x1, int y1, int x2, int y2, int col)",
+ "Draw a rectangle"
+ ],
+ "imagerotate": [
+ "resource imagerotate(resource src_im, float angle, int bgdcolor [, int ignoretransparent])",
+ "Rotate an image using a custom angle"
+ ],
+ "imagesavealpha": [
+ "bool imagesavealpha(resource im, bool on)",
+ "Include alpha channel to a saved image"
+ ],
+ "imagesetbrush": [
+ "bool imagesetbrush(resource image, resource brush)",
+ "Set the brush image to $brush when filling $image with the \"IMG_COLOR_BRUSHED\" color"
+ ],
+ "imagesetpixel": [
+ "bool imagesetpixel(resource im, int x, int y, int col)",
+ "Set a single pixel"
+ ],
+ "imagesetstyle": [
+ "bool imagesetstyle(resource im, array styles)",
+ "Set the line drawing styles for use with imageline and IMG_COLOR_STYLED."
+ ],
+ "imagesetthickness": [
+ "bool imagesetthickness(resource im, int thickness)",
+ "Set line thickness for drawing lines, ellipses, rectangles, polygons etc."
+ ],
+ "imagesettile": [
+ "bool imagesettile(resource image, resource tile)",
+ "Set the tile image to $tile when filling $image with the \"IMG_COLOR_TILED\" color"
+ ],
+ "imagestring": [
+ "bool imagestring(resource im, int font, int x, int y, string str, int col)",
+ "Draw a string horizontally"
+ ],
+ "imagestringup": [
+ "bool imagestringup(resource im, int font, int x, int y, string str, int col)",
+ "Draw a string vertically - rotated 90 degrees counter-clockwise"
+ ],
+ "imagesx": [
+ "int imagesx(resource im)",
+ "Get image width"
+ ],
+ "imagesy": [
+ "int imagesy(resource im)",
+ "Get image height"
+ ],
+ "imagetruecolortopalette": [
+ "void imagetruecolortopalette(resource im, bool ditherFlag, int colorsWanted)",
+ "Convert a true colour image to a palette based image with a number of colours, optionally using dithering."
+ ],
+ "imagettfbbox": [
+ "array imagettfbbox(float size, float angle, string font_file, string text)",
+ "Give the bounding box of a text using TrueType fonts"
+ ],
+ "imagettftext": [
+ "array imagettftext(resource im, float size, float angle, int x, int y, int col, string font_file, string text)",
+ "Write text to the image using a TrueType font"
+ ],
+ "imagetypes": [
+ "int imagetypes(void)",
+ "Return the types of images supported in a bitfield - 1=GIF, 2=JPEG, 4=PNG, 8=WBMP, 16=XPM"
+ ],
+ "imagewbmp": [
+ "bool imagewbmp(resource im [, string filename, [, int foreground]])",
+ "Output WBMP image to browser or file"
+ ],
+ "imagexbm": [
+ "int imagexbm(int im, string filename [, int foreground])",
+ "Output XBM image to browser or file"
+ ],
+ "imap_8bit": [
+ "string imap_8bit(string text)",
+ "Convert an 8-bit string to a quoted-printable string"
+ ],
+ "imap_alerts": [
+ "array imap_alerts(void)",
+ "Returns an array of all IMAP alerts that have been generated since the last page load or since the last imap_alerts() call, whichever came last. The alert stack is cleared after imap_alerts() is called."
+ ],
+ "imap_append": [
+ "bool imap_append(resource stream_id, string folder, string message [, string options [, string internal_date]])",
+ "Append a new message to a specified mailbox"
+ ],
+ "imap_base64": [
+ "string imap_base64(string text)",
+ "Decode BASE64 encoded text"
+ ],
+ "imap_binary": [
+ "string imap_binary(string text)",
+ "Convert an 8bit string to a base64 string"
+ ],
+ "imap_body": [
+ "string imap_body(resource stream_id, int msg_no [, int options])",
+ "Read the message body"
+ ],
+ "imap_bodystruct": [
+ "object imap_bodystruct(resource stream_id, int msg_no, string section)",
+ "Read the structure of a specified body section of a specific message"
+ ],
+ "imap_check": [
+ "object imap_check(resource stream_id)",
+ "Get mailbox properties"
+ ],
+ "imap_clearflag_full": [
+ "bool imap_clearflag_full(resource stream_id, string sequence, string flag [, int options])",
+ "Clears flags on messages"
+ ],
+ "imap_close": [
+ "bool imap_close(resource stream_id [, int options])",
+ "Close an IMAP stream"
+ ],
+ "imap_createmailbox": [
+ "bool imap_createmailbox(resource stream_id, string mailbox)",
+ "Create a new mailbox"
+ ],
+ "imap_delete": [
+ "bool imap_delete(resource stream_id, int msg_no [, int options])",
+ "Mark a message for deletion"
+ ],
+ "imap_deletemailbox": [
+ "bool imap_deletemailbox(resource stream_id, string mailbox)",
+ "Delete a mailbox"
+ ],
+ "imap_errors": [
+ "array imap_errors(void)",
+ "Returns an array of all IMAP errors generated since the last page load, or since the last imap_errors() call, whichever came last. The error stack is cleared after imap_errors() is called."
+ ],
+ "imap_expunge": [
+ "bool imap_expunge(resource stream_id)",
+ "Permanently delete all messages marked for deletion"
+ ],
+ "imap_fetch_overview": [
+ "array imap_fetch_overview(resource stream_id, string sequence [, int options])",
+ "Read an overview of the information in the headers of the given message sequence"
+ ],
+ "imap_fetchbody": [
+ "string imap_fetchbody(resource stream_id, int msg_no, string section [, int options])",
+ "Get a specific body section"
+ ],
+ "imap_fetchheader": [
+ "string imap_fetchheader(resource stream_id, int msg_no [, int options])",
+ "Get the full unfiltered header for a message"
+ ],
+ "imap_fetchstructure": [
+ "object imap_fetchstructure(resource stream_id, int msg_no [, int options])",
+ "Read the full structure of a message"
+ ],
+ "imap_gc": [
+ "bool imap_gc(resource stream_id, int flags)",
+ "This function garbage collects (purges) the cache of entries of a specific type."
+ ],
+ "imap_get_quota": [
+ "array imap_get_quota(resource stream_id, string qroot)",
+ "Returns the quota set to the mailbox account qroot"
+ ],
+ "imap_get_quotaroot": [
+ "array imap_get_quotaroot(resource stream_id, string mbox)",
+ "Returns the quota set to the mailbox account mbox"
+ ],
+ "imap_getacl": [
+ "array imap_getacl(resource stream_id, string mailbox)",
+ "Gets the ACL for a given mailbox"
+ ],
+ "imap_getmailboxes": [
+ "array imap_getmailboxes(resource stream_id, string ref, string pattern)",
+ "Reads the list of mailboxes and returns a full array of objects containing name, attributes, and delimiter"
+ ],
+ "imap_getsubscribed": [
+ "array imap_getsubscribed(resource stream_id, string ref, string pattern)",
+ "Return a list of subscribed mailboxes, in the same format as imap_getmailboxes()"
+ ],
+ "imap_headerinfo": [
+ "object imap_headerinfo(resource stream_id, int msg_no [, int from_length [, int subject_length [, string default_host]]])",
+ "Read the headers of the message"
+ ],
+ "imap_headers": [
+ "array imap_headers(resource stream_id)",
+ "Returns headers for all messages in a mailbox"
+ ],
+ "imap_last_error": [
+ "string imap_last_error(void)",
+ "Returns the last error that was generated by an IMAP function. The error stack is NOT cleared after this call."
+ ],
+ "imap_list": [
+ "array imap_list(resource stream_id, string ref, string pattern)",
+ "Read the list of mailboxes"
+ ],
+ "imap_listscan": [
+ "array imap_listscan(resource stream_id, string ref, string pattern, string content)",
+ "Read list of mailboxes containing a certain string"
+ ],
+ "imap_lsub": [
+ "array imap_lsub(resource stream_id, string ref, string pattern)",
+ "Return a list of subscribed mailboxes"
+ ],
+ "imap_mail": [
+ "bool imap_mail(string to, string subject, string message [, string additional_headers [, string cc [, string bcc [, string rpath]]]])",
+ "Send an email message"
+ ],
+ "imap_mail_compose": [
+ "string imap_mail_compose(array envelope, array body)",
+ "Create a MIME message based on given envelope and body sections"
+ ],
+ "imap_mail_copy": [
+ "bool imap_mail_copy(resource stream_id, string msglist, string mailbox [, int options])",
+ "Copy specified message to a mailbox"
+ ],
+ "imap_mail_move": [
+ "bool imap_mail_move(resource stream_id, string sequence, string mailbox [, int options])",
+ "Move specified message to a mailbox"
+ ],
+ "imap_mailboxmsginfo": [
+ "object imap_mailboxmsginfo(resource stream_id)",
+ "Returns info about the current mailbox"
+ ],
+ "imap_mime_header_decode": [
+ "array imap_mime_header_decode(string str)",
+ "Decode mime header element in accordance with RFC 2047 and return array of objects containing 'charset' encoding and decoded 'text'"
+ ],
+ "imap_msgno": [
+ "int imap_msgno(resource stream_id, int unique_msg_id)",
+ "Get the sequence number associated with a UID"
+ ],
+ "imap_mutf7_to_utf8": [
+ "string imap_mutf7_to_utf8(string in)",
+ "Decode a modified UTF-7 string to UTF-8"
+ ],
+ "imap_num_msg": [
+ "int imap_num_msg(resource stream_id)",
+ "Gives the number of messages in the current mailbox"
+ ],
+ "imap_num_recent": [
+ "int imap_num_recent(resource stream_id)",
+ "Gives the number of recent messages in current mailbox"
+ ],
+ "imap_open": [
+ "resource imap_open(string mailbox, string user, string password [, int options [, int n_retries]])",
+ "Open an IMAP stream to a mailbox"
+ ],
+ "imap_ping": [
+ "bool imap_ping(resource stream_id)",
+ "Check if the IMAP stream is still active"
+ ],
+ "imap_qprint": [
+ "string imap_qprint(string text)",
+ "Convert a quoted-printable string to an 8-bit string"
+ ],
+ "imap_renamemailbox": [
+ "bool imap_renamemailbox(resource stream_id, string old_name, string new_name)",
+ "Rename a mailbox"
+ ],
+ "imap_reopen": [
+ "bool imap_reopen(resource stream_id, string mailbox [, int options [, int n_retries]])",
+ "Reopen an IMAP stream to a new mailbox"
+ ],
+ "imap_rfc822_parse_adrlist": [
+ "array imap_rfc822_parse_adrlist(string address_string, string default_host)",
+ "Parses an address string"
+ ],
+ "imap_rfc822_parse_headers": [
+ "object imap_rfc822_parse_headers(string headers [, string default_host])",
+ "Parse a set of mail headers contained in a string, and return an object similar to imap_headerinfo()"
+ ],
+ "imap_rfc822_write_address": [
+ "string imap_rfc822_write_address(string mailbox, string host, string personal)",
+ "Returns a properly formatted email address given the mailbox, host, and personal info"
+ ],
+ "imap_savebody": [
+ "bool imap_savebody(resource stream_id, string|resource file, int msg_no[, string section = \"\"[, int options = 0]])",
+ "Save a specific body section to a file"
+ ],
+ "imap_search": [
+ "array imap_search(resource stream_id, string criteria [, int options [, string charset]])",
+ "Return a list of messages matching the given criteria"
+ ],
+ "imap_set_quota": [
+ "bool imap_set_quota(resource stream_id, string qroot, int mailbox_size)",
+ "Will set the quota for qroot mailbox"
+ ],
+ "imap_setacl": [
+ "bool imap_setacl(resource stream_id, string mailbox, string id, string rights)",
+ "Sets the ACL for a given mailbox"
+ ],
+ "imap_setflag_full": [
+ "bool imap_setflag_full(resource stream_id, string sequence, string flag [, int options])",
+ "Sets flags on messages"
+ ],
+ "imap_sort": [
+ "array imap_sort(resource stream_id, int criteria, int reverse [, int options [, string search_criteria [, string charset]]])",
+ "Sort an array of message headers, optionally including only messages that meet specified criteria."
+ ],
+ "imap_status": [
+ "object imap_status(resource stream_id, string mailbox, int options)",
+ "Get status info from a mailbox"
+ ],
+ "imap_subscribe": [
+ "bool imap_subscribe(resource stream_id, string mailbox)",
+ "Subscribe to a mailbox"
+ ],
+ "imap_thread": [
+ "array imap_thread(resource stream_id [, int options])",
+ "Return threaded by REFERENCES tree"
+ ],
+ "imap_timeout": [
+ "mixed imap_timeout(int timeout_type [, int timeout])",
+ "Set or fetch imap timeout"
+ ],
+ "imap_uid": [
+ "int imap_uid(resource stream_id, int msg_no)",
+ "Get the unique message id associated with a standard sequential message number"
+ ],
+ "imap_undelete": [
+ "bool imap_undelete(resource stream_id, int msg_no [, int flags])",
+ "Remove the delete flag from a message"
+ ],
+ "imap_unsubscribe": [
+ "bool imap_unsubscribe(resource stream_id, string mailbox)",
+ "Unsubscribe from a mailbox"
+ ],
+ "imap_utf7_decode": [
+ "string imap_utf7_decode(string buf)",
+ "Decode a modified UTF-7 string"
+ ],
+ "imap_utf7_encode": [
+ "string imap_utf7_encode(string buf)",
+ "Encode a string in modified UTF-7"
+ ],
+ "imap_utf8": [
+ "string imap_utf8(string mime_encoded_text)",
+ "Convert a mime-encoded text to UTF-8"
+ ],
+ "imap_utf8_to_mutf7": [
+ "string imap_utf8_to_mutf7(string in)",
+ "Encode a UTF-8 string to modified UTF-7"
+ ],
+ "implode": [
+ "string implode([string glue,] array pieces)",
+ "Joins array elements placing glue string between items and return one string"
+ ],
+ "import_request_variables": [
+ "bool import_request_variables(string types [, string prefix])",
+ "Import GET/POST/Cookie variables into the global scope"
+ ],
+ "in_array": [
+ "bool in_array(mixed needle, array haystack [, bool strict])",
+ "Checks if the given value exists in the array"
+ ],
+ "include": [
+ "bool include(string path)",
+ "Includes and evaluates the specified file"
+ ],
+ "include_once": [
+ "bool include_once(string path)",
+ "Includes and evaluates the specified file"
+ ],
+ "inet_ntop": [
+ "string inet_ntop(string in_addr)",
+ "Converts a packed inet address to a human readable IP address string"
+ ],
+ "inet_pton": [
+ "string inet_pton(string ip_address)",
+ "Converts a human readable IP address to a packed binary string"
+ ],
+ "ini_get": [
+ "string ini_get(string varname)",
+ "Get a configuration option"
+ ],
+ "ini_get_all": [
+ "array ini_get_all([string extension[, bool details = true]])",
+ "Get all configuration options"
+ ],
+ "ini_restore": [
+ "void ini_restore(string varname)",
+ "Restore the value of a configuration option specified by varname"
+ ],
+ "ini_set": [
+ "string ini_set(string varname, string newvalue)",
+ "Set a configuration option, returns false on error and the old value of the configuration option on success"
+ ],
+ "interface_exists": [
+ "bool interface_exists(string classname [, bool autoload])",
+ "Checks if the class exists"
+ ],
+ "intl_error_name": [
+ "string intl_error_name()",
+ "* Return a string for a given error code. * The string will be the same as the name of the error code constant."
+ ],
+ "intl_get_error_code": [
+ "int intl_get_error_code()",
+ "* Get code of the last occured error."
+ ],
+ "intl_get_error_message": [
+ "string intl_get_error_message()",
+ "* Get text description of the last occured error."
+ ],
+ "intl_is_failure": [
+ "bool intl_is_failure()",
+ "* Check whether the given error code indicates a failure. * Returns true if it does, and false if the code * indicates success or a warning."
+ ],
+ "intval": [
+ "int intval(mixed var [, int base])",
+ "Get the integer value of a variable using the optional base for the conversion"
+ ],
+ "ip2long": [
+ "int ip2long(string ip_address)",
+ "Converts a string containing an (IPv4) Internet Protocol dotted address into a proper address"
+ ],
+ "iptcembed": [
+ "array iptcembed(string iptcdata, string jpeg_file_name [, int spool])",
+ "Embed binary IPTC data into a JPEG image."
+ ],
+ "iptcparse": [
+ "array iptcparse(string iptcdata)",
+ "Parse binary IPTC-data into associative array"
+ ],
+ "is_a": [
+ "bool is_a(object object, string class_name)",
+ "Returns true if the object is of this class or has this class as one of its parents"
+ ],
+ "is_array": [
+ "bool is_array(mixed var)",
+ "Returns true if variable is an array"
+ ],
+ "is_bool": [
+ "bool is_bool(mixed var)",
+ "Returns true if variable is a boolean"
+ ],
+ "is_callable": [
+ "bool is_callable(mixed var [, bool syntax_only [, string callable_name]])",
+ "Returns true if var is callable."
+ ],
+ "is_dir": [
+ "bool is_dir(string filename)",
+ "Returns true if file is directory"
+ ],
+ "is_executable": [
+ "bool is_executable(string filename)",
+ "Returns true if file is executable"
+ ],
+ "is_file": [
+ "bool is_file(string filename)",
+ "Returns true if file is a regular file"
+ ],
+ "is_finite": [
+ "bool is_finite(float val)",
+ "Returns whether argument is finite"
+ ],
+ "is_float": [
+ "bool is_float(mixed var)",
+ "Returns true if variable is float point"
+ ],
+ "is_infinite": [
+ "bool is_infinite(float val)",
+ "Returns whether argument is infinite"
+ ],
+ "is_link": [
+ "bool is_link(string filename)",
+ "Returns true if file is symbolic link"
+ ],
+ "is_long": [
+ "bool is_long(mixed var)",
+ "Returns true if variable is a long (integer)"
+ ],
+ "is_nan": [
+ "bool is_nan(float val)",
+ "Returns whether argument is not a number"
+ ],
+ "is_null": [
+ "bool is_null(mixed var)",
+ "Returns true if variable is null"
+ ],
+ "is_numeric": [
+ "bool is_numeric(mixed value)",
+ "Returns true if value is a number or a numeric string"
+ ],
+ "is_object": [
+ "bool is_object(mixed var)",
+ "Returns true if variable is an object"
+ ],
+ "is_readable": [
+ "bool is_readable(string filename)",
+ "Returns true if file can be read"
+ ],
+ "is_resource": [
+ "bool is_resource(mixed var)",
+ "Returns true if variable is a resource"
+ ],
+ "is_scalar": [
+ "bool is_scalar(mixed value)",
+ "Returns true if value is a scalar"
+ ],
+ "is_string": [
+ "bool is_string(mixed var)",
+ "Returns true if variable is a string"
+ ],
+ "is_subclass_of": [
+ "bool is_subclass_of(object object, string class_name)",
+ "Returns true if the object has this class as one of its parents"
+ ],
+ "is_uploaded_file": [
+ "bool is_uploaded_file(string path)",
+ "Check if file was created by rfc1867 upload"
+ ],
+ "is_writable": [
+ "bool is_writable(string filename)",
+ "Returns true if file can be written"
+ ],
+ "isset": [
+ "bool isset(mixed var [, mixed var])",
+ "Determine whether a variable is set"
+ ],
+ "iterator_apply": [
+ "int iterator_apply(Traversable it, mixed function [, mixed params])",
+ "Calls a function for every element in an iterator"
+ ],
+ "iterator_count": [
+ "int iterator_count(Traversable it)",
+ "Count the elements in an iterator"
+ ],
+ "iterator_to_array": [
+ "array iterator_to_array(Traversable it [, bool use_keys = true])",
+ "Copy the iterator into an array"
+ ],
+ "jddayofweek": [
+ "mixed jddayofweek(int juliandaycount [, int mode])",
+ "Returns name or number of day of week from julian day count"
+ ],
+ "jdmonthname": [
+ "string jdmonthname(int juliandaycount, int mode)",
+ "Returns name of month for julian day count"
+ ],
+ "jdtofrench": [
+ "string jdtofrench(int juliandaycount)",
+ "Converts a julian day count to a french republic calendar date"
+ ],
+ "jdtogregorian": [
+ "string jdtogregorian(int juliandaycount)",
+ "Converts a julian day count to a gregorian calendar date"
+ ],
+ "jdtojewish": [
+ "string jdtojewish(int juliandaycount [, bool hebrew [, int fl]])",
+ "Converts a julian day count to a jewish calendar date"
+ ],
+ "jdtojulian": [
+ "string jdtojulian(int juliandaycount)",
+ "Convert a julian day count to a julian calendar date"
+ ],
+ "jdtounix": [
+ "int jdtounix(int jday)",
+ "Convert Julian Day to UNIX timestamp"
+ ],
+ "jewishtojd": [
+ "int jewishtojd(int month, int day, int year)",
+ "Converts a jewish calendar date to a julian day count"
+ ],
+ "join": [
+ "string join(array src, string glue)",
+ "An alias for implode"
+ ],
+ "jpeg2wbmp": [
+ "bool jpeg2wbmp (string f_org, string f_dest, int d_height, int d_width, int threshold)",
+ "Convert JPEG image to WBMP image"
+ ],
+ "json_decode": [
+ "mixed json_decode(string json [, bool assoc [, long depth]])",
+ "Decodes the JSON representation into a PHP value"
+ ],
+ "json_encode": [
+ "string json_encode(mixed data [, int options])",
+ "Returns the JSON representation of a value"
+ ],
+ "json_last_error": [
+ "int json_last_error()",
+ "Returns the error code of the last json_decode()."
+ ],
+ "juliantojd": [
+ "int juliantojd(int month, int day, int year)",
+ "Converts a julian calendar date to julian day count"
+ ],
+ "key": [
+ "mixed key(array array_arg)",
+ "Return the key of the element currently pointed to by the internal array pointer"
+ ],
+ "krsort": [
+ "bool krsort(array &array_arg [, int sort_flags])",
+ "Sort an array by key value in reverse order"
+ ],
+ "ksort": [
+ "bool ksort(array &array_arg [, int sort_flags])",
+ "Sort an array by key"
+ ],
+ "lcfirst": [
+ "string lcfirst(string str)",
+ "Make a string's first character lowercase"
+ ],
+ "lcg_value": [
+ "float lcg_value()",
+ "Returns a value from the combined linear congruential generator"
+ ],
+ "lchgrp": [
+ "bool lchgrp(string filename, mixed group)",
+ "Change symlink group"
+ ],
+ "ldap_8859_to_t61": [
+ "string ldap_8859_to_t61(string value)",
+ "Translate 8859 characters to t61 characters"
+ ],
+ "ldap_add": [
+ "bool ldap_add(resource link, string dn, array entry)",
+ "Add entries to LDAP directory"
+ ],
+ "ldap_bind": [
+ "bool ldap_bind(resource link [, string dn [, string password]])",
+ "Bind to LDAP directory"
+ ],
+ "ldap_compare": [
+ "bool ldap_compare(resource link, string dn, string attr, string value)",
+ "Determine if an entry has a specific value for one of its attributes"
+ ],
+ "ldap_connect": [
+ "resource ldap_connect([string host [, int port [, string wallet [, string wallet_passwd [, int authmode]]]]])",
+ "Connect to an LDAP server"
+ ],
+ "ldap_count_entries": [
+ "int ldap_count_entries(resource link, resource result)",
+ "Count the number of entries in a search result"
+ ],
+ "ldap_delete": [
+ "bool ldap_delete(resource link, string dn)",
+ "Delete an entry from a directory"
+ ],
+ "ldap_dn2ufn": [
+ "string ldap_dn2ufn(string dn)",
+ "Convert DN to User Friendly Naming format"
+ ],
+ "ldap_err2str": [
+ "string ldap_err2str(int errno)",
+ "Convert error number to error string"
+ ],
+ "ldap_errno": [
+ "int ldap_errno(resource link)",
+ "Get the current ldap error number"
+ ],
+ "ldap_error": [
+ "string ldap_error(resource link)",
+ "Get the current ldap error string"
+ ],
+ "ldap_explode_dn": [
+ "array ldap_explode_dn(string dn, int with_attrib)",
+ "Splits DN into its component parts"
+ ],
+ "ldap_first_attribute": [
+ "string ldap_first_attribute(resource link, resource result_entry)",
+ "Return first attribute"
+ ],
+ "ldap_first_entry": [
+ "resource ldap_first_entry(resource link, resource result)",
+ "Return first result id"
+ ],
+ "ldap_first_reference": [
+ "resource ldap_first_reference(resource link, resource result)",
+ "Return first reference"
+ ],
+ "ldap_free_result": [
+ "bool ldap_free_result(resource result)",
+ "Free result memory"
+ ],
+ "ldap_get_attributes": [
+ "array ldap_get_attributes(resource link, resource result_entry)",
+ "Get attributes from a search result entry"
+ ],
+ "ldap_get_dn": [
+ "string ldap_get_dn(resource link, resource result_entry)",
+ "Get the DN of a result entry"
+ ],
+ "ldap_get_entries": [
+ "array ldap_get_entries(resource link, resource result)",
+ "Get all result entries"
+ ],
+ "ldap_get_option": [
+ "bool ldap_get_option(resource link, int option, mixed retval)",
+ "Get the current value of various session-wide parameters"
+ ],
+ "ldap_get_values_len": [
+ "array ldap_get_values_len(resource link, resource result_entry, string attribute)",
+ "Get all values with lengths from a result entry"
+ ],
+ "ldap_list": [
+ "resource ldap_list(resource|array link, string base_dn, string filter [, array attrs [, int attrsonly [, int sizelimit [, int timelimit [, int deref]]]]])",
+ "Single-level search"
+ ],
+ "ldap_mod_add": [
+ "bool ldap_mod_add(resource link, string dn, array entry)",
+ "Add attribute values to current"
+ ],
+ "ldap_mod_del": [
+ "bool ldap_mod_del(resource link, string dn, array entry)",
+ "Delete attribute values"
+ ],
+ "ldap_mod_replace": [
+ "bool ldap_mod_replace(resource link, string dn, array entry)",
+ "Replace attribute values with new ones"
+ ],
+ "ldap_next_attribute": [
+ "string ldap_next_attribute(resource link, resource result_entry)",
+ "Get the next attribute in result"
+ ],
+ "ldap_next_entry": [
+ "resource ldap_next_entry(resource link, resource result_entry)",
+ "Get next result entry"
+ ],
+ "ldap_next_reference": [
+ "resource ldap_next_reference(resource link, resource reference_entry)",
+ "Get next reference"
+ ],
+ "ldap_parse_reference": [
+ "bool ldap_parse_reference(resource link, resource reference_entry, array referrals)",
+ "Extract information from reference entry"
+ ],
+ "ldap_parse_result": [
+ "bool ldap_parse_result(resource link, resource result, int errcode, string matcheddn, string errmsg, array referrals)",
+ "Extract information from result"
+ ],
+ "ldap_read": [
+ "resource ldap_read(resource|array link, string base_dn, string filter [, array attrs [, int attrsonly [, int sizelimit [, int timelimit [, int deref]]]]])",
+ "Read an entry"
+ ],
+ "ldap_rename": [
+ "bool ldap_rename(resource link, string dn, string newrdn, string newparent, bool deleteoldrdn);",
+ "Modify the name of an entry"
+ ],
+ "ldap_sasl_bind": [
+ "bool ldap_sasl_bind(resource link [, string binddn [, string password [, string sasl_mech [, string sasl_realm [, string sasl_authc_id [, string sasl_authz_id [, string props]]]]]]])",
+ "Bind to LDAP directory using SASL"
+ ],
+ "ldap_search": [
+ "resource ldap_search(resource|array link, string base_dn, string filter [, array attrs [, int attrsonly [, int sizelimit [, int timelimit [, int deref]]]]])",
+ "Search LDAP tree under base_dn"
+ ],
+ "ldap_set_option": [
+ "bool ldap_set_option(resource link, int option, mixed newval)",
+ "Set the value of various session-wide parameters"
+ ],
+ "ldap_set_rebind_proc": [
+ "bool ldap_set_rebind_proc(resource link, string callback)",
+ "Set a callback function to do re-binds on referral chasing."
+ ],
+ "ldap_sort": [
+ "bool ldap_sort(resource link, resource result, string sortfilter)",
+ "Sort LDAP result entries"
+ ],
+ "ldap_start_tls": [
+ "bool ldap_start_tls(resource link)",
+ "Start TLS"
+ ],
+ "ldap_t61_to_8859": [
+ "string ldap_t61_to_8859(string value)",
+ "Translate t61 characters to 8859 characters"
+ ],
+ "ldap_unbind": [
+ "bool ldap_unbind(resource link)",
+ "Unbind from LDAP directory"
+ ],
+ "leak": [
+ "void leak(int num_bytes=3)",
+ "Cause an intentional memory leak, for testing/debugging purposes"
+ ],
+ "levenshtein": [
+ "int levenshtein(string str1, string str2[, int cost_ins, int cost_rep, int cost_del])",
+ "Calculate Levenshtein distance between two strings"
+ ],
+ "libxml_clear_errors": [
+ "void libxml_clear_errors()",
+ "Clear last error from libxml"
+ ],
+ "libxml_disable_entity_loader": [
+ "bool libxml_disable_entity_loader([boolean disable])",
+ "Disable/Enable ability to load external entities"
+ ],
+ "libxml_get_errors": [
+ "object libxml_get_errors()",
+ "Retrieve array of errors"
+ ],
+ "libxml_get_last_error": [
+ "object libxml_get_last_error()",
+ "Retrieve last error from libxml"
+ ],
+ "libxml_set_streams_context": [
+ "void libxml_set_streams_context(resource streams_context)",
+ "Set the streams context for the next libxml document load or write"
+ ],
+ "libxml_use_internal_errors": [
+ "bool libxml_use_internal_errors([boolean use_errors])",
+ "Disable libxml errors and allow user to fetch error information as needed"
+ ],
+ "link": [
+ "int link(string target, string link)",
+ "Create a hard link"
+ ],
+ "linkinfo": [
+ "int linkinfo(string filename)",
+ "Returns the st_dev field of the UNIX C stat structure describing the link"
+ ],
+ "litespeed_request_headers": [
+ "array litespeed_request_headers(void)",
+ "Fetch all HTTP request headers"
+ ],
+ "litespeed_response_headers": [
+ "array litespeed_response_headers(void)",
+ "Fetch all HTTP response headers"
+ ],
+ "locale_accept_from_http": [
+ "string locale_accept_from_http(string $http_accept)",
+ null
+ ],
+ "locale_canonicalize": [
+ "static string locale_canonicalize(Locale $loc, string $locale)",
+ "* @param string $locale The locale string to canonicalize"
+ ],
+ "locale_filter_matches": [
+ "boolean locale_filter_matches(string $langtag, string $locale[, bool $canonicalize])",
+ "* Checks if a $langtag filter matches with $locale according to RFC 4647's basic filtering algorithm"
+ ],
+ "locale_get_all_variants": [
+ "static array locale_get_all_variants($locale)",
+ "* gets an array containing the list of variants, or null"
+ ],
+ "locale_get_default": [
+ "static string locale_get_default( )",
+ "Get default locale"
+ ],
+ "locale_get_keywords": [
+ "static array locale_get_keywords(string $locale) {",
+ "* return an associative array containing keyword-value * pairs for this locale. The keys are keys to the array (doh!)"
+ ],
+ "locale_get_primary_language": [
+ "static string locale_get_primary_language($locale)",
+ "* gets the primary language for the $locale"
+ ],
+ "locale_get_region": [
+ "static string locale_get_region($locale)",
+ "* gets the region for the $locale"
+ ],
+ "locale_get_script": [
+ "static string locale_get_script($locale)",
+ "* gets the script for the $locale"
+ ],
+ "locale_lookup": [
+ "string locale_lookup(array $langtag, string $locale[, bool $canonicalize[, string $default = null]])",
+ "* Searchs the items in $langtag for the best match to the language * range"
+ ],
+ "locale_set_default": [
+ "static string locale_set_default( string $locale )",
+ "Set default locale"
+ ],
+ "localeconv": [
+ "array localeconv(void)",
+ "Returns numeric formatting information based on the current locale"
+ ],
+ "localtime": [
+ "array localtime([int timestamp [, bool associative_array]])",
+ "Returns the results of the C system call localtime as an associative array if the associative_array argument is set to 1 other wise it is a regular array"
+ ],
+ "log": [
+ "float log(float number, [float base])",
+ "Returns the natural logarithm of the number, or the base log if base is specified"
+ ],
+ "log10": [
+ "float log10(float number)",
+ "Returns the base-10 logarithm of the number"
+ ],
+ "log1p": [
+ "float log1p(float number)",
+ "Returns log(1 + number), computed in a way that accurate even when the value of number is close to zero"
+ ],
+ "long2ip": [
+ "string long2ip(int proper_address)",
+ "Converts an (IPv4) Internet network address into a string in Internet standard dotted format"
+ ],
+ "lstat": [
+ "array lstat(string filename)",
+ "Give information about a file or symbolic link"
+ ],
+ "ltrim": [
+ "string ltrim(string str [, string character_mask])",
+ "Strips whitespace from the beginning of a string"
+ ],
+ "mail": [
+ "int mail(string to, string subject, string message [, string additional_headers [, string additional_parameters]])",
+ "Send an email message"
+ ],
+ "max": [
+ "mixed max(mixed arg1 [, mixed arg2 [, mixed ...]])",
+ "Return the highest value in an array or a series of arguments"
+ ],
+ "mb_check_encoding": [
+ "bool mb_check_encoding([string var[, string encoding]])",
+ "Check if the string is valid for the specified encoding"
+ ],
+ "mb_convert_case": [
+ "string mb_convert_case(string sourcestring, int mode [, string encoding])",
+ "Returns a case-folded version of sourcestring"
+ ],
+ "mb_convert_encoding": [
+ "string mb_convert_encoding(string str, string to-encoding [, mixed from-encoding])",
+ "Returns converted string in desired encoding"
+ ],
+ "mb_convert_kana": [
+ "string mb_convert_kana(string str [, string option] [, string encoding])",
+ "Conversion between full-width character and half-width character (Japanese)"
+ ],
+ "mb_convert_variables": [
+ "string mb_convert_variables(string to-encoding, mixed from-encoding, mixed vars [, ...])",
+ "Converts the string resource in variables to desired encoding"
+ ],
+ "mb_decode_mimeheader": [
+ "string mb_decode_mimeheader(string string)",
+ "Decodes the MIME \"encoded-word\" in the string"
+ ],
+ "mb_decode_numericentity": [
+ "string mb_decode_numericentity(string string, array convmap [, string encoding])",
+ "Converts HTML numeric entities to character code"
+ ],
+ "mb_detect_encoding": [
+ "string mb_detect_encoding(string str [, mixed encoding_list [, bool strict]])",
+ "Encodings of the given string is returned (as a string)"
+ ],
+ "mb_detect_order": [
+ "bool|array mb_detect_order([mixed encoding-list])",
+ "Sets the current detect_order or Return the current detect_order as a array"
+ ],
+ "mb_encode_mimeheader": [
+ "string mb_encode_mimeheader(string str [, string charset [, string transfer-encoding [, string linefeed [, int indent]]]])",
+ "Converts the string to MIME \"encoded-word\" in the format of =?charset?(B|Q)?encoded_string?="
+ ],
+ "mb_encode_numericentity": [
+ "string mb_encode_numericentity(string string, array convmap [, string encoding])",
+ "Converts specified characters to HTML numeric entities"
+ ],
+ "mb_encoding_aliases": [
+ "array mb_encoding_aliases(string encoding)",
+ "Returns an array of the aliases of a given encoding name"
+ ],
+ "mb_ereg": [
+ "int mb_ereg(string pattern, string string [, array registers])",
+ "Regular expression match for multibyte string"
+ ],
+ "mb_ereg_match": [
+ "bool mb_ereg_match(string pattern, string string [,string option])",
+ "Regular expression match for multibyte string"
+ ],
+ "mb_ereg_replace": [
+ "string mb_ereg_replace(string pattern, string replacement, string string [, string option])",
+ "Replace regular expression for multibyte string"
+ ],
+ "mb_ereg_search": [
+ "bool mb_ereg_search([string pattern[, string option]])",
+ "Regular expression search for multibyte string"
+ ],
+ "mb_ereg_search_getpos": [
+ "int mb_ereg_search_getpos(void)",
+ "Get search start position"
+ ],
+ "mb_ereg_search_getregs": [
+ "array mb_ereg_search_getregs(void)",
+ "Get matched substring of the last time"
+ ],
+ "mb_ereg_search_init": [
+ "bool mb_ereg_search_init(string string [, string pattern[, string option]])",
+ "Initialize string and regular expression for search."
+ ],
+ "mb_ereg_search_pos": [
+ "array mb_ereg_search_pos([string pattern[, string option]])",
+ "Regular expression search for multibyte string"
+ ],
+ "mb_ereg_search_regs": [
+ "array mb_ereg_search_regs([string pattern[, string option]])",
+ "Regular expression search for multibyte string"
+ ],
+ "mb_ereg_search_setpos": [
+ "bool mb_ereg_search_setpos(int position)",
+ "Set search start position"
+ ],
+ "mb_eregi": [
+ "int mb_eregi(string pattern, string string [, array registers])",
+ "Case-insensitive regular expression match for multibyte string"
+ ],
+ "mb_eregi_replace": [
+ "string mb_eregi_replace(string pattern, string replacement, string string)",
+ "Case insensitive replace regular expression for multibyte string"
+ ],
+ "mb_get_info": [
+ "mixed mb_get_info([string type])",
+ "Returns the current settings of mbstring"
+ ],
+ "mb_http_input": [
+ "mixed mb_http_input([string type])",
+ "Returns the input encoding"
+ ],
+ "mb_http_output": [
+ "string mb_http_output([string encoding])",
+ "Sets the current output_encoding or returns the current output_encoding as a string"
+ ],
+ "mb_internal_encoding": [
+ "string mb_internal_encoding([string encoding])",
+ "Sets the current internal encoding or Returns the current internal encoding as a string"
+ ],
+ "mb_language": [
+ "string mb_language([string language])",
+ "Sets the current language or Returns the current language as a string"
+ ],
+ "mb_list_encodings": [
+ "mixed mb_list_encodings()",
+ "Returns an array of all supported entity encodings"
+ ],
+ "mb_output_handler": [
+ "string mb_output_handler(string contents, int status)",
+ "Returns string in output buffer converted to the http_output encoding"
+ ],
+ "mb_parse_str": [
+ "bool mb_parse_str(string encoded_string [, array result])",
+ "Parses GET/POST/COOKIE data and sets global variables"
+ ],
+ "mb_preferred_mime_name": [
+ "string mb_preferred_mime_name(string encoding)",
+ "Return the preferred MIME name (charset) as a string"
+ ],
+ "mb_regex_encoding": [
+ "string mb_regex_encoding([string encoding])",
+ "Returns the current encoding for regex as a string."
+ ],
+ "mb_regex_set_options": [
+ "string mb_regex_set_options([string options])",
+ "Set or get the default options for mbregex functions"
+ ],
+ "mb_send_mail": [
+ "int mb_send_mail(string to, string subject, string message [, string additional_headers [, string additional_parameters]])",
+ "* Sends an email message with MIME scheme"
+ ],
+ "mb_split": [
+ "array mb_split(string pattern, string string [, int limit])",
+ "split multibyte string into array by regular expression"
+ ],
+ "mb_strcut": [
+ "string mb_strcut(string str, int start [, int length [, string encoding]])",
+ "Returns part of a string"
+ ],
+ "mb_strimwidth": [
+ "string mb_strimwidth(string str, int start, int width [, string trimmarker [, string encoding]])",
+ "Trim the string in terminal width"
+ ],
+ "mb_stripos": [
+ "int mb_stripos(string haystack, string needle [, int offset [, string encoding]])",
+ "Finds position of first occurrence of a string within another, case insensitive"
+ ],
+ "mb_stristr": [
+ "string mb_stristr(string haystack, string needle[, bool part[, string encoding]])",
+ "Finds first occurrence of a string within another, case insensitive"
+ ],
+ "mb_strlen": [
+ "int mb_strlen(string str [, string encoding])",
+ "Get character numbers of a string"
+ ],
+ "mb_strpos": [
+ "int mb_strpos(string haystack, string needle [, int offset [, string encoding]])",
+ "Find position of first occurrence of a string within another"
+ ],
+ "mb_strrchr": [
+ "string mb_strrchr(string haystack, string needle[, bool part[, string encoding]])",
+ "Finds the last occurrence of a character in a string within another"
+ ],
+ "mb_strrichr": [
+ "string mb_strrichr(string haystack, string needle[, bool part[, string encoding]])",
+ "Finds the last occurrence of a character in a string within another, case insensitive"
+ ],
+ "mb_strripos": [
+ "int mb_strripos(string haystack, string needle [, int offset [, string encoding]])",
+ "Finds position of last occurrence of a string within another, case insensitive"
+ ],
+ "mb_strrpos": [
+ "int mb_strrpos(string haystack, string needle [, int offset [, string encoding]])",
+ "Find position of last occurrence of a string within another"
+ ],
+ "mb_strstr": [
+ "string mb_strstr(string haystack, string needle[, bool part[, string encoding]])",
+ "Finds first occurrence of a string within another"
+ ],
+ "mb_strtolower": [
+ "string mb_strtolower(string sourcestring [, string encoding])",
+ "* Returns a lowercased version of sourcestring"
+ ],
+ "mb_strtoupper": [
+ "string mb_strtoupper(string sourcestring [, string encoding])",
+ "* Returns a uppercased version of sourcestring"
+ ],
+ "mb_strwidth": [
+ "int mb_strwidth(string str [, string encoding])",
+ "Gets terminal width of a string"
+ ],
+ "mb_substitute_character": [
+ "mixed mb_substitute_character([mixed substchar])",
+ "Sets the current substitute_character or returns the current substitute_character"
+ ],
+ "mb_substr": [
+ "string mb_substr(string str, int start [, int length [, string encoding]])",
+ "Returns part of a string"
+ ],
+ "mb_substr_count": [
+ "int mb_substr_count(string haystack, string needle [, string encoding])",
+ "Count the number of substring occurrences"
+ ],
+ "mcrypt_cbc": [
+ "string mcrypt_cbc(int cipher, string key, string data, int mode, string iv)",
+ "CBC crypt/decrypt data using key key with cipher cipher starting with iv"
+ ],
+ "mcrypt_cfb": [
+ "string mcrypt_cfb(int cipher, string key, string data, int mode, string iv)",
+ "CFB crypt/decrypt data using key key with cipher cipher starting with iv"
+ ],
+ "mcrypt_create_iv": [
+ "string mcrypt_create_iv(int size, int source)",
+ "Create an initialization vector (IV)"
+ ],
+ "mcrypt_decrypt": [
+ "string mcrypt_decrypt(string cipher, string key, string data, string mode, string iv)",
+ "OFB crypt/decrypt data using key key with cipher cipher starting with iv"
+ ],
+ "mcrypt_ecb": [
+ "string mcrypt_ecb(int cipher, string key, string data, int mode, string iv)",
+ "ECB crypt/decrypt data using key key with cipher cipher starting with iv"
+ ],
+ "mcrypt_enc_get_algorithms_name": [
+ "string mcrypt_enc_get_algorithms_name(resource td)",
+ "Returns the name of the algorithm specified by the descriptor td"
+ ],
+ "mcrypt_enc_get_block_size": [
+ "int mcrypt_enc_get_block_size(resource td)",
+ "Returns the block size of the cipher specified by the descriptor td"
+ ],
+ "mcrypt_enc_get_iv_size": [
+ "int mcrypt_enc_get_iv_size(resource td)",
+ "Returns the size of the IV in bytes of the algorithm specified by the descriptor td"
+ ],
+ "mcrypt_enc_get_key_size": [
+ "int mcrypt_enc_get_key_size(resource td)",
+ "Returns the maximum supported key size in bytes of the algorithm specified by the descriptor td"
+ ],
+ "mcrypt_enc_get_modes_name": [
+ "string mcrypt_enc_get_modes_name(resource td)",
+ "Returns the name of the mode specified by the descriptor td"
+ ],
+ "mcrypt_enc_get_supported_key_sizes": [
+ "array mcrypt_enc_get_supported_key_sizes(resource td)",
+ "This function decrypts the crypttext"
+ ],
+ "mcrypt_enc_is_block_algorithm": [
+ "bool mcrypt_enc_is_block_algorithm(resource td)",
+ "Returns TRUE if the alrogithm is a block algorithms"
+ ],
+ "mcrypt_enc_is_block_algorithm_mode": [
+ "bool mcrypt_enc_is_block_algorithm_mode(resource td)",
+ "Returns TRUE if the mode is for use with block algorithms"
+ ],
+ "mcrypt_enc_is_block_mode": [
+ "bool mcrypt_enc_is_block_mode(resource td)",
+ "Returns TRUE if the mode outputs blocks"
+ ],
+ "mcrypt_enc_self_test": [
+ "int mcrypt_enc_self_test(resource td)",
+ "This function runs the self test on the algorithm specified by the descriptor td"
+ ],
+ "mcrypt_encrypt": [
+ "string mcrypt_encrypt(string cipher, string key, string data, string mode, string iv)",
+ "OFB crypt/decrypt data using key key with cipher cipher starting with iv"
+ ],
+ "mcrypt_generic": [
+ "string mcrypt_generic(resource td, string data)",
+ "This function encrypts the plaintext"
+ ],
+ "mcrypt_generic_deinit": [
+ "bool mcrypt_generic_deinit(resource td)",
+ "This function terminates encrypt specified by the descriptor td"
+ ],
+ "mcrypt_generic_init": [
+ "int mcrypt_generic_init(resource td, string key, string iv)",
+ "This function initializes all buffers for the specific module"
+ ],
+ "mcrypt_get_block_size": [
+ "int mcrypt_get_block_size(string cipher, string module)",
+ "Get the key size of cipher"
+ ],
+ "mcrypt_get_cipher_name": [
+ "string mcrypt_get_cipher_name(string cipher)",
+ "Get the key size of cipher"
+ ],
+ "mcrypt_get_iv_size": [
+ "int mcrypt_get_iv_size(string cipher, string module)",
+ "Get the IV size of cipher (Usually the same as the blocksize)"
+ ],
+ "mcrypt_get_key_size": [
+ "int mcrypt_get_key_size(string cipher, string module)",
+ "Get the key size of cipher"
+ ],
+ "mcrypt_list_algorithms": [
+ "array mcrypt_list_algorithms([string lib_dir])",
+ "List all algorithms in \"module_dir\""
+ ],
+ "mcrypt_list_modes": [
+ "array mcrypt_list_modes([string lib_dir])",
+ "List all modes \"module_dir\""
+ ],
+ "mcrypt_module_close": [
+ "bool mcrypt_module_close(resource td)",
+ "Free the descriptor td"
+ ],
+ "mcrypt_module_get_algo_block_size": [
+ "int mcrypt_module_get_algo_block_size(string algorithm [, string lib_dir])",
+ "Returns the block size of the algorithm"
+ ],
+ "mcrypt_module_get_algo_key_size": [
+ "int mcrypt_module_get_algo_key_size(string algorithm [, string lib_dir])",
+ "Returns the maximum supported key size of the algorithm"
+ ],
+ "mcrypt_module_get_supported_key_sizes": [
+ "array mcrypt_module_get_supported_key_sizes(string algorithm [, string lib_dir])",
+ "This function decrypts the crypttext"
+ ],
+ "mcrypt_module_is_block_algorithm": [
+ "bool mcrypt_module_is_block_algorithm(string algorithm [, string lib_dir])",
+ "Returns TRUE if the algorithm is a block algorithm"
+ ],
+ "mcrypt_module_is_block_algorithm_mode": [
+ "bool mcrypt_module_is_block_algorithm_mode(string mode [, string lib_dir])",
+ "Returns TRUE if the mode is for use with block algorithms"
+ ],
+ "mcrypt_module_is_block_mode": [
+ "bool mcrypt_module_is_block_mode(string mode [, string lib_dir])",
+ "Returns TRUE if the mode outputs blocks of bytes"
+ ],
+ "mcrypt_module_open": [
+ "resource mcrypt_module_open(string cipher, string cipher_directory, string mode, string mode_directory)",
+ "Opens the module of the algorithm and the mode to be used"
+ ],
+ "mcrypt_module_self_test": [
+ "bool mcrypt_module_self_test(string algorithm [, string lib_dir])",
+ "Does a self test of the module \"module\""
+ ],
+ "mcrypt_ofb": [
+ "string mcrypt_ofb(int cipher, string key, string data, int mode, string iv)",
+ "OFB crypt/decrypt data using key key with cipher cipher starting with iv"
+ ],
+ "md5": [
+ "string md5(string str, [ bool raw_output])",
+ "Calculate the md5 hash of a string"
+ ],
+ "md5_file": [
+ "string md5_file(string filename [, bool raw_output])",
+ "Calculate the md5 hash of given filename"
+ ],
+ "mdecrypt_generic": [
+ "string mdecrypt_generic(resource td, string data)",
+ "This function decrypts the plaintext"
+ ],
+ "memory_get_peak_usage": [
+ "int memory_get_peak_usage([real_usage])",
+ "Returns the peak allocated by PHP memory"
+ ],
+ "memory_get_usage": [
+ "int memory_get_usage([real_usage])",
+ "Returns the allocated by PHP memory"
+ ],
+ "metaphone": [
+ "string metaphone(string text[, int phones])",
+ "Break english phrases down into their phonemes"
+ ],
+ "method_exists": [
+ "bool method_exists(object object, string method)",
+ "Checks if the class method exists"
+ ],
+ "mhash": [
+ "string mhash(int hash, string data [, string key])",
+ "Hash data with hash"
+ ],
+ "mhash_count": [
+ "int mhash_count(void)",
+ "Gets the number of available hashes"
+ ],
+ "mhash_get_block_size": [
+ "int mhash_get_block_size(int hash)",
+ "Gets the block size of hash"
+ ],
+ "mhash_get_hash_name": [
+ "string mhash_get_hash_name(int hash)",
+ "Gets the name of hash"
+ ],
+ "mhash_keygen_s2k": [
+ "string mhash_keygen_s2k(int hash, string input_password, string salt, int bytes)",
+ "Generates a key using hash functions"
+ ],
+ "microtime": [
+ "mixed microtime([bool get_as_float])",
+ "Returns either a string or a float containing the current time in seconds and microseconds"
+ ],
+ "mime_content_type": [
+ "string mime_content_type(string filename|resource stream)",
+ "Return content-type for file"
+ ],
+ "min": [
+ "mixed min(mixed arg1 [, mixed arg2 [, mixed ...]])",
+ "Return the lowest value in an array or a series of arguments"
+ ],
+ "mkdir": [
+ "bool mkdir(string pathname [, int mode [, bool recursive [, resource context]]])",
+ "Create a directory"
+ ],
+ "mktime": [
+ "int mktime([int hour [, int min [, int sec [, int mon [, int day [, int year]]]]]])",
+ "Get UNIX timestamp for a date"
+ ],
+ "money_format": [
+ "string money_format(string format , float value)",
+ "Convert monetary value(s) to string"
+ ],
+ "move_uploaded_file": [
+ "bool move_uploaded_file(string path, string new_path)",
+ "Move a file if and only if it was created by an upload"
+ ],
+ "msg_get_queue": [
+ "resource msg_get_queue(int key [, int perms])",
+ "Attach to a message queue"
+ ],
+ "msg_queue_exists": [
+ "bool msg_queue_exists(int key)",
+ "Check wether a message queue exists"
+ ],
+ "msg_receive": [
+ "mixed msg_receive(resource queue, int desiredmsgtype, int &msgtype, int maxsize, mixed message [, bool unserialize=true [, int flags=0 [, int errorcode]]])",
+ "Send a message of type msgtype (must be > 0) to a message queue"
+ ],
+ "msg_remove_queue": [
+ "bool msg_remove_queue(resource queue)",
+ "Destroy the queue"
+ ],
+ "msg_send": [
+ "bool msg_send(resource queue, int msgtype, mixed message [, bool serialize=true [, bool blocking=true [, int errorcode]]])",
+ "Send a message of type msgtype (must be > 0) to a message queue"
+ ],
+ "msg_set_queue": [
+ "bool msg_set_queue(resource queue, array data)",
+ "Set information for a message queue"
+ ],
+ "msg_stat_queue": [
+ "array msg_stat_queue(resource queue)",
+ "Returns information about a message queue"
+ ],
+ "msgfmt_create": [
+ "MessageFormatter msgfmt_create( string $locale, string $pattern )",
+ "* Create formatter."
+ ],
+ "msgfmt_format": [
+ "mixed msgfmt_format( MessageFormatter $nf, array $args )",
+ "* Format a message."
+ ],
+ "msgfmt_format_message": [
+ "mixed msgfmt_format_message( string $locale, string $pattern, array $args )",
+ "* Format a message."
+ ],
+ "msgfmt_get_error_code": [
+ "int msgfmt_get_error_code( MessageFormatter $nf )",
+ "* Get formatter's last error code."
+ ],
+ "msgfmt_get_error_message": [
+ "string msgfmt_get_error_message( MessageFormatter $coll )",
+ "* Get text description for formatter's last error code."
+ ],
+ "msgfmt_get_locale": [
+ "string msgfmt_get_locale(MessageFormatter $mf)",
+ "* Get formatter locale."
+ ],
+ "msgfmt_get_pattern": [
+ "string msgfmt_get_pattern( MessageFormatter $mf )",
+ "* Get formatter pattern."
+ ],
+ "msgfmt_parse": [
+ "array msgfmt_parse( MessageFormatter $nf, string $source )",
+ "* Parse a message."
+ ],
+ "msgfmt_set_pattern": [
+ "bool msgfmt_set_pattern( MessageFormatter $mf, string $pattern )",
+ "* Set formatter pattern."
+ ],
+ "mssql_bind": [
+ "bool mssql_bind(resource stmt, string param_name, mixed var, int type [, bool is_output [, bool is_null [, int maxlen]]])",
+ "Adds a parameter to a stored procedure or a remote stored procedure"
+ ],
+ "mssql_close": [
+ "bool mssql_close([resource conn_id])",
+ "Closes a connection to a MS-SQL server"
+ ],
+ "mssql_connect": [
+ "int mssql_connect([string servername [, string username [, string password [, bool new_link]]]])",
+ "Establishes a connection to a MS-SQL server"
+ ],
+ "mssql_data_seek": [
+ "bool mssql_data_seek(resource result_id, int offset)",
+ "Moves the internal row pointer of the MS-SQL result associated with the specified result identifier to pointer to the specified row number"
+ ],
+ "mssql_execute": [
+ "mixed mssql_execute(resource stmt [, bool skip_results = false])",
+ "Executes a stored procedure on a MS-SQL server database"
+ ],
+ "mssql_fetch_array": [
+ "array mssql_fetch_array(resource result_id [, int result_type])",
+ "Returns an associative array of the current row in the result set specified by result_id"
+ ],
+ "mssql_fetch_assoc": [
+ "array mssql_fetch_assoc(resource result_id)",
+ "Returns an associative array of the current row in the result set specified by result_id"
+ ],
+ "mssql_fetch_batch": [
+ "int mssql_fetch_batch(resource result_index)",
+ "Returns the next batch of records"
+ ],
+ "mssql_fetch_field": [
+ "object mssql_fetch_field(resource result_id [, int offset])",
+ "Gets information about certain fields in a query result"
+ ],
+ "mssql_fetch_object": [
+ "object mssql_fetch_object(resource result_id)",
+ "Returns a pseudo-object of the current row in the result set specified by result_id"
+ ],
+ "mssql_fetch_row": [
+ "array mssql_fetch_row(resource result_id)",
+ "Returns an array of the current row in the result set specified by result_id"
+ ],
+ "mssql_field_length": [
+ "int mssql_field_length(resource result_id [, int offset])",
+ "Get the length of a MS-SQL field"
+ ],
+ "mssql_field_name": [
+ "string mssql_field_name(resource result_id [, int offset])",
+ "Returns the name of the field given by offset in the result set given by result_id"
+ ],
+ "mssql_field_seek": [
+ "bool mssql_field_seek(resource result_id, int offset)",
+ "Seeks to the specified field offset"
+ ],
+ "mssql_field_type": [
+ "string mssql_field_type(resource result_id [, int offset])",
+ "Returns the type of a field"
+ ],
+ "mssql_free_result": [
+ "bool mssql_free_result(resource result_index)",
+ "Free a MS-SQL result index"
+ ],
+ "mssql_free_statement": [
+ "bool mssql_free_statement(resource result_index)",
+ "Free a MS-SQL statement index"
+ ],
+ "mssql_get_last_message": [
+ "string mssql_get_last_message(void)",
+ "Gets the last message from the MS-SQL server"
+ ],
+ "mssql_guid_string": [
+ "string mssql_guid_string(string binary [,bool short_format])",
+ "Converts a 16 byte binary GUID to a string"
+ ],
+ "mssql_init": [
+ "int mssql_init(string sp_name [, resource conn_id])",
+ "Initializes a stored procedure or a remote stored procedure"
+ ],
+ "mssql_min_error_severity": [
+ "void mssql_min_error_severity(int severity)",
+ "Sets the lower error severity"
+ ],
+ "mssql_min_message_severity": [
+ "void mssql_min_message_severity(int severity)",
+ "Sets the lower message severity"
+ ],
+ "mssql_next_result": [
+ "bool mssql_next_result(resource result_id)",
+ "Move the internal result pointer to the next result"
+ ],
+ "mssql_num_fields": [
+ "int mssql_num_fields(resource mssql_result_index)",
+ "Returns the number of fields fetched in from the result id specified"
+ ],
+ "mssql_num_rows": [
+ "int mssql_num_rows(resource mssql_result_index)",
+ "Returns the number of rows fetched in from the result id specified"
+ ],
+ "mssql_pconnect": [
+ "int mssql_pconnect([string servername [, string username [, string password [, bool new_link]]]])",
+ "Establishes a persistent connection to a MS-SQL server"
+ ],
+ "mssql_query": [
+ "resource mssql_query(string query [, resource conn_id [, int batch_size]])",
+ "Perform an SQL query on a MS-SQL server database"
+ ],
+ "mssql_result": [
+ "string mssql_result(resource result_id, int row, mixed field)",
+ "Returns the contents of one cell from a MS-SQL result set"
+ ],
+ "mssql_rows_affected": [
+ "int mssql_rows_affected(resource conn_id)",
+ "Returns the number of records affected by the query"
+ ],
+ "mssql_select_db": [
+ "bool mssql_select_db(string database_name [, resource conn_id])",
+ "Select a MS-SQL database"
+ ],
+ "mt_getrandmax": [
+ "int mt_getrandmax(void)",
+ "Returns the maximum value a random number from Mersenne Twister can have"
+ ],
+ "mt_rand": [
+ "int mt_rand([int min, int max])",
+ "Returns a random number from Mersenne Twister"
+ ],
+ "mt_srand": [
+ "void mt_srand([int seed])",
+ "Seeds Mersenne Twister random number generator"
+ ],
+ "mysql_affected_rows": [
+ "int mysql_affected_rows([int link_identifier])",
+ "Gets number of affected rows in previous MySQL operation"
+ ],
+ "mysql_client_encoding": [
+ "string mysql_client_encoding([int link_identifier])",
+ "Returns the default character set for the current connection"
+ ],
+ "mysql_close": [
+ "bool mysql_close([int link_identifier])",
+ "Close a MySQL connection"
+ ],
+ "mysql_connect": [
+ "resource mysql_connect([string hostname[:port][:/path/to/socket] [, string username [, string password [, bool new [, int flags]]]]])",
+ "Opens a connection to a MySQL Server"
+ ],
+ "mysql_create_db": [
+ "bool mysql_create_db(string database_name [, int link_identifier])",
+ "Create a MySQL database"
+ ],
+ "mysql_data_seek": [
+ "bool mysql_data_seek(resource result, int row_number)",
+ "Move internal result pointer"
+ ],
+ "mysql_db_query": [
+ "resource mysql_db_query(string database_name, string query [, int link_identifier])",
+ "Sends an SQL query to MySQL"
+ ],
+ "mysql_drop_db": [
+ "bool mysql_drop_db(string database_name [, int link_identifier])",
+ "Drops (delete) a MySQL database"
+ ],
+ "mysql_errno": [
+ "int mysql_errno([int link_identifier])",
+ "Returns the number of the error message from previous MySQL operation"
+ ],
+ "mysql_error": [
+ "string mysql_error([int link_identifier])",
+ "Returns the text of the error message from previous MySQL operation"
+ ],
+ "mysql_escape_string": [
+ "string mysql_escape_string(string to_be_escaped)",
+ "Escape string for mysql query"
+ ],
+ "mysql_fetch_array": [
+ "array mysql_fetch_array(resource result [, int result_type])",
+ "Fetch a result row as an array (associative, numeric or both)"
+ ],
+ "mysql_fetch_assoc": [
+ "array mysql_fetch_assoc(resource result)",
+ "Fetch a result row as an associative array"
+ ],
+ "mysql_fetch_field": [
+ "object mysql_fetch_field(resource result [, int field_offset])",
+ "Gets column information from a result and return as an object"
+ ],
+ "mysql_fetch_lengths": [
+ "array mysql_fetch_lengths(resource result)",
+ "Gets max data size of each column in a result"
+ ],
+ "mysql_fetch_object": [
+ "object mysql_fetch_object(resource result [, string class_name [, NULL|array ctor_params]])",
+ "Fetch a result row as an object"
+ ],
+ "mysql_fetch_row": [
+ "array mysql_fetch_row(resource result)",
+ "Gets a result row as an enumerated array"
+ ],
+ "mysql_field_flags": [
+ "string mysql_field_flags(resource result, int field_offset)",
+ "Gets the flags associated with the specified field in a result"
+ ],
+ "mysql_field_len": [
+ "int mysql_field_len(resource result, int field_offset)",
+ "Returns the length of the specified field"
+ ],
+ "mysql_field_name": [
+ "string mysql_field_name(resource result, int field_index)",
+ "Gets the name of the specified field in a result"
+ ],
+ "mysql_field_seek": [
+ "bool mysql_field_seek(resource result, int field_offset)",
+ "Sets result pointer to a specific field offset"
+ ],
+ "mysql_field_table": [
+ "string mysql_field_table(resource result, int field_offset)",
+ "Gets name of the table the specified field is in"
+ ],
+ "mysql_field_type": [
+ "string mysql_field_type(resource result, int field_offset)",
+ "Gets the type of the specified field in a result"
+ ],
+ "mysql_free_result": [
+ "bool mysql_free_result(resource result)",
+ "Free result memory"
+ ],
+ "mysql_get_client_info": [
+ "string mysql_get_client_info(void)",
+ "Returns a string that represents the client library version"
+ ],
+ "mysql_get_host_info": [
+ "string mysql_get_host_info([int link_identifier])",
+ "Returns a string describing the type of connection in use, including the server host name"
+ ],
+ "mysql_get_proto_info": [
+ "int mysql_get_proto_info([int link_identifier])",
+ "Returns the protocol version used by current connection"
+ ],
+ "mysql_get_server_info": [
+ "string mysql_get_server_info([int link_identifier])",
+ "Returns a string that represents the server version number"
+ ],
+ "mysql_info": [
+ "string mysql_info([int link_identifier])",
+ "Returns a string containing information about the most recent query"
+ ],
+ "mysql_insert_id": [
+ "int mysql_insert_id([int link_identifier])",
+ "Gets the ID generated from the previous INSERT operation"
+ ],
+ "mysql_list_dbs": [
+ "resource mysql_list_dbs([int link_identifier])",
+ "List databases available on a MySQL server"
+ ],
+ "mysql_list_fields": [
+ "resource mysql_list_fields(string database_name, string table_name [, int link_identifier])",
+ "List MySQL result fields"
+ ],
+ "mysql_list_processes": [
+ "resource mysql_list_processes([int link_identifier])",
+ "Returns a result set describing the current server threads"
+ ],
+ "mysql_list_tables": [
+ "resource mysql_list_tables(string database_name [, int link_identifier])",
+ "List tables in a MySQL database"
+ ],
+ "mysql_num_fields": [
+ "int mysql_num_fields(resource result)",
+ "Gets number of fields in a result"
+ ],
+ "mysql_num_rows": [
+ "int mysql_num_rows(resource result)",
+ "Gets number of rows in a result"
+ ],
+ "mysql_pconnect": [
+ "resource mysql_pconnect([string hostname[:port][:/path/to/socket] [, string username [, string password [, int flags]]]])",
+ "Opens a persistent connection to a MySQL Server"
+ ],
+ "mysql_ping": [
+ "bool mysql_ping([int link_identifier])",
+ "Ping a server connection. If no connection then reconnect."
+ ],
+ "mysql_query": [
+ "resource mysql_query(string query [, int link_identifier])",
+ "Sends an SQL query to MySQL"
+ ],
+ "mysql_real_escape_string": [
+ "string mysql_real_escape_string(string to_be_escaped [, int link_identifier])",
+ "Escape special characters in a string for use in a SQL statement, taking into account the current charset of the connection"
+ ],
+ "mysql_result": [
+ "mixed mysql_result(resource result, int row [, mixed field])",
+ "Gets result data"
+ ],
+ "mysql_select_db": [
+ "bool mysql_select_db(string database_name [, int link_identifier])",
+ "Selects a MySQL database"
+ ],
+ "mysql_set_charset": [
+ "bool mysql_set_charset(string csname [, int link_identifier])",
+ "sets client character set"
+ ],
+ "mysql_stat": [
+ "string mysql_stat([int link_identifier])",
+ "Returns a string containing status information"
+ ],
+ "mysql_thread_id": [
+ "int mysql_thread_id([int link_identifier])",
+ "Returns the thread id of current connection"
+ ],
+ "mysql_unbuffered_query": [
+ "resource mysql_unbuffered_query(string query [, int link_identifier])",
+ "Sends an SQL query to MySQL, without fetching and buffering the result rows"
+ ],
+ "mysqli_affected_rows": [
+ "mixed mysqli_affected_rows(object link)",
+ "Get number of affected rows in previous MySQL operation"
+ ],
+ "mysqli_autocommit": [
+ "bool mysqli_autocommit(object link, bool mode)",
+ "Turn auto commit on or of"
+ ],
+ "mysqli_cache_stats": [
+ "array mysqli_cache_stats(void)",
+ "Returns statistics about the zval cache"
+ ],
+ "mysqli_change_user": [
+ "bool mysqli_change_user(object link, string user, string password, string database)",
+ "Change logged-in user of the active connection"
+ ],
+ "mysqli_character_set_name": [
+ "string mysqli_character_set_name(object link)",
+ "Returns the name of the character set used for this connection"
+ ],
+ "mysqli_close": [
+ "bool mysqli_close(object link)",
+ "Close connection"
+ ],
+ "mysqli_commit": [
+ "bool mysqli_commit(object link)",
+ "Commit outstanding actions and close transaction"
+ ],
+ "mysqli_connect": [
+ "object mysqli_connect([string hostname [,string username [,string passwd [,string dbname [,int port [,string socket]]]]]])",
+ "Open a connection to a mysql server"
+ ],
+ "mysqli_connect_errno": [
+ "int mysqli_connect_errno(void)",
+ "Returns the numerical value of the error message from last connect command"
+ ],
+ "mysqli_connect_error": [
+ "string mysqli_connect_error(void)",
+ "Returns the text of the error message from previous MySQL operation"
+ ],
+ "mysqli_data_seek": [
+ "bool mysqli_data_seek(object result, int offset)",
+ "Move internal result pointer"
+ ],
+ "mysqli_debug": [
+ "void mysqli_debug(string debug)",
+ ""
+ ],
+ "mysqli_dump_debug_info": [
+ "bool mysqli_dump_debug_info(object link)",
+ ""
+ ],
+ "mysqli_embedded_server_end": [
+ "void mysqli_embedded_server_end(void)",
+ ""
+ ],
+ "mysqli_embedded_server_start": [
+ "bool mysqli_embedded_server_start(bool start, array arguments, array groups)",
+ "initialize and start embedded server"
+ ],
+ "mysqli_errno": [
+ "int mysqli_errno(object link)",
+ "Returns the numerical value of the error message from previous MySQL operation"
+ ],
+ "mysqli_error": [
+ "string mysqli_error(object link)",
+ "Returns the text of the error message from previous MySQL operation"
+ ],
+ "mysqli_fetch_all": [
+ "mixed mysqli_fetch_all (object result [,int resulttype])",
+ "Fetches all result rows as an associative array, a numeric array, or both"
+ ],
+ "mysqli_fetch_array": [
+ "mixed mysqli_fetch_array (object result [,int resulttype])",
+ "Fetch a result row as an associative array, a numeric array, or both"
+ ],
+ "mysqli_fetch_assoc": [
+ "mixed mysqli_fetch_assoc (object result)",
+ "Fetch a result row as an associative array"
+ ],
+ "mysqli_fetch_field": [
+ "mixed mysqli_fetch_field (object result)",
+ "Get column information from a result and return as an object"
+ ],
+ "mysqli_fetch_field_direct": [
+ "mixed mysqli_fetch_field_direct (object result, int offset)",
+ "Fetch meta-data for a single field"
+ ],
+ "mysqli_fetch_fields": [
+ "mixed mysqli_fetch_fields (object result)",
+ "Return array of objects containing field meta-data"
+ ],
+ "mysqli_fetch_lengths": [
+ "mixed mysqli_fetch_lengths (object result)",
+ "Get the length of each output in a result"
+ ],
+ "mysqli_fetch_object": [
+ "mixed mysqli_fetch_object (object result [, string class_name [, NULL|array ctor_params]])",
+ "Fetch a result row as an object"
+ ],
+ "mysqli_fetch_row": [
+ "array mysqli_fetch_row (object result)",
+ "Get a result row as an enumerated array"
+ ],
+ "mysqli_field_count": [
+ "int mysqli_field_count(object link)",
+ "Fetch the number of fields returned by the last query for the given link"
+ ],
+ "mysqli_field_seek": [
+ "int mysqli_field_seek(object result, int fieldnr)",
+ "Set result pointer to a specified field offset"
+ ],
+ "mysqli_field_tell": [
+ "int mysqli_field_tell(object result)",
+ "Get current field offset of result pointer"
+ ],
+ "mysqli_free_result": [
+ "void mysqli_free_result(object result)",
+ "Free query result memory for the given result handle"
+ ],
+ "mysqli_get_charset": [
+ "object mysqli_get_charset(object link)",
+ "returns a character set object"
+ ],
+ "mysqli_get_client_info": [
+ "string mysqli_get_client_info(void)",
+ "Get MySQL client info"
+ ],
+ "mysqli_get_client_stats": [
+ "array mysqli_get_client_stats(void)",
+ "Returns statistics about the zval cache"
+ ],
+ "mysqli_get_client_version": [
+ "int mysqli_get_client_version(void)",
+ "Get MySQL client info"
+ ],
+ "mysqli_get_connection_stats": [
+ "array mysqli_get_connection_stats(void)",
+ "Returns statistics about the zval cache"
+ ],
+ "mysqli_get_host_info": [
+ "string mysqli_get_host_info (object link)",
+ "Get MySQL host info"
+ ],
+ "mysqli_get_proto_info": [
+ "int mysqli_get_proto_info(object link)",
+ "Get MySQL protocol information"
+ ],
+ "mysqli_get_server_info": [
+ "string mysqli_get_server_info(object link)",
+ "Get MySQL server info"
+ ],
+ "mysqli_get_server_version": [
+ "int mysqli_get_server_version(object link)",
+ "Return the MySQL version for the server referenced by the given link"
+ ],
+ "mysqli_get_warnings": [
+ "object mysqli_get_warnings(object link) */",
+ "PHP_FUNCTION(mysqli_get_warnings) { MY_MYSQL *mysql; zval *mysql_link; MYSQLI_RESOURCE *mysqli_resource; MYSQLI_WARNING *w; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), \"O\", &mysql_link, mysqli_link_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE(mysql, MY_MYSQL*, &mysql_link, \"mysqli_link\", MYSQLI_STATUS_VALID); if (mysql_warning_count(mysql->mysql)) { w = php_get_warnings(mysql->mysql TSRMLS_CC); } else { RETURN_FALSE; } mysqli_resource = (MYSQLI_RESOURCE *)ecalloc (1, sizeof(MYSQLI_RESOURCE)); mysqli_resource->ptr = mysqli_resource->info = (void *)w; mysqli_resource->status = MYSQLI_STATUS_VALID; MYSQLI_RETURN_RESOURCE(mysqli_resource, mysqli_warning_class_entry); } /* }}}"
+ ],
+ "mysqli_info": [
+ "string mysqli_info(object link)",
+ "Get information about the most recent query"
+ ],
+ "mysqli_init": [
+ "resource mysqli_init(void)",
+ "Initialize mysqli and return a resource for use with mysql_real_connect"
+ ],
+ "mysqli_insert_id": [
+ "mixed mysqli_insert_id(object link)",
+ "Get the ID generated from the previous INSERT operation"
+ ],
+ "mysqli_kill": [
+ "bool mysqli_kill(object link, int processid)",
+ "Kill a mysql process on the server"
+ ],
+ "mysqli_link_construct": [
+ "object mysqli_link_construct()",
+ ""
+ ],
+ "mysqli_more_results": [
+ "bool mysqli_more_results(object link)",
+ "check if there any more query results from a multi query"
+ ],
+ "mysqli_multi_query": [
+ "bool mysqli_multi_query(object link, string query)",
+ "allows to execute multiple queries"
+ ],
+ "mysqli_next_result": [
+ "bool mysqli_next_result(object link)",
+ "read next result from multi_query"
+ ],
+ "mysqli_num_fields": [
+ "int mysqli_num_fields(object result)",
+ "Get number of fields in result"
+ ],
+ "mysqli_num_rows": [
+ "mixed mysqli_num_rows(object result)",
+ "Get number of rows in result"
+ ],
+ "mysqli_options": [
+ "bool mysqli_options(object link, int flags, mixed values)",
+ "Set options"
+ ],
+ "mysqli_ping": [
+ "bool mysqli_ping(object link)",
+ "Ping a server connection or reconnect if there is no connection"
+ ],
+ "mysqli_poll": [
+ "int mysqli_poll(array read, array write, array error, long sec [, long usec])",
+ "Poll connections"
+ ],
+ "mysqli_prepare": [
+ "mixed mysqli_prepare(object link, string query)",
+ "Prepare a SQL statement for execution"
+ ],
+ "mysqli_query": [
+ "mixed mysqli_query(object link, string query [,int resultmode]) */",
+ "PHP_FUNCTION(mysqli_query) { MY_MYSQL *mysql; zval *mysql_link; MYSQLI_RESOURCE *mysqli_resource; MYSQL_RES *result; char *query = NULL; unsigned int query_len; unsigned long resultmode = MYSQLI_STORE_RESULT; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), \"Os|l\", &mysql_link, mysqli_link_class_entry, &query, &query_len, &resultmode) == FAILURE) { return; } if (!query_len) { php_error_docref(NULL TSRMLS_CC, E_WARNING, \"Empty query\"); RETURN_FALSE; } if ((resultmode & ~MYSQLI_ASYNC) != MYSQLI_USE_RESULT && (resultmode & ~MYSQLI_ASYNC) != MYSQLI_STORE_RESULT) { php_error_docref(NULL TSRMLS_CC, E_WARNING, \"Invalid value for resultmode\"); RETURN_FALSE; } MYSQLI_FETCH_RESOURCE(mysql, MY_MYSQL*, &mysql_link, \"mysqli_link\", MYSQLI_STATUS_VALID); MYSQLI_DISABLE_MQ; #ifdef MYSQLI_USE_MYSQLND if (resultmode & MYSQLI_ASYNC) { if (mysqli_async_query(mysql->mysql, query, query_len)) { MYSQLI_REPORT_MYSQL_ERROR(mysql->mysql); RETURN_FALSE; } mysql->async_result_fetch_type = resultmode & ~MYSQLI_ASYNC; RETURN_TRUE; } #endif if (mysql_real_query(mysql->mysql, query, query_len)) { MYSQLI_REPORT_MYSQL_ERROR(mysql->mysql); RETURN_FALSE; } if (!mysql_field_count(mysql->mysql)) { /* no result set - not a SELECT"
+ ],
+ "mysqli_real_connect": [
+ "bool mysqli_real_connect(object link [,string hostname [,string username [,string passwd [,string dbname [,int port [,string socket [,int flags]]]]]]])",
+ "Open a connection to a mysql server"
+ ],
+ "mysqli_real_escape_string": [
+ "string mysqli_real_escape_string(object link, string escapestr)",
+ "Escapes special characters in a string for use in a SQL statement, taking into account the current charset of the connection"
+ ],
+ "mysqli_real_query": [
+ "bool mysqli_real_query(object link, string query)",
+ "Binary-safe version of mysql_query()"
+ ],
+ "mysqli_reap_async_query": [
+ "int mysqli_reap_async_query(object link)",
+ "Poll connections"
+ ],
+ "mysqli_refresh": [
+ "bool mysqli_refresh(object link, long options)",
+ "Flush tables or caches, or reset replication server information"
+ ],
+ "mysqli_report": [
+ "bool mysqli_report(int flags)",
+ "sets report level"
+ ],
+ "mysqli_rollback": [
+ "bool mysqli_rollback(object link)",
+ "Undo actions from current transaction"
+ ],
+ "mysqli_select_db": [
+ "bool mysqli_select_db(object link, string dbname)",
+ "Select a MySQL database"
+ ],
+ "mysqli_set_charset": [
+ "bool mysqli_set_charset(object link, string csname)",
+ "sets client character set"
+ ],
+ "mysqli_set_local_infile_default": [
+ "void mysqli_set_local_infile_default(object link)",
+ "unsets user defined handler for load local infile command"
+ ],
+ "mysqli_set_local_infile_handler": [
+ "bool mysqli_set_local_infile_handler(object link, callback read_func)",
+ "Set callback functions for LOAD DATA LOCAL INFILE"
+ ],
+ "mysqli_sqlstate": [
+ "string mysqli_sqlstate(object link)",
+ "Returns the SQLSTATE error from previous MySQL operation"
+ ],
+ "mysqli_ssl_set": [
+ "bool mysqli_ssl_set(object link ,string key ,string cert ,string ca ,string capath ,string cipher])",
+ ""
+ ],
+ "mysqli_stat": [
+ "mixed mysqli_stat(object link)",
+ "Get current system status"
+ ],
+ "mysqli_stmt_affected_rows": [
+ "mixed mysqli_stmt_affected_rows(object stmt)",
+ "Return the number of rows affected in the last query for the given link"
+ ],
+ "mysqli_stmt_attr_get": [
+ "int mysqli_stmt_attr_get(object stmt, long attr)",
+ ""
+ ],
+ "mysqli_stmt_attr_set": [
+ "int mysqli_stmt_attr_set(object stmt, long attr, long mode)",
+ ""
+ ],
+ "mysqli_stmt_bind_param": [
+ "bool mysqli_stmt_bind_param(object stmt, string types, mixed variable [,mixed,....])",
+ "Bind variables to a prepared statement as parameters"
+ ],
+ "mysqli_stmt_bind_result": [
+ "bool mysqli_stmt_bind_result(object stmt, mixed var, [,mixed, ...])",
+ "Bind variables to a prepared statement for result storage"
+ ],
+ "mysqli_stmt_close": [
+ "bool mysqli_stmt_close(object stmt)",
+ "Close statement"
+ ],
+ "mysqli_stmt_data_seek": [
+ "void mysqli_stmt_data_seek(object stmt, int offset)",
+ "Move internal result pointer"
+ ],
+ "mysqli_stmt_errno": [
+ "int mysqli_stmt_errno(object stmt)",
+ ""
+ ],
+ "mysqli_stmt_error": [
+ "string mysqli_stmt_error(object stmt)",
+ ""
+ ],
+ "mysqli_stmt_execute": [
+ "bool mysqli_stmt_execute(object stmt)",
+ "Execute a prepared statement"
+ ],
+ "mysqli_stmt_fetch": [
+ "mixed mysqli_stmt_fetch(object stmt)",
+ "Fetch results from a prepared statement into the bound variables"
+ ],
+ "mysqli_stmt_field_count": [
+ "int mysqli_stmt_field_count(object stmt) {",
+ "Return the number of result columns for the given statement"
+ ],
+ "mysqli_stmt_free_result": [
+ "void mysqli_stmt_free_result(object stmt)",
+ "Free stored result memory for the given statement handle"
+ ],
+ "mysqli_stmt_get_result": [
+ "object mysqli_stmt_get_result(object link)",
+ "Buffer result set on client"
+ ],
+ "mysqli_stmt_get_warnings": [
+ "object mysqli_stmt_get_warnings(object link) */",
+ "PHP_FUNCTION(mysqli_stmt_get_warnings) { MY_STMT *stmt; zval *stmt_link; MYSQLI_RESOURCE *mysqli_resource; MYSQLI_WARNING *w; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), \"O\", &stmt_link, mysqli_stmt_class_entry) == FAILURE) { return; } MYSQLI_FETCH_RESOURCE(stmt, MY_STMT*, &stmt_link, \"mysqli_stmt\", MYSQLI_STATUS_VALID); if (mysqli_stmt_warning_count(stmt->stmt)) { w = php_get_warnings(mysqli_stmt_get_connection(stmt->stmt) TSRMLS_CC); } else { RETURN_FALSE; } mysqli_resource = (MYSQLI_RESOURCE *)ecalloc (1, sizeof(MYSQLI_RESOURCE)); mysqli_resource->ptr = mysqli_resource->info = (void *)w; mysqli_resource->status = MYSQLI_STATUS_VALID; MYSQLI_RETURN_RESOURCE(mysqli_resource, mysqli_warning_class_entry); } /* }}}"
+ ],
+ "mysqli_stmt_init": [
+ "mixed mysqli_stmt_init(object link)",
+ "Initialize statement object"
+ ],
+ "mysqli_stmt_insert_id": [
+ "mixed mysqli_stmt_insert_id(object stmt)",
+ "Get the ID generated from the previous INSERT operation"
+ ],
+ "mysqli_stmt_next_result": [
+ "bool mysqli_stmt_next_result(object link)",
+ "read next result from multi_query"
+ ],
+ "mysqli_stmt_num_rows": [
+ "mixed mysqli_stmt_num_rows(object stmt)",
+ "Return the number of rows in statements result set"
+ ],
+ "mysqli_stmt_param_count": [
+ "int mysqli_stmt_param_count(object stmt)",
+ "Return the number of parameter for the given statement"
+ ],
+ "mysqli_stmt_prepare": [
+ "bool mysqli_stmt_prepare(object stmt, string query)",
+ "prepare server side statement with query"
+ ],
+ "mysqli_stmt_reset": [
+ "bool mysqli_stmt_reset(object stmt)",
+ "reset a prepared statement"
+ ],
+ "mysqli_stmt_result_metadata": [
+ "mixed mysqli_stmt_result_metadata(object stmt)",
+ "return result set from statement"
+ ],
+ "mysqli_stmt_send_long_data": [
+ "bool mysqli_stmt_send_long_data(object stmt, int param_nr, string data)",
+ ""
+ ],
+ "mysqli_stmt_sqlstate": [
+ "string mysqli_stmt_sqlstate(object stmt)",
+ ""
+ ],
+ "mysqli_stmt_store_result": [
+ "bool mysqli_stmt_store_result(stmt)",
+ ""
+ ],
+ "mysqli_store_result": [
+ "object mysqli_store_result(object link)",
+ "Buffer result set on client"
+ ],
+ "mysqli_thread_id": [
+ "int mysqli_thread_id(object link)",
+ "Return the current thread ID"
+ ],
+ "mysqli_thread_safe": [
+ "bool mysqli_thread_safe(void)",
+ "Return whether thread safety is given or not"
+ ],
+ "mysqli_use_result": [
+ "mixed mysqli_use_result(object link)",
+ "Directly retrieve query results - do not buffer results on client side"
+ ],
+ "mysqli_warning_count": [
+ "int mysqli_warning_count (object link)",
+ "Return number of warnings from the last query for the given link"
+ ],
+ "natcasesort": [
+ "void natcasesort(array &array_arg)",
+ "Sort an array using case-insensitive natural sort"
+ ],
+ "natsort": [
+ "void natsort(array &array_arg)",
+ "Sort an array using natural sort"
+ ],
+ "next": [
+ "mixed next(array array_arg)",
+ "Move array argument's internal pointer to the next element and return it"
+ ],
+ "ngettext": [
+ "string ngettext(string MSGID1, string MSGID2, int N)",
+ "Plural version of gettext()"
+ ],
+ "nl2br": [
+ "string nl2br(string str [, bool is_xhtml])",
+ "Converts newlines to HTML line breaks"
+ ],
+ "nl_langinfo": [
+ "string nl_langinfo(int item)",
+ "Query language and locale information"
+ ],
+ "normalizer_is_normalize": [
+ "bool normalizer_is_normalize( string $input [, string $form = FORM_C] )",
+ "* Test if a string is in a given normalization form."
+ ],
+ "normalizer_normalize": [
+ "string normalizer_normalize( string $input [, string $form = FORM_C] )",
+ "* Normalize a string."
+ ],
+ "nsapi_request_headers": [
+ "array nsapi_request_headers(void)",
+ "Get all headers from the request"
+ ],
+ "nsapi_response_headers": [
+ "array nsapi_response_headers(void)",
+ "Get all headers from the response"
+ ],
+ "nsapi_virtual": [
+ "bool nsapi_virtual(string uri)",
+ "Perform an NSAPI sub-request"
+ ],
+ "number_format": [
+ "string number_format(float number [, int num_decimal_places [, string dec_seperator, string thousands_seperator]])",
+ "Formats a number with grouped thousands"
+ ],
+ "numfmt_create": [
+ "NumberFormatter numfmt_create( string $locale, int style[, string $pattern ] )",
+ "* Create number formatter."
+ ],
+ "numfmt_format": [
+ "mixed numfmt_format( NumberFormatter $nf, mixed $num[, int type] )",
+ "* Format a number."
+ ],
+ "numfmt_format_currency": [
+ "mixed numfmt_format_currency( NumberFormatter $nf, double $num, string $currency )",
+ "* Format a number as currency."
+ ],
+ "numfmt_get_attribute": [
+ "mixed numfmt_get_attribute( NumberFormatter $nf, int $attr )",
+ "* Get formatter attribute value."
+ ],
+ "numfmt_get_error_code": [
+ "int numfmt_get_error_code( NumberFormatter $nf )",
+ "* Get formatter's last error code."
+ ],
+ "numfmt_get_error_message": [
+ "string numfmt_get_error_message( NumberFormatter $nf )",
+ "* Get text description for formatter's last error code."
+ ],
+ "numfmt_get_locale": [
+ "string numfmt_get_locale( NumberFormatter $nf[, int type] )",
+ "* Get formatter locale."
+ ],
+ "numfmt_get_pattern": [
+ "string numfmt_get_pattern( NumberFormatter $nf )",
+ "* Get formatter pattern."
+ ],
+ "numfmt_get_symbol": [
+ "string numfmt_get_symbol( NumberFormatter $nf, int $attr )",
+ "* Get formatter symbol value."
+ ],
+ "numfmt_get_text_attribute": [
+ "string numfmt_get_text_attribute( NumberFormatter $nf, int $attr )",
+ "* Get formatter attribute value."
+ ],
+ "numfmt_parse": [
+ "mixed numfmt_parse( NumberFormatter $nf, string $str[, int $type, int &$position ])",
+ "* Parse a number."
+ ],
+ "numfmt_parse_currency": [
+ "double numfmt_parse_currency( NumberFormatter $nf, string $str, string $&currency[, int $&position] )",
+ "* Parse a number as currency."
+ ],
+ "numfmt_parse_message": [
+ "array numfmt_parse_message( string $locale, string $pattern, string $source )",
+ "* Parse a message."
+ ],
+ "numfmt_set_attribute": [
+ "bool numfmt_set_attribute( NumberFormatter $nf, int $attr, mixed $value )",
+ "* Get formatter attribute value."
+ ],
+ "numfmt_set_pattern": [
+ "bool numfmt_set_pattern( NumberFormatter $nf, string $pattern )",
+ "* Set formatter pattern."
+ ],
+ "numfmt_set_symbol": [
+ "bool numfmt_set_symbol( NumberFormatter $nf, int $attr, string $symbol )",
+ "* Set formatter symbol value."
+ ],
+ "numfmt_set_text_attribute": [
+ "bool numfmt_set_text_attribute( NumberFormatter $nf, int $attr, string $value )",
+ "* Get formatter attribute value."
+ ],
+ "ob_clean": [
+ "bool ob_clean(void)",
+ "Clean (delete) the current output buffer"
+ ],
+ "ob_end_clean": [
+ "bool ob_end_clean(void)",
+ "Clean the output buffer, and delete current output buffer"
+ ],
+ "ob_end_flush": [
+ "bool ob_end_flush(void)",
+ "Flush (send) the output buffer, and delete current output buffer"
+ ],
+ "ob_flush": [
+ "bool ob_flush(void)",
+ "Flush (send) contents of the output buffer. The last buffer content is sent to next buffer"
+ ],
+ "ob_get_clean": [
+ "bool ob_get_clean(void)",
+ "Get current buffer contents and delete current output buffer"
+ ],
+ "ob_get_contents": [
+ "string ob_get_contents(void)",
+ "Return the contents of the output buffer"
+ ],
+ "ob_get_flush": [
+ "bool ob_get_flush(void)",
+ "Get current buffer contents, flush (send) the output buffer, and delete current output buffer"
+ ],
+ "ob_get_length": [
+ "int ob_get_length(void)",
+ "Return the length of the output buffer"
+ ],
+ "ob_get_level": [
+ "int ob_get_level(void)",
+ "Return the nesting level of the output buffer"
+ ],
+ "ob_get_status": [
+ "false|array ob_get_status([bool full_status])",
+ "Return the status of the active or all output buffers"
+ ],
+ "ob_gzhandler": [
+ "string ob_gzhandler(string str, int mode)",
+ "Encode str based on accept-encoding setting - designed to be called from ob_start()"
+ ],
+ "ob_iconv_handler": [
+ "string ob_iconv_handler(string contents, int status)",
+ "Returns str in output buffer converted to the iconv.output_encoding character set"
+ ],
+ "ob_implicit_flush": [
+ "void ob_implicit_flush([int flag])",
+ "Turn implicit flush on/off and is equivalent to calling flush() after every output call"
+ ],
+ "ob_list_handlers": [
+ "false|array ob_list_handlers()",
+ "* List all output_buffers in an array"
+ ],
+ "ob_start": [
+ "bool ob_start([ string|array user_function [, int chunk_size [, bool erase]]])",
+ "Turn on Output Buffering (specifying an optional output handler)."
+ ],
+ "oci_bind_array_by_name": [
+ "bool oci_bind_array_by_name(resource stmt, string name, array &var, int max_table_length [, int max_item_length [, int type ]])",
+ "Bind a PHP array to an Oracle PL/SQL type by name"
+ ],
+ "oci_bind_by_name": [
+ "bool oci_bind_by_name(resource stmt, string name, mixed &var, [, int maxlength [, int type]])",
+ "Bind a PHP variable to an Oracle placeholder by name"
+ ],
+ "oci_cancel": [
+ "bool oci_cancel(resource stmt)",
+ "Cancel reading from a cursor"
+ ],
+ "oci_close": [
+ "bool oci_close(resource connection)",
+ "Disconnect from database"
+ ],
+ "oci_collection_append": [
+ "bool oci_collection_append(string value)",
+ "Append an object to the collection"
+ ],
+ "oci_collection_assign": [
+ "bool oci_collection_assign(object from)",
+ "Assign a collection from another existing collection"
+ ],
+ "oci_collection_element_assign": [
+ "bool oci_collection_element_assign(int index, string val)",
+ "Assign element val to collection at index ndx"
+ ],
+ "oci_collection_element_get": [
+ "string oci_collection_element_get(int ndx)",
+ "Retrieve the value at collection index ndx"
+ ],
+ "oci_collection_max": [
+ "int oci_collection_max()",
+ "Return the max value of a collection. For a varray this is the maximum length of the array"
+ ],
+ "oci_collection_size": [
+ "int oci_collection_size()",
+ "Return the size of a collection"
+ ],
+ "oci_collection_trim": [
+ "bool oci_collection_trim(int num)",
+ "Trim num elements from the end of a collection"
+ ],
+ "oci_commit": [
+ "bool oci_commit(resource connection)",
+ "Commit the current context"
+ ],
+ "oci_connect": [
+ "resource oci_connect(string user, string pass [, string db [, string charset [, int session_mode ]])",
+ "Connect to an Oracle database and log on. Returns a new session."
+ ],
+ "oci_define_by_name": [
+ "bool oci_define_by_name(resource stmt, string name, mixed &var [, int type])",
+ "Define a PHP variable to an Oracle column by name"
+ ],
+ "oci_error": [
+ "array oci_error([resource stmt|connection|global])",
+ "Return the last error of stmt|connection|global. If no error happened returns false."
+ ],
+ "oci_execute": [
+ "bool oci_execute(resource stmt [, int mode])",
+ "Execute a parsed statement"
+ ],
+ "oci_fetch": [
+ "bool oci_fetch(resource stmt)",
+ "Prepare a new row of data for reading"
+ ],
+ "oci_fetch_all": [
+ "int oci_fetch_all(resource stmt, array &output[, int skip[, int maxrows[, int flags]]])",
+ "Fetch all rows of result data into an array"
+ ],
+ "oci_fetch_array": [
+ "array oci_fetch_array( resource stmt [, int mode ])",
+ "Fetch a result row as an array"
+ ],
+ "oci_fetch_assoc": [
+ "array oci_fetch_assoc( resource stmt )",
+ "Fetch a result row as an associative array"
+ ],
+ "oci_fetch_object": [
+ "object oci_fetch_object( resource stmt )",
+ "Fetch a result row as an object"
+ ],
+ "oci_fetch_row": [
+ "array oci_fetch_row( resource stmt )",
+ "Fetch a result row as an enumerated array"
+ ],
+ "oci_field_is_null": [
+ "bool oci_field_is_null(resource stmt, int col)",
+ "Tell whether a column is NULL"
+ ],
+ "oci_field_name": [
+ "string oci_field_name(resource stmt, int col)",
+ "Tell the name of a column"
+ ],
+ "oci_field_precision": [
+ "int oci_field_precision(resource stmt, int col)",
+ "Tell the precision of a column"
+ ],
+ "oci_field_scale": [
+ "int oci_field_scale(resource stmt, int col)",
+ "Tell the scale of a column"
+ ],
+ "oci_field_size": [
+ "int oci_field_size(resource stmt, int col)",
+ "Tell the maximum data size of a column"
+ ],
+ "oci_field_type": [
+ "mixed oci_field_type(resource stmt, int col)",
+ "Tell the data type of a column"
+ ],
+ "oci_field_type_raw": [
+ "int oci_field_type_raw(resource stmt, int col)",
+ "Tell the raw oracle data type of a column"
+ ],
+ "oci_free_collection": [
+ "bool oci_free_collection()",
+ "Deletes collection object"
+ ],
+ "oci_free_descriptor": [
+ "bool oci_free_descriptor()",
+ "Deletes large object description"
+ ],
+ "oci_free_statement": [
+ "bool oci_free_statement(resource stmt)",
+ "Free all resources associated with a statement"
+ ],
+ "oci_internal_debug": [
+ "void oci_internal_debug(int onoff)",
+ "Toggle internal debugging output for the OCI extension"
+ ],
+ "oci_lob_append": [
+ "bool oci_lob_append( object lob )",
+ "Appends data from a LOB to another LOB"
+ ],
+ "oci_lob_close": [
+ "bool oci_lob_close()",
+ "Closes lob descriptor"
+ ],
+ "oci_lob_copy": [
+ "bool oci_lob_copy( object lob_to, object lob_from [, int length ] )",
+ "Copies data from a LOB to another LOB"
+ ],
+ "oci_lob_eof": [
+ "bool oci_lob_eof()",
+ "Checks if EOF is reached"
+ ],
+ "oci_lob_erase": [
+ "int oci_lob_erase( [ int offset [, int length ] ] )",
+ "Erases a specified portion of the internal LOB, starting at a specified offset"
+ ],
+ "oci_lob_export": [
+ "bool oci_lob_export([string filename [, int start [, int length]]])",
+ "Writes a large object into a file"
+ ],
+ "oci_lob_flush": [
+ "bool oci_lob_flush( [ int flag ] )",
+ "Flushes the LOB buffer"
+ ],
+ "oci_lob_import": [
+ "bool oci_lob_import( string filename )",
+ "Loads file into a LOB"
+ ],
+ "oci_lob_is_equal": [
+ "bool oci_lob_is_equal( object lob1, object lob2 )",
+ "Tests to see if two LOB/FILE locators are equal"
+ ],
+ "oci_lob_load": [
+ "string oci_lob_load()",
+ "Loads a large object"
+ ],
+ "oci_lob_read": [
+ "string oci_lob_read( int length )",
+ "Reads particular part of a large object"
+ ],
+ "oci_lob_rewind": [
+ "bool oci_lob_rewind()",
+ "Rewind pointer of a LOB"
+ ],
+ "oci_lob_save": [
+ "bool oci_lob_save( string data [, int offset ])",
+ "Saves a large object"
+ ],
+ "oci_lob_seek": [
+ "bool oci_lob_seek( int offset [, int whence ])",
+ "Moves the pointer of a LOB"
+ ],
+ "oci_lob_size": [
+ "int oci_lob_size()",
+ "Returns size of a large object"
+ ],
+ "oci_lob_tell": [
+ "int oci_lob_tell()",
+ "Tells LOB pointer position"
+ ],
+ "oci_lob_truncate": [
+ "bool oci_lob_truncate( [ int length ])",
+ "Truncates a LOB"
+ ],
+ "oci_lob_write": [
+ "int oci_lob_write( string string [, int length ])",
+ "Writes data to current position of a LOB"
+ ],
+ "oci_lob_write_temporary": [
+ "bool oci_lob_write_temporary(string var [, int lob_type])",
+ "Writes temporary blob"
+ ],
+ "oci_new_collection": [
+ "object oci_new_collection(resource connection, string tdo [, string schema])",
+ "Initialize a new collection"
+ ],
+ "oci_new_connect": [
+ "resource oci_new_connect(string user, string pass [, string db])",
+ "Connect to an Oracle database and log on. Returns a new session."
+ ],
+ "oci_new_cursor": [
+ "resource oci_new_cursor(resource connection)",
+ "Return a new cursor (Statement-Handle) - use this to bind ref-cursors!"
+ ],
+ "oci_new_descriptor": [
+ "object oci_new_descriptor(resource connection [, int type])",
+ "Initialize a new empty descriptor LOB/FILE (LOB is default)"
+ ],
+ "oci_num_fields": [
+ "int oci_num_fields(resource stmt)",
+ "Return the number of result columns in a statement"
+ ],
+ "oci_num_rows": [
+ "int oci_num_rows(resource stmt)",
+ "Return the row count of an OCI statement"
+ ],
+ "oci_parse": [
+ "resource oci_parse(resource connection, string query)",
+ "Parse a query and return a statement"
+ ],
+ "oci_password_change": [
+ "bool oci_password_change(resource connection, string username, string old_password, string new_password)",
+ "Changes the password of an account"
+ ],
+ "oci_pconnect": [
+ "resource oci_pconnect(string user, string pass [, string db [, string charset ]])",
+ "Connect to an Oracle database using a persistent connection and log on. Returns a new session."
+ ],
+ "oci_result": [
+ "string oci_result(resource stmt, mixed column)",
+ "Return a single column of result data"
+ ],
+ "oci_rollback": [
+ "bool oci_rollback(resource connection)",
+ "Rollback the current context"
+ ],
+ "oci_server_version": [
+ "string oci_server_version(resource connection)",
+ "Return a string containing server version information"
+ ],
+ "oci_set_action": [
+ "bool oci_set_action(resource connection, string value)",
+ "Sets the action attribute on the connection"
+ ],
+ "oci_set_client_identifier": [
+ "bool oci_set_client_identifier(resource connection, string value)",
+ "Sets the client identifier attribute on the connection"
+ ],
+ "oci_set_client_info": [
+ "bool oci_set_client_info(resource connection, string value)",
+ "Sets the client info attribute on the connection"
+ ],
+ "oci_set_edition": [
+ "bool oci_set_edition(string value)",
+ "Sets the edition attribute for all subsequent connections created"
+ ],
+ "oci_set_module_name": [
+ "bool oci_set_module_name(resource connection, string value)",
+ "Sets the module attribute on the connection"
+ ],
+ "oci_set_prefetch": [
+ "bool oci_set_prefetch(resource stmt, int prefetch_rows)",
+ "Sets the number of rows to be prefetched on execute to prefetch_rows for stmt"
+ ],
+ "oci_statement_type": [
+ "string oci_statement_type(resource stmt)",
+ "Return the query type of an OCI statement"
+ ],
+ "ocifetchinto": [
+ "int ocifetchinto(resource stmt, array &output [, int mode])",
+ "Fetch a row of result data into an array"
+ ],
+ "ocigetbufferinglob": [
+ "bool ocigetbufferinglob()",
+ "Returns current state of buffering for a LOB"
+ ],
+ "ocisetbufferinglob": [
+ "bool ocisetbufferinglob( boolean flag )",
+ "Enables/disables buffering for a LOB"
+ ],
+ "octdec": [
+ "int octdec(string octal_number)",
+ "Returns the decimal equivalent of an octal string"
+ ],
+ "odbc_autocommit": [
+ "mixed odbc_autocommit(resource connection_id [, int OnOff])",
+ "Toggle autocommit mode or get status"
+ ],
+ "odbc_binmode": [
+ "bool odbc_binmode(int result_id, int mode)",
+ "Handle binary column data"
+ ],
+ "odbc_close": [
+ "void odbc_close(resource connection_id)",
+ "Close an ODBC connection"
+ ],
+ "odbc_close_all": [
+ "void odbc_close_all(void)",
+ "Close all ODBC connections"
+ ],
+ "odbc_columnprivileges": [
+ "resource odbc_columnprivileges(resource connection_id, string catalog, string schema, string table, string column)",
+ "Returns a result identifier that can be used to fetch a list of columns and associated privileges for the specified table"
+ ],
+ "odbc_columns": [
+ "resource odbc_columns(resource connection_id [, string qualifier [, string owner [, string table_name [, string column_name]]]])",
+ "Returns a result identifier that can be used to fetch a list of column names in specified tables"
+ ],
+ "odbc_commit": [
+ "bool odbc_commit(resource connection_id)",
+ "Commit an ODBC transaction"
+ ],
+ "odbc_connect": [
+ "resource odbc_connect(string DSN, string user, string password [, int cursor_option])",
+ "Connect to a datasource"
+ ],
+ "odbc_cursor": [
+ "string odbc_cursor(resource result_id)",
+ "Get cursor name"
+ ],
+ "odbc_data_source": [
+ "array odbc_data_source(resource connection_id, int fetch_type)",
+ "Return information about the currently connected data source"
+ ],
+ "odbc_error": [
+ "string odbc_error([resource connection_id])",
+ "Get the last error code"
+ ],
+ "odbc_errormsg": [
+ "string odbc_errormsg([resource connection_id])",
+ "Get the last error message"
+ ],
+ "odbc_exec": [
+ "resource odbc_exec(resource connection_id, string query [, int flags])",
+ "Prepare and execute an SQL statement"
+ ],
+ "odbc_execute": [
+ "bool odbc_execute(resource result_id [, array parameters_array])",
+ "Execute a prepared statement"
+ ],
+ "odbc_fetch_array": [
+ "array odbc_fetch_array(int result [, int rownumber])",
+ "Fetch a result row as an associative array"
+ ],
+ "odbc_fetch_into": [
+ "int odbc_fetch_into(resource result_id, array &result_array, [, int rownumber])",
+ "Fetch one result row into an array"
+ ],
+ "odbc_fetch_object": [
+ "object odbc_fetch_object(int result [, int rownumber])",
+ "Fetch a result row as an object"
+ ],
+ "odbc_fetch_row": [
+ "bool odbc_fetch_row(resource result_id [, int row_number])",
+ "Fetch a row"
+ ],
+ "odbc_field_len": [
+ "int odbc_field_len(resource result_id, int field_number)",
+ "Get the length (precision) of a column"
+ ],
+ "odbc_field_name": [
+ "string odbc_field_name(resource result_id, int field_number)",
+ "Get a column name"
+ ],
+ "odbc_field_num": [
+ "int odbc_field_num(resource result_id, string field_name)",
+ "Return column number"
+ ],
+ "odbc_field_scale": [
+ "int odbc_field_scale(resource result_id, int field_number)",
+ "Get the scale of a column"
+ ],
+ "odbc_field_type": [
+ "string odbc_field_type(resource result_id, int field_number)",
+ "Get the datatype of a column"
+ ],
+ "odbc_foreignkeys": [
+ "resource odbc_foreignkeys(resource connection_id, string pk_qualifier, string pk_owner, string pk_table, string fk_qualifier, string fk_owner, string fk_table)",
+ "Returns a result identifier to either a list of foreign keys in the specified table or a list of foreign keys in other tables that refer to the primary key in the specified table"
+ ],
+ "odbc_free_result": [
+ "bool odbc_free_result(resource result_id)",
+ "Free resources associated with a result"
+ ],
+ "odbc_gettypeinfo": [
+ "resource odbc_gettypeinfo(resource connection_id [, int data_type])",
+ "Returns a result identifier containing information about data types supported by the data source"
+ ],
+ "odbc_longreadlen": [
+ "bool odbc_longreadlen(int result_id, int length)",
+ "Handle LONG columns"
+ ],
+ "odbc_next_result": [
+ "bool odbc_next_result(resource result_id)",
+ "Checks if multiple results are avaiable"
+ ],
+ "odbc_num_fields": [
+ "int odbc_num_fields(resource result_id)",
+ "Get number of columns in a result"
+ ],
+ "odbc_num_rows": [
+ "int odbc_num_rows(resource result_id)",
+ "Get number of rows in a result"
+ ],
+ "odbc_pconnect": [
+ "resource odbc_pconnect(string DSN, string user, string password [, int cursor_option])",
+ "Establish a persistent connection to a datasource"
+ ],
+ "odbc_prepare": [
+ "resource odbc_prepare(resource connection_id, string query)",
+ "Prepares a statement for execution"
+ ],
+ "odbc_primarykeys": [
+ "resource odbc_primarykeys(resource connection_id, string qualifier, string owner, string table)",
+ "Returns a result identifier listing the column names that comprise the primary key for a table"
+ ],
+ "odbc_procedurecolumns": [
+ "resource odbc_procedurecolumns(resource connection_id [, string qualifier, string owner, string proc, string column])",
+ "Returns a result identifier containing the list of input and output parameters, as well as the columns that make up the result set for the specified procedures"
+ ],
+ "odbc_procedures": [
+ "resource odbc_procedures(resource connection_id [, string qualifier, string owner, string name])",
+ "Returns a result identifier containg the list of procedure names in a datasource"
+ ],
+ "odbc_result": [
+ "mixed odbc_result(resource result_id, mixed field)",
+ "Get result data"
+ ],
+ "odbc_result_all": [
+ "int odbc_result_all(resource result_id [, string format])",
+ "Print result as HTML table"
+ ],
+ "odbc_rollback": [
+ "bool odbc_rollback(resource connection_id)",
+ "Rollback a transaction"
+ ],
+ "odbc_setoption": [
+ "bool odbc_setoption(resource conn_id|result_id, int which, int option, int value)",
+ "Sets connection or statement options"
+ ],
+ "odbc_specialcolumns": [
+ "resource odbc_specialcolumns(resource connection_id, int type, string qualifier, string owner, string table, int scope, int nullable)",
+ "Returns a result identifier containing either the optimal set of columns that uniquely identifies a row in the table or columns that are automatically updated when any value in the row is updated by a transaction"
+ ],
+ "odbc_statistics": [
+ "resource odbc_statistics(resource connection_id, string qualifier, string owner, string name, int unique, int accuracy)",
+ "Returns a result identifier that contains statistics about a single table and the indexes associated with the table"
+ ],
+ "odbc_tableprivileges": [
+ "resource odbc_tableprivileges(resource connection_id, string qualifier, string owner, string name)",
+ "Returns a result identifier containing a list of tables and the privileges associated with each table"
+ ],
+ "odbc_tables": [
+ "resource odbc_tables(resource connection_id [, string qualifier [, string owner [, string name [, string table_types]]]])",
+ "Call the SQLTables function"
+ ],
+ "opendir": [
+ "mixed opendir(string path[, resource context])",
+ "Open a directory and return a dir_handle"
+ ],
+ "openlog": [
+ "bool openlog(string ident, int option, int facility)",
+ "Open connection to system logger"
+ ],
+ "openssl_csr_export": [
+ "bool openssl_csr_export(resource csr, string &out [, bool notext=true])",
+ "Exports a CSR to file or a var"
+ ],
+ "openssl_csr_export_to_file": [
+ "bool openssl_csr_export_to_file(resource csr, string outfilename [, bool notext=true])",
+ "Exports a CSR to file"
+ ],
+ "openssl_csr_get_public_key": [
+ "mixed openssl_csr_get_public_key(mixed csr)",
+ "Returns the subject of a CERT or FALSE on error"
+ ],
+ "openssl_csr_get_subject": [
+ "mixed openssl_csr_get_subject(mixed csr)",
+ "Returns the subject of a CERT or FALSE on error"
+ ],
+ "openssl_csr_new": [
+ "bool openssl_csr_new(array dn, resource &privkey [, array configargs [, array extraattribs]])",
+ "Generates a privkey and CSR"
+ ],
+ "openssl_csr_sign": [
+ "resource openssl_csr_sign(mixed csr, mixed x509, mixed priv_key, long days [, array config_args [, long serial]])",
+ "Signs a cert with another CERT"
+ ],
+ "openssl_decrypt": [
+ "string openssl_decrypt(string data, string method, string password [, bool raw_input=false])",
+ "Takes raw or base64 encoded string and dectupt it using given method and key"
+ ],
+ "openssl_dh_compute_key": [
+ "string openssl_dh_compute_key(string pub_key, resource dh_key)",
+ "Computes shared sicret for public value of remote DH key and local DH key"
+ ],
+ "openssl_digest": [
+ "string openssl_digest(string data, string method [, bool raw_output=false])",
+ "Computes digest hash value for given data using given method, returns raw or binhex encoded string"
+ ],
+ "openssl_encrypt": [
+ "string openssl_encrypt(string data, string method, string password [, bool raw_output=false])",
+ "Encrypts given data with given method and key, returns raw or base64 encoded string"
+ ],
+ "openssl_error_string": [
+ "mixed openssl_error_string(void)",
+ "Returns a description of the last error, and alters the index of the error messages. Returns false when the are no more messages"
+ ],
+ "openssl_get_cipher_methods": [
+ "array openssl_get_cipher_methods([bool aliases = false])",
+ "Return array of available cipher methods"
+ ],
+ "openssl_get_md_methods": [
+ "array openssl_get_md_methods([bool aliases = false])",
+ "Return array of available digest methods"
+ ],
+ "openssl_open": [
+ "bool openssl_open(string data, &string opendata, string ekey, mixed privkey)",
+ "Opens data"
+ ],
+ "openssl_pkcs12_export": [
+ "bool openssl_pkcs12_export(mixed x509, string &out, mixed priv_key, string pass[, array args])",
+ "Creates and exports a PKCS12 to a var"
+ ],
+ "openssl_pkcs12_export_to_file": [
+ "bool openssl_pkcs12_export_to_file(mixed x509, string filename, mixed priv_key, string pass[, array args])",
+ "Creates and exports a PKCS to file"
+ ],
+ "openssl_pkcs12_read": [
+ "bool openssl_pkcs12_read(string PKCS12, array &certs, string pass)",
+ "Parses a PKCS12 to an array"
+ ],
+ "openssl_pkcs7_decrypt": [
+ "bool openssl_pkcs7_decrypt(string infilename, string outfilename, mixed recipcert [, mixed recipkey])",
+ "Decrypts the S/MIME message in the file name infilename and output the results to the file name outfilename. recipcert is a CERT for one of the recipients. recipkey specifies the private key matching recipcert, if recipcert does not include the key"
+ ],
+ "openssl_pkcs7_encrypt": [
+ "bool openssl_pkcs7_encrypt(string infile, string outfile, mixed recipcerts, array headers [, long flags [, long cipher]])",
+ "Encrypts the message in the file named infile with the certificates in recipcerts and output the result to the file named outfile"
+ ],
+ "openssl_pkcs7_sign": [
+ "bool openssl_pkcs7_sign(string infile, string outfile, mixed signcert, mixed signkey, array headers [, long flags [, string extracertsfilename]])",
+ "Signs the MIME message in the file named infile with signcert/signkey and output the result to file name outfile. headers lists plain text headers to exclude from the signed portion of the message, and should include to, from and subject as a minimum"
+ ],
+ "openssl_pkcs7_verify": [
+ "bool openssl_pkcs7_verify(string filename, long flags [, string signerscerts [, array cainfo [, string extracerts [, string content]]]])",
+ "Verifys that the data block is intact, the signer is who they say they are, and returns the CERTs of the signers"
+ ],
+ "openssl_pkey_export": [
+ "bool openssl_pkey_export(mixed key, &mixed out [, string passphrase [, array config_args]])",
+ "Gets an exportable representation of a key into a string or file"
+ ],
+ "openssl_pkey_export_to_file": [
+ "bool openssl_pkey_export_to_file(mixed key, string outfilename [, string passphrase, array config_args)",
+ "Gets an exportable representation of a key into a file"
+ ],
+ "openssl_pkey_free": [
+ "void openssl_pkey_free(int key)",
+ "Frees a key"
+ ],
+ "openssl_pkey_get_details": [
+ "resource openssl_pkey_get_details(resource key)",
+ "returns an array with the key details (bits, pkey, type)"
+ ],
+ "openssl_pkey_get_private": [
+ "int openssl_pkey_get_private(string key [, string passphrase])",
+ "Gets private keys"
+ ],
+ "openssl_pkey_get_public": [
+ "int openssl_pkey_get_public(mixed cert)",
+ "Gets public key from X.509 certificate"
+ ],
+ "openssl_pkey_new": [
+ "resource openssl_pkey_new([array configargs])",
+ "Generates a new private key"
+ ],
+ "openssl_private_decrypt": [
+ "bool openssl_private_decrypt(string data, string &decrypted, mixed key [, int padding])",
+ "Decrypts data with private key"
+ ],
+ "openssl_private_encrypt": [
+ "bool openssl_private_encrypt(string data, string &crypted, mixed key [, int padding])",
+ "Encrypts data with private key"
+ ],
+ "openssl_public_decrypt": [
+ "bool openssl_public_decrypt(string data, string &crypted, resource key [, int padding])",
+ "Decrypts data with public key"
+ ],
+ "openssl_public_encrypt": [
+ "bool openssl_public_encrypt(string data, string &crypted, mixed key [, int padding])",
+ "Encrypts data with public key"
+ ],
+ "openssl_random_pseudo_bytes": [
+ "string openssl_random_pseudo_bytes(integer length [, &bool returned_strong_result])",
+ "Returns a string of the length specified filled with random pseudo bytes"
+ ],
+ "openssl_seal": [
+ "int openssl_seal(string data, &string sealdata, &array ekeys, array pubkeys)",
+ "Seals data"
+ ],
+ "openssl_sign": [
+ "bool openssl_sign(string data, &string signature, mixed key[, mixed method])",
+ "Signs data"
+ ],
+ "openssl_verify": [
+ "int openssl_verify(string data, string signature, mixed key[, mixed method])",
+ "Verifys data"
+ ],
+ "openssl_x509_check_private_key": [
+ "bool openssl_x509_check_private_key(mixed cert, mixed key)",
+ "Checks if a private key corresponds to a CERT"
+ ],
+ "openssl_x509_checkpurpose": [
+ "int openssl_x509_checkpurpose(mixed x509cert, int purpose, array cainfo [, string untrustedfile])",
+ "Checks the CERT to see if it can be used for the purpose in purpose. cainfo holds information about trusted CAs"
+ ],
+ "openssl_x509_export": [
+ "bool openssl_x509_export(mixed x509, string &out [, bool notext = true])",
+ "Exports a CERT to file or a var"
+ ],
+ "openssl_x509_export_to_file": [
+ "bool openssl_x509_export_to_file(mixed x509, string outfilename [, bool notext = true])",
+ "Exports a CERT to file or a var"
+ ],
+ "openssl_x509_free": [
+ "void openssl_x509_free(resource x509)",
+ "Frees X.509 certificates"
+ ],
+ "openssl_x509_parse": [
+ "array openssl_x509_parse(mixed x509 [, bool shortnames=true])",
+ "Returns an array of the fields/values of the CERT"
+ ],
+ "openssl_x509_read": [
+ "resource openssl_x509_read(mixed cert)",
+ "Reads X.509 certificates"
+ ],
+ "ord": [
+ "int ord(string character)",
+ "Returns ASCII value of character"
+ ],
+ "output_add_rewrite_var": [
+ "bool output_add_rewrite_var(string name, string value)",
+ "Add URL rewriter values"
+ ],
+ "output_reset_rewrite_vars": [
+ "bool output_reset_rewrite_vars(void)",
+ "Reset(clear) URL rewriter values"
+ ],
+ "pack": [
+ "string pack(string format, mixed arg1 [, mixed arg2 [, mixed ...]])",
+ "Takes one or more arguments and packs them into a binary string according to the format argument"
+ ],
+ "parse_ini_file": [
+ "array parse_ini_file(string filename [, bool process_sections [, int scanner_mode]])",
+ "Parse configuration file"
+ ],
+ "parse_ini_string": [
+ "array parse_ini_string(string ini_string [, bool process_sections [, int scanner_mode]])",
+ "Parse configuration string"
+ ],
+ "parse_locale": [
+ "static array parse_locale($locale)",
+ "* parses a locale-id into an array the different parts of it"
+ ],
+ "parse_str": [
+ "void parse_str(string encoded_string [, array result])",
+ "Parses GET/POST/COOKIE data and sets global variables"
+ ],
+ "parse_url": [
+ "mixed parse_url(string url, [int url_component])",
+ "Parse a URL and return its components"
+ ],
+ "passthru": [
+ "void passthru(string command [, int &return_value])",
+ "Execute an external program and display raw output"
+ ],
+ "pathinfo": [
+ "array pathinfo(string path[, int options])",
+ "Returns information about a certain string"
+ ],
+ "pclose": [
+ "int pclose(resource fp)",
+ "Close a file pointer opened by popen()"
+ ],
+ "pcnlt_sigwaitinfo": [
+ "int pcnlt_sigwaitinfo(array set[, array &siginfo])",
+ "Synchronously wait for queued signals"
+ ],
+ "pcntl_alarm": [
+ "int pcntl_alarm(int seconds)",
+ "Set an alarm clock for delivery of a signal"
+ ],
+ "pcntl_exec": [
+ "bool pcntl_exec(string path [, array args [, array envs]])",
+ "Executes specified program in current process space as defined by exec(2)"
+ ],
+ "pcntl_fork": [
+ "int pcntl_fork(void)",
+ "Forks the currently running process following the same behavior as the UNIX fork() system call"
+ ],
+ "pcntl_getpriority": [
+ "int pcntl_getpriority([int pid [, int process_identifier]])",
+ "Get the priority of any process"
+ ],
+ "pcntl_setpriority": [
+ "bool pcntl_setpriority(int priority [, int pid [, int process_identifier]])",
+ "Change the priority of any process"
+ ],
+ "pcntl_signal": [
+ "bool pcntl_signal(int signo, callback handle [, bool restart_syscalls])",
+ "Assigns a system signal handler to a PHP function"
+ ],
+ "pcntl_signal_dispatch": [
+ "bool pcntl_signal_dispatch()",
+ "Dispatch signals to signal handlers"
+ ],
+ "pcntl_sigprocmask": [
+ "bool pcntl_sigprocmask(int how, array set[, array &oldset])",
+ "Examine and change blocked signals"
+ ],
+ "pcntl_sigtimedwait": [
+ "int pcntl_sigtimedwait(array set[, array &siginfo[, int seconds[, int nanoseconds]]])",
+ "Wait for queued signals"
+ ],
+ "pcntl_wait": [
+ "int pcntl_wait(int &status)",
+ "Waits on or returns the status of a forked child as defined by the waitpid() system call"
+ ],
+ "pcntl_waitpid": [
+ "int pcntl_waitpid(int pid, int &status, int options)",
+ "Waits on or returns the status of a forked child as defined by the waitpid() system call"
+ ],
+ "pcntl_wexitstatus": [
+ "int pcntl_wexitstatus(int status)",
+ "Returns the status code of a child's exit"
+ ],
+ "pcntl_wifexited": [
+ "bool pcntl_wifexited(int status)",
+ "Returns true if the child status code represents a successful exit"
+ ],
+ "pcntl_wifsignaled": [
+ "bool pcntl_wifsignaled(int status)",
+ "Returns true if the child status code represents a process that was terminated due to a signal"
+ ],
+ "pcntl_wifstopped": [
+ "bool pcntl_wifstopped(int status)",
+ "Returns true if the child status code represents a stopped process (WUNTRACED must have been used with waitpid)"
+ ],
+ "pcntl_wstopsig": [
+ "int pcntl_wstopsig(int status)",
+ "Returns the number of the signal that caused the process to stop who's status code is passed"
+ ],
+ "pcntl_wtermsig": [
+ "int pcntl_wtermsig(int status)",
+ "Returns the number of the signal that terminated the process who's status code is passed"
+ ],
+ "pdo_drivers": [
+ "array pdo_drivers()",
+ "Return array of available PDO drivers"
+ ],
+ "pfsockopen": [
+ "resource pfsockopen(string hostname, int port [, int errno [, string errstr [, float timeout]]])",
+ "Open persistent Internet or Unix domain socket connection"
+ ],
+ "pg_affected_rows": [
+ "int pg_affected_rows(resource result)",
+ "Returns the number of affected tuples"
+ ],
+ "pg_cancel_query": [
+ "bool pg_cancel_query(resource connection)",
+ "Cancel request"
+ ],
+ "pg_client_encoding": [
+ "string pg_client_encoding([resource connection])",
+ "Get the current client encoding"
+ ],
+ "pg_close": [
+ "bool pg_close([resource connection])",
+ "Close a PostgreSQL connection"
+ ],
+ "pg_connect": [
+ "resource pg_connect(string connection_string[, int connect_type] | [string host, string port [, string options [, string tty,]]] string database)",
+ "Open a PostgreSQL connection"
+ ],
+ "pg_connection_busy": [
+ "bool pg_connection_busy(resource connection)",
+ "Get connection is busy or not"
+ ],
+ "pg_connection_reset": [
+ "bool pg_connection_reset(resource connection)",
+ "Reset connection (reconnect)"
+ ],
+ "pg_connection_status": [
+ "int pg_connection_status(resource connnection)",
+ "Get connection status"
+ ],
+ "pg_convert": [
+ "array pg_convert(resource db, string table, array values[, int options])",
+ "Check and convert values for PostgreSQL SQL statement"
+ ],
+ "pg_copy_from": [
+ "bool pg_copy_from(resource connection, string table_name , array rows [, string delimiter [, string null_as]])",
+ "Copy table from array"
+ ],
+ "pg_copy_to": [
+ "array pg_copy_to(resource connection, string table_name [, string delimiter [, string null_as]])",
+ "Copy table to array"
+ ],
+ "pg_dbname": [
+ "string pg_dbname([resource connection])",
+ "Get the database name"
+ ],
+ "pg_delete": [
+ "mixed pg_delete(resource db, string table, array ids[, int options])",
+ "Delete records has ids (id=>value)"
+ ],
+ "pg_end_copy": [
+ "bool pg_end_copy([resource connection])",
+ "Sync with backend. Completes the Copy command"
+ ],
+ "pg_escape_bytea": [
+ "string pg_escape_bytea([resource connection,] string data)",
+ "Escape binary for bytea type"
+ ],
+ "pg_escape_string": [
+ "string pg_escape_string([resource connection,] string data)",
+ "Escape string for text/char type"
+ ],
+ "pg_execute": [
+ "resource pg_execute([resource connection,] string stmtname, array params)",
+ "Execute a prepared query"
+ ],
+ "pg_fetch_all": [
+ "array pg_fetch_all(resource result)",
+ "Fetch all rows into array"
+ ],
+ "pg_fetch_all_columns": [
+ "array pg_fetch_all_columns(resource result [, int column_number])",
+ "Fetch all rows into array"
+ ],
+ "pg_fetch_array": [
+ "array pg_fetch_array(resource result [, int row [, int result_type]])",
+ "Fetch a row as an array"
+ ],
+ "pg_fetch_assoc": [
+ "array pg_fetch_assoc(resource result [, int row])",
+ "Fetch a row as an assoc array"
+ ],
+ "pg_fetch_object": [
+ "object pg_fetch_object(resource result [, int row [, string class_name [, NULL|array ctor_params]]])",
+ "Fetch a row as an object"
+ ],
+ "pg_fetch_result": [
+ "mixed pg_fetch_result(resource result, [int row_number,] mixed field_name)",
+ "Returns values from a result identifier"
+ ],
+ "pg_fetch_row": [
+ "array pg_fetch_row(resource result [, int row [, int result_type]])",
+ "Get a row as an enumerated array"
+ ],
+ "pg_field_is_null": [
+ "int pg_field_is_null(resource result, [int row,] mixed field_name_or_number)",
+ "Test if a field is NULL"
+ ],
+ "pg_field_name": [
+ "string pg_field_name(resource result, int field_number)",
+ "Returns the name of the field"
+ ],
+ "pg_field_num": [
+ "int pg_field_num(resource result, string field_name)",
+ "Returns the field number of the named field"
+ ],
+ "pg_field_prtlen": [
+ "int pg_field_prtlen(resource result, [int row,] mixed field_name_or_number)",
+ "Returns the printed length"
+ ],
+ "pg_field_size": [
+ "int pg_field_size(resource result, int field_number)",
+ "Returns the internal size of the field"
+ ],
+ "pg_field_table": [
+ "mixed pg_field_table(resource result, int field_number[, bool oid_only])",
+ "Returns the name of the table field belongs to, or table's oid if oid_only is true"
+ ],
+ "pg_field_type": [
+ "string pg_field_type(resource result, int field_number)",
+ "Returns the type name for the given field"
+ ],
+ "pg_field_type_oid": [
+ "string pg_field_type_oid(resource result, int field_number)",
+ "Returns the type oid for the given field"
+ ],
+ "pg_free_result": [
+ "bool pg_free_result(resource result)",
+ "Free result memory"
+ ],
+ "pg_get_notify": [
+ "array pg_get_notify([resource connection[, result_type]])",
+ "Get asynchronous notification"
+ ],
+ "pg_get_pid": [
+ "int pg_get_pid([resource connection)",
+ "Get backend(server) pid"
+ ],
+ "pg_get_result": [
+ "resource pg_get_result(resource connection)",
+ "Get asynchronous query result"
+ ],
+ "pg_host": [
+ "string pg_host([resource connection])",
+ "Returns the host name associated with the connection"
+ ],
+ "pg_insert": [
+ "mixed pg_insert(resource db, string table, array values[, int options])",
+ "Insert values (filed=>value) to table"
+ ],
+ "pg_last_error": [
+ "string pg_last_error([resource connection])",
+ "Get the error message string"
+ ],
+ "pg_last_notice": [
+ "string pg_last_notice(resource connection)",
+ "Returns the last notice set by the backend"
+ ],
+ "pg_last_oid": [
+ "string pg_last_oid(resource result)",
+ "Returns the last object identifier"
+ ],
+ "pg_lo_close": [
+ "bool pg_lo_close(resource large_object)",
+ "Close a large object"
+ ],
+ "pg_lo_create": [
+ "mixed pg_lo_create([resource connection],[mixed large_object_oid])",
+ "Create a large object"
+ ],
+ "pg_lo_export": [
+ "bool pg_lo_export([resource connection, ] int objoid, string filename)",
+ "Export large object direct to filesystem"
+ ],
+ "pg_lo_import": [
+ "int pg_lo_import([resource connection, ] string filename [, mixed oid])",
+ "Import large object direct from filesystem"
+ ],
+ "pg_lo_open": [
+ "resource pg_lo_open([resource connection,] int large_object_oid, string mode)",
+ "Open a large object and return fd"
+ ],
+ "pg_lo_read": [
+ "string pg_lo_read(resource large_object [, int len])",
+ "Read a large object"
+ ],
+ "pg_lo_read_all": [
+ "int pg_lo_read_all(resource large_object)",
+ "Read a large object and send straight to browser"
+ ],
+ "pg_lo_seek": [
+ "bool pg_lo_seek(resource large_object, int offset [, int whence])",
+ "Seeks position of large object"
+ ],
+ "pg_lo_tell": [
+ "int pg_lo_tell(resource large_object)",
+ "Returns current position of large object"
+ ],
+ "pg_lo_unlink": [
+ "bool pg_lo_unlink([resource connection,] string large_object_oid)",
+ "Delete a large object"
+ ],
+ "pg_lo_write": [
+ "int pg_lo_write(resource large_object, string buf [, int len])",
+ "Write a large object"
+ ],
+ "pg_meta_data": [
+ "array pg_meta_data(resource db, string table)",
+ "Get meta_data"
+ ],
+ "pg_num_fields": [
+ "int pg_num_fields(resource result)",
+ "Return the number of fields in the result"
+ ],
+ "pg_num_rows": [
+ "int pg_num_rows(resource result)",
+ "Return the number of rows in the result"
+ ],
+ "pg_options": [
+ "string pg_options([resource connection])",
+ "Get the options associated with the connection"
+ ],
+ "pg_parameter_status": [
+ "string|false pg_parameter_status([resource connection,] string param_name)",
+ "Returns the value of a server parameter"
+ ],
+ "pg_pconnect": [
+ "resource pg_pconnect(string connection_string | [string host, string port [, string options [, string tty,]]] string database)",
+ "Open a persistent PostgreSQL connection"
+ ],
+ "pg_ping": [
+ "bool pg_ping([resource connection])",
+ "Ping database. If connection is bad, try to reconnect."
+ ],
+ "pg_port": [
+ "int pg_port([resource connection])",
+ "Return the port number associated with the connection"
+ ],
+ "pg_prepare": [
+ "resource pg_prepare([resource connection,] string stmtname, string query)",
+ "Prepare a query for future execution"
+ ],
+ "pg_put_line": [
+ "bool pg_put_line([resource connection,] string query)",
+ "Send null-terminated string to backend server"
+ ],
+ "pg_query": [
+ "resource pg_query([resource connection,] string query)",
+ "Execute a query"
+ ],
+ "pg_query_params": [
+ "resource pg_query_params([resource connection,] string query, array params)",
+ "Execute a query"
+ ],
+ "pg_result_error": [
+ "string pg_result_error(resource result)",
+ "Get error message associated with result"
+ ],
+ "pg_result_error_field": [
+ "string pg_result_error_field(resource result, int fieldcode)",
+ "Get error message field associated with result"
+ ],
+ "pg_result_seek": [
+ "bool pg_result_seek(resource result, int offset)",
+ "Set internal row offset"
+ ],
+ "pg_result_status": [
+ "mixed pg_result_status(resource result[, long result_type])",
+ "Get status of query result"
+ ],
+ "pg_select": [
+ "mixed pg_select(resource db, string table, array ids[, int options])",
+ "Select records that has ids (id=>value)"
+ ],
+ "pg_send_execute": [
+ "bool pg_send_execute(resource connection, string stmtname, array params)",
+ "Executes prevriously prepared stmtname asynchronously"
+ ],
+ "pg_send_prepare": [
+ "bool pg_send_prepare(resource connection, string stmtname, string query)",
+ "Asynchronously prepare a query for future execution"
+ ],
+ "pg_send_query": [
+ "bool pg_send_query(resource connection, string query)",
+ "Send asynchronous query"
+ ],
+ "pg_send_query_params": [
+ "bool pg_send_query_params(resource connection, string query, array params)",
+ "Send asynchronous parameterized query"
+ ],
+ "pg_set_client_encoding": [
+ "int pg_set_client_encoding([resource connection,] string encoding)",
+ "Set client encoding"
+ ],
+ "pg_set_error_verbosity": [
+ "int pg_set_error_verbosity([resource connection,] int verbosity)",
+ "Set error verbosity"
+ ],
+ "pg_trace": [
+ "bool pg_trace(string filename [, string mode [, resource connection]])",
+ "Enable tracing a PostgreSQL connection"
+ ],
+ "pg_transaction_status": [
+ "int pg_transaction_status(resource connnection)",
+ "Get transaction status"
+ ],
+ "pg_tty": [
+ "string pg_tty([resource connection])",
+ "Return the tty name associated with the connection"
+ ],
+ "pg_unescape_bytea": [
+ "string pg_unescape_bytea(string data)",
+ "Unescape binary for bytea type"
+ ],
+ "pg_untrace": [
+ "bool pg_untrace([resource connection])",
+ "Disable tracing of a PostgreSQL connection"
+ ],
+ "pg_update": [
+ "mixed pg_update(resource db, string table, array fields, array ids[, int options])",
+ "Update table using values (field=>value) and ids (id=>value)"
+ ],
+ "pg_version": [
+ "array pg_version([resource connection])",
+ "Returns an array with client, protocol and server version (when available)"
+ ],
+ "php_egg_logo_guid": [
+ "string php_egg_logo_guid(void)",
+ "Return the special ID used to request the PHP logo in phpinfo screens"
+ ],
+ "php_ini_loaded_file": [
+ "string php_ini_loaded_file(void)",
+ "Return the actual loaded ini filename"
+ ],
+ "php_ini_scanned_files": [
+ "string php_ini_scanned_files(void)",
+ "Return comma-separated string of .ini files parsed from the additional ini dir"
+ ],
+ "php_logo_guid": [
+ "string php_logo_guid(void)",
+ "Return the special ID used to request the PHP logo in phpinfo screens"
+ ],
+ "php_real_logo_guid": [
+ "string php_real_logo_guid(void)",
+ "Return the special ID used to request the PHP logo in phpinfo screens"
+ ],
+ "php_sapi_name": [
+ "string php_sapi_name(void)",
+ "Return the current SAPI module name"
+ ],
+ "php_snmpv3": [
+ "void php_snmpv3(INTERNAL_FUNCTION_PARAMETERS, int st)",
+ "* * Generic SNMPv3 object fetcher * From here is passed on the the common internal object fetcher. * * st=SNMP_CMD_GET snmp3_get() - query an agent and return a single value. * st=SNMP_CMD_GETNEXT snmp3_getnext() - query an agent and return the next single value. * st=SNMP_CMD_WALK snmp3_walk() - walk the mib and return a single dimensional array * containing the values. * st=SNMP_CMD_REALWALK snmp3_real_walk() - walk the mib and return an * array of oid,value pairs. * st=SNMP_CMD_SET snmp3_set() - query an agent and set a single value *"
+ ],
+ "php_strip_whitespace": [
+ "string php_strip_whitespace(string file_name)",
+ "Return source with stripped comments and whitespace"
+ ],
+ "php_uname": [
+ "string php_uname(void)",
+ "Return information about the system PHP was built on"
+ ],
+ "phpcredits": [
+ "void phpcredits([int flag])",
+ "Prints the list of people who've contributed to the PHP project"
+ ],
+ "phpinfo": [
+ "void phpinfo([int what])",
+ "Output a page of useful information about PHP and the current request"
+ ],
+ "phpversion": [
+ "string phpversion([string extension])",
+ "Return the current PHP version"
+ ],
+ "pi": [
+ "float pi(void)",
+ "Returns an approximation of pi"
+ ],
+ "png2wbmp": [
+ "bool png2wbmp (string f_org, string f_dest, int d_height, int d_width, int threshold)",
+ "Convert PNG image to WBMP image"
+ ],
+ "popen": [
+ "resource popen(string command, string mode)",
+ "Execute a command and open either a read or a write pipe to it"
+ ],
+ "posix_access": [
+ "bool posix_access(string file [, int mode])",
+ "Determine accessibility of a file (POSIX.1 5.6.3)"
+ ],
+ "posix_ctermid": [
+ "string posix_ctermid(void)",
+ "Generate terminal path name (POSIX.1, 4.7.1)"
+ ],
+ "posix_get_last_error": [
+ "int posix_get_last_error(void)",
+ "Retrieve the error number set by the last posix function which failed."
+ ],
+ "posix_getcwd": [
+ "string posix_getcwd(void)",
+ "Get working directory pathname (POSIX.1, 5.2.2)"
+ ],
+ "posix_getegid": [
+ "int posix_getegid(void)",
+ "Get the current effective group id (POSIX.1, 4.2.1)"
+ ],
+ "posix_geteuid": [
+ "int posix_geteuid(void)",
+ "Get the current effective user id (POSIX.1, 4.2.1)"
+ ],
+ "posix_getgid": [
+ "int posix_getgid(void)",
+ "Get the current group id (POSIX.1, 4.2.1)"
+ ],
+ "posix_getgrgid": [
+ "array posix_getgrgid(long gid)",
+ "Group database access (POSIX.1, 9.2.1)"
+ ],
+ "posix_getgrnam": [
+ "array posix_getgrnam(string groupname)",
+ "Group database access (POSIX.1, 9.2.1)"
+ ],
+ "posix_getgroups": [
+ "array posix_getgroups(void)",
+ "Get supplementary group id's (POSIX.1, 4.2.3)"
+ ],
+ "posix_getlogin": [
+ "string posix_getlogin(void)",
+ "Get user name (POSIX.1, 4.2.4)"
+ ],
+ "posix_getpgid": [
+ "int posix_getpgid(void)",
+ "Get the process group id of the specified process (This is not a POSIX function, but a SVR4ism, so we compile conditionally)"
+ ],
+ "posix_getpgrp": [
+ "int posix_getpgrp(void)",
+ "Get current process group id (POSIX.1, 4.3.1)"
+ ],
+ "posix_getpid": [
+ "int posix_getpid(void)",
+ "Get the current process id (POSIX.1, 4.1.1)"
+ ],
+ "posix_getppid": [
+ "int posix_getppid(void)",
+ "Get the parent process id (POSIX.1, 4.1.1)"
+ ],
+ "posix_getpwnam": [
+ "array posix_getpwnam(string groupname)",
+ "User database access (POSIX.1, 9.2.2)"
+ ],
+ "posix_getpwuid": [
+ "array posix_getpwuid(long uid)",
+ "User database access (POSIX.1, 9.2.2)"
+ ],
+ "posix_getrlimit": [
+ "array posix_getrlimit(void)",
+ "Get system resource consumption limits (This is not a POSIX function, but a BSDism and a SVR4ism. We compile conditionally)"
+ ],
+ "posix_getsid": [
+ "int posix_getsid(void)",
+ "Get process group id of session leader (This is not a POSIX function, but a SVR4ism, so be compile conditionally)"
+ ],
+ "posix_getuid": [
+ "int posix_getuid(void)",
+ "Get the current user id (POSIX.1, 4.2.1)"
+ ],
+ "posix_initgroups": [
+ "bool posix_initgroups(string name, int base_group_id)",
+ "Calculate the group access list for the user specified in name."
+ ],
+ "posix_isatty": [
+ "bool posix_isatty(int fd)",
+ "Determine if filedesc is a tty (POSIX.1, 4.7.1)"
+ ],
+ "posix_kill": [
+ "bool posix_kill(int pid, int sig)",
+ "Send a signal to a process (POSIX.1, 3.3.2)"
+ ],
+ "posix_mkfifo": [
+ "bool posix_mkfifo(string pathname, int mode)",
+ "Make a FIFO special file (POSIX.1, 5.4.2)"
+ ],
+ "posix_mknod": [
+ "bool posix_mknod(string pathname, int mode [, int major [, int minor]])",
+ "Make a special or ordinary file (POSIX.1)"
+ ],
+ "posix_setegid": [
+ "bool posix_setegid(long uid)",
+ "Set effective group id"
+ ],
+ "posix_seteuid": [
+ "bool posix_seteuid(long uid)",
+ "Set effective user id"
+ ],
+ "posix_setgid": [
+ "bool posix_setgid(int uid)",
+ "Set group id (POSIX.1, 4.2.2)"
+ ],
+ "posix_setpgid": [
+ "bool posix_setpgid(int pid, int pgid)",
+ "Set process group id for job control (POSIX.1, 4.3.3)"
+ ],
+ "posix_setsid": [
+ "int posix_setsid(void)",
+ "Create session and set process group id (POSIX.1, 4.3.2)"
+ ],
+ "posix_setuid": [
+ "bool posix_setuid(long uid)",
+ "Set user id (POSIX.1, 4.2.2)"
+ ],
+ "posix_strerror": [
+ "string posix_strerror(int errno)",
+ "Retrieve the system error message associated with the given errno."
+ ],
+ "posix_times": [
+ "array posix_times(void)",
+ "Get process times (POSIX.1, 4.5.2)"
+ ],
+ "posix_ttyname": [
+ "string posix_ttyname(int fd)",
+ "Determine terminal device name (POSIX.1, 4.7.2)"
+ ],
+ "posix_uname": [
+ "array posix_uname(void)",
+ "Get system name (POSIX.1, 4.4.1)"
+ ],
+ "pow": [
+ "number pow(number base, number exponent)",
+ "Returns base raised to the power of exponent. Returns integer result when possible"
+ ],
+ "preg_filter": [
+ "mixed preg_filter(mixed regex, mixed replace, mixed subject [, int limit [, int &count]])",
+ "Perform Perl-style regular expression replacement and only return matches."
+ ],
+ "preg_grep": [
+ "array preg_grep(string regex, array input [, int flags])",
+ "Searches array and returns entries which match regex"
+ ],
+ "preg_last_error": [
+ "int preg_last_error()",
+ "Returns the error code of the last regexp execution."
+ ],
+ "preg_match": [
+ "int preg_match(string pattern, string subject [, array &subpatterns [, int flags [, int offset]]])",
+ "Perform a Perl-style regular expression match"
+ ],
+ "preg_match_all": [
+ "int preg_match_all(string pattern, string subject, array &subpatterns [, int flags [, int offset]])",
+ "Perform a Perl-style global regular expression match"
+ ],
+ "preg_quote": [
+ "string preg_quote(string str [, string delim_char])",
+ "Quote regular expression characters plus an optional character"
+ ],
+ "preg_replace": [
+ "mixed preg_replace(mixed regex, mixed replace, mixed subject [, int limit [, int &count]])",
+ "Perform Perl-style regular expression replacement."
+ ],
+ "preg_replace_callback": [
+ "mixed preg_replace_callback(mixed regex, mixed callback, mixed subject [, int limit [, int &count]])",
+ "Perform Perl-style regular expression replacement using replacement callback."
+ ],
+ "preg_split": [
+ "array preg_split(string pattern, string subject [, int limit [, int flags]])",
+ "Split string into an array using a perl-style regular expression as a delimiter"
+ ],
+ "prev": [
+ "mixed prev(array array_arg)",
+ "Move array argument's internal pointer to the previous element and return it"
+ ],
+ "print": [
+ "int print(string arg)",
+ "Output a string"
+ ],
+ "print_r": [
+ "mixed print_r(mixed var [, bool return])",
+ "Prints out or returns information about the specified variable"
+ ],
+ "printf": [
+ "int printf(string format [, mixed arg1 [, mixed ...]])",
+ "Output a formatted string"
+ ],
+ "proc_close": [
+ "int proc_close(resource process)",
+ "close a process opened by proc_open"
+ ],
+ "proc_get_status": [
+ "array proc_get_status(resource process)",
+ "get information about a process opened by proc_open"
+ ],
+ "proc_nice": [
+ "bool proc_nice(int priority)",
+ "Change the priority of the current process"
+ ],
+ "proc_open": [
+ "resource proc_open(string command, array descriptorspec, array &pipes [, string cwd [, array env [, array other_options]]])",
+ "Run a process with more control over it's file descriptors"
+ ],
+ "proc_terminate": [
+ "bool proc_terminate(resource process [, long signal])",
+ "kill a process opened by proc_open"
+ ],
+ "property_exists": [
+ "bool property_exists(mixed object_or_class, string property_name)",
+ "Checks if the object or class has a property"
+ ],
+ "pspell_add_to_personal": [
+ "bool pspell_add_to_personal(int pspell, string word)",
+ "Adds a word to a personal list"
+ ],
+ "pspell_add_to_session": [
+ "bool pspell_add_to_session(int pspell, string word)",
+ "Adds a word to the current session"
+ ],
+ "pspell_check": [
+ "bool pspell_check(int pspell, string word)",
+ "Returns true if word is valid"
+ ],
+ "pspell_clear_session": [
+ "bool pspell_clear_session(int pspell)",
+ "Clears the current session"
+ ],
+ "pspell_config_create": [
+ "int pspell_config_create(string language [, string spelling [, string jargon [, string encoding]]])",
+ "Create a new config to be used later to create a manager"
+ ],
+ "pspell_config_data_dir": [
+ "bool pspell_config_data_dir(int conf, string directory)",
+ "location of language data files"
+ ],
+ "pspell_config_dict_dir": [
+ "bool pspell_config_dict_dir(int conf, string directory)",
+ "location of the main word list"
+ ],
+ "pspell_config_ignore": [
+ "bool pspell_config_ignore(int conf, int ignore)",
+ "Ignore words <= n chars"
+ ],
+ "pspell_config_mode": [
+ "bool pspell_config_mode(int conf, long mode)",
+ "Select mode for config (PSPELL_FAST, PSPELL_NORMAL or PSPELL_BAD_SPELLERS)"
+ ],
+ "pspell_config_personal": [
+ "bool pspell_config_personal(int conf, string personal)",
+ "Use a personal dictionary for this config"
+ ],
+ "pspell_config_repl": [
+ "bool pspell_config_repl(int conf, string repl)",
+ "Use a personal dictionary with replacement pairs for this config"
+ ],
+ "pspell_config_runtogether": [
+ "bool pspell_config_runtogether(int conf, bool runtogether)",
+ "Consider run-together words as valid components"
+ ],
+ "pspell_config_save_repl": [
+ "bool pspell_config_save_repl(int conf, bool save)",
+ "Save replacement pairs when personal list is saved for this config"
+ ],
+ "pspell_new": [
+ "int pspell_new(string language [, string spelling [, string jargon [, string encoding [, int mode]]]])",
+ "Load a dictionary"
+ ],
+ "pspell_new_config": [
+ "int pspell_new_config(int config)",
+ "Load a dictionary based on the given config"
+ ],
+ "pspell_new_personal": [
+ "int pspell_new_personal(string personal, string language [, string spelling [, string jargon [, string encoding [, int mode]]]])",
+ "Load a dictionary with a personal wordlist"
+ ],
+ "pspell_save_wordlist": [
+ "bool pspell_save_wordlist(int pspell)",
+ "Saves the current (personal) wordlist"
+ ],
+ "pspell_store_replacement": [
+ "bool pspell_store_replacement(int pspell, string misspell, string correct)",
+ "Notify the dictionary of a user-selected replacement"
+ ],
+ "pspell_suggest": [
+ "array pspell_suggest(int pspell, string word)",
+ "Returns array of suggestions"
+ ],
+ "putenv": [
+ "bool putenv(string setting)",
+ "Set the value of an environment variable"
+ ],
+ "quoted_printable_decode": [
+ "string quoted_printable_decode(string str)",
+ "Convert a quoted-printable string to an 8 bit string"
+ ],
+ "quoted_printable_encode": [
+ "string quoted_printable_encode(string str) */",
+ "PHP_FUNCTION(quoted_printable_encode) { char *str, *new_str; int str_len; size_t new_str_len; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, \"s\", &str, &str_len) != SUCCESS) { return; } if (!str_len) { RETURN_EMPTY_STRING(); } new_str = (char *)php_quot_print_encode((unsigned char *)str, (size_t)str_len, &new_str_len); RETURN_STRINGL(new_str, new_str_len, 0); } /* }}}"
+ ],
+ "quotemeta": [
+ "string quotemeta(string str)",
+ "Quotes meta characters"
+ ],
+ "rad2deg": [
+ "float rad2deg(float number)",
+ "Converts the radian number to the equivalent number in degrees"
+ ],
+ "rand": [
+ "int rand([int min, int max])",
+ "Returns a random number"
+ ],
+ "range": [
+ "array range(mixed low, mixed high[, int step])",
+ "Create an array containing the range of integers or characters from low to high (inclusive)"
+ ],
+ "rawurldecode": [
+ "string rawurldecode(string str)",
+ "Decodes URL-encodes string"
+ ],
+ "rawurlencode": [
+ "string rawurlencode(string str)",
+ "URL-encodes string"
+ ],
+ "readdir": [
+ "string readdir([resource dir_handle])",
+ "Read directory entry from dir_handle"
+ ],
+ "readfile": [
+ "int readfile(string filename [, bool use_include_path[, resource context]])",
+ "Output a file or a URL"
+ ],
+ "readgzfile": [
+ "int readgzfile(string filename [, int use_include_path])",
+ "Output a .gz-file"
+ ],
+ "readline": [
+ "string readline([string prompt])",
+ "Reads a line"
+ ],
+ "readline_add_history": [
+ "bool readline_add_history(string prompt)",
+ "Adds a line to the history"
+ ],
+ "readline_callback_handler_install": [
+ "void readline_callback_handler_install(string prompt, mixed callback)",
+ "Initializes the readline callback interface and terminal, prints the prompt and returns immediately"
+ ],
+ "readline_callback_handler_remove": [
+ "bool readline_callback_handler_remove()",
+ "Removes a previously installed callback handler and restores terminal settings"
+ ],
+ "readline_callback_read_char": [
+ "void readline_callback_read_char()",
+ "Informs the readline callback interface that a character is ready for input"
+ ],
+ "readline_clear_history": [
+ "bool readline_clear_history(void)",
+ "Clears the history"
+ ],
+ "readline_completion_function": [
+ "bool readline_completion_function(string funcname)",
+ "Readline completion function?"
+ ],
+ "readline_info": [
+ "mixed readline_info([string varname [, string newvalue]])",
+ "Gets/sets various internal readline variables."
+ ],
+ "readline_list_history": [
+ "array readline_list_history(void)",
+ "Lists the history"
+ ],
+ "readline_on_new_line": [
+ "void readline_on_new_line(void)",
+ "Inform readline that the cursor has moved to a new line"
+ ],
+ "readline_read_history": [
+ "bool readline_read_history([string filename])",
+ "Reads the history"
+ ],
+ "readline_redisplay": [
+ "void readline_redisplay(void)",
+ "Ask readline to redraw the display"
+ ],
+ "readline_write_history": [
+ "bool readline_write_history([string filename])",
+ "Writes the history"
+ ],
+ "readlink": [
+ "string readlink(string filename)",
+ "Return the target of a symbolic link"
+ ],
+ "realpath": [
+ "string realpath(string path)",
+ "Return the resolved path"
+ ],
+ "realpath_cache_get": [
+ "bool realpath_cache_get()",
+ "Get current size of realpath cache"
+ ],
+ "realpath_cache_size": [
+ "bool realpath_cache_size()",
+ "Get current size of realpath cache"
+ ],
+ "recode_file": [
+ "bool recode_file(string request, resource input, resource output)",
+ "Recode file input into file output according to request"
+ ],
+ "recode_string": [
+ "string recode_string(string request, string str)",
+ "Recode string str according to request string"
+ ],
+ "register_shutdown_function": [
+ "void register_shutdown_function(string function_name)",
+ "Register a user-level function to be called on request termination"
+ ],
+ "register_tick_function": [
+ "bool register_tick_function(string function_name [, mixed arg [, mixed ... ]])",
+ "Registers a tick callback function"
+ ],
+ "rename": [
+ "bool rename(string old_name, string new_name[, resource context])",
+ "Rename a file"
+ ],
+ "require": [
+ "bool require(string path)",
+ "Includes and evaluates the specified file, erroring if the file cannot be included"
+ ],
+ "require_once": [
+ "bool require_once(string path)",
+ "Includes and evaluates the specified file, erroring if the file cannot be included"
+ ],
+ "reset": [
+ "mixed reset(array array_arg)",
+ "Set array argument's internal pointer to the first element and return it"
+ ],
+ "restore_error_handler": [
+ "void restore_error_handler(void)",
+ "Restores the previously defined error handler function"
+ ],
+ "restore_exception_handler": [
+ "void restore_exception_handler(void)",
+ "Restores the previously defined exception handler function"
+ ],
+ "restore_include_path": [
+ "void restore_include_path()",
+ "Restore the value of the include_path configuration option"
+ ],
+ "rewind": [
+ "bool rewind(resource fp)",
+ "Rewind the position of a file pointer"
+ ],
+ "rewinddir": [
+ "void rewinddir([resource dir_handle])",
+ "Rewind dir_handle back to the start"
+ ],
+ "rmdir": [
+ "bool rmdir(string dirname[, resource context])",
+ "Remove a directory"
+ ],
+ "round": [
+ "float round(float number [, int precision [, int mode]])",
+ "Returns the number rounded to specified precision"
+ ],
+ "rsort": [
+ "bool rsort(array &array_arg [, int sort_flags])",
+ "Sort an array in reverse order"
+ ],
+ "rtrim": [
+ "string rtrim(string str [, string character_mask])",
+ "Removes trailing whitespace"
+ ],
+ "scandir": [
+ "array scandir(string dir [, int sorting_order [, resource context]])",
+ "List files & directories inside the specified path"
+ ],
+ "sem_acquire": [
+ "bool sem_acquire(resource id)",
+ "Acquires the semaphore with the given id, blocking if necessary"
+ ],
+ "sem_get": [
+ "resource sem_get(int key [, int max_acquire [, int perm [, int auto_release]])",
+ "Return an id for the semaphore with the given key, and allow max_acquire (default 1) processes to acquire it simultaneously"
+ ],
+ "sem_release": [
+ "bool sem_release(resource id)",
+ "Releases the semaphore with the given id"
+ ],
+ "sem_remove": [
+ "bool sem_remove(resource id)",
+ "Removes semaphore from Unix systems"
+ ],
+ "serialize": [
+ "string serialize(mixed variable)",
+ "Returns a string representation of variable (which can later be unserialized)"
+ ],
+ "session_cache_expire": [
+ "int session_cache_expire([int new_cache_expire])",
+ "Return the current cache expire. If new_cache_expire is given, the current cache_expire is replaced with new_cache_expire"
+ ],
+ "session_cache_limiter": [
+ "string session_cache_limiter([string new_cache_limiter])",
+ "Return the current cache limiter. If new_cache_limited is given, the current cache_limiter is replaced with new_cache_limiter"
+ ],
+ "session_decode": [
+ "bool session_decode(string data)",
+ "Deserializes data and reinitializes the variables"
+ ],
+ "session_destroy": [
+ "bool session_destroy(void)",
+ "Destroy the current session and all data associated with it"
+ ],
+ "session_encode": [
+ "string session_encode(void)",
+ "Serializes the current setup and returns the serialized representation"
+ ],
+ "session_get_cookie_params": [
+ "array session_get_cookie_params(void)",
+ "Return the session cookie parameters"
+ ],
+ "session_id": [
+ "string session_id([string newid])",
+ "Return the current session id. If newid is given, the session id is replaced with newid"
+ ],
+ "session_is_registered": [
+ "bool session_is_registered(string varname)",
+ "Checks if a variable is registered in session"
+ ],
+ "session_module_name": [
+ "string session_module_name([string newname])",
+ "Return the current module name used for accessing session data. If newname is given, the module name is replaced with newname"
+ ],
+ "session_name": [
+ "string session_name([string newname])",
+ "Return the current session name. If newname is given, the session name is replaced with newname"
+ ],
+ "session_regenerate_id": [
+ "bool session_regenerate_id([bool delete_old_session])",
+ "Update the current session id with a newly generated one. If delete_old_session is set to true, remove the old session."
+ ],
+ "session_register": [
+ "bool session_register(mixed var_names [, mixed ...])",
+ "Adds varname(s) to the list of variables which are freezed at the session end"
+ ],
+ "session_save_path": [
+ "string session_save_path([string newname])",
+ "Return the current save path passed to module_name. If newname is given, the save path is replaced with newname"
+ ],
+ "session_set_cookie_params": [
+ "void session_set_cookie_params(int lifetime [, string path [, string domain [, bool secure[, bool httponly]]]])",
+ "Set session cookie parameters"
+ ],
+ "session_set_save_handler": [
+ "void session_set_save_handler(string open, string close, string read, string write, string destroy, string gc)",
+ "Sets user-level functions"
+ ],
+ "session_start": [
+ "bool session_start(void)",
+ "Begin session - reinitializes freezed variables, registers browsers etc"
+ ],
+ "session_unregister": [
+ "bool session_unregister(string varname)",
+ "Removes varname from the list of variables which are freezed at the session end"
+ ],
+ "session_unset": [
+ "void session_unset(void)",
+ "Unset all registered variables"
+ ],
+ "session_write_close": [
+ "void session_write_close(void)",
+ "Write session data and end session"
+ ],
+ "set_error_handler": [
+ "string set_error_handler(string error_handler [, int error_types])",
+ "Sets a user-defined error handler function. Returns the previously defined error handler, or false on error"
+ ],
+ "set_exception_handler": [
+ "string set_exception_handler(callable exception_handler)",
+ "Sets a user-defined exception handler function. Returns the previously defined exception handler, or false on error"
+ ],
+ "set_include_path": [
+ "string set_include_path(string new_include_path)",
+ "Sets the include_path configuration option"
+ ],
+ "set_magic_quotes_runtime": [
+ "bool set_magic_quotes_runtime(int new_setting)",
+ "Set the current active configuration setting of magic_quotes_runtime and return previous"
+ ],
+ "set_time_limit": [
+ "bool set_time_limit(int seconds)",
+ "Sets the maximum time a script can run"
+ ],
+ "setcookie": [
+ "bool setcookie(string name [, string value [, int expires [, string path [, string domain [, bool secure[, bool httponly]]]]]])",
+ "Send a cookie"
+ ],
+ "setlocale": [
+ "string setlocale(mixed category, string locale [, string ...])",
+ "Set locale information"
+ ],
+ "setrawcookie": [
+ "bool setrawcookie(string name [, string value [, int expires [, string path [, string domain [, bool secure[, bool httponly]]]]]])",
+ "Send a cookie with no url encoding of the value"
+ ],
+ "settype": [
+ "bool settype(mixed var, string type)",
+ "Set the type of the variable"
+ ],
+ "sha1": [
+ "string sha1(string str [, bool raw_output])",
+ "Calculate the sha1 hash of a string"
+ ],
+ "sha1_file": [
+ "string sha1_file(string filename [, bool raw_output])",
+ "Calculate the sha1 hash of given filename"
+ ],
+ "shell_exec": [
+ "string shell_exec(string cmd)",
+ "Execute command via shell and return complete output as string"
+ ],
+ "shm_attach": [
+ "int shm_attach(int key [, int memsize [, int perm]])",
+ "Creates or open a shared memory segment"
+ ],
+ "shm_detach": [
+ "bool shm_detach(resource shm_identifier)",
+ "Disconnects from shared memory segment"
+ ],
+ "shm_get_var": [
+ "mixed shm_get_var(resource id, int variable_key)",
+ "Returns a variable from shared memory"
+ ],
+ "shm_has_var": [
+ "bool shm_has_var(resource id, int variable_key)",
+ "Checks whether a specific entry exists"
+ ],
+ "shm_put_var": [
+ "bool shm_put_var(resource shm_identifier, int variable_key, mixed variable)",
+ "Inserts or updates a variable in shared memory"
+ ],
+ "shm_remove": [
+ "bool shm_remove(resource shm_identifier)",
+ "Removes shared memory from Unix systems"
+ ],
+ "shm_remove_var": [
+ "bool shm_remove_var(resource id, int variable_key)",
+ "Removes variable from shared memory"
+ ],
+ "shmop_close": [
+ "void shmop_close (int shmid)",
+ "closes a shared memory segment"
+ ],
+ "shmop_delete": [
+ "bool shmop_delete (int shmid)",
+ "mark segment for deletion"
+ ],
+ "shmop_open": [
+ "int shmop_open (int key, string flags, int mode, int size)",
+ "gets and attaches a shared memory segment"
+ ],
+ "shmop_read": [
+ "string shmop_read (int shmid, int start, int count)",
+ "reads from a shm segment"
+ ],
+ "shmop_size": [
+ "int shmop_size (int shmid)",
+ "returns the shm size"
+ ],
+ "shmop_write": [
+ "int shmop_write (int shmid, string data, int offset)",
+ "writes to a shared memory segment"
+ ],
+ "shuffle": [
+ "bool shuffle(array array_arg)",
+ "Randomly shuffle the contents of an array"
+ ],
+ "similar_text": [
+ "int similar_text(string str1, string str2 [, float percent])",
+ "Calculates the similarity between two strings"
+ ],
+ "simplexml_import_dom": [
+ "simplemxml_element simplexml_import_dom(domNode node [, string class_name])",
+ "Get a simplexml_element object from dom to allow for processing"
+ ],
+ "simplexml_load_file": [
+ "simplemxml_element simplexml_load_file(string filename [, string class_name [, int options [, string ns [, bool is_prefix]]]])",
+ "Load a filename and return a simplexml_element object to allow for processing"
+ ],
+ "simplexml_load_string": [
+ "simplemxml_element simplexml_load_string(string data [, string class_name [, int options [, string ns [, bool is_prefix]]]])",
+ "Load a string and return a simplexml_element object to allow for processing"
+ ],
+ "sin": [
+ "float sin(float number)",
+ "Returns the sine of the number in radians"
+ ],
+ "sinh": [
+ "float sinh(float number)",
+ "Returns the hyperbolic sine of the number, defined as (exp(number) - exp(-number))/2"
+ ],
+ "sleep": [
+ "void sleep(int seconds)",
+ "Delay for a given number of seconds"
+ ],
+ "smfi_addheader": [
+ "bool smfi_addheader(string headerf, string headerv)",
+ "Adds a header to the current message."
+ ],
+ "smfi_addrcpt": [
+ "bool smfi_addrcpt(string rcpt)",
+ "Add a recipient to the message envelope."
+ ],
+ "smfi_chgheader": [
+ "bool smfi_chgheader(string headerf, string headerv)",
+ "Changes a header's value for the current message."
+ ],
+ "smfi_delrcpt": [
+ "bool smfi_delrcpt(string rcpt)",
+ "Removes the named recipient from the current message's envelope."
+ ],
+ "smfi_getsymval": [
+ "string smfi_getsymval(string macro)",
+ "Returns the value of the given macro or NULL if the macro is not defined."
+ ],
+ "smfi_replacebody": [
+ "bool smfi_replacebody(string body)",
+ "Replaces the body of the current message. If called more than once, subsequent calls result in data being appended to the new body."
+ ],
+ "smfi_setflags": [
+ "void smfi_setflags(long flags)",
+ "Sets the flags describing the actions the filter may take."
+ ],
+ "smfi_setreply": [
+ "bool smfi_setreply(string rcode, string xcode, string message)",
+ "Directly set the SMTP error reply code for this connection. This code will be used on subsequent error replies resulting from actions taken by this filter."
+ ],
+ "smfi_settimeout": [
+ "void smfi_settimeout(long timeout)",
+ "Sets the number of seconds libmilter will wait for an MTA connection before timing out a socket."
+ ],
+ "snmp2_get": [
+ "string snmp2_get(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Fetch a SNMP object"
+ ],
+ "snmp2_getnext": [
+ "string snmp2_getnext(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Fetch a SNMP object"
+ ],
+ "snmp2_real_walk": [
+ "array snmp2_real_walk(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Return all objects including their respective object id withing the specified one"
+ ],
+ "snmp2_set": [
+ "int snmp2_set(string host, string community, string object_id, string type, mixed value [, int timeout [, int retries]])",
+ "Set the value of a SNMP object"
+ ],
+ "snmp2_walk": [
+ "array snmp2_walk(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Return all objects under the specified object id"
+ ],
+ "snmp3_get": [
+ "int snmp3_get(string host, string sec_name, string sec_level, string auth_protocol, string auth_passphrase, string priv_protocol, string priv_passphrase, string object_id [, int timeout [, int retries]])",
+ "Fetch the value of a SNMP object"
+ ],
+ "snmp3_getnext": [
+ "int snmp3_getnext(string host, string sec_name, string sec_level, string auth_protocol, string auth_passphrase, string priv_protocol, string priv_passphrase, string object_id [, int timeout [, int retries]])",
+ "Fetch the value of a SNMP object"
+ ],
+ "snmp3_real_walk": [
+ "int snmp3_real_walk(string host, string sec_name, string sec_level, string auth_protocol, string auth_passphrase, string priv_protocol, string priv_passphrase, string object_id [, int timeout [, int retries]])",
+ "Fetch the value of a SNMP object"
+ ],
+ "snmp3_set": [
+ "int snmp3_set(string host, string sec_name, string sec_level, string auth_protocol, string auth_passphrase, string priv_protocol, string priv_passphrase, string object_id, string type, mixed value [, int timeout [, int retries]])",
+ "Fetch the value of a SNMP object"
+ ],
+ "snmp3_walk": [
+ "int snmp3_walk(string host, string sec_name, string sec_level, string auth_protocol, string auth_passphrase, string priv_protocol, string priv_passphrase, string object_id [, int timeout [, int retries]])",
+ "Fetch the value of a SNMP object"
+ ],
+ "snmp_get_quick_print": [
+ "bool snmp_get_quick_print(void)",
+ "Return the current status of quick_print"
+ ],
+ "snmp_get_valueretrieval": [
+ "int snmp_get_valueretrieval()",
+ "Return the method how the SNMP values will be returned"
+ ],
+ "snmp_read_mib": [
+ "int snmp_read_mib(string filename)",
+ "Reads and parses a MIB file into the active MIB tree."
+ ],
+ "snmp_set_enum_print": [
+ "void snmp_set_enum_print(int enum_print)",
+ "Return all values that are enums with their enum value instead of the raw integer"
+ ],
+ "snmp_set_oid_output_format": [
+ "void snmp_set_oid_output_format(int oid_format)",
+ "Set the OID output format."
+ ],
+ "snmp_set_quick_print": [
+ "void snmp_set_quick_print(int quick_print)",
+ "Return all objects including their respective object id withing the specified one"
+ ],
+ "snmp_set_valueretrieval": [
+ "void snmp_set_valueretrieval(int method)",
+ "Specify the method how the SNMP values will be returned"
+ ],
+ "snmpget": [
+ "string snmpget(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Fetch a SNMP object"
+ ],
+ "snmpgetnext": [
+ "string snmpgetnext(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Fetch a SNMP object"
+ ],
+ "snmprealwalk": [
+ "array snmprealwalk(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Return all objects including their respective object id withing the specified one"
+ ],
+ "snmpset": [
+ "int snmpset(string host, string community, string object_id, string type, mixed value [, int timeout [, int retries]])",
+ "Set the value of a SNMP object"
+ ],
+ "snmpwalk": [
+ "array snmpwalk(string host, string community, string object_id [, int timeout [, int retries]])",
+ "Return all objects under the specified object id"
+ ],
+ "socket_accept": [
+ "resource socket_accept(resource socket)",
+ "Accepts a connection on the listening socket fd"
+ ],
+ "socket_bind": [
+ "bool socket_bind(resource socket, string addr [, int port])",
+ "Binds an open socket to a listening port, port is only specified in AF_INET family."
+ ],
+ "socket_clear_error": [
+ "void socket_clear_error([resource socket])",
+ "Clears the error on the socket or the last error code."
+ ],
+ "socket_close": [
+ "void socket_close(resource socket)",
+ "Closes a file descriptor"
+ ],
+ "socket_connect": [
+ "bool socket_connect(resource socket, string addr [, int port])",
+ "Opens a connection to addr:port on the socket specified by socket"
+ ],
+ "socket_create": [
+ "resource socket_create(int domain, int type, int protocol)",
+ "Creates an endpoint for communication in the domain specified by domain, of type specified by type"
+ ],
+ "socket_create_listen": [
+ "resource socket_create_listen(int port[, int backlog])",
+ "Opens a socket on port to accept connections"
+ ],
+ "socket_create_pair": [
+ "bool socket_create_pair(int domain, int type, int protocol, array &fd)",
+ "Creates a pair of indistinguishable sockets and stores them in fds."
+ ],
+ "socket_get_option": [
+ "mixed socket_get_option(resource socket, int level, int optname)",
+ "Gets socket options for the socket"
+ ],
+ "socket_getpeername": [
+ "bool socket_getpeername(resource socket, string &addr[, int &port])",
+ "Queries the remote side of the given socket which may either result in host/port or in a UNIX filesystem path, dependent on its type."
+ ],
+ "socket_getsockname": [
+ "bool socket_getsockname(resource socket, string &addr[, int &port])",
+ "Queries the remote side of the given socket which may either result in host/port or in a UNIX filesystem path, dependent on its type."
+ ],
+ "socket_last_error": [
+ "int socket_last_error([resource socket])",
+ "Returns the last socket error (either the last used or the provided socket resource)"
+ ],
+ "socket_listen": [
+ "bool socket_listen(resource socket[, int backlog])",
+ "Sets the maximum number of connections allowed to be waited for on the socket specified by fd"
+ ],
+ "socket_read": [
+ "string socket_read(resource socket, int length [, int type])",
+ "Reads a maximum of length bytes from socket"
+ ],
+ "socket_recv": [
+ "int socket_recv(resource socket, string &buf, int len, int flags)",
+ "Receives data from a connected socket"
+ ],
+ "socket_recvfrom": [
+ "int socket_recvfrom(resource socket, string &buf, int len, int flags, string &name [, int &port])",
+ "Receives data from a socket, connected or not"
+ ],
+ "socket_select": [
+ "int socket_select(array &read_fds, array &write_fds, array &except_fds, int tv_sec[, int tv_usec])",
+ "Runs the select() system call on the sets mentioned with a timeout specified by tv_sec and tv_usec"
+ ],
+ "socket_send": [
+ "int socket_send(resource socket, string buf, int len, int flags)",
+ "Sends data to a connected socket"
+ ],
+ "socket_sendto": [
+ "int socket_sendto(resource socket, string buf, int len, int flags, string addr [, int port])",
+ "Sends a message to a socket, whether it is connected or not"
+ ],
+ "socket_set_block": [
+ "bool socket_set_block(resource socket)",
+ "Sets blocking mode on a socket resource"
+ ],
+ "socket_set_nonblock": [
+ "bool socket_set_nonblock(resource socket)",
+ "Sets nonblocking mode on a socket resource"
+ ],
+ "socket_set_option": [
+ "bool socket_set_option(resource socket, int level, int optname, int|array optval)",
+ "Sets socket options for the socket"
+ ],
+ "socket_shutdown": [
+ "bool socket_shutdown(resource socket[, int how])",
+ "Shuts down a socket for receiving, sending, or both."
+ ],
+ "socket_strerror": [
+ "string socket_strerror(int errno)",
+ "Returns a string describing an error"
+ ],
+ "socket_write": [
+ "int socket_write(resource socket, string buf[, int length])",
+ "Writes the buffer to the socket resource, length is optional"
+ ],
+ "solid_fetch_prev": [
+ "bool solid_fetch_prev(resource result_id)",
+ ""
+ ],
+ "sort": [
+ "bool sort(array &array_arg [, int sort_flags])",
+ "Sort an array"
+ ],
+ "soundex": [
+ "string soundex(string str)",
+ "Calculate the soundex key of a string"
+ ],
+ "spl_autoload": [
+ "void spl_autoload(string class_name [, string file_extensions])",
+ "Default implementation for __autoload()"
+ ],
+ "spl_autoload_call": [
+ "void spl_autoload_call(string class_name)",
+ "Try all registerd autoload function to load the requested class"
+ ],
+ "spl_autoload_extensions": [
+ "string spl_autoload_extensions([string file_extensions])",
+ "Register and return default file extensions for spl_autoload"
+ ],
+ "spl_autoload_functions": [
+ "false|array spl_autoload_functions()",
+ "Return all registered __autoload() functionns"
+ ],
+ "spl_autoload_register": [
+ "bool spl_autoload_register([mixed autoload_function = \"spl_autoload\" [, throw = true [, prepend]]])",
+ "Register given function as __autoload() implementation"
+ ],
+ "spl_autoload_unregister": [
+ "bool spl_autoload_unregister(mixed autoload_function)",
+ "Unregister given function as __autoload() implementation"
+ ],
+ "spl_classes": [
+ "array spl_classes()",
+ "Return an array containing the names of all clsses and interfaces defined in SPL"
+ ],
+ "spl_object_hash": [
+ "string spl_object_hash(object obj)",
+ "Return hash id for given object"
+ ],
+ "split": [
+ "array split(string pattern, string string [, int limit])",
+ "Split string into array by regular expression"
+ ],
+ "spliti": [
+ "array spliti(string pattern, string string [, int limit])",
+ "Split string into array by regular expression case-insensitive"
+ ],
+ "sprintf": [
+ "string sprintf(string format [, mixed arg1 [, mixed ...]])",
+ "Return a formatted string"
+ ],
+ "sql_regcase": [
+ "string sql_regcase(string string)",
+ "Make regular expression for case insensitive match"
+ ],
+ "sqlite_array_query": [
+ "array sqlite_array_query(resource db, string query [ , int result_type [, bool decode_binary]])",
+ "Executes a query against a given database and returns an array of arrays."
+ ],
+ "sqlite_busy_timeout": [
+ "void sqlite_busy_timeout(resource db, int ms)",
+ "Set busy timeout duration. If ms <= 0, all busy handlers are disabled."
+ ],
+ "sqlite_changes": [
+ "int sqlite_changes(resource db)",
+ "Returns the number of rows that were changed by the most recent SQL statement."
+ ],
+ "sqlite_close": [
+ "void sqlite_close(resource db)",
+ "Closes an open sqlite database."
+ ],
+ "sqlite_column": [
+ "mixed sqlite_column(resource result, mixed index_or_name [, bool decode_binary])",
+ "Fetches a column from the current row of a result set."
+ ],
+ "sqlite_create_aggregate": [
+ "bool sqlite_create_aggregate(resource db, string funcname, mixed step_func, mixed finalize_func[, long num_args])",
+ "Registers an aggregate function for queries."
+ ],
+ "sqlite_create_function": [
+ "bool sqlite_create_function(resource db, string funcname, mixed callback[, long num_args])",
+ "Registers a \"regular\" function for queries."
+ ],
+ "sqlite_current": [
+ "array sqlite_current(resource result [, int result_type [, bool decode_binary]])",
+ "Fetches the current row from a result set as an array."
+ ],
+ "sqlite_error_string": [
+ "string sqlite_error_string(int error_code)",
+ "Returns the textual description of an error code."
+ ],
+ "sqlite_escape_string": [
+ "string sqlite_escape_string(string item)",
+ "Escapes a string for use as a query parameter."
+ ],
+ "sqlite_exec": [
+ "boolean sqlite_exec(string query, resource db[, string &error_message])",
+ "Executes a result-less query against a given database"
+ ],
+ "sqlite_factory": [
+ "object sqlite_factory(string filename [, int mode [, string &error_message]])",
+ "Opens a SQLite database and creates an object for it. Will create the database if it does not exist."
+ ],
+ "sqlite_fetch_all": [
+ "array sqlite_fetch_all(resource result [, int result_type [, bool decode_binary]])",
+ "Fetches all rows from a result set as an array of arrays."
+ ],
+ "sqlite_fetch_array": [
+ "array sqlite_fetch_array(resource result [, int result_type [, bool decode_binary]])",
+ "Fetches the next row from a result set as an array."
+ ],
+ "sqlite_fetch_column_types": [
+ "resource sqlite_fetch_column_types(string table_name, resource db [, int result_type])",
+ "Return an array of column types from a particular table."
+ ],
+ "sqlite_fetch_object": [
+ "object sqlite_fetch_object(resource result [, string class_name [, NULL|array ctor_params [, bool decode_binary]]])",
+ "Fetches the next row from a result set as an object."
+ ],
+ "sqlite_fetch_single": [
+ "string sqlite_fetch_single(resource result [, bool decode_binary])",
+ "Fetches the first column of a result set as a string."
+ ],
+ "sqlite_field_name": [
+ "string sqlite_field_name(resource result, int field_index)",
+ "Returns the name of a particular field of a result set."
+ ],
+ "sqlite_has_prev": [
+ "bool sqlite_has_prev(resource result)",
+ "* Returns whether a previous row is available."
+ ],
+ "sqlite_key": [
+ "int sqlite_key(resource result)",
+ "Return the current row index of a buffered result."
+ ],
+ "sqlite_last_error": [
+ "int sqlite_last_error(resource db)",
+ "Returns the error code of the last error for a database."
+ ],
+ "sqlite_last_insert_rowid": [
+ "int sqlite_last_insert_rowid(resource db)",
+ "Returns the rowid of the most recently inserted row."
+ ],
+ "sqlite_libencoding": [
+ "string sqlite_libencoding()",
+ "Returns the encoding (iso8859 or UTF-8) of the linked SQLite library."
+ ],
+ "sqlite_libversion": [
+ "string sqlite_libversion()",
+ "Returns the version of the linked SQLite library."
+ ],
+ "sqlite_next": [
+ "bool sqlite_next(resource result)",
+ "Seek to the next row number of a result set."
+ ],
+ "sqlite_num_fields": [
+ "int sqlite_num_fields(resource result)",
+ "Returns the number of fields in a result set."
+ ],
+ "sqlite_num_rows": [
+ "int sqlite_num_rows(resource result)",
+ "Returns the number of rows in a buffered result set."
+ ],
+ "sqlite_open": [
+ "resource sqlite_open(string filename [, int mode [, string &error_message]])",
+ "Opens a SQLite database. Will create the database if it does not exist."
+ ],
+ "sqlite_popen": [
+ "resource sqlite_popen(string filename [, int mode [, string &error_message]])",
+ "Opens a persistent handle to a SQLite database. Will create the database if it does not exist."
+ ],
+ "sqlite_prev": [
+ "bool sqlite_prev(resource result)",
+ "* Seek to the previous row number of a result set."
+ ],
+ "sqlite_query": [
+ "resource sqlite_query(string query, resource db [, int result_type [, string &error_message]])",
+ "Executes a query against a given database and returns a result handle."
+ ],
+ "sqlite_rewind": [
+ "bool sqlite_rewind(resource result)",
+ "Seek to the first row number of a buffered result set."
+ ],
+ "sqlite_seek": [
+ "bool sqlite_seek(resource result, int row)",
+ "Seek to a particular row number of a buffered result set."
+ ],
+ "sqlite_single_query": [
+ "array sqlite_single_query(resource db, string query [, bool first_row_only [, bool decode_binary]])",
+ "Executes a query and returns either an array for one single column or the value of the first row."
+ ],
+ "sqlite_udf_decode_binary": [
+ "string sqlite_udf_decode_binary(string data)",
+ "Decode binary encoding on a string parameter passed to an UDF."
+ ],
+ "sqlite_udf_encode_binary": [
+ "string sqlite_udf_encode_binary(string data)",
+ "Apply binary encoding (if required) to a string to return from an UDF."
+ ],
+ "sqlite_unbuffered_query": [
+ "resource sqlite_unbuffered_query(string query, resource db [ , int result_type [, string &error_message]])",
+ "Executes a query that does not prefetch and buffer all data."
+ ],
+ "sqlite_valid": [
+ "bool sqlite_valid(resource result)",
+ "Returns whether more rows are available."
+ ],
+ "sqrt": [
+ "float sqrt(float number)",
+ "Returns the square root of the number"
+ ],
+ "srand": [
+ "void srand([int seed])",
+ "Seeds random number generator"
+ ],
+ "sscanf": [
+ "mixed sscanf(string str, string format [, string ...])",
+ "Implements an ANSI C compatible sscanf"
+ ],
+ "stat": [
+ "array stat(string filename)",
+ "Give information about a file"
+ ],
+ "str_getcsv": [
+ "array str_getcsv(string input[, string delimiter[, string enclosure[, string escape]]])",
+ "Parse a CSV string into an array"
+ ],
+ "str_ireplace": [
+ "mixed str_ireplace(mixed search, mixed replace, mixed subject [, int &replace_count])",
+ "Replaces all occurrences of search in haystack with replace / case-insensitive"
+ ],
+ "str_pad": [
+ "string str_pad(string input, int pad_length [, string pad_string [, int pad_type]])",
+ "Returns input string padded on the left or right to specified length with pad_string"
+ ],
+ "str_repeat": [
+ "string str_repeat(string input, int mult)",
+ "Returns the input string repeat mult times"
+ ],
+ "str_replace": [
+ "mixed str_replace(mixed search, mixed replace, mixed subject [, int &replace_count])",
+ "Replaces all occurrences of search in haystack with replace"
+ ],
+ "str_rot13": [
+ "string str_rot13(string str)",
+ "Perform the rot13 transform on a string"
+ ],
+ "str_shuffle": [
+ "void str_shuffle(string str)",
+ "Shuffles string. One permutation of all possible is created"
+ ],
+ "str_split": [
+ "array str_split(string str [, int split_length])",
+ "Convert a string to an array. If split_length is specified, break the string down into chunks each split_length characters long."
+ ],
+ "str_word_count": [
+ "mixed str_word_count(string str, [int format [, string charlist]])",
+ "Counts the number of words inside a string. If format of 1 is specified, then the function will return an array containing all the words found inside the string. If format of 2 is specified, then the function will return an associated array where the position of the word is the key and the word itself is the value. For the purpose of this function, 'word' is defined as a locale dependent string containing alphabetic characters, which also may contain, but not start with \"'\" and \"-\" characters."
+ ],
+ "strcasecmp": [
+ "int strcasecmp(string str1, string str2)",
+ "Binary safe case-insensitive string comparison"
+ ],
+ "strchr": [
+ "string strchr(string haystack, string needle)",
+ "An alias for strstr"
+ ],
+ "strcmp": [
+ "int strcmp(string str1, string str2)",
+ "Binary safe string comparison"
+ ],
+ "strcoll": [
+ "int strcoll(string str1, string str2)",
+ "Compares two strings using the current locale"
+ ],
+ "strcspn": [
+ "int strcspn(string str, string mask [, start [, len]])",
+ "Finds length of initial segment consisting entirely of characters not found in mask. If start or/and length is provide works like strcspn(substr($s,$start,$len),$bad_chars)"
+ ],
+ "stream_bucket_append": [
+ "void stream_bucket_append(resource brigade, resource bucket)",
+ "Append bucket to brigade"
+ ],
+ "stream_bucket_make_writeable": [
+ "object stream_bucket_make_writeable(resource brigade)",
+ "Return a bucket object from the brigade for operating on"
+ ],
+ "stream_bucket_new": [
+ "resource stream_bucket_new(resource stream, string buffer)",
+ "Create a new bucket for use on the current stream"
+ ],
+ "stream_bucket_prepend": [
+ "void stream_bucket_prepend(resource brigade, resource bucket)",
+ "Prepend bucket to brigade"
+ ],
+ "stream_context_create": [
+ "resource stream_context_create([array options[, array params]])",
+ "Create a file context and optionally set parameters"
+ ],
+ "stream_context_get_default": [
+ "resource stream_context_get_default([array options])",
+ "Get a handle on the default file/stream context and optionally set parameters"
+ ],
+ "stream_context_get_options": [
+ "array stream_context_get_options(resource context|resource stream)",
+ "Retrieve options for a stream/wrapper/context"
+ ],
+ "stream_context_get_params": [
+ "array stream_context_get_params(resource context|resource stream)",
+ "Get parameters of a file context"
+ ],
+ "stream_context_set_default": [
+ "resource stream_context_set_default(array options)",
+ "Set default file/stream context, returns the context as a resource"
+ ],
+ "stream_context_set_option": [
+ "bool stream_context_set_option(resource context|resource stream, string wrappername, string optionname, mixed value)",
+ "Set an option for a wrapper"
+ ],
+ "stream_context_set_params": [
+ "bool stream_context_set_params(resource context|resource stream, array options)",
+ "Set parameters for a file context"
+ ],
+ "stream_copy_to_stream": [
+ "long stream_copy_to_stream(resource source, resource dest [, long maxlen [, long pos]])",
+ "Reads up to maxlen bytes from source stream and writes them to dest stream."
+ ],
+ "stream_filter_append": [
+ "resource stream_filter_append(resource stream, string filtername[, int read_write[, string filterparams]])",
+ "Append a filter to a stream"
+ ],
+ "stream_filter_prepend": [
+ "resource stream_filter_prepend(resource stream, string filtername[, int read_write[, string filterparams]])",
+ "Prepend a filter to a stream"
+ ],
+ "stream_filter_register": [
+ "bool stream_filter_register(string filtername, string classname)",
+ "Registers a custom filter handler class"
+ ],
+ "stream_filter_remove": [
+ "bool stream_filter_remove(resource stream_filter)",
+ "Flushes any data in the filter's internal buffer, removes it from the chain, and frees the resource"
+ ],
+ "stream_get_contents": [
+ "string stream_get_contents(resource source [, long maxlen [, long offset]])",
+ "Reads all remaining bytes (or up to maxlen bytes) from a stream and returns them as a string."
+ ],
+ "stream_get_filters": [
+ "array stream_get_filters(void)",
+ "Returns a list of registered filters"
+ ],
+ "stream_get_line": [
+ "string stream_get_line(resource stream, int maxlen [, string ending])",
+ "Read up to maxlen bytes from a stream or until the ending string is found"
+ ],
+ "stream_get_meta_data": [
+ "array stream_get_meta_data(resource fp)",
+ "Retrieves header/meta data from streams/file pointers"
+ ],
+ "stream_get_transports": [
+ "array stream_get_transports()",
+ "Retrieves list of registered socket transports"
+ ],
+ "stream_get_wrappers": [
+ "array stream_get_wrappers()",
+ "Retrieves list of registered stream wrappers"
+ ],
+ "stream_is_local": [
+ "bool stream_is_local(resource stream|string url)",
+ ""
+ ],
+ "stream_resolve_include_path": [
+ "string stream_resolve_include_path(string filename)",
+ "Determine what file will be opened by calls to fopen() with a relative path"
+ ],
+ "stream_select": [
+ "int stream_select(array &read_streams, array &write_streams, array &except_streams, int tv_sec[, int tv_usec])",
+ "Runs the select() system call on the sets of streams with a timeout specified by tv_sec and tv_usec"
+ ],
+ "stream_set_blocking": [
+ "bool stream_set_blocking(resource socket, int mode)",
+ "Set blocking/non-blocking mode on a socket or stream"
+ ],
+ "stream_set_timeout": [
+ "bool stream_set_timeout(resource stream, int seconds [, int microseconds])",
+ "Set timeout on stream read to seconds + microseonds"
+ ],
+ "stream_set_write_buffer": [
+ "int stream_set_write_buffer(resource fp, int buffer)",
+ "Set file write buffer"
+ ],
+ "stream_socket_accept": [
+ "resource stream_socket_accept(resource serverstream, [ double timeout [, string &peername ]])",
+ "Accept a client connection from a server socket"
+ ],
+ "stream_socket_client": [
+ "resource stream_socket_client(string remoteaddress [, long &errcode [, string &errstring [, double timeout [, long flags [, resource context]]]]])",
+ "Open a client connection to a remote address"
+ ],
+ "stream_socket_enable_crypto": [
+ "int stream_socket_enable_crypto(resource stream, bool enable [, int cryptokind [, resource sessionstream]])",
+ "Enable or disable a specific kind of crypto on the stream"
+ ],
+ "stream_socket_get_name": [
+ "string stream_socket_get_name(resource stream, bool want_peer)",
+ "Returns either the locally bound or remote name for a socket stream"
+ ],
+ "stream_socket_pair": [
+ "array stream_socket_pair(int domain, int type, int protocol)",
+ "Creates a pair of connected, indistinguishable socket streams"
+ ],
+ "stream_socket_recvfrom": [
+ "string stream_socket_recvfrom(resource stream, long amount [, long flags [, string &remote_addr]])",
+ "Receives data from a socket stream"
+ ],
+ "stream_socket_sendto": [
+ "long stream_socket_sendto(resouce stream, string data [, long flags [, string target_addr]])",
+ "Send data to a socket stream. If target_addr is specified it must be in dotted quad (or [ipv6]) format"
+ ],
+ "stream_socket_server": [
+ "resource stream_socket_server(string localaddress [, long &errcode [, string &errstring [, long flags [, resource context]]]])",
+ "Create a server socket bound to localaddress"
+ ],
+ "stream_socket_shutdown": [
+ "int stream_socket_shutdown(resource stream, int how)",
+ "causes all or part of a full-duplex connection on the socket associated with stream to be shut down. If how is SHUT_RD, further receptions will be disallowed. If how is SHUT_WR, further transmissions will be disallowed. If how is SHUT_RDWR, further receptions and transmissions will be disallowed."
+ ],
+ "stream_supports_lock": [
+ "bool stream_supports_lock(resource stream)",
+ "Tells wether the stream supports locking through flock()."
+ ],
+ "stream_wrapper_register": [
+ "bool stream_wrapper_register(string protocol, string classname[, integer flags])",
+ "Registers a custom URL protocol handler class"
+ ],
+ "stream_wrapper_restore": [
+ "bool stream_wrapper_restore(string protocol)",
+ "Restore the original protocol handler, overriding if necessary"
+ ],
+ "stream_wrapper_unregister": [
+ "bool stream_wrapper_unregister(string protocol)",
+ "Unregister a wrapper for the life of the current request."
+ ],
+ "strftime": [
+ "string strftime(string format [, int timestamp])",
+ "Format a local time/date according to locale settings"
+ ],
+ "strip_tags": [
+ "string strip_tags(string str [, string allowable_tags])",
+ "Strips HTML and PHP tags from a string"
+ ],
+ "stripcslashes": [
+ "string stripcslashes(string str)",
+ "Strips backslashes from a string. Uses C-style conventions"
+ ],
+ "stripos": [
+ "int stripos(string haystack, string needle [, int offset])",
+ "Finds position of first occurrence of a string within another, case insensitive"
+ ],
+ "stripslashes": [
+ "string stripslashes(string str)",
+ "Strips backslashes from a string"
+ ],
+ "stristr": [
+ "string stristr(string haystack, string needle[, bool part])",
+ "Finds first occurrence of a string within another, case insensitive"
+ ],
+ "strlen": [
+ "int strlen(string str)",
+ "Get string length"
+ ],
+ "strnatcasecmp": [
+ "int strnatcasecmp(string s1, string s2)",
+ "Returns the result of case-insensitive string comparison using 'natural' algorithm"
+ ],
+ "strnatcmp": [
+ "int strnatcmp(string s1, string s2)",
+ "Returns the result of string comparison using 'natural' algorithm"
+ ],
+ "strncasecmp": [
+ "int strncasecmp(string str1, string str2, int len)",
+ "Binary safe string comparison"
+ ],
+ "strncmp": [
+ "int strncmp(string str1, string str2, int len)",
+ "Binary safe string comparison"
+ ],
+ "strpbrk": [
+ "array strpbrk(string haystack, string char_list)",
+ "Search a string for any of a set of characters"
+ ],
+ "strpos": [
+ "int strpos(string haystack, string needle [, int offset])",
+ "Finds position of first occurrence of a string within another"
+ ],
+ "strptime": [
+ "string strptime(string timestamp, string format)",
+ "Parse a time/date generated with strftime()"
+ ],
+ "strrchr": [
+ "string strrchr(string haystack, string needle)",
+ "Finds the last occurrence of a character in a string within another"
+ ],
+ "strrev": [
+ "string strrev(string str)",
+ "Reverse a string"
+ ],
+ "strripos": [
+ "int strripos(string haystack, string needle [, int offset])",
+ "Finds position of last occurrence of a string within another string"
+ ],
+ "strrpos": [
+ "int strrpos(string haystack, string needle [, int offset])",
+ "Finds position of last occurrence of a string within another string"
+ ],
+ "strspn": [
+ "int strspn(string str, string mask [, start [, len]])",
+ "Finds length of initial segment consisting entirely of characters found in mask. If start or/and length is provided works like strspn(substr($s,$start,$len),$good_chars)"
+ ],
+ "strstr": [
+ "string strstr(string haystack, string needle[, bool part])",
+ "Finds first occurrence of a string within another"
+ ],
+ "strtok": [
+ "string strtok([string str,] string token)",
+ "Tokenize a string"
+ ],
+ "strtolower": [
+ "string strtolower(string str)",
+ "Makes a string lowercase"
+ ],
+ "strtotime": [
+ "int strtotime(string time [, int now ])",
+ "Convert string representation of date and time to a timestamp"
+ ],
+ "strtoupper": [
+ "string strtoupper(string str)",
+ "Makes a string uppercase"
+ ],
+ "strtr": [
+ "string strtr(string str, string from[, string to])",
+ "Translates characters in str using given translation tables"
+ ],
+ "strval": [
+ "string strval(mixed var)",
+ "Get the string value of a variable"
+ ],
+ "substr": [
+ "string substr(string str, int start [, int length])",
+ "Returns part of a string"
+ ],
+ "substr_compare": [
+ "int substr_compare(string main_str, string str, int offset [, int length [, bool case_sensitivity]])",
+ "Binary safe optionally case insensitive comparison of 2 strings from an offset, up to length characters"
+ ],
+ "substr_count": [
+ "int substr_count(string haystack, string needle [, int offset [, int length]])",
+ "Returns the number of times a substring occurs in the string"
+ ],
+ "substr_replace": [
+ "mixed substr_replace(mixed str, mixed repl, mixed start [, mixed length])",
+ "Replaces part of a string with another string"
+ ],
+ "sybase_affected_rows": [
+ "int sybase_affected_rows([resource link_id])",
+ "Get number of affected rows in last query"
+ ],
+ "sybase_close": [
+ "bool sybase_close([resource link_id])",
+ "Close Sybase connection"
+ ],
+ "sybase_connect": [
+ "int sybase_connect([string host [, string user [, string password [, string charset [, string appname [, bool new]]]]]])",
+ "Open Sybase server connection"
+ ],
+ "sybase_data_seek": [
+ "bool sybase_data_seek(resource result, int offset)",
+ "Move internal row pointer"
+ ],
+ "sybase_deadlock_retry_count": [
+ "void sybase_deadlock_retry_count(int retry_count)",
+ "Sets deadlock retry count"
+ ],
+ "sybase_fetch_array": [
+ "array sybase_fetch_array(resource result)",
+ "Fetch row as array"
+ ],
+ "sybase_fetch_assoc": [
+ "array sybase_fetch_assoc(resource result)",
+ "Fetch row as array without numberic indices"
+ ],
+ "sybase_fetch_field": [
+ "object sybase_fetch_field(resource result [, int offset])",
+ "Get field information"
+ ],
+ "sybase_fetch_object": [
+ "object sybase_fetch_object(resource result [, mixed object])",
+ "Fetch row as object"
+ ],
+ "sybase_fetch_row": [
+ "array sybase_fetch_row(resource result)",
+ "Get row as enumerated array"
+ ],
+ "sybase_field_seek": [
+ "bool sybase_field_seek(resource result, int offset)",
+ "Set field offset"
+ ],
+ "sybase_free_result": [
+ "bool sybase_free_result(resource result)",
+ "Free result memory"
+ ],
+ "sybase_get_last_message": [
+ "string sybase_get_last_message(void)",
+ "Returns the last message from server (over min_message_severity)"
+ ],
+ "sybase_min_client_severity": [
+ "void sybase_min_client_severity(int severity)",
+ "Sets minimum client severity"
+ ],
+ "sybase_min_server_severity": [
+ "void sybase_min_server_severity(int severity)",
+ "Sets minimum server severity"
+ ],
+ "sybase_num_fields": [
+ "int sybase_num_fields(resource result)",
+ "Get number of fields in result"
+ ],
+ "sybase_num_rows": [
+ "int sybase_num_rows(resource result)",
+ "Get number of rows in result"
+ ],
+ "sybase_pconnect": [
+ "int sybase_pconnect([string host [, string user [, string password [, string charset [, string appname]]]]])",
+ "Open persistent Sybase connection"
+ ],
+ "sybase_query": [
+ "int sybase_query(string query [, resource link_id])",
+ "Send Sybase query"
+ ],
+ "sybase_result": [
+ "string sybase_result(resource result, int row, mixed field)",
+ "Get result data"
+ ],
+ "sybase_select_db": [
+ "bool sybase_select_db(string database [, resource link_id])",
+ "Select Sybase database"
+ ],
+ "sybase_set_message_handler": [
+ "bool sybase_set_message_handler(mixed error_func [, resource connection])",
+ "Set the error handler, to be called when a server message is raised. If error_func is NULL the handler will be deleted"
+ ],
+ "sybase_unbuffered_query": [
+ "int sybase_unbuffered_query(string query [, resource link_id])",
+ "Send Sybase query"
+ ],
+ "symlink": [
+ "int symlink(string target, string link)",
+ "Create a symbolic link"
+ ],
+ "sys_get_temp_dir": [
+ "string sys_get_temp_dir()",
+ "Returns directory path used for temporary files"
+ ],
+ "sys_getloadavg": [
+ "array sys_getloadavg()",
+ ""
+ ],
+ "syslog": [
+ "bool syslog(int priority, string message)",
+ "Generate a system log message"
+ ],
+ "system": [
+ "int system(string command [, int &return_value])",
+ "Execute an external program and display output"
+ ],
+ "tan": [
+ "float tan(float number)",
+ "Returns the tangent of the number in radians"
+ ],
+ "tanh": [
+ "float tanh(float number)",
+ "Returns the hyperbolic tangent of the number, defined as sinh(number)/cosh(number)"
+ ],
+ "tempnam": [
+ "string tempnam(string dir, string prefix)",
+ "Create a unique filename in a directory"
+ ],
+ "textdomain": [
+ "string textdomain(string domain)",
+ "Set the textdomain to \"domain\". Returns the current domain"
+ ],
+ "tidy_access_count": [
+ "int tidy_access_count()",
+ "Returns the Number of Tidy accessibility warnings encountered for specified document."
+ ],
+ "tidy_clean_repair": [
+ "boolean tidy_clean_repair()",
+ "Execute configured cleanup and repair operations on parsed markup"
+ ],
+ "tidy_config_count": [
+ "int tidy_config_count()",
+ "Returns the Number of Tidy configuration errors encountered for specified document."
+ ],
+ "tidy_diagnose": [
+ "boolean tidy_diagnose()",
+ "Run configured diagnostics on parsed and repaired markup."
+ ],
+ "tidy_error_count": [
+ "int tidy_error_count()",
+ "Returns the Number of Tidy errors encountered for specified document."
+ ],
+ "tidy_get_body": [
+ "TidyNode tidy_get_body(resource tidy)",
+ "Returns a TidyNode Object starting from the <BODY> tag of the tidy parse tree"
+ ],
+ "tidy_get_config": [
+ "array tidy_get_config()",
+ "Get current Tidy configuarion"
+ ],
+ "tidy_get_error_buffer": [
+ "string tidy_get_error_buffer([boolean detailed])",
+ "Return warnings and errors which occured parsing the specified document"
+ ],
+ "tidy_get_head": [
+ "TidyNode tidy_get_head()",
+ "Returns a TidyNode Object starting from the <HEAD> tag of the tidy parse tree"
+ ],
+ "tidy_get_html": [
+ "TidyNode tidy_get_html()",
+ "Returns a TidyNode Object starting from the <HTML> tag of the tidy parse tree"
+ ],
+ "tidy_get_html_ver": [
+ "int tidy_get_html_ver()",
+ "Get the Detected HTML version for the specified document."
+ ],
+ "tidy_get_opt_doc": [
+ "string tidy_get_opt_doc(tidy resource, string optname)",
+ "Returns the documentation for the given option name"
+ ],
+ "tidy_get_output": [
+ "string tidy_get_output()",
+ "Return a string representing the parsed tidy markup"
+ ],
+ "tidy_get_release": [
+ "string tidy_get_release()",
+ "Get release date (version) for Tidy library"
+ ],
+ "tidy_get_root": [
+ "TidyNode tidy_get_root()",
+ "Returns a TidyNode Object representing the root of the tidy parse tree"
+ ],
+ "tidy_get_status": [
+ "int tidy_get_status()",
+ "Get status of specfied document."
+ ],
+ "tidy_getopt": [
+ "mixed tidy_getopt(string option)",
+ "Returns the value of the specified configuration option for the tidy document."
+ ],
+ "tidy_is_xhtml": [
+ "boolean tidy_is_xhtml()",
+ "Indicates if the document is a XHTML document."
+ ],
+ "tidy_is_xml": [
+ "boolean tidy_is_xml()",
+ "Indicates if the document is a generic (non HTML/XHTML) XML document."
+ ],
+ "tidy_parse_file": [
+ "boolean tidy_parse_file(string file [, mixed config_options [, string encoding [, bool use_include_path]]])",
+ "Parse markup in file or URI"
+ ],
+ "tidy_parse_string": [
+ "bool tidy_parse_string(string input [, mixed config_options [, string encoding]])",
+ "Parse a document stored in a string"
+ ],
+ "tidy_repair_file": [
+ "boolean tidy_repair_file(string filename [, mixed config_file [, string encoding [, bool use_include_path]]])",
+ "Repair a file using an optionally provided configuration file"
+ ],
+ "tidy_repair_string": [
+ "boolean tidy_repair_string(string data [, mixed config_file [, string encoding]])",
+ "Repair a string using an optionally provided configuration file"
+ ],
+ "tidy_warning_count": [
+ "int tidy_warning_count()",
+ "Returns the Number of Tidy warnings encountered for specified document."
+ ],
+ "time": [
+ "int time(void)",
+ "Return current UNIX timestamp"
+ ],
+ "time_nanosleep": [
+ "mixed time_nanosleep(long seconds, long nanoseconds)",
+ "Delay for a number of seconds and nano seconds"
+ ],
+ "time_sleep_until": [
+ "mixed time_sleep_until(float timestamp)",
+ "Make the script sleep until the specified time"
+ ],
+ "timezone_abbreviations_list": [
+ "array timezone_abbreviations_list()",
+ "Returns associative array containing dst, offset and the timezone name"
+ ],
+ "timezone_identifiers_list": [
+ "array timezone_identifiers_list([long what[, string country]])",
+ "Returns numerically index array with all timezone identifiers."
+ ],
+ "timezone_location_get": [
+ "array timezone_location_get()",
+ "Returns location information for a timezone, including country code, latitude/longitude and comments"
+ ],
+ "timezone_name_from_abbr": [
+ "string timezone_name_from_abbr(string abbr[, long gmtOffset[, long isdst]])",
+ "Returns the timezone name from abbrevation"
+ ],
+ "timezone_name_get": [
+ "string timezone_name_get(DateTimeZone object)",
+ "Returns the name of the timezone."
+ ],
+ "timezone_offset_get": [
+ "long timezone_offset_get(DateTimeZone object, DateTime object)",
+ "Returns the timezone offset."
+ ],
+ "timezone_open": [
+ "DateTimeZone timezone_open(string timezone)",
+ "Returns new DateTimeZone object"
+ ],
+ "timezone_transitions_get": [
+ "array timezone_transitions_get(DateTimeZone object [, long timestamp_begin [, long timestamp_end ]])",
+ "Returns numerically indexed array containing associative array for all transitions in the specified range for the timezone."
+ ],
+ "timezone_version_get": [
+ "array timezone_version_get()",
+ "Returns the Olson database version number."
+ ],
+ "tmpfile": [
+ "resource tmpfile(void)",
+ "Create a temporary file that will be deleted automatically after use"
+ ],
+ "token_get_all": [
+ "array token_get_all(string source)",
+ ""
+ ],
+ "token_name": [
+ "string token_name(int type)",
+ ""
+ ],
+ "touch": [
+ "bool touch(string filename [, int time [, int atime]])",
+ "Set modification time of file"
+ ],
+ "trigger_error": [
+ "void trigger_error(string messsage [, int error_type])",
+ "Generates a user-level error/warning/notice message"
+ ],
+ "trim": [
+ "string trim(string str [, string character_mask])",
+ "Strips whitespace from the beginning and end of a string"
+ ],
+ "uasort": [
+ "bool uasort(array array_arg, string cmp_function)",
+ "Sort an array with a user-defined comparison function and maintain index association"
+ ],
+ "ucfirst": [
+ "string ucfirst(string str)",
+ "Make a string's first character lowercase"
+ ],
+ "ucwords": [
+ "string ucwords(string str)",
+ "Uppercase the first character of every word in a string"
+ ],
+ "uksort": [
+ "bool uksort(array array_arg, string cmp_function)",
+ "Sort an array by keys using a user-defined comparison function"
+ ],
+ "umask": [
+ "int umask([int mask])",
+ "Return or change the umask"
+ ],
+ "uniqid": [
+ "string uniqid([string prefix [, bool more_entropy]])",
+ "Generates a unique ID"
+ ],
+ "unixtojd": [
+ "int unixtojd([int timestamp])",
+ "Convert UNIX timestamp to Julian Day"
+ ],
+ "unlink": [
+ "bool unlink(string filename[, context context])",
+ "Delete a file"
+ ],
+ "unpack": [
+ "array unpack(string format, string input)",
+ "Unpack binary string into named array elements according to format argument"
+ ],
+ "unregister_tick_function": [
+ "void unregister_tick_function(string function_name)",
+ "Unregisters a tick callback function"
+ ],
+ "unserialize": [
+ "mixed unserialize(string variable_representation)",
+ "Takes a string representation of variable and recreates it"
+ ],
+ "unset": [
+ "void unset (mixed var [, mixed var])",
+ "Unset a given variable"
+ ],
+ "urldecode": [
+ "string urldecode(string str)",
+ "Decodes URL-encoded string"
+ ],
+ "urlencode": [
+ "string urlencode(string str)",
+ "URL-encodes string"
+ ],
+ "usleep": [
+ "void usleep(int micro_seconds)",
+ "Delay for a given number of micro seconds"
+ ],
+ "usort": [
+ "bool usort(array array_arg, string cmp_function)",
+ "Sort an array by values using a user-defined comparison function"
+ ],
+ "utf8_decode": [
+ "string utf8_decode(string data)",
+ "Converts a UTF-8 encoded string to ISO-8859-1"
+ ],
+ "utf8_encode": [
+ "string utf8_encode(string data)",
+ "Encodes an ISO-8859-1 string to UTF-8"
+ ],
+ "var_dump": [
+ "void var_dump(mixed var)",
+ "Dumps a string representation of variable to output"
+ ],
+ "var_export": [
+ "mixed var_export(mixed var [, bool return])",
+ "Outputs or returns a string representation of a variable"
+ ],
+ "variant_abs": [
+ "mixed variant_abs(mixed left)",
+ "Returns the absolute value of a variant"
+ ],
+ "variant_add": [
+ "mixed variant_add(mixed left, mixed right)",
+ "\"Adds\" two variant values together and returns the result"
+ ],
+ "variant_and": [
+ "mixed variant_and(mixed left, mixed right)",
+ "performs a bitwise AND operation between two variants and returns the result"
+ ],
+ "variant_cast": [
+ "object variant_cast(object variant, int type)",
+ "Convert a variant into a new variant object of another type"
+ ],
+ "variant_cat": [
+ "mixed variant_cat(mixed left, mixed right)",
+ "concatenates two variant values together and returns the result"
+ ],
+ "variant_cmp": [
+ "int variant_cmp(mixed left, mixed right [, int lcid [, int flags]])",
+ "Compares two variants"
+ ],
+ "variant_date_from_timestamp": [
+ "object variant_date_from_timestamp(int timestamp)",
+ "Returns a variant date representation of a unix timestamp"
+ ],
+ "variant_date_to_timestamp": [
+ "int variant_date_to_timestamp(object variant)",
+ "Converts a variant date/time value to unix timestamp"
+ ],
+ "variant_div": [
+ "mixed variant_div(mixed left, mixed right)",
+ "Returns the result from dividing two variants"
+ ],
+ "variant_eqv": [
+ "mixed variant_eqv(mixed left, mixed right)",
+ "Performs a bitwise equivalence on two variants"
+ ],
+ "variant_fix": [
+ "mixed variant_fix(mixed left)",
+ "Returns the integer part ? of a variant"
+ ],
+ "variant_get_type": [
+ "int variant_get_type(object variant)",
+ "Returns the VT_XXX type code for a variant"
+ ],
+ "variant_idiv": [
+ "mixed variant_idiv(mixed left, mixed right)",
+ "Converts variants to integers and then returns the result from dividing them"
+ ],
+ "variant_imp": [
+ "mixed variant_imp(mixed left, mixed right)",
+ "Performs a bitwise implication on two variants"
+ ],
+ "variant_int": [
+ "mixed variant_int(mixed left)",
+ "Returns the integer portion of a variant"
+ ],
+ "variant_mod": [
+ "mixed variant_mod(mixed left, mixed right)",
+ "Divides two variants and returns only the remainder"
+ ],
+ "variant_mul": [
+ "mixed variant_mul(mixed left, mixed right)",
+ "multiplies the values of the two variants and returns the result"
+ ],
+ "variant_neg": [
+ "mixed variant_neg(mixed left)",
+ "Performs logical negation on a variant"
+ ],
+ "variant_not": [
+ "mixed variant_not(mixed left)",
+ "Performs bitwise not negation on a variant"
+ ],
+ "variant_or": [
+ "mixed variant_or(mixed left, mixed right)",
+ "Performs a logical disjunction on two variants"
+ ],
+ "variant_pow": [
+ "mixed variant_pow(mixed left, mixed right)",
+ "Returns the result of performing the power function with two variants"
+ ],
+ "variant_round": [
+ "mixed variant_round(mixed left, int decimals)",
+ "Rounds a variant to the specified number of decimal places"
+ ],
+ "variant_set": [
+ "void variant_set(object variant, mixed value)",
+ "Assigns a new value for a variant object"
+ ],
+ "variant_set_type": [
+ "void variant_set_type(object variant, int type)",
+ "Convert a variant into another type. Variant is modified \"in-place\""
+ ],
+ "variant_sub": [
+ "mixed variant_sub(mixed left, mixed right)",
+ "subtracts the value of the right variant from the left variant value and returns the result"
+ ],
+ "variant_xor": [
+ "mixed variant_xor(mixed left, mixed right)",
+ "Performs a logical exclusion on two variants"
+ ],
+ "version_compare": [
+ "int version_compare(string ver1, string ver2 [, string oper])",
+ "Compares two \"PHP-standardized\" version number strings"
+ ],
+ "vfprintf": [
+ "int vfprintf(resource stream, string format, array args)",
+ "Output a formatted string into a stream"
+ ],
+ "virtual": [
+ "bool virtual(string filename)",
+ "Perform an Apache sub-request"
+ ],
+ "vprintf": [
+ "int vprintf(string format, array args)",
+ "Output a formatted string"
+ ],
+ "vsprintf": [
+ "string vsprintf(string format, array args)",
+ "Return a formatted string"
+ ],
+ "wddx_add_vars": [
+ "int wddx_add_vars(resource packet_id, mixed var_names [, mixed ...])",
+ "Serializes given variables and adds them to packet given by packet_id"
+ ],
+ "wddx_deserialize": [
+ "mixed wddx_deserialize(mixed packet)",
+ "Deserializes given packet and returns a PHP value"
+ ],
+ "wddx_packet_end": [
+ "string wddx_packet_end(resource packet_id)",
+ "Ends specified WDDX packet and returns the string containing the packet"
+ ],
+ "wddx_packet_start": [
+ "resource wddx_packet_start([string comment])",
+ "Starts a WDDX packet with optional comment and returns the packet id"
+ ],
+ "wddx_serialize_value": [
+ "string wddx_serialize_value(mixed var [, string comment])",
+ "Creates a new packet and serializes the given value"
+ ],
+ "wddx_serialize_vars": [
+ "string wddx_serialize_vars(mixed var_name [, mixed ...])",
+ "Creates a new packet and serializes given variables into a struct"
+ ],
+ "wordwrap": [
+ "string wordwrap(string str [, int width [, string break [, boolean cut]]])",
+ "Wraps buffer to selected number of characters using string break char"
+ ],
+ "xml_error_string": [
+ "string xml_error_string(int code)",
+ "Get XML parser error string"
+ ],
+ "xml_get_current_byte_index": [
+ "int xml_get_current_byte_index(resource parser)",
+ "Get current byte index for an XML parser"
+ ],
+ "xml_get_current_column_number": [
+ "int xml_get_current_column_number(resource parser)",
+ "Get current column number for an XML parser"
+ ],
+ "xml_get_current_line_number": [
+ "int xml_get_current_line_number(resource parser)",
+ "Get current line number for an XML parser"
+ ],
+ "xml_get_error_code": [
+ "int xml_get_error_code(resource parser)",
+ "Get XML parser error code"
+ ],
+ "xml_parse": [
+ "int xml_parse(resource parser, string data [, int isFinal])",
+ "Start parsing an XML document"
+ ],
+ "xml_parse_into_struct": [
+ "int xml_parse_into_struct(resource parser, string data, array &values [, array &index ])",
+ "Parsing a XML document"
+ ],
+ "xml_parser_create": [
+ "resource xml_parser_create([string encoding])",
+ "Create an XML parser"
+ ],
+ "xml_parser_create_ns": [
+ "resource xml_parser_create_ns([string encoding [, string sep]])",
+ "Create an XML parser"
+ ],
+ "xml_parser_free": [
+ "int xml_parser_free(resource parser)",
+ "Free an XML parser"
+ ],
+ "xml_parser_get_option": [
+ "int xml_parser_get_option(resource parser, int option)",
+ "Get options from an XML parser"
+ ],
+ "xml_parser_set_option": [
+ "int xml_parser_set_option(resource parser, int option, mixed value)",
+ "Set options in an XML parser"
+ ],
+ "xml_set_character_data_handler": [
+ "int xml_set_character_data_handler(resource parser, string hdl)",
+ "Set up character data handler"
+ ],
+ "xml_set_default_handler": [
+ "int xml_set_default_handler(resource parser, string hdl)",
+ "Set up default handler"
+ ],
+ "xml_set_element_handler": [
+ "int xml_set_element_handler(resource parser, string shdl, string ehdl)",
+ "Set up start and end element handlers"
+ ],
+ "xml_set_end_namespace_decl_handler": [
+ "int xml_set_end_namespace_decl_handler(resource parser, string hdl)",
+ "Set up character data handler"
+ ],
+ "xml_set_external_entity_ref_handler": [
+ "int xml_set_external_entity_ref_handler(resource parser, string hdl)",
+ "Set up external entity reference handler"
+ ],
+ "xml_set_notation_decl_handler": [
+ "int xml_set_notation_decl_handler(resource parser, string hdl)",
+ "Set up notation declaration handler"
+ ],
+ "xml_set_object": [
+ "int xml_set_object(resource parser, object &obj)",
+ "Set up object which should be used for callbacks"
+ ],
+ "xml_set_processing_instruction_handler": [
+ "int xml_set_processing_instruction_handler(resource parser, string hdl)",
+ "Set up processing instruction (PI) handler"
+ ],
+ "xml_set_start_namespace_decl_handler": [
+ "int xml_set_start_namespace_decl_handler(resource parser, string hdl)",
+ "Set up character data handler"
+ ],
+ "xml_set_unparsed_entity_decl_handler": [
+ "int xml_set_unparsed_entity_decl_handler(resource parser, string hdl)",
+ "Set up unparsed entity declaration handler"
+ ],
+ "xmlrpc_decode": [
+ "array xmlrpc_decode(string xml [, string encoding])",
+ "Decodes XML into native PHP types"
+ ],
+ "xmlrpc_decode_request": [
+ "array xmlrpc_decode_request(string xml, string& method [, string encoding])",
+ "Decodes XML into native PHP types"
+ ],
+ "xmlrpc_encode": [
+ "string xmlrpc_encode(mixed value)",
+ "Generates XML for a PHP value"
+ ],
+ "xmlrpc_encode_request": [
+ "string xmlrpc_encode_request(string method, mixed params [, array output_options])",
+ "Generates XML for a method request"
+ ],
+ "xmlrpc_get_type": [
+ "string xmlrpc_get_type(mixed value)",
+ "Gets xmlrpc type for a PHP value. Especially useful for base64 and datetime strings"
+ ],
+ "xmlrpc_is_fault": [
+ "bool xmlrpc_is_fault(array)",
+ "Determines if an array value represents an XMLRPC fault."
+ ],
+ "xmlrpc_parse_method_descriptions": [
+ "array xmlrpc_parse_method_descriptions(string xml)",
+ "Decodes XML into a list of method descriptions"
+ ],
+ "xmlrpc_server_add_introspection_data": [
+ "int xmlrpc_server_add_introspection_data(resource server, array desc)",
+ "Adds introspection documentation"
+ ],
+ "xmlrpc_server_call_method": [
+ "mixed xmlrpc_server_call_method(resource server, string xml, mixed user_data [, array output_options])",
+ "Parses XML requests and call methods"
+ ],
+ "xmlrpc_server_create": [
+ "resource xmlrpc_server_create(void)",
+ "Creates an xmlrpc server"
+ ],
+ "xmlrpc_server_destroy": [
+ "int xmlrpc_server_destroy(resource server)",
+ "Destroys server resources"
+ ],
+ "xmlrpc_server_register_introspection_callback": [
+ "bool xmlrpc_server_register_introspection_callback(resource server, string function)",
+ "Register a PHP function to generate documentation"
+ ],
+ "xmlrpc_server_register_method": [
+ "bool xmlrpc_server_register_method(resource server, string method_name, string function)",
+ "Register a PHP function to handle method matching method_name"
+ ],
+ "xmlrpc_set_type": [
+ "bool xmlrpc_set_type(string value, string type)",
+ "Sets xmlrpc type, base64 or datetime, for a PHP string value"
+ ],
+ "xmlwriter_end_attribute": [
+ "bool xmlwriter_end_attribute(resource xmlwriter)",
+ "End attribute - returns FALSE on error"
+ ],
+ "xmlwriter_end_cdata": [
+ "bool xmlwriter_end_cdata(resource xmlwriter)",
+ "End current CDATA - returns FALSE on error"
+ ],
+ "xmlwriter_end_comment": [
+ "bool xmlwriter_end_comment(resource xmlwriter)",
+ "Create end comment - returns FALSE on error"
+ ],
+ "xmlwriter_end_document": [
+ "bool xmlwriter_end_document(resource xmlwriter)",
+ "End current document - returns FALSE on error"
+ ],
+ "xmlwriter_end_dtd": [
+ "bool xmlwriter_end_dtd(resource xmlwriter)",
+ "End current DTD - returns FALSE on error"
+ ],
+ "xmlwriter_end_dtd_attlist": [
+ "bool xmlwriter_end_dtd_attlist(resource xmlwriter)",
+ "End current DTD AttList - returns FALSE on error"
+ ],
+ "xmlwriter_end_dtd_element": [
+ "bool xmlwriter_end_dtd_element(resource xmlwriter)",
+ "End current DTD element - returns FALSE on error"
+ ],
+ "xmlwriter_end_dtd_entity": [
+ "bool xmlwriter_end_dtd_entity(resource xmlwriter)",
+ "End current DTD Entity - returns FALSE on error"
+ ],
+ "xmlwriter_end_element": [
+ "bool xmlwriter_end_element(resource xmlwriter)",
+ "End current element - returns FALSE on error"
+ ],
+ "xmlwriter_end_pi": [
+ "bool xmlwriter_end_pi(resource xmlwriter)",
+ "End current PI - returns FALSE on error"
+ ],
+ "xmlwriter_flush": [
+ "mixed xmlwriter_flush(resource xmlwriter [,bool empty])",
+ "Output current buffer"
+ ],
+ "xmlwriter_full_end_element": [
+ "bool xmlwriter_full_end_element(resource xmlwriter)",
+ "End current element - returns FALSE on error"
+ ],
+ "xmlwriter_open_memory": [
+ "resource xmlwriter_open_memory()",
+ "Create new xmlwriter using memory for string output"
+ ],
+ "xmlwriter_open_uri": [
+ "resource xmlwriter_open_uri(resource xmlwriter, string source)",
+ "Create new xmlwriter using source uri for output"
+ ],
+ "xmlwriter_output_memory": [
+ "string xmlwriter_output_memory(resource xmlwriter [,bool flush])",
+ "Output current buffer as string"
+ ],
+ "xmlwriter_set_indent": [
+ "bool xmlwriter_set_indent(resource xmlwriter, bool indent)",
+ "Toggle indentation on/off - returns FALSE on error"
+ ],
+ "xmlwriter_set_indent_string": [
+ "bool xmlwriter_set_indent_string(resource xmlwriter, string indentString)",
+ "Set string used for indenting - returns FALSE on error"
+ ],
+ "xmlwriter_start_attribute": [
+ "bool xmlwriter_start_attribute(resource xmlwriter, string name)",
+ "Create start attribute - returns FALSE on error"
+ ],
+ "xmlwriter_start_attribute_ns": [
+ "bool xmlwriter_start_attribute_ns(resource xmlwriter, string prefix, string name, string uri)",
+ "Create start namespaced attribute - returns FALSE on error"
+ ],
+ "xmlwriter_start_cdata": [
+ "bool xmlwriter_start_cdata(resource xmlwriter)",
+ "Create start CDATA tag - returns FALSE on error"
+ ],
+ "xmlwriter_start_comment": [
+ "bool xmlwriter_start_comment(resource xmlwriter)",
+ "Create start comment - returns FALSE on error"
+ ],
+ "xmlwriter_start_document": [
+ "bool xmlwriter_start_document(resource xmlwriter, string version, string encoding, string standalone)",
+ "Create document tag - returns FALSE on error"
+ ],
+ "xmlwriter_start_dtd": [
+ "bool xmlwriter_start_dtd(resource xmlwriter, string name, string pubid, string sysid)",
+ "Create start DTD tag - returns FALSE on error"
+ ],
+ "xmlwriter_start_dtd_attlist": [
+ "bool xmlwriter_start_dtd_attlist(resource xmlwriter, string name)",
+ "Create start DTD AttList - returns FALSE on error"
+ ],
+ "xmlwriter_start_dtd_element": [
+ "bool xmlwriter_start_dtd_element(resource xmlwriter, string name)",
+ "Create start DTD element - returns FALSE on error"
+ ],
+ "xmlwriter_start_dtd_entity": [
+ "bool xmlwriter_start_dtd_entity(resource xmlwriter, string name, bool isparam)",
+ "Create start DTD Entity - returns FALSE on error"
+ ],
+ "xmlwriter_start_element": [
+ "bool xmlwriter_start_element(resource xmlwriter, string name)",
+ "Create start element tag - returns FALSE on error"
+ ],
+ "xmlwriter_start_element_ns": [
+ "bool xmlwriter_start_element_ns(resource xmlwriter, string prefix, string name, string uri)",
+ "Create start namespaced element tag - returns FALSE on error"
+ ],
+ "xmlwriter_start_pi": [
+ "bool xmlwriter_start_pi(resource xmlwriter, string target)",
+ "Create start PI tag - returns FALSE on error"
+ ],
+ "xmlwriter_text": [
+ "bool xmlwriter_text(resource xmlwriter, string content)",
+ "Write text - returns FALSE on error"
+ ],
+ "xmlwriter_write_attribute": [
+ "bool xmlwriter_write_attribute(resource xmlwriter, string name, string content)",
+ "Write full attribute - returns FALSE on error"
+ ],
+ "xmlwriter_write_attribute_ns": [
+ "bool xmlwriter_write_attribute_ns(resource xmlwriter, string prefix, string name, string uri, string content)",
+ "Write full namespaced attribute - returns FALSE on error"
+ ],
+ "xmlwriter_write_cdata": [
+ "bool xmlwriter_write_cdata(resource xmlwriter, string content)",
+ "Write full CDATA tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_comment": [
+ "bool xmlwriter_write_comment(resource xmlwriter, string content)",
+ "Write full comment tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_dtd": [
+ "bool xmlwriter_write_dtd(resource xmlwriter, string name, string pubid, string sysid, string subset)",
+ "Write full DTD tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_dtd_attlist": [
+ "bool xmlwriter_write_dtd_attlist(resource xmlwriter, string name, string content)",
+ "Write full DTD AttList tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_dtd_element": [
+ "bool xmlwriter_write_dtd_element(resource xmlwriter, string name, string content)",
+ "Write full DTD element tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_dtd_entity": [
+ "bool xmlwriter_write_dtd_entity(resource xmlwriter, string name, string content [, int pe [, string pubid [, string sysid [, string ndataid]]]])",
+ "Write full DTD Entity tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_element": [
+ "bool xmlwriter_write_element(resource xmlwriter, string name[, string content])",
+ "Write full element tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_element_ns": [
+ "bool xmlwriter_write_element_ns(resource xmlwriter, string prefix, string name, string uri[, string content])",
+ "Write full namesapced element tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_pi": [
+ "bool xmlwriter_write_pi(resource xmlwriter, string target, string content)",
+ "Write full PI tag - returns FALSE on error"
+ ],
+ "xmlwriter_write_raw": [
+ "bool xmlwriter_write_raw(resource xmlwriter, string content)",
+ "Write text - returns FALSE on error"
+ ],
+ "xsl_xsltprocessor_get_parameter": [
+ "string xsl_xsltprocessor_get_parameter(string namespace, string name);",
+ ""
+ ],
+ "xsl_xsltprocessor_has_exslt_support": [
+ "bool xsl_xsltprocessor_has_exslt_support();",
+ ""
+ ],
+ "xsl_xsltprocessor_import_stylesheet": [
+ "void xsl_xsltprocessor_import_stylesheet(domdocument doc);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html# Since:"
+ ],
+ "xsl_xsltprocessor_register_php_functions": [
+ "void xsl_xsltprocessor_register_php_functions([mixed $restrict]);",
+ ""
+ ],
+ "xsl_xsltprocessor_remove_parameter": [
+ "bool xsl_xsltprocessor_remove_parameter(string namespace, string name);",
+ ""
+ ],
+ "xsl_xsltprocessor_set_parameter": [
+ "bool xsl_xsltprocessor_set_parameter(string namespace, mixed name [, string value]);",
+ ""
+ ],
+ "xsl_xsltprocessor_set_profiling": [
+ "bool xsl_xsltprocessor_set_profiling(string filename) */",
+ "PHP_FUNCTION(xsl_xsltprocessor_set_profiling) { zval *id; xsl_object *intern; char *filename = NULL; int filename_len; DOM_GET_THIS(id); if (zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC, \"s!\", &filename, &filename_len) == SUCCESS) { intern = (xsl_object *)zend_object_store_get_object(id TSRMLS_CC); if (intern->profiling) { efree(intern->profiling); } if (filename != NULL) { intern->profiling = estrndup(filename,filename_len); } else { intern->profiling = NULL; } RETURN_TRUE; } else { WRONG_PARAM_COUNT; } } /* }}} end xsl_xsltprocessor_set_profiling"
+ ],
+ "xsl_xsltprocessor_transform_to_doc": [
+ "domdocument xsl_xsltprocessor_transform_to_doc(domnode doc);",
+ "URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html# Since:"
+ ],
+ "xsl_xsltprocessor_transform_to_uri": [
+ "int xsl_xsltprocessor_transform_to_uri(domdocument doc, string uri);",
+ ""
+ ],
+ "xsl_xsltprocessor_transform_to_xml": [
+ "string xsl_xsltprocessor_transform_to_xml(domdocument doc);",
+ ""
+ ],
+ "zend_logo_guid": [
+ "string zend_logo_guid(void)",
+ "Return the special ID used to request the Zend logo in phpinfo screens"
+ ],
+ "zend_version": [
+ "string zend_version(void)",
+ "Get the version of the Zend Engine"
+ ],
+ "zip_close": [
+ "void zip_close(resource zip)",
+ "Close a Zip archive"
+ ],
+ "zip_entry_close": [
+ "void zip_entry_close(resource zip_ent)",
+ "Close a zip entry"
+ ],
+ "zip_entry_compressedsize": [
+ "int zip_entry_compressedsize(resource zip_entry)",
+ "Return the compressed size of a ZZip entry"
+ ],
+ "zip_entry_compressionmethod": [
+ "string zip_entry_compressionmethod(resource zip_entry)",
+ "Return a string containing the compression method used on a particular entry"
+ ],
+ "zip_entry_filesize": [
+ "int zip_entry_filesize(resource zip_entry)",
+ "Return the actual filesize of a ZZip entry"
+ ],
+ "zip_entry_name": [
+ "string zip_entry_name(resource zip_entry)",
+ "Return the name given a ZZip entry"
+ ],
+ "zip_entry_open": [
+ "bool zip_entry_open(resource zip_dp, resource zip_entry [, string mode])",
+ "Open a Zip File, pointed by the resource entry"
+ ],
+ "zip_entry_read": [
+ "mixed zip_entry_read(resource zip_entry [, int len])",
+ "Read from an open directory entry"
+ ],
+ "zip_open": [
+ "resource zip_open(string filename)",
+ "Create new zip using source uri for output"
+ ],
+ "zip_read": [
+ "resource zip_read(resource zip)",
+ "Returns the next file in the archive"
+ ],
+ "zlib_get_coding_type": [
+ "string zlib_get_coding_type(void)",
+ "Returns the coding type used for output compression"
+ ]
+};
+
+var variableMap = {
+ "$_COOKIE": {
+ type: "array"
+ },
+ "$_ENV": {
+ type: "array"
+ },
+ "$_FILES": {
+ type: "array"
+ },
+ "$_GET": {
+ type: "array"
+ },
+ "$_POST": {
+ type: "array"
+ },
+ "$_REQUEST": {
+ type: "array"
+ },
+ "$_SERVER": {
+ type: "array",
+ value: {
+ "DOCUMENT_ROOT": 1,
+ "GATEWAY_INTERFACE": 1,
+ "HTTP_ACCEPT": 1,
+ "HTTP_ACCEPT_CHARSET": 1,
+ "HTTP_ACCEPT_ENCODING": 1 ,
+ "HTTP_ACCEPT_LANGUAGE": 1,
+ "HTTP_CONNECTION": 1,
+ "HTTP_HOST": 1,
+ "HTTP_REFERER": 1,
+ "HTTP_USER_AGENT": 1,
+ "PATH_TRANSLATED": 1,
+ "PHP_SELF": 1,
+ "QUERY_STRING": 1,
+ "REMOTE_ADDR": 1,
+ "REMOTE_PORT": 1,
+ "REQUEST_METHOD": 1,
+ "REQUEST_URI": 1,
+ "SCRIPT_FILENAME": 1,
+ "SCRIPT_NAME": 1,
+ "SERVER_ADMIN": 1,
+ "SERVER_NAME": 1,
+ "SERVER_PORT": 1,
+ "SERVER_PROTOCOL": 1,
+ "SERVER_SIGNATURE": 1,
+ "SERVER_SOFTWARE": 1
+ }
+ },
+ "$_SESSION": {
+ type: "array"
+ },
+ "$GLOBALS": {
+ type: "array"
+ }
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type) > -1;
+}
+
+var PhpCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (token.type==='identifier')
+ return this.getFunctionCompletions(state, session, pos, prefix);
+ if (is(token, "variable"))
+ return this.getVariableCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (token.type==='string' && /(\$[\w]*)\[["']([^'"]*)$/i.test(line))
+ return this.getArrayKeyCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getFunctionCompletions = function(state, session, pos, prefix) {
+ var functions = Object.keys(functionMap);
+ return functions.map(function(func){
+ return {
+ caption: func,
+ snippet: func + '($0)',
+ meta: "php function",
+ score: Number.MAX_VALUE,
+ docHTML: functionMap[func][1]
+ };
+ });
+ };
+
+ this.getVariableCompletions = function(state, session, pos, prefix) {
+ var variables = Object.keys(variableMap);
+ return variables.map(function(variable){
+ return {
+ caption: variable,
+ value: variable,
+ meta: "php variable",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getArrayKeyCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var variable = line.match(/(\$[\w]*)\[["']([^'"]*)$/i)[1];
+
+ if (!variableMap[variable]) {
+ return [];
+ }
+
+ var keys = [];
+ if (variableMap[variable].type==='array' && variableMap[variable].value)
+ keys = Object.keys(variableMap[variable].value);
+
+ return keys.map(function(key) {
+ return {
+ caption: key,
+ value: key,
+ meta: "php array key",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(PhpCompletions.prototype);
+
+exports.PhpCompletions = PhpCompletions;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/php",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/php_highlight_rules","ace/mode/php_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/worker/worker_client","ace/mode/php_completions","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/unicode","ace/mode/html","ace/mode/javascript","ace/mode/css"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PhpHighlightRules = require("./php_highlight_rules").PhpHighlightRules;
+var PhpLangHighlightRules = require("./php_highlight_rules").PhpLangHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var PhpCompletions = require("./php_completions").PhpCompletions;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var unicode = require("../unicode");
+var HtmlMode = require("./html").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+
+var PhpMode = function(opts) {
+ this.HighlightRules = PhpLangHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.$completer = new PhpCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(PhpMode, TextMode);
+
+(function() {
+
+ this.tokenRe = new RegExp("^["
+ + unicode.packages.L
+ + unicode.packages.Mn + unicode.packages.Mc
+ + unicode.packages.Nd
+ + unicode.packages.Pc + "_]+", "g"
+ );
+
+ this.nonTokenRe = new RegExp("^(?:[^"
+ + unicode.packages.L
+ + unicode.packages.Mn + unicode.packages.Mc
+ + unicode.packages.Nd
+ + unicode.packages.Pc + "_]|\\s])+", "g"
+ );
+
+
+ this.lineCommentStart = ["//", "#"];
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState != "doc-start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.$id = "ace/mode/php-inline";
+}).call(PhpMode.prototype);
+
+var Mode = function(opts) {
+ if (opts && opts.inline) {
+ var mode = new PhpMode();
+ mode.createWorker = this.createWorker;
+ mode.inlinePhp = true;
+ return mode;
+ }
+ HtmlMode.call(this);
+ this.HighlightRules = PhpHighlightRules;
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode,
+ "php-": PhpMode
+ });
+ this.foldingRules.subModes["php-"] = new CStyleFoldMode();
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/php_worker", "PhpWorker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.inlinePhp)
+ worker.call("setOptions", [{inline: true}]);
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/php";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-pig.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-pig.js
new file mode 100644
index 00000000..e251e384
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-pig.js
@@ -0,0 +1,303 @@
+ace.define("ace/mode/pig_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PigHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ token: "comment.block.pig",
+ regex: /\/\*/,
+ push: [{
+ token: "comment.block.pig",
+ regex: /\*\//,
+ next: "pop"
+ }, {
+ defaultToken: "comment.block.pig"
+ }]
+ }, {
+ token: "comment.line.double-dash.asciidoc",
+ regex: /--.*$/
+ }, {
+ token: "keyword.control.pig",
+ regex: /\b(?:ASSERT|LOAD|STORE|DUMP|FILTER|DISTINCT|FOREACH|GENERATE|STREAM|JOIN|COGROUP|GROUP|CROSS|ORDER|LIMIT|UNION|SPLIT|DESCRIBE|EXPLAIN|ILLUSTRATE|AS|BY|INTO|USING|LIMIT|PARALLEL|OUTER|INNER|DEFAULT|LEFT|SAMPLE|RANK|CUBE|ALL|KILL|QUIT|MAPREDUCE|ASC|DESC|THROUGH|SHIP|CACHE|DECLARE|CASE|WHEN|THEN|END|IN|PARTITION|FULL|IMPORT|IF|ONSCHEMA|INPUT|OUTPUT)\b/,
+ caseInsensitive: true
+ }, {
+ token: "storage.datatypes.pig",
+ regex: /\b(?:int|long|float|double|chararray|bytearray|boolean|datetime|biginteger|bigdecimal|tuple|bag|map)\b/,
+ caseInsensitive: true
+ }, {
+ token: "support.function.storage.pig",
+ regex: /\b(?:PigStorage|BinStorage|BinaryStorage|PigDump|HBaseStorage|JsonLoader|JsonStorage|AvroStorage|TextLoader|PigStreaming|TrevniStorage|AccumuloStorage)\b/
+ }, {
+ token: "support.function.udf.pig",
+ regex: /\b(?:DIFF|TOBAG|TOMAP|TOP|TOTUPLE|RANDOM|FLATTEN|flatten|CUBE|ROLLUP|IsEmpty|ARITY|PluckTuple|SUBTRACT|BagToString)\b/
+ }, {
+ token: "support.function.udf.math.pig",
+ regex: /\b(?:ABS|ACOS|ASIN|ATAN|CBRT|CEIL|COS|COSH|EXP|FLOOR|LOG|LOG10|ROUND|ROUND_TO|SIN|SINH|SQRT|TAN|TANH|AVG|COUNT|COUNT_STAR|MAX|MIN|SUM|COR|COV)\b/
+ }, {
+ token: "support.function.udf.string.pig",
+ regex: /\b(?:CONCAT|INDEXOF|LAST_INDEX_OF|LCFIRST|LOWER|REGEX_EXTRACT|REGEX_EXTRACT_ALL|REPLACE|SIZE|STRSPLIT|SUBSTRING|TOKENIZE|TRIM|UCFIRST|UPPER|LTRIM|RTRIM|ENDSWITH|STARTSWITH|TRIM)\b/
+ }, {
+ token: "support.function.udf.datetime.pig",
+ regex: /\b(?:AddDuration|CurrentTime|DaysBetween|GetDay|GetHour|GetMilliSecond|GetMinute|GetMonth|GetSecond|GetWeek|GetWeekYear|GetYear|HoursBetween|MilliSecondsBetween|MinutesBetween|MonthsBetween|SecondsBetween|SubtractDuration|ToDate|WeeksBetween|YearsBetween|ToMilliSeconds|ToString|ToUnixTime)\b/
+ }, {
+ token: "support.function.command.pig",
+ regex: /\b(?:cat|cd|copyFromLocal|copyToLocal|cp|ls|mkdir|mv|pwd|rm)\b/
+ }, {
+ token: "variable.pig",
+ regex: /\$[a_zA-Z0-9_]+/
+ }, {
+ token: "constant.language.pig",
+ regex: /\b(?:NULL|true|false|stdin|stdout|stderr)\b/,
+ caseInsensitive: true
+ }, {
+ token: "constant.numeric.pig",
+ regex: /\b\d+(?:\.\d+)?\b/
+ }, {
+ token: "keyword.operator.comparison.pig",
+ regex: /!=|==|<|>|<=|>=|\b(?:MATCHES|IS|OR|AND|NOT)\b/,
+ caseInsensitive: true
+ }, {
+ token: "keyword.operator.arithmetic.pig",
+ regex: /\+|\-|\*|\/|\%|\?|:|::|\.\.|#/
+ }, {
+ token: "string.quoted.double.pig",
+ regex: /"/,
+ push: [{
+ token: "string.quoted.double.pig",
+ regex: /"/,
+ next: "pop"
+ }, {
+ token: "constant.character.escape.pig",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.double.pig"
+ }]
+ }, {
+ token: "string.quoted.single.pig",
+ regex: /'/,
+ push: [{
+ token: "string.quoted.single.pig",
+ regex: /'/,
+ next: "pop"
+ }, {
+ token: "constant.character.escape.pig",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.single.pig"
+ }]
+ }, {
+ todo: {
+ token: [
+ "text",
+ "keyword.parameter.pig",
+ "text",
+ "storage.type.parameter.pig"
+ ],
+ regex: /^(\s*)(set)(\s+)(\S+)/,
+ caseInsensitive: true,
+ push: [{
+ token: "text",
+ regex: /$/,
+ next: "pop"
+ }, {
+ include: "$self"
+ }]
+ }
+ }, {
+ token: [
+ "text",
+ "keyword.alias.pig",
+ "text",
+ "storage.type.alias.pig"
+ ],
+ regex: /(\s*)(DEFINE|DECLARE|REGISTER)(\s+)(\S+)/,
+ caseInsensitive: true,
+ push: [{
+ token: "text",
+ regex: /;?$/,
+ next: "pop"
+ }]
+ }]
+ }
+
+ this.normalizeRules();
+};
+
+PigHighlightRules.metaData = {
+ fileTypes: ["pig"],
+ name: "Pig",
+ scopeName: "source.pig"
+}
+
+
+oop.inherits(PigHighlightRules, TextHighlightRules);
+
+exports.PigHighlightRules = PigHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/pig",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/pig_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PigHighlightRules = require("./pig_highlight_rules").PigHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = PigHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/pig"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-plain_text.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-plain_text.js
new file mode 100644
index 00000000..0f0c9380
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-plain_text.js
@@ -0,0 +1,25 @@
+ace.define("ace/mode/plain_text",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/behaviour"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var Behaviour = require("./behaviour").Behaviour;
+
+var Mode = function() {
+ this.HighlightRules = TextHighlightRules;
+ this.$behaviour = new Behaviour();
+};
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.type = "text";
+ this.getNextLineIndent = function(state, line, tab) {
+ return '';
+ };
+ this.$id = "ace/mode/plain_text";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-powershell.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-powershell.js
new file mode 100644
index 00000000..0b43a83e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-powershell.js
@@ -0,0 +1,411 @@
+ace.define("ace/mode/powershell_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PowershellHighlightRules = function() {
+ var keywords = (
+ "begin|break|catch|continue|data|do|dynamicparam|else|elseif|end|exit|filter|" +
+ "finally|for|foreach|from|function|if|in|inlinescript|hidden|parallel|param|" +
+ "process|return|sequence|switch|throw|trap|try|until|while|workflow"
+ );
+ var builtinFunctions = (
+ "Get-AppBackgroundTask|Start-AppBackgroundTask|Unregister-AppBackgroundTask|Disable-AppBackgroundTaskDiagnosticLog|Enable-AppBackgroundTaskDiagnosticLog|Set-AppBackgroundTaskResourcePolicy|" +
+ "Get-AppLockerFileInformation|Get-AppLockerPolicy|New-AppLockerPolicy|Set-AppLockerPolicy|Test-AppLockerPolicy|" +
+ "Get-AppxLastError|Get-AppxLog|Add-AppxPackage|Add-AppxVolume|Dismount-AppxVolume|Get-AppxDefaultVolume|Get-AppxPackage|Get-AppxPackageManifest|Get-AppxVolume|Mount-AppxVolume|Move-AppxPackage|Remove-AppxPackage|Remove-AppxVolume|Set-AppxDefaultVolume|" +
+ "Clear-AssignedAccess|Get-AssignedAccess|Set-AssignedAccess|" +
+ "Add-BitLockerKeyProtector|Backup-BitLockerKeyProtector|Clear-BitLockerAutoUnlock|Disable-BitLocker|Disable-BitLockerAutoUnlock|Enable-BitLocker|Enable-BitLockerAutoUnlock|Get-BitLockerVolume|Lock-BitLocker|Remove-BitLockerKeyProtector|Resume-BitLocker|Suspend-BitLocker|Unlock-BitLocker|" +
+ "Add-BitsFile|Complete-BitsTransfer|Get-BitsTransfer|Remove-BitsTransfer|Resume-BitsTransfer|Set-BitsTransfer|Start-BitsTransfer|Suspend-BitsTransfer|" +
+ "Add-BCDataCacheExtension|Clear-BCCache|Disable-BC|Disable-BCDowngrading|Disable-BCServeOnBattery|Enable-BCDistributed|Enable-BCDowngrading|Enable-BCHostedClient|Enable-BCHostedServer|Enable-BCLocal|Enable-BCServeOnBattery|Export-BCCachePackage|Export-BCSecretKey|Get-BCClientConfiguration|Get-BCContentServerConfiguration|Get-BCDataCache|Get-BCDataCacheExtension|Get-BCHashCache|Get-BCHostedCacheServerConfiguration|Get-BCNetworkConfiguration|Get-BCStatus|Import-BCCachePackage|Import-BCSecretKey|Publish-BCFileContent|Publish-BCWebContent|Remove-BCDataCacheExtension|Reset-BC|Set-BCAuthentication|Set-BCCache|Set-BCDataCacheEntryMaxAge|Set-BCMinSMBLatency|Set-BCSecretKey|" +
+ "Export-BinaryMiLog|Get-CimAssociatedInstance|Get-CimClass|Get-CimInstance|Get-CimSession|Import-BinaryMiLog|Invoke-CimMethod|New-CimInstance|New-CimSession|New-CimSessionOption|Register-CimIndicationEvent|Remove-CimInstance|Remove-CimSession|Set-CimInstance|" +
+ "ConvertFrom-CIPolicy|" +
+ "Add-SignerRule|Edit-CIPolicyRule|Get-CIPolicy|Get-CIPolicyInfo|Get-SystemDriver|Merge-CIPolicy|New-CIPolicy|New-CIPolicyRule|Remove-CIPolicyRule|Set-CIPolicyVersion|Set-HVCIOptions|Set-RuleOption|" +
+ "Add-MpPreference|Get-MpComputerStatus|Get-MpPreference|Get-MpThreat|Get-MpThreatCatalog|Get-MpThreatDetection|Remove-MpPreference|Remove-MpThreat|Set-MpPreference|Start-MpScan|Start-MpWDOScan|Update-MpSignature|" +
+ "Disable-DAManualEntryPointSelection|Enable-DAManualEntryPointSelection|Get-DAClientExperienceConfiguration|Get-DAEntryPointTableItem|New-DAEntryPointTableItem|Remove-DAEntryPointTableItem|Rename-DAEntryPointTableItem|Reset-DAClientExperienceConfiguration|Reset-DAEntryPointTableItem|Set-DAClientExperienceConfiguration|Set-DAEntryPointTableItem|" +
+ "Add-ProvisionedAppxPackage|Apply-WindowsUnattend|Get-ProvisionedAppxPackage|Remove-ProvisionedAppxPackage|Add-AppxProvisionedPackage|Add-WindowsCapability|Add-WindowsDriver|Add-WindowsImage|Add-WindowsPackage|Clear-WindowsCorruptMountPoint|Disable-WindowsOptionalFeature|Dismount-WindowsImage|Enable-WindowsOptionalFeature|Expand-WindowsCustomDataImage|Expand-WindowsImage|Export-WindowsDriver|Export-WindowsImage|Get-AppxProvisionedPackage|Get-WIMBootEntry|Get-WindowsCapability|Get-WindowsDriver|Get-WindowsEdition|Get-WindowsImage|Get-WindowsImageContent|Get-WindowsOptionalFeature|Get-WindowsPackage|Mount-WindowsImage|New-WindowsCustomImage|New-WindowsImage|Optimize-WindowsImage|Remove-AppxProvisionedPackage|Remove-WindowsCapability|Remove-WindowsDriver|Remove-WindowsImage|Remove-WindowsPackage|Repair-WindowsImage|Save-WindowsImage|Set-AppXProvisionedDataFile|Set-WindowsEdition|Set-WindowsProductKey|Split-WindowsImage|Update-WIMBootEntry|Use-WindowsUnattend|" +
+ "Add-DnsClientNrptRule|Clear-DnsClientCache|Get-DnsClient|Get-DnsClientCache|Get-DnsClientGlobalSetting|Get-DnsClientNrptGlobal|Get-DnsClientNrptPolicy|Get-DnsClientNrptRule|Get-DnsClientServerAddress|Register-DnsClient|Remove-DnsClientNrptRule|Set-DnsClient|Set-DnsClientGlobalSetting|Set-DnsClientNrptGlobal|Set-DnsClientNrptRule|Set-DnsClientServerAddress|Resolve-DnsName|" +
+ "Add-EtwTraceProvider|Get-AutologgerConfig|Get-EtwTraceProvider|Get-EtwTraceSession|New-AutologgerConfig|New-EtwTraceSession|Remove-AutologgerConfig|Remove-EtwTraceProvider|Remove-EtwTraceSession|Send-EtwTraceSession|Set-AutologgerConfig|Set-EtwTraceProvider|Set-EtwTraceSession|" +
+ "Get-WinAcceptLanguageFromLanguageListOptOut|Get-WinCultureFromLanguageListOptOut|Get-WinDefaultInputMethodOverride|Get-WinHomeLocation|Get-WinLanguageBarOption|Get-WinSystemLocale|Get-WinUILanguageOverride|Get-WinUserLanguageList|New-WinUserLanguageList|Set-Culture|Set-WinAcceptLanguageFromLanguageListOptOut|Set-WinCultureFromLanguageListOptOut|Set-WinDefaultInputMethodOverride|Set-WinHomeLocation|Set-WinLanguageBarOption|Set-WinSystemLocale|Set-WinUILanguageOverride|Set-WinUserLanguageList|" +
+ "Connect-IscsiTarget|Disconnect-IscsiTarget|Get-IscsiConnection|Get-IscsiSession|Get-IscsiTarget|Get-IscsiTargetPortal|New-IscsiTargetPortal|Register-IscsiSession|Remove-IscsiTargetPortal|Set-IscsiChapSecret|Unregister-IscsiSession|Update-IscsiTarget|Update-IscsiTargetPortal|" +
+ "Get-IseSnippet|Import-IseSnippet|New-IseSnippet|" +
+ "Add-KdsRootKey|Clear-KdsCache|Get-KdsConfiguration|Get-KdsRootKey|Set-KdsConfiguration|Test-KdsRootKey|" +
+ "Compress-Archive|Expand-Archive|" +
+ "Export-Counter|Get-Counter|Get-WinEvent|Import-Counter|New-WinEvent|" +
+ "Start-Transcript|Stop-Transcript|" +
+ "Add-Computer|Add-Content|Checkpoint-Computer|Clear-Content|Clear-EventLog|Clear-Item|Clear-ItemProperty|Clear-RecycleBin|Complete-Transaction|Convert-Path|Copy-Item|Copy-ItemProperty|Debug-Process|Disable-ComputerRestore|Enable-ComputerRestore|Get-ChildItem|Get-Clipboard|Get-ComputerRestorePoint|Get-Content|Get-ControlPanelItem|Get-EventLog|Get-HotFix|Get-Item|Get-ItemProperty|Get-ItemPropertyValue|Get-Location|Get-Process|Get-PSDrive|Get-PSProvider|Get-Service|Get-Transaction|Get-WmiObject|Invoke-Item|Invoke-WmiMethod|Join-Path|Limit-EventLog|Move-Item|Move-ItemProperty|New-EventLog|New-Item|New-ItemProperty|New-PSDrive|New-Service|New-WebServiceProxy|Pop-Location|Push-Location|Register-WmiEvent|Remove-Computer|Remove-EventLog|Remove-Item|Remove-ItemProperty|Remove-PSDrive|Remove-WmiObject|Rename-Computer|Rename-Item|Rename-ItemProperty|Reset-ComputerMachinePassword|Resolve-Path|Restart-Computer|Restart-Service|Restore-Computer|Resume-Service|Set-Clipboard|Set-Content|Set-Item|Set-ItemProperty|Set-Location|Set-Service|Set-WmiInstance|Show-ControlPanelItem|Show-EventLog|Split-Path|Start-Process|Start-Service|Start-Transaction|Stop-Computer|Stop-Process|Stop-Service|Suspend-Service|Test-ComputerSecureChannel|Test-Connection|Test-Path|Undo-Transaction|Use-Transaction|Wait-Process|Write-EventLog|" +
+ "Export-ODataEndpointProxy|" +
+ "ConvertFrom-SecureString|ConvertTo-SecureString|Get-Acl|Get-AuthenticodeSignature|Get-CmsMessage|Get-Credential|Get-ExecutionPolicy|Get-PfxCertificate|Protect-CmsMessage|Set-Acl|Set-AuthenticodeSignature|Set-ExecutionPolicy|Unprotect-CmsMessage|" +
+ "ConvertFrom-SddlString|Format-Hex|Get-FileHash|Import-PowerShellDataFile|New-Guid|New-TemporaryFile|Add-Member|Add-Type|Clear-Variable|Compare-Object|ConvertFrom-Csv|ConvertFrom-Json|ConvertFrom-String|ConvertFrom-StringData|Convert-String|ConvertTo-Csv|ConvertTo-Html|ConvertTo-Json|ConvertTo-Xml|Debug-Runspace|Disable-PSBreakpoint|Disable-RunspaceDebug|Enable-PSBreakpoint|Enable-RunspaceDebug|Export-Alias|Export-Clixml|Export-Csv|Export-FormatData|Export-PSSession|Format-Custom|Format-List|Format-Table|Format-Wide|Get-Alias|Get-Culture|Get-Date|Get-Event|Get-EventSubscriber|Get-FormatData|Get-Host|Get-Member|Get-PSBreakpoint|Get-PSCallStack|Get-Random|Get-Runspace|Get-RunspaceDebug|Get-TraceSource|Get-TypeData|Get-UICulture|Get-Unique|Get-Variable|Group-Object|Import-Alias|Import-Clixml|Import-Csv|Import-LocalizedData|Import-PSSession|Invoke-Expression|Invoke-RestMethod|Invoke-WebRequest|Measure-Command|Measure-Object|New-Alias|New-Event|New-Object|New-TimeSpan|New-Variable|Out-File|Out-GridView|Out-Printer|Out-String|Read-Host|Register-EngineEvent|Register-ObjectEvent|Remove-Event|Remove-PSBreakpoint|Remove-TypeData|Remove-Variable|Select-Object|Select-String|Select-Xml|Send-MailMessage|Set-Alias|Set-Date|Set-PSBreakpoint|Set-TraceSource|Set-Variable|Show-Command|Sort-Object|Start-Sleep|Tee-Object|Trace-Command|Unblock-File|Unregister-Event|Update-FormatData|Update-List|Update-TypeData|Wait-Debugger|Wait-Event|Write-Debug|Write-Error|Write-Host|Write-Information|Write-Output|Write-Progress|Write-Verbose|Write-Warning|" +
+ "Connect-WSMan|Disable-WSManCredSSP|Disconnect-WSMan|Enable-WSManCredSSP|Get-WSManCredSSP|Get-WSManInstance|Invoke-WSManAction|New-WSManInstance|New-WSManSessionOption|Remove-WSManInstance|Set-WSManInstance|Set-WSManQuickConfig|Test-WSMan|" +
+ "Debug-MMAppPrelaunch|Disable-MMAgent|Enable-MMAgent|Get-MMAgent|Set-MMAgent|" +
+ "Add-DtcClusterTMMapping|Get-Dtc|Get-DtcAdvancedHostSetting|Get-DtcAdvancedSetting|Get-DtcClusterDefault|Get-DtcClusterTMMapping|Get-DtcDefault|Get-DtcLog|Get-DtcNetworkSetting|Get-DtcTransaction|Get-DtcTransactionsStatistics|Get-DtcTransactionsTraceSession|Get-DtcTransactionsTraceSetting|Install-Dtc|Remove-DtcClusterTMMapping|Reset-DtcLog|Set-DtcAdvancedHostSetting|Set-DtcAdvancedSetting|Set-DtcClusterDefault|Set-DtcClusterTMMapping|Set-DtcDefault|Set-DtcLog|Set-DtcNetworkSetting|Set-DtcTransaction|Set-DtcTransactionsTraceSession|Set-DtcTransactionsTraceSetting|Start-Dtc|Start-DtcTransactionsTraceSession|Stop-Dtc|Stop-DtcTransactionsTraceSession|Test-Dtc|Uninstall-Dtc|Write-DtcTransactionsTraceSession|Complete-DtcDiagnosticTransaction|Join-DtcDiagnosticResourceManager|New-DtcDiagnosticTransaction|Receive-DtcDiagnosticTransaction|Send-DtcDiagnosticTransaction|Start-DtcDiagnosticResourceManager|Stop-DtcDiagnosticResourceManager|Undo-DtcDiagnosticTransaction|" +
+ "Disable-NetAdapter|Disable-NetAdapterBinding|Disable-NetAdapterChecksumOffload|Disable-NetAdapterEncapsulatedPacketTaskOffload|Disable-NetAdapterIPsecOffload|Disable-NetAdapterLso|Disable-NetAdapterPacketDirect|Disable-NetAdapterPowerManagement|Disable-NetAdapterQos|Disable-NetAdapterRdma|Disable-NetAdapterRsc|Disable-NetAdapterRss|Disable-NetAdapterSriov|Disable-NetAdapterVmq|Enable-NetAdapter|Enable-NetAdapterBinding|Enable-NetAdapterChecksumOffload|Enable-NetAdapterEncapsulatedPacketTaskOffload|Enable-NetAdapterIPsecOffload|Enable-NetAdapterLso|Enable-NetAdapterPacketDirect|Enable-NetAdapterPowerManagement|Enable-NetAdapterQos|Enable-NetAdapterRdma|Enable-NetAdapterRsc|Enable-NetAdapterRss|Enable-NetAdapterSriov|Enable-NetAdapterVmq|Get-NetAdapter|Get-NetAdapterAdvancedProperty|Get-NetAdapterBinding|Get-NetAdapterChecksumOffload|Get-NetAdapterEncapsulatedPacketTaskOffload|Get-NetAdapterHardwareInfo|Get-NetAdapterIPsecOffload|Get-NetAdapterLso|Get-NetAdapterPacketDirect|Get-NetAdapterPowerManagement|Get-NetAdapterQos|Get-NetAdapterRdma|Get-NetAdapterRsc|Get-NetAdapterRss|Get-NetAdapterSriov|Get-NetAdapterSriovVf|Get-NetAdapterStatistics|Get-NetAdapterVmq|Get-NetAdapterVmqQueue|Get-NetAdapterVPort|New-NetAdapterAdvancedProperty|Remove-NetAdapterAdvancedProperty|Rename-NetAdapter|Reset-NetAdapterAdvancedProperty|Restart-NetAdapter|Set-NetAdapter|Set-NetAdapterAdvancedProperty|Set-NetAdapterBinding|Set-NetAdapterChecksumOffload|Set-NetAdapterEncapsulatedPacketTaskOffload|Set-NetAdapterIPsecOffload|Set-NetAdapterLso|Set-NetAdapterPacketDirect|Set-NetAdapterPowerManagement|Set-NetAdapterQos|Set-NetAdapterRdma|Set-NetAdapterRsc|Set-NetAdapterRss|Set-NetAdapterSriov|Set-NetAdapterVmq|" +
+ "Get-NetConnectionProfile|Set-NetConnectionProfile|" +
+ "Add-NetEventNetworkAdapter|Add-NetEventPacketCaptureProvider|Add-NetEventProvider|Add-NetEventVmNetworkAdapter|Add-NetEventVmSwitch|Add-NetEventWFPCaptureProvider|Get-NetEventNetworkAdapter|Get-NetEventPacketCaptureProvider|Get-NetEventProvider|Get-NetEventSession|Get-NetEventVmNetworkAdapter|Get-NetEventVmSwitch|Get-NetEventWFPCaptureProvider|New-NetEventSession|Remove-NetEventNetworkAdapter|Remove-NetEventPacketCaptureProvider|Remove-NetEventProvider|Remove-NetEventSession|Remove-NetEventVmNetworkAdapter|Remove-NetEventVmSwitch|Remove-NetEventWFPCaptureProvider|Set-NetEventPacketCaptureProvider|Set-NetEventProvider|Set-NetEventSession|Set-NetEventWFPCaptureProvider|Start-NetEventSession|Stop-NetEventSession|" +
+ "Add-NetLbfoTeamMember|Add-NetLbfoTeamNic|Get-NetLbfoTeam|Get-NetLbfoTeamMember|Get-NetLbfoTeamNic|New-NetLbfoTeam|Remove-NetLbfoTeam|Remove-NetLbfoTeamMember|Remove-NetLbfoTeamNic|Rename-NetLbfoTeam|Set-NetLbfoTeam|Set-NetLbfoTeamMember|Set-NetLbfoTeamNic|" +
+ "Add-NetNatExternalAddress|Add-NetNatStaticMapping|Get-NetNat|Get-NetNatExternalAddress|Get-NetNatGlobal|Get-NetNatSession|Get-NetNatStaticMapping|New-NetNat|Remove-NetNat|Remove-NetNatExternalAddress|Remove-NetNatStaticMapping|Set-NetNat|Set-NetNatGlobal|" +
+ "Get-NetQosPolicy|New-NetQosPolicy|Remove-NetQosPolicy|Set-NetQosPolicy|" +
+ "Copy-NetFirewallRule|Copy-NetIPsecMainModeCryptoSet|Copy-NetIPsecMainModeRule|Copy-NetIPsecPhase1AuthSet|Copy-NetIPsecPhase2AuthSet|Copy-NetIPsecQuickModeCryptoSet|Copy-NetIPsecRule|Disable-NetFirewallRule|Disable-NetIPsecMainModeRule|Disable-NetIPsecRule|Enable-NetFirewallRule|Enable-NetIPsecMainModeRule|Enable-NetIPsecRule|Find-NetIPsecRule|Get-NetFirewallAddressFilter|Get-NetFirewallApplicationFilter|Get-NetFirewallInterfaceFilter|Get-NetFirewallInterfaceTypeFilter|Get-NetFirewallPortFilter|Get-NetFirewallProfile|Get-NetFirewallRule|Get-NetFirewallSecurityFilter|Get-NetFirewallServiceFilter|Get-NetFirewallSetting|Get-NetIPsecDospSetting|Get-NetIPsecMainModeCryptoSet|Get-NetIPsecMainModeRule|Get-NetIPsecMainModeSA|Get-NetIPsecPhase1AuthSet|Get-NetIPsecPhase2AuthSet|Get-NetIPsecQuickModeCryptoSet|Get-NetIPsecQuickModeSA|Get-NetIPsecRule|New-NetFirewallRule|New-NetIPsecDospSetting|New-NetIPsecMainModeCryptoSet|New-NetIPsecMainModeRule|New-NetIPsecPhase1AuthSet|New-NetIPsecPhase2AuthSet|New-NetIPsecQuickModeCryptoSet|New-NetIPsecRule|Open-NetGPO|Remove-NetFirewallRule|Remove-NetIPsecDospSetting|Remove-NetIPsecMainModeCryptoSet|Remove-NetIPsecMainModeRule|Remove-NetIPsecMainModeSA|Remove-NetIPsecPhase1AuthSet|Remove-NetIPsecPhase2AuthSet|Remove-NetIPsecQuickModeCryptoSet|Remove-NetIPsecQuickModeSA|Remove-NetIPsecRule|Rename-NetFirewallRule|Rename-NetIPsecMainModeCryptoSet|Rename-NetIPsecMainModeRule|Rename-NetIPsecPhase1AuthSet|Rename-NetIPsecPhase2AuthSet|Rename-NetIPsecQuickModeCryptoSet|Rename-NetIPsecRule|Save-NetGPO|Set-NetFirewallAddressFilter|Set-NetFirewallApplicationFilter|Set-NetFirewallInterfaceFilter|Set-NetFirewallInterfaceTypeFilter|Set-NetFirewallPortFilter|Set-NetFirewallProfile|Set-NetFirewallRule|Set-NetFirewallSecurityFilter|Set-NetFirewallServiceFilter|Set-NetFirewallSetting|Set-NetIPsecDospSetting|Set-NetIPsecMainModeCryptoSet|Set-NetIPsecMainModeRule|Set-NetIPsecPhase1AuthSet|Set-NetIPsecPhase2AuthSet|Set-NetIPsecQuickModeCryptoSet|Set-NetIPsecRule|Show-NetFirewallRule|Show-NetIPsecRule|Sync-NetIPsecRule|Update-NetIPsecRule|Get-DAPolicyChange|New-NetIPsecAuthProposal|New-NetIPsecMainModeCryptoProposal|New-NetIPsecQuickModeCryptoProposal|" +
+ "Add-NetSwitchTeamMember|Get-NetSwitchTeam|Get-NetSwitchTeamMember|New-NetSwitchTeam|Remove-NetSwitchTeam|Remove-NetSwitchTeamMember|Rename-NetSwitchTeam|" +
+ "Find-NetRoute|Get-NetCompartment|Get-NetIPAddress|Get-NetIPConfiguration|Get-NetIPInterface|Get-NetIPv4Protocol|Get-NetIPv6Protocol|Get-NetNeighbor|Get-NetOffloadGlobalSetting|Get-NetPrefixPolicy|Get-NetRoute|Get-NetTCPConnection|Get-NetTCPSetting|Get-NetTransportFilter|Get-NetUDPEndpoint|Get-NetUDPSetting|New-NetIPAddress|New-NetNeighbor|New-NetRoute|New-NetTransportFilter|Remove-NetIPAddress|Remove-NetNeighbor|Remove-NetRoute|Remove-NetTransportFilter|Set-NetIPAddress|Set-NetIPInterface|Set-NetIPv4Protocol|Set-NetIPv6Protocol|Set-NetNeighbor|Set-NetOffloadGlobalSetting|Set-NetRoute|Set-NetTCPSetting|Set-NetUDPSetting|Test-NetConnection|" +
+ "Get-DAConnectionStatus|Get-NCSIPolicyConfiguration|Reset-NCSIPolicyConfiguration|Set-NCSIPolicyConfiguration|" +
+ "Disable-NetworkSwitchEthernetPort|Disable-NetworkSwitchFeature|Disable-NetworkSwitchVlan|Enable-NetworkSwitchEthernetPort|Enable-NetworkSwitchFeature|Enable-NetworkSwitchVlan|Get-NetworkSwitchEthernetPort|Get-NetworkSwitchFeature|Get-NetworkSwitchGlobalData|Get-NetworkSwitchVlan|New-NetworkSwitchVlan|Remove-NetworkSwitchEthernetPortIPAddress|Remove-NetworkSwitchVlan|Restore-NetworkSwitchConfiguration|Save-NetworkSwitchConfiguration|Set-NetworkSwitchEthernetPortIPAddress|Set-NetworkSwitchPortMode|Set-NetworkSwitchPortProperty|Set-NetworkSwitchVlanProperty|" +
+ "Add-NetIPHttpsCertBinding|Disable-NetDnsTransitionConfiguration|Disable-NetIPHttpsProfile|Disable-NetNatTransitionConfiguration|Enable-NetDnsTransitionConfiguration|Enable-NetIPHttpsProfile|Enable-NetNatTransitionConfiguration|Get-Net6to4Configuration|Get-NetDnsTransitionConfiguration|Get-NetDnsTransitionMonitoring|Get-NetIPHttpsConfiguration|Get-NetIPHttpsState|Get-NetIsatapConfiguration|Get-NetNatTransitionConfiguration|Get-NetNatTransitionMonitoring|Get-NetTeredoConfiguration|Get-NetTeredoState|New-NetIPHttpsConfiguration|New-NetNatTransitionConfiguration|Remove-NetIPHttpsCertBinding|Remove-NetIPHttpsConfiguration|Remove-NetNatTransitionConfiguration|Rename-NetIPHttpsConfiguration|Reset-Net6to4Configuration|Reset-NetDnsTransitionConfiguration|Reset-NetIPHttpsConfiguration|Reset-NetIsatapConfiguration|Reset-NetTeredoConfiguration|Set-Net6to4Configuration|Set-NetDnsTransitionConfiguration|Set-NetIPHttpsConfiguration|Set-NetIsatapConfiguration|Set-NetNatTransitionConfiguration|Set-NetTeredoConfiguration|" +
+ "Find-Package|Find-PackageProvider|Get-Package|Get-PackageProvider|Get-PackageSource|Import-PackageProvider|Install-Package|Install-PackageProvider|Register-PackageSource|Save-Package|Set-PackageSource|Uninstall-Package|Unregister-PackageSource|" +
+ "Clear-PcsvDeviceLog|Get-PcsvDevice|Get-PcsvDeviceLog|Restart-PcsvDevice|Set-PcsvDeviceBootConfiguration|Set-PcsvDeviceNetworkConfiguration|Set-PcsvDeviceUserPassword|Start-PcsvDevice|Stop-PcsvDevice|" +
+ "AfterAll|AfterEach|Assert-MockCalled|Assert-VerifiableMocks|BeforeAll|BeforeEach|Context|Describe|Get-MockDynamicParameters|Get-TestDriveItem|In|InModuleScope|Invoke-Mock|Invoke-Pester|It|Mock|New-Fixture|Set-DynamicParameterVariables|Setup|Should|" +
+ "Add-CertificateEnrollmentPolicyServer|Export-Certificate|Export-PfxCertificate|Get-Certificate|Get-CertificateAutoEnrollmentPolicy|Get-CertificateEnrollmentPolicyServer|Get-CertificateNotificationTask|Get-PfxData|Import-Certificate|Import-PfxCertificate|New-CertificateNotificationTask|New-SelfSignedCertificate|Remove-CertificateEnrollmentPolicyServer|Remove-CertificateNotificationTask|Set-CertificateAutoEnrollmentPolicy|Switch-Certificate|Test-Certificate|" +
+ "Disable-PnpDevice|Enable-PnpDevice|Get-PnpDevice|Get-PnpDeviceProperty|" +
+ "Find-DscResource|Find-Module|Find-Script|Get-InstalledModule|Get-InstalledScript|Get-PSRepository|Install-Module|Install-Script|New-ScriptFileInfo|Publish-Module|Publish-Script|Register-PSRepository|Save-Module|Save-Script|Set-PSRepository|Test-ScriptFileInfo|Uninstall-Module|Uninstall-Script|Unregister-PSRepository|Update-Module|Update-ModuleManifest|Update-Script|Update-ScriptFileInfo|" +
+ "Add-Printer|Add-PrinterDriver|Add-PrinterPort|Get-PrintConfiguration|Get-Printer|Get-PrinterDriver|Get-PrinterPort|Get-PrinterProperty|Get-PrintJob|Read-PrinterNfcTag|Remove-Printer|Remove-PrinterDriver|Remove-PrinterPort|Remove-PrintJob|Rename-Printer|Restart-PrintJob|Resume-PrintJob|Set-PrintConfiguration|Set-Printer|Set-PrinterProperty|Suspend-PrintJob|Write-PrinterNfcTag|" +
+ "Configuration|Disable-DscDebug|Enable-DscDebug|Get-DscConfiguration|Get-DscConfigurationStatus|Get-DscLocalConfigurationManager|Get-DscResource|New-DscChecksum|Remove-DscConfigurationDocument|Restore-DscConfiguration|Stop-DscConfiguration|Invoke-DscResource|Publish-DscConfiguration|Set-DscLocalConfigurationManager|Start-DscConfiguration|Test-DscConfiguration|Update-DscConfiguration|" +
+ "Disable-PSTrace|Disable-PSWSManCombinedTrace|Disable-WSManTrace|Enable-PSTrace|Enable-PSWSManCombinedTrace|Enable-WSManTrace|Get-LogProperties|Set-LogProperties|Start-Trace|Stop-Trace|" +
+ "PSConsoleHostReadline|Get-PSReadlineKeyHandler|Get-PSReadlineOption|Remove-PSReadlineKeyHandler|Set-PSReadlineKeyHandler|Set-PSReadlineOption|" +
+ "Add-JobTrigger|Disable-JobTrigger|Disable-ScheduledJob|Enable-JobTrigger|Enable-ScheduledJob|Get-JobTrigger|Get-ScheduledJob|Get-ScheduledJobOption|New-JobTrigger|New-ScheduledJobOption|Register-ScheduledJob|Remove-JobTrigger|Set-JobTrigger|Set-ScheduledJob|Set-ScheduledJobOption|Unregister-ScheduledJob|" +
+ "New-PSWorkflowSession|New-PSWorkflowExecutionOption|" +
+ "Invoke-AsWorkflow|" +
+ "Disable-ScheduledTask|Enable-ScheduledTask|Export-ScheduledTask|Get-ClusteredScheduledTask|Get-ScheduledTask|Get-ScheduledTaskInfo|New-ScheduledTask|New-ScheduledTaskAction|New-ScheduledTaskPrincipal|New-ScheduledTaskSettingsSet|New-ScheduledTaskTrigger|Register-ClusteredScheduledTask|Register-ScheduledTask|Set-ClusteredScheduledTask|Set-ScheduledTask|Start-ScheduledTask|Stop-ScheduledTask|Unregister-ClusteredScheduledTask|Unregister-ScheduledTask|" +
+ "Confirm-SecureBootUEFI|Format-SecureBootUEFI|Get-SecureBootPolicy|Get-SecureBootUEFI|Set-SecureBootUEFI|" +
+ "Block-SmbShareAccess|Close-SmbOpenFile|Close-SmbSession|Disable-SmbDelegation|Enable-SmbDelegation|Get-SmbBandwidthLimit|Get-SmbClientConfiguration|Get-SmbClientNetworkInterface|Get-SmbConnection|Get-SmbDelegation|Get-SmbMapping|Get-SmbMultichannelConnection|Get-SmbMultichannelConstraint|Get-SmbOpenFile|Get-SmbServerConfiguration|Get-SmbServerNetworkInterface|Get-SmbSession|Get-SmbShare|Get-SmbShareAccess|Grant-SmbShareAccess|New-SmbMapping|New-SmbMultichannelConstraint|New-SmbShare|Remove-SmbBandwidthLimit|Remove-SmbMapping|Remove-SmbMultichannelConstraint|Remove-SmbShare|Revoke-SmbShareAccess|Set-SmbBandwidthLimit|Set-SmbClientConfiguration|Set-SmbPathAcl|Set-SmbServerConfiguration|Set-SmbShare|Unblock-SmbShareAccess|Update-SmbMultichannelConnection|" +
+ "Move-SmbClient|Get-SmbWitnessClient|Move-SmbWitnessClient|" +
+ "Get-StartApps|Export-StartLayout|Import-StartLayout|" +
+ "Disable-PhysicalDiskIndication|Disable-StorageDiagnosticLog|Enable-PhysicalDiskIndication|Enable-StorageDiagnosticLog|Flush-Volume|Get-DiskSNV|Get-PhysicalDiskSNV|Get-StorageEnclosureSNV|Initialize-Volume|Write-FileSystemCache|Add-InitiatorIdToMaskingSet|Add-PartitionAccessPath|Add-PhysicalDisk|Add-TargetPortToMaskingSet|Add-VirtualDiskToMaskingSet|Block-FileShareAccess|Clear-Disk|Clear-FileStorageTier|Clear-StorageDiagnosticInfo|Connect-VirtualDisk|Debug-FileShare|Debug-StorageSubSystem|Debug-Volume|Disable-PhysicalDiskIdentification|Disable-StorageEnclosureIdentification|Disable-StorageHighAvailability|Disconnect-VirtualDisk|Dismount-DiskImage|Enable-PhysicalDiskIdentification|Enable-StorageEnclosureIdentification|Enable-StorageHighAvailability|Format-Volume|Get-DedupProperties|Get-Disk|Get-DiskImage|Get-DiskStorageNodeView|Get-FileIntegrity|Get-FileShare|Get-FileShareAccessControlEntry|Get-FileStorageTier|Get-InitiatorId|Get-InitiatorPort|Get-MaskingSet|Get-OffloadDataTransferSetting|Get-Partition|Get-PartitionSupportedSize|Get-PhysicalDisk|Get-PhysicalDiskStorageNodeView|Get-ResiliencySetting|Get-StorageAdvancedProperty|Get-StorageDiagnosticInfo|Get-StorageEnclosure|Get-StorageEnclosureStorageNodeView|Get-StorageEnclosureVendorData|Get-StorageFaultDomain|Get-StorageFileServer|Get-StorageFirmwareInformation|Get-StorageHealthAction|Get-StorageHealthReport|Get-StorageHealthSetting|Get-StorageJob|Get-StorageNode|Get-StoragePool|Get-StorageProvider|Get-StorageReliabilityCounter|Get-StorageSetting|Get-StorageSubSystem|Get-StorageTier|Get-StorageTierSupportedSize|Get-SupportedClusterSizes|Get-SupportedFileSystems|Get-TargetPort|Get-TargetPortal|Get-VirtualDisk|Get-VirtualDiskSupportedSize|Get-Volume|Get-VolumeCorruptionCount|Get-VolumeScrubPolicy|Grant-FileShareAccess|Hide-VirtualDisk|Initialize-Disk|Mount-DiskImage|New-FileShare|New-MaskingSet|New-Partition|New-StorageFileServer|New-StoragePool|New-StorageSubsystemVirtualDisk|New-StorageTier|New-VirtualDisk|New-VirtualDiskClone|New-VirtualDiskSnapshot|New-Volume|Optimize-StoragePool|Optimize-Volume|Register-StorageSubsystem|Remove-FileShare|Remove-InitiatorId|Remove-InitiatorIdFromMaskingSet|Remove-MaskingSet|Remove-Partition|Remove-PartitionAccessPath|Remove-PhysicalDisk|Remove-StorageFileServer|Remove-StorageHealthSetting|Remove-StoragePool|Remove-StorageTier|Remove-TargetPortFromMaskingSet|Remove-VirtualDisk|Remove-VirtualDiskFromMaskingSet|Rename-MaskingSet|Repair-FileIntegrity|Repair-VirtualDisk|Repair-Volume|Reset-PhysicalDisk|Reset-StorageReliabilityCounter|Resize-Partition|Resize-StorageTier|Resize-VirtualDisk|Revoke-FileShareAccess|Set-Disk|Set-FileIntegrity|Set-FileShare|Set-FileStorageTier|Set-InitiatorPort|Set-Partition|Set-PhysicalDisk|Set-ResiliencySetting|Set-StorageFileServer|Set-StorageHealthSetting|Set-StoragePool|Set-StorageProvider|Set-StorageSetting|Set-StorageSubSystem|Set-StorageTier|Set-VirtualDisk|Set-Volume|Set-VolumeScrubPolicy|Show-VirtualDisk|Start-StorageDiagnosticLog|Stop-StorageDiagnosticLog|Stop-StorageJob|Unblock-FileShareAccess|Unregister-StorageSubsystem|Update-Disk|Update-HostStorageCache|Update-StorageFirmware|Update-StoragePool|Update-StorageProviderCache|Write-VolumeCache|" +
+ "Disable-TlsCipherSuite|Disable-TlsSessionTicketKey|Enable-TlsCipherSuite|Enable-TlsSessionTicketKey|Export-TlsSessionTicketKey|Get-TlsCipherSuite|New-TlsSessionTicketKey|" +
+ "Get-TroubleshootingPack|Invoke-TroubleshootingPack|" +
+ "Clear-Tpm|ConvertTo-TpmOwnerAuth|Disable-TpmAutoProvisioning|Enable-TpmAutoProvisioning|Get-Tpm|Get-TpmEndorsementKeyInfo|Get-TpmSupportedFeature|Import-TpmOwnerAuth|Initialize-Tpm|Set-TpmOwnerAuth|Unblock-Tpm|" +
+ "Add-VpnConnection|Add-VpnConnectionRoute|Add-VpnConnectionTriggerApplication|Add-VpnConnectionTriggerDnsConfiguration|Add-VpnConnectionTriggerTrustedNetwork|Get-VpnConnection|Get-VpnConnectionTrigger|New-EapConfiguration|New-VpnServerAddress|Remove-VpnConnection|Remove-VpnConnectionRoute|Remove-VpnConnectionTriggerApplication|Remove-VpnConnectionTriggerDnsConfiguration|Remove-VpnConnectionTriggerTrustedNetwork|Set-VpnConnection|Set-VpnConnectionIPsecConfiguration|Set-VpnConnectionProxy|Set-VpnConnectionTriggerDnsConfiguration|Set-VpnConnectionTriggerTrustedNetwork|" +
+ "Add-OdbcDsn|Disable-OdbcPerfCounter|Disable-WdacBidTrace|Enable-OdbcPerfCounter|Enable-WdacBidTrace|Get-OdbcDriver|Get-OdbcDsn|Get-OdbcPerfCounter|Get-WdacBidTrace|Remove-OdbcDsn|Set-OdbcDriver|Set-OdbcDsn|" +
+ "Get-WindowsDeveloperLicense|Show-WindowsDeveloperLicenseRegistration|Unregister-WindowsDeveloperLicense|" +
+ "Disable-WindowsErrorReporting|Enable-WindowsErrorReporting|Get-WindowsErrorReporting|" +
+ "Get-WindowsSearchSetting|Set-WindowsSearchSetting|" +
+ "Get-WindowsUpdateLog"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords
+ }, "identifier");
+ var binaryOperatorsRe = (
+ "eq|ne|gt|lt|le|ge|like|notlike|match|notmatch|contains|notcontains|in|notin|band|bor|bxor|bnot|" +
+ "ceq|cne|cgt|clt|cle|cge|clike|cnotlike|cmatch|cnotmatch|ccontains|cnotcontains|cin|cnotin|" +
+ "ieq|ine|igt|ilt|ile|ige|ilike|inotlike|imatch|inotmatch|icontains|inotcontains|iin|inotin|" +
+ "and|or|xor|not|" +
+ "split|join|replace|f|" +
+ "csplit|creplace|" +
+ "isplit|ireplace|" +
+ "is|isnot|as|" +
+ "shl|shr"
+ );
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "comment.start",
+ regex : "<#",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "[$](?:[Tt]rue|[Ff]alse)\\b"
+ }, {
+ token : "constant.language",
+ regex : "[$][Nn]ull\\b"
+ }, {
+ token : "variable.instance",
+ regex : "[$][a-zA-Z][a-zA-Z0-9_]*\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$\\-]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\-(?:" + binaryOperatorsRe + ")"
+ }, {
+ token : "keyword.operator",
+ regex : "&|\\+|\\-|\\*|\\/|\\%|\\=|\\>|\\&|\\!|\\|"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment.end",
+ regex : "#>",
+ next : "start"
+ }, {
+ token : "doc.comment.tag",
+ regex : "^\\.\\w+"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+};
+
+oop.inherits(PowershellHighlightRules, TextHighlightRules);
+
+exports.PowershellHighlightRules = PowershellHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/powershell",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/powershell_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PowershellHighlightRules = require("./powershell_highlight_rules").PowershellHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = PowershellHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode({start: "^\\s*(<#)", end: "^[#\\s]>\\s*$"});
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+ this.blockComment = {start: "<#", end: "#>"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/powershell";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-praat.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-praat.js
new file mode 100644
index 00000000..a3a50f7e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-praat.js
@@ -0,0 +1,468 @@
+ace.define("ace/mode/praat_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PraatHighlightRules = function() {
+
+ var keywords = (
+ "if|then|else|elsif|elif|endif|fi|" +
+ "endfor|endproc|" + // related keywords specified below
+ "while|endwhile|" +
+ "repeat|until|" +
+ "select|plus|minus|" +
+ "assert|asserterror"
+ );
+
+ var predefinedVariables = (
+ "macintosh|windows|unix|" +
+ "praatVersion|praatVersion\\$" +
+ "pi|undefined|" +
+ "newline\\$|tab\\$|" +
+ "shellDirectory\\$|homeDirectory\\$|preferencesDirectory\\$|" +
+ "temporaryDirectory\\$|defaultDirectory\\$"
+ );
+ var directives = (
+ "clearinfo|endSendPraat"
+ );
+
+ var functions = (
+ "writeInfo|writeInfoLine|appendInfo|appendInfoLine|info\\$|" +
+ "writeFile|writeFileLine|appendFile|appendFileLine|" +
+ "abs|round|floor|ceiling|min|max|imin|imax|" +
+ "sqrt|sin|cos|tan|arcsin|arccos|arctan|arctan2|sinc|sincpi|" +
+ "exp|ln|lnBeta|lnGamma|log10|log2|" +
+ "sinh|cosh|tanh|arcsinh|arccosh|arctanh|" +
+ "sigmoid|invSigmoid|erf|erfc|" +
+ "random(?:Uniform|Integer|Gauss|Poisson|Binomial)|" +
+ "gaussP|gaussQ|invGaussQ|incompleteGammaP|incompleteBeta|" +
+ "chiSquareP|chiSquareQ|invChiSquareQ|studentP|studentQ|invStudentQ|" +
+ "fisherP|fisherQ|invFisherQ|" +
+ "binomialP|binomialQ|invBinomialP|invBinomialQ|" +
+ "hertzToBark|barkToHerz|" +
+ "hertzToMel|melToHertz|" +
+ "hertzToSemitones|semitonesToHerz|" +
+ "erb|hertzToErb|erbToHertz|" +
+ "phonToDifferenceLimens|differenceLimensToPhon|" +
+ "soundPressureToPhon|" +
+ "beta|beta2|besselI|besselK|" +
+ "numberOfColumns|numberOfRows|" +
+ "selected|selected\\$|numberOfSelected|variableExists|"+
+ "index|rindex|startsWith|endsWith|"+
+ "index_regex|rindex_regex|replace_regex\\$|"+
+ "length|extractWord\\$|extractLine\\$|extractNumber|" +
+ "left\\$|right\\$|mid\\$|replace\\$|" +
+ "date\\$|fixed\\$|percent\\$|" +
+ "zero#|linear#|randomUniform#|randomInteger#|randomGauss#|" +
+ "beginPause|endPause|" +
+ "demoShow|demoWindowTitle|demoInput|demoWaitForInput|" +
+ "demoClicked|demoClickedIn|demoX|demoY|" +
+ "demoKeyPressed|demoKey\\$|" +
+ "demoExtraControlKeyPressed|demoShiftKeyPressed|"+
+ "demoCommandKeyPressed|demoOptionKeyPressed|" +
+ "environment\\$|chooseReadFile\\$|" +
+ "chooseDirectory\\$|createDirectory|fileReadable|deleteFile|" +
+ "selectObject|removeObject|plusObject|minusObject|" +
+ "runScript|exitScript|" +
+ "beginSendPraat|endSendPraat|" +
+ "objectsAreIdentical"
+ );
+
+ var objectTypes = (
+ "Activation|AffineTransform|AmplitudeTier|Art|Artword|Autosegment|" +
+ "BarkFilter|CCA|Categories|Cepstrum|Cepstrumc|ChebyshevSeries|" +
+ "ClassificationTable|Cochleagram|Collection|Configuration|" +
+ "Confusion|ContingencyTable|Corpus|Correlation|Covariance|" +
+ "CrossCorrelationTable|CrossCorrelationTables|DTW|Diagonalizer|" +
+ "Discriminant|Dissimilarity|Distance|Distributions|DurationTier|" +
+ "EEG|ERP|ERPTier|Eigen|Excitation|Excitations|ExperimentMFC|FFNet|" +
+ "FeatureWeights|Formant|FormantFilter|FormantGrid|FormantPoint|" +
+ "FormantTier|GaussianMixture|HMM|HMM_Observation|" +
+ "HMM_ObservationSequence|HMM_State|HMM_StateSequence|Harmonicity|" +
+ "ISpline|Index|Intensity|IntensityTier|IntervalTier|KNN|KlattGrid|" +
+ "KlattTable|LFCC|LPC|Label|LegendreSeries|LinearRegression|" +
+ "LogisticRegression|LongSound|Ltas|MFCC|MSpline|ManPages|" +
+ "Manipulation|Matrix|MelFilter|MixingMatrix|Movie|Network|" +
+ "OTGrammar|OTHistory|OTMulti|PCA|PairDistribution|ParamCurve|" +
+ "Pattern|Permutation|Pitch|PitchTier|PointProcess|Polygon|" +
+ "Polynomial|Procrustes|RealPoint|RealTier|ResultsMFC|Roots|SPINET|" +
+ "SSCP|SVD|Salience|ScalarProduct|Similarity|SimpleString|" +
+ "SortedSetOfString|Sound|Speaker|Spectrogram|Spectrum|SpectrumTier|" +
+ "SpeechSynthesizer|SpellingChecker|Strings|StringsIndex|Table|" +
+ "TableOfReal|TextGrid|TextInterval|TextPoint|TextTier|Tier|" +
+ "Transition|VocalTract|Weight|WordList"
+ );
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "string.interpolated",
+ regex : /'((?:[a-z][a-zA-Z0-9_]*)(?:\$|#|:[0-9]+)?)'/
+ }, {
+ token : ["text", "text", "keyword.operator", "text", "keyword"],
+ regex : /(^\s*)(?:([a-z][a-zA-Z0-9_]*\$?\s+)(=)(\s+))?(stopwatch)/
+ }, {
+ token : ["text", "keyword", "text", "string"],
+ regex : /(^\s*)(print(?:line|tab)?|echo|exit|pause|send(?:praat|socket)|include|execute|system(?:_nocheck)?)(\s+)(.*)/
+ }, {
+ token : ["text", "keyword"],
+ regex : "(^\\s*)(" + directives + ")$"
+ }, {
+ token : ["text", "keyword.operator", "text"],
+ regex : /(\s+)((?:\+|-|\/|\*|<|>)=?|==?|!=|%|\^|\||and|or|not)(\s+)/
+ }, {
+ token : ["text", "text", "keyword.operator", "text", "keyword", "text", "keyword"],
+ regex : /(^\s*)(?:([a-z][a-zA-Z0-9_]*\$?\s+)(=)(\s+))?(?:((?:no)?warn|(?:unix_)?nocheck|noprogress)(\s+))?((?:[A-Z][^.:"]+)(?:$|(?:\.{3}|:)))/
+ }, {
+ token : ["text", "keyword", "text", "keyword"],
+ regex : /(^\s*)(?:(demo)?(\s+))((?:[A-Z][^.:"]+)(?:$|(?:\.{3}|:)))/
+ }, {
+ token : ["text", "keyword", "text", "keyword"],
+ regex : /^(\s*)(?:(demo)(\s+))?(10|12|14|16|24)$/
+ }, {
+ token : ["text", "support.function", "text"],
+ regex : /(\s*)(do\$?)(\s*:\s*|\s*\(\s*)/
+ }, {
+ token : "entity.name.type",
+ regex : "(" + objectTypes + ")"
+ }, {
+ token : "variable.language",
+ regex : "(" + predefinedVariables + ")"
+ }, {
+ token : ["support.function", "text"],
+ regex : "((?:" + functions + ")\\$?)(\\s*(?::|\\())"
+ }, {
+ token : "keyword",
+ regex : /(\bfor\b)/,
+ next : "for"
+ }, {
+ token : "keyword",
+ regex : "(\\b(?:" + keywords + ")\\b)"
+ }, {
+ token : "string",
+ regex : /"[^"]*"/
+ }, {
+ token : "string",
+ regex : /"[^"]*$/,
+ next : "brokenstring"
+ }, {
+ token : ["text", "keyword", "text", "entity.name.section"],
+ regex : /(^\s*)(\bform\b)(\s+)(.*)/,
+ next : "form"
+ }, {
+ token : "constant.numeric",
+ regex : /\b[+-]?\d+(?:(?:\.\d*)?(?:[eE][+-]?\d+)?)?\b/
+ }, {
+ token : ["keyword", "text", "entity.name.function"],
+ regex : /(procedure)(\s+)(\S+)/
+ }, {
+ token : ["entity.name.function", "text"],
+ regex : /(@\S+)(:|\s*\()/
+ }, {
+ token : ["text", "keyword", "text", "entity.name.function"],
+ regex : /(^\s*)(call)(\s+)(\S+)/
+ }, {
+ token : "comment",
+ regex : /(^\s*#|;).*$/
+ }, {
+ token : "text",
+ regex : /\s+/
+ }
+ ],
+ "form" : [
+ {
+ token : ["keyword", "text", "constant.numeric"],
+ regex : /((?:optionmenu|choice)\s+)(\S+:\s+)([0-9]+)/
+ }, {
+ token : ["keyword", "constant.numeric"],
+ regex : /((?:option|button)\s+)([+-]?\d+(?:(?:\.\d*)?(?:[eE][+-]?\d+)?)?\b)/
+ }, {
+ token : ["keyword", "string"],
+ regex : /((?:option|button)\s+)(.*)/
+ }, {
+ token : ["keyword", "text", "string"],
+ regex : /((?:sentence|text)\s+)(\S+\s*)(.*)/
+ }, {
+ token : ["keyword", "text", "string", "invalid.illegal"],
+ regex : /(word\s+)(\S+\s*)(\S+)?(\s.*)?/
+ }, {
+ token : ["keyword", "text", "constant.language"],
+ regex : /(boolean\s+)(\S+\s*)(0|1|"?(?:yes|no)"?)/
+ }, {
+ token : ["keyword", "text", "constant.numeric"],
+ regex : /((?:real|natural|positive|integer)\s+)(\S+\s*)([+-]?\d+(?:(?:\.\d*)?(?:[eE][+-]?\d+)?)?\b)/
+ }, {
+ token : ["keyword", "string"],
+ regex : /(comment\s+)(.*)/
+ }, {
+ token : "keyword",
+ regex : 'endform',
+ next : "start"
+ }
+ ],
+ "for" : [
+ {
+ token : ["keyword", "text", "constant.numeric", "text"],
+ regex : /(from|to)(\s+)([+-]?\d+(?:(?:\.\d*)?(?:[eE][+-]?\d+)?)?)(\s*)/
+ }, {
+ token : ["keyword", "text"],
+ regex : /(from|to)(\s+\S+\s*)/
+ }, {
+ token : "text",
+ regex : /$/,
+ next : "start"
+ }
+ ],
+ "brokenstring" : [
+ {
+ token : ["text", "string"],
+ regex : /(\s*\.{3})([^"]*)/
+ }, {
+ token : "string",
+ regex : /"/,
+ next : "start"
+ }
+ ]
+ };
+};
+
+oop.inherits(PraatHighlightRules, TextHighlightRules);
+
+exports.PraatHighlightRules = PraatHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/praat",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/praat_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PraatHighlightRules = require("./praat_highlight_rules").PraatHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = PraatHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/praat";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-prolog.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-prolog.js
new file mode 100644
index 00000000..6bf01adb
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-prolog.js
@@ -0,0 +1,364 @@
+ace.define("ace/mode/prolog_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PrologHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { include: '#comment' },
+ { include: '#basic_fact' },
+ { include: '#rule' },
+ { include: '#directive' },
+ { include: '#fact' } ],
+ '#atom':
+ [ { token: 'constant.other.atom.prolog',
+ regex: '\\b[a-z][a-zA-Z0-9_]*\\b' },
+ { token: 'constant.numeric.prolog',
+ regex: '-?\\d+(?:\\.\\d+)?' },
+ { include: '#string' } ],
+ '#basic_elem':
+ [ { include: '#comment' },
+ { include: '#statement' },
+ { include: '#constants' },
+ { include: '#operators' },
+ { include: '#builtins' },
+ { include: '#list' },
+ { include: '#atom' },
+ { include: '#variable' } ],
+ '#basic_fact':
+ [ { token:
+ [ 'entity.name.function.fact.basic.prolog',
+ 'punctuation.end.fact.basic.prolog' ],
+ regex: '([a-z]\\w*)(\\.)' } ],
+ '#builtins':
+ [ { token: 'support.function.builtin.prolog',
+ regex: '\\b(?:abolish|abort|ancestors|arg|ascii|assert[az]|atom(?:ic)?|body|char|close|conc|concat|consult|define|definition|dynamic|dump|fail|file|free|free_proc|functor|getc|goal|halt|head|head|integer|length|listing|match_args|member|next_clause|nl|nonvar|nth|number|cvars|nvars|offset|op|print?|prompt|putc|quoted|ratom|read|redefine|rename|retract(?:all)?|see|seeing|seen|skip|spy|statistics|system|tab|tell|telling|term|time|told|univ|unlink_clause|unspy_predicate|var|write)\\b' } ],
+ '#comment':
+ [ { token:
+ [ 'punctuation.definition.comment.prolog',
+ 'comment.line.percentage.prolog' ],
+ regex: '(%)(.*$)' },
+ { token: 'punctuation.definition.comment.prolog',
+ regex: '/\\*',
+ push:
+ [ { token: 'punctuation.definition.comment.prolog',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.prolog' } ] } ],
+ '#constants':
+ [ { token: 'constant.language.prolog',
+ regex: '\\b(?:true|false|yes|no)\\b' } ],
+ '#directive':
+ [ { token: 'keyword.operator.directive.prolog',
+ regex: ':-',
+ push:
+ [ { token: 'meta.directive.prolog', regex: '\\.', next: 'pop' },
+ { include: '#comment' },
+ { include: '#statement' },
+ { defaultToken: 'meta.directive.prolog' } ] } ],
+ '#expr':
+ [ { include: '#comments' },
+ { token: 'meta.expression.prolog',
+ regex: '\\(',
+ push:
+ [ { token: 'meta.expression.prolog', regex: '\\)', next: 'pop' },
+ { include: '#expr' },
+ { defaultToken: 'meta.expression.prolog' } ] },
+ { token: 'keyword.control.cutoff.prolog', regex: '!' },
+ { token: 'punctuation.control.and.prolog', regex: ',' },
+ { token: 'punctuation.control.or.prolog', regex: ';' },
+ { include: '#basic_elem' } ],
+ '#fact':
+ [ { token:
+ [ 'entity.name.function.fact.prolog',
+ 'punctuation.begin.fact.parameters.prolog' ],
+ regex: '([a-z]\\w*)(\\()(?!.*:-)',
+ push:
+ [ { token:
+ [ 'punctuation.end.fact.parameters.prolog',
+ 'punctuation.end.fact.prolog' ],
+ regex: '(\\))(\\.?)',
+ next: 'pop' },
+ { include: '#parameter' },
+ { defaultToken: 'meta.fact.prolog' } ] } ],
+ '#list':
+ [ { token: 'punctuation.begin.list.prolog',
+ regex: '\\[(?=.*\\])',
+ push:
+ [ { token: 'punctuation.end.list.prolog',
+ regex: '\\]',
+ next: 'pop' },
+ { include: '#comment' },
+ { token: 'punctuation.separator.list.prolog', regex: ',' },
+ { token: 'punctuation.concat.list.prolog',
+ regex: '\\|',
+ push:
+ [ { token: 'meta.list.concat.prolog',
+ regex: '(?=\\s*\\])',
+ next: 'pop' },
+ { include: '#basic_elem' },
+ { defaultToken: 'meta.list.concat.prolog' } ] },
+ { include: '#basic_elem' },
+ { defaultToken: 'meta.list.prolog' } ] } ],
+ '#operators':
+ [ { token: 'keyword.operator.prolog',
+ regex: '\\\\\\+|\\bnot\\b|\\bis\\b|->|[><]|[><\\\\:=]?=|(?:=\\\\|\\\\=)=' } ],
+ '#parameter':
+ [ { token: 'variable.language.anonymous.prolog',
+ regex: '\\b_\\b' },
+ { token: 'variable.parameter.prolog',
+ regex: '\\b[A-Z_]\\w*\\b' },
+ { token: 'punctuation.separator.parameters.prolog', regex: ',' },
+ { include: '#basic_elem' },
+ { token: 'text', regex: '[^\\s]' } ],
+ '#rule':
+ [ { token: 'meta.rule.prolog',
+ regex: '(?=[a-z]\\w*.*:-)',
+ push:
+ [ { token: 'punctuation.rule.end.prolog',
+ regex: '\\.',
+ next: 'pop' },
+ { token: 'meta.rule.signature.prolog',
+ regex: '(?=[a-z]\\w*.*:-)',
+ push:
+ [ { token: 'meta.rule.signature.prolog',
+ regex: '(?=:-)',
+ next: 'pop' },
+ { token: 'entity.name.function.rule.prolog',
+ regex: '[a-z]\\w*(?=\\(|\\s*:-)' },
+ { token: 'punctuation.rule.parameters.begin.prolog',
+ regex: '\\(',
+ push:
+ [ { token: 'punctuation.rule.parameters.end.prolog',
+ regex: '\\)',
+ next: 'pop' },
+ { include: '#parameter' },
+ { defaultToken: 'meta.rule.parameters.prolog' } ] },
+ { defaultToken: 'meta.rule.signature.prolog' } ] },
+ { token: 'keyword.operator.definition.prolog',
+ regex: ':-',
+ push:
+ [ { token: 'meta.rule.definition.prolog',
+ regex: '(?=\\.)',
+ next: 'pop' },
+ { include: '#comment' },
+ { include: '#expr' },
+ { defaultToken: 'meta.rule.definition.prolog' } ] },
+ { defaultToken: 'meta.rule.prolog' } ] } ],
+ '#statement':
+ [ { token: 'meta.statement.prolog',
+ regex: '(?=[a-z]\\w*\\()',
+ push:
+ [ { token: 'punctuation.end.statement.parameters.prolog',
+ regex: '\\)',
+ next: 'pop' },
+ { include: '#builtins' },
+ { include: '#atom' },
+ { token: 'punctuation.begin.statement.parameters.prolog',
+ regex: '\\(',
+ push:
+ [ { token: 'meta.statement.parameters.prolog',
+ regex: '(?=\\))',
+ next: 'pop' },
+ { token: 'punctuation.separator.statement.prolog', regex: ',' },
+ { include: '#basic_elem' },
+ { defaultToken: 'meta.statement.parameters.prolog' } ] },
+ { defaultToken: 'meta.statement.prolog' } ] } ],
+ '#string':
+ [ { token: 'punctuation.definition.string.begin.prolog',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.prolog',
+ regex: '\'',
+ next: 'pop' },
+ { token: 'constant.character.escape.prolog', regex: '\\\\.' },
+ { token: 'constant.character.escape.quote.prolog',
+ regex: '\'\'' },
+ { defaultToken: 'string.quoted.single.prolog' } ] } ],
+ '#variable':
+ [ { token: 'variable.language.anonymous.prolog',
+ regex: '\\b_\\b' },
+ { token: 'variable.other.prolog',
+ regex: '\\b[A-Z_][a-zA-Z0-9_]*\\b' } ] }
+
+ this.normalizeRules();
+};
+
+PrologHighlightRules.metaData = { fileTypes: [ 'plg', 'prolog' ],
+ foldingStartMarker: '(%\\s*region \\w*)|([a-z]\\w*.*:- ?)',
+ foldingStopMarker: '(%\\s*end(\\s*region)?)|(?=\\.)',
+ keyEquivalent: '^~P',
+ name: 'Prolog',
+ scopeName: 'source.prolog' }
+
+
+oop.inherits(PrologHighlightRules, TextHighlightRules);
+
+exports.PrologHighlightRules = PrologHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/prolog",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/prolog_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PrologHighlightRules = require("./prolog_highlight_rules").PrologHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = PrologHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "%";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/prolog";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-properties.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-properties.js
new file mode 100644
index 00000000..2e9ba725
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-properties.js
@@ -0,0 +1,73 @@
+ace.define("ace/mode/properties_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PropertiesHighlightRules = function() {
+
+ var escapeRe = /\\u[0-9a-fA-F]{4}|\\/;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : /[!#].*$/
+ }, {
+ token : "keyword",
+ regex : /[=:]$/
+ }, {
+ token : "keyword",
+ regex : /[=:]/,
+ next : "value"
+ }, {
+ token : "constant.language.escape",
+ regex : escapeRe
+ }, {
+ defaultToken: "variable"
+ }
+ ],
+ "value" : [
+ {
+ regex : /\\$/,
+ token : "string",
+ next : "value"
+ }, {
+ regex : /$/,
+ token : "string",
+ next : "start"
+ }, {
+ token : "constant.language.escape",
+ regex : escapeRe
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+};
+
+oop.inherits(PropertiesHighlightRules, TextHighlightRules);
+
+exports.PropertiesHighlightRules = PropertiesHighlightRules;
+});
+
+ace.define("ace/mode/properties",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/properties_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PropertiesHighlightRules = require("./properties_highlight_rules").PropertiesHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = PropertiesHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$id = "ace/mode/properties";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-protobuf.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-protobuf.js
new file mode 100644
index 00000000..8cef6576
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-protobuf.js
@@ -0,0 +1,577 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/c_cpp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var cFunctions = exports.cFunctions = "\\b(?:hypot(?:f|l)?|s(?:scanf|ystem|nprintf|ca(?:nf|lb(?:n(?:f|l)?|ln(?:f|l)?))|i(?:n(?:h(?:f|l)?|f|l)?|gn(?:al|bit))|tr(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?)|error|pbrk|ftime|len|rchr|xfrm)|printf|et(?:jmp|vbuf|locale|buf)|qrt(?:f|l)?|w(?:scanf|printf)|rand)|n(?:e(?:arbyint(?:f|l)?|xt(?:toward(?:f|l)?|after(?:f|l)?))|an(?:f|l)?)|c(?:s(?:in(?:h(?:f|l)?|f|l)?|qrt(?:f|l)?)|cos(?:h(?:f)?|f|l)?|imag(?:f|l)?|t(?:ime|an(?:h(?:f|l)?|f|l)?)|o(?:s(?:h(?:f|l)?|f|l)?|nj(?:f|l)?|pysign(?:f|l)?)|p(?:ow(?:f|l)?|roj(?:f|l)?)|e(?:il(?:f|l)?|xp(?:f|l)?)|l(?:o(?:ck|g(?:f|l)?)|earerr)|a(?:sin(?:h(?:f|l)?|f|l)?|cos(?:h(?:f|l)?|f|l)?|tan(?:h(?:f|l)?|f|l)?|lloc|rg(?:f|l)?|bs(?:f|l)?)|real(?:f|l)?|brt(?:f|l)?)|t(?:ime|o(?:upper|lower)|an(?:h(?:f|l)?|f|l)?|runc(?:f|l)?|gamma(?:f|l)?|mp(?:nam|file))|i(?:s(?:space|n(?:ormal|an)|cntrl|inf|digit|u(?:nordered|pper)|p(?:unct|rint)|finite|w(?:space|c(?:ntrl|type)|digit|upper|p(?:unct|rint)|lower|al(?:num|pha)|graph|xdigit|blank)|l(?:ower|ess(?:equal|greater)?)|al(?:num|pha)|gr(?:eater(?:equal)?|aph)|xdigit|blank)|logb(?:f|l)?|max(?:div|abs))|di(?:v|fftime)|_Exit|unget(?:c|wc)|p(?:ow(?:f|l)?|ut(?:s|c(?:har)?|wc(?:har)?)|error|rintf)|e(?:rf(?:c(?:f|l)?|f|l)?|x(?:it|p(?:2(?:f|l)?|f|l|m1(?:f|l)?)?))|v(?:s(?:scanf|nprintf|canf|printf|w(?:scanf|printf))|printf|f(?:scanf|printf|w(?:scanf|printf))|w(?:scanf|printf)|a_(?:start|copy|end|arg))|qsort|f(?:s(?:canf|e(?:tpos|ek))|close|tell|open|dim(?:f|l)?|p(?:classify|ut(?:s|c|w(?:s|c))|rintf)|e(?:holdexcept|set(?:e(?:nv|xceptflag)|round)|clearexcept|testexcept|of|updateenv|r(?:aiseexcept|ror)|get(?:e(?:nv|xceptflag)|round))|flush|w(?:scanf|ide|printf|rite)|loor(?:f|l)?|abs(?:f|l)?|get(?:s|c|pos|w(?:s|c))|re(?:open|e|ad|xp(?:f|l)?)|m(?:in(?:f|l)?|od(?:f|l)?|a(?:f|l|x(?:f|l)?)?))|l(?:d(?:iv|exp(?:f|l)?)|o(?:ngjmp|cal(?:time|econv)|g(?:1(?:p(?:f|l)?|0(?:f|l)?)|2(?:f|l)?|f|l|b(?:f|l)?)?)|abs|l(?:div|abs|r(?:int(?:f|l)?|ound(?:f|l)?))|r(?:int(?:f|l)?|ound(?:f|l)?)|gamma(?:f|l)?)|w(?:scanf|c(?:s(?:s(?:tr|pn)|nc(?:py|at|mp)|c(?:spn|hr|oll|py|at|mp)|to(?:imax|d|u(?:l(?:l)?|max)|k|f|l(?:d|l)?|mbs)|pbrk|ftime|len|r(?:chr|tombs)|xfrm)|to(?:b|mb)|rtomb)|printf|mem(?:set|c(?:hr|py|mp)|move))|a(?:s(?:sert|ctime|in(?:h(?:f|l)?|f|l)?)|cos(?:h(?:f|l)?|f|l)?|t(?:o(?:i|f|l(?:l)?)|exit|an(?:h(?:f|l)?|2(?:f|l)?|f|l)?)|b(?:s|ort))|g(?:et(?:s|c(?:har)?|env|wc(?:har)?)|mtime)|r(?:int(?:f|l)?|ound(?:f|l)?|e(?:name|alloc|wind|m(?:ove|quo(?:f|l)?|ainder(?:f|l)?))|a(?:nd|ise))|b(?:search|towc)|m(?:odf(?:f|l)?|em(?:set|c(?:hr|py|mp)|move)|ktime|alloc|b(?:s(?:init|towcs|rtowcs)|towc|len|r(?:towc|len))))\\b"
+
+var c_cppHighlightRules = function() {
+
+ var keywordControls = (
+ "break|case|continue|default|do|else|for|goto|if|_Pragma|" +
+ "return|switch|while|catch|operator|try|throw|using"
+ );
+
+ var storageType = (
+ "asm|__asm__|auto|bool|_Bool|char|_Complex|double|enum|float|" +
+ "_Imaginary|int|long|short|signed|struct|typedef|union|unsigned|void|" +
+ "class|wchar_t|template|char16_t|char32_t"
+ );
+
+ var storageModifiers = (
+ "const|extern|register|restrict|static|volatile|inline|private|" +
+ "protected|public|friend|explicit|virtual|export|mutable|typename|" +
+ "constexpr|new|delete|alignas|alignof|decltype|noexcept|thread_local"
+ );
+
+ var keywordOperators = (
+ "and|and_eq|bitand|bitor|compl|not|not_eq|or|or_eq|typeid|xor|xor_eq" +
+ "const_cast|dynamic_cast|reinterpret_cast|static_cast|sizeof|namespace"
+ );
+
+ var builtinConstants = (
+ "NULL|true|false|TRUE|FALSE|nullptr"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword.control" : keywordControls,
+ "storage.type" : storageType,
+ "storage.modifier" : storageModifiers,
+ "keyword.operator" : keywordOperators,
+ "variable.language": "this",
+ "constant.language": builtinConstants
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+ var escapeRe = /\\(?:['"?\\abfnrtv]|[0-7]{1,3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}U[a-fA-F\d]{8}|.)/.source;
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "//$",
+ next : "start"
+ }, {
+ token : "comment",
+ regex : "//",
+ next : "singleLineComment"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : "'(?:" + escapeRe + "|.)?'"
+ }, {
+ token : "string.start",
+ regex : '"',
+ stateName: "qqstring",
+ next: [
+ { token: "string", regex: /\\\s*$/, next: "qqstring" },
+ { token: "constant.language.escape", regex: escapeRe },
+ { token: "constant.language.escape", regex: /%[^'"\\]/ },
+ { token: "string.end", regex: '"|$', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "string.start",
+ regex : 'R"\\(',
+ stateName: "rawString",
+ next: [
+ { token: "string.end", regex: '\\)"', next: "start" },
+ { defaultToken: "string"}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "#\\s*(?:include|import|pragma|line|define|undef)\\b",
+ next : "directive"
+ }, {
+ token : "keyword", // special case pre-compiler directive
+ regex : "#\\s*(?:endif|if|ifdef|else|elif|ifndef)\\b"
+ }, {
+ token : "support.function.C99.c",
+ regex : cFunctions
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*"
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|<<=|>>=|>>>=|<>|&&|\|\||\?:|[*%\/+\-&\^|~!<>=]=?/
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "singleLineComment" : [
+ {
+ token : "comment",
+ regex : /\\$/,
+ next : "singleLineComment"
+ }, {
+ token : "comment",
+ regex : /$/,
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ],
+ "directive" : [
+ {
+ token : "constant.other.multiline",
+ regex : /\\/
+ },
+ {
+ token : "constant.other.multiline",
+ regex : /.*\\/
+ },
+ {
+ token : "constant.other",
+ regex : "\\s*<.+?>",
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : '\\s*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]',
+ next : "start"
+ },
+ {
+ token : "constant.other", // single line
+ regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
+ next : "start"
+ },
+ {
+ token : "constant.other",
+ regex : /[^\\\/]+/,
+ next : "start"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(c_cppHighlightRules, TextHighlightRules);
+
+exports.c_cppHighlightRules = c_cppHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/c_cpp",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/c_cpp_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var c_cppHighlightRules = require("./c_cpp_highlight_rules").c_cppHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = c_cppHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/c_cpp";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/protobuf_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+ "use strict";
+
+ var oop = require("../lib/oop");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+ var ProtobufHighlightRules = function() {
+
+ var builtinTypes = "double|float|int32|int64|uint32|uint64|sint32|" +
+ "sint64|fixed32|fixed64|sfixed32|sfixed64|bool|" +
+ "string|bytes";
+ var keywordDeclaration = "message|required|optional|repeated|package|" +
+ "import|option|enum";
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword.declaration.protobuf": keywordDeclaration,
+ "support.type": builtinTypes
+ }, "identifier");
+
+ this.$rules = {
+ "start": [{
+ token: "comment",
+ regex: /\/\/.*$/
+ }, {
+ token: "comment",
+ regex: /\/\*/,
+ next: "comment"
+ }, {
+ token: "constant",
+ regex: "<[^>]+>"
+ }, {
+ regex: "=",
+ token: "keyword.operator.assignment.protobuf"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : '[\'](?:(?:\\\\.)|(?:[^\'\\\\]))*?[\']'
+ }, {
+ token: "constant.numeric", // hex
+ regex: "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token: "constant.numeric", // float
+ regex: "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token: keywordMapper,
+ regex: "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }],
+ "comment": [{
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }]
+ };
+
+ this.normalizeRules();
+ };
+
+ oop.inherits(ProtobufHighlightRules, TextHighlightRules);
+
+ exports.ProtobufHighlightRules = ProtobufHighlightRules;
+});
+
+ace.define("ace/mode/protobuf",["require","exports","module","ace/lib/oop","ace/mode/c_cpp","ace/mode/protobuf_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var CMode = require("./c_cpp").Mode;
+var ProtobufHighlightRules = require("./protobuf_highlight_rules").ProtobufHighlightRules;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ CMode.call(this);
+ this.foldingRules = new CStyleFoldMode();
+ this.HighlightRules = ProtobufHighlightRules;
+};
+oop.inherits(Mode, CMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/protobuf";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-python.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-python.js
new file mode 100644
index 00000000..19efccb6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-python.js
@@ -0,0 +1,265 @@
+ace.define("ace/mode/python_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var PythonHighlightRules = function() {
+
+ var keywords = (
+ "and|as|assert|break|class|continue|def|del|elif|else|except|exec|" +
+ "finally|for|from|global|if|import|in|is|lambda|not|or|pass|print|" +
+ "raise|return|try|while|with|yield"
+ );
+
+ var builtinConstants = (
+ "True|False|None|NotImplemented|Ellipsis|__debug__"
+ );
+
+ var builtinFunctions = (
+ "abs|divmod|input|open|staticmethod|all|enumerate|int|ord|str|any|" +
+ "eval|isinstance|pow|sum|basestring|execfile|issubclass|print|super|" +
+ "binfile|iter|property|tuple|bool|filter|len|range|type|bytearray|" +
+ "float|list|raw_input|unichr|callable|format|locals|reduce|unicode|" +
+ "chr|frozenset|long|reload|vars|classmethod|getattr|map|repr|xrange|" +
+ "cmp|globals|max|reversed|zip|compile|hasattr|memoryview|round|" +
+ "__import__|complex|hash|min|set|apply|delattr|help|next|setattr|" +
+ "buffer|dict|hex|object|slice|coerce|dir|id|oct|sorted|intern"
+ );
+ var keywordMapper = this.createKeywordMapper({
+ "invalid.deprecated": "debugger",
+ "support.function": builtinFunctions,
+ "constant.language": builtinConstants,
+ "keyword": keywords
+ }, "identifier");
+
+ var strPre = "(?:r|u|ur|R|U|UR|Ur|uR)?";
+
+ var decimalInteger = "(?:(?:[1-9]\\d*)|(?:0))";
+ var octInteger = "(?:0[oO]?[0-7]+)";
+ var hexInteger = "(?:0[xX][\\dA-Fa-f]+)";
+ var binInteger = "(?:0[bB][01]+)";
+ var integer = "(?:" + decimalInteger + "|" + octInteger + "|" + hexInteger + "|" + binInteger + ")";
+
+ var exponent = "(?:[eE][+-]?\\d+)";
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + exponent + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+
+ var stringEscape = "\\\\(x[0-9A-Fa-f]{2}|[0-7]{3}|[\\\\abfnrtv'\"]|U[0-9A-Fa-f]{8}|u[0-9A-Fa-f]{4})";
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "string", // multi line """ string start
+ regex : strPre + '"{3}',
+ next : "qqstring3"
+ }, {
+ token : "string", // " string
+ regex : strPre + '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "string", // multi line ''' string start
+ regex : strPre + "'{3}",
+ next : "qstring3"
+ }, {
+ token : "string", // ' string
+ regex : strPre + "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // imaginary
+ regex : "(?:" + floatNumber + "|\\d+)[jJ]\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // long integer
+ regex : integer + "[lL]\\b"
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|%|<<|>>|&|\\||\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]\\)\\}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ],
+ "qqstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line """ string end
+ regex : '"{3}',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ } ],
+ "qstring3" : [ {
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string", // multi line ''' string end
+ regex : "'{3}",
+ next : "start"
+ }, {
+ defaultToken : "string"
+ } ],
+ "qqstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }],
+ "qstring" : [{
+ token : "constant.language.escape",
+ regex : stringEscape
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "start"
+ }, {
+ defaultToken: "string"
+ }]
+ };
+};
+
+oop.inherits(PythonHighlightRules, TextHighlightRules);
+
+exports.PythonHighlightRules = PythonHighlightRules;
+});
+
+ace.define("ace/mode/folding/pythonic",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(markers) {
+ this.foldingStartMarker = new RegExp("([\\[{])(?:\\s*)$|(" + markers + ")(?:\\s*)(?:#.*)?$");
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, match.index);
+ if (match[2])
+ return this.indentationBlock(session, row, match.index + match[2].length);
+ return this.indentationBlock(session, row);
+ }
+ }
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/python",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/python_highlight_rules","ace/mode/folding/pythonic","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var PythonHighlightRules = require("./python_highlight_rules").PythonHighlightRules;
+var PythonFoldMode = require("./folding/pythonic").FoldMode;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = PythonHighlightRules;
+ this.foldingRules = new PythonFoldMode("\\:");
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ var outdents = {
+ "pass": 1,
+ "return": 1,
+ "raise": 1,
+ "break": 1,
+ "continue": 1
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input !== "\r\n" && input !== "\r" && input !== "\n")
+ return false;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens)
+ return false;
+ do {
+ var last = tokens.pop();
+ } while (last && (last.type == "comment" || (last.type == "text" && last.value.match(/^\s+$/))));
+
+ if (!last)
+ return false;
+
+ return (last.type == "keyword" && outdents[last.value]);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+
+ row += 1;
+ var indent = this.$getIndent(doc.getLine(row));
+ var tab = doc.getTabString();
+ if (indent.slice(-tab.length) == tab)
+ doc.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ };
+
+ this.$id = "ace/mode/python";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-r.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-r.js
new file mode 100644
index 00000000..297d7e05
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-r.js
@@ -0,0 +1,301 @@
+ace.define("ace/mode/tex_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TexHighlightRules = function(textClass) {
+
+ if (!textClass)
+ textClass = "text";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : textClass, // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b",
+ next : "nospell"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])}]"
+ }, {
+ token : textClass,
+ regex : "\\s+"
+ }
+ ],
+ "nospell" : [
+ {
+ token : "comment",
+ regex : "%.*$",
+ next : "start"
+ }, {
+ token : "nospell." + textClass, // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])",
+ next : "start"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "}",
+ next : "start"
+ }, {
+ token : "nospell." + textClass,
+ regex : "\\s+"
+ }, {
+ token : "nospell." + textClass,
+ regex : "\\w+"
+ }
+ ]
+ };
+};
+
+oop.inherits(TexHighlightRules, TextHighlightRules);
+
+exports.TexHighlightRules = TexHighlightRules;
+});
+
+ace.define("ace/mode/r_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/tex_highlight_rules"], function(require, exports, module)
+{
+
+ var oop = require("../lib/oop");
+ var lang = require("../lib/lang");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+ var TexHighlightRules = require("./tex_highlight_rules").TexHighlightRules;
+
+ var RHighlightRules = function()
+ {
+
+ var keywords = lang.arrayToMap(
+ ("function|if|in|break|next|repeat|else|for|return|switch|while|try|tryCatch|stop|warning|require|library|attach|detach|source|setMethod|setGeneric|setGroupGeneric|setClass")
+ .split("|")
+ );
+
+ var buildinConstants = lang.arrayToMap(
+ ("NULL|NA|TRUE|FALSE|T|F|Inf|NaN|NA_integer_|NA_real_|NA_character_|" +
+ "NA_complex_").split("|")
+ );
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment.sectionhead",
+ regex : "#+(?!').*(?:----|====|####)\\s*$"
+ },
+ {
+ token : "comment",
+ regex : "#+'",
+ next : "rd-start"
+ },
+ {
+ token : "comment",
+ regex : "#.*$"
+ },
+ {
+ token : "string", // multi line string start
+ regex : '["]',
+ next : "qqstring"
+ },
+ {
+ token : "string", // multi line string start
+ regex : "[']",
+ next : "qstring"
+ },
+ {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+[Li]?\\b"
+ },
+ {
+ token : "constant.numeric", // explicit integer
+ regex : "\\d+L\\b"
+ },
+ {
+ token : "constant.numeric", // number
+ regex : "\\d+(?:\\.\\d*)?(?:[eE][+\\-]?\\d*)?i?\\b"
+ },
+ {
+ token : "constant.numeric", // number with leading decimal
+ regex : "\\.\\d+(?:[eE][+\\-]?\\d*)?i?\\b"
+ },
+ {
+ token : "constant.language.boolean",
+ regex : "(?:TRUE|FALSE|T|F)\\b"
+ },
+ {
+ token : "identifier",
+ regex : "`.*?`"
+ },
+ {
+ onMatch : function(value) {
+ if (keywords[value])
+ return "keyword";
+ else if (buildinConstants[value])
+ return "constant.language";
+ else if (value == '...' || value.match(/^\.\.\d+$/))
+ return "variable.language";
+ else
+ return "identifier";
+ },
+ regex : "[a-zA-Z.][a-zA-Z0-9._]*\\b"
+ },
+ {
+ token : "keyword.operator",
+ regex : "%%|>=|<=|==|!=|\\->|<\\-|\\|\\||&&|=|\\+|\\-|\\*|/|\\^|>|<|!|&|\\||~|\\$|:"
+ },
+ {
+ token : "keyword.operator", // infix operators
+ regex : "%.*?%"
+ },
+ {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ },
+ {
+ token : "paren.keyword.operator",
+ regex : "[\\])}]"
+ },
+ {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ },
+ {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ },
+ {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+
+ var rdRules = new TexHighlightRules("comment").getRules();
+ for (var i = 0; i < rdRules["start"].length; i++) {
+ rdRules["start"][i].token += ".virtual-comment";
+ }
+
+ this.addRules(rdRules, "rd-");
+ this.$rules["rd-start"].unshift({
+ token: "text",
+ regex: "^",
+ next: "start"
+ });
+ this.$rules["rd-start"].unshift({
+ token : "keyword",
+ regex : "@(?!@)[^ ]*"
+ });
+ this.$rules["rd-start"].unshift({
+ token : "comment",
+ regex : "@@"
+ });
+ this.$rules["rd-start"].push({
+ token : "comment",
+ regex : "[^%\\\\[({\\])}]+"
+ });
+ };
+
+ oop.inherits(RHighlightRules, TextHighlightRules);
+
+ exports.RHighlightRules = RHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/r",["require","exports","module","ace/range","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/r_highlight_rules","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+ "use strict";
+
+ var Range = require("../range").Range;
+ var oop = require("../lib/oop");
+ var TextMode = require("./text").Mode;
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+ var RHighlightRules = require("./r_highlight_rules").RHighlightRules;
+ var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+ var Mode = function(){
+ this.HighlightRules = RHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+ };
+ oop.inherits(Mode, TextMode);
+
+ (function()
+ {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/r";
+ }).call(Mode.prototype);
+ exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-razor.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-razor.js
new file mode 100644
index 00000000..c19ec55f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-razor.js
@@ -0,0 +1,2845 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/csharp_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var CSharpHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": "abstract|event|new|struct|as|explicit|null|switch|base|extern|object|this|bool|false|operator|throw|break|finally|out|true|byte|fixed|override|try|case|float|params|typeof|catch|for|private|uint|char|foreach|protected|ulong|checked|goto|public|unchecked|class|if|readonly|unsafe|const|implicit|ref|ushort|continue|in|return|using|decimal|int|sbyte|virtual|default|interface|sealed|volatile|delegate|internal|short|void|do|is|sizeof|while|double|lock|stackalloc|else|long|static|enum|namespace|string|var|dynamic",
+ "constant.language": "null|true|false"
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // character
+ regex : /'(?:.|\\(:?u[\da-fA-F]+|x[\da-fA-F]+|[tbrf'"n]))?'/
+ }, {
+ token : "string", start : '"', end : '"|$', next: [
+ {token: "constant.language.escape", regex: /\\(:?u[\da-fA-F]+|x[\da-fA-F]+|[tbrf'"n])/},
+ {token: "invalid", regex: /\\./}
+ ]
+ }, {
+ token : "string", start : '@"', end : '"', next:[
+ {token: "constant.language.escape", regex: '""'}
+ ]
+ }, {
+ token : "string", start : /\$"/, end : '"|$', next: [
+ {token: "constant.language.escape", regex: /\\(:?$)|{{/},
+ {token: "constant.language.escape", regex: /\\(:?u[\da-fA-F]+|x[\da-fA-F]+|[tbrf'"n])/},
+ {token: "invalid", regex: /\\./}
+ ]
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "keyword",
+ regex : "^\\s*#(if|else|elif|endif|define|undef|warning|error|line|region|endregion|pragma)"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\?|\\:|\\,|\\;|\\."
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+ this.normalizeRules();
+};
+
+oop.inherits(CSharpHighlightRules, TextHighlightRules);
+
+exports.CSharpHighlightRules = CSharpHighlightRules;
+});
+
+ace.define("ace/mode/razor_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/html_highlight_rules","ace/mode/csharp_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var CSharpHighlightRules = require("./csharp_highlight_rules").CSharpHighlightRules;
+
+var blockPrefix = 'razor-block-';
+var RazorLangHighlightRules = function() {
+ CSharpHighlightRules.call(this);
+
+ var processPotentialCallback = function(value, stackItem) {
+ if (typeof stackItem === "function")
+ return stackItem(value);
+
+ return stackItem;
+ };
+
+ var inBraces = 'in-braces';
+ this.$rules.start.unshift({
+ regex: '[\\[({]',
+ onMatch: function(value, state, stack) {
+ var prefix = /razor-[^\-]+-/.exec(state)[0];
+
+ stack.unshift(value);
+ stack.unshift(prefix + inBraces);
+ this.next = prefix + inBraces;
+ return 'paren.lparen';
+ }
+ }, {
+ start: "@\\*",
+ end: "\\*@",
+ token: "comment"
+ });
+
+ var parentCloseMap = {
+ '{': '}',
+ '[': ']',
+ '(': ')'
+ };
+
+ this.$rules[inBraces] = lang.deepCopy(this.$rules.start);
+ this.$rules[inBraces].unshift({
+ regex: '[\\])}]',
+ onMatch: function(value, state, stack) {
+ var open = stack[1];
+ if (parentCloseMap[open] !== value)
+ return 'invalid.illegal';
+
+ stack.shift(); // exit in-braces block
+ stack.shift(); // exit brace marker
+ this.next = processPotentialCallback(value, stack[0]) || 'start';
+ return 'paren.rparen';
+ }
+ });
+};
+
+oop.inherits(RazorLangHighlightRules, CSharpHighlightRules);
+
+var RazorHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var blockStartRule = {
+ regex: '@[({]|@functions{',
+ onMatch: function(value, state, stack) {
+ stack.unshift(value);
+ stack.unshift('razor-block-start');
+ this.next = 'razor-block-start';
+ return 'punctuation.block.razor';
+ }
+ };
+
+ var blockEndMap = {
+ '@{': '}',
+ '@(': ')',
+ '@functions{':'}'
+ };
+
+ var blockEndRule = {
+ regex: '[})]',
+ onMatch: function(value, state, stack) {
+ var blockStart = stack[1];
+ if (blockEndMap[blockStart] !== value)
+ return 'invalid.illegal';
+
+ stack.shift(); // exit razor block
+ stack.shift(); // remove block type marker
+ this.next = stack.shift() || 'start';
+ return 'punctuation.block.razor';
+ }
+ };
+
+ var shortStartRule = {
+ regex: "@(?![{(])",
+ onMatch: function(value, state, stack) {
+ stack.unshift("razor-short-start");
+ this.next = "razor-short-start";
+ return 'punctuation.short.razor';
+ }
+ };
+
+ var shortEndRule = {
+ token: "",
+ regex: "(?=[^A-Za-z_\\.()\\[\\]])",
+ next: 'pop'
+ };
+
+ var ifStartRule = {
+ regex: "@(?=if)",
+ onMatch: function(value, state, stack) {
+ stack.unshift(function(value) {
+ if (value !== '}')
+ return 'start';
+
+ return stack.shift() || 'start';
+ });
+ this.next = 'razor-block-start';
+ return 'punctuation.control.razor';
+ }
+ };
+
+ var razorStartRules = [
+ {
+ start: "@\\*",
+ end: "\\*@",
+ token: "comment"
+ },
+ {
+ token: ["meta.directive.razor", "text", "identifier"],
+ regex: "^(\\s*@model)(\\s+)(.+)$"
+ },
+ blockStartRule,
+ shortStartRule
+ ];
+
+ for (var key in this.$rules)
+ this.$rules[key].unshift.apply(this.$rules[key], razorStartRules);
+
+ this.embedRules(RazorLangHighlightRules, "razor-block-", [blockEndRule], ["start"]);
+ this.embedRules(RazorLangHighlightRules, "razor-short-", [shortEndRule], ["start"]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(RazorHighlightRules, HtmlHighlightRules);
+
+exports.RazorHighlightRules = RazorHighlightRules;
+exports.RazorLangHighlightRules = RazorLangHighlightRules;
+});
+
+ace.define("ace/mode/razor_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var keywords = [
+ "abstract", "as", "base", "bool",
+ "break", "byte", "case", "catch",
+ "char", "checked", "class", "const",
+ "continue", "decimal", "default", "delegate",
+ "do", "double","else","enum",
+ "event", "explicit", "extern", "false",
+ "finally", "fixed", "float", "for",
+ "foreach", "goto", "if", "implicit",
+ "in", "int", "interface", "internal",
+ "is", "lock", "long", "namespace",
+ "new", "null", "object", "operator",
+ "out", "override", "params", "private",
+ "protected", "public", "readonly", "ref",
+ "return", "sbyte", "sealed", "short",
+ "sizeof", "stackalloc", "static", "string",
+ "struct", "switch", "this", "throw",
+ "true", "try", "typeof", "uint",
+ "ulong", "unchecked", "unsafe", "ushort",
+ "using", "var", "virtual", "void",
+ "volatile", "while"];
+
+var shortHands = [
+ "Html", "Model", "Url", "Layout"
+];
+
+var RazorCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+
+ if(state.lastIndexOf("razor-short-start") == -1 && state.lastIndexOf("razor-block-start") == -1)
+ return [];
+
+ var token = session.getTokenAt(pos.row, pos.column);
+ if (!token)
+ return [];
+
+ if(state.lastIndexOf("razor-short-start") != -1) {
+ return this.getShortStartCompletions(state, session, pos, prefix);
+ }
+
+ if(state.lastIndexOf("razor-block-start") != -1) {
+ return this.getKeywordCompletions(state, session, pos, prefix);
+ }
+
+
+ };
+
+ this.getShortStartCompletions = function(state, session, pos, prefix) {
+ return shortHands.map(function(element){
+ return {
+ value: element,
+ meta: "keyword",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getKeywordCompletions = function(state, session, pos, prefix) {
+ return shortHands.concat(keywords).map(function(element){
+ return {
+ value: element,
+ meta: "keyword",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(RazorCompletions.prototype);
+
+exports.RazorCompletions = RazorCompletions;
+
+});
+
+ace.define("ace/mode/razor",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/razor_highlight_rules","ace/mode/razor_completions","ace/mode/html_completions"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var RazorHighlightRules = require("./razor_highlight_rules").RazorHighlightRules;
+var RazorCompletions = require("./razor_completions").RazorCompletions;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.$highlightRules = new RazorHighlightRules();
+ this.$completer = new RazorCompletions();
+ this.$htmlCompleter = new HtmlCompletions();
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.getCompletions = function(state, session, pos, prefix) {
+ var razorToken = this.$completer.getCompletions(state, session, pos, prefix);
+ var htmlToken = this.$htmlCompleter.getCompletions(state, session, pos, prefix);
+ return razorToken.concat(htmlToken);
+ };
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/razor";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-rdoc.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-rdoc.js
new file mode 100644
index 00000000..fe118c48
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-rdoc.js
@@ -0,0 +1,236 @@
+ace.define("ace/mode/latex_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var LatexHighlightRules = function() {
+
+ this.$rules = {
+ "start" : [{
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : ["keyword", "lparen", "variable.parameter", "rparen", "lparen", "storage.type", "rparen"],
+ regex : "(\\\\(?:documentclass|usepackage|input))(?:(\\[)([^\\]]*)(\\]))?({)([^}]*)(})"
+ }, {
+ token : ["keyword","lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\(?:label|v?ref|cite(?:[^{]*)))(?:({)([^}]*)(}))?"
+ }, {
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\begin)({)(verbatim)(})",
+ next : "verbatim"
+ }, {
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\begin)({)(lstlisting)(})",
+ next : "lstlisting"
+ }, {
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\(?:begin|end))({)([\\w*]*)(})"
+ }, {
+ token : "storage.type",
+ regex : /\\verb\b\*?/,
+ next : [{
+ token : ["keyword.operator", "string", "keyword.operator"],
+ regex : "(.)(.*?)(\\1|$)|",
+ next : "start"
+ }]
+ }, {
+ token : "storage.type",
+ regex : "\\\\[a-zA-Z]+"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "constant.character.escape",
+ regex : "\\\\[^a-zA-Z]?"
+ }, {
+ token : "string",
+ regex : "\\${1,2}",
+ next : "equation"
+ }],
+ "equation" : [{
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : "string",
+ regex : "\\${1,2}",
+ next : "start"
+ }, {
+ token : "constant.character.escape",
+ regex : "\\\\(?:[^a-zA-Z]|[a-zA-Z]+)"
+ }, {
+ token : "error",
+ regex : "^\\s*$",
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }],
+ "verbatim": [{
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\end)({)(verbatim)(})",
+ next : "start"
+ }, {
+ defaultToken : "text"
+ }],
+ "lstlisting": [{
+ token : ["storage.type", "lparen", "variable.parameter", "rparen"],
+ regex : "(\\\\end)({)(lstlisting)(})",
+ next : "start"
+ }, {
+ defaultToken : "text"
+ }]
+ };
+
+ this.normalizeRules();
+};
+oop.inherits(LatexHighlightRules, TextHighlightRules);
+
+exports.LatexHighlightRules = LatexHighlightRules;
+
+});
+
+ace.define("ace/mode/rdoc_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/latex_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var LaTeXHighlightRules = require("./latex_highlight_rules");
+
+var RDocHighlightRules = function() {
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : "text", // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:name|alias|method|S3method|S4method|item|code|preformatted|kbd|pkg|var|env|option|command|author|email|url|source|cite|acronym|href|code|preformatted|link|eqn|deqn|keyword|usage|examples|dontrun|dontshow|figure|if|ifelse|Sexpr|RdOpts|inputencoding|usepackage)\\b",
+ next : "nospell"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "nospell" : [
+ {
+ token : "comment",
+ regex : "%.*$",
+ next : "start"
+ }, {
+ token : "nospell.text", // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:name|alias|method|S3method|S4method|item|code|preformatted|kbd|pkg|var|env|option|command|author|email|url|source|cite|acronym|href|code|preformatted|link|eqn|deqn|keyword|usage|examples|dontrun|dontshow|figure|if|ifelse|Sexpr|RdOpts|inputencoding|usepackage)\\b"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])",
+ next : "start"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "}",
+ next : "start"
+ }, {
+ token : "nospell.text",
+ regex : "\\s+"
+ }, {
+ token : "nospell.text",
+ regex : "\\w+"
+ }
+ ]
+ };
+};
+
+oop.inherits(RDocHighlightRules, TextHighlightRules);
+
+exports.RDocHighlightRules = RDocHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/rdoc",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/rdoc_highlight_rules","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var RDocHighlightRules = require("./rdoc_highlight_rules").RDocHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function(suppressHighlighting) {
+ this.HighlightRules = RDocHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+ this.$id = "ace/mode/rdoc";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-rhtml.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-rhtml.js
new file mode 100644
index 00000000..aae0378d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-rhtml.js
@@ -0,0 +1,2779 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/tex_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TexHighlightRules = function(textClass) {
+
+ if (!textClass)
+ textClass = "text";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : textClass, // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b",
+ next : "nospell"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])}]"
+ }, {
+ token : textClass,
+ regex : "\\s+"
+ }
+ ],
+ "nospell" : [
+ {
+ token : "comment",
+ regex : "%.*$",
+ next : "start"
+ }, {
+ token : "nospell." + textClass, // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])",
+ next : "start"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "}",
+ next : "start"
+ }, {
+ token : "nospell." + textClass,
+ regex : "\\s+"
+ }, {
+ token : "nospell." + textClass,
+ regex : "\\w+"
+ }
+ ]
+ };
+};
+
+oop.inherits(TexHighlightRules, TextHighlightRules);
+
+exports.TexHighlightRules = TexHighlightRules;
+});
+
+ace.define("ace/mode/r_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/tex_highlight_rules"], function(require, exports, module)
+{
+
+ var oop = require("../lib/oop");
+ var lang = require("../lib/lang");
+ var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+ var TexHighlightRules = require("./tex_highlight_rules").TexHighlightRules;
+
+ var RHighlightRules = function()
+ {
+
+ var keywords = lang.arrayToMap(
+ ("function|if|in|break|next|repeat|else|for|return|switch|while|try|tryCatch|stop|warning|require|library|attach|detach|source|setMethod|setGeneric|setGroupGeneric|setClass")
+ .split("|")
+ );
+
+ var buildinConstants = lang.arrayToMap(
+ ("NULL|NA|TRUE|FALSE|T|F|Inf|NaN|NA_integer_|NA_real_|NA_character_|" +
+ "NA_complex_").split("|")
+ );
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment.sectionhead",
+ regex : "#+(?!').*(?:----|====|####)\\s*$"
+ },
+ {
+ token : "comment",
+ regex : "#+'",
+ next : "rd-start"
+ },
+ {
+ token : "comment",
+ regex : "#.*$"
+ },
+ {
+ token : "string", // multi line string start
+ regex : '["]',
+ next : "qqstring"
+ },
+ {
+ token : "string", // multi line string start
+ regex : "[']",
+ next : "qstring"
+ },
+ {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+[Li]?\\b"
+ },
+ {
+ token : "constant.numeric", // explicit integer
+ regex : "\\d+L\\b"
+ },
+ {
+ token : "constant.numeric", // number
+ regex : "\\d+(?:\\.\\d*)?(?:[eE][+\\-]?\\d*)?i?\\b"
+ },
+ {
+ token : "constant.numeric", // number with leading decimal
+ regex : "\\.\\d+(?:[eE][+\\-]?\\d*)?i?\\b"
+ },
+ {
+ token : "constant.language.boolean",
+ regex : "(?:TRUE|FALSE|T|F)\\b"
+ },
+ {
+ token : "identifier",
+ regex : "`.*?`"
+ },
+ {
+ onMatch : function(value) {
+ if (keywords[value])
+ return "keyword";
+ else if (buildinConstants[value])
+ return "constant.language";
+ else if (value == '...' || value.match(/^\.\.\d+$/))
+ return "variable.language";
+ else
+ return "identifier";
+ },
+ regex : "[a-zA-Z.][a-zA-Z0-9._]*\\b"
+ },
+ {
+ token : "keyword.operator",
+ regex : "%%|>=|<=|==|!=|\\->|<\\-|\\|\\||&&|=|\\+|\\-|\\*|/|\\^|>|<|!|&|\\||~|\\$|:"
+ },
+ {
+ token : "keyword.operator", // infix operators
+ regex : "%.*?%"
+ },
+ {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ },
+ {
+ token : "paren.keyword.operator",
+ regex : "[\\])}]"
+ },
+ {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ },
+ {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ },
+ {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+
+ var rdRules = new TexHighlightRules("comment").getRules();
+ for (var i = 0; i < rdRules["start"].length; i++) {
+ rdRules["start"][i].token += ".virtual-comment";
+ }
+
+ this.addRules(rdRules, "rd-");
+ this.$rules["rd-start"].unshift({
+ token: "text",
+ regex: "^",
+ next: "start"
+ });
+ this.$rules["rd-start"].unshift({
+ token : "keyword",
+ regex : "@(?!@)[^ ]*"
+ });
+ this.$rules["rd-start"].unshift({
+ token : "comment",
+ regex : "@@"
+ });
+ this.$rules["rd-start"].push({
+ token : "comment",
+ regex : "[^%\\\\[({\\])}]+"
+ });
+ };
+
+ oop.inherits(RHighlightRules, TextHighlightRules);
+
+ exports.RHighlightRules = RHighlightRules;
+});
+
+ace.define("ace/mode/rhtml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/r_highlight_rules","ace/mode/html_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var RHighlightRules = require("./r_highlight_rules").RHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var RHtmlHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ this.$rules["start"].unshift({
+ token: "support.function.codebegin",
+ regex: "^<" + "!--\\s*begin.rcode\\s*(?:.*)",
+ next: "r-start"
+ });
+
+ this.embedRules(RHighlightRules, "r-", [{
+ token: "support.function.codeend",
+ regex: "^\\s*end.rcode\\s*-->",
+ next: "start"
+ }], ["start"]);
+
+ this.normalizeRules();
+};
+oop.inherits(RHtmlHighlightRules, TextHighlightRules);
+
+exports.RHtmlHighlightRules = RHtmlHighlightRules;
+});
+
+ace.define("ace/mode/rhtml",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/rhtml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+
+var RHtmlHighlightRules = require("./rhtml_highlight_rules").RHtmlHighlightRules;
+
+var Mode = function(doc, session) {
+ HtmlMode.call(this);
+ this.$session = session;
+ this.HighlightRules = RHtmlHighlightRules;
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.insertChunkInfo = {
+ value: "<!--begin.rcode\n\nend.rcode-->\n",
+ position: {row: 0, column: 15}
+ };
+
+ this.getLanguageMode = function(position)
+ {
+ return this.$session.getState(position.row).match(/^r-/) ? 'R' : 'HTML';
+ };
+
+ this.$id = "ace/mode/rhtml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-rst.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-rst.js
new file mode 100644
index 00000000..235d31a2
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-rst.js
@@ -0,0 +1,249 @@
+ace.define("ace/mode/rst_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var RSTHighlightRules = function() {
+
+ var tokens = {
+ title: "markup.heading",
+ list: "markup.heading",
+ table: "constant",
+ directive: "keyword.operator",
+ entity: "string",
+ link: "markup.underline.list",
+ bold: "markup.bold",
+ italic: "markup.italic",
+ literal: "support.function",
+ comment: "comment"
+ };
+
+ var startStringPrefix = "(^|\\s|[\"'(<\\[{\\-/:])";
+ var endStringSuffix = "(?:$|(?=\\s|[\\\\.,;!?\\-/:\"')>\\]}]))";
+
+ this.$rules = {
+ "start": [
+ {
+ token : tokens.title,
+ regex : "(^)([\\=\\-`:\\.'\"~\\^_\\*\\+#])(\\2{2,}\\s*$)"
+ },
+ {
+ token : ["text", tokens.directive, tokens.literal],
+ regex : "(^\\s*\\.\\. )([^: ]+::)(.*$)",
+ next : "codeblock"
+ },
+ {
+ token : tokens.directive,
+ regex : "::$",
+ next : "codeblock"
+ },
+ {
+ token : [tokens.entity, tokens.link],
+ regex : "(^\\.\\. _[^:]+:)(.*$)"
+ },
+ {
+ token : [tokens.entity, tokens.link],
+ regex : "(^__ )(https?://.*$)"
+ },
+ {
+ token : tokens.entity,
+ regex : "^\\.\\. \\[[^\\]]+\\] "
+ },
+ {
+ token : tokens.comment,
+ regex : "^\\.\\. .*$",
+ next : "comment"
+ },
+ {
+ token : tokens.list,
+ regex : "^\\s*[\\*\\+-] "
+ },
+ {
+ token : tokens.list,
+ regex : "^\\s*(?:[A-Za-z]|[0-9]+|[ivxlcdmIVXLCDM]+)\\. "
+ },
+ {
+ token : tokens.list,
+ regex : "^\\s*\\(?(?:[A-Za-z]|[0-9]+|[ivxlcdmIVXLCDM]+)\\) "
+ },
+ {
+ token : tokens.table,
+ regex : "^={2,}(?: +={2,})+$"
+ },
+ {
+ token : tokens.table,
+ regex : "^\\+-{2,}(?:\\+-{2,})+\\+$"
+ },
+ {
+ token : tokens.table,
+ regex : "^\\+={2,}(?:\\+={2,})+\\+$"
+ },
+ {
+ token : ["text", tokens.literal],
+ regex : startStringPrefix + "(``)(?=\\S)",
+ next : "code"
+ },
+ {
+ token : ["text", tokens.bold],
+ regex : startStringPrefix + "(\\*\\*)(?=\\S)",
+ next : "bold"
+ },
+ {
+ token : ["text", tokens.italic],
+ regex : startStringPrefix + "(\\*)(?=\\S)",
+ next : "italic"
+ },
+ {
+ token : tokens.entity,
+ regex : "\\|[\\w\\-]+?\\|"
+ },
+ {
+ token : tokens.entity,
+ regex : ":[\\w-:]+:`\\S",
+ next : "entity"
+ },
+ {
+ token : ["text", tokens.entity],
+ regex : startStringPrefix + "(_`)(?=\\S)",
+ next : "entity"
+ },
+ {
+ token : tokens.entity,
+ regex : "_[A-Za-z0-9\\-]+?"
+ },
+ {
+ token : ["text", tokens.link],
+ regex : startStringPrefix + "(`)(?=\\S)",
+ next : "link"
+ },
+ {
+ token : tokens.link,
+ regex : "[A-Za-z0-9\\-]+?__?"
+ },
+ {
+ token : tokens.link,
+ regex : "\\[[^\\]]+?\\]_"
+ },
+ {
+ token : tokens.link,
+ regex : "https?://\\S+"
+ },
+ {
+ token : tokens.table,
+ regex : "\\|"
+ }
+ ],
+ "codeblock": [
+ {
+ token : tokens.literal,
+ regex : "^ +.+$",
+ next : "codeblock"
+ },
+ {
+ token : tokens.literal,
+ regex : '^$',
+ next: "codeblock"
+ },
+ {
+ token : "empty",
+ regex : "",
+ next : "start"
+ }
+ ],
+ "code": [
+ {
+ token : tokens.literal,
+ regex : "\\S``" + endStringSuffix,
+ next : "start"
+ },
+ {
+ defaultToken: tokens.literal
+ }
+ ],
+ "bold": [
+ {
+ token : tokens.bold,
+ regex : "\\S\\*\\*" + endStringSuffix,
+ next : "start"
+ },
+ {
+ defaultToken: tokens.bold
+ }
+ ],
+ "italic": [
+ {
+ token : tokens.italic,
+ regex : "\\S\\*" + endStringSuffix,
+ next : "start"
+ },
+ {
+ defaultToken: tokens.italic
+ }
+ ],
+ "entity": [
+ {
+ token : tokens.entity,
+ regex : "\\S`" + endStringSuffix,
+ next : "start"
+ },
+ {
+ defaultToken: tokens.entity
+ }
+ ],
+ "link": [
+ {
+ token : tokens.link,
+ regex : "\\S`__?" + endStringSuffix,
+ next : "start"
+ },
+ {
+ defaultToken: tokens.link
+ }
+ ],
+ "comment": [
+ {
+ token : tokens.comment,
+ regex : "^ +.+$",
+ next : "comment"
+ },
+ {
+ token : tokens.comment,
+ regex : '^$',
+ next: "comment"
+ },
+ {
+ token : "empty",
+ regex : "",
+ next : "start"
+ }
+ ]
+ };
+};
+oop.inherits(RSTHighlightRules, TextHighlightRules);
+
+exports.RSTHighlightRules = RSTHighlightRules;
+});
+
+ace.define("ace/mode/rst",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/rst_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var RSTHighlightRules = require("./rst_highlight_rules").RSTHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = RSTHighlightRules;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.type = "text";
+
+ this.$id = "ace/mode/rst";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-ruby.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-ruby.js
new file mode 100644
index 00000000..6732c68b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-ruby.js
@@ -0,0 +1,491 @@
+ace.define("ace/mode/ruby_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var constantOtherSymbol = exports.constantOtherSymbol = {
+ token : "constant.other.symbol.ruby", // symbol
+ regex : "[:](?:[A-Za-z_]|[@$](?=[a-zA-Z0-9_]))[a-zA-Z0-9_]*[!=?]?"
+};
+
+var qString = exports.qString = {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+};
+
+var qqString = exports.qqString = {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+};
+
+var tString = exports.tString = {
+ token : "string", // backtick string
+ regex : "[`](?:(?:\\\\.)|(?:[^'\\\\]))*?[`]"
+};
+
+var constantNumericHex = exports.constantNumericHex = {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F](?:[0-9a-fA-F]|_(?=[0-9a-fA-F]))*\\b"
+};
+
+var constantNumericFloat = exports.constantNumericFloat = {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d(?:\\d|_(?=\\d))*(?:(?:\\.\\d(?:\\d|_(?=\\d))*)?(?:[eE][+-]?\\d+)?)?\\b"
+};
+
+var instanceVariable = exports.instanceVariable = {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+};
+
+var RubyHighlightRules = function() {
+
+ var builtinFunctions = (
+ "abort|Array|assert|assert_equal|assert_not_equal|assert_same|assert_not_same|" +
+ "assert_nil|assert_not_nil|assert_match|assert_no_match|assert_in_delta|assert_throws|" +
+ "assert_raise|assert_nothing_raised|assert_instance_of|assert_kind_of|assert_respond_to|" +
+ "assert_operator|assert_send|assert_difference|assert_no_difference|assert_recognizes|" +
+ "assert_generates|assert_response|assert_redirected_to|assert_template|assert_select|" +
+ "assert_select_email|assert_select_rjs|assert_select_encoded|css_select|at_exit|" +
+ "attr|attr_writer|attr_reader|attr_accessor|attr_accessible|autoload|binding|block_given?|callcc|" +
+ "caller|catch|chomp|chomp!|chop|chop!|defined?|delete_via_redirect|eval|exec|exit|" +
+ "exit!|fail|Float|flunk|follow_redirect!|fork|form_for|form_tag|format|gets|global_variables|gsub|" +
+ "gsub!|get_via_redirect|host!|https?|https!|include|Integer|lambda|link_to|" +
+ "link_to_unless_current|link_to_function|link_to_remote|load|local_variables|loop|open|open_session|" +
+ "p|print|printf|proc|putc|puts|post_via_redirect|put_via_redirect|raise|rand|" +
+ "raw|readline|readlines|redirect?|request_via_redirect|require|scan|select|" +
+ "set_trace_func|sleep|split|sprintf|srand|String|stylesheet_link_tag|syscall|system|sub|sub!|test|" +
+ "throw|trace_var|trap|untrace_var|atan2|cos|exp|frexp|ldexp|log|log10|sin|sqrt|tan|" +
+ "render|javascript_include_tag|csrf_meta_tag|label_tag|text_field_tag|submit_tag|check_box_tag|" +
+ "content_tag|radio_button_tag|text_area_tag|password_field_tag|hidden_field_tag|" +
+ "fields_for|select_tag|options_for_select|options_from_collection_for_select|collection_select|" +
+ "time_zone_select|select_date|select_time|select_datetime|date_select|time_select|datetime_select|" +
+ "select_year|select_month|select_day|select_hour|select_minute|select_second|file_field_tag|" +
+ "file_field|respond_to|skip_before_filter|around_filter|after_filter|verify|" +
+ "protect_from_forgery|rescue_from|helper_method|redirect_to|before_filter|" +
+ "send_data|send_file|validates_presence_of|validates_uniqueness_of|validates_length_of|" +
+ "validates_format_of|validates_acceptance_of|validates_associated|validates_exclusion_of|" +
+ "validates_inclusion_of|validates_numericality_of|validates_with|validates_each|" +
+ "authenticate_or_request_with_http_basic|authenticate_or_request_with_http_digest|" +
+ "filter_parameter_logging|match|get|post|resources|redirect|scope|assert_routing|" +
+ "translate|localize|extract_locale_from_tld|caches_page|expire_page|caches_action|expire_action|" +
+ "cache|expire_fragment|expire_cache_for|observe|cache_sweeper|" +
+ "has_many|has_one|belongs_to|has_and_belongs_to_many"
+ );
+
+ var keywords = (
+ "alias|and|BEGIN|begin|break|case|class|def|defined|do|else|elsif|END|end|ensure|" +
+ "__FILE__|finally|for|gem|if|in|__LINE__|module|next|not|or|private|protected|public|" +
+ "redo|rescue|retry|return|super|then|undef|unless|until|when|while|yield"
+ );
+
+ var buildinConstants = (
+ "true|TRUE|false|FALSE|nil|NIL|ARGF|ARGV|DATA|ENV|RUBY_PLATFORM|RUBY_RELEASE_DATE|" +
+ "RUBY_VERSION|STDERR|STDIN|STDOUT|TOPLEVEL_BINDING"
+ );
+
+ var builtinVariables = (
+ "$DEBUG|$defout|$FILENAME|$LOAD_PATH|$SAFE|$stdin|$stdout|$stderr|$VERBOSE|" +
+ "$!|root_url|flash|session|cookies|params|request|response|logger|self"
+ );
+
+ var keywordMapper = this.$keywords = this.createKeywordMapper({
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "variable.language": builtinVariables,
+ "support.function": builtinFunctions,
+ "invalid.deprecated": "debugger" // TODO is this a remnant from js mode?
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "comment", // multi line comment
+ regex : "^=begin(?:$|\\s.*$)",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ },
+
+ [{
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ return "paren.lparen";
+ }
+ if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1)
+ return "paren.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.start",
+ regex : /"/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /"/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[nsrtvfbae'"\\]|c.|C-.|M-.(?:\\C-.)?|[0-7]{3}|x[\da-fA-F]{2}|u[\da-fA-F]{4})/
+ }, {
+ token : "paren.start",
+ regex : /#{/,
+ push : "start"
+ }, {
+ token : "string.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : /'/,
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\['\\]/
+ }, {
+ token : "string.end",
+ regex : /'/,
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ {
+ token : "text", // namespaces aren't symbols
+ regex : "::"
+ }, {
+ token : "variable.instance", // instance variable
+ regex : "@{1,2}[a-zA-Z_\\d]+"
+ }, {
+ token : "support.class", // class name
+ regex : "[A-Z][a-zA-Z_\\d]+"
+ },
+
+ constantOtherSymbol,
+ constantNumericHex,
+ constantNumericFloat,
+
+ {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "punctuation.separator.key-value",
+ regex : "=>"
+ }, {
+ stateName: "heredoc",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[3]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"string", value: tokens[2]},
+ {type:"support.class", value: tokens[3]},
+ {type:"string", value: tokens[4]}
+ ];
+ },
+ regex : "(<<-?)(['\"`]?)([\\w]+)(['\"`]?)",
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^ +"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : "string.character",
+ regex : "\\B\\?."
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "^=end(?:$|\\s.*$)",
+ next : "start"
+ }, {
+ token : "comment", // comment spanning whole line
+ regex : ".+"
+ }
+ ]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(RubyHighlightRules, TextHighlightRules);
+
+exports.RubyHighlightRules = RubyHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/ruby",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/ruby_highlight_rules","ace/mode/matching_brace_outdent","ace/range","ace/mode/behaviour/cstyle","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var RubyHighlightRules = require("./ruby_highlight_rules").RubyHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = RubyHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ var startingClassOrMethod = line.match(/^\s*(class|def|module)\s.*$/);
+ var startingDoBlock = line.match(/.*do(\s*|\s+\|.*\|\s*)$/);
+ var startingConditional = line.match(/^\s*(if|else|when)\s*/)
+ if (match || startingClassOrMethod || startingDoBlock || startingConditional) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return /^\s+(end|else)$/.test(line + input) || this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, session, row) {
+ var line = session.getLine(row);
+ if (/}/.test(line))
+ return this.$outdent.autoOutdent(session, row);
+ var indent = this.$getIndent(line);
+ var prevLine = session.getLine(row - 1);
+ var prevIndent = this.$getIndent(prevLine);
+ var tab = session.getTabString();
+ if (prevIndent.length <= indent.length) {
+ if (indent.slice(-tab.length) == tab)
+ session.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ }
+ };
+
+ this.$id = "ace/mode/ruby";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-rust.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-rust.js
new file mode 100644
index 00000000..0802f6b4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-rust.js
@@ -0,0 +1,272 @@
+ace.define("ace/mode/rust_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var stringEscape = /\\(?:[nrt0'"\\]|x[\da-fA-F]{2}|u\{[\da-fA-F]{6}\})/.source;
+var RustHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token: 'variable.other.source.rust',
+ regex: '\'[a-zA-Z_][a-zA-Z0-9_]*(?![\\\'])' },
+ { token: 'string.quoted.single.source.rust',
+ regex: "'(?:[^'\\\\]|" + stringEscape + ")'" },
+ {
+ stateName: "bracketedComment",
+ onMatch : function(value, currentState, stack){
+ stack.unshift(this.next, value.length - 1, currentState);
+ return "string.quoted.raw.source.rust";
+ },
+ regex : /r#*"/,
+ next : [
+ {
+ onMatch : function(value, currentState, stack) {
+ var token = "string.quoted.raw.source.rust";
+ if (value.length >= stack[1]) {
+ if (value.length > stack[1])
+ token = "invalid";
+ stack.shift();
+ stack.shift();
+ this.next = stack.shift();
+ } else {
+ this.next = "";
+ }
+ return token;
+ },
+ regex : /"#*/,
+ next : "start"
+ }, {
+ defaultToken : "string.quoted.raw.source.rust"
+ }
+ ]
+ },
+ { token: 'string.quoted.double.source.rust',
+ regex: '"',
+ push:
+ [ { token: 'string.quoted.double.source.rust',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.source.rust',
+ regex: stringEscape },
+ { defaultToken: 'string.quoted.double.source.rust' } ] },
+ { token: [ 'keyword.source.rust', 'text', 'entity.name.function.source.rust' ],
+ regex: '\\b(fn)(\\s+)([a-zA-Z_][a-zA-Z0-9_]*)' },
+ { token: 'support.constant', regex: '\\b[a-zA-Z_][\\w\\d]*::' },
+ { token: 'keyword.source.rust',
+ regex: '\\b(?:abstract|alignof|as|box|break|continue|const|crate|do|else|enum|extern|for|final|if|impl|in|let|loop|macro|match|mod|move|mut|offsetof|override|priv|proc|pub|pure|ref|return|self|sizeof|static|struct|super|trait|type|typeof|unsafe|unsized|use|virtual|where|while|yield)\\b' },
+ { token: 'storage.type.source.rust',
+ regex: '\\b(?:Self|isize|usize|char|bool|u8|u16|u32|u64|u128|f16|f32|f64|i8|i16|i32|i64|i128|str|option|either|c_float|c_double|c_void|FILE|fpos_t|DIR|dirent|c_char|c_schar|c_uchar|c_short|c_ushort|c_int|c_uint|c_long|c_ulong|size_t|ptrdiff_t|clock_t|time_t|c_longlong|c_ulonglong|intptr_t|uintptr_t|off_t|dev_t|ino_t|pid_t|mode_t|ssize_t)\\b' },
+ { token: 'variable.language.source.rust', regex: '\\bself\\b' },
+
+ { token: 'comment.line.doc.source.rust',
+ regex: '//!.*$' },
+ { token: 'comment.line.double-dash.source.rust',
+ regex: '//.*$' },
+ { token: 'comment.start.block.source.rust',
+ regex: '/\\*',
+ stateName: 'comment',
+ push:
+ [ { token: 'comment.start.block.source.rust',
+ regex: '/\\*',
+ push: 'comment' },
+ { token: 'comment.end.block.source.rust',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.source.rust' } ] },
+
+ { token: 'keyword.operator',
+ regex: /\$|[-=]>|[-+%^=!&|<>]=?|[*/](?![*/])=?/ },
+ { token : "punctuation.operator", regex : /[?:,;.]/ },
+ { token : "paren.lparen", regex : /[\[({]/ },
+ { token : "paren.rparen", regex : /[\])}]/ },
+ { token: 'constant.language.source.rust',
+ regex: '\\b(?:true|false|Some|None|Ok|Err)\\b' },
+ { token: 'support.constant.source.rust',
+ regex: '\\b(?:EXIT_FAILURE|EXIT_SUCCESS|RAND_MAX|EOF|SEEK_SET|SEEK_CUR|SEEK_END|_IOFBF|_IONBF|_IOLBF|BUFSIZ|FOPEN_MAX|FILENAME_MAX|L_tmpnam|TMP_MAX|O_RDONLY|O_WRONLY|O_RDWR|O_APPEND|O_CREAT|O_EXCL|O_TRUNC|S_IFIFO|S_IFCHR|S_IFBLK|S_IFDIR|S_IFREG|S_IFMT|S_IEXEC|S_IWRITE|S_IREAD|S_IRWXU|S_IXUSR|S_IWUSR|S_IRUSR|F_OK|R_OK|W_OK|X_OK|STDIN_FILENO|STDOUT_FILENO|STDERR_FILENO)\\b' },
+ { token: 'meta.preprocessor.source.rust',
+ regex: '\\b\\w\\(\\w\\)*!|#\\[[\\w=\\(\\)_]+\\]\\b' },
+ { token: 'constant.numeric.source.rust',
+ regex: /\b(?:0x[a-fA-F0-9_]+|0o[0-7_]+|0b[01_]+|[0-9][0-9_]*(?!\.))(?:[iu](?:size|8|16|32|64|128))?\b/ },
+ { token: 'constant.numeric.source.rust',
+ regex: /\b(?:[0-9][0-9_]*)(?:\.[0-9][0-9_]*)?(?:[Ee][+-][0-9][0-9_]*)?(?:f32|f64)?\b/ } ] }
+
+ this.normalizeRules();
+};
+
+RustHighlightRules.metaData = { fileTypes: [ 'rs', 'rc' ],
+ foldingStartMarker: '^.*\\bfn\\s*(\\w+\\s*)?\\([^\\)]*\\)(\\s*\\{[^\\}]*)?\\s*$',
+ foldingStopMarker: '^\\s*\\}',
+ name: 'Rust',
+ scopeName: 'source.rust' }
+
+
+oop.inherits(RustHighlightRules, TextHighlightRules);
+
+exports.RustHighlightRules = RustHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/rust",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/rust_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var RustHighlightRules = require("./rust_highlight_rules").RustHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = RustHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/", nestable: true};
+ this.$quotes = { '"': '"' };
+ this.$id = "ace/mode/rust";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-sass.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-sass.js
new file mode 100644
index 00000000..bd181705
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-sass.js
@@ -0,0 +1,434 @@
+ace.define("ace/mode/scss_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ScssHighlightRules = function() {
+
+ var properties = lang.arrayToMap( (function () {
+
+ var browserPrefix = ("-webkit-|-moz-|-o-|-ms-|-svg-|-pie-|-khtml-").split("|");
+
+ var prefixProperties = ("appearance|background-clip|background-inline-policy|background-origin|" +
+ "background-size|binding|border-bottom-colors|border-left-colors|" +
+ "border-right-colors|border-top-colors|border-end|border-end-color|" +
+ "border-end-style|border-end-width|border-image|border-start|" +
+ "border-start-color|border-start-style|border-start-width|box-align|" +
+ "box-direction|box-flex|box-flexgroup|box-ordinal-group|box-orient|" +
+ "box-pack|box-sizing|column-count|column-gap|column-width|column-rule|" +
+ "column-rule-width|column-rule-style|column-rule-color|float-edge|" +
+ "font-feature-settings|font-language-override|force-broken-image-icon|" +
+ "image-region|margin-end|margin-start|opacity|outline|outline-color|" +
+ "outline-offset|outline-radius|outline-radius-bottomleft|" +
+ "outline-radius-bottomright|outline-radius-topleft|outline-radius-topright|" +
+ "outline-style|outline-width|padding-end|padding-start|stack-sizing|" +
+ "tab-size|text-blink|text-decoration-color|text-decoration-line|" +
+ "text-decoration-style|transform|transform-origin|transition|" +
+ "transition-delay|transition-duration|transition-property|" +
+ "transition-timing-function|user-focus|user-input|user-modify|user-select|" +
+ "window-shadow|border-radius").split("|");
+
+ var properties = ("azimuth|background-attachment|background-color|background-image|" +
+ "background-position|background-repeat|background|border-bottom-color|" +
+ "border-bottom-style|border-bottom-width|border-bottom|border-collapse|" +
+ "border-color|border-left-color|border-left-style|border-left-width|" +
+ "border-left|border-right-color|border-right-style|border-right-width|" +
+ "border-right|border-spacing|border-style|border-top-color|" +
+ "border-top-style|border-top-width|border-top|border-width|border|bottom|" +
+ "box-shadow|box-sizing|caption-side|clear|clip|color|content|counter-increment|" +
+ "counter-reset|cue-after|cue-before|cue|cursor|direction|display|" +
+ "elevation|empty-cells|float|font-family|font-size-adjust|font-size|" +
+ "font-stretch|font-style|font-variant|font-weight|font|height|left|" +
+ "letter-spacing|line-height|list-style-image|list-style-position|" +
+ "list-style-type|list-style|margin-bottom|margin-left|margin-right|" +
+ "margin-top|marker-offset|margin|marks|max-height|max-width|min-height|" +
+ "min-width|opacity|orphans|outline-color|" +
+ "outline-style|outline-width|outline|overflow|overflow-x|overflow-y|padding-bottom|" +
+ "padding-left|padding-right|padding-top|padding|page-break-after|" +
+ "page-break-before|page-break-inside|page|pause-after|pause-before|" +
+ "pause|pitch-range|pitch|play-during|position|quotes|richness|right|" +
+ "size|speak-header|speak-numeral|speak-punctuation|speech-rate|speak|" +
+ "stress|table-layout|text-align|text-decoration|text-indent|" +
+ "text-shadow|text-transform|top|unicode-bidi|vertical-align|" +
+ "visibility|voice-family|volume|white-space|widows|width|word-spacing|" +
+ "z-index").split("|");
+ var ret = [];
+ for (var i=0, ln=browserPrefix.length; i<ln; i++) {
+ Array.prototype.push.apply(
+ ret,
+ (( browserPrefix[i] + prefixProperties.join("|" + browserPrefix[i]) ).split("|"))
+ );
+ }
+ Array.prototype.push.apply(ret, prefixProperties);
+ Array.prototype.push.apply(ret, properties);
+
+ return ret;
+
+ })() );
+
+
+
+ var functions = lang.arrayToMap(
+ ("hsl|hsla|rgb|rgba|url|attr|counter|counters|abs|adjust_color|adjust_hue|" +
+ "alpha|join|blue|ceil|change_color|comparable|complement|darken|desaturate|" +
+ "floor|grayscale|green|hue|if|invert|join|length|lighten|lightness|mix|" +
+ "nth|opacify|opacity|percentage|quote|red|round|saturate|saturation|" +
+ "scale_color|transparentize|type_of|unit|unitless|unquote").split("|")
+ );
+
+ var constants = lang.arrayToMap(
+ ("absolute|all-scroll|always|armenian|auto|baseline|below|bidi-override|" +
+ "block|bold|bolder|border-box|both|bottom|break-all|break-word|capitalize|center|" +
+ "char|circle|cjk-ideographic|col-resize|collapse|content-box|crosshair|dashed|" +
+ "decimal-leading-zero|decimal|default|disabled|disc|" +
+ "distribute-all-lines|distribute-letter|distribute-space|" +
+ "distribute|dotted|double|e-resize|ellipsis|fixed|georgian|groove|" +
+ "hand|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|" +
+ "ideograph-alpha|ideograph-numeric|ideograph-parenthesis|" +
+ "ideograph-space|inactive|inherit|inline-block|inline|inset|inside|" +
+ "inter-ideograph|inter-word|italic|justify|katakana-iroha|katakana|" +
+ "keep-all|left|lighter|line-edge|line-through|line|list-item|loose|" +
+ "lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|" +
+ "medium|middle|move|n-resize|ne-resize|newspaper|no-drop|no-repeat|" +
+ "nw-resize|none|normal|not-allowed|nowrap|oblique|outset|outside|" +
+ "overline|pointer|progress|relative|repeat-x|repeat-y|repeat|right|" +
+ "ridge|row-resize|rtl|s-resize|scroll|se-resize|separate|small-caps|" +
+ "solid|square|static|strict|super|sw-resize|table-footer-group|" +
+ "table-header-group|tb-rl|text-bottom|text-top|text|thick|thin|top|" +
+ "transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|" +
+ "vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|" +
+ "zero").split("|")
+ );
+
+ var colors = lang.arrayToMap(
+ ("aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|" +
+ "blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|" +
+ "chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|" +
+ "darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|" +
+ "darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|" +
+ "darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|" +
+ "darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|" +
+ "dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|" +
+ "ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|" +
+ "hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|" +
+ "lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|" +
+ "lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|" +
+ "lightsalmon|lightseagreen|lightskyblue|lightslategray|" +
+ "lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|" +
+ "magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|" +
+ "mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|" +
+ "mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|" +
+ "moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|" +
+ "orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|" +
+ "papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|" +
+ "red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|" +
+ "seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|" +
+ "springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|" +
+ "wheat|white|whitesmoke|yellow|yellowgreen").split("|")
+ );
+
+ var keywords = lang.arrayToMap(
+ ("@mixin|@extend|@include|@import|@media|@debug|@warn|@if|@for|@each|@while|@else|@font-face|@-webkit-keyframes|if|and|!default|module|def|end|declare").split("|")
+ )
+
+ var tags = lang.arrayToMap(
+ ("a|abbr|acronym|address|applet|area|article|aside|audio|b|base|basefont|bdo|" +
+ "big|blockquote|body|br|button|canvas|caption|center|cite|code|col|colgroup|" +
+ "command|datalist|dd|del|details|dfn|dir|div|dl|dt|em|embed|fieldset|" +
+ "figcaption|figure|font|footer|form|frame|frameset|h1|h2|h3|h4|h5|h6|head|" +
+ "header|hgroup|hr|html|i|iframe|img|input|ins|keygen|kbd|label|legend|li|" +
+ "link|map|mark|menu|meta|meter|nav|noframes|noscript|object|ol|optgroup|" +
+ "option|output|p|param|pre|progress|q|rp|rt|ruby|s|samp|script|section|select|" +
+ "small|source|span|strike|strong|style|sub|summary|sup|table|tbody|td|" +
+ "textarea|tfoot|th|thead|time|title|tr|tt|u|ul|var|video|wbr|xmp").split("|")
+ );
+
+ var numRe = "\\-?(?:(?:[0-9]+)|(?:[0-9]*\\.[0-9]+))";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : '["].*\\\\$',
+ next : "qqstring"
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "string", // multi line string start
+ regex : "['].*\\\\$",
+ next : "qstring"
+ }, {
+ token : "constant.numeric",
+ regex : numRe + "(?:em|ex|px|cm|mm|in|pt|pc|deg|rad|grad|ms|s|hz|khz|%)"
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : ["support.function", "string", "support.function"],
+ regex : "(url\\()(.*)(\\))"
+ }, {
+ token : function(value) {
+ if (properties.hasOwnProperty(value.toLowerCase()))
+ return "support.type";
+ if (keywords.hasOwnProperty(value))
+ return "keyword";
+ else if (constants.hasOwnProperty(value))
+ return "constant.language";
+ else if (functions.hasOwnProperty(value))
+ return "support.function";
+ else if (colors.hasOwnProperty(value.toLowerCase()))
+ return "support.constant.color";
+ else if (tags.hasOwnProperty(value.toLowerCase()))
+ return "variable.language";
+ else
+ return "text";
+ },
+ regex : "\\-?[@a-z_][@a-z0-9_\\-]*"
+ }, {
+ token : "variable",
+ regex : "[a-z_\\-$][a-z0-9_\\-$]*\\b"
+ }, {
+ token: "variable.language",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ token : "keyword.operator",
+ regex : "<|>|<=|>=|==|!=|-|%|#|\\+|\\$|\\+|\\*"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ caseInsensitive: true
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+};
+
+oop.inherits(ScssHighlightRules, TextHighlightRules);
+
+exports.ScssHighlightRules = ScssHighlightRules;
+
+});
+
+ace.define("ace/mode/sass_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/scss_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var ScssHighlightRules = require("./scss_highlight_rules").ScssHighlightRules;
+
+var SassHighlightRules = function() {
+ ScssHighlightRules.call(this);
+ var start = this.$rules.start;
+ if (start[1].token == "comment") {
+ start.splice(1, 1, {
+ onMatch: function(value, currentState, stack) {
+ stack.unshift(this.next, -1, value.length - 2, currentState);
+ return "comment";
+ },
+ regex: /^\s*\/\*/,
+ next: "comment"
+ }, {
+ token: "error.invalid",
+ regex: "/\\*|[{;}]"
+ }, {
+ token: "support.type",
+ regex: /^\s*:[\w\-]+\s/
+ });
+
+ this.$rules.comment = [
+ {regex: /^\s*/, onMatch: function(value, currentState, stack) {
+ if (stack[1] === -1)
+ stack[1] = Math.max(stack[2], value.length - 1);
+ if (value.length <= stack[1]) {stack.shift();stack.shift();stack.shift();
+ this.next = stack.shift();
+ return "text";
+ } else {
+ this.next = "";
+ return "comment";
+ }
+ }, next: "start"},
+ {defaultToken: "comment"}
+ ]
+ }
+};
+
+oop.inherits(SassHighlightRules, ScssHighlightRules);
+
+exports.SassHighlightRules = SassHighlightRules;
+
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/sass",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sass_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var SassHighlightRules = require("./sass_highlight_rules").SassHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = SassHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.$id = "ace/mode/sass";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-scad.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-scad.js
new file mode 100644
index 00000000..c9a767b9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-scad.js
@@ -0,0 +1,407 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/scad_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var scadHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": "module|if|else|for",
+ "constant.language": "NULL"
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : '["].*\\\\$',
+ next : "qqstring"
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "string", // multi line string start
+ regex : "['].*\\\\$",
+ next : "qstring"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant", // <CONSTANT>
+ regex : "<[a-zA-Z0-9.]+>"
+ }, {
+ token : "keyword", // pre-compiler directivs
+ regex : "(?:use|include)"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|==|=|!=|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(scadHighlightRules, TextHighlightRules);
+
+exports.scadHighlightRules = scadHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/scad",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/scad_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var scadHighlightRules = require("./scad_highlight_rules").scadHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = scadHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/scad";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-scala.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-scala.js
new file mode 100644
index 00000000..94c645c1
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-scala.js
@@ -0,0 +1,975 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/scala_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ScalaHighlightRules = function() {
+
+ var keywords = (
+ "case|default|do|else|for|if|match|while|throw|return|try|trye|catch|finally|yield|" +
+ "abstract|class|def|extends|final|forSome|implicit|implicits|import|lazy|new|object|null|" +
+ "override|package|private|protected|sealed|super|this|trait|type|val|var|with|" +
+ "assert|assume|require|print|println|printf|readLine|readBoolean|readByte|readShort|" + // package scala
+ "readChar|readInt|readLong|readFloat|readDouble" // package scala
+ );
+
+ var buildinConstants = ("true|false");
+
+ var langClasses = (
+ "AbstractMethodError|AssertionError|ClassCircularityError|"+
+ "ClassFormatError|Deprecated|EnumConstantNotPresentException|"+
+ "ExceptionInInitializerError|IllegalAccessError|"+
+ "IllegalThreadStateException|InstantiationError|InternalError|"+
+
+ "NegativeArraySizeException|NoSuchFieldError|Override|Process|"+
+ "ProcessBuilder|SecurityManager|StringIndexOutOfBoundsException|"+
+ "SuppressWarnings|TypeNotPresentException|UnknownError|"+
+ "UnsatisfiedLinkError|UnsupportedClassVersionError|VerifyError|"+
+ "InstantiationException|IndexOutOfBoundsException|"+
+ "ArrayIndexOutOfBoundsException|CloneNotSupportedException|"+
+ "NoSuchFieldException|IllegalArgumentException|NumberFormatException|"+
+ "SecurityException|Void|InheritableThreadLocal|IllegalStateException|"+
+ "InterruptedException|NoSuchMethodException|IllegalAccessException|"+
+ "UnsupportedOperationException|Enum|StrictMath|Package|Compiler|"+
+ "Readable|Runtime|StringBuilder|Math|IncompatibleClassChangeError|"+
+ "NoSuchMethodError|ThreadLocal|RuntimePermission|ArithmeticException|"+
+ "NullPointerException|Long|Integer|Short|Byte|Double|Number|Float|"+
+ "Character|Boolean|StackTraceElement|Appendable|StringBuffer|"+
+ "Iterable|ThreadGroup|Runnable|Thread|IllegalMonitorStateException|"+
+ "StackOverflowError|OutOfMemoryError|VirtualMachineError|"+
+ "ArrayStoreException|ClassCastException|LinkageError|"+
+ "NoClassDefFoundError|ClassNotFoundException|RuntimeException|"+
+ "Exception|ThreadDeath|Error|Throwable|System|ClassLoader|"+
+ "Cloneable|Class|CharSequence|Comparable|String|Object|" +
+ "Unit|Any|AnyVal|AnyRef|Null|ScalaObject|Singleton|Seq|Iterable|List|" +
+ "Option|Array|Char|Byte|Int|Long|Nothing|" +
+
+ "App|Application|BufferedIterator|BigDecimal|BigInt|Console|Either|" +
+ "Enumeration|Equiv|Fractional|Function|IndexedSeq|Integral|Iterator|" +
+ "Map|Numeric|Nil|NotNull|Ordered|Ordering|PartialFunction|PartialOrdering|" +
+ "Product|Proxy|Range|Responder|Seq|Serializable|Set|Specializable|Stream|" +
+ "StringContext|Symbol|Traversable|TraversableOnce|Tuple|Vector|Pair|Triple"
+
+
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "support.function": langClasses,
+ "constant.language": buildinConstants
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string",
+ regex : '"""',
+ next : "tstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)', // " strings can't span multiple lines
+ next : "string"
+ }, {
+ token : "symbol.constant", // single line
+ regex : "'[\\w\\d_]+"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|\\b(?:in|instanceof|new|delete|typeof|void)"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "string" : [
+ {
+ token : "escape",
+ regex : '\\\\"'
+ }, {
+ token : "string",
+ regex : '"',
+ next : "start"
+ }, {
+ token : "string.invalid",
+ regex : '[^"\\\\]*$',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '[^"\\\\]+'
+ }
+ ],
+ "tstring" : [
+ {
+ token : "string",
+ regex : '"{3,5}',
+ next : "start"
+ }, {
+ defaultToken : "string"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(ScalaHighlightRules, TextHighlightRules);
+
+exports.ScalaHighlightRules = ScalaHighlightRules;
+});
+
+ace.define("ace/mode/scala",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/scala_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptMode = require("./javascript").Mode;
+var ScalaHighlightRules = require("./scala_highlight_rules").ScalaHighlightRules;
+
+var Mode = function() {
+ JavaScriptMode.call(this);
+ this.HighlightRules = ScalaHighlightRules;
+};
+oop.inherits(Mode, JavaScriptMode);
+
+(function() {
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/scala";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-scheme.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-scheme.js
new file mode 100644
index 00000000..2e6b7fff
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-scheme.js
@@ -0,0 +1,225 @@
+ace.define("ace/mode/scheme_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SchemeHighlightRules = function() {
+ var keywordControl = "case|do|let|loop|if|else|when";
+ var keywordOperator = "eq?|eqv?|equal?|and|or|not|null?";
+ var constantLanguage = "#t|#f";
+ var supportFunctions = "cons|car|cdr|cond|lambda|lambda*|syntax-rules|format|set!|quote|eval|append|list|list?|member?|load";
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword.control": keywordControl,
+ "keyword.operator": keywordOperator,
+ "constant.language": constantLanguage,
+ "support.function": supportFunctions
+ }, "identifier", true);
+
+ this.$rules =
+ {
+ "start": [
+ {
+ token : "comment",
+ regex : ";.*$"
+ },
+ {
+ "token": ["storage.type.function-type.scheme", "text", "entity.name.function.scheme"],
+ "regex": "(?:\\b(?:(define|define-syntax|define-macro))\\b)(\\s+)((?:\\w|\\-|\\!|\\?)*)"
+ },
+ {
+ "token": "punctuation.definition.constant.character.scheme",
+ "regex": "#:\\S+"
+ },
+ {
+ "token": ["punctuation.definition.variable.scheme", "variable.other.global.scheme", "punctuation.definition.variable.scheme"],
+ "regex": "(\\*)(\\S*)(\\*)"
+ },
+ {
+ "token" : "constant.numeric", // hex
+ "regex" : "#[xXoObB][0-9a-fA-F]+"
+ },
+ {
+ "token" : "constant.numeric", // float
+ "regex" : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?"
+ },
+ {
+ "token" : keywordMapper,
+ "regex" : "[a-zA-Z_#][a-zA-Z0-9_\\-\\?\\!\\*]*"
+ },
+ {
+ "token" : "string",
+ "regex" : '"(?=.)',
+ "next" : "qqstring"
+ }
+ ],
+ "qqstring": [
+ {
+ "token": "constant.character.escape.scheme",
+ "regex": "\\\\."
+ },
+ {
+ "token" : "string",
+ "regex" : '[^"\\\\]+',
+ "merge" : true
+ }, {
+ "token" : "string",
+ "regex" : "\\\\$",
+ "next" : "qqstring",
+ "merge" : true
+ }, {
+ "token" : "string",
+ "regex" : '"|$',
+ "next" : "start",
+ "merge" : true
+ }
+ ]
+}
+
+};
+
+oop.inherits(SchemeHighlightRules, TextHighlightRules);
+
+exports.SchemeHighlightRules = SchemeHighlightRules;
+});
+
+ace.define("ace/mode/matching_parens_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingParensOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\)/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\))/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ var match = line.match(/^(\s+)/);
+ if (match) {
+ return match[1];
+ }
+
+ return "";
+ };
+
+}).call(MatchingParensOutdent.prototype);
+
+exports.MatchingParensOutdent = MatchingParensOutdent;
+});
+
+ace.define("ace/mode/scheme",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/scheme_highlight_rules","ace/mode/matching_parens_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var SchemeHighlightRules = require("./scheme_highlight_rules").SchemeHighlightRules;
+var MatchingParensOutdent = require("./matching_parens_outdent").MatchingParensOutdent;
+
+var Mode = function() {
+ this.HighlightRules = SchemeHighlightRules;
+ this.$outdent = new MatchingParensOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ";";
+ this.minorIndentFunctions = ["define", "lambda", "define-macro", "define-syntax", "syntax-rules", "define-record-type", "define-structure"];
+
+ this.$toIndent = function(str) {
+ return str.split('').map(function(ch) {
+ if (/\s/.exec(ch)) {
+ return ch;
+ } else {
+ return ' ';
+ }
+ }).join('');
+ };
+
+ this.$calculateIndent = function(line, tab) {
+ var baseIndent = this.$getIndent(line);
+ var delta = 0;
+ var isParen, ch;
+ for (var i = line.length - 1; i >= 0; i--) {
+ ch = line[i];
+ if (ch === '(') {
+ delta--;
+ isParen = true;
+ } else if (ch === '(' || ch === '[' || ch === '{') {
+ delta--;
+ isParen = false;
+ } else if (ch === ')' || ch === ']' || ch === '}') {
+ delta++;
+ }
+ if (delta < 0) {
+ break;
+ }
+ }
+ if (delta < 0 && isParen) {
+ i += 1;
+ var iBefore = i;
+ var fn = '';
+ while (true) {
+ ch = line[i];
+ if (ch === ' ' || ch === '\t') {
+ if(this.minorIndentFunctions.indexOf(fn) !== -1) {
+ return this.$toIndent(line.substring(0, iBefore - 1) + tab);
+ } else {
+ return this.$toIndent(line.substring(0, i + 1));
+ }
+ } else if (ch === undefined) {
+ return this.$toIndent(line.substring(0, iBefore - 1) + tab);
+ }
+ fn += line[i];
+ i++;
+ }
+ } else if(delta < 0 && !isParen) {
+ return this.$toIndent(line.substring(0, i+1));
+ } else if(delta > 0) {
+ baseIndent = baseIndent.substring(0, baseIndent.length - tab.length);
+ return baseIndent;
+ } else {
+ return baseIndent;
+ }
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$calculateIndent(line, tab);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/scheme";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-scss.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-scss.js
new file mode 100644
index 00000000..4785dc36
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-scss.js
@@ -0,0 +1,586 @@
+ace.define("ace/mode/scss_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ScssHighlightRules = function() {
+
+ var properties = lang.arrayToMap( (function () {
+
+ var browserPrefix = ("-webkit-|-moz-|-o-|-ms-|-svg-|-pie-|-khtml-").split("|");
+
+ var prefixProperties = ("appearance|background-clip|background-inline-policy|background-origin|" +
+ "background-size|binding|border-bottom-colors|border-left-colors|" +
+ "border-right-colors|border-top-colors|border-end|border-end-color|" +
+ "border-end-style|border-end-width|border-image|border-start|" +
+ "border-start-color|border-start-style|border-start-width|box-align|" +
+ "box-direction|box-flex|box-flexgroup|box-ordinal-group|box-orient|" +
+ "box-pack|box-sizing|column-count|column-gap|column-width|column-rule|" +
+ "column-rule-width|column-rule-style|column-rule-color|float-edge|" +
+ "font-feature-settings|font-language-override|force-broken-image-icon|" +
+ "image-region|margin-end|margin-start|opacity|outline|outline-color|" +
+ "outline-offset|outline-radius|outline-radius-bottomleft|" +
+ "outline-radius-bottomright|outline-radius-topleft|outline-radius-topright|" +
+ "outline-style|outline-width|padding-end|padding-start|stack-sizing|" +
+ "tab-size|text-blink|text-decoration-color|text-decoration-line|" +
+ "text-decoration-style|transform|transform-origin|transition|" +
+ "transition-delay|transition-duration|transition-property|" +
+ "transition-timing-function|user-focus|user-input|user-modify|user-select|" +
+ "window-shadow|border-radius").split("|");
+
+ var properties = ("azimuth|background-attachment|background-color|background-image|" +
+ "background-position|background-repeat|background|border-bottom-color|" +
+ "border-bottom-style|border-bottom-width|border-bottom|border-collapse|" +
+ "border-color|border-left-color|border-left-style|border-left-width|" +
+ "border-left|border-right-color|border-right-style|border-right-width|" +
+ "border-right|border-spacing|border-style|border-top-color|" +
+ "border-top-style|border-top-width|border-top|border-width|border|bottom|" +
+ "box-shadow|box-sizing|caption-side|clear|clip|color|content|counter-increment|" +
+ "counter-reset|cue-after|cue-before|cue|cursor|direction|display|" +
+ "elevation|empty-cells|float|font-family|font-size-adjust|font-size|" +
+ "font-stretch|font-style|font-variant|font-weight|font|height|left|" +
+ "letter-spacing|line-height|list-style-image|list-style-position|" +
+ "list-style-type|list-style|margin-bottom|margin-left|margin-right|" +
+ "margin-top|marker-offset|margin|marks|max-height|max-width|min-height|" +
+ "min-width|opacity|orphans|outline-color|" +
+ "outline-style|outline-width|outline|overflow|overflow-x|overflow-y|padding-bottom|" +
+ "padding-left|padding-right|padding-top|padding|page-break-after|" +
+ "page-break-before|page-break-inside|page|pause-after|pause-before|" +
+ "pause|pitch-range|pitch|play-during|position|quotes|richness|right|" +
+ "size|speak-header|speak-numeral|speak-punctuation|speech-rate|speak|" +
+ "stress|table-layout|text-align|text-decoration|text-indent|" +
+ "text-shadow|text-transform|top|unicode-bidi|vertical-align|" +
+ "visibility|voice-family|volume|white-space|widows|width|word-spacing|" +
+ "z-index").split("|");
+ var ret = [];
+ for (var i=0, ln=browserPrefix.length; i<ln; i++) {
+ Array.prototype.push.apply(
+ ret,
+ (( browserPrefix[i] + prefixProperties.join("|" + browserPrefix[i]) ).split("|"))
+ );
+ }
+ Array.prototype.push.apply(ret, prefixProperties);
+ Array.prototype.push.apply(ret, properties);
+
+ return ret;
+
+ })() );
+
+
+
+ var functions = lang.arrayToMap(
+ ("hsl|hsla|rgb|rgba|url|attr|counter|counters|abs|adjust_color|adjust_hue|" +
+ "alpha|join|blue|ceil|change_color|comparable|complement|darken|desaturate|" +
+ "floor|grayscale|green|hue|if|invert|join|length|lighten|lightness|mix|" +
+ "nth|opacify|opacity|percentage|quote|red|round|saturate|saturation|" +
+ "scale_color|transparentize|type_of|unit|unitless|unquote").split("|")
+ );
+
+ var constants = lang.arrayToMap(
+ ("absolute|all-scroll|always|armenian|auto|baseline|below|bidi-override|" +
+ "block|bold|bolder|border-box|both|bottom|break-all|break-word|capitalize|center|" +
+ "char|circle|cjk-ideographic|col-resize|collapse|content-box|crosshair|dashed|" +
+ "decimal-leading-zero|decimal|default|disabled|disc|" +
+ "distribute-all-lines|distribute-letter|distribute-space|" +
+ "distribute|dotted|double|e-resize|ellipsis|fixed|georgian|groove|" +
+ "hand|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|" +
+ "ideograph-alpha|ideograph-numeric|ideograph-parenthesis|" +
+ "ideograph-space|inactive|inherit|inline-block|inline|inset|inside|" +
+ "inter-ideograph|inter-word|italic|justify|katakana-iroha|katakana|" +
+ "keep-all|left|lighter|line-edge|line-through|line|list-item|loose|" +
+ "lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|" +
+ "medium|middle|move|n-resize|ne-resize|newspaper|no-drop|no-repeat|" +
+ "nw-resize|none|normal|not-allowed|nowrap|oblique|outset|outside|" +
+ "overline|pointer|progress|relative|repeat-x|repeat-y|repeat|right|" +
+ "ridge|row-resize|rtl|s-resize|scroll|se-resize|separate|small-caps|" +
+ "solid|square|static|strict|super|sw-resize|table-footer-group|" +
+ "table-header-group|tb-rl|text-bottom|text-top|text|thick|thin|top|" +
+ "transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|" +
+ "vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|" +
+ "zero").split("|")
+ );
+
+ var colors = lang.arrayToMap(
+ ("aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|" +
+ "blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|" +
+ "chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|" +
+ "darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|" +
+ "darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|" +
+ "darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|" +
+ "darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|" +
+ "dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|" +
+ "ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|" +
+ "hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|" +
+ "lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|" +
+ "lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|" +
+ "lightsalmon|lightseagreen|lightskyblue|lightslategray|" +
+ "lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|" +
+ "magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|" +
+ "mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|" +
+ "mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|" +
+ "moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|" +
+ "orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|" +
+ "papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|" +
+ "red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|" +
+ "seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|" +
+ "springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|" +
+ "wheat|white|whitesmoke|yellow|yellowgreen").split("|")
+ );
+
+ var keywords = lang.arrayToMap(
+ ("@mixin|@extend|@include|@import|@media|@debug|@warn|@if|@for|@each|@while|@else|@font-face|@-webkit-keyframes|if|and|!default|module|def|end|declare").split("|")
+ )
+
+ var tags = lang.arrayToMap(
+ ("a|abbr|acronym|address|applet|area|article|aside|audio|b|base|basefont|bdo|" +
+ "big|blockquote|body|br|button|canvas|caption|center|cite|code|col|colgroup|" +
+ "command|datalist|dd|del|details|dfn|dir|div|dl|dt|em|embed|fieldset|" +
+ "figcaption|figure|font|footer|form|frame|frameset|h1|h2|h3|h4|h5|h6|head|" +
+ "header|hgroup|hr|html|i|iframe|img|input|ins|keygen|kbd|label|legend|li|" +
+ "link|map|mark|menu|meta|meter|nav|noframes|noscript|object|ol|optgroup|" +
+ "option|output|p|param|pre|progress|q|rp|rt|ruby|s|samp|script|section|select|" +
+ "small|source|span|strike|strong|style|sub|summary|sup|table|tbody|td|" +
+ "textarea|tfoot|th|thead|time|title|tr|tt|u|ul|var|video|wbr|xmp").split("|")
+ );
+
+ var numRe = "\\-?(?:(?:[0-9]+)|(?:[0-9]*\\.[0-9]+))";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : '["].*\\\\$',
+ next : "qqstring"
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "string", // multi line string start
+ regex : "['].*\\\\$",
+ next : "qstring"
+ }, {
+ token : "constant.numeric",
+ regex : numRe + "(?:em|ex|px|cm|mm|in|pt|pc|deg|rad|grad|ms|s|hz|khz|%)"
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : ["support.function", "string", "support.function"],
+ regex : "(url\\()(.*)(\\))"
+ }, {
+ token : function(value) {
+ if (properties.hasOwnProperty(value.toLowerCase()))
+ return "support.type";
+ if (keywords.hasOwnProperty(value))
+ return "keyword";
+ else if (constants.hasOwnProperty(value))
+ return "constant.language";
+ else if (functions.hasOwnProperty(value))
+ return "support.function";
+ else if (colors.hasOwnProperty(value.toLowerCase()))
+ return "support.constant.color";
+ else if (tags.hasOwnProperty(value.toLowerCase()))
+ return "variable.language";
+ else
+ return "text";
+ },
+ regex : "\\-?[@a-z_][@a-z0-9_\\-]*"
+ }, {
+ token : "variable",
+ regex : "[a-z_\\-$][a-z0-9_\\-$]*\\b"
+ }, {
+ token: "variable.language",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "variable.language",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ token : "keyword.operator",
+ regex : "<|>|<=|>=|==|!=|-|%|#|\\+|\\$|\\+|\\*"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }, {
+ caseInsensitive: true
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '(?:(?:\\\\.)|(?:[^"\\\\]))*?"',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "(?:(?:\\\\.)|(?:[^'\\\\]))*?'",
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ]
+ };
+};
+
+oop.inherits(ScssHighlightRules, TextHighlightRules);
+
+exports.ScssHighlightRules = ScssHighlightRules;
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/scss",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/scss_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ScssHighlightRules = require("./scss_highlight_rules").ScssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = ScssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/scss";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-sh.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-sh.js
new file mode 100644
index 00000000..6db3e296
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-sh.js
@@ -0,0 +1,441 @@
+ace.define("ace/mode/sh_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var reservedKeywords = exports.reservedKeywords = (
+ '!|{|}|case|do|done|elif|else|'+
+ 'esac|fi|for|if|in|then|until|while|'+
+ '&|;|export|local|read|typeset|unset|'+
+ 'elif|select|set|function|declare|readonly'
+ );
+
+var languageConstructs = exports.languageConstructs = (
+ '[|]|alias|bg|bind|break|builtin|'+
+ 'cd|command|compgen|complete|continue|'+
+ 'dirs|disown|echo|enable|eval|exec|'+
+ 'exit|fc|fg|getopts|hash|help|history|'+
+ 'jobs|kill|let|logout|popd|printf|pushd|'+
+ 'pwd|return|set|shift|shopt|source|'+
+ 'suspend|test|times|trap|type|ulimit|'+
+ 'umask|unalias|wait'
+);
+
+var ShHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "keyword": reservedKeywords,
+ "support.function.builtin": languageConstructs,
+ "invalid.deprecated": "debugger"
+ }, "identifier");
+
+ var integer = "(?:(?:[1-9]\\d*)|(?:0))";
+
+ var fraction = "(?:\\.\\d+)";
+ var intPart = "(?:\\d+)";
+ var pointFloat = "(?:(?:" + intPart + "?" + fraction + ")|(?:" + intPart + "\\.))";
+ var exponentFloat = "(?:(?:" + pointFloat + "|" + intPart + ")" + ")";
+ var floatNumber = "(?:" + exponentFloat + "|" + pointFloat + ")";
+ var fileDescriptor = "(?:&" + intPart + ")";
+
+ var variableName = "[a-zA-Z_][a-zA-Z0-9_]*";
+ var variable = "(?:" + variableName + "(?==))";
+
+ var builtinVariable = "(?:\\$(?:SHLVL|\\$|\\!|\\?))";
+
+ var func = "(?:" + variableName + "\\s*\\(\\))";
+
+ this.$rules = {
+ "start" : [{
+ token : "constant",
+ regex : /\\./
+ }, {
+ token : ["text", "comment"],
+ regex : /(^|\s)(#.*)$/
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[$`"\\]|$)/
+ }, {
+ include : "variables"
+ }, {
+ token : "keyword.operator",
+ regex : /`/ // TODO highlight `
+ }, {
+ token : "string.end",
+ regex : '"',
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string",
+ regex : "\\$'",
+ push : [{
+ token : "constant.language.escape",
+ regex : /\\(?:[abeEfnrtv\\'"]|x[a-fA-F\d]{1,2}|u[a-fA-F\d]{4}([a-fA-F\d]{4})?|c.|\d{1,3})/
+ }, {
+ token : "string",
+ regex : "'",
+ next: "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ regex : "<<<",
+ token : "keyword.operator"
+ }, {
+ stateName: "heredoc",
+ regex : "(<<-?)(\\s*)(['\"`]?)([\\w\\-]+)(['\"`]?)",
+ onMatch : function(value, currentState, stack) {
+ var next = value[2] == '-' ? "indentedHeredoc" : "heredoc";
+ var tokens = value.split(this.splitRegex);
+ stack.push(next, tokens[4]);
+ return [
+ {type:"constant", value: tokens[1]},
+ {type:"text", value: tokens[2]},
+ {type:"string", value: tokens[3]},
+ {type:"support.class", value: tokens[4]},
+ {type:"string", value: tokens[5]}
+ ];
+ },
+ rules: {
+ heredoc: [{
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }],
+ indentedHeredoc: [{
+ token: "string",
+ regex: "^\t+"
+ }, {
+ onMatch: function(value, currentState, stack) {
+ if (value === stack[1]) {
+ stack.shift();
+ stack.shift();
+ this.next = stack[0] || "start";
+ return "support.class";
+ }
+ this.next = "";
+ return "string";
+ },
+ regex: ".*$",
+ next: "start"
+ }]
+ }
+ }, {
+ regex : "$",
+ token : "empty",
+ next : function(currentState, stack) {
+ if (stack[0] === "heredoc" || stack[0] === "indentedHeredoc")
+ return stack[0];
+ return currentState;
+ }
+ }, {
+ token : ["keyword", "text", "text", "text", "variable"],
+ regex : /(declare|local|readonly)(\s+)(?:(-[fixar]+)(\s+))?([a-zA-Z_][a-zA-Z0-9_]*\b)/
+ }, {
+ token : "variable.language",
+ regex : builtinVariable
+ }, {
+ token : "variable",
+ regex : variable
+ }, {
+ include : "variables"
+ }, {
+ token : "support.function",
+ regex : func
+ }, {
+ token : "support.function",
+ regex : fileDescriptor
+ }, {
+ token : "string", // ' string
+ start : "'", end : "'"
+ }, {
+ token : "constant.numeric", // float
+ regex : floatNumber
+ }, {
+ token : "constant.numeric", // integer
+ regex : integer + "\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_][a-zA-Z0-9_]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\*|\\*\\*|\\/|\\/\\/|~|<|>|<=|=>|=|!=|[%&|`]"
+ }, {
+ token : "punctuation.operator",
+ regex : ";"
+ }, {
+ token : "paren.lparen",
+ regex : "[\\[\\(\\{]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\]]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)\\}]",
+ next : "pop"
+ }],
+ variables: [{
+ token : "variable",
+ regex : /(\$)(\w+)/
+ }, {
+ token : ["variable", "paren.lparen"],
+ regex : /(\$)(\()/,
+ push : "start"
+ }, {
+ token : ["variable", "paren.lparen", "keyword.operator", "variable", "keyword.operator"],
+ regex : /(\$)(\{)([#!]?)(\w+|[*@#?\-$!0_])(:[?+\-=]?|##?|%%?|,,?\/|\^\^?)?/,
+ push : "start"
+ }, {
+ token : "variable",
+ regex : /\$[*@#?\-$!0_]/
+ }, {
+ token : ["variable", "paren.lparen"],
+ regex : /(\$)(\{)/,
+ push : "start"
+ }]
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(ShHighlightRules, TextHighlightRules);
+
+exports.ShHighlightRules = ShHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/sh",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sh_highlight_rules","ace/range","ace/mode/folding/cstyle","ace/mode/behaviour/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var ShHighlightRules = require("./sh_highlight_rules").ShHighlightRules;
+var Range = require("../range").Range;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+
+var Mode = function() {
+ this.HighlightRules = ShHighlightRules;
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = new CstyleBehaviour();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[:]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ var outdents = {
+ "pass": 1,
+ "return": 1,
+ "raise": 1,
+ "break": 1,
+ "continue": 1
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (input !== "\r\n" && input !== "\r" && input !== "\n")
+ return false;
+
+ var tokens = this.getTokenizer().getLineTokens(line.trim(), state).tokens;
+
+ if (!tokens)
+ return false;
+ do {
+ var last = tokens.pop();
+ } while (last && (last.type == "comment" || (last.type == "text" && last.value.match(/^\s+$/))));
+
+ if (!last)
+ return false;
+
+ return (last.type == "keyword" && outdents[last.value]);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+
+ row += 1;
+ var indent = this.$getIndent(doc.getLine(row));
+ var tab = doc.getTabString();
+ if (indent.slice(-tab.length) == tab)
+ doc.remove(new Range(row, indent.length-tab.length, row, indent.length));
+ };
+
+ this.$id = "ace/mode/sh";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-sjs.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-sjs.js
new file mode 100644
index 00000000..6bcd0bce
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-sjs.js
@@ -0,0 +1,1006 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/sjs_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/javascript_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SJSHighlightRules = function() {
+ var parent = new JavaScriptHighlightRules({noES6: true});
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-6][0-7]?|" + // oct
+ "37[0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ var contextAware = function(f) {
+ f.isContextAware = true;
+ return f;
+ };
+
+ var ctxBegin = function(opts) {
+ return {
+ token: opts.token,
+ regex: opts.regex,
+ next: contextAware(function(currentState, stack) {
+ if (stack.length === 0)
+ stack.unshift(currentState);
+ stack.unshift(opts.next);
+ return opts.next;
+ })
+ };
+ };
+
+ var ctxEnd = function(opts) {
+ return {
+ token: opts.token,
+ regex: opts.regex,
+ next: contextAware(function(currentState, stack) {
+ stack.shift();
+ return stack[0] || "start";
+ })
+ };
+ };
+
+ this.$rules = parent.$rules;
+ this.$rules.no_regex = [
+ {
+ token: "keyword",
+ regex: "(waitfor|or|and|collapse|spawn|retract)\\b"
+ },
+ {
+ token: "keyword.operator",
+ regex: "(->|=>|\\.\\.)"
+ },
+ {
+ token: "variable.language",
+ regex: "(hold|default)\\b"
+ },
+ ctxBegin({
+ token: "string",
+ regex: "`",
+ next: "bstring"
+ }),
+ ctxBegin({
+ token: "string",
+ regex: '"',
+ next: "qqstring"
+ }),
+ ctxBegin({
+ token: "string",
+ regex: '"',
+ next: "qqstring"
+ }),
+ {
+ token: ["paren.lparen", "text", "paren.rparen"],
+ regex: "(\\{)(\\s*)(\\|)",
+ next: "block_arguments"
+ }
+
+ ].concat(this.$rules.no_regex);
+
+ this.$rules.block_arguments = [
+ {
+ token: "paren.rparen",
+ regex: "\\|",
+ next: "no_regex"
+ }
+ ].concat(this.$rules.function_arguments);
+
+ this.$rules.bstring = [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ },
+ {
+ token : "string",
+ regex : "\\\\$",
+ next: "bstring"
+ },
+ ctxBegin({
+ token : "paren.lparen",
+ regex : "\\$\\{",
+ next: "string_interp"
+ }),
+ ctxBegin({
+ token : "paren.lparen",
+ regex : "\\$",
+ next: "bstring_interp_single"
+ }),
+ ctxEnd({
+ token : "string",
+ regex : "`"
+ }),
+ {
+ defaultToken: "string"
+ }
+ ];
+
+ this.$rules.qqstring = [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ },
+ {
+ token : "string",
+ regex : "\\\\$",
+ next: "qqstring"
+ },
+ ctxBegin({
+ token : "paren.lparen",
+ regex : "#\\{",
+ next: "string_interp"
+ }),
+ ctxEnd({
+ token : "string",
+ regex : '"'
+ }),
+ {
+ defaultToken: "string"
+ }
+ ];
+ var embeddableRules = [];
+ for (var i=0; i < this.$rules.no_regex.length; i++) {
+ var rule = this.$rules.no_regex[i];
+ var token = String(rule.token);
+ if (token.indexOf('paren') == -1 && (!rule.next || rule.next.isContextAware)) {
+ embeddableRules.push(rule);
+ }
+ }
+
+ this.$rules.string_interp = [
+ ctxEnd({
+ token: "paren.rparen",
+ regex: "\\}"
+ }),
+ ctxBegin({
+ token: "paren.lparen",
+ regex: '{',
+ next: "string_interp"
+ })
+ ].concat(embeddableRules);
+ this.$rules.bstring_interp_single = [
+ {
+ token: ["identifier", "paren.lparen"],
+ regex: '(\\w+)(\\()',
+ next: 'bstring_interp_single_call'
+ },
+ ctxEnd({
+ token : "identifier",
+ regex : "\\w*"
+ })
+ ];
+ this.$rules.bstring_interp_single_call = [
+ ctxBegin({
+ token: "paren.lparen",
+ regex: "\\(",
+ next: "bstring_interp_single_call"
+ }),
+ ctxEnd({
+ token: "paren.rparen",
+ regex: "\\)"
+ })
+ ].concat(embeddableRules);
+}
+oop.inherits(SJSHighlightRules, TextHighlightRules);
+
+exports.SJSHighlightRules = SJSHighlightRules;
+});
+
+ace.define("ace/mode/sjs",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/sjs_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+var oop = require("../lib/oop");
+var JSMode = require("./javascript").Mode;
+var SJSHighlightRules = require("./sjs_highlight_rules").SJSHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = SJSHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, JSMode);
+(function() {
+ this.createWorker = function(session) {
+ return null;
+ }
+ this.$id = "ace/mode/sjs";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-smarty.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-smarty.js
new file mode 100644
index 00000000..448ced33
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-smarty.js
@@ -0,0 +1,2606 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/smarty_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var SmartyHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+ var smartyRules = { start:
+ [ { include: '#comments' },
+ { include: '#blocks' } ],
+ '#blocks':
+ [ { token: 'punctuation.section.embedded.begin.smarty',
+ regex: '\\{%?',
+ push:
+ [ { token: 'punctuation.section.embedded.end.smarty',
+ regex: '%?\\}',
+ next: 'pop' },
+ { include: '#strings' },
+ { include: '#variables' },
+ { include: '#lang' },
+ { defaultToken: 'source.smarty' } ] } ],
+ '#comments':
+ [ { token:
+ [ 'punctuation.definition.comment.smarty',
+ 'comment.block.smarty' ],
+ regex: '(\\{%?)(\\*)',
+ push:
+ [ { token: 'comment.block.smarty', regex: '\\*%?\\}', next: 'pop' },
+ { defaultToken: 'comment.block.smarty' } ] } ],
+ '#lang':
+ [ { token: 'keyword.operator.smarty',
+ regex: '(?:!=|!|<=|>=|<|>|===|==|%|&&|\\|\\|)|\\b(?:and|or|eq|neq|ne|gte|gt|ge|lte|lt|le|not|mod)\\b' },
+ { token: 'constant.language.smarty',
+ regex: '\\b(?:TRUE|FALSE|true|false)\\b' },
+ { token: 'keyword.control.smarty',
+ regex: '\\b(?:if|else|elseif|foreach|foreachelse|section|switch|case|break|default)\\b' },
+ { token: 'variable.parameter.smarty', regex: '\\b[a-zA-Z]+=' },
+ { token: 'support.function.built-in.smarty',
+ regex: '\\b(?:capture|config_load|counter|cycle|debug|eval|fetch|include_php|include|insert|literal|math|strip|rdelim|ldelim|assign|constant|block|html_[a-z_]*)\\b' },
+ { token: 'support.function.variable-modifier.smarty',
+ regex: '\\|(?:capitalize|cat|count_characters|count_paragraphs|count_sentences|count_words|date_format|default|escape|indent|lower|nl2br|regex_replace|replace|spacify|string_format|strip_tags|strip|truncate|upper|wordwrap)' } ],
+ '#strings':
+ [ { token: 'punctuation.definition.string.begin.smarty',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.smarty',
+ regex: '\'',
+ next: 'pop' },
+ { token: 'constant.character.escape.smarty', regex: '\\\\.' },
+ { defaultToken: 'string.quoted.single.smarty' } ] },
+ { token: 'punctuation.definition.string.begin.smarty',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.smarty',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.smarty', regex: '\\\\.' },
+ { defaultToken: 'string.quoted.double.smarty' } ] } ],
+ '#variables':
+ [ { token:
+ [ 'punctuation.definition.variable.smarty',
+ 'variable.other.global.smarty' ],
+ regex: '\\b(\\$)(Smarty\\.)' },
+ { token:
+ [ 'punctuation.definition.variable.smarty',
+ 'variable.other.smarty' ],
+ regex: '(\\$)([a-zA-Z_][a-zA-Z0-9_]*)\\b' },
+ { token: [ 'keyword.operator.smarty', 'variable.other.property.smarty' ],
+ regex: '(->)([a-zA-Z_][a-zA-Z0-9_]*)\\b' },
+ { token:
+ [ 'keyword.operator.smarty',
+ 'meta.function-call.object.smarty',
+ 'punctuation.definition.variable.smarty',
+ 'variable.other.smarty',
+ 'punctuation.definition.variable.smarty' ],
+ regex: '(->)([a-zA-Z_][a-zA-Z0-9_]*)(\\()(.*?)(\\))' } ] }
+
+ var smartyStart = smartyRules.start;
+
+ for (var rule in this.$rules) {
+ this.$rules[rule].unshift.apply(this.$rules[rule], smartyStart);
+ }
+
+ Object.keys(smartyRules).forEach(function(x) {
+ if (!this.$rules[x])
+ this.$rules[x] = smartyRules[x];
+ }, this);
+
+ this.normalizeRules();
+};
+
+SmartyHighlightRules.metaData = { fileTypes: [ 'tpl' ],
+ foldingStartMarker: '\\{%?',
+ foldingStopMarker: '%?\\}',
+ name: 'Smarty',
+ scopeName: 'text.html.smarty' }
+
+
+oop.inherits(SmartyHighlightRules, HtmlHighlightRules);
+
+exports.SmartyHighlightRules = SmartyHighlightRules;
+});
+
+ace.define("ace/mode/smarty",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/smarty_highlight_rules"], function(require, exports, module) {
+ "use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var SmartyHighlightRules = require("./smarty_highlight_rules").SmartyHighlightRules;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = SmartyHighlightRules;
+};
+
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+
+ this.$id = "ace/mode/smarty";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-snippets.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-snippets.js
new file mode 100644
index 00000000..a528501f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-snippets.js
@@ -0,0 +1,199 @@
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/snippets",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SnippetHighlightRules = function() {
+
+ var builtins = "SELECTION|CURRENT_WORD|SELECTED_TEXT|CURRENT_LINE|LINE_INDEX|" +
+ "LINE_NUMBER|SOFT_TABS|TAB_SIZE|FILENAME|FILEPATH|FULLNAME";
+
+ this.$rules = {
+ "start" : [
+ {token:"constant.language.escape", regex: /\\[\$}`\\]/},
+ {token:"keyword", regex: "\\$(?:TM_)?(?:" + builtins + ")\\b"},
+ {token:"variable", regex: "\\$\\w+"},
+ {onMatch: function(value, state, stack) {
+ if (stack[1])
+ stack[1]++;
+ else
+ stack.unshift(state, 1);
+ return this.tokenName;
+ }, tokenName: "markup.list", regex: "\\${", next: "varDecl"},
+ {onMatch: function(value, state, stack) {
+ if (!stack[1])
+ return "text";
+ stack[1]--;
+ if (!stack[1])
+ stack.splice(0,2);
+ return this.tokenName;
+ }, tokenName: "markup.list", regex: "}"},
+ {token: "doc.comment", regex:/^\${2}-{5,}$/}
+ ],
+ "varDecl" : [
+ {regex: /\d+\b/, token: "constant.numeric"},
+ {token:"keyword", regex: "(?:TM_)?(?:" + builtins + ")\\b"},
+ {token:"variable", regex: "\\w+"},
+ {regex: /:/, token: "punctuation.operator", next: "start"},
+ {regex: /\//, token: "string.regex", next: "regexp"},
+ {regex: "", next: "start"}
+ ],
+ "regexp" : [
+ {regex: /\\./, token: "escape"},
+ {regex: /\[/, token: "regex.start", next: "charClass"},
+ {regex: "/", token: "string.regex", next: "format"},
+ {"token": "string.regex", regex:"."}
+ ],
+ charClass : [
+ {regex: "\\.", token: "escape"},
+ {regex: "\\]", token: "regex.end", next: "regexp"},
+ {"token": "string.regex", regex:"."}
+ ],
+ "format" : [
+ {regex: /\\[ulULE]/, token: "keyword"},
+ {regex: /\$\d+/, token: "variable"},
+ {regex: "/[gim]*:?", token: "string.regex", next: "start"},
+ {"token": "string", regex:"."}
+ ]
+ };
+};
+oop.inherits(SnippetHighlightRules, TextHighlightRules);
+
+exports.SnippetHighlightRules = SnippetHighlightRules;
+
+var SnippetGroupHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {token: "text", regex: "^\\t", next: "sn-start"},
+ {token:"invalid", regex: /^ \s*/},
+ {token:"comment", regex: /^#.*/},
+ {token:"constant.language.escape", regex: "^regex ", next: "regex"},
+ {token:"constant.language.escape", regex: "^(trigger|endTrigger|name|snippet|guard|endGuard|tabTrigger|key)\\b"}
+ ],
+ "regex" : [
+ {token:"text", regex: "\\."},
+ {token:"keyword", regex: "/"},
+ {token:"empty", regex: "$", next: "start"}
+ ]
+ };
+ this.embedRules(SnippetHighlightRules, "sn-", [
+ {token: "text", regex: "^\\t", next: "sn-start"},
+ {onMatch: function(value, state, stack) {
+ stack.splice(stack.length);
+ return this.tokenName;
+ }, tokenName: "text", regex: "^(?!\t)", next: "start"}
+ ])
+
+};
+
+oop.inherits(SnippetGroupHighlightRules, TextHighlightRules);
+
+exports.SnippetGroupHighlightRules = SnippetGroupHighlightRules;
+
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = SnippetGroupHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$indentWithTabs = true;
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/snippets";
+}).call(Mode.prototype);
+exports.Mode = Mode;
+
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-soy_template.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-soy_template.js
new file mode 100644
index 00000000..df831bb3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-soy_template.js
@@ -0,0 +1,2819 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/soy_template_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var SoyTemplateHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var soyRules = { start:
+ [ { include: '#template' },
+ { include: '#if' },
+ { include: '#comment-line' },
+ { include: '#comment-block' },
+ { include: '#comment-doc' },
+ { include: '#call' },
+ { include: '#css' },
+ { include: '#param' },
+ { include: '#print' },
+ { include: '#msg' },
+ { include: '#for' },
+ { include: '#foreach' },
+ { include: '#switch' },
+ { include: '#tag' },
+ { include: 'text.html.basic' } ],
+ '#call':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.call.soy' ],
+ regex: '(\\{/?)(\\s*)(?=call|delcall)',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#string-quoted-single' },
+ { include: '#string-quoted-double' },
+ { token: ['entity.name.tag.soy', 'variable.parameter.soy'],
+ regex: '(call|delcall)(\\s+[\\.\\w]+)'},
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy' ],
+ regex: '\\b(data)(\\s*)(=)' },
+ { defaultToken: 'meta.tag.call.soy' } ] } ],
+ '#comment-line':
+ [ { token:
+ [ 'comment.line.double-slash.soy',
+ 'comment.line.double-slash.soy' ],
+ regex: '(//)(.*$)' } ],
+ '#comment-block':
+ [ { token: 'punctuation.definition.comment.begin.soy',
+ regex: '/\\*(?!\\*)',
+ push:
+ [ { token: 'punctuation.definition.comment.end.soy',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.soy' } ] } ],
+ '#comment-doc':
+ [ { token: 'punctuation.definition.comment.begin.soy',
+ regex: '/\\*\\*(?!/)',
+ push:
+ [ { token: 'punctuation.definition.comment.end.soy',
+ regex: '\\*/',
+ next: 'pop' },
+ { token: [ 'support.type.soy', 'text', 'variable.parameter.soy' ],
+ regex: '(@param|@param\\?)(\\s+)(\\w+)' },
+ { defaultToken: 'comment.block.documentation.soy' } ] } ],
+ '#css':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.css.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(css)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { token: 'support.constant.soy',
+ regex: '\\b(?:LITERAL|REFERENCE|BACKEND_SPECIFIC|GOOG)\\b' },
+ { defaultToken: 'meta.tag.css.soy' } ] } ],
+ '#for':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.for.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(for)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { token: 'keyword.operator.soy', regex: '\\bin\\b' },
+ { token: 'support.function.soy', regex: '\\brange\\b' },
+ { include: '#variable' },
+ { include: '#number' },
+ { include: '#primitive' },
+ { defaultToken: 'meta.tag.for.soy' } ] } ],
+ '#foreach':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.foreach.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(foreach)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { token: 'keyword.operator.soy', regex: '\\bin\\b' },
+ { include: '#variable' },
+ { defaultToken: 'meta.tag.foreach.soy' } ] } ],
+ '#function':
+ [ { token: 'support.function.soy',
+ regex: '\\b(?:isFirst|isLast|index|hasData|length|keys|round|floor|ceiling|min|max|randomInt)\\b' } ],
+ '#if':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.if.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(if|elseif)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#variable' },
+ { include: '#operator' },
+ { include: '#function' },
+ { include: '#string-quoted-single' },
+ { include: '#string-quoted-double' },
+ { defaultToken: 'meta.tag.if.soy' } ] } ],
+ '#namespace':
+ [ { token: [ 'entity.name.tag.soy', 'text', 'variable.parameter.soy' ],
+ regex: '(namespace|delpackage)(\\s+)([\\w\\.]+)' } ],
+ '#number': [ { token: 'constant.numeric', regex: '[\\d]+' } ],
+ '#operator':
+ [ { token: 'keyword.operator.soy',
+ regex: '==|!=|\\band\\b|\\bor\\b|\\bnot\\b|-|\\+|/|\\?:' } ],
+ '#param':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.param.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(param)',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#variable' },
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy' ],
+ regex: '\\b([\\w]+)(\\s*)((?::)?)' },
+ { defaultToken: 'meta.tag.param.soy' } ] } ],
+ '#primitive':
+ [ { token: 'constant.language.soy',
+ regex: '\\b(?:null|false|true)\\b' } ],
+ '#msg':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.msg.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(msg)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#string-quoted-single' },
+ { include: '#string-quoted-double' },
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy' ],
+ regex: '\\b(meaning|desc)(\\s*)(=)' },
+ { defaultToken: 'meta.tag.msg.soy' } ] } ],
+ '#print':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.print.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(print)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#variable' },
+ { include: '#print-parameter' },
+ { include: '#number' },
+ { include: '#primitive' },
+ { include: '#attribute-lookup' },
+ { defaultToken: 'meta.tag.print.soy' } ] } ],
+ '#print-parameter':
+ [ { token: 'keyword.operator.soy', regex: '\\|' },
+ { token: 'variable.parameter.soy',
+ regex: 'noAutoescape|id|escapeHtml|escapeJs|insertWorkBreaks|truncate' } ],
+ '#special-character':
+ [ { token: 'support.constant.soy',
+ regex: '\\bsp\\b|\\bnil\\b|\\\\r|\\\\n|\\\\t|\\blb\\b|\\brb\\b' } ],
+ '#string-quoted-double': [ { token: 'string.quoted.double', regex: '"[^"]*"' } ],
+ '#string-quoted-single': [ { token: 'string.quoted.single', regex: '\'[^\']*\'' } ],
+ '#switch':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.switch.soy',
+ 'entity.name.tag.soy' ],
+ regex: '(\\{/?)(\\s*)(switch|case)\\b',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#variable' },
+ { include: '#function' },
+ { include: '#number' },
+ { include: '#string-quoted-single' },
+ { include: '#string-quoted-double' },
+ { defaultToken: 'meta.tag.switch.soy' } ] } ],
+ '#attribute-lookup':
+ [ { token: 'punctuation.definition.attribute-lookup.begin.soy',
+ regex: '\\[',
+ push:
+ [ { token: 'punctuation.definition.attribute-lookup.end.soy',
+ regex: '\\]',
+ next: 'pop' },
+ { include: '#variable' },
+ { include: '#function' },
+ { include: '#operator' },
+ { include: '#number' },
+ { include: '#primitive' },
+ { include: '#string-quoted-single' },
+ { include: '#string-quoted-double' } ] } ],
+ '#tag':
+ [ { token: 'punctuation.definition.tag.begin.soy',
+ regex: '\\{',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { include: '#namespace' },
+ { include: '#variable' },
+ { include: '#special-character' },
+ { include: '#tag-simple' },
+ { include: '#function' },
+ { include: '#operator' },
+ { include: '#attribute-lookup' },
+ { include: '#number' },
+ { include: '#primitive' },
+ { include: '#print-parameter' } ] } ],
+ '#tag-simple':
+ [ { token: 'entity.name.tag.soy',
+ regex: '{{\\s*(?:literal|else|ifempty|default)\\s*(?=\\})'} ],
+ '#template':
+ [ { token:
+ [ 'punctuation.definition.tag.begin.soy',
+ 'meta.tag.template.soy' ],
+ regex: '(\\{/?)(\\s*)(?=template|deltemplate)',
+ push:
+ [ { token: 'punctuation.definition.tag.end.soy',
+ regex: '\\}',
+ next: 'pop' },
+ { token: ['entity.name.tag.soy', 'text', 'entity.name.function.soy' ],
+ regex: '(template|deltemplate)(\\s+)([\\.\\w]+)',
+ originalRegex: '(?<=template|deltemplate)\\s+([\\.\\w]+)' },
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy',
+ 'text',
+ 'string.quoted.double.soy' ],
+ regex: '\\b(private)(\\s*)(=)(\\s*)("true"|"false")' },
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy',
+ 'text',
+ 'string.quoted.single.soy' ],
+ regex: '\\b(private)(\\s*)(=)(\\s*)(\'true\'|\'false\')' },
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy',
+ 'text',
+ 'string.quoted.double.soy' ],
+ regex: '\\b(autoescape)(\\s*)(=)(\\s*)("true"|"false"|"contextual")' },
+ { token:
+ [ 'entity.other.attribute-name.soy',
+ 'text',
+ 'keyword.operator.soy',
+ 'text',
+ 'string.quoted.single.soy' ],
+ regex: '\\b(autoescape)(\\s*)(=)(\\s*)(\'true\'|\'false\'|\'contextual\')' },
+ { defaultToken: 'meta.tag.template.soy' } ] } ],
+ '#variable': [ { token: 'variable.other.soy', regex: '\\$[\\w\\.]+' } ] }
+
+
+ for (var i in soyRules) {
+ if (this.$rules[i]) {
+ this.$rules[i].unshift.apply(this.$rules[i], soyRules[i]);
+ } else {
+ this.$rules[i] = soyRules[i];
+ }
+ }
+
+ this.normalizeRules();
+};
+
+SoyTemplateHighlightRules.metaData = { comment: 'SoyTemplate',
+ fileTypes: [ 'soy' ],
+ firstLineMatch: '\\{\\s*namespace\\b',
+ foldingStartMarker: '\\{\\s*template\\s+[^\\}]*\\}',
+ foldingStopMarker: '\\{\\s*/\\s*template\\s*\\}',
+ name: 'SoyTemplate',
+ scopeName: 'source.soy' }
+
+
+oop.inherits(SoyTemplateHighlightRules, HtmlHighlightRules);
+
+exports.SoyTemplateHighlightRules = SoyTemplateHighlightRules;
+});
+
+ace.define("ace/mode/soy_template",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/soy_template_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var SoyTemplateHighlightRules = require("./soy_template_highlight_rules").SoyTemplateHighlightRules;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = SoyTemplateHighlightRules;
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$id = "ace/mode/soy_template";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-space.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-space.js
new file mode 100644
index 00000000..5bbeb482
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-space.js
@@ -0,0 +1,160 @@
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/space_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SpaceHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "empty_line",
+ regex : / */,
+ next : "key"
+ },
+ {
+ token : "empty_line",
+ regex : /$/,
+ next : "key"
+ }
+ ],
+ "key" : [
+ {
+ token : "variable",
+ regex : /\S+/
+ },
+ {
+ token : "empty_line",
+ regex : /$/,
+ next : "start"
+ },{
+ token : "keyword.operator",
+ regex : / /,
+ next : "value"
+ }
+ ],
+ "value" : [
+ {
+ token : "keyword.operator",
+ regex : /$/,
+ next : "start"
+ },
+ {
+ token : "string",
+ regex : /[^$]/
+ }
+ ]
+ };
+
+};
+
+oop.inherits(SpaceHighlightRules, TextHighlightRules);
+
+exports.SpaceHighlightRules = SpaceHighlightRules;
+});
+
+ace.define("ace/mode/space",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/folding/coffee","ace/mode/space_highlight_rules"], function(require, exports, module) {
+"use strict";
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var FoldMode = require("./folding/coffee").FoldMode;
+var SpaceHighlightRules = require("./space_highlight_rules").SpaceHighlightRules;
+var Mode = function() {
+ this.HighlightRules = SpaceHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+(function() {
+
+ this.$id = "ace/mode/space";
+}).call(Mode.prototype);
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-sparql.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-sparql.js
new file mode 100644
index 00000000..e5a58542
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-sparql.js
@@ -0,0 +1,313 @@
+ace.define("ace/mode/sparql_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SPARQLHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ include: "#comments"
+ }, {
+ include: "#strings"
+ }, {
+ include: "#string-language-suffixes"
+ }, {
+ include: "#string-datatype-suffixes"
+ }, {
+ include: "#logic-operators"
+ }, {
+ include: "#relative-urls"
+ }, {
+ include: "#xml-schema-types"
+ }, {
+ include: "#rdf-schema-types"
+ }, {
+ include: "#owl-types"
+ }, {
+ include: "#qnames"
+ }, {
+ include: "#keywords"
+ }, {
+ include: "#built-in-functions"
+ }, {
+ include: "#variables"
+ }, {
+ include: "#boolean-literal"
+ }, {
+ include: "#punctuation-operators"
+ }],
+ "#boolean-literal": [{
+ token: "constant.language.boolean.sparql",
+ regex: /true|false/
+ }],
+ "#built-in-functions": [{
+ token: "support.function.sparql",
+ regex: /[Aa][Bb][Ss]|[Aa][Vv][Gg]|[Bb][Nn][Oo][Dd][Ee]|[Bb][Oo][Uu][Nn][Dd]|[Cc][Ee][Ii][Ll]|[Cc][Oo][Aa][Ll][Ee][Ss][Cc][Ee]|[Cc][Oo][Nn][Cc][Aa][Tt]|[Cc][Oo][Nn][Tt][Aa][Ii][Nn][Ss]|[Cc][Oo][Uu][Nn][Tt]|[Dd][Aa][Tt][Aa][Tt][Yy][Pp][Ee]|[Dd][Aa][Yy]|[Ee][Nn][Cc][Oo][Dd][Ee]_[Ff][Oo][Rr]_[Uu][Rr][Ii]|[Ee][Xx][Ii][Ss][Tt][Ss]|[Ff][Ll][Oo][Oo][Rr]|[Gg][Rr][Oo][Uu][Pp]_[Cc][Oo][Nn][Cc][Aa][Tt]|[Hh][Oo][Uu][Rr][Ss]|[Ii][Ff]|[Ii][Rr][Ii]|[Ii][Ss][Bb][Ll][Aa][Nn][Kk]|[Ii][Ss][Ii][Rr][Ii]|[Ii][Ss][Ll][Ii][Tt][Ee][Rr][Aa][Ll]|[Ii][Ss][Nn][Uu][Mm][Ee][Rr][Ii][Cc]|[Ii][Ss][Uu][Rr][Ii]|[Ll][Aa][Nn][Gg]|[Ll][Aa][Nn][Gg][Mm][Aa][Tt][Cc][Hh][Ee][Ss]|[Ll][Cc][Aa][Ss][Ee]|[Mm][Aa][Xx]|[Mm][Dd]5|[Mm][Ii][Nn]|[Mm][Ii][Nn][Uu][Tt][Ee][Ss]|[Mm][Oo][Nn][Tt][Hh]|[Nn][Oo][Ww]|[Rr][Aa][Nn][Dd]|[Rr][Ee][Gg][Ee][Xx]|[Rr][Ee][Pp][Ll][Aa][Cc][Ee]|[Rr][Oo][Uu][Nn][Dd]|[Ss][Aa][Mm][Ee][Tt][Ee][Rr][Mm]|[Ss][Aa][Mm][Pp][Ll][Ee]|[Ss][Ee][Cc][Oo][Nn][Dd][Ss]|[Ss][Ee][Pp][Aa][Rr][Aa][Tt][Oo][Rr]|[Ss][Hh][Aa](?:1|256|384|512)|[Ss][Tt][Rr]|[Ss][Tt][Rr][Aa][Ff][Tt][Ee][Rr]|[Ss][Tt][Rr][Bb][Ee][Ff][Oo][Rr][Ee]|[Ss][Tt][Rr][Dd][Tt]|[Ss][Tt][Rr][Ee][Nn][Dd][Ss]|[Ss][Tt][Rr][Ll][Aa][Nn][Gg]|[Ss][Tt][Rr][Ll][Ee][Nn]|[Ss][Tt][Rr][Ss][Tt][Aa][Rr][Tt][Ss]|[Ss][Tt][Rr][Uu][Uu][Ii][Dd]|[Ss][Uu][Bb][Ss][Tt][Rr]|[Ss][Uu][Mm]|[Tt][Ii][Mm][Ee][Zz][Oo][Nn][Ee]|[Tt][Zz]|[Uu][Cc][Aa][Ss][Ee]|[Uu][Rr][Ii]|[Uu][Uu][Ii][Dd]|[Yy][Ee][Aa][Rr]/
+ }],
+ "#comments": [{
+ token: [
+ "punctuation.definition.comment.sparql",
+ "comment.line.hash.sparql"
+ ],
+ regex: /(#)(.*$)/
+ }],
+ "#keywords": [{
+ token: "keyword.other.sparql",
+ regex: /[Aa][Dd][Dd]|[Aa][Ll][Ll]|[Aa][Ss]|[As][Ss][Cc]|[Aa][Ss][Kk]|[Bb][Aa][Ss][Ee]|[Bb][Ii][Nn][Dd]|[Bb][Yy]|[Cc][Ll][Ee][Aa][Rr]|[Cc][Oo][Nn][Ss][Tt][Rr][Uu][Cc][Tt]|[Cc][Oo][Pp][Yy]|[Cc][Rr][Ee][Aa][Tt][Ee]|[Dd][Aa][Tt][Aa]|[Dd][Ee][Ff][Aa][Uu][Ll][Tt]|[Dd][Ee][Ll][Ee][Tt][Ee]|[Dd][Ee][Sc][Cc]|[Dd][Ee][Ss][Cc][Rr][Ii][Bb][Ee]|[Dd][Ii][Ss][Tt][Ii][Nn][Cc][Tt]|[Dd][Rr][Oo][Pp]|[Ff][Ii][Ll][Tt][Ee][Rr]|[Ff][Rr][Oo][Mm]|[Gg][Rr][Aa][Pp][Hh]|[Gg][Rr][Oo][Uu][Pp]|[Hh][Aa][Vv][Ii][Nn][Gg]|[Ii][Nn][Ss][Ee][Rr][Tt]|[Ll][Ii][Mm][Ii][Tt]|[Ll][Oo][Aa][Dd]|[Mm][Ii][Nn][Uu][Ss]|[Mm][Oo][Vv][Ee]|[Nn][Aa][Mm][Ee][Dd]|[Oo][Ff][Ff][Ss][Ee][Tt]|[Oo][Pp][Tt][Ii][Oo][Nn][Aa][Ll]|[Oo][Rr][Dd][Ee][Rr]|[Pp][Rr][Ee][Ff][Ii][Xx]|[Rr][Ee][Dd][Uu][Cc][Ee][Dd]|[Ss][Ee][Ll][Ee][Cc][Tt]|[Ss][Ee][Pp][Aa][Rr][Aa][Tt][Oo][Rr]|[Ss][Ee][Rr][Vv][Ii][Cc][Ee]|[Ss][Ii][Ll][Ee][Nn][Tt]|[Tt][Oo]|[Uu][Nn][Dd][Ee][Ff]|[Uu][Nn][Ii][Oo][Nn]|[Uu][Ss][Ii][Nn][Gg]|[Vv][Aa][Ll][Uu][Ee][Ss]|[Ww][He][Ee][Rr][Ee]|[Ww][Ii][Tt][Hh]/
+ }],
+ "#logic-operators": [{
+ token: "keyword.operator.logical.sparql",
+ regex: /\|\||&&|=|!=|<|>|<=|>=|(?:^|!?\s)IN(?:!?\s|$)|(?:^|!?\s)NOT(?:!?\s|$)|-|\+|\*|\/|\!/
+ }],
+ "#owl-types": [{
+ token: "support.type.datatype.owl.sparql",
+ regex: /owl:[a-zA-Z]+/
+ }],
+ "#punctuation-operators": [{
+ token: "keyword.operator.punctuation.sparql",
+ regex: /;|,|\.|\(|\)|\{|\}|\|/
+ }],
+ "#qnames": [{
+ token: "entity.name.other.qname.sparql",
+ regex: /(?:[a-zA-Z][-_a-zA-Z0-9]*)?:(?:[_a-zA-Z][-_a-zA-Z0-9]*)?/
+ }],
+ "#rdf-schema-types": [{
+ token: "support.type.datatype.rdf.schema.sparql",
+ regex: /rdfs?:[a-zA-Z]+|(?:^|\s)a(?:\s|$)/
+ }],
+ "#relative-urls": [{
+ token: "string.quoted.other.relative.url.sparql",
+ regex: /</,
+ push: [{
+ token: "string.quoted.other.relative.url.sparql",
+ regex: />/,
+ next: "pop"
+ }, {
+ defaultToken: "string.quoted.other.relative.url.sparql"
+ }]
+ }],
+ "#string-datatype-suffixes": [{
+ token: "keyword.operator.datatype.suffix.sparql",
+ regex: /\^\^/
+ }],
+ "#string-language-suffixes": [{
+ token: [
+ "keyword.operator.language.suffix.sparql",
+ "constant.language.suffix.sparql"
+ ],
+ regex: /(?!")(@)([a-z]+(?:\-[a-z0-9]+)*)/
+ }],
+ "#strings": [{
+ token: "string.quoted.triple.sparql",
+ regex: /"""/,
+ push: [{
+ token: "string.quoted.triple.sparql",
+ regex: /"""/,
+ next: "pop"
+ }, {
+ defaultToken: "string.quoted.triple.sparql"
+ }]
+ }, {
+ token: "string.quoted.double.sparql",
+ regex: /"/,
+ push: [{
+ token: "string.quoted.double.sparql",
+ regex: /"/,
+ next: "pop"
+ }, {
+ token: "invalid.string.newline",
+ regex: /$/
+ }, {
+ token: "constant.character.escape.sparql",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.double.sparql"
+ }]
+ }],
+ "#variables": [{
+ token: "variable.other.sparql",
+ regex: /(?:\?|\$)[-_a-zA-Z0-9]+/
+ }],
+ "#xml-schema-types": [{
+ token: "support.type.datatype.schema.sparql",
+ regex: /xsd?:[a-z][a-zA-Z]+/
+ }]
+ }
+
+ this.normalizeRules();
+};
+
+SPARQLHighlightRules.metaData = {
+ fileTypes: ["rq", "sparql"],
+ name: "SPARQL",
+ scopeName: "source.sparql"
+}
+
+
+oop.inherits(SPARQLHighlightRules, TextHighlightRules);
+
+exports.SPARQLHighlightRules = SPARQLHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/sparql",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sparql_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var SPARQLHighlightRules = require("./sparql_highlight_rules").SPARQLHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = SPARQLHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$id = "ace/mode/sparql"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-sql.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-sql.js
new file mode 100644
index 00000000..9678787a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-sql.js
@@ -0,0 +1,103 @@
+ace.define("ace/mode/sql_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SqlHighlightRules = function() {
+
+ var keywords = (
+ "select|insert|update|delete|from|where|and|or|group|by|order|limit|offset|having|as|case|" +
+ "when|else|end|type|left|right|join|on|outer|desc|asc|union|create|table|primary|key|if|" +
+ "foreign|not|references|default|null|inner|cross|natural|database|drop|grant"
+ );
+
+ var builtinConstants = (
+ "true|false"
+ );
+
+ var builtinFunctions = (
+ "avg|count|first|last|max|min|sum|ucase|lcase|mid|len|round|rank|now|format|" +
+ "coalesce|ifnull|isnull|nvl"
+ );
+
+ var dataTypes = (
+ "int|numeric|decimal|date|varchar|char|bigint|float|double|bit|binary|text|set|timestamp|" +
+ "money|real|number|integer"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords,
+ "constant.language": builtinConstants,
+ "storage.type": dataTypes
+ }, "identifier", true);
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "--.*$"
+ }, {
+ token : "comment",
+ start : "/\\*",
+ end : "\\*/"
+ }, {
+ token : "string", // " string
+ regex : '".*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'.*?'"
+ }, {
+ token : "string", // ` string (apache drill)
+ regex : "`.*?`"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+ };
+ this.normalizeRules();
+};
+
+oop.inherits(SqlHighlightRules, TextHighlightRules);
+
+exports.SqlHighlightRules = SqlHighlightRules;
+});
+
+ace.define("ace/mode/sql",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sql_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var SqlHighlightRules = require("./sql_highlight_rules").SqlHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = SqlHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "--";
+
+ this.$id = "ace/mode/sql";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-sqlserver.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-sqlserver.js
new file mode 100644
index 00000000..59e9b907
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-sqlserver.js
@@ -0,0 +1,437 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/sqlserver_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SqlServerHighlightRules = function() {
+ var logicalOperators = "ALL|AND|ANY|BETWEEN|EXISTS|IN|LIKE|NOT|OR|SOME";
+ logicalOperators += "|NULL|IS|APPLY|INNER|OUTER|LEFT|RIGHT|JOIN|CROSS"; //SSMS colors these gray too
+
+
+ var builtinFunctions = (
+ "OPENDATASOURCE|OPENQUERY|OPENROWSET|OPENXML|" +
+ "AVG|CHECKSUM_AGG|COUNT|COUNT_BIG|GROUPING|GROUPING_ID|MAX|MIN|STDEV|STDEVP|SUM|VAR|VARP|" +
+ "DENSE_RANK|NTILE|RANK|ROW_NUMBER" +
+ "@@DATEFIRST|@@DBTS|@@LANGID|@@LANGUAGE|@@LOCK_TIMEOUT|@@MAX_CONNECTIONS|@@MAX_PRECISION|@@NESTLEVEL|@@OPTIONS|@@REMSERVER|@@SERVERNAME|@@SERVICENAME|@@SPID|@@TEXTSIZE|@@VERSION|" +
+ "CAST|CONVERT|PARSE|TRY_CAST|TRY_CONVERT|TRY_PARSE" +
+ "@@CURSOR_ROWS|@@FETCH_STATUS|CURSOR_STATUS|" +
+ "@@DATEFIRST|@@LANGUAGE|CURRENT_TIMESTAMP|DATEADD|DATEDIFF|DATEFROMPARTS|DATENAME|DATEPART|DATETIME2FROMPARTS|DATETIMEFROMPARTS|DATETIMEOFFSETFROMPARTS|DAY|EOMONTH|GETDATE|GETUTCDATE|ISDATE|MONTH|SET DATEFIRST|SET DATEFORMAT|SET LANGUAGE|SMALLDATETIMEFROMPARTS|SP_HELPLANGUAGE|SWITCHOFFSET|SYSDATETIME|SYSDATETIMEOFFSET|SYSUTCDATETIME|TIMEFROMPARTS|TODATETIMEOFFSET|YEAR|" +
+ "CHOOSE|IIF|" +
+ "ABS|ACOS|ASIN|ATAN|ATN2|CEILING|COS|COT|DEGREES|EXP|FLOOR|LOG|LOG10|PI|POWER|RADIANS|RAND|ROUND|SIGN|SIN|SQRT|SQUARE|TAN|" +
+ "@@PROCID|APPLOCK_MODE|APPLOCK_TEST|APP_NAME|ASSEMBLYPROPERTY|COLUMNPROPERTY|COL_LENGTH|COL_NAME|DATABASEPROPERTYEX|DATABASE_PRINCIPAL_ID|DB_ID|DB_NAME|FILEGROUPPROPERTY|FILEGROUP_ID|FILEGROUP_NAME|FILEPROPERTY|FILE_ID|FILE_IDEX|FILE_NAME|FULLTEXTCATALOGPROPERTY|FULLTEXTSERVICEPROPERTY|INDEXKEY_PROPERTY|INDEXPROPERTY|INDEX_COL|OBJECTPROPERTY|OBJECTPROPERTYEX|OBJECT_DEFINITION|OBJECT_ID|OBJECT_NAME|OBJECT_SCHEMA_NAME|ORIGINAL_DB_NAME|PARSENAME|SCHEMA_ID|SCHEMA_NAME|SCOPE_IDENTITY|SERVERPROPERTY|STATS_DATE|TYPEPROPERTY|TYPE_ID|TYPE_NAME|" +
+ "CERTENCODED|CERTPRIVATEKEY|CURRENT_USER|DATABASE_PRINCIPAL_ID|HAS_PERMS_BY_NAME|IS_MEMBER|IS_ROLEMEMBER|IS_SRVROLEMEMBER|ORIGINAL_LOGIN|PERMISSIONS|PWDCOMPARE|PWDENCRYPT|SCHEMA_ID|SCHEMA_NAME|SESSION_USER|SUSER_ID|SUSER_NAME|SUSER_SID|SUSER_SNAME|SYS.FN_BUILTIN_PERMISSIONS|SYS.FN_GET_AUDIT_FILE|SYS.FN_MY_PERMISSIONS|SYSTEM_USER|USER_ID|USER_NAME|" +
+ "ASCII|CHAR|CHARINDEX|CONCAT|DIFFERENCE|FORMAT|LEN|LOWER|LTRIM|NCHAR|PATINDEX|QUOTENAME|REPLACE|REPLICATE|REVERSE|RTRIM|SOUNDEX|SPACE|STR|STUFF|SUBSTRING|UNICODE|UPPER|" +
+ "$PARTITION|@@ERROR|@@IDENTITY|@@PACK_RECEIVED|@@ROWCOUNT|@@TRANCOUNT|BINARY_CHECKSUM|CHECKSUM|CONNECTIONPROPERTY|CONTEXT_INFO|CURRENT_REQUEST_ID|ERROR_LINE|ERROR_MESSAGE|ERROR_NUMBER|ERROR_PROCEDURE|ERROR_SEVERITY|ERROR_STATE|FORMATMESSAGE|GETANSINULL|GET_FILESTREAM_TRANSACTION_CONTEXT|HOST_ID|HOST_NAME|ISNULL|ISNUMERIC|MIN_ACTIVE_ROWVERSION|NEWID|NEWSEQUENTIALID|ROWCOUNT_BIG|XACT_STATE|" +
+ "@@CONNECTIONS|@@CPU_BUSY|@@IDLE|@@IO_BUSY|@@PACKET_ERRORS|@@PACK_RECEIVED|@@PACK_SENT|@@TIMETICKS|@@TOTAL_ERRORS|@@TOTAL_READ|@@TOTAL_WRITE|FN_VIRTUALFILESTATS|" +
+ "PATINDEX|TEXTPTR|TEXTVALID|" +
+ "COALESCE|NULLIF"
+ );
+ var dataTypes = ("BIGINT|BINARY|BIT|CHAR|CURSOR|DATE|DATETIME|DATETIME2|DATETIMEOFFSET|DECIMAL|FLOAT|HIERARCHYID|IMAGE|INTEGER|INT|MONEY|NCHAR|NTEXT|NUMERIC|NVARCHAR|REAL|SMALLDATETIME|SMALLINT|SMALLMONEY|SQL_VARIANT|TABLE|TEXT|TIME|TIMESTAMP|TINYINT|UNIQUEIDENTIFIER|VARBINARY|VARCHAR|XML");
+ var builtInStoredProcedures = "sp_addextendedproc|sp_addextendedproperty|sp_addmessage|sp_addtype|sp_addumpdevice|sp_add_data_file_recover_suspect_db|sp_add_log_file_recover_suspect_db|sp_altermessage|sp_attach_db|sp_attach_single_file_db|sp_autostats|sp_bindefault|sp_bindrule|sp_bindsession|sp_certify_removable|sp_clean_db_file_free_space|sp_clean_db_free_space|sp_configure|sp_control_plan_guide|sp_createstats|sp_create_plan_guide|sp_create_plan_guide_from_handle|sp_create_removable|sp_cycle_errorlog|sp_datatype_info|sp_dbcmptlevel|sp_dbmmonitoraddmonitoring|sp_dbmmonitorchangealert|sp_dbmmonitorchangemonitoring|sp_dbmmonitordropalert|sp_dbmmonitordropmonitoring|sp_dbmmonitorhelpalert|sp_dbmmonitorhelpmonitoring|sp_dbmmonitorresults|sp_db_increased_partitions|sp_delete_backuphistory|sp_depends|sp_describe_first_result_set|sp_describe_undeclared_parameters|sp_detach_db|sp_dropdevice|sp_dropextendedproc|sp_dropextendedproperty|sp_dropmessage|sp_droptype|sp_execute|sp_executesql|sp_getapplock|sp_getbindtoken|sp_help|sp_helpconstraint|sp_helpdb|sp_helpdevice|sp_helpextendedproc|sp_helpfile|sp_helpfilegroup|sp_helpindex|sp_helplanguage|sp_helpserver|sp_helpsort|sp_helpstats|sp_helptext|sp_helptrigger|sp_indexoption|sp_invalidate_textptr|sp_lock|sp_monitor|sp_prepare|sp_prepexec|sp_prepexecrpc|sp_procoption|sp_recompile|sp_refreshview|sp_releaseapplock|sp_rename|sp_renamedb|sp_resetstatus|sp_sequence_get_range|sp_serveroption|sp_setnetname|sp_settriggerorder|sp_spaceused|sp_tableoption|sp_unbindefault|sp_unbindrule|sp_unprepare|sp_updateextendedproperty|sp_updatestats|sp_validname|sp_who|sys.sp_merge_xtp_checkpoint_files|sys.sp_xtp_bind_db_resource_pool|sys.sp_xtp_checkpoint_force_garbage_collection|sys.sp_xtp_control_proc_exec_stats|sys.sp_xtp_control_query_exec_stats|sys.sp_xtp_unbind_db_resource_pool";
+ var keywords = "ABSOLUTE|ACTION|ADA|ADD|ADMIN|AFTER|AGGREGATE|ALIAS|ALL|ALLOCATE|ALTER|AND|ANY|ARE|ARRAY|AS|ASC|ASENSITIVE|ASSERTION|ASYMMETRIC|AT|ATOMIC|AUTHORIZATION|BACKUP|BEFORE|BEGIN|BETWEEN|BIT_LENGTH|BLOB|BOOLEAN|BOTH|BREADTH|BREAK|BROWSE|BULK|BY|CALL|CALLED|CARDINALITY|CASCADE|CASCADED|CASE|CATALOG|CHARACTER|CHARACTER_LENGTH|CHAR_LENGTH|CHECK|CHECKPOINT|CLASS|CLOB|CLOSE|CLUSTERED|COALESCE|COLLATE|COLLATION|COLLECT|COLUMN|COMMIT|COMPLETION|COMPUTE|CONDITION|CONNECT|CONNECTION|CONSTRAINT|CONSTRAINTS|CONSTRUCTOR|CONTAINS|CONTAINSTABLE|CONTINUE|CORR|CORRESPONDING|COVAR_POP|COVAR_SAMP|CREATE|CROSS|CUBE|CUME_DIST|CURRENT|CURRENT_CATALOG|CURRENT_DATE|CURRENT_DEFAULT_TRANSFORM_GROUP|CURRENT_PATH|CURRENT_ROLE|CURRENT_SCHEMA|CURRENT_TIME|CURRENT_TRANSFORM_GROUP_FOR_TYPE|CYCLE|DATA|DATABASE|DBCC|DEALLOCATE|DEC|DECLARE|DEFAULT|DEFERRABLE|DEFERRED|DELETE|DENY|DEPTH|DEREF|DESC|DESCRIBE|DESCRIPTOR|DESTROY|DESTRUCTOR|DETERMINISTIC|DIAGNOSTICS|DICTIONARY|DISCONNECT|DISK|DISTINCT|DISTRIBUTED|DOMAIN|DOUBLE|DROP|DUMP|DYNAMIC|EACH|ELEMENT|ELSE|END|END-EXEC|EQUALS|ERRLVL|ESCAPE|EVERY|EXCEPT|EXCEPTION|EXEC|EXECUTE|EXISTS|EXIT|EXTERNAL|EXTRACT|FETCH|FILE|FILLFACTOR|FILTER|FIRST|FOR|FOREIGN|FORTRAN|FOUND|FREE|FREETEXT|FREETEXTTABLE|FROM|FULL|FULLTEXTTABLE|FUNCTION|FUSION|GENERAL|GET|GLOBAL|GO|GOTO|GRANT|GROUP|HAVING|HOLD|HOLDLOCK|HOST|HOUR|IDENTITY|IDENTITYCOL|IDENTITY_INSERT|IF|IGNORE|IMMEDIATE|IN|INCLUDE|INDEX|INDICATOR|INITIALIZE|INITIALLY|INNER|INOUT|INPUT|INSENSITIVE|INSERT|INTEGER|INTERSECT|INTERSECTION|INTERVAL|INTO|IS|ISOLATION|ITERATE|JOIN|KEY|KILL|LANGUAGE|LARGE|LAST|LATERAL|LEADING|LESS|LEVEL|LIKE|LIKE_REGEX|LIMIT|LINENO|LN|LOAD|LOCAL|LOCALTIME|LOCALTIMESTAMP|LOCATOR|MAP|MATCH|MEMBER|MERGE|METHOD|MINUTE|MOD|MODIFIES|MODIFY|MODULE|MULTISET|NAMES|NATIONAL|NATURAL|NCLOB|NEW|NEXT|NO|NOCHECK|NONCLUSTERED|NONE|NORMALIZE|NOT|NULL|NULLIF|OBJECT|OCCURRENCES_REGEX|OCTET_LENGTH|OF|OFF|OFFSETS|OLD|ON|ONLY|OPEN|OPERATION|OPTION|OR|ORDER|ORDINALITY|OUT|OUTER|OUTPUT|OVER|OVERLAPS|OVERLAY|PAD|PARAMETER|PARAMETERS|PARTIAL|PARTITION|PASCAL|PATH|PERCENT|PERCENTILE_CONT|PERCENTILE_DISC|PERCENT_RANK|PIVOT|PLAN|POSITION|POSITION_REGEX|POSTFIX|PRECISION|PREFIX|PREORDER|PREPARE|PRESERVE|PRIMARY|PRINT|PRIOR|PRIVILEGES|PROC|PROCEDURE|PUBLIC|RAISERROR|RANGE|READ|READS|READTEXT|RECONFIGURE|RECURSIVE|REF|REFERENCES|REFERENCING|REGR_AVGX|REGR_AVGY|REGR_COUNT|REGR_INTERCEPT|REGR_R2|REGR_SLOPE|REGR_SXX|REGR_SXY|REGR_SYY|RELATIVE|RELEASE|REPLICATION|RESTORE|RESTRICT|RESULT|RETURN|RETURNS|REVERT|REVOKE|ROLE|ROLLBACK|ROLLUP|ROUTINE|ROW|ROWCOUNT|ROWGUIDCOL|ROWS|RULE|SAVE|SAVEPOINT|SCHEMA|SCOPE|SCROLL|SEARCH|SECOND|SECTION|SECURITYAUDIT|SELECT|SEMANTICKEYPHRASETABLE|SEMANTICSIMILARITYDETAILSTABLE|SEMANTICSIMILARITYTABLE|SENSITIVE|SEQUENCE|SESSION|SET|SETS|SETUSER|SHUTDOWN|SIMILAR|SIZE|SOME|SPECIFIC|SPECIFICTYPE|SQL|SQLCA|SQLCODE|SQLERROR|SQLEXCEPTION|SQLSTATE|SQLWARNING|START|STATE|STATEMENT|STATIC|STATISTICS|STDDEV_POP|STDDEV_SAMP|STRUCTURE|SUBMULTISET|SUBSTRING_REGEX|SYMMETRIC|SYSTEM|TABLESAMPLE|TEMPORARY|TERMINATE|TEXTSIZE|THAN|THEN|TIMEZONE_HOUR|TIMEZONE_MINUTE|TO|TOP|TRAILING|TRAN|TRANSACTION|TRANSLATE|TRANSLATE_REGEX|TRANSLATION|TREAT|TRIGGER|TRIM|TRUNCATE|TSEQUAL|UESCAPE|UNDER|UNION|UNIQUE|UNKNOWN|UNNEST|UNPIVOT|UPDATE|UPDATETEXT|USAGE|USE|USER|USING|VALUE|VALUES|VARIABLE|VARYING|VAR_POP|VAR_SAMP|VIEW|WAITFOR|WHEN|WHENEVER|WHERE|WHILE|WIDTH_BUCKET|WINDOW|WITH|WITHIN|WITHIN GROUP|WITHOUT|WORK|WRITE|WRITETEXT|XMLAGG|XMLATTRIBUTES|XMLBINARY|XMLCAST|XMLCOMMENT|XMLCONCAT|XMLDOCUMENT|XMLELEMENT|XMLEXISTS|XMLFOREST|XMLITERATE|XMLNAMESPACES|XMLPARSE|XMLPI|XMLQUERY|XMLSERIALIZE|XMLTABLE|XMLTEXT|XMLVALIDATE|ZONE";
+ keywords += "|KEEPIDENTITY|KEEPDEFAULTS|IGNORE_CONSTRAINTS|IGNORE_TRIGGERS|XLOCK|FORCESCAN|FORCESEEK|HOLDLOCK|NOLOCK|NOWAIT|PAGLOCK|READCOMMITTED|READCOMMITTEDLOCK|READPAST|READUNCOMMITTED|REPEATABLEREAD|ROWLOCK|SERIALIZABLE|SNAPSHOT|SPATIAL_WINDOW_MAX_CELLS|TABLOCK|TABLOCKX|UPDLOCK|XLOCK|IGNORE_NONCLUSTERED_COLUMNSTORE_INDEX|EXPAND|VIEWS|FAST|FORCE|KEEP|KEEPFIXED|MAXDOP|MAXRECURSION|OPTIMIZE|PARAMETERIZATION|SIMPLE|FORCED|RECOMPILE|ROBUST|PLAN|SPATIAL_WINDOW_MAX_CELLS|NOEXPAND|HINT";
+ keywords += "|LOOP|HASH|MERGE|REMOTE";
+ keywords += "|TRY|CATCH|THROW";
+ keywords += "|TYPE";
+ keywords = keywords.split('|');
+ keywords = keywords.filter(function(value, index, self) {
+ return logicalOperators.split('|').indexOf(value) === -1 && builtinFunctions.split('|').indexOf(value) === -1 && dataTypes.split('|').indexOf(value) === -1;
+ });
+ keywords = keywords.sort().join('|');
+
+
+ var keywordMapper = this.createKeywordMapper({
+ "constant.language": logicalOperators,
+ "storage.type": dataTypes,
+ "support.function": builtinFunctions,
+ "support.storedprocedure": builtInStoredProcedures,
+ "keyword": keywords
+ }, "identifier", true);
+ var setStatements = "SET ANSI_DEFAULTS|SET ANSI_NULLS|SET ANSI_NULL_DFLT_OFF|SET ANSI_NULL_DFLT_ON|SET ANSI_PADDING|SET ANSI_WARNINGS|SET ARITHABORT|SET ARITHIGNORE|SET CONCAT_NULL_YIELDS_NULL|SET CURSOR_CLOSE_ON_COMMIT|SET DATEFIRST|SET DATEFORMAT|SET DEADLOCK_PRIORITY|SET FIPS_FLAGGER|SET FMTONLY|SET FORCEPLAN|SET IDENTITY_INSERT|SET IMPLICIT_TRANSACTIONS|SET LANGUAGE|SET LOCK_TIMEOUT|SET NOCOUNT|SET NOEXEC|SET NUMERIC_ROUNDABORT|SET OFFSETS|SET PARSEONLY|SET QUERY_GOVERNOR_COST_LIMIT|SET QUOTED_IDENTIFIER|SET REMOTE_PROC_TRANSACTIONS|SET ROWCOUNT|SET SHOWPLAN_ALL|SET SHOWPLAN_TEXT|SET SHOWPLAN_XML|SET STATISTICS IO|SET STATISTICS PROFILE|SET STATISTICS TIME|SET STATISTICS XML|SET TEXTSIZE|SET XACT_ABORT".split('|');
+ var isolationLevels = "READ UNCOMMITTED|READ COMMITTED|REPEATABLE READ|SNAPSHOP|SERIALIZABLE".split('|');
+ for (var i = 0; i < isolationLevels.length; i++) {
+ setStatements.push('SET TRANSACTION ISOLATION LEVEL ' + isolationLevels[i]);
+ }
+
+
+ this.$rules = {
+ start: [{
+ token: "string.start",
+ regex: "'",
+ next: [{
+ token: "constant.language.escape",
+ regex: /''/
+ }, {
+ token: "string.end",
+ next: "start",
+ regex: "'"
+ }, {
+ defaultToken: "string"
+ }]
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"), {
+ token: "comment",
+ regex: "--.*$"
+ }, {
+ token: "comment",
+ start: "/\\*",
+ end: "\\*/"
+ }, {
+ token: "constant.numeric", // float
+ regex: "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token: keywordMapper,
+ regex: "@{0,2}[a-zA-Z_$][a-zA-Z0-9_$]*\\b(?!])" //up to 2 @symbols for some built in functions
+ }, {
+ token: "constant.class",
+ regex: "@@?[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token: "keyword.operator",
+ regex: "\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|=|\\*"
+ }, {
+ token: "paren.lparen",
+ regex: "[\\(]"
+ }, {
+ token: "paren.rparen",
+ regex: "[\\)]"
+ }, {
+ token: "punctuation",
+ regex: ",|;"
+ }, {
+ token: "text",
+ regex: "\\s+"
+ }],
+ comment: [
+ DocCommentHighlightRules.getTagRule(), {
+ token: "comment",
+ regex: "\\*\\/",
+ next: "no_regex"
+ }, {
+ defaultToken: "comment",
+ caseInsensitive: true
+ }]
+ };
+ for (var i = 0; i < setStatements.length; i++) {
+ this.$rules.start.unshift({
+ token: "set.statement",
+ regex: setStatements[i]
+ });
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-", [DocCommentHighlightRules.getEndRule("start")]);
+ this.normalizeRules();
+ var completions = [];
+ var addCompletions = function(arr, meta) {
+ arr.forEach(function(v) {
+ completions.push({
+ name: v,
+ value: v,
+ score: 0,
+ meta: meta
+ });
+ });
+ };
+ addCompletions(builtInStoredProcedures.split('|'), 'procedure');
+ addCompletions(logicalOperators.split('|'), 'operator');
+ addCompletions(builtinFunctions.split('|'), 'function');
+ addCompletions(dataTypes.split('|'), 'type');
+ addCompletions(setStatements, 'statement');
+ addCompletions(keywords.split('|'), 'keyword');
+
+ this.completions = completions;
+};
+
+oop.inherits(SqlServerHighlightRules, TextHighlightRules);
+
+exports.SqlHighlightRules = SqlServerHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/sqlserver",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function() {};
+
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\bCASE\b|\bBEGIN\b)|^\s*(\/\*)/i;
+ this.startRegionRe = /^\s*(\/\*|--)#?region\b/;
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line)) return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+ if (match[1]) return this.getBeginEndBlock(session, row, i, match[1]);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ }
+ else if (foldStyle != "all") range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin") return;
+ return;
+ };
+ this.getBeginEndBlock = function(session, row, column, matchSequence) {
+ var start = {
+ row: row,
+ column: column + matchSequence.length
+ };
+ var maxRow = session.getLength();
+ var line;
+
+ var depth = 1;
+ var re = /(\bCASE\b|\bBEGIN\b)|(\bEND\b)/i;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth++;
+ else depth--;
+
+ if (!depth) break;
+ }
+ var endRow = row;
+ if (endRow > start.row) {
+ return new Range(start.row, start.column, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/sqlserver",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sqlserver_highlight_rules","ace/mode/folding/sqlserver"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var SqlServerHighlightRules = require("./sqlserver_highlight_rules").SqlHighlightRules;
+var SqlServerFoldMode = require("./folding/sqlserver").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = SqlServerHighlightRules;
+ this.foldingRules = new SqlServerFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "--";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.getCompletions = function(state, session, pos, prefix) {
+ return session.$mode.$highlightRules.completions;
+ };
+
+ this.$id = "ace/mode/sql";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-stylus.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-stylus.js
new file mode 100644
index 00000000..fed3f82f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-stylus.js
@@ -0,0 +1,462 @@
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/stylus_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules","ace/mode/css_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var CssHighlightRules = require("./css_highlight_rules");
+
+var StylusHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.type": CssHighlightRules.supportType,
+ "support.function": CssHighlightRules.supportFunction,
+ "support.constant": CssHighlightRules.supportConstant,
+ "support.constant.color": CssHighlightRules.supportConstantColor,
+ "support.constant.fonts": CssHighlightRules.supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ start: [
+ {
+ token : "comment",
+ regex : /\/\/.*$/
+ },
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next : "comment"
+ },
+ {
+ token: ["entity.name.function.stylus", "text"],
+ regex: "^([-a-zA-Z_][-\\w]*)?(\\()"
+ },
+ {
+ token: ["entity.other.attribute-name.class.stylus"],
+ regex: "\\.-?[_a-zA-Z]+[_a-zA-Z0-9-]*"
+ },
+ {
+ token: ["entity.language.stylus"],
+ regex: "^ *&"
+ },
+ {
+ token: ["variable.language.stylus"],
+ regex: "(arguments)"
+ },
+ {
+ token: ["keyword.stylus"],
+ regex: "@[-\\w]+"
+ },
+ {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : CssHighlightRules.pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : CssHighlightRules.pseudoClasses
+ },
+ {
+ token: ["entity.name.tag.stylus"],
+ regex: "(?:\\b)(a|abbr|acronym|address|area|article|aside|audio|b|base|big|blockquote|body|br|button|canvas|caption|cite|code|col|colgroup|datalist|dd|del|details|dfn|dialog|div|dl|dt|em|eventsource|fieldset|figure|figcaption|footer|form|frame|frameset|(?:h[1-6])|head|header|hgroup|hr|html|i|iframe|img|input|ins|kbd|label|legend|li|link|map|mark|menu|meta|meter|nav|noframes|noscript|object|ol|optgroup|option|output|p|param|pre|progress|q|samp|script|section|select|small|span|strike|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|tt|ul|var|video)(?:\\b)"
+ },
+ {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ },
+ {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ },
+ {
+ token: ["punctuation.definition.entity.stylus", "entity.other.attribute-name.id.stylus"],
+ regex: "(#)([a-zA-Z][a-zA-Z0-9_-]*)"
+ },
+ {
+ token: "meta.vendor-prefix.stylus",
+ regex: "-webkit-|-moz\\-|-ms-|-o-"
+ },
+ {
+ token: "keyword.control.stylus",
+ regex: "(?:!important|for|in|return|true|false|null|if|else|unless|return)\\b"
+ },
+ {
+ token: "keyword.operator.stylus",
+ regex: "!|~|\\+|-|(?:\\*)?\\*|\\/|%|(?:\\.)\\.\\.|<|>|(?:=|:|\\?|\\+|-|\\*|\\/|%|<|>)?=|!="
+ },
+ {
+ token: "keyword.operator.stylus",
+ regex: "(?:in|is(?:nt)?|not)\\b"
+ },
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ },
+ {
+ token : "constant.numeric",
+ regex : CssHighlightRules.numRe
+ },
+ {
+ token : "keyword",
+ regex : "(?:ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)\\b"
+ },
+ {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : "\\*\\/",
+ next : "start"
+ }, {
+ defaultToken : "comment"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : '[^"\\\\]+'
+ },
+ {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ },
+ {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "string",
+ regex : "[^'\\\\]+"
+ },
+ {
+ token : "string",
+ regex : "\\\\$",
+ next : "qstring"
+ },
+ {
+ token : "string",
+ regex : "'|$",
+ next : "start"
+ }
+ ]
+}
+
+};
+
+oop.inherits(StylusHighlightRules, TextHighlightRules);
+
+exports.StylusHighlightRules = StylusHighlightRules;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/stylus",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/stylus_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var StylusHighlightRules = require("./stylus_highlight_rules").StylusHighlightRules;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = StylusHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.$id = "ace/mode/stylus";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-svg.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-svg.js
new file mode 100644
index 00000000..25d879b3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-svg.js
@@ -0,0 +1,1568 @@
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/xml_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/xml","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var XmlFoldMode = require("./folding/xml").FoldMode;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+
+var Mode = function() {
+ this.HighlightRules = XmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.foldingRules = new XmlFoldMode();
+};
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.voidElements = lang.arrayToMap([]);
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/xml_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/xml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/svg_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var SvgHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.embedTagRules(JavaScriptHighlightRules, "js-", "script");
+
+ this.normalizeRules();
+};
+
+oop.inherits(SvgHighlightRules, XmlHighlightRules);
+
+exports.SvgHighlightRules = SvgHighlightRules;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/svg",["require","exports","module","ace/lib/oop","ace/mode/xml","ace/mode/javascript","ace/mode/svg_highlight_rules","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var XmlMode = require("./xml").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var SvgHighlightRules = require("./svg_highlight_rules").SvgHighlightRules;
+var MixedFoldMode = require("./folding/mixed").FoldMode;
+var XmlFoldMode = require("./folding/xml").FoldMode;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ XmlMode.call(this);
+
+ this.HighlightRules = SvgHighlightRules;
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode
+ });
+
+ this.foldingRules = new MixedFoldMode(new XmlFoldMode(), {
+ "js-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(Mode, XmlMode);
+
+(function() {
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+
+ this.$id = "ace/mode/svg";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-swift.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-swift.js
new file mode 100644
index 00000000..dc5a4303
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-swift.js
@@ -0,0 +1,382 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/swift_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var SwiftHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "",
+ "keyword": "__COLUMN__|__FILE__|__FUNCTION__|__LINE__"
+ + "|as|associativity|break|case|class|continue|default|deinit|didSet"
+ + "|do|dynamicType|else|enum|extension|fallthrough|for|func|get|if|import"
+ + "|in|infix|init|inout|is|left|let|let|mutating|new|none|nonmutating"
+ + "|operator|override|postfix|precedence|prefix|protocol|return|right"
+ + "|safe|Self|self|set|struct|subscript|switch|Type|typealias"
+ + "|unowned|unsafe|var|weak|where|while|willSet"
+ + "|convenience|dynamic|final|infix|lazy|mutating|nonmutating|optional|override|postfix"
+ + "|prefix|required|static|guard|defer",
+ "storage.type": "bool|double|Double"
+ + "|extension|float|Float|int|Int|private|public|string|String",
+ "constant.language":
+ "false|Infinity|NaN|nil|no|null|null|off|on|super|this|true|undefined|yes",
+ "support.function":
+ ""
+ }, "identifier");
+
+ function string(start, options) {
+ var nestable = options.nestable || options.interpolation;
+ var interpStart = options.interpolation && options.interpolation.nextState || "start";
+ var mainRule = {
+ regex: start + (options.multiline ? "" : "(?=.)"),
+ token: "string.start"
+ };
+ var nextState = [
+ options.escape && {
+ regex: options.escape,
+ token: "character.escape"
+ },
+ options.interpolation && {
+ token : "paren.quasi.start",
+ regex : lang.escapeRegExp(options.interpolation.lead + options.interpolation.open),
+ push : interpStart
+ },
+ options.error && {
+ regex: options.error,
+ token: "error.invalid"
+ },
+ {
+ regex: start + (options.multiline ? "" : "|$"),
+ token: "string.end",
+ next: nestable ? "pop" : "start"
+ }, {
+ defaultToken: "string"
+ }
+ ].filter(Boolean);
+
+ if (nestable)
+ mainRule.push = nextState;
+ else
+ mainRule.next = nextState;
+
+ if (!options.interpolation)
+ return mainRule;
+
+ var open = options.interpolation.open;
+ var close = options.interpolation.close;
+ var counter = {
+ regex: "[" + lang.escapeRegExp(open + close) + "]",
+ onMatch: function(val, state, stack) {
+ this.next = val == open ? this.nextState : "";
+ if (val == open && stack.length) {
+ stack.unshift("start", state);
+ return "paren";
+ }
+ if (val == close && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1)
+ return "paren.quasi.end";
+ }
+ return val == open ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: interpStart
+ }
+ return [counter, mainRule];
+ }
+
+ function comments() {
+ return [{
+ token : "comment",
+ regex : "\\/\\/(?=.)",
+ next : [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next: "start"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment.start",
+ regex : /\/\*/,
+ stateName: "nested_comment",
+ push : [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment.start", regex : /\/\*/, push: "nested_comment"},
+ {token : "comment.end", regex : "\\*\\/", next : "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+ }
+
+
+ this.$rules = {
+ start: [
+ string('"', {
+ escape: /\\(?:[0\\tnr"']|u{[a-fA-F1-9]{0,8}})/,
+ interpolation: {lead: "\\", open: "(", close: ")"},
+ error: /\\./,
+ multiline: false
+ }),
+ comments({type: "c", nestable: true}),
+ {
+ regex: /@[a-zA-Z_$][a-zA-Z_$\d\u0080-\ufffe]*/,
+ token: "variable.parameter"
+ },
+ {
+ regex: /[a-zA-Z_$][a-zA-Z_$\d\u0080-\ufffe]*/,
+ token: keywordMapper
+ },
+ {
+ token : "constant.numeric",
+ regex : /[+-]?(?:0(?:b[01]+|o[0-7]+|x[\da-fA-F])|\d+(?:(?:\.\d*)?(?:[PpEe][+-]?\d+)?)\b)/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }
+
+ ]
+ };
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+
+ this.normalizeRules();
+};
+
+
+oop.inherits(SwiftHighlightRules, TextHighlightRules);
+
+exports.HighlightRules = SwiftHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/swift",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/swift_highlight_rules","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var HighlightRules = require("./swift_highlight_rules").HighlightRules;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = HighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = new CstyleBehaviour();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/", nestable: true};
+
+ this.$id = "ace/mode/swift"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-tcl.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-tcl.js
new file mode 100644
index 00000000..1f878c31
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-tcl.js
@@ -0,0 +1,376 @@
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/tcl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TclHighlightRules = function() {
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*\\\\$",
+ next : "commentfollow"
+ }, {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "support.function",
+ regex : '[\\\\]$',
+ next : "splitlineStart"
+ }, {
+ token : "text",
+ regex : /\\(?:["{}\[\]$\\])/
+ }, {
+ token : "text", // last value before command
+ regex : '^|[^{][;][^}]|[/\r/]',
+ next : "commandItem"
+ }, {
+ token : "string", // single line
+ regex : '[ ]*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line """ string start
+ regex : '[ ]*["]',
+ next : "qqstring"
+ }, {
+ token : "variable.instance",
+ regex : "[$]",
+ next : "variable"
+ }, {
+ token : "support.function",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|{\\*}|;|::"
+ }, {
+ token : "identifier",
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "paren.lparen",
+ regex : "[[{]",
+ next : "commandItem"
+ }, {
+ token : "paren.lparen",
+ regex : "[(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "commandItem" : [
+ {
+ token : "comment",
+ regex : "#.*\\\\$",
+ next : "commentfollow"
+ }, {
+ token : "comment",
+ regex : "#.*$",
+ next : "start"
+ }, {
+ token : "string", // single line
+ regex : '[ ]*["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "variable.instance",
+ regex : "[$]",
+ next : "variable"
+ }, {
+ token : "support.function",
+ regex : "(?:[:][:])[a-zA-Z0-9_/]+(?:[:][:])",
+ next : "commandItem"
+ }, {
+ token : "support.function",
+ regex : "[a-zA-Z0-9_/]+(?:[:][:])",
+ next : "commandItem"
+ }, {
+ token : "support.function",
+ regex : "(?:[:][:])",
+ next : "commandItem"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "support.function",
+ regex : "!|\\$|%|&|\\*|\\-\\-|\\-|\\+\\+|\\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\\|\\||\\?\\:|\\*=|%=|\\+=|\\-=|&=|\\^=|{\\*}|;|::"
+ }, {
+ token : "keyword",
+ regex : "[a-zA-Z0-9_/]+",
+ next : "start"
+ } ],
+ "commentfollow" : [
+ {
+ token : "comment",
+ regex : ".*\\\\$",
+ next : "commentfollow"
+ }, {
+ token : "comment",
+ regex : '.+',
+ next : "start"
+ } ],
+ "splitlineStart" : [
+ {
+ token : "text",
+ regex : "^.",
+ next : "start"
+ }],
+ "variable" : [
+ {
+ token : "variable.instance", // variable tcl
+ regex : "[a-zA-Z_\\d]+(?:[(][a-zA-Z_\\d]+[)])?",
+ next : "start"
+ }, {
+ token : "variable.instance", // variable tcl with braces
+ regex : "{?[a-zA-Z_\\d]+}?",
+ next : "start"
+ }],
+ "qqstring" : [ {
+ token : "string", // multi line """ string end
+ regex : '(?:[^\\\\]|\\\\.)*?["]',
+ next : "start"
+ }, {
+ token : "string",
+ regex : '.+'
+ } ]
+ };
+};
+
+oop.inherits(TclHighlightRules, TextHighlightRules);
+
+exports.TclHighlightRules = TclHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/tcl",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/folding/cstyle","ace/mode/tcl_highlight_rules","ace/mode/matching_brace_outdent","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var TclHighlightRules = require("./tcl_highlight_rules").TclHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = TclHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new CStyleFoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/tcl";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-tex.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-tex.js
new file mode 100644
index 00000000..f4f13baa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-tex.js
@@ -0,0 +1,152 @@
+ace.define("ace/mode/tex_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TexHighlightRules = function(textClass) {
+
+ if (!textClass)
+ textClass = "text";
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "%.*$"
+ }, {
+ token : textClass, // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b",
+ next : "nospell"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])}]"
+ }, {
+ token : textClass,
+ regex : "\\s+"
+ }
+ ],
+ "nospell" : [
+ {
+ token : "comment",
+ regex : "%.*$",
+ next : "start"
+ }, {
+ token : "nospell." + textClass, // non-command
+ regex : "\\\\[$&%#\\{\\}]"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:documentclass|usepackage|newcounter|setcounter|addtocounter|value|arabic|stepcounter|newenvironment|renewenvironment|ref|vref|eqref|pageref|label|cite[a-zA-Z]*|tag|begin|end|bibitem)\\b"
+ }, {
+ token : "keyword", // command
+ regex : "\\\\(?:[a-zA-Z0-9]+|[^a-zA-Z0-9])",
+ next : "start"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[[({]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "[\\])]"
+ }, {
+ token : "paren.keyword.operator",
+ regex : "}",
+ next : "start"
+ }, {
+ token : "nospell." + textClass,
+ regex : "\\s+"
+ }, {
+ token : "nospell." + textClass,
+ regex : "\\w+"
+ }
+ ]
+ };
+};
+
+oop.inherits(TexHighlightRules, TextHighlightRules);
+
+exports.TexHighlightRules = TexHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/tex",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/tex_highlight_rules","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var TexHighlightRules = require("./tex_highlight_rules").TexHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function(suppressHighlighting) {
+ if (suppressHighlighting)
+ this.HighlightRules = TextHighlightRules;
+ else
+ this.HighlightRules = TexHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "%";
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.allowAutoInsert = function() {
+ return false;
+ };
+ this.$id = "ace/mode/tex";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-text.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-text.js
new file mode 100644
index 00000000..8b137891
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-text.js
@@ -0,0 +1 @@
+
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-textile.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-textile.js
new file mode 100644
index 00000000..94ed5c77
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-textile.js
@@ -0,0 +1,142 @@
+ace.define("ace/mode/textile_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TextileHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : function(value) {
+ if (value.charAt(0) == "h")
+ return "markup.heading." + value.charAt(1);
+ else
+ return "markup.heading";
+ },
+ regex : "h1|h2|h3|h4|h5|h6|bq|p|bc|pre",
+ next : "blocktag"
+ },
+ {
+ token : "keyword",
+ regex : "[\\*]+|[#]+"
+ },
+ {
+ token : "text",
+ regex : ".+"
+ }
+ ],
+ "blocktag" : [
+ {
+ token : "keyword",
+ regex : "\\. ",
+ next : "start"
+ },
+ {
+ token : "keyword",
+ regex : "\\(",
+ next : "blocktagproperties"
+ }
+ ],
+ "blocktagproperties" : [
+ {
+ token : "keyword",
+ regex : "\\)",
+ next : "blocktag"
+ },
+ {
+ token : "string",
+ regex : "[a-zA-Z0-9\\-_]+"
+ },
+ {
+ token : "keyword",
+ regex : "#"
+ }
+ ]
+ };
+};
+
+oop.inherits(TextileHighlightRules, TextHighlightRules);
+
+exports.TextileHighlightRules = TextileHighlightRules;
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/textile",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/textile_highlight_rules","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TextileHighlightRules = require("./textile_highlight_rules").TextileHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ this.HighlightRules = TextileHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.type = "text";
+ this.getNextLineIndent = function(state, line, tab) {
+ if (state == "intag")
+ return tab;
+
+ return "";
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.$id = "ace/mode/textile";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-toml.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-toml.js
new file mode 100644
index 00000000..2f348937
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-toml.js
@@ -0,0 +1,146 @@
+ace.define("ace/mode/toml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TomlHighlightRules = function() {
+ var keywordMapper = this.createKeywordMapper({
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+
+ var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*\\b";
+
+ this.$rules = {
+ "start": [
+ {
+ token: "comment.toml",
+ regex: /#.*$/
+ },
+ {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ },
+ {
+ token: ["variable.keygroup.toml"],
+ regex: "(?:^\\s*)(\\[\\[([^\\]]+)\\]\\])"
+ },
+ {
+ token: ["variable.keygroup.toml"],
+ regex: "(?:^\\s*)(\\[([^\\]]+)\\])"
+ },
+ {
+ token : keywordMapper,
+ regex : identifierRe
+ },
+ {
+ token : "support.date.toml",
+ regex: "\\d{4}-\\d{2}-\\d{2}(T)\\d{2}:\\d{2}:\\d{2}(Z)"
+ },
+ {
+ token: "constant.numeric.toml",
+ regex: "-?\\d+(\\.?\\d+)?"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "string",
+ regex : "\\\\$",
+ next : "qqstring"
+ },
+ {
+ token : "constant.language.escape",
+ regex : '\\\\[0tnr"\\\\]'
+ },
+ {
+ token : "string",
+ regex : '"|$',
+ next : "start"
+ },
+ {
+ defaultToken: "string"
+ }
+ ]
+ }
+
+};
+
+oop.inherits(TomlHighlightRules, TextHighlightRules);
+
+exports.TomlHighlightRules = TomlHighlightRules;
+});
+
+ace.define("ace/mode/folding/ini",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function() {
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /^\s*\[([^\])]*)]\s*(?:$|[;#])/;
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var re = this.foldingStartMarker;
+ var line = session.getLine(row);
+
+ var m = line.match(re);
+
+ if (!m) return;
+
+ var startName = m[1] + ".";
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ if (/^\s*$/.test(line))
+ continue;
+ m = line.match(re);
+ if (m && m[1].lastIndexOf(startName, 0) !== 0)
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/toml",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/toml_highlight_rules","ace/mode/folding/ini"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TomlHighlightRules = require("./toml_highlight_rules").TomlHighlightRules;
+var FoldMode = require("./folding/ini").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = TomlHighlightRules;
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "#";
+ this.$id = "ace/mode/toml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-tsx.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-tsx.js
new file mode 100644
index 00000000..9db47ac0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-tsx.js
@@ -0,0 +1,891 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/typescript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/javascript_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+
+var TypeScriptHighlightRules = function(options) {
+
+ var tsRules = [
+ {
+ token: ["keyword.operator.ts", "text", "variable.parameter.function.ts", "text"],
+ regex: "\\b(module)(\\s*)([a-zA-Z0-9_?.$][\\w?.$]*)(\\s*\\{)"
+ },
+ {
+ token: ["storage.type.variable.ts", "text", "keyword.other.ts", "text"],
+ regex: "(super)(\\s*\\()([a-zA-Z0-9,_?.$\\s]+\\s*)(\\))"
+ },
+ {
+ token: ["entity.name.function.ts","paren.lparen", "paren.rparen"],
+ regex: "([a-zA-Z_?.$][\\w?.$]*)(\\()(\\))"
+ },
+ {
+ token: ["variable.parameter.function.ts", "text", "variable.parameter.function.ts"],
+ regex: "([a-zA-Z0-9_?.$][\\w?.$]*)(\\s*:\\s*)([a-zA-Z0-9_?.$][\\w?.$]*)"
+ },
+ {
+ token: ["keyword.operator.ts"],
+ regex: "(?:\\b(constructor|declare|interface|as|AS|public|private|class|extends|export|super)\\b)"
+ },
+ {
+ token: ["storage.type.variable.ts"],
+ regex: "(?:\\b(this\\.|string\\b|bool\\b|number)\\b)"
+ },
+ {
+ token: ["keyword.operator.ts", "storage.type.variable.ts", "keyword.operator.ts", "storage.type.variable.ts"],
+ regex: "(class)(\\s+[a-zA-Z0-9_?.$][\\w?.$]*\\s+)(extends)(\\s+[a-zA-Z0-9_?.$][\\w?.$]*\\s+)?"
+ },
+ {
+ token: "keyword",
+ regex: "(?:super|export|class|extends|import)\\b"
+ }
+ ];
+
+ var JSRules = new JavaScriptHighlightRules({jsx: (options && options.jsx) == true}).getRules();
+
+ JSRules.start = tsRules.concat(JSRules.start);
+ this.$rules = JSRules;
+};
+
+oop.inherits(TypeScriptHighlightRules, JavaScriptHighlightRules);
+
+exports.TypeScriptHighlightRules = TypeScriptHighlightRules;
+});
+
+ace.define("ace/mode/typescript",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/typescript_highlight_rules","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var jsMode = require("./javascript").Mode;
+var TypeScriptHighlightRules = require("./typescript_highlight_rules").TypeScriptHighlightRules;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ this.HighlightRules = TypeScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, jsMode);
+
+(function() {
+ this.createWorker = function(session) {
+ return null;
+ };
+ this.$id = "ace/mode/typescript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/tsx",["require","exports","module","ace/lib/oop","ace/mode/typescript"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var tsMode = require("./typescript").Mode;
+
+var Mode = function() {
+ tsMode.call(this);
+ this.$highlightRuleConfig = {jsx: true};
+};
+oop.inherits(Mode, tsMode);
+
+(function() {
+ this.$id = "ace/mode/tsx";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-turtle.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-turtle.js
new file mode 100644
index 00000000..4eef543d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-turtle.js
@@ -0,0 +1,289 @@
+ace.define("ace/mode/turtle_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TurtleHighlightRules = function() {
+
+ this.$rules = {
+ start: [{
+ include: "#comments"
+ }, {
+ include: "#strings"
+ }, {
+ include: "#base-prefix-declarations"
+ }, {
+ include: "#string-language-suffixes"
+ }, {
+ include: "#string-datatype-suffixes"
+ }, {
+ include: "#relative-urls"
+ }, {
+ include: "#xml-schema-types"
+ }, {
+ include: "#rdf-schema-types"
+ }, {
+ include: "#owl-types"
+ }, {
+ include: "#qnames"
+ }, {
+ include: "#punctuation-operators"
+ }],
+ "#base-prefix-declarations": [{
+ token: "keyword.other.prefix.turtle",
+ regex: /@(?:base|prefix)/
+ }],
+ "#comments": [{
+ token: [
+ "punctuation.definition.comment.turtle",
+ "comment.line.hash.turtle"
+ ],
+ regex: /(#)(.*$)/
+ }],
+ "#owl-types": [{
+ token: "support.type.datatype.owl.turtle",
+ regex: /owl:[a-zA-Z]+/
+ }],
+ "#punctuation-operators": [{
+ token: "keyword.operator.punctuation.turtle",
+ regex: /;|,|\.|\(|\)|\[|\]/
+ }],
+ "#qnames": [{
+ token: "entity.name.other.qname.turtle",
+ regex: /(?:[a-zA-Z][-_a-zA-Z0-9]*)?:(?:[_a-zA-Z][-_a-zA-Z0-9]*)?/
+ }],
+ "#rdf-schema-types": [{
+ token: "support.type.datatype.rdf.schema.turtle",
+ regex: /rdfs?:[a-zA-Z]+|(?:^|\s)a(?:\s|$)/
+ }],
+ "#relative-urls": [{
+ token: "string.quoted.other.relative.url.turtle",
+ regex: /</,
+ push: [{
+ token: "string.quoted.other.relative.url.turtle",
+ regex: />/,
+ next: "pop"
+ }, {
+ defaultToken: "string.quoted.other.relative.url.turtle"
+ }]
+ }],
+ "#string-datatype-suffixes": [{
+ token: "keyword.operator.datatype.suffix.turtle",
+ regex: /\^\^/
+ }],
+ "#string-language-suffixes": [{
+ token: [
+ "keyword.operator.language.suffix.turtle",
+ "constant.language.suffix.turtle"
+ ],
+ regex: /(?!")(@)([a-z]+(?:\-[a-z0-9]+)*)/
+ }],
+ "#strings": [{
+ token: "string.quoted.triple.turtle",
+ regex: /"""/,
+ push: [{
+ token: "string.quoted.triple.turtle",
+ regex: /"""/,
+ next: "pop"
+ }, {
+ defaultToken: "string.quoted.triple.turtle"
+ }]
+ }, {
+ token: "string.quoted.double.turtle",
+ regex: /"/,
+ push: [{
+ token: "string.quoted.double.turtle",
+ regex: /"/,
+ next: "pop"
+ }, {
+ token: "invalid.string.newline",
+ regex: /$/
+ }, {
+ token: "constant.character.escape.turtle",
+ regex: /\\./
+ }, {
+ defaultToken: "string.quoted.double.turtle"
+ }]
+ }],
+ "#xml-schema-types": [{
+ token: "support.type.datatype.xml.schema.turtle",
+ regex: /xsd?:[a-z][a-zA-Z]+/
+ }]
+ }
+
+ this.normalizeRules();
+};
+
+TurtleHighlightRules.metaData = {
+ fileTypes: ["ttl", "nt"],
+ name: "Turtle",
+ scopeName: "source.turtle"
+}
+
+
+oop.inherits(TurtleHighlightRules, TextHighlightRules);
+
+exports.TurtleHighlightRules = TurtleHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/turtle",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/turtle_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TurtleHighlightRules = require("./turtle_highlight_rules").TurtleHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = TurtleHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.$id = "ace/mode/turtle"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-twig.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-twig.js
new file mode 100644
index 00000000..557c124b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-twig.js
@@ -0,0 +1,2664 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/twig_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/html_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var TwigHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var tags = "autoescape|block|do|embed|extends|filter|flush|for|from|if|import|include|macro|sandbox|set|spaceless|use|verbatim";
+ tags = tags + "|end" + tags.replace(/\|/g, "|end");
+ var filters = "abs|batch|capitalize|convert_encoding|date|date_modify|default|e|escape|first|format|join|json_encode|keys|last|length|lower|merge|nl2br|number_format|raw|replace|reverse|slice|sort|split|striptags|title|trim|upper|url_encode";
+ var functions = "attribute|constant|cycle|date|dump|parent|random|range|template_from_string";
+ var tests = "constant|divisibleby|sameas|defined|empty|even|iterable|odd";
+ var constants = "null|none|true|false";
+ var operators = "b-and|b-xor|b-or|in|is|and|or|not"
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword.control.twig": tags,
+ "support.function.twig": [filters, functions, tests].join("|"),
+ "keyword.operator.twig": operators,
+ "constant.language.twig": constants
+ }, "identifier");
+ for (var rule in this.$rules) {
+ this.$rules[rule].unshift({
+ token : "variable.other.readwrite.local.twig",
+ regex : "\\{\\{-?",
+ push : "twig-start"
+ }, {
+ token : "meta.tag.twig",
+ regex : "\\{%-?",
+ push : "twig-start"
+ }, {
+ token : "comment.block.twig",
+ regex : "\\{#-?",
+ push : "twig-comment"
+ });
+ }
+ this.$rules["twig-comment"] = [{
+ token : "comment.block.twig",
+ regex : ".*-?#\\}",
+ next : "pop"
+ }];
+
+ this.$rules["twig-start"] = [{
+ token : "variable.other.readwrite.local.twig",
+ regex : "-?\\}\\}",
+ next : "pop"
+ }, {
+ token : "meta.tag.twig",
+ regex : "-?%\\}",
+ next : "pop"
+ }, {
+ token : "string",
+ regex : "'",
+ next : "twig-qstring"
+ }, {
+ token : "string",
+ regex : '"',
+ next : "twig-qqstring"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator.assignment",
+ regex : "=|~"
+ }, {
+ token : "keyword.operator.comparison",
+ regex : "==|!=|<|>|>=|<=|==="
+ }, {
+ token : "keyword.operator.arithmetic",
+ regex : "\\+|-|/|%|//|\\*|\\*\\*"
+ }, {
+ token : "keyword.operator.other",
+ regex : "\\.\\.|\\|"
+ }, {
+ token : "punctuation.operator",
+ regex : /\?|:|,|;|\./
+ }, {
+ token : "paren.lparen",
+ regex : /[\[\({]/
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ];
+
+ this.$rules["twig-qqstring"] = [{
+ token : "constant.language.escape",
+ regex : /\\[\\"$#ntr]|#{[^"}]*}/
+ }, {
+ token : "string",
+ regex : '"',
+ next : "twig-start"
+ }, {
+ defaultToken : "string"
+ }
+ ];
+
+ this.$rules["twig-qstring"] = [{
+ token : "constant.language.escape",
+ regex : /\\[\\'ntr]}/
+ }, {
+ token : "string",
+ regex : "'",
+ next : "twig-start"
+ }, {
+ defaultToken : "string"
+ }
+ ];
+
+ this.normalizeRules();
+};
+
+oop.inherits(TwigHighlightRules, TextHighlightRules);
+
+exports.TwigHighlightRules = TwigHighlightRules;
+});
+
+ace.define("ace/mode/twig",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/twig_highlight_rules","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var TwigHighlightRules = require("./twig_highlight_rules").TwigHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = TwigHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.blockComment = {start: "{#", end: "#}"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+ this.$id = "ace/mode/twig";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-typescript.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-typescript.js
new file mode 100644
index 00000000..1c1b697d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-typescript.js
@@ -0,0 +1,872 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/typescript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/javascript_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+
+var TypeScriptHighlightRules = function(options) {
+
+ var tsRules = [
+ {
+ token: ["keyword.operator.ts", "text", "variable.parameter.function.ts", "text"],
+ regex: "\\b(module)(\\s*)([a-zA-Z0-9_?.$][\\w?.$]*)(\\s*\\{)"
+ },
+ {
+ token: ["storage.type.variable.ts", "text", "keyword.other.ts", "text"],
+ regex: "(super)(\\s*\\()([a-zA-Z0-9,_?.$\\s]+\\s*)(\\))"
+ },
+ {
+ token: ["entity.name.function.ts","paren.lparen", "paren.rparen"],
+ regex: "([a-zA-Z_?.$][\\w?.$]*)(\\()(\\))"
+ },
+ {
+ token: ["variable.parameter.function.ts", "text", "variable.parameter.function.ts"],
+ regex: "([a-zA-Z0-9_?.$][\\w?.$]*)(\\s*:\\s*)([a-zA-Z0-9_?.$][\\w?.$]*)"
+ },
+ {
+ token: ["keyword.operator.ts"],
+ regex: "(?:\\b(constructor|declare|interface|as|AS|public|private|class|extends|export|super)\\b)"
+ },
+ {
+ token: ["storage.type.variable.ts"],
+ regex: "(?:\\b(this\\.|string\\b|bool\\b|number)\\b)"
+ },
+ {
+ token: ["keyword.operator.ts", "storage.type.variable.ts", "keyword.operator.ts", "storage.type.variable.ts"],
+ regex: "(class)(\\s+[a-zA-Z0-9_?.$][\\w?.$]*\\s+)(extends)(\\s+[a-zA-Z0-9_?.$][\\w?.$]*\\s+)?"
+ },
+ {
+ token: "keyword",
+ regex: "(?:super|export|class|extends|import)\\b"
+ }
+ ];
+
+ var JSRules = new JavaScriptHighlightRules({jsx: (options && options.jsx) == true}).getRules();
+
+ JSRules.start = tsRules.concat(JSRules.start);
+ this.$rules = JSRules;
+};
+
+oop.inherits(TypeScriptHighlightRules, JavaScriptHighlightRules);
+
+exports.TypeScriptHighlightRules = TypeScriptHighlightRules;
+});
+
+ace.define("ace/mode/typescript",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/typescript_highlight_rules","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var jsMode = require("./javascript").Mode;
+var TypeScriptHighlightRules = require("./typescript_highlight_rules").TypeScriptHighlightRules;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ this.HighlightRules = TypeScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, jsMode);
+
+(function() {
+ this.createWorker = function(session) {
+ return null;
+ };
+ this.$id = "ace/mode/typescript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-vala.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-vala.js
new file mode 100644
index 00000000..75340fb4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-vala.js
@@ -0,0 +1,669 @@
+ace.define("ace/mode/vala_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var ValaHighlightRules = function() {
+
+ this.$rules = { start:
+ [ { token:
+ [ 'meta.using.vala',
+ 'keyword.other.using.vala',
+ 'meta.using.vala',
+ 'storage.modifier.using.vala',
+ 'meta.using.vala',
+ 'punctuation.terminator.vala' ],
+ regex: '^(\\s*)(using)\\b(?:(\\s*)([^ ;$]+)(\\s*)((?:;)?))?' },
+ { include: '#code' } ],
+ '#all-types':
+ [ { include: '#primitive-arrays' },
+ { include: '#primitive-types' },
+ { include: '#object-types' } ],
+ '#annotations':
+ [ { token:
+ [ 'storage.type.annotation.vala',
+ 'punctuation.definition.annotation-arguments.begin.vala' ],
+ regex: '(@[^ (]+)(\\()',
+ push:
+ [ { token: 'punctuation.definition.annotation-arguments.end.vala',
+ regex: '\\)',
+ next: 'pop' },
+ { token:
+ [ 'constant.other.key.vala',
+ 'text',
+ 'keyword.operator.assignment.vala' ],
+ regex: '(\\w*)(\\s*)(=)' },
+ { include: '#code' },
+ { token: 'punctuation.seperator.property.vala', regex: ',' },
+ { defaultToken: 'meta.declaration.annotation.vala' } ] },
+ { token: 'storage.type.annotation.vala', regex: '@\\w*' } ],
+ '#anonymous-classes-and-new':
+ [ { token: 'keyword.control.new.vala',
+ regex: '\\bnew\\b',
+ push_disabled:
+ [ { token: 'text',
+ regex: '(?<=\\)|\\])(?!\\s*{)|(?<=})|(?=;)',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<=\\)|\\])(?!\\s*{)|(?<=})|(?=;)',
+ next: 'pop' },
+ { token: [ 'storage.type.vala', 'text' ],
+ regex: '(\\w+)(\\s*)(?=\\[)',
+ push:
+ [ { token: 'text', regex: '}|(?=;|\\))', next: 'pop' },
+ { token: 'text',
+ regex: '\\[',
+ push:
+ [ { token: 'text', regex: '\\]', next: 'pop' },
+ { include: '#code' } ] },
+ { token: 'text',
+ regex: '{',
+ push:
+ [ { token: 'text', regex: '(?=})', next: 'pop' },
+ { include: '#code' } ] } ] },
+ { token: 'text',
+ regex: '(?=\\w.*\\()',
+ push:
+ [ { token: 'text',
+ regex: '(?<=\\))',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '(?<=\\))',
+ next: 'pop' },
+ { include: '#object-types' },
+ { token: 'text',
+ regex: '\\(',
+ push:
+ [ { token: 'text', regex: '\\)', next: 'pop' },
+ { include: '#code' } ] } ] },
+ { token: 'meta.inner-class.vala',
+ regex: '{',
+ push:
+ [ { token: 'meta.inner-class.vala', regex: '}', next: 'pop' },
+ { include: '#class-body' },
+ { defaultToken: 'meta.inner-class.vala' } ] } ] } ],
+ '#assertions':
+ [ { token:
+ [ 'keyword.control.assert.vala',
+ 'meta.declaration.assertion.vala' ],
+ regex: '\\b(assert|requires|ensures)(\\s)',
+ push:
+ [ { token: 'meta.declaration.assertion.vala',
+ regex: '$',
+ next: 'pop' },
+ { token: 'keyword.operator.assert.expression-seperator.vala',
+ regex: ':' },
+ { include: '#code' },
+ { defaultToken: 'meta.declaration.assertion.vala' } ] } ],
+ '#class':
+ [ { token: 'meta.class.vala',
+ regex: '(?=\\w?[\\w\\s]*(?:class|(?:@)?interface|enum|struct|namespace)\\s+\\w+)',
+ push:
+ [ { token: 'paren.vala',
+ regex: '}',
+ next: 'pop' },
+ { include: '#storage-modifiers' },
+ { include: '#comments' },
+ { token:
+ [ 'storage.modifier.vala',
+ 'meta.class.identifier.vala',
+ 'entity.name.type.class.vala' ],
+ regex: '(class|(?:@)?interface|enum|struct|namespace)(\\s+)([\\w\\.]+)' },
+ { token: 'storage.modifier.extends.vala',
+ regex: ':',
+ push:
+ [ { token: 'meta.definition.class.inherited.classes.vala',
+ regex: '(?={|,)',
+ next: 'pop' },
+ { include: '#object-types-inherited' },
+ { include: '#comments' },
+ { defaultToken: 'meta.definition.class.inherited.classes.vala' } ] },
+ { token:
+ [ 'storage.modifier.implements.vala',
+ 'meta.definition.class.implemented.interfaces.vala' ],
+ regex: '(,)(\\s)',
+ push:
+ [ { token: 'meta.definition.class.implemented.interfaces.vala',
+ regex: '(?=\\{)',
+ next: 'pop' },
+ { include: '#object-types-inherited' },
+ { include: '#comments' },
+ { defaultToken: 'meta.definition.class.implemented.interfaces.vala' } ] },
+ { token: 'paren.vala',
+ regex: '{',
+ push:
+ [ { token: 'paren.vala', regex: '(?=})', next: 'pop' },
+ { include: '#class-body' },
+ { defaultToken: 'meta.class.body.vala' } ] },
+ { defaultToken: 'meta.class.vala' } ],
+ comment: 'attempting to put namespace in here.' } ],
+ '#class-body':
+ [ { include: '#comments' },
+ { include: '#class' },
+ { include: '#enums' },
+ { include: '#methods' },
+ { include: '#annotations' },
+ { include: '#storage-modifiers' },
+ { include: '#code' } ],
+ '#code':
+ [ { include: '#comments' },
+ { include: '#class' },
+ { token: 'text',
+ regex: '{',
+ push:
+ [ { token: 'text', regex: '}', next: 'pop' },
+ { include: '#code' } ] },
+ { include: '#assertions' },
+ { include: '#parens' },
+ { include: '#constants-and-special-vars' },
+ { include: '#anonymous-classes-and-new' },
+ { include: '#keywords' },
+ { include: '#storage-modifiers' },
+ { include: '#strings' },
+ { include: '#all-types' } ],
+ '#comments':
+ [ { token: 'punctuation.definition.comment.vala',
+ regex: '/\\*\\*/' },
+ { include: 'text.html.javadoc' },
+ { include: '#comments-inline' } ],
+ '#comments-inline':
+ [ { token: 'punctuation.definition.comment.vala',
+ regex: '/\\*',
+ push:
+ [ { token: 'punctuation.definition.comment.vala',
+ regex: '\\*/',
+ next: 'pop' },
+ { defaultToken: 'comment.block.vala' } ] },
+ { token:
+ [ 'text',
+ 'punctuation.definition.comment.vala',
+ 'comment.line.double-slash.vala' ],
+ regex: '(\\s*)(//)(.*$)' } ],
+ '#constants-and-special-vars':
+ [ { token: 'constant.language.vala',
+ regex: '\\b(?:true|false|null)\\b' },
+ { token: 'variable.language.vala',
+ regex: '\\b(?:this|base)\\b' },
+ { token: 'constant.numeric.vala',
+ regex: '\\b(?:0(?:x|X)[0-9a-fA-F]*|(?:[0-9]+\\.?[0-9]*|\\.[0-9]+)(?:(?:e|E)(?:\\+|-)?[0-9]+)?)(?:[LlFfUuDd]|UL|ul)?\\b' },
+ { token: [ 'keyword.operator.dereference.vala', 'constant.other.vala' ],
+ regex: '((?:\\.)?)\\b([A-Z][A-Z0-9_]+)(?!<|\\.class|\\s*\\w+\\s*=)\\b' } ],
+ '#enums':
+ [ { token: 'text',
+ regex: '^(?=\\s*[A-Z0-9_]+\\s*(?:{|\\(|,))',
+ push:
+ [ { token: 'text', regex: '(?=;|})', next: 'pop' },
+ { token: 'constant.other.enum.vala',
+ regex: '\\w+',
+ push:
+ [ { token: 'meta.enum.vala', regex: '(?=,|;|})', next: 'pop' },
+ { include: '#parens' },
+ { token: 'text',
+ regex: '{',
+ push:
+ [ { token: 'text', regex: '}', next: 'pop' },
+ { include: '#class-body' } ] },
+ { defaultToken: 'meta.enum.vala' } ] } ] } ],
+ '#keywords':
+ [ { token: 'keyword.control.catch-exception.vala',
+ regex: '\\b(?:try|catch|finally|throw)\\b' },
+ { token: 'keyword.control.vala', regex: '\\?|:|\\?\\?' },
+ { token: 'keyword.control.vala',
+ regex: '\\b(?:return|break|case|continue|default|do|while|for|foreach|switch|if|else|in|yield|get|set|value)\\b' },
+ { token: 'keyword.operator.vala',
+ regex: '\\b(?:typeof|is|as)\\b' },
+ { token: 'keyword.operator.comparison.vala',
+ regex: '==|!=|<=|>=|<>|<|>' },
+ { token: 'keyword.operator.assignment.vala', regex: '=' },
+ { token: 'keyword.operator.increment-decrement.vala',
+ regex: '\\-\\-|\\+\\+' },
+ { token: 'keyword.operator.arithmetic.vala',
+ regex: '\\-|\\+|\\*|\\/|%' },
+ { token: 'keyword.operator.logical.vala', regex: '!|&&|\\|\\|' },
+ { token: 'keyword.operator.dereference.vala',
+ regex: '\\.(?=\\S)',
+ originalRegex: '(?<=\\S)\\.(?=\\S)' },
+ { token: 'punctuation.terminator.vala', regex: ';' },
+ { token: 'keyword.operator.ownership', regex: 'owned|unowned' } ],
+ '#methods':
+ [ { token: 'meta.method.vala',
+ regex: '(?!new)(?=\\w.*\\s+)(?=[^=]+\\()',
+ push:
+ [ { token: 'paren.vala', regex: '}|(?=;)', next: 'pop' },
+ { include: '#storage-modifiers' },
+ { token: [ 'entity.name.function.vala', 'meta.method.identifier.vala' ],
+ regex: '([\\~\\w\\.]+)(\\s*\\()',
+ push:
+ [ { token: 'meta.method.identifier.vala',
+ regex: '\\)',
+ next: 'pop' },
+ { include: '#parameters' },
+ { defaultToken: 'meta.method.identifier.vala' } ] },
+ { token: 'meta.method.return-type.vala',
+ regex: '(?=\\w.*\\s+\\w+\\s*\\()',
+ push:
+ [ { token: 'meta.method.return-type.vala',
+ regex: '(?=\\w+\\s*\\()',
+ next: 'pop' },
+ { include: '#all-types' },
+ { defaultToken: 'meta.method.return-type.vala' } ] },
+ { include: '#throws' },
+ { token: 'paren.vala',
+ regex: '{',
+ push:
+ [ { token: 'paren.vala', regex: '(?=})', next: 'pop' },
+ { include: '#code' },
+ { defaultToken: 'meta.method.body.vala' } ] },
+ { defaultToken: 'meta.method.vala' } ] } ],
+ '#namespace':
+ [ { token: 'text',
+ regex: '^(?=\\s*[A-Z0-9_]+\\s*(?:{|\\(|,))',
+ push:
+ [ { token: 'text', regex: '(?=;|})', next: 'pop' },
+ { token: 'constant.other.namespace.vala',
+ regex: '\\w+',
+ push:
+ [ { token: 'meta.namespace.vala', regex: '(?=,|;|})', next: 'pop' },
+ { include: '#parens' },
+ { token: 'text',
+ regex: '{',
+ push:
+ [ { token: 'text', regex: '}', next: 'pop' },
+ { include: '#code' } ] },
+ { defaultToken: 'meta.namespace.vala' } ] } ],
+ comment: 'This is not quite right. See the class grammar right now' } ],
+ '#object-types':
+ [ { token: 'storage.type.generic.vala',
+ regex: '\\b(?:[a-z]\\w*\\.)*[A-Z]+\\w*<',
+ push:
+ [ { token: 'storage.type.generic.vala',
+ regex: '>|[^\\w\\s,\\?<\\[()\\]]',
+ TODO: 'FIXME: regexp doesn\'t have js equivalent',
+ originalRegex: '>|[^\\w\\s,\\?<\\[(?:[,]+)\\]]',
+ next: 'pop' },
+ { include: '#object-types' },
+ { token: 'storage.type.generic.vala',
+ regex: '<',
+ push:
+ [ { token: 'storage.type.generic.vala',
+ regex: '>|[^\\w\\s,\\[\\]<]',
+ next: 'pop' },
+ { defaultToken: 'storage.type.generic.vala' } ],
+ comment: 'This is just to support <>\'s with no actual type prefix' },
+ { defaultToken: 'storage.type.generic.vala' } ] },
+ { token: 'storage.type.object.array.vala',
+ regex: '\\b(?:[a-z]\\w*\\.)*[A-Z]+\\w*(?=\\[)',
+ push:
+ [ { token: 'storage.type.object.array.vala',
+ regex: '(?=[^\\]\\s])',
+ next: 'pop' },
+ { token: 'text',
+ regex: '\\[',
+ push:
+ [ { token: 'text', regex: '\\]', next: 'pop' },
+ { include: '#code' } ] },
+ { defaultToken: 'storage.type.object.array.vala' } ] },
+ { token:
+ [ 'storage.type.vala',
+ 'keyword.operator.dereference.vala',
+ 'storage.type.vala' ],
+ regex: '\\b(?:([a-z]\\w*)(\\.))*([A-Z]+\\w*\\b)' } ],
+ '#object-types-inherited':
+ [ { token: 'entity.other.inherited-class.vala',
+ regex: '\\b(?:[a-z]\\w*\\.)*[A-Z]+\\w*<',
+ push:
+ [ { token: 'entity.other.inherited-class.vala',
+ regex: '>|[^\\w\\s,<]',
+ next: 'pop' },
+ { include: '#object-types' },
+ { token: 'storage.type.generic.vala',
+ regex: '<',
+ push:
+ [ { token: 'storage.type.generic.vala',
+ regex: '>|[^\\w\\s,<]',
+ next: 'pop' },
+ { defaultToken: 'storage.type.generic.vala' } ],
+ comment: 'This is just to support <>\'s with no actual type prefix' },
+ { defaultToken: 'entity.other.inherited-class.vala' } ] },
+ { token:
+ [ 'entity.other.inherited-class.vala',
+ 'keyword.operator.dereference.vala',
+ 'entity.other.inherited-class.vala' ],
+ regex: '\\b(?:([a-z]\\w*)(\\.))*([A-Z]+\\w*)' } ],
+ '#parameters':
+ [ { token: 'storage.modifier.vala', regex: 'final' },
+ { include: '#primitive-arrays' },
+ { include: '#primitive-types' },
+ { include: '#object-types' },
+ { token: 'variable.parameter.vala', regex: '\\w+' } ],
+ '#parens':
+ [ { token: 'text',
+ regex: '\\(',
+ push:
+ [ { token: 'text', regex: '\\)', next: 'pop' },
+ { include: '#code' } ] } ],
+ '#primitive-arrays':
+ [ { token: 'storage.type.primitive.array.vala',
+ regex: '\\b(?:bool|byte|sbyte|char|decimal|double|float|int|uint|long|ulong|object|short|ushort|string|void|int8|int16|int32|int64|uint8|uint16|uint32|uint64)(?:\\[\\])*\\b' } ],
+ '#primitive-types':
+ [ { token: 'storage.type.primitive.vala',
+ regex: '\\b(?:var|bool|byte|sbyte|char|decimal|double|float|int|uint|long|ulong|object|short|ushort|string|void|signal|int8|int16|int32|int64|uint8|uint16|uint32|uint64)\\b',
+ comment: 'var is not really a primitive, but acts like one in most cases' } ],
+ '#storage-modifiers':
+ [ { token: 'storage.modifier.vala',
+ regex: '\\b(?:public|private|protected|internal|static|final|sealed|virtual|override|abstract|readonly|volatile|dynamic|async|unsafe|out|ref|weak|owned|unowned|const)\\b',
+ comment: 'Not sure about unsafe and readonly' } ],
+ '#strings':
+ [ { token: 'punctuation.definition.string.begin.vala',
+ regex: '@"',
+ push:
+ [ { token: 'punctuation.definition.string.end.vala',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.vala',
+ regex: '\\\\.|%[\\w\\.\\-]+|\\$(?:\\w+|\\([\\w\\s\\+\\-\\*\\/]+\\))' },
+ { defaultToken: 'string.quoted.interpolated.vala' } ] },
+ { token: 'punctuation.definition.string.begin.vala',
+ regex: '"',
+ push:
+ [ { token: 'punctuation.definition.string.end.vala',
+ regex: '"',
+ next: 'pop' },
+ { token: 'constant.character.escape.vala', regex: '\\\\.' },
+ { token: 'constant.character.escape.vala',
+ regex: '%[\\w\\.\\-]+' },
+ { defaultToken: 'string.quoted.double.vala' } ] },
+ { token: 'punctuation.definition.string.begin.vala',
+ regex: '\'',
+ push:
+ [ { token: 'punctuation.definition.string.end.vala',
+ regex: '\'',
+ next: 'pop' },
+ { token: 'constant.character.escape.vala', regex: '\\\\.' },
+ { defaultToken: 'string.quoted.single.vala' } ] },
+ { token: 'punctuation.definition.string.begin.vala',
+ regex: '"""',
+ push:
+ [ { token: 'punctuation.definition.string.end.vala',
+ regex: '"""',
+ next: 'pop' },
+ { token: 'constant.character.escape.vala',
+ regex: '%[\\w\\.\\-]+' },
+ { defaultToken: 'string.quoted.triple.vala' } ] } ],
+ '#throws':
+ [ { token: 'storage.modifier.vala',
+ regex: 'throws',
+ push:
+ [ { token: 'meta.throwables.vala', regex: '(?={|;)', next: 'pop' },
+ { include: '#object-types' },
+ { defaultToken: 'meta.throwables.vala' } ] } ],
+ '#values':
+ [ { include: '#strings' },
+ { include: '#object-types' },
+ { include: '#constants-and-special-vars' } ] }
+
+ this.normalizeRules();
+};
+
+ValaHighlightRules.metaData = {
+ comment: 'Based heavily on the Java bundle\'s language syntax. TODO:\n* Closures\n* Delegates\n* Properties: Better support for properties.\n* Annotations\n* Error domains\n* Named arguments\n* Array slicing, negative indexes, multidimensional\n* construct blocks\n* lock blocks?\n* regex literals\n* DocBlock syntax highlighting. (Currently importing javadoc)\n* Folding rule for comments.\n',
+ fileTypes: [ 'vala' ],
+ foldingStartMarker: '(\\{\\s*(//.*)?$|^\\s*// \\{\\{\\{)',
+ foldingStopMarker: '^\\s*(\\}|// \\}\\}\\}$)',
+ name: 'Vala',
+ scopeName: 'source.vala' }
+
+
+oop.inherits(ValaHighlightRules, TextHighlightRules);
+
+exports.ValaHighlightRules = ValaHighlightRules;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/vala",["require","exports","module","ace/lib/oop","ace/mode/text","ace/tokenizer","ace/mode/vala_highlight_rules","ace/mode/folding/cstyle","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle","ace/mode/matching_brace_outdent"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var Tokenizer = require("../tokenizer").Tokenizer;
+var ValaHighlightRules = require("./vala_highlight_rules").ValaHighlightRules;
+var FoldMode = require("./folding/cstyle").FoldMode;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+
+var Mode = function() {
+ this.HighlightRules = ValaHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+ this.$id = "ace/mode/vala"
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-vbscript.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-vbscript.js
new file mode 100644
index 00000000..010be5be
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-vbscript.js
@@ -0,0 +1,199 @@
+ace.define("ace/mode/vbscript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var VBScriptHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword.control.asp": "If|Then|Else|ElseIf|End|While|Wend|For|To|Each|Case|Select|Return"
+ + "|Continue|Do|Until|Loop|Next|With|Exit|Function|Property|Type|Enum|Sub|IIf",
+ "storage.type.asp": "Dim|Call|Class|Const|Dim|Redim|Set|Let|Get|New|Randomize|Option|Explicit",
+ "storage.modifier.asp": "Private|Public|Default",
+ "keyword.operator.asp": "Mod|And|Not|Or|Xor|as",
+ "constant.language.asp": "Empty|False|Nothing|Null|True",
+ "support.class.asp": "Application|ObjectContext|Request|Response|Server|Session",
+ "support.class.collection.asp": "Contents|StaticObjects|ClientCertificate|Cookies|Form|QueryString|ServerVariables",
+ "support.constant.asp": "TotalBytes|Buffer|CacheControl|Charset|ContentType|Expires|ExpiresAbsolute"
+ + "|IsClientConnected|PICS|Status|ScriptTimeout|CodePage|LCID|SessionID|Timeout",
+ "support.function.asp": "Lock|Unlock|SetAbort|SetComplete|BinaryRead|AddHeader|AppendToLog"
+ + "|BinaryWrite|Clear|Flush|Redirect|Write|CreateObject|HTMLEncode|MapPath|URLEncode|Abandon|Convert|Regex",
+ "support.function.event.asp": "Application_OnEnd|Application_OnStart"
+ + "|OnTransactionAbort|OnTransactionCommit|Session_OnEnd|Session_OnStart",
+ "support.function.vb.asp": "Array|Add|Asc|Atn|CBool|CByte|CCur|CDate|CDbl|Chr|CInt|CLng"
+ + "|Conversions|Cos|CreateObject|CSng|CStr|Date|DateAdd|DateDiff|DatePart|DateSerial"
+ + "|DateValue|Day|Derived|Math|Escape|Eval|Exists|Exp|Filter|FormatCurrency"
+ + "|FormatDateTime|FormatNumber|FormatPercent|GetLocale|GetObject|GetRef|Hex"
+ + "|Hour|InputBox|InStr|InStrRev|Int|Fix|IsArray|IsDate|IsEmpty|IsNull|IsNumeric"
+ + "|IsObject|Item|Items|Join|Keys|LBound|LCase|Left|Len|LoadPicture|Log|LTrim|RTrim"
+ + "|Trim|Maths|Mid|Minute|Month|MonthName|MsgBox|Now|Oct|Remove|RemoveAll|Replace"
+ + "|RGB|Right|Rnd|Round|ScriptEngine|ScriptEngineBuildVersion|ScriptEngineMajorVersion"
+ + "|ScriptEngineMinorVersion|Second|SetLocale|Sgn|Sin|Space|Split|Sqr|StrComp|String|StrReverse"
+ + "|Tan|Time|Timer|TimeSerial|TimeValue|TypeName|UBound|UCase|Unescape|VarType|Weekday|WeekdayName|Year",
+ "support.type.vb.asp": "vbtrue|vbfalse|vbcr|vbcrlf|vbformfeed|vblf|vbnewline|vbnullchar|vbnullstring|"
+ + "int32|vbtab|vbverticaltab|vbbinarycompare|vbtextcomparevbsunday|vbmonday|vbtuesday|vbwednesday"
+ + "|vbthursday|vbfriday|vbsaturday|vbusesystemdayofweek|vbfirstjan1|vbfirstfourdays|vbfirstfullweek"
+ + "|vbgeneraldate|vblongdate|vbshortdate|vblongtime|vbshorttime|vbobjecterror|vbEmpty|vbNull|vbInteger"
+ + "|vbLong|vbSingle|vbDouble|vbCurrency|vbDate|vbString|vbObject|vbError|vbBoolean|vbVariant"
+ + "|vbDataObject|vbDecimal|vbByte|vbArray"
+ }, "identifier", true);
+
+ this.$rules = {
+ "start": [
+ {
+ token: [
+ "meta.ending-space"
+ ],
+ regex: "$"
+ },
+ {
+ token: [null],
+ regex: "^(?=\\t)",
+ next: "state_3"
+ },
+ {
+ token: [null],
+ regex: "^(?= )",
+ next: "state_4"
+ },
+ {
+ token: [
+ "text",
+ "storage.type.function.asp",
+ "text",
+ "entity.name.function.asp",
+ "text",
+ "punctuation.definition.parameters.asp",
+ "variable.parameter.function.asp",
+ "punctuation.definition.parameters.asp"
+ ],
+ regex: "^(\\s*)(Function|Sub)(\\s+)([a-zA-Z_]\\w*)(\\s*)(\\()([^)]*)(\\))"
+ },
+ {
+ token: "punctuation.definition.comment.asp",
+ regex: "'|REM(?=\\s|$)",
+ next: "comment",
+ caseInsensitive: true
+ },
+ {
+ token: "storage.type.asp",
+ regex: "On Error Resume Next|On Error GoTo",
+ caseInsensitive: true
+ },
+ {
+ token: "punctuation.definition.string.begin.asp",
+ regex: '"',
+ next: "string"
+ },
+ {
+ token: [
+ "punctuation.definition.variable.asp"
+ ],
+ regex: "(\\$)[a-zA-Z_x7f-xff][a-zA-Z0-9_x7f-xff]*?\\b\\s*"
+ },
+ {
+ token: "constant.numeric.asp",
+ regex: "-?\\b(?:(?:0(?:x|X)[0-9a-fA-F]*)|(?:(?:[0-9]+\\.?[0-9]*)|(?:\\.[0-9]+))(?:(?:e|E)(?:\\+|-)?[0-9]+)?)(?:L|l|UL|ul|u|U|F|f)?\\b"
+ },
+ {
+ regex: "\\w+",
+ token: keywordMapper
+ },
+ {
+ token: ["entity.name.function.asp"],
+ regex: "(?:(\\b[a-zA-Z_x7f-xff][a-zA-Z0-9_x7f-xff]*?\\b)(?=\\(\\)?))"
+ },
+ {
+ token: ["keyword.operator.asp"],
+ regex: "\\-|\\+|\\*\\/|\\>|\\<|\\=|\\&"
+ }
+ ],
+ "state_3": [
+ {
+ token: [
+ "meta.odd-tab.tabs",
+ "meta.even-tab.tabs"
+ ],
+ regex: "(\\t)(\\t)?"
+ },
+ {
+ token: "meta.leading-space",
+ regex: "(?=[^\\t])",
+ next: "start"
+ },
+ {
+ token: "meta.leading-space",
+ regex: ".",
+ next: "state_3"
+ }
+ ],
+ "state_4": [
+ {
+ token: ["meta.odd-tab.spaces", "meta.even-tab.spaces"],
+ regex: "( )( )?"
+ },
+ {
+ token: "meta.leading-space",
+ regex: "(?=[^ ])",
+ next: "start"
+ },
+ {
+ defaultToken: "meta.leading-space"
+ }
+ ],
+ "comment": [
+ {
+ token: "comment.line.apostrophe.asp",
+ regex: "$|(?=(?:%>))",
+ next: "start"
+ },
+ {
+ defaultToken: "comment.line.apostrophe.asp"
+ }
+ ],
+ "string": [
+ {
+ token: "constant.character.escape.apostrophe.asp",
+ regex: '""'
+ },
+ {
+ token: "string.quoted.double.asp",
+ regex: '"',
+ next: "start"
+ },
+ {
+ defaultToken: "string.quoted.double.asp"
+ }
+ ]
+}
+
+};
+
+oop.inherits(VBScriptHighlightRules, TextHighlightRules);
+
+exports.VBScriptHighlightRules = VBScriptHighlightRules;
+});
+
+ace.define("ace/mode/vbscript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/vbscript_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var VBScriptHighlightRules = require("./vbscript_highlight_rules").VBScriptHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = VBScriptHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = ["'", "REM"];
+
+ this.$id = "ace/mode/vbscript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-velocity.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-velocity.js
new file mode 100644
index 00000000..2a420b66
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-velocity.js
@@ -0,0 +1,2762 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/css_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var supportType = exports.supportType = "align-content|align-items|align-self|all|animation|animation-delay|animation-direction|animation-duration|animation-fill-mode|animation-iteration-count|animation-name|animation-play-state|animation-timing-function|backface-visibility|background|background-attachment|background-blend-mode|background-clip|background-color|background-image|background-origin|background-position|background-repeat|background-size|border|border-bottom|border-bottom-color|border-bottom-left-radius|border-bottom-right-radius|border-bottom-style|border-bottom-width|border-collapse|border-color|border-image|border-image-outset|border-image-repeat|border-image-slice|border-image-source|border-image-width|border-left|border-left-color|border-left-style|border-left-width|border-radius|border-right|border-right-color|border-right-style|border-right-width|border-spacing|border-style|border-top|border-top-color|border-top-left-radius|border-top-right-radius|border-top-style|border-top-width|border-width|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|column-count|column-fill|column-gap|column-rule|column-rule-color|column-rule-style|column-rule-width|column-span|column-width|columns|content|counter-increment|counter-reset|cursor|direction|display|empty-cells|filter|flex|flex-basis|flex-direction|flex-flow|flex-grow|flex-shrink|flex-wrap|float|font|font-family|font-size|font-size-adjust|font-stretch|font-style|font-variant|font-weight|hanging-punctuation|height|justify-content|left|letter-spacing|line-height|list-style|list-style-image|list-style-position|list-style-type|margin|margin-bottom|margin-left|margin-right|margin-top|max-height|max-width|min-height|min-width|nav-down|nav-index|nav-left|nav-right|nav-up|opacity|order|outline|outline-color|outline-offset|outline-style|outline-width|overflow|overflow-x|overflow-y|padding|padding-bottom|padding-left|padding-right|padding-top|page-break-after|page-break-before|page-break-inside|perspective|perspective-origin|position|quotes|resize|right|tab-size|table-layout|text-align|text-align-last|text-decoration|text-decoration-color|text-decoration-line|text-decoration-style|text-indent|text-justify|text-overflow|text-shadow|text-transform|top|transform|transform-origin|transform-style|transition|transition-delay|transition-duration|transition-property|transition-timing-function|unicode-bidi|vertical-align|visibility|white-space|width|word-break|word-spacing|word-wrap|z-index";
+var supportFunction = exports.supportFunction = "rgb|rgba|url|attr|counter|counters";
+var supportConstant = exports.supportConstant = "absolute|after-edge|after|all-scroll|all|alphabetic|always|antialiased|armenian|auto|avoid-column|avoid-page|avoid|balance|baseline|before-edge|before|below|bidi-override|block-line-height|block|bold|bolder|border-box|both|bottom|box|break-all|break-word|capitalize|caps-height|caption|center|central|char|circle|cjk-ideographic|clone|close-quote|col-resize|collapse|column|consider-shifts|contain|content-box|cover|crosshair|cubic-bezier|dashed|decimal-leading-zero|decimal|default|disabled|disc|disregard-shifts|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ease-in|ease-in-out|ease-out|ease|ellipsis|end|exclude-ruby|fill|fixed|georgian|glyphs|grid-height|groove|hand|hanging|hebrew|help|hidden|hiragana-iroha|hiragana|horizontal|icon|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|ideographic|inactive|include-ruby|inherit|initial|inline-block|inline-box|inline-line-height|inline-table|inline|inset|inside|inter-ideograph|inter-word|invert|italic|justify|katakana-iroha|katakana|keep-all|last|left|lighter|line-edge|line-through|line|linear|list-item|local|loose|lower-alpha|lower-greek|lower-latin|lower-roman|lowercase|lr-tb|ltr|mathematical|max-height|max-size|medium|menu|message-box|middle|move|n-resize|ne-resize|newspaper|no-change|no-close-quote|no-drop|no-open-quote|no-repeat|none|normal|not-allowed|nowrap|nw-resize|oblique|open-quote|outset|outside|overline|padding-box|page|pointer|pre-line|pre-wrap|pre|preserve-3d|progress|relative|repeat-x|repeat-y|repeat|replaced|reset-size|ridge|right|round|row-resize|rtl|s-resize|scroll|se-resize|separate|slice|small-caps|small-caption|solid|space|square|start|static|status-bar|step-end|step-start|steps|stretch|strict|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|table|tb-rl|text-after-edge|text-before-edge|text-bottom|text-size|text-top|text|thick|thin|transparent|underline|upper-alpha|upper-latin|upper-roman|uppercase|use-script|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|z-index|zero";
+var supportConstantColor = exports.supportConstantColor = "aliceblue|antiquewhite|aqua|aquamarine|azure|beige|bisque|black|blanchedalmond|blue|blueviolet|brown|burlywood|cadetblue|chartreuse|chocolate|coral|cornflowerblue|cornsilk|crimson|cyan|darkblue|darkcyan|darkgoldenrod|darkgray|darkgreen|darkgrey|darkkhaki|darkmagenta|darkolivegreen|darkorange|darkorchid|darkred|darksalmon|darkseagreen|darkslateblue|darkslategray|darkslategrey|darkturquoise|darkviolet|deeppink|deepskyblue|dimgray|dimgrey|dodgerblue|firebrick|floralwhite|forestgreen|fuchsia|gainsboro|ghostwhite|gold|goldenrod|gray|green|greenyellow|grey|honeydew|hotpink|indianred|indigo|ivory|khaki|lavender|lavenderblush|lawngreen|lemonchiffon|lightblue|lightcoral|lightcyan|lightgoldenrodyellow|lightgray|lightgreen|lightgrey|lightpink|lightsalmon|lightseagreen|lightskyblue|lightslategray|lightslategrey|lightsteelblue|lightyellow|lime|limegreen|linen|magenta|maroon|mediumaquamarine|mediumblue|mediumorchid|mediumpurple|mediumseagreen|mediumslateblue|mediumspringgreen|mediumturquoise|mediumvioletred|midnightblue|mintcream|mistyrose|moccasin|navajowhite|navy|oldlace|olive|olivedrab|orange|orangered|orchid|palegoldenrod|palegreen|paleturquoise|palevioletred|papayawhip|peachpuff|peru|pink|plum|powderblue|purple|rebeccapurple|red|rosybrown|royalblue|saddlebrown|salmon|sandybrown|seagreen|seashell|sienna|silver|skyblue|slateblue|slategray|slategrey|snow|springgreen|steelblue|tan|teal|thistle|tomato|turquoise|violet|wheat|white|whitesmoke|yellow|yellowgreen";
+var supportConstantFonts = exports.supportConstantFonts = "arial|century|comic|courier|cursive|fantasy|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace";
+
+var numRe = exports.numRe = "\\-?(?:(?:[0-9]+(?:\\.[0-9]+)?)|(?:\\.[0-9]+))";
+var pseudoElements = exports.pseudoElements = "(\\:+)\\b(after|before|first-letter|first-line|moz-selection|selection)\\b";
+var pseudoClasses = exports.pseudoClasses = "(:)\\b(active|checked|disabled|empty|enabled|first-child|first-of-type|focus|hover|indeterminate|invalid|last-child|last-of-type|link|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|only-child|only-of-type|required|root|target|valid|visited)\\b";
+
+var CssHighlightRules = function() {
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": supportFunction,
+ "support.constant": supportConstant,
+ "support.type": supportType,
+ "support.constant.color": supportConstantColor,
+ "support.constant.fonts": supportConstantFonts
+ }, "text", true);
+
+ this.$rules = {
+ "start" : [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "ruleset"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}"
+ }, {
+ token: "string",
+ regex: "@",
+ next: "media"
+ }, {
+ token: "keyword",
+ regex: "#[a-z0-9-_]+"
+ }, {
+ token: "keyword",
+ regex: "%"
+ }, {
+ token: "variable",
+ regex: "\\.[a-z0-9-_]+"
+ }, {
+ token: "string",
+ regex: ":[a-z0-9-_]+"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token: "constant",
+ regex: "[a-z0-9-_]+"
+ }, {
+ caseInsensitive: true
+ }],
+
+ "media": [{
+ include : ["strings", "url", "comments"]
+ }, {
+ token: "paren.lparen",
+ regex: "\\{",
+ next: "start"
+ }, {
+ token: "paren.rparen",
+ regex: "\\}",
+ next: "start"
+ }, {
+ token: "string",
+ regex: ";",
+ next: "start"
+ }, {
+ token: "keyword",
+ regex: "(?:media|supports|document|charset|import|namespace|media|supports|document"
+ + "|page|font|keyframes|viewport|counter-style|font-feature-values"
+ + "|swash|ornaments|annotation|stylistic|styleset|character-variant)"
+ }],
+
+ "comments" : [{
+ token: "comment", // multi line comment
+ regex: "\\/\\*",
+ push: [{
+ token : "comment",
+ regex : "\\*\\/",
+ next : "pop"
+ }, {
+ defaultToken : "comment"
+ }]
+ }],
+
+ "ruleset" : [{
+ regex : "-(webkit|ms|moz|o)-",
+ token : "text"
+ }, {
+ token : "paren.rparen",
+ regex : "\\}",
+ next : "start"
+ }, {
+ include : ["strings", "url", "comments"]
+ }, {
+ token : ["constant.numeric", "keyword"],
+ regex : "(" + numRe + ")(ch|cm|deg|em|ex|fr|gd|grad|Hz|in|kHz|mm|ms|pc|pt|px|rad|rem|s|turn|vh|vm|vw|%)"
+ }, {
+ token : "constant.numeric",
+ regex : numRe
+ }, {
+ token : "constant.numeric", // hex6 color
+ regex : "#[a-f0-9]{6}"
+ }, {
+ token : "constant.numeric", // hex3 color
+ regex : "#[a-f0-9]{3}"
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-element.css"],
+ regex : pseudoElements
+ }, {
+ token : ["punctuation", "entity.other.attribute-name.pseudo-class.css"],
+ regex : pseudoClasses
+ }, {
+ include: "url"
+ }, {
+ token : keywordMapper,
+ regex : "\\-?[a-zA-Z_][a-zA-Z0-9_\\-]*"
+ }, {
+ caseInsensitive: true
+ }],
+
+ url: [{
+ token : "support.function",
+ regex : "(?:url(:?-prefix)?|domain|regexp)\\(",
+ push: [{
+ token : "support.function",
+ regex : "\\)",
+ next : "pop"
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+
+ strings: [{
+ token : "string.start",
+ regex : "'",
+ push : [{
+ token : "string.end",
+ regex : "'|$",
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }, {
+ token : "string.start",
+ regex : '"',
+ push : [{
+ token : "string.end",
+ regex : '"|$',
+ next: "pop"
+ }, {
+ include : "escapes"
+ }, {
+ token : "constant.language.escape",
+ regex : /\\$/,
+ consumeLineEnd: true
+ }, {
+ defaultToken: "string"
+ }]
+ }],
+ escapes: [{
+ token : "constant.language.escape",
+ regex : /\\([a-fA-F\d]{1,6}|[^a-fA-F\d])/
+ }]
+
+ };
+
+ this.normalizeRules();
+};
+
+oop.inherits(CssHighlightRules, TextHighlightRules);
+
+exports.CssHighlightRules = CssHighlightRules;
+
+});
+
+ace.define("ace/mode/css_completions",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var propertyMap = {
+ "background": {"#$0": 1},
+ "background-color": {"#$0": 1, "transparent": 1, "fixed": 1},
+ "background-image": {"url('/$0')": 1},
+ "background-repeat": {"repeat": 1, "repeat-x": 1, "repeat-y": 1, "no-repeat": 1, "inherit": 1},
+ "background-position": {"bottom":2, "center":2, "left":2, "right":2, "top":2, "inherit":2},
+ "background-attachment": {"scroll": 1, "fixed": 1},
+ "background-size": {"cover": 1, "contain": 1},
+ "background-clip": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "background-origin": {"border-box": 1, "padding-box": 1, "content-box": 1},
+ "border": {"solid $0": 1, "dashed $0": 1, "dotted $0": 1, "#$0": 1},
+ "border-color": {"#$0": 1},
+ "border-style": {"solid":2, "dashed":2, "dotted":2, "double":2, "groove":2, "hidden":2, "inherit":2, "inset":2, "none":2, "outset":2, "ridged":2},
+ "border-collapse": {"collapse": 1, "separate": 1},
+ "bottom": {"px": 1, "em": 1, "%": 1},
+ "clear": {"left": 1, "right": 1, "both": 1, "none": 1},
+ "color": {"#$0": 1, "rgb(#$00,0,0)": 1},
+ "cursor": {"default": 1, "pointer": 1, "move": 1, "text": 1, "wait": 1, "help": 1, "progress": 1, "n-resize": 1, "ne-resize": 1, "e-resize": 1, "se-resize": 1, "s-resize": 1, "sw-resize": 1, "w-resize": 1, "nw-resize": 1},
+ "display": {"none": 1, "block": 1, "inline": 1, "inline-block": 1, "table-cell": 1},
+ "empty-cells": {"show": 1, "hide": 1},
+ "float": {"left": 1, "right": 1, "none": 1},
+ "font-family": {"Arial":2,"Comic Sans MS":2,"Consolas":2,"Courier New":2,"Courier":2,"Georgia":2,"Monospace":2,"Sans-Serif":2, "Segoe UI":2,"Tahoma":2,"Times New Roman":2,"Trebuchet MS":2,"Verdana": 1},
+ "font-size": {"px": 1, "em": 1, "%": 1},
+ "font-weight": {"bold": 1, "normal": 1},
+ "font-style": {"italic": 1, "normal": 1},
+ "font-variant": {"normal": 1, "small-caps": 1},
+ "height": {"px": 1, "em": 1, "%": 1},
+ "left": {"px": 1, "em": 1, "%": 1},
+ "letter-spacing": {"normal": 1},
+ "line-height": {"normal": 1},
+ "list-style-type": {"none": 1, "disc": 1, "circle": 1, "square": 1, "decimal": 1, "decimal-leading-zero": 1, "lower-roman": 1, "upper-roman": 1, "lower-greek": 1, "lower-latin": 1, "upper-latin": 1, "georgian": 1, "lower-alpha": 1, "upper-alpha": 1},
+ "margin": {"px": 1, "em": 1, "%": 1},
+ "margin-right": {"px": 1, "em": 1, "%": 1},
+ "margin-left": {"px": 1, "em": 1, "%": 1},
+ "margin-top": {"px": 1, "em": 1, "%": 1},
+ "margin-bottom": {"px": 1, "em": 1, "%": 1},
+ "max-height": {"px": 1, "em": 1, "%": 1},
+ "max-width": {"px": 1, "em": 1, "%": 1},
+ "min-height": {"px": 1, "em": 1, "%": 1},
+ "min-width": {"px": 1, "em": 1, "%": 1},
+ "overflow": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-x": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "overflow-y": {"hidden": 1, "visible": 1, "auto": 1, "scroll": 1},
+ "padding": {"px": 1, "em": 1, "%": 1},
+ "padding-top": {"px": 1, "em": 1, "%": 1},
+ "padding-right": {"px": 1, "em": 1, "%": 1},
+ "padding-bottom": {"px": 1, "em": 1, "%": 1},
+ "padding-left": {"px": 1, "em": 1, "%": 1},
+ "page-break-after": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "page-break-before": {"auto": 1, "always": 1, "avoid": 1, "left": 1, "right": 1},
+ "position": {"absolute": 1, "relative": 1, "fixed": 1, "static": 1},
+ "right": {"px": 1, "em": 1, "%": 1},
+ "table-layout": {"fixed": 1, "auto": 1},
+ "text-decoration": {"none": 1, "underline": 1, "line-through": 1, "blink": 1},
+ "text-align": {"left": 1, "right": 1, "center": 1, "justify": 1},
+ "text-transform": {"capitalize": 1, "uppercase": 1, "lowercase": 1, "none": 1},
+ "top": {"px": 1, "em": 1, "%": 1},
+ "vertical-align": {"top": 1, "bottom": 1},
+ "visibility": {"hidden": 1, "visible": 1},
+ "white-space": {"nowrap": 1, "normal": 1, "pre": 1, "pre-line": 1, "pre-wrap": 1},
+ "width": {"px": 1, "em": 1, "%": 1},
+ "word-spacing": {"normal": 1},
+ "filter": {"alpha(opacity=$0100)": 1},
+
+ "text-shadow": {"$02px 2px 2px #777": 1},
+ "text-overflow": {"ellipsis-word": 1, "clip": 1, "ellipsis": 1},
+ "-moz-border-radius": 1,
+ "-moz-border-radius-topright": 1,
+ "-moz-border-radius-bottomright": 1,
+ "-moz-border-radius-topleft": 1,
+ "-moz-border-radius-bottomleft": 1,
+ "-webkit-border-radius": 1,
+ "-webkit-border-top-right-radius": 1,
+ "-webkit-border-top-left-radius": 1,
+ "-webkit-border-bottom-right-radius": 1,
+ "-webkit-border-bottom-left-radius": 1,
+ "-moz-box-shadow": 1,
+ "-webkit-box-shadow": 1,
+ "transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-moz-transform": {"rotate($00deg)": 1, "skew($00deg)": 1},
+ "-webkit-transform": {"rotate($00deg)": 1, "skew($00deg)": 1 }
+};
+
+var CssCompletions = function() {
+
+};
+
+(function() {
+
+ this.completionsDefined = false;
+
+ this.defineCompletions = function() {
+ if (document) {
+ var style = document.createElement('c').style;
+
+ for (var i in style) {
+ if (typeof style[i] !== 'string')
+ continue;
+
+ var name = i.replace(/[A-Z]/g, function(x) {
+ return '-' + x.toLowerCase();
+ });
+
+ if (!propertyMap.hasOwnProperty(name))
+ propertyMap[name] = 1;
+ }
+ }
+
+ this.completionsDefined = true;
+ }
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ if (!this.completionsDefined) {
+ this.defineCompletions();
+ }
+
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (state==='ruleset'){
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/:[^;]+$/.test(line)) {
+ /([\w\-]+):[^:]*$/.test(line);
+
+ return this.getPropertyValueCompletions(state, session, pos, prefix);
+ } else {
+ return this.getPropertyCompletions(state, session, pos, prefix);
+ }
+ }
+
+ return [];
+ };
+
+ this.getPropertyCompletions = function(state, session, pos, prefix) {
+ var properties = Object.keys(propertyMap);
+ return properties.map(function(property){
+ return {
+ caption: property,
+ snippet: property + ': $0',
+ meta: "property",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getPropertyValueCompletions = function(state, session, pos, prefix) {
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ var property = (/([\w\-]+):[^:]*$/.exec(line) || {})[1];
+
+ if (!property)
+ return [];
+ var values = [];
+ if (property in propertyMap && typeof propertyMap[property] === "object") {
+ values = Object.keys(propertyMap[property]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "property value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(CssCompletions.prototype);
+
+exports.CssCompletions = CssCompletions;
+});
+
+ace.define("ace/mode/behaviour/css",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var CstyleBehaviour = require("./cstyle").CstyleBehaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var CssBehaviour = function () {
+
+ this.inherit(CstyleBehaviour);
+
+ this.add("colon", "insertion", function (state, action, editor, session, text) {
+ if (text === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ':') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ if (!line.substring(cursor.column).match(/^\s*;/)) {
+ return {
+ text: ':;',
+ selection: [1, 1]
+ }
+ }
+ }
+ }
+ });
+
+ this.add("colon", "deletion", function (state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && selected === ':') {
+ var cursor = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+ if (token && token.value.match(/\s+/)) {
+ token = iterator.stepBackward();
+ }
+ if (token && token.type === 'support.type') {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.end.column, range.end.column + 1);
+ if (rightChar === ';') {
+ range.end.column ++;
+ return range;
+ }
+ }
+ }
+ });
+
+ this.add("semicolon", "insertion", function (state, action, editor, session, text) {
+ if (text === ';') {
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ if (rightChar === ';') {
+ return {
+ text: '',
+ selection: [1, 1]
+ }
+ }
+ }
+ });
+
+}
+oop.inherits(CssBehaviour, CstyleBehaviour);
+
+exports.CssBehaviour = CssBehaviour;
+});
+
+ace.define("ace/mode/css",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/css_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/css_completions","ace/mode/behaviour/css","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CssCompletions = require("./css_completions").CssCompletions;
+var CssBehaviour = require("./behaviour/css").CssBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = CssHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CssBehaviour();
+ this.$completer = new CssCompletions();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.foldingRules = "cStyle";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var tokens = this.getTokenizer().getLineTokens(line, state).tokens;
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ var match = line.match(/^.*\{\s*$/);
+ if (match) {
+ indent += tab;
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/css_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/css";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
+
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/html_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/css_highlight_rules","ace/mode/javascript_highlight_rules","ace/mode/xml_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var CssHighlightRules = require("./css_highlight_rules").CssHighlightRules;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+
+var tagMap = lang.createMap({
+ a : 'anchor',
+ button : 'form',
+ form : 'form',
+ img : 'image',
+ input : 'form',
+ label : 'form',
+ option : 'form',
+ script : 'script',
+ select : 'form',
+ textarea : 'form',
+ style : 'style',
+ table : 'table',
+ tbody : 'table',
+ td : 'table',
+ tfoot : 'table',
+ th : 'table',
+ tr : 'table'
+});
+
+var HtmlHighlightRules = function() {
+ XmlHighlightRules.call(this);
+
+ this.addRules({
+ attributes: [{
+ include : "tag_whitespace"
+ }, {
+ token : "entity.other.attribute-name.xml",
+ regex : "[-_a-zA-Z0-9:.]+"
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "=",
+ push : [{
+ include: "tag_whitespace"
+ }, {
+ token : "string.unquoted.attribute-value.html",
+ regex : "[^<>='\"`\\s]+",
+ next : "pop"
+ }, {
+ token : "empty",
+ regex : "",
+ next : "pop"
+ }]
+ }, {
+ include : "attribute_value"
+ }],
+ tag: [{
+ token : function(start, tag) {
+ var group = tagMap[tag];
+ return ["meta.tag.punctuation." + (start == "<" ? "" : "end-") + "tag-open.xml",
+ "meta.tag" + (group ? "." + group : "") + ".tag-name.xml"];
+ },
+ regex : "(</?)([-_a-zA-Z0-9:.]+)",
+ next: "tag_stuff"
+ }],
+ tag_stuff: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ });
+
+ this.embedTagRules(CssHighlightRules, "css-", "style");
+ this.embedTagRules(new JavaScriptHighlightRules({jsx: false}).getRules(), "js-", "script");
+
+ if (this.constructor === HtmlHighlightRules)
+ this.normalizeRules();
+};
+
+oop.inherits(HtmlHighlightRules, XmlHighlightRules);
+
+exports.HtmlHighlightRules = HtmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/mixed",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(defaultMode, subModes) {
+ this.defaultMode = defaultMode;
+ this.subModes = subModes;
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+
+ this.$getMode = function(state) {
+ if (typeof state != "string")
+ state = state[0];
+ for (var key in this.subModes) {
+ if (state.indexOf(key) === 0)
+ return this.subModes[key];
+ }
+ return null;
+ };
+
+ this.$tryMode = function(state, session, foldStyle, row) {
+ var mode = this.$getMode(state);
+ return (mode ? mode.getFoldWidget(session, foldStyle, row) : "");
+ };
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ return (
+ this.$tryMode(session.getState(row-1), session, foldStyle, row) ||
+ this.$tryMode(session.getState(row), session, foldStyle, row) ||
+ this.defaultMode.getFoldWidget(session, foldStyle, row)
+ );
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var mode = this.$getMode(session.getState(row-1));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.$getMode(session.getState(row));
+
+ if (!mode || !mode.getFoldWidget(session, foldStyle, row))
+ mode = this.defaultMode;
+
+ return mode.getFoldWidgetRange(session, foldStyle, row);
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/folding/html",["require","exports","module","ace/lib/oop","ace/mode/folding/mixed","ace/mode/folding/xml","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var MixedFoldMode = require("./mixed").FoldMode;
+var XmlFoldMode = require("./xml").FoldMode;
+var CStyleFoldMode = require("./cstyle").FoldMode;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalTags) {
+ MixedFoldMode.call(this, new XmlFoldMode(voidElements, optionalTags), {
+ "js-": new CStyleFoldMode(),
+ "css-": new CStyleFoldMode()
+ });
+};
+
+oop.inherits(FoldMode, MixedFoldMode);
+
+});
+
+ace.define("ace/mode/html_completions",["require","exports","module","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var TokenIterator = require("../token_iterator").TokenIterator;
+
+var commonAttributes = [
+ "accesskey",
+ "class",
+ "contenteditable",
+ "contextmenu",
+ "dir",
+ "draggable",
+ "dropzone",
+ "hidden",
+ "id",
+ "inert",
+ "itemid",
+ "itemprop",
+ "itemref",
+ "itemscope",
+ "itemtype",
+ "lang",
+ "spellcheck",
+ "style",
+ "tabindex",
+ "title",
+ "translate"
+];
+
+var eventAttributes = [
+ "onabort",
+ "onblur",
+ "oncancel",
+ "oncanplay",
+ "oncanplaythrough",
+ "onchange",
+ "onclick",
+ "onclose",
+ "oncontextmenu",
+ "oncuechange",
+ "ondblclick",
+ "ondrag",
+ "ondragend",
+ "ondragenter",
+ "ondragleave",
+ "ondragover",
+ "ondragstart",
+ "ondrop",
+ "ondurationchange",
+ "onemptied",
+ "onended",
+ "onerror",
+ "onfocus",
+ "oninput",
+ "oninvalid",
+ "onkeydown",
+ "onkeypress",
+ "onkeyup",
+ "onload",
+ "onloadeddata",
+ "onloadedmetadata",
+ "onloadstart",
+ "onmousedown",
+ "onmousemove",
+ "onmouseout",
+ "onmouseover",
+ "onmouseup",
+ "onmousewheel",
+ "onpause",
+ "onplay",
+ "onplaying",
+ "onprogress",
+ "onratechange",
+ "onreset",
+ "onscroll",
+ "onseeked",
+ "onseeking",
+ "onselect",
+ "onshow",
+ "onstalled",
+ "onsubmit",
+ "onsuspend",
+ "ontimeupdate",
+ "onvolumechange",
+ "onwaiting"
+];
+
+var globalAttributes = commonAttributes.concat(eventAttributes);
+
+var attributeMap = {
+ "html": {"manifest": 1},
+ "head": {},
+ "title": {},
+ "base": {"href": 1, "target": 1},
+ "link": {"href": 1, "hreflang": 1, "rel": {"stylesheet": 1, "icon": 1}, "media": {"all": 1, "screen": 1, "print": 1}, "type": {"text/css": 1, "image/png": 1, "image/jpeg": 1, "image/gif": 1}, "sizes": 1},
+ "meta": {"http-equiv": {"content-type": 1}, "name": {"description": 1, "keywords": 1}, "content": {"text/html; charset=UTF-8": 1}, "charset": 1},
+ "style": {"type": 1, "media": {"all": 1, "screen": 1, "print": 1}, "scoped": 1},
+ "script": {"charset": 1, "type": {"text/javascript": 1}, "src": 1, "defer": 1, "async": 1},
+ "noscript": {"href": 1},
+ "body": {"onafterprint": 1, "onbeforeprint": 1, "onbeforeunload": 1, "onhashchange": 1, "onmessage": 1, "onoffline": 1, "onpopstate": 1, "onredo": 1, "onresize": 1, "onstorage": 1, "onundo": 1, "onunload": 1},
+ "section": {},
+ "nav": {},
+ "article": {"pubdate": 1},
+ "aside": {},
+ "h1": {},
+ "h2": {},
+ "h3": {},
+ "h4": {},
+ "h5": {},
+ "h6": {},
+ "header": {},
+ "footer": {},
+ "address": {},
+ "main": {},
+ "p": {},
+ "hr": {},
+ "pre": {},
+ "blockquote": {"cite": 1},
+ "ol": {"start": 1, "reversed": 1},
+ "ul": {},
+ "li": {"value": 1},
+ "dl": {},
+ "dt": {},
+ "dd": {},
+ "figure": {},
+ "figcaption": {},
+ "div": {},
+ "a": {"href": 1, "target": {"_blank": 1, "top": 1}, "ping": 1, "rel": {"nofollow": 1, "alternate": 1, "author": 1, "bookmark": 1, "help": 1, "license": 1, "next": 1, "noreferrer": 1, "prefetch": 1, "prev": 1, "search": 1, "tag": 1}, "media": 1, "hreflang": 1, "type": 1},
+ "em": {},
+ "strong": {},
+ "small": {},
+ "s": {},
+ "cite": {},
+ "q": {"cite": 1},
+ "dfn": {},
+ "abbr": {},
+ "data": {},
+ "time": {"datetime": 1},
+ "code": {},
+ "var": {},
+ "samp": {},
+ "kbd": {},
+ "sub": {},
+ "sup": {},
+ "i": {},
+ "b": {},
+ "u": {},
+ "mark": {},
+ "ruby": {},
+ "rt": {},
+ "rp": {},
+ "bdi": {},
+ "bdo": {},
+ "span": {},
+ "br": {},
+ "wbr": {},
+ "ins": {"cite": 1, "datetime": 1},
+ "del": {"cite": 1, "datetime": 1},
+ "img": {"alt": 1, "src": 1, "height": 1, "width": 1, "usemap": 1, "ismap": 1},
+ "iframe": {"name": 1, "src": 1, "height": 1, "width": 1, "sandbox": {"allow-same-origin": 1, "allow-top-navigation": 1, "allow-forms": 1, "allow-scripts": 1}, "seamless": {"seamless": 1}},
+ "embed": {"src": 1, "height": 1, "width": 1, "type": 1},
+ "object": {"param": 1, "data": 1, "type": 1, "height" : 1, "width": 1, "usemap": 1, "name": 1, "form": 1, "classid": 1},
+ "param": {"name": 1, "value": 1},
+ "video": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "width": 1, "height": 1, "poster": 1, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1}},
+ "audio": {"src": 1, "autobuffer": 1, "autoplay": {"autoplay": 1}, "loop": {"loop": 1}, "controls": {"controls": 1}, "muted": {"muted": 1}, "preload": {"auto": 1, "metadata": 1, "none": 1 }},
+ "source": {"src": 1, "type": 1, "media": 1},
+ "track": {"kind": 1, "src": 1, "srclang": 1, "label": 1, "default": 1},
+ "canvas": {"width": 1, "height": 1},
+ "map": {"name": 1},
+ "area": {"shape": 1, "coords": 1, "href": 1, "hreflang": 1, "alt": 1, "target": 1, "media": 1, "rel": 1, "ping": 1, "type": 1},
+ "svg": {},
+ "math": {},
+ "table": {"summary": 1},
+ "caption": {},
+ "colgroup": {"span": 1},
+ "col": {"span": 1},
+ "tbody": {},
+ "thead": {},
+ "tfoot": {},
+ "tr": {},
+ "td": {"headers": 1, "rowspan": 1, "colspan": 1},
+ "th": {"headers": 1, "rowspan": 1, "colspan": 1, "scope": 1},
+ "form": {"accept-charset": 1, "action": 1, "autocomplete": 1, "enctype": {"multipart/form-data": 1, "application/x-www-form-urlencoded": 1}, "method": {"get": 1, "post": 1}, "name": 1, "novalidate": 1, "target": {"_blank": 1, "top": 1}},
+ "fieldset": {"disabled": 1, "form": 1, "name": 1},
+ "legend": {},
+ "label": {"form": 1, "for": 1},
+ "input": {
+ "type": {"text": 1, "password": 1, "hidden": 1, "checkbox": 1, "submit": 1, "radio": 1, "file": 1, "button": 1, "reset": 1, "image": 31, "color": 1, "date": 1, "datetime": 1, "datetime-local": 1, "email": 1, "month": 1, "number": 1, "range": 1, "search": 1, "tel": 1, "time": 1, "url": 1, "week": 1},
+ "accept": 1, "alt": 1, "autocomplete": {"on": 1, "off": 1}, "autofocus": {"autofocus": 1}, "checked": {"checked": 1}, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": {"application/x-www-form-urlencoded": 1, "multipart/form-data": 1, "text/plain": 1}, "formmethod": {"get": 1, "post": 1}, "formnovalidate": {"formnovalidate": 1}, "formtarget": {"_blank": 1, "_self": 1, "_parent": 1, "_top": 1}, "height": 1, "list": 1, "max": 1, "maxlength": 1, "min": 1, "multiple": {"multiple": 1}, "name": 1, "pattern": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "size": 1, "src": 1, "step": 1, "width": 1, "files": 1, "value": 1},
+ "button": {"autofocus": 1, "disabled": {"disabled": 1}, "form": 1, "formaction": 1, "formenctype": 1, "formmethod": 1, "formnovalidate": 1, "formtarget": 1, "name": 1, "value": 1, "type": {"button": 1, "submit": 1}},
+ "select": {"autofocus": 1, "disabled": 1, "form": 1, "multiple": {"multiple": 1}, "name": 1, "size": 1, "readonly":{"readonly": 1}},
+ "datalist": {},
+ "optgroup": {"disabled": 1, "label": 1},
+ "option": {"disabled": 1, "selected": 1, "label": 1, "value": 1},
+ "textarea": {"autofocus": {"autofocus": 1}, "disabled": {"disabled": 1}, "form": 1, "maxlength": 1, "name": 1, "placeholder": 1, "readonly": {"readonly": 1}, "required": {"required": 1}, "rows": 1, "cols": 1, "wrap": {"on": 1, "off": 1, "hard": 1, "soft": 1}},
+ "keygen": {"autofocus": 1, "challenge": {"challenge": 1}, "disabled": {"disabled": 1}, "form": 1, "keytype": {"rsa": 1, "dsa": 1, "ec": 1}, "name": 1},
+ "output": {"for": 1, "form": 1, "name": 1},
+ "progress": {"value": 1, "max": 1},
+ "meter": {"value": 1, "min": 1, "max": 1, "low": 1, "high": 1, "optimum": 1},
+ "details": {"open": 1},
+ "summary": {},
+ "command": {"type": 1, "label": 1, "icon": 1, "disabled": 1, "checked": 1, "radiogroup": 1, "command": 1},
+ "menu": {"type": 1, "label": 1},
+ "dialog": {"open": 1}
+};
+
+var elements = Object.keys(attributeMap);
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+function findTagName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "tag-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+function findAttributeName(session, pos) {
+ var iterator = new TokenIterator(session, pos.row, pos.column);
+ var token = iterator.getCurrentToken();
+ while (token && !is(token, "attribute-name")){
+ token = iterator.stepBackward();
+ }
+ if (token)
+ return token.value;
+}
+
+var HtmlCompletions = function() {
+
+};
+
+(function() {
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ var token = session.getTokenAt(pos.row, pos.column);
+
+ if (!token)
+ return [];
+ if (is(token, "tag-name") || is(token, "tag-open") || is(token, "end-tag-open"))
+ return this.getTagCompletions(state, session, pos, prefix);
+ if (is(token, "tag-whitespace") || is(token, "attribute-name"))
+ return this.getAttributeCompletions(state, session, pos, prefix);
+ if (is(token, "attribute-value"))
+ return this.getAttributeValueCompletions(state, session, pos, prefix);
+ var line = session.getLine(pos.row).substr(0, pos.column);
+ if (/&[a-z]*$/i.test(line))
+ return this.getHTMLEntityCompletions(state, session, pos, prefix);
+
+ return [];
+ };
+
+ this.getTagCompletions = function(state, session, pos, prefix) {
+ return elements.map(function(element){
+ return {
+ value: element,
+ meta: "tag",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ if (!tagName)
+ return [];
+ var attributes = globalAttributes;
+ if (tagName in attributeMap) {
+ attributes = attributes.concat(Object.keys(attributeMap[tagName]));
+ }
+ return attributes.map(function(attribute){
+ return {
+ caption: attribute,
+ snippet: attribute + '="$0"',
+ meta: "attribute",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getAttributeValueCompletions = function(state, session, pos, prefix) {
+ var tagName = findTagName(session, pos);
+ var attributeName = findAttributeName(session, pos);
+
+ if (!tagName)
+ return [];
+ var values = [];
+ if (tagName in attributeMap && attributeName in attributeMap[tagName] && typeof attributeMap[tagName][attributeName] === "object") {
+ values = Object.keys(attributeMap[tagName][attributeName]);
+ }
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "attribute value",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+ this.getHTMLEntityCompletions = function(state, session, pos, prefix) {
+ var values = ['Aacute;', 'aacute;', 'Acirc;', 'acirc;', 'acute;', 'AElig;', 'aelig;', 'Agrave;', 'agrave;', 'alefsym;', 'Alpha;', 'alpha;', 'amp;', 'and;', 'ang;', 'Aring;', 'aring;', 'asymp;', 'Atilde;', 'atilde;', 'Auml;', 'auml;', 'bdquo;', 'Beta;', 'beta;', 'brvbar;', 'bull;', 'cap;', 'Ccedil;', 'ccedil;', 'cedil;', 'cent;', 'Chi;', 'chi;', 'circ;', 'clubs;', 'cong;', 'copy;', 'crarr;', 'cup;', 'curren;', 'Dagger;', 'dagger;', 'dArr;', 'darr;', 'deg;', 'Delta;', 'delta;', 'diams;', 'divide;', 'Eacute;', 'eacute;', 'Ecirc;', 'ecirc;', 'Egrave;', 'egrave;', 'empty;', 'emsp;', 'ensp;', 'Epsilon;', 'epsilon;', 'equiv;', 'Eta;', 'eta;', 'ETH;', 'eth;', 'Euml;', 'euml;', 'euro;', 'exist;', 'fnof;', 'forall;', 'frac12;', 'frac14;', 'frac34;', 'frasl;', 'Gamma;', 'gamma;', 'ge;', 'gt;', 'hArr;', 'harr;', 'hearts;', 'hellip;', 'Iacute;', 'iacute;', 'Icirc;', 'icirc;', 'iexcl;', 'Igrave;', 'igrave;', 'image;', 'infin;', 'int;', 'Iota;', 'iota;', 'iquest;', 'isin;', 'Iuml;', 'iuml;', 'Kappa;', 'kappa;', 'Lambda;', 'lambda;', 'lang;', 'laquo;', 'lArr;', 'larr;', 'lceil;', 'ldquo;', 'le;', 'lfloor;', 'lowast;', 'loz;', 'lrm;', 'lsaquo;', 'lsquo;', 'lt;', 'macr;', 'mdash;', 'micro;', 'middot;', 'minus;', 'Mu;', 'mu;', 'nabla;', 'nbsp;', 'ndash;', 'ne;', 'ni;', 'not;', 'notin;', 'nsub;', 'Ntilde;', 'ntilde;', 'Nu;', 'nu;', 'Oacute;', 'oacute;', 'Ocirc;', 'ocirc;', 'OElig;', 'oelig;', 'Ograve;', 'ograve;', 'oline;', 'Omega;', 'omega;', 'Omicron;', 'omicron;', 'oplus;', 'or;', 'ordf;', 'ordm;', 'Oslash;', 'oslash;', 'Otilde;', 'otilde;', 'otimes;', 'Ouml;', 'ouml;', 'para;', 'part;', 'permil;', 'perp;', 'Phi;', 'phi;', 'Pi;', 'pi;', 'piv;', 'plusmn;', 'pound;', 'Prime;', 'prime;', 'prod;', 'prop;', 'Psi;', 'psi;', 'quot;', 'radic;', 'rang;', 'raquo;', 'rArr;', 'rarr;', 'rceil;', 'rdquo;', 'real;', 'reg;', 'rfloor;', 'Rho;', 'rho;', 'rlm;', 'rsaquo;', 'rsquo;', 'sbquo;', 'Scaron;', 'scaron;', 'sdot;', 'sect;', 'shy;', 'Sigma;', 'sigma;', 'sigmaf;', 'sim;', 'spades;', 'sub;', 'sube;', 'sum;', 'sup;', 'sup1;', 'sup2;', 'sup3;', 'supe;', 'szlig;', 'Tau;', 'tau;', 'there4;', 'Theta;', 'theta;', 'thetasym;', 'thinsp;', 'THORN;', 'thorn;', 'tilde;', 'times;', 'trade;', 'Uacute;', 'uacute;', 'uArr;', 'uarr;', 'Ucirc;', 'ucirc;', 'Ugrave;', 'ugrave;', 'uml;', 'upsih;', 'Upsilon;', 'upsilon;', 'Uuml;', 'uuml;', 'weierp;', 'Xi;', 'xi;', 'Yacute;', 'yacute;', 'yen;', 'Yuml;', 'yuml;', 'Zeta;', 'zeta;', 'zwj;', 'zwnj;'];
+
+ return values.map(function(value){
+ return {
+ caption: value,
+ snippet: value,
+ meta: "html entity",
+ score: Number.MAX_VALUE
+ };
+ });
+ };
+
+}).call(HtmlCompletions.prototype);
+
+exports.HtmlCompletions = HtmlCompletions;
+});
+
+ace.define("ace/mode/html",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/javascript","ace/mode/css","ace/mode/html_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/html","ace/mode/html_completions","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var JavaScriptMode = require("./javascript").Mode;
+var CssMode = require("./css").Mode;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var HtmlFoldMode = require("./folding/html").FoldMode;
+var HtmlCompletions = require("./html_completions").HtmlCompletions;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var voidElements = ["area", "base", "br", "col", "embed", "hr", "img", "input", "keygen", "link", "meta", "menuitem", "param", "source", "track", "wbr"];
+var optionalEndTags = ["li", "dt", "dd", "p", "rt", "rp", "optgroup", "option", "colgroup", "td", "th"];
+
+var Mode = function(options) {
+ this.fragmentContext = options && options.fragmentContext;
+ this.HighlightRules = HtmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.$completer = new HtmlCompletions();
+
+ this.createModeDelegates({
+ "js-": JavaScriptMode,
+ "css-": CssMode
+ });
+
+ this.foldingRules = new HtmlFoldMode(this.voidElements, lang.arrayToMap(optionalEndTags));
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.voidElements = lang.arrayToMap(voidElements);
+
+ this.getNextLineIndent = function(state, line, tab) {
+ return this.$getIndent(line);
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return false;
+ };
+
+ this.getCompletions = function(state, session, pos, prefix) {
+ return this.$completer.getCompletions(state, session, pos, prefix);
+ };
+
+ this.createWorker = function(session) {
+ if (this.constructor != Mode)
+ return;
+ var worker = new WorkerClient(["ace"], "ace/mode/html_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ if (this.fragmentContext)
+ worker.call("setOptions", [{context: this.fragmentContext}]);
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/html";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/velocity_highlight_rules",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text_highlight_rules","ace/mode/html_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var HtmlHighlightRules = require("./html_highlight_rules").HtmlHighlightRules;
+
+var VelocityHighlightRules = function() {
+ HtmlHighlightRules.call(this);
+
+ var builtinConstants = lang.arrayToMap(
+ ('true|false|null').split('|')
+ );
+
+ var builtinFunctions = lang.arrayToMap(
+ ("_DateTool|_DisplayTool|_EscapeTool|_FieldTool|_MathTool|_NumberTool|_SerializerTool|_SortTool|_StringTool|_XPathTool").split('|')
+ );
+
+ var builtinVariables = lang.arrayToMap(
+ ('$contentRoot|$foreach').split('|')
+ );
+
+ var keywords = lang.arrayToMap(
+ ("#set|#macro|#include|#parse|" +
+ "#if|#elseif|#else|#foreach|" +
+ "#break|#end|#stop"
+ ).split('|')
+ );
+
+ this.$rules.start.push(
+ {
+ token : "comment",
+ regex : "##.*$"
+ },{
+ token : "comment.block", // multi line comment
+ regex : "#\\*",
+ next : "vm_comment"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : function(value) {
+ if (keywords.hasOwnProperty(value))
+ return "keyword";
+ else if (builtinConstants.hasOwnProperty(value))
+ return "constant.language";
+ else if (builtinVariables.hasOwnProperty(value))
+ return "variable.language";
+ else if (builtinFunctions.hasOwnProperty(value) || builtinFunctions.hasOwnProperty(value.substring(1)))
+ return "support.function";
+ else if (value == "debugger")
+ return "invalid.deprecated";
+ else
+ if(value.match(/^(\$[a-zA-Z_][a-zA-Z0-9_]*)$/))
+ return "variable";
+ return "identifier";
+ },
+ regex : "[a-zA-Z$#][a-zA-Z0-9_]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|&|\\*|\\-|\\+|=|!=|<=|>=|<|>|&&|\\|\\|"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ );
+
+ this.$rules["vm_comment"] = [
+ {
+ token : "comment", // closing comment
+ regex : "\\*#|-->",
+ next : "start"
+ }, {
+ defaultToken: "comment"
+ }
+ ];
+
+ this.$rules["vm_start"] = [
+ {
+ token: "variable",
+ regex: "}",
+ next: "pop"
+ }, {
+ token : "string.regexp",
+ regex : "[/](?:(?:\\[(?:\\\\]|[^\\]])+\\])|(?:\\\\/|[^\\]/]))*[/]\\w*\\s*(?=[).,;]|$)"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : "0[xX][0-9a-fA-F]+\\b"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : function(value) {
+ if (keywords.hasOwnProperty(value))
+ return "keyword";
+ else if (builtinConstants.hasOwnProperty(value))
+ return "constant.language";
+ else if (builtinVariables.hasOwnProperty(value))
+ return "variable.language";
+ else if (builtinFunctions.hasOwnProperty(value) || builtinFunctions.hasOwnProperty(value.substring(1)))
+ return "support.function";
+ else if (value == "debugger")
+ return "invalid.deprecated";
+ else
+ if(value.match(/^(\$[a-zA-Z_$][a-zA-Z0-9_]*)$/))
+ return "variable";
+ return "identifier";
+ },
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "!|&|\\*|\\-|\\+|=|!=|<=|>=|<|>|&&|\\|\\|"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ];
+
+ for (var i in this.$rules) {
+ this.$rules[i].unshift({
+ token: "variable",
+ regex: "\\${",
+ push: "vm_start"
+ });
+ }
+
+ this.normalizeRules();
+};
+
+oop.inherits(VelocityHighlightRules, TextHighlightRules);
+
+exports.VelocityHighlightRules = VelocityHighlightRules;
+});
+
+ace.define("ace/mode/folding/velocity",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "##")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "##")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "##" && next[indent] == "##") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "##" && prev[indent] == "##") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/velocity",["require","exports","module","ace/lib/oop","ace/mode/html","ace/mode/velocity_highlight_rules","ace/mode/folding/velocity"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var HtmlMode = require("./html").Mode;
+var VelocityHighlightRules = require("./velocity_highlight_rules").VelocityHighlightRules;
+var FoldMode = require("./folding/velocity").FoldMode;
+
+var Mode = function() {
+ HtmlMode.call(this);
+ this.HighlightRules = VelocityHighlightRules;
+ this.foldingRules = new FoldMode();
+};
+oop.inherits(Mode, HtmlMode);
+
+(function() {
+ this.lineCommentStart = "##";
+ this.blockComment = {start: "#*", end: "*#"};
+ this.$id = "ace/mode/velocity";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-verilog.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-verilog.js
new file mode 100644
index 00000000..7def13b9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-verilog.js
@@ -0,0 +1,104 @@
+ace.define("ace/mode/verilog_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var VerilogHighlightRules = function() {
+var keywords = "always|and|assign|automatic|begin|buf|bufif0|bufif1|case|casex|casez|cell|cmos|config|" +
+ "deassign|default|defparam|design|disable|edge|else|end|endcase|endconfig|endfunction|endgenerate|endmodule|" +
+ "endprimitive|endspecify|endtable|endtask|event|for|force|forever|fork|function|generate|genvar|highz0|" +
+ "highz1|if|ifnone|incdir|include|initial|inout|input|instance|integer|join|large|liblist|library|localparam|" +
+ "macromodule|medium|module|nand|negedge|nmos|nor|noshowcancelled|not|notif0|notif1|or|output|parameter|pmos|" +
+ "posedge|primitive|pull0|pull1|pulldown|pullup|pulsestyle_onevent|pulsestyle_ondetect|rcmos|real|realtime|" +
+ "reg|release|repeat|rnmos|rpmos|rtran|rtranif0|rtranif1|scalared|showcancelled|signed|small|specify|specparam|" +
+ "strong0|strong1|supply0|supply1|table|task|time|tran|tranif0|tranif1|tri|tri0|tri1|triand|trior|trireg|" +
+ "unsigned|use|vectored|wait|wand|weak0|weak1|while|wire|wor|xnor|xor" +
+ "begin|bufif0|bufif1|case|casex|casez|config|else|end|endcase|endconfig|endfunction|" +
+ "endgenerate|endmodule|endprimitive|endspecify|endtable|endtask|for|forever|function|generate|if|ifnone|" +
+ "macromodule|module|primitive|repeat|specify|table|task|while";
+
+ var builtinConstants = (
+ "true|false|null"
+ );
+
+ var builtinFunctions = (
+ "count|min|max|avg|sum|rank|now|coalesce|main"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "support.function": builtinFunctions,
+ "keyword": keywords,
+ "constant.language": builtinConstants
+ }, "identifier", true);
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "//.*$"
+ }, {
+ token : "comment.start",
+ regex : "/\\*",
+ next : [
+ { token : "comment.end", regex : "\\*/", next: "start" },
+ { defaultToken : "comment" }
+ ]
+ }, {
+ token : "string", // " string
+ regex : '".*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'.*?'"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|="
+ }, {
+ token : "paren.lparen",
+ regex : "[\\(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\)]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+ };
+ this.normalizeRules();
+};
+
+oop.inherits(VerilogHighlightRules, TextHighlightRules);
+
+exports.VerilogHighlightRules = VerilogHighlightRules;
+});
+
+ace.define("ace/mode/verilog",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/verilog_highlight_rules","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var VerilogHighlightRules = require("./verilog_highlight_rules").VerilogHighlightRules;
+var Range = require("../range").Range;
+
+var Mode = function() {
+ this.HighlightRules = VerilogHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+
+ this.$id = "ace/mode/verilog";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-vhdl.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-vhdl.js
new file mode 100644
index 00000000..41dab579
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-vhdl.js
@@ -0,0 +1,110 @@
+ace.define("ace/mode/vhdl_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var VHDLHighlightRules = function() {
+
+
+
+ var keywords = "access|after|ailas|all|architecture|assert|attribute|"+
+ "begin|block|buffer|bus|case|component|configuration|"+
+ "disconnect|downto|else|elsif|end|entity|file|for|function|"+
+ "generate|generic|guarded|if|impure|in|inertial|inout|is|"+
+ "label|linkage|literal|loop|mapnew|next|of|on|open|"+
+ "others|out|port|process|pure|range|record|reject|"+
+ "report|return|select|shared|subtype|then|to|transport|"+
+ "type|unaffected|united|until|wait|when|while|with";
+
+ var storageType = "bit|bit_vector|boolean|character|integer|line|natural|"+
+ "positive|real|register|severity|signal|signed|"+
+ "std_logic|std_logic_vector|string||text|time|unsigned|"+
+ "variable";
+
+ var storageModifiers = "array|constant";
+
+ var keywordOperators = "abs|and|mod|nand|nor|not|rem|rol|ror|sla|sll|sra"+
+ "srl|xnor|xor";
+
+ var builtinConstants = (
+ "true|false|null"
+ );
+
+
+ var keywordMapper = this.createKeywordMapper({
+ "keyword.operator": keywordOperators,
+ "keyword": keywords,
+ "constant.language": builtinConstants,
+ "storage.modifier": storageModifiers,
+ "storage.type": storageType
+ }, "identifier", true);
+
+ this.$rules = {
+ "start" : [ {
+ token : "comment",
+ regex : "--.*$"
+ }, {
+ token : "string", // " string
+ regex : '".*?"'
+ }, {
+ token : "string", // ' string
+ regex : "'.*?'"
+ }, {
+ token : "constant.numeric", // float
+ regex : "[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"
+ }, {
+ token : "keyword", // pre-compiler directives
+ regex : "\\s*(?:library|package|use)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "&|\\*|\\+|\\-|\\/|<|=|>|\\||=>|\\*\\*|:=|\\/=|>=|<=|<>"
+ }, {
+ token : "punctuation.operator",
+ regex : "\\'|\\:|\\,|\\;|\\."
+ },{
+ token : "paren.lparen",
+ regex : "[[(]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ } ]
+
+
+ };
+};
+
+oop.inherits(VHDLHighlightRules, TextHighlightRules);
+
+exports.VHDLHighlightRules = VHDLHighlightRules;
+});
+
+ace.define("ace/mode/vhdl",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/vhdl_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var VHDLHighlightRules = require("./vhdl_highlight_rules").VHDLHighlightRules;
+
+var Mode = function() {
+ this.HighlightRules = VHDLHighlightRules;
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "--";
+
+ this.$id = "ace/mode/vhdl";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-wollok.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-wollok.js
new file mode 100644
index 00000000..22c64ac2
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-wollok.js
@@ -0,0 +1,905 @@
+ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var DocCommentHighlightRules = function() {
+ this.$rules = {
+ "start" : [ {
+ token : "comment.doc.tag",
+ regex : "@[\\w\\d_]+" // TODO: fix email addresses
+ },
+ DocCommentHighlightRules.getTagRule(),
+ {
+ defaultToken : "comment.doc",
+ caseInsensitive: true
+ }]
+ };
+};
+
+oop.inherits(DocCommentHighlightRules, TextHighlightRules);
+
+DocCommentHighlightRules.getTagRule = function(start) {
+ return {
+ token : "comment.doc.tag.storage.type",
+ regex : "\\b(?:TODO|FIXME|XXX|HACK)\\b"
+ };
+}
+
+DocCommentHighlightRules.getStartRule = function(start) {
+ return {
+ token : "comment.doc", // doc comment
+ regex : "\\/\\*(?=\\*)",
+ next : start
+ };
+};
+
+DocCommentHighlightRules.getEndRule = function (start) {
+ return {
+ token : "comment.doc", // closing comment
+ regex : "\\*\\/",
+ next : start
+ };
+};
+
+
+exports.DocCommentHighlightRules = DocCommentHighlightRules;
+
+});
+
+ace.define("ace/mode/javascript_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var identifierRe = "[a-zA-Z\\$_\u00a1-\uffff][a-zA-Z\\d\\$_\u00a1-\uffff]*";
+
+var JavaScriptHighlightRules = function(options) {
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language":
+ "Array|Boolean|Date|Function|Iterator|Number|Object|RegExp|String|Proxy|" + // Constructors
+ "Namespace|QName|XML|XMLList|" + // E4X
+ "ArrayBuffer|Float32Array|Float64Array|Int16Array|Int32Array|Int8Array|" +
+ "Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray|" +
+ "Error|EvalError|InternalError|RangeError|ReferenceError|StopIteration|" + // Errors
+ "SyntaxError|TypeError|URIError|" +
+ "decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|eval|isFinite|" + // Non-constructor functions
+ "isNaN|parseFloat|parseInt|" +
+ "JSON|Math|" + // Other
+ "this|arguments|prototype|window|document" , // Pseudo
+ "keyword":
+ "const|yield|import|get|set|async|await|" +
+ "break|case|catch|continue|default|delete|do|else|finally|for|function|" +
+ "if|in|of|instanceof|new|return|switch|throw|try|typeof|let|var|while|with|debugger|" +
+ "__parent__|__count__|escape|unescape|with|__proto__|" +
+ "class|enum|extends|super|export|implements|private|public|interface|package|protected|static",
+ "storage.type":
+ "const|let|var|function",
+ "constant.language":
+ "null|Infinity|NaN|undefined",
+ "support.function":
+ "alert",
+ "constant.language.boolean": "true|false"
+ }, "identifier");
+ var kwBeforeRe = "case|do|else|finally|in|instanceof|return|throw|try|typeof|yield|void";
+
+ var escapedRe = "\\\\(?:x[0-9a-fA-F]{2}|" + // hex
+ "u[0-9a-fA-F]{4}|" + // unicode
+ "u{[0-9a-fA-F]{1,6}}|" + // es6 unicode
+ "[0-2][0-7]{0,2}|" + // oct
+ "3[0-7][0-7]?|" + // oct
+ "[4-7][0-7]?|" + //oct
+ ".)";
+
+ this.$rules = {
+ "no_regex" : [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("no_regex"),
+ {
+ token : "string",
+ regex : "'(?=.)",
+ next : "qstring"
+ }, {
+ token : "string",
+ regex : '"(?=.)',
+ next : "qqstring"
+ }, {
+ token : "constant.numeric", // hexadecimal, octal and binary
+ regex : /0(?:[xX][0-9a-fA-F]+|[oO][0-7]+|[bB][01]+)\b/
+ }, {
+ token : "constant.numeric", // decimal integers and floats
+ regex : /(?:\d\d*(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+\b)?/
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "support.function",
+ "punctuation.operator", "entity.name.function", "text","keyword.operator"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(prototype)(\\.)(" + identifierRe +")(\\s*)(=)",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "keyword.operator", "text", "storage.type",
+ "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(\\s+)(\\w+)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(function)(\\s+)(" + identifierRe + ")(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "entity.name.function", "text", "punctuation.operator",
+ "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\s*)(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : [
+ "text", "text", "storage.type", "text", "paren.lparen"
+ ],
+ regex : "(:)(\\s*)(function)(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "keyword",
+ regex : "from(?=\\s*('|\"))"
+ }, {
+ token : "keyword",
+ regex : "(?:" + kwBeforeRe + ")\\b",
+ next : "start"
+ }, {
+ token : ["support.constant"],
+ regex : /that\b/
+ }, {
+ token : ["storage.type", "punctuation.operator", "support.function.firebug"],
+ regex : /(console)(\.)(warn|info|log|error|time|trace|timeEnd|assert)\b/
+ }, {
+ token : keywordMapper,
+ regex : identifierRe
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/,
+ next : "property"
+ }, {
+ token : "storage.type",
+ regex : /=>/
+ }, {
+ token : "keyword.operator",
+ regex : /--|\+\+|\.{3}|===|==|=|!=|!==|<+=?|>+=?|!|&&|\|\||\?:|[!$%&*+\-~\/^]=?/,
+ next : "start"
+ }, {
+ token : "punctuation.operator",
+ regex : /[?:,;.]/,
+ next : "start"
+ }, {
+ token : "paren.lparen",
+ regex : /[\[({]/,
+ next : "start"
+ }, {
+ token : "paren.rparen",
+ regex : /[\])}]/
+ }, {
+ token: "comment",
+ regex: /^#!.*$/
+ }
+ ],
+ property: [{
+ token : "text",
+ regex : "\\s+"
+ }, {
+ token : [
+ "storage.type", "punctuation.operator", "entity.name.function", "text",
+ "keyword.operator", "text",
+ "storage.type", "text", "entity.name.function", "text", "paren.lparen"
+ ],
+ regex : "(" + identifierRe + ")(\\.)(" + identifierRe +")(\\s*)(=)(\\s*)(function)(?:(\\s+)(\\w+))?(\\s*)(\\()",
+ next: "function_arguments"
+ }, {
+ token : "punctuation.operator",
+ regex : /[.](?![.])/
+ }, {
+ token : "support.function",
+ regex : /(s(?:h(?:ift|ow(?:Mod(?:elessDialog|alDialog)|Help))|croll(?:X|By(?:Pages|Lines)?|Y|To)?|t(?:op|rike)|i(?:n|zeToContent|debar|gnText)|ort|u(?:p|b(?:str(?:ing)?)?)|pli(?:ce|t)|e(?:nd|t(?:Re(?:sizable|questHeader)|M(?:i(?:nutes|lliseconds)|onth)|Seconds|Ho(?:tKeys|urs)|Year|Cursor|Time(?:out)?|Interval|ZOptions|Date|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Date|FullYear)|FullYear|Active)|arch)|qrt|lice|avePreferences|mall)|h(?:ome|andleEvent)|navigate|c(?:har(?:CodeAt|At)|o(?:s|n(?:cat|textual|firm)|mpile)|eil|lear(?:Timeout|Interval)?|a(?:ptureEvents|ll)|reate(?:StyleSheet|Popup|EventObject))|t(?:o(?:GMTString|S(?:tring|ource)|U(?:TCString|pperCase)|Lo(?:caleString|werCase))|est|a(?:n|int(?:Enabled)?))|i(?:s(?:NaN|Finite)|ndexOf|talics)|d(?:isableExternalCapture|ump|etachEvent)|u(?:n(?:shift|taint|escape|watch)|pdateCommands)|j(?:oin|avaEnabled)|p(?:o(?:p|w)|ush|lugins.refresh|a(?:ddings|rse(?:Int|Float)?)|r(?:int|ompt|eference))|e(?:scape|nableExternalCapture|val|lementFromPoint|x(?:p|ec(?:Script|Command)?))|valueOf|UTC|queryCommand(?:State|Indeterm|Enabled|Value)|f(?:i(?:nd|le(?:ModifiedDate|Size|CreatedDate|UpdatedDate)|xed)|o(?:nt(?:size|color)|rward)|loor|romCharCode)|watch|l(?:ink|o(?:ad|g)|astIndexOf)|a(?:sin|nchor|cos|t(?:tachEvent|ob|an(?:2)?)|pply|lert|b(?:s|ort))|r(?:ou(?:nd|teEvents)|e(?:size(?:By|To)|calc|turnValue|place|verse|l(?:oad|ease(?:Capture|Events)))|andom)|g(?:o|et(?:ResponseHeader|M(?:i(?:nutes|lliseconds)|onth)|Se(?:conds|lection)|Hours|Year|Time(?:zoneOffset)?|Da(?:y|te)|UTC(?:M(?:i(?:nutes|lliseconds)|onth)|Seconds|Hours|Da(?:y|te)|FullYear)|FullYear|A(?:ttention|llResponseHeaders)))|m(?:in|ove(?:B(?:y|elow)|To(?:Absolute)?|Above)|ergeAttributes|a(?:tch|rgins|x))|b(?:toa|ig|o(?:ld|rderWidths)|link|ack))\b(?=\()/
+ }, {
+ token : "support.function.dom",
+ regex : /(s(?:ub(?:stringData|mit)|plitText|e(?:t(?:NamedItem|Attribute(?:Node)?)|lect))|has(?:ChildNodes|Feature)|namedItem|c(?:l(?:ick|o(?:se|neNode))|reate(?:C(?:omment|DATASection|aption)|T(?:Head|extNode|Foot)|DocumentFragment|ProcessingInstruction|E(?:ntityReference|lement)|Attribute))|tabIndex|i(?:nsert(?:Row|Before|Cell|Data)|tem)|open|delete(?:Row|C(?:ell|aption)|T(?:Head|Foot)|Data)|focus|write(?:ln)?|a(?:dd|ppend(?:Child|Data))|re(?:set|place(?:Child|Data)|move(?:NamedItem|Child|Attribute(?:Node)?)?)|get(?:NamedItem|Element(?:sBy(?:Name|TagName|ClassName)|ById)|Attribute(?:Node)?)|blur)\b(?=\()/
+ }, {
+ token : "support.constant",
+ regex : /(s(?:ystemLanguage|cr(?:ipts|ollbars|een(?:X|Y|Top|Left))|t(?:yle(?:Sheets)?|atus(?:Text|bar)?)|ibling(?:Below|Above)|ource|uffixes|e(?:curity(?:Policy)?|l(?:ection|f)))|h(?:istory|ost(?:name)?|as(?:h|Focus))|y|X(?:MLDocument|SLDocument)|n(?:ext|ame(?:space(?:s|URI)|Prop))|M(?:IN_VALUE|AX_VALUE)|c(?:haracterSet|o(?:n(?:structor|trollers)|okieEnabled|lorDepth|mp(?:onents|lete))|urrent|puClass|l(?:i(?:p(?:boardData)?|entInformation)|osed|asses)|alle(?:e|r)|rypto)|t(?:o(?:olbar|p)|ext(?:Transform|Indent|Decoration|Align)|ags)|SQRT(?:1_2|2)|i(?:n(?:ner(?:Height|Width)|put)|ds|gnoreCase)|zIndex|o(?:scpu|n(?:readystatechange|Line)|uter(?:Height|Width)|p(?:sProfile|ener)|ffscreenBuffering)|NEGATIVE_INFINITY|d(?:i(?:splay|alog(?:Height|Top|Width|Left|Arguments)|rectories)|e(?:scription|fault(?:Status|Ch(?:ecked|arset)|View)))|u(?:ser(?:Profile|Language|Agent)|n(?:iqueID|defined)|pdateInterval)|_content|p(?:ixelDepth|ort|ersonalbar|kcs11|l(?:ugins|atform)|a(?:thname|dding(?:Right|Bottom|Top|Left)|rent(?:Window|Layer)?|ge(?:X(?:Offset)?|Y(?:Offset)?))|r(?:o(?:to(?:col|type)|duct(?:Sub)?|mpter)|e(?:vious|fix)))|e(?:n(?:coding|abledPlugin)|x(?:ternal|pando)|mbeds)|v(?:isibility|endor(?:Sub)?|Linkcolor)|URLUnencoded|P(?:I|OSITIVE_INFINITY)|f(?:ilename|o(?:nt(?:Size|Family|Weight)|rmName)|rame(?:s|Element)|gColor)|E|whiteSpace|l(?:i(?:stStyleType|n(?:eHeight|kColor))|o(?:ca(?:tion(?:bar)?|lName)|wsrc)|e(?:ngth|ft(?:Context)?)|a(?:st(?:M(?:odified|atch)|Index|Paren)|yer(?:s|X)|nguage))|a(?:pp(?:MinorVersion|Name|Co(?:deName|re)|Version)|vail(?:Height|Top|Width|Left)|ll|r(?:ity|guments)|Linkcolor|bove)|r(?:ight(?:Context)?|e(?:sponse(?:XML|Text)|adyState))|global|x|m(?:imeTypes|ultiline|enubar|argin(?:Right|Bottom|Top|Left))|L(?:N(?:10|2)|OG(?:10E|2E))|b(?:o(?:ttom|rder(?:Width|RightWidth|BottomWidth|Style|Color|TopWidth|LeftWidth))|ufferDepth|elow|ackground(?:Color|Image)))\b/
+ }, {
+ token : "identifier",
+ regex : identifierRe
+ }, {
+ regex: "",
+ token: "empty",
+ next: "no_regex"
+ }
+ ],
+ "start": [
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ comments("start"),
+ {
+ token: "string.regexp",
+ regex: "\\/",
+ next: "regex"
+ }, {
+ token : "text",
+ regex : "\\s+|^$",
+ next : "start"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "regex": [
+ {
+ token: "regexp.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "string.regexp",
+ regex: "/[sxngimy]*",
+ next: "no_regex"
+ }, {
+ token : "invalid",
+ regex: /\{\d+\b,?\d*\}[+*]|[+*$^?][+*]|[$^][?]|\?{3,}/
+ }, {
+ token : "constant.language.escape",
+ regex: /\(\?[:=!]|\)|\{\d+\b,?\d*\}|[+*]\?|[()$^+*?.]/
+ }, {
+ token : "constant.language.delimiter",
+ regex: /\|/
+ }, {
+ token: "constant.language.escape",
+ regex: /\[\^?/,
+ next: "regex_character_class"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp"
+ }
+ ],
+ "regex_character_class": [
+ {
+ token: "regexp.charclass.keyword.operator",
+ regex: "\\\\(?:u[\\da-fA-F]{4}|x[\\da-fA-F]{2}|.)"
+ }, {
+ token: "constant.language.escape",
+ regex: "]",
+ next: "regex"
+ }, {
+ token: "constant.language.escape",
+ regex: "-"
+ }, {
+ token: "empty",
+ regex: "$",
+ next: "no_regex"
+ }, {
+ defaultToken: "string.regexp.charachterclass"
+ }
+ ],
+ "function_arguments": [
+ {
+ token: "variable.parameter",
+ regex: identifierRe
+ }, {
+ token: "punctuation.operator",
+ regex: "[, ]+"
+ }, {
+ token: "punctuation.operator",
+ regex: "$"
+ }, {
+ token: "empty",
+ regex: "",
+ next: "no_regex"
+ }
+ ],
+ "qqstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : '"|$',
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ],
+ "qstring" : [
+ {
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "string",
+ regex : "\\\\$",
+ consumeLineEnd : true
+ }, {
+ token : "string",
+ regex : "'|$",
+ next : "no_regex"
+ }, {
+ defaultToken: "string"
+ }
+ ]
+ };
+
+
+ if (!options || !options.noES6) {
+ this.$rules.no_regex.unshift({
+ regex: "[{}]", onMatch: function(val, state, stack) {
+ this.next = val == "{" ? this.nextState : "";
+ if (val == "{" && stack.length) {
+ stack.unshift("start", state);
+ }
+ else if (val == "}" && stack.length) {
+ stack.shift();
+ this.next = stack.shift();
+ if (this.next.indexOf("string") != -1 || this.next.indexOf("jsx") != -1)
+ return "paren.quasi.end";
+ }
+ return val == "{" ? "paren.lparen" : "paren.rparen";
+ },
+ nextState: "start"
+ }, {
+ token : "string.quasi.start",
+ regex : /`/,
+ push : [{
+ token : "constant.language.escape",
+ regex : escapedRe
+ }, {
+ token : "paren.quasi.start",
+ regex : /\${/,
+ push : "start"
+ }, {
+ token : "string.quasi.end",
+ regex : /`/,
+ next : "pop"
+ }, {
+ defaultToken: "string.quasi"
+ }]
+ });
+
+ if (!options || options.jsx != false)
+ JSX.call(this);
+ }
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("no_regex") ]);
+
+ this.normalizeRules();
+};
+
+oop.inherits(JavaScriptHighlightRules, TextHighlightRules);
+
+function JSX() {
+ var tagRegex = identifierRe.replace("\\d", "\\d\\-");
+ var jsxTag = {
+ onMatch : function(val, state, stack) {
+ var offset = val.charAt(1) == "/" ? 2 : 1;
+ if (offset == 1) {
+ if (state != this.nextState)
+ stack.unshift(this.next, this.nextState, 0);
+ else
+ stack.unshift(this.next);
+ stack[2]++;
+ } else if (offset == 2) {
+ if (state == this.nextState) {
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.shift();
+ stack.shift();
+ }
+ }
+ }
+ return [{
+ type: "meta.tag.punctuation." + (offset == 1 ? "" : "end-") + "tag-open.xml",
+ value: val.slice(0, offset)
+ }, {
+ type: "meta.tag.tag-name.xml",
+ value: val.substr(offset)
+ }];
+ },
+ regex : "</?" + tagRegex + "",
+ next: "jsxAttributes",
+ nextState: "jsx"
+ };
+ this.$rules.start.unshift(jsxTag);
+ var jsxJsRule = {
+ regex: "{",
+ token: "paren.quasi.start",
+ push: "start"
+ };
+ this.$rules.jsx = [
+ jsxJsRule,
+ jsxTag,
+ {include : "reference"},
+ {defaultToken: "string"}
+ ];
+ this.$rules.jsxAttributes = [{
+ token : "meta.tag.punctuation.tag-close.xml",
+ regex : "/?>",
+ onMatch : function(value, currentState, stack) {
+ if (currentState == stack[0])
+ stack.shift();
+ if (value.length == 2) {
+ if (stack[0] == this.nextState)
+ stack[1]--;
+ if (!stack[1] || stack[1] < 0) {
+ stack.splice(0, 2);
+ }
+ }
+ this.next = stack[0] || "start";
+ return [{type: this.token, value: value}];
+ },
+ nextState: "jsx"
+ },
+ jsxJsRule,
+ comments("jsxAttributes"),
+ {
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ token : "text.tag-whitespace.xml",
+ regex : "\\s+"
+ }, {
+ token : "string.attribute-value.xml",
+ regex : "'",
+ stateName : "jsx_attr_q",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ stateName : "jsx_attr_qq",
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ },
+ jsxTag
+ ];
+ this.$rules.reference = [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }];
+}
+
+function comments(next) {
+ return [
+ {
+ token : "comment", // multi line comment
+ regex : /\/\*/,
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "\\*\\/", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }, {
+ token : "comment",
+ regex : "\\/\\/",
+ next: [
+ DocCommentHighlightRules.getTagRule(),
+ {token : "comment", regex : "$|^", next : next || "pop"},
+ {defaultToken : "comment", caseInsensitive: true}
+ ]
+ }
+ ];
+}
+exports.JavaScriptHighlightRules = JavaScriptHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/javascript",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/javascript_highlight_rules","ace/mode/matching_brace_outdent","ace/worker/worker_client","ace/mode/behaviour/cstyle","ace/mode/folding/cstyle"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var JavaScriptHighlightRules = require("./javascript_highlight_rules").JavaScriptHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var CstyleBehaviour = require("./behaviour/cstyle").CstyleBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = JavaScriptHighlightRules;
+
+ this.$outdent = new MatchingBraceOutdent();
+ this.$behaviour = new CstyleBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "//";
+ this.blockComment = {start: "/*", end: "*/"};
+ this.$quotes = {'"': '"', "'": "'", "`": "`"};
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ var tokenizedLine = this.getTokenizer().getLineTokens(line, state);
+ var tokens = tokenizedLine.tokens;
+ var endState = tokenizedLine.state;
+
+ if (tokens.length && tokens[tokens.length-1].type == "comment") {
+ return indent;
+ }
+
+ if (state == "start" || state == "no_regex") {
+ var match = line.match(/^.*(?:\bcase\b.*:|[\{\(\[])\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ } else if (state == "doc-start") {
+ if (endState == "start" || endState == "no_regex") {
+ return "";
+ }
+ var match = line.match(/^\s*(\/?)\*/);
+ if (match) {
+ if (match[1]) {
+ indent += " ";
+ }
+ indent += "* ";
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/javascript_worker", "JavaScriptWorker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("annotate", function(results) {
+ session.setAnnotations(results.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/javascript";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
+
+ace.define("ace/mode/wollok_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/doc_comment_highlight_rules","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var DocCommentHighlightRules = require("./doc_comment_highlight_rules").DocCommentHighlightRules;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var WollokHighlightRules = function() {
+ var keywords = (
+ "test|package|inherits|false|import|else|or|class|and|not|native|override|program|this|try|val|var|catch|object|super|throw|if|null|return|true|new|method"
+ );
+
+ var buildinConstants = ("null|assert|console");
+
+
+ var langClasses = (
+ "Object|Pair|String|Boolean|Number|Integer|Double|Collection|Set|List|Exception|Range" +
+ "|StackTraceElement"
+ );
+
+ var keywordMapper = this.createKeywordMapper({
+ "variable.language": "this",
+ "keyword": keywords,
+ "constant.language": buildinConstants,
+ "support.function": langClasses
+ }, "identifier");
+
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "\\/\\/.*$"
+ },
+ DocCommentHighlightRules.getStartRule("doc-start"),
+ {
+ token : "comment", // multi line comment
+ regex : "\\/\\*",
+ next : "comment"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // single line
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // hex
+ regex : /0(?:[xX][0-9a-fA-F][0-9a-fA-F_]*|[bB][01][01_]*)[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.numeric", // float
+ regex : /[+-]?\d[\d_]*(?:(?:\.[\d_]*)?(?:[eE][+-]?[\d_]+)?)?[LlSsDdFfYy]?\b/
+ }, {
+ token : "constant.language.boolean",
+ regex : "(?:true|false)\\b"
+ }, {
+ token : keywordMapper,
+ regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b"
+ }, {
+ token : "keyword.operator",
+ regex : "===|&&|\\*=|\\.\\.|\\*\\*|#|!|%|\\*|\\?:|\\+|\\/|,|\\+=|\\-|\\.\\.<|!==|:|\\/=|\\?\\.|\\+\\+|>|=|<|>=|=>|==|\\]|\\[|\\-=|\\->|\\||\\-\\-|<>|!=|%=|\\|"
+ }, {
+ token : "lparen",
+ regex : "[[({]"
+ }, {
+ token : "rparen",
+ regex : "[\\])}]"
+ }, {
+ token : "text",
+ regex : "\\s+"
+ }
+ ],
+ "comment" : [
+ {
+ token : "comment", // closing comment
+ regex : ".*?\\*\\/",
+ next : "start"
+ }, {
+ token : "comment", // comment spanning whole line
+ regex : ".+"
+ }
+ ]
+ };
+
+ this.embedRules(DocCommentHighlightRules, "doc-",
+ [ DocCommentHighlightRules.getEndRule("start") ]);
+};
+
+oop.inherits(WollokHighlightRules, TextHighlightRules);
+
+exports.WollokHighlightRules = WollokHighlightRules;
+});
+
+ace.define("ace/mode/wollok",["require","exports","module","ace/lib/oop","ace/mode/javascript","ace/mode/wollok_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var JavaScriptMode = require("./javascript").Mode;
+var WollokHighlightRules = require("./wollok_highlight_rules").WollokHighlightRules;
+
+var Mode = function() {
+ JavaScriptMode.call(this);
+ this.HighlightRules = WollokHighlightRules;
+};
+oop.inherits(Mode, JavaScriptMode);
+
+(function() {
+
+ this.createWorker = function(session) {
+ return null;
+ };
+
+ this.$id = "ace/mode/wollok";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-xml.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-xml.js
new file mode 100644
index 00000000..f5f840a9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-xml.js
@@ -0,0 +1,664 @@
+ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var XmlHighlightRules = function(normalize) {
+ var tagRegex = "[_:a-zA-Z\xc0-\uffff][-_:.a-zA-Z0-9\xc0-\uffff]*";
+
+ this.$rules = {
+ start : [
+ {token : "string.cdata.xml", regex : "<\\!\\[CDATA\\[", next : "cdata"},
+ {
+ token : ["punctuation.instruction.xml", "keyword.instruction.xml"],
+ regex : "(<\\?)(" + tagRegex + ")", next : "processing_instruction"
+ },
+ {token : "comment.start.xml", regex : "<\\!--", next : "comment"},
+ {
+ token : ["xml-pe.doctype.xml", "xml-pe.doctype.xml"],
+ regex : "(<\\!)(DOCTYPE)(?=[\\s])", next : "doctype", caseInsensitive: true
+ },
+ {include : "tag"},
+ {token : "text.end-tag-open.xml", regex: "</"},
+ {token : "text.tag-open.xml", regex: "<"},
+ {include : "reference"},
+ {defaultToken : "text.xml"}
+ ],
+
+ processing_instruction : [{
+ token : "entity.other.attribute-name.decl-attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.decl-attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "whitespace"
+ }, {
+ include: "string"
+ }, {
+ token : "punctuation.xml-decl.xml",
+ regex : "\\?>",
+ next : "start"
+ }],
+
+ doctype : [
+ {include : "whitespace"},
+ {include : "string"},
+ {token : "xml-pe.doctype.xml", regex : ">", next : "start"},
+ {token : "xml-pe.xml", regex : "[-_a-zA-Z0-9:]+"},
+ {token : "punctuation.int-subset", regex : "\\[", push : "int_subset"}
+ ],
+
+ int_subset : [{
+ token : "text.xml",
+ regex : "\\s+"
+ }, {
+ token: "punctuation.int-subset.xml",
+ regex: "]",
+ next: "pop"
+ }, {
+ token : ["punctuation.markup-decl.xml", "keyword.markup-decl.xml"],
+ regex : "(<\\!)(" + tagRegex + ")",
+ push : [{
+ token : "text",
+ regex : "\\s+"
+ },
+ {
+ token : "punctuation.markup-decl.xml",
+ regex : ">",
+ next : "pop"
+ },
+ {include : "string"}]
+ }],
+
+ cdata : [
+ {token : "string.cdata.xml", regex : "\\]\\]>", next : "start"},
+ {token : "text.xml", regex : "\\s+"},
+ {token : "text.xml", regex : "(?:[^\\]]|\\](?!\\]>))+"}
+ ],
+
+ comment : [
+ {token : "comment.end.xml", regex : "-->", next : "start"},
+ {defaultToken : "comment.xml"}
+ ],
+
+ reference : [{
+ token : "constant.language.escape.reference.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ attr_reference : [{
+ token : "constant.language.escape.reference.attribute-value.xml",
+ regex : "(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"
+ }],
+
+ tag : [{
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag.punctuation.end-tag-open.xml", "meta.tag.tag-name.xml"],
+ regex : "(?:(<)|(</))((?:" + tagRegex + ":)?" + tagRegex + ")",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : "start"}
+ ]
+ }],
+
+ tag_whitespace : [
+ {token : "text.tag-whitespace.xml", regex : "\\s+"}
+ ],
+ whitespace : [
+ {token : "text.whitespace.xml", regex : "\\s+"}
+ ],
+ string: [{
+ token : "string.xml",
+ regex : "'",
+ push : [
+ {token : "string.xml", regex: "'", next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }, {
+ token : "string.xml",
+ regex : '"',
+ push : [
+ {token : "string.xml", regex: '"', next: "pop"},
+ {defaultToken : "string.xml"}
+ ]
+ }],
+
+ attributes: [{
+ token : "entity.other.attribute-name.xml",
+ regex : tagRegex
+ }, {
+ token : "keyword.operator.attribute-equals.xml",
+ regex : "="
+ }, {
+ include: "tag_whitespace"
+ }, {
+ include: "attribute_value"
+ }],
+
+ attribute_value: [{
+ token : "string.attribute-value.xml",
+ regex : "'",
+ push : [
+ {token : "string.attribute-value.xml", regex: "'", next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }, {
+ token : "string.attribute-value.xml",
+ regex : '"',
+ push : [
+ {token : "string.attribute-value.xml", regex: '"', next: "pop"},
+ {include : "attr_reference"},
+ {defaultToken : "string.attribute-value.xml"}
+ ]
+ }]
+ };
+
+ if (this.constructor === XmlHighlightRules)
+ this.normalizeRules();
+};
+
+
+(function() {
+
+ this.embedTagRules = function(HighlightRules, prefix, tag){
+ this.$rules.tag.unshift({
+ token : ["meta.tag.punctuation.tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(<)(" + tag + "(?=\\s|>|$))",
+ next: [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next : prefix + "start"}
+ ]
+ });
+
+ this.$rules[tag + "-end"] = [
+ {include : "attributes"},
+ {token : "meta.tag.punctuation.tag-close.xml", regex : "/?>", next: "start",
+ onMatch : function(value, currentState, stack) {
+ stack.splice(0);
+ return this.token;
+ }}
+ ]
+
+ this.embedRules(HighlightRules, prefix, [{
+ token: ["meta.tag.punctuation.end-tag-open.xml", "meta.tag." + tag + ".tag-name.xml"],
+ regex : "(</)(" + tag + "(?=\\s|>|$))",
+ next: tag + "-end"
+ }, {
+ token: "string.cdata.xml",
+ regex : "<\\!\\[CDATA\\["
+ }, {
+ token: "string.cdata.xml",
+ regex : "\\]\\]>"
+ }]);
+ };
+
+}).call(TextHighlightRules.prototype);
+
+oop.inherits(XmlHighlightRules, TextHighlightRules);
+
+exports.XmlHighlightRules = XmlHighlightRules;
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/range","ace/mode/folding/fold_mode","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var lang = require("../../lib/lang");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+
+var FoldMode = exports.FoldMode = function(voidElements, optionalEndTags) {
+ BaseFoldMode.call(this);
+ this.voidElements = voidElements || {};
+ this.optionalEndTags = oop.mixin({}, this.voidElements);
+ if (optionalEndTags)
+ oop.mixin(this.optionalEndTags, optionalEndTags);
+
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+var Tag = function() {
+ this.tagName = "";
+ this.closing = false;
+ this.selfClosing = false;
+ this.start = {row: 0, column: 0};
+ this.end = {row: 0, column: 0};
+};
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+(function() {
+
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var tag = this._getFirstTagInLine(session, row);
+
+ if (!tag)
+ return this.getCommentFoldWidget(session, row);
+
+ if (tag.closing || (!tag.tagName && tag.selfClosing))
+ return foldStyle == "markbeginend" ? "end" : "";
+
+ if (!tag.tagName || tag.selfClosing || this.voidElements.hasOwnProperty(tag.tagName.toLowerCase()))
+ return "";
+
+ if (this._findEndTagInLine(session, row, tag.tagName, tag.end.column))
+ return "";
+
+ return "start";
+ };
+
+ this.getCommentFoldWidget = function(session, row) {
+ if (/comment/.test(session.getState(row)) && /<!-/.test(session.getLine(row)))
+ return "start";
+ return "";
+ }
+ this._getFirstTagInLine = function(session, row) {
+ var tokens = session.getTokens(row);
+ var tag = new Tag();
+
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (is(token, "tag-open")) {
+ tag.end.column = tag.start.column + token.value.length;
+ tag.closing = is(token, "end-tag-open");
+ token = tokens[++i];
+ if (!token)
+ return null;
+ tag.tagName = token.value;
+ tag.end.column += token.value.length;
+ for (i++; i < tokens.length; i++) {
+ token = tokens[i];
+ tag.end.column += token.value.length;
+ if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ break;
+ }
+ }
+ return tag;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == '/>';
+ return tag;
+ }
+ tag.start.column += token.value.length;
+ }
+
+ return null;
+ };
+
+ this._findEndTagInLine = function(session, row, tagName, startColumn) {
+ var tokens = session.getTokens(row);
+ var column = 0;
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ column += token.value.length;
+ if (column < startColumn)
+ continue;
+ if (is(token, "end-tag-open")) {
+ token = tokens[i + 1];
+ if (token && token.value == tagName)
+ return true;
+ }
+ }
+ return false;
+ };
+ this._readTagForward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ iterator.stepForward();
+ return tag;
+ }
+ } while(token = iterator.stepForward());
+
+ return null;
+ };
+
+ this._readTagBackward = function(iterator) {
+ var token = iterator.getCurrentToken();
+ if (!token)
+ return null;
+
+ var tag = new Tag();
+ do {
+ if (is(token, "tag-open")) {
+ tag.closing = is(token, "end-tag-open");
+ tag.start.row = iterator.getCurrentTokenRow();
+ tag.start.column = iterator.getCurrentTokenColumn();
+ iterator.stepBackward();
+ return tag;
+ } else if (is(token, "tag-name")) {
+ tag.tagName = token.value;
+ } else if (is(token, "tag-close")) {
+ tag.selfClosing = token.value == "/>";
+ tag.end.row = iterator.getCurrentTokenRow();
+ tag.end.column = iterator.getCurrentTokenColumn() + token.value.length;
+ }
+ } while(token = iterator.stepBackward());
+
+ return null;
+ };
+
+ this._pop = function(stack, tag) {
+ while (stack.length) {
+
+ var top = stack[stack.length-1];
+ if (!tag || top.tagName == tag.tagName) {
+ return stack.pop();
+ }
+ else if (this.optionalEndTags.hasOwnProperty(top.tagName)) {
+ stack.pop();
+ continue;
+ } else {
+ return null;
+ }
+ }
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var firstTag = this._getFirstTagInLine(session, row);
+
+ if (!firstTag) {
+ return this.getCommentFoldWidget(session, row)
+ && session.getCommentFoldRange(row, session.getLine(row).length);
+ }
+
+ var isBackward = firstTag.closing || firstTag.selfClosing;
+ var stack = [];
+ var tag;
+
+ if (!isBackward) {
+ var iterator = new TokenIterator(session, row, firstTag.start.column);
+ var start = {
+ row: row,
+ column: firstTag.start.column + firstTag.tagName.length + 2
+ };
+ if (firstTag.start.row == firstTag.end.row)
+ start.column = firstTag.end.column;
+ while (tag = this._readTagForward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0)
+ return Range.fromPoints(start, tag.start);
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+ else {
+ var iterator = new TokenIterator(session, row, firstTag.end.column);
+ var end = {
+ row: row,
+ column: firstTag.start.column
+ };
+
+ while (tag = this._readTagBackward(iterator)) {
+ if (tag.selfClosing) {
+ if (!stack.length) {
+ tag.start.column += tag.tagName.length + 2;
+ tag.end.column -= 2;
+ return Range.fromPoints(tag.start, tag.end);
+ } else
+ continue;
+ }
+
+ if (!tag.closing) {
+ this._pop(stack, tag);
+ if (stack.length == 0) {
+ tag.start.column += tag.tagName.length + 2;
+ if (tag.start.row == tag.end.row && tag.start.column < tag.end.column)
+ tag.start.column = tag.end.column;
+ return Range.fromPoints(tag.start, end);
+ }
+ }
+ else {
+ stack.push(tag);
+ }
+ }
+ }
+
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/xml_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/xml","ace/worker/worker_client"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var TextMode = require("./text").Mode;
+var XmlHighlightRules = require("./xml_highlight_rules").XmlHighlightRules;
+var XmlBehaviour = require("./behaviour/xml").XmlBehaviour;
+var XmlFoldMode = require("./folding/xml").FoldMode;
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+
+var Mode = function() {
+ this.HighlightRules = XmlHighlightRules;
+ this.$behaviour = new XmlBehaviour();
+ this.foldingRules = new XmlFoldMode();
+};
+
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.voidElements = lang.arrayToMap([]);
+
+ this.blockComment = {start: "<!--", end: "-->"};
+
+ this.createWorker = function(session) {
+ var worker = new WorkerClient(["ace"], "ace/mode/xml_worker", "Worker");
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("error", function(e) {
+ session.setAnnotations(e.data);
+ });
+
+ worker.on("terminate", function() {
+ session.clearAnnotations();
+ });
+
+ return worker;
+ };
+
+ this.$id = "ace/mode/xml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-xquery.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-xquery.js
new file mode 100644
index 00000000..3de4ec09
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-xquery.js
@@ -0,0 +1,2631 @@
+ace.define("ace/mode/xquery/xquery_lexer",["require","exports","module"], function(require, exports, module) {
+module.exports = (function outer (modules, cache, entry) {
+ var previousRequire = typeof require == "function" && require;
+ function newRequire(name, jumped){
+ if(!cache[name]) {
+ if(!modules[name]) {
+ var currentRequire = typeof require == "function" && require;
+ if (!jumped && currentRequire) return currentRequire(name, true);
+ if (previousRequire) return previousRequire(name, true);
+ var err = new Error('Cannot find module \'' + name + '\'');
+ err.code = 'MODULE_NOT_FOUND';
+ throw err;
+ }
+ var m = cache[name] = {exports:{}};
+ modules[name][0].call(m.exports, function(x){
+ var id = modules[name][1][x];
+ return newRequire(id ? id : x);
+ },m,m.exports,outer,modules,cache,entry);
+ }
+ return cache[name].exports;
+ }
+ for(var i=0;i<entry.length;i++) newRequire(entry[i]);
+ return newRequire(entry[0]);
+})
+({"/node_modules/xqlint/lib/lexers/XQueryTokenizer.js":[function(_dereq_,module,exports){
+ var XQueryTokenizer = exports.XQueryTokenizer = function XQueryTokenizer(string, parsingEventHandler)
+ {
+ init(string, parsingEventHandler);
+ var self = this;
+
+ this.ParseException = function(b, e, s, o, x)
+ {
+ var
+ begin = b,
+ end = e,
+ state = s,
+ offending = o,
+ expected = x;
+
+ this.getBegin = function() {return begin;};
+ this.getEnd = function() {return end;};
+ this.getState = function() {return state;};
+ this.getExpected = function() {return expected;};
+ this.getOffending = function() {return offending;};
+
+ this.getMessage = function()
+ {
+ return offending < 0 ? "lexical analysis failed" : "syntax error";
+ };
+ };
+
+ function init(string, parsingEventHandler)
+ {
+ eventHandler = parsingEventHandler;
+ input = string;
+ size = string.length;
+ reset(0, 0, 0);
+ }
+
+ this.getInput = function()
+ {
+ return input;
+ };
+
+ function reset(l, b, e)
+ {
+ b0 = b; e0 = b;
+ l1 = l; b1 = b; e1 = e;
+ end = e;
+ eventHandler.reset(input);
+ }
+
+ this.getOffendingToken = function(e)
+ {
+ var o = e.getOffending();
+ return o >= 0 ? XQueryTokenizer.TOKEN[o] : null;
+ };
+
+ this.getExpectedTokenSet = function(e)
+ {
+ var expected;
+ if (e.getExpected() < 0)
+ {
+ expected = XQueryTokenizer.getTokenSet(- e.getState());
+ }
+ else
+ {
+ expected = [XQueryTokenizer.TOKEN[e.getExpected()]];
+ }
+ return expected;
+ };
+
+ this.getErrorMessage = function(e)
+ {
+ var tokenSet = this.getExpectedTokenSet(e);
+ var found = this.getOffendingToken(e);
+ var prefix = input.substring(0, e.getBegin());
+ var lines = prefix.split("\n");
+ var line = lines.length;
+ var column = lines[line - 1].length + 1;
+ var size = e.getEnd() - e.getBegin();
+ return e.getMessage()
+ + (found == null ? "" : ", found " + found)
+ + "\nwhile expecting "
+ + (tokenSet.length == 1 ? tokenSet[0] : ("[" + tokenSet.join(", ") + "]"))
+ + "\n"
+ + (size == 0 || found != null ? "" : "after successfully scanning " + size + " characters beginning ")
+ + "at line " + line + ", column " + column + ":\n..."
+ + input.substring(e.getBegin(), Math.min(input.length, e.getBegin() + 64))
+ + "...";
+ };
+
+ this.parse_start = function()
+ {
+ eventHandler.startNonterminal("start", e0);
+ lookahead1W(14); // ModuleDecl | Annotation | OptionDecl | Operator | Variable | Tag | AttrTest |
+ switch (l1)
+ {
+ case 55: // '<![CDATA['
+ shift(55); // '<![CDATA['
+ break;
+ case 54: // '<!--'
+ shift(54); // '<!--'
+ break;
+ case 56: // '<?'
+ shift(56); // '<?'
+ break;
+ case 40: // '(#'
+ shift(40); // '(#'
+ break;
+ case 42: // '(:~'
+ shift(42); // '(:~'
+ break;
+ case 41: // '(:'
+ shift(41); // '(:'
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ case 274: // '}'
+ shift(274); // '}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ case 39: // '('
+ shift(39); // '('
+ break;
+ case 43: // ')'
+ shift(43); // ')'
+ break;
+ case 49: // '/'
+ shift(49); // '/'
+ break;
+ case 62: // '['
+ shift(62); // '['
+ break;
+ case 63: // ']'
+ shift(63); // ']'
+ break;
+ case 46: // ','
+ shift(46); // ','
+ break;
+ case 48: // '.'
+ shift(48); // '.'
+ break;
+ case 53: // ';'
+ shift(53); // ';'
+ break;
+ case 51: // ':'
+ shift(51); // ':'
+ break;
+ case 34: // '!'
+ shift(34); // '!'
+ break;
+ case 273: // '|'
+ shift(273); // '|'
+ break;
+ case 2: // Annotation
+ shift(2); // Annotation
+ break;
+ case 1: // ModuleDecl
+ shift(1); // ModuleDecl
+ break;
+ case 3: // OptionDecl
+ shift(3); // OptionDecl
+ break;
+ case 12: // AttrTest
+ shift(12); // AttrTest
+ break;
+ case 13: // Wildcard
+ shift(13); // Wildcard
+ break;
+ case 15: // IntegerLiteral
+ shift(15); // IntegerLiteral
+ break;
+ case 16: // DecimalLiteral
+ shift(16); // DecimalLiteral
+ break;
+ case 17: // DoubleLiteral
+ shift(17); // DoubleLiteral
+ break;
+ case 5: // Variable
+ shift(5); // Variable
+ break;
+ case 6: // Tag
+ shift(6); // Tag
+ break;
+ case 4: // Operator
+ shift(4); // Operator
+ break;
+ case 33: // EOF
+ shift(33); // EOF
+ break;
+ default:
+ parse_EQName();
+ }
+ eventHandler.endNonterminal("start", e0);
+ };
+
+ this.parse_StartTag = function()
+ {
+ eventHandler.startNonterminal("StartTag", e0);
+ lookahead1W(8); // QName | S^WS | EOF | '"' | "'" | '/>' | '=' | '>'
+ switch (l1)
+ {
+ case 58: // '>'
+ shift(58); // '>'
+ break;
+ case 50: // '/>'
+ shift(50); // '/>'
+ break;
+ case 27: // QName
+ shift(27); // QName
+ break;
+ case 57: // '='
+ shift(57); // '='
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("StartTag", e0);
+ };
+
+ this.parse_TagContent = function()
+ {
+ eventHandler.startNonterminal("TagContent", e0);
+ lookahead1(11); // Tag | EndTag | PredefinedEntityRef | ElementContentChar | CharRef | EOF |
+ switch (l1)
+ {
+ case 23: // ElementContentChar
+ shift(23); // ElementContentChar
+ break;
+ case 6: // Tag
+ shift(6); // Tag
+ break;
+ case 7: // EndTag
+ shift(7); // EndTag
+ break;
+ case 55: // '<![CDATA['
+ shift(55); // '<![CDATA['
+ break;
+ case 54: // '<!--'
+ shift(54); // '<!--'
+ break;
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 272: // '{{'
+ shift(272); // '{{'
+ break;
+ case 275: // '}}'
+ shift(275); // '}}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("TagContent", e0);
+ };
+
+ this.parse_AposAttr = function()
+ {
+ eventHandler.startNonterminal("AposAttr", e0);
+ lookahead1(10); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | EOF | "'" |
+ switch (l1)
+ {
+ case 20: // EscapeApos
+ shift(20); // EscapeApos
+ break;
+ case 25: // AposAttrContentChar
+ shift(25); // AposAttrContentChar
+ break;
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 272: // '{{'
+ shift(272); // '{{'
+ break;
+ case 275: // '}}'
+ shift(275); // '}}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("AposAttr", e0);
+ };
+
+ this.parse_QuotAttr = function()
+ {
+ eventHandler.startNonterminal("QuotAttr", e0);
+ lookahead1(9); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | EOF | '"' |
+ switch (l1)
+ {
+ case 19: // EscapeQuot
+ shift(19); // EscapeQuot
+ break;
+ case 24: // QuotAttrContentChar
+ shift(24); // QuotAttrContentChar
+ break;
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 272: // '{{'
+ shift(272); // '{{'
+ break;
+ case 275: // '}}'
+ shift(275); // '}}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("QuotAttr", e0);
+ };
+
+ this.parse_CData = function()
+ {
+ eventHandler.startNonterminal("CData", e0);
+ lookahead1(1); // CDataSectionContents | EOF | ']]>'
+ switch (l1)
+ {
+ case 11: // CDataSectionContents
+ shift(11); // CDataSectionContents
+ break;
+ case 64: // ']]>'
+ shift(64); // ']]>'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("CData", e0);
+ };
+
+ this.parse_XMLComment = function()
+ {
+ eventHandler.startNonterminal("XMLComment", e0);
+ lookahead1(0); // DirCommentContents | EOF | '-->'
+ switch (l1)
+ {
+ case 9: // DirCommentContents
+ shift(9); // DirCommentContents
+ break;
+ case 47: // '-->'
+ shift(47); // '-->'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("XMLComment", e0);
+ };
+
+ this.parse_PI = function()
+ {
+ eventHandler.startNonterminal("PI", e0);
+ lookahead1(3); // DirPIContents | EOF | '?' | '?>'
+ switch (l1)
+ {
+ case 10: // DirPIContents
+ shift(10); // DirPIContents
+ break;
+ case 59: // '?'
+ shift(59); // '?'
+ break;
+ case 60: // '?>'
+ shift(60); // '?>'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("PI", e0);
+ };
+
+ this.parse_Pragma = function()
+ {
+ eventHandler.startNonterminal("Pragma", e0);
+ lookahead1(2); // PragmaContents | EOF | '#' | '#)'
+ switch (l1)
+ {
+ case 8: // PragmaContents
+ shift(8); // PragmaContents
+ break;
+ case 36: // '#'
+ shift(36); // '#'
+ break;
+ case 37: // '#)'
+ shift(37); // '#)'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("Pragma", e0);
+ };
+
+ this.parse_Comment = function()
+ {
+ eventHandler.startNonterminal("Comment", e0);
+ lookahead1(4); // CommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 52: // ':)'
+ shift(52); // ':)'
+ break;
+ case 41: // '(:'
+ shift(41); // '(:'
+ break;
+ case 30: // CommentContents
+ shift(30); // CommentContents
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("Comment", e0);
+ };
+
+ this.parse_CommentDoc = function()
+ {
+ eventHandler.startNonterminal("CommentDoc", e0);
+ lookahead1(5); // DocTag | DocCommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 31: // DocTag
+ shift(31); // DocTag
+ break;
+ case 32: // DocCommentContents
+ shift(32); // DocCommentContents
+ break;
+ case 52: // ':)'
+ shift(52); // ':)'
+ break;
+ case 41: // '(:'
+ shift(41); // '(:'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("CommentDoc", e0);
+ };
+
+ this.parse_QuotString = function()
+ {
+ eventHandler.startNonterminal("QuotString", e0);
+ lookahead1(6); // PredefinedEntityRef | EscapeQuot | QuotChar | CharRef | EOF | '"'
+ switch (l1)
+ {
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 19: // EscapeQuot
+ shift(19); // EscapeQuot
+ break;
+ case 21: // QuotChar
+ shift(21); // QuotChar
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("QuotString", e0);
+ };
+
+ this.parse_AposString = function()
+ {
+ eventHandler.startNonterminal("AposString", e0);
+ lookahead1(7); // PredefinedEntityRef | EscapeApos | AposChar | CharRef | EOF | "'"
+ switch (l1)
+ {
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 20: // EscapeApos
+ shift(20); // EscapeApos
+ break;
+ case 22: // AposChar
+ shift(22); // AposChar
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("AposString", e0);
+ };
+
+ this.parse_Prefix = function()
+ {
+ eventHandler.startNonterminal("Prefix", e0);
+ lookahead1W(13); // NCName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_NCName();
+ eventHandler.endNonterminal("Prefix", e0);
+ };
+
+ this.parse__EQName = function()
+ {
+ eventHandler.startNonterminal("_EQName", e0);
+ lookahead1W(12); // EQName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_EQName();
+ eventHandler.endNonterminal("_EQName", e0);
+ };
+
+ function parse_EQName()
+ {
+ eventHandler.startNonterminal("EQName", e0);
+ switch (l1)
+ {
+ case 77: // 'attribute'
+ shift(77); // 'attribute'
+ break;
+ case 91: // 'comment'
+ shift(91); // 'comment'
+ break;
+ case 115: // 'document-node'
+ shift(115); // 'document-node'
+ break;
+ case 116: // 'element'
+ shift(116); // 'element'
+ break;
+ case 119: // 'empty-sequence'
+ shift(119); // 'empty-sequence'
+ break;
+ case 140: // 'function'
+ shift(140); // 'function'
+ break;
+ case 147: // 'if'
+ shift(147); // 'if'
+ break;
+ case 160: // 'item'
+ shift(160); // 'item'
+ break;
+ case 180: // 'namespace-node'
+ shift(180); // 'namespace-node'
+ break;
+ case 186: // 'node'
+ shift(186); // 'node'
+ break;
+ case 211: // 'processing-instruction'
+ shift(211); // 'processing-instruction'
+ break;
+ case 221: // 'schema-attribute'
+ shift(221); // 'schema-attribute'
+ break;
+ case 222: // 'schema-element'
+ shift(222); // 'schema-element'
+ break;
+ case 238: // 'switch'
+ shift(238); // 'switch'
+ break;
+ case 239: // 'text'
+ shift(239); // 'text'
+ break;
+ case 248: // 'typeswitch'
+ shift(248); // 'typeswitch'
+ break;
+ default:
+ parse_FunctionName();
+ }
+ eventHandler.endNonterminal("EQName", e0);
+ }
+
+ function parse_FunctionName()
+ {
+ eventHandler.startNonterminal("FunctionName", e0);
+ switch (l1)
+ {
+ case 14: // EQName^Token
+ shift(14); // EQName^Token
+ break;
+ case 65: // 'after'
+ shift(65); // 'after'
+ break;
+ case 68: // 'ancestor'
+ shift(68); // 'ancestor'
+ break;
+ case 69: // 'ancestor-or-self'
+ shift(69); // 'ancestor-or-self'
+ break;
+ case 70: // 'and'
+ shift(70); // 'and'
+ break;
+ case 74: // 'as'
+ shift(74); // 'as'
+ break;
+ case 75: // 'ascending'
+ shift(75); // 'ascending'
+ break;
+ case 79: // 'before'
+ shift(79); // 'before'
+ break;
+ case 83: // 'case'
+ shift(83); // 'case'
+ break;
+ case 84: // 'cast'
+ shift(84); // 'cast'
+ break;
+ case 85: // 'castable'
+ shift(85); // 'castable'
+ break;
+ case 88: // 'child'
+ shift(88); // 'child'
+ break;
+ case 89: // 'collation'
+ shift(89); // 'collation'
+ break;
+ case 98: // 'copy'
+ shift(98); // 'copy'
+ break;
+ case 100: // 'count'
+ shift(100); // 'count'
+ break;
+ case 103: // 'declare'
+ shift(103); // 'declare'
+ break;
+ case 104: // 'default'
+ shift(104); // 'default'
+ break;
+ case 105: // 'delete'
+ shift(105); // 'delete'
+ break;
+ case 106: // 'descendant'
+ shift(106); // 'descendant'
+ break;
+ case 107: // 'descendant-or-self'
+ shift(107); // 'descendant-or-self'
+ break;
+ case 108: // 'descending'
+ shift(108); // 'descending'
+ break;
+ case 113: // 'div'
+ shift(113); // 'div'
+ break;
+ case 114: // 'document'
+ shift(114); // 'document'
+ break;
+ case 117: // 'else'
+ shift(117); // 'else'
+ break;
+ case 118: // 'empty'
+ shift(118); // 'empty'
+ break;
+ case 121: // 'end'
+ shift(121); // 'end'
+ break;
+ case 123: // 'eq'
+ shift(123); // 'eq'
+ break;
+ case 124: // 'every'
+ shift(124); // 'every'
+ break;
+ case 126: // 'except'
+ shift(126); // 'except'
+ break;
+ case 129: // 'first'
+ shift(129); // 'first'
+ break;
+ case 130: // 'following'
+ shift(130); // 'following'
+ break;
+ case 131: // 'following-sibling'
+ shift(131); // 'following-sibling'
+ break;
+ case 132: // 'for'
+ shift(132); // 'for'
+ break;
+ case 141: // 'ge'
+ shift(141); // 'ge'
+ break;
+ case 143: // 'group'
+ shift(143); // 'group'
+ break;
+ case 145: // 'gt'
+ shift(145); // 'gt'
+ break;
+ case 146: // 'idiv'
+ shift(146); // 'idiv'
+ break;
+ case 148: // 'import'
+ shift(148); // 'import'
+ break;
+ case 154: // 'insert'
+ shift(154); // 'insert'
+ break;
+ case 155: // 'instance'
+ shift(155); // 'instance'
+ break;
+ case 157: // 'intersect'
+ shift(157); // 'intersect'
+ break;
+ case 158: // 'into'
+ shift(158); // 'into'
+ break;
+ case 159: // 'is'
+ shift(159); // 'is'
+ break;
+ case 165: // 'last'
+ shift(165); // 'last'
+ break;
+ case 167: // 'le'
+ shift(167); // 'le'
+ break;
+ case 169: // 'let'
+ shift(169); // 'let'
+ break;
+ case 173: // 'lt'
+ shift(173); // 'lt'
+ break;
+ case 175: // 'mod'
+ shift(175); // 'mod'
+ break;
+ case 176: // 'modify'
+ shift(176); // 'modify'
+ break;
+ case 177: // 'module'
+ shift(177); // 'module'
+ break;
+ case 179: // 'namespace'
+ shift(179); // 'namespace'
+ break;
+ case 181: // 'ne'
+ shift(181); // 'ne'
+ break;
+ case 193: // 'only'
+ shift(193); // 'only'
+ break;
+ case 195: // 'or'
+ shift(195); // 'or'
+ break;
+ case 196: // 'order'
+ shift(196); // 'order'
+ break;
+ case 197: // 'ordered'
+ shift(197); // 'ordered'
+ break;
+ case 201: // 'parent'
+ shift(201); // 'parent'
+ break;
+ case 207: // 'preceding'
+ shift(207); // 'preceding'
+ break;
+ case 208: // 'preceding-sibling'
+ shift(208); // 'preceding-sibling'
+ break;
+ case 213: // 'rename'
+ shift(213); // 'rename'
+ break;
+ case 214: // 'replace'
+ shift(214); // 'replace'
+ break;
+ case 215: // 'return'
+ shift(215); // 'return'
+ break;
+ case 219: // 'satisfies'
+ shift(219); // 'satisfies'
+ break;
+ case 224: // 'self'
+ shift(224); // 'self'
+ break;
+ case 230: // 'some'
+ shift(230); // 'some'
+ break;
+ case 231: // 'stable'
+ shift(231); // 'stable'
+ break;
+ case 232: // 'start'
+ shift(232); // 'start'
+ break;
+ case 243: // 'to'
+ shift(243); // 'to'
+ break;
+ case 244: // 'treat'
+ shift(244); // 'treat'
+ break;
+ case 245: // 'try'
+ shift(245); // 'try'
+ break;
+ case 249: // 'union'
+ shift(249); // 'union'
+ break;
+ case 251: // 'unordered'
+ shift(251); // 'unordered'
+ break;
+ case 255: // 'validate'
+ shift(255); // 'validate'
+ break;
+ case 261: // 'where'
+ shift(261); // 'where'
+ break;
+ case 265: // 'with'
+ shift(265); // 'with'
+ break;
+ case 269: // 'xquery'
+ shift(269); // 'xquery'
+ break;
+ case 67: // 'allowing'
+ shift(67); // 'allowing'
+ break;
+ case 76: // 'at'
+ shift(76); // 'at'
+ break;
+ case 78: // 'base-uri'
+ shift(78); // 'base-uri'
+ break;
+ case 80: // 'boundary-space'
+ shift(80); // 'boundary-space'
+ break;
+ case 81: // 'break'
+ shift(81); // 'break'
+ break;
+ case 86: // 'catch'
+ shift(86); // 'catch'
+ break;
+ case 93: // 'construction'
+ shift(93); // 'construction'
+ break;
+ case 96: // 'context'
+ shift(96); // 'context'
+ break;
+ case 97: // 'continue'
+ shift(97); // 'continue'
+ break;
+ case 99: // 'copy-namespaces'
+ shift(99); // 'copy-namespaces'
+ break;
+ case 101: // 'decimal-format'
+ shift(101); // 'decimal-format'
+ break;
+ case 120: // 'encoding'
+ shift(120); // 'encoding'
+ break;
+ case 127: // 'exit'
+ shift(127); // 'exit'
+ break;
+ case 128: // 'external'
+ shift(128); // 'external'
+ break;
+ case 136: // 'ft-option'
+ shift(136); // 'ft-option'
+ break;
+ case 149: // 'in'
+ shift(149); // 'in'
+ break;
+ case 150: // 'index'
+ shift(150); // 'index'
+ break;
+ case 156: // 'integrity'
+ shift(156); // 'integrity'
+ break;
+ case 166: // 'lax'
+ shift(166); // 'lax'
+ break;
+ case 187: // 'nodes'
+ shift(187); // 'nodes'
+ break;
+ case 194: // 'option'
+ shift(194); // 'option'
+ break;
+ case 198: // 'ordering'
+ shift(198); // 'ordering'
+ break;
+ case 217: // 'revalidation'
+ shift(217); // 'revalidation'
+ break;
+ case 220: // 'schema'
+ shift(220); // 'schema'
+ break;
+ case 223: // 'score'
+ shift(223); // 'score'
+ break;
+ case 229: // 'sliding'
+ shift(229); // 'sliding'
+ break;
+ case 235: // 'strict'
+ shift(235); // 'strict'
+ break;
+ case 246: // 'tumbling'
+ shift(246); // 'tumbling'
+ break;
+ case 247: // 'type'
+ shift(247); // 'type'
+ break;
+ case 252: // 'updating'
+ shift(252); // 'updating'
+ break;
+ case 256: // 'value'
+ shift(256); // 'value'
+ break;
+ case 257: // 'variable'
+ shift(257); // 'variable'
+ break;
+ case 258: // 'version'
+ shift(258); // 'version'
+ break;
+ case 262: // 'while'
+ shift(262); // 'while'
+ break;
+ case 92: // 'constraint'
+ shift(92); // 'constraint'
+ break;
+ case 171: // 'loop'
+ shift(171); // 'loop'
+ break;
+ default:
+ shift(216); // 'returning'
+ }
+ eventHandler.endNonterminal("FunctionName", e0);
+ }
+
+ function parse_NCName()
+ {
+ eventHandler.startNonterminal("NCName", e0);
+ switch (l1)
+ {
+ case 26: // NCName^Token
+ shift(26); // NCName^Token
+ break;
+ case 65: // 'after'
+ shift(65); // 'after'
+ break;
+ case 70: // 'and'
+ shift(70); // 'and'
+ break;
+ case 74: // 'as'
+ shift(74); // 'as'
+ break;
+ case 75: // 'ascending'
+ shift(75); // 'ascending'
+ break;
+ case 79: // 'before'
+ shift(79); // 'before'
+ break;
+ case 83: // 'case'
+ shift(83); // 'case'
+ break;
+ case 84: // 'cast'
+ shift(84); // 'cast'
+ break;
+ case 85: // 'castable'
+ shift(85); // 'castable'
+ break;
+ case 89: // 'collation'
+ shift(89); // 'collation'
+ break;
+ case 100: // 'count'
+ shift(100); // 'count'
+ break;
+ case 104: // 'default'
+ shift(104); // 'default'
+ break;
+ case 108: // 'descending'
+ shift(108); // 'descending'
+ break;
+ case 113: // 'div'
+ shift(113); // 'div'
+ break;
+ case 117: // 'else'
+ shift(117); // 'else'
+ break;
+ case 118: // 'empty'
+ shift(118); // 'empty'
+ break;
+ case 121: // 'end'
+ shift(121); // 'end'
+ break;
+ case 123: // 'eq'
+ shift(123); // 'eq'
+ break;
+ case 126: // 'except'
+ shift(126); // 'except'
+ break;
+ case 132: // 'for'
+ shift(132); // 'for'
+ break;
+ case 141: // 'ge'
+ shift(141); // 'ge'
+ break;
+ case 143: // 'group'
+ shift(143); // 'group'
+ break;
+ case 145: // 'gt'
+ shift(145); // 'gt'
+ break;
+ case 146: // 'idiv'
+ shift(146); // 'idiv'
+ break;
+ case 155: // 'instance'
+ shift(155); // 'instance'
+ break;
+ case 157: // 'intersect'
+ shift(157); // 'intersect'
+ break;
+ case 158: // 'into'
+ shift(158); // 'into'
+ break;
+ case 159: // 'is'
+ shift(159); // 'is'
+ break;
+ case 167: // 'le'
+ shift(167); // 'le'
+ break;
+ case 169: // 'let'
+ shift(169); // 'let'
+ break;
+ case 173: // 'lt'
+ shift(173); // 'lt'
+ break;
+ case 175: // 'mod'
+ shift(175); // 'mod'
+ break;
+ case 176: // 'modify'
+ shift(176); // 'modify'
+ break;
+ case 181: // 'ne'
+ shift(181); // 'ne'
+ break;
+ case 193: // 'only'
+ shift(193); // 'only'
+ break;
+ case 195: // 'or'
+ shift(195); // 'or'
+ break;
+ case 196: // 'order'
+ shift(196); // 'order'
+ break;
+ case 215: // 'return'
+ shift(215); // 'return'
+ break;
+ case 219: // 'satisfies'
+ shift(219); // 'satisfies'
+ break;
+ case 231: // 'stable'
+ shift(231); // 'stable'
+ break;
+ case 232: // 'start'
+ shift(232); // 'start'
+ break;
+ case 243: // 'to'
+ shift(243); // 'to'
+ break;
+ case 244: // 'treat'
+ shift(244); // 'treat'
+ break;
+ case 249: // 'union'
+ shift(249); // 'union'
+ break;
+ case 261: // 'where'
+ shift(261); // 'where'
+ break;
+ case 265: // 'with'
+ shift(265); // 'with'
+ break;
+ case 68: // 'ancestor'
+ shift(68); // 'ancestor'
+ break;
+ case 69: // 'ancestor-or-self'
+ shift(69); // 'ancestor-or-self'
+ break;
+ case 77: // 'attribute'
+ shift(77); // 'attribute'
+ break;
+ case 88: // 'child'
+ shift(88); // 'child'
+ break;
+ case 91: // 'comment'
+ shift(91); // 'comment'
+ break;
+ case 98: // 'copy'
+ shift(98); // 'copy'
+ break;
+ case 103: // 'declare'
+ shift(103); // 'declare'
+ break;
+ case 105: // 'delete'
+ shift(105); // 'delete'
+ break;
+ case 106: // 'descendant'
+ shift(106); // 'descendant'
+ break;
+ case 107: // 'descendant-or-self'
+ shift(107); // 'descendant-or-self'
+ break;
+ case 114: // 'document'
+ shift(114); // 'document'
+ break;
+ case 115: // 'document-node'
+ shift(115); // 'document-node'
+ break;
+ case 116: // 'element'
+ shift(116); // 'element'
+ break;
+ case 119: // 'empty-sequence'
+ shift(119); // 'empty-sequence'
+ break;
+ case 124: // 'every'
+ shift(124); // 'every'
+ break;
+ case 129: // 'first'
+ shift(129); // 'first'
+ break;
+ case 130: // 'following'
+ shift(130); // 'following'
+ break;
+ case 131: // 'following-sibling'
+ shift(131); // 'following-sibling'
+ break;
+ case 140: // 'function'
+ shift(140); // 'function'
+ break;
+ case 147: // 'if'
+ shift(147); // 'if'
+ break;
+ case 148: // 'import'
+ shift(148); // 'import'
+ break;
+ case 154: // 'insert'
+ shift(154); // 'insert'
+ break;
+ case 160: // 'item'
+ shift(160); // 'item'
+ break;
+ case 165: // 'last'
+ shift(165); // 'last'
+ break;
+ case 177: // 'module'
+ shift(177); // 'module'
+ break;
+ case 179: // 'namespace'
+ shift(179); // 'namespace'
+ break;
+ case 180: // 'namespace-node'
+ shift(180); // 'namespace-node'
+ break;
+ case 186: // 'node'
+ shift(186); // 'node'
+ break;
+ case 197: // 'ordered'
+ shift(197); // 'ordered'
+ break;
+ case 201: // 'parent'
+ shift(201); // 'parent'
+ break;
+ case 207: // 'preceding'
+ shift(207); // 'preceding'
+ break;
+ case 208: // 'preceding-sibling'
+ shift(208); // 'preceding-sibling'
+ break;
+ case 211: // 'processing-instruction'
+ shift(211); // 'processing-instruction'
+ break;
+ case 213: // 'rename'
+ shift(213); // 'rename'
+ break;
+ case 214: // 'replace'
+ shift(214); // 'replace'
+ break;
+ case 221: // 'schema-attribute'
+ shift(221); // 'schema-attribute'
+ break;
+ case 222: // 'schema-element'
+ shift(222); // 'schema-element'
+ break;
+ case 224: // 'self'
+ shift(224); // 'self'
+ break;
+ case 230: // 'some'
+ shift(230); // 'some'
+ break;
+ case 238: // 'switch'
+ shift(238); // 'switch'
+ break;
+ case 239: // 'text'
+ shift(239); // 'text'
+ break;
+ case 245: // 'try'
+ shift(245); // 'try'
+ break;
+ case 248: // 'typeswitch'
+ shift(248); // 'typeswitch'
+ break;
+ case 251: // 'unordered'
+ shift(251); // 'unordered'
+ break;
+ case 255: // 'validate'
+ shift(255); // 'validate'
+ break;
+ case 257: // 'variable'
+ shift(257); // 'variable'
+ break;
+ case 269: // 'xquery'
+ shift(269); // 'xquery'
+ break;
+ case 67: // 'allowing'
+ shift(67); // 'allowing'
+ break;
+ case 76: // 'at'
+ shift(76); // 'at'
+ break;
+ case 78: // 'base-uri'
+ shift(78); // 'base-uri'
+ break;
+ case 80: // 'boundary-space'
+ shift(80); // 'boundary-space'
+ break;
+ case 81: // 'break'
+ shift(81); // 'break'
+ break;
+ case 86: // 'catch'
+ shift(86); // 'catch'
+ break;
+ case 93: // 'construction'
+ shift(93); // 'construction'
+ break;
+ case 96: // 'context'
+ shift(96); // 'context'
+ break;
+ case 97: // 'continue'
+ shift(97); // 'continue'
+ break;
+ case 99: // 'copy-namespaces'
+ shift(99); // 'copy-namespaces'
+ break;
+ case 101: // 'decimal-format'
+ shift(101); // 'decimal-format'
+ break;
+ case 120: // 'encoding'
+ shift(120); // 'encoding'
+ break;
+ case 127: // 'exit'
+ shift(127); // 'exit'
+ break;
+ case 128: // 'external'
+ shift(128); // 'external'
+ break;
+ case 136: // 'ft-option'
+ shift(136); // 'ft-option'
+ break;
+ case 149: // 'in'
+ shift(149); // 'in'
+ break;
+ case 150: // 'index'
+ shift(150); // 'index'
+ break;
+ case 156: // 'integrity'
+ shift(156); // 'integrity'
+ break;
+ case 166: // 'lax'
+ shift(166); // 'lax'
+ break;
+ case 187: // 'nodes'
+ shift(187); // 'nodes'
+ break;
+ case 194: // 'option'
+ shift(194); // 'option'
+ break;
+ case 198: // 'ordering'
+ shift(198); // 'ordering'
+ break;
+ case 217: // 'revalidation'
+ shift(217); // 'revalidation'
+ break;
+ case 220: // 'schema'
+ shift(220); // 'schema'
+ break;
+ case 223: // 'score'
+ shift(223); // 'score'
+ break;
+ case 229: // 'sliding'
+ shift(229); // 'sliding'
+ break;
+ case 235: // 'strict'
+ shift(235); // 'strict'
+ break;
+ case 246: // 'tumbling'
+ shift(246); // 'tumbling'
+ break;
+ case 247: // 'type'
+ shift(247); // 'type'
+ break;
+ case 252: // 'updating'
+ shift(252); // 'updating'
+ break;
+ case 256: // 'value'
+ shift(256); // 'value'
+ break;
+ case 258: // 'version'
+ shift(258); // 'version'
+ break;
+ case 262: // 'while'
+ shift(262); // 'while'
+ break;
+ case 92: // 'constraint'
+ shift(92); // 'constraint'
+ break;
+ case 171: // 'loop'
+ shift(171); // 'loop'
+ break;
+ default:
+ shift(216); // 'returning'
+ }
+ eventHandler.endNonterminal("NCName", e0);
+ }
+
+ function shift(t)
+ {
+ if (l1 == t)
+ {
+ whitespace();
+ eventHandler.terminal(XQueryTokenizer.TOKEN[l1], b1, e1 > size ? size : e1);
+ b0 = b1; e0 = e1; l1 = 0;
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function whitespace()
+ {
+ if (e0 != b1)
+ {
+ b0 = e0;
+ e0 = b1;
+ eventHandler.whitespace(b0, e0);
+ }
+ }
+
+ function matchW(set)
+ {
+ var code;
+ for (;;)
+ {
+ code = match(set);
+ if (code != 28) // S^WS
+ {
+ break;
+ }
+ }
+ return code;
+ }
+
+ function lookahead1W(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = matchW(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead1(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = match(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function error(b, e, s, l, t)
+ {
+ throw new self.ParseException(b, e, s, l, t);
+ }
+
+ var lk, b0, e0;
+ var l1, b1, e1;
+ var eventHandler;
+
+ var input;
+ var size;
+ var begin;
+ var end;
+
+ function match(tokenSetId)
+ {
+ var nonbmp = false;
+ begin = end;
+ var current = end;
+ var result = XQueryTokenizer.INITIAL[tokenSetId];
+ var state = 0;
+
+ for (var code = result & 4095; code != 0; )
+ {
+ var charclass;
+ var c0 = current < size ? input.charCodeAt(current) : 0;
+ ++current;
+ if (c0 < 0x80)
+ {
+ charclass = XQueryTokenizer.MAP0[c0];
+ }
+ else if (c0 < 0xd800)
+ {
+ var c1 = c0 >> 4;
+ charclass = XQueryTokenizer.MAP1[(c0 & 15) + XQueryTokenizer.MAP1[(c1 & 31) + XQueryTokenizer.MAP1[c1 >> 5]]];
+ }
+ else
+ {
+ if (c0 < 0xdc00)
+ {
+ var c1 = current < size ? input.charCodeAt(current) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000)
+ {
+ ++current;
+ c0 = ((c0 & 0x3ff) << 10) + (c1 & 0x3ff) + 0x10000;
+ nonbmp = true;
+ }
+ }
+ var lo = 0, hi = 5;
+ for (var m = 3; ; m = (hi + lo) >> 1)
+ {
+ if (XQueryTokenizer.MAP2[m] > c0) hi = m - 1;
+ else if (XQueryTokenizer.MAP2[6 + m] < c0) lo = m + 1;
+ else {charclass = XQueryTokenizer.MAP2[12 + m]; break;}
+ if (lo > hi) {charclass = 0; break;}
+ }
+ }
+
+ state = code;
+ var i0 = (charclass << 12) + code - 1;
+ code = XQueryTokenizer.TRANSITION[(i0 & 15) + XQueryTokenizer.TRANSITION[i0 >> 4]];
+
+ if (code > 4095)
+ {
+ result = code;
+ code &= 4095;
+ end = current;
+ }
+ }
+
+ result >>= 12;
+ if (result == 0)
+ {
+ end = current - 1;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ return error(begin, end, state, -1, -1);
+ }
+
+ if (nonbmp)
+ {
+ for (var i = result >> 9; i > 0; --i)
+ {
+ --end;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ }
+ }
+ else
+ {
+ end -= result >> 9;
+ }
+
+ return (result & 511) - 1;
+ }
+}
+
+XQueryTokenizer.getTokenSet = function(tokenSetId)
+{
+ var set = [];
+ var s = tokenSetId < 0 ? - tokenSetId : INITIAL[tokenSetId] & 4095;
+ for (var i = 0; i < 276; i += 32)
+ {
+ var j = i;
+ var i0 = (i >> 5) * 2062 + s - 1;
+ var i1 = i0 >> 2;
+ var i2 = i1 >> 2;
+ var f = XQueryTokenizer.EXPECTED[(i0 & 3) + XQueryTokenizer.EXPECTED[(i1 & 3) + XQueryTokenizer.EXPECTED[(i2 & 3) + XQueryTokenizer.EXPECTED[i2 >> 2]]]];
+ for ( ; f != 0; f >>>= 1, ++j)
+ {
+ if ((f & 1) != 0)
+ {
+ set.push(XQueryTokenizer.TOKEN[j]);
+ }
+ }
+ }
+ return set;
+};
+
+XQueryTokenizer.MAP0 =
+[ 66, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 35, 31, 35, 37, 38, 39, 40, 41, 42, 43, 44, 45, 31, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 31, 61, 62, 63, 64, 35
+];
+
+XQueryTokenizer.MAP1 =
+[ 108, 124, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 156, 181, 181, 181, 181, 181, 214, 215, 213, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 247, 261, 277, 293, 309, 347, 363, 379, 416, 416, 416, 408, 331, 323, 331, 323, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 433, 433, 433, 433, 433, 433, 433, 316, 331, 331, 331, 331, 331, 331, 331, 331, 394, 416, 416, 417, 415, 416, 416, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 330, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 66, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 35, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 35, 31, 35, 37, 38, 39, 40, 41, 42, 43, 44, 45, 31, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 31, 61, 62, 63, 64, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 31, 31, 35, 35, 35, 35, 35, 35, 35, 65, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65
+];
+
+XQueryTokenizer.MAP2 =
+[ 57344, 63744, 64976, 65008, 65536, 983040, 63743, 64975, 65007, 65533, 983039, 1114111, 35, 31, 35, 31, 31, 35
+];
+
+XQueryTokenizer.INITIAL =
+[ 1, 2, 36867, 45060, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
+];
+
+XQueryTokenizer.TRANSITION =
+[ 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22908, 18836, 17152, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 17365, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 17470, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 18157, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 17848, 17880, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18023, 36545, 18621, 18039, 18056, 18072, 18117, 18143, 18173, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17687, 18805, 18421, 18437, 18101, 17393, 18489, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 18579, 21711, 17152, 19008, 19233, 20367, 19008, 28684, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 17365, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 17470, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 18157, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 17848, 17880, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18023, 36545, 18621, 18039, 18056, 18072, 18117, 18143, 18173, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17687, 18805, 18421, 18437, 18101, 17393, 18489, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 20116, 18836, 18637, 19008, 19233, 21267, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 18763, 18778, 18794, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 18821, 22923, 18906, 19008, 19233, 17431, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18937, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 19054, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 18953, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21843, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21696, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22429, 20131, 18720, 19008, 19233, 20367, 19008, 17173, 23559, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 18087, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 21242, 19111, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 19024, 18836, 18609, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 19081, 22444, 18987, 19008, 19233, 20367, 19008, 19065, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21992, 22007, 18987, 19008, 19233, 20367, 19008, 18690, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22414, 18836, 18987, 19008, 19233, 30651, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 19138, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 19280, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 19172, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21783, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 19218, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21651, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 19249, 19265, 19307, 18888, 27857, 30536, 24401, 31444, 23357, 18888, 19351, 18888, 18890, 27211, 19370, 27211, 27211, 19392, 24401, 31911, 24401, 24401, 25467, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 19440, 24401, 24401, 24401, 24401, 24036, 17994, 24060, 18888, 18888, 18888, 18890, 19468, 27211, 27211, 27211, 27211, 19484, 35367, 19520, 24401, 24401, 24401, 19628, 18888, 29855, 18888, 18888, 23086, 27211, 19538, 27211, 27211, 30756, 24012, 24401, 19560, 24401, 24401, 26750, 18888, 18888, 19327, 27855, 27211, 27211, 19580, 17590, 24017, 24401, 24401, 19600, 25665, 18888, 18888, 28518, 27211, 27212, 24016, 19620, 19868, 28435, 25722, 18889, 19644, 27211, 32888, 35852, 19868, 31018, 19694, 19376, 19717, 22215, 19735, 22098, 19751, 35203, 19776, 19797, 19817, 19840, 25783, 31738, 24135, 19701, 19856, 31015, 23516, 31008, 28311, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21768, 18836, 19307, 18888, 27857, 27904, 24401, 29183, 28015, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 19888, 24401, 24401, 24401, 24401, 22953, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 19440, 24401, 24401, 24401, 24401, 24036, 18881, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22399, 18836, 19918, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21666, 18836, 19307, 18888, 27857, 27525, 24401, 29183, 21467, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 19946, 24401, 24401, 24401, 24401, 32382, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 19998, 24401, 24401, 24401, 24401, 31500, 18467, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 20021, 24401, 24401, 24401, 24401, 24401, 34271, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 32926, 29908, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 20050, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 20101, 19039, 20191, 20412, 20903, 17569, 20309, 20872, 25633, 20623, 20505, 20218, 20242, 17189, 17208, 17281, 20355, 20265, 20306, 20328, 20383, 22490, 20796, 20619, 21354, 20654, 20410, 20956, 21232, 20765, 17421, 20535, 17192, 18127, 22459, 20312, 25531, 22470, 20309, 20428, 18964, 20466, 20491, 21342, 21070, 20521, 20682, 17714, 18326, 17543, 17559, 17585, 22497, 20559, 19504, 20279, 20575, 20290, 20475, 20604, 20639, 20226, 20670, 17661, 21190, 17703, 21176, 17730, 19494, 20698, 20711, 22480, 21046, 21116, 18971, 21130, 20727, 20755, 17675, 17753, 17832, 17590, 25518, 20394, 20781, 20831, 20202, 20847, 21401, 17292, 17934, 17979, 18549, 20863, 20588, 25542, 20888, 20919, 18072, 18117, 20935, 20972, 21032, 21062, 21086, 18239, 21102, 18563, 21146, 21162, 21206, 18351, 20949, 20902, 18340, 21222, 21258, 21283, 18360, 20249, 17405, 21295, 21311, 21327, 20739, 20343, 21370, 21386, 21417, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21977, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 21452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 21504, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 36501, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 28674, 21946, 17617, 36473, 18223, 17237, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 21575, 21534, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 21560, 30628, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21798, 18836, 21612, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21636, 18836, 18987, 19008, 19233, 17902, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21753, 19096, 21903, 19008, 19233, 20367, 19008, 19291, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 17379, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 21931, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 18280, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21962, 18594, 18987, 19008, 19233, 22043, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21681, 21858, 18987, 19008, 19233, 20367, 19008, 21544, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 32319, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 22231, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 31678, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 33588, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 35019, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22248, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22324, 18836, 22059, 18888, 27857, 30501, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 34365, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22354, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 27086, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 19930, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21828, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22309, 22513, 18987, 19008, 19233, 20367, 19008, 19122, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 22544, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22608, 18836, 22988, 23004, 27585, 23020, 23036, 23067, 22087, 18888, 18888, 18888, 23083, 27211, 27211, 27211, 23102, 22121, 24401, 24401, 24401, 23122, 31386, 26154, 19674, 18888, 28119, 28232, 19424, 23705, 27211, 27211, 23142, 23173, 23189, 23212, 24401, 24401, 23246, 34427, 31693, 23262, 18888, 23290, 23308, 27783, 27620, 23327, 35263, 35107, 33383, 23346, 18193, 23393, 32748, 23968, 24401, 23414, 35153, 23463, 18888, 33913, 23442, 23482, 27211, 27211, 23532, 23552, 21431, 23575, 24401, 24401, 23604, 26095, 23635, 23657, 18888, 33482, 23685, 33251, 27211, 22187, 18851, 23721, 35536, 24401, 18887, 23750, 32641, 27211, 23769, 23787, 20080, 33012, 24384, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 23803, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 28224, 31826, 23823, 26917, 34978, 23850, 26493, 25782, 23878, 23914, 23516, 31008, 22105, 19419, 27963, 19659, 29781, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22623, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 28909, 25783, 27211, 27211, 27211, 34048, 23933, 22164, 24401, 24401, 24401, 28409, 23949, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 26583, 18888, 18888, 18888, 35585, 23984, 27211, 27211, 27211, 24005, 22201, 24033, 24401, 24401, 24401, 24052, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 26496, 24076, 24126, 24151, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22638, 18836, 22059, 19678, 27857, 24185, 24401, 24201, 24217, 26592, 18888, 18888, 18890, 24252, 24268, 27211, 27211, 22121, 24287, 24303, 24401, 24401, 30613, 19781, 35432, 36007, 32649, 18888, 25783, 24322, 28966, 23771, 27211, 35072, 22164, 24358, 32106, 26829, 24400, 31500, 31693, 18888, 18888, 18888, 24801, 18890, 27211, 27211, 27211, 27211, 24418, 19484, 24401, 24401, 24401, 24401, 20167, 31181, 18888, 18888, 18888, 27833, 23086, 27211, 27211, 33540, 27211, 30756, 21431, 24401, 24401, 22972, 24401, 26095, 18888, 36131, 18888, 27855, 27211, 24440, 27211, 22187, 22968, 24401, 24459, 24401, 31699, 28454, 18888, 34528, 34570, 35779, 24478, 24402, 24494, 25659, 18888, 36228, 27211, 27211, 24515, 30981, 23734, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 24538, 31017, 27856, 31741, 30059, 23377, 24563, 19837, 25782, 19760, 31015, 23516, 25374, 22105, 19419, 29793, 24579, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22653, 18836, 22059, 25756, 19982, 34097, 23196, 29183, 24614, 24110, 23641, 24673, 26103, 24697, 24443, 24713, 28558, 22121, 24748, 24462, 24764, 23398, 30613, 18888, 18888, 18888, 18888, 24798, 25783, 27211, 27211, 27211, 34232, 35072, 22164, 24401, 24401, 24401, 33302, 31500, 22559, 24106, 24232, 18888, 18888, 34970, 24817, 30411, 27211, 27211, 32484, 19484, 29750, 35127, 24401, 24401, 19872, 31181, 24852, 18888, 18888, 24871, 29221, 27211, 27211, 32072, 27211, 30756, 34441, 24401, 24401, 31571, 24401, 26095, 33141, 27802, 27011, 27855, 25295, 25607, 24888, 22187, 22968, 19195, 34593, 24906, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 33663, 27211, 27211, 24924, 24947, 23588, 31018, 18890, 27211, 31833, 22135, 19447, 23086, 23330, 19828, 30904, 31042, 24972, 19840, 25000, 31738, 30898, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 25016, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22668, 18836, 25041, 25057, 31320, 25073, 25089, 25105, 22087, 34796, 24236, 36138, 34870, 34125, 25121, 23106, 35497, 22248, 36613, 25137, 30671, 27365, 30613, 25153, 26447, 25199, 25233, 22574, 23274, 25249, 25265, 25281, 25318, 25344, 25360, 25400, 25428, 25452, 26731, 25504, 31693, 23669, 25558, 27407, 25575, 28599, 25934, 25599, 27211, 28180, 27304, 25623, 25839, 25649, 24401, 34820, 25681, 25698, 22586, 27775, 30190, 25745, 25778, 25799, 25817, 28995, 33569, 30756, 21518, 33443, 25837, 25855, 25893, 26095, 31254, 26677, 30136, 27855, 25930, 25950, 27211, 22187, 22968, 25966, 25986, 24401, 23428, 27763, 36330, 26959, 26002, 26029, 26045, 26085, 26119, 26170, 26203, 26222, 26239, 30527, 26372, 26274, 28404, 31018, 33757, 27211, 34262, 26316, 36729, 26345, 26366, 35337, 31017, 26388, 26407, 30954, 26350, 33861, 26434, 26463, 26479, 26512, 23516, 33189, 26531, 26547, 27963, 31293, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22683, 18836, 26568, 26181, 26608, 34097, 26643, 29183, 22087, 26669, 18888, 18888, 18890, 26693, 27211, 27211, 27211, 22121, 26720, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 26774, 25783, 27211, 27211, 27211, 26619, 35072, 22164, 24401, 24401, 24401, 21596, 31500, 31693, 18888, 18888, 33978, 18888, 18890, 27211, 27211, 25801, 27211, 27211, 19484, 24401, 24401, 24401, 26792, 24401, 31181, 18888, 18888, 18888, 35464, 23086, 27211, 27211, 27211, 26809, 30756, 21431, 24401, 24401, 24401, 26828, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 31948, 18889, 35707, 27211, 19719, 26845, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 26905, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 24984, 31088, 19419, 26945, 27651, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22698, 18836, 26999, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 23051, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 27033, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 27056, 18888, 18890, 27211, 27211, 30320, 27211, 27211, 27075, 24401, 24401, 29032, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 33986, 27855, 27211, 27211, 27102, 17590, 24017, 24401, 24401, 27123, 27144, 36254, 27162, 27210, 27228, 28500, 18187, 34842, 33426, 27244, 35980, 27277, 27302, 27320, 36048, 34013, 20999, 31882, 21478, 27895, 27356, 30287, 27381, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 26329, 30087, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 27406, 27423, 27445, 35294, 27461, 22087, 18888, 18888, 30140, 18890, 27211, 27211, 27989, 27211, 22121, 24401, 24401, 25682, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 34042, 27211, 27211, 27211, 27211, 29700, 22164, 24401, 24401, 24401, 24401, 27128, 31693, 27477, 18888, 18888, 18888, 18890, 27194, 27211, 27211, 27211, 27211, 19484, 35299, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 27059, 23086, 27211, 27211, 27211, 33366, 30756, 24012, 24401, 24401, 24401, 35044, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 20815, 27211, 30818, 19960, 33969, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22713, 18836, 22059, 27496, 27516, 27541, 35231, 27557, 22087, 29662, 26292, 23292, 27573, 24836, 27601, 27211, 27636, 22121, 35544, 27686, 24401, 27721, 18866, 18888, 27799, 18888, 27818, 22071, 27853, 32260, 27211, 26013, 27873, 27920, 22164, 29419, 24401, 29946, 33413, 26742, 27751, 26881, 18888, 18888, 27261, 36776, 27936, 27211, 27211, 27211, 27988, 28005, 28031, 28052, 24401, 24401, 28069, 28088, 28135, 25488, 28152, 26069, 28167, 27211, 28340, 24657, 28196, 30756, 31523, 24401, 28212, 34176, 36174, 24956, 28248, 28266, 28290, 21488, 33077, 28327, 28356, 17590, 20986, 23126, 28391, 28425, 28102, 28451, 28470, 28490, 28516, 28534, 20034, 33728, 25868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 30241, 28274, 28553, 28574, 19406, 28590, 23086, 23330, 19828, 19452, 28615, 28660, 26147, 25783, 31738, 19837, 25782, 19760, 29613, 35958, 29276, 22105, 19419, 27963, 23157, 28700, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 22528, 18888, 18888, 18888, 18888, 18890, 27333, 27211, 27211, 27211, 27211, 19484, 30853, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22728, 18836, 28747, 28782, 28817, 28841, 28857, 28880, 28896, 24161, 28943, 32011, 36261, 27340, 28961, 29492, 28982, 29011, 24522, 29027, 25436, 29048, 23051, 27500, 29090, 29110, 30713, 18888, 23512, 29130, 25183, 27211, 29155, 28927, 27033, 29173, 23230, 24401, 29199, 35373, 31693, 18888, 18888, 25583, 32629, 29218, 27211, 27211, 31461, 30692, 29237, 27075, 24401, 24401, 24401, 29262, 29302, 19628, 18888, 34329, 18888, 18888, 23086, 27211, 29329, 27211, 27211, 30756, 24012, 35933, 24401, 24401, 24401, 27705, 31612, 18888, 18888, 29346, 29374, 27211, 35650, 17590, 21436, 29393, 24401, 25970, 18887, 33895, 18888, 27211, 32528, 27212, 24016, 32769, 19868, 25659, 18888, 26889, 27211, 27211, 29412, 23889, 24371, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31768, 19840, 25783, 31738, 19837, 29435, 29508, 31102, 29550, 29606, 22105, 30300, 29462, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22743, 18836, 22059, 29629, 29473, 34097, 33285, 29183, 29651, 27254, 18888, 29678, 33329, 32535, 27211, 29694, 29716, 22121, 19202, 24401, 32742, 29741, 18866, 26776, 33921, 28474, 18888, 18888, 25783, 29766, 27211, 29809, 27211, 35072, 22164, 35825, 24401, 29828, 24401, 24036, 36769, 25217, 18888, 18888, 29848, 18890, 27211, 29871, 27211, 26258, 27211, 29894, 24401, 29929, 24401, 36587, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 29725, 29962, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18473, 18888, 18888, 19584, 27211, 27212, 24016, 29982, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19902, 19447, 32052, 19544, 19828, 29998, 30097, 30031, 19840, 25783, 30047, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 30075, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22758, 18836, 30121, 30156, 30206, 30257, 30273, 30336, 22087, 35624, 32837, 25762, 18890, 29878, 34934, 26812, 27211, 22121, 24931, 23223, 29202, 24401, 18866, 34373, 30352, 18888, 18888, 18888, 23447, 24828, 27211, 27211, 27211, 35072, 30370, 35052, 24401, 24401, 24401, 24036, 29523, 18888, 18888, 27146, 18888, 31308, 30386, 27211, 27211, 30405, 30558, 19484, 30427, 24401, 24401, 29938, 35686, 19628, 28766, 30447, 34506, 35614, 23086, 28731, 30482, 30517, 30552, 30756, 24012, 20156, 30574, 30598, 30667, 26283, 33464, 28945, 27670, 30687, 32915, 33504, 25328, 17590, 23963, 20450, 33837, 21016, 32397, 26300, 30708, 30729, 27885, 30748, 21588, 36373, 30779, 26653, 24628, 33220, 32514, 30806, 31835, 25412, 25906, 26515, 18890, 28825, 31833, 26133, 19447, 28304, 31730, 23834, 26057, 30869, 30885, 32181, 30920, 30942, 32797, 25782, 30970, 31015, 23516, 31008, 30997, 31034, 27963, 19659, 29450, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22773, 18836, 31058, 31074, 32463, 31125, 31141, 31197, 22087, 18888, 29534, 35471, 36738, 27211, 24342, 31213, 24424, 22121, 24401, 20175, 31229, 31917, 27736, 31245, 34334, 27175, 18888, 29094, 27286, 27211, 31278, 31336, 27211, 31355, 31371, 24401, 31402, 31418, 24401, 31437, 31693, 18888, 31619, 32841, 18888, 18890, 27211, 27211, 31460, 31477, 27211, 19484, 24401, 24401, 31497, 36581, 24401, 33020, 18888, 18888, 18888, 18888, 30007, 27211, 27211, 27211, 27211, 31516, 32310, 24401, 24401, 24401, 24401, 31539, 18888, 28762, 18888, 24651, 35740, 27211, 27211, 28644, 31565, 35796, 24401, 24401, 19318, 32188, 18888, 24334, 28366, 27212, 29966, 29832, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 31587, 19868, 31635, 32435, 33693, 30105, 31663, 20005, 31715, 31757, 31784, 31812, 30015, 31851, 31878, 25783, 31898, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 31933, 30221, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22788, 18836, 22059, 25729, 30466, 31968, 24306, 31984, 32000, 32807, 35160, 27017, 29590, 34941, 19801, 29377, 33700, 22121, 27040, 30431, 29396, 28864, 29565, 18888, 18888, 18888, 32027, 18888, 25783, 27211, 27211, 23698, 27211, 35072, 22164, 24401, 24401, 30845, 24401, 24036, 32045, 18888, 26929, 18888, 18888, 18890, 27211, 31481, 32068, 27211, 27211, 32088, 24401, 33058, 32122, 24401, 24401, 33736, 18888, 18888, 33162, 18888, 23086, 27211, 27211, 29484, 27211, 28375, 32144, 24401, 24401, 33831, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 36704, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 33107, 22171, 33224, 24271, 32169, 31017, 27856, 31741, 19840, 25783, 31738, 30234, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 32204, 32232, 32252, 32677, 33295, 29074, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 23619, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 32276, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 32299, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 33886, 18889, 36065, 27211, 19719, 35326, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22803, 18836, 32335, 31647, 34666, 32351, 32367, 32417, 22087, 18888, 32433, 19335, 32451, 27211, 32479, 27107, 32500, 22121, 24401, 32551, 20085, 32572, 18866, 22287, 23753, 18888, 18888, 32602, 32665, 27211, 32693, 27211, 26972, 32713, 32729, 24401, 32764, 24401, 25877, 32785, 34768, 18888, 27390, 32823, 24594, 24855, 32857, 24890, 32878, 32904, 27211, 32942, 32977, 24401, 33000, 29313, 24401, 30790, 26206, 27666, 33904, 18888, 23086, 36353, 27211, 33036, 27211, 30756, 24012, 32153, 24401, 33056, 24401, 35861, 18888, 18888, 30354, 27972, 27211, 27211, 33800, 17590, 20145, 24401, 24401, 34638, 20811, 18888, 18888, 33074, 27211, 27212, 36167, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 34616, 24169, 33093, 33123, 33157, 27856, 31741, 23862, 26552, 34302, 19837, 25782, 19760, 31015, 23516, 31008, 33178, 19973, 27963, 23497, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22818, 18836, 33205, 28113, 33240, 34097, 33275, 29183, 22087, 33318, 35438, 18888, 18890, 33345, 26391, 33382, 27211, 22121, 33399, 28072, 33442, 24401, 18866, 22232, 18888, 33459, 18888, 18888, 33480, 33498, 25175, 27211, 27211, 26704, 22164, 24775, 35239, 24401, 24401, 25914, 29580, 18888, 18888, 31109, 25211, 33520, 33539, 27211, 27211, 33556, 36284, 19484, 33585, 24401, 24401, 33604, 32556, 19628, 18888, 18888, 31262, 33658, 23086, 27211, 27211, 33679, 27211, 30756, 24012, 24401, 24401, 33716, 24401, 26854, 27480, 18888, 33752, 27855, 33259, 34701, 27211, 17590, 32102, 24782, 23807, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 33773, 36105, 19868, 25659, 18888, 23368, 27211, 29157, 19719, 23889, 34454, 29286, 18890, 33794, 25302, 33816, 19447, 34079, 33853, 31862, 31017, 27856, 31741, 33877, 28920, 33937, 19837, 30461, 34002, 22276, 36041, 34029, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22833, 18836, 34064, 32616, 34113, 34141, 34157, 34192, 34208, 32216, 36013, 31549, 31952, 34224, 34248, 34287, 29330, 34350, 34389, 34413, 34481, 26793, 18866, 26187, 29635, 22293, 18888, 36654, 25783, 34522, 34544, 34566, 25821, 35072, 22164, 34586, 34609, 34632, 19604, 24036, 36644, 36674, 24681, 18888, 32401, 34654, 31339, 34682, 34698, 27211, 34717, 34753, 28053, 34812, 34836, 24401, 33619, 19628, 34858, 32236, 34906, 24598, 33523, 27612, 34890, 34922, 24732, 29246, 36717, 33634, 34465, 32984, 34168, 26750, 34957, 18888, 18888, 34994, 35010, 27211, 33040, 17590, 29913, 35035, 24401, 36304, 25482, 30171, 35883, 35068, 35088, 26627, 20441, 31173, 35123, 35143, 35176, 24640, 30492, 29358, 19719, 35192, 35219, 25384, 28801, 35255, 35279, 32586, 34496, 23086, 23330, 29061, 31017, 27856, 31741, 19840, 25783, 31738, 24547, 25164, 35315, 31796, 35353, 34316, 22105, 19419, 27963, 24091, 28630, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22848, 18836, 22059, 34782, 34088, 35389, 21008, 35405, 35421, 35454, 18888, 18888, 23466, 35487, 27211, 27211, 27211, 35513, 31154, 24401, 24401, 24401, 35560, 18888, 26863, 36664, 35601, 24872, 25783, 30389, 23536, 26250, 35647, 35666, 22164, 19522, 19564, 30582, 35682, 27697, 35575, 29114, 18888, 18888, 18888, 18890, 27211, 35702, 27211, 27211, 27211, 35723, 24401, 35527, 24401, 24401, 24401, 19628, 30184, 18888, 18888, 18888, 23086, 35739, 27211, 27211, 27211, 29139, 22938, 24401, 24401, 24401, 24401, 23898, 35756, 18888, 18888, 25025, 35778, 27211, 27211, 17590, 20064, 35795, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 23917, 18890, 34550, 31833, 22262, 19447, 23086, 23330, 26418, 31017, 27856, 31741, 19840, 25783, 35812, 19837, 27187, 35841, 33135, 23516, 31008, 22105, 22148, 28712, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22863, 18836, 22059, 35877, 28723, 34097, 31164, 29183, 22087, 26758, 18888, 22592, 18890, 23989, 27211, 29812, 27211, 22121, 33778, 24401, 31421, 24401, 18866, 18888, 18888, 26872, 18888, 18888, 25783, 27211, 30732, 27211, 27211, 35072, 22164, 24401, 24908, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22878, 18836, 22059, 27837, 27857, 35899, 24401, 35915, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31602, 18888, 18888, 18888, 18888, 26223, 27211, 27211, 27211, 27211, 27211, 19484, 35931, 24401, 24401, 24401, 24401, 19628, 18888, 28136, 18888, 18888, 35949, 27211, 32862, 27211, 32697, 30756, 24012, 24401, 32283, 24401, 32128, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22893, 18836, 22059, 35974, 34882, 34097, 33960, 29183, 35996, 18888, 23311, 18888, 36029, 27211, 27211, 36064, 36081, 22121, 24401, 24401, 36104, 33950, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 36121, 18888, 25559, 18888, 18888, 18890, 27211, 27211, 30313, 27211, 27211, 36154, 24401, 24401, 34397, 24401, 24401, 19628, 28250, 18888, 18888, 18888, 23086, 30926, 27211, 27211, 27211, 26983, 24012, 33642, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 19354, 27857, 36190, 24401, 36206, 22087, 18888, 18888, 18888, 18007, 27211, 27211, 27211, 24724, 22121, 24401, 24401, 24401, 30827, 18866, 18888, 36222, 18888, 28795, 18888, 25783, 35100, 27211, 27429, 27211, 35072, 22164, 30836, 24401, 24499, 24401, 24036, 31693, 18888, 36244, 18888, 18888, 18890, 27211, 36088, 27211, 27211, 27211, 19484, 24401, 28036, 24401, 24401, 24401, 19628, 18888, 18888, 35631, 18888, 35762, 27211, 27211, 36277, 27211, 34730, 24012, 24401, 24401, 36300, 24401, 36320, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 25712, 18888, 18888, 36346, 27211, 27212, 19184, 24402, 19868, 25659, 32029, 18889, 27211, 33359, 19719, 23889, 36369, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22384, 18836, 36389, 19008, 19233, 20367, 36434, 17173, 17595, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 36453, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 20362, 21726, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22369, 18836, 18987, 19008, 19233, 20367, 19008, 21737, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21813, 18836, 36489, 19008, 19233, 20367, 19008, 17173, 17737, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17768, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 20543, 22022, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21828, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 36517, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21828, 18836, 19307, 18888, 27857, 30756, 24401, 29183, 28015, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 36567, 24401, 24401, 24401, 24401, 22953, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 36603, 24401, 24401, 24401, 24401, 24036, 18881, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 36629, 36690, 18720, 19008, 19233, 20367, 19008, 17454, 17595, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17223, 17308, 17327, 17346, 18918, 36754, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 20362, 21726, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 0, 94242, 0, 118820, 0, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2482176, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 2207744, 2404352, 2412544, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3104768, 2605056, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2678784, 2207744, 2695168, 2207744, 2703360, 2207744, 2711552, 2752512, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 3170304, 3174400, 2158592, 0, 139, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 2748416, 2756608, 2777088, 2801664, 2158592, 2158592, 2158592, 2863104, 2891776, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3104768, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2785280, 2207744, 2809856, 2207744, 2207744, 2842624, 2207744, 2207744, 2207744, 2899968, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2473984, 2207744, 2207744, 2494464, 2207744, 2207744, 2207744, 2523136, 2158592, 2404352, 2412544, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2564096, 2158592, 2158592, 2605056, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2678784, 2158592, 2695168, 2158592, 2703360, 2158592, 2711552, 2752512, 2158592, 2158592, 2785280, 2158592, 2158592, 2785280, 2158592, 2809856, 2158592, 2158592, 2842624, 2158592, 2158592, 2158592, 2899968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 641, 0, 2158592, 0, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 32768, 0, 2158592, 0, 2158592, 2158592, 2158592, 2383872, 2158592, 2158592, 2158592, 2158592, 3006464, 2383872, 2207744, 2207744, 2207744, 2207744, 2158877, 2158877, 2158877, 2158877, 0, 0, 0, 2158877, 2572573, 2158877, 2158877, 0, 2207744, 2207744, 2596864, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2641920, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 167936, 0, 0, 2162688, 0, 0, 3104768, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2146304, 2146304, 2224128, 2224128, 2232320, 2232320, 2232320, 641, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2531328, 2158592, 2158592, 2158592, 2158592, 2158592, 2617344, 2158592, 2158592, 2158592, 2158592, 2441216, 2445312, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2502656, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2580480, 2158592, 2158592, 2158592, 2158592, 2621440, 2158592, 2580480, 2158592, 2158592, 2158592, 2158592, 2621440, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2699264, 2158592, 2158592, 2158592, 2158592, 2158592, 2748416, 2756608, 2777088, 2801664, 2207744, 2863104, 2891776, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3018752, 2207744, 3043328, 2207744, 2207744, 2207744, 2207744, 3080192, 2207744, 2207744, 3112960, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 172310, 279, 0, 2162688, 0, 0, 2207744, 2207744, 2207744, 3186688, 2207744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2404352, 2412544, 2158592, 2510848, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2584576, 2158592, 2609152, 2158592, 2158592, 2629632, 2158592, 2158592, 2158592, 2686976, 2158592, 2715648, 2158592, 2158592, 3121152, 2158592, 2158592, 2158592, 3149824, 2158592, 2158592, 3170304, 3174400, 2158592, 2367488, 2207744, 2207744, 2207744, 2207744, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2572288, 2158592, 2158592, 0, 2207744, 2207744, 2207744, 2433024, 2207744, 2453504, 2461696, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2510848, 2207744, 2207744, 2207744, 2207744, 2207744, 2531328, 2207744, 2207744, 2207744, 2207744, 2207744, 2617344, 2207744, 2207744, 2207744, 2207744, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2572288, 2158592, 2158592, 1508, 2715648, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2867200, 2207744, 2904064, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2580480, 2207744, 2207744, 2207744, 2207744, 2621440, 2207744, 2207744, 2207744, 3149824, 2207744, 2207744, 3170304, 3174400, 2207744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 138, 2158592, 2158592, 2158592, 2404352, 2412544, 2707456, 2732032, 2207744, 2207744, 2207744, 2822144, 2826240, 2207744, 2895872, 2207744, 2207744, 2924544, 2207744, 2207744, 2973696, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 285, 2158592, 2158592, 3112960, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 2207744, 2207744, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 0, 0, 2535424, 2543616, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 2990080, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2572288, 2981888, 2207744, 2207744, 3002368, 2207744, 3047424, 3063808, 3076096, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3203072, 2708960, 2732032, 2158592, 2158592, 2158592, 2822144, 2827748, 2158592, 2895872, 2158592, 2158592, 2924544, 2158592, 2158592, 2973696, 2158592, 2981888, 2158592, 2158592, 3002368, 2158592, 3047424, 3063808, 3076096, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3203072, 2981888, 2158592, 2158592, 3003876, 2158592, 3047424, 3063808, 3076096, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3203072, 2207744, 2207744, 2207744, 2207744, 2207744, 2424832, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 20480, 0, 0, 0, 0, 0, 2162688, 20480, 0, 2523136, 2527232, 2158592, 2158592, 2576384, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2908160, 2527232, 2207744, 2207744, 2576384, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2908160, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 286, 2158592, 2158592, 0, 0, 2158592, 2158592, 2158592, 2158592, 2633728, 2658304, 0, 0, 2740224, 2744320, 0, 2834432, 2207744, 2207744, 2977792, 2207744, 2207744, 2207744, 2207744, 3039232, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3158016, 0, 0, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 933, 45, 45, 45, 45, 442, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 2494464, 2158592, 2158592, 2158592, 2524757, 2527232, 2158592, 2158592, 2576384, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 1504, 2158592, 2498560, 2158592, 2158592, 2158592, 2158592, 2568192, 2158592, 2592768, 2625536, 2158592, 2158592, 2674688, 2736128, 2158592, 2158592, 0, 2158592, 2912256, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3108864, 2158592, 2158592, 3133440, 3145728, 3153920, 2375680, 2379776, 2207744, 2207744, 2420736, 2207744, 2449408, 2207744, 2207744, 2207744, 2498560, 2207744, 2207744, 2207744, 2207744, 2568192, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 551, 2158592, 2158592, 2158592, 2158592, 2207744, 2506752, 2207744, 2207744, 2207744, 2207744, 2207744, 2158592, 2506752, 0, 2020, 2158592, 2592768, 2625536, 2207744, 2207744, 2674688, 2736128, 2207744, 2207744, 2207744, 2912256, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 542, 0, 544, 2207744, 3108864, 2207744, 2207744, 3133440, 3145728, 3153920, 2375680, 2379776, 2158592, 2158592, 2420736, 2158592, 2449408, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 641, 0, 0, 0, 0, 0, 0, 2367488, 2158592, 2498560, 2158592, 2158592, 1621, 2158592, 2158592, 2568192, 2158592, 2592768, 2625536, 2158592, 2158592, 2674688, 0, 0, 0, 0, 0, 1608, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1107, 97, 97, 1110, 97, 97, 3133440, 3145728, 3153920, 2158592, 2408448, 2416640, 2158592, 2465792, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3014656, 2158592, 2158592, 3051520, 2158592, 2158592, 3100672, 2158592, 2158592, 3121152, 2158592, 2158592, 2158592, 3149824, 2416640, 2207744, 2465792, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2633728, 2658304, 2740224, 2744320, 2834432, 2949120, 2158592, 2985984, 2158592, 2998272, 2158592, 2158592, 2158592, 3129344, 2207744, 2408448, 2949120, 2207744, 2985984, 2207744, 2998272, 2207744, 2207744, 2207744, 3129344, 2158592, 2408448, 2416640, 2158592, 2465792, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 32768, 0, 0, 0, 0, 0, 0, 2367488, 2949120, 2158592, 2985984, 2158592, 2998272, 2158592, 2158592, 2158592, 3129344, 2158592, 2158592, 2478080, 2158592, 2158592, 2158592, 2535424, 2543616, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3117056, 2207744, 2207744, 2478080, 2207744, 2207744, 2207744, 2207744, 2699264, 2207744, 2207744, 2207744, 2207744, 2207744, 2748416, 2756608, 2777088, 2801664, 2207744, 2207744, 2158877, 2158877, 2158877, 2158877, 2158877, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 0, 0, 2535709, 2543901, 2158877, 2158877, 2158877, 0, 0, 0, 2158877, 2158877, 2158877, 2990365, 2158877, 2158877, 2158730, 2158730, 2158730, 2158730, 2158730, 2572426, 2207744, 2535424, 2543616, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3117056, 2158592, 2158592, 2478080, 2207744, 2207744, 2990080, 2207744, 2207744, 2158592, 2158592, 2482176, 2158592, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 0, 2158592, 2908160, 2158592, 2158592, 2158592, 2977792, 2158592, 2158592, 2158592, 2158592, 3039232, 2158592, 2158592, 3010560, 2207744, 2428928, 2207744, 2514944, 2207744, 2588672, 2207744, 2838528, 2207744, 2207744, 2207744, 3010560, 2158592, 2428928, 2158592, 2514944, 0, 0, 2158592, 2588672, 2158592, 0, 2838528, 2158592, 2158592, 2158592, 3010560, 2158592, 2506752, 2158592, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 0, 29315, 922, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1539, 45, 3006464, 2383872, 0, 2020, 2158592, 2158592, 2158592, 2158592, 3006464, 2158592, 2637824, 2953216, 2158592, 2207744, 2637824, 2953216, 2207744, 0, 0, 2158592, 2637824, 2953216, 2158592, 2539520, 2158592, 2539520, 2207744, 0, 0, 2539520, 2158592, 2158592, 2158592, 2158592, 2207744, 2506752, 2207744, 2207744, 2207744, 2207744, 2207744, 2158592, 2506752, 0, 0, 2158592, 2207744, 0, 2158592, 2158592, 2207744, 0, 2158592, 2158592, 2207744, 0, 2158592, 2965504, 2965504, 2965504, 0, 0, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2474269, 2158877, 2158877, 0, 0, 2158877, 2158877, 2158877, 2158877, 2634013, 2658589, 0, 0, 2740509, 2744605, 0, 2834717, 40976, 18, 36884, 45078, 24, 28, 90143, 94242, 118820, 102439, 106538, 98347, 118820, 118820, 118820, 40976, 18, 18, 36884, 0, 0, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 86016, 0, 0, 2211840, 102439, 0, 0, 0, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 3158016, 0, 2375680, 2379776, 2158592, 2158592, 2420736, 2158592, 2449408, 2158592, 2158592, 0, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 135, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2564096, 2158592, 2158592, 2158592, 2158592, 2158592, 2596864, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2641920, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2781184, 2793472, 2494464, 2158592, 2158592, 2158592, 2523136, 2527232, 2158592, 2158592, 2576384, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 0, 27, 27, 0, 2158592, 2498560, 2158592, 2158592, 0, 2158592, 2158592, 2568192, 2158592, 2592768, 2625536, 2158592, 2158592, 2674688, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2473984, 2158592, 2158592, 2494464, 2158592, 2158592, 2158592, 3006464, 2383872, 0, 0, 2158592, 2158592, 2158592, 2158592, 3006464, 2158592, 2637824, 2953216, 2158592, 2207744, 2637824, 2953216, 40976, 18, 36884, 45078, 24, 27, 147488, 94242, 147456, 147488, 106538, 98347, 0, 0, 147456, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 0, 81920, 0, 94242, 0, 0, 0, 2211840, 0, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2428928, 2158592, 2514944, 2158592, 2588672, 2158592, 2838528, 2158592, 2158592, 40976, 18, 151573, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 0, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 1315, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1487, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 0, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 130, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3096576, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2207744, 2158592, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 644, 2207744, 2207744, 2207744, 3186688, 2207744, 0, 1080, 0, 1084, 0, 1088, 0, 0, 0, 0, 0, 0, 0, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2531466, 2158730, 2158730, 2158730, 2158730, 2158730, 2617482, 0, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2781184, 2793472, 2158592, 2818048, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 40976, 18, 36884, 45078, 24, 27, 90143, 159779, 159744, 102439, 159779, 98347, 0, 0, 159744, 40976, 18, 18, 36884, 0, 45078, 0, 2224253, 172032, 2224253, 2232448, 2232448, 172032, 2232448, 90143, 0, 0, 2170880, 0, 0, 550, 829, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 124, 124, 127, 127, 127, 40976, 18, 36884, 45078, 25, 29, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 163931, 40976, 18, 18, 36884, 0, 45078, 249856, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 2170880, 0, 0, 827, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 4243810, 4243810, 24, 24, 27, 27, 27, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 57344, 286, 2158592, 2158592, 2158592, 2158592, 2707456, 2732032, 2158592, 2158592, 2158592, 2822144, 2826240, 2158592, 2895872, 2158592, 2158592, 2924544, 2158592, 2158592, 2973696, 2158592, 2207744, 2207744, 2207744, 3186688, 2207744, 0, 0, 0, 0, 0, 0, 53248, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 1613, 97, 97, 97, 97, 97, 97, 1495, 97, 97, 97, 97, 97, 97, 97, 97, 97, 566, 97, 97, 97, 97, 97, 97, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 546, 0, 0, 0, 0, 286, 2158592, 2158592, 2158592, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 17, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 20480, 120, 121, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 2170880, 0, 53248, 550, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 196608, 18, 266240, 24, 24, 27, 27, 27, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 0, 45, 45, 45, 45, 45, 45, 45, 1535, 45, 45, 45, 45, 45, 45, 45, 1416, 45, 45, 45, 45, 45, 45, 45, 45, 424, 45, 45, 45, 45, 45, 45, 45, 45, 45, 405, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 199, 45, 45, 67, 67, 67, 67, 67, 491, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1766, 67, 67, 67, 1767, 67, 24850, 24850, 12564, 12564, 0, 0, 2166784, 546, 0, 53531, 53531, 0, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 743, 57889, 0, 2170880, 0, 0, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1856, 45, 1858, 1859, 67, 67, 67, 1009, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1021, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2367773, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2699549, 2158877, 2158877, 2158877, 2158877, 2158877, 2748701, 2756893, 2777373, 2801949, 97, 1115, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 857, 97, 67, 67, 67, 67, 67, 1258, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1826, 67, 97, 97, 97, 97, 97, 97, 1338, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 870, 97, 97, 67, 67, 67, 1463, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1579, 67, 67, 97, 97, 97, 1518, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 904, 905, 97, 97, 97, 97, 1620, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 0, 0, 0, 0, 0, 45, 1679, 67, 67, 67, 1682, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1690, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 669, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 189, 45, 45, 45, 1748, 45, 45, 45, 1749, 1750, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1959, 67, 67, 67, 67, 1768, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1791, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1802, 67, 1817, 67, 67, 67, 67, 67, 67, 1823, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 97, 1848, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 659, 45, 45, 45, 45, 45, 45, 45, 1863, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 495, 67, 67, 67, 67, 67, 1878, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 1973, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1165, 97, 1167, 67, 24850, 24850, 12564, 12564, 0, 0, 2166784, 0, 0, 53531, 53531, 0, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1789, 97, 0, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 136, 2158592, 2158592, 2158592, 2158592, 2158592, 3158016, 229376, 2375680, 2379776, 2158592, 2158592, 2420736, 2158592, 2449408, 2158592, 2158592, 67, 24850, 24850, 12564, 12564, 0, 0, 280, 547, 0, 53531, 53531, 0, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 1788, 97, 97, 0, 97, 2024, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 235, 67, 67, 67, 67, 67, 57889, 547, 547, 0, 0, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1799, 45, 45, 45, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 1092, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1612, 97, 97, 97, 97, 1616, 97, 1297, 1472, 0, 0, 0, 0, 1303, 1474, 0, 0, 0, 0, 1309, 1476, 0, 0, 0, 0, 97, 97, 97, 1481, 97, 97, 97, 97, 97, 97, 1488, 97, 0, 1474, 0, 1476, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 607, 97, 97, 97, 97, 40976, 18, 36884, 45078, 26, 30, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 213080, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 143448, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 0, 0, 0, 0, 97, 97, 97, 97, 1482, 97, 1483, 97, 97, 97, 97, 97, 97, 1326, 97, 97, 1329, 1330, 97, 97, 97, 97, 97, 97, 1159, 1160, 97, 97, 97, 97, 97, 97, 97, 97, 590, 97, 97, 97, 97, 97, 97, 97, 0, 94242, 0, 0, 0, 2211974, 102439, 0, 0, 106538, 98347, 0, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2474122, 2158730, 2158730, 2494602, 2158730, 2158730, 2158730, 2809994, 2158730, 2158730, 2842762, 2158730, 2158730, 2158730, 2900106, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3014794, 2158730, 2158730, 3051658, 2158730, 2158730, 3100810, 2158730, 2158730, 2158730, 2158730, 3096714, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2207744, 2207744, 2207744, 2207744, 2207744, 2572288, 2207744, 2207744, 2207744, 2207744, 541, 541, 543, 543, 0, 0, 2166784, 0, 548, 549, 549, 0, 286, 2158877, 2158877, 2158877, 2863389, 2892061, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3186973, 2158877, 0, 0, 0, 0, 0, 0, 0, 0, 2367626, 2158877, 2404637, 2412829, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2564381, 2158877, 2158877, 2605341, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2679069, 2158877, 2695453, 2158877, 2703645, 2158877, 2711837, 2752797, 2158877, 0, 2158877, 2158877, 2158877, 2384010, 2158730, 2158730, 2158730, 2158730, 3006602, 2383872, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3096576, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 0, 0, 2158877, 2785565, 2158877, 2810141, 2158877, 2158877, 2842909, 2158877, 2158877, 2158877, 2900253, 2158877, 2158877, 2158877, 2158877, 2158877, 2531613, 2158877, 2158877, 2158877, 2158877, 2158877, 2617629, 2158877, 2158877, 2158877, 2158877, 2158730, 2818186, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3105053, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 0, 0, 0, 0, 0, 97, 97, 97, 1611, 97, 97, 97, 97, 97, 97, 97, 1496, 97, 97, 1499, 97, 97, 97, 97, 97, 2441354, 2445450, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2502794, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2433162, 2158730, 2453642, 2461834, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2580618, 2158730, 2158730, 2158730, 2158730, 2621578, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2699402, 2158730, 2158730, 2158730, 2158730, 2678922, 2158730, 2695306, 2158730, 2703498, 2158730, 2711690, 2752650, 2158730, 2158730, 2785418, 2158730, 2158730, 2158730, 3113098, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3186826, 2158730, 2207744, 2207744, 2207744, 2207744, 2781184, 2793472, 2207744, 2818048, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 541, 0, 543, 2158877, 2502941, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2580765, 2158877, 2158877, 2158877, 2158877, 2621725, 2158877, 3019037, 2158877, 3043613, 2158877, 2158877, 2158877, 2158877, 3080477, 2158877, 2158877, 3113245, 2158877, 2158877, 2158877, 2158877, 0, 2158877, 2908445, 2158877, 2158877, 2158877, 2978077, 2158877, 2158877, 2158877, 2158877, 3039517, 2158877, 2158730, 2510986, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2584714, 2158730, 2609290, 2158730, 2158730, 2629770, 2158730, 2158730, 2158730, 2388106, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2605194, 2158730, 2158730, 2158730, 2158730, 2687114, 2158730, 2715786, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2867338, 2158730, 2904202, 2158730, 2158730, 2158730, 2642058, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2781322, 2793610, 2158730, 3121290, 2158730, 2158730, 2158730, 3149962, 2158730, 2158730, 3170442, 3174538, 2158730, 2367488, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2441216, 2445312, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2502656, 2158877, 2433309, 2158877, 2453789, 2461981, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2511133, 2158877, 2158877, 2158877, 2158877, 2584861, 2158877, 2609437, 2158877, 2158877, 2629917, 2158877, 2158877, 2158877, 2687261, 2158877, 2715933, 2158877, 2158730, 2158730, 2973834, 2158730, 2982026, 2158730, 2158730, 3002506, 2158730, 3047562, 3063946, 3076234, 2158730, 2158730, 2158730, 2158730, 2207744, 2506752, 2207744, 2207744, 2207744, 2207744, 2207744, 2158877, 2507037, 0, 0, 2158877, 2158730, 2158730, 2158730, 3203210, 2207744, 2207744, 2207744, 2207744, 2207744, 2424832, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2564096, 2207744, 2207744, 2207744, 2707741, 2732317, 2158877, 2158877, 2158877, 2822429, 2826525, 2158877, 2896157, 2158877, 2158877, 2924829, 2158877, 2158877, 2973981, 2158877, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 642, 0, 2158592, 0, 45, 1529, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1755, 45, 67, 67, 2982173, 2158877, 2158877, 3002653, 2158877, 3047709, 3064093, 3076381, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3203357, 2523274, 2527370, 2158730, 2158730, 2576522, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2908298, 2494749, 2158877, 2158877, 2158877, 2523421, 2527517, 2158877, 2158877, 2576669, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 0, 40976, 0, 18, 18, 4321280, 2224253, 2232448, 4329472, 2232448, 2158730, 2498698, 2158730, 2158730, 2158730, 2158730, 2568330, 2158730, 2592906, 2625674, 2158730, 2158730, 2674826, 2736266, 2158730, 2158730, 2158730, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2158730, 2912394, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3109002, 2158730, 2158730, 3133578, 3145866, 3154058, 2375680, 2207744, 3108864, 2207744, 2207744, 3133440, 3145728, 3153920, 2375965, 2380061, 2158877, 2158877, 2421021, 2158877, 2449693, 2158877, 2158877, 2158877, 3117341, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3104906, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158877, 2498845, 2158877, 2158877, 0, 2158877, 2158877, 2568477, 2158877, 2593053, 2625821, 2158877, 2158877, 2674973, 0, 0, 0, 0, 97, 97, 1480, 97, 97, 97, 97, 97, 1485, 97, 97, 97, 0, 97, 97, 1729, 97, 1731, 97, 97, 97, 97, 97, 97, 97, 311, 97, 97, 97, 97, 97, 97, 97, 97, 1520, 97, 97, 1523, 97, 97, 1526, 97, 2736413, 2158877, 2158877, 0, 2158877, 2912541, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3109149, 2158877, 2158877, 3014941, 2158877, 2158877, 3051805, 2158877, 2158877, 3100957, 2158877, 2158877, 3121437, 2158877, 2158877, 2158877, 3150109, 3133725, 3146013, 3154205, 2158730, 2408586, 2416778, 2158730, 2465930, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3018890, 2158730, 3043466, 2158730, 2158730, 2158730, 2158730, 3080330, 2633866, 2658442, 2740362, 2744458, 2834570, 2949258, 2158730, 2986122, 2158730, 2998410, 2158730, 2158730, 2158730, 3129482, 2207744, 2408448, 2949120, 2207744, 2985984, 2207744, 2998272, 2207744, 2207744, 2207744, 3129344, 2158877, 2408733, 2416925, 2158877, 2466077, 2158877, 2158877, 3170589, 3174685, 2158877, 0, 0, 0, 2158730, 2158730, 2158730, 2158730, 2158730, 2424970, 2158730, 2158730, 2158730, 2158730, 2707594, 2732170, 2158730, 2158730, 2158730, 2822282, 2826378, 2158730, 2896010, 2158730, 2158730, 2924682, 2949405, 2158877, 2986269, 2158877, 2998557, 2158877, 2158877, 2158877, 3129629, 2158730, 2158730, 2478218, 2158730, 2158730, 2158730, 2535562, 2543754, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3117194, 2207744, 2207744, 2478080, 2207744, 2207744, 2207744, 2207744, 3014656, 2207744, 2207744, 3051520, 2207744, 2207744, 3100672, 2207744, 2207744, 3121152, 2207744, 2207744, 2207744, 2207744, 2207744, 2584576, 2207744, 2609152, 2207744, 2207744, 2629632, 2207744, 2207744, 2207744, 2686976, 2207744, 2207744, 2535424, 2543616, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3117056, 2158877, 2158877, 2478365, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158730, 2158730, 2482314, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2207744, 2207744, 2207744, 2387968, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 823, 0, 825, 2158730, 2158730, 2158730, 2990218, 2158730, 2158730, 2207744, 2207744, 2482176, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 135, 0, 2207744, 2207744, 2990080, 2207744, 2207744, 2158877, 2158877, 2482461, 2158877, 2158877, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2158730, 2429066, 2158730, 2515082, 2158730, 2588810, 2158730, 2838666, 2158730, 2158730, 2158730, 3010698, 2207744, 2428928, 2207744, 2514944, 2207744, 2588672, 2207744, 2838528, 2207744, 2207744, 2207744, 3010560, 2158877, 2429213, 2158877, 2515229, 0, 0, 2158877, 2588957, 2158877, 0, 2838813, 2158877, 2158877, 2158877, 3010845, 2158730, 2506890, 2158730, 2158730, 2158730, 2748554, 2756746, 2777226, 2801802, 2158730, 2158730, 2158730, 2863242, 2891914, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2564234, 2158730, 2158730, 2158730, 2158730, 2158730, 2597002, 2158730, 2158730, 2158730, 3006464, 2384157, 0, 0, 2158877, 2158877, 2158877, 2158877, 3006749, 2158730, 2637962, 2953354, 2158730, 2207744, 2637824, 2953216, 2207744, 0, 0, 2158877, 2638109, 2953501, 2158877, 2539658, 2158730, 2539520, 2207744, 0, 0, 2539805, 2158877, 2158730, 2158730, 2158730, 2977930, 2158730, 2158730, 2158730, 2158730, 3039370, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3158154, 2207744, 0, 2158877, 2158730, 2207744, 0, 2158877, 2158730, 2207744, 0, 2158877, 2965642, 2965504, 2965789, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1484, 97, 97, 97, 97, 2158592, 18, 0, 122880, 0, 0, 0, 77824, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 356, 0, 0, 0, 0, 0, 0, 28809, 0, 139, 45, 45, 45, 45, 45, 45, 1751, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1427, 67, 67, 67, 67, 67, 1432, 67, 67, 67, 3104768, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 122880, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 1322, 550, 0, 286, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 24, 4329472, 27, 27, 2207744, 2207744, 2977792, 2207744, 2207744, 2207744, 2207744, 3039232, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3158016, 542, 0, 0, 0, 542, 0, 544, 0, 0, 0, 544, 0, 550, 0, 0, 0, 0, 0, 97, 97, 1610, 97, 97, 97, 97, 97, 97, 97, 97, 898, 97, 97, 97, 97, 97, 97, 97, 0, 94242, 0, 0, 0, 2211840, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 237568, 102439, 106538, 98347, 0, 0, 20480, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 192512, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 94, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 96, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 12378, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 126, 126, 126, 126, 90143, 0, 0, 2170880, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 20480, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 241664, 102439, 106538, 98347, 0, 0, 20568, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 200797, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 20480, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 0, 0, 44, 0, 0, 20575, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 41, 41, 41, 0, 0, 1126400, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 0, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 89, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 131201, 27, 27, 90143, 0, 0, 2170880, 0, 0, 550, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2441216, 2445312, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 94242, 0, 0, 208896, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 0, 0, 0, 0, 0, 0, 0, 2367488, 32768, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2433024, 2158592, 2453504, 2461696, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2510848, 2158592, 2158592, 2158592, 2158592, 40976, 18, 36884, 245783, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 20480, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 221184, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 180224, 40976, 18, 18, 36884, 155648, 45078, 0, 24, 24, 217088, 27, 27, 27, 217088, 90143, 0, 0, 2170880, 0, 0, 828, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2207744, 2207744, 2387968, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 233472, 0, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 45, 45, 718, 45, 45, 45, 45, 45, 45, 45, 45, 45, 727, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 45, 1808, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 97, 97, 0, 0, 97, 67, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 1787, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 2029, 45, 67, 67, 67, 67, 2033, 57889, 0, 0, 54074, 54074, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 1798, 45, 45, 1800, 45, 45, 0, 1472, 0, 0, 0, 0, 0, 1474, 0, 0, 0, 0, 0, 1476, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 1320, 97, 97, 0, 0, 97, 97, 97, 97, 1786, 97, 0, 0, 97, 97, 0, 1790, 1527, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 663, 67, 24850, 24850, 12564, 12564, 0, 57889, 281, 0, 0, 53531, 53531, 367, 286, 97, 97, 0, 0, 97, 97, 97, 1785, 97, 97, 0, 0, 97, 97, 0, 97, 97, 1979, 97, 97, 45, 45, 1983, 45, 1984, 45, 45, 45, 45, 45, 652, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 690, 45, 45, 694, 45, 45, 40976, 19, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 262144, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 46, 67, 98, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 45, 67, 97, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 258048, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 1122423, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 1114152, 1114152, 1114152, 0, 0, 1114112, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 37, 102439, 106538, 98347, 0, 0, 204800, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 57436, 40976, 18, 36884, 45078, 24, 27, 33, 33, 0, 33, 33, 33, 0, 0, 0, 40976, 18, 18, 36884, 0, 45078, 0, 124, 124, 124, 127, 127, 127, 127, 90143, 0, 0, 2170880, 0, 0, 550, 0, 2158877, 2158877, 2158877, 2388253, 2158877, 2158877, 2158877, 2158877, 2158877, 2781469, 2793757, 2158877, 2818333, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2867485, 2158877, 2904349, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3096861, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2441501, 2445597, 2158877, 2158877, 2158877, 2158877, 2158877, 40976, 122, 123, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 936, 2158592, 4243810, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 935, 45, 45, 45, 715, 45, 45, 45, 45, 45, 45, 45, 723, 45, 45, 45, 45, 45, 1182, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 430, 45, 45, 45, 45, 45, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 47, 68, 99, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 48, 69, 100, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 49, 70, 101, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 50, 71, 102, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 51, 72, 103, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 52, 73, 104, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 53, 74, 105, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 54, 75, 106, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 55, 76, 107, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 56, 77, 108, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 57, 78, 109, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 58, 79, 110, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 59, 80, 111, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 60, 81, 112, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 61, 82, 113, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 62, 83, 114, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 63, 84, 115, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 64, 85, 116, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 65, 86, 117, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 66, 87, 118, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 118820, 102439, 106538, 98347, 118820, 118820, 118820, 40976, 18, 18, 0, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 1314, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 1321, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 0, 367, 0, 0, 1315, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1360, 97, 97, 131, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 145, 149, 45, 45, 45, 45, 45, 174, 45, 179, 45, 185, 45, 188, 45, 45, 202, 67, 255, 67, 67, 269, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 292, 296, 97, 97, 97, 97, 97, 321, 97, 326, 97, 332, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 646, 335, 97, 97, 349, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 437, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 523, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 511, 67, 67, 67, 97, 97, 97, 620, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1501, 1502, 97, 793, 67, 67, 796, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 808, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 2052, 67, 67, 67, 67, 813, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 830, 97, 97, 97, 97, 97, 97, 97, 97, 97, 315, 97, 97, 97, 97, 97, 97, 841, 97, 97, 97, 97, 97, 97, 97, 97, 97, 854, 97, 97, 97, 97, 97, 97, 589, 97, 97, 97, 97, 97, 97, 97, 97, 97, 867, 97, 97, 97, 97, 97, 97, 97, 891, 97, 97, 894, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 906, 45, 937, 45, 45, 940, 45, 45, 45, 45, 45, 45, 948, 45, 45, 45, 45, 45, 734, 735, 67, 737, 67, 738, 67, 740, 67, 67, 67, 45, 967, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 435, 45, 45, 45, 980, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 415, 45, 45, 67, 67, 1024, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 67, 67, 67, 67, 67, 25398, 1081, 13112, 1085, 54074, 1089, 0, 0, 0, 0, 0, 0, 363, 0, 28809, 0, 139, 45, 45, 45, 45, 45, 45, 1674, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1913, 67, 1914, 67, 67, 67, 1918, 67, 67, 97, 97, 97, 97, 1118, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 630, 97, 97, 97, 97, 97, 1169, 97, 97, 97, 97, 97, 0, 921, 0, 1175, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1534, 45, 45, 45, 45, 45, 1538, 45, 45, 45, 45, 1233, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 742, 67, 45, 45, 1191, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 454, 67, 67, 67, 67, 1243, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1251, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 2050, 0, 97, 97, 45, 45, 45, 732, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 67, 67, 67, 1284, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 772, 67, 67, 67, 1293, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 368, 2158592, 2158592, 2158592, 2404352, 2412544, 1323, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1331, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1737, 97, 1364, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1373, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 647, 45, 45, 1387, 45, 45, 1391, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 410, 45, 45, 45, 45, 45, 1400, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1407, 45, 45, 45, 45, 45, 941, 45, 943, 45, 45, 45, 45, 45, 45, 951, 45, 67, 1438, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1447, 67, 67, 67, 67, 67, 67, 782, 67, 67, 67, 67, 67, 67, 67, 67, 67, 756, 67, 67, 67, 67, 67, 67, 97, 1491, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1500, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1736, 97, 45, 45, 1541, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 677, 45, 45, 67, 1581, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 791, 792, 67, 67, 67, 67, 1598, 67, 1600, 67, 67, 67, 67, 67, 67, 67, 67, 1472, 97, 97, 97, 1727, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1513, 97, 97, 67, 67, 97, 1879, 97, 1881, 97, 0, 1884, 0, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 1842, 97, 97, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1928, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1903, 45, 45, 45, 67, 67, 67, 67, 97, 97, 97, 97, 1971, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 1381, 45, 45, 45, 45, 1976, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1747, 809, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 97, 907, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 638, 0, 0, 0, 0, 1478, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1150, 97, 97, 97, 97, 67, 67, 67, 67, 1244, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 477, 67, 67, 67, 67, 67, 67, 1294, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1324, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 1374, 97, 97, 97, 97, 0, 1175, 0, 45, 45, 45, 45, 45, 45, 45, 45, 945, 45, 45, 45, 45, 45, 45, 45, 45, 1908, 45, 45, 1910, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1919, 67, 0, 0, 97, 97, 97, 97, 45, 2048, 67, 2049, 0, 0, 97, 2051, 45, 45, 45, 939, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 397, 45, 45, 45, 1921, 67, 67, 1923, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1947, 45, 1935, 0, 0, 0, 97, 1939, 97, 97, 1941, 97, 45, 45, 45, 45, 45, 45, 382, 389, 45, 45, 45, 45, 45, 45, 45, 45, 1810, 45, 45, 1812, 67, 67, 67, 67, 67, 256, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 336, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 371, 373, 45, 45, 45, 955, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 413, 45, 45, 45, 457, 459, 67, 67, 67, 67, 67, 67, 67, 67, 473, 67, 478, 67, 67, 482, 67, 67, 485, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 1828, 97, 554, 556, 97, 97, 97, 97, 97, 97, 97, 97, 570, 97, 575, 97, 97, 579, 97, 97, 582, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 330, 97, 97, 67, 746, 67, 67, 67, 67, 67, 67, 67, 67, 67, 758, 67, 67, 67, 67, 67, 67, 67, 1575, 67, 67, 67, 67, 67, 67, 67, 67, 493, 67, 67, 67, 67, 67, 67, 67, 97, 97, 844, 97, 97, 97, 97, 97, 97, 97, 97, 97, 856, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1735, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 1642, 97, 1644, 97, 97, 890, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 67, 67, 67, 67, 1065, 1066, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 532, 67, 67, 67, 67, 67, 67, 67, 1451, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 496, 67, 67, 97, 97, 1505, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 593, 97, 97, 0, 1474, 0, 1476, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1617, 97, 97, 1635, 0, 1637, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 885, 97, 97, 97, 97, 67, 67, 1704, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 565, 572, 97, 97, 97, 97, 97, 97, 97, 97, 1832, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1946, 45, 45, 67, 67, 67, 67, 67, 97, 1926, 97, 1927, 97, 0, 0, 0, 97, 97, 1934, 2043, 0, 0, 97, 97, 97, 2047, 45, 45, 67, 67, 0, 1832, 97, 97, 45, 45, 45, 981, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1227, 45, 45, 45, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 372, 45, 45, 45, 45, 1661, 1662, 45, 45, 45, 45, 45, 1666, 45, 45, 45, 45, 45, 1673, 45, 1675, 45, 45, 45, 45, 45, 45, 45, 67, 1426, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1275, 67, 67, 67, 67, 67, 45, 418, 45, 45, 420, 45, 45, 423, 45, 45, 45, 45, 45, 45, 45, 45, 959, 45, 45, 962, 45, 45, 45, 45, 458, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 483, 67, 67, 67, 67, 504, 67, 67, 506, 67, 67, 509, 67, 67, 67, 67, 67, 67, 67, 528, 67, 67, 67, 67, 67, 67, 67, 67, 1287, 67, 67, 67, 67, 67, 67, 67, 555, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 580, 97, 97, 97, 97, 601, 97, 97, 603, 97, 97, 606, 97, 97, 97, 97, 97, 97, 848, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1498, 97, 97, 97, 97, 97, 97, 45, 45, 714, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 989, 990, 45, 67, 67, 67, 67, 67, 1011, 67, 67, 67, 67, 1015, 67, 67, 67, 67, 67, 67, 67, 753, 67, 67, 67, 67, 67, 67, 67, 67, 467, 67, 67, 67, 67, 67, 67, 67, 45, 45, 1179, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1003, 1004, 67, 1217, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 728, 67, 1461, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1034, 67, 97, 1516, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 871, 97, 67, 67, 67, 1705, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 567, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1715, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 1380, 45, 45, 45, 45, 45, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 1887, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 2006, 45, 45, 1907, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1920, 67, 97, 0, 2035, 97, 97, 97, 97, 97, 45, 45, 45, 45, 67, 67, 67, 1428, 67, 67, 67, 67, 67, 67, 1435, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 146, 45, 152, 45, 45, 165, 45, 175, 45, 180, 45, 45, 187, 190, 195, 45, 203, 254, 257, 262, 67, 270, 67, 67, 0, 24850, 12564, 0, 0, 0, 281, 28809, 53531, 97, 97, 97, 293, 97, 299, 97, 97, 312, 97, 322, 97, 327, 97, 97, 334, 337, 342, 97, 350, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 67, 484, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 499, 97, 581, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 596, 648, 45, 650, 45, 651, 45, 653, 45, 45, 45, 657, 45, 45, 45, 45, 45, 45, 1954, 67, 67, 67, 1958, 67, 67, 67, 67, 67, 67, 67, 768, 67, 67, 67, 67, 67, 67, 67, 67, 769, 67, 67, 67, 67, 67, 67, 67, 680, 45, 45, 45, 45, 45, 45, 45, 45, 688, 689, 691, 45, 45, 45, 45, 45, 983, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 947, 45, 45, 45, 45, 952, 45, 45, 698, 699, 45, 45, 702, 703, 45, 45, 45, 45, 45, 45, 45, 711, 744, 67, 67, 67, 67, 67, 67, 67, 67, 67, 757, 67, 67, 67, 67, 761, 67, 67, 67, 67, 765, 67, 767, 67, 67, 67, 67, 67, 67, 67, 67, 775, 776, 778, 67, 67, 67, 67, 67, 67, 785, 786, 67, 67, 789, 790, 67, 67, 67, 67, 67, 67, 1442, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1775, 97, 97, 97, 67, 67, 67, 67, 67, 798, 67, 67, 67, 802, 67, 67, 67, 67, 67, 67, 67, 67, 1465, 67, 67, 1468, 67, 67, 1471, 67, 67, 810, 67, 67, 67, 67, 67, 67, 67, 67, 67, 821, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 0, 833, 97, 835, 97, 836, 97, 838, 97, 97, 0, 0, 97, 97, 97, 2002, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1740, 45, 45, 45, 1744, 45, 45, 45, 97, 842, 97, 97, 97, 97, 97, 97, 97, 97, 97, 855, 97, 97, 97, 97, 0, 1717, 1718, 97, 97, 97, 97, 97, 1722, 97, 0, 0, 859, 97, 97, 97, 97, 863, 97, 865, 97, 97, 97, 97, 97, 97, 97, 97, 604, 97, 97, 97, 97, 97, 97, 97, 873, 874, 876, 97, 97, 97, 97, 97, 97, 883, 884, 97, 97, 887, 888, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 225280, 0, 365, 0, 367, 0, 45, 45, 45, 1531, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1199, 45, 45, 45, 45, 45, 97, 97, 908, 97, 97, 97, 97, 97, 97, 97, 97, 97, 919, 638, 0, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2425117, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2597149, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2642205, 2158877, 2158877, 2158877, 2158877, 2158877, 3158301, 0, 2375818, 2379914, 2158730, 2158730, 2420874, 2158730, 2449546, 2158730, 2158730, 953, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 965, 978, 45, 45, 45, 45, 45, 45, 985, 45, 45, 45, 45, 45, 45, 45, 45, 971, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1027, 67, 1029, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1455, 67, 67, 67, 67, 67, 67, 67, 1077, 1078, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 0, 366, 0, 139, 2158730, 2158730, 2158730, 2404490, 2412682, 1113, 97, 97, 97, 97, 97, 97, 1121, 97, 1123, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1540, 1155, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 615, 1168, 97, 97, 1171, 1172, 97, 97, 0, 921, 0, 1175, 0, 0, 0, 0, 45, 45, 45, 45, 45, 1533, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1663, 45, 45, 45, 45, 45, 45, 45, 45, 45, 183, 45, 45, 45, 45, 201, 45, 45, 45, 1219, 45, 45, 45, 45, 45, 45, 45, 1226, 45, 45, 45, 45, 45, 168, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 427, 45, 45, 45, 45, 45, 45, 45, 1231, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1242, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1046, 67, 67, 1254, 67, 1256, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 806, 807, 67, 67, 97, 1336, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1111, 97, 97, 97, 97, 97, 1351, 97, 97, 97, 1354, 97, 97, 97, 1359, 97, 97, 97, 0, 97, 97, 97, 97, 1640, 97, 97, 97, 97, 97, 97, 97, 897, 97, 97, 97, 902, 97, 97, 97, 97, 97, 97, 97, 97, 1366, 97, 97, 97, 97, 97, 97, 97, 1371, 97, 97, 97, 0, 97, 97, 97, 1730, 97, 97, 97, 97, 97, 97, 97, 97, 915, 97, 97, 97, 97, 0, 360, 0, 67, 67, 67, 1440, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1017, 67, 1019, 67, 67, 67, 67, 67, 1453, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1459, 97, 97, 97, 1493, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1525, 97, 97, 97, 97, 97, 97, 1507, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1514, 67, 67, 67, 67, 1584, 67, 67, 67, 67, 67, 1590, 67, 67, 67, 67, 67, 67, 67, 783, 67, 67, 67, 788, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1599, 1601, 67, 67, 67, 1604, 67, 1606, 1607, 67, 1472, 0, 1474, 0, 1476, 0, 97, 97, 97, 97, 97, 97, 1614, 97, 97, 97, 97, 45, 45, 1850, 45, 45, 45, 45, 1855, 45, 45, 45, 45, 45, 1222, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1229, 97, 1618, 97, 97, 97, 97, 97, 97, 97, 1625, 97, 97, 97, 97, 97, 0, 1175, 0, 45, 45, 45, 45, 45, 45, 45, 45, 447, 45, 45, 45, 45, 45, 67, 67, 1633, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1643, 1645, 97, 97, 0, 0, 97, 97, 1784, 97, 97, 97, 0, 0, 97, 97, 0, 97, 1894, 1895, 97, 1897, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 656, 45, 45, 45, 45, 45, 45, 97, 1648, 97, 1650, 1651, 97, 0, 45, 45, 45, 1654, 45, 45, 45, 45, 45, 169, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 658, 45, 45, 45, 45, 664, 45, 45, 1659, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1187, 45, 45, 1669, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1005, 67, 67, 1681, 67, 67, 67, 67, 67, 67, 67, 1686, 67, 67, 67, 67, 67, 67, 67, 784, 67, 67, 67, 67, 67, 67, 67, 67, 1055, 67, 67, 67, 67, 1060, 67, 67, 97, 97, 1713, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 1378, 45, 45, 45, 45, 45, 45, 45, 408, 45, 45, 45, 45, 45, 45, 45, 45, 1547, 45, 1549, 45, 45, 45, 45, 45, 97, 97, 1780, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 2027, 2028, 45, 45, 67, 67, 2031, 2032, 67, 45, 45, 1804, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1917, 67, 67, 67, 67, 67, 67, 67, 1819, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1708, 97, 97, 97, 97, 97, 45, 45, 1862, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 497, 67, 67, 67, 1877, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 1839, 0, 0, 97, 97, 97, 97, 1936, 0, 0, 97, 97, 97, 97, 97, 97, 1943, 1944, 1945, 45, 45, 45, 45, 670, 45, 45, 45, 45, 674, 45, 45, 45, 45, 678, 45, 1948, 45, 1950, 45, 45, 45, 45, 1955, 1956, 1957, 67, 67, 67, 1960, 67, 1962, 67, 67, 67, 67, 1967, 1968, 1969, 97, 0, 0, 0, 97, 97, 1974, 97, 0, 1936, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1906, 0, 1977, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1746, 45, 45, 45, 45, 2011, 67, 67, 2013, 67, 67, 67, 2017, 97, 97, 0, 0, 2021, 97, 8192, 97, 97, 2025, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1916, 67, 67, 67, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 140, 45, 45, 45, 1180, 45, 45, 45, 45, 1184, 45, 45, 45, 45, 45, 45, 45, 387, 45, 392, 45, 45, 396, 45, 45, 399, 45, 45, 67, 207, 67, 67, 67, 67, 67, 67, 236, 67, 67, 67, 67, 67, 67, 67, 800, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1603, 67, 67, 67, 67, 67, 0, 97, 97, 287, 97, 97, 97, 97, 97, 97, 316, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 1656, 1657, 45, 376, 45, 45, 45, 45, 45, 388, 45, 45, 45, 45, 45, 45, 45, 45, 1406, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 462, 67, 67, 67, 67, 67, 474, 67, 67, 67, 67, 67, 67, 67, 817, 67, 67, 67, 67, 25398, 542, 13112, 544, 97, 97, 97, 97, 559, 97, 97, 97, 97, 97, 571, 97, 97, 97, 97, 97, 97, 896, 97, 97, 97, 900, 97, 97, 97, 97, 97, 97, 912, 914, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 391, 45, 45, 45, 45, 45, 45, 45, 45, 713, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 662, 45, 1140, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 636, 67, 67, 1283, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 513, 67, 67, 1363, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 889, 97, 97, 97, 1714, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 926, 45, 45, 45, 45, 45, 45, 45, 45, 672, 45, 45, 45, 45, 45, 45, 45, 45, 686, 45, 45, 45, 45, 45, 45, 45, 45, 944, 45, 45, 45, 45, 45, 45, 45, 45, 1676, 45, 45, 45, 45, 45, 45, 67, 97, 97, 97, 1833, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1902, 45, 45, 45, 45, 45, 957, 45, 45, 45, 45, 961, 45, 963, 45, 45, 45, 67, 97, 2034, 0, 97, 97, 97, 97, 97, 2040, 45, 45, 45, 2042, 67, 67, 67, 67, 67, 67, 1574, 67, 67, 67, 67, 67, 1578, 67, 67, 67, 67, 67, 67, 799, 67, 67, 67, 804, 67, 67, 67, 67, 67, 67, 67, 1298, 0, 0, 0, 1304, 0, 0, 0, 1310, 132, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 45, 45, 1414, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 428, 45, 45, 45, 45, 45, 57889, 0, 0, 54074, 54074, 550, 831, 97, 97, 97, 97, 97, 97, 97, 97, 97, 568, 97, 97, 97, 97, 578, 97, 45, 45, 968, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1228, 45, 45, 67, 67, 67, 67, 67, 25398, 1082, 13112, 1086, 54074, 1090, 0, 0, 0, 0, 0, 0, 364, 0, 0, 0, 139, 2158592, 2158592, 2158592, 2404352, 2412544, 67, 67, 67, 67, 1464, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 510, 67, 67, 67, 67, 97, 97, 97, 97, 1519, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 918, 97, 0, 0, 0, 0, 1528, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 976, 45, 1554, 45, 45, 45, 45, 45, 45, 45, 45, 1562, 45, 45, 1565, 45, 45, 45, 45, 683, 45, 45, 45, 687, 45, 45, 692, 45, 45, 45, 45, 45, 1953, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1014, 67, 67, 67, 67, 67, 67, 1568, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 67, 67, 67, 67, 67, 1585, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1594, 97, 97, 1649, 97, 97, 97, 0, 45, 45, 1653, 45, 45, 45, 45, 45, 45, 383, 45, 45, 45, 45, 45, 45, 45, 45, 45, 986, 45, 45, 45, 45, 45, 45, 45, 45, 1670, 45, 1672, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 736, 67, 67, 67, 67, 67, 741, 67, 67, 67, 1680, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1074, 67, 67, 67, 1692, 67, 67, 67, 67, 67, 67, 67, 1697, 67, 1699, 67, 67, 67, 67, 67, 67, 1012, 67, 67, 67, 67, 67, 67, 67, 67, 67, 468, 475, 67, 67, 67, 67, 67, 67, 1769, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 624, 97, 97, 97, 97, 97, 97, 634, 97, 97, 1792, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 958, 45, 45, 45, 45, 45, 45, 964, 45, 150, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 977, 204, 45, 67, 67, 67, 217, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 787, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 271, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 97, 351, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 45, 938, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1398, 45, 45, 45, 153, 45, 161, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 660, 661, 45, 45, 205, 45, 67, 67, 67, 67, 220, 67, 228, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 280, 94, 0, 0, 67, 67, 67, 67, 67, 272, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 97, 352, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 439, 45, 45, 45, 45, 45, 445, 45, 45, 45, 452, 45, 45, 67, 67, 212, 216, 67, 67, 67, 67, 67, 241, 67, 246, 67, 252, 67, 67, 486, 67, 67, 67, 67, 67, 67, 67, 494, 67, 67, 67, 67, 67, 67, 67, 1245, 67, 67, 67, 67, 67, 67, 67, 67, 1013, 67, 67, 1016, 67, 67, 67, 67, 67, 521, 67, 67, 525, 67, 67, 67, 67, 67, 531, 67, 67, 67, 538, 67, 0, 0, 2046, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 1192, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1418, 45, 45, 1421, 97, 97, 583, 97, 97, 97, 97, 97, 97, 97, 591, 97, 97, 97, 97, 97, 97, 913, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 1384, 97, 618, 97, 97, 622, 97, 97, 97, 97, 97, 628, 97, 97, 97, 635, 97, 18, 131427, 0, 0, 0, 639, 0, 132, 362, 0, 0, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 932, 45, 45, 45, 45, 45, 1544, 45, 45, 45, 45, 45, 1550, 45, 45, 45, 45, 45, 1194, 45, 1196, 45, 45, 45, 45, 45, 45, 45, 45, 999, 45, 45, 45, 45, 45, 67, 67, 45, 45, 667, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1408, 45, 45, 45, 696, 45, 45, 45, 701, 45, 45, 45, 45, 45, 45, 45, 45, 710, 45, 45, 45, 1220, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 194, 45, 45, 45, 729, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 797, 67, 67, 67, 67, 67, 67, 805, 67, 67, 67, 67, 67, 67, 67, 1587, 67, 1589, 67, 67, 67, 67, 67, 67, 67, 67, 1763, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 2162968, 0, 0, 67, 67, 67, 67, 67, 814, 816, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 67, 67, 1008, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1020, 67, 0, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 67, 67, 67, 67, 1429, 67, 1430, 67, 67, 67, 67, 67, 1062, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 518, 1076, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 0, 28809, 0, 139, 45, 45, 45, 45, 45, 97, 97, 97, 97, 1102, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1124, 97, 1126, 97, 97, 1114, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1112, 97, 97, 1156, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 594, 97, 97, 97, 97, 1170, 97, 97, 97, 97, 0, 921, 0, 0, 0, 0, 0, 0, 45, 45, 45, 45, 1532, 45, 45, 45, 45, 1536, 45, 45, 45, 45, 45, 172, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 706, 45, 45, 709, 45, 45, 1177, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1202, 45, 1204, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1215, 45, 45, 45, 1232, 45, 45, 45, 45, 45, 45, 45, 67, 1237, 67, 67, 67, 67, 67, 67, 1053, 1054, 67, 67, 67, 67, 67, 67, 1061, 67, 67, 1282, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1289, 67, 67, 67, 1292, 97, 97, 97, 97, 1339, 97, 97, 97, 97, 97, 97, 1344, 97, 97, 97, 97, 45, 1849, 45, 1851, 45, 45, 45, 45, 45, 45, 45, 45, 721, 45, 45, 45, 45, 45, 726, 45, 1385, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1188, 45, 45, 1401, 1402, 45, 45, 45, 45, 1405, 45, 45, 45, 45, 45, 45, 45, 45, 1752, 45, 45, 45, 45, 45, 67, 67, 1410, 45, 45, 45, 1413, 45, 1415, 45, 45, 45, 45, 45, 45, 1419, 45, 45, 45, 45, 1806, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 97, 97, 2019, 0, 97, 67, 67, 67, 1452, 67, 67, 67, 67, 67, 67, 67, 67, 1457, 67, 67, 67, 67, 67, 67, 1259, 67, 67, 67, 67, 67, 67, 1264, 67, 67, 1460, 67, 1462, 67, 67, 67, 67, 67, 67, 1466, 67, 67, 67, 67, 67, 67, 67, 67, 1588, 67, 67, 67, 67, 67, 67, 67, 0, 1300, 0, 0, 0, 1306, 0, 0, 0, 97, 97, 97, 1506, 97, 97, 97, 97, 97, 97, 97, 97, 1512, 97, 97, 97, 0, 1728, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 901, 97, 97, 97, 97, 1515, 97, 1517, 97, 97, 97, 97, 97, 97, 1521, 97, 97, 97, 97, 97, 97, 0, 45, 1652, 45, 45, 45, 1655, 45, 45, 45, 45, 45, 1542, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1552, 1553, 45, 45, 45, 1556, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 693, 45, 45, 45, 67, 67, 67, 67, 1572, 67, 67, 67, 67, 1576, 67, 67, 67, 67, 67, 67, 67, 67, 1602, 67, 67, 1605, 67, 67, 67, 0, 67, 1582, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1580, 67, 67, 1596, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 542, 0, 544, 67, 67, 67, 67, 1759, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 533, 67, 67, 67, 67, 67, 67, 67, 1770, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 1777, 97, 97, 97, 1793, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 998, 45, 45, 1001, 1002, 45, 45, 67, 67, 45, 1861, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1871, 67, 1873, 1874, 67, 0, 97, 45, 67, 0, 97, 45, 67, 16384, 97, 45, 67, 97, 0, 0, 0, 1473, 0, 1082, 0, 0, 0, 1475, 0, 1086, 0, 0, 0, 1477, 1876, 67, 97, 97, 97, 97, 97, 1883, 0, 1885, 97, 97, 97, 1889, 0, 0, 0, 286, 0, 0, 0, 286, 0, 2367488, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 24, 126, 126, 126, 2053, 0, 2055, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 97, 97, 2039, 97, 45, 45, 45, 45, 67, 67, 67, 67, 67, 226, 67, 67, 67, 67, 67, 67, 67, 67, 1246, 67, 67, 1249, 1250, 67, 67, 67, 132, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 141, 45, 45, 45, 1403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1186, 45, 45, 1189, 45, 45, 155, 45, 45, 45, 45, 45, 45, 45, 45, 45, 191, 45, 45, 45, 45, 700, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1753, 45, 45, 45, 67, 67, 45, 45, 67, 208, 67, 67, 67, 222, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1764, 67, 67, 67, 67, 67, 67, 67, 258, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 288, 97, 97, 97, 302, 97, 97, 97, 97, 97, 97, 97, 97, 97, 627, 97, 97, 97, 97, 97, 97, 338, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 370, 45, 45, 45, 45, 716, 45, 45, 45, 45, 45, 722, 45, 45, 45, 45, 45, 45, 1912, 67, 67, 67, 67, 67, 67, 67, 67, 67, 819, 67, 67, 25398, 542, 13112, 544, 45, 403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1409, 45, 67, 67, 67, 67, 489, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 771, 67, 67, 67, 67, 520, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 534, 67, 67, 67, 67, 67, 67, 1271, 67, 67, 67, 1274, 67, 67, 67, 1279, 67, 67, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 97, 553, 97, 97, 97, 97, 586, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1138, 97, 97, 97, 97, 617, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 631, 97, 97, 97, 0, 1834, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 353, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 45, 668, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 724, 45, 45, 45, 45, 45, 682, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 949, 45, 45, 45, 67, 67, 747, 748, 67, 67, 67, 67, 755, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 1302, 0, 0, 0, 1308, 0, 67, 794, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1701, 67, 97, 97, 97, 845, 846, 97, 97, 97, 97, 853, 97, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 97, 97, 892, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 610, 97, 97, 45, 992, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1239, 67, 67, 67, 1063, 67, 67, 67, 67, 67, 1068, 67, 67, 67, 67, 67, 67, 67, 0, 0, 1301, 0, 0, 0, 1307, 0, 0, 97, 1141, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1152, 97, 97, 0, 0, 97, 97, 2001, 0, 97, 2003, 97, 97, 97, 45, 45, 45, 1739, 45, 45, 45, 1742, 45, 45, 45, 45, 45, 97, 97, 97, 97, 1157, 97, 97, 97, 97, 97, 1162, 97, 97, 97, 97, 97, 97, 1145, 97, 97, 97, 97, 97, 1151, 97, 97, 97, 1253, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 539, 45, 1423, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1431, 67, 67, 67, 67, 67, 67, 67, 1695, 67, 67, 67, 67, 67, 1700, 67, 1702, 67, 67, 1439, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 514, 67, 67, 97, 97, 1492, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 611, 97, 97, 1703, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 852, 97, 97, 97, 97, 97, 97, 45, 1949, 45, 1951, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1961, 67, 0, 97, 45, 67, 0, 97, 2060, 2061, 0, 2062, 45, 67, 97, 0, 0, 2036, 97, 97, 97, 97, 45, 45, 45, 45, 67, 67, 67, 67, 67, 223, 67, 67, 237, 67, 67, 67, 67, 67, 67, 67, 1272, 67, 67, 67, 67, 67, 67, 67, 67, 507, 67, 67, 67, 67, 67, 67, 67, 1963, 67, 67, 67, 97, 97, 97, 97, 0, 1972, 0, 97, 97, 97, 1975, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 931, 45, 45, 45, 45, 45, 407, 45, 45, 45, 45, 45, 45, 45, 45, 45, 417, 45, 45, 1989, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1996, 97, 18, 131427, 0, 0, 360, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 930, 45, 45, 45, 45, 45, 45, 444, 45, 45, 45, 45, 45, 45, 45, 67, 67, 97, 97, 1998, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1985, 45, 1986, 45, 45, 45, 156, 45, 45, 170, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 675, 45, 45, 45, 45, 679, 131427, 0, 358, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 381, 45, 45, 45, 45, 45, 45, 45, 45, 45, 400, 45, 45, 419, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 436, 67, 67, 67, 67, 67, 505, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 820, 67, 25398, 542, 13112, 544, 67, 67, 522, 67, 67, 67, 67, 67, 529, 67, 67, 67, 67, 67, 67, 67, 0, 1299, 0, 0, 0, 1305, 0, 0, 0, 97, 97, 619, 97, 97, 97, 97, 97, 626, 97, 97, 97, 97, 97, 97, 97, 1105, 97, 97, 97, 97, 1109, 97, 97, 97, 67, 67, 67, 67, 749, 67, 67, 67, 67, 67, 67, 67, 67, 67, 760, 67, 0, 97, 45, 67, 2058, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 2041, 67, 67, 67, 67, 67, 780, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 516, 67, 67, 97, 97, 97, 878, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1629, 97, 0, 45, 979, 45, 45, 45, 45, 984, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1198, 45, 45, 45, 45, 45, 45, 67, 1023, 67, 67, 67, 67, 1028, 67, 67, 67, 67, 67, 67, 67, 67, 67, 470, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 1094, 0, 0, 0, 1092, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1486, 97, 1489, 97, 97, 97, 1117, 97, 97, 97, 97, 1122, 97, 97, 97, 97, 97, 97, 97, 1146, 97, 97, 97, 97, 97, 97, 97, 97, 881, 97, 97, 97, 886, 97, 97, 97, 1311, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1615, 97, 97, 97, 97, 97, 1619, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1631, 97, 97, 1847, 97, 45, 45, 45, 45, 1852, 45, 45, 45, 45, 45, 45, 45, 1235, 45, 45, 45, 67, 67, 67, 67, 67, 1868, 67, 67, 67, 1872, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1882, 0, 0, 0, 97, 97, 97, 97, 0, 1891, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 1929, 0, 0, 97, 97, 97, 97, 97, 97, 45, 1900, 45, 1901, 45, 45, 45, 1905, 45, 67, 2054, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 2037, 2038, 97, 97, 45, 45, 45, 45, 67, 67, 67, 67, 1867, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1774, 97, 97, 97, 97, 97, 97, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 142, 45, 45, 45, 1412, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 432, 45, 45, 45, 45, 45, 157, 45, 45, 171, 45, 45, 45, 182, 45, 45, 45, 45, 200, 45, 45, 45, 1543, 45, 45, 45, 45, 45, 45, 45, 45, 1551, 45, 45, 45, 45, 1181, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1211, 45, 45, 45, 1214, 45, 45, 45, 67, 209, 67, 67, 67, 224, 67, 67, 238, 67, 67, 67, 249, 67, 0, 97, 2056, 2057, 0, 2059, 45, 67, 0, 97, 45, 67, 97, 0, 0, 1937, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1741, 45, 45, 45, 45, 45, 45, 67, 67, 67, 267, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 289, 97, 97, 97, 304, 97, 97, 318, 97, 97, 97, 329, 97, 97, 0, 0, 97, 1783, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 2026, 45, 45, 45, 45, 67, 2030, 67, 67, 67, 67, 67, 67, 1041, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1044, 67, 67, 67, 67, 67, 67, 97, 97, 347, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 666, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1420, 45, 57889, 0, 0, 54074, 54074, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 840, 67, 1007, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 759, 67, 67, 67, 67, 67, 67, 67, 1052, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1031, 67, 67, 67, 67, 67, 97, 97, 97, 1101, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 592, 97, 97, 97, 1190, 45, 45, 45, 45, 45, 1195, 45, 1197, 45, 45, 45, 45, 1201, 45, 45, 45, 45, 1952, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 250, 67, 67, 67, 1255, 67, 1257, 67, 67, 67, 67, 1261, 67, 67, 67, 67, 67, 67, 67, 67, 1685, 67, 67, 67, 67, 67, 67, 67, 0, 24851, 12565, 0, 0, 0, 0, 28809, 53532, 67, 67, 1267, 67, 67, 67, 67, 67, 67, 1273, 67, 67, 67, 67, 67, 67, 67, 67, 1696, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 2162688, 0, 0, 1281, 67, 67, 67, 67, 1285, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1070, 67, 67, 67, 67, 67, 1335, 97, 1337, 97, 97, 97, 97, 1341, 97, 97, 97, 97, 97, 97, 97, 97, 882, 97, 97, 97, 97, 97, 97, 97, 1347, 97, 97, 97, 97, 97, 97, 1353, 97, 97, 97, 97, 97, 97, 1361, 97, 18, 131427, 0, 638, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 544, 0, 550, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2473984, 2158592, 2158592, 2158592, 2990080, 2158592, 2158592, 2207744, 2207744, 2482176, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 0, 53530, 97, 97, 97, 1365, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 608, 97, 97, 97, 45, 45, 1424, 45, 1425, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1058, 67, 67, 67, 67, 45, 1555, 45, 45, 1557, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 707, 45, 45, 45, 45, 67, 67, 1570, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 773, 67, 67, 1595, 67, 67, 1597, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139, 2158592, 2158592, 2158592, 2404352, 2412544, 97, 97, 97, 1636, 97, 97, 97, 1639, 97, 97, 1641, 97, 97, 97, 97, 97, 97, 1173, 0, 921, 0, 0, 0, 0, 0, 0, 45, 67, 67, 67, 1693, 67, 67, 67, 67, 67, 67, 67, 1698, 67, 67, 67, 67, 67, 67, 67, 1773, 67, 97, 97, 97, 97, 97, 97, 97, 625, 97, 97, 97, 97, 97, 97, 97, 97, 850, 97, 97, 97, 97, 97, 97, 97, 97, 880, 97, 97, 97, 97, 97, 97, 97, 97, 1106, 97, 97, 97, 97, 97, 97, 97, 1860, 45, 45, 67, 67, 1865, 67, 67, 67, 67, 1870, 67, 67, 67, 67, 1875, 67, 67, 97, 97, 1880, 97, 97, 0, 0, 0, 97, 97, 1888, 97, 0, 0, 0, 1938, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1854, 45, 45, 45, 45, 45, 45, 45, 1909, 45, 45, 1911, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1248, 67, 67, 67, 67, 67, 67, 1922, 67, 67, 1924, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 1898, 45, 45, 45, 45, 45, 45, 1904, 45, 45, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 16384, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 1724, 2008, 2009, 45, 45, 67, 67, 67, 2014, 2015, 67, 67, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 2022, 0, 2023, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1869, 67, 67, 67, 67, 67, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 147, 151, 154, 45, 162, 45, 45, 176, 178, 181, 45, 45, 45, 192, 196, 45, 45, 45, 45, 2012, 67, 67, 67, 67, 67, 67, 2018, 97, 0, 0, 97, 1978, 97, 97, 97, 1982, 45, 45, 45, 45, 45, 45, 45, 45, 45, 972, 973, 45, 45, 45, 45, 45, 67, 259, 263, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 294, 298, 301, 97, 309, 97, 97, 323, 325, 328, 97, 97, 97, 97, 97, 560, 97, 97, 97, 569, 97, 97, 97, 97, 97, 97, 306, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1624, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 1175, 0, 0, 0, 0, 45, 339, 343, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 67, 67, 503, 67, 67, 67, 67, 67, 67, 67, 67, 67, 512, 67, 67, 519, 97, 97, 600, 97, 97, 97, 97, 97, 97, 97, 97, 97, 609, 97, 97, 616, 45, 649, 45, 45, 45, 45, 45, 654, 45, 45, 45, 45, 45, 45, 45, 45, 1393, 45, 45, 45, 45, 45, 45, 45, 45, 1209, 45, 45, 45, 45, 45, 45, 45, 67, 763, 67, 67, 67, 67, 67, 67, 67, 67, 770, 67, 67, 67, 774, 67, 0, 2045, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 994, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 213, 67, 219, 67, 67, 232, 67, 242, 67, 247, 67, 67, 67, 779, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1018, 67, 67, 67, 67, 811, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 0, 97, 834, 97, 97, 97, 97, 97, 839, 97, 18, 131427, 0, 638, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 645, 97, 97, 861, 97, 97, 97, 97, 97, 97, 97, 97, 868, 97, 97, 97, 872, 97, 97, 877, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 613, 97, 97, 97, 97, 97, 909, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 18, 18, 24, 24, 27, 27, 27, 1036, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1047, 67, 67, 67, 1050, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1033, 67, 67, 67, 97, 97, 1130, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 638, 0, 0, 67, 67, 67, 1295, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 1317, 97, 97, 97, 97, 97, 97, 1375, 97, 97, 97, 0, 0, 0, 45, 1379, 45, 45, 45, 45, 45, 45, 422, 45, 45, 45, 429, 431, 45, 45, 45, 45, 0, 1090, 0, 0, 97, 1479, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1357, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1716, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1723, 0, 921, 29315, 0, 0, 0, 0, 45, 929, 45, 45, 45, 45, 45, 45, 45, 1392, 45, 45, 45, 45, 45, 45, 45, 45, 45, 960, 45, 45, 45, 45, 45, 45, 97, 97, 97, 1738, 45, 45, 45, 45, 45, 45, 45, 1743, 45, 45, 45, 45, 166, 45, 45, 45, 45, 184, 186, 45, 45, 197, 45, 45, 97, 1779, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 18, 131427, 0, 638, 0, 0, 0, 0, 362, 0, 640, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1537, 45, 45, 45, 45, 45, 1803, 45, 45, 45, 45, 45, 1809, 45, 45, 45, 67, 67, 67, 1814, 67, 67, 67, 67, 67, 67, 1821, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 0, 67, 67, 67, 1818, 67, 67, 67, 67, 67, 1824, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 1890, 0, 1829, 97, 97, 0, 0, 97, 97, 1836, 97, 97, 0, 0, 0, 97, 97, 97, 97, 1981, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1987, 1845, 97, 97, 97, 45, 45, 45, 45, 45, 1853, 45, 45, 45, 1857, 45, 45, 45, 67, 1864, 67, 1866, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 1710, 1711, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 1886, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1838, 0, 0, 0, 97, 1843, 97, 0, 1893, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1745, 45, 45, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 1931, 97, 97, 97, 97, 97, 588, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 629, 97, 97, 97, 97, 97, 67, 2044, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 1660, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 453, 45, 455, 67, 67, 67, 67, 268, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 348, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 359, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 421, 45, 45, 45, 45, 45, 45, 45, 434, 45, 45, 695, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1667, 45, 0, 921, 29315, 0, 925, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1811, 45, 67, 67, 67, 67, 67, 67, 1037, 67, 1039, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1277, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 1095, 0, 0, 0, 1096, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 869, 97, 97, 97, 97, 97, 97, 1131, 97, 1133, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1370, 97, 97, 97, 97, 97, 1312, 0, 0, 0, 0, 1096, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1327, 97, 97, 97, 97, 97, 1332, 97, 97, 97, 1830, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 1896, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1548, 45, 45, 45, 45, 45, 45, 133, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 45, 380, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 401, 45, 45, 158, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1200, 45, 45, 45, 45, 206, 67, 67, 67, 67, 67, 225, 67, 67, 67, 67, 67, 67, 67, 67, 754, 67, 67, 67, 67, 67, 67, 67, 57889, 0, 0, 54074, 54074, 550, 832, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1342, 97, 97, 97, 97, 97, 97, 67, 67, 67, 67, 67, 25398, 1083, 13112, 1087, 54074, 1091, 0, 0, 0, 0, 0, 0, 1316, 0, 831, 97, 97, 97, 97, 97, 97, 97, 1174, 921, 0, 1175, 0, 0, 0, 0, 45, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 148, 67, 67, 264, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 295, 97, 97, 97, 97, 313, 97, 97, 97, 97, 331, 333, 97, 18, 131427, 356, 638, 0, 0, 0, 0, 362, 0, 0, 365, 0, 367, 0, 45, 45, 1530, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 988, 45, 45, 45, 97, 344, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 402, 404, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1756, 67, 438, 45, 45, 45, 45, 45, 45, 45, 45, 449, 450, 45, 45, 45, 67, 67, 214, 218, 221, 67, 229, 67, 67, 243, 245, 248, 67, 67, 67, 67, 67, 488, 490, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1071, 67, 1073, 67, 67, 67, 67, 67, 524, 67, 67, 67, 67, 67, 67, 67, 67, 535, 536, 67, 67, 67, 67, 67, 67, 1683, 1684, 67, 67, 67, 67, 1688, 1689, 67, 67, 67, 67, 67, 67, 1586, 67, 67, 67, 67, 67, 67, 67, 67, 67, 469, 67, 67, 67, 67, 67, 67, 97, 97, 97, 585, 587, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1163, 97, 97, 97, 97, 97, 97, 97, 621, 97, 97, 97, 97, 97, 97, 97, 97, 632, 633, 97, 97, 0, 0, 1782, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 712, 45, 45, 45, 717, 45, 45, 45, 45, 45, 45, 45, 45, 725, 45, 45, 45, 163, 167, 173, 177, 45, 45, 45, 45, 45, 193, 45, 45, 45, 45, 982, 45, 45, 45, 45, 45, 45, 987, 45, 45, 45, 45, 45, 1558, 45, 1560, 45, 45, 45, 45, 45, 45, 45, 45, 704, 705, 45, 45, 45, 45, 45, 45, 45, 45, 731, 45, 45, 45, 67, 67, 67, 67, 67, 739, 67, 67, 67, 67, 67, 67, 273, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 67, 67, 67, 764, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1290, 67, 67, 67, 67, 67, 67, 812, 67, 67, 67, 67, 818, 67, 67, 67, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 0, 97, 97, 97, 97, 97, 837, 97, 97, 97, 97, 97, 602, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1137, 97, 97, 97, 97, 97, 97, 97, 97, 97, 862, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1627, 97, 97, 97, 0, 97, 97, 97, 97, 910, 97, 97, 97, 97, 916, 97, 97, 97, 0, 0, 0, 97, 97, 1940, 97, 97, 1942, 45, 45, 45, 45, 45, 45, 385, 45, 45, 45, 45, 395, 45, 45, 45, 45, 966, 45, 969, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 975, 45, 45, 45, 406, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 974, 45, 45, 45, 67, 67, 67, 67, 1010, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1262, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1040, 67, 1042, 67, 1045, 67, 67, 67, 67, 67, 67, 67, 97, 1706, 97, 97, 97, 1709, 97, 97, 97, 67, 67, 67, 67, 1051, 67, 67, 67, 67, 67, 1057, 67, 67, 67, 67, 67, 67, 67, 1443, 67, 67, 1446, 67, 67, 67, 67, 67, 67, 67, 1297, 0, 0, 0, 1303, 0, 0, 0, 1309, 67, 67, 67, 67, 1079, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2207744, 2207744, 2207744, 2207744, 2572288, 2207744, 2207744, 2207744, 1098, 97, 97, 97, 97, 97, 1104, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1356, 97, 97, 97, 97, 97, 97, 1128, 97, 97, 97, 97, 97, 97, 1134, 97, 1136, 97, 1139, 97, 97, 97, 97, 97, 97, 1622, 97, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 0, 0, 1176, 0, 646, 45, 67, 67, 67, 1268, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1469, 67, 67, 67, 97, 1348, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1127, 97, 67, 1569, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1448, 1449, 67, 1816, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1825, 67, 67, 1827, 97, 97, 0, 1781, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 1831, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 1980, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1395, 45, 45, 45, 45, 45, 97, 1846, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1212, 45, 45, 45, 45, 45, 45, 2010, 45, 67, 67, 67, 67, 67, 2016, 67, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 2007, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 143, 45, 45, 45, 1671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1813, 67, 67, 1815, 45, 45, 67, 210, 67, 67, 67, 67, 67, 67, 239, 67, 67, 67, 67, 67, 67, 67, 1454, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1445, 67, 67, 67, 67, 67, 67, 97, 97, 290, 97, 97, 97, 97, 97, 97, 319, 97, 97, 97, 97, 97, 97, 303, 97, 97, 317, 97, 97, 97, 97, 97, 97, 305, 97, 97, 97, 97, 97, 97, 97, 97, 97, 899, 97, 97, 97, 97, 97, 97, 375, 45, 45, 45, 379, 45, 45, 390, 45, 45, 394, 45, 45, 45, 45, 45, 443, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 461, 67, 67, 67, 465, 67, 67, 476, 67, 67, 480, 67, 67, 67, 67, 67, 67, 1694, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1288, 67, 67, 67, 67, 67, 67, 500, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1075, 97, 97, 97, 558, 97, 97, 97, 562, 97, 97, 573, 97, 97, 577, 97, 97, 97, 97, 97, 895, 97, 97, 97, 97, 97, 97, 903, 97, 97, 97, 0, 97, 97, 1638, 97, 97, 97, 97, 97, 97, 97, 97, 1646, 597, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1334, 45, 681, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1396, 45, 45, 1399, 45, 45, 730, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1434, 67, 67, 67, 67, 67, 67, 750, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1456, 67, 67, 67, 67, 67, 45, 45, 993, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1238, 67, 67, 1006, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1280, 1048, 1049, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1059, 67, 67, 67, 67, 67, 67, 1286, 67, 67, 67, 67, 67, 67, 67, 1291, 67, 97, 97, 1100, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 638, 0, 920, 97, 97, 1142, 1143, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1153, 97, 97, 97, 97, 97, 1158, 97, 97, 97, 1161, 97, 97, 97, 97, 1166, 97, 97, 97, 97, 97, 1325, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1328, 97, 97, 97, 97, 97, 97, 97, 45, 1218, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1678, 45, 45, 45, 67, 67, 67, 67, 67, 1269, 67, 67, 67, 67, 67, 67, 67, 67, 1278, 67, 67, 67, 67, 67, 67, 1761, 67, 67, 67, 67, 67, 67, 67, 67, 67, 530, 67, 67, 67, 67, 67, 67, 97, 97, 1349, 97, 97, 97, 97, 97, 97, 97, 97, 1358, 97, 97, 97, 97, 97, 97, 1623, 97, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 0, 926, 0, 0, 0, 45, 45, 1411, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1754, 45, 45, 67, 67, 1301, 0, 1307, 0, 1313, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 21054, 97, 97, 97, 97, 67, 1757, 67, 67, 67, 1760, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1467, 67, 67, 67, 67, 67, 1778, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 97, 97, 1352, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1511, 97, 97, 97, 97, 97, 67, 67, 67, 67, 67, 1820, 67, 1822, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 1933, 97, 1892, 97, 97, 97, 97, 97, 97, 1899, 45, 45, 45, 45, 45, 45, 45, 45, 1664, 45, 45, 45, 45, 45, 45, 45, 45, 1546, 45, 45, 45, 45, 45, 45, 45, 45, 1208, 45, 45, 45, 45, 45, 45, 45, 45, 1224, 45, 45, 45, 45, 45, 45, 45, 45, 673, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1925, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 623, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 307, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1796, 97, 45, 45, 45, 45, 45, 45, 45, 970, 45, 45, 45, 45, 45, 45, 45, 45, 1417, 45, 45, 45, 45, 45, 45, 45, 67, 1964, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1721, 97, 97, 0, 0, 1997, 97, 0, 0, 2000, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 733, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 803, 67, 67, 67, 67, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 144, 45, 45, 45, 1805, 45, 1807, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 231, 67, 67, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 45, 45, 67, 211, 67, 67, 67, 67, 230, 234, 240, 244, 67, 67, 67, 67, 67, 67, 464, 67, 67, 67, 67, 67, 67, 479, 67, 67, 67, 260, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 291, 97, 97, 97, 97, 310, 314, 320, 324, 97, 97, 97, 97, 97, 97, 1367, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1355, 97, 97, 97, 97, 97, 97, 1362, 340, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 360, 0, 362, 0, 365, 28809, 367, 139, 369, 45, 45, 45, 374, 67, 67, 460, 67, 67, 67, 67, 466, 67, 67, 67, 67, 67, 67, 67, 67, 801, 67, 67, 67, 67, 67, 67, 67, 67, 67, 487, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 498, 67, 67, 67, 67, 67, 67, 1772, 67, 67, 97, 97, 97, 97, 97, 97, 97, 0, 921, 922, 1175, 0, 0, 0, 0, 45, 67, 502, 67, 67, 67, 67, 67, 67, 67, 508, 67, 67, 67, 515, 517, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 1932, 97, 97, 0, 1999, 97, 97, 97, 0, 97, 97, 2004, 2005, 97, 45, 45, 45, 45, 1193, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 676, 45, 45, 45, 45, 67, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 552, 97, 97, 97, 97, 97, 1377, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 655, 45, 45, 45, 45, 45, 45, 45, 97, 97, 557, 97, 97, 97, 97, 563, 97, 97, 97, 97, 97, 97, 97, 97, 1135, 97, 97, 97, 97, 97, 97, 97, 97, 97, 584, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 595, 97, 97, 97, 97, 97, 911, 97, 97, 97, 97, 97, 97, 97, 638, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 1319, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1733, 97, 97, 97, 97, 97, 97, 1340, 97, 97, 97, 1343, 97, 97, 1345, 97, 1346, 97, 599, 97, 97, 97, 97, 97, 97, 97, 605, 97, 97, 97, 612, 614, 97, 97, 97, 97, 97, 1794, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 1207, 45, 45, 45, 45, 45, 45, 1213, 45, 45, 745, 67, 67, 67, 67, 751, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1577, 67, 67, 67, 67, 67, 762, 67, 67, 67, 67, 766, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1765, 67, 67, 67, 67, 67, 777, 67, 67, 781, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1592, 1593, 67, 67, 97, 843, 97, 97, 97, 97, 849, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1510, 97, 97, 97, 97, 97, 97, 97, 860, 97, 97, 97, 97, 864, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1797, 45, 45, 45, 45, 1801, 45, 97, 875, 97, 97, 879, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1522, 97, 97, 97, 97, 97, 991, 45, 45, 45, 45, 996, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 215, 67, 67, 67, 67, 233, 67, 67, 67, 67, 251, 253, 1022, 67, 67, 67, 1026, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1035, 67, 67, 1038, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1458, 67, 67, 67, 67, 67, 1064, 67, 67, 67, 1067, 67, 67, 67, 67, 1072, 67, 67, 67, 67, 67, 67, 1296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2367488, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 1096, 0, 921, 29315, 0, 0, 0, 0, 928, 45, 45, 45, 45, 45, 934, 45, 45, 45, 164, 45, 45, 45, 45, 45, 45, 45, 45, 45, 198, 45, 45, 45, 378, 45, 45, 45, 45, 45, 45, 393, 45, 45, 45, 398, 45, 97, 97, 1116, 97, 97, 97, 1120, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1147, 1148, 97, 97, 97, 97, 97, 97, 97, 1129, 97, 97, 1132, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1626, 97, 97, 97, 97, 0, 45, 1178, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1185, 45, 45, 45, 45, 441, 45, 45, 45, 45, 45, 45, 451, 45, 45, 67, 67, 67, 67, 67, 227, 67, 67, 67, 67, 67, 67, 67, 67, 1260, 67, 67, 67, 1263, 67, 67, 1265, 1203, 45, 45, 1205, 45, 1206, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1216, 67, 1266, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1276, 67, 67, 67, 67, 67, 67, 492, 67, 67, 67, 67, 67, 67, 67, 67, 67, 471, 67, 67, 67, 67, 481, 67, 45, 1386, 45, 1389, 45, 45, 45, 45, 1394, 45, 45, 45, 1397, 45, 45, 45, 45, 995, 45, 997, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1915, 67, 67, 67, 67, 67, 1422, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1433, 67, 1436, 67, 67, 67, 67, 1441, 67, 67, 67, 1444, 67, 67, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 281, 28809, 53531, 97, 97, 97, 97, 1494, 97, 97, 97, 1497, 97, 97, 97, 97, 97, 97, 97, 1368, 97, 97, 97, 97, 97, 97, 97, 97, 851, 97, 97, 97, 97, 97, 97, 97, 67, 67, 67, 1571, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 67, 67, 1583, 67, 67, 67, 67, 67, 67, 67, 67, 1591, 67, 67, 67, 67, 67, 67, 752, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1056, 67, 67, 67, 67, 67, 67, 97, 1634, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1125, 97, 97, 97, 1647, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1183, 45, 45, 45, 45, 45, 45, 45, 45, 45, 409, 45, 45, 45, 45, 45, 45, 1658, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1668, 1712, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 1835, 97, 97, 97, 97, 0, 0, 0, 97, 97, 1844, 97, 97, 1726, 0, 97, 97, 97, 97, 97, 1732, 97, 1734, 97, 97, 97, 97, 97, 300, 97, 308, 97, 97, 97, 97, 97, 97, 97, 97, 866, 97, 97, 97, 97, 97, 97, 97, 67, 67, 67, 1758, 67, 67, 67, 1762, 67, 67, 67, 67, 67, 67, 67, 67, 1043, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1771, 67, 67, 67, 97, 97, 97, 97, 97, 1776, 97, 97, 97, 97, 297, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1108, 97, 97, 97, 97, 67, 67, 67, 1966, 97, 97, 97, 1970, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 1720, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1837, 97, 0, 1840, 1841, 97, 97, 97, 1988, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1994, 1995, 67, 97, 97, 97, 97, 97, 1103, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 917, 97, 97, 0, 0, 0, 67, 67, 265, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 345, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 0, 361, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 411, 45, 45, 414, 45, 45, 45, 45, 377, 45, 45, 45, 386, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1223, 45, 45, 45, 45, 45, 45, 45, 45, 45, 426, 45, 45, 433, 45, 45, 45, 67, 67, 67, 67, 67, 463, 67, 67, 67, 472, 67, 67, 67, 67, 67, 67, 67, 527, 67, 67, 67, 67, 67, 67, 537, 67, 540, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 97, 97, 97, 97, 97, 1119, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1509, 97, 97, 97, 97, 97, 97, 97, 97, 564, 97, 97, 97, 97, 97, 97, 97, 637, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 927, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1234, 45, 45, 45, 45, 67, 67, 67, 67, 1240, 45, 697, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 708, 45, 45, 45, 45, 1221, 45, 45, 45, 45, 1225, 45, 45, 45, 45, 45, 45, 384, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1210, 45, 45, 45, 45, 45, 45, 67, 67, 795, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1470, 67, 67, 67, 67, 67, 67, 67, 815, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 97, 97, 97, 893, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1164, 97, 97, 97, 67, 67, 67, 1025, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1687, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 1097, 1241, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1450, 45, 45, 1388, 45, 1390, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1236, 67, 67, 67, 67, 67, 1437, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1472, 1490, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1503, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 1930, 0, 97, 97, 97, 97, 97, 847, 97, 97, 97, 97, 97, 97, 97, 97, 97, 858, 67, 67, 1965, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 1719, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 1382, 45, 1383, 45, 45, 45, 159, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1563, 45, 45, 45, 45, 45, 67, 261, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 341, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 97, 1099, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1333, 97, 1230, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1992, 67, 1993, 67, 67, 67, 97, 97, 45, 45, 160, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1665, 45, 45, 45, 45, 45, 131427, 357, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 684, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 412, 45, 45, 45, 416, 45, 45, 45, 440, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1990, 67, 1991, 67, 67, 67, 67, 67, 67, 67, 97, 97, 1707, 97, 97, 97, 97, 97, 97, 501, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1691, 67, 67, 67, 67, 67, 526, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1030, 67, 1032, 67, 67, 67, 67, 598, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1632, 0, 921, 29315, 923, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1404, 45, 45, 45, 45, 45, 45, 45, 45, 45, 425, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 1093, 0, 0, 0, 0, 0, 97, 1609, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1369, 97, 97, 97, 1372, 97, 97, 67, 67, 266, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 346, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 665, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1677, 45, 45, 45, 45, 67, 45, 45, 954, 45, 956, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1545, 45, 45, 45, 45, 45, 45, 45, 45, 45, 448, 45, 45, 45, 45, 67, 456, 67, 67, 67, 67, 67, 1270, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1069, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1350, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1524, 97, 97, 97, 97, 97, 97, 97, 1376, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 1559, 1561, 45, 45, 45, 1564, 45, 1566, 1567, 45, 67, 67, 67, 67, 67, 1573, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1247, 67, 67, 67, 67, 67, 1252, 97, 1725, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1628, 97, 1630, 0, 0, 94242, 0, 0, 0, 2211840, 0, 1118208, 0, 0, 0, 0, 2158592, 2158731, 2158592, 2158592, 2158592, 3117056, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3018752, 2158592, 3043328, 2158592, 2158592, 2158592, 2158592, 3080192, 2158592, 2158592, 3112960, 2158592, 2158592, 2158592, 2158592, 2158592, 2158878, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2605056, 2158592, 2158592, 2207744, 0, 542, 0, 544, 0, 0, 2166784, 0, 0, 0, 550, 0, 0, 2158592, 2158592, 2686976, 2158592, 2715648, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2867200, 2158592, 2904064, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 94242, 0, 0, 0, 2211840, 0, 0, 1130496, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 0, 139, 0, 0, 0, 139, 0, 2367488, 2207744, 0, 0, 0, 0, 176128, 0, 2166784, 0, 0, 0, 0, 0, 286, 2158592, 2158592, 3170304, 3174400, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 1508, 2158592, 2908160, 2158592, 2158592, 2158592, 2977792, 2158592, 2158592, 2158592, 2158592, 3039232, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3158016, 67, 24850, 24850, 12564, 12564, 0, 0, 0, 0, 0, 53531, 53531, 0, 286, 97, 97, 97, 97, 97, 1144, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1149, 97, 97, 97, 97, 1154, 57889, 0, 0, 0, 0, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 561, 97, 97, 97, 97, 97, 97, 576, 97, 97, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 0, 0, 139264, 0, 921, 29315, 0, 0, 926, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 719, 720, 45, 45, 45, 45, 45, 45, 45, 45, 685, 45, 45, 45, 45, 45, 45, 45, 45, 45, 942, 45, 45, 946, 45, 45, 45, 950, 45, 45, 0, 2146304, 2146304, 0, 0, 0, 0, 2224128, 2224128, 2224128, 2232320, 2232320, 2232320, 2232320, 0, 0, 1301, 0, 0, 0, 0, 0, 1307, 0, 0, 0, 0, 0, 1313, 0, 0, 0, 0, 0, 0, 0, 97, 97, 1318, 97, 97, 97, 97, 97, 97, 1795, 97, 97, 45, 45, 45, 45, 45, 45, 45, 446, 45, 45, 45, 45, 45, 45, 67, 67, 2158592, 2146304, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 921, 29315, 0, 924, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1000, 45, 45, 45, 45, 67, 67
+];
+
+XQueryTokenizer.EXPECTED =
+[ 290, 300, 304, 353, 296, 309, 305, 319, 315, 324, 328, 352, 354, 334, 338, 330, 320, 345, 349, 293, 358, 362, 341, 366, 312, 370, 374, 378, 382, 386, 390, 394, 398, 737, 402, 634, 439, 604, 634, 634, 634, 634, 408, 634, 634, 634, 404, 634, 634, 634, 457, 634, 634, 963, 634, 634, 413, 634, 634, 634, 634, 634, 634, 634, 663, 418, 422, 903, 902, 426, 431, 548, 634, 437, 521, 919, 443, 615, 409, 449, 455, 624, 731, 751, 634, 461, 465, 672, 470, 469, 474, 481, 485, 477, 489, 493, 629, 542, 497, 505, 603, 602, 991, 648, 510, 804, 634, 515, 958, 526, 525, 530, 768, 634, 546, 552, 711, 710, 593, 558, 562, 618, 566, 570, 574, 578, 582, 586, 590, 608, 612, 660, 822, 821, 634, 622, 596, 444, 628, 533, 724, 633, 640, 653, 647, 652, 536, 1008, 451, 450, 445, 657, 670, 676, 685, 689, 693, 697, 701, 704, 707, 715, 719, 798, 815, 634, 723, 762, 996, 634, 728, 969, 730, 735, 908, 634, 741, 679, 889, 511, 747, 634, 750, 755, 499, 666, 499, 501, 759, 772, 776, 780, 634, 787, 784, 797, 802, 809, 808, 427, 814, 1006, 517, 634, 519, 853, 634, 813, 850, 793, 634, 819, 826, 833, 832, 837, 843, 847, 857, 861, 863, 867, 871, 875, 879, 883, 643, 887, 539, 980, 979, 634, 893, 944, 634, 900, 896, 634, 907, 933, 506, 912, 917, 828, 433, 636, 635, 554, 961, 923, 930, 927, 937, 941, 634, 634, 634, 974, 948, 952, 985, 913, 968, 967, 743, 634, 973, 839, 634, 978, 599, 634, 984, 989, 765, 444, 995, 1000, 634, 1003, 790, 955, 1012, 681, 634, 634, 634, 634, 634, 414, 1016, 1020, 1024, 1085, 1027, 1090, 1090, 1046, 1080, 1137, 1108, 1215, 1049, 1032, 1039, 1085, 1085, 1085, 1085, 1058, 1062, 1068, 1085, 1086, 1090, 1090, 1091, 1072, 1064, 1107, 1090, 1090, 1090, 1118, 1123, 1138, 1078, 1074, 1084, 1085, 1085, 1085, 1087, 1090, 1062, 1052, 1060, 1114, 1062, 1104, 1085, 1085, 1090, 1090, 1028, 1122, 1063, 1128, 1139, 1127, 1158, 1085, 1085, 1151, 1090, 1090, 1090, 1095, 1090, 1132, 1073, 1136, 1143, 1061, 1150, 1085, 1155, 1098, 1101, 1146, 1162, 1169, 1101, 1185, 1151, 1090, 1110, 1173, 1054, 1087, 1109, 1177, 1165, 1089, 1204, 1184, 1107, 1189, 1193, 1088, 1197, 1180, 1201, 1208, 1042, 1212, 1219, 1223, 1227, 1231, 1235, 1245, 1777, 1527, 1686, 1686, 1238, 1686, 1254, 1686, 1686, 1686, 1294, 1669, 1686, 1686, 1686, 1322, 1625, 1534, 1268, 1624, 1275, 1281, 1443, 1292, 1300, 1686, 1686, 1686, 1350, 1826, 1306, 1686, 1686, 1240, 2032, 1317, 1321, 1686, 1686, 1253, 1686, 1326, 1686, 1686, 1686, 1418, 1709, 1446, 1686, 1686, 1686, 1492, 1686, 1295, 1447, 1686, 1686, 1258, 1686, 1736, 1686, 1686, 1520, 1355, 1686, 1288, 1348, 1361, 1686, 1359, 1686, 1364, 1498, 1368, 1302, 1362, 1381, 1389, 1395, 1486, 1686, 1371, 1377, 1370, 1686, 1375, 1382, 1384, 1402, 1408, 1385, 1383, 1619, 1413, 1423, 1428, 1433, 1686, 1686, 1270, 1686, 1338, 1686, 1440, 1686, 1686, 1686, 1499, 1465, 1686, 1686, 1686, 1639, 1473, 1884, 1686, 1686, 1293, 1864, 1686, 1686, 1296, 1321, 1483, 1686, 1686, 1686, 1646, 1686, 1748, 1496, 1686, 1418, 1675, 1686, 1418, 1702, 1686, 1418, 1981, 1686, 1429, 1409, 1427, 1504, 1692, 1686, 1686, 1313, 1448, 1651, 1508, 1686, 1686, 1340, 1686, 1903, 1686, 1686, 1435, 1513, 1686, 1283, 1287, 1519, 1686, 1524, 1363, 1568, 1938, 1539, 1566, 1579, 1479, 1533, 1538, 1553, 1544, 1552, 1557, 1563, 1574, 1557, 1583, 1589, 1590, 1759, 1594, 1603, 1607, 1611, 1686, 1436, 1514, 1686, 1434, 1656, 1686, 1434, 1680, 1686, 1453, 1686, 1686, 1686, 1559, 1617, 1686, 1770, 1418, 1623, 1769, 1629, 1686, 1515, 1335, 1686, 1285, 1686, 1671, 1921, 1650, 1686, 1686, 1344, 1308, 1666, 1686, 1686, 1686, 1659, 1685, 1686, 1686, 1686, 1686, 1241, 1686, 1686, 1844, 1691, 1686, 1630, 1977, 1970, 1362, 1686, 1686, 1686, 1693, 1698, 1686, 1686, 1686, 1697, 1686, 1764, 1715, 1686, 1634, 1638, 1686, 1599, 1585, 1686, 1271, 1686, 1269, 1686, 1721, 1686, 1686, 1354, 1686, 1801, 1686, 1799, 1686, 1640, 1686, 1686, 1461, 1686, 1686, 1732, 1686, 1944, 1686, 1740, 1686, 1746, 1415, 1396, 1686, 1598, 1547, 1417, 1597, 1416, 1577, 1546, 1397, 1577, 1547, 1548, 1570, 1398, 1753, 1686, 1652, 1509, 1686, 1686, 1686, 1757, 1686, 1419, 1686, 1763, 1418, 1768, 1781, 1686, 1686, 1686, 1705, 1686, 2048, 1792, 1686, 1686, 1686, 1735, 1686, 1797, 1686, 1686, 1404, 1686, 1639, 1815, 1686, 1686, 1418, 2017, 1820, 1686, 1686, 1803, 1686, 1686, 1686, 1736, 1489, 1686, 1686, 1825, 1338, 1260, 1263, 1686, 1686, 1785, 1686, 1686, 1728, 1686, 1686, 1749, 1497, 1830, 1830, 1262, 1248, 1261, 1329, 1260, 1264, 1329, 1248, 1249, 1259, 1540, 1849, 1842, 1686, 1686, 1835, 1686, 1686, 1816, 1686, 1686, 1831, 1882, 1848, 1686, 1686, 1686, 1774, 2071, 1854, 1686, 1686, 1469, 1884, 1686, 1821, 1859, 1686, 1686, 1350, 1883, 1686, 1686, 1686, 1781, 1391, 1875, 1686, 1686, 1613, 1644, 1686, 1686, 1889, 1686, 1686, 1662, 1884, 1686, 1885, 1890, 1686, 1686, 1686, 1894, 1686, 1686, 1678, 1686, 1907, 1686, 1686, 1529, 1914, 1686, 1838, 1686, 1686, 1881, 1686, 1686, 1872, 1876, 1836, 1919, 1686, 1837, 1692, 1910, 1686, 1925, 1928, 1742, 1686, 1811, 1811, 1930, 1810, 1929, 1935, 1928, 1900, 1942, 1867, 1868, 1931, 1035, 1788, 1948, 1952, 1956, 1960, 1964, 1686, 1976, 1686, 1686, 1686, 2065, 1686, 1992, 2037, 1686, 1686, 1998, 2009, 1972, 2002, 1686, 1686, 1686, 2077, 1300, 2023, 1686, 1686, 1686, 1807, 2031, 1686, 1686, 1686, 1860, 1500, 2032, 1686, 1686, 1686, 2083, 1686, 2036, 1686, 1277, 1276, 2042, 1877, 1686, 1686, 2041, 1686, 1686, 2027, 2037, 2012, 1686, 2012, 1855, 1850, 1686, 2046, 1686, 1686, 2054, 1996, 1686, 1897, 1309, 2059, 2052, 1686, 2058, 1686, 1686, 2081, 1686, 1717, 1477, 1686, 1331, 1686, 1686, 1687, 1686, 1860, 1681, 1686, 1686, 1686, 1966, 1724, 1686, 1686, 1686, 1984, 2015, 1686, 1686, 1686, 1988, 1686, 2063, 1686, 1686, 1686, 2005, 1686, 1727, 1686, 1686, 1711, 1457, 2069, 1686, 1686, 1686, 2019, 2075, 1686, 1686, 1915, 1686, 1686, 1793, 1874, 1686, 1686, 1491, 1362, 1449, 1686, 1686, 1460, 2098, 2087, 2091, 2095, 2184, 2102, 2113, 2780, 2117, 2134, 2142, 2281, 2146, 2146, 2146, 2304, 2296, 2181, 2639, 2591, 2872, 2592, 2873, 2313, 2195, 2200, 2281, 2146, 2273, 2226, 2204, 2152, 2219, 2276, 2167, 2177, 2276, 2235, 2276, 2276, 2230, 2281, 2276, 2296, 2276, 2293, 2276, 2276, 2276, 2276, 2234, 2276, 2311, 2314, 2210, 2199, 2217, 2222, 2276, 2276, 2276, 2240, 2276, 2294, 2276, 2276, 2173, 2276, 2198, 2281, 2281, 2281, 2281, 2282, 2146, 2146, 2146, 2146, 2205, 2146, 2204, 2248, 2276, 2235, 2276, 2297, 2276, 2276, 2276, 2277, 2256, 2281, 2283, 2146, 2146, 2146, 2275, 2276, 2295, 2276, 2276, 2293, 2146, 2304, 2264, 2269, 2221, 2276, 2276, 2276, 2293, 2295, 2276, 2276, 2276, 2295, 2263, 2205, 2268, 2220, 2172, 2276, 2276, 2276, 2296, 2276, 2276, 2296, 2294, 2276, 2276, 2278, 2281, 2281, 2280, 2281, 2281, 2281, 2283, 2206, 2223, 2276, 2276, 2279, 2281, 2281, 2146, 2273, 2276, 2276, 2281, 2281, 2281, 2276, 2292, 2276, 2298, 2225, 2276, 2298, 2169, 2224, 2292, 2298, 2171, 2229, 2281, 2281, 2171, 2236, 2281, 2281, 2281, 2146, 2275, 2225, 2292, 2299, 2276, 2229, 2281, 2146, 2276, 2290, 2297, 2283, 2146, 2146, 2274, 2224, 2227, 2298, 2225, 2297, 2276, 2230, 2170, 2230, 2282, 2146, 2147, 2151, 2156, 2288, 2276, 2230, 2303, 2308, 2236, 2284, 2228, 2318, 2318, 2318, 2326, 2335, 2339, 2343, 2349, 2416, 2693, 2357, 2592, 2109, 2592, 2592, 2162, 2943, 2823, 2646, 2592, 2361, 2592, 2122, 2592, 2592, 2122, 2470, 2592, 2592, 2592, 2109, 2107, 2592, 2592, 2592, 2123, 2592, 2592, 2592, 2125, 2592, 2413, 2592, 2592, 2592, 2127, 2592, 2592, 2414, 2592, 2592, 2592, 2130, 2952, 2592, 2594, 2592, 2592, 2212, 2609, 2252, 2592, 2592, 2592, 2446, 2434, 2592, 2592, 2592, 2212, 2446, 2450, 2456, 2431, 2435, 2592, 2592, 2243, 2478, 2448, 2439, 2946, 2592, 2592, 2592, 2368, 2809, 2813, 2450, 2441, 2212, 2812, 2449, 2440, 2947, 2592, 2592, 2592, 2345, 2451, 2457, 2948, 2592, 2124, 2592, 2592, 2650, 2823, 2449, 2455, 2946, 2592, 2128, 2592, 2592, 2649, 2952, 2592, 2810, 2448, 2461, 2991, 2467, 2592, 2592, 2329, 2817, 2474, 2990, 2466, 2592, 2592, 2373, 2447, 2992, 2469, 2592, 2592, 2592, 2373, 2447, 2477, 2468, 2592, 2592, 2353, 2469, 2592, 2495, 2592, 2592, 2415, 2483, 2592, 2415, 2496, 2592, 2592, 2352, 2592, 2592, 2352, 2352, 2469, 2592, 2592, 2363, 2331, 2494, 2592, 2592, 2592, 2375, 2592, 2375, 2415, 2504, 2592, 2592, 2367, 2372, 2503, 2592, 2592, 2592, 2389, 2418, 2415, 2592, 2592, 2373, 2592, 2592, 2592, 2593, 2732, 2417, 2415, 2592, 2417, 2520, 2592, 2592, 2592, 2390, 2521, 2521, 2592, 2592, 2592, 2401, 2599, 2585, 2526, 2531, 2120, 2592, 2212, 2426, 2450, 2463, 2948, 2592, 2592, 2592, 2213, 2389, 2527, 2532, 2121, 2542, 2551, 2105, 2592, 2213, 2592, 2592, 2592, 2558, 2538, 2544, 2553, 2557, 2537, 2543, 2552, 2421, 2572, 2576, 2546, 2543, 2547, 2592, 2592, 2373, 2615, 2575, 2545, 2105, 2592, 2244, 2479, 2592, 2129, 2592, 2592, 2628, 2690, 2469, 2562, 2566, 2592, 2592, 2592, 2415, 2928, 2934, 2401, 2570, 2574, 2564, 2572, 2585, 2590, 2592, 2592, 2585, 2965, 2592, 2592, 2592, 2445, 2251, 2592, 2592, 2592, 2474, 2592, 2609, 2892, 2592, 2362, 2592, 2592, 2138, 2851, 2159, 2592, 2592, 2592, 2509, 2888, 2892, 2592, 2592, 2592, 2490, 2418, 2891, 2592, 2592, 2376, 2592, 2592, 2374, 2592, 2889, 2388, 2592, 2373, 2373, 2890, 2592, 2592, 2387, 2592, 2887, 2505, 2892, 2592, 2373, 2610, 2388, 2592, 2592, 2376, 2373, 2592, 2887, 2891, 2592, 2374, 2592, 2592, 2608, 2159, 2614, 2620, 2592, 2592, 2394, 2594, 2887, 2399, 2592, 2887, 2397, 2508, 2374, 2507, 2592, 2375, 2592, 2592, 2592, 2595, 2508, 2506, 2592, 2506, 2505, 2505, 2592, 2507, 2637, 2505, 2592, 2592, 2401, 2661, 2592, 2643, 2592, 2592, 2417, 2592, 2655, 2592, 2592, 2592, 2510, 2414, 2656, 2592, 2592, 2592, 2516, 2592, 2593, 2660, 2665, 2880, 2592, 2592, 2592, 2522, 2767, 2666, 2881, 2592, 2592, 2420, 2571, 2696, 2592, 2592, 2592, 2580, 2572, 2686, 2632, 2698, 2592, 2383, 2514, 2592, 2163, 2932, 2465, 2685, 2631, 2697, 2592, 2388, 2592, 2592, 2212, 2604, 2671, 2632, 2678, 2592, 2401, 2405, 2409, 2592, 2592, 2592, 2679, 2592, 2592, 2592, 2592, 2108, 2677, 2591, 2592, 2592, 2592, 2419, 2592, 2683, 2187, 2191, 2469, 2671, 2189, 2467, 2592, 2401, 2629, 2633, 2702, 2468, 2592, 2592, 2421, 2536, 2703, 2469, 2592, 2592, 2422, 2573, 2593, 2672, 2467, 2592, 2402, 2406, 2592, 2402, 2979, 2592, 2592, 2626, 2673, 2467, 2592, 2446, 2259, 2947, 2592, 2377, 2709, 2592, 2592, 2522, 2862, 2713, 2468, 2592, 2592, 2581, 2572, 2562, 2374, 2374, 2592, 2376, 2721, 2724, 2592, 2592, 2624, 2373, 2731, 2592, 2592, 2592, 2626, 2732, 2592, 2592, 2592, 2755, 2656, 2726, 2736, 2741, 2592, 2486, 2593, 2381, 2592, 2727, 2737, 2742, 2715, 2747, 2753, 2592, 2498, 2469, 2873, 2743, 2592, 2592, 2592, 2791, 2759, 2763, 2592, 2592, 2627, 2704, 2592, 2592, 2522, 2789, 2593, 2761, 2753, 2592, 2498, 2863, 2592, 2592, 2767, 2592, 2592, 2592, 2792, 2789, 2592, 2592, 2592, 2803, 2126, 2592, 2592, 2592, 2811, 2122, 2592, 2592, 2592, 2834, 2777, 2592, 2592, 2592, 2848, 2936, 2591, 2489, 2797, 2592, 2592, 2670, 2631, 2490, 2798, 2592, 2592, 2592, 2963, 2807, 2592, 2592, 2592, 2965, 2838, 2592, 2592, 2592, 2975, 2330, 2818, 2829, 2592, 2498, 2939, 2592, 2498, 2592, 2791, 2331, 2819, 2830, 2592, 2592, 2592, 2982, 2834, 2817, 2828, 2106, 2592, 2592, 2592, 2405, 2405, 2817, 2828, 2592, 2592, 2415, 2849, 2842, 2592, 2522, 2773, 2592, 2522, 2868, 2592, 2580, 2600, 2586, 2137, 2850, 2843, 2592, 2592, 2855, 2937, 2844, 2592, 2592, 2592, 2987, 2936, 2591, 2592, 2592, 2684, 2630, 2592, 2856, 2938, 2592, 2592, 2860, 2939, 2592, 2592, 2872, 2592, 2861, 2591, 2592, 2592, 2887, 2616, 2592, 2867, 2592, 2592, 2708, 2592, 2498, 2469, 2498, 2497, 2785, 2773, 2499, 2783, 2770, 2877, 2877, 2877, 2772, 2592, 2592, 2345, 2885, 2592, 2592, 2592, 2715, 2762, 2515, 2896, 2592, 2592, 2715, 2917, 2516, 2897, 2592, 2592, 2592, 2901, 2906, 2911, 2592, 2592, 2956, 2960, 2715, 2902, 2907, 2912, 2593, 2916, 2920, 2820, 2922, 2822, 2592, 2592, 2715, 2927, 2921, 2821, 2106, 2592, 2592, 2974, 2408, 2321, 2821, 2106, 2592, 2592, 2983, 2592, 2593, 2404, 2408, 2592, 2592, 2717, 2749, 2716, 2928, 2322, 2822, 2593, 2926, 2919, 2820, 2934, 2823, 2592, 2592, 2592, 2651, 2824, 2592, 2592, 2592, 2130, 2952, 2592, 2592, 2592, 2592, 2964, 2592, 2592, 2716, 2748, 2592, 2969, 2592, 2592, 2716, 2918, 2368, 2970, 2592, 2592, 2592, 2403, 2407, 2592, 2592, 2787, 2211, 2404, 2409, 2592, 2592, 2802, 2837, 2987, 2592, 2592, 2592, 2809, 2427, 2592, 2793, 2592, 2592, 2809, 2447, 1073741824, 0x80000000, 539754496, 542375936, 402653184, 554434560, 571736064, 545521856, 268451840, 335544320, 268693630, 512, 2048, 256, 1024, 0, 1024, 0, 1073741824, 0x80000000, 0, 0, 0, 8388608, 0, 0, 1073741824, 1073741824, 0, 0x80000000, 537133056, 4194304, 1048576, 268435456, -1073741824, 0, 0, 0, 1048576, 0, 0, 0, 1572864, 0, 0, 0, 4194304, 0, 134217728, 16777216, 0, 0, 32, 64, 98304, 0, 33554432, 8388608, 192, 67108864, 67108864, 67108864, 67108864, 16, 32, 4, 0, 8192, 196608, 196608, 229376, 80, 4096, 524288, 8388608, 0, 0, 32, 128, 256, 24576, 24600, 24576, 24576, 2, 24576, 24576, 24576, 24584, 24592, 24576, 24578, 24576, 24578, 24576, 24576, 16, 512, 2048, 2048, 256, 4096, 32768, 1048576, 4194304, 67108864, 134217728, 268435456, 262144, 134217728, 0, 128, 128, 64, 16384, 16384, 16384, 67108864, 32, 32, 4, 4, 4096, 262144, 134217728, 0, 0, 0, 2, 0, 8192, 131072, 131072, 4096, 4096, 4096, 4096, 24576, 24576, 24576, 8, 8, 24576, 24576, 16384, 16384, 16384, 24576, 24584, 24576, 24576, 24576, 16384, 24576, 536870912, 262144, 0, 0, 32, 2048, 8192, 4, 4096, 4096, 4096, 786432, 8388608, 16777216, 0, 128, 16384, 16384, 16384, 32768, 65536, 2097152, 32, 32, 32, 32, 4, 4, 4, 4, 4, 4096, 67108864, 67108864, 67108864, 24576, 24576, 24576, 24576, 0, 16384, 16384, 16384, 16384, 67108864, 67108864, 8, 67108864, 24576, 8, 8, 8, 24576, 24576, 24576, 24578, 24576, 24576, 24576, 2, 2, 2, 16384, 67108864, 67108864, 67108864, 32, 67108864, 8, 8, 24576, 2048, 0x80000000, 536870912, 262144, 262144, 262144, 67108864, 8, 24576, 16384, 32768, 1048576, 4194304, 25165824, 67108864, 24576, 32770, 2, 4, 112, 512, 98304, 524288, 50, 402653186, 1049090, 1049091, 10, 66, 100925514, 10, 66, 12582914, 0, 0, -1678194207, -1678194207, -1041543218, 0, 32768, 0, 0, 32, 65536, 268435456, 1, 1, 513, 1048577, 0, 12582912, 0, 0, 0, 4, 1792, 0, 0, 0, 7, 29360128, 0, 0, 0, 8, 0, 0, 0, 12, 1, 1, 0, 0, -604102721, -604102721, 4194304, 8388608, 0, 0, 0, 31, 925600, 997981306, 997981306, 997981306, 0, 0, 2048, 8388608, 0, 0, 1, 2, 4, 32, 64, 512, 8192, 0, 0, 0, 245760, 997720064, 0, 0, 0, 32, 0, 0, 0, 3, 12, 16, 32, 8, 112, 3072, 12288, 16384, 32768, 65536, 131072, 7864320, 16777216, 973078528, 0, 0, 65536, 131072, 3670016, 4194304, 16777216, 33554432, 2, 8, 48, 2048, 8192, 16384, 32768, 65536, 131072, 524288, 131072, 524288, 3145728, 4194304, 16777216, 33554432, 65536, 131072, 2097152, 4194304, 16777216, 33554432, 134217728, 268435456, 536870912, 0, 0, 0, 1024, 0, 8, 48, 2048, 8192, 65536, 33554432, 268435456, 536870912, 65536, 268435456, 536870912, 0, 0, 32768, 0, 0, 126, 623104, 65011712, 0, 32, 65536, 536870912, 0, 0, 65536, 524288, 0, 32, 65536, 0, 0, 0, 2048, 0, 0, 0, 15482, 245760, -604102721, 0, 0, 0, 18913, 33062912, 925600, -605028352, 0, 0, 0, 65536, 31, 8096, 131072, 786432, 3145728, 3145728, 12582912, 50331648, 134217728, 268435456, 160, 256, 512, 7168, 131072, 786432, 131072, 786432, 1048576, 2097152, 12582912, 16777216, 268435456, 1073741824, 0x80000000, 12582912, 16777216, 33554432, 268435456, 1073741824, 0x80000000, 3, 12, 16, 160, 256, 7168, 786432, 1048576, 12582912, 16777216, 268435456, 1073741824, 0, 8, 16, 32, 128, 256, 512, 7168, 786432, 1048576, 2097152, 0, 1, 2, 8, 16, 7168, 786432, 1048576, 8388608, 16777216, 16777216, 1073741824, 0, 0, 0, 0, 1, 0, 0, 8, 32, 128, 256, 7168, 8, 32, 0, 3072, 0, 8, 32, 3072, 4096, 524288, 8, 32, 0, 0, 3072, 4096, 0, 2048, 524288, 8388608, 8, 2048, 0, 0, 1, 12, 256, 4096, 32768, 262144, 1048576, 4194304, 67108864, 0, 2048, 0, 2048, 2048, 1073741824, -58805985, -58805985, -58805985, 0, 0, 262144, 0, 0, 32, 4194304, 16777216, 134217728, 4382, 172032, -58982400, 0, 0, 2, 28, 256, 4096, 8192, 8192, 32768, 131072, 262144, 524288, 1, 2, 12, 256, 4096, 0, 0, 4194304, 67108864, 134217728, 805306368, 1073741824, 0, 0, 1, 2, 12, 16, 256, 4096, 1048576, 67108864, 134217728, 268435456, 0, 512, 1048576, 4194304, 201326592, 1879048192, 0, 0, 12, 256, 4096, 134217728, 268435456, 536870912, 12, 256, 268435456, 536870912, 0, 12, 256, 0, 0, 1, 32, 64, 512, 0, 0, 205236961, 205236961, 0, 0, 0, 1, 96, 640, 1, 10976, 229376, 204996608, 0, 640, 2048, 8192, 229376, 1572864, 1572864, 2097152, 201326592, 0, 0, 0, 64, 512, 2048, 229376, 1572864, 201326592, 1572864, 201326592, 0, 0, 1, 4382, 0, 1, 32, 2048, 65536, 131072, 1572864, 201326592, 131072, 1572864, 134217728, 0, 0, 524288, 524288, 0, 0, 0, -68582786, -68582786, -68582786, 0, 0, 2097152, 524288, 0, 524288, 0, 0, 65536, 131072, 1572864, 0, 0, 2, 4, 0, 0, 65011712, -134217728, 0, 0, 0, 0, 2, 4, 120, 512, -268435456, 0, 0, 0, 2, 8, 48, 64, 2048, 8192, 98304, 524288, 2097152, 4194304, 25165824, 33554432, 134217728, 268435456, 0x80000000, 0, 0, 25165824, 33554432, 134217728, 1879048192, 0x80000000, 0, 0, 4, 112, 512, 622592, 65011712, 134217728, -268435456, 16777216, 33554432, 134217728, 1610612736, 0, 0, 0, 64, 98304, 524288, 4194304, 16777216, 33554432, 0, 98304, 524288, 16777216, 33554432, 0, 65536, 524288, 33554432, 536870912, 1073741824, 0, 65536, 524288, 536870912, 1073741824, 0, 0, 65536, 524288, 536870912, 0, 524288, 0, 524288, 524288, 1048576, 2086666240, 0x80000000, 0, -1678194207, 0, 0, 0, 8, 32, 2048, 524288, 8388608, 0, 0, 33062912, 436207616, 0x80000000, 0, 0, 32, 64, 2432, 16384, 32768, 32768, 524288, 3145728, 4194304, 25165824, 25165824, 167772160, 268435456, 0x80000000, 0, 32, 64, 384, 2048, 16384, 32768, 1048576, 2097152, 4194304, 25165824, 32, 64, 128, 256, 2048, 16384, 2048, 16384, 1048576, 4194304, 16777216, 33554432, 134217728, 536870912, 1073741824, 0, 0, 2048, 16384, 4194304, 16777216, 33554432, 134217728, 805306368, 0, 0, 16777216, 134217728, 268435456, 0x80000000, 0, 622592, 622592, 622592, 8807, 8807, 434791, 0, 0, 16777216, 0, 0, 0, 7, 608, 8192, 0, 0, 0, 3, 4, 96, 512, 32, 64, 8192, 0, 0, 16777216, 134217728, 0, 0, 2, 4, 8192, 16384, 65536, 2097152, 33554432, 268435456
+];
+
+XQueryTokenizer.TOKEN =
+[
+ "(0)",
+ "ModuleDecl",
+ "Annotation",
+ "OptionDecl",
+ "Operator",
+ "Variable",
+ "Tag",
+ "EndTag",
+ "PragmaContents",
+ "DirCommentContents",
+ "DirPIContents",
+ "CDataSectionContents",
+ "AttrTest",
+ "Wildcard",
+ "EQName",
+ "IntegerLiteral",
+ "DecimalLiteral",
+ "DoubleLiteral",
+ "PredefinedEntityRef",
+ "'\"\"'",
+ "EscapeApos",
+ "QuotChar",
+ "AposChar",
+ "ElementContentChar",
+ "QuotAttrContentChar",
+ "AposAttrContentChar",
+ "NCName",
+ "QName",
+ "S",
+ "CharRef",
+ "CommentContents",
+ "DocTag",
+ "DocCommentContents",
+ "EOF",
+ "'!'",
+ "'\"'",
+ "'#'",
+ "'#)'",
+ "''''",
+ "'('",
+ "'(#'",
+ "'(:'",
+ "'(:~'",
+ "')'",
+ "'*'",
+ "'*'",
+ "','",
+ "'-->'",
+ "'.'",
+ "'/'",
+ "'/>'",
+ "':'",
+ "':)'",
+ "';'",
+ "'<!--'",
+ "'<![CDATA['",
+ "'<?'",
+ "'='",
+ "'>'",
+ "'?'",
+ "'?>'",
+ "'NaN'",
+ "'['",
+ "']'",
+ "']]>'",
+ "'after'",
+ "'all'",
+ "'allowing'",
+ "'ancestor'",
+ "'ancestor-or-self'",
+ "'and'",
+ "'any'",
+ "'append'",
+ "'array'",
+ "'as'",
+ "'ascending'",
+ "'at'",
+ "'attribute'",
+ "'base-uri'",
+ "'before'",
+ "'boundary-space'",
+ "'break'",
+ "'by'",
+ "'case'",
+ "'cast'",
+ "'castable'",
+ "'catch'",
+ "'check'",
+ "'child'",
+ "'collation'",
+ "'collection'",
+ "'comment'",
+ "'constraint'",
+ "'construction'",
+ "'contains'",
+ "'content'",
+ "'context'",
+ "'continue'",
+ "'copy'",
+ "'copy-namespaces'",
+ "'count'",
+ "'decimal-format'",
+ "'decimal-separator'",
+ "'declare'",
+ "'default'",
+ "'delete'",
+ "'descendant'",
+ "'descendant-or-self'",
+ "'descending'",
+ "'diacritics'",
+ "'different'",
+ "'digit'",
+ "'distance'",
+ "'div'",
+ "'document'",
+ "'document-node'",
+ "'element'",
+ "'else'",
+ "'empty'",
+ "'empty-sequence'",
+ "'encoding'",
+ "'end'",
+ "'entire'",
+ "'eq'",
+ "'every'",
+ "'exactly'",
+ "'except'",
+ "'exit'",
+ "'external'",
+ "'first'",
+ "'following'",
+ "'following-sibling'",
+ "'for'",
+ "'foreach'",
+ "'foreign'",
+ "'from'",
+ "'ft-option'",
+ "'ftand'",
+ "'ftnot'",
+ "'ftor'",
+ "'function'",
+ "'ge'",
+ "'greatest'",
+ "'group'",
+ "'grouping-separator'",
+ "'gt'",
+ "'idiv'",
+ "'if'",
+ "'import'",
+ "'in'",
+ "'index'",
+ "'infinity'",
+ "'inherit'",
+ "'insensitive'",
+ "'insert'",
+ "'instance'",
+ "'integrity'",
+ "'intersect'",
+ "'into'",
+ "'is'",
+ "'item'",
+ "'json'",
+ "'json-item'",
+ "'key'",
+ "'language'",
+ "'last'",
+ "'lax'",
+ "'le'",
+ "'least'",
+ "'let'",
+ "'levels'",
+ "'loop'",
+ "'lowercase'",
+ "'lt'",
+ "'minus-sign'",
+ "'mod'",
+ "'modify'",
+ "'module'",
+ "'most'",
+ "'namespace'",
+ "'namespace-node'",
+ "'ne'",
+ "'next'",
+ "'no'",
+ "'no-inherit'",
+ "'no-preserve'",
+ "'node'",
+ "'nodes'",
+ "'not'",
+ "'object'",
+ "'occurs'",
+ "'of'",
+ "'on'",
+ "'only'",
+ "'option'",
+ "'or'",
+ "'order'",
+ "'ordered'",
+ "'ordering'",
+ "'paragraph'",
+ "'paragraphs'",
+ "'parent'",
+ "'pattern-separator'",
+ "'per-mille'",
+ "'percent'",
+ "'phrase'",
+ "'position'",
+ "'preceding'",
+ "'preceding-sibling'",
+ "'preserve'",
+ "'previous'",
+ "'processing-instruction'",
+ "'relationship'",
+ "'rename'",
+ "'replace'",
+ "'return'",
+ "'returning'",
+ "'revalidation'",
+ "'same'",
+ "'satisfies'",
+ "'schema'",
+ "'schema-attribute'",
+ "'schema-element'",
+ "'score'",
+ "'self'",
+ "'sensitive'",
+ "'sentence'",
+ "'sentences'",
+ "'skip'",
+ "'sliding'",
+ "'some'",
+ "'stable'",
+ "'start'",
+ "'stemming'",
+ "'stop'",
+ "'strict'",
+ "'strip'",
+ "'structured-item'",
+ "'switch'",
+ "'text'",
+ "'then'",
+ "'thesaurus'",
+ "'times'",
+ "'to'",
+ "'treat'",
+ "'try'",
+ "'tumbling'",
+ "'type'",
+ "'typeswitch'",
+ "'union'",
+ "'unique'",
+ "'unordered'",
+ "'updating'",
+ "'uppercase'",
+ "'using'",
+ "'validate'",
+ "'value'",
+ "'variable'",
+ "'version'",
+ "'weight'",
+ "'when'",
+ "'where'",
+ "'while'",
+ "'wildcards'",
+ "'window'",
+ "'with'",
+ "'without'",
+ "'word'",
+ "'words'",
+ "'xquery'",
+ "'zero-digit'",
+ "'{'",
+ "'{{'",
+ "'|'",
+ "'}'",
+ "'}}'"
+];
+
+},{}],"/node_modules/xqlint/lib/lexers/lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var TokenHandler = function(code) {
+ var input = code;
+ this.tokens = [];
+
+ this.reset = function() {
+ input = input;
+ this.tokens = [];
+ };
+
+ this.startNonterminal = function() {};
+ this.endNonterminal = function() {};
+
+ this.terminal = function(name, begin, end) {
+ this.tokens.push({
+ name: name,
+ value: input.substring(begin, end)
+ });
+ };
+
+ this.whitespace = function(begin, end) {
+ this.tokens.push({
+ name: 'WS',
+ value: input.substring(begin, end)
+ });
+ };
+};
+
+exports.Lexer = function(Tokenizer, Rules) {
+
+ this.tokens = [];
+
+ this.getLineTokens = function(line, state) {
+ state = (state === 'start' || !state) ? '["start"]' : state;
+ var stack = JSON.parse(state);
+ var h = new TokenHandler(line);
+ var tokenizer = new Tokenizer(line, h);
+ var tokens = [];
+
+ while(true) {
+ var currentState = stack[stack.length - 1];
+ try {
+ h.tokens = [];
+ tokenizer['parse_' + currentState]();
+ var info = null;
+
+ if(h.tokens.length > 1 && h.tokens[0].name === 'WS') {
+ tokens.push({
+ type: 'text',
+ value: h.tokens[0].value
+ });
+ h.tokens.splice(0, 1);
+ }
+
+ var token = h.tokens[0];
+ var rules = Rules[currentState];
+ for(var k = 0; k < rules.length; k++) {
+ var rule = Rules[currentState][k];
+ if((typeof(rule.name) === 'function' && rule.name(token)) || rule.name === token.name) {
+ info = rule;
+ break;
+ }
+ }
+
+ if(token.name === 'EOF') { break; }
+ if(token.value === '') { throw 'Encountered empty string lexical rule.'; }
+
+ tokens.push({
+ type: info === null ? 'text' : (typeof(info.token) === 'function' ? info.token(token.value) : info.token),
+ value: token.value
+ });
+
+ if(info && info.next) {
+ info.next(stack);
+ }
+
+ } catch(e) {
+ if(e instanceof tokenizer.ParseException) {
+ var index = 0;
+ for(var i=0; i < tokens.length; i++) {
+ index += tokens[i].value.length;
+ }
+ tokens.push({ type: 'text', value: line.substring(index) });
+ return {
+ tokens: tokens,
+ state: JSON.stringify(['start'])
+ };
+ } else {
+ throw e;
+ }
+ }
+ }
+
+ return {
+ tokens: tokens,
+ state: JSON.stringify(stack)
+ };
+ };
+};
+},{}],"/node_modules/xqlint/lib/lexers/xquery_lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var XQueryTokenizer = _dereq_('./XQueryTokenizer').XQueryTokenizer;
+var Lexer = _dereq_('./lexer').Lexer;
+
+var keys = 'after|ancestor|ancestor-or-self|and|as|ascending|attribute|before|case|cast|castable|child|collation|comment|copy|count|declare|default|delete|descendant|descendant-or-self|descending|div|document|document-node|element|else|empty|empty-sequence|end|eq|every|except|first|following|following-sibling|for|function|ge|group|gt|idiv|if|import|insert|instance|intersect|into|is|item|last|le|let|lt|mod|modify|module|namespace|namespace-node|ne|node|only|or|order|ordered|parent|preceding|preceding-sibling|processing-instruction|rename|replace|return|satisfies|schema-attribute|schema-element|self|some|stable|start|switch|text|to|treat|try|typeswitch|union|unordered|validate|where|with|xquery|contains|paragraphs|sentences|times|words|by|collectionreturn|variable|version|option|when|encoding|toswitch|catch|tumbling|sliding|window|at|using|stemming|collection|schema|while|on|nodes|index|external|then|in|updating|value|of|containsbreak|loop|continue|exit|returning|append|json|position|strict'.split('|');
+
+var keywords = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'keyword' }; });
+var ncnames = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'text', next: function(stack){ stack.pop(); } }; });
+
+var cdata = 'constant.language';
+var number = 'constant';
+var xmlcomment = 'comment';
+var pi = 'xml-pe';
+var pragma = 'constant.buildin';
+var n = function(name){
+ return '\'' + name + '\'';
+};
+var Rules = {
+ start: [
+ { name: n('(#'), token: pragma, next: function(stack){ stack.push('Pragma'); } },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n('(:~'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: n('<?'), token: pi, next: function(stack) { stack.push('PI'); } },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposString'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotString'); } },
+ { name: 'Annotation', token: 'support.function' },
+ { name: 'ModuleDecl', token: 'keyword', next: function(stack){ stack.push('Prefix'); } },
+ { name: 'OptionDecl', token: 'keyword', next: function(stack){ stack.push('_EQName'); } },
+ { name: 'AttrTest', token: 'support.type' },
+ { name: 'Variable', token: 'variable' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: 'IntegerLiteral', token: number },
+ { name: 'DecimalLiteral', token: number },
+ { name: 'DoubleLiteral', token: number },
+ { name: 'Operator', token: 'keyword.operator' },
+ { name: 'EQName', token: function(val) { return keys.indexOf(val) !== -1 ? 'keyword' : 'support.function'; } },
+ { name: n('('), token: 'lparen' },
+ { name: n(')'), token: 'rparen' },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: n('}'), token: 'text', next: function(stack){ if(stack.length > 1) { stack.pop(); } } },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } } //, next: function(stack){ if(stack.length > 1) { stack.pop(); } } }
+ ].concat(keywords),
+ _EQName: [
+ { name: 'EQName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ Prefix: [
+ { name: 'NCName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ StartTag: [
+ { name: n('>'), token: 'meta.tag', next: function(stack){ stack.push('TagContent'); } },
+ { name: 'QName', token: 'entity.other.attribute-name' },
+ { name: n('='), token: 'text' },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposAttr'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotAttr'); } },
+ { name: n('/>'), token: 'meta.tag.r', next: function(stack){ stack.pop(); } }
+ ],
+ TagContent: [
+ { name: 'ElementContentChar', token: 'text' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'text' },
+ { name: n('}}'), token: 'text' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } },
+ { name: 'EndTag', token: 'meta.tag', next: function(stack){ stack.pop(); stack.pop(); } }
+ ],
+ AposAttr: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ QuotAttr: [
+ { name: n('\"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeQuot', token: 'constant.language.escape' },
+ { name: 'QuotAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ Pragma: [
+ { name: 'PragmaContents', token: pragma },
+ { name: n('#'), token: pragma },
+ { name: n('#)'), token: pragma, next: function(stack){ stack.pop(); } }
+ ],
+ Comment: [
+ { name: 'CommentContents', token: 'comment' },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n(':)'), token: 'comment', next: function(stack){ stack.pop(); } }
+ ],
+ CommentDoc: [
+ { name: 'DocCommentContents', token: 'comment.doc' },
+ { name: 'DocTag', token: 'comment.doc.tag' },
+ { name: n('(:'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n(':)'), token: 'comment.doc', next: function(stack){ stack.pop(); } }
+ ],
+ XMLComment: [
+ { name: 'DirCommentContents', token: xmlcomment },
+ { name: n('-->'), token: xmlcomment, next: function(stack){ stack.pop(); } }
+ ],
+ CData: [
+ { name: 'CDataSectionContents', token: cdata },
+ { name: n(']]>'), token: cdata, next: function(stack){ stack.pop(); } }
+ ],
+ PI: [
+ { name: 'DirPIContents', token: pi },
+ { name: n('?'), token: pi },
+ { name: n('?>'), token: pi, next: function(stack){ stack.pop(); } }
+ ],
+ AposString: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposChar', token: 'string' }
+ ],
+ QuotString: [
+ { name: n('"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: 'EscapeQuot', token: 'constant.language.escape' },
+ { name: 'QuotChar', token: 'string' }
+ ]
+};
+
+exports.XQueryLexer = function(){ return new Lexer(XQueryTokenizer, Rules); };
+},{"./XQueryTokenizer":"/node_modules/xqlint/lib/lexers/XQueryTokenizer.js","./lexer":"/node_modules/xqlint/lib/lexers/lexer.js"}]},{},["/node_modules/xqlint/lib/lexers/xquery_lexer.js"]);
+
+});
+
+ace.define("ace/mode/behaviour/xml",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/token_iterator","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Behaviour = require("../behaviour").Behaviour;
+var TokenIterator = require("../../token_iterator").TokenIterator;
+var lang = require("../../lib/lang");
+
+function is(token, type) {
+ return token.type.lastIndexOf(type + ".xml") > -1;
+}
+
+var XmlBehaviour = function () {
+
+ this.add("string_dquotes", "insertion", function (state, action, editor, session, text) {
+ if (text == '"' || text == "'") {
+ var quote = text;
+ var selected = session.doc.getTextRange(editor.getSelectionRange());
+ if (selected !== "" && selected !== "'" && selected != '"' && editor.getWrapBehavioursEnabled()) {
+ return {
+ text: quote + selected + quote,
+ selection: false
+ };
+ }
+
+ var cursor = editor.getCursorPosition();
+ var line = session.doc.getLine(cursor.row);
+ var rightChar = line.substring(cursor.column, cursor.column + 1);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (rightChar == quote && (is(token, "attribute-value") || is(token, "string"))) {
+ return {
+ text: "",
+ selection: [1, 1]
+ };
+ }
+
+ if (!token)
+ token = iterator.stepBackward();
+
+ if (!token)
+ return;
+
+ while (is(token, "tag-whitespace") || is(token, "whitespace")) {
+ token = iterator.stepBackward();
+ }
+ var rightSpace = !rightChar || rightChar.match(/\s/);
+ if (is(token, "attribute-equals") && (rightSpace || rightChar == '>') || (is(token, "decl-attribute-equals") && (rightSpace || rightChar == '?'))) {
+ return {
+ text: quote + quote,
+ selection: [1, 1]
+ };
+ }
+ }
+ });
+
+ this.add("string_dquotes", "deletion", function(state, action, editor, session, range) {
+ var selected = session.doc.getTextRange(range);
+ if (!range.isMultiLine() && (selected == '"' || selected == "'")) {
+ var line = session.doc.getLine(range.start.row);
+ var rightChar = line.substring(range.start.column + 1, range.start.column + 2);
+ if (rightChar == selected) {
+ range.end.column++;
+ return range;
+ }
+ }
+ });
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getSelectionRange().start;
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken() || iterator.stepBackward();
+ if (!token || !(is(token, "tag-name") || is(token, "tag-whitespace") || is(token, "attribute-name") || is(token, "attribute-equals") || is(token, "attribute-value")))
+ return;
+ if (is(token, "reference.attribute-value"))
+ return;
+ if (is(token, "attribute-value")) {
+ var firstChar = token.value.charAt(0);
+ if (firstChar == '"' || firstChar == "'") {
+ var lastChar = token.value.charAt(token.value.length - 1);
+ var tokenEnd = iterator.getCurrentTokenColumn() + token.value.length;
+ if (tokenEnd > position.column || tokenEnd == position.column && firstChar != lastChar)
+ return;
+ }
+ }
+ while (!is(token, "tag-name")) {
+ token = iterator.stepBackward();
+ if (token.value == "<") {
+ token = iterator.stepForward();
+ break;
+ }
+ }
+
+ var tokenRow = iterator.getCurrentTokenRow();
+ var tokenColumn = iterator.getCurrentTokenColumn();
+ if (is(iterator.stepBackward(), "end-tag-open"))
+ return;
+
+ var element = token.value;
+ if (tokenRow == position.row)
+ element = element.substring(0, position.column - tokenColumn);
+
+ if (this.voidElements.hasOwnProperty(element.toLowerCase()))
+ return;
+
+ return {
+ text: ">" + "</" + element + ">",
+ selection: [1, 1]
+ };
+ }
+ });
+
+ this.add("autoindent", "insertion", function (state, action, editor, session, text) {
+ if (text == "\n") {
+ var cursor = editor.getCursorPosition();
+ var line = session.getLine(cursor.row);
+ var iterator = new TokenIterator(session, cursor.row, cursor.column);
+ var token = iterator.getCurrentToken();
+
+ if (token && token.type.indexOf("tag-close") !== -1) {
+ if (token.value == "/>")
+ return;
+ while (token && token.type.indexOf("tag-name") === -1) {
+ token = iterator.stepBackward();
+ }
+
+ if (!token) {
+ return;
+ }
+
+ var tag = token.value;
+ var row = iterator.getCurrentTokenRow();
+ token = iterator.stepBackward();
+ if (!token || token.type.indexOf("end-tag") !== -1) {
+ return;
+ }
+
+ if (this.voidElements && !this.voidElements[tag]) {
+ var nextToken = session.getTokenAt(cursor.row, cursor.column+1);
+ var line = session.getLine(row);
+ var nextIndent = this.$getIndent(line);
+ var indent = nextIndent + session.getTabString();
+
+ if (nextToken && nextToken.value === "</") {
+ return {
+ text: "\n" + indent + "\n" + nextIndent,
+ selection: [1, indent.length, 1, indent.length]
+ };
+ } else {
+ return {
+ text: "\n" + indent
+ };
+ }
+ }
+ }
+ }
+ });
+
+};
+
+oop.inherits(XmlBehaviour, Behaviour);
+
+exports.XmlBehaviour = XmlBehaviour;
+});
+
+ace.define("ace/mode/behaviour/xquery",["require","exports","module","ace/lib/oop","ace/mode/behaviour","ace/mode/behaviour/cstyle","ace/mode/behaviour/xml","ace/token_iterator"], function(require, exports, module) {
+"use strict";
+
+ var oop = require("../../lib/oop");
+ var Behaviour = require('../behaviour').Behaviour;
+ var CstyleBehaviour = require('./cstyle').CstyleBehaviour;
+ var XmlBehaviour = require("../behaviour/xml").XmlBehaviour;
+ var TokenIterator = require("../../token_iterator").TokenIterator;
+
+function hasType(token, type) {
+ var hasType = true;
+ var typeList = token.type.split('.');
+ var needleList = type.split('.');
+ needleList.forEach(function(needle){
+ if (typeList.indexOf(needle) == -1) {
+ hasType = false;
+ return false;
+ }
+ });
+ return hasType;
+}
+
+ var XQueryBehaviour = function () {
+
+ this.inherit(CstyleBehaviour, ["braces", "parens", "string_dquotes"]); // Get string behaviour
+ this.inherit(XmlBehaviour); // Get xml behaviour
+
+ this.add("autoclosing", "insertion", function (state, action, editor, session, text) {
+ if (text == '>') {
+ var position = editor.getCursorPosition();
+ var iterator = new TokenIterator(session, position.row, position.column);
+ var token = iterator.getCurrentToken();
+ var atCursor = false;
+ var state = JSON.parse(state).pop();
+ if ((token && token.value === '>') || state !== "StartTag") return;
+ if (!token || !hasType(token, 'meta.tag') && !(hasType(token, 'text') && token.value.match('/'))){
+ do {
+ token = iterator.stepBackward();
+ } while (token && (hasType(token, 'string') || hasType(token, 'keyword.operator') || hasType(token, 'entity.attribute-name') || hasType(token, 'text')));
+ } else {
+ atCursor = true;
+ }
+ var previous = iterator.stepBackward();
+ if (!token || !hasType(token, 'meta.tag') || (previous !== null && previous.value.match('/'))) {
+ return
+ }
+ var tag = token.value.substring(1);
+ if (atCursor){
+ var tag = tag.substring(0, position.column - token.start);
+ }
+
+ return {
+ text: '>' + '</' + tag + '>',
+ selection: [1, 1]
+ }
+ }
+ });
+
+ }
+ oop.inherits(XQueryBehaviour, Behaviour);
+
+ exports.XQueryBehaviour = XQueryBehaviour;
+});
+
+ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var Range = require("../../range").Range;
+var BaseFoldMode = require("./fold_mode").FoldMode;
+
+var FoldMode = exports.FoldMode = function(commentRegex) {
+ if (commentRegex) {
+ this.foldingStartMarker = new RegExp(
+ this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
+ );
+ this.foldingStopMarker = new RegExp(
+ this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
+ );
+ }
+};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
+ this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
+ this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
+ this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
+ this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
+ this._getFoldWidgetBase = this.getFoldWidget;
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+
+ if (this.singleLineBlockCommentRe.test(line)) {
+ if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
+ return "";
+ }
+
+ var fw = this._getFoldWidgetBase(session, foldStyle, row);
+
+ if (!fw && this.startRegionRe.test(line))
+ return "start"; // lineCommentRegionStart
+
+ return fw;
+ };
+
+ this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
+ var line = session.getLine(row);
+
+ if (this.startRegionRe.test(line))
+ return this.getCommentRegionBlock(session, line, row);
+
+ var match = line.match(this.foldingStartMarker);
+ if (match) {
+ var i = match.index;
+
+ if (match[1])
+ return this.openingBracketBlock(session, match[1], row, i);
+
+ var range = session.getCommentFoldRange(row, i + match[0].length, 1);
+
+ if (range && !range.isMultiLine()) {
+ if (forceMultiline) {
+ range = this.getSectionRange(session, row);
+ } else if (foldStyle != "all")
+ range = null;
+ }
+
+ return range;
+ }
+
+ if (foldStyle === "markbegin")
+ return;
+
+ var match = line.match(this.foldingStopMarker);
+ if (match) {
+ var i = match.index + match[0].length;
+
+ if (match[1])
+ return this.closingBracketBlock(session, match[1], row, i);
+
+ return session.getCommentFoldRange(row, i, -1);
+ }
+ };
+
+ this.getSectionRange = function(session, row) {
+ var line = session.getLine(row);
+ var startIndent = line.search(/\S/);
+ var startRow = row;
+ var startColumn = line.length;
+ row = row + 1;
+ var endRow = row;
+ var maxRow = session.getLength();
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var indent = line.search(/\S/);
+ if (indent === -1)
+ continue;
+ if (startIndent > indent)
+ break;
+ var subRange = this.getFoldWidgetRange(session, "all", row);
+
+ if (subRange) {
+ if (subRange.start.row <= startRow) {
+ break;
+ } else if (subRange.isMultiLine()) {
+ row = subRange.end.row;
+ } else if (startIndent == indent) {
+ break;
+ }
+ }
+ endRow = row;
+ }
+
+ return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
+ };
+ this.getCommentRegionBlock = function(session, line, row) {
+ var startColumn = line.search(/\s*$/);
+ var maxRow = session.getLength();
+ var startRow = row;
+
+ var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
+ var depth = 1;
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var m = re.exec(line);
+ if (!m) continue;
+ if (m[1]) depth--;
+ else depth++;
+
+ if (!depth) break;
+ }
+
+ var endRow = row;
+ if (endRow > startRow) {
+ return new Range(startRow, startColumn, endRow, line.length);
+ }
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/xquery",["require","exports","module","ace/worker/worker_client","ace/lib/oop","ace/mode/text","ace/mode/text_highlight_rules","ace/mode/xquery/xquery_lexer","ace/range","ace/mode/behaviour/xquery","ace/mode/folding/cstyle","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var WorkerClient = require("../worker/worker_client").WorkerClient;
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+var XQueryLexer = require("./xquery/xquery_lexer").XQueryLexer;
+var Range = require("../range").Range;
+var XQueryBehaviour = require("./behaviour/xquery").XQueryBehaviour;
+var CStyleFoldMode = require("./folding/cstyle").FoldMode;
+var Anchor = require("../anchor").Anchor;
+
+var Mode = function() {
+ this.$tokenizer = new XQueryLexer();
+ this.$behaviour = new XQueryBehaviour();
+ this.foldingRules = new CStyleFoldMode();
+ this.$highlightRules = new TextHighlightRules();
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.completer = {
+ getCompletions: function(editor, session, pos, prefix, callback) {
+ if (!session.$worker)
+ return callback();
+ session.$worker.emit("complete", { data: { pos: pos, prefix: prefix } });
+ session.$worker.on("complete", function(e){
+ callback(null, e.data);
+ });
+ }
+ };
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+ var match = line.match(/\s*(?:then|else|return|[{\(]|<\w+>)\s*$/);
+ if (match)
+ indent += tab;
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return (/^\s*[\}\)]/).test(input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*[\}\)])/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.toggleCommentLines = function(state, doc, startRow, endRow) {
+ var i, line;
+ var outdent = true;
+ var re = /^\s*\(:(.*):\)/;
+
+ for (i=startRow; i<= endRow; i++) {
+ if (!re.test(doc.getLine(i))) {
+ outdent = false;
+ break;
+ }
+ }
+
+ var range = new Range(0, 0, 0, 0);
+ for (i=startRow; i<= endRow; i++) {
+ line = doc.getLine(i);
+ range.start.row = i;
+ range.end.row = i;
+ range.end.column = line.length;
+
+ doc.replace(range, outdent ? line.match(re)[1] : "(:" + line + ":)");
+ }
+ };
+
+ this.createWorker = function(session) {
+
+ var worker = new WorkerClient(["ace"], "ace/mode/xquery_worker", "XQueryWorker");
+ var that = this;
+
+ worker.attachToDocument(session.getDocument());
+
+ worker.on("ok", function(e) {
+ session.clearAnnotations();
+ });
+
+ worker.on("markers", function(e) {
+ session.clearAnnotations();
+ that.addMarkers(e.data, session);
+ });
+
+ worker.on("highlight", function(tokens) {
+ that.$tokenizer.tokens = tokens.data.tokens;
+ that.$tokenizer.lines = session.getDocument().getAllLines();
+
+ var rows = Object.keys(that.$tokenizer.tokens);
+ for(var i=0; i < rows.length; i++) {
+ var row = parseInt(rows[i]);
+ delete session.bgTokenizer.lines[row];
+ delete session.bgTokenizer.states[row];
+ session.bgTokenizer.fireUpdateEvent(row, row);
+ }
+ });
+
+ return worker;
+ };
+
+ this.removeMarkers = function(session) {
+ var markers = session.getMarkers(false);
+ for (var id in markers) {
+ if (markers[id].clazz.indexOf('language_highlight_') === 0) {
+ session.removeMarker(id);
+ }
+ }
+ for (var i = 0; i < session.markerAnchors.length; i++) {
+ session.markerAnchors[i].detach();
+ }
+ session.markerAnchors = [];
+ };
+
+ this.addMarkers = function(annos, mySession) {
+ var _self = this;
+
+ if (!mySession.markerAnchors) mySession.markerAnchors = [];
+ this.removeMarkers(mySession);
+ mySession.languageAnnos = [];
+ annos.forEach(function(anno) {
+ var anchor = new Anchor(mySession.getDocument(), anno.pos.sl, anno.pos.sc || 0);
+ mySession.markerAnchors.push(anchor);
+ var markerId;
+ var colDiff = anno.pos.ec - anno.pos.sc;
+ var rowDiff = anno.pos.el - anno.pos.sl;
+ var gutterAnno = {
+ guttertext: anno.message,
+ type: anno.level || "warning",
+ text: anno.message
+ };
+
+ function updateFloat(single) {
+ if (markerId)
+ mySession.removeMarker(markerId);
+ gutterAnno.row = anchor.row;
+ if (anno.pos.sc !== undefined && anno.pos.ec !== undefined) {
+ var range = new Range(anno.pos.sl, anno.pos.sc, anno.pos.el, anno.pos.ec);
+ markerId = mySession.addMarker(range, "language_highlight_" + (anno.type ? anno.type : "default"));
+ }
+ if (single) mySession.setAnnotations(mySession.languageAnnos);
+ }
+ updateFloat();
+ anchor.on("change", function() {
+ updateFloat(true);
+ });
+ if (anno.message) mySession.languageAnnos.push(gutterAnno);
+ });
+ mySession.setAnnotations(mySession.languageAnnos);
+ };
+
+ this.$id = "ace/mode/xquery";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/mode-yaml.js b/www/wiki/extensions/CodeEditor/modules/ace/mode-yaml.js
new file mode 100644
index 00000000..8fbc403f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/mode-yaml.js
@@ -0,0 +1,289 @@
+ace.define("ace/mode/yaml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
+
+var YamlHighlightRules = function() {
+ this.$rules = {
+ "start" : [
+ {
+ token : "comment",
+ regex : "#.*$"
+ }, {
+ token : "list.markup",
+ regex : /^(?:-{3}|\.{3})\s*(?=#|$)/
+ }, {
+ token : "list.markup",
+ regex : /^\s*[\-?](?:$|\s)/
+ }, {
+ token: "constant",
+ regex: "!![\\w//]+"
+ }, {
+ token: "constant.language",
+ regex: "[&\\*][a-zA-Z0-9-_]+"
+ }, {
+ token: ["meta.tag", "keyword"],
+ regex: /^(\s*\w.*?)(:(?:\s+|$))/
+ },{
+ token: ["meta.tag", "keyword"],
+ regex: /(\w+?)(\s*:(?:\s+|$))/
+ }, {
+ token : "keyword.operator",
+ regex : "<<\\w*:\\w*"
+ }, {
+ token : "keyword.operator",
+ regex : "-\\s*(?=[{])"
+ }, {
+ token : "string", // single line
+ regex : '["](?:(?:\\\\.)|(?:[^"\\\\]))*?["]'
+ }, {
+ token : "string", // multi line string start
+ regex : /[|>][-+\d\s]*$/,
+ onMatch: function(val, state, stack, line) {
+ var indent = /^\s*/.exec(line)[0];
+ if (stack.length < 1) {
+ stack.push(this.next);
+ } else {
+ stack[0] = "mlString";
+ }
+
+ if (stack.length < 2) {
+ stack.push(indent.length);
+ }
+ else {
+ stack[1] = indent.length;
+ }
+ return this.token;
+ },
+ next : "mlString"
+ }, {
+ token : "string", // single quoted string
+ regex : "['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']"
+ }, {
+ token : "constant.numeric", // float
+ regex : /(\b|[+\-\.])[\d_]+(?:(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)/
+ }, {
+ token : "constant.numeric", // other number
+ regex : /[+\-]?\.inf\b|NaN\b|0x[\dA-Fa-f_]+|0b[10_]+/
+ }, {
+ token : "constant.language.boolean",
+ regex : "\\b(?:true|false|TRUE|FALSE|True|False|yes|no)\\b"
+ }, {
+ token : "paren.lparen",
+ regex : "[[({]"
+ }, {
+ token : "paren.rparen",
+ regex : "[\\])}]"
+ }
+ ],
+ "mlString" : [
+ {
+ token : "indent",
+ regex : /^\s*$/
+ }, {
+ token : "indent",
+ regex : /^\s*/,
+ onMatch: function(val, state, stack) {
+ var curIndent = stack[1];
+
+ if (curIndent >= val.length) {
+ this.next = "start";
+ stack.splice(0);
+ }
+ else {
+ this.next = "mlString";
+ }
+ return this.token;
+ },
+ next : "mlString"
+ }, {
+ token : "string",
+ regex : '.+'
+ }
+ ]};
+ this.normalizeRules();
+
+};
+
+oop.inherits(YamlHighlightRules, TextHighlightRules);
+
+exports.YamlHighlightRules = YamlHighlightRules;
+});
+
+ace.define("ace/mode/matching_brace_outdent",["require","exports","module","ace/range"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+
+var MatchingBraceOutdent = function() {};
+
+(function() {
+
+ this.checkOutdent = function(line, input) {
+ if (! /^\s+$/.test(line))
+ return false;
+
+ return /^\s*\}/.test(input);
+ };
+
+ this.autoOutdent = function(doc, row) {
+ var line = doc.getLine(row);
+ var match = line.match(/^(\s*\})/);
+
+ if (!match) return 0;
+
+ var column = match[1].length;
+ var openBracePos = doc.findMatchingBracket({row: row, column: column});
+
+ if (!openBracePos || openBracePos.row == row) return 0;
+
+ var indent = this.$getIndent(doc.getLine(openBracePos.row));
+ doc.replace(new Range(row, 0, row, column-1), indent);
+ };
+
+ this.$getIndent = function(line) {
+ return line.match(/^\s*/)[0];
+ };
+
+}).call(MatchingBraceOutdent.prototype);
+
+exports.MatchingBraceOutdent = MatchingBraceOutdent;
+});
+
+ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../../lib/oop");
+var BaseFoldMode = require("./fold_mode").FoldMode;
+var Range = require("../../range").Range;
+
+var FoldMode = exports.FoldMode = function() {};
+oop.inherits(FoldMode, BaseFoldMode);
+
+(function() {
+
+ this.getFoldWidgetRange = function(session, foldStyle, row) {
+ var range = this.indentationBlock(session, row);
+ if (range)
+ return range;
+
+ var re = /\S/;
+ var line = session.getLine(row);
+ var startLevel = line.search(re);
+ if (startLevel == -1 || line[startLevel] != "#")
+ return;
+
+ var startColumn = line.length;
+ var maxRow = session.getLength();
+ var startRow = row;
+ var endRow = row;
+
+ while (++row < maxRow) {
+ line = session.getLine(row);
+ var level = line.search(re);
+
+ if (level == -1)
+ continue;
+
+ if (line[level] != "#")
+ break;
+
+ endRow = row;
+ }
+
+ if (endRow > startRow) {
+ var endColumn = session.getLine(endRow).length;
+ return new Range(startRow, startColumn, endRow, endColumn);
+ }
+ };
+ this.getFoldWidget = function(session, foldStyle, row) {
+ var line = session.getLine(row);
+ var indent = line.search(/\S/);
+ var next = session.getLine(row + 1);
+ var prev = session.getLine(row - 1);
+ var prevIndent = prev.search(/\S/);
+ var nextIndent = next.search(/\S/);
+
+ if (indent == -1) {
+ session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
+ return "";
+ }
+ if (prevIndent == -1) {
+ if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
+ session.foldWidgets[row - 1] = "";
+ session.foldWidgets[row + 1] = "";
+ return "start";
+ }
+ } else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
+ if (session.getLine(row - 2).search(/\S/) == -1) {
+ session.foldWidgets[row - 1] = "start";
+ session.foldWidgets[row + 1] = "";
+ return "";
+ }
+ }
+
+ if (prevIndent!= -1 && prevIndent < indent)
+ session.foldWidgets[row - 1] = "start";
+ else
+ session.foldWidgets[row - 1] = "";
+
+ if (indent < nextIndent)
+ return "start";
+ else
+ return "";
+ };
+
+}).call(FoldMode.prototype);
+
+});
+
+ace.define("ace/mode/yaml",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/yaml_highlight_rules","ace/mode/matching_brace_outdent","ace/mode/folding/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var TextMode = require("./text").Mode;
+var YamlHighlightRules = require("./yaml_highlight_rules").YamlHighlightRules;
+var MatchingBraceOutdent = require("./matching_brace_outdent").MatchingBraceOutdent;
+var FoldMode = require("./folding/coffee").FoldMode;
+
+var Mode = function() {
+ this.HighlightRules = YamlHighlightRules;
+ this.$outdent = new MatchingBraceOutdent();
+ this.foldingRules = new FoldMode();
+ this.$behaviour = this.$defaultBehaviour;
+};
+oop.inherits(Mode, TextMode);
+
+(function() {
+
+ this.lineCommentStart = "#";
+
+ this.getNextLineIndent = function(state, line, tab) {
+ var indent = this.$getIndent(line);
+
+ if (state == "start") {
+ var match = line.match(/^.*[\{\(\[]\s*$/);
+ if (match) {
+ indent += tab;
+ }
+ }
+
+ return indent;
+ };
+
+ this.checkOutdent = function(state, line, input) {
+ return this.$outdent.checkOutdent(line, input);
+ };
+
+ this.autoOutdent = function(state, doc, row) {
+ this.$outdent.autoOutdent(doc, row);
+ };
+
+
+ this.$id = "ace/mode/yaml";
+}).call(Mode.prototype);
+
+exports.Mode = Mode;
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/abap.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/abap.js
new file mode 100644
index 00000000..0ef29119
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/abap.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/abap",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "abap";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/abc.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/abc.js
new file mode 100644
index 00000000..17030761
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/abc.js
@@ -0,0 +1,38 @@
+ace.define("ace/snippets/abc",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "\n\
+snippet zupfnoter.print\n\
+ %%%%hn.print {\"startpos\": ${1:pos_y}, \"t\":\"${2:title}\", \"v\":[${3:voices}], \"s\":[[${4:syncvoices}1,2]], \"f\":[${5:flowlines}], \"sf\":[${6:subflowlines}], \"j\":[${7:jumplines}]}\n\
+\n\
+snippet zupfnoter.note\n\
+ %%%%hn.note {\"pos\": [${1:pos_x},${2:pos_y}], \"text\": \"${3:text}\", \"style\": \"${4:style}\"}\n\
+\n\
+snippet zupfnoter.annotation\n\
+ %%%%hn.annotation {\"id\": \"${1:id}\", \"pos\": [${2:pos}], \"text\": \"${3:text}\"}\n\
+\n\
+snippet zupfnoter.lyrics\n\
+ %%%%hn.lyrics {\"pos\": [${1:x_pos},${2:y_pos}]}\n\
+\n\
+snippet zupfnoter.legend\n\
+ %%%%hn.legend {\"pos\": [${1:x_pos},${2:y_pos}]}\n\
+\n\
+\n\
+\n\
+snippet zupfnoter.target\n\
+ \"^:${1:target}\"\n\
+\n\
+snippet zupfnoter.goto\n\
+ \"^@${1:target}@${2:distance}\"\n\
+\n\
+snippet zupfnoter.annotationref\n\
+ \"^#${1:target}\"\n\
+\n\
+snippet zupfnoter.annotation\n\
+ \"^!${1:text}@${2:x_offset},${3:y_offset}\"\n\
+\n\
+\n\
+";
+exports.scope = "abc";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/actionscript.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/actionscript.js
new file mode 100644
index 00000000..bc899d16
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/actionscript.js
@@ -0,0 +1,164 @@
+ace.define("ace/snippets/actionscript",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet main\n\
+ package {\n\
+ import flash.display.*;\n\
+ import flash.Events.*;\n\
+ \n\
+ public class Main extends Sprite {\n\
+ public function Main ( ) {\n\
+ trace(\"start\");\n\
+ stage.scaleMode = StageScaleMode.NO_SCALE;\n\
+ stage.addEventListener(Event.RESIZE, resizeListener);\n\
+ }\n\
+ \n\
+ private function resizeListener (e:Event):void {\n\
+ trace(\"The application window changed size!\");\n\
+ trace(\"New width: \" + stage.stageWidth);\n\
+ trace(\"New height: \" + stage.stageHeight);\n\
+ }\n\
+ \n\
+ }\n\
+ \n\
+ }\n\
+snippet class\n\
+ ${1:public|internal} class ${2:name} ${3:extends } {\n\
+ public function $2 ( ) {\n\
+ (\"start\");\n\
+ }\n\
+ }\n\
+snippet all\n\
+ package name {\n\
+\n\
+ ${1:public|internal|final} class ${2:name} ${3:extends } {\n\
+ private|public| static const FOO = \"abc\";\n\
+ private|public| static var BAR = \"abc\";\n\
+\n\
+ // class initializer - no JIT !! one time setup\n\
+ if Cababilities.os == \"Linux|MacOS\" {\n\
+ FOO = \"other\";\n\
+ }\n\
+\n\
+ // constructor:\n\
+ public function $2 ( ){\n\
+ super2();\n\
+ trace(\"start\");\n\
+ }\n\
+ public function name (a, b...){\n\
+ super.name(..);\n\
+ lable:break\n\
+ }\n\
+ }\n\
+ }\n\
+\n\
+ function A(){\n\
+ // A can only be accessed within this file\n\
+ }\n\
+snippet switch\n\
+ switch(${1}){\n\
+ case ${2}:\n\
+ ${3}\n\
+ break;\n\
+ default:\n\
+ }\n\
+snippet case\n\
+ case ${1}:\n\
+ ${2}\n\
+ break;\n\
+snippet package\n\
+ package ${1:package}{\n\
+ ${2}\n\
+ }\n\
+snippet wh\n\
+ while ${1:cond}{\n\
+ ${2}\n\
+ }\n\
+snippet do\n\
+ do {\n\
+ ${2}\n\
+ } while (${1:cond})\n\
+snippet while\n\
+ while ${1:cond}{\n\
+ ${2}\n\
+ }\n\
+snippet for enumerate names\n\
+ for (${1:var} in ${2:object}){\n\
+ ${3}\n\
+ }\n\
+snippet for enumerate values\n\
+ for each (${1:var} in ${2:object}){\n\
+ ${3}\n\
+ }\n\
+snippet get_set\n\
+ function get ${1:name} {\n\
+ return ${2}\n\
+ }\n\
+ function set $1 (newValue) {\n\
+ ${3}\n\
+ }\n\
+snippet interface\n\
+ interface name {\n\
+ function method(${1}):${2:returntype};\n\
+ }\n\
+snippet try\n\
+ try {\n\
+ ${1}\n\
+ } catch (error:ErrorType) {\n\
+ ${2}\n\
+ } finally {\n\
+ ${3}\n\
+ }\n\
+# For Loop (same as c.snippet)\n\
+snippet for for (..) {..}\n\
+ for (${2:i} = 0; $2 < ${1:count}; $2${3:++}) {\n\
+ ${4:/* code */}\n\
+ }\n\
+# Custom For Loop\n\
+snippet forr\n\
+ for (${1:i} = ${2:0}; ${3:$1 < 10}; $1${4:++}) {\n\
+ ${5:/* code */}\n\
+ }\n\
+# If Condition\n\
+snippet if\n\
+ if (${1:/* condition */}) {\n\
+ ${2:/* code */}\n\
+ }\n\
+snippet el\n\
+ else {\n\
+ ${1}\n\
+ }\n\
+# Ternary conditional\n\
+snippet t\n\
+ ${1:/* condition */} ? ${2:a} : ${3:b}\n\
+snippet fun\n\
+ function ${1:function_name}(${2})${3}\n\
+ {\n\
+ ${4:/* code */}\n\
+ }\n\
+# FlxSprite (usefull when using the flixel library)\n\
+snippet FlxSprite\n\
+ package\n\
+ {\n\
+ import org.flixel.*\n\
+\n\
+ public class ${1:ClassName} extends ${2:FlxSprite}\n\
+ {\n\
+ public function $1(${3: X:Number, Y:Number}):void\n\
+ {\n\
+ super(X,Y);\n\
+ ${4: //code...}\n\
+ }\n\
+\n\
+ override public function update():void\n\
+ {\n\
+ super.update();\n\
+ ${5: //code...}\n\
+ }\n\
+ }\n\
+ }\n\
+\n\
+";
+exports.scope = "actionscript";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/ada.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ada.js
new file mode 100644
index 00000000..656608aa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ada.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/ada",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "ada";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/apache_conf.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/apache_conf.js
new file mode 100644
index 00000000..0f38e54c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/apache_conf.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/apache_conf",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "apache_conf";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/applescript.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/applescript.js
new file mode 100644
index 00000000..6b59011a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/applescript.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/applescript",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "applescript";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/asciidoc.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/asciidoc.js
new file mode 100644
index 00000000..ef22c020
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/asciidoc.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/asciidoc",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "asciidoc";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/assembly_x86.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/assembly_x86.js
new file mode 100644
index 00000000..b3c3cd3d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/assembly_x86.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/assembly_x86",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "assembly_x86";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/autohotkey.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/autohotkey.js
new file mode 100644
index 00000000..61c8ad4e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/autohotkey.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/autohotkey",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "autohotkey";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/batchfile.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/batchfile.js
new file mode 100644
index 00000000..619f57da
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/batchfile.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/batchfile",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "batchfile";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/bro.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/bro.js
new file mode 100644
index 00000000..2f2e2e12
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/bro.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/bro",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/c9search.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/c9search.js
new file mode 100644
index 00000000..78ea3dab
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/c9search.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/c9search",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "c9search";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/c_cpp.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/c_cpp.js
new file mode 100644
index 00000000..a232b56f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/c_cpp.js
@@ -0,0 +1,138 @@
+ace.define("ace/snippets/c_cpp",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "## STL Collections\n\
+# std::array\n\
+snippet array\n\
+ std::array<${1:T}, ${2:N}> ${3};${4}\n\
+# std::vector\n\
+snippet vector\n\
+ std::vector<${1:T}> ${2};${3}\n\
+# std::deque\n\
+snippet deque\n\
+ std::deque<${1:T}> ${2};${3}\n\
+# std::forward_list\n\
+snippet flist\n\
+ std::forward_list<${1:T}> ${2};${3}\n\
+# std::list\n\
+snippet list\n\
+ std::list<${1:T}> ${2};${3}\n\
+# std::set\n\
+snippet set\n\
+ std::set<${1:T}> ${2};${3}\n\
+# std::map\n\
+snippet map\n\
+ std::map<${1:Key}, ${2:T}> ${3};${4}\n\
+# std::multiset\n\
+snippet mset\n\
+ std::multiset<${1:T}> ${2};${3}\n\
+# std::multimap\n\
+snippet mmap\n\
+ std::multimap<${1:Key}, ${2:T}> ${3};${4}\n\
+# std::unordered_set\n\
+snippet uset\n\
+ std::unordered_set<${1:T}> ${2};${3}\n\
+# std::unordered_map\n\
+snippet umap\n\
+ std::unordered_map<${1:Key}, ${2:T}> ${3};${4}\n\
+# std::unordered_multiset\n\
+snippet umset\n\
+ std::unordered_multiset<${1:T}> ${2};${3}\n\
+# std::unordered_multimap\n\
+snippet ummap\n\
+ std::unordered_multimap<${1:Key}, ${2:T}> ${3};${4}\n\
+# std::stack\n\
+snippet stack\n\
+ std::stack<${1:T}> ${2};${3}\n\
+# std::queue\n\
+snippet queue\n\
+ std::queue<${1:T}> ${2};${3}\n\
+# std::priority_queue\n\
+snippet pqueue\n\
+ std::priority_queue<${1:T}> ${2};${3}\n\
+##\n\
+## Access Modifiers\n\
+# private\n\
+snippet pri\n\
+ private\n\
+# protected\n\
+snippet pro\n\
+ protected\n\
+# public\n\
+snippet pub\n\
+ public\n\
+# friend\n\
+snippet fr\n\
+ friend\n\
+# mutable\n\
+snippet mu\n\
+ mutable\n\
+## \n\
+## Class\n\
+# class\n\
+snippet cl\n\
+ class ${1:`Filename('$1', 'name')`} \n\
+ {\n\
+ public:\n\
+ $1(${2});\n\
+ ~$1();\n\
+\n\
+ private:\n\
+ ${3:/* data */}\n\
+ };\n\
+# member function implementation\n\
+snippet mfun\n\
+ ${4:void} ${1:`Filename('$1', 'ClassName')`}::${2:memberFunction}(${3}) {\n\
+ ${5:/* code */}\n\
+ }\n\
+# namespace\n\
+snippet ns\n\
+ namespace ${1:`Filename('', 'my')`} {\n\
+ ${2}\n\
+ } /* namespace $1 */\n\
+##\n\
+## Input/Output\n\
+# std::cout\n\
+snippet cout\n\
+ std::cout << ${1} << std::endl;${2}\n\
+# std::cin\n\
+snippet cin\n\
+ std::cin >> ${1};${2}\n\
+##\n\
+## Iteration\n\
+# for i \n\
+snippet fori\n\
+ for (int ${2:i} = 0; $2 < ${1:count}; $2${3:++}) {\n\
+ ${4:/* code */}\n\
+ }${5}\n\
+\n\
+# foreach\n\
+snippet fore\n\
+ for (${1:auto} ${2:i} : ${3:container}) {\n\
+ ${4:/* code */}\n\
+ }${5}\n\
+# iterator\n\
+snippet iter\n\
+ for (${1:std::vector}<${2:type}>::${3:const_iterator} ${4:i} = ${5:container}.begin(); $4 != $5.end(); ++$4) {\n\
+ ${6}\n\
+ }${7}\n\
+\n\
+# auto iterator\n\
+snippet itera\n\
+ for (auto ${1:i} = $1.begin(); $1 != $1.end(); ++$1) {\n\
+ ${2:std::cout << *$1 << std::endl;}\n\
+ }${3}\n\
+##\n\
+## Lambdas\n\
+# lamda (one line)\n\
+snippet ld\n\
+ [${1}](${2}){${3:/* code */}}${4}\n\
+# lambda (multi-line)\n\
+snippet lld\n\
+ [${1}](${2}){\n\
+ ${3:/* code */}\n\
+ }${4}\n\
+";
+exports.scope = "c_cpp";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/cirru.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/cirru.js
new file mode 100644
index 00000000..02ef1f30
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/cirru.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/cirru",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "cirru";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/clojure.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/clojure.js
new file mode 100644
index 00000000..49f23cac
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/clojure.js
@@ -0,0 +1,97 @@
+ace.define("ace/snippets/clojure",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet comm\n\
+ (comment\n\
+ ${1}\n\
+ )\n\
+snippet condp\n\
+ (condp ${1:pred} ${2:expr}\n\
+ ${3})\n\
+snippet def\n\
+ (def ${1})\n\
+snippet defm\n\
+ (defmethod ${1:multifn} \"${2:doc-string}\" ${3:dispatch-val} [${4:args}]\n\
+ ${5})\n\
+snippet defmm\n\
+ (defmulti ${1:name} \"${2:doc-string}\" ${3:dispatch-fn})\n\
+snippet defma\n\
+ (defmacro ${1:name} \"${2:doc-string}\" ${3:dispatch-fn})\n\
+snippet defn\n\
+ (defn ${1:name} \"${2:doc-string}\" [${3:arg-list}]\n\
+ ${4})\n\
+snippet defp\n\
+ (defprotocol ${1:name}\n\
+ ${2})\n\
+snippet defr\n\
+ (defrecord ${1:name} [${2:fields}]\n\
+ ${3:protocol}\n\
+ ${4})\n\
+snippet deft\n\
+ (deftest ${1:name}\n\
+ (is (= ${2:assertion})))\n\
+ ${3})\n\
+snippet is\n\
+ (is (= ${1} ${2}))\n\
+snippet defty\n\
+ (deftype ${1:Name} [${2:fields}]\n\
+ ${3:Protocol}\n\
+ ${4})\n\
+snippet doseq\n\
+ (doseq [${1:elem} ${2:coll}]\n\
+ ${3})\n\
+snippet fn\n\
+ (fn [${1:arg-list}] ${2})\n\
+snippet if\n\
+ (if ${1:test-expr}\n\
+ ${2:then-expr}\n\
+ ${3:else-expr})\n\
+snippet if-let \n\
+ (if-let [${1:result} ${2:test-expr}]\n\
+ (${3:then-expr} $1)\n\
+ (${4:else-expr}))\n\
+snippet imp\n\
+ (:import [${1:package}])\n\
+ & {:keys [${1:keys}] :or {${2:defaults}}}\n\
+snippet let\n\
+ (let [${1:name} ${2:expr}]\n\
+ ${3})\n\
+snippet letfn\n\
+ (letfn [(${1:name) [${2:args}]\n\
+ ${3})])\n\
+snippet map\n\
+ (map ${1:func} ${2:coll})\n\
+snippet mapl\n\
+ (map #(${1:lambda}) ${2:coll})\n\
+snippet met\n\
+ (${1:name} [${2:this} ${3:args}]\n\
+ ${4})\n\
+snippet ns\n\
+ (ns ${1:name}\n\
+ ${2})\n\
+snippet dotimes\n\
+ (dotimes [_ 10]\n\
+ (time\n\
+ (dotimes [_ ${1:times}]\n\
+ ${2})))\n\
+snippet pmethod\n\
+ (${1:name} [${2:this} ${3:args}])\n\
+snippet refer\n\
+ (:refer-clojure :exclude [${1}])\n\
+snippet require\n\
+ (:require [${1:namespace} :as [${2}]])\n\
+snippet use\n\
+ (:use [${1:namespace} :only [${2}]])\n\
+snippet print\n\
+ (println ${1})\n\
+snippet reduce\n\
+ (reduce ${1:(fn [p n] ${3})} ${2})\n\
+snippet when\n\
+ (when ${1:test} ${2:body})\n\
+snippet when-let\n\
+ (when-let [${1:result} ${2:test}]\n\
+ ${3:body})\n\
+";
+exports.scope = "clojure";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/cobol.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/cobol.js
new file mode 100644
index 00000000..760727ce
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/cobol.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/cobol",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "cobol";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/coffee.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/coffee.js
new file mode 100644
index 00000000..eb1a76d7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/coffee.js
@@ -0,0 +1,102 @@
+ace.define("ace/snippets/coffee",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Closure loop\n\
+snippet forindo\n\
+ for ${1:name} in ${2:array}\n\
+ do ($1) ->\n\
+ ${3:// body}\n\
+# Array comprehension\n\
+snippet fora\n\
+ for ${1:name} in ${2:array}\n\
+ ${3:// body...}\n\
+# Object comprehension\n\
+snippet foro\n\
+ for ${1:key}, ${2:value} of ${3:object}\n\
+ ${4:// body...}\n\
+# Range comprehension (inclusive)\n\
+snippet forr\n\
+ for ${1:name} in [${2:start}..${3:finish}]\n\
+ ${4:// body...}\n\
+snippet forrb\n\
+ for ${1:name} in [${2:start}..${3:finish}] by ${4:step}\n\
+ ${5:// body...}\n\
+# Range comprehension (exclusive)\n\
+snippet forrex\n\
+ for ${1:name} in [${2:start}...${3:finish}]\n\
+ ${4:// body...}\n\
+snippet forrexb\n\
+ for ${1:name} in [${2:start}...${3:finish}] by ${4:step}\n\
+ ${5:// body...}\n\
+# Function\n\
+snippet fun\n\
+ (${1:args}) ->\n\
+ ${2:// body...}\n\
+# Function (bound)\n\
+snippet bfun\n\
+ (${1:args}) =>\n\
+ ${2:// body...}\n\
+# Class\n\
+snippet cla class ..\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ ${2}\n\
+snippet cla class .. constructor: ..\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ constructor: (${2:args}) ->\n\
+ ${3}\n\
+\n\
+ ${4}\n\
+snippet cla class .. extends ..\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`} extends ${2:ParentClass}\n\
+ ${3}\n\
+snippet cla class .. extends .. constructor: ..\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`} extends ${2:ParentClass}\n\
+ constructor: (${3:args}) ->\n\
+ ${4}\n\
+\n\
+ ${5}\n\
+# If\n\
+snippet if\n\
+ if ${1:condition}\n\
+ ${2:// body...}\n\
+# If __ Else\n\
+snippet ife\n\
+ if ${1:condition}\n\
+ ${2:// body...}\n\
+ else\n\
+ ${3:// body...}\n\
+# Else if\n\
+snippet elif\n\
+ else if ${1:condition}\n\
+ ${2:// body...}\n\
+# Ternary If\n\
+snippet ifte\n\
+ if ${1:condition} then ${2:value} else ${3:other}\n\
+# Unless\n\
+snippet unl\n\
+ ${1:action} unless ${2:condition}\n\
+# Switch\n\
+snippet swi\n\
+ switch ${1:object}\n\
+ when ${2:value}\n\
+ ${3:// body...}\n\
+\n\
+# Log\n\
+snippet log\n\
+ console.log ${1}\n\
+# Try __ Catch\n\
+snippet try\n\
+ try\n\
+ ${1}\n\
+ catch ${2:error}\n\
+ ${3}\n\
+# Require\n\
+snippet req\n\
+ ${2:$1} = require '${1:sys}'${3}\n\
+# Export\n\
+snippet exp\n\
+ ${1:root} = exports ? this\n\
+";
+exports.scope = "coffee";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/coldfusion.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/coldfusion.js
new file mode 100644
index 00000000..1a91f967
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/coldfusion.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/coldfusion",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "coldfusion";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/csharp.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/csharp.js
new file mode 100644
index 00000000..96b9174a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/csharp.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/csharp",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "csharp";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/css.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/css.js
new file mode 100644
index 00000000..db5a8c0a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/css.js
@@ -0,0 +1,974 @@
+ace.define("ace/snippets/css",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet .\n\
+ ${1} {\n\
+ ${2}\n\
+ }\n\
+snippet !\n\
+ !important\n\
+snippet bdi:m+\n\
+ -moz-border-image: url(${1}) ${2:0} ${3:0} ${4:0} ${5:0} ${6:stretch} ${7:stretch};\n\
+snippet bdi:m\n\
+ -moz-border-image: ${1};\n\
+snippet bdrz:m\n\
+ -moz-border-radius: ${1};\n\
+snippet bxsh:m+\n\
+ -moz-box-shadow: ${1:0} ${2:0} ${3:0} #${4:000};\n\
+snippet bxsh:m\n\
+ -moz-box-shadow: ${1};\n\
+snippet bdi:w+\n\
+ -webkit-border-image: url(${1}) ${2:0} ${3:0} ${4:0} ${5:0} ${6:stretch} ${7:stretch};\n\
+snippet bdi:w\n\
+ -webkit-border-image: ${1};\n\
+snippet bdrz:w\n\
+ -webkit-border-radius: ${1};\n\
+snippet bxsh:w+\n\
+ -webkit-box-shadow: ${1:0} ${2:0} ${3:0} #${4:000};\n\
+snippet bxsh:w\n\
+ -webkit-box-shadow: ${1};\n\
+snippet @f\n\
+ @font-face {\n\
+ font-family: ${1};\n\
+ src: url(${2});\n\
+ }\n\
+snippet @i\n\
+ @import url(${1});\n\
+snippet @m\n\
+ @media ${1:print} {\n\
+ ${2}\n\
+ }\n\
+snippet bg+\n\
+ background: #${1:FFF} url(${2}) ${3:0} ${4:0} ${5:no-repeat};\n\
+snippet bga\n\
+ background-attachment: ${1};\n\
+snippet bga:f\n\
+ background-attachment: fixed;\n\
+snippet bga:s\n\
+ background-attachment: scroll;\n\
+snippet bgbk\n\
+ background-break: ${1};\n\
+snippet bgbk:bb\n\
+ background-break: bounding-box;\n\
+snippet bgbk:c\n\
+ background-break: continuous;\n\
+snippet bgbk:eb\n\
+ background-break: each-box;\n\
+snippet bgcp\n\
+ background-clip: ${1};\n\
+snippet bgcp:bb\n\
+ background-clip: border-box;\n\
+snippet bgcp:cb\n\
+ background-clip: content-box;\n\
+snippet bgcp:nc\n\
+ background-clip: no-clip;\n\
+snippet bgcp:pb\n\
+ background-clip: padding-box;\n\
+snippet bgc\n\
+ background-color: #${1:FFF};\n\
+snippet bgc:t\n\
+ background-color: transparent;\n\
+snippet bgi\n\
+ background-image: url(${1});\n\
+snippet bgi:n\n\
+ background-image: none;\n\
+snippet bgo\n\
+ background-origin: ${1};\n\
+snippet bgo:bb\n\
+ background-origin: border-box;\n\
+snippet bgo:cb\n\
+ background-origin: content-box;\n\
+snippet bgo:pb\n\
+ background-origin: padding-box;\n\
+snippet bgpx\n\
+ background-position-x: ${1};\n\
+snippet bgpy\n\
+ background-position-y: ${1};\n\
+snippet bgp\n\
+ background-position: ${1:0} ${2:0};\n\
+snippet bgr\n\
+ background-repeat: ${1};\n\
+snippet bgr:n\n\
+ background-repeat: no-repeat;\n\
+snippet bgr:x\n\
+ background-repeat: repeat-x;\n\
+snippet bgr:y\n\
+ background-repeat: repeat-y;\n\
+snippet bgr:r\n\
+ background-repeat: repeat;\n\
+snippet bgz\n\
+ background-size: ${1};\n\
+snippet bgz:a\n\
+ background-size: auto;\n\
+snippet bgz:ct\n\
+ background-size: contain;\n\
+snippet bgz:cv\n\
+ background-size: cover;\n\
+snippet bg\n\
+ background: ${1};\n\
+snippet bg:ie\n\
+ filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='${1}',sizingMethod='${2:crop}');\n\
+snippet bg:n\n\
+ background: none;\n\
+snippet bd+\n\
+ border: ${1:1px} ${2:solid} #${3:000};\n\
+snippet bdb+\n\
+ border-bottom: ${1:1px} ${2:solid} #${3:000};\n\
+snippet bdbc\n\
+ border-bottom-color: #${1:000};\n\
+snippet bdbi\n\
+ border-bottom-image: url(${1});\n\
+snippet bdbi:n\n\
+ border-bottom-image: none;\n\
+snippet bdbli\n\
+ border-bottom-left-image: url(${1});\n\
+snippet bdbli:c\n\
+ border-bottom-left-image: continue;\n\
+snippet bdbli:n\n\
+ border-bottom-left-image: none;\n\
+snippet bdblrz\n\
+ border-bottom-left-radius: ${1};\n\
+snippet bdbri\n\
+ border-bottom-right-image: url(${1});\n\
+snippet bdbri:c\n\
+ border-bottom-right-image: continue;\n\
+snippet bdbri:n\n\
+ border-bottom-right-image: none;\n\
+snippet bdbrrz\n\
+ border-bottom-right-radius: ${1};\n\
+snippet bdbs\n\
+ border-bottom-style: ${1};\n\
+snippet bdbs:n\n\
+ border-bottom-style: none;\n\
+snippet bdbw\n\
+ border-bottom-width: ${1};\n\
+snippet bdb\n\
+ border-bottom: ${1};\n\
+snippet bdb:n\n\
+ border-bottom: none;\n\
+snippet bdbk\n\
+ border-break: ${1};\n\
+snippet bdbk:c\n\
+ border-break: close;\n\
+snippet bdcl\n\
+ border-collapse: ${1};\n\
+snippet bdcl:c\n\
+ border-collapse: collapse;\n\
+snippet bdcl:s\n\
+ border-collapse: separate;\n\
+snippet bdc\n\
+ border-color: #${1:000};\n\
+snippet bdci\n\
+ border-corner-image: url(${1});\n\
+snippet bdci:c\n\
+ border-corner-image: continue;\n\
+snippet bdci:n\n\
+ border-corner-image: none;\n\
+snippet bdf\n\
+ border-fit: ${1};\n\
+snippet bdf:c\n\
+ border-fit: clip;\n\
+snippet bdf:of\n\
+ border-fit: overwrite;\n\
+snippet bdf:ow\n\
+ border-fit: overwrite;\n\
+snippet bdf:r\n\
+ border-fit: repeat;\n\
+snippet bdf:sc\n\
+ border-fit: scale;\n\
+snippet bdf:sp\n\
+ border-fit: space;\n\
+snippet bdf:st\n\
+ border-fit: stretch;\n\
+snippet bdi\n\
+ border-image: url(${1}) ${2:0} ${3:0} ${4:0} ${5:0} ${6:stretch} ${7:stretch};\n\
+snippet bdi:n\n\
+ border-image: none;\n\
+snippet bdl+\n\
+ border-left: ${1:1px} ${2:solid} #${3:000};\n\
+snippet bdlc\n\
+ border-left-color: #${1:000};\n\
+snippet bdli\n\
+ border-left-image: url(${1});\n\
+snippet bdli:n\n\
+ border-left-image: none;\n\
+snippet bdls\n\
+ border-left-style: ${1};\n\
+snippet bdls:n\n\
+ border-left-style: none;\n\
+snippet bdlw\n\
+ border-left-width: ${1};\n\
+snippet bdl\n\
+ border-left: ${1};\n\
+snippet bdl:n\n\
+ border-left: none;\n\
+snippet bdlt\n\
+ border-length: ${1};\n\
+snippet bdlt:a\n\
+ border-length: auto;\n\
+snippet bdrz\n\
+ border-radius: ${1};\n\
+snippet bdr+\n\
+ border-right: ${1:1px} ${2:solid} #${3:000};\n\
+snippet bdrc\n\
+ border-right-color: #${1:000};\n\
+snippet bdri\n\
+ border-right-image: url(${1});\n\
+snippet bdri:n\n\
+ border-right-image: none;\n\
+snippet bdrs\n\
+ border-right-style: ${1};\n\
+snippet bdrs:n\n\
+ border-right-style: none;\n\
+snippet bdrw\n\
+ border-right-width: ${1};\n\
+snippet bdr\n\
+ border-right: ${1};\n\
+snippet bdr:n\n\
+ border-right: none;\n\
+snippet bdsp\n\
+ border-spacing: ${1};\n\
+snippet bds\n\
+ border-style: ${1};\n\
+snippet bds:ds\n\
+ border-style: dashed;\n\
+snippet bds:dtds\n\
+ border-style: dot-dash;\n\
+snippet bds:dtdtds\n\
+ border-style: dot-dot-dash;\n\
+snippet bds:dt\n\
+ border-style: dotted;\n\
+snippet bds:db\n\
+ border-style: double;\n\
+snippet bds:g\n\
+ border-style: groove;\n\
+snippet bds:h\n\
+ border-style: hidden;\n\
+snippet bds:i\n\
+ border-style: inset;\n\
+snippet bds:n\n\
+ border-style: none;\n\
+snippet bds:o\n\
+ border-style: outset;\n\
+snippet bds:r\n\
+ border-style: ridge;\n\
+snippet bds:s\n\
+ border-style: solid;\n\
+snippet bds:w\n\
+ border-style: wave;\n\
+snippet bdt+\n\
+ border-top: ${1:1px} ${2:solid} #${3:000};\n\
+snippet bdtc\n\
+ border-top-color: #${1:000};\n\
+snippet bdti\n\
+ border-top-image: url(${1});\n\
+snippet bdti:n\n\
+ border-top-image: none;\n\
+snippet bdtli\n\
+ border-top-left-image: url(${1});\n\
+snippet bdtli:c\n\
+ border-corner-image: continue;\n\
+snippet bdtli:n\n\
+ border-corner-image: none;\n\
+snippet bdtlrz\n\
+ border-top-left-radius: ${1};\n\
+snippet bdtri\n\
+ border-top-right-image: url(${1});\n\
+snippet bdtri:c\n\
+ border-top-right-image: continue;\n\
+snippet bdtri:n\n\
+ border-top-right-image: none;\n\
+snippet bdtrrz\n\
+ border-top-right-radius: ${1};\n\
+snippet bdts\n\
+ border-top-style: ${1};\n\
+snippet bdts:n\n\
+ border-top-style: none;\n\
+snippet bdtw\n\
+ border-top-width: ${1};\n\
+snippet bdt\n\
+ border-top: ${1};\n\
+snippet bdt:n\n\
+ border-top: none;\n\
+snippet bdw\n\
+ border-width: ${1};\n\
+snippet bd\n\
+ border: ${1};\n\
+snippet bd:n\n\
+ border: none;\n\
+snippet b\n\
+ bottom: ${1};\n\
+snippet b:a\n\
+ bottom: auto;\n\
+snippet bxsh+\n\
+ box-shadow: ${1:0} ${2:0} ${3:0} #${4:000};\n\
+snippet bxsh\n\
+ box-shadow: ${1};\n\
+snippet bxsh:n\n\
+ box-shadow: none;\n\
+snippet bxz\n\
+ box-sizing: ${1};\n\
+snippet bxz:bb\n\
+ box-sizing: border-box;\n\
+snippet bxz:cb\n\
+ box-sizing: content-box;\n\
+snippet cps\n\
+ caption-side: ${1};\n\
+snippet cps:b\n\
+ caption-side: bottom;\n\
+snippet cps:t\n\
+ caption-side: top;\n\
+snippet cl\n\
+ clear: ${1};\n\
+snippet cl:b\n\
+ clear: both;\n\
+snippet cl:l\n\
+ clear: left;\n\
+snippet cl:n\n\
+ clear: none;\n\
+snippet cl:r\n\
+ clear: right;\n\
+snippet cp\n\
+ clip: ${1};\n\
+snippet cp:a\n\
+ clip: auto;\n\
+snippet cp:r\n\
+ clip: rect(${1:0} ${2:0} ${3:0} ${4:0});\n\
+snippet c\n\
+ color: #${1:000};\n\
+snippet ct\n\
+ content: ${1};\n\
+snippet ct:a\n\
+ content: attr(${1});\n\
+snippet ct:cq\n\
+ content: close-quote;\n\
+snippet ct:c\n\
+ content: counter(${1});\n\
+snippet ct:cs\n\
+ content: counters(${1});\n\
+snippet ct:ncq\n\
+ content: no-close-quote;\n\
+snippet ct:noq\n\
+ content: no-open-quote;\n\
+snippet ct:n\n\
+ content: normal;\n\
+snippet ct:oq\n\
+ content: open-quote;\n\
+snippet coi\n\
+ counter-increment: ${1};\n\
+snippet cor\n\
+ counter-reset: ${1};\n\
+snippet cur\n\
+ cursor: ${1};\n\
+snippet cur:a\n\
+ cursor: auto;\n\
+snippet cur:c\n\
+ cursor: crosshair;\n\
+snippet cur:d\n\
+ cursor: default;\n\
+snippet cur:ha\n\
+ cursor: hand;\n\
+snippet cur:he\n\
+ cursor: help;\n\
+snippet cur:m\n\
+ cursor: move;\n\
+snippet cur:p\n\
+ cursor: pointer;\n\
+snippet cur:t\n\
+ cursor: text;\n\
+snippet d\n\
+ display: ${1};\n\
+snippet d:mib\n\
+ display: -moz-inline-box;\n\
+snippet d:mis\n\
+ display: -moz-inline-stack;\n\
+snippet d:b\n\
+ display: block;\n\
+snippet d:cp\n\
+ display: compact;\n\
+snippet d:ib\n\
+ display: inline-block;\n\
+snippet d:itb\n\
+ display: inline-table;\n\
+snippet d:i\n\
+ display: inline;\n\
+snippet d:li\n\
+ display: list-item;\n\
+snippet d:n\n\
+ display: none;\n\
+snippet d:ri\n\
+ display: run-in;\n\
+snippet d:tbcp\n\
+ display: table-caption;\n\
+snippet d:tbc\n\
+ display: table-cell;\n\
+snippet d:tbclg\n\
+ display: table-column-group;\n\
+snippet d:tbcl\n\
+ display: table-column;\n\
+snippet d:tbfg\n\
+ display: table-footer-group;\n\
+snippet d:tbhg\n\
+ display: table-header-group;\n\
+snippet d:tbrg\n\
+ display: table-row-group;\n\
+snippet d:tbr\n\
+ display: table-row;\n\
+snippet d:tb\n\
+ display: table;\n\
+snippet ec\n\
+ empty-cells: ${1};\n\
+snippet ec:h\n\
+ empty-cells: hide;\n\
+snippet ec:s\n\
+ empty-cells: show;\n\
+snippet exp\n\
+ expression()\n\
+snippet fl\n\
+ float: ${1};\n\
+snippet fl:l\n\
+ float: left;\n\
+snippet fl:n\n\
+ float: none;\n\
+snippet fl:r\n\
+ float: right;\n\
+snippet f+\n\
+ font: ${1:1em} ${2:Arial},${3:sans-serif};\n\
+snippet fef\n\
+ font-effect: ${1};\n\
+snippet fef:eb\n\
+ font-effect: emboss;\n\
+snippet fef:eg\n\
+ font-effect: engrave;\n\
+snippet fef:n\n\
+ font-effect: none;\n\
+snippet fef:o\n\
+ font-effect: outline;\n\
+snippet femp\n\
+ font-emphasize-position: ${1};\n\
+snippet femp:a\n\
+ font-emphasize-position: after;\n\
+snippet femp:b\n\
+ font-emphasize-position: before;\n\
+snippet fems\n\
+ font-emphasize-style: ${1};\n\
+snippet fems:ac\n\
+ font-emphasize-style: accent;\n\
+snippet fems:c\n\
+ font-emphasize-style: circle;\n\
+snippet fems:ds\n\
+ font-emphasize-style: disc;\n\
+snippet fems:dt\n\
+ font-emphasize-style: dot;\n\
+snippet fems:n\n\
+ font-emphasize-style: none;\n\
+snippet fem\n\
+ font-emphasize: ${1};\n\
+snippet ff\n\
+ font-family: ${1};\n\
+snippet ff:c\n\
+ font-family: ${1:'Monotype Corsiva','Comic Sans MS'},cursive;\n\
+snippet ff:f\n\
+ font-family: ${1:Capitals,Impact},fantasy;\n\
+snippet ff:m\n\
+ font-family: ${1:Monaco,'Courier New'},monospace;\n\
+snippet ff:ss\n\
+ font-family: ${1:Helvetica,Arial},sans-serif;\n\
+snippet ff:s\n\
+ font-family: ${1:Georgia,'Times New Roman'},serif;\n\
+snippet fza\n\
+ font-size-adjust: ${1};\n\
+snippet fza:n\n\
+ font-size-adjust: none;\n\
+snippet fz\n\
+ font-size: ${1};\n\
+snippet fsm\n\
+ font-smooth: ${1};\n\
+snippet fsm:aw\n\
+ font-smooth: always;\n\
+snippet fsm:a\n\
+ font-smooth: auto;\n\
+snippet fsm:n\n\
+ font-smooth: never;\n\
+snippet fst\n\
+ font-stretch: ${1};\n\
+snippet fst:c\n\
+ font-stretch: condensed;\n\
+snippet fst:e\n\
+ font-stretch: expanded;\n\
+snippet fst:ec\n\
+ font-stretch: extra-condensed;\n\
+snippet fst:ee\n\
+ font-stretch: extra-expanded;\n\
+snippet fst:n\n\
+ font-stretch: normal;\n\
+snippet fst:sc\n\
+ font-stretch: semi-condensed;\n\
+snippet fst:se\n\
+ font-stretch: semi-expanded;\n\
+snippet fst:uc\n\
+ font-stretch: ultra-condensed;\n\
+snippet fst:ue\n\
+ font-stretch: ultra-expanded;\n\
+snippet fs\n\
+ font-style: ${1};\n\
+snippet fs:i\n\
+ font-style: italic;\n\
+snippet fs:n\n\
+ font-style: normal;\n\
+snippet fs:o\n\
+ font-style: oblique;\n\
+snippet fv\n\
+ font-variant: ${1};\n\
+snippet fv:n\n\
+ font-variant: normal;\n\
+snippet fv:sc\n\
+ font-variant: small-caps;\n\
+snippet fw\n\
+ font-weight: ${1};\n\
+snippet fw:b\n\
+ font-weight: bold;\n\
+snippet fw:br\n\
+ font-weight: bolder;\n\
+snippet fw:lr\n\
+ font-weight: lighter;\n\
+snippet fw:n\n\
+ font-weight: normal;\n\
+snippet f\n\
+ font: ${1};\n\
+snippet h\n\
+ height: ${1};\n\
+snippet h:a\n\
+ height: auto;\n\
+snippet l\n\
+ left: ${1};\n\
+snippet l:a\n\
+ left: auto;\n\
+snippet lts\n\
+ letter-spacing: ${1};\n\
+snippet lh\n\
+ line-height: ${1};\n\
+snippet lisi\n\
+ list-style-image: url(${1});\n\
+snippet lisi:n\n\
+ list-style-image: none;\n\
+snippet lisp\n\
+ list-style-position: ${1};\n\
+snippet lisp:i\n\
+ list-style-position: inside;\n\
+snippet lisp:o\n\
+ list-style-position: outside;\n\
+snippet list\n\
+ list-style-type: ${1};\n\
+snippet list:c\n\
+ list-style-type: circle;\n\
+snippet list:dclz\n\
+ list-style-type: decimal-leading-zero;\n\
+snippet list:dc\n\
+ list-style-type: decimal;\n\
+snippet list:d\n\
+ list-style-type: disc;\n\
+snippet list:lr\n\
+ list-style-type: lower-roman;\n\
+snippet list:n\n\
+ list-style-type: none;\n\
+snippet list:s\n\
+ list-style-type: square;\n\
+snippet list:ur\n\
+ list-style-type: upper-roman;\n\
+snippet lis\n\
+ list-style: ${1};\n\
+snippet lis:n\n\
+ list-style: none;\n\
+snippet mb\n\
+ margin-bottom: ${1};\n\
+snippet mb:a\n\
+ margin-bottom: auto;\n\
+snippet ml\n\
+ margin-left: ${1};\n\
+snippet ml:a\n\
+ margin-left: auto;\n\
+snippet mr\n\
+ margin-right: ${1};\n\
+snippet mr:a\n\
+ margin-right: auto;\n\
+snippet mt\n\
+ margin-top: ${1};\n\
+snippet mt:a\n\
+ margin-top: auto;\n\
+snippet m\n\
+ margin: ${1};\n\
+snippet m:4\n\
+ margin: ${1:0} ${2:0} ${3:0} ${4:0};\n\
+snippet m:3\n\
+ margin: ${1:0} ${2:0} ${3:0};\n\
+snippet m:2\n\
+ margin: ${1:0} ${2:0};\n\
+snippet m:0\n\
+ margin: 0;\n\
+snippet m:a\n\
+ margin: auto;\n\
+snippet mah\n\
+ max-height: ${1};\n\
+snippet mah:n\n\
+ max-height: none;\n\
+snippet maw\n\
+ max-width: ${1};\n\
+snippet maw:n\n\
+ max-width: none;\n\
+snippet mih\n\
+ min-height: ${1};\n\
+snippet miw\n\
+ min-width: ${1};\n\
+snippet op\n\
+ opacity: ${1};\n\
+snippet op:ie\n\
+ filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=${1:100});\n\
+snippet op:ms\n\
+ -ms-filter: 'progid:DXImageTransform.Microsoft.Alpha(Opacity=${1:100})';\n\
+snippet orp\n\
+ orphans: ${1};\n\
+snippet o+\n\
+ outline: ${1:1px} ${2:solid} #${3:000};\n\
+snippet oc\n\
+ outline-color: ${1:#000};\n\
+snippet oc:i\n\
+ outline-color: invert;\n\
+snippet oo\n\
+ outline-offset: ${1};\n\
+snippet os\n\
+ outline-style: ${1};\n\
+snippet ow\n\
+ outline-width: ${1};\n\
+snippet o\n\
+ outline: ${1};\n\
+snippet o:n\n\
+ outline: none;\n\
+snippet ovs\n\
+ overflow-style: ${1};\n\
+snippet ovs:a\n\
+ overflow-style: auto;\n\
+snippet ovs:mq\n\
+ overflow-style: marquee;\n\
+snippet ovs:mv\n\
+ overflow-style: move;\n\
+snippet ovs:p\n\
+ overflow-style: panner;\n\
+snippet ovs:s\n\
+ overflow-style: scrollbar;\n\
+snippet ovx\n\
+ overflow-x: ${1};\n\
+snippet ovx:a\n\
+ overflow-x: auto;\n\
+snippet ovx:h\n\
+ overflow-x: hidden;\n\
+snippet ovx:s\n\
+ overflow-x: scroll;\n\
+snippet ovx:v\n\
+ overflow-x: visible;\n\
+snippet ovy\n\
+ overflow-y: ${1};\n\
+snippet ovy:a\n\
+ overflow-y: auto;\n\
+snippet ovy:h\n\
+ overflow-y: hidden;\n\
+snippet ovy:s\n\
+ overflow-y: scroll;\n\
+snippet ovy:v\n\
+ overflow-y: visible;\n\
+snippet ov\n\
+ overflow: ${1};\n\
+snippet ov:a\n\
+ overflow: auto;\n\
+snippet ov:h\n\
+ overflow: hidden;\n\
+snippet ov:s\n\
+ overflow: scroll;\n\
+snippet ov:v\n\
+ overflow: visible;\n\
+snippet pb\n\
+ padding-bottom: ${1};\n\
+snippet pl\n\
+ padding-left: ${1};\n\
+snippet pr\n\
+ padding-right: ${1};\n\
+snippet pt\n\
+ padding-top: ${1};\n\
+snippet p\n\
+ padding: ${1};\n\
+snippet p:4\n\
+ padding: ${1:0} ${2:0} ${3:0} ${4:0};\n\
+snippet p:3\n\
+ padding: ${1:0} ${2:0} ${3:0};\n\
+snippet p:2\n\
+ padding: ${1:0} ${2:0};\n\
+snippet p:0\n\
+ padding: 0;\n\
+snippet pgba\n\
+ page-break-after: ${1};\n\
+snippet pgba:aw\n\
+ page-break-after: always;\n\
+snippet pgba:a\n\
+ page-break-after: auto;\n\
+snippet pgba:l\n\
+ page-break-after: left;\n\
+snippet pgba:r\n\
+ page-break-after: right;\n\
+snippet pgbb\n\
+ page-break-before: ${1};\n\
+snippet pgbb:aw\n\
+ page-break-before: always;\n\
+snippet pgbb:a\n\
+ page-break-before: auto;\n\
+snippet pgbb:l\n\
+ page-break-before: left;\n\
+snippet pgbb:r\n\
+ page-break-before: right;\n\
+snippet pgbi\n\
+ page-break-inside: ${1};\n\
+snippet pgbi:a\n\
+ page-break-inside: auto;\n\
+snippet pgbi:av\n\
+ page-break-inside: avoid;\n\
+snippet pos\n\
+ position: ${1};\n\
+snippet pos:a\n\
+ position: absolute;\n\
+snippet pos:f\n\
+ position: fixed;\n\
+snippet pos:r\n\
+ position: relative;\n\
+snippet pos:s\n\
+ position: static;\n\
+snippet q\n\
+ quotes: ${1};\n\
+snippet q:en\n\
+ quotes: '\\201C' '\\201D' '\\2018' '\\2019';\n\
+snippet q:n\n\
+ quotes: none;\n\
+snippet q:ru\n\
+ quotes: '\\00AB' '\\00BB' '\\201E' '\\201C';\n\
+snippet rz\n\
+ resize: ${1};\n\
+snippet rz:b\n\
+ resize: both;\n\
+snippet rz:h\n\
+ resize: horizontal;\n\
+snippet rz:n\n\
+ resize: none;\n\
+snippet rz:v\n\
+ resize: vertical;\n\
+snippet r\n\
+ right: ${1};\n\
+snippet r:a\n\
+ right: auto;\n\
+snippet tbl\n\
+ table-layout: ${1};\n\
+snippet tbl:a\n\
+ table-layout: auto;\n\
+snippet tbl:f\n\
+ table-layout: fixed;\n\
+snippet tal\n\
+ text-align-last: ${1};\n\
+snippet tal:a\n\
+ text-align-last: auto;\n\
+snippet tal:c\n\
+ text-align-last: center;\n\
+snippet tal:l\n\
+ text-align-last: left;\n\
+snippet tal:r\n\
+ text-align-last: right;\n\
+snippet ta\n\
+ text-align: ${1};\n\
+snippet ta:c\n\
+ text-align: center;\n\
+snippet ta:l\n\
+ text-align: left;\n\
+snippet ta:r\n\
+ text-align: right;\n\
+snippet td\n\
+ text-decoration: ${1};\n\
+snippet td:l\n\
+ text-decoration: line-through;\n\
+snippet td:n\n\
+ text-decoration: none;\n\
+snippet td:o\n\
+ text-decoration: overline;\n\
+snippet td:u\n\
+ text-decoration: underline;\n\
+snippet te\n\
+ text-emphasis: ${1};\n\
+snippet te:ac\n\
+ text-emphasis: accent;\n\
+snippet te:a\n\
+ text-emphasis: after;\n\
+snippet te:b\n\
+ text-emphasis: before;\n\
+snippet te:c\n\
+ text-emphasis: circle;\n\
+snippet te:ds\n\
+ text-emphasis: disc;\n\
+snippet te:dt\n\
+ text-emphasis: dot;\n\
+snippet te:n\n\
+ text-emphasis: none;\n\
+snippet th\n\
+ text-height: ${1};\n\
+snippet th:a\n\
+ text-height: auto;\n\
+snippet th:f\n\
+ text-height: font-size;\n\
+snippet th:m\n\
+ text-height: max-size;\n\
+snippet th:t\n\
+ text-height: text-size;\n\
+snippet ti\n\
+ text-indent: ${1};\n\
+snippet ti:-\n\
+ text-indent: -9999px;\n\
+snippet tj\n\
+ text-justify: ${1};\n\
+snippet tj:a\n\
+ text-justify: auto;\n\
+snippet tj:d\n\
+ text-justify: distribute;\n\
+snippet tj:ic\n\
+ text-justify: inter-cluster;\n\
+snippet tj:ii\n\
+ text-justify: inter-ideograph;\n\
+snippet tj:iw\n\
+ text-justify: inter-word;\n\
+snippet tj:k\n\
+ text-justify: kashida;\n\
+snippet tj:t\n\
+ text-justify: tibetan;\n\
+snippet to+\n\
+ text-outline: ${1:0} ${2:0} #${3:000};\n\
+snippet to\n\
+ text-outline: ${1};\n\
+snippet to:n\n\
+ text-outline: none;\n\
+snippet tr\n\
+ text-replace: ${1};\n\
+snippet tr:n\n\
+ text-replace: none;\n\
+snippet tsh+\n\
+ text-shadow: ${1:0} ${2:0} ${3:0} #${4:000};\n\
+snippet tsh\n\
+ text-shadow: ${1};\n\
+snippet tsh:n\n\
+ text-shadow: none;\n\
+snippet tt\n\
+ text-transform: ${1};\n\
+snippet tt:c\n\
+ text-transform: capitalize;\n\
+snippet tt:l\n\
+ text-transform: lowercase;\n\
+snippet tt:n\n\
+ text-transform: none;\n\
+snippet tt:u\n\
+ text-transform: uppercase;\n\
+snippet tw\n\
+ text-wrap: ${1};\n\
+snippet tw:no\n\
+ text-wrap: none;\n\
+snippet tw:n\n\
+ text-wrap: normal;\n\
+snippet tw:s\n\
+ text-wrap: suppress;\n\
+snippet tw:u\n\
+ text-wrap: unrestricted;\n\
+snippet t\n\
+ top: ${1};\n\
+snippet t:a\n\
+ top: auto;\n\
+snippet va\n\
+ vertical-align: ${1};\n\
+snippet va:bl\n\
+ vertical-align: baseline;\n\
+snippet va:b\n\
+ vertical-align: bottom;\n\
+snippet va:m\n\
+ vertical-align: middle;\n\
+snippet va:sub\n\
+ vertical-align: sub;\n\
+snippet va:sup\n\
+ vertical-align: super;\n\
+snippet va:tb\n\
+ vertical-align: text-bottom;\n\
+snippet va:tt\n\
+ vertical-align: text-top;\n\
+snippet va:t\n\
+ vertical-align: top;\n\
+snippet v\n\
+ visibility: ${1};\n\
+snippet v:c\n\
+ visibility: collapse;\n\
+snippet v:h\n\
+ visibility: hidden;\n\
+snippet v:v\n\
+ visibility: visible;\n\
+snippet whsc\n\
+ white-space-collapse: ${1};\n\
+snippet whsc:ba\n\
+ white-space-collapse: break-all;\n\
+snippet whsc:bs\n\
+ white-space-collapse: break-strict;\n\
+snippet whsc:k\n\
+ white-space-collapse: keep-all;\n\
+snippet whsc:l\n\
+ white-space-collapse: loose;\n\
+snippet whsc:n\n\
+ white-space-collapse: normal;\n\
+snippet whs\n\
+ white-space: ${1};\n\
+snippet whs:n\n\
+ white-space: normal;\n\
+snippet whs:nw\n\
+ white-space: nowrap;\n\
+snippet whs:pl\n\
+ white-space: pre-line;\n\
+snippet whs:pw\n\
+ white-space: pre-wrap;\n\
+snippet whs:p\n\
+ white-space: pre;\n\
+snippet wid\n\
+ widows: ${1};\n\
+snippet w\n\
+ width: ${1};\n\
+snippet w:a\n\
+ width: auto;\n\
+snippet wob\n\
+ word-break: ${1};\n\
+snippet wob:ba\n\
+ word-break: break-all;\n\
+snippet wob:bs\n\
+ word-break: break-strict;\n\
+snippet wob:k\n\
+ word-break: keep-all;\n\
+snippet wob:l\n\
+ word-break: loose;\n\
+snippet wob:n\n\
+ word-break: normal;\n\
+snippet wos\n\
+ word-spacing: ${1};\n\
+snippet wow\n\
+ word-wrap: ${1};\n\
+snippet wow:no\n\
+ word-wrap: none;\n\
+snippet wow:n\n\
+ word-wrap: normal;\n\
+snippet wow:s\n\
+ word-wrap: suppress;\n\
+snippet wow:u\n\
+ word-wrap: unrestricted;\n\
+snippet z\n\
+ z-index: ${1};\n\
+snippet z:a\n\
+ z-index: auto;\n\
+snippet zoo\n\
+ zoom: 1;\n\
+";
+exports.scope = "css";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/curly.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/curly.js
new file mode 100644
index 00000000..1b2b6873
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/curly.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/curly",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "curly";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/d.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/d.js
new file mode 100644
index 00000000..729741cc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/d.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/d",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "d";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/dart.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/dart.js
new file mode 100644
index 00000000..e96cc5d2
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/dart.js
@@ -0,0 +1,90 @@
+ace.define("ace/snippets/dart",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet lib\n\
+ library ${1};\n\
+ ${2}\n\
+snippet im\n\
+ import '${1}';\n\
+ ${2}\n\
+snippet pa\n\
+ part '${1}';\n\
+ ${2}\n\
+snippet pao\n\
+ part of ${1};\n\
+ ${2}\n\
+snippet main\n\
+ void main() {\n\
+ ${1:/* code */}\n\
+ }\n\
+snippet st\n\
+ static ${1}\n\
+snippet fi\n\
+ final ${1}\n\
+snippet re\n\
+ return ${1}\n\
+snippet br\n\
+ break;\n\
+snippet th\n\
+ throw ${1}\n\
+snippet cl\n\
+ class ${1:`Filename(\"\", \"untitled\")`} ${2}\n\
+snippet imp\n\
+ implements ${1}\n\
+snippet ext\n\
+ extends ${1}\n\
+snippet if\n\
+ if (${1:true}) {\n\
+ ${2}\n\
+ }\n\
+snippet ife\n\
+ if (${1:true}) {\n\
+ ${2}\n\
+ } else {\n\
+ ${3}\n\
+ }\n\
+snippet el\n\
+ else\n\
+snippet sw\n\
+ switch (${1}) {\n\
+ ${2}\n\
+ }\n\
+snippet cs\n\
+ case ${1}:\n\
+ ${2}\n\
+snippet de\n\
+ default:\n\
+ ${1}\n\
+snippet for\n\
+ for (var ${2:i} = 0, len = ${1:things}.length; $2 < len; ${3:++}$2) {\n\
+ ${4:$1[$2]}\n\
+ }\n\
+snippet fore\n\
+ for (final ${2:item} in ${1:itemList}) {\n\
+ ${3:/* code */}\n\
+ }\n\
+snippet wh\n\
+ while (${1:/* condition */}) {\n\
+ ${2:/* code */}\n\
+ }\n\
+snippet dowh\n\
+ do {\n\
+ ${2:/* code */}\n\
+ } while (${1:/* condition */});\n\
+snippet as\n\
+ assert(${1:/* condition */});\n\
+snippet try\n\
+ try {\n\
+ ${2}\n\
+ } catch (${1:Exception e}) {\n\
+ }\n\
+snippet tryf\n\
+ try {\n\
+ ${2}\n\
+ } catch (${1:Exception e}) {\n\
+ } finally {\n\
+ }\n\
+";
+exports.scope = "dart";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/diff.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/diff.js
new file mode 100644
index 00000000..8fe075ec
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/diff.js
@@ -0,0 +1,18 @@
+ace.define("ace/snippets/diff",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# DEP-3 (http://dep.debian.net/deps/dep3/) style patch header\n\
+snippet header DEP-3 style header\n\
+ Description: ${1}\n\
+ Origin: ${2:vendor|upstream|other}, ${3:url of the original patch}\n\
+ Bug: ${4:url in upstream bugtracker}\n\
+ Forwarded: ${5:no|not-needed|url}\n\
+ Author: ${6:`g:snips_author`}\n\
+ Reviewed-by: ${7:name and email}\n\
+ Last-Update: ${8:`strftime(\"%Y-%m-%d\")`}\n\
+ Applied-Upstream: ${9:upstream version|url|commit}\n\
+\n\
+";
+exports.scope = "diff";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/django.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/django.js
new file mode 100644
index 00000000..c1dacbed
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/django.js
@@ -0,0 +1,115 @@
+ace.define("ace/snippets/django",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Model Fields\n\
+\n\
+# Note: Optional arguments are using defaults that match what Django will use\n\
+# as a default, e.g. with max_length fields. Doing this as a form of self\n\
+# documentation and to make it easy to know whether you should override the\n\
+# default or not.\n\
+\n\
+# Note: Optional arguments that are booleans will use the opposite since you\n\
+# can either not specify them, or override them, e.g. auto_now_add=False.\n\
+\n\
+snippet auto\n\
+ ${1:FIELDNAME} = models.AutoField(${2})\n\
+snippet bool\n\
+ ${1:FIELDNAME} = models.BooleanField(${2:default=True})\n\
+snippet char\n\
+ ${1:FIELDNAME} = models.CharField(max_length=${2}${3:, blank=True})\n\
+snippet comma\n\
+ ${1:FIELDNAME} = models.CommaSeparatedIntegerField(max_length=${2}${3:, blank=True})\n\
+snippet date\n\
+ ${1:FIELDNAME} = models.DateField(${2:auto_now_add=True, auto_now=True}${3:, blank=True, null=True})\n\
+snippet datetime\n\
+ ${1:FIELDNAME} = models.DateTimeField(${2:auto_now_add=True, auto_now=True}${3:, blank=True, null=True})\n\
+snippet decimal\n\
+ ${1:FIELDNAME} = models.DecimalField(max_digits=${2}, decimal_places=${3})\n\
+snippet email\n\
+ ${1:FIELDNAME} = models.EmailField(max_length=${2:75}${3:, blank=True})\n\
+snippet file\n\
+ ${1:FIELDNAME} = models.FileField(upload_to=${2:path/for/upload}${3:, max_length=100})\n\
+snippet filepath\n\
+ ${1:FIELDNAME} = models.FilePathField(path=${2:\"/abs/path/to/dir\"}${3:, max_length=100}${4:, match=\"*.ext\"}${5:, recursive=True}${6:, blank=True, })\n\
+snippet float\n\
+ ${1:FIELDNAME} = models.FloatField(${2})\n\
+snippet image\n\
+ ${1:FIELDNAME} = models.ImageField(upload_to=${2:path/for/upload}${3:, height_field=height, width_field=width}${4:, max_length=100})\n\
+snippet int\n\
+ ${1:FIELDNAME} = models.IntegerField(${2})\n\
+snippet ip\n\
+ ${1:FIELDNAME} = models.IPAddressField(${2})\n\
+snippet nullbool\n\
+ ${1:FIELDNAME} = models.NullBooleanField(${2})\n\
+snippet posint\n\
+ ${1:FIELDNAME} = models.PositiveIntegerField(${2})\n\
+snippet possmallint\n\
+ ${1:FIELDNAME} = models.PositiveSmallIntegerField(${2})\n\
+snippet slug\n\
+ ${1:FIELDNAME} = models.SlugField(max_length=${2:50}${3:, blank=True})\n\
+snippet smallint\n\
+ ${1:FIELDNAME} = models.SmallIntegerField(${2})\n\
+snippet text\n\
+ ${1:FIELDNAME} = models.TextField(${2:blank=True})\n\
+snippet time\n\
+ ${1:FIELDNAME} = models.TimeField(${2:auto_now_add=True, auto_now=True}${3:, blank=True, null=True})\n\
+snippet url\n\
+ ${1:FIELDNAME} = models.URLField(${2:verify_exists=False}${3:, max_length=200}${4:, blank=True})\n\
+snippet xml\n\
+ ${1:FIELDNAME} = models.XMLField(schema_path=${2:None}${3:, blank=True})\n\
+# Relational Fields\n\
+snippet fk\n\
+ ${1:FIELDNAME} = models.ForeignKey(${2:OtherModel}${3:, related_name=''}${4:, limit_choices_to=}${5:, to_field=''})\n\
+snippet m2m\n\
+ ${1:FIELDNAME} = models.ManyToManyField(${2:OtherModel}${3:, related_name=''}${4:, limit_choices_to=}${5:, symmetrical=False}${6:, through=''}${7:, db_table=''})\n\
+snippet o2o\n\
+ ${1:FIELDNAME} = models.OneToOneField(${2:OtherModel}${3:, parent_link=True}${4:, related_name=''}${5:, limit_choices_to=}${6:, to_field=''})\n\
+\n\
+# Code Skeletons\n\
+\n\
+snippet form\n\
+ class ${1:FormName}(forms.Form):\n\
+ \"\"\"${2:docstring}\"\"\"\n\
+ ${3}\n\
+\n\
+snippet model\n\
+ class ${1:ModelName}(models.Model):\n\
+ \"\"\"${2:docstring}\"\"\"\n\
+ ${3}\n\
+ \n\
+ class Meta:\n\
+ ${4}\n\
+ \n\
+ def __unicode__(self):\n\
+ ${5}\n\
+ \n\
+ def save(self, force_insert=False, force_update=False):\n\
+ ${6}\n\
+ \n\
+ @models.permalink\n\
+ def get_absolute_url(self):\n\
+ return ('${7:view_or_url_name}' ${8})\n\
+\n\
+snippet modeladmin\n\
+ class ${1:ModelName}Admin(admin.ModelAdmin):\n\
+ ${2}\n\
+ \n\
+ admin.site.register($1, $1Admin)\n\
+ \n\
+snippet tabularinline\n\
+ class ${1:ModelName}Inline(admin.TabularInline):\n\
+ model = $1\n\
+\n\
+snippet stackedinline\n\
+ class ${1:ModelName}Inline(admin.StackedInline):\n\
+ model = $1\n\
+\n\
+snippet r2r\n\
+ return render_to_response('${1:template.html}', {\n\
+ ${2}\n\
+ }${3:, context_instance=RequestContext(request)}\n\
+ )\n\
+";
+exports.scope = "django";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/dockerfile.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/dockerfile.js
new file mode 100644
index 00000000..981cee8a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/dockerfile.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/dockerfile",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "dockerfile";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/dot.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/dot.js
new file mode 100644
index 00000000..3a09fc77
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/dot.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/dot",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "dot";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/drools.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/drools.js
new file mode 100644
index 00000000..a8dd859a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/drools.js
@@ -0,0 +1,26 @@
+ace.define("ace/snippets/drools",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "\n\
+snippet rule\n\
+ rule \"${1?:rule_name}\"\n\
+ when\n\
+ ${2:// when...} \n\
+ then\n\
+ ${3:// then...}\n\
+ end\n\
+\n\
+snippet query\n\
+ query ${1?:query_name}\n\
+ ${2:// find} \n\
+ end\n\
+ \n\
+snippet declare\n\
+ declare ${1?:type_name}\n\
+ ${2:// attributes} \n\
+ end\n\
+\n\
+";
+exports.scope = "drools";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/eiffel.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/eiffel.js
new file mode 100644
index 00000000..25672785
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/eiffel.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/eiffel",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "eiffel";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/ejs.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ejs.js
new file mode 100644
index 00000000..fd38fa09
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ejs.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/ejs",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "ejs";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/elixir.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/elixir.js
new file mode 100644
index 00000000..d9326275
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/elixir.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/elixir",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/elm.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/elm.js
new file mode 100644
index 00000000..a9d06b59
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/elm.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/elm",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "elm";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/erlang.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/erlang.js
new file mode 100644
index 00000000..d04ee117
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/erlang.js
@@ -0,0 +1,167 @@
+ace.define("ace/snippets/erlang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# module and export all\n\
+snippet mod\n\
+ -module(${1:`Filename('', 'my')`}).\n\
+ \n\
+ -compile([export_all]).\n\
+ \n\
+ start() ->\n\
+ ${2}\n\
+ \n\
+ stop() ->\n\
+ ok.\n\
+# define directive\n\
+snippet def\n\
+ -define(${1:macro}, ${2:body}).${3}\n\
+# export directive\n\
+snippet exp\n\
+ -export([${1:function}/${2:arity}]).\n\
+# include directive\n\
+snippet inc\n\
+ -include(\"${1:file}\").${2}\n\
+# behavior directive\n\
+snippet beh\n\
+ -behaviour(${1:behaviour}).${2}\n\
+# if expression\n\
+snippet if\n\
+ if\n\
+ ${1:guard} ->\n\
+ ${2:body}\n\
+ end\n\
+# case expression\n\
+snippet case\n\
+ case ${1:expression} of\n\
+ ${2:pattern} ->\n\
+ ${3:body};\n\
+ end\n\
+# anonymous function\n\
+snippet fun\n\
+ fun (${1:Parameters}) -> ${2:body} end${3}\n\
+# try...catch\n\
+snippet try\n\
+ try\n\
+ ${1}\n\
+ catch\n\
+ ${2:_:_} -> ${3:got_some_exception}\n\
+ end\n\
+# record directive\n\
+snippet rec\n\
+ -record(${1:record}, {\n\
+ ${2:field}=${3:value}}).${4}\n\
+# todo comment\n\
+snippet todo\n\
+ %% TODO: ${1}\n\
+## Snippets below (starting with '%') are in EDoc format.\n\
+## See http://www.erlang.org/doc/apps/edoc/chapter.html#id56887 for more details\n\
+# doc comment\n\
+snippet %d\n\
+ %% @doc ${1}\n\
+# end of doc comment\n\
+snippet %e\n\
+ %% @end\n\
+# specification comment\n\
+snippet %s\n\
+ %% @spec ${1}\n\
+# private function marker\n\
+snippet %p\n\
+ %% @private\n\
+# OTP application\n\
+snippet application\n\
+ -module(${1:`Filename('', 'my')`}).\n\
+\n\
+ -behaviour(application).\n\
+\n\
+ -export([start/2, stop/1]).\n\
+\n\
+ start(_Type, _StartArgs) ->\n\
+ case ${2:root_supervisor}:start_link() of\n\
+ {ok, Pid} ->\n\
+ {ok, Pid};\n\
+ Other ->\n\
+ {error, Other}\n\
+ end.\n\
+\n\
+ stop(_State) ->\n\
+ ok. \n\
+# OTP supervisor\n\
+snippet supervisor\n\
+ -module(${1:`Filename('', 'my')`}).\n\
+\n\
+ -behaviour(supervisor).\n\
+\n\
+ %% API\n\
+ -export([start_link/0]).\n\
+\n\
+ %% Supervisor callbacks\n\
+ -export([init/1]).\n\
+\n\
+ -define(SERVER, ?MODULE).\n\
+\n\
+ start_link() ->\n\
+ supervisor:start_link({local, ?SERVER}, ?MODULE, []).\n\
+\n\
+ init([]) ->\n\
+ Server = {${2:my_server}, {$2, start_link, []},\n\
+ permanent, 2000, worker, [$2]},\n\
+ Children = [Server],\n\
+ RestartStrategy = {one_for_one, 0, 1},\n\
+ {ok, {RestartStrategy, Children}}.\n\
+# OTP gen_server\n\
+snippet gen_server\n\
+ -module(${1:`Filename('', 'my')`}).\n\
+\n\
+ -behaviour(gen_server).\n\
+\n\
+ %% API\n\
+ -export([\n\
+ start_link/0\n\
+ ]).\n\
+\n\
+ %% gen_server callbacks\n\
+ -export([init/1, handle_call/3, handle_cast/2, handle_info/2,\n\
+ terminate/2, code_change/3]).\n\
+\n\
+ -define(SERVER, ?MODULE).\n\
+\n\
+ -record(state, {}).\n\
+\n\
+ %%%===================================================================\n\
+ %%% API\n\
+ %%%===================================================================\n\
+\n\
+ start_link() ->\n\
+ gen_server:start_link({local, ?SERVER}, ?MODULE, [], []).\n\
+\n\
+ %%%===================================================================\n\
+ %%% gen_server callbacks\n\
+ %%%===================================================================\n\
+\n\
+ init([]) ->\n\
+ {ok, #state{}}.\n\
+\n\
+ handle_call(_Request, _From, State) ->\n\
+ Reply = ok,\n\
+ {reply, Reply, State}.\n\
+\n\
+ handle_cast(_Msg, State) ->\n\
+ {noreply, State}.\n\
+\n\
+ handle_info(_Info, State) ->\n\
+ {noreply, State}.\n\
+\n\
+ terminate(_Reason, _State) ->\n\
+ ok.\n\
+\n\
+ code_change(_OldVsn, State, _Extra) ->\n\
+ {ok, State}.\n\
+\n\
+ %%%===================================================================\n\
+ %%% Internal functions\n\
+ %%%===================================================================\n\
+\n\
+";
+exports.scope = "erlang";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/forth.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/forth.js
new file mode 100644
index 00000000..afb1f8a4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/forth.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/forth",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "forth";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/fortran.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/fortran.js
new file mode 100644
index 00000000..b4605929
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/fortran.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/fortran",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "fortran";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/ftl.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ftl.js
new file mode 100644
index 00000000..3b53ad41
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ftl.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/ftl",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "ftl";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/gcode.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gcode.js
new file mode 100644
index 00000000..0ed4a102
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gcode.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/gcode",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "gcode";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/gherkin.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gherkin.js
new file mode 100644
index 00000000..20446471
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gherkin.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/gherkin",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "gherkin";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/gitignore.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gitignore.js
new file mode 100644
index 00000000..6da54aa5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gitignore.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/gitignore",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "gitignore";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/glsl.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/glsl.js
new file mode 100644
index 00000000..bb8e40d8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/glsl.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/glsl",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "glsl";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/gobstones.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gobstones.js
new file mode 100644
index 00000000..4e36e531
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/gobstones.js
@@ -0,0 +1,41 @@
+ace.define("ace/snippets/gobstones",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Procedure\n\
+snippet proc\n\
+ procedure ${1?:name}(${2:argument}) {\n\
+ ${3:// body...}\n\
+ }\n\
+\n\
+# Function\n\
+snippet fun\n\
+ function ${1?:name}(${2:argument}) {\n\
+ return ${3:// body...}\n\
+ }\n\
+\n\
+# Repeat\n\
+snippet rep\n\
+ repeat ${1?:times} {\n\
+ ${2:// body...}\n\
+ }\n\
+\n\
+# For\n\
+snippet for\n\
+ foreach ${1?:e} in ${2?:list} {\n\
+ ${3:// body...} \n\
+ }\n\
+\n\
+# If\n\
+snippet if\n\
+ if (${1?:condition}) {\n\
+ ${3:// body...} \n\
+ }\n\
+\n\
+# While\n\
+ while (${1?:condition}) {\n\
+ ${2:// body...} \n\
+ }\n\
+";
+exports.scope = "gobstones";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/golang.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/golang.js
new file mode 100644
index 00000000..0a2411d5
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/golang.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/golang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "golang";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/graphqlschema.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/graphqlschema.js
new file mode 100644
index 00000000..6b1e49f9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/graphqlschema.js
@@ -0,0 +1,39 @@
+ace.define("ace/snippets/graphqlschema",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Type Snippet\n\
+trigger type\n\
+snippet type\n\
+ type ${1:type_name} {\n\
+ ${2:type_siblings}\n\
+ }\n\
+\n\
+# Input Snippet\n\
+trigger input\n\
+snippet input\n\
+ input ${1:input_name} {\n\
+ ${2:input_siblings}\n\
+ }\n\
+\n\
+# Interface Snippet\n\
+trigger interface\n\
+snippet interface\n\
+ interface ${1:interface_name} {\n\
+ ${2:interface_siblings}\n\
+ }\n\
+\n\
+# Interface Snippet\n\
+trigger union\n\
+snippet union\n\
+ union ${1:union_name} = ${2:type} | ${3: type}\n\
+\n\
+# Enum Snippet\n\
+trigger enum\n\
+snippet enum\n\
+ enum ${1:enum_name} {\n\
+ ${2:enum_siblings}\n\
+ }\n\
+";
+exports.scope = "graphqlschema";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/groovy.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/groovy.js
new file mode 100644
index 00000000..ddeab2c8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/groovy.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/groovy",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "groovy";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/haml.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haml.js
new file mode 100644
index 00000000..2d1c68aa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haml.js
@@ -0,0 +1,27 @@
+ace.define("ace/snippets/haml",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet t\n\
+ %table\n\
+ %tr\n\
+ %th\n\
+ ${1:headers}\n\
+ %tr\n\
+ %td\n\
+ ${2:headers}\n\
+snippet ul\n\
+ %ul\n\
+ %li\n\
+ ${1:item}\n\
+ %li\n\
+snippet =rp\n\
+ = render :partial => '${1:partial}'\n\
+snippet =rpl\n\
+ = render :partial => '${1:partial}', :locals => {}\n\
+snippet =rpc\n\
+ = render :partial => '${1:partial}', :collection => @$1\n\
+\n\
+";
+exports.scope = "haml";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/handlebars.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/handlebars.js
new file mode 100644
index 00000000..1764b754
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/handlebars.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/handlebars",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "handlebars";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell.js
new file mode 100644
index 00000000..2bd8b5af
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell.js
@@ -0,0 +1,89 @@
+ace.define("ace/snippets/haskell",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet lang\n\
+ {-# LANGUAGE ${1:OverloadedStrings} #-}\n\
+snippet info\n\
+ -- |\n\
+ -- Module : ${1:Module.Namespace}\n\
+ -- Copyright : ${2:Author} ${3:2011-2012}\n\
+ -- License : ${4:BSD3}\n\
+ --\n\
+ -- Maintainer : ${5:email@something.com}\n\
+ -- Stability : ${6:experimental}\n\
+ -- Portability : ${7:unknown}\n\
+ --\n\
+ -- ${8:Description}\n\
+ --\n\
+snippet import\n\
+ import ${1:Data.Text}\n\
+snippet import2\n\
+ import ${1:Data.Text} (${2:head})\n\
+snippet importq\n\
+ import qualified ${1:Data.Text} as ${2:T}\n\
+snippet inst\n\
+ instance ${1:Monoid} ${2:Type} where\n\
+ ${3}\n\
+snippet type\n\
+ type ${1:Type} = ${2:Type}\n\
+snippet data\n\
+ data ${1:Type} = ${2:$1} ${3:Int}\n\
+snippet newtype\n\
+ newtype ${1:Type} = ${2:$1} ${3:Int}\n\
+snippet class\n\
+ class ${1:Class} a where\n\
+ ${2}\n\
+snippet module\n\
+ module `substitute(substitute(expand('%:r'), '[/\\\\]','.','g'),'^\\%(\\l*\\.\\)\\?','','')` (\n\
+ ) where\n\
+ `expand('%') =~ 'Main' ? \"\\n\\nmain = do\\n print \\\"hello world\\\"\" : \"\"`\n\
+\n\
+snippet const\n\
+ ${1:name} :: ${2:a}\n\
+ $1 = ${3:undefined}\n\
+snippet fn\n\
+ ${1:fn} :: ${2:a} -> ${3:a}\n\
+ $1 ${4} = ${5:undefined}\n\
+snippet fn2\n\
+ ${1:fn} :: ${2:a} -> ${3:a} -> ${4:a}\n\
+ $1 ${5} = ${6:undefined}\n\
+snippet ap\n\
+ ${1:map} ${2:fn} ${3:list}\n\
+snippet do\n\
+ do\n\
+ \n\
+snippet λ\n\
+ \\${1:x} -> ${2}\n\
+snippet \\\n\
+ \\${1:x} -> ${2}\n\
+snippet <-\n\
+ ${1:a} <- ${2:m a}\n\
+snippet ←\n\
+ ${1:a} <- ${2:m a}\n\
+snippet ->\n\
+ ${1:m a} -> ${2:a}\n\
+snippet →\n\
+ ${1:m a} -> ${2:a}\n\
+snippet tup\n\
+ (${1:a}, ${2:b})\n\
+snippet tup2\n\
+ (${1:a}, ${2:b}, ${3:c})\n\
+snippet tup3\n\
+ (${1:a}, ${2:b}, ${3:c}, ${4:d})\n\
+snippet rec\n\
+ ${1:Record} { ${2:recFieldA} = ${3:undefined}\n\
+ , ${4:recFieldB} = ${5:undefined}\n\
+ }\n\
+snippet case\n\
+ case ${1:something} of\n\
+ ${2} -> ${3}\n\
+snippet let\n\
+ let ${1} = ${2}\n\
+ in ${3}\n\
+snippet where\n\
+ where\n\
+ ${1:fn} = ${2:undefined}\n\
+";
+exports.scope = "haskell";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell_cabal.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell_cabal.js
new file mode 100644
index 00000000..56d6e875
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haskell_cabal.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/haskell_cabal",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "haskell_cabal";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/haxe.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haxe.js
new file mode 100644
index 00000000..37695471
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/haxe.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/haxe",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "haxe";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/hjson.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/hjson.js
new file mode 100644
index 00000000..b31e5563
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/hjson.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/hjson",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/html.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/html.js
new file mode 100644
index 00000000..b94132fa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/html.js
@@ -0,0 +1,862 @@
+ace.define("ace/snippets/html",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Some useful Unicode entities\n\
+# Non-Breaking Space\n\
+snippet nbs\n\
+ &nbsp;\n\
+# ←\n\
+snippet left\n\
+ &#x2190;\n\
+# →\n\
+snippet right\n\
+ &#x2192;\n\
+# ↑\n\
+snippet up\n\
+ &#x2191;\n\
+# ↓\n\
+snippet down\n\
+ &#x2193;\n\
+# ↩\n\
+snippet return\n\
+ &#x21A9;\n\
+# ⇤\n\
+snippet backtab\n\
+ &#x21E4;\n\
+# ⇥\n\
+snippet tab\n\
+ &#x21E5;\n\
+# ⇧\n\
+snippet shift\n\
+ &#x21E7;\n\
+# ⌃\n\
+snippet ctrl\n\
+ &#x2303;\n\
+# ⌅\n\
+snippet enter\n\
+ &#x2305;\n\
+# ⌘\n\
+snippet cmd\n\
+ &#x2318;\n\
+# ⌥\n\
+snippet option\n\
+ &#x2325;\n\
+# ⌦\n\
+snippet delete\n\
+ &#x2326;\n\
+# ⌫\n\
+snippet backspace\n\
+ &#x232B;\n\
+# ⎋\n\
+snippet esc\n\
+ &#x238B;\n\
+# Generic Doctype\n\
+snippet doctype HTML 4.01 Strict\n\
+ <!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\"\n\
+ \"http://www.w3.org/TR/html4/strict.dtd\">\n\
+snippet doctype HTML 4.01 Transitional\n\
+ <!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\n\
+ \"http://www.w3.org/TR/html4/loose.dtd\">\n\
+snippet doctype HTML 5\n\
+ <!DOCTYPE HTML>\n\
+snippet doctype XHTML 1.0 Frameset\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"\n\
+ \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">\n\
+snippet doctype XHTML 1.0 Strict\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"\n\
+ \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">\n\
+snippet doctype XHTML 1.0 Transitional\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\"\n\
+ \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n\
+snippet doctype XHTML 1.1\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.1//EN\"\n\
+ \"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd\">\n\
+# HTML Doctype 4.01 Strict\n\
+snippet docts\n\
+ <!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\"\n\
+ \"http://www.w3.org/TR/html4/strict.dtd\">\n\
+# HTML Doctype 4.01 Transitional\n\
+snippet doct\n\
+ <!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\n\
+ \"http://www.w3.org/TR/html4/loose.dtd\">\n\
+# HTML Doctype 5\n\
+snippet doct5\n\
+ <!DOCTYPE html>\n\
+# XHTML Doctype 1.0 Frameset\n\
+snippet docxf\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Frameset//EN\"\n\
+ \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd\">\n\
+# XHTML Doctype 1.0 Strict\n\
+snippet docxs\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"\n\
+ \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">\n\
+# XHTML Doctype 1.0 Transitional\n\
+snippet docxt\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\"\n\
+ \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n\
+# XHTML Doctype 1.1\n\
+snippet docx\n\
+ <!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.1//EN\"\n\
+ \"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd\">\n\
+# html5shiv\n\
+snippet html5shiv\n\
+ <!--[if lte IE 8]>\n\
+ <script src=\"https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv.min.js\"></script>\n\
+ <![endif]-->\n\
+snippet html5printshiv\n\
+ <!--[if lte IE 8]>\n\
+ <script src=\"https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js\"></script>\n\
+ <![endif]-->\n\
+# Attributes\n\
+snippet attr\n\
+ ${1:attribute}=\"${2:property}\"\n\
+snippet attr+\n\
+ ${1:attribute}=\"${2:property}\" attr+${3}\n\
+snippet .\n\
+ class=\"${1}\"${2}\n\
+snippet #\n\
+ id=\"${1}\"${2}\n\
+snippet alt\n\
+ alt=\"${1}\"${2}\n\
+snippet charset\n\
+ charset=\"${1:utf-8}\"${2}\n\
+snippet data\n\
+ data-${1}=\"${2:$1}\"${3}\n\
+snippet for\n\
+ for=\"${1}\"${2}\n\
+snippet height\n\
+ height=\"${1}\"${2}\n\
+snippet href\n\
+ href=\"${1:#}\"${2}\n\
+snippet lang\n\
+ lang=\"${1:en}\"${2}\n\
+snippet media\n\
+ media=\"${1}\"${2}\n\
+snippet name\n\
+ name=\"${1}\"${2}\n\
+snippet rel\n\
+ rel=\"${1}\"${2}\n\
+snippet scope\n\
+ scope=\"${1:row}\"${2}\n\
+snippet src\n\
+ src=\"${1}\"${2}\n\
+snippet title=\n\
+ title=\"${1}\"${2}\n\
+snippet type\n\
+ type=\"${1}\"${2}\n\
+snippet value\n\
+ value=\"${1}\"${2}\n\
+snippet width\n\
+ width=\"${1}\"${2}\n\
+# Elements\n\
+snippet a\n\
+ <a href=\"${1:#}\">${2:$1}</a>\n\
+snippet a.\n\
+ <a class=\"${1}\" href=\"${2:#}\">${3:$1}</a>\n\
+snippet a#\n\
+ <a id=\"${1}\" href=\"${2:#}\">${3:$1}</a>\n\
+snippet a:ext\n\
+ <a href=\"http://${1:example.com}\">${2:$1}</a>\n\
+snippet a:mail\n\
+ <a href=\"mailto:${1:joe@example.com}?subject=${2:feedback}\">${3:email me}</a>\n\
+snippet abbr\n\
+ <abbr title=\"${1}\">${2}</abbr>\n\
+snippet address\n\
+ <address>\n\
+ ${1}\n\
+ </address>\n\
+snippet area\n\
+ <area shape=\"${1:rect}\" coords=\"${2}\" href=\"${3}\" alt=\"${4}\" />\n\
+snippet area+\n\
+ <area shape=\"${1:rect}\" coords=\"${2}\" href=\"${3}\" alt=\"${4}\" />\n\
+ area+${5}\n\
+snippet area:c\n\
+ <area shape=\"circle\" coords=\"${1}\" href=\"${2}\" alt=\"${3}\" />\n\
+snippet area:d\n\
+ <area shape=\"default\" coords=\"${1}\" href=\"${2}\" alt=\"${3}\" />\n\
+snippet area:p\n\
+ <area shape=\"poly\" coords=\"${1}\" href=\"${2}\" alt=\"${3}\" />\n\
+snippet area:r\n\
+ <area shape=\"rect\" coords=\"${1}\" href=\"${2}\" alt=\"${3}\" />\n\
+snippet article\n\
+ <article>\n\
+ ${1}\n\
+ </article>\n\
+snippet article.\n\
+ <article class=\"${1}\">\n\
+ ${2}\n\
+ </article>\n\
+snippet article#\n\
+ <article id=\"${1}\">\n\
+ ${2}\n\
+ </article>\n\
+snippet aside\n\
+ <aside>\n\
+ ${1}\n\
+ </aside>\n\
+snippet aside.\n\
+ <aside class=\"${1}\">\n\
+ ${2}\n\
+ </aside>\n\
+snippet aside#\n\
+ <aside id=\"${1}\">\n\
+ ${2}\n\
+ </aside>\n\
+snippet audio\n\
+ <audio src=\"${1}>${2}</audio>\n\
+snippet b\n\
+ <b>${1}</b>\n\
+snippet base\n\
+ <base href=\"${1}\" target=\"${2}\" />\n\
+snippet bdi\n\
+ <bdi>${1}</bdo>\n\
+snippet bdo\n\
+ <bdo dir=\"${1}\">${2}</bdo>\n\
+snippet bdo:l\n\
+ <bdo dir=\"ltr\">${1}</bdo>\n\
+snippet bdo:r\n\
+ <bdo dir=\"rtl\">${1}</bdo>\n\
+snippet blockquote\n\
+ <blockquote>\n\
+ ${1}\n\
+ </blockquote>\n\
+snippet body\n\
+ <body>\n\
+ ${1}\n\
+ </body>\n\
+snippet br\n\
+ <br />${1}\n\
+snippet button\n\
+ <button type=\"${1:submit}\">${2}</button>\n\
+snippet button.\n\
+ <button class=\"${1:button}\" type=\"${2:submit}\">${3}</button>\n\
+snippet button#\n\
+ <button id=\"${1}\" type=\"${2:submit}\">${3}</button>\n\
+snippet button:s\n\
+ <button type=\"submit\">${1}</button>\n\
+snippet button:r\n\
+ <button type=\"reset\">${1}</button>\n\
+snippet canvas\n\
+ <canvas>\n\
+ ${1}\n\
+ </canvas>\n\
+snippet caption\n\
+ <caption>${1}</caption>\n\
+snippet cite\n\
+ <cite>${1}</cite>\n\
+snippet code\n\
+ <code>${1}</code>\n\
+snippet col\n\
+ <col />${1}\n\
+snippet col+\n\
+ <col />\n\
+ col+${1}\n\
+snippet colgroup\n\
+ <colgroup>\n\
+ ${1}\n\
+ </colgroup>\n\
+snippet colgroup+\n\
+ <colgroup>\n\
+ <col />\n\
+ col+${1}\n\
+ </colgroup>\n\
+snippet command\n\
+ <command type=\"command\" label=\"${1}\" icon=\"${2}\" />\n\
+snippet command:c\n\
+ <command type=\"checkbox\" label=\"${1}\" icon=\"${2}\" />\n\
+snippet command:r\n\
+ <command type=\"radio\" radiogroup=\"${1}\" label=\"${2}\" icon=\"${3}\" />\n\
+snippet datagrid\n\
+ <datagrid>\n\
+ ${1}\n\
+ </datagrid>\n\
+snippet datalist\n\
+ <datalist>\n\
+ ${1}\n\
+ </datalist>\n\
+snippet datatemplate\n\
+ <datatemplate>\n\
+ ${1}\n\
+ </datatemplate>\n\
+snippet dd\n\
+ <dd>${1}</dd>\n\
+snippet dd.\n\
+ <dd class=\"${1}\">${2}</dd>\n\
+snippet dd#\n\
+ <dd id=\"${1}\">${2}</dd>\n\
+snippet del\n\
+ <del>${1}</del>\n\
+snippet details\n\
+ <details>${1}</details>\n\
+snippet dfn\n\
+ <dfn>${1}</dfn>\n\
+snippet dialog\n\
+ <dialog>\n\
+ ${1}\n\
+ </dialog>\n\
+snippet div\n\
+ <div>\n\
+ ${1}\n\
+ </div>\n\
+snippet div.\n\
+ <div class=\"${1}\">\n\
+ ${2}\n\
+ </div>\n\
+snippet div#\n\
+ <div id=\"${1}\">\n\
+ ${2}\n\
+ </div>\n\
+snippet dl\n\
+ <dl>\n\
+ ${1}\n\
+ </dl>\n\
+snippet dl.\n\
+ <dl class=\"${1}\">\n\
+ ${2}\n\
+ </dl>\n\
+snippet dl#\n\
+ <dl id=\"${1}\">\n\
+ ${2}\n\
+ </dl>\n\
+snippet dl+\n\
+ <dl>\n\
+ <dt>${1}</dt>\n\
+ <dd>${2}</dd>\n\
+ dt+${3}\n\
+ </dl>\n\
+snippet dt\n\
+ <dt>${1}</dt>\n\
+snippet dt.\n\
+ <dt class=\"${1}\">${2}</dt>\n\
+snippet dt#\n\
+ <dt id=\"${1}\">${2}</dt>\n\
+snippet dt+\n\
+ <dt>${1}</dt>\n\
+ <dd>${2}</dd>\n\
+ dt+${3}\n\
+snippet em\n\
+ <em>${1}</em>\n\
+snippet embed\n\
+ <embed src=${1} type=\"${2} />\n\
+snippet fieldset\n\
+ <fieldset>\n\
+ ${1}\n\
+ </fieldset>\n\
+snippet fieldset.\n\
+ <fieldset class=\"${1}\">\n\
+ ${2}\n\
+ </fieldset>\n\
+snippet fieldset#\n\
+ <fieldset id=\"${1}\">\n\
+ ${2}\n\
+ </fieldset>\n\
+snippet fieldset+\n\
+ <fieldset>\n\
+ <legend><span>${1}</span></legend>\n\
+ ${2}\n\
+ </fieldset>\n\
+ fieldset+${3}\n\
+snippet figcaption\n\
+ <figcaption>${1}</figcaption>\n\
+snippet figure\n\
+ <figure>${1}</figure>\n\
+snippet footer\n\
+ <footer>\n\
+ ${1}\n\
+ </footer>\n\
+snippet footer.\n\
+ <footer class=\"${1}\">\n\
+ ${2}\n\
+ </footer>\n\
+snippet footer#\n\
+ <footer id=\"${1}\">\n\
+ ${2}\n\
+ </footer>\n\
+snippet form\n\
+ <form action=\"${1}\" method=\"${2:get}\" accept-charset=\"utf-8\">\n\
+ ${3}\n\
+ </form>\n\
+snippet form.\n\
+ <form class=\"${1}\" action=\"${2}\" method=\"${3:get}\" accept-charset=\"utf-8\">\n\
+ ${4}\n\
+ </form>\n\
+snippet form#\n\
+ <form id=\"${1}\" action=\"${2}\" method=\"${3:get}\" accept-charset=\"utf-8\">\n\
+ ${4}\n\
+ </form>\n\
+snippet h1\n\
+ <h1>${1}</h1>\n\
+snippet h1.\n\
+ <h1 class=\"${1}\">${2}</h1>\n\
+snippet h1#\n\
+ <h1 id=\"${1}\">${2}</h1>\n\
+snippet h2\n\
+ <h2>${1}</h2>\n\
+snippet h2.\n\
+ <h2 class=\"${1}\">${2}</h2>\n\
+snippet h2#\n\
+ <h2 id=\"${1}\">${2}</h2>\n\
+snippet h3\n\
+ <h3>${1}</h3>\n\
+snippet h3.\n\
+ <h3 class=\"${1}\">${2}</h3>\n\
+snippet h3#\n\
+ <h3 id=\"${1}\">${2}</h3>\n\
+snippet h4\n\
+ <h4>${1}</h4>\n\
+snippet h4.\n\
+ <h4 class=\"${1}\">${2}</h4>\n\
+snippet h4#\n\
+ <h4 id=\"${1}\">${2}</h4>\n\
+snippet h5\n\
+ <h5>${1}</h5>\n\
+snippet h5.\n\
+ <h5 class=\"${1}\">${2}</h5>\n\
+snippet h5#\n\
+ <h5 id=\"${1}\">${2}</h5>\n\
+snippet h6\n\
+ <h6>${1}</h6>\n\
+snippet h6.\n\
+ <h6 class=\"${1}\">${2}</h6>\n\
+snippet h6#\n\
+ <h6 id=\"${1}\">${2}</h6>\n\
+snippet head\n\
+ <head>\n\
+ <meta http-equiv=\"content-type\" content=\"text/html; charset=utf-8\" />\n\
+\n\
+ <title>${1:`substitute(Filename('', 'Page Title'), '^.', '\\u&', '')`}</title>\n\
+ ${2}\n\
+ </head>\n\
+snippet header\n\
+ <header>\n\
+ ${1}\n\
+ </header>\n\
+snippet header.\n\
+ <header class=\"${1}\">\n\
+ ${2}\n\
+ </header>\n\
+snippet header#\n\
+ <header id=\"${1}\">\n\
+ ${2}\n\
+ </header>\n\
+snippet hgroup\n\
+ <hgroup>\n\
+ ${1}\n\
+ </hgroup>\n\
+snippet hgroup.\n\
+ <hgroup class=\"${1}>\n\
+ ${2}\n\
+ </hgroup>\n\
+snippet hr\n\
+ <hr />${1}\n\
+snippet html\n\
+ <html>\n\
+ ${1}\n\
+ </html>\n\
+snippet xhtml\n\
+ <html xmlns=\"http://www.w3.org/1999/xhtml\">\n\
+ ${1}\n\
+ </html>\n\
+snippet html5\n\
+ <!DOCTYPE html>\n\
+ <html>\n\
+ <head>\n\
+ <meta http-equiv=\"content-type\" content=\"text/html; charset=utf-8\" />\n\
+ <title>${1:`substitute(Filename('', 'Page Title'), '^.', '\\u&', '')`}</title>\n\
+ ${2:meta}\n\
+ </head>\n\
+ <body>\n\
+ ${3:body}\n\
+ </body>\n\
+ </html>\n\
+snippet xhtml5\n\
+ <!DOCTYPE html>\n\
+ <html xmlns=\"http://www.w3.org/1999/xhtml\">\n\
+ <head>\n\
+ <meta http-equiv=\"content-type\" content=\"application/xhtml+xml; charset=utf-8\" />\n\
+ <title>${1:`substitute(Filename('', 'Page Title'), '^.', '\\u&', '')`}</title>\n\
+ ${2:meta}\n\
+ </head>\n\
+ <body>\n\
+ ${3:body}\n\
+ </body>\n\
+ </html>\n\
+snippet i\n\
+ <i>${1}</i>\n\
+snippet iframe\n\
+ <iframe src=\"${1}\" frameborder=\"0\"></iframe>${2}\n\
+snippet iframe.\n\
+ <iframe class=\"${1}\" src=\"${2}\" frameborder=\"0\"></iframe>${3}\n\
+snippet iframe#\n\
+ <iframe id=\"${1}\" src=\"${2}\" frameborder=\"0\"></iframe>${3}\n\
+snippet img\n\
+ <img src=\"${1}\" alt=\"${2}\" />${3}\n\
+snippet img.\n\
+ <img class=\"${1}\" src=\"${2}\" alt=\"${3}\" />${4}\n\
+snippet img#\n\
+ <img id=\"${1}\" src=\"${2}\" alt=\"${3}\" />${4}\n\
+snippet input\n\
+ <input type=\"${1:text/submit/hidden/button/image}\" name=\"${2}\" id=\"${3:$2}\" value=\"${4}\" />${5}\n\
+snippet input.\n\
+ <input class=\"${1}\" type=\"${2:text/submit/hidden/button/image}\" name=\"${3}\" id=\"${4:$3}\" value=\"${5}\" />${6}\n\
+snippet input:text\n\
+ <input type=\"text\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:submit\n\
+ <input type=\"submit\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:hidden\n\
+ <input type=\"hidden\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:button\n\
+ <input type=\"button\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:image\n\
+ <input type=\"image\" name=\"${1}\" id=\"${2:$1}\" src=\"${3}\" alt=\"${4}\" />${5}\n\
+snippet input:checkbox\n\
+ <input type=\"checkbox\" name=\"${1}\" id=\"${2:$1}\" />${3}\n\
+snippet input:radio\n\
+ <input type=\"radio\" name=\"${1}\" id=\"${2:$1}\" />${3}\n\
+snippet input:color\n\
+ <input type=\"color\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:date\n\
+ <input type=\"date\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:datetime\n\
+ <input type=\"datetime\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:datetime-local\n\
+ <input type=\"datetime-local\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:email\n\
+ <input type=\"email\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:file\n\
+ <input type=\"file\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:month\n\
+ <input type=\"month\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:number\n\
+ <input type=\"number\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:password\n\
+ <input type=\"password\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:range\n\
+ <input type=\"range\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:reset\n\
+ <input type=\"reset\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:search\n\
+ <input type=\"search\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:time\n\
+ <input type=\"time\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:url\n\
+ <input type=\"url\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet input:week\n\
+ <input type=\"week\" name=\"${1}\" id=\"${2:$1}\" value=\"${3}\" />${4}\n\
+snippet ins\n\
+ <ins>${1}</ins>\n\
+snippet kbd\n\
+ <kbd>${1}</kbd>\n\
+snippet keygen\n\
+ <keygen>${1}</keygen>\n\
+snippet label\n\
+ <label for=\"${2:$1}\">${1}</label>\n\
+snippet label:i\n\
+ <label for=\"${2:$1}\">${1}</label>\n\
+ <input type=\"${3:text/submit/hidden/button}\" name=\"${4:$2}\" id=\"${5:$2}\" value=\"${6}\" />${7}\n\
+snippet label:s\n\
+ <label for=\"${2:$1}\">${1}</label>\n\
+ <select name=\"${3:$2}\" id=\"${4:$2}\">\n\
+ <option value=\"${5}\">${6:$5}</option>\n\
+ </select>\n\
+snippet legend\n\
+ <legend>${1}</legend>\n\
+snippet legend+\n\
+ <legend><span>${1}</span></legend>\n\
+snippet li\n\
+ <li>${1}</li>\n\
+snippet li.\n\
+ <li class=\"${1}\">${2}</li>\n\
+snippet li+\n\
+ <li>${1}</li>\n\
+ li+${2}\n\
+snippet lia\n\
+ <li><a href=\"${2:#}\">${1}</a></li>\n\
+snippet lia+\n\
+ <li><a href=\"${2:#}\">${1}</a></li>\n\
+ lia+${3}\n\
+snippet link\n\
+ <link rel=\"${1}\" href=\"${2}\" title=\"${3}\" type=\"${4}\" />${5}\n\
+snippet link:atom\n\
+ <link rel=\"alternate\" href=\"${1:atom.xml}\" title=\"Atom\" type=\"application/atom+xml\" />${2}\n\
+snippet link:css\n\
+ <link rel=\"stylesheet\" href=\"${2:style.css}\" type=\"text/css\" media=\"${3:all}\" />${4}\n\
+snippet link:favicon\n\
+ <link rel=\"shortcut icon\" href=\"${1:favicon.ico}\" type=\"image/x-icon\" />${2}\n\
+snippet link:rss\n\
+ <link rel=\"alternate\" href=\"${1:rss.xml}\" title=\"RSS\" type=\"application/atom+xml\" />${2}\n\
+snippet link:touch\n\
+ <link rel=\"apple-touch-icon\" href=\"${1:favicon.png}\" />${2}\n\
+snippet map\n\
+ <map name=\"${1}\">\n\
+ ${2}\n\
+ </map>\n\
+snippet map.\n\
+ <map class=\"${1}\" name=\"${2}\">\n\
+ ${3}\n\
+ </map>\n\
+snippet map#\n\
+ <map name=\"${1}\" id=\"${2:$1}>\n\
+ ${3}\n\
+ </map>\n\
+snippet map+\n\
+ <map name=\"${1}\">\n\
+ <area shape=\"${2}\" coords=\"${3}\" href=\"${4}\" alt=\"${5}\" />${6}\n\
+ </map>${7}\n\
+snippet mark\n\
+ <mark>${1}</mark>\n\
+snippet menu\n\
+ <menu>\n\
+ ${1}\n\
+ </menu>\n\
+snippet menu:c\n\
+ <menu type=\"context\">\n\
+ ${1}\n\
+ </menu>\n\
+snippet menu:t\n\
+ <menu type=\"toolbar\">\n\
+ ${1}\n\
+ </menu>\n\
+snippet meta\n\
+ <meta http-equiv=\"${1}\" content=\"${2}\" />${3}\n\
+snippet meta:compat\n\
+ <meta http-equiv=\"X-UA-Compatible\" content=\"IE=${1:7,8,edge}\" />${3}\n\
+snippet meta:refresh\n\
+ <meta http-equiv=\"refresh\" content=\"text/html;charset=UTF-8\" />${3}\n\
+snippet meta:utf\n\
+ <meta http-equiv=\"content-type\" content=\"text/html;charset=UTF-8\" />${3}\n\
+snippet meter\n\
+ <meter>${1}</meter>\n\
+snippet nav\n\
+ <nav>\n\
+ ${1}\n\
+ </nav>\n\
+snippet nav.\n\
+ <nav class=\"${1}\">\n\
+ ${2}\n\
+ </nav>\n\
+snippet nav#\n\
+ <nav id=\"${1}\">\n\
+ ${2}\n\
+ </nav>\n\
+snippet noscript\n\
+ <noscript>\n\
+ ${1}\n\
+ </noscript>\n\
+snippet object\n\
+ <object data=\"${1}\" type=\"${2}\">\n\
+ ${3}\n\
+ </object>${4}\n\
+# Embed QT Movie\n\
+snippet movie\n\
+ <object width=\"$2\" height=\"$3\" classid=\"clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B\"\n\
+ codebase=\"http://www.apple.com/qtactivex/qtplugin.cab\">\n\
+ <param name=\"src\" value=\"$1\" />\n\
+ <param name=\"controller\" value=\"$4\" />\n\
+ <param name=\"autoplay\" value=\"$5\" />\n\
+ <embed src=\"${1:movie.mov}\"\n\
+ width=\"${2:320}\" height=\"${3:240}\"\n\
+ controller=\"${4:true}\" autoplay=\"${5:true}\"\n\
+ scale=\"tofit\" cache=\"true\"\n\
+ pluginspage=\"http://www.apple.com/quicktime/download/\" />\n\
+ </object>${6}\n\
+snippet ol\n\
+ <ol>\n\
+ ${1}\n\
+ </ol>\n\
+snippet ol.\n\
+ <ol class=\"${1}>\n\
+ ${2}\n\
+ </ol>\n\
+snippet ol#\n\
+ <ol id=\"${1}>\n\
+ ${2}\n\
+ </ol>\n\
+snippet ol+\n\
+ <ol>\n\
+ <li>${1}</li>\n\
+ li+${2}\n\
+ </ol>\n\
+snippet opt\n\
+ <option value=\"${1}\">${2:$1}</option>\n\
+snippet opt+\n\
+ <option value=\"${1}\">${2:$1}</option>\n\
+ opt+${3}\n\
+snippet optt\n\
+ <option>${1}</option>\n\
+snippet optgroup\n\
+ <optgroup>\n\
+ <option value=\"${1}\">${2:$1}</option>\n\
+ opt+${3}\n\
+ </optgroup>\n\
+snippet output\n\
+ <output>${1}</output>\n\
+snippet p\n\
+ <p>${1}</p>\n\
+snippet param\n\
+ <param name=\"${1}\" value=\"${2}\" />${3}\n\
+snippet pre\n\
+ <pre>\n\
+ ${1}\n\
+ </pre>\n\
+snippet progress\n\
+ <progress>${1}</progress>\n\
+snippet q\n\
+ <q>${1}</q>\n\
+snippet rp\n\
+ <rp>${1}</rp>\n\
+snippet rt\n\
+ <rt>${1}</rt>\n\
+snippet ruby\n\
+ <ruby>\n\
+ <rp><rt>${1}</rt></rp>\n\
+ </ruby>\n\
+snippet s\n\
+ <s>${1}</s>\n\
+snippet samp\n\
+ <samp>\n\
+ ${1}\n\
+ </samp>\n\
+snippet script\n\
+ <script type=\"text/javascript\" charset=\"utf-8\">\n\
+ ${1}\n\
+ </script>\n\
+snippet scriptsrc\n\
+ <script src=\"${1}.js\" type=\"text/javascript\" charset=\"utf-8\"></script>\n\
+snippet newscript\n\
+ <script type=\"application/javascript\" charset=\"utf-8\">\n\
+ ${1}\n\
+ </script>\n\
+snippet newscriptsrc\n\
+ <script src=\"${1}.js\" type=\"application/javascript\" charset=\"utf-8\"></script>\n\
+snippet section\n\
+ <section>\n\
+ ${1}\n\
+ </section>\n\
+snippet section.\n\
+ <section class=\"${1}\">\n\
+ ${2}\n\
+ </section>\n\
+snippet section#\n\
+ <section id=\"${1}\">\n\
+ ${2}\n\
+ </section>\n\
+snippet select\n\
+ <select name=\"${1}\" id=\"${2:$1}\">\n\
+ ${3}\n\
+ </select>\n\
+snippet select.\n\
+ <select name=\"${1}\" id=\"${2:$1}\" class=\"${3}>\n\
+ ${4}\n\
+ </select>\n\
+snippet select+\n\
+ <select name=\"${1}\" id=\"${2:$1}\">\n\
+ <option value=\"${3}\">${4:$3}</option>\n\
+ opt+${5}\n\
+ </select>\n\
+snippet small\n\
+ <small>${1}</small>\n\
+snippet source\n\
+ <source src=\"${1}\" type=\"${2}\" media=\"${3}\" />\n\
+snippet span\n\
+ <span>${1}</span>\n\
+snippet strong\n\
+ <strong>${1}</strong>\n\
+snippet style\n\
+ <style type=\"text/css\" media=\"${1:all}\">\n\
+ ${2}\n\
+ </style>\n\
+snippet sub\n\
+ <sub>${1}</sub>\n\
+snippet summary\n\
+ <summary>\n\
+ ${1}\n\
+ </summary>\n\
+snippet sup\n\
+ <sup>${1}</sup>\n\
+snippet table\n\
+ <table border=\"${1:0}\">\n\
+ ${2}\n\
+ </table>\n\
+snippet table.\n\
+ <table class=\"${1}\" border=\"${2:0}\">\n\
+ ${3}\n\
+ </table>\n\
+snippet table#\n\
+ <table id=\"${1}\" border=\"${2:0}\">\n\
+ ${3}\n\
+ </table>\n\
+snippet tbody\n\
+ <tbody>\n\
+ ${1}\n\
+ </tbody>\n\
+snippet td\n\
+ <td>${1}</td>\n\
+snippet td.\n\
+ <td class=\"${1}\">${2}</td>\n\
+snippet td#\n\
+ <td id=\"${1}\">${2}</td>\n\
+snippet td+\n\
+ <td>${1}</td>\n\
+ td+${2}\n\
+snippet textarea\n\
+ <textarea name=\"${1}\" id=${2:$1} rows=\"${3:8}\" cols=\"${4:40}\">${5}</textarea>${6}\n\
+snippet tfoot\n\
+ <tfoot>\n\
+ ${1}\n\
+ </tfoot>\n\
+snippet th\n\
+ <th>${1}</th>\n\
+snippet th.\n\
+ <th class=\"${1}\">${2}</th>\n\
+snippet th#\n\
+ <th id=\"${1}\">${2}</th>\n\
+snippet th+\n\
+ <th>${1}</th>\n\
+ th+${2}\n\
+snippet thead\n\
+ <thead>\n\
+ ${1}\n\
+ </thead>\n\
+snippet time\n\
+ <time datetime=\"${1}\" pubdate=\"${2:$1}>${3:$1}</time>\n\
+snippet title\n\
+ <title>${1:`substitute(Filename('', 'Page Title'), '^.', '\\u&', '')`}</title>\n\
+snippet tr\n\
+ <tr>\n\
+ ${1}\n\
+ </tr>\n\
+snippet tr+\n\
+ <tr>\n\
+ <td>${1}</td>\n\
+ td+${2}\n\
+ </tr>\n\
+snippet track\n\
+ <track src=\"${1}\" srclang=\"${2}\" label=\"${3}\" default=\"${4:default}>${5}</track>${6}\n\
+snippet ul\n\
+ <ul>\n\
+ ${1}\n\
+ </ul>\n\
+snippet ul.\n\
+ <ul class=\"${1}\">\n\
+ ${2}\n\
+ </ul>\n\
+snippet ul#\n\
+ <ul id=\"${1}\">\n\
+ ${2}\n\
+ </ul>\n\
+snippet ul+\n\
+ <ul>\n\
+ <li>${1}</li>\n\
+ li+${2}\n\
+ </ul>\n\
+snippet var\n\
+ <var>${1}</var>\n\
+snippet video\n\
+ <video src=\"${1} height=\"${2}\" width=\"${3}\" preload=\"${5:none}\" autoplay=\"${6:autoplay}>${7}</video>${8}\n\
+snippet wbr\n\
+ <wbr />${1}\n\
+";
+exports.scope = "html";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/html_elixir.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/html_elixir.js
new file mode 100644
index 00000000..66d9eb38
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/html_elixir.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/html_elixir",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "html_elixir";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/html_ruby.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/html_ruby.js
new file mode 100644
index 00000000..83676f79
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/html_ruby.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/html_ruby",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "html_ruby";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/ini.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ini.js
new file mode 100644
index 00000000..ad9bf52f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ini.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/ini",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "ini";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/io.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/io.js
new file mode 100644
index 00000000..431002b4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/io.js
@@ -0,0 +1,69 @@
+ace.define("ace/snippets/io",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippets = [
+ {
+ "content": "assertEquals(${1:expected}, ${2:expr})",
+ "name": "assertEquals",
+ "scope": "io",
+ "tabTrigger": "ae"
+ },
+ {
+ "content": "${1:${2:newValue} := ${3:Object} }clone do(\n\t$0\n)",
+ "name": "clone do",
+ "scope": "io",
+ "tabTrigger": "cdo"
+ },
+ {
+ "content": "docSlot(\"${1:slotName}\", \"${2:documentation}\")",
+ "name": "docSlot",
+ "scope": "io",
+ "tabTrigger": "ds"
+ },
+ {
+ "content": "(${1:header,}\n\t${2:body}\n)$0",
+ "keyEquivalent": "@(",
+ "name": "Indented Bracketed Line",
+ "scope": "io",
+ "tabTrigger": "("
+ },
+ {
+ "content": "\n\t$0\n",
+ "keyEquivalent": "\r",
+ "name": "Special: Return Inside Empty Parenthesis",
+ "scope": "io meta.empty-parenthesis.io, io meta.comma-parenthesis.io"
+ },
+ {
+ "content": "${1:methodName} := method(${2:args,}\n\t$0\n)",
+ "name": "method",
+ "scope": "io",
+ "tabTrigger": "m"
+ },
+ {
+ "content": "newSlot(\"${1:slotName}\", ${2:defaultValue}, \"${3:docString}\")$0",
+ "name": "newSlot",
+ "scope": "io",
+ "tabTrigger": "ns"
+ },
+ {
+ "content": "${1:name} := Object clone do(\n\t$0\n)",
+ "name": "Object clone do",
+ "scope": "io",
+ "tabTrigger": "ocdo"
+ },
+ {
+ "content": "test${1:SomeFeature} := method(\n\t$0\n)",
+ "name": "testMethod",
+ "scope": "io",
+ "tabTrigger": "ts"
+ },
+ {
+ "content": "${1:Something}Test := ${2:UnitTest} clone do(\n\t$0\n)",
+ "name": "UnitTest",
+ "scope": "io",
+ "tabTrigger": "ut"
+ }
+];
+exports.scope = "io";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/jack.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jack.js
new file mode 100644
index 00000000..eca7f293
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jack.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/jack",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "jack";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/jade.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jade.js
new file mode 100644
index 00000000..f516d0c0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jade.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/jade",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "jade";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/java.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/java.js
new file mode 100644
index 00000000..1bc92aca
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/java.js
@@ -0,0 +1,247 @@
+ace.define("ace/snippets/java",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "## Access Modifiers\n\
+snippet po\n\
+ protected\n\
+snippet pu\n\
+ public\n\
+snippet pr\n\
+ private\n\
+##\n\
+## Annotations\n\
+snippet before\n\
+ @Before\n\
+ static void ${1:intercept}(${2:args}) { ${3} }\n\
+snippet mm\n\
+ @ManyToMany\n\
+ ${1}\n\
+snippet mo\n\
+ @ManyToOne\n\
+ ${1}\n\
+snippet om\n\
+ @OneToMany${1:(cascade=CascadeType.ALL)}\n\
+ ${2}\n\
+snippet oo\n\
+ @OneToOne\n\
+ ${1}\n\
+##\n\
+## Basic Java packages and import\n\
+snippet im\n\
+ import\n\
+snippet j.b\n\
+ java.beans.\n\
+snippet j.i\n\
+ java.io.\n\
+snippet j.m\n\
+ java.math.\n\
+snippet j.n\n\
+ java.net.\n\
+snippet j.u\n\
+ java.util.\n\
+##\n\
+## Class\n\
+snippet cl\n\
+ class ${1:`Filename(\"\", \"untitled\")`} ${2}\n\
+snippet in\n\
+ interface ${1:`Filename(\"\", \"untitled\")`} ${2:extends Parent}${3}\n\
+snippet tc\n\
+ public class ${1:`Filename()`} extends ${2:TestCase}\n\
+##\n\
+## Class Enhancements\n\
+snippet ext\n\
+ extends \n\
+snippet imp\n\
+ implements\n\
+##\n\
+## Comments\n\
+snippet /*\n\
+ /*\n\
+ * ${1}\n\
+ */\n\
+##\n\
+## Constants\n\
+snippet co\n\
+ static public final ${1:String} ${2:var} = ${3};${4}\n\
+snippet cos\n\
+ static public final String ${1:var} = \"${2}\";${3}\n\
+##\n\
+## Control Statements\n\
+snippet case\n\
+ case ${1}:\n\
+ ${2}\n\
+snippet def\n\
+ default:\n\
+ ${2}\n\
+snippet el\n\
+ else\n\
+snippet elif\n\
+ else if (${1}) ${2}\n\
+snippet if\n\
+ if (${1}) ${2}\n\
+snippet sw\n\
+ switch (${1}) {\n\
+ ${2}\n\
+ }\n\
+##\n\
+## Create a Method\n\
+snippet m\n\
+ ${1:void} ${2:method}(${3}) ${4:throws }${5}\n\
+##\n\
+## Create a Variable\n\
+snippet v\n\
+ ${1:String} ${2:var}${3: = null}${4};${5}\n\
+##\n\
+## Enhancements to Methods, variables, classes, etc.\n\
+snippet ab\n\
+ abstract\n\
+snippet fi\n\
+ final\n\
+snippet st\n\
+ static\n\
+snippet sy\n\
+ synchronized\n\
+##\n\
+## Error Methods\n\
+snippet err\n\
+ System.err.print(\"${1:Message}\");\n\
+snippet errf\n\
+ System.err.printf(\"${1:Message}\", ${2:exception});\n\
+snippet errln\n\
+ System.err.println(\"${1:Message}\");\n\
+##\n\
+## Exception Handling\n\
+snippet as\n\
+ assert ${1:test} : \"${2:Failure message}\";${3}\n\
+snippet ca\n\
+ catch(${1:Exception} ${2:e}) ${3}\n\
+snippet thr\n\
+ throw\n\
+snippet ths\n\
+ throws\n\
+snippet try\n\
+ try {\n\
+ ${3}\n\
+ } catch(${1:Exception} ${2:e}) {\n\
+ }\n\
+snippet tryf\n\
+ try {\n\
+ ${3}\n\
+ } catch(${1:Exception} ${2:e}) {\n\
+ } finally {\n\
+ }\n\
+##\n\
+## Find Methods\n\
+snippet findall\n\
+ List<${1:listName}> ${2:items} = ${1}.findAll();${3}\n\
+snippet findbyid\n\
+ ${1:var} ${2:item} = ${1}.findById(${3});${4}\n\
+##\n\
+## Javadocs\n\
+snippet /**\n\
+ /**\n\
+ * ${1}\n\
+ */\n\
+snippet @au\n\
+ @author `system(\"grep \\`id -un\\` /etc/passwd | cut -d \\\":\\\" -f5 | cut -d \\\",\\\" -f1\")`\n\
+snippet @br\n\
+ @brief ${1:Description}\n\
+snippet @fi\n\
+ @file ${1:`Filename()`}.java\n\
+snippet @pa\n\
+ @param ${1:param}\n\
+snippet @re\n\
+ @return ${1:param}\n\
+##\n\
+## Logger Methods\n\
+snippet debug\n\
+ Logger.debug(${1:param});${2}\n\
+snippet error\n\
+ Logger.error(${1:param});${2}\n\
+snippet info\n\
+ Logger.info(${1:param});${2}\n\
+snippet warn\n\
+ Logger.warn(${1:param});${2}\n\
+##\n\
+## Loops\n\
+snippet enfor\n\
+ for (${1} : ${2}) ${3}\n\
+snippet for\n\
+ for (${1}; ${2}; ${3}) ${4}\n\
+snippet wh\n\
+ while (${1}) ${2}\n\
+##\n\
+## Main method\n\
+snippet main\n\
+ public static void main (String[] args) {\n\
+ ${1:/* code */}\n\
+ }\n\
+##\n\
+## Print Methods\n\
+snippet print\n\
+ System.out.print(\"${1:Message}\");\n\
+snippet printf\n\
+ System.out.printf(\"${1:Message}\", ${2:args});\n\
+snippet println\n\
+ System.out.println(${1});\n\
+##\n\
+## Render Methods\n\
+snippet ren\n\
+ render(${1:param});${2}\n\
+snippet rena\n\
+ renderArgs.put(\"${1}\", ${2});${3}\n\
+snippet renb\n\
+ renderBinary(${1:param});${2}\n\
+snippet renj\n\
+ renderJSON(${1:param});${2}\n\
+snippet renx\n\
+ renderXml(${1:param});${2}\n\
+##\n\
+## Setter and Getter Methods\n\
+snippet set\n\
+ ${1:public} void set${3:}(${2:String} ${4:}){\n\
+ this.$4 = $4;\n\
+ }\n\
+snippet get\n\
+ ${1:public} ${2:String} get${3:}(){\n\
+ return this.${4:};\n\
+ }\n\
+##\n\
+## Terminate Methods or Loops\n\
+snippet re\n\
+ return\n\
+snippet br\n\
+ break;\n\
+##\n\
+## Test Methods\n\
+snippet t\n\
+ public void test${1:Name}() throws Exception {\n\
+ ${2}\n\
+ }\n\
+snippet test\n\
+ @Test\n\
+ public void test${1:Name}() throws Exception {\n\
+ ${2}\n\
+ }\n\
+##\n\
+## Utils\n\
+snippet Sc\n\
+ Scanner\n\
+##\n\
+## Miscellaneous\n\
+snippet action\n\
+ public static void ${1:index}(${2:args}) { ${3} }\n\
+snippet rnf\n\
+ notFound(${1:param});${2}\n\
+snippet rnfin\n\
+ notFoundIfNull(${1:param});${2}\n\
+snippet rr\n\
+ redirect(${1:param});${2}\n\
+snippet ru\n\
+ unauthorized(${1:param});${2}\n\
+snippet unless\n\
+ (unless=${1:param});${2}\n\
+";
+exports.scope = "java";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/javascript.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/javascript.js
new file mode 100644
index 00000000..f3f998ad
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/javascript.js
@@ -0,0 +1,202 @@
+ace.define("ace/snippets/javascript",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Prototype\n\
+snippet proto\n\
+ ${1:class_name}.prototype.${2:method_name} = function(${3:first_argument}) {\n\
+ ${4:// body...}\n\
+ };\n\
+# Function\n\
+snippet fun\n\
+ function ${1?:function_name}(${2:argument}) {\n\
+ ${3:// body...}\n\
+ }\n\
+# Anonymous Function\n\
+regex /((=)\\s*|(:)\\s*|(\\()|\\b)/f/(\\))?/\n\
+snippet f\n\
+ function${M1?: ${1:functionName}}($2) {\n\
+ ${0:$TM_SELECTED_TEXT}\n\
+ }${M2?;}${M3?,}${M4?)}\n\
+# Immediate function\n\
+trigger \\(?f\\(\n\
+endTrigger \\)?\n\
+snippet f(\n\
+ (function(${1}) {\n\
+ ${0:${TM_SELECTED_TEXT:/* code */}}\n\
+ }(${1}));\n\
+# if\n\
+snippet if\n\
+ if (${1:true}) {\n\
+ ${0}\n\
+ }\n\
+# if ... else\n\
+snippet ife\n\
+ if (${1:true}) {\n\
+ ${2}\n\
+ } else {\n\
+ ${0}\n\
+ }\n\
+# tertiary conditional\n\
+snippet ter\n\
+ ${1:/* condition */} ? ${2:a} : ${3:b}\n\
+# switch\n\
+snippet switch\n\
+ switch (${1:expression}) {\n\
+ case '${3:case}':\n\
+ ${4:// code}\n\
+ break;\n\
+ ${5}\n\
+ default:\n\
+ ${2:// code}\n\
+ }\n\
+# case\n\
+snippet case\n\
+ case '${1:case}':\n\
+ ${2:// code}\n\
+ break;\n\
+ ${3}\n\
+\n\
+# while (...) {...}\n\
+snippet wh\n\
+ while (${1:/* condition */}) {\n\
+ ${0:/* code */}\n\
+ }\n\
+# try\n\
+snippet try\n\
+ try {\n\
+ ${0:/* code */}\n\
+ } catch (e) {}\n\
+# do...while\n\
+snippet do\n\
+ do {\n\
+ ${2:/* code */}\n\
+ } while (${1:/* condition */});\n\
+# Object Method\n\
+snippet :f\n\
+regex /([,{[])|^\\s*/:f/\n\
+ ${1:method_name}: function(${2:attribute}) {\n\
+ ${0}\n\
+ }${3:,}\n\
+# setTimeout function\n\
+snippet setTimeout\n\
+regex /\\b/st|timeout|setTimeo?u?t?/\n\
+ setTimeout(function() {${3:$TM_SELECTED_TEXT}}, ${1:10});\n\
+# Get Elements\n\
+snippet gett\n\
+ getElementsBy${1:TagName}('${2}')${3}\n\
+# Get Element\n\
+snippet get\n\
+ getElementBy${1:Id}('${2}')${3}\n\
+# console.log (Firebug)\n\
+snippet cl\n\
+ console.log(${1});\n\
+# return\n\
+snippet ret\n\
+ return ${1:result}\n\
+# for (property in object ) { ... }\n\
+snippet fori\n\
+ for (var ${1:prop} in ${2:Things}) {\n\
+ ${0:$2[$1]}\n\
+ }\n\
+# hasOwnProperty\n\
+snippet has\n\
+ hasOwnProperty(${1})\n\
+# docstring\n\
+snippet /**\n\
+ /**\n\
+ * ${1:description}\n\
+ *\n\
+ */\n\
+snippet @par\n\
+regex /^\\s*\\*\\s*/@(para?m?)?/\n\
+ @param {${1:type}} ${2:name} ${3:description}\n\
+snippet @ret\n\
+ @return {${1:type}} ${2:description}\n\
+# JSON.parse\n\
+snippet jsonp\n\
+ JSON.parse(${1:jstr});\n\
+# JSON.stringify\n\
+snippet jsons\n\
+ JSON.stringify(${1:object});\n\
+# self-defining function\n\
+snippet sdf\n\
+ var ${1:function_name} = function(${2:argument}) {\n\
+ ${3:// initial code ...}\n\
+\n\
+ $1 = function($2) {\n\
+ ${4:// main code}\n\
+ };\n\
+ }\n\
+# singleton\n\
+snippet sing\n\
+ function ${1:Singleton} (${2:argument}) {\n\
+ // the cached instance\n\
+ var instance;\n\
+\n\
+ // rewrite the constructor\n\
+ $1 = function $1($2) {\n\
+ return instance;\n\
+ };\n\
+ \n\
+ // carry over the prototype properties\n\
+ $1.prototype = this;\n\
+\n\
+ // the instance\n\
+ instance = new $1();\n\
+\n\
+ // reset the constructor pointer\n\
+ instance.constructor = $1;\n\
+\n\
+ ${3:// code ...}\n\
+\n\
+ return instance;\n\
+ }\n\
+# class\n\
+snippet class\n\
+regex /^\\s*/clas{0,2}/\n\
+ var ${1:class} = function(${20}) {\n\
+ $40$0\n\
+ };\n\
+ \n\
+ (function() {\n\
+ ${60:this.prop = \"\"}\n\
+ }).call(${1:class}.prototype);\n\
+ \n\
+ exports.${1:class} = ${1:class};\n\
+# \n\
+snippet for-\n\
+ for (var ${1:i} = ${2:Things}.length; ${1:i}--; ) {\n\
+ ${0:${2:Things}[${1:i}];}\n\
+ }\n\
+# for (...) {...}\n\
+snippet for\n\
+ for (var ${1:i} = 0; $1 < ${2:Things}.length; $1++) {\n\
+ ${3:$2[$1]}$0\n\
+ }\n\
+# for (...) {...} (Improved Native For-Loop)\n\
+snippet forr\n\
+ for (var ${1:i} = ${2:Things}.length - 1; $1 >= 0; $1--) {\n\
+ ${3:$2[$1]}$0\n\
+ }\n\
+\n\
+\n\
+#modules\n\
+snippet def\n\
+ define(function(require, exports, module) {\n\
+ \"use strict\";\n\
+ var ${1/.*\\///} = require(\"${1}\");\n\
+ \n\
+ $TM_SELECTED_TEXT\n\
+ });\n\
+snippet req\n\
+guard ^\\s*\n\
+ var ${1/.*\\///} = require(\"${1}\");\n\
+ $0\n\
+snippet requ\n\
+guard ^\\s*\n\
+ var ${1/.*\\/(.)/\\u$1/} = require(\"${1}\").${1/.*\\/(.)/\\u$1/};\n\
+ $0\n\
+";
+exports.scope = "javascript";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/json.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/json.js
new file mode 100644
index 00000000..cc02e651
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/json.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/json",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "json";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsoniq.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsoniq.js
new file mode 100644
index 00000000..9c5eaf61
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsoniq.js
@@ -0,0 +1,68 @@
+ace.define("ace/snippets/jsoniq",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet for\n\
+ for $${1:item} in ${2:expr}\n\
+snippet return\n\
+ return ${1:expr}\n\
+snippet import\n\
+ import module namespace ${1:ns} = \"${2:http://www.example.com/}\";\n\
+snippet some\n\
+ some $${1:varname} in ${2:expr} satisfies ${3:expr}\n\
+snippet every\n\
+ every $${1:varname} in ${2:expr} satisfies ${3:expr}\n\
+snippet if\n\
+ if(${1:true}) then ${2:expr} else ${3:true}\n\
+snippet switch\n\
+ switch(${1:\"foo\"})\n\
+ case ${2:\"foo\"}\n\
+ return ${3:true}\n\
+ default return ${4:false}\n\
+snippet try\n\
+ try { ${1:expr} } catch ${2:*} { ${3:expr} }\n\
+snippet tumbling\n\
+ for tumbling window $${1:varname} in ${2:expr}\n\
+ start at $${3:start} when ${4:expr}\n\
+ end at $${5:end} when ${6:expr}\n\
+ return ${7:expr}\n\
+snippet sliding\n\
+ for sliding window $${1:varname} in ${2:expr}\n\
+ start at $${3:start} when ${4:expr}\n\
+ end at $${5:end} when ${6:expr}\n\
+ return ${7:expr}\n\
+snippet let\n\
+ let $${1:varname} := ${2:expr}\n\
+snippet group\n\
+ group by $${1:varname} := ${2:expr}\n\
+snippet order\n\
+ order by ${1:expr} ${2:descending}\n\
+snippet stable\n\
+ stable order by ${1:expr}\n\
+snippet count\n\
+ count $${1:varname}\n\
+snippet ordered\n\
+ ordered { ${1:expr} }\n\
+snippet unordered\n\
+ unordered { ${1:expr} }\n\
+snippet treat \n\
+ treat as ${1:expr}\n\
+snippet castable\n\
+ castable as ${1:atomicType}\n\
+snippet cast\n\
+ cast as ${1:atomicType}\n\
+snippet typeswitch\n\
+ typeswitch(${1:expr})\n\
+ case ${2:type} return ${3:expr}\n\
+ default return ${4:expr}\n\
+snippet var\n\
+ declare variable $${1:varname} := ${2:expr};\n\
+snippet fn\n\
+ declare function ${1:ns}:${2:name}(){\n\
+ ${3:expr}\n\
+ };\n\
+snippet module\n\
+ module namespace ${1:ns} = \"${2:http://www.example.com}\";\n\
+";
+exports.scope = "jsoniq";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsp.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsp.js
new file mode 100644
index 00000000..6428e5be
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsp.js
@@ -0,0 +1,106 @@
+ace.define("ace/snippets/jsp",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet @page\n\
+ <%@page contentType=\"text/html\" pageEncoding=\"UTF-8\"%>\n\
+snippet jstl\n\
+ <%@ taglib uri=\"http://java.sun.com/jsp/jstl/core\" prefix=\"c\" %>\n\
+ <%@ taglib uri=\"http://java.sun.com/jsp/jstl/functions\" prefix=\"fn\" %>\n\
+snippet jstl:c\n\
+ <%@ taglib uri=\"http://java.sun.com/jsp/jstl/core\" prefix=\"c\" %>\n\
+snippet jstl:fn\n\
+ <%@ taglib uri=\"http://java.sun.com/jsp/jstl/functions\" prefix=\"fn\" %>\n\
+snippet cpath\n\
+ ${pageContext.request.contextPath}\n\
+snippet cout\n\
+ <c:out value=\"${1}\" default=\"${2}\" />\n\
+snippet cset\n\
+ <c:set var=\"${1}\" value=\"${2}\" />\n\
+snippet cremove\n\
+ <c:remove var=\"${1}\" scope=\"${2:page}\" />\n\
+snippet ccatch\n\
+ <c:catch var=\"${1}\" />\n\
+snippet cif\n\
+ <c:if test=\"${${1}}\">\n\
+ ${2}\n\
+ </c:if>\n\
+snippet cchoose\n\
+ <c:choose>\n\
+ ${1}\n\
+ </c:choose>\n\
+snippet cwhen\n\
+ <c:when test=\"${${1}}\">\n\
+ ${2}\n\
+ </c:when>\n\
+snippet cother\n\
+ <c:otherwise>\n\
+ ${1}\n\
+ </c:otherwise>\n\
+snippet cfore\n\
+ <c:forEach items=\"${${1}}\" var=\"${2}\" varStatus=\"${3}\">\n\
+ ${4:<c:out value=\"$2\" />}\n\
+ </c:forEach>\n\
+snippet cfort\n\
+ <c:set var=\"${1}\">${2:item1,item2,item3}</c:set>\n\
+ <c:forTokens var=\"${3}\" items=\"${$1}\" delims=\"${4:,}\">\n\
+ ${5:<c:out value=\"$3\" />}\n\
+ </c:forTokens>\n\
+snippet cparam\n\
+ <c:param name=\"${1}\" value=\"${2}\" />\n\
+snippet cparam+\n\
+ <c:param name=\"${1}\" value=\"${2}\" />\n\
+ cparam+${3}\n\
+snippet cimport\n\
+ <c:import url=\"${1}\" />\n\
+snippet cimport+\n\
+ <c:import url=\"${1}\">\n\
+ <c:param name=\"${2}\" value=\"${3}\" />\n\
+ cparam+${4}\n\
+ </c:import>\n\
+snippet curl\n\
+ <c:url value=\"${1}\" var=\"${2}\" />\n\
+ <a href=\"${$2}\">${3}</a>\n\
+snippet curl+\n\
+ <c:url value=\"${1}\" var=\"${2}\">\n\
+ <c:param name=\"${4}\" value=\"${5}\" />\n\
+ cparam+${6}\n\
+ </c:url>\n\
+ <a href=\"${$2}\">${3}</a>\n\
+snippet credirect\n\
+ <c:redirect url=\"${1}\" />\n\
+snippet contains\n\
+ ${fn:contains(${1:string}, ${2:substr})}\n\
+snippet contains:i\n\
+ ${fn:containsIgnoreCase(${1:string}, ${2:substr})}\n\
+snippet endswith\n\
+ ${fn:endsWith(${1:string}, ${2:suffix})}\n\
+snippet escape\n\
+ ${fn:escapeXml(${1:string})}\n\
+snippet indexof\n\
+ ${fn:indexOf(${1:string}, ${2:substr})}\n\
+snippet join\n\
+ ${fn:join(${1:collection}, ${2:delims})}\n\
+snippet length\n\
+ ${fn:length(${1:collection_or_string})}\n\
+snippet replace\n\
+ ${fn:replace(${1:string}, ${2:substr}, ${3:replace})}\n\
+snippet split\n\
+ ${fn:split(${1:string}, ${2:delims})}\n\
+snippet startswith\n\
+ ${fn:startsWith(${1:string}, ${2:prefix})}\n\
+snippet substr\n\
+ ${fn:substring(${1:string}, ${2:begin}, ${3:end})}\n\
+snippet substr:a\n\
+ ${fn:substringAfter(${1:string}, ${2:substr})}\n\
+snippet substr:b\n\
+ ${fn:substringBefore(${1:string}, ${2:substr})}\n\
+snippet lc\n\
+ ${fn:toLowerCase(${1:string})}\n\
+snippet uc\n\
+ ${fn:toUpperCase(${1:string})}\n\
+snippet trim\n\
+ ${fn:trim(${1:string})}\n\
+";
+exports.scope = "jsp";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsx.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsx.js
new file mode 100644
index 00000000..9f39a943
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/jsx.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/jsx",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "jsx";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/julia.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/julia.js
new file mode 100644
index 00000000..e81370f7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/julia.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/julia",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "julia";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/kotlin.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/kotlin.js
new file mode 100644
index 00000000..d78bd463
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/kotlin.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/kotlin",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/latex.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/latex.js
new file mode 100644
index 00000000..e6fe7612
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/latex.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/latex",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "latex";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/less.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/less.js
new file mode 100644
index 00000000..148aa0cd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/less.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/less",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "less";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/liquid.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/liquid.js
new file mode 100644
index 00000000..c7f708dc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/liquid.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/liquid",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "liquid";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/lisp.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lisp.js
new file mode 100644
index 00000000..410b807f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lisp.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/lisp",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "lisp";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/livescript.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/livescript.js
new file mode 100644
index 00000000..37ea1c14
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/livescript.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/livescript",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "livescript";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/logiql.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/logiql.js
new file mode 100644
index 00000000..77943f3a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/logiql.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/logiql",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "logiql";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/lsl.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lsl.js
new file mode 100644
index 00000000..717a5cf3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lsl.js
@@ -0,0 +1,1239 @@
+ace.define("ace/snippets/lsl",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet @\n\
+ @${1:label};\n\
+snippet CAMERA_ACTIVE\n\
+ CAMERA_ACTIVE, ${1:integer isActive}, $0\n\
+snippet CAMERA_BEHINDNESS_ANGLE\n\
+ CAMERA_BEHINDNESS_ANGLE, ${1:float degrees}, $0\n\
+snippet CAMERA_BEHINDNESS_LAG\n\
+ CAMERA_BEHINDNESS_LAG, ${1:float seconds}, $0\n\
+snippet CAMERA_DISTANCE\n\
+ CAMERA_DISTANCE, ${1:float meters}, $0\n\
+snippet CAMERA_FOCUS\n\
+ CAMERA_FOCUS, ${1:vector position}, $0\n\
+snippet CAMERA_FOCUS_LAG\n\
+ CAMERA_FOCUS_LAG, ${1:float seconds}, $0\n\
+snippet CAMERA_FOCUS_LOCKED\n\
+ CAMERA_FOCUS_LOCKED, ${1:integer isLocked}, $0\n\
+snippet CAMERA_FOCUS_OFFSET\n\
+ CAMERA_FOCUS_OFFSET, ${1:vector meters}, $0\n\
+snippet CAMERA_FOCUS_THRESHOLD\n\
+ CAMERA_FOCUS_THRESHOLD, ${1:float meters}, $0\n\
+snippet CAMERA_PITCH\n\
+ CAMERA_PITCH, ${1:float degrees}, $0\n\
+snippet CAMERA_POSITION\n\
+ CAMERA_POSITION, ${1:vector position}, $0\n\
+snippet CAMERA_POSITION_LAG\n\
+ CAMERA_POSITION_LAG, ${1:float seconds}, $0\n\
+snippet CAMERA_POSITION_LOCKED\n\
+ CAMERA_POSITION_LOCKED, ${1:integer isLocked}, $0\n\
+snippet CAMERA_POSITION_THRESHOLD\n\
+ CAMERA_POSITION_THRESHOLD, ${1:float meters}, $0\n\
+snippet CHARACTER_AVOIDANCE_MODE\n\
+ CHARACTER_AVOIDANCE_MODE, ${1:integer flags}, $0\n\
+snippet CHARACTER_DESIRED_SPEED\n\
+ CHARACTER_DESIRED_SPEED, ${1:float speed}, $0\n\
+snippet CHARACTER_DESIRED_TURN_SPEED\n\
+ CHARACTER_DESIRED_TURN_SPEED, ${1:float speed}, $0\n\
+snippet CHARACTER_LENGTH\n\
+ CHARACTER_LENGTH, ${1:float length}, $0\n\
+snippet CHARACTER_MAX_TURN_RADIUS\n\
+ CHARACTER_MAX_TURN_RADIUS, ${1:float radius}, $0\n\
+snippet CHARACTER_ORIENTATION\n\
+ CHARACTER_ORIENTATION, ${1:integer orientation}, $0\n\
+snippet CHARACTER_RADIUS\n\
+ CHARACTER_RADIUS, ${1:float radius}, $0\n\
+snippet CHARACTER_STAY_WITHIN_PARCEL\n\
+ CHARACTER_STAY_WITHIN_PARCEL, ${1:boolean stay}, $0\n\
+snippet CHARACTER_TYPE\n\
+ CHARACTER_TYPE, ${1:integer type}, $0\n\
+snippet HTTP_BODY_MAXLENGTH\n\
+ HTTP_BODY_MAXLENGTH, ${1:integer length}, $0\n\
+snippet HTTP_CUSTOM_HEADER\n\
+ HTTP_CUSTOM_HEADER, ${1:string name}, ${2:string value}, $0\n\
+snippet HTTP_METHOD\n\
+ HTTP_METHOD, ${1:string method}, $0\n\
+snippet HTTP_MIMETYPE\n\
+ HTTP_MIMETYPE, ${1:string mimeType}, $0\n\
+snippet HTTP_PRAGMA_NO_CACHE\n\
+ HTTP_PRAGMA_NO_CACHE, ${1:integer send_header}, $0\n\
+snippet HTTP_VERBOSE_THROTTLE\n\
+ HTTP_VERBOSE_THROTTLE, ${1:integer noisy}, $0\n\
+snippet HTTP_VERIFY_CERT\n\
+ HTTP_VERIFY_CERT, ${1:integer verify}, $0\n\
+snippet RC_DATA_FLAGS\n\
+ RC_DATA_FLAGS, ${1:integer flags}, $0\n\
+snippet RC_DETECT_PHANTOM\n\
+ RC_DETECT_PHANTOM, ${1:integer dectedPhantom}, $0\n\
+snippet RC_MAX_HITS\n\
+ RC_MAX_HITS, ${1:integer maxHits}, $0\n\
+snippet RC_REJECT_TYPES\n\
+ RC_REJECT_TYPES, ${1:integer filterMask}, $0\n\
+snippet at_rot_target\n\
+ at_rot_target(${1:integer handle}, ${2:rotation targetrot}, ${3:rotation ourrot})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet at_target\n\
+ at_target(${1:integer tnum}, ${2:vector targetpos}, ${3:vector ourpos})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet attach\n\
+ attach(${1:key id})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet changed\n\
+ changed(${1:integer change})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet collision\n\
+ collision(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet collision_end\n\
+ collision_end(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet collision_start\n\
+ collision_start(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet control\n\
+ control(${1:key id}, ${2:integer level}, ${3:integer edge})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet dataserver\n\
+ dataserver(${1:key query_id}, ${2:string data})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet do\n\
+ do\n\
+ {\n\
+ $0\n\
+ }\n\
+ while (${1:condition});\n\
+snippet else\n\
+ else\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet email\n\
+ email(${1:string time}, ${2:string address}, ${3:string subject}, ${4:string message}, ${5:integer num_left})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet experience_permissions\n\
+ experience_permissions(${1:key agent_id})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet experience_permissions_denied\n\
+ experience_permissions_denied(${1:key agent_id}, ${2:integer reason})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet for\n\
+ for (${1:start}; ${3:condition}; ${3:step})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet http_request\n\
+ http_request(${1:key request_id}, ${2:string method}, ${3:string body})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet http_response\n\
+ http_response(${1:key request_id}, ${2:integer status}, ${3:list metadata}, ${4:string body})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet if\n\
+ if (${1:condition})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet jump\n\
+ jump ${1:label};\n\
+snippet land_collision\n\
+ land_collision(${1:vector pos})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet land_collision_end\n\
+ land_collision_end(${1:vector pos})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet land_collision_start\n\
+ land_collision_start(${1:vector pos})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet link_message\n\
+ link_message(${1:integer sender_num}, ${2:integer num}, ${3:string str}, ${4:key id})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet listen\n\
+ listen(${1:integer channel}, ${2:string name}, ${3:key id}, ${4:string message})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet llAbs\n\
+ llAbs(${1:integer val})\n\
+snippet llAcos\n\
+ llAcos(${1:float val})\n\
+snippet llAddToLandBanList\n\
+ llAddToLandBanList(${1:key agent}, ${2:float hours});\n\
+ $0\n\
+snippet llAddToLandPassList\n\
+ llAddToLandPassList(${1:key agent}, ${2:float hours});\n\
+ $0\n\
+snippet llAdjustSoundVolume\n\
+ llAdjustSoundVolume(${1:float volume});\n\
+ $0\n\
+snippet llAgentInExperience\n\
+ llAgentInExperience(${1:key agent})\n\
+snippet llAllowInventoryDrop\n\
+ llAllowInventoryDrop(${1:integer add});\n\
+ $0\n\
+snippet llAngleBetween\n\
+ llAngleBetween(${1:rotation a}, ${2:rotation b})\n\
+snippet llApplyImpulse\n\
+ llApplyImpulse(${1:vector force}, ${2:integer local});\n\
+ $0\n\
+snippet llApplyRotationalImpulse\n\
+ llApplyRotationalImpulse(${1:vector force}, ${2:integer local});\n\
+ $0\n\
+snippet llAsin\n\
+ llAsin(${1:float val})\n\
+snippet llAtan2\n\
+ llAtan2(${1:float y}, ${2:float x})\n\
+snippet llAttachToAvatar\n\
+ llAttachToAvatar(${1:integer attach_point});\n\
+ $0\n\
+snippet llAttachToAvatarTemp\n\
+ llAttachToAvatarTemp(${1:integer attach_point});\n\
+ $0\n\
+snippet llAvatarOnLinkSitTarget\n\
+ llAvatarOnLinkSitTarget(${1:integer link})\n\
+snippet llAvatarOnSitTarget\n\
+ llAvatarOnSitTarget()\n\
+snippet llAxes2Rot\n\
+ llAxes2Rot(${1:vector fwd}, ${2:vector left}, ${3:vector up})\n\
+snippet llAxisAngle2Rot\n\
+ llAxisAngle2Rot(${1:vector axis}, ${2:float angle})\n\
+snippet llBase64ToInteger\n\
+ llBase64ToInteger(${1:string str})\n\
+snippet llBase64ToString\n\
+ llBase64ToString(${1:string str})\n\
+snippet llBreakAllLinks\n\
+ llBreakAllLinks();\n\
+ $0\n\
+snippet llBreakLink\n\
+ llBreakLink(${1:integer link});\n\
+ $0\n\
+snippet llCastRay\n\
+ llCastRay(${1:vector start}, ${2:vector end}, ${3:list options});\n\
+ $0\n\
+snippet llCeil\n\
+ llCeil(${1:float val})\n\
+snippet llClearCameraParams\n\
+ llClearCameraParams();\n\
+ $0\n\
+snippet llClearLinkMedia\n\
+ llClearLinkMedia(${1:integer link}, ${2:integer face});\n\
+ $0\n\
+snippet llClearPrimMedia\n\
+ llClearPrimMedia(${1:integer face});\n\
+ $0\n\
+snippet llCloseRemoteDataChannel\n\
+ llCloseRemoteDataChannel(${1:key channel});\n\
+ $0\n\
+snippet llCollisionFilter\n\
+ llCollisionFilter(${1:string name}, ${2:key id}, ${3:integer accept});\n\
+ $0\n\
+snippet llCollisionSound\n\
+ llCollisionSound(${1:string impact_sound}, ${2:float impact_volume});\n\
+ $0\n\
+snippet llCos\n\
+ llCos(${1:float theta})\n\
+snippet llCreateCharacter\n\
+ llCreateCharacter(${1:list options});\n\
+ $0\n\
+snippet llCreateKeyValue\n\
+ llCreateKeyValue(${1:string k})\n\
+snippet llCreateLink\n\
+ llCreateLink(${1:key target}, ${2:integer parent});\n\
+ $0\n\
+snippet llCSV2List\n\
+ llCSV2List(${1:string src})\n\
+snippet llDataSizeKeyValue\n\
+ llDataSizeKeyValue()\n\
+snippet llDeleteCharacter\n\
+ llDeleteCharacter();\n\
+ $0\n\
+snippet llDeleteKeyValue\n\
+ llDeleteKeyValue(${1:string k})\n\
+snippet llDeleteSubList\n\
+ llDeleteSubList(${1:list src}, ${2:integer start}, ${3:integer end})\n\
+snippet llDeleteSubString\n\
+ llDeleteSubString(${1:string src}, ${2:integer start}, ${3:integer end})\n\
+snippet llDetachFromAvatar\n\
+ llDetachFromAvatar();\n\
+ $0\n\
+snippet llDetectedGrab\n\
+ llDetectedGrab(${1:integer number})\n\
+snippet llDetectedGroup\n\
+ llDetectedGroup(${1:integer number})\n\
+snippet llDetectedKey\n\
+ llDetectedKey(${1:integer number})\n\
+snippet llDetectedLinkNumber\n\
+ llDetectedLinkNumber(${1:integer number})\n\
+snippet llDetectedName\n\
+ llDetectedName(${1:integer number})\n\
+snippet llDetectedOwner\n\
+ llDetectedOwner(${1:integer number})\n\
+snippet llDetectedPos\n\
+ llDetectedPosl(${1:integer number})\n\
+snippet llDetectedRot\n\
+ llDetectedRot(${1:integer number})\n\
+snippet llDetectedTouchBinormal\n\
+ llDetectedTouchBinormal(${1:integer number})\n\
+snippet llDetectedTouchFace\n\
+ llDetectedTouchFace(${1:integer number})\n\
+snippet llDetectedTouchNormal\n\
+ llDetectedTouchNormal(${1:integer number})\n\
+snippet llDetectedTouchPos\n\
+ llDetectedTouchPos(${1:integer number})\n\
+snippet llDetectedTouchST\n\
+ llDetectedTouchST(${1:integer number})\n\
+snippet llDetectedTouchUV\n\
+ llDetectedTouchUV(${1:integer number})\n\
+snippet llDetectedType\n\
+ llDetectedType(${1:integer number})\n\
+snippet llDetectedVel\n\
+ llDetectedVel(${1:integer number})\n\
+snippet llDialog\n\
+ llDialog(${1:key agent}, ${2:string message}, ${3:list buttons}, ${4:integer channel});\n\
+ $0\n\
+snippet llDie\n\
+ llDie();\n\
+ $0\n\
+snippet llDumpList2String\n\
+ llDumpList2String(${1:list src}, ${2:string separator})\n\
+snippet llEdgeOfWorld\n\
+ llEdgeOfWorld(${1:vector pos}, ${2:vector dir})\n\
+snippet llEjectFromLand\n\
+ llEjectFromLand(${1:key agent});\n\
+ $0\n\
+snippet llEmail\n\
+ llEmail(${1:string address}, ${2:string subject}, ${3:string message});\n\
+ $0\n\
+snippet llEscapeURL\n\
+ llEscapeURL(${1:string url})\n\
+snippet llEuler2Rot\n\
+ llEuler2Rot(${1:vector v})\n\
+snippet llExecCharacterCmd\n\
+ llExecCharacterCmd(${1:integer command}, ${2:list options});\n\
+ $0\n\
+snippet llEvade\n\
+ llEvade(${1:key target}, ${2:list options});\n\
+ $0\n\
+snippet llFabs\n\
+ llFabs(${1:float val})\n\
+snippet llFleeFrom\n\
+ llFleeFrom(${1:vector position}, ${2:float distance}, ${3:list options});\n\
+ $0\n\
+snippet llFloor\n\
+ llFloor(${1:float val})\n\
+snippet llForceMouselook\n\
+ llForceMouselook(${1:integer mouselook});\n\
+ $0\n\
+snippet llFrand\n\
+ llFrand(${1:float mag})\n\
+snippet llGenerateKey\n\
+ llGenerateKey()\n\
+snippet llGetAccel\n\
+ llGetAccel()\n\
+snippet llGetAgentInfo\n\
+ llGetAgentInfo(${1:key id})\n\
+snippet llGetAgentLanguage\n\
+ llGetAgentLanguage(${1:key agent})\n\
+snippet llGetAgentList\n\
+ llGetAgentList(${1:integer scope}, ${2:list options})\n\
+snippet llGetAgentSize\n\
+ llGetAgentSize(${1:key agent})\n\
+snippet llGetAlpha\n\
+ llGetAlpha(${1:integer face})\n\
+snippet llGetAndResetTime\n\
+ llGetAndResetTime()\n\
+snippet llGetAnimation\n\
+ llGetAnimation(${1:key id})\n\
+snippet llGetAnimationList\n\
+ llGetAnimationList(${1:key agent})\n\
+snippet llGetAnimationOverride\n\
+ llGetAnimationOverride(${1:string anim_state})\n\
+snippet llGetAttached\n\
+ llGetAttached()\n\
+snippet llGetAttachedList\n\
+ llGetAttachedList(${1:key id})\n\
+snippet llGetBoundingBox\n\
+ llGetBoundingBox(${1:key object})\n\
+snippet llGetCameraPos\n\
+ llGetCameraPos()\n\
+snippet llGetCameraRot\n\
+ llGetCameraRot()\n\
+snippet llGetCenterOfMass\n\
+ llGetCenterOfMass()\n\
+snippet llGetClosestNavPoint\n\
+ llGetClosestNavPoint(${1:vector point}, ${2:list options})\n\
+snippet llGetColor\n\
+ llGetColor(${1:integer face})\n\
+snippet llGetCreator\n\
+ llGetCreator()\n\
+snippet llGetDate\n\
+ llGetDate()\n\
+snippet llGetDisplayName\n\
+ llGetDisplayName(${1:key id})\n\
+snippet llGetEnergy\n\
+ llGetEnergy()\n\
+snippet llGetEnv\n\
+ llGetEnv(${1:string name})\n\
+snippet llGetExperienceDetails\n\
+ llGetExperienceDetails(${1:key experience_id})\n\
+snippet llGetExperienceErrorMessage\n\
+ llGetExperienceErrorMessage(${1:integer error})\n\
+snippet llGetForce\n\
+ llGetForce()\n\
+snippet llGetFreeMemory\n\
+ llGetFreeMemory()\n\
+snippet llGetFreeURLs\n\
+ llGetFreeURLs()\n\
+snippet llGetGeometricCenter\n\
+ llGetGeometricCenter()\n\
+snippet llGetGMTclock\n\
+ llGetGMTclock()\n\
+snippet llGetHTTPHeader\n\
+ llGetHTTPHeader(${1:key request_id}, ${2:string header})\n\
+snippet llGetInventoryCreator\n\
+ llGetInventoryCreator(${1:string item})\n\
+snippet llGetInventoryKey\n\
+ llGetInventoryKey(${1:string name})\n\
+snippet llGetInventoryName\n\
+ llGetInventoryName(${1:integer type}, ${2:integer number})\n\
+snippet llGetInventoryNumber\n\
+ llGetInventoryNumber(${1:integer type})\n\
+snippet llGetInventoryPermMask\n\
+ llGetInventoryPermMask(${1:string item}, ${2:integer mask})\n\
+snippet llGetInventoryType\n\
+ llGetInventoryType(${1:string name})\n\
+snippet llGetKey\n\
+ llGetKey()\n\
+snippet llGetLandOwnerAt\n\
+ llGetLandOwnerAt(${1:vector pos})\n\
+snippet llGetLinkKey\n\
+ llGetLinkKey(${1:integer link})\n\
+snippet llGetLinkMedia\n\
+ llGetLinkMedia(${1:integer link}, ${2:integer face}, ${3:list params})\n\
+snippet llGetLinkName\n\
+ llGetLinkName(${1:integer link})\n\
+snippet llGetLinkNumber\n\
+ llGetLinkNumber()\n\
+snippet llGetLinkNumberOfSides\n\
+ llGetLinkNumberOfSides(${1:integer link})\n\
+snippet llGetLinkPrimitiveParams\n\
+ llGetLinkPrimitiveParams(${1:integer link}, ${2:list params})\n\
+snippet llGetListEntryType\n\
+ llGetListEntryType(${1:list src}, ${2:integer index})\n\
+snippet llGetListLength\n\
+ llGetListLength(${1:list src})\n\
+snippet llGetLocalPos\n\
+ llGetLocalPos()\n\
+snippet llGetLocalRot\n\
+ llGetLocalRot()\n\
+snippet llGetMass\n\
+ llGetMass()\n\
+snippet llGetMassMKS\n\
+ llGetMassMKS()\n\
+snippet llGetMaxScaleFactor\n\
+ llGetMaxScaleFactor()\n\
+snippet llGetMemoryLimit\n\
+ llGetMemoryLimit()\n\
+snippet llGetMinScaleFactor\n\
+ llGetMinScaleFactor()\n\
+snippet llGetNextEmail\n\
+ llGetNextEmail(${1:string address}, ${2:string subject});\n\
+ $0\n\
+snippet llGetNotecardLine\n\
+ llGetNotecardLine(${1:string name}, ${2:integer line})\n\
+snippet llGetNumberOfNotecardLines\n\
+ llGetNumberOfNotecardLines(${1:string name})\n\
+snippet llGetNumberOfPrims\n\
+ llGetNumberOfPrims()\n\
+snippet llGetNumberOfSides\n\
+ llGetNumberOfSides()\n\
+snippet llGetObjectDesc\n\
+ llGetObjectDesc()\n\
+snippet llGetObjectDetails\n\
+ llGetObjectDetails(${1:key id}, ${2:list params})\n\
+snippet llGetObjectMass\n\
+ llGetObjectMass(${1:key id})\n\
+snippet llGetObjectName\n\
+ llGetObjectName()\n\
+snippet llGetObjectPermMask\n\
+ llGetObjectPermMask(${1:integer mask})\n\
+snippet llGetObjectPrimCount\n\
+ llGetObjectPrimCount(${1:key prim})\n\
+snippet llGetOmega\n\
+ llGetOmega()\n\
+snippet llGetOwner\n\
+ llGetOwner()\n\
+snippet llGetOwnerKey\n\
+ llGetOwnerKey(${1:key id})\n\
+snippet llGetParcelDetails\n\
+ llGetParcelDetails(${1:vector pos}, ${2:list params})\n\
+snippet llGetParcelFlags\n\
+ llGetParcelFlags(${1:vector pos})\n\
+snippet llGetParcelMaxPrims\n\
+ llGetParcelMaxPrims(${1:vector pos}, ${2:integer sim_wide})\n\
+snippet llGetParcelMusicURL\n\
+ llGetParcelMusicURL()\n\
+snippet llGetParcelPrimCount\n\
+ llGetParcelPrimCount(${1:vector pos}, ${2:integer category}, ${3:integer sim_wide})\n\
+snippet llGetParcelPrimOwners\n\
+ llGetParcelPrimOwners(${1:vector pos})\n\
+snippet llGetPermissions\n\
+ llGetPermissions()\n\
+snippet llGetPermissionsKey\n\
+ llGetPermissionsKey()\n\
+snippet llGetPhysicsMaterial\n\
+ llGetPhysicsMaterial()\n\
+snippet llGetPos\n\
+ llGetPos()\n\
+snippet llGetPrimitiveParams\n\
+ llGetPrimitiveParams(${1:list params})\n\
+snippet llGetPrimMediaParams\n\
+ llGetPrimMediaParams(${1:integer face}, ${2:list params})\n\
+snippet llGetRegionAgentCount\n\
+ llGetRegionAgentCount()\n\
+snippet llGetRegionCorner\n\
+ llGetRegionCorner()\n\
+snippet llGetRegionFlags\n\
+ llGetRegionFlags()\n\
+snippet llGetRegionFPS\n\
+ llGetRegionFPS()\n\
+snippet llGetRegionName\n\
+ llGetRegionName()\n\
+snippet llGetRegionTimeDilation\n\
+ llGetRegionTimeDilation()\n\
+snippet llGetRootPosition\n\
+ llGetRootPosition()\n\
+snippet llGetRootRotation\n\
+ llGetRootRotation()\n\
+snippet llGetRot\n\
+ llGetRot()\n\
+snippet llGetScale\n\
+ llGetScale()\n\
+snippet llGetScriptName\n\
+ llGetScriptName()\n\
+snippet llGetScriptState\n\
+ llGetScriptState(${1:string script})\n\
+snippet llGetSimStats\n\
+ llGetSimStats(${1:integer stat_type})\n\
+snippet llGetSimulatorHostname\n\
+ llGetSimulatorHostname()\n\
+snippet llGetSPMaxMemory\n\
+ llGetSPMaxMemory()\n\
+snippet llGetStartParameter\n\
+ llGetStartParameter()\n\
+snippet llGetStaticPath\n\
+ llGetStaticPath(${1:vector start}, ${2:vector end}, ${3:float radius}, ${4:list params})\n\
+snippet llGetStatus\n\
+ llGetStatus(${1:integer status})\n\
+snippet llGetSubString\n\
+ llGetSubString(${1:string src}, ${2:integer start}, ${3:integer end})\n\
+snippet llGetSunDirection\n\
+ llGetSunDirection()\n\
+snippet llGetTexture\n\
+ llGetTexture(${1:integer face})\n\
+snippet llGetTextureOffset\n\
+ llGetTextureOffset(${1:integer face})\n\
+snippet llGetTextureRot\n\
+ llGetTextureRot(${1:integer face})\n\
+snippet llGetTextureScale\n\
+ llGetTextureScale(${1:integer face})\n\
+snippet llGetTime\n\
+ llGetTime()\n\
+snippet llGetTimeOfDay\n\
+ llGetTimeOfDay()\n\
+snippet llGetTimestamp\n\
+ llGetTimestamp()\n\
+snippet llGetTorque\n\
+ llGetTorque()\n\
+snippet llGetUnixTime\n\
+ llGetUnixTime()\n\
+snippet llGetUsedMemory\n\
+ llGetUsedMemory()\n\
+snippet llGetUsername\n\
+ llGetUsername(${1:key id})\n\
+snippet llGetVel\n\
+ llGetVel()\n\
+snippet llGetWallclock\n\
+ llGetWallclock()\n\
+snippet llGiveInventory\n\
+ llGiveInventory(${1:key destination}, ${2:string inventory});\n\
+ $0\n\
+snippet llGiveInventoryList\n\
+ llGiveInventoryList(${1:key target}, ${2:string folder}, ${3:list inventory});\n\
+ $0\n\
+snippet llGiveMoney\n\
+ llGiveMoney(${1:key destination}, ${2:integer amount})\n\
+snippet llGround\n\
+ llGround(${1:vector offset})\n\
+snippet llGroundContour\n\
+ llGroundContour(${1:vector offset})\n\
+snippet llGroundNormal\n\
+ llGroundNormal(${1:vector offset})\n\
+snippet llGroundRepel\n\
+ llGroundRepel(${1:float height}, ${2:integer water}, ${3:float tau});\n\
+ $0\n\
+snippet llGroundSlope\n\
+ llGroundSlope(${1:vector offset})\n\
+snippet llHTTPRequest\n\
+ llHTTPRequest(${1:string url}, ${2:list parameters}, ${3:string body})\n\
+snippet llHTTPResponse\n\
+ llHTTPResponse(${1:key request_id}, ${2:integer status}, ${3:string body});\n\
+ $0\n\
+snippet llInsertString\n\
+ llInsertString(${1:string dst}, ${2:integer pos}, ${3:string src})\n\
+snippet llInstantMessage\n\
+ llInstantMessage(${1:key user}, ${2:string message});\n\
+ $0\n\
+snippet llIntegerToBase64\n\
+ llIntegerToBase64(${1:integer number})\n\
+snippet llJson2List\n\
+ llJson2List(${1:string json})\n\
+snippet llJsonGetValue\n\
+ llJsonGetValue(${1:string json}, ${2:list specifiers})\n\
+snippet llJsonSetValue\n\
+ llJsonSetValue(${1:string json}, ${2:list specifiers}, ${3:string newValue})\n\
+snippet llJsonValueType\n\
+ llJsonValueType(${1:string json}, ${2:list specifiers})\n\
+snippet llKey2Name\n\
+ llKey2Name(${1:key id})\n\
+snippet llKeyCountKeyValue\n\
+ llKeyCountKeyValue()\n\
+snippet llKeysKeyValue\n\
+ llKeysKeyValue(${1:integer first}, ${2:integer count})\n\
+snippet llLinkParticleSystem\n\
+ llLinkParticleSystem(${1:integer link}, ${2:list rules});\n\
+ $0\n\
+snippet llLinkSitTarget\n\
+ llLinkSitTarget(${1:integer link}, ${2:vector offset}, ${3:rotation rot});\n\
+ $0\n\
+snippet llList2CSV\n\
+ llList2CSV(${1:list src})\n\
+snippet llList2Float\n\
+ llList2Float(${1:list src}, ${2:integer index})\n\
+snippet llList2Integer\n\
+ llList2Integer(${1:list src}, ${2:integer index})\n\
+snippet llList2Json\n\
+ llList2Json(${1:string type}, ${2:list values})\n\
+snippet llList2Key\n\
+ llList2Key(${1:list src}, ${2:integer index})\n\
+snippet llList2List\n\
+ llList2List(${1:list src}, ${2:integer start}, ${3:integer end})\n\
+snippet llList2ListStrided\n\
+ llList2ListStrided(${1:list src}, ${2:integer start}, ${3:integer end}, ${4:integer stride})\n\
+snippet llList2Rot\n\
+ llList2Rot(${1:list src}, ${2:integer index})\n\
+snippet llList2String\n\
+ llList2String(${1:list src}, ${2:integer index})\n\
+snippet llList2Vector\n\
+ llList2Vector(${1:list src}, ${2:integer index})\n\
+snippet llListen\n\
+ llListen(${1:integer channel}, ${2:string name}, ${3:key id}, ${4:string msg})\n\
+snippet llListenControl\n\
+ llListenControl(${1:integer handle}, ${2:integer active});\n\
+ $0\n\
+snippet llListenRemove\n\
+ llListenRemove(${1:integer handle});\n\
+ $0\n\
+snippet llListFindList\n\
+ llListFindList(${1:list src}, ${2:list test})\n\
+snippet llListInsertList\n\
+ llListInsertList(${1:list dest}, ${2:list src}, ${3:integer start})\n\
+snippet llListRandomize\n\
+ llListRandomize(${1:list src}, ${2:integer stride})\n\
+snippet llListReplaceList\n\
+ llListReplaceList(${1:list dest}, ${2:list src}, ${3:integer start}, ${4:integer end})\n\
+snippet llListSort\n\
+ llListSort(${1:list src}, ${2:integer stride}, ${3:integer ascending})\n\
+snippet llListStatistics\n\
+ llListStatistics(${1:integer operation}, ${2:list src})\n\
+snippet llLoadURL\n\
+ llLoadURL(${1:key agent}, ${2:string message}, ${3:string url});\n\
+ $0\n\
+snippet llLog\n\
+ llLog(${1:float val})\n\
+snippet llLog10\n\
+ llLog10(${1:float val})\n\
+snippet llLookAt\n\
+ llLookAt(${1:vector target}, ${2:float strength}, ${3:float damping});\n\
+ $0\n\
+snippet llLoopSound\n\
+ llLoopSound(${1:string sound}, ${2:float volume});\n\
+ $0\n\
+snippet llLoopSoundMaster\n\
+ llLoopSoundMaster(${1:string sound}, ${2:float volume});\n\
+ $0\n\
+snippet llLoopSoundSlave\n\
+ llLoopSoundSlave(${1:string sound}, ${2:float volume});\n\
+ $0\n\
+snippet llManageEstateAccess\n\
+ llManageEstateAccess(${1:integer action}, ${2:key agent})\n\
+snippet llMapDestination\n\
+ llMapDestination(${1:string simname}, ${2:vector pos}, ${3:vector look_at});\n\
+ $0\n\
+snippet llMD5String\n\
+ llMD5String(${1:string src}, ${2:integer nonce})\n\
+snippet llMessageLinked\n\
+ llMessageLinked(${1:integer link}, ${2:integer num}, ${3:string str}, ${4:key id});\n\
+ $0\n\
+snippet llMinEventDelay\n\
+ llMinEventDelay(${1:float delay});\n\
+ $0\n\
+snippet llModifyLand\n\
+ llModifyLand(${1:integer action}, ${2:integer brush});\n\
+ $0\n\
+snippet llModPow\n\
+ llModPow(${1:integer a}, ${2:integer b}, ${3:integer c})\n\
+snippet llMoveToTarget\n\
+ llMoveToTarget(${1:vector target}, ${2:float tau});\n\
+ $0\n\
+snippet llNavigateTo\n\
+ llNavigateTo(${1:vector pos}, ${2:list options});\n\
+ $0\n\
+snippet llOffsetTexture\n\
+ llOffsetTexture(${1:float u}, ${2:float v}, ${3:integer face});\n\
+ $0\n\
+snippet llOpenRemoteDataChannel\n\
+ llOpenRemoteDataChannel();\n\
+ $0\n\
+snippet llOverMyLand\n\
+ llOverMyLand(${1:key id})\n\
+snippet llOwnerSay\n\
+ llOwnerSay(${1:string msg});\n\
+ $0\n\
+snippet llParcelMediaCommandList\n\
+ llParcelMediaCommandList(${1:list commandList});\n\
+ $0\n\
+snippet llParcelMediaQuery\n\
+ llParcelMediaQuery(${1:list query})\n\
+snippet llParseString2List\n\
+ llParseString2List(${1:string src}, ${2:list separators}, ${3:list spacers})\n\
+snippet llParseStringKeepNulls\n\
+ llParseStringKeepNulls(${1:string src}, ${2:list separators}, ${3:list spacers})\n\
+snippet llParticleSystem\n\
+ llParticleSystem(${1:list rules});\n\
+ $0\n\
+snippet llPassCollisions\n\
+ llPassCollisions(${1:integer pass});\n\
+ $0\n\
+snippet llPassTouches\n\
+ llPassTouches(${1:integer pass});\n\
+ $0\n\
+snippet llPatrolPoints\n\
+ llPatrolPoints(${1:list patrolPoints}, ${2:list options});\n\
+ $0\n\
+snippet llPlaySound\n\
+ llPlaySound(${1:string sound}, ${2:float volume});\n\
+ $0\n\
+snippet llPlaySoundSlave\n\
+ llPlaySoundSlave(${1:string sound}, ${2:float volume});\n\
+ $0\n\
+snippet llPow\n\
+ llPow(${1:float base}, ${2:float exponent})\n\
+snippet llPreloadSound\n\
+ llPreloadSound(${1:string sound});\n\
+ $0\n\
+snippet llPursue\n\
+ llPursue(${1:key target}, ${2:list options});\n\
+ $0\n\
+snippet llPushObject\n\
+ llPushObject(${1:key target}, ${2:vector impulse}, ${3:vector ang_impulse}, ${4:integer local});\n\
+ $0\n\
+snippet llReadKeyValue\n\
+ llReadKeyValue(${1:string k})\n\
+snippet llRegionSay\n\
+ llRegionSay(${1:integer channel}, ${2:string msg});\n\
+ $0\n\
+snippet llRegionSayTo\n\
+ llRegionSayTo(${1:key target}, ${2:integer channel}, ${3:string msg});\n\
+ $0\n\
+snippet llReleaseControls\n\
+ llReleaseControls();\n\
+ $0\n\
+snippet llReleaseURL\n\
+ llReleaseURL(${1:string url});\n\
+ $0\n\
+snippet llRemoteDataReply\n\
+ llRemoteDataReply(${1:key channel}, ${2:key message_id}, ${3:string sdata}, ${4:integer idata});\n\
+ $0\n\
+snippet llRemoteLoadScriptPin\n\
+ llRemoteLoadScriptPin(${1:key target}, ${2:string name}, ${3:integer pin}, ${4:integer running}, ${5:integer start_param});\n\
+ $0\n\
+snippet llRemoveFromLandBanList\n\
+ llRemoveFromLandBanList(${1:key agent});\n\
+ $0\n\
+snippet llRemoveFromLandPassList\n\
+ llRemoveFromLandPassList(${1:key agent});\n\
+ $0\n\
+snippet llRemoveInventory\n\
+ llRemoveInventory(${1:string item});\n\
+ $0\n\
+snippet llRemoveVehicleFlags\n\
+ llRemoveVehicleFlags(${1:integer flags});\n\
+ $0\n\
+snippet llRequestAgentData\n\
+ llRequestAgentData(${1:key id}, ${2:integer data})\n\
+snippet llRequestDisplayName\n\
+ llRequestDisplayName(${1:key id})\n\
+snippet llRequestExperiencePermissions\n\
+ llRequestExperiencePermissions(${1:key agent}, ${2:string name})\n\
+snippet llRequestInventoryData\n\
+ llRequestInventoryData(${1:string name})\n\
+snippet llRequestPermissions\n\
+ llRequestPermissions(${1:key agent}, ${2:integer permissions})\n\
+snippet llRequestSecureURL\n\
+ llRequestSecureURL()\n\
+snippet llRequestSimulatorData\n\
+ llRequestSimulatorData(${1:string region}, ${2:integer data})\n\
+snippet llRequestURL\n\
+ llRequestURL()\n\
+snippet llRequestUsername\n\
+ llRequestUsername(${1:key id})\n\
+snippet llResetAnimationOverride\n\
+ llResetAnimationOverride(${1:string anim_state});\n\
+ $0\n\
+snippet llResetLandBanList\n\
+ llResetLandBanList();\n\
+ $0\n\
+snippet llResetLandPassList\n\
+ llResetLandPassList();\n\
+ $0\n\
+snippet llResetOtherScript\n\
+ llResetOtherScript(${1:string name});\n\
+ $0\n\
+snippet llResetScript\n\
+ llResetScript();\n\
+ $0\n\
+snippet llResetTime\n\
+ llResetTime();\n\
+ $0\n\
+snippet llReturnObjectsByID\n\
+ llReturnObjectsByID(${1:list objects})\n\
+snippet llReturnObjectsByOwner\n\
+ llReturnObjectsByOwner(${1:key owner}, ${2:integer scope})\n\
+snippet llRezAtRoot\n\
+ llRezAtRoot(${1:string inventory}, ${2:vector position}, ${3:vector velocity}, ${4:rotation rot}, ${5:integer param});\n\
+ $0\n\
+snippet llRezObject\n\
+ llRezObject(${1:string inventory}, ${2:vector pos}, ${3:vector vel}, ${4:rotation rot}, ${5:integer param});\n\
+ $0\n\
+snippet llRot2Angle\n\
+ llRot2Angle(${1:rotation rot})\n\
+snippet llRot2Axis\n\
+ llRot2Axis(${1:rotation rot})\n\
+snippet llRot2Euler\n\
+ llRot2Euler(${1:rotation quat})\n\
+snippet llRot2Fwd\n\
+ llRot2Fwd(${1:rotation q})\n\
+snippet llRot2Left\n\
+ llRot2Left(${1:rotation q})\n\
+snippet llRot2Up\n\
+ llRot2Up(${1:rotation q})\n\
+snippet llRotateTexture\n\
+ llRotateTexture(${1:float angle}, ${2:integer face});\n\
+ $0\n\
+snippet llRotBetween\n\
+ llRotBetween(${1:vector start}, ${2:vector end})\n\
+snippet llRotLookAt\n\
+ llRotLookAt(${1:rotation target_direction}, ${2:float strength}, ${3:float damping});\n\
+ $0\n\
+snippet llRotTarget\n\
+ llRotTarget(${1:rotation rot}, ${2:float error})\n\
+snippet llRotTargetRemove\n\
+ llRotTargetRemove(${1:integer handle});\n\
+ $0\n\
+snippet llRound\n\
+ llRound(${1:float val})\n\
+snippet llSameGroup\n\
+ llSameGroup(${1:key group})\n\
+snippet llSay\n\
+ llSay(${1:integer channel}, ${2:string msg});\n\
+ $0\n\
+snippet llScaleByFactor\n\
+ llScaleByFactor(${1:float scaling_factor})\n\
+snippet llScaleTexture\n\
+ llScaleTexture(${1:float u}, ${2:float v}, ${3:integer face});\n\
+ $0\n\
+snippet llScriptDanger\n\
+ llScriptDanger(${1:vector pos})\n\
+snippet llScriptProfiler\n\
+ llScriptProfiler(${1:integer flags});\n\
+ $0\n\
+snippet llSendRemoteData\n\
+ llSendRemoteData(${1:key channel}, ${2:string dest}, ${3:integer idata}, ${4:string sdata})\n\
+snippet llSensor\n\
+ llSensor(${1:string name}, ${2:key id}, ${3:integer type}, ${4:float range}, ${5:float arc});\n\
+ $0\n\
+snippet llSensorRepeat\n\
+ llSensorRepeat(${1:string name}, ${2:key id}, ${3:integer type}, ${4:float range}, ${5:float arc}, ${6:float rate});\n\
+ $0\n\
+snippet llSetAlpha\n\
+ llSetAlpha(${1:float alpha}, ${2:integer face});\n\
+ $0\n\
+snippet llSetAngularVelocity\n\
+ llSetAngularVelocity(${1:vector force}, ${2:integer local});\n\
+ $0\n\
+snippet llSetAnimationOverride\n\
+ llSetAnimationOverride(${1:string anim_state}, ${2:string anim})\n\
+snippet llSetBuoyancy\n\
+ llSetBuoyancy(${1:float buoyancy});\n\
+ $0\n\
+snippet llSetCameraAtOffset\n\
+ llSetCameraAtOffset(${1:vector offset});\n\
+ $0\n\
+snippet llSetCameraEyeOffset\n\
+ llSetCameraEyeOffset(${1:vector offset});\n\
+ $0\n\
+snippet llSetCameraParams\n\
+ llSetCameraParams(${1:list rules});\n\
+ $0\n\
+snippet llSetClickAction\n\
+ llSetClickAction(${1:integer action});\n\
+ $0\n\
+snippet llSetColor\n\
+ llSetColor(${1:vector color}, ${2:integer face});\n\
+ $0\n\
+snippet llSetContentType\n\
+ llSetContentType(${1:key request_id}, ${2:integer content_type});\n\
+ $0\n\
+snippet llSetDamage\n\
+ llSetDamage(${1:float damage});\n\
+ $0\n\
+snippet llSetForce\n\
+ llSetForce(${1:vector force}, ${2:integer local});\n\
+ $0\n\
+snippet llSetForceAndTorque\n\
+ llSetForceAndTorque(${1:vector force}, ${2:vector torque}, ${3:integer local});\n\
+ $0\n\
+snippet llSetHoverHeight\n\
+ llSetHoverHeight(${1:float height}, ${2:integer water}, ${3:float tau});\n\
+ $0\n\
+snippet llSetKeyframedMotion\n\
+ llSetKeyframedMotion(${1:list keyframes}, ${2:list options});\n\
+ $0\n\
+snippet llSetLinkAlpha\n\
+ llSetLinkAlpha(${1:integer link}, ${2:float alpha}, ${3:integer face});\n\
+ $0\n\
+snippet llSetLinkCamera\n\
+ llSetLinkCamera(${1:integer link}, ${2:vector eye}, ${3:vector at});\n\
+ $0\n\
+snippet llSetLinkColor\n\
+ llSetLinkColor(${1:integer link}, ${2:vector color}, ${3:integer face});\n\
+ $0\n\
+snippet llSetLinkMedia\n\
+ llSetLinkMedia(${1:integer link}, ${2:integer face}, ${3:list params});\n\
+ $0\n\
+snippet llSetLinkPrimitiveParams\n\
+ llSetLinkPrimitiveParams(${1:integer link}, ${2:list rules});\n\
+ $0\n\
+snippet llSetLinkPrimitiveParamsFast\n\
+ llSetLinkPrimitiveParamsFast(${1:integer link}, ${2:list rules});\n\
+ $0\n\
+snippet llSetLinkTexture\n\
+ llSetLinkTexture(${1:integer link}, ${2:string texture}, ${3:integer face});\n\
+ $0\n\
+snippet llSetLinkTextureAnim\n\
+ llSetLinkTextureAnim(${1:integer link}, ${2:integer mode}, ${3:integer face}, ${4:integer sizex}, ${5:integer sizey}, ${6:float start}, ${7:float length}, ${8:float rate});\n\
+ $0\n\
+snippet llSetLocalRot\n\
+ llSetLocalRot(${1:rotation rot});\n\
+ $0\n\
+snippet llSetMemoryLimit\n\
+ llSetMemoryLimit(${1:integer limit})\n\
+snippet llSetObjectDesc\n\
+ llSetObjectDesc(${1:string description});\n\
+ $0\n\
+snippet llSetObjectName\n\
+ llSetObjectName(${1:string name});\n\
+ $0\n\
+snippet llSetParcelMusicURL\n\
+ llSetParcelMusicURL(${1:string url});\n\
+ $0\n\
+snippet llSetPayPrice\n\
+ llSetPayPrice(${1:integer price}, [${2:integer price_button_a}, ${3:integer price_button_b}, ${4:integer price_button_c}, ${5:integer price_button_d}]);\n\
+ $0\n\
+snippet llSetPhysicsMaterial\n\
+ llSetPhysicsMaterial(${1:integer mask}, ${2:float gravity_multiplier}, ${3:float restitution}, ${4:float friction}, ${5:float density});\n\
+ $0\n\
+snippet llSetPos\n\
+ llSetPos(${1:vector pos});\n\
+ $0\n\
+snippet llSetPrimitiveParams\n\
+ llSetPrimitiveParams(${1:list rules});\n\
+ $0\n\
+snippet llSetPrimMediaParams\n\
+ llSetPrimMediaParams(${1:integer face}, ${2:list params});\n\
+ $0\n\
+snippet llSetRegionPos\n\
+ llSetRegionPos(${1:vector position})\n\
+snippet llSetRemoteScriptAccessPin\n\
+ llSetRemoteScriptAccessPin(${1:integer pin});\n\
+ $0\n\
+snippet llSetRot\n\
+ llSetRot(${1:rotation rot});\n\
+ $0\n\
+snippet llSetScale\n\
+ llSetScale(${1:vector size});\n\
+ $0\n\
+snippet llSetScriptState\n\
+ llSetScriptState(${1:string name}, ${2:integer run});\n\
+ $0\n\
+snippet llSetSitText\n\
+ llSetSitText(${1:string text});\n\
+ $0\n\
+snippet llSetSoundQueueing\n\
+ llSetSoundQueueing(${1:integer queue});\n\
+ $0\n\
+snippet llSetSoundRadius\n\
+ llSetSoundRadius(${1:float radius});\n\
+ $0\n\
+snippet llSetStatus\n\
+ llSetStatus(${1:integer status}, ${2:integer value});\n\
+ $0\n\
+snippet llSetText\n\
+ llSetText(${1:string text}, ${2:vector color}, ${3:float alpha});\n\
+ $0\n\
+snippet llSetTexture\n\
+ llSetTexture(${1:string texture}, ${2:integer face});\n\
+ $0\n\
+snippet llSetTextureAnim\n\
+ llSetTextureAnim(${1:integer mode}, ${2:integer face}, ${3:integer sizex}, ${4:integer sizey}, ${5:float start}, ${6:float length}, ${7:float rate});\n\
+ $0\n\
+snippet llSetTimerEvent\n\
+ llSetTimerEvent(${1:float sec});\n\
+ $0\n\
+snippet llSetTorque\n\
+ llSetTorque(${1:vector torque}, ${2:integer local});\n\
+ $0\n\
+snippet llSetTouchText\n\
+ llSetTouchText(${1:string text});\n\
+ $0\n\
+snippet llSetVehicleFlags\n\
+ llSetVehicleFlags(${1:integer flags});\n\
+ $0\n\
+snippet llSetVehicleFloatParam\n\
+ llSetVehicleFloatParam(${1:integer param}, ${2:float value});\n\
+ $0\n\
+snippet llSetVehicleRotationParam\n\
+ llSetVehicleRotationParam(${1:integer param}, ${2:rotation rot});\n\
+ $0\n\
+snippet llSetVehicleType\n\
+ llSetVehicleType(${1:integer type});\n\
+ $0\n\
+snippet llSetVehicleVectorParam\n\
+ llSetVehicleVectorParam(${1:integer param}, ${2:vector vec});\n\
+ $0\n\
+snippet llSetVelocity\n\
+ llSetVelocity(${1:vector force}, ${2:integer local});\n\
+ $0\n\
+snippet llSHA1String\n\
+ llSHA1String(${1:string src})\n\
+snippet llShout\n\
+ llShout(${1:integer channel}, ${2:string msg});\n\
+ $0\n\
+snippet llSin\n\
+ llSin(${1:float theta})\n\
+snippet llSitTarget\n\
+ llSitTarget(${1:vector offset}, ${2:rotation rot});\n\
+ $0\n\
+snippet llSleep\n\
+ llSleep(${1:float sec});\n\
+ $0\n\
+snippet llSqrt\n\
+ llSqrt(${1:float val})\n\
+snippet llStartAnimation\n\
+ llStartAnimation(${1:string anim});\n\
+ $0\n\
+snippet llStopAnimation\n\
+ llStopAnimation(${1:string anim});\n\
+ $0\n\
+snippet llStopHover\n\
+ llStopHover();\n\
+ $0\n\
+snippet llStopLookAt\n\
+ llStopLookAt();\n\
+ $0\n\
+snippet llStopMoveToTarget\n\
+ llStopMoveToTarget();\n\
+ $0\n\
+snippet llStopSound\n\
+ llStopSound();\n\
+ $0\n\
+snippet llStringLength\n\
+ llStringLength(${1:string str})\n\
+snippet llStringToBase64\n\
+ llStringToBase64(${1:string str})\n\
+snippet llStringTrim\n\
+ llStringTrim(${1:string src}, ${2:integer type})\n\
+snippet llSubStringIndex\n\
+ llSubStringIndex(${1:string source}, ${2:string pattern})\n\
+snippet llTakeControls\n\
+ llTakeControls(${1:integer controls}, ${2:integer accept}, ${3:integer pass_on});\n\
+ $0\n\
+snippet llTan\n\
+ llTan(${1:float theta})\n\
+snippet llTarget\n\
+ llTarget(${1:vector position}, ${2:float range})\n\
+snippet llTargetOmega\n\
+ llTargetOmega(${1:vector axis}, ${2:float spinrate}, ${3:float gain});\n\
+ $0\n\
+snippet llTargetRemove\n\
+ llTargetRemove(${1:integer handle});\n\
+ $0\n\
+snippet llTeleportAgent\n\
+ llTeleportAgent(${1:key agent}, ${2:string landmark}, ${3:vector position}, ${4:vector look_at});\n\
+ $0\n\
+snippet llTeleportAgentGlobalCoords\n\
+ llTeleportAgentGlobalCoords(${1:key agent}, ${2:vector global_coordinates}, ${3:vector region_coordinates}, ${4:vector look_at});\n\
+ $0\n\
+snippet llTeleportAgentHome\n\
+ llTeleportAgentHome(${1:key agent});\n\
+ $0\n\
+snippet llTextBox\n\
+ llTextBox(${1:key agent}, ${2:string message}, ${3:integer channel});\n\
+ $0\n\
+snippet llToLower\n\
+ llToLower(${1:string src})\n\
+snippet llToUpper\n\
+ llToUpper(${1:string src})\n\
+snippet llTransferLindenDollars\n\
+ llTransferLindenDollars(${1:key destination}, ${2:integer amount})\n\
+snippet llTriggerSound\n\
+ llTriggerSound(${1:string sound}, ${2:float volume});\n\
+ $0\n\
+snippet llTriggerSoundLimited\n\
+ llTriggerSoundLimited(${1:string sound}, ${2:float volume}, ${3:vector top_north_east}, ${4:vector bottom_south_west});\n\
+ $0\n\
+snippet llUnescapeURL\n\
+ llUnescapeURL(${1:string url})\n\
+snippet llUnSit\n\
+ llUnSit(${1:key id});\n\
+ $0\n\
+snippet llUpdateCharacter\n\
+ llUpdateCharacter(${1:list options})\n\
+snippet llUpdateKeyValue\n\
+ llUpdateKeyValue(${1:string k}, ${2:string v}, ${3:integer checked}, ${4:string ov})\n\
+snippet llVecDist\n\
+ llVecDist(${1:vector vec_a}, ${2:vector vec_b})\n\
+snippet llVecMag\n\
+ llVecMag(${1:vector vec})\n\
+snippet llVecNorm\n\
+ llVecNorm(${1:vector vec})\n\
+snippet llVolumeDetect\n\
+ llVolumeDetect(${1:integer detect});\n\
+ $0\n\
+snippet llWanderWithin\n\
+ llWanderWithin(${1:vector origin}, ${2:vector dist}, ${3:list options});\n\
+ $0\n\
+snippet llWater\n\
+ llWater(${1:vector offset});\n\
+ $0\n\
+snippet llWhisper\n\
+ llWhisper(${1:integer channel}, ${2:string msg});\n\
+ $0\n\
+snippet llWind\n\
+ llWind(${1:vector offset});\n\
+ $0\n\
+snippet llXorBase64\n\
+ llXorBase64(${1:string str1}, ${2:string str2})\n\
+snippet money\n\
+ money(${1:key id}, ${2:integer amount})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet object_rez\n\
+ object_rez(${1:key id})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet on_rez\n\
+ on_rez(${1:integer start_param})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet path_update\n\
+ path_update(${1:integer type}, ${2:list reserved})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet remote_data\n\
+ remote_data(${1:integer event_type}, ${2:key channel}, ${3:key message_id}, ${4:string sender}, ${5:integer idata}, ${6:string sdata})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet run_time_permissions\n\
+ run_time_permissions(${1:integer perm})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet sensor\n\
+ sensor(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet state\n\
+ state ${1:name}\n\
+snippet touch\n\
+ touch(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet touch_end\n\
+ touch_end(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet touch_start\n\
+ touch_start(${1:integer index})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet transaction_result\n\
+ transaction_result(${1:key id}, ${2:integer success}, ${3:string data})\n\
+ {\n\
+ $0\n\
+ }\n\
+snippet while\n\
+ while (${1:condition})\n\
+ {\n\
+ $0\n\
+ }\n\
+";
+exports.scope = "lsl";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/lua.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lua.js
new file mode 100644
index 00000000..c369b648
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lua.js
@@ -0,0 +1,28 @@
+ace.define("ace/snippets/lua",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet #!\n\
+ #!/usr/bin/env lua\n\
+ $1\n\
+snippet local\n\
+ local ${1:x} = ${2:1}\n\
+snippet fun\n\
+ function ${1:fname}(${2:...})\n\
+ ${3:-- body}\n\
+ end\n\
+snippet for\n\
+ for ${1:i}=${2:1},${3:10} do\n\
+ ${4:print(i)}\n\
+ end\n\
+snippet forp\n\
+ for ${1:i},${2:v} in pairs(${3:table_name}) do\n\
+ ${4:-- body}\n\
+ end\n\
+snippet fori\n\
+ for ${1:i},${2:v} in ipairs(${3:table_name}) do\n\
+ ${4:-- body}\n\
+ end\n\
+";
+exports.scope = "lua";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/luapage.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/luapage.js
new file mode 100644
index 00000000..f1bcf091
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/luapage.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/luapage",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "luapage";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/lucene.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lucene.js
new file mode 100644
index 00000000..8795919e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/lucene.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/lucene",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "lucene";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/makefile.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/makefile.js
new file mode 100644
index 00000000..6c02e0d6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/makefile.js
@@ -0,0 +1,11 @@
+ace.define("ace/snippets/makefile",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet ifeq\n\
+ ifeq (${1:cond0},${2:cond1})\n\
+ ${3:code}\n\
+ endif\n\
+";
+exports.scope = "makefile";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/markdown.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/markdown.js
new file mode 100644
index 00000000..d05f16b9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/markdown.js
@@ -0,0 +1,95 @@
+ace.define("ace/snippets/markdown",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Markdown\n\
+\n\
+# Includes octopress (http://octopress.org/) snippets\n\
+\n\
+snippet [\n\
+ [${1:text}](http://${2:address} \"${3:title}\")\n\
+snippet [*\n\
+ [${1:link}](${2:`@*`} \"${3:title}\")${4}\n\
+\n\
+snippet [:\n\
+ [${1:id}]: http://${2:url} \"${3:title}\"\n\
+snippet [:*\n\
+ [${1:id}]: ${2:`@*`} \"${3:title}\"\n\
+\n\
+snippet ![\n\
+ ![${1:alttext}](${2:/images/image.jpg} \"${3:title}\")\n\
+snippet ![*\n\
+ ![${1:alt}](${2:`@*`} \"${3:title}\")${4}\n\
+\n\
+snippet ![:\n\
+ ![${1:id}]: ${2:url} \"${3:title}\"\n\
+snippet ![:*\n\
+ ![${1:id}]: ${2:`@*`} \"${3:title}\"\n\
+\n\
+snippet ===\n\
+regex /^/=+/=*//\n\
+ ${PREV_LINE/./=/g}\n\
+ \n\
+ ${0}\n\
+snippet ---\n\
+regex /^/-+/-*//\n\
+ ${PREV_LINE/./-/g}\n\
+ \n\
+ ${0}\n\
+snippet blockquote\n\
+ {% blockquote %}\n\
+ ${1:quote}\n\
+ {% endblockquote %}\n\
+\n\
+snippet blockquote-author\n\
+ {% blockquote ${1:author}, ${2:title} %}\n\
+ ${3:quote}\n\
+ {% endblockquote %}\n\
+\n\
+snippet blockquote-link\n\
+ {% blockquote ${1:author} ${2:URL} ${3:link_text} %}\n\
+ ${4:quote}\n\
+ {% endblockquote %}\n\
+\n\
+snippet bt-codeblock-short\n\
+ ```\n\
+ ${1:code_snippet}\n\
+ ```\n\
+\n\
+snippet bt-codeblock-full\n\
+ ``` ${1:language} ${2:title} ${3:URL} ${4:link_text}\n\
+ ${5:code_snippet}\n\
+ ```\n\
+\n\
+snippet codeblock-short\n\
+ {% codeblock %}\n\
+ ${1:code_snippet}\n\
+ {% endcodeblock %}\n\
+\n\
+snippet codeblock-full\n\
+ {% codeblock ${1:title} lang:${2:language} ${3:URL} ${4:link_text} %}\n\
+ ${5:code_snippet}\n\
+ {% endcodeblock %}\n\
+\n\
+snippet gist-full\n\
+ {% gist ${1:gist_id} ${2:filename} %}\n\
+\n\
+snippet gist-short\n\
+ {% gist ${1:gist_id} %}\n\
+\n\
+snippet img\n\
+ {% img ${1:class} ${2:URL} ${3:width} ${4:height} ${5:title_text} ${6:alt_text} %}\n\
+\n\
+snippet youtube\n\
+ {% youtube ${1:video_id} %}\n\
+\n\
+# The quote should appear only once in the text. It is inherently part of it.\n\
+# See http://octopress.org/docs/plugins/pullquote/ for more info.\n\
+\n\
+snippet pullquote\n\
+ {% pullquote %}\n\
+ ${1:text} {\" ${2:quote} \"} ${3:text}\n\
+ {% endpullquote %}\n\
+";
+exports.scope = "markdown";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/mask.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mask.js
new file mode 100644
index 00000000..2811ad2a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mask.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/mask",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "mask";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/matlab.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/matlab.js
new file mode 100644
index 00000000..ce298c3f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/matlab.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/matlab",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "matlab";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/maze.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/maze.js
new file mode 100644
index 00000000..c12d5668
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/maze.js
@@ -0,0 +1,16 @@
+ace.define("ace/snippets/maze",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet >\n\
+description assignment\n\
+scope maze\n\
+ -> ${1}= ${2}\n\
+\n\
+snippet >\n\
+description if\n\
+scope maze\n\
+ -> IF ${2:**} THEN %${3:L} ELSE %${4:R}\n\
+";
+exports.scope = "maze";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/mel.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mel.js
new file mode 100644
index 00000000..537cc25b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mel.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/mel",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "mel";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/mushcode.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mushcode.js
new file mode 100644
index 00000000..1f0fe24e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mushcode.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/mushcode",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "mushcode";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/mysql.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mysql.js
new file mode 100644
index 00000000..bfb3a42c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/mysql.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/mysql",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "mysql";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/nix.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/nix.js
new file mode 100644
index 00000000..4fb6e704
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/nix.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/nix",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "nix";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/nsis.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/nsis.js
new file mode 100644
index 00000000..81b5726d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/nsis.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/nsis",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/objectivec.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/objectivec.js
new file mode 100644
index 00000000..f93e6ae9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/objectivec.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/objectivec",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "objectivec";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/ocaml.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ocaml.js
new file mode 100644
index 00000000..06e0940d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ocaml.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/ocaml",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "ocaml";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/pascal.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/pascal.js
new file mode 100644
index 00000000..70aa2ee7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/pascal.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/pascal",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "pascal";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/perl.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/perl.js
new file mode 100644
index 00000000..9f818432
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/perl.js
@@ -0,0 +1,354 @@
+ace.define("ace/snippets/perl",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# #!/usr/bin/perl\n\
+snippet #!\n\
+ #!/usr/bin/env perl\n\
+\n\
+# Hash Pointer\n\
+snippet .\n\
+ =>\n\
+# Function\n\
+snippet sub\n\
+ sub ${1:function_name} {\n\
+ ${2:#body ...}\n\
+ }\n\
+# Conditional\n\
+snippet if\n\
+ if (${1}) {\n\
+ ${2:# body...}\n\
+ }\n\
+# Conditional if..else\n\
+snippet ife\n\
+ if (${1}) {\n\
+ ${2:# body...}\n\
+ }\n\
+ else {\n\
+ ${3:# else...}\n\
+ }\n\
+# Conditional if..elsif..else\n\
+snippet ifee\n\
+ if (${1}) {\n\
+ ${2:# body...}\n\
+ }\n\
+ elsif (${3}) {\n\
+ ${4:# elsif...}\n\
+ }\n\
+ else {\n\
+ ${5:# else...}\n\
+ }\n\
+# Conditional One-line\n\
+snippet xif\n\
+ ${1:expression} if ${2:condition};${3}\n\
+# Unless conditional\n\
+snippet unless\n\
+ unless (${1}) {\n\
+ ${2:# body...}\n\
+ }\n\
+# Unless conditional One-line\n\
+snippet xunless\n\
+ ${1:expression} unless ${2:condition};${3}\n\
+# Try/Except\n\
+snippet eval\n\
+ local $@;\n\
+ eval {\n\
+ ${1:# do something risky...}\n\
+ };\n\
+ if (my $e = $@) {\n\
+ ${2:# handle failure...}\n\
+ }\n\
+# While Loop\n\
+snippet wh\n\
+ while (${1}) {\n\
+ ${2:# body...}\n\
+ }\n\
+# While Loop One-line\n\
+snippet xwh\n\
+ ${1:expression} while ${2:condition};${3}\n\
+# C-style For Loop\n\
+snippet cfor\n\
+ for (my $${2:var} = 0; $$2 < ${1:count}; $$2${3:++}) {\n\
+ ${4:# body...}\n\
+ }\n\
+# For loop one-line\n\
+snippet xfor\n\
+ ${1:expression} for @${2:array};${3}\n\
+# Foreach Loop\n\
+snippet for\n\
+ foreach my $${1:x} (@${2:array}) {\n\
+ ${3:# body...}\n\
+ }\n\
+# Foreach Loop One-line\n\
+snippet fore\n\
+ ${1:expression} foreach @${2:array};${3}\n\
+# Package\n\
+snippet package\n\
+ package ${1:`substitute(Filename('', 'Page Title'), '^.', '\\u&', '')`};\n\
+\n\
+ ${2}\n\
+\n\
+ 1;\n\
+\n\
+ __END__\n\
+# Package syntax perl >= 5.14\n\
+snippet packagev514\n\
+ package ${1:`substitute(Filename('', 'Page Title'), '^.', '\\u&', '')`} ${2:0.99};\n\
+\n\
+ ${3}\n\
+\n\
+ 1;\n\
+\n\
+ __END__\n\
+#moose\n\
+snippet moose\n\
+ use Moose;\n\
+ use namespace::autoclean;\n\
+ ${1:#}BEGIN {extends '${2:ParentClass}'};\n\
+\n\
+ ${3}\n\
+# parent\n\
+snippet parent\n\
+ use parent qw(${1:Parent Class});\n\
+# Read File\n\
+snippet slurp\n\
+ my $${1:var} = do { local $/; open my $file, '<', \"${2:file}\"; <$file> };\n\
+ ${3}\n\
+# strict warnings\n\
+snippet strwar\n\
+ use strict;\n\
+ use warnings;\n\
+# older versioning with perlcritic bypass\n\
+snippet vers\n\
+ ## no critic\n\
+ our $VERSION = '${1:version}';\n\
+ eval $VERSION;\n\
+ ## use critic\n\
+# new 'switch' like feature\n\
+snippet switch\n\
+ use feature 'switch';\n\
+\n\
+# Anonymous subroutine\n\
+snippet asub\n\
+ sub {\n\
+ ${1:# body }\n\
+ }\n\
+\n\
+\n\
+\n\
+# Begin block\n\
+snippet begin\n\
+ BEGIN {\n\
+ ${1:# begin body}\n\
+ }\n\
+\n\
+# call package function with some parameter\n\
+snippet pkgmv\n\
+ __PACKAGE__->${1:package_method}(${2:var})\n\
+\n\
+# call package function without a parameter\n\
+snippet pkgm\n\
+ __PACKAGE__->${1:package_method}()\n\
+\n\
+# call package \"get_\" function without a parameter\n\
+snippet pkget\n\
+ __PACKAGE__->get_${1:package_method}()\n\
+\n\
+# call package function with a parameter\n\
+snippet pkgetv\n\
+ __PACKAGE__->get_${1:package_method}(${2:var})\n\
+\n\
+# complex regex\n\
+snippet qrx\n\
+ qr/\n\
+ ${1:regex}\n\
+ /xms\n\
+\n\
+#simpler regex\n\
+snippet qr/\n\
+ qr/${1:regex}/x\n\
+\n\
+#given\n\
+snippet given\n\
+ given ($${1:var}) {\n\
+ ${2:# cases}\n\
+ ${3:# default}\n\
+ }\n\
+\n\
+# switch-like case\n\
+snippet when\n\
+ when (${1:case}) {\n\
+ ${2:# body}\n\
+ }\n\
+\n\
+# hash slice\n\
+snippet hslice\n\
+ @{ ${1:hash} }{ ${2:array} }\n\
+\n\
+\n\
+# map\n\
+snippet map\n\
+ map { ${2: body } } ${1: @array } ;\n\
+\n\
+\n\
+\n\
+# Pod stub\n\
+snippet ppod\n\
+ =head1 NAME\n\
+\n\
+ ${1:ClassName} - ${2:ShortDesc}\n\
+\n\
+ =head1 SYNOPSIS\n\
+\n\
+ use $1;\n\
+\n\
+ ${3:# synopsis...}\n\
+\n\
+ =head1 DESCRIPTION\n\
+\n\
+ ${4:# longer description...}\n\
+\n\
+\n\
+ =head1 INTERFACE\n\
+\n\
+\n\
+ =head1 DEPENDENCIES\n\
+\n\
+\n\
+ =head1 SEE ALSO\n\
+\n\
+\n\
+# Heading for a subroutine stub\n\
+snippet psub\n\
+ =head2 ${1:MethodName}\n\
+\n\
+ ${2:Summary....}\n\
+\n\
+# Heading for inline subroutine pod\n\
+snippet psubi\n\
+ =head2 ${1:MethodName}\n\
+\n\
+ ${2:Summary...}\n\
+\n\
+\n\
+ =cut\n\
+# inline documented subroutine\n\
+snippet subpod\n\
+ =head2 $1\n\
+\n\
+ Summary of $1\n\
+\n\
+ =cut\n\
+\n\
+ sub ${1:subroutine_name} {\n\
+ ${2:# body...}\n\
+ }\n\
+# Subroutine signature\n\
+snippet parg\n\
+ =over 2\n\
+\n\
+ =item\n\
+ Arguments\n\
+\n\
+\n\
+ =over 3\n\
+\n\
+ =item\n\
+ C<${1:DataStructure}>\n\
+\n\
+ ${2:Sample}\n\
+\n\
+\n\
+ =back\n\
+\n\
+\n\
+ =item\n\
+ Return\n\
+\n\
+ =over 3\n\
+\n\
+\n\
+ =item\n\
+ C<${3:...return data}>\n\
+\n\
+\n\
+ =back\n\
+\n\
+\n\
+ =back\n\
+\n\
+\n\
+\n\
+# Moose has\n\
+snippet has\n\
+ has ${1:attribute} => (\n\
+ is => '${2:ro|rw}',\n\
+ isa => '${3:Str|Int|HashRef|ArrayRef|etc}',\n\
+ default => sub {\n\
+ ${4:defaultvalue}\n\
+ },\n\
+ ${5:# other attributes}\n\
+ );\n\
+\n\
+\n\
+# override\n\
+snippet override\n\
+ override ${1:attribute} => sub {\n\
+ ${2:# my $self = shift;};\n\
+ ${3:# my ($self, $args) = @_;};\n\
+ };\n\
+\n\
+\n\
+# use test classes\n\
+snippet tuse\n\
+ use Test::More;\n\
+ use Test::Deep; # (); # uncomment to stop prototype errors\n\
+ use Test::Exception;\n\
+\n\
+# local test lib\n\
+snippet tlib\n\
+ use lib qw{ ./t/lib };\n\
+\n\
+#test methods\n\
+snippet tmeths\n\
+ $ENV{TEST_METHOD} = '${1:regex}';\n\
+\n\
+# runtestclass\n\
+snippet trunner\n\
+ use ${1:test_class};\n\
+ $1->runtests();\n\
+\n\
+# Test::Class-style test\n\
+snippet tsub\n\
+ sub t${1:number}_${2:test_case} :Test(${3:num_of_tests}) {\n\
+ my $self = shift;\n\
+ ${4:# body}\n\
+\n\
+ }\n\
+\n\
+# Test::Routine-style test\n\
+snippet trsub\n\
+ test ${1:test_name} => { description => '${2:Description of test.}'} => sub {\n\
+ my ($self) = @_;\n\
+ ${3:# test code}\n\
+ };\n\
+\n\
+#prep test method\n\
+snippet tprep\n\
+ sub prep${1:number}_${2:test_case} :Test(startup) {\n\
+ my $self = shift;\n\
+ ${4:# body}\n\
+ }\n\
+\n\
+# cause failures to print stack trace\n\
+snippet debug_trace\n\
+ use Carp; # 'verbose';\n\
+ # cloak \"die\"\n\
+ # warn \"warning\"\n\
+ $SIG{'__DIE__'} = sub {\n\
+ require Carp; Carp::confess\n\
+ };\n\
+\n\
+";
+exports.scope = "perl";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/pgsql.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/pgsql.js
new file mode 100644
index 00000000..5914fe1d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/pgsql.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/pgsql",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "pgsql";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/php.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/php.js
new file mode 100644
index 00000000..a99ab6e0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/php.js
@@ -0,0 +1,384 @@
+ace.define("ace/snippets/php",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet <?\n\
+ <?php\n\
+\n\
+ ${1}\n\
+snippet ec\n\
+ echo ${1};\n\
+snippet <?e\n\
+ <?php echo ${1} ?>\n\
+# this one is for php5.4\n\
+snippet <?=\n\
+ <?=${1}?>\n\
+snippet ns\n\
+ namespace ${1:Foo\\Bar\\Baz};\n\
+ ${2}\n\
+snippet use\n\
+ use ${1:Foo\\Bar\\Baz};\n\
+ ${2}\n\
+snippet c\n\
+ ${1:abstract }class ${2:$FILENAME}\n\
+ {\n\
+ ${3}\n\
+ }\n\
+snippet i\n\
+ interface ${1:$FILENAME}\n\
+ {\n\
+ ${2}\n\
+ }\n\
+snippet t.\n\
+ $this->${1}\n\
+snippet f\n\
+ function ${1:foo}(${2:array }${3:$bar})\n\
+ {\n\
+ ${4}\n\
+ }\n\
+# method\n\
+snippet m\n\
+ ${1:abstract }${2:protected}${3: static} function ${4:foo}(${5:array }${6:$bar})\n\
+ {\n\
+ ${7}\n\
+ }\n\
+# setter method\n\
+snippet sm \n\
+ /**\n\
+ * Sets the value of ${1:foo}\n\
+ *\n\
+ * @param ${2:$1} $$1 ${3:description}\n\
+ *\n\
+ * @return ${4:$FILENAME}\n\
+ */\n\
+ ${5:public} function set${6:$2}(${7:$2 }$$1)\n\
+ {\n\
+ $this->${8:$1} = $$1;\n\
+ return $this;\n\
+ }${9}\n\
+# getter method\n\
+snippet gm\n\
+ /**\n\
+ * Gets the value of ${1:foo}\n\
+ *\n\
+ * @return ${2:$1}\n\
+ */\n\
+ ${3:public} function get${4:$2}()\n\
+ {\n\
+ return $this->${5:$1};\n\
+ }${6}\n\
+#setter\n\
+snippet $s\n\
+ ${1:$foo}->set${2:Bar}(${3});\n\
+#getter\n\
+snippet $g\n\
+ ${1:$foo}->get${2:Bar}();\n\
+\n\
+# Tertiary conditional\n\
+snippet =?:\n\
+ $${1:foo} = ${2:true} ? ${3:a} : ${4};\n\
+snippet ?:\n\
+ ${1:true} ? ${2:a} : ${3}\n\
+\n\
+snippet C\n\
+ $_COOKIE['${1:variable}']${2}\n\
+snippet E\n\
+ $_ENV['${1:variable}']${2}\n\
+snippet F\n\
+ $_FILES['${1:variable}']${2}\n\
+snippet G\n\
+ $_GET['${1:variable}']${2}\n\
+snippet P\n\
+ $_POST['${1:variable}']${2}\n\
+snippet R\n\
+ $_REQUEST['${1:variable}']${2}\n\
+snippet S\n\
+ $_SERVER['${1:variable}']${2}\n\
+snippet SS\n\
+ $_SESSION['${1:variable}']${2}\n\
+ \n\
+# the following are old ones\n\
+snippet inc\n\
+ include '${1:file}';${2}\n\
+snippet inc1\n\
+ include_once '${1:file}';${2}\n\
+snippet req\n\
+ require '${1:file}';${2}\n\
+snippet req1\n\
+ require_once '${1:file}';${2}\n\
+# Start Docblock\n\
+snippet /*\n\
+ /**\n\
+ * ${1}\n\
+ */\n\
+# Class - post doc\n\
+snippet doc_cp\n\
+ /**\n\
+ * ${1:undocumented class}\n\
+ *\n\
+ * @package ${2:default}\n\
+ * @subpackage ${3:default}\n\
+ * @author ${4:`g:snips_author`}\n\
+ */${5}\n\
+# Class Variable - post doc\n\
+snippet doc_vp\n\
+ /**\n\
+ * ${1:undocumented class variable}\n\
+ *\n\
+ * @var ${2:string}\n\
+ */${3}\n\
+# Class Variable\n\
+snippet doc_v\n\
+ /**\n\
+ * ${3:undocumented class variable}\n\
+ *\n\
+ * @var ${4:string}\n\
+ */\n\
+ ${1:var} $${2};${5}\n\
+# Class\n\
+snippet doc_c\n\
+ /**\n\
+ * ${3:undocumented class}\n\
+ *\n\
+ * @package ${4:default}\n\
+ * @subpackage ${5:default}\n\
+ * @author ${6:`g:snips_author`}\n\
+ */\n\
+ ${1:}class ${2:}\n\
+ {\n\
+ ${7}\n\
+ } // END $1class $2\n\
+# Constant Definition - post doc\n\
+snippet doc_dp\n\
+ /**\n\
+ * ${1:undocumented constant}\n\
+ */${2}\n\
+# Constant Definition\n\
+snippet doc_d\n\
+ /**\n\
+ * ${3:undocumented constant}\n\
+ */\n\
+ define(${1}, ${2});${4}\n\
+# Function - post doc\n\
+snippet doc_fp\n\
+ /**\n\
+ * ${1:undocumented function}\n\
+ *\n\
+ * @return ${2:void}\n\
+ * @author ${3:`g:snips_author`}\n\
+ */${4}\n\
+# Function signature\n\
+snippet doc_s\n\
+ /**\n\
+ * ${4:undocumented function}\n\
+ *\n\
+ * @return ${5:void}\n\
+ * @author ${6:`g:snips_author`}\n\
+ */\n\
+ ${1}function ${2}(${3});${7}\n\
+# Function\n\
+snippet doc_f\n\
+ /**\n\
+ * ${4:undocumented function}\n\
+ *\n\
+ * @return ${5:void}\n\
+ * @author ${6:`g:snips_author`}\n\
+ */\n\
+ ${1}function ${2}(${3})\n\
+ {${7}\n\
+ }\n\
+# Header\n\
+snippet doc_h\n\
+ /**\n\
+ * ${1}\n\
+ *\n\
+ * @author ${2:`g:snips_author`}\n\
+ * @version ${3:$Id$}\n\
+ * @copyright ${4:$2}, `strftime('%d %B, %Y')`\n\
+ * @package ${5:default}\n\
+ */\n\
+ \n\
+# Interface\n\
+snippet interface\n\
+ /**\n\
+ * ${2:undocumented class}\n\
+ *\n\
+ * @package ${3:default}\n\
+ * @author ${4:`g:snips_author`}\n\
+ */\n\
+ interface ${1:$FILENAME}\n\
+ {\n\
+ ${5}\n\
+ }\n\
+# class ...\n\
+snippet class\n\
+ /**\n\
+ * ${1}\n\
+ */\n\
+ class ${2:$FILENAME}\n\
+ {\n\
+ ${3}\n\
+ /**\n\
+ * ${4}\n\
+ */\n\
+ ${5:public} function ${6:__construct}(${7:argument})\n\
+ {\n\
+ ${8:// code...}\n\
+ }\n\
+ }\n\
+# define(...)\n\
+snippet def\n\
+ define('${1}'${2});${3}\n\
+# defined(...)\n\
+snippet def?\n\
+ ${1}defined('${2}')${3}\n\
+snippet wh\n\
+ while (${1:/* condition */}) {\n\
+ ${2:// code...}\n\
+ }\n\
+# do ... while\n\
+snippet do\n\
+ do {\n\
+ ${2:// code... }\n\
+ } while (${1:/* condition */});\n\
+snippet if\n\
+ if (${1:/* condition */}) {\n\
+ ${2:// code...}\n\
+ }\n\
+snippet ifil\n\
+ <?php if (${1:/* condition */}): ?>\n\
+ ${2:<!-- code... -->}\n\
+ <?php endif; ?>\n\
+snippet ife\n\
+ if (${1:/* condition */}) {\n\
+ ${2:// code...}\n\
+ } else {\n\
+ ${3:// code...}\n\
+ }\n\
+ ${4}\n\
+snippet ifeil\n\
+ <?php if (${1:/* condition */}): ?>\n\
+ ${2:<!-- html... -->}\n\
+ <?php else: ?>\n\
+ ${3:<!-- html... -->}\n\
+ <?php endif; ?>\n\
+ ${4}\n\
+snippet else\n\
+ else {\n\
+ ${1:// code...}\n\
+ }\n\
+snippet elseif\n\
+ elseif (${1:/* condition */}) {\n\
+ ${2:// code...}\n\
+ }\n\
+snippet switch\n\
+ switch ($${1:variable}) {\n\
+ case '${2:value}':\n\
+ ${3:// code...}\n\
+ break;\n\
+ ${5}\n\
+ default:\n\
+ ${4:// code...}\n\
+ break;\n\
+ }\n\
+snippet case\n\
+ case '${1:value}':\n\
+ ${2:// code...}\n\
+ break;${3}\n\
+snippet for\n\
+ for ($${2:i} = 0; $$2 < ${1:count}; $$2${3:++}) {\n\
+ ${4: // code...}\n\
+ }\n\
+snippet foreach\n\
+ foreach ($${1:variable} as $${2:value}) {\n\
+ ${3:// code...}\n\
+ }\n\
+snippet foreachil\n\
+ <?php foreach ($${1:variable} as $${2:value}): ?>\n\
+ ${3:<!-- html... -->}\n\
+ <?php endforeach; ?>\n\
+snippet foreachk\n\
+ foreach ($${1:variable} as $${2:key} => $${3:value}) {\n\
+ ${4:// code...}\n\
+ }\n\
+snippet foreachkil\n\
+ <?php foreach ($${1:variable} as $${2:key} => $${3:value}): ?>\n\
+ ${4:<!-- html... -->}\n\
+ <?php endforeach; ?>\n\
+# $... = array (...)\n\
+snippet array\n\
+ $${1:arrayName} = array('${2}' => ${3});${4}\n\
+snippet try\n\
+ try {\n\
+ ${2}\n\
+ } catch (${1:Exception} $e) {\n\
+ }\n\
+# lambda with closure\n\
+snippet lambda\n\
+ ${1:static }function (${2:args}) use (${3:&$x, $y /*put vars in scope (closure) */}) {\n\
+ ${4}\n\
+ };\n\
+# pre_dump();\n\
+snippet pd\n\
+ echo '<pre>'; var_dump(${1}); echo '</pre>';\n\
+# pre_dump(); die();\n\
+snippet pdd\n\
+ echo '<pre>'; var_dump(${1}); echo '</pre>'; die(${2:});\n\
+snippet vd\n\
+ var_dump(${1});\n\
+snippet vdd\n\
+ var_dump(${1}); die(${2:});\n\
+snippet http_redirect\n\
+ header (\"HTTP/1.1 301 Moved Permanently\"); \n\
+ header (\"Location: \".URL); \n\
+ exit();\n\
+# Getters & Setters\n\
+snippet gs\n\
+ /**\n\
+ * Gets the value of ${1:foo}\n\
+ *\n\
+ * @return ${2:$1}\n\
+ */\n\
+ public function get${3:$2}()\n\
+ {\n\
+ return $this->${4:$1};\n\
+ }\n\
+\n\
+ /**\n\
+ * Sets the value of $1\n\
+ *\n\
+ * @param $2 $$1 ${5:description}\n\
+ *\n\
+ * @return ${6:$FILENAME}\n\
+ */\n\
+ public function set$3(${7:$2 }$$1)\n\
+ {\n\
+ $this->$4 = $$1;\n\
+ return $this;\n\
+ }${8}\n\
+# anotation, get, and set, useful for doctrine\n\
+snippet ags\n\
+ /**\n\
+ * ${1:description}\n\
+ * \n\
+ * @${7}\n\
+ */\n\
+ ${2:protected} $${3:foo};\n\
+\n\
+ public function get${4:$3}()\n\
+ {\n\
+ return $this->$3;\n\
+ }\n\
+\n\
+ public function set$4(${5:$4 }$${6:$3})\n\
+ {\n\
+ $this->$3 = $$6;\n\
+ return $this;\n\
+ }\n\
+snippet rett\n\
+ return true;\n\
+snippet retf\n\
+ return false;\n\
+";
+exports.scope = "php";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/pig.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/pig.js
new file mode 100644
index 00000000..479a03bc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/pig.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/pig",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "pig";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/plain_text.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/plain_text.js
new file mode 100644
index 00000000..24223a66
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/plain_text.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/plain_text",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "plain_text";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/powershell.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/powershell.js
new file mode 100644
index 00000000..a8e7310a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/powershell.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/powershell",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "powershell";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/praat.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/praat.js
new file mode 100644
index 00000000..dcf68267
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/praat.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/praat",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "praat";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/prolog.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/prolog.js
new file mode 100644
index 00000000..2d63cb83
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/prolog.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/prolog",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "prolog";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/properties.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/properties.js
new file mode 100644
index 00000000..44c1ada7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/properties.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/properties",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "properties";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/protobuf.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/protobuf.js
new file mode 100644
index 00000000..d00d57af
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/protobuf.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/protobuf",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "";
+exports.scope = "protobuf";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/python.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/python.js
new file mode 100644
index 00000000..182b3406
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/python.js
@@ -0,0 +1,165 @@
+ace.define("ace/snippets/python",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet #!\n\
+ #!/usr/bin/env python\n\
+snippet imp\n\
+ import ${1:module}\n\
+snippet from\n\
+ from ${1:package} import ${2:module}\n\
+# Module Docstring\n\
+snippet docs\n\
+ '''\n\
+ File: ${1:FILENAME:file_name}\n\
+ Author: ${2:author}\n\
+ Description: ${3}\n\
+ '''\n\
+snippet wh\n\
+ while ${1:condition}:\n\
+ ${2:# TODO: write code...}\n\
+# dowh - does the same as do...while in other languages\n\
+snippet dowh\n\
+ while True:\n\
+ ${1:# TODO: write code...}\n\
+ if ${2:condition}:\n\
+ break\n\
+snippet with\n\
+ with ${1:expr} as ${2:var}:\n\
+ ${3:# TODO: write code...}\n\
+# New Class\n\
+snippet cl\n\
+ class ${1:ClassName}(${2:object}):\n\
+ \"\"\"${3:docstring for $1}\"\"\"\n\
+ def __init__(self, ${4:arg}):\n\
+ ${5:super($1, self).__init__()}\n\
+ self.$4 = $4\n\
+ ${6}\n\
+# New Function\n\
+snippet def\n\
+ def ${1:fname}(${2:`indent('.') ? 'self' : ''`}):\n\
+ \"\"\"${3:docstring for $1}\"\"\"\n\
+ ${4:# TODO: write code...}\n\
+snippet deff\n\
+ def ${1:fname}(${2:`indent('.') ? 'self' : ''`}):\n\
+ ${3:# TODO: write code...}\n\
+# New Method\n\
+snippet defs\n\
+ def ${1:mname}(self, ${2:arg}):\n\
+ ${3:# TODO: write code...}\n\
+# New Property\n\
+snippet property\n\
+ def ${1:foo}():\n\
+ doc = \"${2:The $1 property.}\"\n\
+ def fget(self):\n\
+ ${3:return self._$1}\n\
+ def fset(self, value):\n\
+ ${4:self._$1 = value}\n\
+# Ifs\n\
+snippet if\n\
+ if ${1:condition}:\n\
+ ${2:# TODO: write code...}\n\
+snippet el\n\
+ else:\n\
+ ${1:# TODO: write code...}\n\
+snippet ei\n\
+ elif ${1:condition}:\n\
+ ${2:# TODO: write code...}\n\
+# For\n\
+snippet for\n\
+ for ${1:item} in ${2:items}:\n\
+ ${3:# TODO: write code...}\n\
+# Encodes\n\
+snippet cutf8\n\
+ # -*- coding: utf-8 -*-\n\
+snippet clatin1\n\
+ # -*- coding: latin-1 -*-\n\
+snippet cascii\n\
+ # -*- coding: ascii -*-\n\
+# Lambda\n\
+snippet ld\n\
+ ${1:var} = lambda ${2:vars} : ${3:action}\n\
+snippet .\n\
+ self.\n\
+snippet try Try/Except\n\
+ try:\n\
+ ${1:# TODO: write code...}\n\
+ except ${2:Exception}, ${3:e}:\n\
+ ${4:raise $3}\n\
+snippet try Try/Except/Else\n\
+ try:\n\
+ ${1:# TODO: write code...}\n\
+ except ${2:Exception}, ${3:e}:\n\
+ ${4:raise $3}\n\
+ else:\n\
+ ${5:# TODO: write code...}\n\
+snippet try Try/Except/Finally\n\
+ try:\n\
+ ${1:# TODO: write code...}\n\
+ except ${2:Exception}, ${3:e}:\n\
+ ${4:raise $3}\n\
+ finally:\n\
+ ${5:# TODO: write code...}\n\
+snippet try Try/Except/Else/Finally\n\
+ try:\n\
+ ${1:# TODO: write code...}\n\
+ except ${2:Exception}, ${3:e}:\n\
+ ${4:raise $3}\n\
+ else:\n\
+ ${5:# TODO: write code...}\n\
+ finally:\n\
+ ${6:# TODO: write code...}\n\
+# if __name__ == '__main__':\n\
+snippet ifmain\n\
+ if __name__ == '__main__':\n\
+ ${1:main()}\n\
+# __magic__\n\
+snippet _\n\
+ __${1:init}__${2}\n\
+# python debugger (pdb)\n\
+snippet pdb\n\
+ import pdb; pdb.set_trace()\n\
+# ipython debugger (ipdb)\n\
+snippet ipdb\n\
+ import ipdb; ipdb.set_trace()\n\
+# ipython debugger (pdbbb)\n\
+snippet pdbbb\n\
+ import pdbpp; pdbpp.set_trace()\n\
+snippet pprint\n\
+ import pprint; pprint.pprint(${1})${2}\n\
+snippet \"\n\
+ \"\"\"\n\
+ ${1:doc}\n\
+ \"\"\"\n\
+# test function/method\n\
+snippet test\n\
+ def test_${1:description}(${2:self}):\n\
+ ${3:# TODO: write code...}\n\
+# test case\n\
+snippet testcase\n\
+ class ${1:ExampleCase}(unittest.TestCase):\n\
+ \n\
+ def test_${2:description}(self):\n\
+ ${3:# TODO: write code...}\n\
+snippet fut\n\
+ from __future__ import ${1}\n\
+#getopt\n\
+snippet getopt\n\
+ try:\n\
+ # Short option syntax: \"hv:\"\n\
+ # Long option syntax: \"help\" or \"verbose=\"\n\
+ opts, args = getopt.getopt(sys.argv[1:], \"${1:short_options}\", [${2:long_options}])\n\
+ \n\
+ except getopt.GetoptError, err:\n\
+ # Print debug info\n\
+ print str(err)\n\
+ ${3:error_action}\n\
+\n\
+ for option, argument in opts:\n\
+ if option in (\"-h\", \"--help\"):\n\
+ ${4}\n\
+ elif option in (\"-v\", \"--verbose\"):\n\
+ verbose = argument\n\
+";
+exports.scope = "python";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/r.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/r.js
new file mode 100644
index 00000000..24c02a0c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/r.js
@@ -0,0 +1,128 @@
+ace.define("ace/snippets/r",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet #!\n\
+ #!/usr/bin/env Rscript\n\
+\n\
+# includes\n\
+snippet lib\n\
+ library(${1:package})\n\
+snippet req\n\
+ require(${1:package})\n\
+snippet source\n\
+ source('${1:file}')\n\
+\n\
+# conditionals\n\
+snippet if\n\
+ if (${1:condition}) {\n\
+ ${2:code}\n\
+ }\n\
+snippet el\n\
+ else {\n\
+ ${1:code}\n\
+ }\n\
+snippet ei\n\
+ else if (${1:condition}) {\n\
+ ${2:code}\n\
+ }\n\
+\n\
+# functions\n\
+snippet fun\n\
+ ${1:name} = function (${2:variables}) {\n\
+ ${3:code}\n\
+ }\n\
+snippet ret\n\
+ return(${1:code})\n\
+\n\
+# dataframes, lists, etc\n\
+snippet df\n\
+ ${1:name}[${2:rows}, ${3:cols}]\n\
+snippet c\n\
+ c(${1:items})\n\
+snippet li\n\
+ list(${1:items})\n\
+snippet mat\n\
+ matrix(${1:data}, nrow=${2:rows}, ncol=${3:cols})\n\
+\n\
+# apply functions\n\
+snippet apply\n\
+ apply(${1:array}, ${2:margin}, ${3:function})\n\
+snippet lapply\n\
+ lapply(${1:list}, ${2:function})\n\
+snippet sapply\n\
+ sapply(${1:list}, ${2:function})\n\
+snippet vapply\n\
+ vapply(${1:list}, ${2:function}, ${3:type})\n\
+snippet mapply\n\
+ mapply(${1:function}, ${2:...})\n\
+snippet tapply\n\
+ tapply(${1:vector}, ${2:index}, ${3:function})\n\
+snippet rapply\n\
+ rapply(${1:list}, ${2:function})\n\
+\n\
+# plyr functions\n\
+snippet dd\n\
+ ddply(${1:frame}, ${2:variables}, ${3:function})\n\
+snippet dl\n\
+ dlply(${1:frame}, ${2:variables}, ${3:function})\n\
+snippet da\n\
+ daply(${1:frame}, ${2:variables}, ${3:function})\n\
+snippet d_\n\
+ d_ply(${1:frame}, ${2:variables}, ${3:function})\n\
+\n\
+snippet ad\n\
+ adply(${1:array}, ${2:margin}, ${3:function})\n\
+snippet al\n\
+ alply(${1:array}, ${2:margin}, ${3:function})\n\
+snippet aa\n\
+ aaply(${1:array}, ${2:margin}, ${3:function})\n\
+snippet a_\n\
+ a_ply(${1:array}, ${2:margin}, ${3:function})\n\
+\n\
+snippet ld\n\
+ ldply(${1:list}, ${2:function})\n\
+snippet ll\n\
+ llply(${1:list}, ${2:function})\n\
+snippet la\n\
+ laply(${1:list}, ${2:function})\n\
+snippet l_\n\
+ l_ply(${1:list}, ${2:function})\n\
+\n\
+snippet md\n\
+ mdply(${1:matrix}, ${2:function})\n\
+snippet ml\n\
+ mlply(${1:matrix}, ${2:function})\n\
+snippet ma\n\
+ maply(${1:matrix}, ${2:function})\n\
+snippet m_\n\
+ m_ply(${1:matrix}, ${2:function})\n\
+\n\
+# plot functions\n\
+snippet pl\n\
+ plot(${1:x}, ${2:y})\n\
+snippet ggp\n\
+ ggplot(${1:data}, aes(${2:aesthetics}))\n\
+snippet img\n\
+ ${1:(jpeg,bmp,png,tiff)}(filename=\"${2:filename}\", width=${3}, height=${4}, unit=\"${5}\")\n\
+ ${6:plot}\n\
+ dev.off()\n\
+\n\
+# statistical test functions\n\
+snippet fis\n\
+ fisher.test(${1:x}, ${2:y})\n\
+snippet chi\n\
+ chisq.test(${1:x}, ${2:y})\n\
+snippet tt\n\
+ t.test(${1:x}, ${2:y})\n\
+snippet wil\n\
+ wilcox.test(${1:x}, ${2:y})\n\
+snippet cor\n\
+ cor.test(${1:x}, ${2:y})\n\
+snippet fte\n\
+ var.test(${1:x}, ${2:y})\n\
+snippet kvt \n\
+ kv.test(${1:x}, ${2:y})\n\
+";
+exports.scope = "r";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/razor.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/razor.js
new file mode 100644
index 00000000..78fdf8c3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/razor.js
@@ -0,0 +1,10 @@
+ace.define("ace/snippets/razor",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet if\n\
+(${1} == ${2}) {\n\
+ ${3}\n\
+}";
+exports.scope = "razor";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/rdoc.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rdoc.js
new file mode 100644
index 00000000..956de47a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rdoc.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/rdoc",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "rdoc";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/rhtml.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rhtml.js
new file mode 100644
index 00000000..e62ce87f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rhtml.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/rhtml",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "rhtml";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/rst.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rst.js
new file mode 100644
index 00000000..db6c960f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rst.js
@@ -0,0 +1,29 @@
+ace.define("ace/snippets/rst",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# rst\n\
+\n\
+snippet :\n\
+ :${1:field name}: ${2:field body}\n\
+snippet *\n\
+ *${1:Emphasis}*\n\
+snippet **\n\
+ **${1:Strong emphasis}**\n\
+snippet _\n\
+ \\`${1:hyperlink-name}\\`_\n\
+ .. _\\`$1\\`: ${2:link-block}\n\
+snippet =\n\
+ ${1:Title}\n\
+ =====${2:=}\n\
+ ${3}\n\
+snippet -\n\
+ ${1:Title}\n\
+ -----${2:-}\n\
+ ${3}\n\
+snippet cont:\n\
+ .. contents::\n\
+ \n\
+";
+exports.scope = "rst";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/ruby.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ruby.js
new file mode 100644
index 00000000..18bc409f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/ruby.js
@@ -0,0 +1,935 @@
+ace.define("ace/snippets/ruby",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "########################################\n\
+# Ruby snippets - for Rails, see below #\n\
+########################################\n\
+\n\
+# encoding for Ruby 1.9\n\
+snippet enc\n\
+ # encoding: utf-8\n\
+\n\
+# #!/usr/bin/env ruby\n\
+snippet #!\n\
+ #!/usr/bin/env ruby\n\
+ # encoding: utf-8\n\
+\n\
+# New Block\n\
+snippet =b\n\
+ =begin rdoc\n\
+ ${1}\n\
+ =end\n\
+snippet y\n\
+ :yields: ${1:arguments}\n\
+snippet rb\n\
+ #!/usr/bin/env ruby -wKU\n\
+snippet beg\n\
+ begin\n\
+ ${3}\n\
+ rescue ${1:Exception} => ${2:e}\n\
+ end\n\
+\n\
+snippet req require\n\
+ require \"${1}\"${2}\n\
+snippet #\n\
+ # =>\n\
+snippet end\n\
+ __END__\n\
+snippet case\n\
+ case ${1:object}\n\
+ when ${2:condition}\n\
+ ${3}\n\
+ end\n\
+snippet when\n\
+ when ${1:condition}\n\
+ ${2}\n\
+snippet def\n\
+ def ${1:method_name}\n\
+ ${2}\n\
+ end\n\
+snippet deft\n\
+ def test_${1:case_name}\n\
+ ${2}\n\
+ end\n\
+snippet if\n\
+ if ${1:condition}\n\
+ ${2}\n\
+ end\n\
+snippet ife\n\
+ if ${1:condition}\n\
+ ${2}\n\
+ else\n\
+ ${3}\n\
+ end\n\
+snippet elsif\n\
+ elsif ${1:condition}\n\
+ ${2}\n\
+snippet unless\n\
+ unless ${1:condition}\n\
+ ${2}\n\
+ end\n\
+snippet while\n\
+ while ${1:condition}\n\
+ ${2}\n\
+ end\n\
+snippet for\n\
+ for ${1:e} in ${2:c}\n\
+ ${3}\n\
+ end\n\
+snippet until\n\
+ until ${1:condition}\n\
+ ${2}\n\
+ end\n\
+snippet cla class .. end\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ ${2}\n\
+ end\n\
+snippet cla class .. initialize .. end\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ def initialize(${2:args})\n\
+ ${3}\n\
+ end\n\
+ end\n\
+snippet cla class .. < ParentClass .. initialize .. end\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`} < ${2:ParentClass}\n\
+ def initialize(${3:args})\n\
+ ${4}\n\
+ end\n\
+ end\n\
+snippet cla ClassName = Struct .. do .. end\n\
+ ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`} = Struct.new(:${2:attr_names}) do\n\
+ def ${3:method_name}\n\
+ ${4}\n\
+ end\n\
+ end\n\
+snippet cla class BlankSlate .. initialize .. end\n\
+ class ${1:BlankSlate}\n\
+ instance_methods.each { |meth| undef_method(meth) unless meth =~ /\\A__/ }\n\
+ end\n\
+snippet cla class << self .. end\n\
+ class << ${1:self}\n\
+ ${2}\n\
+ end\n\
+# class .. < DelegateClass .. initialize .. end\n\
+snippet cla-\n\
+ class ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`} < DelegateClass(${2:ParentClass})\n\
+ def initialize(${3:args})\n\
+ super(${4:del_obj})\n\
+\n\
+ ${5}\n\
+ end\n\
+ end\n\
+snippet mod module .. end\n\
+ module ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ ${2}\n\
+ end\n\
+snippet mod module .. module_function .. end\n\
+ module ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ module_function\n\
+\n\
+ ${2}\n\
+ end\n\
+snippet mod module .. ClassMethods .. end\n\
+ module ${1:`substitute(Filename(), '\\(_\\|^\\)\\(.\\)', '\\u\\2', 'g')`}\n\
+ module ClassMethods\n\
+ ${2}\n\
+ end\n\
+\n\
+ module InstanceMethods\n\
+\n\
+ end\n\
+\n\
+ def self.included(receiver)\n\
+ receiver.extend ClassMethods\n\
+ receiver.send :include, InstanceMethods\n\
+ end\n\
+ end\n\
+# attr_reader\n\
+snippet r\n\
+ attr_reader :${1:attr_names}\n\
+# attr_writer\n\
+snippet w\n\
+ attr_writer :${1:attr_names}\n\
+# attr_accessor\n\
+snippet rw\n\
+ attr_accessor :${1:attr_names}\n\
+snippet atp\n\
+ attr_protected :${1:attr_names}\n\
+snippet ata\n\
+ attr_accessible :${1:attr_names}\n\
+# include Enumerable\n\
+snippet Enum\n\
+ include Enumerable\n\
+\n\
+ def each(&block)\n\
+ ${1}\n\
+ end\n\
+# include Comparable\n\
+snippet Comp\n\
+ include Comparable\n\
+\n\
+ def <=>(other)\n\
+ ${1}\n\
+ end\n\
+# extend Forwardable\n\
+snippet Forw-\n\
+ extend Forwardable\n\
+# def self\n\
+snippet defs\n\
+ def self.${1:class_method_name}\n\
+ ${2}\n\
+ end\n\
+# def method_missing\n\
+snippet defmm\n\
+ def method_missing(meth, *args, &blk)\n\
+ ${1}\n\
+ end\n\
+snippet defd\n\
+ def_delegator :${1:@del_obj}, :${2:del_meth}, :${3:new_name}\n\
+snippet defds\n\
+ def_delegators :${1:@del_obj}, :${2:del_methods}\n\
+snippet am\n\
+ alias_method :${1:new_name}, :${2:old_name}\n\
+snippet app\n\
+ if __FILE__ == $PROGRAM_NAME\n\
+ ${1}\n\
+ end\n\
+# usage_if()\n\
+snippet usai\n\
+ if ARGV.${1}\n\
+ abort \"Usage: #{$PROGRAM_NAME} ${2:ARGS_GO_HERE}\"${3}\n\
+ end\n\
+# usage_unless()\n\
+snippet usau\n\
+ unless ARGV.${1}\n\
+ abort \"Usage: #{$PROGRAM_NAME} ${2:ARGS_GO_HERE}\"${3}\n\
+ end\n\
+snippet array\n\
+ Array.new(${1:10}) { |${2:i}| ${3} }\n\
+snippet hash\n\
+ Hash.new { |${1:hash}, ${2:key}| $1[$2] = ${3} }\n\
+snippet file File.foreach() { |line| .. }\n\
+ File.foreach(${1:\"path/to/file\"}) { |${2:line}| ${3} }\n\
+snippet file File.read()\n\
+ File.read(${1:\"path/to/file\"})${2}\n\
+snippet Dir Dir.global() { |file| .. }\n\
+ Dir.glob(${1:\"dir/glob/*\"}) { |${2:file}| ${3} }\n\
+snippet Dir Dir[\"..\"]\n\
+ Dir[${1:\"glob/**/*.rb\"}]${2}\n\
+snippet dir\n\
+ Filename.dirname(__FILE__)\n\
+snippet deli\n\
+ delete_if { |${1:e}| ${2} }\n\
+snippet fil\n\
+ fill(${1:range}) { |${2:i}| ${3} }\n\
+# flatten_once()\n\
+snippet flao\n\
+ inject(Array.new) { |${1:arr}, ${2:a}| $1.push(*$2)}${3}\n\
+snippet zip\n\
+ zip(${1:enums}) { |${2:row}| ${3} }\n\
+# downto(0) { |n| .. }\n\
+snippet dow\n\
+ downto(${1:0}) { |${2:n}| ${3} }\n\
+snippet ste\n\
+ step(${1:2}) { |${2:n}| ${3} }\n\
+snippet tim\n\
+ times { |${1:n}| ${2} }\n\
+snippet upt\n\
+ upto(${1:1.0/0.0}) { |${2:n}| ${3} }\n\
+snippet loo\n\
+ loop { ${1} }\n\
+snippet ea\n\
+ each { |${1:e}| ${2} }\n\
+snippet ead\n\
+ each do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet eab\n\
+ each_byte { |${1:byte}| ${2} }\n\
+snippet eac- each_char { |chr| .. }\n\
+ each_char { |${1:chr}| ${2} }\n\
+snippet eac- each_cons(..) { |group| .. }\n\
+ each_cons(${1:2}) { |${2:group}| ${3} }\n\
+snippet eai\n\
+ each_index { |${1:i}| ${2} }\n\
+snippet eaid\n\
+ each_index do |${1:i}|\n\
+ ${2}\n\
+ end\n\
+snippet eak\n\
+ each_key { |${1:key}| ${2} }\n\
+snippet eakd\n\
+ each_key do |${1:key}|\n\
+ ${2}\n\
+ end\n\
+snippet eal\n\
+ each_line { |${1:line}| ${2} }\n\
+snippet eald\n\
+ each_line do |${1:line}|\n\
+ ${2}\n\
+ end\n\
+snippet eap\n\
+ each_pair { |${1:name}, ${2:val}| ${3} }\n\
+snippet eapd\n\
+ each_pair do |${1:name}, ${2:val}|\n\
+ ${3}\n\
+ end\n\
+snippet eas-\n\
+ each_slice(${1:2}) { |${2:group}| ${3} }\n\
+snippet easd-\n\
+ each_slice(${1:2}) do |${2:group}|\n\
+ ${3}\n\
+ end\n\
+snippet eav\n\
+ each_value { |${1:val}| ${2} }\n\
+snippet eavd\n\
+ each_value do |${1:val}|\n\
+ ${2}\n\
+ end\n\
+snippet eawi\n\
+ each_with_index { |${1:e}, ${2:i}| ${3} }\n\
+snippet eawid\n\
+ each_with_index do |${1:e},${2:i}|\n\
+ ${3}\n\
+ end\n\
+snippet reve\n\
+ reverse_each { |${1:e}| ${2} }\n\
+snippet reved\n\
+ reverse_each do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet inj\n\
+ inject(${1:init}) { |${2:mem}, ${3:var}| ${4} }\n\
+snippet injd\n\
+ inject(${1:init}) do |${2:mem}, ${3:var}|\n\
+ ${4}\n\
+ end\n\
+snippet map\n\
+ map { |${1:e}| ${2} }\n\
+snippet mapd\n\
+ map do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet mapwi-\n\
+ enum_with_index.map { |${1:e}, ${2:i}| ${3} }\n\
+snippet sor\n\
+ sort { |a, b| ${1} }\n\
+snippet sorb\n\
+ sort_by { |${1:e}| ${2} }\n\
+snippet ran\n\
+ sort_by { rand }\n\
+snippet all\n\
+ all? { |${1:e}| ${2} }\n\
+snippet any\n\
+ any? { |${1:e}| ${2} }\n\
+snippet cl\n\
+ classify { |${1:e}| ${2} }\n\
+snippet col\n\
+ collect { |${1:e}| ${2} }\n\
+snippet cold\n\
+ collect do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet det\n\
+ detect { |${1:e}| ${2} }\n\
+snippet detd\n\
+ detect do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet fet\n\
+ fetch(${1:name}) { |${2:key}| ${3} }\n\
+snippet fin\n\
+ find { |${1:e}| ${2} }\n\
+snippet find\n\
+ find do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet fina\n\
+ find_all { |${1:e}| ${2} }\n\
+snippet finad\n\
+ find_all do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet gre\n\
+ grep(${1:/pattern/}) { |${2:match}| ${3} }\n\
+snippet sub\n\
+ ${1:g}sub(${2:/pattern/}) { |${3:match}| ${4} }\n\
+snippet sca\n\
+ scan(${1:/pattern/}) { |${2:match}| ${3} }\n\
+snippet scad\n\
+ scan(${1:/pattern/}) do |${2:match}|\n\
+ ${3}\n\
+ end\n\
+snippet max\n\
+ max { |a, b| ${1} }\n\
+snippet min\n\
+ min { |a, b| ${1} }\n\
+snippet par\n\
+ partition { |${1:e}| ${2} }\n\
+snippet pard\n\
+ partition do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet rej\n\
+ reject { |${1:e}| ${2} }\n\
+snippet rejd\n\
+ reject do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet sel\n\
+ select { |${1:e}| ${2} }\n\
+snippet seld\n\
+ select do |${1:e}|\n\
+ ${2}\n\
+ end\n\
+snippet lam\n\
+ lambda { |${1:args}| ${2} }\n\
+snippet doo\n\
+ do\n\
+ ${1}\n\
+ end\n\
+snippet dov\n\
+ do |${1:variable}|\n\
+ ${2}\n\
+ end\n\
+snippet :\n\
+ :${1:key} => ${2:\"value\"}${3}\n\
+snippet ope\n\
+ open(${1:\"path/or/url/or/pipe\"}, \"${2:w}\") { |${3:io}| ${4} }\n\
+# path_from_here()\n\
+snippet fpath\n\
+ File.join(File.dirname(__FILE__), *%2[${1:rel path here}])${2}\n\
+# unix_filter {}\n\
+snippet unif\n\
+ ARGF.each_line${1} do |${2:line}|\n\
+ ${3}\n\
+ end\n\
+# option_parse {}\n\
+snippet optp\n\
+ require \"optparse\"\n\
+\n\
+ options = {${1:default => \"args\"}}\n\
+\n\
+ ARGV.options do |opts|\n\
+ opts.banner = \"Usage: #{File.basename($PROGRAM_NAME)}\n\
+snippet opt\n\
+ opts.on( \"-${1:o}\", \"--${2:long-option-name}\", ${3:String},\n\
+ \"${4:Option description.}\") do |${5:opt}|\n\
+ ${6}\n\
+ end\n\
+snippet tc\n\
+ require \"test/unit\"\n\
+\n\
+ require \"${1:library_file_name}\"\n\
+\n\
+ class Test${2:$1} < Test::Unit::TestCase\n\
+ def test_${3:case_name}\n\
+ ${4}\n\
+ end\n\
+ end\n\
+snippet ts\n\
+ require \"test/unit\"\n\
+\n\
+ require \"tc_${1:test_case_file}\"\n\
+ require \"tc_${2:test_case_file}\"${3}\n\
+snippet as\n\
+ assert ${1:test}, \"${2:Failure message.}\"${3}\n\
+snippet ase\n\
+ assert_equal ${1:expected}, ${2:actual}${3}\n\
+snippet asne\n\
+ assert_not_equal ${1:unexpected}, ${2:actual}${3}\n\
+snippet asid\n\
+ assert_in_delta ${1:expected_float}, ${2:actual_float}, ${3:2 ** -20}${4}\n\
+snippet asio\n\
+ assert_instance_of ${1:ExpectedClass}, ${2:actual_instance}${3}\n\
+snippet asko\n\
+ assert_kind_of ${1:ExpectedKind}, ${2:actual_instance}${3}\n\
+snippet asn\n\
+ assert_nil ${1:instance}${2}\n\
+snippet asnn\n\
+ assert_not_nil ${1:instance}${2}\n\
+snippet asm\n\
+ assert_match /${1:expected_pattern}/, ${2:actual_string}${3}\n\
+snippet asnm\n\
+ assert_no_match /${1:unexpected_pattern}/, ${2:actual_string}${3}\n\
+snippet aso\n\
+ assert_operator ${1:left}, :${2:operator}, ${3:right}${4}\n\
+snippet asr\n\
+ assert_raise ${1:Exception} { ${2} }\n\
+snippet asrd\n\
+ assert_raise ${1:Exception} do\n\
+ ${2}\n\
+ end\n\
+snippet asnr\n\
+ assert_nothing_raised ${1:Exception} { ${2} }\n\
+snippet asnrd\n\
+ assert_nothing_raised ${1:Exception} do\n\
+ ${2}\n\
+ end\n\
+snippet asrt\n\
+ assert_respond_to ${1:object}, :${2:method}${3}\n\
+snippet ass assert_same(..)\n\
+ assert_same ${1:expected}, ${2:actual}${3}\n\
+snippet ass assert_send(..)\n\
+ assert_send [${1:object}, :${2:message}, ${3:args}]${4}\n\
+snippet asns\n\
+ assert_not_same ${1:unexpected}, ${2:actual}${3}\n\
+snippet ast\n\
+ assert_throws :${1:expected} { ${2} }\n\
+snippet astd\n\
+ assert_throws :${1:expected} do\n\
+ ${2}\n\
+ end\n\
+snippet asnt\n\
+ assert_nothing_thrown { ${1} }\n\
+snippet asntd\n\
+ assert_nothing_thrown do\n\
+ ${1}\n\
+ end\n\
+snippet fl\n\
+ flunk \"${1:Failure message.}\"${2}\n\
+# Benchmark.bmbm do .. end\n\
+snippet bm-\n\
+ TESTS = ${1:10_000}\n\
+ Benchmark.bmbm do |results|\n\
+ ${2}\n\
+ end\n\
+snippet rep\n\
+ results.report(\"${1:name}:\") { TESTS.times { ${2} }}\n\
+# Marshal.dump(.., file)\n\
+snippet Md\n\
+ File.open(${1:\"path/to/file.dump\"}, \"wb\") { |${2:file}| Marshal.dump(${3:obj}, $2) }${4}\n\
+# Mashal.load(obj)\n\
+snippet Ml\n\
+ File.open(${1:\"path/to/file.dump\"}, \"rb\") { |${2:file}| Marshal.load($2) }${3}\n\
+# deep_copy(..)\n\
+snippet deec\n\
+ Marshal.load(Marshal.dump(${1:obj_to_copy}))${2}\n\
+snippet Pn-\n\
+ PStore.new(${1:\"file_name.pstore\"})${2}\n\
+snippet tra\n\
+ transaction(${1:true}) { ${2} }\n\
+# xmlread(..)\n\
+snippet xml-\n\
+ REXML::Document.new(File.read(${1:\"path/to/file\"}))${2}\n\
+# xpath(..) { .. }\n\
+snippet xpa\n\
+ elements.each(${1:\"//Xpath\"}) do |${2:node}|\n\
+ ${3}\n\
+ end\n\
+# class_from_name()\n\
+snippet clafn\n\
+ split(\"::\").inject(Object) { |par, const| par.const_get(const) }\n\
+# singleton_class()\n\
+snippet sinc\n\
+ class << self; self end\n\
+snippet nam\n\
+ namespace :${1:`Filename()`} do\n\
+ ${2}\n\
+ end\n\
+snippet tas\n\
+ desc \"${1:Task description}\"\n\
+ task :${2:task_name => [:dependent, :tasks]} do\n\
+ ${3}\n\
+ end\n\
+# block\n\
+snippet b\n\
+ { |${1:var}| ${2} }\n\
+snippet begin\n\
+ begin\n\
+ raise 'A test exception.'\n\
+ rescue Exception => e\n\
+ puts e.message\n\
+ puts e.backtrace.inspect\n\
+ else\n\
+ # other exception\n\
+ ensure\n\
+ # always executed\n\
+ end\n\
+\n\
+#debugging\n\
+snippet debug\n\
+ require 'ruby-debug'; debugger; true;\n\
+snippet pry\n\
+ require 'pry'; binding.pry\n\
+\n\
+#############################################\n\
+# Rails snippets - for pure Ruby, see above #\n\
+#############################################\n\
+snippet art\n\
+ assert_redirected_to ${1::action => \"${2:index}\"}\n\
+snippet artnp\n\
+ assert_redirected_to ${1:parent}_${2:child}_path(${3:@$1}, ${4:@$2})\n\
+snippet artnpp\n\
+ assert_redirected_to ${1:parent}_${2:child}_path(${3:@$1})\n\
+snippet artp\n\
+ assert_redirected_to ${1:model}_path(${2:@$1})\n\
+snippet artpp\n\
+ assert_redirected_to ${1:model}s_path\n\
+snippet asd\n\
+ assert_difference \"${1:Model}.${2:count}\", $1 do\n\
+ ${3}\n\
+ end\n\
+snippet asnd\n\
+ assert_no_difference \"${1:Model}.${2:count}\" do\n\
+ ${3}\n\
+ end\n\
+snippet asre\n\
+ assert_response :${1:success}, @response.body${2}\n\
+snippet asrj\n\
+ assert_rjs :${1:replace}, \"${2:dom id}\"\n\
+snippet ass assert_select(..)\n\
+ assert_select '${1:path}', :${2:text} => '${3:inner_html' ${4:do}\n\
+snippet bf\n\
+ before_filter :${1:method}\n\
+snippet bt\n\
+ belongs_to :${1:association}\n\
+snippet crw\n\
+ cattr_accessor :${1:attr_names}\n\
+snippet defcreate\n\
+ def create\n\
+ @${1:model_class_name} = ${2:ModelClassName}.new(params[:$1])\n\
+\n\
+ respond_to do |wants|\n\
+ if @$1.save\n\
+ flash[:notice] = '$2 was successfully created.'\n\
+ wants.html { redirect_to(@$1) }\n\
+ wants.xml { render :xml => @$1, :status => :created, :location => @$1 }\n\
+ else\n\
+ wants.html { render :action => \"new\" }\n\
+ wants.xml { render :xml => @$1.errors, :status => :unprocessable_entity }\n\
+ end\n\
+ end\n\
+ end${3}\n\
+snippet defdestroy\n\
+ def destroy\n\
+ @${1:model_class_name} = ${2:ModelClassName}.find(params[:id])\n\
+ @$1.destroy\n\
+\n\
+ respond_to do |wants|\n\
+ wants.html { redirect_to($1s_url) }\n\
+ wants.xml { head :ok }\n\
+ end\n\
+ end${3}\n\
+snippet defedit\n\
+ def edit\n\
+ @${1:model_class_name} = ${2:ModelClassName}.find(params[:id])\n\
+ end\n\
+snippet defindex\n\
+ def index\n\
+ @${1:model_class_name} = ${2:ModelClassName}.all\n\
+\n\
+ respond_to do |wants|\n\
+ wants.html # index.html.erb\n\
+ wants.xml { render :xml => @$1s }\n\
+ end\n\
+ end${3}\n\
+snippet defnew\n\
+ def new\n\
+ @${1:model_class_name} = ${2:ModelClassName}.new\n\
+\n\
+ respond_to do |wants|\n\
+ wants.html # new.html.erb\n\
+ wants.xml { render :xml => @$1 }\n\
+ end\n\
+ end${3}\n\
+snippet defshow\n\
+ def show\n\
+ @${1:model_class_name} = ${2:ModelClassName}.find(params[:id])\n\
+\n\
+ respond_to do |wants|\n\
+ wants.html # show.html.erb\n\
+ wants.xml { render :xml => @$1 }\n\
+ end\n\
+ end${3}\n\
+snippet defupdate\n\
+ def update\n\
+ @${1:model_class_name} = ${2:ModelClassName}.find(params[:id])\n\
+\n\
+ respond_to do |wants|\n\
+ if @$1.update_attributes(params[:$1])\n\
+ flash[:notice] = '$2 was successfully updated.'\n\
+ wants.html { redirect_to(@$1) }\n\
+ wants.xml { head :ok }\n\
+ else\n\
+ wants.html { render :action => \"edit\" }\n\
+ wants.xml { render :xml => @$1.errors, :status => :unprocessable_entity }\n\
+ end\n\
+ end\n\
+ end${3}\n\
+snippet flash\n\
+ flash[:${1:notice}] = \"${2}\"\n\
+snippet habtm\n\
+ has_and_belongs_to_many :${1:object}, :join_table => \"${2:table_name}\", :foreign_key => \"${3}_id\"${4}\n\
+snippet hm\n\
+ has_many :${1:object}\n\
+snippet hmd\n\
+ has_many :${1:other}s, :class_name => \"${2:$1}\", :foreign_key => \"${3:$1}_id\", :dependent => :destroy${4}\n\
+snippet hmt\n\
+ has_many :${1:object}, :through => :${2:object}\n\
+snippet ho\n\
+ has_one :${1:object}\n\
+snippet i18\n\
+ I18n.t('${1:type.key}')${2}\n\
+snippet ist\n\
+ <%= image_submit_tag(\"${1:agree.png}\", :id => \"${2:id}\"${3} %>\n\
+snippet log\n\
+ Rails.logger.${1:debug} ${2}\n\
+snippet log2\n\
+ RAILS_DEFAULT_LOGGER.${1:debug} ${2}\n\
+snippet logd\n\
+ logger.debug { \"${1:message}\" }${2}\n\
+snippet loge\n\
+ logger.error { \"${1:message}\" }${2}\n\
+snippet logf\n\
+ logger.fatal { \"${1:message}\" }${2}\n\
+snippet logi\n\
+ logger.info { \"${1:message}\" }${2}\n\
+snippet logw\n\
+ logger.warn { \"${1:message}\" }${2}\n\
+snippet mapc\n\
+ ${1:map}.${2:connect} '${3:controller/:action/:id}'\n\
+snippet mapca\n\
+ ${1:map}.catch_all \"*${2:anything}\", :controller => \"${3:default}\", :action => \"${4:error}\"${5}\n\
+snippet mapr\n\
+ ${1:map}.resource :${2:resource}\n\
+snippet maprs\n\
+ ${1:map}.resources :${2:resource}\n\
+snippet mapwo\n\
+ ${1:map}.with_options :${2:controller} => '${3:thing}' do |$3|\n\
+ ${4}\n\
+ end\n\
+snippet mbs\n\
+ before_save :${1:method}\n\
+snippet mcht\n\
+ change_table :${1:table_name} do |t|\n\
+ ${2}\n\
+ end\n\
+snippet mp\n\
+ map(&:${1:id})\n\
+snippet mrw\n\
+ mattr_accessor :${1:attr_names}\n\
+snippet oa\n\
+ order(\"${1:field}\")\n\
+snippet od\n\
+ order(\"${1:field} DESC\")\n\
+snippet pa\n\
+ params[:${1:id}]${2}\n\
+snippet ra\n\
+ render :action => \"${1:action}\"\n\
+snippet ral\n\
+ render :action => \"${1:action}\", :layout => \"${2:layoutname}\"\n\
+snippet rest\n\
+ respond_to do |wants|\n\
+ wants.${1:html} { ${2} }\n\
+ end\n\
+snippet rf\n\
+ render :file => \"${1:filepath}\"\n\
+snippet rfu\n\
+ render :file => \"${1:filepath}\", :use_full_path => ${2:false}\n\
+snippet ri\n\
+ render :inline => \"${1:<%= 'hello' %>}\"\n\
+snippet ril\n\
+ render :inline => \"${1:<%= 'hello' %>}\", :locals => { ${2::name} => \"${3:value}\"${4} }\n\
+snippet rit\n\
+ render :inline => \"${1:<%= 'hello' %>}\", :type => ${2::rxml}\n\
+snippet rjson\n\
+ render :json => ${1:text to render}\n\
+snippet rl\n\
+ render :layout => \"${1:layoutname}\"\n\
+snippet rn\n\
+ render :nothing => ${1:true}\n\
+snippet rns\n\
+ render :nothing => ${1:true}, :status => ${2:401}\n\
+snippet rp\n\
+ render :partial => \"${1:item}\"\n\
+snippet rpc\n\
+ render :partial => \"${1:item}\", :collection => ${2:@$1s}\n\
+snippet rpl\n\
+ render :partial => \"${1:item}\", :locals => { :${2:$1} => ${3:@$1}\n\
+snippet rpo\n\
+ render :partial => \"${1:item}\", :object => ${2:@$1}\n\
+snippet rps\n\
+ render :partial => \"${1:item}\", :status => ${2:500}\n\
+snippet rt\n\
+ render :text => \"${1:text to render}\"\n\
+snippet rtl\n\
+ render :text => \"${1:text to render}\", :layout => \"${2:layoutname}\"\n\
+snippet rtlt\n\
+ render :text => \"${1:text to render}\", :layout => ${2:true}\n\
+snippet rts\n\
+ render :text => \"${1:text to render}\", :status => ${2:401}\n\
+snippet ru\n\
+ render :update do |${1:page}|\n\
+ $1.${2}\n\
+ end\n\
+snippet rxml\n\
+ render :xml => ${1:text to render}\n\
+snippet sc\n\
+ scope :${1:name}, :where(:@${2:field} => ${3:value})\n\
+snippet sl\n\
+ scope :${1:name}, lambda do |${2:value}|\n\
+ where(\"${3:field = ?}\", ${4:bind var})\n\
+ end\n\
+snippet sha1\n\
+ Digest::SHA1.hexdigest(${1:string})\n\
+snippet sweeper\n\
+ class ${1:ModelClassName}Sweeper < ActionController::Caching::Sweeper\n\
+ observe $1\n\
+\n\
+ def after_save(${2:model_class_name})\n\
+ expire_cache($2)\n\
+ end\n\
+\n\
+ def after_destroy($2)\n\
+ expire_cache($2)\n\
+ end\n\
+\n\
+ def expire_cache($2)\n\
+ expire_page\n\
+ end\n\
+ end\n\
+snippet tcb\n\
+ t.boolean :${1:title}\n\
+ ${2}\n\
+snippet tcbi\n\
+ t.binary :${1:title}, :limit => ${2:2}.megabytes\n\
+ ${3}\n\
+snippet tcd\n\
+ t.decimal :${1:title}, :precision => ${2:10}, :scale => ${3:2}\n\
+ ${4}\n\
+snippet tcda\n\
+ t.date :${1:title}\n\
+ ${2}\n\
+snippet tcdt\n\
+ t.datetime :${1:title}\n\
+ ${2}\n\
+snippet tcf\n\
+ t.float :${1:title}\n\
+ ${2}\n\
+snippet tch\n\
+ t.change :${1:name}, :${2:string}, :${3:limit} => ${4:80}\n\
+ ${5}\n\
+snippet tci\n\
+ t.integer :${1:title}\n\
+ ${2}\n\
+snippet tcl\n\
+ t.integer :lock_version, :null => false, :default => 0\n\
+ ${1}\n\
+snippet tcr\n\
+ t.references :${1:taggable}, :polymorphic => { :default => '${2:Photo}' }\n\
+ ${3}\n\
+snippet tcs\n\
+ t.string :${1:title}\n\
+ ${2}\n\
+snippet tct\n\
+ t.text :${1:title}\n\
+ ${2}\n\
+snippet tcti\n\
+ t.time :${1:title}\n\
+ ${2}\n\
+snippet tcts\n\
+ t.timestamp :${1:title}\n\
+ ${2}\n\
+snippet tctss\n\
+ t.timestamps\n\
+ ${1}\n\
+snippet va\n\
+ validates_associated :${1:attribute}\n\
+snippet vao\n\
+ validates_acceptance_of :${1:terms}\n\
+snippet vc\n\
+ validates_confirmation_of :${1:attribute}\n\
+snippet ve\n\
+ validates_exclusion_of :${1:attribute}, :in => ${2:%w( mov avi )}\n\
+snippet vf\n\
+ validates_format_of :${1:attribute}, :with => /${2:regex}/\n\
+snippet vi\n\
+ validates_inclusion_of :${1:attribute}, :in => %w(${2: mov avi })\n\
+snippet vl\n\
+ validates_length_of :${1:attribute}, :within => ${2:3}..${3:20}\n\
+snippet vn\n\
+ validates_numericality_of :${1:attribute}\n\
+snippet vpo\n\
+ validates_presence_of :${1:attribute}\n\
+snippet vu\n\
+ validates_uniqueness_of :${1:attribute}\n\
+snippet wants\n\
+ wants.${1:js|xml|html} { ${2} }\n\
+snippet wc\n\
+ where(${1:\"conditions\"}${2:, bind_var})\n\
+snippet wh\n\
+ where(${1:field} => ${2:value})\n\
+snippet xdelete\n\
+ xhr :delete, :${1:destroy}, :id => ${2:1}${3}\n\
+snippet xget\n\
+ xhr :get, :${1:show}, :id => ${2:1}${3}\n\
+snippet xpost\n\
+ xhr :post, :${1:create}, :${2:object} => { ${3} }\n\
+snippet xput\n\
+ xhr :put, :${1:update}, :id => ${2:1}, :${3:object} => { ${4} }${5}\n\
+snippet test\n\
+ test \"should ${1:do something}\" do\n\
+ ${2}\n\
+ end\n\
+#migrations\n\
+snippet mac\n\
+ add_column :${1:table_name}, :${2:column_name}, :${3:data_type}\n\
+snippet mrc\n\
+ remove_column :${1:table_name}, :${2:column_name}\n\
+snippet mrnc\n\
+ rename_column :${1:table_name}, :${2:old_column_name}, :${3:new_column_name}\n\
+snippet mcc\n\
+ change_column :${1:table}, :${2:column}, :${3:type}\n\
+snippet mccc\n\
+ t.column :${1:title}, :${2:string}\n\
+snippet mct\n\
+ create_table :${1:table_name} do |t|\n\
+ t.column :${2:name}, :${3:type}\n\
+ end\n\
+snippet migration\n\
+ class ${1:class_name} < ActiveRecord::Migration\n\
+ def self.up\n\
+ ${2}\n\
+ end\n\
+\n\
+ def self.down\n\
+ end\n\
+ end\n\
+\n\
+snippet trc\n\
+ t.remove :${1:column}\n\
+snippet tre\n\
+ t.rename :${1:old_column_name}, :${2:new_column_name}\n\
+ ${3}\n\
+snippet tref\n\
+ t.references :${1:model}\n\
+\n\
+#rspec\n\
+snippet it\n\
+ it \"${1:spec_name}\" do\n\
+ ${2}\n\
+ end\n\
+snippet itp\n\
+ it \"${1:spec_name}\"\n\
+ ${2}\n\
+snippet desc\n\
+ describe ${1:class_name} do\n\
+ ${2}\n\
+ end\n\
+snippet cont\n\
+ context \"${1:message}\" do\n\
+ ${2}\n\
+ end\n\
+snippet bef\n\
+ before :${1:each} do\n\
+ ${2}\n\
+ end\n\
+snippet aft\n\
+ after :${1:each} do\n\
+ ${2}\n\
+ end\n\
+";
+exports.scope = "ruby";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/rust.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rust.js
new file mode 100644
index 00000000..0411c63e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/rust.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/rust",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "rust";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/sass.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sass.js
new file mode 100644
index 00000000..b9adc9d8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sass.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/sass",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "sass";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/scad.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scad.js
new file mode 100644
index 00000000..998a98ac
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scad.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/scad",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "scad";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/scala.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scala.js
new file mode 100644
index 00000000..4051d988
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scala.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/scala",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "scala";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/scheme.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scheme.js
new file mode 100644
index 00000000..202d0741
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scheme.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/scheme",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "scheme";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/scss.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scss.js
new file mode 100644
index 00000000..fbd98f74
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/scss.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/scss",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "scss";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/sh.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sh.js
new file mode 100644
index 00000000..0f1f6d8e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sh.js
@@ -0,0 +1,90 @@
+ace.define("ace/snippets/sh",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Shebang. Executing bash via /usr/bin/env makes scripts more portable.\n\
+snippet #!\n\
+ #!/usr/bin/env bash\n\
+ \n\
+snippet if\n\
+ if [[ ${1:condition} ]]; then\n\
+ ${2:#statements}\n\
+ fi\n\
+snippet elif\n\
+ elif [[ ${1:condition} ]]; then\n\
+ ${2:#statements}\n\
+snippet for\n\
+ for (( ${2:i} = 0; $2 < ${1:count}; $2++ )); do\n\
+ ${3:#statements}\n\
+ done\n\
+snippet fori\n\
+ for ${1:needle} in ${2:haystack} ; do\n\
+ ${3:#statements}\n\
+ done\n\
+snippet wh\n\
+ while [[ ${1:condition} ]]; do\n\
+ ${2:#statements}\n\
+ done\n\
+snippet until\n\
+ until [[ ${1:condition} ]]; do\n\
+ ${2:#statements}\n\
+ done\n\
+snippet case\n\
+ case ${1:word} in\n\
+ ${2:pattern})\n\
+ ${3};;\n\
+ esac\n\
+snippet go \n\
+ while getopts '${1:o}' ${2:opts} \n\
+ do \n\
+ case $$2 in\n\
+ ${3:o0})\n\
+ ${4:#staments};;\n\
+ esac\n\
+ done\n\
+# Set SCRIPT_DIR variable to directory script is located.\n\
+snippet sdir\n\
+ SCRIPT_DIR=\"$( cd \"$( dirname \"${BASH_SOURCE[0]}\" )\" && pwd )\"\n\
+# getopt\n\
+snippet getopt\n\
+ __ScriptVersion=\"${1:version}\"\n\
+\n\
+ #=== FUNCTION ================================================================\n\
+ # NAME: usage\n\
+ # DESCRIPTION: Display usage information.\n\
+ #===============================================================================\n\
+ function usage ()\n\
+ {\n\
+ cat <<- EOT\n\
+\n\
+ Usage : $${0:0} [options] [--] \n\
+\n\
+ Options: \n\
+ -h|help Display this message\n\
+ -v|version Display script version\n\
+\n\
+ EOT\n\
+ } # ---------- end of function usage ----------\n\
+\n\
+ #-----------------------------------------------------------------------\n\
+ # Handle command line arguments\n\
+ #-----------------------------------------------------------------------\n\
+\n\
+ while getopts \":hv\" opt\n\
+ do\n\
+ case $opt in\n\
+\n\
+ h|help ) usage; exit 0 ;;\n\
+\n\
+ v|version ) echo \"$${0:0} -- Version $__ScriptVersion\"; exit 0 ;;\n\
+\n\
+ \\? ) echo -e \"\\n Option does not exist : $OPTARG\\n\"\n\
+ usage; exit 1 ;;\n\
+\n\
+ esac # --- end of case ---\n\
+ done\n\
+ shift $(($OPTIND-1))\n\
+\n\
+";
+exports.scope = "sh";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/sjs.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sjs.js
new file mode 100644
index 00000000..cf39a34e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sjs.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/sjs",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "sjs";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/smarty.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/smarty.js
new file mode 100644
index 00000000..47319a25
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/smarty.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/smarty",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "smarty";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/snippets.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/snippets.js
new file mode 100644
index 00000000..b81605cc
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/snippets.js
@@ -0,0 +1,16 @@
+ace.define("ace/snippets/snippets",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# snippets for making snippets :)\n\
+snippet snip\n\
+ snippet ${1:trigger}\n\
+ ${2}\n\
+snippet msnip\n\
+ snippet ${1:trigger} ${2:description}\n\
+ ${3}\n\
+snippet v\n\
+ {VISUAL}\n\
+";
+exports.scope = "snippets";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/soy_template.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/soy_template.js
new file mode 100644
index 00000000..908f5fdf
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/soy_template.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/soy_template",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "soy_template";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/space.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/space.js
new file mode 100644
index 00000000..302b84e0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/space.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/space",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "space";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/sparql.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sparql.js
new file mode 100644
index 00000000..2c87bbfe
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sparql.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/sparql",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/sql.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sql.js
new file mode 100644
index 00000000..1822126b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sql.js
@@ -0,0 +1,33 @@
+ace.define("ace/snippets/sql",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet tbl\n\
+ create table ${1:table} (\n\
+ ${2:columns}\n\
+ );\n\
+snippet col\n\
+ ${1:name} ${2:type} ${3:default ''} ${4:not null}\n\
+snippet ccol\n\
+ ${1:name} varchar2(${2:size}) ${3:default ''} ${4:not null}\n\
+snippet ncol\n\
+ ${1:name} number ${3:default 0} ${4:not null}\n\
+snippet dcol\n\
+ ${1:name} date ${3:default sysdate} ${4:not null}\n\
+snippet ind\n\
+ create index ${3:$1_$2} on ${1:table}(${2:column});\n\
+snippet uind\n\
+ create unique index ${1:name} on ${2:table}(${3:column});\n\
+snippet tblcom\n\
+ comment on table ${1:table} is '${2:comment}';\n\
+snippet colcom\n\
+ comment on column ${1:table}.${2:column} is '${3:comment}';\n\
+snippet addcol\n\
+ alter table ${1:table} add (${2:column} ${3:type});\n\
+snippet seq\n\
+ create sequence ${1:name} start with ${2:1} increment by ${3:1} minvalue ${4:1};\n\
+snippet s*\n\
+ select * from ${1:table}\n\
+";
+exports.scope = "sql";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/sqlserver.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sqlserver.js
new file mode 100644
index 00000000..7dfa2d04
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/sqlserver.js
@@ -0,0 +1,76 @@
+ace.define("ace/snippets/sqlserver",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# ISNULL\n\
+snippet isnull\n\
+ ISNULL(${1:check_expression}, ${2:replacement_value})\n\
+# FORMAT\n\
+snippet format\n\
+ FORMAT(${1:value}, ${2:format})\n\
+# CAST\n\
+snippet cast\n\
+ CAST(${1:expression} AS ${2:data_type})\n\
+# CONVERT\n\
+snippet convert\n\
+ CONVERT(${1:data_type}, ${2:expression})\n\
+# DATEPART\n\
+snippet datepart\n\
+ DATEPART(${1:datepart}, ${2:date})\n\
+# DATEDIFF\n\
+snippet datediff\n\
+ DATEDIFF(${1:datepart}, ${2:startdate}, ${3:enddate})\n\
+# DATEADD\n\
+snippet dateadd\n\
+ DATEADD(${1:datepart}, ${2:number}, ${3:date})\n\
+# DATEFROMPARTS \n\
+snippet datefromparts\n\
+ DATEFROMPARTS(${1:year}, ${2:month}, ${3:day})\n\
+# OBJECT_DEFINITION\n\
+snippet objectdef\n\
+ SELECT OBJECT_DEFINITION(OBJECT_ID('${1:sys.server_permissions /*object name*/}'))\n\
+# STUFF XML\n\
+snippet stuffxml\n\
+ STUFF((SELECT ', ' + ${1:ColumnName}\n\
+ FROM ${2:TableName}\n\
+ WHERE ${3:WhereClause}\n\
+ FOR XML PATH('')), 1, 1, '') AS ${4:Alias}\n\
+ ${5:/*https://msdn.microsoft.com/en-us/library/ms188043.aspx*/}\n\
+# Create Procedure\n\
+snippet createproc\n\
+ -- =============================================\n\
+ -- Author: ${1:Author}\n\
+ -- Create date: ${2:Date}\n\
+ -- Description: ${3:Description}\n\
+ -- =============================================\n\
+ CREATE PROCEDURE ${4:Procedure_Name}\n\
+ ${5:/*Add the parameters for the stored procedure here*/}\n\
+ AS\n\
+ BEGIN\n\
+ -- SET NOCOUNT ON added to prevent extra result sets from interfering with SELECT statements.\n\
+ SET NOCOUNT ON;\n\
+ \n\
+ ${6:/*Add the T-SQL statements to compute the return value here*/}\n\
+ \n\
+ END\n\
+ GO\n\
+# Create Scalar Function\n\
+snippet createfn\n\
+ -- =============================================\n\
+ -- Author: ${1:Author}\n\
+ -- Create date: ${2:Date}\n\
+ -- Description: ${3:Description}\n\
+ -- =============================================\n\
+ CREATE FUNCTION ${4:Scalar_Function_Name}\n\
+ -- Add the parameters for the function here\n\
+ RETURNS ${5:Function_Data_Type}\n\
+ AS\n\
+ BEGIN\n\
+ DECLARE @Result ${5:Function_Data_Type}\n\
+ \n\
+ ${6:/*Add the T-SQL statements to compute the return value here*/}\n\
+ \n\
+ END\n\
+ GO";
+exports.scope = "sqlserver";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/stylus.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/stylus.js
new file mode 100644
index 00000000..5f700bae
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/stylus.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/stylus",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "stylus";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/svg.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/svg.js
new file mode 100644
index 00000000..69a3408e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/svg.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/svg",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "svg";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/swift.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/swift.js
new file mode 100644
index 00000000..55226ba0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/swift.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/swift",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "swift";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/tcl.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/tcl.js
new file mode 100644
index 00000000..4d116da8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/tcl.js
@@ -0,0 +1,99 @@
+ace.define("ace/snippets/tcl",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# #!/usr/bin/env tclsh\n\
+snippet #!\n\
+ #!/usr/bin/env tclsh\n\
+ \n\
+# Process\n\
+snippet pro\n\
+ proc ${1:function_name} {${2:args}} {\n\
+ ${3:#body ...}\n\
+ }\n\
+#xif\n\
+snippet xif\n\
+ ${1:expr}? ${2:true} : ${3:false}\n\
+# Conditional\n\
+snippet if\n\
+ if {${1}} {\n\
+ ${2:# body...}\n\
+ }\n\
+# Conditional if..else\n\
+snippet ife\n\
+ if {${1}} {\n\
+ ${2:# body...}\n\
+ } else {\n\
+ ${3:# else...}\n\
+ }\n\
+# Conditional if..elsif..else\n\
+snippet ifee\n\
+ if {${1}} {\n\
+ ${2:# body...}\n\
+ } elseif {${3}} {\n\
+ ${4:# elsif...}\n\
+ } else {\n\
+ ${5:# else...}\n\
+ }\n\
+# If catch then\n\
+snippet ifc\n\
+ if { [catch {${1:#do something...}} ${2:err}] } {\n\
+ ${3:# handle failure...}\n\
+ }\n\
+# Catch\n\
+snippet catch\n\
+ catch {${1}} ${2:err} ${3:options}\n\
+# While Loop\n\
+snippet wh\n\
+ while {${1}} {\n\
+ ${2:# body...}\n\
+ }\n\
+# For Loop\n\
+snippet for\n\
+ for {set ${2:var} 0} {$$2 < ${1:count}} {${3:incr} $2} {\n\
+ ${4:# body...}\n\
+ }\n\
+# Foreach Loop\n\
+snippet fore\n\
+ foreach ${1:x} {${2:#list}} {\n\
+ ${3:# body...}\n\
+ }\n\
+# after ms script...\n\
+snippet af\n\
+ after ${1:ms} ${2:#do something}\n\
+# after cancel id\n\
+snippet afc\n\
+ after cancel ${1:id or script}\n\
+# after idle\n\
+snippet afi\n\
+ after idle ${1:script}\n\
+# after info id\n\
+snippet afin\n\
+ after info ${1:id}\n\
+# Expr\n\
+snippet exp\n\
+ expr {${1:#expression here}}\n\
+# Switch\n\
+snippet sw\n\
+ switch ${1:var} {\n\
+ ${3:pattern 1} {\n\
+ ${4:#do something}\n\
+ }\n\
+ default {\n\
+ ${2:#do something}\n\
+ }\n\
+ }\n\
+# Case\n\
+snippet ca\n\
+ ${1:pattern} {\n\
+ ${2:#do something}\n\
+ }${3}\n\
+# Namespace eval\n\
+snippet ns\n\
+ namespace eval ${1:path} {${2:#script...}}\n\
+# Namespace current\n\
+snippet nsc\n\
+ namespace current\n\
+";
+exports.scope = "tcl";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/tex.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/tex.js
new file mode 100644
index 00000000..2bd3f103
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/tex.js
@@ -0,0 +1,197 @@
+ace.define("ace/snippets/tex",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "#PREAMBLE\n\
+#newcommand\n\
+snippet nc\n\
+ \\newcommand{\\${1:cmd}}[${2:opt}]{${3:realcmd}}${4}\n\
+#usepackage\n\
+snippet up\n\
+ \\usepackage[${1:[options}]{${2:package}}\n\
+#newunicodechar\n\
+snippet nuc\n\
+ \\newunicodechar{${1}}{${2:\\ensuremath}${3:tex-substitute}}}\n\
+#DeclareMathOperator\n\
+snippet dmo\n\
+ \\DeclareMathOperator{${1}}{${2}}\n\
+\n\
+#DOCUMENT\n\
+# \\begin{}...\\end{}\n\
+snippet begin\n\
+ \\begin{${1:env}}\n\
+ ${2}\n\
+ \\end{$1}\n\
+# Tabular\n\
+snippet tab\n\
+ \\begin{${1:tabular}}{${2:c}}\n\
+ ${3}\n\
+ \\end{$1}\n\
+snippet thm\n\
+ \\begin[${1:author}]{${2:thm}}\n\
+ ${3}\n\
+ \\end{$1}\n\
+snippet center\n\
+ \\begin{center}\n\
+ ${1}\n\
+ \\end{center}\n\
+# Align(ed)\n\
+snippet ali\n\
+ \\begin{align${1:ed}}\n\
+ ${2}\n\
+ \\end{align$1}\n\
+# Gather(ed)\n\
+snippet gat\n\
+ \\begin{gather${1:ed}}\n\
+ ${2}\n\
+ \\end{gather$1}\n\
+# Equation\n\
+snippet eq\n\
+ \\begin{equation}\n\
+ ${1}\n\
+ \\end{equation}\n\
+# Equation\n\
+snippet eq*\n\
+ \\begin{equation*}\n\
+ ${1}\n\
+ \\end{equation*}\n\
+# Unnumbered Equation\n\
+snippet \\\n\
+ \\[\n\
+ ${1}\n\
+ \\]\n\
+# Enumerate\n\
+snippet enum\n\
+ \\begin{enumerate}\n\
+ \\item ${1}\n\
+ \\end{enumerate}\n\
+# Itemize\n\
+snippet itemize\n\
+ \\begin{itemize}\n\
+ \\item ${1}\n\
+ \\end{itemize}\n\
+# Description\n\
+snippet desc\n\
+ \\begin{description}\n\
+ \\item[${1}] ${2}\n\
+ \\end{description}\n\
+# Matrix\n\
+snippet mat\n\
+ \\begin{${1:p/b/v/V/B/small}matrix}\n\
+ ${2}\n\
+ \\end{$1matrix}\n\
+# Cases\n\
+snippet cas\n\
+ \\begin{cases}\n\
+ ${1:equation}, &\\text{ if }${2:case}\\\\\n\
+ ${3}\n\
+ \\end{cases}\n\
+# Split\n\
+snippet spl\n\
+ \\begin{split}\n\
+ ${1}\n\
+ \\end{split}\n\
+# Part\n\
+snippet part\n\
+ \\part{${1:part name}} % (fold)\n\
+ \\label{prt:${2:$1}}\n\
+ ${3}\n\
+ % part $2 (end)\n\
+# Chapter\n\
+snippet cha\n\
+ \\chapter{${1:chapter name}}\n\
+ \\label{cha:${2:$1}}\n\
+ ${3}\n\
+# Section\n\
+snippet sec\n\
+ \\section{${1:section name}}\n\
+ \\label{sec:${2:$1}}\n\
+ ${3}\n\
+# Sub Section\n\
+snippet sub\n\
+ \\subsection{${1:subsection name}}\n\
+ \\label{sub:${2:$1}}\n\
+ ${3}\n\
+# Sub Sub Section\n\
+snippet subs\n\
+ \\subsubsection{${1:subsubsection name}}\n\
+ \\label{ssub:${2:$1}}\n\
+ ${3}\n\
+# Paragraph\n\
+snippet par\n\
+ \\paragraph{${1:paragraph name}}\n\
+ \\label{par:${2:$1}}\n\
+ ${3}\n\
+# Sub Paragraph\n\
+snippet subp\n\
+ \\subparagraph{${1:subparagraph name}}\n\
+ \\label{subp:${2:$1}}\n\
+ ${3}\n\
+#References\n\
+snippet itd\n\
+ \\item[${1:description}] ${2:item}\n\
+snippet figure\n\
+ ${1:Figure}~\\ref{${2:fig:}}${3}\n\
+snippet table\n\
+ ${1:Table}~\\ref{${2:tab:}}${3}\n\
+snippet listing\n\
+ ${1:Listing}~\\ref{${2:list}}${3}\n\
+snippet section\n\
+ ${1:Section}~\\ref{${2:sec:}}${3}\n\
+snippet page\n\
+ ${1:page}~\\pageref{${2}}${3}\n\
+snippet index\n\
+ \\index{${1:index}}${2}\n\
+#Citations\n\
+snippet cite\n\
+ \\cite[${1}]{${2}}${3}\n\
+snippet fcite\n\
+ \\footcite[${1}]{${2}}${3}\n\
+#Formating text: italic, bold, underline, small capital, emphase ..\n\
+snippet it\n\
+ \\textit{${1:text}}\n\
+snippet bf\n\
+ \\textbf{${1:text}}\n\
+snippet under\n\
+ \\underline{${1:text}}\n\
+snippet emp\n\
+ \\emph{${1:text}}\n\
+snippet sc\n\
+ \\textsc{${1:text}}\n\
+#Choosing font\n\
+snippet sf\n\
+ \\textsf{${1:text}}\n\
+snippet rm\n\
+ \\textrm{${1:text}}\n\
+snippet tt\n\
+ \\texttt{${1:text}}\n\
+#misc\n\
+snippet ft\n\
+ \\footnote{${1:text}}\n\
+snippet fig\n\
+ \\begin{figure}\n\
+ \\begin{center}\n\
+ \\includegraphics[scale=${1}]{Figures/${2}}\n\
+ \\end{center}\n\
+ \\caption{${3}}\n\
+ \\label{fig:${4}}\n\
+ \\end{figure}\n\
+snippet tikz\n\
+ \\begin{figure}\n\
+ \\begin{center}\n\
+ \\begin{tikzpicture}[scale=${1:1}]\n\
+ ${2}\n\
+ \\end{tikzpicture}\n\
+ \\end{center}\n\
+ \\caption{${3}}\n\
+ \\label{fig:${4}}\n\
+ \\end{figure}\n\
+#math\n\
+snippet stackrel\n\
+ \\stackrel{${1:above}}{${2:below}} ${3}\n\
+snippet frac\n\
+ \\frac{${1:num}}{${2:denom}}\n\
+snippet sum\n\
+ \\sum^{${1:n}}_{${2:i=1}}{${3}}";
+exports.scope = "tex";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/text.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/text.js
new file mode 100644
index 00000000..57b897bf
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/text.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/text",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "text";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/textile.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/textile.js
new file mode 100644
index 00000000..a6fd711e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/textile.js
@@ -0,0 +1,37 @@
+ace.define("ace/snippets/textile",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# Jekyll post header\n\
+snippet header\n\
+ ---\n\
+ title: ${1:title}\n\
+ layout: post\n\
+ date: ${2:date} ${3:hour:minute:second} -05:00\n\
+ ---\n\
+\n\
+# Image\n\
+snippet img\n\
+ !${1:url}(${2:title}):${3:link}!\n\
+\n\
+# Table\n\
+snippet |\n\
+ |${1}|${2}\n\
+\n\
+# Link\n\
+snippet link\n\
+ \"${1:link text}\":${2:url}\n\
+\n\
+# Acronym\n\
+snippet (\n\
+ (${1:Expand acronym})${2}\n\
+\n\
+# Footnote\n\
+snippet fn\n\
+ [${1:ref number}] ${3}\n\
+\n\
+ fn$1. ${2:footnote}\n\
+ \n\
+";
+exports.scope = "textile";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/toml.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/toml.js
new file mode 100644
index 00000000..0c1a857b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/toml.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/toml",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "toml";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/tsx.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/tsx.js
new file mode 100644
index 00000000..7946297e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/tsx.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/tsx",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "tsx";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/turtle.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/turtle.js
new file mode 100644
index 00000000..5e104b22
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/turtle.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/turtle",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/twig.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/twig.js
new file mode 100644
index 00000000..ccc6073c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/twig.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/twig",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "twig";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/typescript.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/typescript.js
new file mode 100644
index 00000000..5f6217d0
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/typescript.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/typescript",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "typescript";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/vala.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/vala.js
new file mode 100644
index 00000000..3b493422
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/vala.js
@@ -0,0 +1,193 @@
+ace.define("ace/snippets/vala",["require","exports","module"], function(require, exports, module) {
+"use strict";
+exports.snippets = [
+ {
+ "content": "case ${1:condition}:\n\t$0\n\tbreak;\n",
+ "name": "case",
+ "scope": "vala",
+ "tabTrigger": "case"
+ },
+ {
+ "content": "/**\n * ${6}\n */\n${1:public} class ${2:MethodName}${3: : GLib.Object} {\n\n\t/**\n\t * ${7}\n\t */\n\tpublic ${2}(${4}) {\n\t\t${5}\n\t}\n\n\t$0\n}",
+ "name": "class",
+ "scope": "vala",
+ "tabTrigger": "class"
+ },
+ {
+ "content": "(${1}) => {\n\t${0}\n}\n",
+ "name": "closure",
+ "scope": "vala",
+ "tabTrigger": "=>"
+ },
+ {
+ "content": "/*\n * $0\n */",
+ "name": "Comment (multiline)",
+ "scope": "vala",
+ "tabTrigger": "/*"
+ },
+ {
+ "content": "Console.WriteLine($1);\n$0",
+ "name": "Console.WriteLine (writeline)",
+ "scope": "vala",
+ "tabTrigger": "writeline"
+ },
+ {
+ "content": "[DBus(name = \"$0\")]",
+ "name": "DBus annotation",
+ "scope": "vala",
+ "tabTrigger": "[DBus"
+ },
+ {
+ "content": "delegate ${1:void} ${2:DelegateName}($0);",
+ "name": "delegate",
+ "scope": "vala",
+ "tabTrigger": "delegate"
+ },
+ {
+ "content": "do {\n\t$0\n} while ($1);\n",
+ "name": "do while",
+ "scope": "vala",
+ "tabTrigger": "dowhile"
+ },
+ {
+ "content": "/**\n * $0\n */",
+ "name": "DocBlock",
+ "scope": "vala",
+ "tabTrigger": "/**"
+ },
+ {
+ "content": "else if ($1) {\n\t$0\n}\n",
+ "name": "else if (elseif)",
+ "scope": "vala",
+ "tabTrigger": "elseif"
+ },
+ {
+ "content": "else {\n\t$0\n}",
+ "name": "else",
+ "scope": "vala",
+ "tabTrigger": "else"
+ },
+ {
+ "content": "enum {$1:EnumName} {\n\t$0\n}",
+ "name": "enum",
+ "scope": "vala",
+ "tabTrigger": "enum"
+ },
+ {
+ "content": "public errordomain ${1:Error} {\n\t$0\n}",
+ "name": "error domain",
+ "scope": "vala",
+ "tabTrigger": "errordomain"
+ },
+ {
+ "content": "for ($1;$2;$3) {\n\t$0\n}",
+ "name": "for",
+ "scope": "vala",
+ "tabTrigger": "for"
+ },
+ {
+ "content": "foreach ($1 in $2) {\n\t$0\n}",
+ "name": "foreach",
+ "scope": "vala",
+ "tabTrigger": "foreach"
+ },
+ {
+ "content": "Gee.ArrayList<${1:G}>($0);",
+ "name": "Gee.ArrayList",
+ "scope": "vala",
+ "tabTrigger": "ArrayList"
+ },
+ {
+ "content": "Gee.HashMap<${1:K},${2:V}>($0);",
+ "name": "Gee.HashMap",
+ "scope": "vala",
+ "tabTrigger": "HashMap"
+ },
+ {
+ "content": "Gee.HashSet<${1:G}>($0);",
+ "name": "Gee.HashSet",
+ "scope": "vala",
+ "tabTrigger": "HashSet"
+ },
+ {
+ "content": "if ($1) {\n\t$0\n}",
+ "name": "if",
+ "scope": "vala",
+ "tabTrigger": "if"
+ },
+ {
+ "content": "interface ${1:InterfaceName}{$2: : SuperInterface} {\n\t$0\n}",
+ "name": "interface",
+ "scope": "vala",
+ "tabTrigger": "interface"
+ },
+ {
+ "content": "public static int main(string [] argv) {\n\t${0}\n\treturn 0;\n}",
+ "name": "Main function",
+ "scope": "vala",
+ "tabTrigger": "main"
+ },
+ {
+ "content": "namespace $1 {\n\t$0\n}\n",
+ "name": "namespace (ns)",
+ "scope": "vala",
+ "tabTrigger": "ns"
+ },
+ {
+ "content": "stdout.printf($0);",
+ "name": "printf",
+ "scope": "vala",
+ "tabTrigger": "printf"
+ },
+ {
+ "content": "${1:public} ${2:Type} ${3:Name} {\n\tset {\n\t\t$0\n\t}\n\tget {\n\n\t}\n}",
+ "name": "property (prop)",
+ "scope": "vala",
+ "tabTrigger": "prop"
+ },
+ {
+ "content": "${1:public} ${2:Type} ${3:Name} {\n\tget {\n\t\t$0\n\t}\n}",
+ "name": "read-only property (roprop)",
+ "scope": "vala",
+ "tabTrigger": "roprop"
+ },
+ {
+ "content": "@\"${1:\\$var}\"",
+ "name": "String template (@)",
+ "scope": "vala",
+ "tabTrigger": "@"
+ },
+ {
+ "content": "struct ${1:StructName} {\n\t$0\n}",
+ "name": "struct",
+ "scope": "vala",
+ "tabTrigger": "struct"
+ },
+ {
+ "content": "switch ($1) {\n\t$0\n}",
+ "name": "switch",
+ "scope": "vala",
+ "tabTrigger": "switch"
+ },
+ {
+ "content": "try {\n\t$2\n} catch (${1:Error} e) {\n\t$0\n}",
+ "name": "try/catch",
+ "scope": "vala",
+ "tabTrigger": "try"
+ },
+ {
+ "content": "\"\"\"$0\"\"\";",
+ "name": "Verbatim string (\"\"\")",
+ "scope": "vala",
+ "tabTrigger": "verbatim"
+ },
+ {
+ "content": "while ($1) {\n\t$0\n}",
+ "name": "while",
+ "scope": "vala",
+ "tabTrigger": "while"
+ }
+];
+exports.scope = "";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/vbscript.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/vbscript.js
new file mode 100644
index 00000000..38ca68fb
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/vbscript.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/vbscript",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "vbscript";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/velocity.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/velocity.js
new file mode 100644
index 00000000..e2b12a45
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/velocity.js
@@ -0,0 +1,36 @@
+ace.define("ace/snippets/velocity",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "# macro\n\
+snippet #macro\n\
+ #macro ( ${1:macroName} ${2:\\$var1, [\\$var2, ...]} )\n\
+ ${3:## macro code}\n\
+ #end\n\
+# foreach\n\
+snippet #foreach\n\
+ #foreach ( ${1:\\$item} in ${2:\\$collection} )\n\
+ ${3:## foreach code}\n\
+ #end\n\
+# if\n\
+snippet #if\n\
+ #if ( ${1:true} )\n\
+ ${0}\n\
+ #end\n\
+# if ... else\n\
+snippet #ife\n\
+ #if ( ${1:true} )\n\
+ ${2}\n\
+ #else\n\
+ ${0}\n\
+ #end\n\
+#import\n\
+snippet #import\n\
+ #import ( \"${1:path/to/velocity/format}\" )\n\
+# set\n\
+snippet #set\n\
+ #set ( $${1:var} = ${0} )\n\
+";
+exports.scope = "velocity";
+exports.includeScopes = ["html", "javascript", "css"];
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/verilog.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/verilog.js
new file mode 100644
index 00000000..8103ff6f
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/verilog.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/verilog",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "verilog";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/vhdl.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/vhdl.js
new file mode 100644
index 00000000..10d8ca09
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/vhdl.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/vhdl",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "vhdl";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/wollok.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/wollok.js
new file mode 100644
index 00000000..31e62118
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/wollok.js
@@ -0,0 +1,91 @@
+ace.define("ace/snippets/wollok",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "##\n\
+## Basic Java packages and import\n\
+snippet im\n\
+ import\n\
+snippet w.l\n\
+ wollok.lang\n\
+snippet w.i\n\
+ wollok.lib\n\
+\n\
+## Class and object\n\
+snippet cl\n\
+ class ${1:`Filename(\"\", \"untitled\")`} ${2}\n\
+snippet obj\n\
+ object ${1:`Filename(\"\", \"untitled\")`} ${2:inherits Parent}${3}\n\
+snippet te\n\
+ test ${1:`Filename(\"\", \"untitled\")`}\n\
+\n\
+##\n\
+## Enhancements\n\
+snippet inh\n\
+ inherits\n\
+\n\
+##\n\
+## Comments\n\
+snippet /*\n\
+ /*\n\
+ * ${1}\n\
+ */\n\
+\n\
+##\n\
+## Control Statements\n\
+snippet el\n\
+ else\n\
+snippet if\n\
+ if (${1}) ${2}\n\
+\n\
+##\n\
+## Create a Method\n\
+snippet m\n\
+ method ${1:method}(${2}) ${5}\n\
+\n\
+## \n\
+## Tests\n\
+snippet as\n\
+ assert.equals(${1:expected}, ${2:actual})\n\
+\n\
+##\n\
+## Exceptions\n\
+snippet ca\n\
+ catch ${1:e} : (${2:Exception} ) ${3}\n\
+snippet thr\n\
+ throw\n\
+snippet try\n\
+ try {\n\
+ ${3}\n\
+ } catch ${1:e} : ${2:Exception} {\n\
+ }\n\
+\n\
+##\n\
+## Javadocs\n\
+snippet /**\n\
+ /**\n\
+ * ${1}\n\
+ */\n\
+\n\
+##\n\
+## Print Methods\n\
+snippet print\n\
+ console.println(\"${1:Message}\")\n\
+\n\
+##\n\
+## Setter and Getter Methods\n\
+snippet set\n\
+ method set${1:}(${2:}) {\n\
+ $1 = $2\n\
+ }\n\
+snippet get\n\
+ method get${1:}() {\n\
+ return ${1:};\n\
+ }\n\
+\n\
+##\n\
+## Terminate Methods or Loops\n\
+snippet re\n\
+ return";
+exports.scope = "wollok";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/xml.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/xml.js
new file mode 100644
index 00000000..ee4b688a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/xml.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/xml",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "xml";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/xquery.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/xquery.js
new file mode 100644
index 00000000..c880abcf
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/xquery.js
@@ -0,0 +1,68 @@
+ace.define("ace/snippets/xquery",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText = "snippet for\n\
+ for $${1:item} in ${2:expr}\n\
+snippet return\n\
+ return ${1:expr}\n\
+snippet import\n\
+ import module namespace ${1:ns} = \"${2:http://www.example.com/}\";\n\
+snippet some\n\
+ some $${1:varname} in ${2:expr} satisfies ${3:expr}\n\
+snippet every\n\
+ every $${1:varname} in ${2:expr} satisfies ${3:expr}\n\
+snippet if\n\
+ if(${1:true}) then ${2:expr} else ${3:true}\n\
+snippet switch\n\
+ switch(${1:\"foo\"})\n\
+ case ${2:\"foo\"}\n\
+ return ${3:true}\n\
+ default return ${4:false}\n\
+snippet try\n\
+ try { ${1:expr} } catch ${2:*} { ${3:expr} }\n\
+snippet tumbling\n\
+ for tumbling window $${1:varname} in ${2:expr}\n\
+ start at $${3:start} when ${4:expr}\n\
+ end at $${5:end} when ${6:expr}\n\
+ return ${7:expr}\n\
+snippet sliding\n\
+ for sliding window $${1:varname} in ${2:expr}\n\
+ start at $${3:start} when ${4:expr}\n\
+ end at $${5:end} when ${6:expr}\n\
+ return ${7:expr}\n\
+snippet let\n\
+ let $${1:varname} := ${2:expr}\n\
+snippet group\n\
+ group by $${1:varname} := ${2:expr}\n\
+snippet order\n\
+ order by ${1:expr} ${2:descending}\n\
+snippet stable\n\
+ stable order by ${1:expr}\n\
+snippet count\n\
+ count $${1:varname}\n\
+snippet ordered\n\
+ ordered { ${1:expr} }\n\
+snippet unordered\n\
+ unordered { ${1:expr} }\n\
+snippet treat \n\
+ treat as ${1:expr}\n\
+snippet castable\n\
+ castable as ${1:atomicType}\n\
+snippet cast\n\
+ cast as ${1:atomicType}\n\
+snippet typeswitch\n\
+ typeswitch(${1:expr})\n\
+ case ${2:type} return ${3:expr}\n\
+ default return ${4:expr}\n\
+snippet var\n\
+ declare variable $${1:varname} := ${2:expr};\n\
+snippet fn\n\
+ declare function ${1:ns}:${2:name}(){\n\
+ ${3:expr}\n\
+ };\n\
+snippet module\n\
+ module namespace ${1:ns} = \"${2:http://www.example.com}\";\n\
+";
+exports.scope = "xquery";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/snippets/yaml.js b/www/wiki/extensions/CodeEditor/modules/ace/snippets/yaml.js
new file mode 100644
index 00000000..1adceabe
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/snippets/yaml.js
@@ -0,0 +1,7 @@
+ace.define("ace/snippets/yaml",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.snippetText =undefined;
+exports.scope = "yaml";
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-ambiance.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-ambiance.js
new file mode 100644
index 00000000..1e53ecd9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-ambiance.js
@@ -0,0 +1,182 @@
+ace.define("ace/theme/ambiance",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-ambiance";
+exports.cssText = ".ace-ambiance .ace_gutter {\
+background-color: #3d3d3d;\
+background-image: -moz-linear-gradient(left, #3D3D3D, #333);\
+background-image: -ms-linear-gradient(left, #3D3D3D, #333);\
+background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#3D3D3D), to(#333));\
+background-image: -webkit-linear-gradient(left, #3D3D3D, #333);\
+background-image: -o-linear-gradient(left, #3D3D3D, #333);\
+background-image: linear-gradient(left, #3D3D3D, #333);\
+background-repeat: repeat-x;\
+border-right: 1px solid #4d4d4d;\
+text-shadow: 0px 1px 1px #4d4d4d;\
+color: #222;\
+}\
+.ace-ambiance .ace_gutter-layer {\
+background: repeat left top;\
+}\
+.ace-ambiance .ace_gutter-active-line {\
+background-color: #3F3F3F;\
+}\
+.ace-ambiance .ace_fold-widget {\
+text-align: center;\
+}\
+.ace-ambiance .ace_fold-widget:hover {\
+color: #777;\
+}\
+.ace-ambiance .ace_fold-widget.ace_start,\
+.ace-ambiance .ace_fold-widget.ace_end,\
+.ace-ambiance .ace_fold-widget.ace_closed{\
+background: none;\
+border: none;\
+box-shadow: none;\
+}\
+.ace-ambiance .ace_fold-widget.ace_start:after {\
+content: '▾'\
+}\
+.ace-ambiance .ace_fold-widget.ace_end:after {\
+content: '▴'\
+}\
+.ace-ambiance .ace_fold-widget.ace_closed:after {\
+content: '‣'\
+}\
+.ace-ambiance .ace_print-margin {\
+border-left: 1px dotted #2D2D2D;\
+right: 0;\
+background: #262626;\
+}\
+.ace-ambiance .ace_scroller {\
+-webkit-box-shadow: inset 0 0 10px black;\
+-moz-box-shadow: inset 0 0 10px black;\
+-o-box-shadow: inset 0 0 10px black;\
+box-shadow: inset 0 0 10px black;\
+}\
+.ace-ambiance {\
+color: #E6E1DC;\
+background-color: #202020;\
+}\
+.ace-ambiance .ace_cursor {\
+border-left: 1px solid #7991E8;\
+}\
+.ace-ambiance .ace_overwrite-cursors .ace_cursor {\
+border: 1px solid #FFE300;\
+background: #766B13;\
+}\
+.ace-ambiance.normal-mode .ace_cursor-layer {\
+z-index: 0;\
+}\
+.ace-ambiance .ace_marker-layer .ace_selection {\
+background: rgba(221, 240, 255, 0.20);\
+}\
+.ace-ambiance .ace_marker-layer .ace_selected-word {\
+border-radius: 4px;\
+border: 8px solid #3f475d;\
+box-shadow: 0 0 4px black;\
+}\
+.ace-ambiance .ace_marker-layer .ace_step {\
+background: rgb(198, 219, 174);\
+}\
+.ace-ambiance .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(255, 255, 255, 0.25);\
+}\
+.ace-ambiance .ace_marker-layer .ace_active-line {\
+background: rgba(255, 255, 255, 0.031);\
+}\
+.ace-ambiance .ace_invisible {\
+color: #333;\
+}\
+.ace-ambiance .ace_paren {\
+color: #24C2C7;\
+}\
+.ace-ambiance .ace_keyword {\
+color: #cda869;\
+}\
+.ace-ambiance .ace_keyword.ace_operator {\
+color: #fa8d6a;\
+}\
+.ace-ambiance .ace_punctuation.ace_operator {\
+color: #fa8d6a;\
+}\
+.ace-ambiance .ace_identifier {\
+}\
+.ace-ambiance .ace-statement {\
+color: #cda869;\
+}\
+.ace-ambiance .ace_constant {\
+color: #CF7EA9;\
+}\
+.ace-ambiance .ace_constant.ace_language {\
+color: #CF7EA9;\
+}\
+.ace-ambiance .ace_constant.ace_library {\
+}\
+.ace-ambiance .ace_constant.ace_numeric {\
+color: #78CF8A;\
+}\
+.ace-ambiance .ace_invalid {\
+text-decoration: underline;\
+}\
+.ace-ambiance .ace_invalid.ace_illegal {\
+color:#F8F8F8;\
+background-color: rgba(86, 45, 86, 0.75);\
+}\
+.ace-ambiance .ace_invalid,\
+.ace-ambiance .ace_deprecated {\
+text-decoration: underline;\
+font-style: italic;\
+color: #D2A8A1;\
+}\
+.ace-ambiance .ace_support {\
+color: #9B859D;\
+}\
+.ace-ambiance .ace_support.ace_function {\
+color: #DAD085;\
+}\
+.ace-ambiance .ace_function.ace_buildin {\
+color: #9b859d;\
+}\
+.ace-ambiance .ace_string {\
+color: #8f9d6a;\
+}\
+.ace-ambiance .ace_string.ace_regexp {\
+color: #DAD085;\
+}\
+.ace-ambiance .ace_comment {\
+font-style: italic;\
+color: #555;\
+}\
+.ace-ambiance .ace_comment.ace_doc {\
+}\
+.ace-ambiance .ace_comment.ace_doc.ace_tag {\
+color: #666;\
+font-style: normal;\
+}\
+.ace-ambiance .ace_definition,\
+.ace-ambiance .ace_type {\
+color: #aac6e3;\
+}\
+.ace-ambiance .ace_variable {\
+color: #9999cc;\
+}\
+.ace-ambiance .ace_variable.ace_language {\
+color: #9b859d;\
+}\
+.ace-ambiance .ace_xml-pe {\
+color: #494949;\
+}\
+.ace-ambiance .ace_gutter-layer,\
+.ace-ambiance .ace_text-layer {\
+background-image: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAQAAAAHUWYVAABFFUlEQVQYGbzBCeDVU/74/6fj9HIcx/FRHx9JCFmzMyGRURhLZIkUsoeRfUjS2FNDtr6WkMhO9sm+S8maJfu+Jcsg+/o/c+Z4z/t97/vezy3z+z8ekGlnYICG/o7gdk+wmSHZ1z4pJItqapjoKXWahm8NmV6eOTbWUOp6/6a/XIg6GQqmenJ2lDHyvCFZ2cBDbmtHA043VFhHwXxClWmeYAdLhV00Bd85go8VmaFCkbVkzlQENzfBDZ5gtN7HwF0KDrTwJ0dypSOzpaKCMwQHKTIreYIxlmhXTzTWkVm+LTynZhiSBT3RZQ7aGfjGEd3qyXQ1FDymqbKxpspERQN2MiRjNZlFFQXfCNFm9nM1zpAsoYjmtRTc5ajwuaXc5xrWskT97RaKzAGe5ARHhVUsDbjKklziiX5WROcJwSNCNI+9w1Jwv4Zb2r7lCMZ4oq5C0EdTx+2GzNuKpJ+iFf38JEWkHJn9DNF7mmBDITrWEg0VWL3pHU20tSZnuqWu+R3BtYa8XxV1HO7GyD32UkOpL/yDloINFTmvtId+nmAjxRw40VMwVKiwrKLE4bK5UOVntYwhOcSSXKrJHKPJedocpGjVz/ZMIbnYUPB10/eKCrs5apqpgVmWzBYWpmtKHecJPjaUuEgRDDaU0oZghCJ6zNMQ5ZhDYx05r5v2muQdM0EILtXUsaKiQX9WMEUotagQzFbUNN6NUPC2nm5pxEWGCjMc3GdJHjSU2kORLK/JGSrkfGEIjncU/CYUnOipoYemwj8tST9NsJmB7TUVXtbUtXATJVZXBMvYeTXJfobgJUPmGMP/yFaWonaa6BcFO3nqcIqCozSZoZoSr1g4zJOzuyGnxTEX3lUEJ7WcZgme8ddaWvWJo2AJR9DZU3CUIbhCSG6ybSwN6qtJVnCU2svDTP2ZInOw2cBTrqtQahtNZn9NcJ4l2NaSmSkkP1noZWnVwkLmdUPOwLZEwy2Z3S3R+4rIG9hcbpPXHFVWcQdZkn2FOta3cKWQnNRC5g1LsJah4GCzSVsKnCOY5OAFRTBekyyryeyilhFKva75r4Mc0aWanGEaThcy31s439KKxTzJYY5WTHPU1FtIHjQU3Oip4xlNzj/lBw23dYZVliQa7WAXf4shetcQfatI+jWRDBPmyNeW6A1P5kdDgyYJlba0BIM8BZu1JfrFwItyjcAMR3K0BWOIrtMEXyhyrlVEx3ui5dUBjmB/Q3CXW85R4mBD0s7B+4q5tKUjOlb9qqmhi5AZ6GFIC5HXtOobdYGlVdMVbNJ8toNTFcHxnoL+muBagcctjWnbNMuR00uI7nQESwg5q2qqrKWIfrNUmeQocY6HuyxJV02wj36w00yhpmUFenv4p6fUkZYqLyuinx2RGOjhCXYyJF84oiU00YMOOhhquNdfbOB7gU88pY4xJO8LVdp6/q2voeB4R04vIdhSE40xZObx1HGGJ/ja0LBthFInKaLPPFzuCaYaoj8JjPME8yoyxo6zlBqkiUZYgq00OYMswbWO5NGmq+xhipxHLRW29ARjNKXO0wRnear8XSg4XFPLKEPUS1GqvyLwiuBUoa7zpZ0l5xxFwWmWZC1H5h5FwU8eQ7K+g8UcVY6TMQreVQT/8uQ8Z+ALIXnSEa2pYZQneE9RZbSBNYXfWYJzW/h/4j4Dp1tYVcFIC5019Vyi4ThPqSFCzjGWaHQTBU8q6vrVwgxP9Lkm840imWKpcLCjYTtrKuwvsKSnrvHCXGkSMk9p6lhckfRpIeis+N2PiszT+mFLspyGleUhDwcLrZqmyeylxwjBcKHEapqkmyangyLZRVOijwOtCY5SsG5zL0OwlCJ4y5KznF3EUNDDrinwiyLZRzOXtlBbK5ITHFGLp8Q0R6ab6mS7enI2cFrxOyHvOCFaT1HThS1krjCwqWeurCkk+willhCC+RSZnRXBiZaC5RXRIZYKp2lyfrHwiKPKR0JDzrdU2EFgpidawlFDR6FgXUMNa+g1FY3bUQh2cLCwosRdnuQTS/S+JVrGLeWIvtQUvONJxlqSQYYKpwoN2kaocLjdVsis4Mk80ESF2YpSkzwldjHkjFCUutI/r+EHDU8oCs6yzL3PhWiEooZdFMkymlas4AcI3KmoMMNSQ3tHzjGWCrcJJdYyZC7QFGwjRL9p+MrRkAGWzIaWCn9W0F3TsK01c2ZvQw0byvxuQU0r1lM0qJO7wW0kRIMdDTtXEdzi4VIh+EoIHm0mWtAtpCixlabgn83fKTI7anJe9ST7WIK1DMGpQmYeA58ImV6ezOGOzK2Kgq01pd60cKWiUi9Lievb/0vIDPHQ05Kzt4ddPckQBQtoaurjyHnek/nKzpQLrVgKPjIkh2v4uyezpv+Xoo7fPFXaGFp1vaLKxQ4uUpQQS5VuQs7BCq4xRJv7fwpVvvFEB3j+620haOuocqMhWd6TTPAEx+mdFNGHdranFe95WrWmIvlY4F1Dle2ECgc6cto7SryuqGGGha0tFQ5V53migUKmg6XKAo4qS3mik+0OZpAhOLeZKicacgaYcyx5hypYQE02ZA4xi/pNhOQxR4klNKyqacj+mpxnLTnnGSo85++3ZCZq6lrZkXlGEX3o+C9FieccJbZWVFjC0Yo1FZnJhoYMFoI1hEZ9r6hwg75HwzBNhbZCdJEfJwTPGzJvaKImw1yYX1HDAmpXR+ZJQ/SmgqMNVQb5vgamGwLtt7VwvP7Qk1xpiM5x5Cyv93E06MZmgs0Nya2azIKOYKCGBQQW97RmhKNKF02JZqHEJ4o58qp7X5EcZmc56trXEqzjCBZ1MFGR87Ql2tSTs6CGxS05PTzRQorkbw7aKoKXFDXsYW42VJih/q+FP2BdTzDTwVqOYB13liM50vG7wy28qagyuIXMeQI/Oqq8bcn5wJI50xH00CRntyfpL1T4hydYpoXgNiFzoIUTDZnLNRzh4TBHwbYGDvZkxmlyJloyr6tRihpeUG94GnKtIznREF0tzJG/OOr73JBcrSh1k6WuTprgLU+mnSGnv6Zge0NNz+kTDdH8nuAuTdJDCNb21LCiIuqlYbqGzT3RAoZofQfjFazkqeNWdYaGvYTM001EW2oKPvVk1ldUGSgUtHFwjKM1h9jnFcmy5lChoLNaQMGGDsYbKixlaMBmmsx1QjCfflwTfO/gckW0ruZ3jugKR3R5W9hGUWqCgxuFgsuaCHorotGKzGaeZB9DMsaTnKCpMtwTvOzhYk0rdrArKCqcaWmVk1+F372ur1YkKxgatI8Qfe1gIX9wE9FgS8ESmuABIXnRUbCapcKe+nO7slClSZFzpV/LkLncEb1qiO42fS3R855Su2mCLh62t1SYZZYVmKwIHjREF2uihTzB20JOkz7dkxzYQnK0UOU494wh+VWRc6Un2kpTaVgLDFEkJ/uhzRcI0YKGgpGWOlocBU/a4fKoJ/pEaNV6jip3+Es9VXY078rGnmAdf7t9ylPXS34RBSuYPs1UecZTU78WanhBCHpZ5sAoTz0LGZKjPf9TRypqWEiTvOFglL1fCEY3wY/++rbk7C8bWebA6p6om6PgOL2kp44TFJlVNBXae2rqqdZztOJpT87GQsE9jqCPIe9VReZuQ/CIgacsyZdCpIScSYqcZk8r+nsyCzhyfhOqHGOIvrLknC8wTpFcaYiGC/RU1NRbUeUpocQOnkRpGOrIOcNRx+1uA0UrzhSSt+VyS3SJpnFWkzNDqOFGIWcfR86DnmARTQ1HKIL33ExPiemeOhYSSjzlSUZZuE4TveoJLnBUOFof6KiysCbnAEcZgcUNTDOwkqWu3RWtmGpZwlHhJENdZ3miGz0lJlsKnjbwqSHQjpxnFDlTLLwqJPMZMjd7KrzkSG7VsxXBZE+F8YZkb01Oe00yyRK9psh5SYh29ySPKBo2ylNht7ZkZnsKenjKNJu9PNEyZpaCHv4Kt6RQsLvAVp7M9kIimmCUwGeWqLMmGuIotYMmWNpSahkhZw9FqZsVnKJhsjAHvtHMsTM9fCI06Dx/u3vfUXCqfsKRc4oFY2jMsoo/7DJDwZ1CsIKnJu+J9ldkpmiCxQx1rWjI+T9FwcWWzOuaYH0Hj7klNRVWEQpmaqosakiGNTFHdjS/qnUdmf0NJW5xsL0HhimCCZZSRzmSPTXJQ4aaztAwtZnoabebJ+htCaZ7Cm535ByoqXKbX1WRc4Eh2MkRXWzImVc96Cj4VdOKVxR84VdQsIUM8Psoou2byVHyZFuq7O8otbSQ2UAoeEWTudATLGSpZzVLlXVkPU2Jc+27lsw2jmg5T5VhbeE3BT083K9WsTTkFU/Osi0rC5lRlpwRHUiesNS0sOvmqGML1aRbPAxTJD9ZKtxuob+hhl8cwYGWpJ8nub7t5p6coYbMovZ1BTdaKn1jYD6h4GFDNFyT/Kqe1XCXphXHOKLZmuRSRdBPEfVUXQzJm5YGPGGJdvAEr7hHNdGZnuBvrpciGmopOLf5N0uVMy0FfYToJk90uUCbJupaVpO53UJXR2bVpoU00V2KOo4zMFrBd0Jtz2pa0clT5Q5L8IpQ177mWQejPMEJhuQjS10ref6HHjdEhy1P1EYR7GtO0uSsKJQYLiTnG1rVScj5lyazpqWGl5uBbRWl7m6ixGOOnEsMJR7z8J0n6KMnCdxhiNYQCoZ6CmYLnO8omC3MkW3bktlPmEt/VQQHejL3+dOE5FlPdK/Mq8hZxxJtLyRrepLThYKbLZxkSb5W52vYxNOaOxUF0yxMUPwBTYqCzy01XayYK0sJyWBLqX0MwU5CzoymRzV0EjjeUeLgDpTo6ij42ZAzvD01dHUUTPLU96MdLbBME8nFBn7zJCMtJcZokn8YoqU0FS5WFKyniHobguMcmW8N0XkWZjkyN3hqOMtS08r+/xTBwpZSZ3qiVRX8SzMHHjfUNFjgHEPmY9PL3ykEzxkSre/1ZD6z/NuznuB0RcE1TWTm9zRgfUWVJiG6yrzgmWPXC8EAR4Wxhlad0ZbgQyEz3pG5RVEwwDJH2mgKpjcTiCOzn1lfUWANFbZ2BA8balnEweJC9J0iuaeZoI+ippFCztEKVvckR2iice1JvhVytrQwUAZpgsubCPaU7xUe9vWnaOpaSBEspalykhC9bUlOMpT42ZHca6hyrqKmw/wMR8H5ZmdFoBVJb03O4UL0tSNnvIeRmkrLWqrs78gcrEn2tpcboh0UPOW3UUR9PMk4T4nnNKWmCjlrefhCwxRNztfmIQVdDElvS4m1/WuOujoZCs5XVOjtKPGokJzsYCtFYoWonSPT21DheU/wWhM19FcElwqNGOsp9Q8N/cwXaiND1MmeL1Q5XROtYYgGeFq1aTMsoMmcrKjQrOFQTQ1fmBYhmW6o8Jkjc7iDJRTBIo5kgJD5yMEYA3srCg7VFKwiVJkmRCc5ohGOKhsYMn/XBLdo5taZjlb9YAlGWRimqbCsoY7HFAXLa5I1HPRxMMsQDHFkWtRNniqT9UEeNjcE7RUlrCJ4R2CSJuqlKHWvJXjAUNcITYkenuBRB84TbeepcqTj3zZyFJzgYQdHnqfgI0ddUwS6GqWpsKWhjq9cV0vBAEMN2znq+EBfIWT+pClYw5xsTlJU6GeIBsjGmmANTzJZiIYpgrM0Oa8ZMjd7NP87jxhqGOhJlnQtjuQpB+8aEE00wZFznSJPyHxgH3HkPOsJFvYk8zqCHzTs1BYOa4J3PFU+UVRZxlHDM4YavlNUuMoRveiZA2d7grMNc2g+RbSCEKzmgYsUmWmazFJyoiOZ4KnyhKOGRzWJa0+moyV4TVHDzn51Awtqaphfk/lRQ08FX1iiqxTB/kLwd0VynKfEvI6cd4XMV5bMhZ7gZUWVzYQ6Nm2BYzxJbw3bGthEUUMfgbGeorae6DxHtJoZ6alhZ0+ytiVoK1R4z5PTrOECT/SugseEOlb1MMNR4VRNcJy+V1Hg9ONClSZFZjdHlc6W6FBLdJja2MC5hhpu0DBYEY1TFGwiFAxRRCsYkiM9JRb0JNMVkW6CZYT/2EiTGWmo8k+h4FhDNE7BvppoTSFnmCV5xZKzvcCdDo7VVPnIU+I+Rc68juApC90MwcFCsJ5hDqxgScYKreruyQwTqrzoqDCmhWi4IbhB0Yrt3RGa6GfDv52rKXWhh28dyZaWUvcZeMTBaZoSGyiCtRU5J8iviioHaErs7Jkj61syVzTTgOcUOQ8buFBTYWdL5g3T4qlpe0+wvD63heAXRfCCIed9RbCsp2CiI7raUOYOTU13N8PNHvpaGvayo4a3LLT1lDrVEPT2zLUlheB1R+ZTRfKWJ+dcocLJfi11vyJ51lLqJ0WD7tRwryezjiV5W28uJO9qykzX8JDe2lHl/9oyBwa2UMfOngpXCixvKdXTk3wrsKmiVYdZIqsoWEERjbcUNDuiaQomGoIbFdEHmsyWnuR+IeriKDVLnlawlyNHKwKlSU631PKep8J4Q+ayjkSLKYLhalNHlYvttb6fHm0p6OApsZ4l2VfdqZkjuysy6ysKLlckf1KUutCTs39bmCgEyyoasIWlVaMF7mgmWtBT8Kol5xpH9IGllo8cJdopcvZ2sImlDmMIbtDk3KIpeNiS08lQw11NFPTwVFlPP6pJ2gvRfI7gQUfmNAtf6Gs0wQxDsKGlVBdF8rCa3jzdwMaGHOsItrZk7hAyOzpK9VS06j5F49b0VNGOOfKs3lDToMsMBe9ZWtHFEgxTJLs7qrygKZjUnmCYoeAqeU6jqWuLJup4WghOdvCYJnrSkSzoyRkm5M2StQwVltPkfCAk58tET/CSg+8MUecmotMEnhBKfWBIZsg2ihruMJQaoIm+tkTLKEqspMh00w95gvFCQRtDwTT1gVDDSEVdlwqZfxoQRbK0g+tbiBZxzKlpnpypejdDwTaeOvorMk/IJE10h9CqRe28hhLbe0pMsdSwv4ZbhKivo2BjDWfL8UKJgeavwlwb5KlwhyE4u4XkGE2ytZCznKLCDZZq42VzT8HLCrpruFbIfOIINmh/qCdZ1ZBc65kLHR1Bkyf5zn6pN3SvGKIlFNGplhrO9QSXanLOMQTLCa0YJCRrCZm/CZmrLTm7WzCK4GJDiWUdFeYx1LCFg3NMd0XmCuF3Y5rITLDUsYS9zoHVzwnJoYpSTQoObyEzr4cFBNqYTopoaU/wkyLZ2lPhX/5Y95ulxGTV7KjhWrOZgl8MyUUafjYraNjNU1N3IWcjT5WzWqjwtoarHSUObGYO3GCJZpsBlnJGPd6ZYLyl1GdCA2625IwwJDP8GUKymbzuyPlZlvTUsaUh5zFDhRWFzPKKZLAlWdcQbObgF9tOqOsmB1dqcqYJmWstFbZRRI9poolmqiLnU0POvxScpah2iSL5UJNzgScY5+AuIbpO0YD3NCW+dLMszFSdFCWGqG6eVq2uYVNDdICGD6W7EPRWZEY5gpsE9rUkS3mijzzJnm6UpUFXG1hCUeVoS5WfNcFpblELL2qqrCvMvRfd45oalvKU2tiQ6ePJOVMRXase9iTtLJztPxJKLWpo2CRDcJwn2sWSLKIO1WQWNTCvpVUvOZhgSC40JD0dOctaSqzkCRbXsKlb11Oip6PCJ0IwSJM31j3akRxlP7Rwn6aGaUL0qiLnJkvB3xWZ2+Q1TfCwpQH3G0o92UzmX4o/oJNQMMSQc547wVHhdk+VCw01DFYEnTxzZKAm74QmeNNR1w6WzEhNK15VJzuCdxQ53dRUDws5KvwgBMOEgpcVNe0hZI6RXT1Jd0cyj5nsaEAHgVmGaJIlWdsc5Ui2ElrRR6jrRAttNMEAIWrTDFubkZaok7/AkzfIwfuWVq0jHzuCK4QabtLUMVPB3kJ0oyHTSVFlqMALilJf2Rf8k5aaHtMfayocLBS8L89oKoxpJvnAkDPa0qp5DAUTHKWmCcnthlou8iCKaFFLHWcINd1nyIwXqrSxMNmSs6KmoL2QrKuWtlQ5V0120xQ5vRyZS1rgFkWwhiOwiuQbR0OOVhQM9iS3tiXp4RawRPMp5tDletOOBL95MpM01dZTBM9pkn5qF010rIeHFcFZhmSGpYpTsI6nwhqe5C9ynhlpp5ophuRb6WcJFldkVnVEwwxVfrVkvnWUuNLCg5bgboFHPDlDPDmnK7hUrWiIbjadDclujlZcaokOFup4Ri1kacV6jmrrK1hN9bGwpKEBQ4Q6DvIUXOmo6U5LqQM6EPyiKNjVkPnJkDPNEaxhiFay5ExW1NXVUGqcpYYdPcGiCq7z/TSlbhL4pplWXKd7NZO5QQFrefhRQW/NHOsqcIglc4UhWklR8K0QzbAw08CBDnpbgqXdeD/QUsM4RZXDFBW6WJKe/mFPdH0LtBgiq57wFLzlyQzz82qYx5D5WJP5yVJDW01BfyHnS6HKO/reZqId1WGa4Hkh2kWodJ8i6KoIPlAj2hPt76CzXsVR6koPRzWTfKqIentatYpQw2me4AA3y1Kind3SwoOKZDcFXTwl9tWU6mfgRk9d71sKtlNwrjnYw5tC5n5LdKiGry3JKNlHEd3oaMCFHrazBPMp/uNJ+V7IudcSbeOIdjUEdwl0VHCOZo5t6YluEuaC9mQeMgSfOyKnYGFHcIeQ84yQWbuJYJpZw5CzglDH7gKnWqqM9ZTaXcN0TeYhR84eQtJT76JJ1lREe7WnnvsMmRc9FQ7SBBM9mV3lCUdmHk/S2RAMt0QjFNFqQpWjDPQ01DXWUdDBkXziKPjGEP3VP+zIWU2t7im41FOloyWzn/L6dkUy3VLDaZ6appgDLHPjJEsyvJngWEPUyVBiAaHCTEXwrLvSEbV1e1gKJniicWorC1MUrVjB3uDhJE/wgSOzk1DXpk0k73qCM8xw2UvD5kJmDUfOomqMpWCkJRlvKXGmoeBm18USjVIk04SClxTB6YrgLAPLWYK9HLUt5cmc0vYES8GnTeRc6skZbQkWdxRsIcyBRzx1DbTk9FbU0caTPOgJHhJKnOGIVhQqvKmo0llRw9sabrZkDtdg3PqaKi9oatjY8B+G371paMg6+mZFNNtQ04mWBq3rYLOmtWWQp8KJnpy9DdFensyjdqZ+yY40VJlH8wcdLzC8PZnvHMFUTZUrDTkLyQaGus5X5LzpYAf3i+e/ZlhqGqWhh6Ou6xTR9Z6oi5AZZtp7Mj2EEm8oSpxiYZCHU/1fbGdNNNRRoZMhmilEb2gqHOEJDtXkHK/JnG6IrvbPCwV3NhONVdS1thBMs1T4QOBcTWa2IzhMk2nW5Kyn9tXUtpv9RsG2msxk+ZsQzRQacJncpgke0+T8y5Fzj8BiGo7XlJjaTIlpQs7KFjpqGnKuoyEPeIKnFMkZHvopgh81ySxNFWvJWcKRs70j2FOT012IllEEO1n4pD1513Yg2ssQPOThOkvyrqHUdEXOSEsihmBbTbKX1kLBPWqWkLOqJbjB3GBIZmoa8qWl4CG/iZ7oiA72ZL7TJNeZUY7kFQftDcHHluBzRbCegzMtrRjVQpX2lgoPKKLJAkcbMl01XK2p7yhL8pCBbQ3BN2avJgKvttcrWDK3CiUOVxQ8ZP+pqXKyIxnmBymCg5vJjNfkPK4+c8cIfK8ocVt7kmfd/I5SR1hKvCzUtb+lhgc00ZaO6CyhIQP1Uv4yIZjload72PXX0OIJvnFU+0Zf6MhsJwTfW0r0UwQfW4LNLZl5HK261JCZ4qnBaAreVAS3WrjV0LBnNDUNNDToCEeFfwgcb4gOEqLRhirWkexrCEYKVV711DLYEE1XBEsp5tpTGjorkomKYF9FDXv7fR3BGwbettSxnyL53MBPjsxDZjMh+VUW9NRxq1DhVk+FSxQcaGjV9Pawv6eGByw5qzoy7xk4RsOShqjJwWKe/1pEEfzkobeD/dQJmpqedcyBTy2sr4nGNRH0c0SPWTLrqAc0OQcb/gemKgqucQT7ySWKCn2EUotoCvpZct7RO2sy/QW0IWcXd7pQRQyZVwT2USRO87uhjioTLKV2brpMUcMQRbKH/N2T+UlTpaMls6cmc6CCNy3JdYYSUzzJQ4oSD3oKLncULOiJvjBEC2oqnCJkJluCYy2ZQ5so9YYlZ1VLlQU1mXEW1jZERwj/MUSRc24TdexlqLKfQBtDTScJUV8FszXBEY5ktpD5Ur9hYB4Nb1iikw3JoYpkKX+RodRKFt53MMuRnKSpY31PwYaGaILh3wxJGz9TkTPEETxoCWZrgvOlmyMzxFEwVJE5xZKzvyJ4WxEc16Gd4Xe3Weq4XH2jKRikqOkGQ87hQnC7wBmGYLAnesX3M+S87eFATauuN+Qcrh7xIxXJbUIdMw3JGE3ylCWzrieaqCn4zhGM19TQ3z1oH1AX+pWEqIc7wNGAkULBo/ZxRaV9NNyh4Br3rCHZzbzmSfawBL0dNRwpW1kK9mxPXR9povcdrGSZK9c2k0xwFGzjuniCtRSZCZ6ccZ7gaktmgAOtKbG/JnOkJrjcQTdFMsxRQ2cLY3WTIrlCw1eWKn8R6pvt4GFDso3QoL4a3nLk3G6JrtME3dSenpx7PNFTmga0EaJTLQ061sEeQoWXhSo9LTXsaSjoJQRXeZLtDclbCrYzfzHHeaKjHCVOUkQHO3JeEepr56mhiyaYYKjjNU+Fed1wS5VlhWSqI/hYUdDOkaxiKehoyOnrCV5yBHtbWFqTHCCwtpDcYolesVR5yUzTZBb3RNMd0d6WP+SvhuBmRcGxnuQzT95IC285cr41cLGQ6aJJhmi4TMGempxeimBRQw1tFKV+8jd6KuzoSTqqDxzRtpZkurvKEHxlqXKRIjjfUNNXQsNOsRScoWFLT+YeRZVD3GRN0MdQcKqQjHDMrdGGVu3iYJpQx3WGUvfbmxwFfR20WBq0oYY7LMFhhgYtr8jpaEnaOzjawWWaTP8mMr0t/EPDPoqcnxTBI5o58L7uoWnMrpoqPwgVrlAUWE+V+TQl9rawoyP6QGAlQw2TPRX+YSkxyBC8Z6jhHkXBgQL7WII3DVFnRfCrBfxewv9D6xsyjys4VkhWb9pUU627JllV0YDNHMku/ldNMMXDEo4aFnAkk4U6frNEU4XgZUPmEKHUl44KrzmYamjAbh0JFvGnaTLPu1s9jPCwjFpYiN7z1DTOk/nc07CfDFzmCf7i+bfNHXhDtLeBXzTBT5rkMvWOIxpl4EMh2LGJBu2syDnAEx2naEhHDWMMzPZEhygyS1mS5RTJr5ZkoKbEUoYqr2kqdDUE8ztK7OaIntJkFrIECwv8LJTaVx5XJE86go8dFeZ3FN3rjabCAYpoYEeC9zzJVULBbmZhDyd7ko09ydpNZ3nm2Kee4FPPXHnYEF1nqOFEC08LUVcDvYXkJHW8gTaKCk9YGOeIJhqiE4ToPEepdp7IWFjdwnWaufGMwJJCMtUTTBBK9BGCOy2tGGrJTHIwyEOzp6aPzNMOtlZkDvcEWpP5SVNhfkvDxhmSazTJXYrM9U1E0xwFVwqZQwzJxw6+kGGGUj2FglGGmnb1/G51udRSMNlTw6GGnCcUwVcOpmsqTHa06o72sw1RL02p9z0VbnMLOaIX3QKaYKSCFQzBKEUNHTSc48k53RH9wxGMtpQa5KjjW0W0n6XCCCG4yxNNdhQ4R4l1Ff+2sSd6UFHiIEOyqqFgT01mEUMD+joy75jPhOA+oVVLm309FR4yVOlp4RhLiScNmSmaYF5Pw0STrOIoWMSR2UkRXOMp+M4SHW8o8Zoi6OZgjKOaFar8zZDzkWzvKOjkKBjmCXby8JahhjXULY4KlzgKLvAwxVGhvyd4zxB1d9T0piazmKLCVZY5sKiD0y2ZSYrkUEPUbIk+dlQ4SJHTR50k1DPaUWIdTZW9NJwnJMOECgd7ou/MnppMJ02O1VT4Wsh85MnZzcFTngpXGKo84qmwgKbCL/orR/SzJ2crA+t6Mp94KvxJUeIbT3CQu1uIdlQEOzlKfS3UMcrTiFmOuroocrZrT2AcmamOKg8YomeEKm/rlT2sociMaybaUlFhuqHCM2qIJ+rg4EcDFymiDSxzaHdPcpE62pD5kyM5SBMoA1PaUtfIthS85ig1VPiPPYXgYEMNk4Qq7TXBgo7oT57gPUdwgCHzhIVFPFU6OYJzHAX9m5oNrVjeE61miDrqQ4VSa1oiURTsKHC0IfjNwU2WzK6eqK8jWln4g15TVBnqmDteCJ501PGAocJhhqjZdtBEB6lnhLreFJKxmlKbeGrqLiSThVIbCdGzloasa6lpMQXHCME2boLpJgT7yWaemu6wBONbqGNVRS0PKIL7LckbjmQtR7K8I5qtqel+T/ChJTNIKLjdUMNIRyvOEko9YYl2cwQveBikCNawJKcLBbc7+JM92mysNvd/Fqp8a0k6CNEe7cnZrxlW0wQXaXjaktnRwNOGZKYiONwS7a1JVheq3WgJHlQUGKHKmp4KAxXR/ULURcNgoa4zhKSLpZR3kxRRb0NmD0OFn+UCS7CzI1nbP6+o4x47QZE5xRCt3ZagnYcvmpYQktXdk5YKXTzBC57kKEe0VVuiSYqapssMS3C9p2CKkHOg8B8Pa8p5atrIw3qezIWanMGa5HRDNF6RM9wcacl0N+Q8Z8hsIkSnaIIdHRUOEebAPy1zbCkhM062FCJtif7PU+UtoVXzWKqM1PxXO8cfdruhFQ/a6x3JKYagvVDhQEtNiyiiSQ7OsuRsZUku0CRNDs4Sog6KKjsZgk2bYJqijgsEenoKeniinRXBn/U3lgpPdyDZynQx8IiioMnCep5Ky8mjGs6Wty0l1hUQTcNWswS3WRp2kCNZwJG8omG8JphPUaFbC8lEfabwP7VtM9yoaNCAjpR41VNhrD9LkbN722v0CoZMByFzhaW+MyzRYEWFDQwN2M4/JiT76PuljT3VU/A36eaIThb+R9oZGOAJ9tewkgGvqOMNRWYjT/Cwu99Q8LqDE4TgbLWxJ1jaDDAERsFOFrobgjUsBScaguXU8kKm2RL19tRypSHnHNlHiIZqgufs4opgQdVdwxBNNFBR6kVFqb8ogimOzB6a6HTzrlDHEpYaxjiiA4TMQobkDg2vejjfwJGWmnbVFAw3H3hq2NyQfG7hz4aC+w3BbwbesG0swYayvpAs6++Ri1Vfzx93mFChvyN5xVHTS+0p9aqCAxyZ6ZacZyw5+7uuQkFPR9DDk9NOiE7X1PCYJVjVUqq7JlrHwWALF5nfHNGjApdpqgzx5OwilDhCiDYTgnc9waGW4BdLNNUQvOtpzDOWHDH8D7TR/A/85KljEQu3NREc4Pl/6B1Hhc8Umb5CsKMmGC9EPcxoT2amwHNCmeOEnOPbklnMkbOgIvO5UMOpQrS9UGVdt6iH/fURjhI/WOpaW9OKLYRod6HCUEdOX000wpDZQ6hwg6LgZfOqo1RfT/CrJzjekXOGhpc1VW71ZLbXyyp+93ILbC1kPtIEYx0FIx1VDrLoVzXRKRYWk809yYlC9ImcrinxtabKnzRJk3lAU1OLEN1j2zrYzr2myHRXJFf4h4QKT1qSTzTB5+ZNTzTRkAxX8FcLV2uS8eoQQ2aAkFzvCM72sJIcJET3WPjRk5wi32uSS9rfZajpWEvj9hW42F4o5NytSXYy8IKHay10VYdrcl4SkqscrXpMwyGOgtkajheSxdQqmpxP1L3t4R5PqasFnrQEjytq6qgp9Y09Qx9o4S1FzhUCn1kyHSzBWLemoSGvOqLNhZyBjmCaAUYpMgt4Ck7wBBMMwWKWgjsUwTaGVsxWC1mYoKiyqqeGKYqonSIRQ3KIkHO0pmAxTdBHkbOvfllfr+AA+7gnc50huVKYK393FOyg7rbPO/izI7hE4CnHHHnJ0ogNPRUGeUpsrZZTBJcrovUcJe51BPsr6GkJdhCCsZ6aTtMEb2pqWkqeVtDXE/QVggsU/Nl86d9RMF3DxvZTA58agu810RWawCiSzzXBeU3MMW9oyJUedvNEvQyNu1f10BSMddR1vaLCYpYa/mGocLSiYDcLbQz8aMn5iyF4xBNMs1P0QEOV7o5gaWGuzSeLue4tt3ro7y4Tgm4G/mopdZgl6q0o6KzJWE3mMksNr3r+a6CbT8g5wZNzT9O7fi/zpaOmnz3BRoqos+tv9zMbdpxsqDBOEewtJLt7cg5wtKKbvldpSzRRCD43VFheCI7yZLppggMVBS/KMAdHODJvOwq2NQSbKKKPLdFWQs7Fqo+mpl01JXYRgq8dnGLhTiFzqmWsUMdpllZdbKlyvSdYxhI9YghOtxR8LgSLWHK62mGGVoxzBE8LNWzqH9CUesQzFy5RQzTc56mhi6fgXEWwpKfE5Z7M05ZgZUPmo6auiv8YKzDYwWBLMErIbKHJvOwIrvEdhOBcQ9JdU1NHQ7CXn2XIDFBKU2WAgcX9UAUzDXWd5alwuyJ41Z9rjKLCL4aCp4WarhPm2rH+SaHUYE001JDZ2ZAzXPjdMpZWvC9wmqIB2lLhQ01D5jO06hghWMndbM7yRJMsoCj1vYbnFQVrW9jak3OlEJ3s/96+p33dEPRV5GxiqaGjIthUU6FFEZyqCa5qJrpBdzSw95IUnOPIrCUUjRZQFrbw5PR0R1qiYx3cb6nrWUMrBmmiBQxVHtTew5ICP/ip6g4hed/Akob/32wvBHsIOX83cI8hGeNeNPCIkPmXe8fPKx84OMSRM1MTdXSwjCZ4S30jVGhvqTRak/OVhgGazHuOCud5onEO1lJr6ecVyaOK6H7zqlBlIaHE0oroCgfvGJIdPcmfLNGLjpz7hZwZQpUbFME0A1cIJa7VNORkgfsMBatbKgwwJM9bSvQXeNOvbIjelg6WWvo5kvbKaJJNHexkKNHL9xRyFlH8Ti2riB5wVPhUk7nGkJnoCe428LR/wRGdYIlmWebCyxou1rCk4g/ShugBDX0V0ZQWkh0dOVsagkM0yV6OoLd5ye+pRlsCr0n+KiQrGuq5yJDzrTAXHtLUMduTDBVKrSm3eHL+6ijxhFDX9Z5gVU/wliHYTMiMFpKLNMEywu80wd3meoFmt6VbRMPenhrOc6DVe4pgXU8DnnHakLOIIrlF4FZPIw6R+zxBP0dyq6OOZ4Q5sLKCcz084ok+VsMMyQhNZmmBgX5xIXOEJTmi7VsGTvMTNdHHhpzdbE8Du2oKxgvBqQKdDDnTFOylCFaxR1syz2iqrOI/FEpNc3C6f11/7+ASS6l2inq2ciTrCCzgyemrCL5SVPjQkdPZUmGy2c9Sw9FtR1sS30RmsKPCS4rkIC/2U0MduwucYolGaPjKEyhzmiPYXagyWbYz8LWBDdzRimAXzxx4z8K9hpzlhLq+NiQ97HuKorMUfK/OVvC2JfiHUPCQI/q7J2gjK+tTDNxkCc4TMssqCs4TGtLVwQihyoAWgj9bosU80XGW6Ac9TJGziaUh5+hnFcHOnlaM1iRn29NaqGENTTTSUHCH2tWTeV0osUhH6psuVLjRUmGWhm6OZEshGeNowABHcJ2Bpy2ZszRcKkRXd2QuKVEeXnbfaEq825FguqfgfE2whlChSRMdron+LATTPQ2Z369t4B9C5gs/ylzv+CMmepIDPclFQl13W0rspPd1JOcbghGOEutqCv5qacURQl3dDKyvyJlqKXGPgcM9FfawJAMVmdcspcYKOZc4GjDYkFlK05olNMHyHn4zFNykyOxt99RkHlfwmiHo60l2EKI+mhreEKp080Tbug08BVPcgoqC5zWt+NLDTZ7oNSF51N1qie7Va3uCCwyZbkINf/NED6jzOsBdZjFN8oqG3wxVunqCSYYKf3EdhJyf9YWGf7tRU2oH3VHgPr1fe5J9hOgHd7xQ0y7qBwXr23aGErP0cm64JVjZwsOGqL+mhNgZmhJLW2oY4UhedsyBgzrCKrq7BmcpNVhR6jBPq64Vgi+kn6XE68pp8J5/+0wRHGOpsKenQn9DZntPzjRLZpDAdD2fnSgkG9tmIXnUwQ6WVighs7Yi2MxQ0N3CqYaCXkJ0oyOztMDJjmSSpcpvlrk0RMMOjmArQ04PRV1DO1FwhCVaUVPpKUM03JK5SxPsIWRu8/CGHi8UHChiqGFDTbSRJWeYUDDcH6vJWUxR4k1FXbMUwV6e4AJFXS8oMqsZKqzvYQ9DDQdZckY4aGsIhtlubbd2r3j4QBMoTamdPZk7O/Bf62lacZwneNjQoGcdVU7zJOd7ghsUHOkosagic6cnWc8+4gg285R6zZP5s1/LUbCKIznTwK36PkdwlOrl4U1LwfdCCa+IrvFkmgw1PCAUXKWo0sURXWcI2muKJlgyFzhynCY4RBOsqCjoI1R5zREco0n2Vt09BQtYSizgKNHfUmUrQ5UOCh51BFcLmY7umhYqXKQomOop8bUnWNNQcIiBcYaC6xzMNOS8JQQfeqKBmmglB+97ok/lfk3ygaHSyZaCRTzRxQo6GzLfa2jWBPepw+UmT7SQEJyiyRkhBLMVOfcoMjcK0eZChfUNzFAUzCsEN5vP/X1uP/n/aoMX+K+nw/Hjr/9xOo7j7Pju61tLcgvJpTWXNbfN5jLpi6VfCOviTktKlFusQixdEKWmEBUKNaIpjZRSSOXSgzaaKLdabrm1/9nZ+/f+vd/vz/v9+Xy+zZ7PRorYoZqyLrCwQdEAixxVOEXNNnjX2nUSRlkqGmWowk8lxR50JPy9Bo6qJXaXwNvREBvnThPEPrewryLhcAnj5WE15Fqi8W7R1sAuEu86S4ENikItFN4xkv9Af4nXSnUVcLiA9xzesFpivRRVeFKtsMRaKBhuSbjOELnAUtlSQUpXgdfB4Z1oSbnFEetbQ0IrAe+Y+pqnDcEJFj6S8LDZzZHwY4e3XONNlARraomNEt2bkvGsosA3ioyHm+6jCMbI59wqt4eeara28IzEmyPgoRaUOEDhTVdEJhmCoTWfC0p8aNkCp0oYqih2iqGi4yXeMkOsn4LdLLnmKfh/YogjNsPebeFGR4m9BJHLzB61XQ3BtpISfS2FugsK9FAtLWX1dCRcrCnUp44CNzuCowUZmxSRgYaE6Za0W2u/E7CVXCiI/UOR8aAm1+OSyE3mOUcwyc1zBBeoX1kiKy0Zfxck1Gsyulti11i83QTBF5Kg3pDQThFMVHiPSlK+0cSedng/VaS8bOZbtsBcTcZAR8JP5KeqQ1OYKAi20njdNNRpgnsU//K+JnaXJaGTomr7aYIphoRn9aeShJWKEq9LcozSF7QleEfDI5LYm5bgVkFkRwVDBCVu0DDIkGupo8TZBq+/pMQURYErJQmPKGKjNDkWOLx7Jd5QizdUweIaKrlP7SwJDhZvONjLkOsBBX9UpGxnydhXkfBLQ8IxgojQbLFnJf81JytSljclYYyEFyx0kVBvKWOFJmONpshGAcsduQY5giVNCV51eOdJYo/pLhbvM0uDHSevNKRcrKZIqnCtJeEsO95RoqcgGK4ocZcho1tTYtcZvH41pNQ7vA0WrhIfOSraIIntIAi+NXWCErdbkvrWwjRLrt0NKUdL6KSOscTOdMSOUtBHwL6OLA0vNSdynaWQEnCpIvKaIrJJEbvHkmuNhn6OjM8VkSGSqn1uYJCGHnq9I3aLhNME3t6GjIkO7xrNFumpyTNX/NrwX7CrIRiqqWijI9JO4d1iieykyfiposQIQ8YjjsjlBh6oHWbwRjgYJQn2NgSnNycmJAk3NiXhx44Sxykihxm8ybUwT1OVKySc7vi3OXVkdBJ4AyXBeksDXG0IhgtYY0lY5ahCD0ehborIk5aUWRJviMA7Xt5kyRjonrXENkm8yYqgs8VzgrJmClK20uMM3jRJ0FiQICQF9hdETlLQWRIb5ki6WDfWRPobvO6a4GP5mcOrNzDFELtTkONLh9dXE8xypEg7z8A9jkhrQ6Fhjlg/QVktJXxt4WXzT/03Q8IaQWSqIuEvloQ2mqC9Jfi7wRul4RX3pSPlzpoVlmCtI2jvKHCFhjcM3sN6lqF6HxnKelLjXWbwrpR4xzuCrTUZx2qq9oAh8p6ixCUGr78g8oyjRAtB5CZFwi80VerVpI0h+IeBxa6Zg6kWvpDHaioYYuEsRbDC3eOmC2JvGYLeioxGknL2UATNJN6hmtj1DlpLvDVmocYbrGCVJKOrg4X6DgddLA203BKMFngdJJFtFd7vJLm6KEpc5yjQrkk7M80SGe34X24nSex1Ra5Omgb71JKyg8SrU3i/kARKwWpH0kOGhKkObyfd0ZGjvyXlAkVZ4xRbYJ2irFMkFY1SwyWxr2oo4zlNiV+7zmaweFpT4kR3kaDAFW6xpSqzJay05FtYR4HmZhc9UxKbbfF2V8RG1MBmSaE+kmC6JnaRXK9gsiXhJHl/U0qM0WTcbyhwkYIvFGwjSbjfwhiJt8ZSQU+Bd5+marPMOkVkD0muxYLIfEuhh60x/J92itguihJSEMySVPQnTewnEm+620rTQEMsOfo4/kP/0ARvWjitlpSX7GxBgcMEsd3EEeYWvdytd+Saawi6aCIj1CkGb6Aj9rwhx16Cf3vAwFy5pyLhVonXzy51FDpdEblbkdJbUcEPDEFzQ8qNmhzzLTmmKWKbFCXeEuRabp6rxbvAtLF442QjQ+wEA9eL1xSR7Q0JXzlSHjJ4exq89yR0laScJ/FW6z4a73pFMEfDiRZvuvijIt86RaSFOl01riV2mD1UEvxGk/Geg5aWwGki1zgKPG9J2U8PEg8qYvMsZeytiTRXBMslCU8JSlxi8EabjwUldlDNLfzTUmCgxWsjqWCOHavYAqsknKFIO0yQ61VL5AVFxk6WhEaCAkdJgt9aSkzXlKNX2jEa79waYuc7gq0N3GDJGCBhoiTXUEPsdknCUE1CK0fwsiaylSF2uiDyO4XX3pFhNd7R4itFGc0k/ElBZwWvq+GC6szVeEoS/MZ+qylwpKNKv9Z469UOjqCjwlusicyTxG6VpNxcQ8IncoR4RhLbR+NdpGGmJWOcIzJGUuKPGpQg8rrG21dOMqQssJQ4RxH5jaUqnZuQ0F4Q+cjxLwPtpZbIAk3QTJHQWBE5S1BokoVtDd6lhqr9UpHSUxMcIYl9pojsb8h4SBOsMQcqvOWC2E8EVehqiJ1hrrAEbQxeK0NGZ0Gkq+guSRgniM23bIHVkqwx4hiHd7smaOyglyIyQuM978j4VS08J/A2G1KeMBRo4fBaSNhKUEZfQewVQ/C1I+MgfbEleEzCUw7mKXI0M3hd1EESVji8x5uQ41nxs1q4RMJCCXs7Iq9acpxn22oSDnQ/sJTxsCbHIYZiLyhY05TY0ZLIOQrGaSJDDN4t8pVaIrsqqFdEegtizc1iTew5Q4ayBDMUsQMkXocaYkc0hZua412siZ1rSXlR460zRJ5SlHGe5j801RLMlJTxtaOM3Q1pvxJ45zUlWFD7rsAbpfEm1JHxG0eh8w2R7QQVzBUw28FhFp5QZzq8t2rx2joqulYTWSuJdTYfWwqMFMcovFmSyJPNyLhE4E10pHzYjOC3huArRa571ZsGajQpQx38SBP5pyZB6lMU3khDnp0MBV51BE9o2E+TY5Ml2E8S7C0o6w1xvCZjf0HkVEHCzFoyNmqC+9wdcqN+Tp7jSDheE9ws8Y5V0NJCn2bk2tqSY4okdrEhx1iDN8cSudwepWmAGXKcJXK65H9to8jYQRH7SBF01ESUJdd0TayVInaWhLkOjlXE5irKGOnI6GSWGCJa482zBI9rCr0jyTVcEuzriC1vcr6mwFGSiqy5zMwxBH/TJHwjSPhL8+01kaaSUuMFKTcLEvaUePcrSmwn8DZrgikWb7CGPxkSjhQwrRk57tctmxLsb9sZvL9LSlyuSLlWkqOjwduo8b6Uv1DkmudIeFF2dHCgxVtk8dpIvHpBxhEOdhKk7OLIUSdJ+cSRY57B+0DgGUUlNfpthTfGkauzxrvTsUUaCVhlKeteTXCoJDCa2NOKhOmC4G1H8JBd4OBZReSRGkqcb/CO1PyLJTLB4j1q8JYaIutEjSLX8YKM+a6phdMsdLFUoV5RTm9JSkuDN8WcIon0NZMNZWh1q8C7SJEwV5HxrmnnTrf3KoJBlmCYI2ilSLlfEvlE4011NNgjgthzEua0oKK7JLE7HZHlEl60BLMVFewg4EWNt0ThrVNEVkkiTwpKXSWJzdRENgvKGq4IhjsiezgSFtsfCUq8qki5S1LRQeYQQ4nemmCkImWMw3tFUoUBZk4NOeZYEp4XRKTGa6wJjrWNHBVJR4m3FCnbuD6aak2WsMTh3SZImGCIPKNgsDpVwnsa70K31lCFJZYcwwSMFcQulGTsZuEaSdBXkPGZhu0FsdUO73RHjq8MPGGIfaGIbVTk6iuI3GFgucHrIQkmWSJdBd7BBu+uOryWAhY7+Lki9rK5wtEQzWwvtbqGhIMFwWRJsElsY4m9IIg9L6lCX0VklaPAYkfkZEGDnOWowlBJjtMUkcGK4Lg6EtoZInMUBVYLgn0UsdmCyCz7gIGHFfk+k1QwTh5We7A9x+IdJ6CvIkEagms0hR50eH9UnTQJ+2oiKyVlLFUE+8gBGu8MQ3CppUHesnjTHN4QB/UGPhCTHLFPHMFrCqa73gqObUJGa03wgbhHkrCfpEpzNLE7JDS25FMKhlhKKWKfCgqstLCPu1zBXy0J2ztwjtixBu8UTRn9LVtkmCN2iyFhtME70JHRQ1KVZXqKI/KNIKYMCYs1GUMEKbM1bKOI9LDXC7zbHS+bt+1MTWS9odA9DtrYtpbImQJ2VHh/lisEwaHqUk1kjKTAKknkBEXkbkdMGwq0dnhzLJF3NJH3JVwrqOB4Sca2hti75nmJN0WzxS6UxDYoEpxpa4htVlRjkYE7DZGzJVU72uC9IyhQL4i8YfGWSYLLNcHXloyz7QhNifmKSE9JgfGmuyLhc403Xm9vqcp6gXe3xuuv8F6VJNxkyTHEkHG2g0aKXL0MsXc1bGfgas2//dCONXiNLCX+5mB7eZIl1kHh7ajwpikyzlUUWOVOsjSQlsS+M0R+pPje/dzBXRZGO0rMtgQrLLG9VSu9n6CMXS3BhwYmSoIBhsjNBmZbgusE9BCPCP5triU4VhNbJfE+swSP27aayE8tuTpYYjtrYjMVGZdp2NpS1s6aBnKSHDsbKuplKbHM4a0wMFd/5/DmGyKrJSUaW4IBrqUhx0vyfzTBBLPIUcnZdrAkNsKR0sWRspumSns6Ch0v/qqIbBYUWKvPU/CFoyrDJGwSNFhbA/MlzKqjrO80hRbpKx0Jewsi/STftwGSlKc1JZyAzx05dhLEdnfQvhZOqiHWWEAHC7+30FuRcZUgaO5gpaIK+xsiHRUsqaPElTV40xQZQ107Q9BZE1nryDVGU9ZSQ47bmhBpLcYpUt7S+xuK/FiT8qKjwXYw5ypS2iuCv7q1gtgjhuBuB8LCFY5cUuCNtsQOFcT+4Ih9JX+k8Ea6v0iCIRZOtCT0Et00JW5UeC85Cg0ScK0k411HcG1zKtre3SeITBRk7WfwDhEvaYLTHP9le0m8By0JDwn4TlLW/aJOvGHxdjYUes+ScZigCkYQdNdEOhkiezgShqkx8ueKjI8lDfK2oNiOFvrZH1hS+tk7NV7nOmLHicGWEgubkXKdwdtZknCLJXaCpkrjZBtLZFsDP9CdxWsSr05Sxl6CMmoFbCOgryX40uDtamB7SVmXW4Ihlgpmq+00tBKUUa83WbjLUNkzDmY7cow1JDygyPGlhgGKYKz4vcV7QBNbJIgM11TUqZaMdwTeSguH6rOaw1JRKzaaGyxVm2EJ/uCIrVWUcZUkcp2grMsEjK+DMwS59jQk3Kd6SEq1d0S6uVmO4Bc1lDXTUcHjluCXEq+1OlBDj1pi9zgiXxnKuE0SqTXwhqbETW6RggMEnGl/q49UT2iCzgJvRwVXS2K/d6+ZkyUl7jawSVLit46EwxVljDZwoSQ20sDBihztHfk2yA8NVZghiXwrYHQdfKAOtzsayjhY9bY0yE2CWEeJ9xfzO423xhL5syS2TFJofO2pboHob0nY4GiAgRrvGQEDa/FWSsoaaYl0syRsEt3kWoH3B01shCXhTUWe9w3Bt44SC9QCh3eShQctwbaK2ApLroGCMlZrYqvlY3qYhM0aXpFkPOuoqJ3Dm6fxXrGwVF9gCWZagjPqznfkuMKQ8DPTQRO8ZqG1hPGKEm9IgpGW4DZDgTNriTxvFiq+Lz+0cKfp4wj6OCK9JSnzNSn9LFU7UhKZZMnYwcJ8s8yRsECScK4j5UOB95HFO0CzhY4xJxuCix0lDlEUeMdS6EZBkTsUkZ4K74dugyTXS7aNgL8aqjDfkCE0ZbwkCXpaWCKhl8P7VD5jxykivSyxyZrYERbe168LYu9ZYh86IkscgVLE7tWPKmJv11CgoyJltMEbrohtVAQfO4ImltiHEroYEs7RxAarVpY8AwXMcMReFOTYWe5iiLRQxJ5Q8DtJ8LQhWOhIeFESPGsILhbNDRljNbHzNRlTFbk2S3L0NOS6V1KFJYKUbSTcIIhM0wQ/s2TM0SRMNcQmSap3jCH4yhJZKSkwyRHpYYgsFeQ4U7xoCB7VVOExhXepo9ABBsYbvGWKXPME3lyH95YioZ0gssQRWWbI+FaSMkXijZXwgiTlYdPdkNLaETxlyDVIwqeaEus0aTcYcg0RVOkpR3CSJqIddK+90JCxzsDVloyrFd5ZAr4TBKfaWa6boEA7C7s6EpYaeFPjveooY72mjIccLHJ9HUwVlDhKkmutJDJBwnp1rvulJZggKDRfbXAkvC/4l3ozQOG9a8lxjx0i7nV4jSXc7vhe3OwIxjgSHjdEhhsif9YkPGlus3iLFDnWOFhtCZbJg0UbQcIaR67JjthoCyMEZRwhiXWyxO5QxI6w5NhT4U1WsJvDO60J34fW9hwzwlKij6ZAW9ne4L0s8C6XeBMEkd/LQy1VucBRot6QMlbivaBhoBgjqGiCJNhsqVp/S2SsG6DIONCR0dXhvWbJ+MRRZJkkuEjgDXJjFQW6SSL7GXK8Z2CZg7cVsbWGoKmEpzQ5elpiy8Ryg7dMkLLUEauzeO86CuwlSOlgYLojZWeJ9xM3S1PWfEfKl5ISLQ0MEKR8YOB2QfCxJBjrKPCN4f9MkaSsqoVXJBmP7EpFZ9UQfOoOFwSzBN4MQ8LsGrymlipcJQhmy0GaQjPqCHaXRwuCZwRbqK2Fg9wlClZqYicrIgMdZfxTQ0c7TBIbrChxmuzoKG8XRaSrIhhiyNFJkrC7oIAWMEOQa5aBekPCRknCo4IKPrYkvCDI8aYmY7WFtprgekcJZ3oLIqssCSMtFbQTJKwXYy3BY5oCh2iKPCpJOE+zRdpYgi6O2KmOAgvVCYaU4ySRek1sgyFhJ403QFHiVEmJHwtybO1gs8Hr5+BETQX3War0qZngYGgtVZtoqd6vFSk/UwdZElYqyjrF4HXUeFspIi9IGKf4j92pKGAdCYMVsbcV3kRF0N+R8LUd5PCsIGWoxDtBkCI0nKofdJQxT+LtZflvuc8Q3CjwWkq8KwUpHzkK/NmSsclCL0nseQdj5FRH5CNHSgtLiW80Of5HU9Hhlsga9bnBq3fEVltKfO5IaSTmGjjc4J0otcP7QsJUSQM8pEj5/wCuUuC2DWz8AAAAAElFTkSuQmCC\");\
+}\
+.ace-ambiance .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNQUFD4z6Crq/sfAAuYAuYl+7lfAAAAAElFTkSuQmCC\") right repeat-y;\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-chaos.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-chaos.js
new file mode 100644
index 00000000..97ec7fbd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-chaos.js
@@ -0,0 +1,156 @@
+ace.define("ace/theme/chaos",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-chaos";
+exports.cssText = ".ace-chaos .ace_gutter {\
+background: #141414;\
+color: #595959;\
+border-right: 1px solid #282828;\
+}\
+.ace-chaos .ace_gutter-cell.ace_warning {\
+background-image: none;\
+background: #FC0;\
+border-left: none;\
+padding-left: 0;\
+color: #000;\
+}\
+.ace-chaos .ace_gutter-cell.ace_error {\
+background-position: -6px center;\
+background-image: none;\
+background: #F10;\
+border-left: none;\
+padding-left: 0;\
+color: #000;\
+}\
+.ace-chaos .ace_print-margin {\
+border-left: 1px solid #555;\
+right: 0;\
+background: #1D1D1D;\
+}\
+.ace-chaos {\
+background-color: #161616;\
+color: #E6E1DC;\
+}\
+.ace-chaos .ace_cursor {\
+border-left: 2px solid #FFFFFF;\
+}\
+.ace-chaos .ace_cursor.ace_overwrite {\
+border-left: 0px;\
+border-bottom: 1px solid #FFFFFF;\
+}\
+.ace-chaos .ace_marker-layer .ace_selection {\
+background: #494836;\
+}\
+.ace-chaos .ace_marker-layer .ace_step {\
+background: rgb(198, 219, 174);\
+}\
+.ace-chaos .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #FCE94F;\
+}\
+.ace-chaos .ace_marker-layer .ace_active-line {\
+background: #333;\
+}\
+.ace-chaos .ace_gutter-active-line {\
+background-color: #222;\
+}\
+.ace-chaos .ace_invisible {\
+color: #404040;\
+}\
+.ace-chaos .ace_keyword {\
+color:#00698F;\
+}\
+.ace-chaos .ace_keyword.ace_operator {\
+color:#FF308F;\
+}\
+.ace-chaos .ace_constant {\
+color:#1EDAFB;\
+}\
+.ace-chaos .ace_constant.ace_language {\
+color:#FDC251;\
+}\
+.ace-chaos .ace_constant.ace_library {\
+color:#8DFF0A;\
+}\
+.ace-chaos .ace_constant.ace_numeric {\
+color:#58C554;\
+}\
+.ace-chaos .ace_invalid {\
+color:#FFFFFF;\
+background-color:#990000;\
+}\
+.ace-chaos .ace_invalid.ace_deprecated {\
+color:#FFFFFF;\
+background-color:#990000;\
+}\
+.ace-chaos .ace_support {\
+color: #999;\
+}\
+.ace-chaos .ace_support.ace_function {\
+color:#00AEEF;\
+}\
+.ace-chaos .ace_function {\
+color:#00AEEF;\
+}\
+.ace-chaos .ace_string {\
+color:#58C554;\
+}\
+.ace-chaos .ace_comment {\
+color:#555;\
+font-style:italic;\
+padding-bottom: 0px;\
+}\
+.ace-chaos .ace_variable {\
+color:#997744;\
+}\
+.ace-chaos .ace_meta.ace_tag {\
+color:#BE53E6;\
+}\
+.ace-chaos .ace_entity.ace_other.ace_attribute-name {\
+color:#FFFF89;\
+}\
+.ace-chaos .ace_markup.ace_underline {\
+text-decoration: underline;\
+}\
+.ace-chaos .ace_fold-widget {\
+text-align: center;\
+}\
+.ace-chaos .ace_fold-widget:hover {\
+color: #777;\
+}\
+.ace-chaos .ace_fold-widget.ace_start,\
+.ace-chaos .ace_fold-widget.ace_end,\
+.ace-chaos .ace_fold-widget.ace_closed{\
+background: none;\
+border: none;\
+box-shadow: none;\
+}\
+.ace-chaos .ace_fold-widget.ace_start:after {\
+content: '▾'\
+}\
+.ace-chaos .ace_fold-widget.ace_end:after {\
+content: '▴'\
+}\
+.ace-chaos .ace_fold-widget.ace_closed:after {\
+content: '‣'\
+}\
+.ace-chaos .ace_indent-guide {\
+border-right:1px dotted #333;\
+margin-right:-1px;\
+}\
+.ace-chaos .ace_fold { \
+background: #222; \
+border-radius: 3px; \
+color: #7AF; \
+border: none; \
+}\
+.ace-chaos .ace_fold:hover {\
+background: #CCC; \
+color: #000;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-chrome.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-chrome.js
new file mode 100644
index 00000000..83742aa4
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-chrome.js
@@ -0,0 +1,128 @@
+ace.define("ace/theme/chrome",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-chrome";
+exports.cssText = ".ace-chrome .ace_gutter {\
+background: #ebebeb;\
+color: #333;\
+overflow : hidden;\
+}\
+.ace-chrome .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-chrome {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-chrome .ace_cursor {\
+color: black;\
+}\
+.ace-chrome .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-chrome .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-chrome .ace_constant.ace_language {\
+color: rgb(88, 92, 246);\
+}\
+.ace-chrome .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-chrome .ace_invalid {\
+background-color: rgb(153, 0, 0);\
+color: white;\
+}\
+.ace-chrome .ace_fold {\
+}\
+.ace-chrome .ace_support.ace_function {\
+color: rgb(60, 76, 114);\
+}\
+.ace-chrome .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-chrome .ace_support.ace_type,\
+.ace-chrome .ace_support.ace_class\
+.ace-chrome .ace_support.ace_other {\
+color: rgb(109, 121, 222);\
+}\
+.ace-chrome .ace_variable.ace_parameter {\
+font-style:italic;\
+color:#FD971F;\
+}\
+.ace-chrome .ace_keyword.ace_operator {\
+color: rgb(104, 118, 135);\
+}\
+.ace-chrome .ace_comment {\
+color: #236e24;\
+}\
+.ace-chrome .ace_comment.ace_doc {\
+color: #236e24;\
+}\
+.ace-chrome .ace_comment.ace_doc.ace_tag {\
+color: #236e24;\
+}\
+.ace-chrome .ace_constant.ace_numeric {\
+color: rgb(0, 0, 205);\
+}\
+.ace-chrome .ace_variable {\
+color: rgb(49, 132, 149);\
+}\
+.ace-chrome .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-chrome .ace_entity.ace_name.ace_function {\
+color: #0000A2;\
+}\
+.ace-chrome .ace_heading {\
+color: rgb(12, 7, 255);\
+}\
+.ace-chrome .ace_list {\
+color:rgb(185, 6, 144);\
+}\
+.ace-chrome .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-chrome .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-chrome .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-chrome .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-chrome .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.07);\
+}\
+.ace-chrome .ace_gutter-active-line {\
+background-color : #dcdcdc;\
+}\
+.ace-chrome .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-chrome .ace_storage,\
+.ace-chrome .ace_keyword,\
+.ace-chrome .ace_meta.ace_tag {\
+color: rgb(147, 15, 128);\
+}\
+.ace-chrome .ace_string.ace_regex {\
+color: rgb(255, 0, 0)\
+}\
+.ace-chrome .ace_string {\
+color: #1A1AA6;\
+}\
+.ace-chrome .ace_entity.ace_other.ace_attribute-name {\
+color: #994409;\
+}\
+.ace-chrome .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-clouds.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-clouds.js
new file mode 100644
index 00000000..83d0d14d
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-clouds.js
@@ -0,0 +1,95 @@
+ace.define("ace/theme/clouds",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-clouds";
+exports.cssText = ".ace-clouds .ace_gutter {\
+background: #ebebeb;\
+color: #333\
+}\
+.ace-clouds .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8\
+}\
+.ace-clouds {\
+background-color: #FFFFFF;\
+color: #000000\
+}\
+.ace-clouds .ace_cursor {\
+color: #000000\
+}\
+.ace-clouds .ace_marker-layer .ace_selection {\
+background: #BDD5FC\
+}\
+.ace-clouds.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #FFFFFF;\
+}\
+.ace-clouds .ace_marker-layer .ace_step {\
+background: rgb(255, 255, 0)\
+}\
+.ace-clouds .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #BFBFBF\
+}\
+.ace-clouds .ace_marker-layer .ace_active-line {\
+background: #FFFBD1\
+}\
+.ace-clouds .ace_gutter-active-line {\
+background-color : #dcdcdc\
+}\
+.ace-clouds .ace_marker-layer .ace_selected-word {\
+border: 1px solid #BDD5FC\
+}\
+.ace-clouds .ace_invisible {\
+color: #BFBFBF\
+}\
+.ace-clouds .ace_keyword,\
+.ace-clouds .ace_meta,\
+.ace-clouds .ace_support.ace_constant.ace_property-value {\
+color: #AF956F\
+}\
+.ace-clouds .ace_keyword.ace_operator {\
+color: #484848\
+}\
+.ace-clouds .ace_keyword.ace_other.ace_unit {\
+color: #96DC5F\
+}\
+.ace-clouds .ace_constant.ace_language {\
+color: #39946A\
+}\
+.ace-clouds .ace_constant.ace_numeric {\
+color: #46A609\
+}\
+.ace-clouds .ace_constant.ace_character.ace_entity {\
+color: #BF78CC\
+}\
+.ace-clouds .ace_invalid {\
+background-color: #FF002A\
+}\
+.ace-clouds .ace_fold {\
+background-color: #AF956F;\
+border-color: #000000\
+}\
+.ace-clouds .ace_storage,\
+.ace-clouds .ace_support.ace_class,\
+.ace-clouds .ace_support.ace_function,\
+.ace-clouds .ace_support.ace_other,\
+.ace-clouds .ace_support.ace_type {\
+color: #C52727\
+}\
+.ace-clouds .ace_string {\
+color: #5D90CD\
+}\
+.ace-clouds .ace_comment {\
+color: #BCC8BA\
+}\
+.ace-clouds .ace_entity.ace_name.ace_tag,\
+.ace-clouds .ace_entity.ace_other.ace_attribute-name {\
+color: #606060\
+}\
+.ace-clouds .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-clouds_midnight.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-clouds_midnight.js
new file mode 100644
index 00000000..275e9f29
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-clouds_midnight.js
@@ -0,0 +1,96 @@
+ace.define("ace/theme/clouds_midnight",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-clouds-midnight";
+exports.cssText = ".ace-clouds-midnight .ace_gutter {\
+background: #232323;\
+color: #929292\
+}\
+.ace-clouds-midnight .ace_print-margin {\
+width: 1px;\
+background: #232323\
+}\
+.ace-clouds-midnight {\
+background-color: #191919;\
+color: #929292\
+}\
+.ace-clouds-midnight .ace_cursor {\
+color: #7DA5DC\
+}\
+.ace-clouds-midnight .ace_marker-layer .ace_selection {\
+background: #000000\
+}\
+.ace-clouds-midnight.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #191919;\
+}\
+.ace-clouds-midnight .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-clouds-midnight .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #BFBFBF\
+}\
+.ace-clouds-midnight .ace_marker-layer .ace_active-line {\
+background: rgba(215, 215, 215, 0.031)\
+}\
+.ace-clouds-midnight .ace_gutter-active-line {\
+background-color: rgba(215, 215, 215, 0.031)\
+}\
+.ace-clouds-midnight .ace_marker-layer .ace_selected-word {\
+border: 1px solid #000000\
+}\
+.ace-clouds-midnight .ace_invisible {\
+color: #666\
+}\
+.ace-clouds-midnight .ace_keyword,\
+.ace-clouds-midnight .ace_meta,\
+.ace-clouds-midnight .ace_support.ace_constant.ace_property-value {\
+color: #927C5D\
+}\
+.ace-clouds-midnight .ace_keyword.ace_operator {\
+color: #4B4B4B\
+}\
+.ace-clouds-midnight .ace_keyword.ace_other.ace_unit {\
+color: #366F1A\
+}\
+.ace-clouds-midnight .ace_constant.ace_language {\
+color: #39946A\
+}\
+.ace-clouds-midnight .ace_constant.ace_numeric {\
+color: #46A609\
+}\
+.ace-clouds-midnight .ace_constant.ace_character.ace_entity {\
+color: #A165AC\
+}\
+.ace-clouds-midnight .ace_invalid {\
+color: #FFFFFF;\
+background-color: #E92E2E\
+}\
+.ace-clouds-midnight .ace_fold {\
+background-color: #927C5D;\
+border-color: #929292\
+}\
+.ace-clouds-midnight .ace_storage,\
+.ace-clouds-midnight .ace_support.ace_class,\
+.ace-clouds-midnight .ace_support.ace_function,\
+.ace-clouds-midnight .ace_support.ace_other,\
+.ace-clouds-midnight .ace_support.ace_type {\
+color: #E92E2E\
+}\
+.ace-clouds-midnight .ace_string {\
+color: #5D90CD\
+}\
+.ace-clouds-midnight .ace_comment {\
+color: #3C403B\
+}\
+.ace-clouds-midnight .ace_entity.ace_name.ace_tag,\
+.ace-clouds-midnight .ace_entity.ace_other.ace_attribute-name {\
+color: #606060\
+}\
+.ace-clouds-midnight .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYHB3d/8PAAOIAdULw8qMAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-cobalt.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-cobalt.js
new file mode 100644
index 00000000..c5b6f267
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-cobalt.js
@@ -0,0 +1,113 @@
+ace.define("ace/theme/cobalt",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-cobalt";
+exports.cssText = ".ace-cobalt .ace_gutter {\
+background: #011e3a;\
+color: rgb(128,145,160)\
+}\
+.ace-cobalt .ace_print-margin {\
+width: 1px;\
+background: #555555\
+}\
+.ace-cobalt {\
+background-color: #002240;\
+color: #FFFFFF\
+}\
+.ace-cobalt .ace_cursor {\
+color: #FFFFFF\
+}\
+.ace-cobalt .ace_marker-layer .ace_selection {\
+background: rgba(179, 101, 57, 0.75)\
+}\
+.ace-cobalt.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #002240;\
+}\
+.ace-cobalt .ace_marker-layer .ace_step {\
+background: rgb(127, 111, 19)\
+}\
+.ace-cobalt .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(255, 255, 255, 0.15)\
+}\
+.ace-cobalt .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.35)\
+}\
+.ace-cobalt .ace_gutter-active-line {\
+background-color: rgba(0, 0, 0, 0.35)\
+}\
+.ace-cobalt .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(179, 101, 57, 0.75)\
+}\
+.ace-cobalt .ace_invisible {\
+color: rgba(255, 255, 255, 0.15)\
+}\
+.ace-cobalt .ace_keyword,\
+.ace-cobalt .ace_meta {\
+color: #FF9D00\
+}\
+.ace-cobalt .ace_constant,\
+.ace-cobalt .ace_constant.ace_character,\
+.ace-cobalt .ace_constant.ace_character.ace_escape,\
+.ace-cobalt .ace_constant.ace_other {\
+color: #FF628C\
+}\
+.ace-cobalt .ace_invalid {\
+color: #F8F8F8;\
+background-color: #800F00\
+}\
+.ace-cobalt .ace_support {\
+color: #80FFBB\
+}\
+.ace-cobalt .ace_support.ace_constant {\
+color: #EB939A\
+}\
+.ace-cobalt .ace_fold {\
+background-color: #FF9D00;\
+border-color: #FFFFFF\
+}\
+.ace-cobalt .ace_support.ace_function {\
+color: #FFB054\
+}\
+.ace-cobalt .ace_storage {\
+color: #FFEE80\
+}\
+.ace-cobalt .ace_entity {\
+color: #FFDD00\
+}\
+.ace-cobalt .ace_string {\
+color: #3AD900\
+}\
+.ace-cobalt .ace_string.ace_regexp {\
+color: #80FFC2\
+}\
+.ace-cobalt .ace_comment {\
+font-style: italic;\
+color: #0088FF\
+}\
+.ace-cobalt .ace_heading,\
+.ace-cobalt .ace_markup.ace_heading {\
+color: #C8E4FD;\
+background-color: #001221\
+}\
+.ace-cobalt .ace_list,\
+.ace-cobalt .ace_markup.ace_list {\
+background-color: #130D26\
+}\
+.ace-cobalt .ace_variable {\
+color: #CCCCCC\
+}\
+.ace-cobalt .ace_variable.ace_language {\
+color: #FF80E1\
+}\
+.ace-cobalt .ace_meta.ace_tag {\
+color: #9EFFFF\
+}\
+.ace-cobalt .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYHCLSvkPAAP3AgSDTRd4AAAAAElFTkSuQmCC) right repeat-y\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-crimson_editor.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-crimson_editor.js
new file mode 100644
index 00000000..a1885525
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-crimson_editor.js
@@ -0,0 +1,118 @@
+ace.define("ace/theme/crimson_editor",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+exports.isDark = false;
+exports.cssText = ".ace-crimson-editor .ace_gutter {\
+background: #ebebeb;\
+color: #333;\
+overflow : hidden;\
+}\
+.ace-crimson-editor .ace_gutter-layer {\
+width: 100%;\
+text-align: right;\
+}\
+.ace-crimson-editor .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-crimson-editor {\
+background-color: #FFFFFF;\
+color: rgb(64, 64, 64);\
+}\
+.ace-crimson-editor .ace_cursor {\
+color: black;\
+}\
+.ace-crimson-editor .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-crimson-editor .ace_identifier {\
+color: black;\
+}\
+.ace-crimson-editor .ace_keyword {\
+color: blue;\
+}\
+.ace-crimson-editor .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-crimson-editor .ace_constant.ace_language {\
+color: rgb(255, 156, 0);\
+}\
+.ace-crimson-editor .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-crimson-editor .ace_invalid {\
+text-decoration: line-through;\
+color: rgb(224, 0, 0);\
+}\
+.ace-crimson-editor .ace_fold {\
+}\
+.ace-crimson-editor .ace_support.ace_function {\
+color: rgb(192, 0, 0);\
+}\
+.ace-crimson-editor .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-crimson-editor .ace_support.ace_type,\
+.ace-crimson-editor .ace_support.ace_class {\
+color: rgb(109, 121, 222);\
+}\
+.ace-crimson-editor .ace_keyword.ace_operator {\
+color: rgb(49, 132, 149);\
+}\
+.ace-crimson-editor .ace_string {\
+color: rgb(128, 0, 128);\
+}\
+.ace-crimson-editor .ace_comment {\
+color: rgb(76, 136, 107);\
+}\
+.ace-crimson-editor .ace_comment.ace_doc {\
+color: rgb(0, 102, 255);\
+}\
+.ace-crimson-editor .ace_comment.ace_doc.ace_tag {\
+color: rgb(128, 159, 191);\
+}\
+.ace-crimson-editor .ace_constant.ace_numeric {\
+color: rgb(0, 0, 64);\
+}\
+.ace-crimson-editor .ace_variable {\
+color: rgb(0, 64, 128);\
+}\
+.ace-crimson-editor .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-crimson-editor .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-crimson-editor .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-crimson-editor .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-crimson-editor .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-crimson-editor .ace_marker-layer .ace_active-line {\
+background: rgb(232, 242, 254);\
+}\
+.ace-crimson-editor .ace_gutter-active-line {\
+background-color : #dcdcdc;\
+}\
+.ace-crimson-editor .ace_meta.ace_tag {\
+color:rgb(28, 2, 255);\
+}\
+.ace-crimson-editor .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-crimson-editor .ace_string.ace_regex {\
+color: rgb(192, 0, 192);\
+}\
+.ace-crimson-editor .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}";
+
+exports.cssClass = "ace-crimson-editor";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-dawn.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-dawn.js
new file mode 100644
index 00000000..f3c15c92
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-dawn.js
@@ -0,0 +1,108 @@
+ace.define("ace/theme/dawn",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-dawn";
+exports.cssText = ".ace-dawn .ace_gutter {\
+background: #ebebeb;\
+color: #333\
+}\
+.ace-dawn .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8\
+}\
+.ace-dawn {\
+background-color: #F9F9F9;\
+color: #080808\
+}\
+.ace-dawn .ace_cursor {\
+color: #000000\
+}\
+.ace-dawn .ace_marker-layer .ace_selection {\
+background: rgba(39, 95, 255, 0.30)\
+}\
+.ace-dawn.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #F9F9F9;\
+}\
+.ace-dawn .ace_marker-layer .ace_step {\
+background: rgb(255, 255, 0)\
+}\
+.ace-dawn .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(75, 75, 126, 0.50)\
+}\
+.ace-dawn .ace_marker-layer .ace_active-line {\
+background: rgba(36, 99, 180, 0.12)\
+}\
+.ace-dawn .ace_gutter-active-line {\
+background-color : #dcdcdc\
+}\
+.ace-dawn .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(39, 95, 255, 0.30)\
+}\
+.ace-dawn .ace_invisible {\
+color: rgba(75, 75, 126, 0.50)\
+}\
+.ace-dawn .ace_keyword,\
+.ace-dawn .ace_meta {\
+color: #794938\
+}\
+.ace-dawn .ace_constant,\
+.ace-dawn .ace_constant.ace_character,\
+.ace-dawn .ace_constant.ace_character.ace_escape,\
+.ace-dawn .ace_constant.ace_other {\
+color: #811F24\
+}\
+.ace-dawn .ace_invalid.ace_illegal {\
+text-decoration: underline;\
+font-style: italic;\
+color: #F8F8F8;\
+background-color: #B52A1D\
+}\
+.ace-dawn .ace_invalid.ace_deprecated {\
+text-decoration: underline;\
+font-style: italic;\
+color: #B52A1D\
+}\
+.ace-dawn .ace_support {\
+color: #691C97\
+}\
+.ace-dawn .ace_support.ace_constant {\
+color: #B4371F\
+}\
+.ace-dawn .ace_fold {\
+background-color: #794938;\
+border-color: #080808\
+}\
+.ace-dawn .ace_list,\
+.ace-dawn .ace_markup.ace_list,\
+.ace-dawn .ace_support.ace_function {\
+color: #693A17\
+}\
+.ace-dawn .ace_storage {\
+font-style: italic;\
+color: #A71D5D\
+}\
+.ace-dawn .ace_string {\
+color: #0B6125\
+}\
+.ace-dawn .ace_string.ace_regexp {\
+color: #CF5628\
+}\
+.ace-dawn .ace_comment {\
+font-style: italic;\
+color: #5A525F\
+}\
+.ace-dawn .ace_heading,\
+.ace-dawn .ace_markup.ace_heading {\
+color: #19356D\
+}\
+.ace-dawn .ace_variable {\
+color: #234A97\
+}\
+.ace-dawn .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYLh/5+x/AAizA4hxNNsZAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-dreamweaver.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-dreamweaver.js
new file mode 100644
index 00000000..632b1ea9
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-dreamweaver.js
@@ -0,0 +1,141 @@
+ace.define("ace/theme/dreamweaver",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+exports.isDark = false;
+exports.cssClass = "ace-dreamweaver";
+exports.cssText = ".ace-dreamweaver .ace_gutter {\
+background: #e8e8e8;\
+color: #333;\
+}\
+.ace-dreamweaver .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-dreamweaver {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-dreamweaver .ace_fold {\
+background-color: #757AD8;\
+}\
+.ace-dreamweaver .ace_cursor {\
+color: black;\
+}\
+.ace-dreamweaver .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-dreamweaver .ace_storage,\
+.ace-dreamweaver .ace_keyword {\
+color: blue;\
+}\
+.ace-dreamweaver .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-dreamweaver .ace_constant.ace_language {\
+color: rgb(88, 92, 246);\
+}\
+.ace-dreamweaver .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-dreamweaver .ace_invalid {\
+background-color: rgb(153, 0, 0);\
+color: white;\
+}\
+.ace-dreamweaver .ace_support.ace_function {\
+color: rgb(60, 76, 114);\
+}\
+.ace-dreamweaver .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-dreamweaver .ace_support.ace_type,\
+.ace-dreamweaver .ace_support.ace_class {\
+color: #009;\
+}\
+.ace-dreamweaver .ace_support.ace_php_tag {\
+color: #f00;\
+}\
+.ace-dreamweaver .ace_keyword.ace_operator {\
+color: rgb(104, 118, 135);\
+}\
+.ace-dreamweaver .ace_string {\
+color: #00F;\
+}\
+.ace-dreamweaver .ace_comment {\
+color: rgb(76, 136, 107);\
+}\
+.ace-dreamweaver .ace_comment.ace_doc {\
+color: rgb(0, 102, 255);\
+}\
+.ace-dreamweaver .ace_comment.ace_doc.ace_tag {\
+color: rgb(128, 159, 191);\
+}\
+.ace-dreamweaver .ace_constant.ace_numeric {\
+color: rgb(0, 0, 205);\
+}\
+.ace-dreamweaver .ace_variable {\
+color: #06F\
+}\
+.ace-dreamweaver .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-dreamweaver .ace_entity.ace_name.ace_function {\
+color: #00F;\
+}\
+.ace-dreamweaver .ace_heading {\
+color: rgb(12, 7, 255);\
+}\
+.ace-dreamweaver .ace_list {\
+color:rgb(185, 6, 144);\
+}\
+.ace-dreamweaver .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-dreamweaver .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-dreamweaver .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-dreamweaver .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-dreamweaver .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.07);\
+}\
+.ace-dreamweaver .ace_gutter-active-line {\
+background-color : #DCDCDC;\
+}\
+.ace-dreamweaver .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-dreamweaver .ace_meta.ace_tag {\
+color:#009;\
+}\
+.ace-dreamweaver .ace_meta.ace_tag.ace_anchor {\
+color:#060;\
+}\
+.ace-dreamweaver .ace_meta.ace_tag.ace_form {\
+color:#F90;\
+}\
+.ace-dreamweaver .ace_meta.ace_tag.ace_image {\
+color:#909;\
+}\
+.ace-dreamweaver .ace_meta.ace_tag.ace_script {\
+color:#900;\
+}\
+.ace-dreamweaver .ace_meta.ace_tag.ace_style {\
+color:#909;\
+}\
+.ace-dreamweaver .ace_meta.ace_tag.ace_table {\
+color:#099;\
+}\
+.ace-dreamweaver .ace_string.ace_regex {\
+color: rgb(255, 0, 0)\
+}\
+.ace-dreamweaver .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-eclipse.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-eclipse.js
new file mode 100644
index 00000000..63aa334c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-eclipse.js
@@ -0,0 +1,98 @@
+ace.define("ace/theme/eclipse",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+exports.isDark = false;
+exports.cssText = ".ace-eclipse .ace_gutter {\
+background: #ebebeb;\
+border-right: 1px solid rgb(159, 159, 159);\
+color: rgb(136, 136, 136);\
+}\
+.ace-eclipse .ace_print-margin {\
+width: 1px;\
+background: #ebebeb;\
+}\
+.ace-eclipse {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-eclipse .ace_fold {\
+background-color: rgb(60, 76, 114);\
+}\
+.ace-eclipse .ace_cursor {\
+color: black;\
+}\
+.ace-eclipse .ace_storage,\
+.ace-eclipse .ace_keyword,\
+.ace-eclipse .ace_variable {\
+color: rgb(127, 0, 85);\
+}\
+.ace-eclipse .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-eclipse .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-eclipse .ace_function {\
+color: rgb(60, 76, 114);\
+}\
+.ace-eclipse .ace_string {\
+color: rgb(42, 0, 255);\
+}\
+.ace-eclipse .ace_comment {\
+color: rgb(113, 150, 130);\
+}\
+.ace-eclipse .ace_comment.ace_doc {\
+color: rgb(63, 95, 191);\
+}\
+.ace-eclipse .ace_comment.ace_doc.ace_tag {\
+color: rgb(127, 159, 191);\
+}\
+.ace-eclipse .ace_constant.ace_numeric {\
+color: darkblue;\
+}\
+.ace-eclipse .ace_tag {\
+color: rgb(25, 118, 116);\
+}\
+.ace-eclipse .ace_type {\
+color: rgb(127, 0, 127);\
+}\
+.ace-eclipse .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-eclipse .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-eclipse .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-eclipse .ace_meta.ace_tag {\
+color:rgb(25, 118, 116);\
+}\
+.ace-eclipse .ace_invisible {\
+color: #ddd;\
+}\
+.ace-eclipse .ace_entity.ace_other.ace_attribute-name {\
+color:rgb(127, 0, 127);\
+}\
+.ace-eclipse .ace_marker-layer .ace_step {\
+background: rgb(255, 255, 0);\
+}\
+.ace-eclipse .ace_active-line {\
+background: rgb(232, 242, 254);\
+}\
+.ace-eclipse .ace_gutter-active-line {\
+background-color : #DADADA;\
+}\
+.ace-eclipse .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgb(181, 213, 255);\
+}\
+.ace-eclipse .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}";
+
+exports.cssClass = "ace-eclipse";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-github.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-github.js
new file mode 100644
index 00000000..d19512c6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-github.js
@@ -0,0 +1,103 @@
+ace.define("ace/theme/github",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-github";
+exports.cssText = "\
+.ace-github .ace_gutter {\
+background: #e8e8e8;\
+color: #AAA;\
+}\
+.ace-github {\
+background: #fff;\
+color: #000;\
+}\
+.ace-github .ace_keyword {\
+font-weight: bold;\
+}\
+.ace-github .ace_string {\
+color: #D14;\
+}\
+.ace-github .ace_variable.ace_class {\
+color: teal;\
+}\
+.ace-github .ace_constant.ace_numeric {\
+color: #099;\
+}\
+.ace-github .ace_constant.ace_buildin {\
+color: #0086B3;\
+}\
+.ace-github .ace_support.ace_function {\
+color: #0086B3;\
+}\
+.ace-github .ace_comment {\
+color: #998;\
+font-style: italic;\
+}\
+.ace-github .ace_variable.ace_language {\
+color: #0086B3;\
+}\
+.ace-github .ace_paren {\
+font-weight: bold;\
+}\
+.ace-github .ace_boolean {\
+font-weight: bold;\
+}\
+.ace-github .ace_string.ace_regexp {\
+color: #009926;\
+font-weight: normal;\
+}\
+.ace-github .ace_variable.ace_instance {\
+color: teal;\
+}\
+.ace-github .ace_constant.ace_language {\
+font-weight: bold;\
+}\
+.ace-github .ace_cursor {\
+color: black;\
+}\
+.ace-github.ace_focus .ace_marker-layer .ace_active-line {\
+background: rgb(255, 255, 204);\
+}\
+.ace-github .ace_marker-layer .ace_active-line {\
+background: rgb(245, 245, 245);\
+}\
+.ace-github .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-github.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px white;\
+}\
+.ace-github.ace_nobold .ace_line > span {\
+font-weight: normal !important;\
+}\
+.ace-github .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-github .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-github .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-github .ace_gutter-active-line {\
+background-color : rgba(0, 0, 0, 0.07);\
+}\
+.ace-github .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-github .ace_invisible {\
+color: #BFBFBF\
+}\
+.ace-github .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-github .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}";
+
+ var dom = require("../lib/dom");
+ dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-gob.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-gob.js
new file mode 100644
index 00000000..9023fba6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-gob.js
@@ -0,0 +1,112 @@
+ace.define("ace/theme/gob",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-gob";
+exports.cssText = ".ace-gob .ace_gutter {\
+background: #0B1818;\
+color: #03EE03\
+}\
+.ace-gob .ace_print-margin {\
+width: 1px;\
+background: #131313\
+}\
+.ace-gob {\
+background-color: #0B0B0B;\
+color: #00FF00\
+}\
+.ace-gob .ace_cursor {\
+border-color: rgba(16, 248, 255, 0.90);\
+background-color: rgba(16, 240, 248, 0.70);\
+opacity: 0.4;\
+}\
+.ace-gob .ace_marker-layer .ace_selection {\
+background: rgba(221, 240, 255, 0.20)\
+}\
+.ace-gob.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #141414;\
+}\
+.ace-gob .ace_marker-layer .ace_step {\
+background: rgb(16, 128, 0)\
+}\
+.ace-gob .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(64, 255, 255, 0.25)\
+}\
+.ace-gob .ace_marker-layer .ace_active-line {\
+background: rgba(255, 255, 255, 0.04)\
+}\
+.ace-gob .ace_gutter-active-line {\
+background-color: rgba(255, 255, 255, 0.04)\
+}\
+.ace-gob .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(192, 240, 255, 0.20)\
+}\
+.ace-gob .ace_invisible {\
+color: rgba(255, 255, 255, 0.25)\
+}\
+.ace-gob .ace_keyword,\
+.ace-gob .ace_meta {\
+color: #10D8E8\
+}\
+.ace-gob .ace_constant,\
+.ace-gob .ace_constant.ace_character,\
+.ace-gob .ace_constant.ace_character.ace_escape,\
+.ace-gob .ace_constant.ace_other,\
+.ace-gob .ace_heading,\
+.ace-gob .ace_markup.ace_heading,\
+.ace-gob .ace_support.ace_constant {\
+color: #10F0A0\
+}\
+.ace-gob .ace_invalid.ace_illegal {\
+color: #F8F8F8;\
+background-color: rgba(86, 45, 86, 0.75)\
+}\
+.ace-gob .ace_invalid.ace_deprecated {\
+text-decoration: underline;\
+font-style: italic;\
+color: #20F8C0\
+}\
+.ace-gob .ace_support {\
+color: #20E8B0\
+}\
+.ace-gob .ace_fold {\
+background-color: #50B8B8;\
+border-color: #70F8F8\
+}\
+.ace-gob .ace_support.ace_function {\
+color: #00F800\
+}\
+.ace-gob .ace_list,\
+.ace-gob .ace_markup.ace_list,\
+.ace-gob .ace_storage {\
+color: #10FF98\
+}\
+.ace-gob .ace_entity.ace_name.ace_function,\
+.ace-gob .ace_meta.ace_tag,\
+.ace-gob .ace_variable {\
+color: #00F868\
+}\
+.ace-gob .ace_string {\
+color: #10F060\
+}\
+.ace-gob .ace_string.ace_regexp {\
+color: #20F090;\
+}\
+.ace-gob .ace_comment {\
+font-style: italic;\
+color: #00E060;\
+}\
+.ace-gob .ace_variable {\
+color: #00F888;\
+}\
+.ace-gob .ace_xml-pe {\
+color: #488858;\
+}\
+.ace-gob .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQERFpYLC1tf0PAAgOAnPnhxyiAAAAAElFTkSuQmCC) right repeat-y\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-gruvbox.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-gruvbox.js
new file mode 100644
index 00000000..133ca641
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-gruvbox.js
@@ -0,0 +1,82 @@
+ace.define("ace/theme/gruvbox",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-gruvbox";
+exports.cssText = ".ace-gruvbox .ace_gutter-active-line {\
+background-color: #3C3836;\
+}\
+.ace-gruvbox {\
+color: #EBDAB4;\
+background-color: #1D2021;\
+}\
+.ace-gruvbox .ace_invisible {\
+color: #504945;\
+}\
+.ace-gruvbox .ace_marker-layer .ace_selection {\
+background: rgba(179, 101, 57, 0.75)\
+}\
+.ace-gruvbox.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #002240;\
+}\
+.ace-gruvbox .ace_keyword {\
+color: #8ec07c;\
+}\
+.ace-gruvbox .ace_comment {\
+font-style: italic;\
+color: #928375;\
+}\
+.ace-gruvbox .ace-statement {\
+color: red;\
+}\
+.ace-gruvbox .ace_variable {\
+color: #84A598;\
+}\
+.ace-gruvbox .ace_variable.ace_language {\
+color: #D2879B;\
+}\
+.ace-gruvbox .ace_constant {\
+color: #C2859A;\
+}\
+.ace-gruvbox .ace_constant.ace_language {\
+color: #C2859A;\
+}\
+.ace-gruvbox .ace_constant.ace_numeric {\
+color: #C2859A;\
+}\
+.ace-gruvbox .ace_string {\
+color: #B8BA37;\
+}\
+.ace-gruvbox .ace_support {\
+color: #F9BC41;\
+}\
+.ace-gruvbox .ace_support.ace_function {\
+color: #F84B3C;\
+}\
+.ace-gruvbox .ace_storage {\
+color: #8FBF7F;\
+}\
+.ace-gruvbox .ace_keyword.ace_operator {\
+color: #EBDAB4;\
+}\
+.ace-gruvbox .ace_punctuation.ace_operator {\
+color: yellow;\
+}\
+.ace-gruvbox .ace_marker-layer .ace_active-line {\
+background: #3C3836;\
+}\
+.ace-gruvbox .ace_marker-layer .ace_selected-word {\
+border-radius: 4px;\
+border: 8px solid #3f475d;\
+}\
+.ace-gruvbox .ace_print-margin {\
+width: 5px;\
+background: #3C3836;\
+}\
+.ace-gruvbox .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNQUFD4z6Crq/sfAAuYAuYl+7lfAAAAAElFTkSuQmCC\") right repeat-y;\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-idle_fingers.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-idle_fingers.js
new file mode 100644
index 00000000..7fcf1cbd
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-idle_fingers.js
@@ -0,0 +1,96 @@
+ace.define("ace/theme/idle_fingers",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-idle-fingers";
+exports.cssText = ".ace-idle-fingers .ace_gutter {\
+background: #3b3b3b;\
+color: rgb(153,153,153)\
+}\
+.ace-idle-fingers .ace_print-margin {\
+width: 1px;\
+background: #3b3b3b\
+}\
+.ace-idle-fingers {\
+background-color: #323232;\
+color: #FFFFFF\
+}\
+.ace-idle-fingers .ace_cursor {\
+color: #91FF00\
+}\
+.ace-idle-fingers .ace_marker-layer .ace_selection {\
+background: rgba(90, 100, 126, 0.88)\
+}\
+.ace-idle-fingers.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #323232;\
+}\
+.ace-idle-fingers .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-idle-fingers .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #404040\
+}\
+.ace-idle-fingers .ace_marker-layer .ace_active-line {\
+background: #353637\
+}\
+.ace-idle-fingers .ace_gutter-active-line {\
+background-color: #353637\
+}\
+.ace-idle-fingers .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(90, 100, 126, 0.88)\
+}\
+.ace-idle-fingers .ace_invisible {\
+color: #404040\
+}\
+.ace-idle-fingers .ace_keyword,\
+.ace-idle-fingers .ace_meta {\
+color: #CC7833\
+}\
+.ace-idle-fingers .ace_constant,\
+.ace-idle-fingers .ace_constant.ace_character,\
+.ace-idle-fingers .ace_constant.ace_character.ace_escape,\
+.ace-idle-fingers .ace_constant.ace_other,\
+.ace-idle-fingers .ace_support.ace_constant {\
+color: #6C99BB\
+}\
+.ace-idle-fingers .ace_invalid {\
+color: #FFFFFF;\
+background-color: #FF0000\
+}\
+.ace-idle-fingers .ace_fold {\
+background-color: #CC7833;\
+border-color: #FFFFFF\
+}\
+.ace-idle-fingers .ace_support.ace_function {\
+color: #B83426\
+}\
+.ace-idle-fingers .ace_variable.ace_parameter {\
+font-style: italic\
+}\
+.ace-idle-fingers .ace_string {\
+color: #A5C261\
+}\
+.ace-idle-fingers .ace_string.ace_regexp {\
+color: #CCCC33\
+}\
+.ace-idle-fingers .ace_comment {\
+font-style: italic;\
+color: #BC9458\
+}\
+.ace-idle-fingers .ace_meta.ace_tag {\
+color: #FFE5BB\
+}\
+.ace-idle-fingers .ace_entity.ace_name {\
+color: #FFC66D\
+}\
+.ace-idle-fingers .ace_collab.ace_user1 {\
+color: #323232;\
+background-color: #FFF980\
+}\
+.ace-idle-fingers .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMwMjLyZYiPj/8PAAreAwAI1+g0AAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-iplastic.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-iplastic.js
new file mode 100644
index 00000000..593aa00e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-iplastic.js
@@ -0,0 +1,121 @@
+ace.define("ace/theme/iplastic",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-iplastic";
+exports.cssText = ".ace-iplastic .ace_gutter {\
+background: #dddddd;\
+color: #666666\
+}\
+.ace-iplastic .ace_print-margin {\
+width: 1px;\
+background: #bbbbbb\
+}\
+.ace-iplastic {\
+background-color: #eeeeee;\
+color: #333333\
+}\
+.ace-iplastic .ace_cursor {\
+color: #333\
+}\
+.ace-iplastic .ace_marker-layer .ace_selection {\
+background: #BAD6FD;\
+}\
+.ace-iplastic.ace_multiselect .ace_selection.ace_start {\
+border-radius: 4px\
+}\
+.ace-iplastic .ace_marker-layer .ace_step {\
+background: #444444\
+}\
+.ace-iplastic .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #49483E;\
+background: #FFF799\
+}\
+.ace-iplastic .ace_marker-layer .ace_active-line {\
+background: #e5e5e5\
+}\
+.ace-iplastic .ace_gutter-active-line {\
+background-color: #eeeeee\
+}\
+.ace-iplastic .ace_marker-layer .ace_selected-word {\
+border: 1px solid #555555;\
+border-radius:4px\
+}\
+.ace-iplastic .ace_invisible {\
+color: #999999\
+}\
+.ace-iplastic .ace_entity.ace_name.ace_tag,\
+.ace-iplastic .ace_keyword,\
+.ace-iplastic .ace_meta.ace_tag,\
+.ace-iplastic .ace_storage {\
+color: #0000FF\
+}\
+.ace-iplastic .ace_punctuation,\
+.ace-iplastic .ace_punctuation.ace_tag {\
+color: #000\
+}\
+.ace-iplastic .ace_constant {\
+color: #333333;\
+font-weight: 700\
+}\
+.ace-iplastic .ace_constant.ace_character,\
+.ace-iplastic .ace_constant.ace_language,\
+.ace-iplastic .ace_constant.ace_numeric,\
+.ace-iplastic .ace_constant.ace_other {\
+color: #0066FF;\
+font-weight: 700\
+}\
+.ace-iplastic .ace_constant.ace_numeric{\
+font-weight: 100\
+}\
+.ace-iplastic .ace_invalid {\
+color: #F8F8F0;\
+background-color: #F92672\
+}\
+.ace-iplastic .ace_invalid.ace_deprecated {\
+color: #F8F8F0;\
+background-color: #AE81FF\
+}\
+.ace-iplastic .ace_support.ace_constant,\
+.ace-iplastic .ace_support.ace_function {\
+color: #333333;\
+font-weight: 700\
+}\
+.ace-iplastic .ace_fold {\
+background-color: #464646;\
+border-color: #F8F8F2\
+}\
+.ace-iplastic .ace_storage.ace_type,\
+.ace-iplastic .ace_support.ace_class,\
+.ace-iplastic .ace_support.ace_type {\
+color: #3333fc;\
+font-weight: 700\
+}\
+.ace-iplastic .ace_entity.ace_name.ace_function,\
+.ace-iplastic .ace_entity.ace_other,\
+.ace-iplastic .ace_entity.ace_other.ace_attribute-name,\
+.ace-iplastic .ace_variable {\
+color: #3366cc;\
+font-style: italic\
+}\
+.ace-iplastic .ace_variable.ace_parameter {\
+font-style: italic;\
+color: #2469E0\
+}\
+.ace-iplastic .ace_string {\
+color: #a55f03\
+}\
+.ace-iplastic .ace_comment {\
+color: #777777;\
+font-style: italic\
+}\
+.ace-iplastic .ace_fold-widget {\
+background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==);\
+}\
+.ace-iplastic .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKxEJbYcpXff5nwl/AV/1s+X48/Pf14L7iJIEyXYFHBPjgwsz0TKUcz5IJhGLc5o9H/LcL//wd0yLESWK5WCoU41EScY5EmozzMqUiiUKSKcUl0v9k4t8s+wM+3zUAsGo+AXuRLahdYwP2SycQWHTA4vcAAPK7b8HUKAgDgGiD4c93/+8//UegJQCAZkmScQAAXkQkLlTKsz/HCAAARKCBKrBBG/TBGCzABhzBBdzBC/xgNoRCJMTCQhBCCmSAHHJgKayCQiiGzbAdKmAv1EAdNMBRaIaTcA4uwlW4Dj1wD/phCJ7BKLyBCQRByAgTYSHaiAFiilgjjggXmYX4IcFIBBKLJCDJiBRRIkuRNUgxUopUIFVIHfI9cgI5h1xGupE7yAAygvyGvEcxlIGyUT3UDLVDuag3GoRGogvQZHQxmo8WoJvQcrQaPYw2oefQq2gP2o8+Q8cwwOgYBzPEbDAuxsNCsTgsCZNjy7EirAyrxhqwVqwDu4n1Y8+xdwQSgUXACTYEd0IgYR5BSFhMWE7YSKggHCQ0EdoJNwkDhFHCJyKTqEu0JroR+cQYYjIxh1hILCPWEo8TLxB7iEPENyQSiUMyJ7mQAkmxpFTSEtJG0m5SI+ksqZs0SBojk8naZGuyBzmULCAryIXkneTD5DPkG+Qh8lsKnWJAcaT4U+IoUspqShnlEOU05QZlmDJBVaOaUt2ooVQRNY9aQq2htlKvUYeoEzR1mjnNgxZJS6WtopXTGmgXaPdpr+h0uhHdlR5Ol9BX0svpR+iX6AP0dwwNhhWDx4hnKBmbGAcYZxl3GK+YTKYZ04sZx1QwNzHrmOeZD5lvVVgqtip8FZHKCpVKlSaVGyovVKmqpqreqgtV81XLVI+pXlN9rkZVM1PjqQnUlqtVqp1Q61MbU2epO6iHqmeob1Q/pH5Z/YkGWcNMw09DpFGgsV/jvMYgC2MZs3gsIWsNq4Z1gTXEJrHN2Xx2KruY/R27iz2qqaE5QzNKM1ezUvOUZj8H45hx+Jx0TgnnKKeX836K3hTvKeIpG6Y0TLkxZVxrqpaXllirSKtRq0frvTau7aedpr1Fu1n7gQ5Bx0onXCdHZ4/OBZ3nU9lT3acKpxZNPTr1ri6qa6UbobtEd79up+6Ynr5egJ5Mb6feeb3n+hx9L/1U/W36p/VHDFgGswwkBtsMzhg8xTVxbzwdL8fb8VFDXcNAQ6VhlWGX4YSRudE8o9VGjUYPjGnGXOMk423GbcajJgYmISZLTepN7ppSTbmmKaY7TDtMx83MzaLN1pk1mz0x1zLnm+eb15vft2BaeFostqi2uGVJsuRaplnutrxuhVo5WaVYVVpds0atna0l1rutu6cRp7lOk06rntZnw7Dxtsm2qbcZsOXYBtuutm22fWFnYhdnt8Wuw+6TvZN9un2N/T0HDYfZDqsdWh1+c7RyFDpWOt6azpzuP33F9JbpL2dYzxDP2DPjthPLKcRpnVOb00dnF2e5c4PziIuJS4LLLpc+Lpsbxt3IveRKdPVxXeF60vWdm7Obwu2o26/uNu5p7ofcn8w0nymeWTNz0MPIQ+BR5dE/C5+VMGvfrH5PQ0+BZ7XnIy9jL5FXrdewt6V3qvdh7xc+9j5yn+M+4zw33jLeWV/MN8C3yLfLT8Nvnl+F30N/I/9k/3r/0QCngCUBZwOJgUGBWwL7+Hp8Ib+OPzrbZfay2e1BjKC5QRVBj4KtguXBrSFoyOyQrSH355jOkc5pDoVQfujW0Adh5mGLw34MJ4WHhVeGP45wiFga0TGXNXfR3ENz30T6RJZE3ptnMU85ry1KNSo+qi5qPNo3ujS6P8YuZlnM1VidWElsSxw5LiquNm5svt/87fOH4p3iC+N7F5gvyF1weaHOwvSFpxapLhIsOpZATIhOOJTwQRAqqBaMJfITdyWOCnnCHcJnIi/RNtGI2ENcKh5O8kgqTXqS7JG8NXkkxTOlLOW5hCepkLxMDUzdmzqeFpp2IG0yPTq9MYOSkZBxQqohTZO2Z+pn5mZ2y6xlhbL+xW6Lty8elQfJa7OQrAVZLQq2QqboVFoo1yoHsmdlV2a/zYnKOZarnivN7cyzytuQN5zvn//tEsIS4ZK2pYZLVy0dWOa9rGo5sjxxedsK4xUFK4ZWBqw8uIq2Km3VT6vtV5eufr0mek1rgV7ByoLBtQFr6wtVCuWFfevc1+1dT1gvWd+1YfqGnRs+FYmKrhTbF5cVf9go3HjlG4dvyr+Z3JS0qavEuWTPZtJm6ebeLZ5bDpaql+aXDm4N2dq0Dd9WtO319kXbL5fNKNu7g7ZDuaO/PLi8ZafJzs07P1SkVPRU+lQ27tLdtWHX+G7R7ht7vPY07NXbW7z3/T7JvttVAVVN1WbVZftJ+7P3P66Jqun4lvttXa1ObXHtxwPSA/0HIw6217nU1R3SPVRSj9Yr60cOxx++/p3vdy0NNg1VjZzG4iNwRHnk6fcJ3/ceDTradox7rOEH0x92HWcdL2pCmvKaRptTmvtbYlu6T8w+0dbq3nr8R9sfD5w0PFl5SvNUyWna6YLTk2fyz4ydlZ19fi753GDborZ752PO32oPb++6EHTh0kX/i+c7vDvOXPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAABlJREFUeNpi+P//PwMzMzPzfwAAAAD//wMAGRsECSML/RIAAAAASUVORK5CYII=) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-katzenmilch.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-katzenmilch.js
new file mode 100644
index 00000000..f65ce4a8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-katzenmilch.js
@@ -0,0 +1,121 @@
+ace.define("ace/theme/katzenmilch",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-katzenmilch";
+exports.cssText = ".ace-katzenmilch .ace_gutter,\
+.ace-katzenmilch .ace_gutter {\
+background: #e8e8e8;\
+color: #333\
+}\
+.ace-katzenmilch .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8\
+}\
+.ace-katzenmilch {\
+background-color: #f3f2f3;\
+color: rgba(15, 0, 9, 1.0)\
+}\
+.ace-katzenmilch .ace_cursor {\
+border-left: 2px solid #100011\
+}\
+.ace-katzenmilch .ace_overwrite-cursors .ace_cursor {\
+border-left: 0px;\
+border-bottom: 1px solid #100011\
+}\
+.ace-katzenmilch .ace_marker-layer .ace_selection {\
+background: rgba(100, 5, 208, 0.27)\
+}\
+.ace-katzenmilch.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #f3f2f3;\
+}\
+.ace-katzenmilch .ace_marker-layer .ace_step {\
+background: rgb(198, 219, 174)\
+}\
+.ace-katzenmilch .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(0, 0, 0, 0.33);\
+}\
+.ace-katzenmilch .ace_marker-layer .ace_active-line {\
+background: rgb(232, 242, 254)\
+}\
+.ace-katzenmilch .ace_gutter-active-line {\
+background-color: rgb(232, 242, 254)\
+}\
+.ace-katzenmilch .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(100, 5, 208, 0.27)\
+}\
+.ace-katzenmilch .ace_invisible {\
+color: #BFBFBF\
+}\
+.ace-katzenmilch .ace_fold {\
+background-color: rgba(2, 95, 73, 0.97);\
+border-color: rgba(15, 0, 9, 1.0)\
+}\
+.ace-katzenmilch .ace_keyword {\
+color: #674Aa8;\
+rbackground-color: rgba(163, 170, 216, 0.055)\
+}\
+.ace-katzenmilch .ace_constant.ace_language {\
+color: #7D7e52;\
+rbackground-color: rgba(189, 190, 130, 0.059)\
+}\
+.ace-katzenmilch .ace_constant.ace_numeric {\
+color: rgba(79, 130, 123, 0.93);\
+rbackground-color: rgba(119, 194, 187, 0.059)\
+}\
+.ace-katzenmilch .ace_constant.ace_character,\
+.ace-katzenmilch .ace_constant.ace_other {\
+color: rgba(2, 95, 105, 1.0);\
+rbackground-color: rgba(127, 34, 153, 0.063)\
+}\
+.ace-katzenmilch .ace_support.ace_function {\
+color: #9D7e62;\
+rbackground-color: rgba(189, 190, 130, 0.039)\
+}\
+.ace-katzenmilch .ace_support.ace_class {\
+color: rgba(239, 106, 167, 1.0);\
+rbackground-color: rgba(239, 106, 167, 0.063)\
+}\
+.ace-katzenmilch .ace_storage {\
+color: rgba(123, 92, 191, 1.0);\
+rbackground-color: rgba(139, 93, 223, 0.051)\
+}\
+.ace-katzenmilch .ace_invalid {\
+color: #DFDFD5;\
+rbackground-color: #CC1B27\
+}\
+.ace-katzenmilch .ace_string {\
+color: #5a5f9b;\
+rbackground-color: rgba(170, 175, 219, 0.035)\
+}\
+.ace-katzenmilch .ace_comment {\
+font-style: italic;\
+color: rgba(64, 79, 80, 0.67);\
+rbackground-color: rgba(95, 15, 255, 0.0078)\
+}\
+.ace-katzenmilch .ace_entity.ace_name.ace_function,\
+.ace-katzenmilch .ace_variable {\
+color: rgba(2, 95, 73, 0.97);\
+rbackground-color: rgba(34, 255, 73, 0.12)\
+}\
+.ace-katzenmilch .ace_variable.ace_language {\
+color: #316fcf;\
+rbackground-color: rgba(58, 175, 255, 0.039)\
+}\
+.ace-katzenmilch .ace_variable.ace_parameter {\
+font-style: italic;\
+color: rgba(51, 150, 159, 0.87);\
+rbackground-color: rgba(5, 214, 249, 0.043)\
+}\
+.ace-katzenmilch .ace_entity.ace_other.ace_attribute-name {\
+color: rgba(73, 70, 194, 0.93);\
+rbackground-color: rgba(73, 134, 194, 0.035)\
+}\
+.ace-katzenmilch .ace_entity.ace_name.ace_tag {\
+color: #3976a2;\
+rbackground-color: rgba(73, 166, 210, 0.039)\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-kr_theme.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-kr_theme.js
new file mode 100644
index 00000000..8818b33e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-kr_theme.js
@@ -0,0 +1,104 @@
+ace.define("ace/theme/kr_theme",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-kr-theme";
+exports.cssText = ".ace-kr-theme .ace_gutter {\
+background: #1c1917;\
+color: #FCFFE0\
+}\
+.ace-kr-theme .ace_print-margin {\
+width: 1px;\
+background: #1c1917\
+}\
+.ace-kr-theme {\
+background-color: #0B0A09;\
+color: #FCFFE0\
+}\
+.ace-kr-theme .ace_cursor {\
+color: #FF9900\
+}\
+.ace-kr-theme .ace_marker-layer .ace_selection {\
+background: rgba(170, 0, 255, 0.45)\
+}\
+.ace-kr-theme.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #0B0A09;\
+}\
+.ace-kr-theme .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-kr-theme .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(255, 177, 111, 0.32)\
+}\
+.ace-kr-theme .ace_marker-layer .ace_active-line {\
+background: #38403D\
+}\
+.ace-kr-theme .ace_gutter-active-line {\
+background-color : #38403D\
+}\
+.ace-kr-theme .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(170, 0, 255, 0.45)\
+}\
+.ace-kr-theme .ace_invisible {\
+color: rgba(255, 177, 111, 0.32)\
+}\
+.ace-kr-theme .ace_keyword,\
+.ace-kr-theme .ace_meta {\
+color: #949C8B\
+}\
+.ace-kr-theme .ace_constant,\
+.ace-kr-theme .ace_constant.ace_character,\
+.ace-kr-theme .ace_constant.ace_character.ace_escape,\
+.ace-kr-theme .ace_constant.ace_other {\
+color: rgba(210, 117, 24, 0.76)\
+}\
+.ace-kr-theme .ace_invalid {\
+color: #F8F8F8;\
+background-color: #A41300\
+}\
+.ace-kr-theme .ace_support {\
+color: #9FC28A\
+}\
+.ace-kr-theme .ace_support.ace_constant {\
+color: #C27E66\
+}\
+.ace-kr-theme .ace_fold {\
+background-color: #949C8B;\
+border-color: #FCFFE0\
+}\
+.ace-kr-theme .ace_support.ace_function {\
+color: #85873A\
+}\
+.ace-kr-theme .ace_storage {\
+color: #FFEE80\
+}\
+.ace-kr-theme .ace_string {\
+color: rgba(164, 161, 181, 0.8)\
+}\
+.ace-kr-theme .ace_string.ace_regexp {\
+color: rgba(125, 255, 192, 0.65)\
+}\
+.ace-kr-theme .ace_comment {\
+font-style: italic;\
+color: #706D5B\
+}\
+.ace-kr-theme .ace_variable {\
+color: #D1A796\
+}\
+.ace-kr-theme .ace_list,\
+.ace-kr-theme .ace_markup.ace_list {\
+background-color: #0F0040\
+}\
+.ace-kr-theme .ace_variable.ace_language {\
+color: #FF80E1\
+}\
+.ace-kr-theme .ace_meta.ace_tag {\
+color: #BABD9C\
+}\
+.ace-kr-theme .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYFBXV/8PAAJoAXX4kT2EAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-kuroir.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-kuroir.js
new file mode 100644
index 00000000..30e0a8bb
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-kuroir.js
@@ -0,0 +1,61 @@
+ace.define("ace/theme/kuroir",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-kuroir";
+exports.cssText = "\
+.ace-kuroir .ace_gutter {\
+background: #e8e8e8;\
+color: #333;\
+}\
+.ace-kuroir .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-kuroir {\
+background-color: #E8E9E8;\
+color: #363636;\
+}\
+.ace-kuroir .ace_cursor {\
+color: #202020;\
+}\
+.ace-kuroir .ace_marker-layer .ace_selection {\
+background: rgba(245, 170, 0, 0.57);\
+}\
+.ace-kuroir.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #E8E9E8;\
+}\
+.ace-kuroir .ace_marker-layer .ace_step {\
+background: rgb(198, 219, 174);\
+}\
+.ace-kuroir .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(0, 0, 0, 0.29);\
+}\
+.ace-kuroir .ace_marker-layer .ace_active-line {\
+background: rgba(203, 220, 47, 0.22);\
+}\
+.ace-kuroir .ace_gutter-active-line {\
+background-color: rgba(203, 220, 47, 0.22);\
+}\
+.ace-kuroir .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(245, 170, 0, 0.57);\
+}\
+.ace-kuroir .ace_invisible {\
+color: #BFBFBF\
+}\
+.ace-kuroir .ace_fold {\
+border-color: #363636;\
+}\
+.ace-kuroir .ace_constant{color:#CD6839;}.ace-kuroir .ace_constant.ace_numeric{color:#9A5925;}.ace-kuroir .ace_support{color:#104E8B;}.ace-kuroir .ace_support.ace_function{color:#005273;}.ace-kuroir .ace_support.ace_constant{color:#CF6A4C;}.ace-kuroir .ace_storage{color:#A52A2A;}.ace-kuroir .ace_invalid.ace_illegal{color:#FD1224;\
+background-color:rgba(255, 6, 0, 0.15);}.ace-kuroir .ace_invalid.ace_deprecated{text-decoration:underline;\
+font-style:italic;\
+color:#FD1732;\
+background-color:#E8E9E8;}.ace-kuroir .ace_string{color:#639300;}.ace-kuroir .ace_string.ace_regexp{color:#417E00;\
+background-color:#C9D4BE;}.ace-kuroir .ace_comment{color:rgba(148, 148, 148, 0.91);\
+background-color:rgba(220, 220, 220, 0.56);}.ace-kuroir .ace_variable{color:#009ACD;}.ace-kuroir .ace_meta.ace_tag{color:#005273;}.ace-kuroir .ace_markup.ace_heading{color:#B8012D;\
+background-color:rgba(191, 97, 51, 0.051);}.ace-kuroir .ace_markup.ace_list{color:#8F5B26;}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore.js
new file mode 100644
index 00000000..fc0a72f1
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore.js
@@ -0,0 +1,95 @@
+ace.define("ace/theme/merbivore",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-merbivore";
+exports.cssText = ".ace-merbivore .ace_gutter {\
+background: #202020;\
+color: #E6E1DC\
+}\
+.ace-merbivore .ace_print-margin {\
+width: 1px;\
+background: #555651\
+}\
+.ace-merbivore {\
+background-color: #161616;\
+color: #E6E1DC\
+}\
+.ace-merbivore .ace_cursor {\
+color: #FFFFFF\
+}\
+.ace-merbivore .ace_marker-layer .ace_selection {\
+background: #454545\
+}\
+.ace-merbivore.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #161616;\
+}\
+.ace-merbivore .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-merbivore .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #404040\
+}\
+.ace-merbivore .ace_marker-layer .ace_active-line {\
+background: #333435\
+}\
+.ace-merbivore .ace_gutter-active-line {\
+background-color: #333435\
+}\
+.ace-merbivore .ace_marker-layer .ace_selected-word {\
+border: 1px solid #454545\
+}\
+.ace-merbivore .ace_invisible {\
+color: #404040\
+}\
+.ace-merbivore .ace_entity.ace_name.ace_tag,\
+.ace-merbivore .ace_keyword,\
+.ace-merbivore .ace_meta,\
+.ace-merbivore .ace_meta.ace_tag,\
+.ace-merbivore .ace_storage,\
+.ace-merbivore .ace_support.ace_function {\
+color: #FC6F09\
+}\
+.ace-merbivore .ace_constant,\
+.ace-merbivore .ace_constant.ace_character,\
+.ace-merbivore .ace_constant.ace_character.ace_escape,\
+.ace-merbivore .ace_constant.ace_other,\
+.ace-merbivore .ace_support.ace_type {\
+color: #1EDAFB\
+}\
+.ace-merbivore .ace_constant.ace_character.ace_escape {\
+color: #519F50\
+}\
+.ace-merbivore .ace_constant.ace_language {\
+color: #FDC251\
+}\
+.ace-merbivore .ace_constant.ace_library,\
+.ace-merbivore .ace_string,\
+.ace-merbivore .ace_support.ace_constant {\
+color: #8DFF0A\
+}\
+.ace-merbivore .ace_constant.ace_numeric {\
+color: #58C554\
+}\
+.ace-merbivore .ace_invalid {\
+color: #FFFFFF;\
+background-color: #990000\
+}\
+.ace-merbivore .ace_fold {\
+background-color: #FC6F09;\
+border-color: #E6E1DC\
+}\
+.ace-merbivore .ace_comment {\
+font-style: italic;\
+color: #AD2EA4\
+}\
+.ace-merbivore .ace_entity.ace_other.ace_attribute-name {\
+color: #FFFF89\
+}\
+.ace-merbivore .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQFxf3ZXB1df0PAAdsAmERTkEHAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore_soft.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore_soft.js
new file mode 100644
index 00000000..eff24646
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-merbivore_soft.js
@@ -0,0 +1,96 @@
+ace.define("ace/theme/merbivore_soft",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-merbivore-soft";
+exports.cssText = ".ace-merbivore-soft .ace_gutter {\
+background: #262424;\
+color: #E6E1DC\
+}\
+.ace-merbivore-soft .ace_print-margin {\
+width: 1px;\
+background: #262424\
+}\
+.ace-merbivore-soft {\
+background-color: #1C1C1C;\
+color: #E6E1DC\
+}\
+.ace-merbivore-soft .ace_cursor {\
+color: #FFFFFF\
+}\
+.ace-merbivore-soft .ace_marker-layer .ace_selection {\
+background: #494949\
+}\
+.ace-merbivore-soft.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #1C1C1C;\
+}\
+.ace-merbivore-soft .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-merbivore-soft .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #404040\
+}\
+.ace-merbivore-soft .ace_marker-layer .ace_active-line {\
+background: #333435\
+}\
+.ace-merbivore-soft .ace_gutter-active-line {\
+background-color: #333435\
+}\
+.ace-merbivore-soft .ace_marker-layer .ace_selected-word {\
+border: 1px solid #494949\
+}\
+.ace-merbivore-soft .ace_invisible {\
+color: #404040\
+}\
+.ace-merbivore-soft .ace_entity.ace_name.ace_tag,\
+.ace-merbivore-soft .ace_keyword,\
+.ace-merbivore-soft .ace_meta,\
+.ace-merbivore-soft .ace_meta.ace_tag,\
+.ace-merbivore-soft .ace_storage {\
+color: #FC803A\
+}\
+.ace-merbivore-soft .ace_constant,\
+.ace-merbivore-soft .ace_constant.ace_character,\
+.ace-merbivore-soft .ace_constant.ace_character.ace_escape,\
+.ace-merbivore-soft .ace_constant.ace_other,\
+.ace-merbivore-soft .ace_support.ace_type {\
+color: #68C1D8\
+}\
+.ace-merbivore-soft .ace_constant.ace_character.ace_escape {\
+color: #B3E5B4\
+}\
+.ace-merbivore-soft .ace_constant.ace_language {\
+color: #E1C582\
+}\
+.ace-merbivore-soft .ace_constant.ace_library,\
+.ace-merbivore-soft .ace_string,\
+.ace-merbivore-soft .ace_support.ace_constant {\
+color: #8EC65F\
+}\
+.ace-merbivore-soft .ace_constant.ace_numeric {\
+color: #7FC578\
+}\
+.ace-merbivore-soft .ace_invalid,\
+.ace-merbivore-soft .ace_invalid.ace_deprecated {\
+color: #FFFFFF;\
+background-color: #FE3838\
+}\
+.ace-merbivore-soft .ace_fold {\
+background-color: #FC803A;\
+border-color: #E6E1DC\
+}\
+.ace-merbivore-soft .ace_comment,\
+.ace-merbivore-soft .ace_meta {\
+font-style: italic;\
+color: #AC4BB8\
+}\
+.ace-merbivore-soft .ace_entity.ace_other.ace_attribute-name {\
+color: #EAF1A3\
+}\
+.ace-merbivore-soft .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWOQkpLyZfD09PwPAAfYAnaStpHRAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-mono_industrial.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-mono_industrial.js
new file mode 100644
index 00000000..0ece0309
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-mono_industrial.js
@@ -0,0 +1,107 @@
+ace.define("ace/theme/mono_industrial",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-mono-industrial";
+exports.cssText = ".ace-mono-industrial .ace_gutter {\
+background: #1d2521;\
+color: #C5C9C9\
+}\
+.ace-mono-industrial .ace_print-margin {\
+width: 1px;\
+background: #555651\
+}\
+.ace-mono-industrial {\
+background-color: #222C28;\
+color: #FFFFFF\
+}\
+.ace-mono-industrial .ace_cursor {\
+color: #FFFFFF\
+}\
+.ace-mono-industrial .ace_marker-layer .ace_selection {\
+background: rgba(145, 153, 148, 0.40)\
+}\
+.ace-mono-industrial.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #222C28;\
+}\
+.ace-mono-industrial .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-mono-industrial .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(102, 108, 104, 0.50)\
+}\
+.ace-mono-industrial .ace_marker-layer .ace_active-line {\
+background: rgba(12, 13, 12, 0.25)\
+}\
+.ace-mono-industrial .ace_gutter-active-line {\
+background-color: rgba(12, 13, 12, 0.25)\
+}\
+.ace-mono-industrial .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(145, 153, 148, 0.40)\
+}\
+.ace-mono-industrial .ace_invisible {\
+color: rgba(102, 108, 104, 0.50)\
+}\
+.ace-mono-industrial .ace_string {\
+background-color: #151C19;\
+color: #FFFFFF\
+}\
+.ace-mono-industrial .ace_keyword,\
+.ace-mono-industrial .ace_meta {\
+color: #A39E64\
+}\
+.ace-mono-industrial .ace_constant,\
+.ace-mono-industrial .ace_constant.ace_character,\
+.ace-mono-industrial .ace_constant.ace_character.ace_escape,\
+.ace-mono-industrial .ace_constant.ace_numeric,\
+.ace-mono-industrial .ace_constant.ace_other {\
+color: #E98800\
+}\
+.ace-mono-industrial .ace_entity.ace_name.ace_function,\
+.ace-mono-industrial .ace_keyword.ace_operator,\
+.ace-mono-industrial .ace_variable {\
+color: #A8B3AB\
+}\
+.ace-mono-industrial .ace_invalid {\
+color: #FFFFFF;\
+background-color: rgba(153, 0, 0, 0.68)\
+}\
+.ace-mono-industrial .ace_support.ace_constant {\
+color: #C87500\
+}\
+.ace-mono-industrial .ace_fold {\
+background-color: #A8B3AB;\
+border-color: #FFFFFF\
+}\
+.ace-mono-industrial .ace_support.ace_function {\
+color: #588E60\
+}\
+.ace-mono-industrial .ace_entity.ace_name,\
+.ace-mono-industrial .ace_support.ace_class,\
+.ace-mono-industrial .ace_support.ace_type {\
+color: #5778B6\
+}\
+.ace-mono-industrial .ace_storage {\
+color: #C23B00\
+}\
+.ace-mono-industrial .ace_variable.ace_language,\
+.ace-mono-industrial .ace_variable.ace_parameter {\
+color: #648BD2\
+}\
+.ace-mono-industrial .ace_comment {\
+color: #666C68;\
+background-color: #151C19\
+}\
+.ace-mono-industrial .ace_entity.ace_other.ace_attribute-name {\
+color: #909993\
+}\
+.ace-mono-industrial .ace_entity.ace_name.ace_tag {\
+color: #A65EFF\
+}\
+.ace-mono-industrial .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNQ1NbwZfALD/4PAAlTArlEC4r/AAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-monokai.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-monokai.js
new file mode 100644
index 00000000..322c2fa8
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-monokai.js
@@ -0,0 +1,105 @@
+ace.define("ace/theme/monokai",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-monokai";
+exports.cssText = ".ace-monokai .ace_gutter {\
+background: #2F3129;\
+color: #8F908A\
+}\
+.ace-monokai .ace_print-margin {\
+width: 1px;\
+background: #555651\
+}\
+.ace-monokai {\
+background-color: #272822;\
+color: #F8F8F2\
+}\
+.ace-monokai .ace_cursor {\
+color: #F8F8F0\
+}\
+.ace-monokai .ace_marker-layer .ace_selection {\
+background: #49483E\
+}\
+.ace-monokai.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #272822;\
+}\
+.ace-monokai .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-monokai .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #49483E\
+}\
+.ace-monokai .ace_marker-layer .ace_active-line {\
+background: #202020\
+}\
+.ace-monokai .ace_gutter-active-line {\
+background-color: #272727\
+}\
+.ace-monokai .ace_marker-layer .ace_selected-word {\
+border: 1px solid #49483E\
+}\
+.ace-monokai .ace_invisible {\
+color: #52524d\
+}\
+.ace-monokai .ace_entity.ace_name.ace_tag,\
+.ace-monokai .ace_keyword,\
+.ace-monokai .ace_meta.ace_tag,\
+.ace-monokai .ace_storage {\
+color: #F92672\
+}\
+.ace-monokai .ace_punctuation,\
+.ace-monokai .ace_punctuation.ace_tag {\
+color: #fff\
+}\
+.ace-monokai .ace_constant.ace_character,\
+.ace-monokai .ace_constant.ace_language,\
+.ace-monokai .ace_constant.ace_numeric,\
+.ace-monokai .ace_constant.ace_other {\
+color: #AE81FF\
+}\
+.ace-monokai .ace_invalid {\
+color: #F8F8F0;\
+background-color: #F92672\
+}\
+.ace-monokai .ace_invalid.ace_deprecated {\
+color: #F8F8F0;\
+background-color: #AE81FF\
+}\
+.ace-monokai .ace_support.ace_constant,\
+.ace-monokai .ace_support.ace_function {\
+color: #66D9EF\
+}\
+.ace-monokai .ace_fold {\
+background-color: #A6E22E;\
+border-color: #F8F8F2\
+}\
+.ace-monokai .ace_storage.ace_type,\
+.ace-monokai .ace_support.ace_class,\
+.ace-monokai .ace_support.ace_type {\
+font-style: italic;\
+color: #66D9EF\
+}\
+.ace-monokai .ace_entity.ace_name.ace_function,\
+.ace-monokai .ace_entity.ace_other,\
+.ace-monokai .ace_entity.ace_other.ace_attribute-name,\
+.ace-monokai .ace_variable {\
+color: #A6E22E\
+}\
+.ace-monokai .ace_variable.ace_parameter {\
+font-style: italic;\
+color: #FD971F\
+}\
+.ace-monokai .ace_string {\
+color: #E6DB74\
+}\
+.ace-monokai .ace_comment {\
+color: #75715E\
+}\
+.ace-monokai .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWPQ0FD0ZXBzd/wPAAjVAoxeSgNeAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-pastel_on_dark.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-pastel_on_dark.js
new file mode 100644
index 00000000..2631ae00
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-pastel_on_dark.js
@@ -0,0 +1,108 @@
+ace.define("ace/theme/pastel_on_dark",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-pastel-on-dark";
+exports.cssText = ".ace-pastel-on-dark .ace_gutter {\
+background: #353030;\
+color: #8F938F\
+}\
+.ace-pastel-on-dark .ace_print-margin {\
+width: 1px;\
+background: #353030\
+}\
+.ace-pastel-on-dark {\
+background-color: #2C2828;\
+color: #8F938F\
+}\
+.ace-pastel-on-dark .ace_cursor {\
+color: #A7A7A7\
+}\
+.ace-pastel-on-dark .ace_marker-layer .ace_selection {\
+background: rgba(221, 240, 255, 0.20)\
+}\
+.ace-pastel-on-dark.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #2C2828;\
+}\
+.ace-pastel-on-dark .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-pastel-on-dark .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(255, 255, 255, 0.25)\
+}\
+.ace-pastel-on-dark .ace_marker-layer .ace_active-line {\
+background: rgba(255, 255, 255, 0.031)\
+}\
+.ace-pastel-on-dark .ace_gutter-active-line {\
+background-color: rgba(255, 255, 255, 0.031)\
+}\
+.ace-pastel-on-dark .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(221, 240, 255, 0.20)\
+}\
+.ace-pastel-on-dark .ace_invisible {\
+color: rgba(255, 255, 255, 0.25)\
+}\
+.ace-pastel-on-dark .ace_keyword,\
+.ace-pastel-on-dark .ace_meta {\
+color: #757aD8\
+}\
+.ace-pastel-on-dark .ace_constant,\
+.ace-pastel-on-dark .ace_constant.ace_character,\
+.ace-pastel-on-dark .ace_constant.ace_character.ace_escape,\
+.ace-pastel-on-dark .ace_constant.ace_other {\
+color: #4FB7C5\
+}\
+.ace-pastel-on-dark .ace_keyword.ace_operator {\
+color: #797878\
+}\
+.ace-pastel-on-dark .ace_constant.ace_character {\
+color: #AFA472\
+}\
+.ace-pastel-on-dark .ace_constant.ace_language {\
+color: #DE8E30\
+}\
+.ace-pastel-on-dark .ace_constant.ace_numeric {\
+color: #CCCCCC\
+}\
+.ace-pastel-on-dark .ace_invalid,\
+.ace-pastel-on-dark .ace_invalid.ace_illegal {\
+color: #F8F8F8;\
+background-color: rgba(86, 45, 86, 0.75)\
+}\
+.ace-pastel-on-dark .ace_invalid.ace_deprecated {\
+text-decoration: underline;\
+font-style: italic;\
+color: #D2A8A1\
+}\
+.ace-pastel-on-dark .ace_fold {\
+background-color: #757aD8;\
+border-color: #8F938F\
+}\
+.ace-pastel-on-dark .ace_support.ace_function {\
+color: #AEB2F8\
+}\
+.ace-pastel-on-dark .ace_string {\
+color: #66A968\
+}\
+.ace-pastel-on-dark .ace_string.ace_regexp {\
+color: #E9C062\
+}\
+.ace-pastel-on-dark .ace_comment {\
+color: #A6C6FF\
+}\
+.ace-pastel-on-dark .ace_variable {\
+color: #BEBF55\
+}\
+.ace-pastel-on-dark .ace_variable.ace_language {\
+color: #C1C144\
+}\
+.ace-pastel-on-dark .ace_xml-pe {\
+color: #494949\
+}\
+.ace-pastel-on-dark .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYIiPj/8PAARgAh2NTMh8AAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_dark.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_dark.js
new file mode 100644
index 00000000..d1acdb46
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_dark.js
@@ -0,0 +1,88 @@
+ace.define("ace/theme/solarized_dark",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-solarized-dark";
+exports.cssText = ".ace-solarized-dark .ace_gutter {\
+background: #01313f;\
+color: #d0edf7\
+}\
+.ace-solarized-dark .ace_print-margin {\
+width: 1px;\
+background: #33555E\
+}\
+.ace-solarized-dark {\
+background-color: #002B36;\
+color: #93A1A1\
+}\
+.ace-solarized-dark .ace_entity.ace_other.ace_attribute-name,\
+.ace-solarized-dark .ace_storage {\
+color: #93A1A1\
+}\
+.ace-solarized-dark .ace_cursor,\
+.ace-solarized-dark .ace_string.ace_regexp {\
+color: #D30102\
+}\
+.ace-solarized-dark .ace_marker-layer .ace_active-line,\
+.ace-solarized-dark .ace_marker-layer .ace_selection {\
+background: rgba(255, 255, 255, 0.1)\
+}\
+.ace-solarized-dark.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #002B36;\
+}\
+.ace-solarized-dark .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-solarized-dark .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(147, 161, 161, 0.50)\
+}\
+.ace-solarized-dark .ace_gutter-active-line {\
+background-color: #0d3440\
+}\
+.ace-solarized-dark .ace_marker-layer .ace_selected-word {\
+border: 1px solid #073642\
+}\
+.ace-solarized-dark .ace_invisible {\
+color: rgba(147, 161, 161, 0.50)\
+}\
+.ace-solarized-dark .ace_keyword,\
+.ace-solarized-dark .ace_meta,\
+.ace-solarized-dark .ace_support.ace_class,\
+.ace-solarized-dark .ace_support.ace_type {\
+color: #859900\
+}\
+.ace-solarized-dark .ace_constant.ace_character,\
+.ace-solarized-dark .ace_constant.ace_other {\
+color: #CB4B16\
+}\
+.ace-solarized-dark .ace_constant.ace_language {\
+color: #B58900\
+}\
+.ace-solarized-dark .ace_constant.ace_numeric {\
+color: #D33682\
+}\
+.ace-solarized-dark .ace_fold {\
+background-color: #268BD2;\
+border-color: #93A1A1\
+}\
+.ace-solarized-dark .ace_entity.ace_name.ace_function,\
+.ace-solarized-dark .ace_entity.ace_name.ace_tag,\
+.ace-solarized-dark .ace_support.ace_function,\
+.ace-solarized-dark .ace_variable,\
+.ace-solarized-dark .ace_variable.ace_language {\
+color: #268BD2\
+}\
+.ace-solarized-dark .ace_string {\
+color: #2AA198\
+}\
+.ace-solarized-dark .ace_comment {\
+font-style: italic;\
+color: #657B83\
+}\
+.ace-solarized-dark .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNg0Db1ZVCxc/sPAAd4AlUHlLenAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_light.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_light.js
new file mode 100644
index 00000000..f0c078ae
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-solarized_light.js
@@ -0,0 +1,91 @@
+ace.define("ace/theme/solarized_light",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-solarized-light";
+exports.cssText = ".ace-solarized-light .ace_gutter {\
+background: #fbf1d3;\
+color: #333\
+}\
+.ace-solarized-light .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8\
+}\
+.ace-solarized-light {\
+background-color: #FDF6E3;\
+color: #586E75\
+}\
+.ace-solarized-light .ace_cursor {\
+color: #000000\
+}\
+.ace-solarized-light .ace_marker-layer .ace_selection {\
+background: rgba(7, 54, 67, 0.09)\
+}\
+.ace-solarized-light.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #FDF6E3;\
+}\
+.ace-solarized-light .ace_marker-layer .ace_step {\
+background: rgb(255, 255, 0)\
+}\
+.ace-solarized-light .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(147, 161, 161, 0.50)\
+}\
+.ace-solarized-light .ace_marker-layer .ace_active-line {\
+background: #EEE8D5\
+}\
+.ace-solarized-light .ace_gutter-active-line {\
+background-color : #EDE5C1\
+}\
+.ace-solarized-light .ace_marker-layer .ace_selected-word {\
+border: 1px solid #073642\
+}\
+.ace-solarized-light .ace_invisible {\
+color: rgba(147, 161, 161, 0.50)\
+}\
+.ace-solarized-light .ace_keyword,\
+.ace-solarized-light .ace_meta,\
+.ace-solarized-light .ace_support.ace_class,\
+.ace-solarized-light .ace_support.ace_type {\
+color: #859900\
+}\
+.ace-solarized-light .ace_constant.ace_character,\
+.ace-solarized-light .ace_constant.ace_other {\
+color: #CB4B16\
+}\
+.ace-solarized-light .ace_constant.ace_language {\
+color: #B58900\
+}\
+.ace-solarized-light .ace_constant.ace_numeric {\
+color: #D33682\
+}\
+.ace-solarized-light .ace_fold {\
+background-color: #268BD2;\
+border-color: #586E75\
+}\
+.ace-solarized-light .ace_entity.ace_name.ace_function,\
+.ace-solarized-light .ace_entity.ace_name.ace_tag,\
+.ace-solarized-light .ace_support.ace_function,\
+.ace-solarized-light .ace_variable,\
+.ace-solarized-light .ace_variable.ace_language {\
+color: #268BD2\
+}\
+.ace-solarized-light .ace_storage {\
+color: #073642\
+}\
+.ace-solarized-light .ace_string {\
+color: #2AA198\
+}\
+.ace-solarized-light .ace_string.ace_regexp {\
+color: #D30102\
+}\
+.ace-solarized-light .ace_comment,\
+.ace-solarized-light .ace_entity.ace_other.ace_attribute-name {\
+color: #93A1A1\
+}\
+.ace-solarized-light .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYHjy8NJ/AAjgA5fzQUmBAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-sqlserver.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-sqlserver.js
new file mode 100644
index 00000000..91f34f6c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-sqlserver.js
@@ -0,0 +1,138 @@
+ace.define("ace/theme/sqlserver",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-sqlserver";
+exports.cssText = ".ace-sqlserver .ace_gutter {\
+background: #ebebeb;\
+color: #333;\
+overflow: hidden;\
+}\
+.ace-sqlserver .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-sqlserver {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-sqlserver .ace_identifier {\
+color: black;\
+}\
+.ace-sqlserver .ace_keyword {\
+color: #0000FF;\
+}\
+.ace-sqlserver .ace_numeric {\
+color: black;\
+}\
+.ace-sqlserver .ace_storage {\
+color: #11B7BE;\
+}\
+.ace-sqlserver .ace_keyword.ace_operator,\
+.ace-sqlserver .ace_lparen,\
+.ace-sqlserver .ace_rparen,\
+.ace-sqlserver .ace_punctuation {\
+color: #808080;\
+}\
+.ace-sqlserver .ace_set.ace_statement {\
+color: #0000FF;\
+text-decoration: underline;\
+}\
+.ace-sqlserver .ace_cursor {\
+color: black;\
+}\
+.ace-sqlserver .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-sqlserver .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-sqlserver .ace_constant.ace_language {\
+color: #979797;\
+}\
+.ace-sqlserver .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-sqlserver .ace_invalid {\
+background-color: rgb(153, 0, 0);\
+color: white;\
+}\
+.ace-sqlserver .ace_support.ace_function {\
+color: #FF00FF;\
+}\
+.ace-sqlserver .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-sqlserver .ace_class {\
+color: #008080;\
+}\
+.ace-sqlserver .ace_support.ace_other {\
+color: #6D79DE;\
+}\
+.ace-sqlserver .ace_variable.ace_parameter {\
+font-style: italic;\
+color: #FD971F;\
+}\
+.ace-sqlserver .ace_comment {\
+color: #008000;\
+}\
+.ace-sqlserver .ace_constant.ace_numeric {\
+color: black;\
+}\
+.ace-sqlserver .ace_variable {\
+color: rgb(49, 132, 149);\
+}\
+.ace-sqlserver .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-sqlserver .ace_support.ace_storedprocedure {\
+color: #800000;\
+}\
+.ace-sqlserver .ace_heading {\
+color: rgb(12, 7, 255);\
+}\
+.ace-sqlserver .ace_list {\
+color: rgb(185, 6, 144);\
+}\
+.ace-sqlserver .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-sqlserver .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-sqlserver .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-sqlserver .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-sqlserver .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.07);\
+}\
+.ace-sqlserver .ace_gutter-active-line {\
+background-color: #dcdcdc;\
+}\
+.ace-sqlserver .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-sqlserver .ace_meta.ace_tag {\
+color: #0000FF;\
+}\
+.ace-sqlserver .ace_string.ace_regex {\
+color: #FF0000;\
+}\
+.ace-sqlserver .ace_string {\
+color: #FF0000;\
+}\
+.ace-sqlserver .ace_entity.ace_other.ace_attribute-name {\
+color: #994409;\
+}\
+.ace-sqlserver .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-terminal.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-terminal.js
new file mode 100644
index 00000000..def9e69b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-terminal.js
@@ -0,0 +1,114 @@
+ace.define("ace/theme/terminal",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-terminal-theme";
+exports.cssText = ".ace-terminal-theme .ace_gutter {\
+background: #1a0005;\
+color: steelblue\
+}\
+.ace-terminal-theme .ace_print-margin {\
+width: 1px;\
+background: #1a1a1a\
+}\
+.ace-terminal-theme {\
+background-color: black;\
+color: #DEDEDE\
+}\
+.ace-terminal-theme .ace_cursor {\
+color: #9F9F9F\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_selection {\
+background: #424242\
+}\
+.ace-terminal-theme.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px black;\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_step {\
+background: rgb(0, 0, 0)\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_bracket {\
+background: #090;\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_bracket-start {\
+background: #090;\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_bracket-unmatched {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #900\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_active-line {\
+background: #2A2A2A\
+}\
+.ace-terminal-theme .ace_gutter-active-line {\
+background-color: #2A112A\
+}\
+.ace-terminal-theme .ace_marker-layer .ace_selected-word {\
+border: 1px solid #424242\
+}\
+.ace-terminal-theme .ace_invisible {\
+color: #343434\
+}\
+.ace-terminal-theme .ace_keyword,\
+.ace-terminal-theme .ace_meta,\
+.ace-terminal-theme .ace_storage,\
+.ace-terminal-theme .ace_storage.ace_type,\
+.ace-terminal-theme .ace_support.ace_type {\
+color: tomato\
+}\
+.ace-terminal-theme .ace_keyword.ace_operator {\
+color: deeppink\
+}\
+.ace-terminal-theme .ace_constant.ace_character,\
+.ace-terminal-theme .ace_constant.ace_language,\
+.ace-terminal-theme .ace_constant.ace_numeric,\
+.ace-terminal-theme .ace_keyword.ace_other.ace_unit,\
+.ace-terminal-theme .ace_support.ace_constant,\
+.ace-terminal-theme .ace_variable.ace_parameter {\
+color: #E78C45\
+}\
+.ace-terminal-theme .ace_constant.ace_other {\
+color: gold\
+}\
+.ace-terminal-theme .ace_invalid {\
+color: yellow;\
+background-color: red\
+}\
+.ace-terminal-theme .ace_invalid.ace_deprecated {\
+color: #CED2CF;\
+background-color: #B798BF\
+}\
+.ace-terminal-theme .ace_fold {\
+background-color: #7AA6DA;\
+border-color: #DEDEDE\
+}\
+.ace-terminal-theme .ace_entity.ace_name.ace_function,\
+.ace-terminal-theme .ace_support.ace_function,\
+.ace-terminal-theme .ace_variable {\
+color: #7AA6DA\
+}\
+.ace-terminal-theme .ace_support.ace_class,\
+.ace-terminal-theme .ace_support.ace_type {\
+color: #E7C547\
+}\
+.ace-terminal-theme .ace_heading,\
+.ace-terminal-theme .ace_string {\
+color: #B9CA4A\
+}\
+.ace-terminal-theme .ace_entity.ace_name.ace_tag,\
+.ace-terminal-theme .ace_entity.ace_other.ace_attribute-name,\
+.ace-terminal-theme .ace_meta.ace_tag,\
+.ace-terminal-theme .ace_string.ace_regexp,\
+.ace-terminal-theme .ace_variable {\
+color: #D54E53\
+}\
+.ace-terminal-theme .ace_comment {\
+color: orangered\
+}\
+.ace-terminal-theme .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYLBWV/8PAAK4AYnhiq+xAAAAAElFTkSuQmCC) right repeat-y;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-textmate.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-textmate.js
new file mode 100644
index 00000000..0033edae
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-textmate.js
@@ -0,0 +1,129 @@
+ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+"use strict";
+
+exports.isDark = false;
+exports.cssClass = "ace-tm";
+exports.cssText = ".ace-tm .ace_gutter {\
+background: #f0f0f0;\
+color: #333;\
+}\
+.ace-tm .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8;\
+}\
+.ace-tm .ace_fold {\
+background-color: #6B72E6;\
+}\
+.ace-tm {\
+background-color: #FFFFFF;\
+color: black;\
+}\
+.ace-tm .ace_cursor {\
+color: black;\
+}\
+.ace-tm .ace_invisible {\
+color: rgb(191, 191, 191);\
+}\
+.ace-tm .ace_storage,\
+.ace-tm .ace_keyword {\
+color: blue;\
+}\
+.ace-tm .ace_constant {\
+color: rgb(197, 6, 11);\
+}\
+.ace-tm .ace_constant.ace_buildin {\
+color: rgb(88, 72, 246);\
+}\
+.ace-tm .ace_constant.ace_language {\
+color: rgb(88, 92, 246);\
+}\
+.ace-tm .ace_constant.ace_library {\
+color: rgb(6, 150, 14);\
+}\
+.ace-tm .ace_invalid {\
+background-color: rgba(255, 0, 0, 0.1);\
+color: red;\
+}\
+.ace-tm .ace_support.ace_function {\
+color: rgb(60, 76, 114);\
+}\
+.ace-tm .ace_support.ace_constant {\
+color: rgb(6, 150, 14);\
+}\
+.ace-tm .ace_support.ace_type,\
+.ace-tm .ace_support.ace_class {\
+color: rgb(109, 121, 222);\
+}\
+.ace-tm .ace_keyword.ace_operator {\
+color: rgb(104, 118, 135);\
+}\
+.ace-tm .ace_string {\
+color: rgb(3, 106, 7);\
+}\
+.ace-tm .ace_comment {\
+color: rgb(76, 136, 107);\
+}\
+.ace-tm .ace_comment.ace_doc {\
+color: rgb(0, 102, 255);\
+}\
+.ace-tm .ace_comment.ace_doc.ace_tag {\
+color: rgb(128, 159, 191);\
+}\
+.ace-tm .ace_constant.ace_numeric {\
+color: rgb(0, 0, 205);\
+}\
+.ace-tm .ace_variable {\
+color: rgb(49, 132, 149);\
+}\
+.ace-tm .ace_xml-pe {\
+color: rgb(104, 104, 91);\
+}\
+.ace-tm .ace_entity.ace_name.ace_function {\
+color: #0000A2;\
+}\
+.ace-tm .ace_heading {\
+color: rgb(12, 7, 255);\
+}\
+.ace-tm .ace_list {\
+color:rgb(185, 6, 144);\
+}\
+.ace-tm .ace_meta.ace_tag {\
+color:rgb(0, 22, 142);\
+}\
+.ace-tm .ace_string.ace_regex {\
+color: rgb(255, 0, 0)\
+}\
+.ace-tm .ace_marker-layer .ace_selection {\
+background: rgb(181, 213, 255);\
+}\
+.ace-tm.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px white;\
+}\
+.ace-tm .ace_marker-layer .ace_step {\
+background: rgb(252, 255, 0);\
+}\
+.ace-tm .ace_marker-layer .ace_stack {\
+background: rgb(164, 229, 101);\
+}\
+.ace-tm .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgb(192, 192, 192);\
+}\
+.ace-tm .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.07);\
+}\
+.ace-tm .ace_gutter-active-line {\
+background-color : #dcdcdc;\
+}\
+.ace-tm .ace_marker-layer .ace_selected-word {\
+background: rgb(250, 250, 255);\
+border: 1px solid rgb(200, 200, 250);\
+}\
+.ace-tm .ace_indent-guide {\
+background: url(\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==\") right repeat-y;\
+}\
+";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow.js
new file mode 100644
index 00000000..4661be11
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow.js
@@ -0,0 +1,108 @@
+ace.define("ace/theme/tomorrow",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-tomorrow";
+exports.cssText = ".ace-tomorrow .ace_gutter {\
+background: #f6f6f6;\
+color: #4D4D4C\
+}\
+.ace-tomorrow .ace_print-margin {\
+width: 1px;\
+background: #f6f6f6\
+}\
+.ace-tomorrow {\
+background-color: #FFFFFF;\
+color: #4D4D4C\
+}\
+.ace-tomorrow .ace_cursor {\
+color: #AEAFAD\
+}\
+.ace-tomorrow .ace_marker-layer .ace_selection {\
+background: #D6D6D6\
+}\
+.ace-tomorrow.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #FFFFFF;\
+}\
+.ace-tomorrow .ace_marker-layer .ace_step {\
+background: rgb(255, 255, 0)\
+}\
+.ace-tomorrow .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #D1D1D1\
+}\
+.ace-tomorrow .ace_marker-layer .ace_active-line {\
+background: #EFEFEF\
+}\
+.ace-tomorrow .ace_gutter-active-line {\
+background-color : #dcdcdc\
+}\
+.ace-tomorrow .ace_marker-layer .ace_selected-word {\
+border: 1px solid #D6D6D6\
+}\
+.ace-tomorrow .ace_invisible {\
+color: #D1D1D1\
+}\
+.ace-tomorrow .ace_keyword,\
+.ace-tomorrow .ace_meta,\
+.ace-tomorrow .ace_storage,\
+.ace-tomorrow .ace_storage.ace_type,\
+.ace-tomorrow .ace_support.ace_type {\
+color: #8959A8\
+}\
+.ace-tomorrow .ace_keyword.ace_operator {\
+color: #3E999F\
+}\
+.ace-tomorrow .ace_constant.ace_character,\
+.ace-tomorrow .ace_constant.ace_language,\
+.ace-tomorrow .ace_constant.ace_numeric,\
+.ace-tomorrow .ace_keyword.ace_other.ace_unit,\
+.ace-tomorrow .ace_support.ace_constant,\
+.ace-tomorrow .ace_variable.ace_parameter {\
+color: #F5871F\
+}\
+.ace-tomorrow .ace_constant.ace_other {\
+color: #666969\
+}\
+.ace-tomorrow .ace_invalid {\
+color: #FFFFFF;\
+background-color: #C82829\
+}\
+.ace-tomorrow .ace_invalid.ace_deprecated {\
+color: #FFFFFF;\
+background-color: #8959A8\
+}\
+.ace-tomorrow .ace_fold {\
+background-color: #4271AE;\
+border-color: #4D4D4C\
+}\
+.ace-tomorrow .ace_entity.ace_name.ace_function,\
+.ace-tomorrow .ace_support.ace_function,\
+.ace-tomorrow .ace_variable {\
+color: #4271AE\
+}\
+.ace-tomorrow .ace_support.ace_class,\
+.ace-tomorrow .ace_support.ace_type {\
+color: #C99E00\
+}\
+.ace-tomorrow .ace_heading,\
+.ace-tomorrow .ace_markup.ace_heading,\
+.ace-tomorrow .ace_string {\
+color: #718C00\
+}\
+.ace-tomorrow .ace_entity.ace_name.ace_tag,\
+.ace-tomorrow .ace_entity.ace_other.ace_attribute-name,\
+.ace-tomorrow .ace_meta.ace_tag,\
+.ace-tomorrow .ace_string.ace_regexp,\
+.ace-tomorrow .ace_variable {\
+color: #C82829\
+}\
+.ace-tomorrow .ace_comment {\
+color: #8E908C\
+}\
+.ace-tomorrow .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bdu3f/BwAlfgctduB85QAAAABJRU5ErkJggg==) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night.js
new file mode 100644
index 00000000..53e1f39a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night.js
@@ -0,0 +1,108 @@
+ace.define("ace/theme/tomorrow_night",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-tomorrow-night";
+exports.cssText = ".ace-tomorrow-night .ace_gutter {\
+background: #25282c;\
+color: #C5C8C6\
+}\
+.ace-tomorrow-night .ace_print-margin {\
+width: 1px;\
+background: #25282c\
+}\
+.ace-tomorrow-night {\
+background-color: #1D1F21;\
+color: #C5C8C6\
+}\
+.ace-tomorrow-night .ace_cursor {\
+color: #AEAFAD\
+}\
+.ace-tomorrow-night .ace_marker-layer .ace_selection {\
+background: #373B41\
+}\
+.ace-tomorrow-night.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #1D1F21;\
+}\
+.ace-tomorrow-night .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-tomorrow-night .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #4B4E55\
+}\
+.ace-tomorrow-night .ace_marker-layer .ace_active-line {\
+background: #282A2E\
+}\
+.ace-tomorrow-night .ace_gutter-active-line {\
+background-color: #282A2E\
+}\
+.ace-tomorrow-night .ace_marker-layer .ace_selected-word {\
+border: 1px solid #373B41\
+}\
+.ace-tomorrow-night .ace_invisible {\
+color: #4B4E55\
+}\
+.ace-tomorrow-night .ace_keyword,\
+.ace-tomorrow-night .ace_meta,\
+.ace-tomorrow-night .ace_storage,\
+.ace-tomorrow-night .ace_storage.ace_type,\
+.ace-tomorrow-night .ace_support.ace_type {\
+color: #B294BB\
+}\
+.ace-tomorrow-night .ace_keyword.ace_operator {\
+color: #8ABEB7\
+}\
+.ace-tomorrow-night .ace_constant.ace_character,\
+.ace-tomorrow-night .ace_constant.ace_language,\
+.ace-tomorrow-night .ace_constant.ace_numeric,\
+.ace-tomorrow-night .ace_keyword.ace_other.ace_unit,\
+.ace-tomorrow-night .ace_support.ace_constant,\
+.ace-tomorrow-night .ace_variable.ace_parameter {\
+color: #DE935F\
+}\
+.ace-tomorrow-night .ace_constant.ace_other {\
+color: #CED1CF\
+}\
+.ace-tomorrow-night .ace_invalid {\
+color: #CED2CF;\
+background-color: #DF5F5F\
+}\
+.ace-tomorrow-night .ace_invalid.ace_deprecated {\
+color: #CED2CF;\
+background-color: #B798BF\
+}\
+.ace-tomorrow-night .ace_fold {\
+background-color: #81A2BE;\
+border-color: #C5C8C6\
+}\
+.ace-tomorrow-night .ace_entity.ace_name.ace_function,\
+.ace-tomorrow-night .ace_support.ace_function,\
+.ace-tomorrow-night .ace_variable {\
+color: #81A2BE\
+}\
+.ace-tomorrow-night .ace_support.ace_class,\
+.ace-tomorrow-night .ace_support.ace_type {\
+color: #F0C674\
+}\
+.ace-tomorrow-night .ace_heading,\
+.ace-tomorrow-night .ace_markup.ace_heading,\
+.ace-tomorrow-night .ace_string {\
+color: #B5BD68\
+}\
+.ace-tomorrow-night .ace_entity.ace_name.ace_tag,\
+.ace-tomorrow-night .ace_entity.ace_other.ace_attribute-name,\
+.ace-tomorrow-night .ace_meta.ace_tag,\
+.ace-tomorrow-night .ace_string.ace_regexp,\
+.ace-tomorrow-night .ace_variable {\
+color: #CC6666\
+}\
+.ace-tomorrow-night .ace_comment {\
+color: #969896\
+}\
+.ace-tomorrow-night .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYHB3d/8PAAOIAdULw8qMAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_blue.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_blue.js
new file mode 100644
index 00000000..956e221e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_blue.js
@@ -0,0 +1,106 @@
+ace.define("ace/theme/tomorrow_night_blue",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-tomorrow-night-blue";
+exports.cssText = ".ace-tomorrow-night-blue .ace_gutter {\
+background: #00204b;\
+color: #7388b5\
+}\
+.ace-tomorrow-night-blue .ace_print-margin {\
+width: 1px;\
+background: #00204b\
+}\
+.ace-tomorrow-night-blue {\
+background-color: #002451;\
+color: #FFFFFF\
+}\
+.ace-tomorrow-night-blue .ace_constant.ace_other,\
+.ace-tomorrow-night-blue .ace_cursor {\
+color: #FFFFFF\
+}\
+.ace-tomorrow-night-blue .ace_marker-layer .ace_selection {\
+background: #003F8E\
+}\
+.ace-tomorrow-night-blue.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #002451;\
+}\
+.ace-tomorrow-night-blue .ace_marker-layer .ace_step {\
+background: rgb(127, 111, 19)\
+}\
+.ace-tomorrow-night-blue .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #404F7D\
+}\
+.ace-tomorrow-night-blue .ace_marker-layer .ace_active-line {\
+background: #00346E\
+}\
+.ace-tomorrow-night-blue .ace_gutter-active-line {\
+background-color: #022040\
+}\
+.ace-tomorrow-night-blue .ace_marker-layer .ace_selected-word {\
+border: 1px solid #003F8E\
+}\
+.ace-tomorrow-night-blue .ace_invisible {\
+color: #404F7D\
+}\
+.ace-tomorrow-night-blue .ace_keyword,\
+.ace-tomorrow-night-blue .ace_meta,\
+.ace-tomorrow-night-blue .ace_storage,\
+.ace-tomorrow-night-blue .ace_storage.ace_type,\
+.ace-tomorrow-night-blue .ace_support.ace_type {\
+color: #EBBBFF\
+}\
+.ace-tomorrow-night-blue .ace_keyword.ace_operator {\
+color: #99FFFF\
+}\
+.ace-tomorrow-night-blue .ace_constant.ace_character,\
+.ace-tomorrow-night-blue .ace_constant.ace_language,\
+.ace-tomorrow-night-blue .ace_constant.ace_numeric,\
+.ace-tomorrow-night-blue .ace_keyword.ace_other.ace_unit,\
+.ace-tomorrow-night-blue .ace_support.ace_constant,\
+.ace-tomorrow-night-blue .ace_variable.ace_parameter {\
+color: #FFC58F\
+}\
+.ace-tomorrow-night-blue .ace_invalid {\
+color: #FFFFFF;\
+background-color: #F99DA5\
+}\
+.ace-tomorrow-night-blue .ace_invalid.ace_deprecated {\
+color: #FFFFFF;\
+background-color: #EBBBFF\
+}\
+.ace-tomorrow-night-blue .ace_fold {\
+background-color: #BBDAFF;\
+border-color: #FFFFFF\
+}\
+.ace-tomorrow-night-blue .ace_entity.ace_name.ace_function,\
+.ace-tomorrow-night-blue .ace_support.ace_function,\
+.ace-tomorrow-night-blue .ace_variable {\
+color: #BBDAFF\
+}\
+.ace-tomorrow-night-blue .ace_support.ace_class,\
+.ace-tomorrow-night-blue .ace_support.ace_type {\
+color: #FFEEAD\
+}\
+.ace-tomorrow-night-blue .ace_heading,\
+.ace-tomorrow-night-blue .ace_markup.ace_heading,\
+.ace-tomorrow-night-blue .ace_string {\
+color: #D1F1A9\
+}\
+.ace-tomorrow-night-blue .ace_entity.ace_name.ace_tag,\
+.ace-tomorrow-night-blue .ace_entity.ace_other.ace_attribute-name,\
+.ace-tomorrow-night-blue .ace_meta.ace_tag,\
+.ace-tomorrow-night-blue .ace_string.ace_regexp,\
+.ace-tomorrow-night-blue .ace_variable {\
+color: #FF9DA4\
+}\
+.ace-tomorrow-night-blue .ace_comment {\
+color: #7285B7\
+}\
+.ace-tomorrow-night-blue .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYJDzqfwPAANXAeNsiA+ZAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_bright.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_bright.js
new file mode 100644
index 00000000..8514a0d6
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_bright.js
@@ -0,0 +1,121 @@
+ace.define("ace/theme/tomorrow_night_bright",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-tomorrow-night-bright";
+exports.cssText = ".ace-tomorrow-night-bright .ace_gutter {\
+background: #1a1a1a;\
+color: #DEDEDE\
+}\
+.ace-tomorrow-night-bright .ace_print-margin {\
+width: 1px;\
+background: #1a1a1a\
+}\
+.ace-tomorrow-night-bright {\
+background-color: #000000;\
+color: #DEDEDE\
+}\
+.ace-tomorrow-night-bright .ace_cursor {\
+color: #9F9F9F\
+}\
+.ace-tomorrow-night-bright .ace_marker-layer .ace_selection {\
+background: #424242\
+}\
+.ace-tomorrow-night-bright.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #000000;\
+}\
+.ace-tomorrow-night-bright .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-tomorrow-night-bright .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #888888\
+}\
+.ace-tomorrow-night-bright .ace_marker-layer .ace_highlight {\
+border: 1px solid rgb(110, 119, 0);\
+border-bottom: 0;\
+box-shadow: inset 0 -1px rgb(110, 119, 0);\
+margin: -1px 0 0 -1px;\
+background: rgba(255, 235, 0, 0.1)\
+}\
+.ace-tomorrow-night-bright .ace_marker-layer .ace_active-line {\
+background: #2A2A2A\
+}\
+.ace-tomorrow-night-bright .ace_gutter-active-line {\
+background-color: #2A2A2A\
+}\
+.ace-tomorrow-night-bright .ace_stack {\
+background-color: rgb(66, 90, 44)\
+}\
+.ace-tomorrow-night-bright .ace_marker-layer .ace_selected-word {\
+border: 1px solid #888888\
+}\
+.ace-tomorrow-night-bright .ace_invisible {\
+color: #343434\
+}\
+.ace-tomorrow-night-bright .ace_keyword,\
+.ace-tomorrow-night-bright .ace_meta,\
+.ace-tomorrow-night-bright .ace_storage,\
+.ace-tomorrow-night-bright .ace_storage.ace_type,\
+.ace-tomorrow-night-bright .ace_support.ace_type {\
+color: #C397D8\
+}\
+.ace-tomorrow-night-bright .ace_keyword.ace_operator {\
+color: #70C0B1\
+}\
+.ace-tomorrow-night-bright .ace_constant.ace_character,\
+.ace-tomorrow-night-bright .ace_constant.ace_language,\
+.ace-tomorrow-night-bright .ace_constant.ace_numeric,\
+.ace-tomorrow-night-bright .ace_keyword.ace_other.ace_unit,\
+.ace-tomorrow-night-bright .ace_support.ace_constant,\
+.ace-tomorrow-night-bright .ace_variable.ace_parameter {\
+color: #E78C45\
+}\
+.ace-tomorrow-night-bright .ace_constant.ace_other {\
+color: #EEEEEE\
+}\
+.ace-tomorrow-night-bright .ace_invalid {\
+color: #CED2CF;\
+background-color: #DF5F5F\
+}\
+.ace-tomorrow-night-bright .ace_invalid.ace_deprecated {\
+color: #CED2CF;\
+background-color: #B798BF\
+}\
+.ace-tomorrow-night-bright .ace_fold {\
+background-color: #7AA6DA;\
+border-color: #DEDEDE\
+}\
+.ace-tomorrow-night-bright .ace_entity.ace_name.ace_function,\
+.ace-tomorrow-night-bright .ace_support.ace_function,\
+.ace-tomorrow-night-bright .ace_variable {\
+color: #7AA6DA\
+}\
+.ace-tomorrow-night-bright .ace_support.ace_class,\
+.ace-tomorrow-night-bright .ace_support.ace_type {\
+color: #E7C547\
+}\
+.ace-tomorrow-night-bright .ace_heading,\
+.ace-tomorrow-night-bright .ace_markup.ace_heading,\
+.ace-tomorrow-night-bright .ace_string {\
+color: #B9CA4A\
+}\
+.ace-tomorrow-night-bright .ace_entity.ace_name.ace_tag,\
+.ace-tomorrow-night-bright .ace_entity.ace_other.ace_attribute-name,\
+.ace-tomorrow-night-bright .ace_meta.ace_tag,\
+.ace-tomorrow-night-bright .ace_string.ace_regexp,\
+.ace-tomorrow-night-bright .ace_variable {\
+color: #D54E53\
+}\
+.ace-tomorrow-night-bright .ace_comment {\
+color: #969896\
+}\
+.ace-tomorrow-night-bright .ace_c9searchresults.ace_keyword {\
+color: #C2C280\
+}\
+.ace-tomorrow-night-bright .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYFBXV/8PAAJoAXX4kT2EAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_eighties.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_eighties.js
new file mode 100644
index 00000000..3665e3f7
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-tomorrow_night_eighties.js
@@ -0,0 +1,108 @@
+ace.define("ace/theme/tomorrow_night_eighties",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-tomorrow-night-eighties";
+exports.cssText = ".ace-tomorrow-night-eighties .ace_gutter {\
+background: #272727;\
+color: #CCC\
+}\
+.ace-tomorrow-night-eighties .ace_print-margin {\
+width: 1px;\
+background: #272727\
+}\
+.ace-tomorrow-night-eighties {\
+background-color: #2D2D2D;\
+color: #CCCCCC\
+}\
+.ace-tomorrow-night-eighties .ace_constant.ace_other,\
+.ace-tomorrow-night-eighties .ace_cursor {\
+color: #CCCCCC\
+}\
+.ace-tomorrow-night-eighties .ace_marker-layer .ace_selection {\
+background: #515151\
+}\
+.ace-tomorrow-night-eighties.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #2D2D2D;\
+}\
+.ace-tomorrow-night-eighties .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-tomorrow-night-eighties .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #6A6A6A\
+}\
+.ace-tomorrow-night-bright .ace_stack {\
+background: rgb(66, 90, 44)\
+}\
+.ace-tomorrow-night-eighties .ace_marker-layer .ace_active-line {\
+background: #393939\
+}\
+.ace-tomorrow-night-eighties .ace_gutter-active-line {\
+background-color: #393939\
+}\
+.ace-tomorrow-night-eighties .ace_marker-layer .ace_selected-word {\
+border: 1px solid #515151\
+}\
+.ace-tomorrow-night-eighties .ace_invisible {\
+color: #6A6A6A\
+}\
+.ace-tomorrow-night-eighties .ace_keyword,\
+.ace-tomorrow-night-eighties .ace_meta,\
+.ace-tomorrow-night-eighties .ace_storage,\
+.ace-tomorrow-night-eighties .ace_storage.ace_type,\
+.ace-tomorrow-night-eighties .ace_support.ace_type {\
+color: #CC99CC\
+}\
+.ace-tomorrow-night-eighties .ace_keyword.ace_operator {\
+color: #66CCCC\
+}\
+.ace-tomorrow-night-eighties .ace_constant.ace_character,\
+.ace-tomorrow-night-eighties .ace_constant.ace_language,\
+.ace-tomorrow-night-eighties .ace_constant.ace_numeric,\
+.ace-tomorrow-night-eighties .ace_keyword.ace_other.ace_unit,\
+.ace-tomorrow-night-eighties .ace_support.ace_constant,\
+.ace-tomorrow-night-eighties .ace_variable.ace_parameter {\
+color: #F99157\
+}\
+.ace-tomorrow-night-eighties .ace_invalid {\
+color: #CDCDCD;\
+background-color: #F2777A\
+}\
+.ace-tomorrow-night-eighties .ace_invalid.ace_deprecated {\
+color: #CDCDCD;\
+background-color: #CC99CC\
+}\
+.ace-tomorrow-night-eighties .ace_fold {\
+background-color: #6699CC;\
+border-color: #CCCCCC\
+}\
+.ace-tomorrow-night-eighties .ace_entity.ace_name.ace_function,\
+.ace-tomorrow-night-eighties .ace_support.ace_function,\
+.ace-tomorrow-night-eighties .ace_variable {\
+color: #6699CC\
+}\
+.ace-tomorrow-night-eighties .ace_support.ace_class,\
+.ace-tomorrow-night-eighties .ace_support.ace_type {\
+color: #FFCC66\
+}\
+.ace-tomorrow-night-eighties .ace_heading,\
+.ace-tomorrow-night-eighties .ace_markup.ace_heading,\
+.ace-tomorrow-night-eighties .ace_string {\
+color: #99CC99\
+}\
+.ace-tomorrow-night-eighties .ace_comment {\
+color: #999999\
+}\
+.ace-tomorrow-night-eighties .ace_entity.ace_name.ace_tag,\
+.ace-tomorrow-night-eighties .ace_entity.ace_other.ace_attribute-name,\
+.ace-tomorrow-night-eighties .ace_meta.ace_tag,\
+.ace-tomorrow-night-eighties .ace_variable {\
+color: #F2777A\
+}\
+.ace-tomorrow-night-eighties .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWPQ09NrYAgMjP4PAAtGAwchHMyAAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-twilight.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-twilight.js
new file mode 100644
index 00000000..48ec0309
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-twilight.js
@@ -0,0 +1,109 @@
+ace.define("ace/theme/twilight",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-twilight";
+exports.cssText = ".ace-twilight .ace_gutter {\
+background: #232323;\
+color: #E2E2E2\
+}\
+.ace-twilight .ace_print-margin {\
+width: 1px;\
+background: #232323\
+}\
+.ace-twilight {\
+background-color: #141414;\
+color: #F8F8F8\
+}\
+.ace-twilight .ace_cursor {\
+color: #A7A7A7\
+}\
+.ace-twilight .ace_marker-layer .ace_selection {\
+background: rgba(221, 240, 255, 0.20)\
+}\
+.ace-twilight.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #141414;\
+}\
+.ace-twilight .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-twilight .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid rgba(255, 255, 255, 0.25)\
+}\
+.ace-twilight .ace_marker-layer .ace_active-line {\
+background: rgba(255, 255, 255, 0.031)\
+}\
+.ace-twilight .ace_gutter-active-line {\
+background-color: rgba(255, 255, 255, 0.031)\
+}\
+.ace-twilight .ace_marker-layer .ace_selected-word {\
+border: 1px solid rgba(221, 240, 255, 0.20)\
+}\
+.ace-twilight .ace_invisible {\
+color: rgba(255, 255, 255, 0.25)\
+}\
+.ace-twilight .ace_keyword,\
+.ace-twilight .ace_meta {\
+color: #CDA869\
+}\
+.ace-twilight .ace_constant,\
+.ace-twilight .ace_constant.ace_character,\
+.ace-twilight .ace_constant.ace_character.ace_escape,\
+.ace-twilight .ace_constant.ace_other,\
+.ace-twilight .ace_heading,\
+.ace-twilight .ace_markup.ace_heading,\
+.ace-twilight .ace_support.ace_constant {\
+color: #CF6A4C\
+}\
+.ace-twilight .ace_invalid.ace_illegal {\
+color: #F8F8F8;\
+background-color: rgba(86, 45, 86, 0.75)\
+}\
+.ace-twilight .ace_invalid.ace_deprecated {\
+text-decoration: underline;\
+font-style: italic;\
+color: #D2A8A1\
+}\
+.ace-twilight .ace_support {\
+color: #9B859D\
+}\
+.ace-twilight .ace_fold {\
+background-color: #AC885B;\
+border-color: #F8F8F8\
+}\
+.ace-twilight .ace_support.ace_function {\
+color: #DAD085\
+}\
+.ace-twilight .ace_list,\
+.ace-twilight .ace_markup.ace_list,\
+.ace-twilight .ace_storage {\
+color: #F9EE98\
+}\
+.ace-twilight .ace_entity.ace_name.ace_function,\
+.ace-twilight .ace_meta.ace_tag,\
+.ace-twilight .ace_variable {\
+color: #AC885B\
+}\
+.ace-twilight .ace_string {\
+color: #8F9D6A\
+}\
+.ace-twilight .ace_string.ace_regexp {\
+color: #E9C062\
+}\
+.ace-twilight .ace_comment {\
+font-style: italic;\
+color: #5F5A60\
+}\
+.ace-twilight .ace_variable {\
+color: #7587A6\
+}\
+.ace-twilight .ace_xml-pe {\
+color: #494949\
+}\
+.ace-twilight .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQERFpYLC1tf0PAAgOAnPnhxyiAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-vibrant_ink.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-vibrant_ink.js
new file mode 100644
index 00000000..db926c70
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-vibrant_ink.js
@@ -0,0 +1,94 @@
+ace.define("ace/theme/vibrant_ink",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = true;
+exports.cssClass = "ace-vibrant-ink";
+exports.cssText = ".ace-vibrant-ink .ace_gutter {\
+background: #1a1a1a;\
+color: #BEBEBE\
+}\
+.ace-vibrant-ink .ace_print-margin {\
+width: 1px;\
+background: #1a1a1a\
+}\
+.ace-vibrant-ink {\
+background-color: #0F0F0F;\
+color: #FFFFFF\
+}\
+.ace-vibrant-ink .ace_cursor {\
+color: #FFFFFF\
+}\
+.ace-vibrant-ink .ace_marker-layer .ace_selection {\
+background: #6699CC\
+}\
+.ace-vibrant-ink.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #0F0F0F;\
+}\
+.ace-vibrant-ink .ace_marker-layer .ace_step {\
+background: rgb(102, 82, 0)\
+}\
+.ace-vibrant-ink .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #404040\
+}\
+.ace-vibrant-ink .ace_marker-layer .ace_active-line {\
+background: #333333\
+}\
+.ace-vibrant-ink .ace_gutter-active-line {\
+background-color: #333333\
+}\
+.ace-vibrant-ink .ace_marker-layer .ace_selected-word {\
+border: 1px solid #6699CC\
+}\
+.ace-vibrant-ink .ace_invisible {\
+color: #404040\
+}\
+.ace-vibrant-ink .ace_keyword,\
+.ace-vibrant-ink .ace_meta {\
+color: #FF6600\
+}\
+.ace-vibrant-ink .ace_constant,\
+.ace-vibrant-ink .ace_constant.ace_character,\
+.ace-vibrant-ink .ace_constant.ace_character.ace_escape,\
+.ace-vibrant-ink .ace_constant.ace_other {\
+color: #339999\
+}\
+.ace-vibrant-ink .ace_constant.ace_numeric {\
+color: #99CC99\
+}\
+.ace-vibrant-ink .ace_invalid,\
+.ace-vibrant-ink .ace_invalid.ace_deprecated {\
+color: #CCFF33;\
+background-color: #000000\
+}\
+.ace-vibrant-ink .ace_fold {\
+background-color: #FFCC00;\
+border-color: #FFFFFF\
+}\
+.ace-vibrant-ink .ace_entity.ace_name.ace_function,\
+.ace-vibrant-ink .ace_support.ace_function,\
+.ace-vibrant-ink .ace_variable {\
+color: #FFCC00\
+}\
+.ace-vibrant-ink .ace_variable.ace_parameter {\
+font-style: italic\
+}\
+.ace-vibrant-ink .ace_string {\
+color: #66FF00\
+}\
+.ace-vibrant-ink .ace_string.ace_regexp {\
+color: #44B4CC\
+}\
+.ace-vibrant-ink .ace_comment {\
+color: #9933CC\
+}\
+.ace-vibrant-ink .ace_entity.ace_other.ace_attribute-name {\
+font-style: italic;\
+color: #99CC99\
+}\
+.ace-vibrant-ink .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWNgYGBgYNDTc/oPAALPAZ7hxlbYAAAAAElFTkSuQmCC) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/theme-xcode.js b/www/wiki/extensions/CodeEditor/modules/ace/theme-xcode.js
new file mode 100644
index 00000000..3604a170
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/theme-xcode.js
@@ -0,0 +1,88 @@
+ace.define("ace/theme/xcode",["require","exports","module","ace/lib/dom"], function(require, exports, module) {
+
+exports.isDark = false;
+exports.cssClass = "ace-xcode";
+exports.cssText = "\
+.ace-xcode .ace_gutter {\
+background: #e8e8e8;\
+color: #333\
+}\
+.ace-xcode .ace_print-margin {\
+width: 1px;\
+background: #e8e8e8\
+}\
+.ace-xcode {\
+background-color: #FFFFFF;\
+color: #000000\
+}\
+.ace-xcode .ace_cursor {\
+color: #000000\
+}\
+.ace-xcode .ace_marker-layer .ace_selection {\
+background: #B5D5FF\
+}\
+.ace-xcode.ace_multiselect .ace_selection.ace_start {\
+box-shadow: 0 0 3px 0px #FFFFFF;\
+}\
+.ace-xcode .ace_marker-layer .ace_step {\
+background: rgb(198, 219, 174)\
+}\
+.ace-xcode .ace_marker-layer .ace_bracket {\
+margin: -1px 0 0 -1px;\
+border: 1px solid #BFBFBF\
+}\
+.ace-xcode .ace_marker-layer .ace_active-line {\
+background: rgba(0, 0, 0, 0.071)\
+}\
+.ace-xcode .ace_gutter-active-line {\
+background-color: rgba(0, 0, 0, 0.071)\
+}\
+.ace-xcode .ace_marker-layer .ace_selected-word {\
+border: 1px solid #B5D5FF\
+}\
+.ace-xcode .ace_constant.ace_language,\
+.ace-xcode .ace_keyword,\
+.ace-xcode .ace_meta,\
+.ace-xcode .ace_variable.ace_language {\
+color: #C800A4\
+}\
+.ace-xcode .ace_invisible {\
+color: #BFBFBF\
+}\
+.ace-xcode .ace_constant.ace_character,\
+.ace-xcode .ace_constant.ace_other {\
+color: #275A5E\
+}\
+.ace-xcode .ace_constant.ace_numeric {\
+color: #3A00DC\
+}\
+.ace-xcode .ace_entity.ace_other.ace_attribute-name,\
+.ace-xcode .ace_support.ace_constant,\
+.ace-xcode .ace_support.ace_function {\
+color: #450084\
+}\
+.ace-xcode .ace_fold {\
+background-color: #C800A4;\
+border-color: #000000\
+}\
+.ace-xcode .ace_entity.ace_name.ace_tag,\
+.ace-xcode .ace_support.ace_class,\
+.ace-xcode .ace_support.ace_type {\
+color: #790EAD\
+}\
+.ace-xcode .ace_storage {\
+color: #C900A4\
+}\
+.ace-xcode .ace_string {\
+color: #DF0002\
+}\
+.ace-xcode .ace_comment {\
+color: #008E00\
+}\
+.ace-xcode .ace_indent-guide {\
+background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==) right repeat-y\
+}";
+
+var dom = require("../lib/dom");
+dom.importCssString(exports.cssText, exports.cssClass);
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-coffee.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-coffee.js
new file mode 100644
index 00000000..7fca2604
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-coffee.js
@@ -0,0 +1,2157 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/coffee/coffee",["require","exports","module"], function(require, exports, module) {
+function define(f) { module.exports = f() }; define.amd = {};
+(function(root){var CoffeeScript=function(){function _dereq_(e){return _dereq_[e]}return _dereq_["./helpers"]=function(){var e={},t={exports:e};return function(){var t,n,i,r,s,o;e.starts=function(e,t,n){return t===e.substr(n,t.length)},e.ends=function(e,t,n){var i;return i=t.length,t===e.substr(e.length-i-(n||0),i)},e.repeat=s=function(e,t){var n;for(n="";t>0;)1&t&&(n+=e),t>>>=1,e+=e;return n},e.compact=function(e){var t,n,i,r;for(r=[],t=0,i=e.length;i>t;t++)n=e[t],n&&r.push(n);return r},e.count=function(e,t){var n,i;if(n=i=0,!t.length)return 1/0;for(;i=1+e.indexOf(t,i);)n++;return n},e.merge=function(e,t){return n(n({},e),t)},n=e.extend=function(e,t){var n,i;for(n in t)i=t[n],e[n]=i;return e},e.flatten=i=function(e){var t,n,r,s;for(n=[],r=0,s=e.length;s>r;r++)t=e[r],t instanceof Array?n=n.concat(i(t)):n.push(t);return n},e.del=function(e,t){var n;return n=e[t],delete e[t],n},e.some=null!=(r=Array.prototype.some)?r:function(e){var t,n,i;for(n=0,i=this.length;i>n;n++)if(t=this[n],e(t))return!0;return!1},e.invertLiterate=function(e){var t,n,i;return i=!0,n=function(){var n,r,s,o;for(s=e.split("\n"),o=[],n=0,r=s.length;r>n;n++)t=s[n],i&&/^([ ]{4}|[ ]{0,3}\t)/.test(t)?o.push(t):(i=/^\s*$/.test(t))?o.push(t):o.push("# "+t);return o}(),n.join("\n")},t=function(e,t){return t?{first_line:e.first_line,first_column:e.first_column,last_line:t.last_line,last_column:t.last_column}:e},e.addLocationDataFn=function(e,n){return function(i){return"object"==typeof i&&i.updateLocationDataIfMissing&&i.updateLocationDataIfMissing(t(e,n)),i}},e.locationDataToString=function(e){var t;return"2"in e&&"first_line"in e[2]?t=e[2]:"first_line"in e&&(t=e),t?t.first_line+1+":"+(t.first_column+1)+"-"+(t.last_line+1+":"+(t.last_column+1)):"No location data"},e.baseFileName=function(e,t,n){var i,r;return null==t&&(t=!1),null==n&&(n=!1),r=n?/\\|\//:/\//,i=e.split(r),e=i[i.length-1],t&&e.indexOf(".")>=0?(i=e.split("."),i.pop(),"coffee"===i[i.length-1]&&i.length>1&&i.pop(),i.join(".")):e},e.isCoffee=function(e){return/\.((lit)?coffee|coffee\.md)$/.test(e)},e.isLiterate=function(e){return/\.(litcoffee|coffee\.md)$/.test(e)},e.throwSyntaxError=function(e,t){var n;throw n=new SyntaxError(e),n.location=t,n.toString=o,n.stack=""+n,n},e.updateSyntaxError=function(e,t,n){return e.toString===o&&(e.code||(e.code=t),e.filename||(e.filename=n),e.stack=""+e),e},o=function(){var e,t,n,i,r,o,a,c,h,l,u,p,d,f,m;return this.code&&this.location?(u=this.location,a=u.first_line,o=u.first_column,h=u.last_line,c=u.last_column,null==h&&(h=a),null==c&&(c=o),r=this.filename||"[stdin]",e=this.code.split("\n")[a],m=o,i=a===h?c+1:e.length,l=e.slice(0,m).replace(/[^\s]/g," ")+s("^",i-m),"undefined"!=typeof process&&null!==process&&(n=(null!=(p=process.stdout)?p.isTTY:void 0)&&!(null!=(d=process.env)?d.NODE_DISABLE_COLORS:void 0)),(null!=(f=this.colorful)?f:n)&&(t=function(e){return""+e+""},e=e.slice(0,m)+t(e.slice(m,i))+e.slice(i),l=t(l)),r+":"+(a+1)+":"+(o+1)+": error: "+this.message+"\n"+e+"\n"+l):Error.prototype.toString.call(this)},e.nameWhitespaceCharacter=function(e){switch(e){case" ":return"space";case"\n":return"newline";case"\r":return"carriage return";case" ":return"tab";default:return e}}}.call(this),t.exports}(),_dereq_["./rewriter"]=function(){var e={},t={exports:e};return function(){var t,n,i,r,s,o,a,c,h,l,u,p,d,f,m,g,v,y,b,k=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(t in this&&this[t]===e)return t;return-1},w=[].slice;for(f=function(e,t,n){var i;return i=[e,t],i.generated=!0,n&&(i.origin=n),i},e.Rewriter=function(){function e(){}return e.prototype.rewrite=function(e){return this.tokens=e,this.removeLeadingNewlines(),this.closeOpenCalls(),this.closeOpenIndexes(),this.normalizeLines(),this.tagPostfixConditionals(),this.addImplicitBracesAndParens(),this.addLocationDataToGeneratedTokens(),this.tokens},e.prototype.scanTokens=function(e){var t,n,i;for(i=this.tokens,t=0;n=i[t];)t+=e.call(this,n,t,i);return!0},e.prototype.detectEnd=function(e,t,n){var i,o,a,c,h;for(h=this.tokens,i=0;c=h[e];){if(0===i&&t.call(this,c,e))return n.call(this,c,e);if(!c||0>i)return n.call(this,c,e-1);o=c[0],k.call(s,o)>=0?i+=1:(a=c[0],k.call(r,a)>=0&&(i-=1)),e+=1}return e-1},e.prototype.removeLeadingNewlines=function(){var e,t,n,i,r;for(i=this.tokens,e=t=0,n=i.length;n>t&&(r=i[e][0],"TERMINATOR"===r);e=++t);return e?this.tokens.splice(0,e):void 0},e.prototype.closeOpenCalls=function(){var e,t;return t=function(e,t){var n;return")"===(n=e[0])||"CALL_END"===n||"OUTDENT"===e[0]&&")"===this.tag(t-1)},e=function(e,t){return this.tokens["OUTDENT"===e[0]?t-1:t][0]="CALL_END"},this.scanTokens(function(n,i){return"CALL_START"===n[0]&&this.detectEnd(i+1,t,e),1})},e.prototype.closeOpenIndexes=function(){var e,t;return t=function(e){var t;return"]"===(t=e[0])||"INDEX_END"===t},e=function(e){return e[0]="INDEX_END"},this.scanTokens(function(n,i){return"INDEX_START"===n[0]&&this.detectEnd(i+1,t,e),1})},e.prototype.indexOfTag=function(){var e,t,n,i,r,s,o;for(t=arguments[0],r=arguments.length>=2?w.call(arguments,1):[],e=0,n=i=0,s=r.length;s>=0?s>i:i>s;n=s>=0?++i:--i){for(;"HERECOMMENT"===this.tag(t+n+e);)e+=2;if(null!=r[n]&&("string"==typeof r[n]&&(r[n]=[r[n]]),o=this.tag(t+n+e),0>k.call(r[n],o)))return-1}return t+n+e-1},e.prototype.looksObjectish=function(e){var t,n;return this.indexOfTag(e,"@",null,":")>-1||this.indexOfTag(e,null,":")>-1?!0:(n=this.indexOfTag(e,s),n>-1&&(t=null,this.detectEnd(n+1,function(e){var t;return t=e[0],k.call(r,t)>=0},function(e,n){return t=n}),":"===this.tag(t+1))?!0:!1)},e.prototype.findTagsBackwards=function(e,t){var n,i,o,a,c,h,l;for(n=[];e>=0&&(n.length||(a=this.tag(e),0>k.call(t,a)&&(c=this.tag(e),0>k.call(s,c)||this.tokens[e].generated)&&(h=this.tag(e),0>k.call(u,h))));)i=this.tag(e),k.call(r,i)>=0&&n.push(this.tag(e)),o=this.tag(e),k.call(s,o)>=0&&n.length&&n.pop(),e-=1;return l=this.tag(e),k.call(t,l)>=0},e.prototype.addImplicitBracesAndParens=function(){var e,t;return e=[],t=null,this.scanTokens(function(i,l,p){var d,m,g,v,y,b,w,T,C,E,F,N,L,x,S,D,R,A,I,_,O,$,j,M,B,V,P,U;if(U=i[0],F=(N=l>0?p[l-1]:[])[0],C=(p.length-1>l?p[l+1]:[])[0],j=function(){return e[e.length-1]},M=l,g=function(e){return l-M+e},v=function(){var e,t;return null!=(e=j())?null!=(t=e[2])?t.ours:void 0:void 0},y=function(){var e;return v()&&"("===(null!=(e=j())?e[0]:void 0)},w=function(){var e;return v()&&"{"===(null!=(e=j())?e[0]:void 0)},b=function(){var e;return v&&"CONTROL"===(null!=(e=j())?e[0]:void 0)},B=function(t){var n;return n=null!=t?t:l,e.push(["(",n,{ours:!0}]),p.splice(n,0,f("CALL_START","(")),null==t?l+=1:void 0},d=function(){return e.pop(),p.splice(l,0,f("CALL_END",")",["","end of input",i[2]])),l+=1},V=function(t,n){var r,s;return null==n&&(n=!0),r=null!=t?t:l,e.push(["{",r,{sameLine:!0,startsLine:n,ours:!0}]),s=new String("{"),s.generated=!0,p.splice(r,0,f("{",s,i)),null==t?l+=1:void 0},m=function(t){return t=null!=t?t:l,e.pop(),p.splice(t,0,f("}","}",i)),l+=1},y()&&("IF"===U||"TRY"===U||"FINALLY"===U||"CATCH"===U||"CLASS"===U||"SWITCH"===U))return e.push(["CONTROL",l,{ours:!0}]),g(1);if("INDENT"===U&&v()){if("=>"!==F&&"->"!==F&&"["!==F&&"("!==F&&","!==F&&"{"!==F&&"TRY"!==F&&"ELSE"!==F&&"="!==F)for(;y();)d();return b()&&e.pop(),e.push([U,l]),g(1)}if(k.call(s,U)>=0)return e.push([U,l]),g(1);if(k.call(r,U)>=0){for(;v();)y()?d():w()?m():e.pop();t=e.pop()}if((k.call(c,U)>=0&&i.spaced||"?"===U&&l>0&&!p[l-1].spaced)&&(k.call(o,C)>=0||k.call(h,C)>=0&&!(null!=(L=p[l+1])?L.spaced:void 0)&&!(null!=(x=p[l+1])?x.newLine:void 0)))return"?"===U&&(U=i[0]="FUNC_EXIST"),B(l+1),g(2);if(k.call(c,U)>=0&&this.indexOfTag(l+1,"INDENT")>-1&&this.looksObjectish(l+2)&&!this.findTagsBackwards(l,["CLASS","EXTENDS","IF","CATCH","SWITCH","LEADING_WHEN","FOR","WHILE","UNTIL"]))return B(l+1),e.push(["INDENT",l+2]),g(3);if(":"===U){for(I=function(){var e;switch(!1){case e=this.tag(l-1),0>k.call(r,e):return t[1];case"@"!==this.tag(l-2):return l-2;default:return l-1}}.call(this);"HERECOMMENT"===this.tag(I-2);)I-=2;return this.insideForDeclaration="FOR"===C,P=0===I||(S=this.tag(I-1),k.call(u,S)>=0)||p[I-1].newLine,j()&&(D=j(),$=D[0],O=D[1],("{"===$||"INDENT"===$&&"{"===this.tag(O-1))&&(P||","===this.tag(I-1)||"{"===this.tag(I-1)))?g(1):(V(I,!!P),g(2))}if(w()&&k.call(u,U)>=0&&(j()[2].sameLine=!1),T="OUTDENT"===F||N.newLine,k.call(a,U)>=0||k.call(n,U)>=0&&T)for(;v();)if(R=j(),$=R[0],O=R[1],A=R[2],_=A.sameLine,P=A.startsLine,y()&&","!==F)d();else if(w()&&!this.insideForDeclaration&&_&&"TERMINATOR"!==U&&":"!==F)m();else{if(!w()||"TERMINATOR"!==U||","===F||P&&this.looksObjectish(l+1))break;if("HERECOMMENT"===C)return g(1);m()}if(!(","!==U||this.looksObjectish(l+1)||!w()||this.insideForDeclaration||"TERMINATOR"===C&&this.looksObjectish(l+2)))for(E="OUTDENT"===C?1:0;w();)m(l+E);return g(1)})},e.prototype.addLocationDataToGeneratedTokens=function(){return this.scanTokens(function(e,t,n){var i,r,s,o,a,c;return e[2]?1:e.generated||e.explicit?("{"===e[0]&&(s=null!=(a=n[t+1])?a[2]:void 0)?(r=s.first_line,i=s.first_column):(o=null!=(c=n[t-1])?c[2]:void 0)?(r=o.last_line,i=o.last_column):r=i=0,e[2]={first_line:r,first_column:i,last_line:r,last_column:i},1):1})},e.prototype.normalizeLines=function(){var e,t,r,s,o;return o=r=s=null,t=function(e,t){var r,s,a,c;return";"!==e[1]&&(r=e[0],k.call(p,r)>=0)&&!("TERMINATOR"===e[0]&&(s=this.tag(t+1),k.call(i,s)>=0))&&!("ELSE"===e[0]&&"THEN"!==o)&&!!("CATCH"!==(a=e[0])&&"FINALLY"!==a||"->"!==o&&"=>"!==o)||(c=e[0],k.call(n,c)>=0&&this.tokens[t-1].newLine)},e=function(e,t){return this.tokens.splice(","===this.tag(t-1)?t-1:t,0,s)},this.scanTokens(function(n,a,c){var h,l,u,p,f,m;if(m=n[0],"TERMINATOR"===m){if("ELSE"===this.tag(a+1)&&"OUTDENT"!==this.tag(a-1))return c.splice.apply(c,[a,1].concat(w.call(this.indentation()))),1;if(u=this.tag(a+1),k.call(i,u)>=0)return c.splice(a,1),0}if("CATCH"===m)for(h=l=1;2>=l;h=++l)if("OUTDENT"===(p=this.tag(a+h))||"TERMINATOR"===p||"FINALLY"===p)return c.splice.apply(c,[a+h,0].concat(w.call(this.indentation()))),2+h;return k.call(d,m)>=0&&"INDENT"!==this.tag(a+1)&&("ELSE"!==m||"IF"!==this.tag(a+1))?(o=m,f=this.indentation(c[a]),r=f[0],s=f[1],"THEN"===o&&(r.fromThen=!0),c.splice(a+1,0,r),this.detectEnd(a+2,t,e),"THEN"===m&&c.splice(a,1),1):1})},e.prototype.tagPostfixConditionals=function(){var e,t,n;return n=null,t=function(e,t){var n,i;return i=e[0],n=this.tokens[t-1][0],"TERMINATOR"===i||"INDENT"===i&&0>k.call(d,n)},e=function(e){return"INDENT"!==e[0]||e.generated&&!e.fromThen?n[0]="POST_"+n[0]:void 0},this.scanTokens(function(i,r){return"IF"!==i[0]?1:(n=i,this.detectEnd(r+1,t,e),1)})},e.prototype.indentation=function(e){var t,n;return t=["INDENT",2],n=["OUTDENT",2],e?(t.generated=n.generated=!0,t.origin=n.origin=e):t.explicit=n.explicit=!0,[t,n]},e.prototype.generate=f,e.prototype.tag=function(e){var t;return null!=(t=this.tokens[e])?t[0]:void 0},e}(),t=[["(",")"],["[","]"],["{","}"],["INDENT","OUTDENT"],["CALL_START","CALL_END"],["PARAM_START","PARAM_END"],["INDEX_START","INDEX_END"],["STRING_START","STRING_END"],["REGEX_START","REGEX_END"]],e.INVERSES=l={},s=[],r=[],m=0,v=t.length;v>m;m++)y=t[m],g=y[0],b=y[1],s.push(l[b]=g),r.push(l[g]=b);i=["CATCH","THEN","ELSE","FINALLY"].concat(r),c=["IDENTIFIER","SUPER",")","CALL_END","]","INDEX_END","@","THIS"],o=["IDENTIFIER","NUMBER","STRING","STRING_START","JS","REGEX","REGEX_START","NEW","PARAM_START","CLASS","IF","TRY","SWITCH","THIS","BOOL","NULL","UNDEFINED","UNARY","YIELD","UNARY_MATH","SUPER","THROW","@","->","=>","[","(","{","--","++"],h=["+","-"],a=["POST_IF","FOR","WHILE","UNTIL","WHEN","BY","LOOP","TERMINATOR"],d=["ELSE","->","=>","TRY","FINALLY","THEN"],p=["TERMINATOR","CATCH","FINALLY","ELSE","OUTDENT","LEADING_WHEN"],u=["TERMINATOR","INDENT","OUTDENT"],n=[".","?.","::","?::"]}.call(this),t.exports}(),_dereq_["./lexer"]=function(){var e={},t={exports:e};return function(){var t,n,i,r,s,o,a,c,h,l,u,p,d,f,m,g,v,y,b,k,w,T,C,E,F,N,L,x,S,D,R,A,I,_,O,$,j,M,B,V,P,U,G,H,q,X,W,Y,K,z,J,Q,Z,et,tt,nt,it,rt,st,ot,at,ct,ht,lt,ut=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(t in this&&this[t]===e)return t;return-1};ot=_dereq_("./rewriter"),P=ot.Rewriter,w=ot.INVERSES,at=_dereq_("./helpers"),nt=at.count,ht=at.starts,tt=at.compact,ct=at.repeat,it=at.invertLiterate,st=at.locationDataToString,lt=at.throwSyntaxError,e.Lexer=S=function(){function e(){}return e.prototype.tokenize=function(e,t){var n,i,r,s;for(null==t&&(t={}),this.literate=t.literate,this.indent=0,this.baseIndent=0,this.indebt=0,this.outdebt=0,this.indents=[],this.ends=[],this.tokens=[],this.chunkLine=t.line||0,this.chunkColumn=t.column||0,e=this.clean(e),r=0;this.chunk=e.slice(r);)if(n=this.identifierToken()||this.commentToken()||this.whitespaceToken()||this.lineToken()||this.stringToken()||this.numberToken()||this.regexToken()||this.jsToken()||this.literalToken(),s=this.getLineAndColumnFromChunk(n),this.chunkLine=s[0],this.chunkColumn=s[1],r+=n,t.untilBalanced&&0===this.ends.length)return{tokens:this.tokens,index:r};return this.closeIndentation(),(i=this.ends.pop())&&this.error("missing "+i.tag,i.origin[2]),t.rewrite===!1?this.tokens:(new P).rewrite(this.tokens)},e.prototype.clean=function(e){return e.charCodeAt(0)===t&&(e=e.slice(1)),e=e.replace(/\r/g,"").replace(z,""),et.test(e)&&(e="\n"+e,this.chunkLine--),this.literate&&(e=it(e)),e},e.prototype.identifierToken=function(){var e,t,n,i,r,c,h,l,u,p,d,f,m,g,y,b;return(l=v.exec(this.chunk))?(h=l[0],r=l[1],t=l[2],c=r.length,u=void 0,"own"===r&&"FOR"===this.tag()?(this.token("OWN",r),r.length):"from"===r&&"YIELD"===this.tag()?(this.token("FROM",r),r.length):(d=this.tokens,p=d[d.length-1],i=t||null!=p&&("."===(f=p[0])||"?."===f||"::"===f||"?::"===f||!p.spaced&&"@"===p[0]),y="IDENTIFIER",!i&&(ut.call(E,r)>=0||ut.call(a,r)>=0)&&(y=r.toUpperCase(),"WHEN"===y&&(m=this.tag(),ut.call(N,m)>=0)?y="LEADING_WHEN":"FOR"===y?this.seenFor=!0:"UNLESS"===y?y="IF":ut.call(J,y)>=0?y="UNARY":ut.call(B,y)>=0&&("INSTANCEOF"!==y&&this.seenFor?(y="FOR"+y,this.seenFor=!1):(y="RELATION","!"===this.value()&&(u=this.tokens.pop(),r="!"+r)))),ut.call(C,r)>=0&&(i?(y="IDENTIFIER",r=new String(r),r.reserved=!0):ut.call(V,r)>=0&&this.error("reserved word '"+r+"'",{length:r.length})),i||(ut.call(s,r)>=0&&(e=r,r=o[r]),y=function(){switch(r){case"!":return"UNARY";case"==":case"!=":return"COMPARE";case"&&":case"||":return"LOGIC";case"true":case"false":return"BOOL";case"break":case"continue":return"STATEMENT";default:return y}}()),b=this.token(y,r,0,c),e&&(b.origin=[y,e,b[2]]),b.variable=!i,u&&(g=[u[2].first_line,u[2].first_column],b[2].first_line=g[0],b[2].first_column=g[1]),t&&(n=h.lastIndexOf(":"),this.token(":",":",n,t.length)),h.length)):0},e.prototype.numberToken=function(){var e,t,n,i,r;return(n=I.exec(this.chunk))?(i=n[0],t=i.length,/^0[BOX]/.test(i)?this.error("radix prefix in '"+i+"' must be lowercase",{offset:1}):/E/.test(i)&&!/^0x/.test(i)?this.error("exponential notation in '"+i+"' must be indicated with a lowercase 'e'",{offset:i.indexOf("E")}):/^0\d*[89]/.test(i)?this.error("decimal literal '"+i+"' must not be prefixed with '0'",{length:t}):/^0\d+/.test(i)&&this.error("octal literal '"+i+"' must be prefixed with '0o'",{length:t}),(r=/^0o([0-7]+)/.exec(i))&&(i="0x"+parseInt(r[1],8).toString(16)),(e=/^0b([01]+)/.exec(i))&&(i="0x"+parseInt(e[1],2).toString(16)),this.token("NUMBER",i,0,t),t):0},e.prototype.stringToken=function(){var e,t,n,i,r,s,o,a,c,h,l,u,m,g,v,y;if(l=(Y.exec(this.chunk)||[])[0],!l)return 0;if(g=function(){switch(l){case"'":return W;case'"':return q;case"'''":return f;case'"""':return p}}(),s=3===l.length,u=this.matchWithInterpolations(g,l),y=u.tokens,r=u.index,e=y.length-1,n=l.charAt(0),s){for(a=null,i=function(){var e,t,n;for(n=[],o=e=0,t=y.length;t>e;o=++e)v=y[o],"NEOSTRING"===v[0]&&n.push(v[1]);return n}().join("#{}");h=d.exec(i);)t=h[1],(null===a||(m=t.length)>0&&a.length>m)&&(a=t);a&&(c=RegExp("^"+a,"gm")),this.mergeInterpolationTokens(y,{delimiter:n},function(t){return function(n,i){return n=t.formatString(n),0===i&&(n=n.replace(F,"")),i===e&&(n=n.replace(K,"")),c&&(n=n.replace(c,"")),n}}(this))}else this.mergeInterpolationTokens(y,{delimiter:n},function(t){return function(n,i){return n=t.formatString(n),n=n.replace(G,function(t,r){return 0===i&&0===r||i===e&&r+t.length===n.length?"":" "})}}(this));return r},e.prototype.commentToken=function(){var e,t,n;return(n=this.chunk.match(c))?(e=n[0],t=n[1],t&&((n=u.exec(e))&&this.error("block comments cannot contain "+n[0],{offset:n.index,length:n[0].length}),t.indexOf("\n")>=0&&(t=t.replace(RegExp("\\n"+ct(" ",this.indent),"g"),"\n")),this.token("HERECOMMENT",t,0,e.length)),e.length):0},e.prototype.jsToken=function(){var e,t;return"`"===this.chunk.charAt(0)&&(e=T.exec(this.chunk))?(this.token("JS",(t=e[0]).slice(1,-1),0,t.length),t.length):0},e.prototype.regexToken=function(){var e,t,n,r,s,o,a,c,h,l,u,p,d;switch(!1){case!(o=M.exec(this.chunk)):this.error("regular expressions cannot begin with "+o[2],{offset:o.index+o[1].length});break;case!(o=this.matchWithInterpolations(m,"///")):d=o.tokens,s=o.index;break;case!(o=$.exec(this.chunk)):if(p=o[0],e=o[1],t=o[2],this.validateEscapes(e,{isRegex:!0,offsetInChunk:1}),s=p.length,h=this.tokens,c=h[h.length-1],c)if(c.spaced&&(l=c[0],ut.call(i,l)>=0)){if(!t||O.test(p))return 0}else if(u=c[0],ut.call(A,u)>=0)return 0;t||this.error("missing / (unclosed regex)");break;default:return 0}switch(r=j.exec(this.chunk.slice(s))[0],n=s+r.length,a=this.makeToken("REGEX",null,0,n),!1){case!!Z.test(r):this.error("invalid regular expression flags "+r,{offset:s,length:r.length});break;case!(p||1===d.length):null==e&&(e=this.formatHeregex(d[0][1])),this.token("REGEX",""+this.makeDelimitedLiteral(e,{delimiter:"/"})+r,0,n,a);break;default:this.token("REGEX_START","(",0,0,a),this.token("IDENTIFIER","RegExp",0,0),this.token("CALL_START","(",0,0),this.mergeInterpolationTokens(d,{delimiter:'"',"double":!0},this.formatHeregex),r&&(this.token(",",",",s,0),this.token("STRING",'"'+r+'"',s,r.length)),this.token(")",")",n,0),this.token("REGEX_END",")",n,0)}return n},e.prototype.lineToken=function(){var e,t,n,i,r;if(!(n=R.exec(this.chunk)))return 0;if(t=n[0],this.seenFor=!1,r=t.length-1-t.lastIndexOf("\n"),i=this.unfinished(),r-this.indebt===this.indent)return i?this.suppressNewlines():this.newlineToken(0),t.length;if(r>this.indent){if(i)return this.indebt=r-this.indent,this.suppressNewlines(),t.length;if(!this.tokens.length)return this.baseIndent=this.indent=r,t.length;e=r-this.indent+this.outdebt,this.token("INDENT",e,t.length-r,r),this.indents.push(e),this.ends.push({tag:"OUTDENT"}),this.outdebt=this.indebt=0,this.indent=r}else this.baseIndent>r?this.error("missing indentation",{offset:t.length}):(this.indebt=0,this.outdentToken(this.indent-r,i,t.length));return t.length},e.prototype.outdentToken=function(e,t,n){var i,r,s,o;for(i=this.indent-e;e>0;)s=this.indents[this.indents.length-1],s?s===this.outdebt?(e-=this.outdebt,this.outdebt=0):this.outdebt>s?(this.outdebt-=s,e-=s):(r=this.indents.pop()+this.outdebt,n&&(o=this.chunk[n],ut.call(y,o)>=0)&&(i-=r-e,e=r),this.outdebt=0,this.pair("OUTDENT"),this.token("OUTDENT",e,0,n),e-=r):e=0;for(r&&(this.outdebt-=e);";"===this.value();)this.tokens.pop();return"TERMINATOR"===this.tag()||t||this.token("TERMINATOR","\n",n,0),this.indent=i,this},e.prototype.whitespaceToken=function(){var e,t,n,i;return(e=et.exec(this.chunk))||(t="\n"===this.chunk.charAt(0))?(i=this.tokens,n=i[i.length-1],n&&(n[e?"spaced":"newLine"]=!0),e?e[0].length:0):0},e.prototype.newlineToken=function(e){for(;";"===this.value();)this.tokens.pop();return"TERMINATOR"!==this.tag()&&this.token("TERMINATOR","\n",e,0),this},e.prototype.suppressNewlines=function(){return"\\"===this.value()&&this.tokens.pop(),this},e.prototype.literalToken=function(){var e,t,n,s,o,a,c,u,p,d;if((e=_.exec(this.chunk))?(d=e[0],r.test(d)&&this.tagParameters()):d=this.chunk.charAt(0),u=d,n=this.tokens,t=n[n.length-1],"="===d&&t&&(!t[1].reserved&&(s=t[1],ut.call(C,s)>=0)&&(t.origin&&(t=t.origin),this.error("reserved word '"+t[1]+"' can't be assigned",t[2])),"||"===(o=t[1])||"&&"===o))return t[0]="COMPOUND_ASSIGN",t[1]+="=",d.length;if(";"===d)this.seenFor=!1,u="TERMINATOR";else if(ut.call(D,d)>=0)u="MATH";else if(ut.call(h,d)>=0)u="COMPARE";else if(ut.call(l,d)>=0)u="COMPOUND_ASSIGN";else if(ut.call(J,d)>=0)u="UNARY";else if(ut.call(Q,d)>=0)u="UNARY_MATH";else if(ut.call(U,d)>=0)u="SHIFT";else if(ut.call(x,d)>=0||"?"===d&&(null!=t?t.spaced:void 0))u="LOGIC";else if(t&&!t.spaced)if("("===d&&(a=t[0],ut.call(i,a)>=0))"?"===t[0]&&(t[0]="FUNC_EXIST"),u="CALL_START";else if("["===d&&(c=t[0],ut.call(b,c)>=0))switch(u="INDEX_START",t[0]){case"?":t[0]="INDEX_SOAK"}switch(p=this.makeToken(u,d),d){case"(":case"{":case"[":this.ends.push({tag:w[d],origin:p});break;case")":case"}":case"]":this.pair(d)}return this.tokens.push(p),d.length},e.prototype.tagParameters=function(){var e,t,n,i;if(")"!==this.tag())return this;for(t=[],i=this.tokens,e=i.length,i[--e][0]="PARAM_END";n=i[--e];)switch(n[0]){case")":t.push(n);break;case"(":case"CALL_START":if(!t.length)return"("===n[0]?(n[0]="PARAM_START",this):this;t.pop()}return this},e.prototype.closeIndentation=function(){return this.outdentToken(this.indent)},e.prototype.matchWithInterpolations=function(t,n){var i,r,s,o,a,c,h,l,u,p,d,f,m,g,v;if(v=[],l=n.length,this.chunk.slice(0,l)!==n)return null;for(m=this.chunk.slice(l);;){if(g=t.exec(m)[0],this.validateEscapes(g,{isRegex:"/"===n.charAt(0),offsetInChunk:l}),v.push(this.makeToken("NEOSTRING",g,l)),m=m.slice(g.length),l+=g.length,"#{"!==m.slice(0,2))break;p=this.getLineAndColumnFromChunk(l+1),c=p[0],r=p[1],d=(new e).tokenize(m.slice(1),{line:c,column:r,untilBalanced:!0}),h=d.tokens,o=d.index,o+=1,u=h[0],i=h[h.length-1],u[0]=u[1]="(",i[0]=i[1]=")",i.origin=["","end of interpolation",i[2]],"TERMINATOR"===(null!=(f=h[1])?f[0]:void 0)&&h.splice(1,1),v.push(["TOKENS",h]),m=m.slice(o),l+=o}return m.slice(0,n.length)!==n&&this.error("missing "+n,{length:n.length}),s=v[0],a=v[v.length-1],s[2].first_column-=n.length,a[2].last_column+=n.length,0===a[1].length&&(a[2].last_column-=1),{tokens:v,index:l+n.length}},e.prototype.mergeInterpolationTokens=function(e,t,n){var i,r,s,o,a,c,h,l,u,p,d,f,m,g,v,y;for(e.length>1&&(u=this.token("STRING_START","(",0,0)),s=this.tokens.length,o=a=0,h=e.length;h>a;o=++a){switch(g=e[o],m=g[0],y=g[1],m){case"TOKENS":if(2===y.length)continue;l=y[0],v=y;break;case"NEOSTRING":if(i=n(g[1],o),0===i.length){if(0!==o)continue;r=this.tokens.length}2===o&&null!=r&&this.tokens.splice(r,2),g[0]="STRING",g[1]=this.makeDelimitedLiteral(i,t),l=g,v=[g]}this.tokens.length>s&&(p=this.token("+","+"),p[2]={first_line:l[2].first_line,first_column:l[2].first_column,last_line:l[2].first_line,last_column:l[2].first_column}),(d=this.tokens).push.apply(d,v)}return u?(c=e[e.length-1],u.origin=["STRING",null,{first_line:u[2].first_line,first_column:u[2].first_column,last_line:c[2].last_line,last_column:c[2].last_column}],f=this.token("STRING_END",")"),f[2]={first_line:c[2].last_line,first_column:c[2].last_column,last_line:c[2].last_line,last_column:c[2].last_column}):void 0},e.prototype.pair=function(e){var t,n,i,r,s;return i=this.ends,n=i[i.length-1],e!==(s=null!=n?n.tag:void 0)?("OUTDENT"!==s&&this.error("unmatched "+e),r=this.indents,t=r[r.length-1],this.outdentToken(t,!0),this.pair(e)):this.ends.pop()},e.prototype.getLineAndColumnFromChunk=function(e){var t,n,i,r,s;return 0===e?[this.chunkLine,this.chunkColumn]:(s=e>=this.chunk.length?this.chunk:this.chunk.slice(0,+(e-1)+1||9e9),i=nt(s,"\n"),t=this.chunkColumn,i>0?(r=s.split("\n"),n=r[r.length-1],t=n.length):t+=s.length,[this.chunkLine+i,t])},e.prototype.makeToken=function(e,t,n,i){var r,s,o,a,c;return null==n&&(n=0),null==i&&(i=t.length),s={},o=this.getLineAndColumnFromChunk(n),s.first_line=o[0],s.first_column=o[1],r=Math.max(0,i-1),a=this.getLineAndColumnFromChunk(n+r),s.last_line=a[0],s.last_column=a[1],c=[e,t,s]},e.prototype.token=function(e,t,n,i,r){var s;return s=this.makeToken(e,t,n,i),r&&(s.origin=r),this.tokens.push(s),s},e.prototype.tag=function(){var e,t;return e=this.tokens,t=e[e.length-1],null!=t?t[0]:void 0},e.prototype.value=function(){var e,t;return e=this.tokens,t=e[e.length-1],null!=t?t[1]:void 0},e.prototype.unfinished=function(){var e;return L.test(this.chunk)||"\\"===(e=this.tag())||"."===e||"?."===e||"?::"===e||"UNARY"===e||"MATH"===e||"UNARY_MATH"===e||"+"===e||"-"===e||"YIELD"===e||"**"===e||"SHIFT"===e||"RELATION"===e||"COMPARE"===e||"LOGIC"===e||"THROW"===e||"EXTENDS"===e},e.prototype.formatString=function(e){return e.replace(X,"$1")},e.prototype.formatHeregex=function(e){return e.replace(g,"$1$2")},e.prototype.validateEscapes=function(e,t){var n,i,r,s,o,a,c,h;return null==t&&(t={}),s=k.exec(e),!s||(s[0],n=s[1],a=s[2],i=s[3],h=s[4],t.isRegex&&a&&"0"!==a.charAt(0))?void 0:(o=a?"octal escape sequences are not allowed":"invalid escape sequence",r="\\"+(a||i||h),this.error(o+" "+r,{offset:(null!=(c=t.offsetInChunk)?c:0)+s.index+n.length,length:r.length}))},e.prototype.makeDelimitedLiteral=function(e,t){var n;return null==t&&(t={}),""===e&&"/"===t.delimiter&&(e="(?:)"),n=RegExp("(\\\\\\\\)|(\\\\0(?=[1-7]))|\\\\?("+t.delimiter+")|\\\\?(?:(\\n)|(\\r)|(\\u2028)|(\\u2029))|(\\\\.)","g"),e=e.replace(n,function(e,n,i,r,s,o,a,c,h){switch(!1){case!n:return t.double?n+n:n;case!i:return"\\x00";case!r:return"\\"+r;case!s:return"\\n";case!o:return"\\r";case!a:return"\\u2028";case!c:return"\\u2029";case!h:return t.double?"\\"+h:h}}),""+t.delimiter+e+t.delimiter},e.prototype.error=function(e,t){var n,i,r,s,o,a;return null==t&&(t={}),r="first_line"in t?t:(o=this.getLineAndColumnFromChunk(null!=(s=t.offset)?s:0),i=o[0],n=o[1],o,{first_line:i,first_column:n,last_column:n+(null!=(a=t.length)?a:1)-1}),lt(e,r)},e}(),E=["true","false","null","this","new","delete","typeof","in","instanceof","return","throw","break","continue","debugger","yield","if","else","switch","for","while","do","try","catch","finally","class","extends","super"],a=["undefined","then","unless","until","loop","of","by","when"],o={and:"&&",or:"||",is:"==",isnt:"!=",not:"!",yes:"true",no:"false",on:"true",off:"false"},s=function(){var e;e=[];for(rt in o)e.push(rt);return e}(),a=a.concat(s),V=["case","default","function","var","void","with","const","let","enum","export","import","native","implements","interface","package","private","protected","public","static"],H=["arguments","eval","yield*"],C=E.concat(V).concat(H),e.RESERVED=V.concat(E).concat(a).concat(H),e.STRICT_PROSCRIBED=H,t=65279,v=/^(?!\d)((?:(?!\s)[$\w\x7f-\uffff])+)([^\n\S]*:(?!:))?/,I=/^0b[01]+|^0o[0-7]+|^0x[\da-f]+|^\d*\.?\d+(?:e[+-]?\d+)?/i,_=/^(?:[-=]>|[-+*\/%<>&|^!?=]=|>>>=?|([-+:])\1|([&|<>*\/%])\2=?|\?(\.|::)|\.{2,3})/,et=/^[^\n\S]+/,c=/^###([^#][\s\S]*?)(?:###[^\n\S]*|###$)|^(?:\s*#(?!##[^#]).*)+/,r=/^[-=]>/,R=/^(?:\n[^\n\S]*)+/,T=/^`[^\\`]*(?:\\.[^\\`]*)*`/,Y=/^(?:'''|"""|'|")/,W=/^(?:[^\\']|\\[\s\S])*/,q=/^(?:[^\\"#]|\\[\s\S]|\#(?!\{))*/,f=/^(?:[^\\']|\\[\s\S]|'(?!''))*/,p=/^(?:[^\\"#]|\\[\s\S]|"(?!"")|\#(?!\{))*/,X=/((?:\\\\)+)|\\[^\S\n]*\n\s*/g,G=/\s*\n\s*/g,d=/\n+([^\n\S]*)(?=\S)/g,$=/^\/(?!\/)((?:[^[\/\n\\]|\\[^\n]|\[(?:\\[^\n]|[^\]\n\\])*\])*)(\/)?/,j=/^\w*/,Z=/^(?!.*(.).*\1)[imgy]*$/,m=/^(?:[^\\\/#]|\\[\s\S]|\/(?!\/\/)|\#(?!\{))*/,g=/((?:\\\\)+)|\\(\s)|\s+(?:#.*)?/g,M=/^(\/|\/{3}\s*)(\*)/,O=/^\/=?\s/,u=/\*\//,L=/^\s*(?:,|\??\.(?![.\d])|::)/,k=/((?:^|[^\\])(?:\\\\)*)\\(?:(0[0-7]|[1-7])|(x(?![\da-fA-F]{2}).{0,2})|(u(?![\da-fA-F]{4}).{0,4}))/,F=/^[^\n\S]*\n/,K=/\n[^\n\S]*$/,z=/\s+$/,l=["-=","+=","/=","*=","%=","||=","&&=","?=","<<=",">>=",">>>=","&=","^=","|=","**=","//=","%%="],J=["NEW","TYPEOF","DELETE","DO"],Q=["!","~"],x=["&&","||","&","|","^"],U=["<<",">>",">>>"],h=["==","!=","<",">","<=",">="],D=["*","/","%","//","%%"],B=["IN","OF","INSTANCEOF"],n=["TRUE","FALSE"],i=["IDENTIFIER",")","]","?","@","THIS","SUPER"],b=i.concat(["NUMBER","STRING","STRING_END","REGEX","REGEX_END","BOOL","NULL","UNDEFINED","}","::"]),A=b.concat(["++","--"]),N=["INDENT","OUTDENT","TERMINATOR"],y=[")","}","]"]}.call(this),t.exports}(),_dereq_["./parser"]=function(){var e={},t={exports:e},n=function(){function e(){this.yy={}}var t=function(e,t,n,i){for(n=n||{},i=e.length;i--;n[e[i]]=t);return n},n=[1,20],i=[1,75],r=[1,71],s=[1,76],o=[1,77],a=[1,73],c=[1,74],h=[1,50],l=[1,52],u=[1,53],p=[1,54],d=[1,55],f=[1,45],m=[1,46],g=[1,27],v=[1,60],y=[1,61],b=[1,70],k=[1,43],w=[1,26],T=[1,58],C=[1,59],E=[1,57],F=[1,38],N=[1,44],L=[1,56],x=[1,65],S=[1,66],D=[1,67],R=[1,68],A=[1,42],I=[1,64],_=[1,29],O=[1,30],$=[1,31],j=[1,32],M=[1,33],B=[1,34],V=[1,35],P=[1,78],U=[1,6,26,34,108],G=[1,88],H=[1,81],q=[1,80],X=[1,79],W=[1,82],Y=[1,83],K=[1,84],z=[1,85],J=[1,86],Q=[1,87],Z=[1,91],et=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],tt=[1,97],nt=[1,98],it=[1,99],rt=[1,100],st=[1,102],ot=[1,103],at=[1,96],ct=[2,112],ht=[1,6,25,26,34,55,60,63,72,73,74,75,77,79,80,84,90,91,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],lt=[2,79],ut=[1,108],pt=[2,58],dt=[1,112],ft=[1,117],mt=[1,118],gt=[1,120],vt=[1,6,25,26,34,46,55,60,63,72,73,74,75,77,79,80,84,90,91,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],yt=[2,76],bt=[1,6,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],kt=[1,155],wt=[1,157],Tt=[1,152],Ct=[1,6,25,26,34,46,55,60,63,72,73,74,75,77,79,80,84,86,90,91,92,97,99,108,110,111,112,116,117,132,135,136,139,140,141,142,143,144,145,146,147,148],Et=[2,95],Ft=[1,6,25,26,34,49,55,60,63,72,73,74,75,77,79,80,84,90,91,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],Nt=[1,6,25,26,34,46,49,55,60,63,72,73,74,75,77,79,80,84,86,90,91,92,97,99,108,110,111,112,116,117,123,124,132,135,136,139,140,141,142,143,144,145,146,147,148],Lt=[1,206],xt=[1,205],St=[1,6,25,26,34,38,55,60,63,72,73,74,75,77,79,80,84,90,91,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],Dt=[2,56],Rt=[1,216],At=[6,25,26,55,60],It=[6,25,26,46,55,60,63],_t=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,135,136,142,144,145,146,147],Ot=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132],$t=[72,73,74,75,77,80,90,91],jt=[1,235],Mt=[2,133],Bt=[1,6,25,26,34,46,55,60,63,72,73,74,75,77,79,80,84,90,91,92,97,99,108,110,111,112,116,117,123,124,132,135,136,141,142,143,144,145,146,147],Vt=[1,244],Pt=[6,25,26,60,92,97],Ut=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,117,132],Gt=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,111,117,132],Ht=[123,124],qt=[60,123,124],Xt=[1,255],Wt=[6,25,26,60,84],Yt=[6,25,26,49,60,84],Kt=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,135,136,144,145,146,147],zt=[11,28,30,32,33,36,37,40,41,42,43,44,51,52,53,57,58,79,82,85,89,94,95,96,102,106,107,110,112,114,116,125,131,133,134,135,136,137,139,140],Jt=[2,122],Qt=[6,25,26],Zt=[2,57],en=[1,268],tn=[1,269],nn=[1,6,25,26,34,55,60,63,79,84,92,97,99,104,105,108,110,111,112,116,117,127,129,132,135,136,141,142,143,144,145,146,147],rn=[26,127,129],sn=[1,6,26,34,55,60,63,79,84,92,97,99,108,111,117,132],on=[2,71],an=[1,291],cn=[1,292],hn=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,127,132,135,136,141,142,143,144,145,146,147],ln=[1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,112,116,117,132],un=[1,303],pn=[1,304],dn=[6,25,26,60],fn=[1,6,25,26,34,55,60,63,79,84,92,97,99,104,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],mn=[25,60],gn={trace:function(){},yy:{},symbols_:{error:2,Root:3,Body:4,Line:5,TERMINATOR:6,Expression:7,Statement:8,Return:9,Comment:10,STATEMENT:11,Value:12,Invocation:13,Code:14,Operation:15,Assign:16,If:17,Try:18,While:19,For:20,Switch:21,Class:22,Throw:23,Block:24,INDENT:25,OUTDENT:26,Identifier:27,IDENTIFIER:28,AlphaNumeric:29,NUMBER:30,String:31,STRING:32,STRING_START:33,STRING_END:34,Regex:35,REGEX:36,REGEX_START:37,REGEX_END:38,Literal:39,JS:40,DEBUGGER:41,UNDEFINED:42,NULL:43,BOOL:44,Assignable:45,"=":46,AssignObj:47,ObjAssignable:48,":":49,ThisProperty:50,RETURN:51,HERECOMMENT:52,PARAM_START:53,ParamList:54,PARAM_END:55,FuncGlyph:56,"->":57,"=>":58,OptComma:59,",":60,Param:61,ParamVar:62,"...":63,Array:64,Object:65,Splat:66,SimpleAssignable:67,Accessor:68,Parenthetical:69,Range:70,This:71,".":72,"?.":73,"::":74,"?::":75,Index:76,INDEX_START:77,IndexValue:78,INDEX_END:79,INDEX_SOAK:80,Slice:81,"{":82,AssignList:83,"}":84,CLASS:85,EXTENDS:86,OptFuncExist:87,Arguments:88,SUPER:89,FUNC_EXIST:90,CALL_START:91,CALL_END:92,ArgList:93,THIS:94,"@":95,"[":96,"]":97,RangeDots:98,"..":99,Arg:100,SimpleArgs:101,TRY:102,Catch:103,FINALLY:104,CATCH:105,THROW:106,"(":107,")":108,WhileSource:109,WHILE:110,WHEN:111,UNTIL:112,Loop:113,LOOP:114,ForBody:115,FOR:116,BY:117,ForStart:118,ForSource:119,ForVariables:120,OWN:121,ForValue:122,FORIN:123,FOROF:124,SWITCH:125,Whens:126,ELSE:127,When:128,LEADING_WHEN:129,IfBlock:130,IF:131,POST_IF:132,UNARY:133,UNARY_MATH:134,"-":135,"+":136,YIELD:137,FROM:138,"--":139,"++":140,"?":141,MATH:142,"**":143,SHIFT:144,COMPARE:145,LOGIC:146,RELATION:147,COMPOUND_ASSIGN:148,$accept:0,$end:1},terminals_:{2:"error",6:"TERMINATOR",11:"STATEMENT",25:"INDENT",26:"OUTDENT",28:"IDENTIFIER",30:"NUMBER",32:"STRING",33:"STRING_START",34:"STRING_END",36:"REGEX",37:"REGEX_START",38:"REGEX_END",40:"JS",41:"DEBUGGER",42:"UNDEFINED",43:"NULL",44:"BOOL",46:"=",49:":",51:"RETURN",52:"HERECOMMENT",53:"PARAM_START",55:"PARAM_END",57:"->",58:"=>",60:",",63:"...",72:".",73:"?.",74:"::",75:"?::",77:"INDEX_START",79:"INDEX_END",80:"INDEX_SOAK",82:"{",84:"}",85:"CLASS",86:"EXTENDS",89:"SUPER",90:"FUNC_EXIST",91:"CALL_START",92:"CALL_END",94:"THIS",95:"@",96:"[",97:"]",99:"..",102:"TRY",104:"FINALLY",105:"CATCH",106:"THROW",107:"(",108:")",110:"WHILE",111:"WHEN",112:"UNTIL",114:"LOOP",116:"FOR",117:"BY",121:"OWN",123:"FORIN",124:"FOROF",125:"SWITCH",127:"ELSE",129:"LEADING_WHEN",131:"IF",132:"POST_IF",133:"UNARY",134:"UNARY_MATH",135:"-",136:"+",137:"YIELD",138:"FROM",139:"--",140:"++",141:"?",142:"MATH",143:"**",144:"SHIFT",145:"COMPARE",146:"LOGIC",147:"RELATION",148:"COMPOUND_ASSIGN"},productions_:[0,[3,0],[3,1],[4,1],[4,3],[4,2],[5,1],[5,1],[8,1],[8,1],[8,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[7,1],[24,2],[24,3],[27,1],[29,1],[29,1],[31,1],[31,3],[35,1],[35,3],[39,1],[39,1],[39,1],[39,1],[39,1],[39,1],[39,1],[16,3],[16,4],[16,5],[47,1],[47,3],[47,5],[47,1],[48,1],[48,1],[48,1],[9,2],[9,1],[10,1],[14,5],[14,2],[56,1],[56,1],[59,0],[59,1],[54,0],[54,1],[54,3],[54,4],[54,6],[61,1],[61,2],[61,3],[61,1],[62,1],[62,1],[62,1],[62,1],[66,2],[67,1],[67,2],[67,2],[67,1],[45,1],[45,1],[45,1],[12,1],[12,1],[12,1],[12,1],[12,1],[68,2],[68,2],[68,2],[68,2],[68,1],[68,1],[76,3],[76,2],[78,1],[78,1],[65,4],[83,0],[83,1],[83,3],[83,4],[83,6],[22,1],[22,2],[22,3],[22,4],[22,2],[22,3],[22,4],[22,5],[13,3],[13,3],[13,1],[13,2],[87,0],[87,1],[88,2],[88,4],[71,1],[71,1],[50,2],[64,2],[64,4],[98,1],[98,1],[70,5],[81,3],[81,2],[81,2],[81,1],[93,1],[93,3],[93,4],[93,4],[93,6],[100,1],[100,1],[100,1],[101,1],[101,3],[18,2],[18,3],[18,4],[18,5],[103,3],[103,3],[103,2],[23,2],[69,3],[69,5],[109,2],[109,4],[109,2],[109,4],[19,2],[19,2],[19,2],[19,1],[113,2],[113,2],[20,2],[20,2],[20,2],[115,2],[115,4],[115,2],[118,2],[118,3],[122,1],[122,1],[122,1],[122,1],[120,1],[120,3],[119,2],[119,2],[119,4],[119,4],[119,4],[119,6],[119,6],[21,5],[21,7],[21,4],[21,6],[126,1],[126,2],[128,3],[128,4],[130,3],[130,5],[17,1],[17,3],[17,3],[17,3],[15,2],[15,2],[15,2],[15,2],[15,2],[15,2],[15,3],[15,2],[15,2],[15,2],[15,2],[15,2],[15,3],[15,3],[15,3],[15,3],[15,3],[15,3],[15,3],[15,3],[15,3],[15,5],[15,4],[15,3]],performAction:function(e,t,n,i,r,s,o){var a=s.length-1;
+switch(r){case 1:return this.$=i.addLocationDataFn(o[a],o[a])(new i.Block);case 2:return this.$=s[a];case 3:this.$=i.addLocationDataFn(o[a],o[a])(i.Block.wrap([s[a]]));break;case 4:this.$=i.addLocationDataFn(o[a-2],o[a])(s[a-2].push(s[a]));break;case 5:this.$=s[a-1];break;case 6:case 7:case 8:case 9:case 11:case 12:case 13:case 14:case 15:case 16:case 17:case 18:case 19:case 20:case 21:case 22:case 27:case 32:case 34:case 45:case 46:case 47:case 48:case 56:case 57:case 67:case 68:case 69:case 70:case 75:case 76:case 79:case 83:case 89:case 133:case 134:case 136:case 166:case 167:case 183:case 189:this.$=s[a];break;case 10:case 25:case 26:case 28:case 30:case 33:case 35:this.$=i.addLocationDataFn(o[a],o[a])(new i.Literal(s[a]));break;case 23:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Block);break;case 24:case 31:case 90:this.$=i.addLocationDataFn(o[a-2],o[a])(s[a-1]);break;case 29:case 146:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Parens(s[a-1]));break;case 36:this.$=i.addLocationDataFn(o[a],o[a])(new i.Undefined);break;case 37:this.$=i.addLocationDataFn(o[a],o[a])(new i.Null);break;case 38:this.$=i.addLocationDataFn(o[a],o[a])(new i.Bool(s[a]));break;case 39:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Assign(s[a-2],s[a]));break;case 40:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Assign(s[a-3],s[a]));break;case 41:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Assign(s[a-4],s[a-1]));break;case 42:case 72:case 77:case 78:case 80:case 81:case 82:case 168:case 169:this.$=i.addLocationDataFn(o[a],o[a])(new i.Value(s[a]));break;case 43:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Assign(i.addLocationDataFn(o[a-2])(new i.Value(s[a-2])),s[a],"object"));break;case 44:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Assign(i.addLocationDataFn(o[a-4])(new i.Value(s[a-4])),s[a-1],"object"));break;case 49:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Return(s[a]));break;case 50:this.$=i.addLocationDataFn(o[a],o[a])(new i.Return);break;case 51:this.$=i.addLocationDataFn(o[a],o[a])(new i.Comment(s[a]));break;case 52:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Code(s[a-3],s[a],s[a-1]));break;case 53:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Code([],s[a],s[a-1]));break;case 54:this.$=i.addLocationDataFn(o[a],o[a])("func");break;case 55:this.$=i.addLocationDataFn(o[a],o[a])("boundfunc");break;case 58:case 95:this.$=i.addLocationDataFn(o[a],o[a])([]);break;case 59:case 96:case 128:case 170:this.$=i.addLocationDataFn(o[a],o[a])([s[a]]);break;case 60:case 97:case 129:this.$=i.addLocationDataFn(o[a-2],o[a])(s[a-2].concat(s[a]));break;case 61:case 98:case 130:this.$=i.addLocationDataFn(o[a-3],o[a])(s[a-3].concat(s[a]));break;case 62:case 99:case 132:this.$=i.addLocationDataFn(o[a-5],o[a])(s[a-5].concat(s[a-2]));break;case 63:this.$=i.addLocationDataFn(o[a],o[a])(new i.Param(s[a]));break;case 64:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Param(s[a-1],null,!0));break;case 65:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Param(s[a-2],s[a]));break;case 66:case 135:this.$=i.addLocationDataFn(o[a],o[a])(new i.Expansion);break;case 71:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Splat(s[a-1]));break;case 73:this.$=i.addLocationDataFn(o[a-1],o[a])(s[a-1].add(s[a]));break;case 74:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Value(s[a-1],[].concat(s[a])));break;case 84:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Access(s[a]));break;case 85:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Access(s[a],"soak"));break;case 86:this.$=i.addLocationDataFn(o[a-1],o[a])([i.addLocationDataFn(o[a-1])(new i.Access(new i.Literal("prototype"))),i.addLocationDataFn(o[a])(new i.Access(s[a]))]);break;case 87:this.$=i.addLocationDataFn(o[a-1],o[a])([i.addLocationDataFn(o[a-1])(new i.Access(new i.Literal("prototype"),"soak")),i.addLocationDataFn(o[a])(new i.Access(s[a]))]);break;case 88:this.$=i.addLocationDataFn(o[a],o[a])(new i.Access(new i.Literal("prototype")));break;case 91:this.$=i.addLocationDataFn(o[a-1],o[a])(i.extend(s[a],{soak:!0}));break;case 92:this.$=i.addLocationDataFn(o[a],o[a])(new i.Index(s[a]));break;case 93:this.$=i.addLocationDataFn(o[a],o[a])(new i.Slice(s[a]));break;case 94:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Obj(s[a-2],s[a-3].generated));break;case 100:this.$=i.addLocationDataFn(o[a],o[a])(new i.Class);break;case 101:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Class(null,null,s[a]));break;case 102:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Class(null,s[a]));break;case 103:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Class(null,s[a-1],s[a]));break;case 104:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Class(s[a]));break;case 105:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Class(s[a-1],null,s[a]));break;case 106:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Class(s[a-2],s[a]));break;case 107:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Class(s[a-3],s[a-1],s[a]));break;case 108:case 109:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Call(s[a-2],s[a],s[a-1]));break;case 110:this.$=i.addLocationDataFn(o[a],o[a])(new i.Call("super",[new i.Splat(new i.Literal("arguments"))]));break;case 111:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Call("super",s[a]));break;case 112:this.$=i.addLocationDataFn(o[a],o[a])(!1);break;case 113:this.$=i.addLocationDataFn(o[a],o[a])(!0);break;case 114:this.$=i.addLocationDataFn(o[a-1],o[a])([]);break;case 115:case 131:this.$=i.addLocationDataFn(o[a-3],o[a])(s[a-2]);break;case 116:case 117:this.$=i.addLocationDataFn(o[a],o[a])(new i.Value(new i.Literal("this")));break;case 118:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Value(i.addLocationDataFn(o[a-1])(new i.Literal("this")),[i.addLocationDataFn(o[a])(new i.Access(s[a]))],"this"));break;case 119:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Arr([]));break;case 120:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Arr(s[a-2]));break;case 121:this.$=i.addLocationDataFn(o[a],o[a])("inclusive");break;case 122:this.$=i.addLocationDataFn(o[a],o[a])("exclusive");break;case 123:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Range(s[a-3],s[a-1],s[a-2]));break;case 124:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Range(s[a-2],s[a],s[a-1]));break;case 125:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Range(s[a-1],null,s[a]));break;case 126:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Range(null,s[a],s[a-1]));break;case 127:this.$=i.addLocationDataFn(o[a],o[a])(new i.Range(null,null,s[a]));break;case 137:this.$=i.addLocationDataFn(o[a-2],o[a])([].concat(s[a-2],s[a]));break;case 138:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Try(s[a]));break;case 139:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Try(s[a-1],s[a][0],s[a][1]));break;case 140:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Try(s[a-2],null,null,s[a]));break;case 141:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Try(s[a-3],s[a-2][0],s[a-2][1],s[a]));break;case 142:this.$=i.addLocationDataFn(o[a-2],o[a])([s[a-1],s[a]]);break;case 143:this.$=i.addLocationDataFn(o[a-2],o[a])([i.addLocationDataFn(o[a-1])(new i.Value(s[a-1])),s[a]]);break;case 144:this.$=i.addLocationDataFn(o[a-1],o[a])([null,s[a]]);break;case 145:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Throw(s[a]));break;case 147:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Parens(s[a-2]));break;case 148:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.While(s[a]));break;case 149:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.While(s[a-2],{guard:s[a]}));break;case 150:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.While(s[a],{invert:!0}));break;case 151:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.While(s[a-2],{invert:!0,guard:s[a]}));break;case 152:this.$=i.addLocationDataFn(o[a-1],o[a])(s[a-1].addBody(s[a]));break;case 153:case 154:this.$=i.addLocationDataFn(o[a-1],o[a])(s[a].addBody(i.addLocationDataFn(o[a-1])(i.Block.wrap([s[a-1]]))));break;case 155:this.$=i.addLocationDataFn(o[a],o[a])(s[a]);break;case 156:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.While(i.addLocationDataFn(o[a-1])(new i.Literal("true"))).addBody(s[a]));break;case 157:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.While(i.addLocationDataFn(o[a-1])(new i.Literal("true"))).addBody(i.addLocationDataFn(o[a])(i.Block.wrap([s[a]]))));break;case 158:case 159:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.For(s[a-1],s[a]));break;case 160:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.For(s[a],s[a-1]));break;case 161:this.$=i.addLocationDataFn(o[a-1],o[a])({source:i.addLocationDataFn(o[a])(new i.Value(s[a]))});break;case 162:this.$=i.addLocationDataFn(o[a-3],o[a])({source:i.addLocationDataFn(o[a-2])(new i.Value(s[a-2])),step:s[a]});break;case 163:this.$=i.addLocationDataFn(o[a-1],o[a])(function(){return s[a].own=s[a-1].own,s[a].name=s[a-1][0],s[a].index=s[a-1][1],s[a]}());break;case 164:this.$=i.addLocationDataFn(o[a-1],o[a])(s[a]);break;case 165:this.$=i.addLocationDataFn(o[a-2],o[a])(function(){return s[a].own=!0,s[a]}());break;case 171:this.$=i.addLocationDataFn(o[a-2],o[a])([s[a-2],s[a]]);break;case 172:this.$=i.addLocationDataFn(o[a-1],o[a])({source:s[a]});break;case 173:this.$=i.addLocationDataFn(o[a-1],o[a])({source:s[a],object:!0});break;case 174:this.$=i.addLocationDataFn(o[a-3],o[a])({source:s[a-2],guard:s[a]});break;case 175:this.$=i.addLocationDataFn(o[a-3],o[a])({source:s[a-2],guard:s[a],object:!0});break;case 176:this.$=i.addLocationDataFn(o[a-3],o[a])({source:s[a-2],step:s[a]});break;case 177:this.$=i.addLocationDataFn(o[a-5],o[a])({source:s[a-4],guard:s[a-2],step:s[a]});break;case 178:this.$=i.addLocationDataFn(o[a-5],o[a])({source:s[a-4],step:s[a-2],guard:s[a]});break;case 179:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Switch(s[a-3],s[a-1]));break;case 180:this.$=i.addLocationDataFn(o[a-6],o[a])(new i.Switch(s[a-5],s[a-3],s[a-1]));break;case 181:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Switch(null,s[a-1]));break;case 182:this.$=i.addLocationDataFn(o[a-5],o[a])(new i.Switch(null,s[a-3],s[a-1]));break;case 184:this.$=i.addLocationDataFn(o[a-1],o[a])(s[a-1].concat(s[a]));break;case 185:this.$=i.addLocationDataFn(o[a-2],o[a])([[s[a-1],s[a]]]);break;case 186:this.$=i.addLocationDataFn(o[a-3],o[a])([[s[a-2],s[a-1]]]);break;case 187:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.If(s[a-1],s[a],{type:s[a-2]}));break;case 188:this.$=i.addLocationDataFn(o[a-4],o[a])(s[a-4].addElse(i.addLocationDataFn(o[a-2],o[a])(new i.If(s[a-1],s[a],{type:s[a-2]}))));break;case 190:this.$=i.addLocationDataFn(o[a-2],o[a])(s[a-2].addElse(s[a]));break;case 191:case 192:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.If(s[a],i.addLocationDataFn(o[a-2])(i.Block.wrap([s[a-2]])),{type:s[a-1],statement:!0}));break;case 193:case 194:case 197:case 198:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op(s[a-1],s[a]));break;case 195:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op("-",s[a]));break;case 196:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op("+",s[a]));break;case 199:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Op(s[a-2].concat(s[a-1]),s[a]));break;case 200:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op("--",s[a]));break;case 201:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op("++",s[a]));break;case 202:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op("--",s[a-1],null,!0));break;case 203:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Op("++",s[a-1],null,!0));break;case 204:this.$=i.addLocationDataFn(o[a-1],o[a])(new i.Existence(s[a-1]));break;case 205:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Op("+",s[a-2],s[a]));break;case 206:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Op("-",s[a-2],s[a]));break;case 207:case 208:case 209:case 210:case 211:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Op(s[a-1],s[a-2],s[a]));break;case 212:this.$=i.addLocationDataFn(o[a-2],o[a])(function(){return"!"===s[a-1].charAt(0)?new i.Op(s[a-1].slice(1),s[a-2],s[a]).invert():new i.Op(s[a-1],s[a-2],s[a])}());break;case 213:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Assign(s[a-2],s[a],s[a-1]));break;case 214:this.$=i.addLocationDataFn(o[a-4],o[a])(new i.Assign(s[a-4],s[a-1],s[a-3]));break;case 215:this.$=i.addLocationDataFn(o[a-3],o[a])(new i.Assign(s[a-3],s[a],s[a-2]));break;case 216:this.$=i.addLocationDataFn(o[a-2],o[a])(new i.Extends(s[a-2],s[a]))}},table:[{1:[2,1],3:1,4:2,5:3,7:4,8:5,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{1:[3]},{1:[2,2],6:P},t(U,[2,3]),t(U,[2,6],{118:69,109:89,115:90,110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(U,[2,7],{118:69,109:92,115:93,110:x,112:S,116:R,132:Z}),t(et,[2,11],{87:94,68:95,76:101,72:tt,73:nt,74:it,75:rt,77:st,80:ot,90:at,91:ct}),t(et,[2,12],{76:101,87:104,68:105,72:tt,73:nt,74:it,75:rt,77:st,80:ot,90:at,91:ct}),t(et,[2,13]),t(et,[2,14]),t(et,[2,15]),t(et,[2,16]),t(et,[2,17]),t(et,[2,18]),t(et,[2,19]),t(et,[2,20]),t(et,[2,21]),t(et,[2,22]),t(et,[2,8]),t(et,[2,9]),t(et,[2,10]),t(ht,lt,{46:[1,106]}),t(ht,[2,80]),t(ht,[2,81]),t(ht,[2,82]),t(ht,[2,83]),t([1,6,25,26,34,38,55,60,63,72,73,74,75,77,79,80,84,90,92,97,99,108,110,111,112,116,117,132,135,136,141,142,143,144,145,146,147],[2,110],{88:107,91:ut}),t([6,25,55,60],pt,{54:109,61:110,62:111,27:113,50:114,64:115,65:116,28:i,63:dt,82:b,95:ft,96:mt}),{24:119,25:gt},{7:121,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:123,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:124,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:125,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:127,8:126,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,138:[1,128],139:B,140:V},{12:130,13:131,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:132,50:63,64:47,65:48,67:129,69:23,70:24,71:25,82:b,89:w,94:T,95:C,96:E,107:L},{12:130,13:131,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:132,50:63,64:47,65:48,67:133,69:23,70:24,71:25,82:b,89:w,94:T,95:C,96:E,107:L},t(vt,yt,{86:[1,137],139:[1,134],140:[1,135],148:[1,136]}),t(et,[2,189],{127:[1,138]}),{24:139,25:gt},{24:140,25:gt},t(et,[2,155]),{24:141,25:gt},{7:142,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:[1,143],27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(bt,[2,100],{39:22,69:23,70:24,71:25,64:47,65:48,29:49,35:51,27:62,50:63,31:72,12:130,13:131,45:132,24:144,67:146,25:gt,28:i,30:r,32:s,33:o,36:a,37:c,40:h,41:l,42:u,43:p,44:d,82:b,86:[1,145],89:w,94:T,95:C,96:E,107:L}),{7:147,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,141,142,143,144,145,146,147],[2,50],{12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,9:18,10:19,45:21,39:22,69:23,70:24,71:25,56:28,67:36,130:37,109:39,113:40,115:41,64:47,65:48,29:49,35:51,27:62,50:63,118:69,31:72,8:122,7:148,11:n,28:i,30:r,32:s,33:o,36:a,37:c,40:h,41:l,42:u,43:p,44:d,51:f,52:m,53:g,57:v,58:y,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,114:D,125:A,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V}),t(et,[2,51]),t(vt,[2,77]),t(vt,[2,78]),t(ht,[2,32]),t(ht,[2,33]),t(ht,[2,34]),t(ht,[2,35]),t(ht,[2,36]),t(ht,[2,37]),t(ht,[2,38]),{4:149,5:3,7:4,8:5,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:[1,150],27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:151,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:kt,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:wt,64:47,65:48,66:156,67:36,69:23,70:24,71:25,82:b,85:k,89:w,93:153,94:T,95:C,96:E,97:Tt,100:154,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(ht,[2,116]),t(ht,[2,117],{27:158,28:i}),{25:[2,54]},{25:[2,55]},t(Ct,[2,72]),t(Ct,[2,75]),{7:159,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:160,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:161,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:163,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,24:162,25:gt,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{27:168,28:i,50:169,64:170,65:171,70:164,82:b,95:ft,96:E,120:165,121:[1,166],122:167},{119:172,123:[1,173],124:[1,174]},t([6,25,60,84],Et,{31:72,83:175,47:176,48:177,10:178,27:179,29:180,50:181,28:i,30:r,32:s,33:o,52:m,95:ft}),t(Ft,[2,26]),t(Ft,[2,27]),t(ht,[2,30]),{12:130,13:182,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:132,50:63,64:47,65:48,67:183,69:23,70:24,71:25,82:b,89:w,94:T,95:C,96:E,107:L},t(Nt,[2,25]),t(Ft,[2,28]),{4:184,5:3,7:4,8:5,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(U,[2,5],{7:4,8:5,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,9:18,10:19,45:21,39:22,69:23,70:24,71:25,56:28,67:36,130:37,109:39,113:40,115:41,64:47,65:48,29:49,35:51,27:62,50:63,118:69,31:72,5:185,11:n,28:i,30:r,32:s,33:o,36:a,37:c,40:h,41:l,42:u,43:p,44:d,51:f,52:m,53:g,57:v,58:y,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,110:x,112:S,114:D,116:R,125:A,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V}),t(et,[2,204]),{7:186,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:187,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:188,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:189,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:190,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:191,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:192,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:193,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:194,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(et,[2,154]),t(et,[2,159]),{7:195,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(et,[2,153]),t(et,[2,158]),{88:196,91:ut},t(Ct,[2,73]),{91:[2,113]},{27:197,28:i},{27:198,28:i},t(Ct,[2,88],{27:199,28:i}),{27:200,28:i},t(Ct,[2,89]),{7:202,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:Lt,64:47,65:48,67:36,69:23,70:24,71:25,78:201,81:203,82:b,85:k,89:w,94:T,95:C,96:E,98:204,99:xt,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{76:207,77:st,80:ot},{88:208,91:ut},t(Ct,[2,74]),{6:[1,210],7:209,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:[1,211],27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(St,[2,111]),{7:214,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:kt,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:wt,64:47,65:48,66:156,67:36,69:23,70:24,71:25,82:b,85:k,89:w,92:[1,212],93:213,94:T,95:C,96:E,100:154,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t([6,25],Dt,{59:217,55:[1,215],60:Rt}),t(At,[2,59]),t(At,[2,63],{46:[1,219],63:[1,218]}),t(At,[2,66]),t(It,[2,67]),t(It,[2,68]),t(It,[2,69]),t(It,[2,70]),{27:158,28:i},{7:214,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:kt,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:wt,64:47,65:48,66:156,67:36,69:23,70:24,71:25,82:b,85:k,89:w,93:153,94:T,95:C,96:E,97:Tt,100:154,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(et,[2,53]),{4:221,5:3,7:4,8:5,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,26:[1,220],27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,135,136,142,143,144,145,146,147],[2,193],{118:69,109:89,115:90,141:X}),{109:92,110:x,112:S,115:93,116:R,118:69,132:Z},t(_t,[2,194],{118:69,109:89,115:90,141:X,143:Y}),t(_t,[2,195],{118:69,109:89,115:90,141:X,143:Y}),t(_t,[2,196],{118:69,109:89,115:90,141:X,143:Y}),t(et,[2,197],{118:69,109:92,115:93}),t(Ot,[2,198],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{7:222,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(et,[2,200],{72:yt,73:yt,74:yt,75:yt,77:yt,80:yt,90:yt,91:yt}),{68:95,72:tt,73:nt,74:it,75:rt,76:101,77:st,80:ot,87:94,90:at,91:ct},{68:105,72:tt,73:nt,74:it,75:rt,76:101,77:st,80:ot,87:104,90:at,91:ct},t($t,lt),t(et,[2,201],{72:yt,73:yt,74:yt,75:yt,77:yt,80:yt,90:yt,91:yt}),t(et,[2,202]),t(et,[2,203]),{6:[1,225],7:223,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:[1,224],27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:226,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{24:227,25:gt,131:[1,228]},t(et,[2,138],{103:229,104:[1,230],105:[1,231]}),t(et,[2,152]),t(et,[2,160]),{25:[1,232],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},{126:233,128:234,129:jt},t(et,[2,101]),{7:236,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(bt,[2,104],{24:237,25:gt,72:yt,73:yt,74:yt,75:yt,77:yt,80:yt,90:yt,91:yt,86:[1,238]}),t(Ot,[2,145],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Ot,[2,49],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{6:P,108:[1,239]},{4:240,5:3,7:4,8:5,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t([6,25,60,97],Mt,{118:69,109:89,115:90,98:241,63:[1,242],99:xt,110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Bt,[2,119]),t([6,25,97],Dt,{59:243,60:Vt}),t(Pt,[2,128]),{7:214,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:kt,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:wt,64:47,65:48,66:156,67:36,69:23,70:24,71:25,82:b,85:k,89:w,93:245,94:T,95:C,96:E,100:154,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(Pt,[2,134]),t(Pt,[2,135]),t(Nt,[2,118]),{24:246,25:gt,109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},t(Ut,[2,148],{118:69,109:89,115:90,110:x,111:[1,247],112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Ut,[2,150],{118:69,109:89,115:90,110:x,111:[1,248],112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(et,[2,156]),t(Gt,[2,157],{118:69,109:89,115:90,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,132,135,136,141,142,143,144,145,146,147],[2,161],{117:[1,249]}),t(Ht,[2,164]),{27:168,28:i,50:169,64:170,65:171,82:b,95:ft,96:mt,120:250,122:167},t(Ht,[2,170],{60:[1,251]}),t(qt,[2,166]),t(qt,[2,167]),t(qt,[2,168]),t(qt,[2,169]),t(et,[2,163]),{7:252,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:253,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t([6,25,84],Dt,{59:254,60:Xt}),t(Wt,[2,96]),t(Wt,[2,42],{49:[1,256]}),t(Wt,[2,45]),t(Yt,[2,46]),t(Yt,[2,47]),t(Yt,[2,48]),{38:[1,257],68:105,72:tt,73:nt,74:it,75:rt,76:101,77:st,80:ot,87:104,90:at,91:ct},t($t,yt),{6:P,34:[1,258]},t(U,[2,4]),t(Kt,[2,205],{118:69,109:89,115:90,141:X,142:W,143:Y}),t(Kt,[2,206],{118:69,109:89,115:90,141:X,142:W,143:Y}),t(_t,[2,207],{118:69,109:89,115:90,141:X,143:Y}),t(_t,[2,208],{118:69,109:89,115:90,141:X,143:Y}),t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,144,145,146,147],[2,209],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y}),t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,145,146],[2,210],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,147:Q}),t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,146],[2,211],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,147:Q}),t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,117,132,145,146,147],[2,212],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K}),t(Gt,[2,192],{118:69,109:89,115:90,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Gt,[2,191],{118:69,109:89,115:90,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(St,[2,108]),t(Ct,[2,84]),t(Ct,[2,85]),t(Ct,[2,86]),t(Ct,[2,87]),{79:[1,259]},{63:Lt,79:[2,92],98:260,99:xt,109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},{79:[2,93]},{7:261,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,79:[2,127],82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(zt,[2,121]),t(zt,Jt),t(Ct,[2,91]),t(St,[2,109]),t(Ot,[2,39],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{7:262,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:263,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(St,[2,114]),t([6,25,92],Dt,{59:264,60:Vt}),t(Pt,Mt,{118:69,109:89,115:90,63:[1,265],110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{56:266,57:v,58:y},t(Qt,Zt,{62:111,27:113,50:114,64:115,65:116,61:267,28:i,63:dt,82:b,95:ft,96:mt}),{6:en,25:tn},t(At,[2,64]),{7:270,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(nn,[2,23]),{6:P,26:[1,271]},t(Ot,[2,199],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Ot,[2,213],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{7:272,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:273,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(Ot,[2,216],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(et,[2,190]),{7:274,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(et,[2,139],{104:[1,275]}),{24:276,25:gt},{24:279,25:gt,27:277,28:i,65:278,82:b},{126:280,128:234,129:jt},{26:[1,281],127:[1,282],128:283,129:jt},t(rn,[2,183]),{7:285,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,101:284,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(sn,[2,102],{118:69,109:89,115:90,24:286,25:gt,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(et,[2,105]),{7:287,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(ht,[2,146]),{6:P,26:[1,288]},{7:289,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t([11,28,30,32,33,36,37,40,41,42,43,44,51,52,53,57,58,82,85,89,94,95,96,102,106,107,110,112,114,116,125,131,133,134,135,136,137,139,140],Jt,{6:on,25:on,60:on,97:on}),{6:an,25:cn,97:[1,290]},t([6,25,26,92,97],Zt,{12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,9:18,10:19,45:21,39:22,69:23,70:24,71:25,56:28,67:36,130:37,109:39,113:40,115:41,64:47,65:48,29:49,35:51,27:62,50:63,118:69,31:72,8:122,66:156,7:214,100:293,11:n,28:i,30:r,32:s,33:o,36:a,37:c,40:h,41:l,42:u,43:p,44:d,51:f,52:m,53:g,57:v,58:y,63:wt,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,110:x,112:S,114:D,116:R,125:A,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V}),t(Qt,Dt,{59:294,60:Vt}),t(hn,[2,187]),{7:295,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:296,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:297,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(Ht,[2,165]),{27:168,28:i,50:169,64:170,65:171,82:b,95:ft,96:mt,122:298},t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,112,116,132],[2,172],{118:69,109:89,115:90,111:[1,299],117:[1,300],135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(ln,[2,173],{118:69,109:89,115:90,111:[1,301],135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{6:un,25:pn,84:[1,302]},t([6,25,26,84],Zt,{31:72,48:177,10:178,27:179,29:180,50:181,47:305,28:i,30:r,32:s,33:o,52:m,95:ft}),{7:306,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:[1,307],27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(ht,[2,31]),t(Ft,[2,29]),t(Ct,[2,90]),{7:308,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,79:[2,125],82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{79:[2,126],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},t(Ot,[2,40],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{26:[1,309],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},{6:an,25:cn,92:[1,310]},t(Pt,on),{24:311,25:gt},t(At,[2,60]),{27:113,28:i,50:114,61:312,62:111,63:dt,64:115,65:116,82:b,95:ft,96:mt},t(dn,pt,{61:110,62:111,27:113,50:114,64:115,65:116,54:313,28:i,63:dt,82:b,95:ft,96:mt}),t(At,[2,65],{118:69,109:89,115:90,110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(nn,[2,24]),{26:[1,314],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},t(Ot,[2,215],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{24:315,25:gt,109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},{24:316,25:gt},t(et,[2,140]),{24:317,25:gt},{24:318,25:gt},t(fn,[2,144]),{26:[1,319],127:[1,320],128:283,129:jt},t(et,[2,181]),{24:321,25:gt},t(rn,[2,184]),{24:322,25:gt,60:[1,323]},t(mn,[2,136],{118:69,109:89,115:90,110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(et,[2,103]),t(sn,[2,106],{118:69,109:89,115:90,24:324,25:gt,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{108:[1,325]},{97:[1,326],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},t(Bt,[2,120]),{7:214,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:wt,64:47,65:48,66:156,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,100:327,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:214,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,25:kt,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,63:wt,64:47,65:48,66:156,67:36,69:23,70:24,71:25,82:b,85:k,89:w,93:328,94:T,95:C,96:E,100:154,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(Pt,[2,129]),{6:an,25:cn,26:[1,329]},t(Gt,[2,149],{118:69,109:89,115:90,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Gt,[2,151],{118:69,109:89,115:90,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Gt,[2,162],{118:69,109:89,115:90,110:x,112:S,116:R,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Ht,[2,171]),{7:330,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:331,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:332,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(Bt,[2,94]),{10:178,27:179,28:i,29:180,30:r,31:72,32:s,33:o,47:333,48:177,50:181,52:m,95:ft},t(dn,Et,{31:72,47:176,48:177,10:178,27:179,29:180,50:181,83:334,28:i,30:r,32:s,33:o,52:m,95:ft}),t(Wt,[2,97]),t(Wt,[2,43],{118:69,109:89,115:90,110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{7:335,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{79:[2,124],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},t(et,[2,41]),t(St,[2,115]),t(et,[2,52]),t(At,[2,61]),t(Qt,Dt,{59:336,60:Rt}),t(et,[2,214]),t(hn,[2,188]),t(et,[2,141]),t(fn,[2,142]),t(fn,[2,143]),t(et,[2,179]),{24:337,25:gt},{26:[1,338]},t(rn,[2,185],{6:[1,339]}),{7:340,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},t(et,[2,107]),t(ht,[2,147]),t(ht,[2,123]),t(Pt,[2,130]),t(Qt,Dt,{59:341,60:Vt}),t(Pt,[2,131]),t([1,6,25,26,34,55,60,63,79,84,92,97,99,108,110,111,112,116,132],[2,174],{118:69,109:89,115:90,117:[1,342],135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(ln,[2,176],{118:69,109:89,115:90,111:[1,343],135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Ot,[2,175],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Wt,[2,98]),t(Qt,Dt,{59:344,60:Xt}),{26:[1,345],109:89,110:x,112:S,115:90,116:R,118:69,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q},{6:en,25:tn,26:[1,346]},{26:[1,347]},t(et,[2,182]),t(rn,[2,186]),t(mn,[2,137],{118:69,109:89,115:90,110:x,112:S,116:R,132:G,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),{6:an,25:cn,26:[1,348]},{7:349,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{7:350,8:122,9:18,10:19,11:n,12:6,13:7,14:8,15:9,16:10,17:11,18:12,19:13,20:14,21:15,22:16,23:17,27:62,28:i,29:49,30:r,31:72,32:s,33:o,35:51,36:a,37:c,39:22,40:h,41:l,42:u,43:p,44:d,45:21,50:63,51:f,52:m,53:g,56:28,57:v,58:y,64:47,65:48,67:36,69:23,70:24,71:25,82:b,85:k,89:w,94:T,95:C,96:E,102:F,106:N,107:L,109:39,110:x,112:S,113:40,114:D,115:41,116:R,118:69,125:A,130:37,131:I,133:_,134:O,135:$,136:j,137:M,139:B,140:V},{6:un,25:pn,26:[1,351]},t(Wt,[2,44]),t(At,[2,62]),t(et,[2,180]),t(Pt,[2,132]),t(Ot,[2,177],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Ot,[2,178],{118:69,109:89,115:90,135:H,136:q,141:X,142:W,143:Y,144:K,145:z,146:J,147:Q}),t(Wt,[2,99])],defaultActions:{60:[2,54],61:[2,55],96:[2,113],203:[2,93]},parseError:function(e,t){if(!t.recoverable)throw Error(e);
+this.trace(e)},parse:function(e){function t(){var e;return e=f.lex()||p,"number"!=typeof e&&(e=n.symbols_[e]||e),e}var n=this,i=[0],r=[null],s=[],o=this.table,a="",c=0,h=0,l=0,u=2,p=1,d=s.slice.call(arguments,1),f=Object.create(this.lexer),m={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(m.yy[g]=this.yy[g]);f.setInput(e,m.yy),m.yy.lexer=f,m.yy.parser=this,f.yylloc===void 0&&(f.yylloc={});var v=f.yylloc;s.push(v);var y=f.options&&f.options.ranges;this.parseError="function"==typeof m.yy.parseError?m.yy.parseError:Object.getPrototypeOf(this).parseError;for(var b,k,w,T,C,E,F,N,L,x={};;){if(w=i[i.length-1],this.defaultActions[w]?T=this.defaultActions[w]:((null===b||b===void 0)&&(b=t()),T=o[w]&&o[w][b]),T===void 0||!T.length||!T[0]){var S="";L=[];for(E in o[w])this.terminals_[E]&&E>u&&L.push("'"+this.terminals_[E]+"'");S=f.showPosition?"Parse error on line "+(c+1)+":\n"+f.showPosition()+"\nExpecting "+L.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(c+1)+": Unexpected "+(b==p?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(S,{text:f.match,token:this.terminals_[b]||b,line:f.yylineno,loc:v,expected:L})}if(T[0]instanceof Array&&T.length>1)throw Error("Parse Error: multiple actions possible at state: "+w+", token: "+b);switch(T[0]){case 1:i.push(b),r.push(f.yytext),s.push(f.yylloc),i.push(T[1]),b=null,k?(b=k,k=null):(h=f.yyleng,a=f.yytext,c=f.yylineno,v=f.yylloc,l>0&&l--);break;case 2:if(F=this.productions_[T[1]][1],x.$=r[r.length-F],x._$={first_line:s[s.length-(F||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(F||1)].first_column,last_column:s[s.length-1].last_column},y&&(x._$.range=[s[s.length-(F||1)].range[0],s[s.length-1].range[1]]),C=this.performAction.apply(x,[a,h,c,m.yy,T[1],r,s].concat(d)),C!==void 0)return C;F&&(i=i.slice(0,2*-1*F),r=r.slice(0,-1*F),s=s.slice(0,-1*F)),i.push(this.productions_[T[1]][0]),r.push(x.$),s.push(x._$),N=o[i[i.length-2]][i[i.length-1]],i.push(N);break;case 3:return!0}}return!0}};return e.prototype=gn,gn.Parser=e,new e}();return _dereq_!==void 0&&e!==void 0&&(e.parser=n,e.Parser=n.Parser,e.parse=function(){return n.parse.apply(n,arguments)},e.main=function(t){t[1]||(console.log("Usage: "+t[0]+" FILE"),process.exit(1));var n=_dereq_("fs").readFileSync(_dereq_("path").normalize(t[1]),"utf8");return e.parser.parse(n)},t!==void 0&&_dereq_.main===t&&e.main(process.argv.slice(1))),t.exports}(),_dereq_["./scope"]=function(){var e={},t={exports:e};return function(){var t,n=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(t in this&&this[t]===e)return t;return-1};e.Scope=t=function(){function e(e,t,n,i){var r,s;this.parent=e,this.expressions=t,this.method=n,this.referencedVars=i,this.variables=[{name:"arguments",type:"arguments"}],this.positions={},this.parent||(this.utilities={}),this.root=null!=(r=null!=(s=this.parent)?s.root:void 0)?r:this}return e.prototype.add=function(e,t,n){return this.shared&&!n?this.parent.add(e,t,n):Object.prototype.hasOwnProperty.call(this.positions,e)?this.variables[this.positions[e]].type=t:this.positions[e]=this.variables.push({name:e,type:t})-1},e.prototype.namedMethod=function(){var e;return(null!=(e=this.method)?e.name:void 0)||!this.parent?this.method:this.parent.namedMethod()},e.prototype.find=function(e){return this.check(e)?!0:(this.add(e,"var"),!1)},e.prototype.parameter=function(e){return this.shared&&this.parent.check(e,!0)?void 0:this.add(e,"param")},e.prototype.check=function(e){var t;return!!(this.type(e)||(null!=(t=this.parent)?t.check(e):void 0))},e.prototype.temporary=function(e,t,n){return null==n&&(n=!1),n?(t+parseInt(e,36)).toString(36).replace(/\d/g,"a"):e+(t||"")},e.prototype.type=function(e){var t,n,i,r;for(i=this.variables,t=0,n=i.length;n>t;t++)if(r=i[t],r.name===e)return r.type;return null},e.prototype.freeVariable=function(e,t){var i,r,s;for(null==t&&(t={}),i=0;;){if(s=this.temporary(e,i,t.single),!(this.check(s)||n.call(this.root.referencedVars,s)>=0))break;i++}return(null!=(r=t.reserve)?r:!0)&&this.add(s,"var",!0),s},e.prototype.assign=function(e,t){return this.add(e,{value:t,assigned:!0},!0),this.hasAssignments=!0},e.prototype.hasDeclarations=function(){return!!this.declaredVariables().length},e.prototype.declaredVariables=function(){var e;return function(){var t,n,i,r;for(i=this.variables,r=[],t=0,n=i.length;n>t;t++)e=i[t],"var"===e.type&&r.push(e.name);return r}.call(this).sort()},e.prototype.assignedVariables=function(){var e,t,n,i,r;for(n=this.variables,i=[],e=0,t=n.length;t>e;e++)r=n[e],r.type.assigned&&i.push(r.name+" = "+r.type.value);return i},e}()}.call(this),t.exports}(),_dereq_["./nodes"]=function(){var e={},t={exports:e};return function(){var t,n,i,r,s,o,a,c,h,l,u,p,d,f,m,g,v,y,b,k,w,T,C,E,F,N,L,x,S,D,R,A,I,_,O,$,j,M,B,V,P,U,G,H,q,X,W,Y,K,z,J,Q,Z,et,tt,nt,it,rt,st,ot,at,ct,ht,lt,ut,pt,dt,ft,mt,gt,vt,yt,bt,kt=function(e,t){function n(){this.constructor=e}for(var i in t)wt.call(t,i)&&(e[i]=t[i]);return n.prototype=t.prototype,e.prototype=new n,e.__super__=t.prototype,e},wt={}.hasOwnProperty,Tt=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(t in this&&this[t]===e)return t;return-1},Ct=[].slice;Error.stackTraceLimit=1/0,P=_dereq_("./scope").Scope,dt=_dereq_("./lexer"),$=dt.RESERVED,V=dt.STRICT_PROSCRIBED,ft=_dereq_("./helpers"),et=ft.compact,rt=ft.flatten,it=ft.extend,lt=ft.merge,tt=ft.del,gt=ft.starts,nt=ft.ends,mt=ft.some,Z=ft.addLocationDataFn,ht=ft.locationDataToString,vt=ft.throwSyntaxError,e.extend=it,e.addLocationDataFn=Z,Q=function(){return!0},D=function(){return!1},X=function(){return this},S=function(){return this.negated=!this.negated,this},e.CodeFragment=h=function(){function e(e,t){var n;this.code=""+t,this.locationData=null!=e?e.locationData:void 0,this.type=(null!=e?null!=(n=e.constructor)?n.name:void 0:void 0)||"unknown"}return e.prototype.toString=function(){return""+this.code+(this.locationData?": "+ht(this.locationData):"")},e}(),st=function(e){var t;return function(){var n,i,r;for(r=[],n=0,i=e.length;i>n;n++)t=e[n],r.push(t.code);return r}().join("")},e.Base=r=function(){function e(){}return e.prototype.compile=function(e,t){return st(this.compileToFragments(e,t))},e.prototype.compileToFragments=function(e,t){var n;return e=it({},e),t&&(e.level=t),n=this.unfoldSoak(e)||this,n.tab=e.indent,e.level!==L&&n.isStatement(e)?n.compileClosure(e):n.compileNode(e)},e.prototype.compileClosure=function(e){var n,i,r,a,h,l,u;return(a=this.jumps())&&a.error("cannot use a pure statement in an expression"),e.sharedScope=!0,r=new c([],s.wrap([this])),n=[],((i=this.contains(at))||this.contains(ct))&&(n=[new x("this")],i?(h="apply",n.push(new x("arguments"))):h="call",r=new z(r,[new t(new x(h))])),l=new o(r,n).compileNode(e),(r.isGenerator||(null!=(u=r.base)?u.isGenerator:void 0))&&(l.unshift(this.makeCode("(yield* ")),l.push(this.makeCode(")"))),l},e.prototype.cache=function(e,t,n){var r,s,o;return r=null!=n?n(this):this.isComplex(),r?(s=new x(e.scope.freeVariable("ref")),o=new i(s,this),t?[o.compileToFragments(e,t),[this.makeCode(s.value)]]:[o,s]):(s=t?this.compileToFragments(e,t):this,[s,s])},e.prototype.cacheToCodeFragments=function(e){return[st(e[0]),st(e[1])]},e.prototype.makeReturn=function(e){var t;return t=this.unwrapAll(),e?new o(new x(e+".push"),[t]):new M(t)},e.prototype.contains=function(e){var t;return t=void 0,this.traverseChildren(!1,function(n){return e(n)?(t=n,!1):void 0}),t},e.prototype.lastNonComment=function(e){var t;for(t=e.length;t--;)if(!(e[t]instanceof l))return e[t];return null},e.prototype.toString=function(e,t){var n;return null==e&&(e=""),null==t&&(t=this.constructor.name),n="\n"+e+t,this.soak&&(n+="?"),this.eachChild(function(t){return n+=t.toString(e+q)}),n},e.prototype.eachChild=function(e){var t,n,i,r,s,o,a,c;if(!this.children)return this;for(a=this.children,i=0,s=a.length;s>i;i++)if(t=a[i],this[t])for(c=rt([this[t]]),r=0,o=c.length;o>r;r++)if(n=c[r],e(n)===!1)return this;return this},e.prototype.traverseChildren=function(e,t){return this.eachChild(function(n){var i;return i=t(n),i!==!1?n.traverseChildren(e,t):void 0})},e.prototype.invert=function(){return new I("!",this)},e.prototype.unwrapAll=function(){var e;for(e=this;e!==(e=e.unwrap()););return e},e.prototype.children=[],e.prototype.isStatement=D,e.prototype.jumps=D,e.prototype.isComplex=Q,e.prototype.isChainable=D,e.prototype.isAssignable=D,e.prototype.unwrap=X,e.prototype.unfoldSoak=D,e.prototype.assigns=D,e.prototype.updateLocationDataIfMissing=function(e){return this.locationData?this:(this.locationData=e,this.eachChild(function(t){return t.updateLocationDataIfMissing(e)}))},e.prototype.error=function(e){return vt(e,this.locationData)},e.prototype.makeCode=function(e){return new h(this,e)},e.prototype.wrapInBraces=function(e){return[].concat(this.makeCode("("),e,this.makeCode(")"))},e.prototype.joinFragmentArrays=function(e,t){var n,i,r,s,o;for(n=[],r=s=0,o=e.length;o>s;r=++s)i=e[r],r&&n.push(this.makeCode(t)),n=n.concat(i);return n},e}(),e.Block=s=function(e){function t(e){this.expressions=et(rt(e||[]))}return kt(t,e),t.prototype.children=["expressions"],t.prototype.push=function(e){return this.expressions.push(e),this},t.prototype.pop=function(){return this.expressions.pop()},t.prototype.unshift=function(e){return this.expressions.unshift(e),this},t.prototype.unwrap=function(){return 1===this.expressions.length?this.expressions[0]:this},t.prototype.isEmpty=function(){return!this.expressions.length},t.prototype.isStatement=function(e){var t,n,i,r;for(r=this.expressions,n=0,i=r.length;i>n;n++)if(t=r[n],t.isStatement(e))return!0;return!1},t.prototype.jumps=function(e){var t,n,i,r,s;for(s=this.expressions,n=0,r=s.length;r>n;n++)if(t=s[n],i=t.jumps(e))return i},t.prototype.makeReturn=function(e){var t,n;for(n=this.expressions.length;n--;)if(t=this.expressions[n],!(t instanceof l)){this.expressions[n]=t.makeReturn(e),t instanceof M&&!t.expression&&this.expressions.splice(n,1);break}return this},t.prototype.compileToFragments=function(e,n){return null==e&&(e={}),e.scope?t.__super__.compileToFragments.call(this,e,n):this.compileRoot(e)},t.prototype.compileNode=function(e){var n,i,r,s,o,a,c,h,l;for(this.tab=e.indent,l=e.level===L,i=[],h=this.expressions,s=o=0,a=h.length;a>o;s=++o)c=h[s],c=c.unwrapAll(),c=c.unfoldSoak(e)||c,c instanceof t?i.push(c.compileNode(e)):l?(c.front=!0,r=c.compileToFragments(e),c.isStatement(e)||(r.unshift(this.makeCode(""+this.tab)),r.push(this.makeCode(";"))),i.push(r)):i.push(c.compileToFragments(e,E));return l?this.spaced?[].concat(this.joinFragmentArrays(i,"\n\n"),this.makeCode("\n")):this.joinFragmentArrays(i,"\n"):(n=i.length?this.joinFragmentArrays(i,", "):[this.makeCode("void 0")],i.length>1&&e.level>=E?this.wrapInBraces(n):n)},t.prototype.compileRoot=function(e){var t,n,i,r,s,o,a,c,h,u,p;for(e.indent=e.bare?"":q,e.level=L,this.spaced=!0,e.scope=new P(null,this,null,null!=(h=e.referencedVars)?h:[]),u=e.locals||[],r=0,s=u.length;s>r;r++)o=u[r],e.scope.parameter(o);return a=[],e.bare||(c=function(){var e,n,r,s;for(r=this.expressions,s=[],i=e=0,n=r.length;n>e&&(t=r[i],t.unwrap()instanceof l);i=++e)s.push(t);return s}.call(this),p=this.expressions.slice(c.length),this.expressions=c,c.length&&(a=this.compileNode(lt(e,{indent:""})),a.push(this.makeCode("\n"))),this.expressions=p),n=this.compileWithDeclarations(e),e.bare?n:[].concat(a,this.makeCode("(function() {\n"),n,this.makeCode("\n}).call(this);\n"))},t.prototype.compileWithDeclarations=function(e){var t,n,i,r,s,o,a,c,h,u,p,d,f,m;for(r=[],c=[],h=this.expressions,s=o=0,a=h.length;a>o&&(i=h[s],i=i.unwrap(),i instanceof l||i instanceof x);s=++o);return e=lt(e,{level:L}),s&&(d=this.expressions.splice(s,9e9),u=[this.spaced,!1],m=u[0],this.spaced=u[1],p=[this.compileNode(e),m],r=p[0],this.spaced=p[1],this.expressions=d),c=this.compileNode(e),f=e.scope,f.expressions===this&&(n=e.scope.hasDeclarations(),t=f.hasAssignments,n||t?(s&&r.push(this.makeCode("\n")),r.push(this.makeCode(this.tab+"var ")),n&&r.push(this.makeCode(f.declaredVariables().join(", "))),t&&(n&&r.push(this.makeCode(",\n"+(this.tab+q))),r.push(this.makeCode(f.assignedVariables().join(",\n"+(this.tab+q))))),r.push(this.makeCode(";\n"+(this.spaced?"\n":"")))):r.length&&c.length&&r.push(this.makeCode("\n"))),r.concat(c)},t.wrap=function(e){return 1===e.length&&e[0]instanceof t?e[0]:new t(e)},t}(r),e.Literal=x=function(e){function t(e){this.value=e}return kt(t,e),t.prototype.makeReturn=function(){return this.isStatement()?this:t.__super__.makeReturn.apply(this,arguments)},t.prototype.isAssignable=function(){return g.test(this.value)},t.prototype.isStatement=function(){var e;return"break"===(e=this.value)||"continue"===e||"debugger"===e},t.prototype.isComplex=D,t.prototype.assigns=function(e){return e===this.value},t.prototype.jumps=function(e){return"break"!==this.value||(null!=e?e.loop:void 0)||(null!=e?e.block:void 0)?"continue"!==this.value||(null!=e?e.loop:void 0)?void 0:this:this},t.prototype.compileNode=function(e){var t,n,i;return n="this"===this.value?(null!=(i=e.scope.method)?i.bound:void 0)?e.scope.method.context:this.value:this.value.reserved?'"'+this.value+'"':this.value,t=this.isStatement()?""+this.tab+n+";":n,[this.makeCode(t)]},t.prototype.toString=function(){return' "'+this.value+'"'},t}(r),e.Undefined=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return kt(t,e),t.prototype.isAssignable=D,t.prototype.isComplex=D,t.prototype.compileNode=function(e){return[this.makeCode(e.level>=T?"(void 0)":"void 0")]},t}(r),e.Null=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return kt(t,e),t.prototype.isAssignable=D,t.prototype.isComplex=D,t.prototype.compileNode=function(){return[this.makeCode("null")]},t}(r),e.Bool=function(e){function t(e){this.val=e}return kt(t,e),t.prototype.isAssignable=D,t.prototype.isComplex=D,t.prototype.compileNode=function(){return[this.makeCode(this.val)]},t}(r),e.Return=M=function(e){function t(e){this.expression=e}return kt(t,e),t.prototype.children=["expression"],t.prototype.isStatement=Q,t.prototype.makeReturn=X,t.prototype.jumps=X,t.prototype.compileToFragments=function(e,n){var i,r;return i=null!=(r=this.expression)?r.makeReturn():void 0,!i||i instanceof t?t.__super__.compileToFragments.call(this,e,n):i.compileToFragments(e,n)},t.prototype.compileNode=function(e){var t,n,i;return t=[],n=null!=(i=this.expression)?"function"==typeof i.isYieldReturn?i.isYieldReturn():void 0:void 0,n||t.push(this.makeCode(this.tab+("return"+(this.expression?" ":"")))),this.expression&&(t=t.concat(this.expression.compileToFragments(e,N))),n||t.push(this.makeCode(";")),t},t}(r),e.Value=z=function(e){function t(e,n,i){return!n&&e instanceof t?e:(this.base=e,this.properties=n||[],i&&(this[i]=!0),this)}return kt(t,e),t.prototype.children=["base","properties"],t.prototype.add=function(e){return this.properties=this.properties.concat(e),this},t.prototype.hasProperties=function(){return!!this.properties.length},t.prototype.bareLiteral=function(e){return!this.properties.length&&this.base instanceof e},t.prototype.isArray=function(){return this.bareLiteral(n)},t.prototype.isRange=function(){return this.bareLiteral(j)},t.prototype.isComplex=function(){return this.hasProperties()||this.base.isComplex()},t.prototype.isAssignable=function(){return this.hasProperties()||this.base.isAssignable()},t.prototype.isSimpleNumber=function(){return this.bareLiteral(x)&&B.test(this.base.value)},t.prototype.isString=function(){return this.bareLiteral(x)&&y.test(this.base.value)},t.prototype.isRegex=function(){return this.bareLiteral(x)&&v.test(this.base.value)},t.prototype.isAtomic=function(){var e,t,n,i;for(i=this.properties.concat(this.base),e=0,t=i.length;t>e;e++)if(n=i[e],n.soak||n instanceof o)return!1;return!0},t.prototype.isNotCallable=function(){return this.isSimpleNumber()||this.isString()||this.isRegex()||this.isArray()||this.isRange()||this.isSplice()||this.isObject()},t.prototype.isStatement=function(e){return!this.properties.length&&this.base.isStatement(e)},t.prototype.assigns=function(e){return!this.properties.length&&this.base.assigns(e)},t.prototype.jumps=function(e){return!this.properties.length&&this.base.jumps(e)},t.prototype.isObject=function(e){return this.properties.length?!1:this.base instanceof A&&(!e||this.base.generated)},t.prototype.isSplice=function(){var e,t;return t=this.properties,e=t[t.length-1],e instanceof U},t.prototype.looksStatic=function(e){var t;return this.base.value===e&&1===this.properties.length&&"prototype"!==(null!=(t=this.properties[0].name)?t.value:void 0)},t.prototype.unwrap=function(){return this.properties.length?this:this.base},t.prototype.cacheReference=function(e){var n,r,s,o,a;return a=this.properties,s=a[a.length-1],2>this.properties.length&&!this.base.isComplex()&&!(null!=s?s.isComplex():void 0)?[this,this]:(n=new t(this.base,this.properties.slice(0,-1)),n.isComplex()&&(r=new x(e.scope.freeVariable("base")),n=new t(new O(new i(r,n)))),s?(s.isComplex()&&(o=new x(e.scope.freeVariable("name")),s=new w(new i(o,s.index)),o=new w(o)),[n.add(s),new t(r||n.base,[o||s])]):[n,r])},t.prototype.compileNode=function(e){var t,n,i,r,s;for(this.base.front=this.front,s=this.properties,t=this.base.compileToFragments(e,s.length?T:null),(this.base instanceof O||s.length)&&B.test(st(t))&&t.push(this.makeCode(".")),n=0,i=s.length;i>n;n++)r=s[n],t.push.apply(t,r.compileToFragments(e));return t},t.prototype.unfoldSoak=function(e){return null!=this.unfoldedSoak?this.unfoldedSoak:this.unfoldedSoak=function(n){return function(){var r,s,o,a,c,h,l,p,d,f;if(o=n.base.unfoldSoak(e))return(p=o.body.properties).push.apply(p,n.properties),o;for(d=n.properties,s=a=0,c=d.length;c>a;s=++a)if(h=d[s],h.soak)return h.soak=!1,r=new t(n.base,n.properties.slice(0,s)),f=new t(n.base,n.properties.slice(s)),r.isComplex()&&(l=new x(e.scope.freeVariable("ref")),r=new O(new i(l,r)),f.base=l),new b(new u(r),f,{soak:!0});return!1}}(this)()},t}(r),e.Comment=l=function(e){function t(e){this.comment=e}return kt(t,e),t.prototype.isStatement=Q,t.prototype.makeReturn=X,t.prototype.compileNode=function(e,t){var n,i;return i=this.comment.replace(/^(\s*)#(?=\s)/gm,"$1 *"),n="/*"+ut(i,this.tab)+(Tt.call(i,"\n")>=0?"\n"+this.tab:"")+" */",(t||e.level)===L&&(n=e.indent+n),[this.makeCode("\n"),this.makeCode(n)]},t}(r),e.Call=o=function(e){function n(e,t,n){this.args=null!=t?t:[],this.soak=n,this.isNew=!1,this.isSuper="super"===e,this.variable=this.isSuper?null:e,e instanceof z&&e.isNotCallable()&&e.error("literal is not a function")}return kt(n,e),n.prototype.children=["variable","args"],n.prototype.newInstance=function(){var e,t;return e=(null!=(t=this.variable)?t.base:void 0)||this.variable,e instanceof n&&!e.isNew?e.newInstance():this.isNew=!0,this},n.prototype.superReference=function(e){var n,r,s,o,a,c,h,l;return a=e.scope.namedMethod(),(null!=a?a.klass:void 0)?(o=a.klass,c=a.name,l=a.variable,o.isComplex()&&(s=new x(e.scope.parent.freeVariable("base")),r=new z(new O(new i(s,o))),l.base=r,l.properties.splice(0,o.properties.length)),(c.isComplex()||c instanceof w&&c.index.isAssignable())&&(h=new x(e.scope.parent.freeVariable("name")),c=new w(new i(h,c.index)),l.properties.pop(),l.properties.push(c)),n=[new t(new x("__super__"))],a["static"]&&n.push(new t(new x("constructor"))),n.push(null!=h?new w(h):c),new z(null!=s?s:o,n).compile(e)):(null!=a?a.ctor:void 0)?a.name+".__super__.constructor":this.error("cannot call super outside of an instance method.")},n.prototype.superThis=function(e){var t;return t=e.scope.method,t&&!t.klass&&t.context||"this"},n.prototype.unfoldSoak=function(e){var t,i,r,s,o,a,c,h,l;if(this.soak){if(this.variable){if(i=yt(e,this,"variable"))return i;c=new z(this.variable).cacheReference(e),s=c[0],l=c[1]}else s=new x(this.superReference(e)),l=new z(s);return l=new n(l,this.args),l.isNew=this.isNew,s=new x("typeof "+s.compile(e)+' === "function"'),new b(s,new z(l),{soak:!0})}for(t=this,a=[];;)if(t.variable instanceof n)a.push(t),t=t.variable;else{if(!(t.variable instanceof z))break;if(a.push(t),!((t=t.variable.base)instanceof n))break}for(h=a.reverse(),r=0,o=h.length;o>r;r++)t=h[r],i&&(t.variable instanceof n?t.variable=i:t.variable.base=i),i=yt(e,t,"variable");return i},n.prototype.compileNode=function(e){var t,n,i,r,s,o,a,c,h,l;if(null!=(h=this.variable)&&(h.front=this.front),r=G.compileSplattedArray(e,this.args,!0),r.length)return this.compileSplat(e,r);for(i=[],l=this.args,n=o=0,a=l.length;a>o;n=++o)t=l[n],n&&i.push(this.makeCode(", ")),i.push.apply(i,t.compileToFragments(e,E));return s=[],this.isSuper?(c=this.superReference(e)+(".call("+this.superThis(e)),i.length&&(c+=", "),s.push(this.makeCode(c))):(this.isNew&&s.push(this.makeCode("new ")),s.push.apply(s,this.variable.compileToFragments(e,T)),s.push(this.makeCode("("))),s.push.apply(s,i),s.push(this.makeCode(")")),s},n.prototype.compileSplat=function(e,t){var n,i,r,s,o,a;return this.isSuper?[].concat(this.makeCode(this.superReference(e)+".apply("+this.superThis(e)+", "),t,this.makeCode(")")):this.isNew?(s=this.tab+q,[].concat(this.makeCode("(function(func, args, ctor) {\n"+s+"ctor.prototype = func.prototype;\n"+s+"var child = new ctor, result = func.apply(child, args);\n"+s+"return Object(result) === result ? result : child;\n"+this.tab+"})("),this.variable.compileToFragments(e,E),this.makeCode(", "),t,this.makeCode(", function(){})"))):(n=[],i=new z(this.variable),(o=i.properties.pop())&&i.isComplex()?(a=e.scope.freeVariable("ref"),n=n.concat(this.makeCode("("+a+" = "),i.compileToFragments(e,E),this.makeCode(")"),o.compileToFragments(e))):(r=i.compileToFragments(e,T),B.test(st(r))&&(r=this.wrapInBraces(r)),o?(a=st(r),r.push.apply(r,o.compileToFragments(e))):a="null",n=n.concat(r)),n=n.concat(this.makeCode(".apply("+a+", "),t,this.makeCode(")")))},n}(r),e.Extends=d=function(e){function t(e,t){this.child=e,this.parent=t}return kt(t,e),t.prototype.children=["child","parent"],t.prototype.compileToFragments=function(e){return new o(new z(new x(bt("extend",e))),[this.child,this.parent]).compileToFragments(e)},t}(r),e.Access=t=function(e){function t(e,t){this.name=e,this.name.asKey=!0,this.soak="soak"===t}return kt(t,e),t.prototype.children=["name"],t.prototype.compileToFragments=function(e){var t;return t=this.name.compileToFragments(e),g.test(st(t))?t.unshift(this.makeCode(".")):(t.unshift(this.makeCode("[")),t.push(this.makeCode("]"))),t},t.prototype.isComplex=D,t}(r),e.Index=w=function(e){function t(e){this.index=e}return kt(t,e),t.prototype.children=["index"],t.prototype.compileToFragments=function(e){return[].concat(this.makeCode("["),this.index.compileToFragments(e,N),this.makeCode("]"))},t.prototype.isComplex=function(){return this.index.isComplex()},t}(r),e.Range=j=function(e){function t(e,t,n){this.from=e,this.to=t,this.exclusive="exclusive"===n,this.equals=this.exclusive?"":"="}return kt(t,e),t.prototype.children=["from","to"],t.prototype.compileVariables=function(e){var t,n,i,r,s,o;return e=lt(e,{top:!0}),t=tt(e,"isComplex"),n=this.cacheToCodeFragments(this.from.cache(e,E,t)),this.fromC=n[0],this.fromVar=n[1],i=this.cacheToCodeFragments(this.to.cache(e,E,t)),this.toC=i[0],this.toVar=i[1],(o=tt(e,"step"))&&(r=this.cacheToCodeFragments(o.cache(e,E,t)),this.step=r[0],this.stepVar=r[1]),s=[this.fromVar.match(R),this.toVar.match(R)],this.fromNum=s[0],this.toNum=s[1],this.stepVar?this.stepNum=this.stepVar.match(R):void 0},t.prototype.compileNode=function(e){var t,n,i,r,s,o,a,c,h,l,u,p,d,f;return this.fromVar||this.compileVariables(e),e.index?(a=this.fromNum&&this.toNum,s=tt(e,"index"),o=tt(e,"name"),h=o&&o!==s,f=s+" = "+this.fromC,this.toC!==this.toVar&&(f+=", "+this.toC),this.step!==this.stepVar&&(f+=", "+this.step),l=[s+" <"+this.equals,s+" >"+this.equals],c=l[0],r=l[1],n=this.stepNum?pt(this.stepNum[0])>0?c+" "+this.toVar:r+" "+this.toVar:a?(u=[pt(this.fromNum[0]),pt(this.toNum[0])],i=u[0],d=u[1],u,d>=i?c+" "+d:r+" "+d):(t=this.stepVar?this.stepVar+" > 0":this.fromVar+" <= "+this.toVar,t+" ? "+c+" "+this.toVar+" : "+r+" "+this.toVar),p=this.stepVar?s+" += "+this.stepVar:a?h?d>=i?"++"+s:"--"+s:d>=i?s+"++":s+"--":h?t+" ? ++"+s+" : --"+s:t+" ? "+s+"++ : "+s+"--",h&&(f=o+" = "+f),h&&(p=o+" = "+p),[this.makeCode(f+"; "+n+"; "+p)]):this.compileArray(e)},t.prototype.compileArray=function(e){var t,n,i,r,s,o,a,c,h,l,u,p,d;return this.fromNum&&this.toNum&&20>=Math.abs(this.fromNum-this.toNum)?(h=function(){p=[];for(var e=l=+this.fromNum,t=+this.toNum;t>=l?t>=e:e>=t;t>=l?e++:e--)p.push(e);return p}.apply(this),this.exclusive&&h.pop(),[this.makeCode("["+h.join(", ")+"]")]):(o=this.tab+q,s=e.scope.freeVariable("i",{single:!0}),u=e.scope.freeVariable("results"),c="\n"+o+u+" = [];",this.fromNum&&this.toNum?(e.index=s,n=st(this.compileNode(e))):(d=s+" = "+this.fromC+(this.toC!==this.toVar?", "+this.toC:""),i=this.fromVar+" <= "+this.toVar,n="var "+d+"; "+i+" ? "+s+" <"+this.equals+" "+this.toVar+" : "+s+" >"+this.equals+" "+this.toVar+"; "+i+" ? "+s+"++ : "+s+"--"),a="{ "+u+".push("+s+"); }\n"+o+"return "+u+";\n"+e.indent,r=function(e){return null!=e?e.contains(at):void 0},(r(this.from)||r(this.to))&&(t=", arguments"),[this.makeCode("(function() {"+c+"\n"+o+"for ("+n+")"+a+"}).apply(this"+(null!=t?t:"")+")")])},t}(r),e.Slice=U=function(e){function t(e){this.range=e,t.__super__.constructor.call(this)}return kt(t,e),t.prototype.children=["range"],t.prototype.compileNode=function(e){var t,n,i,r,s,o,a;return s=this.range,o=s.to,i=s.from,r=i&&i.compileToFragments(e,N)||[this.makeCode("0")],o&&(t=o.compileToFragments(e,N),n=st(t),(this.range.exclusive||-1!==+n)&&(a=", "+(this.range.exclusive?n:B.test(n)?""+(+n+1):(t=o.compileToFragments(e,T),"+"+st(t)+" + 1 || 9e9")))),[this.makeCode(".slice("+st(r)+(a||"")+")")]},t}(r),e.Obj=A=function(e){function n(e,t){this.generated=null!=t?t:!1,this.objects=this.properties=e||[]}return kt(n,e),n.prototype.children=["properties"],n.prototype.compileNode=function(e){var n,r,s,o,a,c,h,u,p,d,f,m,g,v,y,b,k,w,T,C,E;if(T=this.properties,this.generated)for(h=0,g=T.length;g>h;h++)b=T[h],b instanceof z&&b.error("cannot have an implicit value in an implicit object");for(r=p=0,v=T.length;v>p&&(w=T[r],!((w.variable||w).base instanceof O));r=++p);for(s=T.length>r,a=e.indent+=q,m=this.lastNonComment(this.properties),n=[],s&&(k=e.scope.freeVariable("obj"),n.push(this.makeCode("(\n"+a+k+" = "))),n.push(this.makeCode("{"+(0===T.length||0===r?"}":"\n"))),o=f=0,y=T.length;y>f;o=++f)w=T[o],o===r&&(0!==o&&n.push(this.makeCode("\n"+a+"}")),n.push(this.makeCode(",\n"))),u=o===T.length-1||o===r-1?"":w===m||w instanceof l?"\n":",\n",c=w instanceof l?"":a,s&&r>o&&(c+=q),w instanceof i&&w.variable instanceof z&&w.variable.hasProperties()&&w.variable.error("invalid object key"),w instanceof z&&w["this"]&&(w=new i(w.properties[0].name,w,"object")),w instanceof l||(r>o?(w instanceof i||(w=new i(w,w,"object")),(w.variable.base||w.variable).asKey=!0):(w instanceof i?(d=w.variable,E=w.value):(C=w.base.cache(e),d=C[0],E=C[1]),w=new i(new z(new x(k),[new t(d)]),E))),c&&n.push(this.makeCode(c)),n.push.apply(n,w.compileToFragments(e,L)),u&&n.push(this.makeCode(u));return s?n.push(this.makeCode(",\n"+a+k+"\n"+this.tab+")")):0!==T.length&&n.push(this.makeCode("\n"+this.tab+"}")),this.front&&!s?this.wrapInBraces(n):n},n.prototype.assigns=function(e){var t,n,i,r;for(r=this.properties,t=0,n=r.length;n>t;t++)if(i=r[t],i.assigns(e))return!0;return!1},n}(r),e.Arr=n=function(e){function t(e){this.objects=e||[]}return kt(t,e),t.prototype.children=["objects"],t.prototype.compileNode=function(e){var t,n,i,r,s,o,a;if(!this.objects.length)return[this.makeCode("[]")];if(e.indent+=q,t=G.compileSplattedArray(e,this.objects),t.length)return t;for(t=[],n=function(){var t,n,i,r;for(i=this.objects,r=[],t=0,n=i.length;n>t;t++)a=i[t],r.push(a.compileToFragments(e,E));return r}.call(this),r=s=0,o=n.length;o>s;r=++s)i=n[r],r&&t.push(this.makeCode(", ")),t.push.apply(t,i);return st(t).indexOf("\n")>=0?(t.unshift(this.makeCode("[\n"+e.indent)),t.push(this.makeCode("\n"+this.tab+"]"))):(t.unshift(this.makeCode("[")),t.push(this.makeCode("]"))),t},t.prototype.assigns=function(e){var t,n,i,r;for(r=this.objects,t=0,n=r.length;n>t;t++)if(i=r[t],i.assigns(e))return!0;return!1},t}(r),e.Class=a=function(e){function n(e,t,n){this.variable=e,this.parent=t,this.body=null!=n?n:new s,this.boundFuncs=[],this.body.classBody=!0}return kt(n,e),n.prototype.children=["variable","parent","body"],n.prototype.determineName=function(){var e,n,i;return this.variable?(n=this.variable.properties,i=n[n.length-1],e=i?i instanceof t&&i.name.value:this.variable.base.value,Tt.call(V,e)>=0&&this.variable.error("class variable name may not be "+e),e&&(e=g.test(e)&&e)):null},n.prototype.setContext=function(e){return this.body.traverseChildren(!1,function(t){return t.classBody?!1:t instanceof x&&"this"===t.value?t.value=e:t instanceof c&&t.bound?t.context=e:void 0})},n.prototype.addBoundFunctions=function(e){var n,i,r,s,o;for(o=this.boundFuncs,i=0,r=o.length;r>i;i++)n=o[i],s=new z(new x("this"),[new t(n)]).compile(e),this.ctor.body.unshift(new x(s+" = "+bt("bind",e)+"("+s+", this)"))},n.prototype.addProperties=function(e,n,r){var s,o,a,h,l,u;return u=e.base.properties.slice(0),h=function(){var e;for(e=[];o=u.shift();)o instanceof i&&(a=o.variable.base,delete o.context,l=o.value,"constructor"===a.value?(this.ctor&&o.error("cannot define more than one constructor in a class"),l.bound&&o.error("cannot define a constructor as a bound function"),l instanceof c?o=this.ctor=l:(this.externalCtor=r.classScope.freeVariable("class"),o=new i(new x(this.externalCtor),l))):o.variable["this"]?l["static"]=!0:(s=a.isComplex()?new w(a):new t(a),o.variable=new z(new x(n),[new t(new x("prototype")),s]),l instanceof c&&l.bound&&(this.boundFuncs.push(a),l.bound=!1))),e.push(o);return e}.call(this),et(h)},n.prototype.walkBody=function(e,t){return this.traverseChildren(!1,function(r){return function(o){var a,c,h,l,u,p,d;if(a=!0,o instanceof n)return!1;if(o instanceof s){for(d=c=o.expressions,h=l=0,u=d.length;u>l;h=++l)p=d[h],p instanceof i&&p.variable.looksStatic(e)?p.value["static"]=!0:p instanceof z&&p.isObject(!0)&&(a=!1,c[h]=r.addProperties(p,e,t));o.expressions=c=rt(c)}return a&&!(o instanceof n)}}(this))},n.prototype.hoistDirectivePrologue=function(){var e,t,n;for(t=0,e=this.body.expressions;(n=e[t])&&n instanceof l||n instanceof z&&n.isString();)++t;return this.directives=e.splice(0,t)},n.prototype.ensureConstructor=function(e){return this.ctor||(this.ctor=new c,this.externalCtor?this.ctor.body.push(new x(this.externalCtor+".apply(this, arguments)")):this.parent&&this.ctor.body.push(new x(e+".__super__.constructor.apply(this, arguments)")),this.ctor.body.makeReturn(),this.body.expressions.unshift(this.ctor)),this.ctor.ctor=this.ctor.name=e,this.ctor.klass=null,this.ctor.noReturn=!0},n.prototype.compileNode=function(e){var t,n,r,a,h,l,u,p,f;return(a=this.body.jumps())&&a.error("Class bodies cannot contain pure statements"),(n=this.body.contains(at))&&n.error("Class bodies shouldn't reference arguments"),u=this.determineName()||"_Class",u.reserved&&(u="_"+u),l=new x(u),r=new c([],s.wrap([this.body])),t=[],e.classScope=r.makeScope(e.scope),this.hoistDirectivePrologue(),this.setContext(u),this.walkBody(u,e),this.ensureConstructor(u),this.addBoundFunctions(e),this.body.spaced=!0,this.body.expressions.push(l),this.parent&&(f=new x(e.classScope.freeVariable("superClass",{reserve:!1})),this.body.expressions.unshift(new d(l,f)),r.params.push(new _(f)),t.push(this.parent)),(p=this.body.expressions).unshift.apply(p,this.directives),h=new O(new o(r,t)),this.variable&&(h=new i(this.variable,h)),h.compileToFragments(e)},n}(r),e.Assign=i=function(e){function n(e,t,n,i){var r,s,o;this.variable=e,this.value=t,this.context=n,this.param=i&&i.param,this.subpattern=i&&i.subpattern,o=s=this.variable.unwrapAll().value,r=Tt.call(V,o)>=0,r&&"object"!==this.context&&this.variable.error('variable name may not be "'+s+'"')}return kt(n,e),n.prototype.children=["variable","value"],n.prototype.isStatement=function(e){return(null!=e?e.level:void 0)===L&&null!=this.context&&Tt.call(this.context,"?")>=0
+},n.prototype.assigns=function(e){return this["object"===this.context?"value":"variable"].assigns(e)},n.prototype.unfoldSoak=function(e){return yt(e,this,"variable")},n.prototype.compileNode=function(e){var t,n,i,r,s,o,a,h,l,u,p,d,f,m;if(i=this.variable instanceof z){if(this.variable.isArray()||this.variable.isObject())return this.compilePatternMatch(e);if(this.variable.isSplice())return this.compileSplice(e);if("||="===(h=this.context)||"&&="===h||"?="===h)return this.compileConditional(e);if("**="===(l=this.context)||"//="===l||"%%="===l)return this.compileSpecialMath(e)}return this.value instanceof c&&(this.value["static"]?(this.value.klass=this.variable.base,this.value.name=this.variable.properties[0],this.value.variable=this.variable):(null!=(u=this.variable.properties)?u.length:void 0)>=2&&(p=this.variable.properties,o=p.length>=3?Ct.call(p,0,r=p.length-2):(r=0,[]),a=p[r++],s=p[r++],"prototype"===(null!=(d=a.name)?d.value:void 0)&&(this.value.klass=new z(this.variable.base,o),this.value.name=s,this.value.variable=this.variable))),this.context||(m=this.variable.unwrapAll(),m.isAssignable()||this.variable.error('"'+this.variable.compile(e)+'" cannot be assigned'),("function"==typeof m.hasProperties?m.hasProperties():void 0)||(this.param?e.scope.add(m.value,"var"):e.scope.find(m.value))),f=this.value.compileToFragments(e,E),n=this.variable.compileToFragments(e,E),"object"===this.context?n.concat(this.makeCode(": "),f):(t=n.concat(this.makeCode(" "+(this.context||"=")+" "),f),E>=e.level?t:this.wrapInBraces(t))},n.prototype.compilePatternMatch=function(e){var i,r,s,o,a,c,h,l,u,d,f,m,v,y,b,k,T,C,N,S,D,R,A,I,_,j,M,B;if(I=e.level===L,j=this.value,y=this.variable.base.objects,!(b=y.length))return s=j.compileToFragments(e),e.level>=F?this.wrapInBraces(s):s;if(l=this.variable.isObject(),I&&1===b&&!((v=y[0])instanceof G))return v instanceof n?(T=v,C=T.variable,h=C.base,v=T.value):h=l?v["this"]?v.properties[0].name:v:new x(0),i=g.test(h.unwrap().value||0),j=new z(j),j.properties.push(new(i?t:w)(h)),N=v.unwrap().value,Tt.call($,N)>=0&&v.error("assignment to a reserved word: "+v.compile(e)),new n(v,j,null,{param:this.param}).compileToFragments(e,L);for(M=j.compileToFragments(e,E),B=st(M),r=[],o=!1,(!g.test(B)||this.variable.assigns(B))&&(r.push([this.makeCode((k=e.scope.freeVariable("ref"))+" = ")].concat(Ct.call(M))),M=[this.makeCode(k)],B=k),c=d=0,f=y.length;f>d;c=++d){if(v=y[c],h=c,l&&(v instanceof n?(S=v,D=S.variable,h=D.base,v=S.value):v.base instanceof O?(R=new z(v.unwrapAll()).cacheReference(e),v=R[0],h=R[1]):h=v["this"]?v.properties[0].name:v),!o&&v instanceof G)m=v.name.unwrap().value,v=v.unwrap(),_=b+" <= "+B+".length ? "+bt("slice",e)+".call("+B+", "+c,(A=b-c-1)?(u=e.scope.freeVariable("i",{single:!0}),_+=", "+u+" = "+B+".length - "+A+") : ("+u+" = "+c+", [])"):_+=") : []",_=new x(_),o=u+"++";else{if(!o&&v instanceof p){(A=b-c-1)&&(1===A?o=B+".length - 1":(u=e.scope.freeVariable("i",{single:!0}),_=new x(u+" = "+B+".length - "+A),o=u+"++",r.push(_.compileToFragments(e,E))));continue}m=v.unwrap().value,(v instanceof G||v instanceof p)&&v.error("multiple splats/expansions are disallowed in an assignment"),"number"==typeof h?(h=new x(o||h),i=!1):i=l&&g.test(h.unwrap().value||0),_=new z(new x(B),[new(i?t:w)(h)])}null!=m&&Tt.call($,m)>=0&&v.error("assignment to a reserved word: "+v.compile(e)),r.push(new n(v,_,null,{param:this.param,subpattern:!0}).compileToFragments(e,E))}return I||this.subpattern||r.push(M),a=this.joinFragmentArrays(r,", "),E>e.level?a:this.wrapInBraces(a)},n.prototype.compileConditional=function(e){var t,i,r,s;return r=this.variable.cacheReference(e),i=r[0],s=r[1],!i.properties.length&&i.base instanceof x&&"this"!==i.base.value&&!e.scope.check(i.base.value)&&this.variable.error('the variable "'+i.base.value+"\" can't be assigned with "+this.context+" because it has not been declared before"),Tt.call(this.context,"?")>=0?(e.isExistentialEquals=!0,new b(new u(i),s,{type:"if"}).addElse(new n(s,this.value,"=")).compileToFragments(e)):(t=new I(this.context.slice(0,-1),i,new n(s,this.value,"=")).compileToFragments(e),E>=e.level?t:this.wrapInBraces(t))},n.prototype.compileSpecialMath=function(e){var t,i,r;return i=this.variable.cacheReference(e),t=i[0],r=i[1],new n(t,new I(this.context.slice(0,-1),r,this.value)).compileToFragments(e)},n.prototype.compileSplice=function(e){var t,n,i,r,s,o,a,c,h,l,u,p;return a=this.variable.properties.pop().range,i=a.from,l=a.to,n=a.exclusive,o=this.variable.compile(e),i?(c=this.cacheToCodeFragments(i.cache(e,F)),r=c[0],s=c[1]):r=s="0",l?i instanceof z&&i.isSimpleNumber()&&l instanceof z&&l.isSimpleNumber()?(l=l.compile(e)-s,n||(l+=1)):(l=l.compile(e,T)+" - "+s,n||(l+=" + 1")):l="9e9",h=this.value.cache(e,E),u=h[0],p=h[1],t=[].concat(this.makeCode("[].splice.apply("+o+", ["+r+", "+l+"].concat("),u,this.makeCode(")), "),p),e.level>L?this.wrapInBraces(t):t},n}(r),e.Code=c=function(e){function t(e,t,n){this.params=e||[],this.body=t||new s,this.bound="boundfunc"===n,this.isGenerator=!!this.body.contains(function(e){var t;return e instanceof I&&("yield"===(t=e.operator)||"yield*"===t)})}return kt(t,e),t.prototype.children=["params","body"],t.prototype.isStatement=function(){return!!this.ctor},t.prototype.jumps=D,t.prototype.makeScope=function(e){return new P(e,this.body,this)},t.prototype.compileNode=function(e){var r,a,c,h,l,u,d,f,m,g,v,y,k,w,C,E,F,N,L,S,D,R,A,O,$,j,M,B,V,P,U,G,H;if(this.bound&&(null!=(A=e.scope.method)?A.bound:void 0)&&(this.context=e.scope.method.context),this.bound&&!this.context)return this.context="_this",H=new t([new _(new x(this.context))],new s([this])),a=new o(H,[new x("this")]),a.updateLocationDataIfMissing(this.locationData),a.compileNode(e);for(e.scope=tt(e,"classScope")||this.makeScope(e.scope),e.scope.shared=tt(e,"sharedScope"),e.indent+=q,delete e.bare,delete e.isExistentialEquals,L=[],h=[],O=this.params,u=0,m=O.length;m>u;u++)N=O[u],N instanceof p||e.scope.parameter(N.asReference(e));for($=this.params,d=0,g=$.length;g>d;d++)if(N=$[d],N.splat||N instanceof p){for(j=this.params,f=0,v=j.length;v>f;f++)F=j[f],F instanceof p||!F.name.value||e.scope.add(F.name.value,"var",!0);V=new i(new z(new n(function(){var t,n,i,r;for(i=this.params,r=[],n=0,t=i.length;t>n;n++)F=i[n],r.push(F.asReference(e));return r}.call(this))),new z(new x("arguments")));break}for(M=this.params,E=0,y=M.length;y>E;E++)N=M[E],N.isComplex()?(U=R=N.asReference(e),N.value&&(U=new I("?",R,N.value)),h.push(new i(new z(N.name),U,"=",{param:!0}))):(R=N,N.value&&(C=new x(R.name.value+" == null"),U=new i(new z(N.name),N.value,"="),h.push(new b(C,U)))),V||L.push(R);for(G=this.body.isEmpty(),V&&h.unshift(V),h.length&&(B=this.body.expressions).unshift.apply(B,h),l=S=0,k=L.length;k>S;l=++S)F=L[l],L[l]=F.compileToFragments(e),e.scope.parameter(st(L[l]));for(P=[],this.eachParamName(function(e,t){return Tt.call(P,e)>=0&&t.error("multiple parameters named "+e),P.push(e)}),G||this.noReturn||this.body.makeReturn(),c="function",this.isGenerator&&(c+="*"),this.ctor&&(c+=" "+this.name),c+="(",r=[this.makeCode(c)],l=D=0,w=L.length;w>D;l=++D)F=L[l],l&&r.push(this.makeCode(", ")),r.push.apply(r,F);return r.push(this.makeCode(") {")),this.body.isEmpty()||(r=r.concat(this.makeCode("\n"),this.body.compileWithDeclarations(e),this.makeCode("\n"+this.tab))),r.push(this.makeCode("}")),this.ctor?[this.makeCode(this.tab)].concat(Ct.call(r)):this.front||e.level>=T?this.wrapInBraces(r):r},t.prototype.eachParamName=function(e){var t,n,i,r,s;for(r=this.params,s=[],t=0,n=r.length;n>t;t++)i=r[t],s.push(i.eachName(e));return s},t.prototype.traverseChildren=function(e,n){return e?t.__super__.traverseChildren.call(this,e,n):void 0},t}(r),e.Param=_=function(e){function t(e,t,n){var i,r;this.name=e,this.value=t,this.splat=n,r=i=this.name.unwrapAll().value,Tt.call(V,r)>=0&&this.name.error('parameter name "'+i+'" is not allowed')}return kt(t,e),t.prototype.children=["name","value"],t.prototype.compileToFragments=function(e){return this.name.compileToFragments(e,E)},t.prototype.asReference=function(e){var t,n;return this.reference?this.reference:(n=this.name,n["this"]?(t=n.properties[0].name.value,t.reserved&&(t="_"+t),n=new x(e.scope.freeVariable(t))):n.isComplex()&&(n=new x(e.scope.freeVariable("arg"))),n=new z(n),this.splat&&(n=new G(n)),n.updateLocationDataIfMissing(this.locationData),this.reference=n)},t.prototype.isComplex=function(){return this.name.isComplex()},t.prototype.eachName=function(e,t){var n,r,s,o,a,c;if(null==t&&(t=this.name),n=function(t){return e("@"+t.properties[0].name.value,t)},t instanceof x)return e(t.value,t);if(t instanceof z)return n(t);for(c=t.objects,r=0,s=c.length;s>r;r++)a=c[r],a instanceof i?this.eachName(e,a.value.unwrap()):a instanceof G?(o=a.name.unwrap(),e(o.value,o)):a instanceof z?a.isArray()||a.isObject()?this.eachName(e,a.base):a["this"]?n(a):e(a.base.value,a.base):a instanceof p||a.error("illegal parameter "+a.compile())},t}(r),e.Splat=G=function(e){function t(e){this.name=e.compile?e:new x(e)}return kt(t,e),t.prototype.children=["name"],t.prototype.isAssignable=Q,t.prototype.assigns=function(e){return this.name.assigns(e)},t.prototype.compileToFragments=function(e){return this.name.compileToFragments(e)},t.prototype.unwrap=function(){return this.name},t.compileSplattedArray=function(e,n,i){var r,s,o,a,c,h,l,u,p,d,f;for(l=-1;(f=n[++l])&&!(f instanceof t););if(l>=n.length)return[];if(1===n.length)return f=n[0],c=f.compileToFragments(e,E),i?c:[].concat(f.makeCode(bt("slice",e)+".call("),c,f.makeCode(")"));for(r=n.slice(l),h=u=0,d=r.length;d>u;h=++u)f=r[h],o=f.compileToFragments(e,E),r[h]=f instanceof t?[].concat(f.makeCode(bt("slice",e)+".call("),o,f.makeCode(")")):[].concat(f.makeCode("["),o,f.makeCode("]"));return 0===l?(f=n[0],a=f.joinFragmentArrays(r.slice(1),", "),r[0].concat(f.makeCode(".concat("),a,f.makeCode(")"))):(s=function(){var t,i,r,s;for(r=n.slice(0,l),s=[],t=0,i=r.length;i>t;t++)f=r[t],s.push(f.compileToFragments(e,E));return s}(),s=n[0].joinFragmentArrays(s,", "),a=n[l].joinFragmentArrays(r,", "),p=n[n.length-1],[].concat(n[0].makeCode("["),s,n[l].makeCode("].concat("),a,p.makeCode(")")))},t}(r),e.Expansion=p=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return kt(t,e),t.prototype.isComplex=D,t.prototype.compileNode=function(){return this.error("Expansion must be used inside a destructuring assignment or parameter list")},t.prototype.asReference=function(){return this},t.prototype.eachName=function(){},t}(r),e.While=J=function(e){function t(e,t){this.condition=(null!=t?t.invert:void 0)?e.invert():e,this.guard=null!=t?t.guard:void 0}return kt(t,e),t.prototype.children=["condition","guard","body"],t.prototype.isStatement=Q,t.prototype.makeReturn=function(e){return e?t.__super__.makeReturn.apply(this,arguments):(this.returns=!this.jumps({loop:!0}),this)},t.prototype.addBody=function(e){return this.body=e,this},t.prototype.jumps=function(){var e,t,n,i,r;if(e=this.body.expressions,!e.length)return!1;for(t=0,i=e.length;i>t;t++)if(r=e[t],n=r.jumps({loop:!0}))return n;return!1},t.prototype.compileNode=function(e){var t,n,i,r;return e.indent+=q,r="",n=this.body,n.isEmpty()?n=this.makeCode(""):(this.returns&&(n.makeReturn(i=e.scope.freeVariable("results")),r=""+this.tab+i+" = [];\n"),this.guard&&(n.expressions.length>1?n.expressions.unshift(new b(new O(this.guard).invert(),new x("continue"))):this.guard&&(n=s.wrap([new b(this.guard,n)]))),n=[].concat(this.makeCode("\n"),n.compileToFragments(e,L),this.makeCode("\n"+this.tab))),t=[].concat(this.makeCode(r+this.tab+"while ("),this.condition.compileToFragments(e,N),this.makeCode(") {"),n,this.makeCode("}")),this.returns&&t.push(this.makeCode("\n"+this.tab+"return "+i+";")),t},t}(r),e.Op=I=function(e){function n(e,t,n,i){if("in"===e)return new k(t,n);if("do"===e)return this.generateDo(t);if("new"===e){if(t instanceof o&&!t["do"]&&!t.isNew)return t.newInstance();(t instanceof c&&t.bound||t["do"])&&(t=new O(t))}return this.operator=r[e]||e,this.first=t,this.second=n,this.flip=!!i,this}var r,s;return kt(n,e),r={"==":"===","!=":"!==",of:"in",yieldfrom:"yield*"},s={"!==":"===","===":"!=="},n.prototype.children=["first","second"],n.prototype.isSimpleNumber=D,n.prototype.isYield=function(){var e;return"yield"===(e=this.operator)||"yield*"===e},n.prototype.isYieldReturn=function(){return this.isYield()&&this.first instanceof M},n.prototype.isUnary=function(){return!this.second},n.prototype.isComplex=function(){var e;return!(this.isUnary()&&("+"===(e=this.operator)||"-"===e)&&this.first instanceof z&&this.first.isSimpleNumber())},n.prototype.isChainable=function(){var e;return"<"===(e=this.operator)||">"===e||">="===e||"<="===e||"==="===e||"!=="===e},n.prototype.invert=function(){var e,t,i,r,o;if(this.isChainable()&&this.first.isChainable()){for(e=!0,t=this;t&&t.operator;)e&&(e=t.operator in s),t=t.first;if(!e)return new O(this).invert();for(t=this;t&&t.operator;)t.invert=!t.invert,t.operator=s[t.operator],t=t.first;return this}return(r=s[this.operator])?(this.operator=r,this.first.unwrap()instanceof n&&this.first.invert(),this):this.second?new O(this).invert():"!"===this.operator&&(i=this.first.unwrap())instanceof n&&("!"===(o=i.operator)||"in"===o||"instanceof"===o)?i:new n("!",this)},n.prototype.unfoldSoak=function(e){var t;return("++"===(t=this.operator)||"--"===t||"delete"===t)&&yt(e,this,"first")},n.prototype.generateDo=function(e){var t,n,r,s,a,h,l,u;for(h=[],n=e instanceof i&&(l=e.value.unwrap())instanceof c?l:e,u=n.params||[],r=0,s=u.length;s>r;r++)a=u[r],a.value?(h.push(a.value),delete a.value):h.push(a);return t=new o(e,h),t["do"]=!0,t},n.prototype.compileNode=function(e){var t,n,i,r,s,o;if(n=this.isChainable()&&this.first.isChainable(),n||(this.first.front=this.front),"delete"===this.operator&&e.scope.check(this.first.unwrapAll().value)&&this.error("delete operand may not be argument or var"),("--"===(r=this.operator)||"++"===r)&&(s=this.first.unwrapAll().value,Tt.call(V,s)>=0)&&this.error('cannot increment/decrement "'+this.first.unwrapAll().value+'"'),this.isYield())return this.compileYield(e);if(this.isUnary())return this.compileUnary(e);if(n)return this.compileChain(e);switch(this.operator){case"?":return this.compileExistence(e);case"**":return this.compilePower(e);case"//":return this.compileFloorDivision(e);case"%%":return this.compileModulo(e);default:return i=this.first.compileToFragments(e,F),o=this.second.compileToFragments(e,F),t=[].concat(i,this.makeCode(" "+this.operator+" "),o),F>=e.level?t:this.wrapInBraces(t)}},n.prototype.compileChain=function(e){var t,n,i,r;return i=this.first.second.cache(e),this.first.second=i[0],r=i[1],n=this.first.compileToFragments(e,F),t=n.concat(this.makeCode(" "+(this.invert?"&&":"||")+" "),r.compileToFragments(e),this.makeCode(" "+this.operator+" "),this.second.compileToFragments(e,F)),this.wrapInBraces(t)},n.prototype.compileExistence=function(e){var t,n;return this.first.isComplex()?(n=new x(e.scope.freeVariable("ref")),t=new O(new i(n,this.first))):(t=this.first,n=t),new b(new u(t),n,{type:"if"}).addElse(this.second).compileToFragments(e)},n.prototype.compileUnary=function(e){var t,i,r;return i=[],t=this.operator,i.push([this.makeCode(t)]),"!"===t&&this.first instanceof u?(this.first.negated=!this.first.negated,this.first.compileToFragments(e)):e.level>=T?new O(this).compileToFragments(e):(r="+"===t||"-"===t,("new"===t||"typeof"===t||"delete"===t||r&&this.first instanceof n&&this.first.operator===t)&&i.push([this.makeCode(" ")]),(r&&this.first instanceof n||"new"===t&&this.first.isStatement(e))&&(this.first=new O(this.first)),i.push(this.first.compileToFragments(e,F)),this.flip&&i.reverse(),this.joinFragmentArrays(i,""))},n.prototype.compileYield=function(e){var t,n;return n=[],t=this.operator,null==e.scope.parent&&this.error("yield statements must occur within a function generator."),Tt.call(Object.keys(this.first),"expression")>=0&&!(this.first instanceof W)?this.isYieldReturn()?n.push(this.first.compileToFragments(e,L)):null!=this.first.expression&&n.push(this.first.expression.compileToFragments(e,F)):(n.push([this.makeCode("("+t+" ")]),n.push(this.first.compileToFragments(e,F)),n.push([this.makeCode(")")])),this.joinFragmentArrays(n,"")},n.prototype.compilePower=function(e){var n;return n=new z(new x("Math"),[new t(new x("pow"))]),new o(n,[this.first,this.second]).compileToFragments(e)},n.prototype.compileFloorDivision=function(e){var i,r;return r=new z(new x("Math"),[new t(new x("floor"))]),i=new n("/",this.first,this.second),new o(r,[i]).compileToFragments(e)},n.prototype.compileModulo=function(e){var t;return t=new z(new x(bt("modulo",e))),new o(t,[this.first,this.second]).compileToFragments(e)},n.prototype.toString=function(e){return n.__super__.toString.call(this,e,this.constructor.name+" "+this.operator)},n}(r),e.In=k=function(e){function t(e,t){this.object=e,this.array=t}return kt(t,e),t.prototype.children=["object","array"],t.prototype.invert=S,t.prototype.compileNode=function(e){var t,n,i,r,s;if(this.array instanceof z&&this.array.isArray()&&this.array.base.objects.length){for(s=this.array.base.objects,n=0,i=s.length;i>n;n++)if(r=s[n],r instanceof G){t=!0;break}if(!t)return this.compileOrTest(e)}return this.compileLoopTest(e)},t.prototype.compileOrTest=function(e){var t,n,i,r,s,o,a,c,h,l,u,p;for(c=this.object.cache(e,F),u=c[0],a=c[1],h=this.negated?[" !== "," && "]:[" === "," || "],t=h[0],n=h[1],p=[],l=this.array.base.objects,i=s=0,o=l.length;o>s;i=++s)r=l[i],i&&p.push(this.makeCode(n)),p=p.concat(i?a:u,this.makeCode(t),r.compileToFragments(e,T));return F>e.level?p:this.wrapInBraces(p)},t.prototype.compileLoopTest=function(e){var t,n,i,r;return i=this.object.cache(e,E),r=i[0],n=i[1],t=[].concat(this.makeCode(bt("indexOf",e)+".call("),this.array.compileToFragments(e,E),this.makeCode(", "),n,this.makeCode(") "+(this.negated?"< 0":">= 0"))),st(r)===st(n)?t:(t=r.concat(this.makeCode(", "),t),E>e.level?t:this.wrapInBraces(t))},t.prototype.toString=function(e){return t.__super__.toString.call(this,e,this.constructor.name+(this.negated?"!":""))},t}(r),e.Try=Y=function(e){function t(e,t,n,i){this.attempt=e,this.errorVariable=t,this.recovery=n,this.ensure=i}return kt(t,e),t.prototype.children=["attempt","recovery","ensure"],t.prototype.isStatement=Q,t.prototype.jumps=function(e){var t;return this.attempt.jumps(e)||(null!=(t=this.recovery)?t.jumps(e):void 0)},t.prototype.makeReturn=function(e){return this.attempt&&(this.attempt=this.attempt.makeReturn(e)),this.recovery&&(this.recovery=this.recovery.makeReturn(e)),this},t.prototype.compileNode=function(e){var t,n,r,s;return e.indent+=q,s=this.attempt.compileToFragments(e,L),t=this.recovery?(r=new x("_error"),this.errorVariable?this.recovery.unshift(new i(this.errorVariable,r)):void 0,[].concat(this.makeCode(" catch ("),r.compileToFragments(e),this.makeCode(") {\n"),this.recovery.compileToFragments(e,L),this.makeCode("\n"+this.tab+"}"))):this.ensure||this.recovery?[]:[this.makeCode(" catch (_error) {}")],n=this.ensure?[].concat(this.makeCode(" finally {\n"),this.ensure.compileToFragments(e,L),this.makeCode("\n"+this.tab+"}")):[],[].concat(this.makeCode(this.tab+"try {\n"),s,this.makeCode("\n"+this.tab+"}"),t,n)},t}(r),e.Throw=W=function(e){function t(e){this.expression=e}return kt(t,e),t.prototype.children=["expression"],t.prototype.isStatement=Q,t.prototype.jumps=D,t.prototype.makeReturn=X,t.prototype.compileNode=function(e){return[].concat(this.makeCode(this.tab+"throw "),this.expression.compileToFragments(e),this.makeCode(";"))},t}(r),e.Existence=u=function(e){function t(e){this.expression=e}return kt(t,e),t.prototype.children=["expression"],t.prototype.invert=S,t.prototype.compileNode=function(e){var t,n,i,r;return this.expression.front=this.front,i=this.expression.compile(e,F),g.test(i)&&!e.scope.check(i)?(r=this.negated?["===","||"]:["!==","&&"],t=r[0],n=r[1],i="typeof "+i+" "+t+' "undefined" '+n+" "+i+" "+t+" null"):i=i+" "+(this.negated?"==":"!=")+" null",[this.makeCode(C>=e.level?i:"("+i+")")]},t}(r),e.Parens=O=function(e){function t(e){this.body=e}return kt(t,e),t.prototype.children=["body"],t.prototype.unwrap=function(){return this.body},t.prototype.isComplex=function(){return this.body.isComplex()},t.prototype.compileNode=function(e){var t,n,i;return n=this.body.unwrap(),n instanceof z&&n.isAtomic()?(n.front=this.front,n.compileToFragments(e)):(i=n.compileToFragments(e,N),t=F>e.level&&(n instanceof I||n instanceof o||n instanceof f&&n.returns),t?i:this.wrapInBraces(i))},t}(r),e.For=f=function(e){function t(e,t){var n;this.source=t.source,this.guard=t.guard,this.step=t.step,this.name=t.name,this.index=t.index,this.body=s.wrap([e]),this.own=!!t.own,this.object=!!t.object,this.object&&(n=[this.index,this.name],this.name=n[0],this.index=n[1]),this.index instanceof z&&this.index.error("index cannot be a pattern matching expression"),this.range=this.source instanceof z&&this.source.base instanceof j&&!this.source.properties.length,this.pattern=this.name instanceof z,this.range&&this.index&&this.index.error("indexes do not apply to range loops"),this.range&&this.pattern&&this.name.error("cannot pattern match over range loops"),this.own&&!this.object&&this.name.error("cannot use own with for-in"),this.returns=!1}return kt(t,e),t.prototype.children=["body","source","guard","step"],t.prototype.compileNode=function(e){var t,n,r,o,a,c,h,l,u,p,d,f,m,v,y,k,w,T,C,F,N,S,D,A,I,_,$,j,B,V,P,U,G,H;return t=s.wrap([this.body]),D=t.expressions,T=D[D.length-1],(null!=T?T.jumps():void 0)instanceof M&&(this.returns=!1),B=this.range?this.source.base:this.source,j=e.scope,this.pattern||(F=this.name&&this.name.compile(e,E)),v=this.index&&this.index.compile(e,E),F&&!this.pattern&&j.find(F),v&&j.find(v),this.returns&&($=j.freeVariable("results")),y=this.object&&v||j.freeVariable("i",{single:!0}),k=this.range&&F||v||y,w=k!==y?k+" = ":"",this.step&&!this.range&&(A=this.cacheToCodeFragments(this.step.cache(e,E,ot)),V=A[0],U=A[1],P=U.match(R)),this.pattern&&(F=y),H="",d="",h="",f=this.tab+q,this.range?p=B.compileToFragments(lt(e,{index:y,name:F,step:this.step,isComplex:ot})):(G=this.source.compile(e,E),!F&&!this.own||g.test(G)||(h+=""+this.tab+(S=j.freeVariable("ref"))+" = "+G+";\n",G=S),F&&!this.pattern&&(N=F+" = "+G+"["+k+"]"),this.object||(V!==U&&(h+=""+this.tab+V+";\n"),this.step&&P&&(u=0>pt(P[0]))||(C=j.freeVariable("len")),a=""+w+y+" = 0, "+C+" = "+G+".length",c=""+w+y+" = "+G+".length - 1",r=y+" < "+C,o=y+" >= 0",this.step?(P?u&&(r=o,a=c):(r=U+" > 0 ? "+r+" : "+o,a="("+U+" > 0 ? ("+a+") : "+c+")"),m=y+" += "+U):m=""+(k!==y?"++"+y:y+"++"),p=[this.makeCode(a+"; "+r+"; "+w+m)])),this.returns&&(I=""+this.tab+$+" = [];\n",_="\n"+this.tab+"return "+$+";",t.makeReturn($)),this.guard&&(t.expressions.length>1?t.expressions.unshift(new b(new O(this.guard).invert(),new x("continue"))):this.guard&&(t=s.wrap([new b(this.guard,t)]))),this.pattern&&t.expressions.unshift(new i(this.name,new x(G+"["+k+"]"))),l=[].concat(this.makeCode(h),this.pluckDirectCall(e,t)),N&&(H="\n"+f+N+";"),this.object&&(p=[this.makeCode(k+" in "+G)],this.own&&(d="\n"+f+"if (!"+bt("hasProp",e)+".call("+G+", "+k+")) continue;")),n=t.compileToFragments(lt(e,{indent:f}),L),n&&n.length>0&&(n=[].concat(this.makeCode("\n"),n,this.makeCode("\n"))),[].concat(l,this.makeCode(""+(I||"")+this.tab+"for ("),p,this.makeCode(") {"+d+H),n,this.makeCode(this.tab+"}"+(_||"")))},t.prototype.pluckDirectCall=function(e,t){var n,r,s,a,h,l,u,p,d,f,m,g,v,y,b,k;for(r=[],d=t.expressions,h=l=0,u=d.length;u>l;h=++l)s=d[h],s=s.unwrapAll(),s instanceof o&&(k=null!=(f=s.variable)?f.unwrapAll():void 0,(k instanceof c||k instanceof z&&(null!=(m=k.base)?m.unwrapAll():void 0)instanceof c&&1===k.properties.length&&("call"===(g=null!=(v=k.properties[0].name)?v.value:void 0)||"apply"===g))&&(a=(null!=(y=k.base)?y.unwrapAll():void 0)||k,p=new x(e.scope.freeVariable("fn")),n=new z(p),k.base&&(b=[n,k],k.base=b[0],n=b[1]),t.expressions[h]=new o(n,s.args),r=r.concat(this.makeCode(this.tab),new i(p,a).compileToFragments(e,L),this.makeCode(";\n"))));return r},t}(J),e.Switch=H=function(e){function t(e,t,n){this.subject=e,this.cases=t,this.otherwise=n}return kt(t,e),t.prototype.children=["subject","cases","otherwise"],t.prototype.isStatement=Q,t.prototype.jumps=function(e){var t,n,i,r,s,o,a,c;for(null==e&&(e={block:!0}),o=this.cases,i=0,s=o.length;s>i;i++)if(a=o[i],n=a[0],t=a[1],r=t.jumps(e))return r;return null!=(c=this.otherwise)?c.jumps(e):void 0},t.prototype.makeReturn=function(e){var t,n,i,r,o;for(r=this.cases,t=0,n=r.length;n>t;t++)i=r[t],i[1].makeReturn(e);return e&&(this.otherwise||(this.otherwise=new s([new x("void 0")]))),null!=(o=this.otherwise)&&o.makeReturn(e),this},t.prototype.compileNode=function(e){var t,n,i,r,s,o,a,c,h,l,u,p,d,f,m,g;for(c=e.indent+q,h=e.indent=c+q,o=[].concat(this.makeCode(this.tab+"switch ("),this.subject?this.subject.compileToFragments(e,N):this.makeCode("false"),this.makeCode(") {\n")),f=this.cases,a=l=0,p=f.length;p>l;a=++l){for(m=f[a],r=m[0],t=m[1],g=rt([r]),u=0,d=g.length;d>u;u++)i=g[u],this.subject||(i=i.invert()),o=o.concat(this.makeCode(c+"case "),i.compileToFragments(e,N),this.makeCode(":\n"));if((n=t.compileToFragments(e,L)).length>0&&(o=o.concat(n,this.makeCode("\n"))),a===this.cases.length-1&&!this.otherwise)break;s=this.lastNonComment(t.expressions),s instanceof M||s instanceof x&&s.jumps()&&"debugger"!==s.value||o.push(i.makeCode(h+"break;\n"))}return this.otherwise&&this.otherwise.expressions.length&&o.push.apply(o,[this.makeCode(c+"default:\n")].concat(Ct.call(this.otherwise.compileToFragments(e,L)),[this.makeCode("\n")])),o.push(this.makeCode(this.tab+"}")),o},t}(r),e.If=b=function(e){function t(e,t,n){this.body=t,null==n&&(n={}),this.condition="unless"===n.type?e.invert():e,this.elseBody=null,this.isChain=!1,this.soak=n.soak}return kt(t,e),t.prototype.children=["condition","body","elseBody"],t.prototype.bodyNode=function(){var e;return null!=(e=this.body)?e.unwrap():void 0},t.prototype.elseBodyNode=function(){var e;return null!=(e=this.elseBody)?e.unwrap():void 0},t.prototype.addElse=function(e){return this.isChain?this.elseBodyNode().addElse(e):(this.isChain=e instanceof t,this.elseBody=this.ensureBlock(e),this.elseBody.updateLocationDataIfMissing(e.locationData)),this},t.prototype.isStatement=function(e){var t;return(null!=e?e.level:void 0)===L||this.bodyNode().isStatement(e)||(null!=(t=this.elseBodyNode())?t.isStatement(e):void 0)},t.prototype.jumps=function(e){var t;return this.body.jumps(e)||(null!=(t=this.elseBody)?t.jumps(e):void 0)},t.prototype.compileNode=function(e){return this.isStatement(e)?this.compileStatement(e):this.compileExpression(e)},t.prototype.makeReturn=function(e){return e&&(this.elseBody||(this.elseBody=new s([new x("void 0")]))),this.body&&(this.body=new s([this.body.makeReturn(e)])),this.elseBody&&(this.elseBody=new s([this.elseBody.makeReturn(e)])),this},t.prototype.ensureBlock=function(e){return e instanceof s?e:new s([e])},t.prototype.compileStatement=function(e){var n,i,r,s,o,a,c;return r=tt(e,"chainChild"),(o=tt(e,"isExistentialEquals"))?new t(this.condition.invert(),this.elseBodyNode(),{type:"if"}).compileToFragments(e):(c=e.indent+q,s=this.condition.compileToFragments(e,N),i=this.ensureBlock(this.body).compileToFragments(lt(e,{indent:c})),a=[].concat(this.makeCode("if ("),s,this.makeCode(") {\n"),i,this.makeCode("\n"+this.tab+"}")),r||a.unshift(this.makeCode(this.tab)),this.elseBody?(n=a.concat(this.makeCode(" else ")),this.isChain?(e.chainChild=!0,n=n.concat(this.elseBody.unwrap().compileToFragments(e,L))):n=n.concat(this.makeCode("{\n"),this.elseBody.compileToFragments(lt(e,{indent:c}),L),this.makeCode("\n"+this.tab+"}")),n):a)},t.prototype.compileExpression=function(e){var t,n,i,r;return i=this.condition.compileToFragments(e,C),n=this.bodyNode().compileToFragments(e,E),t=this.elseBodyNode()?this.elseBodyNode().compileToFragments(e,E):[this.makeCode("void 0")],r=i.concat(this.makeCode(" ? "),n,this.makeCode(" : "),t),e.level>=C?this.wrapInBraces(r):r},t.prototype.unfoldSoak=function(){return this.soak&&this},t}(r),K={extend:function(e){return"function(child, parent) { for (var key in parent) { if ("+bt("hasProp",e)+".call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }"},bind:function(){return"function(fn, me){ return function(){ return fn.apply(me, arguments); }; }"},indexOf:function(){return"[].indexOf || function(item) { for (var i = 0, l = this.length; i < l; i++) { if (i in this && this[i] === item) return i; } return -1; }"},modulo:function(){return"function(a, b) { return (+a % (b = +b) + b) % b; }"},hasProp:function(){return"{}.hasOwnProperty"},slice:function(){return"[].slice"}},L=1,N=2,E=3,C=4,F=5,T=6,q=" ",g=/^(?!\d)[$\w\x7f-\uffff]+$/,B=/^[+-]?\d+$/,m=/^[+-]?0x[\da-f]+/i,R=/^[+-]?(?:0x[\da-f]+|\d*\.?\d+(?:e[+-]?\d+)?)$/i,y=/^['"]/,v=/^\//,bt=function(e,t){var n,i;return i=t.scope.root,e in i.utilities?i.utilities[e]:(n=i.freeVariable(e),i.assign(n,K[e](t)),i.utilities[e]=n)},ut=function(e,t){return e=e.replace(/\n/g,"$&"+t),e.replace(/\s+$/,"")},pt=function(e){return null==e?0:e.match(m)?parseInt(e,16):parseFloat(e)},at=function(e){return e instanceof x&&"arguments"===e.value&&!e.asKey},ct=function(e){return e instanceof x&&"this"===e.value&&!e.asKey||e instanceof c&&e.bound||e instanceof o&&e.isSuper},ot=function(e){return e.isComplex()||("function"==typeof e.isAssignable?e.isAssignable():void 0)},yt=function(e,t,n){var i;if(i=t[n].unfoldSoak(e))return t[n]=i.body,i.body=new z(t),i}}.call(this),t.exports}(),_dereq_["./sourcemap"]=function(){var e={},t={exports:e};return function(){var e,n;e=function(){function e(e){this.line=e,this.columns=[]}return e.prototype.add=function(e,t,n){var i,r;return r=t[0],i=t[1],null==n&&(n={}),this.columns[e]&&n.noReplace?void 0:this.columns[e]={line:this.line,column:e,sourceLine:r,sourceColumn:i}},e.prototype.sourceLocation=function(e){for(var t;!((t=this.columns[e])||0>=e);)e--;return t&&[t.sourceLine,t.sourceColumn]},e}(),n=function(){function t(){this.lines=[]}var n,i,r,s;return t.prototype.add=function(t,n,i){var r,s,o,a;return null==i&&(i={}),o=n[0],s=n[1],a=(r=this.lines)[o]||(r[o]=new e(o)),a.add(s,t,i)},t.prototype.sourceLocation=function(e){var t,n,i;for(n=e[0],t=e[1];!((i=this.lines[n])||0>=n);)n--;return i&&i.sourceLocation(t)},t.prototype.generate=function(e,t){var n,i,r,s,o,a,c,h,l,u,p,d,f,m,g,v;for(null==e&&(e={}),null==t&&(t=null),v=0,s=0,a=0,o=0,d=!1,n="",f=this.lines,u=i=0,c=f.length;c>i;u=++i)if(l=f[u])for(m=l.columns,r=0,h=m.length;h>r;r++)if(p=m[r]){for(;p.line>v;)s=0,d=!1,n+=";",v++;d&&(n+=",",d=!1),n+=this.encodeVlq(p.column-s),s=p.column,n+=this.encodeVlq(0),n+=this.encodeVlq(p.sourceLine-a),a=p.sourceLine,n+=this.encodeVlq(p.sourceColumn-o),o=p.sourceColumn,d=!0}return g={version:3,file:e.generatedFile||"",sourceRoot:e.sourceRoot||"",sources:e.sourceFiles||[""],names:[],mappings:n},e.inline&&(g.sourcesContent=[t]),JSON.stringify(g,null,2)},r=5,i=1<<r,s=i-1,t.prototype.encodeVlq=function(e){var t,n,o,a;for(t="",o=0>e?1:0,a=(Math.abs(e)<<1)+o;a||!t;)n=a&s,a>>=r,a&&(n|=i),t+=this.encodeBase64(n);return t},n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t.prototype.encodeBase64=function(e){return n[e]||function(){throw Error("Cannot Base64 encode value: "+e)}()},t}(),t.exports=n}.call(this),t.exports}(),_dereq_["./coffee-script"]=function(){var e={},t={exports:e};return function(){var t,n,i,r,s,o,a,c,h,l,u,p,d,f,m,g,v,y,b={}.hasOwnProperty,k=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(t in this&&this[t]===e)return t;return-1};if(a=_dereq_("fs"),v=_dereq_("vm"),f=_dereq_("path"),t=_dereq_("./lexer").Lexer,d=_dereq_("./parser").parser,h=_dereq_("./helpers"),n=_dereq_("./sourcemap"),e.VERSION="1.9.3",e.FILE_EXTENSIONS=[".coffee",".litcoffee",".coffee.md"],e.helpers=h,y=function(e){return function(t,n){var i;null==n&&(n={});try{return e.call(this,t,n)
+}catch(r){if(i=r,"string"!=typeof t)throw i;throw h.updateSyntaxError(i,t,n.filename)}}},e.compile=r=y(function(e,t){var i,r,s,o,a,c,l,u,f,m,g,v,y,b,k;for(v=h.merge,o=h.extend,t=o({},t),t.sourceMap&&(g=new n),k=p.tokenize(e,t),t.referencedVars=function(){var e,t,n;for(n=[],e=0,t=k.length;t>e;e++)b=k[e],b.variable&&n.push(b[1]);return n}(),c=d.parse(k).compileToFragments(t),s=0,t.header&&(s+=1),t.shiftLine&&(s+=1),r=0,f="",u=0,m=c.length;m>u;u++)a=c[u],t.sourceMap&&(a.locationData&&!/^[;\s]*$/.test(a.code)&&g.add([a.locationData.first_line,a.locationData.first_column],[s,r],{noReplace:!0}),y=h.count(a.code,"\n"),s+=y,y?r=a.code.length-(a.code.lastIndexOf("\n")+1):r+=a.code.length),f+=a.code;return t.header&&(l="Generated by CoffeeScript "+this.VERSION,f="// "+l+"\n"+f),t.sourceMap?(i={js:f},i.sourceMap=g,i.v3SourceMap=g.generate(t,e),i):f}),e.tokens=y(function(e,t){return p.tokenize(e,t)}),e.nodes=y(function(e,t){return"string"==typeof e?d.parse(p.tokenize(e,t)):d.parse(e)}),e.run=function(e,t){var n,i,s,o;return null==t&&(t={}),s=_dereq_.main,s.filename=process.argv[1]=t.filename?a.realpathSync(t.filename):".",s.moduleCache&&(s.moduleCache={}),i=t.filename?f.dirname(a.realpathSync(t.filename)):a.realpathSync("."),s.paths=_dereq_("module")._nodeModulePaths(i),(!h.isCoffee(s.filename)||_dereq_.extensions)&&(n=r(e,t),e=null!=(o=n.js)?o:n),s._compile(e,s.filename)},e.eval=function(e,t){var n,i,s,o,a,c,h,l,u,p,d,m,g,y,k,w,T;if(null==t&&(t={}),e=e.trim()){if(o=null!=(m=v.Script.createContext)?m:v.createContext,c=null!=(g=v.isContext)?g:function(){return t.sandbox instanceof o().constructor},o){if(null!=t.sandbox){if(c(t.sandbox))w=t.sandbox;else{w=o(),y=t.sandbox;for(l in y)b.call(y,l)&&(T=y[l],w[l]=T)}w.global=w.root=w.GLOBAL=w}else w=global;if(w.__filename=t.filename||"eval",w.__dirname=f.dirname(w.__filename),w===global&&!w.module&&!w.require){for(n=_dereq_("module"),w.module=i=new n(t.modulename||"eval"),w.require=s=function(e){return n._load(e,i,!0)},i.filename=w.__filename,k=Object.getOwnPropertyNames(_dereq_),a=0,u=k.length;u>a;a++)d=k[a],"paths"!==d&&(s[d]=_dereq_[d]);s.paths=i.paths=n._nodeModulePaths(process.cwd()),s.resolve=function(e){return n._resolveFilename(e,i)}}}p={};for(l in t)b.call(t,l)&&(T=t[l],p[l]=T);return p.bare=!0,h=r(e,p),w===global?v.runInThisContext(h):v.runInContext(h,w)}},e.register=function(){return _dereq_("./register")},_dereq_.extensions)for(m=this.FILE_EXTENSIONS,l=0,u=m.length;u>l;l++)s=m[l],null==(i=_dereq_.extensions)[s]&&(i[s]=function(){throw Error("Use CoffeeScript.register() or require the coffee-script/register module to require "+s+" files.")});e._compileFile=function(e,t){var n,i,s,o;null==t&&(t=!1),s=a.readFileSync(e,"utf8"),o=65279===s.charCodeAt(0)?s.substring(1):s;try{n=r(o,{filename:e,sourceMap:t,literate:h.isLiterate(e)})}catch(c){throw i=c,h.updateSyntaxError(i,o,e)}return n},p=new t,d.lexer={lex:function(){var e,t;return t=d.tokens[this.pos++],t?(e=t[0],this.yytext=t[1],this.yylloc=t[2],d.errorToken=t.origin||t,this.yylineno=this.yylloc.first_line):e="",e},setInput:function(e){return d.tokens=e,this.pos=0},upcomingInput:function(){return""}},d.yy=_dereq_("./nodes"),d.yy.parseError=function(e,t){var n,i,r,s,o,a;return o=t.token,s=d.errorToken,a=d.tokens,i=s[0],r=s[1],n=s[2],r=function(){switch(!1){case s!==a[a.length-1]:return"end of input";case"INDENT"!==i&&"OUTDENT"!==i:return"indentation";case"IDENTIFIER"!==i&&"NUMBER"!==i&&"STRING"!==i&&"STRING_START"!==i&&"REGEX"!==i&&"REGEX_START"!==i:return i.replace(/_START$/,"").toLowerCase();default:return h.nameWhitespaceCharacter(r)}}(),h.throwSyntaxError("unexpected "+r,n)},o=function(e,t){var n,i,r,s,o,a,c,h,l,u,p,d;return s=void 0,r="",e.isNative()?r="native":(e.isEval()?(s=e.getScriptNameOrSourceURL(),s||(r=e.getEvalOrigin()+", ")):s=e.getFileName(),s||(s="<anonymous>"),h=e.getLineNumber(),i=e.getColumnNumber(),u=t(s,h,i),r=u?s+":"+u[0]+":"+u[1]:s+":"+h+":"+i),o=e.getFunctionName(),a=e.isConstructor(),c=!(e.isToplevel()||a),c?(l=e.getMethodName(),d=e.getTypeName(),o?(p=n="",d&&o.indexOf(d)&&(p=d+"."),l&&o.indexOf("."+l)!==o.length-l.length-1&&(n=" [as "+l+"]"),""+p+o+n+" ("+r+")"):d+"."+(l||"<anonymous>")+" ("+r+")"):a?"new "+(o||"<anonymous>")+" ("+r+")":o?o+" ("+r+")":r},g={},c=function(t){var n,i;if(g[t])return g[t];if(i=null!=f?f.extname(t):void 0,!(0>k.call(e.FILE_EXTENSIONS,i)))return n=e._compileFile(t,!0),g[t]=n.sourceMap},Error.prepareStackTrace=function(t,n){var i,r,s;return s=function(e,t,n){var i,r;return r=c(e),r&&(i=r.sourceLocation([t-1,n-1])),i?[i[0]+1,i[1]+1]:null},r=function(){var t,r,a;for(a=[],t=0,r=n.length;r>t&&(i=n[t],i.getFunction()!==e.run);t++)a.push(" at "+o(i,s));return a}(),""+t+"\n"+r.join("\n")+"\n"}}.call(this),t.exports}(),_dereq_["./browser"]=function(){var exports={},module={exports:exports};return function(){var CoffeeScript,compile,runScripts,indexOf=[].indexOf||function(e){for(var t=0,n=this.length;n>t;t++)if(t in this&&this[t]===e)return t;return-1};CoffeeScript=_dereq_("./coffee-script"),CoffeeScript.require=_dereq_,compile=CoffeeScript.compile,CoffeeScript.eval=function(code,options){return null==options&&(options={}),null==options.bare&&(options.bare=!0),eval(compile(code,options))},CoffeeScript.run=function(e,t){return null==t&&(t={}),t.bare=!0,t.shiftLine=!0,Function(compile(e,t))()},"undefined"!=typeof window&&null!==window&&("undefined"!=typeof btoa&&null!==btoa&&"undefined"!=typeof JSON&&null!==JSON&&"undefined"!=typeof unescape&&null!==unescape&&"undefined"!=typeof encodeURIComponent&&null!==encodeURIComponent&&(compile=function(e,t){var n,i,r;return null==t&&(t={}),t.sourceMap=!0,t.inline=!0,i=CoffeeScript.compile(e,t),n=i.js,r=i.v3SourceMap,n+"\n//# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(r)))+"\n//# sourceURL=coffeescript"}),CoffeeScript.load=function(e,t,n,i){var r;return null==n&&(n={}),null==i&&(i=!1),n.sourceFiles=[e],r=window.ActiveXObject?new window.ActiveXObject("Microsoft.XMLHTTP"):new window.XMLHttpRequest,r.open("GET",e,!0),"overrideMimeType"in r&&r.overrideMimeType("text/plain"),r.onreadystatechange=function(){var s,o;if(4===r.readyState){if(0!==(o=r.status)&&200!==o)throw Error("Could not load "+e);if(s=[r.responseText,n],i||CoffeeScript.run.apply(CoffeeScript,s),t)return t(s)}},r.send(null)},runScripts=function(){var e,t,n,i,r,s,o,a,c,h,l;for(l=window.document.getElementsByTagName("script"),t=["text/coffeescript","text/literate-coffeescript"],e=function(){var e,n,i,r;for(r=[],e=0,n=l.length;n>e;e++)c=l[e],i=c.type,indexOf.call(t,i)>=0&&r.push(c);return r}(),s=0,n=function(){var t;return t=e[s],t instanceof Array?(CoffeeScript.run.apply(CoffeeScript,t),s++,n()):void 0},i=function(i,r){var s,o;return s={literate:i.type===t[1]},o=i.src||i.getAttribute("data-src"),o?CoffeeScript.load(o,function(t){return e[r]=t,n()},s,!0):(s.sourceFiles=["embedded"],e[r]=[i.innerHTML,s])},r=o=0,a=e.length;a>o;r=++o)h=e[r],i(h,r);return n()},window.addEventListener?window.addEventListener("DOMContentLoaded",runScripts,!1):window.attachEvent("onload",runScripts))}.call(this),module.exports}(),_dereq_["./coffee-script"]}();"function"==typeof define&&define.amd?define(function(){return CoffeeScript}):root.CoffeeScript=CoffeeScript})(this);
+});
+
+ace.define("ace/mode/coffee_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/coffee/coffee"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var Mirror = require("../worker/mirror").Mirror;
+var coffee = require("../mode/coffee/coffee");
+
+window.addEventListener = function() {};
+
+
+var Worker = exports.Worker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(250);
+};
+
+oop.inherits(Worker, Mirror);
+
+(function() {
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ var errors = [];
+ try {
+ coffee.compile(value);
+ } catch(e) {
+ var loc = e.location;
+ if (loc) {
+ errors.push({
+ row: loc.first_line,
+ column: loc.first_column,
+ endRow: loc.last_line,
+ endColumn: loc.last_column,
+ text: e.message,
+ type: "error"
+ });
+ }
+ }
+ this.sender.emit("annotate", errors);
+ };
+
+}).call(Worker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-css.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-css.js
new file mode 100644
index 00000000..a9da31d3
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-css.js
@@ -0,0 +1,8761 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/css/csslint",["require","exports","module"], function(require, exports, module) {
+var parserlib = {};
+(function(){
+function EventTarget(){
+ this._listeners = {};
+}
+
+EventTarget.prototype = {
+ constructor: EventTarget,
+ addListener: function(type, listener){
+ if (!this._listeners[type]){
+ this._listeners[type] = [];
+ }
+
+ this._listeners[type].push(listener);
+ },
+ fire: function(event){
+ if (typeof event == "string"){
+ event = { type: event };
+ }
+ if (typeof event.target != "undefined"){
+ event.target = this;
+ }
+
+ if (typeof event.type == "undefined"){
+ throw new Error("Event object missing 'type' property.");
+ }
+
+ if (this._listeners[event.type]){
+ var listeners = this._listeners[event.type].concat();
+ for (var i=0, len=listeners.length; i < len; i++){
+ listeners[i].call(this, event);
+ }
+ }
+ },
+ removeListener: function(type, listener){
+ if (this._listeners[type]){
+ var listeners = this._listeners[type];
+ for (var i=0, len=listeners.length; i < len; i++){
+ if (listeners[i] === listener){
+ listeners.splice(i, 1);
+ break;
+ }
+ }
+
+
+ }
+ }
+};
+function StringReader(text){
+ this._input = text.replace(/\n\r?/g, "\n");
+ this._line = 1;
+ this._col = 1;
+ this._cursor = 0;
+}
+
+StringReader.prototype = {
+ constructor: StringReader,
+ getCol: function(){
+ return this._col;
+ },
+ getLine: function(){
+ return this._line ;
+ },
+ eof: function(){
+ return (this._cursor == this._input.length);
+ },
+ peek: function(count){
+ var c = null;
+ count = (typeof count == "undefined" ? 1 : count);
+ if (this._cursor < this._input.length){
+ c = this._input.charAt(this._cursor + count - 1);
+ }
+
+ return c;
+ },
+ read: function(){
+ var c = null;
+ if (this._cursor < this._input.length){
+ if (this._input.charAt(this._cursor) == "\n"){
+ this._line++;
+ this._col=1;
+ } else {
+ this._col++;
+ }
+ c = this._input.charAt(this._cursor++);
+ }
+
+ return c;
+ },
+ mark: function(){
+ this._bookmark = {
+ cursor: this._cursor,
+ line: this._line,
+ col: this._col
+ };
+ },
+
+ reset: function(){
+ if (this._bookmark){
+ this._cursor = this._bookmark.cursor;
+ this._line = this._bookmark.line;
+ this._col = this._bookmark.col;
+ delete this._bookmark;
+ }
+ },
+ readTo: function(pattern){
+
+ var buffer = "",
+ c;
+ while (buffer.length < pattern.length || buffer.lastIndexOf(pattern) != buffer.length - pattern.length){
+ c = this.read();
+ if (c){
+ buffer += c;
+ } else {
+ throw new Error("Expected \"" + pattern + "\" at line " + this._line + ", col " + this._col + ".");
+ }
+ }
+
+ return buffer;
+
+ },
+ readWhile: function(filter){
+
+ var buffer = "",
+ c = this.read();
+
+ while(c !== null && filter(c)){
+ buffer += c;
+ c = this.read();
+ }
+
+ return buffer;
+
+ },
+ readMatch: function(matcher){
+
+ var source = this._input.substring(this._cursor),
+ value = null;
+ if (typeof matcher == "string"){
+ if (source.indexOf(matcher) === 0){
+ value = this.readCount(matcher.length);
+ }
+ } else if (matcher instanceof RegExp){
+ if (matcher.test(source)){
+ value = this.readCount(RegExp.lastMatch.length);
+ }
+ }
+
+ return value;
+ },
+ readCount: function(count){
+ var buffer = "";
+
+ while(count--){
+ buffer += this.read();
+ }
+
+ return buffer;
+ }
+
+};
+function SyntaxError(message, line, col){
+ this.col = col;
+ this.line = line;
+ this.message = message;
+
+}
+SyntaxError.prototype = new Error();
+function SyntaxUnit(text, line, col, type){
+ this.col = col;
+ this.line = line;
+ this.text = text;
+ this.type = type;
+}
+SyntaxUnit.fromToken = function(token){
+ return new SyntaxUnit(token.value, token.startLine, token.startCol);
+};
+
+SyntaxUnit.prototype = {
+ constructor: SyntaxUnit,
+ valueOf: function(){
+ return this.text;
+ },
+ toString: function(){
+ return this.text;
+ }
+
+};
+function TokenStreamBase(input, tokenData){
+ this._reader = input ? new StringReader(input.toString()) : null;
+ this._token = null;
+ this._tokenData = tokenData;
+ this._lt = [];
+ this._ltIndex = 0;
+
+ this._ltIndexCache = [];
+}
+TokenStreamBase.createTokenData = function(tokens){
+
+ var nameMap = [],
+ typeMap = {},
+ tokenData = tokens.concat([]),
+ i = 0,
+ len = tokenData.length+1;
+
+ tokenData.UNKNOWN = -1;
+ tokenData.unshift({name:"EOF"});
+
+ for (; i < len; i++){
+ nameMap.push(tokenData[i].name);
+ tokenData[tokenData[i].name] = i;
+ if (tokenData[i].text){
+ typeMap[tokenData[i].text] = i;
+ }
+ }
+
+ tokenData.name = function(tt){
+ return nameMap[tt];
+ };
+
+ tokenData.type = function(c){
+ return typeMap[c];
+ };
+
+ return tokenData;
+};
+
+TokenStreamBase.prototype = {
+ constructor: TokenStreamBase,
+ match: function(tokenTypes, channel){
+ if (!(tokenTypes instanceof Array)){
+ tokenTypes = [tokenTypes];
+ }
+
+ var tt = this.get(channel),
+ i = 0,
+ len = tokenTypes.length;
+
+ while(i < len){
+ if (tt == tokenTypes[i++]){
+ return true;
+ }
+ }
+ this.unget();
+ return false;
+ },
+ mustMatch: function(tokenTypes, channel){
+
+ var token;
+ if (!(tokenTypes instanceof Array)){
+ tokenTypes = [tokenTypes];
+ }
+
+ if (!this.match.apply(this, arguments)){
+ token = this.LT(1);
+ throw new SyntaxError("Expected " + this._tokenData[tokenTypes[0]].name +
+ " at line " + token.startLine + ", col " + token.startCol + ".", token.startLine, token.startCol);
+ }
+ },
+ advance: function(tokenTypes, channel){
+
+ while(this.LA(0) !== 0 && !this.match(tokenTypes, channel)){
+ this.get();
+ }
+
+ return this.LA(0);
+ },
+ get: function(channel){
+
+ var tokenInfo = this._tokenData,
+ reader = this._reader,
+ value,
+ i =0,
+ len = tokenInfo.length,
+ found = false,
+ token,
+ info;
+ if (this._lt.length && this._ltIndex >= 0 && this._ltIndex < this._lt.length){
+
+ i++;
+ this._token = this._lt[this._ltIndex++];
+ info = tokenInfo[this._token.type];
+ while((info.channel !== undefined && channel !== info.channel) &&
+ this._ltIndex < this._lt.length){
+ this._token = this._lt[this._ltIndex++];
+ info = tokenInfo[this._token.type];
+ i++;
+ }
+ if ((info.channel === undefined || channel === info.channel) &&
+ this._ltIndex <= this._lt.length){
+ this._ltIndexCache.push(i);
+ return this._token.type;
+ }
+ }
+ token = this._getToken();
+ if (token.type > -1 && !tokenInfo[token.type].hide){
+ token.channel = tokenInfo[token.type].channel;
+ this._token = token;
+ this._lt.push(token);
+ this._ltIndexCache.push(this._lt.length - this._ltIndex + i);
+ if (this._lt.length > 5){
+ this._lt.shift();
+ }
+ if (this._ltIndexCache.length > 5){
+ this._ltIndexCache.shift();
+ }
+ this._ltIndex = this._lt.length;
+ }
+ info = tokenInfo[token.type];
+ if (info &&
+ (info.hide ||
+ (info.channel !== undefined && channel !== info.channel))){
+ return this.get(channel);
+ } else {
+ return token.type;
+ }
+ },
+ LA: function(index){
+ var total = index,
+ tt;
+ if (index > 0){
+ if (index > 5){
+ throw new Error("Too much lookahead.");
+ }
+ while(total){
+ tt = this.get();
+ total--;
+ }
+ while(total < index){
+ this.unget();
+ total++;
+ }
+ } else if (index < 0){
+
+ if(this._lt[this._ltIndex+index]){
+ tt = this._lt[this._ltIndex+index].type;
+ } else {
+ throw new Error("Too much lookbehind.");
+ }
+
+ } else {
+ tt = this._token.type;
+ }
+
+ return tt;
+
+ },
+ LT: function(index){
+ this.LA(index);
+ return this._lt[this._ltIndex+index-1];
+ },
+ peek: function(){
+ return this.LA(1);
+ },
+ token: function(){
+ return this._token;
+ },
+ tokenName: function(tokenType){
+ if (tokenType < 0 || tokenType > this._tokenData.length){
+ return "UNKNOWN_TOKEN";
+ } else {
+ return this._tokenData[tokenType].name;
+ }
+ },
+ tokenType: function(tokenName){
+ return this._tokenData[tokenName] || -1;
+ },
+ unget: function(){
+ if (this._ltIndexCache.length){
+ this._ltIndex -= this._ltIndexCache.pop();//--;
+ this._token = this._lt[this._ltIndex - 1];
+ } else {
+ throw new Error("Too much lookahead.");
+ }
+ }
+
+};
+
+
+parserlib.util = {
+StringReader: StringReader,
+SyntaxError : SyntaxError,
+SyntaxUnit : SyntaxUnit,
+EventTarget : EventTarget,
+TokenStreamBase : TokenStreamBase
+};
+})();
+(function(){
+var EventTarget = parserlib.util.EventTarget,
+TokenStreamBase = parserlib.util.TokenStreamBase,
+StringReader = parserlib.util.StringReader,
+SyntaxError = parserlib.util.SyntaxError,
+SyntaxUnit = parserlib.util.SyntaxUnit;
+
+var Colors = {
+ aliceblue :"#f0f8ff",
+ antiquewhite :"#faebd7",
+ aqua :"#00ffff",
+ aquamarine :"#7fffd4",
+ azure :"#f0ffff",
+ beige :"#f5f5dc",
+ bisque :"#ffe4c4",
+ black :"#000000",
+ blanchedalmond :"#ffebcd",
+ blue :"#0000ff",
+ blueviolet :"#8a2be2",
+ brown :"#a52a2a",
+ burlywood :"#deb887",
+ cadetblue :"#5f9ea0",
+ chartreuse :"#7fff00",
+ chocolate :"#d2691e",
+ coral :"#ff7f50",
+ cornflowerblue :"#6495ed",
+ cornsilk :"#fff8dc",
+ crimson :"#dc143c",
+ cyan :"#00ffff",
+ darkblue :"#00008b",
+ darkcyan :"#008b8b",
+ darkgoldenrod :"#b8860b",
+ darkgray :"#a9a9a9",
+ darkgrey :"#a9a9a9",
+ darkgreen :"#006400",
+ darkkhaki :"#bdb76b",
+ darkmagenta :"#8b008b",
+ darkolivegreen :"#556b2f",
+ darkorange :"#ff8c00",
+ darkorchid :"#9932cc",
+ darkred :"#8b0000",
+ darksalmon :"#e9967a",
+ darkseagreen :"#8fbc8f",
+ darkslateblue :"#483d8b",
+ darkslategray :"#2f4f4f",
+ darkslategrey :"#2f4f4f",
+ darkturquoise :"#00ced1",
+ darkviolet :"#9400d3",
+ deeppink :"#ff1493",
+ deepskyblue :"#00bfff",
+ dimgray :"#696969",
+ dimgrey :"#696969",
+ dodgerblue :"#1e90ff",
+ firebrick :"#b22222",
+ floralwhite :"#fffaf0",
+ forestgreen :"#228b22",
+ fuchsia :"#ff00ff",
+ gainsboro :"#dcdcdc",
+ ghostwhite :"#f8f8ff",
+ gold :"#ffd700",
+ goldenrod :"#daa520",
+ gray :"#808080",
+ grey :"#808080",
+ green :"#008000",
+ greenyellow :"#adff2f",
+ honeydew :"#f0fff0",
+ hotpink :"#ff69b4",
+ indianred :"#cd5c5c",
+ indigo :"#4b0082",
+ ivory :"#fffff0",
+ khaki :"#f0e68c",
+ lavender :"#e6e6fa",
+ lavenderblush :"#fff0f5",
+ lawngreen :"#7cfc00",
+ lemonchiffon :"#fffacd",
+ lightblue :"#add8e6",
+ lightcoral :"#f08080",
+ lightcyan :"#e0ffff",
+ lightgoldenrodyellow :"#fafad2",
+ lightgray :"#d3d3d3",
+ lightgrey :"#d3d3d3",
+ lightgreen :"#90ee90",
+ lightpink :"#ffb6c1",
+ lightsalmon :"#ffa07a",
+ lightseagreen :"#20b2aa",
+ lightskyblue :"#87cefa",
+ lightslategray :"#778899",
+ lightslategrey :"#778899",
+ lightsteelblue :"#b0c4de",
+ lightyellow :"#ffffe0",
+ lime :"#00ff00",
+ limegreen :"#32cd32",
+ linen :"#faf0e6",
+ magenta :"#ff00ff",
+ maroon :"#800000",
+ mediumaquamarine:"#66cdaa",
+ mediumblue :"#0000cd",
+ mediumorchid :"#ba55d3",
+ mediumpurple :"#9370d8",
+ mediumseagreen :"#3cb371",
+ mediumslateblue :"#7b68ee",
+ mediumspringgreen :"#00fa9a",
+ mediumturquoise :"#48d1cc",
+ mediumvioletred :"#c71585",
+ midnightblue :"#191970",
+ mintcream :"#f5fffa",
+ mistyrose :"#ffe4e1",
+ moccasin :"#ffe4b5",
+ navajowhite :"#ffdead",
+ navy :"#000080",
+ oldlace :"#fdf5e6",
+ olive :"#808000",
+ olivedrab :"#6b8e23",
+ orange :"#ffa500",
+ orangered :"#ff4500",
+ orchid :"#da70d6",
+ palegoldenrod :"#eee8aa",
+ palegreen :"#98fb98",
+ paleturquoise :"#afeeee",
+ palevioletred :"#d87093",
+ papayawhip :"#ffefd5",
+ peachpuff :"#ffdab9",
+ peru :"#cd853f",
+ pink :"#ffc0cb",
+ plum :"#dda0dd",
+ powderblue :"#b0e0e6",
+ purple :"#800080",
+ red :"#ff0000",
+ rosybrown :"#bc8f8f",
+ royalblue :"#4169e1",
+ saddlebrown :"#8b4513",
+ salmon :"#fa8072",
+ sandybrown :"#f4a460",
+ seagreen :"#2e8b57",
+ seashell :"#fff5ee",
+ sienna :"#a0522d",
+ silver :"#c0c0c0",
+ skyblue :"#87ceeb",
+ slateblue :"#6a5acd",
+ slategray :"#708090",
+ slategrey :"#708090",
+ snow :"#fffafa",
+ springgreen :"#00ff7f",
+ steelblue :"#4682b4",
+ tan :"#d2b48c",
+ teal :"#008080",
+ thistle :"#d8bfd8",
+ tomato :"#ff6347",
+ turquoise :"#40e0d0",
+ violet :"#ee82ee",
+ wheat :"#f5deb3",
+ white :"#ffffff",
+ whitesmoke :"#f5f5f5",
+ yellow :"#ffff00",
+ yellowgreen :"#9acd32",
+ activeBorder :"Active window border.",
+ activecaption :"Active window caption.",
+ appworkspace :"Background color of multiple document interface.",
+ background :"Desktop background.",
+ buttonface :"The face background color for 3-D elements that appear 3-D due to one layer of surrounding border.",
+ buttonhighlight :"The color of the border facing the light source for 3-D elements that appear 3-D due to one layer of surrounding border.",
+ buttonshadow :"The color of the border away from the light source for 3-D elements that appear 3-D due to one layer of surrounding border.",
+ buttontext :"Text on push buttons.",
+ captiontext :"Text in caption, size box, and scrollbar arrow box.",
+ graytext :"Grayed (disabled) text. This color is set to #000 if the current display driver does not support a solid gray color.",
+ greytext :"Greyed (disabled) text. This color is set to #000 if the current display driver does not support a solid grey color.",
+ highlight :"Item(s) selected in a control.",
+ highlighttext :"Text of item(s) selected in a control.",
+ inactiveborder :"Inactive window border.",
+ inactivecaption :"Inactive window caption.",
+ inactivecaptiontext :"Color of text in an inactive caption.",
+ infobackground :"Background color for tooltip controls.",
+ infotext :"Text color for tooltip controls.",
+ menu :"Menu background.",
+ menutext :"Text in menus.",
+ scrollbar :"Scroll bar gray area.",
+ threeddarkshadow :"The color of the darker (generally outer) of the two borders away from the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",
+ threedface :"The face background color for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",
+ threedhighlight :"The color of the lighter (generally outer) of the two borders facing the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",
+ threedlightshadow :"The color of the darker (generally inner) of the two borders facing the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",
+ threedshadow :"The color of the lighter (generally inner) of the two borders away from the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",
+ window :"Window background.",
+ windowframe :"Window frame.",
+ windowtext :"Text in windows."
+};
+function Combinator(text, line, col){
+
+ SyntaxUnit.call(this, text, line, col, Parser.COMBINATOR_TYPE);
+ this.type = "unknown";
+ if (/^\s+$/.test(text)){
+ this.type = "descendant";
+ } else if (text == ">"){
+ this.type = "child";
+ } else if (text == "+"){
+ this.type = "adjacent-sibling";
+ } else if (text == "~"){
+ this.type = "sibling";
+ }
+
+}
+
+Combinator.prototype = new SyntaxUnit();
+Combinator.prototype.constructor = Combinator;
+function MediaFeature(name, value){
+
+ SyntaxUnit.call(this, "(" + name + (value !== null ? ":" + value : "") + ")", name.startLine, name.startCol, Parser.MEDIA_FEATURE_TYPE);
+ this.name = name;
+ this.value = value;
+}
+
+MediaFeature.prototype = new SyntaxUnit();
+MediaFeature.prototype.constructor = MediaFeature;
+function MediaQuery(modifier, mediaType, features, line, col){
+
+ SyntaxUnit.call(this, (modifier ? modifier + " ": "") + (mediaType ? mediaType : "") + (mediaType && features.length > 0 ? " and " : "") + features.join(" and "), line, col, Parser.MEDIA_QUERY_TYPE);
+ this.modifier = modifier;
+ this.mediaType = mediaType;
+ this.features = features;
+
+}
+
+MediaQuery.prototype = new SyntaxUnit();
+MediaQuery.prototype.constructor = MediaQuery;
+function Parser(options){
+ EventTarget.call(this);
+
+
+ this.options = options || {};
+
+ this._tokenStream = null;
+}
+Parser.DEFAULT_TYPE = 0;
+Parser.COMBINATOR_TYPE = 1;
+Parser.MEDIA_FEATURE_TYPE = 2;
+Parser.MEDIA_QUERY_TYPE = 3;
+Parser.PROPERTY_NAME_TYPE = 4;
+Parser.PROPERTY_VALUE_TYPE = 5;
+Parser.PROPERTY_VALUE_PART_TYPE = 6;
+Parser.SELECTOR_TYPE = 7;
+Parser.SELECTOR_PART_TYPE = 8;
+Parser.SELECTOR_SUB_PART_TYPE = 9;
+
+Parser.prototype = function(){
+
+ var proto = new EventTarget(), //new prototype
+ prop,
+ additions = {
+ constructor: Parser,
+ DEFAULT_TYPE : 0,
+ COMBINATOR_TYPE : 1,
+ MEDIA_FEATURE_TYPE : 2,
+ MEDIA_QUERY_TYPE : 3,
+ PROPERTY_NAME_TYPE : 4,
+ PROPERTY_VALUE_TYPE : 5,
+ PROPERTY_VALUE_PART_TYPE : 6,
+ SELECTOR_TYPE : 7,
+ SELECTOR_PART_TYPE : 8,
+ SELECTOR_SUB_PART_TYPE : 9,
+
+ _stylesheet: function(){
+
+ var tokenStream = this._tokenStream,
+ charset = null,
+ count,
+ token,
+ tt;
+
+ this.fire("startstylesheet");
+ this._charset();
+
+ this._skipCruft();
+ while (tokenStream.peek() == Tokens.IMPORT_SYM){
+ this._import();
+ this._skipCruft();
+ }
+ while (tokenStream.peek() == Tokens.NAMESPACE_SYM){
+ this._namespace();
+ this._skipCruft();
+ }
+ tt = tokenStream.peek();
+ while(tt > Tokens.EOF){
+
+ try {
+
+ switch(tt){
+ case Tokens.MEDIA_SYM:
+ this._media();
+ this._skipCruft();
+ break;
+ case Tokens.PAGE_SYM:
+ this._page();
+ this._skipCruft();
+ break;
+ case Tokens.FONT_FACE_SYM:
+ this._font_face();
+ this._skipCruft();
+ break;
+ case Tokens.KEYFRAMES_SYM:
+ this._keyframes();
+ this._skipCruft();
+ break;
+ case Tokens.VIEWPORT_SYM:
+ this._viewport();
+ this._skipCruft();
+ break;
+ case Tokens.UNKNOWN_SYM: //unknown @ rule
+ tokenStream.get();
+ if (!this.options.strict){
+ this.fire({
+ type: "error",
+ error: null,
+ message: "Unknown @ rule: " + tokenStream.LT(0).value + ".",
+ line: tokenStream.LT(0).startLine,
+ col: tokenStream.LT(0).startCol
+ });
+ count=0;
+ while (tokenStream.advance([Tokens.LBRACE, Tokens.RBRACE]) == Tokens.LBRACE){
+ count++; //keep track of nesting depth
+ }
+
+ while(count){
+ tokenStream.advance([Tokens.RBRACE]);
+ count--;
+ }
+
+ } else {
+ throw new SyntaxError("Unknown @ rule.", tokenStream.LT(0).startLine, tokenStream.LT(0).startCol);
+ }
+ break;
+ case Tokens.S:
+ this._readWhitespace();
+ break;
+ default:
+ if(!this._ruleset()){
+ switch(tt){
+ case Tokens.CHARSET_SYM:
+ token = tokenStream.LT(1);
+ this._charset(false);
+ throw new SyntaxError("@charset not allowed here.", token.startLine, token.startCol);
+ case Tokens.IMPORT_SYM:
+ token = tokenStream.LT(1);
+ this._import(false);
+ throw new SyntaxError("@import not allowed here.", token.startLine, token.startCol);
+ case Tokens.NAMESPACE_SYM:
+ token = tokenStream.LT(1);
+ this._namespace(false);
+ throw new SyntaxError("@namespace not allowed here.", token.startLine, token.startCol);
+ default:
+ tokenStream.get(); //get the last token
+ this._unexpectedToken(tokenStream.token());
+ }
+
+ }
+ }
+ } catch(ex) {
+ if (ex instanceof SyntaxError && !this.options.strict){
+ this.fire({
+ type: "error",
+ error: ex,
+ message: ex.message,
+ line: ex.line,
+ col: ex.col
+ });
+ } else {
+ throw ex;
+ }
+ }
+
+ tt = tokenStream.peek();
+ }
+
+ if (tt != Tokens.EOF){
+ this._unexpectedToken(tokenStream.token());
+ }
+
+ this.fire("endstylesheet");
+ },
+
+ _charset: function(emit){
+ var tokenStream = this._tokenStream,
+ charset,
+ token,
+ line,
+ col;
+
+ if (tokenStream.match(Tokens.CHARSET_SYM)){
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+
+ this._readWhitespace();
+ tokenStream.mustMatch(Tokens.STRING);
+
+ token = tokenStream.token();
+ charset = token.value;
+
+ this._readWhitespace();
+ tokenStream.mustMatch(Tokens.SEMICOLON);
+
+ if (emit !== false){
+ this.fire({
+ type: "charset",
+ charset:charset,
+ line: line,
+ col: col
+ });
+ }
+ }
+ },
+
+ _import: function(emit){
+
+ var tokenStream = this._tokenStream,
+ tt,
+ uri,
+ importToken,
+ mediaList = [];
+ tokenStream.mustMatch(Tokens.IMPORT_SYM);
+ importToken = tokenStream.token();
+ this._readWhitespace();
+
+ tokenStream.mustMatch([Tokens.STRING, Tokens.URI]);
+ uri = tokenStream.token().value.replace(/^(?:url\()?["']?([^"']+?)["']?\)?$/, "$1");
+
+ this._readWhitespace();
+
+ mediaList = this._media_query_list();
+ tokenStream.mustMatch(Tokens.SEMICOLON);
+ this._readWhitespace();
+
+ if (emit !== false){
+ this.fire({
+ type: "import",
+ uri: uri,
+ media: mediaList,
+ line: importToken.startLine,
+ col: importToken.startCol
+ });
+ }
+
+ },
+
+ _namespace: function(emit){
+
+ var tokenStream = this._tokenStream,
+ line,
+ col,
+ prefix,
+ uri;
+ tokenStream.mustMatch(Tokens.NAMESPACE_SYM);
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+ this._readWhitespace();
+ if (tokenStream.match(Tokens.IDENT)){
+ prefix = tokenStream.token().value;
+ this._readWhitespace();
+ }
+
+ tokenStream.mustMatch([Tokens.STRING, Tokens.URI]);
+ uri = tokenStream.token().value.replace(/(?:url\()?["']([^"']+)["']\)?/, "$1");
+
+ this._readWhitespace();
+ tokenStream.mustMatch(Tokens.SEMICOLON);
+ this._readWhitespace();
+
+ if (emit !== false){
+ this.fire({
+ type: "namespace",
+ prefix: prefix,
+ uri: uri,
+ line: line,
+ col: col
+ });
+ }
+
+ },
+
+ _media: function(){
+ var tokenStream = this._tokenStream,
+ line,
+ col,
+ mediaList;// = [];
+ tokenStream.mustMatch(Tokens.MEDIA_SYM);
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+
+ this._readWhitespace();
+
+ mediaList = this._media_query_list();
+
+ tokenStream.mustMatch(Tokens.LBRACE);
+ this._readWhitespace();
+
+ this.fire({
+ type: "startmedia",
+ media: mediaList,
+ line: line,
+ col: col
+ });
+
+ while(true) {
+ if (tokenStream.peek() == Tokens.PAGE_SYM){
+ this._page();
+ } else if (tokenStream.peek() == Tokens.FONT_FACE_SYM){
+ this._font_face();
+ } else if (tokenStream.peek() == Tokens.VIEWPORT_SYM){
+ this._viewport();
+ } else if (!this._ruleset()){
+ break;
+ }
+ }
+
+ tokenStream.mustMatch(Tokens.RBRACE);
+ this._readWhitespace();
+
+ this.fire({
+ type: "endmedia",
+ media: mediaList,
+ line: line,
+ col: col
+ });
+ },
+ _media_query_list: function(){
+ var tokenStream = this._tokenStream,
+ mediaList = [];
+
+
+ this._readWhitespace();
+
+ if (tokenStream.peek() == Tokens.IDENT || tokenStream.peek() == Tokens.LPAREN){
+ mediaList.push(this._media_query());
+ }
+
+ while(tokenStream.match(Tokens.COMMA)){
+ this._readWhitespace();
+ mediaList.push(this._media_query());
+ }
+
+ return mediaList;
+ },
+ _media_query: function(){
+ var tokenStream = this._tokenStream,
+ type = null,
+ ident = null,
+ token = null,
+ expressions = [];
+
+ if (tokenStream.match(Tokens.IDENT)){
+ ident = tokenStream.token().value.toLowerCase();
+ if (ident != "only" && ident != "not"){
+ tokenStream.unget();
+ ident = null;
+ } else {
+ token = tokenStream.token();
+ }
+ }
+
+ this._readWhitespace();
+
+ if (tokenStream.peek() == Tokens.IDENT){
+ type = this._media_type();
+ if (token === null){
+ token = tokenStream.token();
+ }
+ } else if (tokenStream.peek() == Tokens.LPAREN){
+ if (token === null){
+ token = tokenStream.LT(1);
+ }
+ expressions.push(this._media_expression());
+ }
+
+ if (type === null && expressions.length === 0){
+ return null;
+ } else {
+ this._readWhitespace();
+ while (tokenStream.match(Tokens.IDENT)){
+ if (tokenStream.token().value.toLowerCase() != "and"){
+ this._unexpectedToken(tokenStream.token());
+ }
+
+ this._readWhitespace();
+ expressions.push(this._media_expression());
+ }
+ }
+
+ return new MediaQuery(ident, type, expressions, token.startLine, token.startCol);
+ },
+ _media_type: function(){
+ return this._media_feature();
+ },
+ _media_expression: function(){
+ var tokenStream = this._tokenStream,
+ feature = null,
+ token,
+ expression = null;
+
+ tokenStream.mustMatch(Tokens.LPAREN);
+ this._readWhitespace();
+
+ feature = this._media_feature();
+ this._readWhitespace();
+
+ if (tokenStream.match(Tokens.COLON)){
+ this._readWhitespace();
+ token = tokenStream.LT(1);
+ expression = this._expression();
+ }
+
+ tokenStream.mustMatch(Tokens.RPAREN);
+ this._readWhitespace();
+
+ return new MediaFeature(feature, (expression ? new SyntaxUnit(expression, token.startLine, token.startCol) : null));
+ },
+ _media_feature: function(){
+ var tokenStream = this._tokenStream;
+
+ tokenStream.mustMatch(Tokens.IDENT);
+
+ return SyntaxUnit.fromToken(tokenStream.token());
+ },
+ _page: function(){
+ var tokenStream = this._tokenStream,
+ line,
+ col,
+ identifier = null,
+ pseudoPage = null;
+ tokenStream.mustMatch(Tokens.PAGE_SYM);
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+
+ this._readWhitespace();
+
+ if (tokenStream.match(Tokens.IDENT)){
+ identifier = tokenStream.token().value;
+ if (identifier.toLowerCase() === "auto"){
+ this._unexpectedToken(tokenStream.token());
+ }
+ }
+ if (tokenStream.peek() == Tokens.COLON){
+ pseudoPage = this._pseudo_page();
+ }
+
+ this._readWhitespace();
+
+ this.fire({
+ type: "startpage",
+ id: identifier,
+ pseudo: pseudoPage,
+ line: line,
+ col: col
+ });
+
+ this._readDeclarations(true, true);
+
+ this.fire({
+ type: "endpage",
+ id: identifier,
+ pseudo: pseudoPage,
+ line: line,
+ col: col
+ });
+
+ },
+ _margin: function(){
+ var tokenStream = this._tokenStream,
+ line,
+ col,
+ marginSym = this._margin_sym();
+
+ if (marginSym){
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+
+ this.fire({
+ type: "startpagemargin",
+ margin: marginSym,
+ line: line,
+ col: col
+ });
+
+ this._readDeclarations(true);
+
+ this.fire({
+ type: "endpagemargin",
+ margin: marginSym,
+ line: line,
+ col: col
+ });
+ return true;
+ } else {
+ return false;
+ }
+ },
+ _margin_sym: function(){
+
+ var tokenStream = this._tokenStream;
+
+ if(tokenStream.match([Tokens.TOPLEFTCORNER_SYM, Tokens.TOPLEFT_SYM,
+ Tokens.TOPCENTER_SYM, Tokens.TOPRIGHT_SYM, Tokens.TOPRIGHTCORNER_SYM,
+ Tokens.BOTTOMLEFTCORNER_SYM, Tokens.BOTTOMLEFT_SYM,
+ Tokens.BOTTOMCENTER_SYM, Tokens.BOTTOMRIGHT_SYM,
+ Tokens.BOTTOMRIGHTCORNER_SYM, Tokens.LEFTTOP_SYM,
+ Tokens.LEFTMIDDLE_SYM, Tokens.LEFTBOTTOM_SYM, Tokens.RIGHTTOP_SYM,
+ Tokens.RIGHTMIDDLE_SYM, Tokens.RIGHTBOTTOM_SYM]))
+ {
+ return SyntaxUnit.fromToken(tokenStream.token());
+ } else {
+ return null;
+ }
+
+ },
+
+ _pseudo_page: function(){
+
+ var tokenStream = this._tokenStream;
+
+ tokenStream.mustMatch(Tokens.COLON);
+ tokenStream.mustMatch(Tokens.IDENT);
+
+ return tokenStream.token().value;
+ },
+
+ _font_face: function(){
+ var tokenStream = this._tokenStream,
+ line,
+ col;
+ tokenStream.mustMatch(Tokens.FONT_FACE_SYM);
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+
+ this._readWhitespace();
+
+ this.fire({
+ type: "startfontface",
+ line: line,
+ col: col
+ });
+
+ this._readDeclarations(true);
+
+ this.fire({
+ type: "endfontface",
+ line: line,
+ col: col
+ });
+ },
+
+ _viewport: function(){
+ var tokenStream = this._tokenStream,
+ line,
+ col;
+
+ tokenStream.mustMatch(Tokens.VIEWPORT_SYM);
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+
+ this._readWhitespace();
+
+ this.fire({
+ type: "startviewport",
+ line: line,
+ col: col
+ });
+
+ this._readDeclarations(true);
+
+ this.fire({
+ type: "endviewport",
+ line: line,
+ col: col
+ });
+
+ },
+
+ _operator: function(inFunction){
+
+ var tokenStream = this._tokenStream,
+ token = null;
+
+ if (tokenStream.match([Tokens.SLASH, Tokens.COMMA]) ||
+ (inFunction && tokenStream.match([Tokens.PLUS, Tokens.STAR, Tokens.MINUS]))){
+ token = tokenStream.token();
+ this._readWhitespace();
+ }
+ return token ? PropertyValuePart.fromToken(token) : null;
+
+ },
+
+ _combinator: function(){
+
+ var tokenStream = this._tokenStream,
+ value = null,
+ token;
+
+ if(tokenStream.match([Tokens.PLUS, Tokens.GREATER, Tokens.TILDE])){
+ token = tokenStream.token();
+ value = new Combinator(token.value, token.startLine, token.startCol);
+ this._readWhitespace();
+ }
+
+ return value;
+ },
+
+ _unary_operator: function(){
+
+ var tokenStream = this._tokenStream;
+
+ if (tokenStream.match([Tokens.MINUS, Tokens.PLUS])){
+ return tokenStream.token().value;
+ } else {
+ return null;
+ }
+ },
+
+ _property: function(){
+
+ var tokenStream = this._tokenStream,
+ value = null,
+ hack = null,
+ tokenValue,
+ token,
+ line,
+ col;
+ if (tokenStream.peek() == Tokens.STAR && this.options.starHack){
+ tokenStream.get();
+ token = tokenStream.token();
+ hack = token.value;
+ line = token.startLine;
+ col = token.startCol;
+ }
+
+ if(tokenStream.match(Tokens.IDENT)){
+ token = tokenStream.token();
+ tokenValue = token.value;
+ if (tokenValue.charAt(0) == "_" && this.options.underscoreHack){
+ hack = "_";
+ tokenValue = tokenValue.substring(1);
+ }
+
+ value = new PropertyName(tokenValue, hack, (line||token.startLine), (col||token.startCol));
+ this._readWhitespace();
+ }
+
+ return value;
+ },
+ _ruleset: function(){
+
+ var tokenStream = this._tokenStream,
+ tt,
+ selectors;
+ try {
+ selectors = this._selectors_group();
+ } catch (ex){
+ if (ex instanceof SyntaxError && !this.options.strict){
+ this.fire({
+ type: "error",
+ error: ex,
+ message: ex.message,
+ line: ex.line,
+ col: ex.col
+ });
+ tt = tokenStream.advance([Tokens.RBRACE]);
+ if (tt == Tokens.RBRACE){
+ } else {
+ throw ex;
+ }
+
+ } else {
+ throw ex;
+ }
+ return true;
+ }
+ if (selectors){
+
+ this.fire({
+ type: "startrule",
+ selectors: selectors,
+ line: selectors[0].line,
+ col: selectors[0].col
+ });
+
+ this._readDeclarations(true);
+
+ this.fire({
+ type: "endrule",
+ selectors: selectors,
+ line: selectors[0].line,
+ col: selectors[0].col
+ });
+
+ }
+
+ return selectors;
+
+ },
+ _selectors_group: function(){
+ var tokenStream = this._tokenStream,
+ selectors = [],
+ selector;
+
+ selector = this._selector();
+ if (selector !== null){
+
+ selectors.push(selector);
+ while(tokenStream.match(Tokens.COMMA)){
+ this._readWhitespace();
+ selector = this._selector();
+ if (selector !== null){
+ selectors.push(selector);
+ } else {
+ this._unexpectedToken(tokenStream.LT(1));
+ }
+ }
+ }
+
+ return selectors.length ? selectors : null;
+ },
+ _selector: function(){
+
+ var tokenStream = this._tokenStream,
+ selector = [],
+ nextSelector = null,
+ combinator = null,
+ ws = null;
+ nextSelector = this._simple_selector_sequence();
+ if (nextSelector === null){
+ return null;
+ }
+
+ selector.push(nextSelector);
+
+ do {
+ combinator = this._combinator();
+
+ if (combinator !== null){
+ selector.push(combinator);
+ nextSelector = this._simple_selector_sequence();
+ if (nextSelector === null){
+ this._unexpectedToken(tokenStream.LT(1));
+ } else {
+ selector.push(nextSelector);
+ }
+ } else {
+ if (this._readWhitespace()){
+ ws = new Combinator(tokenStream.token().value, tokenStream.token().startLine, tokenStream.token().startCol);
+ combinator = this._combinator();
+ nextSelector = this._simple_selector_sequence();
+ if (nextSelector === null){
+ if (combinator !== null){
+ this._unexpectedToken(tokenStream.LT(1));
+ }
+ } else {
+
+ if (combinator !== null){
+ selector.push(combinator);
+ } else {
+ selector.push(ws);
+ }
+
+ selector.push(nextSelector);
+ }
+ } else {
+ break;
+ }
+
+ }
+ } while(true);
+
+ return new Selector(selector, selector[0].line, selector[0].col);
+ },
+ _simple_selector_sequence: function(){
+
+ var tokenStream = this._tokenStream,
+ elementName = null,
+ modifiers = [],
+ selectorText= "",
+ components = [
+ function(){
+ return tokenStream.match(Tokens.HASH) ?
+ new SelectorSubPart(tokenStream.token().value, "id", tokenStream.token().startLine, tokenStream.token().startCol) :
+ null;
+ },
+ this._class,
+ this._attrib,
+ this._pseudo,
+ this._negation
+ ],
+ i = 0,
+ len = components.length,
+ component = null,
+ found = false,
+ line,
+ col;
+ line = tokenStream.LT(1).startLine;
+ col = tokenStream.LT(1).startCol;
+
+ elementName = this._type_selector();
+ if (!elementName){
+ elementName = this._universal();
+ }
+
+ if (elementName !== null){
+ selectorText += elementName;
+ }
+
+ while(true){
+ if (tokenStream.peek() === Tokens.S){
+ break;
+ }
+ while(i < len && component === null){
+ component = components[i++].call(this);
+ }
+
+ if (component === null){
+ if (selectorText === ""){
+ return null;
+ } else {
+ break;
+ }
+ } else {
+ i = 0;
+ modifiers.push(component);
+ selectorText += component.toString();
+ component = null;
+ }
+ }
+
+
+ return selectorText !== "" ?
+ new SelectorPart(elementName, modifiers, selectorText, line, col) :
+ null;
+ },
+ _type_selector: function(){
+
+ var tokenStream = this._tokenStream,
+ ns = this._namespace_prefix(),
+ elementName = this._element_name();
+
+ if (!elementName){
+ if (ns){
+ tokenStream.unget();
+ if (ns.length > 1){
+ tokenStream.unget();
+ }
+ }
+
+ return null;
+ } else {
+ if (ns){
+ elementName.text = ns + elementName.text;
+ elementName.col -= ns.length;
+ }
+ return elementName;
+ }
+ },
+ _class: function(){
+
+ var tokenStream = this._tokenStream,
+ token;
+
+ if (tokenStream.match(Tokens.DOT)){
+ tokenStream.mustMatch(Tokens.IDENT);
+ token = tokenStream.token();
+ return new SelectorSubPart("." + token.value, "class", token.startLine, token.startCol - 1);
+ } else {
+ return null;
+ }
+
+ },
+ _element_name: function(){
+
+ var tokenStream = this._tokenStream,
+ token;
+
+ if (tokenStream.match(Tokens.IDENT)){
+ token = tokenStream.token();
+ return new SelectorSubPart(token.value, "elementName", token.startLine, token.startCol);
+
+ } else {
+ return null;
+ }
+ },
+ _namespace_prefix: function(){
+ var tokenStream = this._tokenStream,
+ value = "";
+ if (tokenStream.LA(1) === Tokens.PIPE || tokenStream.LA(2) === Tokens.PIPE){
+
+ if(tokenStream.match([Tokens.IDENT, Tokens.STAR])){
+ value += tokenStream.token().value;
+ }
+
+ tokenStream.mustMatch(Tokens.PIPE);
+ value += "|";
+
+ }
+
+ return value.length ? value : null;
+ },
+ _universal: function(){
+ var tokenStream = this._tokenStream,
+ value = "",
+ ns;
+
+ ns = this._namespace_prefix();
+ if(ns){
+ value += ns;
+ }
+
+ if(tokenStream.match(Tokens.STAR)){
+ value += "*";
+ }
+
+ return value.length ? value : null;
+
+ },
+ _attrib: function(){
+
+ var tokenStream = this._tokenStream,
+ value = null,
+ ns,
+ token;
+
+ if (tokenStream.match(Tokens.LBRACKET)){
+ token = tokenStream.token();
+ value = token.value;
+ value += this._readWhitespace();
+
+ ns = this._namespace_prefix();
+
+ if (ns){
+ value += ns;
+ }
+
+ tokenStream.mustMatch(Tokens.IDENT);
+ value += tokenStream.token().value;
+ value += this._readWhitespace();
+
+ if(tokenStream.match([Tokens.PREFIXMATCH, Tokens.SUFFIXMATCH, Tokens.SUBSTRINGMATCH,
+ Tokens.EQUALS, Tokens.INCLUDES, Tokens.DASHMATCH])){
+
+ value += tokenStream.token().value;
+ value += this._readWhitespace();
+
+ tokenStream.mustMatch([Tokens.IDENT, Tokens.STRING]);
+ value += tokenStream.token().value;
+ value += this._readWhitespace();
+ }
+
+ tokenStream.mustMatch(Tokens.RBRACKET);
+
+ return new SelectorSubPart(value + "]", "attribute", token.startLine, token.startCol);
+ } else {
+ return null;
+ }
+ },
+ _pseudo: function(){
+
+ var tokenStream = this._tokenStream,
+ pseudo = null,
+ colons = ":",
+ line,
+ col;
+
+ if (tokenStream.match(Tokens.COLON)){
+
+ if (tokenStream.match(Tokens.COLON)){
+ colons += ":";
+ }
+
+ if (tokenStream.match(Tokens.IDENT)){
+ pseudo = tokenStream.token().value;
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol - colons.length;
+ } else if (tokenStream.peek() == Tokens.FUNCTION){
+ line = tokenStream.LT(1).startLine;
+ col = tokenStream.LT(1).startCol - colons.length;
+ pseudo = this._functional_pseudo();
+ }
+
+ if (pseudo){
+ pseudo = new SelectorSubPart(colons + pseudo, "pseudo", line, col);
+ }
+ }
+
+ return pseudo;
+ },
+ _functional_pseudo: function(){
+
+ var tokenStream = this._tokenStream,
+ value = null;
+
+ if(tokenStream.match(Tokens.FUNCTION)){
+ value = tokenStream.token().value;
+ value += this._readWhitespace();
+ value += this._expression();
+ tokenStream.mustMatch(Tokens.RPAREN);
+ value += ")";
+ }
+
+ return value;
+ },
+ _expression: function(){
+
+ var tokenStream = this._tokenStream,
+ value = "";
+
+ while(tokenStream.match([Tokens.PLUS, Tokens.MINUS, Tokens.DIMENSION,
+ Tokens.NUMBER, Tokens.STRING, Tokens.IDENT, Tokens.LENGTH,
+ Tokens.FREQ, Tokens.ANGLE, Tokens.TIME,
+ Tokens.RESOLUTION, Tokens.SLASH])){
+
+ value += tokenStream.token().value;
+ value += this._readWhitespace();
+ }
+
+ return value.length ? value : null;
+
+ },
+ _negation: function(){
+
+ var tokenStream = this._tokenStream,
+ line,
+ col,
+ value = "",
+ arg,
+ subpart = null;
+
+ if (tokenStream.match(Tokens.NOT)){
+ value = tokenStream.token().value;
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+ value += this._readWhitespace();
+ arg = this._negation_arg();
+ value += arg;
+ value += this._readWhitespace();
+ tokenStream.match(Tokens.RPAREN);
+ value += tokenStream.token().value;
+
+ subpart = new SelectorSubPart(value, "not", line, col);
+ subpart.args.push(arg);
+ }
+
+ return subpart;
+ },
+ _negation_arg: function(){
+
+ var tokenStream = this._tokenStream,
+ args = [
+ this._type_selector,
+ this._universal,
+ function(){
+ return tokenStream.match(Tokens.HASH) ?
+ new SelectorSubPart(tokenStream.token().value, "id", tokenStream.token().startLine, tokenStream.token().startCol) :
+ null;
+ },
+ this._class,
+ this._attrib,
+ this._pseudo
+ ],
+ arg = null,
+ i = 0,
+ len = args.length,
+ elementName,
+ line,
+ col,
+ part;
+
+ line = tokenStream.LT(1).startLine;
+ col = tokenStream.LT(1).startCol;
+
+ while(i < len && arg === null){
+
+ arg = args[i].call(this);
+ i++;
+ }
+ if (arg === null){
+ this._unexpectedToken(tokenStream.LT(1));
+ }
+ if (arg.type == "elementName"){
+ part = new SelectorPart(arg, [], arg.toString(), line, col);
+ } else {
+ part = new SelectorPart(null, [arg], arg.toString(), line, col);
+ }
+
+ return part;
+ },
+
+ _declaration: function(){
+
+ var tokenStream = this._tokenStream,
+ property = null,
+ expr = null,
+ prio = null,
+ error = null,
+ invalid = null,
+ propertyName= "";
+
+ property = this._property();
+ if (property !== null){
+
+ tokenStream.mustMatch(Tokens.COLON);
+ this._readWhitespace();
+
+ expr = this._expr();
+ if (!expr || expr.length === 0){
+ this._unexpectedToken(tokenStream.LT(1));
+ }
+
+ prio = this._prio();
+ propertyName = property.toString();
+ if (this.options.starHack && property.hack == "*" ||
+ this.options.underscoreHack && property.hack == "_") {
+
+ propertyName = property.text;
+ }
+
+ try {
+ this._validateProperty(propertyName, expr);
+ } catch (ex) {
+ invalid = ex;
+ }
+
+ this.fire({
+ type: "property",
+ property: property,
+ value: expr,
+ important: prio,
+ line: property.line,
+ col: property.col,
+ invalid: invalid
+ });
+
+ return true;
+ } else {
+ return false;
+ }
+ },
+
+ _prio: function(){
+
+ var tokenStream = this._tokenStream,
+ result = tokenStream.match(Tokens.IMPORTANT_SYM);
+
+ this._readWhitespace();
+ return result;
+ },
+
+ _expr: function(inFunction){
+
+ var tokenStream = this._tokenStream,
+ values = [],
+ value = null,
+ operator = null;
+
+ value = this._term(inFunction);
+ if (value !== null){
+
+ values.push(value);
+
+ do {
+ operator = this._operator(inFunction);
+ if (operator){
+ values.push(operator);
+ } /*else {
+ values.push(new PropertyValue(valueParts, valueParts[0].line, valueParts[0].col));
+ valueParts = [];
+ }*/
+
+ value = this._term(inFunction);
+
+ if (value === null){
+ break;
+ } else {
+ values.push(value);
+ }
+ } while(true);
+ }
+
+ return values.length > 0 ? new PropertyValue(values, values[0].line, values[0].col) : null;
+ },
+
+ _term: function(inFunction){
+
+ var tokenStream = this._tokenStream,
+ unary = null,
+ value = null,
+ endChar = null,
+ token,
+ line,
+ col;
+ unary = this._unary_operator();
+ if (unary !== null){
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+ }
+ if (tokenStream.peek() == Tokens.IE_FUNCTION && this.options.ieFilters){
+
+ value = this._ie_function();
+ if (unary === null){
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+ }
+ } else if (inFunction && tokenStream.match([Tokens.LPAREN, Tokens.LBRACE, Tokens.LBRACKET])){
+
+ token = tokenStream.token();
+ endChar = token.endChar;
+ value = token.value + this._expr(inFunction).text;
+ if (unary === null){
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+ }
+ tokenStream.mustMatch(Tokens.type(endChar));
+ value += endChar;
+ this._readWhitespace();
+ } else if (tokenStream.match([Tokens.NUMBER, Tokens.PERCENTAGE, Tokens.LENGTH,
+ Tokens.ANGLE, Tokens.TIME,
+ Tokens.FREQ, Tokens.STRING, Tokens.IDENT, Tokens.URI, Tokens.UNICODE_RANGE])){
+
+ value = tokenStream.token().value;
+ if (unary === null){
+ line = tokenStream.token().startLine;
+ col = tokenStream.token().startCol;
+ }
+ this._readWhitespace();
+ } else {
+ token = this._hexcolor();
+ if (token === null){
+ if (unary === null){
+ line = tokenStream.LT(1).startLine;
+ col = tokenStream.LT(1).startCol;
+ }
+ if (value === null){
+ if (tokenStream.LA(3) == Tokens.EQUALS && this.options.ieFilters){
+ value = this._ie_function();
+ } else {
+ value = this._function();
+ }
+ }
+
+ } else {
+ value = token.value;
+ if (unary === null){
+ line = token.startLine;
+ col = token.startCol;
+ }
+ }
+
+ }
+
+ return value !== null ?
+ new PropertyValuePart(unary !== null ? unary + value : value, line, col) :
+ null;
+
+ },
+
+ _function: function(){
+
+ var tokenStream = this._tokenStream,
+ functionText = null,
+ expr = null,
+ lt;
+
+ if (tokenStream.match(Tokens.FUNCTION)){
+ functionText = tokenStream.token().value;
+ this._readWhitespace();
+ expr = this._expr(true);
+ functionText += expr;
+ if (this.options.ieFilters && tokenStream.peek() == Tokens.EQUALS){
+ do {
+
+ if (this._readWhitespace()){
+ functionText += tokenStream.token().value;
+ }
+ if (tokenStream.LA(0) == Tokens.COMMA){
+ functionText += tokenStream.token().value;
+ }
+
+ tokenStream.match(Tokens.IDENT);
+ functionText += tokenStream.token().value;
+
+ tokenStream.match(Tokens.EQUALS);
+ functionText += tokenStream.token().value;
+ lt = tokenStream.peek();
+ while(lt != Tokens.COMMA && lt != Tokens.S && lt != Tokens.RPAREN){
+ tokenStream.get();
+ functionText += tokenStream.token().value;
+ lt = tokenStream.peek();
+ }
+ } while(tokenStream.match([Tokens.COMMA, Tokens.S]));
+ }
+
+ tokenStream.match(Tokens.RPAREN);
+ functionText += ")";
+ this._readWhitespace();
+ }
+
+ return functionText;
+ },
+
+ _ie_function: function(){
+
+ var tokenStream = this._tokenStream,
+ functionText = null,
+ expr = null,
+ lt;
+ if (tokenStream.match([Tokens.IE_FUNCTION, Tokens.FUNCTION])){
+ functionText = tokenStream.token().value;
+
+ do {
+
+ if (this._readWhitespace()){
+ functionText += tokenStream.token().value;
+ }
+ if (tokenStream.LA(0) == Tokens.COMMA){
+ functionText += tokenStream.token().value;
+ }
+
+ tokenStream.match(Tokens.IDENT);
+ functionText += tokenStream.token().value;
+
+ tokenStream.match(Tokens.EQUALS);
+ functionText += tokenStream.token().value;
+ lt = tokenStream.peek();
+ while(lt != Tokens.COMMA && lt != Tokens.S && lt != Tokens.RPAREN){
+ tokenStream.get();
+ functionText += tokenStream.token().value;
+ lt = tokenStream.peek();
+ }
+ } while(tokenStream.match([Tokens.COMMA, Tokens.S]));
+
+ tokenStream.match(Tokens.RPAREN);
+ functionText += ")";
+ this._readWhitespace();
+ }
+
+ return functionText;
+ },
+
+ _hexcolor: function(){
+
+ var tokenStream = this._tokenStream,
+ token = null,
+ color;
+
+ if(tokenStream.match(Tokens.HASH)){
+
+ token = tokenStream.token();
+ color = token.value;
+ if (!/#[a-f0-9]{3,6}/i.test(color)){
+ throw new SyntaxError("Expected a hex color but found '" + color + "' at line " + token.startLine + ", col " + token.startCol + ".", token.startLine, token.startCol);
+ }
+ this._readWhitespace();
+ }
+
+ return token;
+ },
+
+ _keyframes: function(){
+ var tokenStream = this._tokenStream,
+ token,
+ tt,
+ name,
+ prefix = "";
+
+ tokenStream.mustMatch(Tokens.KEYFRAMES_SYM);
+ token = tokenStream.token();
+ if (/^@\-([^\-]+)\-/.test(token.value)) {
+ prefix = RegExp.$1;
+ }
+
+ this._readWhitespace();
+ name = this._keyframe_name();
+
+ this._readWhitespace();
+ tokenStream.mustMatch(Tokens.LBRACE);
+
+ this.fire({
+ type: "startkeyframes",
+ name: name,
+ prefix: prefix,
+ line: token.startLine,
+ col: token.startCol
+ });
+
+ this._readWhitespace();
+ tt = tokenStream.peek();
+ while(tt == Tokens.IDENT || tt == Tokens.PERCENTAGE) {
+ this._keyframe_rule();
+ this._readWhitespace();
+ tt = tokenStream.peek();
+ }
+
+ this.fire({
+ type: "endkeyframes",
+ name: name,
+ prefix: prefix,
+ line: token.startLine,
+ col: token.startCol
+ });
+
+ this._readWhitespace();
+ tokenStream.mustMatch(Tokens.RBRACE);
+
+ },
+
+ _keyframe_name: function(){
+ var tokenStream = this._tokenStream,
+ token;
+
+ tokenStream.mustMatch([Tokens.IDENT, Tokens.STRING]);
+ return SyntaxUnit.fromToken(tokenStream.token());
+ },
+
+ _keyframe_rule: function(){
+ var tokenStream = this._tokenStream,
+ token,
+ keyList = this._key_list();
+
+ this.fire({
+ type: "startkeyframerule",
+ keys: keyList,
+ line: keyList[0].line,
+ col: keyList[0].col
+ });
+
+ this._readDeclarations(true);
+
+ this.fire({
+ type: "endkeyframerule",
+ keys: keyList,
+ line: keyList[0].line,
+ col: keyList[0].col
+ });
+
+ },
+
+ _key_list: function(){
+ var tokenStream = this._tokenStream,
+ token,
+ key,
+ keyList = [];
+ keyList.push(this._key());
+
+ this._readWhitespace();
+
+ while(tokenStream.match(Tokens.COMMA)){
+ this._readWhitespace();
+ keyList.push(this._key());
+ this._readWhitespace();
+ }
+
+ return keyList;
+ },
+
+ _key: function(){
+
+ var tokenStream = this._tokenStream,
+ token;
+
+ if (tokenStream.match(Tokens.PERCENTAGE)){
+ return SyntaxUnit.fromToken(tokenStream.token());
+ } else if (tokenStream.match(Tokens.IDENT)){
+ token = tokenStream.token();
+
+ if (/from|to/i.test(token.value)){
+ return SyntaxUnit.fromToken(token);
+ }
+
+ tokenStream.unget();
+ }
+ this._unexpectedToken(tokenStream.LT(1));
+ },
+ _skipCruft: function(){
+ while(this._tokenStream.match([Tokens.S, Tokens.CDO, Tokens.CDC])){
+ }
+ },
+ _readDeclarations: function(checkStart, readMargins){
+ var tokenStream = this._tokenStream,
+ tt;
+
+
+ this._readWhitespace();
+
+ if (checkStart){
+ tokenStream.mustMatch(Tokens.LBRACE);
+ }
+
+ this._readWhitespace();
+
+ try {
+
+ while(true){
+
+ if (tokenStream.match(Tokens.SEMICOLON) || (readMargins && this._margin())){
+ } else if (this._declaration()){
+ if (!tokenStream.match(Tokens.SEMICOLON)){
+ break;
+ }
+ } else {
+ break;
+ }
+ this._readWhitespace();
+ }
+
+ tokenStream.mustMatch(Tokens.RBRACE);
+ this._readWhitespace();
+
+ } catch (ex) {
+ if (ex instanceof SyntaxError && !this.options.strict){
+ this.fire({
+ type: "error",
+ error: ex,
+ message: ex.message,
+ line: ex.line,
+ col: ex.col
+ });
+ tt = tokenStream.advance([Tokens.SEMICOLON, Tokens.RBRACE]);
+ if (tt == Tokens.SEMICOLON){
+ this._readDeclarations(false, readMargins);
+ } else if (tt != Tokens.RBRACE){
+ throw ex;
+ }
+
+ } else {
+ throw ex;
+ }
+ }
+
+ },
+ _readWhitespace: function(){
+
+ var tokenStream = this._tokenStream,
+ ws = "";
+
+ while(tokenStream.match(Tokens.S)){
+ ws += tokenStream.token().value;
+ }
+
+ return ws;
+ },
+ _unexpectedToken: function(token){
+ throw new SyntaxError("Unexpected token '" + token.value + "' at line " + token.startLine + ", col " + token.startCol + ".", token.startLine, token.startCol);
+ },
+ _verifyEnd: function(){
+ if (this._tokenStream.LA(1) != Tokens.EOF){
+ this._unexpectedToken(this._tokenStream.LT(1));
+ }
+ },
+ _validateProperty: function(property, value){
+ Validation.validate(property, value);
+ },
+
+ parse: function(input){
+ this._tokenStream = new TokenStream(input, Tokens);
+ this._stylesheet();
+ },
+
+ parseStyleSheet: function(input){
+ return this.parse(input);
+ },
+
+ parseMediaQuery: function(input){
+ this._tokenStream = new TokenStream(input, Tokens);
+ var result = this._media_query();
+ this._verifyEnd();
+ return result;
+ },
+ parsePropertyValue: function(input){
+
+ this._tokenStream = new TokenStream(input, Tokens);
+ this._readWhitespace();
+
+ var result = this._expr();
+ this._readWhitespace();
+ this._verifyEnd();
+ return result;
+ },
+ parseRule: function(input){
+ this._tokenStream = new TokenStream(input, Tokens);
+ this._readWhitespace();
+
+ var result = this._ruleset();
+ this._readWhitespace();
+ this._verifyEnd();
+ return result;
+ },
+ parseSelector: function(input){
+
+ this._tokenStream = new TokenStream(input, Tokens);
+ this._readWhitespace();
+
+ var result = this._selector();
+ this._readWhitespace();
+ this._verifyEnd();
+ return result;
+ },
+ parseStyleAttribute: function(input){
+ input += "}"; // for error recovery in _readDeclarations()
+ this._tokenStream = new TokenStream(input, Tokens);
+ this._readDeclarations();
+ }
+ };
+ for (prop in additions){
+ if (additions.hasOwnProperty(prop)){
+ proto[prop] = additions[prop];
+ }
+ }
+
+ return proto;
+}();
+var Properties = {
+ "align-items" : "flex-start | flex-end | center | baseline | stretch",
+ "align-content" : "flex-start | flex-end | center | space-between | space-around | stretch",
+ "align-self" : "auto | flex-start | flex-end | center | baseline | stretch",
+ "-webkit-align-items" : "flex-start | flex-end | center | baseline | stretch",
+ "-webkit-align-content" : "flex-start | flex-end | center | space-between | space-around | stretch",
+ "-webkit-align-self" : "auto | flex-start | flex-end | center | baseline | stretch",
+ "alignment-adjust" : "auto | baseline | before-edge | text-before-edge | middle | central | after-edge | text-after-edge | ideographic | alphabetic | hanging | mathematical | <percentage> | <length>",
+ "alignment-baseline" : "baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical",
+ "animation" : 1,
+ "animation-delay" : { multi: "<time>", comma: true },
+ "animation-direction" : { multi: "normal | reverse | alternate | alternate-reverse", comma: true },
+ "animation-duration" : { multi: "<time>", comma: true },
+ "animation-fill-mode" : { multi: "none | forwards | backwards | both", comma: true },
+ "animation-iteration-count" : { multi: "<number> | infinite", comma: true },
+ "animation-name" : { multi: "none | <ident>", comma: true },
+ "animation-play-state" : { multi: "running | paused", comma: true },
+ "animation-timing-function" : 1,
+ "-moz-animation-delay" : { multi: "<time>", comma: true },
+ "-moz-animation-direction" : { multi: "normal | reverse | alternate | alternate-reverse", comma: true },
+ "-moz-animation-duration" : { multi: "<time>", comma: true },
+ "-moz-animation-iteration-count" : { multi: "<number> | infinite", comma: true },
+ "-moz-animation-name" : { multi: "none | <ident>", comma: true },
+ "-moz-animation-play-state" : { multi: "running | paused", comma: true },
+
+ "-ms-animation-delay" : { multi: "<time>", comma: true },
+ "-ms-animation-direction" : { multi: "normal | reverse | alternate | alternate-reverse", comma: true },
+ "-ms-animation-duration" : { multi: "<time>", comma: true },
+ "-ms-animation-iteration-count" : { multi: "<number> | infinite", comma: true },
+ "-ms-animation-name" : { multi: "none | <ident>", comma: true },
+ "-ms-animation-play-state" : { multi: "running | paused", comma: true },
+
+ "-webkit-animation-delay" : { multi: "<time>", comma: true },
+ "-webkit-animation-direction" : { multi: "normal | reverse | alternate | alternate-reverse", comma: true },
+ "-webkit-animation-duration" : { multi: "<time>", comma: true },
+ "-webkit-animation-fill-mode" : { multi: "none | forwards | backwards | both", comma: true },
+ "-webkit-animation-iteration-count" : { multi: "<number> | infinite", comma: true },
+ "-webkit-animation-name" : { multi: "none | <ident>", comma: true },
+ "-webkit-animation-play-state" : { multi: "running | paused", comma: true },
+
+ "-o-animation-delay" : { multi: "<time>", comma: true },
+ "-o-animation-direction" : { multi: "normal | reverse | alternate | alternate-reverse", comma: true },
+ "-o-animation-duration" : { multi: "<time>", comma: true },
+ "-o-animation-iteration-count" : { multi: "<number> | infinite", comma: true },
+ "-o-animation-name" : { multi: "none | <ident>", comma: true },
+ "-o-animation-play-state" : { multi: "running | paused", comma: true },
+
+ "appearance" : "icon | window | desktop | workspace | document | tooltip | dialog | button | push-button | hyperlink | radio-button | checkbox | menu-item | tab | menu | menubar | pull-down-menu | pop-up-menu | list-menu | radio-group | checkbox-group | outline-tree | range | field | combo-box | signature | password | normal | none | inherit",
+ "azimuth" : function (expression) {
+ var simple = "<angle> | leftwards | rightwards | inherit",
+ direction = "left-side | far-left | left | center-left | center | center-right | right | far-right | right-side",
+ behind = false,
+ valid = false,
+ part;
+
+ if (!ValidationTypes.isAny(expression, simple)) {
+ if (ValidationTypes.isAny(expression, "behind")) {
+ behind = true;
+ valid = true;
+ }
+
+ if (ValidationTypes.isAny(expression, direction)) {
+ valid = true;
+ if (!behind) {
+ ValidationTypes.isAny(expression, "behind");
+ }
+ }
+ }
+
+ if (expression.hasNext()) {
+ part = expression.next();
+ if (valid) {
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ throw new ValidationError("Expected (<'azimuth'>) but found '" + part + "'.", part.line, part.col);
+ }
+ }
+ },
+ "backface-visibility" : "visible | hidden",
+ "background" : 1,
+ "background-attachment" : { multi: "<attachment>", comma: true },
+ "background-clip" : { multi: "<box>", comma: true },
+ "background-color" : "<color> | inherit",
+ "background-image" : { multi: "<bg-image>", comma: true },
+ "background-origin" : { multi: "<box>", comma: true },
+ "background-position" : { multi: "<bg-position>", comma: true },
+ "background-repeat" : { multi: "<repeat-style>" },
+ "background-size" : { multi: "<bg-size>", comma: true },
+ "baseline-shift" : "baseline | sub | super | <percentage> | <length>",
+ "behavior" : 1,
+ "binding" : 1,
+ "bleed" : "<length>",
+ "bookmark-label" : "<content> | <attr> | <string>",
+ "bookmark-level" : "none | <integer>",
+ "bookmark-state" : "open | closed",
+ "bookmark-target" : "none | <uri> | <attr>",
+ "border" : "<border-width> || <border-style> || <color>",
+ "border-bottom" : "<border-width> || <border-style> || <color>",
+ "border-bottom-color" : "<color> | inherit",
+ "border-bottom-left-radius" : "<x-one-radius>",
+ "border-bottom-right-radius" : "<x-one-radius>",
+ "border-bottom-style" : "<border-style>",
+ "border-bottom-width" : "<border-width>",
+ "border-collapse" : "collapse | separate | inherit",
+ "border-color" : { multi: "<color> | inherit", max: 4 },
+ "border-image" : 1,
+ "border-image-outset" : { multi: "<length> | <number>", max: 4 },
+ "border-image-repeat" : { multi: "stretch | repeat | round", max: 2 },
+ "border-image-slice" : function(expression) {
+
+ var valid = false,
+ numeric = "<number> | <percentage>",
+ fill = false,
+ count = 0,
+ max = 4,
+ part;
+
+ if (ValidationTypes.isAny(expression, "fill")) {
+ fill = true;
+ valid = true;
+ }
+
+ while (expression.hasNext() && count < max) {
+ valid = ValidationTypes.isAny(expression, numeric);
+ if (!valid) {
+ break;
+ }
+ count++;
+ }
+
+
+ if (!fill) {
+ ValidationTypes.isAny(expression, "fill");
+ } else {
+ valid = true;
+ }
+
+ if (expression.hasNext()) {
+ part = expression.next();
+ if (valid) {
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ throw new ValidationError("Expected ([<number> | <percentage>]{1,4} && fill?) but found '" + part + "'.", part.line, part.col);
+ }
+ }
+ },
+ "border-image-source" : "<image> | none",
+ "border-image-width" : { multi: "<length> | <percentage> | <number> | auto", max: 4 },
+ "border-left" : "<border-width> || <border-style> || <color>",
+ "border-left-color" : "<color> | inherit",
+ "border-left-style" : "<border-style>",
+ "border-left-width" : "<border-width>",
+ "border-radius" : function(expression) {
+
+ var valid = false,
+ simple = "<length> | <percentage> | inherit",
+ slash = false,
+ fill = false,
+ count = 0,
+ max = 8,
+ part;
+
+ while (expression.hasNext() && count < max) {
+ valid = ValidationTypes.isAny(expression, simple);
+ if (!valid) {
+
+ if (expression.peek() == "/" && count > 0 && !slash) {
+ slash = true;
+ max = count + 5;
+ expression.next();
+ } else {
+ break;
+ }
+ }
+ count++;
+ }
+
+ if (expression.hasNext()) {
+ part = expression.next();
+ if (valid) {
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ throw new ValidationError("Expected (<'border-radius'>) but found '" + part + "'.", part.line, part.col);
+ }
+ }
+ },
+ "border-right" : "<border-width> || <border-style> || <color>",
+ "border-right-color" : "<color> | inherit",
+ "border-right-style" : "<border-style>",
+ "border-right-width" : "<border-width>",
+ "border-spacing" : { multi: "<length> | inherit", max: 2 },
+ "border-style" : { multi: "<border-style>", max: 4 },
+ "border-top" : "<border-width> || <border-style> || <color>",
+ "border-top-color" : "<color> | inherit",
+ "border-top-left-radius" : "<x-one-radius>",
+ "border-top-right-radius" : "<x-one-radius>",
+ "border-top-style" : "<border-style>",
+ "border-top-width" : "<border-width>",
+ "border-width" : { multi: "<border-width>", max: 4 },
+ "bottom" : "<margin-width> | inherit",
+ "-moz-box-align" : "start | end | center | baseline | stretch",
+ "-moz-box-decoration-break" : "slice |clone",
+ "-moz-box-direction" : "normal | reverse | inherit",
+ "-moz-box-flex" : "<number>",
+ "-moz-box-flex-group" : "<integer>",
+ "-moz-box-lines" : "single | multiple",
+ "-moz-box-ordinal-group" : "<integer>",
+ "-moz-box-orient" : "horizontal | vertical | inline-axis | block-axis | inherit",
+ "-moz-box-pack" : "start | end | center | justify",
+ "-webkit-box-align" : "start | end | center | baseline | stretch",
+ "-webkit-box-decoration-break" : "slice |clone",
+ "-webkit-box-direction" : "normal | reverse | inherit",
+ "-webkit-box-flex" : "<number>",
+ "-webkit-box-flex-group" : "<integer>",
+ "-webkit-box-lines" : "single | multiple",
+ "-webkit-box-ordinal-group" : "<integer>",
+ "-webkit-box-orient" : "horizontal | vertical | inline-axis | block-axis | inherit",
+ "-webkit-box-pack" : "start | end | center | justify",
+ "box-shadow" : function (expression) {
+ var result = false,
+ part;
+
+ if (!ValidationTypes.isAny(expression, "none")) {
+ Validation.multiProperty("<shadow>", expression, true, Infinity);
+ } else {
+ if (expression.hasNext()) {
+ part = expression.next();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ }
+ }
+ },
+ "box-sizing" : "content-box | border-box | inherit",
+ "break-after" : "auto | always | avoid | left | right | page | column | avoid-page | avoid-column",
+ "break-before" : "auto | always | avoid | left | right | page | column | avoid-page | avoid-column",
+ "break-inside" : "auto | avoid | avoid-page | avoid-column",
+ "caption-side" : "top | bottom | inherit",
+ "clear" : "none | right | left | both | inherit",
+ "clip" : 1,
+ "color" : "<color> | inherit",
+ "color-profile" : 1,
+ "column-count" : "<integer> | auto", //http://www.w3.org/TR/css3-multicol/
+ "column-fill" : "auto | balance",
+ "column-gap" : "<length> | normal",
+ "column-rule" : "<border-width> || <border-style> || <color>",
+ "column-rule-color" : "<color>",
+ "column-rule-style" : "<border-style>",
+ "column-rule-width" : "<border-width>",
+ "column-span" : "none | all",
+ "column-width" : "<length> | auto",
+ "columns" : 1,
+ "content" : 1,
+ "counter-increment" : 1,
+ "counter-reset" : 1,
+ "crop" : "<shape> | auto",
+ "cue" : "cue-after | cue-before | inherit",
+ "cue-after" : 1,
+ "cue-before" : 1,
+ "cursor" : 1,
+ "direction" : "ltr | rtl | inherit",
+ "display" : "inline | block | list-item | inline-block | table | inline-table | table-row-group | table-header-group | table-footer-group | table-row | table-column-group | table-column | table-cell | table-caption | grid | inline-grid | none | inherit | -moz-box | -moz-inline-block | -moz-inline-box | -moz-inline-grid | -moz-inline-stack | -moz-inline-table | -moz-grid | -moz-grid-group | -moz-grid-line | -moz-groupbox | -moz-deck | -moz-popup | -moz-stack | -moz-marker | -webkit-box | -webkit-inline-box | -ms-flexbox | -ms-inline-flexbox | flex | -webkit-flex | inline-flex | -webkit-inline-flex",
+ "dominant-baseline" : 1,
+ "drop-initial-after-adjust" : "central | middle | after-edge | text-after-edge | ideographic | alphabetic | mathematical | <percentage> | <length>",
+ "drop-initial-after-align" : "baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical",
+ "drop-initial-before-adjust" : "before-edge | text-before-edge | central | middle | hanging | mathematical | <percentage> | <length>",
+ "drop-initial-before-align" : "caps-height | baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical",
+ "drop-initial-size" : "auto | line | <length> | <percentage>",
+ "drop-initial-value" : "initial | <integer>",
+ "elevation" : "<angle> | below | level | above | higher | lower | inherit",
+ "empty-cells" : "show | hide | inherit",
+ "filter" : 1,
+ "fit" : "fill | hidden | meet | slice",
+ "fit-position" : 1,
+ "flex" : "<flex>",
+ "flex-basis" : "<width>",
+ "flex-direction" : "row | row-reverse | column | column-reverse",
+ "flex-flow" : "<flex-direction> || <flex-wrap>",
+ "flex-grow" : "<number>",
+ "flex-shrink" : "<number>",
+ "flex-wrap" : "nowrap | wrap | wrap-reverse",
+ "-webkit-flex" : "<flex>",
+ "-webkit-flex-basis" : "<width>",
+ "-webkit-flex-direction" : "row | row-reverse | column | column-reverse",
+ "-webkit-flex-flow" : "<flex-direction> || <flex-wrap>",
+ "-webkit-flex-grow" : "<number>",
+ "-webkit-flex-shrink" : "<number>",
+ "-webkit-flex-wrap" : "nowrap | wrap | wrap-reverse",
+ "-ms-flex" : "<flex>",
+ "-ms-flex-align" : "start | end | center | stretch | baseline",
+ "-ms-flex-direction" : "row | row-reverse | column | column-reverse | inherit",
+ "-ms-flex-order" : "<number>",
+ "-ms-flex-pack" : "start | end | center | justify",
+ "-ms-flex-wrap" : "nowrap | wrap | wrap-reverse",
+ "float" : "left | right | none | inherit",
+ "float-offset" : 1,
+ "font" : 1,
+ "font-family" : 1,
+ "font-size" : "<absolute-size> | <relative-size> | <length> | <percentage> | inherit",
+ "font-size-adjust" : "<number> | none | inherit",
+ "font-stretch" : "normal | ultra-condensed | extra-condensed | condensed | semi-condensed | semi-expanded | expanded | extra-expanded | ultra-expanded | inherit",
+ "font-style" : "normal | italic | oblique | inherit",
+ "font-variant" : "normal | small-caps | inherit",
+ "font-weight" : "normal | bold | bolder | lighter | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | inherit",
+ "grid-cell-stacking" : "columns | rows | layer",
+ "grid-column" : 1,
+ "grid-columns" : 1,
+ "grid-column-align" : "start | end | center | stretch",
+ "grid-column-sizing" : 1,
+ "grid-column-span" : "<integer>",
+ "grid-flow" : "none | rows | columns",
+ "grid-layer" : "<integer>",
+ "grid-row" : 1,
+ "grid-rows" : 1,
+ "grid-row-align" : "start | end | center | stretch",
+ "grid-row-span" : "<integer>",
+ "grid-row-sizing" : 1,
+ "hanging-punctuation" : 1,
+ "height" : "<margin-width> | <content-sizing> | inherit",
+ "hyphenate-after" : "<integer> | auto",
+ "hyphenate-before" : "<integer> | auto",
+ "hyphenate-character" : "<string> | auto",
+ "hyphenate-lines" : "no-limit | <integer>",
+ "hyphenate-resource" : 1,
+ "hyphens" : "none | manual | auto",
+ "icon" : 1,
+ "image-orientation" : "angle | auto",
+ "image-rendering" : 1,
+ "image-resolution" : 1,
+ "inline-box-align" : "initial | last | <integer>",
+ "justify-content" : "flex-start | flex-end | center | space-between | space-around",
+ "-webkit-justify-content" : "flex-start | flex-end | center | space-between | space-around",
+ "left" : "<margin-width> | inherit",
+ "letter-spacing" : "<length> | normal | inherit",
+ "line-height" : "<number> | <length> | <percentage> | normal | inherit",
+ "line-break" : "auto | loose | normal | strict",
+ "line-stacking" : 1,
+ "line-stacking-ruby" : "exclude-ruby | include-ruby",
+ "line-stacking-shift" : "consider-shifts | disregard-shifts",
+ "line-stacking-strategy" : "inline-line-height | block-line-height | max-height | grid-height",
+ "list-style" : 1,
+ "list-style-image" : "<uri> | none | inherit",
+ "list-style-position" : "inside | outside | inherit",
+ "list-style-type" : "disc | circle | square | decimal | decimal-leading-zero | lower-roman | upper-roman | lower-greek | lower-latin | upper-latin | armenian | georgian | lower-alpha | upper-alpha | none | inherit",
+ "margin" : { multi: "<margin-width> | inherit", max: 4 },
+ "margin-bottom" : "<margin-width> | inherit",
+ "margin-left" : "<margin-width> | inherit",
+ "margin-right" : "<margin-width> | inherit",
+ "margin-top" : "<margin-width> | inherit",
+ "mark" : 1,
+ "mark-after" : 1,
+ "mark-before" : 1,
+ "marks" : 1,
+ "marquee-direction" : 1,
+ "marquee-play-count" : 1,
+ "marquee-speed" : 1,
+ "marquee-style" : 1,
+ "max-height" : "<length> | <percentage> | <content-sizing> | none | inherit",
+ "max-width" : "<length> | <percentage> | <content-sizing> | none | inherit",
+ "min-height" : "<length> | <percentage> | <content-sizing> | contain-floats | -moz-contain-floats | -webkit-contain-floats | inherit",
+ "min-width" : "<length> | <percentage> | <content-sizing> | contain-floats | -moz-contain-floats | -webkit-contain-floats | inherit",
+ "move-to" : 1,
+ "nav-down" : 1,
+ "nav-index" : 1,
+ "nav-left" : 1,
+ "nav-right" : 1,
+ "nav-up" : 1,
+ "opacity" : "<number> | inherit",
+ "order" : "<integer>",
+ "-webkit-order" : "<integer>",
+ "orphans" : "<integer> | inherit",
+ "outline" : 1,
+ "outline-color" : "<color> | invert | inherit",
+ "outline-offset" : 1,
+ "outline-style" : "<border-style> | inherit",
+ "outline-width" : "<border-width> | inherit",
+ "overflow" : "visible | hidden | scroll | auto | inherit",
+ "overflow-style" : 1,
+ "overflow-wrap" : "normal | break-word",
+ "overflow-x" : 1,
+ "overflow-y" : 1,
+ "padding" : { multi: "<padding-width> | inherit", max: 4 },
+ "padding-bottom" : "<padding-width> | inherit",
+ "padding-left" : "<padding-width> | inherit",
+ "padding-right" : "<padding-width> | inherit",
+ "padding-top" : "<padding-width> | inherit",
+ "page" : 1,
+ "page-break-after" : "auto | always | avoid | left | right | inherit",
+ "page-break-before" : "auto | always | avoid | left | right | inherit",
+ "page-break-inside" : "auto | avoid | inherit",
+ "page-policy" : 1,
+ "pause" : 1,
+ "pause-after" : 1,
+ "pause-before" : 1,
+ "perspective" : 1,
+ "perspective-origin" : 1,
+ "phonemes" : 1,
+ "pitch" : 1,
+ "pitch-range" : 1,
+ "play-during" : 1,
+ "pointer-events" : "auto | none | visiblePainted | visibleFill | visibleStroke | visible | painted | fill | stroke | all | inherit",
+ "position" : "static | relative | absolute | fixed | inherit",
+ "presentation-level" : 1,
+ "punctuation-trim" : 1,
+ "quotes" : 1,
+ "rendering-intent" : 1,
+ "resize" : 1,
+ "rest" : 1,
+ "rest-after" : 1,
+ "rest-before" : 1,
+ "richness" : 1,
+ "right" : "<margin-width> | inherit",
+ "rotation" : 1,
+ "rotation-point" : 1,
+ "ruby-align" : 1,
+ "ruby-overhang" : 1,
+ "ruby-position" : 1,
+ "ruby-span" : 1,
+ "size" : 1,
+ "speak" : "normal | none | spell-out | inherit",
+ "speak-header" : "once | always | inherit",
+ "speak-numeral" : "digits | continuous | inherit",
+ "speak-punctuation" : "code | none | inherit",
+ "speech-rate" : 1,
+ "src" : 1,
+ "stress" : 1,
+ "string-set" : 1,
+
+ "table-layout" : "auto | fixed | inherit",
+ "tab-size" : "<integer> | <length>",
+ "target" : 1,
+ "target-name" : 1,
+ "target-new" : 1,
+ "target-position" : 1,
+ "text-align" : "left | right | center | justify | inherit" ,
+ "text-align-last" : 1,
+ "text-decoration" : 1,
+ "text-emphasis" : 1,
+ "text-height" : 1,
+ "text-indent" : "<length> | <percentage> | inherit",
+ "text-justify" : "auto | none | inter-word | inter-ideograph | inter-cluster | distribute | kashida",
+ "text-outline" : 1,
+ "text-overflow" : 1,
+ "text-rendering" : "auto | optimizeSpeed | optimizeLegibility | geometricPrecision | inherit",
+ "text-shadow" : 1,
+ "text-transform" : "capitalize | uppercase | lowercase | none | inherit",
+ "text-wrap" : "normal | none | avoid",
+ "top" : "<margin-width> | inherit",
+ "-ms-touch-action" : "auto | none | pan-x | pan-y",
+ "touch-action" : "auto | none | pan-x | pan-y",
+ "transform" : 1,
+ "transform-origin" : 1,
+ "transform-style" : 1,
+ "transition" : 1,
+ "transition-delay" : 1,
+ "transition-duration" : 1,
+ "transition-property" : 1,
+ "transition-timing-function" : 1,
+ "unicode-bidi" : "normal | embed | isolate | bidi-override | isolate-override | plaintext | inherit",
+ "user-modify" : "read-only | read-write | write-only | inherit",
+ "user-select" : "none | text | toggle | element | elements | all | inherit",
+ "vertical-align" : "auto | use-script | baseline | sub | super | top | text-top | central | middle | bottom | text-bottom | <percentage> | <length>",
+ "visibility" : "visible | hidden | collapse | inherit",
+ "voice-balance" : 1,
+ "voice-duration" : 1,
+ "voice-family" : 1,
+ "voice-pitch" : 1,
+ "voice-pitch-range" : 1,
+ "voice-rate" : 1,
+ "voice-stress" : 1,
+ "voice-volume" : 1,
+ "volume" : 1,
+ "white-space" : "normal | pre | nowrap | pre-wrap | pre-line | inherit | -pre-wrap | -o-pre-wrap | -moz-pre-wrap | -hp-pre-wrap", //http://perishablepress.com/wrapping-content/
+ "white-space-collapse" : 1,
+ "widows" : "<integer> | inherit",
+ "width" : "<length> | <percentage> | <content-sizing> | auto | inherit",
+ "word-break" : "normal | keep-all | break-all",
+ "word-spacing" : "<length> | normal | inherit",
+ "word-wrap" : "normal | break-word",
+ "writing-mode" : "horizontal-tb | vertical-rl | vertical-lr | lr-tb | rl-tb | tb-rl | bt-rl | tb-lr | bt-lr | lr-bt | rl-bt | lr | rl | tb | inherit",
+ "z-index" : "<integer> | auto | inherit",
+ "zoom" : "<number> | <percentage> | normal"
+};
+function PropertyName(text, hack, line, col){
+
+ SyntaxUnit.call(this, text, line, col, Parser.PROPERTY_NAME_TYPE);
+ this.hack = hack;
+
+}
+
+PropertyName.prototype = new SyntaxUnit();
+PropertyName.prototype.constructor = PropertyName;
+PropertyName.prototype.toString = function(){
+ return (this.hack ? this.hack : "") + this.text;
+};
+function PropertyValue(parts, line, col){
+
+ SyntaxUnit.call(this, parts.join(" "), line, col, Parser.PROPERTY_VALUE_TYPE);
+ this.parts = parts;
+
+}
+
+PropertyValue.prototype = new SyntaxUnit();
+PropertyValue.prototype.constructor = PropertyValue;
+function PropertyValueIterator(value){
+ this._i = 0;
+ this._parts = value.parts;
+ this._marks = [];
+ this.value = value;
+
+}
+PropertyValueIterator.prototype.count = function(){
+ return this._parts.length;
+};
+PropertyValueIterator.prototype.isFirst = function(){
+ return this._i === 0;
+};
+PropertyValueIterator.prototype.hasNext = function(){
+ return (this._i < this._parts.length);
+};
+PropertyValueIterator.prototype.mark = function(){
+ this._marks.push(this._i);
+};
+PropertyValueIterator.prototype.peek = function(count){
+ return this.hasNext() ? this._parts[this._i + (count || 0)] : null;
+};
+PropertyValueIterator.prototype.next = function(){
+ return this.hasNext() ? this._parts[this._i++] : null;
+};
+PropertyValueIterator.prototype.previous = function(){
+ return this._i > 0 ? this._parts[--this._i] : null;
+};
+PropertyValueIterator.prototype.restore = function(){
+ if (this._marks.length){
+ this._i = this._marks.pop();
+ }
+};
+function PropertyValuePart(text, line, col){
+
+ SyntaxUnit.call(this, text, line, col, Parser.PROPERTY_VALUE_PART_TYPE);
+ this.type = "unknown";
+
+ var temp;
+ if (/^([+\-]?[\d\.]+)([a-z]+)$/i.test(text)){ //dimension
+ this.type = "dimension";
+ this.value = +RegExp.$1;
+ this.units = RegExp.$2;
+ switch(this.units.toLowerCase()){
+
+ case "em":
+ case "rem":
+ case "ex":
+ case "px":
+ case "cm":
+ case "mm":
+ case "in":
+ case "pt":
+ case "pc":
+ case "ch":
+ case "vh":
+ case "vw":
+ case "vmax":
+ case "vmin":
+ this.type = "length";
+ break;
+
+ case "deg":
+ case "rad":
+ case "grad":
+ this.type = "angle";
+ break;
+
+ case "ms":
+ case "s":
+ this.type = "time";
+ break;
+
+ case "hz":
+ case "khz":
+ this.type = "frequency";
+ break;
+
+ case "dpi":
+ case "dpcm":
+ this.type = "resolution";
+ break;
+
+ }
+
+ } else if (/^([+\-]?[\d\.]+)%$/i.test(text)){ //percentage
+ this.type = "percentage";
+ this.value = +RegExp.$1;
+ } else if (/^([+\-]?\d+)$/i.test(text)){ //integer
+ this.type = "integer";
+ this.value = +RegExp.$1;
+ } else if (/^([+\-]?[\d\.]+)$/i.test(text)){ //number
+ this.type = "number";
+ this.value = +RegExp.$1;
+
+ } else if (/^#([a-f0-9]{3,6})/i.test(text)){ //hexcolor
+ this.type = "color";
+ temp = RegExp.$1;
+ if (temp.length == 3){
+ this.red = parseInt(temp.charAt(0)+temp.charAt(0),16);
+ this.green = parseInt(temp.charAt(1)+temp.charAt(1),16);
+ this.blue = parseInt(temp.charAt(2)+temp.charAt(2),16);
+ } else {
+ this.red = parseInt(temp.substring(0,2),16);
+ this.green = parseInt(temp.substring(2,4),16);
+ this.blue = parseInt(temp.substring(4,6),16);
+ }
+ } else if (/^rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/i.test(text)){ //rgb() color with absolute numbers
+ this.type = "color";
+ this.red = +RegExp.$1;
+ this.green = +RegExp.$2;
+ this.blue = +RegExp.$3;
+ } else if (/^rgb\(\s*(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*\)/i.test(text)){ //rgb() color with percentages
+ this.type = "color";
+ this.red = +RegExp.$1 * 255 / 100;
+ this.green = +RegExp.$2 * 255 / 100;
+ this.blue = +RegExp.$3 * 255 / 100;
+ } else if (/^rgba\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*([\d\.]+)\s*\)/i.test(text)){ //rgba() color with absolute numbers
+ this.type = "color";
+ this.red = +RegExp.$1;
+ this.green = +RegExp.$2;
+ this.blue = +RegExp.$3;
+ this.alpha = +RegExp.$4;
+ } else if (/^rgba\(\s*(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*,\s*([\d\.]+)\s*\)/i.test(text)){ //rgba() color with percentages
+ this.type = "color";
+ this.red = +RegExp.$1 * 255 / 100;
+ this.green = +RegExp.$2 * 255 / 100;
+ this.blue = +RegExp.$3 * 255 / 100;
+ this.alpha = +RegExp.$4;
+ } else if (/^hsl\(\s*(\d+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*\)/i.test(text)){ //hsl()
+ this.type = "color";
+ this.hue = +RegExp.$1;
+ this.saturation = +RegExp.$2 / 100;
+ this.lightness = +RegExp.$3 / 100;
+ } else if (/^hsla\(\s*(\d+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*,\s*([\d\.]+)\s*\)/i.test(text)){ //hsla() color with percentages
+ this.type = "color";
+ this.hue = +RegExp.$1;
+ this.saturation = +RegExp.$2 / 100;
+ this.lightness = +RegExp.$3 / 100;
+ this.alpha = +RegExp.$4;
+ } else if (/^url\(["']?([^\)"']+)["']?\)/i.test(text)){ //URI
+ this.type = "uri";
+ this.uri = RegExp.$1;
+ } else if (/^([^\(]+)\(/i.test(text)){
+ this.type = "function";
+ this.name = RegExp.$1;
+ this.value = text;
+ } else if (/^["'][^"']*["']/.test(text)){ //string
+ this.type = "string";
+ this.value = eval(text);
+ } else if (Colors[text.toLowerCase()]){ //named color
+ this.type = "color";
+ temp = Colors[text.toLowerCase()].substring(1);
+ this.red = parseInt(temp.substring(0,2),16);
+ this.green = parseInt(temp.substring(2,4),16);
+ this.blue = parseInt(temp.substring(4,6),16);
+ } else if (/^[\,\/]$/.test(text)){
+ this.type = "operator";
+ this.value = text;
+ } else if (/^[a-z\-_\u0080-\uFFFF][a-z0-9\-_\u0080-\uFFFF]*$/i.test(text)){
+ this.type = "identifier";
+ this.value = text;
+ }
+
+}
+
+PropertyValuePart.prototype = new SyntaxUnit();
+PropertyValuePart.prototype.constructor = PropertyValuePart;
+PropertyValuePart.fromToken = function(token){
+ return new PropertyValuePart(token.value, token.startLine, token.startCol);
+};
+var Pseudos = {
+ ":first-letter": 1,
+ ":first-line": 1,
+ ":before": 1,
+ ":after": 1
+};
+
+Pseudos.ELEMENT = 1;
+Pseudos.CLASS = 2;
+
+Pseudos.isElement = function(pseudo){
+ return pseudo.indexOf("::") === 0 || Pseudos[pseudo.toLowerCase()] == Pseudos.ELEMENT;
+};
+function Selector(parts, line, col){
+
+ SyntaxUnit.call(this, parts.join(" "), line, col, Parser.SELECTOR_TYPE);
+ this.parts = parts;
+ this.specificity = Specificity.calculate(this);
+
+}
+
+Selector.prototype = new SyntaxUnit();
+Selector.prototype.constructor = Selector;
+function SelectorPart(elementName, modifiers, text, line, col){
+
+ SyntaxUnit.call(this, text, line, col, Parser.SELECTOR_PART_TYPE);
+ this.elementName = elementName;
+ this.modifiers = modifiers;
+
+}
+
+SelectorPart.prototype = new SyntaxUnit();
+SelectorPart.prototype.constructor = SelectorPart;
+function SelectorSubPart(text, type, line, col){
+
+ SyntaxUnit.call(this, text, line, col, Parser.SELECTOR_SUB_PART_TYPE);
+ this.type = type;
+ this.args = [];
+
+}
+
+SelectorSubPart.prototype = new SyntaxUnit();
+SelectorSubPart.prototype.constructor = SelectorSubPart;
+function Specificity(a, b, c, d){
+ this.a = a;
+ this.b = b;
+ this.c = c;
+ this.d = d;
+}
+
+Specificity.prototype = {
+ constructor: Specificity,
+ compare: function(other){
+ var comps = ["a", "b", "c", "d"],
+ i, len;
+
+ for (i=0, len=comps.length; i < len; i++){
+ if (this[comps[i]] < other[comps[i]]){
+ return -1;
+ } else if (this[comps[i]] > other[comps[i]]){
+ return 1;
+ }
+ }
+
+ return 0;
+ },
+ valueOf: function(){
+ return (this.a * 1000) + (this.b * 100) + (this.c * 10) + this.d;
+ },
+ toString: function(){
+ return this.a + "," + this.b + "," + this.c + "," + this.d;
+ }
+
+};
+Specificity.calculate = function(selector){
+
+ var i, len,
+ part,
+ b=0, c=0, d=0;
+
+ function updateValues(part){
+
+ var i, j, len, num,
+ elementName = part.elementName ? part.elementName.text : "",
+ modifier;
+
+ if (elementName && elementName.charAt(elementName.length-1) != "*") {
+ d++;
+ }
+
+ for (i=0, len=part.modifiers.length; i < len; i++){
+ modifier = part.modifiers[i];
+ switch(modifier.type){
+ case "class":
+ case "attribute":
+ c++;
+ break;
+
+ case "id":
+ b++;
+ break;
+
+ case "pseudo":
+ if (Pseudos.isElement(modifier.text)){
+ d++;
+ } else {
+ c++;
+ }
+ break;
+
+ case "not":
+ for (j=0, num=modifier.args.length; j < num; j++){
+ updateValues(modifier.args[j]);
+ }
+ }
+ }
+ }
+
+ for (i=0, len=selector.parts.length; i < len; i++){
+ part = selector.parts[i];
+
+ if (part instanceof SelectorPart){
+ updateValues(part);
+ }
+ }
+
+ return new Specificity(0, b, c, d);
+};
+
+var h = /^[0-9a-fA-F]$/,
+ nonascii = /^[\u0080-\uFFFF]$/,
+ nl = /\n|\r\n|\r|\f/;
+
+
+function isHexDigit(c){
+ return c !== null && h.test(c);
+}
+
+function isDigit(c){
+ return c !== null && /\d/.test(c);
+}
+
+function isWhitespace(c){
+ return c !== null && /\s/.test(c);
+}
+
+function isNewLine(c){
+ return c !== null && nl.test(c);
+}
+
+function isNameStart(c){
+ return c !== null && (/[a-z_\u0080-\uFFFF\\]/i.test(c));
+}
+
+function isNameChar(c){
+ return c !== null && (isNameStart(c) || /[0-9\-\\]/.test(c));
+}
+
+function isIdentStart(c){
+ return c !== null && (isNameStart(c) || /\-\\/.test(c));
+}
+
+function mix(receiver, supplier){
+ for (var prop in supplier){
+ if (supplier.hasOwnProperty(prop)){
+ receiver[prop] = supplier[prop];
+ }
+ }
+ return receiver;
+}
+function TokenStream(input){
+ TokenStreamBase.call(this, input, Tokens);
+}
+
+TokenStream.prototype = mix(new TokenStreamBase(), {
+ _getToken: function(channel){
+
+ var c,
+ reader = this._reader,
+ token = null,
+ startLine = reader.getLine(),
+ startCol = reader.getCol();
+
+ c = reader.read();
+
+
+ while(c){
+ switch(c){
+ case "/":
+
+ if(reader.peek() == "*"){
+ token = this.commentToken(c, startLine, startCol);
+ } else {
+ token = this.charToken(c, startLine, startCol);
+ }
+ break;
+ case "|":
+ case "~":
+ case "^":
+ case "$":
+ case "*":
+ if(reader.peek() == "="){
+ token = this.comparisonToken(c, startLine, startCol);
+ } else {
+ token = this.charToken(c, startLine, startCol);
+ }
+ break;
+ case "\"":
+ case "'":
+ token = this.stringToken(c, startLine, startCol);
+ break;
+ case "#":
+ if (isNameChar(reader.peek())){
+ token = this.hashToken(c, startLine, startCol);
+ } else {
+ token = this.charToken(c, startLine, startCol);
+ }
+ break;
+ case ".":
+ if (isDigit(reader.peek())){
+ token = this.numberToken(c, startLine, startCol);
+ } else {
+ token = this.charToken(c, startLine, startCol);
+ }
+ break;
+ case "-":
+ if (reader.peek() == "-"){ //could be closing HTML-style comment
+ token = this.htmlCommentEndToken(c, startLine, startCol);
+ } else if (isNameStart(reader.peek())){
+ token = this.identOrFunctionToken(c, startLine, startCol);
+ } else {
+ token = this.charToken(c, startLine, startCol);
+ }
+ break;
+ case "!":
+ token = this.importantToken(c, startLine, startCol);
+ break;
+ case "@":
+ token = this.atRuleToken(c, startLine, startCol);
+ break;
+ case ":":
+ token = this.notToken(c, startLine, startCol);
+ break;
+ case "<":
+ token = this.htmlCommentStartToken(c, startLine, startCol);
+ break;
+ case "U":
+ case "u":
+ if (reader.peek() == "+"){
+ token = this.unicodeRangeToken(c, startLine, startCol);
+ break;
+ }
+ default:
+ if (isDigit(c)){
+ token = this.numberToken(c, startLine, startCol);
+ } else
+ if (isWhitespace(c)){
+ token = this.whitespaceToken(c, startLine, startCol);
+ } else
+ if (isIdentStart(c)){
+ token = this.identOrFunctionToken(c, startLine, startCol);
+ } else
+ {
+ token = this.charToken(c, startLine, startCol);
+ }
+
+
+
+
+
+
+ }
+ break;
+ }
+
+ if (!token && c === null){
+ token = this.createToken(Tokens.EOF,null,startLine,startCol);
+ }
+
+ return token;
+ },
+ createToken: function(tt, value, startLine, startCol, options){
+ var reader = this._reader;
+ options = options || {};
+
+ return {
+ value: value,
+ type: tt,
+ channel: options.channel,
+ endChar: options.endChar,
+ hide: options.hide || false,
+ startLine: startLine,
+ startCol: startCol,
+ endLine: reader.getLine(),
+ endCol: reader.getCol()
+ };
+ },
+ atRuleToken: function(first, startLine, startCol){
+ var rule = first,
+ reader = this._reader,
+ tt = Tokens.CHAR,
+ valid = false,
+ ident,
+ c;
+ reader.mark();
+ ident = this.readName();
+ rule = first + ident;
+ tt = Tokens.type(rule.toLowerCase());
+ if (tt == Tokens.CHAR || tt == Tokens.UNKNOWN){
+ if (rule.length > 1){
+ tt = Tokens.UNKNOWN_SYM;
+ } else {
+ tt = Tokens.CHAR;
+ rule = first;
+ reader.reset();
+ }
+ }
+
+ return this.createToken(tt, rule, startLine, startCol);
+ },
+ charToken: function(c, startLine, startCol){
+ var tt = Tokens.type(c);
+ var opts = {};
+
+ if (tt == -1){
+ tt = Tokens.CHAR;
+ } else {
+ opts.endChar = Tokens[tt].endChar;
+ }
+
+ return this.createToken(tt, c, startLine, startCol, opts);
+ },
+ commentToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ comment = this.readComment(first);
+
+ return this.createToken(Tokens.COMMENT, comment, startLine, startCol);
+ },
+ comparisonToken: function(c, startLine, startCol){
+ var reader = this._reader,
+ comparison = c + reader.read(),
+ tt = Tokens.type(comparison) || Tokens.CHAR;
+
+ return this.createToken(tt, comparison, startLine, startCol);
+ },
+ hashToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ name = this.readName(first);
+
+ return this.createToken(Tokens.HASH, name, startLine, startCol);
+ },
+ htmlCommentStartToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ text = first;
+
+ reader.mark();
+ text += reader.readCount(3);
+
+ if (text == "<!--"){
+ return this.createToken(Tokens.CDO, text, startLine, startCol);
+ } else {
+ reader.reset();
+ return this.charToken(first, startLine, startCol);
+ }
+ },
+ htmlCommentEndToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ text = first;
+
+ reader.mark();
+ text += reader.readCount(2);
+
+ if (text == "-->"){
+ return this.createToken(Tokens.CDC, text, startLine, startCol);
+ } else {
+ reader.reset();
+ return this.charToken(first, startLine, startCol);
+ }
+ },
+ identOrFunctionToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ ident = this.readName(first),
+ tt = Tokens.IDENT;
+ if (reader.peek() == "("){
+ ident += reader.read();
+ if (ident.toLowerCase() == "url("){
+ tt = Tokens.URI;
+ ident = this.readURI(ident);
+ if (ident.toLowerCase() == "url("){
+ tt = Tokens.FUNCTION;
+ }
+ } else {
+ tt = Tokens.FUNCTION;
+ }
+ } else if (reader.peek() == ":"){ //might be an IE function
+ if (ident.toLowerCase() == "progid"){
+ ident += reader.readTo("(");
+ tt = Tokens.IE_FUNCTION;
+ }
+ }
+
+ return this.createToken(tt, ident, startLine, startCol);
+ },
+ importantToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ important = first,
+ tt = Tokens.CHAR,
+ temp,
+ c;
+
+ reader.mark();
+ c = reader.read();
+
+ while(c){
+ if (c == "/"){
+ if (reader.peek() != "*"){
+ break;
+ } else {
+ temp = this.readComment(c);
+ if (temp === ""){ //broken!
+ break;
+ }
+ }
+ } else if (isWhitespace(c)){
+ important += c + this.readWhitespace();
+ } else if (/i/i.test(c)){
+ temp = reader.readCount(8);
+ if (/mportant/i.test(temp)){
+ important += c + temp;
+ tt = Tokens.IMPORTANT_SYM;
+
+ }
+ break; //we're done
+ } else {
+ break;
+ }
+
+ c = reader.read();
+ }
+
+ if (tt == Tokens.CHAR){
+ reader.reset();
+ return this.charToken(first, startLine, startCol);
+ } else {
+ return this.createToken(tt, important, startLine, startCol);
+ }
+
+
+ },
+ notToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ text = first;
+
+ reader.mark();
+ text += reader.readCount(4);
+
+ if (text.toLowerCase() == ":not("){
+ return this.createToken(Tokens.NOT, text, startLine, startCol);
+ } else {
+ reader.reset();
+ return this.charToken(first, startLine, startCol);
+ }
+ },
+ numberToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ value = this.readNumber(first),
+ ident,
+ tt = Tokens.NUMBER,
+ c = reader.peek();
+
+ if (isIdentStart(c)){
+ ident = this.readName(reader.read());
+ value += ident;
+
+ if (/^em$|^ex$|^px$|^gd$|^rem$|^vw$|^vh$|^vmax$|^vmin$|^ch$|^cm$|^mm$|^in$|^pt$|^pc$/i.test(ident)){
+ tt = Tokens.LENGTH;
+ } else if (/^deg|^rad$|^grad$/i.test(ident)){
+ tt = Tokens.ANGLE;
+ } else if (/^ms$|^s$/i.test(ident)){
+ tt = Tokens.TIME;
+ } else if (/^hz$|^khz$/i.test(ident)){
+ tt = Tokens.FREQ;
+ } else if (/^dpi$|^dpcm$/i.test(ident)){
+ tt = Tokens.RESOLUTION;
+ } else {
+ tt = Tokens.DIMENSION;
+ }
+
+ } else if (c == "%"){
+ value += reader.read();
+ tt = Tokens.PERCENTAGE;
+ }
+
+ return this.createToken(tt, value, startLine, startCol);
+ },
+ stringToken: function(first, startLine, startCol){
+ var delim = first,
+ string = first,
+ reader = this._reader,
+ prev = first,
+ tt = Tokens.STRING,
+ c = reader.read();
+
+ while(c){
+ string += c;
+ if (c == delim && prev != "\\"){
+ break;
+ }
+ if (isNewLine(reader.peek()) && c != "\\"){
+ tt = Tokens.INVALID;
+ break;
+ }
+ prev = c;
+ c = reader.read();
+ }
+ if (c === null){
+ tt = Tokens.INVALID;
+ }
+
+ return this.createToken(tt, string, startLine, startCol);
+ },
+
+ unicodeRangeToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ value = first,
+ temp,
+ tt = Tokens.CHAR;
+ if (reader.peek() == "+"){
+ reader.mark();
+ value += reader.read();
+ value += this.readUnicodeRangePart(true);
+ if (value.length == 2){
+ reader.reset();
+ } else {
+
+ tt = Tokens.UNICODE_RANGE;
+ if (value.indexOf("?") == -1){
+
+ if (reader.peek() == "-"){
+ reader.mark();
+ temp = reader.read();
+ temp += this.readUnicodeRangePart(false);
+ if (temp.length == 1){
+ reader.reset();
+ } else {
+ value += temp;
+ }
+ }
+
+ }
+ }
+ }
+
+ return this.createToken(tt, value, startLine, startCol);
+ },
+ whitespaceToken: function(first, startLine, startCol){
+ var reader = this._reader,
+ value = first + this.readWhitespace();
+ return this.createToken(Tokens.S, value, startLine, startCol);
+ },
+
+ readUnicodeRangePart: function(allowQuestionMark){
+ var reader = this._reader,
+ part = "",
+ c = reader.peek();
+ while(isHexDigit(c) && part.length < 6){
+ reader.read();
+ part += c;
+ c = reader.peek();
+ }
+ if (allowQuestionMark){
+ while(c == "?" && part.length < 6){
+ reader.read();
+ part += c;
+ c = reader.peek();
+ }
+ }
+
+ return part;
+ },
+
+ readWhitespace: function(){
+ var reader = this._reader,
+ whitespace = "",
+ c = reader.peek();
+
+ while(isWhitespace(c)){
+ reader.read();
+ whitespace += c;
+ c = reader.peek();
+ }
+
+ return whitespace;
+ },
+ readNumber: function(first){
+ var reader = this._reader,
+ number = first,
+ hasDot = (first == "."),
+ c = reader.peek();
+
+
+ while(c){
+ if (isDigit(c)){
+ number += reader.read();
+ } else if (c == "."){
+ if (hasDot){
+ break;
+ } else {
+ hasDot = true;
+ number += reader.read();
+ }
+ } else {
+ break;
+ }
+
+ c = reader.peek();
+ }
+
+ return number;
+ },
+ readString: function(){
+ var reader = this._reader,
+ delim = reader.read(),
+ string = delim,
+ prev = delim,
+ c = reader.peek();
+
+ while(c){
+ c = reader.read();
+ string += c;
+ if (c == delim && prev != "\\"){
+ break;
+ }
+ if (isNewLine(reader.peek()) && c != "\\"){
+ string = "";
+ break;
+ }
+ prev = c;
+ c = reader.peek();
+ }
+ if (c === null){
+ string = "";
+ }
+
+ return string;
+ },
+ readURI: function(first){
+ var reader = this._reader,
+ uri = first,
+ inner = "",
+ c = reader.peek();
+
+ reader.mark();
+ while(c && isWhitespace(c)){
+ reader.read();
+ c = reader.peek();
+ }
+ if (c == "'" || c == "\""){
+ inner = this.readString();
+ } else {
+ inner = this.readURL();
+ }
+
+ c = reader.peek();
+ while(c && isWhitespace(c)){
+ reader.read();
+ c = reader.peek();
+ }
+ if (inner === "" || c != ")"){
+ uri = first;
+ reader.reset();
+ } else {
+ uri += inner + reader.read();
+ }
+
+ return uri;
+ },
+ readURL: function(){
+ var reader = this._reader,
+ url = "",
+ c = reader.peek();
+ while (/^[!#$%&\\*-~]$/.test(c)){
+ url += reader.read();
+ c = reader.peek();
+ }
+
+ return url;
+
+ },
+ readName: function(first){
+ var reader = this._reader,
+ ident = first || "",
+ c = reader.peek();
+
+ while(true){
+ if (c == "\\"){
+ ident += this.readEscape(reader.read());
+ c = reader.peek();
+ } else if(c && isNameChar(c)){
+ ident += reader.read();
+ c = reader.peek();
+ } else {
+ break;
+ }
+ }
+
+ return ident;
+ },
+
+ readEscape: function(first){
+ var reader = this._reader,
+ cssEscape = first || "",
+ i = 0,
+ c = reader.peek();
+
+ if (isHexDigit(c)){
+ do {
+ cssEscape += reader.read();
+ c = reader.peek();
+ } while(c && isHexDigit(c) && ++i < 6);
+ }
+
+ if (cssEscape.length == 3 && /\s/.test(c) ||
+ cssEscape.length == 7 || cssEscape.length == 1){
+ reader.read();
+ } else {
+ c = "";
+ }
+
+ return cssEscape + c;
+ },
+
+ readComment: function(first){
+ var reader = this._reader,
+ comment = first || "",
+ c = reader.read();
+
+ if (c == "*"){
+ while(c){
+ comment += c;
+ if (comment.length > 2 && c == "*" && reader.peek() == "/"){
+ comment += reader.read();
+ break;
+ }
+
+ c = reader.read();
+ }
+
+ return comment;
+ } else {
+ return "";
+ }
+
+ }
+});
+
+var Tokens = [
+ { name: "CDO"},
+ { name: "CDC"},
+ { name: "S", whitespace: true/*, channel: "ws"*/},
+ { name: "COMMENT", comment: true, hide: true, channel: "comment" },
+ { name: "INCLUDES", text: "~="},
+ { name: "DASHMATCH", text: "|="},
+ { name: "PREFIXMATCH", text: "^="},
+ { name: "SUFFIXMATCH", text: "$="},
+ { name: "SUBSTRINGMATCH", text: "*="},
+ { name: "STRING"},
+ { name: "IDENT"},
+ { name: "HASH"},
+ { name: "IMPORT_SYM", text: "@import"},
+ { name: "PAGE_SYM", text: "@page"},
+ { name: "MEDIA_SYM", text: "@media"},
+ { name: "FONT_FACE_SYM", text: "@font-face"},
+ { name: "CHARSET_SYM", text: "@charset"},
+ { name: "NAMESPACE_SYM", text: "@namespace"},
+ { name: "VIEWPORT_SYM", text: ["@viewport", "@-ms-viewport"]},
+ { name: "UNKNOWN_SYM" },
+ { name: "KEYFRAMES_SYM", text: [ "@keyframes", "@-webkit-keyframes", "@-moz-keyframes", "@-o-keyframes" ] },
+ { name: "IMPORTANT_SYM"},
+ { name: "LENGTH"},
+ { name: "ANGLE"},
+ { name: "TIME"},
+ { name: "FREQ"},
+ { name: "DIMENSION"},
+ { name: "PERCENTAGE"},
+ { name: "NUMBER"},
+ { name: "URI"},
+ { name: "FUNCTION"},
+ { name: "UNICODE_RANGE"},
+ { name: "INVALID"},
+ { name: "PLUS", text: "+" },
+ { name: "GREATER", text: ">"},
+ { name: "COMMA", text: ","},
+ { name: "TILDE", text: "~"},
+ { name: "NOT"},
+ { name: "TOPLEFTCORNER_SYM", text: "@top-left-corner"},
+ { name: "TOPLEFT_SYM", text: "@top-left"},
+ { name: "TOPCENTER_SYM", text: "@top-center"},
+ { name: "TOPRIGHT_SYM", text: "@top-right"},
+ { name: "TOPRIGHTCORNER_SYM", text: "@top-right-corner"},
+ { name: "BOTTOMLEFTCORNER_SYM", text: "@bottom-left-corner"},
+ { name: "BOTTOMLEFT_SYM", text: "@bottom-left"},
+ { name: "BOTTOMCENTER_SYM", text: "@bottom-center"},
+ { name: "BOTTOMRIGHT_SYM", text: "@bottom-right"},
+ { name: "BOTTOMRIGHTCORNER_SYM", text: "@bottom-right-corner"},
+ { name: "LEFTTOP_SYM", text: "@left-top"},
+ { name: "LEFTMIDDLE_SYM", text: "@left-middle"},
+ { name: "LEFTBOTTOM_SYM", text: "@left-bottom"},
+ { name: "RIGHTTOP_SYM", text: "@right-top"},
+ { name: "RIGHTMIDDLE_SYM", text: "@right-middle"},
+ { name: "RIGHTBOTTOM_SYM", text: "@right-bottom"},
+ { name: "RESOLUTION", state: "media"},
+ { name: "IE_FUNCTION" },
+ { name: "CHAR" },
+ {
+ name: "PIPE",
+ text: "|"
+ },
+ {
+ name: "SLASH",
+ text: "/"
+ },
+ {
+ name: "MINUS",
+ text: "-"
+ },
+ {
+ name: "STAR",
+ text: "*"
+ },
+
+ {
+ name: "LBRACE",
+ endChar: "}",
+ text: "{"
+ },
+ {
+ name: "RBRACE",
+ text: "}"
+ },
+ {
+ name: "LBRACKET",
+ endChar: "]",
+ text: "["
+ },
+ {
+ name: "RBRACKET",
+ text: "]"
+ },
+ {
+ name: "EQUALS",
+ text: "="
+ },
+ {
+ name: "COLON",
+ text: ":"
+ },
+ {
+ name: "SEMICOLON",
+ text: ";"
+ },
+
+ {
+ name: "LPAREN",
+ endChar: ")",
+ text: "("
+ },
+ {
+ name: "RPAREN",
+ text: ")"
+ },
+ {
+ name: "DOT",
+ text: "."
+ }
+];
+
+(function(){
+
+ var nameMap = [],
+ typeMap = {};
+
+ Tokens.UNKNOWN = -1;
+ Tokens.unshift({name:"EOF"});
+ for (var i=0, len = Tokens.length; i < len; i++){
+ nameMap.push(Tokens[i].name);
+ Tokens[Tokens[i].name] = i;
+ if (Tokens[i].text){
+ if (Tokens[i].text instanceof Array){
+ for (var j=0; j < Tokens[i].text.length; j++){
+ typeMap[Tokens[i].text[j]] = i;
+ }
+ } else {
+ typeMap[Tokens[i].text] = i;
+ }
+ }
+ }
+
+ Tokens.name = function(tt){
+ return nameMap[tt];
+ };
+
+ Tokens.type = function(c){
+ return typeMap[c] || -1;
+ };
+
+})();
+var Validation = {
+
+ validate: function(property, value){
+ var name = property.toString().toLowerCase(),
+ parts = value.parts,
+ expression = new PropertyValueIterator(value),
+ spec = Properties[name],
+ part,
+ valid,
+ j, count,
+ msg,
+ types,
+ last,
+ literals,
+ max, multi, group;
+
+ if (!spec) {
+ if (name.indexOf("-") !== 0){ //vendor prefixed are ok
+ throw new ValidationError("Unknown property '" + property + "'.", property.line, property.col);
+ }
+ } else if (typeof spec != "number"){
+ if (typeof spec == "string"){
+ if (spec.indexOf("||") > -1) {
+ this.groupProperty(spec, expression);
+ } else {
+ this.singleProperty(spec, expression, 1);
+ }
+
+ } else if (spec.multi) {
+ this.multiProperty(spec.multi, expression, spec.comma, spec.max || Infinity);
+ } else if (typeof spec == "function") {
+ spec(expression);
+ }
+
+ }
+
+ },
+
+ singleProperty: function(types, expression, max, partial) {
+
+ var result = false,
+ value = expression.value,
+ count = 0,
+ part;
+
+ while (expression.hasNext() && count < max) {
+ result = ValidationTypes.isAny(expression, types);
+ if (!result) {
+ break;
+ }
+ count++;
+ }
+
+ if (!result) {
+ if (expression.hasNext() && !expression.isFirst()) {
+ part = expression.peek();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ throw new ValidationError("Expected (" + types + ") but found '" + value + "'.", value.line, value.col);
+ }
+ } else if (expression.hasNext()) {
+ part = expression.next();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ }
+
+ },
+
+ multiProperty: function (types, expression, comma, max) {
+
+ var result = false,
+ value = expression.value,
+ count = 0,
+ sep = false,
+ part;
+
+ while(expression.hasNext() && !result && count < max) {
+ if (ValidationTypes.isAny(expression, types)) {
+ count++;
+ if (!expression.hasNext()) {
+ result = true;
+
+ } else if (comma) {
+ if (expression.peek() == ",") {
+ part = expression.next();
+ } else {
+ break;
+ }
+ }
+ } else {
+ break;
+
+ }
+ }
+
+ if (!result) {
+ if (expression.hasNext() && !expression.isFirst()) {
+ part = expression.peek();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ part = expression.previous();
+ if (comma && part == ",") {
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ throw new ValidationError("Expected (" + types + ") but found '" + value + "'.", value.line, value.col);
+ }
+ }
+
+ } else if (expression.hasNext()) {
+ part = expression.next();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ }
+
+ },
+
+ groupProperty: function (types, expression, comma) {
+
+ var result = false,
+ value = expression.value,
+ typeCount = types.split("||").length,
+ groups = { count: 0 },
+ partial = false,
+ name,
+ part;
+
+ while(expression.hasNext() && !result) {
+ name = ValidationTypes.isAnyOfGroup(expression, types);
+ if (name) {
+ if (groups[name]) {
+ break;
+ } else {
+ groups[name] = 1;
+ groups.count++;
+ partial = true;
+
+ if (groups.count == typeCount || !expression.hasNext()) {
+ result = true;
+ }
+ }
+ } else {
+ break;
+ }
+ }
+
+ if (!result) {
+ if (partial && expression.hasNext()) {
+ part = expression.peek();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ } else {
+ throw new ValidationError("Expected (" + types + ") but found '" + value + "'.", value.line, value.col);
+ }
+ } else if (expression.hasNext()) {
+ part = expression.next();
+ throw new ValidationError("Expected end of value but found '" + part + "'.", part.line, part.col);
+ }
+ }
+
+
+
+};
+function ValidationError(message, line, col){
+ this.col = col;
+ this.line = line;
+ this.message = message;
+
+}
+ValidationError.prototype = new Error();
+var ValidationTypes = {
+
+ isLiteral: function (part, literals) {
+ var text = part.text.toString().toLowerCase(),
+ args = literals.split(" | "),
+ i, len, found = false;
+
+ for (i=0,len=args.length; i < len && !found; i++){
+ if (text == args[i].toLowerCase()){
+ found = true;
+ }
+ }
+
+ return found;
+ },
+
+ isSimple: function(type) {
+ return !!this.simple[type];
+ },
+
+ isComplex: function(type) {
+ return !!this.complex[type];
+ },
+ isAny: function (expression, types) {
+ var args = types.split(" | "),
+ i, len, found = false;
+
+ for (i=0,len=args.length; i < len && !found && expression.hasNext(); i++){
+ found = this.isType(expression, args[i]);
+ }
+
+ return found;
+ },
+ isAnyOfGroup: function(expression, types) {
+ var args = types.split(" || "),
+ i, len, found = false;
+
+ for (i=0,len=args.length; i < len && !found; i++){
+ found = this.isType(expression, args[i]);
+ }
+
+ return found ? args[i-1] : false;
+ },
+ isType: function (expression, type) {
+ var part = expression.peek(),
+ result = false;
+
+ if (type.charAt(0) != "<") {
+ result = this.isLiteral(part, type);
+ if (result) {
+ expression.next();
+ }
+ } else if (this.simple[type]) {
+ result = this.simple[type](part);
+ if (result) {
+ expression.next();
+ }
+ } else {
+ result = this.complex[type](expression);
+ }
+
+ return result;
+ },
+
+
+
+ simple: {
+
+ "<absolute-size>": function(part){
+ return ValidationTypes.isLiteral(part, "xx-small | x-small | small | medium | large | x-large | xx-large");
+ },
+
+ "<attachment>": function(part){
+ return ValidationTypes.isLiteral(part, "scroll | fixed | local");
+ },
+
+ "<attr>": function(part){
+ return part.type == "function" && part.name == "attr";
+ },
+
+ "<bg-image>": function(part){
+ return this["<image>"](part) || this["<gradient>"](part) || part == "none";
+ },
+
+ "<gradient>": function(part) {
+ return part.type == "function" && /^(?:\-(?:ms|moz|o|webkit)\-)?(?:repeating\-)?(?:radial\-|linear\-)?gradient/i.test(part);
+ },
+
+ "<box>": function(part){
+ return ValidationTypes.isLiteral(part, "padding-box | border-box | content-box");
+ },
+
+ "<content>": function(part){
+ return part.type == "function" && part.name == "content";
+ },
+
+ "<relative-size>": function(part){
+ return ValidationTypes.isLiteral(part, "smaller | larger");
+ },
+ "<ident>": function(part){
+ return part.type == "identifier";
+ },
+
+ "<length>": function(part){
+ if (part.type == "function" && /^(?:\-(?:ms|moz|o|webkit)\-)?calc/i.test(part)){
+ return true;
+ }else{
+ return part.type == "length" || part.type == "number" || part.type == "integer" || part == "0";
+ }
+ },
+
+ "<color>": function(part){
+ return part.type == "color" || part == "transparent";
+ },
+
+ "<number>": function(part){
+ return part.type == "number" || this["<integer>"](part);
+ },
+
+ "<integer>": function(part){
+ return part.type == "integer";
+ },
+
+ "<line>": function(part){
+ return part.type == "integer";
+ },
+
+ "<angle>": function(part){
+ return part.type == "angle";
+ },
+
+ "<uri>": function(part){
+ return part.type == "uri";
+ },
+
+ "<image>": function(part){
+ return this["<uri>"](part);
+ },
+
+ "<percentage>": function(part){
+ return part.type == "percentage" || part == "0";
+ },
+
+ "<border-width>": function(part){
+ return this["<length>"](part) || ValidationTypes.isLiteral(part, "thin | medium | thick");
+ },
+
+ "<border-style>": function(part){
+ return ValidationTypes.isLiteral(part, "none | hidden | dotted | dashed | solid | double | groove | ridge | inset | outset");
+ },
+
+ "<content-sizing>": function(part){ // http://www.w3.org/TR/css3-sizing/#width-height-keywords
+ return ValidationTypes.isLiteral(part, "fill-available | -moz-available | -webkit-fill-available | max-content | -moz-max-content | -webkit-max-content | min-content | -moz-min-content | -webkit-min-content | fit-content | -moz-fit-content | -webkit-fit-content");
+ },
+
+ "<margin-width>": function(part){
+ return this["<length>"](part) || this["<percentage>"](part) || ValidationTypes.isLiteral(part, "auto");
+ },
+
+ "<padding-width>": function(part){
+ return this["<length>"](part) || this["<percentage>"](part);
+ },
+
+ "<shape>": function(part){
+ return part.type == "function" && (part.name == "rect" || part.name == "inset-rect");
+ },
+
+ "<time>": function(part) {
+ return part.type == "time";
+ },
+
+ "<flex-grow>": function(part){
+ return this["<number>"](part);
+ },
+
+ "<flex-shrink>": function(part){
+ return this["<number>"](part);
+ },
+
+ "<width>": function(part){
+ return this["<margin-width>"](part);
+ },
+
+ "<flex-basis>": function(part){
+ return this["<width>"](part);
+ },
+
+ "<flex-direction>": function(part){
+ return ValidationTypes.isLiteral(part, "row | row-reverse | column | column-reverse");
+ },
+
+ "<flex-wrap>": function(part){
+ return ValidationTypes.isLiteral(part, "nowrap | wrap | wrap-reverse");
+ }
+ },
+
+ complex: {
+
+ "<bg-position>": function(expression){
+ var types = this,
+ result = false,
+ numeric = "<percentage> | <length>",
+ xDir = "left | right",
+ yDir = "top | bottom",
+ count = 0,
+ hasNext = function() {
+ return expression.hasNext() && expression.peek() != ",";
+ };
+
+ while (expression.peek(count) && expression.peek(count) != ",") {
+ count++;
+ }
+
+ if (count < 3) {
+ if (ValidationTypes.isAny(expression, xDir + " | center | " + numeric)) {
+ result = true;
+ ValidationTypes.isAny(expression, yDir + " | center | " + numeric);
+ } else if (ValidationTypes.isAny(expression, yDir)) {
+ result = true;
+ ValidationTypes.isAny(expression, xDir + " | center");
+ }
+ } else {
+ if (ValidationTypes.isAny(expression, xDir)) {
+ if (ValidationTypes.isAny(expression, yDir)) {
+ result = true;
+ ValidationTypes.isAny(expression, numeric);
+ } else if (ValidationTypes.isAny(expression, numeric)) {
+ if (ValidationTypes.isAny(expression, yDir)) {
+ result = true;
+ ValidationTypes.isAny(expression, numeric);
+ } else if (ValidationTypes.isAny(expression, "center")) {
+ result = true;
+ }
+ }
+ } else if (ValidationTypes.isAny(expression, yDir)) {
+ if (ValidationTypes.isAny(expression, xDir)) {
+ result = true;
+ ValidationTypes.isAny(expression, numeric);
+ } else if (ValidationTypes.isAny(expression, numeric)) {
+ if (ValidationTypes.isAny(expression, xDir)) {
+ result = true;
+ ValidationTypes.isAny(expression, numeric);
+ } else if (ValidationTypes.isAny(expression, "center")) {
+ result = true;
+ }
+ }
+ } else if (ValidationTypes.isAny(expression, "center")) {
+ if (ValidationTypes.isAny(expression, xDir + " | " + yDir)) {
+ result = true;
+ ValidationTypes.isAny(expression, numeric);
+ }
+ }
+ }
+
+ return result;
+ },
+
+ "<bg-size>": function(expression){
+ var types = this,
+ result = false,
+ numeric = "<percentage> | <length> | auto",
+ part,
+ i, len;
+
+ if (ValidationTypes.isAny(expression, "cover | contain")) {
+ result = true;
+ } else if (ValidationTypes.isAny(expression, numeric)) {
+ result = true;
+ ValidationTypes.isAny(expression, numeric);
+ }
+
+ return result;
+ },
+
+ "<repeat-style>": function(expression){
+ var result = false,
+ values = "repeat | space | round | no-repeat",
+ part;
+
+ if (expression.hasNext()){
+ part = expression.next();
+
+ if (ValidationTypes.isLiteral(part, "repeat-x | repeat-y")) {
+ result = true;
+ } else if (ValidationTypes.isLiteral(part, values)) {
+ result = true;
+
+ if (expression.hasNext() && ValidationTypes.isLiteral(expression.peek(), values)) {
+ expression.next();
+ }
+ }
+ }
+
+ return result;
+
+ },
+
+ "<shadow>": function(expression) {
+ var result = false,
+ count = 0,
+ inset = false,
+ color = false,
+ part;
+
+ if (expression.hasNext()) {
+
+ if (ValidationTypes.isAny(expression, "inset")){
+ inset = true;
+ }
+
+ if (ValidationTypes.isAny(expression, "<color>")) {
+ color = true;
+ }
+
+ while (ValidationTypes.isAny(expression, "<length>") && count < 4) {
+ count++;
+ }
+
+
+ if (expression.hasNext()) {
+ if (!color) {
+ ValidationTypes.isAny(expression, "<color>");
+ }
+
+ if (!inset) {
+ ValidationTypes.isAny(expression, "inset");
+ }
+
+ }
+
+ result = (count >= 2 && count <= 4);
+
+ }
+
+ return result;
+ },
+
+ "<x-one-radius>": function(expression) {
+ var result = false,
+ simple = "<length> | <percentage> | inherit";
+
+ if (ValidationTypes.isAny(expression, simple)){
+ result = true;
+ ValidationTypes.isAny(expression, simple);
+ }
+
+ return result;
+ },
+
+ "<flex>": function(expression) {
+ var part,
+ result = false;
+ if (ValidationTypes.isAny(expression, "none | inherit")) {
+ result = true;
+ } else {
+ if (ValidationTypes.isType(expression, "<flex-grow>")) {
+ if (expression.peek()) {
+ if (ValidationTypes.isType(expression, "<flex-shrink>")) {
+ if (expression.peek()) {
+ result = ValidationTypes.isType(expression, "<flex-basis>");
+ } else {
+ result = true;
+ }
+ } else if (ValidationTypes.isType(expression, "<flex-basis>")) {
+ result = expression.peek() === null;
+ }
+ } else {
+ result = true;
+ }
+ } else if (ValidationTypes.isType(expression, "<flex-basis>")) {
+ result = true;
+ }
+ }
+
+ if (!result) {
+ part = expression.peek();
+ throw new ValidationError("Expected (none | [ <flex-grow> <flex-shrink>? || <flex-basis> ]) but found '" + expression.value.text + "'.", part.line, part.col);
+ }
+
+ return result;
+ }
+ }
+};
+
+parserlib.css = {
+Colors :Colors,
+Combinator :Combinator,
+Parser :Parser,
+PropertyName :PropertyName,
+PropertyValue :PropertyValue,
+PropertyValuePart :PropertyValuePart,
+MediaFeature :MediaFeature,
+MediaQuery :MediaQuery,
+Selector :Selector,
+SelectorPart :SelectorPart,
+SelectorSubPart :SelectorSubPart,
+Specificity :Specificity,
+TokenStream :TokenStream,
+Tokens :Tokens,
+ValidationError :ValidationError
+};
+})();
+
+(function(){
+for(var prop in parserlib){
+exports[prop] = parserlib[prop];
+}
+})();
+
+
+function objectToString(o) {
+ return Object.prototype.toString.call(o);
+}
+var util = {
+ isArray: function (ar) {
+ return Array.isArray(ar) || (typeof ar === 'object' && objectToString(ar) === '[object Array]');
+ },
+ isDate: function (d) {
+ return typeof d === 'object' && objectToString(d) === '[object Date]';
+ },
+ isRegExp: function (re) {
+ return typeof re === 'object' && objectToString(re) === '[object RegExp]';
+ },
+ getRegExpFlags: function (re) {
+ var flags = '';
+ re.global && (flags += 'g');
+ re.ignoreCase && (flags += 'i');
+ re.multiline && (flags += 'm');
+ return flags;
+ }
+};
+
+
+if (typeof module === 'object')
+ module.exports = clone;
+
+function clone(parent, circular, depth, prototype) {
+ var allParents = [];
+ var allChildren = [];
+
+ var useBuffer = typeof Buffer != 'undefined';
+
+ if (typeof circular == 'undefined')
+ circular = true;
+
+ if (typeof depth == 'undefined')
+ depth = Infinity;
+ function _clone(parent, depth) {
+ if (parent === null)
+ return null;
+
+ if (depth == 0)
+ return parent;
+
+ var child;
+ if (typeof parent != 'object') {
+ return parent;
+ }
+
+ if (util.isArray(parent)) {
+ child = [];
+ } else if (util.isRegExp(parent)) {
+ child = new RegExp(parent.source, util.getRegExpFlags(parent));
+ if (parent.lastIndex) child.lastIndex = parent.lastIndex;
+ } else if (util.isDate(parent)) {
+ child = new Date(parent.getTime());
+ } else if (useBuffer && Buffer.isBuffer(parent)) {
+ child = new Buffer(parent.length);
+ parent.copy(child);
+ return child;
+ } else {
+ if (typeof prototype == 'undefined') child = Object.create(Object.getPrototypeOf(parent));
+ else child = Object.create(prototype);
+ }
+
+ if (circular) {
+ var index = allParents.indexOf(parent);
+
+ if (index != -1) {
+ return allChildren[index];
+ }
+ allParents.push(parent);
+ allChildren.push(child);
+ }
+
+ for (var i in parent) {
+ child[i] = _clone(parent[i], depth - 1);
+ }
+
+ return child;
+ }
+
+ return _clone(parent, depth);
+}
+clone.clonePrototype = function(parent) {
+ if (parent === null)
+ return null;
+
+ var c = function () {};
+ c.prototype = parent;
+ return new c();
+};
+
+var CSSLint = (function(){
+
+ var rules = [],
+ formatters = [],
+ embeddedRuleset = /\/\*csslint([^\*]*)\*\//,
+ api = new parserlib.util.EventTarget();
+
+ api.version = "@VERSION@";
+ api.addRule = function(rule){
+ rules.push(rule);
+ rules[rule.id] = rule;
+ };
+ api.clearRules = function(){
+ rules = [];
+ };
+ api.getRules = function(){
+ return [].concat(rules).sort(function(a,b){
+ return a.id > b.id ? 1 : 0;
+ });
+ };
+ api.getRuleset = function() {
+ var ruleset = {},
+ i = 0,
+ len = rules.length;
+
+ while (i < len){
+ ruleset[rules[i++].id] = 1; //by default, everything is a warning
+ }
+
+ return ruleset;
+ };
+ function applyEmbeddedRuleset(text, ruleset){
+ var valueMap,
+ embedded = text && text.match(embeddedRuleset),
+ rules = embedded && embedded[1];
+
+ if (rules) {
+ valueMap = {
+ "true": 2, // true is error
+ "": 1, // blank is warning
+ "false": 0, // false is ignore
+
+ "2": 2, // explicit error
+ "1": 1, // explicit warning
+ "0": 0 // explicit ignore
+ };
+
+ rules.toLowerCase().split(",").forEach(function(rule){
+ var pair = rule.split(":"),
+ property = pair[0] || "",
+ value = pair[1] || "";
+
+ ruleset[property.trim()] = valueMap[value.trim()];
+ });
+ }
+
+ return ruleset;
+ }
+ api.addFormatter = function(formatter) {
+ formatters[formatter.id] = formatter;
+ };
+ api.getFormatter = function(formatId){
+ return formatters[formatId];
+ };
+ api.format = function(results, filename, formatId, options) {
+ var formatter = this.getFormatter(formatId),
+ result = null;
+
+ if (formatter){
+ result = formatter.startFormat();
+ result += formatter.formatResults(results, filename, options || {});
+ result += formatter.endFormat();
+ }
+
+ return result;
+ };
+ api.hasFormat = function(formatId){
+ return formatters.hasOwnProperty(formatId);
+ };
+ api.verify = function(text, ruleset){
+
+ var i = 0,
+ reporter,
+ lines,
+ report,
+ parser = new parserlib.css.Parser({ starHack: true, ieFilters: true,
+ underscoreHack: true, strict: false });
+ lines = text.replace(/\n\r?/g, "$split$").split("$split$");
+
+ if (!ruleset){
+ ruleset = this.getRuleset();
+ }
+
+ if (embeddedRuleset.test(text)){
+ ruleset = clone(ruleset);
+ ruleset = applyEmbeddedRuleset(text, ruleset);
+ }
+
+ reporter = new Reporter(lines, ruleset);
+
+ ruleset.errors = 2; //always report parsing errors as errors
+ for (i in ruleset){
+ if(ruleset.hasOwnProperty(i) && ruleset[i]){
+ if (rules[i]){
+ rules[i].init(parser, reporter);
+ }
+ }
+ }
+ try {
+ parser.parse(text);
+ } catch (ex) {
+ reporter.error("Fatal error, cannot continue: " + ex.message, ex.line, ex.col, {});
+ }
+
+ report = {
+ messages : reporter.messages,
+ stats : reporter.stats,
+ ruleset : reporter.ruleset
+ };
+ report.messages.sort(function (a, b){
+ if (a.rollup && !b.rollup){
+ return 1;
+ } else if (!a.rollup && b.rollup){
+ return -1;
+ } else {
+ return a.line - b.line;
+ }
+ });
+
+ return report;
+ };
+
+ return api;
+
+})();
+function Reporter(lines, ruleset){
+ this.messages = [];
+ this.stats = [];
+ this.lines = lines;
+ this.ruleset = ruleset;
+}
+
+Reporter.prototype = {
+ constructor: Reporter,
+ error: function(message, line, col, rule){
+ this.messages.push({
+ type : "error",
+ line : line,
+ col : col,
+ message : message,
+ evidence: this.lines[line-1],
+ rule : rule || {}
+ });
+ },
+ warn: function(message, line, col, rule){
+ this.report(message, line, col, rule);
+ },
+ report: function(message, line, col, rule){
+ this.messages.push({
+ type : this.ruleset[rule.id] === 2 ? "error" : "warning",
+ line : line,
+ col : col,
+ message : message,
+ evidence: this.lines[line-1],
+ rule : rule
+ });
+ },
+ info: function(message, line, col, rule){
+ this.messages.push({
+ type : "info",
+ line : line,
+ col : col,
+ message : message,
+ evidence: this.lines[line-1],
+ rule : rule
+ });
+ },
+ rollupError: function(message, rule){
+ this.messages.push({
+ type : "error",
+ rollup : true,
+ message : message,
+ rule : rule
+ });
+ },
+ rollupWarn: function(message, rule){
+ this.messages.push({
+ type : "warning",
+ rollup : true,
+ message : message,
+ rule : rule
+ });
+ },
+ stat: function(name, value){
+ this.stats[name] = value;
+ }
+};
+CSSLint._Reporter = Reporter;
+CSSLint.Util = {
+ mix: function(receiver, supplier){
+ var prop;
+
+ for (prop in supplier){
+ if (supplier.hasOwnProperty(prop)){
+ receiver[prop] = supplier[prop];
+ }
+ }
+
+ return prop;
+ },
+ indexOf: function(values, value){
+ if (values.indexOf){
+ return values.indexOf(value);
+ } else {
+ for (var i=0, len=values.length; i < len; i++){
+ if (values[i] === value){
+ return i;
+ }
+ }
+ return -1;
+ }
+ },
+ forEach: function(values, func) {
+ if (values.forEach){
+ return values.forEach(func);
+ } else {
+ for (var i=0, len=values.length; i < len; i++){
+ func(values[i], i, values);
+ }
+ }
+ }
+};
+
+CSSLint.addRule({
+ id: "adjoining-classes",
+ name: "Disallow adjoining classes",
+ desc: "Don't use adjoining classes.",
+ browsers: "IE6",
+ init: function(parser, reporter){
+ var rule = this;
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ modifier,
+ classCount,
+ i, j, k;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+ for (j=0; j < selector.parts.length; j++){
+ part = selector.parts[j];
+ if (part.type === parser.SELECTOR_PART_TYPE){
+ classCount = 0;
+ for (k=0; k < part.modifiers.length; k++){
+ modifier = part.modifiers[k];
+ if (modifier.type === "class"){
+ classCount++;
+ }
+ if (classCount > 1){
+ reporter.report("Don't use adjoining classes.", part.line, part.col, rule);
+ }
+ }
+ }
+ }
+ }
+ });
+ }
+
+});
+CSSLint.addRule({
+ id: "box-model",
+ name: "Beware of broken box size",
+ desc: "Don't use width or height when using padding or border.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ widthProperties = {
+ border: 1,
+ "border-left": 1,
+ "border-right": 1,
+ padding: 1,
+ "padding-left": 1,
+ "padding-right": 1
+ },
+ heightProperties = {
+ border: 1,
+ "border-bottom": 1,
+ "border-top": 1,
+ padding: 1,
+ "padding-bottom": 1,
+ "padding-top": 1
+ },
+ properties,
+ boxSizing = false;
+
+ function startRule(){
+ properties = {};
+ boxSizing = false;
+ }
+
+ function endRule(){
+ var prop, value;
+
+ if (!boxSizing) {
+ if (properties.height){
+ for (prop in heightProperties){
+ if (heightProperties.hasOwnProperty(prop) && properties[prop]){
+ value = properties[prop].value;
+ if (!(prop === "padding" && value.parts.length === 2 && value.parts[0].value === 0)){
+ reporter.report("Using height with " + prop + " can sometimes make elements larger than you expect.", properties[prop].line, properties[prop].col, rule);
+ }
+ }
+ }
+ }
+
+ if (properties.width){
+ for (prop in widthProperties){
+ if (widthProperties.hasOwnProperty(prop) && properties[prop]){
+ value = properties[prop].value;
+
+ if (!(prop === "padding" && value.parts.length === 2 && value.parts[1].value === 0)){
+ reporter.report("Using width with " + prop + " can sometimes make elements larger than you expect.", properties[prop].line, properties[prop].col, rule);
+ }
+ }
+ }
+ }
+ }
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startpage", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startkeyframerule", startRule);
+
+ parser.addListener("property", function(event){
+ var name = event.property.text.toLowerCase();
+
+ if (heightProperties[name] || widthProperties[name]){
+ if (!/^0\S*$/.test(event.value) && !(name === "border" && event.value.toString() === "none")){
+ properties[name] = { line: event.property.line, col: event.property.col, value: event.value };
+ }
+ } else {
+ if (/^(width|height)/i.test(name) && /^(length|percentage)/.test(event.value.parts[0].type)){
+ properties[name] = 1;
+ } else if (name === "box-sizing") {
+ boxSizing = true;
+ }
+ }
+
+ });
+
+ parser.addListener("endrule", endRule);
+ parser.addListener("endfontface", endRule);
+ parser.addListener("endpage", endRule);
+ parser.addListener("endpagemargin", endRule);
+ parser.addListener("endkeyframerule", endRule);
+ }
+
+});
+
+CSSLint.addRule({
+ id: "box-sizing",
+ name: "Disallow use of box-sizing",
+ desc: "The box-sizing properties isn't supported in IE6 and IE7.",
+ browsers: "IE6, IE7",
+ tags: ["Compatibility"],
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("property", function(event){
+ var name = event.property.text.toLowerCase();
+
+ if (name === "box-sizing"){
+ reporter.report("The box-sizing property isn't supported in IE6 and IE7.", event.line, event.col, rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "bulletproof-font-face",
+ name: "Use the bulletproof @font-face syntax",
+ desc: "Use the bulletproof @font-face syntax to avoid 404's in old IE (http://www.fontspring.com/blog/the-new-bulletproof-font-face-syntax).",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ fontFaceRule = false,
+ firstSrc = true,
+ ruleFailed = false,
+ line, col;
+ parser.addListener("startfontface", function(){
+ fontFaceRule = true;
+ });
+
+ parser.addListener("property", function(event){
+ if (!fontFaceRule) {
+ return;
+ }
+
+ var propertyName = event.property.toString().toLowerCase(),
+ value = event.value.toString();
+ line = event.line;
+ col = event.col;
+ if (propertyName === "src") {
+ var regex = /^\s?url\(['"].+\.eot\?.*['"]\)\s*format\(['"]embedded-opentype['"]\).*$/i;
+ if (!value.match(regex) && firstSrc) {
+ ruleFailed = true;
+ firstSrc = false;
+ } else if (value.match(regex) && !firstSrc) {
+ ruleFailed = false;
+ }
+ }
+
+
+ });
+ parser.addListener("endfontface", function(){
+ fontFaceRule = false;
+
+ if (ruleFailed) {
+ reporter.report("@font-face declaration doesn't follow the fontspring bulletproof syntax.", line, col, rule);
+ }
+ });
+ }
+});
+
+CSSLint.addRule({
+ id: "compatible-vendor-prefixes",
+ name: "Require compatible vendor prefixes",
+ desc: "Include all compatible vendor prefixes to reach a wider range of users.",
+ browsers: "All",
+ init: function (parser, reporter) {
+ var rule = this,
+ compatiblePrefixes,
+ properties,
+ prop,
+ variations,
+ prefixed,
+ i,
+ len,
+ inKeyFrame = false,
+ arrayPush = Array.prototype.push,
+ applyTo = [];
+ compatiblePrefixes = {
+ "animation" : "webkit moz",
+ "animation-delay" : "webkit moz",
+ "animation-direction" : "webkit moz",
+ "animation-duration" : "webkit moz",
+ "animation-fill-mode" : "webkit moz",
+ "animation-iteration-count" : "webkit moz",
+ "animation-name" : "webkit moz",
+ "animation-play-state" : "webkit moz",
+ "animation-timing-function" : "webkit moz",
+ "appearance" : "webkit moz",
+ "border-end" : "webkit moz",
+ "border-end-color" : "webkit moz",
+ "border-end-style" : "webkit moz",
+ "border-end-width" : "webkit moz",
+ "border-image" : "webkit moz o",
+ "border-radius" : "webkit",
+ "border-start" : "webkit moz",
+ "border-start-color" : "webkit moz",
+ "border-start-style" : "webkit moz",
+ "border-start-width" : "webkit moz",
+ "box-align" : "webkit moz ms",
+ "box-direction" : "webkit moz ms",
+ "box-flex" : "webkit moz ms",
+ "box-lines" : "webkit ms",
+ "box-ordinal-group" : "webkit moz ms",
+ "box-orient" : "webkit moz ms",
+ "box-pack" : "webkit moz ms",
+ "box-sizing" : "webkit moz",
+ "box-shadow" : "webkit moz",
+ "column-count" : "webkit moz ms",
+ "column-gap" : "webkit moz ms",
+ "column-rule" : "webkit moz ms",
+ "column-rule-color" : "webkit moz ms",
+ "column-rule-style" : "webkit moz ms",
+ "column-rule-width" : "webkit moz ms",
+ "column-width" : "webkit moz ms",
+ "hyphens" : "epub moz",
+ "line-break" : "webkit ms",
+ "margin-end" : "webkit moz",
+ "margin-start" : "webkit moz",
+ "marquee-speed" : "webkit wap",
+ "marquee-style" : "webkit wap",
+ "padding-end" : "webkit moz",
+ "padding-start" : "webkit moz",
+ "tab-size" : "moz o",
+ "text-size-adjust" : "webkit ms",
+ "transform" : "webkit moz ms o",
+ "transform-origin" : "webkit moz ms o",
+ "transition" : "webkit moz o",
+ "transition-delay" : "webkit moz o",
+ "transition-duration" : "webkit moz o",
+ "transition-property" : "webkit moz o",
+ "transition-timing-function" : "webkit moz o",
+ "user-modify" : "webkit moz",
+ "user-select" : "webkit moz ms",
+ "word-break" : "epub ms",
+ "writing-mode" : "epub ms"
+ };
+
+
+ for (prop in compatiblePrefixes) {
+ if (compatiblePrefixes.hasOwnProperty(prop)) {
+ variations = [];
+ prefixed = compatiblePrefixes[prop].split(" ");
+ for (i = 0, len = prefixed.length; i < len; i++) {
+ variations.push("-" + prefixed[i] + "-" + prop);
+ }
+ compatiblePrefixes[prop] = variations;
+ arrayPush.apply(applyTo, variations);
+ }
+ }
+
+ parser.addListener("startrule", function () {
+ properties = [];
+ });
+
+ parser.addListener("startkeyframes", function (event) {
+ inKeyFrame = event.prefix || true;
+ });
+
+ parser.addListener("endkeyframes", function () {
+ inKeyFrame = false;
+ });
+
+ parser.addListener("property", function (event) {
+ var name = event.property;
+ if (CSSLint.Util.indexOf(applyTo, name.text) > -1) {
+ if (!inKeyFrame || typeof inKeyFrame !== "string" ||
+ name.text.indexOf("-" + inKeyFrame + "-") !== 0) {
+ properties.push(name);
+ }
+ }
+ });
+
+ parser.addListener("endrule", function () {
+ if (!properties.length) {
+ return;
+ }
+
+ var propertyGroups = {},
+ i,
+ len,
+ name,
+ prop,
+ variations,
+ value,
+ full,
+ actual,
+ item,
+ propertiesSpecified;
+
+ for (i = 0, len = properties.length; i < len; i++) {
+ name = properties[i];
+
+ for (prop in compatiblePrefixes) {
+ if (compatiblePrefixes.hasOwnProperty(prop)) {
+ variations = compatiblePrefixes[prop];
+ if (CSSLint.Util.indexOf(variations, name.text) > -1) {
+ if (!propertyGroups[prop]) {
+ propertyGroups[prop] = {
+ full : variations.slice(0),
+ actual : [],
+ actualNodes: []
+ };
+ }
+ if (CSSLint.Util.indexOf(propertyGroups[prop].actual, name.text) === -1) {
+ propertyGroups[prop].actual.push(name.text);
+ propertyGroups[prop].actualNodes.push(name);
+ }
+ }
+ }
+ }
+ }
+
+ for (prop in propertyGroups) {
+ if (propertyGroups.hasOwnProperty(prop)) {
+ value = propertyGroups[prop];
+ full = value.full;
+ actual = value.actual;
+
+ if (full.length > actual.length) {
+ for (i = 0, len = full.length; i < len; i++) {
+ item = full[i];
+ if (CSSLint.Util.indexOf(actual, item) === -1) {
+ propertiesSpecified = (actual.length === 1) ? actual[0] : (actual.length === 2) ? actual.join(" and ") : actual.join(", ");
+ reporter.report("The property " + item + " is compatible with " + propertiesSpecified + " and should be included as well.", value.actualNodes[0].line, value.actualNodes[0].col, rule);
+ }
+ }
+
+ }
+ }
+ }
+ });
+ }
+});
+
+CSSLint.addRule({
+ id: "display-property-grouping",
+ name: "Require properties appropriate for display",
+ desc: "Certain properties shouldn't be used with certain display property values.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ var propertiesToCheck = {
+ display: 1,
+ "float": "none",
+ height: 1,
+ width: 1,
+ margin: 1,
+ "margin-left": 1,
+ "margin-right": 1,
+ "margin-bottom": 1,
+ "margin-top": 1,
+ padding: 1,
+ "padding-left": 1,
+ "padding-right": 1,
+ "padding-bottom": 1,
+ "padding-top": 1,
+ "vertical-align": 1
+ },
+ properties;
+
+ function reportProperty(name, display, msg){
+ if (properties[name]){
+ if (typeof propertiesToCheck[name] !== "string" || properties[name].value.toLowerCase() !== propertiesToCheck[name]){
+ reporter.report(msg || name + " can't be used with display: " + display + ".", properties[name].line, properties[name].col, rule);
+ }
+ }
+ }
+
+ function startRule(){
+ properties = {};
+ }
+
+ function endRule(){
+
+ var display = properties.display ? properties.display.value : null;
+ if (display){
+ switch(display){
+
+ case "inline":
+ reportProperty("height", display);
+ reportProperty("width", display);
+ reportProperty("margin", display);
+ reportProperty("margin-top", display);
+ reportProperty("margin-bottom", display);
+ reportProperty("float", display, "display:inline has no effect on floated elements (but may be used to fix the IE6 double-margin bug).");
+ break;
+
+ case "block":
+ reportProperty("vertical-align", display);
+ break;
+
+ case "inline-block":
+ reportProperty("float", display);
+ break;
+
+ default:
+ if (display.indexOf("table-") === 0){
+ reportProperty("margin", display);
+ reportProperty("margin-left", display);
+ reportProperty("margin-right", display);
+ reportProperty("margin-top", display);
+ reportProperty("margin-bottom", display);
+ reportProperty("float", display);
+ }
+ }
+ }
+
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startkeyframerule", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startpage", startRule);
+
+ parser.addListener("property", function(event){
+ var name = event.property.text.toLowerCase();
+
+ if (propertiesToCheck[name]){
+ properties[name] = { value: event.value.text, line: event.property.line, col: event.property.col };
+ }
+ });
+
+ parser.addListener("endrule", endRule);
+ parser.addListener("endfontface", endRule);
+ parser.addListener("endkeyframerule", endRule);
+ parser.addListener("endpagemargin", endRule);
+ parser.addListener("endpage", endRule);
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "duplicate-background-images",
+ name: "Disallow duplicate background images",
+ desc: "Every background-image should be unique. Use a common class for e.g. sprites.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ stack = {};
+
+ parser.addListener("property", function(event){
+ var name = event.property.text,
+ value = event.value,
+ i, len;
+
+ if (name.match(/background/i)) {
+ for (i=0, len=value.parts.length; i < len; i++) {
+ if (value.parts[i].type === "uri") {
+ if (typeof stack[value.parts[i].uri] === "undefined") {
+ stack[value.parts[i].uri] = event;
+ }
+ else {
+ reporter.report("Background image '" + value.parts[i].uri + "' was used multiple times, first declared at line " + stack[value.parts[i].uri].line + ", col " + stack[value.parts[i].uri].col + ".", event.line, event.col, rule);
+ }
+ }
+ }
+ }
+ });
+ }
+});
+
+CSSLint.addRule({
+ id: "duplicate-properties",
+ name: "Disallow duplicate properties",
+ desc: "Duplicate properties must appear one after the other.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ properties,
+ lastProperty;
+
+ function startRule(){
+ properties = {};
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startpage", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startkeyframerule", startRule);
+
+ parser.addListener("property", function(event){
+ var property = event.property,
+ name = property.text.toLowerCase();
+
+ if (properties[name] && (lastProperty !== name || properties[name] === event.value.text)){
+ reporter.report("Duplicate property '" + event.property + "' found.", event.line, event.col, rule);
+ }
+
+ properties[name] = event.value.text;
+ lastProperty = name;
+
+ });
+
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "empty-rules",
+ name: "Disallow empty rules",
+ desc: "Rules without any properties specified should be removed.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ count = 0;
+
+ parser.addListener("startrule", function(){
+ count=0;
+ });
+
+ parser.addListener("property", function(){
+ count++;
+ });
+
+ parser.addListener("endrule", function(event){
+ var selectors = event.selectors;
+ if (count === 0){
+ reporter.report("Rule is empty.", selectors[0].line, selectors[0].col, rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "errors",
+ name: "Parsing Errors",
+ desc: "This rule looks for recoverable syntax errors.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("error", function(event){
+ reporter.error(event.message, event.line, event.col, rule);
+ });
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "fallback-colors",
+ name: "Require fallback colors",
+ desc: "For older browsers that don't support RGBA, HSL, or HSLA, provide a fallback color.",
+ browsers: "IE6,IE7,IE8",
+ init: function(parser, reporter){
+ var rule = this,
+ lastProperty,
+ propertiesToCheck = {
+ color: 1,
+ background: 1,
+ "border-color": 1,
+ "border-top-color": 1,
+ "border-right-color": 1,
+ "border-bottom-color": 1,
+ "border-left-color": 1,
+ border: 1,
+ "border-top": 1,
+ "border-right": 1,
+ "border-bottom": 1,
+ "border-left": 1,
+ "background-color": 1
+ },
+ properties;
+
+ function startRule(){
+ properties = {};
+ lastProperty = null;
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startpage", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startkeyframerule", startRule);
+
+ parser.addListener("property", function(event){
+ var property = event.property,
+ name = property.text.toLowerCase(),
+ parts = event.value.parts,
+ i = 0,
+ colorType = "",
+ len = parts.length;
+
+ if(propertiesToCheck[name]){
+ while(i < len){
+ if (parts[i].type === "color"){
+ if ("alpha" in parts[i] || "hue" in parts[i]){
+
+ if (/([^\)]+)\(/.test(parts[i])){
+ colorType = RegExp.$1.toUpperCase();
+ }
+
+ if (!lastProperty || (lastProperty.property.text.toLowerCase() !== name || lastProperty.colorType !== "compat")){
+ reporter.report("Fallback " + name + " (hex or RGB) should precede " + colorType + " " + name + ".", event.line, event.col, rule);
+ }
+ } else {
+ event.colorType = "compat";
+ }
+ }
+
+ i++;
+ }
+ }
+
+ lastProperty = event;
+ });
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "floats",
+ name: "Disallow too many floats",
+ desc: "This rule tests if the float property is used too many times",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+ var count = 0;
+ parser.addListener("property", function(event){
+ if (event.property.text.toLowerCase() === "float" &&
+ event.value.text.toLowerCase() !== "none"){
+ count++;
+ }
+ });
+ parser.addListener("endstylesheet", function(){
+ reporter.stat("floats", count);
+ if (count >= 10){
+ reporter.rollupWarn("Too many floats (" + count + "), you're probably using them for layout. Consider using a grid system instead.", rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "font-faces",
+ name: "Don't use too many web fonts",
+ desc: "Too many different web fonts in the same stylesheet.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ count = 0;
+
+
+ parser.addListener("startfontface", function(){
+ count++;
+ });
+
+ parser.addListener("endstylesheet", function(){
+ if (count > 5){
+ reporter.rollupWarn("Too many @font-face declarations (" + count + ").", rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "font-sizes",
+ name: "Disallow too many font sizes",
+ desc: "Checks the number of font-size declarations.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ count = 0;
+ parser.addListener("property", function(event){
+ if (event.property.toString() === "font-size"){
+ count++;
+ }
+ });
+ parser.addListener("endstylesheet", function(){
+ reporter.stat("font-sizes", count);
+ if (count >= 10){
+ reporter.rollupWarn("Too many font-size declarations (" + count + "), abstraction needed.", rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "gradients",
+ name: "Require all gradient definitions",
+ desc: "When using a vendor-prefixed gradient, make sure to use them all.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ gradients;
+
+ parser.addListener("startrule", function(){
+ gradients = {
+ moz: 0,
+ webkit: 0,
+ oldWebkit: 0,
+ o: 0
+ };
+ });
+
+ parser.addListener("property", function(event){
+
+ if (/\-(moz|o|webkit)(?:\-(?:linear|radial))\-gradient/i.test(event.value)){
+ gradients[RegExp.$1] = 1;
+ } else if (/\-webkit\-gradient/i.test(event.value)){
+ gradients.oldWebkit = 1;
+ }
+
+ });
+
+ parser.addListener("endrule", function(event){
+ var missing = [];
+
+ if (!gradients.moz){
+ missing.push("Firefox 3.6+");
+ }
+
+ if (!gradients.webkit){
+ missing.push("Webkit (Safari 5+, Chrome)");
+ }
+
+ if (!gradients.oldWebkit){
+ missing.push("Old Webkit (Safari 4+, Chrome)");
+ }
+
+ if (!gradients.o){
+ missing.push("Opera 11.1+");
+ }
+
+ if (missing.length && missing.length < 4){
+ reporter.report("Missing vendor-prefixed CSS gradients for " + missing.join(", ") + ".", event.selectors[0].line, event.selectors[0].col, rule);
+ }
+
+ });
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "ids",
+ name: "Disallow IDs in selectors",
+ desc: "Selectors should not contain IDs.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ modifier,
+ idCount,
+ i, j, k;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+ idCount = 0;
+
+ for (j=0; j < selector.parts.length; j++){
+ part = selector.parts[j];
+ if (part.type === parser.SELECTOR_PART_TYPE){
+ for (k=0; k < part.modifiers.length; k++){
+ modifier = part.modifiers[k];
+ if (modifier.type === "id"){
+ idCount++;
+ }
+ }
+ }
+ }
+
+ if (idCount === 1){
+ reporter.report("Don't use IDs in selectors.", selector.line, selector.col, rule);
+ } else if (idCount > 1){
+ reporter.report(idCount + " IDs in the selector, really?", selector.line, selector.col, rule);
+ }
+ }
+
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "import",
+ name: "Disallow @import",
+ desc: "Don't use @import, use <link> instead.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("import", function(event){
+ reporter.report("@import prevents parallel downloads, use <link> instead.", event.line, event.col, rule);
+ });
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "important",
+ name: "Disallow !important",
+ desc: "Be careful when using !important declaration",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ count = 0;
+ parser.addListener("property", function(event){
+ if (event.important === true){
+ count++;
+ reporter.report("Use of !important", event.line, event.col, rule);
+ }
+ });
+ parser.addListener("endstylesheet", function(){
+ reporter.stat("important", count);
+ if (count >= 10){
+ reporter.rollupWarn("Too many !important declarations (" + count + "), try to use less than 10 to avoid specificity issues.", rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "known-properties",
+ name: "Require use of known properties",
+ desc: "Properties should be known (listed in CSS3 specification) or be a vendor-prefixed property.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("property", function(event){
+ if (event.invalid) {
+ reporter.report(event.invalid.message, event.line, event.col, rule);
+ }
+
+ });
+ }
+
+});
+CSSLint.addRule({
+ id: "order-alphabetical",
+ name: "Alphabetical order",
+ desc: "Assure properties are in alphabetical order",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ properties;
+
+ var startRule = function () {
+ properties = [];
+ };
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startpage", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startkeyframerule", startRule);
+
+ parser.addListener("property", function(event){
+ var name = event.property.text,
+ lowerCasePrefixLessName = name.toLowerCase().replace(/^-.*?-/, "");
+
+ properties.push(lowerCasePrefixLessName);
+ });
+
+ parser.addListener("endrule", function(event){
+ var currentProperties = properties.join(","),
+ expectedProperties = properties.sort().join(",");
+
+ if (currentProperties !== expectedProperties){
+ reporter.report("Rule doesn't have all its properties in alphabetical ordered.", event.line, event.col, rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "outline-none",
+ name: "Disallow outline: none",
+ desc: "Use of outline: none or outline: 0 should be limited to :focus rules.",
+ browsers: "All",
+ tags: ["Accessibility"],
+ init: function(parser, reporter){
+ var rule = this,
+ lastRule;
+
+ function startRule(event){
+ if (event.selectors){
+ lastRule = {
+ line: event.line,
+ col: event.col,
+ selectors: event.selectors,
+ propCount: 0,
+ outline: false
+ };
+ } else {
+ lastRule = null;
+ }
+ }
+
+ function endRule(){
+ if (lastRule){
+ if (lastRule.outline){
+ if (lastRule.selectors.toString().toLowerCase().indexOf(":focus") === -1){
+ reporter.report("Outlines should only be modified using :focus.", lastRule.line, lastRule.col, rule);
+ } else if (lastRule.propCount === 1) {
+ reporter.report("Outlines shouldn't be hidden unless other visual changes are made.", lastRule.line, lastRule.col, rule);
+ }
+ }
+ }
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startpage", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startkeyframerule", startRule);
+
+ parser.addListener("property", function(event){
+ var name = event.property.text.toLowerCase(),
+ value = event.value;
+
+ if (lastRule){
+ lastRule.propCount++;
+ if (name === "outline" && (value.toString() === "none" || value.toString() === "0")){
+ lastRule.outline = true;
+ }
+ }
+
+ });
+
+ parser.addListener("endrule", endRule);
+ parser.addListener("endfontface", endRule);
+ parser.addListener("endpage", endRule);
+ parser.addListener("endpagemargin", endRule);
+ parser.addListener("endkeyframerule", endRule);
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "overqualified-elements",
+ name: "Disallow overqualified elements",
+ desc: "Don't use classes or IDs with elements (a.foo or a#foo).",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ classes = {};
+
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ modifier,
+ i, j, k;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+
+ for (j=0; j < selector.parts.length; j++){
+ part = selector.parts[j];
+ if (part.type === parser.SELECTOR_PART_TYPE){
+ for (k=0; k < part.modifiers.length; k++){
+ modifier = part.modifiers[k];
+ if (part.elementName && modifier.type === "id"){
+ reporter.report("Element (" + part + ") is overqualified, just use " + modifier + " without element name.", part.line, part.col, rule);
+ } else if (modifier.type === "class"){
+
+ if (!classes[modifier]){
+ classes[modifier] = [];
+ }
+ classes[modifier].push({ modifier: modifier, part: part });
+ }
+ }
+ }
+ }
+ }
+ });
+
+ parser.addListener("endstylesheet", function(){
+
+ var prop;
+ for (prop in classes){
+ if (classes.hasOwnProperty(prop)){
+ if (classes[prop].length === 1 && classes[prop][0].part.elementName){
+ reporter.report("Element (" + classes[prop][0].part + ") is overqualified, just use " + classes[prop][0].modifier + " without element name.", classes[prop][0].part.line, classes[prop][0].part.col, rule);
+ }
+ }
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "qualified-headings",
+ name: "Disallow qualified headings",
+ desc: "Headings should not be qualified (namespaced).",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ i, j;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+
+ for (j=0; j < selector.parts.length; j++){
+ part = selector.parts[j];
+ if (part.type === parser.SELECTOR_PART_TYPE){
+ if (part.elementName && /h[1-6]/.test(part.elementName.toString()) && j > 0){
+ reporter.report("Heading (" + part.elementName + ") should not be qualified.", part.line, part.col, rule);
+ }
+ }
+ }
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "regex-selectors",
+ name: "Disallow selectors that look like regexs",
+ desc: "Selectors that look like regular expressions are slow and should be avoided.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ modifier,
+ i, j, k;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+ for (j=0; j < selector.parts.length; j++){
+ part = selector.parts[j];
+ if (part.type === parser.SELECTOR_PART_TYPE){
+ for (k=0; k < part.modifiers.length; k++){
+ modifier = part.modifiers[k];
+ if (modifier.type === "attribute"){
+ if (/([\~\|\^\$\*]=)/.test(modifier)){
+ reporter.report("Attribute selectors with " + RegExp.$1 + " are slow!", modifier.line, modifier.col, rule);
+ }
+ }
+
+ }
+ }
+ }
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "rules-count",
+ name: "Rules Count",
+ desc: "Track how many rules there are.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var count = 0;
+ parser.addListener("startrule", function(){
+ count++;
+ });
+
+ parser.addListener("endstylesheet", function(){
+ reporter.stat("rule-count", count);
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "selector-max-approaching",
+ name: "Warn when approaching the 4095 selector limit for IE",
+ desc: "Will warn when selector count is >= 3800 selectors.",
+ browsers: "IE",
+ init: function(parser, reporter) {
+ var rule = this, count = 0;
+
+ parser.addListener("startrule", function(event) {
+ count += event.selectors.length;
+ });
+
+ parser.addListener("endstylesheet", function() {
+ if (count >= 3800) {
+ reporter.report("You have " + count + " selectors. Internet Explorer supports a maximum of 4095 selectors per stylesheet. Consider refactoring.",0,0,rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "selector-max",
+ name: "Error when past the 4095 selector limit for IE",
+ desc: "Will error when selector count is > 4095.",
+ browsers: "IE",
+ init: function(parser, reporter){
+ var rule = this, count = 0;
+
+ parser.addListener("startrule", function(event) {
+ count += event.selectors.length;
+ });
+
+ parser.addListener("endstylesheet", function() {
+ if (count > 4095) {
+ reporter.report("You have " + count + " selectors. Internet Explorer supports a maximum of 4095 selectors per stylesheet. Consider refactoring.",0,0,rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "selector-newline",
+ name: "Disallow new-line characters in selectors",
+ desc: "New-line characters in selectors are usually a forgotten comma and not a descendant combinator.",
+ browsers: "All",
+ init: function(parser, reporter) {
+ var rule = this;
+
+ function startRule(event) {
+ var i, len, selector, p, n, pLen, part, part2, type, currentLine, nextLine,
+ selectors = event.selectors;
+
+ for (i = 0, len = selectors.length; i < len; i++) {
+ selector = selectors[i];
+ for (p = 0, pLen = selector.parts.length; p < pLen; p++) {
+ for (n = p + 1; n < pLen; n++) {
+ part = selector.parts[p];
+ part2 = selector.parts[n];
+ type = part.type;
+ currentLine = part.line;
+ nextLine = part2.line;
+
+ if (type === "descendant" && nextLine > currentLine) {
+ reporter.report("newline character found in selector (forgot a comma?)", currentLine, selectors[i].parts[0].col, rule);
+ }
+ }
+ }
+
+ }
+ }
+
+ parser.addListener("startrule", startRule);
+
+ }
+});
+
+CSSLint.addRule({
+ id: "shorthand",
+ name: "Require shorthand properties",
+ desc: "Use shorthand properties where possible.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ prop, i, len,
+ propertiesToCheck = {},
+ properties,
+ mapping = {
+ "margin": [
+ "margin-top",
+ "margin-bottom",
+ "margin-left",
+ "margin-right"
+ ],
+ "padding": [
+ "padding-top",
+ "padding-bottom",
+ "padding-left",
+ "padding-right"
+ ]
+ };
+ for (prop in mapping){
+ if (mapping.hasOwnProperty(prop)){
+ for (i=0, len=mapping[prop].length; i < len; i++){
+ propertiesToCheck[mapping[prop][i]] = prop;
+ }
+ }
+ }
+
+ function startRule(){
+ properties = {};
+ }
+ function endRule(event){
+
+ var prop, i, len, total;
+ for (prop in mapping){
+ if (mapping.hasOwnProperty(prop)){
+ total=0;
+
+ for (i=0, len=mapping[prop].length; i < len; i++){
+ total += properties[mapping[prop][i]] ? 1 : 0;
+ }
+
+ if (total === mapping[prop].length){
+ reporter.report("The properties " + mapping[prop].join(", ") + " can be replaced by " + prop + ".", event.line, event.col, rule);
+ }
+ }
+ }
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("property", function(event){
+ var name = event.property.toString().toLowerCase();
+
+ if (propertiesToCheck[name]){
+ properties[name] = 1;
+ }
+ });
+
+ parser.addListener("endrule", endRule);
+ parser.addListener("endfontface", endRule);
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "star-property-hack",
+ name: "Disallow properties with a star prefix",
+ desc: "Checks for the star property hack (targets IE6/7)",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+ parser.addListener("property", function(event){
+ var property = event.property;
+
+ if (property.hack === "*") {
+ reporter.report("Property with star prefix found.", event.property.line, event.property.col, rule);
+ }
+ });
+ }
+});
+
+CSSLint.addRule({
+ id: "text-indent",
+ name: "Disallow negative text-indent",
+ desc: "Checks for text indent less than -99px",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ textIndent,
+ direction;
+
+
+ function startRule(){
+ textIndent = false;
+ direction = "inherit";
+ }
+ function endRule(){
+ if (textIndent && direction !== "ltr"){
+ reporter.report("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set direction for that item to ltr.", textIndent.line, textIndent.col, rule);
+ }
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("property", function(event){
+ var name = event.property.toString().toLowerCase(),
+ value = event.value;
+
+ if (name === "text-indent" && value.parts[0].value < -99){
+ textIndent = event.property;
+ } else if (name === "direction" && value.toString() === "ltr"){
+ direction = "ltr";
+ }
+ });
+
+ parser.addListener("endrule", endRule);
+ parser.addListener("endfontface", endRule);
+
+ }
+
+});
+
+CSSLint.addRule({
+ id: "underscore-property-hack",
+ name: "Disallow properties with an underscore prefix",
+ desc: "Checks for the underscore property hack (targets IE6)",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+ parser.addListener("property", function(event){
+ var property = event.property;
+
+ if (property.hack === "_") {
+ reporter.report("Property with underscore prefix found.", event.property.line, event.property.col, rule);
+ }
+ });
+ }
+});
+
+CSSLint.addRule({
+ id: "unique-headings",
+ name: "Headings should only be defined once",
+ desc: "Headings should be defined only once.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ var headings = {
+ h1: 0,
+ h2: 0,
+ h3: 0,
+ h4: 0,
+ h5: 0,
+ h6: 0
+ };
+
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ pseudo,
+ i, j;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+ part = selector.parts[selector.parts.length-1];
+
+ if (part.elementName && /(h[1-6])/i.test(part.elementName.toString())){
+
+ for (j=0; j < part.modifiers.length; j++){
+ if (part.modifiers[j].type === "pseudo"){
+ pseudo = true;
+ break;
+ }
+ }
+
+ if (!pseudo){
+ headings[RegExp.$1]++;
+ if (headings[RegExp.$1] > 1) {
+ reporter.report("Heading (" + part.elementName + ") has already been defined.", part.line, part.col, rule);
+ }
+ }
+ }
+ }
+ });
+
+ parser.addListener("endstylesheet", function(){
+ var prop,
+ messages = [];
+
+ for (prop in headings){
+ if (headings.hasOwnProperty(prop)){
+ if (headings[prop] > 1){
+ messages.push(headings[prop] + " " + prop + "s");
+ }
+ }
+ }
+
+ if (messages.length){
+ reporter.rollupWarn("You have " + messages.join(", ") + " defined in this stylesheet.", rule);
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "universal-selector",
+ name: "Disallow universal selector",
+ desc: "The universal selector (*) is known to be slow.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("startrule", function(event){
+ var selectors = event.selectors,
+ selector,
+ part,
+ i;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+
+ part = selector.parts[selector.parts.length-1];
+ if (part.elementName === "*"){
+ reporter.report(rule.desc, part.line, part.col, rule);
+ }
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "unqualified-attributes",
+ name: "Disallow unqualified attribute selectors",
+ desc: "Unqualified attribute selectors are known to be slow.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+
+ parser.addListener("startrule", function(event){
+
+ var selectors = event.selectors,
+ selector,
+ part,
+ modifier,
+ i, k;
+
+ for (i=0; i < selectors.length; i++){
+ selector = selectors[i];
+
+ part = selector.parts[selector.parts.length-1];
+ if (part.type === parser.SELECTOR_PART_TYPE){
+ for (k=0; k < part.modifiers.length; k++){
+ modifier = part.modifiers[k];
+ if (modifier.type === "attribute" && (!part.elementName || part.elementName === "*")){
+ reporter.report(rule.desc, part.line, part.col, rule);
+ }
+ }
+ }
+
+ }
+ });
+ }
+
+});
+
+CSSLint.addRule({
+ id: "vendor-prefix",
+ name: "Require standard property with vendor prefix",
+ desc: "When using a vendor-prefixed property, make sure to include the standard one.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this,
+ properties,
+ num,
+ propertiesToCheck = {
+ "-webkit-border-radius": "border-radius",
+ "-webkit-border-top-left-radius": "border-top-left-radius",
+ "-webkit-border-top-right-radius": "border-top-right-radius",
+ "-webkit-border-bottom-left-radius": "border-bottom-left-radius",
+ "-webkit-border-bottom-right-radius": "border-bottom-right-radius",
+
+ "-o-border-radius": "border-radius",
+ "-o-border-top-left-radius": "border-top-left-radius",
+ "-o-border-top-right-radius": "border-top-right-radius",
+ "-o-border-bottom-left-radius": "border-bottom-left-radius",
+ "-o-border-bottom-right-radius": "border-bottom-right-radius",
+
+ "-moz-border-radius": "border-radius",
+ "-moz-border-radius-topleft": "border-top-left-radius",
+ "-moz-border-radius-topright": "border-top-right-radius",
+ "-moz-border-radius-bottomleft": "border-bottom-left-radius",
+ "-moz-border-radius-bottomright": "border-bottom-right-radius",
+
+ "-moz-column-count": "column-count",
+ "-webkit-column-count": "column-count",
+
+ "-moz-column-gap": "column-gap",
+ "-webkit-column-gap": "column-gap",
+
+ "-moz-column-rule": "column-rule",
+ "-webkit-column-rule": "column-rule",
+
+ "-moz-column-rule-style": "column-rule-style",
+ "-webkit-column-rule-style": "column-rule-style",
+
+ "-moz-column-rule-color": "column-rule-color",
+ "-webkit-column-rule-color": "column-rule-color",
+
+ "-moz-column-rule-width": "column-rule-width",
+ "-webkit-column-rule-width": "column-rule-width",
+
+ "-moz-column-width": "column-width",
+ "-webkit-column-width": "column-width",
+
+ "-webkit-column-span": "column-span",
+ "-webkit-columns": "columns",
+
+ "-moz-box-shadow": "box-shadow",
+ "-webkit-box-shadow": "box-shadow",
+
+ "-moz-transform" : "transform",
+ "-webkit-transform" : "transform",
+ "-o-transform" : "transform",
+ "-ms-transform" : "transform",
+
+ "-moz-transform-origin" : "transform-origin",
+ "-webkit-transform-origin" : "transform-origin",
+ "-o-transform-origin" : "transform-origin",
+ "-ms-transform-origin" : "transform-origin",
+
+ "-moz-box-sizing" : "box-sizing",
+ "-webkit-box-sizing" : "box-sizing"
+ };
+ function startRule(){
+ properties = {};
+ num = 1;
+ }
+ function endRule(){
+ var prop,
+ i,
+ len,
+ needed,
+ actual,
+ needsStandard = [];
+
+ for (prop in properties){
+ if (propertiesToCheck[prop]){
+ needsStandard.push({ actual: prop, needed: propertiesToCheck[prop]});
+ }
+ }
+
+ for (i=0, len=needsStandard.length; i < len; i++){
+ needed = needsStandard[i].needed;
+ actual = needsStandard[i].actual;
+
+ if (!properties[needed]){
+ reporter.report("Missing standard property '" + needed + "' to go along with '" + actual + "'.", properties[actual][0].name.line, properties[actual][0].name.col, rule);
+ } else {
+ if (properties[needed][0].pos < properties[actual][0].pos){
+ reporter.report("Standard property '" + needed + "' should come after vendor-prefixed property '" + actual + "'.", properties[actual][0].name.line, properties[actual][0].name.col, rule);
+ }
+ }
+ }
+
+ }
+
+ parser.addListener("startrule", startRule);
+ parser.addListener("startfontface", startRule);
+ parser.addListener("startpage", startRule);
+ parser.addListener("startpagemargin", startRule);
+ parser.addListener("startkeyframerule", startRule);
+
+ parser.addListener("property", function(event){
+ var name = event.property.text.toLowerCase();
+
+ if (!properties[name]){
+ properties[name] = [];
+ }
+
+ properties[name].push({ name: event.property, value : event.value, pos:num++ });
+ });
+
+ parser.addListener("endrule", endRule);
+ parser.addListener("endfontface", endRule);
+ parser.addListener("endpage", endRule);
+ parser.addListener("endpagemargin", endRule);
+ parser.addListener("endkeyframerule", endRule);
+ }
+
+});
+
+CSSLint.addRule({
+ id: "zero-units",
+ name: "Disallow units for 0 values",
+ desc: "You don't need to specify units when a value is 0.",
+ browsers: "All",
+ init: function(parser, reporter){
+ var rule = this;
+ parser.addListener("property", function(event){
+ var parts = event.value.parts,
+ i = 0,
+ len = parts.length;
+
+ while(i < len){
+ if ((parts[i].units || parts[i].type === "percentage") && parts[i].value === 0 && parts[i].type !== "time"){
+ reporter.report("Values of 0 shouldn't have units specified.", parts[i].line, parts[i].col, rule);
+ }
+ i++;
+ }
+
+ });
+
+ }
+
+});
+
+(function() {
+ var xmlEscape = function(str) {
+ if (!str || str.constructor !== String) {
+ return "";
+ }
+
+ return str.replace(/[\"&><]/g, function(match) {
+ switch (match) {
+ case "\"":
+ return "&quot;";
+ case "&":
+ return "&amp;";
+ case "<":
+ return "&lt;";
+ case ">":
+ return "&gt;";
+ }
+ });
+ };
+
+ CSSLint.addFormatter({
+ id: "checkstyle-xml",
+ name: "Checkstyle XML format",
+ startFormat: function(){
+ return "<?xml version=\"1.0\" encoding=\"utf-8\"?><checkstyle>";
+ },
+ endFormat: function(){
+ return "</checkstyle>";
+ },
+ readError: function(filename, message) {
+ return "<file name=\"" + xmlEscape(filename) + "\"><error line=\"0\" column=\"0\" severty=\"error\" message=\"" + xmlEscape(message) + "\"></error></file>";
+ },
+ formatResults: function(results, filename/*, options*/) {
+ var messages = results.messages,
+ output = [];
+ var generateSource = function(rule) {
+ if (!rule || !("name" in rule)) {
+ return "";
+ }
+ return "net.csslint." + rule.name.replace(/\s/g,"");
+ };
+
+
+
+ if (messages.length > 0) {
+ output.push("<file name=\""+filename+"\">");
+ CSSLint.Util.forEach(messages, function (message) {
+ if (!message.rollup) {
+ output.push("<error line=\"" + message.line + "\" column=\"" + message.col + "\" severity=\"" + message.type + "\"" +
+ " message=\"" + xmlEscape(message.message) + "\" source=\"" + generateSource(message.rule) +"\"/>");
+ }
+ });
+ output.push("</file>");
+ }
+
+ return output.join("");
+ }
+ });
+
+}());
+
+CSSLint.addFormatter({
+ id: "compact",
+ name: "Compact, 'porcelain' format",
+ startFormat: function() {
+ return "";
+ },
+ endFormat: function() {
+ return "";
+ },
+ formatResults: function(results, filename, options) {
+ var messages = results.messages,
+ output = "";
+ options = options || {};
+ var capitalize = function(str) {
+ return str.charAt(0).toUpperCase() + str.slice(1);
+ };
+
+ if (messages.length === 0) {
+ return options.quiet ? "" : filename + ": Lint Free!";
+ }
+
+ CSSLint.Util.forEach(messages, function(message) {
+ if (message.rollup) {
+ output += filename + ": " + capitalize(message.type) + " - " + message.message + "\n";
+ } else {
+ output += filename + ": " + "line " + message.line +
+ ", col " + message.col + ", " + capitalize(message.type) + " - " + message.message + " (" + message.rule.id + ")\n";
+ }
+ });
+
+ return output;
+ }
+});
+
+CSSLint.addFormatter({
+ id: "csslint-xml",
+ name: "CSSLint XML format",
+ startFormat: function(){
+ return "<?xml version=\"1.0\" encoding=\"utf-8\"?><csslint>";
+ },
+ endFormat: function(){
+ return "</csslint>";
+ },
+ formatResults: function(results, filename/*, options*/) {
+ var messages = results.messages,
+ output = [];
+ var escapeSpecialCharacters = function(str) {
+ if (!str || str.constructor !== String) {
+ return "";
+ }
+ return str.replace(/\"/g, "'").replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;");
+ };
+
+ if (messages.length > 0) {
+ output.push("<file name=\""+filename+"\">");
+ CSSLint.Util.forEach(messages, function (message) {
+ if (message.rollup) {
+ output.push("<issue severity=\"" + message.type + "\" reason=\"" + escapeSpecialCharacters(message.message) + "\" evidence=\"" + escapeSpecialCharacters(message.evidence) + "\"/>");
+ } else {
+ output.push("<issue line=\"" + message.line + "\" char=\"" + message.col + "\" severity=\"" + message.type + "\"" +
+ " reason=\"" + escapeSpecialCharacters(message.message) + "\" evidence=\"" + escapeSpecialCharacters(message.evidence) + "\"/>");
+ }
+ });
+ output.push("</file>");
+ }
+
+ return output.join("");
+ }
+});
+
+CSSLint.addFormatter({
+ id: "junit-xml",
+ name: "JUNIT XML format",
+ startFormat: function(){
+ return "<?xml version=\"1.0\" encoding=\"utf-8\"?><testsuites>";
+ },
+ endFormat: function() {
+ return "</testsuites>";
+ },
+ formatResults: function(results, filename/*, options*/) {
+
+ var messages = results.messages,
+ output = [],
+ tests = {
+ "error": 0,
+ "failure": 0
+ };
+ var generateSource = function(rule) {
+ if (!rule || !("name" in rule)) {
+ return "";
+ }
+ return "net.csslint." + rule.name.replace(/\s/g,"");
+ };
+ var escapeSpecialCharacters = function(str) {
+
+ if (!str || str.constructor !== String) {
+ return "";
+ }
+
+ return str.replace(/\"/g, "'").replace(/</g, "&lt;").replace(/>/g, "&gt;");
+
+ };
+
+ if (messages.length > 0) {
+
+ messages.forEach(function (message) {
+ var type = message.type === "warning" ? "error" : message.type;
+ if (!message.rollup) {
+ output.push("<testcase time=\"0\" name=\"" + generateSource(message.rule) + "\">");
+ output.push("<" + type + " message=\"" + escapeSpecialCharacters(message.message) + "\"><![CDATA[" + message.line + ":" + message.col + ":" + escapeSpecialCharacters(message.evidence) + "]]></" + type + ">");
+ output.push("</testcase>");
+
+ tests[type] += 1;
+
+ }
+
+ });
+
+ output.unshift("<testsuite time=\"0\" tests=\"" + messages.length + "\" skipped=\"0\" errors=\"" + tests.error + "\" failures=\"" + tests.failure + "\" package=\"net.csslint\" name=\"" + filename + "\">");
+ output.push("</testsuite>");
+
+ }
+
+ return output.join("");
+
+ }
+});
+
+CSSLint.addFormatter({
+ id: "lint-xml",
+ name: "Lint XML format",
+ startFormat: function(){
+ return "<?xml version=\"1.0\" encoding=\"utf-8\"?><lint>";
+ },
+ endFormat: function(){
+ return "</lint>";
+ },
+ formatResults: function(results, filename/*, options*/) {
+ var messages = results.messages,
+ output = [];
+ var escapeSpecialCharacters = function(str) {
+ if (!str || str.constructor !== String) {
+ return "";
+ }
+ return str.replace(/\"/g, "'").replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;");
+ };
+
+ if (messages.length > 0) {
+
+ output.push("<file name=\""+filename+"\">");
+ CSSLint.Util.forEach(messages, function (message) {
+ if (message.rollup) {
+ output.push("<issue severity=\"" + message.type + "\" reason=\"" + escapeSpecialCharacters(message.message) + "\" evidence=\"" + escapeSpecialCharacters(message.evidence) + "\"/>");
+ } else {
+ output.push("<issue line=\"" + message.line + "\" char=\"" + message.col + "\" severity=\"" + message.type + "\"" +
+ " reason=\"" + escapeSpecialCharacters(message.message) + "\" evidence=\"" + escapeSpecialCharacters(message.evidence) + "\"/>");
+ }
+ });
+ output.push("</file>");
+ }
+
+ return output.join("");
+ }
+});
+
+CSSLint.addFormatter({
+ id: "text",
+ name: "Plain Text",
+ startFormat: function() {
+ return "";
+ },
+ endFormat: function() {
+ return "";
+ },
+ formatResults: function(results, filename, options) {
+ var messages = results.messages,
+ output = "";
+ options = options || {};
+
+ if (messages.length === 0) {
+ return options.quiet ? "" : "\n\ncsslint: No errors in " + filename + ".";
+ }
+
+ output = "\n\ncsslint: There ";
+ if (messages.length === 1) {
+ output += "is 1 problem";
+ } else {
+ output += "are " + messages.length + " problems";
+ }
+ output += " in " + filename + ".";
+
+ var pos = filename.lastIndexOf("/"),
+ shortFilename = filename;
+
+ if (pos === -1){
+ pos = filename.lastIndexOf("\\");
+ }
+ if (pos > -1){
+ shortFilename = filename.substring(pos+1);
+ }
+
+ CSSLint.Util.forEach(messages, function (message, i) {
+ output = output + "\n\n" + shortFilename;
+ if (message.rollup) {
+ output += "\n" + (i+1) + ": " + message.type;
+ output += "\n" + message.message;
+ } else {
+ output += "\n" + (i+1) + ": " + message.type + " at line " + message.line + ", col " + message.col;
+ output += "\n" + message.message;
+ output += "\n" + message.evidence;
+ }
+ });
+
+ return output;
+ }
+});
+
+module.exports.CSSLint = CSSLint;
+
+});
+
+ace.define("ace/mode/css_worker",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/worker/mirror","ace/mode/css/csslint"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var Mirror = require("../worker/mirror").Mirror;
+var CSSLint = require("./css/csslint").CSSLint;
+
+var Worker = exports.Worker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(400);
+ this.ruleset = null;
+ this.setDisabledRules("ids|order-alphabetical");
+ this.setInfoRules(
+ "adjoining-classes|qualified-headings|zero-units|gradients|" +
+ "import|outline-none|vendor-prefix"
+ );
+};
+
+oop.inherits(Worker, Mirror);
+
+(function() {
+ this.setInfoRules = function(ruleNames) {
+ if (typeof ruleNames == "string")
+ ruleNames = ruleNames.split("|");
+ this.infoRules = lang.arrayToMap(ruleNames);
+ this.doc.getValue() && this.deferredUpdate.schedule(100);
+ };
+
+ this.setDisabledRules = function(ruleNames) {
+ if (!ruleNames) {
+ this.ruleset = null;
+ } else {
+ if (typeof ruleNames == "string")
+ ruleNames = ruleNames.split("|");
+ var all = {};
+
+ CSSLint.getRules().forEach(function(x){
+ all[x.id] = true;
+ });
+ ruleNames.forEach(function(x) {
+ delete all[x];
+ });
+
+ this.ruleset = all;
+ }
+ this.doc.getValue() && this.deferredUpdate.schedule(100);
+ };
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ if (!value)
+ return this.sender.emit("annotate", []);
+ var infoRules = this.infoRules;
+
+ var result = CSSLint.verify(value, this.ruleset);
+ this.sender.emit("annotate", result.messages.map(function(msg) {
+ return {
+ row: msg.line - 1,
+ column: msg.col - 1,
+ text: msg.message,
+ type: infoRules[msg.rule.id] ? "info" : msg.type,
+ rule: msg.rule.name
+ }
+ }));
+ };
+
+}).call(Worker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-html.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-html.js
new file mode 100644
index 00000000..ccb04e91
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-html.js
@@ -0,0 +1,11605 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/html/saxparser",["require","exports","module"], function(require, exports, module) {
+module.exports = (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({
+1:[function(_dereq_,module,exports){
+function isScopeMarker(node) {
+ if (node.namespaceURI === "http://www.w3.org/1999/xhtml") {
+ return node.localName === "applet"
+ || node.localName === "caption"
+ || node.localName === "marquee"
+ || node.localName === "object"
+ || node.localName === "table"
+ || node.localName === "td"
+ || node.localName === "th";
+ }
+ if (node.namespaceURI === "http://www.w3.org/1998/Math/MathML") {
+ return node.localName === "mi"
+ || node.localName === "mo"
+ || node.localName === "mn"
+ || node.localName === "ms"
+ || node.localName === "mtext"
+ || node.localName === "annotation-xml";
+ }
+ if (node.namespaceURI === "http://www.w3.org/2000/svg") {
+ return node.localName === "foreignObject"
+ || node.localName === "desc"
+ || node.localName === "title";
+ }
+}
+
+function isListItemScopeMarker(node) {
+ return isScopeMarker(node)
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'ol')
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'ul');
+}
+
+function isTableScopeMarker(node) {
+ return (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'table')
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'html');
+}
+
+function isTableBodyScopeMarker(node) {
+ return (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'tbody')
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'tfoot')
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'thead')
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'html');
+}
+
+function isTableRowScopeMarker(node) {
+ return (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'tr')
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'html');
+}
+
+function isButtonScopeMarker(node) {
+ return isScopeMarker(node)
+ || (node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'button');
+}
+
+function isSelectScopeMarker(node) {
+ return !(node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'optgroup')
+ && !(node.namespaceURI === "http://www.w3.org/1999/xhtml" && node.localName === 'option');
+}
+function ElementStack() {
+ this.elements = [];
+ this.rootNode = null;
+ this.headElement = null;
+ this.bodyElement = null;
+}
+ElementStack.prototype._inScope = function(localName, isMarker) {
+ for (var i = this.elements.length - 1; i >= 0; i--) {
+ var node = this.elements[i];
+ if (node.localName === localName)
+ return true;
+ if (isMarker(node))
+ return false;
+ }
+};
+ElementStack.prototype.push = function(item) {
+ this.elements.push(item);
+};
+ElementStack.prototype.pushHtmlElement = function(item) {
+ this.rootNode = item.node;
+ this.push(item);
+};
+ElementStack.prototype.pushHeadElement = function(item) {
+ this.headElement = item.node;
+ this.push(item);
+};
+ElementStack.prototype.pushBodyElement = function(item) {
+ this.bodyElement = item.node;
+ this.push(item);
+};
+ElementStack.prototype.pop = function() {
+ return this.elements.pop();
+};
+ElementStack.prototype.remove = function(item) {
+ this.elements.splice(this.elements.indexOf(item), 1);
+};
+ElementStack.prototype.popUntilPopped = function(localName) {
+ var element;
+ do {
+ element = this.pop();
+ } while (element.localName != localName);
+};
+
+ElementStack.prototype.popUntilTableScopeMarker = function() {
+ while (!isTableScopeMarker(this.top))
+ this.pop();
+};
+
+ElementStack.prototype.popUntilTableBodyScopeMarker = function() {
+ while (!isTableBodyScopeMarker(this.top))
+ this.pop();
+};
+
+ElementStack.prototype.popUntilTableRowScopeMarker = function() {
+ while (!isTableRowScopeMarker(this.top))
+ this.pop();
+};
+ElementStack.prototype.item = function(index) {
+ return this.elements[index];
+};
+ElementStack.prototype.contains = function(element) {
+ return this.elements.indexOf(element) !== -1;
+};
+ElementStack.prototype.inScope = function(localName) {
+ return this._inScope(localName, isScopeMarker);
+};
+ElementStack.prototype.inListItemScope = function(localName) {
+ return this._inScope(localName, isListItemScopeMarker);
+};
+ElementStack.prototype.inTableScope = function(localName) {
+ return this._inScope(localName, isTableScopeMarker);
+};
+ElementStack.prototype.inButtonScope = function(localName) {
+ return this._inScope(localName, isButtonScopeMarker);
+};
+ElementStack.prototype.inSelectScope = function(localName) {
+ return this._inScope(localName, isSelectScopeMarker);
+};
+ElementStack.prototype.hasNumberedHeaderElementInScope = function() {
+ for (var i = this.elements.length - 1; i >= 0; i--) {
+ var node = this.elements[i];
+ if (node.isNumberedHeader())
+ return true;
+ if (isScopeMarker(node))
+ return false;
+ }
+};
+ElementStack.prototype.furthestBlockForFormattingElement = function(element) {
+ var furthestBlock = null;
+ for (var i = this.elements.length - 1; i >= 0; i--) {
+ var node = this.elements[i];
+ if (node.node === element)
+ break;
+ if (node.isSpecial())
+ furthestBlock = node;
+ }
+ return furthestBlock;
+};
+ElementStack.prototype.findIndex = function(localName) {
+ for (var i = this.elements.length - 1; i >= 0; i--) {
+ if (this.elements[i].localName == localName)
+ return i;
+ }
+ return -1;
+};
+
+ElementStack.prototype.remove_openElements_until = function(callback) {
+ var finished = false;
+ var element;
+ while (!finished) {
+ element = this.elements.pop();
+ finished = callback(element);
+ }
+ return element;
+};
+
+Object.defineProperty(ElementStack.prototype, 'top', {
+ get: function() {
+ return this.elements[this.elements.length - 1];
+ }
+});
+
+Object.defineProperty(ElementStack.prototype, 'length', {
+ get: function() {
+ return this.elements.length;
+ }
+});
+
+exports.ElementStack = ElementStack;
+
+},
+{}],
+2:[function(_dereq_,module,exports){
+var entities = _dereq_('html5-entities');
+var InputStream = _dereq_('./InputStream').InputStream;
+
+var namedEntityPrefixes = {};
+Object.keys(entities).forEach(function (entityKey) {
+ for (var i = 0; i < entityKey.length; i++) {
+ namedEntityPrefixes[entityKey.substring(0, i + 1)] = true;
+ }
+});
+
+function isAlphaNumeric(c) {
+ return (c >= '0' && c <= '9') || (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z');
+}
+
+function isHexDigit(c) {
+ return (c >= '0' && c <= '9') || (c >= 'a' && c <= 'f') || (c >= 'A' && c <= 'F');
+}
+
+function isDecimalDigit(c) {
+ return (c >= '0' && c <= '9');
+}
+
+var EntityParser = {};
+
+EntityParser.consumeEntity = function(buffer, tokenizer, additionalAllowedCharacter) {
+ var decodedCharacter = '';
+ var consumedCharacters = '';
+ var ch = buffer.char();
+ if (ch === InputStream.EOF)
+ return false;
+ consumedCharacters += ch;
+ if (ch == '\t' || ch == '\n' || ch == '\v' || ch == ' ' || ch == '<' || ch == '&') {
+ buffer.unget(consumedCharacters);
+ return false;
+ }
+ if (additionalAllowedCharacter === ch) {
+ buffer.unget(consumedCharacters);
+ return false;
+ }
+ if (ch == '#') {
+ ch = buffer.shift(1);
+ if (ch === InputStream.EOF) {
+ tokenizer._parseError("expected-numeric-entity-but-got-eof");
+ buffer.unget(consumedCharacters);
+ return false;
+ }
+ consumedCharacters += ch;
+ var radix = 10;
+ var isDigit = isDecimalDigit;
+ if (ch == 'x' || ch == 'X') {
+ radix = 16;
+ isDigit = isHexDigit;
+ ch = buffer.shift(1);
+ if (ch === InputStream.EOF) {
+ tokenizer._parseError("expected-numeric-entity-but-got-eof");
+ buffer.unget(consumedCharacters);
+ return false;
+ }
+ consumedCharacters += ch;
+ }
+ if (isDigit(ch)) {
+ var code = '';
+ while (ch !== InputStream.EOF && isDigit(ch)) {
+ code += ch;
+ ch = buffer.char();
+ }
+ code = parseInt(code, radix);
+ var replacement = this.replaceEntityNumbers(code);
+ if (replacement) {
+ tokenizer._parseError("invalid-numeric-entity-replaced");
+ code = replacement;
+ }
+ if (code > 0xFFFF && code <= 0x10FFFF) {
+ code -= 0x10000;
+ var first = ((0xffc00 & code) >> 10) + 0xD800;
+ var second = (0x3ff & code) + 0xDC00;
+ decodedCharacter = String.fromCharCode(first, second);
+ } else
+ decodedCharacter = String.fromCharCode(code);
+ if (ch !== ';') {
+ tokenizer._parseError("numeric-entity-without-semicolon");
+ buffer.unget(ch);
+ }
+ return decodedCharacter;
+ }
+ buffer.unget(consumedCharacters);
+ tokenizer._parseError("expected-numeric-entity");
+ return false;
+ }
+ if ((ch >= 'a' && ch <= 'z') || (ch >= 'A' && ch <= 'Z')) {
+ var mostRecentMatch = '';
+ while (namedEntityPrefixes[consumedCharacters]) {
+ if (entities[consumedCharacters]) {
+ mostRecentMatch = consumedCharacters;
+ }
+ if (ch == ';')
+ break;
+ ch = buffer.char();
+ if (ch === InputStream.EOF)
+ break;
+ consumedCharacters += ch;
+ }
+ if (!mostRecentMatch) {
+ tokenizer._parseError("expected-named-entity");
+ buffer.unget(consumedCharacters);
+ return false;
+ }
+ decodedCharacter = entities[mostRecentMatch];
+ if (ch === ';' || !additionalAllowedCharacter || !(isAlphaNumeric(ch) || ch === '=')) {
+ if (consumedCharacters.length > mostRecentMatch.length) {
+ buffer.unget(consumedCharacters.substring(mostRecentMatch.length));
+ }
+ if (ch !== ';') {
+ tokenizer._parseError("named-entity-without-semicolon");
+ }
+ return decodedCharacter;
+ }
+ buffer.unget(consumedCharacters);
+ return false;
+ }
+};
+
+EntityParser.replaceEntityNumbers = function(c) {
+ switch(c) {
+ case 0x00: return 0xFFFD; // REPLACEMENT CHARACTER
+ case 0x13: return 0x0010; // Carriage return
+ case 0x80: return 0x20AC; // EURO SIGN
+ case 0x81: return 0x0081; // <control>
+ case 0x82: return 0x201A; // SINGLE LOW-9 QUOTATION MARK
+ case 0x83: return 0x0192; // LATIN SMALL LETTER F WITH HOOK
+ case 0x84: return 0x201E; // DOUBLE LOW-9 QUOTATION MARK
+ case 0x85: return 0x2026; // HORIZONTAL ELLIPSIS
+ case 0x86: return 0x2020; // DAGGER
+ case 0x87: return 0x2021; // DOUBLE DAGGER
+ case 0x88: return 0x02C6; // MODIFIER LETTER CIRCUMFLEX ACCENT
+ case 0x89: return 0x2030; // PER MILLE SIGN
+ case 0x8A: return 0x0160; // LATIN CAPITAL LETTER S WITH CARON
+ case 0x8B: return 0x2039; // SINGLE LEFT-POINTING ANGLE QUOTATION MARK
+ case 0x8C: return 0x0152; // LATIN CAPITAL LIGATURE OE
+ case 0x8D: return 0x008D; // <control>
+ case 0x8E: return 0x017D; // LATIN CAPITAL LETTER Z WITH CARON
+ case 0x8F: return 0x008F; // <control>
+ case 0x90: return 0x0090; // <control>
+ case 0x91: return 0x2018; // LEFT SINGLE QUOTATION MARK
+ case 0x92: return 0x2019; // RIGHT SINGLE QUOTATION MARK
+ case 0x93: return 0x201C; // LEFT DOUBLE QUOTATION MARK
+ case 0x94: return 0x201D; // RIGHT DOUBLE QUOTATION MARK
+ case 0x95: return 0x2022; // BULLET
+ case 0x96: return 0x2013; // EN DASH
+ case 0x97: return 0x2014; // EM DASH
+ case 0x98: return 0x02DC; // SMALL TILDE
+ case 0x99: return 0x2122; // TRADE MARK SIGN
+ case 0x9A: return 0x0161; // LATIN SMALL LETTER S WITH CARON
+ case 0x9B: return 0x203A; // SINGLE RIGHT-POINTING ANGLE QUOTATION MARK
+ case 0x9C: return 0x0153; // LATIN SMALL LIGATURE OE
+ case 0x9D: return 0x009D; // <control>
+ case 0x9E: return 0x017E; // LATIN SMALL LETTER Z WITH CARON
+ case 0x9F: return 0x0178; // LATIN CAPITAL LETTER Y WITH DIAERESIS
+ default:
+ if ((c >= 0xD800 && c <= 0xDFFF) || c > 0x10FFFF) {
+ return 0xFFFD;
+ } else if ((c >= 0x0001 && c <= 0x0008) || (c >= 0x000E && c <= 0x001F) ||
+ (c >= 0x007F && c <= 0x009F) || (c >= 0xFDD0 && c <= 0xFDEF) ||
+ c == 0x000B || c == 0xFFFE || c == 0x1FFFE || c == 0x2FFFFE ||
+ c == 0x2FFFF || c == 0x3FFFE || c == 0x3FFFF || c == 0x4FFFE ||
+ c == 0x4FFFF || c == 0x5FFFE || c == 0x5FFFF || c == 0x6FFFE ||
+ c == 0x6FFFF || c == 0x7FFFE || c == 0x7FFFF || c == 0x8FFFE ||
+ c == 0x8FFFF || c == 0x9FFFE || c == 0x9FFFF || c == 0xAFFFE ||
+ c == 0xAFFFF || c == 0xBFFFE || c == 0xBFFFF || c == 0xCFFFE ||
+ c == 0xCFFFF || c == 0xDFFFE || c == 0xDFFFF || c == 0xEFFFE ||
+ c == 0xEFFFF || c == 0xFFFFE || c == 0xFFFFF || c == 0x10FFFE ||
+ c == 0x10FFFF) {
+ return c;
+ }
+ }
+};
+
+exports.EntityParser = EntityParser;
+
+},
+{"./InputStream":3,"html5-entities":12}],
+3:[function(_dereq_,module,exports){
+function InputStream() {
+ this.data = '';
+ this.start = 0;
+ this.committed = 0;
+ this.eof = false;
+ this.lastLocation = {line: 0, column: 0};
+}
+
+InputStream.EOF = -1;
+
+InputStream.DRAIN = -2;
+
+InputStream.prototype = {
+ slice: function() {
+ if(this.start >= this.data.length) {
+ if(!this.eof) throw InputStream.DRAIN;
+ return InputStream.EOF;
+ }
+ return this.data.slice(this.start, this.data.length);
+ },
+ char: function() {
+ if(!this.eof && this.start >= this.data.length - 1) throw InputStream.DRAIN;
+ if(this.start >= this.data.length) {
+ return InputStream.EOF;
+ }
+ var ch = this.data[this.start++];
+ if (ch === '\r')
+ ch = '\n';
+ return ch;
+ },
+ advance: function(amount) {
+ this.start += amount;
+ if(this.start >= this.data.length) {
+ if(!this.eof) throw InputStream.DRAIN;
+ return InputStream.EOF;
+ } else {
+ if(this.committed > this.data.length / 2) {
+ this.lastLocation = this.location();
+ this.data = this.data.slice(this.committed);
+ this.start = this.start - this.committed;
+ this.committed = 0;
+ }
+ }
+ },
+ matchWhile: function(re) {
+ if(this.eof && this.start >= this.data.length ) return '';
+ var r = new RegExp("^"+re+"+");
+ var m = r.exec(this.slice());
+ if(m) {
+ if(!this.eof && m[0].length == this.data.length - this.start) throw InputStream.DRAIN;
+ this.advance(m[0].length);
+ return m[0];
+ } else {
+ return '';
+ }
+ },
+ matchUntil: function(re) {
+ var m, s;
+ s = this.slice();
+ if(s === InputStream.EOF) {
+ return '';
+ } else if(m = new RegExp(re + (this.eof ? "|$" : "")).exec(s)) {
+ var t = this.data.slice(this.start, this.start + m.index);
+ this.advance(m.index);
+ return t.replace(/\r/g, '\n').replace(/\n{2,}/g, '\n');
+ } else {
+ throw InputStream.DRAIN;
+ }
+ },
+ append: function(data) {
+ this.data += data;
+ },
+ shift: function(n) {
+ if(!this.eof && this.start + n >= this.data.length) throw InputStream.DRAIN;
+ if(this.eof && this.start >= this.data.length) return InputStream.EOF;
+ var d = this.data.slice(this.start, this.start + n).toString();
+ this.advance(Math.min(n, this.data.length - this.start));
+ return d;
+ },
+ peek: function(n) {
+ if(!this.eof && this.start + n >= this.data.length) throw InputStream.DRAIN;
+ if(this.eof && this.start >= this.data.length) return InputStream.EOF;
+ return this.data.slice(this.start, Math.min(this.start + n, this.data.length)).toString();
+ },
+ length: function() {
+ return this.data.length - this.start - 1;
+ },
+ unget: function(d) {
+ if(d === InputStream.EOF) return;
+ this.start -= (d.length);
+ },
+ undo: function() {
+ this.start = this.committed;
+ },
+ commit: function() {
+ this.committed = this.start;
+ },
+ location: function() {
+ var lastLine = this.lastLocation.line;
+ var lastColumn = this.lastLocation.column;
+ var read = this.data.slice(0, this.committed);
+ var newlines = read.match(/\n/g);
+ var line = newlines ? lastLine + newlines.length : lastLine;
+ var column = newlines ? read.length - read.lastIndexOf('\n') - 1 : lastColumn + read.length;
+ return {line: line, column: column};
+ }
+};
+
+exports.InputStream = InputStream;
+
+},
+{}],
+4:[function(_dereq_,module,exports){
+var SpecialElements = {
+ "http://www.w3.org/1999/xhtml": [
+ 'address',
+ 'applet',
+ 'area',
+ 'article',
+ 'aside',
+ 'base',
+ 'basefont',
+ 'bgsound',
+ 'blockquote',
+ 'body',
+ 'br',
+ 'button',
+ 'caption',
+ 'center',
+ 'col',
+ 'colgroup',
+ 'dd',
+ 'details',
+ 'dir',
+ 'div',
+ 'dl',
+ 'dt',
+ 'embed',
+ 'fieldset',
+ 'figcaption',
+ 'figure',
+ 'footer',
+ 'form',
+ 'frame',
+ 'frameset',
+ 'h1',
+ 'h2',
+ 'h3',
+ 'h4',
+ 'h5',
+ 'h6',
+ 'head',
+ 'header',
+ 'hgroup',
+ 'hr',
+ 'html',
+ 'iframe',
+ 'img',
+ 'input',
+ 'isindex',
+ 'li',
+ 'link',
+ 'listing',
+ 'main',
+ 'marquee',
+ 'menu',
+ 'menuitem',
+ 'meta',
+ 'nav',
+ 'noembed',
+ 'noframes',
+ 'noscript',
+ 'object',
+ 'ol',
+ 'p',
+ 'param',
+ 'plaintext',
+ 'pre',
+ 'script',
+ 'section',
+ 'select',
+ 'source',
+ 'style',
+ 'summary',
+ 'table',
+ 'tbody',
+ 'td',
+ 'textarea',
+ 'tfoot',
+ 'th',
+ 'thead',
+ 'title',
+ 'tr',
+ 'track',
+ 'ul',
+ 'wbr',
+ 'xmp'
+ ],
+ "http://www.w3.org/1998/Math/MathML": [
+ 'mi',
+ 'mo',
+ 'mn',
+ 'ms',
+ 'mtext',
+ 'annotation-xml'
+ ],
+ "http://www.w3.org/2000/svg": [
+ 'foreignObject',
+ 'desc',
+ 'title'
+ ]
+};
+
+
+function StackItem(namespaceURI, localName, attributes, node) {
+ this.localName = localName;
+ this.namespaceURI = namespaceURI;
+ this.attributes = attributes;
+ this.node = node;
+}
+StackItem.prototype.isSpecial = function() {
+ return this.namespaceURI in SpecialElements &&
+ SpecialElements[this.namespaceURI].indexOf(this.localName) > -1;
+};
+
+StackItem.prototype.isFosterParenting = function() {
+ if (this.namespaceURI === "http://www.w3.org/1999/xhtml") {
+ return this.localName === 'table' ||
+ this.localName === 'tbody' ||
+ this.localName === 'tfoot' ||
+ this.localName === 'thead' ||
+ this.localName === 'tr';
+ }
+ return false;
+};
+
+StackItem.prototype.isNumberedHeader = function() {
+ if (this.namespaceURI === "http://www.w3.org/1999/xhtml") {
+ return this.localName === 'h1' ||
+ this.localName === 'h2' ||
+ this.localName === 'h3' ||
+ this.localName === 'h4' ||
+ this.localName === 'h5' ||
+ this.localName === 'h6';
+ }
+ return false;
+};
+
+StackItem.prototype.isForeign = function() {
+ return this.namespaceURI != "http://www.w3.org/1999/xhtml";
+};
+
+function getAttribute(item, name) {
+ for (var i = 0; i < item.attributes.length; i++) {
+ if (item.attributes[i].nodeName == name)
+ return item.attributes[i].nodeValue;
+ }
+ return null;
+}
+
+StackItem.prototype.isHtmlIntegrationPoint = function() {
+ if (this.namespaceURI === "http://www.w3.org/1998/Math/MathML") {
+ if (this.localName !== "annotation-xml")
+ return false;
+ var encoding = getAttribute(this, 'encoding');
+ if (!encoding)
+ return false;
+ encoding = encoding.toLowerCase();
+ return encoding === "text/html" || encoding === "application/xhtml+xml";
+ }
+ if (this.namespaceURI === "http://www.w3.org/2000/svg") {
+ return this.localName === "foreignObject"
+ || this.localName === "desc"
+ || this.localName === "title";
+ }
+ return false;
+};
+
+StackItem.prototype.isMathMLTextIntegrationPoint = function() {
+ if (this.namespaceURI === "http://www.w3.org/1998/Math/MathML") {
+ return this.localName === "mi"
+ || this.localName === "mo"
+ || this.localName === "mn"
+ || this.localName === "ms"
+ || this.localName === "mtext";
+ }
+ return false;
+};
+
+exports.StackItem = StackItem;
+
+},
+{}],
+5:[function(_dereq_,module,exports){
+var InputStream = _dereq_('./InputStream').InputStream;
+var EntityParser = _dereq_('./EntityParser').EntityParser;
+
+function isWhitespace(c){
+ return c === " " || c === "\n" || c === "\t" || c === "\r" || c === "\f";
+}
+
+function isAlpha(c) {
+ return (c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z');
+}
+function Tokenizer(tokenHandler) {
+ this._tokenHandler = tokenHandler;
+ this._state = Tokenizer.DATA;
+ this._inputStream = new InputStream();
+ this._currentToken = null;
+ this._temporaryBuffer = '';
+ this._additionalAllowedCharacter = '';
+}
+
+Tokenizer.prototype._parseError = function(code, args) {
+ this._tokenHandler.parseError(code, args);
+};
+
+Tokenizer.prototype._emitToken = function(token) {
+ if (token.type === 'StartTag') {
+ for (var i = 1; i < token.data.length; i++) {
+ if (!token.data[i].nodeName)
+ token.data.splice(i--, 1);
+ }
+ } else if (token.type === 'EndTag') {
+ if (token.selfClosing) {
+ this._parseError('self-closing-flag-on-end-tag');
+ }
+ if (token.data.length !== 0) {
+ this._parseError('attributes-in-end-tag');
+ }
+ }
+ this._tokenHandler.processToken(token);
+ if (token.type === 'StartTag' && token.selfClosing && !this._tokenHandler.isSelfClosingFlagAcknowledged()) {
+ this._parseError('non-void-element-with-trailing-solidus', {name: token.name});
+ }
+};
+
+Tokenizer.prototype._emitCurrentToken = function() {
+ this._state = Tokenizer.DATA;
+ this._emitToken(this._currentToken);
+};
+
+Tokenizer.prototype._currentAttribute = function() {
+ return this._currentToken.data[this._currentToken.data.length - 1];
+};
+
+Tokenizer.prototype.setState = function(state) {
+ this._state = state;
+};
+
+Tokenizer.prototype.tokenize = function(source) {
+ Tokenizer.DATA = data_state;
+ Tokenizer.RCDATA = rcdata_state;
+ Tokenizer.RAWTEXT = rawtext_state;
+ Tokenizer.SCRIPT_DATA = script_data_state;
+ Tokenizer.PLAINTEXT = plaintext_state;
+
+
+ this._state = Tokenizer.DATA;
+
+ this._inputStream.append(source);
+
+ this._tokenHandler.startTokenization(this);
+
+ this._inputStream.eof = true;
+
+ var tokenizer = this;
+
+ while (this._state.call(this, this._inputStream));
+
+
+ function data_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._emitToken({type: 'EOF', data: null});
+ return false;
+ } else if (data === '&') {
+ tokenizer.setState(character_reference_in_data_state);
+ } else if (data === '<') {
+ tokenizer.setState(tag_open_state);
+ } else if (data === '\u0000') {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ buffer.commit();
+ } else {
+ var chars = buffer.matchUntil("&|<|\u0000");
+ tokenizer._emitToken({type: 'Characters', data: data + chars});
+ buffer.commit();
+ }
+ return true;
+ }
+
+ function character_reference_in_data_state(buffer) {
+ var character = EntityParser.consumeEntity(buffer, tokenizer);
+ tokenizer.setState(data_state);
+ tokenizer._emitToken({type: 'Characters', data: character || '&'});
+ return true;
+ }
+
+ function rcdata_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._emitToken({type: 'EOF', data: null});
+ return false;
+ } else if (data === '&') {
+ tokenizer.setState(character_reference_in_rcdata_state);
+ } else if (data === '<') {
+ tokenizer.setState(rcdata_less_than_sign_state);
+ } else if (data === "\u0000") {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ buffer.commit();
+ } else {
+ var chars = buffer.matchUntil("&|<|\u0000");
+ tokenizer._emitToken({type: 'Characters', data: data + chars});
+ buffer.commit();
+ }
+ return true;
+ }
+
+ function character_reference_in_rcdata_state(buffer) {
+ var character = EntityParser.consumeEntity(buffer, tokenizer);
+ tokenizer.setState(rcdata_state);
+ tokenizer._emitToken({type: 'Characters', data: character || '&'});
+ return true;
+ }
+
+ function rawtext_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._emitToken({type: 'EOF', data: null});
+ return false;
+ } else if (data === '<') {
+ tokenizer.setState(rawtext_less_than_sign_state);
+ } else if (data === "\u0000") {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ buffer.commit();
+ } else {
+ var chars = buffer.matchUntil("<|\u0000");
+ tokenizer._emitToken({type: 'Characters', data: data + chars});
+ }
+ return true;
+ }
+
+ function plaintext_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._emitToken({type: 'EOF', data: null});
+ return false;
+ } else if (data === "\u0000") {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ buffer.commit();
+ } else {
+ var chars = buffer.matchUntil("\u0000");
+ tokenizer._emitToken({type: 'Characters', data: data + chars});
+ }
+ return true;
+ }
+
+
+ function script_data_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._emitToken({type: 'EOF', data: null});
+ return false;
+ } else if (data === '<') {
+ tokenizer.setState(script_data_less_than_sign_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ buffer.commit();
+ } else {
+ var chars = buffer.matchUntil("<|\u0000");
+ tokenizer._emitToken({type: 'Characters', data: data + chars});
+ }
+ return true;
+ }
+
+ function rcdata_less_than_sign_state(buffer) {
+ var data = buffer.char();
+ if (data === "/") {
+ this._temporaryBuffer = '';
+ tokenizer.setState(rcdata_end_tag_open_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ buffer.unget(data);
+ tokenizer.setState(rcdata_state);
+ }
+ return true;
+ }
+
+ function rcdata_end_tag_open_state(buffer) {
+ var data = buffer.char();
+ if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ tokenizer.setState(rcdata_end_tag_name_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</'});
+ buffer.unget(data);
+ tokenizer.setState(rcdata_state);
+ }
+ return true;
+ }
+
+ function rcdata_end_tag_name_state(buffer) {
+ var appropriate = tokenizer._currentToken && (tokenizer._currentToken.name === this._temporaryBuffer.toLowerCase());
+ var data = buffer.char();
+ if (isWhitespace(data) && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: this._temporaryBuffer, data: [], selfClosing: false};
+ tokenizer.setState(before_attribute_name_state);
+ } else if (data === '/' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: this._temporaryBuffer, data: [], selfClosing: false};
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === '>' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: this._temporaryBuffer, data: [], selfClosing: false};
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ buffer.commit();
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</' + this._temporaryBuffer});
+ buffer.unget(data);
+ tokenizer.setState(rcdata_state);
+ }
+ return true;
+ }
+
+ function rawtext_less_than_sign_state(buffer) {
+ var data = buffer.char();
+ if (data === "/") {
+ this._temporaryBuffer = '';
+ tokenizer.setState(rawtext_end_tag_open_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ buffer.unget(data);
+ tokenizer.setState(rawtext_state);
+ }
+ return true;
+ }
+
+ function rawtext_end_tag_open_state(buffer) {
+ var data = buffer.char();
+ if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ tokenizer.setState(rawtext_end_tag_name_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</'});
+ buffer.unget(data);
+ tokenizer.setState(rawtext_state);
+ }
+ return true;
+ }
+
+ function rawtext_end_tag_name_state(buffer) {
+ var appropriate = tokenizer._currentToken && (tokenizer._currentToken.name === this._temporaryBuffer.toLowerCase());
+ var data = buffer.char();
+ if (isWhitespace(data) && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: this._temporaryBuffer, data: [], selfClosing: false};
+ tokenizer.setState(before_attribute_name_state);
+ } else if (data === '/' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: this._temporaryBuffer, data: [], selfClosing: false};
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === '>' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: this._temporaryBuffer, data: [], selfClosing: false};
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ buffer.commit();
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</' + this._temporaryBuffer});
+ buffer.unget(data);
+ tokenizer.setState(rawtext_state);
+ }
+ return true;
+ }
+
+ function script_data_less_than_sign_state(buffer) {
+ var data = buffer.char();
+ if (data === "/") {
+ this._temporaryBuffer = '';
+ tokenizer.setState(script_data_end_tag_open_state);
+ } else if (data === '!') {
+ tokenizer._emitToken({type: 'Characters', data: '<!'});
+ tokenizer.setState(script_data_escape_start_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ buffer.unget(data);
+ tokenizer.setState(script_data_state);
+ }
+ return true;
+ }
+
+ function script_data_end_tag_open_state(buffer) {
+ var data = buffer.char();
+ if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ tokenizer.setState(script_data_end_tag_name_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</'});
+ buffer.unget(data);
+ tokenizer.setState(script_data_state);
+ }
+ return true;
+ }
+
+ function script_data_end_tag_name_state(buffer) {
+ var appropriate = tokenizer._currentToken && (tokenizer._currentToken.name === this._temporaryBuffer.toLowerCase());
+ var data = buffer.char();
+ if (isWhitespace(data) && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: 'script', data: [], selfClosing: false};
+ tokenizer.setState(before_attribute_name_state);
+ } else if (data === '/' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: 'script', data: [], selfClosing: false};
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === '>' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: 'script', data: [], selfClosing: false};
+ tokenizer._emitCurrentToken();
+ } else if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ buffer.commit();
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</' + this._temporaryBuffer});
+ buffer.unget(data);
+ tokenizer.setState(script_data_state);
+ }
+ return true;
+ }
+
+ function script_data_escape_start_state(buffer) {
+ var data = buffer.char();
+ if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ tokenizer.setState(script_data_escape_start_dash_state);
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(script_data_state);
+ }
+ return true;
+ }
+
+ function script_data_escape_start_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ tokenizer.setState(script_data_escaped_dash_dash_state);
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(script_data_state);
+ }
+ return true;
+ }
+
+ function script_data_escaped_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ tokenizer.setState(script_data_escaped_dash_state);
+ } else if (data === '<') {
+ tokenizer.setState(script_data_escaped_less_then_sign_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ buffer.commit();
+ } else {
+ var chars = buffer.matchUntil('<|-|\u0000');
+ tokenizer._emitToken({type: 'Characters', data: data + chars});
+ }
+ return true;
+ }
+
+ function script_data_escaped_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ tokenizer.setState(script_data_escaped_dash_dash_state);
+ } else if (data === '<') {
+ tokenizer.setState(script_data_escaped_less_then_sign_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ tokenizer.setState(script_data_escaped_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ tokenizer.setState(script_data_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_escaped_dash_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError('eof-in-script');
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '<') {
+ tokenizer.setState(script_data_escaped_less_then_sign_state);
+ } else if (data === '>') {
+ tokenizer._emitToken({type: 'Characters', data: '>'});
+ tokenizer.setState(script_data_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ tokenizer.setState(script_data_escaped_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ tokenizer.setState(script_data_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_escaped_less_then_sign_state(buffer) {
+ var data = buffer.char();
+ if (data === '/') {
+ this._temporaryBuffer = '';
+ tokenizer.setState(script_data_escaped_end_tag_open_state);
+ } else if (isAlpha(data)) {
+ tokenizer._emitToken({type: 'Characters', data: '<' + data});
+ this._temporaryBuffer = data;
+ tokenizer.setState(script_data_double_escape_start_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ buffer.unget(data);
+ tokenizer.setState(script_data_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_escaped_end_tag_open_state(buffer) {
+ var data = buffer.char();
+ if (isAlpha(data)) {
+ this._temporaryBuffer = data;
+ tokenizer.setState(script_data_escaped_end_tag_name_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</'});
+ buffer.unget(data);
+ tokenizer.setState(script_data_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_escaped_end_tag_name_state(buffer) {
+ var appropriate = tokenizer._currentToken && (tokenizer._currentToken.name === this._temporaryBuffer.toLowerCase());
+ var data = buffer.char();
+ if (isWhitespace(data) && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: 'script', data: [], selfClosing: false};
+ tokenizer.setState(before_attribute_name_state);
+ } else if (data === '/' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: 'script', data: [], selfClosing: false};
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === '>' && appropriate) {
+ tokenizer._currentToken = {type: 'EndTag', name: 'script', data: [], selfClosing: false};
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isAlpha(data)) {
+ this._temporaryBuffer += data;
+ buffer.commit();
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: '</' + this._temporaryBuffer});
+ buffer.unget(data);
+ tokenizer.setState(script_data_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_double_escape_start_state(buffer) {
+ var data = buffer.char();
+ if (isWhitespace(data) || data === '/' || data === '>') {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ if (this._temporaryBuffer.toLowerCase() === 'script')
+ tokenizer.setState(script_data_double_escaped_state);
+ else
+ tokenizer.setState(script_data_escaped_state);
+ } else if (isAlpha(data)) {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ this._temporaryBuffer += data;
+ buffer.commit();
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(script_data_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_double_escaped_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError('eof-in-script');
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ tokenizer.setState(script_data_double_escaped_dash_state);
+ } else if (data === '<') {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ tokenizer.setState(script_data_double_escaped_less_than_sign_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError('invalid-codepoint');
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ buffer.commit();
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ buffer.commit();
+ }
+ return true;
+ }
+
+ function script_data_double_escaped_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError('eof-in-script');
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ tokenizer.setState(script_data_double_escaped_dash_dash_state);
+ } else if (data === '<') {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ tokenizer.setState(script_data_double_escaped_less_than_sign_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError('invalid-codepoint');
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ tokenizer.setState(script_data_double_escaped_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ tokenizer.setState(script_data_double_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_double_escaped_dash_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError('eof-in-script');
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer._emitToken({type: 'Characters', data: '-'});
+ buffer.commit();
+ } else if (data === '<') {
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ tokenizer.setState(script_data_double_escaped_less_than_sign_state);
+ } else if (data === '>') {
+ tokenizer._emitToken({type: 'Characters', data: '>'});
+ tokenizer.setState(script_data_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError('invalid-codepoint');
+ tokenizer._emitToken({type: 'Characters', data: '\uFFFD'});
+ tokenizer.setState(script_data_double_escaped_state);
+ } else {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ tokenizer.setState(script_data_double_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_double_escaped_less_than_sign_state(buffer) {
+ var data = buffer.char();
+ if (data === '/') {
+ tokenizer._emitToken({type: 'Characters', data: '/'});
+ this._temporaryBuffer = '';
+ tokenizer.setState(script_data_double_escape_end_state);
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(script_data_double_escaped_state);
+ }
+ return true;
+ }
+
+ function script_data_double_escape_end_state(buffer) {
+ var data = buffer.char();
+ if (isWhitespace(data) || data === '/' || data === '>') {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ if (this._temporaryBuffer.toLowerCase() === 'script')
+ tokenizer.setState(script_data_escaped_state);
+ else
+ tokenizer.setState(script_data_double_escaped_state);
+ } else if (isAlpha(data)) {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ this._temporaryBuffer += data;
+ buffer.commit();
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(script_data_double_escaped_state);
+ }
+ return true;
+ }
+
+ function tag_open_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("bare-less-than-sign-at-eof");
+ tokenizer._emitToken({type: 'Characters', data: '<'});
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isAlpha(data)) {
+ tokenizer._currentToken = {type: 'StartTag', name: data.toLowerCase(), data: []};
+ tokenizer.setState(tag_name_state);
+ } else if (data === '!') {
+ tokenizer.setState(markup_declaration_open_state);
+ } else if (data === '/') {
+ tokenizer.setState(close_tag_open_state);
+ } else if (data === '>') {
+ tokenizer._parseError("expected-tag-name-but-got-right-bracket");
+ tokenizer._emitToken({type: 'Characters', data: "<>"});
+ tokenizer.setState(data_state);
+ } else if (data === '?') {
+ tokenizer._parseError("expected-tag-name-but-got-question-mark");
+ buffer.unget(data);
+ tokenizer.setState(bogus_comment_state);
+ } else {
+ tokenizer._parseError("expected-tag-name");
+ tokenizer._emitToken({type: 'Characters', data: "<"});
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ }
+ return true;
+ }
+
+ function close_tag_open_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("expected-closing-tag-but-got-eof");
+ tokenizer._emitToken({type: 'Characters', data: '</'});
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isAlpha(data)) {
+ tokenizer._currentToken = {type: 'EndTag', name: data.toLowerCase(), data: []};
+ tokenizer.setState(tag_name_state);
+ } else if (data === '>') {
+ tokenizer._parseError("expected-closing-tag-but-got-right-bracket");
+ tokenizer.setState(data_state);
+ } else {
+ tokenizer._parseError("expected-closing-tag-but-got-char", {data: data}); // param 1 is datavars:
+ buffer.unget(data);
+ tokenizer.setState(bogus_comment_state);
+ }
+ return true;
+ }
+
+ function tag_name_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError('eof-in-tag-name');
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(before_attribute_name_state);
+ } else if (isAlpha(data)) {
+ tokenizer._currentToken.name += data.toLowerCase();
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ } else if (data === '/') {
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.name += "\uFFFD";
+ } else {
+ tokenizer._currentToken.name += data;
+ }
+ buffer.commit();
+
+ return true;
+ }
+
+ function before_attribute_name_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("expected-attribute-name-but-got-eof");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ return true;
+ } else if (isAlpha(data)) {
+ tokenizer._currentToken.data.push({nodeName: data.toLowerCase(), nodeValue: ""});
+ tokenizer.setState(attribute_name_state);
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ } else if (data === '/') {
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === "'" || data === '"' || data === '=' || data === '<') {
+ tokenizer._parseError("invalid-character-in-attribute-name");
+ tokenizer._currentToken.data.push({nodeName: data, nodeValue: ""});
+ tokenizer.setState(attribute_name_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data.push({nodeName: "\uFFFD", nodeValue: ""});
+ } else {
+ tokenizer._currentToken.data.push({nodeName: data, nodeValue: ""});
+ tokenizer.setState(attribute_name_state);
+ }
+ return true;
+ }
+
+ function attribute_name_state(buffer) {
+ var data = buffer.char();
+ var leavingThisState = true;
+ var shouldEmit = false;
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-attribute-name");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ shouldEmit = true;
+ } else if (data === '=') {
+ tokenizer.setState(before_attribute_value_state);
+ } else if (isAlpha(data)) {
+ tokenizer._currentAttribute().nodeName += data.toLowerCase();
+ leavingThisState = false;
+ } else if (data === '>') {
+ shouldEmit = true;
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(after_attribute_name_state);
+ } else if (data === '/') {
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === "'" || data === '"') {
+ tokenizer._parseError("invalid-character-in-attribute-name");
+ tokenizer._currentAttribute().nodeName += data;
+ leavingThisState = false;
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentAttribute().nodeName += "\uFFFD";
+ } else {
+ tokenizer._currentAttribute().nodeName += data;
+ leavingThisState = false;
+ }
+
+ if (leavingThisState) {
+ var attributes = tokenizer._currentToken.data;
+ var currentAttribute = attributes[attributes.length - 1];
+ for (var i = attributes.length - 2; i >= 0; i--) {
+ if (currentAttribute.nodeName === attributes[i].nodeName) {
+ tokenizer._parseError("duplicate-attribute", {name: currentAttribute.nodeName});
+ currentAttribute.nodeName = null;
+ break;
+ }
+ }
+ if (shouldEmit)
+ tokenizer._emitCurrentToken();
+ } else {
+ buffer.commit();
+ }
+ return true;
+ }
+
+ function after_attribute_name_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("expected-end-of-tag-but-got-eof");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ return true;
+ } else if (data === '=') {
+ tokenizer.setState(before_attribute_value_state);
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ } else if (isAlpha(data)) {
+ tokenizer._currentToken.data.push({nodeName: data, nodeValue: ""});
+ tokenizer.setState(attribute_name_state);
+ } else if (data === '/') {
+ tokenizer.setState(self_closing_tag_state);
+ } else if (data === "'" || data === '"' || data === '<') {
+ tokenizer._parseError("invalid-character-after-attribute-name");
+ tokenizer._currentToken.data.push({nodeName: data, nodeValue: ""});
+ tokenizer.setState(attribute_name_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data.push({nodeName: "\uFFFD", nodeValue: ""});
+ } else {
+ tokenizer._currentToken.data.push({nodeName: data, nodeValue: ""});
+ tokenizer.setState(attribute_name_state);
+ }
+ return true;
+ }
+
+ function before_attribute_value_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("expected-attribute-value-but-got-eof");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ return true;
+ } else if (data === '"') {
+ tokenizer.setState(attribute_value_double_quoted_state);
+ } else if (data === '&') {
+ tokenizer.setState(attribute_value_unquoted_state);
+ buffer.unget(data);
+ } else if (data === "'") {
+ tokenizer.setState(attribute_value_single_quoted_state);
+ } else if (data === '>') {
+ tokenizer._parseError("expected-attribute-value-but-got-right-bracket");
+ tokenizer._emitCurrentToken();
+ } else if (data === '=' || data === '<' || data === '`') {
+ tokenizer._parseError("unexpected-character-in-unquoted-attribute-value");
+ tokenizer._currentAttribute().nodeValue += data;
+ tokenizer.setState(attribute_value_unquoted_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentAttribute().nodeValue += "\uFFFD";
+ } else {
+ tokenizer._currentAttribute().nodeValue += data;
+ tokenizer.setState(attribute_value_unquoted_state);
+ }
+
+ return true;
+ }
+
+ function attribute_value_double_quoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-attribute-value-double-quote");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '"') {
+ tokenizer.setState(after_attribute_value_state);
+ } else if (data === '&') {
+ this._additionalAllowedCharacter = '"';
+ tokenizer.setState(character_reference_in_attribute_value_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentAttribute().nodeValue += "\uFFFD";
+ } else {
+ var s = buffer.matchUntil('[\0"&]');
+ data = data + s;
+ tokenizer._currentAttribute().nodeValue += data;
+ }
+ return true;
+ }
+
+ function attribute_value_single_quoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-attribute-value-single-quote");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === "'") {
+ tokenizer.setState(after_attribute_value_state);
+ } else if (data === '&') {
+ this._additionalAllowedCharacter = "'";
+ tokenizer.setState(character_reference_in_attribute_value_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentAttribute().nodeValue += "\uFFFD";
+ } else {
+ tokenizer._currentAttribute().nodeValue += data + buffer.matchUntil("\u0000|['&]");
+ }
+ return true;
+ }
+
+ function attribute_value_unquoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-after-attribute-value");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(before_attribute_name_state);
+ } else if (data === '&') {
+ this._additionalAllowedCharacter = ">";
+ tokenizer.setState(character_reference_in_attribute_value_state);
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ } else if (data === '"' || data === "'" || data === '=' || data === '`' || data === '<') {
+ tokenizer._parseError("unexpected-character-in-unquoted-attribute-value");
+ tokenizer._currentAttribute().nodeValue += data;
+ buffer.commit();
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentAttribute().nodeValue += "\uFFFD";
+ } else {
+ var o = buffer.matchUntil("\u0000|["+ "\t\n\v\f\x20\r" + "&<>\"'=`" +"]");
+ if (o === InputStream.EOF) {
+ tokenizer._parseError("eof-in-attribute-value-no-quotes");
+ tokenizer._emitCurrentToken();
+ }
+ buffer.commit();
+ tokenizer._currentAttribute().nodeValue += data + o;
+ }
+ return true;
+ }
+
+ function character_reference_in_attribute_value_state(buffer) {
+ var character = EntityParser.consumeEntity(buffer, tokenizer, this._additionalAllowedCharacter);
+ this._currentAttribute().nodeValue += character || '&';
+ if (this._additionalAllowedCharacter === '"')
+ tokenizer.setState(attribute_value_double_quoted_state);
+ else if (this._additionalAllowedCharacter === '\'')
+ tokenizer.setState(attribute_value_single_quoted_state);
+ else if (this._additionalAllowedCharacter === '>')
+ tokenizer.setState(attribute_value_unquoted_state);
+ return true;
+ }
+
+ function after_attribute_value_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-after-attribute-value");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(before_attribute_name_state);
+ } else if (data === '>') {
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (data === '/') {
+ tokenizer.setState(self_closing_tag_state);
+ } else {
+ tokenizer._parseError("unexpected-character-after-attribute-value");
+ buffer.unget(data);
+ tokenizer.setState(before_attribute_name_state);
+ }
+ return true;
+ }
+
+ function self_closing_tag_state(buffer) {
+ var c = buffer.char();
+ if (c === InputStream.EOF) {
+ tokenizer._parseError("unexpected-eof-after-solidus-in-tag");
+ buffer.unget(c);
+ tokenizer.setState(data_state);
+ } else if (c === '>') {
+ tokenizer._currentToken.selfClosing = true;
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ tokenizer._parseError("unexpected-character-after-solidus-in-tag");
+ buffer.unget(c);
+ tokenizer.setState(before_attribute_name_state);
+ }
+ return true;
+ }
+
+ function bogus_comment_state(buffer) {
+ var data = buffer.matchUntil('>');
+ data = data.replace(/\u0000/g, "\uFFFD");
+ buffer.char();
+ tokenizer._emitToken({type: 'Comment', data: data});
+ tokenizer.setState(data_state);
+ return true;
+ }
+
+ function markup_declaration_open_state(buffer) {
+ var chars = buffer.shift(2);
+ if (chars === '--') {
+ tokenizer._currentToken = {type: 'Comment', data: ''};
+ tokenizer.setState(comment_start_state);
+ } else {
+ var newchars = buffer.shift(5);
+ if (newchars === InputStream.EOF || chars === InputStream.EOF) {
+ tokenizer._parseError("expected-dashes-or-doctype");
+ tokenizer.setState(bogus_comment_state);
+ buffer.unget(chars);
+ return true;
+ }
+
+ chars += newchars;
+ if (chars.toUpperCase() === 'DOCTYPE') {
+ tokenizer._currentToken = {type: 'Doctype', name: '', publicId: null, systemId: null, forceQuirks: false};
+ tokenizer.setState(doctype_state);
+ } else if (tokenizer._tokenHandler.isCdataSectionAllowed() && chars === '[CDATA[') {
+ tokenizer.setState(cdata_section_state);
+ } else {
+ tokenizer._parseError("expected-dashes-or-doctype");
+ buffer.unget(chars);
+ tokenizer.setState(bogus_comment_state);
+ }
+ }
+ return true;
+ }
+
+ function cdata_section_state(buffer) {
+ var data = buffer.matchUntil(']]>');
+ buffer.shift(3);
+ if (data) {
+ tokenizer._emitToken({type: 'Characters', data: data});
+ }
+ tokenizer.setState(data_state);
+ return true;
+ }
+
+ function comment_start_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-comment");
+ tokenizer._emitToken(tokenizer._currentToken);
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer.setState(comment_start_dash_state);
+ } else if (data === '>') {
+ tokenizer._parseError("incorrect-comment");
+ tokenizer._emitToken(tokenizer._currentToken);
+ tokenizer.setState(data_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data += "\uFFFD";
+ } else {
+ tokenizer._currentToken.data += data;
+ tokenizer.setState(comment_state);
+ }
+ return true;
+ }
+
+ function comment_start_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-comment");
+ tokenizer._emitToken(tokenizer._currentToken);
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer.setState(comment_end_state);
+ } else if (data === '>') {
+ tokenizer._parseError("incorrect-comment");
+ tokenizer._emitToken(tokenizer._currentToken);
+ tokenizer.setState(data_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data += "\uFFFD";
+ } else {
+ tokenizer._currentToken.data += '-' + data;
+ tokenizer.setState(comment_state);
+ }
+ return true;
+ }
+
+ function comment_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-comment");
+ tokenizer._emitToken(tokenizer._currentToken);
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer.setState(comment_end_dash_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data += "\uFFFD";
+ } else {
+ tokenizer._currentToken.data += data;
+ buffer.commit();
+ }
+ return true;
+ }
+
+ function comment_end_dash_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-comment-end-dash");
+ tokenizer._emitToken(tokenizer._currentToken);
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer.setState(comment_end_state);
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data += "-\uFFFD";
+ tokenizer.setState(comment_state);
+ } else {
+ tokenizer._currentToken.data += '-' + data + buffer.matchUntil('\u0000|-');
+ buffer.char();
+ }
+ return true;
+ }
+
+ function comment_end_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-comment-double-dash");
+ tokenizer._emitToken(tokenizer._currentToken);
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '>') {
+ tokenizer._emitToken(tokenizer._currentToken);
+ tokenizer.setState(data_state);
+ } else if (data === '!') {
+ tokenizer._parseError("unexpected-bang-after-double-dash-in-comment");
+ tokenizer.setState(comment_end_bang_state);
+ } else if (data === '-') {
+ tokenizer._parseError("unexpected-dash-after-double-dash-in-comment");
+ tokenizer._currentToken.data += data;
+ } else if (data === '\u0000') {
+ tokenizer._parseError("invalid-codepoint");
+ tokenizer._currentToken.data += "--\uFFFD";
+ tokenizer.setState(comment_state);
+ } else {
+ tokenizer._parseError("unexpected-char-in-comment");
+ tokenizer._currentToken.data += '--' + data;
+ tokenizer.setState(comment_state);
+ }
+ return true;
+ }
+
+ function comment_end_bang_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-comment-end-bang-state");
+ tokenizer._emitToken(tokenizer._currentToken);
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '>') {
+ tokenizer._emitToken(tokenizer._currentToken);
+ tokenizer.setState(data_state);
+ } else if (data === '-') {
+ tokenizer._currentToken.data += '--!';
+ tokenizer.setState(comment_end_dash_state);
+ } else {
+ tokenizer._currentToken.data += '--!' + data;
+ tokenizer.setState(comment_state);
+ }
+ return true;
+ }
+
+ function doctype_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("expected-doctype-name-but-got-eof");
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(before_doctype_name_state);
+ } else {
+ tokenizer._parseError("need-space-after-doctype");
+ buffer.unget(data);
+ tokenizer.setState(before_doctype_name_state);
+ }
+ return true;
+ }
+
+ function before_doctype_name_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("expected-doctype-name-but-got-eof");
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isWhitespace(data)) {
+ } else if (data === '>') {
+ tokenizer._parseError("expected-doctype-name-but-got-right-bracket");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ if (isAlpha(data))
+ data = data.toLowerCase();
+ tokenizer._currentToken.name = data;
+ tokenizer.setState(doctype_name_state);
+ }
+ return true;
+ }
+
+ function doctype_name_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer._parseError("eof-in-doctype-name");
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(after_doctype_name_state);
+ } else if (data === '>') {
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ if (isAlpha(data))
+ data = data.toLowerCase();
+ tokenizer._currentToken.name += data;
+ buffer.commit();
+ }
+ return true;
+ }
+
+ function after_doctype_name_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isWhitespace(data)) {
+ } else if (data === '>') {
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ if (['p', 'P'].indexOf(data) > -1) {
+ var expected = [['u', 'U'], ['b', 'B'], ['l', 'L'], ['i', 'I'], ['c', 'C']];
+ var matched = expected.every(function(expected){
+ data = buffer.char();
+ return expected.indexOf(data) > -1;
+ });
+ if (matched) {
+ tokenizer.setState(after_doctype_public_keyword_state);
+ return true;
+ }
+ } else if (['s', 'S'].indexOf(data) > -1) {
+ var expected = [['y', 'Y'], ['s', 'S'], ['t', 'T'], ['e', 'E'], ['m', 'M']];
+ var matched = expected.every(function(expected){
+ data = buffer.char();
+ return expected.indexOf(data) > -1;
+ });
+ if (matched) {
+ tokenizer.setState(after_doctype_system_keyword_state);
+ return true;
+ }
+ }
+ buffer.unget(data);
+ tokenizer._currentToken.forceQuirks = true;
+
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ tokenizer._parseError("expected-space-or-right-bracket-in-doctype", {data: data});
+ tokenizer.setState(bogus_doctype_state);
+ }
+ }
+ return true;
+ }
+
+ function after_doctype_public_keyword_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(before_doctype_public_identifier_state);
+ } else if (data === "'" || data === '"') {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ buffer.unget(data);
+ tokenizer.setState(before_doctype_public_identifier_state);
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(before_doctype_public_identifier_state);
+ }
+ return true;
+ }
+
+ function before_doctype_public_identifier_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (isWhitespace(data)) {
+ } else if (data === '"') {
+ tokenizer._currentToken.publicId = '';
+ tokenizer.setState(doctype_public_identifier_double_quoted_state);
+ } else if (data === "'") {
+ tokenizer._currentToken.publicId = '';
+ tokenizer.setState(doctype_public_identifier_single_quoted_state);
+ } else if (data === '>') {
+ tokenizer._parseError("unexpected-end-of-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(bogus_doctype_state);
+ }
+ return true;
+ }
+
+ function doctype_public_identifier_double_quoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (data === '"') {
+ tokenizer.setState(after_doctype_public_identifier_state);
+ } else if (data === '>') {
+ tokenizer._parseError("unexpected-end-of-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ tokenizer._currentToken.publicId += data;
+ }
+ return true;
+ }
+
+ function doctype_public_identifier_single_quoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (data === "'") {
+ tokenizer.setState(after_doctype_public_identifier_state);
+ } else if (data === '>') {
+ tokenizer._parseError("unexpected-end-of-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else {
+ tokenizer._currentToken.publicId += data;
+ }
+ return true;
+ }
+
+ function after_doctype_public_identifier_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(between_doctype_public_and_system_identifiers_state);
+ } else if (data === '>') {
+ tokenizer.setState(data_state);
+ tokenizer._emitCurrentToken();
+ } else if (data === '"') {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer._currentToken.systemId = '';
+ tokenizer.setState(doctype_system_identifier_double_quoted_state);
+ } else if (data === "'") {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer._currentToken.systemId = '';
+ tokenizer.setState(doctype_system_identifier_single_quoted_state);
+ } else {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(bogus_doctype_state);
+ }
+ return true;
+ }
+
+ function between_doctype_public_and_system_identifiers_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else if (data === '"') {
+ tokenizer._currentToken.systemId = '';
+ tokenizer.setState(doctype_system_identifier_double_quoted_state);
+ } else if (data === "'") {
+ tokenizer._currentToken.systemId = '';
+ tokenizer.setState(doctype_system_identifier_single_quoted_state);
+ } else {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(bogus_doctype_state);
+ }
+ return true;
+ }
+
+ function after_doctype_system_keyword_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ tokenizer.setState(before_doctype_system_identifier_state);
+ } else if (data === "'" || data === '"') {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ buffer.unget(data);
+ tokenizer.setState(before_doctype_system_identifier_state);
+ } else {
+ buffer.unget(data);
+ tokenizer.setState(before_doctype_system_identifier_state);
+ }
+ return true;
+ }
+
+ function before_doctype_system_identifier_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ } else if (data === '"') {
+ tokenizer._currentToken.systemId = '';
+ tokenizer.setState(doctype_system_identifier_double_quoted_state);
+ } else if (data === "'") {
+ tokenizer._currentToken.systemId = '';
+ tokenizer.setState(doctype_system_identifier_single_quoted_state);
+ } else if (data === '>') {
+ tokenizer._parseError("unexpected-end-of-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer.setState(bogus_doctype_state);
+ }
+ return true;
+ }
+
+ function doctype_system_identifier_double_quoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === '"') {
+ tokenizer.setState(after_doctype_system_identifier_state);
+ } else if (data === '>') {
+ tokenizer._parseError("unexpected-end-of-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else {
+ tokenizer._currentToken.systemId += data;
+ }
+ return true;
+ }
+
+ function doctype_system_identifier_single_quoted_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (data === "'") {
+ tokenizer.setState(after_doctype_system_identifier_state);
+ } else if (data === '>') {
+ tokenizer._parseError("unexpected-end-of-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else {
+ tokenizer._currentToken.systemId += data;
+ }
+ return true;
+ }
+
+ function after_doctype_system_identifier_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ tokenizer._parseError("eof-in-doctype");
+ tokenizer._currentToken.forceQuirks = true;
+ tokenizer._emitCurrentToken();
+ buffer.unget(data);
+ tokenizer.setState(data_state);
+ } else if (isWhitespace(data)) {
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else {
+ tokenizer._parseError("unexpected-char-in-doctype");
+ tokenizer.setState(bogus_doctype_state);
+ }
+ return true;
+ }
+
+ function bogus_doctype_state(buffer) {
+ var data = buffer.char();
+ if (data === InputStream.EOF) {
+ buffer.unget(data);
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ } else if (data === '>') {
+ tokenizer._emitCurrentToken();
+ tokenizer.setState(data_state);
+ }
+ return true;
+ }
+};
+
+Object.defineProperty(Tokenizer.prototype, 'lineNumber', {
+ get: function() {
+ return this._inputStream.location().line;
+ }
+});
+
+Object.defineProperty(Tokenizer.prototype, 'columnNumber', {
+ get: function() {
+ return this._inputStream.location().column;
+ }
+});
+
+exports.Tokenizer = Tokenizer;
+
+},
+{"./EntityParser":2,"./InputStream":3}],
+6:[function(_dereq_,module,exports){
+var assert = _dereq_('assert');
+
+var messages = _dereq_('./messages.json');
+var constants = _dereq_('./constants');
+
+var EventEmitter = _dereq_('events').EventEmitter;
+
+var Tokenizer = _dereq_('./Tokenizer').Tokenizer;
+var ElementStack = _dereq_('./ElementStack').ElementStack;
+var StackItem = _dereq_('./StackItem').StackItem;
+
+var Marker = {};
+
+function isWhitespace(ch) {
+ return ch === " " || ch === "\n" || ch === "\t" || ch === "\r" || ch === "\f";
+}
+
+function isWhitespaceOrReplacementCharacter(ch) {
+ return isWhitespace(ch) || ch === '\uFFFD';
+}
+
+function isAllWhitespace(characters) {
+ for (var i = 0; i < characters.length; i++) {
+ var ch = characters[i];
+ if (!isWhitespace(ch))
+ return false;
+ }
+ return true;
+}
+
+function isAllWhitespaceOrReplacementCharacters(characters) {
+ for (var i = 0; i < characters.length; i++) {
+ var ch = characters[i];
+ if (!isWhitespaceOrReplacementCharacter(ch))
+ return false;
+ }
+ return true;
+}
+
+function getAttribute(node, name) {
+ for (var i = 0; i < node.attributes.length; i++) {
+ var attribute = node.attributes[i];
+ if (attribute.nodeName === name) {
+ return attribute;
+ }
+ }
+ return null;
+}
+
+function CharacterBuffer(characters) {
+ this.characters = characters;
+ this.current = 0;
+ this.end = this.characters.length;
+}
+
+CharacterBuffer.prototype.skipAtMostOneLeadingNewline = function() {
+ if (this.characters[this.current] === '\n')
+ this.current++;
+};
+
+CharacterBuffer.prototype.skipLeadingWhitespace = function() {
+ while (isWhitespace(this.characters[this.current])) {
+ if (++this.current == this.end)
+ return;
+ }
+};
+
+CharacterBuffer.prototype.skipLeadingNonWhitespace = function() {
+ while (!isWhitespace(this.characters[this.current])) {
+ if (++this.current == this.end)
+ return;
+ }
+};
+
+CharacterBuffer.prototype.takeRemaining = function() {
+ return this.characters.substring(this.current);
+};
+
+CharacterBuffer.prototype.takeLeadingWhitespace = function() {
+ var start = this.current;
+ this.skipLeadingWhitespace();
+ if (start === this.current)
+ return "";
+ return this.characters.substring(start, this.current - start);
+};
+
+Object.defineProperty(CharacterBuffer.prototype, 'length', {
+ get: function(){
+ return this.end - this.current;
+ }
+});
+function TreeBuilder() {
+ this.tokenizer = null;
+ this.errorHandler = null;
+ this.scriptingEnabled = false;
+ this.document = null;
+ this.head = null;
+ this.form = null;
+ this.openElements = new ElementStack();
+ this.activeFormattingElements = [];
+ this.insertionMode = null;
+ this.insertionModeName = "";
+ this.originalInsertionMode = "";
+ this.inQuirksMode = false; // TODO quirks mode
+ this.compatMode = "no quirks";
+ this.framesetOk = true;
+ this.redirectAttachToFosterParent = false;
+ this.selfClosingFlagAcknowledged = false;
+ this.context = "";
+ this.pendingTableCharacters = [];
+ this.shouldSkipLeadingNewline = false;
+
+ var tree = this;
+ var modes = this.insertionModes = {};
+ modes.base = {
+ end_tag_handlers: {"-default": 'endTagOther'},
+ start_tag_handlers: {"-default": 'startTagOther'},
+ processEOF: function() {
+ tree.generateImpliedEndTags();
+ if (tree.openElements.length > 2) {
+ tree.parseError('expected-closing-tag-but-got-eof');
+ } else if (tree.openElements.length == 2 &&
+ tree.openElements.item(1).localName != 'body') {
+ tree.parseError('expected-closing-tag-but-got-eof');
+ } else if (tree.context && tree.openElements.length > 1) {
+ }
+ },
+ processComment: function(data) {
+ tree.insertComment(data, tree.currentStackItem().node);
+ },
+ processDoctype: function(name, publicId, systemId, forceQuirks) {
+ tree.parseError('unexpected-doctype');
+ },
+ processStartTag: function(name, attributes, selfClosing) {
+ if (this[this.start_tag_handlers[name]]) {
+ this[this.start_tag_handlers[name]](name, attributes, selfClosing);
+ } else if (this[this.start_tag_handlers["-default"]]) {
+ this[this.start_tag_handlers["-default"]](name, attributes, selfClosing);
+ } else {
+ throw(new Error("No handler found for "+name));
+ }
+ },
+ processEndTag: function(name) {
+ if (this[this.end_tag_handlers[name]]) {
+ this[this.end_tag_handlers[name]](name);
+ } else if (this[this.end_tag_handlers["-default"]]) {
+ this[this.end_tag_handlers["-default"]](name);
+ } else {
+ throw(new Error("No handler found for "+name));
+ }
+ },
+ startTagHtml: function(name, attributes) {
+ modes.inBody.startTagHtml(name, attributes);
+ }
+ };
+
+ modes.initial = Object.create(modes.base);
+
+ modes.initial.processEOF = function() {
+ tree.parseError("expected-doctype-but-got-eof");
+ this.anythingElse();
+ tree.insertionMode.processEOF();
+ };
+
+ modes.initial.processComment = function(data) {
+ tree.insertComment(data, tree.document);
+ };
+
+ modes.initial.processDoctype = function(name, publicId, systemId, forceQuirks) {
+ tree.insertDoctype(name || '', publicId || '', systemId || '');
+
+ if (forceQuirks || name != 'html' || (publicId != null && ([
+ "+//silmaril//dtd html pro v0r11 19970101//",
+ "-//advasoft ltd//dtd html 3.0 aswedit + extensions//",
+ "-//as//dtd html 3.0 aswedit + extensions//",
+ "-//ietf//dtd html 2.0 level 1//",
+ "-//ietf//dtd html 2.0 level 2//",
+ "-//ietf//dtd html 2.0 strict level 1//",
+ "-//ietf//dtd html 2.0 strict level 2//",
+ "-//ietf//dtd html 2.0 strict//",
+ "-//ietf//dtd html 2.0//",
+ "-//ietf//dtd html 2.1e//",
+ "-//ietf//dtd html 3.0//",
+ "-//ietf//dtd html 3.0//",
+ "-//ietf//dtd html 3.2 final//",
+ "-//ietf//dtd html 3.2//",
+ "-//ietf//dtd html 3//",
+ "-//ietf//dtd html level 0//",
+ "-//ietf//dtd html level 0//",
+ "-//ietf//dtd html level 1//",
+ "-//ietf//dtd html level 1//",
+ "-//ietf//dtd html level 2//",
+ "-//ietf//dtd html level 2//",
+ "-//ietf//dtd html level 3//",
+ "-//ietf//dtd html level 3//",
+ "-//ietf//dtd html strict level 0//",
+ "-//ietf//dtd html strict level 0//",
+ "-//ietf//dtd html strict level 1//",
+ "-//ietf//dtd html strict level 1//",
+ "-//ietf//dtd html strict level 2//",
+ "-//ietf//dtd html strict level 2//",
+ "-//ietf//dtd html strict level 3//",
+ "-//ietf//dtd html strict level 3//",
+ "-//ietf//dtd html strict//",
+ "-//ietf//dtd html strict//",
+ "-//ietf//dtd html strict//",
+ "-//ietf//dtd html//",
+ "-//ietf//dtd html//",
+ "-//ietf//dtd html//",
+ "-//metrius//dtd metrius presentational//",
+ "-//microsoft//dtd internet explorer 2.0 html strict//",
+ "-//microsoft//dtd internet explorer 2.0 html//",
+ "-//microsoft//dtd internet explorer 2.0 tables//",
+ "-//microsoft//dtd internet explorer 3.0 html strict//",
+ "-//microsoft//dtd internet explorer 3.0 html//",
+ "-//microsoft//dtd internet explorer 3.0 tables//",
+ "-//netscape comm. corp.//dtd html//",
+ "-//netscape comm. corp.//dtd strict html//",
+ "-//o'reilly and associates//dtd html 2.0//",
+ "-//o'reilly and associates//dtd html extended 1.0//",
+ "-//spyglass//dtd html 2.0 extended//",
+ "-//sq//dtd html 2.0 hotmetal + extensions//",
+ "-//sun microsystems corp.//dtd hotjava html//",
+ "-//sun microsystems corp.//dtd hotjava strict html//",
+ "-//w3c//dtd html 3 1995-03-24//",
+ "-//w3c//dtd html 3.2 draft//",
+ "-//w3c//dtd html 3.2 final//",
+ "-//w3c//dtd html 3.2//",
+ "-//w3c//dtd html 3.2s draft//",
+ "-//w3c//dtd html 4.0 frameset//",
+ "-//w3c//dtd html 4.0 transitional//",
+ "-//w3c//dtd html experimental 19960712//",
+ "-//w3c//dtd html experimental 970421//",
+ "-//w3c//dtd w3 html//",
+ "-//w3o//dtd w3 html 3.0//",
+ "-//webtechs//dtd mozilla html 2.0//",
+ "-//webtechs//dtd mozilla html//",
+ "html"
+ ].some(publicIdStartsWith)
+ || [
+ "-//w3o//dtd w3 html strict 3.0//en//",
+ "-/w3c/dtd html 4.0 transitional/en",
+ "html"
+ ].indexOf(publicId.toLowerCase()) > -1
+ || (systemId == null && [
+ "-//w3c//dtd html 4.01 transitional//",
+ "-//w3c//dtd html 4.01 frameset//"
+ ].some(publicIdStartsWith)))
+ )
+ || (systemId != null && (systemId.toLowerCase() == "http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd"))
+ ) {
+ tree.compatMode = "quirks";
+ tree.parseError("quirky-doctype");
+ } else if (publicId != null && ([
+ "-//w3c//dtd xhtml 1.0 transitional//",
+ "-//w3c//dtd xhtml 1.0 frameset//"
+ ].some(publicIdStartsWith)
+ || (systemId != null && [
+ "-//w3c//dtd html 4.01 transitional//",
+ "-//w3c//dtd html 4.01 frameset//"
+ ].indexOf(publicId.toLowerCase()) > -1))
+ ) {
+ tree.compatMode = "limited quirks";
+ tree.parseError("almost-standards-doctype");
+ } else {
+ if ((publicId == "-//W3C//DTD HTML 4.0//EN" && (systemId == null || systemId == "http://www.w3.org/TR/REC-html40/strict.dtd"))
+ || (publicId == "-//W3C//DTD HTML 4.01//EN" && (systemId == null || systemId == "http://www.w3.org/TR/html4/strict.dtd"))
+ || (publicId == "-//W3C//DTD XHTML 1.0 Strict//EN" && (systemId == "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"))
+ || (publicId == "-//W3C//DTD XHTML 1.1//EN" && (systemId == "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"))
+ ) {
+ } else if (!((systemId == null || systemId == "about:legacy-compat") && publicId == null)) {
+ tree.parseError("unknown-doctype");
+ }
+ }
+ tree.setInsertionMode('beforeHTML');
+ function publicIdStartsWith(string) {
+ return publicId.toLowerCase().indexOf(string) === 0;
+ }
+ };
+
+ modes.initial.processCharacters = function(buffer) {
+ buffer.skipLeadingWhitespace();
+ if (!buffer.length)
+ return;
+ tree.parseError('expected-doctype-but-got-chars');
+ this.anythingElse();
+ tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.initial.processStartTag = function(name, attributes, selfClosing) {
+ tree.parseError('expected-doctype-but-got-start-tag', {name: name});
+ this.anythingElse();
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.initial.processEndTag = function(name) {
+ tree.parseError('expected-doctype-but-got-end-tag', {name: name});
+ this.anythingElse();
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.initial.anythingElse = function() {
+ tree.compatMode = 'quirks';
+ tree.setInsertionMode('beforeHTML');
+ };
+
+ modes.beforeHTML = Object.create(modes.base);
+
+ modes.beforeHTML.start_tag_handlers = {
+ html: 'startTagHtml',
+ '-default': 'startTagOther'
+ };
+
+ modes.beforeHTML.processEOF = function() {
+ this.anythingElse();
+ tree.insertionMode.processEOF();
+ };
+
+ modes.beforeHTML.processComment = function(data) {
+ tree.insertComment(data, tree.document);
+ };
+
+ modes.beforeHTML.processCharacters = function(buffer) {
+ buffer.skipLeadingWhitespace();
+ if (!buffer.length)
+ return;
+ this.anythingElse();
+ tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.beforeHTML.startTagHtml = function(name, attributes, selfClosing) {
+ tree.insertHtmlElement(attributes);
+ tree.setInsertionMode('beforeHead');
+ };
+
+ modes.beforeHTML.startTagOther = function(name, attributes, selfClosing) {
+ this.anythingElse();
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.beforeHTML.processEndTag = function(name) {
+ this.anythingElse();
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.beforeHTML.anythingElse = function() {
+ tree.insertHtmlElement();
+ tree.setInsertionMode('beforeHead');
+ };
+
+ modes.afterAfterBody = Object.create(modes.base);
+
+ modes.afterAfterBody.start_tag_handlers = {
+ html: 'startTagHtml',
+ '-default': 'startTagOther'
+ };
+
+ modes.afterAfterBody.processComment = function(data) {
+ tree.insertComment(data, tree.document);
+ };
+
+ modes.afterAfterBody.processDoctype = function(data) {
+ modes.inBody.processDoctype(data);
+ };
+
+ modes.afterAfterBody.startTagHtml = function(data, attributes) {
+ modes.inBody.startTagHtml(data, attributes);
+ };
+
+ modes.afterAfterBody.startTagOther = function(name, attributes, selfClosing) {
+ tree.parseError('unexpected-start-tag', {name: name});
+ tree.setInsertionMode('inBody');
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.afterAfterBody.endTagOther = function(name) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ tree.setInsertionMode('inBody');
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.afterAfterBody.processCharacters = function(data) {
+ if (!isAllWhitespace(data.characters)) {
+ tree.parseError('unexpected-char-after-body');
+ tree.setInsertionMode('inBody');
+ return tree.insertionMode.processCharacters(data);
+ }
+ modes.inBody.processCharacters(data);
+ };
+
+ modes.afterBody = Object.create(modes.base);
+
+ modes.afterBody.end_tag_handlers = {
+ html: 'endTagHtml',
+ '-default': 'endTagOther'
+ };
+
+ modes.afterBody.processComment = function(data) {
+ tree.insertComment(data, tree.openElements.rootNode);
+ };
+
+ modes.afterBody.processCharacters = function(data) {
+ if (!isAllWhitespace(data.characters)) {
+ tree.parseError('unexpected-char-after-body');
+ tree.setInsertionMode('inBody');
+ return tree.insertionMode.processCharacters(data);
+ }
+ modes.inBody.processCharacters(data);
+ };
+
+ modes.afterBody.processStartTag = function(name, attributes, selfClosing) {
+ tree.parseError('unexpected-start-tag-after-body', {name: name});
+ tree.setInsertionMode('inBody');
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.afterBody.endTagHtml = function(name) {
+ if (tree.context) {
+ tree.parseError('end-html-in-innerhtml');
+ } else {
+ tree.setInsertionMode('afterAfterBody');
+ }
+ };
+
+ modes.afterBody.endTagOther = function(name) {
+ tree.parseError('unexpected-end-tag-after-body', {name: name});
+ tree.setInsertionMode('inBody');
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.afterFrameset = Object.create(modes.base);
+
+ modes.afterFrameset.start_tag_handlers = {
+ html: 'startTagHtml',
+ noframes: 'startTagNoframes',
+ '-default': 'startTagOther'
+ };
+
+ modes.afterFrameset.end_tag_handlers = {
+ html: 'endTagHtml',
+ '-default': 'endTagOther'
+ };
+
+ modes.afterFrameset.processCharacters = function(buffer) {
+ var characters = buffer.takeRemaining();
+ var whitespace = "";
+ for (var i = 0; i < characters.length; i++) {
+ var ch = characters[i];
+ if (isWhitespace(ch))
+ whitespace += ch;
+ }
+ if (whitespace) {
+ tree.insertText(whitespace);
+ }
+ if (whitespace.length < characters.length)
+ tree.parseError('expected-eof-but-got-char');
+ };
+
+ modes.afterFrameset.startTagNoframes = function(name, attributes) {
+ modes.inHead.processStartTag(name, attributes);
+ };
+
+ modes.afterFrameset.startTagOther = function(name, attributes) {
+ tree.parseError("unexpected-start-tag-after-frameset", {name: name});
+ };
+
+ modes.afterFrameset.endTagHtml = function(name) {
+ tree.setInsertionMode('afterAfterFrameset');
+ };
+
+ modes.afterFrameset.endTagOther = function(name) {
+ tree.parseError("unexpected-end-tag-after-frameset", {name: name});
+ };
+
+ modes.beforeHead = Object.create(modes.base);
+
+ modes.beforeHead.start_tag_handlers = {
+ html: 'startTagHtml',
+ head: 'startTagHead',
+ '-default': 'startTagOther'
+ };
+
+ modes.beforeHead.end_tag_handlers = {
+ html: 'endTagImplyHead',
+ head: 'endTagImplyHead',
+ body: 'endTagImplyHead',
+ br: 'endTagImplyHead',
+ '-default': 'endTagOther'
+ };
+
+ modes.beforeHead.processEOF = function() {
+ this.startTagHead('head', []);
+ tree.insertionMode.processEOF();
+ };
+
+ modes.beforeHead.processCharacters = function(buffer) {
+ buffer.skipLeadingWhitespace();
+ if (!buffer.length)
+ return;
+ this.startTagHead('head', []);
+ tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.beforeHead.startTagHead = function(name, attributes) {
+ tree.insertHeadElement(attributes);
+ tree.setInsertionMode('inHead');
+ };
+
+ modes.beforeHead.startTagOther = function(name, attributes, selfClosing) {
+ this.startTagHead('head', []);
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.beforeHead.endTagImplyHead = function(name) {
+ this.startTagHead('head', []);
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.beforeHead.endTagOther = function(name) {
+ tree.parseError('end-tag-after-implied-root', {name: name});
+ };
+
+ modes.inHead = Object.create(modes.base);
+
+ modes.inHead.start_tag_handlers = {
+ html: 'startTagHtml',
+ head: 'startTagHead',
+ title: 'startTagTitle',
+ script: 'startTagScript',
+ style: 'startTagNoFramesStyle',
+ noscript: 'startTagNoScript',
+ noframes: 'startTagNoFramesStyle',
+ base: 'startTagBaseBasefontBgsoundLink',
+ basefont: 'startTagBaseBasefontBgsoundLink',
+ bgsound: 'startTagBaseBasefontBgsoundLink',
+ link: 'startTagBaseBasefontBgsoundLink',
+ meta: 'startTagMeta',
+ "-default": 'startTagOther'
+ };
+
+ modes.inHead.end_tag_handlers = {
+ head: 'endTagHead',
+ html: 'endTagHtmlBodyBr',
+ body: 'endTagHtmlBodyBr',
+ br: 'endTagHtmlBodyBr',
+ "-default": 'endTagOther'
+ };
+
+ modes.inHead.processEOF = function() {
+ var name = tree.currentStackItem().localName;
+ if (['title', 'style', 'script'].indexOf(name) != -1) {
+ tree.parseError("expected-named-closing-tag-but-got-eof", {name: name});
+ tree.popElement();
+ }
+
+ this.anythingElse();
+
+ tree.insertionMode.processEOF();
+ };
+
+ modes.inHead.processCharacters = function(buffer) {
+ var leadingWhitespace = buffer.takeLeadingWhitespace();
+ if (leadingWhitespace)
+ tree.insertText(leadingWhitespace);
+ if (!buffer.length)
+ return;
+ this.anythingElse();
+ tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.inHead.startTagHtml = function(name, attributes) {
+ modes.inBody.processStartTag(name, attributes);
+ };
+
+ modes.inHead.startTagHead = function(name, attributes) {
+ tree.parseError('two-heads-are-not-better-than-one');
+ };
+
+ modes.inHead.startTagTitle = function(name, attributes) {
+ tree.processGenericRCDATAStartTag(name, attributes);
+ };
+
+ modes.inHead.startTagNoScript = function(name, attributes) {
+ if (tree.scriptingEnabled)
+ return tree.processGenericRawTextStartTag(name, attributes);
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inHeadNoscript');
+ };
+
+ modes.inHead.startTagNoFramesStyle = function(name, attributes) {
+ tree.processGenericRawTextStartTag(name, attributes);
+ };
+
+ modes.inHead.startTagScript = function(name, attributes) {
+ tree.insertElement(name, attributes);
+ tree.tokenizer.setState(Tokenizer.SCRIPT_DATA);
+ tree.originalInsertionMode = tree.insertionModeName;
+ tree.setInsertionMode('text');
+ };
+
+ modes.inHead.startTagBaseBasefontBgsoundLink = function(name, attributes) {
+ tree.insertSelfClosingElement(name, attributes);
+ };
+
+ modes.inHead.startTagMeta = function(name, attributes) {
+ tree.insertSelfClosingElement(name, attributes);
+ };
+
+ modes.inHead.startTagOther = function(name, attributes, selfClosing) {
+ this.anythingElse();
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inHead.endTagHead = function(name) {
+ if (tree.openElements.item(tree.openElements.length - 1).localName == 'head') {
+ tree.openElements.pop();
+ } else {
+ tree.parseError('unexpected-end-tag', {name: 'head'});
+ }
+ tree.setInsertionMode('afterHead');
+ };
+
+ modes.inHead.endTagHtmlBodyBr = function(name) {
+ this.anythingElse();
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.inHead.endTagOther = function(name) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ };
+
+ modes.inHead.anythingElse = function() {
+ this.endTagHead('head');
+ };
+
+ modes.afterHead = Object.create(modes.base);
+
+ modes.afterHead.start_tag_handlers = {
+ html: 'startTagHtml',
+ head: 'startTagHead',
+ body: 'startTagBody',
+ frameset: 'startTagFrameset',
+ base: 'startTagFromHead',
+ link: 'startTagFromHead',
+ meta: 'startTagFromHead',
+ script: 'startTagFromHead',
+ style: 'startTagFromHead',
+ title: 'startTagFromHead',
+ "-default": 'startTagOther'
+ };
+
+ modes.afterHead.end_tag_handlers = {
+ body: 'endTagBodyHtmlBr',
+ html: 'endTagBodyHtmlBr',
+ br: 'endTagBodyHtmlBr',
+ "-default": 'endTagOther'
+ };
+
+ modes.afterHead.processEOF = function() {
+ this.anythingElse();
+ tree.insertionMode.processEOF();
+ };
+
+ modes.afterHead.processCharacters = function(buffer) {
+ var leadingWhitespace = buffer.takeLeadingWhitespace();
+ if (leadingWhitespace)
+ tree.insertText(leadingWhitespace);
+ if (!buffer.length)
+ return;
+ this.anythingElse();
+ tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.afterHead.startTagHtml = function(name, attributes) {
+ modes.inBody.processStartTag(name, attributes);
+ };
+
+ modes.afterHead.startTagBody = function(name, attributes) {
+ tree.framesetOk = false;
+ tree.insertBodyElement(attributes);
+ tree.setInsertionMode('inBody');
+ };
+
+ modes.afterHead.startTagFrameset = function(name, attributes) {
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inFrameset');
+ };
+
+ modes.afterHead.startTagFromHead = function(name, attributes, selfClosing) {
+ tree.parseError("unexpected-start-tag-out-of-my-head", {name: name});
+ tree.openElements.push(tree.head);
+ modes.inHead.processStartTag(name, attributes, selfClosing);
+ tree.openElements.remove(tree.head);
+ };
+
+ modes.afterHead.startTagHead = function(name, attributes, selfClosing) {
+ tree.parseError('unexpected-start-tag', {name: name});
+ };
+
+ modes.afterHead.startTagOther = function(name, attributes, selfClosing) {
+ this.anythingElse();
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.afterHead.endTagBodyHtmlBr = function(name) {
+ this.anythingElse();
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.afterHead.endTagOther = function(name) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ };
+
+ modes.afterHead.anythingElse = function() {
+ tree.insertBodyElement([]);
+ tree.setInsertionMode('inBody');
+ tree.framesetOk = true;
+ }
+
+ modes.inBody = Object.create(modes.base);
+
+ modes.inBody.start_tag_handlers = {
+ html: 'startTagHtml',
+ head: 'startTagMisplaced',
+ base: 'startTagProcessInHead',
+ basefont: 'startTagProcessInHead',
+ bgsound: 'startTagProcessInHead',
+ link: 'startTagProcessInHead',
+ meta: 'startTagProcessInHead',
+ noframes: 'startTagProcessInHead',
+ script: 'startTagProcessInHead',
+ style: 'startTagProcessInHead',
+ title: 'startTagProcessInHead',
+ body: 'startTagBody',
+ form: 'startTagForm',
+ plaintext: 'startTagPlaintext',
+ a: 'startTagA',
+ button: 'startTagButton',
+ xmp: 'startTagXmp',
+ table: 'startTagTable',
+ hr: 'startTagHr',
+ image: 'startTagImage',
+ input: 'startTagInput',
+ textarea: 'startTagTextarea',
+ select: 'startTagSelect',
+ isindex: 'startTagIsindex',
+ applet: 'startTagAppletMarqueeObject',
+ marquee: 'startTagAppletMarqueeObject',
+ object: 'startTagAppletMarqueeObject',
+ li: 'startTagListItem',
+ dd: 'startTagListItem',
+ dt: 'startTagListItem',
+ address: 'startTagCloseP',
+ article: 'startTagCloseP',
+ aside: 'startTagCloseP',
+ blockquote: 'startTagCloseP',
+ center: 'startTagCloseP',
+ details: 'startTagCloseP',
+ dir: 'startTagCloseP',
+ div: 'startTagCloseP',
+ dl: 'startTagCloseP',
+ fieldset: 'startTagCloseP',
+ figcaption: 'startTagCloseP',
+ figure: 'startTagCloseP',
+ footer: 'startTagCloseP',
+ header: 'startTagCloseP',
+ hgroup: 'startTagCloseP',
+ main: 'startTagCloseP',
+ menu: 'startTagCloseP',
+ nav: 'startTagCloseP',
+ ol: 'startTagCloseP',
+ p: 'startTagCloseP',
+ section: 'startTagCloseP',
+ summary: 'startTagCloseP',
+ ul: 'startTagCloseP',
+ listing: 'startTagPreListing',
+ pre: 'startTagPreListing',
+ b: 'startTagFormatting',
+ big: 'startTagFormatting',
+ code: 'startTagFormatting',
+ em: 'startTagFormatting',
+ font: 'startTagFormatting',
+ i: 'startTagFormatting',
+ s: 'startTagFormatting',
+ small: 'startTagFormatting',
+ strike: 'startTagFormatting',
+ strong: 'startTagFormatting',
+ tt: 'startTagFormatting',
+ u: 'startTagFormatting',
+ nobr: 'startTagNobr',
+ area: 'startTagVoidFormatting',
+ br: 'startTagVoidFormatting',
+ embed: 'startTagVoidFormatting',
+ img: 'startTagVoidFormatting',
+ keygen: 'startTagVoidFormatting',
+ wbr: 'startTagVoidFormatting',
+ param: 'startTagParamSourceTrack',
+ source: 'startTagParamSourceTrack',
+ track: 'startTagParamSourceTrack',
+ iframe: 'startTagIFrame',
+ noembed: 'startTagRawText',
+ noscript: 'startTagRawText',
+ h1: 'startTagHeading',
+ h2: 'startTagHeading',
+ h3: 'startTagHeading',
+ h4: 'startTagHeading',
+ h5: 'startTagHeading',
+ h6: 'startTagHeading',
+ caption: 'startTagMisplaced',
+ col: 'startTagMisplaced',
+ colgroup: 'startTagMisplaced',
+ frame: 'startTagMisplaced',
+ frameset: 'startTagFrameset',
+ tbody: 'startTagMisplaced',
+ td: 'startTagMisplaced',
+ tfoot: 'startTagMisplaced',
+ th: 'startTagMisplaced',
+ thead: 'startTagMisplaced',
+ tr: 'startTagMisplaced',
+ option: 'startTagOptionOptgroup',
+ optgroup: 'startTagOptionOptgroup',
+ math: 'startTagMath',
+ svg: 'startTagSVG',
+ rt: 'startTagRpRt',
+ rp: 'startTagRpRt',
+ "-default": 'startTagOther'
+ };
+
+ modes.inBody.end_tag_handlers = {
+ p: 'endTagP',
+ body: 'endTagBody',
+ html: 'endTagHtml',
+ address: 'endTagBlock',
+ article: 'endTagBlock',
+ aside: 'endTagBlock',
+ blockquote: 'endTagBlock',
+ button: 'endTagBlock',
+ center: 'endTagBlock',
+ details: 'endTagBlock',
+ dir: 'endTagBlock',
+ div: 'endTagBlock',
+ dl: 'endTagBlock',
+ fieldset: 'endTagBlock',
+ figcaption: 'endTagBlock',
+ figure: 'endTagBlock',
+ footer: 'endTagBlock',
+ header: 'endTagBlock',
+ hgroup: 'endTagBlock',
+ listing: 'endTagBlock',
+ main: 'endTagBlock',
+ menu: 'endTagBlock',
+ nav: 'endTagBlock',
+ ol: 'endTagBlock',
+ pre: 'endTagBlock',
+ section: 'endTagBlock',
+ summary: 'endTagBlock',
+ ul: 'endTagBlock',
+ form: 'endTagForm',
+ applet: 'endTagAppletMarqueeObject',
+ marquee: 'endTagAppletMarqueeObject',
+ object: 'endTagAppletMarqueeObject',
+ dd: 'endTagListItem',
+ dt: 'endTagListItem',
+ li: 'endTagListItem',
+ h1: 'endTagHeading',
+ h2: 'endTagHeading',
+ h3: 'endTagHeading',
+ h4: 'endTagHeading',
+ h5: 'endTagHeading',
+ h6: 'endTagHeading',
+ a: 'endTagFormatting',
+ b: 'endTagFormatting',
+ big: 'endTagFormatting',
+ code: 'endTagFormatting',
+ em: 'endTagFormatting',
+ font: 'endTagFormatting',
+ i: 'endTagFormatting',
+ nobr: 'endTagFormatting',
+ s: 'endTagFormatting',
+ small: 'endTagFormatting',
+ strike: 'endTagFormatting',
+ strong: 'endTagFormatting',
+ tt: 'endTagFormatting',
+ u: 'endTagFormatting',
+ br: 'endTagBr',
+ "-default": 'endTagOther'
+ };
+
+ modes.inBody.processCharacters = function(buffer) {
+ if (tree.shouldSkipLeadingNewline) {
+ tree.shouldSkipLeadingNewline = false;
+ buffer.skipAtMostOneLeadingNewline();
+ }
+ tree.reconstructActiveFormattingElements();
+ var characters = buffer.takeRemaining();
+ characters = characters.replace(/\u0000/g, function(match, index){
+ tree.parseError("invalid-codepoint");
+ return '';
+ });
+ if (!characters)
+ return;
+ tree.insertText(characters);
+ if (tree.framesetOk && !isAllWhitespaceOrReplacementCharacters(characters))
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.startTagHtml = function(name, attributes) {
+ tree.parseError('non-html-root');
+ tree.addAttributesToElement(tree.openElements.rootNode, attributes);
+ };
+
+ modes.inBody.startTagProcessInHead = function(name, attributes) {
+ modes.inHead.processStartTag(name, attributes);
+ };
+
+ modes.inBody.startTagBody = function(name, attributes) {
+ tree.parseError('unexpected-start-tag', {name: 'body'});
+ if (tree.openElements.length == 1 ||
+ tree.openElements.item(1).localName != 'body') {
+ assert.ok(tree.context);
+ } else {
+ tree.framesetOk = false;
+ tree.addAttributesToElement(tree.openElements.bodyElement, attributes);
+ }
+ };
+
+ modes.inBody.startTagFrameset = function(name, attributes) {
+ tree.parseError('unexpected-start-tag', {name: 'frameset'});
+ if (tree.openElements.length == 1 ||
+ tree.openElements.item(1).localName != 'body') {
+ assert.ok(tree.context);
+ } else if (tree.framesetOk) {
+ tree.detachFromParent(tree.openElements.bodyElement);
+ while (tree.openElements.length > 1)
+ tree.openElements.pop();
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inFrameset');
+ }
+ };
+
+ modes.inBody.startTagCloseP = function(name, attributes) {
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inBody.startTagPreListing = function(name, attributes) {
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ tree.insertElement(name, attributes);
+ tree.framesetOk = false;
+ tree.shouldSkipLeadingNewline = true;
+ };
+
+ modes.inBody.startTagForm = function(name, attributes) {
+ if (tree.form) {
+ tree.parseError('unexpected-start-tag', {name: name});
+ } else {
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ tree.insertElement(name, attributes);
+ tree.form = tree.currentStackItem();
+ }
+ };
+
+ modes.inBody.startTagRpRt = function(name, attributes) {
+ if (tree.openElements.inScope('ruby')) {
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem().localName != 'ruby') {
+ tree.parseError('unexpected-start-tag', {name: name});
+ }
+ }
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inBody.startTagListItem = function(name, attributes) {
+ var stopNames = {li: ['li'], dd: ['dd', 'dt'], dt: ['dd', 'dt']};
+ var stopName = stopNames[name];
+
+ var els = tree.openElements;
+ for (var i = els.length - 1; i >= 0; i--) {
+ var node = els.item(i);
+ if (stopName.indexOf(node.localName) != -1) {
+ tree.insertionMode.processEndTag(node.localName);
+ break;
+ }
+ if (node.isSpecial() && node.localName !== 'p' && node.localName !== 'address' && node.localName !== 'div')
+ break;
+ }
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ tree.insertElement(name, attributes);
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.startTagPlaintext = function(name, attributes) {
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ tree.insertElement(name, attributes);
+ tree.tokenizer.setState(Tokenizer.PLAINTEXT);
+ };
+
+ modes.inBody.startTagHeading = function(name, attributes) {
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ if (tree.currentStackItem().isNumberedHeader()) {
+ tree.parseError('unexpected-start-tag', {name: name});
+ tree.popElement();
+ }
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inBody.startTagA = function(name, attributes) {
+ var activeA = tree.elementInActiveFormattingElements('a');
+ if (activeA) {
+ tree.parseError("unexpected-start-tag-implies-end-tag", {startName: "a", endName: "a"});
+ tree.adoptionAgencyEndTag('a');
+ if (tree.openElements.contains(activeA))
+ tree.openElements.remove(activeA);
+ tree.removeElementFromActiveFormattingElements(activeA);
+ }
+ tree.reconstructActiveFormattingElements();
+ tree.insertFormattingElement(name, attributes);
+ };
+
+ modes.inBody.startTagFormatting = function(name, attributes) {
+ tree.reconstructActiveFormattingElements();
+ tree.insertFormattingElement(name, attributes);
+ };
+
+ modes.inBody.startTagNobr = function(name, attributes) {
+ tree.reconstructActiveFormattingElements();
+ if (tree.openElements.inScope('nobr')) {
+ tree.parseError("unexpected-start-tag-implies-end-tag", {startName: 'nobr', endName: 'nobr'});
+ this.processEndTag('nobr');
+ tree.reconstructActiveFormattingElements();
+ }
+ tree.insertFormattingElement(name, attributes);
+ };
+
+ modes.inBody.startTagButton = function(name, attributes) {
+ if (tree.openElements.inScope('button')) {
+ tree.parseError('unexpected-start-tag-implies-end-tag', {startName: 'button', endName: 'button'});
+ this.processEndTag('button');
+ tree.insertionMode.processStartTag(name, attributes);
+ } else {
+ tree.framesetOk = false;
+ tree.reconstructActiveFormattingElements();
+ tree.insertElement(name, attributes);
+ }
+ };
+
+ modes.inBody.startTagAppletMarqueeObject = function(name, attributes) {
+ tree.reconstructActiveFormattingElements();
+ tree.insertElement(name, attributes);
+ tree.activeFormattingElements.push(Marker);
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.endTagAppletMarqueeObject = function(name) {
+ if (!tree.openElements.inScope(name)) {
+ tree.parseError("unexpected-end-tag", {name: name});
+ } else {
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem().localName != name) {
+ tree.parseError('end-tag-too-early', {name: name});
+ }
+ tree.openElements.popUntilPopped(name);
+ tree.clearActiveFormattingElements();
+ }
+ };
+
+ modes.inBody.startTagXmp = function(name, attributes) {
+ if (tree.openElements.inButtonScope('p'))
+ this.processEndTag('p');
+ tree.reconstructActiveFormattingElements();
+ tree.processGenericRawTextStartTag(name, attributes);
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.startTagTable = function(name, attributes) {
+ if (tree.compatMode !== "quirks")
+ if (tree.openElements.inButtonScope('p'))
+ this.processEndTag('p');
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inTable');
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.startTagVoidFormatting = function(name, attributes) {
+ tree.reconstructActiveFormattingElements();
+ tree.insertSelfClosingElement(name, attributes);
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.startTagParamSourceTrack = function(name, attributes) {
+ tree.insertSelfClosingElement(name, attributes);
+ };
+
+ modes.inBody.startTagHr = function(name, attributes) {
+ if (tree.openElements.inButtonScope('p'))
+ this.endTagP('p');
+ tree.insertSelfClosingElement(name, attributes);
+ tree.framesetOk = false;
+ };
+
+ modes.inBody.startTagImage = function(name, attributes) {
+ tree.parseError('unexpected-start-tag-treated-as', {originalName: 'image', newName: 'img'});
+ this.processStartTag('img', attributes);
+ };
+
+ modes.inBody.startTagInput = function(name, attributes) {
+ var currentFramesetOk = tree.framesetOk;
+ this.startTagVoidFormatting(name, attributes);
+ for (var key in attributes) {
+ if (attributes[key].nodeName == 'type') {
+ if (attributes[key].nodeValue.toLowerCase() == 'hidden')
+ tree.framesetOk = currentFramesetOk;
+ break;
+ }
+ }
+ };
+
+ modes.inBody.startTagIsindex = function(name, attributes) {
+ tree.parseError('deprecated-tag', {name: 'isindex'});
+ tree.selfClosingFlagAcknowledged = true;
+ if (tree.form)
+ return;
+ var formAttributes = [];
+ var inputAttributes = [];
+ var prompt = "This is a searchable index. Enter search keywords: ";
+ for (var key in attributes) {
+ switch (attributes[key].nodeName) {
+ case 'action':
+ formAttributes.push({nodeName: 'action',
+ nodeValue: attributes[key].nodeValue});
+ break;
+ case 'prompt':
+ prompt = attributes[key].nodeValue;
+ break;
+ case 'name':
+ break;
+ default:
+ inputAttributes.push({nodeName: attributes[key].nodeName,
+ nodeValue: attributes[key].nodeValue});
+ }
+ }
+ inputAttributes.push({nodeName: 'name', nodeValue: 'isindex'});
+ this.processStartTag('form', formAttributes);
+ this.processStartTag('hr');
+ this.processStartTag('label');
+ this.processCharacters(new CharacterBuffer(prompt));
+ this.processStartTag('input', inputAttributes);
+ this.processEndTag('label');
+ this.processStartTag('hr');
+ this.processEndTag('form');
+ };
+
+ modes.inBody.startTagTextarea = function(name, attributes) {
+ tree.insertElement(name, attributes);
+ tree.tokenizer.setState(Tokenizer.RCDATA);
+ tree.originalInsertionMode = tree.insertionModeName;
+ tree.shouldSkipLeadingNewline = true;
+ tree.framesetOk = false;
+ tree.setInsertionMode('text');
+ };
+
+ modes.inBody.startTagIFrame = function(name, attributes) {
+ tree.framesetOk = false;
+ this.startTagRawText(name, attributes);
+ };
+
+ modes.inBody.startTagRawText = function(name, attributes) {
+ tree.processGenericRawTextStartTag(name, attributes);
+ };
+
+ modes.inBody.startTagSelect = function(name, attributes) {
+ tree.reconstructActiveFormattingElements();
+ tree.insertElement(name, attributes);
+ tree.framesetOk = false;
+ var insertionModeName = tree.insertionModeName;
+ if (insertionModeName == 'inTable' ||
+ insertionModeName == 'inCaption' ||
+ insertionModeName == 'inColumnGroup' ||
+ insertionModeName == 'inTableBody' ||
+ insertionModeName == 'inRow' ||
+ insertionModeName == 'inCell') {
+ tree.setInsertionMode('inSelectInTable');
+ } else {
+ tree.setInsertionMode('inSelect');
+ }
+ };
+
+ modes.inBody.startTagMisplaced = function(name, attributes) {
+ tree.parseError('unexpected-start-tag-ignored', {name: name});
+ };
+
+ modes.inBody.endTagMisplaced = function(name) {
+ tree.parseError("unexpected-end-tag", {name: name});
+ };
+
+ modes.inBody.endTagBr = function(name) {
+ tree.parseError("unexpected-end-tag-treated-as", {originalName: "br", newName: "br element"});
+ tree.reconstructActiveFormattingElements();
+ tree.insertElement(name, []);
+ tree.popElement();
+ };
+
+ modes.inBody.startTagOptionOptgroup = function(name, attributes) {
+ if (tree.currentStackItem().localName == 'option')
+ tree.popElement();
+ tree.reconstructActiveFormattingElements();
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inBody.startTagOther = function(name, attributes) {
+ tree.reconstructActiveFormattingElements();
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inBody.endTagOther = function(name) {
+ var node;
+ for (var i = tree.openElements.length - 1; i > 0; i--) {
+ node = tree.openElements.item(i);
+ if (node.localName == name) {
+ tree.generateImpliedEndTags(name);
+ if (tree.currentStackItem().localName != name)
+ tree.parseError('unexpected-end-tag', {name: name});
+ tree.openElements.remove_openElements_until(function(x) {return x === node;});
+ break;
+ }
+ if (node.isSpecial()) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ break;
+ }
+ }
+ };
+
+ modes.inBody.startTagMath = function(name, attributes, selfClosing) {
+ tree.reconstructActiveFormattingElements();
+ attributes = tree.adjustMathMLAttributes(attributes);
+ attributes = tree.adjustForeignAttributes(attributes);
+ tree.insertForeignElement(name, attributes, "http://www.w3.org/1998/Math/MathML", selfClosing);
+ };
+
+ modes.inBody.startTagSVG = function(name, attributes, selfClosing) {
+ tree.reconstructActiveFormattingElements();
+ attributes = tree.adjustSVGAttributes(attributes);
+ attributes = tree.adjustForeignAttributes(attributes);
+ tree.insertForeignElement(name, attributes, "http://www.w3.org/2000/svg", selfClosing);
+ };
+
+ modes.inBody.endTagP = function(name) {
+ if (!tree.openElements.inButtonScope('p')) {
+ tree.parseError('unexpected-end-tag', {name: 'p'});
+ this.startTagCloseP('p', []);
+ this.endTagP('p');
+ } else {
+ tree.generateImpliedEndTags('p');
+ if (tree.currentStackItem().localName != 'p')
+ tree.parseError('unexpected-implied-end-tag', {name: 'p'});
+ tree.openElements.popUntilPopped(name);
+ }
+ };
+
+ modes.inBody.endTagBody = function(name) {
+ if (!tree.openElements.inScope('body')) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ return;
+ }
+ if (tree.currentStackItem().localName != 'body') {
+ tree.parseError('expected-one-end-tag-but-got-another', {
+ expectedName: tree.currentStackItem().localName,
+ gotName: name
+ });
+ }
+ tree.setInsertionMode('afterBody');
+ };
+
+ modes.inBody.endTagHtml = function(name) {
+ if (!tree.openElements.inScope('body')) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ return;
+ }
+ if (tree.currentStackItem().localName != 'body') {
+ tree.parseError('expected-one-end-tag-but-got-another', {
+ expectedName: tree.currentStackItem().localName,
+ gotName: name
+ });
+ }
+ tree.setInsertionMode('afterBody');
+ tree.insertionMode.processEndTag(name);
+ };
+
+ modes.inBody.endTagBlock = function(name) {
+ if (!tree.openElements.inScope(name)) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ } else {
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem().localName != name) {
+ tree.parseError('end-tag-too-early', {name: name});
+ }
+ tree.openElements.popUntilPopped(name);
+ }
+ };
+
+ modes.inBody.endTagForm = function(name) {
+ var node = tree.form;
+ tree.form = null;
+ if (!node || !tree.openElements.inScope(name)) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ } else {
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem() != node) {
+ tree.parseError('end-tag-too-early-ignored', {name: 'form'});
+ }
+ tree.openElements.remove(node);
+ }
+ };
+
+ modes.inBody.endTagListItem = function(name) {
+ if (!tree.openElements.inListItemScope(name)) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ } else {
+ tree.generateImpliedEndTags(name);
+ if (tree.currentStackItem().localName != name)
+ tree.parseError('end-tag-too-early', {name: name});
+ tree.openElements.popUntilPopped(name);
+ }
+ };
+
+ modes.inBody.endTagHeading = function(name) {
+ if (!tree.openElements.hasNumberedHeaderElementInScope()) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ return;
+ }
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem().localName != name)
+ tree.parseError('end-tag-too-early', {name: name});
+
+ tree.openElements.remove_openElements_until(function(e) {
+ return e.isNumberedHeader();
+ });
+ };
+
+ modes.inBody.endTagFormatting = function(name, attributes) {
+ if (!tree.adoptionAgencyEndTag(name))
+ this.endTagOther(name, attributes);
+ };
+
+ modes.inCaption = Object.create(modes.base);
+
+ modes.inCaption.start_tag_handlers = {
+ html: 'startTagHtml',
+ caption: 'startTagTableElement',
+ col: 'startTagTableElement',
+ colgroup: 'startTagTableElement',
+ tbody: 'startTagTableElement',
+ td: 'startTagTableElement',
+ tfoot: 'startTagTableElement',
+ thead: 'startTagTableElement',
+ tr: 'startTagTableElement',
+ '-default': 'startTagOther'
+ };
+
+ modes.inCaption.end_tag_handlers = {
+ caption: 'endTagCaption',
+ table: 'endTagTable',
+ body: 'endTagIgnore',
+ col: 'endTagIgnore',
+ colgroup: 'endTagIgnore',
+ html: 'endTagIgnore',
+ tbody: 'endTagIgnore',
+ td: 'endTagIgnore',
+ tfood: 'endTagIgnore',
+ thead: 'endTagIgnore',
+ tr: 'endTagIgnore',
+ '-default': 'endTagOther'
+ };
+
+ modes.inCaption.processCharacters = function(data) {
+ modes.inBody.processCharacters(data);
+ };
+
+ modes.inCaption.startTagTableElement = function(name, attributes) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ var ignoreEndTag = !tree.openElements.inTableScope('caption');
+ tree.insertionMode.processEndTag('caption');
+ if (!ignoreEndTag) tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inCaption.startTagOther = function(name, attributes, selfClosing) {
+ modes.inBody.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inCaption.endTagCaption = function(name) {
+ if (!tree.openElements.inTableScope('caption')) {
+ assert.ok(tree.context);
+ tree.parseError('unexpected-end-tag', {name: name});
+ } else {
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem().localName != 'caption') {
+ tree.parseError('expected-one-end-tag-but-got-another', {
+ gotName: "caption",
+ expectedName: tree.currentStackItem().localName
+ });
+ }
+ tree.openElements.popUntilPopped('caption');
+ tree.clearActiveFormattingElements();
+ tree.setInsertionMode('inTable');
+ }
+ };
+
+ modes.inCaption.endTagTable = function(name) {
+ tree.parseError("unexpected-end-table-in-caption");
+ var ignoreEndTag = !tree.openElements.inTableScope('caption');
+ tree.insertionMode.processEndTag('caption');
+ if (!ignoreEndTag) tree.insertionMode.processEndTag(name);
+ };
+
+ modes.inCaption.endTagIgnore = function(name) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ };
+
+ modes.inCaption.endTagOther = function(name) {
+ modes.inBody.processEndTag(name);
+ };
+
+ modes.inCell = Object.create(modes.base);
+
+ modes.inCell.start_tag_handlers = {
+ html: 'startTagHtml',
+ caption: 'startTagTableOther',
+ col: 'startTagTableOther',
+ colgroup: 'startTagTableOther',
+ tbody: 'startTagTableOther',
+ td: 'startTagTableOther',
+ tfoot: 'startTagTableOther',
+ th: 'startTagTableOther',
+ thead: 'startTagTableOther',
+ tr: 'startTagTableOther',
+ '-default': 'startTagOther'
+ };
+
+ modes.inCell.end_tag_handlers = {
+ td: 'endTagTableCell',
+ th: 'endTagTableCell',
+ body: 'endTagIgnore',
+ caption: 'endTagIgnore',
+ col: 'endTagIgnore',
+ colgroup: 'endTagIgnore',
+ html: 'endTagIgnore',
+ table: 'endTagImply',
+ tbody: 'endTagImply',
+ tfoot: 'endTagImply',
+ thead: 'endTagImply',
+ tr: 'endTagImply',
+ '-default': 'endTagOther'
+ };
+
+ modes.inCell.processCharacters = function(data) {
+ modes.inBody.processCharacters(data);
+ };
+
+ modes.inCell.startTagTableOther = function(name, attributes, selfClosing) {
+ if (tree.openElements.inTableScope('td') || tree.openElements.inTableScope('th')) {
+ this.closeCell();
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ } else {
+ tree.parseError('unexpected-start-tag', {name: name});
+ }
+ };
+
+ modes.inCell.startTagOther = function(name, attributes, selfClosing) {
+ modes.inBody.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inCell.endTagTableCell = function(name) {
+ if (tree.openElements.inTableScope(name)) {
+ tree.generateImpliedEndTags(name);
+ if (tree.currentStackItem().localName != name.toLowerCase()) {
+ tree.parseError('unexpected-cell-end-tag', {name: name});
+ tree.openElements.popUntilPopped(name);
+ } else {
+ tree.popElement();
+ }
+ tree.clearActiveFormattingElements();
+ tree.setInsertionMode('inRow');
+ } else {
+ tree.parseError('unexpected-end-tag', {name: name});
+ }
+ };
+
+ modes.inCell.endTagIgnore = function(name) {
+ tree.parseError('unexpected-end-tag', {name: name});
+ };
+
+ modes.inCell.endTagImply = function(name) {
+ if (tree.openElements.inTableScope(name)) {
+ this.closeCell();
+ tree.insertionMode.processEndTag(name);
+ } else {
+ tree.parseError('unexpected-end-tag', {name: name});
+ }
+ };
+
+ modes.inCell.endTagOther = function(name) {
+ modes.inBody.processEndTag(name);
+ };
+
+ modes.inCell.closeCell = function() {
+ if (tree.openElements.inTableScope('td')) {
+ this.endTagTableCell('td');
+ } else if (tree.openElements.inTableScope('th')) {
+ this.endTagTableCell('th');
+ }
+ };
+
+
+ modes.inColumnGroup = Object.create(modes.base);
+
+ modes.inColumnGroup.start_tag_handlers = {
+ html: 'startTagHtml',
+ col: 'startTagCol',
+ '-default': 'startTagOther'
+ };
+
+ modes.inColumnGroup.end_tag_handlers = {
+ colgroup: 'endTagColgroup',
+ col: 'endTagCol',
+ '-default': 'endTagOther'
+ };
+
+ modes.inColumnGroup.ignoreEndTagColgroup = function() {
+ return tree.currentStackItem().localName == 'html';
+ };
+
+ modes.inColumnGroup.processCharacters = function(buffer) {
+ var leadingWhitespace = buffer.takeLeadingWhitespace();
+ if (leadingWhitespace)
+ tree.insertText(leadingWhitespace);
+ if (!buffer.length)
+ return;
+ var ignoreEndTag = this.ignoreEndTagColgroup();
+ this.endTagColgroup('colgroup');
+ if (!ignoreEndTag) tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.inColumnGroup.startTagCol = function(name, attributes) {
+ tree.insertSelfClosingElement(name, attributes);
+ };
+
+ modes.inColumnGroup.startTagOther = function(name, attributes, selfClosing) {
+ var ignoreEndTag = this.ignoreEndTagColgroup();
+ this.endTagColgroup('colgroup');
+ if (!ignoreEndTag) tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inColumnGroup.endTagColgroup = function(name) {
+ if (this.ignoreEndTagColgroup()) {
+ assert.ok(tree.context);
+ tree.parseError('unexpected-end-tag', {name: name});
+ } else {
+ tree.popElement();
+ tree.setInsertionMode('inTable');
+ }
+ };
+
+ modes.inColumnGroup.endTagCol = function(name) {
+ tree.parseError("no-end-tag", {name: 'col'});
+ };
+
+ modes.inColumnGroup.endTagOther = function(name) {
+ var ignoreEndTag = this.ignoreEndTagColgroup();
+ this.endTagColgroup('colgroup');
+ if (!ignoreEndTag) tree.insertionMode.processEndTag(name) ;
+ };
+
+ modes.inForeignContent = Object.create(modes.base);
+
+ modes.inForeignContent.processStartTag = function(name, attributes, selfClosing) {
+ if (['b', 'big', 'blockquote', 'body', 'br', 'center', 'code', 'dd', 'div', 'dl', 'dt', 'em', 'embed', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'hr', 'i', 'img', 'li', 'listing', 'menu', 'meta', 'nobr', 'ol', 'p', 'pre', 'ruby', 's', 'small', 'span', 'strong', 'strike', 'sub', 'sup', 'table', 'tt', 'u', 'ul', 'var'].indexOf(name) != -1
+ || (name == 'font' && attributes.some(function(attr){ return ['color', 'face', 'size'].indexOf(attr.nodeName) >= 0 }))) {
+ tree.parseError('unexpected-html-element-in-foreign-content', {name: name});
+ while (tree.currentStackItem().isForeign()
+ && !tree.currentStackItem().isHtmlIntegrationPoint()
+ && !tree.currentStackItem().isMathMLTextIntegrationPoint()) {
+ tree.openElements.pop();
+ }
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ return;
+ }
+ if (tree.currentStackItem().namespaceURI == "http://www.w3.org/1998/Math/MathML") {
+ attributes = tree.adjustMathMLAttributes(attributes);
+ }
+ if (tree.currentStackItem().namespaceURI == "http://www.w3.org/2000/svg") {
+ name = tree.adjustSVGTagNameCase(name);
+ attributes = tree.adjustSVGAttributes(attributes);
+ }
+ attributes = tree.adjustForeignAttributes(attributes);
+ tree.insertForeignElement(name, attributes, tree.currentStackItem().namespaceURI, selfClosing);
+ };
+
+ modes.inForeignContent.processEndTag = function(name) {
+ var node = tree.currentStackItem();
+ var index = tree.openElements.length - 1;
+ if (node.localName.toLowerCase() != name)
+ tree.parseError("unexpected-end-tag", {name: name});
+
+ while (true) {
+ if (index === 0)
+ break;
+ if (node.localName.toLowerCase() == name) {
+ while (tree.openElements.pop() != node);
+ break;
+ }
+ index -= 1;
+ node = tree.openElements.item(index);
+ if (node.isForeign()) {
+ continue;
+ } else {
+ tree.insertionMode.processEndTag(name);
+ break;
+ }
+ }
+ };
+
+ modes.inForeignContent.processCharacters = function(buffer) {
+ var characters = buffer.takeRemaining();
+ characters = characters.replace(/\u0000/g, function(match, index){
+ tree.parseError('invalid-codepoint');
+ return '\uFFFD';
+ });
+ if (tree.framesetOk && !isAllWhitespaceOrReplacementCharacters(characters))
+ tree.framesetOk = false;
+ tree.insertText(characters);
+ };
+
+ modes.inHeadNoscript = Object.create(modes.base);
+
+ modes.inHeadNoscript.start_tag_handlers = {
+ html: 'startTagHtml',
+ basefont: 'startTagBasefontBgsoundLinkMetaNoframesStyle',
+ bgsound: 'startTagBasefontBgsoundLinkMetaNoframesStyle',
+ link: 'startTagBasefontBgsoundLinkMetaNoframesStyle',
+ meta: 'startTagBasefontBgsoundLinkMetaNoframesStyle',
+ noframes: 'startTagBasefontBgsoundLinkMetaNoframesStyle',
+ style: 'startTagBasefontBgsoundLinkMetaNoframesStyle',
+ head: 'startTagHeadNoscript',
+ noscript: 'startTagHeadNoscript',
+ "-default": 'startTagOther'
+ };
+
+ modes.inHeadNoscript.end_tag_handlers = {
+ noscript: 'endTagNoscript',
+ br: 'endTagBr',
+ '-default': 'endTagOther'
+ };
+
+ modes.inHeadNoscript.processCharacters = function(buffer) {
+ var leadingWhitespace = buffer.takeLeadingWhitespace();
+ if (leadingWhitespace)
+ tree.insertText(leadingWhitespace);
+ if (!buffer.length)
+ return;
+ tree.parseError("unexpected-char-in-frameset");
+ this.anythingElse();
+ tree.insertionMode.processCharacters(buffer);
+ };
+
+ modes.inHeadNoscript.processComment = function(data) {
+ modes.inHead.processComment(data);
+ };
+
+ modes.inHeadNoscript.startTagBasefontBgsoundLinkMetaNoframesStyle = function(name, attributes) {
+ modes.inHead.processStartTag(name, attributes);
+ };
+
+ modes.inHeadNoscript.startTagHeadNoscript = function(name, attributes) {
+ tree.parseError("unexpected-start-tag-in-frameset", {name: name});
+ };
+
+ modes.inHeadNoscript.startTagOther = function(name, attributes) {
+ tree.parseError("unexpected-start-tag-in-frameset", {name: name});
+ this.anythingElse();
+ tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inHeadNoscript.endTagBr = function(name, attributes) {
+ tree.parseError("unexpected-end-tag-in-frameset", {name: name});
+ this.anythingElse();
+ tree.insertionMode.processEndTag(name, attributes);
+ };
+
+ modes.inHeadNoscript.endTagNoscript = function(name, attributes) {
+ tree.popElement();
+ tree.setInsertionMode('inHead');
+ };
+
+ modes.inHeadNoscript.endTagOther = function(name, attributes) {
+ tree.parseError("unexpected-end-tag-in-frameset", {name: name});
+ };
+
+ modes.inHeadNoscript.anythingElse = function() {
+ tree.popElement();
+ tree.setInsertionMode('inHead');
+ };
+
+
+ modes.inFrameset = Object.create(modes.base);
+
+ modes.inFrameset.start_tag_handlers = {
+ html: 'startTagHtml',
+ frameset: 'startTagFrameset',
+ frame: 'startTagFrame',
+ noframes: 'startTagNoframes',
+ "-default": 'startTagOther'
+ };
+
+ modes.inFrameset.end_tag_handlers = {
+ frameset: 'endTagFrameset',
+ noframes: 'endTagNoframes',
+ '-default': 'endTagOther'
+ };
+
+ modes.inFrameset.processCharacters = function(data) {
+ tree.parseError("unexpected-char-in-frameset");
+ };
+
+ modes.inFrameset.startTagFrameset = function(name, attributes) {
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inFrameset.startTagFrame = function(name, attributes) {
+ tree.insertSelfClosingElement(name, attributes);
+ };
+
+ modes.inFrameset.startTagNoframes = function(name, attributes) {
+ modes.inBody.processStartTag(name, attributes);
+ };
+
+ modes.inFrameset.startTagOther = function(name, attributes) {
+ tree.parseError("unexpected-start-tag-in-frameset", {name: name});
+ };
+
+ modes.inFrameset.endTagFrameset = function(name, attributes) {
+ if (tree.currentStackItem().localName == 'html') {
+ tree.parseError("unexpected-frameset-in-frameset-innerhtml");
+ } else {
+ tree.popElement();
+ }
+
+ if (!tree.context && tree.currentStackItem().localName != 'frameset') {
+ tree.setInsertionMode('afterFrameset');
+ }
+ };
+
+ modes.inFrameset.endTagNoframes = function(name) {
+ modes.inBody.processEndTag(name);
+ };
+
+ modes.inFrameset.endTagOther = function(name) {
+ tree.parseError("unexpected-end-tag-in-frameset", {name: name});
+ };
+
+ modes.inTable = Object.create(modes.base);
+
+ modes.inTable.start_tag_handlers = {
+ html: 'startTagHtml',
+ caption: 'startTagCaption',
+ colgroup: 'startTagColgroup',
+ col: 'startTagCol',
+ table: 'startTagTable',
+ tbody: 'startTagRowGroup',
+ tfoot: 'startTagRowGroup',
+ thead: 'startTagRowGroup',
+ td: 'startTagImplyTbody',
+ th: 'startTagImplyTbody',
+ tr: 'startTagImplyTbody',
+ style: 'startTagStyleScript',
+ script: 'startTagStyleScript',
+ input: 'startTagInput',
+ form: 'startTagForm',
+ '-default': 'startTagOther'
+ };
+
+ modes.inTable.end_tag_handlers = {
+ table: 'endTagTable',
+ body: 'endTagIgnore',
+ caption: 'endTagIgnore',
+ col: 'endTagIgnore',
+ colgroup: 'endTagIgnore',
+ html: 'endTagIgnore',
+ tbody: 'endTagIgnore',
+ td: 'endTagIgnore',
+ tfoot: 'endTagIgnore',
+ th: 'endTagIgnore',
+ thead: 'endTagIgnore',
+ tr: 'endTagIgnore',
+ '-default': 'endTagOther'
+ };
+
+ modes.inTable.processCharacters = function(data) {
+ if (tree.currentStackItem().isFosterParenting()) {
+ var originalInsertionMode = tree.insertionModeName;
+ tree.setInsertionMode('inTableText');
+ tree.originalInsertionMode = originalInsertionMode;
+ tree.insertionMode.processCharacters(data);
+ } else {
+ tree.redirectAttachToFosterParent = true;
+ modes.inBody.processCharacters(data);
+ tree.redirectAttachToFosterParent = false;
+ }
+ };
+
+ modes.inTable.startTagCaption = function(name, attributes) {
+ tree.openElements.popUntilTableScopeMarker();
+ tree.activeFormattingElements.push(Marker);
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inCaption');
+ };
+
+ modes.inTable.startTagColgroup = function(name, attributes) {
+ tree.openElements.popUntilTableScopeMarker();
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inColumnGroup');
+ };
+
+ modes.inTable.startTagCol = function(name, attributes) {
+ this.startTagColgroup('colgroup', []);
+ tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inTable.startTagRowGroup = function(name, attributes) {
+ tree.openElements.popUntilTableScopeMarker();
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inTableBody');
+ };
+
+ modes.inTable.startTagImplyTbody = function(name, attributes) {
+ this.startTagRowGroup('tbody', []);
+ tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inTable.startTagTable = function(name, attributes) {
+ tree.parseError("unexpected-start-tag-implies-end-tag",
+ {startName: "table", endName: "table"});
+ tree.insertionMode.processEndTag('table');
+ if (!tree.context) tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inTable.startTagStyleScript = function(name, attributes) {
+ modes.inHead.processStartTag(name, attributes);
+ };
+
+ modes.inTable.startTagInput = function(name, attributes) {
+ for (var key in attributes) {
+ if (attributes[key].nodeName.toLowerCase() == 'type') {
+ if (attributes[key].nodeValue.toLowerCase() == 'hidden') {
+ tree.parseError("unexpected-hidden-input-in-table");
+ tree.insertElement(name, attributes);
+ tree.openElements.pop();
+ return;
+ }
+ break;
+ }
+ }
+ this.startTagOther(name, attributes);
+ };
+
+ modes.inTable.startTagForm = function(name, attributes) {
+ tree.parseError("unexpected-form-in-table");
+ if (!tree.form) {
+ tree.insertElement(name, attributes);
+ tree.form = tree.currentStackItem();
+ tree.openElements.pop();
+ }
+ };
+
+ modes.inTable.startTagOther = function(name, attributes, selfClosing) {
+ tree.parseError("unexpected-start-tag-implies-table-voodoo", {name: name});
+ tree.redirectAttachToFosterParent = true;
+ modes.inBody.processStartTag(name, attributes, selfClosing);
+ tree.redirectAttachToFosterParent = false;
+ };
+
+ modes.inTable.endTagTable = function(name) {
+ if (tree.openElements.inTableScope(name)) {
+ tree.generateImpliedEndTags();
+ if (tree.currentStackItem().localName != name) {
+ tree.parseError("end-tag-too-early-named", {gotName: 'table', expectedName: tree.currentStackItem().localName});
+ }
+
+ tree.openElements.popUntilPopped('table');
+ tree.resetInsertionMode();
+ } else {
+ assert.ok(tree.context);
+ tree.parseError('unexpected-end-tag', {name: name});
+ }
+ };
+
+ modes.inTable.endTagIgnore = function(name) {
+ tree.parseError("unexpected-end-tag", {name: name});
+ };
+
+ modes.inTable.endTagOther = function(name) {
+ tree.parseError("unexpected-end-tag-implies-table-voodoo", {name: name});
+ tree.redirectAttachToFosterParent = true;
+ modes.inBody.processEndTag(name);
+ tree.redirectAttachToFosterParent = false;
+ };
+
+ modes.inTableText = Object.create(modes.base);
+
+ modes.inTableText.flushCharacters = function() {
+ var characters = tree.pendingTableCharacters.join('');
+ if (!isAllWhitespace(characters)) {
+ tree.redirectAttachToFosterParent = true;
+ tree.reconstructActiveFormattingElements();
+ tree.insertText(characters);
+ tree.framesetOk = false;
+ tree.redirectAttachToFosterParent = false;
+ } else {
+ tree.insertText(characters);
+ }
+ tree.pendingTableCharacters = [];
+ };
+
+ modes.inTableText.processComment = function(data) {
+ this.flushCharacters();
+ tree.setInsertionMode(tree.originalInsertionMode);
+ tree.insertionMode.processComment(data);
+ };
+
+ modes.inTableText.processEOF = function(data) {
+ this.flushCharacters();
+ tree.setInsertionMode(tree.originalInsertionMode);
+ tree.insertionMode.processEOF();
+ };
+
+ modes.inTableText.processCharacters = function(buffer) {
+ var characters = buffer.takeRemaining();
+ characters = characters.replace(/\u0000/g, function(match, index){
+ tree.parseError("invalid-codepoint");
+ return '';
+ });
+ if (!characters)
+ return;
+ tree.pendingTableCharacters.push(characters);
+ };
+
+ modes.inTableText.processStartTag = function(name, attributes, selfClosing) {
+ this.flushCharacters();
+ tree.setInsertionMode(tree.originalInsertionMode);
+ tree.insertionMode.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inTableText.processEndTag = function(name, attributes) {
+ this.flushCharacters();
+ tree.setInsertionMode(tree.originalInsertionMode);
+ tree.insertionMode.processEndTag(name, attributes);
+ };
+
+ modes.inTableBody = Object.create(modes.base);
+
+ modes.inTableBody.start_tag_handlers = {
+ html: 'startTagHtml',
+ tr: 'startTagTr',
+ td: 'startTagTableCell',
+ th: 'startTagTableCell',
+ caption: 'startTagTableOther',
+ col: 'startTagTableOther',
+ colgroup: 'startTagTableOther',
+ tbody: 'startTagTableOther',
+ tfoot: 'startTagTableOther',
+ thead: 'startTagTableOther',
+ '-default': 'startTagOther'
+ };
+
+ modes.inTableBody.end_tag_handlers = {
+ table: 'endTagTable',
+ tbody: 'endTagTableRowGroup',
+ tfoot: 'endTagTableRowGroup',
+ thead: 'endTagTableRowGroup',
+ body: 'endTagIgnore',
+ caption: 'endTagIgnore',
+ col: 'endTagIgnore',
+ colgroup: 'endTagIgnore',
+ html: 'endTagIgnore',
+ td: 'endTagIgnore',
+ th: 'endTagIgnore',
+ tr: 'endTagIgnore',
+ '-default': 'endTagOther'
+ };
+
+ modes.inTableBody.processCharacters = function(data) {
+ modes.inTable.processCharacters(data);
+ };
+
+ modes.inTableBody.startTagTr = function(name, attributes) {
+ tree.openElements.popUntilTableBodyScopeMarker();
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inRow');
+ };
+
+ modes.inTableBody.startTagTableCell = function(name, attributes) {
+ tree.parseError("unexpected-cell-in-table-body", {name: name});
+ this.startTagTr('tr', []);
+ tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inTableBody.startTagTableOther = function(name, attributes) {
+ if (tree.openElements.inTableScope('tbody') || tree.openElements.inTableScope('thead') || tree.openElements.inTableScope('tfoot')) {
+ tree.openElements.popUntilTableBodyScopeMarker();
+ this.endTagTableRowGroup(tree.currentStackItem().localName);
+ tree.insertionMode.processStartTag(name, attributes);
+ } else {
+ tree.parseError('unexpected-start-tag', {name: name});
+ }
+ };
+
+ modes.inTableBody.startTagOther = function(name, attributes) {
+ modes.inTable.processStartTag(name, attributes);
+ };
+
+ modes.inTableBody.endTagTableRowGroup = function(name) {
+ if (tree.openElements.inTableScope(name)) {
+ tree.openElements.popUntilTableBodyScopeMarker();
+ tree.popElement();
+ tree.setInsertionMode('inTable');
+ } else {
+ tree.parseError('unexpected-end-tag-in-table-body', {name: name});
+ }
+ };
+
+ modes.inTableBody.endTagTable = function(name) {
+ if (tree.openElements.inTableScope('tbody') || tree.openElements.inTableScope('thead') || tree.openElements.inTableScope('tfoot')) {
+ tree.openElements.popUntilTableBodyScopeMarker();
+ this.endTagTableRowGroup(tree.currentStackItem().localName);
+ tree.insertionMode.processEndTag(name);
+ } else {
+ tree.parseError('unexpected-end-tag', {name: name});
+ }
+ };
+
+ modes.inTableBody.endTagIgnore = function(name) {
+ tree.parseError("unexpected-end-tag-in-table-body", {name: name});
+ };
+
+ modes.inTableBody.endTagOther = function(name) {
+ modes.inTable.processEndTag(name);
+ };
+
+ modes.inSelect = Object.create(modes.base);
+
+ modes.inSelect.start_tag_handlers = {
+ html: 'startTagHtml',
+ option: 'startTagOption',
+ optgroup: 'startTagOptgroup',
+ select: 'startTagSelect',
+ input: 'startTagInput',
+ keygen: 'startTagInput',
+ textarea: 'startTagInput',
+ script: 'startTagScript',
+ '-default': 'startTagOther'
+ };
+
+ modes.inSelect.end_tag_handlers = {
+ option: 'endTagOption',
+ optgroup: 'endTagOptgroup',
+ select: 'endTagSelect',
+ caption: 'endTagTableElements',
+ table: 'endTagTableElements',
+ tbody: 'endTagTableElements',
+ tfoot: 'endTagTableElements',
+ thead: 'endTagTableElements',
+ tr: 'endTagTableElements',
+ td: 'endTagTableElements',
+ th: 'endTagTableElements',
+ '-default': 'endTagOther'
+ };
+
+ modes.inSelect.processCharacters = function(buffer) {
+ var data = buffer.takeRemaining();
+ data = data.replace(/\u0000/g, function(match, index){
+ tree.parseError("invalid-codepoint");
+ return '';
+ });
+ if (!data)
+ return;
+ tree.insertText(data);
+ };
+
+ modes.inSelect.startTagOption = function(name, attributes) {
+ if (tree.currentStackItem().localName == 'option')
+ tree.popElement();
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inSelect.startTagOptgroup = function(name, attributes) {
+ if (tree.currentStackItem().localName == 'option')
+ tree.popElement();
+ if (tree.currentStackItem().localName == 'optgroup')
+ tree.popElement();
+ tree.insertElement(name, attributes);
+ };
+
+ modes.inSelect.endTagOption = function(name) {
+ if (tree.currentStackItem().localName !== 'option') {
+ tree.parseError('unexpected-end-tag-in-select', {name: name});
+ return;
+ }
+ tree.popElement();
+ };
+
+ modes.inSelect.endTagOptgroup = function(name) {
+ if (tree.currentStackItem().localName == 'option' && tree.openElements.item(tree.openElements.length - 2).localName == 'optgroup') {
+ tree.popElement();
+ }
+ if (tree.currentStackItem().localName == 'optgroup') {
+ tree.popElement();
+ } else {
+ tree.parseError('unexpected-end-tag-in-select', {name: 'optgroup'});
+ }
+ };
+
+ modes.inSelect.startTagSelect = function(name) {
+ tree.parseError("unexpected-select-in-select");
+ this.endTagSelect('select');
+ };
+
+ modes.inSelect.endTagSelect = function(name) {
+ if (tree.openElements.inTableScope('select')) {
+ tree.openElements.popUntilPopped('select');
+ tree.resetInsertionMode();
+ } else {
+ tree.parseError('unexpected-end-tag', {name: name});
+ }
+ };
+
+ modes.inSelect.startTagInput = function(name, attributes) {
+ tree.parseError("unexpected-input-in-select");
+ if (tree.openElements.inSelectScope('select')) {
+ this.endTagSelect('select');
+ tree.insertionMode.processStartTag(name, attributes);
+ }
+ };
+
+ modes.inSelect.startTagScript = function(name, attributes) {
+ modes.inHead.processStartTag(name, attributes);
+ };
+
+ modes.inSelect.endTagTableElements = function(name) {
+ tree.parseError('unexpected-end-tag-in-select', {name: name});
+ if (tree.openElements.inTableScope(name)) {
+ this.endTagSelect('select');
+ tree.insertionMode.processEndTag(name);
+ }
+ };
+
+ modes.inSelect.startTagOther = function(name, attributes) {
+ tree.parseError("unexpected-start-tag-in-select", {name: name});
+ };
+
+ modes.inSelect.endTagOther = function(name) {
+ tree.parseError('unexpected-end-tag-in-select', {name: name});
+ };
+
+ modes.inSelectInTable = Object.create(modes.base);
+
+ modes.inSelectInTable.start_tag_handlers = {
+ caption: 'startTagTable',
+ table: 'startTagTable',
+ tbody: 'startTagTable',
+ tfoot: 'startTagTable',
+ thead: 'startTagTable',
+ tr: 'startTagTable',
+ td: 'startTagTable',
+ th: 'startTagTable',
+ '-default': 'startTagOther'
+ };
+
+ modes.inSelectInTable.end_tag_handlers = {
+ caption: 'endTagTable',
+ table: 'endTagTable',
+ tbody: 'endTagTable',
+ tfoot: 'endTagTable',
+ thead: 'endTagTable',
+ tr: 'endTagTable',
+ td: 'endTagTable',
+ th: 'endTagTable',
+ '-default': 'endTagOther'
+ };
+
+ modes.inSelectInTable.processCharacters = function(data) {
+ modes.inSelect.processCharacters(data);
+ };
+
+ modes.inSelectInTable.startTagTable = function(name, attributes) {
+ tree.parseError("unexpected-table-element-start-tag-in-select-in-table", {name: name});
+ this.endTagOther("select");
+ tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inSelectInTable.startTagOther = function(name, attributes, selfClosing) {
+ modes.inSelect.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inSelectInTable.endTagTable = function(name) {
+ tree.parseError("unexpected-table-element-end-tag-in-select-in-table", {name: name});
+ if (tree.openElements.inTableScope(name)) {
+ this.endTagOther("select");
+ tree.insertionMode.processEndTag(name);
+ }
+ };
+
+ modes.inSelectInTable.endTagOther = function(name) {
+ modes.inSelect.processEndTag(name);
+ };
+
+ modes.inRow = Object.create(modes.base);
+
+ modes.inRow.start_tag_handlers = {
+ html: 'startTagHtml',
+ td: 'startTagTableCell',
+ th: 'startTagTableCell',
+ caption: 'startTagTableOther',
+ col: 'startTagTableOther',
+ colgroup: 'startTagTableOther',
+ tbody: 'startTagTableOther',
+ tfoot: 'startTagTableOther',
+ thead: 'startTagTableOther',
+ tr: 'startTagTableOther',
+ '-default': 'startTagOther'
+ };
+
+ modes.inRow.end_tag_handlers = {
+ tr: 'endTagTr',
+ table: 'endTagTable',
+ tbody: 'endTagTableRowGroup',
+ tfoot: 'endTagTableRowGroup',
+ thead: 'endTagTableRowGroup',
+ body: 'endTagIgnore',
+ caption: 'endTagIgnore',
+ col: 'endTagIgnore',
+ colgroup: 'endTagIgnore',
+ html: 'endTagIgnore',
+ td: 'endTagIgnore',
+ th: 'endTagIgnore',
+ '-default': 'endTagOther'
+ };
+
+ modes.inRow.processCharacters = function(data) {
+ modes.inTable.processCharacters(data);
+ };
+
+ modes.inRow.startTagTableCell = function(name, attributes) {
+ tree.openElements.popUntilTableRowScopeMarker();
+ tree.insertElement(name, attributes);
+ tree.setInsertionMode('inCell');
+ tree.activeFormattingElements.push(Marker);
+ };
+
+ modes.inRow.startTagTableOther = function(name, attributes) {
+ var ignoreEndTag = this.ignoreEndTagTr();
+ this.endTagTr('tr');
+ if (!ignoreEndTag) tree.insertionMode.processStartTag(name, attributes);
+ };
+
+ modes.inRow.startTagOther = function(name, attributes, selfClosing) {
+ modes.inTable.processStartTag(name, attributes, selfClosing);
+ };
+
+ modes.inRow.endTagTr = function(name) {
+ if (this.ignoreEndTagTr()) {
+ assert.ok(tree.context);
+ tree.parseError('unexpected-end-tag', {name: name});
+ } else {
+ tree.openElements.popUntilTableRowScopeMarker();
+ tree.popElement();
+ tree.setInsertionMode('inTableBody');
+ }
+ };
+
+ modes.inRow.endTagTable = function(name) {
+ var ignoreEndTag = this.ignoreEndTagTr();
+ this.endTagTr('tr');
+ if (!ignoreEndTag) tree.insertionMode.processEndTag(name);
+ };
+
+ modes.inRow.endTagTableRowGroup = function(name) {
+ if (tree.openElements.inTableScope(name)) {
+ this.endTagTr('tr');
+ tree.insertionMode.processEndTag(name);
+ } else {
+ tree.parseError('unexpected-end-tag', {name: name});
+ }
+ };
+
+ modes.inRow.endTagIgnore = function(name) {
+ tree.parseError("unexpected-end-tag-in-table-row", {name: name});
+ };
+
+ modes.inRow.endTagOther = function(name) {
+ modes.inTable.processEndTag(name);
+ };
+
+ modes.inRow.ignoreEndTagTr = function() {
+ return !tree.openElements.inTableScope('tr');
+ };
+
+ modes.afterAfterFrameset = Object.create(modes.base);
+
+ modes.afterAfterFrameset.start_tag_handlers = {
+ html: 'startTagHtml',
+ noframes: 'startTagNoFrames',
+ '-default': 'startTagOther'
+ };
+
+ modes.afterAfterFrameset.processEOF = function() {};
+
+ modes.afterAfterFrameset.processComment = function(data) {
+ tree.insertComment(data, tree.document);
+ };
+
+ modes.afterAfterFrameset.processCharacters = function(buffer) {
+ var characters = buffer.takeRemaining();
+ var whitespace = "";
+ for (var i = 0; i < characters.length; i++) {
+ var ch = characters[i];
+ if (isWhitespace(ch))
+ whitespace += ch;
+ }
+ if (whitespace) {
+ tree.reconstructActiveFormattingElements();
+ tree.insertText(whitespace);
+ }
+ if (whitespace.length < characters.length)
+ tree.parseError('expected-eof-but-got-char');
+ };
+
+ modes.afterAfterFrameset.startTagNoFrames = function(name, attributes) {
+ modes.inHead.processStartTag(name, attributes);
+ };
+
+ modes.afterAfterFrameset.startTagOther = function(name, attributes, selfClosing) {
+ tree.parseError('expected-eof-but-got-start-tag', {name: name});
+ };
+
+ modes.afterAfterFrameset.processEndTag = function(name, attributes) {
+ tree.parseError('expected-eof-but-got-end-tag', {name: name});
+ };
+
+ modes.text = Object.create(modes.base);
+
+ modes.text.start_tag_handlers = {
+ '-default': 'startTagOther'
+ };
+
+ modes.text.end_tag_handlers = {
+ script: 'endTagScript',
+ '-default': 'endTagOther'
+ };
+
+ modes.text.processCharacters = function(buffer) {
+ if (tree.shouldSkipLeadingNewline) {
+ tree.shouldSkipLeadingNewline = false;
+ buffer.skipAtMostOneLeadingNewline();
+ }
+ var data = buffer.takeRemaining();
+ if (!data)
+ return;
+ tree.insertText(data);
+ };
+
+ modes.text.processEOF = function() {
+ tree.parseError("expected-named-closing-tag-but-got-eof",
+ {name: tree.currentStackItem().localName});
+ tree.openElements.pop();
+ tree.setInsertionMode(tree.originalInsertionMode);
+ tree.insertionMode.processEOF();
+ };
+
+ modes.text.startTagOther = function(name) {
+ throw "Tried to process start tag " + name + " in RCDATA/RAWTEXT mode";
+ };
+
+ modes.text.endTagScript = function(name) {
+ var node = tree.openElements.pop();
+ assert.ok(node.localName == 'script');
+ tree.setInsertionMode(tree.originalInsertionMode);
+ };
+
+ modes.text.endTagOther = function(name) {
+ tree.openElements.pop();
+ tree.setInsertionMode(tree.originalInsertionMode);
+ };
+}
+
+TreeBuilder.prototype.setInsertionMode = function(name) {
+ this.insertionMode = this.insertionModes[name];
+ this.insertionModeName = name;
+};
+TreeBuilder.prototype.adoptionAgencyEndTag = function(name) {
+ var outerIterationLimit = 8;
+ var innerIterationLimit = 3;
+ var formattingElement;
+
+ function isActiveFormattingElement(el) {
+ return el === formattingElement;
+ }
+
+ var outerLoopCounter = 0;
+
+ while (outerLoopCounter++ < outerIterationLimit) {
+ formattingElement = this.elementInActiveFormattingElements(name);
+
+ if (!formattingElement || (this.openElements.contains(formattingElement) && !this.openElements.inScope(formattingElement.localName))) {
+ this.parseError('adoption-agency-1.1', {name: name});
+ return false;
+ }
+ if (!this.openElements.contains(formattingElement)) {
+ this.parseError('adoption-agency-1.2', {name: name});
+ this.removeElementFromActiveFormattingElements(formattingElement);
+ return true;
+ }
+ if (!this.openElements.inScope(formattingElement.localName)) {
+ this.parseError('adoption-agency-4.4', {name: name});
+ }
+
+ if (formattingElement != this.currentStackItem()) {
+ this.parseError('adoption-agency-1.3', {name: name});
+ }
+ var furthestBlock = this.openElements.furthestBlockForFormattingElement(formattingElement.node);
+
+ if (!furthestBlock) {
+ this.openElements.remove_openElements_until(isActiveFormattingElement);
+ this.removeElementFromActiveFormattingElements(formattingElement);
+ return true;
+ }
+
+ var afeIndex = this.openElements.elements.indexOf(formattingElement);
+ var commonAncestor = this.openElements.item(afeIndex - 1);
+
+ var bookmark = this.activeFormattingElements.indexOf(formattingElement);
+
+ var node = furthestBlock;
+ var lastNode = furthestBlock;
+ var index = this.openElements.elements.indexOf(node);
+
+ var innerLoopCounter = 0;
+ while (innerLoopCounter++ < innerIterationLimit) {
+ index -= 1;
+ node = this.openElements.item(index);
+ if (this.activeFormattingElements.indexOf(node) < 0) {
+ this.openElements.elements.splice(index, 1);
+ continue;
+ }
+ if (node == formattingElement)
+ break;
+
+ if (lastNode == furthestBlock)
+ bookmark = this.activeFormattingElements.indexOf(node) + 1;
+
+ var clone = this.createElement(node.namespaceURI, node.localName, node.attributes);
+ var newNode = new StackItem(node.namespaceURI, node.localName, node.attributes, clone);
+
+ this.activeFormattingElements[this.activeFormattingElements.indexOf(node)] = newNode;
+ this.openElements.elements[this.openElements.elements.indexOf(node)] = newNode;
+
+ node = newNode;
+ this.detachFromParent(lastNode.node);
+ this.attachNode(lastNode.node, node.node);
+ lastNode = node;
+ }
+
+ this.detachFromParent(lastNode.node);
+ if (commonAncestor.isFosterParenting()) {
+ this.insertIntoFosterParent(lastNode.node);
+ } else {
+ this.attachNode(lastNode.node, commonAncestor.node);
+ }
+
+ var clone = this.createElement("http://www.w3.org/1999/xhtml", formattingElement.localName, formattingElement.attributes);
+ var formattingClone = new StackItem(formattingElement.namespaceURI, formattingElement.localName, formattingElement.attributes, clone);
+
+ this.reparentChildren(furthestBlock.node, clone);
+ this.attachNode(clone, furthestBlock.node);
+
+ this.removeElementFromActiveFormattingElements(formattingElement);
+ this.activeFormattingElements.splice(Math.min(bookmark, this.activeFormattingElements.length), 0, formattingClone);
+
+ this.openElements.remove(formattingElement);
+ this.openElements.elements.splice(this.openElements.elements.indexOf(furthestBlock) + 1, 0, formattingClone);
+ }
+
+ return true;
+};
+
+TreeBuilder.prototype.start = function() {
+ throw "Not mplemented";
+};
+
+TreeBuilder.prototype.startTokenization = function(tokenizer) {
+ this.tokenizer = tokenizer;
+ this.compatMode = "no quirks";
+ this.originalInsertionMode = "initial";
+ this.framesetOk = true;
+ this.openElements = new ElementStack();
+ this.activeFormattingElements = [];
+ this.start();
+ if (this.context) {
+ switch(this.context) {
+ case 'title':
+ case 'textarea':
+ this.tokenizer.setState(Tokenizer.RCDATA);
+ break;
+ case 'style':
+ case 'xmp':
+ case 'iframe':
+ case 'noembed':
+ case 'noframes':
+ this.tokenizer.setState(Tokenizer.RAWTEXT);
+ break;
+ case 'script':
+ this.tokenizer.setState(Tokenizer.SCRIPT_DATA);
+ break;
+ case 'noscript':
+ if (this.scriptingEnabled)
+ this.tokenizer.setState(Tokenizer.RAWTEXT);
+ break;
+ case 'plaintext':
+ this.tokenizer.setState(Tokenizer.PLAINTEXT);
+ break;
+ }
+ this.insertHtmlElement();
+ this.resetInsertionMode();
+ } else {
+ this.setInsertionMode('initial');
+ }
+};
+
+TreeBuilder.prototype.processToken = function(token) {
+ this.selfClosingFlagAcknowledged = false;
+
+ var currentNode = this.openElements.top || null;
+ var insertionMode;
+ if (!currentNode || !currentNode.isForeign() ||
+ (currentNode.isMathMLTextIntegrationPoint() &&
+ ((token.type == 'StartTag' &&
+ !(token.name in {mglyph:0, malignmark:0})) ||
+ (token.type === 'Characters'))
+ ) ||
+ (currentNode.namespaceURI == "http://www.w3.org/1998/Math/MathML" &&
+ currentNode.localName == 'annotation-xml' &&
+ token.type == 'StartTag' && token.name == 'svg'
+ ) ||
+ (currentNode.isHtmlIntegrationPoint() &&
+ token.type in {StartTag:0, Characters:0}
+ ) ||
+ token.type == 'EOF'
+ ) {
+ insertionMode = this.insertionMode;
+ } else {
+ insertionMode = this.insertionModes.inForeignContent;
+ }
+ switch(token.type) {
+ case 'Characters':
+ var buffer = new CharacterBuffer(token.data);
+ insertionMode.processCharacters(buffer);
+ break;
+ case 'Comment':
+ insertionMode.processComment(token.data);
+ break;
+ case 'StartTag':
+ insertionMode.processStartTag(token.name, token.data, token.selfClosing);
+ break;
+ case 'EndTag':
+ insertionMode.processEndTag(token.name);
+ break;
+ case 'Doctype':
+ insertionMode.processDoctype(token.name, token.publicId, token.systemId, token.forceQuirks);
+ break;
+ case 'EOF':
+ insertionMode.processEOF();
+ break;
+ }
+};
+TreeBuilder.prototype.isCdataSectionAllowed = function() {
+ return this.openElements.length > 0 && this.currentStackItem().isForeign();
+};
+TreeBuilder.prototype.isSelfClosingFlagAcknowledged = function() {
+ return this.selfClosingFlagAcknowledged;
+};
+
+TreeBuilder.prototype.createElement = function(namespaceURI, localName, attributes) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.attachNode = function(child, parent) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.attachNodeToFosterParent = function(child, table, stackParent) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.detachFromParent = function(node) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.addAttributesToElement = function(element, attributes) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.insertHtmlElement = function(attributes) {
+ var root = this.createElement("http://www.w3.org/1999/xhtml", 'html', attributes);
+ this.attachNode(root, this.document);
+ this.openElements.pushHtmlElement(new StackItem("http://www.w3.org/1999/xhtml", 'html', attributes, root));
+ return root;
+};
+
+TreeBuilder.prototype.insertHeadElement = function(attributes) {
+ var element = this.createElement("http://www.w3.org/1999/xhtml", "head", attributes);
+ this.head = new StackItem("http://www.w3.org/1999/xhtml", "head", attributes, element);
+ this.attachNode(element, this.openElements.top.node);
+ this.openElements.pushHeadElement(this.head);
+ return element;
+};
+
+TreeBuilder.prototype.insertBodyElement = function(attributes) {
+ var element = this.createElement("http://www.w3.org/1999/xhtml", "body", attributes);
+ this.attachNode(element, this.openElements.top.node);
+ this.openElements.pushBodyElement(new StackItem("http://www.w3.org/1999/xhtml", "body", attributes, element));
+ return element;
+};
+
+TreeBuilder.prototype.insertIntoFosterParent = function(node) {
+ var tableIndex = this.openElements.findIndex('table');
+ var tableElement = this.openElements.item(tableIndex).node;
+ if (tableIndex === 0)
+ return this.attachNode(node, tableElement);
+ this.attachNodeToFosterParent(node, tableElement, this.openElements.item(tableIndex - 1).node);
+};
+
+TreeBuilder.prototype.insertElement = function(name, attributes, namespaceURI, selfClosing) {
+ if (!namespaceURI)
+ namespaceURI = "http://www.w3.org/1999/xhtml";
+ var element = this.createElement(namespaceURI, name, attributes);
+ if (this.shouldFosterParent())
+ this.insertIntoFosterParent(element);
+ else
+ this.attachNode(element, this.openElements.top.node);
+ if (!selfClosing)
+ this.openElements.push(new StackItem(namespaceURI, name, attributes, element));
+};
+
+TreeBuilder.prototype.insertFormattingElement = function(name, attributes) {
+ this.insertElement(name, attributes, "http://www.w3.org/1999/xhtml");
+ this.appendElementToActiveFormattingElements(this.currentStackItem());
+};
+
+TreeBuilder.prototype.insertSelfClosingElement = function(name, attributes) {
+ this.selfClosingFlagAcknowledged = true;
+ this.insertElement(name, attributes, "http://www.w3.org/1999/xhtml", true);
+};
+
+TreeBuilder.prototype.insertForeignElement = function(name, attributes, namespaceURI, selfClosing) {
+ if (selfClosing)
+ this.selfClosingFlagAcknowledged = true;
+ this.insertElement(name, attributes, namespaceURI, selfClosing);
+};
+
+TreeBuilder.prototype.insertComment = function(data, parent) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.insertDoctype = function(name, publicId, systemId) {
+ throw new Error("Not implemented");
+};
+
+TreeBuilder.prototype.insertText = function(data) {
+ throw new Error("Not implemented");
+};
+TreeBuilder.prototype.currentStackItem = function() {
+ return this.openElements.top;
+};
+TreeBuilder.prototype.popElement = function() {
+ return this.openElements.pop();
+};
+TreeBuilder.prototype.shouldFosterParent = function() {
+ return this.redirectAttachToFosterParent && this.currentStackItem().isFosterParenting();
+};
+TreeBuilder.prototype.generateImpliedEndTags = function(exclude) {
+ var name = this.openElements.top.localName;
+ if (['dd', 'dt', 'li', 'option', 'optgroup', 'p', 'rp', 'rt'].indexOf(name) != -1 && name != exclude) {
+ this.popElement();
+ this.generateImpliedEndTags(exclude);
+ }
+};
+TreeBuilder.prototype.reconstructActiveFormattingElements = function() {
+ if (this.activeFormattingElements.length === 0)
+ return;
+ var i = this.activeFormattingElements.length - 1;
+ var entry = this.activeFormattingElements[i];
+ if (entry == Marker || this.openElements.contains(entry))
+ return;
+
+ while (entry != Marker && !this.openElements.contains(entry)) {
+ i -= 1;
+ entry = this.activeFormattingElements[i];
+ if (!entry)
+ break;
+ }
+
+ while (true) {
+ i += 1;
+ entry = this.activeFormattingElements[i];
+ this.insertElement(entry.localName, entry.attributes);
+ var element = this.currentStackItem();
+ this.activeFormattingElements[i] = element;
+ if (element == this.activeFormattingElements[this.activeFormattingElements.length -1])
+ break;
+ }
+
+};
+TreeBuilder.prototype.ensureNoahsArkCondition = function(item) {
+ var kNoahsArkCapacity = 3;
+ if (this.activeFormattingElements.length < kNoahsArkCapacity)
+ return;
+ var candidates = [];
+ var newItemAttributeCount = item.attributes.length;
+ for (var i = this.activeFormattingElements.length - 1; i >= 0; i--) {
+ var candidate = this.activeFormattingElements[i];
+ if (candidate === Marker)
+ break;
+ if (item.localName !== candidate.localName || item.namespaceURI !== candidate.namespaceURI)
+ continue;
+ if (candidate.attributes.length != newItemAttributeCount)
+ continue;
+ candidates.push(candidate);
+ }
+ if (candidates.length < kNoahsArkCapacity)
+ return;
+
+ var remainingCandidates = [];
+ var attributes = item.attributes;
+ for (var i = 0; i < attributes.length; i++) {
+ var attribute = attributes[i];
+
+ for (var j = 0; j < candidates.length; j++) {
+ var candidate = candidates[j];
+ var candidateAttribute = getAttribute(candidate, attribute.nodeName);
+ if (candidateAttribute && candidateAttribute.nodeValue === attribute.nodeValue)
+ remainingCandidates.push(candidate);
+ }
+ if (remainingCandidates.length < kNoahsArkCapacity)
+ return;
+ candidates = remainingCandidates;
+ remainingCandidates = [];
+ }
+ for (var i = kNoahsArkCapacity - 1; i < candidates.length; i++)
+ this.removeElementFromActiveFormattingElements(candidates[i]);
+};
+TreeBuilder.prototype.appendElementToActiveFormattingElements = function(item) {
+ this.ensureNoahsArkCondition(item);
+ this.activeFormattingElements.push(item);
+};
+TreeBuilder.prototype.removeElementFromActiveFormattingElements = function(item) {
+ var index = this.activeFormattingElements.indexOf(item);
+ if (index >= 0)
+ this.activeFormattingElements.splice(index, 1);
+};
+
+TreeBuilder.prototype.elementInActiveFormattingElements = function(name) {
+ var els = this.activeFormattingElements;
+ for (var i = els.length - 1; i >= 0; i--) {
+ if (els[i] == Marker) break;
+ if (els[i].localName == name) return els[i];
+ }
+ return false;
+};
+
+TreeBuilder.prototype.clearActiveFormattingElements = function() {
+ while (!(this.activeFormattingElements.length === 0 || this.activeFormattingElements.pop() == Marker));
+};
+
+TreeBuilder.prototype.reparentChildren = function(oldParent, newParent) {
+ throw new Error("Not implemented");
+};
+TreeBuilder.prototype.setFragmentContext = function(context) {
+ this.context = context;
+};
+TreeBuilder.prototype.parseError = function(code, args) {
+ if (!this.errorHandler)
+ return;
+ var message = formatMessage(messages[code], args);
+ this.errorHandler.error(message, this.tokenizer._inputStream.location(), code);
+};
+TreeBuilder.prototype.resetInsertionMode = function() {
+ var last = false;
+ var node = null;
+ for (var i = this.openElements.length - 1; i >= 0; i--) {
+ node = this.openElements.item(i);
+ if (i === 0) {
+ assert.ok(this.context);
+ last = true;
+ node = new StackItem("http://www.w3.org/1999/xhtml", this.context, [], null);
+ }
+
+ if (node.namespaceURI === "http://www.w3.org/1999/xhtml") {
+ if (node.localName === 'select')
+ return this.setInsertionMode('inSelect');
+ if (node.localName === 'td' || node.localName === 'th')
+ return this.setInsertionMode('inCell');
+ if (node.localName === 'tr')
+ return this.setInsertionMode('inRow');
+ if (node.localName === 'tbody' || node.localName === 'thead' || node.localName === 'tfoot')
+ return this.setInsertionMode('inTableBody');
+ if (node.localName === 'caption')
+ return this.setInsertionMode('inCaption');
+ if (node.localName === 'colgroup')
+ return this.setInsertionMode('inColumnGroup');
+ if (node.localName === 'table')
+ return this.setInsertionMode('inTable');
+ if (node.localName === 'head' && !last)
+ return this.setInsertionMode('inHead');
+ if (node.localName === 'body')
+ return this.setInsertionMode('inBody');
+ if (node.localName === 'frameset')
+ return this.setInsertionMode('inFrameset');
+ if (node.localName === 'html')
+ if (!this.openElements.headElement)
+ return this.setInsertionMode('beforeHead');
+ else
+ return this.setInsertionMode('afterHead');
+ }
+
+ if (last)
+ return this.setInsertionMode('inBody');
+ }
+};
+
+TreeBuilder.prototype.processGenericRCDATAStartTag = function(name, attributes) {
+ this.insertElement(name, attributes);
+ this.tokenizer.setState(Tokenizer.RCDATA);
+ this.originalInsertionMode = this.insertionModeName;
+ this.setInsertionMode('text');
+};
+
+TreeBuilder.prototype.processGenericRawTextStartTag = function(name, attributes) {
+ this.insertElement(name, attributes);
+ this.tokenizer.setState(Tokenizer.RAWTEXT);
+ this.originalInsertionMode = this.insertionModeName;
+ this.setInsertionMode('text');
+};
+
+TreeBuilder.prototype.adjustMathMLAttributes = function(attributes) {
+ attributes.forEach(function(a) {
+ a.namespaceURI = "http://www.w3.org/1998/Math/MathML";
+ if (constants.MATHMLAttributeMap[a.nodeName])
+ a.nodeName = constants.MATHMLAttributeMap[a.nodeName];
+ });
+ return attributes;
+};
+
+TreeBuilder.prototype.adjustSVGTagNameCase = function(name) {
+ return constants.SVGTagMap[name] || name;
+};
+
+TreeBuilder.prototype.adjustSVGAttributes = function(attributes) {
+ attributes.forEach(function(a) {
+ a.namespaceURI = "http://www.w3.org/2000/svg";
+ if (constants.SVGAttributeMap[a.nodeName])
+ a.nodeName = constants.SVGAttributeMap[a.nodeName];
+ });
+ return attributes;
+};
+
+TreeBuilder.prototype.adjustForeignAttributes = function(attributes) {
+ for (var i = 0; i < attributes.length; i++) {
+ var attribute = attributes[i];
+ var adjusted = constants.ForeignAttributeMap[attribute.nodeName];
+ if (adjusted) {
+ attribute.nodeName = adjusted.localName;
+ attribute.prefix = adjusted.prefix;
+ attribute.namespaceURI = adjusted.namespaceURI;
+ }
+ }
+ return attributes;
+};
+
+function formatMessage(format, args) {
+ return format.replace(new RegExp('{[0-9a-z-]+}', 'gi'), function(match) {
+ return args[match.slice(1, -1)] || match;
+ });
+}
+
+exports.TreeBuilder = TreeBuilder;
+
+},
+{"./ElementStack":1,"./StackItem":4,"./Tokenizer":5,"./constants":7,"./messages.json":8,"assert":13,"events":16}],
+7:[function(_dereq_,module,exports){
+exports.SVGTagMap = {
+ "altglyph": "altGlyph",
+ "altglyphdef": "altGlyphDef",
+ "altglyphitem": "altGlyphItem",
+ "animatecolor": "animateColor",
+ "animatemotion": "animateMotion",
+ "animatetransform": "animateTransform",
+ "clippath": "clipPath",
+ "feblend": "feBlend",
+ "fecolormatrix": "feColorMatrix",
+ "fecomponenttransfer": "feComponentTransfer",
+ "fecomposite": "feComposite",
+ "feconvolvematrix": "feConvolveMatrix",
+ "fediffuselighting": "feDiffuseLighting",
+ "fedisplacementmap": "feDisplacementMap",
+ "fedistantlight": "feDistantLight",
+ "feflood": "feFlood",
+ "fefunca": "feFuncA",
+ "fefuncb": "feFuncB",
+ "fefuncg": "feFuncG",
+ "fefuncr": "feFuncR",
+ "fegaussianblur": "feGaussianBlur",
+ "feimage": "feImage",
+ "femerge": "feMerge",
+ "femergenode": "feMergeNode",
+ "femorphology": "feMorphology",
+ "feoffset": "feOffset",
+ "fepointlight": "fePointLight",
+ "fespecularlighting": "feSpecularLighting",
+ "fespotlight": "feSpotLight",
+ "fetile": "feTile",
+ "feturbulence": "feTurbulence",
+ "foreignobject": "foreignObject",
+ "glyphref": "glyphRef",
+ "lineargradient": "linearGradient",
+ "radialgradient": "radialGradient",
+ "textpath": "textPath"
+};
+
+exports.MATHMLAttributeMap = {
+ definitionurl: 'definitionURL'
+};
+
+exports.SVGAttributeMap = {
+ attributename: 'attributeName',
+ attributetype: 'attributeType',
+ basefrequency: 'baseFrequency',
+ baseprofile: 'baseProfile',
+ calcmode: 'calcMode',
+ clippathunits: 'clipPathUnits',
+ contentscripttype: 'contentScriptType',
+ contentstyletype: 'contentStyleType',
+ diffuseconstant: 'diffuseConstant',
+ edgemode: 'edgeMode',
+ externalresourcesrequired: 'externalResourcesRequired',
+ filterres: 'filterRes',
+ filterunits: 'filterUnits',
+ glyphref: 'glyphRef',
+ gradienttransform: 'gradientTransform',
+ gradientunits: 'gradientUnits',
+ kernelmatrix: 'kernelMatrix',
+ kernelunitlength: 'kernelUnitLength',
+ keypoints: 'keyPoints',
+ keysplines: 'keySplines',
+ keytimes: 'keyTimes',
+ lengthadjust: 'lengthAdjust',
+ limitingconeangle: 'limitingConeAngle',
+ markerheight: 'markerHeight',
+ markerunits: 'markerUnits',
+ markerwidth: 'markerWidth',
+ maskcontentunits: 'maskContentUnits',
+ maskunits: 'maskUnits',
+ numoctaves: 'numOctaves',
+ pathlength: 'pathLength',
+ patterncontentunits: 'patternContentUnits',
+ patterntransform: 'patternTransform',
+ patternunits: 'patternUnits',
+ pointsatx: 'pointsAtX',
+ pointsaty: 'pointsAtY',
+ pointsatz: 'pointsAtZ',
+ preservealpha: 'preserveAlpha',
+ preserveaspectratio: 'preserveAspectRatio',
+ primitiveunits: 'primitiveUnits',
+ refx: 'refX',
+ refy: 'refY',
+ repeatcount: 'repeatCount',
+ repeatdur: 'repeatDur',
+ requiredextensions: 'requiredExtensions',
+ requiredfeatures: 'requiredFeatures',
+ specularconstant: 'specularConstant',
+ specularexponent: 'specularExponent',
+ spreadmethod: 'spreadMethod',
+ startoffset: 'startOffset',
+ stddeviation: 'stdDeviation',
+ stitchtiles: 'stitchTiles',
+ surfacescale: 'surfaceScale',
+ systemlanguage: 'systemLanguage',
+ tablevalues: 'tableValues',
+ targetx: 'targetX',
+ targety: 'targetY',
+ textlength: 'textLength',
+ viewbox: 'viewBox',
+ viewtarget: 'viewTarget',
+ xchannelselector: 'xChannelSelector',
+ ychannelselector: 'yChannelSelector',
+ zoomandpan: 'zoomAndPan'
+};
+
+exports.ForeignAttributeMap = {
+ "xlink:actuate": {prefix: "xlink", localName: "actuate", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xlink:arcrole": {prefix: "xlink", localName: "arcrole", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xlink:href": {prefix: "xlink", localName: "href", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xlink:role": {prefix: "xlink", localName: "role", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xlink:show": {prefix: "xlink", localName: "show", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xlink:title": {prefix: "xlink", localName: "title", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xlink:type": {prefix: "xlink", localName: "title", namespaceURI: "http://www.w3.org/1999/xlink"},
+ "xml:base": {prefix: "xml", localName: "base", namespaceURI: "http://www.w3.org/XML/1998/namespace"},
+ "xml:lang": {prefix: "xml", localName: "lang", namespaceURI: "http://www.w3.org/XML/1998/namespace"},
+ "xml:space": {prefix: "xml", localName: "space", namespaceURI: "http://www.w3.org/XML/1998/namespace"},
+ "xmlns": {prefix: null, localName: "xmlns", namespaceURI: "http://www.w3.org/2000/xmlns/"},
+ "xmlns:xlink": {prefix: "xmlns", localName: "xlink", namespaceURI: "http://www.w3.org/2000/xmlns/"},
+};
+},
+{}],
+8:[function(_dereq_,module,exports){
+module.exports={
+ "null-character":
+ "Null character in input stream, replaced with U+FFFD.",
+ "invalid-codepoint":
+ "Invalid codepoint in stream",
+ "incorrectly-placed-solidus":
+ "Solidus (/) incorrectly placed in tag.",
+ "incorrect-cr-newline-entity":
+ "Incorrect CR newline entity, replaced with LF.",
+ "illegal-windows-1252-entity":
+ "Entity used with illegal number (windows-1252 reference).",
+ "cant-convert-numeric-entity":
+ "Numeric entity couldn't be converted to character (codepoint U+{charAsInt}).",
+ "invalid-numeric-entity-replaced":
+ "Numeric entity represents an illegal codepoint. Expanded to the C1 controls range.",
+ "numeric-entity-without-semicolon":
+ "Numeric entity didn't end with ';'.",
+ "expected-numeric-entity-but-got-eof":
+ "Numeric entity expected. Got end of file instead.",
+ "expected-numeric-entity":
+ "Numeric entity expected but none found.",
+ "named-entity-without-semicolon":
+ "Named entity didn't end with ';'.",
+ "expected-named-entity":
+ "Named entity expected. Got none.",
+ "attributes-in-end-tag":
+ "End tag contains unexpected attributes.",
+ "self-closing-flag-on-end-tag":
+ "End tag contains unexpected self-closing flag.",
+ "bare-less-than-sign-at-eof":
+ "End of file after <.",
+ "expected-tag-name-but-got-right-bracket":
+ "Expected tag name. Got '>' instead.",
+ "expected-tag-name-but-got-question-mark":
+ "Expected tag name. Got '?' instead. (HTML doesn't support processing instructions.)",
+ "expected-tag-name":
+ "Expected tag name. Got something else instead.",
+ "expected-closing-tag-but-got-right-bracket":
+ "Expected closing tag. Got '>' instead. Ignoring '</>'.",
+ "expected-closing-tag-but-got-eof":
+ "Expected closing tag. Unexpected end of file.",
+ "expected-closing-tag-but-got-char":
+ "Expected closing tag. Unexpected character '{data}' found.",
+ "eof-in-tag-name":
+ "Unexpected end of file in the tag name.",
+ "expected-attribute-name-but-got-eof":
+ "Unexpected end of file. Expected attribute name instead.",
+ "eof-in-attribute-name":
+ "Unexpected end of file in attribute name.",
+ "invalid-character-in-attribute-name":
+ "Invalid character in attribute name.",
+ "duplicate-attribute":
+ "Dropped duplicate attribute '{name}' on tag.",
+ "expected-end-of-tag-but-got-eof":
+ "Unexpected end of file. Expected = or end of tag.",
+ "expected-attribute-value-but-got-eof":
+ "Unexpected end of file. Expected attribute value.",
+ "expected-attribute-value-but-got-right-bracket":
+ "Expected attribute value. Got '>' instead.",
+ "unexpected-character-in-unquoted-attribute-value":
+ "Unexpected character in unquoted attribute",
+ "invalid-character-after-attribute-name":
+ "Unexpected character after attribute name.",
+ "unexpected-character-after-attribute-value":
+ "Unexpected character after attribute value.",
+ "eof-in-attribute-value-double-quote":
+ "Unexpected end of file in attribute value (\").",
+ "eof-in-attribute-value-single-quote":
+ "Unexpected end of file in attribute value (').",
+ "eof-in-attribute-value-no-quotes":
+ "Unexpected end of file in attribute value.",
+ "eof-after-attribute-value":
+ "Unexpected end of file after attribute value.",
+ "unexpected-eof-after-solidus-in-tag":
+ "Unexpected end of file in tag. Expected >.",
+ "unexpected-character-after-solidus-in-tag":
+ "Unexpected character after / in tag. Expected >.",
+ "expected-dashes-or-doctype":
+ "Expected '--' or 'DOCTYPE'. Not found.",
+ "unexpected-bang-after-double-dash-in-comment":
+ "Unexpected ! after -- in comment.",
+ "incorrect-comment":
+ "Incorrect comment.",
+ "eof-in-comment":
+ "Unexpected end of file in comment.",
+ "eof-in-comment-end-dash":
+ "Unexpected end of file in comment (-).",
+ "unexpected-dash-after-double-dash-in-comment":
+ "Unexpected '-' after '--' found in comment.",
+ "eof-in-comment-double-dash":
+ "Unexpected end of file in comment (--).",
+ "eof-in-comment-end-bang-state":
+ "Unexpected end of file in comment.",
+ "unexpected-char-in-comment":
+ "Unexpected character in comment found.",
+ "need-space-after-doctype":
+ "No space after literal string 'DOCTYPE'.",
+ "expected-doctype-name-but-got-right-bracket":
+ "Unexpected > character. Expected DOCTYPE name.",
+ "expected-doctype-name-but-got-eof":
+ "Unexpected end of file. Expected DOCTYPE name.",
+ "eof-in-doctype-name":
+ "Unexpected end of file in DOCTYPE name.",
+ "eof-in-doctype":
+ "Unexpected end of file in DOCTYPE.",
+ "expected-space-or-right-bracket-in-doctype":
+ "Expected space or '>'. Got '{data}'.",
+ "unexpected-end-of-doctype":
+ "Unexpected end of DOCTYPE.",
+ "unexpected-char-in-doctype":
+ "Unexpected character in DOCTYPE.",
+ "eof-in-bogus-doctype":
+ "Unexpected end of file in bogus doctype.",
+ "eof-in-innerhtml":
+ "Unexpected EOF in inner html mode.",
+ "unexpected-doctype":
+ "Unexpected DOCTYPE. Ignored.",
+ "non-html-root":
+ "html needs to be the first start tag.",
+ "expected-doctype-but-got-eof":
+ "Unexpected End of file. Expected DOCTYPE.",
+ "unknown-doctype":
+ "Erroneous DOCTYPE. Expected <!DOCTYPE html>.",
+ "quirky-doctype":
+ "Quirky doctype. Expected <!DOCTYPE html>.",
+ "almost-standards-doctype":
+ "Almost standards mode doctype. Expected <!DOCTYPE html>.",
+ "obsolete-doctype":
+ "Obsolete doctype. Expected <!DOCTYPE html>.",
+ "expected-doctype-but-got-chars":
+ "Non-space characters found without seeing a doctype first. Expected e.g. <!DOCTYPE html>.",
+ "expected-doctype-but-got-start-tag":
+ "Start tag seen without seeing a doctype first. Expected e.g. <!DOCTYPE html>.",
+ "expected-doctype-but-got-end-tag":
+ "End tag seen without seeing a doctype first. Expected e.g. <!DOCTYPE html>.",
+ "end-tag-after-implied-root":
+ "Unexpected end tag ({name}) after the (implied) root element.",
+ "expected-named-closing-tag-but-got-eof":
+ "Unexpected end of file. Expected end tag ({name}).",
+ "two-heads-are-not-better-than-one":
+ "Unexpected start tag head in existing head. Ignored.",
+ "unexpected-end-tag":
+ "Unexpected end tag ({name}). Ignored.",
+ "unexpected-implied-end-tag":
+ "End tag {name} implied, but there were open elements.",
+ "unexpected-start-tag-out-of-my-head":
+ "Unexpected start tag ({name}) that can be in head. Moved.",
+ "unexpected-start-tag":
+ "Unexpected start tag ({name}).",
+ "missing-end-tag":
+ "Missing end tag ({name}).",
+ "missing-end-tags":
+ "Missing end tags ({name}).",
+ "unexpected-start-tag-implies-end-tag":
+ "Unexpected start tag ({startName}) implies end tag ({endName}).",
+ "unexpected-start-tag-treated-as":
+ "Unexpected start tag ({originalName}). Treated as {newName}.",
+ "deprecated-tag":
+ "Unexpected start tag {name}. Don't use it!",
+ "unexpected-start-tag-ignored":
+ "Unexpected start tag {name}. Ignored.",
+ "expected-one-end-tag-but-got-another":
+ "Unexpected end tag ({gotName}). Missing end tag ({expectedName}).",
+ "end-tag-too-early":
+ "End tag ({name}) seen too early. Expected other end tag.",
+ "end-tag-too-early-named":
+ "Unexpected end tag ({gotName}). Expected end tag ({expectedName}.",
+ "end-tag-too-early-ignored":
+ "End tag ({name}) seen too early. Ignored.",
+ "adoption-agency-1.1":
+ "End tag ({name}) violates step 1, paragraph 1 of the adoption agency algorithm.",
+ "adoption-agency-1.2":
+ "End tag ({name}) violates step 1, paragraph 2 of the adoption agency algorithm.",
+ "adoption-agency-1.3":
+ "End tag ({name}) violates step 1, paragraph 3 of the adoption agency algorithm.",
+ "adoption-agency-4.4":
+ "End tag ({name}) violates step 4, paragraph 4 of the adoption agency algorithm.",
+ "unexpected-end-tag-treated-as":
+ "Unexpected end tag ({originalName}). Treated as {newName}.",
+ "no-end-tag":
+ "This element ({name}) has no end tag.",
+ "unexpected-implied-end-tag-in-table":
+ "Unexpected implied end tag ({name}) in the table phase.",
+ "unexpected-implied-end-tag-in-table-body":
+ "Unexpected implied end tag ({name}) in the table body phase.",
+ "unexpected-char-implies-table-voodoo":
+ "Unexpected non-space characters in table context caused voodoo mode.",
+ "unexpected-hidden-input-in-table":
+ "Unexpected input with type hidden in table context.",
+ "unexpected-form-in-table":
+ "Unexpected form in table context.",
+ "unexpected-start-tag-implies-table-voodoo":
+ "Unexpected start tag ({name}) in table context caused voodoo mode.",
+ "unexpected-end-tag-implies-table-voodoo":
+ "Unexpected end tag ({name}) in table context caused voodoo mode.",
+ "unexpected-cell-in-table-body":
+ "Unexpected table cell start tag ({name}) in the table body phase.",
+ "unexpected-cell-end-tag":
+ "Got table cell end tag ({name}) while required end tags are missing.",
+ "unexpected-end-tag-in-table-body":
+ "Unexpected end tag ({name}) in the table body phase. Ignored.",
+ "unexpected-implied-end-tag-in-table-row":
+ "Unexpected implied end tag ({name}) in the table row phase.",
+ "unexpected-end-tag-in-table-row":
+ "Unexpected end tag ({name}) in the table row phase. Ignored.",
+ "unexpected-select-in-select":
+ "Unexpected select start tag in the select phase treated as select end tag.",
+ "unexpected-input-in-select":
+ "Unexpected input start tag in the select phase.",
+ "unexpected-start-tag-in-select":
+ "Unexpected start tag token ({name}) in the select phase. Ignored.",
+ "unexpected-end-tag-in-select":
+ "Unexpected end tag ({name}) in the select phase. Ignored.",
+ "unexpected-table-element-start-tag-in-select-in-table":
+ "Unexpected table element start tag ({name}) in the select in table phase.",
+ "unexpected-table-element-end-tag-in-select-in-table":
+ "Unexpected table element end tag ({name}) in the select in table phase.",
+ "unexpected-char-after-body":
+ "Unexpected non-space characters in the after body phase.",
+ "unexpected-start-tag-after-body":
+ "Unexpected start tag token ({name}) in the after body phase.",
+ "unexpected-end-tag-after-body":
+ "Unexpected end tag token ({name}) in the after body phase.",
+ "unexpected-char-in-frameset":
+ "Unepxected characters in the frameset phase. Characters ignored.",
+ "unexpected-start-tag-in-frameset":
+ "Unexpected start tag token ({name}) in the frameset phase. Ignored.",
+ "unexpected-frameset-in-frameset-innerhtml":
+ "Unexpected end tag token (frameset in the frameset phase (innerHTML).",
+ "unexpected-end-tag-in-frameset":
+ "Unexpected end tag token ({name}) in the frameset phase. Ignored.",
+ "unexpected-char-after-frameset":
+ "Unexpected non-space characters in the after frameset phase. Ignored.",
+ "unexpected-start-tag-after-frameset":
+ "Unexpected start tag ({name}) in the after frameset phase. Ignored.",
+ "unexpected-end-tag-after-frameset":
+ "Unexpected end tag ({name}) in the after frameset phase. Ignored.",
+ "expected-eof-but-got-char":
+ "Unexpected non-space characters. Expected end of file.",
+ "expected-eof-but-got-start-tag":
+ "Unexpected start tag ({name}). Expected end of file.",
+ "expected-eof-but-got-end-tag":
+ "Unexpected end tag ({name}). Expected end of file.",
+ "unexpected-end-table-in-caption":
+ "Unexpected end table tag in caption. Generates implied end caption.",
+ "end-html-in-innerhtml":
+ "Unexpected html end tag in inner html mode.",
+ "eof-in-table":
+ "Unexpected end of file. Expected table content.",
+ "eof-in-script":
+ "Unexpected end of file. Expected script content.",
+ "non-void-element-with-trailing-solidus":
+ "Trailing solidus not allowed on element {name}.",
+ "unexpected-html-element-in-foreign-content":
+ "HTML start tag \"{name}\" in a foreign namespace context.",
+ "unexpected-start-tag-in-table":
+ "Unexpected {name}. Expected table content."
+}
+},
+{}],
+9:[function(_dereq_,module,exports){
+var SAXTreeBuilder = _dereq_('./SAXTreeBuilder').SAXTreeBuilder;
+var Tokenizer = _dereq_('../Tokenizer').Tokenizer;
+var TreeParser = _dereq_('./TreeParser').TreeParser;
+
+function SAXParser() {
+ this.contentHandler = null;
+ this._errorHandler = null;
+ this._treeBuilder = new SAXTreeBuilder();
+ this._tokenizer = new Tokenizer(this._treeBuilder);
+ this._scriptingEnabled = false;
+}
+
+SAXParser.prototype.parse = function(source) {
+ this._tokenizer.tokenize(source);
+ var document = this._treeBuilder.document;
+ if (document) {
+ new TreeParser(this.contentHandler).parse(document);
+ }
+};
+
+SAXParser.prototype.parseFragment = function(source, context) {
+ this._treeBuilder.setFragmentContext(context);
+ this._tokenizer.tokenize(source);
+ var fragment = this._treeBuilder.getFragment();
+ if (fragment) {
+ new TreeParser(this.contentHandler).parse(fragment);
+ }
+};
+
+Object.defineProperty(SAXParser.prototype, 'scriptingEnabled', {
+ get: function() {
+ return this._scriptingEnabled;
+ },
+ set: function(value) {
+ this._scriptingEnabled = value;
+ this._treeBuilder.scriptingEnabled = value;
+ }
+});
+
+Object.defineProperty(SAXParser.prototype, 'errorHandler', {
+ get: function() {
+ return this._errorHandler;
+ },
+ set: function(value) {
+ this._errorHandler = value;
+ this._treeBuilder.errorHandler = value;
+ }
+});
+
+exports.SAXParser = SAXParser;
+
+},
+{"../Tokenizer":5,"./SAXTreeBuilder":10,"./TreeParser":11}],
+10:[function(_dereq_,module,exports){
+var util = _dereq_('util');
+var TreeBuilder = _dereq_('../TreeBuilder').TreeBuilder;
+
+function SAXTreeBuilder() {
+ TreeBuilder.call(this);
+}
+
+util.inherits(SAXTreeBuilder, TreeBuilder);
+
+SAXTreeBuilder.prototype.start = function(tokenizer) {
+ this.document = new Document(this.tokenizer);
+};
+
+SAXTreeBuilder.prototype.end = function() {
+ this.document.endLocator = this.tokenizer;
+};
+
+SAXTreeBuilder.prototype.insertDoctype = function(name, publicId, systemId) {
+ var doctype = new DTD(this.tokenizer, name, publicId, systemId);
+ doctype.endLocator = this.tokenizer;
+ this.document.appendChild(doctype);
+};
+
+SAXTreeBuilder.prototype.createElement = function(namespaceURI, localName, attributes) {
+ var element = new Element(this.tokenizer, namespaceURI, localName, localName, attributes || []);
+ return element;
+};
+
+SAXTreeBuilder.prototype.insertComment = function(data, parent) {
+ if (!parent)
+ parent = this.currentStackItem();
+ var comment = new Comment(this.tokenizer, data);
+ parent.appendChild(comment);
+};
+
+SAXTreeBuilder.prototype.appendCharacters = function(parent, data) {
+ var text = new Characters(this.tokenizer, data);
+ parent.appendChild(text);
+};
+
+SAXTreeBuilder.prototype.insertText = function(data) {
+ if (this.redirectAttachToFosterParent && this.openElements.top.isFosterParenting()) {
+ var tableIndex = this.openElements.findIndex('table');
+ var tableItem = this.openElements.item(tableIndex);
+ var table = tableItem.node;
+ if (tableIndex === 0) {
+ return this.appendCharacters(table, data);
+ }
+ var text = new Characters(this.tokenizer, data);
+ var parent = table.parentNode;
+ if (parent) {
+ parent.insertBetween(text, table.previousSibling, table);
+ return;
+ }
+ var stackParent = this.openElements.item(tableIndex - 1).node;
+ stackParent.appendChild(text);
+ return;
+ }
+ this.appendCharacters(this.currentStackItem().node, data);
+};
+
+SAXTreeBuilder.prototype.attachNode = function(node, parent) {
+ parent.appendChild(node);
+};
+
+SAXTreeBuilder.prototype.attachNodeToFosterParent = function(child, table, stackParent) {
+ var parent = table.parentNode;
+ if (parent)
+ parent.insertBetween(child, table.previousSibling, table);
+ else
+ stackParent.appendChild(child);
+};
+
+SAXTreeBuilder.prototype.detachFromParent = function(element) {
+ element.detach();
+};
+
+SAXTreeBuilder.prototype.reparentChildren = function(oldParent, newParent) {
+ newParent.appendChildren(oldParent.firstChild);
+};
+
+SAXTreeBuilder.prototype.getFragment = function() {
+ var fragment = new DocumentFragment();
+ this.reparentChildren(this.openElements.rootNode, fragment);
+ return fragment;
+};
+
+function getAttribute(node, name) {
+ for (var i = 0; i < node.attributes.length; i++) {
+ var attribute = node.attributes[i];
+ if (attribute.nodeName === name)
+ return attribute.nodeValue;
+ }
+}
+
+SAXTreeBuilder.prototype.addAttributesToElement = function(element, attributes) {
+ for (var i = 0; i < attributes.length; i++) {
+ var attribute = attributes[i];
+ if (!getAttribute(element, attribute.nodeName))
+ element.attributes.push(attribute);
+ }
+};
+
+var NodeType = {
+ CDATA: 1,
+ CHARACTERS: 2,
+ COMMENT: 3,
+ DOCUMENT: 4,
+ DOCUMENT_FRAGMENT: 5,
+ DTD: 6,
+ ELEMENT: 7,
+ ENTITY: 8,
+ IGNORABLE_WHITESPACE: 9,
+ PROCESSING_INSTRUCTION: 10,
+ SKIPPED_ENTITY: 11
+};
+function Node(locator) {
+ if (!locator) {
+ this.columnNumber = -1;
+ this.lineNumber = -1;
+ } else {
+ this.columnNumber = locator.columnNumber;
+ this.lineNumber = locator.lineNumber;
+ }
+ this.parentNode = null;
+ this.nextSibling = null;
+ this.firstChild = null;
+}
+Node.prototype.visit = function(treeParser) {
+ throw new Error("Not Implemented");
+};
+Node.prototype.revisit = function(treeParser) {
+ return;
+};
+Node.prototype.detach = function() {
+ if (this.parentNode !== null) {
+ this.parentNode.removeChild(this);
+ this.parentNode = null;
+ }
+};
+
+Object.defineProperty(Node.prototype, 'previousSibling', {
+ get: function() {
+ var prev = null;
+ var next = this.parentNode.firstChild;
+ for(;;) {
+ if (this == next) {
+ return prev;
+ }
+ prev = next;
+ next = next.nextSibling;
+ }
+ }
+});
+
+
+function ParentNode(locator) {
+ Node.call(this, locator);
+ this.lastChild = null;
+ this._endLocator = null;
+}
+
+ParentNode.prototype = Object.create(Node.prototype);
+ParentNode.prototype.insertBefore = function(child, sibling) {
+ if (!sibling) {
+ return this.appendChild(child);
+ }
+ child.detach();
+ child.parentNode = this;
+ if (this.firstChild == sibling) {
+ child.nextSibling = sibling;
+ this.firstChild = child;
+ } else {
+ var prev = this.firstChild;
+ var next = this.firstChild.nextSibling;
+ while (next != sibling) {
+ prev = next;
+ next = next.nextSibling;
+ }
+ prev.nextSibling = child;
+ child.nextSibling = next;
+ }
+ return child;
+};
+
+ParentNode.prototype.insertBetween = function(child, prev, next) {
+ if (!next) {
+ return this.appendChild(child);
+ }
+ child.detach();
+ child.parentNode = this;
+ child.nextSibling = next;
+ if (!prev) {
+ firstChild = child;
+ } else {
+ prev.nextSibling = child;
+ }
+ return child;
+};
+ParentNode.prototype.appendChild = function(child) {
+ child.detach();
+ child.parentNode = this;
+ if (!this.firstChild) {
+ this.firstChild = child;
+ } else {
+ this.lastChild.nextSibling = child;
+ }
+ this.lastChild = child;
+ return child;
+};
+ParentNode.prototype.appendChildren = function(parent) {
+ var child = parent.firstChild;
+ if (!child) {
+ return;
+ }
+ var another = parent;
+ if (!this.firstChild) {
+ this.firstChild = child;
+ } else {
+ this.lastChild.nextSibling = child;
+ }
+ this.lastChild = another.lastChild;
+ do {
+ child.parentNode = this;
+ } while ((child = child.nextSibling));
+ another.firstChild = null;
+ another.lastChild = null;
+};
+ParentNode.prototype.removeChild = function(node) {
+ if (this.firstChild == node) {
+ this.firstChild = node.nextSibling;
+ if (this.lastChild == node) {
+ this.lastChild = null;
+ }
+ } else {
+ var prev = this.firstChild;
+ var next = this.firstChild.nextSibling;
+ while (next != node) {
+ prev = next;
+ next = next.nextSibling;
+ }
+ prev.nextSibling = node.nextSibling;
+ if (this.lastChild == node) {
+ this.lastChild = prev;
+ }
+ }
+ node.parentNode = null;
+ return node;
+};
+
+Object.defineProperty(ParentNode.prototype, 'endLocator', {
+ get: function() {
+ return this._endLocator;
+ },
+ set: function(endLocator) {
+ this._endLocator = {
+ lineNumber: endLocator.lineNumber,
+ columnNumber: endLocator.columnNumber
+ };
+ }
+});
+function Document (locator) {
+ ParentNode.call(this, locator);
+ this.nodeType = NodeType.DOCUMENT;
+}
+
+Document.prototype = Object.create(ParentNode.prototype);
+Document.prototype.visit = function(treeParser) {
+ treeParser.startDocument(this);
+};
+Document.prototype.revisit = function(treeParser) {
+ treeParser.endDocument(this.endLocator);
+};
+function DocumentFragment() {
+ ParentNode.call(this, new Locator());
+ this.nodeType = NodeType.DOCUMENT_FRAGMENT;
+}
+
+DocumentFragment.prototype = Object.create(ParentNode.prototype);
+DocumentFragment.prototype.visit = function(treeParser) {
+};
+function Element(locator, uri, localName, qName, atts, prefixMappings) {
+ ParentNode.call(this, locator);
+ this.uri = uri;
+ this.localName = localName;
+ this.qName = qName;
+ this.attributes = atts;
+ this.prefixMappings = prefixMappings;
+ this.nodeType = NodeType.ELEMENT;
+}
+
+Element.prototype = Object.create(ParentNode.prototype);
+Element.prototype.visit = function(treeParser) {
+ if (this.prefixMappings) {
+ for (var key in prefixMappings) {
+ var mapping = prefixMappings[key];
+ treeParser.startPrefixMapping(mapping.getPrefix(),
+ mapping.getUri(), this);
+ }
+ }
+ treeParser.startElement(this.uri, this.localName, this.qName, this.attributes, this);
+};
+Element.prototype.revisit = function(treeParser) {
+ treeParser.endElement(this.uri, this.localName, this.qName, this.endLocator);
+ if (this.prefixMappings) {
+ for (var key in prefixMappings) {
+ var mapping = prefixMappings[key];
+ treeParser.endPrefixMapping(mapping.getPrefix(), this.endLocator);
+ }
+ }
+};
+function Characters(locator, data){
+ Node.call(this, locator);
+ this.data = data;
+ this.nodeType = NodeType.CHARACTERS;
+}
+
+Characters.prototype = Object.create(Node.prototype);
+Characters.prototype.visit = function (treeParser) {
+ treeParser.characters(this.data, 0, this.data.length, this);
+};
+function IgnorableWhitespace(locator, data) {
+ Node.call(this, locator);
+ this.data = data;
+ this.nodeType = NodeType.IGNORABLE_WHITESPACE;
+}
+
+IgnorableWhitespace.prototype = Object.create(Node.prototype);
+IgnorableWhitespace.prototype.visit = function(treeParser) {
+ treeParser.ignorableWhitespace(this.data, 0, this.data.length, this);
+};
+function Comment(locator, data) {
+ Node.call(this, locator);
+ this.data = data;
+ this.nodeType = NodeType.COMMENT;
+}
+
+Comment.prototype = Object.create(Node.prototype);
+Comment.prototype.visit = function(treeParser) {
+ treeParser.comment(this.data, 0, this.data.length, this);
+};
+function CDATA(locator) {
+ ParentNode.call(this, locator);
+ this.nodeType = NodeType.CDATA;
+}
+
+CDATA.prototype = Object.create(ParentNode.prototype);
+CDATA.prototype.visit = function(treeParser) {
+ treeParser.startCDATA(this);
+};
+CDATA.prototype.revisit = function(treeParser) {
+ treeParser.endCDATA(this.endLocator);
+};
+function Entity(name) {
+ ParentNode.call(this);
+ this.name = name;
+ this.nodeType = NodeType.ENTITY;
+}
+
+Entity.prototype = Object.create(ParentNode.prototype);
+Entity.prototype.visit = function(treeParser) {
+ treeParser.startEntity(this.name, this);
+};
+Entity.prototype.revisit = function(treeParser) {
+ treeParser.endEntity(this.name);
+};
+
+function SkippedEntity(name) {
+ Node.call(this);
+ this.name = name;
+ this.nodeType = NodeType.SKIPPED_ENTITY;
+}
+
+SkippedEntity.prototype = Object.create(Node.prototype);
+SkippedEntity.prototype.visit = function(treeParser) {
+ treeParser.skippedEntity(this.name, this);
+};
+function ProcessingInstruction(target, data) {
+ Node.call(this);
+ this.target = target;
+ this.data = data;
+}
+
+ProcessingInstruction.prototype = Object.create(Node.prototype);
+ProcessingInstruction.prototype.visit = function(treeParser) {
+ treeParser.processingInstruction(this.target, this.data, this);
+};
+ProcessingInstruction.prototype.getNodeType = function() {
+ return NodeType.PROCESSING_INSTRUCTION;
+};
+function DTD(name, publicIdentifier, systemIdentifier) {
+ ParentNode.call(this);
+ this.name = name;
+ this.publicIdentifier = publicIdentifier;
+ this.systemIdentifier = systemIdentifier;
+ this.nodeType = NodeType.DTD;
+}
+
+DTD.prototype = Object.create(ParentNode.prototype);
+DTD.prototype.visit = function(treeParser) {
+ treeParser.startDTD(this.name, this.publicIdentifier, this.systemIdentifier, this);
+};
+DTD.prototype.revisit = function(treeParser) {
+ treeParser.endDTD();
+};
+
+exports.SAXTreeBuilder = SAXTreeBuilder;
+
+},
+{"../TreeBuilder":6,"util":20}],
+11:[function(_dereq_,module,exports){
+function TreeParser(contentHandler, lexicalHandler){
+ this.contentHandler;
+ this.lexicalHandler;
+ this.locatorDelegate;
+
+ if (!contentHandler) {
+ throw new IllegalArgumentException("contentHandler was null.");
+ }
+ this.contentHandler = contentHandler;
+ if (!lexicalHandler) {
+ this.lexicalHandler = new NullLexicalHandler();
+ } else {
+ this.lexicalHandler = lexicalHandler;
+ }
+}
+TreeParser.prototype.parse = function(node) {
+ this.contentHandler.documentLocator = this;
+ var current = node;
+ var next;
+ for (;;) {
+ current.visit(this);
+ if (next = current.firstChild) {
+ current = next;
+ continue;
+ }
+ for (;;) {
+ current.revisit(this);
+ if (current == node) {
+ return;
+ }
+ if (next = current.nextSibling) {
+ current = next;
+ break;
+ }
+ current = current.parentNode;
+ }
+ }
+};
+TreeParser.prototype.characters = function(ch, start, length, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.characters(ch, start, length);
+};
+TreeParser.prototype.endDocument = function(locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.endDocument();
+};
+TreeParser.prototype.endElement = function(uri, localName, qName, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.endElement(uri, localName, qName);
+};
+TreeParser.prototype.endPrefixMapping = function(prefix, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.endPrefixMapping(prefix);
+};
+TreeParser.prototype.ignorableWhitespace = function(ch, start, length, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.ignorableWhitespace(ch, start, length);
+};
+TreeParser.prototype.processingInstruction = function(target, data, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.processingInstruction(target, data);
+};
+TreeParser.prototype.skippedEntity = function(name, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.skippedEntity(name);
+};
+TreeParser.prototype.startDocument = function(locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.startDocument();
+};
+TreeParser.prototype.startElement = function(uri, localName, qName, atts, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.startElement(uri, localName, qName, atts);
+};
+TreeParser.prototype.startPrefixMapping = function(prefix, uri, locator) {
+ this.locatorDelegate = locator;
+ this.contentHandler.startPrefixMapping(prefix, uri);
+};
+TreeParser.prototype.comment = function(ch, start, length, locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.comment(ch, start, length);
+};
+TreeParser.prototype.endCDATA = function(locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.endCDATA();
+};
+TreeParser.prototype.endDTD = function(locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.endDTD();
+};
+TreeParser.prototype.endEntity = function(name, locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.endEntity(name);
+};
+TreeParser.prototype.startCDATA = function(locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.startCDATA();
+};
+TreeParser.prototype.startDTD = function(name, publicId, systemId, locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.startDTD(name, publicId, systemId);
+};
+TreeParser.prototype.startEntity = function(name, locator) {
+ this.locatorDelegate = locator;
+ this.lexicalHandler.startEntity(name);
+};
+
+Object.defineProperty(TreeParser.prototype, 'columnNumber', {
+ get: function() {
+ if (!this.locatorDelegate)
+ return -1;
+ else
+ return this.locatorDelegate.columnNumber;
+ }
+});
+
+Object.defineProperty(TreeParser.prototype, 'lineNumber', {
+ get: function() {
+ if (!this.locatorDelegate)
+ return -1;
+ else
+ return this.locatorDelegate.lineNumber;
+ }
+});
+function NullLexicalHandler() {
+
+}
+
+NullLexicalHandler.prototype.comment = function() {};
+NullLexicalHandler.prototype.endCDATA = function() {};
+NullLexicalHandler.prototype.endDTD = function() {};
+NullLexicalHandler.prototype.endEntity = function() {};
+NullLexicalHandler.prototype.startCDATA = function() {};
+NullLexicalHandler.prototype.startDTD = function() {};
+NullLexicalHandler.prototype.startEntity = function() {};
+
+exports.TreeParser = TreeParser;
+
+},
+{}],
+12:[function(_dereq_,module,exports){
+module.exports = {
+ "Aacute;": "\u00C1",
+ "Aacute": "\u00C1",
+ "aacute;": "\u00E1",
+ "aacute": "\u00E1",
+ "Abreve;": "\u0102",
+ "abreve;": "\u0103",
+ "ac;": "\u223E",
+ "acd;": "\u223F",
+ "acE;": "\u223E\u0333",
+ "Acirc;": "\u00C2",
+ "Acirc": "\u00C2",
+ "acirc;": "\u00E2",
+ "acirc": "\u00E2",
+ "acute;": "\u00B4",
+ "acute": "\u00B4",
+ "Acy;": "\u0410",
+ "acy;": "\u0430",
+ "AElig;": "\u00C6",
+ "AElig": "\u00C6",
+ "aelig;": "\u00E6",
+ "aelig": "\u00E6",
+ "af;": "\u2061",
+ "Afr;": "\uD835\uDD04",
+ "afr;": "\uD835\uDD1E",
+ "Agrave;": "\u00C0",
+ "Agrave": "\u00C0",
+ "agrave;": "\u00E0",
+ "agrave": "\u00E0",
+ "alefsym;": "\u2135",
+ "aleph;": "\u2135",
+ "Alpha;": "\u0391",
+ "alpha;": "\u03B1",
+ "Amacr;": "\u0100",
+ "amacr;": "\u0101",
+ "amalg;": "\u2A3F",
+ "amp;": "\u0026",
+ "amp": "\u0026",
+ "AMP;": "\u0026",
+ "AMP": "\u0026",
+ "andand;": "\u2A55",
+ "And;": "\u2A53",
+ "and;": "\u2227",
+ "andd;": "\u2A5C",
+ "andslope;": "\u2A58",
+ "andv;": "\u2A5A",
+ "ang;": "\u2220",
+ "ange;": "\u29A4",
+ "angle;": "\u2220",
+ "angmsdaa;": "\u29A8",
+ "angmsdab;": "\u29A9",
+ "angmsdac;": "\u29AA",
+ "angmsdad;": "\u29AB",
+ "angmsdae;": "\u29AC",
+ "angmsdaf;": "\u29AD",
+ "angmsdag;": "\u29AE",
+ "angmsdah;": "\u29AF",
+ "angmsd;": "\u2221",
+ "angrt;": "\u221F",
+ "angrtvb;": "\u22BE",
+ "angrtvbd;": "\u299D",
+ "angsph;": "\u2222",
+ "angst;": "\u00C5",
+ "angzarr;": "\u237C",
+ "Aogon;": "\u0104",
+ "aogon;": "\u0105",
+ "Aopf;": "\uD835\uDD38",
+ "aopf;": "\uD835\uDD52",
+ "apacir;": "\u2A6F",
+ "ap;": "\u2248",
+ "apE;": "\u2A70",
+ "ape;": "\u224A",
+ "apid;": "\u224B",
+ "apos;": "\u0027",
+ "ApplyFunction;": "\u2061",
+ "approx;": "\u2248",
+ "approxeq;": "\u224A",
+ "Aring;": "\u00C5",
+ "Aring": "\u00C5",
+ "aring;": "\u00E5",
+ "aring": "\u00E5",
+ "Ascr;": "\uD835\uDC9C",
+ "ascr;": "\uD835\uDCB6",
+ "Assign;": "\u2254",
+ "ast;": "\u002A",
+ "asymp;": "\u2248",
+ "asympeq;": "\u224D",
+ "Atilde;": "\u00C3",
+ "Atilde": "\u00C3",
+ "atilde;": "\u00E3",
+ "atilde": "\u00E3",
+ "Auml;": "\u00C4",
+ "Auml": "\u00C4",
+ "auml;": "\u00E4",
+ "auml": "\u00E4",
+ "awconint;": "\u2233",
+ "awint;": "\u2A11",
+ "backcong;": "\u224C",
+ "backepsilon;": "\u03F6",
+ "backprime;": "\u2035",
+ "backsim;": "\u223D",
+ "backsimeq;": "\u22CD",
+ "Backslash;": "\u2216",
+ "Barv;": "\u2AE7",
+ "barvee;": "\u22BD",
+ "barwed;": "\u2305",
+ "Barwed;": "\u2306",
+ "barwedge;": "\u2305",
+ "bbrk;": "\u23B5",
+ "bbrktbrk;": "\u23B6",
+ "bcong;": "\u224C",
+ "Bcy;": "\u0411",
+ "bcy;": "\u0431",
+ "bdquo;": "\u201E",
+ "becaus;": "\u2235",
+ "because;": "\u2235",
+ "Because;": "\u2235",
+ "bemptyv;": "\u29B0",
+ "bepsi;": "\u03F6",
+ "bernou;": "\u212C",
+ "Bernoullis;": "\u212C",
+ "Beta;": "\u0392",
+ "beta;": "\u03B2",
+ "beth;": "\u2136",
+ "between;": "\u226C",
+ "Bfr;": "\uD835\uDD05",
+ "bfr;": "\uD835\uDD1F",
+ "bigcap;": "\u22C2",
+ "bigcirc;": "\u25EF",
+ "bigcup;": "\u22C3",
+ "bigodot;": "\u2A00",
+ "bigoplus;": "\u2A01",
+ "bigotimes;": "\u2A02",
+ "bigsqcup;": "\u2A06",
+ "bigstar;": "\u2605",
+ "bigtriangledown;": "\u25BD",
+ "bigtriangleup;": "\u25B3",
+ "biguplus;": "\u2A04",
+ "bigvee;": "\u22C1",
+ "bigwedge;": "\u22C0",
+ "bkarow;": "\u290D",
+ "blacklozenge;": "\u29EB",
+ "blacksquare;": "\u25AA",
+ "blacktriangle;": "\u25B4",
+ "blacktriangledown;": "\u25BE",
+ "blacktriangleleft;": "\u25C2",
+ "blacktriangleright;": "\u25B8",
+ "blank;": "\u2423",
+ "blk12;": "\u2592",
+ "blk14;": "\u2591",
+ "blk34;": "\u2593",
+ "block;": "\u2588",
+ "bne;": "\u003D\u20E5",
+ "bnequiv;": "\u2261\u20E5",
+ "bNot;": "\u2AED",
+ "bnot;": "\u2310",
+ "Bopf;": "\uD835\uDD39",
+ "bopf;": "\uD835\uDD53",
+ "bot;": "\u22A5",
+ "bottom;": "\u22A5",
+ "bowtie;": "\u22C8",
+ "boxbox;": "\u29C9",
+ "boxdl;": "\u2510",
+ "boxdL;": "\u2555",
+ "boxDl;": "\u2556",
+ "boxDL;": "\u2557",
+ "boxdr;": "\u250C",
+ "boxdR;": "\u2552",
+ "boxDr;": "\u2553",
+ "boxDR;": "\u2554",
+ "boxh;": "\u2500",
+ "boxH;": "\u2550",
+ "boxhd;": "\u252C",
+ "boxHd;": "\u2564",
+ "boxhD;": "\u2565",
+ "boxHD;": "\u2566",
+ "boxhu;": "\u2534",
+ "boxHu;": "\u2567",
+ "boxhU;": "\u2568",
+ "boxHU;": "\u2569",
+ "boxminus;": "\u229F",
+ "boxplus;": "\u229E",
+ "boxtimes;": "\u22A0",
+ "boxul;": "\u2518",
+ "boxuL;": "\u255B",
+ "boxUl;": "\u255C",
+ "boxUL;": "\u255D",
+ "boxur;": "\u2514",
+ "boxuR;": "\u2558",
+ "boxUr;": "\u2559",
+ "boxUR;": "\u255A",
+ "boxv;": "\u2502",
+ "boxV;": "\u2551",
+ "boxvh;": "\u253C",
+ "boxvH;": "\u256A",
+ "boxVh;": "\u256B",
+ "boxVH;": "\u256C",
+ "boxvl;": "\u2524",
+ "boxvL;": "\u2561",
+ "boxVl;": "\u2562",
+ "boxVL;": "\u2563",
+ "boxvr;": "\u251C",
+ "boxvR;": "\u255E",
+ "boxVr;": "\u255F",
+ "boxVR;": "\u2560",
+ "bprime;": "\u2035",
+ "breve;": "\u02D8",
+ "Breve;": "\u02D8",
+ "brvbar;": "\u00A6",
+ "brvbar": "\u00A6",
+ "bscr;": "\uD835\uDCB7",
+ "Bscr;": "\u212C",
+ "bsemi;": "\u204F",
+ "bsim;": "\u223D",
+ "bsime;": "\u22CD",
+ "bsolb;": "\u29C5",
+ "bsol;": "\u005C",
+ "bsolhsub;": "\u27C8",
+ "bull;": "\u2022",
+ "bullet;": "\u2022",
+ "bump;": "\u224E",
+ "bumpE;": "\u2AAE",
+ "bumpe;": "\u224F",
+ "Bumpeq;": "\u224E",
+ "bumpeq;": "\u224F",
+ "Cacute;": "\u0106",
+ "cacute;": "\u0107",
+ "capand;": "\u2A44",
+ "capbrcup;": "\u2A49",
+ "capcap;": "\u2A4B",
+ "cap;": "\u2229",
+ "Cap;": "\u22D2",
+ "capcup;": "\u2A47",
+ "capdot;": "\u2A40",
+ "CapitalDifferentialD;": "\u2145",
+ "caps;": "\u2229\uFE00",
+ "caret;": "\u2041",
+ "caron;": "\u02C7",
+ "Cayleys;": "\u212D",
+ "ccaps;": "\u2A4D",
+ "Ccaron;": "\u010C",
+ "ccaron;": "\u010D",
+ "Ccedil;": "\u00C7",
+ "Ccedil": "\u00C7",
+ "ccedil;": "\u00E7",
+ "ccedil": "\u00E7",
+ "Ccirc;": "\u0108",
+ "ccirc;": "\u0109",
+ "Cconint;": "\u2230",
+ "ccups;": "\u2A4C",
+ "ccupssm;": "\u2A50",
+ "Cdot;": "\u010A",
+ "cdot;": "\u010B",
+ "cedil;": "\u00B8",
+ "cedil": "\u00B8",
+ "Cedilla;": "\u00B8",
+ "cemptyv;": "\u29B2",
+ "cent;": "\u00A2",
+ "cent": "\u00A2",
+ "centerdot;": "\u00B7",
+ "CenterDot;": "\u00B7",
+ "cfr;": "\uD835\uDD20",
+ "Cfr;": "\u212D",
+ "CHcy;": "\u0427",
+ "chcy;": "\u0447",
+ "check;": "\u2713",
+ "checkmark;": "\u2713",
+ "Chi;": "\u03A7",
+ "chi;": "\u03C7",
+ "circ;": "\u02C6",
+ "circeq;": "\u2257",
+ "circlearrowleft;": "\u21BA",
+ "circlearrowright;": "\u21BB",
+ "circledast;": "\u229B",
+ "circledcirc;": "\u229A",
+ "circleddash;": "\u229D",
+ "CircleDot;": "\u2299",
+ "circledR;": "\u00AE",
+ "circledS;": "\u24C8",
+ "CircleMinus;": "\u2296",
+ "CirclePlus;": "\u2295",
+ "CircleTimes;": "\u2297",
+ "cir;": "\u25CB",
+ "cirE;": "\u29C3",
+ "cire;": "\u2257",
+ "cirfnint;": "\u2A10",
+ "cirmid;": "\u2AEF",
+ "cirscir;": "\u29C2",
+ "ClockwiseContourIntegral;": "\u2232",
+ "CloseCurlyDoubleQuote;": "\u201D",
+ "CloseCurlyQuote;": "\u2019",
+ "clubs;": "\u2663",
+ "clubsuit;": "\u2663",
+ "colon;": "\u003A",
+ "Colon;": "\u2237",
+ "Colone;": "\u2A74",
+ "colone;": "\u2254",
+ "coloneq;": "\u2254",
+ "comma;": "\u002C",
+ "commat;": "\u0040",
+ "comp;": "\u2201",
+ "compfn;": "\u2218",
+ "complement;": "\u2201",
+ "complexes;": "\u2102",
+ "cong;": "\u2245",
+ "congdot;": "\u2A6D",
+ "Congruent;": "\u2261",
+ "conint;": "\u222E",
+ "Conint;": "\u222F",
+ "ContourIntegral;": "\u222E",
+ "copf;": "\uD835\uDD54",
+ "Copf;": "\u2102",
+ "coprod;": "\u2210",
+ "Coproduct;": "\u2210",
+ "copy;": "\u00A9",
+ "copy": "\u00A9",
+ "COPY;": "\u00A9",
+ "COPY": "\u00A9",
+ "copysr;": "\u2117",
+ "CounterClockwiseContourIntegral;": "\u2233",
+ "crarr;": "\u21B5",
+ "cross;": "\u2717",
+ "Cross;": "\u2A2F",
+ "Cscr;": "\uD835\uDC9E",
+ "cscr;": "\uD835\uDCB8",
+ "csub;": "\u2ACF",
+ "csube;": "\u2AD1",
+ "csup;": "\u2AD0",
+ "csupe;": "\u2AD2",
+ "ctdot;": "\u22EF",
+ "cudarrl;": "\u2938",
+ "cudarrr;": "\u2935",
+ "cuepr;": "\u22DE",
+ "cuesc;": "\u22DF",
+ "cularr;": "\u21B6",
+ "cularrp;": "\u293D",
+ "cupbrcap;": "\u2A48",
+ "cupcap;": "\u2A46",
+ "CupCap;": "\u224D",
+ "cup;": "\u222A",
+ "Cup;": "\u22D3",
+ "cupcup;": "\u2A4A",
+ "cupdot;": "\u228D",
+ "cupor;": "\u2A45",
+ "cups;": "\u222A\uFE00",
+ "curarr;": "\u21B7",
+ "curarrm;": "\u293C",
+ "curlyeqprec;": "\u22DE",
+ "curlyeqsucc;": "\u22DF",
+ "curlyvee;": "\u22CE",
+ "curlywedge;": "\u22CF",
+ "curren;": "\u00A4",
+ "curren": "\u00A4",
+ "curvearrowleft;": "\u21B6",
+ "curvearrowright;": "\u21B7",
+ "cuvee;": "\u22CE",
+ "cuwed;": "\u22CF",
+ "cwconint;": "\u2232",
+ "cwint;": "\u2231",
+ "cylcty;": "\u232D",
+ "dagger;": "\u2020",
+ "Dagger;": "\u2021",
+ "daleth;": "\u2138",
+ "darr;": "\u2193",
+ "Darr;": "\u21A1",
+ "dArr;": "\u21D3",
+ "dash;": "\u2010",
+ "Dashv;": "\u2AE4",
+ "dashv;": "\u22A3",
+ "dbkarow;": "\u290F",
+ "dblac;": "\u02DD",
+ "Dcaron;": "\u010E",
+ "dcaron;": "\u010F",
+ "Dcy;": "\u0414",
+ "dcy;": "\u0434",
+ "ddagger;": "\u2021",
+ "ddarr;": "\u21CA",
+ "DD;": "\u2145",
+ "dd;": "\u2146",
+ "DDotrahd;": "\u2911",
+ "ddotseq;": "\u2A77",
+ "deg;": "\u00B0",
+ "deg": "\u00B0",
+ "Del;": "\u2207",
+ "Delta;": "\u0394",
+ "delta;": "\u03B4",
+ "demptyv;": "\u29B1",
+ "dfisht;": "\u297F",
+ "Dfr;": "\uD835\uDD07",
+ "dfr;": "\uD835\uDD21",
+ "dHar;": "\u2965",
+ "dharl;": "\u21C3",
+ "dharr;": "\u21C2",
+ "DiacriticalAcute;": "\u00B4",
+ "DiacriticalDot;": "\u02D9",
+ "DiacriticalDoubleAcute;": "\u02DD",
+ "DiacriticalGrave;": "\u0060",
+ "DiacriticalTilde;": "\u02DC",
+ "diam;": "\u22C4",
+ "diamond;": "\u22C4",
+ "Diamond;": "\u22C4",
+ "diamondsuit;": "\u2666",
+ "diams;": "\u2666",
+ "die;": "\u00A8",
+ "DifferentialD;": "\u2146",
+ "digamma;": "\u03DD",
+ "disin;": "\u22F2",
+ "div;": "\u00F7",
+ "divide;": "\u00F7",
+ "divide": "\u00F7",
+ "divideontimes;": "\u22C7",
+ "divonx;": "\u22C7",
+ "DJcy;": "\u0402",
+ "djcy;": "\u0452",
+ "dlcorn;": "\u231E",
+ "dlcrop;": "\u230D",
+ "dollar;": "\u0024",
+ "Dopf;": "\uD835\uDD3B",
+ "dopf;": "\uD835\uDD55",
+ "Dot;": "\u00A8",
+ "dot;": "\u02D9",
+ "DotDot;": "\u20DC",
+ "doteq;": "\u2250",
+ "doteqdot;": "\u2251",
+ "DotEqual;": "\u2250",
+ "dotminus;": "\u2238",
+ "dotplus;": "\u2214",
+ "dotsquare;": "\u22A1",
+ "doublebarwedge;": "\u2306",
+ "DoubleContourIntegral;": "\u222F",
+ "DoubleDot;": "\u00A8",
+ "DoubleDownArrow;": "\u21D3",
+ "DoubleLeftArrow;": "\u21D0",
+ "DoubleLeftRightArrow;": "\u21D4",
+ "DoubleLeftTee;": "\u2AE4",
+ "DoubleLongLeftArrow;": "\u27F8",
+ "DoubleLongLeftRightArrow;": "\u27FA",
+ "DoubleLongRightArrow;": "\u27F9",
+ "DoubleRightArrow;": "\u21D2",
+ "DoubleRightTee;": "\u22A8",
+ "DoubleUpArrow;": "\u21D1",
+ "DoubleUpDownArrow;": "\u21D5",
+ "DoubleVerticalBar;": "\u2225",
+ "DownArrowBar;": "\u2913",
+ "downarrow;": "\u2193",
+ "DownArrow;": "\u2193",
+ "Downarrow;": "\u21D3",
+ "DownArrowUpArrow;": "\u21F5",
+ "DownBreve;": "\u0311",
+ "downdownarrows;": "\u21CA",
+ "downharpoonleft;": "\u21C3",
+ "downharpoonright;": "\u21C2",
+ "DownLeftRightVector;": "\u2950",
+ "DownLeftTeeVector;": "\u295E",
+ "DownLeftVectorBar;": "\u2956",
+ "DownLeftVector;": "\u21BD",
+ "DownRightTeeVector;": "\u295F",
+ "DownRightVectorBar;": "\u2957",
+ "DownRightVector;": "\u21C1",
+ "DownTeeArrow;": "\u21A7",
+ "DownTee;": "\u22A4",
+ "drbkarow;": "\u2910",
+ "drcorn;": "\u231F",
+ "drcrop;": "\u230C",
+ "Dscr;": "\uD835\uDC9F",
+ "dscr;": "\uD835\uDCB9",
+ "DScy;": "\u0405",
+ "dscy;": "\u0455",
+ "dsol;": "\u29F6",
+ "Dstrok;": "\u0110",
+ "dstrok;": "\u0111",
+ "dtdot;": "\u22F1",
+ "dtri;": "\u25BF",
+ "dtrif;": "\u25BE",
+ "duarr;": "\u21F5",
+ "duhar;": "\u296F",
+ "dwangle;": "\u29A6",
+ "DZcy;": "\u040F",
+ "dzcy;": "\u045F",
+ "dzigrarr;": "\u27FF",
+ "Eacute;": "\u00C9",
+ "Eacute": "\u00C9",
+ "eacute;": "\u00E9",
+ "eacute": "\u00E9",
+ "easter;": "\u2A6E",
+ "Ecaron;": "\u011A",
+ "ecaron;": "\u011B",
+ "Ecirc;": "\u00CA",
+ "Ecirc": "\u00CA",
+ "ecirc;": "\u00EA",
+ "ecirc": "\u00EA",
+ "ecir;": "\u2256",
+ "ecolon;": "\u2255",
+ "Ecy;": "\u042D",
+ "ecy;": "\u044D",
+ "eDDot;": "\u2A77",
+ "Edot;": "\u0116",
+ "edot;": "\u0117",
+ "eDot;": "\u2251",
+ "ee;": "\u2147",
+ "efDot;": "\u2252",
+ "Efr;": "\uD835\uDD08",
+ "efr;": "\uD835\uDD22",
+ "eg;": "\u2A9A",
+ "Egrave;": "\u00C8",
+ "Egrave": "\u00C8",
+ "egrave;": "\u00E8",
+ "egrave": "\u00E8",
+ "egs;": "\u2A96",
+ "egsdot;": "\u2A98",
+ "el;": "\u2A99",
+ "Element;": "\u2208",
+ "elinters;": "\u23E7",
+ "ell;": "\u2113",
+ "els;": "\u2A95",
+ "elsdot;": "\u2A97",
+ "Emacr;": "\u0112",
+ "emacr;": "\u0113",
+ "empty;": "\u2205",
+ "emptyset;": "\u2205",
+ "EmptySmallSquare;": "\u25FB",
+ "emptyv;": "\u2205",
+ "EmptyVerySmallSquare;": "\u25AB",
+ "emsp13;": "\u2004",
+ "emsp14;": "\u2005",
+ "emsp;": "\u2003",
+ "ENG;": "\u014A",
+ "eng;": "\u014B",
+ "ensp;": "\u2002",
+ "Eogon;": "\u0118",
+ "eogon;": "\u0119",
+ "Eopf;": "\uD835\uDD3C",
+ "eopf;": "\uD835\uDD56",
+ "epar;": "\u22D5",
+ "eparsl;": "\u29E3",
+ "eplus;": "\u2A71",
+ "epsi;": "\u03B5",
+ "Epsilon;": "\u0395",
+ "epsilon;": "\u03B5",
+ "epsiv;": "\u03F5",
+ "eqcirc;": "\u2256",
+ "eqcolon;": "\u2255",
+ "eqsim;": "\u2242",
+ "eqslantgtr;": "\u2A96",
+ "eqslantless;": "\u2A95",
+ "Equal;": "\u2A75",
+ "equals;": "\u003D",
+ "EqualTilde;": "\u2242",
+ "equest;": "\u225F",
+ "Equilibrium;": "\u21CC",
+ "equiv;": "\u2261",
+ "equivDD;": "\u2A78",
+ "eqvparsl;": "\u29E5",
+ "erarr;": "\u2971",
+ "erDot;": "\u2253",
+ "escr;": "\u212F",
+ "Escr;": "\u2130",
+ "esdot;": "\u2250",
+ "Esim;": "\u2A73",
+ "esim;": "\u2242",
+ "Eta;": "\u0397",
+ "eta;": "\u03B7",
+ "ETH;": "\u00D0",
+ "ETH": "\u00D0",
+ "eth;": "\u00F0",
+ "eth": "\u00F0",
+ "Euml;": "\u00CB",
+ "Euml": "\u00CB",
+ "euml;": "\u00EB",
+ "euml": "\u00EB",
+ "euro;": "\u20AC",
+ "excl;": "\u0021",
+ "exist;": "\u2203",
+ "Exists;": "\u2203",
+ "expectation;": "\u2130",
+ "exponentiale;": "\u2147",
+ "ExponentialE;": "\u2147",
+ "fallingdotseq;": "\u2252",
+ "Fcy;": "\u0424",
+ "fcy;": "\u0444",
+ "female;": "\u2640",
+ "ffilig;": "\uFB03",
+ "fflig;": "\uFB00",
+ "ffllig;": "\uFB04",
+ "Ffr;": "\uD835\uDD09",
+ "ffr;": "\uD835\uDD23",
+ "filig;": "\uFB01",
+ "FilledSmallSquare;": "\u25FC",
+ "FilledVerySmallSquare;": "\u25AA",
+ "fjlig;": "\u0066\u006A",
+ "flat;": "\u266D",
+ "fllig;": "\uFB02",
+ "fltns;": "\u25B1",
+ "fnof;": "\u0192",
+ "Fopf;": "\uD835\uDD3D",
+ "fopf;": "\uD835\uDD57",
+ "forall;": "\u2200",
+ "ForAll;": "\u2200",
+ "fork;": "\u22D4",
+ "forkv;": "\u2AD9",
+ "Fouriertrf;": "\u2131",
+ "fpartint;": "\u2A0D",
+ "frac12;": "\u00BD",
+ "frac12": "\u00BD",
+ "frac13;": "\u2153",
+ "frac14;": "\u00BC",
+ "frac14": "\u00BC",
+ "frac15;": "\u2155",
+ "frac16;": "\u2159",
+ "frac18;": "\u215B",
+ "frac23;": "\u2154",
+ "frac25;": "\u2156",
+ "frac34;": "\u00BE",
+ "frac34": "\u00BE",
+ "frac35;": "\u2157",
+ "frac38;": "\u215C",
+ "frac45;": "\u2158",
+ "frac56;": "\u215A",
+ "frac58;": "\u215D",
+ "frac78;": "\u215E",
+ "frasl;": "\u2044",
+ "frown;": "\u2322",
+ "fscr;": "\uD835\uDCBB",
+ "Fscr;": "\u2131",
+ "gacute;": "\u01F5",
+ "Gamma;": "\u0393",
+ "gamma;": "\u03B3",
+ "Gammad;": "\u03DC",
+ "gammad;": "\u03DD",
+ "gap;": "\u2A86",
+ "Gbreve;": "\u011E",
+ "gbreve;": "\u011F",
+ "Gcedil;": "\u0122",
+ "Gcirc;": "\u011C",
+ "gcirc;": "\u011D",
+ "Gcy;": "\u0413",
+ "gcy;": "\u0433",
+ "Gdot;": "\u0120",
+ "gdot;": "\u0121",
+ "ge;": "\u2265",
+ "gE;": "\u2267",
+ "gEl;": "\u2A8C",
+ "gel;": "\u22DB",
+ "geq;": "\u2265",
+ "geqq;": "\u2267",
+ "geqslant;": "\u2A7E",
+ "gescc;": "\u2AA9",
+ "ges;": "\u2A7E",
+ "gesdot;": "\u2A80",
+ "gesdoto;": "\u2A82",
+ "gesdotol;": "\u2A84",
+ "gesl;": "\u22DB\uFE00",
+ "gesles;": "\u2A94",
+ "Gfr;": "\uD835\uDD0A",
+ "gfr;": "\uD835\uDD24",
+ "gg;": "\u226B",
+ "Gg;": "\u22D9",
+ "ggg;": "\u22D9",
+ "gimel;": "\u2137",
+ "GJcy;": "\u0403",
+ "gjcy;": "\u0453",
+ "gla;": "\u2AA5",
+ "gl;": "\u2277",
+ "glE;": "\u2A92",
+ "glj;": "\u2AA4",
+ "gnap;": "\u2A8A",
+ "gnapprox;": "\u2A8A",
+ "gne;": "\u2A88",
+ "gnE;": "\u2269",
+ "gneq;": "\u2A88",
+ "gneqq;": "\u2269",
+ "gnsim;": "\u22E7",
+ "Gopf;": "\uD835\uDD3E",
+ "gopf;": "\uD835\uDD58",
+ "grave;": "\u0060",
+ "GreaterEqual;": "\u2265",
+ "GreaterEqualLess;": "\u22DB",
+ "GreaterFullEqual;": "\u2267",
+ "GreaterGreater;": "\u2AA2",
+ "GreaterLess;": "\u2277",
+ "GreaterSlantEqual;": "\u2A7E",
+ "GreaterTilde;": "\u2273",
+ "Gscr;": "\uD835\uDCA2",
+ "gscr;": "\u210A",
+ "gsim;": "\u2273",
+ "gsime;": "\u2A8E",
+ "gsiml;": "\u2A90",
+ "gtcc;": "\u2AA7",
+ "gtcir;": "\u2A7A",
+ "gt;": "\u003E",
+ "gt": "\u003E",
+ "GT;": "\u003E",
+ "GT": "\u003E",
+ "Gt;": "\u226B",
+ "gtdot;": "\u22D7",
+ "gtlPar;": "\u2995",
+ "gtquest;": "\u2A7C",
+ "gtrapprox;": "\u2A86",
+ "gtrarr;": "\u2978",
+ "gtrdot;": "\u22D7",
+ "gtreqless;": "\u22DB",
+ "gtreqqless;": "\u2A8C",
+ "gtrless;": "\u2277",
+ "gtrsim;": "\u2273",
+ "gvertneqq;": "\u2269\uFE00",
+ "gvnE;": "\u2269\uFE00",
+ "Hacek;": "\u02C7",
+ "hairsp;": "\u200A",
+ "half;": "\u00BD",
+ "hamilt;": "\u210B",
+ "HARDcy;": "\u042A",
+ "hardcy;": "\u044A",
+ "harrcir;": "\u2948",
+ "harr;": "\u2194",
+ "hArr;": "\u21D4",
+ "harrw;": "\u21AD",
+ "Hat;": "\u005E",
+ "hbar;": "\u210F",
+ "Hcirc;": "\u0124",
+ "hcirc;": "\u0125",
+ "hearts;": "\u2665",
+ "heartsuit;": "\u2665",
+ "hellip;": "\u2026",
+ "hercon;": "\u22B9",
+ "hfr;": "\uD835\uDD25",
+ "Hfr;": "\u210C",
+ "HilbertSpace;": "\u210B",
+ "hksearow;": "\u2925",
+ "hkswarow;": "\u2926",
+ "hoarr;": "\u21FF",
+ "homtht;": "\u223B",
+ "hookleftarrow;": "\u21A9",
+ "hookrightarrow;": "\u21AA",
+ "hopf;": "\uD835\uDD59",
+ "Hopf;": "\u210D",
+ "horbar;": "\u2015",
+ "HorizontalLine;": "\u2500",
+ "hscr;": "\uD835\uDCBD",
+ "Hscr;": "\u210B",
+ "hslash;": "\u210F",
+ "Hstrok;": "\u0126",
+ "hstrok;": "\u0127",
+ "HumpDownHump;": "\u224E",
+ "HumpEqual;": "\u224F",
+ "hybull;": "\u2043",
+ "hyphen;": "\u2010",
+ "Iacute;": "\u00CD",
+ "Iacute": "\u00CD",
+ "iacute;": "\u00ED",
+ "iacute": "\u00ED",
+ "ic;": "\u2063",
+ "Icirc;": "\u00CE",
+ "Icirc": "\u00CE",
+ "icirc;": "\u00EE",
+ "icirc": "\u00EE",
+ "Icy;": "\u0418",
+ "icy;": "\u0438",
+ "Idot;": "\u0130",
+ "IEcy;": "\u0415",
+ "iecy;": "\u0435",
+ "iexcl;": "\u00A1",
+ "iexcl": "\u00A1",
+ "iff;": "\u21D4",
+ "ifr;": "\uD835\uDD26",
+ "Ifr;": "\u2111",
+ "Igrave;": "\u00CC",
+ "Igrave": "\u00CC",
+ "igrave;": "\u00EC",
+ "igrave": "\u00EC",
+ "ii;": "\u2148",
+ "iiiint;": "\u2A0C",
+ "iiint;": "\u222D",
+ "iinfin;": "\u29DC",
+ "iiota;": "\u2129",
+ "IJlig;": "\u0132",
+ "ijlig;": "\u0133",
+ "Imacr;": "\u012A",
+ "imacr;": "\u012B",
+ "image;": "\u2111",
+ "ImaginaryI;": "\u2148",
+ "imagline;": "\u2110",
+ "imagpart;": "\u2111",
+ "imath;": "\u0131",
+ "Im;": "\u2111",
+ "imof;": "\u22B7",
+ "imped;": "\u01B5",
+ "Implies;": "\u21D2",
+ "incare;": "\u2105",
+ "in;": "\u2208",
+ "infin;": "\u221E",
+ "infintie;": "\u29DD",
+ "inodot;": "\u0131",
+ "intcal;": "\u22BA",
+ "int;": "\u222B",
+ "Int;": "\u222C",
+ "integers;": "\u2124",
+ "Integral;": "\u222B",
+ "intercal;": "\u22BA",
+ "Intersection;": "\u22C2",
+ "intlarhk;": "\u2A17",
+ "intprod;": "\u2A3C",
+ "InvisibleComma;": "\u2063",
+ "InvisibleTimes;": "\u2062",
+ "IOcy;": "\u0401",
+ "iocy;": "\u0451",
+ "Iogon;": "\u012E",
+ "iogon;": "\u012F",
+ "Iopf;": "\uD835\uDD40",
+ "iopf;": "\uD835\uDD5A",
+ "Iota;": "\u0399",
+ "iota;": "\u03B9",
+ "iprod;": "\u2A3C",
+ "iquest;": "\u00BF",
+ "iquest": "\u00BF",
+ "iscr;": "\uD835\uDCBE",
+ "Iscr;": "\u2110",
+ "isin;": "\u2208",
+ "isindot;": "\u22F5",
+ "isinE;": "\u22F9",
+ "isins;": "\u22F4",
+ "isinsv;": "\u22F3",
+ "isinv;": "\u2208",
+ "it;": "\u2062",
+ "Itilde;": "\u0128",
+ "itilde;": "\u0129",
+ "Iukcy;": "\u0406",
+ "iukcy;": "\u0456",
+ "Iuml;": "\u00CF",
+ "Iuml": "\u00CF",
+ "iuml;": "\u00EF",
+ "iuml": "\u00EF",
+ "Jcirc;": "\u0134",
+ "jcirc;": "\u0135",
+ "Jcy;": "\u0419",
+ "jcy;": "\u0439",
+ "Jfr;": "\uD835\uDD0D",
+ "jfr;": "\uD835\uDD27",
+ "jmath;": "\u0237",
+ "Jopf;": "\uD835\uDD41",
+ "jopf;": "\uD835\uDD5B",
+ "Jscr;": "\uD835\uDCA5",
+ "jscr;": "\uD835\uDCBF",
+ "Jsercy;": "\u0408",
+ "jsercy;": "\u0458",
+ "Jukcy;": "\u0404",
+ "jukcy;": "\u0454",
+ "Kappa;": "\u039A",
+ "kappa;": "\u03BA",
+ "kappav;": "\u03F0",
+ "Kcedil;": "\u0136",
+ "kcedil;": "\u0137",
+ "Kcy;": "\u041A",
+ "kcy;": "\u043A",
+ "Kfr;": "\uD835\uDD0E",
+ "kfr;": "\uD835\uDD28",
+ "kgreen;": "\u0138",
+ "KHcy;": "\u0425",
+ "khcy;": "\u0445",
+ "KJcy;": "\u040C",
+ "kjcy;": "\u045C",
+ "Kopf;": "\uD835\uDD42",
+ "kopf;": "\uD835\uDD5C",
+ "Kscr;": "\uD835\uDCA6",
+ "kscr;": "\uD835\uDCC0",
+ "lAarr;": "\u21DA",
+ "Lacute;": "\u0139",
+ "lacute;": "\u013A",
+ "laemptyv;": "\u29B4",
+ "lagran;": "\u2112",
+ "Lambda;": "\u039B",
+ "lambda;": "\u03BB",
+ "lang;": "\u27E8",
+ "Lang;": "\u27EA",
+ "langd;": "\u2991",
+ "langle;": "\u27E8",
+ "lap;": "\u2A85",
+ "Laplacetrf;": "\u2112",
+ "laquo;": "\u00AB",
+ "laquo": "\u00AB",
+ "larrb;": "\u21E4",
+ "larrbfs;": "\u291F",
+ "larr;": "\u2190",
+ "Larr;": "\u219E",
+ "lArr;": "\u21D0",
+ "larrfs;": "\u291D",
+ "larrhk;": "\u21A9",
+ "larrlp;": "\u21AB",
+ "larrpl;": "\u2939",
+ "larrsim;": "\u2973",
+ "larrtl;": "\u21A2",
+ "latail;": "\u2919",
+ "lAtail;": "\u291B",
+ "lat;": "\u2AAB",
+ "late;": "\u2AAD",
+ "lates;": "\u2AAD\uFE00",
+ "lbarr;": "\u290C",
+ "lBarr;": "\u290E",
+ "lbbrk;": "\u2772",
+ "lbrace;": "\u007B",
+ "lbrack;": "\u005B",
+ "lbrke;": "\u298B",
+ "lbrksld;": "\u298F",
+ "lbrkslu;": "\u298D",
+ "Lcaron;": "\u013D",
+ "lcaron;": "\u013E",
+ "Lcedil;": "\u013B",
+ "lcedil;": "\u013C",
+ "lceil;": "\u2308",
+ "lcub;": "\u007B",
+ "Lcy;": "\u041B",
+ "lcy;": "\u043B",
+ "ldca;": "\u2936",
+ "ldquo;": "\u201C",
+ "ldquor;": "\u201E",
+ "ldrdhar;": "\u2967",
+ "ldrushar;": "\u294B",
+ "ldsh;": "\u21B2",
+ "le;": "\u2264",
+ "lE;": "\u2266",
+ "LeftAngleBracket;": "\u27E8",
+ "LeftArrowBar;": "\u21E4",
+ "leftarrow;": "\u2190",
+ "LeftArrow;": "\u2190",
+ "Leftarrow;": "\u21D0",
+ "LeftArrowRightArrow;": "\u21C6",
+ "leftarrowtail;": "\u21A2",
+ "LeftCeiling;": "\u2308",
+ "LeftDoubleBracket;": "\u27E6",
+ "LeftDownTeeVector;": "\u2961",
+ "LeftDownVectorBar;": "\u2959",
+ "LeftDownVector;": "\u21C3",
+ "LeftFloor;": "\u230A",
+ "leftharpoondown;": "\u21BD",
+ "leftharpoonup;": "\u21BC",
+ "leftleftarrows;": "\u21C7",
+ "leftrightarrow;": "\u2194",
+ "LeftRightArrow;": "\u2194",
+ "Leftrightarrow;": "\u21D4",
+ "leftrightarrows;": "\u21C6",
+ "leftrightharpoons;": "\u21CB",
+ "leftrightsquigarrow;": "\u21AD",
+ "LeftRightVector;": "\u294E",
+ "LeftTeeArrow;": "\u21A4",
+ "LeftTee;": "\u22A3",
+ "LeftTeeVector;": "\u295A",
+ "leftthreetimes;": "\u22CB",
+ "LeftTriangleBar;": "\u29CF",
+ "LeftTriangle;": "\u22B2",
+ "LeftTriangleEqual;": "\u22B4",
+ "LeftUpDownVector;": "\u2951",
+ "LeftUpTeeVector;": "\u2960",
+ "LeftUpVectorBar;": "\u2958",
+ "LeftUpVector;": "\u21BF",
+ "LeftVectorBar;": "\u2952",
+ "LeftVector;": "\u21BC",
+ "lEg;": "\u2A8B",
+ "leg;": "\u22DA",
+ "leq;": "\u2264",
+ "leqq;": "\u2266",
+ "leqslant;": "\u2A7D",
+ "lescc;": "\u2AA8",
+ "les;": "\u2A7D",
+ "lesdot;": "\u2A7F",
+ "lesdoto;": "\u2A81",
+ "lesdotor;": "\u2A83",
+ "lesg;": "\u22DA\uFE00",
+ "lesges;": "\u2A93",
+ "lessapprox;": "\u2A85",
+ "lessdot;": "\u22D6",
+ "lesseqgtr;": "\u22DA",
+ "lesseqqgtr;": "\u2A8B",
+ "LessEqualGreater;": "\u22DA",
+ "LessFullEqual;": "\u2266",
+ "LessGreater;": "\u2276",
+ "lessgtr;": "\u2276",
+ "LessLess;": "\u2AA1",
+ "lesssim;": "\u2272",
+ "LessSlantEqual;": "\u2A7D",
+ "LessTilde;": "\u2272",
+ "lfisht;": "\u297C",
+ "lfloor;": "\u230A",
+ "Lfr;": "\uD835\uDD0F",
+ "lfr;": "\uD835\uDD29",
+ "lg;": "\u2276",
+ "lgE;": "\u2A91",
+ "lHar;": "\u2962",
+ "lhard;": "\u21BD",
+ "lharu;": "\u21BC",
+ "lharul;": "\u296A",
+ "lhblk;": "\u2584",
+ "LJcy;": "\u0409",
+ "ljcy;": "\u0459",
+ "llarr;": "\u21C7",
+ "ll;": "\u226A",
+ "Ll;": "\u22D8",
+ "llcorner;": "\u231E",
+ "Lleftarrow;": "\u21DA",
+ "llhard;": "\u296B",
+ "lltri;": "\u25FA",
+ "Lmidot;": "\u013F",
+ "lmidot;": "\u0140",
+ "lmoustache;": "\u23B0",
+ "lmoust;": "\u23B0",
+ "lnap;": "\u2A89",
+ "lnapprox;": "\u2A89",
+ "lne;": "\u2A87",
+ "lnE;": "\u2268",
+ "lneq;": "\u2A87",
+ "lneqq;": "\u2268",
+ "lnsim;": "\u22E6",
+ "loang;": "\u27EC",
+ "loarr;": "\u21FD",
+ "lobrk;": "\u27E6",
+ "longleftarrow;": "\u27F5",
+ "LongLeftArrow;": "\u27F5",
+ "Longleftarrow;": "\u27F8",
+ "longleftrightarrow;": "\u27F7",
+ "LongLeftRightArrow;": "\u27F7",
+ "Longleftrightarrow;": "\u27FA",
+ "longmapsto;": "\u27FC",
+ "longrightarrow;": "\u27F6",
+ "LongRightArrow;": "\u27F6",
+ "Longrightarrow;": "\u27F9",
+ "looparrowleft;": "\u21AB",
+ "looparrowright;": "\u21AC",
+ "lopar;": "\u2985",
+ "Lopf;": "\uD835\uDD43",
+ "lopf;": "\uD835\uDD5D",
+ "loplus;": "\u2A2D",
+ "lotimes;": "\u2A34",
+ "lowast;": "\u2217",
+ "lowbar;": "\u005F",
+ "LowerLeftArrow;": "\u2199",
+ "LowerRightArrow;": "\u2198",
+ "loz;": "\u25CA",
+ "lozenge;": "\u25CA",
+ "lozf;": "\u29EB",
+ "lpar;": "\u0028",
+ "lparlt;": "\u2993",
+ "lrarr;": "\u21C6",
+ "lrcorner;": "\u231F",
+ "lrhar;": "\u21CB",
+ "lrhard;": "\u296D",
+ "lrm;": "\u200E",
+ "lrtri;": "\u22BF",
+ "lsaquo;": "\u2039",
+ "lscr;": "\uD835\uDCC1",
+ "Lscr;": "\u2112",
+ "lsh;": "\u21B0",
+ "Lsh;": "\u21B0",
+ "lsim;": "\u2272",
+ "lsime;": "\u2A8D",
+ "lsimg;": "\u2A8F",
+ "lsqb;": "\u005B",
+ "lsquo;": "\u2018",
+ "lsquor;": "\u201A",
+ "Lstrok;": "\u0141",
+ "lstrok;": "\u0142",
+ "ltcc;": "\u2AA6",
+ "ltcir;": "\u2A79",
+ "lt;": "\u003C",
+ "lt": "\u003C",
+ "LT;": "\u003C",
+ "LT": "\u003C",
+ "Lt;": "\u226A",
+ "ltdot;": "\u22D6",
+ "lthree;": "\u22CB",
+ "ltimes;": "\u22C9",
+ "ltlarr;": "\u2976",
+ "ltquest;": "\u2A7B",
+ "ltri;": "\u25C3",
+ "ltrie;": "\u22B4",
+ "ltrif;": "\u25C2",
+ "ltrPar;": "\u2996",
+ "lurdshar;": "\u294A",
+ "luruhar;": "\u2966",
+ "lvertneqq;": "\u2268\uFE00",
+ "lvnE;": "\u2268\uFE00",
+ "macr;": "\u00AF",
+ "macr": "\u00AF",
+ "male;": "\u2642",
+ "malt;": "\u2720",
+ "maltese;": "\u2720",
+ "Map;": "\u2905",
+ "map;": "\u21A6",
+ "mapsto;": "\u21A6",
+ "mapstodown;": "\u21A7",
+ "mapstoleft;": "\u21A4",
+ "mapstoup;": "\u21A5",
+ "marker;": "\u25AE",
+ "mcomma;": "\u2A29",
+ "Mcy;": "\u041C",
+ "mcy;": "\u043C",
+ "mdash;": "\u2014",
+ "mDDot;": "\u223A",
+ "measuredangle;": "\u2221",
+ "MediumSpace;": "\u205F",
+ "Mellintrf;": "\u2133",
+ "Mfr;": "\uD835\uDD10",
+ "mfr;": "\uD835\uDD2A",
+ "mho;": "\u2127",
+ "micro;": "\u00B5",
+ "micro": "\u00B5",
+ "midast;": "\u002A",
+ "midcir;": "\u2AF0",
+ "mid;": "\u2223",
+ "middot;": "\u00B7",
+ "middot": "\u00B7",
+ "minusb;": "\u229F",
+ "minus;": "\u2212",
+ "minusd;": "\u2238",
+ "minusdu;": "\u2A2A",
+ "MinusPlus;": "\u2213",
+ "mlcp;": "\u2ADB",
+ "mldr;": "\u2026",
+ "mnplus;": "\u2213",
+ "models;": "\u22A7",
+ "Mopf;": "\uD835\uDD44",
+ "mopf;": "\uD835\uDD5E",
+ "mp;": "\u2213",
+ "mscr;": "\uD835\uDCC2",
+ "Mscr;": "\u2133",
+ "mstpos;": "\u223E",
+ "Mu;": "\u039C",
+ "mu;": "\u03BC",
+ "multimap;": "\u22B8",
+ "mumap;": "\u22B8",
+ "nabla;": "\u2207",
+ "Nacute;": "\u0143",
+ "nacute;": "\u0144",
+ "nang;": "\u2220\u20D2",
+ "nap;": "\u2249",
+ "napE;": "\u2A70\u0338",
+ "napid;": "\u224B\u0338",
+ "napos;": "\u0149",
+ "napprox;": "\u2249",
+ "natural;": "\u266E",
+ "naturals;": "\u2115",
+ "natur;": "\u266E",
+ "nbsp;": "\u00A0",
+ "nbsp": "\u00A0",
+ "nbump;": "\u224E\u0338",
+ "nbumpe;": "\u224F\u0338",
+ "ncap;": "\u2A43",
+ "Ncaron;": "\u0147",
+ "ncaron;": "\u0148",
+ "Ncedil;": "\u0145",
+ "ncedil;": "\u0146",
+ "ncong;": "\u2247",
+ "ncongdot;": "\u2A6D\u0338",
+ "ncup;": "\u2A42",
+ "Ncy;": "\u041D",
+ "ncy;": "\u043D",
+ "ndash;": "\u2013",
+ "nearhk;": "\u2924",
+ "nearr;": "\u2197",
+ "neArr;": "\u21D7",
+ "nearrow;": "\u2197",
+ "ne;": "\u2260",
+ "nedot;": "\u2250\u0338",
+ "NegativeMediumSpace;": "\u200B",
+ "NegativeThickSpace;": "\u200B",
+ "NegativeThinSpace;": "\u200B",
+ "NegativeVeryThinSpace;": "\u200B",
+ "nequiv;": "\u2262",
+ "nesear;": "\u2928",
+ "nesim;": "\u2242\u0338",
+ "NestedGreaterGreater;": "\u226B",
+ "NestedLessLess;": "\u226A",
+ "NewLine;": "\u000A",
+ "nexist;": "\u2204",
+ "nexists;": "\u2204",
+ "Nfr;": "\uD835\uDD11",
+ "nfr;": "\uD835\uDD2B",
+ "ngE;": "\u2267\u0338",
+ "nge;": "\u2271",
+ "ngeq;": "\u2271",
+ "ngeqq;": "\u2267\u0338",
+ "ngeqslant;": "\u2A7E\u0338",
+ "nges;": "\u2A7E\u0338",
+ "nGg;": "\u22D9\u0338",
+ "ngsim;": "\u2275",
+ "nGt;": "\u226B\u20D2",
+ "ngt;": "\u226F",
+ "ngtr;": "\u226F",
+ "nGtv;": "\u226B\u0338",
+ "nharr;": "\u21AE",
+ "nhArr;": "\u21CE",
+ "nhpar;": "\u2AF2",
+ "ni;": "\u220B",
+ "nis;": "\u22FC",
+ "nisd;": "\u22FA",
+ "niv;": "\u220B",
+ "NJcy;": "\u040A",
+ "njcy;": "\u045A",
+ "nlarr;": "\u219A",
+ "nlArr;": "\u21CD",
+ "nldr;": "\u2025",
+ "nlE;": "\u2266\u0338",
+ "nle;": "\u2270",
+ "nleftarrow;": "\u219A",
+ "nLeftarrow;": "\u21CD",
+ "nleftrightarrow;": "\u21AE",
+ "nLeftrightarrow;": "\u21CE",
+ "nleq;": "\u2270",
+ "nleqq;": "\u2266\u0338",
+ "nleqslant;": "\u2A7D\u0338",
+ "nles;": "\u2A7D\u0338",
+ "nless;": "\u226E",
+ "nLl;": "\u22D8\u0338",
+ "nlsim;": "\u2274",
+ "nLt;": "\u226A\u20D2",
+ "nlt;": "\u226E",
+ "nltri;": "\u22EA",
+ "nltrie;": "\u22EC",
+ "nLtv;": "\u226A\u0338",
+ "nmid;": "\u2224",
+ "NoBreak;": "\u2060",
+ "NonBreakingSpace;": "\u00A0",
+ "nopf;": "\uD835\uDD5F",
+ "Nopf;": "\u2115",
+ "Not;": "\u2AEC",
+ "not;": "\u00AC",
+ "not": "\u00AC",
+ "NotCongruent;": "\u2262",
+ "NotCupCap;": "\u226D",
+ "NotDoubleVerticalBar;": "\u2226",
+ "NotElement;": "\u2209",
+ "NotEqual;": "\u2260",
+ "NotEqualTilde;": "\u2242\u0338",
+ "NotExists;": "\u2204",
+ "NotGreater;": "\u226F",
+ "NotGreaterEqual;": "\u2271",
+ "NotGreaterFullEqual;": "\u2267\u0338",
+ "NotGreaterGreater;": "\u226B\u0338",
+ "NotGreaterLess;": "\u2279",
+ "NotGreaterSlantEqual;": "\u2A7E\u0338",
+ "NotGreaterTilde;": "\u2275",
+ "NotHumpDownHump;": "\u224E\u0338",
+ "NotHumpEqual;": "\u224F\u0338",
+ "notin;": "\u2209",
+ "notindot;": "\u22F5\u0338",
+ "notinE;": "\u22F9\u0338",
+ "notinva;": "\u2209",
+ "notinvb;": "\u22F7",
+ "notinvc;": "\u22F6",
+ "NotLeftTriangleBar;": "\u29CF\u0338",
+ "NotLeftTriangle;": "\u22EA",
+ "NotLeftTriangleEqual;": "\u22EC",
+ "NotLess;": "\u226E",
+ "NotLessEqual;": "\u2270",
+ "NotLessGreater;": "\u2278",
+ "NotLessLess;": "\u226A\u0338",
+ "NotLessSlantEqual;": "\u2A7D\u0338",
+ "NotLessTilde;": "\u2274",
+ "NotNestedGreaterGreater;": "\u2AA2\u0338",
+ "NotNestedLessLess;": "\u2AA1\u0338",
+ "notni;": "\u220C",
+ "notniva;": "\u220C",
+ "notnivb;": "\u22FE",
+ "notnivc;": "\u22FD",
+ "NotPrecedes;": "\u2280",
+ "NotPrecedesEqual;": "\u2AAF\u0338",
+ "NotPrecedesSlantEqual;": "\u22E0",
+ "NotReverseElement;": "\u220C",
+ "NotRightTriangleBar;": "\u29D0\u0338",
+ "NotRightTriangle;": "\u22EB",
+ "NotRightTriangleEqual;": "\u22ED",
+ "NotSquareSubset;": "\u228F\u0338",
+ "NotSquareSubsetEqual;": "\u22E2",
+ "NotSquareSuperset;": "\u2290\u0338",
+ "NotSquareSupersetEqual;": "\u22E3",
+ "NotSubset;": "\u2282\u20D2",
+ "NotSubsetEqual;": "\u2288",
+ "NotSucceeds;": "\u2281",
+ "NotSucceedsEqual;": "\u2AB0\u0338",
+ "NotSucceedsSlantEqual;": "\u22E1",
+ "NotSucceedsTilde;": "\u227F\u0338",
+ "NotSuperset;": "\u2283\u20D2",
+ "NotSupersetEqual;": "\u2289",
+ "NotTilde;": "\u2241",
+ "NotTildeEqual;": "\u2244",
+ "NotTildeFullEqual;": "\u2247",
+ "NotTildeTilde;": "\u2249",
+ "NotVerticalBar;": "\u2224",
+ "nparallel;": "\u2226",
+ "npar;": "\u2226",
+ "nparsl;": "\u2AFD\u20E5",
+ "npart;": "\u2202\u0338",
+ "npolint;": "\u2A14",
+ "npr;": "\u2280",
+ "nprcue;": "\u22E0",
+ "nprec;": "\u2280",
+ "npreceq;": "\u2AAF\u0338",
+ "npre;": "\u2AAF\u0338",
+ "nrarrc;": "\u2933\u0338",
+ "nrarr;": "\u219B",
+ "nrArr;": "\u21CF",
+ "nrarrw;": "\u219D\u0338",
+ "nrightarrow;": "\u219B",
+ "nRightarrow;": "\u21CF",
+ "nrtri;": "\u22EB",
+ "nrtrie;": "\u22ED",
+ "nsc;": "\u2281",
+ "nsccue;": "\u22E1",
+ "nsce;": "\u2AB0\u0338",
+ "Nscr;": "\uD835\uDCA9",
+ "nscr;": "\uD835\uDCC3",
+ "nshortmid;": "\u2224",
+ "nshortparallel;": "\u2226",
+ "nsim;": "\u2241",
+ "nsime;": "\u2244",
+ "nsimeq;": "\u2244",
+ "nsmid;": "\u2224",
+ "nspar;": "\u2226",
+ "nsqsube;": "\u22E2",
+ "nsqsupe;": "\u22E3",
+ "nsub;": "\u2284",
+ "nsubE;": "\u2AC5\u0338",
+ "nsube;": "\u2288",
+ "nsubset;": "\u2282\u20D2",
+ "nsubseteq;": "\u2288",
+ "nsubseteqq;": "\u2AC5\u0338",
+ "nsucc;": "\u2281",
+ "nsucceq;": "\u2AB0\u0338",
+ "nsup;": "\u2285",
+ "nsupE;": "\u2AC6\u0338",
+ "nsupe;": "\u2289",
+ "nsupset;": "\u2283\u20D2",
+ "nsupseteq;": "\u2289",
+ "nsupseteqq;": "\u2AC6\u0338",
+ "ntgl;": "\u2279",
+ "Ntilde;": "\u00D1",
+ "Ntilde": "\u00D1",
+ "ntilde;": "\u00F1",
+ "ntilde": "\u00F1",
+ "ntlg;": "\u2278",
+ "ntriangleleft;": "\u22EA",
+ "ntrianglelefteq;": "\u22EC",
+ "ntriangleright;": "\u22EB",
+ "ntrianglerighteq;": "\u22ED",
+ "Nu;": "\u039D",
+ "nu;": "\u03BD",
+ "num;": "\u0023",
+ "numero;": "\u2116",
+ "numsp;": "\u2007",
+ "nvap;": "\u224D\u20D2",
+ "nvdash;": "\u22AC",
+ "nvDash;": "\u22AD",
+ "nVdash;": "\u22AE",
+ "nVDash;": "\u22AF",
+ "nvge;": "\u2265\u20D2",
+ "nvgt;": "\u003E\u20D2",
+ "nvHarr;": "\u2904",
+ "nvinfin;": "\u29DE",
+ "nvlArr;": "\u2902",
+ "nvle;": "\u2264\u20D2",
+ "nvlt;": "\u003C\u20D2",
+ "nvltrie;": "\u22B4\u20D2",
+ "nvrArr;": "\u2903",
+ "nvrtrie;": "\u22B5\u20D2",
+ "nvsim;": "\u223C\u20D2",
+ "nwarhk;": "\u2923",
+ "nwarr;": "\u2196",
+ "nwArr;": "\u21D6",
+ "nwarrow;": "\u2196",
+ "nwnear;": "\u2927",
+ "Oacute;": "\u00D3",
+ "Oacute": "\u00D3",
+ "oacute;": "\u00F3",
+ "oacute": "\u00F3",
+ "oast;": "\u229B",
+ "Ocirc;": "\u00D4",
+ "Ocirc": "\u00D4",
+ "ocirc;": "\u00F4",
+ "ocirc": "\u00F4",
+ "ocir;": "\u229A",
+ "Ocy;": "\u041E",
+ "ocy;": "\u043E",
+ "odash;": "\u229D",
+ "Odblac;": "\u0150",
+ "odblac;": "\u0151",
+ "odiv;": "\u2A38",
+ "odot;": "\u2299",
+ "odsold;": "\u29BC",
+ "OElig;": "\u0152",
+ "oelig;": "\u0153",
+ "ofcir;": "\u29BF",
+ "Ofr;": "\uD835\uDD12",
+ "ofr;": "\uD835\uDD2C",
+ "ogon;": "\u02DB",
+ "Ograve;": "\u00D2",
+ "Ograve": "\u00D2",
+ "ograve;": "\u00F2",
+ "ograve": "\u00F2",
+ "ogt;": "\u29C1",
+ "ohbar;": "\u29B5",
+ "ohm;": "\u03A9",
+ "oint;": "\u222E",
+ "olarr;": "\u21BA",
+ "olcir;": "\u29BE",
+ "olcross;": "\u29BB",
+ "oline;": "\u203E",
+ "olt;": "\u29C0",
+ "Omacr;": "\u014C",
+ "omacr;": "\u014D",
+ "Omega;": "\u03A9",
+ "omega;": "\u03C9",
+ "Omicron;": "\u039F",
+ "omicron;": "\u03BF",
+ "omid;": "\u29B6",
+ "ominus;": "\u2296",
+ "Oopf;": "\uD835\uDD46",
+ "oopf;": "\uD835\uDD60",
+ "opar;": "\u29B7",
+ "OpenCurlyDoubleQuote;": "\u201C",
+ "OpenCurlyQuote;": "\u2018",
+ "operp;": "\u29B9",
+ "oplus;": "\u2295",
+ "orarr;": "\u21BB",
+ "Or;": "\u2A54",
+ "or;": "\u2228",
+ "ord;": "\u2A5D",
+ "order;": "\u2134",
+ "orderof;": "\u2134",
+ "ordf;": "\u00AA",
+ "ordf": "\u00AA",
+ "ordm;": "\u00BA",
+ "ordm": "\u00BA",
+ "origof;": "\u22B6",
+ "oror;": "\u2A56",
+ "orslope;": "\u2A57",
+ "orv;": "\u2A5B",
+ "oS;": "\u24C8",
+ "Oscr;": "\uD835\uDCAA",
+ "oscr;": "\u2134",
+ "Oslash;": "\u00D8",
+ "Oslash": "\u00D8",
+ "oslash;": "\u00F8",
+ "oslash": "\u00F8",
+ "osol;": "\u2298",
+ "Otilde;": "\u00D5",
+ "Otilde": "\u00D5",
+ "otilde;": "\u00F5",
+ "otilde": "\u00F5",
+ "otimesas;": "\u2A36",
+ "Otimes;": "\u2A37",
+ "otimes;": "\u2297",
+ "Ouml;": "\u00D6",
+ "Ouml": "\u00D6",
+ "ouml;": "\u00F6",
+ "ouml": "\u00F6",
+ "ovbar;": "\u233D",
+ "OverBar;": "\u203E",
+ "OverBrace;": "\u23DE",
+ "OverBracket;": "\u23B4",
+ "OverParenthesis;": "\u23DC",
+ "para;": "\u00B6",
+ "para": "\u00B6",
+ "parallel;": "\u2225",
+ "par;": "\u2225",
+ "parsim;": "\u2AF3",
+ "parsl;": "\u2AFD",
+ "part;": "\u2202",
+ "PartialD;": "\u2202",
+ "Pcy;": "\u041F",
+ "pcy;": "\u043F",
+ "percnt;": "\u0025",
+ "period;": "\u002E",
+ "permil;": "\u2030",
+ "perp;": "\u22A5",
+ "pertenk;": "\u2031",
+ "Pfr;": "\uD835\uDD13",
+ "pfr;": "\uD835\uDD2D",
+ "Phi;": "\u03A6",
+ "phi;": "\u03C6",
+ "phiv;": "\u03D5",
+ "phmmat;": "\u2133",
+ "phone;": "\u260E",
+ "Pi;": "\u03A0",
+ "pi;": "\u03C0",
+ "pitchfork;": "\u22D4",
+ "piv;": "\u03D6",
+ "planck;": "\u210F",
+ "planckh;": "\u210E",
+ "plankv;": "\u210F",
+ "plusacir;": "\u2A23",
+ "plusb;": "\u229E",
+ "pluscir;": "\u2A22",
+ "plus;": "\u002B",
+ "plusdo;": "\u2214",
+ "plusdu;": "\u2A25",
+ "pluse;": "\u2A72",
+ "PlusMinus;": "\u00B1",
+ "plusmn;": "\u00B1",
+ "plusmn": "\u00B1",
+ "plussim;": "\u2A26",
+ "plustwo;": "\u2A27",
+ "pm;": "\u00B1",
+ "Poincareplane;": "\u210C",
+ "pointint;": "\u2A15",
+ "popf;": "\uD835\uDD61",
+ "Popf;": "\u2119",
+ "pound;": "\u00A3",
+ "pound": "\u00A3",
+ "prap;": "\u2AB7",
+ "Pr;": "\u2ABB",
+ "pr;": "\u227A",
+ "prcue;": "\u227C",
+ "precapprox;": "\u2AB7",
+ "prec;": "\u227A",
+ "preccurlyeq;": "\u227C",
+ "Precedes;": "\u227A",
+ "PrecedesEqual;": "\u2AAF",
+ "PrecedesSlantEqual;": "\u227C",
+ "PrecedesTilde;": "\u227E",
+ "preceq;": "\u2AAF",
+ "precnapprox;": "\u2AB9",
+ "precneqq;": "\u2AB5",
+ "precnsim;": "\u22E8",
+ "pre;": "\u2AAF",
+ "prE;": "\u2AB3",
+ "precsim;": "\u227E",
+ "prime;": "\u2032",
+ "Prime;": "\u2033",
+ "primes;": "\u2119",
+ "prnap;": "\u2AB9",
+ "prnE;": "\u2AB5",
+ "prnsim;": "\u22E8",
+ "prod;": "\u220F",
+ "Product;": "\u220F",
+ "profalar;": "\u232E",
+ "profline;": "\u2312",
+ "profsurf;": "\u2313",
+ "prop;": "\u221D",
+ "Proportional;": "\u221D",
+ "Proportion;": "\u2237",
+ "propto;": "\u221D",
+ "prsim;": "\u227E",
+ "prurel;": "\u22B0",
+ "Pscr;": "\uD835\uDCAB",
+ "pscr;": "\uD835\uDCC5",
+ "Psi;": "\u03A8",
+ "psi;": "\u03C8",
+ "puncsp;": "\u2008",
+ "Qfr;": "\uD835\uDD14",
+ "qfr;": "\uD835\uDD2E",
+ "qint;": "\u2A0C",
+ "qopf;": "\uD835\uDD62",
+ "Qopf;": "\u211A",
+ "qprime;": "\u2057",
+ "Qscr;": "\uD835\uDCAC",
+ "qscr;": "\uD835\uDCC6",
+ "quaternions;": "\u210D",
+ "quatint;": "\u2A16",
+ "quest;": "\u003F",
+ "questeq;": "\u225F",
+ "quot;": "\u0022",
+ "quot": "\u0022",
+ "QUOT;": "\u0022",
+ "QUOT": "\u0022",
+ "rAarr;": "\u21DB",
+ "race;": "\u223D\u0331",
+ "Racute;": "\u0154",
+ "racute;": "\u0155",
+ "radic;": "\u221A",
+ "raemptyv;": "\u29B3",
+ "rang;": "\u27E9",
+ "Rang;": "\u27EB",
+ "rangd;": "\u2992",
+ "range;": "\u29A5",
+ "rangle;": "\u27E9",
+ "raquo;": "\u00BB",
+ "raquo": "\u00BB",
+ "rarrap;": "\u2975",
+ "rarrb;": "\u21E5",
+ "rarrbfs;": "\u2920",
+ "rarrc;": "\u2933",
+ "rarr;": "\u2192",
+ "Rarr;": "\u21A0",
+ "rArr;": "\u21D2",
+ "rarrfs;": "\u291E",
+ "rarrhk;": "\u21AA",
+ "rarrlp;": "\u21AC",
+ "rarrpl;": "\u2945",
+ "rarrsim;": "\u2974",
+ "Rarrtl;": "\u2916",
+ "rarrtl;": "\u21A3",
+ "rarrw;": "\u219D",
+ "ratail;": "\u291A",
+ "rAtail;": "\u291C",
+ "ratio;": "\u2236",
+ "rationals;": "\u211A",
+ "rbarr;": "\u290D",
+ "rBarr;": "\u290F",
+ "RBarr;": "\u2910",
+ "rbbrk;": "\u2773",
+ "rbrace;": "\u007D",
+ "rbrack;": "\u005D",
+ "rbrke;": "\u298C",
+ "rbrksld;": "\u298E",
+ "rbrkslu;": "\u2990",
+ "Rcaron;": "\u0158",
+ "rcaron;": "\u0159",
+ "Rcedil;": "\u0156",
+ "rcedil;": "\u0157",
+ "rceil;": "\u2309",
+ "rcub;": "\u007D",
+ "Rcy;": "\u0420",
+ "rcy;": "\u0440",
+ "rdca;": "\u2937",
+ "rdldhar;": "\u2969",
+ "rdquo;": "\u201D",
+ "rdquor;": "\u201D",
+ "rdsh;": "\u21B3",
+ "real;": "\u211C",
+ "realine;": "\u211B",
+ "realpart;": "\u211C",
+ "reals;": "\u211D",
+ "Re;": "\u211C",
+ "rect;": "\u25AD",
+ "reg;": "\u00AE",
+ "reg": "\u00AE",
+ "REG;": "\u00AE",
+ "REG": "\u00AE",
+ "ReverseElement;": "\u220B",
+ "ReverseEquilibrium;": "\u21CB",
+ "ReverseUpEquilibrium;": "\u296F",
+ "rfisht;": "\u297D",
+ "rfloor;": "\u230B",
+ "rfr;": "\uD835\uDD2F",
+ "Rfr;": "\u211C",
+ "rHar;": "\u2964",
+ "rhard;": "\u21C1",
+ "rharu;": "\u21C0",
+ "rharul;": "\u296C",
+ "Rho;": "\u03A1",
+ "rho;": "\u03C1",
+ "rhov;": "\u03F1",
+ "RightAngleBracket;": "\u27E9",
+ "RightArrowBar;": "\u21E5",
+ "rightarrow;": "\u2192",
+ "RightArrow;": "\u2192",
+ "Rightarrow;": "\u21D2",
+ "RightArrowLeftArrow;": "\u21C4",
+ "rightarrowtail;": "\u21A3",
+ "RightCeiling;": "\u2309",
+ "RightDoubleBracket;": "\u27E7",
+ "RightDownTeeVector;": "\u295D",
+ "RightDownVectorBar;": "\u2955",
+ "RightDownVector;": "\u21C2",
+ "RightFloor;": "\u230B",
+ "rightharpoondown;": "\u21C1",
+ "rightharpoonup;": "\u21C0",
+ "rightleftarrows;": "\u21C4",
+ "rightleftharpoons;": "\u21CC",
+ "rightrightarrows;": "\u21C9",
+ "rightsquigarrow;": "\u219D",
+ "RightTeeArrow;": "\u21A6",
+ "RightTee;": "\u22A2",
+ "RightTeeVector;": "\u295B",
+ "rightthreetimes;": "\u22CC",
+ "RightTriangleBar;": "\u29D0",
+ "RightTriangle;": "\u22B3",
+ "RightTriangleEqual;": "\u22B5",
+ "RightUpDownVector;": "\u294F",
+ "RightUpTeeVector;": "\u295C",
+ "RightUpVectorBar;": "\u2954",
+ "RightUpVector;": "\u21BE",
+ "RightVectorBar;": "\u2953",
+ "RightVector;": "\u21C0",
+ "ring;": "\u02DA",
+ "risingdotseq;": "\u2253",
+ "rlarr;": "\u21C4",
+ "rlhar;": "\u21CC",
+ "rlm;": "\u200F",
+ "rmoustache;": "\u23B1",
+ "rmoust;": "\u23B1",
+ "rnmid;": "\u2AEE",
+ "roang;": "\u27ED",
+ "roarr;": "\u21FE",
+ "robrk;": "\u27E7",
+ "ropar;": "\u2986",
+ "ropf;": "\uD835\uDD63",
+ "Ropf;": "\u211D",
+ "roplus;": "\u2A2E",
+ "rotimes;": "\u2A35",
+ "RoundImplies;": "\u2970",
+ "rpar;": "\u0029",
+ "rpargt;": "\u2994",
+ "rppolint;": "\u2A12",
+ "rrarr;": "\u21C9",
+ "Rrightarrow;": "\u21DB",
+ "rsaquo;": "\u203A",
+ "rscr;": "\uD835\uDCC7",
+ "Rscr;": "\u211B",
+ "rsh;": "\u21B1",
+ "Rsh;": "\u21B1",
+ "rsqb;": "\u005D",
+ "rsquo;": "\u2019",
+ "rsquor;": "\u2019",
+ "rthree;": "\u22CC",
+ "rtimes;": "\u22CA",
+ "rtri;": "\u25B9",
+ "rtrie;": "\u22B5",
+ "rtrif;": "\u25B8",
+ "rtriltri;": "\u29CE",
+ "RuleDelayed;": "\u29F4",
+ "ruluhar;": "\u2968",
+ "rx;": "\u211E",
+ "Sacute;": "\u015A",
+ "sacute;": "\u015B",
+ "sbquo;": "\u201A",
+ "scap;": "\u2AB8",
+ "Scaron;": "\u0160",
+ "scaron;": "\u0161",
+ "Sc;": "\u2ABC",
+ "sc;": "\u227B",
+ "sccue;": "\u227D",
+ "sce;": "\u2AB0",
+ "scE;": "\u2AB4",
+ "Scedil;": "\u015E",
+ "scedil;": "\u015F",
+ "Scirc;": "\u015C",
+ "scirc;": "\u015D",
+ "scnap;": "\u2ABA",
+ "scnE;": "\u2AB6",
+ "scnsim;": "\u22E9",
+ "scpolint;": "\u2A13",
+ "scsim;": "\u227F",
+ "Scy;": "\u0421",
+ "scy;": "\u0441",
+ "sdotb;": "\u22A1",
+ "sdot;": "\u22C5",
+ "sdote;": "\u2A66",
+ "searhk;": "\u2925",
+ "searr;": "\u2198",
+ "seArr;": "\u21D8",
+ "searrow;": "\u2198",
+ "sect;": "\u00A7",
+ "sect": "\u00A7",
+ "semi;": "\u003B",
+ "seswar;": "\u2929",
+ "setminus;": "\u2216",
+ "setmn;": "\u2216",
+ "sext;": "\u2736",
+ "Sfr;": "\uD835\uDD16",
+ "sfr;": "\uD835\uDD30",
+ "sfrown;": "\u2322",
+ "sharp;": "\u266F",
+ "SHCHcy;": "\u0429",
+ "shchcy;": "\u0449",
+ "SHcy;": "\u0428",
+ "shcy;": "\u0448",
+ "ShortDownArrow;": "\u2193",
+ "ShortLeftArrow;": "\u2190",
+ "shortmid;": "\u2223",
+ "shortparallel;": "\u2225",
+ "ShortRightArrow;": "\u2192",
+ "ShortUpArrow;": "\u2191",
+ "shy;": "\u00AD",
+ "shy": "\u00AD",
+ "Sigma;": "\u03A3",
+ "sigma;": "\u03C3",
+ "sigmaf;": "\u03C2",
+ "sigmav;": "\u03C2",
+ "sim;": "\u223C",
+ "simdot;": "\u2A6A",
+ "sime;": "\u2243",
+ "simeq;": "\u2243",
+ "simg;": "\u2A9E",
+ "simgE;": "\u2AA0",
+ "siml;": "\u2A9D",
+ "simlE;": "\u2A9F",
+ "simne;": "\u2246",
+ "simplus;": "\u2A24",
+ "simrarr;": "\u2972",
+ "slarr;": "\u2190",
+ "SmallCircle;": "\u2218",
+ "smallsetminus;": "\u2216",
+ "smashp;": "\u2A33",
+ "smeparsl;": "\u29E4",
+ "smid;": "\u2223",
+ "smile;": "\u2323",
+ "smt;": "\u2AAA",
+ "smte;": "\u2AAC",
+ "smtes;": "\u2AAC\uFE00",
+ "SOFTcy;": "\u042C",
+ "softcy;": "\u044C",
+ "solbar;": "\u233F",
+ "solb;": "\u29C4",
+ "sol;": "\u002F",
+ "Sopf;": "\uD835\uDD4A",
+ "sopf;": "\uD835\uDD64",
+ "spades;": "\u2660",
+ "spadesuit;": "\u2660",
+ "spar;": "\u2225",
+ "sqcap;": "\u2293",
+ "sqcaps;": "\u2293\uFE00",
+ "sqcup;": "\u2294",
+ "sqcups;": "\u2294\uFE00",
+ "Sqrt;": "\u221A",
+ "sqsub;": "\u228F",
+ "sqsube;": "\u2291",
+ "sqsubset;": "\u228F",
+ "sqsubseteq;": "\u2291",
+ "sqsup;": "\u2290",
+ "sqsupe;": "\u2292",
+ "sqsupset;": "\u2290",
+ "sqsupseteq;": "\u2292",
+ "square;": "\u25A1",
+ "Square;": "\u25A1",
+ "SquareIntersection;": "\u2293",
+ "SquareSubset;": "\u228F",
+ "SquareSubsetEqual;": "\u2291",
+ "SquareSuperset;": "\u2290",
+ "SquareSupersetEqual;": "\u2292",
+ "SquareUnion;": "\u2294",
+ "squarf;": "\u25AA",
+ "squ;": "\u25A1",
+ "squf;": "\u25AA",
+ "srarr;": "\u2192",
+ "Sscr;": "\uD835\uDCAE",
+ "sscr;": "\uD835\uDCC8",
+ "ssetmn;": "\u2216",
+ "ssmile;": "\u2323",
+ "sstarf;": "\u22C6",
+ "Star;": "\u22C6",
+ "star;": "\u2606",
+ "starf;": "\u2605",
+ "straightepsilon;": "\u03F5",
+ "straightphi;": "\u03D5",
+ "strns;": "\u00AF",
+ "sub;": "\u2282",
+ "Sub;": "\u22D0",
+ "subdot;": "\u2ABD",
+ "subE;": "\u2AC5",
+ "sube;": "\u2286",
+ "subedot;": "\u2AC3",
+ "submult;": "\u2AC1",
+ "subnE;": "\u2ACB",
+ "subne;": "\u228A",
+ "subplus;": "\u2ABF",
+ "subrarr;": "\u2979",
+ "subset;": "\u2282",
+ "Subset;": "\u22D0",
+ "subseteq;": "\u2286",
+ "subseteqq;": "\u2AC5",
+ "SubsetEqual;": "\u2286",
+ "subsetneq;": "\u228A",
+ "subsetneqq;": "\u2ACB",
+ "subsim;": "\u2AC7",
+ "subsub;": "\u2AD5",
+ "subsup;": "\u2AD3",
+ "succapprox;": "\u2AB8",
+ "succ;": "\u227B",
+ "succcurlyeq;": "\u227D",
+ "Succeeds;": "\u227B",
+ "SucceedsEqual;": "\u2AB0",
+ "SucceedsSlantEqual;": "\u227D",
+ "SucceedsTilde;": "\u227F",
+ "succeq;": "\u2AB0",
+ "succnapprox;": "\u2ABA",
+ "succneqq;": "\u2AB6",
+ "succnsim;": "\u22E9",
+ "succsim;": "\u227F",
+ "SuchThat;": "\u220B",
+ "sum;": "\u2211",
+ "Sum;": "\u2211",
+ "sung;": "\u266A",
+ "sup1;": "\u00B9",
+ "sup1": "\u00B9",
+ "sup2;": "\u00B2",
+ "sup2": "\u00B2",
+ "sup3;": "\u00B3",
+ "sup3": "\u00B3",
+ "sup;": "\u2283",
+ "Sup;": "\u22D1",
+ "supdot;": "\u2ABE",
+ "supdsub;": "\u2AD8",
+ "supE;": "\u2AC6",
+ "supe;": "\u2287",
+ "supedot;": "\u2AC4",
+ "Superset;": "\u2283",
+ "SupersetEqual;": "\u2287",
+ "suphsol;": "\u27C9",
+ "suphsub;": "\u2AD7",
+ "suplarr;": "\u297B",
+ "supmult;": "\u2AC2",
+ "supnE;": "\u2ACC",
+ "supne;": "\u228B",
+ "supplus;": "\u2AC0",
+ "supset;": "\u2283",
+ "Supset;": "\u22D1",
+ "supseteq;": "\u2287",
+ "supseteqq;": "\u2AC6",
+ "supsetneq;": "\u228B",
+ "supsetneqq;": "\u2ACC",
+ "supsim;": "\u2AC8",
+ "supsub;": "\u2AD4",
+ "supsup;": "\u2AD6",
+ "swarhk;": "\u2926",
+ "swarr;": "\u2199",
+ "swArr;": "\u21D9",
+ "swarrow;": "\u2199",
+ "swnwar;": "\u292A",
+ "szlig;": "\u00DF",
+ "szlig": "\u00DF",
+ "Tab;": "\u0009",
+ "target;": "\u2316",
+ "Tau;": "\u03A4",
+ "tau;": "\u03C4",
+ "tbrk;": "\u23B4",
+ "Tcaron;": "\u0164",
+ "tcaron;": "\u0165",
+ "Tcedil;": "\u0162",
+ "tcedil;": "\u0163",
+ "Tcy;": "\u0422",
+ "tcy;": "\u0442",
+ "tdot;": "\u20DB",
+ "telrec;": "\u2315",
+ "Tfr;": "\uD835\uDD17",
+ "tfr;": "\uD835\uDD31",
+ "there4;": "\u2234",
+ "therefore;": "\u2234",
+ "Therefore;": "\u2234",
+ "Theta;": "\u0398",
+ "theta;": "\u03B8",
+ "thetasym;": "\u03D1",
+ "thetav;": "\u03D1",
+ "thickapprox;": "\u2248",
+ "thicksim;": "\u223C",
+ "ThickSpace;": "\u205F\u200A",
+ "ThinSpace;": "\u2009",
+ "thinsp;": "\u2009",
+ "thkap;": "\u2248",
+ "thksim;": "\u223C",
+ "THORN;": "\u00DE",
+ "THORN": "\u00DE",
+ "thorn;": "\u00FE",
+ "thorn": "\u00FE",
+ "tilde;": "\u02DC",
+ "Tilde;": "\u223C",
+ "TildeEqual;": "\u2243",
+ "TildeFullEqual;": "\u2245",
+ "TildeTilde;": "\u2248",
+ "timesbar;": "\u2A31",
+ "timesb;": "\u22A0",
+ "times;": "\u00D7",
+ "times": "\u00D7",
+ "timesd;": "\u2A30",
+ "tint;": "\u222D",
+ "toea;": "\u2928",
+ "topbot;": "\u2336",
+ "topcir;": "\u2AF1",
+ "top;": "\u22A4",
+ "Topf;": "\uD835\uDD4B",
+ "topf;": "\uD835\uDD65",
+ "topfork;": "\u2ADA",
+ "tosa;": "\u2929",
+ "tprime;": "\u2034",
+ "trade;": "\u2122",
+ "TRADE;": "\u2122",
+ "triangle;": "\u25B5",
+ "triangledown;": "\u25BF",
+ "triangleleft;": "\u25C3",
+ "trianglelefteq;": "\u22B4",
+ "triangleq;": "\u225C",
+ "triangleright;": "\u25B9",
+ "trianglerighteq;": "\u22B5",
+ "tridot;": "\u25EC",
+ "trie;": "\u225C",
+ "triminus;": "\u2A3A",
+ "TripleDot;": "\u20DB",
+ "triplus;": "\u2A39",
+ "trisb;": "\u29CD",
+ "tritime;": "\u2A3B",
+ "trpezium;": "\u23E2",
+ "Tscr;": "\uD835\uDCAF",
+ "tscr;": "\uD835\uDCC9",
+ "TScy;": "\u0426",
+ "tscy;": "\u0446",
+ "TSHcy;": "\u040B",
+ "tshcy;": "\u045B",
+ "Tstrok;": "\u0166",
+ "tstrok;": "\u0167",
+ "twixt;": "\u226C",
+ "twoheadleftarrow;": "\u219E",
+ "twoheadrightarrow;": "\u21A0",
+ "Uacute;": "\u00DA",
+ "Uacute": "\u00DA",
+ "uacute;": "\u00FA",
+ "uacute": "\u00FA",
+ "uarr;": "\u2191",
+ "Uarr;": "\u219F",
+ "uArr;": "\u21D1",
+ "Uarrocir;": "\u2949",
+ "Ubrcy;": "\u040E",
+ "ubrcy;": "\u045E",
+ "Ubreve;": "\u016C",
+ "ubreve;": "\u016D",
+ "Ucirc;": "\u00DB",
+ "Ucirc": "\u00DB",
+ "ucirc;": "\u00FB",
+ "ucirc": "\u00FB",
+ "Ucy;": "\u0423",
+ "ucy;": "\u0443",
+ "udarr;": "\u21C5",
+ "Udblac;": "\u0170",
+ "udblac;": "\u0171",
+ "udhar;": "\u296E",
+ "ufisht;": "\u297E",
+ "Ufr;": "\uD835\uDD18",
+ "ufr;": "\uD835\uDD32",
+ "Ugrave;": "\u00D9",
+ "Ugrave": "\u00D9",
+ "ugrave;": "\u00F9",
+ "ugrave": "\u00F9",
+ "uHar;": "\u2963",
+ "uharl;": "\u21BF",
+ "uharr;": "\u21BE",
+ "uhblk;": "\u2580",
+ "ulcorn;": "\u231C",
+ "ulcorner;": "\u231C",
+ "ulcrop;": "\u230F",
+ "ultri;": "\u25F8",
+ "Umacr;": "\u016A",
+ "umacr;": "\u016B",
+ "uml;": "\u00A8",
+ "uml": "\u00A8",
+ "UnderBar;": "\u005F",
+ "UnderBrace;": "\u23DF",
+ "UnderBracket;": "\u23B5",
+ "UnderParenthesis;": "\u23DD",
+ "Union;": "\u22C3",
+ "UnionPlus;": "\u228E",
+ "Uogon;": "\u0172",
+ "uogon;": "\u0173",
+ "Uopf;": "\uD835\uDD4C",
+ "uopf;": "\uD835\uDD66",
+ "UpArrowBar;": "\u2912",
+ "uparrow;": "\u2191",
+ "UpArrow;": "\u2191",
+ "Uparrow;": "\u21D1",
+ "UpArrowDownArrow;": "\u21C5",
+ "updownarrow;": "\u2195",
+ "UpDownArrow;": "\u2195",
+ "Updownarrow;": "\u21D5",
+ "UpEquilibrium;": "\u296E",
+ "upharpoonleft;": "\u21BF",
+ "upharpoonright;": "\u21BE",
+ "uplus;": "\u228E",
+ "UpperLeftArrow;": "\u2196",
+ "UpperRightArrow;": "\u2197",
+ "upsi;": "\u03C5",
+ "Upsi;": "\u03D2",
+ "upsih;": "\u03D2",
+ "Upsilon;": "\u03A5",
+ "upsilon;": "\u03C5",
+ "UpTeeArrow;": "\u21A5",
+ "UpTee;": "\u22A5",
+ "upuparrows;": "\u21C8",
+ "urcorn;": "\u231D",
+ "urcorner;": "\u231D",
+ "urcrop;": "\u230E",
+ "Uring;": "\u016E",
+ "uring;": "\u016F",
+ "urtri;": "\u25F9",
+ "Uscr;": "\uD835\uDCB0",
+ "uscr;": "\uD835\uDCCA",
+ "utdot;": "\u22F0",
+ "Utilde;": "\u0168",
+ "utilde;": "\u0169",
+ "utri;": "\u25B5",
+ "utrif;": "\u25B4",
+ "uuarr;": "\u21C8",
+ "Uuml;": "\u00DC",
+ "Uuml": "\u00DC",
+ "uuml;": "\u00FC",
+ "uuml": "\u00FC",
+ "uwangle;": "\u29A7",
+ "vangrt;": "\u299C",
+ "varepsilon;": "\u03F5",
+ "varkappa;": "\u03F0",
+ "varnothing;": "\u2205",
+ "varphi;": "\u03D5",
+ "varpi;": "\u03D6",
+ "varpropto;": "\u221D",
+ "varr;": "\u2195",
+ "vArr;": "\u21D5",
+ "varrho;": "\u03F1",
+ "varsigma;": "\u03C2",
+ "varsubsetneq;": "\u228A\uFE00",
+ "varsubsetneqq;": "\u2ACB\uFE00",
+ "varsupsetneq;": "\u228B\uFE00",
+ "varsupsetneqq;": "\u2ACC\uFE00",
+ "vartheta;": "\u03D1",
+ "vartriangleleft;": "\u22B2",
+ "vartriangleright;": "\u22B3",
+ "vBar;": "\u2AE8",
+ "Vbar;": "\u2AEB",
+ "vBarv;": "\u2AE9",
+ "Vcy;": "\u0412",
+ "vcy;": "\u0432",
+ "vdash;": "\u22A2",
+ "vDash;": "\u22A8",
+ "Vdash;": "\u22A9",
+ "VDash;": "\u22AB",
+ "Vdashl;": "\u2AE6",
+ "veebar;": "\u22BB",
+ "vee;": "\u2228",
+ "Vee;": "\u22C1",
+ "veeeq;": "\u225A",
+ "vellip;": "\u22EE",
+ "verbar;": "\u007C",
+ "Verbar;": "\u2016",
+ "vert;": "\u007C",
+ "Vert;": "\u2016",
+ "VerticalBar;": "\u2223",
+ "VerticalLine;": "\u007C",
+ "VerticalSeparator;": "\u2758",
+ "VerticalTilde;": "\u2240",
+ "VeryThinSpace;": "\u200A",
+ "Vfr;": "\uD835\uDD19",
+ "vfr;": "\uD835\uDD33",
+ "vltri;": "\u22B2",
+ "vnsub;": "\u2282\u20D2",
+ "vnsup;": "\u2283\u20D2",
+ "Vopf;": "\uD835\uDD4D",
+ "vopf;": "\uD835\uDD67",
+ "vprop;": "\u221D",
+ "vrtri;": "\u22B3",
+ "Vscr;": "\uD835\uDCB1",
+ "vscr;": "\uD835\uDCCB",
+ "vsubnE;": "\u2ACB\uFE00",
+ "vsubne;": "\u228A\uFE00",
+ "vsupnE;": "\u2ACC\uFE00",
+ "vsupne;": "\u228B\uFE00",
+ "Vvdash;": "\u22AA",
+ "vzigzag;": "\u299A",
+ "Wcirc;": "\u0174",
+ "wcirc;": "\u0175",
+ "wedbar;": "\u2A5F",
+ "wedge;": "\u2227",
+ "Wedge;": "\u22C0",
+ "wedgeq;": "\u2259",
+ "weierp;": "\u2118",
+ "Wfr;": "\uD835\uDD1A",
+ "wfr;": "\uD835\uDD34",
+ "Wopf;": "\uD835\uDD4E",
+ "wopf;": "\uD835\uDD68",
+ "wp;": "\u2118",
+ "wr;": "\u2240",
+ "wreath;": "\u2240",
+ "Wscr;": "\uD835\uDCB2",
+ "wscr;": "\uD835\uDCCC",
+ "xcap;": "\u22C2",
+ "xcirc;": "\u25EF",
+ "xcup;": "\u22C3",
+ "xdtri;": "\u25BD",
+ "Xfr;": "\uD835\uDD1B",
+ "xfr;": "\uD835\uDD35",
+ "xharr;": "\u27F7",
+ "xhArr;": "\u27FA",
+ "Xi;": "\u039E",
+ "xi;": "\u03BE",
+ "xlarr;": "\u27F5",
+ "xlArr;": "\u27F8",
+ "xmap;": "\u27FC",
+ "xnis;": "\u22FB",
+ "xodot;": "\u2A00",
+ "Xopf;": "\uD835\uDD4F",
+ "xopf;": "\uD835\uDD69",
+ "xoplus;": "\u2A01",
+ "xotime;": "\u2A02",
+ "xrarr;": "\u27F6",
+ "xrArr;": "\u27F9",
+ "Xscr;": "\uD835\uDCB3",
+ "xscr;": "\uD835\uDCCD",
+ "xsqcup;": "\u2A06",
+ "xuplus;": "\u2A04",
+ "xutri;": "\u25B3",
+ "xvee;": "\u22C1",
+ "xwedge;": "\u22C0",
+ "Yacute;": "\u00DD",
+ "Yacute": "\u00DD",
+ "yacute;": "\u00FD",
+ "yacute": "\u00FD",
+ "YAcy;": "\u042F",
+ "yacy;": "\u044F",
+ "Ycirc;": "\u0176",
+ "ycirc;": "\u0177",
+ "Ycy;": "\u042B",
+ "ycy;": "\u044B",
+ "yen;": "\u00A5",
+ "yen": "\u00A5",
+ "Yfr;": "\uD835\uDD1C",
+ "yfr;": "\uD835\uDD36",
+ "YIcy;": "\u0407",
+ "yicy;": "\u0457",
+ "Yopf;": "\uD835\uDD50",
+ "yopf;": "\uD835\uDD6A",
+ "Yscr;": "\uD835\uDCB4",
+ "yscr;": "\uD835\uDCCE",
+ "YUcy;": "\u042E",
+ "yucy;": "\u044E",
+ "yuml;": "\u00FF",
+ "yuml": "\u00FF",
+ "Yuml;": "\u0178",
+ "Zacute;": "\u0179",
+ "zacute;": "\u017A",
+ "Zcaron;": "\u017D",
+ "zcaron;": "\u017E",
+ "Zcy;": "\u0417",
+ "zcy;": "\u0437",
+ "Zdot;": "\u017B",
+ "zdot;": "\u017C",
+ "zeetrf;": "\u2128",
+ "ZeroWidthSpace;": "\u200B",
+ "Zeta;": "\u0396",
+ "zeta;": "\u03B6",
+ "zfr;": "\uD835\uDD37",
+ "Zfr;": "\u2128",
+ "ZHcy;": "\u0416",
+ "zhcy;": "\u0436",
+ "zigrarr;": "\u21DD",
+ "zopf;": "\uD835\uDD6B",
+ "Zopf;": "\u2124",
+ "Zscr;": "\uD835\uDCB5",
+ "zscr;": "\uD835\uDCCF",
+ "zwj;": "\u200D",
+ "zwnj;": "\u200C"
+};
+
+},
+{}],
+13:[function(_dereq_,module,exports){
+var util = _dereq_('util/');
+
+var pSlice = Array.prototype.slice;
+var hasOwn = Object.prototype.hasOwnProperty;
+
+var assert = module.exports = ok;
+
+assert.AssertionError = function AssertionError(options) {
+ this.name = 'AssertionError';
+ this.actual = options.actual;
+ this.expected = options.expected;
+ this.operator = options.operator;
+ if (options.message) {
+ this.message = options.message;
+ this.generatedMessage = false;
+ } else {
+ this.message = getMessage(this);
+ this.generatedMessage = true;
+ }
+ var stackStartFunction = options.stackStartFunction || fail;
+
+ if (Error.captureStackTrace) {
+ Error.captureStackTrace(this, stackStartFunction);
+ }
+ else {
+ var err = new Error();
+ if (err.stack) {
+ var out = err.stack;
+ var fn_name = stackStartFunction.name;
+ var idx = out.indexOf('\n' + fn_name);
+ if (idx >= 0) {
+ var next_line = out.indexOf('\n', idx + 1);
+ out = out.substring(next_line + 1);
+ }
+
+ this.stack = out;
+ }
+ }
+};
+util.inherits(assert.AssertionError, Error);
+
+function replacer(key, value) {
+ if (util.isUndefined(value)) {
+ return '' + value;
+ }
+ if (util.isNumber(value) && (isNaN(value) || !isFinite(value))) {
+ return value.toString();
+ }
+ if (util.isFunction(value) || util.isRegExp(value)) {
+ return value.toString();
+ }
+ return value;
+}
+
+function truncate(s, n) {
+ if (util.isString(s)) {
+ return s.length < n ? s : s.slice(0, n);
+ } else {
+ return s;
+ }
+}
+
+function getMessage(self) {
+ return truncate(JSON.stringify(self.actual, replacer), 128) + ' ' +
+ self.operator + ' ' +
+ truncate(JSON.stringify(self.expected, replacer), 128);
+}
+
+function fail(actual, expected, message, operator, stackStartFunction) {
+ throw new assert.AssertionError({
+ message: message,
+ actual: actual,
+ expected: expected,
+ operator: operator,
+ stackStartFunction: stackStartFunction
+ });
+}
+assert.fail = fail;
+
+function ok(value, message) {
+ if (!value) fail(value, true, message, '==', assert.ok);
+}
+assert.ok = ok;
+
+assert.equal = function equal(actual, expected, message) {
+ if (actual != expected) fail(actual, expected, message, '==', assert.equal);
+};
+
+assert.notEqual = function notEqual(actual, expected, message) {
+ if (actual == expected) {
+ fail(actual, expected, message, '!=', assert.notEqual);
+ }
+};
+
+assert.deepEqual = function deepEqual(actual, expected, message) {
+ if (!_deepEqual(actual, expected)) {
+ fail(actual, expected, message, 'deepEqual', assert.deepEqual);
+ }
+};
+
+function _deepEqual(actual, expected) {
+ if (actual === expected) {
+ return true;
+
+ } else if (util.isBuffer(actual) && util.isBuffer(expected)) {
+ if (actual.length != expected.length) return false;
+
+ for (var i = 0; i < actual.length; i++) {
+ if (actual[i] !== expected[i]) return false;
+ }
+
+ return true;
+ } else if (util.isDate(actual) && util.isDate(expected)) {
+ return actual.getTime() === expected.getTime();
+ } else if (util.isRegExp(actual) && util.isRegExp(expected)) {
+ return actual.source === expected.source &&
+ actual.global === expected.global &&
+ actual.multiline === expected.multiline &&
+ actual.lastIndex === expected.lastIndex &&
+ actual.ignoreCase === expected.ignoreCase;
+ } else if (!util.isObject(actual) && !util.isObject(expected)) {
+ return actual == expected;
+ } else {
+ return objEquiv(actual, expected);
+ }
+}
+
+function isArguments(object) {
+ return Object.prototype.toString.call(object) == '[object Arguments]';
+}
+
+function objEquiv(a, b) {
+ if (util.isNullOrUndefined(a) || util.isNullOrUndefined(b))
+ return false;
+ if (a.prototype !== b.prototype) return false;
+ if (isArguments(a)) {
+ if (!isArguments(b)) {
+ return false;
+ }
+ a = pSlice.call(a);
+ b = pSlice.call(b);
+ return _deepEqual(a, b);
+ }
+ try {
+ var ka = objectKeys(a),
+ kb = objectKeys(b),
+ key, i;
+ } catch (e) {//happens when one is a string literal and the other isn't
+ return false;
+ }
+ if (ka.length != kb.length)
+ return false;
+ ka.sort();
+ kb.sort();
+ for (i = ka.length - 1; i >= 0; i--) {
+ if (ka[i] != kb[i])
+ return false;
+ }
+ for (i = ka.length - 1; i >= 0; i--) {
+ key = ka[i];
+ if (!_deepEqual(a[key], b[key])) return false;
+ }
+ return true;
+}
+
+assert.notDeepEqual = function notDeepEqual(actual, expected, message) {
+ if (_deepEqual(actual, expected)) {
+ fail(actual, expected, message, 'notDeepEqual', assert.notDeepEqual);
+ }
+};
+
+assert.strictEqual = function strictEqual(actual, expected, message) {
+ if (actual !== expected) {
+ fail(actual, expected, message, '===', assert.strictEqual);
+ }
+};
+
+assert.notStrictEqual = function notStrictEqual(actual, expected, message) {
+ if (actual === expected) {
+ fail(actual, expected, message, '!==', assert.notStrictEqual);
+ }
+};
+
+function expectedException(actual, expected) {
+ if (!actual || !expected) {
+ return false;
+ }
+
+ if (Object.prototype.toString.call(expected) == '[object RegExp]') {
+ return expected.test(actual);
+ } else if (actual instanceof expected) {
+ return true;
+ } else if (expected.call({}, actual) === true) {
+ return true;
+ }
+
+ return false;
+}
+
+function _throws(shouldThrow, block, expected, message) {
+ var actual;
+
+ if (util.isString(expected)) {
+ message = expected;
+ expected = null;
+ }
+
+ try {
+ block();
+ } catch (e) {
+ actual = e;
+ }
+
+ message = (expected && expected.name ? ' (' + expected.name + ').' : '.') +
+ (message ? ' ' + message : '.');
+
+ if (shouldThrow && !actual) {
+ fail(actual, expected, 'Missing expected exception' + message);
+ }
+
+ if (!shouldThrow && expectedException(actual, expected)) {
+ fail(actual, expected, 'Got unwanted exception' + message);
+ }
+
+ if ((shouldThrow && actual && expected &&
+ !expectedException(actual, expected)) || (!shouldThrow && actual)) {
+ throw actual;
+ }
+}
+
+assert.throws = function(block, /*optional*/error, /*optional*/message) {
+ _throws.apply(this, [true].concat(pSlice.call(arguments)));
+};
+assert.doesNotThrow = function(block, /*optional*/message) {
+ _throws.apply(this, [false].concat(pSlice.call(arguments)));
+};
+
+assert.ifError = function(err) { if (err) {throw err;}};
+
+var objectKeys = Object.keys || function (obj) {
+ var keys = [];
+ for (var key in obj) {
+ if (hasOwn.call(obj, key)) keys.push(key);
+ }
+ return keys;
+};
+
+},
+{"util/":15}],
+14:[function(_dereq_,module,exports){
+module.exports = function isBuffer(arg) {
+ return arg && typeof arg === 'object'
+ && typeof arg.copy === 'function'
+ && typeof arg.fill === 'function'
+ && typeof arg.readUInt8 === 'function';
+}
+},
+{}],
+15:[function(_dereq_,module,exports){
+(function (process,global){
+
+var formatRegExp = /%[sdj%]/g;
+exports.format = function(f) {
+ if (!isString(f)) {
+ var objects = [];
+ for (var i = 0; i < arguments.length; i++) {
+ objects.push(inspect(arguments[i]));
+ }
+ return objects.join(' ');
+ }
+
+ var i = 1;
+ var args = arguments;
+ var len = args.length;
+ var str = String(f).replace(formatRegExp, function(x) {
+ if (x === '%%') return '%';
+ if (i >= len) return x;
+ switch (x) {
+ case '%s': return String(args[i++]);
+ case '%d': return Number(args[i++]);
+ case '%j':
+ try {
+ return JSON.stringify(args[i++]);
+ } catch (_) {
+ return '[Circular]';
+ }
+ default:
+ return x;
+ }
+ });
+ for (var x = args[i]; i < len; x = args[++i]) {
+ if (isNull(x) || !isObject(x)) {
+ str += ' ' + x;
+ } else {
+ str += ' ' + inspect(x);
+ }
+ }
+ return str;
+};
+exports.deprecate = function(fn, msg) {
+ if (isUndefined(global.process)) {
+ return function() {
+ return exports.deprecate(fn, msg).apply(this, arguments);
+ };
+ }
+
+ if (process.noDeprecation === true) {
+ return fn;
+ }
+
+ var warned = false;
+ function deprecated() {
+ if (!warned) {
+ if (process.throwDeprecation) {
+ throw new Error(msg);
+ } else if (process.traceDeprecation) {
+ console.trace(msg);
+ } else {
+ console.error(msg);
+ }
+ warned = true;
+ }
+ return fn.apply(this, arguments);
+ }
+
+ return deprecated;
+};
+
+
+var debugs = {};
+var debugEnviron;
+exports.debuglog = function(set) {
+ if (isUndefined(debugEnviron))
+ debugEnviron = process.env.NODE_DEBUG || '';
+ set = set.toUpperCase();
+ if (!debugs[set]) {
+ if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
+ var pid = process.pid;
+ debugs[set] = function() {
+ var msg = exports.format.apply(exports, arguments);
+ console.error('%s %d: %s', set, pid, msg);
+ };
+ } else {
+ debugs[set] = function() {};
+ }
+ }
+ return debugs[set];
+};
+function inspect(obj, opts) {
+ var ctx = {
+ seen: [],
+ stylize: stylizeNoColor
+ };
+ if (arguments.length >= 3) ctx.depth = arguments[2];
+ if (arguments.length >= 4) ctx.colors = arguments[3];
+ if (isBoolean(opts)) {
+ ctx.showHidden = opts;
+ } else if (opts) {
+ exports._extend(ctx, opts);
+ }
+ if (isUndefined(ctx.showHidden)) ctx.showHidden = false;
+ if (isUndefined(ctx.depth)) ctx.depth = 2;
+ if (isUndefined(ctx.colors)) ctx.colors = false;
+ if (isUndefined(ctx.customInspect)) ctx.customInspect = true;
+ if (ctx.colors) ctx.stylize = stylizeWithColor;
+ return formatValue(ctx, obj, ctx.depth);
+}
+exports.inspect = inspect;
+inspect.colors = {
+ 'bold' : [1, 22],
+ 'italic' : [3, 23],
+ 'underline' : [4, 24],
+ 'inverse' : [7, 27],
+ 'white' : [37, 39],
+ 'grey' : [90, 39],
+ 'black' : [30, 39],
+ 'blue' : [34, 39],
+ 'cyan' : [36, 39],
+ 'green' : [32, 39],
+ 'magenta' : [35, 39],
+ 'red' : [31, 39],
+ 'yellow' : [33, 39]
+};
+inspect.styles = {
+ 'special': 'cyan',
+ 'number': 'yellow',
+ 'boolean': 'yellow',
+ 'undefined': 'grey',
+ 'null': 'bold',
+ 'string': 'green',
+ 'date': 'magenta',
+ 'regexp': 'red'
+};
+
+
+function stylizeWithColor(str, styleType) {
+ var style = inspect.styles[styleType];
+
+ if (style) {
+ return '\u001b[' + inspect.colors[style][0] + 'm' + str +
+ '\u001b[' + inspect.colors[style][1] + 'm';
+ } else {
+ return str;
+ }
+}
+
+
+function stylizeNoColor(str, styleType) {
+ return str;
+}
+
+
+function arrayToHash(array) {
+ var hash = {};
+
+ array.forEach(function(val, idx) {
+ hash[val] = true;
+ });
+
+ return hash;
+}
+
+
+function formatValue(ctx, value, recurseTimes) {
+ if (ctx.customInspect &&
+ value &&
+ isFunction(value.inspect) &&
+ value.inspect !== exports.inspect &&
+ !(value.constructor && value.constructor.prototype === value)) {
+ var ret = value.inspect(recurseTimes, ctx);
+ if (!isString(ret)) {
+ ret = formatValue(ctx, ret, recurseTimes);
+ }
+ return ret;
+ }
+ var primitive = formatPrimitive(ctx, value);
+ if (primitive) {
+ return primitive;
+ }
+ var keys = Object.keys(value);
+ var visibleKeys = arrayToHash(keys);
+
+ if (ctx.showHidden) {
+ keys = Object.getOwnPropertyNames(value);
+ }
+ if (isError(value)
+ && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {
+ return formatError(value);
+ }
+ if (keys.length === 0) {
+ if (isFunction(value)) {
+ var name = value.name ? ': ' + value.name : '';
+ return ctx.stylize('[Function' + name + ']', 'special');
+ }
+ if (isRegExp(value)) {
+ return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
+ }
+ if (isDate(value)) {
+ return ctx.stylize(Date.prototype.toString.call(value), 'date');
+ }
+ if (isError(value)) {
+ return formatError(value);
+ }
+ }
+
+ var base = '', array = false, braces = ['{', '}'];
+ if (isArray(value)) {
+ array = true;
+ braces = ['[', ']'];
+ }
+ if (isFunction(value)) {
+ var n = value.name ? ': ' + value.name : '';
+ base = ' [Function' + n + ']';
+ }
+ if (isRegExp(value)) {
+ base = ' ' + RegExp.prototype.toString.call(value);
+ }
+ if (isDate(value)) {
+ base = ' ' + Date.prototype.toUTCString.call(value);
+ }
+ if (isError(value)) {
+ base = ' ' + formatError(value);
+ }
+
+ if (keys.length === 0 && (!array || value.length == 0)) {
+ return braces[0] + base + braces[1];
+ }
+
+ if (recurseTimes < 0) {
+ if (isRegExp(value)) {
+ return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
+ } else {
+ return ctx.stylize('[Object]', 'special');
+ }
+ }
+
+ ctx.seen.push(value);
+
+ var output;
+ if (array) {
+ output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
+ } else {
+ output = keys.map(function(key) {
+ return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
+ });
+ }
+
+ ctx.seen.pop();
+
+ return reduceToSingleString(output, base, braces);
+}
+
+
+function formatPrimitive(ctx, value) {
+ if (isUndefined(value))
+ return ctx.stylize('undefined', 'undefined');
+ if (isString(value)) {
+ var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '')
+ .replace(/'/g, "\\'")
+ .replace(/\\"/g, '"') + '\'';
+ return ctx.stylize(simple, 'string');
+ }
+ if (isNumber(value))
+ return ctx.stylize('' + value, 'number');
+ if (isBoolean(value))
+ return ctx.stylize('' + value, 'boolean');
+ if (isNull(value))
+ return ctx.stylize('null', 'null');
+}
+
+
+function formatError(value) {
+ return '[' + Error.prototype.toString.call(value) + ']';
+}
+
+
+function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
+ var output = [];
+ for (var i = 0, l = value.length; i < l; ++i) {
+ if (hasOwnProperty(value, String(i))) {
+ output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
+ String(i), true));
+ } else {
+ output.push('');
+ }
+ }
+ keys.forEach(function(key) {
+ if (!key.match(/^\d+$/)) {
+ output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
+ key, true));
+ }
+ });
+ return output;
+}
+
+
+function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
+ var name, str, desc;
+ desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };
+ if (desc.get) {
+ if (desc.set) {
+ str = ctx.stylize('[Getter/Setter]', 'special');
+ } else {
+ str = ctx.stylize('[Getter]', 'special');
+ }
+ } else {
+ if (desc.set) {
+ str = ctx.stylize('[Setter]', 'special');
+ }
+ }
+ if (!hasOwnProperty(visibleKeys, key)) {
+ name = '[' + key + ']';
+ }
+ if (!str) {
+ if (ctx.seen.indexOf(desc.value) < 0) {
+ if (isNull(recurseTimes)) {
+ str = formatValue(ctx, desc.value, null);
+ } else {
+ str = formatValue(ctx, desc.value, recurseTimes - 1);
+ }
+ if (str.indexOf('\n') > -1) {
+ if (array) {
+ str = str.split('\n').map(function(line) {
+ return ' ' + line;
+ }).join('\n').substr(2);
+ } else {
+ str = '\n' + str.split('\n').map(function(line) {
+ return ' ' + line;
+ }).join('\n');
+ }
+ }
+ } else {
+ str = ctx.stylize('[Circular]', 'special');
+ }
+ }
+ if (isUndefined(name)) {
+ if (array && key.match(/^\d+$/)) {
+ return str;
+ }
+ name = JSON.stringify('' + key);
+ if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
+ name = name.substr(1, name.length - 2);
+ name = ctx.stylize(name, 'name');
+ } else {
+ name = name.replace(/'/g, "\\'")
+ .replace(/\\"/g, '"')
+ .replace(/(^"|"$)/g, "'");
+ name = ctx.stylize(name, 'string');
+ }
+ }
+
+ return name + ': ' + str;
+}
+
+
+function reduceToSingleString(output, base, braces) {
+ var numLinesEst = 0;
+ var length = output.reduce(function(prev, cur) {
+ numLinesEst++;
+ if (cur.indexOf('\n') >= 0) numLinesEst++;
+ return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;
+ }, 0);
+
+ if (length > 60) {
+ return braces[0] +
+ (base === '' ? '' : base + '\n ') +
+ ' ' +
+ output.join(',\n ') +
+ ' ' +
+ braces[1];
+ }
+
+ return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];
+}
+function isArray(ar) {
+ return Array.isArray(ar);
+}
+exports.isArray = isArray;
+
+function isBoolean(arg) {
+ return typeof arg === 'boolean';
+}
+exports.isBoolean = isBoolean;
+
+function isNull(arg) {
+ return arg === null;
+}
+exports.isNull = isNull;
+
+function isNullOrUndefined(arg) {
+ return arg == null;
+}
+exports.isNullOrUndefined = isNullOrUndefined;
+
+function isNumber(arg) {
+ return typeof arg === 'number';
+}
+exports.isNumber = isNumber;
+
+function isString(arg) {
+ return typeof arg === 'string';
+}
+exports.isString = isString;
+
+function isSymbol(arg) {
+ return typeof arg === 'symbol';
+}
+exports.isSymbol = isSymbol;
+
+function isUndefined(arg) {
+ return arg === void 0;
+}
+exports.isUndefined = isUndefined;
+
+function isRegExp(re) {
+ return isObject(re) && objectToString(re) === '[object RegExp]';
+}
+exports.isRegExp = isRegExp;
+
+function isObject(arg) {
+ return typeof arg === 'object' && arg !== null;
+}
+exports.isObject = isObject;
+
+function isDate(d) {
+ return isObject(d) && objectToString(d) === '[object Date]';
+}
+exports.isDate = isDate;
+
+function isError(e) {
+ return isObject(e) &&
+ (objectToString(e) === '[object Error]' || e instanceof Error);
+}
+exports.isError = isError;
+
+function isFunction(arg) {
+ return typeof arg === 'function';
+}
+exports.isFunction = isFunction;
+
+function isPrimitive(arg) {
+ return arg === null ||
+ typeof arg === 'boolean' ||
+ typeof arg === 'number' ||
+ typeof arg === 'string' ||
+ typeof arg === 'symbol' || // ES6 symbol
+ typeof arg === 'undefined';
+}
+exports.isPrimitive = isPrimitive;
+
+exports.isBuffer = _dereq_('./support/isBuffer');
+
+function objectToString(o) {
+ return Object.prototype.toString.call(o);
+}
+
+
+function pad(n) {
+ return n < 10 ? '0' + n.toString(10) : n.toString(10);
+}
+
+
+var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',
+ 'Oct', 'Nov', 'Dec'];
+function timestamp() {
+ var d = new Date();
+ var time = [pad(d.getHours()),
+ pad(d.getMinutes()),
+ pad(d.getSeconds())].join(':');
+ return [d.getDate(), months[d.getMonth()], time].join(' ');
+}
+exports.log = function() {
+ console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));
+};
+exports.inherits = _dereq_('inherits');
+
+exports._extend = function(origin, add) {
+ if (!add || !isObject(add)) return origin;
+
+ var keys = Object.keys(add);
+ var i = keys.length;
+ while (i--) {
+ origin[keys[i]] = add[keys[i]];
+ }
+ return origin;
+};
+
+function hasOwnProperty(obj, prop) {
+ return Object.prototype.hasOwnProperty.call(obj, prop);
+}
+
+}).call(this,_dereq_("/usr/local/lib/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js"),typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
+},
+{"./support/isBuffer":14,"/usr/local/lib/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js":18,"inherits":17}],
+16:[function(_dereq_,module,exports){
+
+function EventEmitter() {
+ this._events = this._events || {};
+ this._maxListeners = this._maxListeners || undefined;
+}
+module.exports = EventEmitter;
+EventEmitter.EventEmitter = EventEmitter;
+
+EventEmitter.prototype._events = undefined;
+EventEmitter.prototype._maxListeners = undefined;
+EventEmitter.defaultMaxListeners = 10;
+EventEmitter.prototype.setMaxListeners = function(n) {
+ if (!isNumber(n) || n < 0 || isNaN(n))
+ throw TypeError('n must be a positive number');
+ this._maxListeners = n;
+ return this;
+};
+
+EventEmitter.prototype.emit = function(type) {
+ var er, handler, len, args, i, listeners;
+
+ if (!this._events)
+ this._events = {};
+ if (type === 'error') {
+ if (!this._events.error ||
+ (isObject(this._events.error) && !this._events.error.length)) {
+ er = arguments[1];
+ if (er instanceof Error) {
+ throw er; // Unhandled 'error' event
+ } else {
+ throw TypeError('Uncaught, unspecified "error" event.');
+ }
+ return false;
+ }
+ }
+
+ handler = this._events[type];
+
+ if (isUndefined(handler))
+ return false;
+
+ if (isFunction(handler)) {
+ switch (arguments.length) {
+ case 1:
+ handler.call(this);
+ break;
+ case 2:
+ handler.call(this, arguments[1]);
+ break;
+ case 3:
+ handler.call(this, arguments[1], arguments[2]);
+ break;
+ default:
+ len = arguments.length;
+ args = new Array(len - 1);
+ for (i = 1; i < len; i++)
+ args[i - 1] = arguments[i];
+ handler.apply(this, args);
+ }
+ } else if (isObject(handler)) {
+ len = arguments.length;
+ args = new Array(len - 1);
+ for (i = 1; i < len; i++)
+ args[i - 1] = arguments[i];
+
+ listeners = handler.slice();
+ len = listeners.length;
+ for (i = 0; i < len; i++)
+ listeners[i].apply(this, args);
+ }
+
+ return true;
+};
+
+EventEmitter.prototype.addListener = function(type, listener) {
+ var m;
+
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ if (!this._events)
+ this._events = {};
+ if (this._events.newListener)
+ this.emit('newListener', type,
+ isFunction(listener.listener) ?
+ listener.listener : listener);
+
+ if (!this._events[type])
+ this._events[type] = listener;
+ else if (isObject(this._events[type]))
+ this._events[type].push(listener);
+ else
+ this._events[type] = [this._events[type], listener];
+ if (isObject(this._events[type]) && !this._events[type].warned) {
+ var m;
+ if (!isUndefined(this._maxListeners)) {
+ m = this._maxListeners;
+ } else {
+ m = EventEmitter.defaultMaxListeners;
+ }
+
+ if (m && m > 0 && this._events[type].length > m) {
+ this._events[type].warned = true;
+ console.error('(node) warning: possible EventEmitter memory ' +
+ 'leak detected. %d listeners added. ' +
+ 'Use emitter.setMaxListeners() to increase limit.',
+ this._events[type].length);
+ console.trace();
+ }
+ }
+
+ return this;
+};
+
+EventEmitter.prototype.on = EventEmitter.prototype.addListener;
+
+EventEmitter.prototype.once = function(type, listener) {
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ var fired = false;
+
+ function g() {
+ this.removeListener(type, g);
+
+ if (!fired) {
+ fired = true;
+ listener.apply(this, arguments);
+ }
+ }
+
+ g.listener = listener;
+ this.on(type, g);
+
+ return this;
+};
+EventEmitter.prototype.removeListener = function(type, listener) {
+ var list, position, length, i;
+
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ if (!this._events || !this._events[type])
+ return this;
+
+ list = this._events[type];
+ length = list.length;
+ position = -1;
+
+ if (list === listener ||
+ (isFunction(list.listener) && list.listener === listener)) {
+ delete this._events[type];
+ if (this._events.removeListener)
+ this.emit('removeListener', type, listener);
+
+ } else if (isObject(list)) {
+ for (i = length; i-- > 0;) {
+ if (list[i] === listener ||
+ (list[i].listener && list[i].listener === listener)) {
+ position = i;
+ break;
+ }
+ }
+
+ if (position < 0)
+ return this;
+
+ if (list.length === 1) {
+ list.length = 0;
+ delete this._events[type];
+ } else {
+ list.splice(position, 1);
+ }
+
+ if (this._events.removeListener)
+ this.emit('removeListener', type, listener);
+ }
+
+ return this;
+};
+
+EventEmitter.prototype.removeAllListeners = function(type) {
+ var key, listeners;
+
+ if (!this._events)
+ return this;
+ if (!this._events.removeListener) {
+ if (arguments.length === 0)
+ this._events = {};
+ else if (this._events[type])
+ delete this._events[type];
+ return this;
+ }
+ if (arguments.length === 0) {
+ for (key in this._events) {
+ if (key === 'removeListener') continue;
+ this.removeAllListeners(key);
+ }
+ this.removeAllListeners('removeListener');
+ this._events = {};
+ return this;
+ }
+
+ listeners = this._events[type];
+
+ if (isFunction(listeners)) {
+ this.removeListener(type, listeners);
+ } else {
+ while (listeners.length)
+ this.removeListener(type, listeners[listeners.length - 1]);
+ }
+ delete this._events[type];
+
+ return this;
+};
+
+EventEmitter.prototype.listeners = function(type) {
+ var ret;
+ if (!this._events || !this._events[type])
+ ret = [];
+ else if (isFunction(this._events[type]))
+ ret = [this._events[type]];
+ else
+ ret = this._events[type].slice();
+ return ret;
+};
+
+EventEmitter.listenerCount = function(emitter, type) {
+ var ret;
+ if (!emitter._events || !emitter._events[type])
+ ret = 0;
+ else if (isFunction(emitter._events[type]))
+ ret = 1;
+ else
+ ret = emitter._events[type].length;
+ return ret;
+};
+
+function isFunction(arg) {
+ return typeof arg === 'function';
+}
+
+function isNumber(arg) {
+ return typeof arg === 'number';
+}
+
+function isObject(arg) {
+ return typeof arg === 'object' && arg !== null;
+}
+
+function isUndefined(arg) {
+ return arg === void 0;
+}
+
+},
+{}],
+17:[function(_dereq_,module,exports){
+if (typeof Object.create === 'function') {
+ module.exports = function inherits(ctor, superCtor) {
+ ctor.super_ = superCtor
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+ };
+} else {
+ module.exports = function inherits(ctor, superCtor) {
+ ctor.super_ = superCtor
+ var TempCtor = function () {}
+ TempCtor.prototype = superCtor.prototype
+ ctor.prototype = new TempCtor()
+ ctor.prototype.constructor = ctor
+ }
+}
+
+},
+{}],
+18:[function(_dereq_,module,exports){
+
+var process = module.exports = {};
+
+process.nextTick = (function () {
+ var canSetImmediate = typeof window !== 'undefined'
+ && window.setImmediate;
+ var canPost = typeof window !== 'undefined'
+ && window.postMessage && window.addEventListener
+ ;
+
+ if (canSetImmediate) {
+ return function (f) { return window.setImmediate(f) };
+ }
+
+ if (canPost) {
+ var queue = [];
+ window.addEventListener('message', function (ev) {
+ var source = ev.source;
+ if ((source === window || source === null) && ev.data === 'process-tick') {
+ ev.stopPropagation();
+ if (queue.length > 0) {
+ var fn = queue.shift();
+ fn();
+ }
+ }
+ }, true);
+
+ return function nextTick(fn) {
+ queue.push(fn);
+ window.postMessage('process-tick', '*');
+ };
+ }
+
+ return function nextTick(fn) {
+ setTimeout(fn, 0);
+ };
+})();
+
+process.title = 'browser';
+process.browser = true;
+process.env = {};
+process.argv = [];
+
+function noop() {}
+
+process.on = noop;
+process.once = noop;
+process.off = noop;
+process.emit = noop;
+
+process.binding = function (name) {
+ throw new Error('process.binding is not supported');
+}
+process.cwd = function () { return '/' };
+process.chdir = function (dir) {
+ throw new Error('process.chdir is not supported');
+};
+
+},
+{}],
+19:[function(_dereq_,module,exports){
+module.exports=_dereq_(14)
+},
+{}],
+20:[function(_dereq_,module,exports){
+module.exports=_dereq_(15)
+},
+{"./support/isBuffer":19,"/usr/local/lib/node_modules/browserify/node_modules/insert-module-globals/node_modules/process/browser.js":18,"inherits":17}]},{},[9])
+(9)
+
+});
+
+ace.define("ace/mode/html_worker",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/worker/mirror","ace/mode/html/saxparser"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var Mirror = require("../worker/mirror").Mirror;
+var SAXParser = require("./html/saxparser").SAXParser;
+
+var errorTypes = {
+ "expected-doctype-but-got-start-tag": "info",
+ "expected-doctype-but-got-chars": "info",
+ "non-html-root": "info"
+}
+
+var Worker = exports.Worker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(400);
+ this.context = null;
+};
+
+oop.inherits(Worker, Mirror);
+
+(function() {
+
+ this.setOptions = function(options) {
+ this.context = options.context;
+ };
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ if (!value)
+ return;
+ var parser = new SAXParser();
+ var errors = [];
+ var noop = function(){};
+ parser.contentHandler = {
+ startDocument: noop,
+ endDocument: noop,
+ startElement: noop,
+ endElement: noop,
+ characters: noop
+ };
+ parser.errorHandler = {
+ error: function(message, location, code) {
+ errors.push({
+ row: location.line,
+ column: location.column,
+ text: message,
+ type: errorTypes[code] || "error"
+ });
+ }
+ };
+ if (this.context)
+ parser.parseFragment(value, this.context);
+ else
+ parser.parse(value);
+ this.sender.emit("error", errors);
+ };
+
+}).call(Worker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-javascript.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-javascript.js
new file mode 100644
index 00000000..3a71fd4e
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-javascript.js
@@ -0,0 +1,12528 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/javascript/jshint",["require","exports","module"], function(require, exports, module) {
+module.exports = (function outer (modules, cache, entry) {
+ var previousRequire = typeof require == "function" && require;
+ function newRequire(name, jumped){
+ if(!cache[name]) {
+ if(!modules[name]) {
+ var currentRequire = typeof require == "function" && require;
+ if (!jumped && currentRequire) return currentRequire(name, true);
+ if (previousRequire) return previousRequire(name, true);
+ var err = new Error('Cannot find module \'' + name + '\'');
+ err.code = 'MODULE_NOT_FOUND';
+ throw err;
+ }
+ var m = cache[name] = {exports:{}};
+ modules[name][0].call(m.exports, function(x){
+ var id = modules[name][1][x];
+ return newRequire(id ? id : x);
+ },m,m.exports,outer,modules,cache,entry);
+ }
+ return cache[name].exports;
+ }
+ for(var i=0;i<entry.length;i++) newRequire(entry[i]);
+ return newRequire(entry[0]);
+})
+({"/node_modules/browserify/node_modules/events/events.js":[function(_dereq_,module,exports){
+
+function EventEmitter() {
+ this._events = this._events || {};
+ this._maxListeners = this._maxListeners || undefined;
+}
+module.exports = EventEmitter;
+EventEmitter.EventEmitter = EventEmitter;
+
+EventEmitter.prototype._events = undefined;
+EventEmitter.prototype._maxListeners = undefined;
+EventEmitter.defaultMaxListeners = 10;
+EventEmitter.prototype.setMaxListeners = function(n) {
+ if (!isNumber(n) || n < 0 || isNaN(n))
+ throw TypeError('n must be a positive number');
+ this._maxListeners = n;
+ return this;
+};
+
+EventEmitter.prototype.emit = function(type) {
+ var er, handler, len, args, i, listeners;
+
+ if (!this._events)
+ this._events = {};
+ if (type === 'error') {
+ if (!this._events.error ||
+ (isObject(this._events.error) && !this._events.error.length)) {
+ er = arguments[1];
+ if (er instanceof Error) {
+ throw er; // Unhandled 'error' event
+ }
+ throw TypeError('Uncaught, unspecified "error" event.');
+ }
+ }
+
+ handler = this._events[type];
+
+ if (isUndefined(handler))
+ return false;
+
+ if (isFunction(handler)) {
+ switch (arguments.length) {
+ case 1:
+ handler.call(this);
+ break;
+ case 2:
+ handler.call(this, arguments[1]);
+ break;
+ case 3:
+ handler.call(this, arguments[1], arguments[2]);
+ break;
+ default:
+ len = arguments.length;
+ args = new Array(len - 1);
+ for (i = 1; i < len; i++)
+ args[i - 1] = arguments[i];
+ handler.apply(this, args);
+ }
+ } else if (isObject(handler)) {
+ len = arguments.length;
+ args = new Array(len - 1);
+ for (i = 1; i < len; i++)
+ args[i - 1] = arguments[i];
+
+ listeners = handler.slice();
+ len = listeners.length;
+ for (i = 0; i < len; i++)
+ listeners[i].apply(this, args);
+ }
+
+ return true;
+};
+
+EventEmitter.prototype.addListener = function(type, listener) {
+ var m;
+
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ if (!this._events)
+ this._events = {};
+ if (this._events.newListener)
+ this.emit('newListener', type,
+ isFunction(listener.listener) ?
+ listener.listener : listener);
+
+ if (!this._events[type])
+ this._events[type] = listener;
+ else if (isObject(this._events[type]))
+ this._events[type].push(listener);
+ else
+ this._events[type] = [this._events[type], listener];
+ if (isObject(this._events[type]) && !this._events[type].warned) {
+ var m;
+ if (!isUndefined(this._maxListeners)) {
+ m = this._maxListeners;
+ } else {
+ m = EventEmitter.defaultMaxListeners;
+ }
+
+ if (m && m > 0 && this._events[type].length > m) {
+ this._events[type].warned = true;
+ console.error('(node) warning: possible EventEmitter memory ' +
+ 'leak detected. %d listeners added. ' +
+ 'Use emitter.setMaxListeners() to increase limit.',
+ this._events[type].length);
+ if (typeof console.trace === 'function') {
+ console.trace();
+ }
+ }
+ }
+
+ return this;
+};
+
+EventEmitter.prototype.on = EventEmitter.prototype.addListener;
+
+EventEmitter.prototype.once = function(type, listener) {
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ var fired = false;
+
+ function g() {
+ this.removeListener(type, g);
+
+ if (!fired) {
+ fired = true;
+ listener.apply(this, arguments);
+ }
+ }
+
+ g.listener = listener;
+ this.on(type, g);
+
+ return this;
+};
+EventEmitter.prototype.removeListener = function(type, listener) {
+ var list, position, length, i;
+
+ if (!isFunction(listener))
+ throw TypeError('listener must be a function');
+
+ if (!this._events || !this._events[type])
+ return this;
+
+ list = this._events[type];
+ length = list.length;
+ position = -1;
+
+ if (list === listener ||
+ (isFunction(list.listener) && list.listener === listener)) {
+ delete this._events[type];
+ if (this._events.removeListener)
+ this.emit('removeListener', type, listener);
+
+ } else if (isObject(list)) {
+ for (i = length; i-- > 0;) {
+ if (list[i] === listener ||
+ (list[i].listener && list[i].listener === listener)) {
+ position = i;
+ break;
+ }
+ }
+
+ if (position < 0)
+ return this;
+
+ if (list.length === 1) {
+ list.length = 0;
+ delete this._events[type];
+ } else {
+ list.splice(position, 1);
+ }
+
+ if (this._events.removeListener)
+ this.emit('removeListener', type, listener);
+ }
+
+ return this;
+};
+
+EventEmitter.prototype.removeAllListeners = function(type) {
+ var key, listeners;
+
+ if (!this._events)
+ return this;
+ if (!this._events.removeListener) {
+ if (arguments.length === 0)
+ this._events = {};
+ else if (this._events[type])
+ delete this._events[type];
+ return this;
+ }
+ if (arguments.length === 0) {
+ for (key in this._events) {
+ if (key === 'removeListener') continue;
+ this.removeAllListeners(key);
+ }
+ this.removeAllListeners('removeListener');
+ this._events = {};
+ return this;
+ }
+
+ listeners = this._events[type];
+
+ if (isFunction(listeners)) {
+ this.removeListener(type, listeners);
+ } else {
+ while (listeners.length)
+ this.removeListener(type, listeners[listeners.length - 1]);
+ }
+ delete this._events[type];
+
+ return this;
+};
+
+EventEmitter.prototype.listeners = function(type) {
+ var ret;
+ if (!this._events || !this._events[type])
+ ret = [];
+ else if (isFunction(this._events[type]))
+ ret = [this._events[type]];
+ else
+ ret = this._events[type].slice();
+ return ret;
+};
+
+EventEmitter.listenerCount = function(emitter, type) {
+ var ret;
+ if (!emitter._events || !emitter._events[type])
+ ret = 0;
+ else if (isFunction(emitter._events[type]))
+ ret = 1;
+ else
+ ret = emitter._events[type].length;
+ return ret;
+};
+
+function isFunction(arg) {
+ return typeof arg === 'function';
+}
+
+function isNumber(arg) {
+ return typeof arg === 'number';
+}
+
+function isObject(arg) {
+ return typeof arg === 'object' && arg !== null;
+}
+
+function isUndefined(arg) {
+ return arg === void 0;
+}
+
+},{}],"/node_modules/jshint/data/ascii-identifier-data.js":[function(_dereq_,module,exports){
+var identifierStartTable = [];
+
+for (var i = 0; i < 128; i++) {
+ identifierStartTable[i] =
+ i === 36 || // $
+ i >= 65 && i <= 90 || // A-Z
+ i === 95 || // _
+ i >= 97 && i <= 122; // a-z
+}
+
+var identifierPartTable = [];
+
+for (var i = 0; i < 128; i++) {
+ identifierPartTable[i] =
+ identifierStartTable[i] || // $, _, A-Z, a-z
+ i >= 48 && i <= 57; // 0-9
+}
+
+module.exports = {
+ asciiIdentifierStartTable: identifierStartTable,
+ asciiIdentifierPartTable: identifierPartTable
+};
+
+},{}],"/node_modules/jshint/lodash.js":[function(_dereq_,module,exports){
+(function (global){
+;(function() {
+
+ var undefined;
+
+ var VERSION = '3.7.0';
+
+ var FUNC_ERROR_TEXT = 'Expected a function';
+
+ var argsTag = '[object Arguments]',
+ arrayTag = '[object Array]',
+ boolTag = '[object Boolean]',
+ dateTag = '[object Date]',
+ errorTag = '[object Error]',
+ funcTag = '[object Function]',
+ mapTag = '[object Map]',
+ numberTag = '[object Number]',
+ objectTag = '[object Object]',
+ regexpTag = '[object RegExp]',
+ setTag = '[object Set]',
+ stringTag = '[object String]',
+ weakMapTag = '[object WeakMap]';
+
+ var arrayBufferTag = '[object ArrayBuffer]',
+ float32Tag = '[object Float32Array]',
+ float64Tag = '[object Float64Array]',
+ int8Tag = '[object Int8Array]',
+ int16Tag = '[object Int16Array]',
+ int32Tag = '[object Int32Array]',
+ uint8Tag = '[object Uint8Array]',
+ uint8ClampedTag = '[object Uint8ClampedArray]',
+ uint16Tag = '[object Uint16Array]',
+ uint32Tag = '[object Uint32Array]';
+
+ var reIsDeepProp = /\.|\[(?:[^[\]]+|(["'])(?:(?!\1)[^\n\\]|\\.)*?)\1\]/,
+ reIsPlainProp = /^\w*$/,
+ rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g;
+
+ var reRegExpChars = /[.*+?^${}()|[\]\/\\]/g,
+ reHasRegExpChars = RegExp(reRegExpChars.source);
+
+ var reEscapeChar = /\\(\\)?/g;
+
+ var reFlags = /\w*$/;
+
+ var reIsHostCtor = /^\[object .+?Constructor\]$/;
+
+ var typedArrayTags = {};
+ typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =
+ typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =
+ typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =
+ typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =
+ typedArrayTags[uint32Tag] = true;
+ typedArrayTags[argsTag] = typedArrayTags[arrayTag] =
+ typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =
+ typedArrayTags[dateTag] = typedArrayTags[errorTag] =
+ typedArrayTags[funcTag] = typedArrayTags[mapTag] =
+ typedArrayTags[numberTag] = typedArrayTags[objectTag] =
+ typedArrayTags[regexpTag] = typedArrayTags[setTag] =
+ typedArrayTags[stringTag] = typedArrayTags[weakMapTag] = false;
+
+ var cloneableTags = {};
+ cloneableTags[argsTag] = cloneableTags[arrayTag] =
+ cloneableTags[arrayBufferTag] = cloneableTags[boolTag] =
+ cloneableTags[dateTag] = cloneableTags[float32Tag] =
+ cloneableTags[float64Tag] = cloneableTags[int8Tag] =
+ cloneableTags[int16Tag] = cloneableTags[int32Tag] =
+ cloneableTags[numberTag] = cloneableTags[objectTag] =
+ cloneableTags[regexpTag] = cloneableTags[stringTag] =
+ cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =
+ cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
+ cloneableTags[errorTag] = cloneableTags[funcTag] =
+ cloneableTags[mapTag] = cloneableTags[setTag] =
+ cloneableTags[weakMapTag] = false;
+
+ var objectTypes = {
+ 'function': true,
+ 'object': true
+ };
+
+ var freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports;
+
+ var freeModule = objectTypes[typeof module] && module && !module.nodeType && module;
+
+ var freeGlobal = freeExports && freeModule && typeof global == 'object' && global && global.Object && global;
+
+ var freeSelf = objectTypes[typeof self] && self && self.Object && self;
+
+ var freeWindow = objectTypes[typeof window] && window && window.Object && window;
+
+ var moduleExports = freeModule && freeModule.exports === freeExports && freeExports;
+
+ var root = freeGlobal || ((freeWindow !== (this && this.window)) && freeWindow) || freeSelf || this;
+
+ function baseFindIndex(array, predicate, fromRight) {
+ var length = array.length,
+ index = fromRight ? length : -1;
+
+ while ((fromRight ? index-- : ++index < length)) {
+ if (predicate(array[index], index, array)) {
+ return index;
+ }
+ }
+ return -1;
+ }
+
+ function baseIndexOf(array, value, fromIndex) {
+ if (value !== value) {
+ return indexOfNaN(array, fromIndex);
+ }
+ var index = fromIndex - 1,
+ length = array.length;
+
+ while (++index < length) {
+ if (array[index] === value) {
+ return index;
+ }
+ }
+ return -1;
+ }
+
+ function baseIsFunction(value) {
+ return typeof value == 'function' || false;
+ }
+
+ function baseToString(value) {
+ if (typeof value == 'string') {
+ return value;
+ }
+ return value == null ? '' : (value + '');
+ }
+
+ function indexOfNaN(array, fromIndex, fromRight) {
+ var length = array.length,
+ index = fromIndex + (fromRight ? 0 : -1);
+
+ while ((fromRight ? index-- : ++index < length)) {
+ var other = array[index];
+ if (other !== other) {
+ return index;
+ }
+ }
+ return -1;
+ }
+
+ function isObjectLike(value) {
+ return !!value && typeof value == 'object';
+ }
+
+ var arrayProto = Array.prototype,
+ objectProto = Object.prototype;
+
+ var fnToString = Function.prototype.toString;
+
+ var hasOwnProperty = objectProto.hasOwnProperty;
+
+ var objToString = objectProto.toString;
+
+ var reIsNative = RegExp('^' +
+ escapeRegExp(objToString)
+ .replace(/toString|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
+ );
+
+ var ArrayBuffer = isNative(ArrayBuffer = root.ArrayBuffer) && ArrayBuffer,
+ bufferSlice = isNative(bufferSlice = ArrayBuffer && new ArrayBuffer(0).slice) && bufferSlice,
+ floor = Math.floor,
+ getOwnPropertySymbols = isNative(getOwnPropertySymbols = Object.getOwnPropertySymbols) && getOwnPropertySymbols,
+ getPrototypeOf = isNative(getPrototypeOf = Object.getPrototypeOf) && getPrototypeOf,
+ push = arrayProto.push,
+ preventExtensions = isNative(Object.preventExtensions = Object.preventExtensions) && preventExtensions,
+ propertyIsEnumerable = objectProto.propertyIsEnumerable,
+ Uint8Array = isNative(Uint8Array = root.Uint8Array) && Uint8Array;
+
+ var Float64Array = (function() {
+ try {
+ var func = isNative(func = root.Float64Array) && func,
+ result = new func(new ArrayBuffer(10), 0, 1) && func;
+ } catch(e) {}
+ return result;
+ }());
+
+ var nativeAssign = (function() {
+ var object = { '1': 0 },
+ func = preventExtensions && isNative(func = Object.assign) && func;
+
+ try { func(preventExtensions(object), 'xo'); } catch(e) {}
+ return !object[1] && func;
+ }());
+
+ var nativeIsArray = isNative(nativeIsArray = Array.isArray) && nativeIsArray,
+ nativeKeys = isNative(nativeKeys = Object.keys) && nativeKeys,
+ nativeMax = Math.max,
+ nativeMin = Math.min;
+
+ var NEGATIVE_INFINITY = Number.NEGATIVE_INFINITY;
+
+ var MAX_ARRAY_LENGTH = Math.pow(2, 32) - 1,
+ MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1,
+ HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1;
+
+ var FLOAT64_BYTES_PER_ELEMENT = Float64Array ? Float64Array.BYTES_PER_ELEMENT : 0;
+
+ var MAX_SAFE_INTEGER = Math.pow(2, 53) - 1;
+
+ function lodash() {
+ }
+
+ var support = lodash.support = {};
+
+ (function(x) {
+ var Ctor = function() { this.x = x; },
+ object = { '0': x, 'length': x },
+ props = [];
+
+ Ctor.prototype = { 'valueOf': x, 'y': x };
+ for (var key in new Ctor) { props.push(key); }
+
+ support.funcDecomp = /\bthis\b/.test(function() { return this; });
+
+ support.funcNames = typeof Function.name == 'string';
+
+ try {
+ support.nonEnumArgs = !propertyIsEnumerable.call(arguments, 1);
+ } catch(e) {
+ support.nonEnumArgs = true;
+ }
+ }(1, 0));
+
+ function arrayCopy(source, array) {
+ var index = -1,
+ length = source.length;
+
+ array || (array = Array(length));
+ while (++index < length) {
+ array[index] = source[index];
+ }
+ return array;
+ }
+
+ function arrayEach(array, iteratee) {
+ var index = -1,
+ length = array.length;
+
+ while (++index < length) {
+ if (iteratee(array[index], index, array) === false) {
+ break;
+ }
+ }
+ return array;
+ }
+
+ function arrayFilter(array, predicate) {
+ var index = -1,
+ length = array.length,
+ resIndex = -1,
+ result = [];
+
+ while (++index < length) {
+ var value = array[index];
+ if (predicate(value, index, array)) {
+ result[++resIndex] = value;
+ }
+ }
+ return result;
+ }
+
+ function arrayMap(array, iteratee) {
+ var index = -1,
+ length = array.length,
+ result = Array(length);
+
+ while (++index < length) {
+ result[index] = iteratee(array[index], index, array);
+ }
+ return result;
+ }
+
+ function arrayMax(array) {
+ var index = -1,
+ length = array.length,
+ result = NEGATIVE_INFINITY;
+
+ while (++index < length) {
+ var value = array[index];
+ if (value > result) {
+ result = value;
+ }
+ }
+ return result;
+ }
+
+ function arraySome(array, predicate) {
+ var index = -1,
+ length = array.length;
+
+ while (++index < length) {
+ if (predicate(array[index], index, array)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ function assignWith(object, source, customizer) {
+ var props = keys(source);
+ push.apply(props, getSymbols(source));
+
+ var index = -1,
+ length = props.length;
+
+ while (++index < length) {
+ var key = props[index],
+ value = object[key],
+ result = customizer(value, source[key], key, object, source);
+
+ if ((result === result ? (result !== value) : (value === value)) ||
+ (value === undefined && !(key in object))) {
+ object[key] = result;
+ }
+ }
+ return object;
+ }
+
+ var baseAssign = nativeAssign || function(object, source) {
+ return source == null
+ ? object
+ : baseCopy(source, getSymbols(source), baseCopy(source, keys(source), object));
+ };
+
+ function baseCopy(source, props, object) {
+ object || (object = {});
+
+ var index = -1,
+ length = props.length;
+
+ while (++index < length) {
+ var key = props[index];
+ object[key] = source[key];
+ }
+ return object;
+ }
+
+ function baseCallback(func, thisArg, argCount) {
+ var type = typeof func;
+ if (type == 'function') {
+ return thisArg === undefined
+ ? func
+ : bindCallback(func, thisArg, argCount);
+ }
+ if (func == null) {
+ return identity;
+ }
+ if (type == 'object') {
+ return baseMatches(func);
+ }
+ return thisArg === undefined
+ ? property(func)
+ : baseMatchesProperty(func, thisArg);
+ }
+
+ function baseClone(value, isDeep, customizer, key, object, stackA, stackB) {
+ var result;
+ if (customizer) {
+ result = object ? customizer(value, key, object) : customizer(value);
+ }
+ if (result !== undefined) {
+ return result;
+ }
+ if (!isObject(value)) {
+ return value;
+ }
+ var isArr = isArray(value);
+ if (isArr) {
+ result = initCloneArray(value);
+ if (!isDeep) {
+ return arrayCopy(value, result);
+ }
+ } else {
+ var tag = objToString.call(value),
+ isFunc = tag == funcTag;
+
+ if (tag == objectTag || tag == argsTag || (isFunc && !object)) {
+ result = initCloneObject(isFunc ? {} : value);
+ if (!isDeep) {
+ return baseAssign(result, value);
+ }
+ } else {
+ return cloneableTags[tag]
+ ? initCloneByTag(value, tag, isDeep)
+ : (object ? value : {});
+ }
+ }
+ stackA || (stackA = []);
+ stackB || (stackB = []);
+
+ var length = stackA.length;
+ while (length--) {
+ if (stackA[length] == value) {
+ return stackB[length];
+ }
+ }
+ stackA.push(value);
+ stackB.push(result);
+
+ (isArr ? arrayEach : baseForOwn)(value, function(subValue, key) {
+ result[key] = baseClone(subValue, isDeep, customizer, key, value, stackA, stackB);
+ });
+ return result;
+ }
+
+ var baseEach = createBaseEach(baseForOwn);
+
+ function baseFilter(collection, predicate) {
+ var result = [];
+ baseEach(collection, function(value, index, collection) {
+ if (predicate(value, index, collection)) {
+ result.push(value);
+ }
+ });
+ return result;
+ }
+
+ var baseFor = createBaseFor();
+
+ function baseForIn(object, iteratee) {
+ return baseFor(object, iteratee, keysIn);
+ }
+
+ function baseForOwn(object, iteratee) {
+ return baseFor(object, iteratee, keys);
+ }
+
+ function baseGet(object, path, pathKey) {
+ if (object == null) {
+ return;
+ }
+ if (pathKey !== undefined && pathKey in toObject(object)) {
+ path = [pathKey];
+ }
+ var index = -1,
+ length = path.length;
+
+ while (object != null && ++index < length) {
+ var result = object = object[path[index]];
+ }
+ return result;
+ }
+
+ function baseIsEqual(value, other, customizer, isLoose, stackA, stackB) {
+ if (value === other) {
+ return value !== 0 || (1 / value == 1 / other);
+ }
+ var valType = typeof value,
+ othType = typeof other;
+
+ if ((valType != 'function' && valType != 'object' && othType != 'function' && othType != 'object') ||
+ value == null || other == null) {
+ return value !== value && other !== other;
+ }
+ return baseIsEqualDeep(value, other, baseIsEqual, customizer, isLoose, stackA, stackB);
+ }
+
+ function baseIsEqualDeep(object, other, equalFunc, customizer, isLoose, stackA, stackB) {
+ var objIsArr = isArray(object),
+ othIsArr = isArray(other),
+ objTag = arrayTag,
+ othTag = arrayTag;
+
+ if (!objIsArr) {
+ objTag = objToString.call(object);
+ if (objTag == argsTag) {
+ objTag = objectTag;
+ } else if (objTag != objectTag) {
+ objIsArr = isTypedArray(object);
+ }
+ }
+ if (!othIsArr) {
+ othTag = objToString.call(other);
+ if (othTag == argsTag) {
+ othTag = objectTag;
+ } else if (othTag != objectTag) {
+ othIsArr = isTypedArray(other);
+ }
+ }
+ var objIsObj = objTag == objectTag,
+ othIsObj = othTag == objectTag,
+ isSameTag = objTag == othTag;
+
+ if (isSameTag && !(objIsArr || objIsObj)) {
+ return equalByTag(object, other, objTag);
+ }
+ if (!isLoose) {
+ var valWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),
+ othWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');
+
+ if (valWrapped || othWrapped) {
+ return equalFunc(valWrapped ? object.value() : object, othWrapped ? other.value() : other, customizer, isLoose, stackA, stackB);
+ }
+ }
+ if (!isSameTag) {
+ return false;
+ }
+ stackA || (stackA = []);
+ stackB || (stackB = []);
+
+ var length = stackA.length;
+ while (length--) {
+ if (stackA[length] == object) {
+ return stackB[length] == other;
+ }
+ }
+ stackA.push(object);
+ stackB.push(other);
+
+ var result = (objIsArr ? equalArrays : equalObjects)(object, other, equalFunc, customizer, isLoose, stackA, stackB);
+
+ stackA.pop();
+ stackB.pop();
+
+ return result;
+ }
+
+ function baseIsMatch(object, props, values, strictCompareFlags, customizer) {
+ var index = -1,
+ length = props.length,
+ noCustomizer = !customizer;
+
+ while (++index < length) {
+ if ((noCustomizer && strictCompareFlags[index])
+ ? values[index] !== object[props[index]]
+ : !(props[index] in object)
+ ) {
+ return false;
+ }
+ }
+ index = -1;
+ while (++index < length) {
+ var key = props[index],
+ objValue = object[key],
+ srcValue = values[index];
+
+ if (noCustomizer && strictCompareFlags[index]) {
+ var result = objValue !== undefined || (key in object);
+ } else {
+ result = customizer ? customizer(objValue, srcValue, key) : undefined;
+ if (result === undefined) {
+ result = baseIsEqual(srcValue, objValue, customizer, true);
+ }
+ }
+ if (!result) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+ function baseMatches(source) {
+ var props = keys(source),
+ length = props.length;
+
+ if (!length) {
+ return constant(true);
+ }
+ if (length == 1) {
+ var key = props[0],
+ value = source[key];
+
+ if (isStrictComparable(value)) {
+ return function(object) {
+ if (object == null) {
+ return false;
+ }
+ return object[key] === value && (value !== undefined || (key in toObject(object)));
+ };
+ }
+ }
+ var values = Array(length),
+ strictCompareFlags = Array(length);
+
+ while (length--) {
+ value = source[props[length]];
+ values[length] = value;
+ strictCompareFlags[length] = isStrictComparable(value);
+ }
+ return function(object) {
+ return object != null && baseIsMatch(toObject(object), props, values, strictCompareFlags);
+ };
+ }
+
+ function baseMatchesProperty(path, value) {
+ var isArr = isArray(path),
+ isCommon = isKey(path) && isStrictComparable(value),
+ pathKey = (path + '');
+
+ path = toPath(path);
+ return function(object) {
+ if (object == null) {
+ return false;
+ }
+ var key = pathKey;
+ object = toObject(object);
+ if ((isArr || !isCommon) && !(key in object)) {
+ object = path.length == 1 ? object : baseGet(object, baseSlice(path, 0, -1));
+ if (object == null) {
+ return false;
+ }
+ key = last(path);
+ object = toObject(object);
+ }
+ return object[key] === value
+ ? (value !== undefined || (key in object))
+ : baseIsEqual(value, object[key], null, true);
+ };
+ }
+
+ function baseMerge(object, source, customizer, stackA, stackB) {
+ if (!isObject(object)) {
+ return object;
+ }
+ var isSrcArr = isLength(source.length) && (isArray(source) || isTypedArray(source));
+ if (!isSrcArr) {
+ var props = keys(source);
+ push.apply(props, getSymbols(source));
+ }
+ arrayEach(props || source, function(srcValue, key) {
+ if (props) {
+ key = srcValue;
+ srcValue = source[key];
+ }
+ if (isObjectLike(srcValue)) {
+ stackA || (stackA = []);
+ stackB || (stackB = []);
+ baseMergeDeep(object, source, key, baseMerge, customizer, stackA, stackB);
+ }
+ else {
+ var value = object[key],
+ result = customizer ? customizer(value, srcValue, key, object, source) : undefined,
+ isCommon = result === undefined;
+
+ if (isCommon) {
+ result = srcValue;
+ }
+ if ((isSrcArr || result !== undefined) &&
+ (isCommon || (result === result ? (result !== value) : (value === value)))) {
+ object[key] = result;
+ }
+ }
+ });
+ return object;
+ }
+
+ function baseMergeDeep(object, source, key, mergeFunc, customizer, stackA, stackB) {
+ var length = stackA.length,
+ srcValue = source[key];
+
+ while (length--) {
+ if (stackA[length] == srcValue) {
+ object[key] = stackB[length];
+ return;
+ }
+ }
+ var value = object[key],
+ result = customizer ? customizer(value, srcValue, key, object, source) : undefined,
+ isCommon = result === undefined;
+
+ if (isCommon) {
+ result = srcValue;
+ if (isLength(srcValue.length) && (isArray(srcValue) || isTypedArray(srcValue))) {
+ result = isArray(value)
+ ? value
+ : (getLength(value) ? arrayCopy(value) : []);
+ }
+ else if (isPlainObject(srcValue) || isArguments(srcValue)) {
+ result = isArguments(value)
+ ? toPlainObject(value)
+ : (isPlainObject(value) ? value : {});
+ }
+ else {
+ isCommon = false;
+ }
+ }
+ stackA.push(srcValue);
+ stackB.push(result);
+
+ if (isCommon) {
+ object[key] = mergeFunc(result, srcValue, customizer, stackA, stackB);
+ } else if (result === result ? (result !== value) : (value === value)) {
+ object[key] = result;
+ }
+ }
+
+ function baseProperty(key) {
+ return function(object) {
+ return object == null ? undefined : object[key];
+ };
+ }
+
+ function basePropertyDeep(path) {
+ var pathKey = (path + '');
+ path = toPath(path);
+ return function(object) {
+ return baseGet(object, path, pathKey);
+ };
+ }
+
+ function baseSlice(array, start, end) {
+ var index = -1,
+ length = array.length;
+
+ start = start == null ? 0 : (+start || 0);
+ if (start < 0) {
+ start = -start > length ? 0 : (length + start);
+ }
+ end = (end === undefined || end > length) ? length : (+end || 0);
+ if (end < 0) {
+ end += length;
+ }
+ length = start > end ? 0 : ((end - start) >>> 0);
+ start >>>= 0;
+
+ var result = Array(length);
+ while (++index < length) {
+ result[index] = array[index + start];
+ }
+ return result;
+ }
+
+ function baseSome(collection, predicate) {
+ var result;
+
+ baseEach(collection, function(value, index, collection) {
+ result = predicate(value, index, collection);
+ return !result;
+ });
+ return !!result;
+ }
+
+ function baseValues(object, props) {
+ var index = -1,
+ length = props.length,
+ result = Array(length);
+
+ while (++index < length) {
+ result[index] = object[props[index]];
+ }
+ return result;
+ }
+
+ function binaryIndex(array, value, retHighest) {
+ var low = 0,
+ high = array ? array.length : low;
+
+ if (typeof value == 'number' && value === value && high <= HALF_MAX_ARRAY_LENGTH) {
+ while (low < high) {
+ var mid = (low + high) >>> 1,
+ computed = array[mid];
+
+ if (retHighest ? (computed <= value) : (computed < value)) {
+ low = mid + 1;
+ } else {
+ high = mid;
+ }
+ }
+ return high;
+ }
+ return binaryIndexBy(array, value, identity, retHighest);
+ }
+
+ function binaryIndexBy(array, value, iteratee, retHighest) {
+ value = iteratee(value);
+
+ var low = 0,
+ high = array ? array.length : 0,
+ valIsNaN = value !== value,
+ valIsUndef = value === undefined;
+
+ while (low < high) {
+ var mid = floor((low + high) / 2),
+ computed = iteratee(array[mid]),
+ isReflexive = computed === computed;
+
+ if (valIsNaN) {
+ var setLow = isReflexive || retHighest;
+ } else if (valIsUndef) {
+ setLow = isReflexive && (retHighest || computed !== undefined);
+ } else {
+ setLow = retHighest ? (computed <= value) : (computed < value);
+ }
+ if (setLow) {
+ low = mid + 1;
+ } else {
+ high = mid;
+ }
+ }
+ return nativeMin(high, MAX_ARRAY_INDEX);
+ }
+
+ function bindCallback(func, thisArg, argCount) {
+ if (typeof func != 'function') {
+ return identity;
+ }
+ if (thisArg === undefined) {
+ return func;
+ }
+ switch (argCount) {
+ case 1: return function(value) {
+ return func.call(thisArg, value);
+ };
+ case 3: return function(value, index, collection) {
+ return func.call(thisArg, value, index, collection);
+ };
+ case 4: return function(accumulator, value, index, collection) {
+ return func.call(thisArg, accumulator, value, index, collection);
+ };
+ case 5: return function(value, other, key, object, source) {
+ return func.call(thisArg, value, other, key, object, source);
+ };
+ }
+ return function() {
+ return func.apply(thisArg, arguments);
+ };
+ }
+
+ function bufferClone(buffer) {
+ return bufferSlice.call(buffer, 0);
+ }
+ if (!bufferSlice) {
+ bufferClone = !(ArrayBuffer && Uint8Array) ? constant(null) : function(buffer) {
+ var byteLength = buffer.byteLength,
+ floatLength = Float64Array ? floor(byteLength / FLOAT64_BYTES_PER_ELEMENT) : 0,
+ offset = floatLength * FLOAT64_BYTES_PER_ELEMENT,
+ result = new ArrayBuffer(byteLength);
+
+ if (floatLength) {
+ var view = new Float64Array(result, 0, floatLength);
+ view.set(new Float64Array(buffer, 0, floatLength));
+ }
+ if (byteLength != offset) {
+ view = new Uint8Array(result, offset);
+ view.set(new Uint8Array(buffer, offset));
+ }
+ return result;
+ };
+ }
+
+ function createAssigner(assigner) {
+ return restParam(function(object, sources) {
+ var index = -1,
+ length = object == null ? 0 : sources.length,
+ customizer = length > 2 && sources[length - 2],
+ guard = length > 2 && sources[2],
+ thisArg = length > 1 && sources[length - 1];
+
+ if (typeof customizer == 'function') {
+ customizer = bindCallback(customizer, thisArg, 5);
+ length -= 2;
+ } else {
+ customizer = typeof thisArg == 'function' ? thisArg : null;
+ length -= (customizer ? 1 : 0);
+ }
+ if (guard && isIterateeCall(sources[0], sources[1], guard)) {
+ customizer = length < 3 ? null : customizer;
+ length = 1;
+ }
+ while (++index < length) {
+ var source = sources[index];
+ if (source) {
+ assigner(object, source, customizer);
+ }
+ }
+ return object;
+ });
+ }
+
+ function createBaseEach(eachFunc, fromRight) {
+ return function(collection, iteratee) {
+ var length = collection ? getLength(collection) : 0;
+ if (!isLength(length)) {
+ return eachFunc(collection, iteratee);
+ }
+ var index = fromRight ? length : -1,
+ iterable = toObject(collection);
+
+ while ((fromRight ? index-- : ++index < length)) {
+ if (iteratee(iterable[index], index, iterable) === false) {
+ break;
+ }
+ }
+ return collection;
+ };
+ }
+
+ function createBaseFor(fromRight) {
+ return function(object, iteratee, keysFunc) {
+ var iterable = toObject(object),
+ props = keysFunc(object),
+ length = props.length,
+ index = fromRight ? length : -1;
+
+ while ((fromRight ? index-- : ++index < length)) {
+ var key = props[index];
+ if (iteratee(iterable[key], key, iterable) === false) {
+ break;
+ }
+ }
+ return object;
+ };
+ }
+
+ function createFindIndex(fromRight) {
+ return function(array, predicate, thisArg) {
+ if (!(array && array.length)) {
+ return -1;
+ }
+ predicate = getCallback(predicate, thisArg, 3);
+ return baseFindIndex(array, predicate, fromRight);
+ };
+ }
+
+ function createForEach(arrayFunc, eachFunc) {
+ return function(collection, iteratee, thisArg) {
+ return (typeof iteratee == 'function' && thisArg === undefined && isArray(collection))
+ ? arrayFunc(collection, iteratee)
+ : eachFunc(collection, bindCallback(iteratee, thisArg, 3));
+ };
+ }
+
+ function equalArrays(array, other, equalFunc, customizer, isLoose, stackA, stackB) {
+ var index = -1,
+ arrLength = array.length,
+ othLength = other.length,
+ result = true;
+
+ if (arrLength != othLength && !(isLoose && othLength > arrLength)) {
+ return false;
+ }
+ while (result && ++index < arrLength) {
+ var arrValue = array[index],
+ othValue = other[index];
+
+ result = undefined;
+ if (customizer) {
+ result = isLoose
+ ? customizer(othValue, arrValue, index)
+ : customizer(arrValue, othValue, index);
+ }
+ if (result === undefined) {
+ if (isLoose) {
+ var othIndex = othLength;
+ while (othIndex--) {
+ othValue = other[othIndex];
+ result = (arrValue && arrValue === othValue) || equalFunc(arrValue, othValue, customizer, isLoose, stackA, stackB);
+ if (result) {
+ break;
+ }
+ }
+ } else {
+ result = (arrValue && arrValue === othValue) || equalFunc(arrValue, othValue, customizer, isLoose, stackA, stackB);
+ }
+ }
+ }
+ return !!result;
+ }
+
+ function equalByTag(object, other, tag) {
+ switch (tag) {
+ case boolTag:
+ case dateTag:
+ return +object == +other;
+
+ case errorTag:
+ return object.name == other.name && object.message == other.message;
+
+ case numberTag:
+ return (object != +object)
+ ? other != +other
+ : (object == 0 ? ((1 / object) == (1 / other)) : object == +other);
+
+ case regexpTag:
+ case stringTag:
+ return object == (other + '');
+ }
+ return false;
+ }
+
+ function equalObjects(object, other, equalFunc, customizer, isLoose, stackA, stackB) {
+ var objProps = keys(object),
+ objLength = objProps.length,
+ othProps = keys(other),
+ othLength = othProps.length;
+
+ if (objLength != othLength && !isLoose) {
+ return false;
+ }
+ var skipCtor = isLoose,
+ index = -1;
+
+ while (++index < objLength) {
+ var key = objProps[index],
+ result = isLoose ? key in other : hasOwnProperty.call(other, key);
+
+ if (result) {
+ var objValue = object[key],
+ othValue = other[key];
+
+ result = undefined;
+ if (customizer) {
+ result = isLoose
+ ? customizer(othValue, objValue, key)
+ : customizer(objValue, othValue, key);
+ }
+ if (result === undefined) {
+ result = (objValue && objValue === othValue) || equalFunc(objValue, othValue, customizer, isLoose, stackA, stackB);
+ }
+ }
+ if (!result) {
+ return false;
+ }
+ skipCtor || (skipCtor = key == 'constructor');
+ }
+ if (!skipCtor) {
+ var objCtor = object.constructor,
+ othCtor = other.constructor;
+
+ if (objCtor != othCtor &&
+ ('constructor' in object && 'constructor' in other) &&
+ !(typeof objCtor == 'function' && objCtor instanceof objCtor &&
+ typeof othCtor == 'function' && othCtor instanceof othCtor)) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+ function getCallback(func, thisArg, argCount) {
+ var result = lodash.callback || callback;
+ result = result === callback ? baseCallback : result;
+ return argCount ? result(func, thisArg, argCount) : result;
+ }
+
+ function getIndexOf(collection, target, fromIndex) {
+ var result = lodash.indexOf || indexOf;
+ result = result === indexOf ? baseIndexOf : result;
+ return collection ? result(collection, target, fromIndex) : result;
+ }
+
+ var getLength = baseProperty('length');
+
+ var getSymbols = !getOwnPropertySymbols ? constant([]) : function(object) {
+ return getOwnPropertySymbols(toObject(object));
+ };
+
+ function initCloneArray(array) {
+ var length = array.length,
+ result = new array.constructor(length);
+
+ if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {
+ result.index = array.index;
+ result.input = array.input;
+ }
+ return result;
+ }
+
+ function initCloneObject(object) {
+ var Ctor = object.constructor;
+ if (!(typeof Ctor == 'function' && Ctor instanceof Ctor)) {
+ Ctor = Object;
+ }
+ return new Ctor;
+ }
+
+ function initCloneByTag(object, tag, isDeep) {
+ var Ctor = object.constructor;
+ switch (tag) {
+ case arrayBufferTag:
+ return bufferClone(object);
+
+ case boolTag:
+ case dateTag:
+ return new Ctor(+object);
+
+ case float32Tag: case float64Tag:
+ case int8Tag: case int16Tag: case int32Tag:
+ case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag:
+ var buffer = object.buffer;
+ return new Ctor(isDeep ? bufferClone(buffer) : buffer, object.byteOffset, object.length);
+
+ case numberTag:
+ case stringTag:
+ return new Ctor(object);
+
+ case regexpTag:
+ var result = new Ctor(object.source, reFlags.exec(object));
+ result.lastIndex = object.lastIndex;
+ }
+ return result;
+ }
+
+ function isIndex(value, length) {
+ value = +value;
+ length = length == null ? MAX_SAFE_INTEGER : length;
+ return value > -1 && value % 1 == 0 && value < length;
+ }
+
+ function isIterateeCall(value, index, object) {
+ if (!isObject(object)) {
+ return false;
+ }
+ var type = typeof index;
+ if (type == 'number') {
+ var length = getLength(object),
+ prereq = isLength(length) && isIndex(index, length);
+ } else {
+ prereq = type == 'string' && index in object;
+ }
+ if (prereq) {
+ var other = object[index];
+ return value === value ? (value === other) : (other !== other);
+ }
+ return false;
+ }
+
+ function isKey(value, object) {
+ var type = typeof value;
+ if ((type == 'string' && reIsPlainProp.test(value)) || type == 'number') {
+ return true;
+ }
+ if (isArray(value)) {
+ return false;
+ }
+ var result = !reIsDeepProp.test(value);
+ return result || (object != null && value in toObject(object));
+ }
+
+ function isLength(value) {
+ return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
+ }
+
+ function isStrictComparable(value) {
+ return value === value && (value === 0 ? ((1 / value) > 0) : !isObject(value));
+ }
+
+ function shimIsPlainObject(value) {
+ var Ctor,
+ support = lodash.support;
+
+ if (!(isObjectLike(value) && objToString.call(value) == objectTag) ||
+ (!hasOwnProperty.call(value, 'constructor') &&
+ (Ctor = value.constructor, typeof Ctor == 'function' && !(Ctor instanceof Ctor)))) {
+ return false;
+ }
+ var result;
+ baseForIn(value, function(subValue, key) {
+ result = key;
+ });
+ return result === undefined || hasOwnProperty.call(value, result);
+ }
+
+ function shimKeys(object) {
+ var props = keysIn(object),
+ propsLength = props.length,
+ length = propsLength && object.length,
+ support = lodash.support;
+
+ var allowIndexes = length && isLength(length) &&
+ (isArray(object) || (support.nonEnumArgs && isArguments(object)));
+
+ var index = -1,
+ result = [];
+
+ while (++index < propsLength) {
+ var key = props[index];
+ if ((allowIndexes && isIndex(key, length)) || hasOwnProperty.call(object, key)) {
+ result.push(key);
+ }
+ }
+ return result;
+ }
+
+ function toObject(value) {
+ return isObject(value) ? value : Object(value);
+ }
+
+ function toPath(value) {
+ if (isArray(value)) {
+ return value;
+ }
+ var result = [];
+ baseToString(value).replace(rePropName, function(match, number, quote, string) {
+ result.push(quote ? string.replace(reEscapeChar, '$1') : (number || match));
+ });
+ return result;
+ }
+
+ var findLastIndex = createFindIndex(true);
+
+ function indexOf(array, value, fromIndex) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return -1;
+ }
+ if (typeof fromIndex == 'number') {
+ fromIndex = fromIndex < 0 ? nativeMax(length + fromIndex, 0) : fromIndex;
+ } else if (fromIndex) {
+ var index = binaryIndex(array, value),
+ other = array[index];
+
+ if (value === value ? (value === other) : (other !== other)) {
+ return index;
+ }
+ return -1;
+ }
+ return baseIndexOf(array, value, fromIndex || 0);
+ }
+
+ function last(array) {
+ var length = array ? array.length : 0;
+ return length ? array[length - 1] : undefined;
+ }
+
+ function slice(array, start, end) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (end && typeof end != 'number' && isIterateeCall(array, start, end)) {
+ start = 0;
+ end = length;
+ }
+ return baseSlice(array, start, end);
+ }
+
+ function unzip(array) {
+ var index = -1,
+ length = (array && array.length && arrayMax(arrayMap(array, getLength))) >>> 0,
+ result = Array(length);
+
+ while (++index < length) {
+ result[index] = arrayMap(array, baseProperty(index));
+ }
+ return result;
+ }
+
+ var zip = restParam(unzip);
+
+ var forEach = createForEach(arrayEach, baseEach);
+
+ function includes(collection, target, fromIndex, guard) {
+ var length = collection ? getLength(collection) : 0;
+ if (!isLength(length)) {
+ collection = values(collection);
+ length = collection.length;
+ }
+ if (!length) {
+ return false;
+ }
+ if (typeof fromIndex != 'number' || (guard && isIterateeCall(target, fromIndex, guard))) {
+ fromIndex = 0;
+ } else {
+ fromIndex = fromIndex < 0 ? nativeMax(length + fromIndex, 0) : (fromIndex || 0);
+ }
+ return (typeof collection == 'string' || !isArray(collection) && isString(collection))
+ ? (fromIndex < length && collection.indexOf(target, fromIndex) > -1)
+ : (getIndexOf(collection, target, fromIndex) > -1);
+ }
+
+ function reject(collection, predicate, thisArg) {
+ var func = isArray(collection) ? arrayFilter : baseFilter;
+ predicate = getCallback(predicate, thisArg, 3);
+ return func(collection, function(value, index, collection) {
+ return !predicate(value, index, collection);
+ });
+ }
+
+ function some(collection, predicate, thisArg) {
+ var func = isArray(collection) ? arraySome : baseSome;
+ if (thisArg && isIterateeCall(collection, predicate, thisArg)) {
+ predicate = null;
+ }
+ if (typeof predicate != 'function' || thisArg !== undefined) {
+ predicate = getCallback(predicate, thisArg, 3);
+ }
+ return func(collection, predicate);
+ }
+
+ function restParam(func, start) {
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ start = nativeMax(start === undefined ? (func.length - 1) : (+start || 0), 0);
+ return function() {
+ var args = arguments,
+ index = -1,
+ length = nativeMax(args.length - start, 0),
+ rest = Array(length);
+
+ while (++index < length) {
+ rest[index] = args[start + index];
+ }
+ switch (start) {
+ case 0: return func.call(this, rest);
+ case 1: return func.call(this, args[0], rest);
+ case 2: return func.call(this, args[0], args[1], rest);
+ }
+ var otherArgs = Array(start + 1);
+ index = -1;
+ while (++index < start) {
+ otherArgs[index] = args[index];
+ }
+ otherArgs[start] = rest;
+ return func.apply(this, otherArgs);
+ };
+ }
+
+ function clone(value, isDeep, customizer, thisArg) {
+ if (isDeep && typeof isDeep != 'boolean' && isIterateeCall(value, isDeep, customizer)) {
+ isDeep = false;
+ }
+ else if (typeof isDeep == 'function') {
+ thisArg = customizer;
+ customizer = isDeep;
+ isDeep = false;
+ }
+ customizer = typeof customizer == 'function' && bindCallback(customizer, thisArg, 1);
+ return baseClone(value, isDeep, customizer);
+ }
+
+ function isArguments(value) {
+ var length = isObjectLike(value) ? value.length : undefined;
+ return isLength(length) && objToString.call(value) == argsTag;
+ }
+
+ var isArray = nativeIsArray || function(value) {
+ return isObjectLike(value) && isLength(value.length) && objToString.call(value) == arrayTag;
+ };
+
+ function isEmpty(value) {
+ if (value == null) {
+ return true;
+ }
+ var length = getLength(value);
+ if (isLength(length) && (isArray(value) || isString(value) || isArguments(value) ||
+ (isObjectLike(value) && isFunction(value.splice)))) {
+ return !length;
+ }
+ return !keys(value).length;
+ }
+
+ var isFunction = !(baseIsFunction(/x/) || (Uint8Array && !baseIsFunction(Uint8Array))) ? baseIsFunction : function(value) {
+ return objToString.call(value) == funcTag;
+ };
+
+ function isObject(value) {
+ var type = typeof value;
+ return type == 'function' || (!!value && type == 'object');
+ }
+
+ function isNative(value) {
+ if (value == null) {
+ return false;
+ }
+ if (objToString.call(value) == funcTag) {
+ return reIsNative.test(fnToString.call(value));
+ }
+ return isObjectLike(value) && reIsHostCtor.test(value);
+ }
+
+ function isNumber(value) {
+ return typeof value == 'number' || (isObjectLike(value) && objToString.call(value) == numberTag);
+ }
+
+ var isPlainObject = !getPrototypeOf ? shimIsPlainObject : function(value) {
+ if (!(value && objToString.call(value) == objectTag)) {
+ return false;
+ }
+ var valueOf = value.valueOf,
+ objProto = isNative(valueOf) && (objProto = getPrototypeOf(valueOf)) && getPrototypeOf(objProto);
+
+ return objProto
+ ? (value == objProto || getPrototypeOf(value) == objProto)
+ : shimIsPlainObject(value);
+ };
+
+ function isString(value) {
+ return typeof value == 'string' || (isObjectLike(value) && objToString.call(value) == stringTag);
+ }
+
+ function isTypedArray(value) {
+ return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[objToString.call(value)];
+ }
+
+ function toPlainObject(value) {
+ return baseCopy(value, keysIn(value));
+ }
+
+ var assign = createAssigner(function(object, source, customizer) {
+ return customizer
+ ? assignWith(object, source, customizer)
+ : baseAssign(object, source);
+ });
+
+ function has(object, path) {
+ if (object == null) {
+ return false;
+ }
+ var result = hasOwnProperty.call(object, path);
+ if (!result && !isKey(path)) {
+ path = toPath(path);
+ object = path.length == 1 ? object : baseGet(object, baseSlice(path, 0, -1));
+ path = last(path);
+ result = object != null && hasOwnProperty.call(object, path);
+ }
+ return result;
+ }
+
+ var keys = !nativeKeys ? shimKeys : function(object) {
+ if (object) {
+ var Ctor = object.constructor,
+ length = object.length;
+ }
+ if ((typeof Ctor == 'function' && Ctor.prototype === object) ||
+ (typeof object != 'function' && isLength(length))) {
+ return shimKeys(object);
+ }
+ return isObject(object) ? nativeKeys(object) : [];
+ };
+
+ function keysIn(object) {
+ if (object == null) {
+ return [];
+ }
+ if (!isObject(object)) {
+ object = Object(object);
+ }
+ var length = object.length;
+ length = (length && isLength(length) &&
+ (isArray(object) || (support.nonEnumArgs && isArguments(object))) && length) || 0;
+
+ var Ctor = object.constructor,
+ index = -1,
+ isProto = typeof Ctor == 'function' && Ctor.prototype === object,
+ result = Array(length),
+ skipIndexes = length > 0;
+
+ while (++index < length) {
+ result[index] = (index + '');
+ }
+ for (var key in object) {
+ if (!(skipIndexes && isIndex(key, length)) &&
+ !(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {
+ result.push(key);
+ }
+ }
+ return result;
+ }
+
+ var merge = createAssigner(baseMerge);
+
+ function values(object) {
+ return baseValues(object, keys(object));
+ }
+
+ function escapeRegExp(string) {
+ string = baseToString(string);
+ return (string && reHasRegExpChars.test(string))
+ ? string.replace(reRegExpChars, '\\$&')
+ : string;
+ }
+
+ function callback(func, thisArg, guard) {
+ if (guard && isIterateeCall(func, thisArg, guard)) {
+ thisArg = null;
+ }
+ return baseCallback(func, thisArg);
+ }
+
+ function constant(value) {
+ return function() {
+ return value;
+ };
+ }
+
+ function identity(value) {
+ return value;
+ }
+
+ function property(path) {
+ return isKey(path) ? baseProperty(path) : basePropertyDeep(path);
+ }
+ lodash.assign = assign;
+ lodash.callback = callback;
+ lodash.constant = constant;
+ lodash.forEach = forEach;
+ lodash.keys = keys;
+ lodash.keysIn = keysIn;
+ lodash.merge = merge;
+ lodash.property = property;
+ lodash.reject = reject;
+ lodash.restParam = restParam;
+ lodash.slice = slice;
+ lodash.toPlainObject = toPlainObject;
+ lodash.unzip = unzip;
+ lodash.values = values;
+ lodash.zip = zip;
+
+ lodash.each = forEach;
+ lodash.extend = assign;
+ lodash.iteratee = callback;
+ lodash.clone = clone;
+ lodash.escapeRegExp = escapeRegExp;
+ lodash.findLastIndex = findLastIndex;
+ lodash.has = has;
+ lodash.identity = identity;
+ lodash.includes = includes;
+ lodash.indexOf = indexOf;
+ lodash.isArguments = isArguments;
+ lodash.isArray = isArray;
+ lodash.isEmpty = isEmpty;
+ lodash.isFunction = isFunction;
+ lodash.isNative = isNative;
+ lodash.isNumber = isNumber;
+ lodash.isObject = isObject;
+ lodash.isPlainObject = isPlainObject;
+ lodash.isString = isString;
+ lodash.isTypedArray = isTypedArray;
+ lodash.last = last;
+ lodash.some = some;
+
+ lodash.any = some;
+ lodash.contains = includes;
+ lodash.include = includes;
+
+ lodash.VERSION = VERSION;
+ if (freeExports && freeModule) {
+ if (moduleExports) {
+ (freeModule.exports = lodash)._ = lodash;
+ }
+ else {
+ freeExports._ = lodash;
+ }
+ }
+ else {
+ root._ = lodash;
+ }
+}.call(this));
+
+}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
+},{}],"/node_modules/jshint/src/jshint.js":[function(_dereq_,module,exports){
+
+var _ = _dereq_("../lodash");
+var events = _dereq_("events");
+var vars = _dereq_("./vars.js");
+var messages = _dereq_("./messages.js");
+var Lexer = _dereq_("./lex.js").Lexer;
+var reg = _dereq_("./reg.js");
+var state = _dereq_("./state.js").state;
+var style = _dereq_("./style.js");
+var options = _dereq_("./options.js");
+var scopeManager = _dereq_("./scope-manager.js");
+
+var JSHINT = (function() {
+ "use strict";
+
+ var api, // Extension API
+ bang = {
+ "<" : true,
+ "<=" : true,
+ "==" : true,
+ "===": true,
+ "!==": true,
+ "!=" : true,
+ ">" : true,
+ ">=" : true,
+ "+" : true,
+ "-" : true,
+ "*" : true,
+ "/" : true,
+ "%" : true
+ },
+
+ declared, // Globals that were declared using /*global ... */ syntax.
+
+ functionicity = [
+ "closure", "exception", "global", "label",
+ "outer", "unused", "var"
+ ],
+
+ functions, // All of the functions
+
+ inblock,
+ indent,
+ lookahead,
+ lex,
+ member,
+ membersOnly,
+ predefined, // Global variables defined by option
+
+ stack,
+ urls,
+
+ extraModules = [],
+ emitter = new events.EventEmitter();
+
+ function checkOption(name, t) {
+ name = name.trim();
+
+ if (/^[+-]W\d{3}$/g.test(name)) {
+ return true;
+ }
+
+ if (options.validNames.indexOf(name) === -1) {
+ if (t.type !== "jslint" && !_.has(options.removed, name)) {
+ error("E001", t, name);
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ function isString(obj) {
+ return Object.prototype.toString.call(obj) === "[object String]";
+ }
+
+ function isIdentifier(tkn, value) {
+ if (!tkn)
+ return false;
+
+ if (!tkn.identifier || tkn.value !== value)
+ return false;
+
+ return true;
+ }
+
+ function isReserved(token) {
+ if (!token.reserved) {
+ return false;
+ }
+ var meta = token.meta;
+
+ if (meta && meta.isFutureReservedWord && state.inES5()) {
+ if (!meta.es5) {
+ return false;
+ }
+ if (meta.strictOnly) {
+ if (!state.option.strict && !state.isStrict()) {
+ return false;
+ }
+ }
+
+ if (token.isProperty) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ function supplant(str, data) {
+ return str.replace(/\{([^{}]*)\}/g, function(a, b) {
+ var r = data[b];
+ return typeof r === "string" || typeof r === "number" ? r : a;
+ });
+ }
+
+ function combine(dest, src) {
+ Object.keys(src).forEach(function(name) {
+ if (_.has(JSHINT.blacklist, name)) return;
+ dest[name] = src[name];
+ });
+ }
+
+ function processenforceall() {
+ if (state.option.enforceall) {
+ for (var enforceopt in options.bool.enforcing) {
+ if (state.option[enforceopt] === undefined &&
+ !options.noenforceall[enforceopt]) {
+ state.option[enforceopt] = true;
+ }
+ }
+ for (var relaxopt in options.bool.relaxing) {
+ if (state.option[relaxopt] === undefined) {
+ state.option[relaxopt] = false;
+ }
+ }
+ }
+ }
+
+ function assume() {
+ processenforceall();
+ if (!state.option.esversion && !state.option.moz) {
+ if (state.option.es3) {
+ state.option.esversion = 3;
+ } else if (state.option.esnext) {
+ state.option.esversion = 6;
+ } else {
+ state.option.esversion = 5;
+ }
+ }
+
+ if (state.inES5()) {
+ combine(predefined, vars.ecmaIdentifiers[5]);
+ }
+
+ if (state.inES6()) {
+ combine(predefined, vars.ecmaIdentifiers[6]);
+ }
+
+ if (state.option.module) {
+ if (state.option.strict === true) {
+ state.option.strict = "global";
+ }
+ if (!state.inES6()) {
+ warning("W134", state.tokens.next, "module", 6);
+ }
+ }
+
+ if (state.option.couch) {
+ combine(predefined, vars.couch);
+ }
+
+ if (state.option.qunit) {
+ combine(predefined, vars.qunit);
+ }
+
+ if (state.option.rhino) {
+ combine(predefined, vars.rhino);
+ }
+
+ if (state.option.shelljs) {
+ combine(predefined, vars.shelljs);
+ combine(predefined, vars.node);
+ }
+ if (state.option.typed) {
+ combine(predefined, vars.typed);
+ }
+
+ if (state.option.phantom) {
+ combine(predefined, vars.phantom);
+ if (state.option.strict === true) {
+ state.option.strict = "global";
+ }
+ }
+
+ if (state.option.prototypejs) {
+ combine(predefined, vars.prototypejs);
+ }
+
+ if (state.option.node) {
+ combine(predefined, vars.node);
+ combine(predefined, vars.typed);
+ if (state.option.strict === true) {
+ state.option.strict = "global";
+ }
+ }
+
+ if (state.option.devel) {
+ combine(predefined, vars.devel);
+ }
+
+ if (state.option.dojo) {
+ combine(predefined, vars.dojo);
+ }
+
+ if (state.option.browser) {
+ combine(predefined, vars.browser);
+ combine(predefined, vars.typed);
+ }
+
+ if (state.option.browserify) {
+ combine(predefined, vars.browser);
+ combine(predefined, vars.typed);
+ combine(predefined, vars.browserify);
+ if (state.option.strict === true) {
+ state.option.strict = "global";
+ }
+ }
+
+ if (state.option.nonstandard) {
+ combine(predefined, vars.nonstandard);
+ }
+
+ if (state.option.jasmine) {
+ combine(predefined, vars.jasmine);
+ }
+
+ if (state.option.jquery) {
+ combine(predefined, vars.jquery);
+ }
+
+ if (state.option.mootools) {
+ combine(predefined, vars.mootools);
+ }
+
+ if (state.option.worker) {
+ combine(predefined, vars.worker);
+ }
+
+ if (state.option.wsh) {
+ combine(predefined, vars.wsh);
+ }
+
+ if (state.option.globalstrict && state.option.strict !== false) {
+ state.option.strict = "global";
+ }
+
+ if (state.option.yui) {
+ combine(predefined, vars.yui);
+ }
+
+ if (state.option.mocha) {
+ combine(predefined, vars.mocha);
+ }
+ }
+ function quit(code, line, chr) {
+ var percentage = Math.floor((line / state.lines.length) * 100);
+ var message = messages.errors[code].desc;
+
+ throw {
+ name: "JSHintError",
+ line: line,
+ character: chr,
+ message: message + " (" + percentage + "% scanned).",
+ raw: message,
+ code: code
+ };
+ }
+
+ function removeIgnoredMessages() {
+ var ignored = state.ignoredLines;
+
+ if (_.isEmpty(ignored)) return;
+ JSHINT.errors = _.reject(JSHINT.errors, function(err) { return ignored[err.line] });
+ }
+
+ function warning(code, t, a, b, c, d) {
+ var ch, l, w, msg;
+
+ if (/^W\d{3}$/.test(code)) {
+ if (state.ignored[code])
+ return;
+
+ msg = messages.warnings[code];
+ } else if (/E\d{3}/.test(code)) {
+ msg = messages.errors[code];
+ } else if (/I\d{3}/.test(code)) {
+ msg = messages.info[code];
+ }
+
+ t = t || state.tokens.next || {};
+ if (t.id === "(end)") { // `~
+ t = state.tokens.curr;
+ }
+
+ l = t.line || 0;
+ ch = t.from || 0;
+
+ w = {
+ id: "(error)",
+ raw: msg.desc,
+ code: msg.code,
+ evidence: state.lines[l - 1] || "",
+ line: l,
+ character: ch,
+ scope: JSHINT.scope,
+ a: a,
+ b: b,
+ c: c,
+ d: d
+ };
+
+ w.reason = supplant(msg.desc, w);
+ JSHINT.errors.push(w);
+
+ removeIgnoredMessages();
+
+ if (JSHINT.errors.length >= state.option.maxerr)
+ quit("E043", l, ch);
+
+ return w;
+ }
+
+ function warningAt(m, l, ch, a, b, c, d) {
+ return warning(m, {
+ line: l,
+ from: ch
+ }, a, b, c, d);
+ }
+
+ function error(m, t, a, b, c, d) {
+ warning(m, t, a, b, c, d);
+ }
+
+ function errorAt(m, l, ch, a, b, c, d) {
+ return error(m, {
+ line: l,
+ from: ch
+ }, a, b, c, d);
+ }
+ function addInternalSrc(elem, src) {
+ var i;
+ i = {
+ id: "(internal)",
+ elem: elem,
+ value: src
+ };
+ JSHINT.internals.push(i);
+ return i;
+ }
+
+ function doOption() {
+ var nt = state.tokens.next;
+ var body = nt.body.match(/(-\s+)?[^\s,:]+(?:\s*:\s*(-\s+)?[^\s,]+)?/g) || [];
+
+ var predef = {};
+ if (nt.type === "globals") {
+ body.forEach(function(g, idx) {
+ g = g.split(":");
+ var key = (g[0] || "").trim();
+ var val = (g[1] || "").trim();
+
+ if (key === "-" || !key.length) {
+ if (idx > 0 && idx === body.length - 1) {
+ return;
+ }
+ error("E002", nt);
+ return;
+ }
+
+ if (key.charAt(0) === "-") {
+ key = key.slice(1);
+ val = false;
+
+ JSHINT.blacklist[key] = key;
+ delete predefined[key];
+ } else {
+ predef[key] = (val === "true");
+ }
+ });
+
+ combine(predefined, predef);
+
+ for (var key in predef) {
+ if (_.has(predef, key)) {
+ declared[key] = nt;
+ }
+ }
+ }
+
+ if (nt.type === "exported") {
+ body.forEach(function(e, idx) {
+ if (!e.length) {
+ if (idx > 0 && idx === body.length - 1) {
+ return;
+ }
+ error("E002", nt);
+ return;
+ }
+
+ state.funct["(scope)"].addExported(e);
+ });
+ }
+
+ if (nt.type === "members") {
+ membersOnly = membersOnly || {};
+
+ body.forEach(function(m) {
+ var ch1 = m.charAt(0);
+ var ch2 = m.charAt(m.length - 1);
+
+ if (ch1 === ch2 && (ch1 === "\"" || ch1 === "'")) {
+ m = m
+ .substr(1, m.length - 2)
+ .replace("\\\"", "\"");
+ }
+
+ membersOnly[m] = false;
+ });
+ }
+
+ var numvals = [
+ "maxstatements",
+ "maxparams",
+ "maxdepth",
+ "maxcomplexity",
+ "maxerr",
+ "maxlen",
+ "indent"
+ ];
+
+ if (nt.type === "jshint" || nt.type === "jslint") {
+ body.forEach(function(g) {
+ g = g.split(":");
+ var key = (g[0] || "").trim();
+ var val = (g[1] || "").trim();
+
+ if (!checkOption(key, nt)) {
+ return;
+ }
+
+ if (numvals.indexOf(key) >= 0) {
+ if (val !== "false") {
+ val = +val;
+
+ if (typeof val !== "number" || !isFinite(val) || val <= 0 || Math.floor(val) !== val) {
+ error("E032", nt, g[1].trim());
+ return;
+ }
+
+ state.option[key] = val;
+ } else {
+ state.option[key] = key === "indent" ? 4 : false;
+ }
+
+ return;
+ }
+
+ if (key === "validthis") {
+
+ if (state.funct["(global)"])
+ return void error("E009");
+
+ if (val !== "true" && val !== "false")
+ return void error("E002", nt);
+
+ state.option.validthis = (val === "true");
+ return;
+ }
+
+ if (key === "quotmark") {
+ switch (val) {
+ case "true":
+ case "false":
+ state.option.quotmark = (val === "true");
+ break;
+ case "double":
+ case "single":
+ state.option.quotmark = val;
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "shadow") {
+ switch (val) {
+ case "true":
+ state.option.shadow = true;
+ break;
+ case "outer":
+ state.option.shadow = "outer";
+ break;
+ case "false":
+ case "inner":
+ state.option.shadow = "inner";
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "unused") {
+ switch (val) {
+ case "true":
+ state.option.unused = true;
+ break;
+ case "false":
+ state.option.unused = false;
+ break;
+ case "vars":
+ case "strict":
+ state.option.unused = val;
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "latedef") {
+ switch (val) {
+ case "true":
+ state.option.latedef = true;
+ break;
+ case "false":
+ state.option.latedef = false;
+ break;
+ case "nofunc":
+ state.option.latedef = "nofunc";
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "ignore") {
+ switch (val) {
+ case "line":
+ state.ignoredLines[nt.line] = true;
+ removeIgnoredMessages();
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "strict") {
+ switch (val) {
+ case "true":
+ state.option.strict = true;
+ break;
+ case "false":
+ state.option.strict = false;
+ break;
+ case "func":
+ case "global":
+ case "implied":
+ state.option.strict = val;
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "module") {
+ if (!hasParsedCode(state.funct)) {
+ error("E055", state.tokens.next, "module");
+ }
+ }
+ var esversions = {
+ es3 : 3,
+ es5 : 5,
+ esnext: 6
+ };
+ if (_.has(esversions, key)) {
+ switch (val) {
+ case "true":
+ state.option.moz = false;
+ state.option.esversion = esversions[key];
+ break;
+ case "false":
+ if (!state.option.moz) {
+ state.option.esversion = 5;
+ }
+ break;
+ default:
+ error("E002", nt);
+ }
+ return;
+ }
+
+ if (key === "esversion") {
+ switch (val) {
+ case "5":
+ if (state.inES5(true)) {
+ warning("I003");
+ }
+ case "3":
+ case "6":
+ state.option.moz = false;
+ state.option.esversion = +val;
+ break;
+ case "2015":
+ state.option.moz = false;
+ state.option.esversion = 6;
+ break;
+ default:
+ error("E002", nt);
+ }
+ if (!hasParsedCode(state.funct)) {
+ error("E055", state.tokens.next, "esversion");
+ }
+ return;
+ }
+
+ var match = /^([+-])(W\d{3})$/g.exec(key);
+ if (match) {
+ state.ignored[match[2]] = (match[1] === "-");
+ return;
+ }
+
+ var tn;
+ if (val === "true" || val === "false") {
+ if (nt.type === "jslint") {
+ tn = options.renamed[key] || key;
+ state.option[tn] = (val === "true");
+
+ if (options.inverted[tn] !== undefined) {
+ state.option[tn] = !state.option[tn];
+ }
+ } else {
+ state.option[key] = (val === "true");
+ }
+
+ if (key === "newcap") {
+ state.option["(explicitNewcap)"] = true;
+ }
+ return;
+ }
+
+ error("E002", nt);
+ });
+
+ assume();
+ }
+ }
+
+ function peek(p) {
+ var i = p || 0, j = lookahead.length, t;
+
+ if (i < j) {
+ return lookahead[i];
+ }
+
+ while (j <= i) {
+ t = lookahead[j];
+ if (!t) {
+ t = lookahead[j] = lex.token();
+ }
+ j += 1;
+ }
+ if (!t && state.tokens.next.id === "(end)") {
+ return state.tokens.next;
+ }
+
+ return t;
+ }
+
+ function peekIgnoreEOL() {
+ var i = 0;
+ var t;
+ do {
+ t = peek(i++);
+ } while (t.id === "(endline)");
+ return t;
+ }
+
+ function advance(id, t) {
+
+ switch (state.tokens.curr.id) {
+ case "(number)":
+ if (state.tokens.next.id === ".") {
+ warning("W005", state.tokens.curr);
+ }
+ break;
+ case "-":
+ if (state.tokens.next.id === "-" || state.tokens.next.id === "--") {
+ warning("W006");
+ }
+ break;
+ case "+":
+ if (state.tokens.next.id === "+" || state.tokens.next.id === "++") {
+ warning("W007");
+ }
+ break;
+ }
+
+ if (id && state.tokens.next.id !== id) {
+ if (t) {
+ if (state.tokens.next.id === "(end)") {
+ error("E019", t, t.id);
+ } else {
+ error("E020", state.tokens.next, id, t.id, t.line, state.tokens.next.value);
+ }
+ } else if (state.tokens.next.type !== "(identifier)" || state.tokens.next.value !== id) {
+ warning("W116", state.tokens.next, id, state.tokens.next.value);
+ }
+ }
+
+ state.tokens.prev = state.tokens.curr;
+ state.tokens.curr = state.tokens.next;
+ for (;;) {
+ state.tokens.next = lookahead.shift() || lex.token();
+
+ if (!state.tokens.next) { // No more tokens left, give up
+ quit("E041", state.tokens.curr.line);
+ }
+
+ if (state.tokens.next.id === "(end)" || state.tokens.next.id === "(error)") {
+ return;
+ }
+
+ if (state.tokens.next.check) {
+ state.tokens.next.check();
+ }
+
+ if (state.tokens.next.isSpecial) {
+ if (state.tokens.next.type === "falls through") {
+ state.tokens.curr.caseFallsThrough = true;
+ } else {
+ doOption();
+ }
+ } else {
+ if (state.tokens.next.id !== "(endline)") {
+ break;
+ }
+ }
+ }
+ }
+
+ function isInfix(token) {
+ return token.infix || (!token.identifier && !token.template && !!token.led);
+ }
+
+ function isEndOfExpr() {
+ var curr = state.tokens.curr;
+ var next = state.tokens.next;
+ if (next.id === ";" || next.id === "}" || next.id === ":") {
+ return true;
+ }
+ if (isInfix(next) === isInfix(curr) || (curr.id === "yield" && state.inMoz())) {
+ return curr.line !== startLine(next);
+ }
+ return false;
+ }
+
+ function isBeginOfExpr(prev) {
+ return !prev.left && prev.arity !== "unary";
+ }
+
+ function expression(rbp, initial) {
+ var left, isArray = false, isObject = false, isLetExpr = false;
+
+ state.nameStack.push();
+ if (!initial && state.tokens.next.value === "let" && peek(0).value === "(") {
+ if (!state.inMoz()) {
+ warning("W118", state.tokens.next, "let expressions");
+ }
+ isLetExpr = true;
+ state.funct["(scope)"].stack();
+ advance("let");
+ advance("(");
+ state.tokens.prev.fud();
+ advance(")");
+ }
+
+ if (state.tokens.next.id === "(end)")
+ error("E006", state.tokens.curr);
+
+ var isDangerous =
+ state.option.asi &&
+ state.tokens.prev.line !== startLine(state.tokens.curr) &&
+ _.contains(["]", ")"], state.tokens.prev.id) &&
+ _.contains(["[", "("], state.tokens.curr.id);
+
+ if (isDangerous)
+ warning("W014", state.tokens.curr, state.tokens.curr.id);
+
+ advance();
+
+ if (initial) {
+ state.funct["(verb)"] = state.tokens.curr.value;
+ state.tokens.curr.beginsStmt = true;
+ }
+
+ if (initial === true && state.tokens.curr.fud) {
+ left = state.tokens.curr.fud();
+ } else {
+ if (state.tokens.curr.nud) {
+ left = state.tokens.curr.nud();
+ } else {
+ error("E030", state.tokens.curr, state.tokens.curr.id);
+ }
+ while ((rbp < state.tokens.next.lbp || state.tokens.next.type === "(template)") &&
+ !isEndOfExpr()) {
+ isArray = state.tokens.curr.value === "Array";
+ isObject = state.tokens.curr.value === "Object";
+ if (left && (left.value || (left.first && left.first.value))) {
+ if (left.value !== "new" ||
+ (left.first && left.first.value && left.first.value === ".")) {
+ isArray = false;
+ if (left.value !== state.tokens.curr.value) {
+ isObject = false;
+ }
+ }
+ }
+
+ advance();
+
+ if (isArray && state.tokens.curr.id === "(" && state.tokens.next.id === ")") {
+ warning("W009", state.tokens.curr);
+ }
+
+ if (isObject && state.tokens.curr.id === "(" && state.tokens.next.id === ")") {
+ warning("W010", state.tokens.curr);
+ }
+
+ if (left && state.tokens.curr.led) {
+ left = state.tokens.curr.led(left);
+ } else {
+ error("E033", state.tokens.curr, state.tokens.curr.id);
+ }
+ }
+ }
+ if (isLetExpr) {
+ state.funct["(scope)"].unstack();
+ }
+
+ state.nameStack.pop();
+
+ return left;
+ }
+
+ function startLine(token) {
+ return token.startLine || token.line;
+ }
+
+ function nobreaknonadjacent(left, right) {
+ left = left || state.tokens.curr;
+ right = right || state.tokens.next;
+ if (!state.option.laxbreak && left.line !== startLine(right)) {
+ warning("W014", right, right.value);
+ }
+ }
+
+ function nolinebreak(t) {
+ t = t || state.tokens.curr;
+ if (t.line !== startLine(state.tokens.next)) {
+ warning("E022", t, t.value);
+ }
+ }
+
+ function nobreakcomma(left, right) {
+ if (left.line !== startLine(right)) {
+ if (!state.option.laxcomma) {
+ if (comma.first) {
+ warning("I001");
+ comma.first = false;
+ }
+ warning("W014", left, right.value);
+ }
+ }
+ }
+
+ function comma(opts) {
+ opts = opts || {};
+
+ if (!opts.peek) {
+ nobreakcomma(state.tokens.curr, state.tokens.next);
+ advance(",");
+ } else {
+ nobreakcomma(state.tokens.prev, state.tokens.curr);
+ }
+
+ if (state.tokens.next.identifier && !(opts.property && state.inES5())) {
+ switch (state.tokens.next.value) {
+ case "break":
+ case "case":
+ case "catch":
+ case "continue":
+ case "default":
+ case "do":
+ case "else":
+ case "finally":
+ case "for":
+ case "if":
+ case "in":
+ case "instanceof":
+ case "return":
+ case "switch":
+ case "throw":
+ case "try":
+ case "var":
+ case "let":
+ case "while":
+ case "with":
+ error("E024", state.tokens.next, state.tokens.next.value);
+ return false;
+ }
+ }
+
+ if (state.tokens.next.type === "(punctuator)") {
+ switch (state.tokens.next.value) {
+ case "}":
+ case "]":
+ case ",":
+ if (opts.allowTrailing) {
+ return true;
+ }
+ case ")":
+ error("E024", state.tokens.next, state.tokens.next.value);
+ return false;
+ }
+ }
+ return true;
+ }
+
+ function symbol(s, p) {
+ var x = state.syntax[s];
+ if (!x || typeof x !== "object") {
+ state.syntax[s] = x = {
+ id: s,
+ lbp: p,
+ value: s
+ };
+ }
+ return x;
+ }
+
+ function delim(s) {
+ var x = symbol(s, 0);
+ x.delim = true;
+ return x;
+ }
+
+ function stmt(s, f) {
+ var x = delim(s);
+ x.identifier = x.reserved = true;
+ x.fud = f;
+ return x;
+ }
+
+ function blockstmt(s, f) {
+ var x = stmt(s, f);
+ x.block = true;
+ return x;
+ }
+
+ function reserveName(x) {
+ var c = x.id.charAt(0);
+ if ((c >= "a" && c <= "z") || (c >= "A" && c <= "Z")) {
+ x.identifier = x.reserved = true;
+ }
+ return x;
+ }
+
+ function prefix(s, f) {
+ var x = symbol(s, 150);
+ reserveName(x);
+
+ x.nud = (typeof f === "function") ? f : function() {
+ this.arity = "unary";
+ this.right = expression(150);
+
+ if (this.id === "++" || this.id === "--") {
+ if (state.option.plusplus) {
+ warning("W016", this, this.id);
+ } else if (this.right && (!this.right.identifier || isReserved(this.right)) &&
+ this.right.id !== "." && this.right.id !== "[") {
+ warning("W017", this);
+ }
+
+ if (this.right && this.right.isMetaProperty) {
+ error("E031", this);
+ } else if (this.right && this.right.identifier) {
+ state.funct["(scope)"].block.modify(this.right.value, this);
+ }
+ }
+
+ return this;
+ };
+
+ return x;
+ }
+
+ function type(s, f) {
+ var x = delim(s);
+ x.type = s;
+ x.nud = f;
+ return x;
+ }
+
+ function reserve(name, func) {
+ var x = type(name, func);
+ x.identifier = true;
+ x.reserved = true;
+ return x;
+ }
+
+ function FutureReservedWord(name, meta) {
+ var x = type(name, (meta && meta.nud) || function() {
+ return this;
+ });
+
+ meta = meta || {};
+ meta.isFutureReservedWord = true;
+
+ x.value = name;
+ x.identifier = true;
+ x.reserved = true;
+ x.meta = meta;
+
+ return x;
+ }
+
+ function reservevar(s, v) {
+ return reserve(s, function() {
+ if (typeof v === "function") {
+ v(this);
+ }
+ return this;
+ });
+ }
+
+ function infix(s, f, p, w) {
+ var x = symbol(s, p);
+ reserveName(x);
+ x.infix = true;
+ x.led = function(left) {
+ if (!w) {
+ nobreaknonadjacent(state.tokens.prev, state.tokens.curr);
+ }
+ if ((s === "in" || s === "instanceof") && left.id === "!") {
+ warning("W018", left, "!");
+ }
+ if (typeof f === "function") {
+ return f(left, this);
+ } else {
+ this.left = left;
+ this.right = expression(p);
+ return this;
+ }
+ };
+ return x;
+ }
+
+ function application(s) {
+ var x = symbol(s, 42);
+
+ x.led = function(left) {
+ nobreaknonadjacent(state.tokens.prev, state.tokens.curr);
+
+ this.left = left;
+ this.right = doFunction({ type: "arrow", loneArg: left });
+ return this;
+ };
+ return x;
+ }
+
+ function relation(s, f) {
+ var x = symbol(s, 100);
+
+ x.led = function(left) {
+ nobreaknonadjacent(state.tokens.prev, state.tokens.curr);
+ this.left = left;
+ var right = this.right = expression(100);
+
+ if (isIdentifier(left, "NaN") || isIdentifier(right, "NaN")) {
+ warning("W019", this);
+ } else if (f) {
+ f.apply(this, [left, right]);
+ }
+
+ if (!left || !right) {
+ quit("E041", state.tokens.curr.line);
+ }
+
+ if (left.id === "!") {
+ warning("W018", left, "!");
+ }
+
+ if (right.id === "!") {
+ warning("W018", right, "!");
+ }
+
+ return this;
+ };
+ return x;
+ }
+
+ function isPoorRelation(node) {
+ return node &&
+ ((node.type === "(number)" && +node.value === 0) ||
+ (node.type === "(string)" && node.value === "") ||
+ (node.type === "null" && !state.option.eqnull) ||
+ node.type === "true" ||
+ node.type === "false" ||
+ node.type === "undefined");
+ }
+
+ var typeofValues = {};
+ typeofValues.legacy = [
+ "xml",
+ "unknown"
+ ];
+ typeofValues.es3 = [
+ "undefined", "boolean", "number", "string", "function", "object",
+ ];
+ typeofValues.es3 = typeofValues.es3.concat(typeofValues.legacy);
+ typeofValues.es6 = typeofValues.es3.concat("symbol");
+ function isTypoTypeof(left, right, state) {
+ var values;
+
+ if (state.option.notypeof)
+ return false;
+
+ if (!left || !right)
+ return false;
+
+ values = state.inES6() ? typeofValues.es6 : typeofValues.es3;
+
+ if (right.type === "(identifier)" && right.value === "typeof" && left.type === "(string)")
+ return !_.contains(values, left.value);
+
+ return false;
+ }
+
+ function isGlobalEval(left, state) {
+ var isGlobal = false;
+ if (left.type === "this" && state.funct["(context)"] === null) {
+ isGlobal = true;
+ }
+ else if (left.type === "(identifier)") {
+ if (state.option.node && left.value === "global") {
+ isGlobal = true;
+ }
+
+ else if (state.option.browser && (left.value === "window" || left.value === "document")) {
+ isGlobal = true;
+ }
+ }
+
+ return isGlobal;
+ }
+
+ function findNativePrototype(left) {
+ var natives = [
+ "Array", "ArrayBuffer", "Boolean", "Collator", "DataView", "Date",
+ "DateTimeFormat", "Error", "EvalError", "Float32Array", "Float64Array",
+ "Function", "Infinity", "Intl", "Int16Array", "Int32Array", "Int8Array",
+ "Iterator", "Number", "NumberFormat", "Object", "RangeError",
+ "ReferenceError", "RegExp", "StopIteration", "String", "SyntaxError",
+ "TypeError", "Uint16Array", "Uint32Array", "Uint8Array", "Uint8ClampedArray",
+ "URIError"
+ ];
+
+ function walkPrototype(obj) {
+ if (typeof obj !== "object") return;
+ return obj.right === "prototype" ? obj : walkPrototype(obj.left);
+ }
+
+ function walkNative(obj) {
+ while (!obj.identifier && typeof obj.left === "object")
+ obj = obj.left;
+
+ if (obj.identifier && natives.indexOf(obj.value) >= 0)
+ return obj.value;
+ }
+
+ var prototype = walkPrototype(left);
+ if (prototype) return walkNative(prototype);
+ }
+ function checkLeftSideAssign(left, assignToken, options) {
+
+ var allowDestructuring = options && options.allowDestructuring;
+
+ assignToken = assignToken || left;
+
+ if (state.option.freeze) {
+ var nativeObject = findNativePrototype(left);
+ if (nativeObject)
+ warning("W121", left, nativeObject);
+ }
+
+ if (left.identifier && !left.isMetaProperty) {
+ state.funct["(scope)"].block.reassign(left.value, left);
+ }
+
+ if (left.id === ".") {
+ if (!left.left || left.left.value === "arguments" && !state.isStrict()) {
+ warning("E031", assignToken);
+ }
+
+ state.nameStack.set(state.tokens.prev);
+ return true;
+ } else if (left.id === "{" || left.id === "[") {
+ if (allowDestructuring && state.tokens.curr.left.destructAssign) {
+ state.tokens.curr.left.destructAssign.forEach(function(t) {
+ if (t.id) {
+ state.funct["(scope)"].block.modify(t.id, t.token);
+ }
+ });
+ } else {
+ if (left.id === "{" || !left.left) {
+ warning("E031", assignToken);
+ } else if (left.left.value === "arguments" && !state.isStrict()) {
+ warning("E031", assignToken);
+ }
+ }
+
+ if (left.id === "[") {
+ state.nameStack.set(left.right);
+ }
+
+ return true;
+ } else if (left.isMetaProperty) {
+ error("E031", assignToken);
+ return true;
+ } else if (left.identifier && !isReserved(left)) {
+ if (state.funct["(scope)"].labeltype(left.value) === "exception") {
+ warning("W022", left);
+ }
+ state.nameStack.set(left);
+ return true;
+ }
+
+ if (left === state.syntax["function"]) {
+ warning("W023", state.tokens.curr);
+ }
+
+ return false;
+ }
+
+ function assignop(s, f, p) {
+ var x = infix(s, typeof f === "function" ? f : function(left, that) {
+ that.left = left;
+
+ if (left && checkLeftSideAssign(left, that, { allowDestructuring: true })) {
+ that.right = expression(10);
+ return that;
+ }
+
+ error("E031", that);
+ }, p);
+
+ x.exps = true;
+ x.assign = true;
+ return x;
+ }
+
+
+ function bitwise(s, f, p) {
+ var x = symbol(s, p);
+ reserveName(x);
+ x.led = (typeof f === "function") ? f : function(left) {
+ if (state.option.bitwise) {
+ warning("W016", this, this.id);
+ }
+ this.left = left;
+ this.right = expression(p);
+ return this;
+ };
+ return x;
+ }
+
+ function bitwiseassignop(s) {
+ return assignop(s, function(left, that) {
+ if (state.option.bitwise) {
+ warning("W016", that, that.id);
+ }
+
+ if (left && checkLeftSideAssign(left, that)) {
+ that.right = expression(10);
+ return that;
+ }
+ error("E031", that);
+ }, 20);
+ }
+
+ function suffix(s) {
+ var x = symbol(s, 150);
+
+ x.led = function(left) {
+ if (state.option.plusplus) {
+ warning("W016", this, this.id);
+ } else if ((!left.identifier || isReserved(left)) && left.id !== "." && left.id !== "[") {
+ warning("W017", this);
+ }
+
+ if (left.isMetaProperty) {
+ error("E031", this);
+ } else if (left && left.identifier) {
+ state.funct["(scope)"].block.modify(left.value, left);
+ }
+
+ this.left = left;
+ return this;
+ };
+ return x;
+ }
+
+ function optionalidentifier(fnparam, prop, preserve) {
+ if (!state.tokens.next.identifier) {
+ return;
+ }
+
+ if (!preserve) {
+ advance();
+ }
+
+ var curr = state.tokens.curr;
+ var val = state.tokens.curr.value;
+
+ if (!isReserved(curr)) {
+ return val;
+ }
+
+ if (prop) {
+ if (state.inES5()) {
+ return val;
+ }
+ }
+
+ if (fnparam && val === "undefined") {
+ return val;
+ }
+
+ warning("W024", state.tokens.curr, state.tokens.curr.id);
+ return val;
+ }
+ function identifier(fnparam, prop) {
+ var i = optionalidentifier(fnparam, prop, false);
+ if (i) {
+ return i;
+ }
+ if (state.tokens.next.value === "...") {
+ if (!state.inES6(true)) {
+ warning("W119", state.tokens.next, "spread/rest operator", "6");
+ }
+ advance();
+
+ if (checkPunctuator(state.tokens.next, "...")) {
+ warning("E024", state.tokens.next, "...");
+ while (checkPunctuator(state.tokens.next, "...")) {
+ advance();
+ }
+ }
+
+ if (!state.tokens.next.identifier) {
+ warning("E024", state.tokens.curr, "...");
+ return;
+ }
+
+ return identifier(fnparam, prop);
+ } else {
+ error("E030", state.tokens.next, state.tokens.next.value);
+ if (state.tokens.next.id !== ";") {
+ advance();
+ }
+ }
+ }
+
+
+ function reachable(controlToken) {
+ var i = 0, t;
+ if (state.tokens.next.id !== ";" || controlToken.inBracelessBlock) {
+ return;
+ }
+ for (;;) {
+ do {
+ t = peek(i);
+ i += 1;
+ } while (t.id !== "(end)" && t.id === "(comment)");
+
+ if (t.reach) {
+ return;
+ }
+ if (t.id !== "(endline)") {
+ if (t.id === "function") {
+ if (state.option.latedef === true) {
+ warning("W026", t);
+ }
+ break;
+ }
+
+ warning("W027", t, t.value, controlToken.value);
+ break;
+ }
+ }
+ }
+
+ function parseFinalSemicolon() {
+ if (state.tokens.next.id !== ";") {
+ if (state.tokens.next.isUnclosed) return advance();
+
+ var sameLine = startLine(state.tokens.next) === state.tokens.curr.line &&
+ state.tokens.next.id !== "(end)";
+ var blockEnd = checkPunctuator(state.tokens.next, "}");
+
+ if (sameLine && !blockEnd) {
+ errorAt("E058", state.tokens.curr.line, state.tokens.curr.character);
+ } else if (!state.option.asi) {
+ if ((blockEnd && !state.option.lastsemic) || !sameLine) {
+ warningAt("W033", state.tokens.curr.line, state.tokens.curr.character);
+ }
+ }
+ } else {
+ advance(";");
+ }
+ }
+
+ function statement() {
+ var i = indent, r, t = state.tokens.next, hasOwnScope = false;
+
+ if (t.id === ";") {
+ advance(";");
+ return;
+ }
+ var res = isReserved(t);
+
+ if (res && t.meta && t.meta.isFutureReservedWord && peek().id === ":") {
+ warning("W024", t, t.id);
+ res = false;
+ }
+
+ if (t.identifier && !res && peek().id === ":") {
+ advance();
+ advance(":");
+
+ hasOwnScope = true;
+ state.funct["(scope)"].stack();
+ state.funct["(scope)"].block.addBreakLabel(t.value, { token: state.tokens.curr });
+
+ if (!state.tokens.next.labelled && state.tokens.next.value !== "{") {
+ warning("W028", state.tokens.next, t.value, state.tokens.next.value);
+ }
+
+ state.tokens.next.label = t.value;
+ t = state.tokens.next;
+ }
+
+ if (t.id === "{") {
+ var iscase = (state.funct["(verb)"] === "case" && state.tokens.curr.value === ":");
+ block(true, true, false, false, iscase);
+ return;
+ }
+
+ r = expression(0, true);
+
+ if (r && !(r.identifier && r.value === "function") &&
+ !(r.type === "(punctuator)" && r.left &&
+ r.left.identifier && r.left.value === "function")) {
+ if (!state.isStrict() &&
+ state.option.strict === "global") {
+ warning("E007");
+ }
+ }
+
+ if (!t.block) {
+ if (!state.option.expr && (!r || !r.exps)) {
+ warning("W030", state.tokens.curr);
+ } else if (state.option.nonew && r && r.left && r.id === "(" && r.left.id === "new") {
+ warning("W031", t);
+ }
+ parseFinalSemicolon();
+ }
+
+ indent = i;
+ if (hasOwnScope) {
+ state.funct["(scope)"].unstack();
+ }
+ return r;
+ }
+
+
+ function statements() {
+ var a = [], p;
+
+ while (!state.tokens.next.reach && state.tokens.next.id !== "(end)") {
+ if (state.tokens.next.id === ";") {
+ p = peek();
+
+ if (!p || (p.id !== "(" && p.id !== "[")) {
+ warning("W032");
+ }
+
+ advance(";");
+ } else {
+ a.push(statement());
+ }
+ }
+ return a;
+ }
+ function directives() {
+ var i, p, pn;
+
+ while (state.tokens.next.id === "(string)") {
+ p = peek(0);
+ if (p.id === "(endline)") {
+ i = 1;
+ do {
+ pn = peek(i++);
+ } while (pn.id === "(endline)");
+ if (pn.id === ";") {
+ p = pn;
+ } else if (pn.value === "[" || pn.value === ".") {
+ break;
+ } else if (!state.option.asi || pn.value === "(") {
+ warning("W033", state.tokens.next);
+ }
+ } else if (p.id === "." || p.id === "[") {
+ break;
+ } else if (p.id !== ";") {
+ warning("W033", p);
+ }
+
+ advance();
+ var directive = state.tokens.curr.value;
+ if (state.directive[directive] ||
+ (directive === "use strict" && state.option.strict === "implied")) {
+ warning("W034", state.tokens.curr, directive);
+ }
+ state.directive[directive] = true;
+
+ if (p.id === ";") {
+ advance(";");
+ }
+ }
+
+ if (state.isStrict()) {
+ if (!state.option["(explicitNewcap)"]) {
+ state.option.newcap = true;
+ }
+ state.option.undef = true;
+ }
+ }
+ function block(ordinary, stmt, isfunc, isfatarrow, iscase) {
+ var a,
+ b = inblock,
+ old_indent = indent,
+ m,
+ t,
+ line,
+ d;
+
+ inblock = ordinary;
+
+ t = state.tokens.next;
+
+ var metrics = state.funct["(metrics)"];
+ metrics.nestedBlockDepth += 1;
+ metrics.verifyMaxNestedBlockDepthPerFunction();
+
+ if (state.tokens.next.id === "{") {
+ advance("{");
+ state.funct["(scope)"].stack();
+
+ line = state.tokens.curr.line;
+ if (state.tokens.next.id !== "}") {
+ indent += state.option.indent;
+ while (!ordinary && state.tokens.next.from > indent) {
+ indent += state.option.indent;
+ }
+
+ if (isfunc) {
+ m = {};
+ for (d in state.directive) {
+ if (_.has(state.directive, d)) {
+ m[d] = state.directive[d];
+ }
+ }
+ directives();
+
+ if (state.option.strict && state.funct["(context)"]["(global)"]) {
+ if (!m["use strict"] && !state.isStrict()) {
+ warning("E007");
+ }
+ }
+ }
+
+ a = statements();
+
+ metrics.statementCount += a.length;
+
+ indent -= state.option.indent;
+ }
+
+ advance("}", t);
+
+ if (isfunc) {
+ state.funct["(scope)"].validateParams();
+ if (m) {
+ state.directive = m;
+ }
+ }
+
+ state.funct["(scope)"].unstack();
+
+ indent = old_indent;
+ } else if (!ordinary) {
+ if (isfunc) {
+ state.funct["(scope)"].stack();
+
+ m = {};
+ if (stmt && !isfatarrow && !state.inMoz()) {
+ error("W118", state.tokens.curr, "function closure expressions");
+ }
+
+ if (!stmt) {
+ for (d in state.directive) {
+ if (_.has(state.directive, d)) {
+ m[d] = state.directive[d];
+ }
+ }
+ }
+ expression(10);
+
+ if (state.option.strict && state.funct["(context)"]["(global)"]) {
+ if (!m["use strict"] && !state.isStrict()) {
+ warning("E007");
+ }
+ }
+
+ state.funct["(scope)"].unstack();
+ } else {
+ error("E021", state.tokens.next, "{", state.tokens.next.value);
+ }
+ } else {
+ state.funct["(noblockscopedvar)"] = state.tokens.next.id !== "for";
+ state.funct["(scope)"].stack();
+
+ if (!stmt || state.option.curly) {
+ warning("W116", state.tokens.next, "{", state.tokens.next.value);
+ }
+
+ state.tokens.next.inBracelessBlock = true;
+ indent += state.option.indent;
+ a = [statement()];
+ indent -= state.option.indent;
+
+ state.funct["(scope)"].unstack();
+ delete state.funct["(noblockscopedvar)"];
+ }
+ switch (state.funct["(verb)"]) {
+ case "break":
+ case "continue":
+ case "return":
+ case "throw":
+ if (iscase) {
+ break;
+ }
+ default:
+ state.funct["(verb)"] = null;
+ }
+
+ inblock = b;
+ if (ordinary && state.option.noempty && (!a || a.length === 0)) {
+ warning("W035", state.tokens.prev);
+ }
+ metrics.nestedBlockDepth -= 1;
+ return a;
+ }
+
+
+ function countMember(m) {
+ if (membersOnly && typeof membersOnly[m] !== "boolean") {
+ warning("W036", state.tokens.curr, m);
+ }
+ if (typeof member[m] === "number") {
+ member[m] += 1;
+ } else {
+ member[m] = 1;
+ }
+ }
+
+ type("(number)", function() {
+ return this;
+ });
+
+ type("(string)", function() {
+ return this;
+ });
+
+ state.syntax["(identifier)"] = {
+ type: "(identifier)",
+ lbp: 0,
+ identifier: true,
+
+ nud: function() {
+ var v = this.value;
+ if (state.tokens.next.id === "=>") {
+ return this;
+ }
+
+ if (!state.funct["(comparray)"].check(v)) {
+ state.funct["(scope)"].block.use(v, state.tokens.curr);
+ }
+ return this;
+ },
+
+ led: function() {
+ error("E033", state.tokens.next, state.tokens.next.value);
+ }
+ };
+
+ var baseTemplateSyntax = {
+ lbp: 0,
+ identifier: false,
+ template: true,
+ };
+ state.syntax["(template)"] = _.extend({
+ type: "(template)",
+ nud: doTemplateLiteral,
+ led: doTemplateLiteral,
+ noSubst: false
+ }, baseTemplateSyntax);
+
+ state.syntax["(template middle)"] = _.extend({
+ type: "(template middle)",
+ middle: true,
+ noSubst: false
+ }, baseTemplateSyntax);
+
+ state.syntax["(template tail)"] = _.extend({
+ type: "(template tail)",
+ tail: true,
+ noSubst: false
+ }, baseTemplateSyntax);
+
+ state.syntax["(no subst template)"] = _.extend({
+ type: "(template)",
+ nud: doTemplateLiteral,
+ led: doTemplateLiteral,
+ noSubst: true,
+ tail: true // mark as tail, since it's always the last component
+ }, baseTemplateSyntax);
+
+ type("(regexp)", function() {
+ return this;
+ });
+
+ delim("(endline)");
+ delim("(begin)");
+ delim("(end)").reach = true;
+ delim("(error)").reach = true;
+ delim("}").reach = true;
+ delim(")");
+ delim("]");
+ delim("\"").reach = true;
+ delim("'").reach = true;
+ delim(";");
+ delim(":").reach = true;
+ delim("#");
+
+ reserve("else");
+ reserve("case").reach = true;
+ reserve("catch");
+ reserve("default").reach = true;
+ reserve("finally");
+ reservevar("arguments", function(x) {
+ if (state.isStrict() && state.funct["(global)"]) {
+ warning("E008", x);
+ }
+ });
+ reservevar("eval");
+ reservevar("false");
+ reservevar("Infinity");
+ reservevar("null");
+ reservevar("this", function(x) {
+ if (state.isStrict() && !isMethod() &&
+ !state.option.validthis && ((state.funct["(statement)"] &&
+ state.funct["(name)"].charAt(0) > "Z") || state.funct["(global)"])) {
+ warning("W040", x);
+ }
+ });
+ reservevar("true");
+ reservevar("undefined");
+
+ assignop("=", "assign", 20);
+ assignop("+=", "assignadd", 20);
+ assignop("-=", "assignsub", 20);
+ assignop("*=", "assignmult", 20);
+ assignop("/=", "assigndiv", 20).nud = function() {
+ error("E014");
+ };
+ assignop("%=", "assignmod", 20);
+
+ bitwiseassignop("&=");
+ bitwiseassignop("|=");
+ bitwiseassignop("^=");
+ bitwiseassignop("<<=");
+ bitwiseassignop(">>=");
+ bitwiseassignop(">>>=");
+ infix(",", function(left, that) {
+ var expr;
+ that.exprs = [left];
+
+ if (state.option.nocomma) {
+ warning("W127");
+ }
+
+ if (!comma({ peek: true })) {
+ return that;
+ }
+ while (true) {
+ if (!(expr = expression(10))) {
+ break;
+ }
+ that.exprs.push(expr);
+ if (state.tokens.next.value !== "," || !comma()) {
+ break;
+ }
+ }
+ return that;
+ }, 10, true);
+
+ infix("?", function(left, that) {
+ increaseComplexityCount();
+ that.left = left;
+ that.right = expression(10);
+ advance(":");
+ that["else"] = expression(10);
+ return that;
+ }, 30);
+
+ var orPrecendence = 40;
+ infix("||", function(left, that) {
+ increaseComplexityCount();
+ that.left = left;
+ that.right = expression(orPrecendence);
+ return that;
+ }, orPrecendence);
+ infix("&&", "and", 50);
+ bitwise("|", "bitor", 70);
+ bitwise("^", "bitxor", 80);
+ bitwise("&", "bitand", 90);
+ relation("==", function(left, right) {
+ var eqnull = state.option.eqnull &&
+ ((left && left.value) === "null" || (right && right.value) === "null");
+
+ switch (true) {
+ case !eqnull && state.option.eqeqeq:
+ this.from = this.character;
+ warning("W116", this, "===", "==");
+ break;
+ case isPoorRelation(left):
+ warning("W041", this, "===", left.value);
+ break;
+ case isPoorRelation(right):
+ warning("W041", this, "===", right.value);
+ break;
+ case isTypoTypeof(right, left, state):
+ warning("W122", this, right.value);
+ break;
+ case isTypoTypeof(left, right, state):
+ warning("W122", this, left.value);
+ break;
+ }
+
+ return this;
+ });
+ relation("===", function(left, right) {
+ if (isTypoTypeof(right, left, state)) {
+ warning("W122", this, right.value);
+ } else if (isTypoTypeof(left, right, state)) {
+ warning("W122", this, left.value);
+ }
+ return this;
+ });
+ relation("!=", function(left, right) {
+ var eqnull = state.option.eqnull &&
+ ((left && left.value) === "null" || (right && right.value) === "null");
+
+ if (!eqnull && state.option.eqeqeq) {
+ this.from = this.character;
+ warning("W116", this, "!==", "!=");
+ } else if (isPoorRelation(left)) {
+ warning("W041", this, "!==", left.value);
+ } else if (isPoorRelation(right)) {
+ warning("W041", this, "!==", right.value);
+ } else if (isTypoTypeof(right, left, state)) {
+ warning("W122", this, right.value);
+ } else if (isTypoTypeof(left, right, state)) {
+ warning("W122", this, left.value);
+ }
+ return this;
+ });
+ relation("!==", function(left, right) {
+ if (isTypoTypeof(right, left, state)) {
+ warning("W122", this, right.value);
+ } else if (isTypoTypeof(left, right, state)) {
+ warning("W122", this, left.value);
+ }
+ return this;
+ });
+ relation("<");
+ relation(">");
+ relation("<=");
+ relation(">=");
+ bitwise("<<", "shiftleft", 120);
+ bitwise(">>", "shiftright", 120);
+ bitwise(">>>", "shiftrightunsigned", 120);
+ infix("in", "in", 120);
+ infix("instanceof", "instanceof", 120);
+ infix("+", function(left, that) {
+ var right;
+ that.left = left;
+ that.right = right = expression(130);
+
+ if (left && right && left.id === "(string)" && right.id === "(string)") {
+ left.value += right.value;
+ left.character = right.character;
+ if (!state.option.scripturl && reg.javascriptURL.test(left.value)) {
+ warning("W050", left);
+ }
+ return left;
+ }
+
+ return that;
+ }, 130);
+ prefix("+", "num");
+ prefix("+++", function() {
+ warning("W007");
+ this.arity = "unary";
+ this.right = expression(150);
+ return this;
+ });
+ infix("+++", function(left) {
+ warning("W007");
+ this.left = left;
+ this.right = expression(130);
+ return this;
+ }, 130);
+ infix("-", "sub", 130);
+ prefix("-", "neg");
+ prefix("---", function() {
+ warning("W006");
+ this.arity = "unary";
+ this.right = expression(150);
+ return this;
+ });
+ infix("---", function(left) {
+ warning("W006");
+ this.left = left;
+ this.right = expression(130);
+ return this;
+ }, 130);
+ infix("*", "mult", 140);
+ infix("/", "div", 140);
+ infix("%", "mod", 140);
+
+ suffix("++");
+ prefix("++", "preinc");
+ state.syntax["++"].exps = true;
+
+ suffix("--");
+ prefix("--", "predec");
+ state.syntax["--"].exps = true;
+ prefix("delete", function() {
+ var p = expression(10);
+ if (!p) {
+ return this;
+ }
+
+ if (p.id !== "." && p.id !== "[") {
+ warning("W051");
+ }
+ this.first = p;
+ if (p.identifier && !state.isStrict()) {
+ p.forgiveUndef = true;
+ }
+ return this;
+ }).exps = true;
+
+ prefix("~", function() {
+ if (state.option.bitwise) {
+ warning("W016", this, "~");
+ }
+ this.arity = "unary";
+ this.right = expression(150);
+ return this;
+ });
+
+ prefix("...", function() {
+ if (!state.inES6(true)) {
+ warning("W119", this, "spread/rest operator", "6");
+ }
+ if (!state.tokens.next.identifier &&
+ state.tokens.next.type !== "(string)" &&
+ !checkPunctuators(state.tokens.next, ["[", "("])) {
+
+ error("E030", state.tokens.next, state.tokens.next.value);
+ }
+ expression(150);
+ return this;
+ });
+
+ prefix("!", function() {
+ this.arity = "unary";
+ this.right = expression(150);
+
+ if (!this.right) { // '!' followed by nothing? Give up.
+ quit("E041", this.line || 0);
+ }
+
+ if (bang[this.right.id] === true) {
+ warning("W018", this, "!");
+ }
+ return this;
+ });
+
+ prefix("typeof", (function() {
+ var p = expression(150);
+ this.first = this.right = p;
+
+ if (!p) { // 'typeof' followed by nothing? Give up.
+ quit("E041", this.line || 0, this.character || 0);
+ }
+ if (p.identifier) {
+ p.forgiveUndef = true;
+ }
+ return this;
+ }));
+ prefix("new", function() {
+ var mp = metaProperty("target", function() {
+ if (!state.inES6(true)) {
+ warning("W119", state.tokens.prev, "new.target", "6");
+ }
+ var inFunction, c = state.funct;
+ while (c) {
+ inFunction = !c["(global)"];
+ if (!c["(arrow)"]) { break; }
+ c = c["(context)"];
+ }
+ if (!inFunction) {
+ warning("W136", state.tokens.prev, "new.target");
+ }
+ });
+ if (mp) { return mp; }
+
+ var c = expression(155), i;
+ if (c && c.id !== "function") {
+ if (c.identifier) {
+ c["new"] = true;
+ switch (c.value) {
+ case "Number":
+ case "String":
+ case "Boolean":
+ case "Math":
+ case "JSON":
+ warning("W053", state.tokens.prev, c.value);
+ break;
+ case "Symbol":
+ if (state.inES6()) {
+ warning("W053", state.tokens.prev, c.value);
+ }
+ break;
+ case "Function":
+ if (!state.option.evil) {
+ warning("W054");
+ }
+ break;
+ case "Date":
+ case "RegExp":
+ case "this":
+ break;
+ default:
+ if (c.id !== "function") {
+ i = c.value.substr(0, 1);
+ if (state.option.newcap && (i < "A" || i > "Z") &&
+ !state.funct["(scope)"].isPredefined(c.value)) {
+ warning("W055", state.tokens.curr);
+ }
+ }
+ }
+ } else {
+ if (c.id !== "." && c.id !== "[" && c.id !== "(") {
+ warning("W056", state.tokens.curr);
+ }
+ }
+ } else {
+ if (!state.option.supernew)
+ warning("W057", this);
+ }
+ if (state.tokens.next.id !== "(" && !state.option.supernew) {
+ warning("W058", state.tokens.curr, state.tokens.curr.value);
+ }
+ this.first = this.right = c;
+ return this;
+ });
+ state.syntax["new"].exps = true;
+
+ prefix("void").exps = true;
+
+ infix(".", function(left, that) {
+ var m = identifier(false, true);
+
+ if (typeof m === "string") {
+ countMember(m);
+ }
+
+ that.left = left;
+ that.right = m;
+
+ if (m && m === "hasOwnProperty" && state.tokens.next.value === "=") {
+ warning("W001");
+ }
+
+ if (left && left.value === "arguments" && (m === "callee" || m === "caller")) {
+ if (state.option.noarg)
+ warning("W059", left, m);
+ else if (state.isStrict())
+ error("E008");
+ } else if (!state.option.evil && left && left.value === "document" &&
+ (m === "write" || m === "writeln")) {
+ warning("W060", left);
+ }
+
+ if (!state.option.evil && (m === "eval" || m === "execScript")) {
+ if (isGlobalEval(left, state)) {
+ warning("W061");
+ }
+ }
+
+ return that;
+ }, 160, true);
+
+ infix("(", function(left, that) {
+ if (state.option.immed && left && !left.immed && left.id === "function") {
+ warning("W062");
+ }
+
+ var n = 0;
+ var p = [];
+
+ if (left) {
+ if (left.type === "(identifier)") {
+ if (left.value.match(/^[A-Z]([A-Z0-9_$]*[a-z][A-Za-z0-9_$]*)?$/)) {
+ if ("Array Number String Boolean Date Object Error Symbol".indexOf(left.value) === -1) {
+ if (left.value === "Math") {
+ warning("W063", left);
+ } else if (state.option.newcap) {
+ warning("W064", left);
+ }
+ }
+ }
+ }
+ }
+
+ if (state.tokens.next.id !== ")") {
+ for (;;) {
+ p[p.length] = expression(10);
+ n += 1;
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ comma();
+ }
+ }
+
+ advance(")");
+
+ if (typeof left === "object") {
+ if (!state.inES5() && left.value === "parseInt" && n === 1) {
+ warning("W065", state.tokens.curr);
+ }
+ if (!state.option.evil) {
+ if (left.value === "eval" || left.value === "Function" ||
+ left.value === "execScript") {
+ warning("W061", left);
+
+ if (p[0] && [0].id === "(string)") {
+ addInternalSrc(left, p[0].value);
+ }
+ } else if (p[0] && p[0].id === "(string)" &&
+ (left.value === "setTimeout" ||
+ left.value === "setInterval")) {
+ warning("W066", left);
+ addInternalSrc(left, p[0].value);
+ } else if (p[0] && p[0].id === "(string)" &&
+ left.value === "." &&
+ left.left.value === "window" &&
+ (left.right === "setTimeout" ||
+ left.right === "setInterval")) {
+ warning("W066", left);
+ addInternalSrc(left, p[0].value);
+ }
+ }
+ if (!left.identifier && left.id !== "." && left.id !== "[" && left.id !== "=>" &&
+ left.id !== "(" && left.id !== "&&" && left.id !== "||" && left.id !== "?" &&
+ !(state.inES6() && left["(name)"])) {
+ warning("W067", that);
+ }
+ }
+
+ that.left = left;
+ return that;
+ }, 155, true).exps = true;
+
+ prefix("(", function() {
+ var pn = state.tokens.next, pn1, i = -1;
+ var ret, triggerFnExpr, first, last;
+ var parens = 1;
+ var opening = state.tokens.curr;
+ var preceeding = state.tokens.prev;
+ var isNecessary = !state.option.singleGroups;
+
+ do {
+ if (pn.value === "(") {
+ parens += 1;
+ } else if (pn.value === ")") {
+ parens -= 1;
+ }
+
+ i += 1;
+ pn1 = pn;
+ pn = peek(i);
+ } while (!(parens === 0 && pn1.value === ")") && pn.value !== ";" && pn.type !== "(end)");
+
+ if (state.tokens.next.id === "function") {
+ triggerFnExpr = state.tokens.next.immed = true;
+ }
+ if (pn.value === "=>") {
+ return doFunction({ type: "arrow", parsedOpening: true });
+ }
+
+ var exprs = [];
+
+ if (state.tokens.next.id !== ")") {
+ for (;;) {
+ exprs.push(expression(10));
+
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+
+ if (state.option.nocomma) {
+ warning("W127");
+ }
+
+ comma();
+ }
+ }
+
+ advance(")", this);
+ if (state.option.immed && exprs[0] && exprs[0].id === "function") {
+ if (state.tokens.next.id !== "(" &&
+ state.tokens.next.id !== "." && state.tokens.next.id !== "[") {
+ warning("W068", this);
+ }
+ }
+
+ if (!exprs.length) {
+ return;
+ }
+ if (exprs.length > 1) {
+ ret = Object.create(state.syntax[","]);
+ ret.exprs = exprs;
+
+ first = exprs[0];
+ last = exprs[exprs.length - 1];
+
+ if (!isNecessary) {
+ isNecessary = preceeding.assign || preceeding.delim;
+ }
+ } else {
+ ret = first = last = exprs[0];
+
+ if (!isNecessary) {
+ isNecessary =
+ (opening.beginsStmt && (ret.id === "{" || triggerFnExpr || isFunctor(ret))) ||
+ (triggerFnExpr &&
+ (!isEndOfExpr() || state.tokens.prev.id !== "}")) ||
+ (isFunctor(ret) && !isEndOfExpr()) ||
+ (ret.id === "{" && preceeding.id === "=>") ||
+ (ret.type === "(number)" &&
+ checkPunctuator(pn, ".") && /^\d+$/.test(ret.value));
+ }
+ }
+
+ if (ret) {
+ if (!isNecessary && (first.left || first.right || ret.exprs)) {
+ isNecessary =
+ (!isBeginOfExpr(preceeding) && first.lbp <= preceeding.lbp) ||
+ (!isEndOfExpr() && last.lbp < state.tokens.next.lbp);
+ }
+
+ if (!isNecessary) {
+ warning("W126", opening);
+ }
+
+ ret.paren = true;
+ }
+
+ return ret;
+ });
+
+ application("=>");
+
+ infix("[", function(left, that) {
+ var e = expression(10), s;
+ if (e && e.type === "(string)") {
+ if (!state.option.evil && (e.value === "eval" || e.value === "execScript")) {
+ if (isGlobalEval(left, state)) {
+ warning("W061");
+ }
+ }
+
+ countMember(e.value);
+ if (!state.option.sub && reg.identifier.test(e.value)) {
+ s = state.syntax[e.value];
+ if (!s || !isReserved(s)) {
+ warning("W069", state.tokens.prev, e.value);
+ }
+ }
+ }
+ advance("]", that);
+
+ if (e && e.value === "hasOwnProperty" && state.tokens.next.value === "=") {
+ warning("W001");
+ }
+
+ that.left = left;
+ that.right = e;
+ return that;
+ }, 160, true);
+
+ function comprehensiveArrayExpression() {
+ var res = {};
+ res.exps = true;
+ state.funct["(comparray)"].stack();
+ var reversed = false;
+ if (state.tokens.next.value !== "for") {
+ reversed = true;
+ if (!state.inMoz()) {
+ warning("W116", state.tokens.next, "for", state.tokens.next.value);
+ }
+ state.funct["(comparray)"].setState("use");
+ res.right = expression(10);
+ }
+
+ advance("for");
+ if (state.tokens.next.value === "each") {
+ advance("each");
+ if (!state.inMoz()) {
+ warning("W118", state.tokens.curr, "for each");
+ }
+ }
+ advance("(");
+ state.funct["(comparray)"].setState("define");
+ res.left = expression(130);
+ if (_.contains(["in", "of"], state.tokens.next.value)) {
+ advance();
+ } else {
+ error("E045", state.tokens.curr);
+ }
+ state.funct["(comparray)"].setState("generate");
+ expression(10);
+
+ advance(")");
+ if (state.tokens.next.value === "if") {
+ advance("if");
+ advance("(");
+ state.funct["(comparray)"].setState("filter");
+ res.filter = expression(10);
+ advance(")");
+ }
+
+ if (!reversed) {
+ state.funct["(comparray)"].setState("use");
+ res.right = expression(10);
+ }
+
+ advance("]");
+ state.funct["(comparray)"].unstack();
+ return res;
+ }
+
+ prefix("[", function() {
+ var blocktype = lookupBlockType();
+ if (blocktype.isCompArray) {
+ if (!state.option.esnext && !state.inMoz()) {
+ warning("W118", state.tokens.curr, "array comprehension");
+ }
+ return comprehensiveArrayExpression();
+ } else if (blocktype.isDestAssign) {
+ this.destructAssign = destructuringPattern({ openingParsed: true, assignment: true });
+ return this;
+ }
+ var b = state.tokens.curr.line !== startLine(state.tokens.next);
+ this.first = [];
+ if (b) {
+ indent += state.option.indent;
+ if (state.tokens.next.from === indent + state.option.indent) {
+ indent += state.option.indent;
+ }
+ }
+ while (state.tokens.next.id !== "(end)") {
+ while (state.tokens.next.id === ",") {
+ if (!state.option.elision) {
+ if (!state.inES5()) {
+ warning("W070");
+ } else {
+ warning("W128");
+ do {
+ advance(",");
+ } while (state.tokens.next.id === ",");
+ continue;
+ }
+ }
+ advance(",");
+ }
+
+ if (state.tokens.next.id === "]") {
+ break;
+ }
+
+ this.first.push(expression(10));
+ if (state.tokens.next.id === ",") {
+ comma({ allowTrailing: true });
+ if (state.tokens.next.id === "]" && !state.inES5()) {
+ warning("W070", state.tokens.curr);
+ break;
+ }
+ } else {
+ break;
+ }
+ }
+ if (b) {
+ indent -= state.option.indent;
+ }
+ advance("]", this);
+ return this;
+ });
+
+
+ function isMethod() {
+ return state.funct["(statement)"] && state.funct["(statement)"].type === "class" ||
+ state.funct["(context)"] && state.funct["(context)"]["(verb)"] === "class";
+ }
+
+
+ function isPropertyName(token) {
+ return token.identifier || token.id === "(string)" || token.id === "(number)";
+ }
+
+
+ function propertyName(preserveOrToken) {
+ var id;
+ var preserve = true;
+ if (typeof preserveOrToken === "object") {
+ id = preserveOrToken;
+ } else {
+ preserve = preserveOrToken;
+ id = optionalidentifier(false, true, preserve);
+ }
+
+ if (!id) {
+ if (state.tokens.next.id === "(string)") {
+ id = state.tokens.next.value;
+ if (!preserve) {
+ advance();
+ }
+ } else if (state.tokens.next.id === "(number)") {
+ id = state.tokens.next.value.toString();
+ if (!preserve) {
+ advance();
+ }
+ }
+ } else if (typeof id === "object") {
+ if (id.id === "(string)" || id.id === "(identifier)") id = id.value;
+ else if (id.id === "(number)") id = id.value.toString();
+ }
+
+ if (id === "hasOwnProperty") {
+ warning("W001");
+ }
+
+ return id;
+ }
+ function functionparams(options) {
+ var next;
+ var paramsIds = [];
+ var ident;
+ var tokens = [];
+ var t;
+ var pastDefault = false;
+ var pastRest = false;
+ var arity = 0;
+ var loneArg = options && options.loneArg;
+
+ if (loneArg && loneArg.identifier === true) {
+ state.funct["(scope)"].addParam(loneArg.value, loneArg);
+ return { arity: 1, params: [ loneArg.value ] };
+ }
+
+ next = state.tokens.next;
+
+ if (!options || !options.parsedOpening) {
+ advance("(");
+ }
+
+ if (state.tokens.next.id === ")") {
+ advance(")");
+ return;
+ }
+
+ function addParam(addParamArgs) {
+ state.funct["(scope)"].addParam.apply(state.funct["(scope)"], addParamArgs);
+ }
+
+ for (;;) {
+ arity++;
+ var currentParams = [];
+
+ if (_.contains(["{", "["], state.tokens.next.id)) {
+ tokens = destructuringPattern();
+ for (t in tokens) {
+ t = tokens[t];
+ if (t.id) {
+ paramsIds.push(t.id);
+ currentParams.push([t.id, t.token]);
+ }
+ }
+ } else {
+ if (checkPunctuator(state.tokens.next, "...")) pastRest = true;
+ ident = identifier(true);
+ if (ident) {
+ paramsIds.push(ident);
+ currentParams.push([ident, state.tokens.curr]);
+ } else {
+ while (!checkPunctuators(state.tokens.next, [",", ")"])) advance();
+ }
+ }
+ if (pastDefault) {
+ if (state.tokens.next.id !== "=") {
+ error("W138", state.tokens.current);
+ }
+ }
+ if (state.tokens.next.id === "=") {
+ if (!state.inES6()) {
+ warning("W119", state.tokens.next, "default parameters", "6");
+ }
+ advance("=");
+ pastDefault = true;
+ expression(10);
+ }
+ currentParams.forEach(addParam);
+
+ if (state.tokens.next.id === ",") {
+ if (pastRest) {
+ warning("W131", state.tokens.next);
+ }
+ comma();
+ } else {
+ advance(")", next);
+ return { arity: arity, params: paramsIds };
+ }
+ }
+ }
+
+ function functor(name, token, overwrites) {
+ var funct = {
+ "(name)" : name,
+ "(breakage)" : 0,
+ "(loopage)" : 0,
+ "(tokens)" : {},
+ "(properties)": {},
+
+ "(catch)" : false,
+ "(global)" : false,
+
+ "(line)" : null,
+ "(character)" : null,
+ "(metrics)" : null,
+ "(statement)" : null,
+ "(context)" : null,
+ "(scope)" : null,
+ "(comparray)" : null,
+ "(generator)" : null,
+ "(arrow)" : null,
+ "(params)" : null
+ };
+
+ if (token) {
+ _.extend(funct, {
+ "(line)" : token.line,
+ "(character)": token.character,
+ "(metrics)" : createMetrics(token)
+ });
+ }
+
+ _.extend(funct, overwrites);
+
+ if (funct["(context)"]) {
+ funct["(scope)"] = funct["(context)"]["(scope)"];
+ funct["(comparray)"] = funct["(context)"]["(comparray)"];
+ }
+
+ return funct;
+ }
+
+ function isFunctor(token) {
+ return "(scope)" in token;
+ }
+ function hasParsedCode(funct) {
+ return funct["(global)"] && !funct["(verb)"];
+ }
+
+ function doTemplateLiteral(left) {
+ var ctx = this.context;
+ var noSubst = this.noSubst;
+ var depth = this.depth;
+
+ if (!noSubst) {
+ while (!end()) {
+ if (!state.tokens.next.template || state.tokens.next.depth > depth) {
+ expression(0); // should probably have different rbp?
+ } else {
+ advance();
+ }
+ }
+ }
+
+ return {
+ id: "(template)",
+ type: "(template)",
+ tag: left
+ };
+
+ function end() {
+ if (state.tokens.curr.template && state.tokens.curr.tail &&
+ state.tokens.curr.context === ctx) return true;
+ var complete = (state.tokens.next.template && state.tokens.next.tail &&
+ state.tokens.next.context === ctx);
+ if (complete) advance();
+ return complete || state.tokens.next.isUnclosed;
+ }
+ }
+ function doFunction(options) {
+ var f, token, name, statement, classExprBinding, isGenerator, isArrow, ignoreLoopFunc;
+ var oldOption = state.option;
+ var oldIgnored = state.ignored;
+
+ if (options) {
+ name = options.name;
+ statement = options.statement;
+ classExprBinding = options.classExprBinding;
+ isGenerator = options.type === "generator";
+ isArrow = options.type === "arrow";
+ ignoreLoopFunc = options.ignoreLoopFunc;
+ }
+
+ state.option = Object.create(state.option);
+ state.ignored = Object.create(state.ignored);
+
+ state.funct = functor(name || state.nameStack.infer(), state.tokens.next, {
+ "(statement)": statement,
+ "(context)": state.funct,
+ "(arrow)": isArrow,
+ "(generator)": isGenerator
+ });
+
+ f = state.funct;
+ token = state.tokens.curr;
+ token.funct = state.funct;
+
+ functions.push(state.funct);
+ state.funct["(scope)"].stack("functionouter");
+ var internallyAccessibleName = name || classExprBinding;
+ if (internallyAccessibleName) {
+ state.funct["(scope)"].block.add(internallyAccessibleName,
+ classExprBinding ? "class" : "function", state.tokens.curr, false);
+ }
+ state.funct["(scope)"].stack("functionparams");
+
+ var paramsInfo = functionparams(options);
+
+ if (paramsInfo) {
+ state.funct["(params)"] = paramsInfo.params;
+ state.funct["(metrics)"].arity = paramsInfo.arity;
+ state.funct["(metrics)"].verifyMaxParametersPerFunction();
+ } else {
+ state.funct["(metrics)"].arity = 0;
+ }
+
+ if (isArrow) {
+ if (!state.inES6(true)) {
+ warning("W119", state.tokens.curr, "arrow function syntax (=>)", "6");
+ }
+
+ if (!options.loneArg) {
+ advance("=>");
+ }
+ }
+
+ block(false, true, true, isArrow);
+
+ if (!state.option.noyield && isGenerator &&
+ state.funct["(generator)"] !== "yielded") {
+ warning("W124", state.tokens.curr);
+ }
+
+ state.funct["(metrics)"].verifyMaxStatementsPerFunction();
+ state.funct["(metrics)"].verifyMaxComplexityPerFunction();
+ state.funct["(unusedOption)"] = state.option.unused;
+ state.option = oldOption;
+ state.ignored = oldIgnored;
+ state.funct["(last)"] = state.tokens.curr.line;
+ state.funct["(lastcharacter)"] = state.tokens.curr.character;
+ state.funct["(scope)"].unstack(); // also does usage and label checks
+ state.funct["(scope)"].unstack();
+
+ state.funct = state.funct["(context)"];
+
+ if (!ignoreLoopFunc && !state.option.loopfunc && state.funct["(loopage)"]) {
+ if (f["(isCapturing)"]) {
+ warning("W083", token);
+ }
+ }
+
+ return f;
+ }
+
+ function createMetrics(functionStartToken) {
+ return {
+ statementCount: 0,
+ nestedBlockDepth: -1,
+ ComplexityCount: 1,
+ arity: 0,
+
+ verifyMaxStatementsPerFunction: function() {
+ if (state.option.maxstatements &&
+ this.statementCount > state.option.maxstatements) {
+ warning("W071", functionStartToken, this.statementCount);
+ }
+ },
+
+ verifyMaxParametersPerFunction: function() {
+ if (_.isNumber(state.option.maxparams) &&
+ this.arity > state.option.maxparams) {
+ warning("W072", functionStartToken, this.arity);
+ }
+ },
+
+ verifyMaxNestedBlockDepthPerFunction: function() {
+ if (state.option.maxdepth &&
+ this.nestedBlockDepth > 0 &&
+ this.nestedBlockDepth === state.option.maxdepth + 1) {
+ warning("W073", null, this.nestedBlockDepth);
+ }
+ },
+
+ verifyMaxComplexityPerFunction: function() {
+ var max = state.option.maxcomplexity;
+ var cc = this.ComplexityCount;
+ if (max && cc > max) {
+ warning("W074", functionStartToken, cc);
+ }
+ }
+ };
+ }
+
+ function increaseComplexityCount() {
+ state.funct["(metrics)"].ComplexityCount += 1;
+ }
+
+ function checkCondAssignment(expr) {
+ var id, paren;
+ if (expr) {
+ id = expr.id;
+ paren = expr.paren;
+ if (id === "," && (expr = expr.exprs[expr.exprs.length - 1])) {
+ id = expr.id;
+ paren = paren || expr.paren;
+ }
+ }
+ switch (id) {
+ case "=":
+ case "+=":
+ case "-=":
+ case "*=":
+ case "%=":
+ case "&=":
+ case "|=":
+ case "^=":
+ case "/=":
+ if (!paren && !state.option.boss) {
+ warning("W084");
+ }
+ }
+ }
+ function checkProperties(props) {
+ if (state.inES5()) {
+ for (var name in props) {
+ if (props[name] && props[name].setterToken && !props[name].getterToken) {
+ warning("W078", props[name].setterToken);
+ }
+ }
+ }
+ }
+
+ function metaProperty(name, c) {
+ if (checkPunctuator(state.tokens.next, ".")) {
+ var left = state.tokens.curr.id;
+ advance(".");
+ var id = identifier();
+ state.tokens.curr.isMetaProperty = true;
+ if (name !== id) {
+ error("E057", state.tokens.prev, left, id);
+ } else {
+ c();
+ }
+ return state.tokens.curr;
+ }
+ }
+
+ (function(x) {
+ x.nud = function() {
+ var b, f, i, p, t, isGeneratorMethod = false, nextVal;
+ var props = Object.create(null); // All properties, including accessors
+
+ b = state.tokens.curr.line !== startLine(state.tokens.next);
+ if (b) {
+ indent += state.option.indent;
+ if (state.tokens.next.from === indent + state.option.indent) {
+ indent += state.option.indent;
+ }
+ }
+
+ var blocktype = lookupBlockType();
+ if (blocktype.isDestAssign) {
+ this.destructAssign = destructuringPattern({ openingParsed: true, assignment: true });
+ return this;
+ }
+
+ for (;;) {
+ if (state.tokens.next.id === "}") {
+ break;
+ }
+
+ nextVal = state.tokens.next.value;
+ if (state.tokens.next.identifier &&
+ (peekIgnoreEOL().id === "," || peekIgnoreEOL().id === "}")) {
+ if (!state.inES6()) {
+ warning("W104", state.tokens.next, "object short notation", "6");
+ }
+ i = propertyName(true);
+ saveProperty(props, i, state.tokens.next);
+
+ expression(10);
+
+ } else if (peek().id !== ":" && (nextVal === "get" || nextVal === "set")) {
+ advance(nextVal);
+
+ if (!state.inES5()) {
+ error("E034");
+ }
+
+ i = propertyName();
+ if (!i && !state.inES6()) {
+ error("E035");
+ }
+ if (i) {
+ saveAccessor(nextVal, props, i, state.tokens.curr);
+ }
+
+ t = state.tokens.next;
+ f = doFunction();
+ p = f["(params)"];
+ if (nextVal === "get" && i && p) {
+ warning("W076", t, p[0], i);
+ } else if (nextVal === "set" && i && (!p || p.length !== 1)) {
+ warning("W077", t, i);
+ }
+ } else {
+ if (state.tokens.next.value === "*" && state.tokens.next.type === "(punctuator)") {
+ if (!state.inES6()) {
+ warning("W104", state.tokens.next, "generator functions", "6");
+ }
+ advance("*");
+ isGeneratorMethod = true;
+ } else {
+ isGeneratorMethod = false;
+ }
+
+ if (state.tokens.next.id === "[") {
+ i = computedPropertyName();
+ state.nameStack.set(i);
+ } else {
+ state.nameStack.set(state.tokens.next);
+ i = propertyName();
+ saveProperty(props, i, state.tokens.next);
+
+ if (typeof i !== "string") {
+ break;
+ }
+ }
+
+ if (state.tokens.next.value === "(") {
+ if (!state.inES6()) {
+ warning("W104", state.tokens.curr, "concise methods", "6");
+ }
+ doFunction({ type: isGeneratorMethod ? "generator" : null });
+ } else {
+ advance(":");
+ expression(10);
+ }
+ }
+
+ countMember(i);
+
+ if (state.tokens.next.id === ",") {
+ comma({ allowTrailing: true, property: true });
+ if (state.tokens.next.id === ",") {
+ warning("W070", state.tokens.curr);
+ } else if (state.tokens.next.id === "}" && !state.inES5()) {
+ warning("W070", state.tokens.curr);
+ }
+ } else {
+ break;
+ }
+ }
+ if (b) {
+ indent -= state.option.indent;
+ }
+ advance("}", this);
+
+ checkProperties(props);
+
+ return this;
+ };
+ x.fud = function() {
+ error("E036", state.tokens.curr);
+ };
+ }(delim("{")));
+
+ function destructuringPattern(options) {
+ var isAssignment = options && options.assignment;
+
+ if (!state.inES6()) {
+ warning("W104", state.tokens.curr,
+ isAssignment ? "destructuring assignment" : "destructuring binding", "6");
+ }
+
+ return destructuringPatternRecursive(options);
+ }
+
+ function destructuringPatternRecursive(options) {
+ var ids;
+ var identifiers = [];
+ var openingParsed = options && options.openingParsed;
+ var isAssignment = options && options.assignment;
+ var recursiveOptions = isAssignment ? { assignment: isAssignment } : null;
+ var firstToken = openingParsed ? state.tokens.curr : state.tokens.next;
+
+ var nextInnerDE = function() {
+ var ident;
+ if (checkPunctuators(state.tokens.next, ["[", "{"])) {
+ ids = destructuringPatternRecursive(recursiveOptions);
+ for (var id in ids) {
+ id = ids[id];
+ identifiers.push({ id: id.id, token: id.token });
+ }
+ } else if (checkPunctuator(state.tokens.next, ",")) {
+ identifiers.push({ id: null, token: state.tokens.curr });
+ } else if (checkPunctuator(state.tokens.next, "(")) {
+ advance("(");
+ nextInnerDE();
+ advance(")");
+ } else {
+ var is_rest = checkPunctuator(state.tokens.next, "...");
+
+ if (isAssignment) {
+ var identifierToken = is_rest ? peek(0) : state.tokens.next;
+ if (!identifierToken.identifier) {
+ warning("E030", identifierToken, identifierToken.value);
+ }
+ var assignTarget = expression(155);
+ if (assignTarget) {
+ checkLeftSideAssign(assignTarget);
+ if (assignTarget.identifier) {
+ ident = assignTarget.value;
+ }
+ }
+ } else {
+ ident = identifier();
+ }
+ if (ident) {
+ identifiers.push({ id: ident, token: state.tokens.curr });
+ }
+ return is_rest;
+ }
+ return false;
+ };
+ var assignmentProperty = function() {
+ var id;
+ if (checkPunctuator(state.tokens.next, "[")) {
+ advance("[");
+ expression(10);
+ advance("]");
+ advance(":");
+ nextInnerDE();
+ } else if (state.tokens.next.id === "(string)" ||
+ state.tokens.next.id === "(number)") {
+ advance();
+ advance(":");
+ nextInnerDE();
+ } else {
+ id = identifier();
+ if (checkPunctuator(state.tokens.next, ":")) {
+ advance(":");
+ nextInnerDE();
+ } else if (id) {
+ if (isAssignment) {
+ checkLeftSideAssign(state.tokens.curr);
+ }
+ identifiers.push({ id: id, token: state.tokens.curr });
+ }
+ }
+ };
+ if (checkPunctuator(firstToken, "[")) {
+ if (!openingParsed) {
+ advance("[");
+ }
+ if (checkPunctuator(state.tokens.next, "]")) {
+ warning("W137", state.tokens.curr);
+ }
+ var element_after_rest = false;
+ while (!checkPunctuator(state.tokens.next, "]")) {
+ if (nextInnerDE() && !element_after_rest &&
+ checkPunctuator(state.tokens.next, ",")) {
+ warning("W130", state.tokens.next);
+ element_after_rest = true;
+ }
+ if (checkPunctuator(state.tokens.next, "=")) {
+ if (checkPunctuator(state.tokens.prev, "...")) {
+ advance("]");
+ } else {
+ advance("=");
+ }
+ if (state.tokens.next.id === "undefined") {
+ warning("W080", state.tokens.prev, state.tokens.prev.value);
+ }
+ expression(10);
+ }
+ if (!checkPunctuator(state.tokens.next, "]")) {
+ advance(",");
+ }
+ }
+ advance("]");
+ } else if (checkPunctuator(firstToken, "{")) {
+
+ if (!openingParsed) {
+ advance("{");
+ }
+ if (checkPunctuator(state.tokens.next, "}")) {
+ warning("W137", state.tokens.curr);
+ }
+ while (!checkPunctuator(state.tokens.next, "}")) {
+ assignmentProperty();
+ if (checkPunctuator(state.tokens.next, "=")) {
+ advance("=");
+ if (state.tokens.next.id === "undefined") {
+ warning("W080", state.tokens.prev, state.tokens.prev.value);
+ }
+ expression(10);
+ }
+ if (!checkPunctuator(state.tokens.next, "}")) {
+ advance(",");
+ if (checkPunctuator(state.tokens.next, "}")) {
+ break;
+ }
+ }
+ }
+ advance("}");
+ }
+ return identifiers;
+ }
+
+ function destructuringPatternMatch(tokens, value) {
+ var first = value.first;
+
+ if (!first)
+ return;
+
+ _.zip(tokens, Array.isArray(first) ? first : [ first ]).forEach(function(val) {
+ var token = val[0];
+ var value = val[1];
+
+ if (token && value)
+ token.first = value;
+ else if (token && token.first && !value)
+ warning("W080", token.first, token.first.value);
+ });
+ }
+
+ function blockVariableStatement(type, statement, context) {
+
+ var prefix = context && context.prefix;
+ var inexport = context && context.inexport;
+ var isLet = type === "let";
+ var isConst = type === "const";
+ var tokens, lone, value, letblock;
+
+ if (!state.inES6()) {
+ warning("W104", state.tokens.curr, type, "6");
+ }
+
+ if (isLet && state.tokens.next.value === "(") {
+ if (!state.inMoz()) {
+ warning("W118", state.tokens.next, "let block");
+ }
+ advance("(");
+ state.funct["(scope)"].stack();
+ letblock = true;
+ } else if (state.funct["(noblockscopedvar)"]) {
+ error("E048", state.tokens.curr, isConst ? "Const" : "Let");
+ }
+
+ statement.first = [];
+ for (;;) {
+ var names = [];
+ if (_.contains(["{", "["], state.tokens.next.value)) {
+ tokens = destructuringPattern();
+ lone = false;
+ } else {
+ tokens = [ { id: identifier(), token: state.tokens.curr } ];
+ lone = true;
+ }
+
+ if (!prefix && isConst && state.tokens.next.id !== "=") {
+ warning("E012", state.tokens.curr, state.tokens.curr.value);
+ }
+
+ for (var t in tokens) {
+ if (tokens.hasOwnProperty(t)) {
+ t = tokens[t];
+ if (state.funct["(scope)"].block.isGlobal()) {
+ if (predefined[t.id] === false) {
+ warning("W079", t.token, t.id);
+ }
+ }
+ if (t.id && !state.funct["(noblockscopedvar)"]) {
+ state.funct["(scope)"].addlabel(t.id, {
+ type: type,
+ token: t.token });
+ names.push(t.token);
+
+ if (lone && inexport) {
+ state.funct["(scope)"].setExported(t.token.value, t.token);
+ }
+ }
+ }
+ }
+
+ if (state.tokens.next.id === "=") {
+ advance("=");
+ if (!prefix && state.tokens.next.id === "undefined") {
+ warning("W080", state.tokens.prev, state.tokens.prev.value);
+ }
+ if (!prefix && peek(0).id === "=" && state.tokens.next.identifier) {
+ warning("W120", state.tokens.next, state.tokens.next.value);
+ }
+ value = expression(prefix ? 120 : 10);
+ if (lone) {
+ tokens[0].first = value;
+ } else {
+ destructuringPatternMatch(names, value);
+ }
+ }
+
+ statement.first = statement.first.concat(names);
+
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ comma();
+ }
+ if (letblock) {
+ advance(")");
+ block(true, true);
+ statement.block = true;
+ state.funct["(scope)"].unstack();
+ }
+
+ return statement;
+ }
+
+ var conststatement = stmt("const", function(context) {
+ return blockVariableStatement("const", this, context);
+ });
+ conststatement.exps = true;
+
+ var letstatement = stmt("let", function(context) {
+ return blockVariableStatement("let", this, context);
+ });
+ letstatement.exps = true;
+
+ var varstatement = stmt("var", function(context) {
+ var prefix = context && context.prefix;
+ var inexport = context && context.inexport;
+ var tokens, lone, value;
+ var implied = context && context.implied;
+ var report = !(context && context.ignore);
+
+ this.first = [];
+ for (;;) {
+ var names = [];
+ if (_.contains(["{", "["], state.tokens.next.value)) {
+ tokens = destructuringPattern();
+ lone = false;
+ } else {
+ tokens = [ { id: identifier(), token: state.tokens.curr } ];
+ lone = true;
+ }
+
+ if (!(prefix && implied) && report && state.option.varstmt) {
+ warning("W132", this);
+ }
+
+ this.first = this.first.concat(names);
+
+ for (var t in tokens) {
+ if (tokens.hasOwnProperty(t)) {
+ t = tokens[t];
+ if (!implied && state.funct["(global)"]) {
+ if (predefined[t.id] === false) {
+ warning("W079", t.token, t.id);
+ } else if (state.option.futurehostile === false) {
+ if ((!state.inES5() && vars.ecmaIdentifiers[5][t.id] === false) ||
+ (!state.inES6() && vars.ecmaIdentifiers[6][t.id] === false)) {
+ warning("W129", t.token, t.id);
+ }
+ }
+ }
+ if (t.id) {
+ if (implied === "for") {
+
+ if (!state.funct["(scope)"].has(t.id)) {
+ if (report) warning("W088", t.token, t.id);
+ }
+ state.funct["(scope)"].block.use(t.id, t.token);
+ } else {
+ state.funct["(scope)"].addlabel(t.id, {
+ type: "var",
+ token: t.token });
+
+ if (lone && inexport) {
+ state.funct["(scope)"].setExported(t.id, t.token);
+ }
+ }
+ names.push(t.token);
+ }
+ }
+ }
+
+ if (state.tokens.next.id === "=") {
+ state.nameStack.set(state.tokens.curr);
+
+ advance("=");
+ if (!prefix && report && !state.funct["(loopage)"] &&
+ state.tokens.next.id === "undefined") {
+ warning("W080", state.tokens.prev, state.tokens.prev.value);
+ }
+ if (peek(0).id === "=" && state.tokens.next.identifier) {
+ if (!prefix && report &&
+ !state.funct["(params)"] ||
+ state.funct["(params)"].indexOf(state.tokens.next.value) === -1) {
+ warning("W120", state.tokens.next, state.tokens.next.value);
+ }
+ }
+ value = expression(prefix ? 120 : 10);
+ if (lone) {
+ tokens[0].first = value;
+ } else {
+ destructuringPatternMatch(names, value);
+ }
+ }
+
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ comma();
+ }
+
+ return this;
+ });
+ varstatement.exps = true;
+
+ blockstmt("class", function() {
+ return classdef.call(this, true);
+ });
+
+ function classdef(isStatement) {
+ if (!state.inES6()) {
+ warning("W104", state.tokens.curr, "class", "6");
+ }
+ if (isStatement) {
+ this.name = identifier();
+
+ state.funct["(scope)"].addlabel(this.name, {
+ type: "class",
+ token: state.tokens.curr });
+ } else if (state.tokens.next.identifier && state.tokens.next.value !== "extends") {
+ this.name = identifier();
+ this.namedExpr = true;
+ } else {
+ this.name = state.nameStack.infer();
+ }
+ classtail(this);
+ return this;
+ }
+
+ function classtail(c) {
+ var wasInClassBody = state.inClassBody;
+ if (state.tokens.next.value === "extends") {
+ advance("extends");
+ c.heritage = expression(10);
+ }
+
+ state.inClassBody = true;
+ advance("{");
+ c.body = classbody(c);
+ advance("}");
+ state.inClassBody = wasInClassBody;
+ }
+
+ function classbody(c) {
+ var name;
+ var isStatic;
+ var isGenerator;
+ var getset;
+ var props = Object.create(null);
+ var staticProps = Object.create(null);
+ var computed;
+ for (var i = 0; state.tokens.next.id !== "}"; ++i) {
+ name = state.tokens.next;
+ isStatic = false;
+ isGenerator = false;
+ getset = null;
+ if (name.id === ";") {
+ warning("W032");
+ advance(";");
+ continue;
+ }
+
+ if (name.id === "*") {
+ isGenerator = true;
+ advance("*");
+ name = state.tokens.next;
+ }
+ if (name.id === "[") {
+ name = computedPropertyName();
+ computed = true;
+ } else if (isPropertyName(name)) {
+ advance();
+ computed = false;
+ if (name.identifier && name.value === "static") {
+ if (checkPunctuator(state.tokens.next, "*")) {
+ isGenerator = true;
+ advance("*");
+ }
+ if (isPropertyName(state.tokens.next) || state.tokens.next.id === "[") {
+ computed = state.tokens.next.id === "[";
+ isStatic = true;
+ name = state.tokens.next;
+ if (state.tokens.next.id === "[") {
+ name = computedPropertyName();
+ } else advance();
+ }
+ }
+
+ if (name.identifier && (name.value === "get" || name.value === "set")) {
+ if (isPropertyName(state.tokens.next) || state.tokens.next.id === "[") {
+ computed = state.tokens.next.id === "[";
+ getset = name;
+ name = state.tokens.next;
+ if (state.tokens.next.id === "[") {
+ name = computedPropertyName();
+ } else advance();
+ }
+ }
+ } else {
+ warning("W052", state.tokens.next, state.tokens.next.value || state.tokens.next.type);
+ advance();
+ continue;
+ }
+
+ if (!checkPunctuator(state.tokens.next, "(")) {
+ error("E054", state.tokens.next, state.tokens.next.value);
+ while (state.tokens.next.id !== "}" &&
+ !checkPunctuator(state.tokens.next, "(")) {
+ advance();
+ }
+ if (state.tokens.next.value !== "(") {
+ doFunction({ statement: c });
+ }
+ }
+
+ if (!computed) {
+ if (getset) {
+ saveAccessor(
+ getset.value, isStatic ? staticProps : props, name.value, name, true, isStatic);
+ } else {
+ if (name.value === "constructor") {
+ state.nameStack.set(c);
+ } else {
+ state.nameStack.set(name);
+ }
+ saveProperty(isStatic ? staticProps : props, name.value, name, true, isStatic);
+ }
+ }
+
+ if (getset && name.value === "constructor") {
+ var propDesc = getset.value === "get" ? "class getter method" : "class setter method";
+ error("E049", name, propDesc, "constructor");
+ } else if (name.value === "prototype") {
+ error("E049", name, "class method", "prototype");
+ }
+
+ propertyName(name);
+
+ doFunction({
+ statement: c,
+ type: isGenerator ? "generator" : null,
+ classExprBinding: c.namedExpr ? c.name : null
+ });
+ }
+
+ checkProperties(props);
+ }
+
+ blockstmt("function", function(context) {
+ var inexport = context && context.inexport;
+ var generator = false;
+ if (state.tokens.next.value === "*") {
+ advance("*");
+ if (state.inES6({ strict: true })) {
+ generator = true;
+ } else {
+ warning("W119", state.tokens.curr, "function*", "6");
+ }
+ }
+ if (inblock) {
+ warning("W082", state.tokens.curr);
+ }
+ var i = optionalidentifier();
+
+ state.funct["(scope)"].addlabel(i, {
+ type: "function",
+ token: state.tokens.curr });
+
+ if (i === undefined) {
+ warning("W025");
+ } else if (inexport) {
+ state.funct["(scope)"].setExported(i, state.tokens.prev);
+ }
+
+ doFunction({
+ name: i,
+ statement: this,
+ type: generator ? "generator" : null,
+ ignoreLoopFunc: inblock // a declaration may already have warned
+ });
+ if (state.tokens.next.id === "(" && state.tokens.next.line === state.tokens.curr.line) {
+ error("E039");
+ }
+ return this;
+ });
+
+ prefix("function", function() {
+ var generator = false;
+
+ if (state.tokens.next.value === "*") {
+ if (!state.inES6()) {
+ warning("W119", state.tokens.curr, "function*", "6");
+ }
+ advance("*");
+ generator = true;
+ }
+
+ var i = optionalidentifier();
+ doFunction({ name: i, type: generator ? "generator" : null });
+ return this;
+ });
+
+ blockstmt("if", function() {
+ var t = state.tokens.next;
+ increaseComplexityCount();
+ state.condition = true;
+ advance("(");
+ var expr = expression(0);
+ checkCondAssignment(expr);
+ var forinifcheck = null;
+ if (state.option.forin && state.forinifcheckneeded) {
+ state.forinifcheckneeded = false; // We only need to analyze the first if inside the loop
+ forinifcheck = state.forinifchecks[state.forinifchecks.length - 1];
+ if (expr.type === "(punctuator)" && expr.value === "!") {
+ forinifcheck.type = "(negative)";
+ } else {
+ forinifcheck.type = "(positive)";
+ }
+ }
+
+ advance(")", t);
+ state.condition = false;
+ var s = block(true, true);
+ if (forinifcheck && forinifcheck.type === "(negative)") {
+ if (s && s[0] && s[0].type === "(identifier)" && s[0].value === "continue") {
+ forinifcheck.type = "(negative-with-continue)";
+ }
+ }
+
+ if (state.tokens.next.id === "else") {
+ advance("else");
+ if (state.tokens.next.id === "if" || state.tokens.next.id === "switch") {
+ statement();
+ } else {
+ block(true, true);
+ }
+ }
+ return this;
+ });
+
+ blockstmt("try", function() {
+ var b;
+
+ function doCatch() {
+ advance("catch");
+ advance("(");
+
+ state.funct["(scope)"].stack("catchparams");
+
+ if (checkPunctuators(state.tokens.next, ["[", "{"])) {
+ var tokens = destructuringPattern();
+ _.each(tokens, function(token) {
+ if (token.id) {
+ state.funct["(scope)"].addParam(token.id, token, "exception");
+ }
+ });
+ } else if (state.tokens.next.type !== "(identifier)") {
+ warning("E030", state.tokens.next, state.tokens.next.value);
+ } else {
+ state.funct["(scope)"].addParam(identifier(), state.tokens.curr, "exception");
+ }
+
+ if (state.tokens.next.value === "if") {
+ if (!state.inMoz()) {
+ warning("W118", state.tokens.curr, "catch filter");
+ }
+ advance("if");
+ expression(0);
+ }
+
+ advance(")");
+
+ block(false);
+
+ state.funct["(scope)"].unstack();
+ }
+
+ block(true);
+
+ while (state.tokens.next.id === "catch") {
+ increaseComplexityCount();
+ if (b && (!state.inMoz())) {
+ warning("W118", state.tokens.next, "multiple catch blocks");
+ }
+ doCatch();
+ b = true;
+ }
+
+ if (state.tokens.next.id === "finally") {
+ advance("finally");
+ block(true);
+ return;
+ }
+
+ if (!b) {
+ error("E021", state.tokens.next, "catch", state.tokens.next.value);
+ }
+
+ return this;
+ });
+
+ blockstmt("while", function() {
+ var t = state.tokens.next;
+ state.funct["(breakage)"] += 1;
+ state.funct["(loopage)"] += 1;
+ increaseComplexityCount();
+ advance("(");
+ checkCondAssignment(expression(0));
+ advance(")", t);
+ block(true, true);
+ state.funct["(breakage)"] -= 1;
+ state.funct["(loopage)"] -= 1;
+ return this;
+ }).labelled = true;
+
+ blockstmt("with", function() {
+ var t = state.tokens.next;
+ if (state.isStrict()) {
+ error("E010", state.tokens.curr);
+ } else if (!state.option.withstmt) {
+ warning("W085", state.tokens.curr);
+ }
+
+ advance("(");
+ expression(0);
+ advance(")", t);
+ block(true, true);
+
+ return this;
+ });
+
+ blockstmt("switch", function() {
+ var t = state.tokens.next;
+ var g = false;
+ var noindent = false;
+
+ state.funct["(breakage)"] += 1;
+ advance("(");
+ checkCondAssignment(expression(0));
+ advance(")", t);
+ t = state.tokens.next;
+ advance("{");
+
+ if (state.tokens.next.from === indent)
+ noindent = true;
+
+ if (!noindent)
+ indent += state.option.indent;
+
+ this.cases = [];
+
+ for (;;) {
+ switch (state.tokens.next.id) {
+ case "case":
+ switch (state.funct["(verb)"]) {
+ case "yield":
+ case "break":
+ case "case":
+ case "continue":
+ case "return":
+ case "switch":
+ case "throw":
+ break;
+ default:
+ if (!state.tokens.curr.caseFallsThrough) {
+ warning("W086", state.tokens.curr, "case");
+ }
+ }
+
+ advance("case");
+ this.cases.push(expression(0));
+ increaseComplexityCount();
+ g = true;
+ advance(":");
+ state.funct["(verb)"] = "case";
+ break;
+ case "default":
+ switch (state.funct["(verb)"]) {
+ case "yield":
+ case "break":
+ case "continue":
+ case "return":
+ case "throw":
+ break;
+ default:
+ if (this.cases.length) {
+ if (!state.tokens.curr.caseFallsThrough) {
+ warning("W086", state.tokens.curr, "default");
+ }
+ }
+ }
+
+ advance("default");
+ g = true;
+ advance(":");
+ break;
+ case "}":
+ if (!noindent)
+ indent -= state.option.indent;
+
+ advance("}", t);
+ state.funct["(breakage)"] -= 1;
+ state.funct["(verb)"] = undefined;
+ return;
+ case "(end)":
+ error("E023", state.tokens.next, "}");
+ return;
+ default:
+ indent += state.option.indent;
+ if (g) {
+ switch (state.tokens.curr.id) {
+ case ",":
+ error("E040");
+ return;
+ case ":":
+ g = false;
+ statements();
+ break;
+ default:
+ error("E025", state.tokens.curr);
+ return;
+ }
+ } else {
+ if (state.tokens.curr.id === ":") {
+ advance(":");
+ error("E024", state.tokens.curr, ":");
+ statements();
+ } else {
+ error("E021", state.tokens.next, "case", state.tokens.next.value);
+ return;
+ }
+ }
+ indent -= state.option.indent;
+ }
+ }
+ return this;
+ }).labelled = true;
+
+ stmt("debugger", function() {
+ if (!state.option.debug) {
+ warning("W087", this);
+ }
+ return this;
+ }).exps = true;
+
+ (function() {
+ var x = stmt("do", function() {
+ state.funct["(breakage)"] += 1;
+ state.funct["(loopage)"] += 1;
+ increaseComplexityCount();
+
+ this.first = block(true, true);
+ advance("while");
+ var t = state.tokens.next;
+ advance("(");
+ checkCondAssignment(expression(0));
+ advance(")", t);
+ state.funct["(breakage)"] -= 1;
+ state.funct["(loopage)"] -= 1;
+ return this;
+ });
+ x.labelled = true;
+ x.exps = true;
+ }());
+
+ blockstmt("for", function() {
+ var s, t = state.tokens.next;
+ var letscope = false;
+ var foreachtok = null;
+
+ if (t.value === "each") {
+ foreachtok = t;
+ advance("each");
+ if (!state.inMoz()) {
+ warning("W118", state.tokens.curr, "for each");
+ }
+ }
+
+ increaseComplexityCount();
+ advance("(");
+ var nextop; // contains the token of the "in" or "of" operator
+ var i = 0;
+ var inof = ["in", "of"];
+ var level = 0; // BindingPattern "level" --- level 0 === no BindingPattern
+ var comma; // First comma punctuator at level 0
+ var initializer; // First initializer at level 0
+ if (checkPunctuators(state.tokens.next, ["{", "["])) ++level;
+ do {
+ nextop = peek(i);
+ ++i;
+ if (checkPunctuators(nextop, ["{", "["])) ++level;
+ else if (checkPunctuators(nextop, ["}", "]"])) --level;
+ if (level < 0) break;
+ if (level === 0) {
+ if (!comma && checkPunctuator(nextop, ",")) comma = nextop;
+ else if (!initializer && checkPunctuator(nextop, "=")) initializer = nextop;
+ }
+ } while (level > 0 || !_.contains(inof, nextop.value) && nextop.value !== ";" &&
+ nextop.type !== "(end)"); // Is this a JSCS bug? This looks really weird.
+ if (_.contains(inof, nextop.value)) {
+ if (!state.inES6() && nextop.value === "of") {
+ warning("W104", nextop, "for of", "6");
+ }
+
+ var ok = !(initializer || comma);
+ if (initializer) {
+ error("W133", comma, nextop.value, "initializer is forbidden");
+ }
+
+ if (comma) {
+ error("W133", comma, nextop.value, "more than one ForBinding");
+ }
+
+ if (state.tokens.next.id === "var") {
+ advance("var");
+ state.tokens.curr.fud({ prefix: true });
+ } else if (state.tokens.next.id === "let" || state.tokens.next.id === "const") {
+ advance(state.tokens.next.id);
+ letscope = true;
+ state.funct["(scope)"].stack();
+ state.tokens.curr.fud({ prefix: true });
+ } else {
+ Object.create(varstatement).fud({ prefix: true, implied: "for", ignore: !ok });
+ }
+ advance(nextop.value);
+ expression(20);
+ advance(")", t);
+
+ if (nextop.value === "in" && state.option.forin) {
+ state.forinifcheckneeded = true;
+
+ if (state.forinifchecks === undefined) {
+ state.forinifchecks = [];
+ }
+ state.forinifchecks.push({
+ type: "(none)"
+ });
+ }
+
+ state.funct["(breakage)"] += 1;
+ state.funct["(loopage)"] += 1;
+
+ s = block(true, true);
+
+ if (nextop.value === "in" && state.option.forin) {
+ if (state.forinifchecks && state.forinifchecks.length > 0) {
+ var check = state.forinifchecks.pop();
+
+ if (// No if statement or not the first statement in loop body
+ s && s.length > 0 && (typeof s[0] !== "object" || s[0].value !== "if") ||
+ check.type === "(positive)" && s.length > 1 ||
+ check.type === "(negative)") {
+ warning("W089", this);
+ }
+ }
+ state.forinifcheckneeded = false;
+ }
+
+ state.funct["(breakage)"] -= 1;
+ state.funct["(loopage)"] -= 1;
+ } else {
+ if (foreachtok) {
+ error("E045", foreachtok);
+ }
+ if (state.tokens.next.id !== ";") {
+ if (state.tokens.next.id === "var") {
+ advance("var");
+ state.tokens.curr.fud();
+ } else if (state.tokens.next.id === "let") {
+ advance("let");
+ letscope = true;
+ state.funct["(scope)"].stack();
+ state.tokens.curr.fud();
+ } else {
+ for (;;) {
+ expression(0, "for");
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ comma();
+ }
+ }
+ }
+ nolinebreak(state.tokens.curr);
+ advance(";");
+ state.funct["(loopage)"] += 1;
+ if (state.tokens.next.id !== ";") {
+ checkCondAssignment(expression(0));
+ }
+ nolinebreak(state.tokens.curr);
+ advance(";");
+ if (state.tokens.next.id === ";") {
+ error("E021", state.tokens.next, ")", ";");
+ }
+ if (state.tokens.next.id !== ")") {
+ for (;;) {
+ expression(0, "for");
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ comma();
+ }
+ }
+ advance(")", t);
+ state.funct["(breakage)"] += 1;
+ block(true, true);
+ state.funct["(breakage)"] -= 1;
+ state.funct["(loopage)"] -= 1;
+
+ }
+ if (letscope) {
+ state.funct["(scope)"].unstack();
+ }
+ return this;
+ }).labelled = true;
+
+
+ stmt("break", function() {
+ var v = state.tokens.next.value;
+
+ if (!state.option.asi)
+ nolinebreak(this);
+
+ if (state.tokens.next.id !== ";" && !state.tokens.next.reach &&
+ state.tokens.curr.line === startLine(state.tokens.next)) {
+ if (!state.funct["(scope)"].funct.hasBreakLabel(v)) {
+ warning("W090", state.tokens.next, v);
+ }
+ this.first = state.tokens.next;
+ advance();
+ } else {
+ if (state.funct["(breakage)"] === 0)
+ warning("W052", state.tokens.next, this.value);
+ }
+
+ reachable(this);
+
+ return this;
+ }).exps = true;
+
+
+ stmt("continue", function() {
+ var v = state.tokens.next.value;
+
+ if (state.funct["(breakage)"] === 0)
+ warning("W052", state.tokens.next, this.value);
+ if (!state.funct["(loopage)"])
+ warning("W052", state.tokens.next, this.value);
+
+ if (!state.option.asi)
+ nolinebreak(this);
+
+ if (state.tokens.next.id !== ";" && !state.tokens.next.reach) {
+ if (state.tokens.curr.line === startLine(state.tokens.next)) {
+ if (!state.funct["(scope)"].funct.hasBreakLabel(v)) {
+ warning("W090", state.tokens.next, v);
+ }
+ this.first = state.tokens.next;
+ advance();
+ }
+ }
+
+ reachable(this);
+
+ return this;
+ }).exps = true;
+
+
+ stmt("return", function() {
+ if (this.line === startLine(state.tokens.next)) {
+ if (state.tokens.next.id !== ";" && !state.tokens.next.reach) {
+ this.first = expression(0);
+
+ if (this.first &&
+ this.first.type === "(punctuator)" && this.first.value === "=" &&
+ !this.first.paren && !state.option.boss) {
+ warningAt("W093", this.first.line, this.first.character);
+ }
+ }
+ } else {
+ if (state.tokens.next.type === "(punctuator)" &&
+ ["[", "{", "+", "-"].indexOf(state.tokens.next.value) > -1) {
+ nolinebreak(this); // always warn (Line breaking error)
+ }
+ }
+
+ reachable(this);
+
+ return this;
+ }).exps = true;
+
+ (function(x) {
+ x.exps = true;
+ x.lbp = 25;
+ }(prefix("yield", function() {
+ var prev = state.tokens.prev;
+ if (state.inES6(true) && !state.funct["(generator)"]) {
+ if (!("(catch)" === state.funct["(name)"] && state.funct["(context)"]["(generator)"])) {
+ error("E046", state.tokens.curr, "yield");
+ }
+ } else if (!state.inES6()) {
+ warning("W104", state.tokens.curr, "yield", "6");
+ }
+ state.funct["(generator)"] = "yielded";
+ var delegatingYield = false;
+
+ if (state.tokens.next.value === "*") {
+ delegatingYield = true;
+ advance("*");
+ }
+
+ if (this.line === startLine(state.tokens.next) || !state.inMoz()) {
+ if (delegatingYield ||
+ (state.tokens.next.id !== ";" && !state.option.asi &&
+ !state.tokens.next.reach && state.tokens.next.nud)) {
+
+ nobreaknonadjacent(state.tokens.curr, state.tokens.next);
+ this.first = expression(10);
+
+ if (this.first.type === "(punctuator)" && this.first.value === "=" &&
+ !this.first.paren && !state.option.boss) {
+ warningAt("W093", this.first.line, this.first.character);
+ }
+ }
+
+ if (state.inMoz() && state.tokens.next.id !== ")" &&
+ (prev.lbp > 30 || (!prev.assign && !isEndOfExpr()) || prev.id === "yield")) {
+ error("E050", this);
+ }
+ } else if (!state.option.asi) {
+ nolinebreak(this); // always warn (Line breaking error)
+ }
+ return this;
+ })));
+
+
+ stmt("throw", function() {
+ nolinebreak(this);
+ this.first = expression(20);
+
+ reachable(this);
+
+ return this;
+ }).exps = true;
+
+ stmt("import", function() {
+ if (!state.inES6()) {
+ warning("W119", state.tokens.curr, "import", "6");
+ }
+
+ if (state.tokens.next.type === "(string)") {
+ advance("(string)");
+ return this;
+ }
+
+ if (state.tokens.next.identifier) {
+ this.name = identifier();
+ state.funct["(scope)"].addlabel(this.name, {
+ type: "const",
+ token: state.tokens.curr });
+
+ if (state.tokens.next.value === ",") {
+ advance(",");
+ } else {
+ advance("from");
+ advance("(string)");
+ return this;
+ }
+ }
+
+ if (state.tokens.next.id === "*") {
+ advance("*");
+ advance("as");
+ if (state.tokens.next.identifier) {
+ this.name = identifier();
+ state.funct["(scope)"].addlabel(this.name, {
+ type: "const",
+ token: state.tokens.curr });
+ }
+ } else {
+ advance("{");
+ for (;;) {
+ if (state.tokens.next.value === "}") {
+ advance("}");
+ break;
+ }
+ var importName;
+ if (state.tokens.next.type === "default") {
+ importName = "default";
+ advance("default");
+ } else {
+ importName = identifier();
+ }
+ if (state.tokens.next.value === "as") {
+ advance("as");
+ importName = identifier();
+ }
+ state.funct["(scope)"].addlabel(importName, {
+ type: "const",
+ token: state.tokens.curr });
+
+ if (state.tokens.next.value === ",") {
+ advance(",");
+ } else if (state.tokens.next.value === "}") {
+ advance("}");
+ break;
+ } else {
+ error("E024", state.tokens.next, state.tokens.next.value);
+ break;
+ }
+ }
+ }
+ advance("from");
+ advance("(string)");
+ return this;
+ }).exps = true;
+
+ stmt("export", function() {
+ var ok = true;
+ var token;
+ var identifier;
+
+ if (!state.inES6()) {
+ warning("W119", state.tokens.curr, "export", "6");
+ ok = false;
+ }
+
+ if (!state.funct["(scope)"].block.isGlobal()) {
+ error("E053", state.tokens.curr);
+ ok = false;
+ }
+
+ if (state.tokens.next.value === "*") {
+ advance("*");
+ advance("from");
+ advance("(string)");
+ return this;
+ }
+
+ if (state.tokens.next.type === "default") {
+ state.nameStack.set(state.tokens.next);
+ advance("default");
+ var exportType = state.tokens.next.id;
+ if (exportType === "function" || exportType === "class") {
+ this.block = true;
+ }
+
+ token = peek();
+
+ expression(10);
+
+ identifier = token.value;
+
+ if (this.block) {
+ state.funct["(scope)"].addlabel(identifier, {
+ type: exportType,
+ token: token });
+
+ state.funct["(scope)"].setExported(identifier, token);
+ }
+
+ return this;
+ }
+
+ if (state.tokens.next.value === "{") {
+ advance("{");
+ var exportedTokens = [];
+ for (;;) {
+ if (!state.tokens.next.identifier) {
+ error("E030", state.tokens.next, state.tokens.next.value);
+ }
+ advance();
+
+ exportedTokens.push(state.tokens.curr);
+
+ if (state.tokens.next.value === "as") {
+ advance("as");
+ if (!state.tokens.next.identifier) {
+ error("E030", state.tokens.next, state.tokens.next.value);
+ }
+ advance();
+ }
+
+ if (state.tokens.next.value === ",") {
+ advance(",");
+ } else if (state.tokens.next.value === "}") {
+ advance("}");
+ break;
+ } else {
+ error("E024", state.tokens.next, state.tokens.next.value);
+ break;
+ }
+ }
+ if (state.tokens.next.value === "from") {
+ advance("from");
+ advance("(string)");
+ } else if (ok) {
+ exportedTokens.forEach(function(token) {
+ state.funct["(scope)"].setExported(token.value, token);
+ });
+ }
+ return this;
+ }
+
+ if (state.tokens.next.id === "var") {
+ advance("var");
+ state.tokens.curr.fud({ inexport:true });
+ } else if (state.tokens.next.id === "let") {
+ advance("let");
+ state.tokens.curr.fud({ inexport:true });
+ } else if (state.tokens.next.id === "const") {
+ advance("const");
+ state.tokens.curr.fud({ inexport:true });
+ } else if (state.tokens.next.id === "function") {
+ this.block = true;
+ advance("function");
+ state.syntax["function"].fud({ inexport:true });
+ } else if (state.tokens.next.id === "class") {
+ this.block = true;
+ advance("class");
+ var classNameToken = state.tokens.next;
+ state.syntax["class"].fud();
+ state.funct["(scope)"].setExported(classNameToken.value, classNameToken);
+ } else {
+ error("E024", state.tokens.next, state.tokens.next.value);
+ }
+
+ return this;
+ }).exps = true;
+
+ FutureReservedWord("abstract");
+ FutureReservedWord("boolean");
+ FutureReservedWord("byte");
+ FutureReservedWord("char");
+ FutureReservedWord("class", { es5: true, nud: classdef });
+ FutureReservedWord("double");
+ FutureReservedWord("enum", { es5: true });
+ FutureReservedWord("export", { es5: true });
+ FutureReservedWord("extends", { es5: true });
+ FutureReservedWord("final");
+ FutureReservedWord("float");
+ FutureReservedWord("goto");
+ FutureReservedWord("implements", { es5: true, strictOnly: true });
+ FutureReservedWord("import", { es5: true });
+ FutureReservedWord("int");
+ FutureReservedWord("interface", { es5: true, strictOnly: true });
+ FutureReservedWord("long");
+ FutureReservedWord("native");
+ FutureReservedWord("package", { es5: true, strictOnly: true });
+ FutureReservedWord("private", { es5: true, strictOnly: true });
+ FutureReservedWord("protected", { es5: true, strictOnly: true });
+ FutureReservedWord("public", { es5: true, strictOnly: true });
+ FutureReservedWord("short");
+ FutureReservedWord("static", { es5: true, strictOnly: true });
+ FutureReservedWord("super", { es5: true });
+ FutureReservedWord("synchronized");
+ FutureReservedWord("transient");
+ FutureReservedWord("volatile");
+
+ var lookupBlockType = function() {
+ var pn, pn1, prev;
+ var i = -1;
+ var bracketStack = 0;
+ var ret = {};
+ if (checkPunctuators(state.tokens.curr, ["[", "{"])) {
+ bracketStack += 1;
+ }
+ do {
+ prev = i === -1 ? state.tokens.curr : pn;
+ pn = i === -1 ? state.tokens.next : peek(i);
+ pn1 = peek(i + 1);
+ i = i + 1;
+ if (checkPunctuators(pn, ["[", "{"])) {
+ bracketStack += 1;
+ } else if (checkPunctuators(pn, ["]", "}"])) {
+ bracketStack -= 1;
+ }
+ if (bracketStack === 1 && pn.identifier && pn.value === "for" &&
+ !checkPunctuator(prev, ".")) {
+ ret.isCompArray = true;
+ ret.notJson = true;
+ break;
+ }
+ if (bracketStack === 0 && checkPunctuators(pn, ["}", "]"])) {
+ if (pn1.value === "=") {
+ ret.isDestAssign = true;
+ ret.notJson = true;
+ break;
+ } else if (pn1.value === ".") {
+ ret.notJson = true;
+ break;
+ }
+ }
+ if (checkPunctuator(pn, ";")) {
+ ret.isBlock = true;
+ ret.notJson = true;
+ }
+ } while (bracketStack > 0 && pn.id !== "(end)");
+ return ret;
+ };
+
+ function saveProperty(props, name, tkn, isClass, isStatic) {
+ var msg = ["key", "class method", "static class method"];
+ msg = msg[(isClass || false) + (isStatic || false)];
+ if (tkn.identifier) {
+ name = tkn.value;
+ }
+
+ if (props[name] && name !== "__proto__") {
+ warning("W075", state.tokens.next, msg, name);
+ } else {
+ props[name] = Object.create(null);
+ }
+
+ props[name].basic = true;
+ props[name].basictkn = tkn;
+ }
+ function saveAccessor(accessorType, props, name, tkn, isClass, isStatic) {
+ var flagName = accessorType === "get" ? "getterToken" : "setterToken";
+ var msg = "";
+
+ if (isClass) {
+ if (isStatic) {
+ msg += "static ";
+ }
+ msg += accessorType + "ter method";
+ } else {
+ msg = "key";
+ }
+
+ state.tokens.curr.accessorType = accessorType;
+ state.nameStack.set(tkn);
+
+ if (props[name]) {
+ if ((props[name].basic || props[name][flagName]) && name !== "__proto__") {
+ warning("W075", state.tokens.next, msg, name);
+ }
+ } else {
+ props[name] = Object.create(null);
+ }
+
+ props[name][flagName] = tkn;
+ }
+
+ function computedPropertyName() {
+ advance("[");
+ if (!state.inES6()) {
+ warning("W119", state.tokens.curr, "computed property names", "6");
+ }
+ var value = expression(10);
+ advance("]");
+ return value;
+ }
+ function checkPunctuators(token, values) {
+ if (token.type === "(punctuator)") {
+ return _.contains(values, token.value);
+ }
+ return false;
+ }
+ function checkPunctuator(token, value) {
+ return token.type === "(punctuator)" && token.value === value;
+ }
+ function destructuringAssignOrJsonValue() {
+
+ var block = lookupBlockType();
+ if (block.notJson) {
+ if (!state.inES6() && block.isDestAssign) {
+ warning("W104", state.tokens.curr, "destructuring assignment", "6");
+ }
+ statements();
+ } else {
+ state.option.laxbreak = true;
+ state.jsonMode = true;
+ jsonValue();
+ }
+ }
+
+ var arrayComprehension = function() {
+ var CompArray = function() {
+ this.mode = "use";
+ this.variables = [];
+ };
+ var _carrays = [];
+ var _current;
+ function declare(v) {
+ var l = _current.variables.filter(function(elt) {
+ if (elt.value === v) {
+ elt.undef = false;
+ return v;
+ }
+ }).length;
+ return l !== 0;
+ }
+ function use(v) {
+ var l = _current.variables.filter(function(elt) {
+ if (elt.value === v && !elt.undef) {
+ if (elt.unused === true) {
+ elt.unused = false;
+ }
+ return v;
+ }
+ }).length;
+ return (l === 0);
+ }
+ return { stack: function() {
+ _current = new CompArray();
+ _carrays.push(_current);
+ },
+ unstack: function() {
+ _current.variables.filter(function(v) {
+ if (v.unused)
+ warning("W098", v.token, v.raw_text || v.value);
+ if (v.undef)
+ state.funct["(scope)"].block.use(v.value, v.token);
+ });
+ _carrays.splice(-1, 1);
+ _current = _carrays[_carrays.length - 1];
+ },
+ setState: function(s) {
+ if (_.contains(["use", "define", "generate", "filter"], s))
+ _current.mode = s;
+ },
+ check: function(v) {
+ if (!_current) {
+ return;
+ }
+ if (_current && _current.mode === "use") {
+ if (use(v)) {
+ _current.variables.push({
+ funct: state.funct,
+ token: state.tokens.curr,
+ value: v,
+ undef: true,
+ unused: false
+ });
+ }
+ return true;
+ } else if (_current && _current.mode === "define") {
+ if (!declare(v)) {
+ _current.variables.push({
+ funct: state.funct,
+ token: state.tokens.curr,
+ value: v,
+ undef: false,
+ unused: true
+ });
+ }
+ return true;
+ } else if (_current && _current.mode === "generate") {
+ state.funct["(scope)"].block.use(v, state.tokens.curr);
+ return true;
+ } else if (_current && _current.mode === "filter") {
+ if (use(v)) {
+ state.funct["(scope)"].block.use(v, state.tokens.curr);
+ }
+ return true;
+ }
+ return false;
+ }
+ };
+ };
+
+ function jsonValue() {
+ function jsonObject() {
+ var o = {}, t = state.tokens.next;
+ advance("{");
+ if (state.tokens.next.id !== "}") {
+ for (;;) {
+ if (state.tokens.next.id === "(end)") {
+ error("E026", state.tokens.next, t.line);
+ } else if (state.tokens.next.id === "}") {
+ warning("W094", state.tokens.curr);
+ break;
+ } else if (state.tokens.next.id === ",") {
+ error("E028", state.tokens.next);
+ } else if (state.tokens.next.id !== "(string)") {
+ warning("W095", state.tokens.next, state.tokens.next.value);
+ }
+ if (o[state.tokens.next.value] === true) {
+ warning("W075", state.tokens.next, "key", state.tokens.next.value);
+ } else if ((state.tokens.next.value === "__proto__" &&
+ !state.option.proto) || (state.tokens.next.value === "__iterator__" &&
+ !state.option.iterator)) {
+ warning("W096", state.tokens.next, state.tokens.next.value);
+ } else {
+ o[state.tokens.next.value] = true;
+ }
+ advance();
+ advance(":");
+ jsonValue();
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ advance(",");
+ }
+ }
+ advance("}");
+ }
+
+ function jsonArray() {
+ var t = state.tokens.next;
+ advance("[");
+ if (state.tokens.next.id !== "]") {
+ for (;;) {
+ if (state.tokens.next.id === "(end)") {
+ error("E027", state.tokens.next, t.line);
+ } else if (state.tokens.next.id === "]") {
+ warning("W094", state.tokens.curr);
+ break;
+ } else if (state.tokens.next.id === ",") {
+ error("E028", state.tokens.next);
+ }
+ jsonValue();
+ if (state.tokens.next.id !== ",") {
+ break;
+ }
+ advance(",");
+ }
+ }
+ advance("]");
+ }
+
+ switch (state.tokens.next.id) {
+ case "{":
+ jsonObject();
+ break;
+ case "[":
+ jsonArray();
+ break;
+ case "true":
+ case "false":
+ case "null":
+ case "(number)":
+ case "(string)":
+ advance();
+ break;
+ case "-":
+ advance("-");
+ advance("(number)");
+ break;
+ default:
+ error("E003", state.tokens.next);
+ }
+ }
+
+ var escapeRegex = function(str) {
+ return str.replace(/[-\/\\^$*+?.()|[\]{}]/g, "\\$&");
+ };
+ var itself = function(s, o, g) {
+ var i, k, x, reIgnoreStr, reIgnore;
+ var optionKeys;
+ var newOptionObj = {};
+ var newIgnoredObj = {};
+
+ o = _.clone(o);
+ state.reset();
+
+ if (o && o.scope) {
+ JSHINT.scope = o.scope;
+ } else {
+ JSHINT.errors = [];
+ JSHINT.undefs = [];
+ JSHINT.internals = [];
+ JSHINT.blacklist = {};
+ JSHINT.scope = "(main)";
+ }
+
+ predefined = Object.create(null);
+ combine(predefined, vars.ecmaIdentifiers[3]);
+ combine(predefined, vars.reservedVars);
+
+ combine(predefined, g || {});
+
+ declared = Object.create(null);
+ var exported = Object.create(null); // Variables that live outside the current file
+
+ function each(obj, cb) {
+ if (!obj)
+ return;
+
+ if (!Array.isArray(obj) && typeof obj === "object")
+ obj = Object.keys(obj);
+
+ obj.forEach(cb);
+ }
+
+ if (o) {
+ each(o.predef || null, function(item) {
+ var slice, prop;
+
+ if (item[0] === "-") {
+ slice = item.slice(1);
+ JSHINT.blacklist[slice] = slice;
+ delete predefined[slice];
+ } else {
+ prop = Object.getOwnPropertyDescriptor(o.predef, item);
+ predefined[item] = prop ? prop.value : false;
+ }
+ });
+
+ each(o.exported || null, function(item) {
+ exported[item] = true;
+ });
+
+ delete o.predef;
+ delete o.exported;
+
+ optionKeys = Object.keys(o);
+ for (x = 0; x < optionKeys.length; x++) {
+ if (/^-W\d{3}$/g.test(optionKeys[x])) {
+ newIgnoredObj[optionKeys[x].slice(1)] = true;
+ } else {
+ var optionKey = optionKeys[x];
+ newOptionObj[optionKey] = o[optionKey];
+ if ((optionKey === "esversion" && o[optionKey] === 5) ||
+ (optionKey === "es5" && o[optionKey])) {
+ warning("I003");
+ }
+
+ if (optionKeys[x] === "newcap" && o[optionKey] === false)
+ newOptionObj["(explicitNewcap)"] = true;
+ }
+ }
+ }
+
+ state.option = newOptionObj;
+ state.ignored = newIgnoredObj;
+
+ state.option.indent = state.option.indent || 4;
+ state.option.maxerr = state.option.maxerr || 50;
+
+ indent = 1;
+
+ var scopeManagerInst = scopeManager(state, predefined, exported, declared);
+ scopeManagerInst.on("warning", function(ev) {
+ warning.apply(null, [ ev.code, ev.token].concat(ev.data));
+ });
+
+ scopeManagerInst.on("error", function(ev) {
+ error.apply(null, [ ev.code, ev.token ].concat(ev.data));
+ });
+
+ state.funct = functor("(global)", null, {
+ "(global)" : true,
+ "(scope)" : scopeManagerInst,
+ "(comparray)" : arrayComprehension(),
+ "(metrics)" : createMetrics(state.tokens.next)
+ });
+
+ functions = [state.funct];
+ urls = [];
+ stack = null;
+ member = {};
+ membersOnly = null;
+ inblock = false;
+ lookahead = [];
+
+ if (!isString(s) && !Array.isArray(s)) {
+ errorAt("E004", 0);
+ return false;
+ }
+
+ api = {
+ get isJSON() {
+ return state.jsonMode;
+ },
+
+ getOption: function(name) {
+ return state.option[name] || null;
+ },
+
+ getCache: function(name) {
+ return state.cache[name];
+ },
+
+ setCache: function(name, value) {
+ state.cache[name] = value;
+ },
+
+ warn: function(code, data) {
+ warningAt.apply(null, [ code, data.line, data.char ].concat(data.data));
+ },
+
+ on: function(names, listener) {
+ names.split(" ").forEach(function(name) {
+ emitter.on(name, listener);
+ }.bind(this));
+ }
+ };
+
+ emitter.removeAllListeners();
+ (extraModules || []).forEach(function(func) {
+ func(api);
+ });
+
+ state.tokens.prev = state.tokens.curr = state.tokens.next = state.syntax["(begin)"];
+
+ if (o && o.ignoreDelimiters) {
+
+ if (!Array.isArray(o.ignoreDelimiters)) {
+ o.ignoreDelimiters = [o.ignoreDelimiters];
+ }
+
+ o.ignoreDelimiters.forEach(function(delimiterPair) {
+ if (!delimiterPair.start || !delimiterPair.end)
+ return;
+
+ reIgnoreStr = escapeRegex(delimiterPair.start) +
+ "[\\s\\S]*?" +
+ escapeRegex(delimiterPair.end);
+
+ reIgnore = new RegExp(reIgnoreStr, "ig");
+
+ s = s.replace(reIgnore, function(match) {
+ return match.replace(/./g, " ");
+ });
+ });
+ }
+
+ lex = new Lexer(s);
+
+ lex.on("warning", function(ev) {
+ warningAt.apply(null, [ ev.code, ev.line, ev.character].concat(ev.data));
+ });
+
+ lex.on("error", function(ev) {
+ errorAt.apply(null, [ ev.code, ev.line, ev.character ].concat(ev.data));
+ });
+
+ lex.on("fatal", function(ev) {
+ quit("E041", ev.line, ev.from);
+ });
+
+ lex.on("Identifier", function(ev) {
+ emitter.emit("Identifier", ev);
+ });
+
+ lex.on("String", function(ev) {
+ emitter.emit("String", ev);
+ });
+
+ lex.on("Number", function(ev) {
+ emitter.emit("Number", ev);
+ });
+
+ lex.start();
+ for (var name in o) {
+ if (_.has(o, name)) {
+ checkOption(name, state.tokens.curr);
+ }
+ }
+
+ assume();
+ combine(predefined, g || {});
+ comma.first = true;
+
+ try {
+ advance();
+ switch (state.tokens.next.id) {
+ case "{":
+ case "[":
+ destructuringAssignOrJsonValue();
+ break;
+ default:
+ directives();
+
+ if (state.directive["use strict"]) {
+ if (state.option.strict !== "global") {
+ warning("W097", state.tokens.prev);
+ }
+ }
+
+ statements();
+ }
+
+ if (state.tokens.next.id !== "(end)") {
+ quit("E041", state.tokens.curr.line);
+ }
+
+ state.funct["(scope)"].unstack();
+
+ } catch (err) {
+ if (err && err.name === "JSHintError") {
+ var nt = state.tokens.next || {};
+ JSHINT.errors.push({
+ scope : "(main)",
+ raw : err.raw,
+ code : err.code,
+ reason : err.message,
+ line : err.line || nt.line,
+ character : err.character || nt.from
+ }, null);
+ } else {
+ throw err;
+ }
+ }
+
+ if (JSHINT.scope === "(main)") {
+ o = o || {};
+
+ for (i = 0; i < JSHINT.internals.length; i += 1) {
+ k = JSHINT.internals[i];
+ o.scope = k.elem;
+ itself(k.value, o, g);
+ }
+ }
+
+ return JSHINT.errors.length === 0;
+ };
+ itself.addModule = function(func) {
+ extraModules.push(func);
+ };
+
+ itself.addModule(style.register);
+ itself.data = function() {
+ var data = {
+ functions: [],
+ options: state.option
+ };
+
+ var fu, f, i, j, n, globals;
+
+ if (itself.errors.length) {
+ data.errors = itself.errors;
+ }
+
+ if (state.jsonMode) {
+ data.json = true;
+ }
+
+ var impliedGlobals = state.funct["(scope)"].getImpliedGlobals();
+ if (impliedGlobals.length > 0) {
+ data.implieds = impliedGlobals;
+ }
+
+ if (urls.length > 0) {
+ data.urls = urls;
+ }
+
+ globals = state.funct["(scope)"].getUsedOrDefinedGlobals();
+ if (globals.length > 0) {
+ data.globals = globals;
+ }
+
+ for (i = 1; i < functions.length; i += 1) {
+ f = functions[i];
+ fu = {};
+
+ for (j = 0; j < functionicity.length; j += 1) {
+ fu[functionicity[j]] = [];
+ }
+
+ for (j = 0; j < functionicity.length; j += 1) {
+ if (fu[functionicity[j]].length === 0) {
+ delete fu[functionicity[j]];
+ }
+ }
+
+ fu.name = f["(name)"];
+ fu.param = f["(params)"];
+ fu.line = f["(line)"];
+ fu.character = f["(character)"];
+ fu.last = f["(last)"];
+ fu.lastcharacter = f["(lastcharacter)"];
+
+ fu.metrics = {
+ complexity: f["(metrics)"].ComplexityCount,
+ parameters: f["(metrics)"].arity,
+ statements: f["(metrics)"].statementCount
+ };
+
+ data.functions.push(fu);
+ }
+
+ var unuseds = state.funct["(scope)"].getUnuseds();
+ if (unuseds.length > 0) {
+ data.unused = unuseds;
+ }
+
+ for (n in member) {
+ if (typeof member[n] === "number") {
+ data.member = member;
+ break;
+ }
+ }
+
+ return data;
+ };
+
+ itself.jshint = itself;
+
+ return itself;
+}());
+if (typeof exports === "object" && exports) {
+ exports.JSHINT = JSHINT;
+}
+
+},{"../lodash":"/node_modules/jshint/lodash.js","./lex.js":"/node_modules/jshint/src/lex.js","./messages.js":"/node_modules/jshint/src/messages.js","./options.js":"/node_modules/jshint/src/options.js","./reg.js":"/node_modules/jshint/src/reg.js","./scope-manager.js":"/node_modules/jshint/src/scope-manager.js","./state.js":"/node_modules/jshint/src/state.js","./style.js":"/node_modules/jshint/src/style.js","./vars.js":"/node_modules/jshint/src/vars.js","events":"/node_modules/browserify/node_modules/events/events.js"}],"/node_modules/jshint/src/lex.js":[function(_dereq_,module,exports){
+
+"use strict";
+
+var _ = _dereq_("../lodash");
+var events = _dereq_("events");
+var reg = _dereq_("./reg.js");
+var state = _dereq_("./state.js").state;
+
+var unicodeData = _dereq_("../data/ascii-identifier-data.js");
+var asciiIdentifierStartTable = unicodeData.asciiIdentifierStartTable;
+var asciiIdentifierPartTable = unicodeData.asciiIdentifierPartTable;
+
+var Token = {
+ Identifier: 1,
+ Punctuator: 2,
+ NumericLiteral: 3,
+ StringLiteral: 4,
+ Comment: 5,
+ Keyword: 6,
+ NullLiteral: 7,
+ BooleanLiteral: 8,
+ RegExp: 9,
+ TemplateHead: 10,
+ TemplateMiddle: 11,
+ TemplateTail: 12,
+ NoSubstTemplate: 13
+};
+
+var Context = {
+ Block: 1,
+ Template: 2
+};
+
+function asyncTrigger() {
+ var _checks = [];
+
+ return {
+ push: function(fn) {
+ _checks.push(fn);
+ },
+
+ check: function() {
+ for (var check = 0; check < _checks.length; ++check) {
+ _checks[check]();
+ }
+
+ _checks.splice(0, _checks.length);
+ }
+ };
+}
+function Lexer(source) {
+ var lines = source;
+
+ if (typeof lines === "string") {
+ lines = lines
+ .replace(/\r\n/g, "\n")
+ .replace(/\r/g, "\n")
+ .split("\n");
+ }
+
+ if (lines[0] && lines[0].substr(0, 2) === "#!") {
+ if (lines[0].indexOf("node") !== -1) {
+ state.option.node = true;
+ }
+ lines[0] = "";
+ }
+
+ this.emitter = new events.EventEmitter();
+ this.source = source;
+ this.setLines(lines);
+ this.prereg = true;
+
+ this.line = 0;
+ this.char = 1;
+ this.from = 1;
+ this.input = "";
+ this.inComment = false;
+ this.context = [];
+ this.templateStarts = [];
+
+ for (var i = 0; i < state.option.indent; i += 1) {
+ state.tab += " ";
+ }
+ this.ignoreLinterErrors = false;
+}
+
+Lexer.prototype = {
+ _lines: [],
+
+ inContext: function(ctxType) {
+ return this.context.length > 0 && this.context[this.context.length - 1].type === ctxType;
+ },
+
+ pushContext: function(ctxType) {
+ this.context.push({ type: ctxType });
+ },
+
+ popContext: function() {
+ return this.context.pop();
+ },
+
+ isContext: function(context) {
+ return this.context.length > 0 && this.context[this.context.length - 1] === context;
+ },
+
+ currentContext: function() {
+ return this.context.length > 0 && this.context[this.context.length - 1];
+ },
+
+ getLines: function() {
+ this._lines = state.lines;
+ return this._lines;
+ },
+
+ setLines: function(val) {
+ this._lines = val;
+ state.lines = this._lines;
+ },
+ peek: function(i) {
+ return this.input.charAt(i || 0);
+ },
+ skip: function(i) {
+ i = i || 1;
+ this.char += i;
+ this.input = this.input.slice(i);
+ },
+ on: function(names, listener) {
+ names.split(" ").forEach(function(name) {
+ this.emitter.on(name, listener);
+ }.bind(this));
+ },
+ trigger: function() {
+ this.emitter.emit.apply(this.emitter, Array.prototype.slice.call(arguments));
+ },
+ triggerAsync: function(type, args, checks, fn) {
+ checks.push(function() {
+ if (fn()) {
+ this.trigger(type, args);
+ }
+ }.bind(this));
+ },
+ scanPunctuator: function() {
+ var ch1 = this.peek();
+ var ch2, ch3, ch4;
+
+ switch (ch1) {
+ case ".":
+ if ((/^[0-9]$/).test(this.peek(1))) {
+ return null;
+ }
+ if (this.peek(1) === "." && this.peek(2) === ".") {
+ return {
+ type: Token.Punctuator,
+ value: "..."
+ };
+ }
+ case "(":
+ case ")":
+ case ";":
+ case ",":
+ case "[":
+ case "]":
+ case ":":
+ case "~":
+ case "?":
+ return {
+ type: Token.Punctuator,
+ value: ch1
+ };
+ case "{":
+ this.pushContext(Context.Block);
+ return {
+ type: Token.Punctuator,
+ value: ch1
+ };
+ case "}":
+ if (this.inContext(Context.Block)) {
+ this.popContext();
+ }
+ return {
+ type: Token.Punctuator,
+ value: ch1
+ };
+ case "#":
+ return {
+ type: Token.Punctuator,
+ value: ch1
+ };
+ case "":
+ return null;
+ }
+
+ ch2 = this.peek(1);
+ ch3 = this.peek(2);
+ ch4 = this.peek(3);
+
+ if (ch1 === ">" && ch2 === ">" && ch3 === ">" && ch4 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: ">>>="
+ };
+ }
+
+ if (ch1 === "=" && ch2 === "=" && ch3 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: "==="
+ };
+ }
+
+ if (ch1 === "!" && ch2 === "=" && ch3 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: "!=="
+ };
+ }
+
+ if (ch1 === ">" && ch2 === ">" && ch3 === ">") {
+ return {
+ type: Token.Punctuator,
+ value: ">>>"
+ };
+ }
+
+ if (ch1 === "<" && ch2 === "<" && ch3 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: "<<="
+ };
+ }
+
+ if (ch1 === ">" && ch2 === ">" && ch3 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: ">>="
+ };
+ }
+ if (ch1 === "=" && ch2 === ">") {
+ return {
+ type: Token.Punctuator,
+ value: ch1 + ch2
+ };
+ }
+ if (ch1 === ch2 && ("+-<>&|".indexOf(ch1) >= 0)) {
+ return {
+ type: Token.Punctuator,
+ value: ch1 + ch2
+ };
+ }
+
+ if ("<>=!+-*%&|^".indexOf(ch1) >= 0) {
+ if (ch2 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: ch1 + ch2
+ };
+ }
+
+ return {
+ type: Token.Punctuator,
+ value: ch1
+ };
+ }
+
+ if (ch1 === "/") {
+ if (ch2 === "=") {
+ return {
+ type: Token.Punctuator,
+ value: "/="
+ };
+ }
+
+ return {
+ type: Token.Punctuator,
+ value: "/"
+ };
+ }
+
+ return null;
+ },
+ scanComments: function() {
+ var ch1 = this.peek();
+ var ch2 = this.peek(1);
+ var rest = this.input.substr(2);
+ var startLine = this.line;
+ var startChar = this.char;
+ var self = this;
+
+ function commentToken(label, body, opt) {
+ var special = ["jshint", "jslint", "members", "member", "globals", "global", "exported"];
+ var isSpecial = false;
+ var value = label + body;
+ var commentType = "plain";
+ opt = opt || {};
+
+ if (opt.isMultiline) {
+ value += "*/";
+ }
+
+ body = body.replace(/\n/g, " ");
+
+ if (label === "/*" && reg.fallsThrough.test(body)) {
+ isSpecial = true;
+ commentType = "falls through";
+ }
+
+ special.forEach(function(str) {
+ if (isSpecial) {
+ return;
+ }
+ if (label === "//" && str !== "jshint") {
+ return;
+ }
+
+ if (body.charAt(str.length) === " " && body.substr(0, str.length) === str) {
+ isSpecial = true;
+ label = label + str;
+ body = body.substr(str.length);
+ }
+
+ if (!isSpecial && body.charAt(0) === " " && body.charAt(str.length + 1) === " " &&
+ body.substr(1, str.length) === str) {
+ isSpecial = true;
+ label = label + " " + str;
+ body = body.substr(str.length + 1);
+ }
+
+ if (!isSpecial) {
+ return;
+ }
+
+ switch (str) {
+ case "member":
+ commentType = "members";
+ break;
+ case "global":
+ commentType = "globals";
+ break;
+ default:
+ var options = body.split(":").map(function(v) {
+ return v.replace(/^\s+/, "").replace(/\s+$/, "");
+ });
+
+ if (options.length === 2) {
+ switch (options[0]) {
+ case "ignore":
+ switch (options[1]) {
+ case "start":
+ self.ignoringLinterErrors = true;
+ isSpecial = false;
+ break;
+ case "end":
+ self.ignoringLinterErrors = false;
+ isSpecial = false;
+ break;
+ }
+ }
+ }
+
+ commentType = str;
+ }
+ });
+
+ return {
+ type: Token.Comment,
+ commentType: commentType,
+ value: value,
+ body: body,
+ isSpecial: isSpecial,
+ isMultiline: opt.isMultiline || false,
+ isMalformed: opt.isMalformed || false
+ };
+ }
+ if (ch1 === "*" && ch2 === "/") {
+ this.trigger("error", {
+ code: "E018",
+ line: startLine,
+ character: startChar
+ });
+
+ this.skip(2);
+ return null;
+ }
+ if (ch1 !== "/" || (ch2 !== "*" && ch2 !== "/")) {
+ return null;
+ }
+ if (ch2 === "/") {
+ this.skip(this.input.length); // Skip to the EOL.
+ return commentToken("//", rest);
+ }
+
+ var body = "";
+ if (ch2 === "*") {
+ this.inComment = true;
+ this.skip(2);
+
+ while (this.peek() !== "*" || this.peek(1) !== "/") {
+ if (this.peek() === "") { // End of Line
+ body += "\n";
+ if (!this.nextLine()) {
+ this.trigger("error", {
+ code: "E017",
+ line: startLine,
+ character: startChar
+ });
+
+ this.inComment = false;
+ return commentToken("/*", body, {
+ isMultiline: true,
+ isMalformed: true
+ });
+ }
+ } else {
+ body += this.peek();
+ this.skip();
+ }
+ }
+
+ this.skip(2);
+ this.inComment = false;
+ return commentToken("/*", body, { isMultiline: true });
+ }
+ },
+ scanKeyword: function() {
+ var result = /^[a-zA-Z_$][a-zA-Z0-9_$]*/.exec(this.input);
+ var keywords = [
+ "if", "in", "do", "var", "for", "new",
+ "try", "let", "this", "else", "case",
+ "void", "with", "enum", "while", "break",
+ "catch", "throw", "const", "yield", "class",
+ "super", "return", "typeof", "delete",
+ "switch", "export", "import", "default",
+ "finally", "extends", "function", "continue",
+ "debugger", "instanceof"
+ ];
+
+ if (result && keywords.indexOf(result[0]) >= 0) {
+ return {
+ type: Token.Keyword,
+ value: result[0]
+ };
+ }
+
+ return null;
+ },
+ scanIdentifier: function() {
+ var id = "";
+ var index = 0;
+ var type, char;
+
+ function isNonAsciiIdentifierStart(code) {
+ return code > 256;
+ }
+
+ function isNonAsciiIdentifierPart(code) {
+ return code > 256;
+ }
+
+ function isHexDigit(str) {
+ return (/^[0-9a-fA-F]$/).test(str);
+ }
+
+ var readUnicodeEscapeSequence = function() {
+ index += 1;
+
+ if (this.peek(index) !== "u") {
+ return null;
+ }
+
+ var ch1 = this.peek(index + 1);
+ var ch2 = this.peek(index + 2);
+ var ch3 = this.peek(index + 3);
+ var ch4 = this.peek(index + 4);
+ var code;
+
+ if (isHexDigit(ch1) && isHexDigit(ch2) && isHexDigit(ch3) && isHexDigit(ch4)) {
+ code = parseInt(ch1 + ch2 + ch3 + ch4, 16);
+
+ if (asciiIdentifierPartTable[code] || isNonAsciiIdentifierPart(code)) {
+ index += 5;
+ return "\\u" + ch1 + ch2 + ch3 + ch4;
+ }
+
+ return null;
+ }
+
+ return null;
+ }.bind(this);
+
+ var getIdentifierStart = function() {
+ var chr = this.peek(index);
+ var code = chr.charCodeAt(0);
+
+ if (code === 92) {
+ return readUnicodeEscapeSequence();
+ }
+
+ if (code < 128) {
+ if (asciiIdentifierStartTable[code]) {
+ index += 1;
+ return chr;
+ }
+
+ return null;
+ }
+
+ if (isNonAsciiIdentifierStart(code)) {
+ index += 1;
+ return chr;
+ }
+
+ return null;
+ }.bind(this);
+
+ var getIdentifierPart = function() {
+ var chr = this.peek(index);
+ var code = chr.charCodeAt(0);
+
+ if (code === 92) {
+ return readUnicodeEscapeSequence();
+ }
+
+ if (code < 128) {
+ if (asciiIdentifierPartTable[code]) {
+ index += 1;
+ return chr;
+ }
+
+ return null;
+ }
+
+ if (isNonAsciiIdentifierPart(code)) {
+ index += 1;
+ return chr;
+ }
+
+ return null;
+ }.bind(this);
+
+ function removeEscapeSequences(id) {
+ return id.replace(/\\u([0-9a-fA-F]{4})/g, function(m0, codepoint) {
+ return String.fromCharCode(parseInt(codepoint, 16));
+ });
+ }
+
+ char = getIdentifierStart();
+ if (char === null) {
+ return null;
+ }
+
+ id = char;
+ for (;;) {
+ char = getIdentifierPart();
+
+ if (char === null) {
+ break;
+ }
+
+ id += char;
+ }
+
+ switch (id) {
+ case "true":
+ case "false":
+ type = Token.BooleanLiteral;
+ break;
+ case "null":
+ type = Token.NullLiteral;
+ break;
+ default:
+ type = Token.Identifier;
+ }
+
+ return {
+ type: type,
+ value: removeEscapeSequences(id),
+ text: id,
+ tokenLength: id.length
+ };
+ },
+ scanNumericLiteral: function() {
+ var index = 0;
+ var value = "";
+ var length = this.input.length;
+ var char = this.peek(index);
+ var bad;
+ var isAllowedDigit = isDecimalDigit;
+ var base = 10;
+ var isLegacy = false;
+
+ function isDecimalDigit(str) {
+ return (/^[0-9]$/).test(str);
+ }
+
+ function isOctalDigit(str) {
+ return (/^[0-7]$/).test(str);
+ }
+
+ function isBinaryDigit(str) {
+ return (/^[01]$/).test(str);
+ }
+
+ function isHexDigit(str) {
+ return (/^[0-9a-fA-F]$/).test(str);
+ }
+
+ function isIdentifierStart(ch) {
+ return (ch === "$") || (ch === "_") || (ch === "\\") ||
+ (ch >= "a" && ch <= "z") || (ch >= "A" && ch <= "Z");
+ }
+
+ if (char !== "." && !isDecimalDigit(char)) {
+ return null;
+ }
+
+ if (char !== ".") {
+ value = this.peek(index);
+ index += 1;
+ char = this.peek(index);
+
+ if (value === "0") {
+ if (char === "x" || char === "X") {
+ isAllowedDigit = isHexDigit;
+ base = 16;
+
+ index += 1;
+ value += char;
+ }
+ if (char === "o" || char === "O") {
+ isAllowedDigit = isOctalDigit;
+ base = 8;
+
+ if (!state.inES6(true)) {
+ this.trigger("warning", {
+ code: "W119",
+ line: this.line,
+ character: this.char,
+ data: [ "Octal integer literal", "6" ]
+ });
+ }
+
+ index += 1;
+ value += char;
+ }
+ if (char === "b" || char === "B") {
+ isAllowedDigit = isBinaryDigit;
+ base = 2;
+
+ if (!state.inES6(true)) {
+ this.trigger("warning", {
+ code: "W119",
+ line: this.line,
+ character: this.char,
+ data: [ "Binary integer literal", "6" ]
+ });
+ }
+
+ index += 1;
+ value += char;
+ }
+ if (isOctalDigit(char)) {
+ isAllowedDigit = isOctalDigit;
+ base = 8;
+ isLegacy = true;
+ bad = false;
+
+ index += 1;
+ value += char;
+ }
+
+ if (!isOctalDigit(char) && isDecimalDigit(char)) {
+ index += 1;
+ value += char;
+ }
+ }
+
+ while (index < length) {
+ char = this.peek(index);
+
+ if (isLegacy && isDecimalDigit(char)) {
+ bad = true;
+ } else if (!isAllowedDigit(char)) {
+ break;
+ }
+ value += char;
+ index += 1;
+ }
+
+ if (isAllowedDigit !== isDecimalDigit) {
+ if (!isLegacy && value.length <= 2) { // 0x
+ return {
+ type: Token.NumericLiteral,
+ value: value,
+ isMalformed: true
+ };
+ }
+
+ if (index < length) {
+ char = this.peek(index);
+ if (isIdentifierStart(char)) {
+ return null;
+ }
+ }
+
+ return {
+ type: Token.NumericLiteral,
+ value: value,
+ base: base,
+ isLegacy: isLegacy,
+ isMalformed: false
+ };
+ }
+ }
+
+ if (char === ".") {
+ value += char;
+ index += 1;
+
+ while (index < length) {
+ char = this.peek(index);
+ if (!isDecimalDigit(char)) {
+ break;
+ }
+ value += char;
+ index += 1;
+ }
+ }
+
+ if (char === "e" || char === "E") {
+ value += char;
+ index += 1;
+ char = this.peek(index);
+
+ if (char === "+" || char === "-") {
+ value += this.peek(index);
+ index += 1;
+ }
+
+ char = this.peek(index);
+ if (isDecimalDigit(char)) {
+ value += char;
+ index += 1;
+
+ while (index < length) {
+ char = this.peek(index);
+ if (!isDecimalDigit(char)) {
+ break;
+ }
+ value += char;
+ index += 1;
+ }
+ } else {
+ return null;
+ }
+ }
+
+ if (index < length) {
+ char = this.peek(index);
+ if (isIdentifierStart(char)) {
+ return null;
+ }
+ }
+
+ return {
+ type: Token.NumericLiteral,
+ value: value,
+ base: base,
+ isMalformed: !isFinite(value)
+ };
+ },
+ scanEscapeSequence: function(checks) {
+ var allowNewLine = false;
+ var jump = 1;
+ this.skip();
+ var char = this.peek();
+
+ switch (char) {
+ case "'":
+ this.triggerAsync("warning", {
+ code: "W114",
+ line: this.line,
+ character: this.char,
+ data: [ "\\'" ]
+ }, checks, function() {return state.jsonMode; });
+ break;
+ case "b":
+ char = "\\b";
+ break;
+ case "f":
+ char = "\\f";
+ break;
+ case "n":
+ char = "\\n";
+ break;
+ case "r":
+ char = "\\r";
+ break;
+ case "t":
+ char = "\\t";
+ break;
+ case "0":
+ char = "\\0";
+ var n = parseInt(this.peek(1), 10);
+ this.triggerAsync("warning", {
+ code: "W115",
+ line: this.line,
+ character: this.char
+ }, checks,
+ function() { return n >= 0 && n <= 7 && state.isStrict(); });
+ break;
+ case "u":
+ var hexCode = this.input.substr(1, 4);
+ var code = parseInt(hexCode, 16);
+ if (isNaN(code)) {
+ this.trigger("warning", {
+ code: "W052",
+ line: this.line,
+ character: this.char,
+ data: [ "u" + hexCode ]
+ });
+ }
+ char = String.fromCharCode(code);
+ jump = 5;
+ break;
+ case "v":
+ this.triggerAsync("warning", {
+ code: "W114",
+ line: this.line,
+ character: this.char,
+ data: [ "\\v" ]
+ }, checks, function() { return state.jsonMode; });
+
+ char = "\v";
+ break;
+ case "x":
+ var x = parseInt(this.input.substr(1, 2), 16);
+
+ this.triggerAsync("warning", {
+ code: "W114",
+ line: this.line,
+ character: this.char,
+ data: [ "\\x-" ]
+ }, checks, function() { return state.jsonMode; });
+
+ char = String.fromCharCode(x);
+ jump = 3;
+ break;
+ case "\\":
+ char = "\\\\";
+ break;
+ case "\"":
+ char = "\\\"";
+ break;
+ case "/":
+ break;
+ case "":
+ allowNewLine = true;
+ char = "";
+ break;
+ }
+
+ return { char: char, jump: jump, allowNewLine: allowNewLine };
+ },
+ scanTemplateLiteral: function(checks) {
+ var tokenType;
+ var value = "";
+ var ch;
+ var startLine = this.line;
+ var startChar = this.char;
+ var depth = this.templateStarts.length;
+
+ if (!state.inES6(true)) {
+ return null;
+ } else if (this.peek() === "`") {
+ tokenType = Token.TemplateHead;
+ this.templateStarts.push({ line: this.line, char: this.char });
+ depth = this.templateStarts.length;
+ this.skip(1);
+ this.pushContext(Context.Template);
+ } else if (this.inContext(Context.Template) && this.peek() === "}") {
+ tokenType = Token.TemplateMiddle;
+ } else {
+ return null;
+ }
+
+ while (this.peek() !== "`") {
+ while ((ch = this.peek()) === "") {
+ value += "\n";
+ if (!this.nextLine()) {
+ var startPos = this.templateStarts.pop();
+ this.trigger("error", {
+ code: "E052",
+ line: startPos.line,
+ character: startPos.char
+ });
+ return {
+ type: tokenType,
+ value: value,
+ startLine: startLine,
+ startChar: startChar,
+ isUnclosed: true,
+ depth: depth,
+ context: this.popContext()
+ };
+ }
+ }
+
+ if (ch === '$' && this.peek(1) === '{') {
+ value += '${';
+ this.skip(2);
+ return {
+ type: tokenType,
+ value: value,
+ startLine: startLine,
+ startChar: startChar,
+ isUnclosed: false,
+ depth: depth,
+ context: this.currentContext()
+ };
+ } else if (ch === '\\') {
+ var escape = this.scanEscapeSequence(checks);
+ value += escape.char;
+ this.skip(escape.jump);
+ } else if (ch !== '`') {
+ value += ch;
+ this.skip(1);
+ }
+ }
+ tokenType = tokenType === Token.TemplateHead ? Token.NoSubstTemplate : Token.TemplateTail;
+ this.skip(1);
+ this.templateStarts.pop();
+
+ return {
+ type: tokenType,
+ value: value,
+ startLine: startLine,
+ startChar: startChar,
+ isUnclosed: false,
+ depth: depth,
+ context: this.popContext()
+ };
+ },
+ scanStringLiteral: function(checks) {
+ var quote = this.peek();
+ if (quote !== "\"" && quote !== "'") {
+ return null;
+ }
+ this.triggerAsync("warning", {
+ code: "W108",
+ line: this.line,
+ character: this.char // +1?
+ }, checks, function() { return state.jsonMode && quote !== "\""; });
+
+ var value = "";
+ var startLine = this.line;
+ var startChar = this.char;
+ var allowNewLine = false;
+
+ this.skip();
+
+ while (this.peek() !== quote) {
+ if (this.peek() === "") { // End Of Line
+
+ if (!allowNewLine) {
+ this.trigger("warning", {
+ code: "W112",
+ line: this.line,
+ character: this.char
+ });
+ } else {
+ allowNewLine = false;
+
+ this.triggerAsync("warning", {
+ code: "W043",
+ line: this.line,
+ character: this.char
+ }, checks, function() { return !state.option.multistr; });
+
+ this.triggerAsync("warning", {
+ code: "W042",
+ line: this.line,
+ character: this.char
+ }, checks, function() { return state.jsonMode && state.option.multistr; });
+ }
+
+ if (!this.nextLine()) {
+ this.trigger("error", {
+ code: "E029",
+ line: startLine,
+ character: startChar
+ });
+
+ return {
+ type: Token.StringLiteral,
+ value: value,
+ startLine: startLine,
+ startChar: startChar,
+ isUnclosed: true,
+ quote: quote
+ };
+ }
+
+ } else { // Any character other than End Of Line
+
+ allowNewLine = false;
+ var char = this.peek();
+ var jump = 1; // A length of a jump, after we're done
+
+ if (char < " ") {
+ this.trigger("warning", {
+ code: "W113",
+ line: this.line,
+ character: this.char,
+ data: [ "<non-printable>" ]
+ });
+ }
+ if (char === "\\") {
+ var parsed = this.scanEscapeSequence(checks);
+ char = parsed.char;
+ jump = parsed.jump;
+ allowNewLine = parsed.allowNewLine;
+ }
+
+ value += char;
+ this.skip(jump);
+ }
+ }
+
+ this.skip();
+ return {
+ type: Token.StringLiteral,
+ value: value,
+ startLine: startLine,
+ startChar: startChar,
+ isUnclosed: false,
+ quote: quote
+ };
+ },
+ scanRegExp: function() {
+ var index = 0;
+ var length = this.input.length;
+ var char = this.peek();
+ var value = char;
+ var body = "";
+ var flags = [];
+ var malformed = false;
+ var isCharSet = false;
+ var terminated;
+
+ var scanUnexpectedChars = function() {
+ if (char < " ") {
+ malformed = true;
+ this.trigger("warning", {
+ code: "W048",
+ line: this.line,
+ character: this.char
+ });
+ }
+ if (char === "<") {
+ malformed = true;
+ this.trigger("warning", {
+ code: "W049",
+ line: this.line,
+ character: this.char,
+ data: [ char ]
+ });
+ }
+ }.bind(this);
+ if (!this.prereg || char !== "/") {
+ return null;
+ }
+
+ index += 1;
+ terminated = false;
+
+ while (index < length) {
+ char = this.peek(index);
+ value += char;
+ body += char;
+
+ if (isCharSet) {
+ if (char === "]") {
+ if (this.peek(index - 1) !== "\\" || this.peek(index - 2) === "\\") {
+ isCharSet = false;
+ }
+ }
+
+ if (char === "\\") {
+ index += 1;
+ char = this.peek(index);
+ body += char;
+ value += char;
+
+ scanUnexpectedChars();
+ }
+
+ index += 1;
+ continue;
+ }
+
+ if (char === "\\") {
+ index += 1;
+ char = this.peek(index);
+ body += char;
+ value += char;
+
+ scanUnexpectedChars();
+
+ if (char === "/") {
+ index += 1;
+ continue;
+ }
+
+ if (char === "[") {
+ index += 1;
+ continue;
+ }
+ }
+
+ if (char === "[") {
+ isCharSet = true;
+ index += 1;
+ continue;
+ }
+
+ if (char === "/") {
+ body = body.substr(0, body.length - 1);
+ terminated = true;
+ index += 1;
+ break;
+ }
+
+ index += 1;
+ }
+
+ if (!terminated) {
+ this.trigger("error", {
+ code: "E015",
+ line: this.line,
+ character: this.from
+ });
+
+ return void this.trigger("fatal", {
+ line: this.line,
+ from: this.from
+ });
+ }
+
+ while (index < length) {
+ char = this.peek(index);
+ if (!/[gim]/.test(char)) {
+ break;
+ }
+ flags.push(char);
+ value += char;
+ index += 1;
+ }
+
+ try {
+ new RegExp(body, flags.join(""));
+ } catch (err) {
+ malformed = true;
+ this.trigger("error", {
+ code: "E016",
+ line: this.line,
+ character: this.char,
+ data: [ err.message ] // Platform dependent!
+ });
+ }
+
+ return {
+ type: Token.RegExp,
+ value: value,
+ flags: flags,
+ isMalformed: malformed
+ };
+ },
+ scanNonBreakingSpaces: function() {
+ return state.option.nonbsp ?
+ this.input.search(/(\u00A0)/) : -1;
+ },
+ scanUnsafeChars: function() {
+ return this.input.search(reg.unsafeChars);
+ },
+ next: function(checks) {
+ this.from = this.char;
+ var start;
+ if (/\s/.test(this.peek())) {
+ start = this.char;
+
+ while (/\s/.test(this.peek())) {
+ this.from += 1;
+ this.skip();
+ }
+ }
+
+ var match = this.scanComments() ||
+ this.scanStringLiteral(checks) ||
+ this.scanTemplateLiteral(checks);
+
+ if (match) {
+ return match;
+ }
+
+ match =
+ this.scanRegExp() ||
+ this.scanPunctuator() ||
+ this.scanKeyword() ||
+ this.scanIdentifier() ||
+ this.scanNumericLiteral();
+
+ if (match) {
+ this.skip(match.tokenLength || match.value.length);
+ return match;
+ }
+
+ return null;
+ },
+ nextLine: function() {
+ var char;
+
+ if (this.line >= this.getLines().length) {
+ return false;
+ }
+
+ this.input = this.getLines()[this.line];
+ this.line += 1;
+ this.char = 1;
+ this.from = 1;
+
+ var inputTrimmed = this.input.trim();
+
+ var startsWith = function() {
+ return _.some(arguments, function(prefix) {
+ return inputTrimmed.indexOf(prefix) === 0;
+ });
+ };
+
+ var endsWith = function() {
+ return _.some(arguments, function(suffix) {
+ return inputTrimmed.indexOf(suffix, inputTrimmed.length - suffix.length) !== -1;
+ });
+ };
+ if (this.ignoringLinterErrors === true) {
+ if (!startsWith("/*", "//") && !(this.inComment && endsWith("*/"))) {
+ this.input = "";
+ }
+ }
+
+ char = this.scanNonBreakingSpaces();
+ if (char >= 0) {
+ this.trigger("warning", { code: "W125", line: this.line, character: char + 1 });
+ }
+
+ this.input = this.input.replace(/\t/g, state.tab);
+ char = this.scanUnsafeChars();
+
+ if (char >= 0) {
+ this.trigger("warning", { code: "W100", line: this.line, character: char });
+ }
+
+ if (!this.ignoringLinterErrors && state.option.maxlen &&
+ state.option.maxlen < this.input.length) {
+ var inComment = this.inComment ||
+ startsWith.call(inputTrimmed, "//") ||
+ startsWith.call(inputTrimmed, "/*");
+
+ var shouldTriggerError = !inComment || !reg.maxlenException.test(inputTrimmed);
+
+ if (shouldTriggerError) {
+ this.trigger("warning", { code: "W101", line: this.line, character: this.input.length });
+ }
+ }
+
+ return true;
+ },
+ start: function() {
+ this.nextLine();
+ },
+ token: function() {
+ var checks = asyncTrigger();
+ var token;
+
+
+ function isReserved(token, isProperty) {
+ if (!token.reserved) {
+ return false;
+ }
+ var meta = token.meta;
+
+ if (meta && meta.isFutureReservedWord && state.inES5()) {
+ if (!meta.es5) {
+ return false;
+ }
+ if (meta.strictOnly) {
+ if (!state.option.strict && !state.isStrict()) {
+ return false;
+ }
+ }
+
+ if (isProperty) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+ var create = function(type, value, isProperty, token) {
+ var obj;
+
+ if (type !== "(endline)" && type !== "(end)") {
+ this.prereg = false;
+ }
+
+ if (type === "(punctuator)") {
+ switch (value) {
+ case ".":
+ case ")":
+ case "~":
+ case "#":
+ case "]":
+ case "++":
+ case "--":
+ this.prereg = false;
+ break;
+ default:
+ this.prereg = true;
+ }
+
+ obj = Object.create(state.syntax[value] || state.syntax["(error)"]);
+ }
+
+ if (type === "(identifier)") {
+ if (value === "return" || value === "case" || value === "typeof") {
+ this.prereg = true;
+ }
+
+ if (_.has(state.syntax, value)) {
+ obj = Object.create(state.syntax[value] || state.syntax["(error)"]);
+ if (!isReserved(obj, isProperty && type === "(identifier)")) {
+ obj = null;
+ }
+ }
+ }
+
+ if (!obj) {
+ obj = Object.create(state.syntax[type]);
+ }
+
+ obj.identifier = (type === "(identifier)");
+ obj.type = obj.type || type;
+ obj.value = value;
+ obj.line = this.line;
+ obj.character = this.char;
+ obj.from = this.from;
+ if (obj.identifier && token) obj.raw_text = token.text || token.value;
+ if (token && token.startLine && token.startLine !== this.line) {
+ obj.startLine = token.startLine;
+ }
+ if (token && token.context) {
+ obj.context = token.context;
+ }
+ if (token && token.depth) {
+ obj.depth = token.depth;
+ }
+ if (token && token.isUnclosed) {
+ obj.isUnclosed = token.isUnclosed;
+ }
+
+ if (isProperty && obj.identifier) {
+ obj.isProperty = isProperty;
+ }
+
+ obj.check = checks.check;
+
+ return obj;
+ }.bind(this);
+
+ for (;;) {
+ if (!this.input.length) {
+ if (this.nextLine()) {
+ return create("(endline)", "");
+ }
+
+ if (this.exhausted) {
+ return null;
+ }
+
+ this.exhausted = true;
+ return create("(end)", "");
+ }
+
+ token = this.next(checks);
+
+ if (!token) {
+ if (this.input.length) {
+ this.trigger("error", {
+ code: "E024",
+ line: this.line,
+ character: this.char,
+ data: [ this.peek() ]
+ });
+
+ this.input = "";
+ }
+
+ continue;
+ }
+
+ switch (token.type) {
+ case Token.StringLiteral:
+ this.triggerAsync("String", {
+ line: this.line,
+ char: this.char,
+ from: this.from,
+ startLine: token.startLine,
+ startChar: token.startChar,
+ value: token.value,
+ quote: token.quote
+ }, checks, function() { return true; });
+
+ return create("(string)", token.value, null, token);
+
+ case Token.TemplateHead:
+ this.trigger("TemplateHead", {
+ line: this.line,
+ char: this.char,
+ from: this.from,
+ startLine: token.startLine,
+ startChar: token.startChar,
+ value: token.value
+ });
+ return create("(template)", token.value, null, token);
+
+ case Token.TemplateMiddle:
+ this.trigger("TemplateMiddle", {
+ line: this.line,
+ char: this.char,
+ from: this.from,
+ startLine: token.startLine,
+ startChar: token.startChar,
+ value: token.value
+ });
+ return create("(template middle)", token.value, null, token);
+
+ case Token.TemplateTail:
+ this.trigger("TemplateTail", {
+ line: this.line,
+ char: this.char,
+ from: this.from,
+ startLine: token.startLine,
+ startChar: token.startChar,
+ value: token.value
+ });
+ return create("(template tail)", token.value, null, token);
+
+ case Token.NoSubstTemplate:
+ this.trigger("NoSubstTemplate", {
+ line: this.line,
+ char: this.char,
+ from: this.from,
+ startLine: token.startLine,
+ startChar: token.startChar,
+ value: token.value
+ });
+ return create("(no subst template)", token.value, null, token);
+
+ case Token.Identifier:
+ this.triggerAsync("Identifier", {
+ line: this.line,
+ char: this.char,
+ from: this.form,
+ name: token.value,
+ raw_name: token.text,
+ isProperty: state.tokens.curr.id === "."
+ }, checks, function() { return true; });
+ case Token.Keyword:
+ case Token.NullLiteral:
+ case Token.BooleanLiteral:
+ return create("(identifier)", token.value, state.tokens.curr.id === ".", token);
+
+ case Token.NumericLiteral:
+ if (token.isMalformed) {
+ this.trigger("warning", {
+ code: "W045",
+ line: this.line,
+ character: this.char,
+ data: [ token.value ]
+ });
+ }
+
+ this.triggerAsync("warning", {
+ code: "W114",
+ line: this.line,
+ character: this.char,
+ data: [ "0x-" ]
+ }, checks, function() { return token.base === 16 && state.jsonMode; });
+
+ this.triggerAsync("warning", {
+ code: "W115",
+ line: this.line,
+ character: this.char
+ }, checks, function() {
+ return state.isStrict() && token.base === 8 && token.isLegacy;
+ });
+
+ this.trigger("Number", {
+ line: this.line,
+ char: this.char,
+ from: this.from,
+ value: token.value,
+ base: token.base,
+ isMalformed: token.malformed
+ });
+
+ return create("(number)", token.value);
+
+ case Token.RegExp:
+ return create("(regexp)", token.value);
+
+ case Token.Comment:
+ state.tokens.curr.comment = true;
+
+ if (token.isSpecial) {
+ return {
+ id: '(comment)',
+ value: token.value,
+ body: token.body,
+ type: token.commentType,
+ isSpecial: token.isSpecial,
+ line: this.line,
+ character: this.char,
+ from: this.from
+ };
+ }
+
+ break;
+
+ case "":
+ break;
+
+ default:
+ return create("(punctuator)", token.value);
+ }
+ }
+ }
+};
+
+exports.Lexer = Lexer;
+exports.Context = Context;
+
+},{"../data/ascii-identifier-data.js":"/node_modules/jshint/data/ascii-identifier-data.js","../lodash":"/node_modules/jshint/lodash.js","./reg.js":"/node_modules/jshint/src/reg.js","./state.js":"/node_modules/jshint/src/state.js","events":"/node_modules/browserify/node_modules/events/events.js"}],"/node_modules/jshint/src/messages.js":[function(_dereq_,module,exports){
+"use strict";
+
+var _ = _dereq_("../lodash");
+
+var errors = {
+ E001: "Bad option: '{a}'.",
+ E002: "Bad option value.",
+ E003: "Expected a JSON value.",
+ E004: "Input is neither a string nor an array of strings.",
+ E005: "Input is empty.",
+ E006: "Unexpected early end of program.",
+ E007: "Missing \"use strict\" statement.",
+ E008: "Strict violation.",
+ E009: "Option 'validthis' can't be used in a global scope.",
+ E010: "'with' is not allowed in strict mode.",
+ E011: "'{a}' has already been declared.",
+ E012: "const '{a}' is initialized to 'undefined'.",
+ E013: "Attempting to override '{a}' which is a constant.",
+ E014: "A regular expression literal can be confused with '/='.",
+ E015: "Unclosed regular expression.",
+ E016: "Invalid regular expression.",
+ E017: "Unclosed comment.",
+ E018: "Unbegun comment.",
+ E019: "Unmatched '{a}'.",
+ E020: "Expected '{a}' to match '{b}' from line {c} and instead saw '{d}'.",
+ E021: "Expected '{a}' and instead saw '{b}'.",
+ E022: "Line breaking error '{a}'.",
+ E023: "Missing '{a}'.",
+ E024: "Unexpected '{a}'.",
+ E025: "Missing ':' on a case clause.",
+ E026: "Missing '}' to match '{' from line {a}.",
+ E027: "Missing ']' to match '[' from line {a}.",
+ E028: "Illegal comma.",
+ E029: "Unclosed string.",
+ E030: "Expected an identifier and instead saw '{a}'.",
+ E031: "Bad assignment.", // FIXME: Rephrase
+ E032: "Expected a small integer or 'false' and instead saw '{a}'.",
+ E033: "Expected an operator and instead saw '{a}'.",
+ E034: "get/set are ES5 features.",
+ E035: "Missing property name.",
+ E036: "Expected to see a statement and instead saw a block.",
+ E037: null,
+ E038: null,
+ E039: "Function declarations are not invocable. Wrap the whole function invocation in parens.",
+ E040: "Each value should have its own case label.",
+ E041: "Unrecoverable syntax error.",
+ E042: "Stopping.",
+ E043: "Too many errors.",
+ E044: null,
+ E045: "Invalid for each loop.",
+ E046: "A yield statement shall be within a generator function (with syntax: `function*`)",
+ E047: null,
+ E048: "{a} declaration not directly within block.",
+ E049: "A {a} cannot be named '{b}'.",
+ E050: "Mozilla requires the yield expression to be parenthesized here.",
+ E051: null,
+ E052: "Unclosed template literal.",
+ E053: "Export declaration must be in global scope.",
+ E054: "Class properties must be methods. Expected '(' but instead saw '{a}'.",
+ E055: "The '{a}' option cannot be set after any executable code.",
+ E056: "'{a}' was used before it was declared, which is illegal for '{b}' variables.",
+ E057: "Invalid meta property: '{a}.{b}'.",
+ E058: "Missing semicolon."
+};
+
+var warnings = {
+ W001: "'hasOwnProperty' is a really bad name.",
+ W002: "Value of '{a}' may be overwritten in IE 8 and earlier.",
+ W003: "'{a}' was used before it was defined.",
+ W004: "'{a}' is already defined.",
+ W005: "A dot following a number can be confused with a decimal point.",
+ W006: "Confusing minuses.",
+ W007: "Confusing plusses.",
+ W008: "A leading decimal point can be confused with a dot: '{a}'.",
+ W009: "The array literal notation [] is preferable.",
+ W010: "The object literal notation {} is preferable.",
+ W011: null,
+ W012: null,
+ W013: null,
+ W014: "Bad line breaking before '{a}'.",
+ W015: null,
+ W016: "Unexpected use of '{a}'.",
+ W017: "Bad operand.",
+ W018: "Confusing use of '{a}'.",
+ W019: "Use the isNaN function to compare with NaN.",
+ W020: "Read only.",
+ W021: "Reassignment of '{a}', which is is a {b}. " +
+ "Use 'var' or 'let' to declare bindings that may change.",
+ W022: "Do not assign to the exception parameter.",
+ W023: "Expected an identifier in an assignment and instead saw a function invocation.",
+ W024: "Expected an identifier and instead saw '{a}' (a reserved word).",
+ W025: "Missing name in function declaration.",
+ W026: "Inner functions should be listed at the top of the outer function.",
+ W027: "Unreachable '{a}' after '{b}'.",
+ W028: "Label '{a}' on {b} statement.",
+ W030: "Expected an assignment or function call and instead saw an expression.",
+ W031: "Do not use 'new' for side effects.",
+ W032: "Unnecessary semicolon.",
+ W033: "Missing semicolon.",
+ W034: "Unnecessary directive \"{a}\".",
+ W035: "Empty block.",
+ W036: "Unexpected /*member '{a}'.",
+ W037: "'{a}' is a statement label.",
+ W038: "'{a}' used out of scope.",
+ W039: "'{a}' is not allowed.",
+ W040: "Possible strict violation.",
+ W041: "Use '{a}' to compare with '{b}'.",
+ W042: "Avoid EOL escaping.",
+ W043: "Bad escaping of EOL. Use option multistr if needed.",
+ W044: "Bad or unnecessary escaping.", /* TODO(caitp): remove W044 */
+ W045: "Bad number '{a}'.",
+ W046: "Don't use extra leading zeros '{a}'.",
+ W047: "A trailing decimal point can be confused with a dot: '{a}'.",
+ W048: "Unexpected control character in regular expression.",
+ W049: "Unexpected escaped character '{a}' in regular expression.",
+ W050: "JavaScript URL.",
+ W051: "Variables should not be deleted.",
+ W052: "Unexpected '{a}'.",
+ W053: "Do not use {a} as a constructor.",
+ W054: "The Function constructor is a form of eval.",
+ W055: "A constructor name should start with an uppercase letter.",
+ W056: "Bad constructor.",
+ W057: "Weird construction. Is 'new' necessary?",
+ W058: "Missing '()' invoking a constructor.",
+ W059: "Avoid arguments.{a}.",
+ W060: "document.write can be a form of eval.",
+ W061: "eval can be harmful.",
+ W062: "Wrap an immediate function invocation in parens " +
+ "to assist the reader in understanding that the expression " +
+ "is the result of a function, and not the function itself.",
+ W063: "Math is not a function.",
+ W064: "Missing 'new' prefix when invoking a constructor.",
+ W065: "Missing radix parameter.",
+ W066: "Implied eval. Consider passing a function instead of a string.",
+ W067: "Bad invocation.",
+ W068: "Wrapping non-IIFE function literals in parens is unnecessary.",
+ W069: "['{a}'] is better written in dot notation.",
+ W070: "Extra comma. (it breaks older versions of IE)",
+ W071: "This function has too many statements. ({a})",
+ W072: "This function has too many parameters. ({a})",
+ W073: "Blocks are nested too deeply. ({a})",
+ W074: "This function's cyclomatic complexity is too high. ({a})",
+ W075: "Duplicate {a} '{b}'.",
+ W076: "Unexpected parameter '{a}' in get {b} function.",
+ W077: "Expected a single parameter in set {a} function.",
+ W078: "Setter is defined without getter.",
+ W079: "Redefinition of '{a}'.",
+ W080: "It's not necessary to initialize '{a}' to 'undefined'.",
+ W081: null,
+ W082: "Function declarations should not be placed in blocks. " +
+ "Use a function expression or move the statement to the top of " +
+ "the outer function.",
+ W083: "Don't make functions within a loop.",
+ W084: "Assignment in conditional expression",
+ W085: "Don't use 'with'.",
+ W086: "Expected a 'break' statement before '{a}'.",
+ W087: "Forgotten 'debugger' statement?",
+ W088: "Creating global 'for' variable. Should be 'for (var {a} ...'.",
+ W089: "The body of a for in should be wrapped in an if statement to filter " +
+ "unwanted properties from the prototype.",
+ W090: "'{a}' is not a statement label.",
+ W091: null,
+ W093: "Did you mean to return a conditional instead of an assignment?",
+ W094: "Unexpected comma.",
+ W095: "Expected a string and instead saw {a}.",
+ W096: "The '{a}' key may produce unexpected results.",
+ W097: "Use the function form of \"use strict\".",
+ W098: "'{a}' is defined but never used.",
+ W099: null,
+ W100: "This character may get silently deleted by one or more browsers.",
+ W101: "Line is too long.",
+ W102: null,
+ W103: "The '{a}' property is deprecated.",
+ W104: "'{a}' is available in ES{b} (use 'esversion: {b}') or Mozilla JS extensions (use moz).",
+ W105: "Unexpected {a} in '{b}'.",
+ W106: "Identifier '{a}' is not in camel case.",
+ W107: "Script URL.",
+ W108: "Strings must use doublequote.",
+ W109: "Strings must use singlequote.",
+ W110: "Mixed double and single quotes.",
+ W112: "Unclosed string.",
+ W113: "Control character in string: {a}.",
+ W114: "Avoid {a}.",
+ W115: "Octal literals are not allowed in strict mode.",
+ W116: "Expected '{a}' and instead saw '{b}'.",
+ W117: "'{a}' is not defined.",
+ W118: "'{a}' is only available in Mozilla JavaScript extensions (use moz option).",
+ W119: "'{a}' is only available in ES{b} (use 'esversion: {b}').",
+ W120: "You might be leaking a variable ({a}) here.",
+ W121: "Extending prototype of native object: '{a}'.",
+ W122: "Invalid typeof value '{a}'",
+ W123: "'{a}' is already defined in outer scope.",
+ W124: "A generator function shall contain a yield statement.",
+ W125: "This line contains non-breaking spaces: http://jshint.com/doc/options/#nonbsp",
+ W126: "Unnecessary grouping operator.",
+ W127: "Unexpected use of a comma operator.",
+ W128: "Empty array elements require elision=true.",
+ W129: "'{a}' is defined in a future version of JavaScript. Use a " +
+ "different variable name to avoid migration issues.",
+ W130: "Invalid element after rest element.",
+ W131: "Invalid parameter after rest parameter.",
+ W132: "`var` declarations are forbidden. Use `let` or `const` instead.",
+ W133: "Invalid for-{a} loop left-hand-side: {b}.",
+ W134: "The '{a}' option is only available when linting ECMAScript {b} code.",
+ W135: "{a} may not be supported by non-browser environments.",
+ W136: "'{a}' must be in function scope.",
+ W137: "Empty destructuring.",
+ W138: "Regular parameters should not come after default parameters."
+};
+
+var info = {
+ I001: "Comma warnings can be turned off with 'laxcomma'.",
+ I002: null,
+ I003: "ES5 option is now set per default"
+};
+
+exports.errors = {};
+exports.warnings = {};
+exports.info = {};
+
+_.each(errors, function(desc, code) {
+ exports.errors[code] = { code: code, desc: desc };
+});
+
+_.each(warnings, function(desc, code) {
+ exports.warnings[code] = { code: code, desc: desc };
+});
+
+_.each(info, function(desc, code) {
+ exports.info[code] = { code: code, desc: desc };
+});
+
+},{"../lodash":"/node_modules/jshint/lodash.js"}],"/node_modules/jshint/src/name-stack.js":[function(_dereq_,module,exports){
+"use strict";
+
+function NameStack() {
+ this._stack = [];
+}
+
+Object.defineProperty(NameStack.prototype, "length", {
+ get: function() {
+ return this._stack.length;
+ }
+});
+NameStack.prototype.push = function() {
+ this._stack.push(null);
+};
+NameStack.prototype.pop = function() {
+ this._stack.pop();
+};
+NameStack.prototype.set = function(token) {
+ this._stack[this.length - 1] = token;
+};
+NameStack.prototype.infer = function() {
+ var nameToken = this._stack[this.length - 1];
+ var prefix = "";
+ var type;
+ if (!nameToken || nameToken.type === "class") {
+ nameToken = this._stack[this.length - 2];
+ }
+
+ if (!nameToken) {
+ return "(empty)";
+ }
+
+ type = nameToken.type;
+
+ if (type !== "(string)" && type !== "(number)" && type !== "(identifier)" && type !== "default") {
+ return "(expression)";
+ }
+
+ if (nameToken.accessorType) {
+ prefix = nameToken.accessorType + " ";
+ }
+
+ return prefix + nameToken.value;
+};
+
+module.exports = NameStack;
+
+},{}],"/node_modules/jshint/src/options.js":[function(_dereq_,module,exports){
+"use strict";
+exports.bool = {
+ enforcing: {
+ bitwise : true,
+ freeze : true,
+ camelcase : true,
+ curly : true,
+ eqeqeq : true,
+ futurehostile: true,
+ notypeof : true,
+ es3 : true,
+ es5 : true,
+ forin : true,
+ funcscope : true,
+ immed : true,
+ iterator : true,
+ newcap : true,
+ noarg : true,
+ nocomma : true,
+ noempty : true,
+ nonbsp : true,
+ nonew : true,
+ undef : true,
+ singleGroups: false,
+ varstmt: false,
+ enforceall : false
+ },
+ relaxing: {
+ asi : true,
+ multistr : true,
+ debug : true,
+ boss : true,
+ evil : true,
+ globalstrict: true,
+ plusplus : true,
+ proto : true,
+ scripturl : true,
+ sub : true,
+ supernew : true,
+ laxbreak : true,
+ laxcomma : true,
+ validthis : true,
+ withstmt : true,
+ moz : true,
+ noyield : true,
+ eqnull : true,
+ lastsemic : true,
+ loopfunc : true,
+ expr : true,
+ esnext : true,
+ elision : true,
+ },
+ environments: {
+ mootools : true,
+ couch : true,
+ jasmine : true,
+ jquery : true,
+ node : true,
+ qunit : true,
+ rhino : true,
+ shelljs : true,
+ prototypejs : true,
+ yui : true,
+ mocha : true,
+ module : true,
+ wsh : true,
+ worker : true,
+ nonstandard : true,
+ browser : true,
+ browserify : true,
+ devel : true,
+ dojo : true,
+ typed : true,
+ phantom : true
+ },
+ obsolete: {
+ onecase : true, // if one case switch statements should be allowed
+ regexp : true, // if the . should not be allowed in regexp literals
+ regexdash : true // if unescaped first/last dash (-) inside brackets
+ }
+};
+exports.val = {
+ maxlen : false,
+ indent : false,
+ maxerr : false,
+ predef : false,
+ globals : false,
+ quotmark : false,
+
+ scope : false,
+ maxstatements: false,
+ maxdepth : false,
+ maxparams : false,
+ maxcomplexity: false,
+ shadow : false,
+ strict : true,
+ unused : true,
+ latedef : false,
+
+ ignore : false, // start/end ignoring lines of code, bypassing the lexer
+
+ ignoreDelimiters: false, // array of start/end delimiters used to ignore
+ esversion: 5
+};
+exports.inverted = {
+ bitwise : true,
+ forin : true,
+ newcap : true,
+ plusplus: true,
+ regexp : true,
+ undef : true,
+ eqeqeq : true,
+ strict : true
+};
+
+exports.validNames = Object.keys(exports.val)
+ .concat(Object.keys(exports.bool.relaxing))
+ .concat(Object.keys(exports.bool.enforcing))
+ .concat(Object.keys(exports.bool.obsolete))
+ .concat(Object.keys(exports.bool.environments));
+exports.renamed = {
+ eqeq : "eqeqeq",
+ windows: "wsh",
+ sloppy : "strict"
+};
+
+exports.removed = {
+ nomen: true,
+ onevar: true,
+ passfail: true,
+ white: true,
+ gcl: true,
+ smarttabs: true,
+ trailing: true
+};
+exports.noenforceall = {
+ varstmt: true,
+ strict: true
+};
+
+},{}],"/node_modules/jshint/src/reg.js":[function(_dereq_,module,exports){
+
+"use strict";
+exports.unsafeString =
+ /@cc|<\/?|script|\]\s*\]|<\s*!|&lt/i;
+exports.unsafeChars =
+ /[\u0000-\u001f\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/;
+exports.needEsc =
+ /[\u0000-\u001f&<"\/\\\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/;
+
+exports.needEscGlobal =
+ /[\u0000-\u001f&<"\/\\\u007f-\u009f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g;
+exports.starSlash = /\*\//;
+exports.identifier = /^([a-zA-Z_$][a-zA-Z0-9_$]*)$/;
+exports.javascriptURL = /^(?:javascript|jscript|ecmascript|vbscript|livescript)\s*:/i;
+exports.fallsThrough = /^\s*falls?\sthrough\s*$/;
+exports.maxlenException = /^(?:(?:\/\/|\/\*|\*) ?)?[^ ]+$/;
+
+},{}],"/node_modules/jshint/src/scope-manager.js":[function(_dereq_,module,exports){
+"use strict";
+
+var _ = _dereq_("../lodash");
+var events = _dereq_("events");
+var marker = {};
+var scopeManager = function(state, predefined, exported, declared) {
+
+ var _current;
+ var _scopeStack = [];
+
+ function _newScope(type) {
+ _current = {
+ "(labels)": Object.create(null),
+ "(usages)": Object.create(null),
+ "(breakLabels)": Object.create(null),
+ "(parent)": _current,
+ "(type)": type,
+ "(params)": (type === "functionparams" || type === "catchparams") ? [] : null
+ };
+ _scopeStack.push(_current);
+ }
+
+ _newScope("global");
+ _current["(predefined)"] = predefined;
+
+ var _currentFunctBody = _current; // this is the block after the params = function
+
+ var usedPredefinedAndGlobals = Object.create(null);
+ var impliedGlobals = Object.create(null);
+ var unuseds = [];
+ var emitter = new events.EventEmitter();
+
+ function warning(code, token) {
+ emitter.emit("warning", {
+ code: code,
+ token: token,
+ data: _.slice(arguments, 2)
+ });
+ }
+
+ function error(code, token) {
+ emitter.emit("warning", {
+ code: code,
+ token: token,
+ data: _.slice(arguments, 2)
+ });
+ }
+
+ function _setupUsages(labelName) {
+ if (!_current["(usages)"][labelName]) {
+ _current["(usages)"][labelName] = {
+ "(modified)": [],
+ "(reassigned)": [],
+ "(tokens)": []
+ };
+ }
+ }
+
+ var _getUnusedOption = function(unused_opt) {
+ if (unused_opt === undefined) {
+ unused_opt = state.option.unused;
+ }
+
+ if (unused_opt === true) {
+ unused_opt = "last-param";
+ }
+
+ return unused_opt;
+ };
+
+ var _warnUnused = function(name, tkn, type, unused_opt) {
+ var line = tkn.line;
+ var chr = tkn.from;
+ var raw_name = tkn.raw_text || name;
+
+ unused_opt = _getUnusedOption(unused_opt);
+
+ var warnable_types = {
+ "vars": ["var"],
+ "last-param": ["var", "param"],
+ "strict": ["var", "param", "last-param"]
+ };
+
+ if (unused_opt) {
+ if (warnable_types[unused_opt] && warnable_types[unused_opt].indexOf(type) !== -1) {
+ warning("W098", { line: line, from: chr }, raw_name);
+ }
+ }
+ if (unused_opt || type === "var") {
+ unuseds.push({
+ name: name,
+ line: line,
+ character: chr
+ });
+ }
+ };
+ function _checkForUnused() {
+ if (_current["(type)"] === "functionparams") {
+ _checkParams();
+ return;
+ }
+ var curentLabels = _current["(labels)"];
+ for (var labelName in curentLabels) {
+ if (curentLabels[labelName]) {
+ if (curentLabels[labelName]["(type)"] !== "exception" &&
+ curentLabels[labelName]["(unused)"]) {
+ _warnUnused(labelName, curentLabels[labelName]["(token)"], "var");
+ }
+ }
+ }
+ }
+ function _checkParams() {
+ var params = _current["(params)"];
+
+ if (!params) {
+ return;
+ }
+
+ var param = params.pop();
+ var unused_opt;
+
+ while (param) {
+ var label = _current["(labels)"][param];
+
+ unused_opt = _getUnusedOption(state.funct["(unusedOption)"]);
+ if (param === "undefined")
+ return;
+
+ if (label["(unused)"]) {
+ _warnUnused(param, label["(token)"], "param", state.funct["(unusedOption)"]);
+ } else if (unused_opt === "last-param") {
+ return;
+ }
+
+ param = params.pop();
+ }
+ }
+ function _getLabel(labelName) {
+ for (var i = _scopeStack.length - 1 ; i >= 0; --i) {
+ var scopeLabels = _scopeStack[i]["(labels)"];
+ if (scopeLabels[labelName]) {
+ return scopeLabels;
+ }
+ }
+ }
+
+ function usedSoFarInCurrentFunction(labelName) {
+ for (var i = _scopeStack.length - 1; i >= 0; i--) {
+ var current = _scopeStack[i];
+ if (current["(usages)"][labelName]) {
+ return current["(usages)"][labelName];
+ }
+ if (current === _currentFunctBody) {
+ break;
+ }
+ }
+ return false;
+ }
+
+ function _checkOuterShadow(labelName, token) {
+ if (state.option.shadow !== "outer") {
+ return;
+ }
+
+ var isGlobal = _currentFunctBody["(type)"] === "global",
+ isNewFunction = _current["(type)"] === "functionparams";
+
+ var outsideCurrentFunction = !isGlobal;
+ for (var i = 0; i < _scopeStack.length; i++) {
+ var stackItem = _scopeStack[i];
+
+ if (!isNewFunction && _scopeStack[i + 1] === _currentFunctBody) {
+ outsideCurrentFunction = false;
+ }
+ if (outsideCurrentFunction && stackItem["(labels)"][labelName]) {
+ warning("W123", token, labelName);
+ }
+ if (stackItem["(breakLabels)"][labelName]) {
+ warning("W123", token, labelName);
+ }
+ }
+ }
+
+ function _latedefWarning(type, labelName, token) {
+ if (state.option.latedef) {
+ if ((state.option.latedef === true && type === "function") ||
+ type !== "function") {
+ warning("W003", token, labelName);
+ }
+ }
+ }
+
+ var scopeManagerInst = {
+
+ on: function(names, listener) {
+ names.split(" ").forEach(function(name) {
+ emitter.on(name, listener);
+ });
+ },
+
+ isPredefined: function(labelName) {
+ return !this.has(labelName) && _.has(_scopeStack[0]["(predefined)"], labelName);
+ },
+ stack: function(type) {
+ var previousScope = _current;
+ _newScope(type);
+
+ if (!type && previousScope["(type)"] === "functionparams") {
+
+ _current["(isFuncBody)"] = true;
+ _current["(context)"] = _currentFunctBody;
+ _currentFunctBody = _current;
+ }
+ },
+
+ unstack: function() {
+ var subScope = _scopeStack.length > 1 ? _scopeStack[_scopeStack.length - 2] : null;
+ var isUnstackingFunctionBody = _current === _currentFunctBody,
+ isUnstackingFunctionParams = _current["(type)"] === "functionparams",
+ isUnstackingFunctionOuter = _current["(type)"] === "functionouter";
+
+ var i, j;
+ var currentUsages = _current["(usages)"];
+ var currentLabels = _current["(labels)"];
+ var usedLabelNameList = Object.keys(currentUsages);
+
+ if (currentUsages.__proto__ && usedLabelNameList.indexOf("__proto__") === -1) {
+ usedLabelNameList.push("__proto__");
+ }
+
+ for (i = 0; i < usedLabelNameList.length; i++) {
+ var usedLabelName = usedLabelNameList[i];
+
+ var usage = currentUsages[usedLabelName];
+ var usedLabel = currentLabels[usedLabelName];
+ if (usedLabel) {
+ var usedLabelType = usedLabel["(type)"];
+
+ if (usedLabel["(useOutsideOfScope)"] && !state.option.funcscope) {
+ var usedTokens = usage["(tokens)"];
+ if (usedTokens) {
+ for (j = 0; j < usedTokens.length; j++) {
+ if (usedLabel["(function)"] === usedTokens[j]["(function)"]) {
+ error("W038", usedTokens[j], usedLabelName);
+ }
+ }
+ }
+ }
+ _current["(labels)"][usedLabelName]["(unused)"] = false;
+ if (usedLabelType === "const" && usage["(modified)"]) {
+ for (j = 0; j < usage["(modified)"].length; j++) {
+ error("E013", usage["(modified)"][j], usedLabelName);
+ }
+ }
+ if ((usedLabelType === "function" || usedLabelType === "class") &&
+ usage["(reassigned)"]) {
+ for (j = 0; j < usage["(reassigned)"].length; j++) {
+ error("W021", usage["(reassigned)"][j], usedLabelName, usedLabelType);
+ }
+ }
+ continue;
+ }
+
+ if (isUnstackingFunctionOuter) {
+ state.funct["(isCapturing)"] = true;
+ }
+
+ if (subScope) {
+ if (!subScope["(usages)"][usedLabelName]) {
+ subScope["(usages)"][usedLabelName] = usage;
+ if (isUnstackingFunctionBody) {
+ subScope["(usages)"][usedLabelName]["(onlyUsedSubFunction)"] = true;
+ }
+ } else {
+ var subScopeUsage = subScope["(usages)"][usedLabelName];
+ subScopeUsage["(modified)"] = subScopeUsage["(modified)"].concat(usage["(modified)"]);
+ subScopeUsage["(tokens)"] = subScopeUsage["(tokens)"].concat(usage["(tokens)"]);
+ subScopeUsage["(reassigned)"] =
+ subScopeUsage["(reassigned)"].concat(usage["(reassigned)"]);
+ subScopeUsage["(onlyUsedSubFunction)"] = false;
+ }
+ } else {
+ if (typeof _current["(predefined)"][usedLabelName] === "boolean") {
+ delete declared[usedLabelName];
+ usedPredefinedAndGlobals[usedLabelName] = marker;
+ if (_current["(predefined)"][usedLabelName] === false && usage["(reassigned)"]) {
+ for (j = 0; j < usage["(reassigned)"].length; j++) {
+ warning("W020", usage["(reassigned)"][j]);
+ }
+ }
+ }
+ else {
+ if (usage["(tokens)"]) {
+ for (j = 0; j < usage["(tokens)"].length; j++) {
+ var undefinedToken = usage["(tokens)"][j];
+ if (!undefinedToken.forgiveUndef) {
+ if (state.option.undef && !undefinedToken.ignoreUndef) {
+ warning("W117", undefinedToken, usedLabelName);
+ }
+ if (impliedGlobals[usedLabelName]) {
+ impliedGlobals[usedLabelName].line.push(undefinedToken.line);
+ } else {
+ impliedGlobals[usedLabelName] = {
+ name: usedLabelName,
+ line: [undefinedToken.line]
+ };
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ if (!subScope) {
+ Object.keys(declared)
+ .forEach(function(labelNotUsed) {
+ _warnUnused(labelNotUsed, declared[labelNotUsed], "var");
+ });
+ }
+ if (subScope && !isUnstackingFunctionBody &&
+ !isUnstackingFunctionParams && !isUnstackingFunctionOuter) {
+ var labelNames = Object.keys(currentLabels);
+ for (i = 0; i < labelNames.length; i++) {
+
+ var defLabelName = labelNames[i];
+ if (!currentLabels[defLabelName]["(blockscoped)"] &&
+ currentLabels[defLabelName]["(type)"] !== "exception" &&
+ !this.funct.has(defLabelName, { excludeCurrent: true })) {
+ subScope["(labels)"][defLabelName] = currentLabels[defLabelName];
+ if (_currentFunctBody["(type)"] !== "global") {
+ subScope["(labels)"][defLabelName]["(useOutsideOfScope)"] = true;
+ }
+ delete currentLabels[defLabelName];
+ }
+ }
+ }
+
+ _checkForUnused();
+
+ _scopeStack.pop();
+ if (isUnstackingFunctionBody) {
+ _currentFunctBody = _scopeStack[_.findLastIndex(_scopeStack, function(scope) {
+ return scope["(isFuncBody)"] || scope["(type)"] === "global";
+ })];
+ }
+
+ _current = subScope;
+ },
+ addParam: function(labelName, token, type) {
+ type = type || "param";
+
+ if (type === "exception") {
+ var previouslyDefinedLabelType = this.funct.labeltype(labelName);
+ if (previouslyDefinedLabelType && previouslyDefinedLabelType !== "exception") {
+ if (!state.option.node) {
+ warning("W002", state.tokens.next, labelName);
+ }
+ }
+ }
+ if (_.has(_current["(labels)"], labelName)) {
+ _current["(labels)"][labelName].duplicated = true;
+ } else {
+ _checkOuterShadow(labelName, token, type);
+
+ _current["(labels)"][labelName] = {
+ "(type)" : type,
+ "(token)": token,
+ "(unused)": true };
+
+ _current["(params)"].push(labelName);
+ }
+
+ if (_.has(_current["(usages)"], labelName)) {
+ var usage = _current["(usages)"][labelName];
+ if (usage["(onlyUsedSubFunction)"]) {
+ _latedefWarning(type, labelName, token);
+ } else {
+ warning("E056", token, labelName, type);
+ }
+ }
+ },
+
+ validateParams: function() {
+ if (_currentFunctBody["(type)"] === "global") {
+ return;
+ }
+
+ var isStrict = state.isStrict();
+ var currentFunctParamScope = _currentFunctBody["(parent)"];
+
+ if (!currentFunctParamScope["(params)"]) {
+ return;
+ }
+
+ currentFunctParamScope["(params)"].forEach(function(labelName) {
+ var label = currentFunctParamScope["(labels)"][labelName];
+
+ if (label && label.duplicated) {
+ if (isStrict) {
+ warning("E011", label["(token)"], labelName);
+ } else if (state.option.shadow !== true) {
+ warning("W004", label["(token)"], labelName);
+ }
+ }
+ });
+ },
+
+ getUsedOrDefinedGlobals: function() {
+ var list = Object.keys(usedPredefinedAndGlobals);
+ if (usedPredefinedAndGlobals.__proto__ === marker &&
+ list.indexOf("__proto__") === -1) {
+ list.push("__proto__");
+ }
+
+ return list;
+ },
+ getImpliedGlobals: function() {
+ var values = _.values(impliedGlobals);
+ var hasProto = false;
+ if (impliedGlobals.__proto__) {
+ hasProto = values.some(function(value) {
+ return value.name === "__proto__";
+ });
+
+ if (!hasProto) {
+ values.push(impliedGlobals.__proto__);
+ }
+ }
+
+ return values;
+ },
+ getUnuseds: function() {
+ return unuseds;
+ },
+
+ has: function(labelName) {
+ return Boolean(_getLabel(labelName));
+ },
+
+ labeltype: function(labelName) {
+ var scopeLabels = _getLabel(labelName);
+ if (scopeLabels) {
+ return scopeLabels[labelName]["(type)"];
+ }
+ return null;
+ },
+ addExported: function(labelName) {
+ var globalLabels = _scopeStack[0]["(labels)"];
+ if (_.has(declared, labelName)) {
+ delete declared[labelName];
+ } else if (_.has(globalLabels, labelName)) {
+ globalLabels[labelName]["(unused)"] = false;
+ } else {
+ for (var i = 1; i < _scopeStack.length; i++) {
+ var scope = _scopeStack[i];
+ if (!scope["(type)"]) {
+ if (_.has(scope["(labels)"], labelName) &&
+ !scope["(labels)"][labelName]["(blockscoped)"]) {
+ scope["(labels)"][labelName]["(unused)"] = false;
+ return;
+ }
+ } else {
+ break;
+ }
+ }
+ exported[labelName] = true;
+ }
+ },
+ setExported: function(labelName, token) {
+ this.block.use(labelName, token);
+ },
+ addlabel: function(labelName, opts) {
+
+ var type = opts.type;
+ var token = opts.token;
+ var isblockscoped = type === "let" || type === "const" || type === "class";
+ var isexported = (isblockscoped ? _current : _currentFunctBody)["(type)"] === "global" &&
+ _.has(exported, labelName);
+ _checkOuterShadow(labelName, token, type);
+ if (isblockscoped) {
+
+ var declaredInCurrentScope = _current["(labels)"][labelName];
+ if (!declaredInCurrentScope && _current === _currentFunctBody &&
+ _current["(type)"] !== "global") {
+ declaredInCurrentScope = !!_currentFunctBody["(parent)"]["(labels)"][labelName];
+ }
+ if (!declaredInCurrentScope && _current["(usages)"][labelName]) {
+ var usage = _current["(usages)"][labelName];
+ if (usage["(onlyUsedSubFunction)"]) {
+ _latedefWarning(type, labelName, token);
+ } else {
+ warning("E056", token, labelName, type);
+ }
+ }
+ if (declaredInCurrentScope) {
+ warning("E011", token, labelName);
+ }
+ else if (state.option.shadow === "outer") {
+ if (scopeManagerInst.funct.has(labelName)) {
+ warning("W004", token, labelName);
+ }
+ }
+
+ scopeManagerInst.block.add(labelName, type, token, !isexported);
+
+ } else {
+
+ var declaredInCurrentFunctionScope = scopeManagerInst.funct.has(labelName);
+ if (!declaredInCurrentFunctionScope && usedSoFarInCurrentFunction(labelName)) {
+ _latedefWarning(type, labelName, token);
+ }
+ if (scopeManagerInst.funct.has(labelName, { onlyBlockscoped: true })) {
+ warning("E011", token, labelName);
+ } else if (state.option.shadow !== true) {
+ if (declaredInCurrentFunctionScope && labelName !== "__proto__") {
+ if (_currentFunctBody["(type)"] !== "global") {
+ warning("W004", token, labelName);
+ }
+ }
+ }
+
+ scopeManagerInst.funct.add(labelName, type, token, !isexported);
+
+ if (_currentFunctBody["(type)"] === "global") {
+ usedPredefinedAndGlobals[labelName] = marker;
+ }
+ }
+ },
+
+ funct: {
+ labeltype: function(labelName, options) {
+ var onlyBlockscoped = options && options.onlyBlockscoped;
+ var excludeParams = options && options.excludeParams;
+ var currentScopeIndex = _scopeStack.length - (options && options.excludeCurrent ? 2 : 1);
+ for (var i = currentScopeIndex; i >= 0; i--) {
+ var current = _scopeStack[i];
+ if (current["(labels)"][labelName] &&
+ (!onlyBlockscoped || current["(labels)"][labelName]["(blockscoped)"])) {
+ return current["(labels)"][labelName]["(type)"];
+ }
+ var scopeCheck = excludeParams ? _scopeStack[ i - 1 ] : current;
+ if (scopeCheck && scopeCheck["(type)"] === "functionparams") {
+ return null;
+ }
+ }
+ return null;
+ },
+ hasBreakLabel: function(labelName) {
+ for (var i = _scopeStack.length - 1; i >= 0; i--) {
+ var current = _scopeStack[i];
+
+ if (current["(breakLabels)"][labelName]) {
+ return true;
+ }
+ if (current["(type)"] === "functionparams") {
+ return false;
+ }
+ }
+ return false;
+ },
+ has: function(labelName, options) {
+ return Boolean(this.labeltype(labelName, options));
+ },
+ add: function(labelName, type, tok, unused) {
+ _current["(labels)"][labelName] = {
+ "(type)" : type,
+ "(token)": tok,
+ "(blockscoped)": false,
+ "(function)": _currentFunctBody,
+ "(unused)": unused };
+ }
+ },
+
+ block: {
+ isGlobal: function() {
+ return _current["(type)"] === "global";
+ },
+
+ use: function(labelName, token) {
+ var paramScope = _currentFunctBody["(parent)"];
+ if (paramScope && paramScope["(labels)"][labelName] &&
+ paramScope["(labels)"][labelName]["(type)"] === "param") {
+ if (!scopeManagerInst.funct.has(labelName,
+ { excludeParams: true, onlyBlockscoped: true })) {
+ paramScope["(labels)"][labelName]["(unused)"] = false;
+ }
+ }
+
+ if (token && (state.ignored.W117 || state.option.undef === false)) {
+ token.ignoreUndef = true;
+ }
+
+ _setupUsages(labelName);
+
+ if (token) {
+ token["(function)"] = _currentFunctBody;
+ _current["(usages)"][labelName]["(tokens)"].push(token);
+ }
+ },
+
+ reassign: function(labelName, token) {
+
+ this.modify(labelName, token);
+
+ _current["(usages)"][labelName]["(reassigned)"].push(token);
+ },
+
+ modify: function(labelName, token) {
+
+ _setupUsages(labelName);
+
+ _current["(usages)"][labelName]["(modified)"].push(token);
+ },
+ add: function(labelName, type, tok, unused) {
+ _current["(labels)"][labelName] = {
+ "(type)" : type,
+ "(token)": tok,
+ "(blockscoped)": true,
+ "(unused)": unused };
+ },
+
+ addBreakLabel: function(labelName, opts) {
+ var token = opts.token;
+ if (scopeManagerInst.funct.hasBreakLabel(labelName)) {
+ warning("E011", token, labelName);
+ }
+ else if (state.option.shadow === "outer") {
+ if (scopeManagerInst.funct.has(labelName)) {
+ warning("W004", token, labelName);
+ } else {
+ _checkOuterShadow(labelName, token);
+ }
+ }
+ _current["(breakLabels)"][labelName] = token;
+ }
+ }
+ };
+ return scopeManagerInst;
+};
+
+module.exports = scopeManager;
+
+},{"../lodash":"/node_modules/jshint/lodash.js","events":"/node_modules/browserify/node_modules/events/events.js"}],"/node_modules/jshint/src/state.js":[function(_dereq_,module,exports){
+"use strict";
+var NameStack = _dereq_("./name-stack.js");
+
+var state = {
+ syntax: {},
+ isStrict: function() {
+ return this.directive["use strict"] || this.inClassBody ||
+ this.option.module || this.option.strict === "implied";
+ },
+
+ inMoz: function() {
+ return this.option.moz;
+ },
+ inES6: function() {
+ return this.option.moz || this.option.esversion >= 6;
+ },
+ inES5: function(strict) {
+ if (strict) {
+ return (!this.option.esversion || this.option.esversion === 5) && !this.option.moz;
+ }
+ return !this.option.esversion || this.option.esversion >= 5 || this.option.moz;
+ },
+
+
+ reset: function() {
+ this.tokens = {
+ prev: null,
+ next: null,
+ curr: null
+ };
+
+ this.option = {};
+ this.funct = null;
+ this.ignored = {};
+ this.directive = {};
+ this.jsonMode = false;
+ this.jsonWarnings = [];
+ this.lines = [];
+ this.tab = "";
+ this.cache = {}; // Node.JS doesn't have Map. Sniff.
+ this.ignoredLines = {};
+ this.forinifcheckneeded = false;
+ this.nameStack = new NameStack();
+ this.inClassBody = false;
+ }
+};
+
+exports.state = state;
+
+},{"./name-stack.js":"/node_modules/jshint/src/name-stack.js"}],"/node_modules/jshint/src/style.js":[function(_dereq_,module,exports){
+"use strict";
+
+exports.register = function(linter) {
+
+ linter.on("Identifier", function style_scanProto(data) {
+ if (linter.getOption("proto")) {
+ return;
+ }
+
+ if (data.name === "__proto__") {
+ linter.warn("W103", {
+ line: data.line,
+ char: data.char,
+ data: [ data.name, "6" ]
+ });
+ }
+ });
+
+ linter.on("Identifier", function style_scanIterator(data) {
+ if (linter.getOption("iterator")) {
+ return;
+ }
+
+ if (data.name === "__iterator__") {
+ linter.warn("W103", {
+ line: data.line,
+ char: data.char,
+ data: [ data.name ]
+ });
+ }
+ });
+
+ linter.on("Identifier", function style_scanCamelCase(data) {
+ if (!linter.getOption("camelcase")) {
+ return;
+ }
+
+ if (data.name.replace(/^_+|_+$/g, "").indexOf("_") > -1 && !data.name.match(/^[A-Z0-9_]*$/)) {
+ linter.warn("W106", {
+ line: data.line,
+ char: data.from,
+ data: [ data.name ]
+ });
+ }
+ });
+
+ linter.on("String", function style_scanQuotes(data) {
+ var quotmark = linter.getOption("quotmark");
+ var code;
+
+ if (!quotmark) {
+ return;
+ }
+
+ if (quotmark === "single" && data.quote !== "'") {
+ code = "W109";
+ }
+
+ if (quotmark === "double" && data.quote !== "\"") {
+ code = "W108";
+ }
+
+ if (quotmark === true) {
+ if (!linter.getCache("quotmark")) {
+ linter.setCache("quotmark", data.quote);
+ }
+
+ if (linter.getCache("quotmark") !== data.quote) {
+ code = "W110";
+ }
+ }
+
+ if (code) {
+ linter.warn(code, {
+ line: data.line,
+ char: data.char,
+ });
+ }
+ });
+
+ linter.on("Number", function style_scanNumbers(data) {
+ if (data.value.charAt(0) === ".") {
+ linter.warn("W008", {
+ line: data.line,
+ char: data.char,
+ data: [ data.value ]
+ });
+ }
+
+ if (data.value.substr(data.value.length - 1) === ".") {
+ linter.warn("W047", {
+ line: data.line,
+ char: data.char,
+ data: [ data.value ]
+ });
+ }
+
+ if (/^00+/.test(data.value)) {
+ linter.warn("W046", {
+ line: data.line,
+ char: data.char,
+ data: [ data.value ]
+ });
+ }
+ });
+
+ linter.on("String", function style_scanJavaScriptURLs(data) {
+ var re = /^(?:javascript|jscript|ecmascript|vbscript|livescript)\s*:/i;
+
+ if (linter.getOption("scripturl")) {
+ return;
+ }
+
+ if (re.test(data.value)) {
+ linter.warn("W107", {
+ line: data.line,
+ char: data.char
+ });
+ }
+ });
+};
+
+},{}],"/node_modules/jshint/src/vars.js":[function(_dereq_,module,exports){
+
+"use strict";
+
+exports.reservedVars = {
+ arguments : false,
+ NaN : false
+};
+
+exports.ecmaIdentifiers = {
+ 3: {
+ Array : false,
+ Boolean : false,
+ Date : false,
+ decodeURI : false,
+ decodeURIComponent : false,
+ encodeURI : false,
+ encodeURIComponent : false,
+ Error : false,
+ "eval" : false,
+ EvalError : false,
+ Function : false,
+ hasOwnProperty : false,
+ isFinite : false,
+ isNaN : false,
+ Math : false,
+ Number : false,
+ Object : false,
+ parseInt : false,
+ parseFloat : false,
+ RangeError : false,
+ ReferenceError : false,
+ RegExp : false,
+ String : false,
+ SyntaxError : false,
+ TypeError : false,
+ URIError : false
+ },
+ 5: {
+ JSON : false
+ },
+ 6: {
+ Map : false,
+ Promise : false,
+ Proxy : false,
+ Reflect : false,
+ Set : false,
+ Symbol : false,
+ WeakMap : false,
+ WeakSet : false
+ }
+};
+
+exports.browser = {
+ Audio : false,
+ Blob : false,
+ addEventListener : false,
+ applicationCache : false,
+ atob : false,
+ blur : false,
+ btoa : false,
+ cancelAnimationFrame : false,
+ CanvasGradient : false,
+ CanvasPattern : false,
+ CanvasRenderingContext2D: false,
+ CSS : false,
+ clearInterval : false,
+ clearTimeout : false,
+ close : false,
+ closed : false,
+ Comment : false,
+ CustomEvent : false,
+ DOMParser : false,
+ defaultStatus : false,
+ Document : false,
+ document : false,
+ DocumentFragment : false,
+ Element : false,
+ ElementTimeControl : false,
+ Event : false,
+ event : false,
+ fetch : false,
+ FileReader : false,
+ FormData : false,
+ focus : false,
+ frames : false,
+ getComputedStyle : false,
+ HTMLElement : false,
+ HTMLAnchorElement : false,
+ HTMLBaseElement : false,
+ HTMLBlockquoteElement: false,
+ HTMLBodyElement : false,
+ HTMLBRElement : false,
+ HTMLButtonElement : false,
+ HTMLCanvasElement : false,
+ HTMLCollection : false,
+ HTMLDirectoryElement : false,
+ HTMLDivElement : false,
+ HTMLDListElement : false,
+ HTMLFieldSetElement : false,
+ HTMLFontElement : false,
+ HTMLFormElement : false,
+ HTMLFrameElement : false,
+ HTMLFrameSetElement : false,
+ HTMLHeadElement : false,
+ HTMLHeadingElement : false,
+ HTMLHRElement : false,
+ HTMLHtmlElement : false,
+ HTMLIFrameElement : false,
+ HTMLImageElement : false,
+ HTMLInputElement : false,
+ HTMLIsIndexElement : false,
+ HTMLLabelElement : false,
+ HTMLLayerElement : false,
+ HTMLLegendElement : false,
+ HTMLLIElement : false,
+ HTMLLinkElement : false,
+ HTMLMapElement : false,
+ HTMLMenuElement : false,
+ HTMLMetaElement : false,
+ HTMLModElement : false,
+ HTMLObjectElement : false,
+ HTMLOListElement : false,
+ HTMLOptGroupElement : false,
+ HTMLOptionElement : false,
+ HTMLParagraphElement : false,
+ HTMLParamElement : false,
+ HTMLPreElement : false,
+ HTMLQuoteElement : false,
+ HTMLScriptElement : false,
+ HTMLSelectElement : false,
+ HTMLStyleElement : false,
+ HTMLTableCaptionElement: false,
+ HTMLTableCellElement : false,
+ HTMLTableColElement : false,
+ HTMLTableElement : false,
+ HTMLTableRowElement : false,
+ HTMLTableSectionElement: false,
+ HTMLTemplateElement : false,
+ HTMLTextAreaElement : false,
+ HTMLTitleElement : false,
+ HTMLUListElement : false,
+ HTMLVideoElement : false,
+ history : false,
+ Image : false,
+ Intl : false,
+ length : false,
+ localStorage : false,
+ location : false,
+ matchMedia : false,
+ MessageChannel : false,
+ MessageEvent : false,
+ MessagePort : false,
+ MouseEvent : false,
+ moveBy : false,
+ moveTo : false,
+ MutationObserver : false,
+ name : false,
+ Node : false,
+ NodeFilter : false,
+ NodeList : false,
+ Notification : false,
+ navigator : false,
+ onbeforeunload : true,
+ onblur : true,
+ onerror : true,
+ onfocus : true,
+ onload : true,
+ onresize : true,
+ onunload : true,
+ open : false,
+ openDatabase : false,
+ opener : false,
+ Option : false,
+ parent : false,
+ performance : false,
+ print : false,
+ Range : false,
+ requestAnimationFrame : false,
+ removeEventListener : false,
+ resizeBy : false,
+ resizeTo : false,
+ screen : false,
+ scroll : false,
+ scrollBy : false,
+ scrollTo : false,
+ sessionStorage : false,
+ setInterval : false,
+ setTimeout : false,
+ SharedWorker : false,
+ status : false,
+ SVGAElement : false,
+ SVGAltGlyphDefElement: false,
+ SVGAltGlyphElement : false,
+ SVGAltGlyphItemElement: false,
+ SVGAngle : false,
+ SVGAnimateColorElement: false,
+ SVGAnimateElement : false,
+ SVGAnimateMotionElement: false,
+ SVGAnimateTransformElement: false,
+ SVGAnimatedAngle : false,
+ SVGAnimatedBoolean : false,
+ SVGAnimatedEnumeration: false,
+ SVGAnimatedInteger : false,
+ SVGAnimatedLength : false,
+ SVGAnimatedLengthList: false,
+ SVGAnimatedNumber : false,
+ SVGAnimatedNumberList: false,
+ SVGAnimatedPathData : false,
+ SVGAnimatedPoints : false,
+ SVGAnimatedPreserveAspectRatio: false,
+ SVGAnimatedRect : false,
+ SVGAnimatedString : false,
+ SVGAnimatedTransformList: false,
+ SVGAnimationElement : false,
+ SVGCSSRule : false,
+ SVGCircleElement : false,
+ SVGClipPathElement : false,
+ SVGColor : false,
+ SVGColorProfileElement: false,
+ SVGColorProfileRule : false,
+ SVGComponentTransferFunctionElement: false,
+ SVGCursorElement : false,
+ SVGDefsElement : false,
+ SVGDescElement : false,
+ SVGDocument : false,
+ SVGElement : false,
+ SVGElementInstance : false,
+ SVGElementInstanceList: false,
+ SVGEllipseElement : false,
+ SVGExternalResourcesRequired: false,
+ SVGFEBlendElement : false,
+ SVGFEColorMatrixElement: false,
+ SVGFEComponentTransferElement: false,
+ SVGFECompositeElement: false,
+ SVGFEConvolveMatrixElement: false,
+ SVGFEDiffuseLightingElement: false,
+ SVGFEDisplacementMapElement: false,
+ SVGFEDistantLightElement: false,
+ SVGFEFloodElement : false,
+ SVGFEFuncAElement : false,
+ SVGFEFuncBElement : false,
+ SVGFEFuncGElement : false,
+ SVGFEFuncRElement : false,
+ SVGFEGaussianBlurElement: false,
+ SVGFEImageElement : false,
+ SVGFEMergeElement : false,
+ SVGFEMergeNodeElement: false,
+ SVGFEMorphologyElement: false,
+ SVGFEOffsetElement : false,
+ SVGFEPointLightElement: false,
+ SVGFESpecularLightingElement: false,
+ SVGFESpotLightElement: false,
+ SVGFETileElement : false,
+ SVGFETurbulenceElement: false,
+ SVGFilterElement : false,
+ SVGFilterPrimitiveStandardAttributes: false,
+ SVGFitToViewBox : false,
+ SVGFontElement : false,
+ SVGFontFaceElement : false,
+ SVGFontFaceFormatElement: false,
+ SVGFontFaceNameElement: false,
+ SVGFontFaceSrcElement: false,
+ SVGFontFaceUriElement: false,
+ SVGForeignObjectElement: false,
+ SVGGElement : false,
+ SVGGlyphElement : false,
+ SVGGlyphRefElement : false,
+ SVGGradientElement : false,
+ SVGHKernElement : false,
+ SVGICCColor : false,
+ SVGImageElement : false,
+ SVGLangSpace : false,
+ SVGLength : false,
+ SVGLengthList : false,
+ SVGLineElement : false,
+ SVGLinearGradientElement: false,
+ SVGLocatable : false,
+ SVGMPathElement : false,
+ SVGMarkerElement : false,
+ SVGMaskElement : false,
+ SVGMatrix : false,
+ SVGMetadataElement : false,
+ SVGMissingGlyphElement: false,
+ SVGNumber : false,
+ SVGNumberList : false,
+ SVGPaint : false,
+ SVGPathElement : false,
+ SVGPathSeg : false,
+ SVGPathSegArcAbs : false,
+ SVGPathSegArcRel : false,
+ SVGPathSegClosePath : false,
+ SVGPathSegCurvetoCubicAbs: false,
+ SVGPathSegCurvetoCubicRel: false,
+ SVGPathSegCurvetoCubicSmoothAbs: false,
+ SVGPathSegCurvetoCubicSmoothRel: false,
+ SVGPathSegCurvetoQuadraticAbs: false,
+ SVGPathSegCurvetoQuadraticRel: false,
+ SVGPathSegCurvetoQuadraticSmoothAbs: false,
+ SVGPathSegCurvetoQuadraticSmoothRel: false,
+ SVGPathSegLinetoAbs : false,
+ SVGPathSegLinetoHorizontalAbs: false,
+ SVGPathSegLinetoHorizontalRel: false,
+ SVGPathSegLinetoRel : false,
+ SVGPathSegLinetoVerticalAbs: false,
+ SVGPathSegLinetoVerticalRel: false,
+ SVGPathSegList : false,
+ SVGPathSegMovetoAbs : false,
+ SVGPathSegMovetoRel : false,
+ SVGPatternElement : false,
+ SVGPoint : false,
+ SVGPointList : false,
+ SVGPolygonElement : false,
+ SVGPolylineElement : false,
+ SVGPreserveAspectRatio: false,
+ SVGRadialGradientElement: false,
+ SVGRect : false,
+ SVGRectElement : false,
+ SVGRenderingIntent : false,
+ SVGSVGElement : false,
+ SVGScriptElement : false,
+ SVGSetElement : false,
+ SVGStopElement : false,
+ SVGStringList : false,
+ SVGStylable : false,
+ SVGStyleElement : false,
+ SVGSwitchElement : false,
+ SVGSymbolElement : false,
+ SVGTRefElement : false,
+ SVGTSpanElement : false,
+ SVGTests : false,
+ SVGTextContentElement: false,
+ SVGTextElement : false,
+ SVGTextPathElement : false,
+ SVGTextPositioningElement: false,
+ SVGTitleElement : false,
+ SVGTransform : false,
+ SVGTransformList : false,
+ SVGTransformable : false,
+ SVGURIReference : false,
+ SVGUnitTypes : false,
+ SVGUseElement : false,
+ SVGVKernElement : false,
+ SVGViewElement : false,
+ SVGViewSpec : false,
+ SVGZoomAndPan : false,
+ Text : false,
+ TextDecoder : false,
+ TextEncoder : false,
+ TimeEvent : false,
+ top : false,
+ URL : false,
+ WebGLActiveInfo : false,
+ WebGLBuffer : false,
+ WebGLContextEvent : false,
+ WebGLFramebuffer : false,
+ WebGLProgram : false,
+ WebGLRenderbuffer : false,
+ WebGLRenderingContext: false,
+ WebGLShader : false,
+ WebGLShaderPrecisionFormat: false,
+ WebGLTexture : false,
+ WebGLUniformLocation : false,
+ WebSocket : false,
+ window : false,
+ Window : false,
+ Worker : false,
+ XDomainRequest : false,
+ XMLHttpRequest : false,
+ XMLSerializer : false,
+ XPathEvaluator : false,
+ XPathException : false,
+ XPathExpression : false,
+ XPathNamespace : false,
+ XPathNSResolver : false,
+ XPathResult : false
+};
+
+exports.devel = {
+ alert : false,
+ confirm: false,
+ console: false,
+ Debug : false,
+ opera : false,
+ prompt : false
+};
+
+exports.worker = {
+ importScripts : true,
+ postMessage : true,
+ self : true,
+ FileReaderSync : true
+};
+exports.nonstandard = {
+ escape : false,
+ unescape: false
+};
+
+exports.couch = {
+ "require" : false,
+ respond : false,
+ getRow : false,
+ emit : false,
+ send : false,
+ start : false,
+ sum : false,
+ log : false,
+ exports : false,
+ module : false,
+ provides : false
+};
+
+exports.node = {
+ __filename : false,
+ __dirname : false,
+ GLOBAL : false,
+ global : false,
+ module : false,
+ require : false,
+
+ Buffer : true,
+ console : true,
+ exports : true,
+ process : true,
+ setTimeout : true,
+ clearTimeout : true,
+ setInterval : true,
+ clearInterval : true,
+ setImmediate : true, // v0.9.1+
+ clearImmediate: true // v0.9.1+
+};
+
+exports.browserify = {
+ __filename : false,
+ __dirname : false,
+ global : false,
+ module : false,
+ require : false,
+ Buffer : true,
+ exports : true,
+ process : true
+};
+
+exports.phantom = {
+ phantom : true,
+ require : true,
+ WebPage : true,
+ console : true, // in examples, but undocumented
+ exports : true // v1.7+
+};
+
+exports.qunit = {
+ asyncTest : false,
+ deepEqual : false,
+ equal : false,
+ expect : false,
+ module : false,
+ notDeepEqual : false,
+ notEqual : false,
+ notPropEqual : false,
+ notStrictEqual : false,
+ ok : false,
+ propEqual : false,
+ QUnit : false,
+ raises : false,
+ start : false,
+ stop : false,
+ strictEqual : false,
+ test : false,
+ "throws" : false
+};
+
+exports.rhino = {
+ defineClass : false,
+ deserialize : false,
+ gc : false,
+ help : false,
+ importClass : false,
+ importPackage: false,
+ "java" : false,
+ load : false,
+ loadClass : false,
+ Packages : false,
+ print : false,
+ quit : false,
+ readFile : false,
+ readUrl : false,
+ runCommand : false,
+ seal : false,
+ serialize : false,
+ spawn : false,
+ sync : false,
+ toint32 : false,
+ version : false
+};
+
+exports.shelljs = {
+ target : false,
+ echo : false,
+ exit : false,
+ cd : false,
+ pwd : false,
+ ls : false,
+ find : false,
+ cp : false,
+ rm : false,
+ mv : false,
+ mkdir : false,
+ test : false,
+ cat : false,
+ sed : false,
+ grep : false,
+ which : false,
+ dirs : false,
+ pushd : false,
+ popd : false,
+ env : false,
+ exec : false,
+ chmod : false,
+ config : false,
+ error : false,
+ tempdir : false
+};
+
+exports.typed = {
+ ArrayBuffer : false,
+ ArrayBufferView : false,
+ DataView : false,
+ Float32Array : false,
+ Float64Array : false,
+ Int16Array : false,
+ Int32Array : false,
+ Int8Array : false,
+ Uint16Array : false,
+ Uint32Array : false,
+ Uint8Array : false,
+ Uint8ClampedArray : false
+};
+
+exports.wsh = {
+ ActiveXObject : true,
+ Enumerator : true,
+ GetObject : true,
+ ScriptEngine : true,
+ ScriptEngineBuildVersion : true,
+ ScriptEngineMajorVersion : true,
+ ScriptEngineMinorVersion : true,
+ VBArray : true,
+ WSH : true,
+ WScript : true,
+ XDomainRequest : true
+};
+
+exports.dojo = {
+ dojo : false,
+ dijit : false,
+ dojox : false,
+ define : false,
+ "require": false
+};
+
+exports.jquery = {
+ "$" : false,
+ jQuery : false
+};
+
+exports.mootools = {
+ "$" : false,
+ "$$" : false,
+ Asset : false,
+ Browser : false,
+ Chain : false,
+ Class : false,
+ Color : false,
+ Cookie : false,
+ Core : false,
+ Document : false,
+ DomReady : false,
+ DOMEvent : false,
+ DOMReady : false,
+ Drag : false,
+ Element : false,
+ Elements : false,
+ Event : false,
+ Events : false,
+ Fx : false,
+ Group : false,
+ Hash : false,
+ HtmlTable : false,
+ IFrame : false,
+ IframeShim : false,
+ InputValidator: false,
+ instanceOf : false,
+ Keyboard : false,
+ Locale : false,
+ Mask : false,
+ MooTools : false,
+ Native : false,
+ Options : false,
+ OverText : false,
+ Request : false,
+ Scroller : false,
+ Slick : false,
+ Slider : false,
+ Sortables : false,
+ Spinner : false,
+ Swiff : false,
+ Tips : false,
+ Type : false,
+ typeOf : false,
+ URI : false,
+ Window : false
+};
+
+exports.prototypejs = {
+ "$" : false,
+ "$$" : false,
+ "$A" : false,
+ "$F" : false,
+ "$H" : false,
+ "$R" : false,
+ "$break" : false,
+ "$continue" : false,
+ "$w" : false,
+ Abstract : false,
+ Ajax : false,
+ Class : false,
+ Enumerable : false,
+ Element : false,
+ Event : false,
+ Field : false,
+ Form : false,
+ Hash : false,
+ Insertion : false,
+ ObjectRange : false,
+ PeriodicalExecuter: false,
+ Position : false,
+ Prototype : false,
+ Selector : false,
+ Template : false,
+ Toggle : false,
+ Try : false,
+ Autocompleter : false,
+ Builder : false,
+ Control : false,
+ Draggable : false,
+ Draggables : false,
+ Droppables : false,
+ Effect : false,
+ Sortable : false,
+ SortableObserver : false,
+ Sound : false,
+ Scriptaculous : false
+};
+
+exports.yui = {
+ YUI : false,
+ Y : false,
+ YUI_config: false
+};
+
+exports.mocha = {
+ mocha : false,
+ describe : false,
+ xdescribe : false,
+ it : false,
+ xit : false,
+ context : false,
+ xcontext : false,
+ before : false,
+ after : false,
+ beforeEach : false,
+ afterEach : false,
+ suite : false,
+ test : false,
+ setup : false,
+ teardown : false,
+ suiteSetup : false,
+ suiteTeardown : false
+};
+
+exports.jasmine = {
+ jasmine : false,
+ describe : false,
+ xdescribe : false,
+ it : false,
+ xit : false,
+ beforeEach : false,
+ afterEach : false,
+ setFixtures : false,
+ loadFixtures: false,
+ spyOn : false,
+ expect : false,
+ runs : false,
+ waitsFor : false,
+ waits : false,
+ beforeAll : false,
+ afterAll : false,
+ fail : false,
+ fdescribe : false,
+ fit : false,
+ pending : false
+};
+
+},{}]},{},["/node_modules/jshint/src/jshint.js"]);
+
+});
+
+ace.define("ace/mode/javascript_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/javascript/jshint"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var Mirror = require("../worker/mirror").Mirror;
+var lint = require("./javascript/jshint").JSHINT;
+
+function startRegex(arr) {
+ return RegExp("^(" + arr.join("|") + ")");
+}
+
+var disabledWarningsRe = startRegex([
+ "Bad for in variable '(.+)'.",
+ 'Missing "use strict"'
+]);
+var errorsRe = startRegex([
+ "Unexpected",
+ "Expected ",
+ "Confusing (plus|minus)",
+ "\\{a\\} unterminated regular expression",
+ "Unclosed ",
+ "Unmatched ",
+ "Unbegun comment",
+ "Bad invocation",
+ "Missing space after",
+ "Missing operator at"
+]);
+var infoRe = startRegex([
+ "Expected an assignment",
+ "Bad escapement of EOL",
+ "Unexpected comma",
+ "Unexpected space",
+ "Missing radix parameter.",
+ "A leading decimal point can",
+ "\\['{a}'\\] is better written in dot notation.",
+ "'{a}' used out of scope"
+]);
+
+var JavaScriptWorker = exports.JavaScriptWorker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(500);
+ this.setOptions();
+};
+
+oop.inherits(JavaScriptWorker, Mirror);
+
+(function() {
+ this.setOptions = function(options) {
+ this.options = options || {
+ esnext: true,
+ moz: true,
+ devel: true,
+ browser: true,
+ node: true,
+ laxcomma: true,
+ laxbreak: true,
+ lastsemic: true,
+ onevar: false,
+ passfail: false,
+ maxerr: 100,
+ expr: true,
+ multistr: true,
+ globalstrict: true
+ };
+ this.doc.getValue() && this.deferredUpdate.schedule(100);
+ };
+
+ this.changeOptions = function(newOptions) {
+ oop.mixin(this.options, newOptions);
+ this.doc.getValue() && this.deferredUpdate.schedule(100);
+ };
+
+ this.isValidJS = function(str) {
+ try {
+ eval("throw 0;" + str);
+ } catch(e) {
+ if (e === 0)
+ return true;
+ }
+ return false
+ };
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ value = value.replace(/^#!.*\n/, "\n");
+ if (!value)
+ return this.sender.emit("annotate", []);
+
+ var errors = [];
+ var maxErrorLevel = this.isValidJS(value) ? "warning" : "error";
+ lint(value, this.options, this.options.globals);
+ var results = lint.errors;
+
+ var errorAdded = false
+ for (var i = 0; i < results.length; i++) {
+ var error = results[i];
+ if (!error)
+ continue;
+ var raw = error.raw;
+ var type = "warning";
+
+ if (raw == "Missing semicolon.") {
+ var str = error.evidence.substr(error.character);
+ str = str.charAt(str.search(/\S/));
+ if (maxErrorLevel == "error" && str && /[\w\d{(['"]/.test(str)) {
+ error.reason = 'Missing ";" before statement';
+ type = "error";
+ } else {
+ type = "info";
+ }
+ }
+ else if (disabledWarningsRe.test(raw)) {
+ continue;
+ }
+ else if (infoRe.test(raw)) {
+ type = "info"
+ }
+ else if (errorsRe.test(raw)) {
+ errorAdded = true;
+ type = maxErrorLevel;
+ }
+ else if (raw == "'{a}' is not defined.") {
+ type = "warning";
+ }
+ else if (raw == "'{a}' is defined but never used.") {
+ type = "info";
+ }
+
+ errors.push({
+ row: error.line-1,
+ column: error.character-1,
+ text: error.reason,
+ type: type,
+ raw: raw
+ });
+
+ if (errorAdded) {
+ }
+ }
+
+ this.sender.emit("annotate", errors);
+ };
+
+}).call(JavaScriptWorker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-json.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-json.js
new file mode 100644
index 00000000..e22fa899
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-json.js
@@ -0,0 +1,2396 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/json/json_parse",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+ var at, // The index of the current character
+ ch, // The current character
+ escapee = {
+ '"': '"',
+ '\\': '\\',
+ '/': '/',
+ b: '\b',
+ f: '\f',
+ n: '\n',
+ r: '\r',
+ t: '\t'
+ },
+ text,
+
+ error = function (m) {
+
+ throw {
+ name: 'SyntaxError',
+ message: m,
+ at: at,
+ text: text
+ };
+ },
+
+ next = function (c) {
+
+ if (c && c !== ch) {
+ error("Expected '" + c + "' instead of '" + ch + "'");
+ }
+
+ ch = text.charAt(at);
+ at += 1;
+ return ch;
+ },
+
+ number = function () {
+
+ var number,
+ string = '';
+
+ if (ch === '-') {
+ string = '-';
+ next('-');
+ }
+ while (ch >= '0' && ch <= '9') {
+ string += ch;
+ next();
+ }
+ if (ch === '.') {
+ string += '.';
+ while (next() && ch >= '0' && ch <= '9') {
+ string += ch;
+ }
+ }
+ if (ch === 'e' || ch === 'E') {
+ string += ch;
+ next();
+ if (ch === '-' || ch === '+') {
+ string += ch;
+ next();
+ }
+ while (ch >= '0' && ch <= '9') {
+ string += ch;
+ next();
+ }
+ }
+ number = +string;
+ if (isNaN(number)) {
+ error("Bad number");
+ } else {
+ return number;
+ }
+ },
+
+ string = function () {
+
+ var hex,
+ i,
+ string = '',
+ uffff;
+
+ if (ch === '"') {
+ while (next()) {
+ if (ch === '"') {
+ next();
+ return string;
+ } else if (ch === '\\') {
+ next();
+ if (ch === 'u') {
+ uffff = 0;
+ for (i = 0; i < 4; i += 1) {
+ hex = parseInt(next(), 16);
+ if (!isFinite(hex)) {
+ break;
+ }
+ uffff = uffff * 16 + hex;
+ }
+ string += String.fromCharCode(uffff);
+ } else if (typeof escapee[ch] === 'string') {
+ string += escapee[ch];
+ } else {
+ break;
+ }
+ } else {
+ string += ch;
+ }
+ }
+ }
+ error("Bad string");
+ },
+
+ white = function () {
+
+ while (ch && ch <= ' ') {
+ next();
+ }
+ },
+
+ word = function () {
+
+ switch (ch) {
+ case 't':
+ next('t');
+ next('r');
+ next('u');
+ next('e');
+ return true;
+ case 'f':
+ next('f');
+ next('a');
+ next('l');
+ next('s');
+ next('e');
+ return false;
+ case 'n':
+ next('n');
+ next('u');
+ next('l');
+ next('l');
+ return null;
+ }
+ error("Unexpected '" + ch + "'");
+ },
+
+ value, // Place holder for the value function.
+
+ array = function () {
+
+ var array = [];
+
+ if (ch === '[') {
+ next('[');
+ white();
+ if (ch === ']') {
+ next(']');
+ return array; // empty array
+ }
+ while (ch) {
+ array.push(value());
+ white();
+ if (ch === ']') {
+ next(']');
+ return array;
+ }
+ next(',');
+ white();
+ }
+ }
+ error("Bad array");
+ },
+
+ object = function () {
+
+ var key,
+ object = {};
+
+ if (ch === '{') {
+ next('{');
+ white();
+ if (ch === '}') {
+ next('}');
+ return object; // empty object
+ }
+ while (ch) {
+ key = string();
+ white();
+ next(':');
+ if (Object.hasOwnProperty.call(object, key)) {
+ error('Duplicate key "' + key + '"');
+ }
+ object[key] = value();
+ white();
+ if (ch === '}') {
+ next('}');
+ return object;
+ }
+ next(',');
+ white();
+ }
+ }
+ error("Bad object");
+ };
+
+ value = function () {
+
+ white();
+ switch (ch) {
+ case '{':
+ return object();
+ case '[':
+ return array();
+ case '"':
+ return string();
+ case '-':
+ return number();
+ default:
+ return ch >= '0' && ch <= '9' ? number() : word();
+ }
+ };
+
+ return function (source, reviver) {
+ var result;
+
+ text = source;
+ at = 0;
+ ch = ' ';
+ result = value();
+ white();
+ if (ch) {
+ error("Syntax error");
+ }
+
+ return typeof reviver === 'function' ? function walk(holder, key) {
+ var k, v, value = holder[key];
+ if (value && typeof value === 'object') {
+ for (k in value) {
+ if (Object.hasOwnProperty.call(value, k)) {
+ v = walk(value, k);
+ if (v !== undefined) {
+ value[k] = v;
+ } else {
+ delete value[k];
+ }
+ }
+ }
+ }
+ return reviver.call(holder, key, value);
+ }({'': result}, '') : result;
+ };
+});
+
+ace.define("ace/mode/json_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/json/json_parse"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var Mirror = require("../worker/mirror").Mirror;
+var parse = require("./json/json_parse");
+
+var JsonWorker = exports.JsonWorker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(200);
+};
+
+oop.inherits(JsonWorker, Mirror);
+
+(function() {
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ var errors = [];
+ try {
+ if (value)
+ parse(value);
+ } catch (e) {
+ var pos = this.doc.indexToPosition(e.at-1);
+ errors.push({
+ row: pos.row,
+ column: pos.column,
+ text: e.message,
+ type: "error"
+ });
+ }
+ this.sender.emit("annotate", errors);
+ };
+
+}).call(JsonWorker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-lua.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-lua.js
new file mode 100644
index 00000000..e5026eab
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-lua.js
@@ -0,0 +1,3632 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/lua/luaparse",["require","exports","module"], function(require, exports, module) {
+
+(function (root, name, factory) {
+ factory(exports)
+}(this, 'luaparse', function (exports) {
+ 'use strict';
+
+ exports.version = '0.1.4';
+
+ var input, options, length;
+ var defaultOptions = exports.defaultOptions = {
+ wait: false
+ , comments: true
+ , scope: false
+ , locations: false
+ , ranges: false
+ };
+
+ var EOF = 1, StringLiteral = 2, Keyword = 4, Identifier = 8
+ , NumericLiteral = 16, Punctuator = 32, BooleanLiteral = 64
+ , NilLiteral = 128, VarargLiteral = 256;
+
+ exports.tokenTypes = { EOF: EOF, StringLiteral: StringLiteral
+ , Keyword: Keyword, Identifier: Identifier, NumericLiteral: NumericLiteral
+ , Punctuator: Punctuator, BooleanLiteral: BooleanLiteral
+ , NilLiteral: NilLiteral, VarargLiteral: VarargLiteral
+ };
+
+ var errors = exports.errors = {
+ unexpected: 'Unexpected %1 \'%2\' near \'%3\''
+ , expected: '\'%1\' expected near \'%2\''
+ , expectedToken: '%1 expected near \'%2\''
+ , unfinishedString: 'unfinished string near \'%1\''
+ , malformedNumber: 'malformed number near \'%1\''
+ };
+
+ var ast = exports.ast = {
+ labelStatement: function(label) {
+ return {
+ type: 'LabelStatement'
+ , label: label
+ };
+ }
+
+ , breakStatement: function() {
+ return {
+ type: 'BreakStatement'
+ };
+ }
+
+ , gotoStatement: function(label) {
+ return {
+ type: 'GotoStatement'
+ , label: label
+ };
+ }
+
+ , returnStatement: function(args) {
+ return {
+ type: 'ReturnStatement'
+ , 'arguments': args
+ };
+ }
+
+ , ifStatement: function(clauses) {
+ return {
+ type: 'IfStatement'
+ , clauses: clauses
+ };
+ }
+ , ifClause: function(condition, body) {
+ return {
+ type: 'IfClause'
+ , condition: condition
+ , body: body
+ };
+ }
+ , elseifClause: function(condition, body) {
+ return {
+ type: 'ElseifClause'
+ , condition: condition
+ , body: body
+ };
+ }
+ , elseClause: function(body) {
+ return {
+ type: 'ElseClause'
+ , body: body
+ };
+ }
+
+ , whileStatement: function(condition, body) {
+ return {
+ type: 'WhileStatement'
+ , condition: condition
+ , body: body
+ };
+ }
+
+ , doStatement: function(body) {
+ return {
+ type: 'DoStatement'
+ , body: body
+ };
+ }
+
+ , repeatStatement: function(condition, body) {
+ return {
+ type: 'RepeatStatement'
+ , condition: condition
+ , body: body
+ };
+ }
+
+ , localStatement: function(variables, init) {
+ return {
+ type: 'LocalStatement'
+ , variables: variables
+ , init: init
+ };
+ }
+
+ , assignmentStatement: function(variables, init) {
+ return {
+ type: 'AssignmentStatement'
+ , variables: variables
+ , init: init
+ };
+ }
+
+ , callStatement: function(expression) {
+ return {
+ type: 'CallStatement'
+ , expression: expression
+ };
+ }
+
+ , functionStatement: function(identifier, parameters, isLocal, body) {
+ return {
+ type: 'FunctionDeclaration'
+ , identifier: identifier
+ , isLocal: isLocal
+ , parameters: parameters
+ , body: body
+ };
+ }
+
+ , forNumericStatement: function(variable, start, end, step, body) {
+ return {
+ type: 'ForNumericStatement'
+ , variable: variable
+ , start: start
+ , end: end
+ , step: step
+ , body: body
+ };
+ }
+
+ , forGenericStatement: function(variables, iterators, body) {
+ return {
+ type: 'ForGenericStatement'
+ , variables: variables
+ , iterators: iterators
+ , body: body
+ };
+ }
+
+ , chunk: function(body) {
+ return {
+ type: 'Chunk'
+ , body: body
+ };
+ }
+
+ , identifier: function(name) {
+ return {
+ type: 'Identifier'
+ , name: name
+ };
+ }
+
+ , literal: function(type, value, raw) {
+ type = (type === StringLiteral) ? 'StringLiteral'
+ : (type === NumericLiteral) ? 'NumericLiteral'
+ : (type === BooleanLiteral) ? 'BooleanLiteral'
+ : (type === NilLiteral) ? 'NilLiteral'
+ : 'VarargLiteral';
+
+ return {
+ type: type
+ , value: value
+ , raw: raw
+ };
+ }
+
+ , tableKey: function(key, value) {
+ return {
+ type: 'TableKey'
+ , key: key
+ , value: value
+ };
+ }
+ , tableKeyString: function(key, value) {
+ return {
+ type: 'TableKeyString'
+ , key: key
+ , value: value
+ };
+ }
+ , tableValue: function(value) {
+ return {
+ type: 'TableValue'
+ , value: value
+ };
+ }
+
+
+ , tableConstructorExpression: function(fields) {
+ return {
+ type: 'TableConstructorExpression'
+ , fields: fields
+ };
+ }
+ , binaryExpression: function(operator, left, right) {
+ var type = ('and' === operator || 'or' === operator) ?
+ 'LogicalExpression' :
+ 'BinaryExpression';
+
+ return {
+ type: type
+ , operator: operator
+ , left: left
+ , right: right
+ };
+ }
+ , unaryExpression: function(operator, argument) {
+ return {
+ type: 'UnaryExpression'
+ , operator: operator
+ , argument: argument
+ };
+ }
+ , memberExpression: function(base, indexer, identifier) {
+ return {
+ type: 'MemberExpression'
+ , indexer: indexer
+ , identifier: identifier
+ , base: base
+ };
+ }
+
+ , indexExpression: function(base, index) {
+ return {
+ type: 'IndexExpression'
+ , base: base
+ , index: index
+ };
+ }
+
+ , callExpression: function(base, args) {
+ return {
+ type: 'CallExpression'
+ , base: base
+ , 'arguments': args
+ };
+ }
+
+ , tableCallExpression: function(base, args) {
+ return {
+ type: 'TableCallExpression'
+ , base: base
+ , 'arguments': args
+ };
+ }
+
+ , stringCallExpression: function(base, argument) {
+ return {
+ type: 'StringCallExpression'
+ , base: base
+ , argument: argument
+ };
+ }
+
+ , comment: function(value, raw) {
+ return {
+ type: 'Comment'
+ , value: value
+ , raw: raw
+ };
+ }
+ };
+
+ function finishNode(node) {
+ if (trackLocations) {
+ var location = locations.pop();
+ location.complete();
+ if (options.locations) node.loc = location.loc;
+ if (options.ranges) node.range = location.range;
+ }
+ return node;
+ }
+
+ var slice = Array.prototype.slice
+ , toString = Object.prototype.toString
+ , indexOf = function indexOf(array, element) {
+ for (var i = 0, length = array.length; i < length; i++) {
+ if (array[i] === element) return i;
+ }
+ return -1;
+ };
+
+ function indexOfObject(array, property, element) {
+ for (var i = 0, length = array.length; i < length; i++) {
+ if (array[i][property] === element) return i;
+ }
+ return -1;
+ }
+
+ function sprintf(format) {
+ var args = slice.call(arguments, 1);
+ format = format.replace(/%(\d)/g, function (match, index) {
+ return '' + args[index - 1] || '';
+ });
+ return format;
+ }
+
+ function extend() {
+ var args = slice.call(arguments)
+ , dest = {}
+ , src, prop;
+
+ for (var i = 0, length = args.length; i < length; i++) {
+ src = args[i];
+ for (prop in src) if (src.hasOwnProperty(prop)) {
+ dest[prop] = src[prop];
+ }
+ }
+ return dest;
+ }
+
+ function raise(token) {
+ var message = sprintf.apply(null, slice.call(arguments, 1))
+ , error, col;
+
+ if ('undefined' !== typeof token.line) {
+ col = token.range[0] - token.lineStart;
+ error = new SyntaxError(sprintf('[%1:%2] %3', token.line, col, message));
+ error.line = token.line;
+ error.index = token.range[0];
+ error.column = col;
+ } else {
+ col = index - lineStart + 1;
+ error = new SyntaxError(sprintf('[%1:%2] %3', line, col, message));
+ error.index = index;
+ error.line = line;
+ error.column = col;
+ }
+ throw error;
+ }
+
+ function raiseUnexpectedToken(type, token) {
+ raise(token, errors.expectedToken, type, token.value);
+ }
+
+ function unexpected(found, near) {
+ if ('undefined' === typeof near) near = lookahead.value;
+ if ('undefined' !== typeof found.type) {
+ var type;
+ switch (found.type) {
+ case StringLiteral: type = 'string'; break;
+ case Keyword: type = 'keyword'; break;
+ case Identifier: type = 'identifier'; break;
+ case NumericLiteral: type = 'number'; break;
+ case Punctuator: type = 'symbol'; break;
+ case BooleanLiteral: type = 'boolean'; break;
+ case NilLiteral:
+ return raise(found, errors.unexpected, 'symbol', 'nil', near);
+ }
+ return raise(found, errors.unexpected, type, found.value, near);
+ }
+ return raise(found, errors.unexpected, 'symbol', found, near);
+ }
+
+ var index
+ , token
+ , previousToken
+ , lookahead
+ , comments
+ , tokenStart
+ , line
+ , lineStart;
+
+ exports.lex = lex;
+
+ function lex() {
+ skipWhiteSpace();
+ while (45 === input.charCodeAt(index) &&
+ 45 === input.charCodeAt(index + 1)) {
+ scanComment();
+ skipWhiteSpace();
+ }
+ if (index >= length) return {
+ type : EOF
+ , value: '<eof>'
+ , line: line
+ , lineStart: lineStart
+ , range: [index, index]
+ };
+
+ var charCode = input.charCodeAt(index)
+ , next = input.charCodeAt(index + 1);
+ tokenStart = index;
+ if (isIdentifierStart(charCode)) return scanIdentifierOrKeyword();
+
+ switch (charCode) {
+ case 39: case 34: // '"
+ return scanStringLiteral();
+ case 48: case 49: case 50: case 51: case 52: case 53:
+ case 54: case 55: case 56: case 57:
+ return scanNumericLiteral();
+
+ case 46: // .
+ if (isDecDigit(next)) return scanNumericLiteral();
+ if (46 === next) {
+ if (46 === input.charCodeAt(index + 2)) return scanVarargLiteral();
+ return scanPunctuator('..');
+ }
+ return scanPunctuator('.');
+
+ case 61: // =
+ if (61 === next) return scanPunctuator('==');
+ return scanPunctuator('=');
+
+ case 62: // >
+ if (61 === next) return scanPunctuator('>=');
+ return scanPunctuator('>');
+
+ case 60: // <
+ if (61 === next) return scanPunctuator('<=');
+ return scanPunctuator('<');
+
+ case 126: // ~
+ if (61 === next) return scanPunctuator('~=');
+ return scanPunctuator('~');
+
+ case 58: // :
+ if (58 === next) return scanPunctuator('::');
+ return scanPunctuator(':');
+
+ case 91: // [
+ if (91 === next || 61 === next) return scanLongStringLiteral();
+ return scanPunctuator('[');
+ case 42: case 47: case 94: case 37: case 44: case 123: case 125:
+ case 93: case 40: case 41: case 59: case 35: case 45: case 43:
+ return scanPunctuator(input.charAt(index));
+ }
+
+ return unexpected(input.charAt(index));
+ }
+
+ function skipWhiteSpace() {
+ while (index < length) {
+ var charCode = input.charCodeAt(index);
+ if (isWhiteSpace(charCode)) {
+ index++;
+ } else if (isLineTerminator(charCode)) {
+ line++;
+ lineStart = ++index;
+ } else {
+ break;
+ }
+ }
+ }
+
+ function scanIdentifierOrKeyword() {
+ var value, type;
+ while (isIdentifierPart(input.charCodeAt(++index)));
+ value = input.slice(tokenStart, index);
+ if (isKeyword(value)) {
+ type = Keyword;
+ } else if ('true' === value || 'false' === value) {
+ type = BooleanLiteral;
+ value = ('true' === value);
+ } else if ('nil' === value) {
+ type = NilLiteral;
+ value = null;
+ } else {
+ type = Identifier;
+ }
+
+ return {
+ type: type
+ , value: value
+ , line: line
+ , lineStart: lineStart
+ , range: [tokenStart, index]
+ };
+ }
+
+ function scanPunctuator(value) {
+ index += value.length;
+ return {
+ type: Punctuator
+ , value: value
+ , line: line
+ , lineStart: lineStart
+ , range: [tokenStart, index]
+ };
+ }
+
+ function scanVarargLiteral() {
+ index += 3;
+ return {
+ type: VarargLiteral
+ , value: '...'
+ , line: line
+ , lineStart: lineStart
+ , range: [tokenStart, index]
+ };
+ }
+
+ function scanStringLiteral() {
+ var delimiter = input.charCodeAt(index++)
+ , stringStart = index
+ , string = ''
+ , charCode;
+
+ while (index < length) {
+ charCode = input.charCodeAt(index++);
+ if (delimiter === charCode) break;
+ if (92 === charCode) { // \
+ string += input.slice(stringStart, index - 1) + readEscapeSequence();
+ stringStart = index;
+ }
+ else if (index >= length || isLineTerminator(charCode)) {
+ string += input.slice(stringStart, index - 1);
+ raise({}, errors.unfinishedString, string + String.fromCharCode(charCode));
+ }
+ }
+ string += input.slice(stringStart, index - 1);
+
+ return {
+ type: StringLiteral
+ , value: string
+ , line: line
+ , lineStart: lineStart
+ , range: [tokenStart, index]
+ };
+ }
+
+ function scanLongStringLiteral() {
+ var string = readLongString();
+ if (false === string) raise(token, errors.expected, '[', token.value);
+
+ return {
+ type: StringLiteral
+ , value: string
+ , line: line
+ , lineStart: lineStart
+ , range: [tokenStart, index]
+ };
+ }
+
+ function scanNumericLiteral() {
+ var character = input.charAt(index)
+ , next = input.charAt(index + 1);
+
+ var value = ('0' === character && 'xX'.indexOf(next || null) >= 0) ?
+ readHexLiteral() : readDecLiteral();
+
+ return {
+ type: NumericLiteral
+ , value: value
+ , line: line
+ , lineStart: lineStart
+ , range: [tokenStart, index]
+ };
+ }
+
+ function readHexLiteral() {
+ var fraction = 0 // defaults to 0 as it gets summed
+ , binaryExponent = 1 // defaults to 1 as it gets multiplied
+ , binarySign = 1 // positive
+ , digit, fractionStart, exponentStart, digitStart;
+
+ digitStart = index += 2; // Skip 0x part
+ if (!isHexDigit(input.charCodeAt(index)))
+ raise({}, errors.malformedNumber, input.slice(tokenStart, index));
+
+ while (isHexDigit(input.charCodeAt(index))) index++;
+ digit = parseInt(input.slice(digitStart, index), 16);
+ if ('.' === input.charAt(index)) {
+ fractionStart = ++index;
+
+ while (isHexDigit(input.charCodeAt(index))) index++;
+ fraction = input.slice(fractionStart, index);
+ fraction = (fractionStart === index) ? 0
+ : parseInt(fraction, 16) / Math.pow(16, index - fractionStart);
+ }
+ if ('pP'.indexOf(input.charAt(index) || null) >= 0) {
+ index++;
+ if ('+-'.indexOf(input.charAt(index) || null) >= 0)
+ binarySign = ('+' === input.charAt(index++)) ? 1 : -1;
+
+ exponentStart = index;
+ if (!isDecDigit(input.charCodeAt(index)))
+ raise({}, errors.malformedNumber, input.slice(tokenStart, index));
+
+ while (isDecDigit(input.charCodeAt(index))) index++;
+ binaryExponent = input.slice(exponentStart, index);
+ binaryExponent = Math.pow(2, binaryExponent * binarySign);
+ }
+
+ return (digit + fraction) * binaryExponent;
+ }
+
+ function readDecLiteral() {
+ while (isDecDigit(input.charCodeAt(index))) index++;
+ if ('.' === input.charAt(index)) {
+ index++;
+ while (isDecDigit(input.charCodeAt(index))) index++;
+ }
+ if ('eE'.indexOf(input.charAt(index) || null) >= 0) {
+ index++;
+ if ('+-'.indexOf(input.charAt(index) || null) >= 0) index++;
+ if (!isDecDigit(input.charCodeAt(index)))
+ raise({}, errors.malformedNumber, input.slice(tokenStart, index));
+
+ while (isDecDigit(input.charCodeAt(index))) index++;
+ }
+
+ return parseFloat(input.slice(tokenStart, index));
+ }
+
+ function readEscapeSequence() {
+ var sequenceStart = index;
+ switch (input.charAt(index)) {
+ case 'n': index++; return '\n';
+ case 'r': index++; return '\r';
+ case 't': index++; return '\t';
+ case 'v': index++; return '\x0B';
+ case 'b': index++; return '\b';
+ case 'f': index++; return '\f';
+ case 'z': index++; skipWhiteSpace(); return '';
+ case 'x':
+ if (isHexDigit(input.charCodeAt(index + 1)) &&
+ isHexDigit(input.charCodeAt(index + 2))) {
+ index += 3;
+ return '\\' + input.slice(sequenceStart, index);
+ }
+ return '\\' + input.charAt(index++);
+ default:
+ if (isDecDigit(input.charCodeAt(index))) {
+ while (isDecDigit(input.charCodeAt(++index)));
+ return '\\' + input.slice(sequenceStart, index);
+ }
+ return input.charAt(index++);
+ }
+ }
+
+ function scanComment() {
+ tokenStart = index;
+ index += 2; // --
+
+ var character = input.charAt(index)
+ , content = ''
+ , isLong = false
+ , commentStart = index
+ , lineStartComment = lineStart
+ , lineComment = line;
+
+ if ('[' === character) {
+ content = readLongString();
+ if (false === content) content = character;
+ else isLong = true;
+ }
+ if (!isLong) {
+ while (index < length) {
+ if (isLineTerminator(input.charCodeAt(index))) break;
+ index++;
+ }
+ if (options.comments) content = input.slice(commentStart, index);
+ }
+
+ if (options.comments) {
+ var node = ast.comment(content, input.slice(tokenStart, index));
+ if (options.locations) {
+ node.loc = {
+ start: { line: lineComment, column: tokenStart - lineStartComment }
+ , end: { line: line, column: index - lineStart }
+ };
+ }
+ if (options.ranges) {
+ node.range = [tokenStart, index];
+ }
+ comments.push(node);
+ }
+ }
+
+ function readLongString() {
+ var level = 0
+ , content = ''
+ , terminator = false
+ , character, stringStart;
+
+ index++; // [
+ while ('=' === input.charAt(index + level)) level++;
+ if ('[' !== input.charAt(index + level)) return false;
+
+ index += level + 1;
+ if (isLineTerminator(input.charCodeAt(index))) {
+ line++;
+ lineStart = index++;
+ }
+
+ stringStart = index;
+ while (index < length) {
+ character = input.charAt(index++);
+ if (isLineTerminator(character.charCodeAt(0))) {
+ line++;
+ lineStart = index;
+ }
+ if (']' === character) {
+ terminator = true;
+ for (var i = 0; i < level; i++) {
+ if ('=' !== input.charAt(index + i)) terminator = false;
+ }
+ if (']' !== input.charAt(index + level)) terminator = false;
+ }
+ if (terminator) break;
+ }
+ content += input.slice(stringStart, index - 1);
+ index += level + 1;
+
+ return content;
+ }
+
+ function next() {
+ previousToken = token;
+ token = lookahead;
+ lookahead = lex();
+ }
+
+ function consume(value) {
+ if (value === token.value) {
+ next();
+ return true;
+ }
+ return false;
+ }
+
+ function expect(value) {
+ if (value === token.value) next();
+ else raise(token, errors.expected, value, token.value);
+ }
+
+ function isWhiteSpace(charCode) {
+ return 9 === charCode || 32 === charCode || 0xB === charCode || 0xC === charCode;
+ }
+
+ function isLineTerminator(charCode) {
+ return 10 === charCode || 13 === charCode;
+ }
+
+ function isDecDigit(charCode) {
+ return charCode >= 48 && charCode <= 57;
+ }
+
+ function isHexDigit(charCode) {
+ return (charCode >= 48 && charCode <= 57) || (charCode >= 97 && charCode <= 102) || (charCode >= 65 && charCode <= 70);
+ }
+
+ function isIdentifierStart(charCode) {
+ return (charCode >= 65 && charCode <= 90) || (charCode >= 97 && charCode <= 122) || 95 === charCode;
+ }
+
+ function isIdentifierPart(charCode) {
+ return (charCode >= 65 && charCode <= 90) || (charCode >= 97 && charCode <= 122) || 95 === charCode || (charCode >= 48 && charCode <= 57);
+ }
+
+ function isKeyword(id) {
+ switch (id.length) {
+ case 2:
+ return 'do' === id || 'if' === id || 'in' === id || 'or' === id;
+ case 3:
+ return 'and' === id || 'end' === id || 'for' === id || 'not' === id;
+ case 4:
+ return 'else' === id || 'goto' === id || 'then' === id;
+ case 5:
+ return 'break' === id || 'local' === id || 'until' === id || 'while' === id;
+ case 6:
+ return 'elseif' === id || 'repeat' === id || 'return' === id;
+ case 8:
+ return 'function' === id;
+ }
+ return false;
+ }
+
+ function isUnary(token) {
+ if (Punctuator === token.type) return '#-~'.indexOf(token.value) >= 0;
+ if (Keyword === token.type) return 'not' === token.value;
+ return false;
+ }
+ function isCallExpression(expression) {
+ switch (expression.type) {
+ case 'CallExpression':
+ case 'TableCallExpression':
+ case 'StringCallExpression':
+ return true;
+ }
+ return false;
+ }
+
+ function isBlockFollow(token) {
+ if (EOF === token.type) return true;
+ if (Keyword !== token.type) return false;
+ switch (token.value) {
+ case 'else': case 'elseif':
+ case 'end': case 'until':
+ return true;
+ default:
+ return false;
+ }
+ }
+ var scopes
+ , scopeDepth
+ , globals;
+ function createScope() {
+ scopes.push(Array.apply(null, scopes[scopeDepth++]));
+ }
+ function exitScope() {
+ scopes.pop();
+ scopeDepth--;
+ }
+ function scopeIdentifierName(name) {
+ if (-1 !== indexOf(scopes[scopeDepth], name)) return;
+ scopes[scopeDepth].push(name);
+ }
+ function scopeIdentifier(node) {
+ scopeIdentifierName(node.name);
+ attachScope(node, true);
+ }
+ function attachScope(node, isLocal) {
+ if (!isLocal && -1 === indexOfObject(globals, 'name', node.name))
+ globals.push(node);
+
+ node.isLocal = isLocal;
+ }
+ function scopeHasName(name) {
+ return (-1 !== indexOf(scopes[scopeDepth], name));
+ }
+
+ var locations = []
+ , trackLocations;
+
+ function createLocationMarker() {
+ return new Marker(token);
+ }
+
+ function Marker(token) {
+ if (options.locations) {
+ this.loc = {
+ start: {
+ line: token.line
+ , column: token.range[0] - token.lineStart
+ }
+ , end: {
+ line: 0
+ , column: 0
+ }
+ };
+ }
+ if (options.ranges) this.range = [token.range[0], 0];
+ }
+ Marker.prototype.complete = function() {
+ if (options.locations) {
+ this.loc.end.line = previousToken.line;
+ this.loc.end.column = previousToken.range[1] - previousToken.lineStart;
+ }
+ if (options.ranges) {
+ this.range[1] = previousToken.range[1];
+ }
+ };
+ function markLocation() {
+ if (trackLocations) locations.push(createLocationMarker());
+ }
+ function pushLocation(marker) {
+ if (trackLocations) locations.push(marker);
+ }
+
+ function parseChunk() {
+ next();
+ markLocation();
+ var body = parseBlock();
+ if (EOF !== token.type) unexpected(token);
+ if (trackLocations && !body.length) previousToken = token;
+ return finishNode(ast.chunk(body));
+ }
+
+ function parseBlock(terminator) {
+ var block = []
+ , statement;
+ if (options.scope) createScope();
+
+ while (!isBlockFollow(token)) {
+ if ('return' === token.value) {
+ block.push(parseStatement());
+ break;
+ }
+ statement = parseStatement();
+ if (statement) block.push(statement);
+ }
+
+ if (options.scope) exitScope();
+ return block;
+ }
+
+ function parseStatement() {
+ markLocation();
+ if (Keyword === token.type) {
+ switch (token.value) {
+ case 'local': next(); return parseLocalStatement();
+ case 'if': next(); return parseIfStatement();
+ case 'return': next(); return parseReturnStatement();
+ case 'function': next();
+ var name = parseFunctionName();
+ return parseFunctionDeclaration(name);
+ case 'while': next(); return parseWhileStatement();
+ case 'for': next(); return parseForStatement();
+ case 'repeat': next(); return parseRepeatStatement();
+ case 'break': next(); return parseBreakStatement();
+ case 'do': next(); return parseDoStatement();
+ case 'goto': next(); return parseGotoStatement();
+ }
+ }
+
+ if (Punctuator === token.type) {
+ if (consume('::')) return parseLabelStatement();
+ }
+ if (trackLocations) locations.pop();
+ if (consume(';')) return;
+
+ return parseAssignmentOrCallStatement();
+ }
+
+ function parseLabelStatement() {
+ var name = token.value
+ , label = parseIdentifier();
+
+ if (options.scope) {
+ scopeIdentifierName('::' + name + '::');
+ attachScope(label, true);
+ }
+
+ expect('::');
+ return finishNode(ast.labelStatement(label));
+ }
+
+ function parseBreakStatement() {
+ return finishNode(ast.breakStatement());
+ }
+
+ function parseGotoStatement() {
+ var name = token.value
+ , label = parseIdentifier();
+
+ if (options.scope) label.isLabel = scopeHasName('::' + name + '::');
+ return finishNode(ast.gotoStatement(label));
+ }
+
+ function parseDoStatement() {
+ var body = parseBlock();
+ expect('end');
+ return finishNode(ast.doStatement(body));
+ }
+
+ function parseWhileStatement() {
+ var condition = parseExpectedExpression();
+ expect('do');
+ var body = parseBlock();
+ expect('end');
+ return finishNode(ast.whileStatement(condition, body));
+ }
+
+ function parseRepeatStatement() {
+ var body = parseBlock();
+ expect('until');
+ var condition = parseExpectedExpression();
+ return finishNode(ast.repeatStatement(condition, body));
+ }
+
+ function parseReturnStatement() {
+ var expressions = [];
+
+ if ('end' !== token.value) {
+ var expression = parseExpression();
+ if (null != expression) expressions.push(expression);
+ while (consume(',')) {
+ expression = parseExpectedExpression();
+ expressions.push(expression);
+ }
+ consume(';'); // grammar tells us ; is optional here.
+ }
+ return finishNode(ast.returnStatement(expressions));
+ }
+
+ function parseIfStatement() {
+ var clauses = []
+ , condition
+ , body
+ , marker;
+ if (trackLocations) {
+ marker = locations[locations.length - 1];
+ locations.push(marker);
+ }
+ condition = parseExpectedExpression();
+ expect('then');
+ body = parseBlock();
+ clauses.push(finishNode(ast.ifClause(condition, body)));
+
+ if (trackLocations) marker = createLocationMarker();
+ while (consume('elseif')) {
+ pushLocation(marker);
+ condition = parseExpectedExpression();
+ expect('then');
+ body = parseBlock();
+ clauses.push(finishNode(ast.elseifClause(condition, body)));
+ if (trackLocations) marker = createLocationMarker();
+ }
+
+ if (consume('else')) {
+ if (trackLocations) {
+ marker = new Marker(previousToken);
+ locations.push(marker);
+ }
+ body = parseBlock();
+ clauses.push(finishNode(ast.elseClause(body)));
+ }
+
+ expect('end');
+ return finishNode(ast.ifStatement(clauses));
+ }
+
+ function parseForStatement() {
+ var variable = parseIdentifier()
+ , body;
+ if (options.scope) scopeIdentifier(variable);
+ if (consume('=')) {
+ var start = parseExpectedExpression();
+ expect(',');
+ var end = parseExpectedExpression();
+ var step = consume(',') ? parseExpectedExpression() : null;
+
+ expect('do');
+ body = parseBlock();
+ expect('end');
+
+ return finishNode(ast.forNumericStatement(variable, start, end, step, body));
+ }
+ else {
+ var variables = [variable];
+ while (consume(',')) {
+ variable = parseIdentifier();
+ if (options.scope) scopeIdentifier(variable);
+ variables.push(variable);
+ }
+ expect('in');
+ var iterators = [];
+ do {
+ var expression = parseExpectedExpression();
+ iterators.push(expression);
+ } while (consume(','));
+
+ expect('do');
+ body = parseBlock();
+ expect('end');
+
+ return finishNode(ast.forGenericStatement(variables, iterators, body));
+ }
+ }
+
+ function parseLocalStatement() {
+ var name;
+
+ if (Identifier === token.type) {
+ var variables = []
+ , init = [];
+
+ do {
+ name = parseIdentifier();
+
+ variables.push(name);
+ } while (consume(','));
+
+ if (consume('=')) {
+ do {
+ var expression = parseExpectedExpression();
+ init.push(expression);
+ } while (consume(','));
+ }
+ if (options.scope) {
+ for (var i = 0, l = variables.length; i < l; i++) {
+ scopeIdentifier(variables[i]);
+ }
+ }
+
+ return finishNode(ast.localStatement(variables, init));
+ }
+ if (consume('function')) {
+ name = parseIdentifier();
+ if (options.scope) scopeIdentifier(name);
+ return parseFunctionDeclaration(name, true);
+ } else {
+ raiseUnexpectedToken('<name>', token);
+ }
+ }
+
+ function parseAssignmentOrCallStatement() {
+ var previous = token
+ , expression, marker;
+
+ if (trackLocations) marker = createLocationMarker();
+ expression = parsePrefixExpression();
+
+ if (null == expression) return unexpected(token);
+ if (',='.indexOf(token.value) >= 0) {
+ var variables = [expression]
+ , init = []
+ , exp;
+
+ while (consume(',')) {
+ exp = parsePrefixExpression();
+ if (null == exp) raiseUnexpectedToken('<expression>', token);
+ variables.push(exp);
+ }
+ expect('=');
+ do {
+ exp = parseExpectedExpression();
+ init.push(exp);
+ } while (consume(','));
+
+ pushLocation(marker);
+ return finishNode(ast.assignmentStatement(variables, init));
+ }
+ if (isCallExpression(expression)) {
+ pushLocation(marker);
+ return finishNode(ast.callStatement(expression));
+ }
+ return unexpected(previous);
+ }
+
+ function parseIdentifier() {
+ markLocation();
+ var identifier = token.value;
+ if (Identifier !== token.type) raiseUnexpectedToken('<name>', token);
+ next();
+ return finishNode(ast.identifier(identifier));
+ }
+
+ function parseFunctionDeclaration(name, isLocal) {
+ var parameters = [];
+ expect('(');
+ if (!consume(')')) {
+ while (true) {
+ if (Identifier === token.type) {
+ var parameter = parseIdentifier();
+ if (options.scope) scopeIdentifier(parameter);
+
+ parameters.push(parameter);
+
+ if (consume(',')) continue;
+ else if (consume(')')) break;
+ }
+ else if (VarargLiteral === token.type) {
+ parameters.push(parsePrimaryExpression());
+ expect(')');
+ break;
+ } else {
+ raiseUnexpectedToken('<name> or \'...\'', token);
+ }
+ }
+ }
+
+ var body = parseBlock();
+ expect('end');
+
+ isLocal = isLocal || false;
+ return finishNode(ast.functionStatement(name, parameters, isLocal, body));
+ }
+
+ function parseFunctionName() {
+ var base, name, marker;
+
+ if (trackLocations) marker = createLocationMarker();
+ base = parseIdentifier();
+
+ if (options.scope) attachScope(base, false);
+
+ while (consume('.')) {
+ pushLocation(marker);
+ name = parseIdentifier();
+ if (options.scope) attachScope(name, false);
+ base = finishNode(ast.memberExpression(base, '.', name));
+ }
+
+ if (consume(':')) {
+ pushLocation(marker);
+ name = parseIdentifier();
+ if (options.scope) attachScope(name, false);
+ base = finishNode(ast.memberExpression(base, ':', name));
+ }
+
+ return base;
+ }
+
+ function parseTableConstructor() {
+ var fields = []
+ , key, value;
+
+ while (true) {
+ markLocation();
+ if (Punctuator === token.type && consume('[')) {
+ key = parseExpectedExpression();
+ expect(']');
+ expect('=');
+ value = parseExpectedExpression();
+ fields.push(finishNode(ast.tableKey(key, value)));
+ } else if (Identifier === token.type) {
+ key = parseExpectedExpression();
+ if (consume('=')) {
+ value = parseExpectedExpression();
+ fields.push(finishNode(ast.tableKeyString(key, value)));
+ } else {
+ fields.push(finishNode(ast.tableValue(key)));
+ }
+ } else {
+ if (null == (value = parseExpression())) {
+ locations.pop();
+ break;
+ }
+ fields.push(finishNode(ast.tableValue(value)));
+ }
+ if (',;'.indexOf(token.value) >= 0) {
+ next();
+ continue;
+ }
+ if ('}' === token.value) break;
+ }
+ expect('}');
+ return finishNode(ast.tableConstructorExpression(fields));
+ }
+
+ function parseExpression() {
+ var expression = parseSubExpression(0);
+ return expression;
+ }
+
+ function parseExpectedExpression() {
+ var expression = parseExpression();
+ if (null == expression) raiseUnexpectedToken('<expression>', token);
+ else return expression;
+ }
+
+ function binaryPrecedence(operator) {
+ var charCode = operator.charCodeAt(0)
+ , length = operator.length;
+
+ if (1 === length) {
+ switch (charCode) {
+ case 94: return 10; // ^
+ case 42: case 47: case 37: return 7; // * / %
+ case 43: case 45: return 6; // + -
+ case 60: case 62: return 3; // < >
+ }
+ } else if (2 === length) {
+ switch (charCode) {
+ case 46: return 5; // ..
+ case 60: case 62: case 61: case 126: return 3; // <= >= == ~=
+ case 111: return 1; // or
+ }
+ } else if (97 === charCode && 'and' === operator) return 2;
+ return 0;
+ }
+
+ function parseSubExpression(minPrecedence) {
+ var operator = token.value
+ , expression, marker;
+
+ if (trackLocations) marker = createLocationMarker();
+ if (isUnary(token)) {
+ markLocation();
+ next();
+ var argument = parseSubExpression(8);
+ if (argument == null) raiseUnexpectedToken('<expression>', token);
+ expression = finishNode(ast.unaryExpression(operator, argument));
+ }
+ if (null == expression) {
+ expression = parsePrimaryExpression();
+ if (null == expression) {
+ expression = parsePrefixExpression();
+ }
+ }
+ if (null == expression) return null;
+
+ var precedence;
+ while (true) {
+ operator = token.value;
+
+ precedence = (Punctuator === token.type || Keyword === token.type) ?
+ binaryPrecedence(operator) : 0;
+
+ if (precedence === 0 || precedence <= minPrecedence) break;
+ if ('^' === operator || '..' === operator) precedence--;
+ next();
+ var right = parseSubExpression(precedence);
+ if (null == right) raiseUnexpectedToken('<expression>', token);
+ if (trackLocations) locations.push(marker);
+ expression = finishNode(ast.binaryExpression(operator, expression, right));
+
+ }
+ return expression;
+ }
+
+ function parsePrefixExpression() {
+ var base, name, marker
+ , isLocal;
+
+ if (trackLocations) marker = createLocationMarker();
+ if (Identifier === token.type) {
+ name = token.value;
+ base = parseIdentifier();
+ if (options.scope) attachScope(base, isLocal = scopeHasName(name));
+ } else if (consume('(')) {
+ base = parseExpectedExpression();
+ expect(')');
+ if (options.scope) isLocal = base.isLocal;
+ } else {
+ return null;
+ }
+ var expression, identifier;
+ while (true) {
+ if (Punctuator === token.type) {
+ switch (token.value) {
+ case '[':
+ pushLocation(marker);
+ next();
+ expression = parseExpectedExpression();
+ base = finishNode(ast.indexExpression(base, expression));
+ expect(']');
+ break;
+ case '.':
+ pushLocation(marker);
+ next();
+ identifier = parseIdentifier();
+ if (options.scope) attachScope(identifier, isLocal);
+ base = finishNode(ast.memberExpression(base, '.', identifier));
+ break;
+ case ':':
+ pushLocation(marker);
+ next();
+ identifier = parseIdentifier();
+ if (options.scope) attachScope(identifier, isLocal);
+ base = finishNode(ast.memberExpression(base, ':', identifier));
+ pushLocation(marker);
+ base = parseCallExpression(base);
+ break;
+ case '(': case '{': // args
+ pushLocation(marker);
+ base = parseCallExpression(base);
+ break;
+ default:
+ return base;
+ }
+ } else if (StringLiteral === token.type) {
+ pushLocation(marker);
+ base = parseCallExpression(base);
+ } else {
+ break;
+ }
+ }
+
+ return base;
+ }
+
+ function parseCallExpression(base) {
+ if (Punctuator === token.type) {
+ switch (token.value) {
+ case '(':
+ next();
+ var expressions = [];
+ var expression = parseExpression();
+ if (null != expression) expressions.push(expression);
+ while (consume(',')) {
+ expression = parseExpectedExpression();
+ expressions.push(expression);
+ }
+
+ expect(')');
+ return finishNode(ast.callExpression(base, expressions));
+
+ case '{':
+ markLocation();
+ next();
+ var table = parseTableConstructor();
+ return finishNode(ast.tableCallExpression(base, table));
+ }
+ } else if (StringLiteral === token.type) {
+ return finishNode(ast.stringCallExpression(base, parsePrimaryExpression()));
+ }
+
+ raiseUnexpectedToken('function arguments', token);
+ }
+
+ function parsePrimaryExpression() {
+ var literals = StringLiteral | NumericLiteral | BooleanLiteral | NilLiteral | VarargLiteral
+ , value = token.value
+ , type = token.type
+ , marker;
+
+ if (trackLocations) marker = createLocationMarker();
+
+ if (type & literals) {
+ pushLocation(marker);
+ var raw = input.slice(token.range[0], token.range[1]);
+ next();
+ return finishNode(ast.literal(type, value, raw));
+ } else if (Keyword === type && 'function' === value) {
+ pushLocation(marker);
+ next();
+ return parseFunctionDeclaration(null);
+ } else if (consume('{')) {
+ pushLocation(marker);
+ return parseTableConstructor();
+ }
+ }
+
+ exports.parse = parse;
+
+ function parse(_input, _options) {
+ if ('undefined' === typeof _options && 'object' === typeof _input) {
+ _options = _input;
+ _input = undefined;
+ }
+ if (!_options) _options = {};
+
+ input = _input || '';
+ options = extend(defaultOptions, _options);
+ index = 0;
+ line = 1;
+ lineStart = 0;
+ length = input.length;
+ scopes = [[]];
+ scopeDepth = 0;
+ globals = [];
+ locations = [];
+
+ if (options.comments) comments = [];
+ if (!options.wait) return end();
+ return exports;
+ }
+ exports.write = write;
+
+ function write(_input) {
+ input += String(_input);
+ length = input.length;
+ return exports;
+ }
+ exports.end = end;
+
+ function end(_input) {
+ if ('undefined' !== typeof _input) write(_input);
+
+ length = input.length;
+ trackLocations = options.locations || options.ranges;
+ lookahead = lex();
+
+ var chunk = parseChunk();
+ if (options.comments) chunk.comments = comments;
+ if (options.scope) chunk.globals = globals;
+
+ if (locations.length > 0)
+ throw new Error('Location tracking failed. This is most likely a bug in luaparse');
+
+ return chunk;
+ }
+
+}));
+
+});
+
+ace.define("ace/mode/lua_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/lua/luaparse"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var Mirror = require("../worker/mirror").Mirror;
+var luaparse = require("../mode/lua/luaparse");
+
+var Worker = exports.Worker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(500);
+};
+
+oop.inherits(Worker, Mirror);
+
+(function() {
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ var errors = [];
+ try {
+ luaparse.parse(value);
+ } catch(e) {
+ if (e instanceof SyntaxError) {
+ errors.push({
+ row: e.line - 1,
+ column: e.column,
+ text: e.message,
+ type: "error"
+ });
+ }
+ }
+ this.sender.emit("annotate", errors);
+ };
+
+}).call(Worker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-php.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-php.js
new file mode 100644
index 00000000..3752c846
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-php.js
@@ -0,0 +1,4302 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/php/php",["require","exports","module"], function(require, exports, module) {
+
+var PHP = {Constants:{}};
+
+PHP.Constants.T_INCLUDE = 257;
+PHP.Constants.T_INCLUDE_ONCE = 258;
+PHP.Constants.T_EVAL = 259;
+PHP.Constants.T_REQUIRE = 260;
+PHP.Constants.T_REQUIRE_ONCE = 261;
+PHP.Constants.T_LOGICAL_OR = 262;
+PHP.Constants.T_LOGICAL_XOR = 263;
+PHP.Constants.T_LOGICAL_AND = 264;
+PHP.Constants.T_PRINT = 265;
+PHP.Constants.T_YIELD = 266;
+PHP.Constants.T_DOUBLE_ARROW = 267;
+PHP.Constants.T_YIELD_FROM = 268;
+PHP.Constants.T_PLUS_EQUAL = 269;
+PHP.Constants.T_MINUS_EQUAL = 270;
+PHP.Constants.T_MUL_EQUAL = 271;
+PHP.Constants.T_DIV_EQUAL = 272;
+PHP.Constants.T_CONCAT_EQUAL = 273;
+PHP.Constants.T_MOD_EQUAL = 274;
+PHP.Constants.T_AND_EQUAL = 275;
+PHP.Constants.T_OR_EQUAL = 276;
+PHP.Constants.T_XOR_EQUAL = 277;
+PHP.Constants.T_SL_EQUAL = 278;
+PHP.Constants.T_SR_EQUAL = 279;
+PHP.Constants.T_POW_EQUAL = 280;
+PHP.Constants.T_COALESCE = 281;
+PHP.Constants.T_BOOLEAN_OR = 282;
+PHP.Constants.T_BOOLEAN_AND = 283;
+PHP.Constants.T_IS_EQUAL = 284;
+PHP.Constants.T_IS_NOT_EQUAL = 285;
+PHP.Constants.T_IS_IDENTICAL = 286;
+PHP.Constants.T_IS_NOT_IDENTICAL = 287;
+PHP.Constants.T_SPACESHIP = 288;
+PHP.Constants.T_IS_SMALLER_OR_EQUAL = 289;
+PHP.Constants.T_IS_GREATER_OR_EQUAL = 290;
+PHP.Constants.T_SL = 291;
+PHP.Constants.T_SR = 292;
+PHP.Constants.T_INSTANCEOF = 293;
+PHP.Constants.T_INC = 294;
+PHP.Constants.T_DEC = 295;
+PHP.Constants.T_INT_CAST = 296;
+PHP.Constants.T_DOUBLE_CAST = 297;
+PHP.Constants.T_STRING_CAST = 298;
+PHP.Constants.T_ARRAY_CAST = 299;
+PHP.Constants.T_OBJECT_CAST = 300;
+PHP.Constants.T_BOOL_CAST = 301;
+PHP.Constants.T_UNSET_CAST = 302;
+PHP.Constants.T_POW = 303;
+PHP.Constants.T_NEW = 304;
+PHP.Constants.T_CLONE = 305;
+PHP.Constants.T_EXIT = 306;
+PHP.Constants.T_IF = 307;
+PHP.Constants.T_ELSEIF = 308;
+PHP.Constants.T_ELSE = 309;
+PHP.Constants.T_ENDIF = 310;
+PHP.Constants.T_LNUMBER = 311;
+PHP.Constants.T_DNUMBER = 312;
+PHP.Constants.T_STRING = 313;
+PHP.Constants.T_STRING_VARNAME = 314;
+PHP.Constants.T_VARIABLE = 315;
+PHP.Constants.T_NUM_STRING = 316;
+PHP.Constants.T_INLINE_HTML = 317;
+PHP.Constants.T_CHARACTER = 318;
+PHP.Constants.T_BAD_CHARACTER = 319;
+PHP.Constants.T_ENCAPSED_AND_WHITESPACE = 320;
+PHP.Constants.T_CONSTANT_ENCAPSED_STRING = 321;
+PHP.Constants.T_ECHO = 322;
+PHP.Constants.T_DO = 323;
+PHP.Constants.T_WHILE = 324;
+PHP.Constants.T_ENDWHILE = 325;
+PHP.Constants.T_FOR = 326;
+PHP.Constants.T_ENDFOR = 327;
+PHP.Constants.T_FOREACH = 328;
+PHP.Constants.T_ENDFOREACH = 329;
+PHP.Constants.T_DECLARE = 330;
+PHP.Constants.T_ENDDECLARE = 331;
+PHP.Constants.T_AS = 332;
+PHP.Constants.T_SWITCH = 333;
+PHP.Constants.T_ENDSWITCH = 334;
+PHP.Constants.T_CASE = 335;
+PHP.Constants.T_DEFAULT = 336;
+PHP.Constants.T_BREAK = 337;
+PHP.Constants.T_CONTINUE = 338;
+PHP.Constants.T_GOTO = 339;
+PHP.Constants.T_FUNCTION = 340;
+PHP.Constants.T_CONST = 341;
+PHP.Constants.T_RETURN = 342;
+PHP.Constants.T_TRY = 343;
+PHP.Constants.T_CATCH = 344;
+PHP.Constants.T_FINALLY = 345;
+PHP.Constants.T_THROW = 346;
+PHP.Constants.T_USE = 347;
+PHP.Constants.T_INSTEADOF = 348;
+PHP.Constants.T_GLOBAL = 349;
+PHP.Constants.T_STATIC = 350;
+PHP.Constants.T_ABSTRACT = 351;
+PHP.Constants.T_FINAL = 352;
+PHP.Constants.T_PRIVATE = 353;
+PHP.Constants.T_PROTECTED = 354;
+PHP.Constants.T_PUBLIC = 355;
+PHP.Constants.T_VAR = 356;
+PHP.Constants.T_UNSET = 357;
+PHP.Constants.T_ISSET = 358;
+PHP.Constants.T_EMPTY = 359;
+PHP.Constants.T_HALT_COMPILER = 360;
+PHP.Constants.T_CLASS = 361;
+PHP.Constants.T_TRAIT = 362;
+PHP.Constants.T_INTERFACE = 363;
+PHP.Constants.T_EXTENDS = 364;
+PHP.Constants.T_IMPLEMENTS = 365;
+PHP.Constants.T_OBJECT_OPERATOR = 366;
+PHP.Constants.T_LIST = 367;
+PHP.Constants.T_ARRAY = 368;
+PHP.Constants.T_CALLABLE = 369;
+PHP.Constants.T_CLASS_C = 370;
+PHP.Constants.T_TRAIT_C = 371;
+PHP.Constants.T_METHOD_C = 372;
+PHP.Constants.T_FUNC_C = 373;
+PHP.Constants.T_LINE = 374;
+PHP.Constants.T_FILE = 375;
+PHP.Constants.T_COMMENT = 376;
+PHP.Constants.T_DOC_COMMENT = 377;
+PHP.Constants.T_OPEN_TAG = 378;
+PHP.Constants.T_OPEN_TAG_WITH_ECHO = 379;
+PHP.Constants.T_CLOSE_TAG = 380;
+PHP.Constants.T_WHITESPACE = 381;
+PHP.Constants.T_START_HEREDOC = 382;
+PHP.Constants.T_END_HEREDOC = 383;
+PHP.Constants.T_DOLLAR_OPEN_CURLY_BRACES = 384;
+PHP.Constants.T_CURLY_OPEN = 385;
+PHP.Constants.T_PAAMAYIM_NEKUDOTAYIM = 386;
+PHP.Constants.T_NAMESPACE = 387;
+PHP.Constants.T_NS_C = 388;
+PHP.Constants.T_DIR = 389;
+PHP.Constants.T_NS_SEPARATOR = 390;
+PHP.Constants.T_ELLIPSIS = 391;
+
+PHP.Lexer = function(src, ini) {
+ var heredoc, heredocEndAllowed,
+
+ stateStack = ['INITIAL'], stackPos = 0,
+ swapState = function(state) {
+ stateStack[stackPos] = state;
+ },
+ pushState = function(state) {
+ stateStack[++stackPos] = state;
+ },
+ popState = function() {
+ --stackPos;
+ },
+
+ shortOpenTag = ini === undefined || /^(on|true|1)$/i.test(ini.short_open_tag),
+ openTag = shortOpenTag
+ ? /^(\<\?php(?:\r\n|[ \t\r\n])|<\?|\<script language\=('|")?php('|")?\>)/i
+ : /^(\<\?php(?:\r\n|[ \t\r\n])|\<script language\=('|")?php('|")?\>)/i,
+ inlineHtml = shortOpenTag
+ ? /[^<]*(?:<(?!\?|script language\=('|")?php('|")?\>)[^<]*)*/i
+ : /[^<]*(?:<(?!\?=|\?php[ \t\r\n]|script language\=('|")?php('|")?\>)[^<]*)*/i;
+ labelRegexPart = '[a-zA-Z_\\x7f-\\uffff][a-zA-Z0-9_\\x7f-\\uffff]*',
+ stringRegexPart = function(quote) {
+ return '[^' + quote + '\\\\${]*(?:(?:\\\\[\\s\\S]|\\$(?!\\{|[a-zA-Z_\\x7f-\\uffff])|\\{(?!\\$))[^' + quote + '\\\\${]*)*';
+ },
+
+ sharedStringTokens = [
+ {
+ value: PHP.Constants.T_VARIABLE,
+ re: new RegExp('^\\$' + labelRegexPart + '(?=\\[)'),
+ func: function() {
+ pushState('VAR_OFFSET');
+ }
+ },
+ {
+ value: PHP.Constants.T_VARIABLE,
+ re: new RegExp('^\\$' + labelRegexPart + '(?=->' + labelRegexPart + ')'),
+ func: function() {
+ pushState('LOOKING_FOR_PROPERTY');
+ }
+ },
+ {
+ value: PHP.Constants.T_DOLLAR_OPEN_CURLY_BRACES,
+ re: new RegExp('^\\$\\{(?=' + labelRegexPart + '[\\[}])'),
+ func: function() {
+ pushState('LOOKING_FOR_VARNAME');
+ }
+ },
+ {
+ value: PHP.Constants.T_VARIABLE,
+ re: new RegExp('^\\$' + labelRegexPart)
+ },
+ {
+ value: PHP.Constants.T_DOLLAR_OPEN_CURLY_BRACES,
+ re: /^\$\{/,
+ func: function() {
+ pushState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_CURLY_OPEN,
+ re: /^\{(?=\$)/,
+ func: function() {
+ pushState('IN_SCRIPTING');
+ }
+ }
+ ],
+ data = {
+ 'INITIAL': [
+ {
+ value: PHP.Constants.T_OPEN_TAG_WITH_ECHO,
+ re: /^<\?=/i,
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_OPEN_TAG,
+ re: openTag,
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_INLINE_HTML,
+ re: inlineHtml
+ },
+ ],
+ 'IN_SCRIPTING': [
+ {
+ value: PHP.Constants.T_WHITESPACE,
+ re: /^[ \n\r\t]+/
+ },
+ {
+ value: PHP.Constants.T_ABSTRACT,
+ re: /^abstract\b/i
+ },
+ {
+ value: PHP.Constants.T_LOGICAL_AND,
+ re: /^and\b/i
+ },
+ {
+ value: PHP.Constants.T_ARRAY,
+ re: /^array\b/i
+ },
+ {
+ value: PHP.Constants.T_AS,
+ re: /^as\b/i
+ },
+ {
+ value: PHP.Constants.T_BREAK,
+ re: /^break\b/i
+ },
+ {
+ value: PHP.Constants.T_CALLABLE,
+ re: /^callable\b/i
+ },
+ {
+ value: PHP.Constants.T_CASE,
+ re: /^case\b/i
+ },
+ {
+ value: PHP.Constants.T_CATCH,
+ re: /^catch\b/i
+ },
+ {
+ value: PHP.Constants.T_CLASS,
+ re: /^class\b/i,
+ },
+ {
+ value: PHP.Constants.T_CLONE,
+ re: /^clone\b/i
+ },
+ {
+ value: PHP.Constants.T_CONST,
+ re: /^const\b/i
+ },
+ {
+ value: PHP.Constants.T_CONTINUE,
+ re: /^continue\b/i
+ },
+ {
+ value: PHP.Constants.T_DECLARE,
+ re: /^declare\b/i
+ },
+ {
+ value: PHP.Constants.T_DEFAULT,
+ re: /^default\b/i
+ },
+ {
+ value: PHP.Constants.T_DO,
+ re: /^do\b/i
+ },
+ {
+ value: PHP.Constants.T_ECHO,
+ re: /^echo\b/i
+ },
+ {
+ value: PHP.Constants.T_ELSE,
+ re: /^else\b/i
+ },
+ {
+ value: PHP.Constants.T_ELSEIF,
+ re: /^elseif\b/i
+ },
+ {
+ value: PHP.Constants.T_ENDDECLARE,
+ re: /^enddeclare\b/i
+ },
+ {
+ value: PHP.Constants.T_ENDFOR,
+ re: /^endfor\b/i
+ },
+ {
+ value: PHP.Constants.T_ENDFOREACH,
+ re: /^endforeach\b/i
+ },
+ {
+ value: PHP.Constants.T_ENDIF,
+ re: /^endif\b/i
+ },
+ {
+ value: PHP.Constants.T_ENDSWITCH,
+ re: /^endswitch\b/i
+ },
+ {
+ value: PHP.Constants.T_ENDWHILE,
+ re: /^endwhile\b/i
+ },
+ {
+ value: PHP.Constants.T_EMPTY,
+ re: /^empty\b/i
+ },
+ {
+ value: PHP.Constants.T_EVAL,
+ re: /^eval\b/i
+ },
+ {
+ value: PHP.Constants.T_EXIT,
+ re: /^(?:exit|die)\b/i
+ },
+ {
+ value: PHP.Constants.T_EXTENDS,
+ re: /^extends\b/i
+ },
+ {
+ value: PHP.Constants.T_FINAL,
+ re: /^final\b/i
+ },
+ {
+ value: PHP.Constants.T_FINALLY,
+ re: /^finally\b/i
+ },
+ {
+ value: PHP.Constants.T_FOR,
+ re: /^for\b/i
+ },
+ {
+ value: PHP.Constants.T_FOREACH,
+ re: /^foreach\b/i
+ },
+ {
+ value: PHP.Constants.T_FUNCTION,
+ re: /^function\b/i
+ },
+ {
+ value: PHP.Constants.T_GLOBAL,
+ re: /^global\b/i
+ },
+ {
+ value: PHP.Constants.T_GOTO,
+ re: /^goto\b/i
+ },
+ {
+ value: PHP.Constants.T_IF,
+ re: /^if\b/i
+ },
+ {
+ value: PHP.Constants.T_IMPLEMENTS,
+ re: /^implements\b/i
+ },
+ {
+ value: PHP.Constants.T_INCLUDE,
+ re: /^include\b/i
+ },
+ {
+ value: PHP.Constants.T_INCLUDE_ONCE,
+ re: /^include_once\b/i
+ },
+ {
+ value: PHP.Constants.T_INSTANCEOF,
+ re: /^instanceof\b/i
+ },
+ {
+ value: PHP.Constants.T_INSTEADOF,
+ re: /^insteadof\b/i
+ },
+ {
+ value: PHP.Constants.T_INTERFACE,
+ re: /^interface\b/i
+ },
+ {
+ value: PHP.Constants.T_ISSET,
+ re: /^isset\b/i
+ },
+ {
+ value: PHP.Constants.T_LIST,
+ re: /^list\b/i
+ },
+ {
+ value: PHP.Constants.T_NAMESPACE,
+ re: /^namespace\b/i
+ },
+ {
+ value: PHP.Constants.T_NEW,
+ re: /^new\b/i
+ },
+ {
+ value: PHP.Constants.T_LOGICAL_OR,
+ re: /^or\b/i
+ },
+ {
+ value: PHP.Constants.T_PRINT,
+ re: /^print\b/i
+ },
+ {
+ value: PHP.Constants.T_PRIVATE,
+ re: /^private\b/i
+ },
+ {
+ value: PHP.Constants.T_PROTECTED,
+ re: /^protected\b/i
+ },
+ {
+ value: PHP.Constants.T_PUBLIC,
+ re: /^public\b/i
+ },
+ {
+ value: PHP.Constants.T_REQUIRE,
+ re: /^require\b/i
+ },
+ {
+ value: PHP.Constants.T_REQUIRE_ONCE,
+ re: /^require_once\b/i
+ },
+ {
+ value: PHP.Constants.T_STATIC,
+ re: /^static\b/i
+ },
+ {
+ value: PHP.Constants.T_SWITCH,
+ re: /^switch\b/i
+ },
+ {
+ value: PHP.Constants.T_THROW,
+ re: /^throw\b/i
+ },
+ {
+ value: PHP.Constants.T_TRAIT,
+ re: /^trait\b/i,
+ },
+ {
+ value: PHP.Constants.T_TRY,
+ re: /^try\b/i
+ },
+ {
+ value: PHP.Constants.T_UNSET,
+ re: /^unset\b/i
+ },
+ {
+ value: PHP.Constants.T_USE,
+ re: /^use\b/i
+ },
+ {
+ value: PHP.Constants.T_VAR,
+ re: /^var\b/i
+ },
+ {
+ value: PHP.Constants.T_WHILE,
+ re: /^while\b/i
+ },
+ {
+ value: PHP.Constants.T_LOGICAL_XOR,
+ re: /^xor\b/i
+ },
+ {
+ value: PHP.Constants.T_YIELD_FROM,
+ re: /^yield\s+from\b/i
+ },
+ {
+ value: PHP.Constants.T_YIELD,
+ re: /^yield\b/i
+ },
+ {
+ value: PHP.Constants.T_RETURN,
+ re: /^return\b/i
+ },
+ {
+ value: PHP.Constants.T_METHOD_C,
+ re: /^__METHOD__\b/i
+ },
+ {
+ value: PHP.Constants.T_LINE,
+ re: /^__LINE__\b/i
+ },
+ {
+ value: PHP.Constants.T_FILE,
+ re: /^__FILE__\b/i
+ },
+ {
+ value: PHP.Constants.T_FUNC_C,
+ re: /^__FUNCTION__\b/i
+ },
+ {
+ value: PHP.Constants.T_NS_C,
+ re: /^__NAMESPACE__\b/i
+ },
+ {
+ value: PHP.Constants.T_TRAIT_C,
+ re: /^__TRAIT__\b/i
+ },
+ {
+ value: PHP.Constants.T_DIR,
+ re: /^__DIR__\b/i
+ },
+ {
+ value: PHP.Constants.T_CLASS_C,
+ re: /^__CLASS__\b/i
+ },
+ {
+ value: PHP.Constants.T_AND_EQUAL,
+ re: /^&=/
+ },
+ {
+ value: PHP.Constants.T_ARRAY_CAST,
+ re: /^\([ \t]*array[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_BOOL_CAST,
+ re: /^\([ \t]*(?:bool|boolean)[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_DOUBLE_CAST,
+ re: /^\([ \t]*(?:real|float|double)[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_INT_CAST,
+ re: /^\([ \t]*(?:int|integer)[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_OBJECT_CAST,
+ re: /^\([ \t]*object[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_STRING_CAST,
+ re: /^\([ \t]*(?:binary|string)[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_UNSET_CAST,
+ re: /^\([ \t]*unset[ \t]*\)/i
+ },
+ {
+ value: PHP.Constants.T_BOOLEAN_AND,
+ re: /^&&/
+ },
+ {
+ value: PHP.Constants.T_BOOLEAN_OR,
+ re: /^\|\|/
+ },
+ {
+ value: PHP.Constants.T_CLOSE_TAG,
+ re: /^(?:\?>|<\/script>)(\r\n|\r|\n)?/i,
+ func: function() {
+ swapState('INITIAL');
+ }
+ },
+ {
+ value: PHP.Constants.T_DOUBLE_ARROW,
+ re: /^=>/
+ },
+ {
+ value: PHP.Constants.T_PAAMAYIM_NEKUDOTAYIM,
+ re: /^::/
+ },
+ {
+ value: PHP.Constants.T_INC,
+ re: /^\+\+/
+ },
+ {
+ value: PHP.Constants.T_DEC,
+ re: /^--/
+ },
+ {
+ value: PHP.Constants.T_CONCAT_EQUAL,
+ re: /^\.=/
+ },
+ {
+ value: PHP.Constants.T_DIV_EQUAL,
+ re: /^\/=/
+ },
+ {
+ value: PHP.Constants.T_XOR_EQUAL,
+ re: /^\^=/
+ },
+ {
+ value: PHP.Constants.T_MUL_EQUAL,
+ re: /^\*=/
+ },
+ {
+ value: PHP.Constants.T_MOD_EQUAL,
+ re: /^%=/
+ },
+ {
+ value: PHP.Constants.T_SL_EQUAL,
+ re: /^<<=/
+ },
+ {
+ value: PHP.Constants.T_START_HEREDOC,
+ re: new RegExp('^[bB]?<<<[ \\t]*\'(' + labelRegexPart + ')\'(?:\\r\\n|\\r|\\n)'),
+ func: function(result) {
+ heredoc = result[1];
+ swapState('NOWDOC');
+ }
+ },
+ {
+ value: PHP.Constants.T_START_HEREDOC,
+ re: new RegExp('^[bB]?<<<[ \\t]*("?)(' + labelRegexPart + ')\\1(?:\\r\\n|\\r|\\n)'),
+ func: function(result) {
+ heredoc = result[2];
+ heredocEndAllowed = true;
+ swapState('HEREDOC');
+ }
+ },
+ {
+ value: PHP.Constants.T_SL,
+ re: /^<</
+ },
+ {
+ value: PHP.Constants.T_SPACESHIP,
+ re: /^<=>/
+ },
+ {
+ value: PHP.Constants.T_IS_SMALLER_OR_EQUAL,
+ re: /^<=/
+ },
+ {
+ value: PHP.Constants.T_SR_EQUAL,
+ re: /^>>=/
+ },
+ {
+ value: PHP.Constants.T_SR,
+ re: /^>>/
+ },
+ {
+ value: PHP.Constants.T_IS_GREATER_OR_EQUAL,
+ re: /^>=/
+ },
+ {
+ value: PHP.Constants.T_OR_EQUAL,
+ re: /^\|=/
+ },
+ {
+ value: PHP.Constants.T_PLUS_EQUAL,
+ re: /^\+=/
+ },
+ {
+ value: PHP.Constants.T_MINUS_EQUAL,
+ re: /^-=/
+ },
+ {
+ value: PHP.Constants.T_OBJECT_OPERATOR,
+ re: new RegExp('^->(?=[ \n\r\t]*' + labelRegexPart + ')'),
+ func: function() {
+ pushState('LOOKING_FOR_PROPERTY');
+ }
+ },
+ {
+ value: PHP.Constants.T_OBJECT_OPERATOR,
+ re: /^->/i
+ },
+ {
+ value: PHP.Constants.T_ELLIPSIS,
+ re: /^\.\.\./
+ },
+ {
+ value: PHP.Constants.T_POW_EQUAL,
+ re: /^\*\*=/
+ },
+ {
+ value: PHP.Constants.T_POW,
+ re: /^\*\*/
+ },
+ {
+ value: PHP.Constants.T_COALESCE,
+ re: /^\?\?/
+ },
+ {
+ value: PHP.Constants.T_COMMENT,
+ re: /^\/\*([\S\s]*?)(?:\*\/|$)/
+ },
+ {
+ value: PHP.Constants.T_COMMENT,
+ re: /^(?:\/\/|#)[^\r\n?]*(?:\?(?!>)[^\r\n?]*)*(?:\r\n|\r|\n)?/
+ },
+ {
+ value: PHP.Constants.T_IS_IDENTICAL,
+ re: /^===/
+ },
+ {
+ value: PHP.Constants.T_IS_EQUAL,
+ re: /^==/
+ },
+ {
+ value: PHP.Constants.T_IS_NOT_IDENTICAL,
+ re: /^!==/
+ },
+ {
+ value: PHP.Constants.T_IS_NOT_EQUAL,
+ re: /^(!=|<>)/
+ },
+ {
+ value: PHP.Constants.T_DNUMBER,
+ re: /^(?:[0-9]+\.[0-9]*|\.[0-9]+)(?:[eE][+-]?[0-9]+)?/
+ },
+ {
+ value: PHP.Constants.T_DNUMBER,
+ re: /^[0-9]+[eE][+-]?[0-9]+/
+ },
+ {
+ value: PHP.Constants.T_LNUMBER,
+ re: /^(?:0x[0-9A-F]+|0b[01]+|[0-9]+)/i
+ },
+ {
+ value: PHP.Constants.T_VARIABLE,
+ re: new RegExp('^\\$' + labelRegexPart)
+ },
+ {
+ value: PHP.Constants.T_CONSTANT_ENCAPSED_STRING,
+ re: /^[bB]?'[^'\\]*(?:\\[\s\S][^'\\]*)*'/,
+ },
+ {
+ value: PHP.Constants.T_CONSTANT_ENCAPSED_STRING,
+ re: new RegExp('^[bB]?"' + stringRegexPart('"') + '"')
+ },
+ {
+ value: -1,
+ re: /^[bB]?"/,
+ func: function() {
+ swapState('DOUBLE_QUOTES');
+ }
+ },
+ {
+ value: -1,
+ re: /^`/,
+ func: function() {
+ swapState('BACKTICKS');
+ }
+ },
+ {
+ value: PHP.Constants.T_NS_SEPARATOR,
+ re: /^\\/
+ },
+ {
+ value: PHP.Constants.T_STRING,
+ re: /^[a-zA-Z_\x7f-\uffff][a-zA-Z0-9_\x7f-\uffff]*/
+ },
+ {
+ value: -1,
+ re: /^\{/,
+ func: function() {
+ pushState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: -1,
+ re: /^\}/,
+ func: function() {
+ if (stackPos > 0) {
+ popState();
+ }
+ }
+ },
+ {
+ value: -1,
+ re: /^[\[\];:?()!.,><=+-/*|&@^%"'$~]/
+ }
+ ],
+ 'DOUBLE_QUOTES': sharedStringTokens.concat([
+ {
+ value: -1,
+ re: /^"/,
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_ENCAPSED_AND_WHITESPACE,
+ re: new RegExp('^' + stringRegexPart('"'))
+ }
+ ]),
+ 'BACKTICKS': sharedStringTokens.concat([
+ {
+ value: -1,
+ re: /^`/,
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_ENCAPSED_AND_WHITESPACE,
+ re: new RegExp('^' + stringRegexPart('`'))
+ }
+ ]),
+ 'VAR_OFFSET': [
+ {
+ value: -1,
+ re: /^\]/,
+ func: function() {
+ popState();
+ }
+ },
+ {
+ value: PHP.Constants.T_NUM_STRING,
+ re: /^(?:0x[0-9A-F]+|0b[01]+|[0-9]+)/i
+ },
+ {
+ value: PHP.Constants.T_VARIABLE,
+ re: new RegExp('^\\$' + labelRegexPart)
+ },
+ {
+ value: PHP.Constants.T_STRING,
+ re: new RegExp('^' + labelRegexPart)
+ },
+ {
+ value: -1,
+ re: /^[;:,.\[()|^&+-/*=%!~$<>?@{}"`]/
+ }
+ ],
+ 'LOOKING_FOR_PROPERTY': [
+ {
+ value: PHP.Constants.T_OBJECT_OPERATOR,
+ re: /^->/
+ },
+ {
+ value: PHP.Constants.T_STRING,
+ re: new RegExp('^' + labelRegexPart),
+ func: function() {
+ popState();
+ }
+ },
+ {
+ value: PHP.Constants.T_WHITESPACE,
+ re: /^[ \n\r\t]+/
+ }
+ ],
+ 'LOOKING_FOR_VARNAME': [
+ {
+ value: PHP.Constants.T_STRING_VARNAME,
+ re: new RegExp('^' + labelRegexPart + '(?=[\\[}])'),
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ }
+ ],
+ 'NOWDOC': [
+ {
+ value: PHP.Constants.T_END_HEREDOC,
+ matchFunc: function(src) {
+ var re = new RegExp('^' + heredoc + '(?=;?[\\r\\n])');
+ if (src.match(re)) {
+ return [src.substr(0, heredoc.length)];
+ } else {
+ return null;
+ }
+ },
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_ENCAPSED_AND_WHITESPACE,
+ matchFunc: function(src) {
+ var re = new RegExp('[\\r\\n]' + heredoc + '(?=;?[\\r\\n])');
+ var result = re.exec(src);
+ var end = result ? result.index + 1 : src.length;
+ return [src.substring(0, end)];
+ }
+ }
+ ],
+ 'HEREDOC': sharedStringTokens.concat([
+ {
+ value: PHP.Constants.T_END_HEREDOC,
+ matchFunc: function(src) {
+ if (!heredocEndAllowed) {
+ return null;
+ }
+ var re = new RegExp('^' + heredoc + '(?=;?[\\r\\n])');
+ if (src.match(re)) {
+ return [src.substr(0, heredoc.length)];
+ } else {
+ return null;
+ }
+ },
+ func: function() {
+ swapState('IN_SCRIPTING');
+ }
+ },
+ {
+ value: PHP.Constants.T_ENCAPSED_AND_WHITESPACE,
+ matchFunc: function(src) {
+ var end = src.length;
+ var re = new RegExp('^' + stringRegexPart(''));
+ var result = re.exec(src);
+ if (result) {
+ end = result[0].length;
+ }
+ re = new RegExp('([\\r\\n])' + heredoc + '(?=;?[\\r\\n])');
+ result = re.exec(src.substring(0, end));
+ if (result) {
+ end = result.index + 1;
+ heredocEndAllowed = true;
+ } else {
+ heredocEndAllowed = false;
+ }
+ if (end == 0) {
+ return null;
+ }
+ return [src.substring(0, end)];
+ }
+ }
+ ])
+ };
+
+ var results = [],
+ line = 1,
+ cancel = true;
+
+ if (src === null) {
+ return results;
+ }
+
+ if (typeof src !== "string") {
+ src = src.toString();
+ }
+
+ while (src.length > 0 && cancel === true) {
+ var state = stateStack[stackPos];
+ var tokens = data[state];
+ cancel = tokens.some(function(token){
+ var result = token.matchFunc !== undefined
+ ? token.matchFunc(src)
+ : src.match(token.re);
+ if (result !== null) {
+ if (result[0].length == 0) {
+ throw new Error("empty match");
+ }
+
+ if (token.func !== undefined) {
+ token.func(result);
+ }
+
+ if (token.value === -1) {
+ results.push(result[0]);
+ } else {
+ var resultString = result[0];
+ results.push([
+ parseInt(token.value, 10),
+ resultString,
+ line
+ ]);
+ line += resultString.split('\n').length - 1;
+ }
+
+ src = src.substring(result[0].length);
+
+ return true;
+ }
+ return false;
+ });
+ }
+
+ return results;
+};
+
+
+PHP.Parser = function ( preprocessedTokens, eval ) {
+
+ var yybase = this.yybase,
+ yydefault = this.yydefault,
+ yycheck = this.yycheck,
+ yyaction = this.yyaction,
+ yylen = this.yylen,
+ yygbase = this.yygbase,
+ yygcheck = this.yygcheck,
+ yyp = this.yyp,
+ yygoto = this.yygoto,
+ yylhs = this.yylhs,
+ terminals = this.terminals,
+ translate = this.translate,
+ yygdefault = this.yygdefault;
+
+
+ this.pos = -1;
+ this.line = 1;
+
+ this.tokenMap = this.createTokenMap( );
+
+ this.dropTokens = {};
+ this.dropTokens[ PHP.Constants.T_WHITESPACE ] = 1;
+ this.dropTokens[ PHP.Constants.T_OPEN_TAG ] = 1;
+ var tokens = [];
+ preprocessedTokens.forEach( function( token, index ) {
+ if ( typeof token === "object" && token[ 0 ] === PHP.Constants.T_OPEN_TAG_WITH_ECHO) {
+ tokens.push([
+ PHP.Constants.T_OPEN_TAG,
+ token[ 1 ],
+ token[ 2 ]
+ ]);
+ tokens.push([
+ PHP.Constants.T_ECHO,
+ token[ 1 ],
+ token[ 2 ]
+ ]);
+ } else {
+ tokens.push( token );
+ }
+ });
+ this.tokens = tokens;
+ var tokenId = this.TOKEN_NONE;
+ this.startAttributes = {
+ 'startLine': 1
+ };
+
+ this.endAttributes = {};
+ var attributeStack = [ this.startAttributes ];
+ var state = 0;
+ var stateStack = [ state ];
+ this.yyastk = [];
+ this.stackPos = 0;
+
+ var yyn;
+
+ var origTokenId;
+
+
+ for (;;) {
+
+ if ( yybase[ state ] === 0 ) {
+ yyn = yydefault[ state ];
+ } else {
+ if (tokenId === this.TOKEN_NONE ) {
+ origTokenId = this.getNextToken( );
+ tokenId = (origTokenId >= 0 && origTokenId < this.TOKEN_MAP_SIZE) ? translate[ origTokenId ] : this.TOKEN_INVALID;
+
+ attributeStack[ this.stackPos ] = this.startAttributes;
+ }
+
+ if (((yyn = yybase[ state ] + tokenId) >= 0
+ && yyn < this.YYLAST && yycheck[ yyn ] === tokenId
+ || (state < this.YY2TBLSTATE
+ && (yyn = yybase[state + this.YYNLSTATES] + tokenId) >= 0
+ && yyn < this.YYLAST
+ && yycheck[ yyn ] === tokenId))
+ && (yyn = yyaction[ yyn ]) !== this.YYDEFAULT ) {
+ if (yyn > 0) {
+ ++this.stackPos;
+
+ stateStack[ this.stackPos ] = state = yyn;
+ this.yyastk[ this.stackPos ] = this.tokenValue;
+ attributeStack[ this.stackPos ] = this.startAttributes;
+ tokenId = this.TOKEN_NONE;
+
+ if (yyn < this.YYNLSTATES)
+ continue;
+ yyn -= this.YYNLSTATES;
+ } else {
+ yyn = -yyn;
+ }
+ } else {
+ yyn = yydefault[ state ];
+ }
+ }
+
+ for (;;) {
+
+ if ( yyn === 0 ) {
+ return this.yyval;
+ } else if (yyn !== this.YYUNEXPECTED ) {
+ for (var attr in this.endAttributes) {
+ attributeStack[ this.stackPos - yylen[ yyn ] ][ attr ] = this.endAttributes[ attr ];
+ }
+ this.stackPos -= yylen[ yyn ];
+ yyn = yylhs[ yyn ];
+ if ((yyp = yygbase[ yyn ] + stateStack[ this.stackPos ]) >= 0
+ && yyp < this.YYGLAST
+ && yygcheck[ yyp ] === yyn) {
+ state = yygoto[ yyp ];
+ } else {
+ state = yygdefault[ yyn ];
+ }
+
+ ++this.stackPos;
+
+ stateStack[ this.stackPos ] = state;
+ this.yyastk[ this.stackPos ] = this.yyval;
+ attributeStack[ this.stackPos ] = this.startAttributes;
+ } else {
+ if (eval !== true) {
+
+ var expected = [];
+
+ for (var i = 0; i < this.TOKEN_MAP_SIZE; ++i) {
+ if ((yyn = yybase[ state ] + i) >= 0 && yyn < this.YYLAST && yycheck[ yyn ] == i
+ || state < this.YY2TBLSTATE
+ && (yyn = yybase[ state + this.YYNLSTATES] + i)
+ && yyn < this.YYLAST && yycheck[ yyn ] == i
+ ) {
+ if (yyaction[ yyn ] != this.YYUNEXPECTED) {
+ if (expected.length == 4) {
+ expected = [];
+ break;
+ }
+
+ expected.push( this.terminals[ i ] );
+ }
+ }
+ }
+
+ var expectedString = '';
+ if (expected.length) {
+ expectedString = ', expecting ' + expected.join(' or ');
+ }
+ throw new PHP.ParseError('syntax error, unexpected ' + terminals[ tokenId ] + expectedString, this.startAttributes['startLine']);
+ } else {
+ return this.startAttributes['startLine'];
+ }
+
+ }
+
+ if (state < this.YYNLSTATES)
+ break;
+ yyn = state - this.YYNLSTATES;
+ }
+ }
+};
+
+PHP.ParseError = function( msg, line ) {
+ this.message = msg;
+ this.line = line;
+};
+
+PHP.Parser.prototype.getNextToken = function( ) {
+
+ this.startAttributes = {};
+ this.endAttributes = {};
+
+ var token,
+ tmp;
+
+ while (this.tokens[++this.pos] !== undefined) {
+ token = this.tokens[this.pos];
+
+ if (typeof token === "string") {
+ this.startAttributes['startLine'] = this.line;
+ this.endAttributes['endLine'] = this.line;
+ if ('b"' === token) {
+ this.tokenValue = 'b"';
+ return '"'.charCodeAt(0);
+ } else {
+ this.tokenValue = token;
+ return token.charCodeAt(0);
+ }
+ } else {
+
+
+
+ this.line += ((tmp = token[ 1 ].match(/\n/g)) === null) ? 0 : tmp.length;
+
+ if (PHP.Constants.T_COMMENT === token[0]) {
+
+ if (!Array.isArray(this.startAttributes['comments'])) {
+ this.startAttributes['comments'] = [];
+ }
+
+ this.startAttributes['comments'].push( {
+ type: "comment",
+ comment: token[1],
+ line: token[2]
+ });
+
+ } else if (PHP.Constants.T_DOC_COMMENT === token[0]) {
+ this.startAttributes['comments'].push( new PHPParser_Comment_Doc(token[1], token[2]) );
+ } else if (this.dropTokens[token[0]] === undefined) {
+ this.tokenValue = token[1];
+ this.startAttributes['startLine'] = token[2];
+ this.endAttributes['endLine'] = this.line;
+
+ return this.tokenMap[token[0]];
+ }
+ }
+ }
+
+ this.startAttributes['startLine'] = this.line;
+ return 0;
+};
+
+PHP.Parser.prototype.tokenName = function( token ) {
+ var constants = ["T_INCLUDE","T_INCLUDE_ONCE","T_EVAL","T_REQUIRE","T_REQUIRE_ONCE","T_LOGICAL_OR","T_LOGICAL_XOR","T_LOGICAL_AND","T_PRINT","T_YIELD","T_DOUBLE_ARROW","T_YIELD_FROM","T_PLUS_EQUAL","T_MINUS_EQUAL","T_MUL_EQUAL","T_DIV_EQUAL","T_CONCAT_EQUAL","T_MOD_EQUAL","T_AND_EQUAL","T_OR_EQUAL","T_XOR_EQUAL","T_SL_EQUAL","T_SR_EQUAL","T_POW_EQUAL","T_COALESCE","T_BOOLEAN_OR","T_BOOLEAN_AND","T_IS_EQUAL","T_IS_NOT_EQUAL","T_IS_IDENTICAL","T_IS_NOT_IDENTICAL","T_SPACESHIP","T_IS_SMALLER_OR_EQUAL","T_IS_GREATER_OR_EQUAL","T_SL","T_SR","T_INSTANCEOF","T_INC","T_DEC","T_INT_CAST","T_DOUBLE_CAST","T_STRING_CAST","T_ARRAY_CAST","T_OBJECT_CAST","T_BOOL_CAST","T_UNSET_CAST","T_POW","T_NEW","T_CLONE","T_EXIT","T_IF","T_ELSEIF","T_ELSE","T_ENDIF","T_LNUMBER","T_DNUMBER","T_STRING","T_STRING_VARNAME","T_VARIABLE","T_NUM_STRING","T_INLINE_HTML","T_CHARACTER","T_BAD_CHARACTER","T_ENCAPSED_AND_WHITESPACE","T_CONSTANT_ENCAPSED_STRING","T_ECHO","T_DO","T_WHILE","T_ENDWHILE","T_FOR","T_ENDFOR","T_FOREACH","T_ENDFOREACH","T_DECLARE","T_ENDDECLARE","T_AS","T_SWITCH","T_ENDSWITCH","T_CASE","T_DEFAULT","T_BREAK","T_CONTINUE","T_GOTO","T_FUNCTION","T_CONST","T_RETURN","T_TRY","T_CATCH","T_FINALLY","T_THROW","T_USE","T_INSTEADOF","T_GLOBAL","T_STATIC","T_ABSTRACT","T_FINAL","T_PRIVATE","T_PROTECTED","T_PUBLIC","T_VAR","T_UNSET","T_ISSET","T_EMPTY","T_HALT_COMPILER","T_CLASS","T_TRAIT","T_INTERFACE","T_EXTENDS","T_IMPLEMENTS","T_OBJECT_OPERATOR","T_DOUBLE_ARROW","T_LIST","T_ARRAY","T_CALLABLE","T_CLASS_C","T_TRAIT_C","T_METHOD_C","T_FUNC_C","T_LINE","T_FILE","T_COMMENT","T_DOC_COMMENT","T_OPEN_TAG","T_OPEN_TAG_WITH_ECHO","T_CLOSE_TAG","T_WHITESPACE","T_START_HEREDOC","T_END_HEREDOC","T_DOLLAR_OPEN_CURLY_BRACES","T_CURLY_OPEN","T_PAAMAYIM_NEKUDOTAYIM","T_NAMESPACE","T_NS_C","T_DIR","T_NS_SEPARATOR","T_ELLIPSIS"];
+ var current = "UNKNOWN";
+ constants.some(function( constant ) {
+ if (PHP.Constants[ constant ] === token) {
+ current = constant;
+ return true;
+ } else {
+ return false;
+ }
+ });
+
+ return current;
+};
+
+PHP.Parser.prototype.createTokenMap = function() {
+ var tokenMap = {},
+ name,
+ i;
+ for ( i = 256; i < 1000; ++i ) {
+ if( PHP.Constants.T_OPEN_TAG_WITH_ECHO === i ) {
+ tokenMap[ i ] = PHP.Constants.T_ECHO;
+ } else if( PHP.Constants.T_CLOSE_TAG === i ) {
+ tokenMap[ i ] = 59;
+ } else if ( 'UNKNOWN' !== (name = this.tokenName( i ) ) ) {
+ tokenMap[ i ] = this[name];
+ }
+ }
+ return tokenMap;
+};
+
+PHP.Parser.prototype.TOKEN_NONE = -1;
+PHP.Parser.prototype.TOKEN_INVALID = 157;
+
+PHP.Parser.prototype.TOKEN_MAP_SIZE = 392;
+
+PHP.Parser.prototype.YYLAST = 889;
+PHP.Parser.prototype.YY2TBLSTATE = 337;
+PHP.Parser.prototype.YYGLAST = 410;
+PHP.Parser.prototype.YYNLSTATES = 564;
+PHP.Parser.prototype.YYUNEXPECTED = 32767;
+PHP.Parser.prototype.YYDEFAULT = -32766;
+PHP.Parser.prototype.YYERRTOK = 256;
+PHP.Parser.prototype.T_INCLUDE = 257;
+PHP.Parser.prototype.T_INCLUDE_ONCE = 258;
+PHP.Parser.prototype.T_EVAL = 259;
+PHP.Parser.prototype.T_REQUIRE = 260;
+PHP.Parser.prototype.T_REQUIRE_ONCE = 261;
+PHP.Parser.prototype.T_LOGICAL_OR = 262;
+PHP.Parser.prototype.T_LOGICAL_XOR = 263;
+PHP.Parser.prototype.T_LOGICAL_AND = 264;
+PHP.Parser.prototype.T_PRINT = 265;
+PHP.Parser.prototype.T_YIELD = 266;
+PHP.Parser.prototype.T_DOUBLE_ARROW = 267;
+PHP.Parser.prototype.T_YIELD_FROM = 268;
+PHP.Parser.prototype.T_PLUS_EQUAL = 269;
+PHP.Parser.prototype.T_MINUS_EQUAL = 270;
+PHP.Parser.prototype.T_MUL_EQUAL = 271;
+PHP.Parser.prototype.T_DIV_EQUAL = 272;
+PHP.Parser.prototype.T_CONCAT_EQUAL = 273;
+PHP.Parser.prototype.T_MOD_EQUAL = 274;
+PHP.Parser.prototype.T_AND_EQUAL = 275;
+PHP.Parser.prototype.T_OR_EQUAL = 276;
+PHP.Parser.prototype.T_XOR_EQUAL = 277;
+PHP.Parser.prototype.T_SL_EQUAL = 278;
+PHP.Parser.prototype.T_SR_EQUAL = 279;
+PHP.Parser.prototype.T_POW_EQUAL = 280;
+PHP.Parser.prototype.T_COALESCE = 281;
+PHP.Parser.prototype.T_BOOLEAN_OR = 282;
+PHP.Parser.prototype.T_BOOLEAN_AND = 283;
+PHP.Parser.prototype.T_IS_EQUAL = 284;
+PHP.Parser.prototype.T_IS_NOT_EQUAL = 285;
+PHP.Parser.prototype.T_IS_IDENTICAL = 286;
+PHP.Parser.prototype.T_IS_NOT_IDENTICAL = 287;
+PHP.Parser.prototype.T_SPACESHIP = 288;
+PHP.Parser.prototype.T_IS_SMALLER_OR_EQUAL = 289;
+PHP.Parser.prototype.T_IS_GREATER_OR_EQUAL = 290;
+PHP.Parser.prototype.T_SL = 291;
+PHP.Parser.prototype.T_SR = 292;
+PHP.Parser.prototype.T_INSTANCEOF = 293;
+PHP.Parser.prototype.T_INC = 294;
+PHP.Parser.prototype.T_DEC = 295;
+PHP.Parser.prototype.T_INT_CAST = 296;
+PHP.Parser.prototype.T_DOUBLE_CAST = 297;
+PHP.Parser.prototype.T_STRING_CAST = 298;
+PHP.Parser.prototype.T_ARRAY_CAST = 299;
+PHP.Parser.prototype.T_OBJECT_CAST = 300;
+PHP.Parser.prototype.T_BOOL_CAST = 301;
+PHP.Parser.prototype.T_UNSET_CAST = 302;
+PHP.Parser.prototype.T_POW = 303;
+PHP.Parser.prototype.T_NEW = 304;
+PHP.Parser.prototype.T_CLONE = 305;
+PHP.Parser.prototype.T_EXIT = 306;
+PHP.Parser.prototype.T_IF = 307;
+PHP.Parser.prototype.T_ELSEIF = 308;
+PHP.Parser.prototype.T_ELSE = 309;
+PHP.Parser.prototype.T_ENDIF = 310;
+PHP.Parser.prototype.T_LNUMBER = 311;
+PHP.Parser.prototype.T_DNUMBER = 312;
+PHP.Parser.prototype.T_STRING = 313;
+PHP.Parser.prototype.T_STRING_VARNAME = 314;
+PHP.Parser.prototype.T_VARIABLE = 315;
+PHP.Parser.prototype.T_NUM_STRING = 316;
+PHP.Parser.prototype.T_INLINE_HTML = 317;
+PHP.Parser.prototype.T_CHARACTER = 318;
+PHP.Parser.prototype.T_BAD_CHARACTER = 319;
+PHP.Parser.prototype.T_ENCAPSED_AND_WHITESPACE = 320;
+PHP.Parser.prototype.T_CONSTANT_ENCAPSED_STRING = 321;
+PHP.Parser.prototype.T_ECHO = 322;
+PHP.Parser.prototype.T_DO = 323;
+PHP.Parser.prototype.T_WHILE = 324;
+PHP.Parser.prototype.T_ENDWHILE = 325;
+PHP.Parser.prototype.T_FOR = 326;
+PHP.Parser.prototype.T_ENDFOR = 327;
+PHP.Parser.prototype.T_FOREACH = 328;
+PHP.Parser.prototype.T_ENDFOREACH = 329;
+PHP.Parser.prototype.T_DECLARE = 330;
+PHP.Parser.prototype.T_ENDDECLARE = 331;
+PHP.Parser.prototype.T_AS = 332;
+PHP.Parser.prototype.T_SWITCH = 333;
+PHP.Parser.prototype.T_ENDSWITCH = 334;
+PHP.Parser.prototype.T_CASE = 335;
+PHP.Parser.prototype.T_DEFAULT = 336;
+PHP.Parser.prototype.T_BREAK = 337;
+PHP.Parser.prototype.T_CONTINUE = 338;
+PHP.Parser.prototype.T_GOTO = 339;
+PHP.Parser.prototype.T_FUNCTION = 340;
+PHP.Parser.prototype.T_CONST = 341;
+PHP.Parser.prototype.T_RETURN = 342;
+PHP.Parser.prototype.T_TRY = 343;
+PHP.Parser.prototype.T_CATCH = 344;
+PHP.Parser.prototype.T_FINALLY = 345;
+PHP.Parser.prototype.T_THROW = 346;
+PHP.Parser.prototype.T_USE = 347;
+PHP.Parser.prototype.T_INSTEADOF = 348;
+PHP.Parser.prototype.T_GLOBAL = 349;
+PHP.Parser.prototype.T_STATIC = 350;
+PHP.Parser.prototype.T_ABSTRACT = 351;
+PHP.Parser.prototype.T_FINAL = 352;
+PHP.Parser.prototype.T_PRIVATE = 353;
+PHP.Parser.prototype.T_PROTECTED = 354;
+PHP.Parser.prototype.T_PUBLIC = 355;
+PHP.Parser.prototype.T_VAR = 356;
+PHP.Parser.prototype.T_UNSET = 357;
+PHP.Parser.prototype.T_ISSET = 358;
+PHP.Parser.prototype.T_EMPTY = 359;
+PHP.Parser.prototype.T_HALT_COMPILER = 360;
+PHP.Parser.prototype.T_CLASS = 361;
+PHP.Parser.prototype.T_TRAIT = 362;
+PHP.Parser.prototype.T_INTERFACE = 363;
+PHP.Parser.prototype.T_EXTENDS = 364;
+PHP.Parser.prototype.T_IMPLEMENTS = 365;
+PHP.Parser.prototype.T_OBJECT_OPERATOR = 366;
+PHP.Parser.prototype.T_LIST = 367;
+PHP.Parser.prototype.T_ARRAY = 368;
+PHP.Parser.prototype.T_CALLABLE = 369;
+PHP.Parser.prototype.T_CLASS_C = 370;
+PHP.Parser.prototype.T_TRAIT_C = 371;
+PHP.Parser.prototype.T_METHOD_C = 372;
+PHP.Parser.prototype.T_FUNC_C = 373;
+PHP.Parser.prototype.T_LINE = 374;
+PHP.Parser.prototype.T_FILE = 375;
+PHP.Parser.prototype.T_COMMENT = 376;
+PHP.Parser.prototype.T_DOC_COMMENT = 377;
+PHP.Parser.prototype.T_OPEN_TAG = 378;
+PHP.Parser.prototype.T_OPEN_TAG_WITH_ECHO = 379;
+PHP.Parser.prototype.T_CLOSE_TAG = 380;
+PHP.Parser.prototype.T_WHITESPACE = 381;
+PHP.Parser.prototype.T_START_HEREDOC = 382;
+PHP.Parser.prototype.T_END_HEREDOC = 383;
+PHP.Parser.prototype.T_DOLLAR_OPEN_CURLY_BRACES = 384;
+PHP.Parser.prototype.T_CURLY_OPEN = 385;
+PHP.Parser.prototype.T_PAAMAYIM_NEKUDOTAYIM = 386;
+PHP.Parser.prototype.T_NAMESPACE = 387;
+PHP.Parser.prototype.T_NS_C = 388;
+PHP.Parser.prototype.T_DIR = 389;
+PHP.Parser.prototype.T_NS_SEPARATOR = 390;
+PHP.Parser.prototype.T_ELLIPSIS = 391;
+PHP.Parser.prototype.terminals = [
+ "$EOF",
+ "error",
+ "T_INCLUDE",
+ "T_INCLUDE_ONCE",
+ "T_EVAL",
+ "T_REQUIRE",
+ "T_REQUIRE_ONCE",
+ "','",
+ "T_LOGICAL_OR",
+ "T_LOGICAL_XOR",
+ "T_LOGICAL_AND",
+ "T_PRINT",
+ "T_YIELD",
+ "T_DOUBLE_ARROW",
+ "T_YIELD_FROM",
+ "'='",
+ "T_PLUS_EQUAL",
+ "T_MINUS_EQUAL",
+ "T_MUL_EQUAL",
+ "T_DIV_EQUAL",
+ "T_CONCAT_EQUAL",
+ "T_MOD_EQUAL",
+ "T_AND_EQUAL",
+ "T_OR_EQUAL",
+ "T_XOR_EQUAL",
+ "T_SL_EQUAL",
+ "T_SR_EQUAL",
+ "T_POW_EQUAL",
+ "'?'",
+ "':'",
+ "T_COALESCE",
+ "T_BOOLEAN_OR",
+ "T_BOOLEAN_AND",
+ "'|'",
+ "'^'",
+ "'&'",
+ "T_IS_EQUAL",
+ "T_IS_NOT_EQUAL",
+ "T_IS_IDENTICAL",
+ "T_IS_NOT_IDENTICAL",
+ "T_SPACESHIP",
+ "'<'",
+ "T_IS_SMALLER_OR_EQUAL",
+ "'>'",
+ "T_IS_GREATER_OR_EQUAL",
+ "T_SL",
+ "T_SR",
+ "'+'",
+ "'-'",
+ "'.'",
+ "'*'",
+ "'/'",
+ "'%'",
+ "'!'",
+ "T_INSTANCEOF",
+ "'~'",
+ "T_INC",
+ "T_DEC",
+ "T_INT_CAST",
+ "T_DOUBLE_CAST",
+ "T_STRING_CAST",
+ "T_ARRAY_CAST",
+ "T_OBJECT_CAST",
+ "T_BOOL_CAST",
+ "T_UNSET_CAST",
+ "'@'",
+ "T_POW",
+ "'['",
+ "T_NEW",
+ "T_CLONE",
+ "T_EXIT",
+ "T_IF",
+ "T_ELSEIF",
+ "T_ELSE",
+ "T_ENDIF",
+ "T_LNUMBER",
+ "T_DNUMBER",
+ "T_STRING",
+ "T_STRING_VARNAME",
+ "T_VARIABLE",
+ "T_NUM_STRING",
+ "T_INLINE_HTML",
+ "T_ENCAPSED_AND_WHITESPACE",
+ "T_CONSTANT_ENCAPSED_STRING",
+ "T_ECHO",
+ "T_DO",
+ "T_WHILE",
+ "T_ENDWHILE",
+ "T_FOR",
+ "T_ENDFOR",
+ "T_FOREACH",
+ "T_ENDFOREACH",
+ "T_DECLARE",
+ "T_ENDDECLARE",
+ "T_AS",
+ "T_SWITCH",
+ "T_ENDSWITCH",
+ "T_CASE",
+ "T_DEFAULT",
+ "T_BREAK",
+ "T_CONTINUE",
+ "T_GOTO",
+ "T_FUNCTION",
+ "T_CONST",
+ "T_RETURN",
+ "T_TRY",
+ "T_CATCH",
+ "T_FINALLY",
+ "T_THROW",
+ "T_USE",
+ "T_INSTEADOF",
+ "T_GLOBAL",
+ "T_STATIC",
+ "T_ABSTRACT",
+ "T_FINAL",
+ "T_PRIVATE",
+ "T_PROTECTED",
+ "T_PUBLIC",
+ "T_VAR",
+ "T_UNSET",
+ "T_ISSET",
+ "T_EMPTY",
+ "T_HALT_COMPILER",
+ "T_CLASS",
+ "T_TRAIT",
+ "T_INTERFACE",
+ "T_EXTENDS",
+ "T_IMPLEMENTS",
+ "T_OBJECT_OPERATOR",
+ "T_LIST",
+ "T_ARRAY",
+ "T_CALLABLE",
+ "T_CLASS_C",
+ "T_TRAIT_C",
+ "T_METHOD_C",
+ "T_FUNC_C",
+ "T_LINE",
+ "T_FILE",
+ "T_START_HEREDOC",
+ "T_END_HEREDOC",
+ "T_DOLLAR_OPEN_CURLY_BRACES",
+ "T_CURLY_OPEN",
+ "T_PAAMAYIM_NEKUDOTAYIM",
+ "T_NAMESPACE",
+ "T_NS_C",
+ "T_DIR",
+ "T_NS_SEPARATOR",
+ "T_ELLIPSIS",
+ "';'",
+ "'{'",
+ "'}'",
+ "'('",
+ "')'",
+ "'`'",
+ "']'",
+ "'\"'",
+ "'$'"
+ , "???"
+];
+PHP.Parser.prototype.translate = [
+ 0, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 53, 155, 157, 156, 52, 35, 157,
+ 151, 152, 50, 47, 7, 48, 49, 51, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 29, 148,
+ 41, 15, 43, 28, 65, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 67, 157, 154, 34, 157, 153, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 149, 33, 150, 55, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 157, 157, 157, 157,
+ 157, 157, 157, 157, 157, 157, 1, 2, 3, 4,
+ 5, 6, 8, 9, 10, 11, 12, 13, 14, 16,
+ 17, 18, 19, 20, 21, 22, 23, 24, 25, 26,
+ 27, 30, 31, 32, 36, 37, 38, 39, 40, 42,
+ 44, 45, 46, 54, 56, 57, 58, 59, 60, 61,
+ 62, 63, 64, 66, 68, 69, 70, 71, 72, 73,
+ 74, 75, 76, 77, 78, 79, 80, 81, 157, 157,
+ 82, 83, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 116, 117, 118, 119, 120, 121,
+ 122, 123, 124, 125, 126, 127, 128, 129, 130, 131,
+ 132, 133, 134, 135, 136, 137, 157, 157, 157, 157,
+ 157, 157, 138, 139, 140, 141, 142, 143, 144, 145,
+ 146, 147
+];
+
+PHP.Parser.prototype.yyaction = [
+ 569, 570, 571, 572, 573, 215, 574, 575, 576, 612,
+ 613, 0, 27, 99, 100, 101, 102, 103, 104, 105,
+ 106, 107, 108, 109, 110,-32766,-32766,-32766, 95, 96,
+ 97, 24, 240, 226, -267,-32766,-32766,-32766,-32766,-32766,
+ -32766, 530, 344, 114, 98,-32766, 286,-32766,-32766,-32766,
+ -32766,-32766, 577, 870, 872,-32766,-32766,-32766,-32766,-32766,
+ -32766,-32766,-32766, 224,-32766, 714, 578, 579, 580, 581,
+ 582, 583, 584,-32766, 264, 644, 840, 841, 842, 839,
+ 838, 837, 585, 586, 587, 588, 589, 590, 591, 592,
+ 593, 594, 595, 615, 616, 617, 618, 619, 607, 608,
+ 609, 610, 611, 596, 597, 598, 599, 600, 601, 602,
+ 638, 639, 640, 641, 642, 643, 603, 604, 605, 606,
+ 636, 627, 625, 626, 622, 623, 116, 614, 620, 621,
+ 628, 629, 631, 630, 632, 633, 42, 43, 381, 44,
+ 45, 624, 635, 634, -214, 46, 47, 289, 48,-32767,
+ -32767,-32767,-32767, 90, 91, 92, 93, 94, 267, 241,
+ 22, 840, 841, 842, 839, 838, 837, 832,-32766,-32766,
+ -32766, 306, 1000, 1000, 1037, 120, 966, 436, -423, 244,
+ 797, 49, 50, 660, 661, 272, 362, 51,-32766, 52,
+ 219, 220, 53, 54, 55, 56, 57, 58, 59, 60,
+ 1016, 22, 238, 61, 351, 945,-32766,-32766,-32766, 967,
+ 968, 646, 705, 1000, 28, -456, 125, 966,-32766,-32766,
+ -32766, 715, 398, 399, 216, 1000,-32766, 339,-32766,-32766,
+ -32766,-32766, 25, 222, 980, 552, 355, 378,-32766, -423,
+ -32766,-32766,-32766, 121, 65, 1045, 408, 1047, 1046, 274,
+ 274, 131, 244, -423, 394, 395, 358, 519, 945, 537,
+ -423, 111, -426, 398, 399, 130, 972, 973, 974, 975,
+ 969, 970, 243, 128, -422, -421, 1013, 409, 976, 971,
+ 353, 791, 792, 7, -162, 63, 124, 255, 701, 256,
+ 274, 382, -122, -122, -122, -4, 715, 383, 646, 1042,
+ -421, 704, 274, -219, 33, 17, 384, -122, 385, -122,
+ 386, -122, 387, -122, 369, 388, -122, -122, -122, 34,
+ 35, 389, 352, 520, 36, 390, 353, 702, 62, 112,
+ 818, 287, 288, 391, 392, -422, -421, -161, 350, 393,
+ 40, 38, 690, 735, 396, 397, 361, 22, 122, -422,
+ -421,-32766,-32766,-32766, 791, 792, -422, -421, -425, 1000,
+ -456, -421, -238, 966, 409, 41, 382, 353, 717, 535,
+ -122,-32766, 383,-32766,-32766, -421, 704, 21, 813, 33,
+ 17, 384, -421, 385, -466, 386, 224, 387, -467, 273,
+ 388, 367, 945, -458, 34, 35, 389, 352, 345, 36,
+ 390, 248, 247, 62, 254, 715, 287, 288, 391, 392,
+ 399,-32766,-32766,-32766, 393, 295, 1000, 652, 735, 396,
+ 397, 117, 115, 113, 814, 119, 72, 73, 74, -162,
+ 764, 65, 240, 541, 370, 518, 274, 118, 270, 92,
+ 93, 94, 242, 717, 535, -4, 26, 1000, 75, 76,
+ 77, 78, 79, 80, 81, 82, 83, 84, 85, 86,
+ 87, 88, 89, 90, 91, 92, 93, 94, 95, 96,
+ 97, 547, 240, 713, 715, 382, 276,-32766,-32766, 126,
+ 945, 383, -161, 938, 98, 704, 225, 659, 33, 17,
+ 384, 346, 385, 274, 386, 728, 387, 221, 120, 388,
+ 505, 506, 540, 34, 35, 389, 715, -238, 36, 390,
+ 1017, 223, 62, 494, 18, 287, 288, 127, 297, 376,
+ 6, 98, 798, 393, 274, 660, 661, 490, 491, -466,
+ 39, -466, 514, -467, 539, -467, 16, 458, -458, 315,
+ 791, 792, 829, 553, 382, 817, 563, 653, 538, 765,
+ 383, 449, 751, 535, 704, 448, 435, 33, 17, 384,
+ 430, 385, 646, 386, 359, 387, 357, 647, 388, 673,
+ 429, 1040, 34, 35, 389, 715, 382, 36, 390, 941,
+ 492, 62, 383, 503, 287, 288, 704, 434, 440, 33,
+ 17, 384, 393, 385,-32766, 386, 445, 387, 495, 509,
+ 388, 10, 529, 542, 34, 35, 389, 715, 515, 36,
+ 390, 499, 500, 62, 214, -80, 287, 288, 452, 269,
+ 736, 717, 535, 488, 393, 356, 266, 979, 265, 730,
+ 982, 722, 358, 338, 493, 548, 0, 294, 737, 0,
+ 3, 0, 309, 0, 0, 382, 0, 0, 271, 0,
+ 0, 383, 0, 717, 535, 704, 227, 0, 33, 17,
+ 384, 9, 385, 0, 386, 0, 387, -382, 0, 388,
+ 0, 0, 325, 34, 35, 389, 715, 382, 36, 390,
+ 321, 341, 62, 383, 340, 287, 288, 704, 22, 320,
+ 33, 17, 384, 393, 385, 442, 386, 337, 387, 562,
+ 1000, 388, 32, 31, 966, 34, 35, 389, 823, 657,
+ 36, 390, 656, 821, 62, 703, 711, 287, 288, 561,
+ 822, 825, 717, 535, 695, 393, 747, 749, 693, 759,
+ 758, 752, 767, 945, 824, 706, 700, 712, 699, 698,
+ 658, 0, 263, 262, 559, 558, 382, 556, 554, 551,
+ 398, 399, 383, 550, 717, 535, 704, 546, 545, 33,
+ 17, 384, 543, 385, 536, 386, 71, 387, 933, 932,
+ 388, 30, 65, 731, 34, 35, 389, 274, 724, 36,
+ 390, 830, 734, 62, 663, 662, 287, 288,-32766,-32766,
+ -32766, 733, 732, 934, 393, 665, 664, 756, 555, 691,
+ 1041, 1001, 994, 1006, 1011, 1014, 757, 1043,-32766, 654,
+ -32766,-32766,-32766,-32766,-32766,-32766,-32767,-32767,-32767,-32767,
+ -32767, 655, 1044, 717, 535, -446, 926, 348, 343, 268,
+ 237, 236, 235, 234, 218, 217, 132, 129, -426, -425,
+ -424, 123, 20, 23, 70, 69, 29, 37, 64, 68,
+ 66, 67, -448, 0, 15, 19, 250, 910, 296, -217,
+ 467, 484, 909, 472, 528, 913, 11, 964, 955, -215,
+ 525, 379, 375, 373, 371, 14, 13, 12, -214, 0,
+ -393, 0, 1005, 1039, 992, 993, 963, 0, 981
+];
+
+PHP.Parser.prototype.yycheck = [
+ 2, 3, 4, 5, 6, 13, 8, 9, 10, 11,
+ 12, 0, 15, 16, 17, 18, 19, 20, 21, 22,
+ 23, 24, 25, 26, 27, 8, 9, 10, 50, 51,
+ 52, 7, 54, 7, 79, 8, 9, 10, 8, 9,
+ 10, 77, 7, 13, 66, 28, 7, 30, 31, 32,
+ 33, 34, 54, 56, 57, 28, 8, 30, 31, 32,
+ 33, 34, 35, 35, 109, 1, 68, 69, 70, 71,
+ 72, 73, 74, 118, 7, 77, 112, 113, 114, 115,
+ 116, 117, 84, 85, 86, 87, 88, 89, 90, 91,
+ 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+ 112, 113, 114, 115, 116, 117, 118, 119, 120, 121,
+ 122, 123, 124, 125, 126, 127, 7, 129, 130, 131,
+ 132, 133, 134, 135, 136, 137, 2, 3, 4, 5,
+ 6, 143, 144, 145, 152, 11, 12, 7, 14, 41,
+ 42, 43, 44, 45, 46, 47, 48, 49, 109, 7,
+ 67, 112, 113, 114, 115, 116, 117, 118, 8, 9,
+ 10, 79, 79, 79, 82, 147, 83, 82, 67, 28,
+ 152, 47, 48, 102, 103, 7, 7, 53, 28, 55,
+ 56, 57, 58, 59, 60, 61, 62, 63, 64, 65,
+ 1, 67, 68, 69, 70, 112, 8, 9, 10, 75,
+ 76, 77, 148, 79, 13, 7, 67, 83, 8, 9,
+ 10, 1, 129, 130, 13, 79, 28, 146, 30, 31,
+ 32, 33, 140, 141, 139, 29, 102, 7, 28, 128,
+ 30, 31, 32, 149, 151, 77, 112, 79, 80, 156,
+ 156, 15, 28, 142, 120, 121, 146, 77, 112, 149,
+ 149, 15, 151, 129, 130, 15, 132, 133, 134, 135,
+ 136, 137, 138, 15, 67, 67, 77, 143, 144, 145,
+ 146, 130, 131, 7, 7, 151, 15, 153, 148, 155,
+ 156, 71, 72, 73, 74, 0, 1, 77, 77, 150,
+ 67, 81, 156, 152, 84, 85, 86, 87, 88, 89,
+ 90, 91, 92, 93, 29, 95, 96, 97, 98, 99,
+ 100, 101, 102, 143, 104, 105, 146, 148, 108, 15,
+ 150, 111, 112, 113, 114, 128, 128, 7, 7, 119,
+ 67, 67, 122, 123, 124, 125, 7, 67, 149, 142,
+ 142, 8, 9, 10, 130, 131, 149, 149, 151, 79,
+ 152, 128, 7, 83, 143, 7, 71, 146, 148, 149,
+ 150, 28, 77, 30, 31, 142, 81, 7, 148, 84,
+ 85, 86, 149, 88, 7, 90, 35, 92, 7, 33,
+ 95, 7, 112, 7, 99, 100, 101, 102, 103, 104,
+ 105, 128, 128, 108, 109, 1, 111, 112, 113, 114,
+ 130, 8, 9, 10, 119, 142, 79, 122, 123, 124,
+ 125, 15, 149, 149, 148, 29, 8, 9, 10, 152,
+ 29, 151, 54, 29, 149, 79, 156, 15, 143, 47,
+ 48, 49, 29, 148, 149, 150, 28, 79, 30, 31,
+ 32, 33, 34, 35, 36, 37, 38, 39, 40, 41,
+ 42, 43, 44, 45, 46, 47, 48, 49, 50, 51,
+ 52, 29, 54, 29, 1, 71, 67, 8, 9, 29,
+ 112, 77, 152, 152, 66, 81, 35, 148, 84, 85,
+ 86, 123, 88, 156, 90, 35, 92, 35, 147, 95,
+ 72, 73, 29, 99, 100, 101, 1, 152, 104, 105,
+ 152, 35, 108, 72, 73, 111, 112, 97, 98, 102,
+ 103, 66, 152, 119, 156, 102, 103, 106, 107, 152,
+ 67, 154, 74, 152, 29, 154, 152, 128, 152, 78,
+ 130, 131, 148, 149, 71, 148, 149, 148, 149, 148,
+ 77, 77, 148, 149, 81, 77, 77, 84, 85, 86,
+ 77, 88, 77, 90, 77, 92, 77, 77, 95, 77,
+ 77, 77, 99, 100, 101, 1, 71, 104, 105, 79,
+ 79, 108, 77, 79, 111, 112, 81, 79, 82, 84,
+ 85, 86, 119, 88, 82, 90, 86, 92, 87, 96,
+ 95, 94, 89, 29, 99, 100, 101, 1, 91, 104,
+ 105, 93, 96, 108, 94, 94, 111, 112, 94, 110,
+ 123, 148, 149, 109, 119, 102, 127, 139, 126, 147,
+ 139, 150, 146, 149, 154, 29, -1, 142, 123, -1,
+ 142, -1, 146, -1, -1, 71, -1, -1, 126, -1,
+ -1, 77, -1, 148, 149, 81, 35, -1, 84, 85,
+ 86, 142, 88, -1, 90, -1, 92, 142, -1, 95,
+ -1, -1, 146, 99, 100, 101, 1, 71, 104, 105,
+ 146, 146, 108, 77, 146, 111, 112, 81, 67, 146,
+ 84, 85, 86, 119, 88, 146, 90, 149, 92, 148,
+ 79, 95, 148, 148, 83, 99, 100, 101, 148, 148,
+ 104, 105, 148, 148, 108, 148, 148, 111, 112, 148,
+ 148, 148, 148, 149, 148, 119, 148, 148, 148, 148,
+ 148, 148, 148, 112, 148, 148, 148, 148, 148, 148,
+ 148, -1, 149, 149, 149, 149, 71, 149, 149, 149,
+ 129, 130, 77, 149, 148, 149, 81, 149, 149, 84,
+ 85, 86, 149, 88, 149, 90, 149, 92, 150, 150,
+ 95, 151, 151, 150, 99, 100, 101, 156, 150, 104,
+ 105, 150, 150, 108, 150, 150, 111, 112, 8, 9,
+ 10, 150, 150, 150, 119, 150, 150, 150, 150, 150,
+ 150, 150, 150, 150, 150, 150, 150, 150, 28, 150,
+ 30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
+ 40, 150, 150, 148, 149, 151, 153, 151, 151, 151,
+ 151, 151, 151, 151, 151, 151, 151, 151, 151, 151,
+ 151, 151, 151, 151, 151, 151, 151, 151, 151, 151,
+ 151, 151, 151, -1, 152, 152, 152, 152, 152, 152,
+ 152, 152, 152, 152, 152, 152, 152, 152, 152, 152,
+ 152, 152, 152, 152, 152, 152, 152, 152, 152, -1,
+ 153, -1, 154, 154, 154, 154, 154, -1, 155
+];
+
+PHP.Parser.prototype.yybase = [
+ 0, 220, 295, 94, 180, 560, -2, -2, -2, -2,
+ -36, 473, 574, 606, 574, 505, 404, 675, 675, 675,
+ 28, 351, 462, 462, 462, 461, 396, 476, 451, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 401, 64, 201, 568, 704, 713, 708,
+ 702, 714, 520, 706, 705, 211, 650, 651, 450, 652,
+ 653, 654, 655, 709, 480, 703, 712, 418, 418, 418,
+ 418, 418, 418, 418, 418, 418, 418, 418, 418, 418,
+ 418, 418, 418, 48, 30, 469, 403, 403, 403, 403,
+ 403, 403, 403, 403, 403, 403, 403, 403, 403, 403,
+ 403, 403, 403, 403, 403, 160, 160, 160, 343, 210,
+ 208, 198, 17, 233, 27, 780, 780, 780, 780, 780,
+ 108, 108, 108, 108, 621, 621, 93, 280, 280, 280,
+ 280, 280, 280, 280, 280, 280, 280, 280, 632, 641,
+ 642, 643, 392, 392, 151, 151, 151, 151, 368, -45,
+ 146, 224, 224, 95, 410, 491, 733, 199, 199, 111,
+ 207, -22, -22, -22, 81, 506, 92, 92, 233, 233,
+ 273, 233, 423, 423, 423, 221, 221, 221, 221, 221,
+ 110, 221, 221, 221, 617, 512, 168, 516, 647, 397,
+ 503, 656, 274, 381, 377, 538, 535, 337, 523, 337,
+ 421, 441, 428, 525, 337, 337, 285, 401, 394, 378,
+ 567, 474, 339, 564, 140, 179, 409, 399, 384, 594,
+ 561, 711, 330, 710, 358, 149, 378, 378, 378, 370,
+ 593, 548, 355, -8, 646, 484, 277, 417, 386, 645,
+ 635, 230, 634, 276, 331, 356, 565, 485, 485, 485,
+ 485, 485, 485, 460, 485, 483, 691, 691, 478, 501,
+ 460, 696, 460, 485, 691, 460, 460, 502, 485, 522,
+ 522, 483, 508, 499, 691, 691, 499, 478, 460, 571,
+ 551, 514, 482, 413, 413, 514, 460, 413, 501, 413,
+ 11, 697, 699, 444, 700, 695, 698, 676, 694, 493,
+ 615, 497, 515, 684, 683, 693, 479, 489, 620, 692,
+ 549, 592, 487, 246, 314, 498, 463, 689, 523, 486,
+ 455, 455, 455, 463, 687, 455, 455, 455, 455, 455,
+ 455, 455, 455, 732, 24, 495, 510, 591, 590, 589,
+ 406, 588, 496, 524, 422, 599, 488, 549, 549, 649,
+ 727, 673, 490, 682, 716, 690, 555, 119, 271, 681,
+ 648, 543, 492, 534, 680, 598, 246, 715, 494, 672,
+ 549, 671, 455, 674, 701, 730, 731, 688, 728, 722,
+ 152, 526, 587, 178, 729, 659, 596, 595, 554, 725,
+ 707, 721, 720, 178, 576, 511, 717, 518, 677, 504,
+ 678, 613, 258, 657, 686, 584, 724, 723, 726, 583,
+ 582, 609, 608, 250, 236, 685, 442, 458, 517, 581,
+ 500, 628, 604, 679, 580, 579, 623, 619, 718, 521,
+ 486, 519, 509, 507, 513, 600, 618, 719, 206, 578,
+ 586, 573, 481, 572, 631, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 134, 134, -2, -2, -2,
+ 0, 0, 0, 0, -2, 134, 134, 134, 134, 134,
+ 134, 134, 134, 134, 134, 134, 134, 134, 134, 134,
+ 134, 134, 134, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 418, 418, 418,
+ 418, 418, 418, 418, 418, 418, 418, 418, 418, 418,
+ 418, 418, 418, 418, 418, 418, 418, 418, 418, 418,
+ 418, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 418, 418, 418,
+ 418, 418, 418, 418, 418, 418, 418, 418, 418, 418,
+ 418, 418, 418, 418, 418, 418, 418, 418, 418, 418,
+ 418, 418, 418, 418, -3, 418, 418, -3, 418, 418,
+ 418, 418, 418, 418, -22, -22, -22, -22, 221, 221,
+ 221, 221, 221, 221, 221, 221, 221, 221, 221, 221,
+ 221, 221, 49, 49, 49, 49, -22, -22, 221, 221,
+ 221, 221, 221, 49, 221, 221, 221, 92, 221, 92,
+ 92, 337, 337, 0, 0, 0, 0, 0, 485, 92,
+ 0, 0, 0, 0, 0, 0, 485, 485, 485, 0,
+ 0, 0, 0, 0, 485, 0, 0, 0, 337, 92,
+ 0, 420, 420, 178, 420, 420, 0, 0, 0, 485,
+ 485, 0, 508, 0, 0, 0, 0, 691, 0, 0,
+ 0, 0, 0, 455, 119, 682, 0, 39, 0, 0,
+ 0, 0, 0, 490, 39, 26, 0, 26, 0, 0,
+ 455, 455, 455, 0, 490, 490, 0, 0, 67, 490,
+ 0, 0, 0, 67, 35, 0, 35, 0, 0, 0,
+ 178
+];
+
+PHP.Parser.prototype.yydefault = [
+ 3,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767, 468, 468, 468,32767,32767,32767,32767, 285,
+ 460, 285, 285,32767, 419, 419, 419, 419, 419, 419,
+ 419, 460,32767,32767,32767,32767,32767, 364,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767, 465,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767, 347, 348, 350,
+ 351, 284, 420, 237, 464, 283, 116, 246, 239, 191,
+ 282, 223, 119, 312, 365, 314, 363, 367, 313, 290,
+ 294, 295, 296, 297, 298, 299, 300, 301, 302, 303,
+ 304, 305, 288, 289, 366, 344, 343, 342, 310, 311,
+ 287, 315, 317, 287, 316, 333, 334, 331, 332, 335,
+ 336, 337, 338, 339,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767, 269, 269,
+ 269, 269, 324, 325, 229, 229, 229, 229,32767, 270,
+ 32767, 229,32767,32767,32767,32767,32767,32767,32767, 413,
+ 341, 319, 320, 318,32767, 392,32767, 394, 307, 309,
+ 387, 291,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767, 389, 421, 421,32767,32767,32767, 381,32767,
+ 159, 210, 212, 397,32767,32767,32767,32767,32767, 329,
+ 32767,32767,32767,32767,32767,32767, 474,32767,32767,32767,
+ 32767,32767, 421,32767,32767,32767, 321, 322, 323,32767,
+ 32767,32767, 421, 421,32767,32767, 421,32767, 421,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767, 163,32767,32767, 395, 395,32767,32767,
+ 163, 390, 163,32767,32767, 163, 163, 176,32767, 174,
+ 174,32767,32767, 178,32767, 435, 178,32767, 163, 196,
+ 196, 373, 165, 231, 231, 373, 163, 231,32767, 231,
+ 32767,32767,32767, 82,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
+ 383,32767,32767,32767, 401,32767, 414, 433, 381,32767,
+ 327, 328, 330,32767, 423, 352, 353, 354, 355, 356,
+ 357, 358, 360,32767, 461, 386,32767,32767,32767,32767,
+ 32767,32767, 84, 108, 245,32767, 473, 84, 384,32767,
+ 473,32767,32767,32767,32767,32767,32767, 286,32767,32767,
+ 32767, 84,32767, 84,32767,32767, 457,32767,32767, 421,
+ 385,32767, 326, 398, 439,32767,32767, 422,32767,32767,
+ 218, 84,32767, 177,32767,32767,32767,32767,32767,32767,
+ 401,32767,32767, 179,32767,32767, 421,32767,32767,32767,
+ 32767,32767, 281,32767,32767,32767,32767,32767, 421,32767,
+ 32767,32767,32767, 222,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767,32767,32767,32767,32767, 82,
+ 60,32767, 263,32767,32767,32767,32767,32767,32767,32767,
+ 32767,32767,32767,32767,32767, 121, 121, 3, 3, 121,
+ 121, 121, 121, 121, 121, 121, 121, 121, 121, 121,
+ 121, 121, 121, 121, 248, 154, 248, 204, 248, 248,
+ 207, 196, 196, 255
+];
+
+PHP.Parser.prototype.yygoto = [
+ 163, 163, 135, 135, 135, 146, 148, 179, 164, 161,
+ 145, 161, 161, 161, 162, 162, 162, 162, 162, 162,
+ 162, 145, 157, 158, 159, 160, 176, 174, 177, 410,
+ 411, 299, 412, 415, 416, 417, 418, 419, 420, 421,
+ 422, 857, 136, 137, 138, 139, 140, 141, 142, 143,
+ 144, 147, 173, 175, 178, 195, 198, 199, 201, 202,
+ 204, 205, 206, 207, 208, 209, 210, 211, 212, 213,
+ 232, 233, 251, 252, 253, 316, 317, 318, 462, 180,
+ 181, 182, 183, 184, 185, 186, 187, 188, 189, 190,
+ 191, 192, 193, 149, 194, 150, 165, 166, 167, 196,
+ 168, 151, 152, 153, 169, 154, 197, 133, 170, 155,
+ 171, 172, 156, 521, 200, 257, 246, 464, 432, 687,
+ 649, 278, 481, 482, 527, 200, 437, 437, 437, 766,
+ 5, 746, 650, 557, 437, 426, 775, 770, 428, 431,
+ 444, 465, 466, 468, 483, 279, 651, 336, 450, 453,
+ 437, 560, 485, 487, 508, 511, 763, 516, 517, 777,
+ 524, 762, 526, 532, 773, 534, 480, 480, 965, 965,
+ 965, 965, 965, 965, 965, 965, 965, 965, 965, 965,
+ 413, 413, 413, 413, 413, 413, 413, 413, 413, 413,
+ 413, 413, 413, 413, 942, 502, 478, 496, 512, 456,
+ 298, 437, 437, 451, 471, 437, 437, 674, 437, 229,
+ 456, 230, 231, 463, 828, 533, 681, 438, 513, 826,
+ 461, 475, 460, 414, 414, 414, 414, 414, 414, 414,
+ 414, 414, 414, 414, 414, 414, 414, 301, 674, 674,
+ 443, 454, 1033, 1033, 1034, 1034, 425, 531, 425, 708,
+ 750, 800, 457, 372, 1033, 943, 1034, 1026, 300, 1018,
+ 497, 8, 313, 904, 796, 944, 996, 785, 789, 1007,
+ 285, 670, 1036, 329, 307, 310, 804, 668, 544, 332,
+ 935, 940, 366, 807, 678, 477, 377, 754, 844, 0,
+ 667, 667, 675, 675, 675, 677, 0, 666, 323, 498,
+ 328, 312, 312, 258, 259, 283, 459, 261, 322, 284,
+ 326, 486, 280, 281, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 790, 790, 790, 790, 946, 0, 946,
+ 790, 790, 1004, 790, 1004, 0, 0, 0, 0, 836,
+ 0, 1015, 1015, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 744, 744, 744, 720, 744, 0,
+ 739, 745, 721, 780, 780, 1023, 0, 0, 1002, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 806, 0, 806, 0, 0, 0, 0, 1008, 1009
+];
+
+PHP.Parser.prototype.yygcheck = [
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 52, 45, 112, 112, 80, 8, 10,
+ 10, 64, 55, 55, 55, 45, 8, 8, 8, 10,
+ 92, 10, 11, 10, 8, 10, 10, 10, 38, 38,
+ 38, 38, 38, 38, 62, 62, 12, 62, 28, 8,
+ 8, 28, 28, 28, 28, 28, 28, 28, 28, 28,
+ 28, 28, 28, 28, 28, 28, 70, 70, 70, 70,
+ 70, 70, 70, 70, 70, 70, 70, 70, 70, 70,
+ 113, 113, 113, 113, 113, 113, 113, 113, 113, 113,
+ 113, 113, 113, 113, 76, 56, 35, 35, 56, 69,
+ 56, 8, 8, 8, 8, 8, 8, 19, 8, 60,
+ 69, 60, 60, 7, 7, 7, 25, 8, 7, 7,
+ 2, 2, 8, 115, 115, 115, 115, 115, 115, 115,
+ 115, 115, 115, 115, 115, 115, 115, 53, 19, 19,
+ 53, 53, 123, 123, 124, 124, 109, 5, 109, 44,
+ 29, 78, 114, 53, 123, 76, 124, 122, 41, 120,
+ 43, 53, 42, 96, 74, 76, 76, 72, 75, 117,
+ 14, 21, 123, 18, 9, 13, 79, 20, 66, 17,
+ 102, 104, 58, 81, 22, 59, 100, 63, 94, -1,
+ 19, 19, 19, 19, 19, 19, -1, 19, 45, 45,
+ 45, 45, 45, 45, 45, 45, 45, 45, 45, 45,
+ 45, 45, 64, 64, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 52, 52, 52, 52, 52, -1, 52,
+ 52, 52, 80, 52, 80, -1, -1, -1, -1, 92,
+ -1, 80, 80, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 52, 52, 52, 52, 52, -1,
+ 52, 52, 52, 69, 69, 69, -1, -1, 80, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 80, -1, 80, -1, -1, -1, -1, 80, 80
+];
+
+PHP.Parser.prototype.yygbase = [
+ 0, 0, -317, 0, 0, 237, 0, 210, -136, 4,
+ 118, 130, 144, -10, 16, 0, 0, -59, 10, -47,
+ -9, 7, -77, -20, 0, 209, 0, 0, -388, 234,
+ 0, 0, 0, 0, 0, 165, 0, 0, 103, 0,
+ 0, 225, 44, 45, 235, 84, 0, 0, 0, 0,
+ 0, 0, 109, -115, 0, -113, -179, 0, -78, -81,
+ -347, 0, -122, -80, -249, 0, -19, 0, 0, 169,
+ -48, 0, 26, 0, 22, 24, -99, 0, 230, -13,
+ 114, -79, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 120, 0, -90, 0, 23, 0, 0, 0,
+ -89, 0, -67, 0, -69, 0, 0, 0, 0, 8,
+ 0, 0, -140, -34, 229, 9, 0, 21, 0, 0,
+ 218, 0, 233, -3, -1, 0
+];
+
+PHP.Parser.prototype.yygdefault = [
+ -32768, 380, 565, 2, 566, 637, 645, 504, 400, 433,
+ 748, 688, 689, 303, 342, 401, 302, 330, 324, 676,
+ 669, 671, 679, 134, 333, 682, 1, 684, 439, 716,
+ 291, 692, 292, 507, 694, 446, 696, 697, 427, 304,
+ 305, 447, 311, 479, 707, 203, 308, 709, 290, 710,
+ 719, 335, 293, 510, 489, 469, 501, 402, 363, 476,
+ 228, 455, 473, 753, 277, 761, 549, 769, 772, 403,
+ 404, 470, 784, 368, 794, 788, 960, 319, 799, 805,
+ 991, 808, 811, 349, 331, 327, 815, 816, 4, 820,
+ 522, 523, 835, 239, 843, 856, 347, 923, 925, 441,
+ 374, 936, 360, 334, 939, 995, 354, 405, 364, 952,
+ 260, 282, 245, 406, 423, 249, 407, 365, 998, 314,
+ 1019, 424, 1027, 1035, 275, 474
+];
+
+PHP.Parser.prototype.yylhs = [
+ 0, 1, 3, 3, 2, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 6, 6, 6, 6, 6, 6, 6,
+ 7, 7, 8, 8, 9, 4, 4, 4, 4, 4,
+ 4, 4, 4, 4, 4, 4, 14, 14, 15, 15,
+ 15, 15, 17, 17, 13, 13, 18, 18, 19, 19,
+ 20, 20, 21, 21, 16, 16, 22, 24, 24, 25,
+ 26, 26, 28, 27, 27, 27, 27, 29, 29, 29,
+ 29, 29, 29, 29, 29, 29, 29, 29, 29, 29,
+ 29, 29, 29, 29, 29, 29, 29, 29, 29, 29,
+ 29, 29, 10, 10, 48, 48, 51, 51, 50, 49,
+ 49, 42, 42, 53, 53, 54, 54, 11, 12, 12,
+ 12, 57, 57, 57, 58, 58, 61, 61, 59, 59,
+ 62, 62, 36, 36, 44, 44, 47, 47, 47, 46,
+ 46, 63, 37, 37, 37, 37, 64, 64, 65, 65,
+ 66, 66, 34, 34, 30, 30, 67, 32, 32, 68,
+ 31, 31, 33, 33, 43, 43, 43, 43, 55, 55,
+ 71, 71, 72, 72, 74, 74, 75, 75, 75, 73,
+ 73, 56, 56, 76, 76, 77, 77, 78, 78, 78,
+ 39, 39, 79, 40, 40, 81, 81, 60, 60, 82,
+ 82, 82, 82, 87, 87, 88, 88, 89, 89, 89,
+ 89, 89, 90, 91, 91, 86, 86, 83, 83, 85,
+ 85, 93, 93, 92, 92, 92, 92, 92, 92, 84,
+ 84, 94, 94, 41, 41, 35, 35, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 101, 95, 95, 100, 100, 103, 103, 104, 105, 105,
+ 105, 109, 109, 52, 52, 52, 96, 96, 107, 107,
+ 97, 97, 99, 99, 99, 102, 102, 113, 113, 70,
+ 115, 115, 115, 98, 98, 98, 98, 98, 98, 98,
+ 98, 98, 98, 98, 98, 98, 98, 98, 98, 38,
+ 38, 111, 111, 111, 106, 106, 106, 116, 116, 116,
+ 116, 116, 116, 45, 45, 45, 80, 80, 80, 118,
+ 110, 110, 110, 110, 110, 110, 108, 108, 108, 117,
+ 117, 117, 117, 69, 119, 119, 120, 120, 120, 120,
+ 120, 114, 121, 121, 122, 122, 122, 122, 122, 112,
+ 112, 112, 112, 124, 123, 123, 123, 123, 123, 123,
+ 123, 125, 125, 125
+];
+
+PHP.Parser.prototype.yylen = [
+ 1, 1, 2, 0, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 3, 1, 1, 1, 1, 1, 3,
+ 5, 4, 3, 4, 2, 3, 1, 1, 7, 8,
+ 6, 7, 3, 1, 3, 1, 3, 1, 1, 3,
+ 1, 2, 1, 2, 3, 1, 3, 3, 1, 3,
+ 2, 0, 1, 1, 1, 1, 1, 3, 7, 10,
+ 5, 7, 9, 5, 3, 3, 3, 3, 3, 3,
+ 1, 2, 5, 7, 9, 5, 6, 3, 3, 2,
+ 2, 1, 1, 1, 0, 2, 1, 3, 8, 0,
+ 4, 1, 3, 0, 1, 0, 1, 10, 7, 6,
+ 5, 1, 2, 2, 0, 2, 0, 2, 0, 2,
+ 1, 3, 1, 4, 1, 4, 1, 1, 4, 1,
+ 3, 3, 3, 4, 4, 5, 0, 2, 4, 3,
+ 1, 1, 1, 4, 0, 2, 5, 0, 2, 6,
+ 0, 2, 0, 3, 1, 2, 1, 1, 1, 0,
+ 1, 3, 4, 6, 1, 2, 1, 1, 1, 0,
+ 1, 0, 2, 2, 3, 1, 3, 1, 2, 2,
+ 3, 1, 1, 3, 1, 1, 3, 2, 0, 3,
+ 4, 9, 3, 1, 3, 0, 2, 4, 5, 4,
+ 4, 4, 3, 1, 1, 1, 3, 1, 1, 0,
+ 1, 1, 2, 1, 1, 1, 1, 1, 1, 1,
+ 3, 1, 3, 3, 1, 0, 1, 1, 3, 3,
+ 3, 4, 1, 2, 3, 3, 3, 3, 3, 3,
+ 3, 3, 3, 3, 3, 3, 2, 2, 2, 2,
+ 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
+ 3, 3, 3, 3, 3, 3, 3, 2, 2, 2,
+ 2, 3, 3, 3, 3, 3, 3, 3, 3, 3,
+ 3, 3, 5, 4, 3, 4, 4, 2, 2, 4,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 1, 3, 2, 1, 2, 4, 2, 10, 11,
+ 7, 3, 2, 0, 4, 1, 3, 2, 2, 2,
+ 4, 1, 1, 1, 2, 3, 1, 1, 1, 1,
+ 0, 3, 0, 1, 1, 0, 1, 1, 3, 3,
+ 4, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 3, 2, 3, 3, 0,
+ 1, 1, 3, 1, 1, 3, 1, 1, 4, 4,
+ 4, 1, 4, 1, 1, 3, 1, 4, 2, 3,
+ 1, 4, 4, 3, 3, 3, 1, 3, 1, 1,
+ 3, 1, 1, 4, 3, 1, 1, 1, 3, 3,
+ 0, 1, 3, 1, 3, 1, 4, 2, 0, 2,
+ 2, 1, 2, 1, 1, 4, 3, 3, 3, 6,
+ 3, 1, 1, 1
+];
+
+
+
+exports.PHP = PHP;
+});
+
+ace.define("ace/mode/php_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/php/php"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var Mirror = require("../worker/mirror").Mirror;
+var PHP = require("./php/php").PHP;
+
+var PhpWorker = exports.PhpWorker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(500);
+};
+
+oop.inherits(PhpWorker, Mirror);
+
+(function() {
+ this.setOptions = function(opts) {
+ this.inlinePhp = opts && opts.inline;
+ };
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ var errors = [];
+ if (this.inlinePhp)
+ value = "<?" + value + "?>";
+
+ var tokens = PHP.Lexer(value, {short_open_tag: 1});
+ try {
+ new PHP.Parser(tokens);
+ } catch(e) {
+ errors.push({
+ row: e.line - 1,
+ column: null,
+ text: e.message.charAt(0).toUpperCase() + e.message.substring(1),
+ type: "error"
+ });
+ }
+
+ this.sender.emit("annotate", errors);
+ };
+
+}).call(PhpWorker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-xml.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-xml.js
new file mode 100644
index 00000000..c53e518b
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-xml.js
@@ -0,0 +1,3887 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/xml/sax",["require","exports","module"], function(require, exports, module) {
+var nameStartChar = /[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]///\u10000-\uEFFFF
+var nameChar = new RegExp("[\\-\\.0-9"+nameStartChar.source.slice(1,-1)+"\u00B7\u0300-\u036F\\ux203F-\u2040]");
+var tagNamePattern = new RegExp('^'+nameStartChar.source+nameChar.source+'*(?:\:'+nameStartChar.source+nameChar.source+'*)?$');
+var S_TAG = 0;//tag name offerring
+var S_ATTR = 1;//attr name offerring
+var S_ATTR_S=2;//attr name end and space offer
+var S_EQ = 3;//=space?
+var S_V = 4;//attr value(no quot value only)
+var S_E = 5;//attr value end and no space(quot end)
+var S_S = 6;//(attr value end || tag end ) && (space offer)
+var S_C = 7;//closed el<el />
+
+function XMLReader(){
+
+}
+
+XMLReader.prototype = {
+ parse:function(source,defaultNSMap,entityMap){
+ var domBuilder = this.domBuilder;
+ domBuilder.startDocument();
+ _copy(defaultNSMap ,defaultNSMap = {})
+ parse(source,defaultNSMap,entityMap,
+ domBuilder,this.errorHandler);
+ domBuilder.endDocument();
+ }
+}
+function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
+ function fixedFromCharCode(code) {
+ if (code > 0xffff) {
+ code -= 0x10000;
+ var surrogate1 = 0xd800 + (code >> 10)
+ , surrogate2 = 0xdc00 + (code & 0x3ff);
+
+ return String.fromCharCode(surrogate1, surrogate2);
+ } else {
+ return String.fromCharCode(code);
+ }
+ }
+ function entityReplacer(a){
+ var k = a.slice(1,-1);
+ if(k in entityMap){
+ return entityMap[k];
+ }else if(k.charAt(0) === '#'){
+ return fixedFromCharCode(parseInt(k.substr(1).replace('x','0x')))
+ }else{
+ errorHandler.error('entity not found:'+a);
+ return a;
+ }
+ }
+ function appendText(end){//has some bugs
+ var xt = source.substring(start,end).replace(/&#?\w+;/g,entityReplacer);
+ locator&&position(start);
+ domBuilder.characters(xt,0,end-start);
+ start = end
+ }
+ function position(start,m){
+ while(start>=endPos && (m = linePattern.exec(source))){
+ startPos = m.index;
+ endPos = startPos + m[0].length;
+ locator.lineNumber++;
+ }
+ locator.columnNumber = start-startPos+1;
+ }
+ var startPos = 0;
+ var endPos = 0;
+ var linePattern = /.+(?:\r\n?|\n)|.*$/g
+ var locator = domBuilder.locator;
+
+ var parseStack = [{currentNSMap:defaultNSMapCopy}]
+ var closeMap = {};
+ var start = 0;
+ while(true){
+ var i = source.indexOf('<',start);
+ if(i<0){
+ if(!source.substr(start).match(/^\s*$/)){
+ var doc = domBuilder.document;
+ var text = doc.createTextNode(source.substr(start));
+ doc.appendChild(text);
+ domBuilder.currentElement = text;
+ }
+ return;
+ }
+ if(i>start){
+ appendText(i);
+ }
+ switch(source.charAt(i+1)){
+ case '/':
+ var end = source.indexOf('>',i+3);
+ var tagName = source.substring(i+2,end);
+ var config;
+ if (parseStack.length > 1) {
+ config = parseStack.pop();
+ } else {
+ errorHandler.fatalError("end tag name not found for: "+tagName);
+ break;
+ }
+ var localNSMap = config.localNSMap;
+
+ if(config.tagName != tagName){
+ errorHandler.fatalError("end tag name: " + tagName + " does not match the current start tagName: "+config.tagName );
+ }
+ domBuilder.endElement(config.uri,config.localName,tagName);
+ if(localNSMap){
+ for(var prefix in localNSMap){
+ domBuilder.endPrefixMapping(prefix) ;
+ }
+ }
+ end++;
+ break;
+ case '?':// <?...?>
+ locator&&position(i);
+ end = parseInstruction(source,i,domBuilder);
+ break;
+ case '!':// <!doctype,<![CDATA,<!--
+ locator&&position(i);
+ end = parseDCC(source,i,domBuilder,errorHandler);
+ break;
+ default:
+ try{
+ locator&&position(i);
+
+ var el = new ElementAttributes();
+ var end = parseElementStartPart(source,i,el,entityReplacer,errorHandler);
+ var len = el.length;
+ if(len && locator){
+ var backup = copyLocator(locator,{});
+ for(var i = 0;i<len;i++){
+ var a = el[i];
+ position(a.offset);
+ a.offset = copyLocator(locator,{});
+ }
+ copyLocator(backup,locator);
+ }
+ if(!el.closed && fixSelfClosed(source,end,el.tagName,closeMap)){
+ el.closed = true;
+ if(!entityMap.nbsp){
+ errorHandler.warning('unclosed xml attribute');
+ }
+ }
+ appendElement(el,domBuilder,parseStack);
+
+
+ if(el.uri === 'http://www.w3.org/1999/xhtml' && !el.closed){
+ end = parseHtmlSpecialContent(source,end,el.tagName,entityReplacer,domBuilder)
+ }else{
+ end++;
+ }
+ }catch(e){
+ errorHandler.error('element parse error: '+e);
+ end = -1;
+ }
+
+ }
+ if(end<0){
+ appendText(i+1);
+ }else{
+ start = end;
+ }
+ }
+}
+function copyLocator(f,t){
+ t.lineNumber = f.lineNumber;
+ t.columnNumber = f.columnNumber;
+ return t;
+
+}
+function parseElementStartPart(source,start,el,entityReplacer,errorHandler){
+ var attrName;
+ var value;
+ var p = ++start;
+ var s = S_TAG;//status
+ while(true){
+ var c = source.charAt(p);
+ switch(c){
+ case '=':
+ if(s === S_ATTR){//attrName
+ attrName = source.slice(start,p);
+ s = S_EQ;
+ }else if(s === S_ATTR_S){
+ s = S_EQ;
+ }else{
+ throw new Error('attribute equal must after attrName');
+ }
+ break;
+ case '\'':
+ case '"':
+ if(s === S_EQ){//equal
+ start = p+1;
+ p = source.indexOf(c,start)
+ if(p>0){
+ value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer);
+ el.add(attrName,value,start-1);
+ s = S_E;
+ }else{
+ throw new Error('attribute value no end \''+c+'\' match');
+ }
+ }else if(s == S_V){
+ value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer);
+ el.add(attrName,value,start);
+ errorHandler.warning('attribute "'+attrName+'" missed start quot('+c+')!!');
+ start = p+1;
+ s = S_E
+ }else{
+ throw new Error('attribute value must after "="');
+ }
+ break;
+ case '/':
+ switch(s){
+ case S_TAG:
+ el.setTagName(source.slice(start,p));
+ case S_E:
+ case S_S:
+ case S_C:
+ s = S_C;
+ el.closed = true;
+ case S_V:
+ case S_ATTR:
+ case S_ATTR_S:
+ break;
+ default:
+ throw new Error("attribute invalid close char('/')")
+ }
+ break;
+ case ''://end document
+ errorHandler.error('unexpected end of input');
+ case '>':
+ switch(s){
+ case S_TAG:
+ el.setTagName(source.slice(start,p));
+ case S_E:
+ case S_S:
+ case S_C:
+ break;//normal
+ case S_V://Compatible state
+ case S_ATTR:
+ value = source.slice(start,p);
+ if(value.slice(-1) === '/'){
+ el.closed = true;
+ value = value.slice(0,-1)
+ }
+ case S_ATTR_S:
+ if(s === S_ATTR_S){
+ value = attrName;
+ }
+ if(s == S_V){
+ errorHandler.warning('attribute "'+value+'" missed quot(")!!');
+ el.add(attrName,value.replace(/&#?\w+;/g,entityReplacer),start)
+ }else{
+ errorHandler.warning('attribute "'+value+'" missed value!! "'+value+'" instead!!')
+ el.add(value,value,start)
+ }
+ break;
+ case S_EQ:
+ throw new Error('attribute value missed!!');
+ }
+ return p;
+ case '\u0080':
+ c = ' ';
+ default:
+ if(c<= ' '){//space
+ switch(s){
+ case S_TAG:
+ el.setTagName(source.slice(start,p));//tagName
+ s = S_S;
+ break;
+ case S_ATTR:
+ attrName = source.slice(start,p)
+ s = S_ATTR_S;
+ break;
+ case S_V:
+ var value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer);
+ errorHandler.warning('attribute "'+value+'" missed quot(")!!');
+ el.add(attrName,value,start)
+ case S_E:
+ s = S_S;
+ break;
+ }
+ }else{//not space
+ switch(s){
+ case S_ATTR_S:
+ errorHandler.warning('attribute "'+attrName+'" missed value!! "'+attrName+'" instead!!')
+ el.add(attrName,attrName,start);
+ start = p;
+ s = S_ATTR;
+ break;
+ case S_E:
+ errorHandler.warning('attribute space is required"'+attrName+'"!!')
+ case S_S:
+ s = S_ATTR;
+ start = p;
+ break;
+ case S_EQ:
+ s = S_V;
+ start = p;
+ break;
+ case S_C:
+ throw new Error("elements closed character '/' and '>' must be connected to");
+ }
+ }
+ }
+ p++;
+ }
+}
+function appendElement(el,domBuilder,parseStack){
+ var tagName = el.tagName;
+ var localNSMap = null;
+ var currentNSMap = parseStack[parseStack.length-1].currentNSMap;
+ var i = el.length;
+ while(i--){
+ var a = el[i];
+ var qName = a.qName;
+ var value = a.value;
+ var nsp = qName.indexOf(':');
+ if(nsp>0){
+ var prefix = a.prefix = qName.slice(0,nsp);
+ var localName = qName.slice(nsp+1);
+ var nsPrefix = prefix === 'xmlns' && localName
+ }else{
+ localName = qName;
+ prefix = null
+ nsPrefix = qName === 'xmlns' && ''
+ }
+ a.localName = localName ;
+ if(nsPrefix !== false){//hack!!
+ if(localNSMap == null){
+ localNSMap = {}
+ _copy(currentNSMap,currentNSMap={})
+ }
+ currentNSMap[nsPrefix] = localNSMap[nsPrefix] = value;
+ a.uri = 'http://www.w3.org/2000/xmlns/'
+ domBuilder.startPrefixMapping(nsPrefix, value)
+ }
+ }
+ var i = el.length;
+ while(i--){
+ a = el[i];
+ var prefix = a.prefix;
+ if(prefix){//no prefix attribute has no namespace
+ if(prefix === 'xml'){
+ a.uri = 'http://www.w3.org/XML/1998/namespace';
+ }if(prefix !== 'xmlns'){
+ a.uri = currentNSMap[prefix]
+ }
+ }
+ }
+ var nsp = tagName.indexOf(':');
+ if(nsp>0){
+ prefix = el.prefix = tagName.slice(0,nsp);
+ localName = el.localName = tagName.slice(nsp+1);
+ }else{
+ prefix = null;//important!!
+ localName = el.localName = tagName;
+ }
+ var ns = el.uri = currentNSMap[prefix || ''];
+ domBuilder.startElement(ns,localName,tagName,el);
+ if(el.closed){
+ domBuilder.endElement(ns,localName,tagName);
+ if(localNSMap){
+ for(prefix in localNSMap){
+ domBuilder.endPrefixMapping(prefix)
+ }
+ }
+ }else{
+ el.currentNSMap = currentNSMap;
+ el.localNSMap = localNSMap;
+ parseStack.push(el);
+ }
+}
+function parseHtmlSpecialContent(source,elStartEnd,tagName,entityReplacer,domBuilder){
+ if(/^(?:script|textarea)$/i.test(tagName)){
+ var elEndStart = source.indexOf('</'+tagName+'>',elStartEnd);
+ var text = source.substring(elStartEnd+1,elEndStart);
+ if(/[&<]/.test(text)){
+ if(/^script$/i.test(tagName)){
+ domBuilder.characters(text,0,text.length);
+ return elEndStart;
+ }//}else{//text area
+ text = text.replace(/&#?\w+;/g,entityReplacer);
+ domBuilder.characters(text,0,text.length);
+ return elEndStart;
+
+ }
+ }
+ return elStartEnd+1;
+}
+function fixSelfClosed(source,elStartEnd,tagName,closeMap){
+ var pos = closeMap[tagName];
+ if(pos == null){
+ pos = closeMap[tagName] = source.lastIndexOf('</'+tagName+'>')
+ }
+ return pos<elStartEnd;
+}
+function _copy(source,target){
+ for(var n in source){target[n] = source[n]}
+}
+function parseDCC(source,start,domBuilder,errorHandler){//sure start with '<!'
+ var next= source.charAt(start+2)
+ switch(next){
+ case '-':
+ if(source.charAt(start + 3) === '-'){
+ var end = source.indexOf('-->',start+4);
+ if(end>start){
+ domBuilder.comment(source,start+4,end-start-4);
+ return end+3;
+ }else{
+ errorHandler.error("Unclosed comment");
+ return -1;
+ }
+ }else{
+ return -1;
+ }
+ default:
+ if(source.substr(start+3,6) == 'CDATA['){
+ var end = source.indexOf(']]>',start+9);
+ domBuilder.startCDATA();
+ domBuilder.characters(source,start+9,end-start-9);
+ domBuilder.endCDATA()
+ return end+3;
+ }
+ var matchs = split(source,start);
+ var len = matchs.length;
+ if(len>1 && /!doctype/i.test(matchs[0][0])){
+ var name = matchs[1][0];
+ var pubid = len>3 && /^public$/i.test(matchs[2][0]) && matchs[3][0]
+ var sysid = len>4 && matchs[4][0];
+ var lastMatch = matchs[len-1]
+ domBuilder.startDTD(name,pubid && pubid.replace(/^(['"])(.*?)\1$/,'$2'),
+ sysid && sysid.replace(/^(['"])(.*?)\1$/,'$2'));
+ domBuilder.endDTD();
+
+ return lastMatch.index+lastMatch[0].length
+ }
+ }
+ return -1;
+}
+
+
+
+function parseInstruction(source,start,domBuilder){
+ var end = source.indexOf('?>',start);
+ if(end){
+ var match = source.substring(start,end).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);
+ if(match){
+ var len = match[0].length;
+ domBuilder.processingInstruction(match[1], match[2]) ;
+ return end+2;
+ }else{//error
+ return -1;
+ }
+ }
+ return -1;
+}
+function ElementAttributes(source){
+
+}
+ElementAttributes.prototype = {
+ setTagName:function(tagName){
+ if(!tagNamePattern.test(tagName)){
+ throw new Error('invalid tagName:'+tagName)
+ }
+ this.tagName = tagName
+ },
+ add:function(qName,value,offset){
+ if(!tagNamePattern.test(qName)){
+ throw new Error('invalid attribute:'+qName)
+ }
+ this[this.length++] = {qName:qName,value:value,offset:offset}
+ },
+ length:0,
+ getLocalName:function(i){return this[i].localName},
+ getOffset:function(i){return this[i].offset},
+ getQName:function(i){return this[i].qName},
+ getURI:function(i){return this[i].uri},
+ getValue:function(i){return this[i].value}
+}
+
+
+
+
+function _set_proto_(thiz,parent){
+ thiz.__proto__ = parent;
+ return thiz;
+}
+if(!(_set_proto_({},_set_proto_.prototype) instanceof _set_proto_)){
+ _set_proto_ = function(thiz,parent){
+ function p(){};
+ p.prototype = parent;
+ p = new p();
+ for(parent in thiz){
+ p[parent] = thiz[parent];
+ }
+ return p;
+ }
+}
+
+function split(source,start){
+ var match;
+ var buf = [];
+ var reg = /'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;
+ reg.lastIndex = start;
+ reg.exec(source);//skip <
+ while(match = reg.exec(source)){
+ buf.push(match);
+ if(match[1])return buf;
+ }
+}
+
+return XMLReader;
+});
+
+ace.define("ace/mode/xml/dom",["require","exports","module"], function(require, exports, module) {
+
+function copy(src,dest){
+ for(var p in src){
+ dest[p] = src[p];
+ }
+}
+function _extends(Class,Super){
+ var pt = Class.prototype;
+ if(Object.create){
+ var ppt = Object.create(Super.prototype)
+ pt.__proto__ = ppt;
+ }
+ if(!(pt instanceof Super)){
+ function t(){};
+ t.prototype = Super.prototype;
+ t = new t();
+ copy(pt,t);
+ Class.prototype = pt = t;
+ }
+ if(pt.constructor != Class){
+ if(typeof Class != 'function'){
+ console.error("unknow Class:"+Class)
+ }
+ pt.constructor = Class
+ }
+}
+var htmlns = 'http://www.w3.org/1999/xhtml' ;
+var NodeType = {}
+var ELEMENT_NODE = NodeType.ELEMENT_NODE = 1;
+var ATTRIBUTE_NODE = NodeType.ATTRIBUTE_NODE = 2;
+var TEXT_NODE = NodeType.TEXT_NODE = 3;
+var CDATA_SECTION_NODE = NodeType.CDATA_SECTION_NODE = 4;
+var ENTITY_REFERENCE_NODE = NodeType.ENTITY_REFERENCE_NODE = 5;
+var ENTITY_NODE = NodeType.ENTITY_NODE = 6;
+var PROCESSING_INSTRUCTION_NODE = NodeType.PROCESSING_INSTRUCTION_NODE = 7;
+var COMMENT_NODE = NodeType.COMMENT_NODE = 8;
+var DOCUMENT_NODE = NodeType.DOCUMENT_NODE = 9;
+var DOCUMENT_TYPE_NODE = NodeType.DOCUMENT_TYPE_NODE = 10;
+var DOCUMENT_FRAGMENT_NODE = NodeType.DOCUMENT_FRAGMENT_NODE = 11;
+var NOTATION_NODE = NodeType.NOTATION_NODE = 12;
+var ExceptionCode = {}
+var ExceptionMessage = {};
+var INDEX_SIZE_ERR = ExceptionCode.INDEX_SIZE_ERR = ((ExceptionMessage[1]="Index size error"),1);
+var DOMSTRING_SIZE_ERR = ExceptionCode.DOMSTRING_SIZE_ERR = ((ExceptionMessage[2]="DOMString size error"),2);
+var HIERARCHY_REQUEST_ERR = ExceptionCode.HIERARCHY_REQUEST_ERR = ((ExceptionMessage[3]="Hierarchy request error"),3);
+var WRONG_DOCUMENT_ERR = ExceptionCode.WRONG_DOCUMENT_ERR = ((ExceptionMessage[4]="Wrong document"),4);
+var INVALID_CHARACTER_ERR = ExceptionCode.INVALID_CHARACTER_ERR = ((ExceptionMessage[5]="Invalid character"),5);
+var NO_DATA_ALLOWED_ERR = ExceptionCode.NO_DATA_ALLOWED_ERR = ((ExceptionMessage[6]="No data allowed"),6);
+var NO_MODIFICATION_ALLOWED_ERR = ExceptionCode.NO_MODIFICATION_ALLOWED_ERR = ((ExceptionMessage[7]="No modification allowed"),7);
+var NOT_FOUND_ERR = ExceptionCode.NOT_FOUND_ERR = ((ExceptionMessage[8]="Not found"),8);
+var NOT_SUPPORTED_ERR = ExceptionCode.NOT_SUPPORTED_ERR = ((ExceptionMessage[9]="Not supported"),9);
+var INUSE_ATTRIBUTE_ERR = ExceptionCode.INUSE_ATTRIBUTE_ERR = ((ExceptionMessage[10]="Attribute in use"),10);
+var INVALID_STATE_ERR = ExceptionCode.INVALID_STATE_ERR = ((ExceptionMessage[11]="Invalid state"),11);
+var SYNTAX_ERR = ExceptionCode.SYNTAX_ERR = ((ExceptionMessage[12]="Syntax error"),12);
+var INVALID_MODIFICATION_ERR = ExceptionCode.INVALID_MODIFICATION_ERR = ((ExceptionMessage[13]="Invalid modification"),13);
+var NAMESPACE_ERR = ExceptionCode.NAMESPACE_ERR = ((ExceptionMessage[14]="Invalid namespace"),14);
+var INVALID_ACCESS_ERR = ExceptionCode.INVALID_ACCESS_ERR = ((ExceptionMessage[15]="Invalid access"),15);
+
+
+function DOMException(code, message) {
+ if(message instanceof Error){
+ var error = message;
+ }else{
+ error = this;
+ Error.call(this, ExceptionMessage[code]);
+ this.message = ExceptionMessage[code];
+ if(Error.captureStackTrace) Error.captureStackTrace(this, DOMException);
+ }
+ error.code = code;
+ if(message) this.message = this.message + ": " + message;
+ return error;
+};
+DOMException.prototype = Error.prototype;
+copy(ExceptionCode,DOMException)
+function NodeList() {
+};
+NodeList.prototype = {
+ length:0,
+ item: function(index) {
+ return this[index] || null;
+ }
+};
+function LiveNodeList(node,refresh){
+ this._node = node;
+ this._refresh = refresh
+ _updateLiveList(this);
+}
+function _updateLiveList(list){
+ var inc = list._node._inc || list._node.ownerDocument._inc;
+ if(list._inc != inc){
+ var ls = list._refresh(list._node);
+ __set__(list,'length',ls.length);
+ copy(ls,list);
+ list._inc = inc;
+ }
+}
+LiveNodeList.prototype.item = function(i){
+ _updateLiveList(this);
+ return this[i];
+}
+
+_extends(LiveNodeList,NodeList);
+function NamedNodeMap() {
+};
+
+function _findNodeIndex(list,node){
+ var i = list.length;
+ while(i--){
+ if(list[i] === node){return i}
+ }
+}
+
+function _addNamedNode(el,list,newAttr,oldAttr){
+ if(oldAttr){
+ list[_findNodeIndex(list,oldAttr)] = newAttr;
+ }else{
+ list[list.length++] = newAttr;
+ }
+ if(el){
+ newAttr.ownerElement = el;
+ var doc = el.ownerDocument;
+ if(doc){
+ oldAttr && _onRemoveAttribute(doc,el,oldAttr);
+ _onAddAttribute(doc,el,newAttr);
+ }
+ }
+}
+function _removeNamedNode(el,list,attr){
+ var i = _findNodeIndex(list,attr);
+ if(i>=0){
+ var lastIndex = list.length-1
+ while(i<lastIndex){
+ list[i] = list[++i]
+ }
+ list.length = lastIndex;
+ if(el){
+ var doc = el.ownerDocument;
+ if(doc){
+ _onRemoveAttribute(doc,el,attr);
+ attr.ownerElement = null;
+ }
+ }
+ }else{
+ throw DOMException(NOT_FOUND_ERR,new Error())
+ }
+}
+NamedNodeMap.prototype = {
+ length:0,
+ item:NodeList.prototype.item,
+ getNamedItem: function(key) {
+ var i = this.length;
+ while(i--){
+ var attr = this[i];
+ if(attr.nodeName == key){
+ return attr;
+ }
+ }
+ },
+ setNamedItem: function(attr) {
+ var el = attr.ownerElement;
+ if(el && el!=this._ownerElement){
+ throw new DOMException(INUSE_ATTRIBUTE_ERR);
+ }
+ var oldAttr = this.getNamedItem(attr.nodeName);
+ _addNamedNode(this._ownerElement,this,attr,oldAttr);
+ return oldAttr;
+ },
+ setNamedItemNS: function(attr) {// raises: WRONG_DOCUMENT_ERR,NO_MODIFICATION_ALLOWED_ERR,INUSE_ATTRIBUTE_ERR
+ var el = attr.ownerElement, oldAttr;
+ if(el && el!=this._ownerElement){
+ throw new DOMException(INUSE_ATTRIBUTE_ERR);
+ }
+ oldAttr = this.getNamedItemNS(attr.namespaceURI,attr.localName);
+ _addNamedNode(this._ownerElement,this,attr,oldAttr);
+ return oldAttr;
+ },
+ removeNamedItem: function(key) {
+ var attr = this.getNamedItem(key);
+ _removeNamedNode(this._ownerElement,this,attr);
+ return attr;
+
+
+ },// raises: NOT_FOUND_ERR,NO_MODIFICATION_ALLOWED_ERR
+ removeNamedItemNS:function(namespaceURI,localName){
+ var attr = this.getNamedItemNS(namespaceURI,localName);
+ _removeNamedNode(this._ownerElement,this,attr);
+ return attr;
+ },
+ getNamedItemNS: function(namespaceURI, localName) {
+ var i = this.length;
+ while(i--){
+ var node = this[i];
+ if(node.localName == localName && node.namespaceURI == namespaceURI){
+ return node;
+ }
+ }
+ return null;
+ }
+};
+function DOMImplementation(/* Object */ features) {
+ this._features = {};
+ if (features) {
+ for (var feature in features) {
+ this._features = features[feature];
+ }
+ }
+};
+
+DOMImplementation.prototype = {
+ hasFeature: function(/* string */ feature, /* string */ version) {
+ var versions = this._features[feature.toLowerCase()];
+ if (versions && (!version || version in versions)) {
+ return true;
+ } else {
+ return false;
+ }
+ },
+ createDocument:function(namespaceURI, qualifiedName, doctype){// raises:INVALID_CHARACTER_ERR,NAMESPACE_ERR,WRONG_DOCUMENT_ERR
+ var doc = new Document();
+ doc.implementation = this;
+ doc.childNodes = new NodeList();
+ doc.doctype = doctype;
+ if(doctype){
+ doc.appendChild(doctype);
+ }
+ if(qualifiedName){
+ var root = doc.createElementNS(namespaceURI,qualifiedName);
+ doc.appendChild(root);
+ }
+ return doc;
+ },
+ createDocumentType:function(qualifiedName, publicId, systemId){// raises:INVALID_CHARACTER_ERR,NAMESPACE_ERR
+ var node = new DocumentType();
+ node.name = qualifiedName;
+ node.nodeName = qualifiedName;
+ node.publicId = publicId;
+ node.systemId = systemId;
+ return node;
+ }
+};
+
+function Node() {
+};
+
+Node.prototype = {
+ firstChild : null,
+ lastChild : null,
+ previousSibling : null,
+ nextSibling : null,
+ attributes : null,
+ parentNode : null,
+ childNodes : null,
+ ownerDocument : null,
+ nodeValue : null,
+ namespaceURI : null,
+ prefix : null,
+ localName : null,
+ insertBefore:function(newChild, refChild){//raises
+ return _insertBefore(this,newChild,refChild);
+ },
+ replaceChild:function(newChild, oldChild){//raises
+ this.insertBefore(newChild,oldChild);
+ if(oldChild){
+ this.removeChild(oldChild);
+ }
+ },
+ removeChild:function(oldChild){
+ return _removeChild(this,oldChild);
+ },
+ appendChild:function(newChild){
+ return this.insertBefore(newChild,null);
+ },
+ hasChildNodes:function(){
+ return this.firstChild != null;
+ },
+ cloneNode:function(deep){
+ return cloneNode(this.ownerDocument||this,this,deep);
+ },
+ normalize:function(){
+ var child = this.firstChild;
+ while(child){
+ var next = child.nextSibling;
+ if(next && next.nodeType == TEXT_NODE && child.nodeType == TEXT_NODE){
+ this.removeChild(next);
+ child.appendData(next.data);
+ }else{
+ child.normalize();
+ child = next;
+ }
+ }
+ },
+ isSupported:function(feature, version){
+ return this.ownerDocument.implementation.hasFeature(feature,version);
+ },
+ hasAttributes:function(){
+ return this.attributes.length>0;
+ },
+ lookupPrefix:function(namespaceURI){
+ var el = this;
+ while(el){
+ var map = el._nsMap;
+ if(map){
+ for(var n in map){
+ if(map[n] == namespaceURI){
+ return n;
+ }
+ }
+ }
+ el = el.nodeType == 2?el.ownerDocument : el.parentNode;
+ }
+ return null;
+ },
+ lookupNamespaceURI:function(prefix){
+ var el = this;
+ while(el){
+ var map = el._nsMap;
+ if(map){
+ if(prefix in map){
+ return map[prefix] ;
+ }
+ }
+ el = el.nodeType == 2?el.ownerDocument : el.parentNode;
+ }
+ return null;
+ },
+ isDefaultNamespace:function(namespaceURI){
+ var prefix = this.lookupPrefix(namespaceURI);
+ return prefix == null;
+ }
+};
+
+
+function _xmlEncoder(c){
+ return c == '<' && '&lt;' ||
+ c == '>' && '&gt;' ||
+ c == '&' && '&amp;' ||
+ c == '"' && '&quot;' ||
+ '&#'+c.charCodeAt()+';'
+}
+
+
+copy(NodeType,Node);
+copy(NodeType,Node.prototype);
+function _visitNode(node,callback){
+ if(callback(node)){
+ return true;
+ }
+ if(node = node.firstChild){
+ do{
+ if(_visitNode(node,callback)){return true}
+ }while(node=node.nextSibling)
+ }
+}
+
+
+
+function Document(){
+}
+function _onAddAttribute(doc,el,newAttr){
+ doc && doc._inc++;
+ var ns = newAttr.namespaceURI ;
+ if(ns == 'http://www.w3.org/2000/xmlns/'){
+ el._nsMap[newAttr.prefix?newAttr.localName:''] = newAttr.value
+ }
+}
+function _onRemoveAttribute(doc,el,newAttr,remove){
+ doc && doc._inc++;
+ var ns = newAttr.namespaceURI ;
+ if(ns == 'http://www.w3.org/2000/xmlns/'){
+ delete el._nsMap[newAttr.prefix?newAttr.localName:'']
+ }
+}
+function _onUpdateChild(doc,el,newChild){
+ if(doc && doc._inc){
+ doc._inc++;
+ var cs = el.childNodes;
+ if(newChild){
+ cs[cs.length++] = newChild;
+ }else{
+ var child = el.firstChild;
+ var i = 0;
+ while(child){
+ cs[i++] = child;
+ child =child.nextSibling;
+ }
+ cs.length = i;
+ }
+ }
+}
+function _removeChild(parentNode,child){
+ var previous = child.previousSibling;
+ var next = child.nextSibling;
+ if(previous){
+ previous.nextSibling = next;
+ }else{
+ parentNode.firstChild = next
+ }
+ if(next){
+ next.previousSibling = previous;
+ }else{
+ parentNode.lastChild = previous;
+ }
+ _onUpdateChild(parentNode.ownerDocument,parentNode);
+ return child;
+}
+function _insertBefore(parentNode,newChild,nextChild){
+ var cp = newChild.parentNode;
+ if(cp){
+ cp.removeChild(newChild);//remove and update
+ }
+ if(newChild.nodeType === DOCUMENT_FRAGMENT_NODE){
+ var newFirst = newChild.firstChild;
+ if (newFirst == null) {
+ return newChild;
+ }
+ var newLast = newChild.lastChild;
+ }else{
+ newFirst = newLast = newChild;
+ }
+ var pre = nextChild ? nextChild.previousSibling : parentNode.lastChild;
+
+ newFirst.previousSibling = pre;
+ newLast.nextSibling = nextChild;
+
+
+ if(pre){
+ pre.nextSibling = newFirst;
+ }else{
+ parentNode.firstChild = newFirst;
+ }
+ if(nextChild == null){
+ parentNode.lastChild = newLast;
+ }else{
+ nextChild.previousSibling = newLast;
+ }
+ do{
+ newFirst.parentNode = parentNode;
+ }while(newFirst !== newLast && (newFirst= newFirst.nextSibling))
+ _onUpdateChild(parentNode.ownerDocument||parentNode,parentNode);
+ if (newChild.nodeType == DOCUMENT_FRAGMENT_NODE) {
+ newChild.firstChild = newChild.lastChild = null;
+ }
+ return newChild;
+}
+function _appendSingleChild(parentNode,newChild){
+ var cp = newChild.parentNode;
+ if(cp){
+ var pre = parentNode.lastChild;
+ cp.removeChild(newChild);//remove and update
+ var pre = parentNode.lastChild;
+ }
+ var pre = parentNode.lastChild;
+ newChild.parentNode = parentNode;
+ newChild.previousSibling = pre;
+ newChild.nextSibling = null;
+ if(pre){
+ pre.nextSibling = newChild;
+ }else{
+ parentNode.firstChild = newChild;
+ }
+ parentNode.lastChild = newChild;
+ _onUpdateChild(parentNode.ownerDocument,parentNode,newChild);
+ return newChild;
+}
+Document.prototype = {
+ nodeName : '#document',
+ nodeType : DOCUMENT_NODE,
+ doctype : null,
+ documentElement : null,
+ _inc : 1,
+
+ insertBefore : function(newChild, refChild){//raises
+ if(newChild.nodeType == DOCUMENT_FRAGMENT_NODE){
+ var child = newChild.firstChild;
+ while(child){
+ var next = child.nextSibling;
+ this.insertBefore(child,refChild);
+ child = next;
+ }
+ return newChild;
+ }
+ if(this.documentElement == null && newChild.nodeType == 1){
+ this.documentElement = newChild;
+ }
+
+ return _insertBefore(this,newChild,refChild),(newChild.ownerDocument = this),newChild;
+ },
+ removeChild : function(oldChild){
+ if(this.documentElement == oldChild){
+ this.documentElement = null;
+ }
+ return _removeChild(this,oldChild);
+ },
+ importNode : function(importedNode,deep){
+ return importNode(this,importedNode,deep);
+ },
+ getElementById : function(id){
+ var rtv = null;
+ _visitNode(this.documentElement,function(node){
+ if(node.nodeType == 1){
+ if(node.getAttribute('id') == id){
+ rtv = node;
+ return true;
+ }
+ }
+ })
+ return rtv;
+ },
+ createElement : function(tagName){
+ var node = new Element();
+ node.ownerDocument = this;
+ node.nodeName = tagName;
+ node.tagName = tagName;
+ node.childNodes = new NodeList();
+ var attrs = node.attributes = new NamedNodeMap();
+ attrs._ownerElement = node;
+ return node;
+ },
+ createDocumentFragment : function(){
+ var node = new DocumentFragment();
+ node.ownerDocument = this;
+ node.childNodes = new NodeList();
+ return node;
+ },
+ createTextNode : function(data){
+ var node = new Text();
+ node.ownerDocument = this;
+ node.appendData(data)
+ return node;
+ },
+ createComment : function(data){
+ var node = new Comment();
+ node.ownerDocument = this;
+ node.appendData(data)
+ return node;
+ },
+ createCDATASection : function(data){
+ var node = new CDATASection();
+ node.ownerDocument = this;
+ node.appendData(data)
+ return node;
+ },
+ createProcessingInstruction : function(target,data){
+ var node = new ProcessingInstruction();
+ node.ownerDocument = this;
+ node.tagName = node.target = target;
+ node.nodeValue= node.data = data;
+ return node;
+ },
+ createAttribute : function(name){
+ var node = new Attr();
+ node.ownerDocument = this;
+ node.name = name;
+ node.nodeName = name;
+ node.localName = name;
+ node.specified = true;
+ return node;
+ },
+ createEntityReference : function(name){
+ var node = new EntityReference();
+ node.ownerDocument = this;
+ node.nodeName = name;
+ return node;
+ },
+ createElementNS : function(namespaceURI,qualifiedName){
+ var node = new Element();
+ var pl = qualifiedName.split(':');
+ var attrs = node.attributes = new NamedNodeMap();
+ node.childNodes = new NodeList();
+ node.ownerDocument = this;
+ node.nodeName = qualifiedName;
+ node.tagName = qualifiedName;
+ node.namespaceURI = namespaceURI;
+ if(pl.length == 2){
+ node.prefix = pl[0];
+ node.localName = pl[1];
+ }else{
+ node.localName = qualifiedName;
+ }
+ attrs._ownerElement = node;
+ return node;
+ },
+ createAttributeNS : function(namespaceURI,qualifiedName){
+ var node = new Attr();
+ var pl = qualifiedName.split(':');
+ node.ownerDocument = this;
+ node.nodeName = qualifiedName;
+ node.name = qualifiedName;
+ node.namespaceURI = namespaceURI;
+ node.specified = true;
+ if(pl.length == 2){
+ node.prefix = pl[0];
+ node.localName = pl[1];
+ }else{
+ node.localName = qualifiedName;
+ }
+ return node;
+ }
+};
+_extends(Document,Node);
+
+
+function Element() {
+ this._nsMap = {};
+};
+Element.prototype = {
+ nodeType : ELEMENT_NODE,
+ hasAttribute : function(name){
+ return this.getAttributeNode(name)!=null;
+ },
+ getAttribute : function(name){
+ var attr = this.getAttributeNode(name);
+ return attr && attr.value || '';
+ },
+ getAttributeNode : function(name){
+ return this.attributes.getNamedItem(name);
+ },
+ setAttribute : function(name, value){
+ var attr = this.ownerDocument.createAttribute(name);
+ attr.value = attr.nodeValue = "" + value;
+ this.setAttributeNode(attr)
+ },
+ removeAttribute : function(name){
+ var attr = this.getAttributeNode(name)
+ attr && this.removeAttributeNode(attr);
+ },
+ appendChild:function(newChild){
+ if(newChild.nodeType === DOCUMENT_FRAGMENT_NODE){
+ return this.insertBefore(newChild,null);
+ }else{
+ return _appendSingleChild(this,newChild);
+ }
+ },
+ setAttributeNode : function(newAttr){
+ return this.attributes.setNamedItem(newAttr);
+ },
+ setAttributeNodeNS : function(newAttr){
+ return this.attributes.setNamedItemNS(newAttr);
+ },
+ removeAttributeNode : function(oldAttr){
+ return this.attributes.removeNamedItem(oldAttr.nodeName);
+ },
+ removeAttributeNS : function(namespaceURI, localName){
+ var old = this.getAttributeNodeNS(namespaceURI, localName);
+ old && this.removeAttributeNode(old);
+ },
+
+ hasAttributeNS : function(namespaceURI, localName){
+ return this.getAttributeNodeNS(namespaceURI, localName)!=null;
+ },
+ getAttributeNS : function(namespaceURI, localName){
+ var attr = this.getAttributeNodeNS(namespaceURI, localName);
+ return attr && attr.value || '';
+ },
+ setAttributeNS : function(namespaceURI, qualifiedName, value){
+ var attr = this.ownerDocument.createAttributeNS(namespaceURI, qualifiedName);
+ attr.value = attr.nodeValue = "" + value;
+ this.setAttributeNode(attr)
+ },
+ getAttributeNodeNS : function(namespaceURI, localName){
+ return this.attributes.getNamedItemNS(namespaceURI, localName);
+ },
+
+ getElementsByTagName : function(tagName){
+ return new LiveNodeList(this,function(base){
+ var ls = [];
+ _visitNode(base,function(node){
+ if(node !== base && node.nodeType == ELEMENT_NODE && (tagName === '*' || node.tagName == tagName)){
+ ls.push(node);
+ }
+ });
+ return ls;
+ });
+ },
+ getElementsByTagNameNS : function(namespaceURI, localName){
+ return new LiveNodeList(this,function(base){
+ var ls = [];
+ _visitNode(base,function(node){
+ if(node !== base && node.nodeType === ELEMENT_NODE && (namespaceURI === '*' || node.namespaceURI === namespaceURI) && (localName === '*' || node.localName == localName)){
+ ls.push(node);
+ }
+ });
+ return ls;
+ });
+ }
+};
+Document.prototype.getElementsByTagName = Element.prototype.getElementsByTagName;
+Document.prototype.getElementsByTagNameNS = Element.prototype.getElementsByTagNameNS;
+
+
+_extends(Element,Node);
+function Attr() {
+};
+Attr.prototype.nodeType = ATTRIBUTE_NODE;
+_extends(Attr,Node);
+
+
+function CharacterData() {
+};
+CharacterData.prototype = {
+ data : '',
+ substringData : function(offset, count) {
+ return this.data.substring(offset, offset+count);
+ },
+ appendData: function(text) {
+ text = this.data+text;
+ this.nodeValue = this.data = text;
+ this.length = text.length;
+ },
+ insertData: function(offset,text) {
+ this.replaceData(offset,0,text);
+
+ },
+ appendChild:function(newChild){
+ throw new Error(ExceptionMessage[3])
+ return Node.prototype.appendChild.apply(this,arguments)
+ },
+ deleteData: function(offset, count) {
+ this.replaceData(offset,count,"");
+ },
+ replaceData: function(offset, count, text) {
+ var start = this.data.substring(0,offset);
+ var end = this.data.substring(offset+count);
+ text = start + text + end;
+ this.nodeValue = this.data = text;
+ this.length = text.length;
+ }
+}
+_extends(CharacterData,Node);
+function Text() {
+};
+Text.prototype = {
+ nodeName : "#text",
+ nodeType : TEXT_NODE,
+ splitText : function(offset) {
+ var text = this.data;
+ var newText = text.substring(offset);
+ text = text.substring(0, offset);
+ this.data = this.nodeValue = text;
+ this.length = text.length;
+ var newNode = this.ownerDocument.createTextNode(newText);
+ if(this.parentNode){
+ this.parentNode.insertBefore(newNode, this.nextSibling);
+ }
+ return newNode;
+ }
+}
+_extends(Text,CharacterData);
+function Comment() {
+};
+Comment.prototype = {
+ nodeName : "#comment",
+ nodeType : COMMENT_NODE
+}
+_extends(Comment,CharacterData);
+
+function CDATASection() {
+};
+CDATASection.prototype = {
+ nodeName : "#cdata-section",
+ nodeType : CDATA_SECTION_NODE
+}
+_extends(CDATASection,CharacterData);
+
+
+function DocumentType() {
+};
+DocumentType.prototype.nodeType = DOCUMENT_TYPE_NODE;
+_extends(DocumentType,Node);
+
+function Notation() {
+};
+Notation.prototype.nodeType = NOTATION_NODE;
+_extends(Notation,Node);
+
+function Entity() {
+};
+Entity.prototype.nodeType = ENTITY_NODE;
+_extends(Entity,Node);
+
+function EntityReference() {
+};
+EntityReference.prototype.nodeType = ENTITY_REFERENCE_NODE;
+_extends(EntityReference,Node);
+
+function DocumentFragment() {
+};
+DocumentFragment.prototype.nodeName = "#document-fragment";
+DocumentFragment.prototype.nodeType = DOCUMENT_FRAGMENT_NODE;
+_extends(DocumentFragment,Node);
+
+
+function ProcessingInstruction() {
+}
+ProcessingInstruction.prototype.nodeType = PROCESSING_INSTRUCTION_NODE;
+_extends(ProcessingInstruction,Node);
+function XMLSerializer(){}
+XMLSerializer.prototype.serializeToString = function(node){
+ var buf = [];
+ serializeToString(node,buf);
+ return buf.join('');
+}
+Node.prototype.toString =function(){
+ return XMLSerializer.prototype.serializeToString(this);
+}
+function serializeToString(node,buf){
+ switch(node.nodeType){
+ case ELEMENT_NODE:
+ var attrs = node.attributes;
+ var len = attrs.length;
+ var child = node.firstChild;
+ var nodeName = node.tagName;
+ var isHTML = htmlns === node.namespaceURI
+ buf.push('<',nodeName);
+ for(var i=0;i<len;i++){
+ serializeToString(attrs.item(i),buf,isHTML);
+ }
+ if(child || isHTML && !/^(?:meta|link|img|br|hr|input|button)$/i.test(nodeName)){
+ buf.push('>');
+ if(isHTML && /^script$/i.test(nodeName)){
+ if(child){
+ buf.push(child.data);
+ }
+ }else{
+ while(child){
+ serializeToString(child,buf);
+ child = child.nextSibling;
+ }
+ }
+ buf.push('</',nodeName,'>');
+ }else{
+ buf.push('/>');
+ }
+ return;
+ case DOCUMENT_NODE:
+ case DOCUMENT_FRAGMENT_NODE:
+ var child = node.firstChild;
+ while(child){
+ serializeToString(child,buf);
+ child = child.nextSibling;
+ }
+ return;
+ case ATTRIBUTE_NODE:
+ return buf.push(' ',node.name,'="',node.value.replace(/[<&"]/g,_xmlEncoder),'"');
+ case TEXT_NODE:
+ return buf.push(node.data.replace(/[<&]/g,_xmlEncoder));
+ case CDATA_SECTION_NODE:
+ return buf.push( '<![CDATA[',node.data,']]>');
+ case COMMENT_NODE:
+ return buf.push( "<!--",node.data,"-->");
+ case DOCUMENT_TYPE_NODE:
+ var pubid = node.publicId;
+ var sysid = node.systemId;
+ buf.push('<!DOCTYPE ',node.name);
+ if(pubid){
+ buf.push(' PUBLIC "',pubid);
+ if (sysid && sysid!='.') {
+ buf.push( '" "',sysid);
+ }
+ buf.push('">');
+ }else if(sysid && sysid!='.'){
+ buf.push(' SYSTEM "',sysid,'">');
+ }else{
+ var sub = node.internalSubset;
+ if(sub){
+ buf.push(" [",sub,"]");
+ }
+ buf.push(">");
+ }
+ return;
+ case PROCESSING_INSTRUCTION_NODE:
+ return buf.push( "<?",node.target," ",node.data,"?>");
+ case ENTITY_REFERENCE_NODE:
+ return buf.push( '&',node.nodeName,';');
+ default:
+ buf.push('??',node.nodeName);
+ }
+}
+function importNode(doc,node,deep){
+ var node2;
+ switch (node.nodeType) {
+ case ELEMENT_NODE:
+ node2 = node.cloneNode(false);
+ node2.ownerDocument = doc;
+ case DOCUMENT_FRAGMENT_NODE:
+ break;
+ case ATTRIBUTE_NODE:
+ deep = true;
+ break;
+ }
+ if(!node2){
+ node2 = node.cloneNode(false);//false
+ }
+ node2.ownerDocument = doc;
+ node2.parentNode = null;
+ if(deep){
+ var child = node.firstChild;
+ while(child){
+ node2.appendChild(importNode(doc,child,deep));
+ child = child.nextSibling;
+ }
+ }
+ return node2;
+}
+function cloneNode(doc,node,deep){
+ var node2 = new node.constructor();
+ for(var n in node){
+ var v = node[n];
+ if(typeof v != 'object' ){
+ if(v != node2[n]){
+ node2[n] = v;
+ }
+ }
+ }
+ if(node.childNodes){
+ node2.childNodes = new NodeList();
+ }
+ node2.ownerDocument = doc;
+ switch (node2.nodeType) {
+ case ELEMENT_NODE:
+ var attrs = node.attributes;
+ var attrs2 = node2.attributes = new NamedNodeMap();
+ var len = attrs.length
+ attrs2._ownerElement = node2;
+ for(var i=0;i<len;i++){
+ node2.setAttributeNode(cloneNode(doc,attrs.item(i),true));
+ }
+ break;;
+ case ATTRIBUTE_NODE:
+ deep = true;
+ }
+ if(deep){
+ var child = node.firstChild;
+ while(child){
+ node2.appendChild(cloneNode(doc,child,deep));
+ child = child.nextSibling;
+ }
+ }
+ return node2;
+}
+
+function __set__(object,key,value){
+ object[key] = value
+}
+try{
+ if(Object.defineProperty){
+ Object.defineProperty(LiveNodeList.prototype,'length',{
+ get:function(){
+ _updateLiveList(this);
+ return this.$$length;
+ }
+ });
+ Object.defineProperty(Node.prototype,'textContent',{
+ get:function(){
+ return getTextContent(this);
+ },
+ set:function(data){
+ switch(this.nodeType){
+ case 1:
+ case 11:
+ while(this.firstChild){
+ this.removeChild(this.firstChild);
+ }
+ if(data || String(data)){
+ this.appendChild(this.ownerDocument.createTextNode(data));
+ }
+ break;
+ default:
+ this.data = data;
+ this.value = value;
+ this.nodeValue = data;
+ }
+ }
+ })
+
+ function getTextContent(node){
+ switch(node.nodeType){
+ case 1:
+ case 11:
+ var buf = [];
+ node = node.firstChild;
+ while(node){
+ if(node.nodeType!==7 && node.nodeType !==8){
+ buf.push(getTextContent(node));
+ }
+ node = node.nextSibling;
+ }
+ return buf.join('');
+ default:
+ return node.nodeValue;
+ }
+ }
+ __set__ = function(object,key,value){
+ object['$$'+key] = value
+ }
+ }
+}catch(e){//ie8
+}
+
+return DOMImplementation;
+});
+
+ace.define("ace/mode/xml/dom-parser",["require","exports","module","ace/mode/xml/sax","ace/mode/xml/dom"], function(require, exports, module) {
+ 'use strict';
+
+ var XMLReader = require('./sax'),
+ DOMImplementation = require('./dom');
+
+function DOMParser(options){
+ this.options = options ||{locator:{}};
+
+}
+DOMParser.prototype.parseFromString = function(source,mimeType){
+ var options = this.options;
+ var sax = new XMLReader();
+ var domBuilder = options.domBuilder || new DOMHandler();//contentHandler and LexicalHandler
+ var errorHandler = options.errorHandler;
+ var locator = options.locator;
+ var defaultNSMap = options.xmlns||{};
+ var entityMap = {'lt':'<','gt':'>','amp':'&','quot':'"','apos':"'"}
+ if(locator){
+ domBuilder.setDocumentLocator(locator)
+ }
+
+ sax.errorHandler = buildErrorHandler(errorHandler,domBuilder,locator);
+ sax.domBuilder = options.domBuilder || domBuilder;
+ if(/\/x?html?$/.test(mimeType)){
+ entityMap.nbsp = '\xa0';
+ entityMap.copy = '\xa9';
+ defaultNSMap['']= 'http://www.w3.org/1999/xhtml';
+ }
+ if(source){
+ sax.parse(source,defaultNSMap,entityMap);
+ }else{
+ sax.errorHandler.error("invalid document source");
+ }
+ return domBuilder.document;
+}
+function buildErrorHandler(errorImpl,domBuilder,locator){
+ if(!errorImpl){
+ if(domBuilder instanceof DOMHandler){
+ return domBuilder;
+ }
+ errorImpl = domBuilder ;
+ }
+ var errorHandler = {}
+ var isCallback = errorImpl instanceof Function;
+ locator = locator||{}
+ function build(key){
+ var fn = errorImpl[key];
+ if(!fn){
+ if(isCallback){
+ fn = errorImpl.length == 2?function(msg){errorImpl(key,msg)}:errorImpl;
+ }else{
+ var i=arguments.length;
+ while(--i){
+ if(fn = errorImpl[arguments[i]]){
+ break;
+ }
+ }
+ }
+ }
+ errorHandler[key] = fn && function(msg){
+ fn(msg+_locator(locator), msg, locator);
+ }||function(){};
+ }
+ build('warning','warn');
+ build('error','warn','warning');
+ build('fatalError','warn','warning','error');
+ return errorHandler;
+}
+function DOMHandler() {
+ this.cdata = false;
+}
+function position(locator,node){
+ node.lineNumber = locator.lineNumber;
+ node.columnNumber = locator.columnNumber;
+}
+DOMHandler.prototype = {
+ startDocument : function() {
+ this.document = new DOMImplementation().createDocument(null, null, null);
+ if (this.locator) {
+ this.document.documentURI = this.locator.systemId;
+ }
+ },
+ startElement:function(namespaceURI, localName, qName, attrs) {
+ var doc = this.document;
+ var el = doc.createElementNS(namespaceURI, qName||localName);
+ var len = attrs.length;
+ appendElement(this, el);
+ this.currentElement = el;
+
+ this.locator && position(this.locator,el)
+ for (var i = 0 ; i < len; i++) {
+ var namespaceURI = attrs.getURI(i);
+ var value = attrs.getValue(i);
+ var qName = attrs.getQName(i);
+ var attr = doc.createAttributeNS(namespaceURI, qName);
+ if( attr.getOffset){
+ position(attr.getOffset(1),attr)
+ }
+ attr.value = attr.nodeValue = value;
+ el.setAttributeNode(attr)
+ }
+ },
+ endElement:function(namespaceURI, localName, qName) {
+ var current = this.currentElement
+ var tagName = current.tagName;
+ this.currentElement = current.parentNode;
+ },
+ startPrefixMapping:function(prefix, uri) {
+ },
+ endPrefixMapping:function(prefix) {
+ },
+ processingInstruction:function(target, data) {
+ var ins = this.document.createProcessingInstruction(target, data);
+ this.locator && position(this.locator,ins)
+ appendElement(this, ins);
+ },
+ ignorableWhitespace:function(ch, start, length) {
+ },
+ characters:function(chars, start, length) {
+ chars = _toString.apply(this,arguments)
+ if(this.currentElement && chars){
+ if (this.cdata) {
+ var charNode = this.document.createCDATASection(chars);
+ this.currentElement.appendChild(charNode);
+ } else {
+ var charNode = this.document.createTextNode(chars);
+ this.currentElement.appendChild(charNode);
+ }
+ this.locator && position(this.locator,charNode)
+ }
+ },
+ skippedEntity:function(name) {
+ },
+ endDocument:function() {
+ this.document.normalize();
+ },
+ setDocumentLocator:function (locator) {
+ if(this.locator = locator){// && !('lineNumber' in locator)){
+ locator.lineNumber = 0;
+ }
+ },
+ comment:function(chars, start, length) {
+ chars = _toString.apply(this,arguments)
+ var comm = this.document.createComment(chars);
+ this.locator && position(this.locator,comm)
+ appendElement(this, comm);
+ },
+
+ startCDATA:function() {
+ this.cdata = true;
+ },
+ endCDATA:function() {
+ this.cdata = false;
+ },
+
+ startDTD:function(name, publicId, systemId) {
+ var impl = this.document.implementation;
+ if (impl && impl.createDocumentType) {
+ var dt = impl.createDocumentType(name, publicId, systemId);
+ this.locator && position(this.locator,dt)
+ appendElement(this, dt);
+ }
+ },
+ warning:function(error) {
+ console.warn(error,_locator(this.locator));
+ },
+ error:function(error) {
+ console.error(error,_locator(this.locator));
+ },
+ fatalError:function(error) {
+ console.error(error,_locator(this.locator));
+ throw error;
+ }
+}
+function _locator(l){
+ if(l){
+ return '\n@'+(l.systemId ||'')+'#[line:'+l.lineNumber+',col:'+l.columnNumber+']'
+ }
+}
+function _toString(chars,start,length){
+ if(typeof chars == 'string'){
+ return chars.substr(start,length)
+ }else{//java sax connect width xmldom on rhino(what about: "? && !(chars instanceof String)")
+ if(chars.length >= start+length || start){
+ return new java.lang.String(chars,start,length)+'';
+ }
+ return chars;
+ }
+}
+"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(key){
+ DOMHandler.prototype[key] = function(){return null}
+})
+function appendElement (hander,node) {
+ if (!hander.currentElement) {
+ hander.document.appendChild(node);
+ } else {
+ hander.currentElement.appendChild(node);
+ }
+}//appendChild and setAttributeNS are preformance key
+
+return {
+ DOMParser: DOMParser
+ };
+});
+
+ace.define("ace/mode/xml_worker",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/worker/mirror","ace/mode/xml/dom-parser"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var lang = require("../lib/lang");
+var Mirror = require("../worker/mirror").Mirror;
+var DOMParser = require("./xml/dom-parser").DOMParser;
+
+var Worker = exports.Worker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(400);
+ this.context = null;
+};
+
+oop.inherits(Worker, Mirror);
+
+(function() {
+
+ this.setOptions = function(options) {
+ this.context = options.context;
+ };
+
+ this.onUpdate = function() {
+ var value = this.doc.getValue();
+ if (!value)
+ return;
+ var parser = new DOMParser();
+ var errors = [];
+ parser.options.errorHandler = {
+ fatalError: function(fullMsg, errorMsg, locator) {
+ errors.push({
+ row: locator.lineNumber,
+ column: locator.columnNumber,
+ text: errorMsg,
+ type: "error"
+ });
+ },
+ error: function(fullMsg, errorMsg, locator) {
+ errors.push({
+ row: locator.lineNumber,
+ column: locator.columnNumber,
+ text: errorMsg,
+ type: "error"
+ });
+ },
+ warning: function(fullMsg, errorMsg, locator) {
+ errors.push({
+ row: locator.lineNumber,
+ column: locator.columnNumber,
+ text: errorMsg,
+ type: "warning"
+ });
+ }
+ };
+
+ parser.parseFromString(value);
+ this.sender.emit("error", errors);
+ };
+
+}).call(Worker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ace/worker-xquery.js b/www/wiki/extensions/CodeEditor/modules/ace/worker-xquery.js
new file mode 100644
index 00000000..5f52793a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ace/worker-xquery.js
@@ -0,0 +1,58351 @@
+"no use strict";
+;(function(window) {
+if (typeof window.window != "undefined" && window.document)
+ return;
+if (window.require && window.define)
+ return;
+
+if (!window.console) {
+ window.console = function() {
+ var msgs = Array.prototype.slice.call(arguments, 0);
+ postMessage({type: "log", data: msgs});
+ };
+ window.console.error =
+ window.console.warn =
+ window.console.log =
+ window.console.trace = window.console;
+}
+window.window = window;
+window.ace = window;
+
+window.onerror = function(message, file, line, col, err) {
+ postMessage({type: "error", data: {
+ message: message,
+ data: err.data,
+ file: file,
+ line: line,
+ col: col,
+ stack: err.stack
+ }});
+};
+
+window.normalizeModule = function(parentId, moduleName) {
+ // normalize plugin requires
+ if (moduleName.indexOf("!") !== -1) {
+ var chunks = moduleName.split("!");
+ return window.normalizeModule(parentId, chunks[0]) + "!" + window.normalizeModule(parentId, chunks[1]);
+ }
+ // normalize relative requires
+ if (moduleName.charAt(0) == ".") {
+ var base = parentId.split("/").slice(0, -1).join("/");
+ moduleName = (base ? base + "/" : "") + moduleName;
+
+ while (moduleName.indexOf(".") !== -1 && previous != moduleName) {
+ var previous = moduleName;
+ moduleName = moduleName.replace(/^\.\//, "").replace(/\/\.\//, "/").replace(/[^\/]+\/\.\.\//, "");
+ }
+ }
+
+ return moduleName;
+};
+
+window.require = function require(parentId, id) {
+ if (!id) {
+ id = parentId;
+ parentId = null;
+ }
+ if (!id.charAt)
+ throw new Error("worker.js require() accepts only (parentId, id) as arguments");
+
+ id = window.normalizeModule(parentId, id);
+
+ var module = window.require.modules[id];
+ if (module) {
+ if (!module.initialized) {
+ module.initialized = true;
+ module.exports = module.factory().exports;
+ }
+ return module.exports;
+ }
+
+ if (!window.require.tlns)
+ return console.log("unable to load " + id);
+
+ var path = resolveModuleId(id, window.require.tlns);
+ if (path.slice(-3) != ".js") path += ".js";
+
+ window.require.id = id;
+ window.require.modules[id] = {}; // prevent infinite loop on broken modules
+ importScripts(path);
+ return window.require(parentId, id);
+};
+function resolveModuleId(id, paths) {
+ var testPath = id, tail = "";
+ while (testPath) {
+ var alias = paths[testPath];
+ if (typeof alias == "string") {
+ return alias + tail;
+ } else if (alias) {
+ return alias.location.replace(/\/*$/, "/") + (tail || alias.main || alias.name);
+ } else if (alias === false) {
+ return "";
+ }
+ var i = testPath.lastIndexOf("/");
+ if (i === -1) break;
+ tail = testPath.substr(i) + tail;
+ testPath = testPath.slice(0, i);
+ }
+ return id;
+}
+window.require.modules = {};
+window.require.tlns = {};
+
+window.define = function(id, deps, factory) {
+ if (arguments.length == 2) {
+ factory = deps;
+ if (typeof id != "string") {
+ deps = id;
+ id = window.require.id;
+ }
+ } else if (arguments.length == 1) {
+ factory = id;
+ deps = [];
+ id = window.require.id;
+ }
+
+ if (typeof factory != "function") {
+ window.require.modules[id] = {
+ exports: factory,
+ initialized: true
+ };
+ return;
+ }
+
+ if (!deps.length)
+ // If there is no dependencies, we inject "require", "exports" and
+ // "module" as dependencies, to provide CommonJS compatibility.
+ deps = ["require", "exports", "module"];
+
+ var req = function(childId) {
+ return window.require(id, childId);
+ };
+
+ window.require.modules[id] = {
+ exports: {},
+ factory: function() {
+ var module = this;
+ var returnExports = factory.apply(this, deps.map(function(dep) {
+ switch (dep) {
+ // Because "require", "exports" and "module" aren't actual
+ // dependencies, we must handle them seperately.
+ case "require": return req;
+ case "exports": return module.exports;
+ case "module": return module;
+ // But for all other dependencies, we can just go ahead and
+ // require them.
+ default: return req(dep);
+ }
+ }));
+ if (returnExports)
+ module.exports = returnExports;
+ return module;
+ }
+ };
+};
+window.define.amd = {};
+require.tlns = {};
+window.initBaseUrls = function initBaseUrls(topLevelNamespaces) {
+ for (var i in topLevelNamespaces)
+ require.tlns[i] = topLevelNamespaces[i];
+};
+
+window.initSender = function initSender() {
+
+ var EventEmitter = window.require("ace/lib/event_emitter").EventEmitter;
+ var oop = window.require("ace/lib/oop");
+
+ var Sender = function() {};
+
+ (function() {
+
+ oop.implement(this, EventEmitter);
+
+ this.callback = function(data, callbackId) {
+ postMessage({
+ type: "call",
+ id: callbackId,
+ data: data
+ });
+ };
+
+ this.emit = function(name, data) {
+ postMessage({
+ type: "event",
+ name: name,
+ data: data
+ });
+ };
+
+ }).call(Sender.prototype);
+
+ return new Sender();
+};
+
+var main = window.main = null;
+var sender = window.sender = null;
+
+window.onmessage = function(e) {
+ var msg = e.data;
+ if (msg.event && sender) {
+ sender._signal(msg.event, msg.data);
+ }
+ else if (msg.command) {
+ if (main[msg.command])
+ main[msg.command].apply(main, msg.args);
+ else if (window[msg.command])
+ window[msg.command].apply(window, msg.args);
+ else
+ throw new Error("Unknown command:" + msg.command);
+ }
+ else if (msg.init) {
+ window.initBaseUrls(msg.tlns);
+ require("ace/lib/es5-shim");
+ sender = window.sender = window.initSender();
+ var clazz = require(msg.module)[msg.classname];
+ main = window.main = new clazz(sender);
+ }
+};
+})(this);
+
+ace.define("ace/lib/oop",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.inherits = function(ctor, superCtor) {
+ ctor.super_ = superCtor;
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+};
+
+exports.mixin = function(obj, mixin) {
+ for (var key in mixin) {
+ obj[key] = mixin[key];
+ }
+ return obj;
+};
+
+exports.implement = function(proto, mixin) {
+ exports.mixin(proto, mixin);
+};
+
+});
+
+ace.define("ace/range",["require","exports","module"], function(require, exports, module) {
+"use strict";
+var comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+var Range = function(startRow, startColumn, endRow, endColumn) {
+ this.start = {
+ row: startRow,
+ column: startColumn
+ };
+
+ this.end = {
+ row: endRow,
+ column: endColumn
+ };
+};
+
+(function() {
+ this.isEqual = function(range) {
+ return this.start.row === range.start.row &&
+ this.end.row === range.end.row &&
+ this.start.column === range.start.column &&
+ this.end.column === range.end.column;
+ };
+ this.toString = function() {
+ return ("Range: [" + this.start.row + "/" + this.start.column +
+ "] -> [" + this.end.row + "/" + this.end.column + "]");
+ };
+
+ this.contains = function(row, column) {
+ return this.compare(row, column) == 0;
+ };
+ this.compareRange = function(range) {
+ var cmp,
+ end = range.end,
+ start = range.start;
+
+ cmp = this.compare(end.row, end.column);
+ if (cmp == 1) {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == 1) {
+ return 2;
+ } else if (cmp == 0) {
+ return 1;
+ } else {
+ return 0;
+ }
+ } else if (cmp == -1) {
+ return -2;
+ } else {
+ cmp = this.compare(start.row, start.column);
+ if (cmp == -1) {
+ return -1;
+ } else if (cmp == 1) {
+ return 42;
+ } else {
+ return 0;
+ }
+ }
+ };
+ this.comparePoint = function(p) {
+ return this.compare(p.row, p.column);
+ };
+ this.containsRange = function(range) {
+ return this.comparePoint(range.start) == 0 && this.comparePoint(range.end) == 0;
+ };
+ this.intersects = function(range) {
+ var cmp = this.compareRange(range);
+ return (cmp == -1 || cmp == 0 || cmp == 1);
+ };
+ this.isEnd = function(row, column) {
+ return this.end.row == row && this.end.column == column;
+ };
+ this.isStart = function(row, column) {
+ return this.start.row == row && this.start.column == column;
+ };
+ this.setStart = function(row, column) {
+ if (typeof row == "object") {
+ this.start.column = row.column;
+ this.start.row = row.row;
+ } else {
+ this.start.row = row;
+ this.start.column = column;
+ }
+ };
+ this.setEnd = function(row, column) {
+ if (typeof row == "object") {
+ this.end.column = row.column;
+ this.end.row = row.row;
+ } else {
+ this.end.row = row;
+ this.end.column = column;
+ }
+ };
+ this.inside = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column) || this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideStart = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isEnd(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.insideEnd = function(row, column) {
+ if (this.compare(row, column) == 0) {
+ if (this.isStart(row, column)) {
+ return false;
+ } else {
+ return true;
+ }
+ }
+ return false;
+ };
+ this.compare = function(row, column) {
+ if (!this.isMultiLine()) {
+ if (row === this.start.row) {
+ return column < this.start.column ? -1 : (column > this.end.column ? 1 : 0);
+ }
+ }
+
+ if (row < this.start.row)
+ return -1;
+
+ if (row > this.end.row)
+ return 1;
+
+ if (this.start.row === row)
+ return column >= this.start.column ? 0 : -1;
+
+ if (this.end.row === row)
+ return column <= this.end.column ? 0 : 1;
+
+ return 0;
+ };
+ this.compareStart = function(row, column) {
+ if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareEnd = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.compareInside = function(row, column) {
+ if (this.end.row == row && this.end.column == column) {
+ return 1;
+ } else if (this.start.row == row && this.start.column == column) {
+ return -1;
+ } else {
+ return this.compare(row, column);
+ }
+ };
+ this.clipRows = function(firstRow, lastRow) {
+ if (this.end.row > lastRow)
+ var end = {row: lastRow + 1, column: 0};
+ else if (this.end.row < firstRow)
+ var end = {row: firstRow, column: 0};
+
+ if (this.start.row > lastRow)
+ var start = {row: lastRow + 1, column: 0};
+ else if (this.start.row < firstRow)
+ var start = {row: firstRow, column: 0};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+ this.extend = function(row, column) {
+ var cmp = this.compare(row, column);
+
+ if (cmp == 0)
+ return this;
+ else if (cmp == -1)
+ var start = {row: row, column: column};
+ else
+ var end = {row: row, column: column};
+
+ return Range.fromPoints(start || this.start, end || this.end);
+ };
+
+ this.isEmpty = function() {
+ return (this.start.row === this.end.row && this.start.column === this.end.column);
+ };
+ this.isMultiLine = function() {
+ return (this.start.row !== this.end.row);
+ };
+ this.clone = function() {
+ return Range.fromPoints(this.start, this.end);
+ };
+ this.collapseRows = function() {
+ if (this.end.column == 0)
+ return new Range(this.start.row, 0, Math.max(this.start.row, this.end.row-1), 0)
+ else
+ return new Range(this.start.row, 0, this.end.row, 0)
+ };
+ this.toScreenRange = function(session) {
+ var screenPosStart = session.documentToScreenPosition(this.start);
+ var screenPosEnd = session.documentToScreenPosition(this.end);
+
+ return new Range(
+ screenPosStart.row, screenPosStart.column,
+ screenPosEnd.row, screenPosEnd.column
+ );
+ };
+ this.moveBy = function(row, column) {
+ this.start.row += row;
+ this.start.column += column;
+ this.end.row += row;
+ this.end.column += column;
+ };
+
+}).call(Range.prototype);
+Range.fromPoints = function(start, end) {
+ return new Range(start.row, start.column, end.row, end.column);
+};
+Range.comparePoints = comparePoints;
+
+Range.comparePoints = function(p1, p2) {
+ return p1.row - p2.row || p1.column - p2.column;
+};
+
+
+exports.Range = Range;
+});
+
+ace.define("ace/apply_delta",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+function throwDeltaError(delta, errorText){
+ console.log("Invalid Delta:", delta);
+ throw "Invalid Delta: " + errorText;
+}
+
+function positionInDocument(docLines, position) {
+ return position.row >= 0 && position.row < docLines.length &&
+ position.column >= 0 && position.column <= docLines[position.row].length;
+}
+
+function validateDelta(docLines, delta) {
+ if (delta.action != "insert" && delta.action != "remove")
+ throwDeltaError(delta, "delta.action must be 'insert' or 'remove'");
+ if (!(delta.lines instanceof Array))
+ throwDeltaError(delta, "delta.lines must be an Array");
+ if (!delta.start || !delta.end)
+ throwDeltaError(delta, "delta.start/end must be an present");
+ var start = delta.start;
+ if (!positionInDocument(docLines, delta.start))
+ throwDeltaError(delta, "delta.start must be contained in document");
+ var end = delta.end;
+ if (delta.action == "remove" && !positionInDocument(docLines, end))
+ throwDeltaError(delta, "delta.end must contained in document for 'remove' actions");
+ var numRangeRows = end.row - start.row;
+ var numRangeLastLineChars = (end.column - (numRangeRows == 0 ? start.column : 0));
+ if (numRangeRows != delta.lines.length - 1 || delta.lines[numRangeRows].length != numRangeLastLineChars)
+ throwDeltaError(delta, "delta.range must match delta lines");
+}
+
+exports.applyDelta = function(docLines, delta, doNotValidate) {
+
+ var row = delta.start.row;
+ var startColumn = delta.start.column;
+ var line = docLines[row] || "";
+ switch (delta.action) {
+ case "insert":
+ var lines = delta.lines;
+ if (lines.length === 1) {
+ docLines[row] = line.substring(0, startColumn) + delta.lines[0] + line.substring(startColumn);
+ } else {
+ var args = [row, 1].concat(delta.lines);
+ docLines.splice.apply(docLines, args);
+ docLines[row] = line.substring(0, startColumn) + docLines[row];
+ docLines[row + delta.lines.length - 1] += line.substring(startColumn);
+ }
+ break;
+ case "remove":
+ var endColumn = delta.end.column;
+ var endRow = delta.end.row;
+ if (row === endRow) {
+ docLines[row] = line.substring(0, startColumn) + line.substring(endColumn);
+ } else {
+ docLines.splice(
+ row, endRow - row + 1,
+ line.substring(0, startColumn) + docLines[endRow].substring(endColumn)
+ );
+ }
+ break;
+ }
+}
+});
+
+ace.define("ace/lib/event_emitter",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+var EventEmitter = {};
+var stopPropagation = function() { this.propagationStopped = true; };
+var preventDefault = function() { this.defaultPrevented = true; };
+
+EventEmitter._emit =
+EventEmitter._dispatchEvent = function(eventName, e) {
+ this._eventRegistry || (this._eventRegistry = {});
+ this._defaultHandlers || (this._defaultHandlers = {});
+
+ var listeners = this._eventRegistry[eventName] || [];
+ var defaultHandler = this._defaultHandlers[eventName];
+ if (!listeners.length && !defaultHandler)
+ return;
+
+ if (typeof e != "object" || !e)
+ e = {};
+
+ if (!e.type)
+ e.type = eventName;
+ if (!e.stopPropagation)
+ e.stopPropagation = stopPropagation;
+ if (!e.preventDefault)
+ e.preventDefault = preventDefault;
+
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++) {
+ listeners[i](e, this);
+ if (e.propagationStopped)
+ break;
+ }
+
+ if (defaultHandler && !e.defaultPrevented)
+ return defaultHandler(e, this);
+};
+
+
+EventEmitter._signal = function(eventName, e) {
+ var listeners = (this._eventRegistry || {})[eventName];
+ if (!listeners)
+ return;
+ listeners = listeners.slice();
+ for (var i=0; i<listeners.length; i++)
+ listeners[i](e, this);
+};
+
+EventEmitter.once = function(eventName, callback) {
+ var _self = this;
+ callback && this.addEventListener(eventName, function newCallback() {
+ _self.removeEventListener(eventName, newCallback);
+ callback.apply(null, arguments);
+ });
+};
+
+
+EventEmitter.setDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ handlers = this._defaultHandlers = {_disabled_: {}};
+
+ if (handlers[eventName]) {
+ var old = handlers[eventName];
+ var disabled = handlers._disabled_[eventName];
+ if (!disabled)
+ handlers._disabled_[eventName] = disabled = [];
+ disabled.push(old);
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+ handlers[eventName] = callback;
+};
+EventEmitter.removeDefaultHandler = function(eventName, callback) {
+ var handlers = this._defaultHandlers
+ if (!handlers)
+ return;
+ var disabled = handlers._disabled_[eventName];
+
+ if (handlers[eventName] == callback) {
+ var old = handlers[eventName];
+ if (disabled)
+ this.setDefaultHandler(eventName, disabled.pop());
+ } else if (disabled) {
+ var i = disabled.indexOf(callback);
+ if (i != -1)
+ disabled.splice(i, 1);
+ }
+};
+
+EventEmitter.on =
+EventEmitter.addEventListener = function(eventName, callback, capturing) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ listeners = this._eventRegistry[eventName] = [];
+
+ if (listeners.indexOf(callback) == -1)
+ listeners[capturing ? "unshift" : "push"](callback);
+ return callback;
+};
+
+EventEmitter.off =
+EventEmitter.removeListener =
+EventEmitter.removeEventListener = function(eventName, callback) {
+ this._eventRegistry = this._eventRegistry || {};
+
+ var listeners = this._eventRegistry[eventName];
+ if (!listeners)
+ return;
+
+ var index = listeners.indexOf(callback);
+ if (index !== -1)
+ listeners.splice(index, 1);
+};
+
+EventEmitter.removeAllListeners = function(eventName) {
+ if (this._eventRegistry) this._eventRegistry[eventName] = [];
+};
+
+exports.EventEmitter = EventEmitter;
+
+});
+
+ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+ this.getDocument = function() {
+ return this.document;
+ };
+ this.$insertRight = false;
+ this.onChange = function(delta) {
+ if (delta.start.row == delta.end.row && delta.start.row != this.row)
+ return;
+
+ if (delta.start.row > this.row)
+ return;
+
+ var point = $getTransformedPoint(delta, {row: this.row, column: this.column}, this.$insertRight);
+ this.setPosition(point.row, point.column, true);
+ };
+
+ function $pointsInOrder(point1, point2, equalPointsInOrder) {
+ var bColIsAfter = equalPointsInOrder ? point1.column <= point2.column : point1.column < point2.column;
+ return (point1.row < point2.row) || (point1.row == point2.row && bColIsAfter);
+ }
+
+ function $getTransformedPoint(delta, point, moveIfEqual) {
+ var deltaIsInsert = delta.action == "insert";
+ var deltaRowShift = (deltaIsInsert ? 1 : -1) * (delta.end.row - delta.start.row);
+ var deltaColShift = (deltaIsInsert ? 1 : -1) * (delta.end.column - delta.start.column);
+ var deltaStart = delta.start;
+ var deltaEnd = deltaIsInsert ? deltaStart : delta.end; // Collapse insert range.
+ if ($pointsInOrder(point, deltaStart, moveIfEqual)) {
+ return {
+ row: point.row,
+ column: point.column
+ };
+ }
+ if ($pointsInOrder(deltaEnd, point, !moveIfEqual)) {
+ return {
+ row: point.row + deltaRowShift,
+ column: point.column + (point.row == deltaEnd.row ? deltaColShift : 0)
+ };
+ }
+
+ return {
+ row: deltaStart.row,
+ column: deltaStart.column
+ };
+ }
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._signal("change", {
+ old: old,
+ value: pos
+ });
+ };
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
+
+ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/apply_delta","ace/lib/event_emitter","ace/range","ace/anchor"], function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var applyDelta = require("./apply_delta").applyDelta;
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+var Range = require("./range").Range;
+var Anchor = require("./anchor").Anchor;
+
+var Document = function(textOrLines) {
+ this.$lines = [""];
+ if (textOrLines.length === 0) {
+ this.$lines = [""];
+ } else if (Array.isArray(textOrLines)) {
+ this.insertMergedLines({row: 0, column: 0}, textOrLines);
+ } else {
+ this.insert({row: 0, column:0}, textOrLines);
+ }
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+ this.setValue = function(text) {
+ var len = this.getLength() - 1;
+ this.remove(new Range(0, 0, len, this.getLine(len).length));
+ this.insert({row: 0, column: 0}, text);
+ };
+ this.getValue = function() {
+ return this.getAllLines().join(this.getNewLineCharacter());
+ };
+ this.createAnchor = function(row, column) {
+ return new Anchor(this, row, column);
+ };
+ if ("aaa".split(/a/).length === 0) {
+ this.$split = function(text) {
+ return text.replace(/\r\n|\r/g, "\n").split("\n");
+ };
+ } else {
+ this.$split = function(text) {
+ return text.split(/\r\n|\r|\n/);
+ };
+ }
+
+
+ this.$detectNewLine = function(text) {
+ var match = text.match(/^.*?(\r\n|\r|\n)/m);
+ this.$autoNewLine = match ? match[1] : "\n";
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineCharacter = function() {
+ switch (this.$newLineMode) {
+ case "windows":
+ return "\r\n";
+ case "unix":
+ return "\n";
+ default:
+ return this.$autoNewLine || "\n";
+ }
+ };
+
+ this.$autoNewLine = "";
+ this.$newLineMode = "auto";
+ this.setNewLineMode = function(newLineMode) {
+ if (this.$newLineMode === newLineMode)
+ return;
+
+ this.$newLineMode = newLineMode;
+ this._signal("changeNewLineMode");
+ };
+ this.getNewLineMode = function() {
+ return this.$newLineMode;
+ };
+ this.isNewLine = function(text) {
+ return (text == "\r\n" || text == "\r" || text == "\n");
+ };
+ this.getLine = function(row) {
+ return this.$lines[row] || "";
+ };
+ this.getLines = function(firstRow, lastRow) {
+ return this.$lines.slice(firstRow, lastRow + 1);
+ };
+ this.getAllLines = function() {
+ return this.getLines(0, this.getLength());
+ };
+ this.getLength = function() {
+ return this.$lines.length;
+ };
+ this.getTextRange = function(range) {
+ return this.getLinesForRange(range).join(this.getNewLineCharacter());
+ };
+ this.getLinesForRange = function(range) {
+ var lines;
+ if (range.start.row === range.end.row) {
+ lines = [this.getLine(range.start.row).substring(range.start.column, range.end.column)];
+ } else {
+ lines = this.getLines(range.start.row, range.end.row);
+ lines[0] = (lines[0] || "").substring(range.start.column);
+ var l = lines.length - 1;
+ if (range.end.row - range.start.row == l)
+ lines[l] = lines[l].substring(0, range.end.column);
+ }
+ return lines;
+ };
+ this.insertLines = function(row, lines) {
+ console.warn("Use of document.insertLines is deprecated. Use the insertFullLines method instead.");
+ return this.insertFullLines(row, lines);
+ };
+ this.removeLines = function(firstRow, lastRow) {
+ console.warn("Use of document.removeLines is deprecated. Use the removeFullLines method instead.");
+ return this.removeFullLines(firstRow, lastRow);
+ };
+ this.insertNewLine = function(position) {
+ console.warn("Use of document.insertNewLine is deprecated. Use insertMergedLines(position, ['', '']) instead.");
+ return this.insertMergedLines(position, ["", ""]);
+ };
+ this.insert = function(position, text) {
+ if (this.getLength() <= 1)
+ this.$detectNewLine(text);
+
+ return this.insertMergedLines(position, this.$split(text));
+ };
+ this.insertInLine = function(position, text) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = this.pos(position.row, position.column + text.length);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: [text]
+ }, true);
+
+ return this.clonePos(end);
+ };
+
+ this.clippedPos = function(row, column) {
+ var length = this.getLength();
+ if (row === undefined) {
+ row = length;
+ } else if (row < 0) {
+ row = 0;
+ } else if (row >= length) {
+ row = length - 1;
+ column = undefined;
+ }
+ var line = this.getLine(row);
+ if (column == undefined)
+ column = line.length;
+ column = Math.min(Math.max(column, 0), line.length);
+ return {row: row, column: column};
+ };
+
+ this.clonePos = function(pos) {
+ return {row: pos.row, column: pos.column};
+ };
+
+ this.pos = function(row, column) {
+ return {row: row, column: column};
+ };
+
+ this.$clipPosition = function(position) {
+ var length = this.getLength();
+ if (position.row >= length) {
+ position.row = Math.max(0, length - 1);
+ position.column = this.getLine(length - 1).length;
+ } else {
+ position.row = Math.max(0, position.row);
+ position.column = Math.min(Math.max(position.column, 0), this.getLine(position.row).length);
+ }
+ return position;
+ };
+ this.insertFullLines = function(row, lines) {
+ row = Math.min(Math.max(row, 0), this.getLength());
+ var column = 0;
+ if (row < this.getLength()) {
+ lines = lines.concat([""]);
+ column = 0;
+ } else {
+ lines = [""].concat(lines);
+ row--;
+ column = this.$lines[row].length;
+ }
+ this.insertMergedLines({row: row, column: column}, lines);
+ };
+ this.insertMergedLines = function(position, lines) {
+ var start = this.clippedPos(position.row, position.column);
+ var end = {
+ row: start.row + lines.length - 1,
+ column: (lines.length == 1 ? start.column : 0) + lines[lines.length - 1].length
+ };
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "insert",
+ lines: lines
+ });
+
+ return this.clonePos(end);
+ };
+ this.remove = function(range) {
+ var start = this.clippedPos(range.start.row, range.start.column);
+ var end = this.clippedPos(range.end.row, range.end.column);
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ });
+ return this.clonePos(start);
+ };
+ this.removeInLine = function(row, startColumn, endColumn) {
+ var start = this.clippedPos(row, startColumn);
+ var end = this.clippedPos(row, endColumn);
+
+ this.applyDelta({
+ start: start,
+ end: end,
+ action: "remove",
+ lines: this.getLinesForRange({start: start, end: end})
+ }, true);
+
+ return this.clonePos(start);
+ };
+ this.removeFullLines = function(firstRow, lastRow) {
+ firstRow = Math.min(Math.max(0, firstRow), this.getLength() - 1);
+ lastRow = Math.min(Math.max(0, lastRow ), this.getLength() - 1);
+ var deleteFirstNewLine = lastRow == this.getLength() - 1 && firstRow > 0;
+ var deleteLastNewLine = lastRow < this.getLength() - 1;
+ var startRow = ( deleteFirstNewLine ? firstRow - 1 : firstRow );
+ var startCol = ( deleteFirstNewLine ? this.getLine(startRow).length : 0 );
+ var endRow = ( deleteLastNewLine ? lastRow + 1 : lastRow );
+ var endCol = ( deleteLastNewLine ? 0 : this.getLine(endRow).length );
+ var range = new Range(startRow, startCol, endRow, endCol);
+ var deletedLines = this.$lines.slice(firstRow, lastRow + 1);
+
+ this.applyDelta({
+ start: range.start,
+ end: range.end,
+ action: "remove",
+ lines: this.getLinesForRange(range)
+ });
+ return deletedLines;
+ };
+ this.removeNewLine = function(row) {
+ if (row < this.getLength() - 1 && row >= 0) {
+ this.applyDelta({
+ start: this.pos(row, this.getLine(row).length),
+ end: this.pos(row + 1, 0),
+ action: "remove",
+ lines: ["", ""]
+ });
+ }
+ };
+ this.replace = function(range, text) {
+ if (!(range instanceof Range))
+ range = Range.fromPoints(range.start, range.end);
+ if (text.length === 0 && range.isEmpty())
+ return range.start;
+ if (text == this.getTextRange(range))
+ return range.end;
+
+ this.remove(range);
+ var end;
+ if (text) {
+ end = this.insert(range.start, text);
+ }
+ else {
+ end = range.start;
+ }
+
+ return end;
+ };
+ this.applyDeltas = function(deltas) {
+ for (var i=0; i<deltas.length; i++) {
+ this.applyDelta(deltas[i]);
+ }
+ };
+ this.revertDeltas = function(deltas) {
+ for (var i=deltas.length-1; i>=0; i--) {
+ this.revertDelta(deltas[i]);
+ }
+ };
+ this.applyDelta = function(delta, doNotValidate) {
+ var isInsert = delta.action == "insert";
+ if (isInsert ? delta.lines.length <= 1 && !delta.lines[0]
+ : !Range.comparePoints(delta.start, delta.end)) {
+ return;
+ }
+
+ if (isInsert && delta.lines.length > 20000)
+ this.$splitAndapplyLargeDelta(delta, 20000);
+ applyDelta(this.$lines, delta, doNotValidate);
+ this._signal("change", delta);
+ };
+
+ this.$splitAndapplyLargeDelta = function(delta, MAX) {
+ var lines = delta.lines;
+ var l = lines.length;
+ var row = delta.start.row;
+ var column = delta.start.column;
+ var from = 0, to = 0;
+ do {
+ from = to;
+ to += MAX - 1;
+ var chunk = lines.slice(from, to);
+ if (to > l) {
+ delta.lines = chunk;
+ delta.start.row = row + from;
+ delta.start.column = column;
+ break;
+ }
+ chunk.push("");
+ this.applyDelta({
+ start: this.pos(row + from, column),
+ end: this.pos(row + to, column = 0),
+ action: delta.action,
+ lines: chunk
+ }, true);
+ } while(true);
+ };
+ this.revertDelta = function(delta) {
+ this.applyDelta({
+ start: this.clonePos(delta.start),
+ end: this.clonePos(delta.end),
+ action: (delta.action == "insert" ? "remove" : "insert"),
+ lines: delta.lines.slice()
+ });
+ };
+ this.indexToPosition = function(index, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ for (var i = startRow || 0, l = lines.length; i < l; i++) {
+ index -= lines[i].length + newlineLength;
+ if (index < 0)
+ return {row: i, column: index + lines[i].length + newlineLength};
+ }
+ return {row: l-1, column: lines[l-1].length};
+ };
+ this.positionToIndex = function(pos, startRow) {
+ var lines = this.$lines || this.getAllLines();
+ var newlineLength = this.getNewLineCharacter().length;
+ var index = 0;
+ var row = Math.min(pos.row, lines.length);
+ for (var i = startRow || 0; i < row; ++i)
+ index += lines[i].length + newlineLength;
+
+ return index + pos.column;
+ };
+
+}).call(Document.prototype);
+
+exports.Document = Document;
+});
+
+ace.define("ace/lib/lang",["require","exports","module"], function(require, exports, module) {
+"use strict";
+
+exports.last = function(a) {
+ return a[a.length - 1];
+};
+
+exports.stringReverse = function(string) {
+ return string.split("").reverse().join("");
+};
+
+exports.stringRepeat = function (string, count) {
+ var result = '';
+ while (count > 0) {
+ if (count & 1)
+ result += string;
+
+ if (count >>= 1)
+ string += string;
+ }
+ return result;
+};
+
+var trimBeginRegexp = /^\s\s*/;
+var trimEndRegexp = /\s\s*$/;
+
+exports.stringTrimLeft = function (string) {
+ return string.replace(trimBeginRegexp, '');
+};
+
+exports.stringTrimRight = function (string) {
+ return string.replace(trimEndRegexp, '');
+};
+
+exports.copyObject = function(obj) {
+ var copy = {};
+ for (var key in obj) {
+ copy[key] = obj[key];
+ }
+ return copy;
+};
+
+exports.copyArray = function(array){
+ var copy = [];
+ for (var i=0, l=array.length; i<l; i++) {
+ if (array[i] && typeof array[i] == "object")
+ copy[i] = this.copyObject(array[i]);
+ else
+ copy[i] = array[i];
+ }
+ return copy;
+};
+
+exports.deepCopy = function deepCopy(obj) {
+ if (typeof obj !== "object" || !obj)
+ return obj;
+ var copy;
+ if (Array.isArray(obj)) {
+ copy = [];
+ for (var key = 0; key < obj.length; key++) {
+ copy[key] = deepCopy(obj[key]);
+ }
+ return copy;
+ }
+ if (Object.prototype.toString.call(obj) !== "[object Object]")
+ return obj;
+
+ copy = {};
+ for (var key in obj)
+ copy[key] = deepCopy(obj[key]);
+ return copy;
+};
+
+exports.arrayToMap = function(arr) {
+ var map = {};
+ for (var i=0; i<arr.length; i++) {
+ map[arr[i]] = 1;
+ }
+ return map;
+
+};
+
+exports.createMap = function(props) {
+ var map = Object.create(null);
+ for (var i in props) {
+ map[i] = props[i];
+ }
+ return map;
+};
+exports.arrayRemove = function(array, value) {
+ for (var i = 0; i <= array.length; i++) {
+ if (value === array[i]) {
+ array.splice(i, 1);
+ }
+ }
+};
+
+exports.escapeRegExp = function(str) {
+ return str.replace(/([.*+?^${}()|[\]\/\\])/g, '\\$1');
+};
+
+exports.escapeHTML = function(str) {
+ return str.replace(/&/g, "&#38;").replace(/"/g, "&#34;").replace(/'/g, "&#39;").replace(/</g, "&#60;");
+};
+
+exports.getMatchOffsets = function(string, regExp) {
+ var matches = [];
+
+ string.replace(regExp, function(str) {
+ matches.push({
+ offset: arguments[arguments.length-2],
+ length: str.length
+ });
+ });
+
+ return matches;
+};
+exports.deferredCall = function(fcn) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var deferred = function(timeout) {
+ deferred.cancel();
+ timer = setTimeout(callback, timeout || 0);
+ return deferred;
+ };
+
+ deferred.schedule = deferred;
+
+ deferred.call = function() {
+ this.cancel();
+ fcn();
+ return deferred;
+ };
+
+ deferred.cancel = function() {
+ clearTimeout(timer);
+ timer = null;
+ return deferred;
+ };
+
+ deferred.isPending = function() {
+ return timer;
+ };
+
+ return deferred;
+};
+
+
+exports.delayedCall = function(fcn, defaultTimeout) {
+ var timer = null;
+ var callback = function() {
+ timer = null;
+ fcn();
+ };
+
+ var _self = function(timeout) {
+ if (timer == null)
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+
+ _self.delay = function(timeout) {
+ timer && clearTimeout(timer);
+ timer = setTimeout(callback, timeout || defaultTimeout);
+ };
+ _self.schedule = _self;
+
+ _self.call = function() {
+ this.cancel();
+ fcn();
+ };
+
+ _self.cancel = function() {
+ timer && clearTimeout(timer);
+ timer = null;
+ };
+
+ _self.isPending = function() {
+ return timer;
+ };
+
+ return _self;
+};
+});
+
+ace.define("ace/worker/mirror",["require","exports","module","ace/range","ace/document","ace/lib/lang"], function(require, exports, module) {
+"use strict";
+
+var Range = require("../range").Range;
+var Document = require("../document").Document;
+var lang = require("../lib/lang");
+
+var Mirror = exports.Mirror = function(sender) {
+ this.sender = sender;
+ var doc = this.doc = new Document("");
+
+ var deferredUpdate = this.deferredUpdate = lang.delayedCall(this.onUpdate.bind(this));
+
+ var _self = this;
+ sender.on("change", function(e) {
+ var data = e.data;
+ if (data[0].start) {
+ doc.applyDeltas(data);
+ } else {
+ for (var i = 0; i < data.length; i += 2) {
+ if (Array.isArray(data[i+1])) {
+ var d = {action: "insert", start: data[i], lines: data[i+1]};
+ } else {
+ var d = {action: "remove", start: data[i], end: data[i+1]};
+ }
+ doc.applyDelta(d, true);
+ }
+ }
+ if (_self.$timeout)
+ return deferredUpdate.schedule(_self.$timeout);
+ _self.onUpdate();
+ });
+};
+
+(function() {
+
+ this.$timeout = 500;
+
+ this.setTimeout = function(timeout) {
+ this.$timeout = timeout;
+ };
+
+ this.setValue = function(value) {
+ this.doc.setValue(value);
+ this.deferredUpdate.schedule(this.$timeout);
+ };
+
+ this.getValue = function(callbackId) {
+ this.sender.callback(this.doc.getValue(), callbackId);
+ };
+
+ this.onUpdate = function() {
+ };
+
+ this.isPending = function() {
+ return this.deferredUpdate.isPending();
+ };
+
+}).call(Mirror.prototype);
+
+});
+
+ace.define("ace/mode/xquery/xqlint",["require","exports","module"], function(require, exports, module) {
+module.exports = (function outer (modules, cache, entry) {
+ var previousRequire = typeof require == "function" && require;
+ function newRequire(name, jumped){
+ if(!cache[name]) {
+ if(!modules[name]) {
+ var currentRequire = typeof require == "function" && require;
+ if (!jumped && currentRequire) return currentRequire(name, true);
+ if (previousRequire) return previousRequire(name, true);
+ var err = new Error('Cannot find module \'' + name + '\'');
+ err.code = 'MODULE_NOT_FOUND';
+ throw err;
+ }
+ var m = cache[name] = {exports:{}};
+ modules[name][0].call(m.exports, function(x){
+ var id = modules[name][1][x];
+ return newRequire(id ? id : x);
+ },m,m.exports,outer,modules,cache,entry);
+ }
+ return cache[name].exports;
+ }
+ for(var i=0;i<entry.length;i++) newRequire(entry[i]);
+ return newRequire(entry[0]);
+})
+({"/node_modules/xqlint/lib/compiler/errors.js":[function(_dereq_,module,exports){
+'use strict';
+
+var init = function(that, code, message, pos, type){
+ if(!code) {
+ throw new Error(type + ' code is missing.');
+ }
+
+ if(!message) {
+ throw new Error(type + ' message is missing.');
+ }
+
+ if(!pos) {
+ throw new Error(type + ' position is missing.');
+ }
+
+ that.getCode = function(){
+ return code;
+ };
+
+ that.getMessage = function(){
+ return message;
+ };
+
+ that.getPos = function(){
+ return pos;
+ };
+};
+
+var StaticError = {};
+var StaticWarning = {};
+StaticError.prototype = new Error();
+StaticWarning.prototype = new Error();
+
+exports.StaticError = StaticError.prototype.constructor = function(code, message, pos) {
+ init(this, code, message, pos, 'Error');
+};
+
+exports.StaticWarning = StaticWarning.prototype.constructor = function(code, message, pos) {
+ init(this, code, message, pos, 'Warning');
+};
+},{}],"/node_modules/xqlint/lib/compiler/handlers.js":[function(_dereq_,module,exports){
+'use strict';
+
+var TreeOps = _dereq_('../tree_ops').TreeOps;
+var Errors = _dereq_('./errors');
+var StaticWarning = Errors.StaticWarning;
+exports.ModuleDecl = function(translator, rootSctx, node){
+ var prefix = '';
+ return {
+ NCName: function(ncname){
+ prefix = TreeOps.flatten(ncname);
+ },
+
+ URILiteral: function(uri) {
+ uri = TreeOps.flatten(uri);
+ uri = uri.substring(1, uri.length - 1);
+ translator.apply(function(){
+ rootSctx.moduleNamespace = uri;
+ rootSctx.addNamespace(uri, prefix, node.pos, 'moduleDecl');
+ });
+ }
+ };
+};
+
+exports.ModuleImport = function(translator, rootSctx, node) {
+ var prefix = '';
+ var moduleURI;
+
+ return {
+ NCName: function(ncname){
+ prefix = TreeOps.flatten(ncname);
+ },
+
+ URILiteral: function(uri) {
+ if(moduleURI !== undefined) {
+ return;
+ }
+ uri = TreeOps.flatten(uri);
+ uri = uri.substring(1, uri.length - 1);
+ moduleURI = uri;
+ translator.apply(function(){
+ rootSctx.importModule(uri, prefix, node.pos);
+ });
+ }
+ };
+};
+
+exports.SchemaImport = function(translator, rootSctx, node) {
+ var prefix = '';
+ var schemaURI;
+
+ return {
+ SchemaPrefix: function(schemaPrefix) {
+ var SchemaPrefixHandler = function () {
+ this.NCName = function (ncname) {
+ prefix = TreeOps.flatten(ncname);
+ };
+ };
+ translator.visitChildren(schemaPrefix, new SchemaPrefixHandler());
+ },
+
+ URILiteral: function(uri) {
+ if(schemaURI !== undefined) {
+ return;
+ }
+ uri = TreeOps.flatten(uri);
+ uri = uri.substring(1, uri.length - 1);
+ schemaURI = uri;
+ translator.apply(function(){
+ rootSctx.addNamespace(uri, prefix, node.pos, 'schema');
+ });
+ }
+ };
+};
+
+exports.DefaultNamespaceDecl = function(translator, rootSctx, node) {
+ var fn = false;
+ var ns = '';
+
+ return {
+ TOKEN: function(token){
+ fn = fn ? true : (token.value === 'function');
+ },
+ URILiteral: function(uri){
+ ns = TreeOps.flatten(uri);
+ ns = ns.substring(1, ns.length - 1);
+ if(!fn) {
+ translator.apply(function(){
+ throw new StaticWarning('W06', 'Avoid default element namespace declarations.', node.pos);
+ });
+ rootSctx.defaultElementNamespace = ns;
+ } else {
+ rootSctx.defaultFunctionNamespace = ns;
+ }
+ }
+ };
+};
+
+exports.NamespaceDecl = function(translator, rootSctx, node) {
+ var prefix = '';
+ return {
+ NCName: function(ncname) {
+ prefix = TreeOps.flatten(ncname);
+ },
+ URILiteral: function(uri) {
+ uri = TreeOps.flatten(uri);
+ uri = uri.substring(1, uri.length - 1);
+ translator.apply(function(){
+ rootSctx.addNamespace(uri, prefix, node.pos, 'declare');
+ });
+ }
+ };
+};
+exports.VarHandler = function(translator, sctx, node){
+ var EQNameHandler = function(eqname){
+ var value = TreeOps.flatten(eqname);
+ translator.apply(function(){
+ var qname = sctx.resolveQName(value, eqname.pos);
+ sctx.addVariable(qname, node.name, eqname.pos);
+ });
+ };
+ return {
+ ExprSingle: function(){ return true; },
+ VarValue: function(){ return true; },
+ VarDefaultValue: function(){ return true; },
+ VarName: EQNameHandler,
+ EQName: EQNameHandler
+ };
+};
+
+exports.VarRefHandler = function(translator, sctx, node){
+ return {
+ VarName: function(eqname){
+ var value = TreeOps.flatten(eqname);
+ translator.apply(function(){
+ var qname = sctx.resolveQName(value, node.pos);
+ if(qname.uri !== '') {
+ sctx.root.namespaces[qname.uri].used = true;
+ }
+ sctx.addVarRef(qname, eqname.pos);
+ });
+ }
+ };
+};
+},{"../tree_ops":"/node_modules/xqlint/lib/tree_ops.js","./errors":"/node_modules/xqlint/lib/compiler/errors.js"}],"/node_modules/xqlint/lib/compiler/schema_built-in_types.js":[function(_dereq_,module,exports){
+'use strict';
+exports.getSchemaBuiltinTypes = function(){
+ var ns = 'http://www.w3.org/2001/XMLSchema';
+ var SchemaBuiltinTypes = {};
+ SchemaBuiltinTypes[ns] = {
+ variables: {},
+ functions: {}
+ };
+ SchemaBuiltinTypes[ns].functions[ns + '#string#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'string', arity: 1, eqname: { uri: ns, name: 'string' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#boolean#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'boolean', arity: 1, eqname: { uri: ns, name: 'boolean' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#decimal#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'decimal', arity: 1, eqname: { uri: ns, name: 'decimal' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#float#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'float', arity: 1, eqname: { uri: ns, name: 'float' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#double#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'double', arity: 1, eqname: { uri: ns, name: 'double' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#duration#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'duration', arity: 1, eqname: { uri: ns, name: 'duration' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#dateTime#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'dateTime', arity: 1, eqname: { uri: ns, name: 'dateTime' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#time#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'time', arity: 1, eqname: { uri: ns, name: 'time' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#date#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'date', arity: 1, eqname: { uri: ns, name: 'date' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#gYearMonth#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'gYearMonth', arity: 1, eqname: { uri: ns, name: 'gYearMonth' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#gYear#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'gYear', arity: 1, eqname: { uri: ns, name: 'gYear' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#gMonthDay#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'gMonthDay', arity: 1, eqname: { uri: ns, name: 'gMonthDay' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#gDay#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'gDay', arity: 1, eqname: { uri: ns, name: 'gDay' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#gMonth#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'gMonth', arity: 1, eqname: { uri: ns, name: 'gMonth' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#hexBinary#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'hexBinary', arity: 1, eqname: { uri: ns, name: 'hexBinary' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#base64Binary#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'base64Binary', arity: 1, eqname: { uri: ns, name: 'base64Binary' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#anyURI#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'anyURI', arity: 1, eqname: { uri: ns, name: 'anyURI' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#QName#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'QName', arity: 1, eqname: { uri: ns, name: 'QName' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#normalizedString#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'normalizedString', arity: 1, eqname: { uri: ns, name: 'normalizedString' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#token#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'token', arity: 1, eqname: { uri: ns, name: 'token' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#language#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'language', arity: 1, eqname: { uri: ns, name: 'language' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#NMTOKEN#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'NMTOKEN', arity: 1, eqname: { uri: ns, name: 'NMTOKEN' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#Name#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'Name', arity: 1, eqname: { uri: ns, name: 'Name' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#NCName#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'NCName', arity: 1, eqname: { uri: ns, name: 'NCName' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#ID#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'ID', arity: 1, eqname: { uri: ns, name: 'ID' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#IDREF#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'IDREF', arity: 1, eqname: { uri: ns, name: 'IDREF' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#ENTITY#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'ENTITY', arity: 1, eqname: { uri: ns, name: 'ENTITY' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#integer#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'integer', arity: 1, eqname: { uri: ns, name: 'integer' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#nonPositiveInteger#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'nonPositiveInteger', arity: 1, eqname: { uri: ns, name: 'nonPositiveInteger' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#negativeInteger#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'negativeInteger', arity: 1, eqname: { uri: ns, name: 'negativeInteger' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#long#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'long', arity: 1, eqname: { uri: ns, name: 'long' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#int#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'int', arity: 1, eqname: { uri: ns, name: 'int' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#short#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'short', arity: 1, eqname: { uri: ns, name: 'short' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#byte#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'byte', arity: 1, eqname: { uri: ns, name: 'byte' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#nonNegativeInteger#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'nonNegativeInteger', arity: 1, eqname: { uri: ns, name: 'nonNegativeInteger' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#unsignedLong#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'unsignedLong', arity: 1, eqname: { uri: ns, name: 'unsignedLong' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#unsignedInt#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'unsignedInt', arity: 1, eqname: { uri: ns, name: 'unsignedInt' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#unsignedShort#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'unsignedShort', arity: 1, eqname: { uri: ns, name: 'unsignedShort' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#unsignedByte#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'unsignedByte', arity: 1, eqname: { uri: ns, name: 'unsignedByte' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#positiveInteger#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'positiveInteger', arity: 1, eqname: { uri: ns, name: 'positiveInteger' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#yearMonthDuration#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'yearMonthDuration', arity: 1, eqname: { uri: ns, name: 'yearMonthDuration' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#dayTimeDuration#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'dayTimeDuration', arity: 1, eqname: { uri: ns, name: 'dayTimeDuration' } };
+ SchemaBuiltinTypes[ns].functions[ns + '#untypedAtomic#1'] = { params: ['$arg as xs:anyAtomicType?'], annotations: [], name: 'untypedAtomic', arity: 1, eqname: { uri: ns, name: 'untypedAtomic' } };
+ return SchemaBuiltinTypes;
+};
+},{}],"/node_modules/xqlint/lib/compiler/static_context.js":[function(_dereq_,module,exports){
+exports.StaticContext = function (parent, pos) {
+ 'use strict';
+
+ var TreeOps = _dereq_('../tree_ops').TreeOps;
+
+ var Errors = _dereq_('./errors');
+ var StaticError = Errors.StaticError;
+ var StaticWarning = Errors.StaticWarning;
+
+ var getSchemaBuiltinTypes = _dereq_('./schema_built-in_types').getSchemaBuiltinTypes;
+
+ var emptyPos = { sl:0, sc: 0, el: 0, ec: 0 };
+ var namespaces = {};
+
+ var getVarKey = function(qname) {
+ return qname.uri + '#' + qname.name;
+ };
+
+ var getFnKey = function(qname, arity) {
+ return getVarKey(qname) + '#' + arity;
+ };
+
+ if(!parent) {
+ namespaces['http://jsoniq.org/functions'] = {
+ prefixes: ['jn'],
+ pos: emptyPos,
+ type: 'module',
+ override: true
+ };
+ namespaces['http://www.28msec.com/modules/collections'] = {
+ prefixes: ['db'],
+ pos: emptyPos,
+ type: 'module',
+ override: true
+ };
+ namespaces['http://www.28msec.com/modules/store'] = {
+ prefixes: ['store'],
+ pos: emptyPos,
+ type: 'module',
+ override: true
+ };
+ namespaces['http://jsoniq.org/function-library'] = {
+ prefixes: ['libjn'],
+ pos: emptyPos,
+ type: 'module',
+ override: true
+ };
+ namespaces['http://www.w3.org/2005/xpath-functions'] = {
+ prefixes: ['fn'],
+ pos: emptyPos,
+ type: 'module',
+ override: true
+ };
+ namespaces['http://www.w3.org/2005/xquery-local-functions'] = {
+ prefixes: ['local'],
+ pos: emptyPos,
+ type: 'declare',
+ override: true
+ };
+ namespaces['http://www.w3.org/2001/XMLSchema-instance'] = {
+ prefixes: ['xsi'],
+ pos: emptyPos,
+ type: 'declare'
+ };
+ namespaces['http://www.w3.org/2001/XMLSchema'] = {
+ prefixes: ['xs'],
+ pos: emptyPos,
+ type: 'declare'
+ };
+ namespaces['http://www.w3.org/XML/1998/namespace'] = {
+ prefixes: ['xml'],
+ pos: emptyPos,
+ type: 'declare'
+ };
+ namespaces['http://zorba.io/annotations'] = {
+ prefixes: ['an'],
+ pos: emptyPos,
+ type: 'declare',
+ override: true
+ };
+ namespaces['http://www.28msec.com/annotations/rest'] = {
+ prefixes: ['rest'],
+ pos: emptyPos,
+ type: 'declare',
+ override: true
+ };
+ namespaces['http://www.w3.org/2005/xqt-errors'] = {
+ prefixes: ['err'],
+ pos: emptyPos,
+ type: 'declare',
+ override: true
+ };
+ namespaces['http://zorba.io/errors'] = {
+ prefixes: ['zerr'],
+ pos: emptyPos,
+ type: 'declare',
+ override: true
+ };
+ }
+
+ var s = {
+ parent: parent,
+ children: [],
+ pos: pos,
+ setModuleResolver: function(resolver){
+ this.root.moduleResolver = resolver;
+ return this;
+ },
+ setModules: function(index){
+ if(this !== this.root){
+ throw new Error('setModules() not invoked from the root static context.');
+ }
+ this.moduleResolver = function(uri){
+ return index[uri];
+ };
+ var that = this;
+ Object.keys(this.namespaces).forEach(function(uri){
+ var ns = that.namespaces[uri];
+ if(ns.type === 'module') {
+ var mod = that.moduleResolver(uri);
+ if(mod.variables) {
+ TreeOps.concat(that.variables, mod.variables);
+ }
+ if(mod.functions) {
+ TreeOps.concat(that.functions, mod.functions);
+ }
+ }
+ });
+ return this;
+ },
+ setModulesFromXQDoc: function(xqdoc){
+ if(this !== this.root){
+ throw new Error('setModulesFromXQDoc() not invoked from the root static context.');
+ }
+ var index = {};
+ Object.keys(xqdoc).forEach(function(uri) {
+ var mod = xqdoc[uri];
+ var variables = {};
+ var functions = {};
+ mod.functions.forEach(function(fn){
+ functions[uri + '#' + fn.name + '#' + fn.arity] = {
+ params: [],
+ annotations: [],
+ name: fn.name,
+ arity: fn.arity,
+ eqname: { uri: uri, name: fn.name }
+ };
+ fn.parameters.forEach(function(param){
+ functions[uri + '#' + fn.name + '#' + fn.arity].params.push('$' + param.name);
+ });
+ });
+ mod.variables.forEach(function(variable){
+ var name = variable.name.substring(variable.name.indexOf(':') + 1);
+ variables[uri + '#' + name] = { type: 'VarDecl', annotations: [], eqname: { uri: uri, name: name } };
+ });
+ index[uri] = {
+ variables: variables,
+ functions: functions
+ };
+ });
+ this.root.moduleResolver = function(uri){
+ return index[uri];
+ };
+ var that = this;
+ Object.keys(this.namespaces).forEach(function(uri){
+ var ns = that.namespaces[uri];
+ if(ns.type === 'module') {
+ var mod = that.moduleResolver(uri);
+ if(mod.variables) {
+ TreeOps.concat(that.variables, mod.variables);
+ }
+ if(mod.functions) {
+ TreeOps.concat(that.functions, mod.functions);
+ }
+ }
+ });
+ return this;
+ },
+ moduleNamespace: '',
+ description: '',
+ defaultFunctionNamespace: 'http://www.w3.org/2005/xpath-functions',
+ defaultFunctionNamespaces: [
+ 'http://www.28msec.com/modules/collections',
+ 'http://www.28msec.com/modules/store',
+ 'http://jsoniq.org/functions',
+ 'http://jsoniq.org/function-library',
+ 'http://www.w3.org/2001/XMLSchema' //Built-in type constructors
+ ],
+ defaultElementNamespace: '',
+ namespaces: namespaces,
+ availableModuleNamespaces: [],
+ importModule: function(uri, prefix, pos) {
+ if(this !== this.root){
+ throw new Error('Function not invoked from the root static context.');
+ }
+ this.addNamespace(uri, prefix, pos, 'module');
+ if(this.moduleResolver) {
+ try {
+ var mod = this.moduleResolver(uri, []);
+ if(mod.variables) {
+ TreeOps.concat(this.variables, mod.variables);
+ }
+ if(mod.functions) {
+ TreeOps.concat(this.functions, mod.functions);
+ }
+ } catch(e) {
+ throw new StaticError('XQST0059', 'module "' + uri + '" not found', pos);
+ }
+ }
+ return this;
+ },
+
+ getAvailableModuleNamespaces: function(){
+ return this.root.availableModuleNamespaces;
+ },
+
+ getPrefixesByNamespace: function(uri){
+ return this.root.namespaces[uri].prefixes;
+ },
+
+ addNamespace: function (uri, prefix, pos, type) {
+ if(prefix === '' && type === 'module') {
+ throw new StaticWarning('W01', 'Avoid this type of import. Use import module namespace instead', pos);
+ }
+ if (uri === '') {
+ throw new StaticError('XQST0088', 'empty target namespace in module import or module declaration', pos);
+ }
+ var namespace = this.getNamespace(uri);
+ if (namespace && namespace.type === type && type !== 'declare' && !namespace.override) {
+ throw new StaticError('XQST0047', '"' + uri + '": duplicate target namespace', pos);
+ }
+ namespace = this.getNamespaceByPrefix(prefix);
+ if (namespace && !namespace.override) {
+ throw new StaticError('XQST0033', '"' + prefix + '": namespace prefix already bound to "' + namespace.uri + '"', pos);
+ }
+
+ namespace = this.namespaces[uri];
+ var prefixes = [prefix];
+ if(namespace) {
+ prefixes = prefixes.concat(this.namespaces[uri].prefixes);
+ }
+ this.namespaces[uri] = {
+ prefixes: prefixes,
+ pos: pos,
+ type: type
+ };
+
+ if (namespace) {
+ throw new StaticWarning('W02', '"' + uri + '" already bound to the "' + namespace.prefixes.join(', ') + '" prefix', pos);
+ }
+
+ },
+
+ getNamespaces: function(){
+ return this.root.namespaces;
+ },
+
+ getNamespace: function (uri) {
+ var that = this;
+ while (that) {
+ var namespace = that.namespaces[uri];
+ if (namespace) {
+ return namespace;
+ }
+ that = that.parent;
+ }
+
+ },
+
+ getNamespaceByPrefix: function (prefix) {
+ var found = [];
+ var handler = function (uri) {
+ var namespace = that.namespaces[uri];
+ if (namespace.prefixes.indexOf(prefix) !== -1) {
+ namespace.uri = uri;
+ found.push(namespace);
+ }
+ };
+ var that = this;
+ while (that) {
+ Object.keys(that.namespaces).forEach(handler);
+ that = that.parent;
+ }
+ var result;
+ found.forEach(function(ns){
+ if(ns.type === 'moduleDecl') {
+ result = ns;
+ }
+ });
+ if(result) {
+ return result;
+ } else {
+ return found[0];
+ }
+ },
+
+ resolveQName: function(value, pos){
+ var qname = {
+ uri: '',
+ prefix: '',
+ name: ''
+ };
+ var idx;
+ if (value.substring(0, 2) === 'Q{') {
+ idx = value.indexOf('}');
+ qname.uri = value.substring(2, idx);
+ qname.name = value.substring(idx + 1);
+ } else {
+ idx = value.indexOf(':');
+ qname.prefix = value.substring(0, idx);
+ var namespace = this.getNamespaceByPrefix(qname.prefix);
+ if(!namespace && qname.prefix !== '' && ['fn', 'jn'].indexOf(qname.prefix) === -1) {
+ throw new StaticError('XPST0081', '"' + qname.prefix + '": can not expand prefix of lexical QName to namespace URI', pos);
+ }
+ if(namespace) {
+ qname.uri = namespace.uri;
+ }
+ qname.name = value.substring(idx + 1);
+ }
+ return qname;
+ },
+
+ variables: {},
+ varRefs: {},
+ functionCalls: {},
+
+ addVariable: function(qname, type, pos){
+ if(
+ type === 'VarDecl' && this.moduleNamespace !== '' &&
+ !(this.moduleNamespace === qname.uri || qname.uri === '')
+ ) {
+ throw new StaticError('XQST0048', '"' + qname.prefix + ':' + qname.name + '": Qname not library namespace', pos);
+ }
+ var key = getVarKey(qname);
+ if(type === 'VarDecl' && this.variables[key]) {
+ throw new StaticError('XQST0049', '"' + qname.name + '": duplicate variable declaration', pos);
+ }
+ this.variables[key] = {
+ type: type,
+ pos: pos,
+ qname: qname,
+ annotations: {}
+ };
+ return this;
+ },
+
+ getVariables: function(){
+ var variables = {};
+ var that = this;
+ var handler = function(key){
+ if(!variables[key]){
+ variables[key] = that.variables[key];
+ }
+ };
+ while(that){
+ Object.keys(that.variables).forEach(handler);
+ that = that.parent;
+ }
+ return variables;
+ },
+
+ getVariable: function(qname) {
+ var key = getVarKey(qname);
+ var that = this;
+ while(that) {
+ if(that.variables[key]) {
+ return that.variables[key];
+ }
+ that = that.parent;
+ }
+ },
+
+ addVarRef: function(qname, pos){
+ var varDecl = this.getVariable(qname);
+ if(!varDecl && (qname.uri === '' || this.root.moduleResolver)) {
+ throw new StaticError('XPST0008', '"' + qname.name + '": undeclared variable', pos);
+ }
+ var key = getVarKey(qname);
+ this.varRefs[key] = true;
+ },
+
+ addFunctionCall: function(qname, arity, pos){
+ var fn = this.getFunction(qname, arity);
+ if(!fn && (qname.uri === 'http://www.w3.org/2005/xquery-local-functions' || this.root.moduleResolver)){
+ if((qname.uri === 'http://www.w3.org/2005/xpath-functions' ||
+ (qname.uri === '' && this.root.defaultFunctionNamespaces.concat(this.root.defaultFunctionNamespace).indexOf('http://www.w3.org/2005/xpath-functions') !== -1)) && qname.name === 'concat') {
+ } else if(!fn){
+ throw new StaticError('XPST0008', '"' + qname.name + '#' + arity + '": undeclared function', pos);
+ }
+ }
+ var key = getFnKey(qname, arity);
+ this.functionCalls[key] = true;
+ },
+
+ functions: getSchemaBuiltinTypes()['http://www.w3.org/2001/XMLSchema'].functions,
+
+ getFunctions: function(){
+ return this.root.functions;
+ },
+
+ getFunction: function(qname, arity){
+ var key = getFnKey(qname, arity);
+ var fn;
+ if(qname.uri === '') {
+ var that = this;
+ this.root.defaultFunctionNamespaces.concat([this.root.defaultFunctionNamespace]).forEach(function(defaultFunctionNamespace){
+ if(!fn){
+ fn = that.getFunction({ uri: defaultFunctionNamespace, prefix: qname.prefix, name: qname.name }, arity);
+ } else {
+ return false;
+ }
+ });
+ return fn;
+ } else {
+ return this.root.functions[key];
+ }
+ },
+
+ addFunction: function(qname, pos, params) {
+ if(this !== this.root){
+ throw new Error('addFunction() not invoked from the root static context.');
+ }
+ var arity = params.length;
+ if(
+ this.moduleNamespace !== '' &&
+ !(this.moduleNamespace === qname.uri || (qname.uri === '' && this.defaultFunctionNamespace === this.moduleNamespace))
+ ) {
+ throw new StaticError('XQST0048', '"' + qname.prefix + ':' + qname.name + '": Qname not library namespace', pos);
+ }
+ var key = getFnKey(qname, arity);
+ if(this.functions[key]) {
+ throw new StaticError('XQST0034', '"' + qname.name + '": duplicate function declaration', pos);
+ }
+ this.functions[key] = {
+ pos: pos,
+ params: params
+ };
+ return this;
+ }
+
+ };
+ s.root = parent ? parent.root : s;
+ return s;
+};
+
+},{"../tree_ops":"/node_modules/xqlint/lib/tree_ops.js","./errors":"/node_modules/xqlint/lib/compiler/errors.js","./schema_built-in_types":"/node_modules/xqlint/lib/compiler/schema_built-in_types.js"}],"/node_modules/xqlint/lib/compiler/translator.js":[function(_dereq_,module,exports){
+exports.Translator = function(rootStcx, ast){
+ 'use strict';
+
+ var Errors = _dereq_('./errors');
+ var StaticError = Errors.StaticError;
+ var StaticWarning = Errors.StaticWarning;
+
+ var TreeOps = _dereq_('../tree_ops').TreeOps;
+ var StaticContext = _dereq_('./static_context').StaticContext;
+ var Handlers = _dereq_('./handlers');
+
+ var get = function(node, path){
+ var result = [];
+ if(path.length === 0){
+ return node;
+ }
+ node.children.forEach(function(child){
+ if(child.name === path[0] && path.length > 1) {
+ result = get(child, path.slice(1));
+ } else if(child.name === path[0]) {
+ result.push(child);
+ }
+ });
+ return result;
+ };
+
+ var markers = [];
+ this.apply = function(fn) {
+ try {
+ fn();
+ } catch(e) {
+ if(e instanceof StaticError) {
+ addStaticError(e);
+ } else if(e instanceof StaticWarning) {
+ addWarning(e.getCode(), e.getMessage(), e.getPos());
+ } else {
+ throw e;
+ }
+ }
+ };
+
+ var addStaticError = function(e){
+ markers.push({
+ pos: e.getPos(),
+ type: 'error',
+ level: 'error',
+ message: '[' + e.getCode() + '] ' + e.getMessage()
+ });
+ };
+
+ var addWarning = function(code, message, pos) {
+ markers.push({
+ pos: pos,
+ type: 'warning',
+ level: 'warning',
+ message: '[' + code + '] ' + message
+ });
+ };
+
+ this.getMarkers = function(){
+ return markers;
+ };
+
+ var translator = this;
+
+ rootStcx.pos = ast.pos;
+ var sctx = rootStcx;
+ var pushSctx = function(pos){
+ sctx = new StaticContext(sctx, pos);
+ sctx.parent.children.push(sctx);
+ };
+
+ var popSctx = function(pos){
+ if (pos !== undefined) {
+ sctx.pos.el = pos.el;
+ sctx.pos.ec = pos.ec;
+ }
+
+ Object.keys(sctx.varRefs).forEach(function(key){
+ if(!sctx.variables[key]) {
+ sctx.parent.varRefs[key] = true;
+ }
+ });
+ Object.keys(sctx.variables).forEach(function(key){
+ if(!sctx.varRefs[key] && sctx.variables[key].type !== 'GroupingVariable' && sctx.variables[key].type !== 'CatchVar') {
+ addWarning('W03', 'Unused variable "$' + sctx.variables[key].qname.name + '"', sctx.variables[key].pos);
+ }
+ });
+
+ sctx = sctx.parent;
+ };
+
+ this.visitOnly = function(node, names) {
+ node.children.forEach(function(child){
+ if (names.indexOf(child.name) !== -1){
+ translator.visit(child);
+ }
+ });
+ };
+
+ this.getFirstChild = function(node, name) {
+ var result;
+ node.children.forEach(function(child){
+ if(child.name === name && result === undefined){
+ result = child;
+ }
+ });
+ return result;
+ };
+
+ this.XQuery = function(node) {
+ rootStcx.description = node.comment ? node.comment.description : undefined;
+ };
+
+ this.ModuleDecl = function(node){
+ this.visitChildren(node, Handlers.ModuleDecl(translator, rootStcx, node));
+ return true;
+ };
+
+ this.Prolog = function(node){
+ this.visitOnly(node, ['DefaultNamespaceDecl', 'Setter', 'NamespaceDecl', 'Import']);
+ ast.index.forEach(function(node){
+ if(node.name === 'VarDecl') {
+ node.children.forEach(function(child){
+ if(child.name === 'VarName') {
+ translator.apply(function(){
+ var value = TreeOps.flatten(child);
+ var qname = rootStcx.resolveQName(value, child.pos);
+ rootStcx.addVariable(qname, node.name, child.pos);
+ });
+ }
+ });
+ } else if(node.name === 'FunctionDecl') {
+ var qname, pos, params = [];
+ node.children.forEach(function(child){
+ if(child.name === 'EQName') {
+ qname = child;
+ pos = child.pos;
+ } else if(child.name === 'ParamList'){
+ child.children.forEach(function(c){
+ if(c.name === 'Param') {
+ params.push(TreeOps.flatten(c));
+ }
+ });
+ }
+ });
+ translator.apply(function(){
+ qname = TreeOps.flatten(qname);
+ qname = rootStcx.resolveQName(qname, pos);
+ rootStcx.addFunction(qname, pos, params);
+ });
+ }
+ });
+ this.visitOnly(node, ['ContextItemDecl', 'AnnotatedDecl', 'OptionDecl']);
+ return true;
+ };
+
+ this.ModuleImport = function (node) {
+ this.visitChildren(node, Handlers.ModuleImport(translator, rootStcx, node));
+ return true;
+ };
+
+ this.SchemaImport = function (node) {
+ this.visitChildren(node, Handlers.SchemaImport(translator, rootStcx, node));
+ return true;
+ };
+
+ this.DefaultNamespaceDecl = function(node){
+ this.visitChildren(node, Handlers.DefaultNamespaceDecl(translator, rootStcx, node));
+ return true;
+ };
+
+ this.NamespaceDecl = function (node) {
+ this.visitChildren(node, Handlers.NamespaceDecl(translator, rootStcx, node));
+ return true;
+ };
+
+ var annotations = {};
+ this.AnnotatedDecl = function(node) {
+ annotations = {};
+ this.visitChildren(node, Handlers.NamespaceDecl(translator, rootStcx, node));
+ return true;
+ };
+
+ this.CompatibilityAnnotation = function(){
+ annotations['http://www.w3.org/2012/xquery#updating'] = [];
+ return true;
+ };
+
+ this.Annotation = function(node){
+ this.visitChildren(node, {
+ EQName: function(eqname){
+ var value = TreeOps.flatten(eqname);
+ translator.apply(function(){
+ var qname = sctx.resolveQName(value, eqname.pos);
+ annotations[qname.uri + '#' + qname.name] = [];
+ });
+ }
+ });
+ return true;
+ };
+
+ this.VarDecl = function(node){
+ try {
+ var varname = translator.getFirstChild(node, 'VarName');
+ var value = TreeOps.flatten(varname);
+ var qname = sctx.resolveQName(value, varname.pos);
+ var variable = rootStcx.getVariable(qname);
+ if(variable) {
+ variable.annotations = annotations;
+ variable.description = node.getParent.comment ? node.getParent.comment.description : undefined;
+ variable.type = TreeOps.flatten(get(node, ['TypeDeclaration'])[0]).substring(2).trim();
+ var last = variable.type.substring(variable.type.length - 1);
+ if(last === '?') {
+ variable.occurrence = 0;
+ variable.type = variable.type.substring(0, variable.type.length - 1);
+ } else if(last === '*') {
+ variable.occurrence = -1;
+ variable.type = variable.type.substring(0, variable.type.length - 1);
+ } else if(last === '+') {
+ variable.occurrence = 2;
+ variable.type = variable.type.substring(0, variable.type.length - 1);
+ } else {
+ variable.occurrence = 1;
+ }
+ }
+ } catch(e) {
+ }
+ this.visitOnly(node, ['ExprSingle', 'VarValue', 'VarDefaultValue']);
+ return true;
+ };
+
+ this.FunctionDecl = function(node) {
+ var isUpdating = annotations['http://www.w3.org/2012/xquery#updating'] !== undefined;
+ var typeDecl = get(node, ['ReturnType'])[0];
+ var name = get(node, ['EQName'])[0];
+ if(!typeDecl && !isUpdating){
+ addWarning('W05', 'Untyped return value', name.pos);
+ }
+ var isExternal = false;
+ node.children.forEach(function(child){
+ if(child.name === 'TOKEN' && child.value === 'external') {
+ isExternal = true;
+ return false;
+ }
+ });
+ if(!isExternal) {
+ pushSctx(node.pos);
+ this.visitChildren(node);
+ popSctx();
+ }
+ return true;
+ };
+
+ this.VarRef = function(node) {
+ this.visitChildren(node, Handlers.VarRefHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.Param = function(node){
+ var typeDecl = get(node, ['TypeDeclaration'])[0];
+ if(!typeDecl){
+ addWarning('W05', 'Untyped function parameter', node.pos);
+ }
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.InlineFunctionExpr = function(node) {
+ pushSctx(node.pos);
+ this.visitChildren(node);
+ popSctx();
+ return true;
+ };
+ var statementCount = [];
+ var handleStatements = function(node) {
+ pushSctx(node.pos);
+ statementCount.push(0);
+ translator.visitChildren(node);
+ for (var i = 1; i <= statementCount[statementCount.length - 1]; i++) {
+ popSctx(node.pos);
+ }
+ statementCount.pop();
+ popSctx();
+ };
+
+ this.StatementsAndOptionalExpr = function (node) {
+ handleStatements(node);
+ return true;
+ };
+
+ this.StatementsAndExpr = function (node) {
+ handleStatements(node);
+ return true;
+ };
+
+ this.BlockStatement = function (node) {
+ handleStatements(node);
+ return true;
+ };
+
+ this.VarDeclStatement = function(node){
+ pushSctx(node.pos);
+ statementCount[statementCount.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ };
+ var clauses = [];
+ this.FLWORExpr = this.FLWORStatement = function (node) {
+ pushSctx(node.pos);
+ clauses.push(0);
+ this.visitChildren(node);
+ for(var i=1; i <= clauses[clauses.length - 1]; i++) {
+ popSctx(node.pos);
+ }
+ clauses.pop();
+ popSctx();
+ return true;
+ };
+
+ this.ForBinding = function (node) {
+ this.visitOnly(node, ['ExprSingle', 'VarValue', 'VarDefaultValue']);
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.LetBinding = function(node){
+ this.visitOnly(node, ['ExprSingle', 'VarValue', 'VarDefaultValue']);
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.GroupingSpec = function(node){
+ var isVarDecl = false;
+ node.children.forEach(function(child){
+ if(child.value === ':=') {
+ isVarDecl = true;
+ return false;
+ }
+ });
+ if(isVarDecl) {
+ var groupingVariable = node.children[0];
+ this.visitOnly(node, ['ExprSingle', 'VarValue', 'VarDefaultValue']);
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(groupingVariable, Handlers.VarHandler(translator, sctx, groupingVariable));
+ return true;
+ } else {
+
+ }
+ };
+
+ this.TumblingWindowClause = function (node) {
+ this.visitOnly(node, ['ExprSingle']);
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ this.visitOnly(node, ['WindowStartCondition', 'WindowEndCondition']);
+ return true;
+ };
+
+ this.WindowVars = function (node) {
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.SlidingWindowClause = function (node) {
+ this.visitOnly(node, ['ExprSingle', 'VarValue', 'VarDefaultValue']);
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ this.visitOnly(node, ['WindowStartCondition', 'WindowEndCondition']);
+ return true;
+ };
+
+ this.PositionalVar = function (node) {
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.PositionalVar = function (node) {
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.CurrentItem = function (node) {
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.PreviousItem = function (node) {
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.NextItem = function (node) {
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.CountClause = function (node) {
+ pushSctx(node.pos);
+ clauses[clauses.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.CaseClause = function(node) {
+ pushSctx(node.pos);
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ this.visitOnly(node, ['ExprSingle']);
+ popSctx();
+ return true;
+ };
+ var copies = [];
+ this.TransformExpr = function (node) {
+ pushSctx(node.pos);
+ copies.push(0);
+ this.visitChildren(node);
+ for(var i=1; i <= copies[copies.length - 1]; i++) {
+ popSctx(node.pos);
+ }
+ copies.pop();
+ popSctx();
+ return true;
+ };
+
+ this.TransformSpec = function(node) {
+ this.visitOnly(node, ['ExprSingle']);
+ pushSctx(node.pos);
+ copies[copies.length-1] += 1;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+ var quantifiedDecls = [];
+ this.QuantifiedExpr = function (node) {
+ pushSctx(node.pos);
+ quantifiedDecls.push(0);
+ this.visitChildren(node);
+ for(var i=1; i <= quantifiedDecls[quantifiedDecls.length - 1]; i++) {
+ popSctx(node.pos);
+ }
+ quantifiedDecls.pop();
+ popSctx();
+ return true;
+ };
+
+ this.QuantifiedVarDecl = function(node) {
+ this.visitOnly(node, ['ExprSingle']);
+ pushSctx(node.pos);
+ quantifiedDecls[quantifiedDecls.length - 1]++;
+ this.visitChildren(node, Handlers.VarHandler(translator, sctx, node));
+ return true;
+ };
+
+ this.FunctionCall = function(node){
+ this.visitOnly(node, ['ArgumentList']);
+ var name = translator.getFirstChild(node, 'EQName');
+ var eqname = TreeOps.flatten(name);
+ var arity = get(node, ['ArgumentList', 'Argument']).length;
+ translator.apply(function(){
+ var qname = sctx.resolveQName(eqname, node.pos);
+ try {
+ if(qname.uri !== '') {
+ sctx.root.namespaces[qname.uri].used = true;
+ }
+ } catch(e){
+ }
+ sctx.addFunctionCall(qname, arity, name.pos);
+ });
+ return true;
+ };
+
+ this.TryClause = function(node){
+ pushSctx(node.pos);
+ this.visitChildren(node);
+ popSctx();
+ return true;
+ };
+
+ this.CatchClause = function(node){
+ pushSctx(node.pos);
+ var prefix = 'err';
+ var uri = 'http://www.w3.org/2005/xqt-errors';
+ var emptyPos = { sl: 0, sc: 0, el: 0, ec: 0 };
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'code' }, 'CatchVar', emptyPos);
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'description' }, 'CatchVar', emptyPos);
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'value' }, 'CatchVar', emptyPos);
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'module' }, 'CatchVar', emptyPos);
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'line-number' }, 'CatchVar', emptyPos);
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'column-number' }, 'CatchVar', emptyPos);
+ sctx.addVariable({ prefix: prefix, uri: uri, name: 'additional' }, 'CatchVar', emptyPos);
+ this.visitChildren(node);
+ popSctx();
+ return true;
+ };
+
+ this.Pragma = function(node){
+ var qname = TreeOps.flatten(get(node, ['EQName'])[0]);
+ qname = rootStcx.resolveQName(qname, node);
+ var value = TreeOps.flatten(get(node, ['PragmaContents'])[0]);
+ if (qname.name === 'xqlint' && qname.uri === 'http://xqlint.io') {
+ pushSctx(node.pos);
+ var commands = value.match(/[a-zA-Z]+\(([^)]+)\)/g);
+ commands.forEach(function (command) {
+ var name = command.substring(0, command.indexOf('('));
+ var args = command.substring(0, command.length - 1).substring(command.indexOf('(') + 1).split(',').map(function (val) {
+ return val.trim();
+ });
+ if (name === 'varrefs') {
+ args.forEach(function (arg) {
+ var qname = sctx.resolveQName(arg.substring(1), node.pos);
+ if (qname.uri !== '') {
+ sctx.root.namespaces[qname.uri].used = true;
+ }
+ sctx.addVarRef(qname, node.pos);
+ });
+ }
+ });
+ this.visitChildren(node);
+ popSctx();
+ return true;
+ }
+ };
+
+ this.visit = function (node) {
+ var name = node.name;
+ var skip = false;
+
+ if (typeof this[name] === 'function') {
+ skip = this[name](node) === true;
+ }
+
+ if (!skip) {
+ this.visitChildren(node);
+ }
+ };
+
+ this.visitChildren = function (node, handler) {
+ for (var i = 0; i < node.children.length; i++) {
+ var child = node.children[i];
+ if (handler !== undefined && typeof handler[child.name] === 'function') {
+ handler[child.name](child);
+ } else {
+ this.visit(child);
+ }
+ }
+ };
+
+ this.visit(ast);
+ Object.keys(rootStcx.variables).forEach(function(key){
+ if(!rootStcx.varRefs[key] && (rootStcx.variables[key].annotations['http://www.w3.org/2005/xpath-functions#private'] || rootStcx.moduleNamespace === '') && rootStcx.variables[key].pos) {
+ addWarning('W03', 'Unused variable "' + rootStcx.variables[key].qname.name + '"', rootStcx.variables[key].pos);
+ }
+ });
+ Object.keys(rootStcx.namespaces).forEach(function(uri){
+ var namespace = rootStcx.namespaces[uri];
+ if(namespace.used === undefined && !namespace.override && namespace.type === 'module') {
+ addWarning('W04', 'Unused module "' + uri + '"', namespace.pos);
+ }
+ });
+};
+
+},{"../tree_ops":"/node_modules/xqlint/lib/tree_ops.js","./errors":"/node_modules/xqlint/lib/compiler/errors.js","./handlers":"/node_modules/xqlint/lib/compiler/handlers.js","./static_context":"/node_modules/xqlint/lib/compiler/static_context.js"}],"/node_modules/xqlint/lib/completion/completer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var TreeOps = _dereq_('../tree_ops').TreeOps;
+
+var ID_REGEX = /[a-zA-Z_0-9\$]/;
+
+function retrievePrecedingIdentifier(text, pos, regex) {
+ regex = regex || ID_REGEX;
+ var buf = [];
+ for (var i = pos-1; i >= 0; i--) {
+ if (regex.test(text[i])) {
+ buf.push(text[i]);
+ } else {
+ break;
+ }
+ }
+ return buf.reverse().join('');
+}
+
+function prefixBinarySearch(items, prefix) {
+ var startIndex = 0;
+ var stopIndex = items.length - 1;
+ var middle = Math.floor((stopIndex + startIndex) / 2);
+
+ while (stopIndex > startIndex && middle >= 0 && items[middle].indexOf(prefix) !== 0) {
+ if (prefix < items[middle]) {
+ stopIndex = middle - 1;
+ } else if (prefix > items[middle]) {
+ startIndex = middle + 1;
+ }
+ middle = Math.floor((stopIndex + startIndex) / 2);
+ }
+ while (middle > 0 && items[middle-1].indexOf(prefix) === 0) {
+ middle--;
+ }
+ return middle >= 0 ? middle : 0; // ensure we're not returning a negative index
+}
+
+var uriRegex = /[a-zA-Z_0-9\/\.:\-#]/;
+var char = '-._A-Za-z0-9:\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02ff\u0300-\u037D\u037F-\u1FFF\u200C\u200D\u203f\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD';
+var nameChar = '[' + char + ']';
+var varChar = '[' + char + '\\$]';
+var nameCharRegExp = new RegExp(nameChar);
+var varCharRegExp = new RegExp(varChar);
+
+var varDeclLabels = {
+ 'LetBinding': 'Let binding',
+ 'Param': 'Function parameter',
+ 'QuantifiedExpr': 'Quantified expression binding',
+ 'VarDeclStatement': 'Local variable',
+ 'ForBinding': 'For binding',
+ 'TumblingWindowClause': 'Tumbling window binding',
+ 'WindowVars': 'Window variable',
+ 'SlidingWindowClause': 'Sliding window binding',
+ 'PositionalVar': 'Positional variable',
+ 'CurrentItem': 'Current item',
+ 'PreviousItem': 'Previous item',
+ 'NextItem': 'Next item',
+ 'CountClause': 'Count binding',
+ 'GroupingVariable': 'Grouping variable',
+ 'VarDecl': 'Module variable'
+};
+
+var findCompletions = function(prefix, allIdentifiers) {
+ allIdentifiers.sort();
+ var startIdx = prefixBinarySearch(allIdentifiers, prefix);
+ var matches = [];
+ for (var i = startIdx; i < allIdentifiers.length && allIdentifiers[i].indexOf(prefix) === 0; i++) {
+ matches.push(allIdentifiers[i]);
+ }
+ return matches;
+};
+
+
+var completePrefix = function(identifier, pos, sctx){
+ var idx = identifier.indexOf(':');
+ if(idx === -1) {
+ var prefixes = [];
+ var namespaces = sctx.getNamespaces();
+ Object.keys(namespaces).forEach(function(key){
+ if(namespaces[key].type === 'module' || key === 'http://www.w3.org/2005/xquery-local-functions') {
+ prefixes.push(namespaces[key].prefixes[0]);
+ }
+ });
+ var matches = findCompletions(identifier, prefixes);
+ var match = function(name) {
+ return {
+ name: name + ':',
+ value: name + ':',
+ meta: 'prefix'
+ };
+ };
+ return matches.map(match);
+ } else {
+ return [];
+ }
+};
+
+var completeFunction = function(identifier, pos, sctx){
+ var names = [];
+ var snippets = {};
+ var functions = sctx.getFunctions();
+ var uri = '';
+ var prefix = '';
+ var name = identifier;
+ var idx = identifier.indexOf(':');
+ var defaultNamespace = false;
+ if(idx !== -1){
+ prefix = identifier.substring(0, idx);
+ name = identifier.substring(idx + 1);
+ var ns = sctx.getNamespaceByPrefix(prefix);
+ if(ns){
+ uri = sctx.getNamespaceByPrefix(prefix).uri;
+ }
+ } else {
+ defaultNamespace = true;
+ uri = sctx.root.defaultFunctionNamespace;
+ }
+ Object.keys(functions).forEach(function(key){
+ var fn = functions[key];
+ var ns = key.substring(0, key.indexOf('#'));
+ var name = key.substring(key.indexOf('#') + 1);
+ name = name.substring(0, name.indexOf('#'));
+ if(ns !== uri) {
+ return;
+ }
+ if(!defaultNamespace){
+ name = sctx.getNamespaces()[ns].prefixes[0] + ':' + name;
+ }
+ name += '(';
+ var snippet = name;
+ snippet += fn.params.map(function(param, index){
+ return '${' + (index + 1) + ':\\' + param.split(' ')[0] + '}';
+ }).join(', ');
+ name += fn.params.join(', ');
+ name += ')';
+ snippet += ')';
+ names.push(name);
+ snippets[name] = snippet;
+ });
+ var matches = findCompletions(identifier, names);
+ var match = function(name) {
+ return {
+ name: name,
+ value: name,
+ meta: 'function',
+ priority: 4,
+ identifierRegex: nameCharRegExp,
+ snippet: snippets[name]
+ };
+ };
+ return matches.map(match);
+};
+
+var completeVariable = function(identifier, pos, sctx){
+ var uri = '';
+ var prefix = '';
+ var idx = identifier.indexOf(':');
+ if(idx !== -1){
+ prefix = identifier.substring(0, idx);
+ uri = sctx.getNamespaceByPrefix(prefix).uri;
+ }
+ var decls = sctx.getVariables();
+ var names = [];
+ var types = {};
+ Object.keys(decls).forEach(function(key){
+ var i = key.indexOf('#');
+ var ns = key.substring(0, i);
+ var name = key.substring(i+1);
+ if(ns !== ''){
+ names.push(sctx.getPrefixesByNamespace(ns)[0] + ':' + name);
+ types[sctx.getPrefixesByNamespace(ns)[0] + ':' + name] = decls[key].type;
+ } else {
+ names.push(name);
+ types[name] = decls[key].type;
+ }
+ });
+
+ var matches = findCompletions(identifier, names);
+ var match = function(name) {
+ return {
+ name: '$' + name,
+ value: '$' + name,
+ meta: varDeclLabels[types[name]],
+ priority: 4,
+ identifierRegex: varCharRegExp
+ };
+ };
+ return matches.map(match);
+};
+
+var completeExpr = function(line, pos, sctx){
+ var identifier = retrievePrecedingIdentifier(line, pos.col, nameCharRegExp);
+ var before = line.substring(0, pos.col - (identifier.length === 0 ? 0 : identifier.length));
+ var isVar = before[before.length - 1] === '$';
+ if(isVar) {
+ return completeVariable(identifier, pos, sctx);
+ } else if(identifier !== '') {
+ return completeFunction(identifier, pos, sctx).concat(completePrefix(identifier, pos, sctx));
+ } else {
+ return completeVariable(identifier, pos, sctx).concat(completeFunction(identifier, pos, sctx)).concat(completePrefix(identifier, pos, sctx));
+ }
+};
+
+var completeModuleUri = function(line, pos, sctx){
+ var identifier = retrievePrecedingIdentifier(line, pos.col, uriRegex);
+ var matches = findCompletions(identifier, sctx.getAvailableModuleNamespaces());
+ var match = function(uri) {
+ return {
+ name: uri,
+ value: uri,
+ meta: 'module',
+ priority: 4,
+ identifierRegex: uriRegex
+ };
+ };
+ return matches.map(match);
+};
+
+exports.complete = function(source, ast, rootSctx, pos){
+ var line = source.split('\n')[pos.line];
+ var node = TreeOps.findNode(ast, pos);
+ var sctx = TreeOps.findNode(rootSctx, pos);
+ sctx = sctx ? sctx : rootSctx;
+ if(node && node.name === 'URILiteral' && node.getParent && node.getParent.name === 'ModuleImport'){
+ return completeModuleUri(line, pos, sctx);
+ } else {
+ return completeExpr(line, pos, sctx);
+ }
+};
+
+},{"../tree_ops":"/node_modules/xqlint/lib/tree_ops.js"}],"/node_modules/xqlint/lib/formatter/style_checker.js":[function(_dereq_,module,exports){
+exports.StyleChecker = function (ast, source) {
+ 'use strict';
+
+ var tab = ' ';
+ var markers = [];
+
+ this.getMarkers = function(){
+ return markers;
+ };
+
+ this.WS = function(node) {
+ var lines = node.value.split('\n');
+ lines.forEach(function(line, index){
+ var isFirst = index === 0;
+ var isLast = index === (lines.length - 1);
+
+ if(/\r$/.test(line)) {
+ markers.push({
+ pos: {
+ sl: node.pos.sl + index,
+ el: node.pos.sl + index,
+ sc: line.length - 1,
+ ec: line.length
+ },
+ type: 'warning',
+ level: 'warning',
+ message: '[SW01] Detected CRLF'
+ });
+ }
+
+ var match = line.match(/\t+/);
+ if(match !== null){
+ markers.push({
+ pos: {
+ sl: node.pos.sl + index,
+ el: node.pos.sl + index,
+ sc: match.index,
+ ec: match.index + match[0].length
+ },
+ type: 'warning',
+ level: 'warning',
+ message: '[SW02] Tabs detected'
+ });
+ }
+
+ if((!isFirst) && isLast){
+ match = line.match(/^\ +/);
+ if(match !== null) {
+ var mod = match[0].length % tab.length;
+ if(mod !== 0) {
+ markers.push({
+ pos: {
+ sl: node.pos.sl + index,
+ el: node.pos.sl + index,
+ sc: match.index,
+ ec: match.index + match[0].length
+ },
+ type: 'warning',
+ level: 'warning',
+ message: '[SW03] Unexcepted indentation of ' + match[0].length
+ });
+ }
+ }
+ }
+ });
+ return true;
+ };
+
+ this.visit = function (node, index) {
+ var name = node.name;
+ var skip = false;
+
+ if (typeof this[name] === 'function') {
+ skip = this[name](node, index) === true;
+ }
+
+ if (!skip) {
+ this.visitChildren(node);
+ }
+ };
+
+ this.visitChildren = function (node, handler) {
+ for (var i = 0; i < node.children.length; i++) {
+ var child = node.children[i];
+ if (handler !== undefined && typeof handler[child.name] === 'function') {
+ handler[child.name](child);
+ } else {
+ this.visit(child);
+ }
+ }
+ };
+
+ source.split('\n').forEach(function(line, index){
+ var match = line.match(/\ +$/);
+ if(match){
+ markers.push({
+ pos: {
+ sl: index,
+ el: index,
+ sc: match.index,
+ ec: match.index + match[0].length
+ },
+ type: 'warning',
+ level: 'warning',
+ message: '[SW04] Trailing whitespace'
+ });
+ }
+ });
+ this.visit(ast);
+};
+},{}],"/node_modules/xqlint/lib/lexers/JSONiqTokenizer.js":[function(_dereq_,module,exports){
+ var JSONiqTokenizer = exports.JSONiqTokenizer = function JSONiqTokenizer(string, parsingEventHandler)
+ {
+ init(string, parsingEventHandler);
+ var self = this;
+
+ this.ParseException = function(b, e, s, o, x)
+ {
+ var
+ begin = b,
+ end = e,
+ state = s,
+ offending = o,
+ expected = x;
+
+ this.getBegin = function() {return begin;};
+ this.getEnd = function() {return end;};
+ this.getState = function() {return state;};
+ this.getExpected = function() {return expected;};
+ this.getOffending = function() {return offending;};
+
+ this.getMessage = function()
+ {
+ return offending < 0 ? "lexical analysis failed" : "syntax error";
+ };
+ };
+
+ function init(string, parsingEventHandler)
+ {
+ eventHandler = parsingEventHandler;
+ input = string;
+ size = string.length;
+ reset(0, 0, 0);
+ }
+
+ this.getInput = function()
+ {
+ return input;
+ };
+
+ function reset(l, b, e)
+ {
+ b0 = b; e0 = b;
+ l1 = l; b1 = b; e1 = e;
+ end = e;
+ eventHandler.reset(input);
+ }
+
+ this.getOffendingToken = function(e)
+ {
+ var o = e.getOffending();
+ return o >= 0 ? JSONiqTokenizer.TOKEN[o] : null;
+ };
+
+ this.getExpectedTokenSet = function(e)
+ {
+ var expected;
+ if (e.getExpected() < 0)
+ {
+ expected = JSONiqTokenizer.getTokenSet(- e.getState());
+ }
+ else
+ {
+ expected = [JSONiqTokenizer.TOKEN[e.getExpected()]];
+ }
+ return expected;
+ };
+
+ this.getErrorMessage = function(e)
+ {
+ var tokenSet = this.getExpectedTokenSet(e);
+ var found = this.getOffendingToken(e);
+ var prefix = input.substring(0, e.getBegin());
+ var lines = prefix.split("\n");
+ var line = lines.length;
+ var column = lines[line - 1].length + 1;
+ var size = e.getEnd() - e.getBegin();
+ return e.getMessage()
+ + (found == null ? "" : ", found " + found)
+ + "\nwhile expecting "
+ + (tokenSet.length == 1 ? tokenSet[0] : ("[" + tokenSet.join(", ") + "]"))
+ + "\n"
+ + (size == 0 || found != null ? "" : "after successfully scanning " + size + " characters beginning ")
+ + "at line " + line + ", column " + column + ":\n..."
+ + input.substring(e.getBegin(), Math.min(input.length, e.getBegin() + 64))
+ + "...";
+ };
+
+ this.parse_start = function()
+ {
+ eventHandler.startNonterminal("start", e0);
+ lookahead1W(14); // ModuleDecl | Annotation | OptionDecl | Operator | Variable | Tag | AttrTest |
+ switch (l1)
+ {
+ case 58: // '<![CDATA['
+ shift(58); // '<![CDATA['
+ break;
+ case 57: // '<!--'
+ shift(57); // '<!--'
+ break;
+ case 59: // '<?'
+ shift(59); // '<?'
+ break;
+ case 43: // '(#'
+ shift(43); // '(#'
+ break;
+ case 45: // '(:~'
+ shift(45); // '(:~'
+ break;
+ case 44: // '(:'
+ shift(44); // '(:'
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ case 277: // '}'
+ shift(277); // '}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ case 42: // '('
+ shift(42); // '('
+ break;
+ case 46: // ')'
+ shift(46); // ')'
+ break;
+ case 52: // '/'
+ shift(52); // '/'
+ break;
+ case 65: // '['
+ shift(65); // '['
+ break;
+ case 66: // ']'
+ shift(66); // ']'
+ break;
+ case 49: // ','
+ shift(49); // ','
+ break;
+ case 51: // '.'
+ shift(51); // '.'
+ break;
+ case 56: // ';'
+ shift(56); // ';'
+ break;
+ case 54: // ':'
+ shift(54); // ':'
+ break;
+ case 36: // '!'
+ shift(36); // '!'
+ break;
+ case 276: // '|'
+ shift(276); // '|'
+ break;
+ case 40: // '$$'
+ shift(40); // '$$'
+ break;
+ case 5: // Annotation
+ shift(5); // Annotation
+ break;
+ case 4: // ModuleDecl
+ shift(4); // ModuleDecl
+ break;
+ case 6: // OptionDecl
+ shift(6); // OptionDecl
+ break;
+ case 15: // AttrTest
+ shift(15); // AttrTest
+ break;
+ case 16: // Wildcard
+ shift(16); // Wildcard
+ break;
+ case 18: // IntegerLiteral
+ shift(18); // IntegerLiteral
+ break;
+ case 19: // DecimalLiteral
+ shift(19); // DecimalLiteral
+ break;
+ case 20: // DoubleLiteral
+ shift(20); // DoubleLiteral
+ break;
+ case 8: // Variable
+ shift(8); // Variable
+ break;
+ case 9: // Tag
+ shift(9); // Tag
+ break;
+ case 7: // Operator
+ shift(7); // Operator
+ break;
+ case 35: // EOF
+ shift(35); // EOF
+ break;
+ default:
+ parse_EQName();
+ }
+ eventHandler.endNonterminal("start", e0);
+ };
+
+ this.parse_StartTag = function()
+ {
+ eventHandler.startNonterminal("StartTag", e0);
+ lookahead1W(8); // QName | S^WS | EOF | '"' | "'" | '/>' | '=' | '>'
+ switch (l1)
+ {
+ case 61: // '>'
+ shift(61); // '>'
+ break;
+ case 53: // '/>'
+ shift(53); // '/>'
+ break;
+ case 29: // QName
+ shift(29); // QName
+ break;
+ case 60: // '='
+ shift(60); // '='
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("StartTag", e0);
+ };
+
+ this.parse_TagContent = function()
+ {
+ eventHandler.startNonterminal("TagContent", e0);
+ lookahead1(11); // Tag | EndTag | PredefinedEntityRef | ElementContentChar | CharRef | EOF |
+ switch (l1)
+ {
+ case 25: // ElementContentChar
+ shift(25); // ElementContentChar
+ break;
+ case 9: // Tag
+ shift(9); // Tag
+ break;
+ case 10: // EndTag
+ shift(10); // EndTag
+ break;
+ case 58: // '<![CDATA['
+ shift(58); // '<![CDATA['
+ break;
+ case 57: // '<!--'
+ shift(57); // '<!--'
+ break;
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 275: // '{{'
+ shift(275); // '{{'
+ break;
+ case 278: // '}}'
+ shift(278); // '}}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("TagContent", e0);
+ };
+
+ this.parse_AposAttr = function()
+ {
+ eventHandler.startNonterminal("AposAttr", e0);
+ lookahead1(10); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | EOF | "'" |
+ switch (l1)
+ {
+ case 23: // EscapeApos
+ shift(23); // EscapeApos
+ break;
+ case 27: // AposAttrContentChar
+ shift(27); // AposAttrContentChar
+ break;
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 275: // '{{'
+ shift(275); // '{{'
+ break;
+ case 278: // '}}'
+ shift(278); // '}}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("AposAttr", e0);
+ };
+
+ this.parse_QuotAttr = function()
+ {
+ eventHandler.startNonterminal("QuotAttr", e0);
+ lookahead1(9); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | EOF | '"' |
+ switch (l1)
+ {
+ case 22: // EscapeQuot
+ shift(22); // EscapeQuot
+ break;
+ case 26: // QuotAttrContentChar
+ shift(26); // QuotAttrContentChar
+ break;
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 275: // '{{'
+ shift(275); // '{{'
+ break;
+ case 278: // '}}'
+ shift(278); // '}}'
+ break;
+ case 274: // '{'
+ shift(274); // '{'
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("QuotAttr", e0);
+ };
+
+ this.parse_CData = function()
+ {
+ eventHandler.startNonterminal("CData", e0);
+ lookahead1(1); // CDataSectionContents | EOF | ']]>'
+ switch (l1)
+ {
+ case 14: // CDataSectionContents
+ shift(14); // CDataSectionContents
+ break;
+ case 67: // ']]>'
+ shift(67); // ']]>'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("CData", e0);
+ };
+
+ this.parse_XMLComment = function()
+ {
+ eventHandler.startNonterminal("XMLComment", e0);
+ lookahead1(0); // DirCommentContents | EOF | '-->'
+ switch (l1)
+ {
+ case 12: // DirCommentContents
+ shift(12); // DirCommentContents
+ break;
+ case 50: // '-->'
+ shift(50); // '-->'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("XMLComment", e0);
+ };
+
+ this.parse_PI = function()
+ {
+ eventHandler.startNonterminal("PI", e0);
+ lookahead1(3); // DirPIContents | EOF | '?' | '?>'
+ switch (l1)
+ {
+ case 13: // DirPIContents
+ shift(13); // DirPIContents
+ break;
+ case 62: // '?'
+ shift(62); // '?'
+ break;
+ case 63: // '?>'
+ shift(63); // '?>'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("PI", e0);
+ };
+
+ this.parse_Pragma = function()
+ {
+ eventHandler.startNonterminal("Pragma", e0);
+ lookahead1(2); // PragmaContents | EOF | '#' | '#)'
+ switch (l1)
+ {
+ case 11: // PragmaContents
+ shift(11); // PragmaContents
+ break;
+ case 38: // '#'
+ shift(38); // '#'
+ break;
+ case 39: // '#)'
+ shift(39); // '#)'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("Pragma", e0);
+ };
+
+ this.parse_Comment = function()
+ {
+ eventHandler.startNonterminal("Comment", e0);
+ lookahead1(4); // CommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 55: // ':)'
+ shift(55); // ':)'
+ break;
+ case 44: // '(:'
+ shift(44); // '(:'
+ break;
+ case 32: // CommentContents
+ shift(32); // CommentContents
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("Comment", e0);
+ };
+
+ this.parse_CommentDoc = function()
+ {
+ eventHandler.startNonterminal("CommentDoc", e0);
+ lookahead1(6); // DocTag | DocCommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 33: // DocTag
+ shift(33); // DocTag
+ break;
+ case 34: // DocCommentContents
+ shift(34); // DocCommentContents
+ break;
+ case 55: // ':)'
+ shift(55); // ':)'
+ break;
+ case 44: // '(:'
+ shift(44); // '(:'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("CommentDoc", e0);
+ };
+
+ this.parse_QuotString = function()
+ {
+ eventHandler.startNonterminal("QuotString", e0);
+ lookahead1(5); // JSONChar | JSONCharRef | JSONPredefinedCharRef | EOF | '"'
+ switch (l1)
+ {
+ case 3: // JSONPredefinedCharRef
+ shift(3); // JSONPredefinedCharRef
+ break;
+ case 2: // JSONCharRef
+ shift(2); // JSONCharRef
+ break;
+ case 1: // JSONChar
+ shift(1); // JSONChar
+ break;
+ case 37: // '"'
+ shift(37); // '"'
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("QuotString", e0);
+ };
+
+ this.parse_AposString = function()
+ {
+ eventHandler.startNonterminal("AposString", e0);
+ lookahead1(7); // PredefinedEntityRef | EscapeApos | AposChar | CharRef | EOF | "'"
+ switch (l1)
+ {
+ case 21: // PredefinedEntityRef
+ shift(21); // PredefinedEntityRef
+ break;
+ case 31: // CharRef
+ shift(31); // CharRef
+ break;
+ case 23: // EscapeApos
+ shift(23); // EscapeApos
+ break;
+ case 24: // AposChar
+ shift(24); // AposChar
+ break;
+ case 41: // "'"
+ shift(41); // "'"
+ break;
+ default:
+ shift(35); // EOF
+ }
+ eventHandler.endNonterminal("AposString", e0);
+ };
+
+ this.parse_Prefix = function()
+ {
+ eventHandler.startNonterminal("Prefix", e0);
+ lookahead1W(13); // NCName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_NCName();
+ eventHandler.endNonterminal("Prefix", e0);
+ };
+
+ this.parse__EQName = function()
+ {
+ eventHandler.startNonterminal("_EQName", e0);
+ lookahead1W(12); // EQName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_EQName();
+ eventHandler.endNonterminal("_EQName", e0);
+ };
+
+ function parse_EQName()
+ {
+ eventHandler.startNonterminal("EQName", e0);
+ switch (l1)
+ {
+ case 80: // 'attribute'
+ shift(80); // 'attribute'
+ break;
+ case 94: // 'comment'
+ shift(94); // 'comment'
+ break;
+ case 118: // 'document-node'
+ shift(118); // 'document-node'
+ break;
+ case 119: // 'element'
+ shift(119); // 'element'
+ break;
+ case 122: // 'empty-sequence'
+ shift(122); // 'empty-sequence'
+ break;
+ case 143: // 'function'
+ shift(143); // 'function'
+ break;
+ case 150: // 'if'
+ shift(150); // 'if'
+ break;
+ case 163: // 'item'
+ shift(163); // 'item'
+ break;
+ case 183: // 'namespace-node'
+ shift(183); // 'namespace-node'
+ break;
+ case 189: // 'node'
+ shift(189); // 'node'
+ break;
+ case 214: // 'processing-instruction'
+ shift(214); // 'processing-instruction'
+ break;
+ case 224: // 'schema-attribute'
+ shift(224); // 'schema-attribute'
+ break;
+ case 225: // 'schema-element'
+ shift(225); // 'schema-element'
+ break;
+ case 241: // 'switch'
+ shift(241); // 'switch'
+ break;
+ case 242: // 'text'
+ shift(242); // 'text'
+ break;
+ case 251: // 'typeswitch'
+ shift(251); // 'typeswitch'
+ break;
+ default:
+ parse_FunctionName();
+ }
+ eventHandler.endNonterminal("EQName", e0);
+ }
+
+ function parse_FunctionName()
+ {
+ eventHandler.startNonterminal("FunctionName", e0);
+ switch (l1)
+ {
+ case 17: // EQName^Token
+ shift(17); // EQName^Token
+ break;
+ case 68: // 'after'
+ shift(68); // 'after'
+ break;
+ case 71: // 'ancestor'
+ shift(71); // 'ancestor'
+ break;
+ case 72: // 'ancestor-or-self'
+ shift(72); // 'ancestor-or-self'
+ break;
+ case 73: // 'and'
+ shift(73); // 'and'
+ break;
+ case 77: // 'as'
+ shift(77); // 'as'
+ break;
+ case 78: // 'ascending'
+ shift(78); // 'ascending'
+ break;
+ case 82: // 'before'
+ shift(82); // 'before'
+ break;
+ case 86: // 'case'
+ shift(86); // 'case'
+ break;
+ case 87: // 'cast'
+ shift(87); // 'cast'
+ break;
+ case 88: // 'castable'
+ shift(88); // 'castable'
+ break;
+ case 91: // 'child'
+ shift(91); // 'child'
+ break;
+ case 92: // 'collation'
+ shift(92); // 'collation'
+ break;
+ case 101: // 'copy'
+ shift(101); // 'copy'
+ break;
+ case 103: // 'count'
+ shift(103); // 'count'
+ break;
+ case 106: // 'declare'
+ shift(106); // 'declare'
+ break;
+ case 107: // 'default'
+ shift(107); // 'default'
+ break;
+ case 108: // 'delete'
+ shift(108); // 'delete'
+ break;
+ case 109: // 'descendant'
+ shift(109); // 'descendant'
+ break;
+ case 110: // 'descendant-or-self'
+ shift(110); // 'descendant-or-self'
+ break;
+ case 111: // 'descending'
+ shift(111); // 'descending'
+ break;
+ case 116: // 'div'
+ shift(116); // 'div'
+ break;
+ case 117: // 'document'
+ shift(117); // 'document'
+ break;
+ case 120: // 'else'
+ shift(120); // 'else'
+ break;
+ case 121: // 'empty'
+ shift(121); // 'empty'
+ break;
+ case 124: // 'end'
+ shift(124); // 'end'
+ break;
+ case 126: // 'eq'
+ shift(126); // 'eq'
+ break;
+ case 127: // 'every'
+ shift(127); // 'every'
+ break;
+ case 129: // 'except'
+ shift(129); // 'except'
+ break;
+ case 132: // 'first'
+ shift(132); // 'first'
+ break;
+ case 133: // 'following'
+ shift(133); // 'following'
+ break;
+ case 134: // 'following-sibling'
+ shift(134); // 'following-sibling'
+ break;
+ case 135: // 'for'
+ shift(135); // 'for'
+ break;
+ case 144: // 'ge'
+ shift(144); // 'ge'
+ break;
+ case 146: // 'group'
+ shift(146); // 'group'
+ break;
+ case 148: // 'gt'
+ shift(148); // 'gt'
+ break;
+ case 149: // 'idiv'
+ shift(149); // 'idiv'
+ break;
+ case 151: // 'import'
+ shift(151); // 'import'
+ break;
+ case 157: // 'insert'
+ shift(157); // 'insert'
+ break;
+ case 158: // 'instance'
+ shift(158); // 'instance'
+ break;
+ case 160: // 'intersect'
+ shift(160); // 'intersect'
+ break;
+ case 161: // 'into'
+ shift(161); // 'into'
+ break;
+ case 162: // 'is'
+ shift(162); // 'is'
+ break;
+ case 168: // 'last'
+ shift(168); // 'last'
+ break;
+ case 170: // 'le'
+ shift(170); // 'le'
+ break;
+ case 172: // 'let'
+ shift(172); // 'let'
+ break;
+ case 176: // 'lt'
+ shift(176); // 'lt'
+ break;
+ case 178: // 'mod'
+ shift(178); // 'mod'
+ break;
+ case 179: // 'modify'
+ shift(179); // 'modify'
+ break;
+ case 180: // 'module'
+ shift(180); // 'module'
+ break;
+ case 182: // 'namespace'
+ shift(182); // 'namespace'
+ break;
+ case 184: // 'ne'
+ shift(184); // 'ne'
+ break;
+ case 196: // 'only'
+ shift(196); // 'only'
+ break;
+ case 198: // 'or'
+ shift(198); // 'or'
+ break;
+ case 199: // 'order'
+ shift(199); // 'order'
+ break;
+ case 200: // 'ordered'
+ shift(200); // 'ordered'
+ break;
+ case 204: // 'parent'
+ shift(204); // 'parent'
+ break;
+ case 210: // 'preceding'
+ shift(210); // 'preceding'
+ break;
+ case 211: // 'preceding-sibling'
+ shift(211); // 'preceding-sibling'
+ break;
+ case 216: // 'rename'
+ shift(216); // 'rename'
+ break;
+ case 217: // 'replace'
+ shift(217); // 'replace'
+ break;
+ case 218: // 'return'
+ shift(218); // 'return'
+ break;
+ case 222: // 'satisfies'
+ shift(222); // 'satisfies'
+ break;
+ case 227: // 'self'
+ shift(227); // 'self'
+ break;
+ case 233: // 'some'
+ shift(233); // 'some'
+ break;
+ case 234: // 'stable'
+ shift(234); // 'stable'
+ break;
+ case 235: // 'start'
+ shift(235); // 'start'
+ break;
+ case 246: // 'to'
+ shift(246); // 'to'
+ break;
+ case 247: // 'treat'
+ shift(247); // 'treat'
+ break;
+ case 248: // 'try'
+ shift(248); // 'try'
+ break;
+ case 252: // 'union'
+ shift(252); // 'union'
+ break;
+ case 254: // 'unordered'
+ shift(254); // 'unordered'
+ break;
+ case 258: // 'validate'
+ shift(258); // 'validate'
+ break;
+ case 264: // 'where'
+ shift(264); // 'where'
+ break;
+ case 268: // 'with'
+ shift(268); // 'with'
+ break;
+ case 272: // 'xquery'
+ shift(272); // 'xquery'
+ break;
+ case 70: // 'allowing'
+ shift(70); // 'allowing'
+ break;
+ case 79: // 'at'
+ shift(79); // 'at'
+ break;
+ case 81: // 'base-uri'
+ shift(81); // 'base-uri'
+ break;
+ case 83: // 'boundary-space'
+ shift(83); // 'boundary-space'
+ break;
+ case 84: // 'break'
+ shift(84); // 'break'
+ break;
+ case 89: // 'catch'
+ shift(89); // 'catch'
+ break;
+ case 96: // 'construction'
+ shift(96); // 'construction'
+ break;
+ case 99: // 'context'
+ shift(99); // 'context'
+ break;
+ case 100: // 'continue'
+ shift(100); // 'continue'
+ break;
+ case 102: // 'copy-namespaces'
+ shift(102); // 'copy-namespaces'
+ break;
+ case 104: // 'decimal-format'
+ shift(104); // 'decimal-format'
+ break;
+ case 123: // 'encoding'
+ shift(123); // 'encoding'
+ break;
+ case 130: // 'exit'
+ shift(130); // 'exit'
+ break;
+ case 131: // 'external'
+ shift(131); // 'external'
+ break;
+ case 139: // 'ft-option'
+ shift(139); // 'ft-option'
+ break;
+ case 152: // 'in'
+ shift(152); // 'in'
+ break;
+ case 153: // 'index'
+ shift(153); // 'index'
+ break;
+ case 159: // 'integrity'
+ shift(159); // 'integrity'
+ break;
+ case 169: // 'lax'
+ shift(169); // 'lax'
+ break;
+ case 190: // 'nodes'
+ shift(190); // 'nodes'
+ break;
+ case 197: // 'option'
+ shift(197); // 'option'
+ break;
+ case 201: // 'ordering'
+ shift(201); // 'ordering'
+ break;
+ case 220: // 'revalidation'
+ shift(220); // 'revalidation'
+ break;
+ case 223: // 'schema'
+ shift(223); // 'schema'
+ break;
+ case 226: // 'score'
+ shift(226); // 'score'
+ break;
+ case 232: // 'sliding'
+ shift(232); // 'sliding'
+ break;
+ case 238: // 'strict'
+ shift(238); // 'strict'
+ break;
+ case 249: // 'tumbling'
+ shift(249); // 'tumbling'
+ break;
+ case 250: // 'type'
+ shift(250); // 'type'
+ break;
+ case 255: // 'updating'
+ shift(255); // 'updating'
+ break;
+ case 259: // 'value'
+ shift(259); // 'value'
+ break;
+ case 260: // 'variable'
+ shift(260); // 'variable'
+ break;
+ case 261: // 'version'
+ shift(261); // 'version'
+ break;
+ case 265: // 'while'
+ shift(265); // 'while'
+ break;
+ case 95: // 'constraint'
+ shift(95); // 'constraint'
+ break;
+ case 174: // 'loop'
+ shift(174); // 'loop'
+ break;
+ default:
+ shift(219); // 'returning'
+ }
+ eventHandler.endNonterminal("FunctionName", e0);
+ }
+
+ function parse_NCName()
+ {
+ eventHandler.startNonterminal("NCName", e0);
+ switch (l1)
+ {
+ case 28: // NCName^Token
+ shift(28); // NCName^Token
+ break;
+ case 68: // 'after'
+ shift(68); // 'after'
+ break;
+ case 73: // 'and'
+ shift(73); // 'and'
+ break;
+ case 77: // 'as'
+ shift(77); // 'as'
+ break;
+ case 78: // 'ascending'
+ shift(78); // 'ascending'
+ break;
+ case 82: // 'before'
+ shift(82); // 'before'
+ break;
+ case 86: // 'case'
+ shift(86); // 'case'
+ break;
+ case 87: // 'cast'
+ shift(87); // 'cast'
+ break;
+ case 88: // 'castable'
+ shift(88); // 'castable'
+ break;
+ case 92: // 'collation'
+ shift(92); // 'collation'
+ break;
+ case 103: // 'count'
+ shift(103); // 'count'
+ break;
+ case 107: // 'default'
+ shift(107); // 'default'
+ break;
+ case 111: // 'descending'
+ shift(111); // 'descending'
+ break;
+ case 116: // 'div'
+ shift(116); // 'div'
+ break;
+ case 120: // 'else'
+ shift(120); // 'else'
+ break;
+ case 121: // 'empty'
+ shift(121); // 'empty'
+ break;
+ case 124: // 'end'
+ shift(124); // 'end'
+ break;
+ case 126: // 'eq'
+ shift(126); // 'eq'
+ break;
+ case 129: // 'except'
+ shift(129); // 'except'
+ break;
+ case 135: // 'for'
+ shift(135); // 'for'
+ break;
+ case 144: // 'ge'
+ shift(144); // 'ge'
+ break;
+ case 146: // 'group'
+ shift(146); // 'group'
+ break;
+ case 148: // 'gt'
+ shift(148); // 'gt'
+ break;
+ case 149: // 'idiv'
+ shift(149); // 'idiv'
+ break;
+ case 158: // 'instance'
+ shift(158); // 'instance'
+ break;
+ case 160: // 'intersect'
+ shift(160); // 'intersect'
+ break;
+ case 161: // 'into'
+ shift(161); // 'into'
+ break;
+ case 162: // 'is'
+ shift(162); // 'is'
+ break;
+ case 170: // 'le'
+ shift(170); // 'le'
+ break;
+ case 172: // 'let'
+ shift(172); // 'let'
+ break;
+ case 176: // 'lt'
+ shift(176); // 'lt'
+ break;
+ case 178: // 'mod'
+ shift(178); // 'mod'
+ break;
+ case 179: // 'modify'
+ shift(179); // 'modify'
+ break;
+ case 184: // 'ne'
+ shift(184); // 'ne'
+ break;
+ case 196: // 'only'
+ shift(196); // 'only'
+ break;
+ case 198: // 'or'
+ shift(198); // 'or'
+ break;
+ case 199: // 'order'
+ shift(199); // 'order'
+ break;
+ case 218: // 'return'
+ shift(218); // 'return'
+ break;
+ case 222: // 'satisfies'
+ shift(222); // 'satisfies'
+ break;
+ case 234: // 'stable'
+ shift(234); // 'stable'
+ break;
+ case 235: // 'start'
+ shift(235); // 'start'
+ break;
+ case 246: // 'to'
+ shift(246); // 'to'
+ break;
+ case 247: // 'treat'
+ shift(247); // 'treat'
+ break;
+ case 252: // 'union'
+ shift(252); // 'union'
+ break;
+ case 264: // 'where'
+ shift(264); // 'where'
+ break;
+ case 268: // 'with'
+ shift(268); // 'with'
+ break;
+ case 71: // 'ancestor'
+ shift(71); // 'ancestor'
+ break;
+ case 72: // 'ancestor-or-self'
+ shift(72); // 'ancestor-or-self'
+ break;
+ case 80: // 'attribute'
+ shift(80); // 'attribute'
+ break;
+ case 91: // 'child'
+ shift(91); // 'child'
+ break;
+ case 94: // 'comment'
+ shift(94); // 'comment'
+ break;
+ case 101: // 'copy'
+ shift(101); // 'copy'
+ break;
+ case 106: // 'declare'
+ shift(106); // 'declare'
+ break;
+ case 108: // 'delete'
+ shift(108); // 'delete'
+ break;
+ case 109: // 'descendant'
+ shift(109); // 'descendant'
+ break;
+ case 110: // 'descendant-or-self'
+ shift(110); // 'descendant-or-self'
+ break;
+ case 117: // 'document'
+ shift(117); // 'document'
+ break;
+ case 118: // 'document-node'
+ shift(118); // 'document-node'
+ break;
+ case 119: // 'element'
+ shift(119); // 'element'
+ break;
+ case 122: // 'empty-sequence'
+ shift(122); // 'empty-sequence'
+ break;
+ case 127: // 'every'
+ shift(127); // 'every'
+ break;
+ case 132: // 'first'
+ shift(132); // 'first'
+ break;
+ case 133: // 'following'
+ shift(133); // 'following'
+ break;
+ case 134: // 'following-sibling'
+ shift(134); // 'following-sibling'
+ break;
+ case 143: // 'function'
+ shift(143); // 'function'
+ break;
+ case 150: // 'if'
+ shift(150); // 'if'
+ break;
+ case 151: // 'import'
+ shift(151); // 'import'
+ break;
+ case 157: // 'insert'
+ shift(157); // 'insert'
+ break;
+ case 163: // 'item'
+ shift(163); // 'item'
+ break;
+ case 168: // 'last'
+ shift(168); // 'last'
+ break;
+ case 180: // 'module'
+ shift(180); // 'module'
+ break;
+ case 182: // 'namespace'
+ shift(182); // 'namespace'
+ break;
+ case 183: // 'namespace-node'
+ shift(183); // 'namespace-node'
+ break;
+ case 189: // 'node'
+ shift(189); // 'node'
+ break;
+ case 200: // 'ordered'
+ shift(200); // 'ordered'
+ break;
+ case 204: // 'parent'
+ shift(204); // 'parent'
+ break;
+ case 210: // 'preceding'
+ shift(210); // 'preceding'
+ break;
+ case 211: // 'preceding-sibling'
+ shift(211); // 'preceding-sibling'
+ break;
+ case 214: // 'processing-instruction'
+ shift(214); // 'processing-instruction'
+ break;
+ case 216: // 'rename'
+ shift(216); // 'rename'
+ break;
+ case 217: // 'replace'
+ shift(217); // 'replace'
+ break;
+ case 224: // 'schema-attribute'
+ shift(224); // 'schema-attribute'
+ break;
+ case 225: // 'schema-element'
+ shift(225); // 'schema-element'
+ break;
+ case 227: // 'self'
+ shift(227); // 'self'
+ break;
+ case 233: // 'some'
+ shift(233); // 'some'
+ break;
+ case 241: // 'switch'
+ shift(241); // 'switch'
+ break;
+ case 242: // 'text'
+ shift(242); // 'text'
+ break;
+ case 248: // 'try'
+ shift(248); // 'try'
+ break;
+ case 251: // 'typeswitch'
+ shift(251); // 'typeswitch'
+ break;
+ case 254: // 'unordered'
+ shift(254); // 'unordered'
+ break;
+ case 258: // 'validate'
+ shift(258); // 'validate'
+ break;
+ case 260: // 'variable'
+ shift(260); // 'variable'
+ break;
+ case 272: // 'xquery'
+ shift(272); // 'xquery'
+ break;
+ case 70: // 'allowing'
+ shift(70); // 'allowing'
+ break;
+ case 79: // 'at'
+ shift(79); // 'at'
+ break;
+ case 81: // 'base-uri'
+ shift(81); // 'base-uri'
+ break;
+ case 83: // 'boundary-space'
+ shift(83); // 'boundary-space'
+ break;
+ case 84: // 'break'
+ shift(84); // 'break'
+ break;
+ case 89: // 'catch'
+ shift(89); // 'catch'
+ break;
+ case 96: // 'construction'
+ shift(96); // 'construction'
+ break;
+ case 99: // 'context'
+ shift(99); // 'context'
+ break;
+ case 100: // 'continue'
+ shift(100); // 'continue'
+ break;
+ case 102: // 'copy-namespaces'
+ shift(102); // 'copy-namespaces'
+ break;
+ case 104: // 'decimal-format'
+ shift(104); // 'decimal-format'
+ break;
+ case 123: // 'encoding'
+ shift(123); // 'encoding'
+ break;
+ case 130: // 'exit'
+ shift(130); // 'exit'
+ break;
+ case 131: // 'external'
+ shift(131); // 'external'
+ break;
+ case 139: // 'ft-option'
+ shift(139); // 'ft-option'
+ break;
+ case 152: // 'in'
+ shift(152); // 'in'
+ break;
+ case 153: // 'index'
+ shift(153); // 'index'
+ break;
+ case 159: // 'integrity'
+ shift(159); // 'integrity'
+ break;
+ case 169: // 'lax'
+ shift(169); // 'lax'
+ break;
+ case 190: // 'nodes'
+ shift(190); // 'nodes'
+ break;
+ case 197: // 'option'
+ shift(197); // 'option'
+ break;
+ case 201: // 'ordering'
+ shift(201); // 'ordering'
+ break;
+ case 220: // 'revalidation'
+ shift(220); // 'revalidation'
+ break;
+ case 223: // 'schema'
+ shift(223); // 'schema'
+ break;
+ case 226: // 'score'
+ shift(226); // 'score'
+ break;
+ case 232: // 'sliding'
+ shift(232); // 'sliding'
+ break;
+ case 238: // 'strict'
+ shift(238); // 'strict'
+ break;
+ case 249: // 'tumbling'
+ shift(249); // 'tumbling'
+ break;
+ case 250: // 'type'
+ shift(250); // 'type'
+ break;
+ case 255: // 'updating'
+ shift(255); // 'updating'
+ break;
+ case 259: // 'value'
+ shift(259); // 'value'
+ break;
+ case 261: // 'version'
+ shift(261); // 'version'
+ break;
+ case 265: // 'while'
+ shift(265); // 'while'
+ break;
+ case 95: // 'constraint'
+ shift(95); // 'constraint'
+ break;
+ case 174: // 'loop'
+ shift(174); // 'loop'
+ break;
+ default:
+ shift(219); // 'returning'
+ }
+ eventHandler.endNonterminal("NCName", e0);
+ }
+
+ function shift(t)
+ {
+ if (l1 == t)
+ {
+ whitespace();
+ eventHandler.terminal(JSONiqTokenizer.TOKEN[l1], b1, e1 > size ? size : e1);
+ b0 = b1; e0 = e1; l1 = 0;
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function whitespace()
+ {
+ if (e0 != b1)
+ {
+ b0 = e0;
+ e0 = b1;
+ eventHandler.whitespace(b0, e0);
+ }
+ }
+
+ function matchW(set)
+ {
+ var code;
+ for (;;)
+ {
+ code = match(set);
+ if (code != 30) // S^WS
+ {
+ break;
+ }
+ }
+ return code;
+ }
+
+ function lookahead1W(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = matchW(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead1(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = match(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function error(b, e, s, l, t)
+ {
+ throw new self.ParseException(b, e, s, l, t);
+ }
+
+ var lk, b0, e0;
+ var l1, b1, e1;
+ var eventHandler;
+
+ var input;
+ var size;
+ var begin;
+ var end;
+
+ function match(tokenSetId)
+ {
+ var nonbmp = false;
+ begin = end;
+ var current = end;
+ var result = JSONiqTokenizer.INITIAL[tokenSetId];
+ var state = 0;
+
+ for (var code = result & 4095; code != 0; )
+ {
+ var charclass;
+ var c0 = current < size ? input.charCodeAt(current) : 0;
+ ++current;
+ if (c0 < 0x80)
+ {
+ charclass = JSONiqTokenizer.MAP0[c0];
+ }
+ else if (c0 < 0xd800)
+ {
+ var c1 = c0 >> 4;
+ charclass = JSONiqTokenizer.MAP1[(c0 & 15) + JSONiqTokenizer.MAP1[(c1 & 31) + JSONiqTokenizer.MAP1[c1 >> 5]]];
+ }
+ else
+ {
+ if (c0 < 0xdc00)
+ {
+ var c1 = current < size ? input.charCodeAt(current) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000)
+ {
+ ++current;
+ c0 = ((c0 & 0x3ff) << 10) + (c1 & 0x3ff) + 0x10000;
+ nonbmp = true;
+ }
+ }
+ var lo = 0, hi = 5;
+ for (var m = 3; ; m = (hi + lo) >> 1)
+ {
+ if (JSONiqTokenizer.MAP2[m] > c0) hi = m - 1;
+ else if (JSONiqTokenizer.MAP2[6 + m] < c0) lo = m + 1;
+ else {charclass = JSONiqTokenizer.MAP2[12 + m]; break;}
+ if (lo > hi) {charclass = 0; break;}
+ }
+ }
+
+ state = code;
+ var i0 = (charclass << 12) + code - 1;
+ code = JSONiqTokenizer.TRANSITION[(i0 & 15) + JSONiqTokenizer.TRANSITION[i0 >> 4]];
+
+ if (code > 4095)
+ {
+ result = code;
+ code &= 4095;
+ end = current;
+ }
+ }
+
+ result >>= 12;
+ if (result == 0)
+ {
+ end = current - 1;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ return error(begin, end, state, -1, -1);
+ }
+
+ if (nonbmp)
+ {
+ for (var i = result >> 9; i > 0; --i)
+ {
+ --end;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ }
+ }
+ else
+ {
+ end -= result >> 9;
+ }
+
+ return (result & 511) - 1;
+ }
+}
+
+JSONiqTokenizer.getTokenSet = function(tokenSetId)
+{
+ var set = [];
+ var s = tokenSetId < 0 ? - tokenSetId : INITIAL[tokenSetId] & 4095;
+ for (var i = 0; i < 279; i += 32)
+ {
+ var j = i;
+ var i0 = (i >> 5) * 2066 + s - 1;
+ var i1 = i0 >> 2;
+ var i2 = i1 >> 2;
+ var f = JSONiqTokenizer.EXPECTED[(i0 & 3) + JSONiqTokenizer.EXPECTED[(i1 & 3) + JSONiqTokenizer.EXPECTED[(i2 & 3) + JSONiqTokenizer.EXPECTED[i2 >> 2]]]];
+ for ( ; f != 0; f >>>= 1, ++j)
+ {
+ if ((f & 1) != 0)
+ {
+ set.push(JSONiqTokenizer.TOKEN[j]);
+ }
+ }
+ }
+ return set;
+};
+
+JSONiqTokenizer.MAP0 =
+[ 67, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 37, 31, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 31, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 31, 62, 63, 64, 65, 37
+];
+
+JSONiqTokenizer.MAP1 =
+[ 108, 124, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 156, 181, 181, 181, 181, 181, 214, 215, 213, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 247, 261, 277, 293, 309, 347, 363, 379, 416, 416, 416, 408, 331, 323, 331, 323, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 433, 433, 433, 433, 433, 433, 433, 316, 331, 331, 331, 331, 331, 331, 331, 331, 394, 416, 416, 417, 415, 416, 416, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 330, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 67, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 37, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 37, 31, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 31, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 31, 62, 63, 64, 65, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 31, 31, 37, 37, 37, 37, 37, 37, 37, 66, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66
+];
+
+JSONiqTokenizer.MAP2 =
+[ 57344, 63744, 64976, 65008, 65536, 983040, 63743, 64975, 65007, 65533, 983039, 1114111, 37, 31, 37, 31, 31, 37
+];
+
+JSONiqTokenizer.INITIAL =
+[ 1, 2, 49155, 57348, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
+];
+
+JSONiqTokenizer.TRANSITION =
+[ 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 17408, 19288, 17439, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 22126, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17672, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 19469, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 36919, 18234, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18419, 18432, 18304, 18448, 18485, 18523, 18553, 18583, 18599, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 18825, 18841, 18871, 18906, 18944, 18960, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19074, 36169, 17439, 36866, 17466, 36890, 36866, 22314, 19105, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 22126, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17672, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 19469, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 36919, 18234, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18419, 18432, 18304, 18448, 18485, 18523, 18553, 18583, 18599, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 18825, 18841, 18871, 18906, 18944, 18960, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22182, 19288, 19121, 36866, 17466, 18345, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19273, 19552, 19304, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19332, 17423, 19363, 36866, 17466, 17537, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 18614, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 19391, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 19427, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36154, 19288, 19457, 36866, 17466, 17740, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22780, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22375, 22197, 18469, 36866, 17466, 36890, 36866, 21991, 24018, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 21331, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 19485, 19501, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19537, 22390, 19568, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19596, 19611, 19457, 36866, 17466, 36890, 36866, 18246, 19627, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22242, 20553, 19457, 36866, 17466, 36890, 36866, 18648, 30477, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36472, 19288, 19457, 36866, 17466, 17809, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 21770, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 19643, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 19672, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 20538, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 17975, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22345, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19726, 19742, 21529, 24035, 23112, 26225, 23511, 27749, 27397, 24035, 34360, 24035, 24036, 23114, 35166, 23114, 23114, 19758, 23511, 35247, 23511, 23511, 28447, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 24254, 19821, 23511, 23511, 23511, 23511, 23512, 19441, 36539, 24035, 24035, 24035, 24035, 19846, 19869, 23114, 23114, 23114, 28618, 32187, 19892, 23511, 23511, 23511, 34585, 20402, 36647, 24035, 24035, 24036, 23114, 33757, 23114, 23114, 23029, 20271, 23511, 27070, 23511, 23511, 30562, 24035, 24035, 29274, 26576, 23114, 23114, 31118, 23036, 29695, 23511, 23511, 32431, 23634, 30821, 24035, 23110, 19913, 23114, 23467, 31261, 23261, 34299, 19932, 24035, 32609, 19965, 35389, 19984, 27689, 19830, 29391, 29337, 20041, 22643, 35619, 33728, 20062, 20121, 20166, 35100, 26145, 20211, 23008, 19876, 20208, 20227, 25670, 20132, 26578, 27685, 20141, 20243, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36094, 19288, 19457, 36866, 17466, 21724, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22735, 19552, 20287, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22750, 19288, 21529, 24035, 23112, 28056, 23511, 29483, 28756, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 20327, 23511, 23511, 23511, 23511, 31156, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 24254, 20371, 23511, 23511, 23511, 23511, 27443, 20395, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 29457, 29700, 23511, 23511, 23511, 23511, 33444, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 28350, 20421, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 20447, 20475, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 20523, 22257, 20569, 20783, 21715, 17603, 20699, 20837, 20614, 20630, 21149, 20670, 21405, 17486, 17509, 17525, 18373, 19179, 20695, 20716, 20732, 20755, 19194, 18042, 21641, 20592, 20779, 20598, 21412, 17470, 17591, 20896, 17468, 17619, 20799, 20700, 21031, 20744, 20699, 20828, 18075, 21259, 20581, 20853, 18048, 20868, 20884, 17756, 17784, 17800, 17825, 17854, 21171, 21200, 20931, 20947, 21378, 20955, 20971, 18086, 20645, 21002, 20986, 18178, 17960, 18012, 18381, 18064, 29176, 21044, 21438, 21018, 21122, 21393, 21060, 21844, 21094, 20654, 17493, 18150, 18166, 18214, 25967, 20763, 21799, 21110, 21830, 21138, 21246, 21301, 18336, 18361, 21165, 21187, 20812, 21216, 21232, 21287, 21317, 18553, 21347, 21363, 21428, 21454, 21271, 21483, 21499, 21515, 21575, 21467, 18712, 21591, 21633, 21078, 18189, 18198, 20679, 21657, 21701, 21074, 21687, 21740, 21756, 21786, 21815, 21860, 21876, 21892, 21946, 21962, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36457, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 36813, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 21981, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 22151, 22007, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 27898, 17884, 18890, 17906, 17928, 22042, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 22070, 22112, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 22142, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36109, 19288, 18469, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22167, 19288, 19457, 36866, 17466, 17768, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22227, 36487, 22273, 36866, 17466, 36890, 36866, 19316, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18749, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 22304, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 19580, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22330, 19089, 19457, 36866, 17466, 18721, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22765, 19347, 19457, 36866, 17466, 36890, 36866, 18114, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34541, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 22540, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29908, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22561, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 23837, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22584, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 27443, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 22839, 23511, 23511, 23511, 23511, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36442, 19288, 21605, 24035, 23112, 28137, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 31568, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22690, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 27584, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 22659, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22360, 19552, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22675, 22811, 19457, 36866, 17466, 36890, 36866, 19133, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 22827, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36139, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36064, 19288, 22865, 22881, 32031, 22897, 22913, 22956, 29939, 24035, 24035, 24035, 23003, 23114, 23114, 23114, 23024, 22420, 23511, 23511, 23511, 23052, 29116, 23073, 29268, 24035, 25563, 26915, 23106, 23131, 23114, 23114, 23159, 23181, 23197, 23248, 23511, 23511, 23282, 23305, 22493, 32364, 24035, 33472, 30138, 26325, 31770, 33508, 27345, 33667, 23114, 23321, 23473, 23351, 35793, 36576, 23511, 23375, 22500, 24145, 24035, 29197, 20192, 24533, 23440, 23114, 19017, 23459, 22839, 23489, 23510, 23511, 33563, 23528, 32076, 25389, 24035, 26576, 23561, 23583, 23114, 32683, 22516, 23622, 23655, 23511, 23634, 35456, 37144, 23110, 23683, 34153, 20499, 32513, 25824, 23705, 24035, 24035, 23111, 23114, 19874, 27078, 33263, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 20507, 32241, 20150, 31862, 27464, 35108, 23727, 23007, 35895, 34953, 26578, 27685, 20141, 24569, 31691, 19787, 33967, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36427, 19552, 21605, 24035, 23112, 32618, 23511, 29483, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 27027, 26576, 23114, 23114, 23114, 31471, 23756, 22468, 23511, 23511, 23511, 34687, 23772, 22493, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34564, 23788, 24035, 24035, 24035, 21559, 23828, 23114, 23114, 23114, 25086, 22839, 23853, 23511, 23511, 23511, 23876, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 31761, 23909, 23953, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36049, 19288, 21605, 30825, 23112, 23987, 23511, 24003, 31001, 27617, 24034, 24035, 24036, 24052, 24089, 23114, 23114, 22420, 24109, 24168, 23511, 23511, 29116, 24188, 27609, 20017, 29516, 24035, 26576, 24222, 19968, 23114, 24252, 33811, 22468, 24270, 33587, 23511, 24320, 27443, 22493, 24035, 24035, 24035, 24035, 24339, 23113, 23114, 23114, 23114, 28128, 28618, 29700, 23511, 23511, 23511, 28276, 34564, 20402, 24035, 24035, 32929, 24036, 23114, 23114, 23114, 24357, 23029, 22839, 23511, 23511, 23511, 24377, 25645, 24035, 34112, 24035, 26576, 23114, 26643, 23114, 32683, 22516, 23511, 25638, 23511, 23711, 24035, 24395, 27809, 23114, 24414, 20499, 24432, 30917, 23628, 24035, 30680, 23111, 23114, 30233, 27078, 25748, 24452, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 24475, 19829, 26577, 26597, 26154, 24519, 24556, 24596, 23007, 20046, 20132, 26578, 24634, 20141, 24569, 31691, 24679, 24727, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36412, 19288, 21605, 19943, 34861, 32618, 26027, 29483, 32016, 32050, 36233, 24776, 35574, 24801, 24819, 32671, 31289, 22420, 24868, 24886, 20087, 26849, 29116, 19803, 24035, 24035, 24035, 36228, 26576, 23114, 23114, 23114, 24981, 33811, 22468, 23511, 23511, 23511, 29028, 27443, 22493, 24923, 27965, 24035, 24035, 32797, 24946, 23443, 23114, 23114, 29636, 24997, 22849, 28252, 23511, 23511, 23511, 25042, 25110, 24035, 24035, 34085, 24036, 25133, 23114, 23114, 25152, 23029, 22839, 25169, 23511, 36764, 23511, 25645, 30403, 24035, 25186, 26576, 31806, 24093, 25212, 32683, 22516, 32713, 26245, 34293, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 24035, 32406, 23111, 23114, 28676, 30944, 27689, 25234, 24035, 23112, 19872, 37063, 23266, 24036, 23114, 30243, 20379, 26100, 29218, 20211, 30105, 25257, 25284, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 24834, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36034, 19288, 21671, 25314, 25072, 25330, 25346, 25362, 29939, 29951, 35288, 29984, 23812, 27216, 25405, 25424, 30456, 22584, 26292, 25461, 25480, 31592, 29116, 25516, 34963, 25545, 27007, 25579, 33937, 25614, 25661, 25686, 34872, 25702, 25718, 25734, 25769, 25795, 25811, 25840, 22493, 26533, 25856, 24035, 25876, 30763, 27481, 25909, 23114, 28987, 25936, 25954, 29700, 25983, 23511, 31412, 26043, 26063, 22568, 29241, 29592, 26116, 31216, 35383, 26170, 34783, 26194, 26221, 22839, 26241, 26261, 22477, 26283, 26308, 27306, 31035, 24655, 26576, 29854, 33386, 26341, 32683, 22516, 32153, 30926, 26361, 19996, 26381, 35463, 26397, 26424, 34646, 26478, 35605, 31386, 26494, 35567, 31964, 22940, 23689, 25218, 30309, 32289, 19830, 33605, 23112, 32109, 27733, 27084, 24496, 35886, 35221, 26525, 36602, 26549, 26558, 26574, 26594, 26613, 26629, 26666, 26700, 26578, 27685, 23740, 24285, 31691, 26733, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36397, 19552, 18991, 25887, 28117, 32618, 26776, 29483, 29939, 26802, 24035, 24035, 24036, 28664, 23114, 23114, 23114, 22420, 30297, 23511, 23511, 23511, 29116, 19803, 24035, 24035, 24035, 25559, 26576, 23114, 23114, 23114, 30525, 33811, 22468, 23511, 23511, 23511, 28725, 27443, 22493, 24035, 24035, 27249, 24035, 24035, 23113, 23114, 23114, 26827, 23114, 28618, 29700, 23511, 23511, 26845, 23511, 34564, 20402, 24035, 24035, 26979, 24036, 23114, 23114, 23114, 24974, 23029, 22839, 23511, 23511, 23511, 26865, 25645, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 32683, 22516, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 20499, 23511, 23261, 23628, 33305, 24035, 25598, 23114, 19874, 34253, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 26886, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 26931, 24569, 26439, 26947, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36019, 19288, 26995, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 27043, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 27061, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 29978, 24035, 24035, 23113, 23114, 33114, 23114, 23114, 30010, 29700, 23511, 35913, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 27155, 26576, 23114, 23114, 30447, 23036, 29695, 23511, 23511, 30935, 20099, 24152, 25529, 27100, 34461, 27121, 22625, 29156, 26009, 27137, 30422, 31903, 31655, 28870, 27171, 32439, 31731, 19830, 27232, 22612, 27265, 26786, 25494, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 20342, 27288, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 27322, 27339, 28020, 27361, 27382, 29939, 24035, 24035, 32581, 24036, 23114, 23114, 23114, 27425, 22420, 23511, 23511, 23511, 27442, 28306, 19803, 24035, 24035, 24035, 24035, 26710, 23114, 23114, 23114, 23114, 32261, 22468, 23511, 23511, 23511, 23511, 35719, 24694, 29510, 24035, 24035, 24035, 24035, 26717, 23114, 23114, 23114, 23114, 28618, 32217, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 27459, 23114, 23114, 23114, 36252, 23029, 20271, 23511, 23511, 23511, 28840, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 27480, 34483, 28401, 29761, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36382, 19288, 21605, 27497, 27517, 28504, 28898, 27569, 29939, 29401, 27600, 27323, 27633, 19025, 27662, 23114, 27705, 22420, 20483, 27721, 23511, 27765, 28306, 19803, 23540, 24035, 24610, 27781, 27805, 26650, 23114, 28573, 32990, 25920, 22468, 26870, 23511, 26684, 34262, 34737, 25057, 34622, 24035, 24035, 23971, 24206, 27825, 27847, 23114, 23114, 27865, 27885, 35766, 27914, 23511, 23511, 32766, 32844, 27934, 28795, 26909, 27955, 26092, 27988, 25445, 28005, 28036, 28052, 21965, 23511, 32196, 19897, 28072, 28102, 36534, 21541, 23801, 28153, 28180, 28197, 28221, 23036, 32695, 28251, 28268, 28292, 23667, 34825, 23930, 24580, 28322, 28344, 31627, 28366, 25996, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 35625, 33477, 33359, 27674, 28393, 33992, 24036, 23114, 30243, 19829, 28417, 28433, 28463, 23008, 19876, 20208, 23007, 20046, 20132, 28489, 28520, 20141, 24569, 31691, 19787, 28550, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 24035, 23112, 32618, 23511, 31507, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 24694, 28589, 24035, 24035, 24035, 24035, 28608, 23114, 23114, 23114, 23114, 28618, 20431, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36004, 19288, 28634, 31951, 28565, 28702, 28718, 28741, 32544, 20175, 28792, 32086, 20105, 28811, 29059, 29862, 28856, 22420, 28886, 30354, 23359, 28922, 28306, 28952, 23888, 26320, 36506, 24035, 29331, 28968, 36609, 23114, 29003, 31661, 27061, 30649, 27366, 23511, 29023, 27918, 24694, 24035, 24035, 23893, 33094, 30867, 23113, 23114, 23114, 29044, 34184, 30010, 29700, 23511, 23511, 29081, 29102, 34585, 20402, 27789, 24035, 24035, 24036, 23114, 29132, 23114, 23114, 23029, 20271, 23511, 29153, 23511, 23511, 30562, 30174, 24035, 24035, 27409, 25438, 23114, 23114, 29172, 36668, 31332, 23511, 23511, 29192, 30144, 24035, 23110, 30203, 23114, 23467, 31544, 23261, 23628, 24035, 22545, 23111, 23114, 29213, 27078, 27689, 29234, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 29257, 23008, 19876, 20208, 28768, 29290, 29320, 34776, 29353, 20141, 22435, 29378, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36367, 19288, 21605, 34616, 19006, 32618, 31497, 31507, 36216, 20184, 24035, 34393, 29424, 34668, 23114, 34900, 29447, 22420, 30360, 23511, 37089, 29473, 28306, 19803, 29499, 24398, 24035, 24035, 26576, 31799, 29532, 29550, 23114, 33811, 22468, 32298, 29571, 31184, 23511, 23512, 37127, 36628, 29589, 24035, 24135, 24035, 23113, 29608, 23114, 27831, 29634, 28618, 29652, 30037, 23511, 24172, 29671, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 29555, 29690, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 29719, 24035, 23110, 29738, 23114, 23467, 34035, 29756, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 29777, 34364, 28181, 30243, 29799, 31920, 27272, 27185, 23008, 31126, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29828, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35989, 19552, 19687, 35139, 28649, 29878, 29894, 29924, 29939, 23224, 23085, 31969, 24036, 35173, 24752, 24803, 23114, 22420, 31190, 30318, 24870, 23511, 28306, 29967, 23967, 24035, 24035, 24035, 26576, 30000, 23114, 23114, 23114, 33811, 22468, 30026, 23511, 23511, 23511, 23512, 26078, 24035, 24035, 24035, 30053, 37137, 30071, 23114, 23114, 33368, 25136, 28618, 30723, 23511, 23511, 37096, 31356, 34585, 20402, 30092, 30127, 30160, 24036, 35740, 30219, 24960, 30259, 23029, 20271, 34042, 30285, 30342, 30376, 23289, 30055, 30400, 30419, 30438, 32640, 33532, 33514, 30472, 18792, 26267, 24323, 23057, 30493, 23639, 20008, 30196, 33188, 30517, 20075, 23511, 30541, 23628, 30578, 33928, 28776, 30594, 19874, 30610, 30637, 19830, 30677, 27646, 19872, 25779, 23266, 23232, 35016, 30243, 30696, 29812, 30712, 30746, 27206, 30779, 30807, 23007, 33395, 20132, 26578, 27685, 31703, 22928, 31691, 19787, 31079, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36352, 19288, 23335, 30841, 26131, 30888, 30904, 30986, 29939, 24035, 24704, 31017, 20025, 23114, 26178, 31051, 31095, 22420, 23511, 22524, 31142, 31172, 28534, 31206, 35497, 25196, 24035, 28592, 24503, 23114, 31239, 31285, 23114, 31305, 31321, 31355, 31372, 31407, 23511, 30556, 24694, 24035, 27501, 19805, 24035, 24035, 23113, 23114, 31428, 24066, 23114, 28618, 29700, 23511, 31837, 18809, 23511, 34585, 31448, 24035, 24035, 24035, 23090, 23114, 23114, 23114, 23114, 31619, 35038, 23511, 23511, 23511, 23511, 33714, 24035, 33085, 24035, 29431, 23114, 31467, 23114, 23143, 31487, 23511, 31523, 23511, 35195, 36783, 24035, 30111, 23567, 23114, 23467, 31543, 31560, 23628, 24035, 24035, 23111, 23114, 19874, 30953, 31584, 34508, 24035, 31608, 26345, 37055, 23266, 31643, 31677, 31719, 31747, 31786, 31822, 26898, 23008, 19876, 31859, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 31878, 31936, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35974, 19288, 21605, 27972, 35663, 31985, 29655, 32001, 36715, 24785, 25893, 23545, 31912, 19853, 19916, 25938, 24540, 22420, 31843, 29674, 29573, 32735, 28936, 19803, 24035, 24035, 32047, 24035, 26576, 23114, 23114, 27544, 23114, 33811, 22468, 23511, 23511, 32161, 23511, 23512, 32066, 24035, 33313, 24035, 24035, 24035, 23113, 27426, 32102, 23114, 23114, 28618, 32125, 23511, 32144, 23511, 23511, 33569, 20402, 24035, 27045, 24035, 24036, 23114, 23114, 28328, 23114, 30076, 32177, 23511, 23511, 30384, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23595, 32212, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 22635, 25753, 32233, 32257, 32277, 19829, 26577, 26597, 20211, 23008, 19876, 32322, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 32352, 35285, 32380, 34196, 33016, 30661, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 32404, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 32422, 23511, 23511, 23511, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 30269, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 19949, 24035, 23111, 32455, 19874, 31269, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36337, 19552, 19209, 21617, 26509, 32475, 32491, 32529, 29939, 24035, 32578, 25241, 32597, 23114, 32634, 29007, 32656, 22420, 23511, 32729, 26365, 32751, 28306, 32788, 32882, 24035, 24035, 32813, 36727, 23114, 33182, 23114, 27553, 33235, 32829, 23511, 32706, 23511, 28906, 28377, 26962, 32881, 32904, 32898, 32920, 24035, 32953, 23114, 32977, 26408, 23114, 28164, 33006, 23511, 33039, 35774, 23511, 32306, 20402, 33076, 30872, 24035, 24036, 25408, 33110, 28979, 23114, 23029, 20271, 35835, 33130, 33054, 23511, 30562, 33148, 24035, 24035, 33167, 23114, 23114, 33775, 23036, 20459, 23511, 23511, 25464, 24646, 24035, 24035, 22446, 23114, 23114, 25627, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 31391, 33204, 33220, 33251, 33287, 26577, 26597, 20211, 33329, 19876, 33345, 23007, 20046, 20132, 26578, 27685, 28473, 22599, 31691, 33411, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35959, 19288, 21907, 27243, 29843, 32618, 33427, 31507, 29939, 33460, 34090, 24035, 24036, 33493, 24416, 33530, 23114, 22420, 33548, 24379, 33585, 23511, 28306, 19803, 33603, 24202, 24035, 24035, 25593, 33749, 28205, 23114, 23114, 32388, 22468, 33853, 33060, 23511, 23511, 31339, 33621, 24035, 24035, 34397, 24618, 30757, 33663, 23114, 23114, 33683, 35684, 28618, 26678, 23511, 23511, 32506, 33699, 34585, 20402, 24035, 32562, 26973, 24036, 23114, 23114, 33377, 33773, 23029, 20271, 23511, 23511, 30621, 23511, 23860, 24035, 33791, 21553, 26576, 36558, 23114, 33809, 23036, 32857, 26047, 23511, 33827, 23634, 24035, 24035, 23110, 23114, 23114, 31252, 23511, 33845, 23628, 24035, 24459, 23111, 23114, 33869, 27078, 30791, 29783, 24035, 24742, 19872, 33895, 23266, 26462, 19710, 33879, 33919, 26577, 26597, 24123, 24930, 21930, 20208, 30501, 33953, 25268, 20252, 33983, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36322, 19552, 23390, 33634, 35154, 34008, 34024, 34058, 35544, 34106, 34128, 26811, 33151, 34144, 34169, 34212, 23114, 34228, 34244, 34278, 34315, 23511, 34331, 34347, 34380, 34413, 24035, 24663, 26576, 34429, 34453, 34477, 29534, 33811, 22468, 34499, 34524, 34557, 25170, 34580, 35436, 23937, 34601, 24035, 24341, 26453, 23113, 34638, 34662, 23114, 24236, 28618, 34684, 34703, 34729, 23511, 35352, 34753, 34799, 24035, 34815, 32558, 34848, 34888, 35814, 34923, 23165, 29137, 23606, 30326, 30730, 34939, 33023, 30562, 36848, 34979, 24035, 24847, 34996, 23114, 23114, 35032, 29695, 35054, 23511, 23511, 35091, 33296, 35124, 24296, 28235, 24361, 36276, 32772, 35067, 35189, 27301, 30855, 24852, 22452, 35211, 35237, 35316, 25500, 35270, 23405, 24304, 35304, 29362, 24036, 23114, 35332, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 35368, 28823, 23920, 32336, 35405, 20141, 24569, 31691, 35421, 35479, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35944, 22795, 21605, 33647, 35877, 35513, 30962, 35529, 34073, 35557, 24035, 24035, 20405, 31107, 23114, 23114, 23114, 35590, 34713, 23511, 23511, 23511, 35641, 19803, 29408, 32937, 25298, 24035, 35657, 23115, 27849, 24760, 35679, 26205, 22468, 23511, 35700, 24907, 24901, 35075, 31893, 34980, 24035, 24035, 24035, 24035, 23113, 35009, 23114, 23114, 23114, 28618, 35716, 30970, 23511, 23511, 23511, 34585, 23215, 24035, 24035, 24035, 24036, 35735, 23114, 23114, 23114, 27105, 35756, 35790, 23511, 23511, 23511, 35254, 35446, 24035, 24035, 31223, 35809, 23114, 23114, 23036, 36825, 35830, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 31031, 20355, 19872, 33903, 23266, 24036, 23114, 28686, 19829, 26577, 26597, 20211, 23008, 23424, 20208, 24711, 31065, 24486, 26578, 27685, 20141, 19773, 35851, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36307, 19288, 21605, 35494, 19702, 32618, 33437, 31507, 29939, 25117, 24035, 27939, 24036, 27869, 23114, 26829, 23114, 22420, 23494, 23511, 33132, 23511, 28306, 19803, 24035, 34832, 24035, 24035, 26576, 23114, 25153, 23114, 23114, 33811, 22468, 23511, 23511, 35911, 23511, 23512, 24694, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 35929, 19288, 21605, 25860, 23112, 36185, 23511, 36201, 29939, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 22420, 23511, 23511, 23511, 23511, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 26748, 24035, 24035, 24035, 24035, 24035, 36249, 23114, 23114, 23114, 23114, 28618, 28835, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 27151, 24035, 26760, 23114, 27989, 23114, 23114, 36268, 20271, 23511, 24436, 23511, 29703, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36292, 19288, 21605, 36503, 21922, 32618, 34534, 31507, 36522, 24035, 33793, 24035, 35864, 23114, 23114, 36555, 23417, 22420, 23511, 23511, 36574, 26020, 28306, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 33811, 22468, 23511, 23511, 23511, 23511, 23512, 36592, 24035, 24035, 36625, 24035, 24035, 23113, 23114, 32961, 23114, 23114, 29618, 29700, 23511, 29086, 23511, 23511, 34585, 20402, 36644, 24035, 24035, 24036, 29740, 23114, 23114, 23114, 29065, 36663, 31527, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36079, 19288, 21605, 31451, 23112, 36684, 23511, 36700, 29939, 24035, 24035, 24035, 30185, 23114, 23114, 23114, 27526, 22420, 23511, 23511, 23511, 32865, 28306, 19803, 36743, 24035, 27017, 24035, 26576, 27535, 23114, 31432, 23114, 33811, 22468, 33271, 23511, 32128, 23511, 23512, 24694, 24035, 27196, 24035, 24035, 24035, 23113, 32459, 23114, 23114, 23114, 28618, 29700, 33829, 36762, 23511, 23511, 34585, 20402, 24035, 36746, 24035, 29722, 23114, 23114, 34437, 23114, 34907, 20271, 23511, 23511, 18801, 23511, 23206, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 36837, 24035, 24035, 33739, 23114, 23114, 25094, 23511, 23261, 23628, 24035, 36780, 23111, 24073, 19874, 27078, 35344, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22720, 19288, 36799, 36866, 17466, 36890, 36864, 21991, 22211, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 17631, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 36883, 36906, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 22705, 19288, 19457, 36866, 17466, 36890, 36866, 19375, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18855, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36124, 19288, 36951, 36866, 17466, 36890, 36866, 21991, 22404, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18567, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 36979, 36995, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36139, 19288, 19457, 36866, 17466, 36890, 36866, 21991, 22971, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18027, 22984, 17553, 17572, 22285, 18462, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 17619, 22083, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 36139, 19288, 21529, 24035, 23112, 23033, 23511, 31507, 25377, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 37040, 23511, 23511, 23511, 23511, 28086, 19803, 24035, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23114, 24254, 37079, 23511, 23511, 23511, 23511, 23512, 34766, 24035, 24035, 24035, 24035, 24035, 23113, 23114, 23114, 23114, 23114, 28618, 29700, 23511, 23511, 23511, 23511, 34585, 20402, 24035, 24035, 24035, 24036, 23114, 23114, 23114, 23114, 23029, 20271, 23511, 23511, 23511, 23511, 30562, 24035, 24035, 24035, 26576, 23114, 23114, 23114, 23036, 29695, 23511, 23511, 23511, 23634, 24035, 24035, 23110, 23114, 23114, 23467, 23511, 23261, 23628, 24035, 24035, 23111, 23114, 19874, 27078, 27689, 19830, 24035, 23112, 19872, 27741, 23266, 24036, 23114, 30243, 19829, 26577, 26597, 20211, 23008, 19876, 20208, 23007, 20046, 20132, 26578, 27685, 20141, 24569, 31691, 19787, 29304, 20268, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 37112, 37160, 18469, 36866, 17466, 36890, 36866, 17656, 37174, 22987, 17556, 17575, 22288, 17486, 17509, 17525, 18373, 18537, 22984, 17553, 17572, 22285, 18780, 17990, 18622, 19411, 20306, 17996, 17689, 17470, 17591, 20896, 17468, 36883, 36906, 36867, 19404, 20299, 36866, 17647, 17862, 18921, 19514, 17705, 20311, 37017, 17728, 17756, 17784, 17800, 17825, 17854, 18403, 18928, 19521, 17712, 37008, 37024, 17878, 18884, 17900, 17922, 17944, 18178, 17960, 18012, 18381, 18064, 18218, 17884, 18890, 17906, 17928, 18102, 25022, 18130, 36931, 36963, 17493, 18150, 18166, 18214, 25010, 25026, 18134, 36935, 18262, 18278, 18294, 18320, 18336, 18361, 18397, 18274, 22096, 18304, 18448, 18485, 18523, 18553, 18583, 19149, 18638, 18497, 19656, 18664, 18680, 18507, 18696, 19164, 18712, 18737, 17681, 22026, 20906, 20915, 22054, 17838, 17450, 22022, 18765, 19225, 18841, 18871, 18906, 19241, 19257, 18976, 19041, 19056, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 19058, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 127011, 110630, 114730, 106539, 127011, 127011, 127011, 53264, 18, 18, 0, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 0, 0, 127011, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2170880, 2170880, 2170880, 3002368, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2576384, 2215936, 2215936, 2215936, 2416640, 2424832, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2543616, 2215936, 2215936, 2215936, 2215936, 2215936, 2629632, 2215936, 2617344, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2691072, 2215936, 2707456, 2215936, 2715648, 2215936, 2723840, 2764800, 2215936, 2215936, 2797568, 2215936, 2822144, 2215936, 2215936, 2854912, 2215936, 2215936, 2215936, 2912256, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 180224, 0, 0, 2174976, 0, 0, 2170880, 2617344, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2691072, 2170880, 2707456, 2170880, 2715648, 2170880, 2723840, 2764800, 2170880, 2170880, 2797568, 2170880, 2170880, 2797568, 2170880, 2822144, 2170880, 2170880, 2854912, 2170880, 2170880, 2170880, 2912256, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2609152, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2654208, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 184599, 280, 0, 2174976, 0, 0, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 544, 0, 546, 0, 0, 2179072, 0, 0, 0, 552, 0, 0, 2170880, 2170880, 2170880, 3117056, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2158592, 2158592, 2232320, 2232320, 0, 2240512, 2240512, 0, 0, 0, 644, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3129344, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2400256, 2215936, 2215936, 2215936, 2215936, 2711552, 2170880, 2170880, 2170880, 2170880, 2170880, 2760704, 2768896, 2789376, 2813952, 2170880, 2170880, 2170880, 2875392, 2904064, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2453504, 2457600, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 167936, 0, 0, 0, 0, 2174976, 0, 0, 2215936, 2215936, 2514944, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2592768, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 32768, 0, 0, 0, 0, 0, 2174976, 32768, 0, 2633728, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2711552, 2215936, 2215936, 2215936, 2215936, 2215936, 2760704, 2768896, 2789376, 2813952, 2215936, 2215936, 2215936, 2875392, 2904064, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 0, 65819, 2215936, 2215936, 3031040, 2215936, 3055616, 2215936, 2215936, 2215936, 2215936, 3092480, 2215936, 2215936, 3125248, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3002368, 2215936, 2215936, 2170880, 2170880, 2494464, 2170880, 2170880, 0, 0, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3198976, 2215936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2379776, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2445312, 2170880, 2465792, 2473984, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2523136, 2170880, 2170880, 2641920, 2170880, 2170880, 2170880, 2699264, 2170880, 2727936, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2879488, 2170880, 2916352, 2170880, 2170880, 2170880, 2879488, 2170880, 2916352, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3026944, 2170880, 2170880, 3063808, 2170880, 2170880, 3112960, 2170880, 2170880, 3133440, 2170880, 2170880, 3112960, 2170880, 2170880, 3133440, 2170880, 2170880, 2170880, 3162112, 2170880, 2170880, 3182592, 3186688, 2170880, 2379776, 2215936, 2523136, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2596864, 2215936, 2621440, 2215936, 2215936, 2641920, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 548, 0, 0, 0, 0, 287, 2170880, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3117056, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2699264, 2215936, 2727936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2879488, 2215936, 2916352, 2215936, 2215936, 0, 0, 0, 0, 188416, 0, 2179072, 0, 0, 0, 0, 0, 287, 2170880, 0, 2171019, 2171019, 2171019, 2400395, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3031179, 2171019, 3055755, 2171019, 2171019, 2215936, 3133440, 2215936, 2215936, 2215936, 3162112, 2215936, 2215936, 3182592, 3186688, 2215936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2523275, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2597003, 2171019, 2621579, 2170880, 2170880, 2170880, 3162112, 2170880, 2170880, 3182592, 3186688, 2170880, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 24, 0, 4337664, 28, 2170880, 2170880, 2170880, 2629632, 2170880, 2170880, 2170880, 2170880, 2719744, 2744320, 2170880, 2170880, 2170880, 2834432, 2838528, 2170880, 2908160, 2170880, 2170880, 2936832, 2215936, 2215936, 2215936, 2215936, 2719744, 2744320, 2215936, 2215936, 2215936, 2834432, 2838528, 2215936, 2908160, 2215936, 2215936, 2936832, 2215936, 2215936, 2985984, 2215936, 2994176, 2215936, 2215936, 3014656, 2215936, 3059712, 3076096, 3088384, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2445312, 2215936, 2465792, 2473984, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2171166, 2171166, 2171166, 2171166, 2171166, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171019, 2171019, 2494603, 2171019, 2171019, 2215936, 2215936, 2215936, 3215360, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2379776, 2170880, 2170880, 2170880, 2170880, 2985984, 2170880, 2994176, 2170880, 2170880, 3016168, 2170880, 3059712, 3076096, 3088384, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 124, 124, 0, 128, 128, 2170880, 2170880, 2170880, 3215360, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2486272, 2170880, 2170880, 2506752, 2170880, 2170880, 2170880, 2535424, 2539520, 2170880, 2170880, 2588672, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2920448, 2170880, 2170880, 2170880, 2990080, 2170880, 2170880, 2170880, 2170880, 3051520, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3170304, 0, 2387968, 2392064, 2170880, 2170880, 2433024, 2170880, 2170880, 2170880, 3170304, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2486272, 2215936, 2215936, 2506752, 2215936, 2215936, 2215936, 2535424, 2539520, 2215936, 2215936, 2588672, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 136, 0, 2215936, 2215936, 2920448, 2215936, 2215936, 2215936, 2990080, 2215936, 2215936, 2215936, 2215936, 3051520, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3108864, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3026944, 2215936, 2215936, 3063808, 2215936, 2215936, 3112960, 2215936, 2215936, 2215936, 3170304, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2453504, 2457600, 2170880, 2170880, 2170880, 2486272, 2170880, 2170880, 2506752, 2170880, 2170880, 2170880, 2537049, 2539520, 2170880, 2170880, 2588672, 2170880, 2170880, 2170880, 1508, 2170880, 2170880, 2170880, 1512, 2170880, 2920448, 2170880, 2170880, 2170880, 2990080, 2170880, 2170880, 2170880, 2461696, 2170880, 2170880, 2170880, 2510848, 2170880, 2170880, 2170880, 2170880, 2580480, 2170880, 2605056, 2637824, 2170880, 2170880, 18, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2686976, 2748416, 2170880, 2170880, 2170880, 2924544, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3121152, 2170880, 2170880, 3145728, 3158016, 3166208, 2170880, 2420736, 2428928, 2170880, 2478080, 2170880, 2170880, 2170880, 2170880, 0, 0, 2170880, 2170880, 2170880, 2170880, 2646016, 2670592, 0, 0, 3145728, 3158016, 3166208, 2387968, 2392064, 2215936, 2215936, 2433024, 2215936, 2461696, 2215936, 2215936, 2215936, 2510848, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 0, 2170880, 2215936, 2215936, 2580480, 2215936, 2605056, 2637824, 2215936, 2215936, 2686976, 2748416, 2215936, 2215936, 2215936, 2924544, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 286, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 3121152, 2215936, 2215936, 3145728, 3158016, 3166208, 2387968, 2392064, 2170880, 2170880, 2433024, 2170880, 2461696, 2170880, 2170880, 2170880, 2510848, 2170880, 2170880, 1625, 2170880, 2170880, 2580480, 2170880, 2605056, 2637824, 2170880, 647, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2576384, 2170880, 2170880, 2170880, 2170880, 2170880, 2609152, 2170880, 2170880, 2686976, 0, 0, 2748416, 2170880, 2170880, 0, 2170880, 2924544, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 0, 0, 28, 28, 2170880, 3141632, 2215936, 2420736, 2428928, 2215936, 2478080, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2646016, 2670592, 2752512, 2756608, 2846720, 2961408, 2215936, 2998272, 2215936, 3010560, 2215936, 2215936, 2215936, 3141632, 2170880, 2420736, 2428928, 2752512, 2756608, 0, 2846720, 2961408, 2170880, 2998272, 2170880, 3010560, 2170880, 2170880, 2170880, 3141632, 2170880, 2170880, 2490368, 2215936, 2490368, 2215936, 2215936, 2215936, 2547712, 2555904, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 245760, 0, 3129344, 2170880, 2170880, 2490368, 2170880, 2170880, 2170880, 0, 0, 2547712, 2555904, 2170880, 2170880, 2170880, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 45056, 0, 2584576, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2170880, 2170880, 2158592, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 0, 1482, 97, 97, 97, 97, 97, 97, 97, 1354, 97, 97, 97, 97, 97, 97, 97, 97, 1148, 97, 97, 97, 97, 97, 97, 97, 2584576, 2170880, 2170880, 1512, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2441216, 2170880, 2527232, 2170880, 2600960, 2170880, 2850816, 2170880, 2170880, 2170880, 3022848, 2215936, 2441216, 2215936, 2527232, 2215936, 2600960, 2215936, 2850816, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 287, 2170880, 2215936, 3022848, 2170880, 2441216, 2170880, 2527232, 0, 0, 2170880, 2600960, 2170880, 0, 2850816, 2170880, 2170880, 2170880, 2170880, 2170880, 2523136, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2596864, 2170880, 2621440, 2170880, 2170880, 2641920, 2170880, 2170880, 2170880, 3022848, 2170880, 2519040, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2519040, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 2453504, 2457600, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2514944, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2592768, 2170880, 2170880, 2519040, 0, 2024, 2170880, 2170880, 0, 2170880, 2170880, 2170880, 2396160, 2170880, 2170880, 2170880, 2170880, 3018752, 2396160, 2215936, 2215936, 2215936, 2215936, 3018752, 2396160, 0, 2024, 2170880, 2170880, 2170880, 2170880, 3018752, 2170880, 2650112, 2965504, 2170880, 2215936, 2650112, 2965504, 2215936, 0, 0, 2170880, 2650112, 2965504, 2170880, 2551808, 2170880, 2551808, 2215936, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 141, 45, 45, 67, 67, 67, 67, 67, 224, 67, 67, 238, 67, 67, 67, 67, 67, 67, 67, 1288, 67, 67, 67, 67, 67, 67, 67, 67, 67, 469, 67, 67, 67, 67, 67, 67, 0, 2551808, 2170880, 2170880, 2215936, 0, 2170880, 2170880, 2215936, 0, 2170880, 2170880, 2215936, 0, 2170880, 2977792, 2977792, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 29, 102432, 127011, 110630, 114730, 106539, 127011, 127011, 127011, 53264, 18, 18, 49172, 0, 0, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 0, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 136, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 4256099, 4256099, 24, 24, 0, 28, 28, 2170880, 2461696, 2170880, 2170880, 2170880, 2510848, 2170880, 2170880, 0, 2170880, 2170880, 2580480, 2170880, 2605056, 2637824, 2170880, 2170880, 2170880, 2547712, 2555904, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3129344, 2215936, 2215936, 543, 543, 545, 545, 0, 0, 2179072, 0, 550, 551, 551, 0, 287, 2171166, 2171166, 18, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 645, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 149, 2584576, 2170880, 2170880, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2441216, 2170880, 2527232, 2170880, 2600960, 2519040, 0, 0, 2170880, 2170880, 0, 2170880, 2170880, 2170880, 2396160, 2170880, 2170880, 2170880, 2170880, 3018752, 2396160, 2215936, 2215936, 2215936, 2215936, 3018752, 2396160, 0, 0, 2170880, 2170880, 2170880, 2170880, 3018752, 2170880, 2650112, 2965504, 53264, 18, 49172, 57366, 24, 155648, 28, 102432, 155648, 155687, 114730, 106539, 0, 0, 155648, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 0, 0, 0, 0, 2220032, 0, 94208, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 208896, 18, 278528, 24, 24, 0, 28, 28, 53264, 18, 159765, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 0, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 139394, 28, 28, 102432, 131, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 32768, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 546, 0, 0, 2183168, 0, 0, 552, 832, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2170880, 2609152, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2654208, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3198976, 2215936, 0, 1084, 0, 1088, 0, 1092, 0, 0, 0, 0, 0, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 937, 0, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 644, 0, 0, 0, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 826, 0, 828, 0, 0, 2183168, 0, 0, 830, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2592768, 2170880, 2170880, 2170880, 2170880, 2633728, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2711552, 2170880, 2170880, 2170880, 2170880, 2170880, 2760704, 53264, 18, 49172, 57366, 24, 8192, 28, 172066, 172032, 110630, 172066, 106539, 0, 0, 172032, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 16384, 28, 28, 28, 28, 102432, 0, 98304, 0, 0, 2220032, 110630, 0, 0, 0, 0, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 45056, 0, 0, 0, 53264, 18, 49172, 57366, 25, 8192, 30, 102432, 0, 110630, 114730, 106539, 0, 0, 176219, 53264, 18, 18, 49172, 0, 57366, 0, 124, 124, 124, 0, 128, 128, 128, 128, 102432, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 0, 546, 0, 0, 2183168, 0, 65536, 552, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2646016, 2670592, 2752512, 2756608, 2846720, 2961408, 2170880, 2998272, 2170880, 3010560, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3198976, 2215936, 0, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 143, 45, 45, 67, 67, 67, 67, 67, 227, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1824, 67, 1826, 67, 67, 67, 67, 17, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 32768, 120, 121, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 67, 67, 37139, 37139, 24853, 24853, 0, 0, 2179072, 548, 0, 65820, 65820, 0, 287, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 2033, 45, 67, 67, 67, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 978, 0, 546, 70179, 0, 2183168, 0, 0, 552, 0, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1013, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 473, 67, 67, 67, 67, 483, 67, 67, 1025, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1119, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1359, 97, 97, 97, 67, 67, 1584, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 497, 67, 67, 1659, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1667, 45, 45, 45, 45, 45, 169, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1668, 45, 45, 45, 45, 67, 67, 1694, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 774, 67, 67, 1713, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 1723, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 1538, 45, 45, 45, 45, 45, 1559, 45, 45, 1561, 45, 45, 45, 45, 45, 45, 45, 687, 45, 45, 45, 45, 45, 45, 45, 45, 448, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1771, 1772, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 67, 67, 67, 67, 67, 1821, 67, 67, 67, 67, 67, 67, 1827, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 1614, 97, 97, 97, 97, 97, 603, 97, 97, 605, 97, 97, 608, 97, 97, 97, 97, 0, 1532, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 450, 45, 45, 45, 45, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 1839, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 97, 1883, 97, 1885, 97, 0, 1888, 0, 97, 97, 0, 97, 97, 1848, 97, 97, 97, 97, 1852, 45, 45, 45, 45, 45, 45, 45, 384, 391, 45, 45, 45, 45, 45, 45, 45, 385, 45, 45, 45, 45, 45, 45, 45, 45, 1237, 45, 45, 45, 45, 45, 45, 67, 0, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 1951, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1963, 97, 2023, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 1994, 67, 1995, 67, 67, 67, 67, 67, 67, 97, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 0, 0, 0, 0, 2220032, 110630, 0, 0, 0, 114730, 106539, 137, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2793472, 2805760, 2170880, 2830336, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3031040, 2170880, 3055616, 2170880, 2170880, 67, 67, 37139, 37139, 24853, 24853, 0, 0, 281, 549, 0, 65820, 65820, 0, 287, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 2031, 2032, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1769, 67, 0, 546, 70179, 549, 549, 0, 0, 552, 0, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1858, 45, 641, 0, 0, 0, 0, 41606, 926, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 456, 67, 0, 0, 0, 1313, 0, 0, 0, 1096, 1319, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1110, 97, 97, 97, 97, 67, 67, 67, 67, 1301, 1476, 0, 0, 0, 0, 1307, 1478, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1486, 97, 1487, 97, 1313, 1480, 0, 0, 0, 0, 1319, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 566, 97, 97, 97, 97, 97, 97, 67, 67, 67, 1476, 0, 1478, 0, 1480, 0, 97, 97, 97, 97, 97, 97, 97, 45, 1853, 45, 1855, 45, 45, 45, 45, 53264, 18, 49172, 57366, 26, 8192, 31, 102432, 0, 110630, 114730, 106539, 0, 0, 225368, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 32768, 53264, 18, 18, 49172, 163840, 57366, 0, 24, 24, 229376, 0, 28, 28, 28, 229376, 102432, 0, 0, 0, 0, 2220167, 110630, 0, 0, 0, 114730, 106539, 0, 2171019, 2171019, 2171019, 2171019, 2592907, 2171019, 2171019, 2171019, 2171019, 2633867, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2654347, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3117195, 2171019, 2171019, 2171019, 2171019, 2240641, 0, 0, 0, 0, 0, 0, 0, 0, 368, 0, 140, 2171019, 2171019, 2171019, 2416779, 2424971, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2617483, 2171019, 2171019, 2642059, 2171019, 2171019, 2171019, 2699403, 2171019, 2728075, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3215499, 2215936, 2215936, 2215936, 2215936, 2215936, 2437120, 2215936, 2215936, 2171019, 2822283, 2171019, 2171019, 2855051, 2171019, 2171019, 2171019, 2912395, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3002507, 2171019, 2171019, 2215936, 2215936, 2494464, 2215936, 2215936, 2215936, 2171166, 2171166, 2416926, 2425118, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2576670, 2171166, 2617630, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2691358, 2171166, 2707742, 2171166, 2715934, 2171166, 2724126, 2765086, 2171166, 2171166, 2797854, 2171166, 2822430, 2171166, 2171166, 2855198, 2171166, 2171166, 2171166, 2912542, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2793758, 2806046, 2171166, 2830622, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3109150, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2543902, 2171166, 2171166, 2171166, 2171166, 2171166, 2629918, 2793611, 2805899, 2171019, 2830475, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 0, 546, 0, 0, 2183168, 0, 0, 552, 0, 2171166, 2171166, 2171166, 2400542, 2171166, 2171166, 2171166, 0, 2171166, 2171166, 2171166, 0, 2171166, 2920734, 2171166, 2171166, 2171166, 2990366, 2171166, 2171166, 2171166, 2171166, 3117342, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 0, 53264, 0, 18, 18, 4329472, 2232445, 0, 2240641, 4337664, 2711691, 2171019, 2171019, 2171019, 2171019, 2171019, 2760843, 2769035, 2789515, 2814091, 2171019, 2171019, 2171019, 2875531, 2904203, 2171019, 2171019, 3092619, 2171019, 2171019, 3125387, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3199115, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2453504, 2457600, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2793472, 2805760, 2215936, 2830336, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2494464, 2170880, 2170880, 2171166, 2171166, 2634014, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2711838, 2171166, 2171166, 2171166, 2171166, 2171166, 2760990, 2769182, 2789662, 2814238, 2171166, 2171166, 2171166, 2875678, 2904350, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3199262, 2171166, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2379915, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2445451, 2171019, 2465931, 2474123, 2171019, 2171019, 3113099, 2171019, 2171019, 3133579, 2171019, 2171019, 2171019, 3162251, 2171019, 2171019, 3182731, 3186827, 2171019, 2379776, 2879627, 2171019, 2916491, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3027083, 2171019, 2171019, 3063947, 2699550, 2171166, 2728222, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2879774, 2171166, 2916638, 2171166, 2171166, 2171166, 2171166, 2171166, 2609438, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2654494, 2171166, 2171166, 2171166, 2171166, 2171166, 2445598, 2171166, 2466078, 2474270, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2523422, 2171019, 2437259, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2543755, 2171019, 2171019, 2171019, 2584715, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2908299, 2171019, 2171019, 2936971, 2171019, 2171019, 2986123, 2171019, 2994315, 2171019, 2171019, 3014795, 2171019, 3059851, 3076235, 3088523, 2171166, 2171166, 2986270, 2171166, 2994462, 2171166, 2171166, 3014942, 2171166, 3059998, 3076382, 3088670, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3027230, 2171166, 2171166, 3064094, 2171166, 2171166, 3113246, 2171166, 2171166, 3133726, 2506891, 2171019, 2171019, 2171019, 2535563, 2539659, 2171019, 2171019, 2588811, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2691211, 2171019, 2707595, 2171019, 2715787, 2171019, 2723979, 2764939, 2171019, 2171019, 2797707, 2215936, 2215936, 3170304, 0, 0, 0, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2453790, 2457886, 2171166, 2171166, 2171166, 2486558, 2171166, 2171166, 2507038, 2171166, 2171166, 2171166, 2535710, 2539806, 2171166, 2171166, 2588958, 2171166, 2171166, 2171166, 2171166, 2515230, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2593054, 2171166, 2171166, 2171166, 2171166, 3051806, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3170590, 0, 2388107, 2392203, 2171019, 2171019, 2433163, 2171019, 2461835, 2171019, 2171019, 2171019, 2510987, 2171019, 2171019, 2171019, 2171019, 2580619, 2171019, 2605195, 2637963, 2171019, 2171019, 2171019, 2920587, 2171019, 2171019, 2171019, 2990219, 2171019, 2171019, 2171019, 2171019, 3051659, 2171019, 2171019, 2171019, 2453643, 2457739, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2515083, 2171019, 2171019, 2171019, 2171019, 2646155, 2670731, 2752651, 2756747, 2846859, 2961547, 2171019, 2998411, 2171019, 3010699, 2171019, 2171019, 2687115, 2748555, 2171019, 2171019, 2171019, 2924683, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3121291, 2171019, 2171019, 2171019, 3170443, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2486272, 2215936, 2215936, 2506752, 3145867, 3158155, 3166347, 2387968, 2392064, 2215936, 2215936, 2433024, 2215936, 2461696, 2215936, 2215936, 2215936, 2510848, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 0, 553, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 3121152, 2215936, 2215936, 3145728, 3158016, 3166208, 2388254, 2392350, 2171166, 2171166, 2433310, 2171166, 2461982, 2171166, 2171166, 2171166, 2511134, 2171166, 2171166, 0, 2171166, 2171166, 2580766, 2171166, 2605342, 2638110, 2171166, 2171166, 2171166, 2171166, 3031326, 2171166, 3055902, 2171166, 2171166, 2171166, 2171166, 3092766, 2171166, 2171166, 3125534, 2171166, 2171166, 2171166, 3162398, 2171166, 2171166, 3182878, 3186974, 2171166, 0, 0, 0, 2171019, 2171019, 2171019, 2171019, 3109003, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2215936, 2215936, 2215936, 2400256, 2215936, 2215936, 2215936, 2215936, 2171166, 2687262, 0, 0, 2748702, 2171166, 2171166, 0, 2171166, 2924830, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 2597150, 2171166, 2621726, 2171166, 2171166, 2642206, 2171166, 2171166, 2171166, 2171166, 3121438, 2171166, 2171166, 3146014, 3158302, 3166494, 2171019, 2420875, 2429067, 2171019, 2478219, 2171019, 2171019, 2171019, 2171019, 2547851, 2556043, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 3129483, 2215936, 2171019, 3141771, 2215936, 2420736, 2428928, 2215936, 2478080, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2646016, 2670592, 2752512, 2756608, 2846720, 2961408, 2215936, 2998272, 2215936, 3010560, 2215936, 2215936, 2215936, 3141632, 2171166, 2421022, 2429214, 2171166, 2478366, 2171166, 2171166, 2171166, 2171166, 0, 0, 2171166, 2171166, 2171166, 2171166, 2646302, 2670878, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 0, 45, 45, 45, 45, 45, 1405, 1406, 45, 45, 45, 45, 1409, 45, 45, 45, 45, 45, 1415, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1238, 45, 45, 45, 45, 67, 2752798, 2756894, 0, 2847006, 2961694, 2171166, 2998558, 2171166, 3010846, 2171166, 2171166, 2171166, 3141918, 2171019, 2171019, 2490507, 3129344, 2171166, 2171166, 2490654, 2171166, 2171166, 2171166, 0, 0, 2547998, 2556190, 2171166, 2171166, 2171166, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 45, 167, 45, 45, 45, 45, 185, 187, 45, 45, 198, 45, 45, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171166, 3129630, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2576523, 2171019, 2171019, 2171019, 2171019, 2171019, 2609291, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3002368, 2215936, 2215936, 2171166, 2171166, 2494750, 2171166, 2171166, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 147, 2584576, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2171166, 2171166, 2171166, 2171166, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 0, 0, 0, 2171166, 2171166, 2171166, 3002654, 2171166, 2171166, 2171019, 2171019, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2175257, 0, 0, 2584862, 2171166, 2171166, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2171019, 2441355, 2171019, 2527371, 2171019, 2601099, 2171019, 2850955, 2171019, 2171019, 2171019, 3022987, 2215936, 2441216, 2215936, 2527232, 2215936, 2600960, 2215936, 2850816, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2179072, 0, 0, 0, 0, 69632, 287, 2170880, 2215936, 3022848, 2171166, 2441502, 2171166, 2527518, 0, 0, 2171166, 2601246, 2171166, 0, 2851102, 2171166, 2171166, 2171166, 2171166, 2720030, 2744606, 2171166, 2171166, 2171166, 2834718, 2838814, 2171166, 2908446, 2171166, 2171166, 2937118, 3023134, 2171019, 2519179, 2171019, 2171019, 2171019, 2171019, 2171019, 2215936, 2519040, 2215936, 2215936, 2215936, 2215936, 2215936, 2171166, 2171166, 2171166, 3215646, 0, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2171019, 2486411, 2171019, 2171019, 2171019, 2629771, 2171019, 2171019, 2171019, 2171019, 2719883, 2744459, 2171019, 2171019, 2171019, 2834571, 2838667, 2171019, 2519326, 0, 0, 2171166, 2171166, 0, 2171166, 2171166, 2171166, 2396299, 2171019, 2171019, 2171019, 2171019, 3018891, 2396160, 2215936, 2215936, 2215936, 2215936, 3018752, 2396446, 0, 0, 2171166, 2171166, 2171166, 2171166, 3019038, 2171019, 2650251, 2965643, 2171019, 2215936, 2650112, 2965504, 2215936, 0, 0, 2171166, 2650398, 2965790, 2171166, 2551947, 2171019, 2551808, 2215936, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 144, 45, 45, 67, 67, 67, 67, 67, 228, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1929, 97, 97, 97, 97, 0, 0, 0, 2552094, 2171166, 2171019, 2215936, 0, 2171166, 2171019, 2215936, 0, 2171166, 2171019, 2215936, 0, 2171166, 2977931, 2977792, 2978078, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 1321, 97, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 140, 0, 2379776, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2445312, 2170880, 2465792, 2473984, 2170880, 2170880, 2170880, 2584576, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2170880, 2170880, 2170880, 3162112, 2170880, 2170880, 3182592, 3186688, 2170880, 0, 140, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3002368, 2170880, 2170880, 2215936, 2215936, 2494464, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 3215360, 544, 0, 0, 0, 544, 0, 546, 0, 0, 0, 546, 0, 0, 2183168, 0, 0, 552, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 0, 2170880, 2170880, 2170880, 0, 2170880, 2920448, 2170880, 2170880, 2170880, 2990080, 2170880, 2170880, 552, 0, 0, 0, 552, 0, 287, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2437120, 2170880, 2170880, 18, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 644, 0, 2215936, 2215936, 3170304, 544, 0, 546, 0, 552, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 0, 140, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 249856, 110630, 114730, 106539, 0, 0, 32768, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 151640, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2416640, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 253952, 110630, 114730, 106539, 0, 0, 32856, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 192512, 53264, 18, 18, 49172, 0, 57366, 0, 2232445, 184320, 2232445, 0, 2240641, 2240641, 184320, 2240641, 102432, 0, 0, 0, 221184, 2220032, 110630, 0, 0, 0, 114730, 106539, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3108864, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2215936, 0, 0, 0, 45056, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 0, 53264, 0, 18, 18, 24, 24, 0, 127, 127, 53264, 18, 49172, 258071, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 32768, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 204800, 53264, 18, 49172, 57366, 24, 27, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 28, 33, 0, 33, 33, 33, 0, 0, 0, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 16384, 28, 28, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139, 2170880, 2170880, 2170880, 2416640, 67, 67, 37139, 37139, 24853, 24853, 0, 70179, 0, 0, 0, 65820, 65820, 369, 287, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 2030, 45, 45, 45, 45, 67, 1573, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1699, 67, 67, 67, 67, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1355, 97, 97, 97, 1358, 97, 97, 97, 641, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 1187, 45, 45, 45, 45, 45, 0, 1480, 0, 0, 0, 0, 1319, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 592, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1531, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1680, 45, 45, 45, 641, 0, 924, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1186, 45, 45, 45, 45, 45, 45, 67, 67, 37139, 37139, 24853, 24853, 0, 70179, 282, 0, 0, 65820, 65820, 369, 287, 97, 0, 0, 97, 97, 0, 97, 2028, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1767, 67, 67, 67, 0, 0, 0, 0, 0, 0, 1612, 97, 97, 97, 97, 97, 97, 0, 1785, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1790, 97, 0, 0, 2170880, 2170880, 3051520, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3170304, 241664, 2387968, 2392064, 2170880, 2170880, 2433024, 53264, 19, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 274432, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 270336, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 1134711, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 1126440, 1126440, 1126440, 0, 0, 1126400, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 36, 110630, 114730, 106539, 0, 0, 217088, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 94, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 96, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 24666, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 126, 28, 28, 28, 28, 102432, 53264, 122, 123, 49172, 0, 57366, 0, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 2170880, 2170880, 4256099, 0, 0, 0, 0, 0, 0, 0, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 0, 1319, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1109, 97, 97, 97, 97, 1113, 132, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 146, 150, 45, 45, 45, 45, 45, 175, 45, 180, 45, 186, 45, 189, 45, 45, 203, 67, 256, 67, 67, 270, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 97, 293, 297, 97, 97, 97, 97, 97, 322, 97, 327, 97, 333, 97, 0, 0, 97, 2026, 0, 2027, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1685, 67, 67, 67, 67, 67, 67, 67, 1690, 67, 336, 97, 97, 350, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 2424832, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2617344, 2170880, 45, 439, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 525, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 622, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1524, 97, 97, 1527, 369, 648, 45, 45, 45, 45, 45, 45, 45, 45, 45, 659, 45, 45, 45, 45, 408, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1239, 45, 45, 45, 67, 729, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 762, 67, 746, 67, 67, 67, 67, 67, 67, 67, 67, 67, 759, 67, 67, 67, 67, 0, 0, 0, 1477, 0, 1086, 0, 0, 0, 1479, 0, 1090, 67, 67, 796, 67, 67, 799, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1291, 67, 67, 67, 811, 67, 67, 67, 67, 67, 816, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 833, 97, 97, 97, 97, 97, 97, 97, 97, 1380, 0, 0, 0, 45, 45, 45, 45, 45, 1185, 45, 45, 45, 45, 45, 45, 45, 386, 45, 45, 45, 45, 45, 45, 45, 45, 1810, 45, 45, 45, 45, 45, 45, 67, 97, 97, 844, 97, 97, 97, 97, 97, 97, 97, 97, 97, 857, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 97, 97, 97, 894, 97, 97, 897, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 1382, 45, 45, 45, 97, 909, 97, 97, 97, 97, 97, 914, 97, 97, 97, 97, 97, 97, 97, 923, 67, 67, 1079, 67, 67, 67, 67, 67, 37689, 1085, 25403, 1089, 66365, 1093, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 148, 1114, 97, 97, 97, 97, 97, 97, 1122, 97, 97, 97, 97, 97, 97, 97, 97, 97, 606, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1173, 97, 97, 97, 97, 97, 12288, 0, 925, 0, 1179, 0, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 145, 45, 45, 67, 67, 67, 67, 67, 1762, 67, 67, 67, 1766, 67, 67, 67, 67, 67, 67, 528, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 1934, 67, 67, 1255, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1035, 67, 67, 67, 67, 67, 67, 1297, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1111, 97, 97, 97, 97, 97, 97, 1327, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 33344, 97, 97, 97, 1335, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 1377, 97, 97, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 670, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 430, 45, 45, 45, 45, 67, 67, 1438, 67, 67, 1442, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1592, 67, 67, 67, 1451, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1458, 67, 67, 67, 67, 0, 0, 1305, 0, 0, 0, 0, 0, 1311, 0, 0, 0, 1317, 0, 0, 0, 0, 0, 0, 0, 97, 97, 1322, 97, 97, 1491, 97, 97, 1495, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1551, 45, 1553, 45, 1504, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1513, 97, 97, 97, 97, 0, 45, 45, 45, 45, 1536, 45, 45, 45, 45, 1540, 45, 67, 67, 67, 67, 67, 1585, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1700, 67, 67, 67, 97, 1648, 97, 97, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1541, 0, 97, 97, 97, 97, 0, 1940, 0, 97, 97, 97, 97, 97, 97, 45, 45, 2011, 45, 45, 45, 2015, 67, 67, 2017, 67, 67, 67, 2021, 97, 67, 67, 812, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 97, 97, 97, 910, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 923, 0, 0, 0, 45, 45, 45, 45, 1184, 45, 45, 45, 45, 1188, 45, 45, 45, 45, 1414, 45, 45, 45, 1417, 45, 1419, 45, 45, 45, 45, 45, 443, 45, 45, 45, 45, 45, 45, 453, 45, 45, 67, 67, 67, 67, 1244, 67, 67, 67, 67, 1248, 67, 67, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 282, 41098, 65820, 97, 1324, 97, 97, 97, 97, 1328, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 930, 45, 45, 45, 45, 97, 97, 97, 97, 1378, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 975, 45, 45, 45, 45, 67, 67, 1923, 67, 1925, 67, 67, 1927, 67, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1985, 45, 45, 45, 45, 45, 45, 1560, 45, 45, 45, 45, 45, 45, 45, 45, 45, 946, 45, 45, 950, 45, 45, 45, 0, 97, 97, 97, 1939, 0, 0, 0, 97, 1943, 97, 97, 1945, 97, 45, 45, 45, 669, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 990, 45, 45, 45, 67, 257, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 337, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 370, 2170880, 2170880, 2170880, 2416640, 401, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 459, 461, 67, 67, 67, 67, 67, 67, 67, 67, 475, 67, 480, 67, 67, 67, 67, 67, 67, 1054, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1698, 67, 67, 67, 67, 67, 484, 67, 67, 487, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1459, 67, 67, 97, 556, 558, 97, 97, 97, 97, 97, 97, 97, 97, 572, 97, 577, 97, 97, 0, 0, 1896, 97, 97, 97, 97, 97, 97, 1903, 45, 45, 45, 45, 983, 45, 45, 45, 45, 988, 45, 45, 45, 45, 45, 45, 1195, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1549, 45, 45, 45, 45, 45, 581, 97, 97, 584, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1153, 97, 97, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 662, 45, 45, 45, 684, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1004, 45, 45, 45, 67, 67, 67, 749, 67, 67, 67, 67, 67, 67, 67, 67, 67, 761, 67, 67, 67, 67, 67, 67, 1068, 67, 67, 67, 1071, 67, 67, 67, 67, 1076, 794, 795, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 544, 97, 97, 97, 97, 847, 97, 97, 97, 97, 97, 97, 97, 97, 97, 859, 97, 0, 0, 2025, 97, 20480, 97, 97, 2029, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1575, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1775, 67, 67, 67, 97, 97, 97, 97, 892, 893, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1515, 97, 993, 994, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 992, 67, 67, 67, 1284, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1607, 67, 67, 97, 1364, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 596, 97, 45, 1556, 1557, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 696, 45, 1596, 1597, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 499, 67, 97, 97, 97, 1621, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1346, 97, 97, 97, 97, 1740, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1678, 45, 45, 45, 45, 45, 67, 97, 97, 97, 97, 97, 97, 1836, 0, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1984, 97, 45, 45, 45, 45, 45, 45, 1808, 45, 45, 45, 45, 45, 45, 45, 45, 67, 739, 67, 67, 67, 67, 67, 744, 45, 45, 1909, 45, 45, 45, 45, 45, 45, 45, 67, 1917, 67, 1918, 67, 67, 67, 67, 67, 67, 1247, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 532, 67, 67, 67, 67, 67, 67, 1922, 67, 67, 67, 67, 67, 67, 67, 97, 1930, 97, 1931, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1576, 67, 67, 67, 67, 1580, 67, 67, 0, 97, 97, 1938, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 699, 45, 45, 45, 704, 45, 45, 45, 45, 45, 45, 45, 45, 987, 45, 45, 45, 45, 45, 45, 45, 67, 67, 97, 97, 97, 97, 0, 0, 97, 97, 97, 2006, 97, 97, 97, 97, 0, 45, 1533, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1416, 45, 45, 45, 45, 45, 45, 45, 45, 722, 723, 45, 45, 45, 45, 45, 45, 2045, 67, 67, 67, 2047, 0, 0, 97, 97, 97, 2051, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 409, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1957, 45, 67, 67, 67, 67, 67, 1836, 97, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 45, 67, 67, 67, 1761, 67, 67, 67, 1764, 67, 67, 67, 67, 67, 67, 67, 494, 67, 67, 67, 67, 67, 67, 67, 67, 67, 787, 67, 67, 67, 67, 67, 67, 45, 45, 420, 45, 45, 422, 45, 45, 425, 45, 45, 45, 45, 45, 45, 45, 387, 45, 45, 45, 45, 397, 45, 45, 45, 67, 460, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 515, 67, 485, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 498, 67, 67, 67, 67, 67, 97, 0, 2039, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1426, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1689, 67, 67, 67, 97, 557, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 612, 97, 582, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 595, 97, 97, 97, 97, 97, 896, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 885, 97, 97, 97, 97, 97, 45, 939, 45, 45, 45, 45, 943, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1916, 67, 67, 67, 67, 67, 45, 67, 67, 67, 67, 67, 67, 67, 1015, 67, 67, 67, 67, 1019, 67, 67, 67, 67, 67, 67, 1271, 67, 67, 67, 67, 67, 67, 1277, 67, 67, 67, 67, 67, 67, 1287, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 804, 67, 67, 67, 67, 67, 1077, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2437120, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2543616, 2170880, 2170880, 2170880, 2170880, 2170880, 2629632, 1169, 97, 1171, 97, 97, 97, 97, 97, 97, 97, 12288, 0, 925, 0, 1179, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 936, 45, 45, 67, 67, 214, 67, 220, 67, 67, 233, 67, 243, 67, 248, 67, 67, 67, 67, 67, 67, 1298, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 1617, 97, 0, 0, 0, 45, 45, 45, 1183, 45, 45, 45, 45, 45, 45, 45, 45, 45, 393, 45, 45, 45, 45, 45, 45, 67, 67, 1243, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1074, 67, 67, 1281, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 776, 1323, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 907, 45, 1412, 45, 45, 45, 45, 45, 45, 45, 1418, 45, 45, 45, 45, 45, 45, 686, 45, 45, 45, 690, 45, 45, 695, 45, 45, 67, 67, 67, 67, 67, 1465, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1712, 97, 97, 97, 97, 1741, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 426, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1924, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1983, 97, 97, 45, 45, 1987, 45, 1988, 45, 0, 97, 97, 97, 97, 0, 0, 0, 1942, 97, 97, 97, 97, 97, 45, 45, 45, 700, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 711, 45, 45, 153, 45, 45, 166, 45, 176, 45, 181, 45, 45, 188, 191, 196, 45, 204, 255, 258, 263, 67, 271, 67, 67, 0, 37139, 24853, 0, 0, 0, 282, 41098, 65820, 97, 97, 97, 294, 97, 300, 97, 97, 313, 97, 323, 97, 328, 97, 97, 335, 338, 343, 97, 351, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 0, 0, 0, 0, 0, 0, 0, 0, 41098, 0, 140, 45, 45, 45, 45, 1404, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1411, 67, 67, 486, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1251, 67, 67, 501, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 513, 67, 67, 67, 67, 67, 67, 1443, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1263, 67, 67, 67, 67, 67, 97, 97, 583, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1526, 97, 598, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 610, 97, 97, 0, 97, 97, 1796, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1744, 45, 45, 45, 369, 0, 651, 45, 653, 45, 654, 45, 656, 45, 45, 45, 660, 45, 45, 45, 45, 1558, 45, 45, 45, 45, 45, 45, 45, 45, 1566, 45, 45, 681, 45, 683, 45, 45, 45, 45, 45, 45, 45, 45, 691, 692, 694, 45, 45, 45, 716, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 709, 45, 45, 712, 45, 714, 45, 45, 45, 718, 45, 45, 45, 45, 45, 45, 45, 726, 45, 45, 45, 733, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1691, 67, 67, 747, 67, 67, 67, 67, 67, 67, 67, 67, 67, 760, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 1613, 97, 97, 97, 97, 97, 97, 1509, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 67, 764, 67, 67, 67, 67, 768, 67, 770, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 1977, 67, 778, 779, 781, 67, 67, 67, 67, 67, 67, 788, 789, 67, 67, 792, 793, 67, 67, 67, 813, 67, 67, 67, 67, 67, 67, 67, 67, 67, 824, 37689, 544, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 836, 97, 838, 97, 839, 97, 841, 97, 97, 97, 845, 97, 97, 97, 97, 97, 97, 97, 97, 97, 858, 97, 97, 0, 1728, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 1802, 45, 97, 97, 862, 97, 97, 97, 97, 866, 97, 868, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1788, 97, 97, 97, 0, 0, 97, 97, 876, 877, 879, 97, 97, 97, 97, 97, 97, 886, 887, 97, 97, 890, 891, 97, 97, 97, 97, 97, 97, 97, 899, 97, 97, 97, 903, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 1646, 97, 97, 97, 97, 911, 97, 97, 97, 97, 97, 97, 97, 97, 97, 922, 923, 45, 955, 45, 957, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 195, 45, 45, 45, 45, 45, 981, 982, 45, 45, 45, 45, 45, 45, 989, 45, 45, 45, 45, 45, 170, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 411, 45, 45, 45, 45, 45, 67, 1023, 67, 67, 67, 67, 67, 67, 1031, 67, 1033, 67, 67, 67, 67, 67, 67, 67, 817, 819, 67, 67, 67, 67, 67, 37689, 544, 67, 1065, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 516, 67, 67, 1078, 67, 67, 1081, 1082, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 0, 0, 0, 0, 0, 2171166, 2171166, 2171166, 2171166, 2171166, 2437406, 2171166, 2171166, 97, 1115, 97, 1117, 97, 97, 97, 97, 97, 97, 1125, 97, 1127, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 1644, 97, 97, 97, 0, 97, 97, 97, 0, 97, 97, 1642, 97, 97, 97, 97, 97, 97, 625, 97, 97, 97, 97, 97, 97, 97, 97, 97, 316, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1159, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1502, 97, 97, 97, 97, 97, 1172, 97, 97, 1175, 1176, 97, 97, 12288, 0, 925, 0, 1179, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 45, 935, 45, 45, 45, 1233, 45, 45, 45, 1236, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1873, 67, 67, 45, 45, 1218, 45, 45, 45, 1223, 45, 45, 45, 45, 45, 45, 45, 1230, 45, 45, 67, 67, 215, 219, 222, 67, 230, 67, 67, 244, 246, 249, 67, 67, 67, 67, 67, 67, 1882, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 1904, 45, 1905, 45, 67, 67, 67, 67, 67, 1258, 67, 1260, 67, 67, 67, 67, 67, 67, 67, 67, 67, 495, 67, 67, 67, 67, 67, 67, 67, 67, 1283, 67, 67, 67, 67, 67, 67, 67, 1290, 67, 67, 67, 67, 67, 67, 67, 818, 67, 67, 67, 67, 67, 67, 37689, 544, 67, 67, 1295, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 2174976, 0, 0, 97, 97, 97, 1326, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1514, 97, 97, 97, 97, 97, 1338, 97, 1340, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1500, 97, 97, 1503, 97, 1363, 97, 97, 97, 97, 97, 97, 97, 1370, 97, 97, 97, 97, 97, 97, 97, 563, 97, 97, 97, 97, 97, 97, 578, 97, 1375, 97, 97, 97, 97, 97, 97, 97, 97, 0, 1179, 0, 45, 45, 45, 45, 685, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1003, 45, 45, 45, 45, 67, 67, 67, 1463, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1778, 97, 97, 97, 97, 97, 1518, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 609, 97, 97, 97, 45, 1542, 45, 45, 45, 45, 45, 45, 45, 1548, 45, 45, 45, 45, 45, 1554, 45, 1570, 1571, 45, 67, 67, 67, 67, 67, 67, 1578, 67, 67, 67, 67, 67, 67, 67, 1055, 67, 67, 67, 67, 67, 1061, 67, 67, 1582, 67, 67, 67, 67, 67, 67, 67, 1588, 67, 67, 67, 67, 67, 1594, 67, 67, 67, 67, 67, 97, 2038, 0, 97, 97, 97, 97, 97, 2044, 45, 45, 45, 995, 45, 45, 45, 45, 1000, 45, 45, 45, 45, 45, 45, 45, 1809, 45, 1811, 45, 45, 45, 45, 45, 67, 1610, 1611, 67, 1476, 0, 1478, 0, 1480, 0, 97, 97, 97, 97, 97, 97, 1618, 1647, 1649, 97, 97, 97, 1652, 97, 1654, 1655, 97, 0, 45, 45, 45, 1658, 45, 45, 67, 67, 216, 67, 67, 67, 67, 234, 67, 67, 67, 67, 252, 254, 1845, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 945, 45, 947, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1881, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 1902, 45, 45, 45, 45, 45, 45, 1908, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1921, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 0, 97, 1937, 97, 97, 1940, 0, 0, 97, 97, 97, 97, 97, 97, 1947, 1948, 1949, 45, 45, 45, 1952, 45, 1954, 45, 45, 45, 45, 1959, 1960, 1961, 67, 67, 67, 67, 67, 67, 1455, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 757, 67, 67, 67, 67, 67, 67, 1964, 67, 1966, 67, 67, 67, 67, 1971, 1972, 1973, 97, 0, 0, 0, 97, 97, 1104, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 884, 97, 97, 97, 889, 97, 97, 1978, 97, 0, 0, 1981, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 736, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1018, 67, 67, 67, 45, 67, 67, 67, 67, 0, 2049, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 933, 45, 45, 45, 45, 1234, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 97, 97, 288, 97, 97, 97, 97, 97, 97, 317, 97, 97, 97, 97, 97, 97, 0, 0, 97, 1787, 97, 97, 97, 97, 0, 0, 45, 45, 378, 45, 45, 45, 45, 45, 390, 45, 45, 45, 45, 45, 45, 45, 424, 45, 45, 45, 431, 433, 45, 45, 45, 67, 1050, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 518, 67, 97, 97, 97, 1144, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 632, 97, 97, 97, 97, 97, 97, 97, 1367, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 855, 97, 97, 97, 97, 67, 97, 97, 97, 97, 97, 97, 1837, 0, 97, 97, 97, 97, 97, 0, 0, 0, 1897, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1208, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 724, 45, 45, 45, 45, 45, 97, 2010, 45, 45, 45, 45, 45, 45, 2016, 67, 67, 67, 67, 67, 67, 2022, 45, 2046, 67, 67, 67, 0, 0, 2050, 97, 97, 97, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 0, 932, 45, 45, 45, 45, 45, 1222, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1227, 45, 45, 45, 45, 45, 133, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 45, 701, 702, 45, 45, 705, 706, 45, 45, 45, 45, 45, 45, 703, 45, 45, 45, 45, 45, 45, 45, 45, 45, 719, 45, 45, 45, 45, 45, 725, 45, 45, 45, 369, 649, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1216, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 834, 97, 97, 97, 97, 97, 97, 97, 1342, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 1799, 97, 97, 45, 45, 45, 1569, 45, 45, 45, 1572, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 1306, 0, 67, 67, 67, 1598, 67, 67, 67, 67, 67, 67, 67, 67, 1606, 67, 67, 1609, 97, 97, 97, 1650, 97, 97, 1653, 97, 97, 97, 0, 45, 45, 1657, 45, 45, 45, 1206, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1421, 45, 45, 45, 1703, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 1711, 97, 97, 0, 1895, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 958, 45, 960, 45, 45, 45, 45, 45, 45, 45, 45, 1913, 45, 45, 1915, 67, 67, 67, 67, 67, 67, 67, 466, 67, 67, 67, 67, 67, 67, 481, 67, 45, 1749, 45, 45, 45, 45, 45, 45, 45, 45, 1755, 45, 45, 45, 45, 45, 173, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 974, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1773, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1886, 0, 0, 0, 97, 97, 67, 2035, 2036, 67, 67, 97, 0, 0, 97, 2041, 2042, 97, 97, 45, 45, 45, 45, 1662, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1397, 45, 45, 45, 45, 151, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 437, 205, 45, 67, 67, 67, 218, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1047, 67, 67, 67, 67, 97, 97, 97, 97, 298, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 870, 97, 97, 97, 97, 97, 97, 97, 97, 352, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 0, 0, 0, 0, 0, 365, 0, 41098, 0, 140, 45, 45, 45, 45, 45, 1427, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1435, 520, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1037, 617, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 923, 45, 1232, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1919, 67, 1759, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1021, 45, 154, 45, 162, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 964, 45, 45, 45, 206, 45, 67, 67, 67, 67, 221, 67, 229, 67, 67, 67, 67, 67, 67, 67, 67, 530, 67, 67, 67, 67, 67, 67, 67, 67, 755, 67, 67, 67, 67, 67, 67, 67, 67, 785, 67, 67, 67, 67, 67, 67, 67, 67, 802, 67, 67, 67, 807, 67, 67, 67, 97, 97, 97, 97, 353, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 0, 0, 0, 0, 0, 366, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 402, 45, 45, 45, 45, 45, 45, 45, 410, 45, 45, 45, 45, 45, 45, 45, 674, 45, 45, 45, 45, 45, 45, 45, 45, 389, 45, 394, 45, 45, 398, 45, 45, 45, 45, 441, 45, 45, 45, 45, 45, 447, 45, 45, 45, 454, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1768, 67, 67, 67, 67, 67, 488, 67, 67, 67, 67, 67, 67, 67, 496, 67, 67, 67, 67, 67, 67, 67, 1774, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 67, 67, 523, 67, 67, 527, 67, 67, 67, 67, 67, 533, 67, 67, 67, 540, 97, 97, 97, 585, 97, 97, 97, 97, 97, 97, 97, 593, 97, 97, 97, 97, 97, 97, 1784, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 0, 18, 18, 24, 24, 0, 28, 28, 97, 97, 620, 97, 97, 624, 97, 97, 97, 97, 97, 630, 97, 97, 97, 637, 713, 45, 45, 45, 45, 45, 45, 721, 45, 45, 45, 45, 45, 45, 45, 45, 1197, 45, 45, 45, 45, 45, 45, 45, 45, 730, 732, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1581, 67, 45, 67, 67, 67, 67, 1012, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1059, 67, 67, 67, 67, 67, 1024, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 775, 67, 67, 67, 67, 1066, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 479, 67, 67, 67, 67, 67, 67, 1080, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 0, 0, 0, 0, 287, 0, 0, 0, 287, 0, 2379776, 2170880, 2170880, 97, 97, 97, 1118, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 920, 97, 97, 0, 0, 0, 0, 45, 1181, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 432, 45, 45, 45, 45, 45, 45, 1219, 45, 45, 45, 45, 45, 45, 1226, 45, 45, 45, 45, 45, 45, 959, 45, 45, 45, 45, 45, 45, 45, 45, 45, 184, 45, 45, 45, 45, 202, 45, 1241, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1266, 67, 1268, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1279, 67, 67, 67, 67, 67, 272, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 67, 67, 67, 1286, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1293, 67, 67, 67, 1296, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 281, 94, 0, 0, 97, 97, 97, 1366, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1373, 97, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 0, 97, 1376, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 1384, 45, 45, 67, 208, 67, 67, 67, 67, 67, 67, 237, 67, 67, 67, 67, 67, 67, 67, 1069, 1070, 67, 67, 67, 67, 67, 67, 67, 0, 37140, 24854, 0, 0, 0, 0, 41098, 65821, 45, 1423, 45, 45, 45, 45, 45, 45, 67, 67, 1431, 67, 67, 67, 67, 67, 67, 67, 1083, 37689, 0, 25403, 0, 66365, 0, 0, 0, 1436, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1830, 67, 1452, 1453, 67, 67, 67, 67, 1456, 67, 67, 67, 67, 67, 67, 67, 67, 67, 771, 67, 67, 67, 67, 67, 67, 1461, 67, 67, 67, 1464, 67, 1466, 67, 67, 67, 67, 67, 67, 1470, 67, 67, 67, 67, 67, 67, 1587, 67, 67, 67, 67, 67, 67, 67, 67, 1595, 1489, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1129, 97, 1505, 1506, 97, 97, 97, 97, 1510, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1163, 1164, 97, 97, 97, 97, 97, 1516, 97, 97, 97, 1519, 97, 1521, 97, 97, 97, 97, 97, 97, 1525, 97, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 67, 67, 67, 67, 67, 1586, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1276, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1600, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1301, 0, 0, 0, 1307, 97, 97, 1620, 97, 97, 97, 97, 97, 97, 97, 1627, 97, 97, 97, 97, 97, 97, 913, 97, 97, 97, 97, 919, 97, 97, 97, 0, 97, 97, 97, 1781, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 1792, 1860, 45, 1862, 1863, 45, 1865, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1875, 67, 1877, 1878, 67, 1880, 67, 97, 97, 97, 97, 97, 1887, 0, 1889, 97, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 237568, 0, 367, 0, 97, 1893, 0, 0, 0, 97, 1898, 1899, 97, 1901, 97, 45, 45, 45, 45, 45, 2014, 45, 67, 67, 67, 67, 67, 2020, 67, 97, 1989, 45, 1990, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1996, 67, 1997, 67, 67, 67, 67, 67, 273, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 97, 97, 97, 97, 0, 0, 97, 97, 2005, 0, 97, 2007, 97, 97, 18, 0, 139621, 0, 0, 0, 642, 0, 133, 364, 0, 0, 367, 41606, 0, 97, 97, 2056, 2057, 0, 2059, 45, 67, 0, 97, 45, 67, 0, 97, 45, 45, 67, 209, 67, 67, 67, 223, 67, 67, 67, 67, 67, 67, 67, 67, 67, 786, 67, 67, 67, 791, 67, 67, 45, 45, 940, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 727, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1016, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 0, 133, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 142, 45, 45, 67, 210, 67, 67, 67, 225, 67, 67, 239, 67, 67, 67, 250, 67, 67, 67, 67, 67, 464, 67, 67, 67, 67, 67, 476, 67, 67, 67, 67, 67, 67, 67, 1709, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 1843, 0, 67, 259, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 289, 97, 97, 97, 303, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 901, 97, 97, 97, 97, 97, 339, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 0, 358, 0, 0, 0, 0, 0, 0, 41098, 0, 140, 45, 45, 45, 45, 45, 1953, 45, 1955, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1687, 1688, 67, 67, 67, 67, 45, 45, 405, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1203, 45, 458, 67, 67, 67, 67, 67, 67, 67, 67, 67, 470, 477, 67, 67, 67, 67, 67, 67, 67, 1970, 97, 97, 97, 1974, 0, 0, 0, 97, 1103, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1372, 97, 97, 97, 97, 67, 522, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 536, 67, 67, 67, 67, 67, 67, 1696, 67, 67, 67, 67, 67, 67, 67, 1701, 67, 555, 97, 97, 97, 97, 97, 97, 97, 97, 97, 567, 574, 97, 97, 97, 97, 97, 301, 97, 309, 97, 97, 97, 97, 97, 97, 97, 97, 97, 900, 97, 97, 97, 905, 97, 97, 97, 619, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 633, 97, 97, 18, 0, 139621, 0, 0, 362, 0, 0, 0, 364, 0, 0, 367, 41606, 369, 649, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 663, 664, 67, 67, 67, 67, 750, 751, 67, 67, 67, 67, 758, 67, 67, 67, 67, 67, 67, 67, 1272, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1057, 1058, 67, 67, 67, 67, 67, 67, 67, 67, 797, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 512, 67, 67, 67, 97, 97, 97, 97, 895, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 902, 97, 97, 97, 97, 67, 67, 1051, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1062, 67, 67, 67, 67, 67, 491, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1302, 0, 0, 0, 1308, 97, 97, 97, 97, 1145, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1139, 97, 97, 97, 97, 1156, 97, 97, 97, 97, 97, 97, 1161, 97, 97, 97, 97, 97, 1166, 97, 97, 18, 640, 139621, 0, 641, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 67, 67, 67, 67, 1257, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 1305, 0, 0, 97, 97, 1337, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1630, 97, 67, 1474, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2380062, 2171166, 2171166, 97, 1529, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1228, 45, 45, 45, 45, 67, 67, 67, 67, 1707, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 1891, 1739, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1198, 45, 1200, 45, 45, 45, 45, 97, 97, 1894, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 672, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1420, 45, 45, 45, 45, 67, 67, 1965, 67, 1967, 67, 67, 67, 97, 97, 97, 97, 0, 1976, 0, 97, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 97, 97, 1979, 0, 0, 97, 1982, 97, 97, 97, 1986, 45, 45, 45, 45, 45, 735, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1770, 67, 67, 2000, 97, 97, 97, 2002, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1798, 97, 97, 97, 45, 45, 45, 2034, 67, 67, 67, 67, 97, 0, 0, 2040, 97, 97, 97, 97, 45, 45, 45, 45, 1752, 45, 45, 45, 1753, 1754, 45, 45, 45, 45, 45, 45, 383, 45, 45, 45, 45, 45, 45, 45, 45, 45, 675, 45, 45, 45, 45, 45, 45, 438, 45, 45, 45, 45, 45, 445, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1430, 67, 67, 67, 67, 67, 67, 67, 67, 67, 524, 67, 67, 67, 67, 67, 531, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 1096, 97, 97, 97, 621, 97, 97, 97, 97, 97, 628, 97, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 356, 28, 28, 665, 45, 45, 45, 45, 45, 45, 45, 45, 45, 676, 45, 45, 45, 45, 45, 942, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 707, 708, 45, 45, 45, 45, 763, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 809, 810, 67, 67, 67, 67, 783, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 1303, 0, 0, 0, 97, 861, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 613, 97, 45, 45, 956, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1215, 45, 67, 67, 67, 67, 1027, 67, 67, 67, 67, 1032, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 0, 25403, 0, 66365, 0, 0, 1097, 1064, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1075, 67, 1098, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 331, 97, 97, 97, 97, 1158, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 594, 97, 97, 1309, 0, 0, 0, 1315, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1374, 97, 45, 45, 1543, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1240, 67, 67, 1583, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1252, 67, 97, 97, 97, 1635, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1800, 97, 45, 45, 45, 97, 97, 1793, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1743, 45, 45, 45, 1746, 45, 0, 97, 97, 97, 97, 97, 1851, 97, 45, 45, 45, 45, 1856, 45, 45, 45, 45, 1864, 45, 45, 67, 67, 1869, 67, 67, 67, 67, 1874, 67, 0, 97, 97, 45, 67, 2058, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 45, 67, 211, 67, 67, 67, 67, 67, 67, 240, 67, 67, 67, 67, 67, 67, 67, 1444, 67, 67, 67, 67, 67, 67, 67, 67, 67, 509, 67, 67, 67, 67, 67, 67, 67, 67, 67, 268, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 290, 97, 97, 97, 305, 97, 97, 319, 97, 97, 97, 330, 97, 97, 18, 640, 139621, 0, 641, 0, 0, 0, 0, 364, 0, 643, 367, 41606, 97, 97, 348, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 380, 45, 45, 45, 45, 45, 45, 395, 45, 45, 45, 400, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 658, 45, 45, 45, 45, 45, 972, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 427, 45, 45, 45, 45, 45, 745, 67, 67, 67, 67, 67, 67, 67, 67, 756, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 1086, 25403, 1090, 66365, 1094, 0, 0, 97, 843, 97, 97, 97, 97, 97, 97, 97, 97, 854, 97, 97, 97, 97, 97, 97, 1121, 97, 97, 97, 97, 1126, 97, 97, 97, 97, 45, 980, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1400, 45, 67, 67, 67, 1011, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 1304, 0, 0, 0, 1190, 45, 45, 1193, 1194, 45, 45, 45, 45, 45, 1199, 45, 1201, 45, 45, 45, 45, 1911, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1579, 67, 67, 67, 67, 45, 1205, 45, 45, 45, 45, 45, 45, 45, 45, 1211, 45, 45, 45, 45, 45, 984, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1550, 45, 45, 45, 45, 45, 1217, 45, 45, 45, 45, 45, 45, 1225, 45, 45, 45, 45, 1229, 45, 45, 45, 1388, 45, 45, 45, 45, 45, 45, 1396, 45, 45, 45, 45, 45, 444, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1574, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1590, 67, 67, 67, 67, 67, 1254, 67, 67, 67, 67, 67, 1259, 67, 1261, 67, 67, 67, 67, 1265, 67, 67, 67, 67, 67, 67, 1708, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 67, 67, 67, 67, 1285, 67, 67, 67, 67, 1289, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 1087, 25403, 1091, 66365, 1095, 0, 0, 97, 97, 97, 97, 1339, 97, 1341, 97, 97, 97, 97, 1345, 97, 97, 97, 97, 97, 561, 97, 97, 97, 97, 97, 573, 97, 97, 97, 97, 97, 97, 1717, 97, 0, 97, 97, 97, 97, 97, 97, 97, 591, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1329, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1351, 97, 97, 97, 97, 97, 97, 1357, 97, 97, 97, 97, 97, 588, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 568, 97, 97, 97, 97, 97, 97, 97, 1365, 97, 97, 97, 97, 1369, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1356, 97, 97, 97, 97, 97, 97, 45, 45, 1403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1399, 45, 45, 45, 1413, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1669, 45, 1422, 45, 45, 1425, 45, 45, 1428, 45, 1429, 67, 67, 67, 67, 67, 67, 67, 67, 1468, 67, 67, 67, 67, 67, 67, 67, 67, 529, 67, 67, 67, 67, 67, 67, 539, 67, 67, 1475, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 140, 2170880, 2170880, 2170880, 2416640, 97, 97, 1530, 97, 0, 45, 45, 1534, 45, 45, 45, 45, 45, 45, 45, 45, 1956, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1599, 67, 67, 1601, 67, 67, 67, 67, 67, 67, 67, 67, 67, 803, 67, 67, 67, 67, 67, 67, 1632, 97, 1634, 0, 97, 97, 97, 1640, 97, 97, 97, 1643, 97, 97, 1645, 97, 97, 97, 97, 97, 912, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1660, 1661, 45, 45, 45, 45, 1665, 1666, 45, 45, 45, 45, 45, 1670, 1692, 1693, 67, 67, 67, 67, 67, 1697, 67, 67, 67, 67, 67, 67, 67, 1702, 97, 97, 1714, 1715, 97, 97, 97, 97, 0, 1721, 1722, 97, 97, 97, 97, 97, 97, 1353, 97, 97, 97, 97, 97, 97, 97, 97, 1362, 1726, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 1734, 97, 97, 97, 97, 97, 848, 849, 97, 97, 97, 97, 856, 97, 97, 97, 97, 97, 354, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 45, 45, 1750, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1681, 45, 0, 1846, 97, 97, 97, 97, 97, 97, 45, 45, 1854, 45, 45, 45, 45, 1859, 67, 67, 67, 1879, 67, 67, 97, 97, 1884, 97, 97, 0, 0, 0, 97, 97, 97, 1105, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1344, 97, 97, 97, 1347, 97, 1892, 97, 0, 0, 0, 97, 97, 97, 1900, 97, 97, 45, 45, 45, 45, 45, 997, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1002, 45, 45, 1005, 1006, 45, 67, 67, 67, 67, 67, 1926, 67, 67, 1928, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1737, 97, 0, 97, 97, 97, 97, 0, 0, 0, 97, 97, 1944, 97, 97, 1946, 45, 45, 45, 1544, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 190, 45, 45, 45, 152, 155, 45, 163, 45, 45, 177, 179, 182, 45, 45, 45, 193, 197, 45, 45, 45, 1672, 45, 45, 45, 45, 45, 1677, 45, 1679, 45, 45, 45, 45, 996, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1212, 45, 45, 45, 45, 67, 260, 264, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 97, 295, 299, 302, 97, 310, 97, 97, 324, 326, 329, 97, 97, 97, 0, 97, 97, 1639, 0, 1641, 97, 97, 97, 97, 97, 97, 97, 97, 1511, 97, 97, 97, 97, 97, 97, 97, 97, 1523, 97, 97, 97, 97, 97, 97, 97, 97, 1719, 97, 97, 97, 97, 97, 97, 97, 97, 1720, 97, 97, 97, 97, 97, 97, 97, 312, 97, 97, 97, 97, 97, 97, 97, 97, 1123, 97, 97, 97, 97, 97, 97, 97, 340, 344, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 373, 375, 419, 45, 45, 45, 45, 45, 45, 45, 45, 45, 428, 45, 45, 435, 45, 45, 45, 1751, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1410, 45, 45, 45, 67, 67, 67, 505, 67, 67, 67, 67, 67, 67, 67, 67, 67, 514, 67, 67, 67, 67, 67, 67, 1969, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 45, 67, 0, 97, 45, 67, 0, 97, 2064, 2065, 0, 2066, 45, 521, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 534, 67, 67, 67, 67, 67, 67, 465, 67, 67, 67, 474, 67, 67, 67, 67, 67, 67, 67, 1467, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 1933, 0, 97, 97, 97, 602, 97, 97, 97, 97, 97, 97, 97, 97, 97, 611, 97, 97, 18, 640, 139621, 358, 641, 0, 0, 0, 0, 364, 0, 0, 367, 0, 618, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 631, 97, 97, 97, 97, 97, 881, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 569, 97, 97, 97, 97, 97, 369, 0, 45, 652, 45, 45, 45, 45, 45, 657, 45, 45, 45, 45, 45, 45, 1235, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1432, 67, 67, 67, 67, 67, 67, 67, 766, 67, 67, 67, 67, 67, 67, 67, 67, 773, 67, 67, 67, 0, 1305, 0, 1311, 0, 1317, 97, 97, 97, 97, 97, 97, 97, 1624, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 1724, 97, 97, 97, 777, 67, 67, 782, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 535, 67, 67, 67, 67, 67, 67, 67, 814, 67, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 97, 837, 97, 97, 97, 97, 97, 97, 1496, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 918, 97, 97, 97, 97, 0, 842, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1168, 97, 97, 97, 97, 864, 97, 97, 97, 97, 97, 97, 97, 97, 871, 97, 97, 97, 0, 1637, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1801, 45, 45, 97, 875, 97, 97, 880, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1151, 1152, 97, 97, 97, 67, 67, 67, 1040, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 790, 67, 67, 67, 1180, 0, 649, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 200, 45, 45, 67, 67, 67, 1454, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 806, 67, 67, 67, 0, 0, 0, 1481, 0, 1094, 0, 0, 97, 1483, 97, 97, 97, 97, 97, 97, 304, 97, 97, 318, 97, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 97, 97, 97, 1507, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1332, 97, 97, 97, 1619, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1631, 97, 1633, 97, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1381, 0, 0, 45, 45, 45, 45, 97, 97, 1727, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 626, 97, 97, 97, 97, 97, 97, 636, 45, 45, 1760, 67, 67, 67, 67, 67, 67, 67, 1765, 67, 67, 67, 67, 67, 67, 67, 1299, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1616, 97, 97, 1803, 45, 45, 45, 45, 1807, 45, 45, 45, 45, 45, 1813, 45, 45, 45, 67, 67, 1684, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 822, 67, 67, 37689, 544, 67, 67, 1818, 67, 67, 67, 67, 1822, 67, 67, 67, 67, 67, 1828, 67, 67, 67, 67, 67, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 2012, 2013, 45, 45, 67, 67, 67, 2018, 2019, 67, 67, 97, 67, 97, 97, 97, 1833, 97, 97, 0, 0, 97, 97, 1840, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 1733, 97, 1735, 97, 97, 97, 0, 97, 97, 97, 1849, 97, 97, 97, 45, 45, 45, 45, 45, 1857, 45, 45, 45, 1910, 45, 1912, 45, 45, 1914, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1017, 67, 67, 1020, 67, 45, 1861, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1872, 67, 67, 67, 67, 67, 67, 752, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1446, 67, 67, 67, 67, 67, 1876, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 1890, 97, 97, 97, 97, 97, 1134, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 570, 97, 97, 97, 97, 580, 1935, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1906, 45, 67, 67, 67, 67, 2048, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 0, 0, 925, 41606, 0, 0, 0, 931, 45, 45, 45, 45, 45, 45, 1674, 45, 1676, 45, 45, 45, 45, 45, 45, 45, 446, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1871, 67, 67, 67, 67, 0, 97, 97, 45, 67, 0, 97, 2060, 2061, 0, 2063, 45, 67, 0, 97, 45, 45, 156, 45, 45, 45, 45, 45, 45, 45, 45, 45, 192, 45, 45, 45, 45, 1673, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 429, 45, 45, 45, 45, 67, 67, 67, 269, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 349, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 374, 45, 45, 67, 67, 213, 217, 67, 67, 67, 67, 67, 242, 67, 247, 67, 253, 45, 45, 698, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 399, 45, 45, 0, 0, 0, 0, 925, 41606, 0, 929, 0, 0, 45, 45, 45, 45, 45, 45, 1391, 45, 45, 1395, 45, 45, 45, 45, 45, 45, 423, 45, 45, 45, 45, 45, 45, 45, 436, 45, 67, 67, 67, 67, 1041, 67, 1043, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1776, 67, 67, 97, 97, 97, 1099, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 888, 97, 97, 97, 1131, 97, 97, 97, 97, 1135, 97, 1137, 97, 97, 97, 97, 97, 97, 97, 1497, 97, 97, 97, 97, 97, 97, 97, 97, 97, 883, 97, 97, 97, 97, 97, 97, 1310, 0, 0, 0, 1316, 0, 0, 0, 0, 1100, 0, 0, 0, 97, 97, 97, 97, 97, 1107, 97, 97, 97, 97, 97, 97, 97, 97, 1343, 97, 97, 97, 97, 97, 97, 1348, 0, 0, 1317, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1112, 97, 45, 1804, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1868, 67, 1870, 67, 67, 67, 67, 67, 1817, 67, 67, 1819, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 823, 67, 37689, 544, 67, 97, 1832, 97, 97, 1834, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 0, 1732, 97, 97, 97, 97, 97, 97, 97, 850, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1177, 0, 0, 925, 0, 0, 0, 0, 97, 97, 97, 97, 0, 0, 1941, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1991, 1992, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1998, 134, 0, 0, 0, 37, 110630, 0, 0, 0, 114730, 106539, 41098, 45, 45, 45, 45, 941, 45, 45, 944, 45, 45, 45, 45, 45, 45, 952, 45, 45, 207, 67, 67, 67, 67, 67, 226, 67, 67, 67, 67, 67, 67, 67, 67, 67, 820, 67, 67, 67, 67, 37689, 544, 369, 650, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1682, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 835, 97, 97, 97, 97, 97, 97, 97, 1522, 97, 97, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1725, 67, 67, 67, 1695, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1034, 67, 1036, 67, 67, 67, 265, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 97, 296, 97, 97, 97, 97, 314, 97, 97, 97, 97, 332, 334, 97, 97, 97, 97, 97, 1146, 1147, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1626, 97, 97, 97, 97, 97, 97, 345, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 372, 45, 45, 45, 1220, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1213, 45, 45, 45, 45, 404, 406, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 434, 45, 45, 45, 440, 45, 45, 45, 45, 45, 45, 45, 45, 451, 452, 45, 45, 45, 67, 1683, 67, 67, 67, 1686, 67, 67, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 67, 67, 490, 492, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1447, 67, 67, 1450, 67, 67, 67, 67, 67, 526, 67, 67, 67, 67, 67, 67, 67, 67, 537, 538, 67, 67, 67, 67, 67, 506, 67, 67, 508, 67, 67, 511, 67, 67, 67, 67, 0, 1476, 0, 0, 0, 0, 0, 1478, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 1484, 97, 97, 97, 97, 97, 97, 865, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1499, 97, 97, 97, 97, 97, 97, 97, 97, 97, 587, 589, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 629, 97, 97, 97, 97, 97, 97, 97, 97, 97, 623, 97, 97, 97, 97, 97, 97, 97, 97, 634, 635, 97, 97, 97, 97, 97, 1160, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1628, 97, 97, 97, 97, 369, 0, 45, 45, 45, 45, 45, 655, 45, 45, 45, 45, 45, 45, 45, 45, 999, 45, 1001, 45, 45, 45, 45, 45, 45, 45, 45, 715, 45, 45, 45, 720, 45, 45, 45, 45, 45, 45, 45, 45, 728, 25403, 546, 70179, 0, 0, 66365, 66365, 552, 0, 97, 97, 97, 97, 97, 840, 97, 97, 97, 97, 97, 1174, 97, 97, 97, 97, 0, 0, 925, 0, 0, 0, 0, 0, 0, 0, 1100, 97, 97, 97, 97, 97, 97, 97, 97, 627, 97, 97, 97, 97, 97, 97, 97, 938, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 680, 45, 968, 45, 970, 45, 973, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 962, 45, 45, 45, 45, 45, 979, 45, 45, 45, 45, 45, 985, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1224, 45, 45, 45, 45, 45, 45, 45, 45, 688, 45, 45, 45, 45, 45, 45, 45, 1007, 1008, 67, 67, 67, 67, 67, 1014, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1045, 67, 67, 67, 67, 67, 67, 67, 1038, 67, 67, 67, 67, 67, 67, 1044, 67, 1046, 67, 1049, 67, 67, 67, 67, 67, 67, 800, 67, 67, 67, 67, 67, 67, 808, 67, 67, 0, 0, 0, 1102, 97, 97, 97, 97, 97, 1108, 97, 97, 97, 97, 97, 97, 306, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1371, 97, 97, 97, 97, 97, 97, 97, 97, 1132, 97, 97, 97, 97, 97, 97, 1138, 97, 1140, 97, 1143, 97, 97, 97, 97, 97, 1352, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 869, 97, 97, 97, 97, 97, 45, 1191, 45, 45, 45, 45, 45, 1196, 45, 45, 45, 45, 45, 45, 45, 45, 1407, 45, 45, 45, 45, 45, 45, 45, 45, 986, 45, 45, 45, 45, 45, 45, 991, 45, 67, 67, 67, 1256, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1048, 67, 67, 67, 97, 1336, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 615, 97, 1386, 45, 1387, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 455, 45, 457, 45, 45, 1424, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1433, 67, 1434, 67, 67, 67, 67, 67, 767, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1591, 67, 1593, 67, 67, 45, 45, 1805, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1814, 45, 45, 1816, 67, 67, 67, 67, 1820, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1829, 67, 67, 67, 67, 67, 815, 67, 67, 67, 67, 821, 67, 67, 67, 37689, 544, 67, 1831, 97, 97, 97, 97, 1835, 0, 0, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1731, 97, 97, 97, 97, 97, 97, 97, 97, 97, 853, 97, 97, 97, 97, 97, 97, 0, 97, 97, 97, 97, 1850, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1547, 45, 45, 45, 45, 45, 45, 45, 45, 1664, 45, 45, 45, 45, 45, 45, 45, 45, 961, 45, 45, 45, 45, 965, 45, 967, 1907, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1920, 0, 1936, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 67, 67, 67, 67, 67, 67, 1763, 67, 67, 67, 67, 67, 67, 67, 67, 1056, 67, 67, 67, 67, 67, 67, 67, 67, 1273, 67, 67, 67, 67, 67, 67, 67, 67, 1457, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 28672, 97, 45, 67, 67, 67, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 2054, 97, 97, 291, 97, 97, 97, 97, 97, 97, 320, 97, 97, 97, 97, 97, 97, 307, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 12288, 0, 925, 926, 1179, 0, 45, 377, 45, 45, 45, 381, 45, 45, 392, 45, 45, 396, 45, 45, 45, 45, 971, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1756, 45, 45, 45, 67, 67, 67, 67, 463, 67, 67, 67, 467, 67, 67, 478, 67, 67, 482, 67, 67, 67, 67, 67, 1028, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1469, 67, 67, 1472, 67, 502, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1460, 67, 97, 97, 97, 97, 560, 97, 97, 97, 564, 97, 97, 575, 97, 97, 579, 97, 97, 97, 97, 97, 1368, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 925, 0, 0, 930, 97, 599, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 872, 97, 45, 666, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1758, 0, 362, 0, 0, 925, 41606, 0, 0, 0, 0, 45, 45, 934, 45, 45, 45, 164, 168, 174, 178, 45, 45, 45, 45, 45, 194, 45, 45, 45, 165, 45, 45, 45, 45, 45, 45, 45, 45, 45, 199, 45, 45, 45, 67, 67, 1010, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1060, 67, 67, 67, 67, 67, 67, 1052, 1053, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1063, 97, 1157, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1167, 97, 97, 97, 97, 97, 1379, 97, 97, 97, 0, 0, 0, 45, 1383, 45, 45, 45, 1806, 45, 45, 45, 45, 45, 45, 1812, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1577, 67, 67, 67, 67, 67, 67, 67, 753, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1262, 67, 67, 67, 67, 67, 67, 67, 1282, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1471, 67, 45, 1402, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 417, 45, 67, 1462, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 37689, 544, 97, 1517, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1128, 97, 97, 97, 97, 1636, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 851, 97, 97, 97, 97, 97, 97, 97, 67, 67, 1705, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1842, 0, 0, 1779, 97, 97, 97, 1782, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1789, 97, 97, 0, 0, 0, 97, 1847, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1675, 45, 45, 45, 45, 45, 45, 45, 45, 737, 738, 67, 740, 67, 741, 67, 743, 67, 67, 67, 67, 67, 67, 1968, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 45, 67, 0, 97, 45, 67, 2062, 97, 45, 67, 0, 97, 45, 67, 67, 97, 97, 2001, 97, 0, 0, 2004, 97, 97, 0, 97, 97, 97, 97, 1797, 97, 97, 97, 97, 97, 45, 45, 45, 67, 261, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 97, 292, 97, 97, 97, 97, 311, 315, 321, 325, 97, 97, 97, 97, 97, 97, 1623, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1330, 97, 97, 1333, 1334, 97, 341, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 0, 363, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 1221, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 413, 45, 45, 416, 45, 376, 45, 45, 45, 45, 382, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1408, 45, 45, 45, 45, 45, 403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 414, 45, 45, 45, 418, 67, 67, 67, 462, 67, 67, 67, 67, 468, 67, 67, 67, 67, 67, 67, 67, 67, 1602, 67, 1604, 67, 67, 67, 67, 67, 67, 67, 67, 489, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 500, 67, 67, 67, 67, 67, 1067, 67, 67, 67, 67, 67, 1072, 67, 67, 67, 67, 67, 67, 274, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 67, 67, 504, 67, 67, 67, 67, 67, 67, 67, 510, 67, 67, 67, 517, 519, 541, 67, 37139, 37139, 24853, 24853, 0, 70179, 0, 0, 0, 65820, 65820, 369, 287, 554, 97, 97, 97, 559, 97, 97, 97, 97, 565, 97, 97, 97, 97, 97, 97, 97, 1718, 0, 97, 97, 97, 97, 97, 97, 97, 898, 97, 97, 97, 97, 97, 97, 906, 97, 97, 97, 97, 586, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 597, 97, 97, 97, 97, 97, 1520, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 45, 1656, 45, 45, 45, 97, 97, 601, 97, 97, 97, 97, 97, 97, 97, 607, 97, 97, 97, 614, 616, 638, 97, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 369, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 661, 45, 45, 45, 407, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1815, 45, 67, 45, 667, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 678, 45, 45, 45, 421, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 976, 977, 45, 45, 45, 682, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 693, 45, 45, 697, 67, 67, 748, 67, 67, 67, 67, 754, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1274, 67, 67, 67, 67, 67, 67, 67, 67, 765, 67, 67, 67, 67, 769, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1589, 67, 67, 67, 67, 67, 67, 67, 67, 780, 67, 67, 784, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1777, 67, 97, 97, 97, 97, 97, 97, 846, 97, 97, 97, 97, 852, 97, 97, 97, 97, 97, 97, 97, 1742, 45, 45, 45, 45, 45, 45, 45, 1747, 97, 97, 97, 863, 97, 97, 97, 97, 867, 97, 97, 97, 97, 97, 97, 97, 308, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 12288, 1178, 925, 0, 1179, 0, 97, 97, 97, 878, 97, 97, 882, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 12288, 0, 925, 0, 1179, 0, 908, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 925, 0, 0, 0, 954, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 963, 45, 45, 966, 45, 45, 157, 45, 45, 171, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 948, 45, 45, 45, 45, 45, 1022, 67, 67, 1026, 67, 67, 67, 1030, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1603, 1605, 67, 67, 67, 1608, 67, 67, 67, 1039, 67, 67, 1042, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 471, 67, 67, 67, 67, 67, 0, 1100, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 904, 97, 97, 97, 97, 1116, 97, 97, 1120, 97, 97, 97, 1124, 97, 97, 97, 97, 97, 97, 562, 97, 97, 97, 571, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1133, 97, 97, 1136, 97, 97, 97, 97, 97, 97, 97, 97, 915, 917, 97, 97, 97, 97, 97, 0, 97, 1170, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 925, 0, 0, 0, 0, 0, 41606, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1993, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1275, 67, 67, 67, 1278, 67, 0, 0, 0, 45, 45, 1182, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1189, 1204, 45, 45, 45, 1207, 45, 45, 1209, 45, 1210, 45, 45, 45, 45, 45, 45, 1546, 45, 45, 45, 45, 45, 45, 45, 45, 45, 689, 45, 45, 45, 45, 45, 45, 1231, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 236, 67, 67, 67, 67, 67, 67, 67, 801, 67, 67, 67, 805, 67, 67, 67, 67, 67, 1242, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1249, 67, 67, 67, 67, 67, 67, 507, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1300, 0, 0, 0, 0, 0, 1267, 67, 67, 1269, 67, 1270, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1280, 97, 1349, 97, 1350, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1360, 97, 97, 97, 0, 1980, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 673, 45, 45, 45, 45, 677, 45, 45, 45, 45, 1401, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 953, 67, 1437, 67, 1440, 67, 67, 67, 67, 1445, 67, 67, 67, 1448, 67, 67, 67, 67, 67, 67, 1029, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1825, 67, 67, 67, 67, 67, 1473, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1320, 0, 834, 97, 97, 97, 97, 1490, 97, 1493, 97, 97, 97, 97, 1498, 97, 97, 97, 1501, 97, 97, 97, 0, 97, 1638, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 916, 97, 97, 97, 97, 97, 97, 0, 1528, 97, 97, 97, 0, 45, 45, 45, 1535, 45, 45, 45, 45, 45, 45, 45, 1867, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1932, 0, 0, 1555, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1567, 45, 45, 158, 45, 45, 172, 45, 45, 45, 183, 45, 45, 45, 45, 201, 45, 45, 67, 212, 67, 67, 67, 67, 231, 235, 241, 245, 67, 67, 67, 67, 67, 67, 493, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 472, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1651, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 1539, 45, 45, 45, 67, 1704, 67, 1706, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1841, 97, 0, 1844, 97, 97, 97, 97, 1716, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 590, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 1385, 1748, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1757, 45, 45, 159, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 415, 45, 45, 97, 97, 1780, 97, 97, 97, 0, 0, 1786, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1730, 0, 97, 97, 97, 97, 97, 1736, 97, 1738, 67, 97, 97, 97, 97, 97, 97, 0, 1838, 97, 97, 97, 97, 97, 0, 0, 97, 1729, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1162, 97, 97, 97, 1165, 97, 97, 97, 45, 1950, 45, 45, 45, 45, 45, 45, 45, 45, 1958, 67, 67, 67, 1962, 67, 67, 67, 67, 67, 1246, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 1710, 97, 97, 97, 1999, 67, 97, 97, 97, 97, 0, 2003, 97, 97, 97, 0, 97, 97, 2008, 2009, 45, 67, 67, 67, 67, 0, 0, 97, 97, 97, 97, 45, 2052, 67, 2053, 0, 0, 0, 0, 925, 41606, 0, 0, 930, 0, 45, 45, 45, 45, 45, 45, 1392, 45, 1394, 45, 45, 45, 45, 45, 45, 45, 1545, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1563, 1565, 45, 45, 45, 1568, 0, 97, 2055, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 28672, 97, 45, 45, 160, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 679, 45, 45, 67, 67, 266, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 346, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 0, 362, 0, 364, 0, 367, 41098, 369, 140, 371, 45, 45, 45, 379, 45, 45, 45, 388, 45, 45, 45, 45, 45, 45, 45, 45, 1663, 45, 45, 45, 45, 45, 45, 45, 45, 45, 449, 45, 45, 45, 45, 45, 67, 67, 542, 37139, 37139, 24853, 24853, 0, 70179, 0, 0, 0, 65820, 65820, 369, 287, 97, 97, 97, 97, 97, 1622, 97, 97, 97, 97, 97, 97, 97, 1629, 97, 97, 0, 1794, 1795, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1745, 45, 45, 97, 639, 18, 0, 139621, 0, 0, 0, 0, 0, 0, 364, 0, 0, 367, 41606, 45, 731, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 251, 67, 67, 67, 67, 67, 798, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1073, 67, 67, 67, 860, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 873, 0, 0, 1101, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 921, 97, 0, 67, 67, 67, 67, 1245, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1250, 67, 67, 1253, 0, 0, 1312, 0, 0, 0, 1318, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1106, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1149, 97, 97, 97, 97, 97, 1155, 97, 97, 1325, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1141, 97, 97, 67, 67, 1439, 67, 1441, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1264, 67, 67, 67, 97, 97, 1492, 97, 1494, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1331, 97, 97, 97, 97, 67, 67, 67, 2037, 67, 97, 0, 0, 97, 97, 97, 2043, 97, 45, 45, 45, 442, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 232, 67, 67, 67, 67, 67, 67, 67, 67, 1823, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1975, 0, 0, 97, 874, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1142, 97, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 65, 86, 117, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 63, 84, 115, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 61, 82, 113, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 59, 80, 111, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 57, 78, 109, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 55, 76, 107, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 53, 74, 105, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 51, 72, 103, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 49, 70, 101, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 47, 68, 99, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 45, 67, 97, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 213085, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 0, 0, 44, 0, 0, 32863, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 41, 41, 41, 0, 0, 1138688, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 0, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 89, 53264, 18, 18, 49172, 0, 57366, 0, 24, 24, 24, 0, 127, 127, 127, 127, 102432, 67, 262, 67, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 342, 97, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 360, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 717, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 412, 45, 45, 45, 45, 45, 67, 1009, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1292, 67, 67, 1294, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 97, 97, 97, 1615, 97, 97, 97, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 66, 87, 118, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 64, 85, 116, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 62, 83, 114, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 60, 81, 112, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 58, 79, 110, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 56, 77, 108, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 54, 75, 106, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 52, 73, 104, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 50, 71, 102, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 48, 69, 100, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 37, 110630, 114730, 106539, 46, 67, 98, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 233472, 53264, 18, 49172, 57366, 24, 8192, 28, 102432, 0, 110630, 114730, 106539, 0, 0, 69724, 53264, 18, 18, 49172, 0, 57366, 262144, 24, 24, 24, 0, 28, 28, 28, 28, 102432, 45, 45, 161, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 710, 45, 45, 28, 139621, 359, 0, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 1389, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 949, 45, 45, 45, 45, 67, 503, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1449, 67, 67, 97, 600, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1154, 97, 0, 0, 0, 0, 925, 41606, 927, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1866, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 772, 67, 67, 67, 67, 67, 45, 45, 969, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 951, 45, 45, 45, 45, 1192, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1202, 45, 45, 0, 0, 0, 1314, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1488, 67, 67, 267, 67, 67, 67, 67, 0, 37139, 24853, 0, 0, 0, 0, 41098, 65820, 97, 347, 97, 97, 97, 97, 0, 53264, 0, 18, 18, 24, 24, 0, 28, 28, 139621, 0, 361, 0, 0, 364, 0, 367, 41098, 369, 140, 45, 45, 45, 45, 734, 45, 45, 45, 67, 67, 67, 67, 67, 742, 67, 67, 45, 45, 668, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1214, 45, 45, 1130, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1361, 97, 45, 45, 1671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1552, 45, 45, 0, 0, 0, 0, 2220032, 0, 0, 1130496, 0, 0, 0, 0, 2170880, 2171020, 2170880, 2170880, 18, 0, 0, 131072, 0, 0, 0, 90112, 0, 2220032, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 1485, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 1537, 45, 45, 45, 45, 45, 1390, 45, 1393, 45, 45, 45, 45, 1398, 45, 45, 45, 2170880, 2171167, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2576384, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 0, 0, 0, 0, 0, 2174976, 0, 0, 0, 0, 0, 0, 2183168, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 2721252, 2744320, 2170880, 2170880, 2170880, 2834432, 2840040, 2170880, 2908160, 2170880, 2170880, 2936832, 2170880, 2170880, 2985984, 2170880, 2994176, 2170880, 2170880, 3014656, 2170880, 3059712, 3076096, 3088384, 2170880, 2170880, 2170880, 2170880, 0, 0, 0, 0, 2220032, 0, 0, 0, 1142784, 0, 0, 0, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3215360, 2215936, 2215936, 2215936, 2215936, 2215936, 2437120, 2215936, 2215936, 2215936, 3117056, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 2215936, 0, 543, 0, 545, 0, 0, 2183168, 0, 0, 831, 0, 2170880, 2170880, 2170880, 2400256, 2170880, 2170880, 2170880, 2170880, 3031040, 2170880, 3055616, 2170880, 2170880, 2170880, 2170880, 3092480, 2170880, 2170880, 3125248, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 2170880, 3198976, 2170880, 0, 0, 0, 0, 0, 0, 67, 67, 37139, 37139, 24853, 24853, 0, 0, 0, 0, 0, 65820, 65820, 0, 287, 97, 97, 97, 97, 97, 1783, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 1791, 0, 0, 546, 70179, 0, 0, 0, 0, 552, 0, 97, 97, 97, 97, 97, 97, 97, 604, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1150, 97, 97, 97, 97, 97, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 147456, 0, 0, 147456, 0, 0, 0, 0, 925, 41606, 0, 928, 0, 0, 45, 45, 45, 45, 45, 45, 998, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1562, 45, 1564, 45, 45, 45, 45, 0, 2158592, 2158592, 0, 0, 0, 0, 2232320, 2232320, 2232320, 0, 2240512, 2240512, 2240512, 2240512, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2170880, 2170880, 2170880, 2416640
+];
+
+JSONiqTokenizer.EXPECTED =
+[ 291, 300, 304, 341, 315, 309, 305, 295, 319, 323, 327, 329, 296, 333, 337, 339, 342, 346, 350, 294, 356, 360, 312, 367, 352, 371, 363, 375, 379, 383, 387, 391, 395, 726, 399, 405, 518, 684, 405, 405, 405, 405, 808, 405, 405, 405, 512, 405, 405, 405, 431, 405, 405, 406, 405, 405, 404, 405, 405, 405, 405, 405, 405, 405, 908, 631, 410, 415, 405, 414, 419, 608, 405, 429, 602, 405, 435, 443, 405, 441, 641, 478, 405, 447, 451, 450, 456, 643, 461, 460, 762, 679, 465, 469, 741, 473, 477, 482, 486, 492, 932, 931, 523, 498, 504, 720, 405, 510, 596, 405, 516, 941, 580, 522, 929, 527, 590, 589, 897, 939, 534, 538, 547, 551, 555, 559, 563, 567, 571, 969, 575, 708, 690, 689, 579, 584, 634, 405, 594, 731, 405, 600, 882, 405, 606, 895, 786, 452, 612, 405, 615, 620, 876, 624, 628, 638, 647, 651, 655, 659, 663, 667, 676, 683, 688, 695, 694, 791, 405, 699, 437, 405, 706, 714, 405, 712, 825, 870, 405, 718, 724, 769, 768, 823, 730, 735, 745, 751, 422, 755, 759, 425, 766, 902, 810, 587, 775, 888, 887, 405, 773, 992, 405, 779, 962, 405, 785, 781, 986, 790, 795, 797, 506, 500, 499, 801, 805, 814, 820, 829, 833, 837, 841, 845, 849, 853, 857, 861, 616, 865, 869, 868, 488, 405, 874, 816, 405, 880, 738, 405, 886, 892, 543, 405, 901, 906, 913, 912, 918, 494, 541, 922, 926, 936, 945, 949, 953, 957, 530, 966, 973, 960, 702, 701, 405, 979, 981, 405, 985, 747, 405, 990, 998, 914, 405, 996, 1004, 672, 975, 974, 1014, 1002, 1008, 670, 1012, 405, 405, 405, 405, 405, 401, 1018, 1022, 1026, 1106, 1071, 1111, 1111, 1111, 1082, 1145, 1030, 1101, 1034, 1038, 1106, 1106, 1106, 1106, 1046, 1206, 1052, 1106, 1072, 1111, 1111, 1042, 1134, 1065, 1111, 1112, 1056, 1160, 1207, 1062, 1204, 1208, 1069, 1106, 1106, 1106, 1076, 1111, 1207, 1161, 1122, 1205, 1064, 1094, 1106, 1106, 1107, 1111, 1111, 1111, 1078, 1086, 1207, 1092, 1098, 1046, 1058, 1106, 1106, 1110, 1111, 1111, 1116, 1120, 1161, 1126, 1202, 1104, 1106, 1145, 1146, 1129, 1138, 1088, 1151, 1048, 1157, 1153, 1132, 1141, 1165, 1107, 1111, 1172, 1179, 1109, 1183, 1175, 1143, 1147, 1187, 1108, 1191, 1195, 1144, 1199, 1168, 1212, 1216, 1220, 1224, 1228, 1232, 1236, 1557, 1247, 1241, 1241, 1038, 1434, 1241, 1241, 1241, 1241, 1254, 1275, 1617, 1241, 1280, 1287, 1241, 1241, 1241, 1287, 1241, 2114, 1291, 1241, 1243, 1241, 2049, 1824, 2094, 2095, 1520, 1309, 1241, 1241, 1302, 1241, 1321, 1311, 1241, 1241, 1313, 1778, 1325, 1336, 1241, 1241, 1325, 1330, 1353, 1241, 1241, 1695, 1354, 1241, 1241, 1241, 1294, 1686, 1331, 1241, 1696, 1368, 1241, 1338, 1370, 1241, 1392, 1399, 1364, 2017, 1406, 2016, 1405, 1716, 1406, 1407, 1422, 1417, 1421, 1241, 1241, 1241, 1349, 1426, 1241, 1774, 1756, 1241, 1773, 1241, 1241, 1345, 1964, 1812, 1432, 1241, 1241, 1345, 1993, 1459, 1241, 1241, 1241, 1395, 1848, 1767, 1465, 1241, 1241, 1394, 1847, 1242, 1477, 1241, 1241, 1428, 1241, 1445, 1492, 1241, 1241, 1438, 1241, 1499, 1241, 1241, 1241, 1455, 1241, 1818, 1448, 1241, 1250, 1241, 2026, 1623, 1449, 1241, 1612, 1616, 1241, 1614, 1241, 1257, 1241, 1241, 1985, 1292, 1586, 1512, 1241, 1517, 2050, 1526, 1674, 1519, 1524, 1647, 2051, 1532, 1537, 1551, 1544, 1550, 1555, 1561, 1571, 1578, 1584, 1590, 1591, 1653, 1595, 1602, 1606, 1610, 1634, 1628, 1640, 1633, 1645, 1241, 1241, 1241, 1469, 1241, 1970, 1651, 1241, 1270, 1241, 1241, 1819, 1449, 1241, 1293, 1664, 1241, 1241, 1481, 1485, 1574, 1672, 1241, 1241, 1513, 1317, 1487, 1684, 1241, 1241, 1533, 1299, 1694, 1241, 1241, 1295, 1241, 1241, 1241, 1546, 1700, 1241, 1241, 1707, 1241, 1713, 1241, 1849, 1715, 1241, 1720, 1241, 1276, 1267, 1241, 1241, 2107, 1657, 1864, 1241, 1881, 1241, 1326, 1292, 1241, 1685, 1358, 1724, 1338, 1241, 1363, 1362, 1342, 1340, 1361, 1339, 1833, 1372, 1360, 1833, 1833, 1342, 1343, 1835, 1341, 1731, 1738, 1344, 1241, 1745, 1241, 1379, 1241, 1241, 2092, 1241, 1388, 1761, 1754, 1241, 1386, 1241, 1400, 1760, 1241, 1241, 1241, 1598, 1734, 1241, 1241, 1241, 1635, 1645, 1241, 1780, 1766, 1241, 1241, 1332, 1771, 1241, 1241, 1629, 2079, 1241, 1242, 1784, 1241, 1241, 1680, 1639, 2063, 1790, 1241, 1241, 1741, 1241, 1241, 1800, 1241, 1241, 1762, 1473, 1241, 1806, 1241, 1241, 1786, 1240, 1709, 1241, 1241, 1241, 1668, 1811, 1241, 1940, 1241, 1401, 1974, 1241, 1408, 1413, 1382, 1241, 1816, 1241, 1241, 1802, 2086, 1811, 1241, 1817, 1945, 1823, 2095, 2095, 2047, 2094, 2046, 2080, 1241, 1409, 1312, 1376, 2096, 2048, 1241, 1241, 1807, 1241, 1241, 1241, 2035, 1241, 1241, 1828, 1241, 2057, 2061, 1241, 1241, 1843, 1241, 2059, 1241, 1241, 1241, 1690, 1847, 1241, 1241, 1241, 1703, 2102, 1848, 1241, 1241, 1853, 1292, 1848, 1241, 2016, 1857, 1241, 2002, 1868, 1241, 1436, 1241, 1241, 1271, 1305, 1241, 1874, 1241, 1241, 1884, 2037, 1892, 1241, 1890, 1241, 1461, 1241, 1241, 1795, 1241, 1241, 1891, 1241, 1878, 1241, 1888, 1241, 1888, 1905, 1896, 2087, 1912, 1903, 1241, 1911, 1906, 1916, 1905, 2027, 1863, 1925, 2088, 1859, 1861, 1922, 1927, 1931, 1935, 1494, 1241, 1241, 1918, 1907, 1939, 1917, 1944, 1949, 1241, 1241, 1451, 1955, 1241, 1241, 1241, 1796, 1727, 2061, 1241, 1241, 1899, 1241, 1660, 1968, 1241, 1241, 1951, 1678, 1978, 1241, 1241, 1241, 1839, 1241, 1241, 1984, 1982, 1241, 1488, 1241, 1241, 1624, 1450, 1989, 1241, 1241, 1241, 1870, 1995, 1292, 1241, 1241, 1958, 1261, 1241, 1996, 1241, 1241, 1241, 2039, 2008, 1241, 1241, 1750, 2000, 1241, 1256, 2001, 1960, 1241, 1564, 1241, 1504, 1241, 1241, 1442, 1241, 1241, 1564, 1528, 1263, 1241, 1508, 1241, 1241, 1468, 1498, 2006, 1540, 2015, 1539, 2014, 1748, 2013, 1539, 1831, 2014, 2012, 1500, 1567, 2022, 2021, 1241, 1580, 1241, 1241, 2033, 2037, 1791, 2045, 2031, 1241, 1621, 1241, 1641, 2044, 1241, 1241, 1241, 2093, 1241, 1241, 2055, 1241, 1241, 2067, 1241, 1283, 1241, 1241, 1241, 2101, 2071, 1241, 1241, 1241, 2073, 1848, 2040, 1241, 1241, 1241, 2077, 1241, 1241, 2106, 1241, 1241, 2084, 1241, 2111, 1241, 1241, 1381, 1380, 1241, 1241, 1241, 2100, 1241, 2129, 2118, 2122, 2126, 2197, 2133, 3010, 2825, 2145, 2698, 2156, 2226, 2160, 2161, 2165, 2174, 2293, 2194, 2630, 2201, 2203, 2152, 3019, 2226, 2263, 2209, 2213, 2218, 2269, 2292, 2269, 2269, 2184, 2226, 2238, 2148, 2151, 3017, 2245, 2214, 2269, 2269, 2185, 2226, 2292, 2269, 2291, 2269, 2269, 2269, 2292, 2205, 3019, 2226, 2226, 2160, 2160, 2160, 2261, 2160, 2160, 2160, 2262, 2276, 2160, 2160, 2277, 2216, 2283, 2216, 2269, 2269, 2268, 2269, 2267, 2269, 2269, 2269, 2271, 2568, 2292, 2269, 2293, 2269, 2182, 2190, 2269, 2186, 2226, 2226, 2226, 2226, 2227, 2160, 2160, 2160, 2160, 2263, 2160, 2275, 2277, 2282, 2215, 2217, 2269, 2269, 2291, 2269, 2269, 2293, 2291, 2269, 2220, 2269, 2295, 2294, 2269, 2269, 2305, 2233, 2262, 2278, 2218, 2269, 2234, 2226, 2226, 2228, 2160, 2160, 2160, 2289, 2220, 2294, 2294, 2269, 2269, 2304, 2269, 2160, 2160, 2287, 2269, 2269, 2305, 2269, 2269, 2312, 2269, 2269, 2225, 2226, 2160, 2287, 2289, 2219, 2304, 2295, 2314, 2234, 2226, 2314, 2269, 2226, 2226, 2160, 2288, 2219, 2222, 2304, 2296, 2269, 2224, 2160, 2160, 2269, 2302, 2294, 2314, 2224, 2226, 2288, 2220, 2294, 2269, 2290, 2269, 2269, 2293, 2269, 2269, 2269, 2269, 2270, 2221, 2313, 2225, 2227, 2160, 2300, 2269, 2225, 2261, 2309, 2234, 2229, 2223, 2318, 2318, 2318, 2328, 2336, 2340, 2344, 2350, 2637, 2712, 2358, 2362, 2372, 2135, 2378, 2398, 2135, 2135, 2135, 2135, 2136, 2417, 2241, 2135, 2378, 2135, 2135, 2980, 2984, 2135, 3006, 2135, 2135, 2135, 2945, 2931, 2425, 2400, 2135, 2135, 2135, 2954, 2135, 2481, 2433, 2135, 2135, 2988, 2824, 2135, 2135, 2482, 2434, 2135, 2135, 2440, 2445, 2452, 2135, 2135, 2998, 3002, 2961, 2441, 2446, 2453, 2463, 2974, 2135, 2135, 2135, 2140, 2642, 2709, 2459, 2470, 2465, 2135, 2135, 3005, 2135, 2135, 2987, 2823, 2458, 2469, 2464, 2975, 2135, 2135, 2135, 2353, 2488, 2447, 2324, 2974, 2135, 2409, 2459, 2448, 2135, 2961, 2487, 2446, 2476, 2323, 2973, 2135, 2135, 2135, 2354, 2476, 2974, 2135, 2135, 2135, 2957, 2135, 2135, 2960, 2135, 2135, 2135, 2363, 2409, 2459, 2474, 2465, 2487, 2571, 2973, 2135, 2135, 2168, 2973, 2135, 2135, 2135, 2959, 2135, 2135, 2135, 2506, 2135, 2957, 2488, 2170, 2135, 2135, 2135, 2960, 2135, 2818, 2493, 2135, 2135, 3033, 2135, 2135, 2135, 2934, 2819, 2494, 2135, 2135, 2135, 2976, 2780, 2499, 2135, 2135, 2135, 3000, 2968, 2135, 2935, 2135, 2135, 2135, 2364, 2507, 2135, 2135, 2934, 2135, 2135, 2780, 2492, 2507, 2135, 2135, 2506, 2780, 2135, 2135, 2782, 2780, 2135, 2782, 2135, 2783, 2374, 2514, 2135, 2135, 2135, 3007, 2530, 2974, 2135, 2135, 2135, 3008, 2135, 2135, 2134, 2135, 2526, 2531, 2975, 2135, 2135, 3042, 2581, 2575, 2956, 2135, 2135, 2135, 2394, 2135, 2508, 2535, 2840, 2844, 2495, 2135, 2135, 2136, 2684, 2537, 2842, 2846, 2135, 2136, 2561, 2581, 2551, 2536, 2841, 2845, 2975, 3043, 2582, 2843, 2555, 2135, 3040, 3044, 2538, 2844, 2975, 2135, 2135, 2253, 2644, 2672, 2542, 2554, 2135, 2135, 2346, 2873, 2551, 2555, 2135, 2135, 2135, 2381, 2559, 2565, 2538, 2553, 2135, 2560, 2914, 2576, 2590, 2135, 2135, 2135, 2408, 2136, 2596, 2624, 2135, 2135, 2135, 2409, 2135, 2618, 2597, 3008, 2135, 2135, 2380, 2956, 2601, 2135, 2135, 2135, 2410, 2620, 2624, 2135, 2136, 2383, 2135, 2135, 2783, 2623, 2135, 2135, 2393, 2888, 2136, 2621, 3008, 2135, 2618, 2618, 2622, 2135, 2135, 2405, 2414, 2619, 2384, 2624, 2135, 2136, 2950, 2135, 2138, 2135, 2139, 2135, 2604, 2623, 2135, 2140, 2878, 2665, 2957, 2622, 2135, 2135, 2428, 2762, 2606, 2612, 2135, 2135, 2501, 2586, 2604, 3038, 2135, 2604, 3036, 2387, 2958, 2386, 2135, 2141, 2135, 2421, 2387, 2385, 2135, 2385, 2384, 2384, 2135, 2386, 2628, 2384, 2135, 2135, 2501, 2596, 2591, 2135, 2135, 2135, 2400, 2135, 2634, 2135, 2135, 2559, 2580, 2575, 2648, 2135, 2135, 2135, 2429, 2649, 2135, 2135, 2135, 2435, 2654, 2658, 2135, 2135, 2135, 2436, 2649, 2178, 2659, 2135, 2135, 2595, 2601, 2669, 2677, 2135, 2135, 2616, 2957, 2879, 2665, 2691, 2135, 2363, 2367, 2900, 2878, 2664, 2690, 2975, 2877, 2643, 2670, 2974, 2671, 2975, 2135, 2135, 2619, 2608, 2669, 2673, 2135, 2135, 2653, 2177, 2672, 2135, 2135, 2135, 2486, 2168, 2251, 2255, 2695, 2974, 2709, 2135, 2135, 2135, 2487, 2169, 2399, 2716, 2975, 2135, 2363, 2770, 2776, 2640, 2717, 2135, 2135, 2729, 2135, 2135, 2641, 2718, 2135, 2135, 2135, 2505, 2135, 2640, 2257, 2974, 2135, 2727, 2975, 2135, 2365, 2332, 2895, 2957, 2135, 2959, 2135, 2365, 2749, 2754, 2959, 2958, 2958, 2135, 2380, 2793, 2799, 2135, 2735, 2738, 2135, 2381, 2135, 2135, 2940, 2974, 2135, 2744, 2135, 2135, 2739, 2519, 2976, 2745, 2135, 2135, 2135, 2509, 2755, 2135, 2135, 2135, 2510, 2772, 2778, 2135, 2135, 2740, 2520, 2135, 2771, 2777, 2135, 2135, 2759, 2750, 2792, 2798, 2135, 2135, 2781, 2392, 2779, 2135, 2135, 2135, 2521, 2135, 2679, 2248, 2135, 2135, 2681, 2480, 2135, 2135, 2786, 3000, 2135, 2679, 2683, 2135, 2135, 2416, 2135, 2135, 2135, 2525, 2135, 2730, 2135, 2135, 2135, 2560, 2581, 2135, 2805, 2135, 2135, 2804, 2962, 2832, 2974, 2135, 2382, 2135, 2135, 2958, 2135, 2135, 2960, 2135, 2829, 2833, 2975, 2961, 2965, 2969, 2973, 2968, 2972, 2135, 2135, 2135, 2641, 2135, 2515, 2966, 2970, 2851, 2478, 2135, 2135, 2808, 2135, 2809, 2135, 2135, 2135, 2722, 2852, 2479, 2135, 2135, 2815, 2135, 2135, 2766, 2853, 2480, 2135, 2857, 2479, 2135, 2388, 2723, 2135, 2364, 2331, 2894, 2858, 2480, 2135, 2135, 2850, 2478, 2135, 2135, 2135, 2806, 2864, 2135, 2399, 2256, 2974, 2865, 2135, 2135, 2862, 2135, 2135, 2135, 2685, 2807, 2865, 2135, 2135, 2807, 2863, 2135, 2135, 2135, 2686, 2884, 2807, 2135, 2809, 2807, 2135, 2135, 2807, 2806, 2705, 2810, 2808, 2700, 2869, 2702, 2702, 2702, 2704, 2883, 2135, 2135, 2135, 2730, 2884, 2135, 2135, 2135, 2731, 2321, 2546, 2135, 2135, 2876, 2255, 2889, 2322, 2547, 2135, 2401, 2135, 2135, 2135, 2949, 2367, 2893, 2544, 2973, 2906, 2973, 2135, 2135, 2877, 2663, 2368, 2901, 2907, 2974, 2366, 2899, 2905, 2972, 2920, 2974, 2135, 2135, 2911, 2900, 2920, 2363, 2913, 2918, 2465, 2941, 2975, 2135, 2135, 2924, 2928, 2974, 2945, 2931, 2135, 2135, 2135, 2765, 2136, 2955, 2135, 2135, 2939, 2931, 2380, 2135, 2135, 2380, 2135, 2135, 2135, 2780, 2507, 2137, 2135, 2137, 2135, 2139, 2135, 2806, 2810, 2135, 2135, 2135, 2992, 2135, 2135, 2962, 2966, 2970, 2974, 2135, 2135, 2787, 3014, 2135, 2521, 2993, 2135, 2135, 2135, 2803, 2135, 2135, 2135, 2618, 2607, 2997, 3001, 2135, 2135, 2963, 2967, 2971, 2975, 2135, 2135, 2791, 2797, 2135, 3009, 2999, 3003, 2787, 3001, 2135, 2135, 2964, 2968, 2785, 2999, 3003, 2135, 2135, 2135, 2804, 2785, 2999, 3004, 2135, 2135, 2135, 2807, 2135, 2135, 3023, 2135, 2135, 2135, 2811, 2135, 2135, 3027, 2135, 2135, 2135, 2837, 2968, 3028, 2135, 2135, 2135, 2875, 2135, 2784, 3029, 2135, 2408, 2457, 2446, 0, 14, 0, -2120220672, 1610612736, -2074083328, -2002780160, -2111830528, 1073872896, 1342177280, 1075807216, 4096, 16384, 2048, 8192, 0, 8192, 0, 0, 0, 0, 1, 0, 0, 0, 2, 0, -2145386496, 8388608, 1073741824, 0, 0x80000000, 0x80000000, 2097152, 2097152, 2097152, 536870912, 0, 0, 134217728, 33554432, 1536, 268435456, 268435456, 268435456, 268435456, 128, 256, 32, 0, 65536, 131072, 524288, 16777216, 268435456, 0x80000000, 1572864, 1835008, 640, 32768, 65536, 262144, 1048576, 2097152, 196608, 196800, 196608, 196608, 0, 131072, 131072, 131072, 196608, 196624, 196608, 196624, 196608, 196608, 128, 4096, 16384, 16384, 2048, 0, 4, 0, 0, 0x80000000, 2097152, 0, 1024, 32, 32, 0, 65536, 1572864, 1048576, 32768, 32768, 32768, 32768, 196608, 196608, 196608, 64, 64, 196608, 196608, 131072, 131072, 131072, 131072, 268435456, 268435456, 64, 196736, 196608, 196608, 196608, 131072, 196608, 196608, 16384, 4, 4, 4, 2, 32, 32, 65536, 1048576, 12582912, 1073741824, 0, 0, 2, 8, 16, 96, 2048, 32768, 0, 0, 131072, 268435456, 268435456, 268435456, 256, 256, 196608, 196672, 196608, 196608, 196608, 196608, 4, 0, 256, 256, 256, 256, 32, 32, 32768, 32, 32, 32, 32, 32768, 268435456, 268435456, 268435456, 196608, 196608, 196608, 196624, 196608, 196608, 196608, 16, 16, 16, 268435456, 196608, 64, 64, 64, 196608, 196608, 196608, 196672, 268435456, 64, 64, 196608, 196608, 16, 196608, 196608, 196608, 268435456, 64, 196608, 131072, 262144, 4194304, 25165824, 33554432, 134217728, 268435456, 268435456, 196608, 262152, 8, 256, 512, 3072, 16384, 200, -1073741816, 8392713, 40, 8392718, 520, 807404072, 40, 520, 100663304, 0, 0, -540651761, -540651761, 257589048, 0, 262144, 0, 0, 3, 8, 256, 0, 4, 6, 4100, 8388612, 0, 0, 0, 3, 4, 8, 256, 512, 1024, 0, 2097152, 0, 0, -537854471, -537854471, 0, 100663296, 0, 0, 1, 2, 0, 0, 0, 16384, 0, 0, 0, 96, 14336, 0, 0, 0, 7, 8, 234881024, 0, 0, 0, 8, 0, 0, 0, 0, 262144, 0, 0, 16, 64, 384, 512, 0, 1, 1, 0, 12582912, 0, 0, 0, 0, 33554432, 67108864, -606084144, -606084144, -606084138, 0, 0, 28, 32, 768, 1966080, -608174080, 0, 0, 0, 14, 35056, 16, 64, 896, 24576, 98304, 98304, 131072, 262144, 524288, 1048576, 4194304, 25165824, 1048576, 62914560, 134217728, -805306368, 0, 384, 512, 16384, 65536, 131072, 262144, 29360128, 33554432, 134217728, 268435456, 1073741824, 0x80000000, 262144, 524288, 1048576, 29360128, 33554432, 524288, 1048576, 16777216, 33554432, 134217728, 268435456, 1073741824, 0, 0, 0, 123856, 1966080, 0, 64, 384, 16384, 65536, 131072, 16384, 65536, 524288, 268435456, 0x80000000, 0, 0, 524288, 0x80000000, 0, 0, 1, 16, 0, 256, 524288, 0, 0, 0, 25, 96, 128, -537854471, 0, 0, 0, 32, 7404800, -545259520, 0, 0, 0, 60, 0, 249, 64768, 1048576, 6291456, 6291456, 25165824, 100663296, 402653184, 1073741824, 96, 128, 1280, 2048, 4096, 57344, 6291456, 57344, 6291456, 8388608, 16777216, 33554432, 201326592, 1342177280, 0x80000000, 0, 57344, 6291456, 8388608, 100663296, 134217728, 0x80000000, 0, 0, 0, 1, 8, 16, 64, 128, 64, 128, 256, 1024, 131072, 131072, 131072, 262144, 524288, 16777216, 57344, 6291456, 8388608, 67108864, 134217728, 64, 256, 1024, 2048, 4096, 57344, 64, 256, 0, 24576, 32768, 6291456, 67108864, 134217728, 0, 1, 64, 256, 24576, 32768, 4194304, 32768, 4194304, 67108864, 0, 0, 64, 256, 0, 0, 24576, 32768, 0, 16384, 4194304, 67108864, 64, 16384, 0, 0, 1, 64, 256, 16384, 4194304, 67108864, 0, 0, 0, 16384, 0, 16384, 16384, 0, -470447874, -470447874, -470447874, 0, 0, 128, 0, 0, 8, 96, 2048, 32768, 262144, 8388608, 35056, 1376256, -471859200, 0, 0, 14, 16, 224, 2048, 32768, 2097152, 4194304, 8388608, -486539264, 0, 96, 128, 2048, 32768, 262144, 2097152, 262144, 2097152, 8388608, 33554432, 536870912, 1073741824, 0x80000000, 0, 1610612736, 0x80000000, 0, 0, 1, 524288, 1048576, 12582912, 0, 0, 0, 151311, 264503296, 2097152, 8388608, 33554432, 1610612736, 0x80000000, 262144, 8388608, 33554432, 536870912, 67108864, 4194304, 0, 4194304, 0, 4194304, 4194304, 0, 0, 524288, 8388608, 536870912, 1073741824, 0x80000000, 1, 4097, 8388609, 96, 2048, 32768, 1073741824, 0x80000000, 0, 96, 2048, 0x80000000, 0, 0, 96, 2048, 0, 0, 1, 12582912, 0, 0, 0, 0, 1641895695, 1641895695, 0, 0, 0, 249, 7404800, 15, 87808, 1835008, 1639972864, 0, 768, 5120, 16384, 65536, 1835008, 1835008, 12582912, 16777216, 1610612736, 0, 3, 4, 8, 768, 4096, 65536, 0, 0, 256, 512, 786432, 8, 256, 512, 4096, 16384, 1835008, 16384, 1835008, 12582912, 1610612736, 0, 0, 0, 256, 0, 0, 0, 4, 8, 16, 32, 1, 2, 8, 256, 16384, 524288, 16384, 524288, 1048576, 12582912, 1610612736, 0, 0, 0, 8388608, 0, 0, 0, 524288, 4194304, 0, 0, 0, 8388608, -548662288, -548662288, -548662288, 0, 0, 256, 16384, 65536, 520093696, -1073741824, 0, 0, 0, 16777216, 0, 16, 32, 960, 4096, 4980736, 520093696, 1073741824, 0, 32, 896, 4096, 57344, 1048576, 6291456, 8388608, 16777216, 100663296, 134217728, 268435456, 0x80000000, 0, 512, 786432, 4194304, 33554432, 134217728, 268435456, 0, 786432, 4194304, 134217728, 268435456, 0, 524288, 4194304, 268435456, 0, 0, 0, 0, 0, 4194304, 4194304, -540651761, 0, 0, 0, 2, 4, 8, 16, 96, 128, 264503296, -805306368, 0, 0, 0, 8, 256, 512, 19456, 131072, 3072, 16384, 131072, 262144, 8388608, 16777216, 512, 1024, 2048, 16384, 131072, 262144, 131072, 262144, 8388608, 33554432, 201326592, 268435456, 0, 3, 4, 256, 1024, 2048, 57344, 16384, 131072, 8388608, 33554432, 134217728, 268435456, 0, 3, 256, 1024, 16384, 131072, 33554432, 134217728, 1073741824, 0x80000000, 0, 0, 256, 524288, 0x80000000, 0, 3, 256, 33554432, 134217728, 1073741824, 0, 1, 2, 33554432, 1, 2, 134217728, 1073741824, 0, 1, 2, 134217728, 0, 0, 0, 64, 0, 0, 0, 16, 32, 896, 4096, 786432, 4194304, 16777216, 33554432, 201326592, 268435456, 1073741824, 0x80000000, 0, 0, 0, 15, 0, 4980736, 4980736, 4980736, 70460, 70460, 3478332, 0, 0, 1008, 4984832, 520093696, 60, 4864, 65536, 0, 0, 0, 12, 16, 32, 256, 512, 4096, 65536, 0, 0, 0, 67108864, 0, 0, 0, 12, 0, 256, 512, 65536, 0, 0, 1024, 512, 131072, 131072, 4, 16, 32, 65536, 0, 4, 16, 32, 0, 0, 0, 4, 16, 0, 0, 16384, 67108864, 0, 0, 1, 24, 96, 128, 256, 1024
+];
+
+JSONiqTokenizer.TOKEN =
+[
+ "(0)",
+ "JSONChar",
+ "JSONCharRef",
+ "JSONPredefinedCharRef",
+ "ModuleDecl",
+ "Annotation",
+ "OptionDecl",
+ "Operator",
+ "Variable",
+ "Tag",
+ "EndTag",
+ "PragmaContents",
+ "DirCommentContents",
+ "DirPIContents",
+ "CDataSectionContents",
+ "AttrTest",
+ "Wildcard",
+ "EQName",
+ "IntegerLiteral",
+ "DecimalLiteral",
+ "DoubleLiteral",
+ "PredefinedEntityRef",
+ "'\"\"'",
+ "EscapeApos",
+ "AposChar",
+ "ElementContentChar",
+ "QuotAttrContentChar",
+ "AposAttrContentChar",
+ "NCName",
+ "QName",
+ "S",
+ "CharRef",
+ "CommentContents",
+ "DocTag",
+ "DocCommentContents",
+ "EOF",
+ "'!'",
+ "'\"'",
+ "'#'",
+ "'#)'",
+ "'$$'",
+ "''''",
+ "'('",
+ "'(#'",
+ "'(:'",
+ "'(:~'",
+ "')'",
+ "'*'",
+ "'*'",
+ "','",
+ "'-->'",
+ "'.'",
+ "'/'",
+ "'/>'",
+ "':'",
+ "':)'",
+ "';'",
+ "'<!--'",
+ "'<![CDATA['",
+ "'<?'",
+ "'='",
+ "'>'",
+ "'?'",
+ "'?>'",
+ "'NaN'",
+ "'['",
+ "']'",
+ "']]>'",
+ "'after'",
+ "'all'",
+ "'allowing'",
+ "'ancestor'",
+ "'ancestor-or-self'",
+ "'and'",
+ "'any'",
+ "'append'",
+ "'array'",
+ "'as'",
+ "'ascending'",
+ "'at'",
+ "'attribute'",
+ "'base-uri'",
+ "'before'",
+ "'boundary-space'",
+ "'break'",
+ "'by'",
+ "'case'",
+ "'cast'",
+ "'castable'",
+ "'catch'",
+ "'check'",
+ "'child'",
+ "'collation'",
+ "'collection'",
+ "'comment'",
+ "'constraint'",
+ "'construction'",
+ "'contains'",
+ "'content'",
+ "'context'",
+ "'continue'",
+ "'copy'",
+ "'copy-namespaces'",
+ "'count'",
+ "'decimal-format'",
+ "'decimal-separator'",
+ "'declare'",
+ "'default'",
+ "'delete'",
+ "'descendant'",
+ "'descendant-or-self'",
+ "'descending'",
+ "'diacritics'",
+ "'different'",
+ "'digit'",
+ "'distance'",
+ "'div'",
+ "'document'",
+ "'document-node'",
+ "'element'",
+ "'else'",
+ "'empty'",
+ "'empty-sequence'",
+ "'encoding'",
+ "'end'",
+ "'entire'",
+ "'eq'",
+ "'every'",
+ "'exactly'",
+ "'except'",
+ "'exit'",
+ "'external'",
+ "'first'",
+ "'following'",
+ "'following-sibling'",
+ "'for'",
+ "'foreach'",
+ "'foreign'",
+ "'from'",
+ "'ft-option'",
+ "'ftand'",
+ "'ftnot'",
+ "'ftor'",
+ "'function'",
+ "'ge'",
+ "'greatest'",
+ "'group'",
+ "'grouping-separator'",
+ "'gt'",
+ "'idiv'",
+ "'if'",
+ "'import'",
+ "'in'",
+ "'index'",
+ "'infinity'",
+ "'inherit'",
+ "'insensitive'",
+ "'insert'",
+ "'instance'",
+ "'integrity'",
+ "'intersect'",
+ "'into'",
+ "'is'",
+ "'item'",
+ "'json'",
+ "'json-item'",
+ "'key'",
+ "'language'",
+ "'last'",
+ "'lax'",
+ "'le'",
+ "'least'",
+ "'let'",
+ "'levels'",
+ "'loop'",
+ "'lowercase'",
+ "'lt'",
+ "'minus-sign'",
+ "'mod'",
+ "'modify'",
+ "'module'",
+ "'most'",
+ "'namespace'",
+ "'namespace-node'",
+ "'ne'",
+ "'next'",
+ "'no'",
+ "'no-inherit'",
+ "'no-preserve'",
+ "'node'",
+ "'nodes'",
+ "'not'",
+ "'object'",
+ "'occurs'",
+ "'of'",
+ "'on'",
+ "'only'",
+ "'option'",
+ "'or'",
+ "'order'",
+ "'ordered'",
+ "'ordering'",
+ "'paragraph'",
+ "'paragraphs'",
+ "'parent'",
+ "'pattern-separator'",
+ "'per-mille'",
+ "'percent'",
+ "'phrase'",
+ "'position'",
+ "'preceding'",
+ "'preceding-sibling'",
+ "'preserve'",
+ "'previous'",
+ "'processing-instruction'",
+ "'relationship'",
+ "'rename'",
+ "'replace'",
+ "'return'",
+ "'returning'",
+ "'revalidation'",
+ "'same'",
+ "'satisfies'",
+ "'schema'",
+ "'schema-attribute'",
+ "'schema-element'",
+ "'score'",
+ "'self'",
+ "'sensitive'",
+ "'sentence'",
+ "'sentences'",
+ "'skip'",
+ "'sliding'",
+ "'some'",
+ "'stable'",
+ "'start'",
+ "'stemming'",
+ "'stop'",
+ "'strict'",
+ "'strip'",
+ "'structured-item'",
+ "'switch'",
+ "'text'",
+ "'then'",
+ "'thesaurus'",
+ "'times'",
+ "'to'",
+ "'treat'",
+ "'try'",
+ "'tumbling'",
+ "'type'",
+ "'typeswitch'",
+ "'union'",
+ "'unique'",
+ "'unordered'",
+ "'updating'",
+ "'uppercase'",
+ "'using'",
+ "'validate'",
+ "'value'",
+ "'variable'",
+ "'version'",
+ "'weight'",
+ "'when'",
+ "'where'",
+ "'while'",
+ "'wildcards'",
+ "'window'",
+ "'with'",
+ "'without'",
+ "'word'",
+ "'words'",
+ "'xquery'",
+ "'zero-digit'",
+ "'{'",
+ "'{{'",
+ "'|'",
+ "'}'",
+ "'}}'"
+];
+
+},{}],"/node_modules/xqlint/lib/lexers/XQueryTokenizer.js":[function(_dereq_,module,exports){
+ var XQueryTokenizer = exports.XQueryTokenizer = function XQueryTokenizer(string, parsingEventHandler)
+ {
+ init(string, parsingEventHandler);
+ var self = this;
+
+ this.ParseException = function(b, e, s, o, x)
+ {
+ var
+ begin = b,
+ end = e,
+ state = s,
+ offending = o,
+ expected = x;
+
+ this.getBegin = function() {return begin;};
+ this.getEnd = function() {return end;};
+ this.getState = function() {return state;};
+ this.getExpected = function() {return expected;};
+ this.getOffending = function() {return offending;};
+
+ this.getMessage = function()
+ {
+ return offending < 0 ? "lexical analysis failed" : "syntax error";
+ };
+ };
+
+ function init(string, parsingEventHandler)
+ {
+ eventHandler = parsingEventHandler;
+ input = string;
+ size = string.length;
+ reset(0, 0, 0);
+ }
+
+ this.getInput = function()
+ {
+ return input;
+ };
+
+ function reset(l, b, e)
+ {
+ b0 = b; e0 = b;
+ l1 = l; b1 = b; e1 = e;
+ end = e;
+ eventHandler.reset(input);
+ }
+
+ this.getOffendingToken = function(e)
+ {
+ var o = e.getOffending();
+ return o >= 0 ? XQueryTokenizer.TOKEN[o] : null;
+ };
+
+ this.getExpectedTokenSet = function(e)
+ {
+ var expected;
+ if (e.getExpected() < 0)
+ {
+ expected = XQueryTokenizer.getTokenSet(- e.getState());
+ }
+ else
+ {
+ expected = [XQueryTokenizer.TOKEN[e.getExpected()]];
+ }
+ return expected;
+ };
+
+ this.getErrorMessage = function(e)
+ {
+ var tokenSet = this.getExpectedTokenSet(e);
+ var found = this.getOffendingToken(e);
+ var prefix = input.substring(0, e.getBegin());
+ var lines = prefix.split("\n");
+ var line = lines.length;
+ var column = lines[line - 1].length + 1;
+ var size = e.getEnd() - e.getBegin();
+ return e.getMessage()
+ + (found == null ? "" : ", found " + found)
+ + "\nwhile expecting "
+ + (tokenSet.length == 1 ? tokenSet[0] : ("[" + tokenSet.join(", ") + "]"))
+ + "\n"
+ + (size == 0 || found != null ? "" : "after successfully scanning " + size + " characters beginning ")
+ + "at line " + line + ", column " + column + ":\n..."
+ + input.substring(e.getBegin(), Math.min(input.length, e.getBegin() + 64))
+ + "...";
+ };
+
+ this.parse_start = function()
+ {
+ eventHandler.startNonterminal("start", e0);
+ lookahead1W(14); // ModuleDecl | Annotation | OptionDecl | Operator | Variable | Tag | AttrTest |
+ switch (l1)
+ {
+ case 55: // '<![CDATA['
+ shift(55); // '<![CDATA['
+ break;
+ case 54: // '<!--'
+ shift(54); // '<!--'
+ break;
+ case 56: // '<?'
+ shift(56); // '<?'
+ break;
+ case 40: // '(#'
+ shift(40); // '(#'
+ break;
+ case 42: // '(:~'
+ shift(42); // '(:~'
+ break;
+ case 41: // '(:'
+ shift(41); // '(:'
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ case 274: // '}'
+ shift(274); // '}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ case 39: // '('
+ shift(39); // '('
+ break;
+ case 43: // ')'
+ shift(43); // ')'
+ break;
+ case 49: // '/'
+ shift(49); // '/'
+ break;
+ case 62: // '['
+ shift(62); // '['
+ break;
+ case 63: // ']'
+ shift(63); // ']'
+ break;
+ case 46: // ','
+ shift(46); // ','
+ break;
+ case 48: // '.'
+ shift(48); // '.'
+ break;
+ case 53: // ';'
+ shift(53); // ';'
+ break;
+ case 51: // ':'
+ shift(51); // ':'
+ break;
+ case 34: // '!'
+ shift(34); // '!'
+ break;
+ case 273: // '|'
+ shift(273); // '|'
+ break;
+ case 2: // Annotation
+ shift(2); // Annotation
+ break;
+ case 1: // ModuleDecl
+ shift(1); // ModuleDecl
+ break;
+ case 3: // OptionDecl
+ shift(3); // OptionDecl
+ break;
+ case 12: // AttrTest
+ shift(12); // AttrTest
+ break;
+ case 13: // Wildcard
+ shift(13); // Wildcard
+ break;
+ case 15: // IntegerLiteral
+ shift(15); // IntegerLiteral
+ break;
+ case 16: // DecimalLiteral
+ shift(16); // DecimalLiteral
+ break;
+ case 17: // DoubleLiteral
+ shift(17); // DoubleLiteral
+ break;
+ case 5: // Variable
+ shift(5); // Variable
+ break;
+ case 6: // Tag
+ shift(6); // Tag
+ break;
+ case 4: // Operator
+ shift(4); // Operator
+ break;
+ case 33: // EOF
+ shift(33); // EOF
+ break;
+ default:
+ parse_EQName();
+ }
+ eventHandler.endNonterminal("start", e0);
+ };
+
+ this.parse_StartTag = function()
+ {
+ eventHandler.startNonterminal("StartTag", e0);
+ lookahead1W(8); // QName | S^WS | EOF | '"' | "'" | '/>' | '=' | '>'
+ switch (l1)
+ {
+ case 58: // '>'
+ shift(58); // '>'
+ break;
+ case 50: // '/>'
+ shift(50); // '/>'
+ break;
+ case 27: // QName
+ shift(27); // QName
+ break;
+ case 57: // '='
+ shift(57); // '='
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("StartTag", e0);
+ };
+
+ this.parse_TagContent = function()
+ {
+ eventHandler.startNonterminal("TagContent", e0);
+ lookahead1(11); // Tag | EndTag | PredefinedEntityRef | ElementContentChar | CharRef | EOF |
+ switch (l1)
+ {
+ case 23: // ElementContentChar
+ shift(23); // ElementContentChar
+ break;
+ case 6: // Tag
+ shift(6); // Tag
+ break;
+ case 7: // EndTag
+ shift(7); // EndTag
+ break;
+ case 55: // '<![CDATA['
+ shift(55); // '<![CDATA['
+ break;
+ case 54: // '<!--'
+ shift(54); // '<!--'
+ break;
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 272: // '{{'
+ shift(272); // '{{'
+ break;
+ case 275: // '}}'
+ shift(275); // '}}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("TagContent", e0);
+ };
+
+ this.parse_AposAttr = function()
+ {
+ eventHandler.startNonterminal("AposAttr", e0);
+ lookahead1(10); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | EOF | "'" |
+ switch (l1)
+ {
+ case 20: // EscapeApos
+ shift(20); // EscapeApos
+ break;
+ case 25: // AposAttrContentChar
+ shift(25); // AposAttrContentChar
+ break;
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 272: // '{{'
+ shift(272); // '{{'
+ break;
+ case 275: // '}}'
+ shift(275); // '}}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("AposAttr", e0);
+ };
+
+ this.parse_QuotAttr = function()
+ {
+ eventHandler.startNonterminal("QuotAttr", e0);
+ lookahead1(9); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | EOF | '"' |
+ switch (l1)
+ {
+ case 19: // EscapeQuot
+ shift(19); // EscapeQuot
+ break;
+ case 24: // QuotAttrContentChar
+ shift(24); // QuotAttrContentChar
+ break;
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 272: // '{{'
+ shift(272); // '{{'
+ break;
+ case 275: // '}}'
+ shift(275); // '}}'
+ break;
+ case 271: // '{'
+ shift(271); // '{'
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("QuotAttr", e0);
+ };
+
+ this.parse_CData = function()
+ {
+ eventHandler.startNonterminal("CData", e0);
+ lookahead1(1); // CDataSectionContents | EOF | ']]>'
+ switch (l1)
+ {
+ case 11: // CDataSectionContents
+ shift(11); // CDataSectionContents
+ break;
+ case 64: // ']]>'
+ shift(64); // ']]>'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("CData", e0);
+ };
+
+ this.parse_XMLComment = function()
+ {
+ eventHandler.startNonterminal("XMLComment", e0);
+ lookahead1(0); // DirCommentContents | EOF | '-->'
+ switch (l1)
+ {
+ case 9: // DirCommentContents
+ shift(9); // DirCommentContents
+ break;
+ case 47: // '-->'
+ shift(47); // '-->'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("XMLComment", e0);
+ };
+
+ this.parse_PI = function()
+ {
+ eventHandler.startNonterminal("PI", e0);
+ lookahead1(3); // DirPIContents | EOF | '?' | '?>'
+ switch (l1)
+ {
+ case 10: // DirPIContents
+ shift(10); // DirPIContents
+ break;
+ case 59: // '?'
+ shift(59); // '?'
+ break;
+ case 60: // '?>'
+ shift(60); // '?>'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("PI", e0);
+ };
+
+ this.parse_Pragma = function()
+ {
+ eventHandler.startNonterminal("Pragma", e0);
+ lookahead1(2); // PragmaContents | EOF | '#' | '#)'
+ switch (l1)
+ {
+ case 8: // PragmaContents
+ shift(8); // PragmaContents
+ break;
+ case 36: // '#'
+ shift(36); // '#'
+ break;
+ case 37: // '#)'
+ shift(37); // '#)'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("Pragma", e0);
+ };
+
+ this.parse_Comment = function()
+ {
+ eventHandler.startNonterminal("Comment", e0);
+ lookahead1(4); // CommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 52: // ':)'
+ shift(52); // ':)'
+ break;
+ case 41: // '(:'
+ shift(41); // '(:'
+ break;
+ case 30: // CommentContents
+ shift(30); // CommentContents
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("Comment", e0);
+ };
+
+ this.parse_CommentDoc = function()
+ {
+ eventHandler.startNonterminal("CommentDoc", e0);
+ lookahead1(5); // DocTag | DocCommentContents | EOF | '(:' | ':)'
+ switch (l1)
+ {
+ case 31: // DocTag
+ shift(31); // DocTag
+ break;
+ case 32: // DocCommentContents
+ shift(32); // DocCommentContents
+ break;
+ case 52: // ':)'
+ shift(52); // ':)'
+ break;
+ case 41: // '(:'
+ shift(41); // '(:'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("CommentDoc", e0);
+ };
+
+ this.parse_QuotString = function()
+ {
+ eventHandler.startNonterminal("QuotString", e0);
+ lookahead1(6); // PredefinedEntityRef | EscapeQuot | QuotChar | CharRef | EOF | '"'
+ switch (l1)
+ {
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 19: // EscapeQuot
+ shift(19); // EscapeQuot
+ break;
+ case 21: // QuotChar
+ shift(21); // QuotChar
+ break;
+ case 35: // '"'
+ shift(35); // '"'
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("QuotString", e0);
+ };
+
+ this.parse_AposString = function()
+ {
+ eventHandler.startNonterminal("AposString", e0);
+ lookahead1(7); // PredefinedEntityRef | EscapeApos | AposChar | CharRef | EOF | "'"
+ switch (l1)
+ {
+ case 18: // PredefinedEntityRef
+ shift(18); // PredefinedEntityRef
+ break;
+ case 29: // CharRef
+ shift(29); // CharRef
+ break;
+ case 20: // EscapeApos
+ shift(20); // EscapeApos
+ break;
+ case 22: // AposChar
+ shift(22); // AposChar
+ break;
+ case 38: // "'"
+ shift(38); // "'"
+ break;
+ default:
+ shift(33); // EOF
+ }
+ eventHandler.endNonterminal("AposString", e0);
+ };
+
+ this.parse_Prefix = function()
+ {
+ eventHandler.startNonterminal("Prefix", e0);
+ lookahead1W(13); // NCName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_NCName();
+ eventHandler.endNonterminal("Prefix", e0);
+ };
+
+ this.parse__EQName = function()
+ {
+ eventHandler.startNonterminal("_EQName", e0);
+ lookahead1W(12); // EQName^Token | S^WS | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ whitespace();
+ parse_EQName();
+ eventHandler.endNonterminal("_EQName", e0);
+ };
+
+ function parse_EQName()
+ {
+ eventHandler.startNonterminal("EQName", e0);
+ switch (l1)
+ {
+ case 77: // 'attribute'
+ shift(77); // 'attribute'
+ break;
+ case 91: // 'comment'
+ shift(91); // 'comment'
+ break;
+ case 115: // 'document-node'
+ shift(115); // 'document-node'
+ break;
+ case 116: // 'element'
+ shift(116); // 'element'
+ break;
+ case 119: // 'empty-sequence'
+ shift(119); // 'empty-sequence'
+ break;
+ case 140: // 'function'
+ shift(140); // 'function'
+ break;
+ case 147: // 'if'
+ shift(147); // 'if'
+ break;
+ case 160: // 'item'
+ shift(160); // 'item'
+ break;
+ case 180: // 'namespace-node'
+ shift(180); // 'namespace-node'
+ break;
+ case 186: // 'node'
+ shift(186); // 'node'
+ break;
+ case 211: // 'processing-instruction'
+ shift(211); // 'processing-instruction'
+ break;
+ case 221: // 'schema-attribute'
+ shift(221); // 'schema-attribute'
+ break;
+ case 222: // 'schema-element'
+ shift(222); // 'schema-element'
+ break;
+ case 238: // 'switch'
+ shift(238); // 'switch'
+ break;
+ case 239: // 'text'
+ shift(239); // 'text'
+ break;
+ case 248: // 'typeswitch'
+ shift(248); // 'typeswitch'
+ break;
+ default:
+ parse_FunctionName();
+ }
+ eventHandler.endNonterminal("EQName", e0);
+ }
+
+ function parse_FunctionName()
+ {
+ eventHandler.startNonterminal("FunctionName", e0);
+ switch (l1)
+ {
+ case 14: // EQName^Token
+ shift(14); // EQName^Token
+ break;
+ case 65: // 'after'
+ shift(65); // 'after'
+ break;
+ case 68: // 'ancestor'
+ shift(68); // 'ancestor'
+ break;
+ case 69: // 'ancestor-or-self'
+ shift(69); // 'ancestor-or-self'
+ break;
+ case 70: // 'and'
+ shift(70); // 'and'
+ break;
+ case 74: // 'as'
+ shift(74); // 'as'
+ break;
+ case 75: // 'ascending'
+ shift(75); // 'ascending'
+ break;
+ case 79: // 'before'
+ shift(79); // 'before'
+ break;
+ case 83: // 'case'
+ shift(83); // 'case'
+ break;
+ case 84: // 'cast'
+ shift(84); // 'cast'
+ break;
+ case 85: // 'castable'
+ shift(85); // 'castable'
+ break;
+ case 88: // 'child'
+ shift(88); // 'child'
+ break;
+ case 89: // 'collation'
+ shift(89); // 'collation'
+ break;
+ case 98: // 'copy'
+ shift(98); // 'copy'
+ break;
+ case 100: // 'count'
+ shift(100); // 'count'
+ break;
+ case 103: // 'declare'
+ shift(103); // 'declare'
+ break;
+ case 104: // 'default'
+ shift(104); // 'default'
+ break;
+ case 105: // 'delete'
+ shift(105); // 'delete'
+ break;
+ case 106: // 'descendant'
+ shift(106); // 'descendant'
+ break;
+ case 107: // 'descendant-or-self'
+ shift(107); // 'descendant-or-self'
+ break;
+ case 108: // 'descending'
+ shift(108); // 'descending'
+ break;
+ case 113: // 'div'
+ shift(113); // 'div'
+ break;
+ case 114: // 'document'
+ shift(114); // 'document'
+ break;
+ case 117: // 'else'
+ shift(117); // 'else'
+ break;
+ case 118: // 'empty'
+ shift(118); // 'empty'
+ break;
+ case 121: // 'end'
+ shift(121); // 'end'
+ break;
+ case 123: // 'eq'
+ shift(123); // 'eq'
+ break;
+ case 124: // 'every'
+ shift(124); // 'every'
+ break;
+ case 126: // 'except'
+ shift(126); // 'except'
+ break;
+ case 129: // 'first'
+ shift(129); // 'first'
+ break;
+ case 130: // 'following'
+ shift(130); // 'following'
+ break;
+ case 131: // 'following-sibling'
+ shift(131); // 'following-sibling'
+ break;
+ case 132: // 'for'
+ shift(132); // 'for'
+ break;
+ case 141: // 'ge'
+ shift(141); // 'ge'
+ break;
+ case 143: // 'group'
+ shift(143); // 'group'
+ break;
+ case 145: // 'gt'
+ shift(145); // 'gt'
+ break;
+ case 146: // 'idiv'
+ shift(146); // 'idiv'
+ break;
+ case 148: // 'import'
+ shift(148); // 'import'
+ break;
+ case 154: // 'insert'
+ shift(154); // 'insert'
+ break;
+ case 155: // 'instance'
+ shift(155); // 'instance'
+ break;
+ case 157: // 'intersect'
+ shift(157); // 'intersect'
+ break;
+ case 158: // 'into'
+ shift(158); // 'into'
+ break;
+ case 159: // 'is'
+ shift(159); // 'is'
+ break;
+ case 165: // 'last'
+ shift(165); // 'last'
+ break;
+ case 167: // 'le'
+ shift(167); // 'le'
+ break;
+ case 169: // 'let'
+ shift(169); // 'let'
+ break;
+ case 173: // 'lt'
+ shift(173); // 'lt'
+ break;
+ case 175: // 'mod'
+ shift(175); // 'mod'
+ break;
+ case 176: // 'modify'
+ shift(176); // 'modify'
+ break;
+ case 177: // 'module'
+ shift(177); // 'module'
+ break;
+ case 179: // 'namespace'
+ shift(179); // 'namespace'
+ break;
+ case 181: // 'ne'
+ shift(181); // 'ne'
+ break;
+ case 193: // 'only'
+ shift(193); // 'only'
+ break;
+ case 195: // 'or'
+ shift(195); // 'or'
+ break;
+ case 196: // 'order'
+ shift(196); // 'order'
+ break;
+ case 197: // 'ordered'
+ shift(197); // 'ordered'
+ break;
+ case 201: // 'parent'
+ shift(201); // 'parent'
+ break;
+ case 207: // 'preceding'
+ shift(207); // 'preceding'
+ break;
+ case 208: // 'preceding-sibling'
+ shift(208); // 'preceding-sibling'
+ break;
+ case 213: // 'rename'
+ shift(213); // 'rename'
+ break;
+ case 214: // 'replace'
+ shift(214); // 'replace'
+ break;
+ case 215: // 'return'
+ shift(215); // 'return'
+ break;
+ case 219: // 'satisfies'
+ shift(219); // 'satisfies'
+ break;
+ case 224: // 'self'
+ shift(224); // 'self'
+ break;
+ case 230: // 'some'
+ shift(230); // 'some'
+ break;
+ case 231: // 'stable'
+ shift(231); // 'stable'
+ break;
+ case 232: // 'start'
+ shift(232); // 'start'
+ break;
+ case 243: // 'to'
+ shift(243); // 'to'
+ break;
+ case 244: // 'treat'
+ shift(244); // 'treat'
+ break;
+ case 245: // 'try'
+ shift(245); // 'try'
+ break;
+ case 249: // 'union'
+ shift(249); // 'union'
+ break;
+ case 251: // 'unordered'
+ shift(251); // 'unordered'
+ break;
+ case 255: // 'validate'
+ shift(255); // 'validate'
+ break;
+ case 261: // 'where'
+ shift(261); // 'where'
+ break;
+ case 265: // 'with'
+ shift(265); // 'with'
+ break;
+ case 269: // 'xquery'
+ shift(269); // 'xquery'
+ break;
+ case 67: // 'allowing'
+ shift(67); // 'allowing'
+ break;
+ case 76: // 'at'
+ shift(76); // 'at'
+ break;
+ case 78: // 'base-uri'
+ shift(78); // 'base-uri'
+ break;
+ case 80: // 'boundary-space'
+ shift(80); // 'boundary-space'
+ break;
+ case 81: // 'break'
+ shift(81); // 'break'
+ break;
+ case 86: // 'catch'
+ shift(86); // 'catch'
+ break;
+ case 93: // 'construction'
+ shift(93); // 'construction'
+ break;
+ case 96: // 'context'
+ shift(96); // 'context'
+ break;
+ case 97: // 'continue'
+ shift(97); // 'continue'
+ break;
+ case 99: // 'copy-namespaces'
+ shift(99); // 'copy-namespaces'
+ break;
+ case 101: // 'decimal-format'
+ shift(101); // 'decimal-format'
+ break;
+ case 120: // 'encoding'
+ shift(120); // 'encoding'
+ break;
+ case 127: // 'exit'
+ shift(127); // 'exit'
+ break;
+ case 128: // 'external'
+ shift(128); // 'external'
+ break;
+ case 136: // 'ft-option'
+ shift(136); // 'ft-option'
+ break;
+ case 149: // 'in'
+ shift(149); // 'in'
+ break;
+ case 150: // 'index'
+ shift(150); // 'index'
+ break;
+ case 156: // 'integrity'
+ shift(156); // 'integrity'
+ break;
+ case 166: // 'lax'
+ shift(166); // 'lax'
+ break;
+ case 187: // 'nodes'
+ shift(187); // 'nodes'
+ break;
+ case 194: // 'option'
+ shift(194); // 'option'
+ break;
+ case 198: // 'ordering'
+ shift(198); // 'ordering'
+ break;
+ case 217: // 'revalidation'
+ shift(217); // 'revalidation'
+ break;
+ case 220: // 'schema'
+ shift(220); // 'schema'
+ break;
+ case 223: // 'score'
+ shift(223); // 'score'
+ break;
+ case 229: // 'sliding'
+ shift(229); // 'sliding'
+ break;
+ case 235: // 'strict'
+ shift(235); // 'strict'
+ break;
+ case 246: // 'tumbling'
+ shift(246); // 'tumbling'
+ break;
+ case 247: // 'type'
+ shift(247); // 'type'
+ break;
+ case 252: // 'updating'
+ shift(252); // 'updating'
+ break;
+ case 256: // 'value'
+ shift(256); // 'value'
+ break;
+ case 257: // 'variable'
+ shift(257); // 'variable'
+ break;
+ case 258: // 'version'
+ shift(258); // 'version'
+ break;
+ case 262: // 'while'
+ shift(262); // 'while'
+ break;
+ case 92: // 'constraint'
+ shift(92); // 'constraint'
+ break;
+ case 171: // 'loop'
+ shift(171); // 'loop'
+ break;
+ default:
+ shift(216); // 'returning'
+ }
+ eventHandler.endNonterminal("FunctionName", e0);
+ }
+
+ function parse_NCName()
+ {
+ eventHandler.startNonterminal("NCName", e0);
+ switch (l1)
+ {
+ case 26: // NCName^Token
+ shift(26); // NCName^Token
+ break;
+ case 65: // 'after'
+ shift(65); // 'after'
+ break;
+ case 70: // 'and'
+ shift(70); // 'and'
+ break;
+ case 74: // 'as'
+ shift(74); // 'as'
+ break;
+ case 75: // 'ascending'
+ shift(75); // 'ascending'
+ break;
+ case 79: // 'before'
+ shift(79); // 'before'
+ break;
+ case 83: // 'case'
+ shift(83); // 'case'
+ break;
+ case 84: // 'cast'
+ shift(84); // 'cast'
+ break;
+ case 85: // 'castable'
+ shift(85); // 'castable'
+ break;
+ case 89: // 'collation'
+ shift(89); // 'collation'
+ break;
+ case 100: // 'count'
+ shift(100); // 'count'
+ break;
+ case 104: // 'default'
+ shift(104); // 'default'
+ break;
+ case 108: // 'descending'
+ shift(108); // 'descending'
+ break;
+ case 113: // 'div'
+ shift(113); // 'div'
+ break;
+ case 117: // 'else'
+ shift(117); // 'else'
+ break;
+ case 118: // 'empty'
+ shift(118); // 'empty'
+ break;
+ case 121: // 'end'
+ shift(121); // 'end'
+ break;
+ case 123: // 'eq'
+ shift(123); // 'eq'
+ break;
+ case 126: // 'except'
+ shift(126); // 'except'
+ break;
+ case 132: // 'for'
+ shift(132); // 'for'
+ break;
+ case 141: // 'ge'
+ shift(141); // 'ge'
+ break;
+ case 143: // 'group'
+ shift(143); // 'group'
+ break;
+ case 145: // 'gt'
+ shift(145); // 'gt'
+ break;
+ case 146: // 'idiv'
+ shift(146); // 'idiv'
+ break;
+ case 155: // 'instance'
+ shift(155); // 'instance'
+ break;
+ case 157: // 'intersect'
+ shift(157); // 'intersect'
+ break;
+ case 158: // 'into'
+ shift(158); // 'into'
+ break;
+ case 159: // 'is'
+ shift(159); // 'is'
+ break;
+ case 167: // 'le'
+ shift(167); // 'le'
+ break;
+ case 169: // 'let'
+ shift(169); // 'let'
+ break;
+ case 173: // 'lt'
+ shift(173); // 'lt'
+ break;
+ case 175: // 'mod'
+ shift(175); // 'mod'
+ break;
+ case 176: // 'modify'
+ shift(176); // 'modify'
+ break;
+ case 181: // 'ne'
+ shift(181); // 'ne'
+ break;
+ case 193: // 'only'
+ shift(193); // 'only'
+ break;
+ case 195: // 'or'
+ shift(195); // 'or'
+ break;
+ case 196: // 'order'
+ shift(196); // 'order'
+ break;
+ case 215: // 'return'
+ shift(215); // 'return'
+ break;
+ case 219: // 'satisfies'
+ shift(219); // 'satisfies'
+ break;
+ case 231: // 'stable'
+ shift(231); // 'stable'
+ break;
+ case 232: // 'start'
+ shift(232); // 'start'
+ break;
+ case 243: // 'to'
+ shift(243); // 'to'
+ break;
+ case 244: // 'treat'
+ shift(244); // 'treat'
+ break;
+ case 249: // 'union'
+ shift(249); // 'union'
+ break;
+ case 261: // 'where'
+ shift(261); // 'where'
+ break;
+ case 265: // 'with'
+ shift(265); // 'with'
+ break;
+ case 68: // 'ancestor'
+ shift(68); // 'ancestor'
+ break;
+ case 69: // 'ancestor-or-self'
+ shift(69); // 'ancestor-or-self'
+ break;
+ case 77: // 'attribute'
+ shift(77); // 'attribute'
+ break;
+ case 88: // 'child'
+ shift(88); // 'child'
+ break;
+ case 91: // 'comment'
+ shift(91); // 'comment'
+ break;
+ case 98: // 'copy'
+ shift(98); // 'copy'
+ break;
+ case 103: // 'declare'
+ shift(103); // 'declare'
+ break;
+ case 105: // 'delete'
+ shift(105); // 'delete'
+ break;
+ case 106: // 'descendant'
+ shift(106); // 'descendant'
+ break;
+ case 107: // 'descendant-or-self'
+ shift(107); // 'descendant-or-self'
+ break;
+ case 114: // 'document'
+ shift(114); // 'document'
+ break;
+ case 115: // 'document-node'
+ shift(115); // 'document-node'
+ break;
+ case 116: // 'element'
+ shift(116); // 'element'
+ break;
+ case 119: // 'empty-sequence'
+ shift(119); // 'empty-sequence'
+ break;
+ case 124: // 'every'
+ shift(124); // 'every'
+ break;
+ case 129: // 'first'
+ shift(129); // 'first'
+ break;
+ case 130: // 'following'
+ shift(130); // 'following'
+ break;
+ case 131: // 'following-sibling'
+ shift(131); // 'following-sibling'
+ break;
+ case 140: // 'function'
+ shift(140); // 'function'
+ break;
+ case 147: // 'if'
+ shift(147); // 'if'
+ break;
+ case 148: // 'import'
+ shift(148); // 'import'
+ break;
+ case 154: // 'insert'
+ shift(154); // 'insert'
+ break;
+ case 160: // 'item'
+ shift(160); // 'item'
+ break;
+ case 165: // 'last'
+ shift(165); // 'last'
+ break;
+ case 177: // 'module'
+ shift(177); // 'module'
+ break;
+ case 179: // 'namespace'
+ shift(179); // 'namespace'
+ break;
+ case 180: // 'namespace-node'
+ shift(180); // 'namespace-node'
+ break;
+ case 186: // 'node'
+ shift(186); // 'node'
+ break;
+ case 197: // 'ordered'
+ shift(197); // 'ordered'
+ break;
+ case 201: // 'parent'
+ shift(201); // 'parent'
+ break;
+ case 207: // 'preceding'
+ shift(207); // 'preceding'
+ break;
+ case 208: // 'preceding-sibling'
+ shift(208); // 'preceding-sibling'
+ break;
+ case 211: // 'processing-instruction'
+ shift(211); // 'processing-instruction'
+ break;
+ case 213: // 'rename'
+ shift(213); // 'rename'
+ break;
+ case 214: // 'replace'
+ shift(214); // 'replace'
+ break;
+ case 221: // 'schema-attribute'
+ shift(221); // 'schema-attribute'
+ break;
+ case 222: // 'schema-element'
+ shift(222); // 'schema-element'
+ break;
+ case 224: // 'self'
+ shift(224); // 'self'
+ break;
+ case 230: // 'some'
+ shift(230); // 'some'
+ break;
+ case 238: // 'switch'
+ shift(238); // 'switch'
+ break;
+ case 239: // 'text'
+ shift(239); // 'text'
+ break;
+ case 245: // 'try'
+ shift(245); // 'try'
+ break;
+ case 248: // 'typeswitch'
+ shift(248); // 'typeswitch'
+ break;
+ case 251: // 'unordered'
+ shift(251); // 'unordered'
+ break;
+ case 255: // 'validate'
+ shift(255); // 'validate'
+ break;
+ case 257: // 'variable'
+ shift(257); // 'variable'
+ break;
+ case 269: // 'xquery'
+ shift(269); // 'xquery'
+ break;
+ case 67: // 'allowing'
+ shift(67); // 'allowing'
+ break;
+ case 76: // 'at'
+ shift(76); // 'at'
+ break;
+ case 78: // 'base-uri'
+ shift(78); // 'base-uri'
+ break;
+ case 80: // 'boundary-space'
+ shift(80); // 'boundary-space'
+ break;
+ case 81: // 'break'
+ shift(81); // 'break'
+ break;
+ case 86: // 'catch'
+ shift(86); // 'catch'
+ break;
+ case 93: // 'construction'
+ shift(93); // 'construction'
+ break;
+ case 96: // 'context'
+ shift(96); // 'context'
+ break;
+ case 97: // 'continue'
+ shift(97); // 'continue'
+ break;
+ case 99: // 'copy-namespaces'
+ shift(99); // 'copy-namespaces'
+ break;
+ case 101: // 'decimal-format'
+ shift(101); // 'decimal-format'
+ break;
+ case 120: // 'encoding'
+ shift(120); // 'encoding'
+ break;
+ case 127: // 'exit'
+ shift(127); // 'exit'
+ break;
+ case 128: // 'external'
+ shift(128); // 'external'
+ break;
+ case 136: // 'ft-option'
+ shift(136); // 'ft-option'
+ break;
+ case 149: // 'in'
+ shift(149); // 'in'
+ break;
+ case 150: // 'index'
+ shift(150); // 'index'
+ break;
+ case 156: // 'integrity'
+ shift(156); // 'integrity'
+ break;
+ case 166: // 'lax'
+ shift(166); // 'lax'
+ break;
+ case 187: // 'nodes'
+ shift(187); // 'nodes'
+ break;
+ case 194: // 'option'
+ shift(194); // 'option'
+ break;
+ case 198: // 'ordering'
+ shift(198); // 'ordering'
+ break;
+ case 217: // 'revalidation'
+ shift(217); // 'revalidation'
+ break;
+ case 220: // 'schema'
+ shift(220); // 'schema'
+ break;
+ case 223: // 'score'
+ shift(223); // 'score'
+ break;
+ case 229: // 'sliding'
+ shift(229); // 'sliding'
+ break;
+ case 235: // 'strict'
+ shift(235); // 'strict'
+ break;
+ case 246: // 'tumbling'
+ shift(246); // 'tumbling'
+ break;
+ case 247: // 'type'
+ shift(247); // 'type'
+ break;
+ case 252: // 'updating'
+ shift(252); // 'updating'
+ break;
+ case 256: // 'value'
+ shift(256); // 'value'
+ break;
+ case 258: // 'version'
+ shift(258); // 'version'
+ break;
+ case 262: // 'while'
+ shift(262); // 'while'
+ break;
+ case 92: // 'constraint'
+ shift(92); // 'constraint'
+ break;
+ case 171: // 'loop'
+ shift(171); // 'loop'
+ break;
+ default:
+ shift(216); // 'returning'
+ }
+ eventHandler.endNonterminal("NCName", e0);
+ }
+
+ function shift(t)
+ {
+ if (l1 == t)
+ {
+ whitespace();
+ eventHandler.terminal(XQueryTokenizer.TOKEN[l1], b1, e1 > size ? size : e1);
+ b0 = b1; e0 = e1; l1 = 0;
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function whitespace()
+ {
+ if (e0 != b1)
+ {
+ b0 = e0;
+ e0 = b1;
+ eventHandler.whitespace(b0, e0);
+ }
+ }
+
+ function matchW(set)
+ {
+ var code;
+ for (;;)
+ {
+ code = match(set);
+ if (code != 28) // S^WS
+ {
+ break;
+ }
+ }
+ return code;
+ }
+
+ function lookahead1W(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = matchW(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead1(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = match(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function error(b, e, s, l, t)
+ {
+ throw new self.ParseException(b, e, s, l, t);
+ }
+
+ var lk, b0, e0;
+ var l1, b1, e1;
+ var eventHandler;
+
+ var input;
+ var size;
+ var begin;
+ var end;
+
+ function match(tokenSetId)
+ {
+ var nonbmp = false;
+ begin = end;
+ var current = end;
+ var result = XQueryTokenizer.INITIAL[tokenSetId];
+ var state = 0;
+
+ for (var code = result & 4095; code != 0; )
+ {
+ var charclass;
+ var c0 = current < size ? input.charCodeAt(current) : 0;
+ ++current;
+ if (c0 < 0x80)
+ {
+ charclass = XQueryTokenizer.MAP0[c0];
+ }
+ else if (c0 < 0xd800)
+ {
+ var c1 = c0 >> 4;
+ charclass = XQueryTokenizer.MAP1[(c0 & 15) + XQueryTokenizer.MAP1[(c1 & 31) + XQueryTokenizer.MAP1[c1 >> 5]]];
+ }
+ else
+ {
+ if (c0 < 0xdc00)
+ {
+ var c1 = current < size ? input.charCodeAt(current) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000)
+ {
+ ++current;
+ c0 = ((c0 & 0x3ff) << 10) + (c1 & 0x3ff) + 0x10000;
+ nonbmp = true;
+ }
+ }
+ var lo = 0, hi = 5;
+ for (var m = 3; ; m = (hi + lo) >> 1)
+ {
+ if (XQueryTokenizer.MAP2[m] > c0) hi = m - 1;
+ else if (XQueryTokenizer.MAP2[6 + m] < c0) lo = m + 1;
+ else {charclass = XQueryTokenizer.MAP2[12 + m]; break;}
+ if (lo > hi) {charclass = 0; break;}
+ }
+ }
+
+ state = code;
+ var i0 = (charclass << 12) + code - 1;
+ code = XQueryTokenizer.TRANSITION[(i0 & 15) + XQueryTokenizer.TRANSITION[i0 >> 4]];
+
+ if (code > 4095)
+ {
+ result = code;
+ code &= 4095;
+ end = current;
+ }
+ }
+
+ result >>= 12;
+ if (result == 0)
+ {
+ end = current - 1;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ return error(begin, end, state, -1, -1);
+ }
+
+ if (nonbmp)
+ {
+ for (var i = result >> 9; i > 0; --i)
+ {
+ --end;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ }
+ }
+ else
+ {
+ end -= result >> 9;
+ }
+
+ return (result & 511) - 1;
+ }
+}
+
+XQueryTokenizer.getTokenSet = function(tokenSetId)
+{
+ var set = [];
+ var s = tokenSetId < 0 ? - tokenSetId : INITIAL[tokenSetId] & 4095;
+ for (var i = 0; i < 276; i += 32)
+ {
+ var j = i;
+ var i0 = (i >> 5) * 2062 + s - 1;
+ var i1 = i0 >> 2;
+ var i2 = i1 >> 2;
+ var f = XQueryTokenizer.EXPECTED[(i0 & 3) + XQueryTokenizer.EXPECTED[(i1 & 3) + XQueryTokenizer.EXPECTED[(i2 & 3) + XQueryTokenizer.EXPECTED[i2 >> 2]]]];
+ for ( ; f != 0; f >>>= 1, ++j)
+ {
+ if ((f & 1) != 0)
+ {
+ set.push(XQueryTokenizer.TOKEN[j]);
+ }
+ }
+ }
+ return set;
+};
+
+XQueryTokenizer.MAP0 =
+[ 66, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 35, 31, 35, 37, 38, 39, 40, 41, 42, 43, 44, 45, 31, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 31, 61, 62, 63, 64, 35
+];
+
+XQueryTokenizer.MAP1 =
+[ 108, 124, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 156, 181, 181, 181, 181, 181, 214, 215, 213, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 247, 261, 277, 293, 309, 347, 363, 379, 416, 416, 416, 408, 331, 323, 331, 323, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 433, 433, 433, 433, 433, 433, 433, 316, 331, 331, 331, 331, 331, 331, 331, 331, 394, 416, 416, 417, 415, 416, 416, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 416, 330, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 331, 416, 66, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 27, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 35, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 31, 33, 31, 31, 31, 31, 31, 31, 34, 35, 36, 35, 31, 35, 37, 38, 39, 40, 41, 42, 43, 44, 45, 31, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 31, 61, 62, 63, 64, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 31, 31, 35, 35, 35, 35, 35, 35, 35, 65, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65, 65
+];
+
+XQueryTokenizer.MAP2 =
+[ 57344, 63744, 64976, 65008, 65536, 983040, 63743, 64975, 65007, 65533, 983039, 1114111, 35, 31, 35, 31, 31, 35
+];
+
+XQueryTokenizer.INITIAL =
+[ 1, 2, 36867, 45060, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
+];
+
+XQueryTokenizer.TRANSITION =
+[ 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22908, 18836, 17152, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 17365, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 17470, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 18157, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 17848, 17880, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18023, 36545, 18621, 18039, 18056, 18072, 18117, 18143, 18173, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17687, 18805, 18421, 18437, 18101, 17393, 18489, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 18579, 21711, 17152, 19008, 19233, 20367, 19008, 28684, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 17365, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 17470, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 18157, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 17848, 17880, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18023, 36545, 18621, 18039, 18056, 18072, 18117, 18143, 18173, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17687, 18805, 18421, 18437, 18101, 17393, 18489, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 20116, 18836, 18637, 19008, 19233, 21267, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 18763, 18778, 18794, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 18821, 22923, 18906, 19008, 19233, 17431, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18937, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 19054, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 18953, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21843, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21696, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22429, 20131, 18720, 19008, 19233, 20367, 19008, 17173, 23559, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 18087, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 21242, 19111, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 19024, 18836, 18609, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 19081, 22444, 18987, 19008, 19233, 20367, 19008, 19065, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21992, 22007, 18987, 19008, 19233, 20367, 19008, 18690, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22414, 18836, 18987, 19008, 19233, 30651, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 19138, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 19280, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 19172, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21783, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 19218, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21651, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 19249, 19265, 19307, 18888, 27857, 30536, 24401, 31444, 23357, 18888, 19351, 18888, 18890, 27211, 19370, 27211, 27211, 19392, 24401, 31911, 24401, 24401, 25467, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 19440, 24401, 24401, 24401, 24401, 24036, 17994, 24060, 18888, 18888, 18888, 18890, 19468, 27211, 27211, 27211, 27211, 19484, 35367, 19520, 24401, 24401, 24401, 19628, 18888, 29855, 18888, 18888, 23086, 27211, 19538, 27211, 27211, 30756, 24012, 24401, 19560, 24401, 24401, 26750, 18888, 18888, 19327, 27855, 27211, 27211, 19580, 17590, 24017, 24401, 24401, 19600, 25665, 18888, 18888, 28518, 27211, 27212, 24016, 19620, 19868, 28435, 25722, 18889, 19644, 27211, 32888, 35852, 19868, 31018, 19694, 19376, 19717, 22215, 19735, 22098, 19751, 35203, 19776, 19797, 19817, 19840, 25783, 31738, 24135, 19701, 19856, 31015, 23516, 31008, 28311, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21768, 18836, 19307, 18888, 27857, 27904, 24401, 29183, 28015, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 19888, 24401, 24401, 24401, 24401, 22953, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 19440, 24401, 24401, 24401, 24401, 24036, 18881, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22399, 18836, 19918, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21666, 18836, 19307, 18888, 27857, 27525, 24401, 29183, 21467, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 19946, 24401, 24401, 24401, 24401, 32382, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 19998, 24401, 24401, 24401, 24401, 31500, 18467, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 20021, 24401, 24401, 24401, 24401, 24401, 34271, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 32926, 29908, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 20050, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 20101, 19039, 20191, 20412, 20903, 17569, 20309, 20872, 25633, 20623, 20505, 20218, 20242, 17189, 17208, 17281, 20355, 20265, 20306, 20328, 20383, 22490, 20796, 20619, 21354, 20654, 20410, 20956, 21232, 20765, 17421, 20535, 17192, 18127, 22459, 20312, 25531, 22470, 20309, 20428, 18964, 20466, 20491, 21342, 21070, 20521, 20682, 17714, 18326, 17543, 17559, 17585, 22497, 20559, 19504, 20279, 20575, 20290, 20475, 20604, 20639, 20226, 20670, 17661, 21190, 17703, 21176, 17730, 19494, 20698, 20711, 22480, 21046, 21116, 18971, 21130, 20727, 20755, 17675, 17753, 17832, 17590, 25518, 20394, 20781, 20831, 20202, 20847, 21401, 17292, 17934, 17979, 18549, 20863, 20588, 25542, 20888, 20919, 18072, 18117, 20935, 20972, 21032, 21062, 21086, 18239, 21102, 18563, 21146, 21162, 21206, 18351, 20949, 20902, 18340, 21222, 21258, 21283, 18360, 20249, 17405, 21295, 21311, 21327, 20739, 20343, 21370, 21386, 21417, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21977, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 21452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 21504, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 36501, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 28674, 21946, 17617, 36473, 18223, 17237, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 21575, 21534, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 21560, 30628, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21798, 18836, 21612, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21636, 18836, 18987, 19008, 19233, 17902, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21753, 19096, 21903, 19008, 19233, 20367, 19008, 19291, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 17379, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 21931, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 18280, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21962, 18594, 18987, 19008, 19233, 22043, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21681, 21858, 18987, 19008, 19233, 20367, 19008, 21544, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 32319, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 22231, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 31678, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 33588, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 35019, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22248, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 31500, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 21431, 24401, 24401, 24401, 24401, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22324, 18836, 22059, 18888, 27857, 30501, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 34365, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22354, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 27086, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 19930, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21828, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22309, 22513, 18987, 19008, 19233, 20367, 19008, 19122, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 22544, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22608, 18836, 22988, 23004, 27585, 23020, 23036, 23067, 22087, 18888, 18888, 18888, 23083, 27211, 27211, 27211, 23102, 22121, 24401, 24401, 24401, 23122, 31386, 26154, 19674, 18888, 28119, 28232, 19424, 23705, 27211, 27211, 23142, 23173, 23189, 23212, 24401, 24401, 23246, 34427, 31693, 23262, 18888, 23290, 23308, 27783, 27620, 23327, 35263, 35107, 33383, 23346, 18193, 23393, 32748, 23968, 24401, 23414, 35153, 23463, 18888, 33913, 23442, 23482, 27211, 27211, 23532, 23552, 21431, 23575, 24401, 24401, 23604, 26095, 23635, 23657, 18888, 33482, 23685, 33251, 27211, 22187, 18851, 23721, 35536, 24401, 18887, 23750, 32641, 27211, 23769, 23787, 20080, 33012, 24384, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 23803, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 28224, 31826, 23823, 26917, 34978, 23850, 26493, 25782, 23878, 23914, 23516, 31008, 22105, 19419, 27963, 19659, 29781, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22623, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 28909, 25783, 27211, 27211, 27211, 34048, 23933, 22164, 24401, 24401, 24401, 28409, 23949, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 31181, 26583, 18888, 18888, 18888, 35585, 23984, 27211, 27211, 27211, 24005, 22201, 24033, 24401, 24401, 24401, 24052, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 26496, 24076, 24126, 24151, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22638, 18836, 22059, 19678, 27857, 24185, 24401, 24201, 24217, 26592, 18888, 18888, 18890, 24252, 24268, 27211, 27211, 22121, 24287, 24303, 24401, 24401, 30613, 19781, 35432, 36007, 32649, 18888, 25783, 24322, 28966, 23771, 27211, 35072, 22164, 24358, 32106, 26829, 24400, 31500, 31693, 18888, 18888, 18888, 24801, 18890, 27211, 27211, 27211, 27211, 24418, 19484, 24401, 24401, 24401, 24401, 20167, 31181, 18888, 18888, 18888, 27833, 23086, 27211, 27211, 33540, 27211, 30756, 21431, 24401, 24401, 22972, 24401, 26095, 18888, 36131, 18888, 27855, 27211, 24440, 27211, 22187, 22968, 24401, 24459, 24401, 31699, 28454, 18888, 34528, 34570, 35779, 24478, 24402, 24494, 25659, 18888, 36228, 27211, 27211, 24515, 30981, 23734, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 24538, 31017, 27856, 31741, 30059, 23377, 24563, 19837, 25782, 19760, 31015, 23516, 25374, 22105, 19419, 29793, 24579, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22653, 18836, 22059, 25756, 19982, 34097, 23196, 29183, 24614, 24110, 23641, 24673, 26103, 24697, 24443, 24713, 28558, 22121, 24748, 24462, 24764, 23398, 30613, 18888, 18888, 18888, 18888, 24798, 25783, 27211, 27211, 27211, 34232, 35072, 22164, 24401, 24401, 24401, 33302, 31500, 22559, 24106, 24232, 18888, 18888, 34970, 24817, 30411, 27211, 27211, 32484, 19484, 29750, 35127, 24401, 24401, 19872, 31181, 24852, 18888, 18888, 24871, 29221, 27211, 27211, 32072, 27211, 30756, 34441, 24401, 24401, 31571, 24401, 26095, 33141, 27802, 27011, 27855, 25295, 25607, 24888, 22187, 22968, 19195, 34593, 24906, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 18888, 33663, 27211, 27211, 24924, 24947, 23588, 31018, 18890, 27211, 31833, 22135, 19447, 23086, 23330, 19828, 30904, 31042, 24972, 19840, 25000, 31738, 30898, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 25016, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22668, 18836, 25041, 25057, 31320, 25073, 25089, 25105, 22087, 34796, 24236, 36138, 34870, 34125, 25121, 23106, 35497, 22248, 36613, 25137, 30671, 27365, 30613, 25153, 26447, 25199, 25233, 22574, 23274, 25249, 25265, 25281, 25318, 25344, 25360, 25400, 25428, 25452, 26731, 25504, 31693, 23669, 25558, 27407, 25575, 28599, 25934, 25599, 27211, 28180, 27304, 25623, 25839, 25649, 24401, 34820, 25681, 25698, 22586, 27775, 30190, 25745, 25778, 25799, 25817, 28995, 33569, 30756, 21518, 33443, 25837, 25855, 25893, 26095, 31254, 26677, 30136, 27855, 25930, 25950, 27211, 22187, 22968, 25966, 25986, 24401, 23428, 27763, 36330, 26959, 26002, 26029, 26045, 26085, 26119, 26170, 26203, 26222, 26239, 30527, 26372, 26274, 28404, 31018, 33757, 27211, 34262, 26316, 36729, 26345, 26366, 35337, 31017, 26388, 26407, 30954, 26350, 33861, 26434, 26463, 26479, 26512, 23516, 33189, 26531, 26547, 27963, 31293, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22683, 18836, 26568, 26181, 26608, 34097, 26643, 29183, 22087, 26669, 18888, 18888, 18890, 26693, 27211, 27211, 27211, 22121, 26720, 24401, 24401, 24401, 30613, 18888, 18888, 18888, 18888, 26774, 25783, 27211, 27211, 27211, 26619, 35072, 22164, 24401, 24401, 24401, 21596, 31500, 31693, 18888, 18888, 33978, 18888, 18890, 27211, 27211, 25801, 27211, 27211, 19484, 24401, 24401, 24401, 26792, 24401, 31181, 18888, 18888, 18888, 35464, 23086, 27211, 27211, 27211, 26809, 30756, 21431, 24401, 24401, 24401, 26828, 26095, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 22187, 22968, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 35779, 20080, 24402, 19868, 25659, 31948, 18889, 35707, 27211, 19719, 26845, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 26905, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 24984, 31088, 19419, 26945, 27651, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22698, 18836, 26999, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 23051, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 27033, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 27056, 18888, 18890, 27211, 27211, 30320, 27211, 27211, 27075, 24401, 24401, 29032, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 33986, 27855, 27211, 27211, 27102, 17590, 24017, 24401, 24401, 27123, 27144, 36254, 27162, 27210, 27228, 28500, 18187, 34842, 33426, 27244, 35980, 27277, 27302, 27320, 36048, 34013, 20999, 31882, 21478, 27895, 27356, 30287, 27381, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 26329, 30087, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 27406, 27423, 27445, 35294, 27461, 22087, 18888, 18888, 30140, 18890, 27211, 27211, 27989, 27211, 22121, 24401, 24401, 25682, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 34042, 27211, 27211, 27211, 27211, 29700, 22164, 24401, 24401, 24401, 24401, 27128, 31693, 27477, 18888, 18888, 18888, 18890, 27194, 27211, 27211, 27211, 27211, 19484, 35299, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 27059, 23086, 27211, 27211, 27211, 33366, 30756, 24012, 24401, 24401, 24401, 35044, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 20815, 27211, 30818, 19960, 33969, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22713, 18836, 22059, 27496, 27516, 27541, 35231, 27557, 22087, 29662, 26292, 23292, 27573, 24836, 27601, 27211, 27636, 22121, 35544, 27686, 24401, 27721, 18866, 18888, 27799, 18888, 27818, 22071, 27853, 32260, 27211, 26013, 27873, 27920, 22164, 29419, 24401, 29946, 33413, 26742, 27751, 26881, 18888, 18888, 27261, 36776, 27936, 27211, 27211, 27211, 27988, 28005, 28031, 28052, 24401, 24401, 28069, 28088, 28135, 25488, 28152, 26069, 28167, 27211, 28340, 24657, 28196, 30756, 31523, 24401, 28212, 34176, 36174, 24956, 28248, 28266, 28290, 21488, 33077, 28327, 28356, 17590, 20986, 23126, 28391, 28425, 28102, 28451, 28470, 28490, 28516, 28534, 20034, 33728, 25868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 30241, 28274, 28553, 28574, 19406, 28590, 23086, 23330, 19828, 19452, 28615, 28660, 26147, 25783, 31738, 19837, 25782, 19760, 29613, 35958, 29276, 22105, 19419, 27963, 23157, 28700, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 18888, 27857, 34097, 24401, 29183, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 22528, 18888, 18888, 18888, 18888, 18890, 27333, 27211, 27211, 27211, 27211, 19484, 30853, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22728, 18836, 28747, 28782, 28817, 28841, 28857, 28880, 28896, 24161, 28943, 32011, 36261, 27340, 28961, 29492, 28982, 29011, 24522, 29027, 25436, 29048, 23051, 27500, 29090, 29110, 30713, 18888, 23512, 29130, 25183, 27211, 29155, 28927, 27033, 29173, 23230, 24401, 29199, 35373, 31693, 18888, 18888, 25583, 32629, 29218, 27211, 27211, 31461, 30692, 29237, 27075, 24401, 24401, 24401, 29262, 29302, 19628, 18888, 34329, 18888, 18888, 23086, 27211, 29329, 27211, 27211, 30756, 24012, 35933, 24401, 24401, 24401, 27705, 31612, 18888, 18888, 29346, 29374, 27211, 35650, 17590, 21436, 29393, 24401, 25970, 18887, 33895, 18888, 27211, 32528, 27212, 24016, 32769, 19868, 25659, 18888, 26889, 27211, 27211, 29412, 23889, 24371, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31768, 19840, 25783, 31738, 19837, 29435, 29508, 31102, 29550, 29606, 22105, 30300, 29462, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22743, 18836, 22059, 29629, 29473, 34097, 33285, 29183, 29651, 27254, 18888, 29678, 33329, 32535, 27211, 29694, 29716, 22121, 19202, 24401, 32742, 29741, 18866, 26776, 33921, 28474, 18888, 18888, 25783, 29766, 27211, 29809, 27211, 35072, 22164, 35825, 24401, 29828, 24401, 24036, 36769, 25217, 18888, 18888, 29848, 18890, 27211, 29871, 27211, 26258, 27211, 29894, 24401, 29929, 24401, 36587, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 29725, 29962, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18473, 18888, 18888, 19584, 27211, 27212, 24016, 29982, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19902, 19447, 32052, 19544, 19828, 29998, 30097, 30031, 19840, 25783, 30047, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 30075, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22758, 18836, 30121, 30156, 30206, 30257, 30273, 30336, 22087, 35624, 32837, 25762, 18890, 29878, 34934, 26812, 27211, 22121, 24931, 23223, 29202, 24401, 18866, 34373, 30352, 18888, 18888, 18888, 23447, 24828, 27211, 27211, 27211, 35072, 30370, 35052, 24401, 24401, 24401, 24036, 29523, 18888, 18888, 27146, 18888, 31308, 30386, 27211, 27211, 30405, 30558, 19484, 30427, 24401, 24401, 29938, 35686, 19628, 28766, 30447, 34506, 35614, 23086, 28731, 30482, 30517, 30552, 30756, 24012, 20156, 30574, 30598, 30667, 26283, 33464, 28945, 27670, 30687, 32915, 33504, 25328, 17590, 23963, 20450, 33837, 21016, 32397, 26300, 30708, 30729, 27885, 30748, 21588, 36373, 30779, 26653, 24628, 33220, 32514, 30806, 31835, 25412, 25906, 26515, 18890, 28825, 31833, 26133, 19447, 28304, 31730, 23834, 26057, 30869, 30885, 32181, 30920, 30942, 32797, 25782, 30970, 31015, 23516, 31008, 30997, 31034, 27963, 19659, 29450, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22773, 18836, 31058, 31074, 32463, 31125, 31141, 31197, 22087, 18888, 29534, 35471, 36738, 27211, 24342, 31213, 24424, 22121, 24401, 20175, 31229, 31917, 27736, 31245, 34334, 27175, 18888, 29094, 27286, 27211, 31278, 31336, 27211, 31355, 31371, 24401, 31402, 31418, 24401, 31437, 31693, 18888, 31619, 32841, 18888, 18890, 27211, 27211, 31460, 31477, 27211, 19484, 24401, 24401, 31497, 36581, 24401, 33020, 18888, 18888, 18888, 18888, 30007, 27211, 27211, 27211, 27211, 31516, 32310, 24401, 24401, 24401, 24401, 31539, 18888, 28762, 18888, 24651, 35740, 27211, 27211, 28644, 31565, 35796, 24401, 24401, 19318, 32188, 18888, 24334, 28366, 27212, 29966, 29832, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 31587, 19868, 31635, 32435, 33693, 30105, 31663, 20005, 31715, 31757, 31784, 31812, 30015, 31851, 31878, 25783, 31898, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 31933, 30221, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22788, 18836, 22059, 25729, 30466, 31968, 24306, 31984, 32000, 32807, 35160, 27017, 29590, 34941, 19801, 29377, 33700, 22121, 27040, 30431, 29396, 28864, 29565, 18888, 18888, 18888, 32027, 18888, 25783, 27211, 27211, 23698, 27211, 35072, 22164, 24401, 24401, 30845, 24401, 24036, 32045, 18888, 26929, 18888, 18888, 18890, 27211, 31481, 32068, 27211, 27211, 32088, 24401, 33058, 32122, 24401, 24401, 33736, 18888, 18888, 33162, 18888, 23086, 27211, 27211, 29484, 27211, 28375, 32144, 24401, 24401, 33831, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 36704, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 33107, 22171, 33224, 24271, 32169, 31017, 27856, 31741, 19840, 25783, 31738, 30234, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 32204, 32232, 32252, 32677, 33295, 29074, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 23619, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 32276, 24401, 24401, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 32299, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 33886, 18889, 36065, 27211, 19719, 35326, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22803, 18836, 32335, 31647, 34666, 32351, 32367, 32417, 22087, 18888, 32433, 19335, 32451, 27211, 32479, 27107, 32500, 22121, 24401, 32551, 20085, 32572, 18866, 22287, 23753, 18888, 18888, 32602, 32665, 27211, 32693, 27211, 26972, 32713, 32729, 24401, 32764, 24401, 25877, 32785, 34768, 18888, 27390, 32823, 24594, 24855, 32857, 24890, 32878, 32904, 27211, 32942, 32977, 24401, 33000, 29313, 24401, 30790, 26206, 27666, 33904, 18888, 23086, 36353, 27211, 33036, 27211, 30756, 24012, 32153, 24401, 33056, 24401, 35861, 18888, 18888, 30354, 27972, 27211, 27211, 33800, 17590, 20145, 24401, 24401, 34638, 20811, 18888, 18888, 33074, 27211, 27212, 36167, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 34616, 24169, 33093, 33123, 33157, 27856, 31741, 23862, 26552, 34302, 19837, 25782, 19760, 31015, 23516, 31008, 33178, 19973, 27963, 23497, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22818, 18836, 33205, 28113, 33240, 34097, 33275, 29183, 22087, 33318, 35438, 18888, 18890, 33345, 26391, 33382, 27211, 22121, 33399, 28072, 33442, 24401, 18866, 22232, 18888, 33459, 18888, 18888, 33480, 33498, 25175, 27211, 27211, 26704, 22164, 24775, 35239, 24401, 24401, 25914, 29580, 18888, 18888, 31109, 25211, 33520, 33539, 27211, 27211, 33556, 36284, 19484, 33585, 24401, 24401, 33604, 32556, 19628, 18888, 18888, 31262, 33658, 23086, 27211, 27211, 33679, 27211, 30756, 24012, 24401, 24401, 33716, 24401, 26854, 27480, 18888, 33752, 27855, 33259, 34701, 27211, 17590, 32102, 24782, 23807, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 33773, 36105, 19868, 25659, 18888, 23368, 27211, 29157, 19719, 23889, 34454, 29286, 18890, 33794, 25302, 33816, 19447, 34079, 33853, 31862, 31017, 27856, 31741, 33877, 28920, 33937, 19837, 30461, 34002, 22276, 36041, 34029, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22833, 18836, 34064, 32616, 34113, 34141, 34157, 34192, 34208, 32216, 36013, 31549, 31952, 34224, 34248, 34287, 29330, 34350, 34389, 34413, 34481, 26793, 18866, 26187, 29635, 22293, 18888, 36654, 25783, 34522, 34544, 34566, 25821, 35072, 22164, 34586, 34609, 34632, 19604, 24036, 36644, 36674, 24681, 18888, 32401, 34654, 31339, 34682, 34698, 27211, 34717, 34753, 28053, 34812, 34836, 24401, 33619, 19628, 34858, 32236, 34906, 24598, 33523, 27612, 34890, 34922, 24732, 29246, 36717, 33634, 34465, 32984, 34168, 26750, 34957, 18888, 18888, 34994, 35010, 27211, 33040, 17590, 29913, 35035, 24401, 36304, 25482, 30171, 35883, 35068, 35088, 26627, 20441, 31173, 35123, 35143, 35176, 24640, 30492, 29358, 19719, 35192, 35219, 25384, 28801, 35255, 35279, 32586, 34496, 23086, 23330, 29061, 31017, 27856, 31741, 19840, 25783, 31738, 24547, 25164, 35315, 31796, 35353, 34316, 22105, 19419, 27963, 24091, 28630, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22848, 18836, 22059, 34782, 34088, 35389, 21008, 35405, 35421, 35454, 18888, 18888, 23466, 35487, 27211, 27211, 27211, 35513, 31154, 24401, 24401, 24401, 35560, 18888, 26863, 36664, 35601, 24872, 25783, 30389, 23536, 26250, 35647, 35666, 22164, 19522, 19564, 30582, 35682, 27697, 35575, 29114, 18888, 18888, 18888, 18890, 27211, 35702, 27211, 27211, 27211, 35723, 24401, 35527, 24401, 24401, 24401, 19628, 30184, 18888, 18888, 18888, 23086, 35739, 27211, 27211, 27211, 29139, 22938, 24401, 24401, 24401, 24401, 23898, 35756, 18888, 18888, 25025, 35778, 27211, 27211, 17590, 20064, 35795, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 23917, 18890, 34550, 31833, 22262, 19447, 23086, 23330, 26418, 31017, 27856, 31741, 19840, 25783, 35812, 19837, 27187, 35841, 33135, 23516, 31008, 22105, 22148, 28712, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22863, 18836, 22059, 35877, 28723, 34097, 31164, 29183, 22087, 26758, 18888, 22592, 18890, 23989, 27211, 29812, 27211, 22121, 33778, 24401, 31421, 24401, 18866, 18888, 18888, 26872, 18888, 18888, 25783, 27211, 30732, 27211, 27211, 35072, 22164, 24401, 24908, 24401, 24401, 24036, 31693, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22878, 18836, 22059, 27837, 27857, 35899, 24401, 35915, 22087, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 22121, 24401, 24401, 24401, 24401, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 31602, 18888, 18888, 18888, 18888, 26223, 27211, 27211, 27211, 27211, 27211, 19484, 35931, 24401, 24401, 24401, 24401, 19628, 18888, 28136, 18888, 18888, 35949, 27211, 32862, 27211, 32697, 30756, 24012, 24401, 32283, 24401, 32128, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22893, 18836, 22059, 35974, 34882, 34097, 33960, 29183, 35996, 18888, 23311, 18888, 36029, 27211, 27211, 36064, 36081, 22121, 24401, 24401, 36104, 33950, 18866, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 35072, 22164, 24401, 24401, 24401, 24401, 24036, 36121, 18888, 25559, 18888, 18888, 18890, 27211, 27211, 30313, 27211, 27211, 36154, 24401, 24401, 34397, 24401, 24401, 19628, 28250, 18888, 18888, 18888, 23086, 30926, 27211, 27211, 27211, 26983, 24012, 33642, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22339, 18836, 22059, 19354, 27857, 36190, 24401, 36206, 22087, 18888, 18888, 18888, 18007, 27211, 27211, 27211, 24724, 22121, 24401, 24401, 24401, 30827, 18866, 18888, 36222, 18888, 28795, 18888, 25783, 35100, 27211, 27429, 27211, 35072, 22164, 30836, 24401, 24499, 24401, 24036, 31693, 18888, 36244, 18888, 18888, 18890, 27211, 36088, 27211, 27211, 27211, 19484, 24401, 28036, 24401, 24401, 24401, 19628, 18888, 18888, 35631, 18888, 35762, 27211, 27211, 36277, 27211, 34730, 24012, 24401, 24401, 36300, 24401, 36320, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 25712, 18888, 18888, 36346, 27211, 27212, 19184, 24402, 19868, 25659, 32029, 18889, 27211, 33359, 19719, 23889, 36369, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22384, 18836, 36389, 19008, 19233, 20367, 36434, 17173, 17595, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 36453, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 20362, 21726, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 22369, 18836, 18987, 19008, 19233, 20367, 19008, 21737, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17949, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21813, 18836, 36489, 19008, 19233, 20367, 19008, 17173, 17737, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17768, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 20543, 22022, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21828, 18836, 18987, 19008, 19233, 20367, 19008, 17173, 30763, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 36517, 17308, 17327, 17346, 18918, 18452, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 18127, 21873, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 21828, 18836, 19307, 18888, 27857, 30756, 24401, 29183, 28015, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 36567, 24401, 24401, 24401, 24401, 22953, 18888, 18888, 18888, 18888, 18888, 25783, 27211, 27211, 27211, 27211, 28537, 36603, 24401, 24401, 24401, 24401, 24036, 18881, 18888, 18888, 18888, 18888, 18890, 27211, 27211, 27211, 27211, 27211, 19484, 24401, 24401, 24401, 24401, 24401, 19628, 18888, 18888, 18888, 18888, 23086, 27211, 27211, 27211, 27211, 30756, 24012, 24401, 24401, 24401, 24401, 26750, 18888, 18888, 18888, 27855, 27211, 27211, 27211, 17590, 24017, 24401, 24401, 24401, 18887, 18888, 18888, 27211, 27211, 27212, 24016, 24402, 19868, 25659, 18888, 18889, 27211, 27211, 19719, 23889, 19868, 31018, 18890, 27211, 31833, 19406, 19447, 23086, 23330, 19828, 31017, 27856, 31741, 19840, 25783, 31738, 19837, 25782, 19760, 31015, 23516, 31008, 22105, 19419, 27963, 19659, 27951, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 36629, 36690, 18720, 19008, 19233, 20367, 19008, 17454, 17595, 36437, 17330, 17349, 18921, 17189, 17208, 17281, 20355, 17223, 17308, 17327, 17346, 18918, 36754, 21880, 18649, 18665, 19006, 17265, 22033, 20765, 17421, 20535, 17192, 20362, 21726, 17311, 18658, 18999, 19008, 17447, 32952, 17497, 17520, 17251, 36411, 17782, 20682, 17714, 18326, 17543, 17559, 17585, 21887, 17504, 17527, 17258, 36418, 21915, 21940, 17611, 36467, 18217, 17633, 17661, 21190, 17703, 21176, 17730, 34737, 21946, 17617, 36473, 18223, 36531, 17477, 19152, 17860, 17892, 17675, 17753, 17832, 17590, 21620, 17481, 19156, 17864, 18731, 17918, 36551, 17292, 17934, 17979, 18727, 18681, 18405, 18621, 18039, 18056, 18072, 18117, 18143, 18706, 18052, 18209, 18250, 18239, 18266, 17963, 18296, 18312, 18376, 17807, 36403, 19232, 17796, 17163, 30642, 18392, 17816, 32961, 17645, 18805, 18421, 18437, 18519, 17393, 18747, 18505, 18535, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 17590, 0, 94242, 0, 118820, 0, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2482176, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 2207744, 2404352, 2412544, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3104768, 2605056, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2678784, 2207744, 2695168, 2207744, 2703360, 2207744, 2711552, 2752512, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 3170304, 3174400, 2158592, 0, 139, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 2748416, 2756608, 2777088, 2801664, 2158592, 2158592, 2158592, 2863104, 2891776, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3104768, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2785280, 2207744, 2809856, 2207744, 2207744, 2842624, 2207744, 2207744, 2207744, 2899968, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2473984, 2207744, 2207744, 2494464, 2207744, 2207744, 2207744, 2523136, 2158592, 2404352, 2412544, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2564096, 2158592, 2158592, 2605056, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2678784, 2158592, 2695168, 2158592, 2703360, 2158592, 2711552, 2752512, 2158592, 2158592, 2785280, 2158592, 2158592, 2785280, 2158592, 2809856, 2158592, 2158592, 2842624, 2158592, 2158592, 2158592, 2899968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 641, 0, 2158592, 0, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 32768, 0, 2158592, 0, 2158592, 2158592, 2158592, 2383872, 2158592, 2158592, 2158592, 2158592, 3006464, 2383872, 2207744, 2207744, 2207744, 2207744, 2158877, 2158877, 2158877, 2158877, 0, 0, 0, 2158877, 2572573, 2158877, 2158877, 0, 2207744, 2207744, 2596864, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2641920, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 167936, 0, 0, 2162688, 0, 0, 3104768, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2146304, 2146304, 2224128, 2224128, 2232320, 2232320, 2232320, 641, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2531328, 2158592, 2158592, 2158592, 2158592, 2158592, 2617344, 2158592, 2158592, 2158592, 2158592, 2441216, 2445312, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2502656, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2580480, 2158592, 2158592, 2158592, 2158592, 2621440, 2158592, 2580480, 2158592, 2158592, 2158592, 2158592, 2621440, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2699264, 2158592, 2158592, 2158592, 2158592, 2158592, 2748416, 2756608, 2777088, 2801664, 2207744, 2863104, 2891776, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3018752, 2207744, 3043328, 2207744, 2207744, 2207744, 2207744, 3080192, 2207744, 2207744, 3112960, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 172310, 279, 0, 2162688, 0, 0, 2207744, 2207744, 2207744, 3186688, 2207744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2404352, 2412544, 2158592, 2510848, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2584576, 2158592, 2609152, 2158592, 2158592, 2629632, 2158592, 2158592, 2158592, 2686976, 2158592, 2715648, 2158592, 2158592, 3121152, 2158592, 2158592, 2158592, 3149824, 2158592, 2158592, 3170304, 3174400, 2158592, 2367488, 2207744, 2207744, 2207744, 2207744, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2572288, 2158592, 2158592, 0, 2207744, 2207744, 2207744, 2433024, 2207744, 2453504, 2461696, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2510848, 2207744, 2207744, 2207744, 2207744, 2207744, 2531328, 2207744, 2207744, 2207744, 2207744, 2207744, 2617344, 2207744, 2207744, 2207744, 2207744, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2572288, 2158592, 2158592, 1508, 2715648, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2867200, 2207744, 2904064, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2580480, 2207744, 2207744, 2207744, 2207744, 2621440, 2207744, 2207744, 2207744, 3149824, 2207744, 2207744, 3170304, 3174400, 2207744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 138, 2158592, 2158592, 2158592, 2404352, 2412544, 2707456, 2732032, 2207744, 2207744, 2207744, 2822144, 2826240, 2207744, 2895872, 2207744, 2207744, 2924544, 2207744, 2207744, 2973696, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 285, 2158592, 2158592, 3112960, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 2207744, 2207744, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 0, 0, 2535424, 2543616, 2158592, 2158592, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 2990080, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2572288, 2981888, 2207744, 2207744, 3002368, 2207744, 3047424, 3063808, 3076096, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3203072, 2708960, 2732032, 2158592, 2158592, 2158592, 2822144, 2827748, 2158592, 2895872, 2158592, 2158592, 2924544, 2158592, 2158592, 2973696, 2158592, 2981888, 2158592, 2158592, 3002368, 2158592, 3047424, 3063808, 3076096, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3203072, 2981888, 2158592, 2158592, 3003876, 2158592, 3047424, 3063808, 3076096, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3203072, 2207744, 2207744, 2207744, 2207744, 2207744, 2424832, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 20480, 0, 0, 0, 0, 0, 2162688, 20480, 0, 2523136, 2527232, 2158592, 2158592, 2576384, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2908160, 2527232, 2207744, 2207744, 2576384, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2908160, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 286, 2158592, 2158592, 0, 0, 2158592, 2158592, 2158592, 2158592, 2633728, 2658304, 0, 0, 2740224, 2744320, 0, 2834432, 2207744, 2207744, 2977792, 2207744, 2207744, 2207744, 2207744, 3039232, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3158016, 0, 0, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 933, 45, 45, 45, 45, 442, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 2494464, 2158592, 2158592, 2158592, 2524757, 2527232, 2158592, 2158592, 2576384, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 1504, 2158592, 2498560, 2158592, 2158592, 2158592, 2158592, 2568192, 2158592, 2592768, 2625536, 2158592, 2158592, 2674688, 2736128, 2158592, 2158592, 0, 2158592, 2912256, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3108864, 2158592, 2158592, 3133440, 3145728, 3153920, 2375680, 2379776, 2207744, 2207744, 2420736, 2207744, 2449408, 2207744, 2207744, 2207744, 2498560, 2207744, 2207744, 2207744, 2207744, 2568192, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 0, 551, 2158592, 2158592, 2158592, 2158592, 2207744, 2506752, 2207744, 2207744, 2207744, 2207744, 2207744, 2158592, 2506752, 0, 2020, 2158592, 2592768, 2625536, 2207744, 2207744, 2674688, 2736128, 2207744, 2207744, 2207744, 2912256, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 542, 0, 544, 2207744, 3108864, 2207744, 2207744, 3133440, 3145728, 3153920, 2375680, 2379776, 2158592, 2158592, 2420736, 2158592, 2449408, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 641, 0, 0, 0, 0, 0, 0, 2367488, 2158592, 2498560, 2158592, 2158592, 1621, 2158592, 2158592, 2568192, 2158592, 2592768, 2625536, 2158592, 2158592, 2674688, 0, 0, 0, 0, 0, 1608, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1107, 97, 97, 1110, 97, 97, 3133440, 3145728, 3153920, 2158592, 2408448, 2416640, 2158592, 2465792, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3014656, 2158592, 2158592, 3051520, 2158592, 2158592, 3100672, 2158592, 2158592, 3121152, 2158592, 2158592, 2158592, 3149824, 2416640, 2207744, 2465792, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2633728, 2658304, 2740224, 2744320, 2834432, 2949120, 2158592, 2985984, 2158592, 2998272, 2158592, 2158592, 2158592, 3129344, 2207744, 2408448, 2949120, 2207744, 2985984, 2207744, 2998272, 2207744, 2207744, 2207744, 3129344, 2158592, 2408448, 2416640, 2158592, 2465792, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 32768, 0, 0, 0, 0, 0, 0, 2367488, 2949120, 2158592, 2985984, 2158592, 2998272, 2158592, 2158592, 2158592, 3129344, 2158592, 2158592, 2478080, 2158592, 2158592, 2158592, 2535424, 2543616, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3117056, 2207744, 2207744, 2478080, 2207744, 2207744, 2207744, 2207744, 2699264, 2207744, 2207744, 2207744, 2207744, 2207744, 2748416, 2756608, 2777088, 2801664, 2207744, 2207744, 2158877, 2158877, 2158877, 2158877, 2158877, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 0, 0, 2535709, 2543901, 2158877, 2158877, 2158877, 0, 0, 0, 2158877, 2158877, 2158877, 2990365, 2158877, 2158877, 2158730, 2158730, 2158730, 2158730, 2158730, 2572426, 2207744, 2535424, 2543616, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3117056, 2158592, 2158592, 2478080, 2207744, 2207744, 2990080, 2207744, 2207744, 2158592, 2158592, 2482176, 2158592, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 0, 2158592, 2908160, 2158592, 2158592, 2158592, 2977792, 2158592, 2158592, 2158592, 2158592, 3039232, 2158592, 2158592, 3010560, 2207744, 2428928, 2207744, 2514944, 2207744, 2588672, 2207744, 2838528, 2207744, 2207744, 2207744, 3010560, 2158592, 2428928, 2158592, 2514944, 0, 0, 2158592, 2588672, 2158592, 0, 2838528, 2158592, 2158592, 2158592, 3010560, 2158592, 2506752, 2158592, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 0, 29315, 922, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1539, 45, 3006464, 2383872, 0, 2020, 2158592, 2158592, 2158592, 2158592, 3006464, 2158592, 2637824, 2953216, 2158592, 2207744, 2637824, 2953216, 2207744, 0, 0, 2158592, 2637824, 2953216, 2158592, 2539520, 2158592, 2539520, 2207744, 0, 0, 2539520, 2158592, 2158592, 2158592, 2158592, 2207744, 2506752, 2207744, 2207744, 2207744, 2207744, 2207744, 2158592, 2506752, 0, 0, 2158592, 2207744, 0, 2158592, 2158592, 2207744, 0, 2158592, 2158592, 2207744, 0, 2158592, 2965504, 2965504, 2965504, 0, 0, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2474269, 2158877, 2158877, 0, 0, 2158877, 2158877, 2158877, 2158877, 2634013, 2658589, 0, 0, 2740509, 2744605, 0, 2834717, 40976, 18, 36884, 45078, 24, 28, 90143, 94242, 118820, 102439, 106538, 98347, 118820, 118820, 118820, 40976, 18, 18, 36884, 0, 0, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 86016, 0, 0, 2211840, 102439, 0, 0, 0, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 3158016, 0, 2375680, 2379776, 2158592, 2158592, 2420736, 2158592, 2449408, 2158592, 2158592, 0, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 135, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2564096, 2158592, 2158592, 2158592, 2158592, 2158592, 2596864, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2641920, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2781184, 2793472, 2494464, 2158592, 2158592, 2158592, 2523136, 2527232, 2158592, 2158592, 2576384, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 0, 27, 27, 0, 2158592, 2498560, 2158592, 2158592, 0, 2158592, 2158592, 2568192, 2158592, 2592768, 2625536, 2158592, 2158592, 2674688, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2473984, 2158592, 2158592, 2494464, 2158592, 2158592, 2158592, 3006464, 2383872, 0, 0, 2158592, 2158592, 2158592, 2158592, 3006464, 2158592, 2637824, 2953216, 2158592, 2207744, 2637824, 2953216, 40976, 18, 36884, 45078, 24, 27, 147488, 94242, 147456, 147488, 106538, 98347, 0, 0, 147456, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 0, 81920, 0, 94242, 0, 0, 0, 2211840, 0, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2428928, 2158592, 2514944, 2158592, 2588672, 2158592, 2838528, 2158592, 2158592, 40976, 18, 151573, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 0, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 1315, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1487, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 0, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 130, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3096576, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2207744, 2158592, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 644, 2207744, 2207744, 2207744, 3186688, 2207744, 0, 1080, 0, 1084, 0, 1088, 0, 0, 0, 0, 0, 0, 0, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2531466, 2158730, 2158730, 2158730, 2158730, 2158730, 2617482, 0, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2781184, 2793472, 2158592, 2818048, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 40976, 18, 36884, 45078, 24, 27, 90143, 159779, 159744, 102439, 159779, 98347, 0, 0, 159744, 40976, 18, 18, 36884, 0, 45078, 0, 2224253, 172032, 2224253, 2232448, 2232448, 172032, 2232448, 90143, 0, 0, 2170880, 0, 0, 550, 829, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 124, 124, 127, 127, 127, 40976, 18, 36884, 45078, 25, 29, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 163931, 40976, 18, 18, 36884, 0, 45078, 249856, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 2170880, 0, 0, 827, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 4243810, 4243810, 24, 24, 27, 27, 27, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 0, 0, 0, 0, 57344, 286, 2158592, 2158592, 2158592, 2158592, 2707456, 2732032, 2158592, 2158592, 2158592, 2822144, 2826240, 2158592, 2895872, 2158592, 2158592, 2924544, 2158592, 2158592, 2973696, 2158592, 2207744, 2207744, 2207744, 3186688, 2207744, 0, 0, 0, 0, 0, 0, 53248, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 1613, 97, 97, 97, 97, 97, 97, 1495, 97, 97, 97, 97, 97, 97, 97, 97, 97, 566, 97, 97, 97, 97, 97, 97, 2207744, 0, 0, 0, 0, 0, 0, 2166784, 546, 0, 0, 0, 0, 286, 2158592, 2158592, 2158592, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 17, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 20480, 120, 121, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 2170880, 0, 53248, 550, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 196608, 18, 266240, 24, 24, 27, 27, 27, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 0, 45, 45, 45, 45, 45, 45, 45, 1535, 45, 45, 45, 45, 45, 45, 45, 1416, 45, 45, 45, 45, 45, 45, 45, 45, 424, 45, 45, 45, 45, 45, 45, 45, 45, 45, 405, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 199, 45, 45, 67, 67, 67, 67, 67, 491, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1766, 67, 67, 67, 1767, 67, 24850, 24850, 12564, 12564, 0, 0, 2166784, 546, 0, 53531, 53531, 0, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 743, 57889, 0, 2170880, 0, 0, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1856, 45, 1858, 1859, 67, 67, 67, 1009, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1021, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2367773, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2699549, 2158877, 2158877, 2158877, 2158877, 2158877, 2748701, 2756893, 2777373, 2801949, 97, 1115, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 857, 97, 67, 67, 67, 67, 67, 1258, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1826, 67, 97, 97, 97, 97, 97, 97, 1338, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 870, 97, 97, 67, 67, 67, 1463, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1579, 67, 67, 97, 97, 97, 1518, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 904, 905, 97, 97, 97, 97, 1620, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 0, 0, 0, 0, 0, 45, 1679, 67, 67, 67, 1682, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1690, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 669, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 189, 45, 45, 45, 1748, 45, 45, 45, 1749, 1750, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1959, 67, 67, 67, 67, 1768, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1791, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1802, 67, 1817, 67, 67, 67, 67, 67, 67, 1823, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 97, 1848, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 659, 45, 45, 45, 45, 45, 45, 45, 1863, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 495, 67, 67, 67, 67, 67, 1878, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 0, 1973, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1165, 97, 1167, 67, 24850, 24850, 12564, 12564, 0, 0, 2166784, 0, 0, 53531, 53531, 0, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 1789, 97, 0, 94242, 0, 0, 0, 2211840, 102439, 0, 0, 106538, 98347, 136, 2158592, 2158592, 2158592, 2158592, 2158592, 3158016, 229376, 2375680, 2379776, 2158592, 2158592, 2420736, 2158592, 2449408, 2158592, 2158592, 67, 24850, 24850, 12564, 12564, 0, 0, 280, 547, 0, 53531, 53531, 0, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 1788, 97, 97, 0, 97, 2024, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 235, 67, 67, 67, 67, 67, 57889, 547, 547, 0, 0, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1799, 45, 45, 45, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 1092, 0, 0, 0, 0, 0, 97, 97, 97, 97, 1612, 97, 97, 97, 97, 1616, 97, 1297, 1472, 0, 0, 0, 0, 1303, 1474, 0, 0, 0, 0, 1309, 1476, 0, 0, 0, 0, 97, 97, 97, 1481, 97, 97, 97, 97, 97, 97, 1488, 97, 0, 1474, 0, 1476, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 607, 97, 97, 97, 97, 40976, 18, 36884, 45078, 26, 30, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 213080, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 143448, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 0, 0, 0, 0, 97, 97, 97, 97, 1482, 97, 1483, 97, 97, 97, 97, 97, 97, 1326, 97, 97, 1329, 1330, 97, 97, 97, 97, 97, 97, 1159, 1160, 97, 97, 97, 97, 97, 97, 97, 97, 590, 97, 97, 97, 97, 97, 97, 97, 0, 94242, 0, 0, 0, 2211974, 102439, 0, 0, 106538, 98347, 0, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2474122, 2158730, 2158730, 2494602, 2158730, 2158730, 2158730, 2809994, 2158730, 2158730, 2842762, 2158730, 2158730, 2158730, 2900106, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3014794, 2158730, 2158730, 3051658, 2158730, 2158730, 3100810, 2158730, 2158730, 2158730, 2158730, 3096714, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2207744, 2207744, 2207744, 2207744, 2207744, 2572288, 2207744, 2207744, 2207744, 2207744, 541, 541, 543, 543, 0, 0, 2166784, 0, 548, 549, 549, 0, 286, 2158877, 2158877, 2158877, 2863389, 2892061, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3186973, 2158877, 0, 0, 0, 0, 0, 0, 0, 0, 2367626, 2158877, 2404637, 2412829, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2564381, 2158877, 2158877, 2605341, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2679069, 2158877, 2695453, 2158877, 2703645, 2158877, 2711837, 2752797, 2158877, 0, 2158877, 2158877, 2158877, 2384010, 2158730, 2158730, 2158730, 2158730, 3006602, 2383872, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3096576, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 0, 0, 2158877, 2785565, 2158877, 2810141, 2158877, 2158877, 2842909, 2158877, 2158877, 2158877, 2900253, 2158877, 2158877, 2158877, 2158877, 2158877, 2531613, 2158877, 2158877, 2158877, 2158877, 2158877, 2617629, 2158877, 2158877, 2158877, 2158877, 2158730, 2818186, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3105053, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 0, 0, 0, 0, 0, 97, 97, 97, 1611, 97, 97, 97, 97, 97, 97, 97, 1496, 97, 97, 1499, 97, 97, 97, 97, 97, 2441354, 2445450, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2502794, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2433162, 2158730, 2453642, 2461834, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2580618, 2158730, 2158730, 2158730, 2158730, 2621578, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2699402, 2158730, 2158730, 2158730, 2158730, 2678922, 2158730, 2695306, 2158730, 2703498, 2158730, 2711690, 2752650, 2158730, 2158730, 2785418, 2158730, 2158730, 2158730, 3113098, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3186826, 2158730, 2207744, 2207744, 2207744, 2207744, 2781184, 2793472, 2207744, 2818048, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 541, 0, 543, 2158877, 2502941, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2580765, 2158877, 2158877, 2158877, 2158877, 2621725, 2158877, 3019037, 2158877, 3043613, 2158877, 2158877, 2158877, 2158877, 3080477, 2158877, 2158877, 3113245, 2158877, 2158877, 2158877, 2158877, 0, 2158877, 2908445, 2158877, 2158877, 2158877, 2978077, 2158877, 2158877, 2158877, 2158877, 3039517, 2158877, 2158730, 2510986, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2584714, 2158730, 2609290, 2158730, 2158730, 2629770, 2158730, 2158730, 2158730, 2388106, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2605194, 2158730, 2158730, 2158730, 2158730, 2687114, 2158730, 2715786, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2867338, 2158730, 2904202, 2158730, 2158730, 2158730, 2642058, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2781322, 2793610, 2158730, 3121290, 2158730, 2158730, 2158730, 3149962, 2158730, 2158730, 3170442, 3174538, 2158730, 2367488, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2441216, 2445312, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2502656, 2158877, 2433309, 2158877, 2453789, 2461981, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2511133, 2158877, 2158877, 2158877, 2158877, 2584861, 2158877, 2609437, 2158877, 2158877, 2629917, 2158877, 2158877, 2158877, 2687261, 2158877, 2715933, 2158877, 2158730, 2158730, 2973834, 2158730, 2982026, 2158730, 2158730, 3002506, 2158730, 3047562, 3063946, 3076234, 2158730, 2158730, 2158730, 2158730, 2207744, 2506752, 2207744, 2207744, 2207744, 2207744, 2207744, 2158877, 2507037, 0, 0, 2158877, 2158730, 2158730, 2158730, 3203210, 2207744, 2207744, 2207744, 2207744, 2207744, 2424832, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2564096, 2207744, 2207744, 2207744, 2707741, 2732317, 2158877, 2158877, 2158877, 2822429, 2826525, 2158877, 2896157, 2158877, 2158877, 2924829, 2158877, 2158877, 2973981, 2158877, 18, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 642, 0, 2158592, 0, 45, 1529, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1755, 45, 67, 67, 2982173, 2158877, 2158877, 3002653, 2158877, 3047709, 3064093, 3076381, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3203357, 2523274, 2527370, 2158730, 2158730, 2576522, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2908298, 2494749, 2158877, 2158877, 2158877, 2523421, 2527517, 2158877, 2158877, 2576669, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 0, 40976, 0, 18, 18, 4321280, 2224253, 2232448, 4329472, 2232448, 2158730, 2498698, 2158730, 2158730, 2158730, 2158730, 2568330, 2158730, 2592906, 2625674, 2158730, 2158730, 2674826, 2736266, 2158730, 2158730, 2158730, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2158730, 2912394, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3109002, 2158730, 2158730, 3133578, 3145866, 3154058, 2375680, 2207744, 3108864, 2207744, 2207744, 3133440, 3145728, 3153920, 2375965, 2380061, 2158877, 2158877, 2421021, 2158877, 2449693, 2158877, 2158877, 2158877, 3117341, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3104906, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158877, 2498845, 2158877, 2158877, 0, 2158877, 2158877, 2568477, 2158877, 2593053, 2625821, 2158877, 2158877, 2674973, 0, 0, 0, 0, 97, 97, 1480, 97, 97, 97, 97, 97, 1485, 97, 97, 97, 0, 97, 97, 1729, 97, 1731, 97, 97, 97, 97, 97, 97, 97, 311, 97, 97, 97, 97, 97, 97, 97, 97, 1520, 97, 97, 1523, 97, 97, 1526, 97, 2736413, 2158877, 2158877, 0, 2158877, 2912541, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3109149, 2158877, 2158877, 3014941, 2158877, 2158877, 3051805, 2158877, 2158877, 3100957, 2158877, 2158877, 3121437, 2158877, 2158877, 2158877, 3150109, 3133725, 3146013, 3154205, 2158730, 2408586, 2416778, 2158730, 2465930, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3018890, 2158730, 3043466, 2158730, 2158730, 2158730, 2158730, 3080330, 2633866, 2658442, 2740362, 2744458, 2834570, 2949258, 2158730, 2986122, 2158730, 2998410, 2158730, 2158730, 2158730, 3129482, 2207744, 2408448, 2949120, 2207744, 2985984, 2207744, 2998272, 2207744, 2207744, 2207744, 3129344, 2158877, 2408733, 2416925, 2158877, 2466077, 2158877, 2158877, 3170589, 3174685, 2158877, 0, 0, 0, 2158730, 2158730, 2158730, 2158730, 2158730, 2424970, 2158730, 2158730, 2158730, 2158730, 2707594, 2732170, 2158730, 2158730, 2158730, 2822282, 2826378, 2158730, 2896010, 2158730, 2158730, 2924682, 2949405, 2158877, 2986269, 2158877, 2998557, 2158877, 2158877, 2158877, 3129629, 2158730, 2158730, 2478218, 2158730, 2158730, 2158730, 2535562, 2543754, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3117194, 2207744, 2207744, 2478080, 2207744, 2207744, 2207744, 2207744, 3014656, 2207744, 2207744, 3051520, 2207744, 2207744, 3100672, 2207744, 2207744, 3121152, 2207744, 2207744, 2207744, 2207744, 2207744, 2584576, 2207744, 2609152, 2207744, 2207744, 2629632, 2207744, 2207744, 2207744, 2686976, 2207744, 2207744, 2535424, 2543616, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3117056, 2158877, 2158877, 2478365, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158730, 2158730, 2482314, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2207744, 2207744, 2207744, 2387968, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 823, 0, 825, 2158730, 2158730, 2158730, 2990218, 2158730, 2158730, 2207744, 2207744, 2482176, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 135, 0, 2207744, 2207744, 2990080, 2207744, 2207744, 2158877, 2158877, 2482461, 2158877, 2158877, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2158730, 2429066, 2158730, 2515082, 2158730, 2588810, 2158730, 2838666, 2158730, 2158730, 2158730, 3010698, 2207744, 2428928, 2207744, 2514944, 2207744, 2588672, 2207744, 2838528, 2207744, 2207744, 2207744, 3010560, 2158877, 2429213, 2158877, 2515229, 0, 0, 2158877, 2588957, 2158877, 0, 2838813, 2158877, 2158877, 2158877, 3010845, 2158730, 2506890, 2158730, 2158730, 2158730, 2748554, 2756746, 2777226, 2801802, 2158730, 2158730, 2158730, 2863242, 2891914, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 2564234, 2158730, 2158730, 2158730, 2158730, 2158730, 2597002, 2158730, 2158730, 2158730, 3006464, 2384157, 0, 0, 2158877, 2158877, 2158877, 2158877, 3006749, 2158730, 2637962, 2953354, 2158730, 2207744, 2637824, 2953216, 2207744, 0, 0, 2158877, 2638109, 2953501, 2158877, 2539658, 2158730, 2539520, 2207744, 0, 0, 2539805, 2158877, 2158730, 2158730, 2158730, 2977930, 2158730, 2158730, 2158730, 2158730, 3039370, 2158730, 2158730, 2158730, 2158730, 2158730, 2158730, 3158154, 2207744, 0, 2158877, 2158730, 2207744, 0, 2158877, 2158730, 2207744, 0, 2158877, 2965642, 2965504, 2965789, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1484, 97, 97, 97, 97, 2158592, 18, 0, 122880, 0, 0, 0, 77824, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 356, 0, 0, 0, 0, 0, 0, 28809, 0, 139, 45, 45, 45, 45, 45, 45, 1751, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1427, 67, 67, 67, 67, 67, 1432, 67, 67, 67, 3104768, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 122880, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 1322, 550, 0, 286, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 24, 4329472, 27, 27, 2207744, 2207744, 2977792, 2207744, 2207744, 2207744, 2207744, 3039232, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 3158016, 542, 0, 0, 0, 542, 0, 544, 0, 0, 0, 544, 0, 550, 0, 0, 0, 0, 0, 97, 97, 1610, 97, 97, 97, 97, 97, 97, 97, 97, 898, 97, 97, 97, 97, 97, 97, 97, 0, 94242, 0, 0, 0, 2211840, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 237568, 102439, 106538, 98347, 0, 0, 20480, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 192512, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 94, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 96, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 12378, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 126, 126, 126, 126, 90143, 0, 0, 2170880, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 20480, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 241664, 102439, 106538, 98347, 0, 0, 20568, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 200797, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 20480, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 0, 0, 44, 0, 0, 20575, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 41, 41, 41, 0, 0, 1126400, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 0, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 89, 40976, 18, 18, 36884, 0, 45078, 0, 24, 24, 24, 27, 131201, 27, 27, 90143, 0, 0, 2170880, 0, 0, 550, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2441216, 2445312, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 94242, 0, 0, 208896, 2211840, 102439, 0, 0, 106538, 98347, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 0, 0, 0, 0, 0, 0, 0, 2367488, 32768, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2433024, 2158592, 2453504, 2461696, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2510848, 2158592, 2158592, 2158592, 2158592, 40976, 18, 36884, 245783, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 20480, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 221184, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 180224, 40976, 18, 18, 36884, 155648, 45078, 0, 24, 24, 217088, 27, 27, 27, 217088, 90143, 0, 0, 2170880, 0, 0, 828, 0, 2158592, 2158592, 2158592, 2387968, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2207744, 2207744, 2387968, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 233472, 0, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 45, 45, 718, 45, 45, 45, 45, 45, 45, 45, 45, 45, 727, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 45, 1808, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 97, 97, 0, 0, 97, 67, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 97, 97, 0, 0, 97, 97, 97, 97, 97, 97, 1787, 0, 97, 97, 0, 97, 97, 97, 45, 45, 45, 45, 2029, 45, 67, 67, 67, 67, 2033, 57889, 0, 0, 54074, 54074, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 45, 1798, 45, 45, 1800, 45, 45, 0, 1472, 0, 0, 0, 0, 0, 1474, 0, 0, 0, 0, 0, 1476, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 1320, 97, 97, 0, 0, 97, 97, 97, 97, 1786, 97, 0, 0, 97, 97, 0, 1790, 1527, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 663, 67, 24850, 24850, 12564, 12564, 0, 57889, 281, 0, 0, 53531, 53531, 367, 286, 97, 97, 0, 0, 97, 97, 97, 1785, 97, 97, 0, 0, 97, 97, 0, 97, 97, 1979, 97, 97, 45, 45, 1983, 45, 1984, 45, 45, 45, 45, 45, 652, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 690, 45, 45, 694, 45, 45, 40976, 19, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 262144, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 46, 67, 98, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 45, 67, 97, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 258048, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 1122423, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 1114152, 1114152, 1114152, 0, 0, 1114112, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 37, 102439, 106538, 98347, 0, 0, 204800, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 0, 102439, 106538, 98347, 0, 0, 57436, 40976, 18, 36884, 45078, 24, 27, 33, 33, 0, 33, 33, 33, 0, 0, 0, 40976, 18, 18, 36884, 0, 45078, 0, 124, 124, 124, 127, 127, 127, 127, 90143, 0, 0, 2170880, 0, 0, 550, 0, 2158877, 2158877, 2158877, 2388253, 2158877, 2158877, 2158877, 2158877, 2158877, 2781469, 2793757, 2158877, 2818333, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2867485, 2158877, 2904349, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 3096861, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2441501, 2445597, 2158877, 2158877, 2158877, 2158877, 2158877, 40976, 122, 123, 36884, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 936, 2158592, 4243810, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 935, 45, 45, 45, 715, 45, 45, 45, 45, 45, 45, 45, 723, 45, 45, 45, 45, 45, 1182, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 430, 45, 45, 45, 45, 45, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 47, 68, 99, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 48, 69, 100, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 49, 70, 101, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 50, 71, 102, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 51, 72, 103, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 52, 73, 104, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 53, 74, 105, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 54, 75, 106, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 55, 76, 107, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 56, 77, 108, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 57, 78, 109, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 58, 79, 110, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 59, 80, 111, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 60, 81, 112, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 61, 82, 113, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 62, 83, 114, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 63, 84, 115, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 64, 85, 116, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 65, 86, 117, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 38, 102439, 106538, 98347, 66, 87, 118, 40976, 18, 36884, 45078, 24, 27, 90143, 94242, 118820, 102439, 106538, 98347, 118820, 118820, 118820, 40976, 18, 18, 0, 0, 45078, 0, 24, 24, 24, 27, 27, 27, 27, 90143, 0, 0, 1314, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 1321, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 0, 367, 0, 0, 1315, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1360, 97, 97, 131, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 145, 149, 45, 45, 45, 45, 45, 174, 45, 179, 45, 185, 45, 188, 45, 45, 202, 67, 255, 67, 67, 269, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 292, 296, 97, 97, 97, 97, 97, 321, 97, 326, 97, 332, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 646, 335, 97, 97, 349, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 437, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 523, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 511, 67, 67, 67, 97, 97, 97, 620, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1501, 1502, 97, 793, 67, 67, 796, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 808, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 2052, 67, 67, 67, 67, 813, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 830, 97, 97, 97, 97, 97, 97, 97, 97, 97, 315, 97, 97, 97, 97, 97, 97, 841, 97, 97, 97, 97, 97, 97, 97, 97, 97, 854, 97, 97, 97, 97, 97, 97, 589, 97, 97, 97, 97, 97, 97, 97, 97, 97, 867, 97, 97, 97, 97, 97, 97, 97, 891, 97, 97, 894, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 906, 45, 937, 45, 45, 940, 45, 45, 45, 45, 45, 45, 948, 45, 45, 45, 45, 45, 734, 735, 67, 737, 67, 738, 67, 740, 67, 67, 67, 45, 967, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 435, 45, 45, 45, 980, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 415, 45, 45, 67, 67, 1024, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 67, 67, 67, 67, 67, 25398, 1081, 13112, 1085, 54074, 1089, 0, 0, 0, 0, 0, 0, 363, 0, 28809, 0, 139, 45, 45, 45, 45, 45, 45, 1674, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1913, 67, 1914, 67, 67, 67, 1918, 67, 67, 97, 97, 97, 97, 1118, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 630, 97, 97, 97, 97, 97, 1169, 97, 97, 97, 97, 97, 0, 921, 0, 1175, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 1534, 45, 45, 45, 45, 45, 1538, 45, 45, 45, 45, 1233, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 742, 67, 45, 45, 1191, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 454, 67, 67, 67, 67, 1243, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1251, 67, 0, 0, 97, 97, 97, 97, 45, 45, 67, 67, 2050, 0, 97, 97, 45, 45, 45, 732, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 67, 67, 67, 1284, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 772, 67, 67, 67, 1293, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 368, 2158592, 2158592, 2158592, 2404352, 2412544, 1323, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1331, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1737, 97, 1364, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1373, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 647, 45, 45, 1387, 45, 45, 1391, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 410, 45, 45, 45, 45, 45, 1400, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1407, 45, 45, 45, 45, 45, 941, 45, 943, 45, 45, 45, 45, 45, 45, 951, 45, 67, 1438, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1447, 67, 67, 67, 67, 67, 67, 782, 67, 67, 67, 67, 67, 67, 67, 67, 67, 756, 67, 67, 67, 67, 67, 67, 97, 1491, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1500, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1736, 97, 45, 45, 1541, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 677, 45, 45, 67, 1581, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 791, 792, 67, 67, 67, 67, 1598, 67, 1600, 67, 67, 67, 67, 67, 67, 67, 67, 1472, 97, 97, 97, 1727, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1513, 97, 97, 67, 67, 97, 1879, 97, 1881, 97, 0, 1884, 0, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 1842, 97, 97, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1928, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1903, 45, 45, 45, 67, 67, 67, 67, 97, 97, 97, 97, 1971, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 1381, 45, 45, 45, 45, 1976, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1747, 809, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 97, 907, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 638, 0, 0, 0, 0, 1478, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1150, 97, 97, 97, 97, 67, 67, 67, 67, 1244, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 477, 67, 67, 67, 67, 67, 67, 1294, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1324, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 1374, 97, 97, 97, 97, 0, 1175, 0, 45, 45, 45, 45, 45, 45, 45, 45, 945, 45, 45, 45, 45, 45, 45, 45, 45, 1908, 45, 45, 1910, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1919, 67, 0, 0, 97, 97, 97, 97, 45, 2048, 67, 2049, 0, 0, 97, 2051, 45, 45, 45, 939, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 397, 45, 45, 45, 1921, 67, 67, 1923, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1947, 45, 1935, 0, 0, 0, 97, 1939, 97, 97, 1941, 97, 45, 45, 45, 45, 45, 45, 382, 389, 45, 45, 45, 45, 45, 45, 45, 45, 1810, 45, 45, 1812, 67, 67, 67, 67, 67, 256, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 336, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 371, 373, 45, 45, 45, 955, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 413, 45, 45, 45, 457, 459, 67, 67, 67, 67, 67, 67, 67, 67, 473, 67, 478, 67, 67, 482, 67, 67, 485, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 1828, 97, 554, 556, 97, 97, 97, 97, 97, 97, 97, 97, 570, 97, 575, 97, 97, 579, 97, 97, 582, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 330, 97, 97, 67, 746, 67, 67, 67, 67, 67, 67, 67, 67, 67, 758, 67, 67, 67, 67, 67, 67, 67, 1575, 67, 67, 67, 67, 67, 67, 67, 67, 493, 67, 67, 67, 67, 67, 67, 67, 97, 97, 844, 97, 97, 97, 97, 97, 97, 97, 97, 97, 856, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1735, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 1642, 97, 1644, 97, 97, 890, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 67, 67, 67, 67, 1065, 1066, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 532, 67, 67, 67, 67, 67, 67, 67, 1451, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 496, 67, 67, 97, 97, 1505, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 593, 97, 97, 0, 1474, 0, 1476, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1617, 97, 97, 1635, 0, 1637, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 885, 97, 97, 97, 97, 67, 67, 1704, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 565, 572, 97, 97, 97, 97, 97, 97, 97, 97, 1832, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 1946, 45, 45, 67, 67, 67, 67, 67, 97, 1926, 97, 1927, 97, 0, 0, 0, 97, 97, 1934, 2043, 0, 0, 97, 97, 97, 2047, 45, 45, 67, 67, 0, 1832, 97, 97, 45, 45, 45, 981, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1227, 45, 45, 45, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 372, 45, 45, 45, 45, 1661, 1662, 45, 45, 45, 45, 45, 1666, 45, 45, 45, 45, 45, 1673, 45, 1675, 45, 45, 45, 45, 45, 45, 45, 67, 1426, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1275, 67, 67, 67, 67, 67, 45, 418, 45, 45, 420, 45, 45, 423, 45, 45, 45, 45, 45, 45, 45, 45, 959, 45, 45, 962, 45, 45, 45, 45, 458, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 483, 67, 67, 67, 67, 504, 67, 67, 506, 67, 67, 509, 67, 67, 67, 67, 67, 67, 67, 528, 67, 67, 67, 67, 67, 67, 67, 67, 1287, 67, 67, 67, 67, 67, 67, 67, 555, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 580, 97, 97, 97, 97, 601, 97, 97, 603, 97, 97, 606, 97, 97, 97, 97, 97, 97, 848, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1498, 97, 97, 97, 97, 97, 97, 45, 45, 714, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 989, 990, 45, 67, 67, 67, 67, 67, 1011, 67, 67, 67, 67, 1015, 67, 67, 67, 67, 67, 67, 67, 753, 67, 67, 67, 67, 67, 67, 67, 67, 467, 67, 67, 67, 67, 67, 67, 67, 45, 45, 1179, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1003, 1004, 67, 1217, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 728, 67, 1461, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1034, 67, 97, 1516, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 871, 97, 67, 67, 67, 1705, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 567, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1715, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 1380, 45, 45, 45, 45, 45, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 1887, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 2006, 45, 45, 1907, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1920, 67, 97, 0, 2035, 97, 97, 97, 97, 97, 45, 45, 45, 45, 67, 67, 67, 1428, 67, 67, 67, 67, 67, 67, 1435, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 146, 45, 152, 45, 45, 165, 45, 175, 45, 180, 45, 45, 187, 190, 195, 45, 203, 254, 257, 262, 67, 270, 67, 67, 0, 24850, 12564, 0, 0, 0, 281, 28809, 53531, 97, 97, 97, 293, 97, 299, 97, 97, 312, 97, 322, 97, 327, 97, 97, 334, 337, 342, 97, 350, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 67, 484, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 499, 97, 581, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 596, 648, 45, 650, 45, 651, 45, 653, 45, 45, 45, 657, 45, 45, 45, 45, 45, 45, 1954, 67, 67, 67, 1958, 67, 67, 67, 67, 67, 67, 67, 768, 67, 67, 67, 67, 67, 67, 67, 67, 769, 67, 67, 67, 67, 67, 67, 67, 680, 45, 45, 45, 45, 45, 45, 45, 45, 688, 689, 691, 45, 45, 45, 45, 45, 983, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 947, 45, 45, 45, 45, 952, 45, 45, 698, 699, 45, 45, 702, 703, 45, 45, 45, 45, 45, 45, 45, 711, 744, 67, 67, 67, 67, 67, 67, 67, 67, 67, 757, 67, 67, 67, 67, 761, 67, 67, 67, 67, 765, 67, 767, 67, 67, 67, 67, 67, 67, 67, 67, 775, 776, 778, 67, 67, 67, 67, 67, 67, 785, 786, 67, 67, 789, 790, 67, 67, 67, 67, 67, 67, 1442, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1775, 97, 97, 97, 67, 67, 67, 67, 67, 798, 67, 67, 67, 802, 67, 67, 67, 67, 67, 67, 67, 67, 1465, 67, 67, 1468, 67, 67, 1471, 67, 67, 810, 67, 67, 67, 67, 67, 67, 67, 67, 67, 821, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 0, 833, 97, 835, 97, 836, 97, 838, 97, 97, 0, 0, 97, 97, 97, 2002, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 1740, 45, 45, 45, 1744, 45, 45, 45, 97, 842, 97, 97, 97, 97, 97, 97, 97, 97, 97, 855, 97, 97, 97, 97, 0, 1717, 1718, 97, 97, 97, 97, 97, 1722, 97, 0, 0, 859, 97, 97, 97, 97, 863, 97, 865, 97, 97, 97, 97, 97, 97, 97, 97, 604, 97, 97, 97, 97, 97, 97, 97, 873, 874, 876, 97, 97, 97, 97, 97, 97, 883, 884, 97, 97, 887, 888, 97, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 225280, 0, 365, 0, 367, 0, 45, 45, 45, 1531, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1199, 45, 45, 45, 45, 45, 97, 97, 908, 97, 97, 97, 97, 97, 97, 97, 97, 97, 919, 638, 0, 0, 0, 0, 2158877, 2158877, 2158877, 2158877, 2158877, 2425117, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2597149, 2158877, 2158877, 2158877, 2158877, 2158877, 2158877, 2642205, 2158877, 2158877, 2158877, 2158877, 2158877, 3158301, 0, 2375818, 2379914, 2158730, 2158730, 2420874, 2158730, 2449546, 2158730, 2158730, 953, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 965, 978, 45, 45, 45, 45, 45, 45, 985, 45, 45, 45, 45, 45, 45, 45, 45, 971, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1027, 67, 1029, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1455, 67, 67, 67, 67, 67, 67, 67, 1077, 1078, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 0, 366, 0, 139, 2158730, 2158730, 2158730, 2404490, 2412682, 1113, 97, 97, 97, 97, 97, 97, 1121, 97, 1123, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1540, 1155, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 615, 1168, 97, 97, 1171, 1172, 97, 97, 0, 921, 0, 1175, 0, 0, 0, 0, 45, 45, 45, 45, 45, 1533, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1663, 45, 45, 45, 45, 45, 45, 45, 45, 45, 183, 45, 45, 45, 45, 201, 45, 45, 45, 1219, 45, 45, 45, 45, 45, 45, 45, 1226, 45, 45, 45, 45, 45, 168, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 427, 45, 45, 45, 45, 45, 45, 45, 1231, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1242, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1046, 67, 67, 1254, 67, 1256, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 806, 807, 67, 67, 97, 1336, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1111, 97, 97, 97, 97, 97, 1351, 97, 97, 97, 1354, 97, 97, 97, 1359, 97, 97, 97, 0, 97, 97, 97, 97, 1640, 97, 97, 97, 97, 97, 97, 97, 897, 97, 97, 97, 902, 97, 97, 97, 97, 97, 97, 97, 97, 1366, 97, 97, 97, 97, 97, 97, 97, 1371, 97, 97, 97, 0, 97, 97, 97, 1730, 97, 97, 97, 97, 97, 97, 97, 97, 915, 97, 97, 97, 97, 0, 360, 0, 67, 67, 67, 1440, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1017, 67, 1019, 67, 67, 67, 67, 67, 1453, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1459, 97, 97, 97, 1493, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1525, 97, 97, 97, 97, 97, 97, 1507, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1514, 67, 67, 67, 67, 1584, 67, 67, 67, 67, 67, 1590, 67, 67, 67, 67, 67, 67, 67, 783, 67, 67, 67, 788, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1599, 1601, 67, 67, 67, 1604, 67, 1606, 1607, 67, 1472, 0, 1474, 0, 1476, 0, 97, 97, 97, 97, 97, 97, 1614, 97, 97, 97, 97, 45, 45, 1850, 45, 45, 45, 45, 1855, 45, 45, 45, 45, 45, 1222, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1229, 97, 1618, 97, 97, 97, 97, 97, 97, 97, 1625, 97, 97, 97, 97, 97, 0, 1175, 0, 45, 45, 45, 45, 45, 45, 45, 45, 447, 45, 45, 45, 45, 45, 67, 67, 1633, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 1643, 1645, 97, 97, 0, 0, 97, 97, 1784, 97, 97, 97, 0, 0, 97, 97, 0, 97, 1894, 1895, 97, 1897, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 656, 45, 45, 45, 45, 45, 45, 97, 1648, 97, 1650, 1651, 97, 0, 45, 45, 45, 1654, 45, 45, 45, 45, 45, 169, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 658, 45, 45, 45, 45, 664, 45, 45, 1659, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1187, 45, 45, 1669, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1005, 67, 67, 1681, 67, 67, 67, 67, 67, 67, 67, 1686, 67, 67, 67, 67, 67, 67, 67, 784, 67, 67, 67, 67, 67, 67, 67, 67, 1055, 67, 67, 67, 67, 1060, 67, 67, 97, 97, 1713, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 1378, 45, 45, 45, 45, 45, 45, 45, 408, 45, 45, 45, 45, 45, 45, 45, 45, 1547, 45, 1549, 45, 45, 45, 45, 45, 97, 97, 1780, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 45, 2027, 2028, 45, 45, 67, 67, 2031, 2032, 67, 45, 45, 1804, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1917, 67, 67, 67, 67, 67, 67, 67, 1819, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1708, 97, 97, 97, 97, 97, 45, 45, 1862, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 497, 67, 67, 67, 1877, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 0, 97, 97, 97, 97, 97, 1839, 0, 0, 97, 97, 97, 97, 1936, 0, 0, 97, 97, 97, 97, 97, 97, 1943, 1944, 1945, 45, 45, 45, 45, 670, 45, 45, 45, 45, 674, 45, 45, 45, 45, 678, 45, 1948, 45, 1950, 45, 45, 45, 45, 1955, 1956, 1957, 67, 67, 67, 1960, 67, 1962, 67, 67, 67, 67, 1967, 1968, 1969, 97, 0, 0, 0, 97, 97, 1974, 97, 0, 1936, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 1906, 0, 1977, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1746, 45, 45, 45, 45, 2011, 67, 67, 2013, 67, 67, 67, 2017, 97, 97, 0, 0, 2021, 97, 8192, 97, 97, 2025, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1916, 67, 67, 67, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 140, 45, 45, 45, 1180, 45, 45, 45, 45, 1184, 45, 45, 45, 45, 45, 45, 45, 387, 45, 392, 45, 45, 396, 45, 45, 399, 45, 45, 67, 207, 67, 67, 67, 67, 67, 67, 236, 67, 67, 67, 67, 67, 67, 67, 800, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1603, 67, 67, 67, 67, 67, 0, 97, 97, 287, 97, 97, 97, 97, 97, 97, 316, 97, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 1656, 1657, 45, 376, 45, 45, 45, 45, 45, 388, 45, 45, 45, 45, 45, 45, 45, 45, 1406, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 462, 67, 67, 67, 67, 67, 474, 67, 67, 67, 67, 67, 67, 67, 817, 67, 67, 67, 67, 25398, 542, 13112, 544, 97, 97, 97, 97, 559, 97, 97, 97, 97, 97, 571, 97, 97, 97, 97, 97, 97, 896, 97, 97, 97, 900, 97, 97, 97, 97, 97, 97, 912, 914, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 391, 45, 45, 45, 45, 45, 45, 45, 45, 713, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 662, 45, 1140, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 636, 67, 67, 1283, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 513, 67, 67, 1363, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 889, 97, 97, 97, 1714, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 926, 45, 45, 45, 45, 45, 45, 45, 45, 672, 45, 45, 45, 45, 45, 45, 45, 45, 686, 45, 45, 45, 45, 45, 45, 45, 45, 944, 45, 45, 45, 45, 45, 45, 45, 45, 1676, 45, 45, 45, 45, 45, 45, 67, 97, 97, 97, 1833, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 1902, 45, 45, 45, 45, 45, 957, 45, 45, 45, 45, 961, 45, 963, 45, 45, 45, 67, 97, 2034, 0, 97, 97, 97, 97, 97, 2040, 45, 45, 45, 2042, 67, 67, 67, 67, 67, 67, 1574, 67, 67, 67, 67, 67, 1578, 67, 67, 67, 67, 67, 67, 799, 67, 67, 67, 804, 67, 67, 67, 67, 67, 67, 67, 1298, 0, 0, 0, 1304, 0, 0, 0, 1310, 132, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 45, 45, 1414, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 428, 45, 45, 45, 45, 45, 57889, 0, 0, 54074, 54074, 550, 831, 97, 97, 97, 97, 97, 97, 97, 97, 97, 568, 97, 97, 97, 97, 578, 97, 45, 45, 968, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1228, 45, 45, 67, 67, 67, 67, 67, 25398, 1082, 13112, 1086, 54074, 1090, 0, 0, 0, 0, 0, 0, 364, 0, 0, 0, 139, 2158592, 2158592, 2158592, 2404352, 2412544, 67, 67, 67, 67, 1464, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 510, 67, 67, 67, 67, 97, 97, 97, 97, 1519, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 918, 97, 0, 0, 0, 0, 1528, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 976, 45, 1554, 45, 45, 45, 45, 45, 45, 45, 45, 1562, 45, 45, 1565, 45, 45, 45, 45, 683, 45, 45, 45, 687, 45, 45, 692, 45, 45, 45, 45, 45, 1953, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1014, 67, 67, 67, 67, 67, 67, 1568, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 67, 67, 67, 67, 67, 1585, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1594, 97, 97, 1649, 97, 97, 97, 0, 45, 45, 1653, 45, 45, 45, 45, 45, 45, 383, 45, 45, 45, 45, 45, 45, 45, 45, 45, 986, 45, 45, 45, 45, 45, 45, 45, 45, 1670, 45, 1672, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 736, 67, 67, 67, 67, 67, 741, 67, 67, 67, 1680, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1074, 67, 67, 67, 1692, 67, 67, 67, 67, 67, 67, 67, 1697, 67, 1699, 67, 67, 67, 67, 67, 67, 1012, 67, 67, 67, 67, 67, 67, 67, 67, 67, 468, 475, 67, 67, 67, 67, 67, 67, 1769, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 624, 97, 97, 97, 97, 97, 97, 634, 97, 97, 1792, 97, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 958, 45, 45, 45, 45, 45, 45, 964, 45, 150, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 977, 204, 45, 67, 67, 67, 217, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 787, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 271, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 97, 351, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 45, 938, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1398, 45, 45, 45, 153, 45, 161, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 660, 661, 45, 45, 205, 45, 67, 67, 67, 67, 220, 67, 228, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 280, 94, 0, 0, 67, 67, 67, 67, 67, 272, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 97, 352, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 439, 45, 45, 45, 45, 45, 445, 45, 45, 45, 452, 45, 45, 67, 67, 212, 216, 67, 67, 67, 67, 67, 241, 67, 246, 67, 252, 67, 67, 486, 67, 67, 67, 67, 67, 67, 67, 494, 67, 67, 67, 67, 67, 67, 67, 1245, 67, 67, 67, 67, 67, 67, 67, 67, 1013, 67, 67, 1016, 67, 67, 67, 67, 67, 521, 67, 67, 525, 67, 67, 67, 67, 67, 531, 67, 67, 67, 538, 67, 0, 0, 2046, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 1192, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1418, 45, 45, 1421, 97, 97, 583, 97, 97, 97, 97, 97, 97, 97, 591, 97, 97, 97, 97, 97, 97, 913, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 1384, 97, 618, 97, 97, 622, 97, 97, 97, 97, 97, 628, 97, 97, 97, 635, 97, 18, 131427, 0, 0, 0, 639, 0, 132, 362, 0, 0, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 932, 45, 45, 45, 45, 45, 1544, 45, 45, 45, 45, 45, 1550, 45, 45, 45, 45, 45, 1194, 45, 1196, 45, 45, 45, 45, 45, 45, 45, 45, 999, 45, 45, 45, 45, 45, 67, 67, 45, 45, 667, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1408, 45, 45, 45, 696, 45, 45, 45, 701, 45, 45, 45, 45, 45, 45, 45, 45, 710, 45, 45, 45, 1220, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 194, 45, 45, 45, 729, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 797, 67, 67, 67, 67, 67, 67, 805, 67, 67, 67, 67, 67, 67, 67, 1587, 67, 1589, 67, 67, 67, 67, 67, 67, 67, 67, 1763, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 2162968, 0, 0, 67, 67, 67, 67, 67, 814, 816, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 67, 67, 1008, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1020, 67, 0, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 67, 67, 67, 67, 1429, 67, 1430, 67, 67, 67, 67, 67, 1062, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 518, 1076, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 0, 28809, 0, 139, 45, 45, 45, 45, 45, 97, 97, 97, 97, 1102, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1124, 97, 1126, 97, 97, 1114, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1112, 97, 97, 1156, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 594, 97, 97, 97, 97, 1170, 97, 97, 97, 97, 0, 921, 0, 0, 0, 0, 0, 0, 45, 45, 45, 45, 1532, 45, 45, 45, 45, 1536, 45, 45, 45, 45, 45, 172, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 706, 45, 45, 709, 45, 45, 1177, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1202, 45, 1204, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1215, 45, 45, 45, 1232, 45, 45, 45, 45, 45, 45, 45, 67, 1237, 67, 67, 67, 67, 67, 67, 1053, 1054, 67, 67, 67, 67, 67, 67, 1061, 67, 67, 1282, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1289, 67, 67, 67, 1292, 97, 97, 97, 97, 1339, 97, 97, 97, 97, 97, 97, 1344, 97, 97, 97, 97, 45, 1849, 45, 1851, 45, 45, 45, 45, 45, 45, 45, 45, 721, 45, 45, 45, 45, 45, 726, 45, 1385, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1188, 45, 45, 1401, 1402, 45, 45, 45, 45, 1405, 45, 45, 45, 45, 45, 45, 45, 45, 1752, 45, 45, 45, 45, 45, 67, 67, 1410, 45, 45, 45, 1413, 45, 1415, 45, 45, 45, 45, 45, 45, 1419, 45, 45, 45, 45, 1806, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 97, 97, 2019, 0, 97, 67, 67, 67, 1452, 67, 67, 67, 67, 67, 67, 67, 67, 1457, 67, 67, 67, 67, 67, 67, 1259, 67, 67, 67, 67, 67, 67, 1264, 67, 67, 1460, 67, 1462, 67, 67, 67, 67, 67, 67, 1466, 67, 67, 67, 67, 67, 67, 67, 67, 1588, 67, 67, 67, 67, 67, 67, 67, 0, 1300, 0, 0, 0, 1306, 0, 0, 0, 97, 97, 97, 1506, 97, 97, 97, 97, 97, 97, 97, 97, 1512, 97, 97, 97, 0, 1728, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 901, 97, 97, 97, 97, 1515, 97, 1517, 97, 97, 97, 97, 97, 97, 1521, 97, 97, 97, 97, 97, 97, 0, 45, 1652, 45, 45, 45, 1655, 45, 45, 45, 45, 45, 1542, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1552, 1553, 45, 45, 45, 1556, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 693, 45, 45, 45, 67, 67, 67, 67, 1572, 67, 67, 67, 67, 1576, 67, 67, 67, 67, 67, 67, 67, 67, 1602, 67, 67, 1605, 67, 67, 67, 0, 67, 1582, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1580, 67, 67, 1596, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 542, 0, 544, 67, 67, 67, 67, 1759, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 533, 67, 67, 67, 67, 67, 67, 67, 1770, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 1777, 97, 97, 97, 1793, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 998, 45, 45, 1001, 1002, 45, 45, 67, 67, 45, 1861, 45, 67, 67, 67, 67, 67, 67, 67, 67, 1871, 67, 1873, 1874, 67, 0, 97, 45, 67, 0, 97, 45, 67, 16384, 97, 45, 67, 97, 0, 0, 0, 1473, 0, 1082, 0, 0, 0, 1475, 0, 1086, 0, 0, 0, 1477, 1876, 67, 97, 97, 97, 97, 97, 1883, 0, 1885, 97, 97, 97, 1889, 0, 0, 0, 286, 0, 0, 0, 286, 0, 2367488, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 40976, 0, 18, 18, 24, 24, 126, 126, 126, 2053, 0, 2055, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 97, 97, 2039, 97, 45, 45, 45, 45, 67, 67, 67, 67, 67, 226, 67, 67, 67, 67, 67, 67, 67, 67, 1246, 67, 67, 1249, 1250, 67, 67, 67, 132, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 141, 45, 45, 45, 1403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1186, 45, 45, 1189, 45, 45, 155, 45, 45, 45, 45, 45, 45, 45, 45, 45, 191, 45, 45, 45, 45, 700, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1753, 45, 45, 45, 67, 67, 45, 45, 67, 208, 67, 67, 67, 222, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1764, 67, 67, 67, 67, 67, 67, 67, 258, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 288, 97, 97, 97, 302, 97, 97, 97, 97, 97, 97, 97, 97, 97, 627, 97, 97, 97, 97, 97, 97, 338, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 370, 45, 45, 45, 45, 716, 45, 45, 45, 45, 45, 722, 45, 45, 45, 45, 45, 45, 1912, 67, 67, 67, 67, 67, 67, 67, 67, 67, 819, 67, 67, 25398, 542, 13112, 544, 45, 403, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1409, 45, 67, 67, 67, 67, 489, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 771, 67, 67, 67, 67, 520, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 534, 67, 67, 67, 67, 67, 67, 1271, 67, 67, 67, 1274, 67, 67, 67, 1279, 67, 67, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 97, 553, 97, 97, 97, 97, 586, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1138, 97, 97, 97, 97, 617, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 631, 97, 97, 97, 0, 1834, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 353, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 45, 668, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 724, 45, 45, 45, 45, 45, 682, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 949, 45, 45, 45, 67, 67, 747, 748, 67, 67, 67, 67, 755, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 1302, 0, 0, 0, 1308, 0, 67, 794, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1701, 67, 97, 97, 97, 845, 846, 97, 97, 97, 97, 853, 97, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 97, 97, 892, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 610, 97, 97, 45, 992, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 1239, 67, 67, 67, 1063, 67, 67, 67, 67, 67, 1068, 67, 67, 67, 67, 67, 67, 67, 0, 0, 1301, 0, 0, 0, 1307, 0, 0, 97, 1141, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1152, 97, 97, 0, 0, 97, 97, 2001, 0, 97, 2003, 97, 97, 97, 45, 45, 45, 1739, 45, 45, 45, 1742, 45, 45, 45, 45, 45, 97, 97, 97, 97, 1157, 97, 97, 97, 97, 97, 1162, 97, 97, 97, 97, 97, 97, 1145, 97, 97, 97, 97, 97, 1151, 97, 97, 97, 1253, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 539, 45, 1423, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1431, 67, 67, 67, 67, 67, 67, 67, 1695, 67, 67, 67, 67, 67, 1700, 67, 1702, 67, 67, 1439, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 514, 67, 67, 97, 97, 1492, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 611, 97, 97, 1703, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 97, 97, 852, 97, 97, 97, 97, 97, 97, 45, 1949, 45, 1951, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 1961, 67, 0, 97, 45, 67, 0, 97, 2060, 2061, 0, 2062, 45, 67, 97, 0, 0, 2036, 97, 97, 97, 97, 45, 45, 45, 45, 67, 67, 67, 67, 67, 223, 67, 67, 237, 67, 67, 67, 67, 67, 67, 67, 1272, 67, 67, 67, 67, 67, 67, 67, 67, 507, 67, 67, 67, 67, 67, 67, 67, 1963, 67, 67, 67, 97, 97, 97, 97, 0, 1972, 0, 97, 97, 97, 1975, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 931, 45, 45, 45, 45, 45, 407, 45, 45, 45, 45, 45, 45, 45, 45, 45, 417, 45, 45, 1989, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1996, 97, 18, 131427, 0, 0, 360, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 930, 45, 45, 45, 45, 45, 45, 444, 45, 45, 45, 45, 45, 45, 45, 67, 67, 97, 97, 1998, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1985, 45, 1986, 45, 45, 45, 156, 45, 45, 170, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 675, 45, 45, 45, 45, 679, 131427, 0, 358, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 381, 45, 45, 45, 45, 45, 45, 45, 45, 45, 400, 45, 45, 419, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 436, 67, 67, 67, 67, 67, 505, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 820, 67, 25398, 542, 13112, 544, 67, 67, 522, 67, 67, 67, 67, 67, 529, 67, 67, 67, 67, 67, 67, 67, 0, 1299, 0, 0, 0, 1305, 0, 0, 0, 97, 97, 619, 97, 97, 97, 97, 97, 626, 97, 97, 97, 97, 97, 97, 97, 1105, 97, 97, 97, 97, 1109, 97, 97, 97, 67, 67, 67, 67, 749, 67, 67, 67, 67, 67, 67, 67, 67, 67, 760, 67, 0, 97, 45, 67, 2058, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 97, 97, 97, 97, 45, 45, 45, 2041, 67, 67, 67, 67, 67, 780, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 516, 67, 67, 97, 97, 97, 878, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1629, 97, 0, 45, 979, 45, 45, 45, 45, 984, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1198, 45, 45, 45, 45, 45, 45, 67, 1023, 67, 67, 67, 67, 1028, 67, 67, 67, 67, 67, 67, 67, 67, 67, 470, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 1094, 0, 0, 0, 1092, 1315, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1486, 97, 1489, 97, 97, 97, 1117, 97, 97, 97, 97, 1122, 97, 97, 97, 97, 97, 97, 97, 1146, 97, 97, 97, 97, 97, 97, 97, 97, 881, 97, 97, 97, 886, 97, 97, 97, 1311, 0, 0, 0, 0, 0, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1615, 97, 97, 97, 97, 97, 1619, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1631, 97, 97, 1847, 97, 45, 45, 45, 45, 1852, 45, 45, 45, 45, 45, 45, 45, 1235, 45, 45, 45, 67, 67, 67, 67, 67, 1868, 67, 67, 67, 1872, 67, 67, 67, 67, 67, 97, 97, 97, 97, 1882, 0, 0, 0, 97, 97, 97, 97, 0, 1891, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 1929, 0, 0, 97, 97, 97, 97, 97, 97, 45, 1900, 45, 1901, 45, 45, 45, 1905, 45, 67, 2054, 97, 45, 67, 0, 97, 45, 67, 0, 97, 45, 67, 97, 0, 0, 97, 2037, 2038, 97, 97, 45, 45, 45, 45, 67, 67, 67, 67, 1867, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1774, 97, 97, 97, 97, 97, 97, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 142, 45, 45, 45, 1412, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 432, 45, 45, 45, 45, 45, 157, 45, 45, 171, 45, 45, 45, 182, 45, 45, 45, 45, 200, 45, 45, 45, 1543, 45, 45, 45, 45, 45, 45, 45, 45, 1551, 45, 45, 45, 45, 1181, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1211, 45, 45, 45, 1214, 45, 45, 45, 67, 209, 67, 67, 67, 224, 67, 67, 238, 67, 67, 67, 249, 67, 0, 97, 2056, 2057, 0, 2059, 45, 67, 0, 97, 45, 67, 97, 0, 0, 1937, 97, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1741, 45, 45, 45, 45, 45, 45, 67, 67, 67, 267, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 289, 97, 97, 97, 304, 97, 97, 318, 97, 97, 97, 329, 97, 97, 0, 0, 97, 1783, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 45, 2026, 45, 45, 45, 45, 67, 2030, 67, 67, 67, 67, 67, 67, 1041, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1044, 67, 67, 67, 67, 67, 67, 97, 97, 347, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 45, 666, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1420, 45, 57889, 0, 0, 54074, 54074, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 840, 67, 1007, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 759, 67, 67, 67, 67, 67, 67, 67, 1052, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1031, 67, 67, 67, 67, 67, 97, 97, 97, 1101, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 592, 97, 97, 97, 1190, 45, 45, 45, 45, 45, 1195, 45, 1197, 45, 45, 45, 45, 1201, 45, 45, 45, 45, 1952, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 250, 67, 67, 67, 1255, 67, 1257, 67, 67, 67, 67, 1261, 67, 67, 67, 67, 67, 67, 67, 67, 1685, 67, 67, 67, 67, 67, 67, 67, 0, 24851, 12565, 0, 0, 0, 0, 28809, 53532, 67, 67, 1267, 67, 67, 67, 67, 67, 67, 1273, 67, 67, 67, 67, 67, 67, 67, 67, 1696, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 2162688, 0, 0, 1281, 67, 67, 67, 67, 1285, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1070, 67, 67, 67, 67, 67, 1335, 97, 1337, 97, 97, 97, 97, 1341, 97, 97, 97, 97, 97, 97, 97, 97, 882, 97, 97, 97, 97, 97, 97, 97, 1347, 97, 97, 97, 97, 97, 97, 1353, 97, 97, 97, 97, 97, 97, 1361, 97, 18, 131427, 0, 638, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 544, 0, 550, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2473984, 2158592, 2158592, 2158592, 2990080, 2158592, 2158592, 2207744, 2207744, 2482176, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 2207744, 0, 0, 0, 0, 0, 0, 2162688, 0, 53530, 97, 97, 97, 1365, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 608, 97, 97, 97, 45, 45, 1424, 45, 1425, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1058, 67, 67, 67, 67, 45, 1555, 45, 45, 1557, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 707, 45, 45, 45, 45, 67, 67, 1570, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 773, 67, 67, 1595, 67, 67, 1597, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139, 2158592, 2158592, 2158592, 2404352, 2412544, 97, 97, 97, 1636, 97, 97, 97, 1639, 97, 97, 1641, 97, 97, 97, 97, 97, 97, 1173, 0, 921, 0, 0, 0, 0, 0, 0, 45, 67, 67, 67, 1693, 67, 67, 67, 67, 67, 67, 67, 1698, 67, 67, 67, 67, 67, 67, 67, 1773, 67, 97, 97, 97, 97, 97, 97, 97, 625, 97, 97, 97, 97, 97, 97, 97, 97, 850, 97, 97, 97, 97, 97, 97, 97, 97, 880, 97, 97, 97, 97, 97, 97, 97, 97, 1106, 97, 97, 97, 97, 97, 97, 97, 1860, 45, 45, 67, 67, 1865, 67, 67, 67, 67, 1870, 67, 67, 67, 67, 1875, 67, 67, 97, 97, 1880, 97, 97, 0, 0, 0, 97, 97, 1888, 97, 0, 0, 0, 1938, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 1854, 45, 45, 45, 45, 45, 45, 45, 1909, 45, 45, 1911, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1248, 67, 67, 67, 67, 67, 67, 1922, 67, 67, 1924, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 1898, 45, 45, 45, 45, 45, 45, 1904, 45, 45, 67, 67, 67, 67, 97, 97, 97, 97, 0, 0, 16384, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 1724, 2008, 2009, 45, 45, 67, 67, 67, 2014, 2015, 67, 67, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 2022, 0, 2023, 97, 97, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1869, 67, 67, 67, 67, 67, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 147, 151, 154, 45, 162, 45, 45, 176, 178, 181, 45, 45, 45, 192, 196, 45, 45, 45, 45, 2012, 67, 67, 67, 67, 67, 67, 2018, 97, 0, 0, 97, 1978, 97, 97, 97, 1982, 45, 45, 45, 45, 45, 45, 45, 45, 45, 972, 973, 45, 45, 45, 45, 45, 67, 259, 263, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 294, 298, 301, 97, 309, 97, 97, 323, 325, 328, 97, 97, 97, 97, 97, 560, 97, 97, 97, 569, 97, 97, 97, 97, 97, 97, 306, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1624, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 1175, 0, 0, 0, 0, 45, 339, 343, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 67, 67, 503, 67, 67, 67, 67, 67, 67, 67, 67, 67, 512, 67, 67, 519, 97, 97, 600, 97, 97, 97, 97, 97, 97, 97, 97, 97, 609, 97, 97, 616, 45, 649, 45, 45, 45, 45, 45, 654, 45, 45, 45, 45, 45, 45, 45, 45, 1393, 45, 45, 45, 45, 45, 45, 45, 45, 1209, 45, 45, 45, 45, 45, 45, 45, 67, 763, 67, 67, 67, 67, 67, 67, 67, 67, 770, 67, 67, 67, 774, 67, 0, 2045, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 994, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 213, 67, 219, 67, 67, 232, 67, 242, 67, 247, 67, 67, 67, 779, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1018, 67, 67, 67, 67, 811, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 0, 97, 834, 97, 97, 97, 97, 97, 839, 97, 18, 131427, 0, 638, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 645, 97, 97, 861, 97, 97, 97, 97, 97, 97, 97, 97, 868, 97, 97, 97, 872, 97, 97, 877, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 613, 97, 97, 97, 97, 97, 909, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 0, 18, 18, 24, 24, 27, 27, 27, 1036, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1047, 67, 67, 67, 1050, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1033, 67, 67, 67, 97, 97, 1130, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 638, 0, 0, 67, 67, 67, 1295, 67, 67, 67, 0, 0, 0, 0, 0, 0, 0, 0, 0, 97, 1317, 97, 97, 97, 97, 97, 97, 1375, 97, 97, 97, 0, 0, 0, 45, 1379, 45, 45, 45, 45, 45, 45, 422, 45, 45, 45, 429, 431, 45, 45, 45, 45, 0, 1090, 0, 0, 97, 1479, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1357, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1716, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1723, 0, 921, 29315, 0, 0, 0, 0, 45, 929, 45, 45, 45, 45, 45, 45, 45, 1392, 45, 45, 45, 45, 45, 45, 45, 45, 45, 960, 45, 45, 45, 45, 45, 45, 97, 97, 97, 1738, 45, 45, 45, 45, 45, 45, 45, 1743, 45, 45, 45, 45, 166, 45, 45, 45, 45, 184, 186, 45, 45, 197, 45, 45, 97, 1779, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 18, 131427, 0, 638, 0, 0, 0, 0, 362, 0, 640, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1537, 45, 45, 45, 45, 45, 1803, 45, 45, 45, 45, 45, 1809, 45, 45, 45, 67, 67, 67, 1814, 67, 67, 67, 67, 67, 67, 1821, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 0, 67, 67, 67, 1818, 67, 67, 67, 67, 67, 1824, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 1890, 0, 1829, 97, 97, 0, 0, 97, 97, 1836, 97, 97, 0, 0, 0, 97, 97, 97, 97, 1981, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1987, 1845, 97, 97, 97, 45, 45, 45, 45, 45, 1853, 45, 45, 45, 1857, 45, 45, 45, 67, 1864, 67, 1866, 67, 67, 67, 67, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 97, 97, 1710, 1711, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 1886, 97, 97, 97, 0, 0, 97, 97, 97, 97, 1838, 0, 0, 0, 97, 1843, 97, 0, 1893, 97, 97, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1745, 45, 45, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 1931, 97, 97, 97, 97, 97, 588, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 629, 97, 97, 97, 97, 97, 67, 2044, 0, 97, 97, 97, 97, 45, 45, 67, 67, 0, 0, 97, 97, 45, 45, 45, 1660, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 453, 45, 455, 67, 67, 67, 67, 268, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 348, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 359, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 421, 45, 45, 45, 45, 45, 45, 45, 434, 45, 45, 695, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1667, 45, 0, 921, 29315, 0, 925, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1811, 45, 67, 67, 67, 67, 67, 67, 1037, 67, 1039, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1277, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 1095, 0, 0, 0, 1096, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 869, 97, 97, 97, 97, 97, 97, 1131, 97, 1133, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1370, 97, 97, 97, 97, 97, 1312, 0, 0, 0, 0, 1096, 0, 0, 0, 97, 97, 97, 97, 97, 97, 97, 1327, 97, 97, 97, 97, 97, 1332, 97, 97, 97, 1830, 97, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 1896, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1548, 45, 45, 45, 45, 45, 45, 133, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 45, 380, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 401, 45, 45, 158, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1200, 45, 45, 45, 45, 206, 67, 67, 67, 67, 67, 225, 67, 67, 67, 67, 67, 67, 67, 67, 754, 67, 67, 67, 67, 67, 67, 67, 57889, 0, 0, 54074, 54074, 550, 832, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1342, 97, 97, 97, 97, 97, 97, 67, 67, 67, 67, 67, 25398, 1083, 13112, 1087, 54074, 1091, 0, 0, 0, 0, 0, 0, 1316, 0, 831, 97, 97, 97, 97, 97, 97, 97, 1174, 921, 0, 1175, 0, 0, 0, 0, 45, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 45, 148, 67, 67, 264, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 97, 295, 97, 97, 97, 97, 313, 97, 97, 97, 97, 331, 333, 97, 18, 131427, 356, 638, 0, 0, 0, 0, 362, 0, 0, 365, 0, 367, 0, 45, 45, 1530, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 988, 45, 45, 45, 97, 344, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 402, 404, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1756, 67, 438, 45, 45, 45, 45, 45, 45, 45, 45, 449, 450, 45, 45, 45, 67, 67, 214, 218, 221, 67, 229, 67, 67, 243, 245, 248, 67, 67, 67, 67, 67, 488, 490, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1071, 67, 1073, 67, 67, 67, 67, 67, 524, 67, 67, 67, 67, 67, 67, 67, 67, 535, 536, 67, 67, 67, 67, 67, 67, 1683, 1684, 67, 67, 67, 67, 1688, 1689, 67, 67, 67, 67, 67, 67, 1586, 67, 67, 67, 67, 67, 67, 67, 67, 67, 469, 67, 67, 67, 67, 67, 67, 97, 97, 97, 585, 587, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1163, 97, 97, 97, 97, 97, 97, 97, 621, 97, 97, 97, 97, 97, 97, 97, 97, 632, 633, 97, 97, 0, 0, 1782, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 712, 45, 45, 45, 717, 45, 45, 45, 45, 45, 45, 45, 45, 725, 45, 45, 45, 163, 167, 173, 177, 45, 45, 45, 45, 45, 193, 45, 45, 45, 45, 982, 45, 45, 45, 45, 45, 45, 987, 45, 45, 45, 45, 45, 1558, 45, 1560, 45, 45, 45, 45, 45, 45, 45, 45, 704, 705, 45, 45, 45, 45, 45, 45, 45, 45, 731, 45, 45, 45, 67, 67, 67, 67, 67, 739, 67, 67, 67, 67, 67, 67, 273, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 67, 67, 67, 764, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1290, 67, 67, 67, 67, 67, 67, 812, 67, 67, 67, 67, 818, 67, 67, 67, 25398, 542, 13112, 544, 57889, 0, 0, 54074, 54074, 550, 0, 97, 97, 97, 97, 97, 837, 97, 97, 97, 97, 97, 602, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1137, 97, 97, 97, 97, 97, 97, 97, 97, 97, 862, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1627, 97, 97, 97, 0, 97, 97, 97, 97, 910, 97, 97, 97, 97, 916, 97, 97, 97, 0, 0, 0, 97, 97, 1940, 97, 97, 1942, 45, 45, 45, 45, 45, 45, 385, 45, 45, 45, 45, 395, 45, 45, 45, 45, 966, 45, 969, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 975, 45, 45, 45, 406, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 974, 45, 45, 45, 67, 67, 67, 67, 1010, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1262, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1040, 67, 1042, 67, 1045, 67, 67, 67, 67, 67, 67, 67, 97, 1706, 97, 97, 97, 1709, 97, 97, 97, 67, 67, 67, 67, 1051, 67, 67, 67, 67, 67, 1057, 67, 67, 67, 67, 67, 67, 67, 1443, 67, 67, 1446, 67, 67, 67, 67, 67, 67, 67, 1297, 0, 0, 0, 1303, 0, 0, 0, 1309, 67, 67, 67, 67, 1079, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2207744, 2207744, 2207744, 2207744, 2207744, 2572288, 2207744, 2207744, 2207744, 1098, 97, 97, 97, 97, 97, 1104, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1356, 97, 97, 97, 97, 97, 97, 1128, 97, 97, 97, 97, 97, 97, 1134, 97, 1136, 97, 1139, 97, 97, 97, 97, 97, 97, 1622, 97, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 0, 0, 1176, 0, 646, 45, 67, 67, 67, 1268, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1469, 67, 67, 67, 97, 1348, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1127, 97, 67, 1569, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1448, 1449, 67, 1816, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1825, 67, 67, 1827, 97, 97, 0, 1781, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 1831, 0, 0, 97, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 1980, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1395, 45, 45, 45, 45, 45, 97, 1846, 97, 97, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1212, 45, 45, 45, 45, 45, 45, 2010, 45, 67, 67, 67, 67, 67, 2016, 67, 97, 97, 0, 0, 97, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 2007, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 143, 45, 45, 45, 1671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 1813, 67, 67, 1815, 45, 45, 67, 210, 67, 67, 67, 67, 67, 67, 239, 67, 67, 67, 67, 67, 67, 67, 1454, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1445, 67, 67, 67, 67, 67, 67, 97, 97, 290, 97, 97, 97, 97, 97, 97, 319, 97, 97, 97, 97, 97, 97, 303, 97, 97, 317, 97, 97, 97, 97, 97, 97, 305, 97, 97, 97, 97, 97, 97, 97, 97, 97, 899, 97, 97, 97, 97, 97, 97, 375, 45, 45, 45, 379, 45, 45, 390, 45, 45, 394, 45, 45, 45, 45, 45, 443, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 461, 67, 67, 67, 465, 67, 67, 476, 67, 67, 480, 67, 67, 67, 67, 67, 67, 1694, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1288, 67, 67, 67, 67, 67, 67, 500, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1075, 97, 97, 97, 558, 97, 97, 97, 562, 97, 97, 573, 97, 97, 577, 97, 97, 97, 97, 97, 895, 97, 97, 97, 97, 97, 97, 903, 97, 97, 97, 0, 97, 97, 1638, 97, 97, 97, 97, 97, 97, 97, 97, 1646, 597, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1334, 45, 681, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1396, 45, 45, 1399, 45, 45, 730, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1434, 67, 67, 67, 67, 67, 67, 750, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1456, 67, 67, 67, 67, 67, 45, 45, 993, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1238, 67, 67, 1006, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1280, 1048, 1049, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1059, 67, 67, 67, 67, 67, 67, 1286, 67, 67, 67, 67, 67, 67, 67, 1291, 67, 97, 97, 1100, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 638, 0, 920, 97, 97, 1142, 1143, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1153, 97, 97, 97, 97, 97, 1158, 97, 97, 97, 1161, 97, 97, 97, 97, 1166, 97, 97, 97, 97, 97, 1325, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1328, 97, 97, 97, 97, 97, 97, 97, 45, 1218, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1678, 45, 45, 45, 67, 67, 67, 67, 67, 1269, 67, 67, 67, 67, 67, 67, 67, 67, 1278, 67, 67, 67, 67, 67, 67, 1761, 67, 67, 67, 67, 67, 67, 67, 67, 67, 530, 67, 67, 67, 67, 67, 67, 97, 97, 1349, 97, 97, 97, 97, 97, 97, 97, 97, 1358, 97, 97, 97, 97, 97, 97, 1623, 97, 97, 97, 97, 97, 97, 97, 97, 0, 921, 0, 0, 926, 0, 0, 0, 45, 45, 1411, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1754, 45, 45, 67, 67, 1301, 0, 1307, 0, 1313, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 21054, 97, 97, 97, 97, 67, 1757, 67, 67, 67, 1760, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1467, 67, 67, 67, 67, 67, 1778, 97, 0, 0, 97, 97, 97, 97, 97, 97, 0, 0, 97, 97, 0, 97, 97, 97, 97, 97, 1352, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1511, 97, 97, 97, 97, 97, 67, 67, 67, 67, 67, 1820, 67, 1822, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 97, 1933, 97, 1892, 97, 97, 97, 97, 97, 97, 1899, 45, 45, 45, 45, 45, 45, 45, 45, 1664, 45, 45, 45, 45, 45, 45, 45, 45, 1546, 45, 45, 45, 45, 45, 45, 45, 45, 1208, 45, 45, 45, 45, 45, 45, 45, 45, 1224, 45, 45, 45, 45, 45, 45, 45, 45, 673, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 1925, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 97, 623, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 307, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1796, 97, 45, 45, 45, 45, 45, 45, 45, 970, 45, 45, 45, 45, 45, 45, 45, 45, 1417, 45, 45, 45, 45, 45, 45, 45, 67, 1964, 67, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1721, 97, 97, 0, 0, 1997, 97, 0, 0, 2000, 97, 97, 0, 97, 97, 97, 97, 97, 45, 45, 45, 45, 733, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 803, 67, 67, 67, 67, 67, 0, 94242, 0, 0, 0, 38, 102439, 0, 0, 106538, 98347, 28809, 45, 45, 144, 45, 45, 45, 1805, 45, 1807, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 231, 67, 67, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 45, 45, 67, 211, 67, 67, 67, 67, 230, 234, 240, 244, 67, 67, 67, 67, 67, 67, 464, 67, 67, 67, 67, 67, 67, 479, 67, 67, 67, 260, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 97, 291, 97, 97, 97, 97, 310, 314, 320, 324, 97, 97, 97, 97, 97, 97, 1367, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1355, 97, 97, 97, 97, 97, 97, 1362, 340, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 360, 0, 362, 0, 365, 28809, 367, 139, 369, 45, 45, 45, 374, 67, 67, 460, 67, 67, 67, 67, 466, 67, 67, 67, 67, 67, 67, 67, 67, 801, 67, 67, 67, 67, 67, 67, 67, 67, 67, 487, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 498, 67, 67, 67, 67, 67, 67, 1772, 67, 67, 97, 97, 97, 97, 97, 97, 97, 0, 921, 922, 1175, 0, 0, 0, 0, 45, 67, 502, 67, 67, 67, 67, 67, 67, 67, 508, 67, 67, 67, 515, 517, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 0, 0, 1932, 97, 97, 0, 1999, 97, 97, 97, 0, 97, 97, 2004, 2005, 97, 45, 45, 45, 45, 1193, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 676, 45, 45, 45, 45, 67, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 552, 97, 97, 97, 97, 97, 1377, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 655, 45, 45, 45, 45, 45, 45, 45, 97, 97, 557, 97, 97, 97, 97, 563, 97, 97, 97, 97, 97, 97, 97, 97, 1135, 97, 97, 97, 97, 97, 97, 97, 97, 97, 584, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 595, 97, 97, 97, 97, 97, 911, 97, 97, 97, 97, 97, 97, 97, 638, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 97, 97, 97, 1319, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 1733, 97, 97, 97, 97, 97, 97, 1340, 97, 97, 97, 1343, 97, 97, 1345, 97, 1346, 97, 599, 97, 97, 97, 97, 97, 97, 97, 605, 97, 97, 97, 612, 614, 97, 97, 97, 97, 97, 1794, 97, 97, 97, 45, 45, 45, 45, 45, 45, 45, 1207, 45, 45, 45, 45, 45, 45, 1213, 45, 45, 745, 67, 67, 67, 67, 751, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1577, 67, 67, 67, 67, 67, 762, 67, 67, 67, 67, 766, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1765, 67, 67, 67, 67, 67, 777, 67, 67, 781, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1592, 1593, 67, 67, 97, 843, 97, 97, 97, 97, 849, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1510, 97, 97, 97, 97, 97, 97, 97, 860, 97, 97, 97, 97, 864, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1797, 45, 45, 45, 45, 1801, 45, 97, 875, 97, 97, 879, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1522, 97, 97, 97, 97, 97, 991, 45, 45, 45, 45, 996, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 215, 67, 67, 67, 67, 233, 67, 67, 67, 67, 251, 253, 1022, 67, 67, 67, 1026, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1035, 67, 67, 1038, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1458, 67, 67, 67, 67, 67, 1064, 67, 67, 67, 1067, 67, 67, 67, 67, 1072, 67, 67, 67, 67, 67, 67, 1296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2367488, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 1096, 0, 921, 29315, 0, 0, 0, 0, 928, 45, 45, 45, 45, 45, 934, 45, 45, 45, 164, 45, 45, 45, 45, 45, 45, 45, 45, 45, 198, 45, 45, 45, 378, 45, 45, 45, 45, 45, 45, 393, 45, 45, 45, 398, 45, 97, 97, 1116, 97, 97, 97, 1120, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1147, 1148, 97, 97, 97, 97, 97, 97, 97, 1129, 97, 97, 1132, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1626, 97, 97, 97, 97, 0, 45, 1178, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1185, 45, 45, 45, 45, 441, 45, 45, 45, 45, 45, 45, 451, 45, 45, 67, 67, 67, 67, 67, 227, 67, 67, 67, 67, 67, 67, 67, 67, 1260, 67, 67, 67, 1263, 67, 67, 1265, 1203, 45, 45, 1205, 45, 1206, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1216, 67, 1266, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1276, 67, 67, 67, 67, 67, 67, 492, 67, 67, 67, 67, 67, 67, 67, 67, 67, 471, 67, 67, 67, 67, 481, 67, 45, 1386, 45, 1389, 45, 45, 45, 45, 1394, 45, 45, 45, 1397, 45, 45, 45, 45, 995, 45, 997, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 1915, 67, 67, 67, 67, 67, 1422, 45, 45, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1433, 67, 1436, 67, 67, 67, 67, 1441, 67, 67, 67, 1444, 67, 67, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 281, 28809, 53531, 97, 97, 97, 97, 1494, 97, 97, 97, 1497, 97, 97, 97, 97, 97, 97, 97, 1368, 97, 97, 97, 97, 97, 97, 97, 97, 851, 97, 97, 97, 97, 97, 97, 97, 67, 67, 67, 1571, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 67, 67, 1583, 67, 67, 67, 67, 67, 67, 67, 67, 1591, 67, 67, 67, 67, 67, 67, 752, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1056, 67, 67, 67, 67, 67, 67, 97, 1634, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1125, 97, 97, 97, 1647, 97, 97, 97, 97, 97, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1183, 45, 45, 45, 45, 45, 45, 45, 45, 45, 409, 45, 45, 45, 45, 45, 45, 1658, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1668, 1712, 97, 97, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 0, 0, 1835, 97, 97, 97, 97, 0, 0, 0, 97, 97, 1844, 97, 97, 1726, 0, 97, 97, 97, 97, 97, 1732, 97, 1734, 97, 97, 97, 97, 97, 300, 97, 308, 97, 97, 97, 97, 97, 97, 97, 97, 866, 97, 97, 97, 97, 97, 97, 97, 67, 67, 67, 1758, 67, 67, 67, 1762, 67, 67, 67, 67, 67, 67, 67, 67, 1043, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1771, 67, 67, 67, 97, 97, 97, 97, 97, 1776, 97, 97, 97, 97, 297, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1108, 97, 97, 97, 97, 67, 67, 67, 1966, 97, 97, 97, 1970, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 97, 1720, 97, 97, 97, 97, 97, 0, 0, 97, 97, 97, 1837, 97, 0, 1840, 1841, 97, 97, 97, 1988, 45, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1994, 1995, 67, 97, 97, 97, 97, 97, 1103, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 917, 97, 97, 0, 0, 0, 67, 67, 265, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 345, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 131427, 0, 0, 0, 361, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 671, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 411, 45, 45, 414, 45, 45, 45, 45, 377, 45, 45, 45, 386, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1223, 45, 45, 45, 45, 45, 45, 45, 45, 45, 426, 45, 45, 433, 45, 45, 45, 67, 67, 67, 67, 67, 463, 67, 67, 67, 472, 67, 67, 67, 67, 67, 67, 67, 527, 67, 67, 67, 67, 67, 67, 537, 67, 540, 24850, 24850, 12564, 12564, 0, 57889, 0, 0, 0, 53531, 53531, 367, 286, 97, 97, 97, 97, 97, 1119, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1509, 97, 97, 97, 97, 97, 97, 97, 97, 564, 97, 97, 97, 97, 97, 97, 97, 637, 18, 131427, 0, 0, 0, 0, 0, 0, 362, 0, 0, 365, 29315, 367, 0, 921, 29315, 0, 0, 0, 927, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1234, 45, 45, 45, 45, 67, 67, 67, 67, 1240, 45, 697, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 708, 45, 45, 45, 45, 1221, 45, 45, 45, 45, 1225, 45, 45, 45, 45, 45, 45, 384, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1210, 45, 45, 45, 45, 45, 45, 67, 67, 795, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1470, 67, 67, 67, 67, 67, 67, 67, 815, 67, 67, 67, 67, 67, 67, 25398, 542, 13112, 544, 97, 97, 97, 893, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1164, 97, 97, 97, 67, 67, 67, 1025, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1687, 67, 67, 67, 67, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 0, 0, 0, 1097, 1241, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1450, 45, 45, 1388, 45, 1390, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1236, 67, 67, 67, 67, 67, 1437, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1472, 1490, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1503, 67, 67, 67, 67, 67, 97, 97, 97, 97, 97, 0, 1930, 0, 97, 97, 97, 97, 97, 847, 97, 97, 97, 97, 97, 97, 97, 97, 97, 858, 67, 67, 1965, 67, 97, 97, 97, 97, 0, 0, 0, 97, 97, 97, 97, 0, 97, 97, 1719, 97, 97, 97, 97, 97, 97, 0, 0, 0, 45, 45, 45, 45, 1382, 45, 1383, 45, 45, 45, 159, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1563, 45, 45, 45, 45, 45, 67, 261, 67, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 341, 97, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 97, 1099, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1333, 97, 1230, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 67, 1992, 67, 1993, 67, 67, 67, 97, 97, 45, 45, 160, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1665, 45, 45, 45, 45, 45, 131427, 357, 0, 0, 0, 362, 0, 365, 28809, 367, 139, 45, 45, 45, 45, 45, 684, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 412, 45, 45, 45, 416, 45, 45, 45, 440, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 67, 67, 1990, 67, 1991, 67, 67, 67, 67, 67, 67, 67, 97, 97, 1707, 97, 97, 97, 97, 97, 97, 501, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1691, 67, 67, 67, 67, 67, 526, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1030, 67, 1032, 67, 67, 67, 67, 598, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1632, 0, 921, 29315, 923, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1404, 45, 45, 45, 45, 45, 45, 45, 45, 45, 425, 45, 45, 45, 45, 45, 45, 67, 67, 67, 67, 67, 25398, 0, 13112, 0, 54074, 0, 0, 1093, 0, 0, 0, 0, 0, 97, 1609, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1369, 97, 97, 97, 1372, 97, 97, 67, 67, 266, 67, 67, 67, 67, 0, 24850, 12564, 0, 0, 0, 0, 28809, 53531, 97, 346, 97, 97, 97, 97, 0, 40976, 0, 18, 18, 24, 24, 27, 27, 27, 665, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1677, 45, 45, 45, 45, 67, 45, 45, 954, 45, 956, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1545, 45, 45, 45, 45, 45, 45, 45, 45, 45, 448, 45, 45, 45, 45, 67, 456, 67, 67, 67, 67, 67, 1270, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1069, 67, 67, 67, 67, 67, 67, 97, 97, 97, 1350, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1524, 97, 97, 97, 97, 97, 97, 97, 1376, 0, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 1559, 1561, 45, 45, 45, 1564, 45, 1566, 1567, 45, 67, 67, 67, 67, 67, 1573, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 1247, 67, 67, 67, 67, 67, 1252, 97, 1725, 97, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1628, 97, 1630, 0, 0, 94242, 0, 0, 0, 2211840, 0, 1118208, 0, 0, 0, 0, 2158592, 2158731, 2158592, 2158592, 2158592, 3117056, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3018752, 2158592, 3043328, 2158592, 2158592, 2158592, 2158592, 3080192, 2158592, 2158592, 3112960, 2158592, 2158592, 2158592, 2158592, 2158592, 2158878, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2605056, 2158592, 2158592, 2207744, 0, 542, 0, 544, 0, 0, 2166784, 0, 0, 0, 550, 0, 0, 2158592, 2158592, 2686976, 2158592, 2715648, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2867200, 2158592, 2904064, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 0, 94242, 0, 0, 0, 2211840, 0, 0, 1130496, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 3186688, 2158592, 0, 0, 139, 0, 0, 0, 139, 0, 2367488, 2207744, 0, 0, 0, 0, 176128, 0, 2166784, 0, 0, 0, 0, 0, 286, 2158592, 2158592, 3170304, 3174400, 2158592, 0, 0, 0, 2158592, 2158592, 2158592, 2158592, 2158592, 2424832, 2158592, 2158592, 2158592, 1508, 2158592, 2908160, 2158592, 2158592, 2158592, 2977792, 2158592, 2158592, 2158592, 2158592, 3039232, 2158592, 2158592, 2158592, 2158592, 2158592, 2158592, 3158016, 67, 24850, 24850, 12564, 12564, 0, 0, 0, 0, 0, 53531, 53531, 0, 286, 97, 97, 97, 97, 97, 1144, 97, 97, 97, 97, 97, 97, 97, 97, 97, 97, 1149, 97, 97, 97, 97, 1154, 57889, 0, 0, 0, 0, 550, 0, 97, 97, 97, 97, 97, 97, 97, 97, 97, 561, 97, 97, 97, 97, 97, 97, 576, 97, 97, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 139264, 0, 0, 139264, 0, 921, 29315, 0, 0, 926, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 719, 720, 45, 45, 45, 45, 45, 45, 45, 45, 685, 45, 45, 45, 45, 45, 45, 45, 45, 45, 942, 45, 45, 946, 45, 45, 45, 950, 45, 45, 0, 2146304, 2146304, 0, 0, 0, 0, 2224128, 2224128, 2224128, 2232320, 2232320, 2232320, 2232320, 0, 0, 1301, 0, 0, 0, 0, 0, 1307, 0, 0, 0, 0, 0, 1313, 0, 0, 0, 0, 0, 0, 0, 97, 97, 1318, 97, 97, 97, 97, 97, 97, 1795, 97, 97, 45, 45, 45, 45, 45, 45, 45, 446, 45, 45, 45, 45, 45, 45, 67, 67, 2158592, 2146304, 0, 0, 0, 0, 0, 0, 0, 2211840, 0, 0, 0, 0, 2158592, 0, 921, 29315, 0, 924, 0, 0, 45, 45, 45, 45, 45, 45, 45, 45, 45, 1000, 45, 45, 45, 45, 67, 67
+];
+
+XQueryTokenizer.EXPECTED =
+[ 290, 300, 304, 353, 296, 309, 305, 319, 315, 324, 328, 352, 354, 334, 338, 330, 320, 345, 349, 293, 358, 362, 341, 366, 312, 370, 374, 378, 382, 386, 390, 394, 398, 737, 402, 634, 439, 604, 634, 634, 634, 634, 408, 634, 634, 634, 404, 634, 634, 634, 457, 634, 634, 963, 634, 634, 413, 634, 634, 634, 634, 634, 634, 634, 663, 418, 422, 903, 902, 426, 431, 548, 634, 437, 521, 919, 443, 615, 409, 449, 455, 624, 731, 751, 634, 461, 465, 672, 470, 469, 474, 481, 485, 477, 489, 493, 629, 542, 497, 505, 603, 602, 991, 648, 510, 804, 634, 515, 958, 526, 525, 530, 768, 634, 546, 552, 711, 710, 593, 558, 562, 618, 566, 570, 574, 578, 582, 586, 590, 608, 612, 660, 822, 821, 634, 622, 596, 444, 628, 533, 724, 633, 640, 653, 647, 652, 536, 1008, 451, 450, 445, 657, 670, 676, 685, 689, 693, 697, 701, 704, 707, 715, 719, 798, 815, 634, 723, 762, 996, 634, 728, 969, 730, 735, 908, 634, 741, 679, 889, 511, 747, 634, 750, 755, 499, 666, 499, 501, 759, 772, 776, 780, 634, 787, 784, 797, 802, 809, 808, 427, 814, 1006, 517, 634, 519, 853, 634, 813, 850, 793, 634, 819, 826, 833, 832, 837, 843, 847, 857, 861, 863, 867, 871, 875, 879, 883, 643, 887, 539, 980, 979, 634, 893, 944, 634, 900, 896, 634, 907, 933, 506, 912, 917, 828, 433, 636, 635, 554, 961, 923, 930, 927, 937, 941, 634, 634, 634, 974, 948, 952, 985, 913, 968, 967, 743, 634, 973, 839, 634, 978, 599, 634, 984, 989, 765, 444, 995, 1000, 634, 1003, 790, 955, 1012, 681, 634, 634, 634, 634, 634, 414, 1016, 1020, 1024, 1085, 1027, 1090, 1090, 1046, 1080, 1137, 1108, 1215, 1049, 1032, 1039, 1085, 1085, 1085, 1085, 1058, 1062, 1068, 1085, 1086, 1090, 1090, 1091, 1072, 1064, 1107, 1090, 1090, 1090, 1118, 1123, 1138, 1078, 1074, 1084, 1085, 1085, 1085, 1087, 1090, 1062, 1052, 1060, 1114, 1062, 1104, 1085, 1085, 1090, 1090, 1028, 1122, 1063, 1128, 1139, 1127, 1158, 1085, 1085, 1151, 1090, 1090, 1090, 1095, 1090, 1132, 1073, 1136, 1143, 1061, 1150, 1085, 1155, 1098, 1101, 1146, 1162, 1169, 1101, 1185, 1151, 1090, 1110, 1173, 1054, 1087, 1109, 1177, 1165, 1089, 1204, 1184, 1107, 1189, 1193, 1088, 1197, 1180, 1201, 1208, 1042, 1212, 1219, 1223, 1227, 1231, 1235, 1245, 1777, 1527, 1686, 1686, 1238, 1686, 1254, 1686, 1686, 1686, 1294, 1669, 1686, 1686, 1686, 1322, 1625, 1534, 1268, 1624, 1275, 1281, 1443, 1292, 1300, 1686, 1686, 1686, 1350, 1826, 1306, 1686, 1686, 1240, 2032, 1317, 1321, 1686, 1686, 1253, 1686, 1326, 1686, 1686, 1686, 1418, 1709, 1446, 1686, 1686, 1686, 1492, 1686, 1295, 1447, 1686, 1686, 1258, 1686, 1736, 1686, 1686, 1520, 1355, 1686, 1288, 1348, 1361, 1686, 1359, 1686, 1364, 1498, 1368, 1302, 1362, 1381, 1389, 1395, 1486, 1686, 1371, 1377, 1370, 1686, 1375, 1382, 1384, 1402, 1408, 1385, 1383, 1619, 1413, 1423, 1428, 1433, 1686, 1686, 1270, 1686, 1338, 1686, 1440, 1686, 1686, 1686, 1499, 1465, 1686, 1686, 1686, 1639, 1473, 1884, 1686, 1686, 1293, 1864, 1686, 1686, 1296, 1321, 1483, 1686, 1686, 1686, 1646, 1686, 1748, 1496, 1686, 1418, 1675, 1686, 1418, 1702, 1686, 1418, 1981, 1686, 1429, 1409, 1427, 1504, 1692, 1686, 1686, 1313, 1448, 1651, 1508, 1686, 1686, 1340, 1686, 1903, 1686, 1686, 1435, 1513, 1686, 1283, 1287, 1519, 1686, 1524, 1363, 1568, 1938, 1539, 1566, 1579, 1479, 1533, 1538, 1553, 1544, 1552, 1557, 1563, 1574, 1557, 1583, 1589, 1590, 1759, 1594, 1603, 1607, 1611, 1686, 1436, 1514, 1686, 1434, 1656, 1686, 1434, 1680, 1686, 1453, 1686, 1686, 1686, 1559, 1617, 1686, 1770, 1418, 1623, 1769, 1629, 1686, 1515, 1335, 1686, 1285, 1686, 1671, 1921, 1650, 1686, 1686, 1344, 1308, 1666, 1686, 1686, 1686, 1659, 1685, 1686, 1686, 1686, 1686, 1241, 1686, 1686, 1844, 1691, 1686, 1630, 1977, 1970, 1362, 1686, 1686, 1686, 1693, 1698, 1686, 1686, 1686, 1697, 1686, 1764, 1715, 1686, 1634, 1638, 1686, 1599, 1585, 1686, 1271, 1686, 1269, 1686, 1721, 1686, 1686, 1354, 1686, 1801, 1686, 1799, 1686, 1640, 1686, 1686, 1461, 1686, 1686, 1732, 1686, 1944, 1686, 1740, 1686, 1746, 1415, 1396, 1686, 1598, 1547, 1417, 1597, 1416, 1577, 1546, 1397, 1577, 1547, 1548, 1570, 1398, 1753, 1686, 1652, 1509, 1686, 1686, 1686, 1757, 1686, 1419, 1686, 1763, 1418, 1768, 1781, 1686, 1686, 1686, 1705, 1686, 2048, 1792, 1686, 1686, 1686, 1735, 1686, 1797, 1686, 1686, 1404, 1686, 1639, 1815, 1686, 1686, 1418, 2017, 1820, 1686, 1686, 1803, 1686, 1686, 1686, 1736, 1489, 1686, 1686, 1825, 1338, 1260, 1263, 1686, 1686, 1785, 1686, 1686, 1728, 1686, 1686, 1749, 1497, 1830, 1830, 1262, 1248, 1261, 1329, 1260, 1264, 1329, 1248, 1249, 1259, 1540, 1849, 1842, 1686, 1686, 1835, 1686, 1686, 1816, 1686, 1686, 1831, 1882, 1848, 1686, 1686, 1686, 1774, 2071, 1854, 1686, 1686, 1469, 1884, 1686, 1821, 1859, 1686, 1686, 1350, 1883, 1686, 1686, 1686, 1781, 1391, 1875, 1686, 1686, 1613, 1644, 1686, 1686, 1889, 1686, 1686, 1662, 1884, 1686, 1885, 1890, 1686, 1686, 1686, 1894, 1686, 1686, 1678, 1686, 1907, 1686, 1686, 1529, 1914, 1686, 1838, 1686, 1686, 1881, 1686, 1686, 1872, 1876, 1836, 1919, 1686, 1837, 1692, 1910, 1686, 1925, 1928, 1742, 1686, 1811, 1811, 1930, 1810, 1929, 1935, 1928, 1900, 1942, 1867, 1868, 1931, 1035, 1788, 1948, 1952, 1956, 1960, 1964, 1686, 1976, 1686, 1686, 1686, 2065, 1686, 1992, 2037, 1686, 1686, 1998, 2009, 1972, 2002, 1686, 1686, 1686, 2077, 1300, 2023, 1686, 1686, 1686, 1807, 2031, 1686, 1686, 1686, 1860, 1500, 2032, 1686, 1686, 1686, 2083, 1686, 2036, 1686, 1277, 1276, 2042, 1877, 1686, 1686, 2041, 1686, 1686, 2027, 2037, 2012, 1686, 2012, 1855, 1850, 1686, 2046, 1686, 1686, 2054, 1996, 1686, 1897, 1309, 2059, 2052, 1686, 2058, 1686, 1686, 2081, 1686, 1717, 1477, 1686, 1331, 1686, 1686, 1687, 1686, 1860, 1681, 1686, 1686, 1686, 1966, 1724, 1686, 1686, 1686, 1984, 2015, 1686, 1686, 1686, 1988, 1686, 2063, 1686, 1686, 1686, 2005, 1686, 1727, 1686, 1686, 1711, 1457, 2069, 1686, 1686, 1686, 2019, 2075, 1686, 1686, 1915, 1686, 1686, 1793, 1874, 1686, 1686, 1491, 1362, 1449, 1686, 1686, 1460, 2098, 2087, 2091, 2095, 2184, 2102, 2113, 2780, 2117, 2134, 2142, 2281, 2146, 2146, 2146, 2304, 2296, 2181, 2639, 2591, 2872, 2592, 2873, 2313, 2195, 2200, 2281, 2146, 2273, 2226, 2204, 2152, 2219, 2276, 2167, 2177, 2276, 2235, 2276, 2276, 2230, 2281, 2276, 2296, 2276, 2293, 2276, 2276, 2276, 2276, 2234, 2276, 2311, 2314, 2210, 2199, 2217, 2222, 2276, 2276, 2276, 2240, 2276, 2294, 2276, 2276, 2173, 2276, 2198, 2281, 2281, 2281, 2281, 2282, 2146, 2146, 2146, 2146, 2205, 2146, 2204, 2248, 2276, 2235, 2276, 2297, 2276, 2276, 2276, 2277, 2256, 2281, 2283, 2146, 2146, 2146, 2275, 2276, 2295, 2276, 2276, 2293, 2146, 2304, 2264, 2269, 2221, 2276, 2276, 2276, 2293, 2295, 2276, 2276, 2276, 2295, 2263, 2205, 2268, 2220, 2172, 2276, 2276, 2276, 2296, 2276, 2276, 2296, 2294, 2276, 2276, 2278, 2281, 2281, 2280, 2281, 2281, 2281, 2283, 2206, 2223, 2276, 2276, 2279, 2281, 2281, 2146, 2273, 2276, 2276, 2281, 2281, 2281, 2276, 2292, 2276, 2298, 2225, 2276, 2298, 2169, 2224, 2292, 2298, 2171, 2229, 2281, 2281, 2171, 2236, 2281, 2281, 2281, 2146, 2275, 2225, 2292, 2299, 2276, 2229, 2281, 2146, 2276, 2290, 2297, 2283, 2146, 2146, 2274, 2224, 2227, 2298, 2225, 2297, 2276, 2230, 2170, 2230, 2282, 2146, 2147, 2151, 2156, 2288, 2276, 2230, 2303, 2308, 2236, 2284, 2228, 2318, 2318, 2318, 2326, 2335, 2339, 2343, 2349, 2416, 2693, 2357, 2592, 2109, 2592, 2592, 2162, 2943, 2823, 2646, 2592, 2361, 2592, 2122, 2592, 2592, 2122, 2470, 2592, 2592, 2592, 2109, 2107, 2592, 2592, 2592, 2123, 2592, 2592, 2592, 2125, 2592, 2413, 2592, 2592, 2592, 2127, 2592, 2592, 2414, 2592, 2592, 2592, 2130, 2952, 2592, 2594, 2592, 2592, 2212, 2609, 2252, 2592, 2592, 2592, 2446, 2434, 2592, 2592, 2592, 2212, 2446, 2450, 2456, 2431, 2435, 2592, 2592, 2243, 2478, 2448, 2439, 2946, 2592, 2592, 2592, 2368, 2809, 2813, 2450, 2441, 2212, 2812, 2449, 2440, 2947, 2592, 2592, 2592, 2345, 2451, 2457, 2948, 2592, 2124, 2592, 2592, 2650, 2823, 2449, 2455, 2946, 2592, 2128, 2592, 2592, 2649, 2952, 2592, 2810, 2448, 2461, 2991, 2467, 2592, 2592, 2329, 2817, 2474, 2990, 2466, 2592, 2592, 2373, 2447, 2992, 2469, 2592, 2592, 2592, 2373, 2447, 2477, 2468, 2592, 2592, 2353, 2469, 2592, 2495, 2592, 2592, 2415, 2483, 2592, 2415, 2496, 2592, 2592, 2352, 2592, 2592, 2352, 2352, 2469, 2592, 2592, 2363, 2331, 2494, 2592, 2592, 2592, 2375, 2592, 2375, 2415, 2504, 2592, 2592, 2367, 2372, 2503, 2592, 2592, 2592, 2389, 2418, 2415, 2592, 2592, 2373, 2592, 2592, 2592, 2593, 2732, 2417, 2415, 2592, 2417, 2520, 2592, 2592, 2592, 2390, 2521, 2521, 2592, 2592, 2592, 2401, 2599, 2585, 2526, 2531, 2120, 2592, 2212, 2426, 2450, 2463, 2948, 2592, 2592, 2592, 2213, 2389, 2527, 2532, 2121, 2542, 2551, 2105, 2592, 2213, 2592, 2592, 2592, 2558, 2538, 2544, 2553, 2557, 2537, 2543, 2552, 2421, 2572, 2576, 2546, 2543, 2547, 2592, 2592, 2373, 2615, 2575, 2545, 2105, 2592, 2244, 2479, 2592, 2129, 2592, 2592, 2628, 2690, 2469, 2562, 2566, 2592, 2592, 2592, 2415, 2928, 2934, 2401, 2570, 2574, 2564, 2572, 2585, 2590, 2592, 2592, 2585, 2965, 2592, 2592, 2592, 2445, 2251, 2592, 2592, 2592, 2474, 2592, 2609, 2892, 2592, 2362, 2592, 2592, 2138, 2851, 2159, 2592, 2592, 2592, 2509, 2888, 2892, 2592, 2592, 2592, 2490, 2418, 2891, 2592, 2592, 2376, 2592, 2592, 2374, 2592, 2889, 2388, 2592, 2373, 2373, 2890, 2592, 2592, 2387, 2592, 2887, 2505, 2892, 2592, 2373, 2610, 2388, 2592, 2592, 2376, 2373, 2592, 2887, 2891, 2592, 2374, 2592, 2592, 2608, 2159, 2614, 2620, 2592, 2592, 2394, 2594, 2887, 2399, 2592, 2887, 2397, 2508, 2374, 2507, 2592, 2375, 2592, 2592, 2592, 2595, 2508, 2506, 2592, 2506, 2505, 2505, 2592, 2507, 2637, 2505, 2592, 2592, 2401, 2661, 2592, 2643, 2592, 2592, 2417, 2592, 2655, 2592, 2592, 2592, 2510, 2414, 2656, 2592, 2592, 2592, 2516, 2592, 2593, 2660, 2665, 2880, 2592, 2592, 2592, 2522, 2767, 2666, 2881, 2592, 2592, 2420, 2571, 2696, 2592, 2592, 2592, 2580, 2572, 2686, 2632, 2698, 2592, 2383, 2514, 2592, 2163, 2932, 2465, 2685, 2631, 2697, 2592, 2388, 2592, 2592, 2212, 2604, 2671, 2632, 2678, 2592, 2401, 2405, 2409, 2592, 2592, 2592, 2679, 2592, 2592, 2592, 2592, 2108, 2677, 2591, 2592, 2592, 2592, 2419, 2592, 2683, 2187, 2191, 2469, 2671, 2189, 2467, 2592, 2401, 2629, 2633, 2702, 2468, 2592, 2592, 2421, 2536, 2703, 2469, 2592, 2592, 2422, 2573, 2593, 2672, 2467, 2592, 2402, 2406, 2592, 2402, 2979, 2592, 2592, 2626, 2673, 2467, 2592, 2446, 2259, 2947, 2592, 2377, 2709, 2592, 2592, 2522, 2862, 2713, 2468, 2592, 2592, 2581, 2572, 2562, 2374, 2374, 2592, 2376, 2721, 2724, 2592, 2592, 2624, 2373, 2731, 2592, 2592, 2592, 2626, 2732, 2592, 2592, 2592, 2755, 2656, 2726, 2736, 2741, 2592, 2486, 2593, 2381, 2592, 2727, 2737, 2742, 2715, 2747, 2753, 2592, 2498, 2469, 2873, 2743, 2592, 2592, 2592, 2791, 2759, 2763, 2592, 2592, 2627, 2704, 2592, 2592, 2522, 2789, 2593, 2761, 2753, 2592, 2498, 2863, 2592, 2592, 2767, 2592, 2592, 2592, 2792, 2789, 2592, 2592, 2592, 2803, 2126, 2592, 2592, 2592, 2811, 2122, 2592, 2592, 2592, 2834, 2777, 2592, 2592, 2592, 2848, 2936, 2591, 2489, 2797, 2592, 2592, 2670, 2631, 2490, 2798, 2592, 2592, 2592, 2963, 2807, 2592, 2592, 2592, 2965, 2838, 2592, 2592, 2592, 2975, 2330, 2818, 2829, 2592, 2498, 2939, 2592, 2498, 2592, 2791, 2331, 2819, 2830, 2592, 2592, 2592, 2982, 2834, 2817, 2828, 2106, 2592, 2592, 2592, 2405, 2405, 2817, 2828, 2592, 2592, 2415, 2849, 2842, 2592, 2522, 2773, 2592, 2522, 2868, 2592, 2580, 2600, 2586, 2137, 2850, 2843, 2592, 2592, 2855, 2937, 2844, 2592, 2592, 2592, 2987, 2936, 2591, 2592, 2592, 2684, 2630, 2592, 2856, 2938, 2592, 2592, 2860, 2939, 2592, 2592, 2872, 2592, 2861, 2591, 2592, 2592, 2887, 2616, 2592, 2867, 2592, 2592, 2708, 2592, 2498, 2469, 2498, 2497, 2785, 2773, 2499, 2783, 2770, 2877, 2877, 2877, 2772, 2592, 2592, 2345, 2885, 2592, 2592, 2592, 2715, 2762, 2515, 2896, 2592, 2592, 2715, 2917, 2516, 2897, 2592, 2592, 2592, 2901, 2906, 2911, 2592, 2592, 2956, 2960, 2715, 2902, 2907, 2912, 2593, 2916, 2920, 2820, 2922, 2822, 2592, 2592, 2715, 2927, 2921, 2821, 2106, 2592, 2592, 2974, 2408, 2321, 2821, 2106, 2592, 2592, 2983, 2592, 2593, 2404, 2408, 2592, 2592, 2717, 2749, 2716, 2928, 2322, 2822, 2593, 2926, 2919, 2820, 2934, 2823, 2592, 2592, 2592, 2651, 2824, 2592, 2592, 2592, 2130, 2952, 2592, 2592, 2592, 2592, 2964, 2592, 2592, 2716, 2748, 2592, 2969, 2592, 2592, 2716, 2918, 2368, 2970, 2592, 2592, 2592, 2403, 2407, 2592, 2592, 2787, 2211, 2404, 2409, 2592, 2592, 2802, 2837, 2987, 2592, 2592, 2592, 2809, 2427, 2592, 2793, 2592, 2592, 2809, 2447, 1073741824, 0x80000000, 539754496, 542375936, 402653184, 554434560, 571736064, 545521856, 268451840, 335544320, 268693630, 512, 2048, 256, 1024, 0, 1024, 0, 1073741824, 0x80000000, 0, 0, 0, 8388608, 0, 0, 1073741824, 1073741824, 0, 0x80000000, 537133056, 4194304, 1048576, 268435456, -1073741824, 0, 0, 0, 1048576, 0, 0, 0, 1572864, 0, 0, 0, 4194304, 0, 134217728, 16777216, 0, 0, 32, 64, 98304, 0, 33554432, 8388608, 192, 67108864, 67108864, 67108864, 67108864, 16, 32, 4, 0, 8192, 196608, 196608, 229376, 80, 4096, 524288, 8388608, 0, 0, 32, 128, 256, 24576, 24600, 24576, 24576, 2, 24576, 24576, 24576, 24584, 24592, 24576, 24578, 24576, 24578, 24576, 24576, 16, 512, 2048, 2048, 256, 4096, 32768, 1048576, 4194304, 67108864, 134217728, 268435456, 262144, 134217728, 0, 128, 128, 64, 16384, 16384, 16384, 67108864, 32, 32, 4, 4, 4096, 262144, 134217728, 0, 0, 0, 2, 0, 8192, 131072, 131072, 4096, 4096, 4096, 4096, 24576, 24576, 24576, 8, 8, 24576, 24576, 16384, 16384, 16384, 24576, 24584, 24576, 24576, 24576, 16384, 24576, 536870912, 262144, 0, 0, 32, 2048, 8192, 4, 4096, 4096, 4096, 786432, 8388608, 16777216, 0, 128, 16384, 16384, 16384, 32768, 65536, 2097152, 32, 32, 32, 32, 4, 4, 4, 4, 4, 4096, 67108864, 67108864, 67108864, 24576, 24576, 24576, 24576, 0, 16384, 16384, 16384, 16384, 67108864, 67108864, 8, 67108864, 24576, 8, 8, 8, 24576, 24576, 24576, 24578, 24576, 24576, 24576, 2, 2, 2, 16384, 67108864, 67108864, 67108864, 32, 67108864, 8, 8, 24576, 2048, 0x80000000, 536870912, 262144, 262144, 262144, 67108864, 8, 24576, 16384, 32768, 1048576, 4194304, 25165824, 67108864, 24576, 32770, 2, 4, 112, 512, 98304, 524288, 50, 402653186, 1049090, 1049091, 10, 66, 100925514, 10, 66, 12582914, 0, 0, -1678194207, -1678194207, -1041543218, 0, 32768, 0, 0, 32, 65536, 268435456, 1, 1, 513, 1048577, 0, 12582912, 0, 0, 0, 4, 1792, 0, 0, 0, 7, 29360128, 0, 0, 0, 8, 0, 0, 0, 12, 1, 1, 0, 0, -604102721, -604102721, 4194304, 8388608, 0, 0, 0, 31, 925600, 997981306, 997981306, 997981306, 0, 0, 2048, 8388608, 0, 0, 1, 2, 4, 32, 64, 512, 8192, 0, 0, 0, 245760, 997720064, 0, 0, 0, 32, 0, 0, 0, 3, 12, 16, 32, 8, 112, 3072, 12288, 16384, 32768, 65536, 131072, 7864320, 16777216, 973078528, 0, 0, 65536, 131072, 3670016, 4194304, 16777216, 33554432, 2, 8, 48, 2048, 8192, 16384, 32768, 65536, 131072, 524288, 131072, 524288, 3145728, 4194304, 16777216, 33554432, 65536, 131072, 2097152, 4194304, 16777216, 33554432, 134217728, 268435456, 536870912, 0, 0, 0, 1024, 0, 8, 48, 2048, 8192, 65536, 33554432, 268435456, 536870912, 65536, 268435456, 536870912, 0, 0, 32768, 0, 0, 126, 623104, 65011712, 0, 32, 65536, 536870912, 0, 0, 65536, 524288, 0, 32, 65536, 0, 0, 0, 2048, 0, 0, 0, 15482, 245760, -604102721, 0, 0, 0, 18913, 33062912, 925600, -605028352, 0, 0, 0, 65536, 31, 8096, 131072, 786432, 3145728, 3145728, 12582912, 50331648, 134217728, 268435456, 160, 256, 512, 7168, 131072, 786432, 131072, 786432, 1048576, 2097152, 12582912, 16777216, 268435456, 1073741824, 0x80000000, 12582912, 16777216, 33554432, 268435456, 1073741824, 0x80000000, 3, 12, 16, 160, 256, 7168, 786432, 1048576, 12582912, 16777216, 268435456, 1073741824, 0, 8, 16, 32, 128, 256, 512, 7168, 786432, 1048576, 2097152, 0, 1, 2, 8, 16, 7168, 786432, 1048576, 8388608, 16777216, 16777216, 1073741824, 0, 0, 0, 0, 1, 0, 0, 8, 32, 128, 256, 7168, 8, 32, 0, 3072, 0, 8, 32, 3072, 4096, 524288, 8, 32, 0, 0, 3072, 4096, 0, 2048, 524288, 8388608, 8, 2048, 0, 0, 1, 12, 256, 4096, 32768, 262144, 1048576, 4194304, 67108864, 0, 2048, 0, 2048, 2048, 1073741824, -58805985, -58805985, -58805985, 0, 0, 262144, 0, 0, 32, 4194304, 16777216, 134217728, 4382, 172032, -58982400, 0, 0, 2, 28, 256, 4096, 8192, 8192, 32768, 131072, 262144, 524288, 1, 2, 12, 256, 4096, 0, 0, 4194304, 67108864, 134217728, 805306368, 1073741824, 0, 0, 1, 2, 12, 16, 256, 4096, 1048576, 67108864, 134217728, 268435456, 0, 512, 1048576, 4194304, 201326592, 1879048192, 0, 0, 12, 256, 4096, 134217728, 268435456, 536870912, 12, 256, 268435456, 536870912, 0, 12, 256, 0, 0, 1, 32, 64, 512, 0, 0, 205236961, 205236961, 0, 0, 0, 1, 96, 640, 1, 10976, 229376, 204996608, 0, 640, 2048, 8192, 229376, 1572864, 1572864, 2097152, 201326592, 0, 0, 0, 64, 512, 2048, 229376, 1572864, 201326592, 1572864, 201326592, 0, 0, 1, 4382, 0, 1, 32, 2048, 65536, 131072, 1572864, 201326592, 131072, 1572864, 134217728, 0, 0, 524288, 524288, 0, 0, 0, -68582786, -68582786, -68582786, 0, 0, 2097152, 524288, 0, 524288, 0, 0, 65536, 131072, 1572864, 0, 0, 2, 4, 0, 0, 65011712, -134217728, 0, 0, 0, 0, 2, 4, 120, 512, -268435456, 0, 0, 0, 2, 8, 48, 64, 2048, 8192, 98304, 524288, 2097152, 4194304, 25165824, 33554432, 134217728, 268435456, 0x80000000, 0, 0, 25165824, 33554432, 134217728, 1879048192, 0x80000000, 0, 0, 4, 112, 512, 622592, 65011712, 134217728, -268435456, 16777216, 33554432, 134217728, 1610612736, 0, 0, 0, 64, 98304, 524288, 4194304, 16777216, 33554432, 0, 98304, 524288, 16777216, 33554432, 0, 65536, 524288, 33554432, 536870912, 1073741824, 0, 65536, 524288, 536870912, 1073741824, 0, 0, 65536, 524288, 536870912, 0, 524288, 0, 524288, 524288, 1048576, 2086666240, 0x80000000, 0, -1678194207, 0, 0, 0, 8, 32, 2048, 524288, 8388608, 0, 0, 33062912, 436207616, 0x80000000, 0, 0, 32, 64, 2432, 16384, 32768, 32768, 524288, 3145728, 4194304, 25165824, 25165824, 167772160, 268435456, 0x80000000, 0, 32, 64, 384, 2048, 16384, 32768, 1048576, 2097152, 4194304, 25165824, 32, 64, 128, 256, 2048, 16384, 2048, 16384, 1048576, 4194304, 16777216, 33554432, 134217728, 536870912, 1073741824, 0, 0, 2048, 16384, 4194304, 16777216, 33554432, 134217728, 805306368, 0, 0, 16777216, 134217728, 268435456, 0x80000000, 0, 622592, 622592, 622592, 8807, 8807, 434791, 0, 0, 16777216, 0, 0, 0, 7, 608, 8192, 0, 0, 0, 3, 4, 96, 512, 32, 64, 8192, 0, 0, 16777216, 134217728, 0, 0, 2, 4, 8192, 16384, 65536, 2097152, 33554432, 268435456
+];
+
+XQueryTokenizer.TOKEN =
+[
+ "(0)",
+ "ModuleDecl",
+ "Annotation",
+ "OptionDecl",
+ "Operator",
+ "Variable",
+ "Tag",
+ "EndTag",
+ "PragmaContents",
+ "DirCommentContents",
+ "DirPIContents",
+ "CDataSectionContents",
+ "AttrTest",
+ "Wildcard",
+ "EQName",
+ "IntegerLiteral",
+ "DecimalLiteral",
+ "DoubleLiteral",
+ "PredefinedEntityRef",
+ "'\"\"'",
+ "EscapeApos",
+ "QuotChar",
+ "AposChar",
+ "ElementContentChar",
+ "QuotAttrContentChar",
+ "AposAttrContentChar",
+ "NCName",
+ "QName",
+ "S",
+ "CharRef",
+ "CommentContents",
+ "DocTag",
+ "DocCommentContents",
+ "EOF",
+ "'!'",
+ "'\"'",
+ "'#'",
+ "'#)'",
+ "''''",
+ "'('",
+ "'(#'",
+ "'(:'",
+ "'(:~'",
+ "')'",
+ "'*'",
+ "'*'",
+ "','",
+ "'-->'",
+ "'.'",
+ "'/'",
+ "'/>'",
+ "':'",
+ "':)'",
+ "';'",
+ "'<!--'",
+ "'<![CDATA['",
+ "'<?'",
+ "'='",
+ "'>'",
+ "'?'",
+ "'?>'",
+ "'NaN'",
+ "'['",
+ "']'",
+ "']]>'",
+ "'after'",
+ "'all'",
+ "'allowing'",
+ "'ancestor'",
+ "'ancestor-or-self'",
+ "'and'",
+ "'any'",
+ "'append'",
+ "'array'",
+ "'as'",
+ "'ascending'",
+ "'at'",
+ "'attribute'",
+ "'base-uri'",
+ "'before'",
+ "'boundary-space'",
+ "'break'",
+ "'by'",
+ "'case'",
+ "'cast'",
+ "'castable'",
+ "'catch'",
+ "'check'",
+ "'child'",
+ "'collation'",
+ "'collection'",
+ "'comment'",
+ "'constraint'",
+ "'construction'",
+ "'contains'",
+ "'content'",
+ "'context'",
+ "'continue'",
+ "'copy'",
+ "'copy-namespaces'",
+ "'count'",
+ "'decimal-format'",
+ "'decimal-separator'",
+ "'declare'",
+ "'default'",
+ "'delete'",
+ "'descendant'",
+ "'descendant-or-self'",
+ "'descending'",
+ "'diacritics'",
+ "'different'",
+ "'digit'",
+ "'distance'",
+ "'div'",
+ "'document'",
+ "'document-node'",
+ "'element'",
+ "'else'",
+ "'empty'",
+ "'empty-sequence'",
+ "'encoding'",
+ "'end'",
+ "'entire'",
+ "'eq'",
+ "'every'",
+ "'exactly'",
+ "'except'",
+ "'exit'",
+ "'external'",
+ "'first'",
+ "'following'",
+ "'following-sibling'",
+ "'for'",
+ "'foreach'",
+ "'foreign'",
+ "'from'",
+ "'ft-option'",
+ "'ftand'",
+ "'ftnot'",
+ "'ftor'",
+ "'function'",
+ "'ge'",
+ "'greatest'",
+ "'group'",
+ "'grouping-separator'",
+ "'gt'",
+ "'idiv'",
+ "'if'",
+ "'import'",
+ "'in'",
+ "'index'",
+ "'infinity'",
+ "'inherit'",
+ "'insensitive'",
+ "'insert'",
+ "'instance'",
+ "'integrity'",
+ "'intersect'",
+ "'into'",
+ "'is'",
+ "'item'",
+ "'json'",
+ "'json-item'",
+ "'key'",
+ "'language'",
+ "'last'",
+ "'lax'",
+ "'le'",
+ "'least'",
+ "'let'",
+ "'levels'",
+ "'loop'",
+ "'lowercase'",
+ "'lt'",
+ "'minus-sign'",
+ "'mod'",
+ "'modify'",
+ "'module'",
+ "'most'",
+ "'namespace'",
+ "'namespace-node'",
+ "'ne'",
+ "'next'",
+ "'no'",
+ "'no-inherit'",
+ "'no-preserve'",
+ "'node'",
+ "'nodes'",
+ "'not'",
+ "'object'",
+ "'occurs'",
+ "'of'",
+ "'on'",
+ "'only'",
+ "'option'",
+ "'or'",
+ "'order'",
+ "'ordered'",
+ "'ordering'",
+ "'paragraph'",
+ "'paragraphs'",
+ "'parent'",
+ "'pattern-separator'",
+ "'per-mille'",
+ "'percent'",
+ "'phrase'",
+ "'position'",
+ "'preceding'",
+ "'preceding-sibling'",
+ "'preserve'",
+ "'previous'",
+ "'processing-instruction'",
+ "'relationship'",
+ "'rename'",
+ "'replace'",
+ "'return'",
+ "'returning'",
+ "'revalidation'",
+ "'same'",
+ "'satisfies'",
+ "'schema'",
+ "'schema-attribute'",
+ "'schema-element'",
+ "'score'",
+ "'self'",
+ "'sensitive'",
+ "'sentence'",
+ "'sentences'",
+ "'skip'",
+ "'sliding'",
+ "'some'",
+ "'stable'",
+ "'start'",
+ "'stemming'",
+ "'stop'",
+ "'strict'",
+ "'strip'",
+ "'structured-item'",
+ "'switch'",
+ "'text'",
+ "'then'",
+ "'thesaurus'",
+ "'times'",
+ "'to'",
+ "'treat'",
+ "'try'",
+ "'tumbling'",
+ "'type'",
+ "'typeswitch'",
+ "'union'",
+ "'unique'",
+ "'unordered'",
+ "'updating'",
+ "'uppercase'",
+ "'using'",
+ "'validate'",
+ "'value'",
+ "'variable'",
+ "'version'",
+ "'weight'",
+ "'when'",
+ "'where'",
+ "'while'",
+ "'wildcards'",
+ "'window'",
+ "'with'",
+ "'without'",
+ "'word'",
+ "'words'",
+ "'xquery'",
+ "'zero-digit'",
+ "'{'",
+ "'{{'",
+ "'|'",
+ "'}'",
+ "'}}'"
+];
+
+},{}],"/node_modules/xqlint/lib/lexers/jsoniq_lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var JSONiqTokenizer = _dereq_('./JSONiqTokenizer').JSONiqTokenizer;
+var Lexer = _dereq_('./lexer').Lexer;
+
+var keys = 'NaN|after|allowing|ancestor|ancestor-or-self|and|append|array|as|ascending|at|attribute|base-uri|before|boundary-space|break|by|case|cast|castable|catch|child|collation|comment|constraint|construction|contains|context|continue|copy|copy-namespaces|count|decimal-format|decimal-separator|declare|default|delete|descendant|descendant-or-self|descending|digit|div|document|document-node|element|else|empty|empty-sequence|encoding|end|eq|every|except|exit|external|false|first|following|following-sibling|for|from|ft-option|function|ge|greatest|group|grouping-separator|gt|idiv|if|import|in|index|infinity|insert|instance|integrity|intersect|into|is|item|json|json-item|jsoniq|last|lax|le|least|let|loop|lt|minus-sign|mod|modify|module|namespace|namespace-node|ne|next|node|nodes|not|null|object|of|only|option|or|order|ordered|ordering|paragraphs|parent|pattern-separator|per-mille|percent|preceding|preceding-sibling|previous|processing-instruction|rename|replace|return|returning|revalidation|satisfies|schema|schema-attribute|schema-element|score|select|self|sentences|sliding|some|stable|start|strict|switch|text|then|times|to|treat|true|try|tumbling|type|typeswitch|union|unordered|updating|validate|value|variable|version|when|where|while|window|with|words|xquery|zero-digit'.split('|');
+var keywords = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'keyword' }; });
+var ncnames = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'text', next: function(stack){ stack.pop(); } }; });
+
+var cdata = 'constant.language';
+var number = 'constant';
+var xmlcomment = 'comment';
+var pi = 'xml-pe';
+var pragma = 'constant.buildin';
+var n = function(name){
+ return '\'' + name + '\'';
+};
+var Rules = {
+ start: [
+ { name: n('(#'), token: pragma, next: function(stack){ stack.push('Pragma'); } },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n('(:~'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: n('<?'), token: pi, next: function(stack) { stack.push('PI'); } },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposString'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotString'); } },
+ { name: 'Annotation', token: 'support.function' },
+ { name: 'ModuleDecl', token: 'keyword', next: function(stack){ stack.push('Prefix'); } },
+ { name: 'OptionDecl', token: 'keyword', next: function(stack){ stack.push('_EQName'); } },
+ { name: 'AttrTest', token: 'support.type' },
+ { name: 'Variable', token: 'variable' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: 'IntegerLiteral', token: number },
+ { name: 'DecimalLiteral', token: number },
+ { name: 'DoubleLiteral', token: number },
+ { name: 'Operator', token: 'keyword.operator' },
+ { name: 'EQName', token: function(val) { return keys.indexOf(val) !== -1 ? 'keyword' : 'support.function'; } },
+ { name: n('('), token: 'lparen' },
+ { name: n(')'), token: 'rparen' },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: n('}'), token: 'text', next: function(stack){ if(stack.length > 1) { stack.pop(); } } },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } } //, next: function(stack){ if(stack.length > 1) { stack.pop(); } } }
+ ].concat(keywords),
+ _EQName: [
+ { name: 'EQName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ Prefix: [
+ { name: 'NCName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ StartTag: [
+ { name: n('>'), token: 'meta.tag', next: function(stack){ stack.push('TagContent'); } },
+ { name: 'QName', token: 'entity.other.attribute-name' },
+ { name: n('='), token: 'text' },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposAttr'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotAttr'); } },
+ { name: n('/>'), token: 'meta.tag.r', next: function(stack){ stack.pop(); } }
+ ],
+ TagContent: [
+ { name: 'ElementContentChar', token: 'text' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'text' },
+ { name: n('}}'), token: 'text' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } },
+ { name: 'EndTag', token: 'meta.tag', next: function(stack){ stack.pop(); stack.pop(); } }
+ ],
+ AposAttr: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ QuotAttr: [
+ { name: n('\"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeQuot', token: 'constant.language.escape' },
+ { name: 'QuotAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ Pragma: [
+ { name: 'PragmaContents', token: pragma },
+ { name: n('#'), token: pragma },
+ { name: n('#)'), token: pragma, next: function(stack){ stack.pop(); } }
+ ],
+ Comment: [
+ { name: 'CommentContents', token: 'comment' },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n(':)'), token: 'comment', next: function(stack){ stack.pop(); } }
+ ],
+ CommentDoc: [
+ { name: 'DocCommentContents', token: 'comment.doc' },
+ { name: 'DocTag', token: 'comment.doc.tag' },
+ { name: n('(:'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n(':)'), token: 'comment.doc', next: function(stack){ stack.pop(); } }
+ ],
+ XMLComment: [
+ { name: 'DirCommentContents', token: xmlcomment },
+ { name: n('-->'), token: xmlcomment, next: function(stack){ stack.pop(); } }
+ ],
+ CData: [
+ { name: 'CDataSectionContents', token: cdata },
+ { name: n(']]>'), token: cdata, next: function(stack){ stack.pop(); } }
+ ],
+ PI: [
+ { name: 'DirPIContents', token: pi },
+ { name: n('?'), token: pi },
+ { name: n('?>'), token: pi, next: function(stack){ stack.pop(); } }
+ ],
+ AposString: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposChar', token: 'string' }
+ ],
+ QuotString: [
+ { name: n('"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'JSONPredefinedCharRef', token: 'constant.language.escape' },
+ { name: 'JSONCharRef', token: 'constant.language.escape' },
+ { name: 'JSONChar', token: 'string' }
+ ]
+};
+
+exports.JSONiqLexer = function(){ return new Lexer(JSONiqTokenizer, Rules); };
+},{"./JSONiqTokenizer":"/node_modules/xqlint/lib/lexers/JSONiqTokenizer.js","./lexer":"/node_modules/xqlint/lib/lexers/lexer.js"}],"/node_modules/xqlint/lib/lexers/lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var TokenHandler = function(code) {
+ var input = code;
+ this.tokens = [];
+
+ this.reset = function() {
+ input = input;
+ this.tokens = [];
+ };
+
+ this.startNonterminal = function() {};
+ this.endNonterminal = function() {};
+
+ this.terminal = function(name, begin, end) {
+ this.tokens.push({
+ name: name,
+ value: input.substring(begin, end)
+ });
+ };
+
+ this.whitespace = function(begin, end) {
+ this.tokens.push({
+ name: 'WS',
+ value: input.substring(begin, end)
+ });
+ };
+};
+
+exports.Lexer = function(Tokenizer, Rules) {
+
+ this.tokens = [];
+
+ this.getLineTokens = function(line, state) {
+ state = (state === 'start' || !state) ? '["start"]' : state;
+ var stack = JSON.parse(state);
+ var h = new TokenHandler(line);
+ var tokenizer = new Tokenizer(line, h);
+ var tokens = [];
+
+ while(true) {
+ var currentState = stack[stack.length - 1];
+ try {
+ h.tokens = [];
+ tokenizer['parse_' + currentState]();
+ var info = null;
+
+ if(h.tokens.length > 1 && h.tokens[0].name === 'WS') {
+ tokens.push({
+ type: 'text',
+ value: h.tokens[0].value
+ });
+ h.tokens.splice(0, 1);
+ }
+
+ var token = h.tokens[0];
+ var rules = Rules[currentState];
+ for(var k = 0; k < rules.length; k++) {
+ var rule = Rules[currentState][k];
+ if((typeof(rule.name) === 'function' && rule.name(token)) || rule.name === token.name) {
+ info = rule;
+ break;
+ }
+ }
+
+ if(token.name === 'EOF') { break; }
+ if(token.value === '') { throw 'Encountered empty string lexical rule.'; }
+
+ tokens.push({
+ type: info === null ? 'text' : (typeof(info.token) === 'function' ? info.token(token.value) : info.token),
+ value: token.value
+ });
+
+ if(info && info.next) {
+ info.next(stack);
+ }
+
+ } catch(e) {
+ if(e instanceof tokenizer.ParseException) {
+ var index = 0;
+ for(var i=0; i < tokens.length; i++) {
+ index += tokens[i].value.length;
+ }
+ tokens.push({ type: 'text', value: line.substring(index) });
+ return {
+ tokens: tokens,
+ state: JSON.stringify(['start'])
+ };
+ } else {
+ throw e;
+ }
+ }
+ }
+
+ return {
+ tokens: tokens,
+ state: JSON.stringify(stack)
+ };
+ };
+};
+},{}],"/node_modules/xqlint/lib/lexers/xquery_lexer.js":[function(_dereq_,module,exports){
+'use strict';
+
+var XQueryTokenizer = _dereq_('./XQueryTokenizer').XQueryTokenizer;
+var Lexer = _dereq_('./lexer').Lexer;
+
+var keys = 'after|ancestor|ancestor-or-self|and|as|ascending|attribute|before|case|cast|castable|child|collation|comment|copy|count|declare|default|delete|descendant|descendant-or-self|descending|div|document|document-node|element|else|empty|empty-sequence|end|eq|every|except|first|following|following-sibling|for|function|ge|group|gt|idiv|if|import|insert|instance|intersect|into|is|item|last|le|let|lt|mod|modify|module|namespace|namespace-node|ne|node|only|or|order|ordered|parent|preceding|preceding-sibling|processing-instruction|rename|replace|return|satisfies|schema-attribute|schema-element|self|some|stable|start|switch|text|to|treat|try|typeswitch|union|unordered|validate|where|with|xquery|contains|paragraphs|sentences|times|words|by|collectionreturn|variable|version|option|when|encoding|toswitch|catch|tumbling|sliding|window|at|using|stemming|collection|schema|while|on|nodes|index|external|then|in|updating|value|of|containsbreak|loop|continue|exit|returning|append|json|position|strict'.split('|');
+
+var keywords = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'keyword' }; });
+var ncnames = keys.map(function(val) { return { name: '\'' + val + '\'', token: 'text', next: function(stack){ stack.pop(); } }; });
+
+var cdata = 'constant.language';
+var number = 'constant';
+var xmlcomment = 'comment';
+var pi = 'xml-pe';
+var pragma = 'constant.buildin';
+var n = function(name){
+ return '\'' + name + '\'';
+};
+var Rules = {
+ start: [
+ { name: n('(#'), token: pragma, next: function(stack){ stack.push('Pragma'); } },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n('(:~'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: n('<?'), token: pi, next: function(stack) { stack.push('PI'); } },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposString'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotString'); } },
+ { name: 'Annotation', token: 'support.function' },
+ { name: 'ModuleDecl', token: 'keyword', next: function(stack){ stack.push('Prefix'); } },
+ { name: 'OptionDecl', token: 'keyword', next: function(stack){ stack.push('_EQName'); } },
+ { name: 'AttrTest', token: 'support.type' },
+ { name: 'Variable', token: 'variable' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: 'IntegerLiteral', token: number },
+ { name: 'DecimalLiteral', token: number },
+ { name: 'DoubleLiteral', token: number },
+ { name: 'Operator', token: 'keyword.operator' },
+ { name: 'EQName', token: function(val) { return keys.indexOf(val) !== -1 ? 'keyword' : 'support.function'; } },
+ { name: n('('), token: 'lparen' },
+ { name: n(')'), token: 'rparen' },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: n('}'), token: 'text', next: function(stack){ if(stack.length > 1) { stack.pop(); } } },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } } //, next: function(stack){ if(stack.length > 1) { stack.pop(); } } }
+ ].concat(keywords),
+ _EQName: [
+ { name: 'EQName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ Prefix: [
+ { name: 'NCName', token: 'text', next: function(stack) { stack.pop(); } }
+ ].concat(ncnames),
+ StartTag: [
+ { name: n('>'), token: 'meta.tag', next: function(stack){ stack.push('TagContent'); } },
+ { name: 'QName', token: 'entity.other.attribute-name' },
+ { name: n('='), token: 'text' },
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.push('AposAttr'); } },
+ { name: n('"'), token: 'string', next: function(stack){ stack.push('QuotAttr'); } },
+ { name: n('/>'), token: 'meta.tag.r', next: function(stack){ stack.pop(); } }
+ ],
+ TagContent: [
+ { name: 'ElementContentChar', token: 'text' },
+ { name: n('<![CDATA['), token: cdata, next: function(stack){ stack.push('CData'); } },
+ { name: n('<!--'), token: xmlcomment, next: function(stack){ stack.push('XMLComment'); } },
+ { name: 'Tag', token: 'meta.tag', next: function(stack){ stack.push('StartTag'); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'text' },
+ { name: n('}}'), token: 'text' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } },
+ { name: 'EndTag', token: 'meta.tag', next: function(stack){ stack.pop(); stack.pop(); } }
+ ],
+ AposAttr: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ QuotAttr: [
+ { name: n('\"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'EscapeQuot', token: 'constant.language.escape' },
+ { name: 'QuotAttrContentChar', token: 'string' },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: n('{{'), token: 'string' },
+ { name: n('}}'), token: 'string' },
+ { name: n('{'), token: 'text', next: function(stack){ stack.push('start'); } }
+ ],
+ Pragma: [
+ { name: 'PragmaContents', token: pragma },
+ { name: n('#'), token: pragma },
+ { name: n('#)'), token: pragma, next: function(stack){ stack.pop(); } }
+ ],
+ Comment: [
+ { name: 'CommentContents', token: 'comment' },
+ { name: n('(:'), token: 'comment', next: function(stack){ stack.push('Comment'); } },
+ { name: n(':)'), token: 'comment', next: function(stack){ stack.pop(); } }
+ ],
+ CommentDoc: [
+ { name: 'DocCommentContents', token: 'comment.doc' },
+ { name: 'DocTag', token: 'comment.doc.tag' },
+ { name: n('(:'), token: 'comment.doc', next: function(stack){ stack.push('CommentDoc'); } },
+ { name: n(':)'), token: 'comment.doc', next: function(stack){ stack.pop(); } }
+ ],
+ XMLComment: [
+ { name: 'DirCommentContents', token: xmlcomment },
+ { name: n('-->'), token: xmlcomment, next: function(stack){ stack.pop(); } }
+ ],
+ CData: [
+ { name: 'CDataSectionContents', token: cdata },
+ { name: n(']]>'), token: cdata, next: function(stack){ stack.pop(); } }
+ ],
+ PI: [
+ { name: 'DirPIContents', token: pi },
+ { name: n('?'), token: pi },
+ { name: n('?>'), token: pi, next: function(stack){ stack.pop(); } }
+ ],
+ AposString: [
+ { name: n('\'\''), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: 'EscapeApos', token: 'constant.language.escape' },
+ { name: 'AposChar', token: 'string' }
+ ],
+ QuotString: [
+ { name: n('"'), token: 'string', next: function(stack){ stack.pop(); } },
+ { name: 'PredefinedEntityRef', token: 'constant.language.escape' },
+ { name: 'CharRef', token: 'constant.language.escape' },
+ { name: 'EscapeQuot', token: 'constant.language.escape' },
+ { name: 'QuotChar', token: 'string' }
+ ]
+};
+
+exports.XQueryLexer = function(){ return new Lexer(XQueryTokenizer, Rules); };
+},{"./XQueryTokenizer":"/node_modules/xqlint/lib/lexers/XQueryTokenizer.js","./lexer":"/node_modules/xqlint/lib/lexers/lexer.js"}],"/node_modules/xqlint/lib/parsers/JSONParseTreeHandler.js":[function(_dereq_,module,exports){
+exports.JSONParseTreeHandler = function (code) {
+ 'use strict';
+ var toBeIndex = ['VarDecl', 'FunctionDecl'];
+ var list = [
+ 'OrExpr', 'AndExpr', 'ComparisonExpr', 'StringConcatExpr', 'RangeExpr',
+ 'AdditiveExpr', 'MultiplicativeExpr',
+ 'UnionExpr', 'IntersectExceptExpr', 'InstanceofExpr', 'TreatExpr', 'CastableExpr', 'CastExpr', 'UnaryExpr', 'ValueExpr',
+ 'FTContainsExpr', 'SimpleMapExpr', 'PathExpr', 'RelativePathExpr', 'PostfixExpr', 'StepExpr'
+ ];
+
+ var ast = null;
+ var ptr = null;
+ var remains = code;
+ var cursor = 0;
+ var lineCursor = 0;
+ var line = 0;
+
+ function createNode(name) {
+ return {
+ name: name,
+ children: [],
+ getParent: null,
+ pos: {
+ sl: 0,
+ sc: 0,
+ el: 0,
+ ec: 0
+ }
+ };
+ }
+
+ function pushNode(name) { //begin
+ var node = createNode(name);
+ if (ast === null) {
+ ast = node;
+ ast.index = [];
+ ptr = node;
+ } else {
+ node.getParent = ptr;
+ ptr.children.push(node);
+ ptr = ptr.children[ptr.children.length - 1];
+ }
+ }
+
+ function popNode() {
+
+ if (ptr.children.length > 0) {
+ var s = ptr.children[0];
+ var e = null;
+ for (var i = ptr.children.length - 1; i >= 0; i--) {
+ e = ptr.children[i];
+ if (e.pos.el !== 0 || e.pos.ec !== 0) {
+ break;
+ }
+ }
+ ptr.pos.sl = s.pos.sl;
+ ptr.pos.sc = s.pos.sc;
+ ptr.pos.el = e.pos.el;
+ ptr.pos.ec = e.pos.ec;
+ }
+ if (ptr.name === 'FunctionName') {
+ ptr.name = 'EQName';
+ }
+ if (ptr.name === 'EQName' && ptr.value === undefined) {
+ ptr.value = ptr.children[0].value;
+ ptr.children.pop();
+ }
+
+ if(toBeIndex.indexOf(ptr.name) !== -1) {
+ ast.index.push(ptr);
+ }
+
+ if (ptr.getParent !== null) {
+ ptr = ptr.getParent;
+ } else {
+ }
+ if (ptr.children.length > 0) {
+ var lastChild = ptr.children[ptr.children.length - 1];
+ if (lastChild.children.length === 1 && list.indexOf(lastChild.name) !== -1) {
+ ptr.children[ptr.children.length - 1] = lastChild.children[0];
+ }
+ }
+ }
+
+ this.closeParseTree = function () {
+ while (ptr.getParent !== null) {
+ popNode();
+ }
+ popNode();
+ };
+
+ this.peek = function () {
+ return ptr;
+ };
+
+ this.getParseTree = function () {
+ return ast;
+ };
+
+ this.reset = function () {}; //input
+
+ this.startNonterminal = function (name, begin) {
+ pushNode(name, begin);
+ };
+
+ this.endNonterminal = function () {//name, end
+ popNode();
+ };
+
+ this.terminal = function (name, begin, end) {
+ name = (name.substring(0, 1) === '\'' && name.substring(name.length - 1) === '\'') ? 'TOKEN' : name;
+ pushNode(name, begin);
+ setValue(ptr, begin, end);
+ popNode();
+ };
+
+ this.whitespace = function (begin, end) {
+ var name = 'WS';
+ pushNode(name, begin);
+ setValue(ptr, begin, end);
+ popNode();
+ };
+
+ function setValue(node, begin, end) {
+
+ var e = end - cursor;
+ ptr.value = remains.substring(0, e);
+ remains = remains.substring(e);
+ cursor = end;
+
+ var sl = line;
+ var sc = lineCursor;
+ var el = sl + ptr.value.split('\n').length - 1;
+ var lastIdx = ptr.value.lastIndexOf('\n');
+ var ec = lastIdx === -1 ? sc + ptr.value.length : ptr.value.substring(lastIdx + 1).length;
+
+ line = el;
+ lineCursor = ec;
+
+ ptr.pos.sl = sl;
+ ptr.pos.sc = sc;
+ ptr.pos.el = el;
+ ptr.pos.ec = ec;
+ }
+};
+
+},{}],"/node_modules/xqlint/lib/parsers/JSONiqParser.js":[function(_dereq_,module,exports){
+ var JSONiqParser = exports.JSONiqParser = function JSONiqParser(string, parsingEventHandler)
+ {
+ init(string, parsingEventHandler);
+ var self = this;
+
+ this.ParseException = function(b, e, s, o, x)
+ {
+ var
+ begin = b,
+ end = e,
+ state = s,
+ offending = o,
+ expected = x;
+
+ this.getBegin = function() {return begin;};
+ this.getEnd = function() {return end;};
+ this.getState = function() {return state;};
+ this.getExpected = function() {return expected;};
+ this.getOffending = function() {return offending;};
+
+ this.getMessage = function()
+ {
+ return offending < 0 ? "lexical analysis failed" : "syntax error";
+ };
+ };
+
+ function init(string, parsingEventHandler)
+ {
+ eventHandler = parsingEventHandler;
+ input = string;
+ size = string.length;
+ reset(0, 0, 0);
+ }
+
+ this.getInput = function()
+ {
+ return input;
+ };
+
+ function reset(l, b, e)
+ {
+ b0 = b; e0 = b;
+ l1 = l; b1 = b; e1 = e;
+ l2 = 0;
+ end = e;
+ ex = -1;
+ memo = {};
+ eventHandler.reset(input);
+ }
+
+ this.getOffendingToken = function(e)
+ {
+ var o = e.getOffending();
+ return o >= 0 ? JSONiqParser.TOKEN[o] : null;
+ };
+
+ this.getExpectedTokenSet = function(e)
+ {
+ var expected;
+ if (e.getExpected() < 0)
+ {
+ expected = JSONiqParser.getTokenSet(- e.getState());
+ }
+ else
+ {
+ expected = [JSONiqParser.TOKEN[e.getExpected()]];
+ }
+ return expected;
+ };
+
+ this.getErrorMessage = function(e)
+ {
+ var tokenSet = this.getExpectedTokenSet(e);
+ var found = this.getOffendingToken(e);
+ var prefix = input.substring(0, e.getBegin());
+ var lines = prefix.split("\n");
+ var line = lines.length;
+ var column = lines[line - 1].length + 1;
+ var size = e.getEnd() - e.getBegin();
+ return e.getMessage()
+ + (found == null ? "" : ", found " + found)
+ + "\nwhile expecting "
+ + (tokenSet.length == 1 ? tokenSet[0] : ("[" + tokenSet.join(", ") + "]"))
+ + "\n"
+ + (size == 0 || found != null ? "" : "after successfully scanning " + size + " characters beginning ")
+ + "at line " + line + ", column " + column + ":\n..."
+ + input.substring(e.getBegin(), Math.min(input.length, e.getBegin() + 64))
+ + "...";
+ };
+
+ this.parse_XQuery = function()
+ {
+ eventHandler.startNonterminal("XQuery", e0);
+ lookahead1W(277); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Module();
+ shift(25); // EOF
+ eventHandler.endNonterminal("XQuery", e0);
+ };
+
+ function parse_Module()
+ {
+ eventHandler.startNonterminal("Module", e0);
+ switch (l1)
+ {
+ case 170: // 'jsoniq'
+ lookahead2W(168); // S^WS | '#' | '(' | '(:' | 'encoding' | 'version'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 64682 // 'jsoniq' 'encoding'
+ || lk == 137898) // 'jsoniq' 'version'
+ {
+ parse_VersionDecl();
+ }
+ lookahead1W(277); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 185: // 'module'
+ lookahead2W(146); // S^WS | '#' | '(' | '(:' | 'namespace'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 95929: // 'module' 'namespace'
+ whitespace();
+ parse_LibraryModule();
+ break;
+ default:
+ whitespace();
+ parse_MainModule();
+ }
+ eventHandler.endNonterminal("Module", e0);
+ }
+
+ function parse_VersionDecl()
+ {
+ eventHandler.startNonterminal("VersionDecl", e0);
+ shift(170); // 'jsoniq'
+ lookahead1W(120); // S^WS | '(:' | 'encoding' | 'version'
+ switch (l1)
+ {
+ case 126: // 'encoding'
+ shift(126); // 'encoding'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ break;
+ default:
+ shift(269); // 'version'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ lookahead1W(113); // S^WS | '(:' | ';' | 'encoding'
+ if (l1 == 126) // 'encoding'
+ {
+ shift(126); // 'encoding'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ }
+ lookahead1W(29); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ eventHandler.endNonterminal("VersionDecl", e0);
+ }
+
+ function parse_LibraryModule()
+ {
+ eventHandler.startNonterminal("LibraryModule", e0);
+ parse_ModuleDecl();
+ lookahead1W(142); // S^WS | EOF | '(:' | 'declare' | 'import'
+ whitespace();
+ parse_Prolog();
+ eventHandler.endNonterminal("LibraryModule", e0);
+ }
+
+ function parse_ModuleDecl()
+ {
+ eventHandler.startNonterminal("ModuleDecl", e0);
+ shift(185); // 'module'
+ lookahead1W(64); // S^WS | '(:' | 'namespace'
+ shift(187); // 'namespace'
+ lookahead1W(239); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(30); // S^WS | '(:' | '='
+ shift(61); // '='
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(29); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ eventHandler.endNonterminal("ModuleDecl", e0);
+ }
+
+ function parse_Prolog()
+ {
+ eventHandler.startNonterminal("Prolog", e0);
+ for (;;)
+ {
+ lookahead1W(277); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 109: // 'declare'
+ lookahead2W(206); // S^WS | '#' | '%' | '(' | '(:' | 'base-uri' | 'boundary-space' | 'collection' |
+ break;
+ case 155: // 'import'
+ lookahead2W(169); // S^WS | '#' | '(' | '(:' | 'module' | 'schema'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 43117 // 'declare' 'base-uri'
+ && lk != 44141 // 'declare' 'boundary-space'
+ && lk != 50797 // 'declare' 'construction'
+ && lk != 53869 // 'declare' 'copy-namespaces'
+ && lk != 54893 // 'declare' 'decimal-format'
+ && lk != 56429 // 'declare' 'default'
+ && lk != 73325 // 'declare' 'ft-option'
+ && lk != 94875 // 'import' 'module'
+ && lk != 95853 // 'declare' 'namespace'
+ && lk != 106093 // 'declare' 'ordering'
+ && lk != 115821 // 'declare' 'revalidation'
+ && lk != 117403) // 'import' 'schema'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 109: // 'declare'
+ lookahead2W(200); // S^WS | '(:' | 'base-uri' | 'boundary-space' | 'construction' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 56429) // 'declare' 'default'
+ {
+ lk = memoized(0, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_DefaultNamespaceDecl();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(0, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ whitespace();
+ parse_DefaultNamespaceDecl();
+ break;
+ case 95853: // 'declare' 'namespace'
+ whitespace();
+ parse_NamespaceDecl();
+ break;
+ case 155: // 'import'
+ whitespace();
+ parse_Import();
+ break;
+ case 73325: // 'declare' 'ft-option'
+ whitespace();
+ parse_FTOptionDecl();
+ break;
+ default:
+ whitespace();
+ parse_Setter();
+ }
+ lookahead1W(29); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ }
+ for (;;)
+ {
+ lookahead1W(277); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 109: // 'declare'
+ lookahead2W(201); // S^WS | '#' | '%' | '(' | '(:' | 'collection' | 'context' | 'function' | 'index' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 17005 // 'declare' '%'
+ && lk != 49261 // 'declare' 'collection'
+ && lk != 52333 // 'declare' 'context'
+ && lk != 75373 // 'declare' 'function'
+ && lk != 80493 // 'declare' 'index'
+ && lk != 83565 // 'declare' 'integrity'
+ && lk != 104045 // 'declare' 'option'
+ && lk != 134765 // 'declare' 'updating'
+ && lk != 137325) // 'declare' 'variable'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 109: // 'declare'
+ lookahead2W(197); // S^WS | '%' | '(:' | 'collection' | 'context' | 'function' | 'index' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 52333: // 'declare' 'context'
+ whitespace();
+ parse_ContextItemDecl();
+ break;
+ case 104045: // 'declare' 'option'
+ whitespace();
+ parse_OptionDecl();
+ break;
+ default:
+ whitespace();
+ parse_AnnotatedDecl();
+ }
+ lookahead1W(29); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ }
+ eventHandler.endNonterminal("Prolog", e0);
+ }
+
+ function parse_Separator()
+ {
+ eventHandler.startNonterminal("Separator", e0);
+ shift(54); // ';'
+ eventHandler.endNonterminal("Separator", e0);
+ }
+
+ function parse_Setter()
+ {
+ eventHandler.startNonterminal("Setter", e0);
+ switch (l1)
+ {
+ case 109: // 'declare'
+ lookahead2W(194); // S^WS | '(:' | 'base-uri' | 'boundary-space' | 'construction' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 56429) // 'declare' 'default'
+ {
+ lk = memoized(1, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_DefaultCollationDecl();
+ lk = -2;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_EmptyOrderDecl();
+ lk = -6;
+ }
+ catch (p6A)
+ {
+ lk = -9;
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(1, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 44141: // 'declare' 'boundary-space'
+ parse_BoundarySpaceDecl();
+ break;
+ case -2:
+ parse_DefaultCollationDecl();
+ break;
+ case 43117: // 'declare' 'base-uri'
+ parse_BaseURIDecl();
+ break;
+ case 50797: // 'declare' 'construction'
+ parse_ConstructionDecl();
+ break;
+ case 106093: // 'declare' 'ordering'
+ parse_OrderingModeDecl();
+ break;
+ case -6:
+ parse_EmptyOrderDecl();
+ break;
+ case 115821: // 'declare' 'revalidation'
+ parse_RevalidationDecl();
+ break;
+ case 53869: // 'declare' 'copy-namespaces'
+ parse_CopyNamespacesDecl();
+ break;
+ default:
+ parse_DecimalFormatDecl();
+ }
+ eventHandler.endNonterminal("Setter", e0);
+ }
+
+ function parse_BoundarySpaceDecl()
+ {
+ eventHandler.startNonterminal("BoundarySpaceDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(36); // S^WS | '(:' | 'boundary-space'
+ shift(86); // 'boundary-space'
+ lookahead1W(137); // S^WS | '(:' | 'preserve' | 'strip'
+ switch (l1)
+ {
+ case 218: // 'preserve'
+ shift(218); // 'preserve'
+ break;
+ default:
+ shift(246); // 'strip'
+ }
+ eventHandler.endNonterminal("BoundarySpaceDecl", e0);
+ }
+
+ function parse_DefaultCollationDecl()
+ {
+ eventHandler.startNonterminal("DefaultCollationDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(49); // S^WS | '(:' | 'default'
+ shift(110); // 'default'
+ lookahead1W(41); // S^WS | '(:' | 'collation'
+ shift(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("DefaultCollationDecl", e0);
+ }
+
+ function try_DefaultCollationDecl()
+ {
+ shiftT(109); // 'declare'
+ lookahead1W(49); // S^WS | '(:' | 'default'
+ shiftT(110); // 'default'
+ lookahead1W(41); // S^WS | '(:' | 'collation'
+ shiftT(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+
+ function parse_BaseURIDecl()
+ {
+ eventHandler.startNonterminal("BaseURIDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(35); // S^WS | '(:' | 'base-uri'
+ shift(84); // 'base-uri'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("BaseURIDecl", e0);
+ }
+
+ function parse_ConstructionDecl()
+ {
+ eventHandler.startNonterminal("ConstructionDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(44); // S^WS | '(:' | 'construction'
+ shift(99); // 'construction'
+ lookahead1W(137); // S^WS | '(:' | 'preserve' | 'strip'
+ switch (l1)
+ {
+ case 246: // 'strip'
+ shift(246); // 'strip'
+ break;
+ default:
+ shift(218); // 'preserve'
+ }
+ eventHandler.endNonterminal("ConstructionDecl", e0);
+ }
+
+ function parse_OrderingModeDecl()
+ {
+ eventHandler.startNonterminal("OrderingModeDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(71); // S^WS | '(:' | 'ordering'
+ shift(207); // 'ordering'
+ lookahead1W(135); // S^WS | '(:' | 'ordered' | 'unordered'
+ switch (l1)
+ {
+ case 206: // 'ordered'
+ shift(206); // 'ordered'
+ break;
+ default:
+ shift(262); // 'unordered'
+ }
+ eventHandler.endNonterminal("OrderingModeDecl", e0);
+ }
+
+ function parse_EmptyOrderDecl()
+ {
+ eventHandler.startNonterminal("EmptyOrderDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(49); // S^WS | '(:' | 'default'
+ shift(110); // 'default'
+ lookahead1W(70); // S^WS | '(:' | 'order'
+ shift(205); // 'order'
+ lookahead1W(52); // S^WS | '(:' | 'empty'
+ shift(124); // 'empty'
+ lookahead1W(125); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 149: // 'greatest'
+ shift(149); // 'greatest'
+ break;
+ default:
+ shift(176); // 'least'
+ }
+ eventHandler.endNonterminal("EmptyOrderDecl", e0);
+ }
+
+ function try_EmptyOrderDecl()
+ {
+ shiftT(109); // 'declare'
+ lookahead1W(49); // S^WS | '(:' | 'default'
+ shiftT(110); // 'default'
+ lookahead1W(70); // S^WS | '(:' | 'order'
+ shiftT(205); // 'order'
+ lookahead1W(52); // S^WS | '(:' | 'empty'
+ shiftT(124); // 'empty'
+ lookahead1W(125); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 149: // 'greatest'
+ shiftT(149); // 'greatest'
+ break;
+ default:
+ shiftT(176); // 'least'
+ }
+ }
+
+ function parse_CopyNamespacesDecl()
+ {
+ eventHandler.startNonterminal("CopyNamespacesDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(47); // S^WS | '(:' | 'copy-namespaces'
+ shift(105); // 'copy-namespaces'
+ lookahead1W(132); // S^WS | '(:' | 'no-preserve' | 'preserve'
+ whitespace();
+ parse_PreserveMode();
+ lookahead1W(25); // S^WS | '(:' | ','
+ shift(42); // ','
+ lookahead1W(127); // S^WS | '(:' | 'inherit' | 'no-inherit'
+ whitespace();
+ parse_InheritMode();
+ eventHandler.endNonterminal("CopyNamespacesDecl", e0);
+ }
+
+ function parse_PreserveMode()
+ {
+ eventHandler.startNonterminal("PreserveMode", e0);
+ switch (l1)
+ {
+ case 218: // 'preserve'
+ shift(218); // 'preserve'
+ break;
+ default:
+ shift(193); // 'no-preserve'
+ }
+ eventHandler.endNonterminal("PreserveMode", e0);
+ }
+
+ function parse_InheritMode()
+ {
+ eventHandler.startNonterminal("InheritMode", e0);
+ switch (l1)
+ {
+ case 159: // 'inherit'
+ shift(159); // 'inherit'
+ break;
+ default:
+ shift(192); // 'no-inherit'
+ }
+ eventHandler.endNonterminal("InheritMode", e0);
+ }
+
+ function parse_DecimalFormatDecl()
+ {
+ eventHandler.startNonterminal("DecimalFormatDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(118); // S^WS | '(:' | 'decimal-format' | 'default'
+ switch (l1)
+ {
+ case 107: // 'decimal-format'
+ shift(107); // 'decimal-format'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ break;
+ default:
+ shift(110); // 'default'
+ lookahead1W(48); // S^WS | '(:' | 'decimal-format'
+ shift(107); // 'decimal-format'
+ }
+ for (;;)
+ {
+ lookahead1W(203); // S^WS | '(:' | ';' | 'NaN' | 'decimal-separator' | 'digit' |
+ if (l1 == 54) // ';'
+ {
+ break;
+ }
+ whitespace();
+ parse_DFPropertyName();
+ lookahead1W(30); // S^WS | '(:' | '='
+ shift(61); // '='
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ eventHandler.endNonterminal("DecimalFormatDecl", e0);
+ }
+
+ function parse_DFPropertyName()
+ {
+ eventHandler.startNonterminal("DFPropertyName", e0);
+ switch (l1)
+ {
+ case 108: // 'decimal-separator'
+ shift(108); // 'decimal-separator'
+ break;
+ case 151: // 'grouping-separator'
+ shift(151); // 'grouping-separator'
+ break;
+ case 158: // 'infinity'
+ shift(158); // 'infinity'
+ break;
+ case 182: // 'minus-sign'
+ shift(182); // 'minus-sign'
+ break;
+ case 68: // 'NaN'
+ shift(68); // 'NaN'
+ break;
+ case 213: // 'percent'
+ shift(213); // 'percent'
+ break;
+ case 212: // 'per-mille'
+ shift(212); // 'per-mille'
+ break;
+ case 280: // 'zero-digit'
+ shift(280); // 'zero-digit'
+ break;
+ case 117: // 'digit'
+ shift(117); // 'digit'
+ break;
+ default:
+ shift(211); // 'pattern-separator'
+ }
+ eventHandler.endNonterminal("DFPropertyName", e0);
+ }
+
+ function parse_Import()
+ {
+ eventHandler.startNonterminal("Import", e0);
+ switch (l1)
+ {
+ case 155: // 'import'
+ lookahead2W(130); // S^WS | '(:' | 'module' | 'schema'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 117403: // 'import' 'schema'
+ parse_SchemaImport();
+ break;
+ default:
+ parse_ModuleImport();
+ }
+ eventHandler.endNonterminal("Import", e0);
+ }
+
+ function parse_SchemaImport()
+ {
+ eventHandler.startNonterminal("SchemaImport", e0);
+ shift(155); // 'import'
+ lookahead1W(76); // S^WS | '(:' | 'schema'
+ shift(229); // 'schema'
+ lookahead1W(141); // URILiteral | S^WS | '(:' | 'default' | 'namespace'
+ if (l1 != 7) // URILiteral
+ {
+ whitespace();
+ parse_SchemaPrefix();
+ }
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(112); // S^WS | '(:' | ';' | 'at'
+ if (l1 == 82) // 'at'
+ {
+ shift(82); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ for (;;)
+ {
+ lookahead1W(107); // S^WS | '(:' | ',' | ';'
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ }
+ eventHandler.endNonterminal("SchemaImport", e0);
+ }
+
+ function parse_SchemaPrefix()
+ {
+ eventHandler.startNonterminal("SchemaPrefix", e0);
+ switch (l1)
+ {
+ case 187: // 'namespace'
+ shift(187); // 'namespace'
+ lookahead1W(239); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(30); // S^WS | '(:' | '='
+ shift(61); // '='
+ break;
+ default:
+ shift(110); // 'default'
+ lookahead1W(50); // S^WS | '(:' | 'element'
+ shift(122); // 'element'
+ lookahead1W(64); // S^WS | '(:' | 'namespace'
+ shift(187); // 'namespace'
+ }
+ eventHandler.endNonterminal("SchemaPrefix", e0);
+ }
+
+ function parse_ModuleImport()
+ {
+ eventHandler.startNonterminal("ModuleImport", e0);
+ shift(155); // 'import'
+ lookahead1W(63); // S^WS | '(:' | 'module'
+ shift(185); // 'module'
+ lookahead1W(93); // URILiteral | S^WS | '(:' | 'namespace'
+ if (l1 == 187) // 'namespace'
+ {
+ shift(187); // 'namespace'
+ lookahead1W(239); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(30); // S^WS | '(:' | '='
+ shift(61); // '='
+ }
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(112); // S^WS | '(:' | ';' | 'at'
+ if (l1 == 82) // 'at'
+ {
+ shift(82); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ for (;;)
+ {
+ lookahead1W(107); // S^WS | '(:' | ',' | ';'
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ }
+ eventHandler.endNonterminal("ModuleImport", e0);
+ }
+
+ function parse_NamespaceDecl()
+ {
+ eventHandler.startNonterminal("NamespaceDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(64); // S^WS | '(:' | 'namespace'
+ shift(187); // 'namespace'
+ lookahead1W(239); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(30); // S^WS | '(:' | '='
+ shift(61); // '='
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("NamespaceDecl", e0);
+ }
+
+ function parse_DefaultNamespaceDecl()
+ {
+ eventHandler.startNonterminal("DefaultNamespaceDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(49); // S^WS | '(:' | 'default'
+ shift(110); // 'default'
+ lookahead1W(119); // S^WS | '(:' | 'element' | 'function'
+ switch (l1)
+ {
+ case 122: // 'element'
+ shift(122); // 'element'
+ break;
+ default:
+ shift(147); // 'function'
+ }
+ lookahead1W(64); // S^WS | '(:' | 'namespace'
+ shift(187); // 'namespace'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("DefaultNamespaceDecl", e0);
+ }
+
+ function try_DefaultNamespaceDecl()
+ {
+ shiftT(109); // 'declare'
+ lookahead1W(49); // S^WS | '(:' | 'default'
+ shiftT(110); // 'default'
+ lookahead1W(119); // S^WS | '(:' | 'element' | 'function'
+ switch (l1)
+ {
+ case 122: // 'element'
+ shiftT(122); // 'element'
+ break;
+ default:
+ shiftT(147); // 'function'
+ }
+ lookahead1W(64); // S^WS | '(:' | 'namespace'
+ shiftT(187); // 'namespace'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+
+ function parse_FTOptionDecl()
+ {
+ eventHandler.startNonterminal("FTOptionDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(55); // S^WS | '(:' | 'ft-option'
+ shift(143); // 'ft-option'
+ lookahead1W(84); // S^WS | '(:' | 'using'
+ whitespace();
+ parse_FTMatchOptions();
+ eventHandler.endNonterminal("FTOptionDecl", e0);
+ }
+
+ function parse_AnnotatedDecl()
+ {
+ eventHandler.startNonterminal("AnnotatedDecl", e0);
+ shift(109); // 'declare'
+ for (;;)
+ {
+ lookahead1W(192); // S^WS | '%' | '(:' | 'collection' | 'function' | 'index' | 'integrity' |
+ if (l1 != 33 // '%'
+ && l1 != 263) // 'updating'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 263: // 'updating'
+ whitespace();
+ parse_CompatibilityAnnotation();
+ break;
+ default:
+ whitespace();
+ parse_Annotation();
+ }
+ }
+ switch (l1)
+ {
+ case 268: // 'variable'
+ whitespace();
+ parse_VarDecl();
+ break;
+ case 147: // 'function'
+ whitespace();
+ parse_FunctionDecl();
+ break;
+ case 96: // 'collection'
+ whitespace();
+ parse_CollectionDecl();
+ break;
+ case 157: // 'index'
+ whitespace();
+ parse_IndexDecl();
+ break;
+ default:
+ whitespace();
+ parse_ICDecl();
+ }
+ eventHandler.endNonterminal("AnnotatedDecl", e0);
+ }
+
+ function parse_CompatibilityAnnotation()
+ {
+ eventHandler.startNonterminal("CompatibilityAnnotation", e0);
+ shift(263); // 'updating'
+ eventHandler.endNonterminal("CompatibilityAnnotation", e0);
+ }
+
+ function parse_Annotation()
+ {
+ eventHandler.startNonterminal("Annotation", e0);
+ shift(33); // '%'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(193); // S^WS | '%' | '(' | '(:' | 'collection' | 'function' | 'index' | 'integrity' |
+ if (l1 == 35) // '('
+ {
+ shift(35); // '('
+ lookahead1W(190); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:' |
+ whitespace();
+ parse_Literal();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(190); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:' |
+ whitespace();
+ parse_Literal();
+ }
+ shift(38); // ')'
+ }
+ eventHandler.endNonterminal("Annotation", e0);
+ }
+
+ function try_Annotation()
+ {
+ shiftT(33); // '%'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_EQName();
+ lookahead1W(193); // S^WS | '%' | '(' | '(:' | 'collection' | 'function' | 'index' | 'integrity' |
+ if (l1 == 35) // '('
+ {
+ shiftT(35); // '('
+ lookahead1W(190); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:' |
+ try_Literal();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(190); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:' |
+ try_Literal();
+ }
+ shiftT(38); // ')'
+ }
+ }
+
+ function parse_VarDecl()
+ {
+ eventHandler.startNonterminal("VarDecl", e0);
+ shift(268); // 'variable'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(157); // S^WS | '(:' | ':=' | 'as' | 'external'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(110); // S^WS | '(:' | ':=' | 'external'
+ switch (l1)
+ {
+ case 53: // ':='
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_VarValue();
+ break;
+ default:
+ shift(134); // 'external'
+ lookahead1W(108); // S^WS | '(:' | ':=' | ';'
+ if (l1 == 53) // ':='
+ {
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_VarDefaultValue();
+ }
+ }
+ eventHandler.endNonterminal("VarDecl", e0);
+ }
+
+ function parse_VarValue()
+ {
+ eventHandler.startNonterminal("VarValue", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("VarValue", e0);
+ }
+
+ function parse_VarDefaultValue()
+ {
+ eventHandler.startNonterminal("VarDefaultValue", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("VarDefaultValue", e0);
+ }
+
+ function parse_ContextItemDecl()
+ {
+ eventHandler.startNonterminal("ContextItemDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'context'
+ shift(102); // 'context'
+ lookahead1W(58); // S^WS | '(:' | 'item'
+ shift(167); // 'item'
+ lookahead1W(157); // S^WS | '(:' | ':=' | 'as' | 'external'
+ if (l1 == 80) // 'as'
+ {
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ItemType();
+ }
+ lookahead1W(110); // S^WS | '(:' | ':=' | 'external'
+ switch (l1)
+ {
+ case 53: // ':='
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_VarValue();
+ break;
+ default:
+ shift(134); // 'external'
+ lookahead1W(108); // S^WS | '(:' | ':=' | ';'
+ if (l1 == 53) // ':='
+ {
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_VarDefaultValue();
+ }
+ }
+ eventHandler.endNonterminal("ContextItemDecl", e0);
+ }
+
+ function parse_ParamList()
+ {
+ eventHandler.startNonterminal("ParamList", e0);
+ parse_Param();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_Param();
+ }
+ eventHandler.endNonterminal("ParamList", e0);
+ }
+
+ function try_ParamList()
+ {
+ try_Param();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_Param();
+ }
+ }
+
+ function parse_Param()
+ {
+ eventHandler.startNonterminal("Param", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(153); // S^WS | '(:' | ')' | ',' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ eventHandler.endNonterminal("Param", e0);
+ }
+
+ function try_Param()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_EQName();
+ lookahead1W(153); // S^WS | '(:' | ')' | ',' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ }
+
+ function parse_FunctionBody()
+ {
+ eventHandler.startNonterminal("FunctionBody", e0);
+ parse_EnclosedExpr();
+ eventHandler.endNonterminal("FunctionBody", e0);
+ }
+
+ function try_FunctionBody()
+ {
+ try_EnclosedExpr();
+ }
+
+ function parse_EnclosedExpr()
+ {
+ eventHandler.startNonterminal("EnclosedExpr", e0);
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("EnclosedExpr", e0);
+ }
+
+ function try_EnclosedExpr()
+ {
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+
+ function parse_OptionDecl()
+ {
+ eventHandler.startNonterminal("OptionDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(69); // S^WS | '(:' | 'option'
+ shift(203); // 'option'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ eventHandler.endNonterminal("OptionDecl", e0);
+ }
+
+ function parse_Expr()
+ {
+ eventHandler.startNonterminal("Expr", e0);
+ parse_ExprSingle();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("Expr", e0);
+ }
+
+ function try_Expr()
+ {
+ try_ExprSingle();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ }
+
+ function parse_FLWORExpr()
+ {
+ eventHandler.startNonterminal("FLWORExpr", e0);
+ parse_InitialClause();
+ for (;;)
+ {
+ lookahead1W(195); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 224) // 'return'
+ {
+ break;
+ }
+ whitespace();
+ parse_IntermediateClause();
+ }
+ whitespace();
+ parse_ReturnClause();
+ eventHandler.endNonterminal("FLWORExpr", e0);
+ }
+
+ function try_FLWORExpr()
+ {
+ try_InitialClause();
+ for (;;)
+ {
+ lookahead1W(195); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 224) // 'return'
+ {
+ break;
+ }
+ try_IntermediateClause();
+ }
+ try_ReturnClause();
+ }
+
+ function parse_InitialClause()
+ {
+ eventHandler.startNonterminal("InitialClause", e0);
+ switch (l1)
+ {
+ case 139: // 'for'
+ lookahead2W(151); // S^WS | '$' | '(:' | 'sliding' | 'tumbling'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16011: // 'for' '$'
+ parse_ForClause();
+ break;
+ case 177: // 'let'
+ parse_LetClause();
+ break;
+ default:
+ parse_WindowClause();
+ }
+ eventHandler.endNonterminal("InitialClause", e0);
+ }
+
+ function try_InitialClause()
+ {
+ switch (l1)
+ {
+ case 139: // 'for'
+ lookahead2W(151); // S^WS | '$' | '(:' | 'sliding' | 'tumbling'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16011: // 'for' '$'
+ try_ForClause();
+ break;
+ case 177: // 'let'
+ try_LetClause();
+ break;
+ default:
+ try_WindowClause();
+ }
+ }
+
+ function parse_IntermediateClause()
+ {
+ eventHandler.startNonterminal("IntermediateClause", e0);
+ switch (l1)
+ {
+ case 139: // 'for'
+ case 177: // 'let'
+ parse_InitialClause();
+ break;
+ case 272: // 'where'
+ parse_WhereClause();
+ break;
+ case 150: // 'group'
+ parse_GroupByClause();
+ break;
+ case 106: // 'count'
+ parse_CountClause();
+ break;
+ default:
+ parse_OrderByClause();
+ }
+ eventHandler.endNonterminal("IntermediateClause", e0);
+ }
+
+ function try_IntermediateClause()
+ {
+ switch (l1)
+ {
+ case 139: // 'for'
+ case 177: // 'let'
+ try_InitialClause();
+ break;
+ case 272: // 'where'
+ try_WhereClause();
+ break;
+ case 150: // 'group'
+ try_GroupByClause();
+ break;
+ case 106: // 'count'
+ try_CountClause();
+ break;
+ default:
+ try_OrderByClause();
+ }
+ }
+
+ function parse_ForClause()
+ {
+ eventHandler.startNonterminal("ForClause", e0);
+ shift(139); // 'for'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_ForBinding();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_ForBinding();
+ }
+ eventHandler.endNonterminal("ForClause", e0);
+ }
+
+ function try_ForClause()
+ {
+ shiftT(139); // 'for'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_ForBinding();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_ForBinding();
+ }
+ }
+
+ function parse_ForBinding()
+ {
+ eventHandler.startNonterminal("ForBinding", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(182); // S^WS | '(:' | 'allowing' | 'as' | 'at' | 'in' | 'score'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(173); // S^WS | '(:' | 'allowing' | 'at' | 'in' | 'score'
+ if (l1 == 73) // 'allowing'
+ {
+ whitespace();
+ parse_AllowingEmpty();
+ }
+ lookahead1W(160); // S^WS | '(:' | 'at' | 'in' | 'score'
+ if (l1 == 82) // 'at'
+ {
+ whitespace();
+ parse_PositionalVar();
+ }
+ lookahead1W(126); // S^WS | '(:' | 'in' | 'score'
+ if (l1 == 232) // 'score'
+ {
+ whitespace();
+ parse_FTScoreVar();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shift(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ForBinding", e0);
+ }
+
+ function try_ForBinding()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(182); // S^WS | '(:' | 'allowing' | 'as' | 'at' | 'in' | 'score'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(173); // S^WS | '(:' | 'allowing' | 'at' | 'in' | 'score'
+ if (l1 == 73) // 'allowing'
+ {
+ try_AllowingEmpty();
+ }
+ lookahead1W(160); // S^WS | '(:' | 'at' | 'in' | 'score'
+ if (l1 == 82) // 'at'
+ {
+ try_PositionalVar();
+ }
+ lookahead1W(126); // S^WS | '(:' | 'in' | 'score'
+ if (l1 == 232) // 'score'
+ {
+ try_FTScoreVar();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shiftT(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_AllowingEmpty()
+ {
+ eventHandler.startNonterminal("AllowingEmpty", e0);
+ shift(73); // 'allowing'
+ lookahead1W(52); // S^WS | '(:' | 'empty'
+ shift(124); // 'empty'
+ eventHandler.endNonterminal("AllowingEmpty", e0);
+ }
+
+ function try_AllowingEmpty()
+ {
+ shiftT(73); // 'allowing'
+ lookahead1W(52); // S^WS | '(:' | 'empty'
+ shiftT(124); // 'empty'
+ }
+
+ function parse_PositionalVar()
+ {
+ eventHandler.startNonterminal("PositionalVar", e0);
+ shift(82); // 'at'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("PositionalVar", e0);
+ }
+
+ function try_PositionalVar()
+ {
+ shiftT(82); // 'at'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_FTScoreVar()
+ {
+ eventHandler.startNonterminal("FTScoreVar", e0);
+ shift(232); // 'score'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("FTScoreVar", e0);
+ }
+
+ function try_FTScoreVar()
+ {
+ shiftT(232); // 'score'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_LetClause()
+ {
+ eventHandler.startNonterminal("LetClause", e0);
+ shift(177); // 'let'
+ lookahead1W(100); // S^WS | '$' | '(:' | 'score'
+ whitespace();
+ parse_LetBinding();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(100); // S^WS | '$' | '(:' | 'score'
+ whitespace();
+ parse_LetBinding();
+ }
+ eventHandler.endNonterminal("LetClause", e0);
+ }
+
+ function try_LetClause()
+ {
+ shiftT(177); // 'let'
+ lookahead1W(100); // S^WS | '$' | '(:' | 'score'
+ try_LetBinding();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(100); // S^WS | '$' | '(:' | 'score'
+ try_LetBinding();
+ }
+ }
+
+ function parse_LetBinding()
+ {
+ eventHandler.startNonterminal("LetBinding", e0);
+ switch (l1)
+ {
+ case 31: // '$'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(109); // S^WS | '(:' | ':=' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ break;
+ default:
+ parse_FTScoreVar();
+ }
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("LetBinding", e0);
+ }
+
+ function try_LetBinding()
+ {
+ switch (l1)
+ {
+ case 31: // '$'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(109); // S^WS | '(:' | ':=' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ break;
+ default:
+ try_FTScoreVar();
+ }
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_WindowClause()
+ {
+ eventHandler.startNonterminal("WindowClause", e0);
+ shift(139); // 'for'
+ lookahead1W(139); // S^WS | '(:' | 'sliding' | 'tumbling'
+ switch (l1)
+ {
+ case 257: // 'tumbling'
+ whitespace();
+ parse_TumblingWindowClause();
+ break;
+ default:
+ whitespace();
+ parse_SlidingWindowClause();
+ }
+ eventHandler.endNonterminal("WindowClause", e0);
+ }
+
+ function try_WindowClause()
+ {
+ shiftT(139); // 'for'
+ lookahead1W(139); // S^WS | '(:' | 'sliding' | 'tumbling'
+ switch (l1)
+ {
+ case 257: // 'tumbling'
+ try_TumblingWindowClause();
+ break;
+ default:
+ try_SlidingWindowClause();
+ }
+ }
+
+ function parse_TumblingWindowClause()
+ {
+ eventHandler.startNonterminal("TumblingWindowClause", e0);
+ shift(257); // 'tumbling'
+ lookahead1W(88); // S^WS | '(:' | 'window'
+ shift(275); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(114); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shift(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ whitespace();
+ parse_WindowStartCondition();
+ if (l1 == 127 // 'end'
+ || l1 == 202) // 'only'
+ {
+ whitespace();
+ parse_WindowEndCondition();
+ }
+ eventHandler.endNonterminal("TumblingWindowClause", e0);
+ }
+
+ function try_TumblingWindowClause()
+ {
+ shiftT(257); // 'tumbling'
+ lookahead1W(88); // S^WS | '(:' | 'window'
+ shiftT(275); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(114); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shiftT(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ try_WindowStartCondition();
+ if (l1 == 127 // 'end'
+ || l1 == 202) // 'only'
+ {
+ try_WindowEndCondition();
+ }
+ }
+
+ function parse_SlidingWindowClause()
+ {
+ eventHandler.startNonterminal("SlidingWindowClause", e0);
+ shift(239); // 'sliding'
+ lookahead1W(88); // S^WS | '(:' | 'window'
+ shift(275); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(114); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shift(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ whitespace();
+ parse_WindowStartCondition();
+ whitespace();
+ parse_WindowEndCondition();
+ eventHandler.endNonterminal("SlidingWindowClause", e0);
+ }
+
+ function try_SlidingWindowClause()
+ {
+ shiftT(239); // 'sliding'
+ lookahead1W(88); // S^WS | '(:' | 'window'
+ shiftT(275); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(114); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shiftT(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ try_WindowStartCondition();
+ try_WindowEndCondition();
+ }
+
+ function parse_WindowStartCondition()
+ {
+ eventHandler.startNonterminal("WindowStartCondition", e0);
+ shift(242); // 'start'
+ lookahead1W(181); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ whitespace();
+ parse_WindowVars();
+ lookahead1W(86); // S^WS | '(:' | 'when'
+ shift(271); // 'when'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("WindowStartCondition", e0);
+ }
+
+ function try_WindowStartCondition()
+ {
+ shiftT(242); // 'start'
+ lookahead1W(181); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ try_WindowVars();
+ lookahead1W(86); // S^WS | '(:' | 'when'
+ shiftT(271); // 'when'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_WindowEndCondition()
+ {
+ eventHandler.startNonterminal("WindowEndCondition", e0);
+ if (l1 == 202) // 'only'
+ {
+ shift(202); // 'only'
+ }
+ lookahead1W(53); // S^WS | '(:' | 'end'
+ shift(127); // 'end'
+ lookahead1W(181); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ whitespace();
+ parse_WindowVars();
+ lookahead1W(86); // S^WS | '(:' | 'when'
+ shift(271); // 'when'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("WindowEndCondition", e0);
+ }
+
+ function try_WindowEndCondition()
+ {
+ if (l1 == 202) // 'only'
+ {
+ shiftT(202); // 'only'
+ }
+ lookahead1W(53); // S^WS | '(:' | 'end'
+ shiftT(127); // 'end'
+ lookahead1W(181); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ try_WindowVars();
+ lookahead1W(86); // S^WS | '(:' | 'when'
+ shiftT(271); // 'when'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_WindowVars()
+ {
+ eventHandler.startNonterminal("WindowVars", e0);
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_CurrentItem();
+ }
+ lookahead1W(174); // S^WS | '(:' | 'at' | 'next' | 'previous' | 'when'
+ if (l1 == 82) // 'at'
+ {
+ whitespace();
+ parse_PositionalVar();
+ }
+ lookahead1W(163); // S^WS | '(:' | 'next' | 'previous' | 'when'
+ if (l1 == 219) // 'previous'
+ {
+ shift(219); // 'previous'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_PreviousItem();
+ }
+ lookahead1W(131); // S^WS | '(:' | 'next' | 'when'
+ if (l1 == 190) // 'next'
+ {
+ shift(190); // 'next'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NextItem();
+ }
+ eventHandler.endNonterminal("WindowVars", e0);
+ }
+
+ function try_WindowVars()
+ {
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CurrentItem();
+ }
+ lookahead1W(174); // S^WS | '(:' | 'at' | 'next' | 'previous' | 'when'
+ if (l1 == 82) // 'at'
+ {
+ try_PositionalVar();
+ }
+ lookahead1W(163); // S^WS | '(:' | 'next' | 'previous' | 'when'
+ if (l1 == 219) // 'previous'
+ {
+ shiftT(219); // 'previous'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_PreviousItem();
+ }
+ lookahead1W(131); // S^WS | '(:' | 'next' | 'when'
+ if (l1 == 190) // 'next'
+ {
+ shiftT(190); // 'next'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NextItem();
+ }
+ }
+
+ function parse_CurrentItem()
+ {
+ eventHandler.startNonterminal("CurrentItem", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("CurrentItem", e0);
+ }
+
+ function try_CurrentItem()
+ {
+ try_EQName();
+ }
+
+ function parse_PreviousItem()
+ {
+ eventHandler.startNonterminal("PreviousItem", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("PreviousItem", e0);
+ }
+
+ function try_PreviousItem()
+ {
+ try_EQName();
+ }
+
+ function parse_NextItem()
+ {
+ eventHandler.startNonterminal("NextItem", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("NextItem", e0);
+ }
+
+ function try_NextItem()
+ {
+ try_EQName();
+ }
+
+ function parse_CountClause()
+ {
+ eventHandler.startNonterminal("CountClause", e0);
+ shift(106); // 'count'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("CountClause", e0);
+ }
+
+ function try_CountClause()
+ {
+ shiftT(106); // 'count'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_WhereClause()
+ {
+ eventHandler.startNonterminal("WhereClause", e0);
+ shift(272); // 'where'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("WhereClause", e0);
+ }
+
+ function try_WhereClause()
+ {
+ shiftT(272); // 'where'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_GroupByClause()
+ {
+ eventHandler.startNonterminal("GroupByClause", e0);
+ shift(150); // 'group'
+ lookahead1W(37); // S^WS | '(:' | 'by'
+ shift(88); // 'by'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_GroupingSpecList();
+ eventHandler.endNonterminal("GroupByClause", e0);
+ }
+
+ function try_GroupByClause()
+ {
+ shiftT(150); // 'group'
+ lookahead1W(37); // S^WS | '(:' | 'by'
+ shiftT(88); // 'by'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_GroupingSpecList();
+ }
+
+ function parse_GroupingSpecList()
+ {
+ eventHandler.startNonterminal("GroupingSpecList", e0);
+ parse_GroupingSpec();
+ for (;;)
+ {
+ lookahead1W(198); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_GroupingSpec();
+ }
+ eventHandler.endNonterminal("GroupingSpecList", e0);
+ }
+
+ function try_GroupingSpecList()
+ {
+ try_GroupingSpec();
+ for (;;)
+ {
+ lookahead1W(198); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_GroupingSpec();
+ }
+ }
+
+ function parse_GroupingSpec()
+ {
+ eventHandler.startNonterminal("GroupingSpec", e0);
+ switch (l1)
+ {
+ case 31: // '$'
+ lookahead2W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 3103 // '$' EQName^Token
+ || lk == 36383 // '$' 'after'
+ || lk == 37407 // '$' 'allowing'
+ || lk == 37919 // '$' 'ancestor'
+ || lk == 38431 // '$' 'ancestor-or-self'
+ || lk == 38943 // '$' 'and'
+ || lk == 39967 // '$' 'append'
+ || lk == 40479 // '$' 'array'
+ || lk == 40991 // '$' 'as'
+ || lk == 41503 // '$' 'ascending'
+ || lk == 42015 // '$' 'at'
+ || lk == 42527 // '$' 'attribute'
+ || lk == 43039 // '$' 'base-uri'
+ || lk == 43551 // '$' 'before'
+ || lk == 44063 // '$' 'boundary-space'
+ || lk == 44575 // '$' 'break'
+ || lk == 45599 // '$' 'case'
+ || lk == 46111 // '$' 'cast'
+ || lk == 46623 // '$' 'castable'
+ || lk == 47135 // '$' 'catch'
+ || lk == 48159 // '$' 'child'
+ || lk == 48671 // '$' 'collation'
+ || lk == 49695 // '$' 'comment'
+ || lk == 50207 // '$' 'constraint'
+ || lk == 50719 // '$' 'construction'
+ || lk == 52255 // '$' 'context'
+ || lk == 52767 // '$' 'continue'
+ || lk == 53279 // '$' 'copy'
+ || lk == 53791 // '$' 'copy-namespaces'
+ || lk == 54303 // '$' 'count'
+ || lk == 54815 // '$' 'decimal-format'
+ || lk == 55839 // '$' 'declare'
+ || lk == 56351 // '$' 'default'
+ || lk == 56863 // '$' 'delete'
+ || lk == 57375 // '$' 'descendant'
+ || lk == 57887 // '$' 'descendant-or-self'
+ || lk == 58399 // '$' 'descending'
+ || lk == 60959 // '$' 'div'
+ || lk == 61471 // '$' 'document'
+ || lk == 61983 // '$' 'document-node'
+ || lk == 62495 // '$' 'element'
+ || lk == 63007 // '$' 'else'
+ || lk == 63519 // '$' 'empty'
+ || lk == 64031 // '$' 'empty-sequence'
+ || lk == 64543 // '$' 'encoding'
+ || lk == 65055 // '$' 'end'
+ || lk == 66079 // '$' 'eq'
+ || lk == 66591 // '$' 'every'
+ || lk == 67615 // '$' 'except'
+ || lk == 68127 // '$' 'exit'
+ || lk == 68639 // '$' 'external'
+ || lk == 69151 // '$' 'false'
+ || lk == 69663 // '$' 'first'
+ || lk == 70175 // '$' 'following'
+ || lk == 70687 // '$' 'following-sibling'
+ || lk == 71199 // '$' 'for'
+ || lk == 72735 // '$' 'from'
+ || lk == 73247 // '$' 'ft-option'
+ || lk == 75295 // '$' 'function'
+ || lk == 75807 // '$' 'ge'
+ || lk == 76831 // '$' 'group'
+ || lk == 77855 // '$' 'gt'
+ || lk == 78367 // '$' 'idiv'
+ || lk == 78879 // '$' 'if'
+ || lk == 79391 // '$' 'import'
+ || lk == 79903 // '$' 'in'
+ || lk == 80415 // '$' 'index'
+ || lk == 82463 // '$' 'insert'
+ || lk == 82975 // '$' 'instance'
+ || lk == 83487 // '$' 'integrity'
+ || lk == 83999 // '$' 'intersect'
+ || lk == 84511 // '$' 'into'
+ || lk == 85023 // '$' 'is'
+ || lk == 85535 // '$' 'item'
+ || lk == 86047 // '$' 'json'
+ || lk == 86559 // '$' 'json-item'
+ || lk == 87071 // '$' 'jsoniq'
+ || lk == 88607 // '$' 'last'
+ || lk == 89119 // '$' 'lax'
+ || lk == 89631 // '$' 'le'
+ || lk == 90655 // '$' 'let'
+ || lk == 91679 // '$' 'loop'
+ || lk == 92703 // '$' 'lt'
+ || lk == 93727 // '$' 'mod'
+ || lk == 94239 // '$' 'modify'
+ || lk == 94751 // '$' 'module'
+ || lk == 95775 // '$' 'namespace'
+ || lk == 96287 // '$' 'namespace-node'
+ || lk == 96799 // '$' 'ne'
+ || lk == 99359 // '$' 'node'
+ || lk == 99871 // '$' 'nodes'
+ || lk == 100895 // '$' 'null'
+ || lk == 101407 // '$' 'object'
+ || lk == 103455 // '$' 'only'
+ || lk == 103967 // '$' 'option'
+ || lk == 104479 // '$' 'or'
+ || lk == 104991 // '$' 'order'
+ || lk == 105503 // '$' 'ordered'
+ || lk == 106015 // '$' 'ordering'
+ || lk == 107551 // '$' 'parent'
+ || lk == 110623 // '$' 'preceding'
+ || lk == 111135 // '$' 'preceding-sibling'
+ || lk == 112671 // '$' 'processing-instruction'
+ || lk == 113695 // '$' 'rename'
+ || lk == 114207 // '$' 'replace'
+ || lk == 114719 // '$' 'return'
+ || lk == 115231 // '$' 'returning'
+ || lk == 115743 // '$' 'revalidation'
+ || lk == 116767 // '$' 'satisfies'
+ || lk == 117279 // '$' 'schema'
+ || lk == 117791 // '$' 'schema-attribute'
+ || lk == 118303 // '$' 'schema-element'
+ || lk == 118815 // '$' 'score'
+ || lk == 119327 // '$' 'select'
+ || lk == 119839 // '$' 'self'
+ || lk == 122399 // '$' 'sliding'
+ || lk == 122911 // '$' 'some'
+ || lk == 123423 // '$' 'stable'
+ || lk == 123935 // '$' 'start'
+ || lk == 125471 // '$' 'strict'
+ || lk == 126495 // '$' 'structured-item'
+ || lk == 127007 // '$' 'switch'
+ || lk == 127519 // '$' 'text'
+ || lk == 129567 // '$' 'to'
+ || lk == 130079 // '$' 'treat'
+ || lk == 130591 // '$' 'true'
+ || lk == 131103 // '$' 'try'
+ || lk == 131615 // '$' 'tumbling'
+ || lk == 132127 // '$' 'type'
+ || lk == 132639 // '$' 'typeswitch'
+ || lk == 133151 // '$' 'union'
+ || lk == 134175 // '$' 'unordered'
+ || lk == 134687 // '$' 'updating'
+ || lk == 136223 // '$' 'validate'
+ || lk == 136735 // '$' 'value'
+ || lk == 137247 // '$' 'variable'
+ || lk == 137759 // '$' 'version'
+ || lk == 139295 // '$' 'where'
+ || lk == 139807 // '$' 'while'
+ || lk == 141343) // '$' 'with'
+ {
+ lk = memoized(2, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_GroupingVariable();
+ lookahead1W(205); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 53 // ':='
+ || l1 == 80) // 'as'
+ {
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ if (l1 == 95) // 'collation'
+ {
+ shiftT(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(2, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ parse_GroupingVariable();
+ lookahead1W(205); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 53 // ':='
+ || l1 == 80) // 'as'
+ {
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ if (l1 == 95) // 'collation'
+ {
+ shift(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ break;
+ default:
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("GroupingSpec", e0);
+ }
+
+ function try_GroupingSpec()
+ {
+ switch (l1)
+ {
+ case 31: // '$'
+ lookahead2W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 3103 // '$' EQName^Token
+ || lk == 36383 // '$' 'after'
+ || lk == 37407 // '$' 'allowing'
+ || lk == 37919 // '$' 'ancestor'
+ || lk == 38431 // '$' 'ancestor-or-self'
+ || lk == 38943 // '$' 'and'
+ || lk == 39967 // '$' 'append'
+ || lk == 40479 // '$' 'array'
+ || lk == 40991 // '$' 'as'
+ || lk == 41503 // '$' 'ascending'
+ || lk == 42015 // '$' 'at'
+ || lk == 42527 // '$' 'attribute'
+ || lk == 43039 // '$' 'base-uri'
+ || lk == 43551 // '$' 'before'
+ || lk == 44063 // '$' 'boundary-space'
+ || lk == 44575 // '$' 'break'
+ || lk == 45599 // '$' 'case'
+ || lk == 46111 // '$' 'cast'
+ || lk == 46623 // '$' 'castable'
+ || lk == 47135 // '$' 'catch'
+ || lk == 48159 // '$' 'child'
+ || lk == 48671 // '$' 'collation'
+ || lk == 49695 // '$' 'comment'
+ || lk == 50207 // '$' 'constraint'
+ || lk == 50719 // '$' 'construction'
+ || lk == 52255 // '$' 'context'
+ || lk == 52767 // '$' 'continue'
+ || lk == 53279 // '$' 'copy'
+ || lk == 53791 // '$' 'copy-namespaces'
+ || lk == 54303 // '$' 'count'
+ || lk == 54815 // '$' 'decimal-format'
+ || lk == 55839 // '$' 'declare'
+ || lk == 56351 // '$' 'default'
+ || lk == 56863 // '$' 'delete'
+ || lk == 57375 // '$' 'descendant'
+ || lk == 57887 // '$' 'descendant-or-self'
+ || lk == 58399 // '$' 'descending'
+ || lk == 60959 // '$' 'div'
+ || lk == 61471 // '$' 'document'
+ || lk == 61983 // '$' 'document-node'
+ || lk == 62495 // '$' 'element'
+ || lk == 63007 // '$' 'else'
+ || lk == 63519 // '$' 'empty'
+ || lk == 64031 // '$' 'empty-sequence'
+ || lk == 64543 // '$' 'encoding'
+ || lk == 65055 // '$' 'end'
+ || lk == 66079 // '$' 'eq'
+ || lk == 66591 // '$' 'every'
+ || lk == 67615 // '$' 'except'
+ || lk == 68127 // '$' 'exit'
+ || lk == 68639 // '$' 'external'
+ || lk == 69151 // '$' 'false'
+ || lk == 69663 // '$' 'first'
+ || lk == 70175 // '$' 'following'
+ || lk == 70687 // '$' 'following-sibling'
+ || lk == 71199 // '$' 'for'
+ || lk == 72735 // '$' 'from'
+ || lk == 73247 // '$' 'ft-option'
+ || lk == 75295 // '$' 'function'
+ || lk == 75807 // '$' 'ge'
+ || lk == 76831 // '$' 'group'
+ || lk == 77855 // '$' 'gt'
+ || lk == 78367 // '$' 'idiv'
+ || lk == 78879 // '$' 'if'
+ || lk == 79391 // '$' 'import'
+ || lk == 79903 // '$' 'in'
+ || lk == 80415 // '$' 'index'
+ || lk == 82463 // '$' 'insert'
+ || lk == 82975 // '$' 'instance'
+ || lk == 83487 // '$' 'integrity'
+ || lk == 83999 // '$' 'intersect'
+ || lk == 84511 // '$' 'into'
+ || lk == 85023 // '$' 'is'
+ || lk == 85535 // '$' 'item'
+ || lk == 86047 // '$' 'json'
+ || lk == 86559 // '$' 'json-item'
+ || lk == 87071 // '$' 'jsoniq'
+ || lk == 88607 // '$' 'last'
+ || lk == 89119 // '$' 'lax'
+ || lk == 89631 // '$' 'le'
+ || lk == 90655 // '$' 'let'
+ || lk == 91679 // '$' 'loop'
+ || lk == 92703 // '$' 'lt'
+ || lk == 93727 // '$' 'mod'
+ || lk == 94239 // '$' 'modify'
+ || lk == 94751 // '$' 'module'
+ || lk == 95775 // '$' 'namespace'
+ || lk == 96287 // '$' 'namespace-node'
+ || lk == 96799 // '$' 'ne'
+ || lk == 99359 // '$' 'node'
+ || lk == 99871 // '$' 'nodes'
+ || lk == 100895 // '$' 'null'
+ || lk == 101407 // '$' 'object'
+ || lk == 103455 // '$' 'only'
+ || lk == 103967 // '$' 'option'
+ || lk == 104479 // '$' 'or'
+ || lk == 104991 // '$' 'order'
+ || lk == 105503 // '$' 'ordered'
+ || lk == 106015 // '$' 'ordering'
+ || lk == 107551 // '$' 'parent'
+ || lk == 110623 // '$' 'preceding'
+ || lk == 111135 // '$' 'preceding-sibling'
+ || lk == 112671 // '$' 'processing-instruction'
+ || lk == 113695 // '$' 'rename'
+ || lk == 114207 // '$' 'replace'
+ || lk == 114719 // '$' 'return'
+ || lk == 115231 // '$' 'returning'
+ || lk == 115743 // '$' 'revalidation'
+ || lk == 116767 // '$' 'satisfies'
+ || lk == 117279 // '$' 'schema'
+ || lk == 117791 // '$' 'schema-attribute'
+ || lk == 118303 // '$' 'schema-element'
+ || lk == 118815 // '$' 'score'
+ || lk == 119327 // '$' 'select'
+ || lk == 119839 // '$' 'self'
+ || lk == 122399 // '$' 'sliding'
+ || lk == 122911 // '$' 'some'
+ || lk == 123423 // '$' 'stable'
+ || lk == 123935 // '$' 'start'
+ || lk == 125471 // '$' 'strict'
+ || lk == 126495 // '$' 'structured-item'
+ || lk == 127007 // '$' 'switch'
+ || lk == 127519 // '$' 'text'
+ || lk == 129567 // '$' 'to'
+ || lk == 130079 // '$' 'treat'
+ || lk == 130591 // '$' 'true'
+ || lk == 131103 // '$' 'try'
+ || lk == 131615 // '$' 'tumbling'
+ || lk == 132127 // '$' 'type'
+ || lk == 132639 // '$' 'typeswitch'
+ || lk == 133151 // '$' 'union'
+ || lk == 134175 // '$' 'unordered'
+ || lk == 134687 // '$' 'updating'
+ || lk == 136223 // '$' 'validate'
+ || lk == 136735 // '$' 'value'
+ || lk == 137247 // '$' 'variable'
+ || lk == 137759 // '$' 'version'
+ || lk == 139295 // '$' 'where'
+ || lk == 139807 // '$' 'while'
+ || lk == 141343) // '$' 'with'
+ {
+ lk = memoized(2, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_GroupingVariable();
+ lookahead1W(205); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 53 // ':='
+ || l1 == 80) // 'as'
+ {
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ if (l1 == 95) // 'collation'
+ {
+ shiftT(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ memoize(2, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(2, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ try_GroupingVariable();
+ lookahead1W(205); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 53 // ':='
+ || l1 == 80) // 'as'
+ {
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ if (l1 == 95) // 'collation'
+ {
+ shiftT(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ break;
+ case -3:
+ break;
+ default:
+ try_ExprSingle();
+ }
+ }
+
+ function parse_GroupingVariable()
+ {
+ eventHandler.startNonterminal("GroupingVariable", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("GroupingVariable", e0);
+ }
+
+ function try_GroupingVariable()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_OrderByClause()
+ {
+ eventHandler.startNonterminal("OrderByClause", e0);
+ switch (l1)
+ {
+ case 205: // 'order'
+ shift(205); // 'order'
+ lookahead1W(37); // S^WS | '(:' | 'by'
+ shift(88); // 'by'
+ break;
+ default:
+ shift(241); // 'stable'
+ lookahead1W(70); // S^WS | '(:' | 'order'
+ shift(205); // 'order'
+ lookahead1W(37); // S^WS | '(:' | 'by'
+ shift(88); // 'by'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_OrderSpecList();
+ eventHandler.endNonterminal("OrderByClause", e0);
+ }
+
+ function try_OrderByClause()
+ {
+ switch (l1)
+ {
+ case 205: // 'order'
+ shiftT(205); // 'order'
+ lookahead1W(37); // S^WS | '(:' | 'by'
+ shiftT(88); // 'by'
+ break;
+ default:
+ shiftT(241); // 'stable'
+ lookahead1W(70); // S^WS | '(:' | 'order'
+ shiftT(205); // 'order'
+ lookahead1W(37); // S^WS | '(:' | 'by'
+ shiftT(88); // 'by'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_OrderSpecList();
+ }
+
+ function parse_OrderSpecList()
+ {
+ eventHandler.startNonterminal("OrderSpecList", e0);
+ parse_OrderSpec();
+ for (;;)
+ {
+ lookahead1W(198); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_OrderSpec();
+ }
+ eventHandler.endNonterminal("OrderSpecList", e0);
+ }
+
+ function try_OrderSpecList()
+ {
+ try_OrderSpec();
+ for (;;)
+ {
+ lookahead1W(198); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_OrderSpec();
+ }
+ }
+
+ function parse_OrderSpec()
+ {
+ eventHandler.startNonterminal("OrderSpec", e0);
+ parse_ExprSingle();
+ whitespace();
+ parse_OrderModifier();
+ eventHandler.endNonterminal("OrderSpec", e0);
+ }
+
+ function try_OrderSpec()
+ {
+ try_ExprSingle();
+ try_OrderModifier();
+ }
+
+ function parse_OrderModifier()
+ {
+ eventHandler.startNonterminal("OrderModifier", e0);
+ if (l1 == 81 // 'ascending'
+ || l1 == 114) // 'descending'
+ {
+ switch (l1)
+ {
+ case 81: // 'ascending'
+ shift(81); // 'ascending'
+ break;
+ default:
+ shift(114); // 'descending'
+ }
+ }
+ lookahead1W(202); // S^WS | '(:' | ',' | 'collation' | 'count' | 'empty' | 'for' | 'group' | 'let' |
+ if (l1 == 124) // 'empty'
+ {
+ shift(124); // 'empty'
+ lookahead1W(125); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 149: // 'greatest'
+ shift(149); // 'greatest'
+ break;
+ default:
+ shift(176); // 'least'
+ }
+ }
+ lookahead1W(199); // S^WS | '(:' | ',' | 'collation' | 'count' | 'for' | 'group' | 'let' | 'order' |
+ if (l1 == 95) // 'collation'
+ {
+ shift(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ eventHandler.endNonterminal("OrderModifier", e0);
+ }
+
+ function try_OrderModifier()
+ {
+ if (l1 == 81 // 'ascending'
+ || l1 == 114) // 'descending'
+ {
+ switch (l1)
+ {
+ case 81: // 'ascending'
+ shiftT(81); // 'ascending'
+ break;
+ default:
+ shiftT(114); // 'descending'
+ }
+ }
+ lookahead1W(202); // S^WS | '(:' | ',' | 'collation' | 'count' | 'empty' | 'for' | 'group' | 'let' |
+ if (l1 == 124) // 'empty'
+ {
+ shiftT(124); // 'empty'
+ lookahead1W(125); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 149: // 'greatest'
+ shiftT(149); // 'greatest'
+ break;
+ default:
+ shiftT(176); // 'least'
+ }
+ }
+ lookahead1W(199); // S^WS | '(:' | ',' | 'collation' | 'count' | 'for' | 'group' | 'let' | 'order' |
+ if (l1 == 95) // 'collation'
+ {
+ shiftT(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ }
+
+ function parse_ReturnClause()
+ {
+ eventHandler.startNonterminal("ReturnClause", e0);
+ shift(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ReturnClause", e0);
+ }
+
+ function try_ReturnClause()
+ {
+ shiftT(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_QuantifiedExpr()
+ {
+ eventHandler.startNonterminal("QuantifiedExpr", e0);
+ switch (l1)
+ {
+ case 240: // 'some'
+ shift(240); // 'some'
+ break;
+ default:
+ shift(130); // 'every'
+ }
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_QuantifiedVarDecl();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_QuantifiedVarDecl();
+ }
+ shift(228); // 'satisfies'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("QuantifiedExpr", e0);
+ }
+
+ function try_QuantifiedExpr()
+ {
+ switch (l1)
+ {
+ case 240: // 'some'
+ shiftT(240); // 'some'
+ break;
+ default:
+ shiftT(130); // 'every'
+ }
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_QuantifiedVarDecl();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_QuantifiedVarDecl();
+ }
+ shiftT(228); // 'satisfies'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_QuantifiedVarDecl()
+ {
+ eventHandler.startNonterminal("QuantifiedVarDecl", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(114); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shift(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("QuantifiedVarDecl", e0);
+ }
+
+ function try_QuantifiedVarDecl()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(114); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shiftT(156); // 'in'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SwitchExpr()
+ {
+ eventHandler.startNonterminal("SwitchExpr", e0);
+ shift(248); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_SwitchCaseClause();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shift(110); // 'default'
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shift(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SwitchExpr", e0);
+ }
+
+ function try_SwitchExpr()
+ {
+ shiftT(248); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ try_SwitchCaseClause();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(110); // 'default'
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shiftT(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SwitchCaseClause()
+ {
+ eventHandler.startNonterminal("SwitchCaseClause", e0);
+ for (;;)
+ {
+ shift(89); // 'case'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_SwitchCaseOperand();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shift(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SwitchCaseClause", e0);
+ }
+
+ function try_SwitchCaseClause()
+ {
+ for (;;)
+ {
+ shiftT(89); // 'case'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_SwitchCaseOperand();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SwitchCaseOperand()
+ {
+ eventHandler.startNonterminal("SwitchCaseOperand", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SwitchCaseOperand", e0);
+ }
+
+ function try_SwitchCaseOperand()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_TypeswitchExpr()
+ {
+ eventHandler.startNonterminal("TypeswitchExpr", e0);
+ shift(259); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_CaseClause();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shift(110); // 'default'
+ lookahead1W(99); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ }
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shift(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TypeswitchExpr", e0);
+ }
+
+ function try_TypeswitchExpr()
+ {
+ shiftT(259); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ try_CaseClause();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(110); // 'default'
+ lookahead1W(99); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shiftT(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_CaseClause()
+ {
+ eventHandler.startNonterminal("CaseClause", e0);
+ shift(89); // 'case'
+ lookahead1W(257); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shift(80); // 'as'
+ }
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceTypeUnion();
+ shift(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("CaseClause", e0);
+ }
+
+ function try_CaseClause()
+ {
+ shiftT(89); // 'case'
+ lookahead1W(257); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shiftT(80); // 'as'
+ }
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceTypeUnion();
+ shiftT(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SequenceTypeUnion()
+ {
+ eventHandler.startNonterminal("SequenceTypeUnion", e0);
+ parse_SequenceType();
+ for (;;)
+ {
+ lookahead1W(138); // S^WS | '(:' | 'return' | '|'
+ if (l1 != 284) // '|'
+ {
+ break;
+ }
+ shift(284); // '|'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ eventHandler.endNonterminal("SequenceTypeUnion", e0);
+ }
+
+ function try_SequenceTypeUnion()
+ {
+ try_SequenceType();
+ for (;;)
+ {
+ lookahead1W(138); // S^WS | '(:' | 'return' | '|'
+ if (l1 != 284) // '|'
+ {
+ break;
+ }
+ shiftT(284); // '|'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+
+ function parse_IfExpr()
+ {
+ eventHandler.startNonterminal("IfExpr", e0);
+ shift(154); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ lookahead1W(80); // S^WS | '(:' | 'then'
+ shift(250); // 'then'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(123); // 'else'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("IfExpr", e0);
+ }
+
+ function try_IfExpr()
+ {
+ shiftT(154); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ lookahead1W(80); // S^WS | '(:' | 'then'
+ shiftT(250); // 'then'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(123); // 'else'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_TryCatchExpr()
+ {
+ eventHandler.startNonterminal("TryCatchExpr", e0);
+ parse_TryClause();
+ for (;;)
+ {
+ lookahead1W(39); // S^WS | '(:' | 'catch'
+ whitespace();
+ parse_CatchClause();
+ lookahead1W(207); // S^WS | EOF | '(:' | ')' | ',' | ':' | ';' | ']' | 'after' | 'as' | 'ascending' |
+ if (l1 != 92) // 'catch'
+ {
+ break;
+ }
+ }
+ eventHandler.endNonterminal("TryCatchExpr", e0);
+ }
+
+ function try_TryCatchExpr()
+ {
+ try_TryClause();
+ for (;;)
+ {
+ lookahead1W(39); // S^WS | '(:' | 'catch'
+ try_CatchClause();
+ lookahead1W(207); // S^WS | EOF | '(:' | ')' | ',' | ':' | ';' | ']' | 'after' | 'as' | 'ascending' |
+ if (l1 != 92) // 'catch'
+ {
+ break;
+ }
+ }
+ }
+
+ function parse_TryClause()
+ {
+ eventHandler.startNonterminal("TryClause", e0);
+ shift(256); // 'try'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_TryTargetExpr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("TryClause", e0);
+ }
+
+ function try_TryClause()
+ {
+ shiftT(256); // 'try'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_TryTargetExpr();
+ shiftT(287); // '}'
+ }
+
+ function parse_TryTargetExpr()
+ {
+ eventHandler.startNonterminal("TryTargetExpr", e0);
+ parse_Expr();
+ eventHandler.endNonterminal("TryTargetExpr", e0);
+ }
+
+ function try_TryTargetExpr()
+ {
+ try_Expr();
+ }
+
+ function parse_CatchClause()
+ {
+ eventHandler.startNonterminal("CatchClause", e0);
+ shift(92); // 'catch'
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_CatchErrorList();
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("CatchClause", e0);
+ }
+
+ function try_CatchClause()
+ {
+ shiftT(92); // 'catch'
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+
+ function parse_CatchErrorList()
+ {
+ eventHandler.startNonterminal("CatchErrorList", e0);
+ parse_NameTest();
+ for (;;)
+ {
+ lookahead1W(140); // S^WS | '(:' | '{' | '|'
+ if (l1 != 284) // '|'
+ {
+ break;
+ }
+ shift(284); // '|'
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NameTest();
+ }
+ eventHandler.endNonterminal("CatchErrorList", e0);
+ }
+
+ function try_CatchErrorList()
+ {
+ try_NameTest();
+ for (;;)
+ {
+ lookahead1W(140); // S^WS | '(:' | '{' | '|'
+ if (l1 != 284) // '|'
+ {
+ break;
+ }
+ shiftT(284); // '|'
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NameTest();
+ }
+ }
+
+ function parse_OrExpr()
+ {
+ eventHandler.startNonterminal("OrExpr", e0);
+ parse_AndExpr();
+ for (;;)
+ {
+ if (l1 != 204) // 'or'
+ {
+ break;
+ }
+ shift(204); // 'or'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AndExpr();
+ }
+ eventHandler.endNonterminal("OrExpr", e0);
+ }
+
+ function try_OrExpr()
+ {
+ try_AndExpr();
+ for (;;)
+ {
+ if (l1 != 204) // 'or'
+ {
+ break;
+ }
+ shiftT(204); // 'or'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AndExpr();
+ }
+ }
+
+ function parse_AndExpr()
+ {
+ eventHandler.startNonterminal("AndExpr", e0);
+ parse_NotExpr();
+ for (;;)
+ {
+ if (l1 != 76) // 'and'
+ {
+ break;
+ }
+ shift(76); // 'and'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_NotExpr();
+ }
+ eventHandler.endNonterminal("AndExpr", e0);
+ }
+
+ function try_AndExpr()
+ {
+ try_NotExpr();
+ for (;;)
+ {
+ if (l1 != 76) // 'and'
+ {
+ break;
+ }
+ shiftT(76); // 'and'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_NotExpr();
+ }
+ }
+
+ function parse_NotExpr()
+ {
+ eventHandler.startNonterminal("NotExpr", e0);
+ if (l1 == 196) // 'not'
+ {
+ shift(196); // 'not'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ComparisonExpr();
+ eventHandler.endNonterminal("NotExpr", e0);
+ }
+
+ function try_NotExpr()
+ {
+ if (l1 == 196) // 'not'
+ {
+ shiftT(196); // 'not'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ComparisonExpr();
+ }
+
+ function parse_ComparisonExpr()
+ {
+ eventHandler.startNonterminal("ComparisonExpr", e0);
+ parse_FTContainsExpr();
+ if (l1 == 27 // '!='
+ || l1 == 55 // '<'
+ || l1 == 58 // '<<'
+ || l1 == 59 // '<='
+ || l1 == 61 // '='
+ || l1 == 62 // '>'
+ || l1 == 63 // '>='
+ || l1 == 64 // '>>'
+ || l1 == 129 // 'eq'
+ || l1 == 148 // 'ge'
+ || l1 == 152 // 'gt'
+ || l1 == 166 // 'is'
+ || l1 == 175 // 'le'
+ || l1 == 181 // 'lt'
+ || l1 == 189) // 'ne'
+ {
+ switch (l1)
+ {
+ case 129: // 'eq'
+ case 148: // 'ge'
+ case 152: // 'gt'
+ case 175: // 'le'
+ case 181: // 'lt'
+ case 189: // 'ne'
+ whitespace();
+ parse_ValueComp();
+ break;
+ case 58: // '<<'
+ case 64: // '>>'
+ case 166: // 'is'
+ whitespace();
+ parse_NodeComp();
+ break;
+ default:
+ whitespace();
+ parse_GeneralComp();
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_FTContainsExpr();
+ }
+ eventHandler.endNonterminal("ComparisonExpr", e0);
+ }
+
+ function try_ComparisonExpr()
+ {
+ try_FTContainsExpr();
+ if (l1 == 27 // '!='
+ || l1 == 55 // '<'
+ || l1 == 58 // '<<'
+ || l1 == 59 // '<='
+ || l1 == 61 // '='
+ || l1 == 62 // '>'
+ || l1 == 63 // '>='
+ || l1 == 64 // '>>'
+ || l1 == 129 // 'eq'
+ || l1 == 148 // 'ge'
+ || l1 == 152 // 'gt'
+ || l1 == 166 // 'is'
+ || l1 == 175 // 'le'
+ || l1 == 181 // 'lt'
+ || l1 == 189) // 'ne'
+ {
+ switch (l1)
+ {
+ case 129: // 'eq'
+ case 148: // 'ge'
+ case 152: // 'gt'
+ case 175: // 'le'
+ case 181: // 'lt'
+ case 189: // 'ne'
+ try_ValueComp();
+ break;
+ case 58: // '<<'
+ case 64: // '>>'
+ case 166: // 'is'
+ try_NodeComp();
+ break;
+ default:
+ try_GeneralComp();
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_FTContainsExpr();
+ }
+ }
+
+ function parse_FTContainsExpr()
+ {
+ eventHandler.startNonterminal("FTContainsExpr", e0);
+ parse_StringConcatExpr();
+ if (l1 == 100) // 'contains'
+ {
+ shift(100); // 'contains'
+ lookahead1W(79); // S^WS | '(:' | 'text'
+ shift(249); // 'text'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTSelection();
+ if (l1 == 277) // 'without'
+ {
+ whitespace();
+ parse_FTIgnoreOption();
+ }
+ }
+ eventHandler.endNonterminal("FTContainsExpr", e0);
+ }
+
+ function try_FTContainsExpr()
+ {
+ try_StringConcatExpr();
+ if (l1 == 100) // 'contains'
+ {
+ shiftT(100); // 'contains'
+ lookahead1W(79); // S^WS | '(:' | 'text'
+ shiftT(249); // 'text'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTSelection();
+ if (l1 == 277) // 'without'
+ {
+ try_FTIgnoreOption();
+ }
+ }
+ }
+
+ function parse_StringConcatExpr()
+ {
+ eventHandler.startNonterminal("StringConcatExpr", e0);
+ parse_RangeExpr();
+ for (;;)
+ {
+ if (l1 != 285) // '||'
+ {
+ break;
+ }
+ shift(285); // '||'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_RangeExpr();
+ }
+ eventHandler.endNonterminal("StringConcatExpr", e0);
+ }
+
+ function try_StringConcatExpr()
+ {
+ try_RangeExpr();
+ for (;;)
+ {
+ if (l1 != 285) // '||'
+ {
+ break;
+ }
+ shiftT(285); // '||'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_RangeExpr();
+ }
+ }
+
+ function parse_RangeExpr()
+ {
+ eventHandler.startNonterminal("RangeExpr", e0);
+ parse_AdditiveExpr();
+ if (l1 == 253) // 'to'
+ {
+ shift(253); // 'to'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ }
+ eventHandler.endNonterminal("RangeExpr", e0);
+ }
+
+ function try_RangeExpr()
+ {
+ try_AdditiveExpr();
+ if (l1 == 253) // 'to'
+ {
+ shiftT(253); // 'to'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ }
+ }
+
+ function parse_AdditiveExpr()
+ {
+ eventHandler.startNonterminal("AdditiveExpr", e0);
+ parse_MultiplicativeExpr();
+ for (;;)
+ {
+ if (l1 != 41 // '+'
+ && l1 != 43) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 41: // '+'
+ shift(41); // '+'
+ break;
+ default:
+ shift(43); // '-'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_MultiplicativeExpr();
+ }
+ eventHandler.endNonterminal("AdditiveExpr", e0);
+ }
+
+ function try_AdditiveExpr()
+ {
+ try_MultiplicativeExpr();
+ for (;;)
+ {
+ if (l1 != 41 // '+'
+ && l1 != 43) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 41: // '+'
+ shiftT(41); // '+'
+ break;
+ default:
+ shiftT(43); // '-'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_MultiplicativeExpr();
+ }
+ }
+
+ function parse_MultiplicativeExpr()
+ {
+ eventHandler.startNonterminal("MultiplicativeExpr", e0);
+ parse_UnionExpr();
+ for (;;)
+ {
+ if (l1 != 39 // '*'
+ && l1 != 119 // 'div'
+ && l1 != 153 // 'idiv'
+ && l1 != 183) // 'mod'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 39: // '*'
+ shift(39); // '*'
+ break;
+ case 119: // 'div'
+ shift(119); // 'div'
+ break;
+ case 153: // 'idiv'
+ shift(153); // 'idiv'
+ break;
+ default:
+ shift(183); // 'mod'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_UnionExpr();
+ }
+ eventHandler.endNonterminal("MultiplicativeExpr", e0);
+ }
+
+ function try_MultiplicativeExpr()
+ {
+ try_UnionExpr();
+ for (;;)
+ {
+ if (l1 != 39 // '*'
+ && l1 != 119 // 'div'
+ && l1 != 153 // 'idiv'
+ && l1 != 183) // 'mod'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 39: // '*'
+ shiftT(39); // '*'
+ break;
+ case 119: // 'div'
+ shiftT(119); // 'div'
+ break;
+ case 153: // 'idiv'
+ shiftT(153); // 'idiv'
+ break;
+ default:
+ shiftT(183); // 'mod'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_UnionExpr();
+ }
+ }
+
+ function parse_UnionExpr()
+ {
+ eventHandler.startNonterminal("UnionExpr", e0);
+ parse_IntersectExceptExpr();
+ for (;;)
+ {
+ if (l1 != 260 // 'union'
+ && l1 != 284) // '|'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 260: // 'union'
+ shift(260); // 'union'
+ break;
+ default:
+ shift(284); // '|'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_IntersectExceptExpr();
+ }
+ eventHandler.endNonterminal("UnionExpr", e0);
+ }
+
+ function try_UnionExpr()
+ {
+ try_IntersectExceptExpr();
+ for (;;)
+ {
+ if (l1 != 260 // 'union'
+ && l1 != 284) // '|'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 260: // 'union'
+ shiftT(260); // 'union'
+ break;
+ default:
+ shiftT(284); // '|'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_IntersectExceptExpr();
+ }
+ }
+
+ function parse_IntersectExceptExpr()
+ {
+ eventHandler.startNonterminal("IntersectExceptExpr", e0);
+ parse_InstanceofExpr();
+ for (;;)
+ {
+ lookahead1W(221); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 != 132 // 'except'
+ && l1 != 164) // 'intersect'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 164: // 'intersect'
+ shift(164); // 'intersect'
+ break;
+ default:
+ shift(132); // 'except'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_InstanceofExpr();
+ }
+ eventHandler.endNonterminal("IntersectExceptExpr", e0);
+ }
+
+ function try_IntersectExceptExpr()
+ {
+ try_InstanceofExpr();
+ for (;;)
+ {
+ lookahead1W(221); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 != 132 // 'except'
+ && l1 != 164) // 'intersect'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 164: // 'intersect'
+ shiftT(164); // 'intersect'
+ break;
+ default:
+ shiftT(132); // 'except'
+ }
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_InstanceofExpr();
+ }
+ }
+
+ function parse_InstanceofExpr()
+ {
+ eventHandler.startNonterminal("InstanceofExpr", e0);
+ parse_TreatExpr();
+ lookahead1W(222); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 162) // 'instance'
+ {
+ shift(162); // 'instance'
+ lookahead1W(67); // S^WS | '(:' | 'of'
+ shift(200); // 'of'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ eventHandler.endNonterminal("InstanceofExpr", e0);
+ }
+
+ function try_InstanceofExpr()
+ {
+ try_TreatExpr();
+ lookahead1W(222); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 162) // 'instance'
+ {
+ shiftT(162); // 'instance'
+ lookahead1W(67); // S^WS | '(:' | 'of'
+ shiftT(200); // 'of'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+
+ function parse_TreatExpr()
+ {
+ eventHandler.startNonterminal("TreatExpr", e0);
+ parse_CastableExpr();
+ lookahead1W(223); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 254) // 'treat'
+ {
+ shift(254); // 'treat'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ eventHandler.endNonterminal("TreatExpr", e0);
+ }
+
+ function try_TreatExpr()
+ {
+ try_CastableExpr();
+ lookahead1W(223); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 254) // 'treat'
+ {
+ shiftT(254); // 'treat'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shiftT(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+
+ function parse_CastableExpr()
+ {
+ eventHandler.startNonterminal("CastableExpr", e0);
+ parse_CastExpr();
+ lookahead1W(224); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 91) // 'castable'
+ {
+ shift(91); // 'castable'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shift(80); // 'as'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SingleType();
+ }
+ eventHandler.endNonterminal("CastableExpr", e0);
+ }
+
+ function try_CastableExpr()
+ {
+ try_CastExpr();
+ lookahead1W(224); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 91) // 'castable'
+ {
+ shiftT(91); // 'castable'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shiftT(80); // 'as'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SingleType();
+ }
+ }
+
+ function parse_CastExpr()
+ {
+ eventHandler.startNonterminal("CastExpr", e0);
+ parse_UnaryExpr();
+ lookahead1W(226); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 90) // 'cast'
+ {
+ shift(90); // 'cast'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shift(80); // 'as'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SingleType();
+ }
+ eventHandler.endNonterminal("CastExpr", e0);
+ }
+
+ function try_CastExpr()
+ {
+ try_UnaryExpr();
+ lookahead1W(226); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 90) // 'cast'
+ {
+ shiftT(90); // 'cast'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shiftT(80); // 'as'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SingleType();
+ }
+ }
+
+ function parse_UnaryExpr()
+ {
+ eventHandler.startNonterminal("UnaryExpr", e0);
+ for (;;)
+ {
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 41 // '+'
+ && l1 != 43) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 43: // '-'
+ shift(43); // '-'
+ break;
+ default:
+ shift(41); // '+'
+ }
+ }
+ whitespace();
+ parse_ValueExpr();
+ eventHandler.endNonterminal("UnaryExpr", e0);
+ }
+
+ function try_UnaryExpr()
+ {
+ for (;;)
+ {
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 41 // '+'
+ && l1 != 43) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 43: // '-'
+ shiftT(43); // '-'
+ break;
+ default:
+ shiftT(41); // '+'
+ }
+ }
+ try_ValueExpr();
+ }
+
+ function parse_ValueExpr()
+ {
+ eventHandler.startNonterminal("ValueExpr", e0);
+ switch (l1)
+ {
+ case 266: // 'validate'
+ lookahead2W(188); // S^WS | '#' | '(' | '(:' | 'lax' | 'strict' | 'type' | '{'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 89354: // 'validate' 'lax'
+ case 125706: // 'validate' 'strict'
+ case 132362: // 'validate' 'type'
+ case 144138: // 'validate' '{'
+ parse_ValidateExpr();
+ break;
+ case 36: // '(#'
+ parse_ExtensionExpr();
+ break;
+ default:
+ parse_SimpleMapExpr();
+ }
+ eventHandler.endNonterminal("ValueExpr", e0);
+ }
+
+ function try_ValueExpr()
+ {
+ switch (l1)
+ {
+ case 266: // 'validate'
+ lookahead2W(188); // S^WS | '#' | '(' | '(:' | 'lax' | 'strict' | 'type' | '{'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 89354: // 'validate' 'lax'
+ case 125706: // 'validate' 'strict'
+ case 132362: // 'validate' 'type'
+ case 144138: // 'validate' '{'
+ try_ValidateExpr();
+ break;
+ case 36: // '(#'
+ try_ExtensionExpr();
+ break;
+ default:
+ try_SimpleMapExpr();
+ }
+ }
+
+ function parse_SimpleMapExpr()
+ {
+ eventHandler.startNonterminal("SimpleMapExpr", e0);
+ parse_PathExpr();
+ for (;;)
+ {
+ if (l1 != 26) // '!'
+ {
+ break;
+ }
+ shift(26); // '!'
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PathExpr();
+ }
+ eventHandler.endNonterminal("SimpleMapExpr", e0);
+ }
+
+ function try_SimpleMapExpr()
+ {
+ try_PathExpr();
+ for (;;)
+ {
+ if (l1 != 26) // '!'
+ {
+ break;
+ }
+ shiftT(26); // '!'
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PathExpr();
+ }
+ }
+
+ function parse_GeneralComp()
+ {
+ eventHandler.startNonterminal("GeneralComp", e0);
+ switch (l1)
+ {
+ case 61: // '='
+ shift(61); // '='
+ break;
+ case 27: // '!='
+ shift(27); // '!='
+ break;
+ case 55: // '<'
+ shift(55); // '<'
+ break;
+ case 59: // '<='
+ shift(59); // '<='
+ break;
+ case 62: // '>'
+ shift(62); // '>'
+ break;
+ default:
+ shift(63); // '>='
+ }
+ eventHandler.endNonterminal("GeneralComp", e0);
+ }
+
+ function try_GeneralComp()
+ {
+ switch (l1)
+ {
+ case 61: // '='
+ shiftT(61); // '='
+ break;
+ case 27: // '!='
+ shiftT(27); // '!='
+ break;
+ case 55: // '<'
+ shiftT(55); // '<'
+ break;
+ case 59: // '<='
+ shiftT(59); // '<='
+ break;
+ case 62: // '>'
+ shiftT(62); // '>'
+ break;
+ default:
+ shiftT(63); // '>='
+ }
+ }
+
+ function parse_ValueComp()
+ {
+ eventHandler.startNonterminal("ValueComp", e0);
+ switch (l1)
+ {
+ case 129: // 'eq'
+ shift(129); // 'eq'
+ break;
+ case 189: // 'ne'
+ shift(189); // 'ne'
+ break;
+ case 181: // 'lt'
+ shift(181); // 'lt'
+ break;
+ case 175: // 'le'
+ shift(175); // 'le'
+ break;
+ case 152: // 'gt'
+ shift(152); // 'gt'
+ break;
+ default:
+ shift(148); // 'ge'
+ }
+ eventHandler.endNonterminal("ValueComp", e0);
+ }
+
+ function try_ValueComp()
+ {
+ switch (l1)
+ {
+ case 129: // 'eq'
+ shiftT(129); // 'eq'
+ break;
+ case 189: // 'ne'
+ shiftT(189); // 'ne'
+ break;
+ case 181: // 'lt'
+ shiftT(181); // 'lt'
+ break;
+ case 175: // 'le'
+ shiftT(175); // 'le'
+ break;
+ case 152: // 'gt'
+ shiftT(152); // 'gt'
+ break;
+ default:
+ shiftT(148); // 'ge'
+ }
+ }
+
+ function parse_NodeComp()
+ {
+ eventHandler.startNonterminal("NodeComp", e0);
+ switch (l1)
+ {
+ case 166: // 'is'
+ shift(166); // 'is'
+ break;
+ case 58: // '<<'
+ shift(58); // '<<'
+ break;
+ default:
+ shift(64); // '>>'
+ }
+ eventHandler.endNonterminal("NodeComp", e0);
+ }
+
+ function try_NodeComp()
+ {
+ switch (l1)
+ {
+ case 166: // 'is'
+ shiftT(166); // 'is'
+ break;
+ case 58: // '<<'
+ shiftT(58); // '<<'
+ break;
+ default:
+ shiftT(64); // '>>'
+ }
+ }
+
+ function parse_ValidateExpr()
+ {
+ eventHandler.startNonterminal("ValidateExpr", e0);
+ shift(266); // 'validate'
+ lookahead1W(175); // S^WS | '(:' | 'lax' | 'strict' | 'type' | '{'
+ if (l1 != 281) // '{'
+ {
+ switch (l1)
+ {
+ case 258: // 'type'
+ shift(258); // 'type'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_TypeName();
+ break;
+ default:
+ whitespace();
+ parse_ValidationMode();
+ }
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("ValidateExpr", e0);
+ }
+
+ function try_ValidateExpr()
+ {
+ shiftT(266); // 'validate'
+ lookahead1W(175); // S^WS | '(:' | 'lax' | 'strict' | 'type' | '{'
+ if (l1 != 281) // '{'
+ {
+ switch (l1)
+ {
+ case 258: // 'type'
+ shiftT(258); // 'type'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_TypeName();
+ break;
+ default:
+ try_ValidationMode();
+ }
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+
+ function parse_ValidationMode()
+ {
+ eventHandler.startNonterminal("ValidationMode", e0);
+ switch (l1)
+ {
+ case 174: // 'lax'
+ shift(174); // 'lax'
+ break;
+ default:
+ shift(245); // 'strict'
+ }
+ eventHandler.endNonterminal("ValidationMode", e0);
+ }
+
+ function try_ValidationMode()
+ {
+ switch (l1)
+ {
+ case 174: // 'lax'
+ shiftT(174); // 'lax'
+ break;
+ default:
+ shiftT(245); // 'strict'
+ }
+ }
+
+ function parse_ExtensionExpr()
+ {
+ eventHandler.startNonterminal("ExtensionExpr", e0);
+ for (;;)
+ {
+ whitespace();
+ parse_Pragma();
+ lookahead1W(104); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 36) // '(#'
+ {
+ break;
+ }
+ }
+ shift(281); // '{'
+ lookahead1W(274); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 287) // '}'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(287); // '}'
+ eventHandler.endNonterminal("ExtensionExpr", e0);
+ }
+
+ function try_ExtensionExpr()
+ {
+ for (;;)
+ {
+ try_Pragma();
+ lookahead1W(104); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 36) // '(#'
+ {
+ break;
+ }
+ }
+ shiftT(281); // '{'
+ lookahead1W(274); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 287) // '}'
+ {
+ try_Expr();
+ }
+ shiftT(287); // '}'
+ }
+
+ function parse_Pragma()
+ {
+ eventHandler.startNonterminal("Pragma", e0);
+ shift(36); // '(#'
+ lookahead1(242); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ parse_EQName();
+ lookahead1(10); // S | '#)'
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ lookahead1(0); // PragmaContents
+ shift(1); // PragmaContents
+ }
+ lookahead1(5); // '#)'
+ shift(30); // '#)'
+ eventHandler.endNonterminal("Pragma", e0);
+ }
+
+ function try_Pragma()
+ {
+ shiftT(36); // '(#'
+ lookahead1(242); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ try_EQName();
+ lookahead1(10); // S | '#)'
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ lookahead1(0); // PragmaContents
+ shiftT(1); // PragmaContents
+ }
+ lookahead1(5); // '#)'
+ shiftT(30); // '#)'
+ }
+
+ function parse_PathExpr()
+ {
+ eventHandler.startNonterminal("PathExpr", e0);
+ switch (l1)
+ {
+ case 47: // '/'
+ shift(47); // '/'
+ lookahead1W(288); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 25: // EOF
+ case 26: // '!'
+ case 27: // '!='
+ case 38: // ')'
+ case 39: // '*'
+ case 41: // '+'
+ case 42: // ','
+ case 43: // '-'
+ case 50: // ':'
+ case 54: // ';'
+ case 58: // '<<'
+ case 59: // '<='
+ case 61: // '='
+ case 62: // '>'
+ case 63: // '>='
+ case 64: // '>>'
+ case 70: // ']'
+ case 88: // 'by'
+ case 100: // 'contains'
+ case 209: // 'paragraphs'
+ case 237: // 'sentences'
+ case 252: // 'times'
+ case 279: // 'words'
+ case 284: // '|'
+ case 285: // '||'
+ case 286: // '|}'
+ case 287: // '}'
+ break;
+ default:
+ whitespace();
+ parse_RelativePathExpr();
+ }
+ break;
+ case 48: // '//'
+ shift(48); // '//'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_RelativePathExpr();
+ break;
+ default:
+ parse_RelativePathExpr();
+ }
+ eventHandler.endNonterminal("PathExpr", e0);
+ }
+
+ function try_PathExpr()
+ {
+ switch (l1)
+ {
+ case 47: // '/'
+ shiftT(47); // '/'
+ lookahead1W(288); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 25: // EOF
+ case 26: // '!'
+ case 27: // '!='
+ case 38: // ')'
+ case 39: // '*'
+ case 41: // '+'
+ case 42: // ','
+ case 43: // '-'
+ case 50: // ':'
+ case 54: // ';'
+ case 58: // '<<'
+ case 59: // '<='
+ case 61: // '='
+ case 62: // '>'
+ case 63: // '>='
+ case 64: // '>>'
+ case 70: // ']'
+ case 88: // 'by'
+ case 100: // 'contains'
+ case 209: // 'paragraphs'
+ case 237: // 'sentences'
+ case 252: // 'times'
+ case 279: // 'words'
+ case 284: // '|'
+ case 285: // '||'
+ case 286: // '|}'
+ case 287: // '}'
+ break;
+ default:
+ try_RelativePathExpr();
+ }
+ break;
+ case 48: // '//'
+ shiftT(48); // '//'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_RelativePathExpr();
+ break;
+ default:
+ try_RelativePathExpr();
+ }
+ }
+
+ function parse_RelativePathExpr()
+ {
+ eventHandler.startNonterminal("RelativePathExpr", e0);
+ parse_PostfixExpr();
+ for (;;)
+ {
+ switch (l1)
+ {
+ case 26: // '!'
+ lookahead2W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 27 // '!='
+ && lk != 38 // ')'
+ && lk != 39 // '*'
+ && lk != 41 // '+'
+ && lk != 42 // ','
+ && lk != 43 // '-'
+ && lk != 47 // '/'
+ && lk != 48 // '//'
+ && lk != 50 // ':'
+ && lk != 54 // ';'
+ && lk != 55 // '<'
+ && lk != 58 // '<<'
+ && lk != 59 // '<='
+ && lk != 61 // '='
+ && lk != 62 // '>'
+ && lk != 63 // '>='
+ && lk != 64 // '>>'
+ && lk != 70 // ']'
+ && lk != 71 // 'after'
+ && lk != 76 // 'and'
+ && lk != 80 // 'as'
+ && lk != 81 // 'ascending'
+ && lk != 82 // 'at'
+ && lk != 85 // 'before'
+ && lk != 88 // 'by'
+ && lk != 89 // 'case'
+ && lk != 90 // 'cast'
+ && lk != 91 // 'castable'
+ && lk != 95 // 'collation'
+ && lk != 100 // 'contains'
+ && lk != 106 // 'count'
+ && lk != 110 // 'default'
+ && lk != 114 // 'descending'
+ && lk != 119 // 'div'
+ && lk != 123 // 'else'
+ && lk != 124 // 'empty'
+ && lk != 127 // 'end'
+ && lk != 129 // 'eq'
+ && lk != 132 // 'except'
+ && lk != 139 // 'for'
+ && lk != 148 // 'ge'
+ && lk != 150 // 'group'
+ && lk != 152 // 'gt'
+ && lk != 153 // 'idiv'
+ && lk != 162 // 'instance'
+ && lk != 164 // 'intersect'
+ && lk != 165 // 'into'
+ && lk != 166 // 'is'
+ && lk != 175 // 'le'
+ && lk != 177 // 'let'
+ && lk != 181 // 'lt'
+ && lk != 183 // 'mod'
+ && lk != 184 // 'modify'
+ && lk != 189 // 'ne'
+ && lk != 202 // 'only'
+ && lk != 204 // 'or'
+ && lk != 205 // 'order'
+ && lk != 209 // 'paragraphs'
+ && lk != 224 // 'return'
+ && lk != 228 // 'satisfies'
+ && lk != 237 // 'sentences'
+ && lk != 241 // 'stable'
+ && lk != 242 // 'start'
+ && lk != 252 // 'times'
+ && lk != 253 // 'to'
+ && lk != 254 // 'treat'
+ && lk != 260 // 'union'
+ && lk != 272 // 'where'
+ && lk != 276 // 'with'
+ && lk != 279 // 'words'
+ && lk != 284 // '|'
+ && lk != 285 // '||'
+ && lk != 286 // '|}'
+ && lk != 287 // '}'
+ && lk != 2586 // '!' Wildcard
+ && lk != 23578 // '!' '..'
+ && lk != 24090 // '!' '/'
+ && lk != 24602 // '!' '//'
+ && lk != 34330) // '!' '@'
+ {
+ lk = memoized(3, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ switch (l1)
+ {
+ case 47: // '/'
+ shiftT(47); // '/'
+ break;
+ case 48: // '//'
+ shiftT(48); // '//'
+ break;
+ default:
+ shiftT(26); // '!'
+ }
+ lookahead1W(263); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StepExpr();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(3, e0, lk);
+ }
+ }
+ if (lk != -1
+ && lk != 47 // '/'
+ && lk != 48 // '//'
+ && lk != 2586 // '!' Wildcard
+ && lk != 23578 // '!' '..'
+ && lk != 34330) // '!' '@'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 47: // '/'
+ shift(47); // '/'
+ break;
+ case 48: // '//'
+ shift(48); // '//'
+ break;
+ default:
+ shift(26); // '!'
+ }
+ lookahead1W(263); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_StepExpr();
+ }
+ eventHandler.endNonterminal("RelativePathExpr", e0);
+ }
+
+ function try_RelativePathExpr()
+ {
+ try_PostfixExpr();
+ for (;;)
+ {
+ switch (l1)
+ {
+ case 26: // '!'
+ lookahead2W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 27 // '!='
+ && lk != 38 // ')'
+ && lk != 39 // '*'
+ && lk != 41 // '+'
+ && lk != 42 // ','
+ && lk != 43 // '-'
+ && lk != 47 // '/'
+ && lk != 48 // '//'
+ && lk != 50 // ':'
+ && lk != 54 // ';'
+ && lk != 55 // '<'
+ && lk != 58 // '<<'
+ && lk != 59 // '<='
+ && lk != 61 // '='
+ && lk != 62 // '>'
+ && lk != 63 // '>='
+ && lk != 64 // '>>'
+ && lk != 70 // ']'
+ && lk != 71 // 'after'
+ && lk != 76 // 'and'
+ && lk != 80 // 'as'
+ && lk != 81 // 'ascending'
+ && lk != 82 // 'at'
+ && lk != 85 // 'before'
+ && lk != 88 // 'by'
+ && lk != 89 // 'case'
+ && lk != 90 // 'cast'
+ && lk != 91 // 'castable'
+ && lk != 95 // 'collation'
+ && lk != 100 // 'contains'
+ && lk != 106 // 'count'
+ && lk != 110 // 'default'
+ && lk != 114 // 'descending'
+ && lk != 119 // 'div'
+ && lk != 123 // 'else'
+ && lk != 124 // 'empty'
+ && lk != 127 // 'end'
+ && lk != 129 // 'eq'
+ && lk != 132 // 'except'
+ && lk != 139 // 'for'
+ && lk != 148 // 'ge'
+ && lk != 150 // 'group'
+ && lk != 152 // 'gt'
+ && lk != 153 // 'idiv'
+ && lk != 162 // 'instance'
+ && lk != 164 // 'intersect'
+ && lk != 165 // 'into'
+ && lk != 166 // 'is'
+ && lk != 175 // 'le'
+ && lk != 177 // 'let'
+ && lk != 181 // 'lt'
+ && lk != 183 // 'mod'
+ && lk != 184 // 'modify'
+ && lk != 189 // 'ne'
+ && lk != 202 // 'only'
+ && lk != 204 // 'or'
+ && lk != 205 // 'order'
+ && lk != 209 // 'paragraphs'
+ && lk != 224 // 'return'
+ && lk != 228 // 'satisfies'
+ && lk != 237 // 'sentences'
+ && lk != 241 // 'stable'
+ && lk != 242 // 'start'
+ && lk != 252 // 'times'
+ && lk != 253 // 'to'
+ && lk != 254 // 'treat'
+ && lk != 260 // 'union'
+ && lk != 272 // 'where'
+ && lk != 276 // 'with'
+ && lk != 279 // 'words'
+ && lk != 284 // '|'
+ && lk != 285 // '||'
+ && lk != 286 // '|}'
+ && lk != 287 // '}'
+ && lk != 2586 // '!' Wildcard
+ && lk != 23578 // '!' '..'
+ && lk != 24090 // '!' '/'
+ && lk != 24602 // '!' '//'
+ && lk != 34330) // '!' '@'
+ {
+ lk = memoized(3, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ switch (l1)
+ {
+ case 47: // '/'
+ shiftT(47); // '/'
+ break;
+ case 48: // '//'
+ shiftT(48); // '//'
+ break;
+ default:
+ shiftT(26); // '!'
+ }
+ lookahead1W(263); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StepExpr();
+ memoize(3, e0A, -1);
+ continue;
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(3, e0A, -2);
+ break;
+ }
+ }
+ }
+ if (lk != -1
+ && lk != 47 // '/'
+ && lk != 48 // '//'
+ && lk != 2586 // '!' Wildcard
+ && lk != 23578 // '!' '..'
+ && lk != 34330) // '!' '@'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 47: // '/'
+ shiftT(47); // '/'
+ break;
+ case 48: // '//'
+ shiftT(48); // '//'
+ break;
+ default:
+ shiftT(26); // '!'
+ }
+ lookahead1W(263); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StepExpr();
+ }
+ }
+
+ function parse_StepExpr()
+ {
+ eventHandler.startNonterminal("StepExpr", e0);
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ lookahead2W(287); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 122: // 'element'
+ lookahead2W(286); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 187: // 'namespace'
+ case 220: // 'processing-instruction'
+ lookahead2W(284); // NCName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(236); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '.' |
+ break;
+ case 97: // 'comment'
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 249: // 'text'
+ case 262: // 'unordered'
+ lookahead2W(238); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 79: // 'array'
+ case 125: // 'empty-sequence'
+ case 154: // 'if'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 247: // 'structured-item'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ lookahead2W(229); // S^WS | EOF | '!' | '!=' | '#' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 94: // 'child'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 234: // 'self'
+ lookahead2W(237); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 6: // EQName^Token
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 76: // 'and'
+ case 78: // 'append'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 87: // 'break'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 103: // 'continue'
+ case 104: // 'copy'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 111: // 'delete'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 121: // 'document-node'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 130: // 'every'
+ case 132: // 'except'
+ case 133: // 'exit'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 139: // 'for'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 147: // 'function'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 161: // 'insert'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 177: // 'let'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 188: // 'namespace-node'
+ case 189: // 'ne'
+ case 194: // 'node'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 222: // 'rename'
+ case 223: // 'replace'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 239: // 'sliding'
+ case 240: // 'some'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 256: // 'try'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 266: // 'validate'
+ case 267: // 'value'
+ case 268: // 'variable'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(233); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 12935 // 'false' EOF
+ || lk == 12997 // 'null' EOF
+ || lk == 13055 // 'true' EOF
+ || lk == 13447 // 'false' '!'
+ || lk == 13509 // 'null' '!'
+ || lk == 13567 // 'true' '!'
+ || lk == 13959 // 'false' '!='
+ || lk == 14021 // 'null' '!='
+ || lk == 14079 // 'true' '!='
+ || lk == 19591 // 'false' ')'
+ || lk == 19653 // 'null' ')'
+ || lk == 19711 // 'true' ')'
+ || lk == 20103 // 'false' '*'
+ || lk == 20165 // 'null' '*'
+ || lk == 20223 // 'true' '*'
+ || lk == 21127 // 'false' '+'
+ || lk == 21189 // 'null' '+'
+ || lk == 21247 // 'true' '+'
+ || lk == 21639 // 'false' ','
+ || lk == 21701 // 'null' ','
+ || lk == 21759 // 'true' ','
+ || lk == 22151 // 'false' '-'
+ || lk == 22213 // 'null' '-'
+ || lk == 22271 // 'true' '-'
+ || lk == 24199 // 'false' '/'
+ || lk == 24261 // 'null' '/'
+ || lk == 24319 // 'true' '/'
+ || lk == 24711 // 'false' '//'
+ || lk == 24773 // 'null' '//'
+ || lk == 24831 // 'true' '//'
+ || lk == 25735 // 'false' ':'
+ || lk == 25797 // 'null' ':'
+ || lk == 25855 // 'true' ':'
+ || lk == 27783 // 'false' ';'
+ || lk == 27845 // 'null' ';'
+ || lk == 27903 // 'true' ';'
+ || lk == 28295 // 'false' '<'
+ || lk == 28357 // 'null' '<'
+ || lk == 28415 // 'true' '<'
+ || lk == 29831 // 'false' '<<'
+ || lk == 29893 // 'null' '<<'
+ || lk == 29951 // 'true' '<<'
+ || lk == 30343 // 'false' '<='
+ || lk == 30405 // 'null' '<='
+ || lk == 30463 // 'true' '<='
+ || lk == 31367 // 'false' '='
+ || lk == 31429 // 'null' '='
+ || lk == 31487 // 'true' '='
+ || lk == 31879 // 'false' '>'
+ || lk == 31941 // 'null' '>'
+ || lk == 31999 // 'true' '>'
+ || lk == 32391 // 'false' '>='
+ || lk == 32453 // 'null' '>='
+ || lk == 32511 // 'true' '>='
+ || lk == 32903 // 'false' '>>'
+ || lk == 32965 // 'null' '>>'
+ || lk == 33023 // 'true' '>>'
+ || lk == 35463 // 'false' '['
+ || lk == 35525 // 'null' '['
+ || lk == 35583 // 'true' '['
+ || lk == 35975 // 'false' ']'
+ || lk == 36037 // 'null' ']'
+ || lk == 36095 // 'true' ']'
+ || lk == 36435 // 'attribute' 'after'
+ || lk == 36474 // 'element' 'after'
+ || lk == 36487 // 'false' 'after'
+ || lk == 36539 // 'namespace' 'after'
+ || lk == 36549 // 'null' 'after'
+ || lk == 36572 // 'processing-instruction' 'after'
+ || lk == 36607 // 'true' 'after'
+ || lk == 38995 // 'attribute' 'and'
+ || lk == 39034 // 'element' 'and'
+ || lk == 39047 // 'false' 'and'
+ || lk == 39099 // 'namespace' 'and'
+ || lk == 39109 // 'null' 'and'
+ || lk == 39132 // 'processing-instruction' 'and'
+ || lk == 39167 // 'true' 'and'
+ || lk == 41043 // 'attribute' 'as'
+ || lk == 41082 // 'element' 'as'
+ || lk == 41095 // 'false' 'as'
+ || lk == 41147 // 'namespace' 'as'
+ || lk == 41157 // 'null' 'as'
+ || lk == 41180 // 'processing-instruction' 'as'
+ || lk == 41215 // 'true' 'as'
+ || lk == 41555 // 'attribute' 'ascending'
+ || lk == 41594 // 'element' 'ascending'
+ || lk == 41607 // 'false' 'ascending'
+ || lk == 41659 // 'namespace' 'ascending'
+ || lk == 41669 // 'null' 'ascending'
+ || lk == 41692 // 'processing-instruction' 'ascending'
+ || lk == 41727 // 'true' 'ascending'
+ || lk == 42067 // 'attribute' 'at'
+ || lk == 42106 // 'element' 'at'
+ || lk == 42119 // 'false' 'at'
+ || lk == 42171 // 'namespace' 'at'
+ || lk == 42181 // 'null' 'at'
+ || lk == 42204 // 'processing-instruction' 'at'
+ || lk == 42239 // 'true' 'at'
+ || lk == 43603 // 'attribute' 'before'
+ || lk == 43642 // 'element' 'before'
+ || lk == 43655 // 'false' 'before'
+ || lk == 43707 // 'namespace' 'before'
+ || lk == 43717 // 'null' 'before'
+ || lk == 43740 // 'processing-instruction' 'before'
+ || lk == 43775 // 'true' 'before'
+ || lk == 45191 // 'false' 'by'
+ || lk == 45253 // 'null' 'by'
+ || lk == 45311 // 'true' 'by'
+ || lk == 45651 // 'attribute' 'case'
+ || lk == 45690 // 'element' 'case'
+ || lk == 45703 // 'false' 'case'
+ || lk == 45755 // 'namespace' 'case'
+ || lk == 45765 // 'null' 'case'
+ || lk == 45788 // 'processing-instruction' 'case'
+ || lk == 45823 // 'true' 'case'
+ || lk == 46163 // 'attribute' 'cast'
+ || lk == 46202 // 'element' 'cast'
+ || lk == 46215 // 'false' 'cast'
+ || lk == 46267 // 'namespace' 'cast'
+ || lk == 46277 // 'null' 'cast'
+ || lk == 46300 // 'processing-instruction' 'cast'
+ || lk == 46335 // 'true' 'cast'
+ || lk == 46675 // 'attribute' 'castable'
+ || lk == 46714 // 'element' 'castable'
+ || lk == 46727 // 'false' 'castable'
+ || lk == 46779 // 'namespace' 'castable'
+ || lk == 46789 // 'null' 'castable'
+ || lk == 46812 // 'processing-instruction' 'castable'
+ || lk == 46847 // 'true' 'castable'
+ || lk == 48723 // 'attribute' 'collation'
+ || lk == 48762 // 'element' 'collation'
+ || lk == 48775 // 'false' 'collation'
+ || lk == 48827 // 'namespace' 'collation'
+ || lk == 48837 // 'null' 'collation'
+ || lk == 48860 // 'processing-instruction' 'collation'
+ || lk == 48895 // 'true' 'collation'
+ || lk == 51335 // 'false' 'contains'
+ || lk == 51397 // 'null' 'contains'
+ || lk == 51455 // 'true' 'contains'
+ || lk == 54355 // 'attribute' 'count'
+ || lk == 54394 // 'element' 'count'
+ || lk == 54407 // 'false' 'count'
+ || lk == 54459 // 'namespace' 'count'
+ || lk == 54469 // 'null' 'count'
+ || lk == 54492 // 'processing-instruction' 'count'
+ || lk == 54527 // 'true' 'count'
+ || lk == 56403 // 'attribute' 'default'
+ || lk == 56442 // 'element' 'default'
+ || lk == 56455 // 'false' 'default'
+ || lk == 56507 // 'namespace' 'default'
+ || lk == 56517 // 'null' 'default'
+ || lk == 56540 // 'processing-instruction' 'default'
+ || lk == 56575 // 'true' 'default'
+ || lk == 58451 // 'attribute' 'descending'
+ || lk == 58490 // 'element' 'descending'
+ || lk == 58503 // 'false' 'descending'
+ || lk == 58555 // 'namespace' 'descending'
+ || lk == 58565 // 'null' 'descending'
+ || lk == 58588 // 'processing-instruction' 'descending'
+ || lk == 58623 // 'true' 'descending'
+ || lk == 61011 // 'attribute' 'div'
+ || lk == 61050 // 'element' 'div'
+ || lk == 61063 // 'false' 'div'
+ || lk == 61115 // 'namespace' 'div'
+ || lk == 61125 // 'null' 'div'
+ || lk == 61148 // 'processing-instruction' 'div'
+ || lk == 61183 // 'true' 'div'
+ || lk == 63059 // 'attribute' 'else'
+ || lk == 63098 // 'element' 'else'
+ || lk == 63111 // 'false' 'else'
+ || lk == 63163 // 'namespace' 'else'
+ || lk == 63173 // 'null' 'else'
+ || lk == 63196 // 'processing-instruction' 'else'
+ || lk == 63231 // 'true' 'else'
+ || lk == 63571 // 'attribute' 'empty'
+ || lk == 63610 // 'element' 'empty'
+ || lk == 63623 // 'false' 'empty'
+ || lk == 63675 // 'namespace' 'empty'
+ || lk == 63685 // 'null' 'empty'
+ || lk == 63708 // 'processing-instruction' 'empty'
+ || lk == 63743 // 'true' 'empty'
+ || lk == 65107 // 'attribute' 'end'
+ || lk == 65146 // 'element' 'end'
+ || lk == 65159 // 'false' 'end'
+ || lk == 65211 // 'namespace' 'end'
+ || lk == 65221 // 'null' 'end'
+ || lk == 65244 // 'processing-instruction' 'end'
+ || lk == 65279 // 'true' 'end'
+ || lk == 66131 // 'attribute' 'eq'
+ || lk == 66170 // 'element' 'eq'
+ || lk == 66183 // 'false' 'eq'
+ || lk == 66235 // 'namespace' 'eq'
+ || lk == 66245 // 'null' 'eq'
+ || lk == 66268 // 'processing-instruction' 'eq'
+ || lk == 66303 // 'true' 'eq'
+ || lk == 67667 // 'attribute' 'except'
+ || lk == 67706 // 'element' 'except'
+ || lk == 67719 // 'false' 'except'
+ || lk == 67771 // 'namespace' 'except'
+ || lk == 67781 // 'null' 'except'
+ || lk == 67804 // 'processing-instruction' 'except'
+ || lk == 67839 // 'true' 'except'
+ || lk == 71251 // 'attribute' 'for'
+ || lk == 71290 // 'element' 'for'
+ || lk == 71303 // 'false' 'for'
+ || lk == 71355 // 'namespace' 'for'
+ || lk == 71365 // 'null' 'for'
+ || lk == 71388 // 'processing-instruction' 'for'
+ || lk == 71423 // 'true' 'for'
+ || lk == 75859 // 'attribute' 'ge'
+ || lk == 75898 // 'element' 'ge'
+ || lk == 75911 // 'false' 'ge'
+ || lk == 75963 // 'namespace' 'ge'
+ || lk == 75973 // 'null' 'ge'
+ || lk == 75996 // 'processing-instruction' 'ge'
+ || lk == 76031 // 'true' 'ge'
+ || lk == 76883 // 'attribute' 'group'
+ || lk == 76922 // 'element' 'group'
+ || lk == 76935 // 'false' 'group'
+ || lk == 76987 // 'namespace' 'group'
+ || lk == 76997 // 'null' 'group'
+ || lk == 77020 // 'processing-instruction' 'group'
+ || lk == 77055 // 'true' 'group'
+ || lk == 77907 // 'attribute' 'gt'
+ || lk == 77946 // 'element' 'gt'
+ || lk == 77959 // 'false' 'gt'
+ || lk == 78011 // 'namespace' 'gt'
+ || lk == 78021 // 'null' 'gt'
+ || lk == 78044 // 'processing-instruction' 'gt'
+ || lk == 78079 // 'true' 'gt'
+ || lk == 78419 // 'attribute' 'idiv'
+ || lk == 78458 // 'element' 'idiv'
+ || lk == 78471 // 'false' 'idiv'
+ || lk == 78523 // 'namespace' 'idiv'
+ || lk == 78533 // 'null' 'idiv'
+ || lk == 78556 // 'processing-instruction' 'idiv'
+ || lk == 78591 // 'true' 'idiv'
+ || lk == 83027 // 'attribute' 'instance'
+ || lk == 83066 // 'element' 'instance'
+ || lk == 83079 // 'false' 'instance'
+ || lk == 83131 // 'namespace' 'instance'
+ || lk == 83141 // 'null' 'instance'
+ || lk == 83164 // 'processing-instruction' 'instance'
+ || lk == 83199 // 'true' 'instance'
+ || lk == 84051 // 'attribute' 'intersect'
+ || lk == 84090 // 'element' 'intersect'
+ || lk == 84103 // 'false' 'intersect'
+ || lk == 84155 // 'namespace' 'intersect'
+ || lk == 84165 // 'null' 'intersect'
+ || lk == 84188 // 'processing-instruction' 'intersect'
+ || lk == 84223 // 'true' 'intersect'
+ || lk == 84563 // 'attribute' 'into'
+ || lk == 84602 // 'element' 'into'
+ || lk == 84615 // 'false' 'into'
+ || lk == 84667 // 'namespace' 'into'
+ || lk == 84677 // 'null' 'into'
+ || lk == 84700 // 'processing-instruction' 'into'
+ || lk == 84735 // 'true' 'into'
+ || lk == 85075 // 'attribute' 'is'
+ || lk == 85114 // 'element' 'is'
+ || lk == 85127 // 'false' 'is'
+ || lk == 85179 // 'namespace' 'is'
+ || lk == 85189 // 'null' 'is'
+ || lk == 85212 // 'processing-instruction' 'is'
+ || lk == 85247 // 'true' 'is'
+ || lk == 89683 // 'attribute' 'le'
+ || lk == 89722 // 'element' 'le'
+ || lk == 89735 // 'false' 'le'
+ || lk == 89787 // 'namespace' 'le'
+ || lk == 89797 // 'null' 'le'
+ || lk == 89820 // 'processing-instruction' 'le'
+ || lk == 89855 // 'true' 'le'
+ || lk == 90707 // 'attribute' 'let'
+ || lk == 90746 // 'element' 'let'
+ || lk == 90759 // 'false' 'let'
+ || lk == 90811 // 'namespace' 'let'
+ || lk == 90821 // 'null' 'let'
+ || lk == 90844 // 'processing-instruction' 'let'
+ || lk == 90879 // 'true' 'let'
+ || lk == 92755 // 'attribute' 'lt'
+ || lk == 92794 // 'element' 'lt'
+ || lk == 92807 // 'false' 'lt'
+ || lk == 92859 // 'namespace' 'lt'
+ || lk == 92869 // 'null' 'lt'
+ || lk == 92892 // 'processing-instruction' 'lt'
+ || lk == 92927 // 'true' 'lt'
+ || lk == 93779 // 'attribute' 'mod'
+ || lk == 93818 // 'element' 'mod'
+ || lk == 93831 // 'false' 'mod'
+ || lk == 93883 // 'namespace' 'mod'
+ || lk == 93893 // 'null' 'mod'
+ || lk == 93916 // 'processing-instruction' 'mod'
+ || lk == 93951 // 'true' 'mod'
+ || lk == 94291 // 'attribute' 'modify'
+ || lk == 94330 // 'element' 'modify'
+ || lk == 94343 // 'false' 'modify'
+ || lk == 94395 // 'namespace' 'modify'
+ || lk == 94405 // 'null' 'modify'
+ || lk == 94428 // 'processing-instruction' 'modify'
+ || lk == 94463 // 'true' 'modify'
+ || lk == 96851 // 'attribute' 'ne'
+ || lk == 96890 // 'element' 'ne'
+ || lk == 96903 // 'false' 'ne'
+ || lk == 96955 // 'namespace' 'ne'
+ || lk == 96965 // 'null' 'ne'
+ || lk == 96988 // 'processing-instruction' 'ne'
+ || lk == 97023 // 'true' 'ne'
+ || lk == 103507 // 'attribute' 'only'
+ || lk == 103546 // 'element' 'only'
+ || lk == 103559 // 'false' 'only'
+ || lk == 103611 // 'namespace' 'only'
+ || lk == 103621 // 'null' 'only'
+ || lk == 103644 // 'processing-instruction' 'only'
+ || lk == 103679 // 'true' 'only'
+ || lk == 104531 // 'attribute' 'or'
+ || lk == 104570 // 'element' 'or'
+ || lk == 104583 // 'false' 'or'
+ || lk == 104635 // 'namespace' 'or'
+ || lk == 104645 // 'null' 'or'
+ || lk == 104668 // 'processing-instruction' 'or'
+ || lk == 104703 // 'true' 'or'
+ || lk == 105043 // 'attribute' 'order'
+ || lk == 105082 // 'element' 'order'
+ || lk == 105095 // 'false' 'order'
+ || lk == 105147 // 'namespace' 'order'
+ || lk == 105157 // 'null' 'order'
+ || lk == 105180 // 'processing-instruction' 'order'
+ || lk == 105215 // 'true' 'order'
+ || lk == 107143 // 'false' 'paragraphs'
+ || lk == 107205 // 'null' 'paragraphs'
+ || lk == 107263 // 'true' 'paragraphs'
+ || lk == 114771 // 'attribute' 'return'
+ || lk == 114810 // 'element' 'return'
+ || lk == 114823 // 'false' 'return'
+ || lk == 114875 // 'namespace' 'return'
+ || lk == 114885 // 'null' 'return'
+ || lk == 114908 // 'processing-instruction' 'return'
+ || lk == 114943 // 'true' 'return'
+ || lk == 116819 // 'attribute' 'satisfies'
+ || lk == 116858 // 'element' 'satisfies'
+ || lk == 116871 // 'false' 'satisfies'
+ || lk == 116923 // 'namespace' 'satisfies'
+ || lk == 116933 // 'null' 'satisfies'
+ || lk == 116956 // 'processing-instruction' 'satisfies'
+ || lk == 116991 // 'true' 'satisfies'
+ || lk == 121479 // 'false' 'sentences'
+ || lk == 121541 // 'null' 'sentences'
+ || lk == 121599 // 'true' 'sentences'
+ || lk == 123475 // 'attribute' 'stable'
+ || lk == 123514 // 'element' 'stable'
+ || lk == 123527 // 'false' 'stable'
+ || lk == 123579 // 'namespace' 'stable'
+ || lk == 123589 // 'null' 'stable'
+ || lk == 123612 // 'processing-instruction' 'stable'
+ || lk == 123647 // 'true' 'stable'
+ || lk == 123987 // 'attribute' 'start'
+ || lk == 124026 // 'element' 'start'
+ || lk == 124039 // 'false' 'start'
+ || lk == 124091 // 'namespace' 'start'
+ || lk == 124101 // 'null' 'start'
+ || lk == 124124 // 'processing-instruction' 'start'
+ || lk == 124159 // 'true' 'start'
+ || lk == 129159 // 'false' 'times'
+ || lk == 129221 // 'null' 'times'
+ || lk == 129279 // 'true' 'times'
+ || lk == 129619 // 'attribute' 'to'
+ || lk == 129658 // 'element' 'to'
+ || lk == 129671 // 'false' 'to'
+ || lk == 129723 // 'namespace' 'to'
+ || lk == 129733 // 'null' 'to'
+ || lk == 129756 // 'processing-instruction' 'to'
+ || lk == 129791 // 'true' 'to'
+ || lk == 130131 // 'attribute' 'treat'
+ || lk == 130170 // 'element' 'treat'
+ || lk == 130183 // 'false' 'treat'
+ || lk == 130235 // 'namespace' 'treat'
+ || lk == 130245 // 'null' 'treat'
+ || lk == 130268 // 'processing-instruction' 'treat'
+ || lk == 130303 // 'true' 'treat'
+ || lk == 133203 // 'attribute' 'union'
+ || lk == 133242 // 'element' 'union'
+ || lk == 133255 // 'false' 'union'
+ || lk == 133307 // 'namespace' 'union'
+ || lk == 133317 // 'null' 'union'
+ || lk == 133340 // 'processing-instruction' 'union'
+ || lk == 133375 // 'true' 'union'
+ || lk == 139347 // 'attribute' 'where'
+ || lk == 139386 // 'element' 'where'
+ || lk == 139399 // 'false' 'where'
+ || lk == 139451 // 'namespace' 'where'
+ || lk == 139461 // 'null' 'where'
+ || lk == 139484 // 'processing-instruction' 'where'
+ || lk == 139519 // 'true' 'where'
+ || lk == 141395 // 'attribute' 'with'
+ || lk == 141434 // 'element' 'with'
+ || lk == 141447 // 'false' 'with'
+ || lk == 141499 // 'namespace' 'with'
+ || lk == 141509 // 'null' 'with'
+ || lk == 141532 // 'processing-instruction' 'with'
+ || lk == 141567 // 'true' 'with'
+ || lk == 142983 // 'false' 'words'
+ || lk == 143045 // 'null' 'words'
+ || lk == 143103 // 'true' 'words'
+ || lk == 145543 // 'false' '|'
+ || lk == 145605 // 'null' '|'
+ || lk == 145663 // 'true' '|'
+ || lk == 146055 // 'false' '||'
+ || lk == 146117 // 'null' '||'
+ || lk == 146175 // 'true' '||'
+ || lk == 146567 // 'false' '|}'
+ || lk == 146629 // 'null' '|}'
+ || lk == 146687 // 'true' '|}'
+ || lk == 147079 // 'false' '}'
+ || lk == 147141 // 'null' '}'
+ || lk == 147199) // 'true' '}'
+ {
+ lk = memoized(4, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_PostfixExpr();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(4, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 31: // '$'
+ case 32: // '$$'
+ case 33: // '%'
+ case 35: // '('
+ case 55: // '<'
+ case 56: // '<!--'
+ case 60: // '<?'
+ case 69: // '['
+ case 281: // '{'
+ case 283: // '{|'
+ case 3155: // 'attribute' EQName^Token
+ case 3194: // 'element' EQName^Token
+ case 9915: // 'namespace' NCName^Token
+ case 9948: // 'processing-instruction' NCName^Token
+ case 14854: // EQName^Token '#'
+ case 14919: // 'after' '#'
+ case 14921: // 'allowing' '#'
+ case 14922: // 'ancestor' '#'
+ case 14923: // 'ancestor-or-self' '#'
+ case 14924: // 'and' '#'
+ case 14926: // 'append' '#'
+ case 14927: // 'array' '#'
+ case 14928: // 'as' '#'
+ case 14929: // 'ascending' '#'
+ case 14930: // 'at' '#'
+ case 14931: // 'attribute' '#'
+ case 14932: // 'base-uri' '#'
+ case 14933: // 'before' '#'
+ case 14934: // 'boundary-space' '#'
+ case 14935: // 'break' '#'
+ case 14937: // 'case' '#'
+ case 14938: // 'cast' '#'
+ case 14939: // 'castable' '#'
+ case 14940: // 'catch' '#'
+ case 14942: // 'child' '#'
+ case 14943: // 'collation' '#'
+ case 14945: // 'comment' '#'
+ case 14946: // 'constraint' '#'
+ case 14947: // 'construction' '#'
+ case 14950: // 'context' '#'
+ case 14951: // 'continue' '#'
+ case 14952: // 'copy' '#'
+ case 14953: // 'copy-namespaces' '#'
+ case 14954: // 'count' '#'
+ case 14955: // 'decimal-format' '#'
+ case 14957: // 'declare' '#'
+ case 14958: // 'default' '#'
+ case 14959: // 'delete' '#'
+ case 14960: // 'descendant' '#'
+ case 14961: // 'descendant-or-self' '#'
+ case 14962: // 'descending' '#'
+ case 14967: // 'div' '#'
+ case 14968: // 'document' '#'
+ case 14969: // 'document-node' '#'
+ case 14970: // 'element' '#'
+ case 14971: // 'else' '#'
+ case 14972: // 'empty' '#'
+ case 14973: // 'empty-sequence' '#'
+ case 14974: // 'encoding' '#'
+ case 14975: // 'end' '#'
+ case 14977: // 'eq' '#'
+ case 14978: // 'every' '#'
+ case 14980: // 'except' '#'
+ case 14981: // 'exit' '#'
+ case 14982: // 'external' '#'
+ case 14983: // 'false' '#'
+ case 14984: // 'first' '#'
+ case 14985: // 'following' '#'
+ case 14986: // 'following-sibling' '#'
+ case 14987: // 'for' '#'
+ case 14990: // 'from' '#'
+ case 14991: // 'ft-option' '#'
+ case 14995: // 'function' '#'
+ case 14996: // 'ge' '#'
+ case 14998: // 'group' '#'
+ case 15000: // 'gt' '#'
+ case 15001: // 'idiv' '#'
+ case 15002: // 'if' '#'
+ case 15003: // 'import' '#'
+ case 15004: // 'in' '#'
+ case 15005: // 'index' '#'
+ case 15009: // 'insert' '#'
+ case 15010: // 'instance' '#'
+ case 15011: // 'integrity' '#'
+ case 15012: // 'intersect' '#'
+ case 15013: // 'into' '#'
+ case 15014: // 'is' '#'
+ case 15015: // 'item' '#'
+ case 15016: // 'json' '#'
+ case 15017: // 'json-item' '#'
+ case 15018: // 'jsoniq' '#'
+ case 15021: // 'last' '#'
+ case 15022: // 'lax' '#'
+ case 15023: // 'le' '#'
+ case 15025: // 'let' '#'
+ case 15027: // 'loop' '#'
+ case 15029: // 'lt' '#'
+ case 15031: // 'mod' '#'
+ case 15032: // 'modify' '#'
+ case 15033: // 'module' '#'
+ case 15035: // 'namespace' '#'
+ case 15036: // 'namespace-node' '#'
+ case 15037: // 'ne' '#'
+ case 15042: // 'node' '#'
+ case 15043: // 'nodes' '#'
+ case 15045: // 'null' '#'
+ case 15046: // 'object' '#'
+ case 15050: // 'only' '#'
+ case 15051: // 'option' '#'
+ case 15052: // 'or' '#'
+ case 15053: // 'order' '#'
+ case 15054: // 'ordered' '#'
+ case 15055: // 'ordering' '#'
+ case 15058: // 'parent' '#'
+ case 15064: // 'preceding' '#'
+ case 15065: // 'preceding-sibling' '#'
+ case 15068: // 'processing-instruction' '#'
+ case 15070: // 'rename' '#'
+ case 15071: // 'replace' '#'
+ case 15072: // 'return' '#'
+ case 15073: // 'returning' '#'
+ case 15074: // 'revalidation' '#'
+ case 15076: // 'satisfies' '#'
+ case 15077: // 'schema' '#'
+ case 15078: // 'schema-attribute' '#'
+ case 15079: // 'schema-element' '#'
+ case 15080: // 'score' '#'
+ case 15081: // 'select' '#'
+ case 15082: // 'self' '#'
+ case 15087: // 'sliding' '#'
+ case 15088: // 'some' '#'
+ case 15089: // 'stable' '#'
+ case 15090: // 'start' '#'
+ case 15093: // 'strict' '#'
+ case 15095: // 'structured-item' '#'
+ case 15096: // 'switch' '#'
+ case 15097: // 'text' '#'
+ case 15101: // 'to' '#'
+ case 15102: // 'treat' '#'
+ case 15103: // 'true' '#'
+ case 15104: // 'try' '#'
+ case 15105: // 'tumbling' '#'
+ case 15106: // 'type' '#'
+ case 15107: // 'typeswitch' '#'
+ case 15108: // 'union' '#'
+ case 15110: // 'unordered' '#'
+ case 15111: // 'updating' '#'
+ case 15114: // 'validate' '#'
+ case 15115: // 'value' '#'
+ case 15116: // 'variable' '#'
+ case 15117: // 'version' '#'
+ case 15120: // 'where' '#'
+ case 15121: // 'while' '#'
+ case 15124: // 'with' '#'
+ case 17926: // EQName^Token '('
+ case 17991: // 'after' '('
+ case 17993: // 'allowing' '('
+ case 17994: // 'ancestor' '('
+ case 17995: // 'ancestor-or-self' '('
+ case 17996: // 'and' '('
+ case 17998: // 'append' '('
+ case 18000: // 'as' '('
+ case 18001: // 'ascending' '('
+ case 18002: // 'at' '('
+ case 18004: // 'base-uri' '('
+ case 18005: // 'before' '('
+ case 18006: // 'boundary-space' '('
+ case 18007: // 'break' '('
+ case 18009: // 'case' '('
+ case 18010: // 'cast' '('
+ case 18011: // 'castable' '('
+ case 18012: // 'catch' '('
+ case 18014: // 'child' '('
+ case 18015: // 'collation' '('
+ case 18018: // 'constraint' '('
+ case 18019: // 'construction' '('
+ case 18022: // 'context' '('
+ case 18023: // 'continue' '('
+ case 18024: // 'copy' '('
+ case 18025: // 'copy-namespaces' '('
+ case 18026: // 'count' '('
+ case 18027: // 'decimal-format' '('
+ case 18029: // 'declare' '('
+ case 18030: // 'default' '('
+ case 18031: // 'delete' '('
+ case 18032: // 'descendant' '('
+ case 18033: // 'descendant-or-self' '('
+ case 18034: // 'descending' '('
+ case 18039: // 'div' '('
+ case 18040: // 'document' '('
+ case 18043: // 'else' '('
+ case 18044: // 'empty' '('
+ case 18046: // 'encoding' '('
+ case 18047: // 'end' '('
+ case 18049: // 'eq' '('
+ case 18050: // 'every' '('
+ case 18052: // 'except' '('
+ case 18053: // 'exit' '('
+ case 18054: // 'external' '('
+ case 18055: // 'false' '('
+ case 18056: // 'first' '('
+ case 18057: // 'following' '('
+ case 18058: // 'following-sibling' '('
+ case 18059: // 'for' '('
+ case 18062: // 'from' '('
+ case 18063: // 'ft-option' '('
+ case 18067: // 'function' '('
+ case 18068: // 'ge' '('
+ case 18070: // 'group' '('
+ case 18072: // 'gt' '('
+ case 18073: // 'idiv' '('
+ case 18075: // 'import' '('
+ case 18076: // 'in' '('
+ case 18077: // 'index' '('
+ case 18081: // 'insert' '('
+ case 18082: // 'instance' '('
+ case 18083: // 'integrity' '('
+ case 18084: // 'intersect' '('
+ case 18085: // 'into' '('
+ case 18086: // 'is' '('
+ case 18088: // 'json' '('
+ case 18090: // 'jsoniq' '('
+ case 18093: // 'last' '('
+ case 18094: // 'lax' '('
+ case 18095: // 'le' '('
+ case 18097: // 'let' '('
+ case 18099: // 'loop' '('
+ case 18101: // 'lt' '('
+ case 18103: // 'mod' '('
+ case 18104: // 'modify' '('
+ case 18105: // 'module' '('
+ case 18107: // 'namespace' '('
+ case 18109: // 'ne' '('
+ case 18115: // 'nodes' '('
+ case 18117: // 'null' '('
+ case 18118: // 'object' '('
+ case 18122: // 'only' '('
+ case 18123: // 'option' '('
+ case 18124: // 'or' '('
+ case 18125: // 'order' '('
+ case 18126: // 'ordered' '('
+ case 18127: // 'ordering' '('
+ case 18130: // 'parent' '('
+ case 18136: // 'preceding' '('
+ case 18137: // 'preceding-sibling' '('
+ case 18142: // 'rename' '('
+ case 18143: // 'replace' '('
+ case 18144: // 'return' '('
+ case 18145: // 'returning' '('
+ case 18146: // 'revalidation' '('
+ case 18148: // 'satisfies' '('
+ case 18149: // 'schema' '('
+ case 18152: // 'score' '('
+ case 18153: // 'select' '('
+ case 18154: // 'self' '('
+ case 18159: // 'sliding' '('
+ case 18160: // 'some' '('
+ case 18161: // 'stable' '('
+ case 18162: // 'start' '('
+ case 18165: // 'strict' '('
+ case 18173: // 'to' '('
+ case 18174: // 'treat' '('
+ case 18175: // 'true' '('
+ case 18176: // 'try' '('
+ case 18177: // 'tumbling' '('
+ case 18178: // 'type' '('
+ case 18180: // 'union' '('
+ case 18182: // 'unordered' '('
+ case 18183: // 'updating' '('
+ case 18186: // 'validate' '('
+ case 18187: // 'value' '('
+ case 18188: // 'variable' '('
+ case 18189: // 'version' '('
+ case 18192: // 'where' '('
+ case 18193: // 'while' '('
+ case 18196: // 'with' '('
+ case 23175: // 'false' '.'
+ case 23237: // 'null' '.'
+ case 23295: // 'true' '.'
+ case 37459: // 'attribute' 'allowing'
+ case 37498: // 'element' 'allowing'
+ case 37563: // 'namespace' 'allowing'
+ case 37596: // 'processing-instruction' 'allowing'
+ case 37971: // 'attribute' 'ancestor'
+ case 38010: // 'element' 'ancestor'
+ case 38075: // 'namespace' 'ancestor'
+ case 38108: // 'processing-instruction' 'ancestor'
+ case 38483: // 'attribute' 'ancestor-or-self'
+ case 38522: // 'element' 'ancestor-or-self'
+ case 38587: // 'namespace' 'ancestor-or-self'
+ case 38620: // 'processing-instruction' 'ancestor-or-self'
+ case 40019: // 'attribute' 'append'
+ case 40058: // 'element' 'append'
+ case 40123: // 'namespace' 'append'
+ case 40156: // 'processing-instruction' 'append'
+ case 40531: // 'attribute' 'array'
+ case 40570: // 'element' 'array'
+ case 42579: // 'attribute' 'attribute'
+ case 42618: // 'element' 'attribute'
+ case 42683: // 'namespace' 'attribute'
+ case 42716: // 'processing-instruction' 'attribute'
+ case 43091: // 'attribute' 'base-uri'
+ case 43130: // 'element' 'base-uri'
+ case 43195: // 'namespace' 'base-uri'
+ case 43228: // 'processing-instruction' 'base-uri'
+ case 44115: // 'attribute' 'boundary-space'
+ case 44154: // 'element' 'boundary-space'
+ case 44219: // 'namespace' 'boundary-space'
+ case 44252: // 'processing-instruction' 'boundary-space'
+ case 44627: // 'attribute' 'break'
+ case 44666: // 'element' 'break'
+ case 44731: // 'namespace' 'break'
+ case 44764: // 'processing-instruction' 'break'
+ case 47187: // 'attribute' 'catch'
+ case 47226: // 'element' 'catch'
+ case 47291: // 'namespace' 'catch'
+ case 47324: // 'processing-instruction' 'catch'
+ case 48211: // 'attribute' 'child'
+ case 48250: // 'element' 'child'
+ case 48315: // 'namespace' 'child'
+ case 48348: // 'processing-instruction' 'child'
+ case 49747: // 'attribute' 'comment'
+ case 49786: // 'element' 'comment'
+ case 49851: // 'namespace' 'comment'
+ case 49884: // 'processing-instruction' 'comment'
+ case 50259: // 'attribute' 'constraint'
+ case 50298: // 'element' 'constraint'
+ case 50363: // 'namespace' 'constraint'
+ case 50396: // 'processing-instruction' 'constraint'
+ case 50771: // 'attribute' 'construction'
+ case 50810: // 'element' 'construction'
+ case 50875: // 'namespace' 'construction'
+ case 50908: // 'processing-instruction' 'construction'
+ case 52307: // 'attribute' 'context'
+ case 52346: // 'element' 'context'
+ case 52411: // 'namespace' 'context'
+ case 52444: // 'processing-instruction' 'context'
+ case 52819: // 'attribute' 'continue'
+ case 52858: // 'element' 'continue'
+ case 52923: // 'namespace' 'continue'
+ case 52956: // 'processing-instruction' 'continue'
+ case 53331: // 'attribute' 'copy'
+ case 53370: // 'element' 'copy'
+ case 53435: // 'namespace' 'copy'
+ case 53468: // 'processing-instruction' 'copy'
+ case 53843: // 'attribute' 'copy-namespaces'
+ case 53882: // 'element' 'copy-namespaces'
+ case 53947: // 'namespace' 'copy-namespaces'
+ case 53980: // 'processing-instruction' 'copy-namespaces'
+ case 54867: // 'attribute' 'decimal-format'
+ case 54906: // 'element' 'decimal-format'
+ case 54971: // 'namespace' 'decimal-format'
+ case 55004: // 'processing-instruction' 'decimal-format'
+ case 55891: // 'attribute' 'declare'
+ case 55930: // 'element' 'declare'
+ case 55995: // 'namespace' 'declare'
+ case 56028: // 'processing-instruction' 'declare'
+ case 56915: // 'attribute' 'delete'
+ case 56954: // 'element' 'delete'
+ case 57019: // 'namespace' 'delete'
+ case 57052: // 'processing-instruction' 'delete'
+ case 57427: // 'attribute' 'descendant'
+ case 57466: // 'element' 'descendant'
+ case 57531: // 'namespace' 'descendant'
+ case 57564: // 'processing-instruction' 'descendant'
+ case 57939: // 'attribute' 'descendant-or-self'
+ case 57978: // 'element' 'descendant-or-self'
+ case 58043: // 'namespace' 'descendant-or-self'
+ case 58076: // 'processing-instruction' 'descendant-or-self'
+ case 61523: // 'attribute' 'document'
+ case 61562: // 'element' 'document'
+ case 61627: // 'namespace' 'document'
+ case 61660: // 'processing-instruction' 'document'
+ case 62035: // 'attribute' 'document-node'
+ case 62074: // 'element' 'document-node'
+ case 62139: // 'namespace' 'document-node'
+ case 62172: // 'processing-instruction' 'document-node'
+ case 62547: // 'attribute' 'element'
+ case 62586: // 'element' 'element'
+ case 62651: // 'namespace' 'element'
+ case 62684: // 'processing-instruction' 'element'
+ case 64083: // 'attribute' 'empty-sequence'
+ case 64122: // 'element' 'empty-sequence'
+ case 64187: // 'namespace' 'empty-sequence'
+ case 64220: // 'processing-instruction' 'empty-sequence'
+ case 64595: // 'attribute' 'encoding'
+ case 64634: // 'element' 'encoding'
+ case 64699: // 'namespace' 'encoding'
+ case 64732: // 'processing-instruction' 'encoding'
+ case 66643: // 'attribute' 'every'
+ case 66682: // 'element' 'every'
+ case 66747: // 'namespace' 'every'
+ case 66780: // 'processing-instruction' 'every'
+ case 68179: // 'attribute' 'exit'
+ case 68218: // 'element' 'exit'
+ case 68283: // 'namespace' 'exit'
+ case 68316: // 'processing-instruction' 'exit'
+ case 68691: // 'attribute' 'external'
+ case 68730: // 'element' 'external'
+ case 68795: // 'namespace' 'external'
+ case 68828: // 'processing-instruction' 'external'
+ case 69203: // 'attribute' 'false'
+ case 69242: // 'element' 'false'
+ case 69307: // 'namespace' 'false'
+ case 69340: // 'processing-instruction' 'false'
+ case 69715: // 'attribute' 'first'
+ case 69754: // 'element' 'first'
+ case 69819: // 'namespace' 'first'
+ case 69852: // 'processing-instruction' 'first'
+ case 70227: // 'attribute' 'following'
+ case 70266: // 'element' 'following'
+ case 70331: // 'namespace' 'following'
+ case 70364: // 'processing-instruction' 'following'
+ case 70739: // 'attribute' 'following-sibling'
+ case 70778: // 'element' 'following-sibling'
+ case 70843: // 'namespace' 'following-sibling'
+ case 70876: // 'processing-instruction' 'following-sibling'
+ case 72787: // 'attribute' 'from'
+ case 72826: // 'element' 'from'
+ case 72891: // 'namespace' 'from'
+ case 72924: // 'processing-instruction' 'from'
+ case 73299: // 'attribute' 'ft-option'
+ case 73338: // 'element' 'ft-option'
+ case 73403: // 'namespace' 'ft-option'
+ case 73436: // 'processing-instruction' 'ft-option'
+ case 75347: // 'attribute' 'function'
+ case 75386: // 'element' 'function'
+ case 75451: // 'namespace' 'function'
+ case 75484: // 'processing-instruction' 'function'
+ case 78931: // 'attribute' 'if'
+ case 78970: // 'element' 'if'
+ case 79035: // 'namespace' 'if'
+ case 79068: // 'processing-instruction' 'if'
+ case 79443: // 'attribute' 'import'
+ case 79482: // 'element' 'import'
+ case 79547: // 'namespace' 'import'
+ case 79580: // 'processing-instruction' 'import'
+ case 79955: // 'attribute' 'in'
+ case 79994: // 'element' 'in'
+ case 80059: // 'namespace' 'in'
+ case 80092: // 'processing-instruction' 'in'
+ case 80467: // 'attribute' 'index'
+ case 80506: // 'element' 'index'
+ case 80571: // 'namespace' 'index'
+ case 80604: // 'processing-instruction' 'index'
+ case 82515: // 'attribute' 'insert'
+ case 82554: // 'element' 'insert'
+ case 82619: // 'namespace' 'insert'
+ case 82652: // 'processing-instruction' 'insert'
+ case 83539: // 'attribute' 'integrity'
+ case 83578: // 'element' 'integrity'
+ case 83643: // 'namespace' 'integrity'
+ case 83676: // 'processing-instruction' 'integrity'
+ case 85587: // 'attribute' 'item'
+ case 85626: // 'element' 'item'
+ case 85691: // 'namespace' 'item'
+ case 85724: // 'processing-instruction' 'item'
+ case 86099: // 'attribute' 'json'
+ case 86138: // 'element' 'json'
+ case 86203: // 'namespace' 'json'
+ case 86236: // 'processing-instruction' 'json'
+ case 86611: // 'attribute' 'json-item'
+ case 86650: // 'element' 'json-item'
+ case 87123: // 'attribute' 'jsoniq'
+ case 87162: // 'element' 'jsoniq'
+ case 87227: // 'namespace' 'jsoniq'
+ case 87260: // 'processing-instruction' 'jsoniq'
+ case 88659: // 'attribute' 'last'
+ case 88698: // 'element' 'last'
+ case 88763: // 'namespace' 'last'
+ case 88796: // 'processing-instruction' 'last'
+ case 89171: // 'attribute' 'lax'
+ case 89210: // 'element' 'lax'
+ case 89275: // 'namespace' 'lax'
+ case 89308: // 'processing-instruction' 'lax'
+ case 91731: // 'attribute' 'loop'
+ case 91770: // 'element' 'loop'
+ case 91835: // 'namespace' 'loop'
+ case 91868: // 'processing-instruction' 'loop'
+ case 94803: // 'attribute' 'module'
+ case 94842: // 'element' 'module'
+ case 94907: // 'namespace' 'module'
+ case 94940: // 'processing-instruction' 'module'
+ case 95827: // 'attribute' 'namespace'
+ case 95866: // 'element' 'namespace'
+ case 95931: // 'namespace' 'namespace'
+ case 95964: // 'processing-instruction' 'namespace'
+ case 96339: // 'attribute' 'namespace-node'
+ case 96378: // 'element' 'namespace-node'
+ case 96443: // 'namespace' 'namespace-node'
+ case 96476: // 'processing-instruction' 'namespace-node'
+ case 99411: // 'attribute' 'node'
+ case 99450: // 'element' 'node'
+ case 99515: // 'namespace' 'node'
+ case 99548: // 'processing-instruction' 'node'
+ case 99923: // 'attribute' 'nodes'
+ case 99962: // 'element' 'nodes'
+ case 100027: // 'namespace' 'nodes'
+ case 100060: // 'processing-instruction' 'nodes'
+ case 100947: // 'attribute' 'null'
+ case 100986: // 'element' 'null'
+ case 101051: // 'namespace' 'null'
+ case 101084: // 'processing-instruction' 'null'
+ case 101459: // 'attribute' 'object'
+ case 101498: // 'element' 'object'
+ case 101563: // 'namespace' 'object'
+ case 101596: // 'processing-instruction' 'object'
+ case 104019: // 'attribute' 'option'
+ case 104058: // 'element' 'option'
+ case 104123: // 'namespace' 'option'
+ case 104156: // 'processing-instruction' 'option'
+ case 105555: // 'attribute' 'ordered'
+ case 105594: // 'element' 'ordered'
+ case 105659: // 'namespace' 'ordered'
+ case 105692: // 'processing-instruction' 'ordered'
+ case 106067: // 'attribute' 'ordering'
+ case 106106: // 'element' 'ordering'
+ case 106171: // 'namespace' 'ordering'
+ case 106204: // 'processing-instruction' 'ordering'
+ case 107603: // 'attribute' 'parent'
+ case 107642: // 'element' 'parent'
+ case 107707: // 'namespace' 'parent'
+ case 107740: // 'processing-instruction' 'parent'
+ case 110675: // 'attribute' 'preceding'
+ case 110714: // 'element' 'preceding'
+ case 110779: // 'namespace' 'preceding'
+ case 110812: // 'processing-instruction' 'preceding'
+ case 111187: // 'attribute' 'preceding-sibling'
+ case 111226: // 'element' 'preceding-sibling'
+ case 111291: // 'namespace' 'preceding-sibling'
+ case 111324: // 'processing-instruction' 'preceding-sibling'
+ case 112723: // 'attribute' 'processing-instruction'
+ case 112762: // 'element' 'processing-instruction'
+ case 112827: // 'namespace' 'processing-instruction'
+ case 112860: // 'processing-instruction' 'processing-instruction'
+ case 113747: // 'attribute' 'rename'
+ case 113786: // 'element' 'rename'
+ case 113851: // 'namespace' 'rename'
+ case 113884: // 'processing-instruction' 'rename'
+ case 114259: // 'attribute' 'replace'
+ case 114298: // 'element' 'replace'
+ case 114363: // 'namespace' 'replace'
+ case 114396: // 'processing-instruction' 'replace'
+ case 115283: // 'attribute' 'returning'
+ case 115322: // 'element' 'returning'
+ case 115387: // 'namespace' 'returning'
+ case 115420: // 'processing-instruction' 'returning'
+ case 115795: // 'attribute' 'revalidation'
+ case 115834: // 'element' 'revalidation'
+ case 115899: // 'namespace' 'revalidation'
+ case 115932: // 'processing-instruction' 'revalidation'
+ case 117331: // 'attribute' 'schema'
+ case 117370: // 'element' 'schema'
+ case 117435: // 'namespace' 'schema'
+ case 117468: // 'processing-instruction' 'schema'
+ case 117843: // 'attribute' 'schema-attribute'
+ case 117882: // 'element' 'schema-attribute'
+ case 117947: // 'namespace' 'schema-attribute'
+ case 117980: // 'processing-instruction' 'schema-attribute'
+ case 118355: // 'attribute' 'schema-element'
+ case 118394: // 'element' 'schema-element'
+ case 118459: // 'namespace' 'schema-element'
+ case 118492: // 'processing-instruction' 'schema-element'
+ case 118867: // 'attribute' 'score'
+ case 118906: // 'element' 'score'
+ case 118971: // 'namespace' 'score'
+ case 119004: // 'processing-instruction' 'score'
+ case 119379: // 'attribute' 'select'
+ case 119418: // 'element' 'select'
+ case 119483: // 'namespace' 'select'
+ case 119516: // 'processing-instruction' 'select'
+ case 119891: // 'attribute' 'self'
+ case 119930: // 'element' 'self'
+ case 119995: // 'namespace' 'self'
+ case 120028: // 'processing-instruction' 'self'
+ case 122451: // 'attribute' 'sliding'
+ case 122490: // 'element' 'sliding'
+ case 122555: // 'namespace' 'sliding'
+ case 122588: // 'processing-instruction' 'sliding'
+ case 122963: // 'attribute' 'some'
+ case 123002: // 'element' 'some'
+ case 123067: // 'namespace' 'some'
+ case 123100: // 'processing-instruction' 'some'
+ case 125523: // 'attribute' 'strict'
+ case 125562: // 'element' 'strict'
+ case 125627: // 'namespace' 'strict'
+ case 125660: // 'processing-instruction' 'strict'
+ case 126547: // 'attribute' 'structured-item'
+ case 126586: // 'element' 'structured-item'
+ case 127059: // 'attribute' 'switch'
+ case 127098: // 'element' 'switch'
+ case 127163: // 'namespace' 'switch'
+ case 127196: // 'processing-instruction' 'switch'
+ case 127571: // 'attribute' 'text'
+ case 127610: // 'element' 'text'
+ case 127675: // 'namespace' 'text'
+ case 127708: // 'processing-instruction' 'text'
+ case 130643: // 'attribute' 'true'
+ case 130682: // 'element' 'true'
+ case 130747: // 'namespace' 'true'
+ case 130780: // 'processing-instruction' 'true'
+ case 131155: // 'attribute' 'try'
+ case 131194: // 'element' 'try'
+ case 131259: // 'namespace' 'try'
+ case 131292: // 'processing-instruction' 'try'
+ case 131667: // 'attribute' 'tumbling'
+ case 131706: // 'element' 'tumbling'
+ case 131771: // 'namespace' 'tumbling'
+ case 131804: // 'processing-instruction' 'tumbling'
+ case 132179: // 'attribute' 'type'
+ case 132218: // 'element' 'type'
+ case 132283: // 'namespace' 'type'
+ case 132316: // 'processing-instruction' 'type'
+ case 132691: // 'attribute' 'typeswitch'
+ case 132730: // 'element' 'typeswitch'
+ case 132795: // 'namespace' 'typeswitch'
+ case 132828: // 'processing-instruction' 'typeswitch'
+ case 134227: // 'attribute' 'unordered'
+ case 134266: // 'element' 'unordered'
+ case 134331: // 'namespace' 'unordered'
+ case 134364: // 'processing-instruction' 'unordered'
+ case 134739: // 'attribute' 'updating'
+ case 134778: // 'element' 'updating'
+ case 134843: // 'namespace' 'updating'
+ case 134876: // 'processing-instruction' 'updating'
+ case 136275: // 'attribute' 'validate'
+ case 136314: // 'element' 'validate'
+ case 136379: // 'namespace' 'validate'
+ case 136412: // 'processing-instruction' 'validate'
+ case 136787: // 'attribute' 'value'
+ case 136826: // 'element' 'value'
+ case 136891: // 'namespace' 'value'
+ case 136924: // 'processing-instruction' 'value'
+ case 137299: // 'attribute' 'variable'
+ case 137338: // 'element' 'variable'
+ case 137403: // 'namespace' 'variable'
+ case 137436: // 'processing-instruction' 'variable'
+ case 137811: // 'attribute' 'version'
+ case 137850: // 'element' 'version'
+ case 137915: // 'namespace' 'version'
+ case 137948: // 'processing-instruction' 'version'
+ case 139859: // 'attribute' 'while'
+ case 139898: // 'element' 'while'
+ case 139963: // 'namespace' 'while'
+ case 139996: // 'processing-instruction' 'while'
+ case 143955: // 'attribute' '{'
+ case 143969: // 'comment' '{'
+ case 143992: // 'document' '{'
+ case 143994: // 'element' '{'
+ case 144059: // 'namespace' '{'
+ case 144078: // 'ordered' '{'
+ case 144092: // 'processing-instruction' '{'
+ case 144121: // 'text' '{'
+ case 144134: // 'unordered' '{'
+ parse_PostfixExpr();
+ break;
+ default:
+ parse_AxisStep();
+ }
+ eventHandler.endNonterminal("StepExpr", e0);
+ }
+
+ function try_StepExpr()
+ {
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ lookahead2W(287); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 122: // 'element'
+ lookahead2W(286); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 187: // 'namespace'
+ case 220: // 'processing-instruction'
+ lookahead2W(284); // NCName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(236); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '.' |
+ break;
+ case 97: // 'comment'
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 249: // 'text'
+ case 262: // 'unordered'
+ lookahead2W(238); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 79: // 'array'
+ case 125: // 'empty-sequence'
+ case 154: // 'if'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 247: // 'structured-item'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ lookahead2W(229); // S^WS | EOF | '!' | '!=' | '#' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 94: // 'child'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 234: // 'self'
+ lookahead2W(237); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 6: // EQName^Token
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 76: // 'and'
+ case 78: // 'append'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 87: // 'break'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 103: // 'continue'
+ case 104: // 'copy'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 111: // 'delete'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 121: // 'document-node'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 130: // 'every'
+ case 132: // 'except'
+ case 133: // 'exit'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 139: // 'for'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 147: // 'function'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 161: // 'insert'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 177: // 'let'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 188: // 'namespace-node'
+ case 189: // 'ne'
+ case 194: // 'node'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 222: // 'rename'
+ case 223: // 'replace'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 239: // 'sliding'
+ case 240: // 'some'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 256: // 'try'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 266: // 'validate'
+ case 267: // 'value'
+ case 268: // 'variable'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(233); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 12935 // 'false' EOF
+ || lk == 12997 // 'null' EOF
+ || lk == 13055 // 'true' EOF
+ || lk == 13447 // 'false' '!'
+ || lk == 13509 // 'null' '!'
+ || lk == 13567 // 'true' '!'
+ || lk == 13959 // 'false' '!='
+ || lk == 14021 // 'null' '!='
+ || lk == 14079 // 'true' '!='
+ || lk == 19591 // 'false' ')'
+ || lk == 19653 // 'null' ')'
+ || lk == 19711 // 'true' ')'
+ || lk == 20103 // 'false' '*'
+ || lk == 20165 // 'null' '*'
+ || lk == 20223 // 'true' '*'
+ || lk == 21127 // 'false' '+'
+ || lk == 21189 // 'null' '+'
+ || lk == 21247 // 'true' '+'
+ || lk == 21639 // 'false' ','
+ || lk == 21701 // 'null' ','
+ || lk == 21759 // 'true' ','
+ || lk == 22151 // 'false' '-'
+ || lk == 22213 // 'null' '-'
+ || lk == 22271 // 'true' '-'
+ || lk == 24199 // 'false' '/'
+ || lk == 24261 // 'null' '/'
+ || lk == 24319 // 'true' '/'
+ || lk == 24711 // 'false' '//'
+ || lk == 24773 // 'null' '//'
+ || lk == 24831 // 'true' '//'
+ || lk == 25735 // 'false' ':'
+ || lk == 25797 // 'null' ':'
+ || lk == 25855 // 'true' ':'
+ || lk == 27783 // 'false' ';'
+ || lk == 27845 // 'null' ';'
+ || lk == 27903 // 'true' ';'
+ || lk == 28295 // 'false' '<'
+ || lk == 28357 // 'null' '<'
+ || lk == 28415 // 'true' '<'
+ || lk == 29831 // 'false' '<<'
+ || lk == 29893 // 'null' '<<'
+ || lk == 29951 // 'true' '<<'
+ || lk == 30343 // 'false' '<='
+ || lk == 30405 // 'null' '<='
+ || lk == 30463 // 'true' '<='
+ || lk == 31367 // 'false' '='
+ || lk == 31429 // 'null' '='
+ || lk == 31487 // 'true' '='
+ || lk == 31879 // 'false' '>'
+ || lk == 31941 // 'null' '>'
+ || lk == 31999 // 'true' '>'
+ || lk == 32391 // 'false' '>='
+ || lk == 32453 // 'null' '>='
+ || lk == 32511 // 'true' '>='
+ || lk == 32903 // 'false' '>>'
+ || lk == 32965 // 'null' '>>'
+ || lk == 33023 // 'true' '>>'
+ || lk == 35463 // 'false' '['
+ || lk == 35525 // 'null' '['
+ || lk == 35583 // 'true' '['
+ || lk == 35975 // 'false' ']'
+ || lk == 36037 // 'null' ']'
+ || lk == 36095 // 'true' ']'
+ || lk == 36435 // 'attribute' 'after'
+ || lk == 36474 // 'element' 'after'
+ || lk == 36487 // 'false' 'after'
+ || lk == 36539 // 'namespace' 'after'
+ || lk == 36549 // 'null' 'after'
+ || lk == 36572 // 'processing-instruction' 'after'
+ || lk == 36607 // 'true' 'after'
+ || lk == 38995 // 'attribute' 'and'
+ || lk == 39034 // 'element' 'and'
+ || lk == 39047 // 'false' 'and'
+ || lk == 39099 // 'namespace' 'and'
+ || lk == 39109 // 'null' 'and'
+ || lk == 39132 // 'processing-instruction' 'and'
+ || lk == 39167 // 'true' 'and'
+ || lk == 41043 // 'attribute' 'as'
+ || lk == 41082 // 'element' 'as'
+ || lk == 41095 // 'false' 'as'
+ || lk == 41147 // 'namespace' 'as'
+ || lk == 41157 // 'null' 'as'
+ || lk == 41180 // 'processing-instruction' 'as'
+ || lk == 41215 // 'true' 'as'
+ || lk == 41555 // 'attribute' 'ascending'
+ || lk == 41594 // 'element' 'ascending'
+ || lk == 41607 // 'false' 'ascending'
+ || lk == 41659 // 'namespace' 'ascending'
+ || lk == 41669 // 'null' 'ascending'
+ || lk == 41692 // 'processing-instruction' 'ascending'
+ || lk == 41727 // 'true' 'ascending'
+ || lk == 42067 // 'attribute' 'at'
+ || lk == 42106 // 'element' 'at'
+ || lk == 42119 // 'false' 'at'
+ || lk == 42171 // 'namespace' 'at'
+ || lk == 42181 // 'null' 'at'
+ || lk == 42204 // 'processing-instruction' 'at'
+ || lk == 42239 // 'true' 'at'
+ || lk == 43603 // 'attribute' 'before'
+ || lk == 43642 // 'element' 'before'
+ || lk == 43655 // 'false' 'before'
+ || lk == 43707 // 'namespace' 'before'
+ || lk == 43717 // 'null' 'before'
+ || lk == 43740 // 'processing-instruction' 'before'
+ || lk == 43775 // 'true' 'before'
+ || lk == 45191 // 'false' 'by'
+ || lk == 45253 // 'null' 'by'
+ || lk == 45311 // 'true' 'by'
+ || lk == 45651 // 'attribute' 'case'
+ || lk == 45690 // 'element' 'case'
+ || lk == 45703 // 'false' 'case'
+ || lk == 45755 // 'namespace' 'case'
+ || lk == 45765 // 'null' 'case'
+ || lk == 45788 // 'processing-instruction' 'case'
+ || lk == 45823 // 'true' 'case'
+ || lk == 46163 // 'attribute' 'cast'
+ || lk == 46202 // 'element' 'cast'
+ || lk == 46215 // 'false' 'cast'
+ || lk == 46267 // 'namespace' 'cast'
+ || lk == 46277 // 'null' 'cast'
+ || lk == 46300 // 'processing-instruction' 'cast'
+ || lk == 46335 // 'true' 'cast'
+ || lk == 46675 // 'attribute' 'castable'
+ || lk == 46714 // 'element' 'castable'
+ || lk == 46727 // 'false' 'castable'
+ || lk == 46779 // 'namespace' 'castable'
+ || lk == 46789 // 'null' 'castable'
+ || lk == 46812 // 'processing-instruction' 'castable'
+ || lk == 46847 // 'true' 'castable'
+ || lk == 48723 // 'attribute' 'collation'
+ || lk == 48762 // 'element' 'collation'
+ || lk == 48775 // 'false' 'collation'
+ || lk == 48827 // 'namespace' 'collation'
+ || lk == 48837 // 'null' 'collation'
+ || lk == 48860 // 'processing-instruction' 'collation'
+ || lk == 48895 // 'true' 'collation'
+ || lk == 51335 // 'false' 'contains'
+ || lk == 51397 // 'null' 'contains'
+ || lk == 51455 // 'true' 'contains'
+ || lk == 54355 // 'attribute' 'count'
+ || lk == 54394 // 'element' 'count'
+ || lk == 54407 // 'false' 'count'
+ || lk == 54459 // 'namespace' 'count'
+ || lk == 54469 // 'null' 'count'
+ || lk == 54492 // 'processing-instruction' 'count'
+ || lk == 54527 // 'true' 'count'
+ || lk == 56403 // 'attribute' 'default'
+ || lk == 56442 // 'element' 'default'
+ || lk == 56455 // 'false' 'default'
+ || lk == 56507 // 'namespace' 'default'
+ || lk == 56517 // 'null' 'default'
+ || lk == 56540 // 'processing-instruction' 'default'
+ || lk == 56575 // 'true' 'default'
+ || lk == 58451 // 'attribute' 'descending'
+ || lk == 58490 // 'element' 'descending'
+ || lk == 58503 // 'false' 'descending'
+ || lk == 58555 // 'namespace' 'descending'
+ || lk == 58565 // 'null' 'descending'
+ || lk == 58588 // 'processing-instruction' 'descending'
+ || lk == 58623 // 'true' 'descending'
+ || lk == 61011 // 'attribute' 'div'
+ || lk == 61050 // 'element' 'div'
+ || lk == 61063 // 'false' 'div'
+ || lk == 61115 // 'namespace' 'div'
+ || lk == 61125 // 'null' 'div'
+ || lk == 61148 // 'processing-instruction' 'div'
+ || lk == 61183 // 'true' 'div'
+ || lk == 63059 // 'attribute' 'else'
+ || lk == 63098 // 'element' 'else'
+ || lk == 63111 // 'false' 'else'
+ || lk == 63163 // 'namespace' 'else'
+ || lk == 63173 // 'null' 'else'
+ || lk == 63196 // 'processing-instruction' 'else'
+ || lk == 63231 // 'true' 'else'
+ || lk == 63571 // 'attribute' 'empty'
+ || lk == 63610 // 'element' 'empty'
+ || lk == 63623 // 'false' 'empty'
+ || lk == 63675 // 'namespace' 'empty'
+ || lk == 63685 // 'null' 'empty'
+ || lk == 63708 // 'processing-instruction' 'empty'
+ || lk == 63743 // 'true' 'empty'
+ || lk == 65107 // 'attribute' 'end'
+ || lk == 65146 // 'element' 'end'
+ || lk == 65159 // 'false' 'end'
+ || lk == 65211 // 'namespace' 'end'
+ || lk == 65221 // 'null' 'end'
+ || lk == 65244 // 'processing-instruction' 'end'
+ || lk == 65279 // 'true' 'end'
+ || lk == 66131 // 'attribute' 'eq'
+ || lk == 66170 // 'element' 'eq'
+ || lk == 66183 // 'false' 'eq'
+ || lk == 66235 // 'namespace' 'eq'
+ || lk == 66245 // 'null' 'eq'
+ || lk == 66268 // 'processing-instruction' 'eq'
+ || lk == 66303 // 'true' 'eq'
+ || lk == 67667 // 'attribute' 'except'
+ || lk == 67706 // 'element' 'except'
+ || lk == 67719 // 'false' 'except'
+ || lk == 67771 // 'namespace' 'except'
+ || lk == 67781 // 'null' 'except'
+ || lk == 67804 // 'processing-instruction' 'except'
+ || lk == 67839 // 'true' 'except'
+ || lk == 71251 // 'attribute' 'for'
+ || lk == 71290 // 'element' 'for'
+ || lk == 71303 // 'false' 'for'
+ || lk == 71355 // 'namespace' 'for'
+ || lk == 71365 // 'null' 'for'
+ || lk == 71388 // 'processing-instruction' 'for'
+ || lk == 71423 // 'true' 'for'
+ || lk == 75859 // 'attribute' 'ge'
+ || lk == 75898 // 'element' 'ge'
+ || lk == 75911 // 'false' 'ge'
+ || lk == 75963 // 'namespace' 'ge'
+ || lk == 75973 // 'null' 'ge'
+ || lk == 75996 // 'processing-instruction' 'ge'
+ || lk == 76031 // 'true' 'ge'
+ || lk == 76883 // 'attribute' 'group'
+ || lk == 76922 // 'element' 'group'
+ || lk == 76935 // 'false' 'group'
+ || lk == 76987 // 'namespace' 'group'
+ || lk == 76997 // 'null' 'group'
+ || lk == 77020 // 'processing-instruction' 'group'
+ || lk == 77055 // 'true' 'group'
+ || lk == 77907 // 'attribute' 'gt'
+ || lk == 77946 // 'element' 'gt'
+ || lk == 77959 // 'false' 'gt'
+ || lk == 78011 // 'namespace' 'gt'
+ || lk == 78021 // 'null' 'gt'
+ || lk == 78044 // 'processing-instruction' 'gt'
+ || lk == 78079 // 'true' 'gt'
+ || lk == 78419 // 'attribute' 'idiv'
+ || lk == 78458 // 'element' 'idiv'
+ || lk == 78471 // 'false' 'idiv'
+ || lk == 78523 // 'namespace' 'idiv'
+ || lk == 78533 // 'null' 'idiv'
+ || lk == 78556 // 'processing-instruction' 'idiv'
+ || lk == 78591 // 'true' 'idiv'
+ || lk == 83027 // 'attribute' 'instance'
+ || lk == 83066 // 'element' 'instance'
+ || lk == 83079 // 'false' 'instance'
+ || lk == 83131 // 'namespace' 'instance'
+ || lk == 83141 // 'null' 'instance'
+ || lk == 83164 // 'processing-instruction' 'instance'
+ || lk == 83199 // 'true' 'instance'
+ || lk == 84051 // 'attribute' 'intersect'
+ || lk == 84090 // 'element' 'intersect'
+ || lk == 84103 // 'false' 'intersect'
+ || lk == 84155 // 'namespace' 'intersect'
+ || lk == 84165 // 'null' 'intersect'
+ || lk == 84188 // 'processing-instruction' 'intersect'
+ || lk == 84223 // 'true' 'intersect'
+ || lk == 84563 // 'attribute' 'into'
+ || lk == 84602 // 'element' 'into'
+ || lk == 84615 // 'false' 'into'
+ || lk == 84667 // 'namespace' 'into'
+ || lk == 84677 // 'null' 'into'
+ || lk == 84700 // 'processing-instruction' 'into'
+ || lk == 84735 // 'true' 'into'
+ || lk == 85075 // 'attribute' 'is'
+ || lk == 85114 // 'element' 'is'
+ || lk == 85127 // 'false' 'is'
+ || lk == 85179 // 'namespace' 'is'
+ || lk == 85189 // 'null' 'is'
+ || lk == 85212 // 'processing-instruction' 'is'
+ || lk == 85247 // 'true' 'is'
+ || lk == 89683 // 'attribute' 'le'
+ || lk == 89722 // 'element' 'le'
+ || lk == 89735 // 'false' 'le'
+ || lk == 89787 // 'namespace' 'le'
+ || lk == 89797 // 'null' 'le'
+ || lk == 89820 // 'processing-instruction' 'le'
+ || lk == 89855 // 'true' 'le'
+ || lk == 90707 // 'attribute' 'let'
+ || lk == 90746 // 'element' 'let'
+ || lk == 90759 // 'false' 'let'
+ || lk == 90811 // 'namespace' 'let'
+ || lk == 90821 // 'null' 'let'
+ || lk == 90844 // 'processing-instruction' 'let'
+ || lk == 90879 // 'true' 'let'
+ || lk == 92755 // 'attribute' 'lt'
+ || lk == 92794 // 'element' 'lt'
+ || lk == 92807 // 'false' 'lt'
+ || lk == 92859 // 'namespace' 'lt'
+ || lk == 92869 // 'null' 'lt'
+ || lk == 92892 // 'processing-instruction' 'lt'
+ || lk == 92927 // 'true' 'lt'
+ || lk == 93779 // 'attribute' 'mod'
+ || lk == 93818 // 'element' 'mod'
+ || lk == 93831 // 'false' 'mod'
+ || lk == 93883 // 'namespace' 'mod'
+ || lk == 93893 // 'null' 'mod'
+ || lk == 93916 // 'processing-instruction' 'mod'
+ || lk == 93951 // 'true' 'mod'
+ || lk == 94291 // 'attribute' 'modify'
+ || lk == 94330 // 'element' 'modify'
+ || lk == 94343 // 'false' 'modify'
+ || lk == 94395 // 'namespace' 'modify'
+ || lk == 94405 // 'null' 'modify'
+ || lk == 94428 // 'processing-instruction' 'modify'
+ || lk == 94463 // 'true' 'modify'
+ || lk == 96851 // 'attribute' 'ne'
+ || lk == 96890 // 'element' 'ne'
+ || lk == 96903 // 'false' 'ne'
+ || lk == 96955 // 'namespace' 'ne'
+ || lk == 96965 // 'null' 'ne'
+ || lk == 96988 // 'processing-instruction' 'ne'
+ || lk == 97023 // 'true' 'ne'
+ || lk == 103507 // 'attribute' 'only'
+ || lk == 103546 // 'element' 'only'
+ || lk == 103559 // 'false' 'only'
+ || lk == 103611 // 'namespace' 'only'
+ || lk == 103621 // 'null' 'only'
+ || lk == 103644 // 'processing-instruction' 'only'
+ || lk == 103679 // 'true' 'only'
+ || lk == 104531 // 'attribute' 'or'
+ || lk == 104570 // 'element' 'or'
+ || lk == 104583 // 'false' 'or'
+ || lk == 104635 // 'namespace' 'or'
+ || lk == 104645 // 'null' 'or'
+ || lk == 104668 // 'processing-instruction' 'or'
+ || lk == 104703 // 'true' 'or'
+ || lk == 105043 // 'attribute' 'order'
+ || lk == 105082 // 'element' 'order'
+ || lk == 105095 // 'false' 'order'
+ || lk == 105147 // 'namespace' 'order'
+ || lk == 105157 // 'null' 'order'
+ || lk == 105180 // 'processing-instruction' 'order'
+ || lk == 105215 // 'true' 'order'
+ || lk == 107143 // 'false' 'paragraphs'
+ || lk == 107205 // 'null' 'paragraphs'
+ || lk == 107263 // 'true' 'paragraphs'
+ || lk == 114771 // 'attribute' 'return'
+ || lk == 114810 // 'element' 'return'
+ || lk == 114823 // 'false' 'return'
+ || lk == 114875 // 'namespace' 'return'
+ || lk == 114885 // 'null' 'return'
+ || lk == 114908 // 'processing-instruction' 'return'
+ || lk == 114943 // 'true' 'return'
+ || lk == 116819 // 'attribute' 'satisfies'
+ || lk == 116858 // 'element' 'satisfies'
+ || lk == 116871 // 'false' 'satisfies'
+ || lk == 116923 // 'namespace' 'satisfies'
+ || lk == 116933 // 'null' 'satisfies'
+ || lk == 116956 // 'processing-instruction' 'satisfies'
+ || lk == 116991 // 'true' 'satisfies'
+ || lk == 121479 // 'false' 'sentences'
+ || lk == 121541 // 'null' 'sentences'
+ || lk == 121599 // 'true' 'sentences'
+ || lk == 123475 // 'attribute' 'stable'
+ || lk == 123514 // 'element' 'stable'
+ || lk == 123527 // 'false' 'stable'
+ || lk == 123579 // 'namespace' 'stable'
+ || lk == 123589 // 'null' 'stable'
+ || lk == 123612 // 'processing-instruction' 'stable'
+ || lk == 123647 // 'true' 'stable'
+ || lk == 123987 // 'attribute' 'start'
+ || lk == 124026 // 'element' 'start'
+ || lk == 124039 // 'false' 'start'
+ || lk == 124091 // 'namespace' 'start'
+ || lk == 124101 // 'null' 'start'
+ || lk == 124124 // 'processing-instruction' 'start'
+ || lk == 124159 // 'true' 'start'
+ || lk == 129159 // 'false' 'times'
+ || lk == 129221 // 'null' 'times'
+ || lk == 129279 // 'true' 'times'
+ || lk == 129619 // 'attribute' 'to'
+ || lk == 129658 // 'element' 'to'
+ || lk == 129671 // 'false' 'to'
+ || lk == 129723 // 'namespace' 'to'
+ || lk == 129733 // 'null' 'to'
+ || lk == 129756 // 'processing-instruction' 'to'
+ || lk == 129791 // 'true' 'to'
+ || lk == 130131 // 'attribute' 'treat'
+ || lk == 130170 // 'element' 'treat'
+ || lk == 130183 // 'false' 'treat'
+ || lk == 130235 // 'namespace' 'treat'
+ || lk == 130245 // 'null' 'treat'
+ || lk == 130268 // 'processing-instruction' 'treat'
+ || lk == 130303 // 'true' 'treat'
+ || lk == 133203 // 'attribute' 'union'
+ || lk == 133242 // 'element' 'union'
+ || lk == 133255 // 'false' 'union'
+ || lk == 133307 // 'namespace' 'union'
+ || lk == 133317 // 'null' 'union'
+ || lk == 133340 // 'processing-instruction' 'union'
+ || lk == 133375 // 'true' 'union'
+ || lk == 139347 // 'attribute' 'where'
+ || lk == 139386 // 'element' 'where'
+ || lk == 139399 // 'false' 'where'
+ || lk == 139451 // 'namespace' 'where'
+ || lk == 139461 // 'null' 'where'
+ || lk == 139484 // 'processing-instruction' 'where'
+ || lk == 139519 // 'true' 'where'
+ || lk == 141395 // 'attribute' 'with'
+ || lk == 141434 // 'element' 'with'
+ || lk == 141447 // 'false' 'with'
+ || lk == 141499 // 'namespace' 'with'
+ || lk == 141509 // 'null' 'with'
+ || lk == 141532 // 'processing-instruction' 'with'
+ || lk == 141567 // 'true' 'with'
+ || lk == 142983 // 'false' 'words'
+ || lk == 143045 // 'null' 'words'
+ || lk == 143103 // 'true' 'words'
+ || lk == 145543 // 'false' '|'
+ || lk == 145605 // 'null' '|'
+ || lk == 145663 // 'true' '|'
+ || lk == 146055 // 'false' '||'
+ || lk == 146117 // 'null' '||'
+ || lk == 146175 // 'true' '||'
+ || lk == 146567 // 'false' '|}'
+ || lk == 146629 // 'null' '|}'
+ || lk == 146687 // 'true' '|}'
+ || lk == 147079 // 'false' '}'
+ || lk == 147141 // 'null' '}'
+ || lk == 147199) // 'true' '}'
+ {
+ lk = memoized(4, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_PostfixExpr();
+ memoize(4, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(4, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 31: // '$'
+ case 32: // '$$'
+ case 33: // '%'
+ case 35: // '('
+ case 55: // '<'
+ case 56: // '<!--'
+ case 60: // '<?'
+ case 69: // '['
+ case 281: // '{'
+ case 283: // '{|'
+ case 3155: // 'attribute' EQName^Token
+ case 3194: // 'element' EQName^Token
+ case 9915: // 'namespace' NCName^Token
+ case 9948: // 'processing-instruction' NCName^Token
+ case 14854: // EQName^Token '#'
+ case 14919: // 'after' '#'
+ case 14921: // 'allowing' '#'
+ case 14922: // 'ancestor' '#'
+ case 14923: // 'ancestor-or-self' '#'
+ case 14924: // 'and' '#'
+ case 14926: // 'append' '#'
+ case 14927: // 'array' '#'
+ case 14928: // 'as' '#'
+ case 14929: // 'ascending' '#'
+ case 14930: // 'at' '#'
+ case 14931: // 'attribute' '#'
+ case 14932: // 'base-uri' '#'
+ case 14933: // 'before' '#'
+ case 14934: // 'boundary-space' '#'
+ case 14935: // 'break' '#'
+ case 14937: // 'case' '#'
+ case 14938: // 'cast' '#'
+ case 14939: // 'castable' '#'
+ case 14940: // 'catch' '#'
+ case 14942: // 'child' '#'
+ case 14943: // 'collation' '#'
+ case 14945: // 'comment' '#'
+ case 14946: // 'constraint' '#'
+ case 14947: // 'construction' '#'
+ case 14950: // 'context' '#'
+ case 14951: // 'continue' '#'
+ case 14952: // 'copy' '#'
+ case 14953: // 'copy-namespaces' '#'
+ case 14954: // 'count' '#'
+ case 14955: // 'decimal-format' '#'
+ case 14957: // 'declare' '#'
+ case 14958: // 'default' '#'
+ case 14959: // 'delete' '#'
+ case 14960: // 'descendant' '#'
+ case 14961: // 'descendant-or-self' '#'
+ case 14962: // 'descending' '#'
+ case 14967: // 'div' '#'
+ case 14968: // 'document' '#'
+ case 14969: // 'document-node' '#'
+ case 14970: // 'element' '#'
+ case 14971: // 'else' '#'
+ case 14972: // 'empty' '#'
+ case 14973: // 'empty-sequence' '#'
+ case 14974: // 'encoding' '#'
+ case 14975: // 'end' '#'
+ case 14977: // 'eq' '#'
+ case 14978: // 'every' '#'
+ case 14980: // 'except' '#'
+ case 14981: // 'exit' '#'
+ case 14982: // 'external' '#'
+ case 14983: // 'false' '#'
+ case 14984: // 'first' '#'
+ case 14985: // 'following' '#'
+ case 14986: // 'following-sibling' '#'
+ case 14987: // 'for' '#'
+ case 14990: // 'from' '#'
+ case 14991: // 'ft-option' '#'
+ case 14995: // 'function' '#'
+ case 14996: // 'ge' '#'
+ case 14998: // 'group' '#'
+ case 15000: // 'gt' '#'
+ case 15001: // 'idiv' '#'
+ case 15002: // 'if' '#'
+ case 15003: // 'import' '#'
+ case 15004: // 'in' '#'
+ case 15005: // 'index' '#'
+ case 15009: // 'insert' '#'
+ case 15010: // 'instance' '#'
+ case 15011: // 'integrity' '#'
+ case 15012: // 'intersect' '#'
+ case 15013: // 'into' '#'
+ case 15014: // 'is' '#'
+ case 15015: // 'item' '#'
+ case 15016: // 'json' '#'
+ case 15017: // 'json-item' '#'
+ case 15018: // 'jsoniq' '#'
+ case 15021: // 'last' '#'
+ case 15022: // 'lax' '#'
+ case 15023: // 'le' '#'
+ case 15025: // 'let' '#'
+ case 15027: // 'loop' '#'
+ case 15029: // 'lt' '#'
+ case 15031: // 'mod' '#'
+ case 15032: // 'modify' '#'
+ case 15033: // 'module' '#'
+ case 15035: // 'namespace' '#'
+ case 15036: // 'namespace-node' '#'
+ case 15037: // 'ne' '#'
+ case 15042: // 'node' '#'
+ case 15043: // 'nodes' '#'
+ case 15045: // 'null' '#'
+ case 15046: // 'object' '#'
+ case 15050: // 'only' '#'
+ case 15051: // 'option' '#'
+ case 15052: // 'or' '#'
+ case 15053: // 'order' '#'
+ case 15054: // 'ordered' '#'
+ case 15055: // 'ordering' '#'
+ case 15058: // 'parent' '#'
+ case 15064: // 'preceding' '#'
+ case 15065: // 'preceding-sibling' '#'
+ case 15068: // 'processing-instruction' '#'
+ case 15070: // 'rename' '#'
+ case 15071: // 'replace' '#'
+ case 15072: // 'return' '#'
+ case 15073: // 'returning' '#'
+ case 15074: // 'revalidation' '#'
+ case 15076: // 'satisfies' '#'
+ case 15077: // 'schema' '#'
+ case 15078: // 'schema-attribute' '#'
+ case 15079: // 'schema-element' '#'
+ case 15080: // 'score' '#'
+ case 15081: // 'select' '#'
+ case 15082: // 'self' '#'
+ case 15087: // 'sliding' '#'
+ case 15088: // 'some' '#'
+ case 15089: // 'stable' '#'
+ case 15090: // 'start' '#'
+ case 15093: // 'strict' '#'
+ case 15095: // 'structured-item' '#'
+ case 15096: // 'switch' '#'
+ case 15097: // 'text' '#'
+ case 15101: // 'to' '#'
+ case 15102: // 'treat' '#'
+ case 15103: // 'true' '#'
+ case 15104: // 'try' '#'
+ case 15105: // 'tumbling' '#'
+ case 15106: // 'type' '#'
+ case 15107: // 'typeswitch' '#'
+ case 15108: // 'union' '#'
+ case 15110: // 'unordered' '#'
+ case 15111: // 'updating' '#'
+ case 15114: // 'validate' '#'
+ case 15115: // 'value' '#'
+ case 15116: // 'variable' '#'
+ case 15117: // 'version' '#'
+ case 15120: // 'where' '#'
+ case 15121: // 'while' '#'
+ case 15124: // 'with' '#'
+ case 17926: // EQName^Token '('
+ case 17991: // 'after' '('
+ case 17993: // 'allowing' '('
+ case 17994: // 'ancestor' '('
+ case 17995: // 'ancestor-or-self' '('
+ case 17996: // 'and' '('
+ case 17998: // 'append' '('
+ case 18000: // 'as' '('
+ case 18001: // 'ascending' '('
+ case 18002: // 'at' '('
+ case 18004: // 'base-uri' '('
+ case 18005: // 'before' '('
+ case 18006: // 'boundary-space' '('
+ case 18007: // 'break' '('
+ case 18009: // 'case' '('
+ case 18010: // 'cast' '('
+ case 18011: // 'castable' '('
+ case 18012: // 'catch' '('
+ case 18014: // 'child' '('
+ case 18015: // 'collation' '('
+ case 18018: // 'constraint' '('
+ case 18019: // 'construction' '('
+ case 18022: // 'context' '('
+ case 18023: // 'continue' '('
+ case 18024: // 'copy' '('
+ case 18025: // 'copy-namespaces' '('
+ case 18026: // 'count' '('
+ case 18027: // 'decimal-format' '('
+ case 18029: // 'declare' '('
+ case 18030: // 'default' '('
+ case 18031: // 'delete' '('
+ case 18032: // 'descendant' '('
+ case 18033: // 'descendant-or-self' '('
+ case 18034: // 'descending' '('
+ case 18039: // 'div' '('
+ case 18040: // 'document' '('
+ case 18043: // 'else' '('
+ case 18044: // 'empty' '('
+ case 18046: // 'encoding' '('
+ case 18047: // 'end' '('
+ case 18049: // 'eq' '('
+ case 18050: // 'every' '('
+ case 18052: // 'except' '('
+ case 18053: // 'exit' '('
+ case 18054: // 'external' '('
+ case 18055: // 'false' '('
+ case 18056: // 'first' '('
+ case 18057: // 'following' '('
+ case 18058: // 'following-sibling' '('
+ case 18059: // 'for' '('
+ case 18062: // 'from' '('
+ case 18063: // 'ft-option' '('
+ case 18067: // 'function' '('
+ case 18068: // 'ge' '('
+ case 18070: // 'group' '('
+ case 18072: // 'gt' '('
+ case 18073: // 'idiv' '('
+ case 18075: // 'import' '('
+ case 18076: // 'in' '('
+ case 18077: // 'index' '('
+ case 18081: // 'insert' '('
+ case 18082: // 'instance' '('
+ case 18083: // 'integrity' '('
+ case 18084: // 'intersect' '('
+ case 18085: // 'into' '('
+ case 18086: // 'is' '('
+ case 18088: // 'json' '('
+ case 18090: // 'jsoniq' '('
+ case 18093: // 'last' '('
+ case 18094: // 'lax' '('
+ case 18095: // 'le' '('
+ case 18097: // 'let' '('
+ case 18099: // 'loop' '('
+ case 18101: // 'lt' '('
+ case 18103: // 'mod' '('
+ case 18104: // 'modify' '('
+ case 18105: // 'module' '('
+ case 18107: // 'namespace' '('
+ case 18109: // 'ne' '('
+ case 18115: // 'nodes' '('
+ case 18117: // 'null' '('
+ case 18118: // 'object' '('
+ case 18122: // 'only' '('
+ case 18123: // 'option' '('
+ case 18124: // 'or' '('
+ case 18125: // 'order' '('
+ case 18126: // 'ordered' '('
+ case 18127: // 'ordering' '('
+ case 18130: // 'parent' '('
+ case 18136: // 'preceding' '('
+ case 18137: // 'preceding-sibling' '('
+ case 18142: // 'rename' '('
+ case 18143: // 'replace' '('
+ case 18144: // 'return' '('
+ case 18145: // 'returning' '('
+ case 18146: // 'revalidation' '('
+ case 18148: // 'satisfies' '('
+ case 18149: // 'schema' '('
+ case 18152: // 'score' '('
+ case 18153: // 'select' '('
+ case 18154: // 'self' '('
+ case 18159: // 'sliding' '('
+ case 18160: // 'some' '('
+ case 18161: // 'stable' '('
+ case 18162: // 'start' '('
+ case 18165: // 'strict' '('
+ case 18173: // 'to' '('
+ case 18174: // 'treat' '('
+ case 18175: // 'true' '('
+ case 18176: // 'try' '('
+ case 18177: // 'tumbling' '('
+ case 18178: // 'type' '('
+ case 18180: // 'union' '('
+ case 18182: // 'unordered' '('
+ case 18183: // 'updating' '('
+ case 18186: // 'validate' '('
+ case 18187: // 'value' '('
+ case 18188: // 'variable' '('
+ case 18189: // 'version' '('
+ case 18192: // 'where' '('
+ case 18193: // 'while' '('
+ case 18196: // 'with' '('
+ case 23175: // 'false' '.'
+ case 23237: // 'null' '.'
+ case 23295: // 'true' '.'
+ case 37459: // 'attribute' 'allowing'
+ case 37498: // 'element' 'allowing'
+ case 37563: // 'namespace' 'allowing'
+ case 37596: // 'processing-instruction' 'allowing'
+ case 37971: // 'attribute' 'ancestor'
+ case 38010: // 'element' 'ancestor'
+ case 38075: // 'namespace' 'ancestor'
+ case 38108: // 'processing-instruction' 'ancestor'
+ case 38483: // 'attribute' 'ancestor-or-self'
+ case 38522: // 'element' 'ancestor-or-self'
+ case 38587: // 'namespace' 'ancestor-or-self'
+ case 38620: // 'processing-instruction' 'ancestor-or-self'
+ case 40019: // 'attribute' 'append'
+ case 40058: // 'element' 'append'
+ case 40123: // 'namespace' 'append'
+ case 40156: // 'processing-instruction' 'append'
+ case 40531: // 'attribute' 'array'
+ case 40570: // 'element' 'array'
+ case 42579: // 'attribute' 'attribute'
+ case 42618: // 'element' 'attribute'
+ case 42683: // 'namespace' 'attribute'
+ case 42716: // 'processing-instruction' 'attribute'
+ case 43091: // 'attribute' 'base-uri'
+ case 43130: // 'element' 'base-uri'
+ case 43195: // 'namespace' 'base-uri'
+ case 43228: // 'processing-instruction' 'base-uri'
+ case 44115: // 'attribute' 'boundary-space'
+ case 44154: // 'element' 'boundary-space'
+ case 44219: // 'namespace' 'boundary-space'
+ case 44252: // 'processing-instruction' 'boundary-space'
+ case 44627: // 'attribute' 'break'
+ case 44666: // 'element' 'break'
+ case 44731: // 'namespace' 'break'
+ case 44764: // 'processing-instruction' 'break'
+ case 47187: // 'attribute' 'catch'
+ case 47226: // 'element' 'catch'
+ case 47291: // 'namespace' 'catch'
+ case 47324: // 'processing-instruction' 'catch'
+ case 48211: // 'attribute' 'child'
+ case 48250: // 'element' 'child'
+ case 48315: // 'namespace' 'child'
+ case 48348: // 'processing-instruction' 'child'
+ case 49747: // 'attribute' 'comment'
+ case 49786: // 'element' 'comment'
+ case 49851: // 'namespace' 'comment'
+ case 49884: // 'processing-instruction' 'comment'
+ case 50259: // 'attribute' 'constraint'
+ case 50298: // 'element' 'constraint'
+ case 50363: // 'namespace' 'constraint'
+ case 50396: // 'processing-instruction' 'constraint'
+ case 50771: // 'attribute' 'construction'
+ case 50810: // 'element' 'construction'
+ case 50875: // 'namespace' 'construction'
+ case 50908: // 'processing-instruction' 'construction'
+ case 52307: // 'attribute' 'context'
+ case 52346: // 'element' 'context'
+ case 52411: // 'namespace' 'context'
+ case 52444: // 'processing-instruction' 'context'
+ case 52819: // 'attribute' 'continue'
+ case 52858: // 'element' 'continue'
+ case 52923: // 'namespace' 'continue'
+ case 52956: // 'processing-instruction' 'continue'
+ case 53331: // 'attribute' 'copy'
+ case 53370: // 'element' 'copy'
+ case 53435: // 'namespace' 'copy'
+ case 53468: // 'processing-instruction' 'copy'
+ case 53843: // 'attribute' 'copy-namespaces'
+ case 53882: // 'element' 'copy-namespaces'
+ case 53947: // 'namespace' 'copy-namespaces'
+ case 53980: // 'processing-instruction' 'copy-namespaces'
+ case 54867: // 'attribute' 'decimal-format'
+ case 54906: // 'element' 'decimal-format'
+ case 54971: // 'namespace' 'decimal-format'
+ case 55004: // 'processing-instruction' 'decimal-format'
+ case 55891: // 'attribute' 'declare'
+ case 55930: // 'element' 'declare'
+ case 55995: // 'namespace' 'declare'
+ case 56028: // 'processing-instruction' 'declare'
+ case 56915: // 'attribute' 'delete'
+ case 56954: // 'element' 'delete'
+ case 57019: // 'namespace' 'delete'
+ case 57052: // 'processing-instruction' 'delete'
+ case 57427: // 'attribute' 'descendant'
+ case 57466: // 'element' 'descendant'
+ case 57531: // 'namespace' 'descendant'
+ case 57564: // 'processing-instruction' 'descendant'
+ case 57939: // 'attribute' 'descendant-or-self'
+ case 57978: // 'element' 'descendant-or-self'
+ case 58043: // 'namespace' 'descendant-or-self'
+ case 58076: // 'processing-instruction' 'descendant-or-self'
+ case 61523: // 'attribute' 'document'
+ case 61562: // 'element' 'document'
+ case 61627: // 'namespace' 'document'
+ case 61660: // 'processing-instruction' 'document'
+ case 62035: // 'attribute' 'document-node'
+ case 62074: // 'element' 'document-node'
+ case 62139: // 'namespace' 'document-node'
+ case 62172: // 'processing-instruction' 'document-node'
+ case 62547: // 'attribute' 'element'
+ case 62586: // 'element' 'element'
+ case 62651: // 'namespace' 'element'
+ case 62684: // 'processing-instruction' 'element'
+ case 64083: // 'attribute' 'empty-sequence'
+ case 64122: // 'element' 'empty-sequence'
+ case 64187: // 'namespace' 'empty-sequence'
+ case 64220: // 'processing-instruction' 'empty-sequence'
+ case 64595: // 'attribute' 'encoding'
+ case 64634: // 'element' 'encoding'
+ case 64699: // 'namespace' 'encoding'
+ case 64732: // 'processing-instruction' 'encoding'
+ case 66643: // 'attribute' 'every'
+ case 66682: // 'element' 'every'
+ case 66747: // 'namespace' 'every'
+ case 66780: // 'processing-instruction' 'every'
+ case 68179: // 'attribute' 'exit'
+ case 68218: // 'element' 'exit'
+ case 68283: // 'namespace' 'exit'
+ case 68316: // 'processing-instruction' 'exit'
+ case 68691: // 'attribute' 'external'
+ case 68730: // 'element' 'external'
+ case 68795: // 'namespace' 'external'
+ case 68828: // 'processing-instruction' 'external'
+ case 69203: // 'attribute' 'false'
+ case 69242: // 'element' 'false'
+ case 69307: // 'namespace' 'false'
+ case 69340: // 'processing-instruction' 'false'
+ case 69715: // 'attribute' 'first'
+ case 69754: // 'element' 'first'
+ case 69819: // 'namespace' 'first'
+ case 69852: // 'processing-instruction' 'first'
+ case 70227: // 'attribute' 'following'
+ case 70266: // 'element' 'following'
+ case 70331: // 'namespace' 'following'
+ case 70364: // 'processing-instruction' 'following'
+ case 70739: // 'attribute' 'following-sibling'
+ case 70778: // 'element' 'following-sibling'
+ case 70843: // 'namespace' 'following-sibling'
+ case 70876: // 'processing-instruction' 'following-sibling'
+ case 72787: // 'attribute' 'from'
+ case 72826: // 'element' 'from'
+ case 72891: // 'namespace' 'from'
+ case 72924: // 'processing-instruction' 'from'
+ case 73299: // 'attribute' 'ft-option'
+ case 73338: // 'element' 'ft-option'
+ case 73403: // 'namespace' 'ft-option'
+ case 73436: // 'processing-instruction' 'ft-option'
+ case 75347: // 'attribute' 'function'
+ case 75386: // 'element' 'function'
+ case 75451: // 'namespace' 'function'
+ case 75484: // 'processing-instruction' 'function'
+ case 78931: // 'attribute' 'if'
+ case 78970: // 'element' 'if'
+ case 79035: // 'namespace' 'if'
+ case 79068: // 'processing-instruction' 'if'
+ case 79443: // 'attribute' 'import'
+ case 79482: // 'element' 'import'
+ case 79547: // 'namespace' 'import'
+ case 79580: // 'processing-instruction' 'import'
+ case 79955: // 'attribute' 'in'
+ case 79994: // 'element' 'in'
+ case 80059: // 'namespace' 'in'
+ case 80092: // 'processing-instruction' 'in'
+ case 80467: // 'attribute' 'index'
+ case 80506: // 'element' 'index'
+ case 80571: // 'namespace' 'index'
+ case 80604: // 'processing-instruction' 'index'
+ case 82515: // 'attribute' 'insert'
+ case 82554: // 'element' 'insert'
+ case 82619: // 'namespace' 'insert'
+ case 82652: // 'processing-instruction' 'insert'
+ case 83539: // 'attribute' 'integrity'
+ case 83578: // 'element' 'integrity'
+ case 83643: // 'namespace' 'integrity'
+ case 83676: // 'processing-instruction' 'integrity'
+ case 85587: // 'attribute' 'item'
+ case 85626: // 'element' 'item'
+ case 85691: // 'namespace' 'item'
+ case 85724: // 'processing-instruction' 'item'
+ case 86099: // 'attribute' 'json'
+ case 86138: // 'element' 'json'
+ case 86203: // 'namespace' 'json'
+ case 86236: // 'processing-instruction' 'json'
+ case 86611: // 'attribute' 'json-item'
+ case 86650: // 'element' 'json-item'
+ case 87123: // 'attribute' 'jsoniq'
+ case 87162: // 'element' 'jsoniq'
+ case 87227: // 'namespace' 'jsoniq'
+ case 87260: // 'processing-instruction' 'jsoniq'
+ case 88659: // 'attribute' 'last'
+ case 88698: // 'element' 'last'
+ case 88763: // 'namespace' 'last'
+ case 88796: // 'processing-instruction' 'last'
+ case 89171: // 'attribute' 'lax'
+ case 89210: // 'element' 'lax'
+ case 89275: // 'namespace' 'lax'
+ case 89308: // 'processing-instruction' 'lax'
+ case 91731: // 'attribute' 'loop'
+ case 91770: // 'element' 'loop'
+ case 91835: // 'namespace' 'loop'
+ case 91868: // 'processing-instruction' 'loop'
+ case 94803: // 'attribute' 'module'
+ case 94842: // 'element' 'module'
+ case 94907: // 'namespace' 'module'
+ case 94940: // 'processing-instruction' 'module'
+ case 95827: // 'attribute' 'namespace'
+ case 95866: // 'element' 'namespace'
+ case 95931: // 'namespace' 'namespace'
+ case 95964: // 'processing-instruction' 'namespace'
+ case 96339: // 'attribute' 'namespace-node'
+ case 96378: // 'element' 'namespace-node'
+ case 96443: // 'namespace' 'namespace-node'
+ case 96476: // 'processing-instruction' 'namespace-node'
+ case 99411: // 'attribute' 'node'
+ case 99450: // 'element' 'node'
+ case 99515: // 'namespace' 'node'
+ case 99548: // 'processing-instruction' 'node'
+ case 99923: // 'attribute' 'nodes'
+ case 99962: // 'element' 'nodes'
+ case 100027: // 'namespace' 'nodes'
+ case 100060: // 'processing-instruction' 'nodes'
+ case 100947: // 'attribute' 'null'
+ case 100986: // 'element' 'null'
+ case 101051: // 'namespace' 'null'
+ case 101084: // 'processing-instruction' 'null'
+ case 101459: // 'attribute' 'object'
+ case 101498: // 'element' 'object'
+ case 101563: // 'namespace' 'object'
+ case 101596: // 'processing-instruction' 'object'
+ case 104019: // 'attribute' 'option'
+ case 104058: // 'element' 'option'
+ case 104123: // 'namespace' 'option'
+ case 104156: // 'processing-instruction' 'option'
+ case 105555: // 'attribute' 'ordered'
+ case 105594: // 'element' 'ordered'
+ case 105659: // 'namespace' 'ordered'
+ case 105692: // 'processing-instruction' 'ordered'
+ case 106067: // 'attribute' 'ordering'
+ case 106106: // 'element' 'ordering'
+ case 106171: // 'namespace' 'ordering'
+ case 106204: // 'processing-instruction' 'ordering'
+ case 107603: // 'attribute' 'parent'
+ case 107642: // 'element' 'parent'
+ case 107707: // 'namespace' 'parent'
+ case 107740: // 'processing-instruction' 'parent'
+ case 110675: // 'attribute' 'preceding'
+ case 110714: // 'element' 'preceding'
+ case 110779: // 'namespace' 'preceding'
+ case 110812: // 'processing-instruction' 'preceding'
+ case 111187: // 'attribute' 'preceding-sibling'
+ case 111226: // 'element' 'preceding-sibling'
+ case 111291: // 'namespace' 'preceding-sibling'
+ case 111324: // 'processing-instruction' 'preceding-sibling'
+ case 112723: // 'attribute' 'processing-instruction'
+ case 112762: // 'element' 'processing-instruction'
+ case 112827: // 'namespace' 'processing-instruction'
+ case 112860: // 'processing-instruction' 'processing-instruction'
+ case 113747: // 'attribute' 'rename'
+ case 113786: // 'element' 'rename'
+ case 113851: // 'namespace' 'rename'
+ case 113884: // 'processing-instruction' 'rename'
+ case 114259: // 'attribute' 'replace'
+ case 114298: // 'element' 'replace'
+ case 114363: // 'namespace' 'replace'
+ case 114396: // 'processing-instruction' 'replace'
+ case 115283: // 'attribute' 'returning'
+ case 115322: // 'element' 'returning'
+ case 115387: // 'namespace' 'returning'
+ case 115420: // 'processing-instruction' 'returning'
+ case 115795: // 'attribute' 'revalidation'
+ case 115834: // 'element' 'revalidation'
+ case 115899: // 'namespace' 'revalidation'
+ case 115932: // 'processing-instruction' 'revalidation'
+ case 117331: // 'attribute' 'schema'
+ case 117370: // 'element' 'schema'
+ case 117435: // 'namespace' 'schema'
+ case 117468: // 'processing-instruction' 'schema'
+ case 117843: // 'attribute' 'schema-attribute'
+ case 117882: // 'element' 'schema-attribute'
+ case 117947: // 'namespace' 'schema-attribute'
+ case 117980: // 'processing-instruction' 'schema-attribute'
+ case 118355: // 'attribute' 'schema-element'
+ case 118394: // 'element' 'schema-element'
+ case 118459: // 'namespace' 'schema-element'
+ case 118492: // 'processing-instruction' 'schema-element'
+ case 118867: // 'attribute' 'score'
+ case 118906: // 'element' 'score'
+ case 118971: // 'namespace' 'score'
+ case 119004: // 'processing-instruction' 'score'
+ case 119379: // 'attribute' 'select'
+ case 119418: // 'element' 'select'
+ case 119483: // 'namespace' 'select'
+ case 119516: // 'processing-instruction' 'select'
+ case 119891: // 'attribute' 'self'
+ case 119930: // 'element' 'self'
+ case 119995: // 'namespace' 'self'
+ case 120028: // 'processing-instruction' 'self'
+ case 122451: // 'attribute' 'sliding'
+ case 122490: // 'element' 'sliding'
+ case 122555: // 'namespace' 'sliding'
+ case 122588: // 'processing-instruction' 'sliding'
+ case 122963: // 'attribute' 'some'
+ case 123002: // 'element' 'some'
+ case 123067: // 'namespace' 'some'
+ case 123100: // 'processing-instruction' 'some'
+ case 125523: // 'attribute' 'strict'
+ case 125562: // 'element' 'strict'
+ case 125627: // 'namespace' 'strict'
+ case 125660: // 'processing-instruction' 'strict'
+ case 126547: // 'attribute' 'structured-item'
+ case 126586: // 'element' 'structured-item'
+ case 127059: // 'attribute' 'switch'
+ case 127098: // 'element' 'switch'
+ case 127163: // 'namespace' 'switch'
+ case 127196: // 'processing-instruction' 'switch'
+ case 127571: // 'attribute' 'text'
+ case 127610: // 'element' 'text'
+ case 127675: // 'namespace' 'text'
+ case 127708: // 'processing-instruction' 'text'
+ case 130643: // 'attribute' 'true'
+ case 130682: // 'element' 'true'
+ case 130747: // 'namespace' 'true'
+ case 130780: // 'processing-instruction' 'true'
+ case 131155: // 'attribute' 'try'
+ case 131194: // 'element' 'try'
+ case 131259: // 'namespace' 'try'
+ case 131292: // 'processing-instruction' 'try'
+ case 131667: // 'attribute' 'tumbling'
+ case 131706: // 'element' 'tumbling'
+ case 131771: // 'namespace' 'tumbling'
+ case 131804: // 'processing-instruction' 'tumbling'
+ case 132179: // 'attribute' 'type'
+ case 132218: // 'element' 'type'
+ case 132283: // 'namespace' 'type'
+ case 132316: // 'processing-instruction' 'type'
+ case 132691: // 'attribute' 'typeswitch'
+ case 132730: // 'element' 'typeswitch'
+ case 132795: // 'namespace' 'typeswitch'
+ case 132828: // 'processing-instruction' 'typeswitch'
+ case 134227: // 'attribute' 'unordered'
+ case 134266: // 'element' 'unordered'
+ case 134331: // 'namespace' 'unordered'
+ case 134364: // 'processing-instruction' 'unordered'
+ case 134739: // 'attribute' 'updating'
+ case 134778: // 'element' 'updating'
+ case 134843: // 'namespace' 'updating'
+ case 134876: // 'processing-instruction' 'updating'
+ case 136275: // 'attribute' 'validate'
+ case 136314: // 'element' 'validate'
+ case 136379: // 'namespace' 'validate'
+ case 136412: // 'processing-instruction' 'validate'
+ case 136787: // 'attribute' 'value'
+ case 136826: // 'element' 'value'
+ case 136891: // 'namespace' 'value'
+ case 136924: // 'processing-instruction' 'value'
+ case 137299: // 'attribute' 'variable'
+ case 137338: // 'element' 'variable'
+ case 137403: // 'namespace' 'variable'
+ case 137436: // 'processing-instruction' 'variable'
+ case 137811: // 'attribute' 'version'
+ case 137850: // 'element' 'version'
+ case 137915: // 'namespace' 'version'
+ case 137948: // 'processing-instruction' 'version'
+ case 139859: // 'attribute' 'while'
+ case 139898: // 'element' 'while'
+ case 139963: // 'namespace' 'while'
+ case 139996: // 'processing-instruction' 'while'
+ case 143955: // 'attribute' '{'
+ case 143969: // 'comment' '{'
+ case 143992: // 'document' '{'
+ case 143994: // 'element' '{'
+ case 144059: // 'namespace' '{'
+ case 144078: // 'ordered' '{'
+ case 144092: // 'processing-instruction' '{'
+ case 144121: // 'text' '{'
+ case 144134: // 'unordered' '{'
+ try_PostfixExpr();
+ break;
+ case -3:
+ break;
+ default:
+ try_AxisStep();
+ }
+ }
+
+ function parse_AxisStep()
+ {
+ eventHandler.startNonterminal("AxisStep", e0);
+ switch (l1)
+ {
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ lookahead2W(231); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 46: // '..'
+ case 26698: // 'ancestor' '::'
+ case 26699: // 'ancestor-or-self' '::'
+ case 26834: // 'parent' '::'
+ case 26840: // 'preceding' '::'
+ case 26841: // 'preceding-sibling' '::'
+ parse_ReverseStep();
+ break;
+ default:
+ parse_ForwardStep();
+ }
+ lookahead1W(227); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ whitespace();
+ parse_PredicateList();
+ eventHandler.endNonterminal("AxisStep", e0);
+ }
+
+ function try_AxisStep()
+ {
+ switch (l1)
+ {
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ lookahead2W(231); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 46: // '..'
+ case 26698: // 'ancestor' '::'
+ case 26699: // 'ancestor-or-self' '::'
+ case 26834: // 'parent' '::'
+ case 26840: // 'preceding' '::'
+ case 26841: // 'preceding-sibling' '::'
+ try_ReverseStep();
+ break;
+ default:
+ try_ForwardStep();
+ }
+ lookahead1W(227); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ try_PredicateList();
+ }
+
+ function parse_ForwardStep()
+ {
+ eventHandler.startNonterminal("ForwardStep", e0);
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ lookahead2W(235); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 94: // 'child'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 234: // 'self'
+ lookahead2W(231); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 26707: // 'attribute' '::'
+ case 26718: // 'child' '::'
+ case 26736: // 'descendant' '::'
+ case 26737: // 'descendant-or-self' '::'
+ case 26761: // 'following' '::'
+ case 26762: // 'following-sibling' '::'
+ case 26858: // 'self' '::'
+ parse_ForwardAxis();
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NodeTest();
+ break;
+ default:
+ parse_AbbrevForwardStep();
+ }
+ eventHandler.endNonterminal("ForwardStep", e0);
+ }
+
+ function try_ForwardStep()
+ {
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ lookahead2W(235); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 94: // 'child'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 234: // 'self'
+ lookahead2W(231); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 26707: // 'attribute' '::'
+ case 26718: // 'child' '::'
+ case 26736: // 'descendant' '::'
+ case 26737: // 'descendant-or-self' '::'
+ case 26761: // 'following' '::'
+ case 26762: // 'following-sibling' '::'
+ case 26858: // 'self' '::'
+ try_ForwardAxis();
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NodeTest();
+ break;
+ default:
+ try_AbbrevForwardStep();
+ }
+ }
+
+ function parse_ForwardAxis()
+ {
+ eventHandler.startNonterminal("ForwardAxis", e0);
+ switch (l1)
+ {
+ case 94: // 'child'
+ shift(94); // 'child'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 112: // 'descendant'
+ shift(112); // 'descendant'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 83: // 'attribute'
+ shift(83); // 'attribute'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 234: // 'self'
+ shift(234); // 'self'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 113: // 'descendant-or-self'
+ shift(113); // 'descendant-or-self'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 138: // 'following-sibling'
+ shift(138); // 'following-sibling'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ default:
+ shift(137); // 'following'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ }
+ eventHandler.endNonterminal("ForwardAxis", e0);
+ }
+
+ function try_ForwardAxis()
+ {
+ switch (l1)
+ {
+ case 94: // 'child'
+ shiftT(94); // 'child'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 112: // 'descendant'
+ shiftT(112); // 'descendant'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 83: // 'attribute'
+ shiftT(83); // 'attribute'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 234: // 'self'
+ shiftT(234); // 'self'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 113: // 'descendant-or-self'
+ shiftT(113); // 'descendant-or-self'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 138: // 'following-sibling'
+ shiftT(138); // 'following-sibling'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ default:
+ shiftT(137); // 'following'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ }
+ }
+
+ function parse_AbbrevForwardStep()
+ {
+ eventHandler.startNonterminal("AbbrevForwardStep", e0);
+ if (l1 == 67) // '@'
+ {
+ shift(67); // '@'
+ }
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NodeTest();
+ eventHandler.endNonterminal("AbbrevForwardStep", e0);
+ }
+
+ function try_AbbrevForwardStep()
+ {
+ if (l1 == 67) // '@'
+ {
+ shiftT(67); // '@'
+ }
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NodeTest();
+ }
+
+ function parse_ReverseStep()
+ {
+ eventHandler.startNonterminal("ReverseStep", e0);
+ switch (l1)
+ {
+ case 46: // '..'
+ parse_AbbrevReverseStep();
+ break;
+ default:
+ parse_ReverseAxis();
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NodeTest();
+ }
+ eventHandler.endNonterminal("ReverseStep", e0);
+ }
+
+ function try_ReverseStep()
+ {
+ switch (l1)
+ {
+ case 46: // '..'
+ try_AbbrevReverseStep();
+ break;
+ default:
+ try_ReverseAxis();
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NodeTest();
+ }
+ }
+
+ function parse_ReverseAxis()
+ {
+ eventHandler.startNonterminal("ReverseAxis", e0);
+ switch (l1)
+ {
+ case 210: // 'parent'
+ shift(210); // 'parent'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 74: // 'ancestor'
+ shift(74); // 'ancestor'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 217: // 'preceding-sibling'
+ shift(217); // 'preceding-sibling'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ case 216: // 'preceding'
+ shift(216); // 'preceding'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ break;
+ default:
+ shift(75); // 'ancestor-or-self'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shift(52); // '::'
+ }
+ eventHandler.endNonterminal("ReverseAxis", e0);
+ }
+
+ function try_ReverseAxis()
+ {
+ switch (l1)
+ {
+ case 210: // 'parent'
+ shiftT(210); // 'parent'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 74: // 'ancestor'
+ shiftT(74); // 'ancestor'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 217: // 'preceding-sibling'
+ shiftT(217); // 'preceding-sibling'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ case 216: // 'preceding'
+ shiftT(216); // 'preceding'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ break;
+ default:
+ shiftT(75); // 'ancestor-or-self'
+ lookahead1W(27); // S^WS | '(:' | '::'
+ shiftT(52); // '::'
+ }
+ }
+
+ function parse_AbbrevReverseStep()
+ {
+ eventHandler.startNonterminal("AbbrevReverseStep", e0);
+ shift(46); // '..'
+ eventHandler.endNonterminal("AbbrevReverseStep", e0);
+ }
+
+ function try_AbbrevReverseStep()
+ {
+ shiftT(46); // '..'
+ }
+
+ function parse_NodeTest()
+ {
+ eventHandler.startNonterminal("NodeTest", e0);
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ case 97: // 'comment'
+ case 121: // 'document-node'
+ case 122: // 'element'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 220: // 'processing-instruction'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 249: // 'text'
+ lookahead2W(230); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 18003: // 'attribute' '('
+ case 18017: // 'comment' '('
+ case 18041: // 'document-node' '('
+ case 18042: // 'element' '('
+ case 18108: // 'namespace-node' '('
+ case 18114: // 'node' '('
+ case 18140: // 'processing-instruction' '('
+ case 18150: // 'schema-attribute' '('
+ case 18151: // 'schema-element' '('
+ case 18169: // 'text' '('
+ parse_KindTest();
+ break;
+ default:
+ parse_NameTest();
+ }
+ eventHandler.endNonterminal("NodeTest", e0);
+ }
+
+ function try_NodeTest()
+ {
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ case 97: // 'comment'
+ case 121: // 'document-node'
+ case 122: // 'element'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 220: // 'processing-instruction'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 249: // 'text'
+ lookahead2W(230); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 18003: // 'attribute' '('
+ case 18017: // 'comment' '('
+ case 18041: // 'document-node' '('
+ case 18042: // 'element' '('
+ case 18108: // 'namespace-node' '('
+ case 18114: // 'node' '('
+ case 18140: // 'processing-instruction' '('
+ case 18150: // 'schema-attribute' '('
+ case 18151: // 'schema-element' '('
+ case 18169: // 'text' '('
+ try_KindTest();
+ break;
+ default:
+ try_NameTest();
+ }
+ }
+
+ function parse_NameTest()
+ {
+ eventHandler.startNonterminal("NameTest", e0);
+ switch (l1)
+ {
+ case 5: // Wildcard
+ shift(5); // Wildcard
+ break;
+ default:
+ parse_EQName();
+ }
+ eventHandler.endNonterminal("NameTest", e0);
+ }
+
+ function try_NameTest()
+ {
+ switch (l1)
+ {
+ case 5: // Wildcard
+ shiftT(5); // Wildcard
+ break;
+ default:
+ try_EQName();
+ }
+ }
+
+ function parse_PostfixExpr()
+ {
+ eventHandler.startNonterminal("PostfixExpr", e0);
+ parse_PrimaryExpr();
+ for (;;)
+ {
+ lookahead1W(234); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '.' | '/' |
+ if (l1 != 35 // '('
+ && l1 != 45 // '.'
+ && l1 != 69) // '['
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 69: // '['
+ lookahead2W(272); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 35397) // '[' '['
+ {
+ lk = memoized(5, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Predicate();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -4;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(5, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 35: // '('
+ whitespace();
+ parse_ArgumentList();
+ break;
+ case 45: // '.'
+ whitespace();
+ parse_ObjectLookup();
+ break;
+ case -4:
+ whitespace();
+ parse_ArrayLookup();
+ break;
+ case 35909: // '[' ']'
+ whitespace();
+ parse_ArrayUnboxing();
+ break;
+ default:
+ whitespace();
+ parse_Predicate();
+ }
+ }
+ eventHandler.endNonterminal("PostfixExpr", e0);
+ }
+
+ function try_PostfixExpr()
+ {
+ try_PrimaryExpr();
+ for (;;)
+ {
+ lookahead1W(234); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '.' | '/' |
+ if (l1 != 35 // '('
+ && l1 != 45 // '.'
+ && l1 != 69) // '['
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 69: // '['
+ lookahead2W(272); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 35397) // '[' '['
+ {
+ lk = memoized(5, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Predicate();
+ memoize(5, e0A, -1);
+ lk = -6;
+ }
+ catch (p1A)
+ {
+ lk = -4;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(5, e0A, -4);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case 35: // '('
+ try_ArgumentList();
+ break;
+ case 45: // '.'
+ try_ObjectLookup();
+ break;
+ case -4:
+ try_ArrayLookup();
+ break;
+ case 35909: // '[' ']'
+ try_ArrayUnboxing();
+ break;
+ case -6:
+ break;
+ default:
+ try_Predicate();
+ }
+ }
+ }
+
+ function parse_ObjectLookup()
+ {
+ eventHandler.startNonterminal("ObjectLookup", e0);
+ shift(45); // '.'
+ lookahead1W(250); // StringLiteral | NCName^Token | S^WS | '$' | '$$' | '(' | '(:' | 'after' |
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ case 35: // '('
+ whitespace();
+ parse_ParenthesizedExpr();
+ break;
+ case 31: // '$'
+ whitespace();
+ parse_VarRef();
+ break;
+ case 32: // '$$'
+ whitespace();
+ parse_ContextItemExpr();
+ break;
+ default:
+ whitespace();
+ parse_NCName();
+ }
+ eventHandler.endNonterminal("ObjectLookup", e0);
+ }
+
+ function try_ObjectLookup()
+ {
+ shiftT(45); // '.'
+ lookahead1W(250); // StringLiteral | NCName^Token | S^WS | '$' | '$$' | '(' | '(:' | 'after' |
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ case 35: // '('
+ try_ParenthesizedExpr();
+ break;
+ case 31: // '$'
+ try_VarRef();
+ break;
+ case 32: // '$$'
+ try_ContextItemExpr();
+ break;
+ default:
+ try_NCName();
+ }
+ }
+
+ function parse_ArrayLookup()
+ {
+ eventHandler.startNonterminal("ArrayLookup", e0);
+ shift(69); // '['
+ lookahead1W(31); // S^WS | '(:' | '['
+ shift(69); // '['
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(70); // ']'
+ lookahead1W(32); // S^WS | '(:' | ']'
+ shift(70); // ']'
+ eventHandler.endNonterminal("ArrayLookup", e0);
+ }
+
+ function try_ArrayLookup()
+ {
+ shiftT(69); // '['
+ lookahead1W(31); // S^WS | '(:' | '['
+ shiftT(69); // '['
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(70); // ']'
+ lookahead1W(32); // S^WS | '(:' | ']'
+ shiftT(70); // ']'
+ }
+
+ function parse_ArrayUnboxing()
+ {
+ eventHandler.startNonterminal("ArrayUnboxing", e0);
+ shift(69); // '['
+ lookahead1W(32); // S^WS | '(:' | ']'
+ shift(70); // ']'
+ eventHandler.endNonterminal("ArrayUnboxing", e0);
+ }
+
+ function try_ArrayUnboxing()
+ {
+ shiftT(69); // '['
+ lookahead1W(32); // S^WS | '(:' | ']'
+ shiftT(70); // ']'
+ }
+
+ function parse_ArgumentList()
+ {
+ eventHandler.startNonterminal("ArgumentList", e0);
+ shift(35); // '('
+ lookahead1W(279); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 38) // ')'
+ {
+ whitespace();
+ parse_Argument();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(271); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Argument();
+ }
+ }
+ shift(38); // ')'
+ eventHandler.endNonterminal("ArgumentList", e0);
+ }
+
+ function try_ArgumentList()
+ {
+ shiftT(35); // '('
+ lookahead1W(279); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 38) // ')'
+ {
+ try_Argument();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(271); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Argument();
+ }
+ }
+ shiftT(38); // ')'
+ }
+
+ function parse_PredicateList()
+ {
+ eventHandler.startNonterminal("PredicateList", e0);
+ for (;;)
+ {
+ lookahead1W(227); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ if (l1 != 69) // '['
+ {
+ break;
+ }
+ whitespace();
+ parse_Predicate();
+ }
+ eventHandler.endNonterminal("PredicateList", e0);
+ }
+
+ function try_PredicateList()
+ {
+ for (;;)
+ {
+ lookahead1W(227); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ if (l1 != 69) // '['
+ {
+ break;
+ }
+ try_Predicate();
+ }
+ }
+
+ function parse_Predicate()
+ {
+ eventHandler.startNonterminal("Predicate", e0);
+ shift(69); // '['
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(70); // ']'
+ eventHandler.endNonterminal("Predicate", e0);
+ }
+
+ function try_Predicate()
+ {
+ shiftT(69); // '['
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(70); // ']'
+ }
+
+ function parse_Literal()
+ {
+ eventHandler.startNonterminal("Literal", e0);
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ case 135: // 'false'
+ case 255: // 'true'
+ parse_BooleanLiteral();
+ break;
+ case 197: // 'null'
+ parse_NullLiteral();
+ break;
+ default:
+ parse_NumericLiteral();
+ }
+ eventHandler.endNonterminal("Literal", e0);
+ }
+
+ function try_Literal()
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ case 135: // 'false'
+ case 255: // 'true'
+ try_BooleanLiteral();
+ break;
+ case 197: // 'null'
+ try_NullLiteral();
+ break;
+ default:
+ try_NumericLiteral();
+ }
+ }
+
+ function parse_BooleanLiteral()
+ {
+ eventHandler.startNonterminal("BooleanLiteral", e0);
+ switch (l1)
+ {
+ case 255: // 'true'
+ shift(255); // 'true'
+ break;
+ default:
+ shift(135); // 'false'
+ }
+ eventHandler.endNonterminal("BooleanLiteral", e0);
+ }
+
+ function try_BooleanLiteral()
+ {
+ switch (l1)
+ {
+ case 255: // 'true'
+ shiftT(255); // 'true'
+ break;
+ default:
+ shiftT(135); // 'false'
+ }
+ }
+
+ function parse_NullLiteral()
+ {
+ eventHandler.startNonterminal("NullLiteral", e0);
+ shift(197); // 'null'
+ eventHandler.endNonterminal("NullLiteral", e0);
+ }
+
+ function try_NullLiteral()
+ {
+ shiftT(197); // 'null'
+ }
+
+ function parse_NumericLiteral()
+ {
+ eventHandler.startNonterminal("NumericLiteral", e0);
+ switch (l1)
+ {
+ case 8: // IntegerLiteral
+ shift(8); // IntegerLiteral
+ break;
+ case 9: // DecimalLiteral
+ shift(9); // DecimalLiteral
+ break;
+ default:
+ shift(10); // DoubleLiteral
+ }
+ eventHandler.endNonterminal("NumericLiteral", e0);
+ }
+
+ function try_NumericLiteral()
+ {
+ switch (l1)
+ {
+ case 8: // IntegerLiteral
+ shiftT(8); // IntegerLiteral
+ break;
+ case 9: // DecimalLiteral
+ shiftT(9); // DecimalLiteral
+ break;
+ default:
+ shiftT(10); // DoubleLiteral
+ }
+ }
+
+ function parse_VarRef()
+ {
+ eventHandler.startNonterminal("VarRef", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("VarRef", e0);
+ }
+
+ function try_VarRef()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_VarName()
+ {
+ eventHandler.startNonterminal("VarName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("VarName", e0);
+ }
+
+ function try_VarName()
+ {
+ try_EQName();
+ }
+
+ function parse_ParenthesizedExpr()
+ {
+ eventHandler.startNonterminal("ParenthesizedExpr", e0);
+ shift(35); // '('
+ lookahead1W(269); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 38) // ')'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(38); // ')'
+ eventHandler.endNonterminal("ParenthesizedExpr", e0);
+ }
+
+ function try_ParenthesizedExpr()
+ {
+ shiftT(35); // '('
+ lookahead1W(269); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 38) // ')'
+ {
+ try_Expr();
+ }
+ shiftT(38); // ')'
+ }
+
+ function parse_ContextItemExpr()
+ {
+ eventHandler.startNonterminal("ContextItemExpr", e0);
+ shift(32); // '$$'
+ eventHandler.endNonterminal("ContextItemExpr", e0);
+ }
+
+ function try_ContextItemExpr()
+ {
+ shiftT(32); // '$$'
+ }
+
+ function parse_OrderedExpr()
+ {
+ eventHandler.startNonterminal("OrderedExpr", e0);
+ shift(206); // 'ordered'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("OrderedExpr", e0);
+ }
+
+ function try_OrderedExpr()
+ {
+ shiftT(206); // 'ordered'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+
+ function parse_UnorderedExpr()
+ {
+ eventHandler.startNonterminal("UnorderedExpr", e0);
+ shift(262); // 'unordered'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("UnorderedExpr", e0);
+ }
+
+ function try_UnorderedExpr()
+ {
+ shiftT(262); // 'unordered'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+
+ function parse_FunctionCall()
+ {
+ eventHandler.startNonterminal("FunctionCall", e0);
+ parse_FunctionName();
+ lookahead1W(22); // S^WS | '(' | '(:'
+ whitespace();
+ parse_ArgumentList();
+ eventHandler.endNonterminal("FunctionCall", e0);
+ }
+
+ function try_FunctionCall()
+ {
+ try_FunctionName();
+ lookahead1W(22); // S^WS | '(' | '(:'
+ try_ArgumentList();
+ }
+
+ function parse_Argument()
+ {
+ eventHandler.startNonterminal("Argument", e0);
+ switch (l1)
+ {
+ case 65: // '?'
+ parse_ArgumentPlaceholder();
+ break;
+ default:
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("Argument", e0);
+ }
+
+ function try_Argument()
+ {
+ switch (l1)
+ {
+ case 65: // '?'
+ try_ArgumentPlaceholder();
+ break;
+ default:
+ try_ExprSingle();
+ }
+ }
+
+ function parse_ArgumentPlaceholder()
+ {
+ eventHandler.startNonterminal("ArgumentPlaceholder", e0);
+ shift(65); // '?'
+ eventHandler.endNonterminal("ArgumentPlaceholder", e0);
+ }
+
+ function try_ArgumentPlaceholder()
+ {
+ shiftT(65); // '?'
+ }
+
+ function parse_Constructor()
+ {
+ eventHandler.startNonterminal("Constructor", e0);
+ switch (l1)
+ {
+ case 55: // '<'
+ case 56: // '<!--'
+ case 60: // '<?'
+ parse_DirectConstructor();
+ break;
+ default:
+ parse_ComputedConstructor();
+ }
+ eventHandler.endNonterminal("Constructor", e0);
+ }
+
+ function try_Constructor()
+ {
+ switch (l1)
+ {
+ case 55: // '<'
+ case 56: // '<!--'
+ case 60: // '<?'
+ try_DirectConstructor();
+ break;
+ default:
+ try_ComputedConstructor();
+ }
+ }
+
+ function parse_DirectConstructor()
+ {
+ eventHandler.startNonterminal("DirectConstructor", e0);
+ switch (l1)
+ {
+ case 55: // '<'
+ parse_DirElemConstructor();
+ break;
+ case 56: // '<!--'
+ parse_DirCommentConstructor();
+ break;
+ default:
+ parse_DirPIConstructor();
+ }
+ eventHandler.endNonterminal("DirectConstructor", e0);
+ }
+
+ function try_DirectConstructor()
+ {
+ switch (l1)
+ {
+ case 55: // '<'
+ try_DirElemConstructor();
+ break;
+ case 56: // '<!--'
+ try_DirCommentConstructor();
+ break;
+ default:
+ try_DirPIConstructor();
+ }
+ }
+
+ function parse_DirElemConstructor()
+ {
+ eventHandler.startNonterminal("DirElemConstructor", e0);
+ shift(55); // '<'
+ lookahead1(4); // QName
+ shift(20); // QName
+ parse_DirAttributeList();
+ switch (l1)
+ {
+ case 49: // '/>'
+ shift(49); // '/>'
+ break;
+ default:
+ shift(62); // '>'
+ for (;;)
+ {
+ lookahead1(196); // CDataSection | PredefinedEntityRef | ElementContentChar | CharRef | '<' |
+ if (l1 == 57) // '</'
+ {
+ break;
+ }
+ parse_DirElemContent();
+ }
+ shift(57); // '</'
+ lookahead1(4); // QName
+ shift(20); // QName
+ lookahead1(12); // S | '>'
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ lookahead1(8); // '>'
+ shift(62); // '>'
+ }
+ eventHandler.endNonterminal("DirElemConstructor", e0);
+ }
+
+ function try_DirElemConstructor()
+ {
+ shiftT(55); // '<'
+ lookahead1(4); // QName
+ shiftT(20); // QName
+ try_DirAttributeList();
+ switch (l1)
+ {
+ case 49: // '/>'
+ shiftT(49); // '/>'
+ break;
+ default:
+ shiftT(62); // '>'
+ for (;;)
+ {
+ lookahead1(196); // CDataSection | PredefinedEntityRef | ElementContentChar | CharRef | '<' |
+ if (l1 == 57) // '</'
+ {
+ break;
+ }
+ try_DirElemContent();
+ }
+ shiftT(57); // '</'
+ lookahead1(4); // QName
+ shiftT(20); // QName
+ lookahead1(12); // S | '>'
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ lookahead1(8); // '>'
+ shiftT(62); // '>'
+ }
+ }
+
+ function parse_DirAttributeList()
+ {
+ eventHandler.startNonterminal("DirAttributeList", e0);
+ for (;;)
+ {
+ lookahead1(19); // S | '/>' | '>'
+ if (l1 != 21) // S
+ {
+ break;
+ }
+ shift(21); // S
+ lookahead1(94); // QName | S | '/>' | '>'
+ if (l1 == 20) // QName
+ {
+ shift(20); // QName
+ lookahead1(11); // S | '='
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ lookahead1(7); // '='
+ shift(61); // '='
+ lookahead1(18); // S | '"' | "'"
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ parse_DirAttributeValue();
+ }
+ }
+ eventHandler.endNonterminal("DirAttributeList", e0);
+ }
+
+ function try_DirAttributeList()
+ {
+ for (;;)
+ {
+ lookahead1(19); // S | '/>' | '>'
+ if (l1 != 21) // S
+ {
+ break;
+ }
+ shiftT(21); // S
+ lookahead1(94); // QName | S | '/>' | '>'
+ if (l1 == 20) // QName
+ {
+ shiftT(20); // QName
+ lookahead1(11); // S | '='
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ lookahead1(7); // '='
+ shiftT(61); // '='
+ lookahead1(18); // S | '"' | "'"
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ try_DirAttributeValue();
+ }
+ }
+ }
+
+ function parse_DirAttributeValue()
+ {
+ eventHandler.startNonterminal("DirAttributeValue", e0);
+ lookahead1(14); // '"' | "'"
+ switch (l1)
+ {
+ case 28: // '"'
+ shift(28); // '"'
+ for (;;)
+ {
+ lookahead1(185); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | '"' | '{' |
+ if (l1 == 28) // '"'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 13: // EscapeQuot
+ shift(13); // EscapeQuot
+ break;
+ default:
+ parse_QuotAttrValueContent();
+ }
+ }
+ shift(28); // '"'
+ break;
+ default:
+ shift(34); // "'"
+ for (;;)
+ {
+ lookahead1(186); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | "'" | '{' |
+ if (l1 == 34) // "'"
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 14: // EscapeApos
+ shift(14); // EscapeApos
+ break;
+ default:
+ parse_AposAttrValueContent();
+ }
+ }
+ shift(34); // "'"
+ }
+ eventHandler.endNonterminal("DirAttributeValue", e0);
+ }
+
+ function try_DirAttributeValue()
+ {
+ lookahead1(14); // '"' | "'"
+ switch (l1)
+ {
+ case 28: // '"'
+ shiftT(28); // '"'
+ for (;;)
+ {
+ lookahead1(185); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | '"' | '{' |
+ if (l1 == 28) // '"'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 13: // EscapeQuot
+ shiftT(13); // EscapeQuot
+ break;
+ default:
+ try_QuotAttrValueContent();
+ }
+ }
+ shiftT(28); // '"'
+ break;
+ default:
+ shiftT(34); // "'"
+ for (;;)
+ {
+ lookahead1(186); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | "'" | '{' |
+ if (l1 == 34) // "'"
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 14: // EscapeApos
+ shiftT(14); // EscapeApos
+ break;
+ default:
+ try_AposAttrValueContent();
+ }
+ }
+ shiftT(34); // "'"
+ }
+ }
+
+ function parse_QuotAttrValueContent()
+ {
+ eventHandler.startNonterminal("QuotAttrValueContent", e0);
+ switch (l1)
+ {
+ case 16: // QuotAttrContentChar
+ shift(16); // QuotAttrContentChar
+ break;
+ default:
+ parse_CommonContent();
+ }
+ eventHandler.endNonterminal("QuotAttrValueContent", e0);
+ }
+
+ function try_QuotAttrValueContent()
+ {
+ switch (l1)
+ {
+ case 16: // QuotAttrContentChar
+ shiftT(16); // QuotAttrContentChar
+ break;
+ default:
+ try_CommonContent();
+ }
+ }
+
+ function parse_AposAttrValueContent()
+ {
+ eventHandler.startNonterminal("AposAttrValueContent", e0);
+ switch (l1)
+ {
+ case 17: // AposAttrContentChar
+ shift(17); // AposAttrContentChar
+ break;
+ default:
+ parse_CommonContent();
+ }
+ eventHandler.endNonterminal("AposAttrValueContent", e0);
+ }
+
+ function try_AposAttrValueContent()
+ {
+ switch (l1)
+ {
+ case 17: // AposAttrContentChar
+ shiftT(17); // AposAttrContentChar
+ break;
+ default:
+ try_CommonContent();
+ }
+ }
+
+ function parse_DirElemContent()
+ {
+ eventHandler.startNonterminal("DirElemContent", e0);
+ switch (l1)
+ {
+ case 55: // '<'
+ case 56: // '<!--'
+ case 60: // '<?'
+ parse_DirectConstructor();
+ break;
+ case 4: // CDataSection
+ shift(4); // CDataSection
+ break;
+ case 15: // ElementContentChar
+ shift(15); // ElementContentChar
+ break;
+ default:
+ parse_CommonContent();
+ }
+ eventHandler.endNonterminal("DirElemContent", e0);
+ }
+
+ function try_DirElemContent()
+ {
+ switch (l1)
+ {
+ case 55: // '<'
+ case 56: // '<!--'
+ case 60: // '<?'
+ try_DirectConstructor();
+ break;
+ case 4: // CDataSection
+ shiftT(4); // CDataSection
+ break;
+ case 15: // ElementContentChar
+ shiftT(15); // ElementContentChar
+ break;
+ default:
+ try_CommonContent();
+ }
+ }
+
+ function parse_DirCommentConstructor()
+ {
+ eventHandler.startNonterminal("DirCommentConstructor", e0);
+ shift(56); // '<!--'
+ lookahead1(1); // DirCommentContents
+ shift(2); // DirCommentContents
+ lookahead1(6); // '-->'
+ shift(44); // '-->'
+ eventHandler.endNonterminal("DirCommentConstructor", e0);
+ }
+
+ function try_DirCommentConstructor()
+ {
+ shiftT(56); // '<!--'
+ lookahead1(1); // DirCommentContents
+ shiftT(2); // DirCommentContents
+ lookahead1(6); // '-->'
+ shiftT(44); // '-->'
+ }
+
+ function parse_DirPIConstructor()
+ {
+ eventHandler.startNonterminal("DirPIConstructor", e0);
+ shift(60); // '<?'
+ lookahead1(3); // PITarget
+ shift(18); // PITarget
+ lookahead1(13); // S | '?>'
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ lookahead1(2); // DirPIContents
+ shift(3); // DirPIContents
+ }
+ lookahead1(9); // '?>'
+ shift(66); // '?>'
+ eventHandler.endNonterminal("DirPIConstructor", e0);
+ }
+
+ function try_DirPIConstructor()
+ {
+ shiftT(60); // '<?'
+ lookahead1(3); // PITarget
+ shiftT(18); // PITarget
+ lookahead1(13); // S | '?>'
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ lookahead1(2); // DirPIContents
+ shiftT(3); // DirPIContents
+ }
+ lookahead1(9); // '?>'
+ shiftT(66); // '?>'
+ }
+
+ function parse_ComputedConstructor()
+ {
+ eventHandler.startNonterminal("ComputedConstructor", e0);
+ switch (l1)
+ {
+ case 120: // 'document'
+ parse_CompDocConstructor();
+ break;
+ case 122: // 'element'
+ parse_CompElemConstructor();
+ break;
+ case 83: // 'attribute'
+ parse_CompAttrConstructor();
+ break;
+ case 187: // 'namespace'
+ parse_CompNamespaceConstructor();
+ break;
+ case 249: // 'text'
+ parse_CompTextConstructor();
+ break;
+ case 97: // 'comment'
+ parse_CompCommentConstructor();
+ break;
+ default:
+ parse_CompPIConstructor();
+ }
+ eventHandler.endNonterminal("ComputedConstructor", e0);
+ }
+
+ function try_ComputedConstructor()
+ {
+ switch (l1)
+ {
+ case 120: // 'document'
+ try_CompDocConstructor();
+ break;
+ case 122: // 'element'
+ try_CompElemConstructor();
+ break;
+ case 83: // 'attribute'
+ try_CompAttrConstructor();
+ break;
+ case 187: // 'namespace'
+ try_CompNamespaceConstructor();
+ break;
+ case 249: // 'text'
+ try_CompTextConstructor();
+ break;
+ case 97: // 'comment'
+ try_CompCommentConstructor();
+ break;
+ default:
+ try_CompPIConstructor();
+ }
+ }
+
+ function parse_CompElemConstructor()
+ {
+ eventHandler.startNonterminal("CompElemConstructor", e0);
+ shift(122); // 'element'
+ lookahead1W(249); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ break;
+ default:
+ whitespace();
+ parse_EQName();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 287) // '}'
+ {
+ whitespace();
+ parse_ContentExpr();
+ }
+ shift(287); // '}'
+ eventHandler.endNonterminal("CompElemConstructor", e0);
+ }
+
+ function try_CompElemConstructor()
+ {
+ shiftT(122); // 'element'
+ lookahead1W(249); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ break;
+ default:
+ try_EQName();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 287) // '}'
+ {
+ try_ContentExpr();
+ }
+ shiftT(287); // '}'
+ }
+
+ function parse_CompNamespaceConstructor()
+ {
+ eventHandler.startNonterminal("CompNamespaceConstructor", e0);
+ shift(187); // 'namespace'
+ lookahead1W(241); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PrefixExpr();
+ shift(287); // '}'
+ break;
+ default:
+ whitespace();
+ parse_Prefix();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_URIExpr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("CompNamespaceConstructor", e0);
+ }
+
+ function try_CompNamespaceConstructor()
+ {
+ shiftT(187); // 'namespace'
+ lookahead1W(241); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PrefixExpr();
+ shiftT(287); // '}'
+ break;
+ default:
+ try_Prefix();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_URIExpr();
+ shiftT(287); // '}'
+ }
+
+ function parse_Prefix()
+ {
+ eventHandler.startNonterminal("Prefix", e0);
+ parse_NCName();
+ eventHandler.endNonterminal("Prefix", e0);
+ }
+
+ function try_Prefix()
+ {
+ try_NCName();
+ }
+
+ function parse_PrefixExpr()
+ {
+ eventHandler.startNonterminal("PrefixExpr", e0);
+ parse_Expr();
+ eventHandler.endNonterminal("PrefixExpr", e0);
+ }
+
+ function try_PrefixExpr()
+ {
+ try_Expr();
+ }
+
+ function parse_URIExpr()
+ {
+ eventHandler.startNonterminal("URIExpr", e0);
+ parse_Expr();
+ eventHandler.endNonterminal("URIExpr", e0);
+ }
+
+ function try_URIExpr()
+ {
+ try_Expr();
+ }
+
+ function parse_FunctionItemExpr()
+ {
+ eventHandler.startNonterminal("FunctionItemExpr", e0);
+ switch (l1)
+ {
+ case 147: // 'function'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 33: // '%'
+ case 18067: // 'function' '('
+ parse_InlineFunctionExpr();
+ break;
+ default:
+ parse_NamedFunctionRef();
+ }
+ eventHandler.endNonterminal("FunctionItemExpr", e0);
+ }
+
+ function try_FunctionItemExpr()
+ {
+ switch (l1)
+ {
+ case 147: // 'function'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 33: // '%'
+ case 18067: // 'function' '('
+ try_InlineFunctionExpr();
+ break;
+ default:
+ try_NamedFunctionRef();
+ }
+ }
+
+ function parse_NamedFunctionRef()
+ {
+ eventHandler.startNonterminal("NamedFunctionRef", e0);
+ parse_EQName();
+ lookahead1W(20); // S^WS | '#' | '(:'
+ shift(29); // '#'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ eventHandler.endNonterminal("NamedFunctionRef", e0);
+ }
+
+ function try_NamedFunctionRef()
+ {
+ try_EQName();
+ lookahead1W(20); // S^WS | '#' | '(:'
+ shiftT(29); // '#'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ }
+
+ function parse_InlineFunctionExpr()
+ {
+ eventHandler.startNonterminal("InlineFunctionExpr", e0);
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 33) // '%'
+ {
+ break;
+ }
+ whitespace();
+ parse_Annotation();
+ }
+ shift(147); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(98); // S^WS | '$' | '(:' | ')'
+ if (l1 == 31) // '$'
+ {
+ whitespace();
+ parse_ParamList();
+ }
+ shift(38); // ')'
+ lookahead1W(115); // S^WS | '(:' | 'as' | '{'
+ if (l1 == 80) // 'as'
+ {
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ whitespace();
+ parse_FunctionBody();
+ eventHandler.endNonterminal("InlineFunctionExpr", e0);
+ }
+
+ function try_InlineFunctionExpr()
+ {
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 33) // '%'
+ {
+ break;
+ }
+ try_Annotation();
+ }
+ shiftT(147); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(98); // S^WS | '$' | '(:' | ')'
+ if (l1 == 31) // '$'
+ {
+ try_ParamList();
+ }
+ shiftT(38); // ')'
+ lookahead1W(115); // S^WS | '(:' | 'as' | '{'
+ if (l1 == 80) // 'as'
+ {
+ shiftT(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ try_FunctionBody();
+ }
+
+ function parse_SingleType()
+ {
+ eventHandler.startNonterminal("SingleType", e0);
+ parse_SimpleTypeName();
+ lookahead1W(225); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 65) // '?'
+ {
+ shift(65); // '?'
+ }
+ eventHandler.endNonterminal("SingleType", e0);
+ }
+
+ function try_SingleType()
+ {
+ try_SimpleTypeName();
+ lookahead1W(225); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 65) // '?'
+ {
+ shiftT(65); // '?'
+ }
+ }
+
+ function parse_TypeDeclaration()
+ {
+ eventHandler.startNonterminal("TypeDeclaration", e0);
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ eventHandler.endNonterminal("TypeDeclaration", e0);
+ }
+
+ function try_TypeDeclaration()
+ {
+ shiftT(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+
+ function parse_SequenceType()
+ {
+ eventHandler.startNonterminal("SequenceType", e0);
+ switch (l1)
+ {
+ case 35: // '('
+ lookahead2W(258); // EQName^Token | S^WS | '%' | '(' | '(:' | ')' | 'after' | 'allowing' |
+ break;
+ case 125: // 'empty-sequence'
+ lookahead2W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 18045: // 'empty-sequence' '('
+ case 19491: // '(' ')'
+ if (l1 == 125) // 'empty-sequence'
+ {
+ shift(125); // 'empty-sequence'
+ }
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ break;
+ default:
+ parse_ItemType();
+ lookahead1W(228); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' | ';' |
+ switch (l1)
+ {
+ case 40: // '*'
+ case 41: // '+'
+ case 65: // '?'
+ whitespace();
+ parse_OccurrenceIndicator();
+ break;
+ default:
+ break;
+ }
+ }
+ eventHandler.endNonterminal("SequenceType", e0);
+ }
+
+ function try_SequenceType()
+ {
+ switch (l1)
+ {
+ case 35: // '('
+ lookahead2W(258); // EQName^Token | S^WS | '%' | '(' | '(:' | ')' | 'after' | 'allowing' |
+ break;
+ case 125: // 'empty-sequence'
+ lookahead2W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 18045: // 'empty-sequence' '('
+ case 19491: // '(' ')'
+ if (l1 == 125) // 'empty-sequence'
+ {
+ shiftT(125); // 'empty-sequence'
+ }
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ break;
+ default:
+ try_ItemType();
+ lookahead1W(228); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' | ';' |
+ switch (l1)
+ {
+ case 40: // '*'
+ case 41: // '+'
+ case 65: // '?'
+ try_OccurrenceIndicator();
+ break;
+ default:
+ break;
+ }
+ }
+ }
+
+ function parse_OccurrenceIndicator()
+ {
+ eventHandler.startNonterminal("OccurrenceIndicator", e0);
+ switch (l1)
+ {
+ case 65: // '?'
+ shift(65); // '?'
+ break;
+ case 40: // '*'
+ shift(40); // '*'
+ break;
+ default:
+ shift(41); // '+'
+ }
+ eventHandler.endNonterminal("OccurrenceIndicator", e0);
+ }
+
+ function try_OccurrenceIndicator()
+ {
+ switch (l1)
+ {
+ case 65: // '?'
+ shiftT(65); // '?'
+ break;
+ case 40: // '*'
+ shiftT(40); // '*'
+ break;
+ default:
+ shiftT(41); // '+'
+ }
+ }
+
+ function parse_ItemType()
+ {
+ eventHandler.startNonterminal("ItemType", e0);
+ switch (l1)
+ {
+ case 79: // 'array'
+ case 83: // 'attribute'
+ case 97: // 'comment'
+ case 121: // 'document-node'
+ case 122: // 'element'
+ case 147: // 'function'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 198: // 'object'
+ case 220: // 'processing-instruction'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 247: // 'structured-item'
+ case 249: // 'text'
+ lookahead2W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 12879 // 'array' EOF
+ || lk == 12969 // 'json-item' EOF
+ || lk == 12998 // 'object' EOF
+ || lk == 13047 // 'structured-item' EOF
+ || lk == 13903 // 'array' '!='
+ || lk == 13993 // 'json-item' '!='
+ || lk == 14022 // 'object' '!='
+ || lk == 14071 // 'structured-item' '!='
+ || lk == 19535 // 'array' ')'
+ || lk == 19625 // 'json-item' ')'
+ || lk == 19654 // 'object' ')'
+ || lk == 19703 // 'structured-item' ')'
+ || lk == 20047 // 'array' '*'
+ || lk == 20137 // 'json-item' '*'
+ || lk == 20166 // 'object' '*'
+ || lk == 20215 // 'structured-item' '*'
+ || lk == 20559 // 'array' '*'
+ || lk == 20649 // 'json-item' '*'
+ || lk == 20678 // 'object' '*'
+ || lk == 20727 // 'structured-item' '*'
+ || lk == 21071 // 'array' '+'
+ || lk == 21161 // 'json-item' '+'
+ || lk == 21190 // 'object' '+'
+ || lk == 21239 // 'structured-item' '+'
+ || lk == 21583 // 'array' ','
+ || lk == 21673 // 'json-item' ','
+ || lk == 21702 // 'object' ','
+ || lk == 21751 // 'structured-item' ','
+ || lk == 22095 // 'array' '-'
+ || lk == 22185 // 'json-item' '-'
+ || lk == 22214 // 'object' '-'
+ || lk == 22263 // 'structured-item' '-'
+ || lk == 25679 // 'array' ':'
+ || lk == 25769 // 'json-item' ':'
+ || lk == 25798 // 'object' ':'
+ || lk == 25847 // 'structured-item' ':'
+ || lk == 27215 // 'array' ':='
+ || lk == 27305 // 'json-item' ':='
+ || lk == 27334 // 'object' ':='
+ || lk == 27383 // 'structured-item' ':='
+ || lk == 27727 // 'array' ';'
+ || lk == 27817 // 'json-item' ';'
+ || lk == 27846 // 'object' ';'
+ || lk == 27895 // 'structured-item' ';'
+ || lk == 28239 // 'array' '<'
+ || lk == 28329 // 'json-item' '<'
+ || lk == 28358 // 'object' '<'
+ || lk == 28407 // 'structured-item' '<'
+ || lk == 29775 // 'array' '<<'
+ || lk == 29865 // 'json-item' '<<'
+ || lk == 29894 // 'object' '<<'
+ || lk == 29943 // 'structured-item' '<<'
+ || lk == 30287 // 'array' '<='
+ || lk == 30377 // 'json-item' '<='
+ || lk == 30406 // 'object' '<='
+ || lk == 30455 // 'structured-item' '<='
+ || lk == 31311 // 'array' '='
+ || lk == 31401 // 'json-item' '='
+ || lk == 31430 // 'object' '='
+ || lk == 31479 // 'structured-item' '='
+ || lk == 31823 // 'array' '>'
+ || lk == 31913 // 'json-item' '>'
+ || lk == 31942 // 'object' '>'
+ || lk == 31991 // 'structured-item' '>'
+ || lk == 32335 // 'array' '>='
+ || lk == 32425 // 'json-item' '>='
+ || lk == 32454 // 'object' '>='
+ || lk == 32503 // 'structured-item' '>='
+ || lk == 32847 // 'array' '>>'
+ || lk == 32937 // 'json-item' '>>'
+ || lk == 32966 // 'object' '>>'
+ || lk == 33015 // 'structured-item' '>>'
+ || lk == 33359 // 'array' '?'
+ || lk == 33449 // 'json-item' '?'
+ || lk == 33478 // 'object' '?'
+ || lk == 33527 // 'structured-item' '?'
+ || lk == 35919 // 'array' ']'
+ || lk == 36009 // 'json-item' ']'
+ || lk == 36038 // 'object' ']'
+ || lk == 36087 // 'structured-item' ']'
+ || lk == 36431 // 'array' 'after'
+ || lk == 36521 // 'json-item' 'after'
+ || lk == 36550 // 'object' 'after'
+ || lk == 36599 // 'structured-item' 'after'
+ || lk == 37455 // 'array' 'allowing'
+ || lk == 37545 // 'json-item' 'allowing'
+ || lk == 37574 // 'object' 'allowing'
+ || lk == 37623 // 'structured-item' 'allowing'
+ || lk == 38991 // 'array' 'and'
+ || lk == 39081 // 'json-item' 'and'
+ || lk == 39110 // 'object' 'and'
+ || lk == 39159 // 'structured-item' 'and'
+ || lk == 41039 // 'array' 'as'
+ || lk == 41129 // 'json-item' 'as'
+ || lk == 41158 // 'object' 'as'
+ || lk == 41207 // 'structured-item' 'as'
+ || lk == 41551 // 'array' 'ascending'
+ || lk == 41641 // 'json-item' 'ascending'
+ || lk == 41670 // 'object' 'ascending'
+ || lk == 41719 // 'structured-item' 'ascending'
+ || lk == 42063 // 'array' 'at'
+ || lk == 42153 // 'json-item' 'at'
+ || lk == 42182 // 'object' 'at'
+ || lk == 42231 // 'structured-item' 'at'
+ || lk == 43599 // 'array' 'before'
+ || lk == 43689 // 'json-item' 'before'
+ || lk == 43718 // 'object' 'before'
+ || lk == 43767 // 'structured-item' 'before'
+ || lk == 45647 // 'array' 'case'
+ || lk == 45737 // 'json-item' 'case'
+ || lk == 45766 // 'object' 'case'
+ || lk == 45815 // 'structured-item' 'case'
+ || lk == 48719 // 'array' 'collation'
+ || lk == 48809 // 'json-item' 'collation'
+ || lk == 48838 // 'object' 'collation'
+ || lk == 48887 // 'structured-item' 'collation'
+ || lk == 51279 // 'array' 'contains'
+ || lk == 51369 // 'json-item' 'contains'
+ || lk == 51398 // 'object' 'contains'
+ || lk == 51447 // 'structured-item' 'contains'
+ || lk == 54351 // 'array' 'count'
+ || lk == 54441 // 'json-item' 'count'
+ || lk == 54470 // 'object' 'count'
+ || lk == 54519 // 'structured-item' 'count'
+ || lk == 56399 // 'array' 'default'
+ || lk == 56489 // 'json-item' 'default'
+ || lk == 56518 // 'object' 'default'
+ || lk == 56567 // 'structured-item' 'default'
+ || lk == 58447 // 'array' 'descending'
+ || lk == 58537 // 'json-item' 'descending'
+ || lk == 58566 // 'object' 'descending'
+ || lk == 58615 // 'structured-item' 'descending'
+ || lk == 61007 // 'array' 'div'
+ || lk == 61097 // 'json-item' 'div'
+ || lk == 61126 // 'object' 'div'
+ || lk == 61175 // 'structured-item' 'div'
+ || lk == 63055 // 'array' 'else'
+ || lk == 63145 // 'json-item' 'else'
+ || lk == 63174 // 'object' 'else'
+ || lk == 63223 // 'structured-item' 'else'
+ || lk == 63567 // 'array' 'empty'
+ || lk == 63657 // 'json-item' 'empty'
+ || lk == 63686 // 'object' 'empty'
+ || lk == 63735 // 'structured-item' 'empty'
+ || lk == 65103 // 'array' 'end'
+ || lk == 65193 // 'json-item' 'end'
+ || lk == 65222 // 'object' 'end'
+ || lk == 65271 // 'structured-item' 'end'
+ || lk == 66127 // 'array' 'eq'
+ || lk == 66217 // 'json-item' 'eq'
+ || lk == 66246 // 'object' 'eq'
+ || lk == 66295 // 'structured-item' 'eq'
+ || lk == 67663 // 'array' 'except'
+ || lk == 67753 // 'json-item' 'except'
+ || lk == 67782 // 'object' 'except'
+ || lk == 67831 // 'structured-item' 'except'
+ || lk == 68687 // 'array' 'external'
+ || lk == 68777 // 'json-item' 'external'
+ || lk == 68806 // 'object' 'external'
+ || lk == 68855 // 'structured-item' 'external'
+ || lk == 71247 // 'array' 'for'
+ || lk == 71337 // 'json-item' 'for'
+ || lk == 71366 // 'object' 'for'
+ || lk == 71415 // 'structured-item' 'for'
+ || lk == 75855 // 'array' 'ge'
+ || lk == 75945 // 'json-item' 'ge'
+ || lk == 75974 // 'object' 'ge'
+ || lk == 76023 // 'structured-item' 'ge'
+ || lk == 76879 // 'array' 'group'
+ || lk == 76969 // 'json-item' 'group'
+ || lk == 76998 // 'object' 'group'
+ || lk == 77047 // 'structured-item' 'group'
+ || lk == 77903 // 'array' 'gt'
+ || lk == 77993 // 'json-item' 'gt'
+ || lk == 78022 // 'object' 'gt'
+ || lk == 78071 // 'structured-item' 'gt'
+ || lk == 78415 // 'array' 'idiv'
+ || lk == 78505 // 'json-item' 'idiv'
+ || lk == 78534 // 'object' 'idiv'
+ || lk == 78583 // 'structured-item' 'idiv'
+ || lk == 79951 // 'array' 'in'
+ || lk == 80041 // 'json-item' 'in'
+ || lk == 80070 // 'object' 'in'
+ || lk == 80119 // 'structured-item' 'in'
+ || lk == 83023 // 'array' 'instance'
+ || lk == 83113 // 'json-item' 'instance'
+ || lk == 83142 // 'object' 'instance'
+ || lk == 83191 // 'structured-item' 'instance'
+ || lk == 84047 // 'array' 'intersect'
+ || lk == 84137 // 'json-item' 'intersect'
+ || lk == 84166 // 'object' 'intersect'
+ || lk == 84215 // 'structured-item' 'intersect'
+ || lk == 84559 // 'array' 'into'
+ || lk == 84649 // 'json-item' 'into'
+ || lk == 84678 // 'object' 'into'
+ || lk == 84727 // 'structured-item' 'into'
+ || lk == 85071 // 'array' 'is'
+ || lk == 85161 // 'json-item' 'is'
+ || lk == 85190 // 'object' 'is'
+ || lk == 85239 // 'structured-item' 'is'
+ || lk == 89679 // 'array' 'le'
+ || lk == 89769 // 'json-item' 'le'
+ || lk == 89798 // 'object' 'le'
+ || lk == 89847 // 'structured-item' 'le'
+ || lk == 90703 // 'array' 'let'
+ || lk == 90793 // 'json-item' 'let'
+ || lk == 90822 // 'object' 'let'
+ || lk == 90871 // 'structured-item' 'let'
+ || lk == 92751 // 'array' 'lt'
+ || lk == 92841 // 'json-item' 'lt'
+ || lk == 92870 // 'object' 'lt'
+ || lk == 92919 // 'structured-item' 'lt'
+ || lk == 93775 // 'array' 'mod'
+ || lk == 93865 // 'json-item' 'mod'
+ || lk == 93894 // 'object' 'mod'
+ || lk == 93943 // 'structured-item' 'mod'
+ || lk == 94287 // 'array' 'modify'
+ || lk == 94377 // 'json-item' 'modify'
+ || lk == 94406 // 'object' 'modify'
+ || lk == 94455 // 'structured-item' 'modify'
+ || lk == 96847 // 'array' 'ne'
+ || lk == 96937 // 'json-item' 'ne'
+ || lk == 96966 // 'object' 'ne'
+ || lk == 97015 // 'structured-item' 'ne'
+ || lk == 103503 // 'array' 'only'
+ || lk == 103593 // 'json-item' 'only'
+ || lk == 103622 // 'object' 'only'
+ || lk == 103671 // 'structured-item' 'only'
+ || lk == 104527 // 'array' 'or'
+ || lk == 104617 // 'json-item' 'or'
+ || lk == 104646 // 'object' 'or'
+ || lk == 104695 // 'structured-item' 'or'
+ || lk == 105039 // 'array' 'order'
+ || lk == 105129 // 'json-item' 'order'
+ || lk == 105158 // 'object' 'order'
+ || lk == 105207 // 'structured-item' 'order'
+ || lk == 107087 // 'array' 'paragraphs'
+ || lk == 107177 // 'json-item' 'paragraphs'
+ || lk == 107206 // 'object' 'paragraphs'
+ || lk == 107255 // 'structured-item' 'paragraphs'
+ || lk == 114767 // 'array' 'return'
+ || lk == 114857 // 'json-item' 'return'
+ || lk == 114886 // 'object' 'return'
+ || lk == 114935 // 'structured-item' 'return'
+ || lk == 116815 // 'array' 'satisfies'
+ || lk == 116905 // 'json-item' 'satisfies'
+ || lk == 116934 // 'object' 'satisfies'
+ || lk == 116983 // 'structured-item' 'satisfies'
+ || lk == 118863 // 'array' 'score'
+ || lk == 118953 // 'json-item' 'score'
+ || lk == 118982 // 'object' 'score'
+ || lk == 119031 // 'structured-item' 'score'
+ || lk == 121423 // 'array' 'sentences'
+ || lk == 121513 // 'json-item' 'sentences'
+ || lk == 121542 // 'object' 'sentences'
+ || lk == 121591 // 'structured-item' 'sentences'
+ || lk == 123471 // 'array' 'stable'
+ || lk == 123561 // 'json-item' 'stable'
+ || lk == 123590 // 'object' 'stable'
+ || lk == 123639 // 'structured-item' 'stable'
+ || lk == 123983 // 'array' 'start'
+ || lk == 124073 // 'json-item' 'start'
+ || lk == 124102 // 'object' 'start'
+ || lk == 124151 // 'structured-item' 'start'
+ || lk == 129103 // 'array' 'times'
+ || lk == 129193 // 'json-item' 'times'
+ || lk == 129222 // 'object' 'times'
+ || lk == 129271 // 'structured-item' 'times'
+ || lk == 129615 // 'array' 'to'
+ || lk == 129705 // 'json-item' 'to'
+ || lk == 129734 // 'object' 'to'
+ || lk == 129783 // 'structured-item' 'to'
+ || lk == 133199 // 'array' 'union'
+ || lk == 133289 // 'json-item' 'union'
+ || lk == 133318 // 'object' 'union'
+ || lk == 133367 // 'structured-item' 'union'
+ || lk == 139343 // 'array' 'where'
+ || lk == 139433 // 'json-item' 'where'
+ || lk == 139462 // 'object' 'where'
+ || lk == 139511 // 'structured-item' 'where'
+ || lk == 141391 // 'array' 'with'
+ || lk == 141481 // 'json-item' 'with'
+ || lk == 141510 // 'object' 'with'
+ || lk == 141559 // 'structured-item' 'with'
+ || lk == 142927 // 'array' 'words'
+ || lk == 143017 // 'json-item' 'words'
+ || lk == 143046 // 'object' 'words'
+ || lk == 143095 // 'structured-item' 'words'
+ || lk == 143951 // 'array' '{'
+ || lk == 144041 // 'json-item' '{'
+ || lk == 144070 // 'object' '{'
+ || lk == 144119 // 'structured-item' '{'
+ || lk == 145487 // 'array' '|'
+ || lk == 145577 // 'json-item' '|'
+ || lk == 145606 // 'object' '|'
+ || lk == 145655 // 'structured-item' '|'
+ || lk == 145999 // 'array' '||'
+ || lk == 146089 // 'json-item' '||'
+ || lk == 146118 // 'object' '||'
+ || lk == 146167 // 'structured-item' '||'
+ || lk == 146511 // 'array' '|}'
+ || lk == 146601 // 'json-item' '|}'
+ || lk == 146630 // 'object' '|}'
+ || lk == 146679 // 'structured-item' '|}'
+ || lk == 147023 // 'array' '}'
+ || lk == 147113 // 'json-item' '}'
+ || lk == 147142 // 'object' '}'
+ || lk == 147191) // 'structured-item' '}'
+ {
+ lk = memoized(6, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_AtomicOrUnionType();
+ lk = -4;
+ }
+ catch (p4A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONTest();
+ lk = -6;
+ }
+ catch (p6A)
+ {
+ lk = -7;
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(6, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 18003: // 'attribute' '('
+ case 18017: // 'comment' '('
+ case 18041: // 'document-node' '('
+ case 18042: // 'element' '('
+ case 18108: // 'namespace-node' '('
+ case 18114: // 'node' '('
+ case 18140: // 'processing-instruction' '('
+ case 18150: // 'schema-attribute' '('
+ case 18151: // 'schema-element' '('
+ case 18169: // 'text' '('
+ parse_KindTest();
+ break;
+ case 18087: // 'item' '('
+ shift(167); // 'item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ break;
+ case 33: // '%'
+ case 18067: // 'function' '('
+ parse_FunctionTest();
+ break;
+ case 35: // '('
+ parse_ParenthesizedItemType();
+ break;
+ case -6:
+ case 17999: // 'array' '('
+ case 18089: // 'json-item' '('
+ case 18118: // 'object' '('
+ parse_JSONTest();
+ break;
+ case -7:
+ case 18167: // 'structured-item' '('
+ parse_StructuredItemTest();
+ break;
+ default:
+ parse_AtomicOrUnionType();
+ }
+ eventHandler.endNonterminal("ItemType", e0);
+ }
+
+ function try_ItemType()
+ {
+ switch (l1)
+ {
+ case 79: // 'array'
+ case 83: // 'attribute'
+ case 97: // 'comment'
+ case 121: // 'document-node'
+ case 122: // 'element'
+ case 147: // 'function'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 198: // 'object'
+ case 220: // 'processing-instruction'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 247: // 'structured-item'
+ case 249: // 'text'
+ lookahead2W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 12879 // 'array' EOF
+ || lk == 12969 // 'json-item' EOF
+ || lk == 12998 // 'object' EOF
+ || lk == 13047 // 'structured-item' EOF
+ || lk == 13903 // 'array' '!='
+ || lk == 13993 // 'json-item' '!='
+ || lk == 14022 // 'object' '!='
+ || lk == 14071 // 'structured-item' '!='
+ || lk == 19535 // 'array' ')'
+ || lk == 19625 // 'json-item' ')'
+ || lk == 19654 // 'object' ')'
+ || lk == 19703 // 'structured-item' ')'
+ || lk == 20047 // 'array' '*'
+ || lk == 20137 // 'json-item' '*'
+ || lk == 20166 // 'object' '*'
+ || lk == 20215 // 'structured-item' '*'
+ || lk == 20559 // 'array' '*'
+ || lk == 20649 // 'json-item' '*'
+ || lk == 20678 // 'object' '*'
+ || lk == 20727 // 'structured-item' '*'
+ || lk == 21071 // 'array' '+'
+ || lk == 21161 // 'json-item' '+'
+ || lk == 21190 // 'object' '+'
+ || lk == 21239 // 'structured-item' '+'
+ || lk == 21583 // 'array' ','
+ || lk == 21673 // 'json-item' ','
+ || lk == 21702 // 'object' ','
+ || lk == 21751 // 'structured-item' ','
+ || lk == 22095 // 'array' '-'
+ || lk == 22185 // 'json-item' '-'
+ || lk == 22214 // 'object' '-'
+ || lk == 22263 // 'structured-item' '-'
+ || lk == 25679 // 'array' ':'
+ || lk == 25769 // 'json-item' ':'
+ || lk == 25798 // 'object' ':'
+ || lk == 25847 // 'structured-item' ':'
+ || lk == 27215 // 'array' ':='
+ || lk == 27305 // 'json-item' ':='
+ || lk == 27334 // 'object' ':='
+ || lk == 27383 // 'structured-item' ':='
+ || lk == 27727 // 'array' ';'
+ || lk == 27817 // 'json-item' ';'
+ || lk == 27846 // 'object' ';'
+ || lk == 27895 // 'structured-item' ';'
+ || lk == 28239 // 'array' '<'
+ || lk == 28329 // 'json-item' '<'
+ || lk == 28358 // 'object' '<'
+ || lk == 28407 // 'structured-item' '<'
+ || lk == 29775 // 'array' '<<'
+ || lk == 29865 // 'json-item' '<<'
+ || lk == 29894 // 'object' '<<'
+ || lk == 29943 // 'structured-item' '<<'
+ || lk == 30287 // 'array' '<='
+ || lk == 30377 // 'json-item' '<='
+ || lk == 30406 // 'object' '<='
+ || lk == 30455 // 'structured-item' '<='
+ || lk == 31311 // 'array' '='
+ || lk == 31401 // 'json-item' '='
+ || lk == 31430 // 'object' '='
+ || lk == 31479 // 'structured-item' '='
+ || lk == 31823 // 'array' '>'
+ || lk == 31913 // 'json-item' '>'
+ || lk == 31942 // 'object' '>'
+ || lk == 31991 // 'structured-item' '>'
+ || lk == 32335 // 'array' '>='
+ || lk == 32425 // 'json-item' '>='
+ || lk == 32454 // 'object' '>='
+ || lk == 32503 // 'structured-item' '>='
+ || lk == 32847 // 'array' '>>'
+ || lk == 32937 // 'json-item' '>>'
+ || lk == 32966 // 'object' '>>'
+ || lk == 33015 // 'structured-item' '>>'
+ || lk == 33359 // 'array' '?'
+ || lk == 33449 // 'json-item' '?'
+ || lk == 33478 // 'object' '?'
+ || lk == 33527 // 'structured-item' '?'
+ || lk == 35919 // 'array' ']'
+ || lk == 36009 // 'json-item' ']'
+ || lk == 36038 // 'object' ']'
+ || lk == 36087 // 'structured-item' ']'
+ || lk == 36431 // 'array' 'after'
+ || lk == 36521 // 'json-item' 'after'
+ || lk == 36550 // 'object' 'after'
+ || lk == 36599 // 'structured-item' 'after'
+ || lk == 37455 // 'array' 'allowing'
+ || lk == 37545 // 'json-item' 'allowing'
+ || lk == 37574 // 'object' 'allowing'
+ || lk == 37623 // 'structured-item' 'allowing'
+ || lk == 38991 // 'array' 'and'
+ || lk == 39081 // 'json-item' 'and'
+ || lk == 39110 // 'object' 'and'
+ || lk == 39159 // 'structured-item' 'and'
+ || lk == 41039 // 'array' 'as'
+ || lk == 41129 // 'json-item' 'as'
+ || lk == 41158 // 'object' 'as'
+ || lk == 41207 // 'structured-item' 'as'
+ || lk == 41551 // 'array' 'ascending'
+ || lk == 41641 // 'json-item' 'ascending'
+ || lk == 41670 // 'object' 'ascending'
+ || lk == 41719 // 'structured-item' 'ascending'
+ || lk == 42063 // 'array' 'at'
+ || lk == 42153 // 'json-item' 'at'
+ || lk == 42182 // 'object' 'at'
+ || lk == 42231 // 'structured-item' 'at'
+ || lk == 43599 // 'array' 'before'
+ || lk == 43689 // 'json-item' 'before'
+ || lk == 43718 // 'object' 'before'
+ || lk == 43767 // 'structured-item' 'before'
+ || lk == 45647 // 'array' 'case'
+ || lk == 45737 // 'json-item' 'case'
+ || lk == 45766 // 'object' 'case'
+ || lk == 45815 // 'structured-item' 'case'
+ || lk == 48719 // 'array' 'collation'
+ || lk == 48809 // 'json-item' 'collation'
+ || lk == 48838 // 'object' 'collation'
+ || lk == 48887 // 'structured-item' 'collation'
+ || lk == 51279 // 'array' 'contains'
+ || lk == 51369 // 'json-item' 'contains'
+ || lk == 51398 // 'object' 'contains'
+ || lk == 51447 // 'structured-item' 'contains'
+ || lk == 54351 // 'array' 'count'
+ || lk == 54441 // 'json-item' 'count'
+ || lk == 54470 // 'object' 'count'
+ || lk == 54519 // 'structured-item' 'count'
+ || lk == 56399 // 'array' 'default'
+ || lk == 56489 // 'json-item' 'default'
+ || lk == 56518 // 'object' 'default'
+ || lk == 56567 // 'structured-item' 'default'
+ || lk == 58447 // 'array' 'descending'
+ || lk == 58537 // 'json-item' 'descending'
+ || lk == 58566 // 'object' 'descending'
+ || lk == 58615 // 'structured-item' 'descending'
+ || lk == 61007 // 'array' 'div'
+ || lk == 61097 // 'json-item' 'div'
+ || lk == 61126 // 'object' 'div'
+ || lk == 61175 // 'structured-item' 'div'
+ || lk == 63055 // 'array' 'else'
+ || lk == 63145 // 'json-item' 'else'
+ || lk == 63174 // 'object' 'else'
+ || lk == 63223 // 'structured-item' 'else'
+ || lk == 63567 // 'array' 'empty'
+ || lk == 63657 // 'json-item' 'empty'
+ || lk == 63686 // 'object' 'empty'
+ || lk == 63735 // 'structured-item' 'empty'
+ || lk == 65103 // 'array' 'end'
+ || lk == 65193 // 'json-item' 'end'
+ || lk == 65222 // 'object' 'end'
+ || lk == 65271 // 'structured-item' 'end'
+ || lk == 66127 // 'array' 'eq'
+ || lk == 66217 // 'json-item' 'eq'
+ || lk == 66246 // 'object' 'eq'
+ || lk == 66295 // 'structured-item' 'eq'
+ || lk == 67663 // 'array' 'except'
+ || lk == 67753 // 'json-item' 'except'
+ || lk == 67782 // 'object' 'except'
+ || lk == 67831 // 'structured-item' 'except'
+ || lk == 68687 // 'array' 'external'
+ || lk == 68777 // 'json-item' 'external'
+ || lk == 68806 // 'object' 'external'
+ || lk == 68855 // 'structured-item' 'external'
+ || lk == 71247 // 'array' 'for'
+ || lk == 71337 // 'json-item' 'for'
+ || lk == 71366 // 'object' 'for'
+ || lk == 71415 // 'structured-item' 'for'
+ || lk == 75855 // 'array' 'ge'
+ || lk == 75945 // 'json-item' 'ge'
+ || lk == 75974 // 'object' 'ge'
+ || lk == 76023 // 'structured-item' 'ge'
+ || lk == 76879 // 'array' 'group'
+ || lk == 76969 // 'json-item' 'group'
+ || lk == 76998 // 'object' 'group'
+ || lk == 77047 // 'structured-item' 'group'
+ || lk == 77903 // 'array' 'gt'
+ || lk == 77993 // 'json-item' 'gt'
+ || lk == 78022 // 'object' 'gt'
+ || lk == 78071 // 'structured-item' 'gt'
+ || lk == 78415 // 'array' 'idiv'
+ || lk == 78505 // 'json-item' 'idiv'
+ || lk == 78534 // 'object' 'idiv'
+ || lk == 78583 // 'structured-item' 'idiv'
+ || lk == 79951 // 'array' 'in'
+ || lk == 80041 // 'json-item' 'in'
+ || lk == 80070 // 'object' 'in'
+ || lk == 80119 // 'structured-item' 'in'
+ || lk == 83023 // 'array' 'instance'
+ || lk == 83113 // 'json-item' 'instance'
+ || lk == 83142 // 'object' 'instance'
+ || lk == 83191 // 'structured-item' 'instance'
+ || lk == 84047 // 'array' 'intersect'
+ || lk == 84137 // 'json-item' 'intersect'
+ || lk == 84166 // 'object' 'intersect'
+ || lk == 84215 // 'structured-item' 'intersect'
+ || lk == 84559 // 'array' 'into'
+ || lk == 84649 // 'json-item' 'into'
+ || lk == 84678 // 'object' 'into'
+ || lk == 84727 // 'structured-item' 'into'
+ || lk == 85071 // 'array' 'is'
+ || lk == 85161 // 'json-item' 'is'
+ || lk == 85190 // 'object' 'is'
+ || lk == 85239 // 'structured-item' 'is'
+ || lk == 89679 // 'array' 'le'
+ || lk == 89769 // 'json-item' 'le'
+ || lk == 89798 // 'object' 'le'
+ || lk == 89847 // 'structured-item' 'le'
+ || lk == 90703 // 'array' 'let'
+ || lk == 90793 // 'json-item' 'let'
+ || lk == 90822 // 'object' 'let'
+ || lk == 90871 // 'structured-item' 'let'
+ || lk == 92751 // 'array' 'lt'
+ || lk == 92841 // 'json-item' 'lt'
+ || lk == 92870 // 'object' 'lt'
+ || lk == 92919 // 'structured-item' 'lt'
+ || lk == 93775 // 'array' 'mod'
+ || lk == 93865 // 'json-item' 'mod'
+ || lk == 93894 // 'object' 'mod'
+ || lk == 93943 // 'structured-item' 'mod'
+ || lk == 94287 // 'array' 'modify'
+ || lk == 94377 // 'json-item' 'modify'
+ || lk == 94406 // 'object' 'modify'
+ || lk == 94455 // 'structured-item' 'modify'
+ || lk == 96847 // 'array' 'ne'
+ || lk == 96937 // 'json-item' 'ne'
+ || lk == 96966 // 'object' 'ne'
+ || lk == 97015 // 'structured-item' 'ne'
+ || lk == 103503 // 'array' 'only'
+ || lk == 103593 // 'json-item' 'only'
+ || lk == 103622 // 'object' 'only'
+ || lk == 103671 // 'structured-item' 'only'
+ || lk == 104527 // 'array' 'or'
+ || lk == 104617 // 'json-item' 'or'
+ || lk == 104646 // 'object' 'or'
+ || lk == 104695 // 'structured-item' 'or'
+ || lk == 105039 // 'array' 'order'
+ || lk == 105129 // 'json-item' 'order'
+ || lk == 105158 // 'object' 'order'
+ || lk == 105207 // 'structured-item' 'order'
+ || lk == 107087 // 'array' 'paragraphs'
+ || lk == 107177 // 'json-item' 'paragraphs'
+ || lk == 107206 // 'object' 'paragraphs'
+ || lk == 107255 // 'structured-item' 'paragraphs'
+ || lk == 114767 // 'array' 'return'
+ || lk == 114857 // 'json-item' 'return'
+ || lk == 114886 // 'object' 'return'
+ || lk == 114935 // 'structured-item' 'return'
+ || lk == 116815 // 'array' 'satisfies'
+ || lk == 116905 // 'json-item' 'satisfies'
+ || lk == 116934 // 'object' 'satisfies'
+ || lk == 116983 // 'structured-item' 'satisfies'
+ || lk == 118863 // 'array' 'score'
+ || lk == 118953 // 'json-item' 'score'
+ || lk == 118982 // 'object' 'score'
+ || lk == 119031 // 'structured-item' 'score'
+ || lk == 121423 // 'array' 'sentences'
+ || lk == 121513 // 'json-item' 'sentences'
+ || lk == 121542 // 'object' 'sentences'
+ || lk == 121591 // 'structured-item' 'sentences'
+ || lk == 123471 // 'array' 'stable'
+ || lk == 123561 // 'json-item' 'stable'
+ || lk == 123590 // 'object' 'stable'
+ || lk == 123639 // 'structured-item' 'stable'
+ || lk == 123983 // 'array' 'start'
+ || lk == 124073 // 'json-item' 'start'
+ || lk == 124102 // 'object' 'start'
+ || lk == 124151 // 'structured-item' 'start'
+ || lk == 129103 // 'array' 'times'
+ || lk == 129193 // 'json-item' 'times'
+ || lk == 129222 // 'object' 'times'
+ || lk == 129271 // 'structured-item' 'times'
+ || lk == 129615 // 'array' 'to'
+ || lk == 129705 // 'json-item' 'to'
+ || lk == 129734 // 'object' 'to'
+ || lk == 129783 // 'structured-item' 'to'
+ || lk == 133199 // 'array' 'union'
+ || lk == 133289 // 'json-item' 'union'
+ || lk == 133318 // 'object' 'union'
+ || lk == 133367 // 'structured-item' 'union'
+ || lk == 139343 // 'array' 'where'
+ || lk == 139433 // 'json-item' 'where'
+ || lk == 139462 // 'object' 'where'
+ || lk == 139511 // 'structured-item' 'where'
+ || lk == 141391 // 'array' 'with'
+ || lk == 141481 // 'json-item' 'with'
+ || lk == 141510 // 'object' 'with'
+ || lk == 141559 // 'structured-item' 'with'
+ || lk == 142927 // 'array' 'words'
+ || lk == 143017 // 'json-item' 'words'
+ || lk == 143046 // 'object' 'words'
+ || lk == 143095 // 'structured-item' 'words'
+ || lk == 143951 // 'array' '{'
+ || lk == 144041 // 'json-item' '{'
+ || lk == 144070 // 'object' '{'
+ || lk == 144119 // 'structured-item' '{'
+ || lk == 145487 // 'array' '|'
+ || lk == 145577 // 'json-item' '|'
+ || lk == 145606 // 'object' '|'
+ || lk == 145655 // 'structured-item' '|'
+ || lk == 145999 // 'array' '||'
+ || lk == 146089 // 'json-item' '||'
+ || lk == 146118 // 'object' '||'
+ || lk == 146167 // 'structured-item' '||'
+ || lk == 146511 // 'array' '|}'
+ || lk == 146601 // 'json-item' '|}'
+ || lk == 146630 // 'object' '|}'
+ || lk == 146679 // 'structured-item' '|}'
+ || lk == 147023 // 'array' '}'
+ || lk == 147113 // 'json-item' '}'
+ || lk == 147142 // 'object' '}'
+ || lk == 147191) // 'structured-item' '}'
+ {
+ lk = memoized(6, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_AtomicOrUnionType();
+ memoize(6, e0A, -4);
+ lk = -8;
+ }
+ catch (p4A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONTest();
+ memoize(6, e0A, -6);
+ lk = -8;
+ }
+ catch (p6A)
+ {
+ lk = -7;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(6, e0A, -7);
+ }
+ }
+ }
+ }
+ switch (lk)
+ {
+ case 18003: // 'attribute' '('
+ case 18017: // 'comment' '('
+ case 18041: // 'document-node' '('
+ case 18042: // 'element' '('
+ case 18108: // 'namespace-node' '('
+ case 18114: // 'node' '('
+ case 18140: // 'processing-instruction' '('
+ case 18150: // 'schema-attribute' '('
+ case 18151: // 'schema-element' '('
+ case 18169: // 'text' '('
+ try_KindTest();
+ break;
+ case 18087: // 'item' '('
+ shiftT(167); // 'item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ break;
+ case 33: // '%'
+ case 18067: // 'function' '('
+ try_FunctionTest();
+ break;
+ case 35: // '('
+ try_ParenthesizedItemType();
+ break;
+ case -6:
+ case 17999: // 'array' '('
+ case 18089: // 'json-item' '('
+ case 18118: // 'object' '('
+ try_JSONTest();
+ break;
+ case -7:
+ case 18167: // 'structured-item' '('
+ try_StructuredItemTest();
+ break;
+ case -8:
+ break;
+ default:
+ try_AtomicOrUnionType();
+ }
+ }
+
+ function parse_JSONTest()
+ {
+ eventHandler.startNonterminal("JSONTest", e0);
+ switch (l1)
+ {
+ case 169: // 'json-item'
+ parse_JSONItemTest();
+ break;
+ case 198: // 'object'
+ parse_JSONObjectTest();
+ break;
+ default:
+ parse_JSONArrayTest();
+ }
+ eventHandler.endNonterminal("JSONTest", e0);
+ }
+
+ function try_JSONTest()
+ {
+ switch (l1)
+ {
+ case 169: // 'json-item'
+ try_JSONItemTest();
+ break;
+ case 198: // 'object'
+ try_JSONObjectTest();
+ break;
+ default:
+ try_JSONArrayTest();
+ }
+ }
+
+ function parse_StructuredItemTest()
+ {
+ eventHandler.startNonterminal("StructuredItemTest", e0);
+ shift(247); // 'structured-item'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ }
+ eventHandler.endNonterminal("StructuredItemTest", e0);
+ }
+
+ function try_StructuredItemTest()
+ {
+ shiftT(247); // 'structured-item'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+ }
+
+ function parse_JSONItemTest()
+ {
+ eventHandler.startNonterminal("JSONItemTest", e0);
+ shift(169); // 'json-item'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ }
+ eventHandler.endNonterminal("JSONItemTest", e0);
+ }
+
+ function try_JSONItemTest()
+ {
+ shiftT(169); // 'json-item'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+ }
+
+ function parse_JSONObjectTest()
+ {
+ eventHandler.startNonterminal("JSONObjectTest", e0);
+ shift(198); // 'object'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ }
+ eventHandler.endNonterminal("JSONObjectTest", e0);
+ }
+
+ function try_JSONObjectTest()
+ {
+ shiftT(198); // 'object'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+ }
+
+ function parse_JSONArrayTest()
+ {
+ eventHandler.startNonterminal("JSONArrayTest", e0);
+ shift(79); // 'array'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ }
+ eventHandler.endNonterminal("JSONArrayTest", e0);
+ }
+
+ function try_JSONArrayTest()
+ {
+ shiftT(79); // 'array'
+ lookahead1W(232); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ if (l1 == 35) // '('
+ {
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+ }
+
+ function parse_AtomicOrUnionType()
+ {
+ eventHandler.startNonterminal("AtomicOrUnionType", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("AtomicOrUnionType", e0);
+ }
+
+ function try_AtomicOrUnionType()
+ {
+ try_EQName();
+ }
+
+ function parse_KindTest()
+ {
+ eventHandler.startNonterminal("KindTest", e0);
+ switch (l1)
+ {
+ case 121: // 'document-node'
+ parse_DocumentTest();
+ break;
+ case 122: // 'element'
+ parse_ElementTest();
+ break;
+ case 83: // 'attribute'
+ parse_AttributeTest();
+ break;
+ case 231: // 'schema-element'
+ parse_SchemaElementTest();
+ break;
+ case 230: // 'schema-attribute'
+ parse_SchemaAttributeTest();
+ break;
+ case 220: // 'processing-instruction'
+ parse_PITest();
+ break;
+ case 97: // 'comment'
+ parse_CommentTest();
+ break;
+ case 249: // 'text'
+ parse_TextTest();
+ break;
+ case 188: // 'namespace-node'
+ parse_NamespaceNodeTest();
+ break;
+ default:
+ parse_AnyKindTest();
+ }
+ eventHandler.endNonterminal("KindTest", e0);
+ }
+
+ function try_KindTest()
+ {
+ switch (l1)
+ {
+ case 121: // 'document-node'
+ try_DocumentTest();
+ break;
+ case 122: // 'element'
+ try_ElementTest();
+ break;
+ case 83: // 'attribute'
+ try_AttributeTest();
+ break;
+ case 231: // 'schema-element'
+ try_SchemaElementTest();
+ break;
+ case 230: // 'schema-attribute'
+ try_SchemaAttributeTest();
+ break;
+ case 220: // 'processing-instruction'
+ try_PITest();
+ break;
+ case 97: // 'comment'
+ try_CommentTest();
+ break;
+ case 249: // 'text'
+ try_TextTest();
+ break;
+ case 188: // 'namespace-node'
+ try_NamespaceNodeTest();
+ break;
+ default:
+ try_AnyKindTest();
+ }
+ }
+
+ function parse_AnyKindTest()
+ {
+ eventHandler.startNonterminal("AnyKindTest", e0);
+ shift(194); // 'node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("AnyKindTest", e0);
+ }
+
+ function try_AnyKindTest()
+ {
+ shiftT(194); // 'node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_DocumentTest()
+ {
+ eventHandler.startNonterminal("DocumentTest", e0);
+ shift(121); // 'document-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(154); // S^WS | '(:' | ')' | 'element' | 'schema-element'
+ if (l1 != 38) // ')'
+ {
+ switch (l1)
+ {
+ case 122: // 'element'
+ whitespace();
+ parse_ElementTest();
+ break;
+ default:
+ whitespace();
+ parse_SchemaElementTest();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("DocumentTest", e0);
+ }
+
+ function try_DocumentTest()
+ {
+ shiftT(121); // 'document-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(154); // S^WS | '(:' | ')' | 'element' | 'schema-element'
+ if (l1 != 38) // ')'
+ {
+ switch (l1)
+ {
+ case 122: // 'element'
+ try_ElementTest();
+ break;
+ default:
+ try_SchemaElementTest();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_TextTest()
+ {
+ eventHandler.startNonterminal("TextTest", e0);
+ shift(249); // 'text'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("TextTest", e0);
+ }
+
+ function try_TextTest()
+ {
+ shiftT(249); // 'text'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_CommentTest()
+ {
+ eventHandler.startNonterminal("CommentTest", e0);
+ shift(97); // 'comment'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("CommentTest", e0);
+ }
+
+ function try_CommentTest()
+ {
+ shiftT(97); // 'comment'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_NamespaceNodeTest()
+ {
+ eventHandler.startNonterminal("NamespaceNodeTest", e0);
+ shift(188); // 'namespace-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("NamespaceNodeTest", e0);
+ }
+
+ function try_NamespaceNodeTest()
+ {
+ shiftT(188); // 'namespace-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_PITest()
+ {
+ eventHandler.startNonterminal("PITest", e0);
+ shift(220); // 'processing-instruction'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(243); // StringLiteral | NCName^Token | S^WS | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 38) // ')'
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ default:
+ whitespace();
+ parse_NCName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("PITest", e0);
+ }
+
+ function try_PITest()
+ {
+ shiftT(220); // 'processing-instruction'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(243); // StringLiteral | NCName^Token | S^WS | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 38) // ')'
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ default:
+ try_NCName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_AttributeTest()
+ {
+ eventHandler.startNonterminal("AttributeTest", e0);
+ shift(83); // 'attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 38) // ')'
+ {
+ whitespace();
+ parse_AttribNameOrWildcard();
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 == 42) // ','
+ {
+ shift(42); // ','
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_TypeName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("AttributeTest", e0);
+ }
+
+ function try_AttributeTest()
+ {
+ shiftT(83); // 'attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 38) // ')'
+ {
+ try_AttribNameOrWildcard();
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 == 42) // ','
+ {
+ shiftT(42); // ','
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_TypeName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_AttribNameOrWildcard()
+ {
+ eventHandler.startNonterminal("AttribNameOrWildcard", e0);
+ switch (l1)
+ {
+ case 39: // '*'
+ shift(39); // '*'
+ break;
+ default:
+ parse_AttributeName();
+ }
+ eventHandler.endNonterminal("AttribNameOrWildcard", e0);
+ }
+
+ function try_AttribNameOrWildcard()
+ {
+ switch (l1)
+ {
+ case 39: // '*'
+ shiftT(39); // '*'
+ break;
+ default:
+ try_AttributeName();
+ }
+ }
+
+ function parse_SchemaAttributeTest()
+ {
+ eventHandler.startNonterminal("SchemaAttributeTest", e0);
+ shift(230); // 'schema-attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_AttributeDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("SchemaAttributeTest", e0);
+ }
+
+ function try_SchemaAttributeTest()
+ {
+ shiftT(230); // 'schema-attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_AttributeDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_AttributeDeclaration()
+ {
+ eventHandler.startNonterminal("AttributeDeclaration", e0);
+ parse_AttributeName();
+ eventHandler.endNonterminal("AttributeDeclaration", e0);
+ }
+
+ function try_AttributeDeclaration()
+ {
+ try_AttributeName();
+ }
+
+ function parse_ElementTest()
+ {
+ eventHandler.startNonterminal("ElementTest", e0);
+ shift(122); // 'element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 38) // ')'
+ {
+ whitespace();
+ parse_ElementNameOrWildcard();
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 == 42) // ','
+ {
+ shift(42); // ','
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_TypeName();
+ lookahead1W(106); // S^WS | '(:' | ')' | '?'
+ if (l1 == 65) // '?'
+ {
+ shift(65); // '?'
+ }
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("ElementTest", e0);
+ }
+
+ function try_ElementTest()
+ {
+ shiftT(122); // 'element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 38) // ')'
+ {
+ try_ElementNameOrWildcard();
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 == 42) // ','
+ {
+ shiftT(42); // ','
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_TypeName();
+ lookahead1W(106); // S^WS | '(:' | ')' | '?'
+ if (l1 == 65) // '?'
+ {
+ shiftT(65); // '?'
+ }
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_ElementNameOrWildcard()
+ {
+ eventHandler.startNonterminal("ElementNameOrWildcard", e0);
+ switch (l1)
+ {
+ case 39: // '*'
+ shift(39); // '*'
+ break;
+ default:
+ parse_ElementName();
+ }
+ eventHandler.endNonterminal("ElementNameOrWildcard", e0);
+ }
+
+ function try_ElementNameOrWildcard()
+ {
+ switch (l1)
+ {
+ case 39: // '*'
+ shiftT(39); // '*'
+ break;
+ default:
+ try_ElementName();
+ }
+ }
+
+ function parse_SchemaElementTest()
+ {
+ eventHandler.startNonterminal("SchemaElementTest", e0);
+ shift(231); // 'schema-element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ElementDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("SchemaElementTest", e0);
+ }
+
+ function try_SchemaElementTest()
+ {
+ shiftT(231); // 'schema-element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_ElementDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_ElementDeclaration()
+ {
+ eventHandler.startNonterminal("ElementDeclaration", e0);
+ parse_ElementName();
+ eventHandler.endNonterminal("ElementDeclaration", e0);
+ }
+
+ function try_ElementDeclaration()
+ {
+ try_ElementName();
+ }
+
+ function parse_AttributeName()
+ {
+ eventHandler.startNonterminal("AttributeName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("AttributeName", e0);
+ }
+
+ function try_AttributeName()
+ {
+ try_EQName();
+ }
+
+ function parse_ElementName()
+ {
+ eventHandler.startNonterminal("ElementName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("ElementName", e0);
+ }
+
+ function try_ElementName()
+ {
+ try_EQName();
+ }
+
+ function parse_SimpleTypeName()
+ {
+ eventHandler.startNonterminal("SimpleTypeName", e0);
+ parse_TypeName();
+ eventHandler.endNonterminal("SimpleTypeName", e0);
+ }
+
+ function try_SimpleTypeName()
+ {
+ try_TypeName();
+ }
+
+ function parse_TypeName()
+ {
+ eventHandler.startNonterminal("TypeName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("TypeName", e0);
+ }
+
+ function try_TypeName()
+ {
+ try_EQName();
+ }
+
+ function parse_FunctionTest()
+ {
+ eventHandler.startNonterminal("FunctionTest", e0);
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 33) // '%'
+ {
+ break;
+ }
+ whitespace();
+ parse_Annotation();
+ }
+ switch (l1)
+ {
+ case 147: // 'function'
+ lookahead2W(22); // S^WS | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ lk = memoized(7, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_AnyFunctionTest();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(7, e0, lk);
+ }
+ switch (lk)
+ {
+ case -1:
+ whitespace();
+ parse_AnyFunctionTest();
+ break;
+ default:
+ whitespace();
+ parse_TypedFunctionTest();
+ }
+ eventHandler.endNonterminal("FunctionTest", e0);
+ }
+
+ function try_FunctionTest()
+ {
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 33) // '%'
+ {
+ break;
+ }
+ try_Annotation();
+ }
+ switch (l1)
+ {
+ case 147: // 'function'
+ lookahead2W(22); // S^WS | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ lk = memoized(7, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_AnyFunctionTest();
+ memoize(7, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(7, e0A, -2);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ try_AnyFunctionTest();
+ break;
+ case -3:
+ break;
+ default:
+ try_TypedFunctionTest();
+ }
+ }
+
+ function parse_AnyFunctionTest()
+ {
+ eventHandler.startNonterminal("AnyFunctionTest", e0);
+ shift(147); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(24); // S^WS | '(:' | '*'
+ shift(39); // '*'
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("AnyFunctionTest", e0);
+ }
+
+ function try_AnyFunctionTest()
+ {
+ shiftT(147); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(24); // S^WS | '(:' | '*'
+ shiftT(39); // '*'
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_TypedFunctionTest()
+ {
+ eventHandler.startNonterminal("TypedFunctionTest", e0);
+ shift(147); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(258); // EQName^Token | S^WS | '%' | '(' | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 38) // ')'
+ {
+ whitespace();
+ parse_SequenceType();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ }
+ shift(38); // ')'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ eventHandler.endNonterminal("TypedFunctionTest", e0);
+ }
+
+ function try_TypedFunctionTest()
+ {
+ shiftT(147); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(258); // EQName^Token | S^WS | '%' | '(' | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 38) // ')'
+ {
+ try_SequenceType();
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+ shiftT(38); // ')'
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shiftT(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+
+ function parse_ParenthesizedItemType()
+ {
+ eventHandler.startNonterminal("ParenthesizedItemType", e0);
+ shift(35); // '('
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ItemType();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(38); // ')'
+ eventHandler.endNonterminal("ParenthesizedItemType", e0);
+ }
+
+ function try_ParenthesizedItemType()
+ {
+ shiftT(35); // '('
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_ItemType();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(38); // ')'
+ }
+
+ function parse_RevalidationDecl()
+ {
+ eventHandler.startNonterminal("RevalidationDecl", e0);
+ shift(109); // 'declare'
+ lookahead1W(75); // S^WS | '(:' | 'revalidation'
+ shift(226); // 'revalidation'
+ lookahead1W(162); // S^WS | '(:' | 'lax' | 'skip' | 'strict'
+ switch (l1)
+ {
+ case 245: // 'strict'
+ shift(245); // 'strict'
+ break;
+ case 174: // 'lax'
+ shift(174); // 'lax'
+ break;
+ default:
+ shift(238); // 'skip'
+ }
+ eventHandler.endNonterminal("RevalidationDecl", e0);
+ }
+
+ function parse_InsertExprTargetChoice()
+ {
+ eventHandler.startNonterminal("InsertExprTargetChoice", e0);
+ switch (l1)
+ {
+ case 71: // 'after'
+ shift(71); // 'after'
+ break;
+ case 85: // 'before'
+ shift(85); // 'before'
+ break;
+ default:
+ if (l1 == 80) // 'as'
+ {
+ shift(80); // 'as'
+ lookahead1W(123); // S^WS | '(:' | 'first' | 'last'
+ switch (l1)
+ {
+ case 136: // 'first'
+ shift(136); // 'first'
+ break;
+ default:
+ shift(173); // 'last'
+ }
+ }
+ lookahead1W(57); // S^WS | '(:' | 'into'
+ shift(165); // 'into'
+ }
+ eventHandler.endNonterminal("InsertExprTargetChoice", e0);
+ }
+
+ function try_InsertExprTargetChoice()
+ {
+ switch (l1)
+ {
+ case 71: // 'after'
+ shiftT(71); // 'after'
+ break;
+ case 85: // 'before'
+ shiftT(85); // 'before'
+ break;
+ default:
+ if (l1 == 80) // 'as'
+ {
+ shiftT(80); // 'as'
+ lookahead1W(123); // S^WS | '(:' | 'first' | 'last'
+ switch (l1)
+ {
+ case 136: // 'first'
+ shiftT(136); // 'first'
+ break;
+ default:
+ shiftT(173); // 'last'
+ }
+ }
+ lookahead1W(57); // S^WS | '(:' | 'into'
+ shiftT(165); // 'into'
+ }
+ }
+
+ function parse_InsertExpr()
+ {
+ eventHandler.startNonterminal("InsertExpr", e0);
+ shift(161); // 'insert'
+ lookahead1W(133); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 194: // 'node'
+ shift(194); // 'node'
+ break;
+ default:
+ shift(195); // 'nodes'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_SourceExpr();
+ whitespace();
+ parse_InsertExprTargetChoice();
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_TargetExpr();
+ eventHandler.endNonterminal("InsertExpr", e0);
+ }
+
+ function try_InsertExpr()
+ {
+ shiftT(161); // 'insert'
+ lookahead1W(133); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 194: // 'node'
+ shiftT(194); // 'node'
+ break;
+ default:
+ shiftT(195); // 'nodes'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_SourceExpr();
+ try_InsertExprTargetChoice();
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_TargetExpr();
+ }
+
+ function parse_DeleteExpr()
+ {
+ eventHandler.startNonterminal("DeleteExpr", e0);
+ shift(111); // 'delete'
+ lookahead1W(133); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 194: // 'node'
+ shift(194); // 'node'
+ break;
+ default:
+ shift(195); // 'nodes'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_TargetExpr();
+ eventHandler.endNonterminal("DeleteExpr", e0);
+ }
+
+ function try_DeleteExpr()
+ {
+ shiftT(111); // 'delete'
+ lookahead1W(133); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 194: // 'node'
+ shiftT(194); // 'node'
+ break;
+ default:
+ shiftT(195); // 'nodes'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_TargetExpr();
+ }
+
+ function parse_ReplaceExpr()
+ {
+ eventHandler.startNonterminal("ReplaceExpr", e0);
+ shift(223); // 'replace'
+ lookahead1W(134); // S^WS | '(:' | 'node' | 'value'
+ if (l1 == 267) // 'value'
+ {
+ shift(267); // 'value'
+ lookahead1W(67); // S^WS | '(:' | 'of'
+ shift(200); // 'of'
+ }
+ lookahead1W(65); // S^WS | '(:' | 'node'
+ shift(194); // 'node'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_TargetExpr();
+ shift(276); // 'with'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ReplaceExpr", e0);
+ }
+
+ function try_ReplaceExpr()
+ {
+ shiftT(223); // 'replace'
+ lookahead1W(134); // S^WS | '(:' | 'node' | 'value'
+ if (l1 == 267) // 'value'
+ {
+ shiftT(267); // 'value'
+ lookahead1W(67); // S^WS | '(:' | 'of'
+ shiftT(200); // 'of'
+ }
+ lookahead1W(65); // S^WS | '(:' | 'node'
+ shiftT(194); // 'node'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_TargetExpr();
+ shiftT(276); // 'with'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_RenameExpr()
+ {
+ eventHandler.startNonterminal("RenameExpr", e0);
+ shift(222); // 'rename'
+ lookahead1W(65); // S^WS | '(:' | 'node'
+ shift(194); // 'node'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_TargetExpr();
+ shift(80); // 'as'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_NewNameExpr();
+ eventHandler.endNonterminal("RenameExpr", e0);
+ }
+
+ function try_RenameExpr()
+ {
+ shiftT(222); // 'rename'
+ lookahead1W(65); // S^WS | '(:' | 'node'
+ shiftT(194); // 'node'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_TargetExpr();
+ shiftT(80); // 'as'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_NewNameExpr();
+ }
+
+ function parse_SourceExpr()
+ {
+ eventHandler.startNonterminal("SourceExpr", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SourceExpr", e0);
+ }
+
+ function try_SourceExpr()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_TargetExpr()
+ {
+ eventHandler.startNonterminal("TargetExpr", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TargetExpr", e0);
+ }
+
+ function try_TargetExpr()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_NewNameExpr()
+ {
+ eventHandler.startNonterminal("NewNameExpr", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("NewNameExpr", e0);
+ }
+
+ function try_NewNameExpr()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_TransformExpr()
+ {
+ eventHandler.startNonterminal("TransformExpr", e0);
+ shift(104); // 'copy'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_TransformSpec();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_TransformSpec();
+ }
+ shift(184); // 'modify'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TransformExpr", e0);
+ }
+
+ function try_TransformExpr()
+ {
+ shiftT(104); // 'copy'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_TransformSpec();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_TransformSpec();
+ }
+ shiftT(184); // 'modify'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(224); // 'return'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_TransformSpec()
+ {
+ eventHandler.startNonterminal("TransformSpec", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TransformSpec", e0);
+ }
+
+ function try_TransformSpec()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_FTSelection()
+ {
+ eventHandler.startNonterminal("FTSelection", e0);
+ parse_FTOr();
+ for (;;)
+ {
+ lookahead1W(211); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(161); // S^WS | '(:' | 'end' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 116 // 'different'
+ && lk != 118 // 'distance'
+ && lk != 128 // 'entire'
+ && lk != 206 // 'ordered'
+ && lk != 227 // 'same'
+ && lk != 275 // 'window'
+ && lk != 65106 // 'at' 'end'
+ && lk != 123986) // 'at' 'start'
+ {
+ break;
+ }
+ whitespace();
+ parse_FTPosFilter();
+ }
+ eventHandler.endNonterminal("FTSelection", e0);
+ }
+
+ function try_FTSelection()
+ {
+ try_FTOr();
+ for (;;)
+ {
+ lookahead1W(211); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(161); // S^WS | '(:' | 'end' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 116 // 'different'
+ && lk != 118 // 'distance'
+ && lk != 128 // 'entire'
+ && lk != 206 // 'ordered'
+ && lk != 227 // 'same'
+ && lk != 275 // 'window'
+ && lk != 65106 // 'at' 'end'
+ && lk != 123986) // 'at' 'start'
+ {
+ break;
+ }
+ try_FTPosFilter();
+ }
+ }
+
+ function parse_FTWeight()
+ {
+ eventHandler.startNonterminal("FTWeight", e0);
+ shift(270); // 'weight'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("FTWeight", e0);
+ }
+
+ function try_FTWeight()
+ {
+ shiftT(270); // 'weight'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+
+ function parse_FTOr()
+ {
+ eventHandler.startNonterminal("FTOr", e0);
+ parse_FTAnd();
+ for (;;)
+ {
+ if (l1 != 146) // 'ftor'
+ {
+ break;
+ }
+ shift(146); // 'ftor'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTAnd();
+ }
+ eventHandler.endNonterminal("FTOr", e0);
+ }
+
+ function try_FTOr()
+ {
+ try_FTAnd();
+ for (;;)
+ {
+ if (l1 != 146) // 'ftor'
+ {
+ break;
+ }
+ shiftT(146); // 'ftor'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTAnd();
+ }
+ }
+
+ function parse_FTAnd()
+ {
+ eventHandler.startNonterminal("FTAnd", e0);
+ parse_FTMildNot();
+ for (;;)
+ {
+ if (l1 != 144) // 'ftand'
+ {
+ break;
+ }
+ shift(144); // 'ftand'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTMildNot();
+ }
+ eventHandler.endNonterminal("FTAnd", e0);
+ }
+
+ function try_FTAnd()
+ {
+ try_FTMildNot();
+ for (;;)
+ {
+ if (l1 != 144) // 'ftand'
+ {
+ break;
+ }
+ shiftT(144); // 'ftand'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTMildNot();
+ }
+ }
+
+ function parse_FTMildNot()
+ {
+ eventHandler.startNonterminal("FTMildNot", e0);
+ parse_FTUnaryNot();
+ for (;;)
+ {
+ lookahead1W(212); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 196) // 'not'
+ {
+ break;
+ }
+ shift(196); // 'not'
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shift(156); // 'in'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTUnaryNot();
+ }
+ eventHandler.endNonterminal("FTMildNot", e0);
+ }
+
+ function try_FTMildNot()
+ {
+ try_FTUnaryNot();
+ for (;;)
+ {
+ lookahead1W(212); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 196) // 'not'
+ {
+ break;
+ }
+ shiftT(196); // 'not'
+ lookahead1W(56); // S^WS | '(:' | 'in'
+ shiftT(156); // 'in'
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTUnaryNot();
+ }
+ }
+
+ function parse_FTUnaryNot()
+ {
+ eventHandler.startNonterminal("FTUnaryNot", e0);
+ if (l1 == 145) // 'ftnot'
+ {
+ shift(145); // 'ftnot'
+ }
+ lookahead1W(164); // StringLiteral | S^WS | '(' | '(#' | '(:' | '{'
+ whitespace();
+ parse_FTPrimaryWithOptions();
+ eventHandler.endNonterminal("FTUnaryNot", e0);
+ }
+
+ function try_FTUnaryNot()
+ {
+ if (l1 == 145) // 'ftnot'
+ {
+ shiftT(145); // 'ftnot'
+ }
+ lookahead1W(164); // StringLiteral | S^WS | '(' | '(#' | '(:' | '{'
+ try_FTPrimaryWithOptions();
+ }
+
+ function parse_FTPrimaryWithOptions()
+ {
+ eventHandler.startNonterminal("FTPrimaryWithOptions", e0);
+ parse_FTPrimary();
+ lookahead1W(213); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 265) // 'using'
+ {
+ whitespace();
+ parse_FTMatchOptions();
+ }
+ if (l1 == 270) // 'weight'
+ {
+ whitespace();
+ parse_FTWeight();
+ }
+ eventHandler.endNonterminal("FTPrimaryWithOptions", e0);
+ }
+
+ function try_FTPrimaryWithOptions()
+ {
+ try_FTPrimary();
+ lookahead1W(213); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 265) // 'using'
+ {
+ try_FTMatchOptions();
+ }
+ if (l1 == 270) // 'weight'
+ {
+ try_FTWeight();
+ }
+ }
+
+ function parse_FTPrimary()
+ {
+ eventHandler.startNonterminal("FTPrimary", e0);
+ switch (l1)
+ {
+ case 35: // '('
+ shift(35); // '('
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTSelection();
+ shift(38); // ')'
+ break;
+ case 36: // '(#'
+ parse_FTExtensionSelection();
+ break;
+ default:
+ parse_FTWords();
+ lookahead1W(214); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 199) // 'occurs'
+ {
+ whitespace();
+ parse_FTTimes();
+ }
+ }
+ eventHandler.endNonterminal("FTPrimary", e0);
+ }
+
+ function try_FTPrimary()
+ {
+ switch (l1)
+ {
+ case 35: // '('
+ shiftT(35); // '('
+ lookahead1W(177); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTSelection();
+ shiftT(38); // ')'
+ break;
+ case 36: // '(#'
+ try_FTExtensionSelection();
+ break;
+ default:
+ try_FTWords();
+ lookahead1W(214); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 199) // 'occurs'
+ {
+ try_FTTimes();
+ }
+ }
+ }
+
+ function parse_FTWords()
+ {
+ eventHandler.startNonterminal("FTWords", e0);
+ parse_FTWordsValue();
+ lookahead1W(220); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 72 // 'all'
+ || l1 == 77 // 'any'
+ || l1 == 214) // 'phrase'
+ {
+ whitespace();
+ parse_FTAnyallOption();
+ }
+ eventHandler.endNonterminal("FTWords", e0);
+ }
+
+ function try_FTWords()
+ {
+ try_FTWordsValue();
+ lookahead1W(220); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 72 // 'all'
+ || l1 == 77 // 'any'
+ || l1 == 214) // 'phrase'
+ {
+ try_FTAnyallOption();
+ }
+ }
+
+ function parse_FTWordsValue()
+ {
+ eventHandler.startNonterminal("FTWordsValue", e0);
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ default:
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ }
+ eventHandler.endNonterminal("FTWordsValue", e0);
+ }
+
+ function try_FTWordsValue()
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ default:
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ }
+ }
+
+ function parse_FTExtensionSelection()
+ {
+ eventHandler.startNonterminal("FTExtensionSelection", e0);
+ for (;;)
+ {
+ whitespace();
+ parse_Pragma();
+ lookahead1W(104); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 36) // '(#'
+ {
+ break;
+ }
+ }
+ shift(281); // '{'
+ lookahead1W(184); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{' | '}'
+ if (l1 != 287) // '}'
+ {
+ whitespace();
+ parse_FTSelection();
+ }
+ shift(287); // '}'
+ eventHandler.endNonterminal("FTExtensionSelection", e0);
+ }
+
+ function try_FTExtensionSelection()
+ {
+ for (;;)
+ {
+ try_Pragma();
+ lookahead1W(104); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 36) // '(#'
+ {
+ break;
+ }
+ }
+ shiftT(281); // '{'
+ lookahead1W(184); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{' | '}'
+ if (l1 != 287) // '}'
+ {
+ try_FTSelection();
+ }
+ shiftT(287); // '}'
+ }
+
+ function parse_FTAnyallOption()
+ {
+ eventHandler.startNonterminal("FTAnyallOption", e0);
+ switch (l1)
+ {
+ case 77: // 'any'
+ shift(77); // 'any'
+ lookahead1W(217); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 278) // 'word'
+ {
+ shift(278); // 'word'
+ }
+ break;
+ case 72: // 'all'
+ shift(72); // 'all'
+ lookahead1W(218); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 279) // 'words'
+ {
+ shift(279); // 'words'
+ }
+ break;
+ default:
+ shift(214); // 'phrase'
+ }
+ eventHandler.endNonterminal("FTAnyallOption", e0);
+ }
+
+ function try_FTAnyallOption()
+ {
+ switch (l1)
+ {
+ case 77: // 'any'
+ shiftT(77); // 'any'
+ lookahead1W(217); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 278) // 'word'
+ {
+ shiftT(278); // 'word'
+ }
+ break;
+ case 72: // 'all'
+ shiftT(72); // 'all'
+ lookahead1W(218); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 279) // 'words'
+ {
+ shiftT(279); // 'words'
+ }
+ break;
+ default:
+ shiftT(214); // 'phrase'
+ }
+ }
+
+ function parse_FTTimes()
+ {
+ eventHandler.startNonterminal("FTTimes", e0);
+ shift(199); // 'occurs'
+ lookahead1W(159); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ whitespace();
+ parse_FTRange();
+ shift(252); // 'times'
+ eventHandler.endNonterminal("FTTimes", e0);
+ }
+
+ function try_FTTimes()
+ {
+ shiftT(199); // 'occurs'
+ lookahead1W(159); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ try_FTRange();
+ shiftT(252); // 'times'
+ }
+
+ function parse_FTRange()
+ {
+ eventHandler.startNonterminal("FTRange", e0);
+ switch (l1)
+ {
+ case 131: // 'exactly'
+ shift(131); // 'exactly'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ break;
+ case 82: // 'at'
+ shift(82); // 'at'
+ lookahead1W(129); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 176: // 'least'
+ shift(176); // 'least'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ break;
+ default:
+ shift(186); // 'most'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ }
+ break;
+ default:
+ shift(142); // 'from'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ shift(253); // 'to'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ }
+ eventHandler.endNonterminal("FTRange", e0);
+ }
+
+ function try_FTRange()
+ {
+ switch (l1)
+ {
+ case 131: // 'exactly'
+ shiftT(131); // 'exactly'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ break;
+ case 82: // 'at'
+ shiftT(82); // 'at'
+ lookahead1W(129); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 176: // 'least'
+ shiftT(176); // 'least'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ break;
+ default:
+ shiftT(186); // 'most'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ }
+ break;
+ default:
+ shiftT(142); // 'from'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ shiftT(253); // 'to'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ }
+ }
+
+ function parse_FTPosFilter()
+ {
+ eventHandler.startNonterminal("FTPosFilter", e0);
+ switch (l1)
+ {
+ case 206: // 'ordered'
+ parse_FTOrder();
+ break;
+ case 275: // 'window'
+ parse_FTWindow();
+ break;
+ case 118: // 'distance'
+ parse_FTDistance();
+ break;
+ case 116: // 'different'
+ case 227: // 'same'
+ parse_FTScope();
+ break;
+ default:
+ parse_FTContent();
+ }
+ eventHandler.endNonterminal("FTPosFilter", e0);
+ }
+
+ function try_FTPosFilter()
+ {
+ switch (l1)
+ {
+ case 206: // 'ordered'
+ try_FTOrder();
+ break;
+ case 275: // 'window'
+ try_FTWindow();
+ break;
+ case 118: // 'distance'
+ try_FTDistance();
+ break;
+ case 116: // 'different'
+ case 227: // 'same'
+ try_FTScope();
+ break;
+ default:
+ try_FTContent();
+ }
+ }
+
+ function parse_FTOrder()
+ {
+ eventHandler.startNonterminal("FTOrder", e0);
+ shift(206); // 'ordered'
+ eventHandler.endNonterminal("FTOrder", e0);
+ }
+
+ function try_FTOrder()
+ {
+ shiftT(206); // 'ordered'
+ }
+
+ function parse_FTWindow()
+ {
+ eventHandler.startNonterminal("FTWindow", e0);
+ shift(275); // 'window'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ whitespace();
+ parse_FTUnit();
+ eventHandler.endNonterminal("FTWindow", e0);
+ }
+
+ function try_FTWindow()
+ {
+ shiftT(275); // 'window'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_AdditiveExpr();
+ try_FTUnit();
+ }
+
+ function parse_FTDistance()
+ {
+ eventHandler.startNonterminal("FTDistance", e0);
+ shift(118); // 'distance'
+ lookahead1W(159); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ whitespace();
+ parse_FTRange();
+ whitespace();
+ parse_FTUnit();
+ eventHandler.endNonterminal("FTDistance", e0);
+ }
+
+ function try_FTDistance()
+ {
+ shiftT(118); // 'distance'
+ lookahead1W(159); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ try_FTRange();
+ try_FTUnit();
+ }
+
+ function parse_FTUnit()
+ {
+ eventHandler.startNonterminal("FTUnit", e0);
+ switch (l1)
+ {
+ case 279: // 'words'
+ shift(279); // 'words'
+ break;
+ case 237: // 'sentences'
+ shift(237); // 'sentences'
+ break;
+ default:
+ shift(209); // 'paragraphs'
+ }
+ eventHandler.endNonterminal("FTUnit", e0);
+ }
+
+ function try_FTUnit()
+ {
+ switch (l1)
+ {
+ case 279: // 'words'
+ shiftT(279); // 'words'
+ break;
+ case 237: // 'sentences'
+ shiftT(237); // 'sentences'
+ break;
+ default:
+ shiftT(209); // 'paragraphs'
+ }
+ }
+
+ function parse_FTScope()
+ {
+ eventHandler.startNonterminal("FTScope", e0);
+ switch (l1)
+ {
+ case 227: // 'same'
+ shift(227); // 'same'
+ break;
+ default:
+ shift(116); // 'different'
+ }
+ lookahead1W(136); // S^WS | '(:' | 'paragraph' | 'sentence'
+ whitespace();
+ parse_FTBigUnit();
+ eventHandler.endNonterminal("FTScope", e0);
+ }
+
+ function try_FTScope()
+ {
+ switch (l1)
+ {
+ case 227: // 'same'
+ shiftT(227); // 'same'
+ break;
+ default:
+ shiftT(116); // 'different'
+ }
+ lookahead1W(136); // S^WS | '(:' | 'paragraph' | 'sentence'
+ try_FTBigUnit();
+ }
+
+ function parse_FTBigUnit()
+ {
+ eventHandler.startNonterminal("FTBigUnit", e0);
+ switch (l1)
+ {
+ case 236: // 'sentence'
+ shift(236); // 'sentence'
+ break;
+ default:
+ shift(208); // 'paragraph'
+ }
+ eventHandler.endNonterminal("FTBigUnit", e0);
+ }
+
+ function try_FTBigUnit()
+ {
+ switch (l1)
+ {
+ case 236: // 'sentence'
+ shiftT(236); // 'sentence'
+ break;
+ default:
+ shiftT(208); // 'paragraph'
+ }
+ }
+
+ function parse_FTContent()
+ {
+ eventHandler.startNonterminal("FTContent", e0);
+ switch (l1)
+ {
+ case 82: // 'at'
+ shift(82); // 'at'
+ lookahead1W(121); // S^WS | '(:' | 'end' | 'start'
+ switch (l1)
+ {
+ case 242: // 'start'
+ shift(242); // 'start'
+ break;
+ default:
+ shift(127); // 'end'
+ }
+ break;
+ default:
+ shift(128); // 'entire'
+ lookahead1W(45); // S^WS | '(:' | 'content'
+ shift(101); // 'content'
+ }
+ eventHandler.endNonterminal("FTContent", e0);
+ }
+
+ function try_FTContent()
+ {
+ switch (l1)
+ {
+ case 82: // 'at'
+ shiftT(82); // 'at'
+ lookahead1W(121); // S^WS | '(:' | 'end' | 'start'
+ switch (l1)
+ {
+ case 242: // 'start'
+ shiftT(242); // 'start'
+ break;
+ default:
+ shiftT(127); // 'end'
+ }
+ break;
+ default:
+ shiftT(128); // 'entire'
+ lookahead1W(45); // S^WS | '(:' | 'content'
+ shiftT(101); // 'content'
+ }
+ }
+
+ function parse_FTMatchOptions()
+ {
+ eventHandler.startNonterminal("FTMatchOptions", e0);
+ for (;;)
+ {
+ shift(265); // 'using'
+ lookahead1W(204); // S^WS | '(:' | 'case' | 'diacritics' | 'language' | 'lowercase' | 'no' |
+ whitespace();
+ parse_FTMatchOption();
+ lookahead1W(213); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 265) // 'using'
+ {
+ break;
+ }
+ }
+ eventHandler.endNonterminal("FTMatchOptions", e0);
+ }
+
+ function try_FTMatchOptions()
+ {
+ for (;;)
+ {
+ shiftT(265); // 'using'
+ lookahead1W(204); // S^WS | '(:' | 'case' | 'diacritics' | 'language' | 'lowercase' | 'no' |
+ try_FTMatchOption();
+ lookahead1W(213); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 265) // 'using'
+ {
+ break;
+ }
+ }
+ }
+
+ function parse_FTMatchOption()
+ {
+ eventHandler.startNonterminal("FTMatchOption", e0);
+ switch (l1)
+ {
+ case 191: // 'no'
+ lookahead2W(176); // S^WS | '(:' | 'stemming' | 'stop' | 'thesaurus' | 'wildcards'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 172: // 'language'
+ parse_FTLanguageOption();
+ break;
+ case 274: // 'wildcards'
+ case 140479: // 'no' 'wildcards'
+ parse_FTWildCardOption();
+ break;
+ case 251: // 'thesaurus'
+ case 128703: // 'no' 'thesaurus'
+ parse_FTThesaurusOption();
+ break;
+ case 243: // 'stemming'
+ case 124607: // 'no' 'stemming'
+ parse_FTStemOption();
+ break;
+ case 115: // 'diacritics'
+ parse_FTDiacriticsOption();
+ break;
+ case 244: // 'stop'
+ case 125119: // 'no' 'stop'
+ parse_FTStopWordOption();
+ break;
+ case 203: // 'option'
+ parse_FTExtensionOption();
+ break;
+ default:
+ parse_FTCaseOption();
+ }
+ eventHandler.endNonterminal("FTMatchOption", e0);
+ }
+
+ function try_FTMatchOption()
+ {
+ switch (l1)
+ {
+ case 191: // 'no'
+ lookahead2W(176); // S^WS | '(:' | 'stemming' | 'stop' | 'thesaurus' | 'wildcards'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 172: // 'language'
+ try_FTLanguageOption();
+ break;
+ case 274: // 'wildcards'
+ case 140479: // 'no' 'wildcards'
+ try_FTWildCardOption();
+ break;
+ case 251: // 'thesaurus'
+ case 128703: // 'no' 'thesaurus'
+ try_FTThesaurusOption();
+ break;
+ case 243: // 'stemming'
+ case 124607: // 'no' 'stemming'
+ try_FTStemOption();
+ break;
+ case 115: // 'diacritics'
+ try_FTDiacriticsOption();
+ break;
+ case 244: // 'stop'
+ case 125119: // 'no' 'stop'
+ try_FTStopWordOption();
+ break;
+ case 203: // 'option'
+ try_FTExtensionOption();
+ break;
+ default:
+ try_FTCaseOption();
+ }
+ }
+
+ function parse_FTCaseOption()
+ {
+ eventHandler.startNonterminal("FTCaseOption", e0);
+ switch (l1)
+ {
+ case 89: // 'case'
+ shift(89); // 'case'
+ lookahead1W(128); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 160: // 'insensitive'
+ shift(160); // 'insensitive'
+ break;
+ default:
+ shift(235); // 'sensitive'
+ }
+ break;
+ case 180: // 'lowercase'
+ shift(180); // 'lowercase'
+ break;
+ default:
+ shift(264); // 'uppercase'
+ }
+ eventHandler.endNonterminal("FTCaseOption", e0);
+ }
+
+ function try_FTCaseOption()
+ {
+ switch (l1)
+ {
+ case 89: // 'case'
+ shiftT(89); // 'case'
+ lookahead1W(128); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 160: // 'insensitive'
+ shiftT(160); // 'insensitive'
+ break;
+ default:
+ shiftT(235); // 'sensitive'
+ }
+ break;
+ case 180: // 'lowercase'
+ shiftT(180); // 'lowercase'
+ break;
+ default:
+ shiftT(264); // 'uppercase'
+ }
+ }
+
+ function parse_FTDiacriticsOption()
+ {
+ eventHandler.startNonterminal("FTDiacriticsOption", e0);
+ shift(115); // 'diacritics'
+ lookahead1W(128); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 160: // 'insensitive'
+ shift(160); // 'insensitive'
+ break;
+ default:
+ shift(235); // 'sensitive'
+ }
+ eventHandler.endNonterminal("FTDiacriticsOption", e0);
+ }
+
+ function try_FTDiacriticsOption()
+ {
+ shiftT(115); // 'diacritics'
+ lookahead1W(128); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 160: // 'insensitive'
+ shiftT(160); // 'insensitive'
+ break;
+ default:
+ shiftT(235); // 'sensitive'
+ }
+ }
+
+ function parse_FTStemOption()
+ {
+ eventHandler.startNonterminal("FTStemOption", e0);
+ switch (l1)
+ {
+ case 243: // 'stemming'
+ shift(243); // 'stemming'
+ break;
+ default:
+ shift(191); // 'no'
+ lookahead1W(77); // S^WS | '(:' | 'stemming'
+ shift(243); // 'stemming'
+ }
+ eventHandler.endNonterminal("FTStemOption", e0);
+ }
+
+ function try_FTStemOption()
+ {
+ switch (l1)
+ {
+ case 243: // 'stemming'
+ shiftT(243); // 'stemming'
+ break;
+ default:
+ shiftT(191); // 'no'
+ lookahead1W(77); // S^WS | '(:' | 'stemming'
+ shiftT(243); // 'stemming'
+ }
+ }
+
+ function parse_FTThesaurusOption()
+ {
+ eventHandler.startNonterminal("FTThesaurusOption", e0);
+ switch (l1)
+ {
+ case 251: // 'thesaurus'
+ shift(251); // 'thesaurus'
+ lookahead1W(152); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 82: // 'at'
+ whitespace();
+ parse_FTThesaurusID();
+ break;
+ case 110: // 'default'
+ shift(110); // 'default'
+ break;
+ default:
+ shift(35); // '('
+ lookahead1W(116); // S^WS | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 82: // 'at'
+ whitespace();
+ parse_FTThesaurusID();
+ break;
+ default:
+ shift(110); // 'default'
+ }
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(34); // S^WS | '(:' | 'at'
+ whitespace();
+ parse_FTThesaurusID();
+ }
+ shift(38); // ')'
+ }
+ break;
+ default:
+ shift(191); // 'no'
+ lookahead1W(81); // S^WS | '(:' | 'thesaurus'
+ shift(251); // 'thesaurus'
+ }
+ eventHandler.endNonterminal("FTThesaurusOption", e0);
+ }
+
+ function try_FTThesaurusOption()
+ {
+ switch (l1)
+ {
+ case 251: // 'thesaurus'
+ shiftT(251); // 'thesaurus'
+ lookahead1W(152); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 82: // 'at'
+ try_FTThesaurusID();
+ break;
+ case 110: // 'default'
+ shiftT(110); // 'default'
+ break;
+ default:
+ shiftT(35); // '('
+ lookahead1W(116); // S^WS | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 82: // 'at'
+ try_FTThesaurusID();
+ break;
+ default:
+ shiftT(110); // 'default'
+ }
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(34); // S^WS | '(:' | 'at'
+ try_FTThesaurusID();
+ }
+ shiftT(38); // ')'
+ }
+ break;
+ default:
+ shiftT(191); // 'no'
+ lookahead1W(81); // S^WS | '(:' | 'thesaurus'
+ shiftT(251); // 'thesaurus'
+ }
+ }
+
+ function parse_FTThesaurusID()
+ {
+ eventHandler.startNonterminal("FTThesaurusID", e0);
+ shift(82); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(219); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 221) // 'relationship'
+ {
+ shift(221); // 'relationship'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ lookahead1W(215); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(183); // S^WS | '(:' | 'end' | 'least' | 'most' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 131 // 'exactly'
+ || lk == 142 // 'from'
+ || lk == 90194 // 'at' 'least'
+ || lk == 95314) // 'at' 'most'
+ {
+ whitespace();
+ parse_FTLiteralRange();
+ lookahead1W(61); // S^WS | '(:' | 'levels'
+ shift(178); // 'levels'
+ }
+ eventHandler.endNonterminal("FTThesaurusID", e0);
+ }
+
+ function try_FTThesaurusID()
+ {
+ shiftT(82); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ lookahead1W(219); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 221) // 'relationship'
+ {
+ shiftT(221); // 'relationship'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+ lookahead1W(215); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(183); // S^WS | '(:' | 'end' | 'least' | 'most' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 131 // 'exactly'
+ || lk == 142 // 'from'
+ || lk == 90194 // 'at' 'least'
+ || lk == 95314) // 'at' 'most'
+ {
+ try_FTLiteralRange();
+ lookahead1W(61); // S^WS | '(:' | 'levels'
+ shiftT(178); // 'levels'
+ }
+ }
+
+ function parse_FTLiteralRange()
+ {
+ eventHandler.startNonterminal("FTLiteralRange", e0);
+ switch (l1)
+ {
+ case 131: // 'exactly'
+ shift(131); // 'exactly'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ break;
+ case 82: // 'at'
+ shift(82); // 'at'
+ lookahead1W(129); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 176: // 'least'
+ shift(176); // 'least'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ break;
+ default:
+ shift(186); // 'most'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ }
+ break;
+ default:
+ shift(142); // 'from'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ lookahead1W(82); // S^WS | '(:' | 'to'
+ shift(253); // 'to'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ }
+ eventHandler.endNonterminal("FTLiteralRange", e0);
+ }
+
+ function try_FTLiteralRange()
+ {
+ switch (l1)
+ {
+ case 131: // 'exactly'
+ shiftT(131); // 'exactly'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ break;
+ case 82: // 'at'
+ shiftT(82); // 'at'
+ lookahead1W(129); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 176: // 'least'
+ shiftT(176); // 'least'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ break;
+ default:
+ shiftT(186); // 'most'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ }
+ break;
+ default:
+ shiftT(142); // 'from'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ lookahead1W(82); // S^WS | '(:' | 'to'
+ shiftT(253); // 'to'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ }
+ }
+
+ function parse_FTStopWordOption()
+ {
+ eventHandler.startNonterminal("FTStopWordOption", e0);
+ switch (l1)
+ {
+ case 244: // 'stop'
+ shift(244); // 'stop'
+ lookahead1W(89); // S^WS | '(:' | 'words'
+ shift(279); // 'words'
+ lookahead1W(152); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 110: // 'default'
+ shift(110); // 'default'
+ for (;;)
+ {
+ lookahead1W(216); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 132 // 'except'
+ && l1 != 260) // 'union'
+ {
+ break;
+ }
+ whitespace();
+ parse_FTStopWordsInclExcl();
+ }
+ break;
+ default:
+ whitespace();
+ parse_FTStopWords();
+ for (;;)
+ {
+ lookahead1W(216); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 132 // 'except'
+ && l1 != 260) // 'union'
+ {
+ break;
+ }
+ whitespace();
+ parse_FTStopWordsInclExcl();
+ }
+ }
+ break;
+ default:
+ shift(191); // 'no'
+ lookahead1W(78); // S^WS | '(:' | 'stop'
+ shift(244); // 'stop'
+ lookahead1W(89); // S^WS | '(:' | 'words'
+ shift(279); // 'words'
+ }
+ eventHandler.endNonterminal("FTStopWordOption", e0);
+ }
+
+ function try_FTStopWordOption()
+ {
+ switch (l1)
+ {
+ case 244: // 'stop'
+ shiftT(244); // 'stop'
+ lookahead1W(89); // S^WS | '(:' | 'words'
+ shiftT(279); // 'words'
+ lookahead1W(152); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 110: // 'default'
+ shiftT(110); // 'default'
+ for (;;)
+ {
+ lookahead1W(216); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 132 // 'except'
+ && l1 != 260) // 'union'
+ {
+ break;
+ }
+ try_FTStopWordsInclExcl();
+ }
+ break;
+ default:
+ try_FTStopWords();
+ for (;;)
+ {
+ lookahead1W(216); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 132 // 'except'
+ && l1 != 260) // 'union'
+ {
+ break;
+ }
+ try_FTStopWordsInclExcl();
+ }
+ }
+ break;
+ default:
+ shiftT(191); // 'no'
+ lookahead1W(78); // S^WS | '(:' | 'stop'
+ shiftT(244); // 'stop'
+ lookahead1W(89); // S^WS | '(:' | 'words'
+ shiftT(279); // 'words'
+ }
+ }
+
+ function parse_FTStopWords()
+ {
+ eventHandler.startNonterminal("FTStopWords", e0);
+ switch (l1)
+ {
+ case 82: // 'at'
+ shift(82); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ break;
+ default:
+ shift(35); // '('
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ shift(38); // ')'
+ }
+ eventHandler.endNonterminal("FTStopWords", e0);
+ }
+
+ function try_FTStopWords()
+ {
+ switch (l1)
+ {
+ case 82: // 'at'
+ shiftT(82); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ break;
+ default:
+ shiftT(35); // '('
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ for (;;)
+ {
+ lookahead1W(105); // S^WS | '(:' | ')' | ','
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+ shiftT(38); // ')'
+ }
+ }
+
+ function parse_FTStopWordsInclExcl()
+ {
+ eventHandler.startNonterminal("FTStopWordsInclExcl", e0);
+ switch (l1)
+ {
+ case 260: // 'union'
+ shift(260); // 'union'
+ break;
+ default:
+ shift(132); // 'except'
+ }
+ lookahead1W(103); // S^WS | '(' | '(:' | 'at'
+ whitespace();
+ parse_FTStopWords();
+ eventHandler.endNonterminal("FTStopWordsInclExcl", e0);
+ }
+
+ function try_FTStopWordsInclExcl()
+ {
+ switch (l1)
+ {
+ case 260: // 'union'
+ shiftT(260); // 'union'
+ break;
+ default:
+ shiftT(132); // 'except'
+ }
+ lookahead1W(103); // S^WS | '(' | '(:' | 'at'
+ try_FTStopWords();
+ }
+
+ function parse_FTLanguageOption()
+ {
+ eventHandler.startNonterminal("FTLanguageOption", e0);
+ shift(172); // 'language'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ eventHandler.endNonterminal("FTLanguageOption", e0);
+ }
+
+ function try_FTLanguageOption()
+ {
+ shiftT(172); // 'language'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+
+ function parse_FTWildCardOption()
+ {
+ eventHandler.startNonterminal("FTWildCardOption", e0);
+ switch (l1)
+ {
+ case 274: // 'wildcards'
+ shift(274); // 'wildcards'
+ break;
+ default:
+ shift(191); // 'no'
+ lookahead1W(87); // S^WS | '(:' | 'wildcards'
+ shift(274); // 'wildcards'
+ }
+ eventHandler.endNonterminal("FTWildCardOption", e0);
+ }
+
+ function try_FTWildCardOption()
+ {
+ switch (l1)
+ {
+ case 274: // 'wildcards'
+ shiftT(274); // 'wildcards'
+ break;
+ default:
+ shiftT(191); // 'no'
+ lookahead1W(87); // S^WS | '(:' | 'wildcards'
+ shiftT(274); // 'wildcards'
+ }
+ }
+
+ function parse_FTExtensionOption()
+ {
+ eventHandler.startNonterminal("FTExtensionOption", e0);
+ shift(203); // 'option'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ eventHandler.endNonterminal("FTExtensionOption", e0);
+ }
+
+ function try_FTExtensionOption()
+ {
+ shiftT(203); // 'option'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_EQName();
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+
+ function parse_FTIgnoreOption()
+ {
+ eventHandler.startNonterminal("FTIgnoreOption", e0);
+ shift(277); // 'without'
+ lookahead1W(45); // S^WS | '(:' | 'content'
+ shift(101); // 'content'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_UnionExpr();
+ eventHandler.endNonterminal("FTIgnoreOption", e0);
+ }
+
+ function try_FTIgnoreOption()
+ {
+ shiftT(277); // 'without'
+ lookahead1W(45); // S^WS | '(:' | 'content'
+ shiftT(101); // 'content'
+ lookahead1W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_UnionExpr();
+ }
+
+ function parse_CollectionDecl()
+ {
+ eventHandler.startNonterminal("CollectionDecl", e0);
+ shift(96); // 'collection'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(111); // S^WS | '(:' | ';' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_CollectionTypeDecl();
+ }
+ eventHandler.endNonterminal("CollectionDecl", e0);
+ }
+
+ function parse_CollectionTypeDecl()
+ {
+ eventHandler.startNonterminal("CollectionTypeDecl", e0);
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ItemType();
+ lookahead1W(171); // S^WS | '(:' | '*' | '+' | ';' | '?'
+ if (l1 != 54) // ';'
+ {
+ whitespace();
+ parse_OccurrenceIndicator();
+ }
+ eventHandler.endNonterminal("CollectionTypeDecl", e0);
+ }
+
+ function parse_IndexName()
+ {
+ eventHandler.startNonterminal("IndexName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("IndexName", e0);
+ }
+
+ function parse_IndexDomainExpr()
+ {
+ eventHandler.startNonterminal("IndexDomainExpr", e0);
+ parse_PathExpr();
+ eventHandler.endNonterminal("IndexDomainExpr", e0);
+ }
+
+ function parse_IndexKeySpec()
+ {
+ eventHandler.startNonterminal("IndexKeySpec", e0);
+ parse_IndexKeyExpr();
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_IndexKeyTypeDecl();
+ }
+ lookahead1W(156); // S^WS | '(:' | ',' | ';' | 'collation'
+ if (l1 == 95) // 'collation'
+ {
+ whitespace();
+ parse_IndexKeyCollation();
+ }
+ eventHandler.endNonterminal("IndexKeySpec", e0);
+ }
+
+ function parse_IndexKeyExpr()
+ {
+ eventHandler.startNonterminal("IndexKeyExpr", e0);
+ parse_PathExpr();
+ eventHandler.endNonterminal("IndexKeyExpr", e0);
+ }
+
+ function parse_IndexKeyTypeDecl()
+ {
+ eventHandler.startNonterminal("IndexKeyTypeDecl", e0);
+ shift(80); // 'as'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_AtomicType();
+ lookahead1W(189); // S^WS | '(:' | '*' | '+' | ',' | ';' | '?' | 'collation'
+ if (l1 == 40 // '*'
+ || l1 == 41 // '+'
+ || l1 == 65) // '?'
+ {
+ whitespace();
+ parse_OccurrenceIndicator();
+ }
+ eventHandler.endNonterminal("IndexKeyTypeDecl", e0);
+ }
+
+ function parse_AtomicType()
+ {
+ eventHandler.startNonterminal("AtomicType", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("AtomicType", e0);
+ }
+
+ function parse_IndexKeyCollation()
+ {
+ eventHandler.startNonterminal("IndexKeyCollation", e0);
+ shift(95); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("IndexKeyCollation", e0);
+ }
+
+ function parse_IndexDecl()
+ {
+ eventHandler.startNonterminal("IndexDecl", e0);
+ shift(157); // 'index'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_IndexName();
+ lookahead1W(68); // S^WS | '(:' | 'on'
+ shift(201); // 'on'
+ lookahead1W(66); // S^WS | '(:' | 'nodes'
+ shift(195); // 'nodes'
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_IndexDomainExpr();
+ shift(88); // 'by'
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_IndexKeySpec();
+ for (;;)
+ {
+ lookahead1W(107); // S^WS | '(:' | ',' | ';'
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_IndexKeySpec();
+ }
+ eventHandler.endNonterminal("IndexDecl", e0);
+ }
+
+ function parse_ICDecl()
+ {
+ eventHandler.startNonterminal("ICDecl", e0);
+ shift(163); // 'integrity'
+ lookahead1W(43); // S^WS | '(:' | 'constraint'
+ shift(98); // 'constraint'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(124); // S^WS | '(:' | 'foreign' | 'on'
+ switch (l1)
+ {
+ case 201: // 'on'
+ whitespace();
+ parse_ICCollection();
+ break;
+ default:
+ whitespace();
+ parse_ICForeignKey();
+ }
+ eventHandler.endNonterminal("ICDecl", e0);
+ }
+
+ function parse_ICCollection()
+ {
+ eventHandler.startNonterminal("ICCollection", e0);
+ shift(201); // 'on'
+ lookahead1W(42); // S^WS | '(:' | 'collection'
+ shift(96); // 'collection'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(150); // S^WS | '$' | '(:' | 'foreach' | 'node'
+ switch (l1)
+ {
+ case 31: // '$'
+ whitespace();
+ parse_ICCollSequence();
+ break;
+ case 194: // 'node'
+ whitespace();
+ parse_ICCollSequenceUnique();
+ break;
+ default:
+ whitespace();
+ parse_ICCollNode();
+ }
+ eventHandler.endNonterminal("ICCollection", e0);
+ }
+
+ function parse_ICCollSequence()
+ {
+ eventHandler.startNonterminal("ICCollSequence", e0);
+ parse_VarRef();
+ lookahead1W(40); // S^WS | '(:' | 'check'
+ shift(93); // 'check'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ICCollSequence", e0);
+ }
+
+ function parse_ICCollSequenceUnique()
+ {
+ eventHandler.startNonterminal("ICCollSequenceUnique", e0);
+ shift(194); // 'node'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_VarRef();
+ lookahead1W(40); // S^WS | '(:' | 'check'
+ shift(93); // 'check'
+ lookahead1W(83); // S^WS | '(:' | 'unique'
+ shift(261); // 'unique'
+ lookahead1W(60); // S^WS | '(:' | 'key'
+ shift(171); // 'key'
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PathExpr();
+ eventHandler.endNonterminal("ICCollSequenceUnique", e0);
+ }
+
+ function parse_ICCollNode()
+ {
+ eventHandler.startNonterminal("ICCollNode", e0);
+ shift(140); // 'foreach'
+ lookahead1W(65); // S^WS | '(:' | 'node'
+ shift(194); // 'node'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_VarRef();
+ lookahead1W(40); // S^WS | '(:' | 'check'
+ shift(93); // 'check'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ICCollNode", e0);
+ }
+
+ function parse_ICForeignKey()
+ {
+ eventHandler.startNonterminal("ICForeignKey", e0);
+ shift(141); // 'foreign'
+ lookahead1W(60); // S^WS | '(:' | 'key'
+ shift(171); // 'key'
+ lookahead1W(54); // S^WS | '(:' | 'from'
+ whitespace();
+ parse_ICForeignKeySource();
+ whitespace();
+ parse_ICForeignKeyTarget();
+ eventHandler.endNonterminal("ICForeignKey", e0);
+ }
+
+ function parse_ICForeignKeySource()
+ {
+ eventHandler.startNonterminal("ICForeignKeySource", e0);
+ shift(142); // 'from'
+ lookahead1W(42); // S^WS | '(:' | 'collection'
+ whitespace();
+ parse_ICForeignKeyValues();
+ eventHandler.endNonterminal("ICForeignKeySource", e0);
+ }
+
+ function parse_ICForeignKeyTarget()
+ {
+ eventHandler.startNonterminal("ICForeignKeyTarget", e0);
+ shift(253); // 'to'
+ lookahead1W(42); // S^WS | '(:' | 'collection'
+ whitespace();
+ parse_ICForeignKeyValues();
+ eventHandler.endNonterminal("ICForeignKeyTarget", e0);
+ }
+
+ function parse_ICForeignKeyValues()
+ {
+ eventHandler.startNonterminal("ICForeignKeyValues", e0);
+ shift(96); // 'collection'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(65); // S^WS | '(:' | 'node'
+ shift(194); // 'node'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_VarRef();
+ lookahead1W(60); // S^WS | '(:' | 'key'
+ shift(171); // 'key'
+ lookahead1W(262); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PathExpr();
+ eventHandler.endNonterminal("ICForeignKeyValues", e0);
+ }
+
+ function try_Comment()
+ {
+ shiftT(37); // '(:'
+ for (;;)
+ {
+ lookahead1(92); // CommentContents | '(:' | ':)'
+ if (l1 == 51) // ':)'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 24: // CommentContents
+ shiftT(24); // CommentContents
+ break;
+ default:
+ try_Comment();
+ }
+ }
+ shiftT(51); // ':)'
+ }
+
+ function try_Whitespace()
+ {
+ switch (l1)
+ {
+ case 22: // S^WS
+ shiftT(22); // S^WS
+ break;
+ default:
+ try_Comment();
+ }
+ }
+
+ function parse_EQName()
+ {
+ eventHandler.startNonterminal("EQName", e0);
+ lookahead1(240); // EQName^Token | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' | 'and' |
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ shift(83); // 'attribute'
+ break;
+ case 97: // 'comment'
+ shift(97); // 'comment'
+ break;
+ case 121: // 'document-node'
+ shift(121); // 'document-node'
+ break;
+ case 122: // 'element'
+ shift(122); // 'element'
+ break;
+ case 125: // 'empty-sequence'
+ shift(125); // 'empty-sequence'
+ break;
+ case 147: // 'function'
+ shift(147); // 'function'
+ break;
+ case 154: // 'if'
+ shift(154); // 'if'
+ break;
+ case 167: // 'item'
+ shift(167); // 'item'
+ break;
+ case 188: // 'namespace-node'
+ shift(188); // 'namespace-node'
+ break;
+ case 194: // 'node'
+ shift(194); // 'node'
+ break;
+ case 220: // 'processing-instruction'
+ shift(220); // 'processing-instruction'
+ break;
+ case 230: // 'schema-attribute'
+ shift(230); // 'schema-attribute'
+ break;
+ case 231: // 'schema-element'
+ shift(231); // 'schema-element'
+ break;
+ case 248: // 'switch'
+ shift(248); // 'switch'
+ break;
+ case 249: // 'text'
+ shift(249); // 'text'
+ break;
+ case 259: // 'typeswitch'
+ shift(259); // 'typeswitch'
+ break;
+ case 79: // 'array'
+ shift(79); // 'array'
+ break;
+ case 169: // 'json-item'
+ shift(169); // 'json-item'
+ break;
+ case 247: // 'structured-item'
+ shift(247); // 'structured-item'
+ break;
+ default:
+ parse_FunctionName();
+ }
+ eventHandler.endNonterminal("EQName", e0);
+ }
+
+ function try_EQName()
+ {
+ lookahead1(240); // EQName^Token | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' | 'and' |
+ switch (l1)
+ {
+ case 83: // 'attribute'
+ shiftT(83); // 'attribute'
+ break;
+ case 97: // 'comment'
+ shiftT(97); // 'comment'
+ break;
+ case 121: // 'document-node'
+ shiftT(121); // 'document-node'
+ break;
+ case 122: // 'element'
+ shiftT(122); // 'element'
+ break;
+ case 125: // 'empty-sequence'
+ shiftT(125); // 'empty-sequence'
+ break;
+ case 147: // 'function'
+ shiftT(147); // 'function'
+ break;
+ case 154: // 'if'
+ shiftT(154); // 'if'
+ break;
+ case 167: // 'item'
+ shiftT(167); // 'item'
+ break;
+ case 188: // 'namespace-node'
+ shiftT(188); // 'namespace-node'
+ break;
+ case 194: // 'node'
+ shiftT(194); // 'node'
+ break;
+ case 220: // 'processing-instruction'
+ shiftT(220); // 'processing-instruction'
+ break;
+ case 230: // 'schema-attribute'
+ shiftT(230); // 'schema-attribute'
+ break;
+ case 231: // 'schema-element'
+ shiftT(231); // 'schema-element'
+ break;
+ case 248: // 'switch'
+ shiftT(248); // 'switch'
+ break;
+ case 249: // 'text'
+ shiftT(249); // 'text'
+ break;
+ case 259: // 'typeswitch'
+ shiftT(259); // 'typeswitch'
+ break;
+ case 79: // 'array'
+ shiftT(79); // 'array'
+ break;
+ case 169: // 'json-item'
+ shiftT(169); // 'json-item'
+ break;
+ case 247: // 'structured-item'
+ shiftT(247); // 'structured-item'
+ break;
+ default:
+ try_FunctionName();
+ }
+ }
+
+ function parse_FunctionName()
+ {
+ eventHandler.startNonterminal("FunctionName", e0);
+ switch (l1)
+ {
+ case 6: // EQName^Token
+ shift(6); // EQName^Token
+ break;
+ case 71: // 'after'
+ shift(71); // 'after'
+ break;
+ case 74: // 'ancestor'
+ shift(74); // 'ancestor'
+ break;
+ case 75: // 'ancestor-or-self'
+ shift(75); // 'ancestor-or-self'
+ break;
+ case 76: // 'and'
+ shift(76); // 'and'
+ break;
+ case 80: // 'as'
+ shift(80); // 'as'
+ break;
+ case 81: // 'ascending'
+ shift(81); // 'ascending'
+ break;
+ case 85: // 'before'
+ shift(85); // 'before'
+ break;
+ case 89: // 'case'
+ shift(89); // 'case'
+ break;
+ case 90: // 'cast'
+ shift(90); // 'cast'
+ break;
+ case 91: // 'castable'
+ shift(91); // 'castable'
+ break;
+ case 94: // 'child'
+ shift(94); // 'child'
+ break;
+ case 95: // 'collation'
+ shift(95); // 'collation'
+ break;
+ case 104: // 'copy'
+ shift(104); // 'copy'
+ break;
+ case 106: // 'count'
+ shift(106); // 'count'
+ break;
+ case 109: // 'declare'
+ shift(109); // 'declare'
+ break;
+ case 110: // 'default'
+ shift(110); // 'default'
+ break;
+ case 111: // 'delete'
+ shift(111); // 'delete'
+ break;
+ case 112: // 'descendant'
+ shift(112); // 'descendant'
+ break;
+ case 113: // 'descendant-or-self'
+ shift(113); // 'descendant-or-self'
+ break;
+ case 114: // 'descending'
+ shift(114); // 'descending'
+ break;
+ case 119: // 'div'
+ shift(119); // 'div'
+ break;
+ case 120: // 'document'
+ shift(120); // 'document'
+ break;
+ case 123: // 'else'
+ shift(123); // 'else'
+ break;
+ case 124: // 'empty'
+ shift(124); // 'empty'
+ break;
+ case 127: // 'end'
+ shift(127); // 'end'
+ break;
+ case 129: // 'eq'
+ shift(129); // 'eq'
+ break;
+ case 130: // 'every'
+ shift(130); // 'every'
+ break;
+ case 132: // 'except'
+ shift(132); // 'except'
+ break;
+ case 136: // 'first'
+ shift(136); // 'first'
+ break;
+ case 137: // 'following'
+ shift(137); // 'following'
+ break;
+ case 138: // 'following-sibling'
+ shift(138); // 'following-sibling'
+ break;
+ case 139: // 'for'
+ shift(139); // 'for'
+ break;
+ case 148: // 'ge'
+ shift(148); // 'ge'
+ break;
+ case 150: // 'group'
+ shift(150); // 'group'
+ break;
+ case 152: // 'gt'
+ shift(152); // 'gt'
+ break;
+ case 153: // 'idiv'
+ shift(153); // 'idiv'
+ break;
+ case 155: // 'import'
+ shift(155); // 'import'
+ break;
+ case 161: // 'insert'
+ shift(161); // 'insert'
+ break;
+ case 162: // 'instance'
+ shift(162); // 'instance'
+ break;
+ case 164: // 'intersect'
+ shift(164); // 'intersect'
+ break;
+ case 165: // 'into'
+ shift(165); // 'into'
+ break;
+ case 166: // 'is'
+ shift(166); // 'is'
+ break;
+ case 173: // 'last'
+ shift(173); // 'last'
+ break;
+ case 175: // 'le'
+ shift(175); // 'le'
+ break;
+ case 177: // 'let'
+ shift(177); // 'let'
+ break;
+ case 181: // 'lt'
+ shift(181); // 'lt'
+ break;
+ case 183: // 'mod'
+ shift(183); // 'mod'
+ break;
+ case 184: // 'modify'
+ shift(184); // 'modify'
+ break;
+ case 185: // 'module'
+ shift(185); // 'module'
+ break;
+ case 187: // 'namespace'
+ shift(187); // 'namespace'
+ break;
+ case 189: // 'ne'
+ shift(189); // 'ne'
+ break;
+ case 202: // 'only'
+ shift(202); // 'only'
+ break;
+ case 204: // 'or'
+ shift(204); // 'or'
+ break;
+ case 205: // 'order'
+ shift(205); // 'order'
+ break;
+ case 206: // 'ordered'
+ shift(206); // 'ordered'
+ break;
+ case 210: // 'parent'
+ shift(210); // 'parent'
+ break;
+ case 216: // 'preceding'
+ shift(216); // 'preceding'
+ break;
+ case 217: // 'preceding-sibling'
+ shift(217); // 'preceding-sibling'
+ break;
+ case 222: // 'rename'
+ shift(222); // 'rename'
+ break;
+ case 223: // 'replace'
+ shift(223); // 'replace'
+ break;
+ case 224: // 'return'
+ shift(224); // 'return'
+ break;
+ case 228: // 'satisfies'
+ shift(228); // 'satisfies'
+ break;
+ case 234: // 'self'
+ shift(234); // 'self'
+ break;
+ case 240: // 'some'
+ shift(240); // 'some'
+ break;
+ case 241: // 'stable'
+ shift(241); // 'stable'
+ break;
+ case 242: // 'start'
+ shift(242); // 'start'
+ break;
+ case 253: // 'to'
+ shift(253); // 'to'
+ break;
+ case 254: // 'treat'
+ shift(254); // 'treat'
+ break;
+ case 256: // 'try'
+ shift(256); // 'try'
+ break;
+ case 260: // 'union'
+ shift(260); // 'union'
+ break;
+ case 262: // 'unordered'
+ shift(262); // 'unordered'
+ break;
+ case 266: // 'validate'
+ shift(266); // 'validate'
+ break;
+ case 272: // 'where'
+ shift(272); // 'where'
+ break;
+ case 276: // 'with'
+ shift(276); // 'with'
+ break;
+ case 170: // 'jsoniq'
+ shift(170); // 'jsoniq'
+ break;
+ case 73: // 'allowing'
+ shift(73); // 'allowing'
+ break;
+ case 82: // 'at'
+ shift(82); // 'at'
+ break;
+ case 84: // 'base-uri'
+ shift(84); // 'base-uri'
+ break;
+ case 86: // 'boundary-space'
+ shift(86); // 'boundary-space'
+ break;
+ case 87: // 'break'
+ shift(87); // 'break'
+ break;
+ case 92: // 'catch'
+ shift(92); // 'catch'
+ break;
+ case 99: // 'construction'
+ shift(99); // 'construction'
+ break;
+ case 102: // 'context'
+ shift(102); // 'context'
+ break;
+ case 103: // 'continue'
+ shift(103); // 'continue'
+ break;
+ case 105: // 'copy-namespaces'
+ shift(105); // 'copy-namespaces'
+ break;
+ case 107: // 'decimal-format'
+ shift(107); // 'decimal-format'
+ break;
+ case 126: // 'encoding'
+ shift(126); // 'encoding'
+ break;
+ case 133: // 'exit'
+ shift(133); // 'exit'
+ break;
+ case 134: // 'external'
+ shift(134); // 'external'
+ break;
+ case 143: // 'ft-option'
+ shift(143); // 'ft-option'
+ break;
+ case 156: // 'in'
+ shift(156); // 'in'
+ break;
+ case 157: // 'index'
+ shift(157); // 'index'
+ break;
+ case 163: // 'integrity'
+ shift(163); // 'integrity'
+ break;
+ case 174: // 'lax'
+ shift(174); // 'lax'
+ break;
+ case 195: // 'nodes'
+ shift(195); // 'nodes'
+ break;
+ case 203: // 'option'
+ shift(203); // 'option'
+ break;
+ case 207: // 'ordering'
+ shift(207); // 'ordering'
+ break;
+ case 226: // 'revalidation'
+ shift(226); // 'revalidation'
+ break;
+ case 229: // 'schema'
+ shift(229); // 'schema'
+ break;
+ case 232: // 'score'
+ shift(232); // 'score'
+ break;
+ case 239: // 'sliding'
+ shift(239); // 'sliding'
+ break;
+ case 245: // 'strict'
+ shift(245); // 'strict'
+ break;
+ case 257: // 'tumbling'
+ shift(257); // 'tumbling'
+ break;
+ case 258: // 'type'
+ shift(258); // 'type'
+ break;
+ case 263: // 'updating'
+ shift(263); // 'updating'
+ break;
+ case 267: // 'value'
+ shift(267); // 'value'
+ break;
+ case 268: // 'variable'
+ shift(268); // 'variable'
+ break;
+ case 269: // 'version'
+ shift(269); // 'version'
+ break;
+ case 273: // 'while'
+ shift(273); // 'while'
+ break;
+ case 98: // 'constraint'
+ shift(98); // 'constraint'
+ break;
+ case 179: // 'loop'
+ shift(179); // 'loop'
+ break;
+ case 225: // 'returning'
+ shift(225); // 'returning'
+ break;
+ case 78: // 'append'
+ shift(78); // 'append'
+ break;
+ case 135: // 'false'
+ shift(135); // 'false'
+ break;
+ case 142: // 'from'
+ shift(142); // 'from'
+ break;
+ case 197: // 'null'
+ shift(197); // 'null'
+ break;
+ case 168: // 'json'
+ shift(168); // 'json'
+ break;
+ case 198: // 'object'
+ shift(198); // 'object'
+ break;
+ case 233: // 'select'
+ shift(233); // 'select'
+ break;
+ default:
+ shift(255); // 'true'
+ }
+ eventHandler.endNonterminal("FunctionName", e0);
+ }
+
+ function try_FunctionName()
+ {
+ switch (l1)
+ {
+ case 6: // EQName^Token
+ shiftT(6); // EQName^Token
+ break;
+ case 71: // 'after'
+ shiftT(71); // 'after'
+ break;
+ case 74: // 'ancestor'
+ shiftT(74); // 'ancestor'
+ break;
+ case 75: // 'ancestor-or-self'
+ shiftT(75); // 'ancestor-or-self'
+ break;
+ case 76: // 'and'
+ shiftT(76); // 'and'
+ break;
+ case 80: // 'as'
+ shiftT(80); // 'as'
+ break;
+ case 81: // 'ascending'
+ shiftT(81); // 'ascending'
+ break;
+ case 85: // 'before'
+ shiftT(85); // 'before'
+ break;
+ case 89: // 'case'
+ shiftT(89); // 'case'
+ break;
+ case 90: // 'cast'
+ shiftT(90); // 'cast'
+ break;
+ case 91: // 'castable'
+ shiftT(91); // 'castable'
+ break;
+ case 94: // 'child'
+ shiftT(94); // 'child'
+ break;
+ case 95: // 'collation'
+ shiftT(95); // 'collation'
+ break;
+ case 104: // 'copy'
+ shiftT(104); // 'copy'
+ break;
+ case 106: // 'count'
+ shiftT(106); // 'count'
+ break;
+ case 109: // 'declare'
+ shiftT(109); // 'declare'
+ break;
+ case 110: // 'default'
+ shiftT(110); // 'default'
+ break;
+ case 111: // 'delete'
+ shiftT(111); // 'delete'
+ break;
+ case 112: // 'descendant'
+ shiftT(112); // 'descendant'
+ break;
+ case 113: // 'descendant-or-self'
+ shiftT(113); // 'descendant-or-self'
+ break;
+ case 114: // 'descending'
+ shiftT(114); // 'descending'
+ break;
+ case 119: // 'div'
+ shiftT(119); // 'div'
+ break;
+ case 120: // 'document'
+ shiftT(120); // 'document'
+ break;
+ case 123: // 'else'
+ shiftT(123); // 'else'
+ break;
+ case 124: // 'empty'
+ shiftT(124); // 'empty'
+ break;
+ case 127: // 'end'
+ shiftT(127); // 'end'
+ break;
+ case 129: // 'eq'
+ shiftT(129); // 'eq'
+ break;
+ case 130: // 'every'
+ shiftT(130); // 'every'
+ break;
+ case 132: // 'except'
+ shiftT(132); // 'except'
+ break;
+ case 136: // 'first'
+ shiftT(136); // 'first'
+ break;
+ case 137: // 'following'
+ shiftT(137); // 'following'
+ break;
+ case 138: // 'following-sibling'
+ shiftT(138); // 'following-sibling'
+ break;
+ case 139: // 'for'
+ shiftT(139); // 'for'
+ break;
+ case 148: // 'ge'
+ shiftT(148); // 'ge'
+ break;
+ case 150: // 'group'
+ shiftT(150); // 'group'
+ break;
+ case 152: // 'gt'
+ shiftT(152); // 'gt'
+ break;
+ case 153: // 'idiv'
+ shiftT(153); // 'idiv'
+ break;
+ case 155: // 'import'
+ shiftT(155); // 'import'
+ break;
+ case 161: // 'insert'
+ shiftT(161); // 'insert'
+ break;
+ case 162: // 'instance'
+ shiftT(162); // 'instance'
+ break;
+ case 164: // 'intersect'
+ shiftT(164); // 'intersect'
+ break;
+ case 165: // 'into'
+ shiftT(165); // 'into'
+ break;
+ case 166: // 'is'
+ shiftT(166); // 'is'
+ break;
+ case 173: // 'last'
+ shiftT(173); // 'last'
+ break;
+ case 175: // 'le'
+ shiftT(175); // 'le'
+ break;
+ case 177: // 'let'
+ shiftT(177); // 'let'
+ break;
+ case 181: // 'lt'
+ shiftT(181); // 'lt'
+ break;
+ case 183: // 'mod'
+ shiftT(183); // 'mod'
+ break;
+ case 184: // 'modify'
+ shiftT(184); // 'modify'
+ break;
+ case 185: // 'module'
+ shiftT(185); // 'module'
+ break;
+ case 187: // 'namespace'
+ shiftT(187); // 'namespace'
+ break;
+ case 189: // 'ne'
+ shiftT(189); // 'ne'
+ break;
+ case 202: // 'only'
+ shiftT(202); // 'only'
+ break;
+ case 204: // 'or'
+ shiftT(204); // 'or'
+ break;
+ case 205: // 'order'
+ shiftT(205); // 'order'
+ break;
+ case 206: // 'ordered'
+ shiftT(206); // 'ordered'
+ break;
+ case 210: // 'parent'
+ shiftT(210); // 'parent'
+ break;
+ case 216: // 'preceding'
+ shiftT(216); // 'preceding'
+ break;
+ case 217: // 'preceding-sibling'
+ shiftT(217); // 'preceding-sibling'
+ break;
+ case 222: // 'rename'
+ shiftT(222); // 'rename'
+ break;
+ case 223: // 'replace'
+ shiftT(223); // 'replace'
+ break;
+ case 224: // 'return'
+ shiftT(224); // 'return'
+ break;
+ case 228: // 'satisfies'
+ shiftT(228); // 'satisfies'
+ break;
+ case 234: // 'self'
+ shiftT(234); // 'self'
+ break;
+ case 240: // 'some'
+ shiftT(240); // 'some'
+ break;
+ case 241: // 'stable'
+ shiftT(241); // 'stable'
+ break;
+ case 242: // 'start'
+ shiftT(242); // 'start'
+ break;
+ case 253: // 'to'
+ shiftT(253); // 'to'
+ break;
+ case 254: // 'treat'
+ shiftT(254); // 'treat'
+ break;
+ case 256: // 'try'
+ shiftT(256); // 'try'
+ break;
+ case 260: // 'union'
+ shiftT(260); // 'union'
+ break;
+ case 262: // 'unordered'
+ shiftT(262); // 'unordered'
+ break;
+ case 266: // 'validate'
+ shiftT(266); // 'validate'
+ break;
+ case 272: // 'where'
+ shiftT(272); // 'where'
+ break;
+ case 276: // 'with'
+ shiftT(276); // 'with'
+ break;
+ case 170: // 'jsoniq'
+ shiftT(170); // 'jsoniq'
+ break;
+ case 73: // 'allowing'
+ shiftT(73); // 'allowing'
+ break;
+ case 82: // 'at'
+ shiftT(82); // 'at'
+ break;
+ case 84: // 'base-uri'
+ shiftT(84); // 'base-uri'
+ break;
+ case 86: // 'boundary-space'
+ shiftT(86); // 'boundary-space'
+ break;
+ case 87: // 'break'
+ shiftT(87); // 'break'
+ break;
+ case 92: // 'catch'
+ shiftT(92); // 'catch'
+ break;
+ case 99: // 'construction'
+ shiftT(99); // 'construction'
+ break;
+ case 102: // 'context'
+ shiftT(102); // 'context'
+ break;
+ case 103: // 'continue'
+ shiftT(103); // 'continue'
+ break;
+ case 105: // 'copy-namespaces'
+ shiftT(105); // 'copy-namespaces'
+ break;
+ case 107: // 'decimal-format'
+ shiftT(107); // 'decimal-format'
+ break;
+ case 126: // 'encoding'
+ shiftT(126); // 'encoding'
+ break;
+ case 133: // 'exit'
+ shiftT(133); // 'exit'
+ break;
+ case 134: // 'external'
+ shiftT(134); // 'external'
+ break;
+ case 143: // 'ft-option'
+ shiftT(143); // 'ft-option'
+ break;
+ case 156: // 'in'
+ shiftT(156); // 'in'
+ break;
+ case 157: // 'index'
+ shiftT(157); // 'index'
+ break;
+ case 163: // 'integrity'
+ shiftT(163); // 'integrity'
+ break;
+ case 174: // 'lax'
+ shiftT(174); // 'lax'
+ break;
+ case 195: // 'nodes'
+ shiftT(195); // 'nodes'
+ break;
+ case 203: // 'option'
+ shiftT(203); // 'option'
+ break;
+ case 207: // 'ordering'
+ shiftT(207); // 'ordering'
+ break;
+ case 226: // 'revalidation'
+ shiftT(226); // 'revalidation'
+ break;
+ case 229: // 'schema'
+ shiftT(229); // 'schema'
+ break;
+ case 232: // 'score'
+ shiftT(232); // 'score'
+ break;
+ case 239: // 'sliding'
+ shiftT(239); // 'sliding'
+ break;
+ case 245: // 'strict'
+ shiftT(245); // 'strict'
+ break;
+ case 257: // 'tumbling'
+ shiftT(257); // 'tumbling'
+ break;
+ case 258: // 'type'
+ shiftT(258); // 'type'
+ break;
+ case 263: // 'updating'
+ shiftT(263); // 'updating'
+ break;
+ case 267: // 'value'
+ shiftT(267); // 'value'
+ break;
+ case 268: // 'variable'
+ shiftT(268); // 'variable'
+ break;
+ case 269: // 'version'
+ shiftT(269); // 'version'
+ break;
+ case 273: // 'while'
+ shiftT(273); // 'while'
+ break;
+ case 98: // 'constraint'
+ shiftT(98); // 'constraint'
+ break;
+ case 179: // 'loop'
+ shiftT(179); // 'loop'
+ break;
+ case 225: // 'returning'
+ shiftT(225); // 'returning'
+ break;
+ case 78: // 'append'
+ shiftT(78); // 'append'
+ break;
+ case 135: // 'false'
+ shiftT(135); // 'false'
+ break;
+ case 142: // 'from'
+ shiftT(142); // 'from'
+ break;
+ case 197: // 'null'
+ shiftT(197); // 'null'
+ break;
+ case 168: // 'json'
+ shiftT(168); // 'json'
+ break;
+ case 198: // 'object'
+ shiftT(198); // 'object'
+ break;
+ case 233: // 'select'
+ shiftT(233); // 'select'
+ break;
+ default:
+ shiftT(255); // 'true'
+ }
+ }
+
+ function parse_NCName()
+ {
+ eventHandler.startNonterminal("NCName", e0);
+ switch (l1)
+ {
+ case 19: // NCName^Token
+ shift(19); // NCName^Token
+ break;
+ case 71: // 'after'
+ shift(71); // 'after'
+ break;
+ case 76: // 'and'
+ shift(76); // 'and'
+ break;
+ case 80: // 'as'
+ shift(80); // 'as'
+ break;
+ case 81: // 'ascending'
+ shift(81); // 'ascending'
+ break;
+ case 85: // 'before'
+ shift(85); // 'before'
+ break;
+ case 89: // 'case'
+ shift(89); // 'case'
+ break;
+ case 90: // 'cast'
+ shift(90); // 'cast'
+ break;
+ case 91: // 'castable'
+ shift(91); // 'castable'
+ break;
+ case 95: // 'collation'
+ shift(95); // 'collation'
+ break;
+ case 106: // 'count'
+ shift(106); // 'count'
+ break;
+ case 110: // 'default'
+ shift(110); // 'default'
+ break;
+ case 114: // 'descending'
+ shift(114); // 'descending'
+ break;
+ case 119: // 'div'
+ shift(119); // 'div'
+ break;
+ case 123: // 'else'
+ shift(123); // 'else'
+ break;
+ case 124: // 'empty'
+ shift(124); // 'empty'
+ break;
+ case 127: // 'end'
+ shift(127); // 'end'
+ break;
+ case 129: // 'eq'
+ shift(129); // 'eq'
+ break;
+ case 132: // 'except'
+ shift(132); // 'except'
+ break;
+ case 139: // 'for'
+ shift(139); // 'for'
+ break;
+ case 148: // 'ge'
+ shift(148); // 'ge'
+ break;
+ case 150: // 'group'
+ shift(150); // 'group'
+ break;
+ case 152: // 'gt'
+ shift(152); // 'gt'
+ break;
+ case 153: // 'idiv'
+ shift(153); // 'idiv'
+ break;
+ case 162: // 'instance'
+ shift(162); // 'instance'
+ break;
+ case 164: // 'intersect'
+ shift(164); // 'intersect'
+ break;
+ case 165: // 'into'
+ shift(165); // 'into'
+ break;
+ case 166: // 'is'
+ shift(166); // 'is'
+ break;
+ case 175: // 'le'
+ shift(175); // 'le'
+ break;
+ case 177: // 'let'
+ shift(177); // 'let'
+ break;
+ case 181: // 'lt'
+ shift(181); // 'lt'
+ break;
+ case 183: // 'mod'
+ shift(183); // 'mod'
+ break;
+ case 184: // 'modify'
+ shift(184); // 'modify'
+ break;
+ case 189: // 'ne'
+ shift(189); // 'ne'
+ break;
+ case 202: // 'only'
+ shift(202); // 'only'
+ break;
+ case 204: // 'or'
+ shift(204); // 'or'
+ break;
+ case 205: // 'order'
+ shift(205); // 'order'
+ break;
+ case 224: // 'return'
+ shift(224); // 'return'
+ break;
+ case 228: // 'satisfies'
+ shift(228); // 'satisfies'
+ break;
+ case 241: // 'stable'
+ shift(241); // 'stable'
+ break;
+ case 242: // 'start'
+ shift(242); // 'start'
+ break;
+ case 253: // 'to'
+ shift(253); // 'to'
+ break;
+ case 254: // 'treat'
+ shift(254); // 'treat'
+ break;
+ case 260: // 'union'
+ shift(260); // 'union'
+ break;
+ case 272: // 'where'
+ shift(272); // 'where'
+ break;
+ case 276: // 'with'
+ shift(276); // 'with'
+ break;
+ case 74: // 'ancestor'
+ shift(74); // 'ancestor'
+ break;
+ case 75: // 'ancestor-or-self'
+ shift(75); // 'ancestor-or-self'
+ break;
+ case 83: // 'attribute'
+ shift(83); // 'attribute'
+ break;
+ case 94: // 'child'
+ shift(94); // 'child'
+ break;
+ case 97: // 'comment'
+ shift(97); // 'comment'
+ break;
+ case 104: // 'copy'
+ shift(104); // 'copy'
+ break;
+ case 109: // 'declare'
+ shift(109); // 'declare'
+ break;
+ case 111: // 'delete'
+ shift(111); // 'delete'
+ break;
+ case 112: // 'descendant'
+ shift(112); // 'descendant'
+ break;
+ case 113: // 'descendant-or-self'
+ shift(113); // 'descendant-or-self'
+ break;
+ case 120: // 'document'
+ shift(120); // 'document'
+ break;
+ case 121: // 'document-node'
+ shift(121); // 'document-node'
+ break;
+ case 122: // 'element'
+ shift(122); // 'element'
+ break;
+ case 125: // 'empty-sequence'
+ shift(125); // 'empty-sequence'
+ break;
+ case 130: // 'every'
+ shift(130); // 'every'
+ break;
+ case 136: // 'first'
+ shift(136); // 'first'
+ break;
+ case 137: // 'following'
+ shift(137); // 'following'
+ break;
+ case 138: // 'following-sibling'
+ shift(138); // 'following-sibling'
+ break;
+ case 147: // 'function'
+ shift(147); // 'function'
+ break;
+ case 154: // 'if'
+ shift(154); // 'if'
+ break;
+ case 155: // 'import'
+ shift(155); // 'import'
+ break;
+ case 161: // 'insert'
+ shift(161); // 'insert'
+ break;
+ case 167: // 'item'
+ shift(167); // 'item'
+ break;
+ case 173: // 'last'
+ shift(173); // 'last'
+ break;
+ case 185: // 'module'
+ shift(185); // 'module'
+ break;
+ case 187: // 'namespace'
+ shift(187); // 'namespace'
+ break;
+ case 188: // 'namespace-node'
+ shift(188); // 'namespace-node'
+ break;
+ case 194: // 'node'
+ shift(194); // 'node'
+ break;
+ case 206: // 'ordered'
+ shift(206); // 'ordered'
+ break;
+ case 210: // 'parent'
+ shift(210); // 'parent'
+ break;
+ case 216: // 'preceding'
+ shift(216); // 'preceding'
+ break;
+ case 217: // 'preceding-sibling'
+ shift(217); // 'preceding-sibling'
+ break;
+ case 220: // 'processing-instruction'
+ shift(220); // 'processing-instruction'
+ break;
+ case 222: // 'rename'
+ shift(222); // 'rename'
+ break;
+ case 223: // 'replace'
+ shift(223); // 'replace'
+ break;
+ case 230: // 'schema-attribute'
+ shift(230); // 'schema-attribute'
+ break;
+ case 231: // 'schema-element'
+ shift(231); // 'schema-element'
+ break;
+ case 234: // 'self'
+ shift(234); // 'self'
+ break;
+ case 240: // 'some'
+ shift(240); // 'some'
+ break;
+ case 248: // 'switch'
+ shift(248); // 'switch'
+ break;
+ case 249: // 'text'
+ shift(249); // 'text'
+ break;
+ case 256: // 'try'
+ shift(256); // 'try'
+ break;
+ case 259: // 'typeswitch'
+ shift(259); // 'typeswitch'
+ break;
+ case 262: // 'unordered'
+ shift(262); // 'unordered'
+ break;
+ case 266: // 'validate'
+ shift(266); // 'validate'
+ break;
+ case 268: // 'variable'
+ shift(268); // 'variable'
+ break;
+ case 170: // 'jsoniq'
+ shift(170); // 'jsoniq'
+ break;
+ case 73: // 'allowing'
+ shift(73); // 'allowing'
+ break;
+ case 82: // 'at'
+ shift(82); // 'at'
+ break;
+ case 84: // 'base-uri'
+ shift(84); // 'base-uri'
+ break;
+ case 86: // 'boundary-space'
+ shift(86); // 'boundary-space'
+ break;
+ case 87: // 'break'
+ shift(87); // 'break'
+ break;
+ case 92: // 'catch'
+ shift(92); // 'catch'
+ break;
+ case 99: // 'construction'
+ shift(99); // 'construction'
+ break;
+ case 102: // 'context'
+ shift(102); // 'context'
+ break;
+ case 103: // 'continue'
+ shift(103); // 'continue'
+ break;
+ case 105: // 'copy-namespaces'
+ shift(105); // 'copy-namespaces'
+ break;
+ case 107: // 'decimal-format'
+ shift(107); // 'decimal-format'
+ break;
+ case 126: // 'encoding'
+ shift(126); // 'encoding'
+ break;
+ case 133: // 'exit'
+ shift(133); // 'exit'
+ break;
+ case 134: // 'external'
+ shift(134); // 'external'
+ break;
+ case 143: // 'ft-option'
+ shift(143); // 'ft-option'
+ break;
+ case 156: // 'in'
+ shift(156); // 'in'
+ break;
+ case 157: // 'index'
+ shift(157); // 'index'
+ break;
+ case 163: // 'integrity'
+ shift(163); // 'integrity'
+ break;
+ case 174: // 'lax'
+ shift(174); // 'lax'
+ break;
+ case 195: // 'nodes'
+ shift(195); // 'nodes'
+ break;
+ case 203: // 'option'
+ shift(203); // 'option'
+ break;
+ case 207: // 'ordering'
+ shift(207); // 'ordering'
+ break;
+ case 226: // 'revalidation'
+ shift(226); // 'revalidation'
+ break;
+ case 229: // 'schema'
+ shift(229); // 'schema'
+ break;
+ case 232: // 'score'
+ shift(232); // 'score'
+ break;
+ case 239: // 'sliding'
+ shift(239); // 'sliding'
+ break;
+ case 245: // 'strict'
+ shift(245); // 'strict'
+ break;
+ case 257: // 'tumbling'
+ shift(257); // 'tumbling'
+ break;
+ case 258: // 'type'
+ shift(258); // 'type'
+ break;
+ case 263: // 'updating'
+ shift(263); // 'updating'
+ break;
+ case 267: // 'value'
+ shift(267); // 'value'
+ break;
+ case 269: // 'version'
+ shift(269); // 'version'
+ break;
+ case 273: // 'while'
+ shift(273); // 'while'
+ break;
+ case 98: // 'constraint'
+ shift(98); // 'constraint'
+ break;
+ case 179: // 'loop'
+ shift(179); // 'loop'
+ break;
+ case 225: // 'returning'
+ shift(225); // 'returning'
+ break;
+ case 78: // 'append'
+ shift(78); // 'append'
+ break;
+ case 135: // 'false'
+ shift(135); // 'false'
+ break;
+ case 142: // 'from'
+ shift(142); // 'from'
+ break;
+ case 197: // 'null'
+ shift(197); // 'null'
+ break;
+ case 168: // 'json'
+ shift(168); // 'json'
+ break;
+ case 198: // 'object'
+ shift(198); // 'object'
+ break;
+ case 233: // 'select'
+ shift(233); // 'select'
+ break;
+ default:
+ shift(255); // 'true'
+ }
+ eventHandler.endNonterminal("NCName", e0);
+ }
+
+ function try_NCName()
+ {
+ switch (l1)
+ {
+ case 19: // NCName^Token
+ shiftT(19); // NCName^Token
+ break;
+ case 71: // 'after'
+ shiftT(71); // 'after'
+ break;
+ case 76: // 'and'
+ shiftT(76); // 'and'
+ break;
+ case 80: // 'as'
+ shiftT(80); // 'as'
+ break;
+ case 81: // 'ascending'
+ shiftT(81); // 'ascending'
+ break;
+ case 85: // 'before'
+ shiftT(85); // 'before'
+ break;
+ case 89: // 'case'
+ shiftT(89); // 'case'
+ break;
+ case 90: // 'cast'
+ shiftT(90); // 'cast'
+ break;
+ case 91: // 'castable'
+ shiftT(91); // 'castable'
+ break;
+ case 95: // 'collation'
+ shiftT(95); // 'collation'
+ break;
+ case 106: // 'count'
+ shiftT(106); // 'count'
+ break;
+ case 110: // 'default'
+ shiftT(110); // 'default'
+ break;
+ case 114: // 'descending'
+ shiftT(114); // 'descending'
+ break;
+ case 119: // 'div'
+ shiftT(119); // 'div'
+ break;
+ case 123: // 'else'
+ shiftT(123); // 'else'
+ break;
+ case 124: // 'empty'
+ shiftT(124); // 'empty'
+ break;
+ case 127: // 'end'
+ shiftT(127); // 'end'
+ break;
+ case 129: // 'eq'
+ shiftT(129); // 'eq'
+ break;
+ case 132: // 'except'
+ shiftT(132); // 'except'
+ break;
+ case 139: // 'for'
+ shiftT(139); // 'for'
+ break;
+ case 148: // 'ge'
+ shiftT(148); // 'ge'
+ break;
+ case 150: // 'group'
+ shiftT(150); // 'group'
+ break;
+ case 152: // 'gt'
+ shiftT(152); // 'gt'
+ break;
+ case 153: // 'idiv'
+ shiftT(153); // 'idiv'
+ break;
+ case 162: // 'instance'
+ shiftT(162); // 'instance'
+ break;
+ case 164: // 'intersect'
+ shiftT(164); // 'intersect'
+ break;
+ case 165: // 'into'
+ shiftT(165); // 'into'
+ break;
+ case 166: // 'is'
+ shiftT(166); // 'is'
+ break;
+ case 175: // 'le'
+ shiftT(175); // 'le'
+ break;
+ case 177: // 'let'
+ shiftT(177); // 'let'
+ break;
+ case 181: // 'lt'
+ shiftT(181); // 'lt'
+ break;
+ case 183: // 'mod'
+ shiftT(183); // 'mod'
+ break;
+ case 184: // 'modify'
+ shiftT(184); // 'modify'
+ break;
+ case 189: // 'ne'
+ shiftT(189); // 'ne'
+ break;
+ case 202: // 'only'
+ shiftT(202); // 'only'
+ break;
+ case 204: // 'or'
+ shiftT(204); // 'or'
+ break;
+ case 205: // 'order'
+ shiftT(205); // 'order'
+ break;
+ case 224: // 'return'
+ shiftT(224); // 'return'
+ break;
+ case 228: // 'satisfies'
+ shiftT(228); // 'satisfies'
+ break;
+ case 241: // 'stable'
+ shiftT(241); // 'stable'
+ break;
+ case 242: // 'start'
+ shiftT(242); // 'start'
+ break;
+ case 253: // 'to'
+ shiftT(253); // 'to'
+ break;
+ case 254: // 'treat'
+ shiftT(254); // 'treat'
+ break;
+ case 260: // 'union'
+ shiftT(260); // 'union'
+ break;
+ case 272: // 'where'
+ shiftT(272); // 'where'
+ break;
+ case 276: // 'with'
+ shiftT(276); // 'with'
+ break;
+ case 74: // 'ancestor'
+ shiftT(74); // 'ancestor'
+ break;
+ case 75: // 'ancestor-or-self'
+ shiftT(75); // 'ancestor-or-self'
+ break;
+ case 83: // 'attribute'
+ shiftT(83); // 'attribute'
+ break;
+ case 94: // 'child'
+ shiftT(94); // 'child'
+ break;
+ case 97: // 'comment'
+ shiftT(97); // 'comment'
+ break;
+ case 104: // 'copy'
+ shiftT(104); // 'copy'
+ break;
+ case 109: // 'declare'
+ shiftT(109); // 'declare'
+ break;
+ case 111: // 'delete'
+ shiftT(111); // 'delete'
+ break;
+ case 112: // 'descendant'
+ shiftT(112); // 'descendant'
+ break;
+ case 113: // 'descendant-or-self'
+ shiftT(113); // 'descendant-or-self'
+ break;
+ case 120: // 'document'
+ shiftT(120); // 'document'
+ break;
+ case 121: // 'document-node'
+ shiftT(121); // 'document-node'
+ break;
+ case 122: // 'element'
+ shiftT(122); // 'element'
+ break;
+ case 125: // 'empty-sequence'
+ shiftT(125); // 'empty-sequence'
+ break;
+ case 130: // 'every'
+ shiftT(130); // 'every'
+ break;
+ case 136: // 'first'
+ shiftT(136); // 'first'
+ break;
+ case 137: // 'following'
+ shiftT(137); // 'following'
+ break;
+ case 138: // 'following-sibling'
+ shiftT(138); // 'following-sibling'
+ break;
+ case 147: // 'function'
+ shiftT(147); // 'function'
+ break;
+ case 154: // 'if'
+ shiftT(154); // 'if'
+ break;
+ case 155: // 'import'
+ shiftT(155); // 'import'
+ break;
+ case 161: // 'insert'
+ shiftT(161); // 'insert'
+ break;
+ case 167: // 'item'
+ shiftT(167); // 'item'
+ break;
+ case 173: // 'last'
+ shiftT(173); // 'last'
+ break;
+ case 185: // 'module'
+ shiftT(185); // 'module'
+ break;
+ case 187: // 'namespace'
+ shiftT(187); // 'namespace'
+ break;
+ case 188: // 'namespace-node'
+ shiftT(188); // 'namespace-node'
+ break;
+ case 194: // 'node'
+ shiftT(194); // 'node'
+ break;
+ case 206: // 'ordered'
+ shiftT(206); // 'ordered'
+ break;
+ case 210: // 'parent'
+ shiftT(210); // 'parent'
+ break;
+ case 216: // 'preceding'
+ shiftT(216); // 'preceding'
+ break;
+ case 217: // 'preceding-sibling'
+ shiftT(217); // 'preceding-sibling'
+ break;
+ case 220: // 'processing-instruction'
+ shiftT(220); // 'processing-instruction'
+ break;
+ case 222: // 'rename'
+ shiftT(222); // 'rename'
+ break;
+ case 223: // 'replace'
+ shiftT(223); // 'replace'
+ break;
+ case 230: // 'schema-attribute'
+ shiftT(230); // 'schema-attribute'
+ break;
+ case 231: // 'schema-element'
+ shiftT(231); // 'schema-element'
+ break;
+ case 234: // 'self'
+ shiftT(234); // 'self'
+ break;
+ case 240: // 'some'
+ shiftT(240); // 'some'
+ break;
+ case 248: // 'switch'
+ shiftT(248); // 'switch'
+ break;
+ case 249: // 'text'
+ shiftT(249); // 'text'
+ break;
+ case 256: // 'try'
+ shiftT(256); // 'try'
+ break;
+ case 259: // 'typeswitch'
+ shiftT(259); // 'typeswitch'
+ break;
+ case 262: // 'unordered'
+ shiftT(262); // 'unordered'
+ break;
+ case 266: // 'validate'
+ shiftT(266); // 'validate'
+ break;
+ case 268: // 'variable'
+ shiftT(268); // 'variable'
+ break;
+ case 170: // 'jsoniq'
+ shiftT(170); // 'jsoniq'
+ break;
+ case 73: // 'allowing'
+ shiftT(73); // 'allowing'
+ break;
+ case 82: // 'at'
+ shiftT(82); // 'at'
+ break;
+ case 84: // 'base-uri'
+ shiftT(84); // 'base-uri'
+ break;
+ case 86: // 'boundary-space'
+ shiftT(86); // 'boundary-space'
+ break;
+ case 87: // 'break'
+ shiftT(87); // 'break'
+ break;
+ case 92: // 'catch'
+ shiftT(92); // 'catch'
+ break;
+ case 99: // 'construction'
+ shiftT(99); // 'construction'
+ break;
+ case 102: // 'context'
+ shiftT(102); // 'context'
+ break;
+ case 103: // 'continue'
+ shiftT(103); // 'continue'
+ break;
+ case 105: // 'copy-namespaces'
+ shiftT(105); // 'copy-namespaces'
+ break;
+ case 107: // 'decimal-format'
+ shiftT(107); // 'decimal-format'
+ break;
+ case 126: // 'encoding'
+ shiftT(126); // 'encoding'
+ break;
+ case 133: // 'exit'
+ shiftT(133); // 'exit'
+ break;
+ case 134: // 'external'
+ shiftT(134); // 'external'
+ break;
+ case 143: // 'ft-option'
+ shiftT(143); // 'ft-option'
+ break;
+ case 156: // 'in'
+ shiftT(156); // 'in'
+ break;
+ case 157: // 'index'
+ shiftT(157); // 'index'
+ break;
+ case 163: // 'integrity'
+ shiftT(163); // 'integrity'
+ break;
+ case 174: // 'lax'
+ shiftT(174); // 'lax'
+ break;
+ case 195: // 'nodes'
+ shiftT(195); // 'nodes'
+ break;
+ case 203: // 'option'
+ shiftT(203); // 'option'
+ break;
+ case 207: // 'ordering'
+ shiftT(207); // 'ordering'
+ break;
+ case 226: // 'revalidation'
+ shiftT(226); // 'revalidation'
+ break;
+ case 229: // 'schema'
+ shiftT(229); // 'schema'
+ break;
+ case 232: // 'score'
+ shiftT(232); // 'score'
+ break;
+ case 239: // 'sliding'
+ shiftT(239); // 'sliding'
+ break;
+ case 245: // 'strict'
+ shiftT(245); // 'strict'
+ break;
+ case 257: // 'tumbling'
+ shiftT(257); // 'tumbling'
+ break;
+ case 258: // 'type'
+ shiftT(258); // 'type'
+ break;
+ case 263: // 'updating'
+ shiftT(263); // 'updating'
+ break;
+ case 267: // 'value'
+ shiftT(267); // 'value'
+ break;
+ case 269: // 'version'
+ shiftT(269); // 'version'
+ break;
+ case 273: // 'while'
+ shiftT(273); // 'while'
+ break;
+ case 98: // 'constraint'
+ shiftT(98); // 'constraint'
+ break;
+ case 179: // 'loop'
+ shiftT(179); // 'loop'
+ break;
+ case 225: // 'returning'
+ shiftT(225); // 'returning'
+ break;
+ case 78: // 'append'
+ shiftT(78); // 'append'
+ break;
+ case 135: // 'false'
+ shiftT(135); // 'false'
+ break;
+ case 142: // 'from'
+ shiftT(142); // 'from'
+ break;
+ case 197: // 'null'
+ shiftT(197); // 'null'
+ break;
+ case 168: // 'json'
+ shiftT(168); // 'json'
+ break;
+ case 198: // 'object'
+ shiftT(198); // 'object'
+ break;
+ case 233: // 'select'
+ shiftT(233); // 'select'
+ break;
+ default:
+ shiftT(255); // 'true'
+ }
+ }
+
+ function parse_MainModule()
+ {
+ eventHandler.startNonterminal("MainModule", e0);
+ parse_Prolog();
+ whitespace();
+ parse_Program();
+ eventHandler.endNonterminal("MainModule", e0);
+ }
+
+ function parse_Program()
+ {
+ eventHandler.startNonterminal("Program", e0);
+ parse_StatementsAndOptionalExpr();
+ eventHandler.endNonterminal("Program", e0);
+ }
+
+ function parse_Statements()
+ {
+ eventHandler.startNonterminal("Statements", e0);
+ for (;;)
+ {
+ lookahead1W(283); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 35: // '('
+ lookahead2W(269); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 36: // '(#'
+ lookahead2(242); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ break;
+ case 47: // '/'
+ lookahead2W(285); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 48: // '//'
+ lookahead2W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 55: // '<'
+ lookahead2(4); // QName
+ break;
+ case 56: // '<!--'
+ lookahead2(1); // DirCommentContents
+ break;
+ case 60: // '<?'
+ lookahead2(3); // PITarget
+ break;
+ case 69: // '['
+ lookahead2W(272); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 78: // 'append'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 133: // 'exit'
+ lookahead2W(147); // S^WS | '#' | '(' | '(:' | 'returning'
+ break;
+ case 139: // 'for'
+ lookahead2W(179); // S^WS | '#' | '$' | '(' | '(:' | 'sliding' | 'tumbling'
+ break;
+ case 161: // 'insert'
+ lookahead2W(275); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 177: // 'let'
+ lookahead2W(166); // S^WS | '#' | '$' | '(' | '(:' | 'score'
+ break;
+ case 187: // 'namespace'
+ lookahead2W(246); // NCName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 220: // 'processing-instruction'
+ lookahead2W(244); // NCName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 223: // 'replace'
+ lookahead2W(170); // S^WS | '#' | '(' | '(:' | 'node' | 'value'
+ break;
+ case 266: // 'validate'
+ lookahead2W(188); // S^WS | '#' | '(' | '(:' | 'lax' | 'strict' | 'type' | '{'
+ break;
+ case 281: // '{'
+ lookahead2W(282); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 283: // '{|'
+ lookahead2W(273); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 31: // '$'
+ case 33: // '%'
+ lookahead2W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 83: // 'attribute'
+ case 122: // 'element'
+ lookahead2W(252); // EQName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 87: // 'break'
+ case 103: // 'continue'
+ lookahead2W(145); // S^WS | '#' | '(' | '(:' | 'loop'
+ break;
+ case 97: // 'comment'
+ case 249: // 'text'
+ lookahead2W(97); // S^WS | '#' | '(:' | '{'
+ break;
+ case 111: // 'delete'
+ case 222: // 'rename'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 41: // '+'
+ case 43: // '-'
+ case 196: // 'not'
+ lookahead2W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(210); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '.' | '/' |
+ break;
+ case 104: // 'copy'
+ case 130: // 'every'
+ case 240: // 'some'
+ case 268: // 'variable'
+ lookahead2W(143); // S^WS | '#' | '$' | '(' | '(:'
+ break;
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 256: // 'try'
+ case 262: // 'unordered'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 32: // '$$'
+ lookahead2W(209); // S^WS | EOF | '!' | '!=' | '(' | '(:' | '*' | '+' | ',' | '-' | '.' | '/' | '//' |
+ break;
+ case 79: // 'array'
+ case 121: // 'document-node'
+ case 125: // 'empty-sequence'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 247: // 'structured-item'
+ lookahead2W(20); // S^WS | '#' | '(:'
+ break;
+ case 6: // EQName^Token
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 76: // 'and'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 94: // 'child'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 132: // 'except'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 147: // 'function'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 154: // 'if'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 189: // 'ne'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 234: // 'self'
+ case 239: // 'sliding'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 248: // 'switch'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 259: // 'typeswitch'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 267: // 'value'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 54 // ';'
+ && lk != 287 // '}'
+ && lk != 12808 // IntegerLiteral EOF
+ && lk != 12809 // DecimalLiteral EOF
+ && lk != 12810 // DoubleLiteral EOF
+ && lk != 12811 // StringLiteral EOF
+ && lk != 12832 // '$$' EOF
+ && lk != 12847 // '/' EOF
+ && lk != 12935 // 'false' EOF
+ && lk != 12997 // 'null' EOF
+ && lk != 13055 // 'true' EOF
+ && lk != 16140 // 'variable' '$'
+ && lk != 21512 // IntegerLiteral ','
+ && lk != 21513 // DecimalLiteral ','
+ && lk != 21514 // DoubleLiteral ','
+ && lk != 21515 // StringLiteral ','
+ && lk != 21536 // '$$' ','
+ && lk != 21551 // '/' ','
+ && lk != 21639 // 'false' ','
+ && lk != 21701 // 'null' ','
+ && lk != 21759 // 'true' ','
+ && lk != 27656 // IntegerLiteral ';'
+ && lk != 27657 // DecimalLiteral ';'
+ && lk != 27658 // DoubleLiteral ';'
+ && lk != 27659 // StringLiteral ';'
+ && lk != 27680 // '$$' ';'
+ && lk != 27695 // '/' ';'
+ && lk != 27783 // 'false' ';'
+ && lk != 27845 // 'null' ';'
+ && lk != 27903 // 'true' ';'
+ && lk != 91735 // 'break' 'loop'
+ && lk != 91751 // 'continue' 'loop'
+ && lk != 115333 // 'exit' 'returning'
+ && lk != 146952 // IntegerLiteral '}'
+ && lk != 146953 // DecimalLiteral '}'
+ && lk != 146954 // DoubleLiteral '}'
+ && lk != 146955 // StringLiteral '}'
+ && lk != 146976 // '$$' '}'
+ && lk != 146991 // '/' '}'
+ && lk != 147079 // 'false' '}'
+ && lk != 147141 // 'null' '}'
+ && lk != 147199) // 'true' '}'
+ {
+ lk = memoized(8, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Statement();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(8, e0, lk);
+ }
+ }
+ if (lk != -1
+ && lk != 54 // ';'
+ && lk != 16140 // 'variable' '$'
+ && lk != 27656 // IntegerLiteral ';'
+ && lk != 27657 // DecimalLiteral ';'
+ && lk != 27658 // DoubleLiteral ';'
+ && lk != 27659 // StringLiteral ';'
+ && lk != 27680 // '$$' ';'
+ && lk != 27695 // '/' ';'
+ && lk != 27783 // 'false' ';'
+ && lk != 27845 // 'null' ';'
+ && lk != 27903 // 'true' ';'
+ && lk != 91735 // 'break' 'loop'
+ && lk != 91751 // 'continue' 'loop'
+ && lk != 115333) // 'exit' 'returning'
+ {
+ break;
+ }
+ whitespace();
+ parse_Statement();
+ }
+ eventHandler.endNonterminal("Statements", e0);
+ }
+
+ function try_Statements()
+ {
+ for (;;)
+ {
+ lookahead1W(283); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 35: // '('
+ lookahead2W(269); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 36: // '(#'
+ lookahead2(242); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ break;
+ case 47: // '/'
+ lookahead2W(285); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 48: // '//'
+ lookahead2W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 55: // '<'
+ lookahead2(4); // QName
+ break;
+ case 56: // '<!--'
+ lookahead2(1); // DirCommentContents
+ break;
+ case 60: // '<?'
+ lookahead2(3); // PITarget
+ break;
+ case 69: // '['
+ lookahead2W(272); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 78: // 'append'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 133: // 'exit'
+ lookahead2W(147); // S^WS | '#' | '(' | '(:' | 'returning'
+ break;
+ case 139: // 'for'
+ lookahead2W(179); // S^WS | '#' | '$' | '(' | '(:' | 'sliding' | 'tumbling'
+ break;
+ case 161: // 'insert'
+ lookahead2W(275); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 177: // 'let'
+ lookahead2W(166); // S^WS | '#' | '$' | '(' | '(:' | 'score'
+ break;
+ case 187: // 'namespace'
+ lookahead2W(246); // NCName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 220: // 'processing-instruction'
+ lookahead2W(244); // NCName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 223: // 'replace'
+ lookahead2W(170); // S^WS | '#' | '(' | '(:' | 'node' | 'value'
+ break;
+ case 266: // 'validate'
+ lookahead2W(188); // S^WS | '#' | '(' | '(:' | 'lax' | 'strict' | 'type' | '{'
+ break;
+ case 281: // '{'
+ lookahead2W(282); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 283: // '{|'
+ lookahead2W(273); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 31: // '$'
+ case 33: // '%'
+ lookahead2W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 83: // 'attribute'
+ case 122: // 'element'
+ lookahead2W(252); // EQName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 87: // 'break'
+ case 103: // 'continue'
+ lookahead2W(145); // S^WS | '#' | '(' | '(:' | 'loop'
+ break;
+ case 97: // 'comment'
+ case 249: // 'text'
+ lookahead2W(97); // S^WS | '#' | '(:' | '{'
+ break;
+ case 111: // 'delete'
+ case 222: // 'rename'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 41: // '+'
+ case 43: // '-'
+ case 196: // 'not'
+ lookahead2W(265); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(210); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '.' | '/' |
+ break;
+ case 104: // 'copy'
+ case 130: // 'every'
+ case 240: // 'some'
+ case 268: // 'variable'
+ lookahead2W(143); // S^WS | '#' | '$' | '(' | '(:'
+ break;
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 256: // 'try'
+ case 262: // 'unordered'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 32: // '$$'
+ lookahead2W(209); // S^WS | EOF | '!' | '!=' | '(' | '(:' | '*' | '+' | ',' | '-' | '.' | '/' | '//' |
+ break;
+ case 79: // 'array'
+ case 121: // 'document-node'
+ case 125: // 'empty-sequence'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 247: // 'structured-item'
+ lookahead2W(20); // S^WS | '#' | '(:'
+ break;
+ case 6: // EQName^Token
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 76: // 'and'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 94: // 'child'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 132: // 'except'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 147: // 'function'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 154: // 'if'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 189: // 'ne'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 234: // 'self'
+ case 239: // 'sliding'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 248: // 'switch'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 259: // 'typeswitch'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 267: // 'value'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 54 // ';'
+ && lk != 287 // '}'
+ && lk != 12808 // IntegerLiteral EOF
+ && lk != 12809 // DecimalLiteral EOF
+ && lk != 12810 // DoubleLiteral EOF
+ && lk != 12811 // StringLiteral EOF
+ && lk != 12832 // '$$' EOF
+ && lk != 12847 // '/' EOF
+ && lk != 12935 // 'false' EOF
+ && lk != 12997 // 'null' EOF
+ && lk != 13055 // 'true' EOF
+ && lk != 16140 // 'variable' '$'
+ && lk != 21512 // IntegerLiteral ','
+ && lk != 21513 // DecimalLiteral ','
+ && lk != 21514 // DoubleLiteral ','
+ && lk != 21515 // StringLiteral ','
+ && lk != 21536 // '$$' ','
+ && lk != 21551 // '/' ','
+ && lk != 21639 // 'false' ','
+ && lk != 21701 // 'null' ','
+ && lk != 21759 // 'true' ','
+ && lk != 27656 // IntegerLiteral ';'
+ && lk != 27657 // DecimalLiteral ';'
+ && lk != 27658 // DoubleLiteral ';'
+ && lk != 27659 // StringLiteral ';'
+ && lk != 27680 // '$$' ';'
+ && lk != 27695 // '/' ';'
+ && lk != 27783 // 'false' ';'
+ && lk != 27845 // 'null' ';'
+ && lk != 27903 // 'true' ';'
+ && lk != 91735 // 'break' 'loop'
+ && lk != 91751 // 'continue' 'loop'
+ && lk != 115333 // 'exit' 'returning'
+ && lk != 146952 // IntegerLiteral '}'
+ && lk != 146953 // DecimalLiteral '}'
+ && lk != 146954 // DoubleLiteral '}'
+ && lk != 146955 // StringLiteral '}'
+ && lk != 146976 // '$$' '}'
+ && lk != 146991 // '/' '}'
+ && lk != 147079 // 'false' '}'
+ && lk != 147141 // 'null' '}'
+ && lk != 147199) // 'true' '}'
+ {
+ lk = memoized(8, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Statement();
+ memoize(8, e0A, -1);
+ continue;
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(8, e0A, -2);
+ break;
+ }
+ }
+ }
+ if (lk != -1
+ && lk != 54 // ';'
+ && lk != 16140 // 'variable' '$'
+ && lk != 27656 // IntegerLiteral ';'
+ && lk != 27657 // DecimalLiteral ';'
+ && lk != 27658 // DoubleLiteral ';'
+ && lk != 27659 // StringLiteral ';'
+ && lk != 27680 // '$$' ';'
+ && lk != 27695 // '/' ';'
+ && lk != 27783 // 'false' ';'
+ && lk != 27845 // 'null' ';'
+ && lk != 27903 // 'true' ';'
+ && lk != 91735 // 'break' 'loop'
+ && lk != 91751 // 'continue' 'loop'
+ && lk != 115333) // 'exit' 'returning'
+ {
+ break;
+ }
+ try_Statement();
+ }
+ }
+
+ function parse_StatementsAndExpr()
+ {
+ eventHandler.startNonterminal("StatementsAndExpr", e0);
+ parse_Statements();
+ whitespace();
+ parse_Expr();
+ eventHandler.endNonterminal("StatementsAndExpr", e0);
+ }
+
+ function try_StatementsAndExpr()
+ {
+ try_Statements();
+ try_Expr();
+ }
+
+ function parse_StatementsAndOptionalExpr()
+ {
+ eventHandler.startNonterminal("StatementsAndOptionalExpr", e0);
+ parse_Statements();
+ if (l1 != 25 // EOF
+ && l1 != 287) // '}'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ eventHandler.endNonterminal("StatementsAndOptionalExpr", e0);
+ }
+
+ function try_StatementsAndOptionalExpr()
+ {
+ try_Statements();
+ if (l1 != 25 // EOF
+ && l1 != 287) // '}'
+ {
+ try_Expr();
+ }
+ }
+
+ function parse_Statement()
+ {
+ eventHandler.startNonterminal("Statement", e0);
+ switch (l1)
+ {
+ case 133: // 'exit'
+ lookahead2W(147); // S^WS | '#' | '(' | '(:' | 'returning'
+ break;
+ case 139: // 'for'
+ lookahead2W(179); // S^WS | '#' | '$' | '(' | '(:' | 'sliding' | 'tumbling'
+ break;
+ case 177: // 'let'
+ lookahead2W(166); // S^WS | '#' | '$' | '(' | '(:' | 'score'
+ break;
+ case 256: // 'try'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 268: // 'variable'
+ lookahead2W(143); // S^WS | '#' | '$' | '(' | '(:'
+ break;
+ case 281: // '{'
+ lookahead2W(282); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 31: // '$'
+ case 33: // '%'
+ lookahead2W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 87: // 'break'
+ case 103: // 'continue'
+ lookahead2W(145); // S^WS | '#' | '(' | '(:' | 'loop'
+ break;
+ case 154: // 'if'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ case 273: // 'while'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 6 // EQName^Token
+ && lk != 8 // IntegerLiteral
+ && lk != 9 // DecimalLiteral
+ && lk != 10 // DoubleLiteral
+ && lk != 11 // StringLiteral
+ && lk != 32 // '$$'
+ && lk != 35 // '('
+ && lk != 36 // '(#'
+ && lk != 41 // '+'
+ && lk != 43 // '-'
+ && lk != 47 // '/'
+ && lk != 48 // '//'
+ && lk != 54 // ';'
+ && lk != 55 // '<'
+ && lk != 56 // '<!--'
+ && lk != 60 // '<?'
+ && lk != 69 // '['
+ && lk != 71 // 'after'
+ && lk != 73 // 'allowing'
+ && lk != 74 // 'ancestor'
+ && lk != 75 // 'ancestor-or-self'
+ && lk != 76 // 'and'
+ && lk != 78 // 'append'
+ && lk != 79 // 'array'
+ && lk != 80 // 'as'
+ && lk != 81 // 'ascending'
+ && lk != 82 // 'at'
+ && lk != 83 // 'attribute'
+ && lk != 84 // 'base-uri'
+ && lk != 85 // 'before'
+ && lk != 86 // 'boundary-space'
+ && lk != 89 // 'case'
+ && lk != 90 // 'cast'
+ && lk != 91 // 'castable'
+ && lk != 92 // 'catch'
+ && lk != 94 // 'child'
+ && lk != 95 // 'collation'
+ && lk != 97 // 'comment'
+ && lk != 98 // 'constraint'
+ && lk != 99 // 'construction'
+ && lk != 102 // 'context'
+ && lk != 104 // 'copy'
+ && lk != 105 // 'copy-namespaces'
+ && lk != 106 // 'count'
+ && lk != 107 // 'decimal-format'
+ && lk != 109 // 'declare'
+ && lk != 110 // 'default'
+ && lk != 111 // 'delete'
+ && lk != 112 // 'descendant'
+ && lk != 113 // 'descendant-or-self'
+ && lk != 114 // 'descending'
+ && lk != 119 // 'div'
+ && lk != 120 // 'document'
+ && lk != 121 // 'document-node'
+ && lk != 122 // 'element'
+ && lk != 123 // 'else'
+ && lk != 124 // 'empty'
+ && lk != 125 // 'empty-sequence'
+ && lk != 126 // 'encoding'
+ && lk != 127 // 'end'
+ && lk != 129 // 'eq'
+ && lk != 130 // 'every'
+ && lk != 132 // 'except'
+ && lk != 134 // 'external'
+ && lk != 135 // 'false'
+ && lk != 136 // 'first'
+ && lk != 137 // 'following'
+ && lk != 138 // 'following-sibling'
+ && lk != 142 // 'from'
+ && lk != 143 // 'ft-option'
+ && lk != 147 // 'function'
+ && lk != 148 // 'ge'
+ && lk != 150 // 'group'
+ && lk != 152 // 'gt'
+ && lk != 153 // 'idiv'
+ && lk != 155 // 'import'
+ && lk != 156 // 'in'
+ && lk != 157 // 'index'
+ && lk != 161 // 'insert'
+ && lk != 162 // 'instance'
+ && lk != 163 // 'integrity'
+ && lk != 164 // 'intersect'
+ && lk != 165 // 'into'
+ && lk != 166 // 'is'
+ && lk != 167 // 'item'
+ && lk != 168 // 'json'
+ && lk != 169 // 'json-item'
+ && lk != 170 // 'jsoniq'
+ && lk != 173 // 'last'
+ && lk != 174 // 'lax'
+ && lk != 175 // 'le'
+ && lk != 179 // 'loop'
+ && lk != 181 // 'lt'
+ && lk != 183 // 'mod'
+ && lk != 184 // 'modify'
+ && lk != 185 // 'module'
+ && lk != 187 // 'namespace'
+ && lk != 188 // 'namespace-node'
+ && lk != 189 // 'ne'
+ && lk != 194 // 'node'
+ && lk != 195 // 'nodes'
+ && lk != 196 // 'not'
+ && lk != 197 // 'null'
+ && lk != 198 // 'object'
+ && lk != 202 // 'only'
+ && lk != 203 // 'option'
+ && lk != 204 // 'or'
+ && lk != 205 // 'order'
+ && lk != 206 // 'ordered'
+ && lk != 207 // 'ordering'
+ && lk != 210 // 'parent'
+ && lk != 216 // 'preceding'
+ && lk != 217 // 'preceding-sibling'
+ && lk != 220 // 'processing-instruction'
+ && lk != 222 // 'rename'
+ && lk != 223 // 'replace'
+ && lk != 224 // 'return'
+ && lk != 225 // 'returning'
+ && lk != 226 // 'revalidation'
+ && lk != 228 // 'satisfies'
+ && lk != 229 // 'schema'
+ && lk != 230 // 'schema-attribute'
+ && lk != 231 // 'schema-element'
+ && lk != 232 // 'score'
+ && lk != 233 // 'select'
+ && lk != 234 // 'self'
+ && lk != 239 // 'sliding'
+ && lk != 240 // 'some'
+ && lk != 241 // 'stable'
+ && lk != 242 // 'start'
+ && lk != 245 // 'strict'
+ && lk != 247 // 'structured-item'
+ && lk != 249 // 'text'
+ && lk != 253 // 'to'
+ && lk != 254 // 'treat'
+ && lk != 255 // 'true'
+ && lk != 257 // 'tumbling'
+ && lk != 258 // 'type'
+ && lk != 260 // 'union'
+ && lk != 262 // 'unordered'
+ && lk != 263 // 'updating'
+ && lk != 266 // 'validate'
+ && lk != 267 // 'value'
+ && lk != 269 // 'version'
+ && lk != 272 // 'where'
+ && lk != 276 // 'with'
+ && lk != 283 // '{|'
+ && lk != 10009 // '{' NCName^Token
+ && lk != 14935 // 'break' '#'
+ && lk != 14951 // 'continue' '#'
+ && lk != 14981 // 'exit' '#'
+ && lk != 14987 // 'for' '#'
+ && lk != 15002 // 'if' '#'
+ && lk != 15025 // 'let' '#'
+ && lk != 15096 // 'switch' '#'
+ && lk != 15104 // 'try' '#'
+ && lk != 15107 // 'typeswitch' '#'
+ && lk != 15116 // 'variable' '#'
+ && lk != 15121 // 'while' '#'
+ && lk != 16011 // 'for' '$'
+ && lk != 16049 // 'let' '$'
+ && lk != 16140 // 'variable' '$'
+ && lk != 18007 // 'break' '('
+ && lk != 18023 // 'continue' '('
+ && lk != 18053 // 'exit' '('
+ && lk != 18059 // 'for' '('
+ && lk != 18074 // 'if' '('
+ && lk != 18097 // 'let' '('
+ && lk != 18168 // 'switch' '('
+ && lk != 18176 // 'try' '('
+ && lk != 18179 // 'typeswitch' '('
+ && lk != 18188 // 'variable' '('
+ && lk != 91735 // 'break' 'loop'
+ && lk != 91751 // 'continue' 'loop'
+ && lk != 115333 // 'exit' 'returning'
+ && lk != 118961 // 'let' 'score'
+ && lk != 122507 // 'for' 'sliding'
+ && lk != 131723 // 'for' 'tumbling'
+ && lk != 144128 // 'try' '{'
+ && lk != 147225) // '{' '}'
+ {
+ lk = memoized(9, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ApplyStatement();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_AssignStatement();
+ lk = -2;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_BlockStatement();
+ lk = -3;
+ }
+ catch (p3A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_VarDeclStatement();
+ lk = -12;
+ }
+ catch (p12A)
+ {
+ lk = -13;
+ }
+ }
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(9, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -2:
+ parse_AssignStatement();
+ break;
+ case -3:
+ parse_BlockStatement();
+ break;
+ case 91735: // 'break' 'loop'
+ parse_BreakStatement();
+ break;
+ case 91751: // 'continue' 'loop'
+ parse_ContinueStatement();
+ break;
+ case 115333: // 'exit' 'returning'
+ parse_ExitStatement();
+ break;
+ case 16011: // 'for' '$'
+ case 16049: // 'let' '$'
+ case 118961: // 'let' 'score'
+ case 122507: // 'for' 'sliding'
+ case 131723: // 'for' 'tumbling'
+ parse_FLWORStatement();
+ break;
+ case 18074: // 'if' '('
+ parse_IfStatement();
+ break;
+ case 18168: // 'switch' '('
+ parse_SwitchStatement();
+ break;
+ case 144128: // 'try' '{'
+ parse_TryCatchStatement();
+ break;
+ case 18179: // 'typeswitch' '('
+ parse_TypeswitchStatement();
+ break;
+ case -12:
+ case 16140: // 'variable' '$'
+ parse_VarDeclStatement();
+ break;
+ case -13:
+ parse_WhileStatement();
+ break;
+ case 54: // ';'
+ parse_VoidStatement();
+ break;
+ default:
+ parse_ApplyStatement();
+ }
+ eventHandler.endNonterminal("Statement", e0);
+ }
+
+ function try_Statement()
+ {
+ switch (l1)
+ {
+ case 133: // 'exit'
+ lookahead2W(147); // S^WS | '#' | '(' | '(:' | 'returning'
+ break;
+ case 139: // 'for'
+ lookahead2W(179); // S^WS | '#' | '$' | '(' | '(:' | 'sliding' | 'tumbling'
+ break;
+ case 177: // 'let'
+ lookahead2W(166); // S^WS | '#' | '$' | '(' | '(:' | 'score'
+ break;
+ case 256: // 'try'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 268: // 'variable'
+ lookahead2W(143); // S^WS | '#' | '$' | '(' | '(:'
+ break;
+ case 281: // '{'
+ lookahead2W(282); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 31: // '$'
+ case 33: // '%'
+ lookahead2W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 87: // 'break'
+ case 103: // 'continue'
+ lookahead2W(145); // S^WS | '#' | '(' | '(:' | 'loop'
+ break;
+ case 154: // 'if'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ case 273: // 'while'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 6 // EQName^Token
+ && lk != 8 // IntegerLiteral
+ && lk != 9 // DecimalLiteral
+ && lk != 10 // DoubleLiteral
+ && lk != 11 // StringLiteral
+ && lk != 32 // '$$'
+ && lk != 35 // '('
+ && lk != 36 // '(#'
+ && lk != 41 // '+'
+ && lk != 43 // '-'
+ && lk != 47 // '/'
+ && lk != 48 // '//'
+ && lk != 54 // ';'
+ && lk != 55 // '<'
+ && lk != 56 // '<!--'
+ && lk != 60 // '<?'
+ && lk != 69 // '['
+ && lk != 71 // 'after'
+ && lk != 73 // 'allowing'
+ && lk != 74 // 'ancestor'
+ && lk != 75 // 'ancestor-or-self'
+ && lk != 76 // 'and'
+ && lk != 78 // 'append'
+ && lk != 79 // 'array'
+ && lk != 80 // 'as'
+ && lk != 81 // 'ascending'
+ && lk != 82 // 'at'
+ && lk != 83 // 'attribute'
+ && lk != 84 // 'base-uri'
+ && lk != 85 // 'before'
+ && lk != 86 // 'boundary-space'
+ && lk != 89 // 'case'
+ && lk != 90 // 'cast'
+ && lk != 91 // 'castable'
+ && lk != 92 // 'catch'
+ && lk != 94 // 'child'
+ && lk != 95 // 'collation'
+ && lk != 97 // 'comment'
+ && lk != 98 // 'constraint'
+ && lk != 99 // 'construction'
+ && lk != 102 // 'context'
+ && lk != 104 // 'copy'
+ && lk != 105 // 'copy-namespaces'
+ && lk != 106 // 'count'
+ && lk != 107 // 'decimal-format'
+ && lk != 109 // 'declare'
+ && lk != 110 // 'default'
+ && lk != 111 // 'delete'
+ && lk != 112 // 'descendant'
+ && lk != 113 // 'descendant-or-self'
+ && lk != 114 // 'descending'
+ && lk != 119 // 'div'
+ && lk != 120 // 'document'
+ && lk != 121 // 'document-node'
+ && lk != 122 // 'element'
+ && lk != 123 // 'else'
+ && lk != 124 // 'empty'
+ && lk != 125 // 'empty-sequence'
+ && lk != 126 // 'encoding'
+ && lk != 127 // 'end'
+ && lk != 129 // 'eq'
+ && lk != 130 // 'every'
+ && lk != 132 // 'except'
+ && lk != 134 // 'external'
+ && lk != 135 // 'false'
+ && lk != 136 // 'first'
+ && lk != 137 // 'following'
+ && lk != 138 // 'following-sibling'
+ && lk != 142 // 'from'
+ && lk != 143 // 'ft-option'
+ && lk != 147 // 'function'
+ && lk != 148 // 'ge'
+ && lk != 150 // 'group'
+ && lk != 152 // 'gt'
+ && lk != 153 // 'idiv'
+ && lk != 155 // 'import'
+ && lk != 156 // 'in'
+ && lk != 157 // 'index'
+ && lk != 161 // 'insert'
+ && lk != 162 // 'instance'
+ && lk != 163 // 'integrity'
+ && lk != 164 // 'intersect'
+ && lk != 165 // 'into'
+ && lk != 166 // 'is'
+ && lk != 167 // 'item'
+ && lk != 168 // 'json'
+ && lk != 169 // 'json-item'
+ && lk != 170 // 'jsoniq'
+ && lk != 173 // 'last'
+ && lk != 174 // 'lax'
+ && lk != 175 // 'le'
+ && lk != 179 // 'loop'
+ && lk != 181 // 'lt'
+ && lk != 183 // 'mod'
+ && lk != 184 // 'modify'
+ && lk != 185 // 'module'
+ && lk != 187 // 'namespace'
+ && lk != 188 // 'namespace-node'
+ && lk != 189 // 'ne'
+ && lk != 194 // 'node'
+ && lk != 195 // 'nodes'
+ && lk != 196 // 'not'
+ && lk != 197 // 'null'
+ && lk != 198 // 'object'
+ && lk != 202 // 'only'
+ && lk != 203 // 'option'
+ && lk != 204 // 'or'
+ && lk != 205 // 'order'
+ && lk != 206 // 'ordered'
+ && lk != 207 // 'ordering'
+ && lk != 210 // 'parent'
+ && lk != 216 // 'preceding'
+ && lk != 217 // 'preceding-sibling'
+ && lk != 220 // 'processing-instruction'
+ && lk != 222 // 'rename'
+ && lk != 223 // 'replace'
+ && lk != 224 // 'return'
+ && lk != 225 // 'returning'
+ && lk != 226 // 'revalidation'
+ && lk != 228 // 'satisfies'
+ && lk != 229 // 'schema'
+ && lk != 230 // 'schema-attribute'
+ && lk != 231 // 'schema-element'
+ && lk != 232 // 'score'
+ && lk != 233 // 'select'
+ && lk != 234 // 'self'
+ && lk != 239 // 'sliding'
+ && lk != 240 // 'some'
+ && lk != 241 // 'stable'
+ && lk != 242 // 'start'
+ && lk != 245 // 'strict'
+ && lk != 247 // 'structured-item'
+ && lk != 249 // 'text'
+ && lk != 253 // 'to'
+ && lk != 254 // 'treat'
+ && lk != 255 // 'true'
+ && lk != 257 // 'tumbling'
+ && lk != 258 // 'type'
+ && lk != 260 // 'union'
+ && lk != 262 // 'unordered'
+ && lk != 263 // 'updating'
+ && lk != 266 // 'validate'
+ && lk != 267 // 'value'
+ && lk != 269 // 'version'
+ && lk != 272 // 'where'
+ && lk != 276 // 'with'
+ && lk != 283 // '{|'
+ && lk != 10009 // '{' NCName^Token
+ && lk != 14935 // 'break' '#'
+ && lk != 14951 // 'continue' '#'
+ && lk != 14981 // 'exit' '#'
+ && lk != 14987 // 'for' '#'
+ && lk != 15002 // 'if' '#'
+ && lk != 15025 // 'let' '#'
+ && lk != 15096 // 'switch' '#'
+ && lk != 15104 // 'try' '#'
+ && lk != 15107 // 'typeswitch' '#'
+ && lk != 15116 // 'variable' '#'
+ && lk != 15121 // 'while' '#'
+ && lk != 16011 // 'for' '$'
+ && lk != 16049 // 'let' '$'
+ && lk != 16140 // 'variable' '$'
+ && lk != 18007 // 'break' '('
+ && lk != 18023 // 'continue' '('
+ && lk != 18053 // 'exit' '('
+ && lk != 18059 // 'for' '('
+ && lk != 18074 // 'if' '('
+ && lk != 18097 // 'let' '('
+ && lk != 18168 // 'switch' '('
+ && lk != 18176 // 'try' '('
+ && lk != 18179 // 'typeswitch' '('
+ && lk != 18188 // 'variable' '('
+ && lk != 91735 // 'break' 'loop'
+ && lk != 91751 // 'continue' 'loop'
+ && lk != 115333 // 'exit' 'returning'
+ && lk != 118961 // 'let' 'score'
+ && lk != 122507 // 'for' 'sliding'
+ && lk != 131723 // 'for' 'tumbling'
+ && lk != 144128 // 'try' '{'
+ && lk != 147225) // '{' '}'
+ {
+ lk = memoized(9, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ApplyStatement();
+ memoize(9, e0A, -1);
+ lk = -15;
+ }
+ catch (p1A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_AssignStatement();
+ memoize(9, e0A, -2);
+ lk = -15;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_BlockStatement();
+ memoize(9, e0A, -3);
+ lk = -15;
+ }
+ catch (p3A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_VarDeclStatement();
+ memoize(9, e0A, -12);
+ lk = -15;
+ }
+ catch (p12A)
+ {
+ lk = -13;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(9, e0A, -13);
+ }
+ }
+ }
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -2:
+ try_AssignStatement();
+ break;
+ case -3:
+ try_BlockStatement();
+ break;
+ case 91735: // 'break' 'loop'
+ try_BreakStatement();
+ break;
+ case 91751: // 'continue' 'loop'
+ try_ContinueStatement();
+ break;
+ case 115333: // 'exit' 'returning'
+ try_ExitStatement();
+ break;
+ case 16011: // 'for' '$'
+ case 16049: // 'let' '$'
+ case 118961: // 'let' 'score'
+ case 122507: // 'for' 'sliding'
+ case 131723: // 'for' 'tumbling'
+ try_FLWORStatement();
+ break;
+ case 18074: // 'if' '('
+ try_IfStatement();
+ break;
+ case 18168: // 'switch' '('
+ try_SwitchStatement();
+ break;
+ case 144128: // 'try' '{'
+ try_TryCatchStatement();
+ break;
+ case 18179: // 'typeswitch' '('
+ try_TypeswitchStatement();
+ break;
+ case -12:
+ case 16140: // 'variable' '$'
+ try_VarDeclStatement();
+ break;
+ case -13:
+ try_WhileStatement();
+ break;
+ case 54: // ';'
+ try_VoidStatement();
+ break;
+ case -15:
+ break;
+ default:
+ try_ApplyStatement();
+ }
+ }
+
+ function parse_ApplyStatement()
+ {
+ eventHandler.startNonterminal("ApplyStatement", e0);
+ parse_ExprSimple();
+ shift(54); // ';'
+ eventHandler.endNonterminal("ApplyStatement", e0);
+ }
+
+ function try_ApplyStatement()
+ {
+ try_ExprSimple();
+ shiftT(54); // ';'
+ }
+
+ function parse_AssignStatement()
+ {
+ eventHandler.startNonterminal("AssignStatement", e0);
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(54); // ';'
+ eventHandler.endNonterminal("AssignStatement", e0);
+ }
+
+ function try_AssignStatement()
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(28); // S^WS | '(:' | ':='
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(54); // ';'
+ }
+
+ function parse_BlockStatement()
+ {
+ eventHandler.startNonterminal("BlockStatement", e0);
+ shift(281); // '{'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statements();
+ shift(287); // '}'
+ eventHandler.endNonterminal("BlockStatement", e0);
+ }
+
+ function try_BlockStatement()
+ {
+ shiftT(281); // '{'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statements();
+ shiftT(287); // '}'
+ }
+
+ function parse_BreakStatement()
+ {
+ eventHandler.startNonterminal("BreakStatement", e0);
+ shift(87); // 'break'
+ lookahead1W(62); // S^WS | '(:' | 'loop'
+ shift(179); // 'loop'
+ lookahead1W(29); // S^WS | '(:' | ';'
+ shift(54); // ';'
+ eventHandler.endNonterminal("BreakStatement", e0);
+ }
+
+ function try_BreakStatement()
+ {
+ shiftT(87); // 'break'
+ lookahead1W(62); // S^WS | '(:' | 'loop'
+ shiftT(179); // 'loop'
+ lookahead1W(29); // S^WS | '(:' | ';'
+ shiftT(54); // ';'
+ }
+
+ function parse_ContinueStatement()
+ {
+ eventHandler.startNonterminal("ContinueStatement", e0);
+ shift(103); // 'continue'
+ lookahead1W(62); // S^WS | '(:' | 'loop'
+ shift(179); // 'loop'
+ lookahead1W(29); // S^WS | '(:' | ';'
+ shift(54); // ';'
+ eventHandler.endNonterminal("ContinueStatement", e0);
+ }
+
+ function try_ContinueStatement()
+ {
+ shiftT(103); // 'continue'
+ lookahead1W(62); // S^WS | '(:' | 'loop'
+ shiftT(179); // 'loop'
+ lookahead1W(29); // S^WS | '(:' | ';'
+ shiftT(54); // ';'
+ }
+
+ function parse_ExitStatement()
+ {
+ eventHandler.startNonterminal("ExitStatement", e0);
+ shift(133); // 'exit'
+ lookahead1W(74); // S^WS | '(:' | 'returning'
+ shift(225); // 'returning'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(54); // ';'
+ eventHandler.endNonterminal("ExitStatement", e0);
+ }
+
+ function try_ExitStatement()
+ {
+ shiftT(133); // 'exit'
+ lookahead1W(74); // S^WS | '(:' | 'returning'
+ shiftT(225); // 'returning'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(54); // ';'
+ }
+
+ function parse_FLWORStatement()
+ {
+ eventHandler.startNonterminal("FLWORStatement", e0);
+ parse_InitialClause();
+ for (;;)
+ {
+ lookahead1W(195); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 224) // 'return'
+ {
+ break;
+ }
+ whitespace();
+ parse_IntermediateClause();
+ }
+ whitespace();
+ parse_ReturnStatement();
+ eventHandler.endNonterminal("FLWORStatement", e0);
+ }
+
+ function try_FLWORStatement()
+ {
+ try_InitialClause();
+ for (;;)
+ {
+ lookahead1W(195); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 224) // 'return'
+ {
+ break;
+ }
+ try_IntermediateClause();
+ }
+ try_ReturnStatement();
+ }
+
+ function parse_ReturnStatement()
+ {
+ eventHandler.startNonterminal("ReturnStatement", e0);
+ shift(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("ReturnStatement", e0);
+ }
+
+ function try_ReturnStatement()
+ {
+ shiftT(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_IfStatement()
+ {
+ eventHandler.startNonterminal("IfStatement", e0);
+ shift(154); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ lookahead1W(80); // S^WS | '(:' | 'then'
+ shift(250); // 'then'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ lookahead1W(51); // S^WS | '(:' | 'else'
+ shift(123); // 'else'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("IfStatement", e0);
+ }
+
+ function try_IfStatement()
+ {
+ shiftT(154); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ lookahead1W(80); // S^WS | '(:' | 'then'
+ shiftT(250); // 'then'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ lookahead1W(51); // S^WS | '(:' | 'else'
+ shiftT(123); // 'else'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_SwitchStatement()
+ {
+ eventHandler.startNonterminal("SwitchStatement", e0);
+ shift(248); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_SwitchCaseStatement();
+ lookahead1W(117); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shift(110); // 'default'
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shift(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("SwitchStatement", e0);
+ }
+
+ function try_SwitchStatement()
+ {
+ shiftT(248); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ try_SwitchCaseStatement();
+ lookahead1W(117); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(110); // 'default'
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shiftT(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_SwitchCaseStatement()
+ {
+ eventHandler.startNonterminal("SwitchCaseStatement", e0);
+ for (;;)
+ {
+ shift(89); // 'case'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_SwitchCaseOperand();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shift(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("SwitchCaseStatement", e0);
+ }
+
+ function try_SwitchCaseStatement()
+ {
+ for (;;)
+ {
+ shiftT(89); // 'case'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_SwitchCaseOperand();
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_TryCatchStatement()
+ {
+ eventHandler.startNonterminal("TryCatchStatement", e0);
+ shift(256); // 'try'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockStatement();
+ for (;;)
+ {
+ lookahead1W(39); // S^WS | '(:' | 'catch'
+ shift(92); // 'catch'
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_CatchErrorList();
+ whitespace();
+ parse_BlockStatement();
+ lookahead1W(283); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 92: // 'catch'
+ lookahead2W(255); // Wildcard | EQName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 2652 // 'catch' Wildcard
+ && lk != 3164 // 'catch' EQName^Token
+ && lk != 36444 // 'catch' 'after'
+ && lk != 37468 // 'catch' 'allowing'
+ && lk != 37980 // 'catch' 'ancestor'
+ && lk != 38492 // 'catch' 'ancestor-or-self'
+ && lk != 39004 // 'catch' 'and'
+ && lk != 40028 // 'catch' 'append'
+ && lk != 40540 // 'catch' 'array'
+ && lk != 41052 // 'catch' 'as'
+ && lk != 41564 // 'catch' 'ascending'
+ && lk != 42076 // 'catch' 'at'
+ && lk != 42588 // 'catch' 'attribute'
+ && lk != 43100 // 'catch' 'base-uri'
+ && lk != 43612 // 'catch' 'before'
+ && lk != 44124 // 'catch' 'boundary-space'
+ && lk != 44636 // 'catch' 'break'
+ && lk != 45660 // 'catch' 'case'
+ && lk != 46172 // 'catch' 'cast'
+ && lk != 46684 // 'catch' 'castable'
+ && lk != 47196 // 'catch' 'catch'
+ && lk != 48220 // 'catch' 'child'
+ && lk != 48732 // 'catch' 'collation'
+ && lk != 49756 // 'catch' 'comment'
+ && lk != 50268 // 'catch' 'constraint'
+ && lk != 50780 // 'catch' 'construction'
+ && lk != 52316 // 'catch' 'context'
+ && lk != 52828 // 'catch' 'continue'
+ && lk != 53340 // 'catch' 'copy'
+ && lk != 53852 // 'catch' 'copy-namespaces'
+ && lk != 54364 // 'catch' 'count'
+ && lk != 54876 // 'catch' 'decimal-format'
+ && lk != 55900 // 'catch' 'declare'
+ && lk != 56412 // 'catch' 'default'
+ && lk != 56924 // 'catch' 'delete'
+ && lk != 57436 // 'catch' 'descendant'
+ && lk != 57948 // 'catch' 'descendant-or-self'
+ && lk != 58460 // 'catch' 'descending'
+ && lk != 61020 // 'catch' 'div'
+ && lk != 61532 // 'catch' 'document'
+ && lk != 62044 // 'catch' 'document-node'
+ && lk != 62556 // 'catch' 'element'
+ && lk != 63068 // 'catch' 'else'
+ && lk != 63580 // 'catch' 'empty'
+ && lk != 64092 // 'catch' 'empty-sequence'
+ && lk != 64604 // 'catch' 'encoding'
+ && lk != 65116 // 'catch' 'end'
+ && lk != 66140 // 'catch' 'eq'
+ && lk != 66652 // 'catch' 'every'
+ && lk != 67676 // 'catch' 'except'
+ && lk != 68188 // 'catch' 'exit'
+ && lk != 68700 // 'catch' 'external'
+ && lk != 69212 // 'catch' 'false'
+ && lk != 69724 // 'catch' 'first'
+ && lk != 70236 // 'catch' 'following'
+ && lk != 70748 // 'catch' 'following-sibling'
+ && lk != 71260 // 'catch' 'for'
+ && lk != 72796 // 'catch' 'from'
+ && lk != 73308 // 'catch' 'ft-option'
+ && lk != 75356 // 'catch' 'function'
+ && lk != 75868 // 'catch' 'ge'
+ && lk != 76892 // 'catch' 'group'
+ && lk != 77916 // 'catch' 'gt'
+ && lk != 78428 // 'catch' 'idiv'
+ && lk != 78940 // 'catch' 'if'
+ && lk != 79452 // 'catch' 'import'
+ && lk != 79964 // 'catch' 'in'
+ && lk != 80476 // 'catch' 'index'
+ && lk != 82524 // 'catch' 'insert'
+ && lk != 83036 // 'catch' 'instance'
+ && lk != 83548 // 'catch' 'integrity'
+ && lk != 84060 // 'catch' 'intersect'
+ && lk != 84572 // 'catch' 'into'
+ && lk != 85084 // 'catch' 'is'
+ && lk != 85596 // 'catch' 'item'
+ && lk != 86108 // 'catch' 'json'
+ && lk != 86620 // 'catch' 'json-item'
+ && lk != 87132 // 'catch' 'jsoniq'
+ && lk != 88668 // 'catch' 'last'
+ && lk != 89180 // 'catch' 'lax'
+ && lk != 89692 // 'catch' 'le'
+ && lk != 90716 // 'catch' 'let'
+ && lk != 91740 // 'catch' 'loop'
+ && lk != 92764 // 'catch' 'lt'
+ && lk != 93788 // 'catch' 'mod'
+ && lk != 94300 // 'catch' 'modify'
+ && lk != 94812 // 'catch' 'module'
+ && lk != 95836 // 'catch' 'namespace'
+ && lk != 96348 // 'catch' 'namespace-node'
+ && lk != 96860 // 'catch' 'ne'
+ && lk != 99420 // 'catch' 'node'
+ && lk != 99932 // 'catch' 'nodes'
+ && lk != 100956 // 'catch' 'null'
+ && lk != 101468 // 'catch' 'object'
+ && lk != 103516 // 'catch' 'only'
+ && lk != 104028 // 'catch' 'option'
+ && lk != 104540 // 'catch' 'or'
+ && lk != 105052 // 'catch' 'order'
+ && lk != 105564 // 'catch' 'ordered'
+ && lk != 106076 // 'catch' 'ordering'
+ && lk != 107612 // 'catch' 'parent'
+ && lk != 110684 // 'catch' 'preceding'
+ && lk != 111196 // 'catch' 'preceding-sibling'
+ && lk != 112732 // 'catch' 'processing-instruction'
+ && lk != 113756 // 'catch' 'rename'
+ && lk != 114268 // 'catch' 'replace'
+ && lk != 114780 // 'catch' 'return'
+ && lk != 115292 // 'catch' 'returning'
+ && lk != 115804 // 'catch' 'revalidation'
+ && lk != 116828 // 'catch' 'satisfies'
+ && lk != 117340 // 'catch' 'schema'
+ && lk != 117852 // 'catch' 'schema-attribute'
+ && lk != 118364 // 'catch' 'schema-element'
+ && lk != 118876 // 'catch' 'score'
+ && lk != 119388 // 'catch' 'select'
+ && lk != 119900 // 'catch' 'self'
+ && lk != 122460 // 'catch' 'sliding'
+ && lk != 122972 // 'catch' 'some'
+ && lk != 123484 // 'catch' 'stable'
+ && lk != 123996 // 'catch' 'start'
+ && lk != 125532 // 'catch' 'strict'
+ && lk != 126556 // 'catch' 'structured-item'
+ && lk != 127068 // 'catch' 'switch'
+ && lk != 127580 // 'catch' 'text'
+ && lk != 129628 // 'catch' 'to'
+ && lk != 130140 // 'catch' 'treat'
+ && lk != 130652 // 'catch' 'true'
+ && lk != 131164 // 'catch' 'try'
+ && lk != 131676 // 'catch' 'tumbling'
+ && lk != 132188 // 'catch' 'type'
+ && lk != 132700 // 'catch' 'typeswitch'
+ && lk != 133212 // 'catch' 'union'
+ && lk != 134236 // 'catch' 'unordered'
+ && lk != 134748 // 'catch' 'updating'
+ && lk != 136284 // 'catch' 'validate'
+ && lk != 136796 // 'catch' 'value'
+ && lk != 137308 // 'catch' 'variable'
+ && lk != 137820 // 'catch' 'version'
+ && lk != 139356 // 'catch' 'where'
+ && lk != 139868 // 'catch' 'while'
+ && lk != 141404) // 'catch' 'with'
+ {
+ break;
+ }
+ }
+ eventHandler.endNonterminal("TryCatchStatement", e0);
+ }
+
+ function try_TryCatchStatement()
+ {
+ shiftT(256); // 'try'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ try_BlockStatement();
+ for (;;)
+ {
+ lookahead1W(39); // S^WS | '(:' | 'catch'
+ shiftT(92); // 'catch'
+ lookahead1W(248); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ try_BlockStatement();
+ lookahead1W(283); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 92: // 'catch'
+ lookahead2W(255); // Wildcard | EQName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 2652 // 'catch' Wildcard
+ && lk != 3164 // 'catch' EQName^Token
+ && lk != 36444 // 'catch' 'after'
+ && lk != 37468 // 'catch' 'allowing'
+ && lk != 37980 // 'catch' 'ancestor'
+ && lk != 38492 // 'catch' 'ancestor-or-self'
+ && lk != 39004 // 'catch' 'and'
+ && lk != 40028 // 'catch' 'append'
+ && lk != 40540 // 'catch' 'array'
+ && lk != 41052 // 'catch' 'as'
+ && lk != 41564 // 'catch' 'ascending'
+ && lk != 42076 // 'catch' 'at'
+ && lk != 42588 // 'catch' 'attribute'
+ && lk != 43100 // 'catch' 'base-uri'
+ && lk != 43612 // 'catch' 'before'
+ && lk != 44124 // 'catch' 'boundary-space'
+ && lk != 44636 // 'catch' 'break'
+ && lk != 45660 // 'catch' 'case'
+ && lk != 46172 // 'catch' 'cast'
+ && lk != 46684 // 'catch' 'castable'
+ && lk != 47196 // 'catch' 'catch'
+ && lk != 48220 // 'catch' 'child'
+ && lk != 48732 // 'catch' 'collation'
+ && lk != 49756 // 'catch' 'comment'
+ && lk != 50268 // 'catch' 'constraint'
+ && lk != 50780 // 'catch' 'construction'
+ && lk != 52316 // 'catch' 'context'
+ && lk != 52828 // 'catch' 'continue'
+ && lk != 53340 // 'catch' 'copy'
+ && lk != 53852 // 'catch' 'copy-namespaces'
+ && lk != 54364 // 'catch' 'count'
+ && lk != 54876 // 'catch' 'decimal-format'
+ && lk != 55900 // 'catch' 'declare'
+ && lk != 56412 // 'catch' 'default'
+ && lk != 56924 // 'catch' 'delete'
+ && lk != 57436 // 'catch' 'descendant'
+ && lk != 57948 // 'catch' 'descendant-or-self'
+ && lk != 58460 // 'catch' 'descending'
+ && lk != 61020 // 'catch' 'div'
+ && lk != 61532 // 'catch' 'document'
+ && lk != 62044 // 'catch' 'document-node'
+ && lk != 62556 // 'catch' 'element'
+ && lk != 63068 // 'catch' 'else'
+ && lk != 63580 // 'catch' 'empty'
+ && lk != 64092 // 'catch' 'empty-sequence'
+ && lk != 64604 // 'catch' 'encoding'
+ && lk != 65116 // 'catch' 'end'
+ && lk != 66140 // 'catch' 'eq'
+ && lk != 66652 // 'catch' 'every'
+ && lk != 67676 // 'catch' 'except'
+ && lk != 68188 // 'catch' 'exit'
+ && lk != 68700 // 'catch' 'external'
+ && lk != 69212 // 'catch' 'false'
+ && lk != 69724 // 'catch' 'first'
+ && lk != 70236 // 'catch' 'following'
+ && lk != 70748 // 'catch' 'following-sibling'
+ && lk != 71260 // 'catch' 'for'
+ && lk != 72796 // 'catch' 'from'
+ && lk != 73308 // 'catch' 'ft-option'
+ && lk != 75356 // 'catch' 'function'
+ && lk != 75868 // 'catch' 'ge'
+ && lk != 76892 // 'catch' 'group'
+ && lk != 77916 // 'catch' 'gt'
+ && lk != 78428 // 'catch' 'idiv'
+ && lk != 78940 // 'catch' 'if'
+ && lk != 79452 // 'catch' 'import'
+ && lk != 79964 // 'catch' 'in'
+ && lk != 80476 // 'catch' 'index'
+ && lk != 82524 // 'catch' 'insert'
+ && lk != 83036 // 'catch' 'instance'
+ && lk != 83548 // 'catch' 'integrity'
+ && lk != 84060 // 'catch' 'intersect'
+ && lk != 84572 // 'catch' 'into'
+ && lk != 85084 // 'catch' 'is'
+ && lk != 85596 // 'catch' 'item'
+ && lk != 86108 // 'catch' 'json'
+ && lk != 86620 // 'catch' 'json-item'
+ && lk != 87132 // 'catch' 'jsoniq'
+ && lk != 88668 // 'catch' 'last'
+ && lk != 89180 // 'catch' 'lax'
+ && lk != 89692 // 'catch' 'le'
+ && lk != 90716 // 'catch' 'let'
+ && lk != 91740 // 'catch' 'loop'
+ && lk != 92764 // 'catch' 'lt'
+ && lk != 93788 // 'catch' 'mod'
+ && lk != 94300 // 'catch' 'modify'
+ && lk != 94812 // 'catch' 'module'
+ && lk != 95836 // 'catch' 'namespace'
+ && lk != 96348 // 'catch' 'namespace-node'
+ && lk != 96860 // 'catch' 'ne'
+ && lk != 99420 // 'catch' 'node'
+ && lk != 99932 // 'catch' 'nodes'
+ && lk != 100956 // 'catch' 'null'
+ && lk != 101468 // 'catch' 'object'
+ && lk != 103516 // 'catch' 'only'
+ && lk != 104028 // 'catch' 'option'
+ && lk != 104540 // 'catch' 'or'
+ && lk != 105052 // 'catch' 'order'
+ && lk != 105564 // 'catch' 'ordered'
+ && lk != 106076 // 'catch' 'ordering'
+ && lk != 107612 // 'catch' 'parent'
+ && lk != 110684 // 'catch' 'preceding'
+ && lk != 111196 // 'catch' 'preceding-sibling'
+ && lk != 112732 // 'catch' 'processing-instruction'
+ && lk != 113756 // 'catch' 'rename'
+ && lk != 114268 // 'catch' 'replace'
+ && lk != 114780 // 'catch' 'return'
+ && lk != 115292 // 'catch' 'returning'
+ && lk != 115804 // 'catch' 'revalidation'
+ && lk != 116828 // 'catch' 'satisfies'
+ && lk != 117340 // 'catch' 'schema'
+ && lk != 117852 // 'catch' 'schema-attribute'
+ && lk != 118364 // 'catch' 'schema-element'
+ && lk != 118876 // 'catch' 'score'
+ && lk != 119388 // 'catch' 'select'
+ && lk != 119900 // 'catch' 'self'
+ && lk != 122460 // 'catch' 'sliding'
+ && lk != 122972 // 'catch' 'some'
+ && lk != 123484 // 'catch' 'stable'
+ && lk != 123996 // 'catch' 'start'
+ && lk != 125532 // 'catch' 'strict'
+ && lk != 126556 // 'catch' 'structured-item'
+ && lk != 127068 // 'catch' 'switch'
+ && lk != 127580 // 'catch' 'text'
+ && lk != 129628 // 'catch' 'to'
+ && lk != 130140 // 'catch' 'treat'
+ && lk != 130652 // 'catch' 'true'
+ && lk != 131164 // 'catch' 'try'
+ && lk != 131676 // 'catch' 'tumbling'
+ && lk != 132188 // 'catch' 'type'
+ && lk != 132700 // 'catch' 'typeswitch'
+ && lk != 133212 // 'catch' 'union'
+ && lk != 134236 // 'catch' 'unordered'
+ && lk != 134748 // 'catch' 'updating'
+ && lk != 136284 // 'catch' 'validate'
+ && lk != 136796 // 'catch' 'value'
+ && lk != 137308 // 'catch' 'variable'
+ && lk != 137820 // 'catch' 'version'
+ && lk != 139356 // 'catch' 'where'
+ && lk != 139868 // 'catch' 'while'
+ && lk != 141404) // 'catch' 'with'
+ {
+ break;
+ }
+ }
+ }
+
+ function parse_TypeswitchStatement()
+ {
+ eventHandler.startNonterminal("TypeswitchStatement", e0);
+ shift(259); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_CaseStatement();
+ lookahead1W(117); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shift(110); // 'default'
+ lookahead1W(99); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ }
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shift(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("TypeswitchStatement", e0);
+ }
+
+ function try_TypeswitchStatement()
+ {
+ shiftT(259); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ for (;;)
+ {
+ lookahead1W(38); // S^WS | '(:' | 'case'
+ try_CaseStatement();
+ lookahead1W(117); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 89) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(110); // 'default'
+ lookahead1W(99); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shiftT(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_CaseStatement()
+ {
+ eventHandler.startNonterminal("CaseStatement", e0);
+ shift(89); // 'case'
+ lookahead1W(257); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shift(80); // 'as'
+ }
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shift(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("CaseStatement", e0);
+ }
+
+ function try_CaseStatement()
+ {
+ shiftT(89); // 'case'
+ lookahead1W(257); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(33); // S^WS | '(:' | 'as'
+ shiftT(80); // 'as'
+ }
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ lookahead1W(73); // S^WS | '(:' | 'return'
+ shiftT(224); // 'return'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_VarDeclStatement()
+ {
+ eventHandler.startNonterminal("VarDeclStatement", e0);
+ for (;;)
+ {
+ lookahead1W(102); // S^WS | '%' | '(:' | 'variable'
+ if (l1 != 33) // '%'
+ {
+ break;
+ }
+ whitespace();
+ parse_Annotation();
+ }
+ shift(268); // 'variable'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(172); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(155); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 53) // ':='
+ {
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(172); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(155); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 53) // ':='
+ {
+ shift(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ }
+ shift(54); // ';'
+ eventHandler.endNonterminal("VarDeclStatement", e0);
+ }
+
+ function try_VarDeclStatement()
+ {
+ for (;;)
+ {
+ lookahead1W(102); // S^WS | '%' | '(:' | 'variable'
+ if (l1 != 33) // '%'
+ {
+ break;
+ }
+ try_Annotation();
+ }
+ shiftT(268); // 'variable'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(172); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(155); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 53) // ':='
+ {
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(172); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 80) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(155); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 53) // ':='
+ {
+ shiftT(53); // ':='
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ }
+ shiftT(54); // ';'
+ }
+
+ function parse_WhileStatement()
+ {
+ eventHandler.startNonterminal("WhileStatement", e0);
+ shift(273); // 'while'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(38); // ')'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("WhileStatement", e0);
+ }
+
+ function try_WhileStatement()
+ {
+ shiftT(273); // 'while'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(35); // '('
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(38); // ')'
+ lookahead1W(270); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Statement();
+ }
+
+ function parse_VoidStatement()
+ {
+ eventHandler.startNonterminal("VoidStatement", e0);
+ shift(54); // ';'
+ eventHandler.endNonterminal("VoidStatement", e0);
+ }
+
+ function try_VoidStatement()
+ {
+ shiftT(54); // ';'
+ }
+
+ function parse_ExprSingle()
+ {
+ eventHandler.startNonterminal("ExprSingle", e0);
+ switch (l1)
+ {
+ case 139: // 'for'
+ lookahead2W(179); // S^WS | '#' | '$' | '(' | '(:' | 'sliding' | 'tumbling'
+ break;
+ case 177: // 'let'
+ lookahead2W(166); // S^WS | '#' | '$' | '(' | '(:' | 'score'
+ break;
+ case 256: // 'try'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 154: // 'if'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16011: // 'for' '$'
+ case 16049: // 'let' '$'
+ case 118961: // 'let' 'score'
+ case 122507: // 'for' 'sliding'
+ case 131723: // 'for' 'tumbling'
+ parse_FLWORExpr();
+ break;
+ case 18074: // 'if' '('
+ parse_IfExpr();
+ break;
+ case 18168: // 'switch' '('
+ parse_SwitchExpr();
+ break;
+ case 144128: // 'try' '{'
+ parse_TryCatchExpr();
+ break;
+ case 18179: // 'typeswitch' '('
+ parse_TypeswitchExpr();
+ break;
+ default:
+ parse_ExprSimple();
+ }
+ eventHandler.endNonterminal("ExprSingle", e0);
+ }
+
+ function try_ExprSingle()
+ {
+ switch (l1)
+ {
+ case 139: // 'for'
+ lookahead2W(179); // S^WS | '#' | '$' | '(' | '(:' | 'sliding' | 'tumbling'
+ break;
+ case 177: // 'let'
+ lookahead2W(166); // S^WS | '#' | '$' | '(' | '(:' | 'score'
+ break;
+ case 256: // 'try'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 154: // 'if'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16011: // 'for' '$'
+ case 16049: // 'let' '$'
+ case 118961: // 'let' 'score'
+ case 122507: // 'for' 'sliding'
+ case 131723: // 'for' 'tumbling'
+ try_FLWORExpr();
+ break;
+ case 18074: // 'if' '('
+ try_IfExpr();
+ break;
+ case 18168: // 'switch' '('
+ try_SwitchExpr();
+ break;
+ case 144128: // 'try' '{'
+ try_TryCatchExpr();
+ break;
+ case 18179: // 'typeswitch' '('
+ try_TypeswitchExpr();
+ break;
+ default:
+ try_ExprSimple();
+ }
+ }
+
+ function parse_ExprSimple()
+ {
+ eventHandler.startNonterminal("ExprSimple", e0);
+ switch (l1)
+ {
+ case 78: // 'append'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 161: // 'insert'
+ lookahead2W(275); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 223: // 'replace'
+ lookahead2W(170); // S^WS | '#' | '(' | '(:' | 'node' | 'value'
+ break;
+ case 111: // 'delete'
+ case 222: // 'rename'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 104: // 'copy'
+ case 130: // 'every'
+ case 240: // 'some'
+ lookahead2W(143); // S^WS | '#' | '$' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 17998 // 'append' '('
+ || lk == 18031 // 'delete' '('
+ || lk == 18081 // 'insert' '('
+ || lk == 18142 // 'rename' '('
+ || lk == 99439 // 'delete' 'node'
+ || lk == 99489 // 'insert' 'node'
+ || lk == 99550 // 'rename' 'node'
+ || lk == 99951 // 'delete' 'nodes'
+ || lk == 100001 // 'insert' 'nodes'
+ || lk == 136927) // 'replace' 'value'
+ {
+ lk = memoized(10, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_OrExpr();
+ lk = -2;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_InsertExpr();
+ lk = -3;
+ }
+ catch (p3A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_DeleteExpr();
+ lk = -4;
+ }
+ catch (p4A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_RenameExpr();
+ lk = -5;
+ }
+ catch (p5A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_ReplaceExpr();
+ lk = -6;
+ }
+ catch (p6A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONDeleteExpr();
+ lk = -8;
+ }
+ catch (p8A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONInsertExpr();
+ lk = -9;
+ }
+ catch (p9A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONRenameExpr();
+ lk = -10;
+ }
+ catch (p10A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONReplaceExpr();
+ lk = -11;
+ }
+ catch (p11A)
+ {
+ lk = -12;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(10, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 16002: // 'every' '$'
+ case 16112: // 'some' '$'
+ parse_QuantifiedExpr();
+ break;
+ case -3:
+ parse_InsertExpr();
+ break;
+ case -4:
+ parse_DeleteExpr();
+ break;
+ case -5:
+ parse_RenameExpr();
+ break;
+ case -6:
+ case 99551: // 'replace' 'node'
+ parse_ReplaceExpr();
+ break;
+ case 15976: // 'copy' '$'
+ parse_TransformExpr();
+ break;
+ case -8:
+ case 3183: // 'delete' EQName^Token
+ case 4207: // 'delete' IntegerLiteral
+ case 4719: // 'delete' DecimalLiteral
+ case 5231: // 'delete' DoubleLiteral
+ case 5743: // 'delete' StringLiteral
+ case 15983: // 'delete' '$'
+ case 16495: // 'delete' '$$'
+ case 17007: // 'delete' '%'
+ case 28271: // 'delete' '<'
+ case 28783: // 'delete' '<!--'
+ case 30831: // 'delete' '<?'
+ case 35439: // 'delete' '['
+ case 36463: // 'delete' 'after'
+ case 37487: // 'delete' 'allowing'
+ case 37999: // 'delete' 'ancestor'
+ case 38511: // 'delete' 'ancestor-or-self'
+ case 39023: // 'delete' 'and'
+ case 40047: // 'delete' 'append'
+ case 40559: // 'delete' 'array'
+ case 41071: // 'delete' 'as'
+ case 41583: // 'delete' 'ascending'
+ case 42095: // 'delete' 'at'
+ case 42607: // 'delete' 'attribute'
+ case 43119: // 'delete' 'base-uri'
+ case 43631: // 'delete' 'before'
+ case 44143: // 'delete' 'boundary-space'
+ case 44655: // 'delete' 'break'
+ case 45679: // 'delete' 'case'
+ case 46191: // 'delete' 'cast'
+ case 46703: // 'delete' 'castable'
+ case 47215: // 'delete' 'catch'
+ case 48239: // 'delete' 'child'
+ case 48751: // 'delete' 'collation'
+ case 49775: // 'delete' 'comment'
+ case 50287: // 'delete' 'constraint'
+ case 50799: // 'delete' 'construction'
+ case 52335: // 'delete' 'context'
+ case 52847: // 'delete' 'continue'
+ case 53359: // 'delete' 'copy'
+ case 53871: // 'delete' 'copy-namespaces'
+ case 54383: // 'delete' 'count'
+ case 54895: // 'delete' 'decimal-format'
+ case 55919: // 'delete' 'declare'
+ case 56431: // 'delete' 'default'
+ case 56943: // 'delete' 'delete'
+ case 57455: // 'delete' 'descendant'
+ case 57967: // 'delete' 'descendant-or-self'
+ case 58479: // 'delete' 'descending'
+ case 61039: // 'delete' 'div'
+ case 61551: // 'delete' 'document'
+ case 62063: // 'delete' 'document-node'
+ case 62575: // 'delete' 'element'
+ case 63087: // 'delete' 'else'
+ case 63599: // 'delete' 'empty'
+ case 64111: // 'delete' 'empty-sequence'
+ case 64623: // 'delete' 'encoding'
+ case 65135: // 'delete' 'end'
+ case 66159: // 'delete' 'eq'
+ case 66671: // 'delete' 'every'
+ case 67695: // 'delete' 'except'
+ case 68207: // 'delete' 'exit'
+ case 68719: // 'delete' 'external'
+ case 69231: // 'delete' 'false'
+ case 69743: // 'delete' 'first'
+ case 70255: // 'delete' 'following'
+ case 70767: // 'delete' 'following-sibling'
+ case 71279: // 'delete' 'for'
+ case 72815: // 'delete' 'from'
+ case 73327: // 'delete' 'ft-option'
+ case 75375: // 'delete' 'function'
+ case 75887: // 'delete' 'ge'
+ case 76911: // 'delete' 'group'
+ case 77935: // 'delete' 'gt'
+ case 78447: // 'delete' 'idiv'
+ case 78959: // 'delete' 'if'
+ case 79471: // 'delete' 'import'
+ case 79983: // 'delete' 'in'
+ case 80495: // 'delete' 'index'
+ case 82543: // 'delete' 'insert'
+ case 83055: // 'delete' 'instance'
+ case 83567: // 'delete' 'integrity'
+ case 84079: // 'delete' 'intersect'
+ case 84591: // 'delete' 'into'
+ case 85103: // 'delete' 'is'
+ case 85615: // 'delete' 'item'
+ case 86127: // 'delete' 'json'
+ case 86639: // 'delete' 'json-item'
+ case 87151: // 'delete' 'jsoniq'
+ case 88687: // 'delete' 'last'
+ case 89199: // 'delete' 'lax'
+ case 89711: // 'delete' 'le'
+ case 90735: // 'delete' 'let'
+ case 91759: // 'delete' 'loop'
+ case 92783: // 'delete' 'lt'
+ case 93807: // 'delete' 'mod'
+ case 94319: // 'delete' 'modify'
+ case 94831: // 'delete' 'module'
+ case 95855: // 'delete' 'namespace'
+ case 96367: // 'delete' 'namespace-node'
+ case 96879: // 'delete' 'ne'
+ case 100975: // 'delete' 'null'
+ case 101487: // 'delete' 'object'
+ case 103535: // 'delete' 'only'
+ case 104047: // 'delete' 'option'
+ case 104559: // 'delete' 'or'
+ case 105071: // 'delete' 'order'
+ case 105583: // 'delete' 'ordered'
+ case 106095: // 'delete' 'ordering'
+ case 107631: // 'delete' 'parent'
+ case 110703: // 'delete' 'preceding'
+ case 111215: // 'delete' 'preceding-sibling'
+ case 112751: // 'delete' 'processing-instruction'
+ case 113775: // 'delete' 'rename'
+ case 114287: // 'delete' 'replace'
+ case 114799: // 'delete' 'return'
+ case 115311: // 'delete' 'returning'
+ case 115823: // 'delete' 'revalidation'
+ case 116847: // 'delete' 'satisfies'
+ case 117359: // 'delete' 'schema'
+ case 117871: // 'delete' 'schema-attribute'
+ case 118383: // 'delete' 'schema-element'
+ case 118895: // 'delete' 'score'
+ case 119407: // 'delete' 'select'
+ case 119919: // 'delete' 'self'
+ case 122479: // 'delete' 'sliding'
+ case 122991: // 'delete' 'some'
+ case 123503: // 'delete' 'stable'
+ case 124015: // 'delete' 'start'
+ case 125551: // 'delete' 'strict'
+ case 126575: // 'delete' 'structured-item'
+ case 127087: // 'delete' 'switch'
+ case 127599: // 'delete' 'text'
+ case 129647: // 'delete' 'to'
+ case 130159: // 'delete' 'treat'
+ case 130671: // 'delete' 'true'
+ case 131183: // 'delete' 'try'
+ case 131695: // 'delete' 'tumbling'
+ case 132207: // 'delete' 'type'
+ case 132719: // 'delete' 'typeswitch'
+ case 133231: // 'delete' 'union'
+ case 134255: // 'delete' 'unordered'
+ case 134767: // 'delete' 'updating'
+ case 136303: // 'delete' 'validate'
+ case 136815: // 'delete' 'value'
+ case 137327: // 'delete' 'variable'
+ case 137839: // 'delete' 'version'
+ case 139375: // 'delete' 'where'
+ case 139887: // 'delete' 'while'
+ case 141423: // 'delete' 'with'
+ case 143983: // 'delete' '{'
+ case 145007: // 'delete' '{|'
+ parse_JSONDeleteExpr();
+ break;
+ case -9:
+ case 3233: // 'insert' EQName^Token
+ case 4257: // 'insert' IntegerLiteral
+ case 4769: // 'insert' DecimalLiteral
+ case 5281: // 'insert' DoubleLiteral
+ case 5793: // 'insert' StringLiteral
+ case 9889: // 'insert' NCName^Token
+ case 16033: // 'insert' '$'
+ case 16545: // 'insert' '$$'
+ case 17057: // 'insert' '%'
+ case 18593: // 'insert' '(#'
+ case 21153: // 'insert' '+'
+ case 22177: // 'insert' '-'
+ case 24225: // 'insert' '/'
+ case 24737: // 'insert' '//'
+ case 28321: // 'insert' '<'
+ case 28833: // 'insert' '<!--'
+ case 30881: // 'insert' '<?'
+ case 35489: // 'insert' '['
+ case 36513: // 'insert' 'after'
+ case 37537: // 'insert' 'allowing'
+ case 38049: // 'insert' 'ancestor'
+ case 38561: // 'insert' 'ancestor-or-self'
+ case 39073: // 'insert' 'and'
+ case 40097: // 'insert' 'append'
+ case 40609: // 'insert' 'array'
+ case 41121: // 'insert' 'as'
+ case 41633: // 'insert' 'ascending'
+ case 42145: // 'insert' 'at'
+ case 42657: // 'insert' 'attribute'
+ case 43169: // 'insert' 'base-uri'
+ case 43681: // 'insert' 'before'
+ case 44193: // 'insert' 'boundary-space'
+ case 44705: // 'insert' 'break'
+ case 45729: // 'insert' 'case'
+ case 46241: // 'insert' 'cast'
+ case 46753: // 'insert' 'castable'
+ case 47265: // 'insert' 'catch'
+ case 48289: // 'insert' 'child'
+ case 48801: // 'insert' 'collation'
+ case 49825: // 'insert' 'comment'
+ case 50337: // 'insert' 'constraint'
+ case 50849: // 'insert' 'construction'
+ case 52385: // 'insert' 'context'
+ case 52897: // 'insert' 'continue'
+ case 53409: // 'insert' 'copy'
+ case 53921: // 'insert' 'copy-namespaces'
+ case 54433: // 'insert' 'count'
+ case 54945: // 'insert' 'decimal-format'
+ case 55969: // 'insert' 'declare'
+ case 56481: // 'insert' 'default'
+ case 56993: // 'insert' 'delete'
+ case 57505: // 'insert' 'descendant'
+ case 58017: // 'insert' 'descendant-or-self'
+ case 58529: // 'insert' 'descending'
+ case 61089: // 'insert' 'div'
+ case 61601: // 'insert' 'document'
+ case 62113: // 'insert' 'document-node'
+ case 62625: // 'insert' 'element'
+ case 63137: // 'insert' 'else'
+ case 63649: // 'insert' 'empty'
+ case 64161: // 'insert' 'empty-sequence'
+ case 64673: // 'insert' 'encoding'
+ case 65185: // 'insert' 'end'
+ case 66209: // 'insert' 'eq'
+ case 66721: // 'insert' 'every'
+ case 67745: // 'insert' 'except'
+ case 68257: // 'insert' 'exit'
+ case 68769: // 'insert' 'external'
+ case 69281: // 'insert' 'false'
+ case 69793: // 'insert' 'first'
+ case 70305: // 'insert' 'following'
+ case 70817: // 'insert' 'following-sibling'
+ case 71329: // 'insert' 'for'
+ case 72865: // 'insert' 'from'
+ case 73377: // 'insert' 'ft-option'
+ case 75425: // 'insert' 'function'
+ case 75937: // 'insert' 'ge'
+ case 76961: // 'insert' 'group'
+ case 77985: // 'insert' 'gt'
+ case 78497: // 'insert' 'idiv'
+ case 79009: // 'insert' 'if'
+ case 79521: // 'insert' 'import'
+ case 80033: // 'insert' 'in'
+ case 80545: // 'insert' 'index'
+ case 82593: // 'insert' 'insert'
+ case 83105: // 'insert' 'instance'
+ case 83617: // 'insert' 'integrity'
+ case 84129: // 'insert' 'intersect'
+ case 84641: // 'insert' 'into'
+ case 85153: // 'insert' 'is'
+ case 85665: // 'insert' 'item'
+ case 86177: // 'insert' 'json'
+ case 86689: // 'insert' 'json-item'
+ case 87201: // 'insert' 'jsoniq'
+ case 88737: // 'insert' 'last'
+ case 89249: // 'insert' 'lax'
+ case 89761: // 'insert' 'le'
+ case 90785: // 'insert' 'let'
+ case 91809: // 'insert' 'loop'
+ case 92833: // 'insert' 'lt'
+ case 93857: // 'insert' 'mod'
+ case 94369: // 'insert' 'modify'
+ case 94881: // 'insert' 'module'
+ case 95905: // 'insert' 'namespace'
+ case 96417: // 'insert' 'namespace-node'
+ case 96929: // 'insert' 'ne'
+ case 100513: // 'insert' 'not'
+ case 101025: // 'insert' 'null'
+ case 101537: // 'insert' 'object'
+ case 103585: // 'insert' 'only'
+ case 104097: // 'insert' 'option'
+ case 104609: // 'insert' 'or'
+ case 105121: // 'insert' 'order'
+ case 105633: // 'insert' 'ordered'
+ case 106145: // 'insert' 'ordering'
+ case 107681: // 'insert' 'parent'
+ case 110753: // 'insert' 'preceding'
+ case 111265: // 'insert' 'preceding-sibling'
+ case 112801: // 'insert' 'processing-instruction'
+ case 113825: // 'insert' 'rename'
+ case 114337: // 'insert' 'replace'
+ case 114849: // 'insert' 'return'
+ case 115361: // 'insert' 'returning'
+ case 115873: // 'insert' 'revalidation'
+ case 116897: // 'insert' 'satisfies'
+ case 117409: // 'insert' 'schema'
+ case 117921: // 'insert' 'schema-attribute'
+ case 118433: // 'insert' 'schema-element'
+ case 118945: // 'insert' 'score'
+ case 119457: // 'insert' 'select'
+ case 119969: // 'insert' 'self'
+ case 122529: // 'insert' 'sliding'
+ case 123041: // 'insert' 'some'
+ case 123553: // 'insert' 'stable'
+ case 124065: // 'insert' 'start'
+ case 125601: // 'insert' 'strict'
+ case 126625: // 'insert' 'structured-item'
+ case 127137: // 'insert' 'switch'
+ case 127649: // 'insert' 'text'
+ case 129697: // 'insert' 'to'
+ case 130209: // 'insert' 'treat'
+ case 130721: // 'insert' 'true'
+ case 131233: // 'insert' 'try'
+ case 131745: // 'insert' 'tumbling'
+ case 132257: // 'insert' 'type'
+ case 132769: // 'insert' 'typeswitch'
+ case 133281: // 'insert' 'union'
+ case 134305: // 'insert' 'unordered'
+ case 134817: // 'insert' 'updating'
+ case 136353: // 'insert' 'validate'
+ case 136865: // 'insert' 'value'
+ case 137377: // 'insert' 'variable'
+ case 137889: // 'insert' 'version'
+ case 139425: // 'insert' 'where'
+ case 139937: // 'insert' 'while'
+ case 141473: // 'insert' 'with'
+ case 144033: // 'insert' '{'
+ case 145057: // 'insert' '{|'
+ parse_JSONInsertExpr();
+ break;
+ case -10:
+ case 3294: // 'rename' EQName^Token
+ case 4318: // 'rename' IntegerLiteral
+ case 4830: // 'rename' DecimalLiteral
+ case 5342: // 'rename' DoubleLiteral
+ case 5854: // 'rename' StringLiteral
+ case 16094: // 'rename' '$'
+ case 16606: // 'rename' '$$'
+ case 17118: // 'rename' '%'
+ case 28382: // 'rename' '<'
+ case 28894: // 'rename' '<!--'
+ case 30942: // 'rename' '<?'
+ case 35550: // 'rename' '['
+ case 36574: // 'rename' 'after'
+ case 37598: // 'rename' 'allowing'
+ case 38110: // 'rename' 'ancestor'
+ case 38622: // 'rename' 'ancestor-or-self'
+ case 39134: // 'rename' 'and'
+ case 40158: // 'rename' 'append'
+ case 40670: // 'rename' 'array'
+ case 41182: // 'rename' 'as'
+ case 41694: // 'rename' 'ascending'
+ case 42206: // 'rename' 'at'
+ case 42718: // 'rename' 'attribute'
+ case 43230: // 'rename' 'base-uri'
+ case 43742: // 'rename' 'before'
+ case 44254: // 'rename' 'boundary-space'
+ case 44766: // 'rename' 'break'
+ case 45790: // 'rename' 'case'
+ case 46302: // 'rename' 'cast'
+ case 46814: // 'rename' 'castable'
+ case 47326: // 'rename' 'catch'
+ case 48350: // 'rename' 'child'
+ case 48862: // 'rename' 'collation'
+ case 49886: // 'rename' 'comment'
+ case 50398: // 'rename' 'constraint'
+ case 50910: // 'rename' 'construction'
+ case 52446: // 'rename' 'context'
+ case 52958: // 'rename' 'continue'
+ case 53470: // 'rename' 'copy'
+ case 53982: // 'rename' 'copy-namespaces'
+ case 54494: // 'rename' 'count'
+ case 55006: // 'rename' 'decimal-format'
+ case 56030: // 'rename' 'declare'
+ case 56542: // 'rename' 'default'
+ case 57054: // 'rename' 'delete'
+ case 57566: // 'rename' 'descendant'
+ case 58078: // 'rename' 'descendant-or-self'
+ case 58590: // 'rename' 'descending'
+ case 61150: // 'rename' 'div'
+ case 61662: // 'rename' 'document'
+ case 62174: // 'rename' 'document-node'
+ case 62686: // 'rename' 'element'
+ case 63198: // 'rename' 'else'
+ case 63710: // 'rename' 'empty'
+ case 64222: // 'rename' 'empty-sequence'
+ case 64734: // 'rename' 'encoding'
+ case 65246: // 'rename' 'end'
+ case 66270: // 'rename' 'eq'
+ case 66782: // 'rename' 'every'
+ case 67806: // 'rename' 'except'
+ case 68318: // 'rename' 'exit'
+ case 68830: // 'rename' 'external'
+ case 69342: // 'rename' 'false'
+ case 69854: // 'rename' 'first'
+ case 70366: // 'rename' 'following'
+ case 70878: // 'rename' 'following-sibling'
+ case 71390: // 'rename' 'for'
+ case 72926: // 'rename' 'from'
+ case 73438: // 'rename' 'ft-option'
+ case 75486: // 'rename' 'function'
+ case 75998: // 'rename' 'ge'
+ case 77022: // 'rename' 'group'
+ case 78046: // 'rename' 'gt'
+ case 78558: // 'rename' 'idiv'
+ case 79070: // 'rename' 'if'
+ case 79582: // 'rename' 'import'
+ case 80094: // 'rename' 'in'
+ case 80606: // 'rename' 'index'
+ case 82654: // 'rename' 'insert'
+ case 83166: // 'rename' 'instance'
+ case 83678: // 'rename' 'integrity'
+ case 84190: // 'rename' 'intersect'
+ case 84702: // 'rename' 'into'
+ case 85214: // 'rename' 'is'
+ case 85726: // 'rename' 'item'
+ case 86238: // 'rename' 'json'
+ case 86750: // 'rename' 'json-item'
+ case 87262: // 'rename' 'jsoniq'
+ case 88798: // 'rename' 'last'
+ case 89310: // 'rename' 'lax'
+ case 89822: // 'rename' 'le'
+ case 90846: // 'rename' 'let'
+ case 91870: // 'rename' 'loop'
+ case 92894: // 'rename' 'lt'
+ case 93918: // 'rename' 'mod'
+ case 94430: // 'rename' 'modify'
+ case 94942: // 'rename' 'module'
+ case 95966: // 'rename' 'namespace'
+ case 96478: // 'rename' 'namespace-node'
+ case 96990: // 'rename' 'ne'
+ case 100062: // 'rename' 'nodes'
+ case 101086: // 'rename' 'null'
+ case 101598: // 'rename' 'object'
+ case 103646: // 'rename' 'only'
+ case 104158: // 'rename' 'option'
+ case 104670: // 'rename' 'or'
+ case 105182: // 'rename' 'order'
+ case 105694: // 'rename' 'ordered'
+ case 106206: // 'rename' 'ordering'
+ case 107742: // 'rename' 'parent'
+ case 110814: // 'rename' 'preceding'
+ case 111326: // 'rename' 'preceding-sibling'
+ case 112862: // 'rename' 'processing-instruction'
+ case 113886: // 'rename' 'rename'
+ case 114398: // 'rename' 'replace'
+ case 114910: // 'rename' 'return'
+ case 115422: // 'rename' 'returning'
+ case 115934: // 'rename' 'revalidation'
+ case 116958: // 'rename' 'satisfies'
+ case 117470: // 'rename' 'schema'
+ case 117982: // 'rename' 'schema-attribute'
+ case 118494: // 'rename' 'schema-element'
+ case 119006: // 'rename' 'score'
+ case 119518: // 'rename' 'select'
+ case 120030: // 'rename' 'self'
+ case 122590: // 'rename' 'sliding'
+ case 123102: // 'rename' 'some'
+ case 123614: // 'rename' 'stable'
+ case 124126: // 'rename' 'start'
+ case 125662: // 'rename' 'strict'
+ case 126686: // 'rename' 'structured-item'
+ case 127198: // 'rename' 'switch'
+ case 127710: // 'rename' 'text'
+ case 129758: // 'rename' 'to'
+ case 130270: // 'rename' 'treat'
+ case 130782: // 'rename' 'true'
+ case 131294: // 'rename' 'try'
+ case 131806: // 'rename' 'tumbling'
+ case 132318: // 'rename' 'type'
+ case 132830: // 'rename' 'typeswitch'
+ case 133342: // 'rename' 'union'
+ case 134366: // 'rename' 'unordered'
+ case 134878: // 'rename' 'updating'
+ case 136414: // 'rename' 'validate'
+ case 136926: // 'rename' 'value'
+ case 137438: // 'rename' 'variable'
+ case 137950: // 'rename' 'version'
+ case 139486: // 'rename' 'where'
+ case 139998: // 'rename' 'while'
+ case 141534: // 'rename' 'with'
+ case 144094: // 'rename' '{'
+ case 145118: // 'rename' '{|'
+ parse_JSONRenameExpr();
+ break;
+ case -11:
+ parse_JSONReplaceExpr();
+ break;
+ case -12:
+ case 3150: // 'append' EQName^Token
+ case 4174: // 'append' IntegerLiteral
+ case 4686: // 'append' DecimalLiteral
+ case 5198: // 'append' DoubleLiteral
+ case 5710: // 'append' StringLiteral
+ case 15950: // 'append' '$'
+ case 16462: // 'append' '$$'
+ case 16974: // 'append' '%'
+ case 18510: // 'append' '(#'
+ case 21070: // 'append' '+'
+ case 22094: // 'append' '-'
+ case 24142: // 'append' '/'
+ case 24654: // 'append' '//'
+ case 28238: // 'append' '<'
+ case 28750: // 'append' '<!--'
+ case 30798: // 'append' '<?'
+ case 35406: // 'append' '['
+ case 36430: // 'append' 'after'
+ case 37454: // 'append' 'allowing'
+ case 37966: // 'append' 'ancestor'
+ case 38478: // 'append' 'ancestor-or-self'
+ case 38990: // 'append' 'and'
+ case 40014: // 'append' 'append'
+ case 40526: // 'append' 'array'
+ case 41038: // 'append' 'as'
+ case 41550: // 'append' 'ascending'
+ case 42062: // 'append' 'at'
+ case 42574: // 'append' 'attribute'
+ case 43086: // 'append' 'base-uri'
+ case 43598: // 'append' 'before'
+ case 44110: // 'append' 'boundary-space'
+ case 44622: // 'append' 'break'
+ case 45646: // 'append' 'case'
+ case 46158: // 'append' 'cast'
+ case 46670: // 'append' 'castable'
+ case 47182: // 'append' 'catch'
+ case 48206: // 'append' 'child'
+ case 48718: // 'append' 'collation'
+ case 49742: // 'append' 'comment'
+ case 50254: // 'append' 'constraint'
+ case 50766: // 'append' 'construction'
+ case 52302: // 'append' 'context'
+ case 52814: // 'append' 'continue'
+ case 53326: // 'append' 'copy'
+ case 53838: // 'append' 'copy-namespaces'
+ case 54350: // 'append' 'count'
+ case 54862: // 'append' 'decimal-format'
+ case 55886: // 'append' 'declare'
+ case 56398: // 'append' 'default'
+ case 56910: // 'append' 'delete'
+ case 57422: // 'append' 'descendant'
+ case 57934: // 'append' 'descendant-or-self'
+ case 58446: // 'append' 'descending'
+ case 61006: // 'append' 'div'
+ case 61518: // 'append' 'document'
+ case 62030: // 'append' 'document-node'
+ case 62542: // 'append' 'element'
+ case 63054: // 'append' 'else'
+ case 63566: // 'append' 'empty'
+ case 64078: // 'append' 'empty-sequence'
+ case 64590: // 'append' 'encoding'
+ case 65102: // 'append' 'end'
+ case 66126: // 'append' 'eq'
+ case 66638: // 'append' 'every'
+ case 67662: // 'append' 'except'
+ case 68174: // 'append' 'exit'
+ case 68686: // 'append' 'external'
+ case 69198: // 'append' 'false'
+ case 69710: // 'append' 'first'
+ case 70222: // 'append' 'following'
+ case 70734: // 'append' 'following-sibling'
+ case 71246: // 'append' 'for'
+ case 72782: // 'append' 'from'
+ case 73294: // 'append' 'ft-option'
+ case 75342: // 'append' 'function'
+ case 75854: // 'append' 'ge'
+ case 76878: // 'append' 'group'
+ case 77902: // 'append' 'gt'
+ case 78414: // 'append' 'idiv'
+ case 78926: // 'append' 'if'
+ case 79438: // 'append' 'import'
+ case 79950: // 'append' 'in'
+ case 80462: // 'append' 'index'
+ case 82510: // 'append' 'insert'
+ case 83022: // 'append' 'instance'
+ case 83534: // 'append' 'integrity'
+ case 84046: // 'append' 'intersect'
+ case 84558: // 'append' 'into'
+ case 85070: // 'append' 'is'
+ case 85582: // 'append' 'item'
+ case 86094: // 'append' 'json'
+ case 86606: // 'append' 'json-item'
+ case 87118: // 'append' 'jsoniq'
+ case 88654: // 'append' 'last'
+ case 89166: // 'append' 'lax'
+ case 89678: // 'append' 'le'
+ case 90702: // 'append' 'let'
+ case 91726: // 'append' 'loop'
+ case 92750: // 'append' 'lt'
+ case 93774: // 'append' 'mod'
+ case 94286: // 'append' 'modify'
+ case 94798: // 'append' 'module'
+ case 95822: // 'append' 'namespace'
+ case 96334: // 'append' 'namespace-node'
+ case 96846: // 'append' 'ne'
+ case 99406: // 'append' 'node'
+ case 99918: // 'append' 'nodes'
+ case 100430: // 'append' 'not'
+ case 100942: // 'append' 'null'
+ case 101454: // 'append' 'object'
+ case 103502: // 'append' 'only'
+ case 104014: // 'append' 'option'
+ case 104526: // 'append' 'or'
+ case 105038: // 'append' 'order'
+ case 105550: // 'append' 'ordered'
+ case 106062: // 'append' 'ordering'
+ case 107598: // 'append' 'parent'
+ case 110670: // 'append' 'preceding'
+ case 111182: // 'append' 'preceding-sibling'
+ case 112718: // 'append' 'processing-instruction'
+ case 113742: // 'append' 'rename'
+ case 114254: // 'append' 'replace'
+ case 114766: // 'append' 'return'
+ case 115278: // 'append' 'returning'
+ case 115790: // 'append' 'revalidation'
+ case 116814: // 'append' 'satisfies'
+ case 117326: // 'append' 'schema'
+ case 117838: // 'append' 'schema-attribute'
+ case 118350: // 'append' 'schema-element'
+ case 118862: // 'append' 'score'
+ case 119374: // 'append' 'select'
+ case 119886: // 'append' 'self'
+ case 122446: // 'append' 'sliding'
+ case 122958: // 'append' 'some'
+ case 123470: // 'append' 'stable'
+ case 123982: // 'append' 'start'
+ case 125518: // 'append' 'strict'
+ case 126542: // 'append' 'structured-item'
+ case 127054: // 'append' 'switch'
+ case 127566: // 'append' 'text'
+ case 129614: // 'append' 'to'
+ case 130126: // 'append' 'treat'
+ case 130638: // 'append' 'true'
+ case 131150: // 'append' 'try'
+ case 131662: // 'append' 'tumbling'
+ case 132174: // 'append' 'type'
+ case 132686: // 'append' 'typeswitch'
+ case 133198: // 'append' 'union'
+ case 134222: // 'append' 'unordered'
+ case 134734: // 'append' 'updating'
+ case 136270: // 'append' 'validate'
+ case 136782: // 'append' 'value'
+ case 137294: // 'append' 'variable'
+ case 137806: // 'append' 'version'
+ case 139342: // 'append' 'where'
+ case 139854: // 'append' 'while'
+ case 141390: // 'append' 'with'
+ case 143950: // 'append' '{'
+ case 144974: // 'append' '{|'
+ parse_JSONAppendExpr();
+ break;
+ default:
+ parse_OrExpr();
+ }
+ eventHandler.endNonterminal("ExprSimple", e0);
+ }
+
+ function try_ExprSimple()
+ {
+ switch (l1)
+ {
+ case 78: // 'append'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 161: // 'insert'
+ lookahead2W(275); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 223: // 'replace'
+ lookahead2W(170); // S^WS | '#' | '(' | '(:' | 'node' | 'value'
+ break;
+ case 111: // 'delete'
+ case 222: // 'rename'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 104: // 'copy'
+ case 130: // 'every'
+ case 240: // 'some'
+ lookahead2W(143); // S^WS | '#' | '$' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 17998 // 'append' '('
+ || lk == 18031 // 'delete' '('
+ || lk == 18081 // 'insert' '('
+ || lk == 18142 // 'rename' '('
+ || lk == 99439 // 'delete' 'node'
+ || lk == 99489 // 'insert' 'node'
+ || lk == 99550 // 'rename' 'node'
+ || lk == 99951 // 'delete' 'nodes'
+ || lk == 100001 // 'insert' 'nodes'
+ || lk == 136927) // 'replace' 'value'
+ {
+ lk = memoized(10, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_OrExpr();
+ memoize(10, e0A, -2);
+ lk = -13;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_InsertExpr();
+ memoize(10, e0A, -3);
+ lk = -13;
+ }
+ catch (p3A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_DeleteExpr();
+ memoize(10, e0A, -4);
+ lk = -13;
+ }
+ catch (p4A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_RenameExpr();
+ memoize(10, e0A, -5);
+ lk = -13;
+ }
+ catch (p5A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_ReplaceExpr();
+ memoize(10, e0A, -6);
+ lk = -13;
+ }
+ catch (p6A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONDeleteExpr();
+ memoize(10, e0A, -8);
+ lk = -13;
+ }
+ catch (p8A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONInsertExpr();
+ memoize(10, e0A, -9);
+ lk = -13;
+ }
+ catch (p9A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONRenameExpr();
+ memoize(10, e0A, -10);
+ lk = -13;
+ }
+ catch (p10A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_JSONReplaceExpr();
+ memoize(10, e0A, -11);
+ lk = -13;
+ }
+ catch (p11A)
+ {
+ lk = -12;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(10, e0A, -12);
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ switch (lk)
+ {
+ case 16002: // 'every' '$'
+ case 16112: // 'some' '$'
+ try_QuantifiedExpr();
+ break;
+ case -3:
+ try_InsertExpr();
+ break;
+ case -4:
+ try_DeleteExpr();
+ break;
+ case -5:
+ try_RenameExpr();
+ break;
+ case -6:
+ case 99551: // 'replace' 'node'
+ try_ReplaceExpr();
+ break;
+ case 15976: // 'copy' '$'
+ try_TransformExpr();
+ break;
+ case -8:
+ case 3183: // 'delete' EQName^Token
+ case 4207: // 'delete' IntegerLiteral
+ case 4719: // 'delete' DecimalLiteral
+ case 5231: // 'delete' DoubleLiteral
+ case 5743: // 'delete' StringLiteral
+ case 15983: // 'delete' '$'
+ case 16495: // 'delete' '$$'
+ case 17007: // 'delete' '%'
+ case 28271: // 'delete' '<'
+ case 28783: // 'delete' '<!--'
+ case 30831: // 'delete' '<?'
+ case 35439: // 'delete' '['
+ case 36463: // 'delete' 'after'
+ case 37487: // 'delete' 'allowing'
+ case 37999: // 'delete' 'ancestor'
+ case 38511: // 'delete' 'ancestor-or-self'
+ case 39023: // 'delete' 'and'
+ case 40047: // 'delete' 'append'
+ case 40559: // 'delete' 'array'
+ case 41071: // 'delete' 'as'
+ case 41583: // 'delete' 'ascending'
+ case 42095: // 'delete' 'at'
+ case 42607: // 'delete' 'attribute'
+ case 43119: // 'delete' 'base-uri'
+ case 43631: // 'delete' 'before'
+ case 44143: // 'delete' 'boundary-space'
+ case 44655: // 'delete' 'break'
+ case 45679: // 'delete' 'case'
+ case 46191: // 'delete' 'cast'
+ case 46703: // 'delete' 'castable'
+ case 47215: // 'delete' 'catch'
+ case 48239: // 'delete' 'child'
+ case 48751: // 'delete' 'collation'
+ case 49775: // 'delete' 'comment'
+ case 50287: // 'delete' 'constraint'
+ case 50799: // 'delete' 'construction'
+ case 52335: // 'delete' 'context'
+ case 52847: // 'delete' 'continue'
+ case 53359: // 'delete' 'copy'
+ case 53871: // 'delete' 'copy-namespaces'
+ case 54383: // 'delete' 'count'
+ case 54895: // 'delete' 'decimal-format'
+ case 55919: // 'delete' 'declare'
+ case 56431: // 'delete' 'default'
+ case 56943: // 'delete' 'delete'
+ case 57455: // 'delete' 'descendant'
+ case 57967: // 'delete' 'descendant-or-self'
+ case 58479: // 'delete' 'descending'
+ case 61039: // 'delete' 'div'
+ case 61551: // 'delete' 'document'
+ case 62063: // 'delete' 'document-node'
+ case 62575: // 'delete' 'element'
+ case 63087: // 'delete' 'else'
+ case 63599: // 'delete' 'empty'
+ case 64111: // 'delete' 'empty-sequence'
+ case 64623: // 'delete' 'encoding'
+ case 65135: // 'delete' 'end'
+ case 66159: // 'delete' 'eq'
+ case 66671: // 'delete' 'every'
+ case 67695: // 'delete' 'except'
+ case 68207: // 'delete' 'exit'
+ case 68719: // 'delete' 'external'
+ case 69231: // 'delete' 'false'
+ case 69743: // 'delete' 'first'
+ case 70255: // 'delete' 'following'
+ case 70767: // 'delete' 'following-sibling'
+ case 71279: // 'delete' 'for'
+ case 72815: // 'delete' 'from'
+ case 73327: // 'delete' 'ft-option'
+ case 75375: // 'delete' 'function'
+ case 75887: // 'delete' 'ge'
+ case 76911: // 'delete' 'group'
+ case 77935: // 'delete' 'gt'
+ case 78447: // 'delete' 'idiv'
+ case 78959: // 'delete' 'if'
+ case 79471: // 'delete' 'import'
+ case 79983: // 'delete' 'in'
+ case 80495: // 'delete' 'index'
+ case 82543: // 'delete' 'insert'
+ case 83055: // 'delete' 'instance'
+ case 83567: // 'delete' 'integrity'
+ case 84079: // 'delete' 'intersect'
+ case 84591: // 'delete' 'into'
+ case 85103: // 'delete' 'is'
+ case 85615: // 'delete' 'item'
+ case 86127: // 'delete' 'json'
+ case 86639: // 'delete' 'json-item'
+ case 87151: // 'delete' 'jsoniq'
+ case 88687: // 'delete' 'last'
+ case 89199: // 'delete' 'lax'
+ case 89711: // 'delete' 'le'
+ case 90735: // 'delete' 'let'
+ case 91759: // 'delete' 'loop'
+ case 92783: // 'delete' 'lt'
+ case 93807: // 'delete' 'mod'
+ case 94319: // 'delete' 'modify'
+ case 94831: // 'delete' 'module'
+ case 95855: // 'delete' 'namespace'
+ case 96367: // 'delete' 'namespace-node'
+ case 96879: // 'delete' 'ne'
+ case 100975: // 'delete' 'null'
+ case 101487: // 'delete' 'object'
+ case 103535: // 'delete' 'only'
+ case 104047: // 'delete' 'option'
+ case 104559: // 'delete' 'or'
+ case 105071: // 'delete' 'order'
+ case 105583: // 'delete' 'ordered'
+ case 106095: // 'delete' 'ordering'
+ case 107631: // 'delete' 'parent'
+ case 110703: // 'delete' 'preceding'
+ case 111215: // 'delete' 'preceding-sibling'
+ case 112751: // 'delete' 'processing-instruction'
+ case 113775: // 'delete' 'rename'
+ case 114287: // 'delete' 'replace'
+ case 114799: // 'delete' 'return'
+ case 115311: // 'delete' 'returning'
+ case 115823: // 'delete' 'revalidation'
+ case 116847: // 'delete' 'satisfies'
+ case 117359: // 'delete' 'schema'
+ case 117871: // 'delete' 'schema-attribute'
+ case 118383: // 'delete' 'schema-element'
+ case 118895: // 'delete' 'score'
+ case 119407: // 'delete' 'select'
+ case 119919: // 'delete' 'self'
+ case 122479: // 'delete' 'sliding'
+ case 122991: // 'delete' 'some'
+ case 123503: // 'delete' 'stable'
+ case 124015: // 'delete' 'start'
+ case 125551: // 'delete' 'strict'
+ case 126575: // 'delete' 'structured-item'
+ case 127087: // 'delete' 'switch'
+ case 127599: // 'delete' 'text'
+ case 129647: // 'delete' 'to'
+ case 130159: // 'delete' 'treat'
+ case 130671: // 'delete' 'true'
+ case 131183: // 'delete' 'try'
+ case 131695: // 'delete' 'tumbling'
+ case 132207: // 'delete' 'type'
+ case 132719: // 'delete' 'typeswitch'
+ case 133231: // 'delete' 'union'
+ case 134255: // 'delete' 'unordered'
+ case 134767: // 'delete' 'updating'
+ case 136303: // 'delete' 'validate'
+ case 136815: // 'delete' 'value'
+ case 137327: // 'delete' 'variable'
+ case 137839: // 'delete' 'version'
+ case 139375: // 'delete' 'where'
+ case 139887: // 'delete' 'while'
+ case 141423: // 'delete' 'with'
+ case 143983: // 'delete' '{'
+ case 145007: // 'delete' '{|'
+ try_JSONDeleteExpr();
+ break;
+ case -9:
+ case 3233: // 'insert' EQName^Token
+ case 4257: // 'insert' IntegerLiteral
+ case 4769: // 'insert' DecimalLiteral
+ case 5281: // 'insert' DoubleLiteral
+ case 5793: // 'insert' StringLiteral
+ case 9889: // 'insert' NCName^Token
+ case 16033: // 'insert' '$'
+ case 16545: // 'insert' '$$'
+ case 17057: // 'insert' '%'
+ case 18593: // 'insert' '(#'
+ case 21153: // 'insert' '+'
+ case 22177: // 'insert' '-'
+ case 24225: // 'insert' '/'
+ case 24737: // 'insert' '//'
+ case 28321: // 'insert' '<'
+ case 28833: // 'insert' '<!--'
+ case 30881: // 'insert' '<?'
+ case 35489: // 'insert' '['
+ case 36513: // 'insert' 'after'
+ case 37537: // 'insert' 'allowing'
+ case 38049: // 'insert' 'ancestor'
+ case 38561: // 'insert' 'ancestor-or-self'
+ case 39073: // 'insert' 'and'
+ case 40097: // 'insert' 'append'
+ case 40609: // 'insert' 'array'
+ case 41121: // 'insert' 'as'
+ case 41633: // 'insert' 'ascending'
+ case 42145: // 'insert' 'at'
+ case 42657: // 'insert' 'attribute'
+ case 43169: // 'insert' 'base-uri'
+ case 43681: // 'insert' 'before'
+ case 44193: // 'insert' 'boundary-space'
+ case 44705: // 'insert' 'break'
+ case 45729: // 'insert' 'case'
+ case 46241: // 'insert' 'cast'
+ case 46753: // 'insert' 'castable'
+ case 47265: // 'insert' 'catch'
+ case 48289: // 'insert' 'child'
+ case 48801: // 'insert' 'collation'
+ case 49825: // 'insert' 'comment'
+ case 50337: // 'insert' 'constraint'
+ case 50849: // 'insert' 'construction'
+ case 52385: // 'insert' 'context'
+ case 52897: // 'insert' 'continue'
+ case 53409: // 'insert' 'copy'
+ case 53921: // 'insert' 'copy-namespaces'
+ case 54433: // 'insert' 'count'
+ case 54945: // 'insert' 'decimal-format'
+ case 55969: // 'insert' 'declare'
+ case 56481: // 'insert' 'default'
+ case 56993: // 'insert' 'delete'
+ case 57505: // 'insert' 'descendant'
+ case 58017: // 'insert' 'descendant-or-self'
+ case 58529: // 'insert' 'descending'
+ case 61089: // 'insert' 'div'
+ case 61601: // 'insert' 'document'
+ case 62113: // 'insert' 'document-node'
+ case 62625: // 'insert' 'element'
+ case 63137: // 'insert' 'else'
+ case 63649: // 'insert' 'empty'
+ case 64161: // 'insert' 'empty-sequence'
+ case 64673: // 'insert' 'encoding'
+ case 65185: // 'insert' 'end'
+ case 66209: // 'insert' 'eq'
+ case 66721: // 'insert' 'every'
+ case 67745: // 'insert' 'except'
+ case 68257: // 'insert' 'exit'
+ case 68769: // 'insert' 'external'
+ case 69281: // 'insert' 'false'
+ case 69793: // 'insert' 'first'
+ case 70305: // 'insert' 'following'
+ case 70817: // 'insert' 'following-sibling'
+ case 71329: // 'insert' 'for'
+ case 72865: // 'insert' 'from'
+ case 73377: // 'insert' 'ft-option'
+ case 75425: // 'insert' 'function'
+ case 75937: // 'insert' 'ge'
+ case 76961: // 'insert' 'group'
+ case 77985: // 'insert' 'gt'
+ case 78497: // 'insert' 'idiv'
+ case 79009: // 'insert' 'if'
+ case 79521: // 'insert' 'import'
+ case 80033: // 'insert' 'in'
+ case 80545: // 'insert' 'index'
+ case 82593: // 'insert' 'insert'
+ case 83105: // 'insert' 'instance'
+ case 83617: // 'insert' 'integrity'
+ case 84129: // 'insert' 'intersect'
+ case 84641: // 'insert' 'into'
+ case 85153: // 'insert' 'is'
+ case 85665: // 'insert' 'item'
+ case 86177: // 'insert' 'json'
+ case 86689: // 'insert' 'json-item'
+ case 87201: // 'insert' 'jsoniq'
+ case 88737: // 'insert' 'last'
+ case 89249: // 'insert' 'lax'
+ case 89761: // 'insert' 'le'
+ case 90785: // 'insert' 'let'
+ case 91809: // 'insert' 'loop'
+ case 92833: // 'insert' 'lt'
+ case 93857: // 'insert' 'mod'
+ case 94369: // 'insert' 'modify'
+ case 94881: // 'insert' 'module'
+ case 95905: // 'insert' 'namespace'
+ case 96417: // 'insert' 'namespace-node'
+ case 96929: // 'insert' 'ne'
+ case 100513: // 'insert' 'not'
+ case 101025: // 'insert' 'null'
+ case 101537: // 'insert' 'object'
+ case 103585: // 'insert' 'only'
+ case 104097: // 'insert' 'option'
+ case 104609: // 'insert' 'or'
+ case 105121: // 'insert' 'order'
+ case 105633: // 'insert' 'ordered'
+ case 106145: // 'insert' 'ordering'
+ case 107681: // 'insert' 'parent'
+ case 110753: // 'insert' 'preceding'
+ case 111265: // 'insert' 'preceding-sibling'
+ case 112801: // 'insert' 'processing-instruction'
+ case 113825: // 'insert' 'rename'
+ case 114337: // 'insert' 'replace'
+ case 114849: // 'insert' 'return'
+ case 115361: // 'insert' 'returning'
+ case 115873: // 'insert' 'revalidation'
+ case 116897: // 'insert' 'satisfies'
+ case 117409: // 'insert' 'schema'
+ case 117921: // 'insert' 'schema-attribute'
+ case 118433: // 'insert' 'schema-element'
+ case 118945: // 'insert' 'score'
+ case 119457: // 'insert' 'select'
+ case 119969: // 'insert' 'self'
+ case 122529: // 'insert' 'sliding'
+ case 123041: // 'insert' 'some'
+ case 123553: // 'insert' 'stable'
+ case 124065: // 'insert' 'start'
+ case 125601: // 'insert' 'strict'
+ case 126625: // 'insert' 'structured-item'
+ case 127137: // 'insert' 'switch'
+ case 127649: // 'insert' 'text'
+ case 129697: // 'insert' 'to'
+ case 130209: // 'insert' 'treat'
+ case 130721: // 'insert' 'true'
+ case 131233: // 'insert' 'try'
+ case 131745: // 'insert' 'tumbling'
+ case 132257: // 'insert' 'type'
+ case 132769: // 'insert' 'typeswitch'
+ case 133281: // 'insert' 'union'
+ case 134305: // 'insert' 'unordered'
+ case 134817: // 'insert' 'updating'
+ case 136353: // 'insert' 'validate'
+ case 136865: // 'insert' 'value'
+ case 137377: // 'insert' 'variable'
+ case 137889: // 'insert' 'version'
+ case 139425: // 'insert' 'where'
+ case 139937: // 'insert' 'while'
+ case 141473: // 'insert' 'with'
+ case 144033: // 'insert' '{'
+ case 145057: // 'insert' '{|'
+ try_JSONInsertExpr();
+ break;
+ case -10:
+ case 3294: // 'rename' EQName^Token
+ case 4318: // 'rename' IntegerLiteral
+ case 4830: // 'rename' DecimalLiteral
+ case 5342: // 'rename' DoubleLiteral
+ case 5854: // 'rename' StringLiteral
+ case 16094: // 'rename' '$'
+ case 16606: // 'rename' '$$'
+ case 17118: // 'rename' '%'
+ case 28382: // 'rename' '<'
+ case 28894: // 'rename' '<!--'
+ case 30942: // 'rename' '<?'
+ case 35550: // 'rename' '['
+ case 36574: // 'rename' 'after'
+ case 37598: // 'rename' 'allowing'
+ case 38110: // 'rename' 'ancestor'
+ case 38622: // 'rename' 'ancestor-or-self'
+ case 39134: // 'rename' 'and'
+ case 40158: // 'rename' 'append'
+ case 40670: // 'rename' 'array'
+ case 41182: // 'rename' 'as'
+ case 41694: // 'rename' 'ascending'
+ case 42206: // 'rename' 'at'
+ case 42718: // 'rename' 'attribute'
+ case 43230: // 'rename' 'base-uri'
+ case 43742: // 'rename' 'before'
+ case 44254: // 'rename' 'boundary-space'
+ case 44766: // 'rename' 'break'
+ case 45790: // 'rename' 'case'
+ case 46302: // 'rename' 'cast'
+ case 46814: // 'rename' 'castable'
+ case 47326: // 'rename' 'catch'
+ case 48350: // 'rename' 'child'
+ case 48862: // 'rename' 'collation'
+ case 49886: // 'rename' 'comment'
+ case 50398: // 'rename' 'constraint'
+ case 50910: // 'rename' 'construction'
+ case 52446: // 'rename' 'context'
+ case 52958: // 'rename' 'continue'
+ case 53470: // 'rename' 'copy'
+ case 53982: // 'rename' 'copy-namespaces'
+ case 54494: // 'rename' 'count'
+ case 55006: // 'rename' 'decimal-format'
+ case 56030: // 'rename' 'declare'
+ case 56542: // 'rename' 'default'
+ case 57054: // 'rename' 'delete'
+ case 57566: // 'rename' 'descendant'
+ case 58078: // 'rename' 'descendant-or-self'
+ case 58590: // 'rename' 'descending'
+ case 61150: // 'rename' 'div'
+ case 61662: // 'rename' 'document'
+ case 62174: // 'rename' 'document-node'
+ case 62686: // 'rename' 'element'
+ case 63198: // 'rename' 'else'
+ case 63710: // 'rename' 'empty'
+ case 64222: // 'rename' 'empty-sequence'
+ case 64734: // 'rename' 'encoding'
+ case 65246: // 'rename' 'end'
+ case 66270: // 'rename' 'eq'
+ case 66782: // 'rename' 'every'
+ case 67806: // 'rename' 'except'
+ case 68318: // 'rename' 'exit'
+ case 68830: // 'rename' 'external'
+ case 69342: // 'rename' 'false'
+ case 69854: // 'rename' 'first'
+ case 70366: // 'rename' 'following'
+ case 70878: // 'rename' 'following-sibling'
+ case 71390: // 'rename' 'for'
+ case 72926: // 'rename' 'from'
+ case 73438: // 'rename' 'ft-option'
+ case 75486: // 'rename' 'function'
+ case 75998: // 'rename' 'ge'
+ case 77022: // 'rename' 'group'
+ case 78046: // 'rename' 'gt'
+ case 78558: // 'rename' 'idiv'
+ case 79070: // 'rename' 'if'
+ case 79582: // 'rename' 'import'
+ case 80094: // 'rename' 'in'
+ case 80606: // 'rename' 'index'
+ case 82654: // 'rename' 'insert'
+ case 83166: // 'rename' 'instance'
+ case 83678: // 'rename' 'integrity'
+ case 84190: // 'rename' 'intersect'
+ case 84702: // 'rename' 'into'
+ case 85214: // 'rename' 'is'
+ case 85726: // 'rename' 'item'
+ case 86238: // 'rename' 'json'
+ case 86750: // 'rename' 'json-item'
+ case 87262: // 'rename' 'jsoniq'
+ case 88798: // 'rename' 'last'
+ case 89310: // 'rename' 'lax'
+ case 89822: // 'rename' 'le'
+ case 90846: // 'rename' 'let'
+ case 91870: // 'rename' 'loop'
+ case 92894: // 'rename' 'lt'
+ case 93918: // 'rename' 'mod'
+ case 94430: // 'rename' 'modify'
+ case 94942: // 'rename' 'module'
+ case 95966: // 'rename' 'namespace'
+ case 96478: // 'rename' 'namespace-node'
+ case 96990: // 'rename' 'ne'
+ case 100062: // 'rename' 'nodes'
+ case 101086: // 'rename' 'null'
+ case 101598: // 'rename' 'object'
+ case 103646: // 'rename' 'only'
+ case 104158: // 'rename' 'option'
+ case 104670: // 'rename' 'or'
+ case 105182: // 'rename' 'order'
+ case 105694: // 'rename' 'ordered'
+ case 106206: // 'rename' 'ordering'
+ case 107742: // 'rename' 'parent'
+ case 110814: // 'rename' 'preceding'
+ case 111326: // 'rename' 'preceding-sibling'
+ case 112862: // 'rename' 'processing-instruction'
+ case 113886: // 'rename' 'rename'
+ case 114398: // 'rename' 'replace'
+ case 114910: // 'rename' 'return'
+ case 115422: // 'rename' 'returning'
+ case 115934: // 'rename' 'revalidation'
+ case 116958: // 'rename' 'satisfies'
+ case 117470: // 'rename' 'schema'
+ case 117982: // 'rename' 'schema-attribute'
+ case 118494: // 'rename' 'schema-element'
+ case 119006: // 'rename' 'score'
+ case 119518: // 'rename' 'select'
+ case 120030: // 'rename' 'self'
+ case 122590: // 'rename' 'sliding'
+ case 123102: // 'rename' 'some'
+ case 123614: // 'rename' 'stable'
+ case 124126: // 'rename' 'start'
+ case 125662: // 'rename' 'strict'
+ case 126686: // 'rename' 'structured-item'
+ case 127198: // 'rename' 'switch'
+ case 127710: // 'rename' 'text'
+ case 129758: // 'rename' 'to'
+ case 130270: // 'rename' 'treat'
+ case 130782: // 'rename' 'true'
+ case 131294: // 'rename' 'try'
+ case 131806: // 'rename' 'tumbling'
+ case 132318: // 'rename' 'type'
+ case 132830: // 'rename' 'typeswitch'
+ case 133342: // 'rename' 'union'
+ case 134366: // 'rename' 'unordered'
+ case 134878: // 'rename' 'updating'
+ case 136414: // 'rename' 'validate'
+ case 136926: // 'rename' 'value'
+ case 137438: // 'rename' 'variable'
+ case 137950: // 'rename' 'version'
+ case 139486: // 'rename' 'where'
+ case 139998: // 'rename' 'while'
+ case 141534: // 'rename' 'with'
+ case 144094: // 'rename' '{'
+ case 145118: // 'rename' '{|'
+ try_JSONRenameExpr();
+ break;
+ case -11:
+ try_JSONReplaceExpr();
+ break;
+ case -12:
+ case 3150: // 'append' EQName^Token
+ case 4174: // 'append' IntegerLiteral
+ case 4686: // 'append' DecimalLiteral
+ case 5198: // 'append' DoubleLiteral
+ case 5710: // 'append' StringLiteral
+ case 15950: // 'append' '$'
+ case 16462: // 'append' '$$'
+ case 16974: // 'append' '%'
+ case 18510: // 'append' '(#'
+ case 21070: // 'append' '+'
+ case 22094: // 'append' '-'
+ case 24142: // 'append' '/'
+ case 24654: // 'append' '//'
+ case 28238: // 'append' '<'
+ case 28750: // 'append' '<!--'
+ case 30798: // 'append' '<?'
+ case 35406: // 'append' '['
+ case 36430: // 'append' 'after'
+ case 37454: // 'append' 'allowing'
+ case 37966: // 'append' 'ancestor'
+ case 38478: // 'append' 'ancestor-or-self'
+ case 38990: // 'append' 'and'
+ case 40014: // 'append' 'append'
+ case 40526: // 'append' 'array'
+ case 41038: // 'append' 'as'
+ case 41550: // 'append' 'ascending'
+ case 42062: // 'append' 'at'
+ case 42574: // 'append' 'attribute'
+ case 43086: // 'append' 'base-uri'
+ case 43598: // 'append' 'before'
+ case 44110: // 'append' 'boundary-space'
+ case 44622: // 'append' 'break'
+ case 45646: // 'append' 'case'
+ case 46158: // 'append' 'cast'
+ case 46670: // 'append' 'castable'
+ case 47182: // 'append' 'catch'
+ case 48206: // 'append' 'child'
+ case 48718: // 'append' 'collation'
+ case 49742: // 'append' 'comment'
+ case 50254: // 'append' 'constraint'
+ case 50766: // 'append' 'construction'
+ case 52302: // 'append' 'context'
+ case 52814: // 'append' 'continue'
+ case 53326: // 'append' 'copy'
+ case 53838: // 'append' 'copy-namespaces'
+ case 54350: // 'append' 'count'
+ case 54862: // 'append' 'decimal-format'
+ case 55886: // 'append' 'declare'
+ case 56398: // 'append' 'default'
+ case 56910: // 'append' 'delete'
+ case 57422: // 'append' 'descendant'
+ case 57934: // 'append' 'descendant-or-self'
+ case 58446: // 'append' 'descending'
+ case 61006: // 'append' 'div'
+ case 61518: // 'append' 'document'
+ case 62030: // 'append' 'document-node'
+ case 62542: // 'append' 'element'
+ case 63054: // 'append' 'else'
+ case 63566: // 'append' 'empty'
+ case 64078: // 'append' 'empty-sequence'
+ case 64590: // 'append' 'encoding'
+ case 65102: // 'append' 'end'
+ case 66126: // 'append' 'eq'
+ case 66638: // 'append' 'every'
+ case 67662: // 'append' 'except'
+ case 68174: // 'append' 'exit'
+ case 68686: // 'append' 'external'
+ case 69198: // 'append' 'false'
+ case 69710: // 'append' 'first'
+ case 70222: // 'append' 'following'
+ case 70734: // 'append' 'following-sibling'
+ case 71246: // 'append' 'for'
+ case 72782: // 'append' 'from'
+ case 73294: // 'append' 'ft-option'
+ case 75342: // 'append' 'function'
+ case 75854: // 'append' 'ge'
+ case 76878: // 'append' 'group'
+ case 77902: // 'append' 'gt'
+ case 78414: // 'append' 'idiv'
+ case 78926: // 'append' 'if'
+ case 79438: // 'append' 'import'
+ case 79950: // 'append' 'in'
+ case 80462: // 'append' 'index'
+ case 82510: // 'append' 'insert'
+ case 83022: // 'append' 'instance'
+ case 83534: // 'append' 'integrity'
+ case 84046: // 'append' 'intersect'
+ case 84558: // 'append' 'into'
+ case 85070: // 'append' 'is'
+ case 85582: // 'append' 'item'
+ case 86094: // 'append' 'json'
+ case 86606: // 'append' 'json-item'
+ case 87118: // 'append' 'jsoniq'
+ case 88654: // 'append' 'last'
+ case 89166: // 'append' 'lax'
+ case 89678: // 'append' 'le'
+ case 90702: // 'append' 'let'
+ case 91726: // 'append' 'loop'
+ case 92750: // 'append' 'lt'
+ case 93774: // 'append' 'mod'
+ case 94286: // 'append' 'modify'
+ case 94798: // 'append' 'module'
+ case 95822: // 'append' 'namespace'
+ case 96334: // 'append' 'namespace-node'
+ case 96846: // 'append' 'ne'
+ case 99406: // 'append' 'node'
+ case 99918: // 'append' 'nodes'
+ case 100430: // 'append' 'not'
+ case 100942: // 'append' 'null'
+ case 101454: // 'append' 'object'
+ case 103502: // 'append' 'only'
+ case 104014: // 'append' 'option'
+ case 104526: // 'append' 'or'
+ case 105038: // 'append' 'order'
+ case 105550: // 'append' 'ordered'
+ case 106062: // 'append' 'ordering'
+ case 107598: // 'append' 'parent'
+ case 110670: // 'append' 'preceding'
+ case 111182: // 'append' 'preceding-sibling'
+ case 112718: // 'append' 'processing-instruction'
+ case 113742: // 'append' 'rename'
+ case 114254: // 'append' 'replace'
+ case 114766: // 'append' 'return'
+ case 115278: // 'append' 'returning'
+ case 115790: // 'append' 'revalidation'
+ case 116814: // 'append' 'satisfies'
+ case 117326: // 'append' 'schema'
+ case 117838: // 'append' 'schema-attribute'
+ case 118350: // 'append' 'schema-element'
+ case 118862: // 'append' 'score'
+ case 119374: // 'append' 'select'
+ case 119886: // 'append' 'self'
+ case 122446: // 'append' 'sliding'
+ case 122958: // 'append' 'some'
+ case 123470: // 'append' 'stable'
+ case 123982: // 'append' 'start'
+ case 125518: // 'append' 'strict'
+ case 126542: // 'append' 'structured-item'
+ case 127054: // 'append' 'switch'
+ case 127566: // 'append' 'text'
+ case 129614: // 'append' 'to'
+ case 130126: // 'append' 'treat'
+ case 130638: // 'append' 'true'
+ case 131150: // 'append' 'try'
+ case 131662: // 'append' 'tumbling'
+ case 132174: // 'append' 'type'
+ case 132686: // 'append' 'typeswitch'
+ case 133198: // 'append' 'union'
+ case 134222: // 'append' 'unordered'
+ case 134734: // 'append' 'updating'
+ case 136270: // 'append' 'validate'
+ case 136782: // 'append' 'value'
+ case 137294: // 'append' 'variable'
+ case 137806: // 'append' 'version'
+ case 139342: // 'append' 'where'
+ case 139854: // 'append' 'while'
+ case 141390: // 'append' 'with'
+ case 143950: // 'append' '{'
+ case 144974: // 'append' '{|'
+ try_JSONAppendExpr();
+ break;
+ case -13:
+ break;
+ default:
+ try_OrExpr();
+ }
+ }
+
+ function parse_JSONDeleteExpr()
+ {
+ eventHandler.startNonterminal("JSONDeleteExpr", e0);
+ shift(111); // 'delete'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(11, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(11, e0, lk);
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shift(168); // 'json'
+ }
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PostfixExpr();
+ eventHandler.endNonterminal("JSONDeleteExpr", e0);
+ }
+
+ function try_JSONDeleteExpr()
+ {
+ shiftT(111); // 'delete'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(11, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(11, e0A, -1);
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(11, e0A, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PostfixExpr();
+ }
+
+ function parse_JSONInsertExpr()
+ {
+ eventHandler.startNonterminal("JSONInsertExpr", e0);
+ switch (l1)
+ {
+ case 161: // 'insert'
+ lookahead2W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 9889) // 'insert' NCName^Token
+ {
+ lk = memoized(12, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(161); // 'insert'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(13, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(13, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(13, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(72); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 110162) // 'at' 'position'
+ {
+ lk = memoized(14, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ memoize(14, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(14, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1)
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(12, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shift(161); // 'insert'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(13, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ lk = -1;
+ }
+ catch (p1B)
+ {
+ lk = -2;
+ }
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(13, e0, lk);
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shift(168); // 'json'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(72); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 110162) // 'at' 'position'
+ {
+ lk = memoized(14, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ lk = -1;
+ }
+ catch (p1B)
+ {
+ lk = -2;
+ }
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(14, e0, lk);
+ }
+ }
+ if (lk == -1)
+ {
+ shift(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shift(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ break;
+ default:
+ shift(161); // 'insert'
+ lookahead1W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(281); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(15, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ lk = -1;
+ }
+ catch (p1B)
+ {
+ lk = -2;
+ }
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(15, e0, lk);
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 9896 // 'json' NCName^Token
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shift(168); // 'json'
+ }
+ lookahead1W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PairConstructorList();
+ shift(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("JSONInsertExpr", e0);
+ }
+
+ function try_JSONInsertExpr()
+ {
+ switch (l1)
+ {
+ case 161: // 'insert'
+ lookahead2W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 9889) // 'insert' NCName^Token
+ {
+ lk = memoized(12, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(161); // 'insert'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(13, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(13, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(13, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(72); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 110162) // 'at' 'position'
+ {
+ lk = memoized(14, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ memoize(14, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(14, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1)
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ memoize(12, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(12, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shiftT(161); // 'insert'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(13, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(13, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(13, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ switch (l1)
+ {
+ case 82: // 'at'
+ lookahead2W(72); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 110162) // 'at' 'position'
+ {
+ lk = memoized(14, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ memoize(14, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(14, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1)
+ {
+ shiftT(82); // 'at'
+ lookahead1W(72); // S^WS | '(:' | 'position'
+ shiftT(215); // 'position'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ break;
+ case -3:
+ break;
+ default:
+ shiftT(161); // 'insert'
+ lookahead1W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(281); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(15, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(15, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(15, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 9896 // 'json' NCName^Token
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PairConstructorList();
+ shiftT(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+ }
+
+ function parse_JSONRenameExpr()
+ {
+ eventHandler.startNonterminal("JSONRenameExpr", e0);
+ shift(222); // 'rename'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(16, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(16, e0, lk);
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shift(168); // 'json'
+ }
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PostfixExpr();
+ shift(80); // 'as'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("JSONRenameExpr", e0);
+ }
+
+ function try_JSONRenameExpr()
+ {
+ shiftT(222); // 'rename'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(260); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(16, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(16, e0A, -1);
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(16, e0A, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PostfixExpr();
+ shiftT(80); // 'as'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_JSONReplaceExpr()
+ {
+ eventHandler.startNonterminal("JSONReplaceExpr", e0);
+ shift(223); // 'replace'
+ lookahead1W(85); // S^WS | '(:' | 'value'
+ shift(267); // 'value'
+ lookahead1W(67); // S^WS | '(:' | 'of'
+ shift(200); // 'of'
+ lookahead1W(59); // S^WS | '(:' | 'json'
+ shift(168); // 'json'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PostfixExpr();
+ shift(276); // 'with'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("JSONReplaceExpr", e0);
+ }
+
+ function try_JSONReplaceExpr()
+ {
+ shiftT(223); // 'replace'
+ lookahead1W(85); // S^WS | '(:' | 'value'
+ shiftT(267); // 'value'
+ lookahead1W(67); // S^WS | '(:' | 'of'
+ shiftT(200); // 'of'
+ lookahead1W(59); // S^WS | '(:' | 'json'
+ shiftT(168); // 'json'
+ lookahead1W(259); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PostfixExpr();
+ shiftT(276); // 'with'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_JSONAppendExpr()
+ {
+ eventHandler.startNonterminal("JSONAppendExpr", e0);
+ shift(78); // 'append'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(17, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(17, e0, lk);
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shift(168); // 'json'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("JSONAppendExpr", e0);
+ }
+
+ function try_JSONAppendExpr()
+ {
+ shiftT(78); // 'append'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ switch (l1)
+ {
+ case 168: // 'json'
+ lookahead2W(268); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 18088) // 'json' '('
+ {
+ lk = memoized(17, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(168); // 'json'
+ memoize(17, e0A, -1);
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(17, e0A, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1
+ || lk == 3240 // 'json' EQName^Token
+ || lk == 4264 // 'json' IntegerLiteral
+ || lk == 4776 // 'json' DecimalLiteral
+ || lk == 5288 // 'json' DoubleLiteral
+ || lk == 5800 // 'json' StringLiteral
+ || lk == 16040 // 'json' '$'
+ || lk == 16552 // 'json' '$$'
+ || lk == 17064 // 'json' '%'
+ || lk == 18600 // 'json' '(#'
+ || lk == 21160 // 'json' '+'
+ || lk == 22184 // 'json' '-'
+ || lk == 24232 // 'json' '/'
+ || lk == 24744 // 'json' '//'
+ || lk == 28328 // 'json' '<'
+ || lk == 28840 // 'json' '<!--'
+ || lk == 30888 // 'json' '<?'
+ || lk == 35496 // 'json' '['
+ || lk == 36520 // 'json' 'after'
+ || lk == 37544 // 'json' 'allowing'
+ || lk == 38056 // 'json' 'ancestor'
+ || lk == 38568 // 'json' 'ancestor-or-self'
+ || lk == 39080 // 'json' 'and'
+ || lk == 40104 // 'json' 'append'
+ || lk == 40616 // 'json' 'array'
+ || lk == 41128 // 'json' 'as'
+ || lk == 41640 // 'json' 'ascending'
+ || lk == 42152 // 'json' 'at'
+ || lk == 42664 // 'json' 'attribute'
+ || lk == 43176 // 'json' 'base-uri'
+ || lk == 43688 // 'json' 'before'
+ || lk == 44200 // 'json' 'boundary-space'
+ || lk == 44712 // 'json' 'break'
+ || lk == 45736 // 'json' 'case'
+ || lk == 46248 // 'json' 'cast'
+ || lk == 46760 // 'json' 'castable'
+ || lk == 47272 // 'json' 'catch'
+ || lk == 48296 // 'json' 'child'
+ || lk == 48808 // 'json' 'collation'
+ || lk == 49832 // 'json' 'comment'
+ || lk == 50344 // 'json' 'constraint'
+ || lk == 50856 // 'json' 'construction'
+ || lk == 52392 // 'json' 'context'
+ || lk == 52904 // 'json' 'continue'
+ || lk == 53416 // 'json' 'copy'
+ || lk == 53928 // 'json' 'copy-namespaces'
+ || lk == 54440 // 'json' 'count'
+ || lk == 54952 // 'json' 'decimal-format'
+ || lk == 55976 // 'json' 'declare'
+ || lk == 56488 // 'json' 'default'
+ || lk == 57000 // 'json' 'delete'
+ || lk == 57512 // 'json' 'descendant'
+ || lk == 58024 // 'json' 'descendant-or-self'
+ || lk == 58536 // 'json' 'descending'
+ || lk == 61096 // 'json' 'div'
+ || lk == 61608 // 'json' 'document'
+ || lk == 62120 // 'json' 'document-node'
+ || lk == 62632 // 'json' 'element'
+ || lk == 63144 // 'json' 'else'
+ || lk == 63656 // 'json' 'empty'
+ || lk == 64168 // 'json' 'empty-sequence'
+ || lk == 64680 // 'json' 'encoding'
+ || lk == 65192 // 'json' 'end'
+ || lk == 66216 // 'json' 'eq'
+ || lk == 66728 // 'json' 'every'
+ || lk == 67752 // 'json' 'except'
+ || lk == 68264 // 'json' 'exit'
+ || lk == 68776 // 'json' 'external'
+ || lk == 69288 // 'json' 'false'
+ || lk == 69800 // 'json' 'first'
+ || lk == 70312 // 'json' 'following'
+ || lk == 70824 // 'json' 'following-sibling'
+ || lk == 71336 // 'json' 'for'
+ || lk == 72872 // 'json' 'from'
+ || lk == 73384 // 'json' 'ft-option'
+ || lk == 75432 // 'json' 'function'
+ || lk == 75944 // 'json' 'ge'
+ || lk == 76968 // 'json' 'group'
+ || lk == 77992 // 'json' 'gt'
+ || lk == 78504 // 'json' 'idiv'
+ || lk == 79016 // 'json' 'if'
+ || lk == 79528 // 'json' 'import'
+ || lk == 80040 // 'json' 'in'
+ || lk == 80552 // 'json' 'index'
+ || lk == 82600 // 'json' 'insert'
+ || lk == 83112 // 'json' 'instance'
+ || lk == 83624 // 'json' 'integrity'
+ || lk == 84136 // 'json' 'intersect'
+ || lk == 84648 // 'json' 'into'
+ || lk == 85160 // 'json' 'is'
+ || lk == 85672 // 'json' 'item'
+ || lk == 86184 // 'json' 'json'
+ || lk == 86696 // 'json' 'json-item'
+ || lk == 87208 // 'json' 'jsoniq'
+ || lk == 88744 // 'json' 'last'
+ || lk == 89256 // 'json' 'lax'
+ || lk == 89768 // 'json' 'le'
+ || lk == 90792 // 'json' 'let'
+ || lk == 91816 // 'json' 'loop'
+ || lk == 92840 // 'json' 'lt'
+ || lk == 93864 // 'json' 'mod'
+ || lk == 94376 // 'json' 'modify'
+ || lk == 94888 // 'json' 'module'
+ || lk == 95912 // 'json' 'namespace'
+ || lk == 96424 // 'json' 'namespace-node'
+ || lk == 96936 // 'json' 'ne'
+ || lk == 99496 // 'json' 'node'
+ || lk == 100008 // 'json' 'nodes'
+ || lk == 100520 // 'json' 'not'
+ || lk == 101032 // 'json' 'null'
+ || lk == 101544 // 'json' 'object'
+ || lk == 103592 // 'json' 'only'
+ || lk == 104104 // 'json' 'option'
+ || lk == 104616 // 'json' 'or'
+ || lk == 105128 // 'json' 'order'
+ || lk == 105640 // 'json' 'ordered'
+ || lk == 106152 // 'json' 'ordering'
+ || lk == 107688 // 'json' 'parent'
+ || lk == 110760 // 'json' 'preceding'
+ || lk == 111272 // 'json' 'preceding-sibling'
+ || lk == 112808 // 'json' 'processing-instruction'
+ || lk == 113832 // 'json' 'rename'
+ || lk == 114344 // 'json' 'replace'
+ || lk == 114856 // 'json' 'return'
+ || lk == 115368 // 'json' 'returning'
+ || lk == 115880 // 'json' 'revalidation'
+ || lk == 116904 // 'json' 'satisfies'
+ || lk == 117416 // 'json' 'schema'
+ || lk == 117928 // 'json' 'schema-attribute'
+ || lk == 118440 // 'json' 'schema-element'
+ || lk == 118952 // 'json' 'score'
+ || lk == 119464 // 'json' 'select'
+ || lk == 119976 // 'json' 'self'
+ || lk == 122536 // 'json' 'sliding'
+ || lk == 123048 // 'json' 'some'
+ || lk == 123560 // 'json' 'stable'
+ || lk == 124072 // 'json' 'start'
+ || lk == 125608 // 'json' 'strict'
+ || lk == 126632 // 'json' 'structured-item'
+ || lk == 127144 // 'json' 'switch'
+ || lk == 127656 // 'json' 'text'
+ || lk == 129704 // 'json' 'to'
+ || lk == 130216 // 'json' 'treat'
+ || lk == 130728 // 'json' 'true'
+ || lk == 131240 // 'json' 'try'
+ || lk == 131752 // 'json' 'tumbling'
+ || lk == 132264 // 'json' 'type'
+ || lk == 132776 // 'json' 'typeswitch'
+ || lk == 133288 // 'json' 'union'
+ || lk == 134312 // 'json' 'unordered'
+ || lk == 134824 // 'json' 'updating'
+ || lk == 136360 // 'json' 'validate'
+ || lk == 136872 // 'json' 'value'
+ || lk == 137384 // 'json' 'variable'
+ || lk == 137896 // 'json' 'version'
+ || lk == 139432 // 'json' 'where'
+ || lk == 139944 // 'json' 'while'
+ || lk == 141480 // 'json' 'with'
+ || lk == 144040 // 'json' '{'
+ || lk == 145064) // 'json' '{|'
+ {
+ shiftT(168); // 'json'
+ }
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ shiftT(165); // 'into'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_CommonContent()
+ {
+ eventHandler.startNonterminal("CommonContent", e0);
+ switch (l1)
+ {
+ case 12: // PredefinedEntityRef
+ shift(12); // PredefinedEntityRef
+ break;
+ case 23: // CharRef
+ shift(23); // CharRef
+ break;
+ case 282: // '{{'
+ shift(282); // '{{'
+ break;
+ case 288: // '}}'
+ shift(288); // '}}'
+ break;
+ default:
+ parse_BlockExpr();
+ }
+ eventHandler.endNonterminal("CommonContent", e0);
+ }
+
+ function try_CommonContent()
+ {
+ switch (l1)
+ {
+ case 12: // PredefinedEntityRef
+ shiftT(12); // PredefinedEntityRef
+ break;
+ case 23: // CharRef
+ shiftT(23); // CharRef
+ break;
+ case 282: // '{{'
+ shiftT(282); // '{{'
+ break;
+ case 288: // '}}'
+ shiftT(288); // '}}'
+ break;
+ default:
+ try_BlockExpr();
+ }
+ }
+
+ function parse_ContentExpr()
+ {
+ eventHandler.startNonterminal("ContentExpr", e0);
+ parse_StatementsAndExpr();
+ eventHandler.endNonterminal("ContentExpr", e0);
+ }
+
+ function try_ContentExpr()
+ {
+ try_StatementsAndExpr();
+ }
+
+ function parse_CompDocConstructor()
+ {
+ eventHandler.startNonterminal("CompDocConstructor", e0);
+ shift(120); // 'document'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockExpr();
+ eventHandler.endNonterminal("CompDocConstructor", e0);
+ }
+
+ function try_CompDocConstructor()
+ {
+ shiftT(120); // 'document'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ try_BlockExpr();
+ }
+
+ function parse_CompAttrConstructor()
+ {
+ eventHandler.startNonterminal("CompAttrConstructor", e0);
+ shift(83); // 'attribute'
+ lookahead1W(249); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ break;
+ default:
+ whitespace();
+ parse_EQName();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 281: // '{'
+ lookahead2W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 147225) // '{' '}'
+ {
+ lk = memoized(18, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shiftT(287); // '}'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(18, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shift(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shift(287); // '}'
+ break;
+ default:
+ whitespace();
+ parse_BlockExpr();
+ }
+ eventHandler.endNonterminal("CompAttrConstructor", e0);
+ }
+
+ function try_CompAttrConstructor()
+ {
+ shiftT(83); // 'attribute'
+ lookahead1W(249); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ break;
+ default:
+ try_EQName();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 281: // '{'
+ lookahead2W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 147225) // '{' '}'
+ {
+ lk = memoized(18, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shiftT(287); // '}'
+ memoize(18, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(18, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shiftT(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shiftT(287); // '}'
+ break;
+ case -3:
+ break;
+ default:
+ try_BlockExpr();
+ }
+ }
+
+ function parse_CompPIConstructor()
+ {
+ eventHandler.startNonterminal("CompPIConstructor", e0);
+ shift(220); // 'processing-instruction'
+ lookahead1W(241); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shift(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_Expr();
+ shift(287); // '}'
+ break;
+ default:
+ whitespace();
+ parse_NCName();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 281: // '{'
+ lookahead2W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 147225) // '{' '}'
+ {
+ lk = memoized(19, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shiftT(287); // '}'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(19, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shift(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shift(287); // '}'
+ break;
+ default:
+ whitespace();
+ parse_BlockExpr();
+ }
+ eventHandler.endNonterminal("CompPIConstructor", e0);
+ }
+
+ function try_CompPIConstructor()
+ {
+ shiftT(220); // 'processing-instruction'
+ lookahead1W(241); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 281: // '{'
+ shiftT(281); // '{'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_Expr();
+ shiftT(287); // '}'
+ break;
+ default:
+ try_NCName();
+ }
+ lookahead1W(90); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 281: // '{'
+ lookahead2W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 147225) // '{' '}'
+ {
+ lk = memoized(19, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shiftT(287); // '}'
+ memoize(19, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(19, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shiftT(281); // '{'
+ lookahead1W(91); // S^WS | '(:' | '}'
+ shiftT(287); // '}'
+ break;
+ case -3:
+ break;
+ default:
+ try_BlockExpr();
+ }
+ }
+
+ function parse_CompCommentConstructor()
+ {
+ eventHandler.startNonterminal("CompCommentConstructor", e0);
+ shift(97); // 'comment'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockExpr();
+ eventHandler.endNonterminal("CompCommentConstructor", e0);
+ }
+
+ function try_CompCommentConstructor()
+ {
+ shiftT(97); // 'comment'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ try_BlockExpr();
+ }
+
+ function parse_CompTextConstructor()
+ {
+ eventHandler.startNonterminal("CompTextConstructor", e0);
+ shift(249); // 'text'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockExpr();
+ eventHandler.endNonterminal("CompTextConstructor", e0);
+ }
+
+ function try_CompTextConstructor()
+ {
+ shiftT(249); // 'text'
+ lookahead1W(90); // S^WS | '(:' | '{'
+ try_BlockExpr();
+ }
+
+ function parse_PrimaryExpr()
+ {
+ eventHandler.startNonterminal("PrimaryExpr", e0);
+ switch (l1)
+ {
+ case 187: // 'namespace'
+ lookahead2W(246); // NCName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 220: // 'processing-instruction'
+ lookahead2W(244); // NCName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 281: // '{'
+ lookahead2W(282); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 83: // 'attribute'
+ case 122: // 'element'
+ lookahead2W(252); // EQName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 97: // 'comment'
+ case 249: // 'text'
+ lookahead2W(97); // S^WS | '#' | '(:' | '{'
+ break;
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 262: // 'unordered'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(236); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '.' |
+ break;
+ case 6: // EQName^Token
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 76: // 'and'
+ case 78: // 'append'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 87: // 'break'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 94: // 'child'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 103: // 'continue'
+ case 104: // 'copy'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 111: // 'delete'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 130: // 'every'
+ case 132: // 'except'
+ case 133: // 'exit'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 139: // 'for'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 161: // 'insert'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 177: // 'let'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 189: // 'ne'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 222: // 'rename'
+ case 223: // 'replace'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 234: // 'self'
+ case 239: // 'sliding'
+ case 240: // 'some'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 256: // 'try'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 266: // 'validate'
+ case 267: // 'value'
+ case 268: // 'variable'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 3353 // '{' EQName^Token
+ || lk == 4377 // '{' IntegerLiteral
+ || lk == 4889 // '{' DecimalLiteral
+ || lk == 5401 // '{' DoubleLiteral
+ || lk == 5913 // '{' StringLiteral
+ || lk == 16153 // '{' '$'
+ || lk == 16665 // '{' '$$'
+ || lk == 17177 // '{' '%'
+ || lk == 18055 // 'false' '('
+ || lk == 18117 // 'null' '('
+ || lk == 18175 // 'true' '('
+ || lk == 18201 // '{' '('
+ || lk == 18713 // '{' '(#'
+ || lk == 21273 // '{' '+'
+ || lk == 22297 // '{' '-'
+ || lk == 24345 // '{' '/'
+ || lk == 24857 // '{' '//'
+ || lk == 28441 // '{' '<'
+ || lk == 28953 // '{' '<!--'
+ || lk == 31001 // '{' '<?'
+ || lk == 35609 // '{' '['
+ || lk == 36633 // '{' 'after'
+ || lk == 37657 // '{' 'allowing'
+ || lk == 38169 // '{' 'ancestor'
+ || lk == 38681 // '{' 'ancestor-or-self'
+ || lk == 39193 // '{' 'and'
+ || lk == 40217 // '{' 'append'
+ || lk == 40729 // '{' 'array'
+ || lk == 41241 // '{' 'as'
+ || lk == 41753 // '{' 'ascending'
+ || lk == 42265 // '{' 'at'
+ || lk == 42777 // '{' 'attribute'
+ || lk == 43289 // '{' 'base-uri'
+ || lk == 43801 // '{' 'before'
+ || lk == 44313 // '{' 'boundary-space'
+ || lk == 44825 // '{' 'break'
+ || lk == 45849 // '{' 'case'
+ || lk == 46361 // '{' 'cast'
+ || lk == 46873 // '{' 'castable'
+ || lk == 47385 // '{' 'catch'
+ || lk == 48409 // '{' 'child'
+ || lk == 48921 // '{' 'collation'
+ || lk == 49945 // '{' 'comment'
+ || lk == 50457 // '{' 'constraint'
+ || lk == 50969 // '{' 'construction'
+ || lk == 52505 // '{' 'context'
+ || lk == 53017 // '{' 'continue'
+ || lk == 53529 // '{' 'copy'
+ || lk == 54041 // '{' 'copy-namespaces'
+ || lk == 54553 // '{' 'count'
+ || lk == 55065 // '{' 'decimal-format'
+ || lk == 56089 // '{' 'declare'
+ || lk == 56601 // '{' 'default'
+ || lk == 57113 // '{' 'delete'
+ || lk == 57625 // '{' 'descendant'
+ || lk == 58137 // '{' 'descendant-or-self'
+ || lk == 58649 // '{' 'descending'
+ || lk == 61209 // '{' 'div'
+ || lk == 61721 // '{' 'document'
+ || lk == 62233 // '{' 'document-node'
+ || lk == 62745 // '{' 'element'
+ || lk == 63257 // '{' 'else'
+ || lk == 63769 // '{' 'empty'
+ || lk == 64281 // '{' 'empty-sequence'
+ || lk == 64793 // '{' 'encoding'
+ || lk == 65305 // '{' 'end'
+ || lk == 66329 // '{' 'eq'
+ || lk == 66841 // '{' 'every'
+ || lk == 67865 // '{' 'except'
+ || lk == 68377 // '{' 'exit'
+ || lk == 68889 // '{' 'external'
+ || lk == 69401 // '{' 'false'
+ || lk == 69913 // '{' 'first'
+ || lk == 70425 // '{' 'following'
+ || lk == 70937 // '{' 'following-sibling'
+ || lk == 71449 // '{' 'for'
+ || lk == 72985 // '{' 'from'
+ || lk == 73497 // '{' 'ft-option'
+ || lk == 75545 // '{' 'function'
+ || lk == 76057 // '{' 'ge'
+ || lk == 77081 // '{' 'group'
+ || lk == 78105 // '{' 'gt'
+ || lk == 78617 // '{' 'idiv'
+ || lk == 79129 // '{' 'if'
+ || lk == 79641 // '{' 'import'
+ || lk == 80153 // '{' 'in'
+ || lk == 80665 // '{' 'index'
+ || lk == 82713 // '{' 'insert'
+ || lk == 83225 // '{' 'instance'
+ || lk == 83737 // '{' 'integrity'
+ || lk == 84249 // '{' 'intersect'
+ || lk == 84761 // '{' 'into'
+ || lk == 85273 // '{' 'is'
+ || lk == 85785 // '{' 'item'
+ || lk == 86297 // '{' 'json'
+ || lk == 86809 // '{' 'json-item'
+ || lk == 87321 // '{' 'jsoniq'
+ || lk == 88857 // '{' 'last'
+ || lk == 89369 // '{' 'lax'
+ || lk == 89881 // '{' 'le'
+ || lk == 90905 // '{' 'let'
+ || lk == 91929 // '{' 'loop'
+ || lk == 92953 // '{' 'lt'
+ || lk == 93977 // '{' 'mod'
+ || lk == 94489 // '{' 'modify'
+ || lk == 95001 // '{' 'module'
+ || lk == 96025 // '{' 'namespace'
+ || lk == 96537 // '{' 'namespace-node'
+ || lk == 97049 // '{' 'ne'
+ || lk == 99609 // '{' 'node'
+ || lk == 100121 // '{' 'nodes'
+ || lk == 100633 // '{' 'not'
+ || lk == 101145 // '{' 'null'
+ || lk == 101657 // '{' 'object'
+ || lk == 103705 // '{' 'only'
+ || lk == 104217 // '{' 'option'
+ || lk == 104729 // '{' 'or'
+ || lk == 105241 // '{' 'order'
+ || lk == 105753 // '{' 'ordered'
+ || lk == 106265 // '{' 'ordering'
+ || lk == 107801 // '{' 'parent'
+ || lk == 110873 // '{' 'preceding'
+ || lk == 111385 // '{' 'preceding-sibling'
+ || lk == 112921 // '{' 'processing-instruction'
+ || lk == 113945 // '{' 'rename'
+ || lk == 114457 // '{' 'replace'
+ || lk == 114969 // '{' 'return'
+ || lk == 115481 // '{' 'returning'
+ || lk == 115993 // '{' 'revalidation'
+ || lk == 117017 // '{' 'satisfies'
+ || lk == 117529 // '{' 'schema'
+ || lk == 118041 // '{' 'schema-attribute'
+ || lk == 118553 // '{' 'schema-element'
+ || lk == 119065 // '{' 'score'
+ || lk == 119577 // '{' 'select'
+ || lk == 120089 // '{' 'self'
+ || lk == 122649 // '{' 'sliding'
+ || lk == 123161 // '{' 'some'
+ || lk == 123673 // '{' 'stable'
+ || lk == 124185 // '{' 'start'
+ || lk == 125721 // '{' 'strict'
+ || lk == 126745 // '{' 'structured-item'
+ || lk == 127257 // '{' 'switch'
+ || lk == 127769 // '{' 'text'
+ || lk == 129817 // '{' 'to'
+ || lk == 130329 // '{' 'treat'
+ || lk == 130841 // '{' 'true'
+ || lk == 131353 // '{' 'try'
+ || lk == 131865 // '{' 'tumbling'
+ || lk == 132377 // '{' 'type'
+ || lk == 132889 // '{' 'typeswitch'
+ || lk == 133401 // '{' 'union'
+ || lk == 134425 // '{' 'unordered'
+ || lk == 134937 // '{' 'updating'
+ || lk == 136473 // '{' 'validate'
+ || lk == 136985 // '{' 'value'
+ || lk == 137497 // '{' 'variable'
+ || lk == 138009 // '{' 'version'
+ || lk == 139545 // '{' 'where'
+ || lk == 140057 // '{' 'while'
+ || lk == 141593 // '{' 'with'
+ || lk == 144153 // '{' '{'
+ || lk == 145177 // '{' '{|'
+ || lk == 147225) // '{' '}'
+ {
+ lk = memoized(20, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Literal();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_FunctionCall();
+ lk = -5;
+ }
+ catch (p5A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_BlockExpr();
+ lk = -10;
+ }
+ catch (p10A)
+ {
+ lk = -11;
+ }
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(20, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 12935: // 'false' EOF
+ case 12997: // 'null' EOF
+ case 13055: // 'true' EOF
+ case 13447: // 'false' '!'
+ case 13509: // 'null' '!'
+ case 13567: // 'true' '!'
+ case 13959: // 'false' '!='
+ case 14021: // 'null' '!='
+ case 14079: // 'true' '!='
+ case 19591: // 'false' ')'
+ case 19653: // 'null' ')'
+ case 19711: // 'true' ')'
+ case 20103: // 'false' '*'
+ case 20165: // 'null' '*'
+ case 20223: // 'true' '*'
+ case 21127: // 'false' '+'
+ case 21189: // 'null' '+'
+ case 21247: // 'true' '+'
+ case 21639: // 'false' ','
+ case 21701: // 'null' ','
+ case 21759: // 'true' ','
+ case 22151: // 'false' '-'
+ case 22213: // 'null' '-'
+ case 22271: // 'true' '-'
+ case 23175: // 'false' '.'
+ case 23237: // 'null' '.'
+ case 23295: // 'true' '.'
+ case 24199: // 'false' '/'
+ case 24261: // 'null' '/'
+ case 24319: // 'true' '/'
+ case 24711: // 'false' '//'
+ case 24773: // 'null' '//'
+ case 24831: // 'true' '//'
+ case 25735: // 'false' ':'
+ case 25797: // 'null' ':'
+ case 25855: // 'true' ':'
+ case 27783: // 'false' ';'
+ case 27845: // 'null' ';'
+ case 27903: // 'true' ';'
+ case 28295: // 'false' '<'
+ case 28357: // 'null' '<'
+ case 28415: // 'true' '<'
+ case 29831: // 'false' '<<'
+ case 29893: // 'null' '<<'
+ case 29951: // 'true' '<<'
+ case 30343: // 'false' '<='
+ case 30405: // 'null' '<='
+ case 30463: // 'true' '<='
+ case 31367: // 'false' '='
+ case 31429: // 'null' '='
+ case 31487: // 'true' '='
+ case 31879: // 'false' '>'
+ case 31941: // 'null' '>'
+ case 31999: // 'true' '>'
+ case 32391: // 'false' '>='
+ case 32453: // 'null' '>='
+ case 32511: // 'true' '>='
+ case 32903: // 'false' '>>'
+ case 32965: // 'null' '>>'
+ case 33023: // 'true' '>>'
+ case 35463: // 'false' '['
+ case 35525: // 'null' '['
+ case 35583: // 'true' '['
+ case 35975: // 'false' ']'
+ case 36037: // 'null' ']'
+ case 36095: // 'true' ']'
+ case 36487: // 'false' 'after'
+ case 36549: // 'null' 'after'
+ case 36607: // 'true' 'after'
+ case 39047: // 'false' 'and'
+ case 39109: // 'null' 'and'
+ case 39167: // 'true' 'and'
+ case 41095: // 'false' 'as'
+ case 41157: // 'null' 'as'
+ case 41215: // 'true' 'as'
+ case 41607: // 'false' 'ascending'
+ case 41669: // 'null' 'ascending'
+ case 41727: // 'true' 'ascending'
+ case 42119: // 'false' 'at'
+ case 42181: // 'null' 'at'
+ case 42239: // 'true' 'at'
+ case 43655: // 'false' 'before'
+ case 43717: // 'null' 'before'
+ case 43775: // 'true' 'before'
+ case 45191: // 'false' 'by'
+ case 45253: // 'null' 'by'
+ case 45311: // 'true' 'by'
+ case 45703: // 'false' 'case'
+ case 45765: // 'null' 'case'
+ case 45823: // 'true' 'case'
+ case 46215: // 'false' 'cast'
+ case 46277: // 'null' 'cast'
+ case 46335: // 'true' 'cast'
+ case 46727: // 'false' 'castable'
+ case 46789: // 'null' 'castable'
+ case 46847: // 'true' 'castable'
+ case 48775: // 'false' 'collation'
+ case 48837: // 'null' 'collation'
+ case 48895: // 'true' 'collation'
+ case 51335: // 'false' 'contains'
+ case 51397: // 'null' 'contains'
+ case 51455: // 'true' 'contains'
+ case 54407: // 'false' 'count'
+ case 54469: // 'null' 'count'
+ case 54527: // 'true' 'count'
+ case 56455: // 'false' 'default'
+ case 56517: // 'null' 'default'
+ case 56575: // 'true' 'default'
+ case 58503: // 'false' 'descending'
+ case 58565: // 'null' 'descending'
+ case 58623: // 'true' 'descending'
+ case 61063: // 'false' 'div'
+ case 61125: // 'null' 'div'
+ case 61183: // 'true' 'div'
+ case 63111: // 'false' 'else'
+ case 63173: // 'null' 'else'
+ case 63231: // 'true' 'else'
+ case 63623: // 'false' 'empty'
+ case 63685: // 'null' 'empty'
+ case 63743: // 'true' 'empty'
+ case 65159: // 'false' 'end'
+ case 65221: // 'null' 'end'
+ case 65279: // 'true' 'end'
+ case 66183: // 'false' 'eq'
+ case 66245: // 'null' 'eq'
+ case 66303: // 'true' 'eq'
+ case 67719: // 'false' 'except'
+ case 67781: // 'null' 'except'
+ case 67839: // 'true' 'except'
+ case 71303: // 'false' 'for'
+ case 71365: // 'null' 'for'
+ case 71423: // 'true' 'for'
+ case 75911: // 'false' 'ge'
+ case 75973: // 'null' 'ge'
+ case 76031: // 'true' 'ge'
+ case 76935: // 'false' 'group'
+ case 76997: // 'null' 'group'
+ case 77055: // 'true' 'group'
+ case 77959: // 'false' 'gt'
+ case 78021: // 'null' 'gt'
+ case 78079: // 'true' 'gt'
+ case 78471: // 'false' 'idiv'
+ case 78533: // 'null' 'idiv'
+ case 78591: // 'true' 'idiv'
+ case 83079: // 'false' 'instance'
+ case 83141: // 'null' 'instance'
+ case 83199: // 'true' 'instance'
+ case 84103: // 'false' 'intersect'
+ case 84165: // 'null' 'intersect'
+ case 84223: // 'true' 'intersect'
+ case 84615: // 'false' 'into'
+ case 84677: // 'null' 'into'
+ case 84735: // 'true' 'into'
+ case 85127: // 'false' 'is'
+ case 85189: // 'null' 'is'
+ case 85247: // 'true' 'is'
+ case 89735: // 'false' 'le'
+ case 89797: // 'null' 'le'
+ case 89855: // 'true' 'le'
+ case 90759: // 'false' 'let'
+ case 90821: // 'null' 'let'
+ case 90879: // 'true' 'let'
+ case 92807: // 'false' 'lt'
+ case 92869: // 'null' 'lt'
+ case 92927: // 'true' 'lt'
+ case 93831: // 'false' 'mod'
+ case 93893: // 'null' 'mod'
+ case 93951: // 'true' 'mod'
+ case 94343: // 'false' 'modify'
+ case 94405: // 'null' 'modify'
+ case 94463: // 'true' 'modify'
+ case 96903: // 'false' 'ne'
+ case 96965: // 'null' 'ne'
+ case 97023: // 'true' 'ne'
+ case 103559: // 'false' 'only'
+ case 103621: // 'null' 'only'
+ case 103679: // 'true' 'only'
+ case 104583: // 'false' 'or'
+ case 104645: // 'null' 'or'
+ case 104703: // 'true' 'or'
+ case 105095: // 'false' 'order'
+ case 105157: // 'null' 'order'
+ case 105215: // 'true' 'order'
+ case 107143: // 'false' 'paragraphs'
+ case 107205: // 'null' 'paragraphs'
+ case 107263: // 'true' 'paragraphs'
+ case 114823: // 'false' 'return'
+ case 114885: // 'null' 'return'
+ case 114943: // 'true' 'return'
+ case 116871: // 'false' 'satisfies'
+ case 116933: // 'null' 'satisfies'
+ case 116991: // 'true' 'satisfies'
+ case 121479: // 'false' 'sentences'
+ case 121541: // 'null' 'sentences'
+ case 121599: // 'true' 'sentences'
+ case 123527: // 'false' 'stable'
+ case 123589: // 'null' 'stable'
+ case 123647: // 'true' 'stable'
+ case 124039: // 'false' 'start'
+ case 124101: // 'null' 'start'
+ case 124159: // 'true' 'start'
+ case 129159: // 'false' 'times'
+ case 129221: // 'null' 'times'
+ case 129279: // 'true' 'times'
+ case 129671: // 'false' 'to'
+ case 129733: // 'null' 'to'
+ case 129791: // 'true' 'to'
+ case 130183: // 'false' 'treat'
+ case 130245: // 'null' 'treat'
+ case 130303: // 'true' 'treat'
+ case 133255: // 'false' 'union'
+ case 133317: // 'null' 'union'
+ case 133375: // 'true' 'union'
+ case 139399: // 'false' 'where'
+ case 139461: // 'null' 'where'
+ case 139519: // 'true' 'where'
+ case 141447: // 'false' 'with'
+ case 141509: // 'null' 'with'
+ case 141567: // 'true' 'with'
+ case 142983: // 'false' 'words'
+ case 143045: // 'null' 'words'
+ case 143103: // 'true' 'words'
+ case 145543: // 'false' '|'
+ case 145605: // 'null' '|'
+ case 145663: // 'true' '|'
+ case 146055: // 'false' '||'
+ case 146117: // 'null' '||'
+ case 146175: // 'true' '||'
+ case 146567: // 'false' '|}'
+ case 146629: // 'null' '|}'
+ case 146687: // 'true' '|}'
+ case 147079: // 'false' '}'
+ case 147141: // 'null' '}'
+ case 147199: // 'true' '}'
+ parse_Literal();
+ break;
+ case 31: // '$'
+ parse_VarRef();
+ break;
+ case 35: // '('
+ parse_ParenthesizedExpr();
+ break;
+ case 32: // '$$'
+ parse_ContextItemExpr();
+ break;
+ case -5:
+ case 17926: // EQName^Token '('
+ case 17991: // 'after' '('
+ case 17993: // 'allowing' '('
+ case 17994: // 'ancestor' '('
+ case 17995: // 'ancestor-or-self' '('
+ case 17996: // 'and' '('
+ case 17998: // 'append' '('
+ case 18000: // 'as' '('
+ case 18001: // 'ascending' '('
+ case 18002: // 'at' '('
+ case 18004: // 'base-uri' '('
+ case 18005: // 'before' '('
+ case 18006: // 'boundary-space' '('
+ case 18007: // 'break' '('
+ case 18009: // 'case' '('
+ case 18010: // 'cast' '('
+ case 18011: // 'castable' '('
+ case 18012: // 'catch' '('
+ case 18014: // 'child' '('
+ case 18015: // 'collation' '('
+ case 18018: // 'constraint' '('
+ case 18019: // 'construction' '('
+ case 18022: // 'context' '('
+ case 18023: // 'continue' '('
+ case 18024: // 'copy' '('
+ case 18025: // 'copy-namespaces' '('
+ case 18026: // 'count' '('
+ case 18027: // 'decimal-format' '('
+ case 18029: // 'declare' '('
+ case 18030: // 'default' '('
+ case 18031: // 'delete' '('
+ case 18032: // 'descendant' '('
+ case 18033: // 'descendant-or-self' '('
+ case 18034: // 'descending' '('
+ case 18039: // 'div' '('
+ case 18040: // 'document' '('
+ case 18043: // 'else' '('
+ case 18044: // 'empty' '('
+ case 18046: // 'encoding' '('
+ case 18047: // 'end' '('
+ case 18049: // 'eq' '('
+ case 18050: // 'every' '('
+ case 18052: // 'except' '('
+ case 18053: // 'exit' '('
+ case 18054: // 'external' '('
+ case 18056: // 'first' '('
+ case 18057: // 'following' '('
+ case 18058: // 'following-sibling' '('
+ case 18059: // 'for' '('
+ case 18062: // 'from' '('
+ case 18063: // 'ft-option' '('
+ case 18068: // 'ge' '('
+ case 18070: // 'group' '('
+ case 18072: // 'gt' '('
+ case 18073: // 'idiv' '('
+ case 18075: // 'import' '('
+ case 18076: // 'in' '('
+ case 18077: // 'index' '('
+ case 18081: // 'insert' '('
+ case 18082: // 'instance' '('
+ case 18083: // 'integrity' '('
+ case 18084: // 'intersect' '('
+ case 18085: // 'into' '('
+ case 18086: // 'is' '('
+ case 18088: // 'json' '('
+ case 18090: // 'jsoniq' '('
+ case 18093: // 'last' '('
+ case 18094: // 'lax' '('
+ case 18095: // 'le' '('
+ case 18097: // 'let' '('
+ case 18099: // 'loop' '('
+ case 18101: // 'lt' '('
+ case 18103: // 'mod' '('
+ case 18104: // 'modify' '('
+ case 18105: // 'module' '('
+ case 18107: // 'namespace' '('
+ case 18109: // 'ne' '('
+ case 18115: // 'nodes' '('
+ case 18118: // 'object' '('
+ case 18122: // 'only' '('
+ case 18123: // 'option' '('
+ case 18124: // 'or' '('
+ case 18125: // 'order' '('
+ case 18126: // 'ordered' '('
+ case 18127: // 'ordering' '('
+ case 18130: // 'parent' '('
+ case 18136: // 'preceding' '('
+ case 18137: // 'preceding-sibling' '('
+ case 18142: // 'rename' '('
+ case 18143: // 'replace' '('
+ case 18144: // 'return' '('
+ case 18145: // 'returning' '('
+ case 18146: // 'revalidation' '('
+ case 18148: // 'satisfies' '('
+ case 18149: // 'schema' '('
+ case 18152: // 'score' '('
+ case 18153: // 'select' '('
+ case 18154: // 'self' '('
+ case 18159: // 'sliding' '('
+ case 18160: // 'some' '('
+ case 18161: // 'stable' '('
+ case 18162: // 'start' '('
+ case 18165: // 'strict' '('
+ case 18173: // 'to' '('
+ case 18174: // 'treat' '('
+ case 18176: // 'try' '('
+ case 18177: // 'tumbling' '('
+ case 18178: // 'type' '('
+ case 18180: // 'union' '('
+ case 18182: // 'unordered' '('
+ case 18183: // 'updating' '('
+ case 18186: // 'validate' '('
+ case 18187: // 'value' '('
+ case 18188: // 'variable' '('
+ case 18189: // 'version' '('
+ case 18192: // 'where' '('
+ case 18193: // 'while' '('
+ case 18196: // 'with' '('
+ parse_FunctionCall();
+ break;
+ case 144078: // 'ordered' '{'
+ parse_OrderedExpr();
+ break;
+ case 144134: // 'unordered' '{'
+ parse_UnorderedExpr();
+ break;
+ case 33: // '%'
+ case 79: // 'array'
+ case 121: // 'document-node'
+ case 125: // 'empty-sequence'
+ case 147: // 'function'
+ case 154: // 'if'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 247: // 'structured-item'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ case 14854: // EQName^Token '#'
+ case 14919: // 'after' '#'
+ case 14921: // 'allowing' '#'
+ case 14922: // 'ancestor' '#'
+ case 14923: // 'ancestor-or-self' '#'
+ case 14924: // 'and' '#'
+ case 14926: // 'append' '#'
+ case 14928: // 'as' '#'
+ case 14929: // 'ascending' '#'
+ case 14930: // 'at' '#'
+ case 14931: // 'attribute' '#'
+ case 14932: // 'base-uri' '#'
+ case 14933: // 'before' '#'
+ case 14934: // 'boundary-space' '#'
+ case 14935: // 'break' '#'
+ case 14937: // 'case' '#'
+ case 14938: // 'cast' '#'
+ case 14939: // 'castable' '#'
+ case 14940: // 'catch' '#'
+ case 14942: // 'child' '#'
+ case 14943: // 'collation' '#'
+ case 14945: // 'comment' '#'
+ case 14946: // 'constraint' '#'
+ case 14947: // 'construction' '#'
+ case 14950: // 'context' '#'
+ case 14951: // 'continue' '#'
+ case 14952: // 'copy' '#'
+ case 14953: // 'copy-namespaces' '#'
+ case 14954: // 'count' '#'
+ case 14955: // 'decimal-format' '#'
+ case 14957: // 'declare' '#'
+ case 14958: // 'default' '#'
+ case 14959: // 'delete' '#'
+ case 14960: // 'descendant' '#'
+ case 14961: // 'descendant-or-self' '#'
+ case 14962: // 'descending' '#'
+ case 14967: // 'div' '#'
+ case 14968: // 'document' '#'
+ case 14970: // 'element' '#'
+ case 14971: // 'else' '#'
+ case 14972: // 'empty' '#'
+ case 14974: // 'encoding' '#'
+ case 14975: // 'end' '#'
+ case 14977: // 'eq' '#'
+ case 14978: // 'every' '#'
+ case 14980: // 'except' '#'
+ case 14981: // 'exit' '#'
+ case 14982: // 'external' '#'
+ case 14983: // 'false' '#'
+ case 14984: // 'first' '#'
+ case 14985: // 'following' '#'
+ case 14986: // 'following-sibling' '#'
+ case 14987: // 'for' '#'
+ case 14990: // 'from' '#'
+ case 14991: // 'ft-option' '#'
+ case 14996: // 'ge' '#'
+ case 14998: // 'group' '#'
+ case 15000: // 'gt' '#'
+ case 15001: // 'idiv' '#'
+ case 15003: // 'import' '#'
+ case 15004: // 'in' '#'
+ case 15005: // 'index' '#'
+ case 15009: // 'insert' '#'
+ case 15010: // 'instance' '#'
+ case 15011: // 'integrity' '#'
+ case 15012: // 'intersect' '#'
+ case 15013: // 'into' '#'
+ case 15014: // 'is' '#'
+ case 15016: // 'json' '#'
+ case 15018: // 'jsoniq' '#'
+ case 15021: // 'last' '#'
+ case 15022: // 'lax' '#'
+ case 15023: // 'le' '#'
+ case 15025: // 'let' '#'
+ case 15027: // 'loop' '#'
+ case 15029: // 'lt' '#'
+ case 15031: // 'mod' '#'
+ case 15032: // 'modify' '#'
+ case 15033: // 'module' '#'
+ case 15035: // 'namespace' '#'
+ case 15037: // 'ne' '#'
+ case 15043: // 'nodes' '#'
+ case 15045: // 'null' '#'
+ case 15046: // 'object' '#'
+ case 15050: // 'only' '#'
+ case 15051: // 'option' '#'
+ case 15052: // 'or' '#'
+ case 15053: // 'order' '#'
+ case 15054: // 'ordered' '#'
+ case 15055: // 'ordering' '#'
+ case 15058: // 'parent' '#'
+ case 15064: // 'preceding' '#'
+ case 15065: // 'preceding-sibling' '#'
+ case 15068: // 'processing-instruction' '#'
+ case 15070: // 'rename' '#'
+ case 15071: // 'replace' '#'
+ case 15072: // 'return' '#'
+ case 15073: // 'returning' '#'
+ case 15074: // 'revalidation' '#'
+ case 15076: // 'satisfies' '#'
+ case 15077: // 'schema' '#'
+ case 15080: // 'score' '#'
+ case 15081: // 'select' '#'
+ case 15082: // 'self' '#'
+ case 15087: // 'sliding' '#'
+ case 15088: // 'some' '#'
+ case 15089: // 'stable' '#'
+ case 15090: // 'start' '#'
+ case 15093: // 'strict' '#'
+ case 15097: // 'text' '#'
+ case 15101: // 'to' '#'
+ case 15102: // 'treat' '#'
+ case 15103: // 'true' '#'
+ case 15104: // 'try' '#'
+ case 15105: // 'tumbling' '#'
+ case 15106: // 'type' '#'
+ case 15108: // 'union' '#'
+ case 15110: // 'unordered' '#'
+ case 15111: // 'updating' '#'
+ case 15114: // 'validate' '#'
+ case 15115: // 'value' '#'
+ case 15116: // 'variable' '#'
+ case 15117: // 'version' '#'
+ case 15120: // 'where' '#'
+ case 15121: // 'while' '#'
+ case 15124: // 'with' '#'
+ parse_FunctionItemExpr();
+ break;
+ case -10:
+ case 27929: // '{' ';'
+ parse_BlockExpr();
+ break;
+ case -11:
+ case 10009: // '{' NCName^Token
+ parse_ObjectConstructor();
+ break;
+ case 69: // '['
+ parse_ArrayConstructor();
+ break;
+ case 283: // '{|'
+ parse_JSONSimpleObjectUnion();
+ break;
+ default:
+ parse_Constructor();
+ }
+ eventHandler.endNonterminal("PrimaryExpr", e0);
+ }
+
+ function try_PrimaryExpr()
+ {
+ switch (l1)
+ {
+ case 187: // 'namespace'
+ lookahead2W(246); // NCName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 220: // 'processing-instruction'
+ lookahead2W(244); // NCName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 281: // '{'
+ lookahead2W(282); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 83: // 'attribute'
+ case 122: // 'element'
+ lookahead2W(252); // EQName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 97: // 'comment'
+ case 249: // 'text'
+ lookahead2W(97); // S^WS | '#' | '(:' | '{'
+ break;
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 262: // 'unordered'
+ lookahead2W(148); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(236); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '.' |
+ break;
+ case 6: // EQName^Token
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 76: // 'and'
+ case 78: // 'append'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 87: // 'break'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 94: // 'child'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 103: // 'continue'
+ case 104: // 'copy'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 111: // 'delete'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 130: // 'every'
+ case 132: // 'except'
+ case 133: // 'exit'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 139: // 'for'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 161: // 'insert'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 177: // 'let'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 189: // 'ne'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 222: // 'rename'
+ case 223: // 'replace'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 234: // 'self'
+ case 239: // 'sliding'
+ case 240: // 'some'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 256: // 'try'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 266: // 'validate'
+ case 267: // 'value'
+ case 268: // 'variable'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(95); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 3353 // '{' EQName^Token
+ || lk == 4377 // '{' IntegerLiteral
+ || lk == 4889 // '{' DecimalLiteral
+ || lk == 5401 // '{' DoubleLiteral
+ || lk == 5913 // '{' StringLiteral
+ || lk == 16153 // '{' '$'
+ || lk == 16665 // '{' '$$'
+ || lk == 17177 // '{' '%'
+ || lk == 18055 // 'false' '('
+ || lk == 18117 // 'null' '('
+ || lk == 18175 // 'true' '('
+ || lk == 18201 // '{' '('
+ || lk == 18713 // '{' '(#'
+ || lk == 21273 // '{' '+'
+ || lk == 22297 // '{' '-'
+ || lk == 24345 // '{' '/'
+ || lk == 24857 // '{' '//'
+ || lk == 28441 // '{' '<'
+ || lk == 28953 // '{' '<!--'
+ || lk == 31001 // '{' '<?'
+ || lk == 35609 // '{' '['
+ || lk == 36633 // '{' 'after'
+ || lk == 37657 // '{' 'allowing'
+ || lk == 38169 // '{' 'ancestor'
+ || lk == 38681 // '{' 'ancestor-or-self'
+ || lk == 39193 // '{' 'and'
+ || lk == 40217 // '{' 'append'
+ || lk == 40729 // '{' 'array'
+ || lk == 41241 // '{' 'as'
+ || lk == 41753 // '{' 'ascending'
+ || lk == 42265 // '{' 'at'
+ || lk == 42777 // '{' 'attribute'
+ || lk == 43289 // '{' 'base-uri'
+ || lk == 43801 // '{' 'before'
+ || lk == 44313 // '{' 'boundary-space'
+ || lk == 44825 // '{' 'break'
+ || lk == 45849 // '{' 'case'
+ || lk == 46361 // '{' 'cast'
+ || lk == 46873 // '{' 'castable'
+ || lk == 47385 // '{' 'catch'
+ || lk == 48409 // '{' 'child'
+ || lk == 48921 // '{' 'collation'
+ || lk == 49945 // '{' 'comment'
+ || lk == 50457 // '{' 'constraint'
+ || lk == 50969 // '{' 'construction'
+ || lk == 52505 // '{' 'context'
+ || lk == 53017 // '{' 'continue'
+ || lk == 53529 // '{' 'copy'
+ || lk == 54041 // '{' 'copy-namespaces'
+ || lk == 54553 // '{' 'count'
+ || lk == 55065 // '{' 'decimal-format'
+ || lk == 56089 // '{' 'declare'
+ || lk == 56601 // '{' 'default'
+ || lk == 57113 // '{' 'delete'
+ || lk == 57625 // '{' 'descendant'
+ || lk == 58137 // '{' 'descendant-or-self'
+ || lk == 58649 // '{' 'descending'
+ || lk == 61209 // '{' 'div'
+ || lk == 61721 // '{' 'document'
+ || lk == 62233 // '{' 'document-node'
+ || lk == 62745 // '{' 'element'
+ || lk == 63257 // '{' 'else'
+ || lk == 63769 // '{' 'empty'
+ || lk == 64281 // '{' 'empty-sequence'
+ || lk == 64793 // '{' 'encoding'
+ || lk == 65305 // '{' 'end'
+ || lk == 66329 // '{' 'eq'
+ || lk == 66841 // '{' 'every'
+ || lk == 67865 // '{' 'except'
+ || lk == 68377 // '{' 'exit'
+ || lk == 68889 // '{' 'external'
+ || lk == 69401 // '{' 'false'
+ || lk == 69913 // '{' 'first'
+ || lk == 70425 // '{' 'following'
+ || lk == 70937 // '{' 'following-sibling'
+ || lk == 71449 // '{' 'for'
+ || lk == 72985 // '{' 'from'
+ || lk == 73497 // '{' 'ft-option'
+ || lk == 75545 // '{' 'function'
+ || lk == 76057 // '{' 'ge'
+ || lk == 77081 // '{' 'group'
+ || lk == 78105 // '{' 'gt'
+ || lk == 78617 // '{' 'idiv'
+ || lk == 79129 // '{' 'if'
+ || lk == 79641 // '{' 'import'
+ || lk == 80153 // '{' 'in'
+ || lk == 80665 // '{' 'index'
+ || lk == 82713 // '{' 'insert'
+ || lk == 83225 // '{' 'instance'
+ || lk == 83737 // '{' 'integrity'
+ || lk == 84249 // '{' 'intersect'
+ || lk == 84761 // '{' 'into'
+ || lk == 85273 // '{' 'is'
+ || lk == 85785 // '{' 'item'
+ || lk == 86297 // '{' 'json'
+ || lk == 86809 // '{' 'json-item'
+ || lk == 87321 // '{' 'jsoniq'
+ || lk == 88857 // '{' 'last'
+ || lk == 89369 // '{' 'lax'
+ || lk == 89881 // '{' 'le'
+ || lk == 90905 // '{' 'let'
+ || lk == 91929 // '{' 'loop'
+ || lk == 92953 // '{' 'lt'
+ || lk == 93977 // '{' 'mod'
+ || lk == 94489 // '{' 'modify'
+ || lk == 95001 // '{' 'module'
+ || lk == 96025 // '{' 'namespace'
+ || lk == 96537 // '{' 'namespace-node'
+ || lk == 97049 // '{' 'ne'
+ || lk == 99609 // '{' 'node'
+ || lk == 100121 // '{' 'nodes'
+ || lk == 100633 // '{' 'not'
+ || lk == 101145 // '{' 'null'
+ || lk == 101657 // '{' 'object'
+ || lk == 103705 // '{' 'only'
+ || lk == 104217 // '{' 'option'
+ || lk == 104729 // '{' 'or'
+ || lk == 105241 // '{' 'order'
+ || lk == 105753 // '{' 'ordered'
+ || lk == 106265 // '{' 'ordering'
+ || lk == 107801 // '{' 'parent'
+ || lk == 110873 // '{' 'preceding'
+ || lk == 111385 // '{' 'preceding-sibling'
+ || lk == 112921 // '{' 'processing-instruction'
+ || lk == 113945 // '{' 'rename'
+ || lk == 114457 // '{' 'replace'
+ || lk == 114969 // '{' 'return'
+ || lk == 115481 // '{' 'returning'
+ || lk == 115993 // '{' 'revalidation'
+ || lk == 117017 // '{' 'satisfies'
+ || lk == 117529 // '{' 'schema'
+ || lk == 118041 // '{' 'schema-attribute'
+ || lk == 118553 // '{' 'schema-element'
+ || lk == 119065 // '{' 'score'
+ || lk == 119577 // '{' 'select'
+ || lk == 120089 // '{' 'self'
+ || lk == 122649 // '{' 'sliding'
+ || lk == 123161 // '{' 'some'
+ || lk == 123673 // '{' 'stable'
+ || lk == 124185 // '{' 'start'
+ || lk == 125721 // '{' 'strict'
+ || lk == 126745 // '{' 'structured-item'
+ || lk == 127257 // '{' 'switch'
+ || lk == 127769 // '{' 'text'
+ || lk == 129817 // '{' 'to'
+ || lk == 130329 // '{' 'treat'
+ || lk == 130841 // '{' 'true'
+ || lk == 131353 // '{' 'try'
+ || lk == 131865 // '{' 'tumbling'
+ || lk == 132377 // '{' 'type'
+ || lk == 132889 // '{' 'typeswitch'
+ || lk == 133401 // '{' 'union'
+ || lk == 134425 // '{' 'unordered'
+ || lk == 134937 // '{' 'updating'
+ || lk == 136473 // '{' 'validate'
+ || lk == 136985 // '{' 'value'
+ || lk == 137497 // '{' 'variable'
+ || lk == 138009 // '{' 'version'
+ || lk == 139545 // '{' 'where'
+ || lk == 140057 // '{' 'while'
+ || lk == 141593 // '{' 'with'
+ || lk == 144153 // '{' '{'
+ || lk == 145177 // '{' '{|'
+ || lk == 147225) // '{' '}'
+ {
+ lk = memoized(20, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Literal();
+ memoize(20, e0A, -1);
+ lk = -14;
+ }
+ catch (p1A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_FunctionCall();
+ memoize(20, e0A, -5);
+ lk = -14;
+ }
+ catch (p5A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_BlockExpr();
+ memoize(20, e0A, -10);
+ lk = -14;
+ }
+ catch (p10A)
+ {
+ lk = -11;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(20, e0A, -11);
+ }
+ }
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 12935: // 'false' EOF
+ case 12997: // 'null' EOF
+ case 13055: // 'true' EOF
+ case 13447: // 'false' '!'
+ case 13509: // 'null' '!'
+ case 13567: // 'true' '!'
+ case 13959: // 'false' '!='
+ case 14021: // 'null' '!='
+ case 14079: // 'true' '!='
+ case 19591: // 'false' ')'
+ case 19653: // 'null' ')'
+ case 19711: // 'true' ')'
+ case 20103: // 'false' '*'
+ case 20165: // 'null' '*'
+ case 20223: // 'true' '*'
+ case 21127: // 'false' '+'
+ case 21189: // 'null' '+'
+ case 21247: // 'true' '+'
+ case 21639: // 'false' ','
+ case 21701: // 'null' ','
+ case 21759: // 'true' ','
+ case 22151: // 'false' '-'
+ case 22213: // 'null' '-'
+ case 22271: // 'true' '-'
+ case 23175: // 'false' '.'
+ case 23237: // 'null' '.'
+ case 23295: // 'true' '.'
+ case 24199: // 'false' '/'
+ case 24261: // 'null' '/'
+ case 24319: // 'true' '/'
+ case 24711: // 'false' '//'
+ case 24773: // 'null' '//'
+ case 24831: // 'true' '//'
+ case 25735: // 'false' ':'
+ case 25797: // 'null' ':'
+ case 25855: // 'true' ':'
+ case 27783: // 'false' ';'
+ case 27845: // 'null' ';'
+ case 27903: // 'true' ';'
+ case 28295: // 'false' '<'
+ case 28357: // 'null' '<'
+ case 28415: // 'true' '<'
+ case 29831: // 'false' '<<'
+ case 29893: // 'null' '<<'
+ case 29951: // 'true' '<<'
+ case 30343: // 'false' '<='
+ case 30405: // 'null' '<='
+ case 30463: // 'true' '<='
+ case 31367: // 'false' '='
+ case 31429: // 'null' '='
+ case 31487: // 'true' '='
+ case 31879: // 'false' '>'
+ case 31941: // 'null' '>'
+ case 31999: // 'true' '>'
+ case 32391: // 'false' '>='
+ case 32453: // 'null' '>='
+ case 32511: // 'true' '>='
+ case 32903: // 'false' '>>'
+ case 32965: // 'null' '>>'
+ case 33023: // 'true' '>>'
+ case 35463: // 'false' '['
+ case 35525: // 'null' '['
+ case 35583: // 'true' '['
+ case 35975: // 'false' ']'
+ case 36037: // 'null' ']'
+ case 36095: // 'true' ']'
+ case 36487: // 'false' 'after'
+ case 36549: // 'null' 'after'
+ case 36607: // 'true' 'after'
+ case 39047: // 'false' 'and'
+ case 39109: // 'null' 'and'
+ case 39167: // 'true' 'and'
+ case 41095: // 'false' 'as'
+ case 41157: // 'null' 'as'
+ case 41215: // 'true' 'as'
+ case 41607: // 'false' 'ascending'
+ case 41669: // 'null' 'ascending'
+ case 41727: // 'true' 'ascending'
+ case 42119: // 'false' 'at'
+ case 42181: // 'null' 'at'
+ case 42239: // 'true' 'at'
+ case 43655: // 'false' 'before'
+ case 43717: // 'null' 'before'
+ case 43775: // 'true' 'before'
+ case 45191: // 'false' 'by'
+ case 45253: // 'null' 'by'
+ case 45311: // 'true' 'by'
+ case 45703: // 'false' 'case'
+ case 45765: // 'null' 'case'
+ case 45823: // 'true' 'case'
+ case 46215: // 'false' 'cast'
+ case 46277: // 'null' 'cast'
+ case 46335: // 'true' 'cast'
+ case 46727: // 'false' 'castable'
+ case 46789: // 'null' 'castable'
+ case 46847: // 'true' 'castable'
+ case 48775: // 'false' 'collation'
+ case 48837: // 'null' 'collation'
+ case 48895: // 'true' 'collation'
+ case 51335: // 'false' 'contains'
+ case 51397: // 'null' 'contains'
+ case 51455: // 'true' 'contains'
+ case 54407: // 'false' 'count'
+ case 54469: // 'null' 'count'
+ case 54527: // 'true' 'count'
+ case 56455: // 'false' 'default'
+ case 56517: // 'null' 'default'
+ case 56575: // 'true' 'default'
+ case 58503: // 'false' 'descending'
+ case 58565: // 'null' 'descending'
+ case 58623: // 'true' 'descending'
+ case 61063: // 'false' 'div'
+ case 61125: // 'null' 'div'
+ case 61183: // 'true' 'div'
+ case 63111: // 'false' 'else'
+ case 63173: // 'null' 'else'
+ case 63231: // 'true' 'else'
+ case 63623: // 'false' 'empty'
+ case 63685: // 'null' 'empty'
+ case 63743: // 'true' 'empty'
+ case 65159: // 'false' 'end'
+ case 65221: // 'null' 'end'
+ case 65279: // 'true' 'end'
+ case 66183: // 'false' 'eq'
+ case 66245: // 'null' 'eq'
+ case 66303: // 'true' 'eq'
+ case 67719: // 'false' 'except'
+ case 67781: // 'null' 'except'
+ case 67839: // 'true' 'except'
+ case 71303: // 'false' 'for'
+ case 71365: // 'null' 'for'
+ case 71423: // 'true' 'for'
+ case 75911: // 'false' 'ge'
+ case 75973: // 'null' 'ge'
+ case 76031: // 'true' 'ge'
+ case 76935: // 'false' 'group'
+ case 76997: // 'null' 'group'
+ case 77055: // 'true' 'group'
+ case 77959: // 'false' 'gt'
+ case 78021: // 'null' 'gt'
+ case 78079: // 'true' 'gt'
+ case 78471: // 'false' 'idiv'
+ case 78533: // 'null' 'idiv'
+ case 78591: // 'true' 'idiv'
+ case 83079: // 'false' 'instance'
+ case 83141: // 'null' 'instance'
+ case 83199: // 'true' 'instance'
+ case 84103: // 'false' 'intersect'
+ case 84165: // 'null' 'intersect'
+ case 84223: // 'true' 'intersect'
+ case 84615: // 'false' 'into'
+ case 84677: // 'null' 'into'
+ case 84735: // 'true' 'into'
+ case 85127: // 'false' 'is'
+ case 85189: // 'null' 'is'
+ case 85247: // 'true' 'is'
+ case 89735: // 'false' 'le'
+ case 89797: // 'null' 'le'
+ case 89855: // 'true' 'le'
+ case 90759: // 'false' 'let'
+ case 90821: // 'null' 'let'
+ case 90879: // 'true' 'let'
+ case 92807: // 'false' 'lt'
+ case 92869: // 'null' 'lt'
+ case 92927: // 'true' 'lt'
+ case 93831: // 'false' 'mod'
+ case 93893: // 'null' 'mod'
+ case 93951: // 'true' 'mod'
+ case 94343: // 'false' 'modify'
+ case 94405: // 'null' 'modify'
+ case 94463: // 'true' 'modify'
+ case 96903: // 'false' 'ne'
+ case 96965: // 'null' 'ne'
+ case 97023: // 'true' 'ne'
+ case 103559: // 'false' 'only'
+ case 103621: // 'null' 'only'
+ case 103679: // 'true' 'only'
+ case 104583: // 'false' 'or'
+ case 104645: // 'null' 'or'
+ case 104703: // 'true' 'or'
+ case 105095: // 'false' 'order'
+ case 105157: // 'null' 'order'
+ case 105215: // 'true' 'order'
+ case 107143: // 'false' 'paragraphs'
+ case 107205: // 'null' 'paragraphs'
+ case 107263: // 'true' 'paragraphs'
+ case 114823: // 'false' 'return'
+ case 114885: // 'null' 'return'
+ case 114943: // 'true' 'return'
+ case 116871: // 'false' 'satisfies'
+ case 116933: // 'null' 'satisfies'
+ case 116991: // 'true' 'satisfies'
+ case 121479: // 'false' 'sentences'
+ case 121541: // 'null' 'sentences'
+ case 121599: // 'true' 'sentences'
+ case 123527: // 'false' 'stable'
+ case 123589: // 'null' 'stable'
+ case 123647: // 'true' 'stable'
+ case 124039: // 'false' 'start'
+ case 124101: // 'null' 'start'
+ case 124159: // 'true' 'start'
+ case 129159: // 'false' 'times'
+ case 129221: // 'null' 'times'
+ case 129279: // 'true' 'times'
+ case 129671: // 'false' 'to'
+ case 129733: // 'null' 'to'
+ case 129791: // 'true' 'to'
+ case 130183: // 'false' 'treat'
+ case 130245: // 'null' 'treat'
+ case 130303: // 'true' 'treat'
+ case 133255: // 'false' 'union'
+ case 133317: // 'null' 'union'
+ case 133375: // 'true' 'union'
+ case 139399: // 'false' 'where'
+ case 139461: // 'null' 'where'
+ case 139519: // 'true' 'where'
+ case 141447: // 'false' 'with'
+ case 141509: // 'null' 'with'
+ case 141567: // 'true' 'with'
+ case 142983: // 'false' 'words'
+ case 143045: // 'null' 'words'
+ case 143103: // 'true' 'words'
+ case 145543: // 'false' '|'
+ case 145605: // 'null' '|'
+ case 145663: // 'true' '|'
+ case 146055: // 'false' '||'
+ case 146117: // 'null' '||'
+ case 146175: // 'true' '||'
+ case 146567: // 'false' '|}'
+ case 146629: // 'null' '|}'
+ case 146687: // 'true' '|}'
+ case 147079: // 'false' '}'
+ case 147141: // 'null' '}'
+ case 147199: // 'true' '}'
+ try_Literal();
+ break;
+ case 31: // '$'
+ try_VarRef();
+ break;
+ case 35: // '('
+ try_ParenthesizedExpr();
+ break;
+ case 32: // '$$'
+ try_ContextItemExpr();
+ break;
+ case -5:
+ case 17926: // EQName^Token '('
+ case 17991: // 'after' '('
+ case 17993: // 'allowing' '('
+ case 17994: // 'ancestor' '('
+ case 17995: // 'ancestor-or-self' '('
+ case 17996: // 'and' '('
+ case 17998: // 'append' '('
+ case 18000: // 'as' '('
+ case 18001: // 'ascending' '('
+ case 18002: // 'at' '('
+ case 18004: // 'base-uri' '('
+ case 18005: // 'before' '('
+ case 18006: // 'boundary-space' '('
+ case 18007: // 'break' '('
+ case 18009: // 'case' '('
+ case 18010: // 'cast' '('
+ case 18011: // 'castable' '('
+ case 18012: // 'catch' '('
+ case 18014: // 'child' '('
+ case 18015: // 'collation' '('
+ case 18018: // 'constraint' '('
+ case 18019: // 'construction' '('
+ case 18022: // 'context' '('
+ case 18023: // 'continue' '('
+ case 18024: // 'copy' '('
+ case 18025: // 'copy-namespaces' '('
+ case 18026: // 'count' '('
+ case 18027: // 'decimal-format' '('
+ case 18029: // 'declare' '('
+ case 18030: // 'default' '('
+ case 18031: // 'delete' '('
+ case 18032: // 'descendant' '('
+ case 18033: // 'descendant-or-self' '('
+ case 18034: // 'descending' '('
+ case 18039: // 'div' '('
+ case 18040: // 'document' '('
+ case 18043: // 'else' '('
+ case 18044: // 'empty' '('
+ case 18046: // 'encoding' '('
+ case 18047: // 'end' '('
+ case 18049: // 'eq' '('
+ case 18050: // 'every' '('
+ case 18052: // 'except' '('
+ case 18053: // 'exit' '('
+ case 18054: // 'external' '('
+ case 18056: // 'first' '('
+ case 18057: // 'following' '('
+ case 18058: // 'following-sibling' '('
+ case 18059: // 'for' '('
+ case 18062: // 'from' '('
+ case 18063: // 'ft-option' '('
+ case 18068: // 'ge' '('
+ case 18070: // 'group' '('
+ case 18072: // 'gt' '('
+ case 18073: // 'idiv' '('
+ case 18075: // 'import' '('
+ case 18076: // 'in' '('
+ case 18077: // 'index' '('
+ case 18081: // 'insert' '('
+ case 18082: // 'instance' '('
+ case 18083: // 'integrity' '('
+ case 18084: // 'intersect' '('
+ case 18085: // 'into' '('
+ case 18086: // 'is' '('
+ case 18088: // 'json' '('
+ case 18090: // 'jsoniq' '('
+ case 18093: // 'last' '('
+ case 18094: // 'lax' '('
+ case 18095: // 'le' '('
+ case 18097: // 'let' '('
+ case 18099: // 'loop' '('
+ case 18101: // 'lt' '('
+ case 18103: // 'mod' '('
+ case 18104: // 'modify' '('
+ case 18105: // 'module' '('
+ case 18107: // 'namespace' '('
+ case 18109: // 'ne' '('
+ case 18115: // 'nodes' '('
+ case 18118: // 'object' '('
+ case 18122: // 'only' '('
+ case 18123: // 'option' '('
+ case 18124: // 'or' '('
+ case 18125: // 'order' '('
+ case 18126: // 'ordered' '('
+ case 18127: // 'ordering' '('
+ case 18130: // 'parent' '('
+ case 18136: // 'preceding' '('
+ case 18137: // 'preceding-sibling' '('
+ case 18142: // 'rename' '('
+ case 18143: // 'replace' '('
+ case 18144: // 'return' '('
+ case 18145: // 'returning' '('
+ case 18146: // 'revalidation' '('
+ case 18148: // 'satisfies' '('
+ case 18149: // 'schema' '('
+ case 18152: // 'score' '('
+ case 18153: // 'select' '('
+ case 18154: // 'self' '('
+ case 18159: // 'sliding' '('
+ case 18160: // 'some' '('
+ case 18161: // 'stable' '('
+ case 18162: // 'start' '('
+ case 18165: // 'strict' '('
+ case 18173: // 'to' '('
+ case 18174: // 'treat' '('
+ case 18176: // 'try' '('
+ case 18177: // 'tumbling' '('
+ case 18178: // 'type' '('
+ case 18180: // 'union' '('
+ case 18182: // 'unordered' '('
+ case 18183: // 'updating' '('
+ case 18186: // 'validate' '('
+ case 18187: // 'value' '('
+ case 18188: // 'variable' '('
+ case 18189: // 'version' '('
+ case 18192: // 'where' '('
+ case 18193: // 'while' '('
+ case 18196: // 'with' '('
+ try_FunctionCall();
+ break;
+ case 144078: // 'ordered' '{'
+ try_OrderedExpr();
+ break;
+ case 144134: // 'unordered' '{'
+ try_UnorderedExpr();
+ break;
+ case 33: // '%'
+ case 79: // 'array'
+ case 121: // 'document-node'
+ case 125: // 'empty-sequence'
+ case 147: // 'function'
+ case 154: // 'if'
+ case 167: // 'item'
+ case 169: // 'json-item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ case 247: // 'structured-item'
+ case 248: // 'switch'
+ case 259: // 'typeswitch'
+ case 14854: // EQName^Token '#'
+ case 14919: // 'after' '#'
+ case 14921: // 'allowing' '#'
+ case 14922: // 'ancestor' '#'
+ case 14923: // 'ancestor-or-self' '#'
+ case 14924: // 'and' '#'
+ case 14926: // 'append' '#'
+ case 14928: // 'as' '#'
+ case 14929: // 'ascending' '#'
+ case 14930: // 'at' '#'
+ case 14931: // 'attribute' '#'
+ case 14932: // 'base-uri' '#'
+ case 14933: // 'before' '#'
+ case 14934: // 'boundary-space' '#'
+ case 14935: // 'break' '#'
+ case 14937: // 'case' '#'
+ case 14938: // 'cast' '#'
+ case 14939: // 'castable' '#'
+ case 14940: // 'catch' '#'
+ case 14942: // 'child' '#'
+ case 14943: // 'collation' '#'
+ case 14945: // 'comment' '#'
+ case 14946: // 'constraint' '#'
+ case 14947: // 'construction' '#'
+ case 14950: // 'context' '#'
+ case 14951: // 'continue' '#'
+ case 14952: // 'copy' '#'
+ case 14953: // 'copy-namespaces' '#'
+ case 14954: // 'count' '#'
+ case 14955: // 'decimal-format' '#'
+ case 14957: // 'declare' '#'
+ case 14958: // 'default' '#'
+ case 14959: // 'delete' '#'
+ case 14960: // 'descendant' '#'
+ case 14961: // 'descendant-or-self' '#'
+ case 14962: // 'descending' '#'
+ case 14967: // 'div' '#'
+ case 14968: // 'document' '#'
+ case 14970: // 'element' '#'
+ case 14971: // 'else' '#'
+ case 14972: // 'empty' '#'
+ case 14974: // 'encoding' '#'
+ case 14975: // 'end' '#'
+ case 14977: // 'eq' '#'
+ case 14978: // 'every' '#'
+ case 14980: // 'except' '#'
+ case 14981: // 'exit' '#'
+ case 14982: // 'external' '#'
+ case 14983: // 'false' '#'
+ case 14984: // 'first' '#'
+ case 14985: // 'following' '#'
+ case 14986: // 'following-sibling' '#'
+ case 14987: // 'for' '#'
+ case 14990: // 'from' '#'
+ case 14991: // 'ft-option' '#'
+ case 14996: // 'ge' '#'
+ case 14998: // 'group' '#'
+ case 15000: // 'gt' '#'
+ case 15001: // 'idiv' '#'
+ case 15003: // 'import' '#'
+ case 15004: // 'in' '#'
+ case 15005: // 'index' '#'
+ case 15009: // 'insert' '#'
+ case 15010: // 'instance' '#'
+ case 15011: // 'integrity' '#'
+ case 15012: // 'intersect' '#'
+ case 15013: // 'into' '#'
+ case 15014: // 'is' '#'
+ case 15016: // 'json' '#'
+ case 15018: // 'jsoniq' '#'
+ case 15021: // 'last' '#'
+ case 15022: // 'lax' '#'
+ case 15023: // 'le' '#'
+ case 15025: // 'let' '#'
+ case 15027: // 'loop' '#'
+ case 15029: // 'lt' '#'
+ case 15031: // 'mod' '#'
+ case 15032: // 'modify' '#'
+ case 15033: // 'module' '#'
+ case 15035: // 'namespace' '#'
+ case 15037: // 'ne' '#'
+ case 15043: // 'nodes' '#'
+ case 15045: // 'null' '#'
+ case 15046: // 'object' '#'
+ case 15050: // 'only' '#'
+ case 15051: // 'option' '#'
+ case 15052: // 'or' '#'
+ case 15053: // 'order' '#'
+ case 15054: // 'ordered' '#'
+ case 15055: // 'ordering' '#'
+ case 15058: // 'parent' '#'
+ case 15064: // 'preceding' '#'
+ case 15065: // 'preceding-sibling' '#'
+ case 15068: // 'processing-instruction' '#'
+ case 15070: // 'rename' '#'
+ case 15071: // 'replace' '#'
+ case 15072: // 'return' '#'
+ case 15073: // 'returning' '#'
+ case 15074: // 'revalidation' '#'
+ case 15076: // 'satisfies' '#'
+ case 15077: // 'schema' '#'
+ case 15080: // 'score' '#'
+ case 15081: // 'select' '#'
+ case 15082: // 'self' '#'
+ case 15087: // 'sliding' '#'
+ case 15088: // 'some' '#'
+ case 15089: // 'stable' '#'
+ case 15090: // 'start' '#'
+ case 15093: // 'strict' '#'
+ case 15097: // 'text' '#'
+ case 15101: // 'to' '#'
+ case 15102: // 'treat' '#'
+ case 15103: // 'true' '#'
+ case 15104: // 'try' '#'
+ case 15105: // 'tumbling' '#'
+ case 15106: // 'type' '#'
+ case 15108: // 'union' '#'
+ case 15110: // 'unordered' '#'
+ case 15111: // 'updating' '#'
+ case 15114: // 'validate' '#'
+ case 15115: // 'value' '#'
+ case 15116: // 'variable' '#'
+ case 15117: // 'version' '#'
+ case 15120: // 'where' '#'
+ case 15121: // 'while' '#'
+ case 15124: // 'with' '#'
+ try_FunctionItemExpr();
+ break;
+ case -10:
+ case 27929: // '{' ';'
+ try_BlockExpr();
+ break;
+ case -11:
+ case 10009: // '{' NCName^Token
+ try_ObjectConstructor();
+ break;
+ case 69: // '['
+ try_ArrayConstructor();
+ break;
+ case 283: // '{|'
+ try_JSONSimpleObjectUnion();
+ break;
+ case -14:
+ break;
+ default:
+ try_Constructor();
+ }
+ }
+
+ function parse_JSONSimpleObjectUnion()
+ {
+ eventHandler.startNonterminal("JSONSimpleObjectUnion", e0);
+ shift(283); // '{|'
+ lookahead1W(273); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 286) // '|}'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(286); // '|}'
+ eventHandler.endNonterminal("JSONSimpleObjectUnion", e0);
+ }
+
+ function try_JSONSimpleObjectUnion()
+ {
+ shiftT(283); // '{|'
+ lookahead1W(273); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 286) // '|}'
+ {
+ try_Expr();
+ }
+ shiftT(286); // '|}'
+ }
+
+ function parse_ObjectConstructor()
+ {
+ eventHandler.startNonterminal("ObjectConstructor", e0);
+ shift(281); // '{'
+ lookahead1W(276); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 287) // '}'
+ {
+ whitespace();
+ parse_PairConstructorList();
+ }
+ shift(287); // '}'
+ eventHandler.endNonterminal("ObjectConstructor", e0);
+ }
+
+ function try_ObjectConstructor()
+ {
+ shiftT(281); // '{'
+ lookahead1W(276); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 287) // '}'
+ {
+ try_PairConstructorList();
+ }
+ shiftT(287); // '}'
+ }
+
+ function parse_PairConstructorList()
+ {
+ eventHandler.startNonterminal("PairConstructorList", e0);
+ parse_PairConstructor();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shift(42); // ','
+ lookahead1W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PairConstructor();
+ }
+ eventHandler.endNonterminal("PairConstructorList", e0);
+ }
+
+ function try_PairConstructorList()
+ {
+ try_PairConstructor();
+ for (;;)
+ {
+ if (l1 != 42) // ','
+ {
+ break;
+ }
+ shiftT(42); // ','
+ lookahead1W(267); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PairConstructor();
+ }
+ }
+
+ function parse_PairConstructor()
+ {
+ eventHandler.startNonterminal("PairConstructor", e0);
+ switch (l1)
+ {
+ case 78: // 'append'
+ lookahead2W(278); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 139: // 'for'
+ lookahead2W(187); // S^WS | '#' | '$' | '(' | '(:' | ':' | 'sliding' | 'tumbling'
+ break;
+ case 161: // 'insert'
+ lookahead2W(281); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 177: // 'let'
+ lookahead2W(178); // S^WS | '#' | '$' | '(' | '(:' | ':' | 'score'
+ break;
+ case 187: // 'namespace'
+ lookahead2W(251); // NCName^Token | S^WS | '#' | '(' | '(:' | ':' | 'after' | 'allowing' |
+ break;
+ case 220: // 'processing-instruction'
+ lookahead2W(247); // NCName^Token | S^WS | '#' | '(:' | ':' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 223: // 'replace'
+ lookahead2W(180); // S^WS | '#' | '(' | '(:' | ':' | 'node' | 'value'
+ break;
+ case 266: // 'validate'
+ lookahead2W(191); // S^WS | '#' | '(' | '(:' | ':' | 'lax' | 'strict' | 'type' | '{'
+ break;
+ case 83: // 'attribute'
+ case 122: // 'element'
+ lookahead2W(256); // EQName^Token | S^WS | '#' | '(:' | ':' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 97: // 'comment'
+ case 249: // 'text'
+ lookahead2W(149); // S^WS | '#' | '(:' | ':' | '{'
+ break;
+ case 111: // 'delete'
+ case 222: // 'rename'
+ lookahead2W(261); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 104: // 'copy'
+ case 130: // 'every'
+ case 240: // 'some'
+ lookahead2W(165); // S^WS | '#' | '$' | '(' | '(:' | ':'
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(208); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '.' | '/' | '//' | ':' |
+ break;
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 256: // 'try'
+ case 262: // 'unordered'
+ lookahead2W(167); // S^WS | '#' | '(' | '(:' | ':' | '{'
+ break;
+ case 121: // 'document-node'
+ case 125: // 'empty-sequence'
+ case 167: // 'item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ lookahead2W(96); // S^WS | '#' | '(:' | ':'
+ break;
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 76: // 'and'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 87: // 'break'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 94: // 'child'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 103: // 'continue'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 132: // 'except'
+ case 133: // 'exit'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 147: // 'function'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 154: // 'if'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 189: // 'ne'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 234: // 'self'
+ case 239: // 'sliding'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 248: // 'switch'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 259: // 'typeswitch'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 267: // 'value'
+ case 268: // 'variable'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(144); // S^WS | '#' | '(' | '(:' | ':'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 25735 // 'false' ':'
+ || lk == 25797 // 'null' ':'
+ || lk == 25855) // 'true' ':'
+ {
+ lk = memoized(21, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ExprSingle();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(21, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -2:
+ case 19: // NCName^Token
+ case 25671: // 'after' ':'
+ case 25673: // 'allowing' ':'
+ case 25674: // 'ancestor' ':'
+ case 25675: // 'ancestor-or-self' ':'
+ case 25676: // 'and' ':'
+ case 25678: // 'append' ':'
+ case 25680: // 'as' ':'
+ case 25681: // 'ascending' ':'
+ case 25682: // 'at' ':'
+ case 25683: // 'attribute' ':'
+ case 25684: // 'base-uri' ':'
+ case 25685: // 'before' ':'
+ case 25686: // 'boundary-space' ':'
+ case 25687: // 'break' ':'
+ case 25689: // 'case' ':'
+ case 25690: // 'cast' ':'
+ case 25691: // 'castable' ':'
+ case 25692: // 'catch' ':'
+ case 25694: // 'child' ':'
+ case 25695: // 'collation' ':'
+ case 25697: // 'comment' ':'
+ case 25698: // 'constraint' ':'
+ case 25699: // 'construction' ':'
+ case 25702: // 'context' ':'
+ case 25703: // 'continue' ':'
+ case 25704: // 'copy' ':'
+ case 25705: // 'copy-namespaces' ':'
+ case 25706: // 'count' ':'
+ case 25707: // 'decimal-format' ':'
+ case 25709: // 'declare' ':'
+ case 25710: // 'default' ':'
+ case 25711: // 'delete' ':'
+ case 25712: // 'descendant' ':'
+ case 25713: // 'descendant-or-self' ':'
+ case 25714: // 'descending' ':'
+ case 25719: // 'div' ':'
+ case 25720: // 'document' ':'
+ case 25721: // 'document-node' ':'
+ case 25722: // 'element' ':'
+ case 25723: // 'else' ':'
+ case 25724: // 'empty' ':'
+ case 25725: // 'empty-sequence' ':'
+ case 25726: // 'encoding' ':'
+ case 25727: // 'end' ':'
+ case 25729: // 'eq' ':'
+ case 25730: // 'every' ':'
+ case 25732: // 'except' ':'
+ case 25733: // 'exit' ':'
+ case 25734: // 'external' ':'
+ case 25736: // 'first' ':'
+ case 25737: // 'following' ':'
+ case 25738: // 'following-sibling' ':'
+ case 25739: // 'for' ':'
+ case 25742: // 'from' ':'
+ case 25743: // 'ft-option' ':'
+ case 25747: // 'function' ':'
+ case 25748: // 'ge' ':'
+ case 25750: // 'group' ':'
+ case 25752: // 'gt' ':'
+ case 25753: // 'idiv' ':'
+ case 25754: // 'if' ':'
+ case 25755: // 'import' ':'
+ case 25756: // 'in' ':'
+ case 25757: // 'index' ':'
+ case 25761: // 'insert' ':'
+ case 25762: // 'instance' ':'
+ case 25763: // 'integrity' ':'
+ case 25764: // 'intersect' ':'
+ case 25765: // 'into' ':'
+ case 25766: // 'is' ':'
+ case 25767: // 'item' ':'
+ case 25768: // 'json' ':'
+ case 25770: // 'jsoniq' ':'
+ case 25773: // 'last' ':'
+ case 25774: // 'lax' ':'
+ case 25775: // 'le' ':'
+ case 25777: // 'let' ':'
+ case 25779: // 'loop' ':'
+ case 25781: // 'lt' ':'
+ case 25783: // 'mod' ':'
+ case 25784: // 'modify' ':'
+ case 25785: // 'module' ':'
+ case 25787: // 'namespace' ':'
+ case 25788: // 'namespace-node' ':'
+ case 25789: // 'ne' ':'
+ case 25794: // 'node' ':'
+ case 25795: // 'nodes' ':'
+ case 25798: // 'object' ':'
+ case 25802: // 'only' ':'
+ case 25803: // 'option' ':'
+ case 25804: // 'or' ':'
+ case 25805: // 'order' ':'
+ case 25806: // 'ordered' ':'
+ case 25807: // 'ordering' ':'
+ case 25810: // 'parent' ':'
+ case 25816: // 'preceding' ':'
+ case 25817: // 'preceding-sibling' ':'
+ case 25820: // 'processing-instruction' ':'
+ case 25822: // 'rename' ':'
+ case 25823: // 'replace' ':'
+ case 25824: // 'return' ':'
+ case 25825: // 'returning' ':'
+ case 25826: // 'revalidation' ':'
+ case 25828: // 'satisfies' ':'
+ case 25829: // 'schema' ':'
+ case 25830: // 'schema-attribute' ':'
+ case 25831: // 'schema-element' ':'
+ case 25832: // 'score' ':'
+ case 25833: // 'select' ':'
+ case 25834: // 'self' ':'
+ case 25839: // 'sliding' ':'
+ case 25840: // 'some' ':'
+ case 25841: // 'stable' ':'
+ case 25842: // 'start' ':'
+ case 25845: // 'strict' ':'
+ case 25848: // 'switch' ':'
+ case 25849: // 'text' ':'
+ case 25853: // 'to' ':'
+ case 25854: // 'treat' ':'
+ case 25856: // 'try' ':'
+ case 25857: // 'tumbling' ':'
+ case 25858: // 'type' ':'
+ case 25859: // 'typeswitch' ':'
+ case 25860: // 'union' ':'
+ case 25862: // 'unordered' ':'
+ case 25863: // 'updating' ':'
+ case 25866: // 'validate' ':'
+ case 25867: // 'value' ':'
+ case 25868: // 'variable' ':'
+ case 25869: // 'version' ':'
+ case 25872: // 'where' ':'
+ case 25873: // 'while' ':'
+ case 25876: // 'with' ':'
+ parse_NCName();
+ break;
+ default:
+ parse_ExprSingle();
+ }
+ lookahead1W(26); // S^WS | '(:' | ':'
+ shift(50); // ':'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("PairConstructor", e0);
+ }
+
+ function try_PairConstructor()
+ {
+ switch (l1)
+ {
+ case 78: // 'append'
+ lookahead2W(278); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 139: // 'for'
+ lookahead2W(187); // S^WS | '#' | '$' | '(' | '(:' | ':' | 'sliding' | 'tumbling'
+ break;
+ case 161: // 'insert'
+ lookahead2W(281); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 177: // 'let'
+ lookahead2W(178); // S^WS | '#' | '$' | '(' | '(:' | ':' | 'score'
+ break;
+ case 187: // 'namespace'
+ lookahead2W(251); // NCName^Token | S^WS | '#' | '(' | '(:' | ':' | 'after' | 'allowing' |
+ break;
+ case 220: // 'processing-instruction'
+ lookahead2W(247); // NCName^Token | S^WS | '#' | '(:' | ':' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 223: // 'replace'
+ lookahead2W(180); // S^WS | '#' | '(' | '(:' | ':' | 'node' | 'value'
+ break;
+ case 266: // 'validate'
+ lookahead2W(191); // S^WS | '#' | '(' | '(:' | ':' | 'lax' | 'strict' | 'type' | '{'
+ break;
+ case 83: // 'attribute'
+ case 122: // 'element'
+ lookahead2W(256); // EQName^Token | S^WS | '#' | '(:' | ':' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 97: // 'comment'
+ case 249: // 'text'
+ lookahead2W(149); // S^WS | '#' | '(:' | ':' | '{'
+ break;
+ case 111: // 'delete'
+ case 222: // 'rename'
+ lookahead2W(261); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ break;
+ case 104: // 'copy'
+ case 130: // 'every'
+ case 240: // 'some'
+ lookahead2W(165); // S^WS | '#' | '$' | '(' | '(:' | ':'
+ break;
+ case 135: // 'false'
+ case 197: // 'null'
+ case 255: // 'true'
+ lookahead2W(208); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '.' | '/' | '//' | ':' |
+ break;
+ case 120: // 'document'
+ case 206: // 'ordered'
+ case 256: // 'try'
+ case 262: // 'unordered'
+ lookahead2W(167); // S^WS | '#' | '(' | '(:' | ':' | '{'
+ break;
+ case 121: // 'document-node'
+ case 125: // 'empty-sequence'
+ case 167: // 'item'
+ case 188: // 'namespace-node'
+ case 194: // 'node'
+ case 230: // 'schema-attribute'
+ case 231: // 'schema-element'
+ lookahead2W(96); // S^WS | '#' | '(:' | ':'
+ break;
+ case 71: // 'after'
+ case 73: // 'allowing'
+ case 74: // 'ancestor'
+ case 75: // 'ancestor-or-self'
+ case 76: // 'and'
+ case 80: // 'as'
+ case 81: // 'ascending'
+ case 82: // 'at'
+ case 84: // 'base-uri'
+ case 85: // 'before'
+ case 86: // 'boundary-space'
+ case 87: // 'break'
+ case 89: // 'case'
+ case 90: // 'cast'
+ case 91: // 'castable'
+ case 92: // 'catch'
+ case 94: // 'child'
+ case 95: // 'collation'
+ case 98: // 'constraint'
+ case 99: // 'construction'
+ case 102: // 'context'
+ case 103: // 'continue'
+ case 105: // 'copy-namespaces'
+ case 106: // 'count'
+ case 107: // 'decimal-format'
+ case 109: // 'declare'
+ case 110: // 'default'
+ case 112: // 'descendant'
+ case 113: // 'descendant-or-self'
+ case 114: // 'descending'
+ case 119: // 'div'
+ case 123: // 'else'
+ case 124: // 'empty'
+ case 126: // 'encoding'
+ case 127: // 'end'
+ case 129: // 'eq'
+ case 132: // 'except'
+ case 133: // 'exit'
+ case 134: // 'external'
+ case 136: // 'first'
+ case 137: // 'following'
+ case 138: // 'following-sibling'
+ case 142: // 'from'
+ case 143: // 'ft-option'
+ case 147: // 'function'
+ case 148: // 'ge'
+ case 150: // 'group'
+ case 152: // 'gt'
+ case 153: // 'idiv'
+ case 154: // 'if'
+ case 155: // 'import'
+ case 156: // 'in'
+ case 157: // 'index'
+ case 162: // 'instance'
+ case 163: // 'integrity'
+ case 164: // 'intersect'
+ case 165: // 'into'
+ case 166: // 'is'
+ case 168: // 'json'
+ case 170: // 'jsoniq'
+ case 173: // 'last'
+ case 174: // 'lax'
+ case 175: // 'le'
+ case 179: // 'loop'
+ case 181: // 'lt'
+ case 183: // 'mod'
+ case 184: // 'modify'
+ case 185: // 'module'
+ case 189: // 'ne'
+ case 195: // 'nodes'
+ case 198: // 'object'
+ case 202: // 'only'
+ case 203: // 'option'
+ case 204: // 'or'
+ case 205: // 'order'
+ case 207: // 'ordering'
+ case 210: // 'parent'
+ case 216: // 'preceding'
+ case 217: // 'preceding-sibling'
+ case 224: // 'return'
+ case 225: // 'returning'
+ case 226: // 'revalidation'
+ case 228: // 'satisfies'
+ case 229: // 'schema'
+ case 232: // 'score'
+ case 233: // 'select'
+ case 234: // 'self'
+ case 239: // 'sliding'
+ case 241: // 'stable'
+ case 242: // 'start'
+ case 245: // 'strict'
+ case 248: // 'switch'
+ case 253: // 'to'
+ case 254: // 'treat'
+ case 257: // 'tumbling'
+ case 258: // 'type'
+ case 259: // 'typeswitch'
+ case 260: // 'union'
+ case 263: // 'updating'
+ case 267: // 'value'
+ case 268: // 'variable'
+ case 269: // 'version'
+ case 272: // 'where'
+ case 273: // 'while'
+ case 276: // 'with'
+ lookahead2W(144); // S^WS | '#' | '(' | '(:' | ':'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 25735 // 'false' ':'
+ || lk == 25797 // 'null' ':'
+ || lk == 25855) // 'true' ':'
+ {
+ lk = memoized(21, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ExprSingle();
+ memoize(21, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(21, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -2:
+ case 19: // NCName^Token
+ case 25671: // 'after' ':'
+ case 25673: // 'allowing' ':'
+ case 25674: // 'ancestor' ':'
+ case 25675: // 'ancestor-or-self' ':'
+ case 25676: // 'and' ':'
+ case 25678: // 'append' ':'
+ case 25680: // 'as' ':'
+ case 25681: // 'ascending' ':'
+ case 25682: // 'at' ':'
+ case 25683: // 'attribute' ':'
+ case 25684: // 'base-uri' ':'
+ case 25685: // 'before' ':'
+ case 25686: // 'boundary-space' ':'
+ case 25687: // 'break' ':'
+ case 25689: // 'case' ':'
+ case 25690: // 'cast' ':'
+ case 25691: // 'castable' ':'
+ case 25692: // 'catch' ':'
+ case 25694: // 'child' ':'
+ case 25695: // 'collation' ':'
+ case 25697: // 'comment' ':'
+ case 25698: // 'constraint' ':'
+ case 25699: // 'construction' ':'
+ case 25702: // 'context' ':'
+ case 25703: // 'continue' ':'
+ case 25704: // 'copy' ':'
+ case 25705: // 'copy-namespaces' ':'
+ case 25706: // 'count' ':'
+ case 25707: // 'decimal-format' ':'
+ case 25709: // 'declare' ':'
+ case 25710: // 'default' ':'
+ case 25711: // 'delete' ':'
+ case 25712: // 'descendant' ':'
+ case 25713: // 'descendant-or-self' ':'
+ case 25714: // 'descending' ':'
+ case 25719: // 'div' ':'
+ case 25720: // 'document' ':'
+ case 25721: // 'document-node' ':'
+ case 25722: // 'element' ':'
+ case 25723: // 'else' ':'
+ case 25724: // 'empty' ':'
+ case 25725: // 'empty-sequence' ':'
+ case 25726: // 'encoding' ':'
+ case 25727: // 'end' ':'
+ case 25729: // 'eq' ':'
+ case 25730: // 'every' ':'
+ case 25732: // 'except' ':'
+ case 25733: // 'exit' ':'
+ case 25734: // 'external' ':'
+ case 25736: // 'first' ':'
+ case 25737: // 'following' ':'
+ case 25738: // 'following-sibling' ':'
+ case 25739: // 'for' ':'
+ case 25742: // 'from' ':'
+ case 25743: // 'ft-option' ':'
+ case 25747: // 'function' ':'
+ case 25748: // 'ge' ':'
+ case 25750: // 'group' ':'
+ case 25752: // 'gt' ':'
+ case 25753: // 'idiv' ':'
+ case 25754: // 'if' ':'
+ case 25755: // 'import' ':'
+ case 25756: // 'in' ':'
+ case 25757: // 'index' ':'
+ case 25761: // 'insert' ':'
+ case 25762: // 'instance' ':'
+ case 25763: // 'integrity' ':'
+ case 25764: // 'intersect' ':'
+ case 25765: // 'into' ':'
+ case 25766: // 'is' ':'
+ case 25767: // 'item' ':'
+ case 25768: // 'json' ':'
+ case 25770: // 'jsoniq' ':'
+ case 25773: // 'last' ':'
+ case 25774: // 'lax' ':'
+ case 25775: // 'le' ':'
+ case 25777: // 'let' ':'
+ case 25779: // 'loop' ':'
+ case 25781: // 'lt' ':'
+ case 25783: // 'mod' ':'
+ case 25784: // 'modify' ':'
+ case 25785: // 'module' ':'
+ case 25787: // 'namespace' ':'
+ case 25788: // 'namespace-node' ':'
+ case 25789: // 'ne' ':'
+ case 25794: // 'node' ':'
+ case 25795: // 'nodes' ':'
+ case 25798: // 'object' ':'
+ case 25802: // 'only' ':'
+ case 25803: // 'option' ':'
+ case 25804: // 'or' ':'
+ case 25805: // 'order' ':'
+ case 25806: // 'ordered' ':'
+ case 25807: // 'ordering' ':'
+ case 25810: // 'parent' ':'
+ case 25816: // 'preceding' ':'
+ case 25817: // 'preceding-sibling' ':'
+ case 25820: // 'processing-instruction' ':'
+ case 25822: // 'rename' ':'
+ case 25823: // 'replace' ':'
+ case 25824: // 'return' ':'
+ case 25825: // 'returning' ':'
+ case 25826: // 'revalidation' ':'
+ case 25828: // 'satisfies' ':'
+ case 25829: // 'schema' ':'
+ case 25830: // 'schema-attribute' ':'
+ case 25831: // 'schema-element' ':'
+ case 25832: // 'score' ':'
+ case 25833: // 'select' ':'
+ case 25834: // 'self' ':'
+ case 25839: // 'sliding' ':'
+ case 25840: // 'some' ':'
+ case 25841: // 'stable' ':'
+ case 25842: // 'start' ':'
+ case 25845: // 'strict' ':'
+ case 25848: // 'switch' ':'
+ case 25849: // 'text' ':'
+ case 25853: // 'to' ':'
+ case 25854: // 'treat' ':'
+ case 25856: // 'try' ':'
+ case 25857: // 'tumbling' ':'
+ case 25858: // 'type' ':'
+ case 25859: // 'typeswitch' ':'
+ case 25860: // 'union' ':'
+ case 25862: // 'unordered' ':'
+ case 25863: // 'updating' ':'
+ case 25866: // 'validate' ':'
+ case 25867: // 'value' ':'
+ case 25868: // 'variable' ':'
+ case 25869: // 'version' ':'
+ case 25872: // 'where' ':'
+ case 25873: // 'while' ':'
+ case 25876: // 'with' ':'
+ try_NCName();
+ break;
+ case -3:
+ break;
+ default:
+ try_ExprSingle();
+ }
+ lookahead1W(26); // S^WS | '(:' | ':'
+ shiftT(50); // ':'
+ lookahead1W(266); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_ArrayConstructor()
+ {
+ eventHandler.startNonterminal("ArrayConstructor", e0);
+ shift(69); // '['
+ lookahead1W(272); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 70) // ']'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(70); // ']'
+ eventHandler.endNonterminal("ArrayConstructor", e0);
+ }
+
+ function try_ArrayConstructor()
+ {
+ shiftT(69); // '['
+ lookahead1W(272); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ if (l1 != 70) // ']'
+ {
+ try_Expr();
+ }
+ shiftT(70); // ']'
+ }
+
+ function parse_BlockExpr()
+ {
+ eventHandler.startNonterminal("BlockExpr", e0);
+ shift(281); // '{'
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_StatementsAndOptionalExpr();
+ shift(287); // '}'
+ eventHandler.endNonterminal("BlockExpr", e0);
+ }
+
+ function try_BlockExpr()
+ {
+ shiftT(281); // '{'
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_StatementsAndOptionalExpr();
+ shiftT(287); // '}'
+ }
+
+ function parse_FunctionDecl()
+ {
+ eventHandler.startNonterminal("FunctionDecl", e0);
+ shift(147); // 'function'
+ lookahead1W(245); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(35); // '('
+ lookahead1W(98); // S^WS | '$' | '(:' | ')'
+ if (l1 == 31) // '$'
+ {
+ whitespace();
+ parse_ParamList();
+ }
+ shift(38); // ')'
+ lookahead1W(158); // S^WS | '(:' | 'as' | 'external' | '{'
+ if (l1 == 80) // 'as'
+ {
+ whitespace();
+ parse_ReturnType();
+ }
+ lookahead1W(122); // S^WS | '(:' | 'external' | '{'
+ switch (l1)
+ {
+ case 281: // '{'
+ shift(281); // '{'
+ lookahead1W(280); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_StatementsAndOptionalExpr();
+ shift(287); // '}'
+ break;
+ default:
+ shift(134); // 'external'
+ }
+ eventHandler.endNonterminal("FunctionDecl", e0);
+ }
+
+ function parse_ReturnType()
+ {
+ eventHandler.startNonterminal("ReturnType", e0);
+ shift(80); // 'as'
+ lookahead1W(253); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ eventHandler.endNonterminal("ReturnType", e0);
+ }
+
+ function shift(t)
+ {
+ if (l1 == t)
+ {
+ whitespace();
+ eventHandler.terminal(JSONiqParser.TOKEN[l1], b1, e1 > size ? size : e1);
+ b0 = b1; e0 = e1; l1 = l2; if (l1 != 0) {
+ b1 = b2; e1 = e2; l2 = 0; }
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function shiftT(t)
+ {
+ if (l1 == t)
+ {
+ b0 = b1; e0 = e1; l1 = l2; if (l1 != 0) {
+ b1 = b2; e1 = e2; l2 = 0; }
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function skip(code)
+ {
+ var b0W = b0; var e0W = e0; var l1W = l1;
+ var b1W = b1; var e1W = e1;
+
+ l1 = code; b1 = begin; e1 = end;
+ l2 = 0;
+
+ try_Whitespace();
+
+ b0 = b0W; e0 = e0W; l1 = l1W; if (l1 != 0) {
+ b1 = b1W; e1 = e1W; }
+ }
+
+ function whitespace()
+ {
+ if (e0 != b1)
+ {
+ eventHandler.whitespace(e0, b1);
+ e0 = b1;
+ }
+ }
+
+ function matchW(set)
+ {
+ var code;
+ for (;;)
+ {
+ code = match(set);
+ if (code != 22) // S^WS
+ {
+ if (code != 37) // '(:'
+ {
+ break;
+ }
+ skip(code);
+ }
+ }
+ return code;
+ }
+
+ function lookahead1W(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = matchW(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead2W(set)
+ {
+ if (l2 == 0)
+ {
+ l2 = matchW(set);
+ b2 = begin;
+ e2 = end;
+ }
+ lk = (l2 << 9) | l1;
+ }
+
+ function lookahead1(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = match(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead2(set)
+ {
+ if (l2 == 0)
+ {
+ l2 = match(set);
+ b2 = begin;
+ e2 = end;
+ }
+ lk = (l2 << 9) | l1;
+ }
+
+ function error(b, e, s, l, t)
+ {
+ if (e >= ex)
+ {
+ bx = b;
+ ex = e;
+ sx = s;
+ lx = l;
+ tx = t;
+ }
+ throw new self.ParseException(bx, ex, sx, lx, tx);
+ }
+
+ var lk, b0, e0;
+ var l1, b1, e1;
+ var l2, b2, e2;
+ var bx, ex, sx, lx, tx;
+ var eventHandler;
+ var memo;
+
+ function memoize(i, e, v)
+ {
+ memo[(e << 5) + i] = v;
+ }
+
+ function memoized(i, e)
+ {
+ var v = memo[(e << 5) + i];
+ return typeof v != "undefined" ? v : 0;
+ }
+
+ var input;
+ var size;
+ var begin;
+ var end;
+
+ function match(tokenSetId)
+ {
+ var nonbmp = false;
+ begin = end;
+ var current = end;
+ var result = JSONiqParser.INITIAL[tokenSetId];
+ var state = 0;
+
+ for (var code = result & 8191; code != 0; )
+ {
+ var charclass;
+ var c0 = current < size ? input.charCodeAt(current) : 0;
+ ++current;
+ if (c0 < 0x80)
+ {
+ charclass = JSONiqParser.MAP0[c0];
+ }
+ else if (c0 < 0xd800)
+ {
+ var c1 = c0 >> 4;
+ charclass = JSONiqParser.MAP1[(c0 & 15) + JSONiqParser.MAP1[(c1 & 31) + JSONiqParser.MAP1[c1 >> 5]]];
+ }
+ else
+ {
+ if (c0 < 0xdc00)
+ {
+ var c1 = current < size ? input.charCodeAt(current) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000)
+ {
+ ++current;
+ c0 = ((c0 & 0x3ff) << 10) + (c1 & 0x3ff) + 0x10000;
+ nonbmp = true;
+ }
+ }
+ var lo = 0, hi = 5;
+ for (var m = 3; ; m = (hi + lo) >> 1)
+ {
+ if (JSONiqParser.MAP2[m] > c0) hi = m - 1;
+ else if (JSONiqParser.MAP2[6 + m] < c0) lo = m + 1;
+ else {charclass = JSONiqParser.MAP2[12 + m]; break;}
+ if (lo > hi) {charclass = 0; break;}
+ }
+ }
+
+ state = code;
+ var i0 = (charclass << 13) + code - 1;
+ code = JSONiqParser.TRANSITION[(i0 & 31) + JSONiqParser.TRANSITION[i0 >> 5]];
+
+ if (code > 8191)
+ {
+ result = code;
+ code &= 8191;
+ end = current;
+ }
+ }
+
+ result >>= 13;
+ if (result == 0)
+ {
+ end = current - 1;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ return error(begin, end, state, -1, -1);
+ }
+
+ if (nonbmp)
+ {
+ for (var i = result >> 9; i > 0; --i)
+ {
+ --end;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ }
+ }
+ else
+ {
+ end -= result >> 9;
+ }
+
+ return (result & 511) - 1;
+ }
+}
+
+JSONiqParser.getTokenSet = function(tokenSetId)
+{
+ var set = [];
+ var s = tokenSetId < 0 ? - tokenSetId : JSONiqParser.INITIAL[tokenSetId] & 8191;
+ for (var i = 0; i < 289; i += 32)
+ {
+ var j = i;
+ var i0 = (i >> 5) * 4235 + s - 1;
+ var i1 = i0 >> 2;
+ var i2 = i1 >> 2;
+ var f = JSONiqParser.EXPECTED[(i0 & 3) + JSONiqParser.EXPECTED[(i1 & 3) + JSONiqParser.EXPECTED[(i2 & 15) + JSONiqParser.EXPECTED[i2 >> 4]]]];
+ for ( ; f != 0; f >>>= 1, ++j)
+ {
+ if ((f & 1) != 0)
+ {
+ set.push(JSONiqParser.TOKEN[j]);
+ }
+ }
+ }
+ return set;
+};
+
+JSONiqParser.MAP0 =
+[ 71, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 26, 30, 30, 30, 30, 30, 31, 32, 33, 30, 30, 34, 30, 30, 35, 30, 30, 30, 36, 30, 30, 37, 38, 39, 40, 30, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 40, 40
+];
+
+JSONiqParser.MAP1 =
+[ 108, 124, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 156, 181, 181, 181, 181, 181, 214, 215, 213, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 247, 261, 277, 293, 309, 355, 371, 387, 423, 423, 423, 415, 339, 331, 339, 331, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 440, 440, 440, 440, 440, 440, 440, 324, 339, 339, 339, 339, 339, 339, 339, 339, 401, 423, 423, 424, 422, 423, 423, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 338, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 423, 71, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 26, 30, 30, 30, 30, 30, 31, 32, 33, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 40, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 34, 30, 30, 35, 30, 30, 30, 36, 30, 30, 37, 38, 39, 40, 30, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 30, 30, 40, 40, 40, 40, 40, 40, 40, 70, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70, 70
+];
+
+JSONiqParser.MAP2 =
+[ 57344, 63744, 64976, 65008, 65536, 983040, 63743, 64975, 65007, 65533, 983039, 1114111, 40, 30, 40, 30, 30, 40
+];
+
+JSONiqParser.INITIAL =
+[ 1, 24578, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, 289
+];
+
+JSONiqParser.TRANSITION =
+[ 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 18432, 18508, 18512, 18508, 18508, 18471, 18503, 18452, 18508, 18544, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 53140, 22565, 22594, 54694, 22641, 32640, 25253, 32640, 22707, 32640, 32640, 18907, 32640, 40804, 19219, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22757, 32640, 23442, 32640, 20728, 22822, 22912, 62853, 22949, 23023, 32640, 25253, 37379, 72986, 32640, 32640, 18907, 32640, 23058, 40482, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 23090, 32640, 70756, 57235, 23625, 57174, 23143, 53889, 57205, 23194, 32640, 44590, 57237, 72986, 32640, 32640, 18907, 32640, 23058, 18925, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 22132, 19073, 46732, 23294, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 23361, 32640, 61740, 23437, 23807, 23824, 22912, 35136, 23474, 23607, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 40461, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 57592, 32640, 53140, 23657, 43708, 23704, 23789, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 39259, 23856, 32640, 32640, 23893, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 73053, 22069, 23965, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 24031, 32640, 23861, 32640, 22776, 24082, 22912, 56240, 24206, 24329, 32640, 25253, 32640, 24379, 32640, 32640, 18907, 32640, 23058, 57529, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 24415, 24449, 24453, 24440, 24534, 24485, 24515, 24566, 24596, 24628, 32640, 32105, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 45903, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 24678, 32640, 61740, 24746, 48361, 53140, 24789, 24808, 24825, 24857, 32640, 27397, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 45563, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 24907, 32640, 61740, 32640, 32640, 52064, 24984, 25013, 61799, 25045, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 25095, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 54034, 25151, 25188, 25171, 25235, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 25302, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 25340, 32640, 61740, 24702, 35413, 25353, 25385, 25402, 58363, 25449, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 25499, 32640, 61740, 32640, 32640, 53140, 25538, 25575, 25558, 25622, 32640, 25253, 32640, 72986, 32640, 32640, 49347, 54782, 64809, 35297, 64457, 32024, 25672, 25724, 32640, 25308, 42746, 72012, 48724, 25775, 59604, 63895, 70062, 53329, 26051, 44572, 32640, 32640, 53365, 69246, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 36217, 25878, 32640, 32640, 25912, 56403, 72012, 72012, 47453, 69896, 25776, 64787, 25947, 25982, 26472, 26016, 26050, 68602, 32640, 32640, 21278, 65491, 41507, 72012, 47768, 59999, 36922, 55439, 25983, 53287, 66001, 26051, 68608, 32640, 35129, 65495, 72012, 26084, 25776, 26132, 25983, 66375, 26051, 26181, 26227, 36550, 62167, 71378, 26264, 56947, 53286, 26299, 56814, 66968, 50229, 37146, 26336, 26407, 64681, 37193, 26609, 67516, 26450, 26504, 26590, 60773, 47253, 26654, 26722, 26771, 49912, 26461, 51539, 26820, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 29428, 26976, 69042, 27027, 27107, 32640, 25253, 32640, 27176, 32640, 32640, 18907, 32640, 35800, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 27212, 32640, 18617, 32640, 32640, 53140, 27264, 27332, 41428, 27379, 32640, 25253, 32640, 27446, 36386, 32640, 18907, 32640, 23058, 40482, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 27496, 32640, 61740, 32640, 32640, 45704, 22912, 32640, 27545, 27614, 32640, 25253, 32640, 27679, 32640, 32640, 49347, 54782, 51035, 35297, 32640, 32024, 32640, 27715, 32640, 25308, 72012, 72012, 48724, 25776, 59604, 25983, 61672, 26051, 26051, 49853, 32640, 32640, 70980, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 40010, 32640, 32640, 25692, 32640, 68393, 72012, 72012, 27753, 25776, 25776, 39830, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 32640, 32640, 65491, 72012, 72012, 27795, 25776, 60349, 39842, 25983, 53287, 26051, 26051, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 27836, 32640, 26232, 27985, 34535, 60068, 27930, 27958, 60099, 28032, 32640, 32366, 32640, 72986, 32640, 32640, 73079, 29194, 30273, 28620, 31154, 44986, 32640, 18612, 18649, 18757, 18789, 18959, 32755, 28084, 30249, 28403, 29274, 28141, 28173, 28885, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21681, 28259, 30189, 28317, 28376, 29214, 30382, 28201, 30288, 28732, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 28435, 28285, 28497, 28109, 28529, 28561, 28593, 28652, 28684, 28716, 19661, 19735, 19811, 19878, 19910, 19942, 28764, 21709, 32781, 28826, 28935, 28991, 29023, 29361, 30055, 20090, 20138, 20211, 20265, 29171, 28465, 29246, 28344, 29334, 29302, 29393, 20579, 20709, 20774, 29460, 29082, 29111, 29139, 29492, 29611, 20949, 21030, 29555, 29643, 29675, 28857, 29707, 21310, 29804, 29832, 29864, 29896, 29992, 30024, 30105, 30173, 28959, 30221, 29583, 29053, 28794, 28227, 30320, 30352, 29523, 30414, 30442, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 30485, 32640, 61740, 55714, 40332, 67370, 30532, 30549, 30500, 30596, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 25063, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 62487, 66570, 19251, 64424, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 30661, 19661, 19735, 19811, 19878, 19910, 19942, 30758, 30851, 33683, 30826, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 30890, 63521, 30967, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 32640, 31025, 31042, 31089, 31121, 32640, 25253, 32640, 72986, 41921, 32640, 18907, 32640, 23058, 19161, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31186, 32640, 61740, 32640, 32640, 53140, 31304, 31321, 61422, 31368, 32640, 25253, 32640, 72986, 38336, 32640, 18907, 32640, 23058, 19597, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31436, 32640, 22917, 32640, 32640, 53140, 31488, 31505, 63455, 31552, 32640, 25253, 32640, 72986, 23911, 32640, 18907, 32640, 23058, 20233, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 31603, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31688, 32640, 61740, 27887, 32640, 57839, 22912, 31734, 24347, 31775, 32640, 25253, 32640, 31840, 32640, 32640, 18907, 32640, 57508, 20515, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 53140, 22912, 32640, 62571, 27379, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 53000, 32640, 32640, 25682, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 34467, 32640, 32640, 25692, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 32640, 46497, 65491, 72012, 72012, 51277, 25776, 46932, 39842, 25983, 53287, 26051, 26051, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 52315, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 53000, 32640, 32640, 25682, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 34467, 32640, 32640, 25692, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 32640, 32640, 65491, 72012, 72012, 51277, 25776, 46932, 39842, 25983, 53287, 26051, 26051, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 53000, 32640, 32640, 25682, 32497, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 34467, 32640, 32640, 25692, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 32640, 32640, 65491, 72012, 72012, 51277, 25776, 46932, 39842, 25983, 53287, 26051, 26051, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 53000, 32640, 32640, 25682, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 34467, 32640, 32640, 20179, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 32640, 32640, 65491, 72012, 72012, 51277, 25776, 46932, 39842, 25983, 53287, 26051, 26051, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 31980, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 31979, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 53000, 32640, 32640, 25682, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 34467, 32640, 32640, 25692, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 32640, 32640, 65491, 72012, 72012, 51277, 25776, 46932, 39842, 25983, 53287, 26051, 26051, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 69771, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 41903, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 32012, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 57111, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 27513, 32056, 32087, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 31793, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32154, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32191, 32640, 61740, 32640, 32640, 53140, 32266, 32219, 32317, 32348, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 32398, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 32449, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 53140, 22912, 32640, 32640, 32541, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 40482, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32639, 61740, 32640, 32640, 53140, 32606, 32625, 66147, 32673, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 32724, 21452, 21374, 21431, 32813, 21618, 21650, 32920, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 53140, 22912, 32640, 32640, 27379, 32640, 25253, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 33014, 72814, 65242, 23329, 65262, 33049, 33078, 33110, 33141, 72172, 33868, 38406, 33224, 33302, 35892, 33415, 33497, 33529, 33657, 32640, 70241, 33715, 23262, 70547, 65483, 72012, 56115, 31942, 25776, 33771, 25983, 62395, 26051, 60426, 53000, 43338, 33820, 20169, 33900, 28052, 33936, 72012, 34004, 34096, 25776, 69679, 34153, 25983, 34209, 34305, 26051, 34381, 34413, 59316, 60982, 34567, 18580, 43988, 66280, 56105, 34613, 34671, 54769, 57995, 34763, 50540, 69616, 34835, 44365, 69116, 72659, 27683, 51215, 45101, 34941, 55781, 57901, 25776, 68182, 34981, 25983, 35037, 38017, 43551, 35100, 35168, 46148, 32692, 38542, 69316, 67857, 54357, 35200, 37506, 35270, 39191, 36089, 32640, 37090, 24260, 50683, 56669, 60278, 35348, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 43929, 35445, 35530, 35582, 50980, 66874, 47849, 48295, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 35651, 72814, 32640, 32640, 53140, 35689, 35718, 35750, 35781, 32640, 25253, 32640, 32640, 32640, 32640, 42703, 63159, 35832, 71490, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 53000, 32640, 32640, 71083, 54414, 54421, 64131, 72012, 55872, 25809, 25776, 60149, 25844, 25983, 63179, 26051, 26051, 34327, 34467, 32640, 32640, 25692, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 43098, 32640, 35952, 27144, 30726, 72012, 63213, 63138, 25776, 69714, 35989, 25983, 42068, 36035, 26051, 36069, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 20456, 36134, 36191, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 64516, 72814, 48426, 59530, 63767, 36272, 36304, 36336, 36367, 32640, 36432, 25203, 32640, 32640, 41660, 37716, 55922, 36483, 36530, 48415, 59494, 31702, 18855, 62820, 64973, 39682, 72012, 36599, 25776, 18725, 36659, 69934, 36699, 26051, 52493, 36750, 23246, 55732, 34581, 32640, 18679, 55301, 36783, 36820, 35485, 36918, 36954, 37494, 37030, 64702, 65892, 37178, 34467, 32640, 37225, 65319, 32640, 68393, 72012, 37261, 33962, 25776, 37316, 55427, 25983, 39119, 39566, 26051, 49047, 43098, 37375, 42559, 23999, 65491, 72012, 48479, 51277, 25776, 37411, 39842, 45287, 53287, 26051, 67220, 70527, 32640, 37538, 37571, 37131, 46827, 23541, 55996, 67894, 53288, 53572, 47622, 37618, 25915, 66600, 37659, 46843, 32872, 37796, 37836, 46302, 47046, 68392, 23524, 65621, 25983, 37889, 41315, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 37927, 37988, 38060, 47849, 36159, 34716, 26535, 44815, 38151, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 20106, 72814, 32509, 23162, 53140, 38224, 38253, 38285, 38316, 32640, 25253, 32640, 32640, 60657, 39330, 34441, 50711, 54836, 51195, 33270, 38384, 46719, 22206, 33192, 38438, 72385, 38511, 38616, 40937, 20657, 38673, 38705, 39528, 38892, 38940, 32640, 47380, 49323, 32640, 70823, 64131, 72012, 32968, 25809, 25776, 45195, 25844, 25983, 46666, 26051, 26051, 58683, 38996, 32640, 59450, 25692, 27180, 22361, 39052, 64136, 40912, 42209, 25776, 39090, 66443, 25983, 39151, 60300, 26051, 39223, 32640, 32640, 36102, 70444, 72012, 71366, 65683, 25776, 39291, 39362, 35619, 34803, 26051, 43538, 70527, 72942, 37229, 65495, 39402, 46827, 39434, 39492, 52767, 39560, 39598, 39731, 22659, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 19837, 68392, 68106, 33972, 25983, 39769, 58918, 26609, 71375, 56493, 39511, 67952, 33375, 70146, 67746, 39807, 39877, 27300, 39932, 39984, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 22609, 72814, 27464, 30794, 40060, 40119, 40148, 40180, 40211, 40263, 40295, 40364, 40412, 40514, 40546, 40606, 40667, 40699, 40731, 40783, 20976, 40854, 40994, 52527, 25308, 41046, 39699, 41078, 46357, 49141, 41137, 44544, 41236, 41286, 41368, 47192, 41460, 41554, 41610, 40087, 41703, 41735, 41816, 41872, 41968, 42030, 42100, 42250, 42282, 42373, 42458, 42490, 42522, 42554, 42591, 31571, 42679, 24113, 42735, 42778, 42826, 42887, 59586, 42933, 43014, 20677, 52796, 43080, 37857, 50773, 19009, 50153, 72778, 68055, 66201, 43130, 61992, 43205, 43285, 43380, 36003, 43457, 50341, 43583, 43639, 62580, 43704, 43740, 65764, 46827, 43772, 55996, 43804, 43857, 43893, 43961, 72604, 44020, 44104, 67022, 44136, 44196, 44228, 44289, 44397, 41399, 46788, 44452, 69369, 44513, 44648, 70208, 20438, 68896, 51376, 63626, 44257, 54317, 44622, 67433, 55113, 55250, 49487, 51457, 67801, 44680, 44712, 34716, 38736, 44788, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 54076, 72814, 67462, 71804, 46979, 44874, 44903, 44935, 44966, 65157, 25253, 32640, 32640, 45018, 45029, 45061, 36627, 47904, 71490, 70229, 49986, 32640, 30141, 65148, 45093, 45133, 72012, 45175, 25776, 67154, 25983, 61672, 45240, 26051, 53000, 32640, 32640, 25682, 32640, 30614, 64131, 72012, 62187, 25809, 25776, 34052, 25844, 25983, 58051, 26051, 26051, 68586, 34467, 32640, 32640, 25692, 49974, 68393, 36788, 72012, 33962, 51715, 25776, 55427, 25983, 45283, 39566, 26051, 45319, 43098, 32640, 32640, 22533, 65491, 72012, 65748, 51277, 25776, 40635, 39842, 48131, 53287, 26051, 72059, 70527, 32640, 32640, 65495, 72012, 46827, 25776, 55996, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 26195, 32640, 30913, 33383, 31947, 68516, 43425, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 38767, 44815, 45355, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 72990, 32640, 53140, 45461, 45480, 45512, 45543, 32640, 25253, 25880, 32640, 32640, 32640, 49347, 54782, 64809, 65216, 32640, 32024, 32640, 29772, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 26944, 43348, 64131, 72012, 72012, 45595, 25776, 25776, 45631, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 45666, 62963, 32640, 45736, 45143, 72012, 33962, 47777, 25776, 55427, 45634, 25983, 39566, 62106, 26051, 66507, 32640, 61374, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 45776, 65495, 72012, 45833, 25776, 43236, 25983, 48970, 26051, 35378, 19759, 45883, 40885, 45935, 34121, 45988, 46059, 68691, 46114, 46509, 48784, 46180, 46232, 52911, 56583, 46294, 61320, 46334, 46389, 52972, 46541, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 57068, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 37061, 32640, 46592, 32640, 23927, 23933, 35920, 72528, 46641, 71255, 46698, 32640, 41638, 46765, 32640, 32640, 25308, 72012, 32982, 31942, 25812, 62010, 25983, 52465, 26051, 62071, 44572, 32640, 32640, 32640, 32640, 46875, 64131, 72012, 72012, 46928, 25776, 25777, 25844, 25983, 25846, 26051, 26051, 48238, 66922, 32640, 32640, 32640, 58432, 34888, 72012, 72012, 24139, 25776, 25776, 64186, 25983, 25983, 64365, 26051, 26051, 68602, 32640, 31139, 32640, 65491, 72012, 59125, 47768, 25776, 23575, 39842, 25983, 43409, 26051, 51585, 68608, 32640, 40326, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 23989, 59115, 71381, 31947, 25983, 51580, 26788, 46560, 61892, 58181, 67203, 61301, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 48851, 72814, 23672, 46964, 47011, 47078, 47108, 47140, 47171, 32640, 41336, 32640, 50620, 20998, 40574, 47224, 47285, 49169, 47359, 32640, 35316, 31404, 32640, 22498, 71540, 47426, 22395, 47485, 41998, 47553, 68243, 35005, 43487, 49590, 47654, 45801, 22675, 32476, 32285, 47707, 67491, 67589, 47739, 47809, 47521, 53771, 47881, 39370, 54202, 70106, 63727, 47936, 58552, 32640, 49793, 48007, 32640, 65551, 71979, 37586, 48049, 48729, 71596, 33444, 48130, 48163, 50320, 48235, 48270, 34864, 70560, 48327, 48393, 48458, 72887, 48523, 38468, 37956, 42313, 48632, 55501, 51516, 36886, 48664, 48761, 48816, 50855, 27414, 41840, 48883, 63268, 48941, 45429, 49017, 55015, 49079, 32640, 22725, 23734, 49111, 51113, 69533, 55593, 49224, 46302, 49298, 68392, 71381, 31947, 25983, 51580, 58698, 26609, 49388, 58232, 70503, 49450, 42622, 70146, 67746, 49519, 60834, 49912, 26461, 39900, 47849, 56608, 49551, 26535, 44815, 49622, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 69860, 72814, 32640, 32640, 53140, 22912, 46609, 49741, 49772, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 57444, 31942, 38479, 62010, 25983, 49825, 26051, 53559, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 59709, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 61385, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 55063, 32640, 32640, 32640, 32640, 51342, 72012, 72012, 34031, 25776, 25776, 21586, 25983, 25983, 37804, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 52831, 72814, 72305, 49953, 50018, 50050, 50069, 50101, 50132, 70815, 25253, 24050, 32640, 72261, 50206, 50261, 50293, 50389, 50456, 50572, 49266, 32159, 46476, 50609, 46896, 49653, 37284, 50652, 61556, 51136, 34792, 50743, 43516, 41182, 50834, 50887, 32640, 37764, 32640, 32640, 39657, 23757, 50924, 50956, 53683, 55377, 51012, 52437, 51082, 71275, 51168, 51247, 58552, 31456, 32640, 51318, 32640, 68393, 71632, 34909, 33962, 25776, 51408, 55427, 25983, 51489, 51571, 26051, 51617, 51676, 60646, 71309, 32640, 65491, 66269, 72012, 47768, 51714, 36922, 67551, 25983, 53287, 50411, 26051, 51682, 70346, 19987, 51747, 72012, 24952, 25776, 68123, 51821, 47327, 51856, 50424, 31808, 72723, 44072, 71378, 24163, 55203, 53286, 67732, 46302, 62840, 68392, 67136, 45208, 51824, 51580, 51892, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 49192, 51996, 52096, 48579, 26535, 57041, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32641, 72814, 32640, 52167, 20380, 52202, 52231, 52263, 52294, 52373, 25253, 38352, 32640, 52375, 52359, 29926, 52407, 61167, 51195, 57599, 32024, 25590, 52525, 32640, 52559, 51778, 52613, 52685, 43173, 52736, 25950, 43825, 49580, 44319, 53632, 52043, 52828, 32640, 32640, 32640, 58759, 38563, 72012, 52863, 54749, 25776, 52943, 55231, 25984, 38908, 53056, 26018, 58552, 53105, 32640, 22853, 53172, 39020, 53205, 55838, 69472, 53239, 53488, 67539, 53276, 33788, 39566, 53320, 63643, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 53361, 32640, 72366, 71378, 53397, 57660, 53286, 53431, 46302, 32640, 68392, 71381, 47833, 35238, 66390, 37193, 26609, 71375, 60465, 43860, 63958, 50482, 38641, 53073, 53467, 53538, 49912, 26461, 39900, 47849, 36159, 48078, 53604, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 53715, 36751, 53803, 53858, 53921, 53950, 53982, 54013, 68341, 65423, 54066, 22337, 73196, 54108, 54140, 54172, 54234, 54389, 39321, 25417, 42341, 50174, 54455, 44050, 56059, 66616, 54504, 54555, 45851, 57679, 42130, 56789, 64232, 60925, 56829, 19692, 32640, 54689, 69055, 20609, 57455, 72012, 54726, 52653, 25776, 54814, 63908, 25984, 61227, 36498, 26018, 58552, 32640, 47394, 24383, 68318, 72870, 72012, 54868, 18707, 25776, 69705, 54929, 25983, 71927, 54995, 26051, 43915, 55047, 31632, 29738, 32574, 55095, 55145, 55282, 55174, 55347, 55409, 55471, 55533, 55625, 55661, 26850, 67349, 33333, 55693, 55764, 55813, 55904, 55954, 45409, 55563, 59673, 58326, 64010, 31239, 37627, 56028, 56147, 63574, 71739, 56202, 48600, 52021, 33017, 44420, 56272, 51439, 56304, 26558, 56379, 49469, 56435, 56525, 55629, 58860, 53658, 56557, 38796, 56640, 56760, 53746, 56861, 56918, 47849, 36159, 34716, 35068, 57014, 26905, 57100, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 57143, 60501, 46140, 53140, 57269, 57298, 57330, 57361, 57393, 21867, 57487, 53826, 57561, 73137, 57631, 57725, 57757, 57818, 64532, 33845, 25743, 28903, 32640, 30718, 48491, 57871, 57933, 57965, 50507, 34177, 46420, 65902, 58083, 44572, 34502, 27347, 47675, 69192, 32417, 27057, 58115, 45744, 58167, 58213, 58473, 58264, 36980, 26375, 58296, 44349, 69977, 37742, 31057, 58358, 32640, 35957, 68393, 49673, 58395, 33962, 23558, 65824, 55427, 66456, 46015, 39566, 60313, 47611, 68602, 32640, 47038, 58431, 65491, 72012, 72012, 58464, 25776, 27804, 58505, 25983, 57693, 26051, 26051, 58542, 33253, 32640, 51913, 22383, 49691, 64312, 64327, 50524, 46027, 71028, 38028, 53132, 32640, 21514, 49356, 67641, 68454, 61634, 65986, 49249, 32640, 68392, 71381, 31947, 25983, 51580, 39737, 67971, 58592, 35498, 68821, 42982, 65031, 58624, 58730, 58791, 58892, 49912, 26461, 39900, 47849, 36159, 34716, 60897, 62262, 58971, 59003, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 53024, 32640, 59046, 59088, 59157, 59186, 59218, 59249, 26690, 25253, 32640, 62512, 59314, 32640, 21399, 45956, 59348, 59428, 60204, 32024, 59282, 59482, 59526, 27721, 62325, 42794, 59562, 37343, 41105, 59653, 46262, 57786, 56728, 42158, 59014, 59705, 59741, 32640, 32640, 64131, 27582, 72012, 25809, 51286, 25776, 25844, 68525, 25984, 26051, 69412, 26018, 38086, 59766, 53173, 30453, 31873, 68393, 59807, 72012, 38182, 56458, 25776, 67880, 68261, 25983, 39566, 61247, 26051, 68602, 40380, 32640, 32640, 65491, 72012, 59857, 47966, 60005, 45599, 39842, 71940, 53287, 26051, 59892, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 71116, 32640, 59931, 71378, 25776, 29955, 53286, 26051, 56227, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 36718, 59969, 24280, 60037, 60131, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25253, 54423, 32640, 20742, 60181, 32843, 60251, 67710, 54291, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 29420, 32640, 32640, 32640, 64131, 72012, 72012, 60345, 25776, 25776, 60381, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 53207, 72012, 47768, 27763, 36922, 39842, 71874, 53287, 26051, 60418, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 70720, 71381, 60458, 35226, 48985, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 36240, 60497, 23383, 53140, 60533, 60561, 60593, 60624, 23405, 25467, 22160, 33169, 60689, 60747, 60715, 60805, 60866, 60957, 32640, 36400, 61023, 26995, 32640, 33355, 55315, 59825, 61082, 65831, 61145, 47313, 61199, 61279, 67236, 61352, 32640, 30073, 61417, 71794, 61454, 22979, 61508, 38584, 61544, 61588, 56170, 61624, 61666, 64623, 61704, 26051, 48694, 58552, 65333, 72472, 61736, 61772, 61831, 56082, 61881, 64292, 46200, 55981, 63076, 32888, 56329, 36998, 50357, 58842, 68602, 61924, 31336, 31217, 32949, 61962, 72012, 54897, 52135, 36922, 43253, 54949, 53287, 62059, 62103, 54635, 69791, 32640, 71552, 72012, 20633, 25776, 66700, 25983, 70631, 26051, 43048, 60991, 32640, 27575, 38860, 26267, 35612, 71431, 26052, 46302, 39252, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 59396, 61050, 48909, 62138, 49921, 43861, 50802, 44756, 26873, 47849, 36159, 34716, 33560, 62235, 62294, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 69266, 62427, 62544, 62612, 62644, 62673, 62705, 62736, 31256, 49878, 31910, 32640, 62790, 62885, 62917, 44164, 69556, 51644, 62949, 62995, 45696, 32640, 19278, 63027, 63108, 63211, 63245, 54342, 53506, 63300, 61672, 63378, 63410, 44572, 63450, 21770, 63487, 58560, 32640, 57422, 68884, 61512, 63553, 47513, 61592, 63606, 63675, 29960, 51050, 63717, 37895, 63759, 18562, 21217, 40028, 32560, 63799, 59860, 58135, 43158, 25776, 63843, 70614, 25983, 63875, 63940, 26051, 63990, 64042, 64442, 21262, 32640, 64117, 58399, 38848, 47768, 24174, 64168, 39842, 56347, 53287, 26051, 64218, 68608, 27898, 31520, 65495, 64264, 51931, 42855, 67656, 26365, 64359, 39180, 64397, 32640, 22880, 64131, 71378, 25776, 29955, 53286, 26051, 56886, 32234, 41489, 41766, 51964, 60386, 51580, 64489, 54657, 64564, 34064, 72128, 35550, 42184, 64655, 39628, 49921, 43861, 62758, 40962, 68714, 54610, 64734, 36847, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 25270, 32640, 23111, 32122, 64856, 64887, 64919, 64950, 31389, 65005, 27232, 34519, 65063, 65120, 65088, 61113, 65189, 65294, 65365, 65397, 32640, 65455, 65527, 65583, 65653, 65730, 65796, 42647, 52704, 58025, 65863, 65934, 65966, 66033, 64072, 66099, 26683, 30564, 66131, 66179, 66246, 41522, 66312, 64765, 26100, 66344, 66422, 62027, 63346, 66488, 48098, 66539, 38119, 40439, 30690, 24714, 66648, 46809, 22991, 67082, 66680, 47975, 66732, 66764, 58510, 66819, 66851, 26304, 66906, 66954, 31272, 32640, 67000, 67054, 67114, 21544, 34639, 21568, 67186, 67268, 67325, 67402, 54264, 43607, 48017, 34273, 42426, 67583, 30935, 67621, 41784, 67688, 48203, 67778, 64824, 41671, 20315, 24236, 67833, 44481, 37470, 67926, 59378, 68003, 32640, 68087, 68155, 34696, 68214, 39952, 68293, 68373, 68425, 68486, 66787, 35862, 33375, 70146, 67746, 49921, 43861, 49912, 58817, 68777, 68557, 68640, 68746, 58655, 44815, 68853, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 64085, 32640, 48353, 53140, 68928, 68957, 68989, 69020, 32640, 27125, 27632, 30788, 27143, 32640, 31656, 64595, 69087, 69148, 32640, 32024, 32640, 69224, 32640, 49895, 69298, 39058, 69348, 25776, 49418, 25983, 70024, 69401, 45323, 46448, 24757, 70970, 32640, 27865, 31743, 52581, 61849, 69444, 69504, 54523, 54583, 69588, 33465, 69648, 59899, 33588, 69746, 58552, 69823, 32640, 32640, 69855, 38964, 72012, 72012, 65611, 69892, 25776, 72113, 69928, 25983, 39566, 69966, 26051, 41254, 35657, 32640, 32640, 61476, 72012, 72012, 62354, 25776, 36922, 70009, 25983, 26418, 26051, 26051, 34349, 32640, 18845, 26622, 72012, 27075, 25776, 39460, 70056, 67293, 70094, 41204, 31858, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 45386, 70138, 70178, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 46082, 68666, 70273, 34716, 26535, 44842, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 22217, 68030, 66060, 33739, 70331, 54472, 70378, 70409, 32640, 25253, 32640, 32640, 32640, 32640, 19302, 70476, 56692, 51195, 59775, 43315, 32640, 32640, 27647, 25308, 37113, 62203, 70592, 53244, 62010, 70663, 47583, 56714, 33625, 44572, 32640, 32640, 28000, 32640, 29763, 64131, 55855, 72012, 25809, 51949, 25776, 25844, 56967, 25984, 26051, 33611, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 50577, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 25506, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 70701, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 59056, 32640, 70752, 70788, 70855, 70884, 70916, 70947, 32640, 25253, 32640, 32640, 32640, 32640, 41578, 49709, 71012, 71060, 32640, 32024, 32640, 32640, 71115, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 38108, 32640, 24932, 72012, 72012, 52641, 25776, 25776, 71858, 25983, 25983, 43032, 26051, 26051, 68602, 32640, 71148, 32640, 65491, 51789, 34949, 47768, 56478, 42901, 39842, 71181, 63325, 63418, 36037, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32154, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 34240, 32640, 25640, 43672, 32640, 22790, 58939, 37441, 71228, 41160, 51195, 32640, 22183, 71515, 71307, 32640, 25308, 72012, 71341, 31942, 35465, 71413, 36667, 59621, 26051, 71463, 42401, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 41936, 32640, 68393, 66214, 72012, 71584, 38192, 25776, 42053, 70669, 25983, 39566, 39775, 26051, 68602, 35405, 32640, 32640, 65491, 71628, 72012, 48552, 25776, 36922, 26149, 25983, 53287, 71664, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 22912, 36567, 70299, 37690, 32640, 25253, 66067, 32640, 32640, 32640, 71710, 26739, 42964, 71771, 20325, 32024, 32640, 32640, 32640, 27283, 72012, 59937, 31942, 25776, 52893, 25983, 56982, 26051, 51860, 44572, 23321, 32640, 32640, 37539, 32640, 38825, 72013, 72012, 71836, 53399, 25776, 71906, 39845, 25984, 71678, 53435, 26018, 58552, 30134, 32640, 32640, 32640, 68393, 71972, 72012, 63054, 52123, 25776, 62376, 48188, 25983, 24297, 36872, 26051, 68602, 32640, 32640, 33904, 65491, 72012, 72011, 47768, 42218, 36922, 39842, 71196, 53287, 26051, 72045, 68608, 32640, 48843, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 45251, 32640, 34258, 23504, 63811, 25776, 68806, 63685, 26051, 46302, 23041, 68392, 72091, 44738, 54963, 34731, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 31905, 32640, 72814, 32640, 32640, 53140, 72160, 36567, 70299, 34240, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 51195, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 31942, 25776, 62010, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 72268, 72234, 40231, 72204, 72300, 72337, 72417, 72449, 32640, 25253, 71149, 72986, 32640, 32640, 22011, 19703, 24646, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 21985, 22069, 72504, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 70431, 53140, 72560, 72589, 60219, 72636, 32640, 25253, 32640, 72986, 50892, 50890, 18907, 32640, 40751, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22037, 22069, 18821, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61930, 32640, 32640, 19846, 72691, 72708, 30629, 72755, 32640, 25253, 32640, 72810, 59270, 52170, 18907, 32640, 23058, 21807, 31154, 19779, 32640, 18612, 18649, 18757, 18789, 18959, 22311, 22069, 72846, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 21310, 21452, 21374, 21431, 21484, 21618, 21650, 21741, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 22530, 32640, 61740, 32640, 32640, 53140, 22912, 32640, 32640, 72919, 32640, 25253, 32640, 32640, 32640, 32640, 49347, 54782, 64809, 35297, 32640, 32024, 32640, 32640, 32640, 25308, 72012, 72012, 48724, 25776, 59604, 25983, 61672, 26051, 26051, 44572, 32640, 32640, 32640, 32640, 32640, 64131, 72012, 72012, 25809, 25776, 25776, 25844, 25983, 25984, 26051, 26051, 26018, 58552, 32640, 32640, 32640, 32640, 68393, 72012, 72012, 33962, 25776, 25776, 55427, 25983, 25983, 39566, 26051, 26051, 68602, 32640, 32640, 32640, 65491, 72012, 72012, 47768, 25776, 36922, 39842, 25983, 53287, 26051, 26051, 68608, 32640, 32640, 65495, 72012, 51360, 25776, 65698, 25983, 53288, 26051, 37187, 32640, 32640, 64131, 71378, 25776, 29955, 53286, 26051, 46302, 32640, 68392, 71381, 31947, 25983, 51580, 37193, 26609, 71375, 60465, 43860, 58860, 33375, 70146, 67746, 49921, 43861, 49912, 26461, 39900, 47849, 36159, 34716, 26535, 44815, 26905, 26933, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 34485, 32640, 23212, 23229, 52327, 72974, 32640, 32640, 32640, 72986, 32640, 32640, 18907, 32640, 23058, 21807, 31154, 43659, 32640, 18612, 18649, 18757, 18789, 18959, 21985, 22069, 72504, 22057, 18887, 18787, 18957, 18991, 36451, 32640, 24875, 69179, 19041, 62458, 19134, 40819, 21341, 19073, 46732, 21342, 19074, 46733, 19106, 19193, 40822, 19438, 66570, 19251, 21244, 41014, 19334, 19366, 19398, 19470, 19502, 19538, 25119, 19498, 19534, 19570, 19359, 19629, 19422, 19661, 19735, 19811, 19878, 19910, 19942, 20019, 30851, 30993, 20026, 30858, 20058, 19907, 21927, 19969, 20090, 20138, 20211, 20265, 20357, 63521, 20412, 63518, 20488, 20547, 20291, 20579, 20709, 20774, 20821, 20870, 20853, 20885, 20789, 20917, 20949, 21030, 21062, 21094, 21084, 21126, 21186, 73022, 21452, 21374, 21431, 73111, 21618, 21650, 73169, 21802, 23057, 21839, 21899, 21959, 22101, 21154, 22249, 22281, 22427, 22459, 22487, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 32640, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 180523, 180523, 180523, 180523, 0, 188716, 188716, 188716, 180523, 180523, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 0, 188716, 180523, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 139264, 147456, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 131072, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 188716, 367, 188716, 180523, 188716, 188716, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 180523, 188716, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2289, 0, 2290, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2368, 2369, 0, 0, 2371, 0, 0, 0, 0, 2376, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4276224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 307, 0, 0, 5767168, 0, 0, 0, 4857856, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5259264, 0, 5414912, 5447680, 0, 0, 5562368, 5636096, 5685248, 0, 5750784, 5873664, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1877, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1889, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 59821, 57886, 59823, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 58853, 57909, 57909, 58857, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58871, 0, 0, 5636096, 5873664, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5873664, 0, 0, 0, 0, 0, 0, 0, 5480448, 4358144, 4358144, 4358144, 4358144, 4857856, 4874240, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5259264, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5414912, 4358144, 5447680, 4358144, 5464064, 4358144, 5480448, 5562368, 4358144, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 977, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1262, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5873664, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1140, 0, 0, 1145, 0, 4857856, 4874240, 0, 0, 4923392, 5562368, 4358144, 4358144, 4358144, 5636096, 4358144, 5685248, 4358144, 4358144, 5750784, 4358144, 4358144, 4358144, 4358144, 4358144, 5873664, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6275072, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4923392, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 4923392, 0, 0, 0, 0, 4366336, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2755, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2766, 0, 0, 0, 0, 0, 0, 4825088, 0, 0, 5177344, 0, 0, 0, 0, 5701632, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5808128, 0, 0, 0, 0, 4792320, 4833280, 0, 0, 5701632, 0, 5242880, 0, 0, 0, 0, 0, 0, 0, 5341184, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5627904, 5652480, 0, 5701632, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4825088, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5177344, 4358144, 4358144, 4358144, 4358144, 4358144, 5242880, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5341184, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5627904, 5652480, 4358144, 5701632, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 483328, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5341184, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5627904, 5652480, 4358144, 5701632, 4358144, 4358144, 5808128, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 1051, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 0, 0, 6422528, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5619712, 0, 0, 0, 0, 0, 0, 0, 5726208, 5758976, 0, 0, 5791744, 0, 0, 0, 0, 0, 0, 0, 1151, 1278, 0, 0, 0, 0, 0, 0, 1285, 0, 0, 0, 0, 0, 0, 0, 1290, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 848, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 0, 6479872, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4931584, 4939776, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5054464, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5210112, 4358144, 4358144, 4358144, 4358144, 5292032, 4358144, 4358144, 4358144, 4358144, 5365760, 4358144, 4358144, 4358144, 5455872, 4358144, 4358144, 4358144, 4358144, 4358144, 5554176, 5570560, 5578752, 5619712, 5668864, 4358144, 4358144, 4358144, 5791744, 5816320, 4358144, 5857280, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6119424, 4358144, 6168576, 4358144, 4358144, 4358144, 4358144, 6242304, 4358144, 6291456, 4358144, 6316032, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6463488, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4931584, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 6463488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4931584, 4939776, 0, 0, 0, 0, 0, 0, 5054464, 0, 0, 0, 0, 0, 0, 0, 0, 5210112, 0, 0, 0, 0, 5292032, 0, 0, 0, 0, 5365760, 0, 0, 0, 5455872, 0, 0, 0, 0, 0, 5554176, 5570560, 5578752, 5619712, 5668864, 0, 5578752, 5619712, 5668864, 0, 0, 0, 5791744, 5816320, 0, 5857280, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6119424, 0, 6168576, 0, 0, 0, 0, 0, 6242304, 0, 6291456, 0, 6316032, 0, 6291456, 0, 6316032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6463488, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4931584, 4939776, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 491520, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 5578752, 5619712, 5668864, 4358144, 4358144, 4358144, 5791744, 5816320, 4358144, 5857280, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6119424, 4358144, 6168576, 4358144, 4358144, 4358144, 4358144, 4358144, 6242304, 4956160, 4964352, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5218304, 0, 0, 0, 0, 5799936, 0, 5881856, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6373376, 6389760, 0, 0, 0, 0, 0, 1758, 0, 0, 1761, 0, 1763, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 977, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6488064, 6103040, 0, 0, 0, 0, 0, 6184960, 5316608, 0, 0, 5644288, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6217728, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3384, 0, 0, 0, 3388, 0, 0, 0, 0, 0, 3394, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5390336, 5308416, 5488640, 0, 0, 5070848, 5431296, 0, 6430720, 0, 0, 5160960, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4784128, 0, 0, 0, 0, 0, 0, 0, 0, 3623, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2359296, 417, 417, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6283264, 6332416, 0, 0, 0, 5881856, 0, 5382144, 0, 0, 0, 0, 0, 0, 6266880, 4784128, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4915200, 4358144, 4956160, 4972544, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5070848, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5218304, 4358144, 5267456, 4358144, 4358144, 5308416, 5316608, 4358144, 4358144, 4358144, 5431296, 4358144, 5488640, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5799936, 4358144, 4358144, 5881856, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6103040, 4358144, 4358144, 4358144, 6184960, 4358144, 4358144, 6283264, 4358144, 4358144, 6332416, 4358144, 4358144, 4358144, 6389760, 4358144, 4358144, 6430720, 6438912, 4358144, 4358144, 4358144, 6266880, 6488064, 0, 0, 0, 6266880, 6488064, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3149, 0, 0, 0, 0, 3154, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 6430720, 6438912, 0, 0, 0, 0, 0, 0, 4784128, 0, 0, 0, 4849664, 0, 0, 0, 0, 0, 4915200, 0, 4956160, 4972544, 0, 0, 0, 0, 0, 0, 5070848, 0, 0, 0, 0, 0, 0, 0, 5218304, 0, 0, 6103040, 0, 0, 0, 6184960, 0, 0, 0, 6283264, 0, 0, 6332416, 0, 0, 0, 6389760, 0, 0, 6430720, 6438912, 4784128, 4358144, 4358144, 4358144, 4849664, 4358144, 4358144, 4358144, 4358144, 4358144, 4915200, 0, 5660672, 5718016, 0, 5865472, 0, 0, 6037504, 0, 0, 6078464, 0, 0, 6340608, 0, 6455296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 325, 326, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5472256, 0, 0, 0, 6209536, 0, 0, 0, 0, 6176768, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4898816, 0, 5709824, 0, 0, 0, 0, 0, 1790, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2348, 0, 0, 0, 0, 0, 0, 0, 0, 5283840, 0, 0, 0, 0, 5251072, 0, 6414336, 5832704, 0, 5955584, 0, 0, 4358144, 4358144, 4841472, 4358144, 4358144, 4358144, 4898816, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 368640, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 4358144, 5111808, 4358144, 4358144, 4358144, 4358144, 4358144, 5283840, 4358144, 4358144, 4358144, 4358144, 5472256, 5521408, 4358144, 4358144, 4358144, 5595136, 5709824, 5718016, 4358144, 5824512, 5865472, 4358144, 4358144, 5922816, 4358144, 4358144, 6021120, 4358144, 6037504, 4358144, 4358144, 6078464, 6111232, 4358144, 6176768, 6209536, 4358144, 6234112, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3408, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1172, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 6078464, 6111232, 4358144, 6176768, 6209536, 6234112, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 4841472, 0, 0, 0, 4898816, 0, 0, 0, 0, 0, 0, 0, 0, 0, 340, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 388, 0, 139264, 147456, 0, 0, 0, 0, 0, 6037504, 0, 0, 6078464, 6111232, 0, 6176768, 6209536, 0, 6234112, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4841472, 0, 0, 0, 4898816, 0, 0, 0, 0, 0, 0, 0, 0, 3773, 0, 3627, 3775, 0, 0, 3778, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 4024, 521, 4026, 521, 521, 4028, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 6021120, 0, 6037504, 0, 0, 6078464, 6111232, 0, 6176768, 6209536, 0, 6234112, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4841472, 4358144, 4358144, 4358144, 4898816, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 499712, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5111808, 4358144, 4358144, 4358144, 4358144, 4358144, 5283840, 4358144, 4358144, 4358144, 4358144, 5472256, 5521408, 4358144, 4358144, 4358144, 4358144, 5595136, 5709824, 5718016, 4358144, 5824512, 5865472, 4358144, 4358144, 5922816, 0, 5029888, 5038080, 0, 0, 5103616, 5201920, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6406144, 5357568, 0, 5505024, 0, 0, 0, 0, 0, 5890048, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1873, 521, 521, 521, 521, 521, 521, 521, 521, 1884, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3216, 521, 521, 521, 521, 0, 0, 57886, 57886, 57886, 57886, 57886, 60569, 57886, 60570, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58842, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 58854, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59962, 59963, 57909, 57909, 57909, 57909, 57909, 57909, 59970, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 6160384, 0, 5095424, 5349376, 0, 5275648, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5947392, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 301, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 787, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6471680, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4997120, 4358144, 4358144, 5038080, 4358144, 4358144, 4358144, 5095424, 5103616, 4358144, 4358144, 5201920, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5890048, 4358144, 4358144, 4358144, 6029312, 4358144, 4358144, 4358144, 4358144, 6160384, 4358144, 4358144, 4358144, 4358144, 5890048, 4358144, 4358144, 4358144, 6029312, 4358144, 4358144, 4358144, 4358144, 6160384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6406144, 0, 0, 0, 0, 0, 0, 0, 0, 4997120, 0, 0, 5038080, 0, 0, 0, 0, 6406144, 0, 0, 0, 0, 0, 0, 0, 0, 4997120, 0, 0, 5038080, 0, 0, 0, 5095424, 5103616, 0, 0, 5201920, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5890048, 0, 0, 0, 6029312, 0, 0, 0, 0, 6160384, 0, 0, 0, 0, 0, 0, 0, 6406144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4997120, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6406144, 4358144, 4358144, 4358144, 0, 0, 0, 4890624, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5898240, 5963776, 0, 0, 6193152, 0, 0, 5406720, 6397952, 5300224, 5234688, 5423104, 0, 0, 0, 0, 5988352, 0, 0, 6135808, 6307840, 0, 5996544, 4800512, 0, 6356992, 0, 0, 0, 5496832, 0, 0, 0, 0, 0, 5611520, 0, 0, 0, 0, 0, 0, 0, 1187, 0, 0, 1190, 1191, 0, 0, 0, 0, 1195, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 782, 0, 0, 0, 0, 0, 0, 0, 786, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 801, 4947968, 5021696, 5529600, 0, 0, 5169152, 0, 0, 0, 4800512, 4808704, 4358144, 4358144, 4890624, 4358144, 4947968, 4358144, 4358144, 4358144, 5046272, 4358144, 4358144, 4358144, 4358144, 5185536, 4358144, 5234688, 5300224, 4358144, 4358144, 5406720, 5529600, 4358144, 4358144, 4358144, 5898240, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6307840, 4358144, 4358144, 6356992, 6381568, 6397952, 4800512, 4808704, 0, 0, 4890624, 0, 4947968, 0, 0, 0, 5046272, 0, 0, 0, 0, 5185536, 0, 5234688, 5300224, 0, 0, 5406720, 5529600, 0, 0, 0, 0, 5898240, 0, 0, 0, 0, 0, 0, 0, 0, 6307840, 0, 0, 6356992, 6381568, 6397952, 4800512, 4808704, 0, 0, 4890624, 0, 0, 6356992, 6381568, 6397952, 4800512, 4808704, 4358144, 4358144, 4890624, 4358144, 4947968, 4358144, 4358144, 4358144, 5046272, 4358144, 4358144, 4358144, 4358144, 5185536, 4358144, 5234688, 5300224, 4358144, 4358144, 5406720, 5529600, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4907008, 0, 5079040, 6094848, 0, 0, 0, 4358144, 4907008, 4358144, 5079040, 4358144, 5226496, 4358144, 5742592, 4358144, 4358144, 4358144, 6094848, 0, 4907008, 0, 5079040, 0, 5226496, 5898240, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6307840, 4358144, 4358144, 6356992, 6381568, 6397952, 5021696, 4358144, 4358144, 5021696, 0, 0, 0, 4980736, 0, 0, 0, 0, 0, 5373952, 5734400, 6045696, 0, 0, 0, 0, 0, 2306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2290, 0, 0, 0, 0, 0, 0, 0, 6152192, 0, 0, 0, 6316032, 0, 0, 0, 0, 5816320, 6291456, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2778, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2803, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6258688, 6447104, 0, 0, 6127616, 0, 6348800, 5906432, 0, 5537792, 3627, 0, 0, 0, 0, 5939200, 0, 0, 5677056, 6365184, 4866048, 0, 6070272, 5545984, 5152768, 0, 0, 6144000, 4358144, 4866048, 4882432, 4358144, 0, 0, 0, 0, 0, 4825088, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5177344, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5324800, 5373952, 5537792, 5545984, 5586944, 5734400, 5971968, 0, 6045696, 0, 6070272, 0, 0, 0, 0, 6348800, 0, 4866048, 4882432, 0, 4980736, 0, 0, 0, 0, 0, 0, 0, 0, 521, 831, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 877, 521, 521, 521, 521, 895, 521, 521, 57886, 57886, 58249, 0, 5324800, 5373952, 5537792, 5545984, 5586944, 5734400, 5971968, 0, 6045696, 0, 6070272, 0, 0, 0, 0, 6348800, 4358144, 4866048, 4882432, 4358144, 4980736, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5324800, 5373952, 5537792, 5545984, 5734400, 5971968, 4358144, 6045696, 4358144, 6070272, 4358144, 4358144, 4358144, 6348800, 0, 4866048, 4882432, 0, 4980736, 0, 0, 0, 0, 5537792, 5545984, 5586944, 5734400, 5971968, 4358144, 6045696, 4358144, 6070272, 4358144, 4358144, 4358144, 4358144, 6348800, 4358144, 6144000, 0, 6144000, 0, 4988928, 5005312, 0, 0, 0, 0, 5775360, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 3441, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3454, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 57886, 60242, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60250, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60293, 57886, 57886, 57886, 60296, 60297, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59917, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 5693440, 0, 6496256, 5144576, 5136384, 0, 5914624, 4358144, 4358144, 5005312, 4358144, 4358144, 4358144, 5120000, 5136384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6324224, 0, 0, 5005312, 0, 0, 0, 5120000, 5136384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6324224, 0, 0, 5005312, 0, 0, 0, 5120000, 5136384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6324224, 4358144, 0, 0, 900, 900, 900, 4825988, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 5178244, 900, 900, 900, 900, 900, 5219204, 900, 5268356, 900, 900, 5309316, 5317508, 900, 900, 900, 5432196, 900, 5489540, 900, 900, 900, 900, 900, 900, 900, 900, 900, 5800836, 900, 900, 5882756, 900, 4358144, 5005312, 4358144, 4358144, 4358144, 5120000, 5136384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6324224, 5914624, 5914624, 0, 0, 0, 0, 0, 5513216, 5783552, 0, 3627, 0, 0, 0, 0, 0, 0, 1759, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1772, 0, 1774, 0, 0, 0, 1778, 0, 0, 0, 1782, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 0, 5013504, 0, 0, 6053888, 0, 0, 0, 0, 6012928, 4358144, 4358144, 5013504, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6053888, 4358144, 4358144, 0, 0, 5013504, 0, 0, 0, 0, 0, 0, 685, 0, 0, 0, 0, 0, 0, 692, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 705, 0, 0, 0, 0, 0, 0, 0, 0, 6053888, 0, 0, 0, 0, 0, 5013504, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6053888, 0, 0, 0, 4358144, 4358144, 5013504, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5799936, 4358144, 4358144, 5881856, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6103040, 4358144, 4358144, 4358144, 6184960, 4358144, 4358144, 4358144, 6283264, 4358144, 4358144, 6332416, 4358144, 4358144, 4358144, 4358144, 4358144, 6053888, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 5193728, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5259264, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 901, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5259264, 0, 0, 0, 0, 0, 0, 0, 0, 5414912, 0, 5447680, 0, 5464064, 0, 5480448, 5562368, 0, 0, 0, 5636096, 0, 5685248, 0, 0, 5750784, 0, 0, 0, 0, 0, 5873664, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5193728, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5193728, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 5193728, 4358144, 0, 1959, 0, 0, 0, 4825088, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5177344, 0, 0, 0, 0, 0, 0, 715, 0, 717, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 732, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1189, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1250, 1252, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 362, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 0, 5742592, 0, 0, 0, 6094848, 0, 0, 4907008, 0, 5079040, 0, 5226496, 0, 5742592, 0, 0, 0, 6094848, 0, 4358144, 4907008, 4358144, 5079040, 4358144, 5226496, 4358144, 5742592, 4358144, 4358144, 4358144, 6094848, 4358144, 5062656, 0, 0, 0, 4358144, 5062656, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 5062656, 0, 0, 0, 0, 0, 6225920, 0, 5062656, 0, 0, 0, 0, 0, 6225920, 4358144, 5062656, 4358144, 4358144, 4358144, 0, 900, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5259264, 0, 0, 0, 0, 0, 0, 0, 746, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 762, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 2396, 521, 521, 521, 521, 2400, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3199, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1390, 521, 521, 1394, 521, 521, 521, 521, 521, 1401, 521, 521, 4358144, 4358144, 4358144, 6225920, 0, 0, 0, 4816896, 4358144, 4358144, 4358144, 4358144, 6086656, 4816896, 0, 0, 0, 0, 6086656, 4816896, 0, 0, 0, 0, 6086656, 4816896, 4358144, 4358144, 4358144, 4358144, 6086656, 5087232, 0, 5931008, 4358144, 5332992, 5980160, 4358144, 0, 5332992, 5980160, 0, 0, 5332992, 5980160, 0, 4358144, 5332992, 5980160, 4358144, 5439488, 5128192, 4358144, 5128192, 0, 5128192, 0, 5128192, 4358144, 4358144, 0, 0, 4358144, 4358144, 0, 0, 4358144, 6004736, 6004736, 6004736, 6004736, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1289, 0, 0, 0, 0, 0, 0, 0, 0, 1294, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2816, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221645, 221645, 221645, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 221645, 461, 221645, 221645, 221645, 461, 221645, 221645, 221645, 221645, 221645, 221645, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 327, 328, 329, 330, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221645, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3390, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1769, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1780, 0, 0, 0, 0, 0, 0, 0, 4268032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 755, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3414, 0, 0, 0, 0, 3418, 0, 0, 0, 0, 3423, 0, 0, 0, 0, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 237568, 301, 0, 305, 237568, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 302, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 788, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 305, 0, 0, 0, 0, 0, 0, 305, 237982, 147456, 0, 0, 0, 305, 0, 0, 0, 0, 0, 2334, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2349, 0, 0, 0, 0, 0, 0, 0, 3406, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3420, 3421, 0, 0, 0, 0, 3426, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 516096, 0, 0, 0, 0, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 305, 0, 305, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 1870, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2453, 521, 521, 521, 2456, 521, 521, 521, 521, 521, 2461, 521, 305, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 65536, 302, 0, 4268032, 98304, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3626, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4210978, 24578, 3, 0, 0, 296, 0, 0, 0, 0, 296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 245760, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 399, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 399, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 245760, 0, 0, 0, 0, 245760, 0, 245760, 0, 245760, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 326, 400, 0, 0, 0, 0, 0, 0, 0, 0, 0, 326, 0, 0, 0, 0, 0, 0, 0, 0, 4210978, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 212992, 0, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 212992, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1768, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1257, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1270, 0, 0, 2059, 0, 0, 0, 4825088, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5177344, 0, 0, 0, 0, 0, 0, 0, 1730, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 311, 310, 0, 0, 0, 310, 310, 311, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 262144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 350, 0, 0, 0, 0, 0, 0, 0, 0, 351, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 657, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 673, 674, 0, 0, 0, 0, 0, 0, 262144, 262144, 262144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 301, 0, 0, 0, 262144, 0, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 262731, 0, 262731, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 3439, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3670, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60591, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59853, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60298, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 262731, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 245760, 245760, 245760, 245760, 245760, 245760, 245760, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 278528, 278528, 0, 0, 131072, 278528, 0, 0, 0, 278528, 0, 0, 0, 0, 278528, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 333, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 333, 384, 0, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 278528, 0, 278528, 0, 0, 0, 0, 0, 521, 521, 521, 521, 3438, 521, 521, 521, 521, 3442, 521, 521, 521, 521, 521, 521, 521, 3448, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1901, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1921, 521, 521, 278528, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 262144, 0, 0, 0, 0, 0, 0, 262144, 262144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 262144, 262144, 0, 262144, 0, 0, 0, 139264, 147456, 262144, 0, 0, 0, 0, 0, 0, 0, 0, 415, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 302, 0, 0, 0, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 631, 0, 4268032, 305, 634, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 532480, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 754, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1506, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3624, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2810, 2811, 0, 0, 0, 0, 0, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 286720, 302, 0, 306, 286720, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 722, 0, 0, 0, 0, 0, 0, 0, 0, 0, 733, 0, 0, 0, 0, 733, 0, 739, 0, 0, 0, 0, 0, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 306, 0, 0, 0, 0, 0, 0, 306, 139264, 287138, 0, 0, 0, 306, 0, 0, 0, 0, 0, 2386, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2402, 521, 2404, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59830, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60836, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60274, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 306, 0, 306, 0, 0, 0, 0, 0, 521, 521, 521, 3437, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3449, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3464, 521, 3466, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 61250, 57909, 57909, 61252, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 59994, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 306, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 66168, 0, 4268032, 305, 98939, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 540672, 0, 0, 0, 0, 0, 0, 0, 540672, 0, 0, 0, 0, 0, 0, 0, 0, 0, 122880, 0, 4268032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2352, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 303, 303, 303, 0, 0, 303, 303, 295215, 303, 303, 303, 303, 303, 303, 303, 303, 303, 295215, 373, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 368, 303, 0, 295215, 303, 303, 303, 303, 295285, 295215, 295215, 295215, 295215, 295215, 295215, 303, 303, 303, 303, 303, 303, 295285, 295215, 295215, 295215, 303, 303, 303, 295285, 139264, 147456, 295215, 295215, 303, 303, 295215, 303, 303, 131072, 303, 303, 303, 303, 295215, 303, 303, 303, 303, 295215, 303, 295215, 295215, 295215, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 295215, 295215, 295215, 295215, 295215, 295215, 303, 303, 303, 295215, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 303, 295215, 303, 295215, 295215, 295215, 295215, 295215, 295215, 295215, 303, 0, 303, 0, 303, 303, 303, 295215, 303, 303, 303, 295215, 295215, 303, 295215, 303, 295215, 295215, 295215, 295215, 295215, 295215, 295215, 295215, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295285, 295215, 295215, 295215, 295215, 295215, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 4359045, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 352256, 0, 352256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2373, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319488, 0, 0, 0, 0, 0, 0, 319488, 319488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1743, 0, 0, 0, 0, 0, 0, 0, 1751, 1752, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319488, 0, 0, 0, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 319488, 0, 0, 0, 0, 319488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319488, 0, 0, 0, 0, 319488, 0, 319488, 319488, 319488, 0, 24578, 3, 0, 0, 4366336, 253952, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5627904, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4284416, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 327680, 0, 0, 0, 0, 0, 0, 0, 0, 521, 2389, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3219, 521, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60571, 57886, 57886, 57886, 57886, 57886, 57886, 60579, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 327680, 327680, 327680, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 327680, 327680, 327680, 327680, 335872, 327680, 327680, 327680, 335872, 327680, 327680, 327680, 327680, 327680, 327680, 0, 0, 0, 0, 0, 0, 0, 0, 0, 49716, 0, 0, 0, 0, 0, 327680, 49716, 327680, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5627904, 0, 0, 0, 0, 0, 0, 196608, 0, 0, 0, 106496, 0, 0, 4284416, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 49152, 977, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6463488, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4931584, 4939776, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 344064, 344064, 344064, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 344064, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 727, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 344064, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 356, 357, 358, 359, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 0, 0, 0, 0, 4276224, 1245, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 352256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 352256, 0, 0, 0, 0, 0, 0, 131072, 0, 352256, 352256, 0, 0, 352256, 0, 0, 352256, 0, 352256, 0, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 352256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1197, 0, 367, 367, 0, 1200, 0, 0, 0, 0, 0, 0, 0, 0, 352256, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 706, 0, 0, 1, 291, 3, 0, 0, 0, 297, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3398, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 360448, 360448, 360448, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 360448, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1226, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 360448, 1, 0, 3, 155941, 155941, 295, 0, 629, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 698, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1212, 0, 0, 0, 0, 1217, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4276224, 1245, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1259, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1221, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1188, 0, 58796, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59402, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58826, 57886, 57886, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59502, 57886, 0, 2281, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 739, 0, 0, 0, 2357, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3428, 0, 57909, 59926, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58906, 57909, 57909, 59952, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57936, 60009, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 60035, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60937, 521, 3212, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59387, 59388, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60604, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60320, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60702, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 3612, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3381, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 369, 0, 0, 0, 57886, 57886, 60830, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60853, 57886, 57886, 57936, 57936, 57936, 57936, 60914, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60057, 57936, 57936, 57936, 57936, 61027, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 61045, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60634, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59493, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 61048, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61056, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60378, 57936, 57936, 57936, 57886, 57886, 57886, 57886, 61156, 57886, 57886, 57886, 57886, 61157, 61158, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59997, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 61175, 57909, 57909, 57909, 57909, 61176, 61177, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61194, 57936, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61078, 61079, 57936, 57936, 57936, 57936, 61083, 61084, 57936, 57936, 57936, 57936, 57936, 61088, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61195, 61196, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 3177, 521, 521, 521, 521, 521, 521, 3184, 521, 3186, 521, 521, 521, 57936, 57936, 57936, 57936, 57936, 61270, 57936, 57936, 57936, 57936, 57936, 57936, 61276, 57936, 57936, 57936, 61280, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 0, 1791, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 672, 0, 0, 0, 0, 0, 0, 0, 3947, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 61306, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58312, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61322, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61338, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 3759, 521, 57886, 61105, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57886, 61439, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 61452, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 61465, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60413, 57936, 57936, 57936, 57936, 57936, 57936, 60421, 57936, 57936, 57936, 57936, 57936, 60426, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 4077, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 0, 0, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 0, 521, 521, 57886, 57886, 57909, 57909, 57936, 57936, 521, 57886, 57909, 57936, 521, 57886, 57909, 57936, 521, 57886, 57909, 57936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1829, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 376832, 376832, 376832, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1254, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1268, 1269, 0, 0, 0, 0, 0, 419, 419, 419, 419, 590, 590, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 419, 0, 419, 0, 0, 0, 0, 0, 521, 1866, 521, 521, 521, 521, 521, 521, 1872, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 57886, 57886, 57886, 57886, 60568, 57886, 57886, 57886, 57886, 57886, 57886, 60575, 57886, 60577, 57886, 57886, 419, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 696, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2817, 0, 0, 0, 4268773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2380, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 307, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 721, 0, 0, 0, 0, 0, 0, 0, 0, 731, 0, 637, 731, 0, 735, 736, 637, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 393678, 393678, 393678, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1309, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 4025, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 393678, 0, 393678, 393678, 393678, 0, 393678, 393678, 393678, 393678, 393678, 393678, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1771, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 425984, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 3176, 521, 521, 521, 521, 521, 3181, 521, 521, 521, 521, 521, 521, 521, 0, 0, 0, 4268032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 475136, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 374, 0, 0, 375, 0, 0, 0, 0, 0, 327, 375, 330, 374, 0, 0, 0, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 57887, 521, 57887, 521, 521, 57887, 521, 521, 57910, 57887, 521, 521, 57887, 57887, 57887, 57910, 0, 0, 0, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 420, 0, 420, 0, 0, 0, 0, 0, 521, 3435, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1916, 521, 521, 521, 521, 521, 521, 420, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 304, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 723, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1287, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 741, 420, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2791, 0, 0, 1239, 0, 0, 0, 741, 1246, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 1322, 521, 521, 521, 521, 521, 521, 521, 2468, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60276, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 521, 521, 521, 2468, 2895, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60305, 57886, 57886, 0, 0, 0, 2963, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 417792, 308, 309, 0, 0, 0, 0, 0, 0, 1815, 0, 0, 0, 0, 0, 0, 0, 0, 1821, 0, 1823, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 540672, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3127, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 309, 0, 417792, 417792, 0, 0, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 417792, 418101, 417792, 417792, 418100, 418101, 417792, 417792, 418100, 417792, 418100, 417792, 0, 0, 0, 0, 0, 0, 0, 0, 417792, 0, 0, 0, 417792, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 309, 309, 309, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1802, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 417792, 1, 24578, 3, 0, 0, 4366964, 0, 0, 0, 0, 0, 301, 302, 311296, 4268032, 305, 306, 0, 434176, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1846, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1859, 0, 0, 1860, 0, 0, 900, 900, 5415812, 900, 5448580, 900, 5464964, 900, 5481348, 5563268, 900, 900, 900, 5636996, 900, 5686148, 900, 900, 5751684, 900, 900, 900, 900, 900, 5874564, 900, 900, 900, 900, 900, 900, 900, 900, 900, 6464388, 0, 0, 0, 0, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 4932560, 4940752, 976, 976, 976, 976, 976, 4359044, 4858756, 4875140, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5260164, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5415812, 4359044, 5448580, 4359044, 5464964, 4359044, 5481348, 5563268, 4359044, 4359044, 4359044, 5636996, 4359044, 5686148, 4359044, 4359044, 5751684, 4359044, 4359044, 4359044, 4359044, 4359044, 5874564, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6275972, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5342084, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5628804, 5653380, 4359044, 5702532, 4359044, 4359044, 5809028, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4907008, 0, 5079040, 6094848, 0, 0, 0, 4358144, 4907008, 4358144, 5079040, 4358144, 5226496, 4358144, 5742592, 4358144, 4358144, 4358144, 6094848, 900, 4907908, 900, 5079940, 900, 5227396, 900, 5243780, 900, 900, 900, 900, 900, 900, 900, 5342084, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 5628804, 5653380, 900, 5702532, 900, 900, 900, 900, 900, 900, 5211012, 900, 900, 900, 900, 5292932, 900, 900, 900, 900, 5366660, 900, 900, 900, 5456772, 900, 900, 900, 900, 900, 5555076, 5571460, 5579652, 5620612, 5669764, 900, 0, 0, 976, 976, 976, 4826064, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 5178320, 976, 976, 976, 976, 976, 5112784, 976, 976, 976, 976, 976, 5284816, 976, 976, 976, 976, 5473232, 5522384, 976, 976, 976, 976, 5596112, 5710800, 5718992, 976, 5825488, 5866448, 976, 976, 5923792, 976, 5243856, 976, 976, 976, 976, 976, 976, 976, 5342160, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 5628880, 5653456, 976, 5702608, 976, 976, 976, 976, 976, 976, 976, 5260240, 976, 976, 976, 976, 976, 976, 976, 976, 5415888, 976, 5448656, 976, 5465040, 976, 5481424, 5563344, 976, 976, 976, 5637072, 976, 5686224, 976, 976, 5751760, 976, 4358144, 4358144, 4358144, 4358144, 4358144, 6463488, 0, 0, 0, 0, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 4932484, 4940676, 900, 900, 900, 900, 900, 900, 5055364, 900, 900, 5112708, 900, 900, 900, 900, 900, 5284740, 900, 900, 900, 900, 5473156, 5522308, 900, 900, 900, 900, 5596036, 5710724, 5718916, 900, 5825412, 5866372, 900, 900, 5923716, 900, 900, 6022020, 900, 900, 900, 5792644, 5817220, 900, 5858180, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 6120324, 900, 6169476, 900, 900, 900, 900, 900, 6243204, 900, 6292356, 900, 6316932, 976, 5055440, 976, 976, 976, 976, 976, 976, 976, 976, 5211088, 976, 976, 976, 976, 5293008, 976, 976, 976, 976, 5366736, 976, 976, 976, 5456848, 976, 976, 976, 976, 976, 5555152, 5571536, 5579728, 5620688, 5669840, 976, 976, 976, 5792720, 5817296, 976, 5858256, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 6120400, 976, 6169552, 976, 976, 976, 976, 976, 6243280, 976, 6292432, 976, 6317008, 976, 976, 976, 976, 976, 976, 976, 976, 976, 6464464, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4932484, 4940676, 4359044, 4359044, 4359044, 4359044, 4359044, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 900, 900, 900, 900, 900, 900, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 4923392, 4359044, 5055364, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5211012, 4359044, 4359044, 4359044, 4359044, 5292932, 4359044, 4359044, 4359044, 4359044, 5366660, 4359044, 4359044, 4359044, 5456772, 4359044, 4359044, 4359044, 4359044, 4359044, 5555076, 5571460, 5579652, 5620612, 5669764, 4359044, 4359044, 4359044, 5792644, 5817220, 4359044, 5858180, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6120324, 4359044, 6169476, 4359044, 4359044, 4359044, 4359044, 4359044, 6243204, 4359044, 6292356, 4359044, 6316932, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6464388, 4358144, 4358144, 4358144, 4358144, 4358144, 900, 900, 900, 900, 900, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4931584, 0, 0, 0, 0, 0, 0, 0, 4358144, 6430720, 6438912, 0, 0, 0, 0, 0, 0, 4785028, 900, 900, 900, 4850564, 900, 900, 900, 900, 900, 4916100, 900, 4957060, 4973444, 900, 900, 900, 900, 900, 900, 5071748, 900, 900, 5194628, 900, 900, 900, 900, 900, 900, 900, 900, 976, 976, 976, 976, 976, 5194704, 976, 976, 976, 976, 976, 976, 976, 976, 4359044, 4359044, 4359044, 4359044, 4359044, 5194628, 4359044, 0, 0, 4785104, 976, 976, 976, 4850640, 976, 976, 976, 976, 976, 4916176, 976, 4957136, 4973520, 976, 976, 976, 976, 976, 976, 5071824, 976, 976, 976, 976, 976, 976, 976, 5219280, 976, 976, 6357968, 6382544, 6398928, 4801412, 4809604, 4359044, 4359044, 4891524, 4359044, 4948868, 4359044, 4359044, 4359044, 5047172, 4359044, 4359044, 4359044, 4359044, 5186436, 4359044, 5235588, 5301124, 4359044, 4359044, 5407620, 5530500, 4359044, 4359044, 4359044, 4359044, 4359044, 4923392, 4358144, 4358144, 4358144, 4358144, 4358144, 900, 4924292, 900, 900, 900, 900, 4366336, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1264, 0, 0, 0, 0, 0, 0, 0, 5268432, 976, 976, 5309392, 5317584, 976, 976, 976, 5432272, 976, 5489616, 976, 976, 976, 976, 976, 976, 976, 976, 976, 5800912, 976, 976, 5882832, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 976, 6104016, 976, 976, 976, 6185936, 976, 976, 976, 6284240, 976, 976, 6333392, 976, 976, 976, 6390736, 976, 976, 6431696, 6439888, 4785028, 4359044, 4359044, 4359044, 4850564, 4359044, 4359044, 4359044, 4359044, 4359044, 4916100, 4359044, 4957060, 4973444, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5071748, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5219204, 4359044, 5268356, 4359044, 4359044, 5309316, 5317508, 4359044, 4359044, 4359044, 5432196, 4359044, 5489540, 4359044, 4359044, 4359044, 4359044, 4359044, 6054788, 4359044, 4359044, 4359044, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 5193728, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 900, 900, 900, 5096324, 5104516, 900, 900, 5202820, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 5890948, 900, 900, 900, 6030212, 900, 900, 900, 900, 6161284, 900, 900, 900, 900, 6407044, 976, 976, 976, 976, 976, 976, 976, 976, 4998096, 976, 976, 5039056, 976, 976, 976, 5096400, 5104592, 976, 976, 5202896, 976, 976, 976, 976, 976, 976, 976, 5891024, 976, 976, 976, 6030288, 976, 976, 976, 976, 6161360, 976, 976, 976, 976, 976, 976, 976, 6407120, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4998020, 4359044, 4358144, 6078464, 6111232, 4358144, 6176768, 6209536, 6234112, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 900, 900, 4842372, 900, 900, 900, 4899716, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 975, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 6300624, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 5809028, 6038404, 900, 900, 6079364, 6112132, 900, 6177668, 6210436, 900, 6235012, 900, 900, 900, 900, 900, 900, 900, 0, 0, 976, 976, 4842448, 976, 976, 976, 4899792, 976, 976, 976, 976, 976, 976, 5874640, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 6276048, 976, 976, 976, 976, 976, 976, 976, 976, 976, 0, 900, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5112708, 4359044, 4359044, 4359044, 4359044, 4359044, 5284740, 4359044, 4359044, 4359044, 4359044, 5473156, 5522308, 4359044, 4359044, 4359044, 4359044, 5596036, 5710724, 5718916, 4359044, 5825412, 5866372, 4359044, 4359044, 5923716, 976, 6022096, 976, 6038480, 976, 976, 6079440, 6112208, 976, 6177744, 6210512, 976, 6235088, 976, 976, 976, 976, 976, 976, 976, 4359044, 4359044, 4842372, 4359044, 4359044, 4359044, 4899716, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5800836, 4359044, 4359044, 5882756, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6103940, 4359044, 4359044, 4359044, 6185860, 4359044, 4359044, 4359044, 6284164, 4359044, 4359044, 6333316, 4359044, 4359044, 6022020, 4359044, 6038404, 4359044, 4359044, 6079364, 6112132, 4359044, 6177668, 6210436, 4359044, 6235012, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4358144, 4358144, 4358144, 900, 900, 900, 0, 0, 0, 0, 0, 0, 0, 1760, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 0, 419, 0, 4358144, 4358144, 4358144, 5890048, 4358144, 4358144, 4358144, 6029312, 4358144, 4358144, 4358144, 4358144, 6160384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6406144, 900, 900, 900, 900, 900, 900, 900, 900, 4998020, 900, 900, 5038980, 4359044, 5038980, 4359044, 4359044, 4359044, 5096324, 5104516, 4359044, 4359044, 5202820, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5890948, 4359044, 4359044, 4359044, 6030212, 4359044, 4359044, 4359044, 4359044, 6161284, 4359044, 4359044, 4359044, 6226820, 0, 0, 0, 4816896, 4358144, 4358144, 4358144, 4358144, 6086656, 4817796, 900, 900, 900, 900, 6087556, 4817872, 976, 976, 976, 976, 6087632, 4817796, 4359044, 4359044, 4359044, 4359044, 6087556, 5087232, 4358144, 4358144, 4358144, 5898240, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6307840, 4358144, 4358144, 6356992, 6381568, 6397952, 4801412, 4809604, 900, 900, 4891524, 900, 4948868, 900, 900, 900, 5047172, 900, 900, 900, 900, 900, 6054788, 900, 900, 900, 976, 976, 5014480, 976, 976, 976, 976, 976, 976, 976, 976, 976, 6054864, 976, 976, 976, 4359044, 4359044, 5014404, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6407044, 4358144, 4358144, 4358144, 900, 900, 900, 4890624, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5898240, 5963776, 0, 0, 6193152, 0, 0, 5406720, 6397952, 5186436, 900, 5235588, 5301124, 900, 900, 5407620, 5530500, 900, 900, 900, 900, 5899140, 900, 900, 900, 900, 900, 900, 900, 900, 6308740, 900, 900, 6357892, 6382468, 6398852, 4801488, 4809680, 976, 976, 4891600, 976, 4948944, 976, 976, 976, 5047248, 976, 976, 976, 976, 5186512, 976, 5235664, 5301200, 976, 976, 5407696, 5530576, 976, 976, 976, 976, 5899216, 976, 976, 976, 976, 976, 976, 976, 976, 6308816, 5899140, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6308740, 4359044, 4359044, 6357892, 6382468, 6398852, 5021696, 4358144, 4358144, 5022596, 900, 900, 0, 4980736, 0, 0, 0, 0, 0, 5373952, 5734400, 6045696, 0, 0, 0, 0, 0, 2771, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2785, 0, 2786, 0, 0, 0, 0, 0, 0, 0, 0, 1843, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1263, 0, 0, 0, 0, 0, 0, 0, 0, 4980736, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5324800, 5373952, 5537792, 5545984, 5734400, 5971968, 4358144, 6045696, 4358144, 6070272, 4358144, 4358144, 4358144, 6348800, 900, 4866948, 4883332, 900, 4981636, 900, 900, 900, 900, 5325700, 5374852, 5538692, 5546884, 5587844, 5735300, 5972868, 900, 6046596, 900, 6071172, 900, 900, 900, 900, 6349700, 976, 4867024, 4883408, 976, 4981712, 976, 976, 976, 976, 976, 976, 976, 976, 5325776, 5374928, 5538768, 5546960, 5587920, 5735376, 5972944, 976, 6046672, 976, 6071248, 976, 976, 976, 976, 6349776, 4359044, 4866948, 4883332, 4359044, 4981636, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5325700, 5374852, 5538692, 5546884, 5587844, 5735300, 5972868, 4359044, 6046596, 4359044, 6071172, 4359044, 4359044, 4359044, 4359044, 6349700, 4358144, 6144000, 900, 6144900, 0, 4988928, 5005312, 0, 0, 0, 0, 5775360, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 655, 0, 0, 521, 521, 521, 521, 521, 845, 521, 521, 861, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59499, 57909, 57909, 57909, 57886, 5693440, 0, 6496256, 5144576, 5136384, 0, 5914624, 4358144, 4358144, 5005312, 4358144, 4358144, 4358144, 5120000, 5136384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6324224, 900, 900, 5006212, 900, 900, 900, 5120900, 5137284, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 6325124, 976, 976, 5006288, 976, 976, 976, 5120976, 5137360, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 6325200, 4359044, 4359044, 4359044, 6390660, 4359044, 4359044, 6431620, 6439812, 4358144, 4358144, 4358144, 6266880, 6488064, 900, 900, 900, 6267780, 6488964, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1767, 0, 0, 0, 0, 0, 1773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4359044, 5006212, 4359044, 4359044, 4359044, 5120900, 5137284, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6325124, 5914624, 5915524, 0, 0, 0, 0, 0, 5513216, 5783552, 0, 3627, 0, 0, 0, 0, 0, 0, 2285, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1265, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 6300548, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 0, 5013504, 0, 0, 6053888, 0, 0, 0, 0, 6012928, 4358144, 4358144, 5013504, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6053888, 4358144, 4358144, 900, 900, 5014404, 900, 900, 900, 900, 6275972, 900, 900, 900, 900, 900, 900, 900, 900, 900, 0, 0, 977, 976, 976, 976, 976, 976, 4858832, 4875216, 976, 976, 976, 976, 976, 976, 976, 976, 976, 976, 0, 0, 0, 0, 900, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 6300548, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4358144, 4358144, 900, 5743492, 900, 900, 900, 6095748, 900, 976, 4907984, 976, 5080016, 976, 5227472, 976, 5743568, 976, 976, 976, 6095824, 976, 4359044, 4907908, 4359044, 5079940, 4359044, 5227396, 4359044, 5743492, 4359044, 4359044, 4359044, 6095748, 4359044, 5062656, 0, 0, 0, 4358144, 5062656, 4358144, 4358144, 4358144, 4358144, 4358144, 900, 5063556, 900, 900, 900, 900, 900, 6226820, 976, 5063632, 976, 976, 976, 976, 976, 6226896, 4359044, 5063556, 4359044, 4359044, 4359044, 4825988, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 4359044, 5178244, 4359044, 4359044, 4359044, 4359044, 4359044, 5243780, 4359044, 0, 5931008, 4358144, 5332992, 5980160, 4358144, 900, 5333892, 5981060, 900, 976, 5333968, 5981136, 976, 4359044, 5333892, 5981060, 4359044, 5439488, 5128192, 4358144, 5129092, 900, 5129168, 976, 5129092, 4359044, 4358144, 900, 976, 4359044, 4358144, 900, 976, 4359044, 6004736, 6005636, 6005712, 6005636, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2345, 0, 0, 0, 0, 0, 2351, 0, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 450560, 0, 0, 0, 0, 0, 0, 450560, 0, 0, 450560, 0, 450560, 450560, 450560, 450560, 450560, 450560, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 450560, 0, 0, 0, 450560, 0, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 450560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1824, 0, 0, 0, 0, 0, 0, 1729, 0, 0, 0, 0, 0, 0, 450560, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1848, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2359296, 0, 2359296, 0, 0, 0, 2359296, 0, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 4358144, 6291456, 4358144, 6316032, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6463488, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 302, 0, 0, 306, 0, 0, 0, 0, 0, 0, 2335, 0, 0, 0, 0, 0, 2339, 0, 0, 0, 0, 0, 0, 0, 2343, 2344, 0, 0, 0, 0, 0, 2350, 0, 0, 0, 0, 0, 0, 1302, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 2836, 521, 521, 521, 521, 2840, 521, 521, 4358144, 6430720, 6438912, 901, 0, 0, 0, 901, 0, 4784128, 0, 0, 0, 4849664, 0, 0, 0, 0, 0, 4915200, 0, 4956160, 4972544, 0, 0, 0, 0, 0, 0, 5070848, 0, 0, 0, 0, 0, 744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 327, 0, 0, 374, 374, 404, 977, 0, 4784128, 0, 0, 0, 4849664, 0, 0, 0, 0, 0, 4915200, 0, 4956160, 4972544, 0, 0, 0, 0, 0, 0, 5070848, 0, 0, 0, 0, 0, 0, 0, 5218304, 0, 5267456, 0, 0, 5308416, 5316608, 0, 0, 0, 5431296, 0, 5488640, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5799936, 0, 0, 5881856, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 6078464, 6111232, 4358144, 6176768, 6209536, 6234112, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 901, 0, 0, 0, 4841472, 0, 0, 0, 4898816, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3653, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3218, 521, 521, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60573, 57886, 60576, 57886, 57886, 57886, 6037504, 0, 0, 6078464, 6111232, 0, 6176768, 6209536, 0, 6234112, 0, 0, 0, 0, 0, 0, 0, 977, 0, 0, 0, 4841472, 0, 0, 0, 4898816, 0, 0, 0, 0, 0, 0, 0, 0, 6103040, 0, 0, 0, 6184960, 0, 0, 0, 6283264, 0, 0, 6332416, 0, 0, 0, 6389760, 0, 0, 6430720, 6438912, 0, 0, 0, 0, 0, 0, 0, 0, 459186, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 459215, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2291, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459340, 459215, 459372, 459215, 459215, 459372, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2777, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5480448, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5840896, 5849088, 0, 1, 24578, 3, 0, 0, 0, 0, 507904, 0, 0, 0, 507904, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 507904, 0, 0, 0, 0, 0, 2796, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2804, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3385, 3386, 0, 0, 0, 0, 3391, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 662, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2779, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2789, 0, 0, 0, 2793, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 507904, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2781, 0, 0, 2784, 0, 0, 0, 0, 2788, 0, 0, 0, 0, 0, 507904, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 442368, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 658, 0, 0, 661, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1225, 0, 0, 0, 0, 0, 0, 0, 1233, 0, 0, 0, 0, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 516096, 0, 0, 0, 516096, 0, 0, 0, 0, 0, 0, 516096, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2287, 0, 2288, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2297, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 516560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3152, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 516560, 1, 24578, 0, 0, 0, 4366336, 0, 0, 548864, 0, 0, 301, 302, 0, 4268032, 305, 306, 409600, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 2340, 0, 0, 0, 0, 0, 0, 0, 0, 2347, 0, 0, 0, 0, 0, 0, 2354, 4358144, 5005312, 4358144, 4358144, 4358144, 5120000, 5136384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6324224, 5914624, 5914624, 0, 0, 0, 0, 0, 5513216, 5783552, 0, 40960, 0, 0, 0, 0, 0, 0, 2747, 0, 2749, 0, 0, 2752, 0, 0, 0, 0, 0, 0, 2757, 0, 0, 0, 2760, 2761, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 855, 521, 521, 521, 521, 521, 874, 521, 521, 521, 521, 892, 521, 521, 521, 57886, 57886, 57886, 1, 24578, 4227364, 0, 0, 0, 0, 0, 0, 298, 0, 0, 0, 298, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1227, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 540672, 0, 0, 540672, 0, 0, 0, 540672, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1857, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24578, 4227364, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3148, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3393, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4268032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 499712, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3389, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2370, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24578, 3, 155941, 295, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 636, 0, 0, 0, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 742, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 437, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57887, 57887, 57887, 57887, 57887, 57887, 57887, 57910, 57910, 57887, 57887, 57937, 57887, 57887, 57887, 57887, 57887, 57887, 57887, 57937, 57937, 57887, 57887, 57887, 57887, 57937, 57937, 57887, 521, 57887, 57887, 57887, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4399797, 4399797, 4399797, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 410, 358, 0, 0, 399, 0, 0, 0, 0, 0, 139264, 147456, 399, 410, 0, 423, 410, 1, 24578, 3, 155942, 295, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1236, 0, 0, 0, 1, 24578, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 573440, 0, 573440, 573440, 573440, 0, 573440, 573440, 573440, 573440, 573440, 573440, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3628, 0, 0, 0, 3631, 0, 0, 0, 0, 0, 0, 0, 0, 3639, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 573440, 573440, 573440, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1819, 1820, 0, 1822, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1836, 0, 0, 0, 0, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 573440, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4399798, 311296, 4399798, 0, 0, 0, 311296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4276224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1260, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1847, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1738, 0, 5300224, 5234688, 5423104, 0, 0, 0, 0, 5988352, 0, 0, 6135808, 6307840, 0, 5996544, 4800512, 0, 6356992, 3627, 0, 0, 5496832, 0, 0, 0, 0, 0, 5611520, 0, 0, 0, 0, 0, 0, 0, 1792, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1801, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1818, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 326, 326, 376, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 630, 302, 0, 4268032, 633, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2806, 0, 0, 0, 0, 0, 0, 0, 0, 2814, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 581632, 0, 0, 0, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 581632, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 340, 581632, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3172, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3183, 521, 521, 3187, 521, 521, 6258688, 6447104, 0, 0, 6127616, 0, 6348800, 5906432, 0, 5537792, 3774, 0, 0, 0, 0, 5939200, 0, 0, 5677056, 6365184, 4866048, 0, 6070272, 5545984, 5152768, 0, 0, 6144000, 4358144, 4866048, 4882432, 4358144, 4358144, 4358144, 0, 901, 900, 900, 900, 900, 900, 4858756, 4875140, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 900, 5260164, 900, 900, 900, 900, 900, 900, 900, 900, 6103940, 900, 900, 900, 6185860, 900, 900, 900, 6284164, 900, 900, 6333316, 900, 900, 900, 6390660, 900, 900, 6431620, 6439812, 0, 0, 0, 0, 5537792, 5545984, 5586944, 5734400, 5971968, 4358144, 6045696, 4358144, 6070272, 4358144, 4358144, 4358144, 4358144, 6348800, 4358144, 6144000, 0, 6144000, 0, 4988928, 5005312, 0, 0, 0, 0, 5775360, 0, 0, 0, 3869, 0, 0, 0, 0, 0, 787, 0, 0, 521, 521, 521, 521, 521, 847, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60869, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59939, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59946, 57909, 59948, 57909, 59951, 57909, 57909, 4358144, 5005312, 4358144, 4358144, 4358144, 5120000, 5136384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6324224, 5914624, 5914624, 0, 0, 0, 0, 0, 5513216, 5783552, 0, 3869, 0, 0, 0, 0, 0, 0, 2822, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2830, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1938, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1387, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 310, 311, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3638, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 310, 0, 451, 465, 465, 465, 478, 478, 478, 478, 478, 478, 478, 478, 478, 499, 478, 478, 478, 478, 517, 478, 478, 478, 517, 478, 478, 478, 478, 478, 478, 522, 57888, 522, 57888, 522, 522, 57888, 522, 522, 57911, 57888, 522, 522, 57888, 57888, 57888, 57911, 57888, 57888, 57888, 57888, 57888, 57888, 57888, 57911, 57911, 57888, 57888, 57938, 57888, 57888, 57888, 57888, 57888, 57888, 57888, 57938, 57938, 57888, 57888, 57888, 57888, 57938, 57938, 57888, 522, 57888, 57888, 57888, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 638, 0, 0, 641, 642, 0, 0, 0, 0, 0, 0, 745, 0, 0, 0, 0, 0, 0, 751, 0, 0, 0, 0, 0, 0, 0, 0, 761, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1279, 0, 0, 0, 0, 1284, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1292, 0, 0, 0, 0, 0, 0, 0, 0, 743, 0, 0, 0, 0, 638, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 758, 0, 0, 0, 0, 764, 0, 0, 768, 0, 0, 0, 0, 0, 0, 3115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3121, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1166, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1175, 0, 1177, 1178, 0, 0, 0, 0, 0, 0, 0, 776, 0, 0, 0, 0, 780, 0, 0, 0, 0, 0, 0, 0, 784, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 641, 0, 0, 0, 0, 0, 3114, 0, 0, 0, 0, 0, 3118, 0, 0, 0, 0, 0, 0, 0, 3124, 3125, 3126, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1306, 0, 0, 0, 1310, 0, 0, 0, 0, 1313, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61024, 57886, 57886, 0, 824, 825, 0, 0, 0, 0, 780, 521, 521, 834, 838, 521, 521, 850, 521, 521, 521, 866, 521, 871, 521, 879, 521, 882, 521, 521, 896, 521, 57886, 57886, 57886, 57886, 57886, 57886, 59898, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 59913, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59448, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59461, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58253, 58257, 57886, 57886, 58269, 57886, 57886, 57886, 58285, 57886, 58290, 57886, 58298, 57886, 58301, 57886, 57886, 58315, 57886, 0, 57909, 57909, 57909, 58329, 58333, 57909, 57909, 58345, 57909, 57909, 57909, 58361, 57909, 58366, 57909, 58374, 57909, 58377, 57909, 57909, 58391, 57909, 0, 0, 0, 0, 58290, 57936, 57936, 57936, 58404, 58408, 57936, 57936, 58420, 57936, 57936, 57936, 58436, 57936, 58441, 57936, 58449, 57936, 0, 0, 0, 0, 521, 521, 521, 521, 521, 4172, 521, 57886, 57886, 57886, 57886, 57886, 61522, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 61528, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59544, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59557, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59545, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59014, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58452, 57936, 57936, 58466, 57936, 834, 838, 1128, 882, 521, 521, 0, 58257, 58253, 58478, 58301, 57886, 57886, 155941, 1138, 0, 0, 1141, 0, 0, 1146, 0, 0, 0, 0, 0, 0, 0, 0, 6103040, 0, 0, 0, 6184960, 0, 0, 0, 6283264, 0, 0, 6332416, 0, 0, 0, 6389760, 0, 0, 6430720, 6438912, 977, 0, 0, 0, 0, 0, 1210, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1231, 0, 0, 0, 0, 0, 0, 0, 0, 377, 0, 362, 0, 0, 0, 0, 0, 0, 0, 0, 0, 362, 0, 0, 0, 0, 139264, 147456, 0, 0, 0, 0, 0, 57886, 58831, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59964, 57909, 57909, 57909, 57909, 59969, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 1753, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1777, 0, 0, 0, 0, 0, 0, 0, 0, 1188, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 1199, 0, 0, 0, 0, 0, 0, 0, 0, 0, 688, 0, 0, 0, 0, 367, 367, 367, 0, 0, 697, 0, 0, 0, 0, 0, 0, 0, 704, 0, 0, 0, 0, 0, 0, 0, 1813, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2815, 0, 0, 1861, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1874, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1887, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61044, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 521, 521, 521, 521, 521, 1929, 521, 521, 1932, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1945, 521, 521, 521, 521, 521, 521, 1951, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59828, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59380, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 61166, 57909, 57909, 57909, 61169, 57909, 57909, 57909, 57909, 521, 58754, 1960, 57886, 57886, 57886, 57886, 57886, 59311, 57886, 57886, 57886, 57886, 57886, 59317, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59330, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60835, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60845, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60854, 57886, 50657, 2060, 57909, 57909, 57909, 57909, 57909, 59411, 57909, 57909, 57909, 57909, 57909, 59417, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59430, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58890, 57909, 57909, 57909, 58893, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58900, 57909, 57909, 58904, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59472, 57909, 57909, 59475, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59489, 57909, 57909, 57909, 57909, 57909, 57909, 59495, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3413, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3151, 0, 0, 0, 3155, 0, 3157, 0, 0, 0, 0, 0, 0, 0, 0, 57936, 57936, 57936, 57936, 57936, 59507, 57936, 57936, 57936, 57936, 57936, 59513, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59526, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59579, 57936, 57936, 57936, 57936, 57936, 57936, 59587, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 3105, 0, 0, 0, 0, 0, 0, 57936, 57936, 59568, 57936, 57936, 59571, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59585, 57936, 57936, 57936, 57936, 57936, 57936, 59591, 57936, 57936, 57936, 57936, 57936, 57936, 521, 2256, 521, 521, 521, 57886, 59605, 57886, 57886, 57886, 2265, 0, 2266, 0, 0, 0, 0, 2268, 0, 2269, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2275, 0, 0, 0, 0, 0, 0, 791, 0, 521, 521, 521, 521, 521, 521, 521, 521, 859, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 2265, 0, 2266, 0, 0, 0, 0, 2268, 0, 2269, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 212992, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1737, 1738, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 753, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 417792, 0, 0, 0, 0, 417792, 0, 0, 0, 0, 0, 309, 0, 309, 0, 0, 0, 0, 2331, 0, 2333, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1826, 0, 1828, 0, 0, 0, 0, 0, 0, 0, 1835, 0, 0, 521, 2464, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59829, 57886, 57886, 59832, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60265, 57886, 57886, 57886, 57886, 60268, 57886, 57886, 60270, 57886, 60271, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60280, 57886, 57886, 60284, 59840, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59860, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61032, 57886, 57886, 57886, 57886, 57886, 57886, 61038, 57886, 61040, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61089, 57936, 57936, 57936, 57909, 57909, 57909, 57909, 59929, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59949, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58886, 57909, 58888, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 60375, 57936, 60376, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60012, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60032, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60070, 57936, 57936, 57936, 2405, 521, 521, 521, 521, 59836, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2399, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2446, 521, 521, 521, 521, 521, 521, 521, 2452, 521, 521, 521, 521, 521, 521, 2457, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2847, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2889, 521, 521, 521, 521, 521, 521, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60315, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60323, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58924, 57909, 57909, 58928, 57909, 57909, 57909, 57909, 57909, 58935, 57909, 57909, 57909, 58942, 57909, 0, 57886, 57936, 57936, 57936, 57936, 60359, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60370, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60380, 57936, 0, 0, 0, 0, 521, 521, 521, 4170, 4171, 521, 521, 57886, 57886, 57886, 61520, 61521, 57886, 57886, 57886, 57909, 57909, 57909, 61526, 61527, 57909, 57909, 57909, 57936, 57936, 57936, 61532, 57936, 57936, 60435, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 301, 305, 0, 0, 0, 0, 3104, 0, 0, 0, 3108, 0, 0, 0, 0, 0, 0, 3142, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 262731, 0, 0, 0, 0, 0, 0, 0, 0, 3113, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3123, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3136, 57909, 60627, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60636, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60644, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61057, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61062, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 60676, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60685, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60693, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1192, 1193, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60915, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60933, 57936, 60935, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60703, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 2748, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 352256, 0, 352256, 352256, 0, 0, 0, 0, 521, 3948, 521, 3950, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 61307, 57886, 61309, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58807, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59347, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61165, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61170, 57909, 57909, 57909, 57909, 61323, 57909, 61325, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 61339, 57936, 61341, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 3859, 521, 61204, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 4012, 0, 0, 0, 4015, 0, 0, 521, 521, 521, 521, 4020, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 61377, 57886, 57886, 57886, 57886, 57886, 57909, 60861, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60352, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 312, 313, 314, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2765, 0, 0, 0, 0, 0, 0, 426, 0, 131072, 0, 0, 0, 426, 0, 0, 0, 0, 0, 426, 452, 0, 0, 0, 452, 452, 452, 452, 452, 452, 452, 452, 452, 452, 452, 452, 452, 516, 452, 516, 516, 516, 452, 516, 516, 516, 516, 516, 516, 523, 57889, 523, 57889, 523, 523, 57889, 523, 523, 57912, 57889, 523, 523, 57889, 57889, 57889, 57912, 57889, 57889, 57889, 57889, 57889, 57889, 57889, 57912, 57912, 57889, 57889, 57939, 57889, 57889, 57889, 57889, 57889, 57889, 57889, 57939, 57939, 57889, 57889, 57889, 57889, 57939, 57939, 57889, 614, 57889, 57966, 57966, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 385024, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 57909, 57909, 58370, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58445, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61199, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 805, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 641, 0, 0, 0, 0, 0, 820, 780, 0, 0, 0, 0, 0, 0, 754, 0, 0, 754, 0, 0, 0, 0, 0, 754, 754, 0, 0, 815, 0, 0, 0, 0, 0, 0, 0, 0, 0, 754, 0, 0, 0, 0, 0, 0, 2770, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2379, 0, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 60312, 57909, 57909, 57909, 57909, 60316, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60345, 57909, 57909, 57909, 57909, 60349, 57909, 57909, 57909, 60354, 57909, 57909, 57909, 57909, 60381, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60432, 57936, 57936, 57936, 57936, 57936, 60436, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 301, 305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3387, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2807, 0, 0, 0, 0, 0, 2812, 0, 0, 0, 0, 0, 57886, 61381, 57886, 61383, 57886, 57886, 61385, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61395, 57909, 61397, 57909, 57909, 61399, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57936, 61409, 57936, 61411, 57936, 57936, 61413, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2271, 0, 0, 0, 0, 0, 0, 0, 0, 0, 350, 351, 352, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 319, 319, 427, 428, 131072, 435, 428, 436, 427, 435, 436, 0, 315, 436, 448, 453, 466, 466, 466, 479, 479, 479, 479, 479, 479, 479, 479, 479, 479, 501, 501, 501, 514, 514, 515, 515, 501, 515, 515, 515, 501, 515, 515, 515, 515, 515, 515, 524, 57890, 524, 57890, 524, 524, 57890, 524, 524, 57913, 57890, 524, 524, 57890, 57890, 57890, 57913, 57890, 57890, 57890, 57890, 57890, 57890, 57890, 57913, 57913, 57890, 57890, 57940, 57890, 57890, 57890, 57890, 57890, 57890, 57890, 57940, 57940, 57890, 57890, 57890, 57890, 57940, 57940, 57890, 615, 57965, 57965, 57965, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 401408, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1198, 367, 367, 0, 0, 1201, 0, 0, 0, 1204, 0, 1206, 0, 679, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 695, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5242880, 0, 0, 0, 0, 0, 5603328, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 58378, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59553, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58453, 57936, 57936, 57936, 57936, 521, 521, 521, 883, 521, 521, 0, 57886, 57886, 57886, 58302, 57886, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3411, 0, 0, 0, 3415, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 57886, 521, 57886, 521, 521, 57886, 521, 521, 57909, 57886, 521, 521, 57886, 57886, 57886, 57909, 521, 521, 521, 58754, 901, 57886, 57886, 58758, 57886, 57886, 58762, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58776, 57886, 58781, 57886, 57886, 58785, 57886, 57886, 58788, 57886, 57886, 57886, 57886, 57886, 57886, 58279, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 58322, 57909, 57909, 57909, 57909, 57909, 57909, 58355, 57909, 57909, 57909, 58876, 57909, 57909, 58880, 57909, 57909, 58883, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58902, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 58951, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58965, 57936, 58970, 57936, 57936, 58974, 57936, 57936, 58977, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 3861, 0, 0, 0, 3863, 0, 0, 0, 0, 0, 0, 3627, 3870, 0, 1723, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 385, 521, 521, 521, 1927, 1928, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2433, 521, 521, 521, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59320, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59332, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 61494, 57909, 61495, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 61502, 57936, 61503, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60018, 57936, 60020, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60396, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60401, 57936, 57936, 57936, 57936, 57936, 57886, 57886, 59370, 59371, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59420, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59432, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59446, 57909, 57909, 57909, 59450, 57909, 57909, 59455, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59990, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59998, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 59470, 59471, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 643, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3447, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1341, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3200, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 61016, 57886, 57886, 57886, 61019, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59566, 59567, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3162, 0, 0, 521, 2437, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2450, 521, 521, 521, 521, 521, 2454, 2455, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1374, 521, 1376, 521, 521, 521, 521, 521, 521, 521, 1389, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1404, 57886, 57886, 57886, 57886, 59869, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59882, 57886, 57886, 57886, 57886, 57886, 59886, 59887, 59888, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58800, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58822, 57886, 57886, 57886, 57886, 0, 0, 0, 2744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 114688, 0, 0, 57886, 57886, 57886, 60288, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2962, 0, 0, 0, 0, 0, 826, 0, 0, 521, 521, 521, 521, 521, 849, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 60863, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60875, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59447, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60672, 3137, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1837, 0, 0, 0, 3166, 0, 0, 3169, 0, 0, 0, 0, 0, 0, 0, 3173, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2451, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3379, 0, 0, 0, 0, 0, 0, 0, 3383, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3422, 0, 0, 0, 0, 0, 0, 3429, 521, 3458, 3459, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60827, 57886, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 640, 0, 0, 0, 0, 0, 0, 0, 695, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 883, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 2267, 0, 1142, 0, 0, 0, 0, 2270, 0, 1147, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1795, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1809, 57909, 60884, 57909, 60886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60000, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60911, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60926, 57936, 60928, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60045, 60046, 57936, 57936, 57936, 57936, 57936, 57936, 60053, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61072, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59595, 57936, 57936, 57936, 1881, 521, 4010, 0, 4011, 0, 0, 0, 0, 0, 0, 0, 521, 4018, 521, 4019, 521, 521, 521, 4023, 521, 521, 521, 521, 521, 521, 521, 57886, 61375, 57886, 61376, 57886, 57886, 57886, 57886, 57886, 57886, 60264, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60269, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60275, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60283, 57886, 61380, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 61389, 57909, 61390, 57909, 57909, 57909, 61394, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 61403, 57936, 61404, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60388, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 3376, 0, 0, 61408, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 1710, 0, 0, 0, 0, 0, 0, 1717, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2338, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2294, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 4213, 57886, 57886, 57886, 61559, 57909, 57909, 57909, 61561, 57936, 57936, 57936, 61563, 0, 521, 521, 57886, 57886, 57909, 57909, 57936, 57936, 521, 57886, 57909, 57936, 521, 521, 521, 521, 521, 521, 0, 2471, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59858, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 376, 0, 131072, 0, 0, 0, 376, 0, 0, 438, 444, 0, 376, 454, 467, 467, 467, 480, 480, 480, 480, 480, 480, 480, 480, 480, 480, 502, 502, 502, 502, 502, 502, 502, 502, 502, 502, 502, 502, 502, 502, 502, 525, 57891, 525, 57891, 525, 525, 57891, 525, 525, 57914, 57891, 525, 525, 57891, 57891, 57891, 57914, 57891, 57891, 57891, 57891, 57891, 57891, 57891, 57914, 57914, 57891, 57891, 57941, 57891, 57891, 57891, 57891, 57891, 57891, 57891, 57941, 57941, 57891, 57891, 57891, 57891, 57941, 57941, 57891, 525, 57891, 57891, 57891, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 229376, 0, 491520, 524288, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 725, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1180, 1181, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 719, 0, 0, 0, 0, 0, 0, 0, 0, 0, 729, 0, 0, 0, 0, 0, 0, 0, 0, 0, 738, 0, 0, 1166, 0, 1298, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1284, 0, 0, 0, 1312, 1180, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 1321, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 60241, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58814, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 521, 521, 521, 521, 521, 1371, 521, 521, 1373, 521, 521, 521, 521, 1378, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1403, 521, 521, 521, 521, 521, 521, 521, 521, 3196, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3203, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1902, 521, 521, 521, 521, 521, 521, 521, 521, 1913, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1935, 521, 521, 521, 1941, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1950, 521, 521, 521, 521, 1956, 521, 521, 521, 521, 58754, 901, 57886, 57886, 58759, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58786, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61247, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61263, 57909, 57909, 57936, 57909, 57909, 57909, 57909, 58881, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58896, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58905, 57909, 57909, 58907, 57909, 57909, 57909, 57909, 58912, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58937, 57909, 57909, 57909, 57909, 0, 58812, 57936, 57936, 58948, 57936, 0, 0, 0, 0, 521, 521, 4169, 521, 521, 521, 4173, 57886, 57886, 61519, 57886, 57886, 57886, 61523, 57886, 57909, 57909, 61525, 57909, 57909, 57909, 61529, 57909, 57936, 57936, 61531, 57936, 0, 0, 0, 0, 4168, 521, 521, 521, 521, 521, 521, 61518, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61524, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61530, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61274, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 57886, 0, 3938, 0, 0, 3941, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1883, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2876, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 60819, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58999, 57936, 57936, 59001, 57936, 57936, 57936, 57936, 59007, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59519, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59530, 57936, 57936, 57936, 57936, 57936, 59032, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 1705, 0, 0, 0, 0, 1712, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2410, 521, 521, 521, 2259, 57886, 57886, 57886, 57886, 59608, 2265, 0, 2266, 0, 0, 0, 0, 2268, 0, 2269, 0, 0, 0, 0, 0, 2272, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2408, 521, 521, 521, 521, 521, 521, 521, 521, 2416, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1397, 521, 521, 521, 521, 521, 57886, 59893, 57886, 59895, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59916, 57909, 57909, 57909, 57909, 59920, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59958, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59971, 57909, 57909, 57909, 57909, 57909, 59975, 59976, 59977, 57909, 57909, 57909, 57909, 57909, 57909, 59982, 57909, 59984, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59999, 57936, 57936, 57936, 57936, 60003, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60683, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 3369, 521, 57886, 60716, 57886, 0, 0, 0, 0, 0, 57936, 57936, 57936, 57936, 57936, 60065, 57936, 60067, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 2739, 2266, 0, 2740, 2269, 0, 0, 0, 0, 0, 0, 3622, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 415, 415, 0, 0, 0, 0, 0, 60285, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2962, 0, 0, 0, 0, 0, 1156, 1157, 1158, 1159, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 791, 0, 0, 0, 0, 0, 0, 0, 791, 0, 0, 57909, 57909, 57909, 60310, 57909, 60311, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59460, 57909, 57909, 57909, 57909, 57909, 59467, 57909, 521, 521, 3191, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3204, 521, 521, 521, 521, 521, 521, 521, 3210, 57886, 57886, 57886, 60582, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60596, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60606, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 57909, 57909, 57909, 57909, 60617, 57909, 57909, 57909, 57909, 57909, 57909, 60624, 57909, 57886, 60602, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 2962, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61182, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58975, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58990, 57909, 57909, 57909, 57909, 60651, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60680, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60694, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61273, 57936, 61275, 57936, 57936, 57936, 57936, 57936, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1878, 1879, 521, 521, 521, 521, 1886, 521, 521, 521, 521, 521, 521, 521, 521, 1337, 521, 1342, 521, 521, 1346, 521, 521, 1349, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1380, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1396, 521, 521, 521, 521, 521, 57936, 57936, 57936, 57936, 57936, 60700, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 3768, 0, 0, 0, 0, 57909, 61073, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60030, 57936, 57936, 57936, 57936, 57936, 0, 521, 521, 521, 521, 521, 521, 3953, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 61312, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 2557, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59466, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61328, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 61344, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 61382, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61396, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61080, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61090, 57936, 57936, 57936, 57936, 61410, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 2265, 1706, 2266, 0, 0, 0, 0, 2268, 1713, 2269, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1243, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2353, 0, 0, 330, 0, 0, 0, 0, 0, 0, 375, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 330, 0, 139264, 147456, 0, 0, 0, 0, 0, 0, 0, 1842, 0, 0, 1845, 0, 0, 0, 0, 0, 0, 1851, 1852, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1845, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 329, 0, 0, 0, 0, 455, 468, 468, 468, 481, 481, 481, 481, 492, 494, 481, 481, 492, 481, 503, 503, 503, 503, 518, 503, 503, 503, 518, 503, 503, 503, 503, 503, 503, 526, 57892, 526, 57892, 526, 526, 57892, 526, 526, 57915, 57892, 526, 526, 57892, 57892, 57892, 57915, 57892, 57892, 57892, 57892, 57892, 57892, 57892, 57915, 57915, 57892, 57892, 57942, 57892, 57892, 57892, 57892, 57892, 57892, 57892, 57942, 57942, 57892, 57892, 57892, 57892, 57942, 57942, 57892, 526, 57892, 57892, 57892, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 0, 0, 0, 0, 0, 2310144, 2310144, 0, 0, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 0, 0, 0, 651, 652, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 663, 664, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 676, 677, 678, 0, 0, 0, 682, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 700, 701, 0, 0, 0, 0, 0, 707, 0, 0, 0, 0, 0, 3141, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 450560, 450560, 0, 0, 0, 0, 0, 711, 0, 713, 0, 0, 0, 0, 0, 0, 720, 0, 0, 0, 724, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2756, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 742, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 752, 0, 0, 0, 0, 0, 0, 759, 0, 0, 0, 765, 766, 0, 0, 0, 0, 0, 0, 0, 2308, 0, 0, 0, 0, 2313, 2314, 0, 0, 2316, 2317, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 270336, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 301, 0, 0, 305, 0, 0, 4857856, 4874240, 0, 0, 4923392, 0, 0, 0, 775, 0, 777, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 789, 0, 794, 0, 797, 0, 0, 0, 0, 0, 0, 777, 0, 789, 0, 803, 0, 0, 0, 0, 797, 809, 0, 0, 0, 0, 0, 809, 809, 812, 0, 0, 0, 777, 0, 0, 0, 0, 0, 821, 0, 0, 0, 0, 0, 0, 806, 0, 0, 806, 0, 0, 0, 0, 0, 806, 806, 0, 0, 0, 0, 786, 0, 0, 0, 0, 0, 0, 822, 782, 0, 0, 0, 0, 0, 775, 0, 0, 0, 821, 521, 521, 835, 521, 841, 521, 521, 856, 521, 521, 867, 521, 872, 521, 521, 881, 884, 889, 521, 897, 521, 57886, 57886, 57886, 57886, 57886, 57886, 60291, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2962, 0, 0, 58254, 57886, 58260, 57886, 57886, 58275, 57886, 57886, 58286, 57886, 58291, 57886, 57886, 58300, 58303, 58308, 57886, 58316, 57886, 0, 57909, 57909, 57909, 58330, 57909, 58336, 57909, 57909, 58351, 57909, 57909, 58362, 57909, 58367, 57909, 57909, 58376, 58379, 58384, 57909, 58392, 57909, 0, 0, 0, 0, 58291, 57936, 57936, 57936, 58405, 57936, 58411, 57936, 57936, 58426, 57936, 57936, 58437, 57936, 58442, 57936, 57936, 58451, 58454, 58459, 57936, 58467, 57936, 835, 521, 521, 1129, 889, 521, 0, 57886, 58254, 57886, 58479, 58308, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2326528, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 1153, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1163, 0, 0, 0, 0, 0, 0, 0, 1170, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1051, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6299648, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 1209, 0, 0, 0, 0, 0, 0, 0, 0, 1218, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1235, 0, 0, 1187, 0, 0, 0, 0, 0, 3434, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3451, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59827, 57886, 57886, 57886, 57886, 59831, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58801, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58810, 57886, 57886, 58812, 57886, 57886, 57886, 57886, 58817, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61388, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61402, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 742, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1258, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5857280, 0, 6463488, 4939776, 0, 0, 5455872, 0, 0, 0, 0, 0, 0, 0, 0, 6062080, 6463488, 0, 5398528, 0, 521, 521, 521, 521, 1328, 521, 521, 521, 521, 521, 521, 1343, 521, 521, 521, 1348, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1365, 521, 1407, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58767, 57886, 57886, 57886, 57886, 57886, 57886, 58782, 57886, 57886, 57886, 58787, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58839, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 58855, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58869, 57909, 57909, 57909, 58877, 57909, 57909, 57909, 58882, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58899, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 58419, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59003, 57936, 59005, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59018, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60704, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 57936, 57936, 57936, 57936, 57936, 57936, 58956, 57936, 57936, 57936, 57936, 57936, 57936, 58971, 57936, 57936, 57936, 58976, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 2741, 0, 57936, 58993, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59009, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59025, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61101, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 690, 691, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 703, 0, 0, 0, 0, 0, 57936, 57936, 57936, 59036, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 1705, 0, 0, 0, 0, 1712, 0, 0, 0, 0, 1719, 0, 1721, 0, 0, 0, 0, 0, 3621, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3632, 0, 0, 0, 3635, 3636, 0, 0, 0, 0, 0, 0, 393678, 0, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 393678, 0, 393678, 393678, 0, 1754, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1770, 0, 0, 0, 0, 0, 1776, 0, 0, 1779, 0, 1781, 0, 0, 0, 0, 0, 0, 3642, 0, 3644, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2854, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1943, 1944, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 1787, 1788, 0, 0, 0, 0, 0, 0, 0, 0, 1797, 1798, 0, 0, 0, 0, 0, 0, 1804, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 888, 521, 521, 521, 521, 57886, 57886, 57886, 1810, 1811, 1812, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1830, 1831, 0, 1832, 1833, 0, 0, 0, 0, 0, 0, 1186, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 810, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3395, 0, 0, 3397, 0, 0, 0, 0, 0, 0, 0, 0, 1863, 1721, 1721, 1865, 521, 1867, 521, 1868, 1869, 521, 1871, 521, 521, 521, 1875, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1888, 521, 521, 521, 521, 1892, 521, 521, 521, 521, 1896, 521, 1898, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1908, 1909, 1911, 521, 521, 521, 521, 521, 521, 521, 1919, 1920, 521, 1922, 521, 521, 521, 521, 521, 521, 521, 521, 3667, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60611, 57886, 57886, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60622, 57909, 60625, 521, 1925, 1926, 521, 521, 521, 521, 521, 521, 521, 1934, 521, 1936, 521, 1939, 521, 521, 521, 521, 521, 1946, 521, 521, 1948, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3197, 3198, 521, 521, 521, 521, 3201, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3206, 521, 521, 521, 3209, 521, 521, 58754, 0, 59307, 57886, 59309, 57886, 59310, 57886, 59312, 57886, 59314, 57886, 57886, 57886, 59318, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59331, 57886, 57886, 57886, 57886, 59335, 57886, 1, 24578, 3, 155941, 156275, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 483328, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2341, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 59339, 57886, 59341, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59351, 59352, 59354, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59362, 59363, 57886, 59365, 57886, 57886, 57886, 57886, 57886, 58799, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58829, 59368, 59369, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59377, 57886, 59379, 57886, 59382, 57886, 57886, 57886, 57886, 57886, 59390, 57886, 57886, 59392, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 2558, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60371, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 60377, 57936, 57936, 57936, 57936, 50657, 0, 59407, 57909, 59409, 57909, 59410, 57909, 59412, 57909, 59414, 57909, 57909, 57909, 59418, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59431, 57909, 57909, 57909, 57909, 59435, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58916, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 521, 1335, 521, 521, 521, 521, 58774, 57886, 57886, 57886, 57886, 57886, 1138, 0, 0, 1709, 0, 0, 0, 0, 1716, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3882, 521, 3884, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59847, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60277, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 59439, 57909, 59441, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59451, 59452, 59454, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59462, 59463, 57909, 59465, 57909, 57909, 59468, 59469, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59477, 57909, 59479, 57909, 59482, 57909, 57909, 57909, 57909, 57909, 59490, 57909, 57909, 59492, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 57886, 57886, 57886, 60290, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60299, 57886, 57886, 57886, 60302, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 1214, 0, 0, 0, 0, 0, 0, 0, 0, 1223, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1238, 59503, 57936, 59505, 57936, 59506, 57936, 59508, 57936, 59510, 57936, 57936, 57936, 59514, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59527, 57936, 57936, 57936, 57936, 59531, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 0, 1707, 0, 0, 0, 0, 1714, 0, 0, 0, 0, 0, 0, 0, 0, 3170, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3182, 521, 3185, 521, 521, 521, 521, 59535, 57936, 59537, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59547, 59548, 59550, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59558, 59559, 57936, 57936, 59561, 57936, 57936, 59564, 59565, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59573, 57936, 59575, 57936, 59578, 57936, 57936, 57936, 57936, 57936, 59586, 57936, 57936, 59588, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 1926, 521, 2258, 521, 57886, 59369, 57886, 59607, 57886, 2265, 0, 2266, 0, 0, 0, 0, 2268, 0, 2269, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2276, 0, 0, 2279, 2280, 0, 0, 0, 2284, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2790, 0, 0, 0, 0, 2303, 0, 0, 0, 0, 2307, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2323, 0, 0, 0, 0, 2327, 0, 0, 0, 0, 0, 3873, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58803, 57886, 57886, 57886, 57886, 58808, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58816, 57886, 57886, 57886, 58823, 58825, 57886, 57886, 57886, 0, 2356, 0, 0, 0, 0, 0, 0, 0, 0, 2365, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2375, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 875, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 2412, 521, 2414, 521, 521, 521, 521, 521, 521, 521, 2420, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1357, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2441, 2442, 521, 521, 521, 521, 521, 521, 2449, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1383, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1400, 521, 521, 521, 2463, 521, 521, 2466, 2467, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59833, 57886, 59835, 57886, 57886, 57886, 57886, 57886, 57886, 60585, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60599, 57886, 57886, 57886, 57886, 57886, 59843, 57886, 59845, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59851, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60300, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 59896, 57886, 57886, 59899, 59900, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59922, 57909, 57909, 57909, 57909, 57909, 57909, 58388, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 3862, 0, 0, 3865, 0, 0, 0, 0, 3627, 0, 0, 59924, 57909, 57909, 57909, 57909, 57909, 57909, 59932, 57909, 59934, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59940, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 59991, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60707, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 60007, 57936, 57936, 57936, 57936, 57936, 57936, 60015, 57936, 60017, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60023, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 2739, 2266, 0, 2740, 2269, 0, 0, 0, 521, 2868, 521, 521, 521, 521, 2872, 521, 521, 521, 2877, 521, 521, 521, 521, 521, 521, 521, 521, 2885, 521, 521, 521, 521, 521, 521, 521, 2890, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 59820, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58811, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60259, 57886, 60261, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60278, 57886, 57886, 57886, 57886, 60282, 57886, 57886, 57886, 57886, 57886, 60605, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60319, 57909, 57909, 57909, 57909, 57909, 60324, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 60287, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60295, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60301, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2962, 0, 0, 0, 0, 0, 1185, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1732, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1856, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60314, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60326, 57909, 60328, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60365, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61082, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 57909, 60362, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60368, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60379, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58959, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58978, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58988, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58960, 58967, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58980, 57936, 58982, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60417, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60424, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60410, 57936, 57936, 57936, 57936, 60414, 57936, 57936, 57936, 60419, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60427, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 3103, 0, 0, 3106, 3107, 0, 0, 3110, 3111, 60433, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 301, 305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 728, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3140, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 278528, 0, 0, 0, 0, 0, 0, 3167, 3168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3189, 60580, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60593, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60600, 57909, 57909, 57909, 60629, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60642, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58925, 57909, 57909, 57909, 57909, 57909, 58933, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57909, 57909, 60649, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60678, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60691, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60044, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 57886, 3937, 0, 3939, 0, 0, 0, 0, 0, 3627, 3943, 0, 3945, 57936, 57936, 57936, 60698, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 2368, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2398, 521, 521, 2401, 521, 521, 521, 521, 521, 521, 2409, 521, 521, 3403, 0, 0, 0, 0, 3405, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3419, 0, 0, 0, 0, 3424, 3425, 0, 3427, 0, 0, 0, 0, 0, 1197, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1286, 0, 0, 0, 0, 1314, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3452, 521, 521, 521, 521, 3430, 0, 0, 0, 3433, 521, 521, 521, 521, 521, 521, 3440, 521, 521, 521, 521, 521, 3444, 521, 521, 521, 521, 521, 521, 521, 3450, 521, 521, 521, 521, 521, 3456, 60828, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60834, 57886, 57886, 57886, 57886, 57886, 60840, 57886, 57886, 60843, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60850, 60852, 57886, 57886, 57886, 57886, 57886, 57886, 58282, 58284, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 58327, 57909, 57909, 57909, 57909, 57909, 57909, 58358, 58360, 57909, 60856, 57886, 60858, 60859, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 60866, 57909, 57909, 57909, 57909, 57909, 60870, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60876, 57909, 57909, 57909, 57909, 57909, 60882, 57909, 57909, 60885, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60892, 60894, 57909, 57909, 57909, 57909, 60898, 57909, 60900, 60901, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 60908, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61200, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3866, 3867, 0, 3627, 0, 3871, 57936, 57936, 60912, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60918, 57936, 57936, 57936, 57936, 57936, 60924, 57936, 57936, 60927, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60934, 60936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59000, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59020, 57936, 57936, 57936, 57936, 57936, 59028, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59542, 57936, 57936, 57936, 59546, 57936, 57936, 59551, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60048, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60940, 57936, 60942, 60943, 57936, 521, 521, 3602, 57886, 57886, 60949, 0, 0, 0, 0, 0, 0, 3611, 0, 0, 3614, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 3649, 3650, 521, 521, 521, 521, 3654, 3655, 521, 521, 521, 521, 521, 3659, 521, 521, 521, 521, 3662, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 61018, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61023, 57886, 57886, 57886, 57886, 57886, 57886, 60833, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60841, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60855, 57909, 57909, 57909, 57909, 57909, 57909, 61052, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61063, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61071, 57909, 57909, 57909, 57909, 57909, 57909, 58914, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58930, 57909, 57909, 57909, 57909, 57909, 57909, 58941, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 303104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57886, 57886, 61240, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61256, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 61076, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61081, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61092, 57886, 57886, 57886, 61440, 57886, 61442, 57886, 57886, 57886, 57886, 61447, 61448, 61449, 61450, 57909, 57909, 57909, 61453, 57909, 61455, 57909, 57909, 57909, 57909, 61460, 61461, 61462, 61463, 57936, 57936, 57936, 61466, 57936, 61468, 57936, 57936, 57936, 57936, 61473, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61031, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 61392, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 61406, 57936, 57936, 57936, 61535, 57936, 0, 0, 0, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 521, 521, 521, 521, 4198, 521, 57886, 57886, 57886, 57886, 61546, 57886, 57909, 57909, 57909, 57909, 61550, 57909, 57936, 57936, 57936, 57936, 61554, 57936, 0, 371, 371, 0, 429, 131072, 371, 429, 429, 332, 371, 429, 0, 0, 429, 449, 429, 0, 0, 0, 429, 488, 488, 488, 493, 488, 488, 488, 493, 488, 429, 429, 429, 429, 429, 429, 429, 429, 429, 429, 429, 429, 429, 429, 429, 527, 57893, 527, 57893, 527, 527, 57893, 527, 527, 57916, 57893, 527, 527, 57893, 57893, 57893, 57916, 57893, 57893, 57893, 57893, 57893, 57893, 57893, 57916, 57916, 57893, 57893, 57943, 57893, 57893, 57893, 57893, 57893, 57893, 57893, 57943, 57943, 57893, 57893, 57893, 57893, 57943, 57943, 57893, 527, 57893, 57893, 57893, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 4399798, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 773, 0, 0, 0, 521, 828, 521, 521, 521, 521, 521, 521, 860, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 58246, 1295, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 2839, 521, 521, 521, 521, 521, 521, 1326, 521, 521, 521, 521, 521, 1338, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2430, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58765, 57886, 57886, 57886, 57886, 57886, 58777, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59381, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61041, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 58954, 57936, 57936, 57936, 57936, 57936, 58966, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 3375, 0, 0, 0, 57909, 57909, 57909, 59954, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60355, 57909, 57909, 57909, 57936, 57936, 57936, 60037, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59026, 57936, 57936, 57936, 0, 0, 4212, 521, 521, 521, 61558, 57886, 57886, 57886, 61560, 57909, 57909, 57909, 61562, 57936, 57936, 57936, 0, 521, 521, 57886, 57886, 57909, 57909, 57936, 57936, 521, 57886, 57909, 57936, 521, 521, 521, 521, 521, 521, 521, 521, 3793, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60607, 57886, 57886, 60610, 57886, 57886, 60613, 0, 0, 60614, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60637, 60638, 57909, 57909, 57909, 57909, 60641, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60647, 0, 0, 0, 430, 131072, 0, 430, 430, 0, 0, 430, 439, 0, 430, 0, 430, 469, 469, 469, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 528, 57894, 528, 57894, 528, 528, 57894, 528, 528, 57917, 57894, 528, 528, 57894, 57894, 57894, 57917, 57894, 57894, 57894, 57894, 57894, 57894, 57894, 57917, 57917, 57894, 57894, 57944, 57894, 57894, 57894, 57894, 57894, 57894, 57894, 57944, 57944, 57894, 57894, 57894, 57894, 57944, 57944, 57894, 528, 57894, 57894, 57894, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 58754, 1961, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 2561, 0, 50657, 2061, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59950, 57909, 57909, 2302, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2326, 0, 0, 0, 0, 0, 1213, 0, 1215, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 0, 420, 0, 0, 0, 0, 0, 2385, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1949, 521, 521, 521, 521, 521, 521, 521, 0, 3138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3158, 0, 0, 0, 0, 0, 0, 0, 0, 1731, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1747, 0, 0, 1750, 0, 0, 521, 521, 521, 3213, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58868, 57909, 0, 0, 3404, 0, 0, 0, 0, 0, 3407, 0, 3409, 0, 0, 3412, 0, 0, 0, 0, 0, 3417, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 4399797, 4399797, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 3460, 521, 521, 521, 521, 521, 521, 521, 521, 3468, 521, 521, 3471, 521, 521, 521, 60818, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58296, 57886, 57886, 57886, 57886, 58314, 57886, 57886, 0, 57909, 57909, 58325, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 60857, 57886, 57886, 57886, 60860, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60877, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59959, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 60664, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 57909, 57909, 60887, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60896, 57909, 57909, 60899, 57909, 57909, 57909, 60902, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 4089, 521, 57886, 57886, 57886, 60938, 57936, 57936, 60941, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3615, 0, 0, 0, 0, 0, 0, 0, 393, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3159, 3160, 0, 0, 0, 0, 0, 521, 521, 521, 521, 3663, 521, 3665, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 61017, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59850, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59857, 57886, 59859, 57886, 59862, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61029, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61035, 57886, 61037, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 61046, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58917, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58934, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 58949, 57936, 61093, 57936, 61095, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 3791, 521, 521, 521, 521, 521, 521, 521, 521, 3797, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58804, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58819, 57886, 57886, 57886, 57886, 57886, 57886, 61153, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61159, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61172, 57909, 57909, 57909, 57909, 57909, 57909, 58915, 57909, 57909, 58922, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58936, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 521, 1336, 521, 521, 521, 521, 58775, 57886, 57886, 57886, 57886, 57886, 1138, 0, 0, 0, 0, 1711, 0, 0, 0, 0, 1718, 0, 0, 0, 0, 0, 0, 1247, 1248, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1155, 1154, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2799, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3630, 0, 0, 0, 0, 0, 0, 0, 3637, 0, 0, 57936, 57936, 57936, 57936, 57936, 61197, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3782, 0, 0, 521, 521, 521, 521, 0, 0, 0, 0, 683, 684, 0, 0, 0, 0, 689, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 530, 57896, 530, 57896, 530, 530, 57896, 530, 530, 57919, 57896, 530, 530, 57896, 57896, 57896, 57919, 57886, 58258, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58317, 0, 57909, 57909, 57909, 57909, 58334, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59481, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57936, 57936, 57936, 57936, 58468, 521, 839, 521, 521, 521, 898, 0, 58258, 57886, 57886, 57886, 57886, 58317, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1219, 1220, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6299648, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5808128, 0, 0, 0, 1211, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1230, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 3647, 521, 521, 521, 521, 521, 521, 521, 3652, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2421, 521, 521, 521, 2424, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2895, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60842, 57886, 60844, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 1839, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1853, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1307, 1308, 0, 0, 1154, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 1319, 521, 521, 521, 1958, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2962, 0, 0, 386, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 401, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 412, 0, 0, 0, 0, 0, 0, 412, 139264, 147456, 0, 0, 0, 421, 0, 333, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 333, 0, 0, 0, 0, 0, 0, 0, 0, 333, 0, 0, 139264, 147456, 0, 0, 0, 0, 0, 0, 0, 2773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3634, 0, 0, 0, 0, 0, 0, 424, 424, 0, 0, 131072, 424, 0, 0, 0, 424, 0, 440, 0, 0, 424, 334, 470, 470, 470, 483, 483, 483, 483, 483, 483, 483, 483, 483, 483, 504, 512, 512, 512, 512, 519, 512, 512, 512, 519, 512, 512, 512, 512, 512, 512, 529, 57895, 529, 57895, 529, 529, 57895, 529, 529, 57918, 57895, 529, 529, 57895, 57895, 57895, 57918, 57895, 57895, 57895, 57895, 57895, 57895, 57895, 57918, 57918, 57895, 57895, 57945, 57895, 57895, 57895, 57895, 57895, 57895, 57895, 57945, 57945, 57895, 57895, 57895, 57895, 57945, 57945, 57895, 529, 57895, 57895, 57895, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1734, 0, 0, 0, 0, 0, 0, 0, 0, 1741, 0, 0, 1744, 1745, 1746, 0, 1748, 1749, 0, 0, 0, 822, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 842, 521, 851, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 899, 57886, 57886, 57886, 57886, 57886, 57886, 61244, 57886, 57886, 57886, 61248, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 61254, 57909, 57909, 57909, 57909, 57909, 57909, 61260, 57909, 57909, 57909, 61264, 57909, 57936, 57886, 57886, 58261, 57886, 58270, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58318, 0, 57909, 57909, 57909, 57909, 57909, 58337, 57909, 58346, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58887, 58889, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60661, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60669, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58469, 521, 521, 521, 521, 1130, 899, 0, 57886, 57886, 57886, 57886, 58480, 58318, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1764, 1765, 1766, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2319, 2320, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 1331, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1350, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1360, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59825, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59837, 57886, 57886, 521, 1408, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58770, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58789, 57886, 57886, 57886, 57886, 57886, 57886, 59342, 59343, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59360, 57886, 57886, 57886, 57886, 57886, 59367, 57886, 57886, 58833, 57886, 57886, 57886, 57886, 57886, 58840, 57886, 57886, 57886, 58847, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58865, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58919, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60042, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 3370, 57886, 57886, 60717, 0, 0, 0, 0, 0, 57936, 57936, 57936, 59037, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1796, 0, 0, 0, 0, 0, 0, 0, 1803, 0, 1805, 0, 0, 0, 1807, 0, 739, 0, 0, 0, 0, 1838, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1850, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1836, 1924, 521, 521, 521, 521, 521, 521, 521, 521, 1933, 521, 521, 521, 521, 521, 521, 1942, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1952, 1954, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59861, 57886, 57886, 57886, 57886, 57886, 57886, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59328, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61033, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59428, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58397, 57936, 57936, 57936, 57936, 57936, 57936, 58430, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59572, 57936, 57936, 57936, 57936, 57936, 57936, 59581, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59592, 59594, 57936, 57936, 57936, 57936, 521, 521, 521, 0, 0, 2472, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59885, 57886, 57886, 57886, 57886, 59889, 57886, 57886, 57886, 2329, 0, 0, 0, 0, 0, 0, 0, 0, 2337, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3128, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 2465, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 59824, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59836, 57886, 57886, 57886, 57886, 57886, 57886, 61492, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61500, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59583, 59584, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 2255, 521, 59925, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60358, 59953, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59972, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59935, 57909, 59937, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60660, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60671, 57936, 60008, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59598, 521, 521, 60036, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60055, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 4132, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 2769, 0, 0, 2772, 0, 0, 0, 0, 0, 0, 2776, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2787, 0, 0, 0, 0, 0, 0, 0, 394, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 319488, 319488, 0, 0, 0, 0, 0, 0, 2795, 0, 0, 0, 0, 2797, 0, 0, 0, 0, 0, 0, 0, 2801, 2802, 0, 0, 2805, 0, 0, 2808, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1161, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 315, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2818, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2828, 0, 0, 0, 0, 521, 2832, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2878, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1356, 521, 521, 521, 1359, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2873, 521, 521, 521, 521, 521, 521, 2880, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2888, 521, 521, 521, 2891, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60253, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61493, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61501, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60921, 57936, 60923, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60930, 57936, 57936, 60932, 57936, 57936, 57936, 57936, 57936, 0, 0, 57909, 60308, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60331, 57936, 57936, 60407, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60415, 57936, 57936, 57936, 57936, 57936, 57936, 60422, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60431, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59574, 57936, 57936, 57936, 59580, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59590, 57936, 57936, 57936, 57936, 59596, 57936, 57936, 521, 521, 521, 0, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59864, 57886, 57886, 57886, 57936, 60434, 57936, 57936, 57936, 57936, 57936, 57936, 3094, 521, 521, 521, 521, 60441, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 3102, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 3646, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3658, 521, 521, 521, 3112, 0, 0, 0, 0, 0, 0, 0, 3116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3130, 3131, 0, 0, 0, 0, 0, 0, 0, 3143, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 333, 334, 335, 0, 0, 0, 0, 0, 3211, 521, 521, 521, 521, 521, 521, 521, 3215, 521, 521, 521, 521, 521, 0, 0, 57886, 57886, 57886, 60567, 57886, 57886, 57886, 57886, 57886, 60572, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61246, 57886, 57886, 57886, 61249, 57909, 57909, 57909, 57909, 61253, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61262, 57909, 57909, 57909, 61265, 60601, 57886, 60603, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60608, 57886, 57886, 57886, 57886, 57886, 0, 0, 57909, 57909, 57909, 60616, 57909, 57909, 57909, 57909, 57909, 60621, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60654, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61086, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 60650, 57909, 60652, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60657, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 60665, 57936, 57936, 57936, 57936, 57936, 60670, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60041, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60054, 57936, 57936, 57936, 57936, 57936, 60058, 60059, 60060, 57936, 60696, 57936, 57936, 57936, 60699, 57936, 60701, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60706, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 3374, 0, 0, 3377, 3378, 521, 521, 521, 521, 521, 521, 3462, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 60822, 57886, 57886, 57886, 57886, 60826, 57886, 57886, 57886, 57886, 57886, 58835, 57886, 57886, 57886, 57886, 57886, 57886, 58846, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58862, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58394, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 58412, 57936, 58421, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 4085, 521, 4087, 521, 521, 521, 57886, 57886, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60916, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60931, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 3608, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1194, 0, 1196, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3619, 3620, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3633, 0, 0, 0, 0, 0, 0, 0, 0, 1793, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60825, 57886, 57886, 57886, 57886, 521, 521, 3787, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3798, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 61149, 57886, 57886, 57886, 57886, 57886, 58836, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58861, 57909, 57909, 57909, 58870, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61198, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 3777, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 4022, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 61379, 0, 521, 521, 521, 521, 521, 521, 521, 521, 3955, 521, 3957, 3958, 521, 3960, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61314, 57886, 61316, 61317, 57886, 61319, 57886, 61321, 61488, 57886, 61489, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 61496, 57909, 61497, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 61504, 57936, 61505, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58961, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59019, 57936, 57936, 59023, 57936, 57936, 57936, 57936, 57936, 59030, 0, 0, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 0, 521, 521, 57886, 57886, 57909, 57909, 57936, 57936, 4224, 61569, 61570, 61571, 521, 521, 521, 521, 521, 521, 521, 1332, 1339, 521, 521, 521, 521, 521, 521, 521, 521, 1352, 521, 1354, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2422, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 57886, 60566, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58307, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57896, 57896, 57896, 57896, 57896, 57896, 57896, 57919, 57919, 57896, 57896, 57946, 57896, 57896, 57896, 57896, 57896, 57896, 57896, 57946, 57946, 57896, 57896, 57896, 57896, 57946, 57946, 57896, 530, 57896, 57896, 57896, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2312, 0, 0, 0, 2315, 0, 0, 0, 0, 0, 2321, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57909, 58909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 1705, 1706, 0, 0, 0, 1712, 1713, 0, 0, 0, 0, 0, 0, 0, 0, 687, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 383, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 339, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2366, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, 405, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 405, 0, 0, 0, 0, 0, 0, 0, 383, 0, 139264, 147456, 0, 405, 0, 0, 405, 0, 0, 0, 431, 131072, 0, 431, 431, 0, 0, 431, 0, 445, 431, 0, 431, 471, 471, 471, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 484, 531, 57897, 531, 57897, 531, 531, 57897, 531, 531, 57920, 57897, 531, 531, 57897, 57897, 57897, 57920, 57897, 57897, 57897, 57897, 57897, 57897, 57897, 57920, 57920, 57897, 57897, 57947, 57897, 57897, 57897, 57897, 57897, 57897, 57897, 57947, 57947, 57897, 57897, 57897, 57897, 57947, 57947, 57897, 531, 57897, 57897, 57897, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2775, 0, 0, 0, 0, 0, 2780, 0, 2782, 2783, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1157, 0, 0, 0, 0, 0, 0, 0, 1159, 0, 0, 0, 0, 0, 0, 1266, 0, 0, 0, 0, 1271, 654, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 654, 0, 654, 0, 0, 0, 0, 813, 0, 0, 0, 654, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 3645, 521, 521, 521, 3648, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3656, 521, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 733, 654, 0, 0, 521, 829, 521, 521, 521, 844, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 885, 521, 521, 521, 521, 57886, 57886, 58247, 57886, 57886, 57886, 58263, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58304, 57886, 57886, 57886, 57886, 0, 57909, 57909, 58323, 57909, 57909, 57909, 58339, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59987, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 59996, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60391, 57936, 60393, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60022, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60029, 57936, 60031, 57936, 60034, 57936, 57936, 57909, 57909, 57909, 57909, 57909, 58380, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58398, 57936, 57936, 57936, 58414, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60390, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60710, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 58455, 57936, 57936, 57936, 57936, 521, 521, 521, 885, 521, 521, 0, 57886, 57886, 57886, 58304, 57886, 57886, 293, 1138, 0, 0, 1142, 0, 0, 1147, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3888, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58841, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60639, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59965, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 1154, 1155, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3133, 0, 0, 0, 0, 0, 0, 1155, 0, 0, 0, 0, 0, 0, 1280, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 760, 0, 0, 763, 0, 0, 767, 0, 0, 0, 0, 521, 521, 521, 58754, 901, 57886, 58757, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58771, 58778, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58791, 57886, 58793, 57886, 57886, 57886, 57886, 57886, 60831, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60849, 57886, 60851, 57886, 57886, 57886, 57886, 57886, 57886, 58278, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58354, 57909, 57909, 58908, 57909, 58910, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58923, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58938, 57909, 57909, 57909, 0, 57886, 57936, 58946, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60068, 57936, 57936, 60071, 60072, 57936, 2404, 521, 2731, 521, 521, 59835, 57886, 60080, 57886, 57886, 2739, 2266, 0, 2740, 2269, 0, 0, 0, 0, 0, 0, 4014, 0, 4016, 0, 521, 521, 521, 521, 521, 4021, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 61378, 57886, 57936, 59033, 57936, 57936, 57936, 521, 1332, 521, 1389, 521, 521, 58771, 57886, 57886, 58828, 57886, 57886, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3146, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3156, 0, 0, 0, 0, 3161, 0, 0, 0, 3163, 0, 1724, 1725, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2342912, 0, 0, 0, 521, 521, 521, 521, 521, 521, 1930, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1957, 521, 58754, 1961, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59321, 59322, 57886, 57886, 57886, 57886, 59329, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 61391, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 61405, 57936, 57936, 50657, 2061, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59421, 59422, 57909, 57909, 57909, 57909, 59429, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 741, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59520, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 57909, 59473, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59501, 57909, 57886, 57886, 57886, 57886, 57886, 60832, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60847, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58843, 57886, 57886, 57886, 50657, 58754, 977, 57909, 58852, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58866, 58873, 57936, 57936, 57936, 57936, 57936, 59540, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59560, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2800, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2809, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57936, 57936, 57936, 59569, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59597, 57936, 521, 521, 521, 0, 2895, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59359, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2330, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2346, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2397, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61162, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59866, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59878, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59884, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59890, 57886, 57886, 57886, 57886, 57886, 61030, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61036, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 61393, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 61407, 57909, 57909, 57909, 57909, 59955, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59967, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59973, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60366, 57909, 57909, 57909, 60369, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 60373, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 4083, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57909, 57909, 59979, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60430, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60038, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60050, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60056, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1149, 0, 0, 57936, 57936, 60062, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3109, 0, 0, 60258, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59865, 3164, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 3180, 521, 521, 521, 521, 521, 521, 3188, 521, 521, 521, 521, 521, 521, 521, 1333, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2858, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57909, 57909, 60628, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61070, 57909, 57909, 57936, 57936, 57936, 60677, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59027, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61099, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3171, 0, 0, 0, 521, 3175, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 2472, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59349, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61039, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 57886, 57886, 61441, 57886, 61443, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61454, 57909, 61456, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 3607, 0, 3609, 0, 0, 0, 3613, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1733, 0, 0, 0, 1736, 0, 0, 1739, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 335872, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 335872, 0, 0, 61467, 57936, 61469, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 4134, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 61485, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59846, 57886, 59848, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60273, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 388, 340, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2351104, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 441, 0, 0, 0, 456, 472, 472, 472, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 505, 532, 57898, 532, 57898, 532, 532, 57898, 532, 532, 57921, 57898, 532, 532, 57898, 57898, 57898, 57921, 57898, 57898, 57898, 57898, 57898, 57898, 57898, 57921, 57921, 57898, 57898, 57948, 57898, 57898, 57898, 57898, 57898, 57898, 57898, 57948, 57948, 57898, 57898, 57898, 57898, 57948, 57948, 57898, 532, 57898, 57898, 57898, 1, 24578, 3, 155941, 156275, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3410, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 212992, 0, 0, 0, 0, 0, 212992, 212992, 212992, 212992, 212992, 655, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 655, 0, 655, 0, 0, 0, 0, 0, 0, 0, 0, 655, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 58264, 57886, 57886, 58280, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 58340, 57909, 57909, 58356, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59444, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59464, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58921, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 1705, 0, 0, 0, 0, 1712, 0, 0, 0, 0, 0, 0, 0, 1722, 0, 1241, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1293, 0, 0, 0, 0, 0, 1299, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1315, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1890, 521, 521, 521, 521, 521, 521, 521, 521, 1372, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1391, 521, 521, 521, 521, 521, 1399, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 59819, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59357, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58772, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58848, 50657, 58754, 977, 58851, 57909, 57909, 57909, 57909, 57909, 58858, 57909, 57909, 57909, 57909, 58864, 57909, 57909, 57909, 58830, 57886, 57886, 57886, 57886, 57886, 58838, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58867, 57909, 57909, 57909, 57909, 57909, 57909, 60631, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60645, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59985, 57909, 57909, 59988, 59989, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60005, 57936, 0, 0, 1755, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 338, 339, 0, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59323, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59334, 57886, 57886, 57886, 57886, 57886, 58837, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61058, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61064, 57909, 61066, 57909, 57909, 57909, 57909, 57909, 57909, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59423, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59434, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61178, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61191, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 1705, 0, 0, 0, 0, 1712, 0, 0, 0, 0, 0, 0, 0, 0, 349, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59541, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59552, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61279, 57936, 57936, 521, 57886, 0, 0, 0, 3940, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 2282, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2298, 2299, 0, 0, 0, 0, 0, 0, 0, 3382, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 0, 0, 0, 2355, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2328, 521, 2413, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2866, 57886, 57886, 57886, 57886, 59844, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58824, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 59928, 57909, 57909, 57909, 57909, 59933, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60011, 57936, 57936, 57936, 57936, 60016, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58985, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 3380, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4284416, 0, 0, 57886, 60829, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59366, 57886, 57936, 57936, 57936, 60913, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59562, 57936, 57936, 57936, 0, 521, 521, 521, 521, 3951, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 61310, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59875, 57886, 57886, 57886, 57886, 59880, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58859, 57909, 57909, 57909, 58863, 57909, 57909, 58874, 57909, 57909, 57909, 57909, 61326, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 61342, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59004, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60689, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61508, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 521, 1333, 521, 521, 1698, 521, 58772, 57886, 57886, 57886, 59047, 57886, 1138, 0, 0, 1708, 0, 0, 0, 0, 1715, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3883, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59344, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59364, 57886, 57886, 57886, 341, 342, 343, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 341, 295, 0, 0, 0, 0, 0, 4013, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 4027, 521, 521, 4029, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59376, 57886, 57886, 57886, 57886, 57886, 57886, 59385, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59396, 59398, 57886, 57886, 57886, 57886, 0, 0, 0, 389, 390, 392, 342, 0, 0, 0, 0, 0, 0, 341, 0, 0, 0, 0, 341, 0, 0, 0, 342, 0, 0, 0, 0, 0, 0, 0, 0, 0, 639, 748, 749, 750, 0, 0, 0, 0, 0, 756, 757, 0, 0, 0, 0, 0, 0, 0, 0, 769, 770, 0, 772, 0, 0, 0, 389, 0, 0, 0, 0, 0, 0, 342, 0, 0, 0, 389, 0, 0, 0, 0, 0, 342, 389, 0, 0, 0, 139264, 147456, 0, 0, 0, 422, 0, 0, 0, 0, 0, 245760, 0, 0, 0, 245760, 0, 0, 245760, 245760, 245760, 0, 0, 0, 0, 0, 245760, 0, 245760, 245760, 0, 0, 0, 245760, 245760, 0, 0, 245760, 0, 0, 0, 0, 131072, 0, 0, 0, 341, 0, 0, 0, 446, 0, 341, 0, 473, 473, 473, 473, 489, 489, 489, 489, 489, 489, 489, 489, 489, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 473, 533, 57899, 533, 57899, 533, 533, 57899, 533, 533, 57922, 57899, 533, 533, 57899, 57899, 57899, 57922, 57899, 57899, 57899, 57899, 57899, 57899, 57899, 57922, 57922, 57899, 57935, 57949, 57935, 57935, 57935, 57935, 57935, 57935, 57935, 57949, 57949, 57935, 57935, 57935, 57935, 57949, 57949, 57935, 533, 57899, 57899, 57899, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 344064, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 344064, 0, 0, 0, 710, 0, 0, 0, 0, 0, 0, 0, 718, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 331, 332, 0, 0, 0, 0, 0, 0, 0, 0, 802, 0, 660, 0, 779, 0, 0, 0, 0, 0, 779, 802, 0, 802, 800, 0, 0, 0, 814, 0, 0, 0, 656, 817, 0, 779, 0, 0, 0, 0, 0, 823, 0, 0, 0, 0, 783, 656, 827, 0, 521, 830, 521, 521, 521, 846, 521, 521, 862, 521, 521, 521, 521, 876, 521, 521, 521, 521, 894, 521, 521, 57886, 57886, 58248, 57886, 57886, 57886, 58265, 57886, 57886, 58281, 57886, 57886, 57886, 57886, 58295, 57886, 57886, 57886, 57886, 58313, 57886, 57886, 0, 57909, 57909, 58324, 57909, 57909, 57909, 58341, 57909, 57909, 58357, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59476, 57909, 57909, 57909, 57909, 57909, 57909, 59485, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59496, 59498, 57909, 57909, 57909, 57909, 57886, 57909, 57909, 58371, 57909, 57909, 57909, 57909, 58389, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58399, 57936, 57936, 57936, 58416, 57936, 57936, 58432, 57936, 57936, 57936, 57936, 58446, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60412, 57936, 57936, 60416, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60425, 57936, 57936, 57936, 60428, 60429, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 0, 1143, 0, 0, 1148, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3881, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58802, 57886, 57886, 57886, 58806, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 2962, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60623, 57909, 57936, 57936, 58464, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 301, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 1816, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 740, 0, 0, 0, 0, 1274, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1286, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 540, 57906, 540, 57906, 540, 540, 57906, 540, 540, 57929, 57906, 540, 540, 57906, 57906, 57906, 57929, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58773, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59348, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59361, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58797, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58821, 57886, 57886, 57886, 57886, 57886, 57886, 59374, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59386, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59397, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61444, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61457, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 3095, 521, 521, 521, 57886, 60442, 57886, 57886, 57886, 0, 0, 3100, 3101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 3776, 0, 0, 0, 0, 3780, 0, 0, 0, 0, 0, 0, 0, 0, 3783, 0, 521, 521, 521, 3785, 0, 0, 0, 0, 1814, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221645, 221645, 221645, 221645, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59316, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59327, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59345, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59356, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59876, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59416, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59427, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58429, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 2440, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2459, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60252, 57886, 57886, 57886, 57886, 57886, 60257, 59892, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 59910, 57909, 59912, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60340, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61060, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59981, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 59993, 57936, 59995, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60686, 60687, 57936, 57936, 57936, 57936, 60690, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60064, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2274, 0, 0, 0, 0, 0, 0, 0, 2820, 0, 0, 0, 0, 2823, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2831, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3961, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61320, 57886, 521, 2842, 521, 521, 2845, 2846, 521, 521, 521, 521, 521, 2851, 521, 2853, 521, 521, 521, 521, 2857, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2863, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60251, 57886, 57886, 60254, 60255, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60878, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59445, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59456, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61336, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61352, 57936, 521, 521, 521, 521, 521, 2871, 521, 521, 521, 521, 521, 521, 2879, 521, 521, 521, 521, 521, 2884, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1904, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1353, 1355, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 60260, 57886, 60262, 57886, 57886, 57886, 57886, 60266, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60272, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60281, 57886, 57886, 57886, 57886, 57886, 59373, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59401, 57886, 57886, 57886, 57886, 57886, 60289, 57886, 57886, 57886, 57886, 57886, 60294, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60330, 57909, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60318, 57909, 57909, 60321, 60322, 57909, 57909, 57909, 57909, 57909, 60327, 57909, 60329, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60336, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60342, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60350, 57909, 57909, 57909, 57909, 57909, 57909, 60357, 57909, 57909, 57909, 60333, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60339, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60348, 57909, 57909, 57909, 57909, 57909, 57909, 60356, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60632, 57909, 57909, 60635, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60646, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60889, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 60906, 57936, 57936, 57936, 57936, 60910, 57909, 57909, 57909, 60361, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61192, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60383, 57936, 57936, 60386, 60387, 57936, 57936, 57936, 57936, 57936, 60392, 57936, 60394, 57936, 57936, 57936, 57936, 60398, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60404, 0, 0, 3139, 0, 0, 0, 0, 0, 0, 0, 3145, 0, 3147, 0, 0, 0, 3150, 0, 0, 3153, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 450560, 450560, 0, 0, 450560, 450560, 450560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1799, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3165, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3174, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2882, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2892, 521, 521, 521, 521, 521, 3192, 521, 521, 3195, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3205, 521, 521, 521, 521, 521, 521, 521, 521, 2443, 521, 521, 521, 521, 2448, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1906, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1940, 521, 521, 521, 521, 521, 521, 1947, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3214, 521, 521, 3217, 521, 521, 3220, 0, 0, 60565, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58302, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 57886, 57886, 60583, 57886, 57886, 60586, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60597, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59871, 57886, 57886, 57886, 57886, 57886, 59877, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 2962, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 3431, 0, 0, 521, 521, 3436, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3453, 521, 3455, 521, 521, 521, 521, 521, 521, 521, 1334, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1358, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2419, 521, 521, 521, 521, 521, 521, 521, 521, 2426, 521, 2428, 521, 2431, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2444, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1392, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3461, 521, 521, 3463, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 60820, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59378, 57886, 57886, 57886, 59384, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59394, 57886, 57886, 57886, 57886, 59400, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 60888, 57909, 57909, 60890, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 60904, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 3601, 521, 57886, 60948, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 306, 0, 0, 0, 0, 0, 0, 306, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 3664, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61020, 61021, 57886, 57886, 57886, 57886, 61025, 61026, 57909, 57909, 61049, 61050, 57909, 57909, 57909, 57909, 61054, 61055, 57909, 57909, 57909, 57909, 57909, 61059, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61065, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59960, 57909, 57909, 57909, 57909, 57909, 59966, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60341, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60353, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 61094, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 3764, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 2394, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2406, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3792, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59849, 57886, 57886, 57886, 57886, 57886, 57886, 59854, 57886, 59856, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60267, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61163, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 61154, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61173, 57886, 57886, 57886, 57886, 61242, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61258, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 61075, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61087, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 4137, 521, 4138, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 0, 521, 521, 3949, 521, 521, 521, 521, 3954, 521, 521, 521, 521, 3959, 521, 521, 57886, 57886, 61308, 57886, 57886, 57886, 57886, 61313, 57886, 57886, 57886, 57886, 61318, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60873, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 58418, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58969, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59012, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59029, 57936, 57909, 57909, 61324, 57909, 57909, 57909, 57909, 61329, 57909, 57909, 57909, 57909, 61334, 57909, 57909, 57909, 57936, 57936, 61340, 57936, 57936, 57936, 57936, 61345, 57936, 57936, 57936, 57936, 61350, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58962, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58986, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 3606, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1740, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 61384, 57886, 57886, 61386, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61398, 57909, 57909, 61400, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 3600, 521, 521, 60947, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3617, 3618, 0, 0, 57936, 57936, 57936, 57936, 61412, 57936, 57936, 61414, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60872, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59449, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58932, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 61533, 57936, 57936, 57936, 0, 0, 0, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 521, 4195, 521, 521, 521, 521, 57886, 61543, 57886, 57886, 57886, 57886, 57909, 61547, 57909, 57909, 57909, 57909, 57936, 61551, 57936, 57936, 57936, 57936, 0, 0, 0, 521, 521, 4196, 4197, 521, 521, 57886, 57886, 61544, 61545, 57886, 57886, 57909, 57909, 61548, 61549, 57909, 57909, 57936, 57936, 61552, 61553, 57936, 57936, 0, 57886, 57909, 57936, 4232, 61577, 61578, 61579, 521, 57886, 57909, 57936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1261, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 344, 345, 346, 347, 348, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 0, 0, 0, 0, 245760, 245760, 245760, 245760, 245760, 245760, 0, 0, 0, 0, 0, 0, 0, 245760, 245760, 245760, 0, 0, 0, 0, 139264, 147456, 245760, 245760, 0, 0, 245760, 0, 0, 0, 245760, 245760, 0, 0, 0, 0, 0, 0, 245760, 0, 0, 0, 0, 0, 0, 245760, 0, 0, 245760, 0, 0, 245760, 0, 0, 245760, 0, 245760, 245760, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 737, 0, 0, 0, 348, 347, 131072, 346, 347, 347, 348, 346, 347, 0, 346, 347, 450, 457, 474, 474, 474, 485, 485, 485, 491, 485, 485, 491, 491, 485, 491, 506, 506, 506, 506, 506, 506, 506, 506, 506, 506, 506, 506, 506, 506, 506, 534, 57900, 534, 57900, 534, 534, 57900, 534, 534, 57923, 57900, 534, 534, 57900, 57900, 57900, 57923, 57900, 57900, 57900, 57900, 57900, 57900, 57900, 57923, 57923, 57900, 57900, 57950, 57900, 57900, 57900, 57900, 57900, 57900, 57900, 57950, 57950, 57900, 57900, 57900, 57900, 57950, 57950, 57900, 534, 57900, 57900, 57900, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 639, 0, 0, 0, 0, 644, 645, 646, 647, 648, 649, 650, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 665, 666, 0, 668, 669, 0, 0, 0, 0, 0, 675, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1881, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1375, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1914, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 709, 0, 0, 712, 0, 714, 0, 716, 0, 0, 0, 0, 0, 0, 0, 0, 0, 726, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 499712, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 301, 0, 302, 305, 0, 306, 4857856, 4874240, 0, 0, 4923392, 0, 0, 0, 0, 757, 0, 0, 778, 0, 0, 0, 0, 0, 0, 0, 0, 0, 785, 0, 0, 0, 0, 0, 796, 0, 0, 685, 0, 0, 0, 757, 0, 0, 0, 0, 0, 278528, 278528, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1176, 0, 0, 0, 0, 0, 685, 816, 816, 0, 0, 0, 0, 0, 521, 521, 836, 840, 843, 521, 852, 521, 521, 521, 868, 870, 873, 521, 521, 521, 886, 890, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60871, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58892, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60372, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58255, 58259, 58262, 57886, 58271, 57886, 57886, 57886, 58287, 58289, 58292, 57886, 57886, 57886, 58305, 58309, 57886, 57886, 57886, 0, 57909, 57909, 57909, 58331, 58335, 58338, 57909, 58347, 57909, 57909, 57909, 58363, 58365, 58368, 57909, 57909, 57909, 58381, 58385, 57909, 57909, 57909, 0, 0, 0, 0, 58396, 57936, 57936, 57936, 58406, 58410, 58413, 57936, 58422, 57936, 57936, 57936, 58438, 58440, 58443, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58963, 57936, 57936, 57936, 57936, 58973, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58989, 57936, 58456, 58460, 57936, 57936, 57936, 836, 1127, 521, 886, 890, 1131, 0, 58476, 58255, 57886, 58305, 58309, 58481, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 540672, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 540672, 0, 0, 1366, 521, 521, 1370, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1381, 521, 521, 1388, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1402, 521, 521, 521, 0, 2895, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60248, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60256, 57886, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58795, 57886, 57886, 57886, 58798, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58805, 57886, 57886, 58809, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58820, 57886, 57886, 58827, 57886, 57886, 57886, 57886, 57886, 59897, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59918, 57909, 57909, 59921, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58885, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58898, 57909, 57909, 57909, 57909, 58903, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59480, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57936, 57936, 58994, 57936, 57936, 58998, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59010, 57936, 57936, 59017, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59031, 521, 1894, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1903, 521, 521, 521, 1907, 521, 521, 1912, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2447, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2458, 521, 521, 521, 521, 521, 58754, 0, 57886, 59308, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59315, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61164, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59337, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59346, 57886, 57886, 57886, 59350, 57886, 57886, 59355, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61160, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 61168, 57909, 57909, 57909, 57909, 57909, 50657, 0, 57909, 59408, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59415, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59437, 57936, 59504, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59511, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59533, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60681, 57936, 57936, 60684, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60695, 57936, 0, 0, 0, 0, 2305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 352256, 352256, 352256, 352256, 521, 521, 521, 2438, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2865, 521, 2794, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2381, 2894, 521, 521, 0, 0, 0, 2896, 0, 1961, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59393, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2061, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59974, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 60437, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1727, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 3789, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 61146, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61151, 57886, 61239, 57886, 57886, 57886, 57886, 57886, 61245, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 61251, 57909, 57909, 57909, 57909, 61255, 57909, 57909, 57909, 57909, 57909, 61261, 57909, 57909, 57909, 57909, 57936, 0, 0, 4166, 0, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59577, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 3766, 0, 0, 0, 0, 0, 3769, 57936, 57936, 61267, 57936, 57936, 57936, 57936, 61271, 57936, 57936, 57936, 57936, 57936, 61277, 57936, 57936, 57936, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1880, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1891, 521, 0, 521, 521, 521, 521, 521, 3952, 521, 521, 521, 3956, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 61311, 57886, 57886, 57886, 61315, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61387, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61401, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60043, 57936, 57936, 57936, 57936, 57936, 60049, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 57909, 57909, 57909, 57909, 57909, 61327, 57909, 57909, 57909, 61331, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 61343, 57936, 57936, 57936, 61347, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61102, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 728, 0, 788, 0, 0, 0, 0, 0, 0, 0, 0, 788, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 0, 521, 521, 57886, 57886, 57909, 57909, 57936, 57936, 521, 57886, 57909, 57936, 4228, 61573, 61574, 61575, 521, 57886, 57909, 57936, 521, 57886, 57909, 57936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1742, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 391, 0, 0, 0, 395, 391, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 363, 364, 365, 366, 0, 0, 367, 0, 295, 0, 0, 349, 0, 407, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 407, 0, 0, 0, 0, 0, 0, 407, 0, 349, 0, 139264, 147456, 0, 0, 0, 0, 0, 0, 0, 3643, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2887, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 442, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 500, 507, 507, 507, 507, 507, 507, 507, 507, 507, 507, 507, 507, 507, 507, 507, 535, 57901, 535, 57901, 535, 535, 57901, 535, 535, 57924, 57901, 535, 535, 57901, 57901, 57901, 57924, 57901, 57901, 57901, 57901, 57901, 57901, 57901, 57924, 57924, 57901, 57901, 57951, 57901, 57901, 57901, 57901, 57901, 57901, 57901, 57951, 57951, 57901, 57901, 57901, 57901, 57951, 57951, 57901, 616, 57901, 57967, 57967, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2351104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1228, 0, 0, 0, 0, 0, 0, 0, 0, 1237, 0, 0, 0, 672, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2300, 0, 57909, 57909, 58372, 57909, 57909, 57909, 57909, 58390, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58400, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58447, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60917, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60925, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 3864, 0, 0, 0, 0, 0, 3627, 0, 0, 57936, 57936, 58465, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2311, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2325, 0, 0, 0, 0, 1242, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 1203, 1161, 0, 0, 0, 0, 0, 0, 1273, 1160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 318, 0, 0, 0, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 58760, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58774, 57886, 57886, 57886, 57886, 58784, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59873, 59874, 57886, 57886, 57886, 57886, 57886, 57886, 59881, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58929, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 58879, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58895, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60656, 57909, 57909, 60659, 57909, 57909, 60662, 60663, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 1756, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 337, 0, 0, 0, 1785, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1800, 0, 0, 0, 0, 0, 0, 0, 1243, 0, 0, 0, 0, 0, 0, 0, 0, 2286, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1173, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 2418, 521, 521, 521, 521, 521, 521, 2423, 521, 2425, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1379, 521, 521, 521, 521, 521, 521, 521, 1393, 521, 521, 521, 521, 521, 521, 521, 521, 1405, 521, 521, 2869, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2435, 2436, 57936, 57936, 57936, 57936, 57936, 57936, 60411, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59529, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 3432, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1398, 521, 521, 521, 521, 521, 0, 3872, 0, 0, 0, 0, 0, 521, 3875, 521, 521, 3877, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 61234, 57886, 57886, 61236, 57886, 57886, 57886, 57886, 57886, 60263, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60279, 57886, 57886, 57886, 57886, 57886, 61266, 57936, 57936, 61268, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 3944, 0, 0, 0, 0, 0, 417792, 0, 417792, 0, 0, 0, 0, 309, 0, 0, 0, 0, 0, 417792, 0, 417792, 0, 0, 0, 0, 139264, 147456, 417792, 0, 0, 0, 417792, 0, 0, 0, 0, 417792, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 417792, 0, 0, 417792, 0, 0, 417792, 0, 417792, 418100, 3946, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59383, 57886, 57886, 57886, 57886, 57886, 57886, 59391, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 787, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 787, 0, 787, 0, 0, 0, 0, 0, 0, 0, 0, 787, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1160, 0, 0, 0, 0, 1165, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 460, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2335231, 2335197, 2335231, 2335231, 57886, 57886, 57886, 58266, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 58342, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60891, 57909, 60893, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60019, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60025, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 58754, 1962, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 2557, 2962, 0, 0, 50657, 2062, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61068, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 60408, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59021, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57886, 61028, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 350, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 345, 0, 0, 0, 0, 0, 352, 350, 131072, 0, 350, 350, 352, 0, 350, 0, 0, 350, 352, 350, 0, 0, 0, 350, 350, 350, 350, 350, 350, 350, 350, 498, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 350, 536, 57902, 536, 57902, 536, 536, 57902, 536, 536, 57925, 57902, 536, 536, 57902, 57902, 57902, 57925, 57902, 57902, 57902, 57902, 57902, 57902, 57902, 57925, 57925, 57902, 57902, 57952, 57902, 57902, 57902, 57902, 57902, 57902, 57902, 57952, 57952, 57902, 57902, 57902, 57902, 57952, 57952, 57902, 536, 57902, 57902, 57902, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2751, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 791, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 674, 0, 0, 0, 0, 0, 0, 673, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 798, 799, 0, 0, 0, 0, 0, 0, 0, 521, 521, 837, 521, 521, 521, 853, 857, 521, 521, 521, 521, 521, 878, 880, 521, 521, 891, 521, 521, 521, 57886, 57886, 58250, 0, 751, 0, 0, 804, 0, 0, 0, 0, 0, 804, 0, 657, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 819, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 3879, 521, 521, 521, 521, 521, 521, 3885, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 61238, 58256, 57886, 57886, 57886, 58272, 58276, 57886, 57886, 57886, 57886, 57886, 58297, 58299, 57886, 57886, 58310, 57886, 57886, 57886, 0, 57909, 57909, 58326, 58332, 57909, 57909, 57909, 58348, 58352, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61330, 57909, 61332, 61333, 57909, 61335, 57909, 61337, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61346, 57936, 61348, 61349, 57936, 61351, 57936, 61353, 57909, 57909, 58373, 58375, 57909, 57909, 58386, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58401, 58407, 57936, 57936, 57936, 58423, 58427, 57936, 57936, 57936, 57936, 57936, 58448, 58450, 57936, 0, 4165, 0, 4167, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 521, 1695, 521, 1697, 521, 521, 59044, 57886, 57886, 59046, 57886, 57886, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1720, 0, 0, 57936, 58461, 57936, 57936, 57936, 837, 521, 880, 521, 891, 521, 0, 57886, 58256, 58299, 57886, 58310, 57886, 155941, 1138, 0, 301, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 2309, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3396, 0, 0, 0, 0, 0, 0, 0, 1208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1222, 0, 1224, 0, 0, 0, 0, 1229, 0, 0, 0, 0, 1234, 0, 0, 0, 0, 0, 0, 0, 3874, 521, 521, 521, 521, 3878, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3887, 521, 521, 61233, 57886, 57886, 57886, 57886, 61237, 57886, 1406, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 58761, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58792, 58794, 57886, 57886, 57886, 57886, 58273, 58277, 58283, 57886, 58288, 57886, 57886, 57886, 57886, 57886, 58306, 57886, 57886, 57886, 57886, 0, 57909, 57909, 58328, 57909, 57909, 57909, 57909, 58349, 58353, 58359, 57909, 58364, 57886, 58832, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58844, 58845, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 58856, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 58415, 57936, 57936, 58431, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 57909, 57909, 58913, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58927, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58939, 58940, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59512, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59523, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60021, 57936, 57936, 57936, 57936, 57936, 57936, 60026, 57936, 60028, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58950, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58981, 58983, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61202, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3781, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 57936, 59034, 59035, 57936, 57936, 521, 521, 1696, 521, 521, 1699, 57886, 57886, 59045, 57886, 57886, 59048, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2774, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 730, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1789, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 507904, 507904, 507904, 507904, 0, 1773, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1855, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2825, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 2837, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1895, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1955, 521, 521, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59313, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58813, 57886, 58815, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58828, 57886, 57886, 57886, 59338, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59399, 57886, 57886, 57886, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59413, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60909, 57936, 57936, 57909, 59438, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59509, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59534, 0, 0, 0, 2332, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 0, 0, 0, 0, 0, 2358, 0, 2360, 2361, 2362, 0, 2364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2372, 0, 0, 0, 0, 2377, 2378, 0, 0, 0, 0, 0, 0, 0, 49716, 49716, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 327680, 327680, 327680, 327680, 2382, 0, 0, 0, 0, 0, 0, 0, 2388, 521, 521, 521, 521, 521, 521, 2395, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1905, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1918, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2439, 521, 521, 521, 521, 521, 2445, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3801, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 2745, 2746, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2359296, 367, 0, 0, 0, 521, 521, 2843, 521, 521, 521, 521, 521, 2848, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2864, 521, 521, 521, 0, 2895, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60247, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59487, 59488, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57936, 57936, 57936, 57936, 57936, 60384, 57936, 57936, 57936, 57936, 57936, 60389, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59016, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60405, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60033, 57936, 57936, 57936, 57936, 57936, 57936, 61269, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61278, 57936, 57936, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3446, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1937, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1385, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57936, 61534, 57936, 57936, 4192, 0, 4194, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 0, 4193, 0, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 0, 4211, 0, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 0, 521, 521, 57886, 57886, 57909, 57909, 57936, 57936, 521, 57886, 57909, 57936, 521, 521, 521, 521, 521, 521, 521, 1335, 521, 521, 521, 521, 1345, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1361, 521, 521, 521, 0, 0, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60246, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 59911, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58926, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 370, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 378, 0, 0, 0, 0, 370, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4825088, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 5177344, 4358144, 4358144, 4358144, 0, 0, 0, 0, 0, 0, 302, 0, 0, 0, 302, 0, 0, 306, 0, 0, 0, 306, 0, 0, 0, 4931584, 0, 0, 0, 0, 0, 0, 0, 0, 747, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 771, 0, 387, 0, 353, 0, 0, 0, 0, 0, 396, 397, 0, 398, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 398, 0, 0, 403, 0, 0, 0, 0, 0, 0, 0, 557056, 557056, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3129, 0, 0, 0, 0, 0, 0, 0, 370, 378, 406, 0, 0, 0, 370, 0, 0, 353, 0, 0, 0, 370, 0, 409, 411, 0, 370, 398, 0, 0, 370, 378, 0, 139264, 147456, 398, 409, 0, 0, 409, 0, 0, 0, 432, 131072, 0, 432, 432, 0, 0, 432, 0, 411, 432, 0, 458, 0, 0, 0, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 508, 508, 508, 508, 520, 508, 508, 508, 520, 508, 508, 508, 508, 508, 508, 537, 57903, 537, 57903, 537, 537, 57903, 537, 537, 57926, 57903, 537, 537, 57903, 57903, 57903, 57926, 57903, 57903, 57903, 57903, 57903, 57903, 57903, 57926, 57926, 57903, 57903, 57953, 57903, 57903, 57903, 57903, 57903, 57903, 57903, 57953, 57953, 57903, 57903, 57903, 57903, 57953, 57953, 57903, 617, 57903, 57968, 57968, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 636, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4017, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 61374, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 774, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 793, 0, 0, 0, 0, 0, 0, 0, 774, 0, 0, 0, 0, 0, 1276, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1288, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3625, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 305, 0, 0, 0, 0, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 793, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 687, 0, 0, 0, 774, 0, 0, 0, 0, 793, 0, 0, 0, 0, 0, 0, 0, 793, 0, 0, 0, 0, 774, 0, 793, 0, 521, 832, 521, 521, 521, 521, 521, 521, 863, 865, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 58251, 1151, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1164, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2342, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1182, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1207, 1296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1290, 1316, 1317, 0, 1290, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 59822, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 59907, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59915, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 521, 1325, 521, 521, 521, 1329, 521, 521, 1340, 521, 521, 1344, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1363, 521, 521, 521, 0, 2895, 0, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 60245, 57886, 57886, 57886, 57886, 60249, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58294, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59483, 57909, 57909, 57909, 57909, 57909, 57909, 59491, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 521, 1367, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2893, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58764, 57886, 57886, 57886, 58768, 57886, 57886, 58779, 57886, 57886, 58783, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60588, 60589, 57886, 57886, 57886, 57886, 60592, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60598, 57886, 57886, 57886, 57909, 57909, 58878, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58897, 57909, 57909, 57909, 58901, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60367, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59515, 57936, 57936, 57936, 57936, 59521, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59532, 57936, 57936, 57936, 57936, 57936, 57936, 58953, 57936, 57936, 57936, 58957, 57936, 57936, 58968, 57936, 57936, 58972, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58991, 57936, 57936, 57936, 58995, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60399, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 1726, 1727, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 516560, 516560, 516560, 516560, 0, 1786, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1808, 0, 0, 0, 0, 0, 5111808, 0, 0, 0, 0, 0, 5283840, 0, 0, 0, 0, 5472256, 5521408, 0, 0, 0, 0, 5595136, 5709824, 5718016, 0, 5824512, 5865472, 0, 0, 5922816, 0, 0, 6021120, 0, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59324, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60837, 57886, 60839, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60846, 57886, 57886, 60848, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59424, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61181, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60047, 57936, 57936, 57936, 57936, 60052, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 57909, 57909, 57909, 57909, 59442, 59443, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 60907, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59538, 59539, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59556, 57936, 57936, 57936, 57936, 57936, 57936, 59563, 57936, 57936, 521, 521, 521, 59324, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 318, 0, 0, 0, 0, 0, 2384, 0, 0, 2387, 0, 521, 521, 2390, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 60823, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59867, 59868, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59879, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59891, 57909, 57909, 57909, 57909, 57909, 59956, 59957, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59968, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58891, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59457, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59980, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 59992, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3868, 3627, 0, 0, 57936, 57936, 57936, 57936, 57936, 60039, 60040, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60051, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60705, 57936, 57936, 60708, 57936, 57936, 60711, 3368, 521, 521, 60715, 57886, 57886, 0, 0, 0, 0, 0, 57936, 57936, 57936, 60063, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 2732, 2733, 57886, 57886, 57886, 60081, 60082, 0, 0, 1710, 0, 0, 1717, 0, 0, 0, 0, 0, 1728, 1729, 0, 0, 0, 0, 0, 1735, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 360, 361, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 0, 0, 0, 2821, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2827, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2460, 521, 2462, 57886, 60286, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59919, 57909, 57909, 57909, 57909, 57936, 60406, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60418, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59011, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 3194, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3207, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 59818, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59826, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60590, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 57909, 60615, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60648, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60002, 57936, 57936, 57936, 57936, 57936, 60697, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 6152192, 0, 0, 0, 6316032, 0, 196608, 0, 0, 5816320, 6291456, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2754, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57936, 57936, 57936, 57936, 57936, 61097, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 3760, 57886, 57886, 61106, 3763, 0, 0, 0, 0, 3767, 0, 0, 0, 0, 0, 0, 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1167, 0, 0, 0, 0, 1171, 0, 0, 1174, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 3788, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 61147, 57886, 57886, 57886, 61150, 57886, 57886, 57886, 57886, 58274, 57886, 57886, 57886, 57886, 57886, 58293, 57886, 57886, 57886, 57886, 58311, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58350, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59478, 57909, 57909, 57909, 59484, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59494, 57909, 57909, 57909, 57909, 59500, 57909, 57909, 57886, 57886, 57886, 57886, 61241, 57886, 61243, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61257, 57909, 61259, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 61074, 57936, 57936, 57936, 61077, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61085, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59516, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59528, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61470, 57936, 57936, 57936, 0, 4130, 0, 0, 0, 0, 0, 521, 521, 4135, 521, 4136, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 61486, 57886, 61487, 57886, 57886, 57886, 57886, 59340, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59353, 57886, 57886, 57886, 59358, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59914, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60709, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 358, 0, 0, 0, 475, 475, 475, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 509, 509, 513, 513, 513, 513, 509, 513, 513, 513, 509, 513, 513, 513, 513, 513, 513, 538, 57904, 538, 57904, 538, 538, 57904, 538, 538, 57927, 57904, 538, 538, 57904, 57904, 57904, 57927, 57904, 57904, 57904, 57904, 57904, 57904, 57904, 57927, 57927, 57904, 57904, 57954, 57904, 57904, 57904, 57904, 57904, 57904, 57904, 57954, 57954, 57904, 57904, 57904, 57904, 57954, 57954, 57904, 618, 57904, 57969, 57969, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 637, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1288, 0, 521, 521, 1320, 521, 1323, 0, 680, 681, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 0, 0, 0, 702, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 3876, 521, 521, 521, 521, 3880, 521, 521, 521, 521, 521, 3886, 521, 521, 521, 57886, 57886, 57886, 61235, 57886, 57886, 57886, 658, 0, 637, 0, 0, 0, 0, 0, 0, 781, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 790, 0, 795, 0, 0, 0, 0, 0, 0, 637, 0, 0, 781, 521, 833, 521, 521, 521, 521, 854, 858, 864, 521, 869, 521, 521, 521, 521, 521, 887, 521, 521, 521, 521, 57886, 57886, 58252, 0, 790, 0, 795, 0, 781, 0, 807, 0, 0, 0, 0, 807, 0, 0, 0, 0, 0, 637, 0, 0, 0, 0, 0, 0, 0, 0, 781, 0, 0, 0, 0, 0, 0, 1277, 0, 1162, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 670, 0, 0, 0, 0, 0, 0, 0, 0, 57909, 57909, 57909, 57909, 57909, 58382, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58403, 57936, 57936, 57936, 57936, 58424, 58428, 58434, 57936, 58439, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 0, 1142, 0, 0, 1147, 0, 0, 0, 0, 0, 0, 0, 311, 0, 0, 0, 0, 0, 310, 0, 310, 311, 0, 310, 310, 311, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 310, 408, 311, 0, 0, 0, 0, 0, 0, 311, 413, 0, 0, 139264, 147456, 0, 0, 0, 0, 0, 58457, 57936, 57936, 57936, 57936, 521, 521, 521, 887, 521, 521, 0, 57886, 57886, 57886, 58306, 57886, 57886, 155941, 1138, 0, 301, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 2336, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2292, 2293, 0, 2295, 2296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1152, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1169, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1179, 0, 0, 0, 1183, 1184, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 1202, 0, 0, 0, 0, 0, 0, 0, 686, 0, 0, 0, 0, 0, 0, 367, 367, 367, 0, 0, 0, 0, 0, 699, 0, 0, 0, 0, 0, 0, 0, 0, 708, 0, 0, 1243, 0, 0, 0, 0, 0, 0, 1251, 0, 0, 0, 0, 0, 1256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1267, 0, 0, 0, 0, 0, 0, 1301, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 0, 0, 1275, 0, 0, 1152, 0, 0, 0, 1281, 0, 1283, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1291, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 2393, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2405, 521, 521, 521, 521, 521, 521, 0, 1297, 1256, 0, 1281, 1300, 0, 1303, 0, 0, 0, 1183, 0, 0, 0, 0, 1311, 0, 0, 0, 0, 0, 1311, 0, 0, 1202, 1311, 1318, 521, 521, 521, 521, 521, 521, 0, 0, 0, 2473, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61043, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 1324, 521, 521, 521, 521, 1330, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1351, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1364, 521, 521, 521, 0, 2895, 0, 0, 0, 0, 57886, 57886, 57886, 60243, 57886, 60244, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 521, 521, 1369, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1377, 521, 521, 521, 1384, 1386, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2881, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3202, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3208, 521, 521, 521, 521, 1409, 58754, 901, 58756, 57886, 57886, 57886, 57886, 57886, 58763, 57886, 57886, 57886, 57886, 58769, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58790, 57886, 57886, 57886, 57886, 57886, 57886, 59870, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58818, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 58911, 57909, 57909, 57909, 58918, 58920, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58943, 0, 58944, 58945, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59543, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58984, 57936, 57936, 57936, 58987, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58952, 57936, 57936, 57936, 57936, 58958, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58979, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58992, 57936, 57936, 57936, 57936, 58997, 57936, 57936, 57936, 57936, 57936, 59002, 57936, 57936, 57936, 59006, 57936, 57936, 57936, 59013, 59015, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60922, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60395, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59038, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 1138, 0, 0, 0, 1710, 0, 0, 0, 0, 1717, 0, 0, 0, 0, 0, 0, 362, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 734, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1757, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1775, 0, 0, 0, 0, 0, 0, 0, 1783, 1784, 0, 0, 0, 0, 1840, 1841, 0, 0, 0, 1844, 0, 0, 0, 0, 0, 1849, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 581632, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 581632, 0, 581632, 581632, 0, 1862, 0, 1864, 1840, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1876, 521, 521, 521, 521, 1882, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2850, 521, 2852, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2427, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1893, 521, 521, 521, 521, 1897, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1910, 521, 521, 521, 1915, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2849, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2429, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59319, 57886, 57886, 57886, 57886, 59325, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59336, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59419, 57909, 57909, 57909, 57909, 59425, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59436, 57909, 57909, 57909, 57909, 57909, 57909, 60653, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61091, 57936, 57909, 57909, 57909, 59440, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59453, 57909, 57909, 57909, 59458, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59936, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59942, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 59536, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59549, 57936, 57936, 57936, 59554, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 2730, 521, 521, 521, 57886, 60079, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 2257, 521, 521, 59604, 57886, 59606, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2277, 2278, 0, 0, 0, 0, 0, 5210112, 0, 5365760, 0, 5554176, 5570560, 5578752, 0, 5668864, 0, 0, 5791744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6201344, 6242304, 6250496, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3443, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1382, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 0, 0, 2383, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2403, 521, 521, 2407, 521, 521, 521, 2411, 57886, 57886, 59842, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59852, 57886, 57886, 57886, 59855, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60609, 57886, 57886, 57886, 57886, 0, 0, 57909, 57909, 57909, 57909, 57909, 60618, 57909, 60619, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 59894, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 2561, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59923, 57909, 57909, 59927, 57909, 57909, 57909, 59931, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59941, 57909, 57909, 57909, 59944, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61180, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 61186, 57936, 57936, 57936, 61190, 57936, 57936, 57936, 57936, 57936, 59978, 57909, 57909, 57909, 57909, 57909, 59983, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60006, 57936, 57936, 60010, 57936, 57936, 57936, 60014, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60024, 57936, 57936, 57936, 60027, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 4076, 0, 4078, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 60061, 57936, 57936, 57936, 57936, 57936, 60066, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2273, 0, 0, 0, 0, 0, 0, 0, 0, 2743, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2753, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3629, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2819, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2826, 0, 0, 0, 0, 0, 0, 521, 521, 2833, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3465, 3467, 521, 521, 521, 3470, 521, 3472, 3473, 521, 57886, 57886, 57886, 57886, 57886, 57886, 60824, 57886, 57886, 57886, 57886, 57886, 2841, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2856, 521, 521, 521, 521, 2859, 521, 521, 2861, 521, 2862, 521, 521, 521, 521, 521, 521, 0, 0, 2472, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59834, 57886, 57886, 59838, 57886, 521, 521, 521, 521, 2870, 521, 521, 2874, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2883, 521, 521, 521, 2886, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3669, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58860, 57909, 57909, 57909, 57909, 57909, 58872, 0, 0, 57909, 57909, 60309, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60317, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61183, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60420, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59008, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59022, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57909, 60332, 57909, 57909, 57909, 57909, 60335, 57909, 57909, 60337, 57909, 60338, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60347, 57909, 57909, 60351, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60655, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 60666, 57936, 57936, 57936, 57936, 57936, 57936, 60673, 57909, 57909, 60360, 57909, 57909, 57909, 60363, 60364, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 60374, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 3096, 521, 521, 57886, 57886, 60443, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 450560, 450560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 147456, 0, 0, 450560, 0, 0, 57936, 57936, 57936, 60382, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60397, 57936, 57936, 57936, 57936, 60400, 57936, 57936, 60402, 57936, 60403, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61272, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 3942, 3627, 0, 0, 0, 0, 0, 371, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 371, 0, 0, 0, 379, 381, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1885, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3794, 521, 521, 521, 3795, 3796, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2559, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60325, 57909, 57909, 57909, 57909, 57909, 57909, 3190, 521, 521, 521, 3193, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1917, 521, 521, 521, 521, 521, 57886, 60581, 57886, 57886, 57886, 60584, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60594, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60838, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2561, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60630, 57909, 57909, 57909, 60633, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60643, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 58417, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60920, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 60674, 57936, 57936, 57936, 57936, 60679, 57936, 57936, 57936, 60682, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60692, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 4072, 4073, 0, 0, 0, 0, 0, 4079, 4080, 4081, 521, 521, 521, 4084, 521, 4086, 521, 521, 521, 521, 61435, 61436, 61437, 3457, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3469, 521, 521, 521, 521, 521, 57886, 57886, 57886, 60821, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60587, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60595, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 2560, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60640, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60883, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60897, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 60905, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61201, 57936, 57936, 521, 521, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3784, 521, 521, 521, 57936, 60939, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 3610, 0, 0, 0, 0, 0, 0, 0, 3616, 0, 0, 0, 0, 0, 0, 372, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 377, 0, 0, 0, 0, 0, 0, 0, 0, 2824, 2782, 0, 0, 0, 0, 0, 2829, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 2838, 521, 521, 521, 521, 521, 0, 0, 0, 3640, 3641, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3651, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3671, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60612, 57886, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60620, 57909, 57909, 57909, 57909, 521, 3661, 521, 521, 521, 521, 521, 3666, 521, 3668, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61022, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60292, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60303, 57886, 57886, 57886, 57886, 57886, 0, 2962, 0, 0, 57909, 57909, 57909, 57909, 61051, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61061, 57909, 57909, 57909, 57909, 57909, 57909, 61067, 57909, 61069, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58884, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58894, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59938, 57909, 57909, 57909, 57909, 57909, 57909, 59943, 57909, 59945, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 61096, 57936, 61098, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 3765, 0, 0, 0, 0, 0, 0, 0, 0, 2363, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2374, 0, 0, 0, 0, 0, 0, 0, 0, 0, 656, 0, 0, 659, 660, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 671, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3770, 0, 0, 0, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 3779, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3786, 521, 521, 521, 3790, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3799, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 61148, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60867, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60880, 57909, 57909, 61152, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61161, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 61167, 57909, 57909, 57909, 61171, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61053, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59459, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61438, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61446, 57886, 57909, 57909, 57909, 61451, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61459, 57909, 57936, 57936, 57936, 61464, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59576, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57936, 57936, 57936, 57936, 57936, 61472, 57936, 0, 0, 0, 0, 4131, 0, 4133, 521, 521, 521, 521, 521, 521, 521, 521, 521, 4139, 4140, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61445, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61458, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60919, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60929, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 4088, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 61490, 61491, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61498, 61499, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61506, 61507, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61415, 0, 0, 4074, 4075, 0, 0, 0, 521, 521, 521, 4082, 521, 521, 521, 521, 521, 521, 521, 521, 4090, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 60865, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61184, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61189, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 0, 521, 4220, 57886, 61565, 57909, 61566, 57936, 61567, 521, 57886, 57909, 57936, 521, 521, 521, 521, 521, 521, 521, 1899, 1900, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3800, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 425, 425, 0, 0, 131072, 425, 0, 0, 0, 425, 0, 0, 447, 0, 425, 0, 476, 476, 476, 0, 0, 361, 361, 361, 495, 361, 361, 361, 361, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 476, 539, 57905, 539, 57905, 539, 539, 57905, 539, 539, 57928, 57905, 539, 539, 57905, 57905, 57905, 57928, 57905, 57905, 57905, 57905, 57905, 57905, 57905, 57928, 57928, 57905, 57905, 57955, 57905, 57905, 57905, 57905, 57905, 57905, 57905, 57955, 57955, 57905, 57905, 57905, 57905, 57955, 57955, 57905, 539, 57905, 57905, 57905, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 376832, 0, 376832, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1854, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57909, 58369, 57909, 57909, 57909, 57909, 58387, 57909, 57909, 57909, 0, 0, 0, 0, 58293, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58425, 57936, 57936, 57936, 57936, 57936, 58444, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60069, 57936, 57936, 57936, 57936, 2729, 521, 521, 521, 521, 60078, 57886, 57886, 57886, 57886, 2739, 2266, 0, 2740, 2269, 0, 0, 2742, 57936, 58462, 57936, 57936, 57936, 521, 521, 521, 521, 892, 521, 0, 57886, 57886, 57886, 57886, 58311, 57886, 155941, 1138, 0, 1139, 0, 0, 1144, 0, 0, 0, 0, 0, 1150, 0, 0, 0, 0, 0, 5341184, 0, 5652480, 0, 0, 0, 0, 4759552, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1827, 0, 0, 0, 0, 0, 0, 0, 1834, 0, 0, 0, 0, 0, 0, 1244, 0, 0, 0, 0, 1249, 0, 0, 0, 1253, 0, 0, 0, 0, 0, 0, 0, 1253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 466944, 0, 0, 0, 0, 0, 0, 0, 0, 1825, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 353, 354, 355, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 521, 521, 521, 1327, 521, 521, 521, 1336, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2895, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60574, 57886, 57886, 60578, 57886, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58766, 57886, 57886, 57886, 58775, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61034, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 61042, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 61047, 57909, 57936, 57936, 57936, 57936, 57936, 58955, 57936, 57936, 57936, 58964, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59555, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 521, 1931, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1953, 521, 521, 521, 521, 521, 521, 0, 2470, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59839, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59333, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 60864, 57909, 57909, 57909, 57909, 60868, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60874, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 58402, 57936, 57936, 57936, 57936, 57936, 57936, 58433, 58435, 57936, 57936, 57936, 57936, 57936, 57936, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59433, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59986, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60001, 57936, 57936, 60004, 57936, 57936, 57909, 57909, 57909, 57909, 57909, 59474, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59486, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59497, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 57886, 57886, 59372, 57886, 57886, 59375, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59389, 57886, 57886, 57886, 57886, 57886, 57886, 59395, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59872, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 60304, 57886, 57886, 57886, 0, 2962, 0, 0, 57936, 57936, 57936, 57936, 59570, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59582, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59593, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 293, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3119, 0, 3120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3135, 0, 0, 0, 0, 2283, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2301, 0, 0, 0, 0, 2359, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 336, 0, 0, 0, 0, 57886, 59841, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59863, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 59930, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 58947, 57936, 57936, 57936, 57936, 57936, 57936, 60013, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59589, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 0, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60313, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58931, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 0, 57886, 57936, 57936, 57936, 57936, 60626, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 1259, 57886, 57936, 57936, 57936, 57936, 57936, 60675, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59524, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57886, 57886, 57886, 61155, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 61174, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61193, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 61100, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 57886, 57886, 57886, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 367, 0, 0, 0, 0, 0, 0, 0, 1205, 0, 0, 57936, 57936, 57936, 57936, 61471, 57936, 57936, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 57886, 57886, 57936, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57936, 57936, 57886, 57886, 57886, 57886, 57936, 57936, 57886, 521, 57886, 57886, 57886, 372, 372, 0, 0, 131072, 372, 0, 0, 0, 372, 0, 0, 0, 0, 372, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3122, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 57906, 57906, 57906, 57906, 57906, 57906, 57906, 57929, 57929, 57906, 57906, 57956, 57906, 57906, 57906, 57906, 57906, 57906, 57906, 57956, 57956, 57906, 57906, 57906, 57906, 57956, 57956, 57906, 540, 57906, 57906, 57906, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2334720, 0, 2334720, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 2834, 2835, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 58267, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 58343, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 61179, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 57936, 61187, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 301, 305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1282, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2758, 2759, 0, 0, 2762, 0, 2764, 0, 0, 0, 0, 0, 521, 521, 521, 58754, 901, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58780, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 57909, 59909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60658, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 57936, 57936, 60667, 57936, 60668, 57936, 57936, 57936, 57936, 58875, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59947, 57909, 57909, 57909, 57909, 57909, 0, 0, 0, 3771, 0, 3772, 0, 0, 0, 0, 3627, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3657, 521, 521, 521, 521, 521, 521, 0, 0, 0, 363, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 0, 245760, 0, 0, 0, 363, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 363, 0, 364, 0, 0, 0, 0, 363, 0, 0, 0, 139264, 147456, 0, 0, 0, 0, 0, 0, 653, 654, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1858, 0, 0, 0, 0, 0, 0, 0, 0, 0, 433, 131072, 0, 433, 433, 0, 0, 433, 0, 364, 433, 0, 459, 0, 0, 0, 487, 487, 490, 490, 490, 490, 496, 497, 490, 490, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 541, 57907, 541, 57907, 541, 541, 57907, 541, 541, 57930, 57907, 541, 541, 57907, 57907, 57907, 57930, 57907, 57907, 57907, 57907, 57907, 57907, 57907, 57930, 57930, 57907, 57907, 57957, 57907, 57907, 57907, 57907, 57907, 57907, 57907, 57957, 57957, 57907, 57907, 57907, 57907, 57957, 57957, 57907, 619, 57907, 57970, 57970, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1762, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1239, 1806, 0, 0, 0, 0, 1246, 1246, 0, 0, 57909, 57909, 57909, 57909, 57909, 58383, 57909, 57909, 57909, 57909, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60688, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58458, 57936, 57936, 57936, 57936, 521, 521, 521, 888, 521, 521, 0, 57886, 57886, 57886, 58307, 57886, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1794, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1806, 0, 0, 0, 0, 0, 0, 0, 0, 1272, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3402, 2768, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2318336, 57909, 57909, 57909, 57909, 57909, 60334, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60344, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57886, 57886, 57886, 58268, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 57909, 57909, 57909, 57909, 57909, 57909, 58344, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 58393, 0, 0, 0, 0, 57886, 57936, 57936, 57936, 57936, 58409, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59517, 59518, 57936, 57936, 57936, 57936, 59525, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 1240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2792, 0, 521, 1368, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1395, 521, 521, 521, 521, 521, 521, 521, 521, 2875, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 58834, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 50657, 58754, 977, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60895, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 60903, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 58996, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59024, 57936, 57936, 57936, 57936, 57936, 521, 521, 521, 521, 521, 521, 0, 57886, 57886, 57886, 57886, 57886, 57886, 155941, 1138, 0, 301, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 1216, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1232, 0, 0, 0, 0, 0, 0, 0, 0, 1304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 3178, 521, 3179, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2469, 0, 0, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59883, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 521, 521, 521, 2844, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2434, 521, 521, 57936, 57936, 57936, 57936, 57936, 57936, 60385, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 59522, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 640, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 893, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57909, 57909, 60862, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60879, 57909, 60881, 57909, 57936, 58463, 57936, 57936, 57936, 1126, 521, 521, 521, 893, 521, 0, 57886, 58477, 57886, 57886, 58312, 57886, 155941, 1138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1817, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 402, 0, 0, 0, 0, 0, 0, 0, 0, 331, 521, 58754, 0, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 59326, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 0, 57909, 59908, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60343, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 50657, 0, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59426, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 59961, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 60346, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 521, 521, 521, 521, 2415, 521, 2417, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2432, 521, 521, 521, 521, 521, 521, 2867, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1923, 57936, 57936, 57936, 57936, 60409, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 60423, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 3660, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 57886, 0, 0, 0, 2562, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57909, 57936, 57936, 57936, 61185, 57936, 57936, 57936, 61188, 57936, 57936, 57936, 57936, 57936, 57936, 57936, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 443, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 667, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 2310144, 0, 0, 0, 0, 0, 0, 0, 2310144, 0, 2310144, 0, 0, 0, 0, 0, 0, 2310144, 2310560, 2310560, 0, 2310144, 0, 0, 2310144, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 0, 0, 0, 0, 654, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2310144, 0, 367, 0, 0, 0, 0, 0, 0, 0, 2310560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 380, 0, 383, 0, 0, 0, 0, 0, 0, 2310144, 0, 0, 0, 2310144, 0, 0, 0, 0, 0, 2310144, 0, 0, 2310144, 0, 0, 2310144, 0, 2310144, 2310144, 0, 2310144, 0, 2310144, 2310144, 0, 0, 0, 0, 0, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 3445, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1347, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 1362, 521, 521, 2310144, 0, 0, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310733, 2310144, 2310733, 2310144, 2310144, 2310733, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2310, 0, 0, 0, 0, 0, 0, 0, 0, 2318, 0, 0, 0, 0, 0, 2322, 0, 0, 2324, 0, 0, 0, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 839, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 898, 57886, 57886, 57886, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 460, 2335197, 2335197, 2335197, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 2335231, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3392, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3399, 3400, 0, 3401, 0, 2335231, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2750, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2763, 0, 0, 0, 0, 0, 2767, 0, 0, 0, 0, 417, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2359296, 0, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 2359296, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3416, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2359296, 1, 24578, 3, 0, 0, 4366336, 0, 0, 0, 0, 0, 301, 302, 0, 4268032, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2798, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2813, 0, 0, 0, 0, 2367488, 0, 0, 4268032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 367, 0, 295, 0, 0, 0, 0, 0, 6275072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 976, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 521, 521, 521, 2391, 2392, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 521, 2855, 521, 521, 521, 521, 521, 521, 521, 2860, 521, 521, 521, 521, 521, 521, 521, 521, 0, 1, 24578, 3, 155941, 155941, 295, 0, 0, 0, 0, 0, 301, 302, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3117, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3134, 0, 0, 212992, 0, 0, 0, 0, 0, 4366336, 0, 0, 0, 0, 0, 0, 0, 0, 4268032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 382, 0, 0, 6258688, 6447104, 0, 0, 6127616, 0, 6348800, 5906432, 0, 5537792, 0, 0, 0, 0, 0, 5939200, 0, 0, 5677056, 6365184, 4866048, 0, 6070272, 5545984, 5152768, 0, 0, 6144000, 4358144, 4866048, 4882432, 4358144, 4358144, 4358144, 0, 1411, 0, 0, 0, 0, 0, 4857856, 4874240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5259264, 0, 0, 0, 0, 0, 0, 0, 0, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 900, 900, 900, 5537792, 5545984, 5586944, 5734400, 5971968, 4358144, 6045696, 4358144, 6070272, 4358144, 4358144, 4358144, 4358144, 6348800, 4358144, 6144000, 0, 6144000, 0, 4988928, 5005312, 0, 0, 0, 0, 5775360, 0, 0, 0, 0, 0, 0, 0, 750, 808, 0, 0, 0, 750, 0, 0, 811, 692, 0, 0, 0, 816, 0, 0, 0, 818, 0, 0, 0, 685, 692, 0, 0, 4358144, 5005312, 4358144, 4358144, 4358144, 5120000, 5136384, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 4358144, 6324224, 5914624, 5914624, 0, 0, 0, 0, 0, 5513216, 5783552, 0, 0, 0, 0, 0, 0, 656, 0, 779, 0, 0, 0, 0, 0, 0, 0, 783, 0, 0, 0, 0, 792, 0, 0, 0, 0, 0, 800, 0, 783, 0, 0
+];
+
+JSONiqParser.EXPECTED =
+[ 166, 182, 211, 1104, 242, 1452, 1467, 273, 289, 712, 1117, 319, 349, 333, 365, 381, 397, 413, 195, 1866, 2240, 2243, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 429, 445, 461, 477, 2088, 226, 493, 2075, 939, 621, 523, 543, 1716, 559, 575, 591, 607, 1422, 650, 666, 1822, 697, 1565, 634, 728, 738, 754, 796, 812, 828, 844, 860, 876, 892, 908, 924, 955, 2180, 985, 681, 2211, 1015, 1044, 1028, 1060, 1090, 1133, 1320, 1149, 1165, 1551, 1181, 1197, 1213, 1229, 1259, 1904, 1365, 1375, 999, 969, 1762, 1289, 1305, 1336, 1351, 1488, 1391, 1407, 1504, 1623, 1520, 1536, 1581, 1273, 1610, 1639, 1655, 1671, 2118, 2149, 1687, 1703, 1437, 507, 1732, 1748, 1778, 1074, 780, 1809, 1838, 1854, 1890, 1920, 1936, 1952, 1968, 1984, 2000, 2016, 2032, 2061, 257, 2104, 303, 2045, 767, 1793, 1594, 2134, 1243, 2165, 2196, 2227, 2234, 1874, 1479, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 2234, 536, 2259, 2263, 2271, 2271, 2271, 2265, 2269, 2271, 2272, 2276, 2279, 2286, 2282, 2290, 2294, 2298, 2302, 2306, 2310, 2381, 2790, 2790, 4003, 4941, 2790, 2791, 2314, 3074, 2982, 2790, 2790, 2790, 2687, 2790, 5013, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2827, 2790, 2571, 3537, 4080, 2436, 2320, 2443, 2466, 2326, 2336, 2790, 2790, 2790, 2343, 2790, 2790, 2349, 3841, 2707, 2790, 2734, 2759, 2790, 2790, 2790, 2790, 4756, 2738, 2790, 2790, 2790, 2790, 4767, 2321, 2390, 2466, 2466, 2466, 2466, 2355, 2361, 2790, 2790, 2790, 2790, 2790, 2371, 4535, 2790, 2696, 4816, 2790, 2790, 2790, 2697, 4817, 2790, 2790, 2790, 4822, 4790, 2790, 2790, 3017, 3842, 2448, 2790, 2790, 3537, 4079, 4079, 4079, 4079, 4079, 4099, 2436, 2436, 2436, 2436, 2436, 2387, 2321, 2321, 2321, 2321, 2321, 2459, 2466, 2466, 2466, 2466, 2466, 2332, 2401, 2790, 2790, 2762, 4873, 2790, 2790, 2790, 2790, 2820, 4885, 2790, 2790, 2790, 2790, 3243, 4891, 3542, 4079, 4079, 4079, 4097, 2436, 2436, 2436, 2436, 2458, 2321, 2321, 2321, 2331, 2466, 2466, 2426, 2790, 2790, 3074, 4076, 4079, 4079, 2396, 2436, 2482, 2321, 2321, 2464, 2466, 2466, 2411, 2790, 2790, 4535, 2790, 4077, 4079, 4079, 2480, 2436, 2436, 2457, 2321, 2321, 2420, 2467, 2428, 2834, 3536, 4079, 2434, 2436, 2441, 2321, 2465, 2332, 2447, 4095, 4081, 2437, 2376, 2466, 2452, 4078, 2436, 2321, 2466, 4335, 4081, 2456, 2463, 2422, 4080, 2482, 2463, 2471, 4098, 2483, 2331, 2478, 2329, 2487, 2491, 2474, 2495, 2498, 2508, 2512, 2519, 2519, 2519, 2515, 2525, 2519, 2521, 2529, 2536, 2532, 2540, 2544, 2548, 2552, 2556, 2560, 4697, 2790, 2790, 2790, 4729, 2790, 4591, 2584, 2858, 2790, 2790, 2790, 3364, 2591, 2790, 3610, 2603, 2609, 2613, 2617, 2621, 2625, 2628, 2632, 2636, 4053, 2702, 2790, 2790, 2790, 2790, 3877, 2642, 2648, 2892, 4432, 2646, 2915, 2367, 2654, 3828, 2813, 2790, 2652, 3406, 2659, 2664, 2790, 2790, 2790, 2790, 2790, 2671, 4434, 2580, 4063, 2790, 2676, 2680, 2790, 2790, 2790, 3867, 2684, 2790, 2790, 2790, 3868, 2685, 2750, 2790, 2790, 2790, 2790, 2756, 2760, 2790, 2790, 2790, 2790, 2790, 2880, 2666, 2790, 2790, 2777, 4228, 3359, 2851, 4232, 4238, 2790, 4246, 4420, 4253, 3266, 4258, 4264, 3443, 2790, 4721, 2782, 2790, 2790, 2790, 3228, 3232, 2790, 2790, 2790, 2790, 4105, 2790, 2790, 2790, 2790, 2790, 2790, 3903, 3876, 2788, 4641, 2790, 2790, 2790, 3307, 2790, 2790, 2790, 4640, 2818, 2790, 2790, 3306, 2795, 2935, 2812, 2790, 2790, 2744, 2790, 3875, 3239, 2817, 2790, 4088, 2790, 2790, 2824, 2790, 3502, 2818, 2790, 3007, 2790, 3959, 3750, 2960, 2745, 3748, 2790, 4626, 2790, 4622, 2667, 2940, 2842, 3754, 2902, 4615, 2840, 3753, 3753, 3753, 4616, 2838, 4624, 4624, 3006, 3753, 2841, 2903, 2719, 3291, 3292, 3752, 2941, 2998, 3000, 2847, 2790, 2790, 2790, 2790, 2790, 3322, 3326, 2790, 2790, 2790, 3241, 4802, 2775, 4735, 2782, 2790, 2790, 2790, 4802, 3231, 2790, 2790, 2790, 2771, 4780, 3110, 4601, 2790, 3607, 2790, 3763, 3555, 2886, 2973, 2790, 3980, 2790, 3666, 2790, 4542, 2416, 2884, 2890, 2896, 2907, 4569, 2911, 2790, 2919, 5035, 2790, 2913, 2925, 2790, 4599, 2686, 2790, 3665, 2790, 4541, 3125, 4330, 4429, 2929, 2934, 2939, 3953, 2790, 2790, 4197, 3440, 2790, 2790, 2790, 2790, 4592, 3426, 2790, 2790, 2790, 2790, 2790, 4860, 2951, 2790, 3324, 2790, 2790, 3609, 3761, 2790, 4016, 2955, 2741, 2842, 2790, 4742, 2959, 2790, 2790, 4535, 2790, 2790, 4096, 4079, 4079, 4079, 4079, 2435, 2436, 2436, 2436, 2436, 2437, 2980, 2790, 2790, 2790, 2790, 2802, 2989, 2790, 2790, 2790, 2790, 2801, 2988, 2790, 2790, 2790, 4818, 4810, 3928, 2790, 3608, 3761, 2316, 2993, 3004, 2790, 3011, 3032, 2790, 2790, 2790, 4503, 3015, 2790, 2790, 2790, 2790, 3011, 3032, 2790, 2790, 2790, 2790, 2790, 3026, 4920, 2790, 2790, 2790, 2790, 3025, 4919, 2790, 2790, 2790, 2790, 2790, 4355, 3755, 4359, 2790, 2790, 3354, 3059, 4366, 4372, 4240, 2834, 4504, 3016, 2790, 2790, 3635, 3927, 3023, 3031, 4541, 3436, 3037, 3854, 3044, 2790, 2790, 3451, 3049, 2790, 2790, 3024, 3043, 2790, 2790, 2801, 3048, 2790, 2790, 3053, 3064, 3031, 4492, 3071, 2975, 3079, 2790, 3470, 3088, 2790, 3421, 3079, 2790, 2801, 3098, 2790, 4152, 3102, 3109, 2574, 3114, 3122, 2790, 4585, 3124, 2790, 3129, 2790, 4584, 3123, 2790, 4154, 3033, 3133, 4950, 3518, 3142, 4948, 4952, 3148, 2790, 4155, 3156, 3188, 3160, 3150, 4950, 3167, 3186, 3174, 3174, 3174, 3180, 3184, 3192, 3192, 3196, 3200, 3175, 3209, 3433, 3213, 3176, 3861, 3217, 3221, 4494, 3225, 3236, 3247, 2790, 2790, 2790, 2790, 3914, 2790, 2790, 3253, 3263, 3403, 3170, 3479, 3270, 3274, 3278, 3282, 3285, 3285, 3286, 2790, 2790, 3913, 2790, 3549, 3337, 3848, 3342, 3290, 3496, 2655, 3296, 3300, 3311, 3318, 4953, 3330, 4637, 2790, 3320, 2790, 2790, 3659, 2790, 2790, 3336, 2790, 2790, 4722, 2770, 2790, 2790, 2790, 2790, 4722, 2770, 2790, 2790, 2790, 2790, 2790, 4190, 3341, 3484, 3460, 3144, 3346, 3363, 3369, 2976, 3375, 2790, 2790, 2790, 3383, 3388, 2790, 2790, 2790, 3472, 2790, 2790, 2790, 4413, 2790, 4305, 3786, 4825, 2790, 2790, 2364, 2790, 3482, 3486, 2790, 3416, 3420, 2790, 4591, 3425, 2790, 2790, 2790, 2790, 2672, 3430, 2790, 2790, 2790, 3769, 2790, 2790, 2790, 2790, 3471, 3736, 2790, 2790, 2790, 2790, 3776, 2790, 3469, 2790, 2790, 2790, 2790, 4198, 3468, 2790, 2790, 2790, 2790, 4198, 3468, 2790, 2790, 2790, 2790, 2921, 3506, 2790, 2790, 2790, 4591, 3513, 2790, 2790, 2790, 3724, 2660, 2790, 4124, 3542, 3476, 3490, 3494, 3634, 3500, 2790, 2921, 3506, 2790, 2790, 2790, 2790, 3512, 3517, 3522, 2833, 3204, 2790, 3527, 2790, 2790, 2790, 4249, 2790, 2790, 2790, 3526, 2790, 2790, 2790, 3821, 2761, 2790, 2790, 2790, 2790, 4347, 2686, 2790, 2790, 2790, 2790, 4351, 2790, 4248, 2790, 2790, 2790, 3531, 3517, 3412, 2790, 2790, 4987, 2790, 2790, 2563, 2790, 2790, 2790, 4094, 4079, 4079, 4079, 4079, 2435, 2436, 2436, 2436, 2397, 2321, 2321, 2321, 2321, 2321, 2464, 2466, 2466, 2466, 2466, 2393, 2405, 2790, 2790, 2833, 2790, 4987, 2790, 2790, 4422, 2790, 2790, 4126, 4322, 3032, 2790, 4987, 2790, 3390, 4989, 2790, 2605, 2730, 2790, 3541, 3547, 4788, 3547, 2566, 2566, 2566, 4894, 4014, 4014, 4014, 4788, 2832, 3553, 2315, 4875, 2567, 4015, 4896, 2830, 2899, 3559, 3560, 3564, 2790, 2790, 2790, 2790, 2790, 3615, 3614, 2790, 2790, 4465, 3917, 2585, 3619, 3625, 3737, 4266, 4915, 3629, 3649, 4306, 3633, 3639, 3647, 3653, 2790, 2790, 4691, 3658, 2790, 4464, 3916, 2790, 3663, 2722, 3670, 3674, 4193, 4196, 2790, 3690, 2790, 2790, 2790, 2382, 3694, 2790, 2790, 2790, 2383, 3695, 2790, 2790, 2790, 2339, 3143, 2790, 2790, 2790, 4517, 2790, 2965, 4474, 4719, 4065, 4703, 2578, 3699, 3704, 2790, 2790, 3118, 2790, 2790, 2790, 4999, 2790, 4869, 4984, 5004, 2752, 2790, 2790, 3118, 2790, 4317, 3723, 2790, 2790, 2790, 2790, 4391, 3711, 2790, 2790, 2790, 2790, 3716, 3847, 2790, 2790, 3259, 2790, 2790, 2790, 2790, 2790, 3258, 2783, 2790, 2790, 2790, 2790, 3258, 2783, 3791, 2725, 2790, 3795, 2790, 2790, 3803, 2790, 2790, 3810, 2790, 2790, 2638, 2790, 4782, 3202, 2716, 3818, 2790, 3795, 2790, 4584, 3812, 2790, 2351, 2790, 2790, 3811, 2790, 3825, 3838, 2790, 2790, 4988, 2790, 3725, 4875, 2790, 2414, 2790, 3535, 4942, 2790, 2430, 2790, 4323, 4014, 3846, 3205, 3847, 4039, 2790, 2713, 2790, 3852, 3683, 3067, 3104, 2790, 3685, 4305, 3685, 3915, 3915, 3105, 3683, 3683, 3683, 3066, 3331, 3105, 3332, 3331, 3332, 3684, 3256, 2790, 2790, 3371, 3735, 2790, 2790, 2790, 2790, 3421, 3742, 2790, 2790, 2790, 2790, 2790, 3741, 2790, 2790, 2790, 2790, 3746, 2790, 3759, 2703, 3621, 4113, 3881, 3885, 3889, 3893, 3894, 3898, 3902, 2790, 2790, 3162, 2790, 2790, 3643, 2983, 4501, 4562, 3907, 3765, 4282, 3921, 2790, 4554, 4022, 2790, 3925, 3932, 4556, 3936, 2790, 4242, 3941, 2790, 2855, 2784, 3943, 4375, 4402, 2862, 2866, 2870, 2874, 2874, 2875, 2879, 2819, 3325, 2790, 2778, 2790, 4182, 4960, 4187, 2504, 5007, 4203, 4207, 4211, 4215, 4219, 4222, 4224, 2790, 2790, 4077, 4079, 4079, 4079, 4079, 4079, 2396, 2436, 2436, 2436, 2436, 2436, 2375, 2321, 2321, 2321, 2322, 2466, 2466, 2466, 2466, 2466, 2332, 2357, 2380, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 3204, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 3163, 2790, 2790, 2746, 3858, 4848, 4930, 3872, 3642, 4579, 2727, 4118, 2315, 3764, 3947, 3951, 2790, 2790, 3814, 3957, 2790, 2790, 2790, 3967, 3350, 2984, 2729, 3978, 3548, 3984, 3961, 2790, 2790, 3813, 3988, 2790, 2790, 2790, 2790, 3686, 4027, 2790, 2790, 2790, 2790, 3257, 4051, 2790, 3074, 2790, 2790, 4299, 3993, 2790, 4007, 2790, 2984, 2790, 3568, 3575, 4260, 3583, 3587, 3591, 3594, 3597, 3600, 3601, 3605, 2790, 2790, 2790, 4750, 2964, 2790, 2790, 2790, 2790, 2969, 2761, 2790, 2790, 2790, 2790, 4743, 2790, 4834, 2790, 3348, 4604, 4013, 4070, 4311, 4020, 2790, 2790, 2790, 4026, 2790, 2790, 2790, 2790, 3578, 4964, 2790, 2790, 2790, 2790, 4969, 2790, 2790, 2790, 2790, 3579, 2790, 4031, 2790, 4037, 2790, 4043, 2789, 4333, 4571, 4021, 2790, 2790, 4362, 2790, 2790, 2790, 2790, 3968, 4183, 2790, 2790, 4271, 3972, 4033, 2790, 2790, 4832, 2790, 2796, 2790, 4360, 3993, 2790, 2790, 2790, 2790, 4049, 2790, 2790, 2790, 2790, 4361, 2761, 4510, 4241, 4057, 4254, 4773, 4069, 4439, 2790, 2790, 4976, 2790, 2790, 2790, 4457, 2761, 2790, 2790, 4485, 3989, 2790, 2790, 4456, 4074, 3731, 4836, 4254, 4085, 4092, 3707, 2790, 4060, 2790, 2790, 4060, 4147, 4132, 4140, 4134, 4843, 2501, 4130, 4921, 4921, 4921, 4291, 4135, 4132, 4132, 4132, 4139, 4922, 4135, 4144, 4922, 4923, 4133, 4159, 4169, 4171, 4166, 4163, 4175, 4178, 2790, 2790, 2790, 2800, 2790, 2746, 3958, 4087, 2818, 2790, 3314, 2806, 2790, 3502, 2818, 2790, 2790, 4270, 3039, 4275, 2790, 2790, 2790, 4279, 3358, 2850, 4286, 4295, 2790, 3397, 3607, 4303, 4310, 2790, 2790, 4965, 4315, 2790, 2790, 2790, 3378, 4321, 2790, 2790, 2790, 3379, 2790, 2790, 3472, 2790, 2790, 2790, 2345, 3847, 2790, 2790, 3471, 3736, 2790, 4603, 2790, 4305, 2790, 4812, 4327, 4339, 2790, 2790, 3352, 3356, 2996, 4343, 3937, 4297, 4995, 4476, 2843, 2790, 3025, 4927, 2790, 2790, 4934, 2406, 2599, 4938, 5023, 4946, 2790, 2790, 2790, 2790, 4957, 4381, 4359, 2790, 2790, 2790, 3806, 4389, 2790, 2790, 2790, 2790, 3963, 4396, 2790, 2790, 2790, 2946, 2790, 2790, 2790, 3712, 2947, 2790, 2790, 2790, 4234, 3973, 2790, 2790, 2790, 3962, 4395, 2790, 2790, 2790, 2790, 3962, 4395, 3755, 4359, 2790, 3056, 3060, 4368, 3960, 4535, 4377, 2790, 2790, 2790, 2808, 4400, 2790, 2790, 2790, 2790, 4406, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 4708, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 3152, 3203, 2790, 2790, 2790, 2790, 2790, 3963, 4411, 2790, 2790, 2790, 2807, 4407, 4446, 2790, 4417, 2942, 4426, 3654, 3761, 2790, 2790, 3720, 2790, 2790, 2790, 2790, 2790, 3729, 2790, 4472, 2790, 2586, 3787, 3138, 2790, 4862, 4438, 2790, 2790, 2807, 4451, 2790, 2790, 2790, 4443, 2790, 2790, 2790, 4450, 4689, 3400, 2942, 4455, 4536, 4484, 2790, 4461, 2790, 2790, 4469, 2790, 2790, 4480, 2790, 2790, 3779, 4523, 4489, 4498, 3654, 4483, 2790, 4508, 2790, 5040, 4002, 2790, 4514, 2790, 2790, 4521, 4525, 4529, 4540, 4384, 4590, 4385, 2790, 4514, 2790, 4547, 4551, 2790, 3997, 4560, 4566, 3999, 4575, 3995, 4009, 4009, 4009, 4583, 4589, 4001, 4001, 4596, 3680, 4608, 4879, 4613, 4620, 4609, 4877, 2407, 3782, 4792, 4793, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 3018, 4630, 4634, 4645, 4649, 4653, 4657, 4661, 4665, 4669, 4672, 4676, 4679, 4683, 2790, 2790, 2790, 3017, 4695, 4542, 4761, 4701, 4577, 4906, 4707, 4712, 4716, 4727, 2790, 3832, 2594, 3075, 4733, 3830, 4739, 2790, 2790, 2790, 3019, 4842, 2597, 4900, 4904, 4853, 4912, 2790, 2790, 2790, 2790, 2790, 3027, 4747, 4754, 4760, 4765, 4771, 4777, 4786, 4797, 4801, 2790, 2790, 2790, 2790, 4807, 2790, 2790, 3876, 4543, 4150, 2930, 2766, 2790, 2790, 2790, 2790, 2790, 4723, 2790, 2790, 2790, 2691, 2790, 2790, 2790, 3094, 2695, 2701, 2790, 2790, 2790, 2790, 3508, 2790, 4840, 2406, 4847, 4803, 4111, 4852, 4857, 4914, 2790, 2790, 2790, 2790, 2696, 4866, 2790, 2790, 3910, 2790, 2790, 4686, 4531, 4887, 3772, 3082, 3706, 2790, 4289, 2790, 3974, 3915, 4973, 2790, 4980, 4984, 5018, 4907, 4994, 2790, 2790, 2801, 4830, 2790, 2790, 2790, 5000, 2790, 3091, 2790, 2790, 4103, 4533, 4109, 3084, 2790, 4117, 4908, 2790, 3303, 2790, 4122, 3249, 2790, 4999, 2790, 2790, 4828, 2790, 2790, 3571, 2790, 5011, 5017, 5022, 2790, 2790, 3799, 2790, 3384, 3389, 2790, 2790, 5029, 3394, 2790, 2790, 2790, 2790, 4881, 2790, 3543, 3449, 3410, 3116, 5028, 2790, 3798, 2790, 2790, 5027, 3365, 3864, 2790, 4990, 2790, 4045, 2790, 2710, 2790, 3447, 4603, 3455, 3459, 3700, 3677, 2790, 2790, 3464, 2790, 2790, 2790, 2790, 2790, 4199, 5033, 3136, 2790, 4383, 5039, 2587, 3834, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2578, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 2790, 6090, 6563, 5044, 5057, 5054, 6594, 6596, 6596, 6596, 6591, 5074, 6595, 6596, 6596, 6596, 6596, 5087, 5061, 5074, 6596, 6596, 5067, 5062, 6596, 5078, 5084, 5080, 5066, 6594, 6163, 5071, 5091, 5094, 5094, 5094, 5095, 5099, 5099, 5103, 5107, 5114, 5111, 5118, 5122, 5134, 5137, 5129, 5130, 5127, 5125, 5141, 5145, 6561, 6446, 5234, 5173, 5635, 5635, 5635, 5219, 5598, 5503, 5251, 5251, 5251, 5251, 5252, 5196, 5267, 6248, 5502, 5251, 5251, 5196, 5196, 5196, 5266, 5202, 5212, 5632, 5635, 5050, 6519, 6509, 5635, 6818, 5635, 5635, 5146, 5150, 6535, 5218, 5635, 5635, 5147, 5154, 5196, 5267, 5268, 5502, 5213, 5214, 5232, 5214, 5631, 5635, 5146, 5151, 5635, 5155, 5619, 6297, 5635, 6532, 6536, 5244, 5250, 5251, 5251, 5251, 5295, 5631, 5633, 5635, 5635, 5635, 5049, 6518, 5502, 5502, 5293, 5251, 5251, 5226, 5196, 5196, 6247, 5270, 5502, 5502, 5502, 5504, 5268, 5502, 5214, 5633, 5282, 5635, 5635, 5635, 5273, 6084, 5196, 5267, 5271, 5635, 5166, 5635, 5635, 5749, 5219, 5251, 5296, 5196, 5196, 5306, 5635, 5196, 5265, 5269, 5273, 5635, 5635, 5165, 5635, 6247, 5268, 5502, 5502, 5502, 5502, 5251, 5502, 5251, 5251, 5251, 5186, 5193, 5272, 5635, 5635, 6261, 5635, 5298, 5635, 5635, 6262, 5502, 5502, 5294, 5251, 5251, 5251, 5296, 5251, 5251, 5264, 5196, 5196, 5196, 5196, 5265, 5196, 5197, 5635, 6245, 5269, 5293, 5296, 5306, 6246, 6247, 5502, 5502, 5502, 5292, 5251, 5251, 5196, 6255, 6247, 5270, 5292, 5251, 5264, 5197, 5198, 5302, 5297, 5312, 5312, 5304, 5635, 5179, 5635, 5643, 5168, 5635, 6860, 5329, 5590, 5333, 5336, 5339, 5343, 5362, 5419, 5347, 5351, 5404, 5419, 5419, 5419, 5419, 5368, 5384, 5393, 5355, 5359, 5418, 5367, 5372, 5346, 5420, 5381, 5390, 5397, 5377, 5386, 5419, 5376, 5401, 5416, 5424, 5428, 5430, 5430, 5434, 5436, 5440, 5473, 5444, 5446, 5365, 5407, 5450, 5454, 5458, 5466, 5464, 5466, 5462, 5470, 5477, 5635, 5181, 6353, 5635, 5219, 5635, 5635, 5219, 5635, 7266, 5635, 5904, 5635, 6256, 6080, 5635, 6853, 5635, 5635, 5169, 5672, 6820, 5635, 5635, 5635, 5275, 5635, 5635, 7112, 6346, 7172, 5635, 5220, 7282, 5635, 5273, 5642, 5635, 5635, 6879, 5246, 5891, 5635, 5635, 5182, 6258, 5523, 6083, 6080, 5977, 6569, 5635, 6877, 6875, 6150, 5527, 5530, 5531, 5535, 5538, 5542, 5547, 5545, 5551, 5553, 5554, 5558, 5561, 5569, 5562, 5566, 5562, 5572, 5574, 5578, 5635, 6820, 6222, 5635, 5975, 5635, 5635, 6702, 6210, 5614, 5635, 5635, 5189, 5635, 5635, 6773, 5656, 5635, 5635, 5635, 5307, 5668, 5635, 5635, 5635, 5315, 6779, 5662, 5666, 5635, 5635, 5635, 5582, 5675, 5635, 5635, 5635, 5320, 5679, 6567, 5635, 5683, 5691, 5698, 5706, 5734, 5699, 5707, 6568, 5635, 5635, 5635, 5491, 6736, 5694, 5700, 5708, 5162, 5635, 5635, 5635, 5513, 7310, 6318, 5664, 5635, 5635, 5635, 5277, 5746, 5635, 5712, 5635, 5274, 5273, 5635, 5274, 6223, 5635, 5275, 5635, 6695, 5635, 5635, 6694, 5823, 6568, 5635, 5322, 5635, 5635, 5910, 5635, 5635, 5635, 6618, 5236, 5635, 5717, 6739, 6745, 5731, 6568, 5635, 5324, 5635, 6335, 5811, 5635, 5635, 5635, 5675, 5701, 5732, 5635, 5635, 5318, 5635, 5635, 6736, 6740, 6744, 5730, 5734, 5635, 5635, 5635, 5514, 5768, 5701, 5775, 6568, 5776, 5635, 5635, 5635, 5615, 5747, 7254, 5635, 5635, 5512, 6989, 5208, 6448, 5733, 5635, 5635, 5635, 5625, 5788, 7253, 5635, 5635, 5635, 5635, 5159, 5797, 5635, 5635, 5635, 5638, 6319, 5635, 5635, 5635, 5640, 6027, 5799, 5635, 5635, 5635, 5646, 5650, 6805, 5635, 5635, 5635, 5655, 5805, 5798, 5635, 5635, 5635, 5636, 5515, 5803, 6804, 6568, 5635, 5496, 5048, 5635, 5219, 6618, 5635, 5635, 5635, 6260, 5635, 5583, 5635, 5635, 5819, 6695, 5635, 5635, 5635, 5724, 5819, 5635, 5821, 5819, 5635, 5635, 6934, 6878, 5756, 5815, 5829, 5635, 5508, 5204, 5664, 5842, 5846, 5854, 5858, 5862, 5866, 5866, 5868, 5870, 5870, 5870, 5870, 5874, 5874, 5874, 5874, 5877, 5879, 5635, 5635, 5635, 5738, 7116, 5885, 5635, 6258, 6080, 5635, 5899, 5917, 5635, 5635, 5594, 5635, 5324, 5635, 5635, 6618, 5635, 6618, 5635, 5582, 5635, 5635, 5819, 5921, 5635, 5635, 5487, 7303, 5485, 5635, 6834, 5635, 5635, 5612, 5635, 6832, 5932, 5635, 5635, 5635, 7178, 5635, 6696, 5635, 5937, 5325, 5635, 5635, 5635, 5761, 5969, 5635, 5635, 5635, 5804, 5984, 5635, 5635, 5635, 5819, 5635, 5850, 6339, 5992, 5606, 5635, 5635, 5635, 6696, 5635, 5938, 5635, 6256, 6930, 6081, 6015, 5635, 5635, 5635, 5895, 6016, 5635, 5635, 5635, 5902, 5640, 5999, 6005, 6011, 6261, 5635, 6095, 5635, 5635, 6088, 6289, 6037, 6042, 5635, 5635, 5635, 7255, 5635, 5635, 6027, 6032, 6038, 6043, 5635, 5635, 6256, 5635, 6082, 5635, 5820, 5635, 5820, 5635, 5635, 5821, 6261, 6335, 6695, 5635, 5635, 6692, 6568, 5923, 7028, 6032, 6058, 6033, 6059, 5635, 5635, 5635, 5908, 7128, 7132, 6613, 5635, 5635, 5635, 5923, 5517, 6786, 6790, 5635, 6564, 5635, 5635, 5635, 5907, 6260, 6318, 5635, 5635, 5635, 7259, 6072, 6033, 6064, 5635, 5635, 7027, 6032, 6063, 6564, 5635, 5635, 6260, 6261, 5636, 6988, 7255, 5678, 5635, 6082, 5635, 5821, 5945, 5412, 5635, 5635, 5635, 7285, 5635, 5635, 6257, 6081, 6261, 5635, 5635, 5635, 5221, 6071, 6711, 6064, 5635, 5635, 6838, 5635, 5589, 6617, 6072, 6712, 6065, 5635, 5635, 6844, 5635, 5635, 6851, 6568, 6070, 6710, 6063, 6564, 5943, 6983, 5635, 5635, 5635, 7286, 5635, 5756, 5635, 5635, 5635, 5943, 6260, 6094, 5635, 5635, 5635, 7332, 5720, 5635, 6821, 6073, 6109, 5635, 5635, 5635, 5956, 5635, 6099, 6107, 6066, 6256, 6081, 6337, 5635, 5635, 6852, 5635, 5320, 5635, 6075, 6079, 5635, 5635, 5635, 5958, 5635, 6820, 7158, 6077, 5635, 5635, 5635, 7346, 5635, 6131, 6821, 6074, 6076, 5635, 5635, 6820, 6708, 6127, 5635, 5635, 7156, 5634, 5905, 5635, 5228, 6053, 5274, 6116, 6079, 5635, 6981, 6142, 7156, 5822, 5635, 7157, 6118, 5635, 5635, 6115, 6078, 5635, 5635, 6114, 6078, 5635, 5635, 6115, 6078, 5635, 5674, 5285, 5674, 6117, 5635, 5635, 5636, 5635, 5635, 5635, 6221, 6118, 5635, 5635, 6116, 6139, 6079, 5635, 6139, 7083, 5674, 6617, 7134, 5635, 7134, 5635, 7134, 5635, 6616, 6614, 5635, 5635, 6878, 5764, 6744, 6449, 5734, 5635, 5287, 6614, 6614, 6614, 7253, 5635, 5674, 5635, 5635, 5512, 5516, 5635, 6392, 6392, 5635, 5636, 5642, 6257, 5635, 6085, 7286, 5635, 5635, 5635, 6481, 6485, 5733, 6255, 6840, 6147, 5635, 5635, 6940, 6946, 7286, 6617, 6879, 6154, 6160, 6167, 6156, 6171, 6175, 6179, 6183, 6184, 6189, 6189, 6185, 6193, 6193, 6193, 6193, 6196, 7276, 5635, 5583, 5635, 5635, 5582, 6208, 5635, 5635, 6214, 6197, 5278, 6228, 5635, 5635, 6975, 5635, 5635, 7001, 5769, 5797, 5308, 5635, 6961, 5635, 5635, 7001, 5770, 6236, 5635, 5980, 6254, 5635, 5635, 5636, 5945, 5412, 5951, 5635, 5635, 6252, 5635, 5635, 5635, 6053, 5635, 6255, 6086, 6855, 6868, 5635, 6399, 5635, 6614, 5635, 5635, 6273, 5635, 5635, 5638, 5964, 6676, 5635, 5635, 5636, 6988, 6994, 5635, 5678, 5635, 6081, 5635, 5819, 5972, 5635, 5635, 5635, 6082, 6085, 5635, 6281, 5635, 5635, 5640, 6573, 6802, 5206, 6295, 5635, 5635, 7007, 7016, 7041, 5635, 7144, 6290, 6803, 5207, 5207, 6296, 5635, 5635, 5635, 6084, 6291, 5771, 6995, 5635, 5635, 7034, 5635, 5635, 7152, 5635, 5635, 7253, 5635, 5635, 6954, 5657, 5635, 7252, 6400, 5635, 6670, 5635, 6259, 6209, 5635, 5639, 6347, 5635, 5635, 5635, 6088, 6309, 6301, 6325, 6329, 5635, 6310, 6302, 6326, 6079, 5635, 6982, 5907, 5635, 6258, 6081, 6311, 6801, 6327, 5635, 5635, 7257, 6960, 6255, 6086, 6856, 6869, 5635, 5635, 5640, 7027, 6400, 5635, 6735, 7277, 6693, 5635, 6671, 5635, 5635, 5320, 6310, 6323, 6327, 6324, 6328, 5635, 5635, 5635, 6089, 5149, 5153, 6086, 6866, 6567, 5635, 5635, 7287, 6616, 5635, 6879, 7278, 5582, 5635, 6769, 6564, 5635, 7252, 6400, 5288, 6079, 6695, 6669, 5635, 5635, 6201, 5635, 6344, 5635, 5635, 5674, 5805, 6351, 6357, 5635, 5635, 5676, 5635, 6820, 7179, 6366, 6329, 5635, 5260, 5635, 5635, 5635, 6122, 6399, 5635, 5635, 6671, 5635, 6259, 6365, 7255, 5635, 6021, 5635, 5635, 5315, 5167, 5635, 5635, 5635, 6247, 6247, 6619, 5635, 5635, 5635, 6255, 6086, 5635, 6620, 5635, 5635, 5635, 6256, 5219, 5635, 5635, 6619, 5904, 5748, 6771, 6620, 6618, 5635, 7096, 6618, 6618, 6618, 6770, 5901, 5511, 6370, 5635, 5635, 7333, 5721, 5635, 7255, 7154, 5635, 5635, 7349, 5518, 7319, 6209, 6384, 5635, 6372, 5985, 6719, 6390, 6396, 6404, 6408, 6411, 6413, 6417, 6418, 6418, 6422, 6424, 6425, 6429, 6429, 6429, 6429, 6430, 6429, 5635, 5635, 5755, 5635, 5635, 5635, 5888, 5635, 6604, 7326, 5635, 5635, 5635, 6616, 5635, 6692, 5635, 5824, 6457, 6568, 5635, 6852, 5635, 6948, 5635, 6949, 6455, 5635, 5635, 5635, 6261, 6260, 5635, 6462, 6456, 5635, 5637, 5640, 6675, 7115, 5635, 6467, 5635, 5658, 6453, 5635, 6463, 5635, 5635, 5635, 6262, 7328, 5635, 5635, 5635, 6267, 5277, 6615, 5635, 5635, 5755, 5818, 5635, 6819, 5635, 5635, 6494, 6473, 5635, 6477, 5635, 5638, 6346, 5635, 5635, 7275, 5635, 5635, 7287, 5635, 5635, 5635, 6480, 5635, 6498, 6507, 6513, 6518, 6508, 6514, 5635, 5635, 6523, 5635, 5635, 5635, 6315, 5635, 6540, 5635, 5635, 5783, 5635, 5635, 6554, 5635, 5635, 5635, 6339, 5635, 6263, 6549, 6503, 5635, 6547, 5176, 6553, 5635, 5635, 5635, 6334, 5635, 6558, 7327, 5635, 5635, 5784, 5635, 6578, 5153, 5635, 5635, 5635, 6439, 6088, 6574, 6579, 5154, 5635, 5635, 6583, 5635, 5635, 5894, 5810, 5635, 5635, 5581, 5635, 5635, 5635, 5725, 6054, 5637, 5635, 5635, 5900, 5635, 5635, 5635, 5904, 5635, 6088, 6588, 5153, 5635, 5638, 6826, 7252, 6088, 5148, 5152, 5635, 5640, 7087, 6772, 6084, 6772, 6084, 5275, 5635, 6694, 5904, 6338, 5277, 6693, 5635, 5825, 5635, 6821, 6600, 5635, 5640, 7334, 5907, 5635, 5635, 6822, 6224, 5635, 5644, 5648, 6102, 5635, 6821, 6223, 5635, 5635, 5635, 6479, 6762, 5824, 5635, 5321, 5635, 5647, 7054, 7038, 5635, 7255, 5637, 5635, 5654, 5635, 5635, 5222, 7284, 5635, 5635, 5276, 5635, 5277, 6695, 6337, 6260, 5635, 5635, 5635, 5256, 6220, 5154, 5635, 5635, 5635, 6399, 5638, 6692, 5635, 5635, 5923, 6072, 5638, 7024, 6610, 5635, 5674, 6141, 5635, 5635, 6854, 5635, 5635, 6878, 5693, 5699, 7255, 6216, 6771, 5635, 5677, 5635, 5635, 5635, 5587, 5911, 6624, 5628, 6630, 6638, 6641, 6645, 6648, 6656, 6656, 6656, 6656, 6651, 6652, 6652, 6652, 6660, 6660, 6660, 6660, 6662, 6666, 5635, 5635, 5635, 6566, 6048, 5635, 5622, 5635, 5686, 5838, 5635, 5686, 6053, 5635, 5635, 5635, 5985, 5635, 5589, 6694, 5939, 6617, 5912, 6686, 5635, 5635, 5944, 5411, 6052, 6691, 5635, 5635, 6756, 6701, 5635, 5635, 5635, 6567, 6125, 6772, 5635, 5635, 5987, 5635, 5635, 6723, 6729, 7278, 6695, 6734, 5635, 5635, 5991, 5605, 6749, 5635, 5635, 5635, 6615, 5635, 5635, 5635, 5645, 5649, 5635, 6480, 6763, 6750, 5635, 6764, 5607, 5635, 5635, 5635, 5835, 5635, 6717, 5635, 5635, 6026, 6031, 5608, 5635, 6730, 6143, 6483, 6487, 6568, 5635, 5635, 6486, 5734, 5635, 5635, 6133, 6881, 5635, 5635, 6133, 7095, 5635, 5635, 5635, 6816, 6204, 6203, 5635, 5635, 6134, 6772, 5909, 5635, 5635, 5635, 6620, 5635, 5597, 6879, 6795, 5635, 5635, 5635, 6685, 6480, 6484, 6488, 5635, 5635, 6616, 6615, 5635, 5635, 6204, 6202, 5274, 6126, 5635, 5635, 6220, 6224, 7347, 6777, 5635, 5635, 6230, 5635, 5635, 6230, 6485, 5733, 5635, 5635, 6054, 5204, 5635, 7269, 6772, 5635, 5687, 5952, 5635, 5713, 5635, 5635, 5276, 6615, 5635, 6277, 5635, 5635, 6619, 6809, 5734, 5635, 5635, 6246, 6247, 6247, 6247, 6247, 5270, 5502, 7114, 5635, 7254, 5635, 5674, 5805, 5798, 6276, 5748, 5635, 5635, 6255, 6247, 6247, 6247, 5269, 5502, 5502, 5835, 6053, 5635, 5635, 6318, 6568, 5635, 7347, 7114, 5635, 5635, 6819, 5321, 5635, 6845, 5635, 5635, 5635, 6716, 5635, 6974, 5635, 5635, 6333, 5635, 6256, 5317, 6285, 5635, 5635, 6966, 5635, 5635, 6965, 5635, 5635, 6257, 5635, 6961, 6053, 5635, 5635, 6967, 5635, 6255, 5589, 6617, 5635, 5753, 5635, 5635, 5323, 5635, 6113, 5634, 5904, 5635, 6256, 6961, 6053, 6255, 6965, 6965, 6965, 5635, 6967, 6965, 5635, 6965, 5635, 6258, 6967, 6965, 7286, 6269, 5741, 5741, 5741, 6053, 6849, 5635, 5635, 5635, 6754, 5635, 7342, 6334, 5635, 5780, 6568, 5635, 5492, 6542, 6492, 5635, 5635, 5635, 6307, 6311, 6324, 6936, 6083, 6873, 5319, 6886, 6892, 6890, 6896, 6900, 6900, 6902, 6908, 6906, 6906, 6908, 6916, 6915, 6912, 6920, 6921, 6921, 6921, 6921, 6925, 6928, 5208, 5635, 5635, 6855, 6526, 6380, 5635, 5635, 6340, 5993, 6565, 5635, 5635, 6617, 5635, 5635, 5635, 6706, 5635, 6239, 5635, 5635, 6364, 7154, 5635, 6242, 5635, 5635, 5637, 5965, 5635, 6953, 5635, 5635, 6376, 5635, 5635, 6958, 5635, 5635, 6443, 5589, 7258, 5635, 5635, 5635, 6760, 5635, 6971, 5635, 6979, 6987, 6993, 6329, 5635, 5832, 6260, 6680, 6878, 5791, 6543, 5635, 5836, 5635, 5635, 6284, 5635, 5635, 6567, 5635, 6616, 5635, 5635, 6469, 6482, 6999, 5635, 5639, 5635, 5635, 5635, 6461, 5725, 5635, 5635, 5635, 6768, 7012, 7040, 5635, 5635, 6547, 6501, 7041, 5635, 5635, 5635, 6769, 5635, 7008, 7017, 7042, 5635, 5848, 5748, 6255, 5483, 5635, 5635, 6245, 6247, 5635, 7021, 5933, 6053, 5904, 6935, 6879, 5792, 5644, 5648, 7055, 7046, 5645, 7052, 7056, 7047, 5646, 7053, 7057, 7048, 5724, 5635, 5635, 5635, 6783, 6486, 5734, 5820, 5635, 5904, 6935, 6879, 5748, 6879, 5793, 5635, 6566, 5635, 5757, 5635, 5635, 5724, 5756, 5635, 5277, 5635, 5635, 5635, 7176, 7094, 7061, 7048, 5635, 5635, 6548, 6502, 5649, 6103, 7067, 7048, 5635, 7061, 6564, 5635, 5635, 6568, 5635, 5646, 5650, 7066, 7124, 5635, 7065, 7123, 5635, 5635, 6584, 5635, 5635, 6987, 7154, 5635, 5881, 5635, 5635, 6365, 5635, 6878, 5318, 6615, 5635, 5899, 5962, 5635, 5602, 5635, 5635, 5188, 5635, 7077, 5635, 5635, 5635, 6794, 5647, 7076, 7069, 5635, 5900, 6053, 5726, 5646, 7075, 7068, 5635, 5635, 6879, 5635, 5635, 5635, 6799, 6809, 5635, 7176, 7081, 5635, 5901, 7114, 6434, 5635, 5635, 7176, 7089, 5635, 5902, 5511, 6435, 5635, 5635, 5757, 5274, 5635, 6088, 7088, 5635, 5902, 5635, 5635, 5635, 6800, 5635, 6088, 7154, 5635, 5903, 5635, 5906, 6616, 6614, 5820, 5904, 6880, 5635, 5908, 5635, 5635, 5924, 7029, 6033, 5640, 7178, 5635, 5635, 6614, 5635, 5635, 6088, 7093, 5635, 5908, 6605, 7327, 7177, 7095, 5635, 5901, 5902, 5635, 5640, 6218, 5821, 6880, 5635, 5635, 6615, 6616, 5635, 5635, 6259, 5635, 5635, 6259, 5635, 5903, 5635, 5635, 5635, 5745, 5640, 7178, 6772, 5238, 5635, 7100, 6880, 5635, 5913, 6687, 5635, 6700, 5635, 5635, 6135, 5635, 5635, 6681, 5635, 5635, 6820, 7094, 5635, 5928, 5635, 5635, 5608, 6878, 5635, 7100, 6881, 5635, 7115, 5635, 5635, 7254, 7106, 5635, 5635, 5635, 6821, 6073, 6820, 7275, 5635, 5635, 5635, 6820, 6309, 6133, 7095, 6880, 5635, 5943, 5410, 5949, 5635, 5635, 5635, 7252, 5635, 5635, 7120, 5635, 5635, 7273, 7120, 6878, 5635, 5635, 6693, 5635, 5635, 5635, 7274, 5635, 5635, 6695, 5635, 5635, 5819, 5809, 5635, 7138, 5635, 6963, 5905, 6209, 5635, 6961, 5635, 5979, 6253, 5635, 5635, 7002, 6744, 5798, 5240, 5635, 6021, 5499, 7109, 5673, 5635, 7142, 5635, 6962, 6021, 6964, 6625, 6022, 7174, 7271, 7149, 7162, 7166, 7170, 7183, 7187, 7191, 7194, 7202, 7197, 7198, 7206, 7208, 7212, 7218, 7217, 7213, 7222, 7232, 7232, 7225, 7231, 7227, 7236, 7240, 5635, 5985, 5837, 5635, 5723, 5635, 5635, 6602, 6606, 7128, 7132, 5904, 5635, 5910, 5481, 7100, 7241, 5635, 5635, 6695, 5824, 6360, 5635, 5635, 5635, 6853, 6259, 6079, 5635, 6529, 7245, 7247, 7251, 5635, 5986, 5635, 5635, 5763, 6743, 5702, 5776, 5635, 7263, 5635, 5635, 6725, 5492, 7283, 7255, 5635, 5635, 6737, 5769, 7291, 5635, 7292, 5635, 5997, 6003, 6009, 6015, 5635, 7296, 7130, 5635, 5998, 6004, 6010, 5907, 5903, 5635, 5635, 6737, 6741, 5635, 6086, 5641, 5635, 5635, 5635, 7100, 5635, 5635, 6738, 6742, 6879, 5635, 7114, 5635, 7252, 5635, 5635, 6853, 6855, 5635, 6020, 5635, 5635, 5635, 7254, 5635, 6337, 5635, 5635, 6770, 5635, 6772, 5635, 6086, 6084, 5635, 5635, 6259, 5635, 7301, 6386, 5635, 5635, 5635, 6878, 5635, 5512, 7309, 6633, 5635, 6047, 5635, 5635, 5635, 7256, 7310, 6634, 5635, 5635, 5635, 6882, 5635, 7307, 7311, 6338, 6853, 5320, 5635, 5640, 7334, 5722, 5635, 5635, 6821, 6126, 5635, 5635, 6021, 6772, 7128, 7132, 5258, 5635, 5635, 5635, 6966, 5642, 5635, 5635, 7101, 5635, 6850, 5635, 6336, 5635, 6260, 5635, 6261, 7102, 5985, 6334, 5635, 5635, 5644, 7073, 7315, 7319, 6338, 5635, 6080, 5906, 5903, 7316, 6788, 5635, 5635, 6772, 5635, 6084, 7095, 5635, 5635, 5686, 5635, 7317, 6789, 5635, 5635, 6813, 5635, 7318, 6790, 6770, 6769, 5635, 5635, 6619, 5635, 6769, 6820, 5635, 5635, 6881, 7115, 5635, 6852, 6855, 5635, 5635, 5635, 6845, 5635, 6718, 6694, 5635, 5635, 5635, 6942, 6786, 6790, 5635, 5635, 5635, 6967, 5635, 5635, 6786, 6790, 6770, 6769, 7254, 5635, 7101, 5635, 7297, 7132, 5258, 7113, 5635, 5635, 6819, 5635, 5635, 5635, 5166, 6379, 5048, 5635, 5635, 6821, 6074, 6078, 5635, 5635, 5635, 5978, 7350, 5519, 7320, 5635, 6081, 5678, 6626, 7319, 5635, 5635, 5635, 7006, 7348, 5517, 6786, 6617, 5635, 6772, 6771, 5635, 6084, 6303, 6488, 5635, 7324, 5906, 5903, 5635, 6085, 5641, 5635, 6084, 6352, 5635, 5635, 5635, 6231, 5047, 5635, 5635, 5635, 7033, 5635, 7348, 7335, 5903, 5635, 6879, 5635, 6851, 5678, 5909, 6855, 6864, 5635, 7340, 5635, 5635, 6829, 5635, 6087, 5635, 6881, 5635, 6852, 6819, 6850, 5635, 5635, 6261, 7332, 7336, 5635, 5635, 5635, 7145, 5635, 6232, 5635, 5635, 6833, 5635, 5274, 5635, 5635, 5635, 7177, 0, 0, 1075838976, 2097152, 16384, 0, 0, 0, 62, 64, 4194560, 4196352, 270532608, 2097152, 2097152, 268435456, 4194432, 541065216, 541065216, 541065216, 541065216, 4194304, 4194304, 4196352, -1606418432, -1606418432, 541065216, 541065216, 4194304, 4198144, 541065216, 541065216, -2143289344, -2143289344, 8425488, 4194304, 4194304, 4194304, 541065216, 37748736, 4194304, 541065216, 4194304, 4194304, 4194432, 37748736, -1606418432, 742391808, 239075328, 775946240, 171966464, 171966464, 171966464, 171966464, 239075328, 171966464, 775946240, 239075328, 239075328, 775946240, 775946240, 775946240, 4718592, 64, 4718592, 2097216, 4720640, 4194400, 4194368, -2142763008, 541589504, 4194368, 541589504, 541589504, 541065280, 4194368, 4194368, 541065312, 541065280, -2143289280, 4194368, -2143285440, -1605890240, -2142761152, -2109731008, -1606414528, -2143285440, -2143285440, -2143285440, -1605890240, -1606414528, -1606414528, -2143285440, -2143285408, -2143285440, -2143285440, -2142761152, 776470528, -1908404416, 775946304, 775946304, -1908404416, 2, 4, 8, 16, 512, 1024, 16777216, 33554432, 402653184, 0, 0, 0, -1979711488, 0, 8192, 8392704, 0, 0x80000000, 16777216, 0, 0, 1536, 32768, 0, 0, 128, 196608, 0, 16384, 1536, 1792, 8192, 16384, 131072, 131072, 0, 0, 64, 1536, 32768, 96, 96, 0, 0, 0x80000000, 16, 0, 0, 1536, 64, 524352, 524352, 524352, 524352, 0, 524288, 64, 64, 262144, 1048576, 4194304, 16777216, 33554432, 67108864, 134217728, 536870912, 0, 128, 128, 128, 128, 2048, 1536, 1024, 0, 0, 0, 15, 208, 15360, 96, 96, 0, 64, 64, 16392, 64, 1048576, 128, 128, 0, 256, 8192, 0, 8192, 0, 33554432, 0, 1024, 1024, 0, 0, 0x80000000, 65536, 32, 96, 96, 96, 96, 64, 0, 8388608, 4096, 0, 0, 8192, 2097152, 0x80000000, 96, 524352, 524352, 524352, 524288, 524288, 524288, 64, 64, 64, 0, 0, 0, 8, 0, 0, 0, 11, 64, 64, 128, 2048, 0, 4096, 0, 0, 131072, 128, 64, 64, 64, 96, 96, 96, 524352, 524352, 524288, 64, 524288, 64, 64, 96, 524352, 0, 0, 0, 18, 33554432, 64, 96, 524352, 524288, 0, 64, 0, 2097152, 0, 0, 4, 16, 0, 0, 16, 8388608, 0, 0, 4096, 536870912, 1073741824, 0, 4, 32, 32, 4, 1073872896, 32, 40, 96, 160, 1056, 262176, 1048608, 2097184, 32, 32, 32, 524320, 32, 1073872896, 40, 262176, 1120, 96, 4195360, 6291488, 2097184, 2097184, 4194336, 4194336, 536870944, 32, 32, 40, 262176, 32, 32, 40, 262184, 1120, 96, 6292512, 4195360, 56, 262184, 40, 262184, 40, 0, 4, 262184, 40, 40, 40, 40, 4195104, 6292512, 4196128, 32, 262184, 34, 34, 40, 48, 42, 32, 32, 327155712, 34, 1056, 1056, 32, 96, 32, 32, 41, 262184, 32, 64, 512, 2048, 16384, 67108864, 42, 1056, 4194336, 32, 32, 32, 32, 56, 2098208, 42, 4457568, -326784344, -322851160, -322851160, -322698144, -322698144, -322698144, -322698144, -322695456, -322695456, -322695456, -322695456, -322597152, -320598176, -322597152, -322597144, -321548576, -320598168, -321548568, -322597144, 32, 0, 96, 32, 42, 224, 40, 262176, 42, 106, 293601323, 293601323, 293863467, 293699627, 293617707, 293716011, 297896507, 293964347, 293702267, 297896507, 293702203, 293702203, 293702203, 293702203, 293964347, 297896507, 297896507, -322597144, -322588952, -321548568, -322588952, -37744981, -322597144, -321548568, -37482773, 0, 131072, 1048576, 2097152, 0, 0, -1744830464, 0, -1744830464, 0, 318767104, 0, 0, 0, 48, 0, 1, 285212672, 0, 0, 2048, 64, 64, 64, 64, 32, 96, 0, 32, 64, 65536, 0, 0, 1, 2, 12, 16, 64, 128, 1024, 2048, 4096, 0, 2, 65536, 262656, 5242880, -1842937664, 201330721, 201330721, -2111369023, -2111369023, -2111369023, -2111369023, -2111369023, -2111369023, -2111360575, -2111369023, -2111369023, -1977151295, -1977151293, -1910042431, -1893265183, -2111368509, -1893265183, -1893265183, -1893265183, -1893265183, -2111368509, -1893265183, -1893265183, -553689472, -553656704, -553689472, -553689472, -553656704, -553656704, -553656704, -553656704, -553656704, -553656704, -553656672, -553656672, -553656672, -553656672, -553656672, -553656670, -553656608, -553656672, -553656664, -553656664, -553656672, -553656670, -553656672, -553656672, -536912159, -553656671, -536879391, -536879391, -536879391, 0, 0, 2048, 4194304, 0, 0, 0, 262656, 0, 0, 0, 536870912, 1073741824, 458880, 2097152, -1845493760, 0, 0, 4096, 2097152, 0, 0, 1, 4096, 201326592, 805306368, -1073741824, 0, 0, 0, 24576, 471424, 0, -2113929216, 0, 0, 0, 220, -1912602624, 18874368, 463488, 0, 0, 9216, 0, 0, 16384, 8192, 8192, 32768, 2048, 2048, 2048, 2048, 0, 0, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 3, 4, 16, 224, 256, 512, 32768, 0, 1040000, 15728640, -570425344, 0, 0, 0, 254, 4194304, 16777216, 33554432, 268435456, 536870912, 0x80000000, 0, 0, -570425344, 32505856, 2097152, 301989888, 0, 0, 0, 512, 0, 0, 0, 256, 12288, 0, 167772160, 234881024, 0, 0, 16384, 32768, 50331648, 0, 128, 512, 7168, 16384, 32768, 196608, 16384, 196608, 786432, 1048576, 2097152, 4194304, 8388608, 33554432, 2097152, 4194304, 8388608, 503316480, 1073741824, 0x80000000, 0, 4096, 201326592, 0, 0, 0, 167772160, 234881024, 128, 1024, 4096, 8192, 0, 0, 8192, 268435456, 0, 0, 4194304, 8388608, 234881024, 268435456, 1073741824, 0x80000000, 0, 0, 1048576, 4194304, 33554432, 268435456, 268435456, 268435456, 268435456, 0, 128, 131072, 2097152, 0, 0, 0, 520, 0, 201326592, 0, 0, 0, 1073741824, 0, 0, 0, 134217728, 128, 512, 3072, 16384, 32768, 3072, 16384, 131072, 524288, 1048576, 4194304, 16777216, 33554432, 201326592, 268435456, 1073741824, 0x80000000, 1048576, 4194304, 268435456, 536870912, 131072, 0, 0, 131072, 0, 131072, 2097152, 0, 0, 16384, 2097152, 0, 0, 2097152, 4194304, 134217728, 0x80000000, 0, 0, 0, 512, 3072, 131072, 524288, 1048576, 131072, 524288, 4194304, 0x80000000, 0, 0, 0, 16384, 16384, 18432, 0, 0, 0, 2048, 0, 0, 4096, 1048576, 0, 0, 67108864, 1073741824, 0x80000000, 0, 0, 29696, 0, 0, 32768, 50331648, 268435456, 0x80000000, 0, 0, 1, 1, 18952, 1024, 0, 65, 1024, 0, 4096, 32768, 0, 1024, 18952, 65, 268436480, 2101248, 524288, 1024, 19017, -1744550912, 8388624, 8388624, 8388624, -1739308032, -1739308032, -1739308032, -1739308032, -1736162288, -1736162288, -1736162288, -1736162288, -7868466, -7868466, -7868466, -7868466, -7868450, -7868450, -7868450, 0, 0, 0, 1610612736, 1024, 0, 2101248, 0, 0, 262144, 65536, 262144, 262144, 0, 0, 2048, 131072, 524288, 585, 0, 0, 0, 8192, 0, 0, 0, 4096, 0, 0, 0, 32, 0, 0, 0, 44, 64576, 0, 1024, 278528, -1744830464, 5521408, -1744830464, 0, 0, 2, 12, 64, 0, 1040, 8667136, -1744830464, -67108864, 0, 0, 0, 9728, 0, 2014, 0, 0, 0, 13312, 0, 1, 4, 8, 32, 64, 16384, 67108864, 134217728, 268435456, 0x80000000, 0, 0, 520, 1024, 0, 0, 2, 16, 0, 278528, 0, 0, 2, 67108864, 16384, 0, 5242880, 0x80000000, 0, 0, 327680, 0, 0, 328192, 0, 0, 0, 118, 577408, 22020096, 1040, 0, 0, 0, 16384, 0, 67108864, 1998, 518144, 8388608, 50331648, 201326592, 805306368, 0, 2, 204, 768, 1024, 10240, 1024, 10240, 16384, 32768, 458752, 8388608, 458752, 8388608, 50331648, 67108864, 134217728, 805306368, 134217728, 805306368, 1073741824, 0x80000000, 0, 220, 0, 0, 0, 32768, 33554436, 2, 12, 192, 768, 1024, 1024, 2048, 8192, 16384, 32768, 458752, 32768, 458752, 50331648, 67108864, 134217728, 134217728, 805306368, 1073741824, 0, 0, 208, 0, 0, 0, 34816, 67108864, 268435456, 0, 0, 0, 65536, 458752, 50331648, 67108864, 805306368, 1073741824, 458752, 50331648, 67108864, 536870912, 1073741824, 0, 0, 4, 8, 64, 128, 512, 2048, 196608, 262144, 33554432, 536870912, 0, 0, 0, 262144, 0, 0, 0, 64, 0, 0, 2, 4, 8, 262144, 0, 1048576, 4194304, 0, 0, 4, 8, 128, 512, 1024, 32768, 65536, 131072, 2048, 196608, 262144, 50331648, 536870912, 1073741824, 1, 4, 8, 512, 2048, 131072, 33554432, 536870912, 0, 0, 4, 8, 512, 2048, 8192, 32768, 8388608, 0, 524288, 262144, 0, 0, 4, 64, 128, 8388608, 0, 512, 2048, 131072, 536870912, 0, 0, 4194304, 8192, 2097152, 268435456, 0x80000000, 16, 33554432, -2147418112, 537395200, 537395200, 0, 4196352, 537427968, 4196352, 0, 537395200, 4196352, 4196352, 276901888, 8540160, -1606418432, 32768, 537395200, 4196352, 1082130432, 51380242, 51380242, 51380242, 22022147, 22349827, 22349827, 22349827, 22366219, 22349843, 22349827, 22349827, 22366219, 22349827, 55576594, 55576594, 55576594, 55576594, 1062785014, 324012114, 55576594, 55576594, 55576594, 1062785014, 1062785014, 1062785014, 1062785014, 0, 0, 0, 329728, 557056, 0, 0, 0, 393216, 0, 0, 17825792, 33554432, 0, 0, 0, 462976, 3, 22020096, 0, 0, 4, 134217728, 0, 0, 8, 16, 512, 402653184, 0, 0, 346112, 19, 0, 0, 8, 64, 0, 0, 0, 82, 301989888, 0, 0, 393232, 0, 0, 393240, 0, 0, 524288, 524288, 524288, 524288, 0, 577408, 22020096, 1040187392, 0, 0, 0, 524288, 0, 0, 0, 16, 0, 0, 0, 6, 16384, 32768, 268435456, 0, 268435456, 0, 1048576, 16777216, 33554432, 0, 0, 524288, 1048576, 2097152, 0, 80, 268435456, 0, 0, 524288, 536870912, 0, 112, 128, 256, 3584, 16384, 32768, 134217728, 805306368, 0, 0, 0, 1007232, 256, 1536, 2048, 16384, 32768, 262144, 0, 4, 16, 32, 64, 128, 256, 1536, 0, 16, 33554432, 0, 0, 1048576, 4194304, 0x80000000, 1536, 16384, 32768, 524288, 4194304, 33554432, 134217728, 536870912, 0, 0, 0, 32768, 0, 0, 0, 1048576, 0, 0, 0, 1998, 518144, 1, 0, 0, 65536, 262144, 0, 0, 256, 1536, 32768, 524288, 0, 0, 4194304, 134217728, 536870912, 0, 0, 1114112, 1073741824, 16, 64, 1536, 32768, 524288, 4194304, 67174400, 33554432, 1073741824, 0, 67174400, 0, 0, 16384, 1073741824, 0, 0, 2097152, 0, 1572864, 0, 1073741824, 16384, 0, 4194304, 0, 8, 0, 131072, 0, 131072, 0, 8, 131072, 131072, 134217728, 4096, 0, 8, 0, 8, 131072, 4194304, -2146430976, 131072, 134217736, 16908320, 547389524, 547389524, 555909216, 555909216, 555909216, 555909216, 564297840, 564297844, 564297844, 564297844, 564297844, 564297844, 564297844, 1001055742, 1001056254, 1001055742, 1001055742, 1001056254, 1001056254, 1001056254, 1001056254, 1001056254, 1001055742, 1, 0, 67108864, 1073741824, 0, 84, 2129920, 8388608, 536870912, 0, 96, 2260992, 0, 0, 2097152, 4194304, 8388608, 134217728, 268435456, 1280, 2809856, 58720256, 939524096, 0, 0, 0, 1052672, 0, 254, 1792, 2809856, 58720256, 939524096, 0, 939524096, 0, 0, 12, 16, 32768, 2097152, 8388608, 536870912, 0, 163840, 0, 0, 12, 32, 64, 1024, 2048, 57344, 262144, 50331648, 268435456, 1073741824, 0x80000000, 0, 52, 0, 0, 20, 64, 62, 64, 128, 1280, 8192, 16384, 131072, 524288, 58720256, 24576, 163840, 524288, 2097152, 58720256, 402653184, 58720256, 402653184, 536870912, 0, 0, 64, 128, 1792, 24576, 163840, 4, 16, 8388608, 0, 0, 2113536, 0, 0, 3735552, 0, 0, 8388608, 8388608, 4096, 4096, 4096, 4096, 0, 48, 25165824, 0, 0, 0, 1572864, 0, 6, 56, 128, 1792, 8192, 524288, 58720256, 402653184, 0, 0, 32, 128, 256, 262144, 262144, 1048576, 1073741824, 0, 0, 0, 0x80000000, 0, 0, 0, -2147483646, 4, 24, 32, 128, 1792, 1280, 8192, 524288, 16777216, 33554432, 0, 262144, 33554432, 134217728, 0, 8, 16, 1024, 16777216, 4194432, 3145728, 541065216, -2143289344, 4194304, 4194304, 4194304, 4194304, 16, 402653184, 0, 0, 32, 128, 256, 2048, 262144, 524288, 4, 16384, 65536, 67108864, 0, 0, 0, 131072, 0, 0, 0, 1024, 0, 0, 32768, 8192, 0, 2048, 0, 32, 8192, 3670016, 2048, 8192, 196608, 1048576, 0, 0, 34816, 9216, 4096, 4096, 29696, 29712, 29712, 29840, 29712, 29712, 29840, 536900624, 4224144, 144384, -754647956, -754647956, -754647956, -754647956, 144384, 144384, 144384, 144384, -754647940, -754647940, -754647940, -754647940, -754516884, -754647956, -754516884, -754516884, -754516884, 0, 0, 8388608, 1073741824, 0, 0, 67108864, 12, 16384, 0, 65536, 29824, 0, 0, 0, 3670016, 44, 64576, 319029248, -1073741824, 0, 0, 60, 0, 0, 0, 4194304, 0, 0, 0, 2014, 0, 319160320, 0, 0, 0, 5242880, 0, 4, 8, 256, 512, 2048, 8192, 16384, 458752, 50331648, 0, 524288, 3145728, 0, 0, 16384, 8, 0, 28672, 0, 0, 32, 524288, 0, 16, 0, 128, 0, 12288, 131072, 0, 0, 128, 512, 3072, 4096, 16384, 32768, 131072, 524288, 1048576, 2097152, 4194304, 262144, 318767104, -1073741824, 0, 0, 0, 28, 0, 0, 60, 64576, 28, 32, 64, 1024, 2048, 61440, 262144, 318767104, 24576, 0, 0, 0, 8388608, 0, 0, 0, 1040000, 67108864, 16384, 0, 65536, 262144, 1048576, 0, 8, 64, 2048, 4096, 8192, 65536, 131072, 1048576, 0, 0, 128, 536870912, 4194304, 131072, 0, 0, 64, 2048, 16384, 32768, 524288, 1048576, 4194304, 134217728, 0x80000000, 32768, 262144, 50331648, 268435456, 0, 32768, 8388608, 0, 0, 16777216, 16777216, 0, 0, 0, 4, 8, 16, 2, 67108864, 0, 65536, 201326592, 0x80000000, 0, 0, 1998, 59238400, -67108864, 0, 524288, 1048576, 0, 0, 64, 256, 32768, 50331648, 268435456, 0, 0, 1, 256, 0, 0, 0, 16777216, 0, 0, 256, 0, 8192, 0, 256, 262144, 2113536, 2097152, 135790592, 0, 256, 8192, 2097152, 0, 0x80000000, 0, 32768, 2097152, 0, 0x80000000, 5242880, 0, 0, 0, 128, 0, 0, 0, 208, 131073, 0, 0, 131073, 0, 135790592, 131073, 4, 0, 131073, 393233, 1610612736, 1610612736, 1610612736, 393241, 393241, 393241, 393241, 805707793, 805707793, 1879449617, 805708049, 1879449617, 1879449617, 1879449617, 1879449617, -483948553, -475559945, -475559945, -483948553, -483948553, -475559945, -483948553, -475559945, -483948553, -475559945, -475559945, -475559945, -475559945, -475559945, -215504905, -475559945, -207116297, -207116297, 0, 0, 72, 0, 4096, 4194304, 32768, 0, 0, 256, 401424, 805306368, 0, 0, 112, 25165824, 0, 1879048192, 0, 0, 116, 0, 0, 401680, 0, 0, 0, 32505856, 7, 19367920, -503316480, 0, 0, 0, 33554432, 0, 0, 33554432, 268435456, 0, 0, 0, 19376112, -234881024, 0, 0, 50331648, 268435456, 0, 27764720, -234881024, 0, 0, 512, 2048, 0, 0, 1, 2, 4, 32, 524288, 1048576, 524288, 1048576, 33554432, 67108864, 134217728, 805306368, 0, 24, 0, 0, 512, 3072, 16384, 0, 7, 16, 480, 1536, 32768, 1536, 32768, 65536, 2490368, 32768, 65536, 10878976, 16777216, 33554432, 0, 9728, 268435456, 0, 0, 67108866, 12, 64, 128, 512, 1024, 2048, 0, 16, 393216, 0, 0, 393216, 2097152, 16777216, 33554432, 536870912, -1073741824, 0, 0, 10485760, 16777216, 33554432, 1073741824, 0x80000000, 0, 16, 224, 256, 1536, 32768, 65536, 393216, 10485760, 16777216, 131072, 262144, 2097152, 16777216, 32768, 131072, 262144, 2097152, 8388608, 16777216, 0, 0, 4, 16, 224, 512, 32768, 131072, 2097152, 16777216, 192, 32768, 0, 0, 512, 4096, 4, 16, 192, 32768, 8388608, 0, 16, 64, 128, 8388608, 0, 0, 1024, 0, 4, 0, 0, 0, 3145728, 0, 4, 128, 0, 0, 268435456, 2, 0, 0, 65536, 0, 0, 0, 65, 0, 64, 128, 8388608, 16777216, 1073741824, 0, 0, 512, 2048, 32768, 262144, 524288, 8388608, 0, 0, 512, 131072, 524288, 8388608, 33554432, 0x80000000, 33554432, 33554432, 0, 2, 4, 112, 128, -2113929216, 100663296, 100663296, 2, 4, 524288, 134217728, 0, 0, 8, 512, 2048, 196608, 33554436, 0, 0, 33554436, 4224, 4224, 0, 65536, 100663296, 4224, 65536, 65536, 262144, 33554432, 0, 2, 4, 16, 64, 128, 256, 0, 4224, 65536, 16777216, 262400, 65536, 4224, -1072627712, 805306384, -1342177264, -1342177264, -1070006272, -1069989376, -1069989376, -1069989376, -258932720, -258932720, -258932720, -258932720, -1069989360, -1065795072, -1061600768, -1069989376, -225378288, -258932720, -258932720, -258932720, -225378288, 1260767, 1260767, 34815199, 1260767, 1260767, 1260767, 1260767, 34815199, 1260767, 34815199, 34815199, 34815199, 1260767, 1260767, 169032927, 1242774751, -1978450721, 169032927, -1978450721, -1978450721, -1978450721, 169032927, 169032927, 169032927, 169032927, -225231649, -1173144353, -225231649, -225231649, -91013921, 0, 0, 0, 67108864, 0, 3751936, 0, 0, 528, 7946240, 12140544, 0, 0, 0, 134217728, 0, 0, 0, 7, 27756528, -503316480, 0, 0, 9502720, 1610612736, 0, 0, 486539264, 0, 0, 2048, 32768, 0, 0, 64, 128, 0, 0, 536870912, 0, 0, 208, 15360, 1245184, 0, 0, 0, 268435456, 0, 0, 0, 15, 9633792, 0, 0, 0, 32, 512, 2048, 262144, 0, 3670016, 0, 0, 1040, 1040, 1, 2, 12, 80, 128, 7168, 8192, 196608, 16, 64, 128, 3072, 4096, 8192, 65536, 131072, 0, 0, 32, 262144, 524288, 33554432, 134217728, 0, 0, 0, 2, 8, 64, 128, 1024, 4096, 0, 0, 262144, 0, 4096, 4194304, 1, 1, 1, 0, 0, 2, 8, 16, 64
+];
+
+JSONiqParser.TOKEN =
+[
+ "(0)",
+ "PragmaContents",
+ "DirCommentContents",
+ "DirPIContents",
+ "CDataSection",
+ "Wildcard",
+ "EQName",
+ "URILiteral",
+ "IntegerLiteral",
+ "DecimalLiteral",
+ "DoubleLiteral",
+ "StringLiteral",
+ "PredefinedEntityRef",
+ "'\"\"'",
+ "EscapeApos",
+ "ElementContentChar",
+ "QuotAttrContentChar",
+ "AposAttrContentChar",
+ "PITarget",
+ "NCName",
+ "QName",
+ "S",
+ "S",
+ "CharRef",
+ "CommentContents",
+ "EOF",
+ "'!'",
+ "'!='",
+ "'\"'",
+ "'#'",
+ "'#)'",
+ "'$'",
+ "'$$'",
+ "'%'",
+ "''''",
+ "'('",
+ "'(#'",
+ "'(:'",
+ "')'",
+ "'*'",
+ "'*'",
+ "'+'",
+ "','",
+ "'-'",
+ "'-->'",
+ "'.'",
+ "'..'",
+ "'/'",
+ "'//'",
+ "'/>'",
+ "':'",
+ "':)'",
+ "'::'",
+ "':='",
+ "';'",
+ "'<'",
+ "'<!--'",
+ "'</'",
+ "'<<'",
+ "'<='",
+ "'<?'",
+ "'='",
+ "'>'",
+ "'>='",
+ "'>>'",
+ "'?'",
+ "'?>'",
+ "'@'",
+ "'NaN'",
+ "'['",
+ "']'",
+ "'after'",
+ "'all'",
+ "'allowing'",
+ "'ancestor'",
+ "'ancestor-or-self'",
+ "'and'",
+ "'any'",
+ "'append'",
+ "'array'",
+ "'as'",
+ "'ascending'",
+ "'at'",
+ "'attribute'",
+ "'base-uri'",
+ "'before'",
+ "'boundary-space'",
+ "'break'",
+ "'by'",
+ "'case'",
+ "'cast'",
+ "'castable'",
+ "'catch'",
+ "'check'",
+ "'child'",
+ "'collation'",
+ "'collection'",
+ "'comment'",
+ "'constraint'",
+ "'construction'",
+ "'contains'",
+ "'content'",
+ "'context'",
+ "'continue'",
+ "'copy'",
+ "'copy-namespaces'",
+ "'count'",
+ "'decimal-format'",
+ "'decimal-separator'",
+ "'declare'",
+ "'default'",
+ "'delete'",
+ "'descendant'",
+ "'descendant-or-self'",
+ "'descending'",
+ "'diacritics'",
+ "'different'",
+ "'digit'",
+ "'distance'",
+ "'div'",
+ "'document'",
+ "'document-node'",
+ "'element'",
+ "'else'",
+ "'empty'",
+ "'empty-sequence'",
+ "'encoding'",
+ "'end'",
+ "'entire'",
+ "'eq'",
+ "'every'",
+ "'exactly'",
+ "'except'",
+ "'exit'",
+ "'external'",
+ "'false'",
+ "'first'",
+ "'following'",
+ "'following-sibling'",
+ "'for'",
+ "'foreach'",
+ "'foreign'",
+ "'from'",
+ "'ft-option'",
+ "'ftand'",
+ "'ftnot'",
+ "'ftor'",
+ "'function'",
+ "'ge'",
+ "'greatest'",
+ "'group'",
+ "'grouping-separator'",
+ "'gt'",
+ "'idiv'",
+ "'if'",
+ "'import'",
+ "'in'",
+ "'index'",
+ "'infinity'",
+ "'inherit'",
+ "'insensitive'",
+ "'insert'",
+ "'instance'",
+ "'integrity'",
+ "'intersect'",
+ "'into'",
+ "'is'",
+ "'item'",
+ "'json'",
+ "'json-item'",
+ "'jsoniq'",
+ "'key'",
+ "'language'",
+ "'last'",
+ "'lax'",
+ "'le'",
+ "'least'",
+ "'let'",
+ "'levels'",
+ "'loop'",
+ "'lowercase'",
+ "'lt'",
+ "'minus-sign'",
+ "'mod'",
+ "'modify'",
+ "'module'",
+ "'most'",
+ "'namespace'",
+ "'namespace-node'",
+ "'ne'",
+ "'next'",
+ "'no'",
+ "'no-inherit'",
+ "'no-preserve'",
+ "'node'",
+ "'nodes'",
+ "'not'",
+ "'null'",
+ "'object'",
+ "'occurs'",
+ "'of'",
+ "'on'",
+ "'only'",
+ "'option'",
+ "'or'",
+ "'order'",
+ "'ordered'",
+ "'ordering'",
+ "'paragraph'",
+ "'paragraphs'",
+ "'parent'",
+ "'pattern-separator'",
+ "'per-mille'",
+ "'percent'",
+ "'phrase'",
+ "'position'",
+ "'preceding'",
+ "'preceding-sibling'",
+ "'preserve'",
+ "'previous'",
+ "'processing-instruction'",
+ "'relationship'",
+ "'rename'",
+ "'replace'",
+ "'return'",
+ "'returning'",
+ "'revalidation'",
+ "'same'",
+ "'satisfies'",
+ "'schema'",
+ "'schema-attribute'",
+ "'schema-element'",
+ "'score'",
+ "'select'",
+ "'self'",
+ "'sensitive'",
+ "'sentence'",
+ "'sentences'",
+ "'skip'",
+ "'sliding'",
+ "'some'",
+ "'stable'",
+ "'start'",
+ "'stemming'",
+ "'stop'",
+ "'strict'",
+ "'strip'",
+ "'structured-item'",
+ "'switch'",
+ "'text'",
+ "'then'",
+ "'thesaurus'",
+ "'times'",
+ "'to'",
+ "'treat'",
+ "'true'",
+ "'try'",
+ "'tumbling'",
+ "'type'",
+ "'typeswitch'",
+ "'union'",
+ "'unique'",
+ "'unordered'",
+ "'updating'",
+ "'uppercase'",
+ "'using'",
+ "'validate'",
+ "'value'",
+ "'variable'",
+ "'version'",
+ "'weight'",
+ "'when'",
+ "'where'",
+ "'while'",
+ "'wildcards'",
+ "'window'",
+ "'with'",
+ "'without'",
+ "'word'",
+ "'words'",
+ "'zero-digit'",
+ "'{'",
+ "'{{'",
+ "'{|'",
+ "'|'",
+ "'||'",
+ "'|}'",
+ "'}'",
+ "'}}'"
+];
+
+},{}],"/node_modules/xqlint/lib/parsers/XQueryParser.js":[function(_dereq_,module,exports){
+ var XQueryParser = exports.XQueryParser = function XQueryParser(string, parsingEventHandler)
+ {
+ init(string, parsingEventHandler);
+ var self = this;
+
+ this.ParseException = function(b, e, s, o, x)
+ {
+ var
+ begin = b,
+ end = e,
+ state = s,
+ offending = o,
+ expected = x;
+
+ this.getBegin = function() {return begin;};
+ this.getEnd = function() {return end;};
+ this.getState = function() {return state;};
+ this.getExpected = function() {return expected;};
+ this.getOffending = function() {return offending;};
+
+ this.getMessage = function()
+ {
+ return offending < 0 ? "lexical analysis failed" : "syntax error";
+ };
+ };
+
+ function init(string, parsingEventHandler)
+ {
+ eventHandler = parsingEventHandler;
+ input = string;
+ size = string.length;
+ reset(0, 0, 0);
+ }
+
+ this.getInput = function()
+ {
+ return input;
+ };
+
+ function reset(l, b, e)
+ {
+ b0 = b; e0 = b;
+ l1 = l; b1 = b; e1 = e;
+ l2 = 0;
+ end = e;
+ ex = -1;
+ memo = {};
+ eventHandler.reset(input);
+ }
+
+ this.getOffendingToken = function(e)
+ {
+ var o = e.getOffending();
+ return o >= 0 ? XQueryParser.TOKEN[o] : null;
+ };
+
+ this.getExpectedTokenSet = function(e)
+ {
+ var expected;
+ if (e.getExpected() < 0)
+ {
+ expected = XQueryParser.getTokenSet(- e.getState());
+ }
+ else
+ {
+ expected = [XQueryParser.TOKEN[e.getExpected()]];
+ }
+ return expected;
+ };
+
+ this.getErrorMessage = function(e)
+ {
+ var tokenSet = this.getExpectedTokenSet(e);
+ var found = this.getOffendingToken(e);
+ var prefix = input.substring(0, e.getBegin());
+ var lines = prefix.split("\n");
+ var line = lines.length;
+ var column = lines[line - 1].length + 1;
+ var size = e.getEnd() - e.getBegin();
+ return e.getMessage()
+ + (found == null ? "" : ", found " + found)
+ + "\nwhile expecting "
+ + (tokenSet.length == 1 ? tokenSet[0] : ("[" + tokenSet.join(", ") + "]"))
+ + "\n"
+ + (size == 0 || found != null ? "" : "after successfully scanning " + size + " characters beginning ")
+ + "at line " + line + ", column " + column + ":\n..."
+ + input.substring(e.getBegin(), Math.min(input.length, e.getBegin() + 64))
+ + "...";
+ };
+
+ this.parse_XQuery = function()
+ {
+ eventHandler.startNonterminal("XQuery", e0);
+ lookahead1W(274); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Module();
+ shift(25); // EOF
+ eventHandler.endNonterminal("XQuery", e0);
+ };
+
+ function parse_Module()
+ {
+ eventHandler.startNonterminal("Module", e0);
+ switch (l1)
+ {
+ case 274: // 'xquery'
+ lookahead2W(198); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 64274 // 'xquery' 'encoding'
+ || lk == 134930) // 'xquery' 'version'
+ {
+ parse_VersionDecl();
+ }
+ lookahead1W(274); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 182: // 'module'
+ lookahead2W(193); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 94390: // 'module' 'namespace'
+ whitespace();
+ parse_LibraryModule();
+ break;
+ default:
+ whitespace();
+ parse_MainModule();
+ }
+ eventHandler.endNonterminal("Module", e0);
+ }
+
+ function parse_VersionDecl()
+ {
+ eventHandler.startNonterminal("VersionDecl", e0);
+ shift(274); // 'xquery'
+ lookahead1W(116); // S^WS | '(:' | 'encoding' | 'version'
+ switch (l1)
+ {
+ case 125: // 'encoding'
+ shift(125); // 'encoding'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ break;
+ default:
+ shift(263); // 'version'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ lookahead1W(109); // S^WS | '(:' | ';' | 'encoding'
+ if (l1 == 125) // 'encoding'
+ {
+ shift(125); // 'encoding'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ }
+ lookahead1W(28); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ eventHandler.endNonterminal("VersionDecl", e0);
+ }
+
+ function parse_LibraryModule()
+ {
+ eventHandler.startNonterminal("LibraryModule", e0);
+ parse_ModuleDecl();
+ lookahead1W(138); // S^WS | EOF | '(:' | 'declare' | 'import'
+ whitespace();
+ parse_Prolog();
+ eventHandler.endNonterminal("LibraryModule", e0);
+ }
+
+ function parse_ModuleDecl()
+ {
+ eventHandler.startNonterminal("ModuleDecl", e0);
+ shift(182); // 'module'
+ lookahead1W(61); // S^WS | '(:' | 'namespace'
+ shift(184); // 'namespace'
+ lookahead1W(248); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(29); // S^WS | '(:' | '='
+ shift(60); // '='
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(28); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ eventHandler.endNonterminal("ModuleDecl", e0);
+ }
+
+ function parse_Prolog()
+ {
+ eventHandler.startNonterminal("Prolog", e0);
+ for (;;)
+ {
+ lookahead1W(274); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 108: // 'declare'
+ lookahead2W(213); // S^WS | EOF | '!' | '!=' | '#' | '%' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 153: // 'import'
+ lookahead2W(201); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 42604 // 'declare' 'base-uri'
+ && lk != 43628 // 'declare' 'boundary-space'
+ && lk != 50284 // 'declare' 'construction'
+ && lk != 53356 // 'declare' 'copy-namespaces'
+ && lk != 54380 // 'declare' 'decimal-format'
+ && lk != 55916 // 'declare' 'default'
+ && lk != 72300 // 'declare' 'ft-option'
+ && lk != 93337 // 'import' 'module'
+ && lk != 94316 // 'declare' 'namespace'
+ && lk != 104044 // 'declare' 'ordering'
+ && lk != 113772 // 'declare' 'revalidation'
+ && lk != 115353) // 'import' 'schema'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 108: // 'declare'
+ lookahead2W(178); // S^WS | '(:' | 'base-uri' | 'boundary-space' | 'construction' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 55916) // 'declare' 'default'
+ {
+ lk = memoized(0, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_DefaultNamespaceDecl();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(0, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ whitespace();
+ parse_DefaultNamespaceDecl();
+ break;
+ case 94316: // 'declare' 'namespace'
+ whitespace();
+ parse_NamespaceDecl();
+ break;
+ case 153: // 'import'
+ whitespace();
+ parse_Import();
+ break;
+ case 72300: // 'declare' 'ft-option'
+ whitespace();
+ parse_FTOptionDecl();
+ break;
+ default:
+ whitespace();
+ parse_Setter();
+ }
+ lookahead1W(28); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ }
+ for (;;)
+ {
+ lookahead1W(274); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 108: // 'declare'
+ lookahead2W(210); // S^WS | EOF | '!' | '!=' | '#' | '%' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 16492 // 'declare' '%'
+ && lk != 48748 // 'declare' 'collection'
+ && lk != 51820 // 'declare' 'context'
+ && lk != 74348 // 'declare' 'function'
+ && lk != 79468 // 'declare' 'index'
+ && lk != 82540 // 'declare' 'integrity'
+ && lk != 101996 // 'declare' 'option'
+ && lk != 131692 // 'declare' 'updating'
+ && lk != 134252) // 'declare' 'variable'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 108: // 'declare'
+ lookahead2W(175); // S^WS | '%' | '(:' | 'collection' | 'context' | 'function' | 'index' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 51820: // 'declare' 'context'
+ whitespace();
+ parse_ContextItemDecl();
+ break;
+ case 101996: // 'declare' 'option'
+ whitespace();
+ parse_OptionDecl();
+ break;
+ default:
+ whitespace();
+ parse_AnnotatedDecl();
+ }
+ lookahead1W(28); // S^WS | '(:' | ';'
+ whitespace();
+ parse_Separator();
+ }
+ eventHandler.endNonterminal("Prolog", e0);
+ }
+
+ function parse_Separator()
+ {
+ eventHandler.startNonterminal("Separator", e0);
+ shift(53); // ';'
+ eventHandler.endNonterminal("Separator", e0);
+ }
+
+ function parse_Setter()
+ {
+ eventHandler.startNonterminal("Setter", e0);
+ switch (l1)
+ {
+ case 108: // 'declare'
+ lookahead2W(172); // S^WS | '(:' | 'base-uri' | 'boundary-space' | 'construction' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 55916) // 'declare' 'default'
+ {
+ lk = memoized(1, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_DefaultCollationDecl();
+ lk = -2;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_EmptyOrderDecl();
+ lk = -6;
+ }
+ catch (p6A)
+ {
+ lk = -9;
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(1, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 43628: // 'declare' 'boundary-space'
+ parse_BoundarySpaceDecl();
+ break;
+ case -2:
+ parse_DefaultCollationDecl();
+ break;
+ case 42604: // 'declare' 'base-uri'
+ parse_BaseURIDecl();
+ break;
+ case 50284: // 'declare' 'construction'
+ parse_ConstructionDecl();
+ break;
+ case 104044: // 'declare' 'ordering'
+ parse_OrderingModeDecl();
+ break;
+ case -6:
+ parse_EmptyOrderDecl();
+ break;
+ case 113772: // 'declare' 'revalidation'
+ parse_RevalidationDecl();
+ break;
+ case 53356: // 'declare' 'copy-namespaces'
+ parse_CopyNamespacesDecl();
+ break;
+ default:
+ parse_DecimalFormatDecl();
+ }
+ eventHandler.endNonterminal("Setter", e0);
+ }
+
+ function parse_BoundarySpaceDecl()
+ {
+ eventHandler.startNonterminal("BoundarySpaceDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(33); // S^WS | '(:' | 'boundary-space'
+ shift(85); // 'boundary-space'
+ lookahead1W(133); // S^WS | '(:' | 'preserve' | 'strip'
+ switch (l1)
+ {
+ case 214: // 'preserve'
+ shift(214); // 'preserve'
+ break;
+ default:
+ shift(241); // 'strip'
+ }
+ eventHandler.endNonterminal("BoundarySpaceDecl", e0);
+ }
+
+ function parse_DefaultCollationDecl()
+ {
+ eventHandler.startNonterminal("DefaultCollationDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'default'
+ shift(109); // 'default'
+ lookahead1W(38); // S^WS | '(:' | 'collation'
+ shift(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("DefaultCollationDecl", e0);
+ }
+
+ function try_DefaultCollationDecl()
+ {
+ shiftT(108); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'default'
+ shiftT(109); // 'default'
+ lookahead1W(38); // S^WS | '(:' | 'collation'
+ shiftT(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+
+ function parse_BaseURIDecl()
+ {
+ eventHandler.startNonterminal("BaseURIDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(32); // S^WS | '(:' | 'base-uri'
+ shift(83); // 'base-uri'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("BaseURIDecl", e0);
+ }
+
+ function parse_ConstructionDecl()
+ {
+ eventHandler.startNonterminal("ConstructionDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(41); // S^WS | '(:' | 'construction'
+ shift(98); // 'construction'
+ lookahead1W(133); // S^WS | '(:' | 'preserve' | 'strip'
+ switch (l1)
+ {
+ case 241: // 'strip'
+ shift(241); // 'strip'
+ break;
+ default:
+ shift(214); // 'preserve'
+ }
+ eventHandler.endNonterminal("ConstructionDecl", e0);
+ }
+
+ function parse_OrderingModeDecl()
+ {
+ eventHandler.startNonterminal("OrderingModeDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(68); // S^WS | '(:' | 'ordering'
+ shift(203); // 'ordering'
+ lookahead1W(131); // S^WS | '(:' | 'ordered' | 'unordered'
+ switch (l1)
+ {
+ case 202: // 'ordered'
+ shift(202); // 'ordered'
+ break;
+ default:
+ shift(256); // 'unordered'
+ }
+ eventHandler.endNonterminal("OrderingModeDecl", e0);
+ }
+
+ function parse_EmptyOrderDecl()
+ {
+ eventHandler.startNonterminal("EmptyOrderDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'default'
+ shift(109); // 'default'
+ lookahead1W(67); // S^WS | '(:' | 'order'
+ shift(201); // 'order'
+ lookahead1W(49); // S^WS | '(:' | 'empty'
+ shift(123); // 'empty'
+ lookahead1W(121); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 147: // 'greatest'
+ shift(147); // 'greatest'
+ break;
+ default:
+ shift(173); // 'least'
+ }
+ eventHandler.endNonterminal("EmptyOrderDecl", e0);
+ }
+
+ function try_EmptyOrderDecl()
+ {
+ shiftT(108); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'default'
+ shiftT(109); // 'default'
+ lookahead1W(67); // S^WS | '(:' | 'order'
+ shiftT(201); // 'order'
+ lookahead1W(49); // S^WS | '(:' | 'empty'
+ shiftT(123); // 'empty'
+ lookahead1W(121); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 147: // 'greatest'
+ shiftT(147); // 'greatest'
+ break;
+ default:
+ shiftT(173); // 'least'
+ }
+ }
+
+ function parse_CopyNamespacesDecl()
+ {
+ eventHandler.startNonterminal("CopyNamespacesDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(44); // S^WS | '(:' | 'copy-namespaces'
+ shift(104); // 'copy-namespaces'
+ lookahead1W(128); // S^WS | '(:' | 'no-preserve' | 'preserve'
+ whitespace();
+ parse_PreserveMode();
+ lookahead1W(25); // S^WS | '(:' | ','
+ shift(41); // ','
+ lookahead1W(123); // S^WS | '(:' | 'inherit' | 'no-inherit'
+ whitespace();
+ parse_InheritMode();
+ eventHandler.endNonterminal("CopyNamespacesDecl", e0);
+ }
+
+ function parse_PreserveMode()
+ {
+ eventHandler.startNonterminal("PreserveMode", e0);
+ switch (l1)
+ {
+ case 214: // 'preserve'
+ shift(214); // 'preserve'
+ break;
+ default:
+ shift(190); // 'no-preserve'
+ }
+ eventHandler.endNonterminal("PreserveMode", e0);
+ }
+
+ function parse_InheritMode()
+ {
+ eventHandler.startNonterminal("InheritMode", e0);
+ switch (l1)
+ {
+ case 157: // 'inherit'
+ shift(157); // 'inherit'
+ break;
+ default:
+ shift(189); // 'no-inherit'
+ }
+ eventHandler.endNonterminal("InheritMode", e0);
+ }
+
+ function parse_DecimalFormatDecl()
+ {
+ eventHandler.startNonterminal("DecimalFormatDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(114); // S^WS | '(:' | 'decimal-format' | 'default'
+ switch (l1)
+ {
+ case 106: // 'decimal-format'
+ shift(106); // 'decimal-format'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ break;
+ default:
+ shift(109); // 'default'
+ lookahead1W(45); // S^WS | '(:' | 'decimal-format'
+ shift(106); // 'decimal-format'
+ }
+ for (;;)
+ {
+ lookahead1W(180); // S^WS | '(:' | ';' | 'NaN' | 'decimal-separator' | 'digit' |
+ if (l1 == 53) // ';'
+ {
+ break;
+ }
+ whitespace();
+ parse_DFPropertyName();
+ lookahead1W(29); // S^WS | '(:' | '='
+ shift(60); // '='
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ eventHandler.endNonterminal("DecimalFormatDecl", e0);
+ }
+
+ function parse_DFPropertyName()
+ {
+ eventHandler.startNonterminal("DFPropertyName", e0);
+ switch (l1)
+ {
+ case 107: // 'decimal-separator'
+ shift(107); // 'decimal-separator'
+ break;
+ case 149: // 'grouping-separator'
+ shift(149); // 'grouping-separator'
+ break;
+ case 156: // 'infinity'
+ shift(156); // 'infinity'
+ break;
+ case 179: // 'minus-sign'
+ shift(179); // 'minus-sign'
+ break;
+ case 67: // 'NaN'
+ shift(67); // 'NaN'
+ break;
+ case 209: // 'percent'
+ shift(209); // 'percent'
+ break;
+ case 208: // 'per-mille'
+ shift(208); // 'per-mille'
+ break;
+ case 275: // 'zero-digit'
+ shift(275); // 'zero-digit'
+ break;
+ case 116: // 'digit'
+ shift(116); // 'digit'
+ break;
+ default:
+ shift(207); // 'pattern-separator'
+ }
+ eventHandler.endNonterminal("DFPropertyName", e0);
+ }
+
+ function parse_Import()
+ {
+ eventHandler.startNonterminal("Import", e0);
+ switch (l1)
+ {
+ case 153: // 'import'
+ lookahead2W(126); // S^WS | '(:' | 'module' | 'schema'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 115353: // 'import' 'schema'
+ parse_SchemaImport();
+ break;
+ default:
+ parse_ModuleImport();
+ }
+ eventHandler.endNonterminal("Import", e0);
+ }
+
+ function parse_SchemaImport()
+ {
+ eventHandler.startNonterminal("SchemaImport", e0);
+ shift(153); // 'import'
+ lookahead1W(73); // S^WS | '(:' | 'schema'
+ shift(225); // 'schema'
+ lookahead1W(137); // URILiteral | S^WS | '(:' | 'default' | 'namespace'
+ if (l1 != 7) // URILiteral
+ {
+ whitespace();
+ parse_SchemaPrefix();
+ }
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(108); // S^WS | '(:' | ';' | 'at'
+ if (l1 == 81) // 'at'
+ {
+ shift(81); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ for (;;)
+ {
+ lookahead1W(103); // S^WS | '(:' | ',' | ';'
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ }
+ eventHandler.endNonterminal("SchemaImport", e0);
+ }
+
+ function parse_SchemaPrefix()
+ {
+ eventHandler.startNonterminal("SchemaPrefix", e0);
+ switch (l1)
+ {
+ case 184: // 'namespace'
+ shift(184); // 'namespace'
+ lookahead1W(248); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(29); // S^WS | '(:' | '='
+ shift(60); // '='
+ break;
+ default:
+ shift(109); // 'default'
+ lookahead1W(47); // S^WS | '(:' | 'element'
+ shift(121); // 'element'
+ lookahead1W(61); // S^WS | '(:' | 'namespace'
+ shift(184); // 'namespace'
+ }
+ eventHandler.endNonterminal("SchemaPrefix", e0);
+ }
+
+ function parse_ModuleImport()
+ {
+ eventHandler.startNonterminal("ModuleImport", e0);
+ shift(153); // 'import'
+ lookahead1W(60); // S^WS | '(:' | 'module'
+ shift(182); // 'module'
+ lookahead1W(90); // URILiteral | S^WS | '(:' | 'namespace'
+ if (l1 == 184) // 'namespace'
+ {
+ shift(184); // 'namespace'
+ lookahead1W(248); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(29); // S^WS | '(:' | '='
+ shift(60); // '='
+ }
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(108); // S^WS | '(:' | ';' | 'at'
+ if (l1 == 81) // 'at'
+ {
+ shift(81); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ for (;;)
+ {
+ lookahead1W(103); // S^WS | '(:' | ',' | ';'
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ }
+ eventHandler.endNonterminal("ModuleImport", e0);
+ }
+
+ function parse_NamespaceDecl()
+ {
+ eventHandler.startNonterminal("NamespaceDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(61); // S^WS | '(:' | 'namespace'
+ shift(184); // 'namespace'
+ lookahead1W(248); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NCName();
+ lookahead1W(29); // S^WS | '(:' | '='
+ shift(60); // '='
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("NamespaceDecl", e0);
+ }
+
+ function parse_DefaultNamespaceDecl()
+ {
+ eventHandler.startNonterminal("DefaultNamespaceDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'default'
+ shift(109); // 'default'
+ lookahead1W(115); // S^WS | '(:' | 'element' | 'function'
+ switch (l1)
+ {
+ case 121: // 'element'
+ shift(121); // 'element'
+ break;
+ default:
+ shift(145); // 'function'
+ }
+ lookahead1W(61); // S^WS | '(:' | 'namespace'
+ shift(184); // 'namespace'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("DefaultNamespaceDecl", e0);
+ }
+
+ function try_DefaultNamespaceDecl()
+ {
+ shiftT(108); // 'declare'
+ lookahead1W(46); // S^WS | '(:' | 'default'
+ shiftT(109); // 'default'
+ lookahead1W(115); // S^WS | '(:' | 'element' | 'function'
+ switch (l1)
+ {
+ case 121: // 'element'
+ shiftT(121); // 'element'
+ break;
+ default:
+ shiftT(145); // 'function'
+ }
+ lookahead1W(61); // S^WS | '(:' | 'namespace'
+ shiftT(184); // 'namespace'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+
+ function parse_FTOptionDecl()
+ {
+ eventHandler.startNonterminal("FTOptionDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(52); // S^WS | '(:' | 'ft-option'
+ shift(141); // 'ft-option'
+ lookahead1W(81); // S^WS | '(:' | 'using'
+ whitespace();
+ parse_FTMatchOptions();
+ eventHandler.endNonterminal("FTOptionDecl", e0);
+ }
+
+ function parse_AnnotatedDecl()
+ {
+ eventHandler.startNonterminal("AnnotatedDecl", e0);
+ shift(108); // 'declare'
+ for (;;)
+ {
+ lookahead1W(170); // S^WS | '%' | '(:' | 'collection' | 'function' | 'index' | 'integrity' |
+ if (l1 != 32 // '%'
+ && l1 != 257) // 'updating'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 257: // 'updating'
+ whitespace();
+ parse_CompatibilityAnnotation();
+ break;
+ default:
+ whitespace();
+ parse_Annotation();
+ }
+ }
+ switch (l1)
+ {
+ case 262: // 'variable'
+ whitespace();
+ parse_VarDecl();
+ break;
+ case 145: // 'function'
+ whitespace();
+ parse_FunctionDecl();
+ break;
+ case 95: // 'collection'
+ whitespace();
+ parse_CollectionDecl();
+ break;
+ case 155: // 'index'
+ whitespace();
+ parse_IndexDecl();
+ break;
+ default:
+ whitespace();
+ parse_ICDecl();
+ }
+ eventHandler.endNonterminal("AnnotatedDecl", e0);
+ }
+
+ function parse_CompatibilityAnnotation()
+ {
+ eventHandler.startNonterminal("CompatibilityAnnotation", e0);
+ shift(257); // 'updating'
+ eventHandler.endNonterminal("CompatibilityAnnotation", e0);
+ }
+
+ function parse_Annotation()
+ {
+ eventHandler.startNonterminal("Annotation", e0);
+ shift(32); // '%'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(171); // S^WS | '%' | '(' | '(:' | 'collection' | 'function' | 'index' | 'integrity' |
+ if (l1 == 34) // '('
+ {
+ shift(34); // '('
+ lookahead1W(154); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:'
+ whitespace();
+ parse_Literal();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(154); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:'
+ whitespace();
+ parse_Literal();
+ }
+ shift(37); // ')'
+ }
+ eventHandler.endNonterminal("Annotation", e0);
+ }
+
+ function try_Annotation()
+ {
+ shiftT(32); // '%'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_EQName();
+ lookahead1W(171); // S^WS | '%' | '(' | '(:' | 'collection' | 'function' | 'index' | 'integrity' |
+ if (l1 == 34) // '('
+ {
+ shiftT(34); // '('
+ lookahead1W(154); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:'
+ try_Literal();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(154); // IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral | S^WS | '(:'
+ try_Literal();
+ }
+ shiftT(37); // ')'
+ }
+ }
+
+ function parse_VarDecl()
+ {
+ eventHandler.startNonterminal("VarDecl", e0);
+ shift(262); // 'variable'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(147); // S^WS | '(:' | ':=' | 'as' | 'external'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(106); // S^WS | '(:' | ':=' | 'external'
+ switch (l1)
+ {
+ case 52: // ':='
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_VarValue();
+ break;
+ default:
+ shift(133); // 'external'
+ lookahead1W(104); // S^WS | '(:' | ':=' | ';'
+ if (l1 == 52) // ':='
+ {
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_VarDefaultValue();
+ }
+ }
+ eventHandler.endNonterminal("VarDecl", e0);
+ }
+
+ function parse_VarValue()
+ {
+ eventHandler.startNonterminal("VarValue", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("VarValue", e0);
+ }
+
+ function parse_VarDefaultValue()
+ {
+ eventHandler.startNonterminal("VarDefaultValue", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("VarDefaultValue", e0);
+ }
+
+ function parse_ContextItemDecl()
+ {
+ eventHandler.startNonterminal("ContextItemDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(43); // S^WS | '(:' | 'context'
+ shift(101); // 'context'
+ lookahead1W(55); // S^WS | '(:' | 'item'
+ shift(165); // 'item'
+ lookahead1W(147); // S^WS | '(:' | ':=' | 'as' | 'external'
+ if (l1 == 79) // 'as'
+ {
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ItemType();
+ }
+ lookahead1W(106); // S^WS | '(:' | ':=' | 'external'
+ switch (l1)
+ {
+ case 52: // ':='
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_VarValue();
+ break;
+ default:
+ shift(133); // 'external'
+ lookahead1W(104); // S^WS | '(:' | ':=' | ';'
+ if (l1 == 52) // ':='
+ {
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_VarDefaultValue();
+ }
+ }
+ eventHandler.endNonterminal("ContextItemDecl", e0);
+ }
+
+ function parse_ParamList()
+ {
+ eventHandler.startNonterminal("ParamList", e0);
+ parse_Param();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_Param();
+ }
+ eventHandler.endNonterminal("ParamList", e0);
+ }
+
+ function try_ParamList()
+ {
+ try_Param();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_Param();
+ }
+ }
+
+ function parse_Param()
+ {
+ eventHandler.startNonterminal("Param", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(143); // S^WS | '(:' | ')' | ',' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ eventHandler.endNonterminal("Param", e0);
+ }
+
+ function try_Param()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_EQName();
+ lookahead1W(143); // S^WS | '(:' | ')' | ',' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ }
+
+ function parse_FunctionBody()
+ {
+ eventHandler.startNonterminal("FunctionBody", e0);
+ parse_EnclosedExpr();
+ eventHandler.endNonterminal("FunctionBody", e0);
+ }
+
+ function try_FunctionBody()
+ {
+ try_EnclosedExpr();
+ }
+
+ function parse_EnclosedExpr()
+ {
+ eventHandler.startNonterminal("EnclosedExpr", e0);
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("EnclosedExpr", e0);
+ }
+
+ function try_EnclosedExpr()
+ {
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+
+ function parse_OptionDecl()
+ {
+ eventHandler.startNonterminal("OptionDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(66); // S^WS | '(:' | 'option'
+ shift(199); // 'option'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ eventHandler.endNonterminal("OptionDecl", e0);
+ }
+
+ function parse_Expr()
+ {
+ eventHandler.startNonterminal("Expr", e0);
+ parse_ExprSingle();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("Expr", e0);
+ }
+
+ function try_Expr()
+ {
+ try_ExprSingle();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ }
+
+ function parse_FLWORExpr()
+ {
+ eventHandler.startNonterminal("FLWORExpr", e0);
+ parse_InitialClause();
+ for (;;)
+ {
+ lookahead1W(173); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 220) // 'return'
+ {
+ break;
+ }
+ whitespace();
+ parse_IntermediateClause();
+ }
+ whitespace();
+ parse_ReturnClause();
+ eventHandler.endNonterminal("FLWORExpr", e0);
+ }
+
+ function try_FLWORExpr()
+ {
+ try_InitialClause();
+ for (;;)
+ {
+ lookahead1W(173); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 220) // 'return'
+ {
+ break;
+ }
+ try_IntermediateClause();
+ }
+ try_ReturnClause();
+ }
+
+ function parse_InitialClause()
+ {
+ eventHandler.startNonterminal("InitialClause", e0);
+ switch (l1)
+ {
+ case 137: // 'for'
+ lookahead2W(141); // S^WS | '$' | '(:' | 'sliding' | 'tumbling'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16009: // 'for' '$'
+ parse_ForClause();
+ break;
+ case 174: // 'let'
+ parse_LetClause();
+ break;
+ default:
+ parse_WindowClause();
+ }
+ eventHandler.endNonterminal("InitialClause", e0);
+ }
+
+ function try_InitialClause()
+ {
+ switch (l1)
+ {
+ case 137: // 'for'
+ lookahead2W(141); // S^WS | '$' | '(:' | 'sliding' | 'tumbling'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16009: // 'for' '$'
+ try_ForClause();
+ break;
+ case 174: // 'let'
+ try_LetClause();
+ break;
+ default:
+ try_WindowClause();
+ }
+ }
+
+ function parse_IntermediateClause()
+ {
+ eventHandler.startNonterminal("IntermediateClause", e0);
+ switch (l1)
+ {
+ case 137: // 'for'
+ case 174: // 'let'
+ parse_InitialClause();
+ break;
+ case 266: // 'where'
+ parse_WhereClause();
+ break;
+ case 148: // 'group'
+ parse_GroupByClause();
+ break;
+ case 105: // 'count'
+ parse_CountClause();
+ break;
+ default:
+ parse_OrderByClause();
+ }
+ eventHandler.endNonterminal("IntermediateClause", e0);
+ }
+
+ function try_IntermediateClause()
+ {
+ switch (l1)
+ {
+ case 137: // 'for'
+ case 174: // 'let'
+ try_InitialClause();
+ break;
+ case 266: // 'where'
+ try_WhereClause();
+ break;
+ case 148: // 'group'
+ try_GroupByClause();
+ break;
+ case 105: // 'count'
+ try_CountClause();
+ break;
+ default:
+ try_OrderByClause();
+ }
+ }
+
+ function parse_ForClause()
+ {
+ eventHandler.startNonterminal("ForClause", e0);
+ shift(137); // 'for'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_ForBinding();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_ForBinding();
+ }
+ eventHandler.endNonterminal("ForClause", e0);
+ }
+
+ function try_ForClause()
+ {
+ shiftT(137); // 'for'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_ForBinding();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_ForBinding();
+ }
+ }
+
+ function parse_ForBinding()
+ {
+ eventHandler.startNonterminal("ForBinding", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(164); // S^WS | '(:' | 'allowing' | 'as' | 'at' | 'in' | 'score'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(158); // S^WS | '(:' | 'allowing' | 'at' | 'in' | 'score'
+ if (l1 == 72) // 'allowing'
+ {
+ whitespace();
+ parse_AllowingEmpty();
+ }
+ lookahead1W(150); // S^WS | '(:' | 'at' | 'in' | 'score'
+ if (l1 == 81) // 'at'
+ {
+ whitespace();
+ parse_PositionalVar();
+ }
+ lookahead1W(122); // S^WS | '(:' | 'in' | 'score'
+ if (l1 == 228) // 'score'
+ {
+ whitespace();
+ parse_FTScoreVar();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shift(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ForBinding", e0);
+ }
+
+ function try_ForBinding()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(164); // S^WS | '(:' | 'allowing' | 'as' | 'at' | 'in' | 'score'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(158); // S^WS | '(:' | 'allowing' | 'at' | 'in' | 'score'
+ if (l1 == 72) // 'allowing'
+ {
+ try_AllowingEmpty();
+ }
+ lookahead1W(150); // S^WS | '(:' | 'at' | 'in' | 'score'
+ if (l1 == 81) // 'at'
+ {
+ try_PositionalVar();
+ }
+ lookahead1W(122); // S^WS | '(:' | 'in' | 'score'
+ if (l1 == 228) // 'score'
+ {
+ try_FTScoreVar();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shiftT(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_AllowingEmpty()
+ {
+ eventHandler.startNonterminal("AllowingEmpty", e0);
+ shift(72); // 'allowing'
+ lookahead1W(49); // S^WS | '(:' | 'empty'
+ shift(123); // 'empty'
+ eventHandler.endNonterminal("AllowingEmpty", e0);
+ }
+
+ function try_AllowingEmpty()
+ {
+ shiftT(72); // 'allowing'
+ lookahead1W(49); // S^WS | '(:' | 'empty'
+ shiftT(123); // 'empty'
+ }
+
+ function parse_PositionalVar()
+ {
+ eventHandler.startNonterminal("PositionalVar", e0);
+ shift(81); // 'at'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("PositionalVar", e0);
+ }
+
+ function try_PositionalVar()
+ {
+ shiftT(81); // 'at'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_FTScoreVar()
+ {
+ eventHandler.startNonterminal("FTScoreVar", e0);
+ shift(228); // 'score'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("FTScoreVar", e0);
+ }
+
+ function try_FTScoreVar()
+ {
+ shiftT(228); // 'score'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_LetClause()
+ {
+ eventHandler.startNonterminal("LetClause", e0);
+ shift(174); // 'let'
+ lookahead1W(96); // S^WS | '$' | '(:' | 'score'
+ whitespace();
+ parse_LetBinding();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(96); // S^WS | '$' | '(:' | 'score'
+ whitespace();
+ parse_LetBinding();
+ }
+ eventHandler.endNonterminal("LetClause", e0);
+ }
+
+ function try_LetClause()
+ {
+ shiftT(174); // 'let'
+ lookahead1W(96); // S^WS | '$' | '(:' | 'score'
+ try_LetBinding();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(96); // S^WS | '$' | '(:' | 'score'
+ try_LetBinding();
+ }
+ }
+
+ function parse_LetBinding()
+ {
+ eventHandler.startNonterminal("LetBinding", e0);
+ switch (l1)
+ {
+ case 31: // '$'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(105); // S^WS | '(:' | ':=' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ break;
+ default:
+ parse_FTScoreVar();
+ }
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("LetBinding", e0);
+ }
+
+ function try_LetBinding()
+ {
+ switch (l1)
+ {
+ case 31: // '$'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(105); // S^WS | '(:' | ':=' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ break;
+ default:
+ try_FTScoreVar();
+ }
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_WindowClause()
+ {
+ eventHandler.startNonterminal("WindowClause", e0);
+ shift(137); // 'for'
+ lookahead1W(135); // S^WS | '(:' | 'sliding' | 'tumbling'
+ switch (l1)
+ {
+ case 251: // 'tumbling'
+ whitespace();
+ parse_TumblingWindowClause();
+ break;
+ default:
+ whitespace();
+ parse_SlidingWindowClause();
+ }
+ eventHandler.endNonterminal("WindowClause", e0);
+ }
+
+ function try_WindowClause()
+ {
+ shiftT(137); // 'for'
+ lookahead1W(135); // S^WS | '(:' | 'sliding' | 'tumbling'
+ switch (l1)
+ {
+ case 251: // 'tumbling'
+ try_TumblingWindowClause();
+ break;
+ default:
+ try_SlidingWindowClause();
+ }
+ }
+
+ function parse_TumblingWindowClause()
+ {
+ eventHandler.startNonterminal("TumblingWindowClause", e0);
+ shift(251); // 'tumbling'
+ lookahead1W(85); // S^WS | '(:' | 'window'
+ shift(269); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(110); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shift(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ whitespace();
+ parse_WindowStartCondition();
+ if (l1 == 126 // 'end'
+ || l1 == 198) // 'only'
+ {
+ whitespace();
+ parse_WindowEndCondition();
+ }
+ eventHandler.endNonterminal("TumblingWindowClause", e0);
+ }
+
+ function try_TumblingWindowClause()
+ {
+ shiftT(251); // 'tumbling'
+ lookahead1W(85); // S^WS | '(:' | 'window'
+ shiftT(269); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(110); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shiftT(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ try_WindowStartCondition();
+ if (l1 == 126 // 'end'
+ || l1 == 198) // 'only'
+ {
+ try_WindowEndCondition();
+ }
+ }
+
+ function parse_SlidingWindowClause()
+ {
+ eventHandler.startNonterminal("SlidingWindowClause", e0);
+ shift(234); // 'sliding'
+ lookahead1W(85); // S^WS | '(:' | 'window'
+ shift(269); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(110); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shift(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ whitespace();
+ parse_WindowStartCondition();
+ whitespace();
+ parse_WindowEndCondition();
+ eventHandler.endNonterminal("SlidingWindowClause", e0);
+ }
+
+ function try_SlidingWindowClause()
+ {
+ shiftT(234); // 'sliding'
+ lookahead1W(85); // S^WS | '(:' | 'window'
+ shiftT(269); // 'window'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(110); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shiftT(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ try_WindowStartCondition();
+ try_WindowEndCondition();
+ }
+
+ function parse_WindowStartCondition()
+ {
+ eventHandler.startNonterminal("WindowStartCondition", e0);
+ shift(237); // 'start'
+ lookahead1W(163); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ whitespace();
+ parse_WindowVars();
+ lookahead1W(83); // S^WS | '(:' | 'when'
+ shift(265); // 'when'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("WindowStartCondition", e0);
+ }
+
+ function try_WindowStartCondition()
+ {
+ shiftT(237); // 'start'
+ lookahead1W(163); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ try_WindowVars();
+ lookahead1W(83); // S^WS | '(:' | 'when'
+ shiftT(265); // 'when'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_WindowEndCondition()
+ {
+ eventHandler.startNonterminal("WindowEndCondition", e0);
+ if (l1 == 198) // 'only'
+ {
+ shift(198); // 'only'
+ }
+ lookahead1W(50); // S^WS | '(:' | 'end'
+ shift(126); // 'end'
+ lookahead1W(163); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ whitespace();
+ parse_WindowVars();
+ lookahead1W(83); // S^WS | '(:' | 'when'
+ shift(265); // 'when'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("WindowEndCondition", e0);
+ }
+
+ function try_WindowEndCondition()
+ {
+ if (l1 == 198) // 'only'
+ {
+ shiftT(198); // 'only'
+ }
+ lookahead1W(50); // S^WS | '(:' | 'end'
+ shiftT(126); // 'end'
+ lookahead1W(163); // S^WS | '$' | '(:' | 'at' | 'next' | 'previous' | 'when'
+ try_WindowVars();
+ lookahead1W(83); // S^WS | '(:' | 'when'
+ shiftT(265); // 'when'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_WindowVars()
+ {
+ eventHandler.startNonterminal("WindowVars", e0);
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_CurrentItem();
+ }
+ lookahead1W(159); // S^WS | '(:' | 'at' | 'next' | 'previous' | 'when'
+ if (l1 == 81) // 'at'
+ {
+ whitespace();
+ parse_PositionalVar();
+ }
+ lookahead1W(153); // S^WS | '(:' | 'next' | 'previous' | 'when'
+ if (l1 == 215) // 'previous'
+ {
+ shift(215); // 'previous'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_PreviousItem();
+ }
+ lookahead1W(127); // S^WS | '(:' | 'next' | 'when'
+ if (l1 == 187) // 'next'
+ {
+ shift(187); // 'next'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NextItem();
+ }
+ eventHandler.endNonterminal("WindowVars", e0);
+ }
+
+ function try_WindowVars()
+ {
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CurrentItem();
+ }
+ lookahead1W(159); // S^WS | '(:' | 'at' | 'next' | 'previous' | 'when'
+ if (l1 == 81) // 'at'
+ {
+ try_PositionalVar();
+ }
+ lookahead1W(153); // S^WS | '(:' | 'next' | 'previous' | 'when'
+ if (l1 == 215) // 'previous'
+ {
+ shiftT(215); // 'previous'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_PreviousItem();
+ }
+ lookahead1W(127); // S^WS | '(:' | 'next' | 'when'
+ if (l1 == 187) // 'next'
+ {
+ shiftT(187); // 'next'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NextItem();
+ }
+ }
+
+ function parse_CurrentItem()
+ {
+ eventHandler.startNonterminal("CurrentItem", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("CurrentItem", e0);
+ }
+
+ function try_CurrentItem()
+ {
+ try_EQName();
+ }
+
+ function parse_PreviousItem()
+ {
+ eventHandler.startNonterminal("PreviousItem", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("PreviousItem", e0);
+ }
+
+ function try_PreviousItem()
+ {
+ try_EQName();
+ }
+
+ function parse_NextItem()
+ {
+ eventHandler.startNonterminal("NextItem", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("NextItem", e0);
+ }
+
+ function try_NextItem()
+ {
+ try_EQName();
+ }
+
+ function parse_CountClause()
+ {
+ eventHandler.startNonterminal("CountClause", e0);
+ shift(105); // 'count'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("CountClause", e0);
+ }
+
+ function try_CountClause()
+ {
+ shiftT(105); // 'count'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_WhereClause()
+ {
+ eventHandler.startNonterminal("WhereClause", e0);
+ shift(266); // 'where'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("WhereClause", e0);
+ }
+
+ function try_WhereClause()
+ {
+ shiftT(266); // 'where'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_GroupByClause()
+ {
+ eventHandler.startNonterminal("GroupByClause", e0);
+ shift(148); // 'group'
+ lookahead1W(34); // S^WS | '(:' | 'by'
+ shift(87); // 'by'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_GroupingSpecList();
+ eventHandler.endNonterminal("GroupByClause", e0);
+ }
+
+ function try_GroupByClause()
+ {
+ shiftT(148); // 'group'
+ lookahead1W(34); // S^WS | '(:' | 'by'
+ shiftT(87); // 'by'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_GroupingSpecList();
+ }
+
+ function parse_GroupingSpecList()
+ {
+ eventHandler.startNonterminal("GroupingSpecList", e0);
+ parse_GroupingSpec();
+ for (;;)
+ {
+ lookahead1W(176); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_GroupingSpec();
+ }
+ eventHandler.endNonterminal("GroupingSpecList", e0);
+ }
+
+ function try_GroupingSpecList()
+ {
+ try_GroupingSpec();
+ for (;;)
+ {
+ lookahead1W(176); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_GroupingSpec();
+ }
+ }
+
+ function parse_GroupingSpec()
+ {
+ eventHandler.startNonterminal("GroupingSpec", e0);
+ switch (l1)
+ {
+ case 31: // '$'
+ lookahead2W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 3103 // '$' EQName^Token
+ || lk == 35871 // '$' 'after'
+ || lk == 36895 // '$' 'allowing'
+ || lk == 37407 // '$' 'ancestor'
+ || lk == 37919 // '$' 'ancestor-or-self'
+ || lk == 38431 // '$' 'and'
+ || lk == 39455 // '$' 'append'
+ || lk == 39967 // '$' 'array'
+ || lk == 40479 // '$' 'as'
+ || lk == 40991 // '$' 'ascending'
+ || lk == 41503 // '$' 'at'
+ || lk == 42015 // '$' 'attribute'
+ || lk == 42527 // '$' 'base-uri'
+ || lk == 43039 // '$' 'before'
+ || lk == 43551 // '$' 'boundary-space'
+ || lk == 44063 // '$' 'break'
+ || lk == 45087 // '$' 'case'
+ || lk == 45599 // '$' 'cast'
+ || lk == 46111 // '$' 'castable'
+ || lk == 46623 // '$' 'catch'
+ || lk == 47647 // '$' 'child'
+ || lk == 48159 // '$' 'collation'
+ || lk == 49183 // '$' 'comment'
+ || lk == 49695 // '$' 'constraint'
+ || lk == 50207 // '$' 'construction'
+ || lk == 51743 // '$' 'context'
+ || lk == 52255 // '$' 'continue'
+ || lk == 52767 // '$' 'copy'
+ || lk == 53279 // '$' 'copy-namespaces'
+ || lk == 53791 // '$' 'count'
+ || lk == 54303 // '$' 'decimal-format'
+ || lk == 55327 // '$' 'declare'
+ || lk == 55839 // '$' 'default'
+ || lk == 56351 // '$' 'delete'
+ || lk == 56863 // '$' 'descendant'
+ || lk == 57375 // '$' 'descendant-or-self'
+ || lk == 57887 // '$' 'descending'
+ || lk == 60447 // '$' 'div'
+ || lk == 60959 // '$' 'document'
+ || lk == 61471 // '$' 'document-node'
+ || lk == 61983 // '$' 'element'
+ || lk == 62495 // '$' 'else'
+ || lk == 63007 // '$' 'empty'
+ || lk == 63519 // '$' 'empty-sequence'
+ || lk == 64031 // '$' 'encoding'
+ || lk == 64543 // '$' 'end'
+ || lk == 65567 // '$' 'eq'
+ || lk == 66079 // '$' 'every'
+ || lk == 67103 // '$' 'except'
+ || lk == 67615 // '$' 'exit'
+ || lk == 68127 // '$' 'external'
+ || lk == 68639 // '$' 'first'
+ || lk == 69151 // '$' 'following'
+ || lk == 69663 // '$' 'following-sibling'
+ || lk == 70175 // '$' 'for'
+ || lk == 72223 // '$' 'ft-option'
+ || lk == 74271 // '$' 'function'
+ || lk == 74783 // '$' 'ge'
+ || lk == 75807 // '$' 'group'
+ || lk == 76831 // '$' 'gt'
+ || lk == 77343 // '$' 'idiv'
+ || lk == 77855 // '$' 'if'
+ || lk == 78367 // '$' 'import'
+ || lk == 78879 // '$' 'in'
+ || lk == 79391 // '$' 'index'
+ || lk == 81439 // '$' 'insert'
+ || lk == 81951 // '$' 'instance'
+ || lk == 82463 // '$' 'integrity'
+ || lk == 82975 // '$' 'intersect'
+ || lk == 83487 // '$' 'into'
+ || lk == 83999 // '$' 'is'
+ || lk == 84511 // '$' 'item'
+ || lk == 85023 // '$' 'json'
+ || lk == 85535 // '$' 'json-item'
+ || lk == 87071 // '$' 'last'
+ || lk == 87583 // '$' 'lax'
+ || lk == 88095 // '$' 'le'
+ || lk == 89119 // '$' 'let'
+ || lk == 90143 // '$' 'loop'
+ || lk == 91167 // '$' 'lt'
+ || lk == 92191 // '$' 'mod'
+ || lk == 92703 // '$' 'modify'
+ || lk == 93215 // '$' 'module'
+ || lk == 94239 // '$' 'namespace'
+ || lk == 94751 // '$' 'namespace-node'
+ || lk == 95263 // '$' 'ne'
+ || lk == 97823 // '$' 'node'
+ || lk == 98335 // '$' 'nodes'
+ || lk == 99359 // '$' 'object'
+ || lk == 101407 // '$' 'only'
+ || lk == 101919 // '$' 'option'
+ || lk == 102431 // '$' 'or'
+ || lk == 102943 // '$' 'order'
+ || lk == 103455 // '$' 'ordered'
+ || lk == 103967 // '$' 'ordering'
+ || lk == 105503 // '$' 'parent'
+ || lk == 108575 // '$' 'preceding'
+ || lk == 109087 // '$' 'preceding-sibling'
+ || lk == 110623 // '$' 'processing-instruction'
+ || lk == 111647 // '$' 'rename'
+ || lk == 112159 // '$' 'replace'
+ || lk == 112671 // '$' 'return'
+ || lk == 113183 // '$' 'returning'
+ || lk == 113695 // '$' 'revalidation'
+ || lk == 114719 // '$' 'satisfies'
+ || lk == 115231 // '$' 'schema'
+ || lk == 115743 // '$' 'schema-attribute'
+ || lk == 116255 // '$' 'schema-element'
+ || lk == 116767 // '$' 'score'
+ || lk == 117279 // '$' 'self'
+ || lk == 119839 // '$' 'sliding'
+ || lk == 120351 // '$' 'some'
+ || lk == 120863 // '$' 'stable'
+ || lk == 121375 // '$' 'start'
+ || lk == 122911 // '$' 'strict'
+ || lk == 123935 // '$' 'structured-item'
+ || lk == 124447 // '$' 'switch'
+ || lk == 124959 // '$' 'text'
+ || lk == 127007 // '$' 'to'
+ || lk == 127519 // '$' 'treat'
+ || lk == 128031 // '$' 'try'
+ || lk == 128543 // '$' 'tumbling'
+ || lk == 129055 // '$' 'type'
+ || lk == 129567 // '$' 'typeswitch'
+ || lk == 130079 // '$' 'union'
+ || lk == 131103 // '$' 'unordered'
+ || lk == 131615 // '$' 'updating'
+ || lk == 133151 // '$' 'validate'
+ || lk == 133663 // '$' 'value'
+ || lk == 134175 // '$' 'variable'
+ || lk == 134687 // '$' 'version'
+ || lk == 136223 // '$' 'where'
+ || lk == 136735 // '$' 'while'
+ || lk == 138271 // '$' 'with'
+ || lk == 140319) // '$' 'xquery'
+ {
+ lk = memoized(2, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_GroupingVariable();
+ lookahead1W(182); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 52 // ':='
+ || l1 == 79) // 'as'
+ {
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ if (l1 == 94) // 'collation'
+ {
+ shiftT(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(2, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ parse_GroupingVariable();
+ lookahead1W(182); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 52 // ':='
+ || l1 == 79) // 'as'
+ {
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ if (l1 == 94) // 'collation'
+ {
+ shift(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ break;
+ default:
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("GroupingSpec", e0);
+ }
+
+ function try_GroupingSpec()
+ {
+ switch (l1)
+ {
+ case 31: // '$'
+ lookahead2W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 3103 // '$' EQName^Token
+ || lk == 35871 // '$' 'after'
+ || lk == 36895 // '$' 'allowing'
+ || lk == 37407 // '$' 'ancestor'
+ || lk == 37919 // '$' 'ancestor-or-self'
+ || lk == 38431 // '$' 'and'
+ || lk == 39455 // '$' 'append'
+ || lk == 39967 // '$' 'array'
+ || lk == 40479 // '$' 'as'
+ || lk == 40991 // '$' 'ascending'
+ || lk == 41503 // '$' 'at'
+ || lk == 42015 // '$' 'attribute'
+ || lk == 42527 // '$' 'base-uri'
+ || lk == 43039 // '$' 'before'
+ || lk == 43551 // '$' 'boundary-space'
+ || lk == 44063 // '$' 'break'
+ || lk == 45087 // '$' 'case'
+ || lk == 45599 // '$' 'cast'
+ || lk == 46111 // '$' 'castable'
+ || lk == 46623 // '$' 'catch'
+ || lk == 47647 // '$' 'child'
+ || lk == 48159 // '$' 'collation'
+ || lk == 49183 // '$' 'comment'
+ || lk == 49695 // '$' 'constraint'
+ || lk == 50207 // '$' 'construction'
+ || lk == 51743 // '$' 'context'
+ || lk == 52255 // '$' 'continue'
+ || lk == 52767 // '$' 'copy'
+ || lk == 53279 // '$' 'copy-namespaces'
+ || lk == 53791 // '$' 'count'
+ || lk == 54303 // '$' 'decimal-format'
+ || lk == 55327 // '$' 'declare'
+ || lk == 55839 // '$' 'default'
+ || lk == 56351 // '$' 'delete'
+ || lk == 56863 // '$' 'descendant'
+ || lk == 57375 // '$' 'descendant-or-self'
+ || lk == 57887 // '$' 'descending'
+ || lk == 60447 // '$' 'div'
+ || lk == 60959 // '$' 'document'
+ || lk == 61471 // '$' 'document-node'
+ || lk == 61983 // '$' 'element'
+ || lk == 62495 // '$' 'else'
+ || lk == 63007 // '$' 'empty'
+ || lk == 63519 // '$' 'empty-sequence'
+ || lk == 64031 // '$' 'encoding'
+ || lk == 64543 // '$' 'end'
+ || lk == 65567 // '$' 'eq'
+ || lk == 66079 // '$' 'every'
+ || lk == 67103 // '$' 'except'
+ || lk == 67615 // '$' 'exit'
+ || lk == 68127 // '$' 'external'
+ || lk == 68639 // '$' 'first'
+ || lk == 69151 // '$' 'following'
+ || lk == 69663 // '$' 'following-sibling'
+ || lk == 70175 // '$' 'for'
+ || lk == 72223 // '$' 'ft-option'
+ || lk == 74271 // '$' 'function'
+ || lk == 74783 // '$' 'ge'
+ || lk == 75807 // '$' 'group'
+ || lk == 76831 // '$' 'gt'
+ || lk == 77343 // '$' 'idiv'
+ || lk == 77855 // '$' 'if'
+ || lk == 78367 // '$' 'import'
+ || lk == 78879 // '$' 'in'
+ || lk == 79391 // '$' 'index'
+ || lk == 81439 // '$' 'insert'
+ || lk == 81951 // '$' 'instance'
+ || lk == 82463 // '$' 'integrity'
+ || lk == 82975 // '$' 'intersect'
+ || lk == 83487 // '$' 'into'
+ || lk == 83999 // '$' 'is'
+ || lk == 84511 // '$' 'item'
+ || lk == 85023 // '$' 'json'
+ || lk == 85535 // '$' 'json-item'
+ || lk == 87071 // '$' 'last'
+ || lk == 87583 // '$' 'lax'
+ || lk == 88095 // '$' 'le'
+ || lk == 89119 // '$' 'let'
+ || lk == 90143 // '$' 'loop'
+ || lk == 91167 // '$' 'lt'
+ || lk == 92191 // '$' 'mod'
+ || lk == 92703 // '$' 'modify'
+ || lk == 93215 // '$' 'module'
+ || lk == 94239 // '$' 'namespace'
+ || lk == 94751 // '$' 'namespace-node'
+ || lk == 95263 // '$' 'ne'
+ || lk == 97823 // '$' 'node'
+ || lk == 98335 // '$' 'nodes'
+ || lk == 99359 // '$' 'object'
+ || lk == 101407 // '$' 'only'
+ || lk == 101919 // '$' 'option'
+ || lk == 102431 // '$' 'or'
+ || lk == 102943 // '$' 'order'
+ || lk == 103455 // '$' 'ordered'
+ || lk == 103967 // '$' 'ordering'
+ || lk == 105503 // '$' 'parent'
+ || lk == 108575 // '$' 'preceding'
+ || lk == 109087 // '$' 'preceding-sibling'
+ || lk == 110623 // '$' 'processing-instruction'
+ || lk == 111647 // '$' 'rename'
+ || lk == 112159 // '$' 'replace'
+ || lk == 112671 // '$' 'return'
+ || lk == 113183 // '$' 'returning'
+ || lk == 113695 // '$' 'revalidation'
+ || lk == 114719 // '$' 'satisfies'
+ || lk == 115231 // '$' 'schema'
+ || lk == 115743 // '$' 'schema-attribute'
+ || lk == 116255 // '$' 'schema-element'
+ || lk == 116767 // '$' 'score'
+ || lk == 117279 // '$' 'self'
+ || lk == 119839 // '$' 'sliding'
+ || lk == 120351 // '$' 'some'
+ || lk == 120863 // '$' 'stable'
+ || lk == 121375 // '$' 'start'
+ || lk == 122911 // '$' 'strict'
+ || lk == 123935 // '$' 'structured-item'
+ || lk == 124447 // '$' 'switch'
+ || lk == 124959 // '$' 'text'
+ || lk == 127007 // '$' 'to'
+ || lk == 127519 // '$' 'treat'
+ || lk == 128031 // '$' 'try'
+ || lk == 128543 // '$' 'tumbling'
+ || lk == 129055 // '$' 'type'
+ || lk == 129567 // '$' 'typeswitch'
+ || lk == 130079 // '$' 'union'
+ || lk == 131103 // '$' 'unordered'
+ || lk == 131615 // '$' 'updating'
+ || lk == 133151 // '$' 'validate'
+ || lk == 133663 // '$' 'value'
+ || lk == 134175 // '$' 'variable'
+ || lk == 134687 // '$' 'version'
+ || lk == 136223 // '$' 'where'
+ || lk == 136735 // '$' 'while'
+ || lk == 138271 // '$' 'with'
+ || lk == 140319) // '$' 'xquery'
+ {
+ lk = memoized(2, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_GroupingVariable();
+ lookahead1W(182); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 52 // ':='
+ || l1 == 79) // 'as'
+ {
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ if (l1 == 94) // 'collation'
+ {
+ shiftT(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ memoize(2, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(2, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ try_GroupingVariable();
+ lookahead1W(182); // S^WS | '(:' | ',' | ':=' | 'as' | 'collation' | 'count' | 'for' | 'group' |
+ if (l1 == 52 // ':='
+ || l1 == 79) // 'as'
+ {
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ if (l1 == 94) // 'collation'
+ {
+ shiftT(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ break;
+ case -3:
+ break;
+ default:
+ try_ExprSingle();
+ }
+ }
+
+ function parse_GroupingVariable()
+ {
+ eventHandler.startNonterminal("GroupingVariable", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("GroupingVariable", e0);
+ }
+
+ function try_GroupingVariable()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_OrderByClause()
+ {
+ eventHandler.startNonterminal("OrderByClause", e0);
+ switch (l1)
+ {
+ case 201: // 'order'
+ shift(201); // 'order'
+ lookahead1W(34); // S^WS | '(:' | 'by'
+ shift(87); // 'by'
+ break;
+ default:
+ shift(236); // 'stable'
+ lookahead1W(67); // S^WS | '(:' | 'order'
+ shift(201); // 'order'
+ lookahead1W(34); // S^WS | '(:' | 'by'
+ shift(87); // 'by'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_OrderSpecList();
+ eventHandler.endNonterminal("OrderByClause", e0);
+ }
+
+ function try_OrderByClause()
+ {
+ switch (l1)
+ {
+ case 201: // 'order'
+ shiftT(201); // 'order'
+ lookahead1W(34); // S^WS | '(:' | 'by'
+ shiftT(87); // 'by'
+ break;
+ default:
+ shiftT(236); // 'stable'
+ lookahead1W(67); // S^WS | '(:' | 'order'
+ shiftT(201); // 'order'
+ lookahead1W(34); // S^WS | '(:' | 'by'
+ shiftT(87); // 'by'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_OrderSpecList();
+ }
+
+ function parse_OrderSpecList()
+ {
+ eventHandler.startNonterminal("OrderSpecList", e0);
+ parse_OrderSpec();
+ for (;;)
+ {
+ lookahead1W(176); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_OrderSpec();
+ }
+ eventHandler.endNonterminal("OrderSpecList", e0);
+ }
+
+ function try_OrderSpecList()
+ {
+ try_OrderSpec();
+ for (;;)
+ {
+ lookahead1W(176); // S^WS | '(:' | ',' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' |
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_OrderSpec();
+ }
+ }
+
+ function parse_OrderSpec()
+ {
+ eventHandler.startNonterminal("OrderSpec", e0);
+ parse_ExprSingle();
+ whitespace();
+ parse_OrderModifier();
+ eventHandler.endNonterminal("OrderSpec", e0);
+ }
+
+ function try_OrderSpec()
+ {
+ try_ExprSingle();
+ try_OrderModifier();
+ }
+
+ function parse_OrderModifier()
+ {
+ eventHandler.startNonterminal("OrderModifier", e0);
+ if (l1 == 80 // 'ascending'
+ || l1 == 113) // 'descending'
+ {
+ switch (l1)
+ {
+ case 80: // 'ascending'
+ shift(80); // 'ascending'
+ break;
+ default:
+ shift(113); // 'descending'
+ }
+ }
+ lookahead1W(179); // S^WS | '(:' | ',' | 'collation' | 'count' | 'empty' | 'for' | 'group' | 'let' |
+ if (l1 == 123) // 'empty'
+ {
+ shift(123); // 'empty'
+ lookahead1W(121); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 147: // 'greatest'
+ shift(147); // 'greatest'
+ break;
+ default:
+ shift(173); // 'least'
+ }
+ }
+ lookahead1W(177); // S^WS | '(:' | ',' | 'collation' | 'count' | 'for' | 'group' | 'let' | 'order' |
+ if (l1 == 94) // 'collation'
+ {
+ shift(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ }
+ eventHandler.endNonterminal("OrderModifier", e0);
+ }
+
+ function try_OrderModifier()
+ {
+ if (l1 == 80 // 'ascending'
+ || l1 == 113) // 'descending'
+ {
+ switch (l1)
+ {
+ case 80: // 'ascending'
+ shiftT(80); // 'ascending'
+ break;
+ default:
+ shiftT(113); // 'descending'
+ }
+ }
+ lookahead1W(179); // S^WS | '(:' | ',' | 'collation' | 'count' | 'empty' | 'for' | 'group' | 'let' |
+ if (l1 == 123) // 'empty'
+ {
+ shiftT(123); // 'empty'
+ lookahead1W(121); // S^WS | '(:' | 'greatest' | 'least'
+ switch (l1)
+ {
+ case 147: // 'greatest'
+ shiftT(147); // 'greatest'
+ break;
+ default:
+ shiftT(173); // 'least'
+ }
+ }
+ lookahead1W(177); // S^WS | '(:' | ',' | 'collation' | 'count' | 'for' | 'group' | 'let' | 'order' |
+ if (l1 == 94) // 'collation'
+ {
+ shiftT(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ }
+ }
+
+ function parse_ReturnClause()
+ {
+ eventHandler.startNonterminal("ReturnClause", e0);
+ shift(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ReturnClause", e0);
+ }
+
+ function try_ReturnClause()
+ {
+ shiftT(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_QuantifiedExpr()
+ {
+ eventHandler.startNonterminal("QuantifiedExpr", e0);
+ switch (l1)
+ {
+ case 235: // 'some'
+ shift(235); // 'some'
+ break;
+ default:
+ shift(129); // 'every'
+ }
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_QuantifiedVarDecl();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_QuantifiedVarDecl();
+ }
+ shift(224); // 'satisfies'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("QuantifiedExpr", e0);
+ }
+
+ function try_QuantifiedExpr()
+ {
+ switch (l1)
+ {
+ case 235: // 'some'
+ shiftT(235); // 'some'
+ break;
+ default:
+ shiftT(129); // 'every'
+ }
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_QuantifiedVarDecl();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_QuantifiedVarDecl();
+ }
+ shiftT(224); // 'satisfies'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_QuantifiedVarDecl()
+ {
+ eventHandler.startNonterminal("QuantifiedVarDecl", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(110); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shift(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("QuantifiedVarDecl", e0);
+ }
+
+ function try_QuantifiedVarDecl()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(110); // S^WS | '(:' | 'as' | 'in'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shiftT(154); // 'in'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SwitchExpr()
+ {
+ eventHandler.startNonterminal("SwitchExpr", e0);
+ shift(243); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_SwitchCaseClause();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shift(109); // 'default'
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shift(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SwitchExpr", e0);
+ }
+
+ function try_SwitchExpr()
+ {
+ shiftT(243); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ try_SwitchCaseClause();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(109); // 'default'
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shiftT(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SwitchCaseClause()
+ {
+ eventHandler.startNonterminal("SwitchCaseClause", e0);
+ for (;;)
+ {
+ shift(88); // 'case'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_SwitchCaseOperand();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shift(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SwitchCaseClause", e0);
+ }
+
+ function try_SwitchCaseClause()
+ {
+ for (;;)
+ {
+ shiftT(88); // 'case'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_SwitchCaseOperand();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SwitchCaseOperand()
+ {
+ eventHandler.startNonterminal("SwitchCaseOperand", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SwitchCaseOperand", e0);
+ }
+
+ function try_SwitchCaseOperand()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_TypeswitchExpr()
+ {
+ eventHandler.startNonterminal("TypeswitchExpr", e0);
+ shift(253); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_CaseClause();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shift(109); // 'default'
+ lookahead1W(95); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ }
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shift(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TypeswitchExpr", e0);
+ }
+
+ function try_TypeswitchExpr()
+ {
+ shiftT(253); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ try_CaseClause();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(109); // 'default'
+ lookahead1W(95); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shiftT(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_CaseClause()
+ {
+ eventHandler.startNonterminal("CaseClause", e0);
+ shift(88); // 'case'
+ lookahead1W(261); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shift(79); // 'as'
+ }
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceTypeUnion();
+ shift(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("CaseClause", e0);
+ }
+
+ function try_CaseClause()
+ {
+ shiftT(88); // 'case'
+ lookahead1W(261); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shiftT(79); // 'as'
+ }
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceTypeUnion();
+ shiftT(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_SequenceTypeUnion()
+ {
+ eventHandler.startNonterminal("SequenceTypeUnion", e0);
+ parse_SequenceType();
+ for (;;)
+ {
+ lookahead1W(134); // S^WS | '(:' | 'return' | '|'
+ if (l1 != 279) // '|'
+ {
+ break;
+ }
+ shift(279); // '|'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ eventHandler.endNonterminal("SequenceTypeUnion", e0);
+ }
+
+ function try_SequenceTypeUnion()
+ {
+ try_SequenceType();
+ for (;;)
+ {
+ lookahead1W(134); // S^WS | '(:' | 'return' | '|'
+ if (l1 != 279) // '|'
+ {
+ break;
+ }
+ shiftT(279); // '|'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+
+ function parse_IfExpr()
+ {
+ eventHandler.startNonterminal("IfExpr", e0);
+ shift(152); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ lookahead1W(77); // S^WS | '(:' | 'then'
+ shift(245); // 'then'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(122); // 'else'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("IfExpr", e0);
+ }
+
+ function try_IfExpr()
+ {
+ shiftT(152); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ lookahead1W(77); // S^WS | '(:' | 'then'
+ shiftT(245); // 'then'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(122); // 'else'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_TryCatchExpr()
+ {
+ eventHandler.startNonterminal("TryCatchExpr", e0);
+ parse_TryClause();
+ for (;;)
+ {
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ whitespace();
+ parse_CatchClause();
+ lookahead1W(183); // S^WS | EOF | '(:' | ')' | ',' | ':' | ';' | ']' | 'after' | 'as' | 'ascending' |
+ if (l1 != 91) // 'catch'
+ {
+ break;
+ }
+ }
+ eventHandler.endNonterminal("TryCatchExpr", e0);
+ }
+
+ function try_TryCatchExpr()
+ {
+ try_TryClause();
+ for (;;)
+ {
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ try_CatchClause();
+ lookahead1W(183); // S^WS | EOF | '(:' | ')' | ',' | ':' | ';' | ']' | 'after' | 'as' | 'ascending' |
+ if (l1 != 91) // 'catch'
+ {
+ break;
+ }
+ }
+ }
+
+ function parse_TryClause()
+ {
+ eventHandler.startNonterminal("TryClause", e0);
+ shift(250); // 'try'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_TryTargetExpr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("TryClause", e0);
+ }
+
+ function try_TryClause()
+ {
+ shiftT(250); // 'try'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_TryTargetExpr();
+ shiftT(282); // '}'
+ }
+
+ function parse_TryTargetExpr()
+ {
+ eventHandler.startNonterminal("TryTargetExpr", e0);
+ parse_Expr();
+ eventHandler.endNonterminal("TryTargetExpr", e0);
+ }
+
+ function try_TryTargetExpr()
+ {
+ try_Expr();
+ }
+
+ function parse_CatchClause()
+ {
+ eventHandler.startNonterminal("CatchClause", e0);
+ shift(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_CatchErrorList();
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("CatchClause", e0);
+ }
+
+ function try_CatchClause()
+ {
+ shiftT(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+
+ function parse_CatchErrorList()
+ {
+ eventHandler.startNonterminal("CatchErrorList", e0);
+ parse_NameTest();
+ for (;;)
+ {
+ lookahead1W(136); // S^WS | '(:' | '{' | '|'
+ if (l1 != 279) // '|'
+ {
+ break;
+ }
+ shift(279); // '|'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NameTest();
+ }
+ eventHandler.endNonterminal("CatchErrorList", e0);
+ }
+
+ function try_CatchErrorList()
+ {
+ try_NameTest();
+ for (;;)
+ {
+ lookahead1W(136); // S^WS | '(:' | '{' | '|'
+ if (l1 != 279) // '|'
+ {
+ break;
+ }
+ shiftT(279); // '|'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NameTest();
+ }
+ }
+
+ function parse_OrExpr()
+ {
+ eventHandler.startNonterminal("OrExpr", e0);
+ parse_AndExpr();
+ for (;;)
+ {
+ if (l1 != 200) // 'or'
+ {
+ break;
+ }
+ shift(200); // 'or'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AndExpr();
+ }
+ eventHandler.endNonterminal("OrExpr", e0);
+ }
+
+ function try_OrExpr()
+ {
+ try_AndExpr();
+ for (;;)
+ {
+ if (l1 != 200) // 'or'
+ {
+ break;
+ }
+ shiftT(200); // 'or'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AndExpr();
+ }
+ }
+
+ function parse_AndExpr()
+ {
+ eventHandler.startNonterminal("AndExpr", e0);
+ parse_ComparisonExpr();
+ for (;;)
+ {
+ if (l1 != 75) // 'and'
+ {
+ break;
+ }
+ shift(75); // 'and'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ComparisonExpr();
+ }
+ eventHandler.endNonterminal("AndExpr", e0);
+ }
+
+ function try_AndExpr()
+ {
+ try_ComparisonExpr();
+ for (;;)
+ {
+ if (l1 != 75) // 'and'
+ {
+ break;
+ }
+ shiftT(75); // 'and'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ComparisonExpr();
+ }
+ }
+
+ function parse_ComparisonExpr()
+ {
+ eventHandler.startNonterminal("ComparisonExpr", e0);
+ parse_FTContainsExpr();
+ if (l1 == 27 // '!='
+ || l1 == 54 // '<'
+ || l1 == 57 // '<<'
+ || l1 == 58 // '<='
+ || l1 == 60 // '='
+ || l1 == 61 // '>'
+ || l1 == 62 // '>='
+ || l1 == 63 // '>>'
+ || l1 == 128 // 'eq'
+ || l1 == 146 // 'ge'
+ || l1 == 150 // 'gt'
+ || l1 == 164 // 'is'
+ || l1 == 172 // 'le'
+ || l1 == 178 // 'lt'
+ || l1 == 186) // 'ne'
+ {
+ switch (l1)
+ {
+ case 128: // 'eq'
+ case 146: // 'ge'
+ case 150: // 'gt'
+ case 172: // 'le'
+ case 178: // 'lt'
+ case 186: // 'ne'
+ whitespace();
+ parse_ValueComp();
+ break;
+ case 57: // '<<'
+ case 63: // '>>'
+ case 164: // 'is'
+ whitespace();
+ parse_NodeComp();
+ break;
+ default:
+ whitespace();
+ parse_GeneralComp();
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_FTContainsExpr();
+ }
+ eventHandler.endNonterminal("ComparisonExpr", e0);
+ }
+
+ function try_ComparisonExpr()
+ {
+ try_FTContainsExpr();
+ if (l1 == 27 // '!='
+ || l1 == 54 // '<'
+ || l1 == 57 // '<<'
+ || l1 == 58 // '<='
+ || l1 == 60 // '='
+ || l1 == 61 // '>'
+ || l1 == 62 // '>='
+ || l1 == 63 // '>>'
+ || l1 == 128 // 'eq'
+ || l1 == 146 // 'ge'
+ || l1 == 150 // 'gt'
+ || l1 == 164 // 'is'
+ || l1 == 172 // 'le'
+ || l1 == 178 // 'lt'
+ || l1 == 186) // 'ne'
+ {
+ switch (l1)
+ {
+ case 128: // 'eq'
+ case 146: // 'ge'
+ case 150: // 'gt'
+ case 172: // 'le'
+ case 178: // 'lt'
+ case 186: // 'ne'
+ try_ValueComp();
+ break;
+ case 57: // '<<'
+ case 63: // '>>'
+ case 164: // 'is'
+ try_NodeComp();
+ break;
+ default:
+ try_GeneralComp();
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_FTContainsExpr();
+ }
+ }
+
+ function parse_FTContainsExpr()
+ {
+ eventHandler.startNonterminal("FTContainsExpr", e0);
+ parse_StringConcatExpr();
+ if (l1 == 99) // 'contains'
+ {
+ shift(99); // 'contains'
+ lookahead1W(76); // S^WS | '(:' | 'text'
+ shift(244); // 'text'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTSelection();
+ if (l1 == 271) // 'without'
+ {
+ whitespace();
+ parse_FTIgnoreOption();
+ }
+ }
+ eventHandler.endNonterminal("FTContainsExpr", e0);
+ }
+
+ function try_FTContainsExpr()
+ {
+ try_StringConcatExpr();
+ if (l1 == 99) // 'contains'
+ {
+ shiftT(99); // 'contains'
+ lookahead1W(76); // S^WS | '(:' | 'text'
+ shiftT(244); // 'text'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTSelection();
+ if (l1 == 271) // 'without'
+ {
+ try_FTIgnoreOption();
+ }
+ }
+ }
+
+ function parse_StringConcatExpr()
+ {
+ eventHandler.startNonterminal("StringConcatExpr", e0);
+ parse_RangeExpr();
+ for (;;)
+ {
+ if (l1 != 280) // '||'
+ {
+ break;
+ }
+ shift(280); // '||'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_RangeExpr();
+ }
+ eventHandler.endNonterminal("StringConcatExpr", e0);
+ }
+
+ function try_StringConcatExpr()
+ {
+ try_RangeExpr();
+ for (;;)
+ {
+ if (l1 != 280) // '||'
+ {
+ break;
+ }
+ shiftT(280); // '||'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_RangeExpr();
+ }
+ }
+
+ function parse_RangeExpr()
+ {
+ eventHandler.startNonterminal("RangeExpr", e0);
+ parse_AdditiveExpr();
+ if (l1 == 248) // 'to'
+ {
+ shift(248); // 'to'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ }
+ eventHandler.endNonterminal("RangeExpr", e0);
+ }
+
+ function try_RangeExpr()
+ {
+ try_AdditiveExpr();
+ if (l1 == 248) // 'to'
+ {
+ shiftT(248); // 'to'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ }
+ }
+
+ function parse_AdditiveExpr()
+ {
+ eventHandler.startNonterminal("AdditiveExpr", e0);
+ parse_MultiplicativeExpr();
+ for (;;)
+ {
+ if (l1 != 40 // '+'
+ && l1 != 42) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 40: // '+'
+ shift(40); // '+'
+ break;
+ default:
+ shift(42); // '-'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_MultiplicativeExpr();
+ }
+ eventHandler.endNonterminal("AdditiveExpr", e0);
+ }
+
+ function try_AdditiveExpr()
+ {
+ try_MultiplicativeExpr();
+ for (;;)
+ {
+ if (l1 != 40 // '+'
+ && l1 != 42) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 40: // '+'
+ shiftT(40); // '+'
+ break;
+ default:
+ shiftT(42); // '-'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_MultiplicativeExpr();
+ }
+ }
+
+ function parse_MultiplicativeExpr()
+ {
+ eventHandler.startNonterminal("MultiplicativeExpr", e0);
+ parse_UnionExpr();
+ for (;;)
+ {
+ if (l1 != 38 // '*'
+ && l1 != 118 // 'div'
+ && l1 != 151 // 'idiv'
+ && l1 != 180) // 'mod'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 38: // '*'
+ shift(38); // '*'
+ break;
+ case 118: // 'div'
+ shift(118); // 'div'
+ break;
+ case 151: // 'idiv'
+ shift(151); // 'idiv'
+ break;
+ default:
+ shift(180); // 'mod'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_UnionExpr();
+ }
+ eventHandler.endNonterminal("MultiplicativeExpr", e0);
+ }
+
+ function try_MultiplicativeExpr()
+ {
+ try_UnionExpr();
+ for (;;)
+ {
+ if (l1 != 38 // '*'
+ && l1 != 118 // 'div'
+ && l1 != 151 // 'idiv'
+ && l1 != 180) // 'mod'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 38: // '*'
+ shiftT(38); // '*'
+ break;
+ case 118: // 'div'
+ shiftT(118); // 'div'
+ break;
+ case 151: // 'idiv'
+ shiftT(151); // 'idiv'
+ break;
+ default:
+ shiftT(180); // 'mod'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_UnionExpr();
+ }
+ }
+
+ function parse_UnionExpr()
+ {
+ eventHandler.startNonterminal("UnionExpr", e0);
+ parse_IntersectExceptExpr();
+ for (;;)
+ {
+ if (l1 != 254 // 'union'
+ && l1 != 279) // '|'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 254: // 'union'
+ shift(254); // 'union'
+ break;
+ default:
+ shift(279); // '|'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_IntersectExceptExpr();
+ }
+ eventHandler.endNonterminal("UnionExpr", e0);
+ }
+
+ function try_UnionExpr()
+ {
+ try_IntersectExceptExpr();
+ for (;;)
+ {
+ if (l1 != 254 // 'union'
+ && l1 != 279) // '|'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 254: // 'union'
+ shiftT(254); // 'union'
+ break;
+ default:
+ shiftT(279); // '|'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_IntersectExceptExpr();
+ }
+ }
+
+ function parse_IntersectExceptExpr()
+ {
+ eventHandler.startNonterminal("IntersectExceptExpr", e0);
+ parse_InstanceofExpr();
+ for (;;)
+ {
+ lookahead1W(222); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 != 131 // 'except'
+ && l1 != 162) // 'intersect'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 162: // 'intersect'
+ shift(162); // 'intersect'
+ break;
+ default:
+ shift(131); // 'except'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_InstanceofExpr();
+ }
+ eventHandler.endNonterminal("IntersectExceptExpr", e0);
+ }
+
+ function try_IntersectExceptExpr()
+ {
+ try_InstanceofExpr();
+ for (;;)
+ {
+ lookahead1W(222); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 != 131 // 'except'
+ && l1 != 162) // 'intersect'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 162: // 'intersect'
+ shiftT(162); // 'intersect'
+ break;
+ default:
+ shiftT(131); // 'except'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_InstanceofExpr();
+ }
+ }
+
+ function parse_InstanceofExpr()
+ {
+ eventHandler.startNonterminal("InstanceofExpr", e0);
+ parse_TreatExpr();
+ lookahead1W(223); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 160) // 'instance'
+ {
+ shift(160); // 'instance'
+ lookahead1W(64); // S^WS | '(:' | 'of'
+ shift(196); // 'of'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ eventHandler.endNonterminal("InstanceofExpr", e0);
+ }
+
+ function try_InstanceofExpr()
+ {
+ try_TreatExpr();
+ lookahead1W(223); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 160) // 'instance'
+ {
+ shiftT(160); // 'instance'
+ lookahead1W(64); // S^WS | '(:' | 'of'
+ shiftT(196); // 'of'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+
+ function parse_TreatExpr()
+ {
+ eventHandler.startNonterminal("TreatExpr", e0);
+ parse_CastableExpr();
+ lookahead1W(224); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 249) // 'treat'
+ {
+ shift(249); // 'treat'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ eventHandler.endNonterminal("TreatExpr", e0);
+ }
+
+ function try_TreatExpr()
+ {
+ try_CastableExpr();
+ lookahead1W(224); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 249) // 'treat'
+ {
+ shiftT(249); // 'treat'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shiftT(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+
+ function parse_CastableExpr()
+ {
+ eventHandler.startNonterminal("CastableExpr", e0);
+ parse_CastExpr();
+ lookahead1W(225); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 90) // 'castable'
+ {
+ shift(90); // 'castable'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shift(79); // 'as'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SingleType();
+ }
+ eventHandler.endNonterminal("CastableExpr", e0);
+ }
+
+ function try_CastableExpr()
+ {
+ try_CastExpr();
+ lookahead1W(225); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 90) // 'castable'
+ {
+ shiftT(90); // 'castable'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shiftT(79); // 'as'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SingleType();
+ }
+ }
+
+ function parse_CastExpr()
+ {
+ eventHandler.startNonterminal("CastExpr", e0);
+ parse_UnaryExpr();
+ lookahead1W(227); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 89) // 'cast'
+ {
+ shift(89); // 'cast'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shift(79); // 'as'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SingleType();
+ }
+ eventHandler.endNonterminal("CastExpr", e0);
+ }
+
+ function try_CastExpr()
+ {
+ try_UnaryExpr();
+ lookahead1W(227); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 89) // 'cast'
+ {
+ shiftT(89); // 'cast'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shiftT(79); // 'as'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SingleType();
+ }
+ }
+
+ function parse_UnaryExpr()
+ {
+ eventHandler.startNonterminal("UnaryExpr", e0);
+ for (;;)
+ {
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 40 // '+'
+ && l1 != 42) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 42: // '-'
+ shift(42); // '-'
+ break;
+ default:
+ shift(40); // '+'
+ }
+ }
+ whitespace();
+ parse_ValueExpr();
+ eventHandler.endNonterminal("UnaryExpr", e0);
+ }
+
+ function try_UnaryExpr()
+ {
+ for (;;)
+ {
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 40 // '+'
+ && l1 != 42) // '-'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 42: // '-'
+ shiftT(42); // '-'
+ break;
+ default:
+ shiftT(40); // '+'
+ }
+ }
+ try_ValueExpr();
+ }
+
+ function parse_ValueExpr()
+ {
+ eventHandler.startNonterminal("ValueExpr", e0);
+ switch (l1)
+ {
+ case 260: // 'validate'
+ lookahead2W(247); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 87812: // 'validate' 'lax'
+ case 123140: // 'validate' 'strict'
+ case 129284: // 'validate' 'type'
+ case 141572: // 'validate' '{'
+ parse_ValidateExpr();
+ break;
+ case 35: // '(#'
+ parse_ExtensionExpr();
+ break;
+ default:
+ parse_SimpleMapExpr();
+ }
+ eventHandler.endNonterminal("ValueExpr", e0);
+ }
+
+ function try_ValueExpr()
+ {
+ switch (l1)
+ {
+ case 260: // 'validate'
+ lookahead2W(247); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 87812: // 'validate' 'lax'
+ case 123140: // 'validate' 'strict'
+ case 129284: // 'validate' 'type'
+ case 141572: // 'validate' '{'
+ try_ValidateExpr();
+ break;
+ case 35: // '(#'
+ try_ExtensionExpr();
+ break;
+ default:
+ try_SimpleMapExpr();
+ }
+ }
+
+ function parse_SimpleMapExpr()
+ {
+ eventHandler.startNonterminal("SimpleMapExpr", e0);
+ parse_PathExpr();
+ for (;;)
+ {
+ if (l1 != 26) // '!'
+ {
+ break;
+ }
+ shift(26); // '!'
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_PathExpr();
+ }
+ eventHandler.endNonterminal("SimpleMapExpr", e0);
+ }
+
+ function try_SimpleMapExpr()
+ {
+ try_PathExpr();
+ for (;;)
+ {
+ if (l1 != 26) // '!'
+ {
+ break;
+ }
+ shiftT(26); // '!'
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_PathExpr();
+ }
+ }
+
+ function parse_GeneralComp()
+ {
+ eventHandler.startNonterminal("GeneralComp", e0);
+ switch (l1)
+ {
+ case 60: // '='
+ shift(60); // '='
+ break;
+ case 27: // '!='
+ shift(27); // '!='
+ break;
+ case 54: // '<'
+ shift(54); // '<'
+ break;
+ case 58: // '<='
+ shift(58); // '<='
+ break;
+ case 61: // '>'
+ shift(61); // '>'
+ break;
+ default:
+ shift(62); // '>='
+ }
+ eventHandler.endNonterminal("GeneralComp", e0);
+ }
+
+ function try_GeneralComp()
+ {
+ switch (l1)
+ {
+ case 60: // '='
+ shiftT(60); // '='
+ break;
+ case 27: // '!='
+ shiftT(27); // '!='
+ break;
+ case 54: // '<'
+ shiftT(54); // '<'
+ break;
+ case 58: // '<='
+ shiftT(58); // '<='
+ break;
+ case 61: // '>'
+ shiftT(61); // '>'
+ break;
+ default:
+ shiftT(62); // '>='
+ }
+ }
+
+ function parse_ValueComp()
+ {
+ eventHandler.startNonterminal("ValueComp", e0);
+ switch (l1)
+ {
+ case 128: // 'eq'
+ shift(128); // 'eq'
+ break;
+ case 186: // 'ne'
+ shift(186); // 'ne'
+ break;
+ case 178: // 'lt'
+ shift(178); // 'lt'
+ break;
+ case 172: // 'le'
+ shift(172); // 'le'
+ break;
+ case 150: // 'gt'
+ shift(150); // 'gt'
+ break;
+ default:
+ shift(146); // 'ge'
+ }
+ eventHandler.endNonterminal("ValueComp", e0);
+ }
+
+ function try_ValueComp()
+ {
+ switch (l1)
+ {
+ case 128: // 'eq'
+ shiftT(128); // 'eq'
+ break;
+ case 186: // 'ne'
+ shiftT(186); // 'ne'
+ break;
+ case 178: // 'lt'
+ shiftT(178); // 'lt'
+ break;
+ case 172: // 'le'
+ shiftT(172); // 'le'
+ break;
+ case 150: // 'gt'
+ shiftT(150); // 'gt'
+ break;
+ default:
+ shiftT(146); // 'ge'
+ }
+ }
+
+ function parse_NodeComp()
+ {
+ eventHandler.startNonterminal("NodeComp", e0);
+ switch (l1)
+ {
+ case 164: // 'is'
+ shift(164); // 'is'
+ break;
+ case 57: // '<<'
+ shift(57); // '<<'
+ break;
+ default:
+ shift(63); // '>>'
+ }
+ eventHandler.endNonterminal("NodeComp", e0);
+ }
+
+ function try_NodeComp()
+ {
+ switch (l1)
+ {
+ case 164: // 'is'
+ shiftT(164); // 'is'
+ break;
+ case 57: // '<<'
+ shiftT(57); // '<<'
+ break;
+ default:
+ shiftT(63); // '>>'
+ }
+ }
+
+ function parse_ValidateExpr()
+ {
+ eventHandler.startNonterminal("ValidateExpr", e0);
+ shift(260); // 'validate'
+ lookahead1W(160); // S^WS | '(:' | 'lax' | 'strict' | 'type' | '{'
+ if (l1 != 276) // '{'
+ {
+ switch (l1)
+ {
+ case 252: // 'type'
+ shift(252); // 'type'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_TypeName();
+ break;
+ default:
+ whitespace();
+ parse_ValidationMode();
+ }
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("ValidateExpr", e0);
+ }
+
+ function try_ValidateExpr()
+ {
+ shiftT(260); // 'validate'
+ lookahead1W(160); // S^WS | '(:' | 'lax' | 'strict' | 'type' | '{'
+ if (l1 != 276) // '{'
+ {
+ switch (l1)
+ {
+ case 252: // 'type'
+ shiftT(252); // 'type'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_TypeName();
+ break;
+ default:
+ try_ValidationMode();
+ }
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+
+ function parse_ValidationMode()
+ {
+ eventHandler.startNonterminal("ValidationMode", e0);
+ switch (l1)
+ {
+ case 171: // 'lax'
+ shift(171); // 'lax'
+ break;
+ default:
+ shift(240); // 'strict'
+ }
+ eventHandler.endNonterminal("ValidationMode", e0);
+ }
+
+ function try_ValidationMode()
+ {
+ switch (l1)
+ {
+ case 171: // 'lax'
+ shiftT(171); // 'lax'
+ break;
+ default:
+ shiftT(240); // 'strict'
+ }
+ }
+
+ function parse_ExtensionExpr()
+ {
+ eventHandler.startNonterminal("ExtensionExpr", e0);
+ for (;;)
+ {
+ whitespace();
+ parse_Pragma();
+ lookahead1W(100); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 35) // '(#'
+ {
+ break;
+ }
+ }
+ shift(276); // '{'
+ lookahead1W(273); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 282) // '}'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(282); // '}'
+ eventHandler.endNonterminal("ExtensionExpr", e0);
+ }
+
+ function try_ExtensionExpr()
+ {
+ for (;;)
+ {
+ try_Pragma();
+ lookahead1W(100); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 35) // '(#'
+ {
+ break;
+ }
+ }
+ shiftT(276); // '{'
+ lookahead1W(273); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 282) // '}'
+ {
+ try_Expr();
+ }
+ shiftT(282); // '}'
+ }
+
+ function parse_Pragma()
+ {
+ eventHandler.startNonterminal("Pragma", e0);
+ shift(35); // '(#'
+ lookahead1(251); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ parse_EQName();
+ lookahead1(10); // S | '#)'
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ lookahead1(0); // PragmaContents
+ shift(1); // PragmaContents
+ }
+ lookahead1(5); // '#)'
+ shift(30); // '#)'
+ eventHandler.endNonterminal("Pragma", e0);
+ }
+
+ function try_Pragma()
+ {
+ shiftT(35); // '(#'
+ lookahead1(251); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ try_EQName();
+ lookahead1(10); // S | '#)'
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ lookahead1(0); // PragmaContents
+ shiftT(1); // PragmaContents
+ }
+ lookahead1(5); // '#)'
+ shiftT(30); // '#)'
+ }
+
+ function parse_PathExpr()
+ {
+ eventHandler.startNonterminal("PathExpr", e0);
+ switch (l1)
+ {
+ case 46: // '/'
+ shift(46); // '/'
+ lookahead1W(285); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 25: // EOF
+ case 26: // '!'
+ case 27: // '!='
+ case 37: // ')'
+ case 38: // '*'
+ case 40: // '+'
+ case 41: // ','
+ case 42: // '-'
+ case 49: // ':'
+ case 53: // ';'
+ case 57: // '<<'
+ case 58: // '<='
+ case 60: // '='
+ case 61: // '>'
+ case 62: // '>='
+ case 63: // '>>'
+ case 69: // ']'
+ case 87: // 'by'
+ case 99: // 'contains'
+ case 205: // 'paragraphs'
+ case 232: // 'sentences'
+ case 247: // 'times'
+ case 273: // 'words'
+ case 279: // '|'
+ case 280: // '||'
+ case 281: // '|}'
+ case 282: // '}'
+ break;
+ default:
+ whitespace();
+ parse_RelativePathExpr();
+ }
+ break;
+ case 47: // '//'
+ shift(47); // '//'
+ lookahead1W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_RelativePathExpr();
+ break;
+ default:
+ parse_RelativePathExpr();
+ }
+ eventHandler.endNonterminal("PathExpr", e0);
+ }
+
+ function try_PathExpr()
+ {
+ switch (l1)
+ {
+ case 46: // '/'
+ shiftT(46); // '/'
+ lookahead1W(285); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 25: // EOF
+ case 26: // '!'
+ case 27: // '!='
+ case 37: // ')'
+ case 38: // '*'
+ case 40: // '+'
+ case 41: // ','
+ case 42: // '-'
+ case 49: // ':'
+ case 53: // ';'
+ case 57: // '<<'
+ case 58: // '<='
+ case 60: // '='
+ case 61: // '>'
+ case 62: // '>='
+ case 63: // '>>'
+ case 69: // ']'
+ case 87: // 'by'
+ case 99: // 'contains'
+ case 205: // 'paragraphs'
+ case 232: // 'sentences'
+ case 247: // 'times'
+ case 273: // 'words'
+ case 279: // '|'
+ case 280: // '||'
+ case 281: // '|}'
+ case 282: // '}'
+ break;
+ default:
+ try_RelativePathExpr();
+ }
+ break;
+ case 47: // '//'
+ shiftT(47); // '//'
+ lookahead1W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_RelativePathExpr();
+ break;
+ default:
+ try_RelativePathExpr();
+ }
+ }
+
+ function parse_RelativePathExpr()
+ {
+ eventHandler.startNonterminal("RelativePathExpr", e0);
+ parse_StepExpr();
+ for (;;)
+ {
+ switch (l1)
+ {
+ case 26: // '!'
+ lookahead2W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 27 // '!='
+ && lk != 37 // ')'
+ && lk != 38 // '*'
+ && lk != 40 // '+'
+ && lk != 41 // ','
+ && lk != 42 // '-'
+ && lk != 46 // '/'
+ && lk != 47 // '//'
+ && lk != 49 // ':'
+ && lk != 53 // ';'
+ && lk != 54 // '<'
+ && lk != 57 // '<<'
+ && lk != 58 // '<='
+ && lk != 60 // '='
+ && lk != 61 // '>'
+ && lk != 62 // '>='
+ && lk != 63 // '>>'
+ && lk != 69 // ']'
+ && lk != 70 // 'after'
+ && lk != 75 // 'and'
+ && lk != 79 // 'as'
+ && lk != 80 // 'ascending'
+ && lk != 81 // 'at'
+ && lk != 84 // 'before'
+ && lk != 87 // 'by'
+ && lk != 88 // 'case'
+ && lk != 89 // 'cast'
+ && lk != 90 // 'castable'
+ && lk != 94 // 'collation'
+ && lk != 99 // 'contains'
+ && lk != 105 // 'count'
+ && lk != 109 // 'default'
+ && lk != 113 // 'descending'
+ && lk != 118 // 'div'
+ && lk != 122 // 'else'
+ && lk != 123 // 'empty'
+ && lk != 126 // 'end'
+ && lk != 128 // 'eq'
+ && lk != 131 // 'except'
+ && lk != 137 // 'for'
+ && lk != 146 // 'ge'
+ && lk != 148 // 'group'
+ && lk != 150 // 'gt'
+ && lk != 151 // 'idiv'
+ && lk != 160 // 'instance'
+ && lk != 162 // 'intersect'
+ && lk != 163 // 'into'
+ && lk != 164 // 'is'
+ && lk != 172 // 'le'
+ && lk != 174 // 'let'
+ && lk != 178 // 'lt'
+ && lk != 180 // 'mod'
+ && lk != 181 // 'modify'
+ && lk != 186 // 'ne'
+ && lk != 198 // 'only'
+ && lk != 200 // 'or'
+ && lk != 201 // 'order'
+ && lk != 205 // 'paragraphs'
+ && lk != 220 // 'return'
+ && lk != 224 // 'satisfies'
+ && lk != 232 // 'sentences'
+ && lk != 236 // 'stable'
+ && lk != 237 // 'start'
+ && lk != 247 // 'times'
+ && lk != 248 // 'to'
+ && lk != 249 // 'treat'
+ && lk != 254 // 'union'
+ && lk != 266 // 'where'
+ && lk != 270 // 'with'
+ && lk != 273 // 'words'
+ && lk != 279 // '|'
+ && lk != 280 // '||'
+ && lk != 281 // '|}'
+ && lk != 282 // '}'
+ && lk != 23578 // '!' '/'
+ && lk != 24090) // '!' '//'
+ {
+ lk = memoized(3, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ switch (l1)
+ {
+ case 46: // '/'
+ shiftT(46); // '/'
+ break;
+ case 47: // '//'
+ shiftT(47); // '//'
+ break;
+ default:
+ shiftT(26); // '!'
+ }
+ lookahead1W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StepExpr();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(3, e0, lk);
+ }
+ }
+ if (lk != -1
+ && lk != 46 // '/'
+ && lk != 47) // '//'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 46: // '/'
+ shift(46); // '/'
+ break;
+ case 47: // '//'
+ shift(47); // '//'
+ break;
+ default:
+ shift(26); // '!'
+ }
+ lookahead1W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_StepExpr();
+ }
+ eventHandler.endNonterminal("RelativePathExpr", e0);
+ }
+
+ function try_RelativePathExpr()
+ {
+ try_StepExpr();
+ for (;;)
+ {
+ switch (l1)
+ {
+ case 26: // '!'
+ lookahead2W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 27 // '!='
+ && lk != 37 // ')'
+ && lk != 38 // '*'
+ && lk != 40 // '+'
+ && lk != 41 // ','
+ && lk != 42 // '-'
+ && lk != 46 // '/'
+ && lk != 47 // '//'
+ && lk != 49 // ':'
+ && lk != 53 // ';'
+ && lk != 54 // '<'
+ && lk != 57 // '<<'
+ && lk != 58 // '<='
+ && lk != 60 // '='
+ && lk != 61 // '>'
+ && lk != 62 // '>='
+ && lk != 63 // '>>'
+ && lk != 69 // ']'
+ && lk != 70 // 'after'
+ && lk != 75 // 'and'
+ && lk != 79 // 'as'
+ && lk != 80 // 'ascending'
+ && lk != 81 // 'at'
+ && lk != 84 // 'before'
+ && lk != 87 // 'by'
+ && lk != 88 // 'case'
+ && lk != 89 // 'cast'
+ && lk != 90 // 'castable'
+ && lk != 94 // 'collation'
+ && lk != 99 // 'contains'
+ && lk != 105 // 'count'
+ && lk != 109 // 'default'
+ && lk != 113 // 'descending'
+ && lk != 118 // 'div'
+ && lk != 122 // 'else'
+ && lk != 123 // 'empty'
+ && lk != 126 // 'end'
+ && lk != 128 // 'eq'
+ && lk != 131 // 'except'
+ && lk != 137 // 'for'
+ && lk != 146 // 'ge'
+ && lk != 148 // 'group'
+ && lk != 150 // 'gt'
+ && lk != 151 // 'idiv'
+ && lk != 160 // 'instance'
+ && lk != 162 // 'intersect'
+ && lk != 163 // 'into'
+ && lk != 164 // 'is'
+ && lk != 172 // 'le'
+ && lk != 174 // 'let'
+ && lk != 178 // 'lt'
+ && lk != 180 // 'mod'
+ && lk != 181 // 'modify'
+ && lk != 186 // 'ne'
+ && lk != 198 // 'only'
+ && lk != 200 // 'or'
+ && lk != 201 // 'order'
+ && lk != 205 // 'paragraphs'
+ && lk != 220 // 'return'
+ && lk != 224 // 'satisfies'
+ && lk != 232 // 'sentences'
+ && lk != 236 // 'stable'
+ && lk != 237 // 'start'
+ && lk != 247 // 'times'
+ && lk != 248 // 'to'
+ && lk != 249 // 'treat'
+ && lk != 254 // 'union'
+ && lk != 266 // 'where'
+ && lk != 270 // 'with'
+ && lk != 273 // 'words'
+ && lk != 279 // '|'
+ && lk != 280 // '||'
+ && lk != 281 // '|}'
+ && lk != 282 // '}'
+ && lk != 23578 // '!' '/'
+ && lk != 24090) // '!' '//'
+ {
+ lk = memoized(3, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ switch (l1)
+ {
+ case 46: // '/'
+ shiftT(46); // '/'
+ break;
+ case 47: // '//'
+ shiftT(47); // '//'
+ break;
+ default:
+ shiftT(26); // '!'
+ }
+ lookahead1W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StepExpr();
+ memoize(3, e0A, -1);
+ continue;
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(3, e0A, -2);
+ break;
+ }
+ }
+ }
+ if (lk != -1
+ && lk != 46 // '/'
+ && lk != 47) // '//'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 46: // '/'
+ shiftT(46); // '/'
+ break;
+ case 47: // '//'
+ shiftT(47); // '//'
+ break;
+ default:
+ shiftT(26); // '!'
+ }
+ lookahead1W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StepExpr();
+ }
+ }
+
+ function parse_StepExpr()
+ {
+ eventHandler.startNonterminal("StepExpr", e0);
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ lookahead2W(284); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 121: // 'element'
+ lookahead2W(282); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 184: // 'namespace'
+ case 216: // 'processing-instruction'
+ lookahead2W(281); // NCName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 96: // 'comment'
+ case 119: // 'document'
+ case 202: // 'ordered'
+ case 244: // 'text'
+ case 256: // 'unordered'
+ lookahead2W(246); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 78: // 'array'
+ case 124: // 'empty-sequence'
+ case 152: // 'if'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 242: // 'structured-item'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ lookahead2W(239); // S^WS | EOF | '!' | '!=' | '#' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 93: // 'child'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ case 229: // 'self'
+ lookahead2W(245); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 6: // EQName^Token
+ case 70: // 'after'
+ case 72: // 'allowing'
+ case 75: // 'and'
+ case 77: // 'append'
+ case 79: // 'as'
+ case 80: // 'ascending'
+ case 81: // 'at'
+ case 83: // 'base-uri'
+ case 84: // 'before'
+ case 85: // 'boundary-space'
+ case 86: // 'break'
+ case 88: // 'case'
+ case 89: // 'cast'
+ case 90: // 'castable'
+ case 91: // 'catch'
+ case 94: // 'collation'
+ case 97: // 'constraint'
+ case 98: // 'construction'
+ case 101: // 'context'
+ case 102: // 'continue'
+ case 103: // 'copy'
+ case 104: // 'copy-namespaces'
+ case 105: // 'count'
+ case 106: // 'decimal-format'
+ case 108: // 'declare'
+ case 109: // 'default'
+ case 110: // 'delete'
+ case 113: // 'descending'
+ case 118: // 'div'
+ case 120: // 'document-node'
+ case 122: // 'else'
+ case 123: // 'empty'
+ case 125: // 'encoding'
+ case 126: // 'end'
+ case 128: // 'eq'
+ case 129: // 'every'
+ case 131: // 'except'
+ case 132: // 'exit'
+ case 133: // 'external'
+ case 134: // 'first'
+ case 137: // 'for'
+ case 141: // 'ft-option'
+ case 145: // 'function'
+ case 146: // 'ge'
+ case 148: // 'group'
+ case 150: // 'gt'
+ case 151: // 'idiv'
+ case 153: // 'import'
+ case 154: // 'in'
+ case 155: // 'index'
+ case 159: // 'insert'
+ case 160: // 'instance'
+ case 161: // 'integrity'
+ case 162: // 'intersect'
+ case 163: // 'into'
+ case 164: // 'is'
+ case 166: // 'json'
+ case 170: // 'last'
+ case 171: // 'lax'
+ case 172: // 'le'
+ case 174: // 'let'
+ case 176: // 'loop'
+ case 178: // 'lt'
+ case 180: // 'mod'
+ case 181: // 'modify'
+ case 182: // 'module'
+ case 185: // 'namespace-node'
+ case 186: // 'ne'
+ case 191: // 'node'
+ case 192: // 'nodes'
+ case 194: // 'object'
+ case 198: // 'only'
+ case 199: // 'option'
+ case 200: // 'or'
+ case 201: // 'order'
+ case 203: // 'ordering'
+ case 218: // 'rename'
+ case 219: // 'replace'
+ case 220: // 'return'
+ case 221: // 'returning'
+ case 222: // 'revalidation'
+ case 224: // 'satisfies'
+ case 225: // 'schema'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 228: // 'score'
+ case 234: // 'sliding'
+ case 235: // 'some'
+ case 236: // 'stable'
+ case 237: // 'start'
+ case 240: // 'strict'
+ case 248: // 'to'
+ case 249: // 'treat'
+ case 250: // 'try'
+ case 251: // 'tumbling'
+ case 252: // 'type'
+ case 254: // 'union'
+ case 257: // 'updating'
+ case 260: // 'validate'
+ case 261: // 'value'
+ case 262: // 'variable'
+ case 263: // 'version'
+ case 266: // 'where'
+ case 267: // 'while'
+ case 270: // 'with'
+ case 274: // 'xquery'
+ lookahead2W(243); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 35922 // 'attribute' 'after'
+ || lk == 35961 // 'element' 'after'
+ || lk == 36024 // 'namespace' 'after'
+ || lk == 36056 // 'processing-instruction' 'after'
+ || lk == 38482 // 'attribute' 'and'
+ || lk == 38521 // 'element' 'and'
+ || lk == 38584 // 'namespace' 'and'
+ || lk == 38616 // 'processing-instruction' 'and'
+ || lk == 40530 // 'attribute' 'as'
+ || lk == 40569 // 'element' 'as'
+ || lk == 40632 // 'namespace' 'as'
+ || lk == 40664 // 'processing-instruction' 'as'
+ || lk == 41042 // 'attribute' 'ascending'
+ || lk == 41081 // 'element' 'ascending'
+ || lk == 41144 // 'namespace' 'ascending'
+ || lk == 41176 // 'processing-instruction' 'ascending'
+ || lk == 41554 // 'attribute' 'at'
+ || lk == 41593 // 'element' 'at'
+ || lk == 41656 // 'namespace' 'at'
+ || lk == 41688 // 'processing-instruction' 'at'
+ || lk == 43090 // 'attribute' 'before'
+ || lk == 43129 // 'element' 'before'
+ || lk == 43192 // 'namespace' 'before'
+ || lk == 43224 // 'processing-instruction' 'before'
+ || lk == 45138 // 'attribute' 'case'
+ || lk == 45177 // 'element' 'case'
+ || lk == 45240 // 'namespace' 'case'
+ || lk == 45272 // 'processing-instruction' 'case'
+ || lk == 45650 // 'attribute' 'cast'
+ || lk == 45689 // 'element' 'cast'
+ || lk == 45752 // 'namespace' 'cast'
+ || lk == 45784 // 'processing-instruction' 'cast'
+ || lk == 46162 // 'attribute' 'castable'
+ || lk == 46201 // 'element' 'castable'
+ || lk == 46264 // 'namespace' 'castable'
+ || lk == 46296 // 'processing-instruction' 'castable'
+ || lk == 48210 // 'attribute' 'collation'
+ || lk == 48249 // 'element' 'collation'
+ || lk == 48312 // 'namespace' 'collation'
+ || lk == 48344 // 'processing-instruction' 'collation'
+ || lk == 53842 // 'attribute' 'count'
+ || lk == 53881 // 'element' 'count'
+ || lk == 53944 // 'namespace' 'count'
+ || lk == 53976 // 'processing-instruction' 'count'
+ || lk == 55890 // 'attribute' 'default'
+ || lk == 55929 // 'element' 'default'
+ || lk == 55992 // 'namespace' 'default'
+ || lk == 56024 // 'processing-instruction' 'default'
+ || lk == 57938 // 'attribute' 'descending'
+ || lk == 57977 // 'element' 'descending'
+ || lk == 58040 // 'namespace' 'descending'
+ || lk == 58072 // 'processing-instruction' 'descending'
+ || lk == 60498 // 'attribute' 'div'
+ || lk == 60537 // 'element' 'div'
+ || lk == 60600 // 'namespace' 'div'
+ || lk == 60632 // 'processing-instruction' 'div'
+ || lk == 62546 // 'attribute' 'else'
+ || lk == 62585 // 'element' 'else'
+ || lk == 62648 // 'namespace' 'else'
+ || lk == 62680 // 'processing-instruction' 'else'
+ || lk == 63058 // 'attribute' 'empty'
+ || lk == 63097 // 'element' 'empty'
+ || lk == 63160 // 'namespace' 'empty'
+ || lk == 63192 // 'processing-instruction' 'empty'
+ || lk == 64594 // 'attribute' 'end'
+ || lk == 64633 // 'element' 'end'
+ || lk == 64696 // 'namespace' 'end'
+ || lk == 64728 // 'processing-instruction' 'end'
+ || lk == 65618 // 'attribute' 'eq'
+ || lk == 65657 // 'element' 'eq'
+ || lk == 65720 // 'namespace' 'eq'
+ || lk == 65752 // 'processing-instruction' 'eq'
+ || lk == 67154 // 'attribute' 'except'
+ || lk == 67193 // 'element' 'except'
+ || lk == 67256 // 'namespace' 'except'
+ || lk == 67288 // 'processing-instruction' 'except'
+ || lk == 70226 // 'attribute' 'for'
+ || lk == 70265 // 'element' 'for'
+ || lk == 70328 // 'namespace' 'for'
+ || lk == 70360 // 'processing-instruction' 'for'
+ || lk == 74834 // 'attribute' 'ge'
+ || lk == 74873 // 'element' 'ge'
+ || lk == 74936 // 'namespace' 'ge'
+ || lk == 74968 // 'processing-instruction' 'ge'
+ || lk == 75858 // 'attribute' 'group'
+ || lk == 75897 // 'element' 'group'
+ || lk == 75960 // 'namespace' 'group'
+ || lk == 75992 // 'processing-instruction' 'group'
+ || lk == 76882 // 'attribute' 'gt'
+ || lk == 76921 // 'element' 'gt'
+ || lk == 76984 // 'namespace' 'gt'
+ || lk == 77016 // 'processing-instruction' 'gt'
+ || lk == 77394 // 'attribute' 'idiv'
+ || lk == 77433 // 'element' 'idiv'
+ || lk == 77496 // 'namespace' 'idiv'
+ || lk == 77528 // 'processing-instruction' 'idiv'
+ || lk == 82002 // 'attribute' 'instance'
+ || lk == 82041 // 'element' 'instance'
+ || lk == 82104 // 'namespace' 'instance'
+ || lk == 82136 // 'processing-instruction' 'instance'
+ || lk == 83026 // 'attribute' 'intersect'
+ || lk == 83065 // 'element' 'intersect'
+ || lk == 83128 // 'namespace' 'intersect'
+ || lk == 83160 // 'processing-instruction' 'intersect'
+ || lk == 83538 // 'attribute' 'into'
+ || lk == 83577 // 'element' 'into'
+ || lk == 83640 // 'namespace' 'into'
+ || lk == 83672 // 'processing-instruction' 'into'
+ || lk == 84050 // 'attribute' 'is'
+ || lk == 84089 // 'element' 'is'
+ || lk == 84152 // 'namespace' 'is'
+ || lk == 84184 // 'processing-instruction' 'is'
+ || lk == 88146 // 'attribute' 'le'
+ || lk == 88185 // 'element' 'le'
+ || lk == 88248 // 'namespace' 'le'
+ || lk == 88280 // 'processing-instruction' 'le'
+ || lk == 89170 // 'attribute' 'let'
+ || lk == 89209 // 'element' 'let'
+ || lk == 89272 // 'namespace' 'let'
+ || lk == 89304 // 'processing-instruction' 'let'
+ || lk == 91218 // 'attribute' 'lt'
+ || lk == 91257 // 'element' 'lt'
+ || lk == 91320 // 'namespace' 'lt'
+ || lk == 91352 // 'processing-instruction' 'lt'
+ || lk == 92242 // 'attribute' 'mod'
+ || lk == 92281 // 'element' 'mod'
+ || lk == 92344 // 'namespace' 'mod'
+ || lk == 92376 // 'processing-instruction' 'mod'
+ || lk == 92754 // 'attribute' 'modify'
+ || lk == 92793 // 'element' 'modify'
+ || lk == 92856 // 'namespace' 'modify'
+ || lk == 92888 // 'processing-instruction' 'modify'
+ || lk == 95314 // 'attribute' 'ne'
+ || lk == 95353 // 'element' 'ne'
+ || lk == 95416 // 'namespace' 'ne'
+ || lk == 95448 // 'processing-instruction' 'ne'
+ || lk == 101458 // 'attribute' 'only'
+ || lk == 101497 // 'element' 'only'
+ || lk == 101560 // 'namespace' 'only'
+ || lk == 101592 // 'processing-instruction' 'only'
+ || lk == 102482 // 'attribute' 'or'
+ || lk == 102521 // 'element' 'or'
+ || lk == 102584 // 'namespace' 'or'
+ || lk == 102616 // 'processing-instruction' 'or'
+ || lk == 102994 // 'attribute' 'order'
+ || lk == 103033 // 'element' 'order'
+ || lk == 103096 // 'namespace' 'order'
+ || lk == 103128 // 'processing-instruction' 'order'
+ || lk == 112722 // 'attribute' 'return'
+ || lk == 112761 // 'element' 'return'
+ || lk == 112824 // 'namespace' 'return'
+ || lk == 112856 // 'processing-instruction' 'return'
+ || lk == 114770 // 'attribute' 'satisfies'
+ || lk == 114809 // 'element' 'satisfies'
+ || lk == 114872 // 'namespace' 'satisfies'
+ || lk == 114904 // 'processing-instruction' 'satisfies'
+ || lk == 120914 // 'attribute' 'stable'
+ || lk == 120953 // 'element' 'stable'
+ || lk == 121016 // 'namespace' 'stable'
+ || lk == 121048 // 'processing-instruction' 'stable'
+ || lk == 121426 // 'attribute' 'start'
+ || lk == 121465 // 'element' 'start'
+ || lk == 121528 // 'namespace' 'start'
+ || lk == 121560 // 'processing-instruction' 'start'
+ || lk == 127058 // 'attribute' 'to'
+ || lk == 127097 // 'element' 'to'
+ || lk == 127160 // 'namespace' 'to'
+ || lk == 127192 // 'processing-instruction' 'to'
+ || lk == 127570 // 'attribute' 'treat'
+ || lk == 127609 // 'element' 'treat'
+ || lk == 127672 // 'namespace' 'treat'
+ || lk == 127704 // 'processing-instruction' 'treat'
+ || lk == 130130 // 'attribute' 'union'
+ || lk == 130169 // 'element' 'union'
+ || lk == 130232 // 'namespace' 'union'
+ || lk == 130264 // 'processing-instruction' 'union'
+ || lk == 136274 // 'attribute' 'where'
+ || lk == 136313 // 'element' 'where'
+ || lk == 136376 // 'namespace' 'where'
+ || lk == 136408 // 'processing-instruction' 'where'
+ || lk == 138322 // 'attribute' 'with'
+ || lk == 138361 // 'element' 'with'
+ || lk == 138424 // 'namespace' 'with'
+ || lk == 138456) // 'processing-instruction' 'with'
+ {
+ lk = memoized(4, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_PostfixExpr();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(4, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 31: // '$'
+ case 32: // '%'
+ case 34: // '('
+ case 44: // '.'
+ case 54: // '<'
+ case 55: // '<!--'
+ case 59: // '<?'
+ case 68: // '['
+ case 276: // '{'
+ case 278: // '{|'
+ case 3154: // 'attribute' EQName^Token
+ case 3193: // 'element' EQName^Token
+ case 9912: // 'namespace' NCName^Token
+ case 9944: // 'processing-instruction' NCName^Token
+ case 14854: // EQName^Token '#'
+ case 14918: // 'after' '#'
+ case 14920: // 'allowing' '#'
+ case 14921: // 'ancestor' '#'
+ case 14922: // 'ancestor-or-self' '#'
+ case 14923: // 'and' '#'
+ case 14925: // 'append' '#'
+ case 14926: // 'array' '#'
+ case 14927: // 'as' '#'
+ case 14928: // 'ascending' '#'
+ case 14929: // 'at' '#'
+ case 14930: // 'attribute' '#'
+ case 14931: // 'base-uri' '#'
+ case 14932: // 'before' '#'
+ case 14933: // 'boundary-space' '#'
+ case 14934: // 'break' '#'
+ case 14936: // 'case' '#'
+ case 14937: // 'cast' '#'
+ case 14938: // 'castable' '#'
+ case 14939: // 'catch' '#'
+ case 14941: // 'child' '#'
+ case 14942: // 'collation' '#'
+ case 14944: // 'comment' '#'
+ case 14945: // 'constraint' '#'
+ case 14946: // 'construction' '#'
+ case 14949: // 'context' '#'
+ case 14950: // 'continue' '#'
+ case 14951: // 'copy' '#'
+ case 14952: // 'copy-namespaces' '#'
+ case 14953: // 'count' '#'
+ case 14954: // 'decimal-format' '#'
+ case 14956: // 'declare' '#'
+ case 14957: // 'default' '#'
+ case 14958: // 'delete' '#'
+ case 14959: // 'descendant' '#'
+ case 14960: // 'descendant-or-self' '#'
+ case 14961: // 'descending' '#'
+ case 14966: // 'div' '#'
+ case 14967: // 'document' '#'
+ case 14968: // 'document-node' '#'
+ case 14969: // 'element' '#'
+ case 14970: // 'else' '#'
+ case 14971: // 'empty' '#'
+ case 14972: // 'empty-sequence' '#'
+ case 14973: // 'encoding' '#'
+ case 14974: // 'end' '#'
+ case 14976: // 'eq' '#'
+ case 14977: // 'every' '#'
+ case 14979: // 'except' '#'
+ case 14980: // 'exit' '#'
+ case 14981: // 'external' '#'
+ case 14982: // 'first' '#'
+ case 14983: // 'following' '#'
+ case 14984: // 'following-sibling' '#'
+ case 14985: // 'for' '#'
+ case 14989: // 'ft-option' '#'
+ case 14993: // 'function' '#'
+ case 14994: // 'ge' '#'
+ case 14996: // 'group' '#'
+ case 14998: // 'gt' '#'
+ case 14999: // 'idiv' '#'
+ case 15000: // 'if' '#'
+ case 15001: // 'import' '#'
+ case 15002: // 'in' '#'
+ case 15003: // 'index' '#'
+ case 15007: // 'insert' '#'
+ case 15008: // 'instance' '#'
+ case 15009: // 'integrity' '#'
+ case 15010: // 'intersect' '#'
+ case 15011: // 'into' '#'
+ case 15012: // 'is' '#'
+ case 15013: // 'item' '#'
+ case 15014: // 'json' '#'
+ case 15015: // 'json-item' '#'
+ case 15018: // 'last' '#'
+ case 15019: // 'lax' '#'
+ case 15020: // 'le' '#'
+ case 15022: // 'let' '#'
+ case 15024: // 'loop' '#'
+ case 15026: // 'lt' '#'
+ case 15028: // 'mod' '#'
+ case 15029: // 'modify' '#'
+ case 15030: // 'module' '#'
+ case 15032: // 'namespace' '#'
+ case 15033: // 'namespace-node' '#'
+ case 15034: // 'ne' '#'
+ case 15039: // 'node' '#'
+ case 15040: // 'nodes' '#'
+ case 15042: // 'object' '#'
+ case 15046: // 'only' '#'
+ case 15047: // 'option' '#'
+ case 15048: // 'or' '#'
+ case 15049: // 'order' '#'
+ case 15050: // 'ordered' '#'
+ case 15051: // 'ordering' '#'
+ case 15054: // 'parent' '#'
+ case 15060: // 'preceding' '#'
+ case 15061: // 'preceding-sibling' '#'
+ case 15064: // 'processing-instruction' '#'
+ case 15066: // 'rename' '#'
+ case 15067: // 'replace' '#'
+ case 15068: // 'return' '#'
+ case 15069: // 'returning' '#'
+ case 15070: // 'revalidation' '#'
+ case 15072: // 'satisfies' '#'
+ case 15073: // 'schema' '#'
+ case 15074: // 'schema-attribute' '#'
+ case 15075: // 'schema-element' '#'
+ case 15076: // 'score' '#'
+ case 15077: // 'self' '#'
+ case 15082: // 'sliding' '#'
+ case 15083: // 'some' '#'
+ case 15084: // 'stable' '#'
+ case 15085: // 'start' '#'
+ case 15088: // 'strict' '#'
+ case 15090: // 'structured-item' '#'
+ case 15091: // 'switch' '#'
+ case 15092: // 'text' '#'
+ case 15096: // 'to' '#'
+ case 15097: // 'treat' '#'
+ case 15098: // 'try' '#'
+ case 15099: // 'tumbling' '#'
+ case 15100: // 'type' '#'
+ case 15101: // 'typeswitch' '#'
+ case 15102: // 'union' '#'
+ case 15104: // 'unordered' '#'
+ case 15105: // 'updating' '#'
+ case 15108: // 'validate' '#'
+ case 15109: // 'value' '#'
+ case 15110: // 'variable' '#'
+ case 15111: // 'version' '#'
+ case 15114: // 'where' '#'
+ case 15115: // 'while' '#'
+ case 15118: // 'with' '#'
+ case 15122: // 'xquery' '#'
+ case 17414: // EQName^Token '('
+ case 17478: // 'after' '('
+ case 17480: // 'allowing' '('
+ case 17481: // 'ancestor' '('
+ case 17482: // 'ancestor-or-self' '('
+ case 17483: // 'and' '('
+ case 17485: // 'append' '('
+ case 17487: // 'as' '('
+ case 17488: // 'ascending' '('
+ case 17489: // 'at' '('
+ case 17491: // 'base-uri' '('
+ case 17492: // 'before' '('
+ case 17493: // 'boundary-space' '('
+ case 17494: // 'break' '('
+ case 17496: // 'case' '('
+ case 17497: // 'cast' '('
+ case 17498: // 'castable' '('
+ case 17499: // 'catch' '('
+ case 17501: // 'child' '('
+ case 17502: // 'collation' '('
+ case 17505: // 'constraint' '('
+ case 17506: // 'construction' '('
+ case 17509: // 'context' '('
+ case 17510: // 'continue' '('
+ case 17511: // 'copy' '('
+ case 17512: // 'copy-namespaces' '('
+ case 17513: // 'count' '('
+ case 17514: // 'decimal-format' '('
+ case 17516: // 'declare' '('
+ case 17517: // 'default' '('
+ case 17518: // 'delete' '('
+ case 17519: // 'descendant' '('
+ case 17520: // 'descendant-or-self' '('
+ case 17521: // 'descending' '('
+ case 17526: // 'div' '('
+ case 17527: // 'document' '('
+ case 17530: // 'else' '('
+ case 17531: // 'empty' '('
+ case 17533: // 'encoding' '('
+ case 17534: // 'end' '('
+ case 17536: // 'eq' '('
+ case 17537: // 'every' '('
+ case 17539: // 'except' '('
+ case 17540: // 'exit' '('
+ case 17541: // 'external' '('
+ case 17542: // 'first' '('
+ case 17543: // 'following' '('
+ case 17544: // 'following-sibling' '('
+ case 17545: // 'for' '('
+ case 17549: // 'ft-option' '('
+ case 17553: // 'function' '('
+ case 17554: // 'ge' '('
+ case 17556: // 'group' '('
+ case 17558: // 'gt' '('
+ case 17559: // 'idiv' '('
+ case 17561: // 'import' '('
+ case 17562: // 'in' '('
+ case 17563: // 'index' '('
+ case 17567: // 'insert' '('
+ case 17568: // 'instance' '('
+ case 17569: // 'integrity' '('
+ case 17570: // 'intersect' '('
+ case 17571: // 'into' '('
+ case 17572: // 'is' '('
+ case 17574: // 'json' '('
+ case 17578: // 'last' '('
+ case 17579: // 'lax' '('
+ case 17580: // 'le' '('
+ case 17582: // 'let' '('
+ case 17584: // 'loop' '('
+ case 17586: // 'lt' '('
+ case 17588: // 'mod' '('
+ case 17589: // 'modify' '('
+ case 17590: // 'module' '('
+ case 17592: // 'namespace' '('
+ case 17594: // 'ne' '('
+ case 17600: // 'nodes' '('
+ case 17602: // 'object' '('
+ case 17606: // 'only' '('
+ case 17607: // 'option' '('
+ case 17608: // 'or' '('
+ case 17609: // 'order' '('
+ case 17610: // 'ordered' '('
+ case 17611: // 'ordering' '('
+ case 17614: // 'parent' '('
+ case 17620: // 'preceding' '('
+ case 17621: // 'preceding-sibling' '('
+ case 17626: // 'rename' '('
+ case 17627: // 'replace' '('
+ case 17628: // 'return' '('
+ case 17629: // 'returning' '('
+ case 17630: // 'revalidation' '('
+ case 17632: // 'satisfies' '('
+ case 17633: // 'schema' '('
+ case 17636: // 'score' '('
+ case 17637: // 'self' '('
+ case 17642: // 'sliding' '('
+ case 17643: // 'some' '('
+ case 17644: // 'stable' '('
+ case 17645: // 'start' '('
+ case 17648: // 'strict' '('
+ case 17656: // 'to' '('
+ case 17657: // 'treat' '('
+ case 17658: // 'try' '('
+ case 17659: // 'tumbling' '('
+ case 17660: // 'type' '('
+ case 17662: // 'union' '('
+ case 17664: // 'unordered' '('
+ case 17665: // 'updating' '('
+ case 17668: // 'validate' '('
+ case 17669: // 'value' '('
+ case 17670: // 'variable' '('
+ case 17671: // 'version' '('
+ case 17674: // 'where' '('
+ case 17675: // 'while' '('
+ case 17678: // 'with' '('
+ case 17682: // 'xquery' '('
+ case 36946: // 'attribute' 'allowing'
+ case 36985: // 'element' 'allowing'
+ case 37048: // 'namespace' 'allowing'
+ case 37080: // 'processing-instruction' 'allowing'
+ case 37458: // 'attribute' 'ancestor'
+ case 37497: // 'element' 'ancestor'
+ case 37560: // 'namespace' 'ancestor'
+ case 37592: // 'processing-instruction' 'ancestor'
+ case 37970: // 'attribute' 'ancestor-or-self'
+ case 38009: // 'element' 'ancestor-or-self'
+ case 38072: // 'namespace' 'ancestor-or-self'
+ case 38104: // 'processing-instruction' 'ancestor-or-self'
+ case 39506: // 'attribute' 'append'
+ case 39545: // 'element' 'append'
+ case 39608: // 'namespace' 'append'
+ case 39640: // 'processing-instruction' 'append'
+ case 40018: // 'attribute' 'array'
+ case 40057: // 'element' 'array'
+ case 42066: // 'attribute' 'attribute'
+ case 42105: // 'element' 'attribute'
+ case 42168: // 'namespace' 'attribute'
+ case 42200: // 'processing-instruction' 'attribute'
+ case 42578: // 'attribute' 'base-uri'
+ case 42617: // 'element' 'base-uri'
+ case 42680: // 'namespace' 'base-uri'
+ case 42712: // 'processing-instruction' 'base-uri'
+ case 43602: // 'attribute' 'boundary-space'
+ case 43641: // 'element' 'boundary-space'
+ case 43704: // 'namespace' 'boundary-space'
+ case 43736: // 'processing-instruction' 'boundary-space'
+ case 44114: // 'attribute' 'break'
+ case 44153: // 'element' 'break'
+ case 44216: // 'namespace' 'break'
+ case 44248: // 'processing-instruction' 'break'
+ case 46674: // 'attribute' 'catch'
+ case 46713: // 'element' 'catch'
+ case 46776: // 'namespace' 'catch'
+ case 46808: // 'processing-instruction' 'catch'
+ case 47698: // 'attribute' 'child'
+ case 47737: // 'element' 'child'
+ case 47800: // 'namespace' 'child'
+ case 47832: // 'processing-instruction' 'child'
+ case 49234: // 'attribute' 'comment'
+ case 49273: // 'element' 'comment'
+ case 49336: // 'namespace' 'comment'
+ case 49368: // 'processing-instruction' 'comment'
+ case 49746: // 'attribute' 'constraint'
+ case 49785: // 'element' 'constraint'
+ case 49848: // 'namespace' 'constraint'
+ case 49880: // 'processing-instruction' 'constraint'
+ case 50258: // 'attribute' 'construction'
+ case 50297: // 'element' 'construction'
+ case 50360: // 'namespace' 'construction'
+ case 50392: // 'processing-instruction' 'construction'
+ case 51794: // 'attribute' 'context'
+ case 51833: // 'element' 'context'
+ case 51896: // 'namespace' 'context'
+ case 51928: // 'processing-instruction' 'context'
+ case 52306: // 'attribute' 'continue'
+ case 52345: // 'element' 'continue'
+ case 52408: // 'namespace' 'continue'
+ case 52440: // 'processing-instruction' 'continue'
+ case 52818: // 'attribute' 'copy'
+ case 52857: // 'element' 'copy'
+ case 52920: // 'namespace' 'copy'
+ case 52952: // 'processing-instruction' 'copy'
+ case 53330: // 'attribute' 'copy-namespaces'
+ case 53369: // 'element' 'copy-namespaces'
+ case 53432: // 'namespace' 'copy-namespaces'
+ case 53464: // 'processing-instruction' 'copy-namespaces'
+ case 54354: // 'attribute' 'decimal-format'
+ case 54393: // 'element' 'decimal-format'
+ case 54456: // 'namespace' 'decimal-format'
+ case 54488: // 'processing-instruction' 'decimal-format'
+ case 55378: // 'attribute' 'declare'
+ case 55417: // 'element' 'declare'
+ case 55480: // 'namespace' 'declare'
+ case 55512: // 'processing-instruction' 'declare'
+ case 56402: // 'attribute' 'delete'
+ case 56441: // 'element' 'delete'
+ case 56504: // 'namespace' 'delete'
+ case 56536: // 'processing-instruction' 'delete'
+ case 56914: // 'attribute' 'descendant'
+ case 56953: // 'element' 'descendant'
+ case 57016: // 'namespace' 'descendant'
+ case 57048: // 'processing-instruction' 'descendant'
+ case 57426: // 'attribute' 'descendant-or-self'
+ case 57465: // 'element' 'descendant-or-self'
+ case 57528: // 'namespace' 'descendant-or-self'
+ case 57560: // 'processing-instruction' 'descendant-or-self'
+ case 61010: // 'attribute' 'document'
+ case 61049: // 'element' 'document'
+ case 61112: // 'namespace' 'document'
+ case 61144: // 'processing-instruction' 'document'
+ case 61522: // 'attribute' 'document-node'
+ case 61561: // 'element' 'document-node'
+ case 61624: // 'namespace' 'document-node'
+ case 61656: // 'processing-instruction' 'document-node'
+ case 62034: // 'attribute' 'element'
+ case 62073: // 'element' 'element'
+ case 62136: // 'namespace' 'element'
+ case 62168: // 'processing-instruction' 'element'
+ case 63570: // 'attribute' 'empty-sequence'
+ case 63609: // 'element' 'empty-sequence'
+ case 63672: // 'namespace' 'empty-sequence'
+ case 63704: // 'processing-instruction' 'empty-sequence'
+ case 64082: // 'attribute' 'encoding'
+ case 64121: // 'element' 'encoding'
+ case 64184: // 'namespace' 'encoding'
+ case 64216: // 'processing-instruction' 'encoding'
+ case 66130: // 'attribute' 'every'
+ case 66169: // 'element' 'every'
+ case 66232: // 'namespace' 'every'
+ case 66264: // 'processing-instruction' 'every'
+ case 67666: // 'attribute' 'exit'
+ case 67705: // 'element' 'exit'
+ case 67768: // 'namespace' 'exit'
+ case 67800: // 'processing-instruction' 'exit'
+ case 68178: // 'attribute' 'external'
+ case 68217: // 'element' 'external'
+ case 68280: // 'namespace' 'external'
+ case 68312: // 'processing-instruction' 'external'
+ case 68690: // 'attribute' 'first'
+ case 68729: // 'element' 'first'
+ case 68792: // 'namespace' 'first'
+ case 68824: // 'processing-instruction' 'first'
+ case 69202: // 'attribute' 'following'
+ case 69241: // 'element' 'following'
+ case 69304: // 'namespace' 'following'
+ case 69336: // 'processing-instruction' 'following'
+ case 69714: // 'attribute' 'following-sibling'
+ case 69753: // 'element' 'following-sibling'
+ case 69816: // 'namespace' 'following-sibling'
+ case 69848: // 'processing-instruction' 'following-sibling'
+ case 72274: // 'attribute' 'ft-option'
+ case 72313: // 'element' 'ft-option'
+ case 72376: // 'namespace' 'ft-option'
+ case 72408: // 'processing-instruction' 'ft-option'
+ case 74322: // 'attribute' 'function'
+ case 74361: // 'element' 'function'
+ case 74424: // 'namespace' 'function'
+ case 74456: // 'processing-instruction' 'function'
+ case 77906: // 'attribute' 'if'
+ case 77945: // 'element' 'if'
+ case 78008: // 'namespace' 'if'
+ case 78040: // 'processing-instruction' 'if'
+ case 78418: // 'attribute' 'import'
+ case 78457: // 'element' 'import'
+ case 78520: // 'namespace' 'import'
+ case 78552: // 'processing-instruction' 'import'
+ case 78930: // 'attribute' 'in'
+ case 78969: // 'element' 'in'
+ case 79032: // 'namespace' 'in'
+ case 79064: // 'processing-instruction' 'in'
+ case 79442: // 'attribute' 'index'
+ case 79481: // 'element' 'index'
+ case 79544: // 'namespace' 'index'
+ case 79576: // 'processing-instruction' 'index'
+ case 81490: // 'attribute' 'insert'
+ case 81529: // 'element' 'insert'
+ case 81592: // 'namespace' 'insert'
+ case 81624: // 'processing-instruction' 'insert'
+ case 82514: // 'attribute' 'integrity'
+ case 82553: // 'element' 'integrity'
+ case 82616: // 'namespace' 'integrity'
+ case 82648: // 'processing-instruction' 'integrity'
+ case 84562: // 'attribute' 'item'
+ case 84601: // 'element' 'item'
+ case 84664: // 'namespace' 'item'
+ case 84696: // 'processing-instruction' 'item'
+ case 85074: // 'attribute' 'json'
+ case 85113: // 'element' 'json'
+ case 85176: // 'namespace' 'json'
+ case 85208: // 'processing-instruction' 'json'
+ case 85586: // 'attribute' 'json-item'
+ case 85625: // 'element' 'json-item'
+ case 87122: // 'attribute' 'last'
+ case 87161: // 'element' 'last'
+ case 87224: // 'namespace' 'last'
+ case 87256: // 'processing-instruction' 'last'
+ case 87634: // 'attribute' 'lax'
+ case 87673: // 'element' 'lax'
+ case 87736: // 'namespace' 'lax'
+ case 87768: // 'processing-instruction' 'lax'
+ case 90194: // 'attribute' 'loop'
+ case 90233: // 'element' 'loop'
+ case 90296: // 'namespace' 'loop'
+ case 90328: // 'processing-instruction' 'loop'
+ case 93266: // 'attribute' 'module'
+ case 93305: // 'element' 'module'
+ case 93368: // 'namespace' 'module'
+ case 93400: // 'processing-instruction' 'module'
+ case 94290: // 'attribute' 'namespace'
+ case 94329: // 'element' 'namespace'
+ case 94392: // 'namespace' 'namespace'
+ case 94424: // 'processing-instruction' 'namespace'
+ case 94802: // 'attribute' 'namespace-node'
+ case 94841: // 'element' 'namespace-node'
+ case 94904: // 'namespace' 'namespace-node'
+ case 94936: // 'processing-instruction' 'namespace-node'
+ case 97874: // 'attribute' 'node'
+ case 97913: // 'element' 'node'
+ case 97976: // 'namespace' 'node'
+ case 98008: // 'processing-instruction' 'node'
+ case 98386: // 'attribute' 'nodes'
+ case 98425: // 'element' 'nodes'
+ case 98488: // 'namespace' 'nodes'
+ case 98520: // 'processing-instruction' 'nodes'
+ case 99410: // 'attribute' 'object'
+ case 99449: // 'element' 'object'
+ case 99512: // 'namespace' 'object'
+ case 99544: // 'processing-instruction' 'object'
+ case 101970: // 'attribute' 'option'
+ case 102009: // 'element' 'option'
+ case 102072: // 'namespace' 'option'
+ case 102104: // 'processing-instruction' 'option'
+ case 103506: // 'attribute' 'ordered'
+ case 103545: // 'element' 'ordered'
+ case 103608: // 'namespace' 'ordered'
+ case 103640: // 'processing-instruction' 'ordered'
+ case 104018: // 'attribute' 'ordering'
+ case 104057: // 'element' 'ordering'
+ case 104120: // 'namespace' 'ordering'
+ case 104152: // 'processing-instruction' 'ordering'
+ case 105554: // 'attribute' 'parent'
+ case 105593: // 'element' 'parent'
+ case 105656: // 'namespace' 'parent'
+ case 105688: // 'processing-instruction' 'parent'
+ case 108626: // 'attribute' 'preceding'
+ case 108665: // 'element' 'preceding'
+ case 108728: // 'namespace' 'preceding'
+ case 108760: // 'processing-instruction' 'preceding'
+ case 109138: // 'attribute' 'preceding-sibling'
+ case 109177: // 'element' 'preceding-sibling'
+ case 109240: // 'namespace' 'preceding-sibling'
+ case 109272: // 'processing-instruction' 'preceding-sibling'
+ case 110674: // 'attribute' 'processing-instruction'
+ case 110713: // 'element' 'processing-instruction'
+ case 110776: // 'namespace' 'processing-instruction'
+ case 110808: // 'processing-instruction' 'processing-instruction'
+ case 111698: // 'attribute' 'rename'
+ case 111737: // 'element' 'rename'
+ case 111800: // 'namespace' 'rename'
+ case 111832: // 'processing-instruction' 'rename'
+ case 112210: // 'attribute' 'replace'
+ case 112249: // 'element' 'replace'
+ case 112312: // 'namespace' 'replace'
+ case 112344: // 'processing-instruction' 'replace'
+ case 113234: // 'attribute' 'returning'
+ case 113273: // 'element' 'returning'
+ case 113336: // 'namespace' 'returning'
+ case 113368: // 'processing-instruction' 'returning'
+ case 113746: // 'attribute' 'revalidation'
+ case 113785: // 'element' 'revalidation'
+ case 113848: // 'namespace' 'revalidation'
+ case 113880: // 'processing-instruction' 'revalidation'
+ case 115282: // 'attribute' 'schema'
+ case 115321: // 'element' 'schema'
+ case 115384: // 'namespace' 'schema'
+ case 115416: // 'processing-instruction' 'schema'
+ case 115794: // 'attribute' 'schema-attribute'
+ case 115833: // 'element' 'schema-attribute'
+ case 115896: // 'namespace' 'schema-attribute'
+ case 115928: // 'processing-instruction' 'schema-attribute'
+ case 116306: // 'attribute' 'schema-element'
+ case 116345: // 'element' 'schema-element'
+ case 116408: // 'namespace' 'schema-element'
+ case 116440: // 'processing-instruction' 'schema-element'
+ case 116818: // 'attribute' 'score'
+ case 116857: // 'element' 'score'
+ case 116920: // 'namespace' 'score'
+ case 116952: // 'processing-instruction' 'score'
+ case 117330: // 'attribute' 'self'
+ case 117369: // 'element' 'self'
+ case 117432: // 'namespace' 'self'
+ case 117464: // 'processing-instruction' 'self'
+ case 119890: // 'attribute' 'sliding'
+ case 119929: // 'element' 'sliding'
+ case 119992: // 'namespace' 'sliding'
+ case 120024: // 'processing-instruction' 'sliding'
+ case 120402: // 'attribute' 'some'
+ case 120441: // 'element' 'some'
+ case 120504: // 'namespace' 'some'
+ case 120536: // 'processing-instruction' 'some'
+ case 122962: // 'attribute' 'strict'
+ case 123001: // 'element' 'strict'
+ case 123064: // 'namespace' 'strict'
+ case 123096: // 'processing-instruction' 'strict'
+ case 123986: // 'attribute' 'structured-item'
+ case 124025: // 'element' 'structured-item'
+ case 124498: // 'attribute' 'switch'
+ case 124537: // 'element' 'switch'
+ case 124600: // 'namespace' 'switch'
+ case 124632: // 'processing-instruction' 'switch'
+ case 125010: // 'attribute' 'text'
+ case 125049: // 'element' 'text'
+ case 125112: // 'namespace' 'text'
+ case 125144: // 'processing-instruction' 'text'
+ case 128082: // 'attribute' 'try'
+ case 128121: // 'element' 'try'
+ case 128184: // 'namespace' 'try'
+ case 128216: // 'processing-instruction' 'try'
+ case 128594: // 'attribute' 'tumbling'
+ case 128633: // 'element' 'tumbling'
+ case 128696: // 'namespace' 'tumbling'
+ case 128728: // 'processing-instruction' 'tumbling'
+ case 129106: // 'attribute' 'type'
+ case 129145: // 'element' 'type'
+ case 129208: // 'namespace' 'type'
+ case 129240: // 'processing-instruction' 'type'
+ case 129618: // 'attribute' 'typeswitch'
+ case 129657: // 'element' 'typeswitch'
+ case 129720: // 'namespace' 'typeswitch'
+ case 129752: // 'processing-instruction' 'typeswitch'
+ case 131154: // 'attribute' 'unordered'
+ case 131193: // 'element' 'unordered'
+ case 131256: // 'namespace' 'unordered'
+ case 131288: // 'processing-instruction' 'unordered'
+ case 131666: // 'attribute' 'updating'
+ case 131705: // 'element' 'updating'
+ case 131768: // 'namespace' 'updating'
+ case 131800: // 'processing-instruction' 'updating'
+ case 133202: // 'attribute' 'validate'
+ case 133241: // 'element' 'validate'
+ case 133304: // 'namespace' 'validate'
+ case 133336: // 'processing-instruction' 'validate'
+ case 133714: // 'attribute' 'value'
+ case 133753: // 'element' 'value'
+ case 133816: // 'namespace' 'value'
+ case 133848: // 'processing-instruction' 'value'
+ case 134226: // 'attribute' 'variable'
+ case 134265: // 'element' 'variable'
+ case 134328: // 'namespace' 'variable'
+ case 134360: // 'processing-instruction' 'variable'
+ case 134738: // 'attribute' 'version'
+ case 134777: // 'element' 'version'
+ case 134840: // 'namespace' 'version'
+ case 134872: // 'processing-instruction' 'version'
+ case 136786: // 'attribute' 'while'
+ case 136825: // 'element' 'while'
+ case 136888: // 'namespace' 'while'
+ case 136920: // 'processing-instruction' 'while'
+ case 140370: // 'attribute' 'xquery'
+ case 140409: // 'element' 'xquery'
+ case 140472: // 'namespace' 'xquery'
+ case 140504: // 'processing-instruction' 'xquery'
+ case 141394: // 'attribute' '{'
+ case 141408: // 'comment' '{'
+ case 141431: // 'document' '{'
+ case 141433: // 'element' '{'
+ case 141496: // 'namespace' '{'
+ case 141514: // 'ordered' '{'
+ case 141528: // 'processing-instruction' '{'
+ case 141556: // 'text' '{'
+ case 141568: // 'unordered' '{'
+ parse_PostfixExpr();
+ break;
+ default:
+ parse_AxisStep();
+ }
+ eventHandler.endNonterminal("StepExpr", e0);
+ }
+
+ function try_StepExpr()
+ {
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ lookahead2W(284); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 121: // 'element'
+ lookahead2W(282); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 184: // 'namespace'
+ case 216: // 'processing-instruction'
+ lookahead2W(281); // NCName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' |
+ break;
+ case 96: // 'comment'
+ case 119: // 'document'
+ case 202: // 'ordered'
+ case 244: // 'text'
+ case 256: // 'unordered'
+ lookahead2W(246); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 78: // 'array'
+ case 124: // 'empty-sequence'
+ case 152: // 'if'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 242: // 'structured-item'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ lookahead2W(239); // S^WS | EOF | '!' | '!=' | '#' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 93: // 'child'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ case 229: // 'self'
+ lookahead2W(245); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 6: // EQName^Token
+ case 70: // 'after'
+ case 72: // 'allowing'
+ case 75: // 'and'
+ case 77: // 'append'
+ case 79: // 'as'
+ case 80: // 'ascending'
+ case 81: // 'at'
+ case 83: // 'base-uri'
+ case 84: // 'before'
+ case 85: // 'boundary-space'
+ case 86: // 'break'
+ case 88: // 'case'
+ case 89: // 'cast'
+ case 90: // 'castable'
+ case 91: // 'catch'
+ case 94: // 'collation'
+ case 97: // 'constraint'
+ case 98: // 'construction'
+ case 101: // 'context'
+ case 102: // 'continue'
+ case 103: // 'copy'
+ case 104: // 'copy-namespaces'
+ case 105: // 'count'
+ case 106: // 'decimal-format'
+ case 108: // 'declare'
+ case 109: // 'default'
+ case 110: // 'delete'
+ case 113: // 'descending'
+ case 118: // 'div'
+ case 120: // 'document-node'
+ case 122: // 'else'
+ case 123: // 'empty'
+ case 125: // 'encoding'
+ case 126: // 'end'
+ case 128: // 'eq'
+ case 129: // 'every'
+ case 131: // 'except'
+ case 132: // 'exit'
+ case 133: // 'external'
+ case 134: // 'first'
+ case 137: // 'for'
+ case 141: // 'ft-option'
+ case 145: // 'function'
+ case 146: // 'ge'
+ case 148: // 'group'
+ case 150: // 'gt'
+ case 151: // 'idiv'
+ case 153: // 'import'
+ case 154: // 'in'
+ case 155: // 'index'
+ case 159: // 'insert'
+ case 160: // 'instance'
+ case 161: // 'integrity'
+ case 162: // 'intersect'
+ case 163: // 'into'
+ case 164: // 'is'
+ case 166: // 'json'
+ case 170: // 'last'
+ case 171: // 'lax'
+ case 172: // 'le'
+ case 174: // 'let'
+ case 176: // 'loop'
+ case 178: // 'lt'
+ case 180: // 'mod'
+ case 181: // 'modify'
+ case 182: // 'module'
+ case 185: // 'namespace-node'
+ case 186: // 'ne'
+ case 191: // 'node'
+ case 192: // 'nodes'
+ case 194: // 'object'
+ case 198: // 'only'
+ case 199: // 'option'
+ case 200: // 'or'
+ case 201: // 'order'
+ case 203: // 'ordering'
+ case 218: // 'rename'
+ case 219: // 'replace'
+ case 220: // 'return'
+ case 221: // 'returning'
+ case 222: // 'revalidation'
+ case 224: // 'satisfies'
+ case 225: // 'schema'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 228: // 'score'
+ case 234: // 'sliding'
+ case 235: // 'some'
+ case 236: // 'stable'
+ case 237: // 'start'
+ case 240: // 'strict'
+ case 248: // 'to'
+ case 249: // 'treat'
+ case 250: // 'try'
+ case 251: // 'tumbling'
+ case 252: // 'type'
+ case 254: // 'union'
+ case 257: // 'updating'
+ case 260: // 'validate'
+ case 261: // 'value'
+ case 262: // 'variable'
+ case 263: // 'version'
+ case 266: // 'where'
+ case 267: // 'while'
+ case 270: // 'with'
+ case 274: // 'xquery'
+ lookahead2W(243); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 35922 // 'attribute' 'after'
+ || lk == 35961 // 'element' 'after'
+ || lk == 36024 // 'namespace' 'after'
+ || lk == 36056 // 'processing-instruction' 'after'
+ || lk == 38482 // 'attribute' 'and'
+ || lk == 38521 // 'element' 'and'
+ || lk == 38584 // 'namespace' 'and'
+ || lk == 38616 // 'processing-instruction' 'and'
+ || lk == 40530 // 'attribute' 'as'
+ || lk == 40569 // 'element' 'as'
+ || lk == 40632 // 'namespace' 'as'
+ || lk == 40664 // 'processing-instruction' 'as'
+ || lk == 41042 // 'attribute' 'ascending'
+ || lk == 41081 // 'element' 'ascending'
+ || lk == 41144 // 'namespace' 'ascending'
+ || lk == 41176 // 'processing-instruction' 'ascending'
+ || lk == 41554 // 'attribute' 'at'
+ || lk == 41593 // 'element' 'at'
+ || lk == 41656 // 'namespace' 'at'
+ || lk == 41688 // 'processing-instruction' 'at'
+ || lk == 43090 // 'attribute' 'before'
+ || lk == 43129 // 'element' 'before'
+ || lk == 43192 // 'namespace' 'before'
+ || lk == 43224 // 'processing-instruction' 'before'
+ || lk == 45138 // 'attribute' 'case'
+ || lk == 45177 // 'element' 'case'
+ || lk == 45240 // 'namespace' 'case'
+ || lk == 45272 // 'processing-instruction' 'case'
+ || lk == 45650 // 'attribute' 'cast'
+ || lk == 45689 // 'element' 'cast'
+ || lk == 45752 // 'namespace' 'cast'
+ || lk == 45784 // 'processing-instruction' 'cast'
+ || lk == 46162 // 'attribute' 'castable'
+ || lk == 46201 // 'element' 'castable'
+ || lk == 46264 // 'namespace' 'castable'
+ || lk == 46296 // 'processing-instruction' 'castable'
+ || lk == 48210 // 'attribute' 'collation'
+ || lk == 48249 // 'element' 'collation'
+ || lk == 48312 // 'namespace' 'collation'
+ || lk == 48344 // 'processing-instruction' 'collation'
+ || lk == 53842 // 'attribute' 'count'
+ || lk == 53881 // 'element' 'count'
+ || lk == 53944 // 'namespace' 'count'
+ || lk == 53976 // 'processing-instruction' 'count'
+ || lk == 55890 // 'attribute' 'default'
+ || lk == 55929 // 'element' 'default'
+ || lk == 55992 // 'namespace' 'default'
+ || lk == 56024 // 'processing-instruction' 'default'
+ || lk == 57938 // 'attribute' 'descending'
+ || lk == 57977 // 'element' 'descending'
+ || lk == 58040 // 'namespace' 'descending'
+ || lk == 58072 // 'processing-instruction' 'descending'
+ || lk == 60498 // 'attribute' 'div'
+ || lk == 60537 // 'element' 'div'
+ || lk == 60600 // 'namespace' 'div'
+ || lk == 60632 // 'processing-instruction' 'div'
+ || lk == 62546 // 'attribute' 'else'
+ || lk == 62585 // 'element' 'else'
+ || lk == 62648 // 'namespace' 'else'
+ || lk == 62680 // 'processing-instruction' 'else'
+ || lk == 63058 // 'attribute' 'empty'
+ || lk == 63097 // 'element' 'empty'
+ || lk == 63160 // 'namespace' 'empty'
+ || lk == 63192 // 'processing-instruction' 'empty'
+ || lk == 64594 // 'attribute' 'end'
+ || lk == 64633 // 'element' 'end'
+ || lk == 64696 // 'namespace' 'end'
+ || lk == 64728 // 'processing-instruction' 'end'
+ || lk == 65618 // 'attribute' 'eq'
+ || lk == 65657 // 'element' 'eq'
+ || lk == 65720 // 'namespace' 'eq'
+ || lk == 65752 // 'processing-instruction' 'eq'
+ || lk == 67154 // 'attribute' 'except'
+ || lk == 67193 // 'element' 'except'
+ || lk == 67256 // 'namespace' 'except'
+ || lk == 67288 // 'processing-instruction' 'except'
+ || lk == 70226 // 'attribute' 'for'
+ || lk == 70265 // 'element' 'for'
+ || lk == 70328 // 'namespace' 'for'
+ || lk == 70360 // 'processing-instruction' 'for'
+ || lk == 74834 // 'attribute' 'ge'
+ || lk == 74873 // 'element' 'ge'
+ || lk == 74936 // 'namespace' 'ge'
+ || lk == 74968 // 'processing-instruction' 'ge'
+ || lk == 75858 // 'attribute' 'group'
+ || lk == 75897 // 'element' 'group'
+ || lk == 75960 // 'namespace' 'group'
+ || lk == 75992 // 'processing-instruction' 'group'
+ || lk == 76882 // 'attribute' 'gt'
+ || lk == 76921 // 'element' 'gt'
+ || lk == 76984 // 'namespace' 'gt'
+ || lk == 77016 // 'processing-instruction' 'gt'
+ || lk == 77394 // 'attribute' 'idiv'
+ || lk == 77433 // 'element' 'idiv'
+ || lk == 77496 // 'namespace' 'idiv'
+ || lk == 77528 // 'processing-instruction' 'idiv'
+ || lk == 82002 // 'attribute' 'instance'
+ || lk == 82041 // 'element' 'instance'
+ || lk == 82104 // 'namespace' 'instance'
+ || lk == 82136 // 'processing-instruction' 'instance'
+ || lk == 83026 // 'attribute' 'intersect'
+ || lk == 83065 // 'element' 'intersect'
+ || lk == 83128 // 'namespace' 'intersect'
+ || lk == 83160 // 'processing-instruction' 'intersect'
+ || lk == 83538 // 'attribute' 'into'
+ || lk == 83577 // 'element' 'into'
+ || lk == 83640 // 'namespace' 'into'
+ || lk == 83672 // 'processing-instruction' 'into'
+ || lk == 84050 // 'attribute' 'is'
+ || lk == 84089 // 'element' 'is'
+ || lk == 84152 // 'namespace' 'is'
+ || lk == 84184 // 'processing-instruction' 'is'
+ || lk == 88146 // 'attribute' 'le'
+ || lk == 88185 // 'element' 'le'
+ || lk == 88248 // 'namespace' 'le'
+ || lk == 88280 // 'processing-instruction' 'le'
+ || lk == 89170 // 'attribute' 'let'
+ || lk == 89209 // 'element' 'let'
+ || lk == 89272 // 'namespace' 'let'
+ || lk == 89304 // 'processing-instruction' 'let'
+ || lk == 91218 // 'attribute' 'lt'
+ || lk == 91257 // 'element' 'lt'
+ || lk == 91320 // 'namespace' 'lt'
+ || lk == 91352 // 'processing-instruction' 'lt'
+ || lk == 92242 // 'attribute' 'mod'
+ || lk == 92281 // 'element' 'mod'
+ || lk == 92344 // 'namespace' 'mod'
+ || lk == 92376 // 'processing-instruction' 'mod'
+ || lk == 92754 // 'attribute' 'modify'
+ || lk == 92793 // 'element' 'modify'
+ || lk == 92856 // 'namespace' 'modify'
+ || lk == 92888 // 'processing-instruction' 'modify'
+ || lk == 95314 // 'attribute' 'ne'
+ || lk == 95353 // 'element' 'ne'
+ || lk == 95416 // 'namespace' 'ne'
+ || lk == 95448 // 'processing-instruction' 'ne'
+ || lk == 101458 // 'attribute' 'only'
+ || lk == 101497 // 'element' 'only'
+ || lk == 101560 // 'namespace' 'only'
+ || lk == 101592 // 'processing-instruction' 'only'
+ || lk == 102482 // 'attribute' 'or'
+ || lk == 102521 // 'element' 'or'
+ || lk == 102584 // 'namespace' 'or'
+ || lk == 102616 // 'processing-instruction' 'or'
+ || lk == 102994 // 'attribute' 'order'
+ || lk == 103033 // 'element' 'order'
+ || lk == 103096 // 'namespace' 'order'
+ || lk == 103128 // 'processing-instruction' 'order'
+ || lk == 112722 // 'attribute' 'return'
+ || lk == 112761 // 'element' 'return'
+ || lk == 112824 // 'namespace' 'return'
+ || lk == 112856 // 'processing-instruction' 'return'
+ || lk == 114770 // 'attribute' 'satisfies'
+ || lk == 114809 // 'element' 'satisfies'
+ || lk == 114872 // 'namespace' 'satisfies'
+ || lk == 114904 // 'processing-instruction' 'satisfies'
+ || lk == 120914 // 'attribute' 'stable'
+ || lk == 120953 // 'element' 'stable'
+ || lk == 121016 // 'namespace' 'stable'
+ || lk == 121048 // 'processing-instruction' 'stable'
+ || lk == 121426 // 'attribute' 'start'
+ || lk == 121465 // 'element' 'start'
+ || lk == 121528 // 'namespace' 'start'
+ || lk == 121560 // 'processing-instruction' 'start'
+ || lk == 127058 // 'attribute' 'to'
+ || lk == 127097 // 'element' 'to'
+ || lk == 127160 // 'namespace' 'to'
+ || lk == 127192 // 'processing-instruction' 'to'
+ || lk == 127570 // 'attribute' 'treat'
+ || lk == 127609 // 'element' 'treat'
+ || lk == 127672 // 'namespace' 'treat'
+ || lk == 127704 // 'processing-instruction' 'treat'
+ || lk == 130130 // 'attribute' 'union'
+ || lk == 130169 // 'element' 'union'
+ || lk == 130232 // 'namespace' 'union'
+ || lk == 130264 // 'processing-instruction' 'union'
+ || lk == 136274 // 'attribute' 'where'
+ || lk == 136313 // 'element' 'where'
+ || lk == 136376 // 'namespace' 'where'
+ || lk == 136408 // 'processing-instruction' 'where'
+ || lk == 138322 // 'attribute' 'with'
+ || lk == 138361 // 'element' 'with'
+ || lk == 138424 // 'namespace' 'with'
+ || lk == 138456) // 'processing-instruction' 'with'
+ {
+ lk = memoized(4, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_PostfixExpr();
+ memoize(4, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(4, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 31: // '$'
+ case 32: // '%'
+ case 34: // '('
+ case 44: // '.'
+ case 54: // '<'
+ case 55: // '<!--'
+ case 59: // '<?'
+ case 68: // '['
+ case 276: // '{'
+ case 278: // '{|'
+ case 3154: // 'attribute' EQName^Token
+ case 3193: // 'element' EQName^Token
+ case 9912: // 'namespace' NCName^Token
+ case 9944: // 'processing-instruction' NCName^Token
+ case 14854: // EQName^Token '#'
+ case 14918: // 'after' '#'
+ case 14920: // 'allowing' '#'
+ case 14921: // 'ancestor' '#'
+ case 14922: // 'ancestor-or-self' '#'
+ case 14923: // 'and' '#'
+ case 14925: // 'append' '#'
+ case 14926: // 'array' '#'
+ case 14927: // 'as' '#'
+ case 14928: // 'ascending' '#'
+ case 14929: // 'at' '#'
+ case 14930: // 'attribute' '#'
+ case 14931: // 'base-uri' '#'
+ case 14932: // 'before' '#'
+ case 14933: // 'boundary-space' '#'
+ case 14934: // 'break' '#'
+ case 14936: // 'case' '#'
+ case 14937: // 'cast' '#'
+ case 14938: // 'castable' '#'
+ case 14939: // 'catch' '#'
+ case 14941: // 'child' '#'
+ case 14942: // 'collation' '#'
+ case 14944: // 'comment' '#'
+ case 14945: // 'constraint' '#'
+ case 14946: // 'construction' '#'
+ case 14949: // 'context' '#'
+ case 14950: // 'continue' '#'
+ case 14951: // 'copy' '#'
+ case 14952: // 'copy-namespaces' '#'
+ case 14953: // 'count' '#'
+ case 14954: // 'decimal-format' '#'
+ case 14956: // 'declare' '#'
+ case 14957: // 'default' '#'
+ case 14958: // 'delete' '#'
+ case 14959: // 'descendant' '#'
+ case 14960: // 'descendant-or-self' '#'
+ case 14961: // 'descending' '#'
+ case 14966: // 'div' '#'
+ case 14967: // 'document' '#'
+ case 14968: // 'document-node' '#'
+ case 14969: // 'element' '#'
+ case 14970: // 'else' '#'
+ case 14971: // 'empty' '#'
+ case 14972: // 'empty-sequence' '#'
+ case 14973: // 'encoding' '#'
+ case 14974: // 'end' '#'
+ case 14976: // 'eq' '#'
+ case 14977: // 'every' '#'
+ case 14979: // 'except' '#'
+ case 14980: // 'exit' '#'
+ case 14981: // 'external' '#'
+ case 14982: // 'first' '#'
+ case 14983: // 'following' '#'
+ case 14984: // 'following-sibling' '#'
+ case 14985: // 'for' '#'
+ case 14989: // 'ft-option' '#'
+ case 14993: // 'function' '#'
+ case 14994: // 'ge' '#'
+ case 14996: // 'group' '#'
+ case 14998: // 'gt' '#'
+ case 14999: // 'idiv' '#'
+ case 15000: // 'if' '#'
+ case 15001: // 'import' '#'
+ case 15002: // 'in' '#'
+ case 15003: // 'index' '#'
+ case 15007: // 'insert' '#'
+ case 15008: // 'instance' '#'
+ case 15009: // 'integrity' '#'
+ case 15010: // 'intersect' '#'
+ case 15011: // 'into' '#'
+ case 15012: // 'is' '#'
+ case 15013: // 'item' '#'
+ case 15014: // 'json' '#'
+ case 15015: // 'json-item' '#'
+ case 15018: // 'last' '#'
+ case 15019: // 'lax' '#'
+ case 15020: // 'le' '#'
+ case 15022: // 'let' '#'
+ case 15024: // 'loop' '#'
+ case 15026: // 'lt' '#'
+ case 15028: // 'mod' '#'
+ case 15029: // 'modify' '#'
+ case 15030: // 'module' '#'
+ case 15032: // 'namespace' '#'
+ case 15033: // 'namespace-node' '#'
+ case 15034: // 'ne' '#'
+ case 15039: // 'node' '#'
+ case 15040: // 'nodes' '#'
+ case 15042: // 'object' '#'
+ case 15046: // 'only' '#'
+ case 15047: // 'option' '#'
+ case 15048: // 'or' '#'
+ case 15049: // 'order' '#'
+ case 15050: // 'ordered' '#'
+ case 15051: // 'ordering' '#'
+ case 15054: // 'parent' '#'
+ case 15060: // 'preceding' '#'
+ case 15061: // 'preceding-sibling' '#'
+ case 15064: // 'processing-instruction' '#'
+ case 15066: // 'rename' '#'
+ case 15067: // 'replace' '#'
+ case 15068: // 'return' '#'
+ case 15069: // 'returning' '#'
+ case 15070: // 'revalidation' '#'
+ case 15072: // 'satisfies' '#'
+ case 15073: // 'schema' '#'
+ case 15074: // 'schema-attribute' '#'
+ case 15075: // 'schema-element' '#'
+ case 15076: // 'score' '#'
+ case 15077: // 'self' '#'
+ case 15082: // 'sliding' '#'
+ case 15083: // 'some' '#'
+ case 15084: // 'stable' '#'
+ case 15085: // 'start' '#'
+ case 15088: // 'strict' '#'
+ case 15090: // 'structured-item' '#'
+ case 15091: // 'switch' '#'
+ case 15092: // 'text' '#'
+ case 15096: // 'to' '#'
+ case 15097: // 'treat' '#'
+ case 15098: // 'try' '#'
+ case 15099: // 'tumbling' '#'
+ case 15100: // 'type' '#'
+ case 15101: // 'typeswitch' '#'
+ case 15102: // 'union' '#'
+ case 15104: // 'unordered' '#'
+ case 15105: // 'updating' '#'
+ case 15108: // 'validate' '#'
+ case 15109: // 'value' '#'
+ case 15110: // 'variable' '#'
+ case 15111: // 'version' '#'
+ case 15114: // 'where' '#'
+ case 15115: // 'while' '#'
+ case 15118: // 'with' '#'
+ case 15122: // 'xquery' '#'
+ case 17414: // EQName^Token '('
+ case 17478: // 'after' '('
+ case 17480: // 'allowing' '('
+ case 17481: // 'ancestor' '('
+ case 17482: // 'ancestor-or-self' '('
+ case 17483: // 'and' '('
+ case 17485: // 'append' '('
+ case 17487: // 'as' '('
+ case 17488: // 'ascending' '('
+ case 17489: // 'at' '('
+ case 17491: // 'base-uri' '('
+ case 17492: // 'before' '('
+ case 17493: // 'boundary-space' '('
+ case 17494: // 'break' '('
+ case 17496: // 'case' '('
+ case 17497: // 'cast' '('
+ case 17498: // 'castable' '('
+ case 17499: // 'catch' '('
+ case 17501: // 'child' '('
+ case 17502: // 'collation' '('
+ case 17505: // 'constraint' '('
+ case 17506: // 'construction' '('
+ case 17509: // 'context' '('
+ case 17510: // 'continue' '('
+ case 17511: // 'copy' '('
+ case 17512: // 'copy-namespaces' '('
+ case 17513: // 'count' '('
+ case 17514: // 'decimal-format' '('
+ case 17516: // 'declare' '('
+ case 17517: // 'default' '('
+ case 17518: // 'delete' '('
+ case 17519: // 'descendant' '('
+ case 17520: // 'descendant-or-self' '('
+ case 17521: // 'descending' '('
+ case 17526: // 'div' '('
+ case 17527: // 'document' '('
+ case 17530: // 'else' '('
+ case 17531: // 'empty' '('
+ case 17533: // 'encoding' '('
+ case 17534: // 'end' '('
+ case 17536: // 'eq' '('
+ case 17537: // 'every' '('
+ case 17539: // 'except' '('
+ case 17540: // 'exit' '('
+ case 17541: // 'external' '('
+ case 17542: // 'first' '('
+ case 17543: // 'following' '('
+ case 17544: // 'following-sibling' '('
+ case 17545: // 'for' '('
+ case 17549: // 'ft-option' '('
+ case 17553: // 'function' '('
+ case 17554: // 'ge' '('
+ case 17556: // 'group' '('
+ case 17558: // 'gt' '('
+ case 17559: // 'idiv' '('
+ case 17561: // 'import' '('
+ case 17562: // 'in' '('
+ case 17563: // 'index' '('
+ case 17567: // 'insert' '('
+ case 17568: // 'instance' '('
+ case 17569: // 'integrity' '('
+ case 17570: // 'intersect' '('
+ case 17571: // 'into' '('
+ case 17572: // 'is' '('
+ case 17574: // 'json' '('
+ case 17578: // 'last' '('
+ case 17579: // 'lax' '('
+ case 17580: // 'le' '('
+ case 17582: // 'let' '('
+ case 17584: // 'loop' '('
+ case 17586: // 'lt' '('
+ case 17588: // 'mod' '('
+ case 17589: // 'modify' '('
+ case 17590: // 'module' '('
+ case 17592: // 'namespace' '('
+ case 17594: // 'ne' '('
+ case 17600: // 'nodes' '('
+ case 17602: // 'object' '('
+ case 17606: // 'only' '('
+ case 17607: // 'option' '('
+ case 17608: // 'or' '('
+ case 17609: // 'order' '('
+ case 17610: // 'ordered' '('
+ case 17611: // 'ordering' '('
+ case 17614: // 'parent' '('
+ case 17620: // 'preceding' '('
+ case 17621: // 'preceding-sibling' '('
+ case 17626: // 'rename' '('
+ case 17627: // 'replace' '('
+ case 17628: // 'return' '('
+ case 17629: // 'returning' '('
+ case 17630: // 'revalidation' '('
+ case 17632: // 'satisfies' '('
+ case 17633: // 'schema' '('
+ case 17636: // 'score' '('
+ case 17637: // 'self' '('
+ case 17642: // 'sliding' '('
+ case 17643: // 'some' '('
+ case 17644: // 'stable' '('
+ case 17645: // 'start' '('
+ case 17648: // 'strict' '('
+ case 17656: // 'to' '('
+ case 17657: // 'treat' '('
+ case 17658: // 'try' '('
+ case 17659: // 'tumbling' '('
+ case 17660: // 'type' '('
+ case 17662: // 'union' '('
+ case 17664: // 'unordered' '('
+ case 17665: // 'updating' '('
+ case 17668: // 'validate' '('
+ case 17669: // 'value' '('
+ case 17670: // 'variable' '('
+ case 17671: // 'version' '('
+ case 17674: // 'where' '('
+ case 17675: // 'while' '('
+ case 17678: // 'with' '('
+ case 17682: // 'xquery' '('
+ case 36946: // 'attribute' 'allowing'
+ case 36985: // 'element' 'allowing'
+ case 37048: // 'namespace' 'allowing'
+ case 37080: // 'processing-instruction' 'allowing'
+ case 37458: // 'attribute' 'ancestor'
+ case 37497: // 'element' 'ancestor'
+ case 37560: // 'namespace' 'ancestor'
+ case 37592: // 'processing-instruction' 'ancestor'
+ case 37970: // 'attribute' 'ancestor-or-self'
+ case 38009: // 'element' 'ancestor-or-self'
+ case 38072: // 'namespace' 'ancestor-or-self'
+ case 38104: // 'processing-instruction' 'ancestor-or-self'
+ case 39506: // 'attribute' 'append'
+ case 39545: // 'element' 'append'
+ case 39608: // 'namespace' 'append'
+ case 39640: // 'processing-instruction' 'append'
+ case 40018: // 'attribute' 'array'
+ case 40057: // 'element' 'array'
+ case 42066: // 'attribute' 'attribute'
+ case 42105: // 'element' 'attribute'
+ case 42168: // 'namespace' 'attribute'
+ case 42200: // 'processing-instruction' 'attribute'
+ case 42578: // 'attribute' 'base-uri'
+ case 42617: // 'element' 'base-uri'
+ case 42680: // 'namespace' 'base-uri'
+ case 42712: // 'processing-instruction' 'base-uri'
+ case 43602: // 'attribute' 'boundary-space'
+ case 43641: // 'element' 'boundary-space'
+ case 43704: // 'namespace' 'boundary-space'
+ case 43736: // 'processing-instruction' 'boundary-space'
+ case 44114: // 'attribute' 'break'
+ case 44153: // 'element' 'break'
+ case 44216: // 'namespace' 'break'
+ case 44248: // 'processing-instruction' 'break'
+ case 46674: // 'attribute' 'catch'
+ case 46713: // 'element' 'catch'
+ case 46776: // 'namespace' 'catch'
+ case 46808: // 'processing-instruction' 'catch'
+ case 47698: // 'attribute' 'child'
+ case 47737: // 'element' 'child'
+ case 47800: // 'namespace' 'child'
+ case 47832: // 'processing-instruction' 'child'
+ case 49234: // 'attribute' 'comment'
+ case 49273: // 'element' 'comment'
+ case 49336: // 'namespace' 'comment'
+ case 49368: // 'processing-instruction' 'comment'
+ case 49746: // 'attribute' 'constraint'
+ case 49785: // 'element' 'constraint'
+ case 49848: // 'namespace' 'constraint'
+ case 49880: // 'processing-instruction' 'constraint'
+ case 50258: // 'attribute' 'construction'
+ case 50297: // 'element' 'construction'
+ case 50360: // 'namespace' 'construction'
+ case 50392: // 'processing-instruction' 'construction'
+ case 51794: // 'attribute' 'context'
+ case 51833: // 'element' 'context'
+ case 51896: // 'namespace' 'context'
+ case 51928: // 'processing-instruction' 'context'
+ case 52306: // 'attribute' 'continue'
+ case 52345: // 'element' 'continue'
+ case 52408: // 'namespace' 'continue'
+ case 52440: // 'processing-instruction' 'continue'
+ case 52818: // 'attribute' 'copy'
+ case 52857: // 'element' 'copy'
+ case 52920: // 'namespace' 'copy'
+ case 52952: // 'processing-instruction' 'copy'
+ case 53330: // 'attribute' 'copy-namespaces'
+ case 53369: // 'element' 'copy-namespaces'
+ case 53432: // 'namespace' 'copy-namespaces'
+ case 53464: // 'processing-instruction' 'copy-namespaces'
+ case 54354: // 'attribute' 'decimal-format'
+ case 54393: // 'element' 'decimal-format'
+ case 54456: // 'namespace' 'decimal-format'
+ case 54488: // 'processing-instruction' 'decimal-format'
+ case 55378: // 'attribute' 'declare'
+ case 55417: // 'element' 'declare'
+ case 55480: // 'namespace' 'declare'
+ case 55512: // 'processing-instruction' 'declare'
+ case 56402: // 'attribute' 'delete'
+ case 56441: // 'element' 'delete'
+ case 56504: // 'namespace' 'delete'
+ case 56536: // 'processing-instruction' 'delete'
+ case 56914: // 'attribute' 'descendant'
+ case 56953: // 'element' 'descendant'
+ case 57016: // 'namespace' 'descendant'
+ case 57048: // 'processing-instruction' 'descendant'
+ case 57426: // 'attribute' 'descendant-or-self'
+ case 57465: // 'element' 'descendant-or-self'
+ case 57528: // 'namespace' 'descendant-or-self'
+ case 57560: // 'processing-instruction' 'descendant-or-self'
+ case 61010: // 'attribute' 'document'
+ case 61049: // 'element' 'document'
+ case 61112: // 'namespace' 'document'
+ case 61144: // 'processing-instruction' 'document'
+ case 61522: // 'attribute' 'document-node'
+ case 61561: // 'element' 'document-node'
+ case 61624: // 'namespace' 'document-node'
+ case 61656: // 'processing-instruction' 'document-node'
+ case 62034: // 'attribute' 'element'
+ case 62073: // 'element' 'element'
+ case 62136: // 'namespace' 'element'
+ case 62168: // 'processing-instruction' 'element'
+ case 63570: // 'attribute' 'empty-sequence'
+ case 63609: // 'element' 'empty-sequence'
+ case 63672: // 'namespace' 'empty-sequence'
+ case 63704: // 'processing-instruction' 'empty-sequence'
+ case 64082: // 'attribute' 'encoding'
+ case 64121: // 'element' 'encoding'
+ case 64184: // 'namespace' 'encoding'
+ case 64216: // 'processing-instruction' 'encoding'
+ case 66130: // 'attribute' 'every'
+ case 66169: // 'element' 'every'
+ case 66232: // 'namespace' 'every'
+ case 66264: // 'processing-instruction' 'every'
+ case 67666: // 'attribute' 'exit'
+ case 67705: // 'element' 'exit'
+ case 67768: // 'namespace' 'exit'
+ case 67800: // 'processing-instruction' 'exit'
+ case 68178: // 'attribute' 'external'
+ case 68217: // 'element' 'external'
+ case 68280: // 'namespace' 'external'
+ case 68312: // 'processing-instruction' 'external'
+ case 68690: // 'attribute' 'first'
+ case 68729: // 'element' 'first'
+ case 68792: // 'namespace' 'first'
+ case 68824: // 'processing-instruction' 'first'
+ case 69202: // 'attribute' 'following'
+ case 69241: // 'element' 'following'
+ case 69304: // 'namespace' 'following'
+ case 69336: // 'processing-instruction' 'following'
+ case 69714: // 'attribute' 'following-sibling'
+ case 69753: // 'element' 'following-sibling'
+ case 69816: // 'namespace' 'following-sibling'
+ case 69848: // 'processing-instruction' 'following-sibling'
+ case 72274: // 'attribute' 'ft-option'
+ case 72313: // 'element' 'ft-option'
+ case 72376: // 'namespace' 'ft-option'
+ case 72408: // 'processing-instruction' 'ft-option'
+ case 74322: // 'attribute' 'function'
+ case 74361: // 'element' 'function'
+ case 74424: // 'namespace' 'function'
+ case 74456: // 'processing-instruction' 'function'
+ case 77906: // 'attribute' 'if'
+ case 77945: // 'element' 'if'
+ case 78008: // 'namespace' 'if'
+ case 78040: // 'processing-instruction' 'if'
+ case 78418: // 'attribute' 'import'
+ case 78457: // 'element' 'import'
+ case 78520: // 'namespace' 'import'
+ case 78552: // 'processing-instruction' 'import'
+ case 78930: // 'attribute' 'in'
+ case 78969: // 'element' 'in'
+ case 79032: // 'namespace' 'in'
+ case 79064: // 'processing-instruction' 'in'
+ case 79442: // 'attribute' 'index'
+ case 79481: // 'element' 'index'
+ case 79544: // 'namespace' 'index'
+ case 79576: // 'processing-instruction' 'index'
+ case 81490: // 'attribute' 'insert'
+ case 81529: // 'element' 'insert'
+ case 81592: // 'namespace' 'insert'
+ case 81624: // 'processing-instruction' 'insert'
+ case 82514: // 'attribute' 'integrity'
+ case 82553: // 'element' 'integrity'
+ case 82616: // 'namespace' 'integrity'
+ case 82648: // 'processing-instruction' 'integrity'
+ case 84562: // 'attribute' 'item'
+ case 84601: // 'element' 'item'
+ case 84664: // 'namespace' 'item'
+ case 84696: // 'processing-instruction' 'item'
+ case 85074: // 'attribute' 'json'
+ case 85113: // 'element' 'json'
+ case 85176: // 'namespace' 'json'
+ case 85208: // 'processing-instruction' 'json'
+ case 85586: // 'attribute' 'json-item'
+ case 85625: // 'element' 'json-item'
+ case 87122: // 'attribute' 'last'
+ case 87161: // 'element' 'last'
+ case 87224: // 'namespace' 'last'
+ case 87256: // 'processing-instruction' 'last'
+ case 87634: // 'attribute' 'lax'
+ case 87673: // 'element' 'lax'
+ case 87736: // 'namespace' 'lax'
+ case 87768: // 'processing-instruction' 'lax'
+ case 90194: // 'attribute' 'loop'
+ case 90233: // 'element' 'loop'
+ case 90296: // 'namespace' 'loop'
+ case 90328: // 'processing-instruction' 'loop'
+ case 93266: // 'attribute' 'module'
+ case 93305: // 'element' 'module'
+ case 93368: // 'namespace' 'module'
+ case 93400: // 'processing-instruction' 'module'
+ case 94290: // 'attribute' 'namespace'
+ case 94329: // 'element' 'namespace'
+ case 94392: // 'namespace' 'namespace'
+ case 94424: // 'processing-instruction' 'namespace'
+ case 94802: // 'attribute' 'namespace-node'
+ case 94841: // 'element' 'namespace-node'
+ case 94904: // 'namespace' 'namespace-node'
+ case 94936: // 'processing-instruction' 'namespace-node'
+ case 97874: // 'attribute' 'node'
+ case 97913: // 'element' 'node'
+ case 97976: // 'namespace' 'node'
+ case 98008: // 'processing-instruction' 'node'
+ case 98386: // 'attribute' 'nodes'
+ case 98425: // 'element' 'nodes'
+ case 98488: // 'namespace' 'nodes'
+ case 98520: // 'processing-instruction' 'nodes'
+ case 99410: // 'attribute' 'object'
+ case 99449: // 'element' 'object'
+ case 99512: // 'namespace' 'object'
+ case 99544: // 'processing-instruction' 'object'
+ case 101970: // 'attribute' 'option'
+ case 102009: // 'element' 'option'
+ case 102072: // 'namespace' 'option'
+ case 102104: // 'processing-instruction' 'option'
+ case 103506: // 'attribute' 'ordered'
+ case 103545: // 'element' 'ordered'
+ case 103608: // 'namespace' 'ordered'
+ case 103640: // 'processing-instruction' 'ordered'
+ case 104018: // 'attribute' 'ordering'
+ case 104057: // 'element' 'ordering'
+ case 104120: // 'namespace' 'ordering'
+ case 104152: // 'processing-instruction' 'ordering'
+ case 105554: // 'attribute' 'parent'
+ case 105593: // 'element' 'parent'
+ case 105656: // 'namespace' 'parent'
+ case 105688: // 'processing-instruction' 'parent'
+ case 108626: // 'attribute' 'preceding'
+ case 108665: // 'element' 'preceding'
+ case 108728: // 'namespace' 'preceding'
+ case 108760: // 'processing-instruction' 'preceding'
+ case 109138: // 'attribute' 'preceding-sibling'
+ case 109177: // 'element' 'preceding-sibling'
+ case 109240: // 'namespace' 'preceding-sibling'
+ case 109272: // 'processing-instruction' 'preceding-sibling'
+ case 110674: // 'attribute' 'processing-instruction'
+ case 110713: // 'element' 'processing-instruction'
+ case 110776: // 'namespace' 'processing-instruction'
+ case 110808: // 'processing-instruction' 'processing-instruction'
+ case 111698: // 'attribute' 'rename'
+ case 111737: // 'element' 'rename'
+ case 111800: // 'namespace' 'rename'
+ case 111832: // 'processing-instruction' 'rename'
+ case 112210: // 'attribute' 'replace'
+ case 112249: // 'element' 'replace'
+ case 112312: // 'namespace' 'replace'
+ case 112344: // 'processing-instruction' 'replace'
+ case 113234: // 'attribute' 'returning'
+ case 113273: // 'element' 'returning'
+ case 113336: // 'namespace' 'returning'
+ case 113368: // 'processing-instruction' 'returning'
+ case 113746: // 'attribute' 'revalidation'
+ case 113785: // 'element' 'revalidation'
+ case 113848: // 'namespace' 'revalidation'
+ case 113880: // 'processing-instruction' 'revalidation'
+ case 115282: // 'attribute' 'schema'
+ case 115321: // 'element' 'schema'
+ case 115384: // 'namespace' 'schema'
+ case 115416: // 'processing-instruction' 'schema'
+ case 115794: // 'attribute' 'schema-attribute'
+ case 115833: // 'element' 'schema-attribute'
+ case 115896: // 'namespace' 'schema-attribute'
+ case 115928: // 'processing-instruction' 'schema-attribute'
+ case 116306: // 'attribute' 'schema-element'
+ case 116345: // 'element' 'schema-element'
+ case 116408: // 'namespace' 'schema-element'
+ case 116440: // 'processing-instruction' 'schema-element'
+ case 116818: // 'attribute' 'score'
+ case 116857: // 'element' 'score'
+ case 116920: // 'namespace' 'score'
+ case 116952: // 'processing-instruction' 'score'
+ case 117330: // 'attribute' 'self'
+ case 117369: // 'element' 'self'
+ case 117432: // 'namespace' 'self'
+ case 117464: // 'processing-instruction' 'self'
+ case 119890: // 'attribute' 'sliding'
+ case 119929: // 'element' 'sliding'
+ case 119992: // 'namespace' 'sliding'
+ case 120024: // 'processing-instruction' 'sliding'
+ case 120402: // 'attribute' 'some'
+ case 120441: // 'element' 'some'
+ case 120504: // 'namespace' 'some'
+ case 120536: // 'processing-instruction' 'some'
+ case 122962: // 'attribute' 'strict'
+ case 123001: // 'element' 'strict'
+ case 123064: // 'namespace' 'strict'
+ case 123096: // 'processing-instruction' 'strict'
+ case 123986: // 'attribute' 'structured-item'
+ case 124025: // 'element' 'structured-item'
+ case 124498: // 'attribute' 'switch'
+ case 124537: // 'element' 'switch'
+ case 124600: // 'namespace' 'switch'
+ case 124632: // 'processing-instruction' 'switch'
+ case 125010: // 'attribute' 'text'
+ case 125049: // 'element' 'text'
+ case 125112: // 'namespace' 'text'
+ case 125144: // 'processing-instruction' 'text'
+ case 128082: // 'attribute' 'try'
+ case 128121: // 'element' 'try'
+ case 128184: // 'namespace' 'try'
+ case 128216: // 'processing-instruction' 'try'
+ case 128594: // 'attribute' 'tumbling'
+ case 128633: // 'element' 'tumbling'
+ case 128696: // 'namespace' 'tumbling'
+ case 128728: // 'processing-instruction' 'tumbling'
+ case 129106: // 'attribute' 'type'
+ case 129145: // 'element' 'type'
+ case 129208: // 'namespace' 'type'
+ case 129240: // 'processing-instruction' 'type'
+ case 129618: // 'attribute' 'typeswitch'
+ case 129657: // 'element' 'typeswitch'
+ case 129720: // 'namespace' 'typeswitch'
+ case 129752: // 'processing-instruction' 'typeswitch'
+ case 131154: // 'attribute' 'unordered'
+ case 131193: // 'element' 'unordered'
+ case 131256: // 'namespace' 'unordered'
+ case 131288: // 'processing-instruction' 'unordered'
+ case 131666: // 'attribute' 'updating'
+ case 131705: // 'element' 'updating'
+ case 131768: // 'namespace' 'updating'
+ case 131800: // 'processing-instruction' 'updating'
+ case 133202: // 'attribute' 'validate'
+ case 133241: // 'element' 'validate'
+ case 133304: // 'namespace' 'validate'
+ case 133336: // 'processing-instruction' 'validate'
+ case 133714: // 'attribute' 'value'
+ case 133753: // 'element' 'value'
+ case 133816: // 'namespace' 'value'
+ case 133848: // 'processing-instruction' 'value'
+ case 134226: // 'attribute' 'variable'
+ case 134265: // 'element' 'variable'
+ case 134328: // 'namespace' 'variable'
+ case 134360: // 'processing-instruction' 'variable'
+ case 134738: // 'attribute' 'version'
+ case 134777: // 'element' 'version'
+ case 134840: // 'namespace' 'version'
+ case 134872: // 'processing-instruction' 'version'
+ case 136786: // 'attribute' 'while'
+ case 136825: // 'element' 'while'
+ case 136888: // 'namespace' 'while'
+ case 136920: // 'processing-instruction' 'while'
+ case 140370: // 'attribute' 'xquery'
+ case 140409: // 'element' 'xquery'
+ case 140472: // 'namespace' 'xquery'
+ case 140504: // 'processing-instruction' 'xquery'
+ case 141394: // 'attribute' '{'
+ case 141408: // 'comment' '{'
+ case 141431: // 'document' '{'
+ case 141433: // 'element' '{'
+ case 141496: // 'namespace' '{'
+ case 141514: // 'ordered' '{'
+ case 141528: // 'processing-instruction' '{'
+ case 141556: // 'text' '{'
+ case 141568: // 'unordered' '{'
+ try_PostfixExpr();
+ break;
+ case -3:
+ break;
+ default:
+ try_AxisStep();
+ }
+ }
+
+ function parse_AxisStep()
+ {
+ eventHandler.startNonterminal("AxisStep", e0);
+ switch (l1)
+ {
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ lookahead2W(241); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 45: // '..'
+ case 26185: // 'ancestor' '::'
+ case 26186: // 'ancestor-or-self' '::'
+ case 26318: // 'parent' '::'
+ case 26324: // 'preceding' '::'
+ case 26325: // 'preceding-sibling' '::'
+ parse_ReverseStep();
+ break;
+ default:
+ parse_ForwardStep();
+ }
+ lookahead1W(237); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ whitespace();
+ parse_PredicateList();
+ eventHandler.endNonterminal("AxisStep", e0);
+ }
+
+ function try_AxisStep()
+ {
+ switch (l1)
+ {
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ lookahead2W(241); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 45: // '..'
+ case 26185: // 'ancestor' '::'
+ case 26186: // 'ancestor-or-self' '::'
+ case 26318: // 'parent' '::'
+ case 26324: // 'preceding' '::'
+ case 26325: // 'preceding-sibling' '::'
+ try_ReverseStep();
+ break;
+ default:
+ try_ForwardStep();
+ }
+ lookahead1W(237); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ try_PredicateList();
+ }
+
+ function parse_ForwardStep()
+ {
+ eventHandler.startNonterminal("ForwardStep", e0);
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ lookahead2W(244); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 93: // 'child'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 229: // 'self'
+ lookahead2W(241); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 26194: // 'attribute' '::'
+ case 26205: // 'child' '::'
+ case 26223: // 'descendant' '::'
+ case 26224: // 'descendant-or-self' '::'
+ case 26247: // 'following' '::'
+ case 26248: // 'following-sibling' '::'
+ case 26341: // 'self' '::'
+ parse_ForwardAxis();
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NodeTest();
+ break;
+ default:
+ parse_AbbrevForwardStep();
+ }
+ eventHandler.endNonterminal("ForwardStep", e0);
+ }
+
+ function try_ForwardStep()
+ {
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ lookahead2W(244); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 93: // 'child'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 229: // 'self'
+ lookahead2W(241); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 26194: // 'attribute' '::'
+ case 26205: // 'child' '::'
+ case 26223: // 'descendant' '::'
+ case 26224: // 'descendant-or-self' '::'
+ case 26247: // 'following' '::'
+ case 26248: // 'following-sibling' '::'
+ case 26341: // 'self' '::'
+ try_ForwardAxis();
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NodeTest();
+ break;
+ default:
+ try_AbbrevForwardStep();
+ }
+ }
+
+ function parse_ForwardAxis()
+ {
+ eventHandler.startNonterminal("ForwardAxis", e0);
+ switch (l1)
+ {
+ case 93: // 'child'
+ shift(93); // 'child'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 111: // 'descendant'
+ shift(111); // 'descendant'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 82: // 'attribute'
+ shift(82); // 'attribute'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 229: // 'self'
+ shift(229); // 'self'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 112: // 'descendant-or-self'
+ shift(112); // 'descendant-or-self'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 136: // 'following-sibling'
+ shift(136); // 'following-sibling'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ default:
+ shift(135); // 'following'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ }
+ eventHandler.endNonterminal("ForwardAxis", e0);
+ }
+
+ function try_ForwardAxis()
+ {
+ switch (l1)
+ {
+ case 93: // 'child'
+ shiftT(93); // 'child'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 111: // 'descendant'
+ shiftT(111); // 'descendant'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 82: // 'attribute'
+ shiftT(82); // 'attribute'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 229: // 'self'
+ shiftT(229); // 'self'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 112: // 'descendant-or-self'
+ shiftT(112); // 'descendant-or-self'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 136: // 'following-sibling'
+ shiftT(136); // 'following-sibling'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ default:
+ shiftT(135); // 'following'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ }
+ }
+
+ function parse_AbbrevForwardStep()
+ {
+ eventHandler.startNonterminal("AbbrevForwardStep", e0);
+ if (l1 == 66) // '@'
+ {
+ shift(66); // '@'
+ }
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NodeTest();
+ eventHandler.endNonterminal("AbbrevForwardStep", e0);
+ }
+
+ function try_AbbrevForwardStep()
+ {
+ if (l1 == 66) // '@'
+ {
+ shiftT(66); // '@'
+ }
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NodeTest();
+ }
+
+ function parse_ReverseStep()
+ {
+ eventHandler.startNonterminal("ReverseStep", e0);
+ switch (l1)
+ {
+ case 45: // '..'
+ parse_AbbrevReverseStep();
+ break;
+ default:
+ parse_ReverseAxis();
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_NodeTest();
+ }
+ eventHandler.endNonterminal("ReverseStep", e0);
+ }
+
+ function try_ReverseStep()
+ {
+ switch (l1)
+ {
+ case 45: // '..'
+ try_AbbrevReverseStep();
+ break;
+ default:
+ try_ReverseAxis();
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_NodeTest();
+ }
+ }
+
+ function parse_ReverseAxis()
+ {
+ eventHandler.startNonterminal("ReverseAxis", e0);
+ switch (l1)
+ {
+ case 206: // 'parent'
+ shift(206); // 'parent'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 73: // 'ancestor'
+ shift(73); // 'ancestor'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 213: // 'preceding-sibling'
+ shift(213); // 'preceding-sibling'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ case 212: // 'preceding'
+ shift(212); // 'preceding'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ break;
+ default:
+ shift(74); // 'ancestor-or-self'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shift(51); // '::'
+ }
+ eventHandler.endNonterminal("ReverseAxis", e0);
+ }
+
+ function try_ReverseAxis()
+ {
+ switch (l1)
+ {
+ case 206: // 'parent'
+ shiftT(206); // 'parent'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 73: // 'ancestor'
+ shiftT(73); // 'ancestor'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 213: // 'preceding-sibling'
+ shiftT(213); // 'preceding-sibling'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ case 212: // 'preceding'
+ shiftT(212); // 'preceding'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ break;
+ default:
+ shiftT(74); // 'ancestor-or-self'
+ lookahead1W(26); // S^WS | '(:' | '::'
+ shiftT(51); // '::'
+ }
+ }
+
+ function parse_AbbrevReverseStep()
+ {
+ eventHandler.startNonterminal("AbbrevReverseStep", e0);
+ shift(45); // '..'
+ eventHandler.endNonterminal("AbbrevReverseStep", e0);
+ }
+
+ function try_AbbrevReverseStep()
+ {
+ shiftT(45); // '..'
+ }
+
+ function parse_NodeTest()
+ {
+ eventHandler.startNonterminal("NodeTest", e0);
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ case 96: // 'comment'
+ case 120: // 'document-node'
+ case 121: // 'element'
+ case 185: // 'namespace-node'
+ case 191: // 'node'
+ case 216: // 'processing-instruction'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 244: // 'text'
+ lookahead2W(240); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 17490: // 'attribute' '('
+ case 17504: // 'comment' '('
+ case 17528: // 'document-node' '('
+ case 17529: // 'element' '('
+ case 17593: // 'namespace-node' '('
+ case 17599: // 'node' '('
+ case 17624: // 'processing-instruction' '('
+ case 17634: // 'schema-attribute' '('
+ case 17635: // 'schema-element' '('
+ case 17652: // 'text' '('
+ parse_KindTest();
+ break;
+ default:
+ parse_NameTest();
+ }
+ eventHandler.endNonterminal("NodeTest", e0);
+ }
+
+ function try_NodeTest()
+ {
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ case 96: // 'comment'
+ case 120: // 'document-node'
+ case 121: // 'element'
+ case 185: // 'namespace-node'
+ case 191: // 'node'
+ case 216: // 'processing-instruction'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 244: // 'text'
+ lookahead2W(240); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 17490: // 'attribute' '('
+ case 17504: // 'comment' '('
+ case 17528: // 'document-node' '('
+ case 17529: // 'element' '('
+ case 17593: // 'namespace-node' '('
+ case 17599: // 'node' '('
+ case 17624: // 'processing-instruction' '('
+ case 17634: // 'schema-attribute' '('
+ case 17635: // 'schema-element' '('
+ case 17652: // 'text' '('
+ try_KindTest();
+ break;
+ default:
+ try_NameTest();
+ }
+ }
+
+ function parse_NameTest()
+ {
+ eventHandler.startNonterminal("NameTest", e0);
+ switch (l1)
+ {
+ case 5: // Wildcard
+ shift(5); // Wildcard
+ break;
+ default:
+ parse_EQName();
+ }
+ eventHandler.endNonterminal("NameTest", e0);
+ }
+
+ function try_NameTest()
+ {
+ switch (l1)
+ {
+ case 5: // Wildcard
+ shiftT(5); // Wildcard
+ break;
+ default:
+ try_EQName();
+ }
+ }
+
+ function parse_PostfixExpr()
+ {
+ eventHandler.startNonterminal("PostfixExpr", e0);
+ parse_PrimaryExpr();
+ for (;;)
+ {
+ lookahead1W(240); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ if (l1 != 34 // '('
+ && l1 != 68) // '['
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 68: // '['
+ whitespace();
+ parse_Predicate();
+ break;
+ default:
+ whitespace();
+ parse_ArgumentList();
+ }
+ }
+ eventHandler.endNonterminal("PostfixExpr", e0);
+ }
+
+ function try_PostfixExpr()
+ {
+ try_PrimaryExpr();
+ for (;;)
+ {
+ lookahead1W(240); // S^WS | EOF | '!' | '!=' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' |
+ if (l1 != 34 // '('
+ && l1 != 68) // '['
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 68: // '['
+ try_Predicate();
+ break;
+ default:
+ try_ArgumentList();
+ }
+ }
+ }
+
+ function parse_ArgumentList()
+ {
+ eventHandler.startNonterminal("ArgumentList", e0);
+ shift(34); // '('
+ lookahead1W(275); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 37) // ')'
+ {
+ whitespace();
+ parse_Argument();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(270); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Argument();
+ }
+ }
+ shift(37); // ')'
+ eventHandler.endNonterminal("ArgumentList", e0);
+ }
+
+ function try_ArgumentList()
+ {
+ shiftT(34); // '('
+ lookahead1W(275); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 37) // ')'
+ {
+ try_Argument();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(270); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Argument();
+ }
+ }
+ shiftT(37); // ')'
+ }
+
+ function parse_PredicateList()
+ {
+ eventHandler.startNonterminal("PredicateList", e0);
+ for (;;)
+ {
+ lookahead1W(237); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ if (l1 != 68) // '['
+ {
+ break;
+ }
+ whitespace();
+ parse_Predicate();
+ }
+ eventHandler.endNonterminal("PredicateList", e0);
+ }
+
+ function try_PredicateList()
+ {
+ for (;;)
+ {
+ lookahead1W(237); // S^WS | EOF | '!' | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' | '//' | ':' |
+ if (l1 != 68) // '['
+ {
+ break;
+ }
+ try_Predicate();
+ }
+ }
+
+ function parse_Predicate()
+ {
+ eventHandler.startNonterminal("Predicate", e0);
+ shift(68); // '['
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(69); // ']'
+ eventHandler.endNonterminal("Predicate", e0);
+ }
+
+ function try_Predicate()
+ {
+ shiftT(68); // '['
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(69); // ']'
+ }
+
+ function parse_Literal()
+ {
+ eventHandler.startNonterminal("Literal", e0);
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ default:
+ parse_NumericLiteral();
+ }
+ eventHandler.endNonterminal("Literal", e0);
+ }
+
+ function try_Literal()
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ default:
+ try_NumericLiteral();
+ }
+ }
+
+ function parse_NumericLiteral()
+ {
+ eventHandler.startNonterminal("NumericLiteral", e0);
+ switch (l1)
+ {
+ case 8: // IntegerLiteral
+ shift(8); // IntegerLiteral
+ break;
+ case 9: // DecimalLiteral
+ shift(9); // DecimalLiteral
+ break;
+ default:
+ shift(10); // DoubleLiteral
+ }
+ eventHandler.endNonterminal("NumericLiteral", e0);
+ }
+
+ function try_NumericLiteral()
+ {
+ switch (l1)
+ {
+ case 8: // IntegerLiteral
+ shiftT(8); // IntegerLiteral
+ break;
+ case 9: // DecimalLiteral
+ shiftT(9); // DecimalLiteral
+ break;
+ default:
+ shiftT(10); // DoubleLiteral
+ }
+ }
+
+ function parse_VarRef()
+ {
+ eventHandler.startNonterminal("VarRef", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ eventHandler.endNonterminal("VarRef", e0);
+ }
+
+ function try_VarRef()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+
+ function parse_VarName()
+ {
+ eventHandler.startNonterminal("VarName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("VarName", e0);
+ }
+
+ function try_VarName()
+ {
+ try_EQName();
+ }
+
+ function parse_ParenthesizedExpr()
+ {
+ eventHandler.startNonterminal("ParenthesizedExpr", e0);
+ shift(34); // '('
+ lookahead1W(268); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 37) // ')'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(37); // ')'
+ eventHandler.endNonterminal("ParenthesizedExpr", e0);
+ }
+
+ function try_ParenthesizedExpr()
+ {
+ shiftT(34); // '('
+ lookahead1W(268); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 37) // ')'
+ {
+ try_Expr();
+ }
+ shiftT(37); // ')'
+ }
+
+ function parse_ContextItemExpr()
+ {
+ eventHandler.startNonterminal("ContextItemExpr", e0);
+ shift(44); // '.'
+ eventHandler.endNonterminal("ContextItemExpr", e0);
+ }
+
+ function try_ContextItemExpr()
+ {
+ shiftT(44); // '.'
+ }
+
+ function parse_OrderedExpr()
+ {
+ eventHandler.startNonterminal("OrderedExpr", e0);
+ shift(202); // 'ordered'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("OrderedExpr", e0);
+ }
+
+ function try_OrderedExpr()
+ {
+ shiftT(202); // 'ordered'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+
+ function parse_UnorderedExpr()
+ {
+ eventHandler.startNonterminal("UnorderedExpr", e0);
+ shift(256); // 'unordered'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("UnorderedExpr", e0);
+ }
+
+ function try_UnorderedExpr()
+ {
+ shiftT(256); // 'unordered'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+
+ function parse_FunctionCall()
+ {
+ eventHandler.startNonterminal("FunctionCall", e0);
+ parse_FunctionName();
+ lookahead1W(22); // S^WS | '(' | '(:'
+ whitespace();
+ parse_ArgumentList();
+ eventHandler.endNonterminal("FunctionCall", e0);
+ }
+
+ function try_FunctionCall()
+ {
+ try_FunctionName();
+ lookahead1W(22); // S^WS | '(' | '(:'
+ try_ArgumentList();
+ }
+
+ function parse_Argument()
+ {
+ eventHandler.startNonterminal("Argument", e0);
+ switch (l1)
+ {
+ case 64: // '?'
+ parse_ArgumentPlaceholder();
+ break;
+ default:
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("Argument", e0);
+ }
+
+ function try_Argument()
+ {
+ switch (l1)
+ {
+ case 64: // '?'
+ try_ArgumentPlaceholder();
+ break;
+ default:
+ try_ExprSingle();
+ }
+ }
+
+ function parse_ArgumentPlaceholder()
+ {
+ eventHandler.startNonterminal("ArgumentPlaceholder", e0);
+ shift(64); // '?'
+ eventHandler.endNonterminal("ArgumentPlaceholder", e0);
+ }
+
+ function try_ArgumentPlaceholder()
+ {
+ shiftT(64); // '?'
+ }
+
+ function parse_Constructor()
+ {
+ eventHandler.startNonterminal("Constructor", e0);
+ switch (l1)
+ {
+ case 54: // '<'
+ case 55: // '<!--'
+ case 59: // '<?'
+ parse_DirectConstructor();
+ break;
+ default:
+ parse_ComputedConstructor();
+ }
+ eventHandler.endNonterminal("Constructor", e0);
+ }
+
+ function try_Constructor()
+ {
+ switch (l1)
+ {
+ case 54: // '<'
+ case 55: // '<!--'
+ case 59: // '<?'
+ try_DirectConstructor();
+ break;
+ default:
+ try_ComputedConstructor();
+ }
+ }
+
+ function parse_DirectConstructor()
+ {
+ eventHandler.startNonterminal("DirectConstructor", e0);
+ switch (l1)
+ {
+ case 54: // '<'
+ parse_DirElemConstructor();
+ break;
+ case 55: // '<!--'
+ parse_DirCommentConstructor();
+ break;
+ default:
+ parse_DirPIConstructor();
+ }
+ eventHandler.endNonterminal("DirectConstructor", e0);
+ }
+
+ function try_DirectConstructor()
+ {
+ switch (l1)
+ {
+ case 54: // '<'
+ try_DirElemConstructor();
+ break;
+ case 55: // '<!--'
+ try_DirCommentConstructor();
+ break;
+ default:
+ try_DirPIConstructor();
+ }
+ }
+
+ function parse_DirElemConstructor()
+ {
+ eventHandler.startNonterminal("DirElemConstructor", e0);
+ shift(54); // '<'
+ lookahead1(4); // QName
+ shift(20); // QName
+ parse_DirAttributeList();
+ switch (l1)
+ {
+ case 48: // '/>'
+ shift(48); // '/>'
+ break;
+ default:
+ shift(61); // '>'
+ for (;;)
+ {
+ lookahead1(174); // CDataSection | PredefinedEntityRef | ElementContentChar | CharRef | '<' |
+ if (l1 == 56) // '</'
+ {
+ break;
+ }
+ parse_DirElemContent();
+ }
+ shift(56); // '</'
+ lookahead1(4); // QName
+ shift(20); // QName
+ lookahead1(12); // S | '>'
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ lookahead1(8); // '>'
+ shift(61); // '>'
+ }
+ eventHandler.endNonterminal("DirElemConstructor", e0);
+ }
+
+ function try_DirElemConstructor()
+ {
+ shiftT(54); // '<'
+ lookahead1(4); // QName
+ shiftT(20); // QName
+ try_DirAttributeList();
+ switch (l1)
+ {
+ case 48: // '/>'
+ shiftT(48); // '/>'
+ break;
+ default:
+ shiftT(61); // '>'
+ for (;;)
+ {
+ lookahead1(174); // CDataSection | PredefinedEntityRef | ElementContentChar | CharRef | '<' |
+ if (l1 == 56) // '</'
+ {
+ break;
+ }
+ try_DirElemContent();
+ }
+ shiftT(56); // '</'
+ lookahead1(4); // QName
+ shiftT(20); // QName
+ lookahead1(12); // S | '>'
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ lookahead1(8); // '>'
+ shiftT(61); // '>'
+ }
+ }
+
+ function parse_DirAttributeList()
+ {
+ eventHandler.startNonterminal("DirAttributeList", e0);
+ for (;;)
+ {
+ lookahead1(19); // S | '/>' | '>'
+ if (l1 != 21) // S
+ {
+ break;
+ }
+ shift(21); // S
+ lookahead1(91); // QName | S | '/>' | '>'
+ if (l1 == 20) // QName
+ {
+ shift(20); // QName
+ lookahead1(11); // S | '='
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ lookahead1(7); // '='
+ shift(60); // '='
+ lookahead1(18); // S | '"' | "'"
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ }
+ parse_DirAttributeValue();
+ }
+ }
+ eventHandler.endNonterminal("DirAttributeList", e0);
+ }
+
+ function try_DirAttributeList()
+ {
+ for (;;)
+ {
+ lookahead1(19); // S | '/>' | '>'
+ if (l1 != 21) // S
+ {
+ break;
+ }
+ shiftT(21); // S
+ lookahead1(91); // QName | S | '/>' | '>'
+ if (l1 == 20) // QName
+ {
+ shiftT(20); // QName
+ lookahead1(11); // S | '='
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ lookahead1(7); // '='
+ shiftT(60); // '='
+ lookahead1(18); // S | '"' | "'"
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ }
+ try_DirAttributeValue();
+ }
+ }
+ }
+
+ function parse_DirAttributeValue()
+ {
+ eventHandler.startNonterminal("DirAttributeValue", e0);
+ lookahead1(14); // '"' | "'"
+ switch (l1)
+ {
+ case 28: // '"'
+ shift(28); // '"'
+ for (;;)
+ {
+ lookahead1(167); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | '"' | '{' |
+ if (l1 == 28) // '"'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 13: // EscapeQuot
+ shift(13); // EscapeQuot
+ break;
+ default:
+ parse_QuotAttrValueContent();
+ }
+ }
+ shift(28); // '"'
+ break;
+ default:
+ shift(33); // "'"
+ for (;;)
+ {
+ lookahead1(168); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | "'" | '{' |
+ if (l1 == 33) // "'"
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 14: // EscapeApos
+ shift(14); // EscapeApos
+ break;
+ default:
+ parse_AposAttrValueContent();
+ }
+ }
+ shift(33); // "'"
+ }
+ eventHandler.endNonterminal("DirAttributeValue", e0);
+ }
+
+ function try_DirAttributeValue()
+ {
+ lookahead1(14); // '"' | "'"
+ switch (l1)
+ {
+ case 28: // '"'
+ shiftT(28); // '"'
+ for (;;)
+ {
+ lookahead1(167); // PredefinedEntityRef | EscapeQuot | QuotAttrContentChar | CharRef | '"' | '{' |
+ if (l1 == 28) // '"'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 13: // EscapeQuot
+ shiftT(13); // EscapeQuot
+ break;
+ default:
+ try_QuotAttrValueContent();
+ }
+ }
+ shiftT(28); // '"'
+ break;
+ default:
+ shiftT(33); // "'"
+ for (;;)
+ {
+ lookahead1(168); // PredefinedEntityRef | EscapeApos | AposAttrContentChar | CharRef | "'" | '{' |
+ if (l1 == 33) // "'"
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 14: // EscapeApos
+ shiftT(14); // EscapeApos
+ break;
+ default:
+ try_AposAttrValueContent();
+ }
+ }
+ shiftT(33); // "'"
+ }
+ }
+
+ function parse_QuotAttrValueContent()
+ {
+ eventHandler.startNonterminal("QuotAttrValueContent", e0);
+ switch (l1)
+ {
+ case 16: // QuotAttrContentChar
+ shift(16); // QuotAttrContentChar
+ break;
+ default:
+ parse_CommonContent();
+ }
+ eventHandler.endNonterminal("QuotAttrValueContent", e0);
+ }
+
+ function try_QuotAttrValueContent()
+ {
+ switch (l1)
+ {
+ case 16: // QuotAttrContentChar
+ shiftT(16); // QuotAttrContentChar
+ break;
+ default:
+ try_CommonContent();
+ }
+ }
+
+ function parse_AposAttrValueContent()
+ {
+ eventHandler.startNonterminal("AposAttrValueContent", e0);
+ switch (l1)
+ {
+ case 17: // AposAttrContentChar
+ shift(17); // AposAttrContentChar
+ break;
+ default:
+ parse_CommonContent();
+ }
+ eventHandler.endNonterminal("AposAttrValueContent", e0);
+ }
+
+ function try_AposAttrValueContent()
+ {
+ switch (l1)
+ {
+ case 17: // AposAttrContentChar
+ shiftT(17); // AposAttrContentChar
+ break;
+ default:
+ try_CommonContent();
+ }
+ }
+
+ function parse_DirElemContent()
+ {
+ eventHandler.startNonterminal("DirElemContent", e0);
+ switch (l1)
+ {
+ case 54: // '<'
+ case 55: // '<!--'
+ case 59: // '<?'
+ parse_DirectConstructor();
+ break;
+ case 4: // CDataSection
+ shift(4); // CDataSection
+ break;
+ case 15: // ElementContentChar
+ shift(15); // ElementContentChar
+ break;
+ default:
+ parse_CommonContent();
+ }
+ eventHandler.endNonterminal("DirElemContent", e0);
+ }
+
+ function try_DirElemContent()
+ {
+ switch (l1)
+ {
+ case 54: // '<'
+ case 55: // '<!--'
+ case 59: // '<?'
+ try_DirectConstructor();
+ break;
+ case 4: // CDataSection
+ shiftT(4); // CDataSection
+ break;
+ case 15: // ElementContentChar
+ shiftT(15); // ElementContentChar
+ break;
+ default:
+ try_CommonContent();
+ }
+ }
+
+ function parse_DirCommentConstructor()
+ {
+ eventHandler.startNonterminal("DirCommentConstructor", e0);
+ shift(55); // '<!--'
+ lookahead1(1); // DirCommentContents
+ shift(2); // DirCommentContents
+ lookahead1(6); // '-->'
+ shift(43); // '-->'
+ eventHandler.endNonterminal("DirCommentConstructor", e0);
+ }
+
+ function try_DirCommentConstructor()
+ {
+ shiftT(55); // '<!--'
+ lookahead1(1); // DirCommentContents
+ shiftT(2); // DirCommentContents
+ lookahead1(6); // '-->'
+ shiftT(43); // '-->'
+ }
+
+ function parse_DirPIConstructor()
+ {
+ eventHandler.startNonterminal("DirPIConstructor", e0);
+ shift(59); // '<?'
+ lookahead1(3); // PITarget
+ shift(18); // PITarget
+ lookahead1(13); // S | '?>'
+ if (l1 == 21) // S
+ {
+ shift(21); // S
+ lookahead1(2); // DirPIContents
+ shift(3); // DirPIContents
+ }
+ lookahead1(9); // '?>'
+ shift(65); // '?>'
+ eventHandler.endNonterminal("DirPIConstructor", e0);
+ }
+
+ function try_DirPIConstructor()
+ {
+ shiftT(59); // '<?'
+ lookahead1(3); // PITarget
+ shiftT(18); // PITarget
+ lookahead1(13); // S | '?>'
+ if (l1 == 21) // S
+ {
+ shiftT(21); // S
+ lookahead1(2); // DirPIContents
+ shiftT(3); // DirPIContents
+ }
+ lookahead1(9); // '?>'
+ shiftT(65); // '?>'
+ }
+
+ function parse_ComputedConstructor()
+ {
+ eventHandler.startNonterminal("ComputedConstructor", e0);
+ switch (l1)
+ {
+ case 119: // 'document'
+ parse_CompDocConstructor();
+ break;
+ case 121: // 'element'
+ parse_CompElemConstructor();
+ break;
+ case 82: // 'attribute'
+ parse_CompAttrConstructor();
+ break;
+ case 184: // 'namespace'
+ parse_CompNamespaceConstructor();
+ break;
+ case 244: // 'text'
+ parse_CompTextConstructor();
+ break;
+ case 96: // 'comment'
+ parse_CompCommentConstructor();
+ break;
+ default:
+ parse_CompPIConstructor();
+ }
+ eventHandler.endNonterminal("ComputedConstructor", e0);
+ }
+
+ function try_ComputedConstructor()
+ {
+ switch (l1)
+ {
+ case 119: // 'document'
+ try_CompDocConstructor();
+ break;
+ case 121: // 'element'
+ try_CompElemConstructor();
+ break;
+ case 82: // 'attribute'
+ try_CompAttrConstructor();
+ break;
+ case 184: // 'namespace'
+ try_CompNamespaceConstructor();
+ break;
+ case 244: // 'text'
+ try_CompTextConstructor();
+ break;
+ case 96: // 'comment'
+ try_CompCommentConstructor();
+ break;
+ default:
+ try_CompPIConstructor();
+ }
+ }
+
+ function parse_CompElemConstructor()
+ {
+ eventHandler.startNonterminal("CompElemConstructor", e0);
+ shift(121); // 'element'
+ lookahead1W(257); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ break;
+ default:
+ whitespace();
+ parse_EQName();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 282) // '}'
+ {
+ whitespace();
+ parse_ContentExpr();
+ }
+ shift(282); // '}'
+ eventHandler.endNonterminal("CompElemConstructor", e0);
+ }
+
+ function try_CompElemConstructor()
+ {
+ shiftT(121); // 'element'
+ lookahead1W(257); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ break;
+ default:
+ try_EQName();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 282) // '}'
+ {
+ try_ContentExpr();
+ }
+ shiftT(282); // '}'
+ }
+
+ function parse_CompNamespaceConstructor()
+ {
+ eventHandler.startNonterminal("CompNamespaceConstructor", e0);
+ shift(184); // 'namespace'
+ lookahead1W(250); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_PrefixExpr();
+ shift(282); // '}'
+ break;
+ default:
+ whitespace();
+ parse_Prefix();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_URIExpr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("CompNamespaceConstructor", e0);
+ }
+
+ function try_CompNamespaceConstructor()
+ {
+ shiftT(184); // 'namespace'
+ lookahead1W(250); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_PrefixExpr();
+ shiftT(282); // '}'
+ break;
+ default:
+ try_Prefix();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_URIExpr();
+ shiftT(282); // '}'
+ }
+
+ function parse_Prefix()
+ {
+ eventHandler.startNonterminal("Prefix", e0);
+ parse_NCName();
+ eventHandler.endNonterminal("Prefix", e0);
+ }
+
+ function try_Prefix()
+ {
+ try_NCName();
+ }
+
+ function parse_PrefixExpr()
+ {
+ eventHandler.startNonterminal("PrefixExpr", e0);
+ parse_Expr();
+ eventHandler.endNonterminal("PrefixExpr", e0);
+ }
+
+ function try_PrefixExpr()
+ {
+ try_Expr();
+ }
+
+ function parse_URIExpr()
+ {
+ eventHandler.startNonterminal("URIExpr", e0);
+ parse_Expr();
+ eventHandler.endNonterminal("URIExpr", e0);
+ }
+
+ function try_URIExpr()
+ {
+ try_Expr();
+ }
+
+ function parse_FunctionItemExpr()
+ {
+ eventHandler.startNonterminal("FunctionItemExpr", e0);
+ switch (l1)
+ {
+ case 145: // 'function'
+ lookahead2W(92); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 32: // '%'
+ case 17553: // 'function' '('
+ parse_InlineFunctionExpr();
+ break;
+ default:
+ parse_NamedFunctionRef();
+ }
+ eventHandler.endNonterminal("FunctionItemExpr", e0);
+ }
+
+ function try_FunctionItemExpr()
+ {
+ switch (l1)
+ {
+ case 145: // 'function'
+ lookahead2W(92); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 32: // '%'
+ case 17553: // 'function' '('
+ try_InlineFunctionExpr();
+ break;
+ default:
+ try_NamedFunctionRef();
+ }
+ }
+
+ function parse_NamedFunctionRef()
+ {
+ eventHandler.startNonterminal("NamedFunctionRef", e0);
+ parse_EQName();
+ lookahead1W(20); // S^WS | '#' | '(:'
+ shift(29); // '#'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ eventHandler.endNonterminal("NamedFunctionRef", e0);
+ }
+
+ function try_NamedFunctionRef()
+ {
+ try_EQName();
+ lookahead1W(20); // S^WS | '#' | '(:'
+ shiftT(29); // '#'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ }
+
+ function parse_InlineFunctionExpr()
+ {
+ eventHandler.startNonterminal("InlineFunctionExpr", e0);
+ for (;;)
+ {
+ lookahead1W(97); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 32) // '%'
+ {
+ break;
+ }
+ whitespace();
+ parse_Annotation();
+ }
+ shift(145); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(94); // S^WS | '$' | '(:' | ')'
+ if (l1 == 31) // '$'
+ {
+ whitespace();
+ parse_ParamList();
+ }
+ shift(37); // ')'
+ lookahead1W(111); // S^WS | '(:' | 'as' | '{'
+ if (l1 == 79) // 'as'
+ {
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ whitespace();
+ parse_FunctionBody();
+ eventHandler.endNonterminal("InlineFunctionExpr", e0);
+ }
+
+ function try_InlineFunctionExpr()
+ {
+ for (;;)
+ {
+ lookahead1W(97); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 32) // '%'
+ {
+ break;
+ }
+ try_Annotation();
+ }
+ shiftT(145); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(94); // S^WS | '$' | '(:' | ')'
+ if (l1 == 31) // '$'
+ {
+ try_ParamList();
+ }
+ shiftT(37); // ')'
+ lookahead1W(111); // S^WS | '(:' | 'as' | '{'
+ if (l1 == 79) // 'as'
+ {
+ shiftT(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ try_FunctionBody();
+ }
+
+ function parse_SingleType()
+ {
+ eventHandler.startNonterminal("SingleType", e0);
+ parse_SimpleTypeName();
+ lookahead1W(226); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 64) // '?'
+ {
+ shift(64); // '?'
+ }
+ eventHandler.endNonterminal("SingleType", e0);
+ }
+
+ function try_SingleType()
+ {
+ try_SimpleTypeName();
+ lookahead1W(226); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '+' | ',' | '-' | ':' | ';' | '<' | '<<' |
+ if (l1 == 64) // '?'
+ {
+ shiftT(64); // '?'
+ }
+ }
+
+ function parse_TypeDeclaration()
+ {
+ eventHandler.startNonterminal("TypeDeclaration", e0);
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ eventHandler.endNonterminal("TypeDeclaration", e0);
+ }
+
+ function try_TypeDeclaration()
+ {
+ shiftT(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+
+ function parse_SequenceType()
+ {
+ eventHandler.startNonterminal("SequenceType", e0);
+ switch (l1)
+ {
+ case 124: // 'empty-sequence'
+ lookahead2W(242); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 17532: // 'empty-sequence' '('
+ shift(124); // 'empty-sequence'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ break;
+ default:
+ parse_ItemType();
+ lookahead1W(238); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' | ';' |
+ switch (l1)
+ {
+ case 39: // '*'
+ case 40: // '+'
+ case 64: // '?'
+ whitespace();
+ parse_OccurrenceIndicator();
+ break;
+ default:
+ break;
+ }
+ }
+ eventHandler.endNonterminal("SequenceType", e0);
+ }
+
+ function try_SequenceType()
+ {
+ switch (l1)
+ {
+ case 124: // 'empty-sequence'
+ lookahead2W(242); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 17532: // 'empty-sequence' '('
+ shiftT(124); // 'empty-sequence'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ break;
+ default:
+ try_ItemType();
+ lookahead1W(238); // S^WS | EOF | '!=' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' | ';' |
+ switch (l1)
+ {
+ case 39: // '*'
+ case 40: // '+'
+ case 64: // '?'
+ try_OccurrenceIndicator();
+ break;
+ default:
+ break;
+ }
+ }
+ }
+
+ function parse_OccurrenceIndicator()
+ {
+ eventHandler.startNonterminal("OccurrenceIndicator", e0);
+ switch (l1)
+ {
+ case 64: // '?'
+ shift(64); // '?'
+ break;
+ case 39: // '*'
+ shift(39); // '*'
+ break;
+ default:
+ shift(40); // '+'
+ }
+ eventHandler.endNonterminal("OccurrenceIndicator", e0);
+ }
+
+ function try_OccurrenceIndicator()
+ {
+ switch (l1)
+ {
+ case 64: // '?'
+ shiftT(64); // '?'
+ break;
+ case 39: // '*'
+ shiftT(39); // '*'
+ break;
+ default:
+ shiftT(40); // '+'
+ }
+ }
+
+ function parse_ItemType()
+ {
+ eventHandler.startNonterminal("ItemType", e0);
+ switch (l1)
+ {
+ case 78: // 'array'
+ case 82: // 'attribute'
+ case 96: // 'comment'
+ case 120: // 'document-node'
+ case 121: // 'element'
+ case 145: // 'function'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 185: // 'namespace-node'
+ case 191: // 'node'
+ case 194: // 'object'
+ case 216: // 'processing-instruction'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 242: // 'structured-item'
+ case 244: // 'text'
+ lookahead2W(242); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 17490: // 'attribute' '('
+ case 17504: // 'comment' '('
+ case 17528: // 'document-node' '('
+ case 17529: // 'element' '('
+ case 17593: // 'namespace-node' '('
+ case 17599: // 'node' '('
+ case 17624: // 'processing-instruction' '('
+ case 17634: // 'schema-attribute' '('
+ case 17635: // 'schema-element' '('
+ case 17652: // 'text' '('
+ parse_KindTest();
+ break;
+ case 17573: // 'item' '('
+ shift(165); // 'item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ break;
+ case 32: // '%'
+ case 17553: // 'function' '('
+ parse_FunctionTest();
+ break;
+ case 34: // '('
+ parse_ParenthesizedItemType();
+ break;
+ case 17486: // 'array' '('
+ case 17575: // 'json-item' '('
+ case 17602: // 'object' '('
+ parse_JSONTest();
+ break;
+ case 17650: // 'structured-item' '('
+ parse_StructuredItemTest();
+ break;
+ default:
+ parse_AtomicOrUnionType();
+ }
+ eventHandler.endNonterminal("ItemType", e0);
+ }
+
+ function try_ItemType()
+ {
+ switch (l1)
+ {
+ case 78: // 'array'
+ case 82: // 'attribute'
+ case 96: // 'comment'
+ case 120: // 'document-node'
+ case 121: // 'element'
+ case 145: // 'function'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 185: // 'namespace-node'
+ case 191: // 'node'
+ case 194: // 'object'
+ case 216: // 'processing-instruction'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 242: // 'structured-item'
+ case 244: // 'text'
+ lookahead2W(242); // S^WS | EOF | '!=' | '(' | '(:' | ')' | '*' | '*' | '+' | ',' | '-' | ':' | ':=' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 17490: // 'attribute' '('
+ case 17504: // 'comment' '('
+ case 17528: // 'document-node' '('
+ case 17529: // 'element' '('
+ case 17593: // 'namespace-node' '('
+ case 17599: // 'node' '('
+ case 17624: // 'processing-instruction' '('
+ case 17634: // 'schema-attribute' '('
+ case 17635: // 'schema-element' '('
+ case 17652: // 'text' '('
+ try_KindTest();
+ break;
+ case 17573: // 'item' '('
+ shiftT(165); // 'item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ break;
+ case 32: // '%'
+ case 17553: // 'function' '('
+ try_FunctionTest();
+ break;
+ case 34: // '('
+ try_ParenthesizedItemType();
+ break;
+ case 17486: // 'array' '('
+ case 17575: // 'json-item' '('
+ case 17602: // 'object' '('
+ try_JSONTest();
+ break;
+ case 17650: // 'structured-item' '('
+ try_StructuredItemTest();
+ break;
+ default:
+ try_AtomicOrUnionType();
+ }
+ }
+
+ function parse_JSONTest()
+ {
+ eventHandler.startNonterminal("JSONTest", e0);
+ switch (l1)
+ {
+ case 167: // 'json-item'
+ parse_JSONItemTest();
+ break;
+ case 194: // 'object'
+ parse_JSONObjectTest();
+ break;
+ default:
+ parse_JSONArrayTest();
+ }
+ eventHandler.endNonterminal("JSONTest", e0);
+ }
+
+ function try_JSONTest()
+ {
+ switch (l1)
+ {
+ case 167: // 'json-item'
+ try_JSONItemTest();
+ break;
+ case 194: // 'object'
+ try_JSONObjectTest();
+ break;
+ default:
+ try_JSONArrayTest();
+ }
+ }
+
+ function parse_StructuredItemTest()
+ {
+ eventHandler.startNonterminal("StructuredItemTest", e0);
+ shift(242); // 'structured-item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("StructuredItemTest", e0);
+ }
+
+ function try_StructuredItemTest()
+ {
+ shiftT(242); // 'structured-item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_JSONItemTest()
+ {
+ eventHandler.startNonterminal("JSONItemTest", e0);
+ shift(167); // 'json-item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("JSONItemTest", e0);
+ }
+
+ function try_JSONItemTest()
+ {
+ shiftT(167); // 'json-item'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_JSONObjectTest()
+ {
+ eventHandler.startNonterminal("JSONObjectTest", e0);
+ shift(194); // 'object'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("JSONObjectTest", e0);
+ }
+
+ function try_JSONObjectTest()
+ {
+ shiftT(194); // 'object'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_JSONArrayTest()
+ {
+ eventHandler.startNonterminal("JSONArrayTest", e0);
+ shift(78); // 'array'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("JSONArrayTest", e0);
+ }
+
+ function try_JSONArrayTest()
+ {
+ shiftT(78); // 'array'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_AtomicOrUnionType()
+ {
+ eventHandler.startNonterminal("AtomicOrUnionType", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("AtomicOrUnionType", e0);
+ }
+
+ function try_AtomicOrUnionType()
+ {
+ try_EQName();
+ }
+
+ function parse_KindTest()
+ {
+ eventHandler.startNonterminal("KindTest", e0);
+ switch (l1)
+ {
+ case 120: // 'document-node'
+ parse_DocumentTest();
+ break;
+ case 121: // 'element'
+ parse_ElementTest();
+ break;
+ case 82: // 'attribute'
+ parse_AttributeTest();
+ break;
+ case 227: // 'schema-element'
+ parse_SchemaElementTest();
+ break;
+ case 226: // 'schema-attribute'
+ parse_SchemaAttributeTest();
+ break;
+ case 216: // 'processing-instruction'
+ parse_PITest();
+ break;
+ case 96: // 'comment'
+ parse_CommentTest();
+ break;
+ case 244: // 'text'
+ parse_TextTest();
+ break;
+ case 185: // 'namespace-node'
+ parse_NamespaceNodeTest();
+ break;
+ default:
+ parse_AnyKindTest();
+ }
+ eventHandler.endNonterminal("KindTest", e0);
+ }
+
+ function try_KindTest()
+ {
+ switch (l1)
+ {
+ case 120: // 'document-node'
+ try_DocumentTest();
+ break;
+ case 121: // 'element'
+ try_ElementTest();
+ break;
+ case 82: // 'attribute'
+ try_AttributeTest();
+ break;
+ case 227: // 'schema-element'
+ try_SchemaElementTest();
+ break;
+ case 226: // 'schema-attribute'
+ try_SchemaAttributeTest();
+ break;
+ case 216: // 'processing-instruction'
+ try_PITest();
+ break;
+ case 96: // 'comment'
+ try_CommentTest();
+ break;
+ case 244: // 'text'
+ try_TextTest();
+ break;
+ case 185: // 'namespace-node'
+ try_NamespaceNodeTest();
+ break;
+ default:
+ try_AnyKindTest();
+ }
+ }
+
+ function parse_AnyKindTest()
+ {
+ eventHandler.startNonterminal("AnyKindTest", e0);
+ shift(191); // 'node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("AnyKindTest", e0);
+ }
+
+ function try_AnyKindTest()
+ {
+ shiftT(191); // 'node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_DocumentTest()
+ {
+ eventHandler.startNonterminal("DocumentTest", e0);
+ shift(120); // 'document-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(144); // S^WS | '(:' | ')' | 'element' | 'schema-element'
+ if (l1 != 37) // ')'
+ {
+ switch (l1)
+ {
+ case 121: // 'element'
+ whitespace();
+ parse_ElementTest();
+ break;
+ default:
+ whitespace();
+ parse_SchemaElementTest();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("DocumentTest", e0);
+ }
+
+ function try_DocumentTest()
+ {
+ shiftT(120); // 'document-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(144); // S^WS | '(:' | ')' | 'element' | 'schema-element'
+ if (l1 != 37) // ')'
+ {
+ switch (l1)
+ {
+ case 121: // 'element'
+ try_ElementTest();
+ break;
+ default:
+ try_SchemaElementTest();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_TextTest()
+ {
+ eventHandler.startNonterminal("TextTest", e0);
+ shift(244); // 'text'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("TextTest", e0);
+ }
+
+ function try_TextTest()
+ {
+ shiftT(244); // 'text'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_CommentTest()
+ {
+ eventHandler.startNonterminal("CommentTest", e0);
+ shift(96); // 'comment'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("CommentTest", e0);
+ }
+
+ function try_CommentTest()
+ {
+ shiftT(96); // 'comment'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_NamespaceNodeTest()
+ {
+ eventHandler.startNonterminal("NamespaceNodeTest", e0);
+ shift(185); // 'namespace-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("NamespaceNodeTest", e0);
+ }
+
+ function try_NamespaceNodeTest()
+ {
+ shiftT(185); // 'namespace-node'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_PITest()
+ {
+ eventHandler.startNonterminal("PITest", e0);
+ shift(216); // 'processing-instruction'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(252); // StringLiteral | NCName^Token | S^WS | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 37) // ')'
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ default:
+ whitespace();
+ parse_NCName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("PITest", e0);
+ }
+
+ function try_PITest()
+ {
+ shiftT(216); // 'processing-instruction'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(252); // StringLiteral | NCName^Token | S^WS | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 37) // ')'
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ default:
+ try_NCName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_AttributeTest()
+ {
+ eventHandler.startNonterminal("AttributeTest", e0);
+ shift(82); // 'attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(260); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 37) // ')'
+ {
+ whitespace();
+ parse_AttribNameOrWildcard();
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 == 41) // ','
+ {
+ shift(41); // ','
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_TypeName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("AttributeTest", e0);
+ }
+
+ function try_AttributeTest()
+ {
+ shiftT(82); // 'attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(260); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 37) // ')'
+ {
+ try_AttribNameOrWildcard();
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 == 41) // ','
+ {
+ shiftT(41); // ','
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_TypeName();
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_AttribNameOrWildcard()
+ {
+ eventHandler.startNonterminal("AttribNameOrWildcard", e0);
+ switch (l1)
+ {
+ case 38: // '*'
+ shift(38); // '*'
+ break;
+ default:
+ parse_AttributeName();
+ }
+ eventHandler.endNonterminal("AttribNameOrWildcard", e0);
+ }
+
+ function try_AttribNameOrWildcard()
+ {
+ switch (l1)
+ {
+ case 38: // '*'
+ shiftT(38); // '*'
+ break;
+ default:
+ try_AttributeName();
+ }
+ }
+
+ function parse_SchemaAttributeTest()
+ {
+ eventHandler.startNonterminal("SchemaAttributeTest", e0);
+ shift(226); // 'schema-attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_AttributeDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("SchemaAttributeTest", e0);
+ }
+
+ function try_SchemaAttributeTest()
+ {
+ shiftT(226); // 'schema-attribute'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_AttributeDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_AttributeDeclaration()
+ {
+ eventHandler.startNonterminal("AttributeDeclaration", e0);
+ parse_AttributeName();
+ eventHandler.endNonterminal("AttributeDeclaration", e0);
+ }
+
+ function try_AttributeDeclaration()
+ {
+ try_AttributeName();
+ }
+
+ function parse_ElementTest()
+ {
+ eventHandler.startNonterminal("ElementTest", e0);
+ shift(121); // 'element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(260); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 37) // ')'
+ {
+ whitespace();
+ parse_ElementNameOrWildcard();
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 == 41) // ','
+ {
+ shift(41); // ','
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_TypeName();
+ lookahead1W(102); // S^WS | '(:' | ')' | '?'
+ if (l1 == 64) // '?'
+ {
+ shift(64); // '?'
+ }
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("ElementTest", e0);
+ }
+
+ function try_ElementTest()
+ {
+ shiftT(121); // 'element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(260); // EQName^Token | S^WS | '(:' | ')' | '*' | 'after' | 'allowing' | 'ancestor' |
+ if (l1 != 37) // ')'
+ {
+ try_ElementNameOrWildcard();
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 == 41) // ','
+ {
+ shiftT(41); // ','
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_TypeName();
+ lookahead1W(102); // S^WS | '(:' | ')' | '?'
+ if (l1 == 64) // '?'
+ {
+ shiftT(64); // '?'
+ }
+ }
+ }
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_ElementNameOrWildcard()
+ {
+ eventHandler.startNonterminal("ElementNameOrWildcard", e0);
+ switch (l1)
+ {
+ case 38: // '*'
+ shift(38); // '*'
+ break;
+ default:
+ parse_ElementName();
+ }
+ eventHandler.endNonterminal("ElementNameOrWildcard", e0);
+ }
+
+ function try_ElementNameOrWildcard()
+ {
+ switch (l1)
+ {
+ case 38: // '*'
+ shiftT(38); // '*'
+ break;
+ default:
+ try_ElementName();
+ }
+ }
+
+ function parse_SchemaElementTest()
+ {
+ eventHandler.startNonterminal("SchemaElementTest", e0);
+ shift(227); // 'schema-element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ElementDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("SchemaElementTest", e0);
+ }
+
+ function try_SchemaElementTest()
+ {
+ shiftT(227); // 'schema-element'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_ElementDeclaration();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_ElementDeclaration()
+ {
+ eventHandler.startNonterminal("ElementDeclaration", e0);
+ parse_ElementName();
+ eventHandler.endNonterminal("ElementDeclaration", e0);
+ }
+
+ function try_ElementDeclaration()
+ {
+ try_ElementName();
+ }
+
+ function parse_AttributeName()
+ {
+ eventHandler.startNonterminal("AttributeName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("AttributeName", e0);
+ }
+
+ function try_AttributeName()
+ {
+ try_EQName();
+ }
+
+ function parse_ElementName()
+ {
+ eventHandler.startNonterminal("ElementName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("ElementName", e0);
+ }
+
+ function try_ElementName()
+ {
+ try_EQName();
+ }
+
+ function parse_SimpleTypeName()
+ {
+ eventHandler.startNonterminal("SimpleTypeName", e0);
+ parse_TypeName();
+ eventHandler.endNonterminal("SimpleTypeName", e0);
+ }
+
+ function try_SimpleTypeName()
+ {
+ try_TypeName();
+ }
+
+ function parse_TypeName()
+ {
+ eventHandler.startNonterminal("TypeName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("TypeName", e0);
+ }
+
+ function try_TypeName()
+ {
+ try_EQName();
+ }
+
+ function parse_FunctionTest()
+ {
+ eventHandler.startNonterminal("FunctionTest", e0);
+ for (;;)
+ {
+ lookahead1W(97); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 32) // '%'
+ {
+ break;
+ }
+ whitespace();
+ parse_Annotation();
+ }
+ switch (l1)
+ {
+ case 145: // 'function'
+ lookahead2W(22); // S^WS | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ lk = memoized(5, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_AnyFunctionTest();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(5, e0, lk);
+ }
+ switch (lk)
+ {
+ case -1:
+ whitespace();
+ parse_AnyFunctionTest();
+ break;
+ default:
+ whitespace();
+ parse_TypedFunctionTest();
+ }
+ eventHandler.endNonterminal("FunctionTest", e0);
+ }
+
+ function try_FunctionTest()
+ {
+ for (;;)
+ {
+ lookahead1W(97); // S^WS | '%' | '(:' | 'function'
+ if (l1 != 32) // '%'
+ {
+ break;
+ }
+ try_Annotation();
+ }
+ switch (l1)
+ {
+ case 145: // 'function'
+ lookahead2W(22); // S^WS | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ lk = memoized(5, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_AnyFunctionTest();
+ memoize(5, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(5, e0A, -2);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ try_AnyFunctionTest();
+ break;
+ case -3:
+ break;
+ default:
+ try_TypedFunctionTest();
+ }
+ }
+
+ function parse_AnyFunctionTest()
+ {
+ eventHandler.startNonterminal("AnyFunctionTest", e0);
+ shift(145); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(24); // S^WS | '(:' | '*'
+ shift(38); // '*'
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("AnyFunctionTest", e0);
+ }
+
+ function try_AnyFunctionTest()
+ {
+ shiftT(145); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(24); // S^WS | '(:' | '*'
+ shiftT(38); // '*'
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_TypedFunctionTest()
+ {
+ eventHandler.startNonterminal("TypedFunctionTest", e0);
+ shift(145); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(262); // EQName^Token | S^WS | '%' | '(' | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 37) // ')'
+ {
+ whitespace();
+ parse_SequenceType();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ }
+ }
+ shift(37); // ')'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ eventHandler.endNonterminal("TypedFunctionTest", e0);
+ }
+
+ function try_TypedFunctionTest()
+ {
+ shiftT(145); // 'function'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(262); // EQName^Token | S^WS | '%' | '(' | '(:' | ')' | 'after' | 'allowing' |
+ if (l1 != 37) // ')'
+ {
+ try_SequenceType();
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+ }
+ shiftT(37); // ')'
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shiftT(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ }
+
+ function parse_ParenthesizedItemType()
+ {
+ eventHandler.startNonterminal("ParenthesizedItemType", e0);
+ shift(34); // '('
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ItemType();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shift(37); // ')'
+ eventHandler.endNonterminal("ParenthesizedItemType", e0);
+ }
+
+ function try_ParenthesizedItemType()
+ {
+ shiftT(34); // '('
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_ItemType();
+ lookahead1W(23); // S^WS | '(:' | ')'
+ shiftT(37); // ')'
+ }
+
+ function parse_RevalidationDecl()
+ {
+ eventHandler.startNonterminal("RevalidationDecl", e0);
+ shift(108); // 'declare'
+ lookahead1W(72); // S^WS | '(:' | 'revalidation'
+ shift(222); // 'revalidation'
+ lookahead1W(152); // S^WS | '(:' | 'lax' | 'skip' | 'strict'
+ switch (l1)
+ {
+ case 240: // 'strict'
+ shift(240); // 'strict'
+ break;
+ case 171: // 'lax'
+ shift(171); // 'lax'
+ break;
+ default:
+ shift(233); // 'skip'
+ }
+ eventHandler.endNonterminal("RevalidationDecl", e0);
+ }
+
+ function parse_InsertExprTargetChoice()
+ {
+ eventHandler.startNonterminal("InsertExprTargetChoice", e0);
+ switch (l1)
+ {
+ case 70: // 'after'
+ shift(70); // 'after'
+ break;
+ case 84: // 'before'
+ shift(84); // 'before'
+ break;
+ default:
+ if (l1 == 79) // 'as'
+ {
+ shift(79); // 'as'
+ lookahead1W(119); // S^WS | '(:' | 'first' | 'last'
+ switch (l1)
+ {
+ case 134: // 'first'
+ shift(134); // 'first'
+ break;
+ default:
+ shift(170); // 'last'
+ }
+ }
+ lookahead1W(54); // S^WS | '(:' | 'into'
+ shift(163); // 'into'
+ }
+ eventHandler.endNonterminal("InsertExprTargetChoice", e0);
+ }
+
+ function try_InsertExprTargetChoice()
+ {
+ switch (l1)
+ {
+ case 70: // 'after'
+ shiftT(70); // 'after'
+ break;
+ case 84: // 'before'
+ shiftT(84); // 'before'
+ break;
+ default:
+ if (l1 == 79) // 'as'
+ {
+ shiftT(79); // 'as'
+ lookahead1W(119); // S^WS | '(:' | 'first' | 'last'
+ switch (l1)
+ {
+ case 134: // 'first'
+ shiftT(134); // 'first'
+ break;
+ default:
+ shiftT(170); // 'last'
+ }
+ }
+ lookahead1W(54); // S^WS | '(:' | 'into'
+ shiftT(163); // 'into'
+ }
+ }
+
+ function parse_InsertExpr()
+ {
+ eventHandler.startNonterminal("InsertExpr", e0);
+ shift(159); // 'insert'
+ lookahead1W(129); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 191: // 'node'
+ shift(191); // 'node'
+ break;
+ default:
+ shift(192); // 'nodes'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_SourceExpr();
+ whitespace();
+ parse_InsertExprTargetChoice();
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_TargetExpr();
+ eventHandler.endNonterminal("InsertExpr", e0);
+ }
+
+ function try_InsertExpr()
+ {
+ shiftT(159); // 'insert'
+ lookahead1W(129); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 191: // 'node'
+ shiftT(191); // 'node'
+ break;
+ default:
+ shiftT(192); // 'nodes'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_SourceExpr();
+ try_InsertExprTargetChoice();
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_TargetExpr();
+ }
+
+ function parse_DeleteExpr()
+ {
+ eventHandler.startNonterminal("DeleteExpr", e0);
+ shift(110); // 'delete'
+ lookahead1W(129); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 191: // 'node'
+ shift(191); // 'node'
+ break;
+ default:
+ shift(192); // 'nodes'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_TargetExpr();
+ eventHandler.endNonterminal("DeleteExpr", e0);
+ }
+
+ function try_DeleteExpr()
+ {
+ shiftT(110); // 'delete'
+ lookahead1W(129); // S^WS | '(:' | 'node' | 'nodes'
+ switch (l1)
+ {
+ case 191: // 'node'
+ shiftT(191); // 'node'
+ break;
+ default:
+ shiftT(192); // 'nodes'
+ }
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_TargetExpr();
+ }
+
+ function parse_ReplaceExpr()
+ {
+ eventHandler.startNonterminal("ReplaceExpr", e0);
+ shift(219); // 'replace'
+ lookahead1W(130); // S^WS | '(:' | 'node' | 'value'
+ if (l1 == 261) // 'value'
+ {
+ shift(261); // 'value'
+ lookahead1W(64); // S^WS | '(:' | 'of'
+ shift(196); // 'of'
+ }
+ lookahead1W(62); // S^WS | '(:' | 'node'
+ shift(191); // 'node'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_TargetExpr();
+ shift(270); // 'with'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ReplaceExpr", e0);
+ }
+
+ function try_ReplaceExpr()
+ {
+ shiftT(219); // 'replace'
+ lookahead1W(130); // S^WS | '(:' | 'node' | 'value'
+ if (l1 == 261) // 'value'
+ {
+ shiftT(261); // 'value'
+ lookahead1W(64); // S^WS | '(:' | 'of'
+ shiftT(196); // 'of'
+ }
+ lookahead1W(62); // S^WS | '(:' | 'node'
+ shiftT(191); // 'node'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_TargetExpr();
+ shiftT(270); // 'with'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_RenameExpr()
+ {
+ eventHandler.startNonterminal("RenameExpr", e0);
+ shift(218); // 'rename'
+ lookahead1W(62); // S^WS | '(:' | 'node'
+ shift(191); // 'node'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_TargetExpr();
+ shift(79); // 'as'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_NewNameExpr();
+ eventHandler.endNonterminal("RenameExpr", e0);
+ }
+
+ function try_RenameExpr()
+ {
+ shiftT(218); // 'rename'
+ lookahead1W(62); // S^WS | '(:' | 'node'
+ shiftT(191); // 'node'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_TargetExpr();
+ shiftT(79); // 'as'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_NewNameExpr();
+ }
+
+ function parse_SourceExpr()
+ {
+ eventHandler.startNonterminal("SourceExpr", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("SourceExpr", e0);
+ }
+
+ function try_SourceExpr()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_TargetExpr()
+ {
+ eventHandler.startNonterminal("TargetExpr", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TargetExpr", e0);
+ }
+
+ function try_TargetExpr()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_NewNameExpr()
+ {
+ eventHandler.startNonterminal("NewNameExpr", e0);
+ parse_ExprSingle();
+ eventHandler.endNonterminal("NewNameExpr", e0);
+ }
+
+ function try_NewNameExpr()
+ {
+ try_ExprSingle();
+ }
+
+ function parse_TransformExpr()
+ {
+ eventHandler.startNonterminal("TransformExpr", e0);
+ shift(103); // 'copy'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_TransformSpec();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_TransformSpec();
+ }
+ shift(181); // 'modify'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TransformExpr", e0);
+ }
+
+ function try_TransformExpr()
+ {
+ shiftT(103); // 'copy'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_TransformSpec();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ try_TransformSpec();
+ }
+ shiftT(181); // 'modify'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(220); // 'return'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_TransformSpec()
+ {
+ eventHandler.startNonterminal("TransformSpec", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("TransformSpec", e0);
+ }
+
+ function try_TransformSpec()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_FTSelection()
+ {
+ eventHandler.startNonterminal("FTSelection", e0);
+ parse_FTOr();
+ for (;;)
+ {
+ lookahead1W(211); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(151); // S^WS | '(:' | 'end' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 115 // 'different'
+ && lk != 117 // 'distance'
+ && lk != 127 // 'entire'
+ && lk != 202 // 'ordered'
+ && lk != 223 // 'same'
+ && lk != 269 // 'window'
+ && lk != 64593 // 'at' 'end'
+ && lk != 121425) // 'at' 'start'
+ {
+ break;
+ }
+ whitespace();
+ parse_FTPosFilter();
+ }
+ eventHandler.endNonterminal("FTSelection", e0);
+ }
+
+ function try_FTSelection()
+ {
+ try_FTOr();
+ for (;;)
+ {
+ lookahead1W(211); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(151); // S^WS | '(:' | 'end' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 115 // 'different'
+ && lk != 117 // 'distance'
+ && lk != 127 // 'entire'
+ && lk != 202 // 'ordered'
+ && lk != 223 // 'same'
+ && lk != 269 // 'window'
+ && lk != 64593 // 'at' 'end'
+ && lk != 121425) // 'at' 'start'
+ {
+ break;
+ }
+ try_FTPosFilter();
+ }
+ }
+
+ function parse_FTWeight()
+ {
+ eventHandler.startNonterminal("FTWeight", e0);
+ shift(264); // 'weight'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("FTWeight", e0);
+ }
+
+ function try_FTWeight()
+ {
+ shiftT(264); // 'weight'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+
+ function parse_FTOr()
+ {
+ eventHandler.startNonterminal("FTOr", e0);
+ parse_FTAnd();
+ for (;;)
+ {
+ if (l1 != 144) // 'ftor'
+ {
+ break;
+ }
+ shift(144); // 'ftor'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTAnd();
+ }
+ eventHandler.endNonterminal("FTOr", e0);
+ }
+
+ function try_FTOr()
+ {
+ try_FTAnd();
+ for (;;)
+ {
+ if (l1 != 144) // 'ftor'
+ {
+ break;
+ }
+ shiftT(144); // 'ftor'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTAnd();
+ }
+ }
+
+ function parse_FTAnd()
+ {
+ eventHandler.startNonterminal("FTAnd", e0);
+ parse_FTMildNot();
+ for (;;)
+ {
+ if (l1 != 142) // 'ftand'
+ {
+ break;
+ }
+ shift(142); // 'ftand'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTMildNot();
+ }
+ eventHandler.endNonterminal("FTAnd", e0);
+ }
+
+ function try_FTAnd()
+ {
+ try_FTMildNot();
+ for (;;)
+ {
+ if (l1 != 142) // 'ftand'
+ {
+ break;
+ }
+ shiftT(142); // 'ftand'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTMildNot();
+ }
+ }
+
+ function parse_FTMildNot()
+ {
+ eventHandler.startNonterminal("FTMildNot", e0);
+ parse_FTUnaryNot();
+ for (;;)
+ {
+ lookahead1W(212); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 193) // 'not'
+ {
+ break;
+ }
+ shift(193); // 'not'
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shift(154); // 'in'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTUnaryNot();
+ }
+ eventHandler.endNonterminal("FTMildNot", e0);
+ }
+
+ function try_FTMildNot()
+ {
+ try_FTUnaryNot();
+ for (;;)
+ {
+ lookahead1W(212); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 193) // 'not'
+ {
+ break;
+ }
+ shiftT(193); // 'not'
+ lookahead1W(53); // S^WS | '(:' | 'in'
+ shiftT(154); // 'in'
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTUnaryNot();
+ }
+ }
+
+ function parse_FTUnaryNot()
+ {
+ eventHandler.startNonterminal("FTUnaryNot", e0);
+ if (l1 == 143) // 'ftnot'
+ {
+ shift(143); // 'ftnot'
+ }
+ lookahead1W(155); // StringLiteral | S^WS | '(' | '(#' | '(:' | '{'
+ whitespace();
+ parse_FTPrimaryWithOptions();
+ eventHandler.endNonterminal("FTUnaryNot", e0);
+ }
+
+ function try_FTUnaryNot()
+ {
+ if (l1 == 143) // 'ftnot'
+ {
+ shiftT(143); // 'ftnot'
+ }
+ lookahead1W(155); // StringLiteral | S^WS | '(' | '(#' | '(:' | '{'
+ try_FTPrimaryWithOptions();
+ }
+
+ function parse_FTPrimaryWithOptions()
+ {
+ eventHandler.startNonterminal("FTPrimaryWithOptions", e0);
+ parse_FTPrimary();
+ lookahead1W(214); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 259) // 'using'
+ {
+ whitespace();
+ parse_FTMatchOptions();
+ }
+ if (l1 == 264) // 'weight'
+ {
+ whitespace();
+ parse_FTWeight();
+ }
+ eventHandler.endNonterminal("FTPrimaryWithOptions", e0);
+ }
+
+ function try_FTPrimaryWithOptions()
+ {
+ try_FTPrimary();
+ lookahead1W(214); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 259) // 'using'
+ {
+ try_FTMatchOptions();
+ }
+ if (l1 == 264) // 'weight'
+ {
+ try_FTWeight();
+ }
+ }
+
+ function parse_FTPrimary()
+ {
+ eventHandler.startNonterminal("FTPrimary", e0);
+ switch (l1)
+ {
+ case 34: // '('
+ shift(34); // '('
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ whitespace();
+ parse_FTSelection();
+ shift(37); // ')'
+ break;
+ case 35: // '(#'
+ parse_FTExtensionSelection();
+ break;
+ default:
+ parse_FTWords();
+ lookahead1W(215); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 195) // 'occurs'
+ {
+ whitespace();
+ parse_FTTimes();
+ }
+ }
+ eventHandler.endNonterminal("FTPrimary", e0);
+ }
+
+ function try_FTPrimary()
+ {
+ switch (l1)
+ {
+ case 34: // '('
+ shiftT(34); // '('
+ lookahead1W(162); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{'
+ try_FTSelection();
+ shiftT(37); // ')'
+ break;
+ case 35: // '(#'
+ try_FTExtensionSelection();
+ break;
+ default:
+ try_FTWords();
+ lookahead1W(215); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 195) // 'occurs'
+ {
+ try_FTTimes();
+ }
+ }
+ }
+
+ function parse_FTWords()
+ {
+ eventHandler.startNonterminal("FTWords", e0);
+ parse_FTWordsValue();
+ lookahead1W(221); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 71 // 'all'
+ || l1 == 76 // 'any'
+ || l1 == 210) // 'phrase'
+ {
+ whitespace();
+ parse_FTAnyallOption();
+ }
+ eventHandler.endNonterminal("FTWords", e0);
+ }
+
+ function try_FTWords()
+ {
+ try_FTWordsValue();
+ lookahead1W(221); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 71 // 'all'
+ || l1 == 76 // 'any'
+ || l1 == 210) // 'phrase'
+ {
+ try_FTAnyallOption();
+ }
+ }
+
+ function parse_FTWordsValue()
+ {
+ eventHandler.startNonterminal("FTWordsValue", e0);
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shift(11); // StringLiteral
+ break;
+ default:
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ }
+ eventHandler.endNonterminal("FTWordsValue", e0);
+ }
+
+ function try_FTWordsValue()
+ {
+ switch (l1)
+ {
+ case 11: // StringLiteral
+ shiftT(11); // StringLiteral
+ break;
+ default:
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ }
+ }
+
+ function parse_FTExtensionSelection()
+ {
+ eventHandler.startNonterminal("FTExtensionSelection", e0);
+ for (;;)
+ {
+ whitespace();
+ parse_Pragma();
+ lookahead1W(100); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 35) // '(#'
+ {
+ break;
+ }
+ }
+ shift(276); // '{'
+ lookahead1W(166); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{' | '}'
+ if (l1 != 282) // '}'
+ {
+ whitespace();
+ parse_FTSelection();
+ }
+ shift(282); // '}'
+ eventHandler.endNonterminal("FTExtensionSelection", e0);
+ }
+
+ function try_FTExtensionSelection()
+ {
+ for (;;)
+ {
+ try_Pragma();
+ lookahead1W(100); // S^WS | '(#' | '(:' | '{'
+ if (l1 != 35) // '(#'
+ {
+ break;
+ }
+ }
+ shiftT(276); // '{'
+ lookahead1W(166); // StringLiteral | S^WS | '(' | '(#' | '(:' | 'ftnot' | '{' | '}'
+ if (l1 != 282) // '}'
+ {
+ try_FTSelection();
+ }
+ shiftT(282); // '}'
+ }
+
+ function parse_FTAnyallOption()
+ {
+ eventHandler.startNonterminal("FTAnyallOption", e0);
+ switch (l1)
+ {
+ case 76: // 'any'
+ shift(76); // 'any'
+ lookahead1W(218); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 272) // 'word'
+ {
+ shift(272); // 'word'
+ }
+ break;
+ case 71: // 'all'
+ shift(71); // 'all'
+ lookahead1W(219); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 273) // 'words'
+ {
+ shift(273); // 'words'
+ }
+ break;
+ default:
+ shift(210); // 'phrase'
+ }
+ eventHandler.endNonterminal("FTAnyallOption", e0);
+ }
+
+ function try_FTAnyallOption()
+ {
+ switch (l1)
+ {
+ case 76: // 'any'
+ shiftT(76); // 'any'
+ lookahead1W(218); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 272) // 'word'
+ {
+ shiftT(272); // 'word'
+ }
+ break;
+ case 71: // 'all'
+ shiftT(71); // 'all'
+ lookahead1W(219); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 273) // 'words'
+ {
+ shiftT(273); // 'words'
+ }
+ break;
+ default:
+ shiftT(210); // 'phrase'
+ }
+ }
+
+ function parse_FTTimes()
+ {
+ eventHandler.startNonterminal("FTTimes", e0);
+ shift(195); // 'occurs'
+ lookahead1W(149); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ whitespace();
+ parse_FTRange();
+ shift(247); // 'times'
+ eventHandler.endNonterminal("FTTimes", e0);
+ }
+
+ function try_FTTimes()
+ {
+ shiftT(195); // 'occurs'
+ lookahead1W(149); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ try_FTRange();
+ shiftT(247); // 'times'
+ }
+
+ function parse_FTRange()
+ {
+ eventHandler.startNonterminal("FTRange", e0);
+ switch (l1)
+ {
+ case 130: // 'exactly'
+ shift(130); // 'exactly'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ break;
+ case 81: // 'at'
+ shift(81); // 'at'
+ lookahead1W(125); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 173: // 'least'
+ shift(173); // 'least'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ break;
+ default:
+ shift(183); // 'most'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ }
+ break;
+ default:
+ shift(140); // 'from'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ shift(248); // 'to'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ }
+ eventHandler.endNonterminal("FTRange", e0);
+ }
+
+ function try_FTRange()
+ {
+ switch (l1)
+ {
+ case 130: // 'exactly'
+ shiftT(130); // 'exactly'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ break;
+ case 81: // 'at'
+ shiftT(81); // 'at'
+ lookahead1W(125); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 173: // 'least'
+ shiftT(173); // 'least'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ break;
+ default:
+ shiftT(183); // 'most'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ }
+ break;
+ default:
+ shiftT(140); // 'from'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ shiftT(248); // 'to'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ }
+ }
+
+ function parse_FTPosFilter()
+ {
+ eventHandler.startNonterminal("FTPosFilter", e0);
+ switch (l1)
+ {
+ case 202: // 'ordered'
+ parse_FTOrder();
+ break;
+ case 269: // 'window'
+ parse_FTWindow();
+ break;
+ case 117: // 'distance'
+ parse_FTDistance();
+ break;
+ case 115: // 'different'
+ case 223: // 'same'
+ parse_FTScope();
+ break;
+ default:
+ parse_FTContent();
+ }
+ eventHandler.endNonterminal("FTPosFilter", e0);
+ }
+
+ function try_FTPosFilter()
+ {
+ switch (l1)
+ {
+ case 202: // 'ordered'
+ try_FTOrder();
+ break;
+ case 269: // 'window'
+ try_FTWindow();
+ break;
+ case 117: // 'distance'
+ try_FTDistance();
+ break;
+ case 115: // 'different'
+ case 223: // 'same'
+ try_FTScope();
+ break;
+ default:
+ try_FTContent();
+ }
+ }
+
+ function parse_FTOrder()
+ {
+ eventHandler.startNonterminal("FTOrder", e0);
+ shift(202); // 'ordered'
+ eventHandler.endNonterminal("FTOrder", e0);
+ }
+
+ function try_FTOrder()
+ {
+ shiftT(202); // 'ordered'
+ }
+
+ function parse_FTWindow()
+ {
+ eventHandler.startNonterminal("FTWindow", e0);
+ shift(269); // 'window'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_AdditiveExpr();
+ whitespace();
+ parse_FTUnit();
+ eventHandler.endNonterminal("FTWindow", e0);
+ }
+
+ function try_FTWindow()
+ {
+ shiftT(269); // 'window'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_AdditiveExpr();
+ try_FTUnit();
+ }
+
+ function parse_FTDistance()
+ {
+ eventHandler.startNonterminal("FTDistance", e0);
+ shift(117); // 'distance'
+ lookahead1W(149); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ whitespace();
+ parse_FTRange();
+ whitespace();
+ parse_FTUnit();
+ eventHandler.endNonterminal("FTDistance", e0);
+ }
+
+ function try_FTDistance()
+ {
+ shiftT(117); // 'distance'
+ lookahead1W(149); // S^WS | '(:' | 'at' | 'exactly' | 'from'
+ try_FTRange();
+ try_FTUnit();
+ }
+
+ function parse_FTUnit()
+ {
+ eventHandler.startNonterminal("FTUnit", e0);
+ switch (l1)
+ {
+ case 273: // 'words'
+ shift(273); // 'words'
+ break;
+ case 232: // 'sentences'
+ shift(232); // 'sentences'
+ break;
+ default:
+ shift(205); // 'paragraphs'
+ }
+ eventHandler.endNonterminal("FTUnit", e0);
+ }
+
+ function try_FTUnit()
+ {
+ switch (l1)
+ {
+ case 273: // 'words'
+ shiftT(273); // 'words'
+ break;
+ case 232: // 'sentences'
+ shiftT(232); // 'sentences'
+ break;
+ default:
+ shiftT(205); // 'paragraphs'
+ }
+ }
+
+ function parse_FTScope()
+ {
+ eventHandler.startNonterminal("FTScope", e0);
+ switch (l1)
+ {
+ case 223: // 'same'
+ shift(223); // 'same'
+ break;
+ default:
+ shift(115); // 'different'
+ }
+ lookahead1W(132); // S^WS | '(:' | 'paragraph' | 'sentence'
+ whitespace();
+ parse_FTBigUnit();
+ eventHandler.endNonterminal("FTScope", e0);
+ }
+
+ function try_FTScope()
+ {
+ switch (l1)
+ {
+ case 223: // 'same'
+ shiftT(223); // 'same'
+ break;
+ default:
+ shiftT(115); // 'different'
+ }
+ lookahead1W(132); // S^WS | '(:' | 'paragraph' | 'sentence'
+ try_FTBigUnit();
+ }
+
+ function parse_FTBigUnit()
+ {
+ eventHandler.startNonterminal("FTBigUnit", e0);
+ switch (l1)
+ {
+ case 231: // 'sentence'
+ shift(231); // 'sentence'
+ break;
+ default:
+ shift(204); // 'paragraph'
+ }
+ eventHandler.endNonterminal("FTBigUnit", e0);
+ }
+
+ function try_FTBigUnit()
+ {
+ switch (l1)
+ {
+ case 231: // 'sentence'
+ shiftT(231); // 'sentence'
+ break;
+ default:
+ shiftT(204); // 'paragraph'
+ }
+ }
+
+ function parse_FTContent()
+ {
+ eventHandler.startNonterminal("FTContent", e0);
+ switch (l1)
+ {
+ case 81: // 'at'
+ shift(81); // 'at'
+ lookahead1W(117); // S^WS | '(:' | 'end' | 'start'
+ switch (l1)
+ {
+ case 237: // 'start'
+ shift(237); // 'start'
+ break;
+ default:
+ shift(126); // 'end'
+ }
+ break;
+ default:
+ shift(127); // 'entire'
+ lookahead1W(42); // S^WS | '(:' | 'content'
+ shift(100); // 'content'
+ }
+ eventHandler.endNonterminal("FTContent", e0);
+ }
+
+ function try_FTContent()
+ {
+ switch (l1)
+ {
+ case 81: // 'at'
+ shiftT(81); // 'at'
+ lookahead1W(117); // S^WS | '(:' | 'end' | 'start'
+ switch (l1)
+ {
+ case 237: // 'start'
+ shiftT(237); // 'start'
+ break;
+ default:
+ shiftT(126); // 'end'
+ }
+ break;
+ default:
+ shiftT(127); // 'entire'
+ lookahead1W(42); // S^WS | '(:' | 'content'
+ shiftT(100); // 'content'
+ }
+ }
+
+ function parse_FTMatchOptions()
+ {
+ eventHandler.startNonterminal("FTMatchOptions", e0);
+ for (;;)
+ {
+ shift(259); // 'using'
+ lookahead1W(181); // S^WS | '(:' | 'case' | 'diacritics' | 'language' | 'lowercase' | 'no' |
+ whitespace();
+ parse_FTMatchOption();
+ lookahead1W(214); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 259) // 'using'
+ {
+ break;
+ }
+ }
+ eventHandler.endNonterminal("FTMatchOptions", e0);
+ }
+
+ function try_FTMatchOptions()
+ {
+ for (;;)
+ {
+ shiftT(259); // 'using'
+ lookahead1W(181); // S^WS | '(:' | 'case' | 'diacritics' | 'language' | 'lowercase' | 'no' |
+ try_FTMatchOption();
+ lookahead1W(214); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 259) // 'using'
+ {
+ break;
+ }
+ }
+ }
+
+ function parse_FTMatchOption()
+ {
+ eventHandler.startNonterminal("FTMatchOption", e0);
+ switch (l1)
+ {
+ case 188: // 'no'
+ lookahead2W(161); // S^WS | '(:' | 'stemming' | 'stop' | 'thesaurus' | 'wildcards'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 169: // 'language'
+ parse_FTLanguageOption();
+ break;
+ case 268: // 'wildcards'
+ case 137404: // 'no' 'wildcards'
+ parse_FTWildCardOption();
+ break;
+ case 246: // 'thesaurus'
+ case 126140: // 'no' 'thesaurus'
+ parse_FTThesaurusOption();
+ break;
+ case 238: // 'stemming'
+ case 122044: // 'no' 'stemming'
+ parse_FTStemOption();
+ break;
+ case 114: // 'diacritics'
+ parse_FTDiacriticsOption();
+ break;
+ case 239: // 'stop'
+ case 122556: // 'no' 'stop'
+ parse_FTStopWordOption();
+ break;
+ case 199: // 'option'
+ parse_FTExtensionOption();
+ break;
+ default:
+ parse_FTCaseOption();
+ }
+ eventHandler.endNonterminal("FTMatchOption", e0);
+ }
+
+ function try_FTMatchOption()
+ {
+ switch (l1)
+ {
+ case 188: // 'no'
+ lookahead2W(161); // S^WS | '(:' | 'stemming' | 'stop' | 'thesaurus' | 'wildcards'
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 169: // 'language'
+ try_FTLanguageOption();
+ break;
+ case 268: // 'wildcards'
+ case 137404: // 'no' 'wildcards'
+ try_FTWildCardOption();
+ break;
+ case 246: // 'thesaurus'
+ case 126140: // 'no' 'thesaurus'
+ try_FTThesaurusOption();
+ break;
+ case 238: // 'stemming'
+ case 122044: // 'no' 'stemming'
+ try_FTStemOption();
+ break;
+ case 114: // 'diacritics'
+ try_FTDiacriticsOption();
+ break;
+ case 239: // 'stop'
+ case 122556: // 'no' 'stop'
+ try_FTStopWordOption();
+ break;
+ case 199: // 'option'
+ try_FTExtensionOption();
+ break;
+ default:
+ try_FTCaseOption();
+ }
+ }
+
+ function parse_FTCaseOption()
+ {
+ eventHandler.startNonterminal("FTCaseOption", e0);
+ switch (l1)
+ {
+ case 88: // 'case'
+ shift(88); // 'case'
+ lookahead1W(124); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 158: // 'insensitive'
+ shift(158); // 'insensitive'
+ break;
+ default:
+ shift(230); // 'sensitive'
+ }
+ break;
+ case 177: // 'lowercase'
+ shift(177); // 'lowercase'
+ break;
+ default:
+ shift(258); // 'uppercase'
+ }
+ eventHandler.endNonterminal("FTCaseOption", e0);
+ }
+
+ function try_FTCaseOption()
+ {
+ switch (l1)
+ {
+ case 88: // 'case'
+ shiftT(88); // 'case'
+ lookahead1W(124); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 158: // 'insensitive'
+ shiftT(158); // 'insensitive'
+ break;
+ default:
+ shiftT(230); // 'sensitive'
+ }
+ break;
+ case 177: // 'lowercase'
+ shiftT(177); // 'lowercase'
+ break;
+ default:
+ shiftT(258); // 'uppercase'
+ }
+ }
+
+ function parse_FTDiacriticsOption()
+ {
+ eventHandler.startNonterminal("FTDiacriticsOption", e0);
+ shift(114); // 'diacritics'
+ lookahead1W(124); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 158: // 'insensitive'
+ shift(158); // 'insensitive'
+ break;
+ default:
+ shift(230); // 'sensitive'
+ }
+ eventHandler.endNonterminal("FTDiacriticsOption", e0);
+ }
+
+ function try_FTDiacriticsOption()
+ {
+ shiftT(114); // 'diacritics'
+ lookahead1W(124); // S^WS | '(:' | 'insensitive' | 'sensitive'
+ switch (l1)
+ {
+ case 158: // 'insensitive'
+ shiftT(158); // 'insensitive'
+ break;
+ default:
+ shiftT(230); // 'sensitive'
+ }
+ }
+
+ function parse_FTStemOption()
+ {
+ eventHandler.startNonterminal("FTStemOption", e0);
+ switch (l1)
+ {
+ case 238: // 'stemming'
+ shift(238); // 'stemming'
+ break;
+ default:
+ shift(188); // 'no'
+ lookahead1W(74); // S^WS | '(:' | 'stemming'
+ shift(238); // 'stemming'
+ }
+ eventHandler.endNonterminal("FTStemOption", e0);
+ }
+
+ function try_FTStemOption()
+ {
+ switch (l1)
+ {
+ case 238: // 'stemming'
+ shiftT(238); // 'stemming'
+ break;
+ default:
+ shiftT(188); // 'no'
+ lookahead1W(74); // S^WS | '(:' | 'stemming'
+ shiftT(238); // 'stemming'
+ }
+ }
+
+ function parse_FTThesaurusOption()
+ {
+ eventHandler.startNonterminal("FTThesaurusOption", e0);
+ switch (l1)
+ {
+ case 246: // 'thesaurus'
+ shift(246); // 'thesaurus'
+ lookahead1W(142); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 81: // 'at'
+ whitespace();
+ parse_FTThesaurusID();
+ break;
+ case 109: // 'default'
+ shift(109); // 'default'
+ break;
+ default:
+ shift(34); // '('
+ lookahead1W(112); // S^WS | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 81: // 'at'
+ whitespace();
+ parse_FTThesaurusID();
+ break;
+ default:
+ shift(109); // 'default'
+ }
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(31); // S^WS | '(:' | 'at'
+ whitespace();
+ parse_FTThesaurusID();
+ }
+ shift(37); // ')'
+ }
+ break;
+ default:
+ shift(188); // 'no'
+ lookahead1W(78); // S^WS | '(:' | 'thesaurus'
+ shift(246); // 'thesaurus'
+ }
+ eventHandler.endNonterminal("FTThesaurusOption", e0);
+ }
+
+ function try_FTThesaurusOption()
+ {
+ switch (l1)
+ {
+ case 246: // 'thesaurus'
+ shiftT(246); // 'thesaurus'
+ lookahead1W(142); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 81: // 'at'
+ try_FTThesaurusID();
+ break;
+ case 109: // 'default'
+ shiftT(109); // 'default'
+ break;
+ default:
+ shiftT(34); // '('
+ lookahead1W(112); // S^WS | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 81: // 'at'
+ try_FTThesaurusID();
+ break;
+ default:
+ shiftT(109); // 'default'
+ }
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(31); // S^WS | '(:' | 'at'
+ try_FTThesaurusID();
+ }
+ shiftT(37); // ')'
+ }
+ break;
+ default:
+ shiftT(188); // 'no'
+ lookahead1W(78); // S^WS | '(:' | 'thesaurus'
+ shiftT(246); // 'thesaurus'
+ }
+ }
+
+ function parse_FTThesaurusID()
+ {
+ eventHandler.startNonterminal("FTThesaurusID", e0);
+ shift(81); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ lookahead1W(220); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 217) // 'relationship'
+ {
+ shift(217); // 'relationship'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ lookahead1W(216); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(165); // S^WS | '(:' | 'end' | 'least' | 'most' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 130 // 'exactly'
+ || lk == 140 // 'from'
+ || lk == 88657 // 'at' 'least'
+ || lk == 93777) // 'at' 'most'
+ {
+ whitespace();
+ parse_FTLiteralRange();
+ lookahead1W(58); // S^WS | '(:' | 'levels'
+ shift(175); // 'levels'
+ }
+ eventHandler.endNonterminal("FTThesaurusID", e0);
+ }
+
+ function try_FTThesaurusID()
+ {
+ shiftT(81); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ lookahead1W(220); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 == 217) // 'relationship'
+ {
+ shiftT(217); // 'relationship'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+ lookahead1W(216); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(165); // S^WS | '(:' | 'end' | 'least' | 'most' | 'position' | 'start'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 130 // 'exactly'
+ || lk == 140 // 'from'
+ || lk == 88657 // 'at' 'least'
+ || lk == 93777) // 'at' 'most'
+ {
+ try_FTLiteralRange();
+ lookahead1W(58); // S^WS | '(:' | 'levels'
+ shiftT(175); // 'levels'
+ }
+ }
+
+ function parse_FTLiteralRange()
+ {
+ eventHandler.startNonterminal("FTLiteralRange", e0);
+ switch (l1)
+ {
+ case 130: // 'exactly'
+ shift(130); // 'exactly'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ break;
+ case 81: // 'at'
+ shift(81); // 'at'
+ lookahead1W(125); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 173: // 'least'
+ shift(173); // 'least'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ break;
+ default:
+ shift(183); // 'most'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ }
+ break;
+ default:
+ shift(140); // 'from'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ lookahead1W(79); // S^WS | '(:' | 'to'
+ shift(248); // 'to'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shift(8); // IntegerLiteral
+ }
+ eventHandler.endNonterminal("FTLiteralRange", e0);
+ }
+
+ function try_FTLiteralRange()
+ {
+ switch (l1)
+ {
+ case 130: // 'exactly'
+ shiftT(130); // 'exactly'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ break;
+ case 81: // 'at'
+ shiftT(81); // 'at'
+ lookahead1W(125); // S^WS | '(:' | 'least' | 'most'
+ switch (l1)
+ {
+ case 173: // 'least'
+ shiftT(173); // 'least'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ break;
+ default:
+ shiftT(183); // 'most'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ }
+ break;
+ default:
+ shiftT(140); // 'from'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ lookahead1W(79); // S^WS | '(:' | 'to'
+ shiftT(248); // 'to'
+ lookahead1W(16); // IntegerLiteral | S^WS | '(:'
+ shiftT(8); // IntegerLiteral
+ }
+ }
+
+ function parse_FTStopWordOption()
+ {
+ eventHandler.startNonterminal("FTStopWordOption", e0);
+ switch (l1)
+ {
+ case 239: // 'stop'
+ shift(239); // 'stop'
+ lookahead1W(86); // S^WS | '(:' | 'words'
+ shift(273); // 'words'
+ lookahead1W(142); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 109: // 'default'
+ shift(109); // 'default'
+ for (;;)
+ {
+ lookahead1W(217); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 131 // 'except'
+ && l1 != 254) // 'union'
+ {
+ break;
+ }
+ whitespace();
+ parse_FTStopWordsInclExcl();
+ }
+ break;
+ default:
+ whitespace();
+ parse_FTStopWords();
+ for (;;)
+ {
+ lookahead1W(217); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 131 // 'except'
+ && l1 != 254) // 'union'
+ {
+ break;
+ }
+ whitespace();
+ parse_FTStopWordsInclExcl();
+ }
+ }
+ break;
+ default:
+ shift(188); // 'no'
+ lookahead1W(75); // S^WS | '(:' | 'stop'
+ shift(239); // 'stop'
+ lookahead1W(86); // S^WS | '(:' | 'words'
+ shift(273); // 'words'
+ }
+ eventHandler.endNonterminal("FTStopWordOption", e0);
+ }
+
+ function try_FTStopWordOption()
+ {
+ switch (l1)
+ {
+ case 239: // 'stop'
+ shiftT(239); // 'stop'
+ lookahead1W(86); // S^WS | '(:' | 'words'
+ shiftT(273); // 'words'
+ lookahead1W(142); // S^WS | '(' | '(:' | 'at' | 'default'
+ switch (l1)
+ {
+ case 109: // 'default'
+ shiftT(109); // 'default'
+ for (;;)
+ {
+ lookahead1W(217); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 131 // 'except'
+ && l1 != 254) // 'union'
+ {
+ break;
+ }
+ try_FTStopWordsInclExcl();
+ }
+ break;
+ default:
+ try_FTStopWords();
+ for (;;)
+ {
+ lookahead1W(217); // S^WS | EOF | '!=' | '(:' | ')' | ',' | ':' | ';' | '<' | '<<' | '<=' | '=' |
+ if (l1 != 131 // 'except'
+ && l1 != 254) // 'union'
+ {
+ break;
+ }
+ try_FTStopWordsInclExcl();
+ }
+ }
+ break;
+ default:
+ shiftT(188); // 'no'
+ lookahead1W(75); // S^WS | '(:' | 'stop'
+ shiftT(239); // 'stop'
+ lookahead1W(86); // S^WS | '(:' | 'words'
+ shiftT(273); // 'words'
+ }
+ }
+
+ function parse_FTStopWords()
+ {
+ eventHandler.startNonterminal("FTStopWords", e0);
+ switch (l1)
+ {
+ case 81: // 'at'
+ shift(81); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ break;
+ default:
+ shift(34); // '('
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ }
+ shift(37); // ')'
+ }
+ eventHandler.endNonterminal("FTStopWords", e0);
+ }
+
+ function try_FTStopWords()
+ {
+ switch (l1)
+ {
+ case 81: // 'at'
+ shiftT(81); // 'at'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shiftT(7); // URILiteral
+ break;
+ default:
+ shiftT(34); // '('
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ for (;;)
+ {
+ lookahead1W(101); // S^WS | '(:' | ')' | ','
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+ shiftT(37); // ')'
+ }
+ }
+
+ function parse_FTStopWordsInclExcl()
+ {
+ eventHandler.startNonterminal("FTStopWordsInclExcl", e0);
+ switch (l1)
+ {
+ case 254: // 'union'
+ shift(254); // 'union'
+ break;
+ default:
+ shift(131); // 'except'
+ }
+ lookahead1W(99); // S^WS | '(' | '(:' | 'at'
+ whitespace();
+ parse_FTStopWords();
+ eventHandler.endNonterminal("FTStopWordsInclExcl", e0);
+ }
+
+ function try_FTStopWordsInclExcl()
+ {
+ switch (l1)
+ {
+ case 254: // 'union'
+ shiftT(254); // 'union'
+ break;
+ default:
+ shiftT(131); // 'except'
+ }
+ lookahead1W(99); // S^WS | '(' | '(:' | 'at'
+ try_FTStopWords();
+ }
+
+ function parse_FTLanguageOption()
+ {
+ eventHandler.startNonterminal("FTLanguageOption", e0);
+ shift(169); // 'language'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ eventHandler.endNonterminal("FTLanguageOption", e0);
+ }
+
+ function try_FTLanguageOption()
+ {
+ shiftT(169); // 'language'
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+
+ function parse_FTWildCardOption()
+ {
+ eventHandler.startNonterminal("FTWildCardOption", e0);
+ switch (l1)
+ {
+ case 268: // 'wildcards'
+ shift(268); // 'wildcards'
+ break;
+ default:
+ shift(188); // 'no'
+ lookahead1W(84); // S^WS | '(:' | 'wildcards'
+ shift(268); // 'wildcards'
+ }
+ eventHandler.endNonterminal("FTWildCardOption", e0);
+ }
+
+ function try_FTWildCardOption()
+ {
+ switch (l1)
+ {
+ case 268: // 'wildcards'
+ shiftT(268); // 'wildcards'
+ break;
+ default:
+ shiftT(188); // 'no'
+ lookahead1W(84); // S^WS | '(:' | 'wildcards'
+ shiftT(268); // 'wildcards'
+ }
+ }
+
+ function parse_FTExtensionOption()
+ {
+ eventHandler.startNonterminal("FTExtensionOption", e0);
+ shift(199); // 'option'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shift(11); // StringLiteral
+ eventHandler.endNonterminal("FTExtensionOption", e0);
+ }
+
+ function try_FTExtensionOption()
+ {
+ shiftT(199); // 'option'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_EQName();
+ lookahead1W(17); // StringLiteral | S^WS | '(:'
+ shiftT(11); // StringLiteral
+ }
+
+ function parse_FTIgnoreOption()
+ {
+ eventHandler.startNonterminal("FTIgnoreOption", e0);
+ shift(271); // 'without'
+ lookahead1W(42); // S^WS | '(:' | 'content'
+ shift(100); // 'content'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_UnionExpr();
+ eventHandler.endNonterminal("FTIgnoreOption", e0);
+ }
+
+ function try_FTIgnoreOption()
+ {
+ shiftT(271); // 'without'
+ lookahead1W(42); // S^WS | '(:' | 'content'
+ shiftT(100); // 'content'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_UnionExpr();
+ }
+
+ function parse_CollectionDecl()
+ {
+ eventHandler.startNonterminal("CollectionDecl", e0);
+ shift(95); // 'collection'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(107); // S^WS | '(:' | ';' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_CollectionTypeDecl();
+ }
+ eventHandler.endNonterminal("CollectionDecl", e0);
+ }
+
+ function parse_CollectionTypeDecl()
+ {
+ eventHandler.startNonterminal("CollectionTypeDecl", e0);
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_ItemType();
+ lookahead1W(156); // S^WS | '(:' | '*' | '+' | ';' | '?'
+ if (l1 != 53) // ';'
+ {
+ whitespace();
+ parse_OccurrenceIndicator();
+ }
+ eventHandler.endNonterminal("CollectionTypeDecl", e0);
+ }
+
+ function parse_IndexName()
+ {
+ eventHandler.startNonterminal("IndexName", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("IndexName", e0);
+ }
+
+ function parse_IndexDomainExpr()
+ {
+ eventHandler.startNonterminal("IndexDomainExpr", e0);
+ parse_PathExpr();
+ eventHandler.endNonterminal("IndexDomainExpr", e0);
+ }
+
+ function parse_IndexKeySpec()
+ {
+ eventHandler.startNonterminal("IndexKeySpec", e0);
+ parse_IndexKeyExpr();
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_IndexKeyTypeDecl();
+ }
+ lookahead1W(146); // S^WS | '(:' | ',' | ';' | 'collation'
+ if (l1 == 94) // 'collation'
+ {
+ whitespace();
+ parse_IndexKeyCollation();
+ }
+ eventHandler.endNonterminal("IndexKeySpec", e0);
+ }
+
+ function parse_IndexKeyExpr()
+ {
+ eventHandler.startNonterminal("IndexKeyExpr", e0);
+ parse_PathExpr();
+ eventHandler.endNonterminal("IndexKeyExpr", e0);
+ }
+
+ function parse_IndexKeyTypeDecl()
+ {
+ eventHandler.startNonterminal("IndexKeyTypeDecl", e0);
+ shift(79); // 'as'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_AtomicType();
+ lookahead1W(169); // S^WS | '(:' | '*' | '+' | ',' | ';' | '?' | 'collation'
+ if (l1 == 39 // '*'
+ || l1 == 40 // '+'
+ || l1 == 64) // '?'
+ {
+ whitespace();
+ parse_OccurrenceIndicator();
+ }
+ eventHandler.endNonterminal("IndexKeyTypeDecl", e0);
+ }
+
+ function parse_AtomicType()
+ {
+ eventHandler.startNonterminal("AtomicType", e0);
+ parse_EQName();
+ eventHandler.endNonterminal("AtomicType", e0);
+ }
+
+ function parse_IndexKeyCollation()
+ {
+ eventHandler.startNonterminal("IndexKeyCollation", e0);
+ shift(94); // 'collation'
+ lookahead1W(15); // URILiteral | S^WS | '(:'
+ shift(7); // URILiteral
+ eventHandler.endNonterminal("IndexKeyCollation", e0);
+ }
+
+ function parse_IndexDecl()
+ {
+ eventHandler.startNonterminal("IndexDecl", e0);
+ shift(155); // 'index'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_IndexName();
+ lookahead1W(65); // S^WS | '(:' | 'on'
+ shift(197); // 'on'
+ lookahead1W(63); // S^WS | '(:' | 'nodes'
+ shift(192); // 'nodes'
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_IndexDomainExpr();
+ shift(87); // 'by'
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_IndexKeySpec();
+ for (;;)
+ {
+ lookahead1W(103); // S^WS | '(:' | ',' | ';'
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_IndexKeySpec();
+ }
+ eventHandler.endNonterminal("IndexDecl", e0);
+ }
+
+ function parse_ICDecl()
+ {
+ eventHandler.startNonterminal("ICDecl", e0);
+ shift(161); // 'integrity'
+ lookahead1W(40); // S^WS | '(:' | 'constraint'
+ shift(97); // 'constraint'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(120); // S^WS | '(:' | 'foreign' | 'on'
+ switch (l1)
+ {
+ case 197: // 'on'
+ whitespace();
+ parse_ICCollection();
+ break;
+ default:
+ whitespace();
+ parse_ICForeignKey();
+ }
+ eventHandler.endNonterminal("ICDecl", e0);
+ }
+
+ function parse_ICCollection()
+ {
+ eventHandler.startNonterminal("ICCollection", e0);
+ shift(197); // 'on'
+ lookahead1W(39); // S^WS | '(:' | 'collection'
+ shift(95); // 'collection'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(140); // S^WS | '$' | '(:' | 'foreach' | 'node'
+ switch (l1)
+ {
+ case 31: // '$'
+ whitespace();
+ parse_ICCollSequence();
+ break;
+ case 191: // 'node'
+ whitespace();
+ parse_ICCollSequenceUnique();
+ break;
+ default:
+ whitespace();
+ parse_ICCollNode();
+ }
+ eventHandler.endNonterminal("ICCollection", e0);
+ }
+
+ function parse_ICCollSequence()
+ {
+ eventHandler.startNonterminal("ICCollSequence", e0);
+ parse_VarRef();
+ lookahead1W(37); // S^WS | '(:' | 'check'
+ shift(92); // 'check'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ICCollSequence", e0);
+ }
+
+ function parse_ICCollSequenceUnique()
+ {
+ eventHandler.startNonterminal("ICCollSequenceUnique", e0);
+ shift(191); // 'node'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_VarRef();
+ lookahead1W(37); // S^WS | '(:' | 'check'
+ shift(92); // 'check'
+ lookahead1W(80); // S^WS | '(:' | 'unique'
+ shift(255); // 'unique'
+ lookahead1W(57); // S^WS | '(:' | 'key'
+ shift(168); // 'key'
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_PathExpr();
+ eventHandler.endNonterminal("ICCollSequenceUnique", e0);
+ }
+
+ function parse_ICCollNode()
+ {
+ eventHandler.startNonterminal("ICCollNode", e0);
+ shift(138); // 'foreach'
+ lookahead1W(62); // S^WS | '(:' | 'node'
+ shift(191); // 'node'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_VarRef();
+ lookahead1W(37); // S^WS | '(:' | 'check'
+ shift(92); // 'check'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("ICCollNode", e0);
+ }
+
+ function parse_ICForeignKey()
+ {
+ eventHandler.startNonterminal("ICForeignKey", e0);
+ shift(139); // 'foreign'
+ lookahead1W(57); // S^WS | '(:' | 'key'
+ shift(168); // 'key'
+ lookahead1W(51); // S^WS | '(:' | 'from'
+ whitespace();
+ parse_ICForeignKeySource();
+ whitespace();
+ parse_ICForeignKeyTarget();
+ eventHandler.endNonterminal("ICForeignKey", e0);
+ }
+
+ function parse_ICForeignKeySource()
+ {
+ eventHandler.startNonterminal("ICForeignKeySource", e0);
+ shift(140); // 'from'
+ lookahead1W(39); // S^WS | '(:' | 'collection'
+ whitespace();
+ parse_ICForeignKeyValues();
+ eventHandler.endNonterminal("ICForeignKeySource", e0);
+ }
+
+ function parse_ICForeignKeyTarget()
+ {
+ eventHandler.startNonterminal("ICForeignKeyTarget", e0);
+ shift(248); // 'to'
+ lookahead1W(39); // S^WS | '(:' | 'collection'
+ whitespace();
+ parse_ICForeignKeyValues();
+ eventHandler.endNonterminal("ICForeignKeyTarget", e0);
+ }
+
+ function parse_ICForeignKeyValues()
+ {
+ eventHandler.startNonterminal("ICForeignKeyValues", e0);
+ shift(95); // 'collection'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(62); // S^WS | '(:' | 'node'
+ shift(191); // 'node'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ whitespace();
+ parse_VarRef();
+ lookahead1W(57); // S^WS | '(:' | 'key'
+ shift(168); // 'key'
+ lookahead1W(265); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_PathExpr();
+ eventHandler.endNonterminal("ICForeignKeyValues", e0);
+ }
+
+ function try_Comment()
+ {
+ shiftT(36); // '(:'
+ for (;;)
+ {
+ lookahead1(89); // CommentContents | '(:' | ':)'
+ if (l1 == 50) // ':)'
+ {
+ break;
+ }
+ switch (l1)
+ {
+ case 24: // CommentContents
+ shiftT(24); // CommentContents
+ break;
+ default:
+ try_Comment();
+ }
+ }
+ shiftT(50); // ':)'
+ }
+
+ function try_Whitespace()
+ {
+ switch (l1)
+ {
+ case 22: // S^WS
+ shiftT(22); // S^WS
+ break;
+ default:
+ try_Comment();
+ }
+ }
+
+ function parse_EQName()
+ {
+ eventHandler.startNonterminal("EQName", e0);
+ lookahead1(249); // EQName^Token | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' | 'and' |
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ shift(82); // 'attribute'
+ break;
+ case 96: // 'comment'
+ shift(96); // 'comment'
+ break;
+ case 120: // 'document-node'
+ shift(120); // 'document-node'
+ break;
+ case 121: // 'element'
+ shift(121); // 'element'
+ break;
+ case 124: // 'empty-sequence'
+ shift(124); // 'empty-sequence'
+ break;
+ case 145: // 'function'
+ shift(145); // 'function'
+ break;
+ case 152: // 'if'
+ shift(152); // 'if'
+ break;
+ case 165: // 'item'
+ shift(165); // 'item'
+ break;
+ case 185: // 'namespace-node'
+ shift(185); // 'namespace-node'
+ break;
+ case 191: // 'node'
+ shift(191); // 'node'
+ break;
+ case 216: // 'processing-instruction'
+ shift(216); // 'processing-instruction'
+ break;
+ case 226: // 'schema-attribute'
+ shift(226); // 'schema-attribute'
+ break;
+ case 227: // 'schema-element'
+ shift(227); // 'schema-element'
+ break;
+ case 243: // 'switch'
+ shift(243); // 'switch'
+ break;
+ case 244: // 'text'
+ shift(244); // 'text'
+ break;
+ case 253: // 'typeswitch'
+ shift(253); // 'typeswitch'
+ break;
+ case 78: // 'array'
+ shift(78); // 'array'
+ break;
+ case 167: // 'json-item'
+ shift(167); // 'json-item'
+ break;
+ case 242: // 'structured-item'
+ shift(242); // 'structured-item'
+ break;
+ default:
+ parse_FunctionName();
+ }
+ eventHandler.endNonterminal("EQName", e0);
+ }
+
+ function try_EQName()
+ {
+ lookahead1(249); // EQName^Token | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' | 'and' |
+ switch (l1)
+ {
+ case 82: // 'attribute'
+ shiftT(82); // 'attribute'
+ break;
+ case 96: // 'comment'
+ shiftT(96); // 'comment'
+ break;
+ case 120: // 'document-node'
+ shiftT(120); // 'document-node'
+ break;
+ case 121: // 'element'
+ shiftT(121); // 'element'
+ break;
+ case 124: // 'empty-sequence'
+ shiftT(124); // 'empty-sequence'
+ break;
+ case 145: // 'function'
+ shiftT(145); // 'function'
+ break;
+ case 152: // 'if'
+ shiftT(152); // 'if'
+ break;
+ case 165: // 'item'
+ shiftT(165); // 'item'
+ break;
+ case 185: // 'namespace-node'
+ shiftT(185); // 'namespace-node'
+ break;
+ case 191: // 'node'
+ shiftT(191); // 'node'
+ break;
+ case 216: // 'processing-instruction'
+ shiftT(216); // 'processing-instruction'
+ break;
+ case 226: // 'schema-attribute'
+ shiftT(226); // 'schema-attribute'
+ break;
+ case 227: // 'schema-element'
+ shiftT(227); // 'schema-element'
+ break;
+ case 243: // 'switch'
+ shiftT(243); // 'switch'
+ break;
+ case 244: // 'text'
+ shiftT(244); // 'text'
+ break;
+ case 253: // 'typeswitch'
+ shiftT(253); // 'typeswitch'
+ break;
+ case 78: // 'array'
+ shiftT(78); // 'array'
+ break;
+ case 167: // 'json-item'
+ shiftT(167); // 'json-item'
+ break;
+ case 242: // 'structured-item'
+ shiftT(242); // 'structured-item'
+ break;
+ default:
+ try_FunctionName();
+ }
+ }
+
+ function parse_FunctionName()
+ {
+ eventHandler.startNonterminal("FunctionName", e0);
+ switch (l1)
+ {
+ case 6: // EQName^Token
+ shift(6); // EQName^Token
+ break;
+ case 70: // 'after'
+ shift(70); // 'after'
+ break;
+ case 73: // 'ancestor'
+ shift(73); // 'ancestor'
+ break;
+ case 74: // 'ancestor-or-self'
+ shift(74); // 'ancestor-or-self'
+ break;
+ case 75: // 'and'
+ shift(75); // 'and'
+ break;
+ case 79: // 'as'
+ shift(79); // 'as'
+ break;
+ case 80: // 'ascending'
+ shift(80); // 'ascending'
+ break;
+ case 84: // 'before'
+ shift(84); // 'before'
+ break;
+ case 88: // 'case'
+ shift(88); // 'case'
+ break;
+ case 89: // 'cast'
+ shift(89); // 'cast'
+ break;
+ case 90: // 'castable'
+ shift(90); // 'castable'
+ break;
+ case 93: // 'child'
+ shift(93); // 'child'
+ break;
+ case 94: // 'collation'
+ shift(94); // 'collation'
+ break;
+ case 103: // 'copy'
+ shift(103); // 'copy'
+ break;
+ case 105: // 'count'
+ shift(105); // 'count'
+ break;
+ case 108: // 'declare'
+ shift(108); // 'declare'
+ break;
+ case 109: // 'default'
+ shift(109); // 'default'
+ break;
+ case 110: // 'delete'
+ shift(110); // 'delete'
+ break;
+ case 111: // 'descendant'
+ shift(111); // 'descendant'
+ break;
+ case 112: // 'descendant-or-self'
+ shift(112); // 'descendant-or-self'
+ break;
+ case 113: // 'descending'
+ shift(113); // 'descending'
+ break;
+ case 118: // 'div'
+ shift(118); // 'div'
+ break;
+ case 119: // 'document'
+ shift(119); // 'document'
+ break;
+ case 122: // 'else'
+ shift(122); // 'else'
+ break;
+ case 123: // 'empty'
+ shift(123); // 'empty'
+ break;
+ case 126: // 'end'
+ shift(126); // 'end'
+ break;
+ case 128: // 'eq'
+ shift(128); // 'eq'
+ break;
+ case 129: // 'every'
+ shift(129); // 'every'
+ break;
+ case 131: // 'except'
+ shift(131); // 'except'
+ break;
+ case 134: // 'first'
+ shift(134); // 'first'
+ break;
+ case 135: // 'following'
+ shift(135); // 'following'
+ break;
+ case 136: // 'following-sibling'
+ shift(136); // 'following-sibling'
+ break;
+ case 137: // 'for'
+ shift(137); // 'for'
+ break;
+ case 146: // 'ge'
+ shift(146); // 'ge'
+ break;
+ case 148: // 'group'
+ shift(148); // 'group'
+ break;
+ case 150: // 'gt'
+ shift(150); // 'gt'
+ break;
+ case 151: // 'idiv'
+ shift(151); // 'idiv'
+ break;
+ case 153: // 'import'
+ shift(153); // 'import'
+ break;
+ case 159: // 'insert'
+ shift(159); // 'insert'
+ break;
+ case 160: // 'instance'
+ shift(160); // 'instance'
+ break;
+ case 162: // 'intersect'
+ shift(162); // 'intersect'
+ break;
+ case 163: // 'into'
+ shift(163); // 'into'
+ break;
+ case 164: // 'is'
+ shift(164); // 'is'
+ break;
+ case 170: // 'last'
+ shift(170); // 'last'
+ break;
+ case 172: // 'le'
+ shift(172); // 'le'
+ break;
+ case 174: // 'let'
+ shift(174); // 'let'
+ break;
+ case 178: // 'lt'
+ shift(178); // 'lt'
+ break;
+ case 180: // 'mod'
+ shift(180); // 'mod'
+ break;
+ case 181: // 'modify'
+ shift(181); // 'modify'
+ break;
+ case 182: // 'module'
+ shift(182); // 'module'
+ break;
+ case 184: // 'namespace'
+ shift(184); // 'namespace'
+ break;
+ case 186: // 'ne'
+ shift(186); // 'ne'
+ break;
+ case 198: // 'only'
+ shift(198); // 'only'
+ break;
+ case 200: // 'or'
+ shift(200); // 'or'
+ break;
+ case 201: // 'order'
+ shift(201); // 'order'
+ break;
+ case 202: // 'ordered'
+ shift(202); // 'ordered'
+ break;
+ case 206: // 'parent'
+ shift(206); // 'parent'
+ break;
+ case 212: // 'preceding'
+ shift(212); // 'preceding'
+ break;
+ case 213: // 'preceding-sibling'
+ shift(213); // 'preceding-sibling'
+ break;
+ case 218: // 'rename'
+ shift(218); // 'rename'
+ break;
+ case 219: // 'replace'
+ shift(219); // 'replace'
+ break;
+ case 220: // 'return'
+ shift(220); // 'return'
+ break;
+ case 224: // 'satisfies'
+ shift(224); // 'satisfies'
+ break;
+ case 229: // 'self'
+ shift(229); // 'self'
+ break;
+ case 235: // 'some'
+ shift(235); // 'some'
+ break;
+ case 236: // 'stable'
+ shift(236); // 'stable'
+ break;
+ case 237: // 'start'
+ shift(237); // 'start'
+ break;
+ case 248: // 'to'
+ shift(248); // 'to'
+ break;
+ case 249: // 'treat'
+ shift(249); // 'treat'
+ break;
+ case 250: // 'try'
+ shift(250); // 'try'
+ break;
+ case 254: // 'union'
+ shift(254); // 'union'
+ break;
+ case 256: // 'unordered'
+ shift(256); // 'unordered'
+ break;
+ case 260: // 'validate'
+ shift(260); // 'validate'
+ break;
+ case 266: // 'where'
+ shift(266); // 'where'
+ break;
+ case 270: // 'with'
+ shift(270); // 'with'
+ break;
+ case 274: // 'xquery'
+ shift(274); // 'xquery'
+ break;
+ case 72: // 'allowing'
+ shift(72); // 'allowing'
+ break;
+ case 81: // 'at'
+ shift(81); // 'at'
+ break;
+ case 83: // 'base-uri'
+ shift(83); // 'base-uri'
+ break;
+ case 85: // 'boundary-space'
+ shift(85); // 'boundary-space'
+ break;
+ case 86: // 'break'
+ shift(86); // 'break'
+ break;
+ case 91: // 'catch'
+ shift(91); // 'catch'
+ break;
+ case 98: // 'construction'
+ shift(98); // 'construction'
+ break;
+ case 101: // 'context'
+ shift(101); // 'context'
+ break;
+ case 102: // 'continue'
+ shift(102); // 'continue'
+ break;
+ case 104: // 'copy-namespaces'
+ shift(104); // 'copy-namespaces'
+ break;
+ case 106: // 'decimal-format'
+ shift(106); // 'decimal-format'
+ break;
+ case 125: // 'encoding'
+ shift(125); // 'encoding'
+ break;
+ case 132: // 'exit'
+ shift(132); // 'exit'
+ break;
+ case 133: // 'external'
+ shift(133); // 'external'
+ break;
+ case 141: // 'ft-option'
+ shift(141); // 'ft-option'
+ break;
+ case 154: // 'in'
+ shift(154); // 'in'
+ break;
+ case 155: // 'index'
+ shift(155); // 'index'
+ break;
+ case 161: // 'integrity'
+ shift(161); // 'integrity'
+ break;
+ case 171: // 'lax'
+ shift(171); // 'lax'
+ break;
+ case 192: // 'nodes'
+ shift(192); // 'nodes'
+ break;
+ case 199: // 'option'
+ shift(199); // 'option'
+ break;
+ case 203: // 'ordering'
+ shift(203); // 'ordering'
+ break;
+ case 222: // 'revalidation'
+ shift(222); // 'revalidation'
+ break;
+ case 225: // 'schema'
+ shift(225); // 'schema'
+ break;
+ case 228: // 'score'
+ shift(228); // 'score'
+ break;
+ case 234: // 'sliding'
+ shift(234); // 'sliding'
+ break;
+ case 240: // 'strict'
+ shift(240); // 'strict'
+ break;
+ case 251: // 'tumbling'
+ shift(251); // 'tumbling'
+ break;
+ case 252: // 'type'
+ shift(252); // 'type'
+ break;
+ case 257: // 'updating'
+ shift(257); // 'updating'
+ break;
+ case 261: // 'value'
+ shift(261); // 'value'
+ break;
+ case 262: // 'variable'
+ shift(262); // 'variable'
+ break;
+ case 263: // 'version'
+ shift(263); // 'version'
+ break;
+ case 267: // 'while'
+ shift(267); // 'while'
+ break;
+ case 97: // 'constraint'
+ shift(97); // 'constraint'
+ break;
+ case 176: // 'loop'
+ shift(176); // 'loop'
+ break;
+ case 221: // 'returning'
+ shift(221); // 'returning'
+ break;
+ case 77: // 'append'
+ shift(77); // 'append'
+ break;
+ case 166: // 'json'
+ shift(166); // 'json'
+ break;
+ default:
+ shift(194); // 'object'
+ }
+ eventHandler.endNonterminal("FunctionName", e0);
+ }
+
+ function try_FunctionName()
+ {
+ switch (l1)
+ {
+ case 6: // EQName^Token
+ shiftT(6); // EQName^Token
+ break;
+ case 70: // 'after'
+ shiftT(70); // 'after'
+ break;
+ case 73: // 'ancestor'
+ shiftT(73); // 'ancestor'
+ break;
+ case 74: // 'ancestor-or-self'
+ shiftT(74); // 'ancestor-or-self'
+ break;
+ case 75: // 'and'
+ shiftT(75); // 'and'
+ break;
+ case 79: // 'as'
+ shiftT(79); // 'as'
+ break;
+ case 80: // 'ascending'
+ shiftT(80); // 'ascending'
+ break;
+ case 84: // 'before'
+ shiftT(84); // 'before'
+ break;
+ case 88: // 'case'
+ shiftT(88); // 'case'
+ break;
+ case 89: // 'cast'
+ shiftT(89); // 'cast'
+ break;
+ case 90: // 'castable'
+ shiftT(90); // 'castable'
+ break;
+ case 93: // 'child'
+ shiftT(93); // 'child'
+ break;
+ case 94: // 'collation'
+ shiftT(94); // 'collation'
+ break;
+ case 103: // 'copy'
+ shiftT(103); // 'copy'
+ break;
+ case 105: // 'count'
+ shiftT(105); // 'count'
+ break;
+ case 108: // 'declare'
+ shiftT(108); // 'declare'
+ break;
+ case 109: // 'default'
+ shiftT(109); // 'default'
+ break;
+ case 110: // 'delete'
+ shiftT(110); // 'delete'
+ break;
+ case 111: // 'descendant'
+ shiftT(111); // 'descendant'
+ break;
+ case 112: // 'descendant-or-self'
+ shiftT(112); // 'descendant-or-self'
+ break;
+ case 113: // 'descending'
+ shiftT(113); // 'descending'
+ break;
+ case 118: // 'div'
+ shiftT(118); // 'div'
+ break;
+ case 119: // 'document'
+ shiftT(119); // 'document'
+ break;
+ case 122: // 'else'
+ shiftT(122); // 'else'
+ break;
+ case 123: // 'empty'
+ shiftT(123); // 'empty'
+ break;
+ case 126: // 'end'
+ shiftT(126); // 'end'
+ break;
+ case 128: // 'eq'
+ shiftT(128); // 'eq'
+ break;
+ case 129: // 'every'
+ shiftT(129); // 'every'
+ break;
+ case 131: // 'except'
+ shiftT(131); // 'except'
+ break;
+ case 134: // 'first'
+ shiftT(134); // 'first'
+ break;
+ case 135: // 'following'
+ shiftT(135); // 'following'
+ break;
+ case 136: // 'following-sibling'
+ shiftT(136); // 'following-sibling'
+ break;
+ case 137: // 'for'
+ shiftT(137); // 'for'
+ break;
+ case 146: // 'ge'
+ shiftT(146); // 'ge'
+ break;
+ case 148: // 'group'
+ shiftT(148); // 'group'
+ break;
+ case 150: // 'gt'
+ shiftT(150); // 'gt'
+ break;
+ case 151: // 'idiv'
+ shiftT(151); // 'idiv'
+ break;
+ case 153: // 'import'
+ shiftT(153); // 'import'
+ break;
+ case 159: // 'insert'
+ shiftT(159); // 'insert'
+ break;
+ case 160: // 'instance'
+ shiftT(160); // 'instance'
+ break;
+ case 162: // 'intersect'
+ shiftT(162); // 'intersect'
+ break;
+ case 163: // 'into'
+ shiftT(163); // 'into'
+ break;
+ case 164: // 'is'
+ shiftT(164); // 'is'
+ break;
+ case 170: // 'last'
+ shiftT(170); // 'last'
+ break;
+ case 172: // 'le'
+ shiftT(172); // 'le'
+ break;
+ case 174: // 'let'
+ shiftT(174); // 'let'
+ break;
+ case 178: // 'lt'
+ shiftT(178); // 'lt'
+ break;
+ case 180: // 'mod'
+ shiftT(180); // 'mod'
+ break;
+ case 181: // 'modify'
+ shiftT(181); // 'modify'
+ break;
+ case 182: // 'module'
+ shiftT(182); // 'module'
+ break;
+ case 184: // 'namespace'
+ shiftT(184); // 'namespace'
+ break;
+ case 186: // 'ne'
+ shiftT(186); // 'ne'
+ break;
+ case 198: // 'only'
+ shiftT(198); // 'only'
+ break;
+ case 200: // 'or'
+ shiftT(200); // 'or'
+ break;
+ case 201: // 'order'
+ shiftT(201); // 'order'
+ break;
+ case 202: // 'ordered'
+ shiftT(202); // 'ordered'
+ break;
+ case 206: // 'parent'
+ shiftT(206); // 'parent'
+ break;
+ case 212: // 'preceding'
+ shiftT(212); // 'preceding'
+ break;
+ case 213: // 'preceding-sibling'
+ shiftT(213); // 'preceding-sibling'
+ break;
+ case 218: // 'rename'
+ shiftT(218); // 'rename'
+ break;
+ case 219: // 'replace'
+ shiftT(219); // 'replace'
+ break;
+ case 220: // 'return'
+ shiftT(220); // 'return'
+ break;
+ case 224: // 'satisfies'
+ shiftT(224); // 'satisfies'
+ break;
+ case 229: // 'self'
+ shiftT(229); // 'self'
+ break;
+ case 235: // 'some'
+ shiftT(235); // 'some'
+ break;
+ case 236: // 'stable'
+ shiftT(236); // 'stable'
+ break;
+ case 237: // 'start'
+ shiftT(237); // 'start'
+ break;
+ case 248: // 'to'
+ shiftT(248); // 'to'
+ break;
+ case 249: // 'treat'
+ shiftT(249); // 'treat'
+ break;
+ case 250: // 'try'
+ shiftT(250); // 'try'
+ break;
+ case 254: // 'union'
+ shiftT(254); // 'union'
+ break;
+ case 256: // 'unordered'
+ shiftT(256); // 'unordered'
+ break;
+ case 260: // 'validate'
+ shiftT(260); // 'validate'
+ break;
+ case 266: // 'where'
+ shiftT(266); // 'where'
+ break;
+ case 270: // 'with'
+ shiftT(270); // 'with'
+ break;
+ case 274: // 'xquery'
+ shiftT(274); // 'xquery'
+ break;
+ case 72: // 'allowing'
+ shiftT(72); // 'allowing'
+ break;
+ case 81: // 'at'
+ shiftT(81); // 'at'
+ break;
+ case 83: // 'base-uri'
+ shiftT(83); // 'base-uri'
+ break;
+ case 85: // 'boundary-space'
+ shiftT(85); // 'boundary-space'
+ break;
+ case 86: // 'break'
+ shiftT(86); // 'break'
+ break;
+ case 91: // 'catch'
+ shiftT(91); // 'catch'
+ break;
+ case 98: // 'construction'
+ shiftT(98); // 'construction'
+ break;
+ case 101: // 'context'
+ shiftT(101); // 'context'
+ break;
+ case 102: // 'continue'
+ shiftT(102); // 'continue'
+ break;
+ case 104: // 'copy-namespaces'
+ shiftT(104); // 'copy-namespaces'
+ break;
+ case 106: // 'decimal-format'
+ shiftT(106); // 'decimal-format'
+ break;
+ case 125: // 'encoding'
+ shiftT(125); // 'encoding'
+ break;
+ case 132: // 'exit'
+ shiftT(132); // 'exit'
+ break;
+ case 133: // 'external'
+ shiftT(133); // 'external'
+ break;
+ case 141: // 'ft-option'
+ shiftT(141); // 'ft-option'
+ break;
+ case 154: // 'in'
+ shiftT(154); // 'in'
+ break;
+ case 155: // 'index'
+ shiftT(155); // 'index'
+ break;
+ case 161: // 'integrity'
+ shiftT(161); // 'integrity'
+ break;
+ case 171: // 'lax'
+ shiftT(171); // 'lax'
+ break;
+ case 192: // 'nodes'
+ shiftT(192); // 'nodes'
+ break;
+ case 199: // 'option'
+ shiftT(199); // 'option'
+ break;
+ case 203: // 'ordering'
+ shiftT(203); // 'ordering'
+ break;
+ case 222: // 'revalidation'
+ shiftT(222); // 'revalidation'
+ break;
+ case 225: // 'schema'
+ shiftT(225); // 'schema'
+ break;
+ case 228: // 'score'
+ shiftT(228); // 'score'
+ break;
+ case 234: // 'sliding'
+ shiftT(234); // 'sliding'
+ break;
+ case 240: // 'strict'
+ shiftT(240); // 'strict'
+ break;
+ case 251: // 'tumbling'
+ shiftT(251); // 'tumbling'
+ break;
+ case 252: // 'type'
+ shiftT(252); // 'type'
+ break;
+ case 257: // 'updating'
+ shiftT(257); // 'updating'
+ break;
+ case 261: // 'value'
+ shiftT(261); // 'value'
+ break;
+ case 262: // 'variable'
+ shiftT(262); // 'variable'
+ break;
+ case 263: // 'version'
+ shiftT(263); // 'version'
+ break;
+ case 267: // 'while'
+ shiftT(267); // 'while'
+ break;
+ case 97: // 'constraint'
+ shiftT(97); // 'constraint'
+ break;
+ case 176: // 'loop'
+ shiftT(176); // 'loop'
+ break;
+ case 221: // 'returning'
+ shiftT(221); // 'returning'
+ break;
+ case 77: // 'append'
+ shiftT(77); // 'append'
+ break;
+ case 166: // 'json'
+ shiftT(166); // 'json'
+ break;
+ default:
+ shiftT(194); // 'object'
+ }
+ }
+
+ function parse_NCName()
+ {
+ eventHandler.startNonterminal("NCName", e0);
+ switch (l1)
+ {
+ case 19: // NCName^Token
+ shift(19); // NCName^Token
+ break;
+ case 70: // 'after'
+ shift(70); // 'after'
+ break;
+ case 75: // 'and'
+ shift(75); // 'and'
+ break;
+ case 79: // 'as'
+ shift(79); // 'as'
+ break;
+ case 80: // 'ascending'
+ shift(80); // 'ascending'
+ break;
+ case 84: // 'before'
+ shift(84); // 'before'
+ break;
+ case 88: // 'case'
+ shift(88); // 'case'
+ break;
+ case 89: // 'cast'
+ shift(89); // 'cast'
+ break;
+ case 90: // 'castable'
+ shift(90); // 'castable'
+ break;
+ case 94: // 'collation'
+ shift(94); // 'collation'
+ break;
+ case 105: // 'count'
+ shift(105); // 'count'
+ break;
+ case 109: // 'default'
+ shift(109); // 'default'
+ break;
+ case 113: // 'descending'
+ shift(113); // 'descending'
+ break;
+ case 118: // 'div'
+ shift(118); // 'div'
+ break;
+ case 122: // 'else'
+ shift(122); // 'else'
+ break;
+ case 123: // 'empty'
+ shift(123); // 'empty'
+ break;
+ case 126: // 'end'
+ shift(126); // 'end'
+ break;
+ case 128: // 'eq'
+ shift(128); // 'eq'
+ break;
+ case 131: // 'except'
+ shift(131); // 'except'
+ break;
+ case 137: // 'for'
+ shift(137); // 'for'
+ break;
+ case 146: // 'ge'
+ shift(146); // 'ge'
+ break;
+ case 148: // 'group'
+ shift(148); // 'group'
+ break;
+ case 150: // 'gt'
+ shift(150); // 'gt'
+ break;
+ case 151: // 'idiv'
+ shift(151); // 'idiv'
+ break;
+ case 160: // 'instance'
+ shift(160); // 'instance'
+ break;
+ case 162: // 'intersect'
+ shift(162); // 'intersect'
+ break;
+ case 163: // 'into'
+ shift(163); // 'into'
+ break;
+ case 164: // 'is'
+ shift(164); // 'is'
+ break;
+ case 172: // 'le'
+ shift(172); // 'le'
+ break;
+ case 174: // 'let'
+ shift(174); // 'let'
+ break;
+ case 178: // 'lt'
+ shift(178); // 'lt'
+ break;
+ case 180: // 'mod'
+ shift(180); // 'mod'
+ break;
+ case 181: // 'modify'
+ shift(181); // 'modify'
+ break;
+ case 186: // 'ne'
+ shift(186); // 'ne'
+ break;
+ case 198: // 'only'
+ shift(198); // 'only'
+ break;
+ case 200: // 'or'
+ shift(200); // 'or'
+ break;
+ case 201: // 'order'
+ shift(201); // 'order'
+ break;
+ case 220: // 'return'
+ shift(220); // 'return'
+ break;
+ case 224: // 'satisfies'
+ shift(224); // 'satisfies'
+ break;
+ case 236: // 'stable'
+ shift(236); // 'stable'
+ break;
+ case 237: // 'start'
+ shift(237); // 'start'
+ break;
+ case 248: // 'to'
+ shift(248); // 'to'
+ break;
+ case 249: // 'treat'
+ shift(249); // 'treat'
+ break;
+ case 254: // 'union'
+ shift(254); // 'union'
+ break;
+ case 266: // 'where'
+ shift(266); // 'where'
+ break;
+ case 270: // 'with'
+ shift(270); // 'with'
+ break;
+ case 73: // 'ancestor'
+ shift(73); // 'ancestor'
+ break;
+ case 74: // 'ancestor-or-self'
+ shift(74); // 'ancestor-or-self'
+ break;
+ case 82: // 'attribute'
+ shift(82); // 'attribute'
+ break;
+ case 93: // 'child'
+ shift(93); // 'child'
+ break;
+ case 96: // 'comment'
+ shift(96); // 'comment'
+ break;
+ case 103: // 'copy'
+ shift(103); // 'copy'
+ break;
+ case 108: // 'declare'
+ shift(108); // 'declare'
+ break;
+ case 110: // 'delete'
+ shift(110); // 'delete'
+ break;
+ case 111: // 'descendant'
+ shift(111); // 'descendant'
+ break;
+ case 112: // 'descendant-or-self'
+ shift(112); // 'descendant-or-self'
+ break;
+ case 119: // 'document'
+ shift(119); // 'document'
+ break;
+ case 120: // 'document-node'
+ shift(120); // 'document-node'
+ break;
+ case 121: // 'element'
+ shift(121); // 'element'
+ break;
+ case 124: // 'empty-sequence'
+ shift(124); // 'empty-sequence'
+ break;
+ case 129: // 'every'
+ shift(129); // 'every'
+ break;
+ case 134: // 'first'
+ shift(134); // 'first'
+ break;
+ case 135: // 'following'
+ shift(135); // 'following'
+ break;
+ case 136: // 'following-sibling'
+ shift(136); // 'following-sibling'
+ break;
+ case 145: // 'function'
+ shift(145); // 'function'
+ break;
+ case 152: // 'if'
+ shift(152); // 'if'
+ break;
+ case 153: // 'import'
+ shift(153); // 'import'
+ break;
+ case 159: // 'insert'
+ shift(159); // 'insert'
+ break;
+ case 165: // 'item'
+ shift(165); // 'item'
+ break;
+ case 170: // 'last'
+ shift(170); // 'last'
+ break;
+ case 182: // 'module'
+ shift(182); // 'module'
+ break;
+ case 184: // 'namespace'
+ shift(184); // 'namespace'
+ break;
+ case 185: // 'namespace-node'
+ shift(185); // 'namespace-node'
+ break;
+ case 191: // 'node'
+ shift(191); // 'node'
+ break;
+ case 202: // 'ordered'
+ shift(202); // 'ordered'
+ break;
+ case 206: // 'parent'
+ shift(206); // 'parent'
+ break;
+ case 212: // 'preceding'
+ shift(212); // 'preceding'
+ break;
+ case 213: // 'preceding-sibling'
+ shift(213); // 'preceding-sibling'
+ break;
+ case 216: // 'processing-instruction'
+ shift(216); // 'processing-instruction'
+ break;
+ case 218: // 'rename'
+ shift(218); // 'rename'
+ break;
+ case 219: // 'replace'
+ shift(219); // 'replace'
+ break;
+ case 226: // 'schema-attribute'
+ shift(226); // 'schema-attribute'
+ break;
+ case 227: // 'schema-element'
+ shift(227); // 'schema-element'
+ break;
+ case 229: // 'self'
+ shift(229); // 'self'
+ break;
+ case 235: // 'some'
+ shift(235); // 'some'
+ break;
+ case 243: // 'switch'
+ shift(243); // 'switch'
+ break;
+ case 244: // 'text'
+ shift(244); // 'text'
+ break;
+ case 250: // 'try'
+ shift(250); // 'try'
+ break;
+ case 253: // 'typeswitch'
+ shift(253); // 'typeswitch'
+ break;
+ case 256: // 'unordered'
+ shift(256); // 'unordered'
+ break;
+ case 260: // 'validate'
+ shift(260); // 'validate'
+ break;
+ case 262: // 'variable'
+ shift(262); // 'variable'
+ break;
+ case 274: // 'xquery'
+ shift(274); // 'xquery'
+ break;
+ case 72: // 'allowing'
+ shift(72); // 'allowing'
+ break;
+ case 81: // 'at'
+ shift(81); // 'at'
+ break;
+ case 83: // 'base-uri'
+ shift(83); // 'base-uri'
+ break;
+ case 85: // 'boundary-space'
+ shift(85); // 'boundary-space'
+ break;
+ case 86: // 'break'
+ shift(86); // 'break'
+ break;
+ case 91: // 'catch'
+ shift(91); // 'catch'
+ break;
+ case 98: // 'construction'
+ shift(98); // 'construction'
+ break;
+ case 101: // 'context'
+ shift(101); // 'context'
+ break;
+ case 102: // 'continue'
+ shift(102); // 'continue'
+ break;
+ case 104: // 'copy-namespaces'
+ shift(104); // 'copy-namespaces'
+ break;
+ case 106: // 'decimal-format'
+ shift(106); // 'decimal-format'
+ break;
+ case 125: // 'encoding'
+ shift(125); // 'encoding'
+ break;
+ case 132: // 'exit'
+ shift(132); // 'exit'
+ break;
+ case 133: // 'external'
+ shift(133); // 'external'
+ break;
+ case 141: // 'ft-option'
+ shift(141); // 'ft-option'
+ break;
+ case 154: // 'in'
+ shift(154); // 'in'
+ break;
+ case 155: // 'index'
+ shift(155); // 'index'
+ break;
+ case 161: // 'integrity'
+ shift(161); // 'integrity'
+ break;
+ case 171: // 'lax'
+ shift(171); // 'lax'
+ break;
+ case 192: // 'nodes'
+ shift(192); // 'nodes'
+ break;
+ case 199: // 'option'
+ shift(199); // 'option'
+ break;
+ case 203: // 'ordering'
+ shift(203); // 'ordering'
+ break;
+ case 222: // 'revalidation'
+ shift(222); // 'revalidation'
+ break;
+ case 225: // 'schema'
+ shift(225); // 'schema'
+ break;
+ case 228: // 'score'
+ shift(228); // 'score'
+ break;
+ case 234: // 'sliding'
+ shift(234); // 'sliding'
+ break;
+ case 240: // 'strict'
+ shift(240); // 'strict'
+ break;
+ case 251: // 'tumbling'
+ shift(251); // 'tumbling'
+ break;
+ case 252: // 'type'
+ shift(252); // 'type'
+ break;
+ case 257: // 'updating'
+ shift(257); // 'updating'
+ break;
+ case 261: // 'value'
+ shift(261); // 'value'
+ break;
+ case 263: // 'version'
+ shift(263); // 'version'
+ break;
+ case 267: // 'while'
+ shift(267); // 'while'
+ break;
+ case 97: // 'constraint'
+ shift(97); // 'constraint'
+ break;
+ case 176: // 'loop'
+ shift(176); // 'loop'
+ break;
+ case 221: // 'returning'
+ shift(221); // 'returning'
+ break;
+ case 77: // 'append'
+ shift(77); // 'append'
+ break;
+ case 166: // 'json'
+ shift(166); // 'json'
+ break;
+ default:
+ shift(194); // 'object'
+ }
+ eventHandler.endNonterminal("NCName", e0);
+ }
+
+ function try_NCName()
+ {
+ switch (l1)
+ {
+ case 19: // NCName^Token
+ shiftT(19); // NCName^Token
+ break;
+ case 70: // 'after'
+ shiftT(70); // 'after'
+ break;
+ case 75: // 'and'
+ shiftT(75); // 'and'
+ break;
+ case 79: // 'as'
+ shiftT(79); // 'as'
+ break;
+ case 80: // 'ascending'
+ shiftT(80); // 'ascending'
+ break;
+ case 84: // 'before'
+ shiftT(84); // 'before'
+ break;
+ case 88: // 'case'
+ shiftT(88); // 'case'
+ break;
+ case 89: // 'cast'
+ shiftT(89); // 'cast'
+ break;
+ case 90: // 'castable'
+ shiftT(90); // 'castable'
+ break;
+ case 94: // 'collation'
+ shiftT(94); // 'collation'
+ break;
+ case 105: // 'count'
+ shiftT(105); // 'count'
+ break;
+ case 109: // 'default'
+ shiftT(109); // 'default'
+ break;
+ case 113: // 'descending'
+ shiftT(113); // 'descending'
+ break;
+ case 118: // 'div'
+ shiftT(118); // 'div'
+ break;
+ case 122: // 'else'
+ shiftT(122); // 'else'
+ break;
+ case 123: // 'empty'
+ shiftT(123); // 'empty'
+ break;
+ case 126: // 'end'
+ shiftT(126); // 'end'
+ break;
+ case 128: // 'eq'
+ shiftT(128); // 'eq'
+ break;
+ case 131: // 'except'
+ shiftT(131); // 'except'
+ break;
+ case 137: // 'for'
+ shiftT(137); // 'for'
+ break;
+ case 146: // 'ge'
+ shiftT(146); // 'ge'
+ break;
+ case 148: // 'group'
+ shiftT(148); // 'group'
+ break;
+ case 150: // 'gt'
+ shiftT(150); // 'gt'
+ break;
+ case 151: // 'idiv'
+ shiftT(151); // 'idiv'
+ break;
+ case 160: // 'instance'
+ shiftT(160); // 'instance'
+ break;
+ case 162: // 'intersect'
+ shiftT(162); // 'intersect'
+ break;
+ case 163: // 'into'
+ shiftT(163); // 'into'
+ break;
+ case 164: // 'is'
+ shiftT(164); // 'is'
+ break;
+ case 172: // 'le'
+ shiftT(172); // 'le'
+ break;
+ case 174: // 'let'
+ shiftT(174); // 'let'
+ break;
+ case 178: // 'lt'
+ shiftT(178); // 'lt'
+ break;
+ case 180: // 'mod'
+ shiftT(180); // 'mod'
+ break;
+ case 181: // 'modify'
+ shiftT(181); // 'modify'
+ break;
+ case 186: // 'ne'
+ shiftT(186); // 'ne'
+ break;
+ case 198: // 'only'
+ shiftT(198); // 'only'
+ break;
+ case 200: // 'or'
+ shiftT(200); // 'or'
+ break;
+ case 201: // 'order'
+ shiftT(201); // 'order'
+ break;
+ case 220: // 'return'
+ shiftT(220); // 'return'
+ break;
+ case 224: // 'satisfies'
+ shiftT(224); // 'satisfies'
+ break;
+ case 236: // 'stable'
+ shiftT(236); // 'stable'
+ break;
+ case 237: // 'start'
+ shiftT(237); // 'start'
+ break;
+ case 248: // 'to'
+ shiftT(248); // 'to'
+ break;
+ case 249: // 'treat'
+ shiftT(249); // 'treat'
+ break;
+ case 254: // 'union'
+ shiftT(254); // 'union'
+ break;
+ case 266: // 'where'
+ shiftT(266); // 'where'
+ break;
+ case 270: // 'with'
+ shiftT(270); // 'with'
+ break;
+ case 73: // 'ancestor'
+ shiftT(73); // 'ancestor'
+ break;
+ case 74: // 'ancestor-or-self'
+ shiftT(74); // 'ancestor-or-self'
+ break;
+ case 82: // 'attribute'
+ shiftT(82); // 'attribute'
+ break;
+ case 93: // 'child'
+ shiftT(93); // 'child'
+ break;
+ case 96: // 'comment'
+ shiftT(96); // 'comment'
+ break;
+ case 103: // 'copy'
+ shiftT(103); // 'copy'
+ break;
+ case 108: // 'declare'
+ shiftT(108); // 'declare'
+ break;
+ case 110: // 'delete'
+ shiftT(110); // 'delete'
+ break;
+ case 111: // 'descendant'
+ shiftT(111); // 'descendant'
+ break;
+ case 112: // 'descendant-or-self'
+ shiftT(112); // 'descendant-or-self'
+ break;
+ case 119: // 'document'
+ shiftT(119); // 'document'
+ break;
+ case 120: // 'document-node'
+ shiftT(120); // 'document-node'
+ break;
+ case 121: // 'element'
+ shiftT(121); // 'element'
+ break;
+ case 124: // 'empty-sequence'
+ shiftT(124); // 'empty-sequence'
+ break;
+ case 129: // 'every'
+ shiftT(129); // 'every'
+ break;
+ case 134: // 'first'
+ shiftT(134); // 'first'
+ break;
+ case 135: // 'following'
+ shiftT(135); // 'following'
+ break;
+ case 136: // 'following-sibling'
+ shiftT(136); // 'following-sibling'
+ break;
+ case 145: // 'function'
+ shiftT(145); // 'function'
+ break;
+ case 152: // 'if'
+ shiftT(152); // 'if'
+ break;
+ case 153: // 'import'
+ shiftT(153); // 'import'
+ break;
+ case 159: // 'insert'
+ shiftT(159); // 'insert'
+ break;
+ case 165: // 'item'
+ shiftT(165); // 'item'
+ break;
+ case 170: // 'last'
+ shiftT(170); // 'last'
+ break;
+ case 182: // 'module'
+ shiftT(182); // 'module'
+ break;
+ case 184: // 'namespace'
+ shiftT(184); // 'namespace'
+ break;
+ case 185: // 'namespace-node'
+ shiftT(185); // 'namespace-node'
+ break;
+ case 191: // 'node'
+ shiftT(191); // 'node'
+ break;
+ case 202: // 'ordered'
+ shiftT(202); // 'ordered'
+ break;
+ case 206: // 'parent'
+ shiftT(206); // 'parent'
+ break;
+ case 212: // 'preceding'
+ shiftT(212); // 'preceding'
+ break;
+ case 213: // 'preceding-sibling'
+ shiftT(213); // 'preceding-sibling'
+ break;
+ case 216: // 'processing-instruction'
+ shiftT(216); // 'processing-instruction'
+ break;
+ case 218: // 'rename'
+ shiftT(218); // 'rename'
+ break;
+ case 219: // 'replace'
+ shiftT(219); // 'replace'
+ break;
+ case 226: // 'schema-attribute'
+ shiftT(226); // 'schema-attribute'
+ break;
+ case 227: // 'schema-element'
+ shiftT(227); // 'schema-element'
+ break;
+ case 229: // 'self'
+ shiftT(229); // 'self'
+ break;
+ case 235: // 'some'
+ shiftT(235); // 'some'
+ break;
+ case 243: // 'switch'
+ shiftT(243); // 'switch'
+ break;
+ case 244: // 'text'
+ shiftT(244); // 'text'
+ break;
+ case 250: // 'try'
+ shiftT(250); // 'try'
+ break;
+ case 253: // 'typeswitch'
+ shiftT(253); // 'typeswitch'
+ break;
+ case 256: // 'unordered'
+ shiftT(256); // 'unordered'
+ break;
+ case 260: // 'validate'
+ shiftT(260); // 'validate'
+ break;
+ case 262: // 'variable'
+ shiftT(262); // 'variable'
+ break;
+ case 274: // 'xquery'
+ shiftT(274); // 'xquery'
+ break;
+ case 72: // 'allowing'
+ shiftT(72); // 'allowing'
+ break;
+ case 81: // 'at'
+ shiftT(81); // 'at'
+ break;
+ case 83: // 'base-uri'
+ shiftT(83); // 'base-uri'
+ break;
+ case 85: // 'boundary-space'
+ shiftT(85); // 'boundary-space'
+ break;
+ case 86: // 'break'
+ shiftT(86); // 'break'
+ break;
+ case 91: // 'catch'
+ shiftT(91); // 'catch'
+ break;
+ case 98: // 'construction'
+ shiftT(98); // 'construction'
+ break;
+ case 101: // 'context'
+ shiftT(101); // 'context'
+ break;
+ case 102: // 'continue'
+ shiftT(102); // 'continue'
+ break;
+ case 104: // 'copy-namespaces'
+ shiftT(104); // 'copy-namespaces'
+ break;
+ case 106: // 'decimal-format'
+ shiftT(106); // 'decimal-format'
+ break;
+ case 125: // 'encoding'
+ shiftT(125); // 'encoding'
+ break;
+ case 132: // 'exit'
+ shiftT(132); // 'exit'
+ break;
+ case 133: // 'external'
+ shiftT(133); // 'external'
+ break;
+ case 141: // 'ft-option'
+ shiftT(141); // 'ft-option'
+ break;
+ case 154: // 'in'
+ shiftT(154); // 'in'
+ break;
+ case 155: // 'index'
+ shiftT(155); // 'index'
+ break;
+ case 161: // 'integrity'
+ shiftT(161); // 'integrity'
+ break;
+ case 171: // 'lax'
+ shiftT(171); // 'lax'
+ break;
+ case 192: // 'nodes'
+ shiftT(192); // 'nodes'
+ break;
+ case 199: // 'option'
+ shiftT(199); // 'option'
+ break;
+ case 203: // 'ordering'
+ shiftT(203); // 'ordering'
+ break;
+ case 222: // 'revalidation'
+ shiftT(222); // 'revalidation'
+ break;
+ case 225: // 'schema'
+ shiftT(225); // 'schema'
+ break;
+ case 228: // 'score'
+ shiftT(228); // 'score'
+ break;
+ case 234: // 'sliding'
+ shiftT(234); // 'sliding'
+ break;
+ case 240: // 'strict'
+ shiftT(240); // 'strict'
+ break;
+ case 251: // 'tumbling'
+ shiftT(251); // 'tumbling'
+ break;
+ case 252: // 'type'
+ shiftT(252); // 'type'
+ break;
+ case 257: // 'updating'
+ shiftT(257); // 'updating'
+ break;
+ case 261: // 'value'
+ shiftT(261); // 'value'
+ break;
+ case 263: // 'version'
+ shiftT(263); // 'version'
+ break;
+ case 267: // 'while'
+ shiftT(267); // 'while'
+ break;
+ case 97: // 'constraint'
+ shiftT(97); // 'constraint'
+ break;
+ case 176: // 'loop'
+ shiftT(176); // 'loop'
+ break;
+ case 221: // 'returning'
+ shiftT(221); // 'returning'
+ break;
+ case 77: // 'append'
+ shiftT(77); // 'append'
+ break;
+ case 166: // 'json'
+ shiftT(166); // 'json'
+ break;
+ default:
+ shiftT(194); // 'object'
+ }
+ }
+
+ function parse_MainModule()
+ {
+ eventHandler.startNonterminal("MainModule", e0);
+ parse_Prolog();
+ whitespace();
+ parse_Program();
+ eventHandler.endNonterminal("MainModule", e0);
+ }
+
+ function parse_Program()
+ {
+ eventHandler.startNonterminal("Program", e0);
+ parse_StatementsAndOptionalExpr();
+ eventHandler.endNonterminal("Program", e0);
+ }
+
+ function parse_Statements()
+ {
+ eventHandler.startNonterminal("Statements", e0);
+ for (;;)
+ {
+ lookahead1W(277); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 34: // '('
+ lookahead2W(268); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 35: // '(#'
+ lookahead2(251); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ break;
+ case 46: // '/'
+ lookahead2W(283); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 47: // '//'
+ lookahead2W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 54: // '<'
+ lookahead2(4); // QName
+ break;
+ case 55: // '<!--'
+ lookahead2(1); // DirCommentContents
+ break;
+ case 59: // '<?'
+ lookahead2(3); // PITarget
+ break;
+ case 66: // '@'
+ lookahead2W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 68: // '['
+ lookahead2W(271); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 77: // 'append'
+ lookahead2W(199); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 82: // 'attribute'
+ lookahead2W(280); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' |
+ break;
+ case 121: // 'element'
+ lookahead2W(279); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' |
+ break;
+ case 132: // 'exit'
+ lookahead2W(202); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 137: // 'for'
+ lookahead2W(207); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 174: // 'let'
+ lookahead2W(204); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 218: // 'rename'
+ lookahead2W(205); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 219: // 'replace'
+ lookahead2W(206); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 260: // 'validate'
+ lookahead2W(209); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 278: // '{|'
+ lookahead2W(272); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 5: // Wildcard
+ case 45: // '..'
+ lookahead2W(185); // S^WS | EOF | '!' | '!=' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 31: // '$'
+ case 32: // '%'
+ lookahead2W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 40: // '+'
+ case 42: // '-'
+ lookahead2W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 86: // 'break'
+ case 102: // 'continue'
+ lookahead2W(200); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 110: // 'delete'
+ case 159: // 'insert'
+ lookahead2W(208); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 184: // 'namespace'
+ case 216: // 'processing-instruction'
+ lookahead2W(267); // NCName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' |
+ break;
+ case 103: // 'copy'
+ case 129: // 'every'
+ case 235: // 'some'
+ case 262: // 'variable'
+ lookahead2W(196); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 44: // '.'
+ lookahead2W(191); // S^WS | EOF | '!' | '!=' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' | ';' |
+ break;
+ case 78: // 'array'
+ case 124: // 'empty-sequence'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 242: // 'structured-item'
+ lookahead2W(190); // S^WS | EOF | '!' | '!=' | '#' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' | ';' |
+ break;
+ case 96: // 'comment'
+ case 119: // 'document'
+ case 202: // 'ordered'
+ case 244: // 'text'
+ case 250: // 'try'
+ case 256: // 'unordered'
+ lookahead2W(203); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 93: // 'child'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ case 229: // 'self'
+ lookahead2W(197); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 6: // EQName^Token
+ case 70: // 'after'
+ case 72: // 'allowing'
+ case 75: // 'and'
+ case 79: // 'as'
+ case 80: // 'ascending'
+ case 81: // 'at'
+ case 83: // 'base-uri'
+ case 84: // 'before'
+ case 85: // 'boundary-space'
+ case 88: // 'case'
+ case 89: // 'cast'
+ case 90: // 'castable'
+ case 91: // 'catch'
+ case 94: // 'collation'
+ case 97: // 'constraint'
+ case 98: // 'construction'
+ case 101: // 'context'
+ case 104: // 'copy-namespaces'
+ case 105: // 'count'
+ case 106: // 'decimal-format'
+ case 108: // 'declare'
+ case 109: // 'default'
+ case 113: // 'descending'
+ case 118: // 'div'
+ case 120: // 'document-node'
+ case 122: // 'else'
+ case 123: // 'empty'
+ case 125: // 'encoding'
+ case 126: // 'end'
+ case 128: // 'eq'
+ case 131: // 'except'
+ case 133: // 'external'
+ case 134: // 'first'
+ case 141: // 'ft-option'
+ case 145: // 'function'
+ case 146: // 'ge'
+ case 148: // 'group'
+ case 150: // 'gt'
+ case 151: // 'idiv'
+ case 152: // 'if'
+ case 153: // 'import'
+ case 154: // 'in'
+ case 155: // 'index'
+ case 160: // 'instance'
+ case 161: // 'integrity'
+ case 162: // 'intersect'
+ case 163: // 'into'
+ case 164: // 'is'
+ case 166: // 'json'
+ case 170: // 'last'
+ case 171: // 'lax'
+ case 172: // 'le'
+ case 176: // 'loop'
+ case 178: // 'lt'
+ case 180: // 'mod'
+ case 181: // 'modify'
+ case 182: // 'module'
+ case 185: // 'namespace-node'
+ case 186: // 'ne'
+ case 191: // 'node'
+ case 192: // 'nodes'
+ case 194: // 'object'
+ case 198: // 'only'
+ case 199: // 'option'
+ case 200: // 'or'
+ case 201: // 'order'
+ case 203: // 'ordering'
+ case 220: // 'return'
+ case 221: // 'returning'
+ case 222: // 'revalidation'
+ case 224: // 'satisfies'
+ case 225: // 'schema'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 228: // 'score'
+ case 234: // 'sliding'
+ case 236: // 'stable'
+ case 237: // 'start'
+ case 240: // 'strict'
+ case 243: // 'switch'
+ case 248: // 'to'
+ case 249: // 'treat'
+ case 251: // 'tumbling'
+ case 252: // 'type'
+ case 253: // 'typeswitch'
+ case 254: // 'union'
+ case 257: // 'updating'
+ case 261: // 'value'
+ case 263: // 'version'
+ case 266: // 'where'
+ case 267: // 'while'
+ case 270: // 'with'
+ case 274: // 'xquery'
+ lookahead2W(194); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 53 // ';'
+ && lk != 282 // '}'
+ && lk != 12805 // Wildcard EOF
+ && lk != 12806 // EQName^Token EOF
+ && lk != 12808 // IntegerLiteral EOF
+ && lk != 12809 // DecimalLiteral EOF
+ && lk != 12810 // DoubleLiteral EOF
+ && lk != 12811 // StringLiteral EOF
+ && lk != 12844 // '.' EOF
+ && lk != 12845 // '..' EOF
+ && lk != 12846 // '/' EOF
+ && lk != 12870 // 'after' EOF
+ && lk != 12872 // 'allowing' EOF
+ && lk != 12873 // 'ancestor' EOF
+ && lk != 12874 // 'ancestor-or-self' EOF
+ && lk != 12875 // 'and' EOF
+ && lk != 12877 // 'append' EOF
+ && lk != 12878 // 'array' EOF
+ && lk != 12879 // 'as' EOF
+ && lk != 12880 // 'ascending' EOF
+ && lk != 12881 // 'at' EOF
+ && lk != 12882 // 'attribute' EOF
+ && lk != 12883 // 'base-uri' EOF
+ && lk != 12884 // 'before' EOF
+ && lk != 12885 // 'boundary-space' EOF
+ && lk != 12886 // 'break' EOF
+ && lk != 12888 // 'case' EOF
+ && lk != 12889 // 'cast' EOF
+ && lk != 12890 // 'castable' EOF
+ && lk != 12891 // 'catch' EOF
+ && lk != 12893 // 'child' EOF
+ && lk != 12894 // 'collation' EOF
+ && lk != 12896 // 'comment' EOF
+ && lk != 12897 // 'constraint' EOF
+ && lk != 12898 // 'construction' EOF
+ && lk != 12901 // 'context' EOF
+ && lk != 12902 // 'continue' EOF
+ && lk != 12903 // 'copy' EOF
+ && lk != 12904 // 'copy-namespaces' EOF
+ && lk != 12905 // 'count' EOF
+ && lk != 12906 // 'decimal-format' EOF
+ && lk != 12908 // 'declare' EOF
+ && lk != 12909 // 'default' EOF
+ && lk != 12910 // 'delete' EOF
+ && lk != 12911 // 'descendant' EOF
+ && lk != 12912 // 'descendant-or-self' EOF
+ && lk != 12913 // 'descending' EOF
+ && lk != 12918 // 'div' EOF
+ && lk != 12919 // 'document' EOF
+ && lk != 12920 // 'document-node' EOF
+ && lk != 12921 // 'element' EOF
+ && lk != 12922 // 'else' EOF
+ && lk != 12923 // 'empty' EOF
+ && lk != 12924 // 'empty-sequence' EOF
+ && lk != 12925 // 'encoding' EOF
+ && lk != 12926 // 'end' EOF
+ && lk != 12928 // 'eq' EOF
+ && lk != 12929 // 'every' EOF
+ && lk != 12931 // 'except' EOF
+ && lk != 12932 // 'exit' EOF
+ && lk != 12933 // 'external' EOF
+ && lk != 12934 // 'first' EOF
+ && lk != 12935 // 'following' EOF
+ && lk != 12936 // 'following-sibling' EOF
+ && lk != 12937 // 'for' EOF
+ && lk != 12941 // 'ft-option' EOF
+ && lk != 12945 // 'function' EOF
+ && lk != 12946 // 'ge' EOF
+ && lk != 12948 // 'group' EOF
+ && lk != 12950 // 'gt' EOF
+ && lk != 12951 // 'idiv' EOF
+ && lk != 12952 // 'if' EOF
+ && lk != 12953 // 'import' EOF
+ && lk != 12954 // 'in' EOF
+ && lk != 12955 // 'index' EOF
+ && lk != 12959 // 'insert' EOF
+ && lk != 12960 // 'instance' EOF
+ && lk != 12961 // 'integrity' EOF
+ && lk != 12962 // 'intersect' EOF
+ && lk != 12963 // 'into' EOF
+ && lk != 12964 // 'is' EOF
+ && lk != 12965 // 'item' EOF
+ && lk != 12966 // 'json' EOF
+ && lk != 12967 // 'json-item' EOF
+ && lk != 12970 // 'last' EOF
+ && lk != 12971 // 'lax' EOF
+ && lk != 12972 // 'le' EOF
+ && lk != 12974 // 'let' EOF
+ && lk != 12976 // 'loop' EOF
+ && lk != 12978 // 'lt' EOF
+ && lk != 12980 // 'mod' EOF
+ && lk != 12981 // 'modify' EOF
+ && lk != 12982 // 'module' EOF
+ && lk != 12984 // 'namespace' EOF
+ && lk != 12985 // 'namespace-node' EOF
+ && lk != 12986 // 'ne' EOF
+ && lk != 12991 // 'node' EOF
+ && lk != 12992 // 'nodes' EOF
+ && lk != 12994 // 'object' EOF
+ && lk != 12998 // 'only' EOF
+ && lk != 12999 // 'option' EOF
+ && lk != 13000 // 'or' EOF
+ && lk != 13001 // 'order' EOF
+ && lk != 13002 // 'ordered' EOF
+ && lk != 13003 // 'ordering' EOF
+ && lk != 13006 // 'parent' EOF
+ && lk != 13012 // 'preceding' EOF
+ && lk != 13013 // 'preceding-sibling' EOF
+ && lk != 13016 // 'processing-instruction' EOF
+ && lk != 13018 // 'rename' EOF
+ && lk != 13019 // 'replace' EOF
+ && lk != 13020 // 'return' EOF
+ && lk != 13021 // 'returning' EOF
+ && lk != 13022 // 'revalidation' EOF
+ && lk != 13024 // 'satisfies' EOF
+ && lk != 13025 // 'schema' EOF
+ && lk != 13026 // 'schema-attribute' EOF
+ && lk != 13027 // 'schema-element' EOF
+ && lk != 13028 // 'score' EOF
+ && lk != 13029 // 'self' EOF
+ && lk != 13034 // 'sliding' EOF
+ && lk != 13035 // 'some' EOF
+ && lk != 13036 // 'stable' EOF
+ && lk != 13037 // 'start' EOF
+ && lk != 13040 // 'strict' EOF
+ && lk != 13042 // 'structured-item' EOF
+ && lk != 13043 // 'switch' EOF
+ && lk != 13044 // 'text' EOF
+ && lk != 13048 // 'to' EOF
+ && lk != 13049 // 'treat' EOF
+ && lk != 13050 // 'try' EOF
+ && lk != 13051 // 'tumbling' EOF
+ && lk != 13052 // 'type' EOF
+ && lk != 13053 // 'typeswitch' EOF
+ && lk != 13054 // 'union' EOF
+ && lk != 13056 // 'unordered' EOF
+ && lk != 13057 // 'updating' EOF
+ && lk != 13060 // 'validate' EOF
+ && lk != 13061 // 'value' EOF
+ && lk != 13062 // 'variable' EOF
+ && lk != 13063 // 'version' EOF
+ && lk != 13066 // 'where' EOF
+ && lk != 13067 // 'while' EOF
+ && lk != 13070 // 'with' EOF
+ && lk != 13074 // 'xquery' EOF
+ && lk != 16134 // 'variable' '$'
+ && lk != 20997 // Wildcard ','
+ && lk != 20998 // EQName^Token ','
+ && lk != 21000 // IntegerLiteral ','
+ && lk != 21001 // DecimalLiteral ','
+ && lk != 21002 // DoubleLiteral ','
+ && lk != 21003 // StringLiteral ','
+ && lk != 21036 // '.' ','
+ && lk != 21037 // '..' ','
+ && lk != 21038 // '/' ','
+ && lk != 21062 // 'after' ','
+ && lk != 21064 // 'allowing' ','
+ && lk != 21065 // 'ancestor' ','
+ && lk != 21066 // 'ancestor-or-self' ','
+ && lk != 21067 // 'and' ','
+ && lk != 21069 // 'append' ','
+ && lk != 21070 // 'array' ','
+ && lk != 21071 // 'as' ','
+ && lk != 21072 // 'ascending' ','
+ && lk != 21073 // 'at' ','
+ && lk != 21074 // 'attribute' ','
+ && lk != 21075 // 'base-uri' ','
+ && lk != 21076 // 'before' ','
+ && lk != 21077 // 'boundary-space' ','
+ && lk != 21078 // 'break' ','
+ && lk != 21080 // 'case' ','
+ && lk != 21081 // 'cast' ','
+ && lk != 21082 // 'castable' ','
+ && lk != 21083 // 'catch' ','
+ && lk != 21085 // 'child' ','
+ && lk != 21086 // 'collation' ','
+ && lk != 21088 // 'comment' ','
+ && lk != 21089 // 'constraint' ','
+ && lk != 21090 // 'construction' ','
+ && lk != 21093 // 'context' ','
+ && lk != 21094 // 'continue' ','
+ && lk != 21095 // 'copy' ','
+ && lk != 21096 // 'copy-namespaces' ','
+ && lk != 21097 // 'count' ','
+ && lk != 21098 // 'decimal-format' ','
+ && lk != 21100 // 'declare' ','
+ && lk != 21101 // 'default' ','
+ && lk != 21102 // 'delete' ','
+ && lk != 21103 // 'descendant' ','
+ && lk != 21104 // 'descendant-or-self' ','
+ && lk != 21105 // 'descending' ','
+ && lk != 21110 // 'div' ','
+ && lk != 21111 // 'document' ','
+ && lk != 21112 // 'document-node' ','
+ && lk != 21113 // 'element' ','
+ && lk != 21114 // 'else' ','
+ && lk != 21115 // 'empty' ','
+ && lk != 21116 // 'empty-sequence' ','
+ && lk != 21117 // 'encoding' ','
+ && lk != 21118 // 'end' ','
+ && lk != 21120 // 'eq' ','
+ && lk != 21121 // 'every' ','
+ && lk != 21123 // 'except' ','
+ && lk != 21124 // 'exit' ','
+ && lk != 21125 // 'external' ','
+ && lk != 21126 // 'first' ','
+ && lk != 21127 // 'following' ','
+ && lk != 21128 // 'following-sibling' ','
+ && lk != 21129 // 'for' ','
+ && lk != 21133 // 'ft-option' ','
+ && lk != 21137 // 'function' ','
+ && lk != 21138 // 'ge' ','
+ && lk != 21140 // 'group' ','
+ && lk != 21142 // 'gt' ','
+ && lk != 21143 // 'idiv' ','
+ && lk != 21144 // 'if' ','
+ && lk != 21145 // 'import' ','
+ && lk != 21146 // 'in' ','
+ && lk != 21147 // 'index' ','
+ && lk != 21151 // 'insert' ','
+ && lk != 21152 // 'instance' ','
+ && lk != 21153 // 'integrity' ','
+ && lk != 21154 // 'intersect' ','
+ && lk != 21155 // 'into' ','
+ && lk != 21156 // 'is' ','
+ && lk != 21157 // 'item' ','
+ && lk != 21158 // 'json' ','
+ && lk != 21159 // 'json-item' ','
+ && lk != 21162 // 'last' ','
+ && lk != 21163 // 'lax' ','
+ && lk != 21164 // 'le' ','
+ && lk != 21166 // 'let' ','
+ && lk != 21168 // 'loop' ','
+ && lk != 21170 // 'lt' ','
+ && lk != 21172 // 'mod' ','
+ && lk != 21173 // 'modify' ','
+ && lk != 21174 // 'module' ','
+ && lk != 21176 // 'namespace' ','
+ && lk != 21177 // 'namespace-node' ','
+ && lk != 21178 // 'ne' ','
+ && lk != 21183 // 'node' ','
+ && lk != 21184 // 'nodes' ','
+ && lk != 21186 // 'object' ','
+ && lk != 21190 // 'only' ','
+ && lk != 21191 // 'option' ','
+ && lk != 21192 // 'or' ','
+ && lk != 21193 // 'order' ','
+ && lk != 21194 // 'ordered' ','
+ && lk != 21195 // 'ordering' ','
+ && lk != 21198 // 'parent' ','
+ && lk != 21204 // 'preceding' ','
+ && lk != 21205 // 'preceding-sibling' ','
+ && lk != 21208 // 'processing-instruction' ','
+ && lk != 21210 // 'rename' ','
+ && lk != 21211 // 'replace' ','
+ && lk != 21212 // 'return' ','
+ && lk != 21213 // 'returning' ','
+ && lk != 21214 // 'revalidation' ','
+ && lk != 21216 // 'satisfies' ','
+ && lk != 21217 // 'schema' ','
+ && lk != 21218 // 'schema-attribute' ','
+ && lk != 21219 // 'schema-element' ','
+ && lk != 21220 // 'score' ','
+ && lk != 21221 // 'self' ','
+ && lk != 21226 // 'sliding' ','
+ && lk != 21227 // 'some' ','
+ && lk != 21228 // 'stable' ','
+ && lk != 21229 // 'start' ','
+ && lk != 21232 // 'strict' ','
+ && lk != 21234 // 'structured-item' ','
+ && lk != 21235 // 'switch' ','
+ && lk != 21236 // 'text' ','
+ && lk != 21240 // 'to' ','
+ && lk != 21241 // 'treat' ','
+ && lk != 21242 // 'try' ','
+ && lk != 21243 // 'tumbling' ','
+ && lk != 21244 // 'type' ','
+ && lk != 21245 // 'typeswitch' ','
+ && lk != 21246 // 'union' ','
+ && lk != 21248 // 'unordered' ','
+ && lk != 21249 // 'updating' ','
+ && lk != 21252 // 'validate' ','
+ && lk != 21253 // 'value' ','
+ && lk != 21254 // 'variable' ','
+ && lk != 21255 // 'version' ','
+ && lk != 21258 // 'where' ','
+ && lk != 21259 // 'while' ','
+ && lk != 21262 // 'with' ','
+ && lk != 21266 // 'xquery' ','
+ && lk != 27141 // Wildcard ';'
+ && lk != 27142 // EQName^Token ';'
+ && lk != 27144 // IntegerLiteral ';'
+ && lk != 27145 // DecimalLiteral ';'
+ && lk != 27146 // DoubleLiteral ';'
+ && lk != 27147 // StringLiteral ';'
+ && lk != 27180 // '.' ';'
+ && lk != 27181 // '..' ';'
+ && lk != 27182 // '/' ';'
+ && lk != 27206 // 'after' ';'
+ && lk != 27208 // 'allowing' ';'
+ && lk != 27209 // 'ancestor' ';'
+ && lk != 27210 // 'ancestor-or-self' ';'
+ && lk != 27211 // 'and' ';'
+ && lk != 27213 // 'append' ';'
+ && lk != 27214 // 'array' ';'
+ && lk != 27215 // 'as' ';'
+ && lk != 27216 // 'ascending' ';'
+ && lk != 27217 // 'at' ';'
+ && lk != 27218 // 'attribute' ';'
+ && lk != 27219 // 'base-uri' ';'
+ && lk != 27220 // 'before' ';'
+ && lk != 27221 // 'boundary-space' ';'
+ && lk != 27222 // 'break' ';'
+ && lk != 27224 // 'case' ';'
+ && lk != 27225 // 'cast' ';'
+ && lk != 27226 // 'castable' ';'
+ && lk != 27227 // 'catch' ';'
+ && lk != 27229 // 'child' ';'
+ && lk != 27230 // 'collation' ';'
+ && lk != 27232 // 'comment' ';'
+ && lk != 27233 // 'constraint' ';'
+ && lk != 27234 // 'construction' ';'
+ && lk != 27237 // 'context' ';'
+ && lk != 27238 // 'continue' ';'
+ && lk != 27239 // 'copy' ';'
+ && lk != 27240 // 'copy-namespaces' ';'
+ && lk != 27241 // 'count' ';'
+ && lk != 27242 // 'decimal-format' ';'
+ && lk != 27244 // 'declare' ';'
+ && lk != 27245 // 'default' ';'
+ && lk != 27246 // 'delete' ';'
+ && lk != 27247 // 'descendant' ';'
+ && lk != 27248 // 'descendant-or-self' ';'
+ && lk != 27249 // 'descending' ';'
+ && lk != 27254 // 'div' ';'
+ && lk != 27255 // 'document' ';'
+ && lk != 27256 // 'document-node' ';'
+ && lk != 27257 // 'element' ';'
+ && lk != 27258 // 'else' ';'
+ && lk != 27259 // 'empty' ';'
+ && lk != 27260 // 'empty-sequence' ';'
+ && lk != 27261 // 'encoding' ';'
+ && lk != 27262 // 'end' ';'
+ && lk != 27264 // 'eq' ';'
+ && lk != 27265 // 'every' ';'
+ && lk != 27267 // 'except' ';'
+ && lk != 27268 // 'exit' ';'
+ && lk != 27269 // 'external' ';'
+ && lk != 27270 // 'first' ';'
+ && lk != 27271 // 'following' ';'
+ && lk != 27272 // 'following-sibling' ';'
+ && lk != 27273 // 'for' ';'
+ && lk != 27277 // 'ft-option' ';'
+ && lk != 27281 // 'function' ';'
+ && lk != 27282 // 'ge' ';'
+ && lk != 27284 // 'group' ';'
+ && lk != 27286 // 'gt' ';'
+ && lk != 27287 // 'idiv' ';'
+ && lk != 27288 // 'if' ';'
+ && lk != 27289 // 'import' ';'
+ && lk != 27290 // 'in' ';'
+ && lk != 27291 // 'index' ';'
+ && lk != 27295 // 'insert' ';'
+ && lk != 27296 // 'instance' ';'
+ && lk != 27297 // 'integrity' ';'
+ && lk != 27298 // 'intersect' ';'
+ && lk != 27299 // 'into' ';'
+ && lk != 27300 // 'is' ';'
+ && lk != 27301 // 'item' ';'
+ && lk != 27302 // 'json' ';'
+ && lk != 27303 // 'json-item' ';'
+ && lk != 27306 // 'last' ';'
+ && lk != 27307 // 'lax' ';'
+ && lk != 27308 // 'le' ';'
+ && lk != 27310 // 'let' ';'
+ && lk != 27312 // 'loop' ';'
+ && lk != 27314 // 'lt' ';'
+ && lk != 27316 // 'mod' ';'
+ && lk != 27317 // 'modify' ';'
+ && lk != 27318 // 'module' ';'
+ && lk != 27320 // 'namespace' ';'
+ && lk != 27321 // 'namespace-node' ';'
+ && lk != 27322 // 'ne' ';'
+ && lk != 27327 // 'node' ';'
+ && lk != 27328 // 'nodes' ';'
+ && lk != 27330 // 'object' ';'
+ && lk != 27334 // 'only' ';'
+ && lk != 27335 // 'option' ';'
+ && lk != 27336 // 'or' ';'
+ && lk != 27337 // 'order' ';'
+ && lk != 27338 // 'ordered' ';'
+ && lk != 27339 // 'ordering' ';'
+ && lk != 27342 // 'parent' ';'
+ && lk != 27348 // 'preceding' ';'
+ && lk != 27349 // 'preceding-sibling' ';'
+ && lk != 27352 // 'processing-instruction' ';'
+ && lk != 27354 // 'rename' ';'
+ && lk != 27355 // 'replace' ';'
+ && lk != 27356 // 'return' ';'
+ && lk != 27357 // 'returning' ';'
+ && lk != 27358 // 'revalidation' ';'
+ && lk != 27360 // 'satisfies' ';'
+ && lk != 27361 // 'schema' ';'
+ && lk != 27362 // 'schema-attribute' ';'
+ && lk != 27363 // 'schema-element' ';'
+ && lk != 27364 // 'score' ';'
+ && lk != 27365 // 'self' ';'
+ && lk != 27370 // 'sliding' ';'
+ && lk != 27371 // 'some' ';'
+ && lk != 27372 // 'stable' ';'
+ && lk != 27373 // 'start' ';'
+ && lk != 27376 // 'strict' ';'
+ && lk != 27378 // 'structured-item' ';'
+ && lk != 27379 // 'switch' ';'
+ && lk != 27380 // 'text' ';'
+ && lk != 27384 // 'to' ';'
+ && lk != 27385 // 'treat' ';'
+ && lk != 27386 // 'try' ';'
+ && lk != 27387 // 'tumbling' ';'
+ && lk != 27388 // 'type' ';'
+ && lk != 27389 // 'typeswitch' ';'
+ && lk != 27390 // 'union' ';'
+ && lk != 27392 // 'unordered' ';'
+ && lk != 27393 // 'updating' ';'
+ && lk != 27396 // 'validate' ';'
+ && lk != 27397 // 'value' ';'
+ && lk != 27398 // 'variable' ';'
+ && lk != 27399 // 'version' ';'
+ && lk != 27402 // 'where' ';'
+ && lk != 27403 // 'while' ';'
+ && lk != 27406 // 'with' ';'
+ && lk != 27410 // 'xquery' ';'
+ && lk != 90198 // 'break' 'loop'
+ && lk != 90214 // 'continue' 'loop'
+ && lk != 113284 // 'exit' 'returning'
+ && lk != 144389 // Wildcard '}'
+ && lk != 144390 // EQName^Token '}'
+ && lk != 144392 // IntegerLiteral '}'
+ && lk != 144393 // DecimalLiteral '}'
+ && lk != 144394 // DoubleLiteral '}'
+ && lk != 144395 // StringLiteral '}'
+ && lk != 144428 // '.' '}'
+ && lk != 144429 // '..' '}'
+ && lk != 144430 // '/' '}'
+ && lk != 144454 // 'after' '}'
+ && lk != 144456 // 'allowing' '}'
+ && lk != 144457 // 'ancestor' '}'
+ && lk != 144458 // 'ancestor-or-self' '}'
+ && lk != 144459 // 'and' '}'
+ && lk != 144461 // 'append' '}'
+ && lk != 144462 // 'array' '}'
+ && lk != 144463 // 'as' '}'
+ && lk != 144464 // 'ascending' '}'
+ && lk != 144465 // 'at' '}'
+ && lk != 144466 // 'attribute' '}'
+ && lk != 144467 // 'base-uri' '}'
+ && lk != 144468 // 'before' '}'
+ && lk != 144469 // 'boundary-space' '}'
+ && lk != 144470 // 'break' '}'
+ && lk != 144472 // 'case' '}'
+ && lk != 144473 // 'cast' '}'
+ && lk != 144474 // 'castable' '}'
+ && lk != 144475 // 'catch' '}'
+ && lk != 144477 // 'child' '}'
+ && lk != 144478 // 'collation' '}'
+ && lk != 144480 // 'comment' '}'
+ && lk != 144481 // 'constraint' '}'
+ && lk != 144482 // 'construction' '}'
+ && lk != 144485 // 'context' '}'
+ && lk != 144486 // 'continue' '}'
+ && lk != 144487 // 'copy' '}'
+ && lk != 144488 // 'copy-namespaces' '}'
+ && lk != 144489 // 'count' '}'
+ && lk != 144490 // 'decimal-format' '}'
+ && lk != 144492 // 'declare' '}'
+ && lk != 144493 // 'default' '}'
+ && lk != 144494 // 'delete' '}'
+ && lk != 144495 // 'descendant' '}'
+ && lk != 144496 // 'descendant-or-self' '}'
+ && lk != 144497 // 'descending' '}'
+ && lk != 144502 // 'div' '}'
+ && lk != 144503 // 'document' '}'
+ && lk != 144504 // 'document-node' '}'
+ && lk != 144505 // 'element' '}'
+ && lk != 144506 // 'else' '}'
+ && lk != 144507 // 'empty' '}'
+ && lk != 144508 // 'empty-sequence' '}'
+ && lk != 144509 // 'encoding' '}'
+ && lk != 144510 // 'end' '}'
+ && lk != 144512 // 'eq' '}'
+ && lk != 144513 // 'every' '}'
+ && lk != 144515 // 'except' '}'
+ && lk != 144516 // 'exit' '}'
+ && lk != 144517 // 'external' '}'
+ && lk != 144518 // 'first' '}'
+ && lk != 144519 // 'following' '}'
+ && lk != 144520 // 'following-sibling' '}'
+ && lk != 144521 // 'for' '}'
+ && lk != 144525 // 'ft-option' '}'
+ && lk != 144529 // 'function' '}'
+ && lk != 144530 // 'ge' '}'
+ && lk != 144532 // 'group' '}'
+ && lk != 144534 // 'gt' '}'
+ && lk != 144535 // 'idiv' '}'
+ && lk != 144536 // 'if' '}'
+ && lk != 144537 // 'import' '}'
+ && lk != 144538 // 'in' '}'
+ && lk != 144539 // 'index' '}'
+ && lk != 144543 // 'insert' '}'
+ && lk != 144544 // 'instance' '}'
+ && lk != 144545 // 'integrity' '}'
+ && lk != 144546 // 'intersect' '}'
+ && lk != 144547 // 'into' '}'
+ && lk != 144548 // 'is' '}'
+ && lk != 144549 // 'item' '}'
+ && lk != 144550 // 'json' '}'
+ && lk != 144551 // 'json-item' '}'
+ && lk != 144554 // 'last' '}'
+ && lk != 144555 // 'lax' '}'
+ && lk != 144556 // 'le' '}'
+ && lk != 144558 // 'let' '}'
+ && lk != 144560 // 'loop' '}'
+ && lk != 144562 // 'lt' '}'
+ && lk != 144564 // 'mod' '}'
+ && lk != 144565 // 'modify' '}'
+ && lk != 144566 // 'module' '}'
+ && lk != 144568 // 'namespace' '}'
+ && lk != 144569 // 'namespace-node' '}'
+ && lk != 144570 // 'ne' '}'
+ && lk != 144575 // 'node' '}'
+ && lk != 144576 // 'nodes' '}'
+ && lk != 144578 // 'object' '}'
+ && lk != 144582 // 'only' '}'
+ && lk != 144583 // 'option' '}'
+ && lk != 144584 // 'or' '}'
+ && lk != 144585 // 'order' '}'
+ && lk != 144586 // 'ordered' '}'
+ && lk != 144587 // 'ordering' '}'
+ && lk != 144590 // 'parent' '}'
+ && lk != 144596 // 'preceding' '}'
+ && lk != 144597 // 'preceding-sibling' '}'
+ && lk != 144600 // 'processing-instruction' '}'
+ && lk != 144602 // 'rename' '}'
+ && lk != 144603 // 'replace' '}'
+ && lk != 144604 // 'return' '}'
+ && lk != 144605 // 'returning' '}'
+ && lk != 144606 // 'revalidation' '}'
+ && lk != 144608 // 'satisfies' '}'
+ && lk != 144609 // 'schema' '}'
+ && lk != 144610 // 'schema-attribute' '}'
+ && lk != 144611 // 'schema-element' '}'
+ && lk != 144612 // 'score' '}'
+ && lk != 144613 // 'self' '}'
+ && lk != 144618 // 'sliding' '}'
+ && lk != 144619 // 'some' '}'
+ && lk != 144620 // 'stable' '}'
+ && lk != 144621 // 'start' '}'
+ && lk != 144624 // 'strict' '}'
+ && lk != 144626 // 'structured-item' '}'
+ && lk != 144627 // 'switch' '}'
+ && lk != 144628 // 'text' '}'
+ && lk != 144632 // 'to' '}'
+ && lk != 144633 // 'treat' '}'
+ && lk != 144634 // 'try' '}'
+ && lk != 144635 // 'tumbling' '}'
+ && lk != 144636 // 'type' '}'
+ && lk != 144637 // 'typeswitch' '}'
+ && lk != 144638 // 'union' '}'
+ && lk != 144640 // 'unordered' '}'
+ && lk != 144641 // 'updating' '}'
+ && lk != 144644 // 'validate' '}'
+ && lk != 144645 // 'value' '}'
+ && lk != 144646 // 'variable' '}'
+ && lk != 144647 // 'version' '}'
+ && lk != 144650 // 'where' '}'
+ && lk != 144651 // 'while' '}'
+ && lk != 144654 // 'with' '}'
+ && lk != 144658) // 'xquery' '}'
+ {
+ lk = memoized(6, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Statement();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(6, e0, lk);
+ }
+ }
+ if (lk != -1
+ && lk != 53 // ';'
+ && lk != 16134 // 'variable' '$'
+ && lk != 27141 // Wildcard ';'
+ && lk != 27142 // EQName^Token ';'
+ && lk != 27144 // IntegerLiteral ';'
+ && lk != 27145 // DecimalLiteral ';'
+ && lk != 27146 // DoubleLiteral ';'
+ && lk != 27147 // StringLiteral ';'
+ && lk != 27180 // '.' ';'
+ && lk != 27181 // '..' ';'
+ && lk != 27182 // '/' ';'
+ && lk != 27206 // 'after' ';'
+ && lk != 27208 // 'allowing' ';'
+ && lk != 27209 // 'ancestor' ';'
+ && lk != 27210 // 'ancestor-or-self' ';'
+ && lk != 27211 // 'and' ';'
+ && lk != 27213 // 'append' ';'
+ && lk != 27214 // 'array' ';'
+ && lk != 27215 // 'as' ';'
+ && lk != 27216 // 'ascending' ';'
+ && lk != 27217 // 'at' ';'
+ && lk != 27218 // 'attribute' ';'
+ && lk != 27219 // 'base-uri' ';'
+ && lk != 27220 // 'before' ';'
+ && lk != 27221 // 'boundary-space' ';'
+ && lk != 27222 // 'break' ';'
+ && lk != 27224 // 'case' ';'
+ && lk != 27225 // 'cast' ';'
+ && lk != 27226 // 'castable' ';'
+ && lk != 27227 // 'catch' ';'
+ && lk != 27229 // 'child' ';'
+ && lk != 27230 // 'collation' ';'
+ && lk != 27232 // 'comment' ';'
+ && lk != 27233 // 'constraint' ';'
+ && lk != 27234 // 'construction' ';'
+ && lk != 27237 // 'context' ';'
+ && lk != 27238 // 'continue' ';'
+ && lk != 27239 // 'copy' ';'
+ && lk != 27240 // 'copy-namespaces' ';'
+ && lk != 27241 // 'count' ';'
+ && lk != 27242 // 'decimal-format' ';'
+ && lk != 27244 // 'declare' ';'
+ && lk != 27245 // 'default' ';'
+ && lk != 27246 // 'delete' ';'
+ && lk != 27247 // 'descendant' ';'
+ && lk != 27248 // 'descendant-or-self' ';'
+ && lk != 27249 // 'descending' ';'
+ && lk != 27254 // 'div' ';'
+ && lk != 27255 // 'document' ';'
+ && lk != 27256 // 'document-node' ';'
+ && lk != 27257 // 'element' ';'
+ && lk != 27258 // 'else' ';'
+ && lk != 27259 // 'empty' ';'
+ && lk != 27260 // 'empty-sequence' ';'
+ && lk != 27261 // 'encoding' ';'
+ && lk != 27262 // 'end' ';'
+ && lk != 27264 // 'eq' ';'
+ && lk != 27265 // 'every' ';'
+ && lk != 27267 // 'except' ';'
+ && lk != 27268 // 'exit' ';'
+ && lk != 27269 // 'external' ';'
+ && lk != 27270 // 'first' ';'
+ && lk != 27271 // 'following' ';'
+ && lk != 27272 // 'following-sibling' ';'
+ && lk != 27273 // 'for' ';'
+ && lk != 27277 // 'ft-option' ';'
+ && lk != 27281 // 'function' ';'
+ && lk != 27282 // 'ge' ';'
+ && lk != 27284 // 'group' ';'
+ && lk != 27286 // 'gt' ';'
+ && lk != 27287 // 'idiv' ';'
+ && lk != 27288 // 'if' ';'
+ && lk != 27289 // 'import' ';'
+ && lk != 27290 // 'in' ';'
+ && lk != 27291 // 'index' ';'
+ && lk != 27295 // 'insert' ';'
+ && lk != 27296 // 'instance' ';'
+ && lk != 27297 // 'integrity' ';'
+ && lk != 27298 // 'intersect' ';'
+ && lk != 27299 // 'into' ';'
+ && lk != 27300 // 'is' ';'
+ && lk != 27301 // 'item' ';'
+ && lk != 27302 // 'json' ';'
+ && lk != 27303 // 'json-item' ';'
+ && lk != 27306 // 'last' ';'
+ && lk != 27307 // 'lax' ';'
+ && lk != 27308 // 'le' ';'
+ && lk != 27310 // 'let' ';'
+ && lk != 27312 // 'loop' ';'
+ && lk != 27314 // 'lt' ';'
+ && lk != 27316 // 'mod' ';'
+ && lk != 27317 // 'modify' ';'
+ && lk != 27318 // 'module' ';'
+ && lk != 27320 // 'namespace' ';'
+ && lk != 27321 // 'namespace-node' ';'
+ && lk != 27322 // 'ne' ';'
+ && lk != 27327 // 'node' ';'
+ && lk != 27328 // 'nodes' ';'
+ && lk != 27330 // 'object' ';'
+ && lk != 27334 // 'only' ';'
+ && lk != 27335 // 'option' ';'
+ && lk != 27336 // 'or' ';'
+ && lk != 27337 // 'order' ';'
+ && lk != 27338 // 'ordered' ';'
+ && lk != 27339 // 'ordering' ';'
+ && lk != 27342 // 'parent' ';'
+ && lk != 27348 // 'preceding' ';'
+ && lk != 27349 // 'preceding-sibling' ';'
+ && lk != 27352 // 'processing-instruction' ';'
+ && lk != 27354 // 'rename' ';'
+ && lk != 27355 // 'replace' ';'
+ && lk != 27356 // 'return' ';'
+ && lk != 27357 // 'returning' ';'
+ && lk != 27358 // 'revalidation' ';'
+ && lk != 27360 // 'satisfies' ';'
+ && lk != 27361 // 'schema' ';'
+ && lk != 27362 // 'schema-attribute' ';'
+ && lk != 27363 // 'schema-element' ';'
+ && lk != 27364 // 'score' ';'
+ && lk != 27365 // 'self' ';'
+ && lk != 27370 // 'sliding' ';'
+ && lk != 27371 // 'some' ';'
+ && lk != 27372 // 'stable' ';'
+ && lk != 27373 // 'start' ';'
+ && lk != 27376 // 'strict' ';'
+ && lk != 27378 // 'structured-item' ';'
+ && lk != 27379 // 'switch' ';'
+ && lk != 27380 // 'text' ';'
+ && lk != 27384 // 'to' ';'
+ && lk != 27385 // 'treat' ';'
+ && lk != 27386 // 'try' ';'
+ && lk != 27387 // 'tumbling' ';'
+ && lk != 27388 // 'type' ';'
+ && lk != 27389 // 'typeswitch' ';'
+ && lk != 27390 // 'union' ';'
+ && lk != 27392 // 'unordered' ';'
+ && lk != 27393 // 'updating' ';'
+ && lk != 27396 // 'validate' ';'
+ && lk != 27397 // 'value' ';'
+ && lk != 27398 // 'variable' ';'
+ && lk != 27399 // 'version' ';'
+ && lk != 27402 // 'where' ';'
+ && lk != 27403 // 'while' ';'
+ && lk != 27406 // 'with' ';'
+ && lk != 27410 // 'xquery' ';'
+ && lk != 90198 // 'break' 'loop'
+ && lk != 90214 // 'continue' 'loop'
+ && lk != 113284) // 'exit' 'returning'
+ {
+ break;
+ }
+ whitespace();
+ parse_Statement();
+ }
+ eventHandler.endNonterminal("Statements", e0);
+ }
+
+ function try_Statements()
+ {
+ for (;;)
+ {
+ lookahead1W(277); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 34: // '('
+ lookahead2W(268); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 35: // '(#'
+ lookahead2(251); // EQName^Token | S | 'after' | 'allowing' | 'ancestor' | 'ancestor-or-self' |
+ break;
+ case 46: // '/'
+ lookahead2W(283); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 47: // '//'
+ lookahead2W(264); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 54: // '<'
+ lookahead2(4); // QName
+ break;
+ case 55: // '<!--'
+ lookahead2(1); // DirCommentContents
+ break;
+ case 59: // '<?'
+ lookahead2(3); // PITarget
+ break;
+ case 66: // '@'
+ lookahead2W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 68: // '['
+ lookahead2W(271); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 77: // 'append'
+ lookahead2W(199); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 82: // 'attribute'
+ lookahead2W(280); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' |
+ break;
+ case 121: // 'element'
+ lookahead2W(279); // EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' |
+ break;
+ case 132: // 'exit'
+ lookahead2W(202); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 137: // 'for'
+ lookahead2W(207); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 174: // 'let'
+ lookahead2W(204); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 218: // 'rename'
+ lookahead2W(205); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 219: // 'replace'
+ lookahead2W(206); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 260: // 'validate'
+ lookahead2W(209); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 278: // '{|'
+ lookahead2W(272); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 5: // Wildcard
+ case 45: // '..'
+ lookahead2W(185); // S^WS | EOF | '!' | '!=' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 31: // '$'
+ case 32: // '%'
+ lookahead2W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 40: // '+'
+ case 42: // '-'
+ lookahead2W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 86: // 'break'
+ case 102: // 'continue'
+ lookahead2W(200); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 110: // 'delete'
+ case 159: // 'insert'
+ lookahead2W(208); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 184: // 'namespace'
+ case 216: // 'processing-instruction'
+ lookahead2W(267); // NCName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' |
+ break;
+ case 103: // 'copy'
+ case 129: // 'every'
+ case 235: // 'some'
+ case 262: // 'variable'
+ lookahead2W(196); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ case 44: // '.'
+ lookahead2W(191); // S^WS | EOF | '!' | '!=' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' | ';' |
+ break;
+ case 78: // 'array'
+ case 124: // 'empty-sequence'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 242: // 'structured-item'
+ lookahead2W(190); // S^WS | EOF | '!' | '!=' | '#' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' | ';' |
+ break;
+ case 96: // 'comment'
+ case 119: // 'document'
+ case 202: // 'ordered'
+ case 244: // 'text'
+ case 250: // 'try'
+ case 256: // 'unordered'
+ lookahead2W(203); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 93: // 'child'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ case 229: // 'self'
+ lookahead2W(197); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ case 6: // EQName^Token
+ case 70: // 'after'
+ case 72: // 'allowing'
+ case 75: // 'and'
+ case 79: // 'as'
+ case 80: // 'ascending'
+ case 81: // 'at'
+ case 83: // 'base-uri'
+ case 84: // 'before'
+ case 85: // 'boundary-space'
+ case 88: // 'case'
+ case 89: // 'cast'
+ case 90: // 'castable'
+ case 91: // 'catch'
+ case 94: // 'collation'
+ case 97: // 'constraint'
+ case 98: // 'construction'
+ case 101: // 'context'
+ case 104: // 'copy-namespaces'
+ case 105: // 'count'
+ case 106: // 'decimal-format'
+ case 108: // 'declare'
+ case 109: // 'default'
+ case 113: // 'descending'
+ case 118: // 'div'
+ case 120: // 'document-node'
+ case 122: // 'else'
+ case 123: // 'empty'
+ case 125: // 'encoding'
+ case 126: // 'end'
+ case 128: // 'eq'
+ case 131: // 'except'
+ case 133: // 'external'
+ case 134: // 'first'
+ case 141: // 'ft-option'
+ case 145: // 'function'
+ case 146: // 'ge'
+ case 148: // 'group'
+ case 150: // 'gt'
+ case 151: // 'idiv'
+ case 152: // 'if'
+ case 153: // 'import'
+ case 154: // 'in'
+ case 155: // 'index'
+ case 160: // 'instance'
+ case 161: // 'integrity'
+ case 162: // 'intersect'
+ case 163: // 'into'
+ case 164: // 'is'
+ case 166: // 'json'
+ case 170: // 'last'
+ case 171: // 'lax'
+ case 172: // 'le'
+ case 176: // 'loop'
+ case 178: // 'lt'
+ case 180: // 'mod'
+ case 181: // 'modify'
+ case 182: // 'module'
+ case 185: // 'namespace-node'
+ case 186: // 'ne'
+ case 191: // 'node'
+ case 192: // 'nodes'
+ case 194: // 'object'
+ case 198: // 'only'
+ case 199: // 'option'
+ case 200: // 'or'
+ case 201: // 'order'
+ case 203: // 'ordering'
+ case 220: // 'return'
+ case 221: // 'returning'
+ case 222: // 'revalidation'
+ case 224: // 'satisfies'
+ case 225: // 'schema'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 228: // 'score'
+ case 234: // 'sliding'
+ case 236: // 'stable'
+ case 237: // 'start'
+ case 240: // 'strict'
+ case 243: // 'switch'
+ case 248: // 'to'
+ case 249: // 'treat'
+ case 251: // 'tumbling'
+ case 252: // 'type'
+ case 253: // 'typeswitch'
+ case 254: // 'union'
+ case 257: // 'updating'
+ case 261: // 'value'
+ case 263: // 'version'
+ case 266: // 'where'
+ case 267: // 'while'
+ case 270: // 'with'
+ case 274: // 'xquery'
+ lookahead2W(194); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | ',' | '-' | '/' | '//' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk != 25 // EOF
+ && lk != 53 // ';'
+ && lk != 282 // '}'
+ && lk != 12805 // Wildcard EOF
+ && lk != 12806 // EQName^Token EOF
+ && lk != 12808 // IntegerLiteral EOF
+ && lk != 12809 // DecimalLiteral EOF
+ && lk != 12810 // DoubleLiteral EOF
+ && lk != 12811 // StringLiteral EOF
+ && lk != 12844 // '.' EOF
+ && lk != 12845 // '..' EOF
+ && lk != 12846 // '/' EOF
+ && lk != 12870 // 'after' EOF
+ && lk != 12872 // 'allowing' EOF
+ && lk != 12873 // 'ancestor' EOF
+ && lk != 12874 // 'ancestor-or-self' EOF
+ && lk != 12875 // 'and' EOF
+ && lk != 12877 // 'append' EOF
+ && lk != 12878 // 'array' EOF
+ && lk != 12879 // 'as' EOF
+ && lk != 12880 // 'ascending' EOF
+ && lk != 12881 // 'at' EOF
+ && lk != 12882 // 'attribute' EOF
+ && lk != 12883 // 'base-uri' EOF
+ && lk != 12884 // 'before' EOF
+ && lk != 12885 // 'boundary-space' EOF
+ && lk != 12886 // 'break' EOF
+ && lk != 12888 // 'case' EOF
+ && lk != 12889 // 'cast' EOF
+ && lk != 12890 // 'castable' EOF
+ && lk != 12891 // 'catch' EOF
+ && lk != 12893 // 'child' EOF
+ && lk != 12894 // 'collation' EOF
+ && lk != 12896 // 'comment' EOF
+ && lk != 12897 // 'constraint' EOF
+ && lk != 12898 // 'construction' EOF
+ && lk != 12901 // 'context' EOF
+ && lk != 12902 // 'continue' EOF
+ && lk != 12903 // 'copy' EOF
+ && lk != 12904 // 'copy-namespaces' EOF
+ && lk != 12905 // 'count' EOF
+ && lk != 12906 // 'decimal-format' EOF
+ && lk != 12908 // 'declare' EOF
+ && lk != 12909 // 'default' EOF
+ && lk != 12910 // 'delete' EOF
+ && lk != 12911 // 'descendant' EOF
+ && lk != 12912 // 'descendant-or-self' EOF
+ && lk != 12913 // 'descending' EOF
+ && lk != 12918 // 'div' EOF
+ && lk != 12919 // 'document' EOF
+ && lk != 12920 // 'document-node' EOF
+ && lk != 12921 // 'element' EOF
+ && lk != 12922 // 'else' EOF
+ && lk != 12923 // 'empty' EOF
+ && lk != 12924 // 'empty-sequence' EOF
+ && lk != 12925 // 'encoding' EOF
+ && lk != 12926 // 'end' EOF
+ && lk != 12928 // 'eq' EOF
+ && lk != 12929 // 'every' EOF
+ && lk != 12931 // 'except' EOF
+ && lk != 12932 // 'exit' EOF
+ && lk != 12933 // 'external' EOF
+ && lk != 12934 // 'first' EOF
+ && lk != 12935 // 'following' EOF
+ && lk != 12936 // 'following-sibling' EOF
+ && lk != 12937 // 'for' EOF
+ && lk != 12941 // 'ft-option' EOF
+ && lk != 12945 // 'function' EOF
+ && lk != 12946 // 'ge' EOF
+ && lk != 12948 // 'group' EOF
+ && lk != 12950 // 'gt' EOF
+ && lk != 12951 // 'idiv' EOF
+ && lk != 12952 // 'if' EOF
+ && lk != 12953 // 'import' EOF
+ && lk != 12954 // 'in' EOF
+ && lk != 12955 // 'index' EOF
+ && lk != 12959 // 'insert' EOF
+ && lk != 12960 // 'instance' EOF
+ && lk != 12961 // 'integrity' EOF
+ && lk != 12962 // 'intersect' EOF
+ && lk != 12963 // 'into' EOF
+ && lk != 12964 // 'is' EOF
+ && lk != 12965 // 'item' EOF
+ && lk != 12966 // 'json' EOF
+ && lk != 12967 // 'json-item' EOF
+ && lk != 12970 // 'last' EOF
+ && lk != 12971 // 'lax' EOF
+ && lk != 12972 // 'le' EOF
+ && lk != 12974 // 'let' EOF
+ && lk != 12976 // 'loop' EOF
+ && lk != 12978 // 'lt' EOF
+ && lk != 12980 // 'mod' EOF
+ && lk != 12981 // 'modify' EOF
+ && lk != 12982 // 'module' EOF
+ && lk != 12984 // 'namespace' EOF
+ && lk != 12985 // 'namespace-node' EOF
+ && lk != 12986 // 'ne' EOF
+ && lk != 12991 // 'node' EOF
+ && lk != 12992 // 'nodes' EOF
+ && lk != 12994 // 'object' EOF
+ && lk != 12998 // 'only' EOF
+ && lk != 12999 // 'option' EOF
+ && lk != 13000 // 'or' EOF
+ && lk != 13001 // 'order' EOF
+ && lk != 13002 // 'ordered' EOF
+ && lk != 13003 // 'ordering' EOF
+ && lk != 13006 // 'parent' EOF
+ && lk != 13012 // 'preceding' EOF
+ && lk != 13013 // 'preceding-sibling' EOF
+ && lk != 13016 // 'processing-instruction' EOF
+ && lk != 13018 // 'rename' EOF
+ && lk != 13019 // 'replace' EOF
+ && lk != 13020 // 'return' EOF
+ && lk != 13021 // 'returning' EOF
+ && lk != 13022 // 'revalidation' EOF
+ && lk != 13024 // 'satisfies' EOF
+ && lk != 13025 // 'schema' EOF
+ && lk != 13026 // 'schema-attribute' EOF
+ && lk != 13027 // 'schema-element' EOF
+ && lk != 13028 // 'score' EOF
+ && lk != 13029 // 'self' EOF
+ && lk != 13034 // 'sliding' EOF
+ && lk != 13035 // 'some' EOF
+ && lk != 13036 // 'stable' EOF
+ && lk != 13037 // 'start' EOF
+ && lk != 13040 // 'strict' EOF
+ && lk != 13042 // 'structured-item' EOF
+ && lk != 13043 // 'switch' EOF
+ && lk != 13044 // 'text' EOF
+ && lk != 13048 // 'to' EOF
+ && lk != 13049 // 'treat' EOF
+ && lk != 13050 // 'try' EOF
+ && lk != 13051 // 'tumbling' EOF
+ && lk != 13052 // 'type' EOF
+ && lk != 13053 // 'typeswitch' EOF
+ && lk != 13054 // 'union' EOF
+ && lk != 13056 // 'unordered' EOF
+ && lk != 13057 // 'updating' EOF
+ && lk != 13060 // 'validate' EOF
+ && lk != 13061 // 'value' EOF
+ && lk != 13062 // 'variable' EOF
+ && lk != 13063 // 'version' EOF
+ && lk != 13066 // 'where' EOF
+ && lk != 13067 // 'while' EOF
+ && lk != 13070 // 'with' EOF
+ && lk != 13074 // 'xquery' EOF
+ && lk != 16134 // 'variable' '$'
+ && lk != 20997 // Wildcard ','
+ && lk != 20998 // EQName^Token ','
+ && lk != 21000 // IntegerLiteral ','
+ && lk != 21001 // DecimalLiteral ','
+ && lk != 21002 // DoubleLiteral ','
+ && lk != 21003 // StringLiteral ','
+ && lk != 21036 // '.' ','
+ && lk != 21037 // '..' ','
+ && lk != 21038 // '/' ','
+ && lk != 21062 // 'after' ','
+ && lk != 21064 // 'allowing' ','
+ && lk != 21065 // 'ancestor' ','
+ && lk != 21066 // 'ancestor-or-self' ','
+ && lk != 21067 // 'and' ','
+ && lk != 21069 // 'append' ','
+ && lk != 21070 // 'array' ','
+ && lk != 21071 // 'as' ','
+ && lk != 21072 // 'ascending' ','
+ && lk != 21073 // 'at' ','
+ && lk != 21074 // 'attribute' ','
+ && lk != 21075 // 'base-uri' ','
+ && lk != 21076 // 'before' ','
+ && lk != 21077 // 'boundary-space' ','
+ && lk != 21078 // 'break' ','
+ && lk != 21080 // 'case' ','
+ && lk != 21081 // 'cast' ','
+ && lk != 21082 // 'castable' ','
+ && lk != 21083 // 'catch' ','
+ && lk != 21085 // 'child' ','
+ && lk != 21086 // 'collation' ','
+ && lk != 21088 // 'comment' ','
+ && lk != 21089 // 'constraint' ','
+ && lk != 21090 // 'construction' ','
+ && lk != 21093 // 'context' ','
+ && lk != 21094 // 'continue' ','
+ && lk != 21095 // 'copy' ','
+ && lk != 21096 // 'copy-namespaces' ','
+ && lk != 21097 // 'count' ','
+ && lk != 21098 // 'decimal-format' ','
+ && lk != 21100 // 'declare' ','
+ && lk != 21101 // 'default' ','
+ && lk != 21102 // 'delete' ','
+ && lk != 21103 // 'descendant' ','
+ && lk != 21104 // 'descendant-or-self' ','
+ && lk != 21105 // 'descending' ','
+ && lk != 21110 // 'div' ','
+ && lk != 21111 // 'document' ','
+ && lk != 21112 // 'document-node' ','
+ && lk != 21113 // 'element' ','
+ && lk != 21114 // 'else' ','
+ && lk != 21115 // 'empty' ','
+ && lk != 21116 // 'empty-sequence' ','
+ && lk != 21117 // 'encoding' ','
+ && lk != 21118 // 'end' ','
+ && lk != 21120 // 'eq' ','
+ && lk != 21121 // 'every' ','
+ && lk != 21123 // 'except' ','
+ && lk != 21124 // 'exit' ','
+ && lk != 21125 // 'external' ','
+ && lk != 21126 // 'first' ','
+ && lk != 21127 // 'following' ','
+ && lk != 21128 // 'following-sibling' ','
+ && lk != 21129 // 'for' ','
+ && lk != 21133 // 'ft-option' ','
+ && lk != 21137 // 'function' ','
+ && lk != 21138 // 'ge' ','
+ && lk != 21140 // 'group' ','
+ && lk != 21142 // 'gt' ','
+ && lk != 21143 // 'idiv' ','
+ && lk != 21144 // 'if' ','
+ && lk != 21145 // 'import' ','
+ && lk != 21146 // 'in' ','
+ && lk != 21147 // 'index' ','
+ && lk != 21151 // 'insert' ','
+ && lk != 21152 // 'instance' ','
+ && lk != 21153 // 'integrity' ','
+ && lk != 21154 // 'intersect' ','
+ && lk != 21155 // 'into' ','
+ && lk != 21156 // 'is' ','
+ && lk != 21157 // 'item' ','
+ && lk != 21158 // 'json' ','
+ && lk != 21159 // 'json-item' ','
+ && lk != 21162 // 'last' ','
+ && lk != 21163 // 'lax' ','
+ && lk != 21164 // 'le' ','
+ && lk != 21166 // 'let' ','
+ && lk != 21168 // 'loop' ','
+ && lk != 21170 // 'lt' ','
+ && lk != 21172 // 'mod' ','
+ && lk != 21173 // 'modify' ','
+ && lk != 21174 // 'module' ','
+ && lk != 21176 // 'namespace' ','
+ && lk != 21177 // 'namespace-node' ','
+ && lk != 21178 // 'ne' ','
+ && lk != 21183 // 'node' ','
+ && lk != 21184 // 'nodes' ','
+ && lk != 21186 // 'object' ','
+ && lk != 21190 // 'only' ','
+ && lk != 21191 // 'option' ','
+ && lk != 21192 // 'or' ','
+ && lk != 21193 // 'order' ','
+ && lk != 21194 // 'ordered' ','
+ && lk != 21195 // 'ordering' ','
+ && lk != 21198 // 'parent' ','
+ && lk != 21204 // 'preceding' ','
+ && lk != 21205 // 'preceding-sibling' ','
+ && lk != 21208 // 'processing-instruction' ','
+ && lk != 21210 // 'rename' ','
+ && lk != 21211 // 'replace' ','
+ && lk != 21212 // 'return' ','
+ && lk != 21213 // 'returning' ','
+ && lk != 21214 // 'revalidation' ','
+ && lk != 21216 // 'satisfies' ','
+ && lk != 21217 // 'schema' ','
+ && lk != 21218 // 'schema-attribute' ','
+ && lk != 21219 // 'schema-element' ','
+ && lk != 21220 // 'score' ','
+ && lk != 21221 // 'self' ','
+ && lk != 21226 // 'sliding' ','
+ && lk != 21227 // 'some' ','
+ && lk != 21228 // 'stable' ','
+ && lk != 21229 // 'start' ','
+ && lk != 21232 // 'strict' ','
+ && lk != 21234 // 'structured-item' ','
+ && lk != 21235 // 'switch' ','
+ && lk != 21236 // 'text' ','
+ && lk != 21240 // 'to' ','
+ && lk != 21241 // 'treat' ','
+ && lk != 21242 // 'try' ','
+ && lk != 21243 // 'tumbling' ','
+ && lk != 21244 // 'type' ','
+ && lk != 21245 // 'typeswitch' ','
+ && lk != 21246 // 'union' ','
+ && lk != 21248 // 'unordered' ','
+ && lk != 21249 // 'updating' ','
+ && lk != 21252 // 'validate' ','
+ && lk != 21253 // 'value' ','
+ && lk != 21254 // 'variable' ','
+ && lk != 21255 // 'version' ','
+ && lk != 21258 // 'where' ','
+ && lk != 21259 // 'while' ','
+ && lk != 21262 // 'with' ','
+ && lk != 21266 // 'xquery' ','
+ && lk != 27141 // Wildcard ';'
+ && lk != 27142 // EQName^Token ';'
+ && lk != 27144 // IntegerLiteral ';'
+ && lk != 27145 // DecimalLiteral ';'
+ && lk != 27146 // DoubleLiteral ';'
+ && lk != 27147 // StringLiteral ';'
+ && lk != 27180 // '.' ';'
+ && lk != 27181 // '..' ';'
+ && lk != 27182 // '/' ';'
+ && lk != 27206 // 'after' ';'
+ && lk != 27208 // 'allowing' ';'
+ && lk != 27209 // 'ancestor' ';'
+ && lk != 27210 // 'ancestor-or-self' ';'
+ && lk != 27211 // 'and' ';'
+ && lk != 27213 // 'append' ';'
+ && lk != 27214 // 'array' ';'
+ && lk != 27215 // 'as' ';'
+ && lk != 27216 // 'ascending' ';'
+ && lk != 27217 // 'at' ';'
+ && lk != 27218 // 'attribute' ';'
+ && lk != 27219 // 'base-uri' ';'
+ && lk != 27220 // 'before' ';'
+ && lk != 27221 // 'boundary-space' ';'
+ && lk != 27222 // 'break' ';'
+ && lk != 27224 // 'case' ';'
+ && lk != 27225 // 'cast' ';'
+ && lk != 27226 // 'castable' ';'
+ && lk != 27227 // 'catch' ';'
+ && lk != 27229 // 'child' ';'
+ && lk != 27230 // 'collation' ';'
+ && lk != 27232 // 'comment' ';'
+ && lk != 27233 // 'constraint' ';'
+ && lk != 27234 // 'construction' ';'
+ && lk != 27237 // 'context' ';'
+ && lk != 27238 // 'continue' ';'
+ && lk != 27239 // 'copy' ';'
+ && lk != 27240 // 'copy-namespaces' ';'
+ && lk != 27241 // 'count' ';'
+ && lk != 27242 // 'decimal-format' ';'
+ && lk != 27244 // 'declare' ';'
+ && lk != 27245 // 'default' ';'
+ && lk != 27246 // 'delete' ';'
+ && lk != 27247 // 'descendant' ';'
+ && lk != 27248 // 'descendant-or-self' ';'
+ && lk != 27249 // 'descending' ';'
+ && lk != 27254 // 'div' ';'
+ && lk != 27255 // 'document' ';'
+ && lk != 27256 // 'document-node' ';'
+ && lk != 27257 // 'element' ';'
+ && lk != 27258 // 'else' ';'
+ && lk != 27259 // 'empty' ';'
+ && lk != 27260 // 'empty-sequence' ';'
+ && lk != 27261 // 'encoding' ';'
+ && lk != 27262 // 'end' ';'
+ && lk != 27264 // 'eq' ';'
+ && lk != 27265 // 'every' ';'
+ && lk != 27267 // 'except' ';'
+ && lk != 27268 // 'exit' ';'
+ && lk != 27269 // 'external' ';'
+ && lk != 27270 // 'first' ';'
+ && lk != 27271 // 'following' ';'
+ && lk != 27272 // 'following-sibling' ';'
+ && lk != 27273 // 'for' ';'
+ && lk != 27277 // 'ft-option' ';'
+ && lk != 27281 // 'function' ';'
+ && lk != 27282 // 'ge' ';'
+ && lk != 27284 // 'group' ';'
+ && lk != 27286 // 'gt' ';'
+ && lk != 27287 // 'idiv' ';'
+ && lk != 27288 // 'if' ';'
+ && lk != 27289 // 'import' ';'
+ && lk != 27290 // 'in' ';'
+ && lk != 27291 // 'index' ';'
+ && lk != 27295 // 'insert' ';'
+ && lk != 27296 // 'instance' ';'
+ && lk != 27297 // 'integrity' ';'
+ && lk != 27298 // 'intersect' ';'
+ && lk != 27299 // 'into' ';'
+ && lk != 27300 // 'is' ';'
+ && lk != 27301 // 'item' ';'
+ && lk != 27302 // 'json' ';'
+ && lk != 27303 // 'json-item' ';'
+ && lk != 27306 // 'last' ';'
+ && lk != 27307 // 'lax' ';'
+ && lk != 27308 // 'le' ';'
+ && lk != 27310 // 'let' ';'
+ && lk != 27312 // 'loop' ';'
+ && lk != 27314 // 'lt' ';'
+ && lk != 27316 // 'mod' ';'
+ && lk != 27317 // 'modify' ';'
+ && lk != 27318 // 'module' ';'
+ && lk != 27320 // 'namespace' ';'
+ && lk != 27321 // 'namespace-node' ';'
+ && lk != 27322 // 'ne' ';'
+ && lk != 27327 // 'node' ';'
+ && lk != 27328 // 'nodes' ';'
+ && lk != 27330 // 'object' ';'
+ && lk != 27334 // 'only' ';'
+ && lk != 27335 // 'option' ';'
+ && lk != 27336 // 'or' ';'
+ && lk != 27337 // 'order' ';'
+ && lk != 27338 // 'ordered' ';'
+ && lk != 27339 // 'ordering' ';'
+ && lk != 27342 // 'parent' ';'
+ && lk != 27348 // 'preceding' ';'
+ && lk != 27349 // 'preceding-sibling' ';'
+ && lk != 27352 // 'processing-instruction' ';'
+ && lk != 27354 // 'rename' ';'
+ && lk != 27355 // 'replace' ';'
+ && lk != 27356 // 'return' ';'
+ && lk != 27357 // 'returning' ';'
+ && lk != 27358 // 'revalidation' ';'
+ && lk != 27360 // 'satisfies' ';'
+ && lk != 27361 // 'schema' ';'
+ && lk != 27362 // 'schema-attribute' ';'
+ && lk != 27363 // 'schema-element' ';'
+ && lk != 27364 // 'score' ';'
+ && lk != 27365 // 'self' ';'
+ && lk != 27370 // 'sliding' ';'
+ && lk != 27371 // 'some' ';'
+ && lk != 27372 // 'stable' ';'
+ && lk != 27373 // 'start' ';'
+ && lk != 27376 // 'strict' ';'
+ && lk != 27378 // 'structured-item' ';'
+ && lk != 27379 // 'switch' ';'
+ && lk != 27380 // 'text' ';'
+ && lk != 27384 // 'to' ';'
+ && lk != 27385 // 'treat' ';'
+ && lk != 27386 // 'try' ';'
+ && lk != 27387 // 'tumbling' ';'
+ && lk != 27388 // 'type' ';'
+ && lk != 27389 // 'typeswitch' ';'
+ && lk != 27390 // 'union' ';'
+ && lk != 27392 // 'unordered' ';'
+ && lk != 27393 // 'updating' ';'
+ && lk != 27396 // 'validate' ';'
+ && lk != 27397 // 'value' ';'
+ && lk != 27398 // 'variable' ';'
+ && lk != 27399 // 'version' ';'
+ && lk != 27402 // 'where' ';'
+ && lk != 27403 // 'while' ';'
+ && lk != 27406 // 'with' ';'
+ && lk != 27410 // 'xquery' ';'
+ && lk != 90198 // 'break' 'loop'
+ && lk != 90214 // 'continue' 'loop'
+ && lk != 113284 // 'exit' 'returning'
+ && lk != 144389 // Wildcard '}'
+ && lk != 144390 // EQName^Token '}'
+ && lk != 144392 // IntegerLiteral '}'
+ && lk != 144393 // DecimalLiteral '}'
+ && lk != 144394 // DoubleLiteral '}'
+ && lk != 144395 // StringLiteral '}'
+ && lk != 144428 // '.' '}'
+ && lk != 144429 // '..' '}'
+ && lk != 144430 // '/' '}'
+ && lk != 144454 // 'after' '}'
+ && lk != 144456 // 'allowing' '}'
+ && lk != 144457 // 'ancestor' '}'
+ && lk != 144458 // 'ancestor-or-self' '}'
+ && lk != 144459 // 'and' '}'
+ && lk != 144461 // 'append' '}'
+ && lk != 144462 // 'array' '}'
+ && lk != 144463 // 'as' '}'
+ && lk != 144464 // 'ascending' '}'
+ && lk != 144465 // 'at' '}'
+ && lk != 144466 // 'attribute' '}'
+ && lk != 144467 // 'base-uri' '}'
+ && lk != 144468 // 'before' '}'
+ && lk != 144469 // 'boundary-space' '}'
+ && lk != 144470 // 'break' '}'
+ && lk != 144472 // 'case' '}'
+ && lk != 144473 // 'cast' '}'
+ && lk != 144474 // 'castable' '}'
+ && lk != 144475 // 'catch' '}'
+ && lk != 144477 // 'child' '}'
+ && lk != 144478 // 'collation' '}'
+ && lk != 144480 // 'comment' '}'
+ && lk != 144481 // 'constraint' '}'
+ && lk != 144482 // 'construction' '}'
+ && lk != 144485 // 'context' '}'
+ && lk != 144486 // 'continue' '}'
+ && lk != 144487 // 'copy' '}'
+ && lk != 144488 // 'copy-namespaces' '}'
+ && lk != 144489 // 'count' '}'
+ && lk != 144490 // 'decimal-format' '}'
+ && lk != 144492 // 'declare' '}'
+ && lk != 144493 // 'default' '}'
+ && lk != 144494 // 'delete' '}'
+ && lk != 144495 // 'descendant' '}'
+ && lk != 144496 // 'descendant-or-self' '}'
+ && lk != 144497 // 'descending' '}'
+ && lk != 144502 // 'div' '}'
+ && lk != 144503 // 'document' '}'
+ && lk != 144504 // 'document-node' '}'
+ && lk != 144505 // 'element' '}'
+ && lk != 144506 // 'else' '}'
+ && lk != 144507 // 'empty' '}'
+ && lk != 144508 // 'empty-sequence' '}'
+ && lk != 144509 // 'encoding' '}'
+ && lk != 144510 // 'end' '}'
+ && lk != 144512 // 'eq' '}'
+ && lk != 144513 // 'every' '}'
+ && lk != 144515 // 'except' '}'
+ && lk != 144516 // 'exit' '}'
+ && lk != 144517 // 'external' '}'
+ && lk != 144518 // 'first' '}'
+ && lk != 144519 // 'following' '}'
+ && lk != 144520 // 'following-sibling' '}'
+ && lk != 144521 // 'for' '}'
+ && lk != 144525 // 'ft-option' '}'
+ && lk != 144529 // 'function' '}'
+ && lk != 144530 // 'ge' '}'
+ && lk != 144532 // 'group' '}'
+ && lk != 144534 // 'gt' '}'
+ && lk != 144535 // 'idiv' '}'
+ && lk != 144536 // 'if' '}'
+ && lk != 144537 // 'import' '}'
+ && lk != 144538 // 'in' '}'
+ && lk != 144539 // 'index' '}'
+ && lk != 144543 // 'insert' '}'
+ && lk != 144544 // 'instance' '}'
+ && lk != 144545 // 'integrity' '}'
+ && lk != 144546 // 'intersect' '}'
+ && lk != 144547 // 'into' '}'
+ && lk != 144548 // 'is' '}'
+ && lk != 144549 // 'item' '}'
+ && lk != 144550 // 'json' '}'
+ && lk != 144551 // 'json-item' '}'
+ && lk != 144554 // 'last' '}'
+ && lk != 144555 // 'lax' '}'
+ && lk != 144556 // 'le' '}'
+ && lk != 144558 // 'let' '}'
+ && lk != 144560 // 'loop' '}'
+ && lk != 144562 // 'lt' '}'
+ && lk != 144564 // 'mod' '}'
+ && lk != 144565 // 'modify' '}'
+ && lk != 144566 // 'module' '}'
+ && lk != 144568 // 'namespace' '}'
+ && lk != 144569 // 'namespace-node' '}'
+ && lk != 144570 // 'ne' '}'
+ && lk != 144575 // 'node' '}'
+ && lk != 144576 // 'nodes' '}'
+ && lk != 144578 // 'object' '}'
+ && lk != 144582 // 'only' '}'
+ && lk != 144583 // 'option' '}'
+ && lk != 144584 // 'or' '}'
+ && lk != 144585 // 'order' '}'
+ && lk != 144586 // 'ordered' '}'
+ && lk != 144587 // 'ordering' '}'
+ && lk != 144590 // 'parent' '}'
+ && lk != 144596 // 'preceding' '}'
+ && lk != 144597 // 'preceding-sibling' '}'
+ && lk != 144600 // 'processing-instruction' '}'
+ && lk != 144602 // 'rename' '}'
+ && lk != 144603 // 'replace' '}'
+ && lk != 144604 // 'return' '}'
+ && lk != 144605 // 'returning' '}'
+ && lk != 144606 // 'revalidation' '}'
+ && lk != 144608 // 'satisfies' '}'
+ && lk != 144609 // 'schema' '}'
+ && lk != 144610 // 'schema-attribute' '}'
+ && lk != 144611 // 'schema-element' '}'
+ && lk != 144612 // 'score' '}'
+ && lk != 144613 // 'self' '}'
+ && lk != 144618 // 'sliding' '}'
+ && lk != 144619 // 'some' '}'
+ && lk != 144620 // 'stable' '}'
+ && lk != 144621 // 'start' '}'
+ && lk != 144624 // 'strict' '}'
+ && lk != 144626 // 'structured-item' '}'
+ && lk != 144627 // 'switch' '}'
+ && lk != 144628 // 'text' '}'
+ && lk != 144632 // 'to' '}'
+ && lk != 144633 // 'treat' '}'
+ && lk != 144634 // 'try' '}'
+ && lk != 144635 // 'tumbling' '}'
+ && lk != 144636 // 'type' '}'
+ && lk != 144637 // 'typeswitch' '}'
+ && lk != 144638 // 'union' '}'
+ && lk != 144640 // 'unordered' '}'
+ && lk != 144641 // 'updating' '}'
+ && lk != 144644 // 'validate' '}'
+ && lk != 144645 // 'value' '}'
+ && lk != 144646 // 'variable' '}'
+ && lk != 144647 // 'version' '}'
+ && lk != 144650 // 'where' '}'
+ && lk != 144651 // 'while' '}'
+ && lk != 144654 // 'with' '}'
+ && lk != 144658) // 'xquery' '}'
+ {
+ lk = memoized(6, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_Statement();
+ memoize(6, e0A, -1);
+ continue;
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(6, e0A, -2);
+ break;
+ }
+ }
+ }
+ if (lk != -1
+ && lk != 53 // ';'
+ && lk != 16134 // 'variable' '$'
+ && lk != 27141 // Wildcard ';'
+ && lk != 27142 // EQName^Token ';'
+ && lk != 27144 // IntegerLiteral ';'
+ && lk != 27145 // DecimalLiteral ';'
+ && lk != 27146 // DoubleLiteral ';'
+ && lk != 27147 // StringLiteral ';'
+ && lk != 27180 // '.' ';'
+ && lk != 27181 // '..' ';'
+ && lk != 27182 // '/' ';'
+ && lk != 27206 // 'after' ';'
+ && lk != 27208 // 'allowing' ';'
+ && lk != 27209 // 'ancestor' ';'
+ && lk != 27210 // 'ancestor-or-self' ';'
+ && lk != 27211 // 'and' ';'
+ && lk != 27213 // 'append' ';'
+ && lk != 27214 // 'array' ';'
+ && lk != 27215 // 'as' ';'
+ && lk != 27216 // 'ascending' ';'
+ && lk != 27217 // 'at' ';'
+ && lk != 27218 // 'attribute' ';'
+ && lk != 27219 // 'base-uri' ';'
+ && lk != 27220 // 'before' ';'
+ && lk != 27221 // 'boundary-space' ';'
+ && lk != 27222 // 'break' ';'
+ && lk != 27224 // 'case' ';'
+ && lk != 27225 // 'cast' ';'
+ && lk != 27226 // 'castable' ';'
+ && lk != 27227 // 'catch' ';'
+ && lk != 27229 // 'child' ';'
+ && lk != 27230 // 'collation' ';'
+ && lk != 27232 // 'comment' ';'
+ && lk != 27233 // 'constraint' ';'
+ && lk != 27234 // 'construction' ';'
+ && lk != 27237 // 'context' ';'
+ && lk != 27238 // 'continue' ';'
+ && lk != 27239 // 'copy' ';'
+ && lk != 27240 // 'copy-namespaces' ';'
+ && lk != 27241 // 'count' ';'
+ && lk != 27242 // 'decimal-format' ';'
+ && lk != 27244 // 'declare' ';'
+ && lk != 27245 // 'default' ';'
+ && lk != 27246 // 'delete' ';'
+ && lk != 27247 // 'descendant' ';'
+ && lk != 27248 // 'descendant-or-self' ';'
+ && lk != 27249 // 'descending' ';'
+ && lk != 27254 // 'div' ';'
+ && lk != 27255 // 'document' ';'
+ && lk != 27256 // 'document-node' ';'
+ && lk != 27257 // 'element' ';'
+ && lk != 27258 // 'else' ';'
+ && lk != 27259 // 'empty' ';'
+ && lk != 27260 // 'empty-sequence' ';'
+ && lk != 27261 // 'encoding' ';'
+ && lk != 27262 // 'end' ';'
+ && lk != 27264 // 'eq' ';'
+ && lk != 27265 // 'every' ';'
+ && lk != 27267 // 'except' ';'
+ && lk != 27268 // 'exit' ';'
+ && lk != 27269 // 'external' ';'
+ && lk != 27270 // 'first' ';'
+ && lk != 27271 // 'following' ';'
+ && lk != 27272 // 'following-sibling' ';'
+ && lk != 27273 // 'for' ';'
+ && lk != 27277 // 'ft-option' ';'
+ && lk != 27281 // 'function' ';'
+ && lk != 27282 // 'ge' ';'
+ && lk != 27284 // 'group' ';'
+ && lk != 27286 // 'gt' ';'
+ && lk != 27287 // 'idiv' ';'
+ && lk != 27288 // 'if' ';'
+ && lk != 27289 // 'import' ';'
+ && lk != 27290 // 'in' ';'
+ && lk != 27291 // 'index' ';'
+ && lk != 27295 // 'insert' ';'
+ && lk != 27296 // 'instance' ';'
+ && lk != 27297 // 'integrity' ';'
+ && lk != 27298 // 'intersect' ';'
+ && lk != 27299 // 'into' ';'
+ && lk != 27300 // 'is' ';'
+ && lk != 27301 // 'item' ';'
+ && lk != 27302 // 'json' ';'
+ && lk != 27303 // 'json-item' ';'
+ && lk != 27306 // 'last' ';'
+ && lk != 27307 // 'lax' ';'
+ && lk != 27308 // 'le' ';'
+ && lk != 27310 // 'let' ';'
+ && lk != 27312 // 'loop' ';'
+ && lk != 27314 // 'lt' ';'
+ && lk != 27316 // 'mod' ';'
+ && lk != 27317 // 'modify' ';'
+ && lk != 27318 // 'module' ';'
+ && lk != 27320 // 'namespace' ';'
+ && lk != 27321 // 'namespace-node' ';'
+ && lk != 27322 // 'ne' ';'
+ && lk != 27327 // 'node' ';'
+ && lk != 27328 // 'nodes' ';'
+ && lk != 27330 // 'object' ';'
+ && lk != 27334 // 'only' ';'
+ && lk != 27335 // 'option' ';'
+ && lk != 27336 // 'or' ';'
+ && lk != 27337 // 'order' ';'
+ && lk != 27338 // 'ordered' ';'
+ && lk != 27339 // 'ordering' ';'
+ && lk != 27342 // 'parent' ';'
+ && lk != 27348 // 'preceding' ';'
+ && lk != 27349 // 'preceding-sibling' ';'
+ && lk != 27352 // 'processing-instruction' ';'
+ && lk != 27354 // 'rename' ';'
+ && lk != 27355 // 'replace' ';'
+ && lk != 27356 // 'return' ';'
+ && lk != 27357 // 'returning' ';'
+ && lk != 27358 // 'revalidation' ';'
+ && lk != 27360 // 'satisfies' ';'
+ && lk != 27361 // 'schema' ';'
+ && lk != 27362 // 'schema-attribute' ';'
+ && lk != 27363 // 'schema-element' ';'
+ && lk != 27364 // 'score' ';'
+ && lk != 27365 // 'self' ';'
+ && lk != 27370 // 'sliding' ';'
+ && lk != 27371 // 'some' ';'
+ && lk != 27372 // 'stable' ';'
+ && lk != 27373 // 'start' ';'
+ && lk != 27376 // 'strict' ';'
+ && lk != 27378 // 'structured-item' ';'
+ && lk != 27379 // 'switch' ';'
+ && lk != 27380 // 'text' ';'
+ && lk != 27384 // 'to' ';'
+ && lk != 27385 // 'treat' ';'
+ && lk != 27386 // 'try' ';'
+ && lk != 27387 // 'tumbling' ';'
+ && lk != 27388 // 'type' ';'
+ && lk != 27389 // 'typeswitch' ';'
+ && lk != 27390 // 'union' ';'
+ && lk != 27392 // 'unordered' ';'
+ && lk != 27393 // 'updating' ';'
+ && lk != 27396 // 'validate' ';'
+ && lk != 27397 // 'value' ';'
+ && lk != 27398 // 'variable' ';'
+ && lk != 27399 // 'version' ';'
+ && lk != 27402 // 'where' ';'
+ && lk != 27403 // 'while' ';'
+ && lk != 27406 // 'with' ';'
+ && lk != 27410 // 'xquery' ';'
+ && lk != 90198 // 'break' 'loop'
+ && lk != 90214 // 'continue' 'loop'
+ && lk != 113284) // 'exit' 'returning'
+ {
+ break;
+ }
+ try_Statement();
+ }
+ }
+
+ function parse_StatementsAndExpr()
+ {
+ eventHandler.startNonterminal("StatementsAndExpr", e0);
+ parse_Statements();
+ whitespace();
+ parse_Expr();
+ eventHandler.endNonterminal("StatementsAndExpr", e0);
+ }
+
+ function try_StatementsAndExpr()
+ {
+ try_Statements();
+ try_Expr();
+ }
+
+ function parse_StatementsAndOptionalExpr()
+ {
+ eventHandler.startNonterminal("StatementsAndOptionalExpr", e0);
+ parse_Statements();
+ if (l1 != 25 // EOF
+ && l1 != 282) // '}'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ eventHandler.endNonterminal("StatementsAndOptionalExpr", e0);
+ }
+
+ function try_StatementsAndOptionalExpr()
+ {
+ try_Statements();
+ if (l1 != 25 // EOF
+ && l1 != 282) // '}'
+ {
+ try_Expr();
+ }
+ }
+
+ function parse_Statement()
+ {
+ eventHandler.startNonterminal("Statement", e0);
+ switch (l1)
+ {
+ case 132: // 'exit'
+ lookahead2W(188); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 137: // 'for'
+ lookahead2W(195); // S^WS | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' |
+ break;
+ case 174: // 'let'
+ lookahead2W(192); // S^WS | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' |
+ break;
+ case 250: // 'try'
+ lookahead2W(189); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 262: // 'variable'
+ lookahead2W(186); // S^WS | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' |
+ break;
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 31: // '$'
+ case 32: // '%'
+ lookahead2W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 86: // 'break'
+ case 102: // 'continue'
+ lookahead2W(187); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 152: // 'if'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ case 267: // 'while'
+ lookahead2W(184); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 2836 // '{' Wildcard
+ || lk == 3103 // '$' EQName^Token
+ || lk == 3104 // '%' EQName^Token
+ || lk == 3348 // '{' EQName^Token
+ || lk == 4372 // '{' IntegerLiteral
+ || lk == 4884 // '{' DecimalLiteral
+ || lk == 5396 // '{' DoubleLiteral
+ || lk == 5908 // '{' StringLiteral
+ || lk == 16148 // '{' '$'
+ || lk == 16660 // '{' '%'
+ || lk == 17675 // 'while' '('
+ || lk == 17684 // '{' '('
+ || lk == 18196 // '{' '(#'
+ || lk == 20756 // '{' '+'
+ || lk == 21780 // '{' '-'
+ || lk == 22804 // '{' '.'
+ || lk == 23316 // '{' '..'
+ || lk == 23828 // '{' '/'
+ || lk == 24340 // '{' '//'
+ || lk == 27412 // '{' ';'
+ || lk == 27924 // '{' '<'
+ || lk == 28436 // '{' '<!--'
+ || lk == 30484 // '{' '<?'
+ || lk == 34068 // '{' '@'
+ || lk == 35092 // '{' '['
+ || lk == 35871 // '$' 'after'
+ || lk == 35872 // '%' 'after'
+ || lk == 36116 // '{' 'after'
+ || lk == 36895 // '$' 'allowing'
+ || lk == 36896 // '%' 'allowing'
+ || lk == 37140 // '{' 'allowing'
+ || lk == 37407 // '$' 'ancestor'
+ || lk == 37408 // '%' 'ancestor'
+ || lk == 37652 // '{' 'ancestor'
+ || lk == 37919 // '$' 'ancestor-or-self'
+ || lk == 37920 // '%' 'ancestor-or-self'
+ || lk == 38164 // '{' 'ancestor-or-self'
+ || lk == 38431 // '$' 'and'
+ || lk == 38432 // '%' 'and'
+ || lk == 38676 // '{' 'and'
+ || lk == 39455 // '$' 'append'
+ || lk == 39456 // '%' 'append'
+ || lk == 39700 // '{' 'append'
+ || lk == 39967 // '$' 'array'
+ || lk == 39968 // '%' 'array'
+ || lk == 40212 // '{' 'array'
+ || lk == 40479 // '$' 'as'
+ || lk == 40480 // '%' 'as'
+ || lk == 40724 // '{' 'as'
+ || lk == 40991 // '$' 'ascending'
+ || lk == 40992 // '%' 'ascending'
+ || lk == 41236 // '{' 'ascending'
+ || lk == 41503 // '$' 'at'
+ || lk == 41504 // '%' 'at'
+ || lk == 41748 // '{' 'at'
+ || lk == 42015 // '$' 'attribute'
+ || lk == 42016 // '%' 'attribute'
+ || lk == 42260 // '{' 'attribute'
+ || lk == 42527 // '$' 'base-uri'
+ || lk == 42528 // '%' 'base-uri'
+ || lk == 42772 // '{' 'base-uri'
+ || lk == 43039 // '$' 'before'
+ || lk == 43040 // '%' 'before'
+ || lk == 43284 // '{' 'before'
+ || lk == 43551 // '$' 'boundary-space'
+ || lk == 43552 // '%' 'boundary-space'
+ || lk == 43796 // '{' 'boundary-space'
+ || lk == 44063 // '$' 'break'
+ || lk == 44064 // '%' 'break'
+ || lk == 44308 // '{' 'break'
+ || lk == 45087 // '$' 'case'
+ || lk == 45088 // '%' 'case'
+ || lk == 45332 // '{' 'case'
+ || lk == 45599 // '$' 'cast'
+ || lk == 45600 // '%' 'cast'
+ || lk == 45844 // '{' 'cast'
+ || lk == 46111 // '$' 'castable'
+ || lk == 46112 // '%' 'castable'
+ || lk == 46356 // '{' 'castable'
+ || lk == 46623 // '$' 'catch'
+ || lk == 46624 // '%' 'catch'
+ || lk == 46868 // '{' 'catch'
+ || lk == 47647 // '$' 'child'
+ || lk == 47648 // '%' 'child'
+ || lk == 47892 // '{' 'child'
+ || lk == 48159 // '$' 'collation'
+ || lk == 48160 // '%' 'collation'
+ || lk == 48404 // '{' 'collation'
+ || lk == 49183 // '$' 'comment'
+ || lk == 49184 // '%' 'comment'
+ || lk == 49428 // '{' 'comment'
+ || lk == 49695 // '$' 'constraint'
+ || lk == 49696 // '%' 'constraint'
+ || lk == 49940 // '{' 'constraint'
+ || lk == 50207 // '$' 'construction'
+ || lk == 50208 // '%' 'construction'
+ || lk == 50452 // '{' 'construction'
+ || lk == 51743 // '$' 'context'
+ || lk == 51744 // '%' 'context'
+ || lk == 51988 // '{' 'context'
+ || lk == 52255 // '$' 'continue'
+ || lk == 52256 // '%' 'continue'
+ || lk == 52500 // '{' 'continue'
+ || lk == 52767 // '$' 'copy'
+ || lk == 52768 // '%' 'copy'
+ || lk == 53012 // '{' 'copy'
+ || lk == 53279 // '$' 'copy-namespaces'
+ || lk == 53280 // '%' 'copy-namespaces'
+ || lk == 53524 // '{' 'copy-namespaces'
+ || lk == 53791 // '$' 'count'
+ || lk == 53792 // '%' 'count'
+ || lk == 54036 // '{' 'count'
+ || lk == 54303 // '$' 'decimal-format'
+ || lk == 54304 // '%' 'decimal-format'
+ || lk == 54548 // '{' 'decimal-format'
+ || lk == 55327 // '$' 'declare'
+ || lk == 55328 // '%' 'declare'
+ || lk == 55572 // '{' 'declare'
+ || lk == 55839 // '$' 'default'
+ || lk == 55840 // '%' 'default'
+ || lk == 56084 // '{' 'default'
+ || lk == 56351 // '$' 'delete'
+ || lk == 56352 // '%' 'delete'
+ || lk == 56596 // '{' 'delete'
+ || lk == 56863 // '$' 'descendant'
+ || lk == 56864 // '%' 'descendant'
+ || lk == 57108 // '{' 'descendant'
+ || lk == 57375 // '$' 'descendant-or-self'
+ || lk == 57376 // '%' 'descendant-or-self'
+ || lk == 57620 // '{' 'descendant-or-self'
+ || lk == 57887 // '$' 'descending'
+ || lk == 57888 // '%' 'descending'
+ || lk == 58132 // '{' 'descending'
+ || lk == 60447 // '$' 'div'
+ || lk == 60448 // '%' 'div'
+ || lk == 60692 // '{' 'div'
+ || lk == 60959 // '$' 'document'
+ || lk == 60960 // '%' 'document'
+ || lk == 61204 // '{' 'document'
+ || lk == 61471 // '$' 'document-node'
+ || lk == 61472 // '%' 'document-node'
+ || lk == 61716 // '{' 'document-node'
+ || lk == 61983 // '$' 'element'
+ || lk == 61984 // '%' 'element'
+ || lk == 62228 // '{' 'element'
+ || lk == 62495 // '$' 'else'
+ || lk == 62496 // '%' 'else'
+ || lk == 62740 // '{' 'else'
+ || lk == 63007 // '$' 'empty'
+ || lk == 63008 // '%' 'empty'
+ || lk == 63252 // '{' 'empty'
+ || lk == 63519 // '$' 'empty-sequence'
+ || lk == 63520 // '%' 'empty-sequence'
+ || lk == 63764 // '{' 'empty-sequence'
+ || lk == 64031 // '$' 'encoding'
+ || lk == 64032 // '%' 'encoding'
+ || lk == 64276 // '{' 'encoding'
+ || lk == 64543 // '$' 'end'
+ || lk == 64544 // '%' 'end'
+ || lk == 64788 // '{' 'end'
+ || lk == 65567 // '$' 'eq'
+ || lk == 65568 // '%' 'eq'
+ || lk == 65812 // '{' 'eq'
+ || lk == 66079 // '$' 'every'
+ || lk == 66080 // '%' 'every'
+ || lk == 66324 // '{' 'every'
+ || lk == 67103 // '$' 'except'
+ || lk == 67104 // '%' 'except'
+ || lk == 67348 // '{' 'except'
+ || lk == 67615 // '$' 'exit'
+ || lk == 67616 // '%' 'exit'
+ || lk == 67860 // '{' 'exit'
+ || lk == 68127 // '$' 'external'
+ || lk == 68128 // '%' 'external'
+ || lk == 68372 // '{' 'external'
+ || lk == 68639 // '$' 'first'
+ || lk == 68640 // '%' 'first'
+ || lk == 68884 // '{' 'first'
+ || lk == 69151 // '$' 'following'
+ || lk == 69152 // '%' 'following'
+ || lk == 69396 // '{' 'following'
+ || lk == 69663 // '$' 'following-sibling'
+ || lk == 69664 // '%' 'following-sibling'
+ || lk == 69908 // '{' 'following-sibling'
+ || lk == 70175 // '$' 'for'
+ || lk == 70176 // '%' 'for'
+ || lk == 70420 // '{' 'for'
+ || lk == 72223 // '$' 'ft-option'
+ || lk == 72224 // '%' 'ft-option'
+ || lk == 72468 // '{' 'ft-option'
+ || lk == 74271 // '$' 'function'
+ || lk == 74272 // '%' 'function'
+ || lk == 74516 // '{' 'function'
+ || lk == 74783 // '$' 'ge'
+ || lk == 74784 // '%' 'ge'
+ || lk == 75028 // '{' 'ge'
+ || lk == 75807 // '$' 'group'
+ || lk == 75808 // '%' 'group'
+ || lk == 76052 // '{' 'group'
+ || lk == 76831 // '$' 'gt'
+ || lk == 76832 // '%' 'gt'
+ || lk == 77076 // '{' 'gt'
+ || lk == 77343 // '$' 'idiv'
+ || lk == 77344 // '%' 'idiv'
+ || lk == 77588 // '{' 'idiv'
+ || lk == 77855 // '$' 'if'
+ || lk == 77856 // '%' 'if'
+ || lk == 78100 // '{' 'if'
+ || lk == 78367 // '$' 'import'
+ || lk == 78368 // '%' 'import'
+ || lk == 78612 // '{' 'import'
+ || lk == 78879 // '$' 'in'
+ || lk == 78880 // '%' 'in'
+ || lk == 79124 // '{' 'in'
+ || lk == 79391 // '$' 'index'
+ || lk == 79392 // '%' 'index'
+ || lk == 79636 // '{' 'index'
+ || lk == 81439 // '$' 'insert'
+ || lk == 81440 // '%' 'insert'
+ || lk == 81684 // '{' 'insert'
+ || lk == 81951 // '$' 'instance'
+ || lk == 81952 // '%' 'instance'
+ || lk == 82196 // '{' 'instance'
+ || lk == 82463 // '$' 'integrity'
+ || lk == 82464 // '%' 'integrity'
+ || lk == 82708 // '{' 'integrity'
+ || lk == 82975 // '$' 'intersect'
+ || lk == 82976 // '%' 'intersect'
+ || lk == 83220 // '{' 'intersect'
+ || lk == 83487 // '$' 'into'
+ || lk == 83488 // '%' 'into'
+ || lk == 83732 // '{' 'into'
+ || lk == 83999 // '$' 'is'
+ || lk == 84000 // '%' 'is'
+ || lk == 84244 // '{' 'is'
+ || lk == 84511 // '$' 'item'
+ || lk == 84512 // '%' 'item'
+ || lk == 84756 // '{' 'item'
+ || lk == 85023 // '$' 'json'
+ || lk == 85024 // '%' 'json'
+ || lk == 85268 // '{' 'json'
+ || lk == 85535 // '$' 'json-item'
+ || lk == 85536 // '%' 'json-item'
+ || lk == 85780 // '{' 'json-item'
+ || lk == 87071 // '$' 'last'
+ || lk == 87072 // '%' 'last'
+ || lk == 87316 // '{' 'last'
+ || lk == 87583 // '$' 'lax'
+ || lk == 87584 // '%' 'lax'
+ || lk == 87828 // '{' 'lax'
+ || lk == 88095 // '$' 'le'
+ || lk == 88096 // '%' 'le'
+ || lk == 88340 // '{' 'le'
+ || lk == 89119 // '$' 'let'
+ || lk == 89120 // '%' 'let'
+ || lk == 89364 // '{' 'let'
+ || lk == 90143 // '$' 'loop'
+ || lk == 90144 // '%' 'loop'
+ || lk == 90388 // '{' 'loop'
+ || lk == 91167 // '$' 'lt'
+ || lk == 91168 // '%' 'lt'
+ || lk == 91412 // '{' 'lt'
+ || lk == 92191 // '$' 'mod'
+ || lk == 92192 // '%' 'mod'
+ || lk == 92436 // '{' 'mod'
+ || lk == 92703 // '$' 'modify'
+ || lk == 92704 // '%' 'modify'
+ || lk == 92948 // '{' 'modify'
+ || lk == 93215 // '$' 'module'
+ || lk == 93216 // '%' 'module'
+ || lk == 93460 // '{' 'module'
+ || lk == 94239 // '$' 'namespace'
+ || lk == 94240 // '%' 'namespace'
+ || lk == 94484 // '{' 'namespace'
+ || lk == 94751 // '$' 'namespace-node'
+ || lk == 94752 // '%' 'namespace-node'
+ || lk == 94996 // '{' 'namespace-node'
+ || lk == 95263 // '$' 'ne'
+ || lk == 95264 // '%' 'ne'
+ || lk == 95508 // '{' 'ne'
+ || lk == 97823 // '$' 'node'
+ || lk == 97824 // '%' 'node'
+ || lk == 98068 // '{' 'node'
+ || lk == 98335 // '$' 'nodes'
+ || lk == 98336 // '%' 'nodes'
+ || lk == 98580 // '{' 'nodes'
+ || lk == 99359 // '$' 'object'
+ || lk == 99360 // '%' 'object'
+ || lk == 99604 // '{' 'object'
+ || lk == 101407 // '$' 'only'
+ || lk == 101408 // '%' 'only'
+ || lk == 101652 // '{' 'only'
+ || lk == 101919 // '$' 'option'
+ || lk == 101920 // '%' 'option'
+ || lk == 102164 // '{' 'option'
+ || lk == 102431 // '$' 'or'
+ || lk == 102432 // '%' 'or'
+ || lk == 102676 // '{' 'or'
+ || lk == 102943 // '$' 'order'
+ || lk == 102944 // '%' 'order'
+ || lk == 103188 // '{' 'order'
+ || lk == 103455 // '$' 'ordered'
+ || lk == 103456 // '%' 'ordered'
+ || lk == 103700 // '{' 'ordered'
+ || lk == 103967 // '$' 'ordering'
+ || lk == 103968 // '%' 'ordering'
+ || lk == 104212 // '{' 'ordering'
+ || lk == 105503 // '$' 'parent'
+ || lk == 105504 // '%' 'parent'
+ || lk == 105748 // '{' 'parent'
+ || lk == 108575 // '$' 'preceding'
+ || lk == 108576 // '%' 'preceding'
+ || lk == 108820 // '{' 'preceding'
+ || lk == 109087 // '$' 'preceding-sibling'
+ || lk == 109088 // '%' 'preceding-sibling'
+ || lk == 109332 // '{' 'preceding-sibling'
+ || lk == 110623 // '$' 'processing-instruction'
+ || lk == 110624 // '%' 'processing-instruction'
+ || lk == 110868 // '{' 'processing-instruction'
+ || lk == 111647 // '$' 'rename'
+ || lk == 111648 // '%' 'rename'
+ || lk == 111892 // '{' 'rename'
+ || lk == 112159 // '$' 'replace'
+ || lk == 112160 // '%' 'replace'
+ || lk == 112404 // '{' 'replace'
+ || lk == 112671 // '$' 'return'
+ || lk == 112672 // '%' 'return'
+ || lk == 112916 // '{' 'return'
+ || lk == 113183 // '$' 'returning'
+ || lk == 113184 // '%' 'returning'
+ || lk == 113428 // '{' 'returning'
+ || lk == 113695 // '$' 'revalidation'
+ || lk == 113696 // '%' 'revalidation'
+ || lk == 113940 // '{' 'revalidation'
+ || lk == 114719 // '$' 'satisfies'
+ || lk == 114720 // '%' 'satisfies'
+ || lk == 114964 // '{' 'satisfies'
+ || lk == 115231 // '$' 'schema'
+ || lk == 115232 // '%' 'schema'
+ || lk == 115476 // '{' 'schema'
+ || lk == 115743 // '$' 'schema-attribute'
+ || lk == 115744 // '%' 'schema-attribute'
+ || lk == 115988 // '{' 'schema-attribute'
+ || lk == 116255 // '$' 'schema-element'
+ || lk == 116256 // '%' 'schema-element'
+ || lk == 116500 // '{' 'schema-element'
+ || lk == 116767 // '$' 'score'
+ || lk == 116768 // '%' 'score'
+ || lk == 117012 // '{' 'score'
+ || lk == 117279 // '$' 'self'
+ || lk == 117280 // '%' 'self'
+ || lk == 117524 // '{' 'self'
+ || lk == 119839 // '$' 'sliding'
+ || lk == 119840 // '%' 'sliding'
+ || lk == 120084 // '{' 'sliding'
+ || lk == 120351 // '$' 'some'
+ || lk == 120352 // '%' 'some'
+ || lk == 120596 // '{' 'some'
+ || lk == 120863 // '$' 'stable'
+ || lk == 120864 // '%' 'stable'
+ || lk == 121108 // '{' 'stable'
+ || lk == 121375 // '$' 'start'
+ || lk == 121376 // '%' 'start'
+ || lk == 121620 // '{' 'start'
+ || lk == 122911 // '$' 'strict'
+ || lk == 122912 // '%' 'strict'
+ || lk == 123156 // '{' 'strict'
+ || lk == 123935 // '$' 'structured-item'
+ || lk == 123936 // '%' 'structured-item'
+ || lk == 124180 // '{' 'structured-item'
+ || lk == 124447 // '$' 'switch'
+ || lk == 124448 // '%' 'switch'
+ || lk == 124692 // '{' 'switch'
+ || lk == 124959 // '$' 'text'
+ || lk == 124960 // '%' 'text'
+ || lk == 125204 // '{' 'text'
+ || lk == 127007 // '$' 'to'
+ || lk == 127008 // '%' 'to'
+ || lk == 127252 // '{' 'to'
+ || lk == 127519 // '$' 'treat'
+ || lk == 127520 // '%' 'treat'
+ || lk == 127764 // '{' 'treat'
+ || lk == 128031 // '$' 'try'
+ || lk == 128032 // '%' 'try'
+ || lk == 128276 // '{' 'try'
+ || lk == 128543 // '$' 'tumbling'
+ || lk == 128544 // '%' 'tumbling'
+ || lk == 128788 // '{' 'tumbling'
+ || lk == 129055 // '$' 'type'
+ || lk == 129056 // '%' 'type'
+ || lk == 129300 // '{' 'type'
+ || lk == 129567 // '$' 'typeswitch'
+ || lk == 129568 // '%' 'typeswitch'
+ || lk == 129812 // '{' 'typeswitch'
+ || lk == 130079 // '$' 'union'
+ || lk == 130080 // '%' 'union'
+ || lk == 130324 // '{' 'union'
+ || lk == 131103 // '$' 'unordered'
+ || lk == 131104 // '%' 'unordered'
+ || lk == 131348 // '{' 'unordered'
+ || lk == 131615 // '$' 'updating'
+ || lk == 131616 // '%' 'updating'
+ || lk == 131860 // '{' 'updating'
+ || lk == 133151 // '$' 'validate'
+ || lk == 133152 // '%' 'validate'
+ || lk == 133396 // '{' 'validate'
+ || lk == 133663 // '$' 'value'
+ || lk == 133664 // '%' 'value'
+ || lk == 133908 // '{' 'value'
+ || lk == 134175 // '$' 'variable'
+ || lk == 134176 // '%' 'variable'
+ || lk == 134420 // '{' 'variable'
+ || lk == 134687 // '$' 'version'
+ || lk == 134688 // '%' 'version'
+ || lk == 134932 // '{' 'version'
+ || lk == 136223 // '$' 'where'
+ || lk == 136224 // '%' 'where'
+ || lk == 136468 // '{' 'where'
+ || lk == 136735 // '$' 'while'
+ || lk == 136736 // '%' 'while'
+ || lk == 136980 // '{' 'while'
+ || lk == 138271 // '$' 'with'
+ || lk == 138272 // '%' 'with'
+ || lk == 138516 // '{' 'with'
+ || lk == 140319 // '$' 'xquery'
+ || lk == 140320 // '%' 'xquery'
+ || lk == 140564 // '{' 'xquery'
+ || lk == 141588 // '{' '{'
+ || lk == 142612 // '{' '{|'
+ || lk == 144660) // '{' '}'
+ {
+ lk = memoized(7, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ApplyStatement();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_AssignStatement();
+ lk = -2;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_BlockStatement();
+ lk = -3;
+ }
+ catch (p3A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_VarDeclStatement();
+ lk = -12;
+ }
+ catch (p12A)
+ {
+ lk = -13;
+ }
+ }
+ }
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(7, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -2:
+ parse_AssignStatement();
+ break;
+ case -3:
+ parse_BlockStatement();
+ break;
+ case 90198: // 'break' 'loop'
+ parse_BreakStatement();
+ break;
+ case 90214: // 'continue' 'loop'
+ parse_ContinueStatement();
+ break;
+ case 113284: // 'exit' 'returning'
+ parse_ExitStatement();
+ break;
+ case 16009: // 'for' '$'
+ case 16046: // 'let' '$'
+ case 116910: // 'let' 'score'
+ case 119945: // 'for' 'sliding'
+ case 128649: // 'for' 'tumbling'
+ parse_FLWORStatement();
+ break;
+ case 17560: // 'if' '('
+ parse_IfStatement();
+ break;
+ case 17651: // 'switch' '('
+ parse_SwitchStatement();
+ break;
+ case 141562: // 'try' '{'
+ parse_TryCatchStatement();
+ break;
+ case 17661: // 'typeswitch' '('
+ parse_TypeswitchStatement();
+ break;
+ case -12:
+ case 16134: // 'variable' '$'
+ parse_VarDeclStatement();
+ break;
+ case -13:
+ parse_WhileStatement();
+ break;
+ case 53: // ';'
+ parse_VoidStatement();
+ break;
+ default:
+ parse_ApplyStatement();
+ }
+ eventHandler.endNonterminal("Statement", e0);
+ }
+
+ function try_Statement()
+ {
+ switch (l1)
+ {
+ case 132: // 'exit'
+ lookahead2W(188); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 137: // 'for'
+ lookahead2W(195); // S^WS | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' |
+ break;
+ case 174: // 'let'
+ lookahead2W(192); // S^WS | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' |
+ break;
+ case 250: // 'try'
+ lookahead2W(189); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 262: // 'variable'
+ lookahead2W(186); // S^WS | '!' | '!=' | '#' | '$' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' |
+ break;
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 31: // '$'
+ case 32: // '%'
+ lookahead2W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 86: // 'break'
+ case 102: // 'continue'
+ lookahead2W(187); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ case 152: // 'if'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ case 267: // 'while'
+ lookahead2W(184); // S^WS | '!' | '!=' | '#' | '(' | '(:' | '*' | '+' | '-' | '/' | '//' | ';' | '<' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 2836 // '{' Wildcard
+ || lk == 3103 // '$' EQName^Token
+ || lk == 3104 // '%' EQName^Token
+ || lk == 3348 // '{' EQName^Token
+ || lk == 4372 // '{' IntegerLiteral
+ || lk == 4884 // '{' DecimalLiteral
+ || lk == 5396 // '{' DoubleLiteral
+ || lk == 5908 // '{' StringLiteral
+ || lk == 16148 // '{' '$'
+ || lk == 16660 // '{' '%'
+ || lk == 17675 // 'while' '('
+ || lk == 17684 // '{' '('
+ || lk == 18196 // '{' '(#'
+ || lk == 20756 // '{' '+'
+ || lk == 21780 // '{' '-'
+ || lk == 22804 // '{' '.'
+ || lk == 23316 // '{' '..'
+ || lk == 23828 // '{' '/'
+ || lk == 24340 // '{' '//'
+ || lk == 27412 // '{' ';'
+ || lk == 27924 // '{' '<'
+ || lk == 28436 // '{' '<!--'
+ || lk == 30484 // '{' '<?'
+ || lk == 34068 // '{' '@'
+ || lk == 35092 // '{' '['
+ || lk == 35871 // '$' 'after'
+ || lk == 35872 // '%' 'after'
+ || lk == 36116 // '{' 'after'
+ || lk == 36895 // '$' 'allowing'
+ || lk == 36896 // '%' 'allowing'
+ || lk == 37140 // '{' 'allowing'
+ || lk == 37407 // '$' 'ancestor'
+ || lk == 37408 // '%' 'ancestor'
+ || lk == 37652 // '{' 'ancestor'
+ || lk == 37919 // '$' 'ancestor-or-self'
+ || lk == 37920 // '%' 'ancestor-or-self'
+ || lk == 38164 // '{' 'ancestor-or-self'
+ || lk == 38431 // '$' 'and'
+ || lk == 38432 // '%' 'and'
+ || lk == 38676 // '{' 'and'
+ || lk == 39455 // '$' 'append'
+ || lk == 39456 // '%' 'append'
+ || lk == 39700 // '{' 'append'
+ || lk == 39967 // '$' 'array'
+ || lk == 39968 // '%' 'array'
+ || lk == 40212 // '{' 'array'
+ || lk == 40479 // '$' 'as'
+ || lk == 40480 // '%' 'as'
+ || lk == 40724 // '{' 'as'
+ || lk == 40991 // '$' 'ascending'
+ || lk == 40992 // '%' 'ascending'
+ || lk == 41236 // '{' 'ascending'
+ || lk == 41503 // '$' 'at'
+ || lk == 41504 // '%' 'at'
+ || lk == 41748 // '{' 'at'
+ || lk == 42015 // '$' 'attribute'
+ || lk == 42016 // '%' 'attribute'
+ || lk == 42260 // '{' 'attribute'
+ || lk == 42527 // '$' 'base-uri'
+ || lk == 42528 // '%' 'base-uri'
+ || lk == 42772 // '{' 'base-uri'
+ || lk == 43039 // '$' 'before'
+ || lk == 43040 // '%' 'before'
+ || lk == 43284 // '{' 'before'
+ || lk == 43551 // '$' 'boundary-space'
+ || lk == 43552 // '%' 'boundary-space'
+ || lk == 43796 // '{' 'boundary-space'
+ || lk == 44063 // '$' 'break'
+ || lk == 44064 // '%' 'break'
+ || lk == 44308 // '{' 'break'
+ || lk == 45087 // '$' 'case'
+ || lk == 45088 // '%' 'case'
+ || lk == 45332 // '{' 'case'
+ || lk == 45599 // '$' 'cast'
+ || lk == 45600 // '%' 'cast'
+ || lk == 45844 // '{' 'cast'
+ || lk == 46111 // '$' 'castable'
+ || lk == 46112 // '%' 'castable'
+ || lk == 46356 // '{' 'castable'
+ || lk == 46623 // '$' 'catch'
+ || lk == 46624 // '%' 'catch'
+ || lk == 46868 // '{' 'catch'
+ || lk == 47647 // '$' 'child'
+ || lk == 47648 // '%' 'child'
+ || lk == 47892 // '{' 'child'
+ || lk == 48159 // '$' 'collation'
+ || lk == 48160 // '%' 'collation'
+ || lk == 48404 // '{' 'collation'
+ || lk == 49183 // '$' 'comment'
+ || lk == 49184 // '%' 'comment'
+ || lk == 49428 // '{' 'comment'
+ || lk == 49695 // '$' 'constraint'
+ || lk == 49696 // '%' 'constraint'
+ || lk == 49940 // '{' 'constraint'
+ || lk == 50207 // '$' 'construction'
+ || lk == 50208 // '%' 'construction'
+ || lk == 50452 // '{' 'construction'
+ || lk == 51743 // '$' 'context'
+ || lk == 51744 // '%' 'context'
+ || lk == 51988 // '{' 'context'
+ || lk == 52255 // '$' 'continue'
+ || lk == 52256 // '%' 'continue'
+ || lk == 52500 // '{' 'continue'
+ || lk == 52767 // '$' 'copy'
+ || lk == 52768 // '%' 'copy'
+ || lk == 53012 // '{' 'copy'
+ || lk == 53279 // '$' 'copy-namespaces'
+ || lk == 53280 // '%' 'copy-namespaces'
+ || lk == 53524 // '{' 'copy-namespaces'
+ || lk == 53791 // '$' 'count'
+ || lk == 53792 // '%' 'count'
+ || lk == 54036 // '{' 'count'
+ || lk == 54303 // '$' 'decimal-format'
+ || lk == 54304 // '%' 'decimal-format'
+ || lk == 54548 // '{' 'decimal-format'
+ || lk == 55327 // '$' 'declare'
+ || lk == 55328 // '%' 'declare'
+ || lk == 55572 // '{' 'declare'
+ || lk == 55839 // '$' 'default'
+ || lk == 55840 // '%' 'default'
+ || lk == 56084 // '{' 'default'
+ || lk == 56351 // '$' 'delete'
+ || lk == 56352 // '%' 'delete'
+ || lk == 56596 // '{' 'delete'
+ || lk == 56863 // '$' 'descendant'
+ || lk == 56864 // '%' 'descendant'
+ || lk == 57108 // '{' 'descendant'
+ || lk == 57375 // '$' 'descendant-or-self'
+ || lk == 57376 // '%' 'descendant-or-self'
+ || lk == 57620 // '{' 'descendant-or-self'
+ || lk == 57887 // '$' 'descending'
+ || lk == 57888 // '%' 'descending'
+ || lk == 58132 // '{' 'descending'
+ || lk == 60447 // '$' 'div'
+ || lk == 60448 // '%' 'div'
+ || lk == 60692 // '{' 'div'
+ || lk == 60959 // '$' 'document'
+ || lk == 60960 // '%' 'document'
+ || lk == 61204 // '{' 'document'
+ || lk == 61471 // '$' 'document-node'
+ || lk == 61472 // '%' 'document-node'
+ || lk == 61716 // '{' 'document-node'
+ || lk == 61983 // '$' 'element'
+ || lk == 61984 // '%' 'element'
+ || lk == 62228 // '{' 'element'
+ || lk == 62495 // '$' 'else'
+ || lk == 62496 // '%' 'else'
+ || lk == 62740 // '{' 'else'
+ || lk == 63007 // '$' 'empty'
+ || lk == 63008 // '%' 'empty'
+ || lk == 63252 // '{' 'empty'
+ || lk == 63519 // '$' 'empty-sequence'
+ || lk == 63520 // '%' 'empty-sequence'
+ || lk == 63764 // '{' 'empty-sequence'
+ || lk == 64031 // '$' 'encoding'
+ || lk == 64032 // '%' 'encoding'
+ || lk == 64276 // '{' 'encoding'
+ || lk == 64543 // '$' 'end'
+ || lk == 64544 // '%' 'end'
+ || lk == 64788 // '{' 'end'
+ || lk == 65567 // '$' 'eq'
+ || lk == 65568 // '%' 'eq'
+ || lk == 65812 // '{' 'eq'
+ || lk == 66079 // '$' 'every'
+ || lk == 66080 // '%' 'every'
+ || lk == 66324 // '{' 'every'
+ || lk == 67103 // '$' 'except'
+ || lk == 67104 // '%' 'except'
+ || lk == 67348 // '{' 'except'
+ || lk == 67615 // '$' 'exit'
+ || lk == 67616 // '%' 'exit'
+ || lk == 67860 // '{' 'exit'
+ || lk == 68127 // '$' 'external'
+ || lk == 68128 // '%' 'external'
+ || lk == 68372 // '{' 'external'
+ || lk == 68639 // '$' 'first'
+ || lk == 68640 // '%' 'first'
+ || lk == 68884 // '{' 'first'
+ || lk == 69151 // '$' 'following'
+ || lk == 69152 // '%' 'following'
+ || lk == 69396 // '{' 'following'
+ || lk == 69663 // '$' 'following-sibling'
+ || lk == 69664 // '%' 'following-sibling'
+ || lk == 69908 // '{' 'following-sibling'
+ || lk == 70175 // '$' 'for'
+ || lk == 70176 // '%' 'for'
+ || lk == 70420 // '{' 'for'
+ || lk == 72223 // '$' 'ft-option'
+ || lk == 72224 // '%' 'ft-option'
+ || lk == 72468 // '{' 'ft-option'
+ || lk == 74271 // '$' 'function'
+ || lk == 74272 // '%' 'function'
+ || lk == 74516 // '{' 'function'
+ || lk == 74783 // '$' 'ge'
+ || lk == 74784 // '%' 'ge'
+ || lk == 75028 // '{' 'ge'
+ || lk == 75807 // '$' 'group'
+ || lk == 75808 // '%' 'group'
+ || lk == 76052 // '{' 'group'
+ || lk == 76831 // '$' 'gt'
+ || lk == 76832 // '%' 'gt'
+ || lk == 77076 // '{' 'gt'
+ || lk == 77343 // '$' 'idiv'
+ || lk == 77344 // '%' 'idiv'
+ || lk == 77588 // '{' 'idiv'
+ || lk == 77855 // '$' 'if'
+ || lk == 77856 // '%' 'if'
+ || lk == 78100 // '{' 'if'
+ || lk == 78367 // '$' 'import'
+ || lk == 78368 // '%' 'import'
+ || lk == 78612 // '{' 'import'
+ || lk == 78879 // '$' 'in'
+ || lk == 78880 // '%' 'in'
+ || lk == 79124 // '{' 'in'
+ || lk == 79391 // '$' 'index'
+ || lk == 79392 // '%' 'index'
+ || lk == 79636 // '{' 'index'
+ || lk == 81439 // '$' 'insert'
+ || lk == 81440 // '%' 'insert'
+ || lk == 81684 // '{' 'insert'
+ || lk == 81951 // '$' 'instance'
+ || lk == 81952 // '%' 'instance'
+ || lk == 82196 // '{' 'instance'
+ || lk == 82463 // '$' 'integrity'
+ || lk == 82464 // '%' 'integrity'
+ || lk == 82708 // '{' 'integrity'
+ || lk == 82975 // '$' 'intersect'
+ || lk == 82976 // '%' 'intersect'
+ || lk == 83220 // '{' 'intersect'
+ || lk == 83487 // '$' 'into'
+ || lk == 83488 // '%' 'into'
+ || lk == 83732 // '{' 'into'
+ || lk == 83999 // '$' 'is'
+ || lk == 84000 // '%' 'is'
+ || lk == 84244 // '{' 'is'
+ || lk == 84511 // '$' 'item'
+ || lk == 84512 // '%' 'item'
+ || lk == 84756 // '{' 'item'
+ || lk == 85023 // '$' 'json'
+ || lk == 85024 // '%' 'json'
+ || lk == 85268 // '{' 'json'
+ || lk == 85535 // '$' 'json-item'
+ || lk == 85536 // '%' 'json-item'
+ || lk == 85780 // '{' 'json-item'
+ || lk == 87071 // '$' 'last'
+ || lk == 87072 // '%' 'last'
+ || lk == 87316 // '{' 'last'
+ || lk == 87583 // '$' 'lax'
+ || lk == 87584 // '%' 'lax'
+ || lk == 87828 // '{' 'lax'
+ || lk == 88095 // '$' 'le'
+ || lk == 88096 // '%' 'le'
+ || lk == 88340 // '{' 'le'
+ || lk == 89119 // '$' 'let'
+ || lk == 89120 // '%' 'let'
+ || lk == 89364 // '{' 'let'
+ || lk == 90143 // '$' 'loop'
+ || lk == 90144 // '%' 'loop'
+ || lk == 90388 // '{' 'loop'
+ || lk == 91167 // '$' 'lt'
+ || lk == 91168 // '%' 'lt'
+ || lk == 91412 // '{' 'lt'
+ || lk == 92191 // '$' 'mod'
+ || lk == 92192 // '%' 'mod'
+ || lk == 92436 // '{' 'mod'
+ || lk == 92703 // '$' 'modify'
+ || lk == 92704 // '%' 'modify'
+ || lk == 92948 // '{' 'modify'
+ || lk == 93215 // '$' 'module'
+ || lk == 93216 // '%' 'module'
+ || lk == 93460 // '{' 'module'
+ || lk == 94239 // '$' 'namespace'
+ || lk == 94240 // '%' 'namespace'
+ || lk == 94484 // '{' 'namespace'
+ || lk == 94751 // '$' 'namespace-node'
+ || lk == 94752 // '%' 'namespace-node'
+ || lk == 94996 // '{' 'namespace-node'
+ || lk == 95263 // '$' 'ne'
+ || lk == 95264 // '%' 'ne'
+ || lk == 95508 // '{' 'ne'
+ || lk == 97823 // '$' 'node'
+ || lk == 97824 // '%' 'node'
+ || lk == 98068 // '{' 'node'
+ || lk == 98335 // '$' 'nodes'
+ || lk == 98336 // '%' 'nodes'
+ || lk == 98580 // '{' 'nodes'
+ || lk == 99359 // '$' 'object'
+ || lk == 99360 // '%' 'object'
+ || lk == 99604 // '{' 'object'
+ || lk == 101407 // '$' 'only'
+ || lk == 101408 // '%' 'only'
+ || lk == 101652 // '{' 'only'
+ || lk == 101919 // '$' 'option'
+ || lk == 101920 // '%' 'option'
+ || lk == 102164 // '{' 'option'
+ || lk == 102431 // '$' 'or'
+ || lk == 102432 // '%' 'or'
+ || lk == 102676 // '{' 'or'
+ || lk == 102943 // '$' 'order'
+ || lk == 102944 // '%' 'order'
+ || lk == 103188 // '{' 'order'
+ || lk == 103455 // '$' 'ordered'
+ || lk == 103456 // '%' 'ordered'
+ || lk == 103700 // '{' 'ordered'
+ || lk == 103967 // '$' 'ordering'
+ || lk == 103968 // '%' 'ordering'
+ || lk == 104212 // '{' 'ordering'
+ || lk == 105503 // '$' 'parent'
+ || lk == 105504 // '%' 'parent'
+ || lk == 105748 // '{' 'parent'
+ || lk == 108575 // '$' 'preceding'
+ || lk == 108576 // '%' 'preceding'
+ || lk == 108820 // '{' 'preceding'
+ || lk == 109087 // '$' 'preceding-sibling'
+ || lk == 109088 // '%' 'preceding-sibling'
+ || lk == 109332 // '{' 'preceding-sibling'
+ || lk == 110623 // '$' 'processing-instruction'
+ || lk == 110624 // '%' 'processing-instruction'
+ || lk == 110868 // '{' 'processing-instruction'
+ || lk == 111647 // '$' 'rename'
+ || lk == 111648 // '%' 'rename'
+ || lk == 111892 // '{' 'rename'
+ || lk == 112159 // '$' 'replace'
+ || lk == 112160 // '%' 'replace'
+ || lk == 112404 // '{' 'replace'
+ || lk == 112671 // '$' 'return'
+ || lk == 112672 // '%' 'return'
+ || lk == 112916 // '{' 'return'
+ || lk == 113183 // '$' 'returning'
+ || lk == 113184 // '%' 'returning'
+ || lk == 113428 // '{' 'returning'
+ || lk == 113695 // '$' 'revalidation'
+ || lk == 113696 // '%' 'revalidation'
+ || lk == 113940 // '{' 'revalidation'
+ || lk == 114719 // '$' 'satisfies'
+ || lk == 114720 // '%' 'satisfies'
+ || lk == 114964 // '{' 'satisfies'
+ || lk == 115231 // '$' 'schema'
+ || lk == 115232 // '%' 'schema'
+ || lk == 115476 // '{' 'schema'
+ || lk == 115743 // '$' 'schema-attribute'
+ || lk == 115744 // '%' 'schema-attribute'
+ || lk == 115988 // '{' 'schema-attribute'
+ || lk == 116255 // '$' 'schema-element'
+ || lk == 116256 // '%' 'schema-element'
+ || lk == 116500 // '{' 'schema-element'
+ || lk == 116767 // '$' 'score'
+ || lk == 116768 // '%' 'score'
+ || lk == 117012 // '{' 'score'
+ || lk == 117279 // '$' 'self'
+ || lk == 117280 // '%' 'self'
+ || lk == 117524 // '{' 'self'
+ || lk == 119839 // '$' 'sliding'
+ || lk == 119840 // '%' 'sliding'
+ || lk == 120084 // '{' 'sliding'
+ || lk == 120351 // '$' 'some'
+ || lk == 120352 // '%' 'some'
+ || lk == 120596 // '{' 'some'
+ || lk == 120863 // '$' 'stable'
+ || lk == 120864 // '%' 'stable'
+ || lk == 121108 // '{' 'stable'
+ || lk == 121375 // '$' 'start'
+ || lk == 121376 // '%' 'start'
+ || lk == 121620 // '{' 'start'
+ || lk == 122911 // '$' 'strict'
+ || lk == 122912 // '%' 'strict'
+ || lk == 123156 // '{' 'strict'
+ || lk == 123935 // '$' 'structured-item'
+ || lk == 123936 // '%' 'structured-item'
+ || lk == 124180 // '{' 'structured-item'
+ || lk == 124447 // '$' 'switch'
+ || lk == 124448 // '%' 'switch'
+ || lk == 124692 // '{' 'switch'
+ || lk == 124959 // '$' 'text'
+ || lk == 124960 // '%' 'text'
+ || lk == 125204 // '{' 'text'
+ || lk == 127007 // '$' 'to'
+ || lk == 127008 // '%' 'to'
+ || lk == 127252 // '{' 'to'
+ || lk == 127519 // '$' 'treat'
+ || lk == 127520 // '%' 'treat'
+ || lk == 127764 // '{' 'treat'
+ || lk == 128031 // '$' 'try'
+ || lk == 128032 // '%' 'try'
+ || lk == 128276 // '{' 'try'
+ || lk == 128543 // '$' 'tumbling'
+ || lk == 128544 // '%' 'tumbling'
+ || lk == 128788 // '{' 'tumbling'
+ || lk == 129055 // '$' 'type'
+ || lk == 129056 // '%' 'type'
+ || lk == 129300 // '{' 'type'
+ || lk == 129567 // '$' 'typeswitch'
+ || lk == 129568 // '%' 'typeswitch'
+ || lk == 129812 // '{' 'typeswitch'
+ || lk == 130079 // '$' 'union'
+ || lk == 130080 // '%' 'union'
+ || lk == 130324 // '{' 'union'
+ || lk == 131103 // '$' 'unordered'
+ || lk == 131104 // '%' 'unordered'
+ || lk == 131348 // '{' 'unordered'
+ || lk == 131615 // '$' 'updating'
+ || lk == 131616 // '%' 'updating'
+ || lk == 131860 // '{' 'updating'
+ || lk == 133151 // '$' 'validate'
+ || lk == 133152 // '%' 'validate'
+ || lk == 133396 // '{' 'validate'
+ || lk == 133663 // '$' 'value'
+ || lk == 133664 // '%' 'value'
+ || lk == 133908 // '{' 'value'
+ || lk == 134175 // '$' 'variable'
+ || lk == 134176 // '%' 'variable'
+ || lk == 134420 // '{' 'variable'
+ || lk == 134687 // '$' 'version'
+ || lk == 134688 // '%' 'version'
+ || lk == 134932 // '{' 'version'
+ || lk == 136223 // '$' 'where'
+ || lk == 136224 // '%' 'where'
+ || lk == 136468 // '{' 'where'
+ || lk == 136735 // '$' 'while'
+ || lk == 136736 // '%' 'while'
+ || lk == 136980 // '{' 'while'
+ || lk == 138271 // '$' 'with'
+ || lk == 138272 // '%' 'with'
+ || lk == 138516 // '{' 'with'
+ || lk == 140319 // '$' 'xquery'
+ || lk == 140320 // '%' 'xquery'
+ || lk == 140564 // '{' 'xquery'
+ || lk == 141588 // '{' '{'
+ || lk == 142612 // '{' '{|'
+ || lk == 144660) // '{' '}'
+ {
+ lk = memoized(7, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ApplyStatement();
+ memoize(7, e0A, -1);
+ lk = -15;
+ }
+ catch (p1A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_AssignStatement();
+ memoize(7, e0A, -2);
+ lk = -15;
+ }
+ catch (p2A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_BlockStatement();
+ memoize(7, e0A, -3);
+ lk = -15;
+ }
+ catch (p3A)
+ {
+ try
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ try_VarDeclStatement();
+ memoize(7, e0A, -12);
+ lk = -15;
+ }
+ catch (p12A)
+ {
+ lk = -13;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(7, e0A, -13);
+ }
+ }
+ }
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -2:
+ try_AssignStatement();
+ break;
+ case -3:
+ try_BlockStatement();
+ break;
+ case 90198: // 'break' 'loop'
+ try_BreakStatement();
+ break;
+ case 90214: // 'continue' 'loop'
+ try_ContinueStatement();
+ break;
+ case 113284: // 'exit' 'returning'
+ try_ExitStatement();
+ break;
+ case 16009: // 'for' '$'
+ case 16046: // 'let' '$'
+ case 116910: // 'let' 'score'
+ case 119945: // 'for' 'sliding'
+ case 128649: // 'for' 'tumbling'
+ try_FLWORStatement();
+ break;
+ case 17560: // 'if' '('
+ try_IfStatement();
+ break;
+ case 17651: // 'switch' '('
+ try_SwitchStatement();
+ break;
+ case 141562: // 'try' '{'
+ try_TryCatchStatement();
+ break;
+ case 17661: // 'typeswitch' '('
+ try_TypeswitchStatement();
+ break;
+ case -12:
+ case 16134: // 'variable' '$'
+ try_VarDeclStatement();
+ break;
+ case -13:
+ try_WhileStatement();
+ break;
+ case 53: // ';'
+ try_VoidStatement();
+ break;
+ case -15:
+ break;
+ default:
+ try_ApplyStatement();
+ }
+ }
+
+ function parse_ApplyStatement()
+ {
+ eventHandler.startNonterminal("ApplyStatement", e0);
+ parse_ExprSimple();
+ shift(53); // ';'
+ eventHandler.endNonterminal("ApplyStatement", e0);
+ }
+
+ function try_ApplyStatement()
+ {
+ try_ExprSimple();
+ shiftT(53); // ';'
+ }
+
+ function parse_AssignStatement()
+ {
+ eventHandler.startNonterminal("AssignStatement", e0);
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(53); // ';'
+ eventHandler.endNonterminal("AssignStatement", e0);
+ }
+
+ function try_AssignStatement()
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(27); // S^WS | '(:' | ':='
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(53); // ';'
+ }
+
+ function parse_BlockStatement()
+ {
+ eventHandler.startNonterminal("BlockStatement", e0);
+ shift(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statements();
+ shift(282); // '}'
+ eventHandler.endNonterminal("BlockStatement", e0);
+ }
+
+ function try_BlockStatement()
+ {
+ shiftT(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statements();
+ shiftT(282); // '}'
+ }
+
+ function parse_BreakStatement()
+ {
+ eventHandler.startNonterminal("BreakStatement", e0);
+ shift(86); // 'break'
+ lookahead1W(59); // S^WS | '(:' | 'loop'
+ shift(176); // 'loop'
+ lookahead1W(28); // S^WS | '(:' | ';'
+ shift(53); // ';'
+ eventHandler.endNonterminal("BreakStatement", e0);
+ }
+
+ function try_BreakStatement()
+ {
+ shiftT(86); // 'break'
+ lookahead1W(59); // S^WS | '(:' | 'loop'
+ shiftT(176); // 'loop'
+ lookahead1W(28); // S^WS | '(:' | ';'
+ shiftT(53); // ';'
+ }
+
+ function parse_ContinueStatement()
+ {
+ eventHandler.startNonterminal("ContinueStatement", e0);
+ shift(102); // 'continue'
+ lookahead1W(59); // S^WS | '(:' | 'loop'
+ shift(176); // 'loop'
+ lookahead1W(28); // S^WS | '(:' | ';'
+ shift(53); // ';'
+ eventHandler.endNonterminal("ContinueStatement", e0);
+ }
+
+ function try_ContinueStatement()
+ {
+ shiftT(102); // 'continue'
+ lookahead1W(59); // S^WS | '(:' | 'loop'
+ shiftT(176); // 'loop'
+ lookahead1W(28); // S^WS | '(:' | ';'
+ shiftT(53); // ';'
+ }
+
+ function parse_ExitStatement()
+ {
+ eventHandler.startNonterminal("ExitStatement", e0);
+ shift(132); // 'exit'
+ lookahead1W(71); // S^WS | '(:' | 'returning'
+ shift(221); // 'returning'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(53); // ';'
+ eventHandler.endNonterminal("ExitStatement", e0);
+ }
+
+ function try_ExitStatement()
+ {
+ shiftT(132); // 'exit'
+ lookahead1W(71); // S^WS | '(:' | 'returning'
+ shiftT(221); // 'returning'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(53); // ';'
+ }
+
+ function parse_FLWORStatement()
+ {
+ eventHandler.startNonterminal("FLWORStatement", e0);
+ parse_InitialClause();
+ for (;;)
+ {
+ lookahead1W(173); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 220) // 'return'
+ {
+ break;
+ }
+ whitespace();
+ parse_IntermediateClause();
+ }
+ whitespace();
+ parse_ReturnStatement();
+ eventHandler.endNonterminal("FLWORStatement", e0);
+ }
+
+ function try_FLWORStatement()
+ {
+ try_InitialClause();
+ for (;;)
+ {
+ lookahead1W(173); // S^WS | '(:' | 'count' | 'for' | 'group' | 'let' | 'order' | 'return' | 'stable' |
+ if (l1 == 220) // 'return'
+ {
+ break;
+ }
+ try_IntermediateClause();
+ }
+ try_ReturnStatement();
+ }
+
+ function parse_ReturnStatement()
+ {
+ eventHandler.startNonterminal("ReturnStatement", e0);
+ shift(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("ReturnStatement", e0);
+ }
+
+ function try_ReturnStatement()
+ {
+ shiftT(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_IfStatement()
+ {
+ eventHandler.startNonterminal("IfStatement", e0);
+ shift(152); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ lookahead1W(77); // S^WS | '(:' | 'then'
+ shift(245); // 'then'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ lookahead1W(48); // S^WS | '(:' | 'else'
+ shift(122); // 'else'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("IfStatement", e0);
+ }
+
+ function try_IfStatement()
+ {
+ shiftT(152); // 'if'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ lookahead1W(77); // S^WS | '(:' | 'then'
+ shiftT(245); // 'then'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ lookahead1W(48); // S^WS | '(:' | 'else'
+ shiftT(122); // 'else'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_SwitchStatement()
+ {
+ eventHandler.startNonterminal("SwitchStatement", e0);
+ shift(243); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_SwitchCaseStatement();
+ lookahead1W(113); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shift(109); // 'default'
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shift(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("SwitchStatement", e0);
+ }
+
+ function try_SwitchStatement()
+ {
+ shiftT(243); // 'switch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ try_SwitchCaseStatement();
+ lookahead1W(113); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(109); // 'default'
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shiftT(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_SwitchCaseStatement()
+ {
+ eventHandler.startNonterminal("SwitchCaseStatement", e0);
+ for (;;)
+ {
+ shift(88); // 'case'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_SwitchCaseOperand();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shift(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("SwitchCaseStatement", e0);
+ }
+
+ function try_SwitchCaseStatement()
+ {
+ for (;;)
+ {
+ shiftT(88); // 'case'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_SwitchCaseOperand();
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_TryCatchStatement()
+ {
+ eventHandler.startNonterminal("TryCatchStatement", e0);
+ shift(250); // 'try'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockStatement();
+ for (;;)
+ {
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ shift(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_CatchErrorList();
+ whitespace();
+ parse_BlockStatement();
+ lookahead1W(277); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 91: // 'catch'
+ lookahead2W(278); // Wildcard | EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 38491 // 'catch' 'and'
+ || lk == 45659 // 'catch' 'cast'
+ || lk == 46171 // 'catch' 'castable'
+ || lk == 60507 // 'catch' 'div'
+ || lk == 65627 // 'catch' 'eq'
+ || lk == 67163 // 'catch' 'except'
+ || lk == 74843 // 'catch' 'ge'
+ || lk == 76891 // 'catch' 'gt'
+ || lk == 77403 // 'catch' 'idiv'
+ || lk == 82011 // 'catch' 'instance'
+ || lk == 83035 // 'catch' 'intersect'
+ || lk == 84059 // 'catch' 'is'
+ || lk == 88155 // 'catch' 'le'
+ || lk == 91227 // 'catch' 'lt'
+ || lk == 92251 // 'catch' 'mod'
+ || lk == 95323 // 'catch' 'ne'
+ || lk == 102491 // 'catch' 'or'
+ || lk == 127067 // 'catch' 'to'
+ || lk == 127579 // 'catch' 'treat'
+ || lk == 130139) // 'catch' 'union'
+ {
+ lk = memoized(8, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ shiftT(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ try_BlockStatement();
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(8, e0, lk);
+ }
+ }
+ if (lk != -1
+ && lk != 2651 // 'catch' Wildcard
+ && lk != 3163 // 'catch' EQName^Token
+ && lk != 35931 // 'catch' 'after'
+ && lk != 36955 // 'catch' 'allowing'
+ && lk != 37467 // 'catch' 'ancestor'
+ && lk != 37979 // 'catch' 'ancestor-or-self'
+ && lk != 39515 // 'catch' 'append'
+ && lk != 40027 // 'catch' 'array'
+ && lk != 40539 // 'catch' 'as'
+ && lk != 41051 // 'catch' 'ascending'
+ && lk != 41563 // 'catch' 'at'
+ && lk != 42075 // 'catch' 'attribute'
+ && lk != 42587 // 'catch' 'base-uri'
+ && lk != 43099 // 'catch' 'before'
+ && lk != 43611 // 'catch' 'boundary-space'
+ && lk != 44123 // 'catch' 'break'
+ && lk != 45147 // 'catch' 'case'
+ && lk != 46683 // 'catch' 'catch'
+ && lk != 47707 // 'catch' 'child'
+ && lk != 48219 // 'catch' 'collation'
+ && lk != 49243 // 'catch' 'comment'
+ && lk != 49755 // 'catch' 'constraint'
+ && lk != 50267 // 'catch' 'construction'
+ && lk != 51803 // 'catch' 'context'
+ && lk != 52315 // 'catch' 'continue'
+ && lk != 52827 // 'catch' 'copy'
+ && lk != 53339 // 'catch' 'copy-namespaces'
+ && lk != 53851 // 'catch' 'count'
+ && lk != 54363 // 'catch' 'decimal-format'
+ && lk != 55387 // 'catch' 'declare'
+ && lk != 55899 // 'catch' 'default'
+ && lk != 56411 // 'catch' 'delete'
+ && lk != 56923 // 'catch' 'descendant'
+ && lk != 57435 // 'catch' 'descendant-or-self'
+ && lk != 57947 // 'catch' 'descending'
+ && lk != 61019 // 'catch' 'document'
+ && lk != 61531 // 'catch' 'document-node'
+ && lk != 62043 // 'catch' 'element'
+ && lk != 62555 // 'catch' 'else'
+ && lk != 63067 // 'catch' 'empty'
+ && lk != 63579 // 'catch' 'empty-sequence'
+ && lk != 64091 // 'catch' 'encoding'
+ && lk != 64603 // 'catch' 'end'
+ && lk != 66139 // 'catch' 'every'
+ && lk != 67675 // 'catch' 'exit'
+ && lk != 68187 // 'catch' 'external'
+ && lk != 68699 // 'catch' 'first'
+ && lk != 69211 // 'catch' 'following'
+ && lk != 69723 // 'catch' 'following-sibling'
+ && lk != 70235 // 'catch' 'for'
+ && lk != 72283 // 'catch' 'ft-option'
+ && lk != 74331 // 'catch' 'function'
+ && lk != 75867 // 'catch' 'group'
+ && lk != 77915 // 'catch' 'if'
+ && lk != 78427 // 'catch' 'import'
+ && lk != 78939 // 'catch' 'in'
+ && lk != 79451 // 'catch' 'index'
+ && lk != 81499 // 'catch' 'insert'
+ && lk != 82523 // 'catch' 'integrity'
+ && lk != 83547 // 'catch' 'into'
+ && lk != 84571 // 'catch' 'item'
+ && lk != 85083 // 'catch' 'json'
+ && lk != 85595 // 'catch' 'json-item'
+ && lk != 87131 // 'catch' 'last'
+ && lk != 87643 // 'catch' 'lax'
+ && lk != 89179 // 'catch' 'let'
+ && lk != 90203 // 'catch' 'loop'
+ && lk != 92763 // 'catch' 'modify'
+ && lk != 93275 // 'catch' 'module'
+ && lk != 94299 // 'catch' 'namespace'
+ && lk != 94811 // 'catch' 'namespace-node'
+ && lk != 97883 // 'catch' 'node'
+ && lk != 98395 // 'catch' 'nodes'
+ && lk != 99419 // 'catch' 'object'
+ && lk != 101467 // 'catch' 'only'
+ && lk != 101979 // 'catch' 'option'
+ && lk != 103003 // 'catch' 'order'
+ && lk != 103515 // 'catch' 'ordered'
+ && lk != 104027 // 'catch' 'ordering'
+ && lk != 105563 // 'catch' 'parent'
+ && lk != 108635 // 'catch' 'preceding'
+ && lk != 109147 // 'catch' 'preceding-sibling'
+ && lk != 110683 // 'catch' 'processing-instruction'
+ && lk != 111707 // 'catch' 'rename'
+ && lk != 112219 // 'catch' 'replace'
+ && lk != 112731 // 'catch' 'return'
+ && lk != 113243 // 'catch' 'returning'
+ && lk != 113755 // 'catch' 'revalidation'
+ && lk != 114779 // 'catch' 'satisfies'
+ && lk != 115291 // 'catch' 'schema'
+ && lk != 115803 // 'catch' 'schema-attribute'
+ && lk != 116315 // 'catch' 'schema-element'
+ && lk != 116827 // 'catch' 'score'
+ && lk != 117339 // 'catch' 'self'
+ && lk != 119899 // 'catch' 'sliding'
+ && lk != 120411 // 'catch' 'some'
+ && lk != 120923 // 'catch' 'stable'
+ && lk != 121435 // 'catch' 'start'
+ && lk != 122971 // 'catch' 'strict'
+ && lk != 123995 // 'catch' 'structured-item'
+ && lk != 124507 // 'catch' 'switch'
+ && lk != 125019 // 'catch' 'text'
+ && lk != 128091 // 'catch' 'try'
+ && lk != 128603 // 'catch' 'tumbling'
+ && lk != 129115 // 'catch' 'type'
+ && lk != 129627 // 'catch' 'typeswitch'
+ && lk != 131163 // 'catch' 'unordered'
+ && lk != 131675 // 'catch' 'updating'
+ && lk != 133211 // 'catch' 'validate'
+ && lk != 133723 // 'catch' 'value'
+ && lk != 134235 // 'catch' 'variable'
+ && lk != 134747 // 'catch' 'version'
+ && lk != 136283 // 'catch' 'where'
+ && lk != 136795 // 'catch' 'while'
+ && lk != 138331 // 'catch' 'with'
+ && lk != 140379) // 'catch' 'xquery'
+ {
+ break;
+ }
+ }
+ eventHandler.endNonterminal("TryCatchStatement", e0);
+ }
+
+ function try_TryCatchStatement()
+ {
+ shiftT(250); // 'try'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ try_BlockStatement();
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ shiftT(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ try_BlockStatement();
+ for (;;)
+ {
+ lookahead1W(277); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ switch (l1)
+ {
+ case 91: // 'catch'
+ lookahead2W(278); // Wildcard | EQName^Token | S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | '*' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 38491 // 'catch' 'and'
+ || lk == 45659 // 'catch' 'cast'
+ || lk == 46171 // 'catch' 'castable'
+ || lk == 60507 // 'catch' 'div'
+ || lk == 65627 // 'catch' 'eq'
+ || lk == 67163 // 'catch' 'except'
+ || lk == 74843 // 'catch' 'ge'
+ || lk == 76891 // 'catch' 'gt'
+ || lk == 77403 // 'catch' 'idiv'
+ || lk == 82011 // 'catch' 'instance'
+ || lk == 83035 // 'catch' 'intersect'
+ || lk == 84059 // 'catch' 'is'
+ || lk == 88155 // 'catch' 'le'
+ || lk == 91227 // 'catch' 'lt'
+ || lk == 92251 // 'catch' 'mod'
+ || lk == 95323 // 'catch' 'ne'
+ || lk == 102491 // 'catch' 'or'
+ || lk == 127067 // 'catch' 'to'
+ || lk == 127579 // 'catch' 'treat'
+ || lk == 130139) // 'catch' 'union'
+ {
+ lk = memoized(8, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ shiftT(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ try_BlockStatement();
+ memoize(8, e0A, -1);
+ continue;
+ }
+ catch (p1A)
+ {
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(8, e0A, -2);
+ break;
+ }
+ }
+ }
+ if (lk != -1
+ && lk != 2651 // 'catch' Wildcard
+ && lk != 3163 // 'catch' EQName^Token
+ && lk != 35931 // 'catch' 'after'
+ && lk != 36955 // 'catch' 'allowing'
+ && lk != 37467 // 'catch' 'ancestor'
+ && lk != 37979 // 'catch' 'ancestor-or-self'
+ && lk != 39515 // 'catch' 'append'
+ && lk != 40027 // 'catch' 'array'
+ && lk != 40539 // 'catch' 'as'
+ && lk != 41051 // 'catch' 'ascending'
+ && lk != 41563 // 'catch' 'at'
+ && lk != 42075 // 'catch' 'attribute'
+ && lk != 42587 // 'catch' 'base-uri'
+ && lk != 43099 // 'catch' 'before'
+ && lk != 43611 // 'catch' 'boundary-space'
+ && lk != 44123 // 'catch' 'break'
+ && lk != 45147 // 'catch' 'case'
+ && lk != 46683 // 'catch' 'catch'
+ && lk != 47707 // 'catch' 'child'
+ && lk != 48219 // 'catch' 'collation'
+ && lk != 49243 // 'catch' 'comment'
+ && lk != 49755 // 'catch' 'constraint'
+ && lk != 50267 // 'catch' 'construction'
+ && lk != 51803 // 'catch' 'context'
+ && lk != 52315 // 'catch' 'continue'
+ && lk != 52827 // 'catch' 'copy'
+ && lk != 53339 // 'catch' 'copy-namespaces'
+ && lk != 53851 // 'catch' 'count'
+ && lk != 54363 // 'catch' 'decimal-format'
+ && lk != 55387 // 'catch' 'declare'
+ && lk != 55899 // 'catch' 'default'
+ && lk != 56411 // 'catch' 'delete'
+ && lk != 56923 // 'catch' 'descendant'
+ && lk != 57435 // 'catch' 'descendant-or-self'
+ && lk != 57947 // 'catch' 'descending'
+ && lk != 61019 // 'catch' 'document'
+ && lk != 61531 // 'catch' 'document-node'
+ && lk != 62043 // 'catch' 'element'
+ && lk != 62555 // 'catch' 'else'
+ && lk != 63067 // 'catch' 'empty'
+ && lk != 63579 // 'catch' 'empty-sequence'
+ && lk != 64091 // 'catch' 'encoding'
+ && lk != 64603 // 'catch' 'end'
+ && lk != 66139 // 'catch' 'every'
+ && lk != 67675 // 'catch' 'exit'
+ && lk != 68187 // 'catch' 'external'
+ && lk != 68699 // 'catch' 'first'
+ && lk != 69211 // 'catch' 'following'
+ && lk != 69723 // 'catch' 'following-sibling'
+ && lk != 70235 // 'catch' 'for'
+ && lk != 72283 // 'catch' 'ft-option'
+ && lk != 74331 // 'catch' 'function'
+ && lk != 75867 // 'catch' 'group'
+ && lk != 77915 // 'catch' 'if'
+ && lk != 78427 // 'catch' 'import'
+ && lk != 78939 // 'catch' 'in'
+ && lk != 79451 // 'catch' 'index'
+ && lk != 81499 // 'catch' 'insert'
+ && lk != 82523 // 'catch' 'integrity'
+ && lk != 83547 // 'catch' 'into'
+ && lk != 84571 // 'catch' 'item'
+ && lk != 85083 // 'catch' 'json'
+ && lk != 85595 // 'catch' 'json-item'
+ && lk != 87131 // 'catch' 'last'
+ && lk != 87643 // 'catch' 'lax'
+ && lk != 89179 // 'catch' 'let'
+ && lk != 90203 // 'catch' 'loop'
+ && lk != 92763 // 'catch' 'modify'
+ && lk != 93275 // 'catch' 'module'
+ && lk != 94299 // 'catch' 'namespace'
+ && lk != 94811 // 'catch' 'namespace-node'
+ && lk != 97883 // 'catch' 'node'
+ && lk != 98395 // 'catch' 'nodes'
+ && lk != 99419 // 'catch' 'object'
+ && lk != 101467 // 'catch' 'only'
+ && lk != 101979 // 'catch' 'option'
+ && lk != 103003 // 'catch' 'order'
+ && lk != 103515 // 'catch' 'ordered'
+ && lk != 104027 // 'catch' 'ordering'
+ && lk != 105563 // 'catch' 'parent'
+ && lk != 108635 // 'catch' 'preceding'
+ && lk != 109147 // 'catch' 'preceding-sibling'
+ && lk != 110683 // 'catch' 'processing-instruction'
+ && lk != 111707 // 'catch' 'rename'
+ && lk != 112219 // 'catch' 'replace'
+ && lk != 112731 // 'catch' 'return'
+ && lk != 113243 // 'catch' 'returning'
+ && lk != 113755 // 'catch' 'revalidation'
+ && lk != 114779 // 'catch' 'satisfies'
+ && lk != 115291 // 'catch' 'schema'
+ && lk != 115803 // 'catch' 'schema-attribute'
+ && lk != 116315 // 'catch' 'schema-element'
+ && lk != 116827 // 'catch' 'score'
+ && lk != 117339 // 'catch' 'self'
+ && lk != 119899 // 'catch' 'sliding'
+ && lk != 120411 // 'catch' 'some'
+ && lk != 120923 // 'catch' 'stable'
+ && lk != 121435 // 'catch' 'start'
+ && lk != 122971 // 'catch' 'strict'
+ && lk != 123995 // 'catch' 'structured-item'
+ && lk != 124507 // 'catch' 'switch'
+ && lk != 125019 // 'catch' 'text'
+ && lk != 128091 // 'catch' 'try'
+ && lk != 128603 // 'catch' 'tumbling'
+ && lk != 129115 // 'catch' 'type'
+ && lk != 129627 // 'catch' 'typeswitch'
+ && lk != 131163 // 'catch' 'unordered'
+ && lk != 131675 // 'catch' 'updating'
+ && lk != 133211 // 'catch' 'validate'
+ && lk != 133723 // 'catch' 'value'
+ && lk != 134235 // 'catch' 'variable'
+ && lk != 134747 // 'catch' 'version'
+ && lk != 136283 // 'catch' 'where'
+ && lk != 136795 // 'catch' 'while'
+ && lk != 138331 // 'catch' 'with'
+ && lk != 140379) // 'catch' 'xquery'
+ {
+ break;
+ }
+ lookahead1W(36); // S^WS | '(:' | 'catch'
+ shiftT(91); // 'catch'
+ lookahead1W(256); // Wildcard | EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_CatchErrorList();
+ try_BlockStatement();
+ }
+ }
+
+ function parse_TypeswitchStatement()
+ {
+ eventHandler.startNonterminal("TypeswitchStatement", e0);
+ shift(253); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ whitespace();
+ parse_CaseStatement();
+ lookahead1W(113); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shift(109); // 'default'
+ lookahead1W(95); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ }
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shift(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("TypeswitchStatement", e0);
+ }
+
+ function try_TypeswitchStatement()
+ {
+ shiftT(253); // 'typeswitch'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ for (;;)
+ {
+ lookahead1W(35); // S^WS | '(:' | 'case'
+ try_CaseStatement();
+ lookahead1W(113); // S^WS | '(:' | 'case' | 'default'
+ if (l1 != 88) // 'case'
+ {
+ break;
+ }
+ }
+ shiftT(109); // 'default'
+ lookahead1W(95); // S^WS | '$' | '(:' | 'return'
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ }
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shiftT(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_CaseStatement()
+ {
+ eventHandler.startNonterminal("CaseStatement", e0);
+ shift(88); // 'case'
+ lookahead1W(261); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shift(79); // 'as'
+ }
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shift(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("CaseStatement", e0);
+ }
+
+ function try_CaseStatement()
+ {
+ shiftT(88); // 'case'
+ lookahead1W(261); // EQName^Token | S^WS | '$' | '%' | '(' | '(:' | 'after' | 'allowing' |
+ if (l1 == 31) // '$'
+ {
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(30); // S^WS | '(:' | 'as'
+ shiftT(79); // 'as'
+ }
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_SequenceType();
+ lookahead1W(70); // S^WS | '(:' | 'return'
+ shiftT(220); // 'return'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_VarDeclStatement()
+ {
+ eventHandler.startNonterminal("VarDeclStatement", e0);
+ for (;;)
+ {
+ lookahead1W(98); // S^WS | '%' | '(:' | 'variable'
+ if (l1 != 32) // '%'
+ {
+ break;
+ }
+ whitespace();
+ parse_Annotation();
+ }
+ shift(262); // 'variable'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(157); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(145); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 52) // ':='
+ {
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shift(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_VarName();
+ lookahead1W(157); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_TypeDeclaration();
+ }
+ lookahead1W(145); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 52) // ':='
+ {
+ shift(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ }
+ shift(53); // ';'
+ eventHandler.endNonterminal("VarDeclStatement", e0);
+ }
+
+ function try_VarDeclStatement()
+ {
+ for (;;)
+ {
+ lookahead1W(98); // S^WS | '%' | '(:' | 'variable'
+ if (l1 != 32) // '%'
+ {
+ break;
+ }
+ try_Annotation();
+ }
+ shiftT(262); // 'variable'
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(157); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(145); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 52) // ':='
+ {
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(21); // S^WS | '$' | '(:'
+ shiftT(31); // '$'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ try_VarName();
+ lookahead1W(157); // S^WS | '(:' | ',' | ':=' | ';' | 'as'
+ if (l1 == 79) // 'as'
+ {
+ try_TypeDeclaration();
+ }
+ lookahead1W(145); // S^WS | '(:' | ',' | ':=' | ';'
+ if (l1 == 52) // ':='
+ {
+ shiftT(52); // ':='
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ }
+ shiftT(53); // ';'
+ }
+
+ function parse_WhileStatement()
+ {
+ eventHandler.startNonterminal("WhileStatement", e0);
+ shift(267); // 'while'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(37); // ')'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Statement();
+ eventHandler.endNonterminal("WhileStatement", e0);
+ }
+
+ function try_WhileStatement()
+ {
+ shiftT(267); // 'while'
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shiftT(34); // '('
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(37); // ')'
+ lookahead1W(269); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Statement();
+ }
+
+ function parse_VoidStatement()
+ {
+ eventHandler.startNonterminal("VoidStatement", e0);
+ shift(53); // ';'
+ eventHandler.endNonterminal("VoidStatement", e0);
+ }
+
+ function try_VoidStatement()
+ {
+ shiftT(53); // ';'
+ }
+
+ function parse_ExprSingle()
+ {
+ eventHandler.startNonterminal("ExprSingle", e0);
+ switch (l1)
+ {
+ case 137: // 'for'
+ lookahead2W(235); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' |
+ break;
+ case 174: // 'let'
+ lookahead2W(232); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' |
+ break;
+ case 250: // 'try'
+ lookahead2W(231); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 152: // 'if'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ lookahead2W(228); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16009: // 'for' '$'
+ case 16046: // 'let' '$'
+ case 116910: // 'let' 'score'
+ case 119945: // 'for' 'sliding'
+ case 128649: // 'for' 'tumbling'
+ parse_FLWORExpr();
+ break;
+ case 17560: // 'if' '('
+ parse_IfExpr();
+ break;
+ case 17651: // 'switch' '('
+ parse_SwitchExpr();
+ break;
+ case 141562: // 'try' '{'
+ parse_TryCatchExpr();
+ break;
+ case 17661: // 'typeswitch' '('
+ parse_TypeswitchExpr();
+ break;
+ default:
+ parse_ExprSimple();
+ }
+ eventHandler.endNonterminal("ExprSingle", e0);
+ }
+
+ function try_ExprSingle()
+ {
+ switch (l1)
+ {
+ case 137: // 'for'
+ lookahead2W(235); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' |
+ break;
+ case 174: // 'let'
+ lookahead2W(232); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' |
+ break;
+ case 250: // 'try'
+ lookahead2W(231); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 152: // 'if'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ lookahead2W(228); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ default:
+ lk = l1;
+ }
+ switch (lk)
+ {
+ case 16009: // 'for' '$'
+ case 16046: // 'let' '$'
+ case 116910: // 'let' 'score'
+ case 119945: // 'for' 'sliding'
+ case 128649: // 'for' 'tumbling'
+ try_FLWORExpr();
+ break;
+ case 17560: // 'if' '('
+ try_IfExpr();
+ break;
+ case 17651: // 'switch' '('
+ try_SwitchExpr();
+ break;
+ case 141562: // 'try' '{'
+ try_TryCatchExpr();
+ break;
+ case 17661: // 'typeswitch' '('
+ try_TypeswitchExpr();
+ break;
+ default:
+ try_ExprSimple();
+ }
+ }
+
+ function parse_ExprSimple()
+ {
+ eventHandler.startNonterminal("ExprSimple", e0);
+ switch (l1)
+ {
+ case 77: // 'append'
+ lookahead2W(230); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 218: // 'rename'
+ lookahead2W(233); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 219: // 'replace'
+ lookahead2W(234); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 110: // 'delete'
+ case 159: // 'insert'
+ lookahead2W(236); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 103: // 'copy'
+ case 129: // 'every'
+ case 235: // 'some'
+ lookahead2W(229); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 133851) // 'replace' 'value'
+ {
+ lk = memoized(9, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ReplaceExpr();
+ lk = -6;
+ }
+ catch (p6A)
+ {
+ lk = -11;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(9, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 16001: // 'every' '$'
+ case 16107: // 'some' '$'
+ parse_QuantifiedExpr();
+ break;
+ case 97951: // 'insert' 'node'
+ case 98463: // 'insert' 'nodes'
+ parse_InsertExpr();
+ break;
+ case 97902: // 'delete' 'node'
+ case 98414: // 'delete' 'nodes'
+ parse_DeleteExpr();
+ break;
+ case 98010: // 'rename' 'node'
+ parse_RenameExpr();
+ break;
+ case -6:
+ case 98011: // 'replace' 'node'
+ parse_ReplaceExpr();
+ break;
+ case 15975: // 'copy' '$'
+ parse_TransformExpr();
+ break;
+ case 85102: // 'delete' 'json'
+ parse_JSONDeleteExpr();
+ break;
+ case 85151: // 'insert' 'json'
+ parse_JSONInsertExpr();
+ break;
+ case 85210: // 'rename' 'json'
+ parse_JSONRenameExpr();
+ break;
+ case -11:
+ parse_JSONReplaceExpr();
+ break;
+ case 85069: // 'append' 'json'
+ parse_JSONAppendExpr();
+ break;
+ default:
+ parse_OrExpr();
+ }
+ eventHandler.endNonterminal("ExprSimple", e0);
+ }
+
+ function try_ExprSimple()
+ {
+ switch (l1)
+ {
+ case 77: // 'append'
+ lookahead2W(230); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 218: // 'rename'
+ lookahead2W(233); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 219: // 'replace'
+ lookahead2W(234); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 110: // 'delete'
+ case 159: // 'insert'
+ lookahead2W(236); // S^WS | EOF | '!' | '!=' | '#' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' | '/' |
+ break;
+ case 103: // 'copy'
+ case 129: // 'every'
+ case 235: // 'some'
+ lookahead2W(229); // S^WS | EOF | '!' | '!=' | '#' | '$' | '(' | '(:' | ')' | '*' | '+' | ',' | '-' |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 133851) // 'replace' 'value'
+ {
+ lk = memoized(9, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_ReplaceExpr();
+ memoize(9, e0A, -6);
+ lk = -13;
+ }
+ catch (p6A)
+ {
+ lk = -11;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(9, e0A, -11);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case 16001: // 'every' '$'
+ case 16107: // 'some' '$'
+ try_QuantifiedExpr();
+ break;
+ case 97951: // 'insert' 'node'
+ case 98463: // 'insert' 'nodes'
+ try_InsertExpr();
+ break;
+ case 97902: // 'delete' 'node'
+ case 98414: // 'delete' 'nodes'
+ try_DeleteExpr();
+ break;
+ case 98010: // 'rename' 'node'
+ try_RenameExpr();
+ break;
+ case -6:
+ case 98011: // 'replace' 'node'
+ try_ReplaceExpr();
+ break;
+ case 15975: // 'copy' '$'
+ try_TransformExpr();
+ break;
+ case 85102: // 'delete' 'json'
+ try_JSONDeleteExpr();
+ break;
+ case 85151: // 'insert' 'json'
+ try_JSONInsertExpr();
+ break;
+ case 85210: // 'rename' 'json'
+ try_JSONRenameExpr();
+ break;
+ case -11:
+ try_JSONReplaceExpr();
+ break;
+ case 85069: // 'append' 'json'
+ try_JSONAppendExpr();
+ break;
+ case -13:
+ break;
+ default:
+ try_OrExpr();
+ }
+ }
+
+ function parse_JSONDeleteExpr()
+ {
+ eventHandler.startNonterminal("JSONDeleteExpr", e0);
+ shift(110); // 'delete'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shift(166); // 'json'
+ lookahead1W(263); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PostfixExpr();
+ eventHandler.endNonterminal("JSONDeleteExpr", e0);
+ }
+
+ function try_JSONDeleteExpr()
+ {
+ shiftT(110); // 'delete'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(263); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PostfixExpr();
+ }
+
+ function parse_JSONInsertExpr()
+ {
+ eventHandler.startNonterminal("JSONInsertExpr", e0);
+ switch (l1)
+ {
+ case 159: // 'insert'
+ lookahead2W(56); // S^WS | '(:' | 'json'
+ break;
+ default:
+ lk = l1;
+ }
+ lk = memoized(10, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(159); // 'insert'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(69); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 108113) // 'at' 'position'
+ {
+ lk = memoized(11, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ memoize(11, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(11, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1)
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(10, e0, lk);
+ }
+ switch (lk)
+ {
+ case -1:
+ shift(159); // 'insert'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shift(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(69); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 108113) // 'at' 'position'
+ {
+ lk = memoized(11, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ lk = -1;
+ }
+ catch (p1B)
+ {
+ lk = -2;
+ }
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(11, e0, lk);
+ }
+ }
+ if (lk == -1)
+ {
+ shift(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shift(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ break;
+ default:
+ shift(159); // 'insert'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shift(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_PairConstructorList();
+ shift(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ }
+ eventHandler.endNonterminal("JSONInsertExpr", e0);
+ }
+
+ function try_JSONInsertExpr()
+ {
+ switch (l1)
+ {
+ case 159: // 'insert'
+ lookahead2W(56); // S^WS | '(:' | 'json'
+ break;
+ default:
+ lk = l1;
+ }
+ lk = memoized(10, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(159); // 'insert'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(69); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 108113) // 'at' 'position'
+ {
+ lk = memoized(11, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ memoize(11, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(11, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1)
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ memoize(10, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(10, e0A, -2);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shiftT(159); // 'insert'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ switch (l1)
+ {
+ case 81: // 'at'
+ lookahead2W(69); // S^WS | '(:' | 'position'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 108113) // 'at' 'position'
+ {
+ lk = memoized(11, e0);
+ if (lk == 0)
+ {
+ var b0B = b0; var e0B = e0; var l1B = l1;
+ var b1B = b1; var e1B = e1; var l2B = l2;
+ var b2B = b2; var e2B = e2;
+ try
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ memoize(11, e0B, -1);
+ }
+ catch (p1B)
+ {
+ b0 = b0B; e0 = e0B; l1 = l1B; if (l1 == 0) {end = e0B;} else {
+ b1 = b1B; e1 = e1B; l2 = l2B; if (l2 == 0) {end = e1B;} else {
+ b2 = b2B; e2 = e2B; end = e2B; }}
+ memoize(11, e0B, -2);
+ }
+ lk = -2;
+ }
+ }
+ if (lk == -1)
+ {
+ shiftT(81); // 'at'
+ lookahead1W(69); // S^WS | '(:' | 'position'
+ shiftT(211); // 'position'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ break;
+ case -3:
+ break;
+ default:
+ shiftT(159); // 'insert'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_PairConstructorList();
+ shiftT(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+ }
+
+ function parse_JSONRenameExpr()
+ {
+ eventHandler.startNonterminal("JSONRenameExpr", e0);
+ shift(218); // 'rename'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shift(166); // 'json'
+ lookahead1W(263); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PostfixExpr();
+ shift(79); // 'as'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("JSONRenameExpr", e0);
+ }
+
+ function try_JSONRenameExpr()
+ {
+ shiftT(218); // 'rename'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(263); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PostfixExpr();
+ shiftT(79); // 'as'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_JSONReplaceExpr()
+ {
+ eventHandler.startNonterminal("JSONReplaceExpr", e0);
+ shift(219); // 'replace'
+ lookahead1W(82); // S^WS | '(:' | 'value'
+ shift(261); // 'value'
+ lookahead1W(64); // S^WS | '(:' | 'of'
+ shift(196); // 'of'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shift(166); // 'json'
+ lookahead1W(263); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ whitespace();
+ parse_PostfixExpr();
+ shift(270); // 'with'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("JSONReplaceExpr", e0);
+ }
+
+ function try_JSONReplaceExpr()
+ {
+ shiftT(219); // 'replace'
+ lookahead1W(82); // S^WS | '(:' | 'value'
+ shiftT(261); // 'value'
+ lookahead1W(64); // S^WS | '(:' | 'of'
+ shiftT(196); // 'of'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(263); // EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral | StringLiteral |
+ try_PostfixExpr();
+ shiftT(270); // 'with'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_JSONAppendExpr()
+ {
+ eventHandler.startNonterminal("JSONAppendExpr", e0);
+ shift(77); // 'append'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shift(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ shift(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("JSONAppendExpr", e0);
+ }
+
+ function try_JSONAppendExpr()
+ {
+ shiftT(77); // 'append'
+ lookahead1W(56); // S^WS | '(:' | 'json'
+ shiftT(166); // 'json'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ shiftT(163); // 'into'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_CommonContent()
+ {
+ eventHandler.startNonterminal("CommonContent", e0);
+ switch (l1)
+ {
+ case 12: // PredefinedEntityRef
+ shift(12); // PredefinedEntityRef
+ break;
+ case 23: // CharRef
+ shift(23); // CharRef
+ break;
+ case 277: // '{{'
+ shift(277); // '{{'
+ break;
+ case 283: // '}}'
+ shift(283); // '}}'
+ break;
+ default:
+ parse_BlockExpr();
+ }
+ eventHandler.endNonterminal("CommonContent", e0);
+ }
+
+ function try_CommonContent()
+ {
+ switch (l1)
+ {
+ case 12: // PredefinedEntityRef
+ shiftT(12); // PredefinedEntityRef
+ break;
+ case 23: // CharRef
+ shiftT(23); // CharRef
+ break;
+ case 277: // '{{'
+ shiftT(277); // '{{'
+ break;
+ case 283: // '}}'
+ shiftT(283); // '}}'
+ break;
+ default:
+ try_BlockExpr();
+ }
+ }
+
+ function parse_ContentExpr()
+ {
+ eventHandler.startNonterminal("ContentExpr", e0);
+ parse_StatementsAndExpr();
+ eventHandler.endNonterminal("ContentExpr", e0);
+ }
+
+ function try_ContentExpr()
+ {
+ try_StatementsAndExpr();
+ }
+
+ function parse_CompDocConstructor()
+ {
+ eventHandler.startNonterminal("CompDocConstructor", e0);
+ shift(119); // 'document'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockExpr();
+ eventHandler.endNonterminal("CompDocConstructor", e0);
+ }
+
+ function try_CompDocConstructor()
+ {
+ shiftT(119); // 'document'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ try_BlockExpr();
+ }
+
+ function parse_CompAttrConstructor()
+ {
+ eventHandler.startNonterminal("CompAttrConstructor", e0);
+ shift(82); // 'attribute'
+ lookahead1W(257); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ break;
+ default:
+ whitespace();
+ parse_EQName();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 144660) // '{' '}'
+ {
+ lk = memoized(12, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shiftT(282); // '}'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(12, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shift(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shift(282); // '}'
+ break;
+ default:
+ whitespace();
+ parse_BlockExpr();
+ }
+ eventHandler.endNonterminal("CompAttrConstructor", e0);
+ }
+
+ function try_CompAttrConstructor()
+ {
+ shiftT(82); // 'attribute'
+ lookahead1W(257); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ break;
+ default:
+ try_EQName();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 144660) // '{' '}'
+ {
+ lk = memoized(12, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shiftT(282); // '}'
+ memoize(12, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(12, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shiftT(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shiftT(282); // '}'
+ break;
+ case -3:
+ break;
+ default:
+ try_BlockExpr();
+ }
+ }
+
+ function parse_CompPIConstructor()
+ {
+ eventHandler.startNonterminal("CompPIConstructor", e0);
+ shift(216); // 'processing-instruction'
+ lookahead1W(250); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shift(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_Expr();
+ shift(282); // '}'
+ break;
+ default:
+ whitespace();
+ parse_NCName();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 144660) // '{' '}'
+ {
+ lk = memoized(13, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shiftT(282); // '}'
+ lk = -1;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(13, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shift(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shift(282); // '}'
+ break;
+ default:
+ whitespace();
+ parse_BlockExpr();
+ }
+ eventHandler.endNonterminal("CompPIConstructor", e0);
+ }
+
+ function try_CompPIConstructor()
+ {
+ shiftT(216); // 'processing-instruction'
+ lookahead1W(250); // NCName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ switch (l1)
+ {
+ case 276: // '{'
+ shiftT(276); // '{'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_Expr();
+ shiftT(282); // '}'
+ break;
+ default:
+ try_NCName();
+ }
+ lookahead1W(87); // S^WS | '(:' | '{'
+ switch (l1)
+ {
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 144660) // '{' '}'
+ {
+ lk = memoized(13, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ shiftT(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shiftT(282); // '}'
+ memoize(13, e0A, -1);
+ lk = -3;
+ }
+ catch (p1A)
+ {
+ lk = -2;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(13, e0A, -2);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case -1:
+ shiftT(276); // '{'
+ lookahead1W(88); // S^WS | '(:' | '}'
+ shiftT(282); // '}'
+ break;
+ case -3:
+ break;
+ default:
+ try_BlockExpr();
+ }
+ }
+
+ function parse_CompCommentConstructor()
+ {
+ eventHandler.startNonterminal("CompCommentConstructor", e0);
+ shift(96); // 'comment'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockExpr();
+ eventHandler.endNonterminal("CompCommentConstructor", e0);
+ }
+
+ function try_CompCommentConstructor()
+ {
+ shiftT(96); // 'comment'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ try_BlockExpr();
+ }
+
+ function parse_CompTextConstructor()
+ {
+ eventHandler.startNonterminal("CompTextConstructor", e0);
+ shift(244); // 'text'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ whitespace();
+ parse_BlockExpr();
+ eventHandler.endNonterminal("CompTextConstructor", e0);
+ }
+
+ function try_CompTextConstructor()
+ {
+ shiftT(244); // 'text'
+ lookahead1W(87); // S^WS | '(:' | '{'
+ try_BlockExpr();
+ }
+
+ function parse_PrimaryExpr()
+ {
+ eventHandler.startNonterminal("PrimaryExpr", e0);
+ switch (l1)
+ {
+ case 184: // 'namespace'
+ lookahead2W(255); // NCName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 216: // 'processing-instruction'
+ lookahead2W(253); // NCName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 82: // 'attribute'
+ case 121: // 'element'
+ lookahead2W(258); // EQName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 96: // 'comment'
+ case 244: // 'text'
+ lookahead2W(93); // S^WS | '#' | '(:' | '{'
+ break;
+ case 119: // 'document'
+ case 202: // 'ordered'
+ case 256: // 'unordered'
+ lookahead2W(139); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 6: // EQName^Token
+ case 70: // 'after'
+ case 72: // 'allowing'
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 75: // 'and'
+ case 77: // 'append'
+ case 79: // 'as'
+ case 80: // 'ascending'
+ case 81: // 'at'
+ case 83: // 'base-uri'
+ case 84: // 'before'
+ case 85: // 'boundary-space'
+ case 86: // 'break'
+ case 88: // 'case'
+ case 89: // 'cast'
+ case 90: // 'castable'
+ case 91: // 'catch'
+ case 93: // 'child'
+ case 94: // 'collation'
+ case 97: // 'constraint'
+ case 98: // 'construction'
+ case 101: // 'context'
+ case 102: // 'continue'
+ case 103: // 'copy'
+ case 104: // 'copy-namespaces'
+ case 105: // 'count'
+ case 106: // 'decimal-format'
+ case 108: // 'declare'
+ case 109: // 'default'
+ case 110: // 'delete'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 113: // 'descending'
+ case 118: // 'div'
+ case 122: // 'else'
+ case 123: // 'empty'
+ case 125: // 'encoding'
+ case 126: // 'end'
+ case 128: // 'eq'
+ case 129: // 'every'
+ case 131: // 'except'
+ case 132: // 'exit'
+ case 133: // 'external'
+ case 134: // 'first'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 137: // 'for'
+ case 141: // 'ft-option'
+ case 146: // 'ge'
+ case 148: // 'group'
+ case 150: // 'gt'
+ case 151: // 'idiv'
+ case 153: // 'import'
+ case 154: // 'in'
+ case 155: // 'index'
+ case 159: // 'insert'
+ case 160: // 'instance'
+ case 161: // 'integrity'
+ case 162: // 'intersect'
+ case 163: // 'into'
+ case 164: // 'is'
+ case 166: // 'json'
+ case 170: // 'last'
+ case 171: // 'lax'
+ case 172: // 'le'
+ case 174: // 'let'
+ case 176: // 'loop'
+ case 178: // 'lt'
+ case 180: // 'mod'
+ case 181: // 'modify'
+ case 182: // 'module'
+ case 186: // 'ne'
+ case 192: // 'nodes'
+ case 194: // 'object'
+ case 198: // 'only'
+ case 199: // 'option'
+ case 200: // 'or'
+ case 201: // 'order'
+ case 203: // 'ordering'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ case 218: // 'rename'
+ case 219: // 'replace'
+ case 220: // 'return'
+ case 221: // 'returning'
+ case 222: // 'revalidation'
+ case 224: // 'satisfies'
+ case 225: // 'schema'
+ case 228: // 'score'
+ case 229: // 'self'
+ case 234: // 'sliding'
+ case 235: // 'some'
+ case 236: // 'stable'
+ case 237: // 'start'
+ case 240: // 'strict'
+ case 248: // 'to'
+ case 249: // 'treat'
+ case 250: // 'try'
+ case 251: // 'tumbling'
+ case 252: // 'type'
+ case 254: // 'union'
+ case 257: // 'updating'
+ case 260: // 'validate'
+ case 261: // 'value'
+ case 262: // 'variable'
+ case 263: // 'version'
+ case 266: // 'where'
+ case 267: // 'while'
+ case 270: // 'with'
+ case 274: // 'xquery'
+ lookahead2W(92); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 2836 // '{' Wildcard
+ || lk == 3348 // '{' EQName^Token
+ || lk == 4372 // '{' IntegerLiteral
+ || lk == 4884 // '{' DecimalLiteral
+ || lk == 5396 // '{' DoubleLiteral
+ || lk == 5908 // '{' StringLiteral
+ || lk == 16148 // '{' '$'
+ || lk == 16660 // '{' '%'
+ || lk == 17684 // '{' '('
+ || lk == 18196 // '{' '(#'
+ || lk == 20756 // '{' '+'
+ || lk == 21780 // '{' '-'
+ || lk == 22804 // '{' '.'
+ || lk == 23316 // '{' '..'
+ || lk == 23828 // '{' '/'
+ || lk == 24340 // '{' '//'
+ || lk == 27924 // '{' '<'
+ || lk == 28436 // '{' '<!--'
+ || lk == 30484 // '{' '<?'
+ || lk == 34068 // '{' '@'
+ || lk == 35092 // '{' '['
+ || lk == 36116 // '{' 'after'
+ || lk == 37140 // '{' 'allowing'
+ || lk == 37652 // '{' 'ancestor'
+ || lk == 38164 // '{' 'ancestor-or-self'
+ || lk == 38676 // '{' 'and'
+ || lk == 39700 // '{' 'append'
+ || lk == 40212 // '{' 'array'
+ || lk == 40724 // '{' 'as'
+ || lk == 41236 // '{' 'ascending'
+ || lk == 41748 // '{' 'at'
+ || lk == 42260 // '{' 'attribute'
+ || lk == 42772 // '{' 'base-uri'
+ || lk == 43284 // '{' 'before'
+ || lk == 43796 // '{' 'boundary-space'
+ || lk == 44308 // '{' 'break'
+ || lk == 45332 // '{' 'case'
+ || lk == 45844 // '{' 'cast'
+ || lk == 46356 // '{' 'castable'
+ || lk == 46868 // '{' 'catch'
+ || lk == 47892 // '{' 'child'
+ || lk == 48404 // '{' 'collation'
+ || lk == 49428 // '{' 'comment'
+ || lk == 49940 // '{' 'constraint'
+ || lk == 50452 // '{' 'construction'
+ || lk == 51988 // '{' 'context'
+ || lk == 52500 // '{' 'continue'
+ || lk == 53012 // '{' 'copy'
+ || lk == 53524 // '{' 'copy-namespaces'
+ || lk == 54036 // '{' 'count'
+ || lk == 54548 // '{' 'decimal-format'
+ || lk == 55572 // '{' 'declare'
+ || lk == 56084 // '{' 'default'
+ || lk == 56596 // '{' 'delete'
+ || lk == 57108 // '{' 'descendant'
+ || lk == 57620 // '{' 'descendant-or-self'
+ || lk == 58132 // '{' 'descending'
+ || lk == 60692 // '{' 'div'
+ || lk == 61204 // '{' 'document'
+ || lk == 61716 // '{' 'document-node'
+ || lk == 62228 // '{' 'element'
+ || lk == 62740 // '{' 'else'
+ || lk == 63252 // '{' 'empty'
+ || lk == 63764 // '{' 'empty-sequence'
+ || lk == 64276 // '{' 'encoding'
+ || lk == 64788 // '{' 'end'
+ || lk == 65812 // '{' 'eq'
+ || lk == 66324 // '{' 'every'
+ || lk == 67348 // '{' 'except'
+ || lk == 67860 // '{' 'exit'
+ || lk == 68372 // '{' 'external'
+ || lk == 68884 // '{' 'first'
+ || lk == 69396 // '{' 'following'
+ || lk == 69908 // '{' 'following-sibling'
+ || lk == 70420 // '{' 'for'
+ || lk == 72468 // '{' 'ft-option'
+ || lk == 74516 // '{' 'function'
+ || lk == 75028 // '{' 'ge'
+ || lk == 76052 // '{' 'group'
+ || lk == 77076 // '{' 'gt'
+ || lk == 77588 // '{' 'idiv'
+ || lk == 78100 // '{' 'if'
+ || lk == 78612 // '{' 'import'
+ || lk == 79124 // '{' 'in'
+ || lk == 79636 // '{' 'index'
+ || lk == 81684 // '{' 'insert'
+ || lk == 82196 // '{' 'instance'
+ || lk == 82708 // '{' 'integrity'
+ || lk == 83220 // '{' 'intersect'
+ || lk == 83732 // '{' 'into'
+ || lk == 84244 // '{' 'is'
+ || lk == 84756 // '{' 'item'
+ || lk == 85268 // '{' 'json'
+ || lk == 85780 // '{' 'json-item'
+ || lk == 87316 // '{' 'last'
+ || lk == 87828 // '{' 'lax'
+ || lk == 88340 // '{' 'le'
+ || lk == 89364 // '{' 'let'
+ || lk == 90388 // '{' 'loop'
+ || lk == 91412 // '{' 'lt'
+ || lk == 92436 // '{' 'mod'
+ || lk == 92948 // '{' 'modify'
+ || lk == 93460 // '{' 'module'
+ || lk == 94484 // '{' 'namespace'
+ || lk == 94996 // '{' 'namespace-node'
+ || lk == 95508 // '{' 'ne'
+ || lk == 98068 // '{' 'node'
+ || lk == 98580 // '{' 'nodes'
+ || lk == 99604 // '{' 'object'
+ || lk == 101652 // '{' 'only'
+ || lk == 102164 // '{' 'option'
+ || lk == 102676 // '{' 'or'
+ || lk == 103188 // '{' 'order'
+ || lk == 103700 // '{' 'ordered'
+ || lk == 104212 // '{' 'ordering'
+ || lk == 105748 // '{' 'parent'
+ || lk == 108820 // '{' 'preceding'
+ || lk == 109332 // '{' 'preceding-sibling'
+ || lk == 110868 // '{' 'processing-instruction'
+ || lk == 111892 // '{' 'rename'
+ || lk == 112404 // '{' 'replace'
+ || lk == 112916 // '{' 'return'
+ || lk == 113428 // '{' 'returning'
+ || lk == 113940 // '{' 'revalidation'
+ || lk == 114964 // '{' 'satisfies'
+ || lk == 115476 // '{' 'schema'
+ || lk == 115988 // '{' 'schema-attribute'
+ || lk == 116500 // '{' 'schema-element'
+ || lk == 117012 // '{' 'score'
+ || lk == 117524 // '{' 'self'
+ || lk == 120084 // '{' 'sliding'
+ || lk == 120596 // '{' 'some'
+ || lk == 121108 // '{' 'stable'
+ || lk == 121620 // '{' 'start'
+ || lk == 123156 // '{' 'strict'
+ || lk == 124180 // '{' 'structured-item'
+ || lk == 124692 // '{' 'switch'
+ || lk == 125204 // '{' 'text'
+ || lk == 127252 // '{' 'to'
+ || lk == 127764 // '{' 'treat'
+ || lk == 128276 // '{' 'try'
+ || lk == 128788 // '{' 'tumbling'
+ || lk == 129300 // '{' 'type'
+ || lk == 129812 // '{' 'typeswitch'
+ || lk == 130324 // '{' 'union'
+ || lk == 131348 // '{' 'unordered'
+ || lk == 131860 // '{' 'updating'
+ || lk == 133396 // '{' 'validate'
+ || lk == 133908 // '{' 'value'
+ || lk == 134420 // '{' 'variable'
+ || lk == 134932 // '{' 'version'
+ || lk == 136468 // '{' 'where'
+ || lk == 136980 // '{' 'while'
+ || lk == 138516 // '{' 'with'
+ || lk == 140564 // '{' 'xquery'
+ || lk == 141588 // '{' '{'
+ || lk == 142612 // '{' '{|'
+ || lk == 144660) // '{' '}'
+ {
+ lk = memoized(14, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_BlockExpr();
+ lk = -10;
+ }
+ catch (p10A)
+ {
+ lk = -11;
+ }
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(14, e0, lk);
+ }
+ }
+ switch (lk)
+ {
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ parse_Literal();
+ break;
+ case 31: // '$'
+ parse_VarRef();
+ break;
+ case 34: // '('
+ parse_ParenthesizedExpr();
+ break;
+ case 44: // '.'
+ parse_ContextItemExpr();
+ break;
+ case 17414: // EQName^Token '('
+ case 17478: // 'after' '('
+ case 17480: // 'allowing' '('
+ case 17481: // 'ancestor' '('
+ case 17482: // 'ancestor-or-self' '('
+ case 17483: // 'and' '('
+ case 17485: // 'append' '('
+ case 17487: // 'as' '('
+ case 17488: // 'ascending' '('
+ case 17489: // 'at' '('
+ case 17491: // 'base-uri' '('
+ case 17492: // 'before' '('
+ case 17493: // 'boundary-space' '('
+ case 17494: // 'break' '('
+ case 17496: // 'case' '('
+ case 17497: // 'cast' '('
+ case 17498: // 'castable' '('
+ case 17499: // 'catch' '('
+ case 17501: // 'child' '('
+ case 17502: // 'collation' '('
+ case 17505: // 'constraint' '('
+ case 17506: // 'construction' '('
+ case 17509: // 'context' '('
+ case 17510: // 'continue' '('
+ case 17511: // 'copy' '('
+ case 17512: // 'copy-namespaces' '('
+ case 17513: // 'count' '('
+ case 17514: // 'decimal-format' '('
+ case 17516: // 'declare' '('
+ case 17517: // 'default' '('
+ case 17518: // 'delete' '('
+ case 17519: // 'descendant' '('
+ case 17520: // 'descendant-or-self' '('
+ case 17521: // 'descending' '('
+ case 17526: // 'div' '('
+ case 17527: // 'document' '('
+ case 17530: // 'else' '('
+ case 17531: // 'empty' '('
+ case 17533: // 'encoding' '('
+ case 17534: // 'end' '('
+ case 17536: // 'eq' '('
+ case 17537: // 'every' '('
+ case 17539: // 'except' '('
+ case 17540: // 'exit' '('
+ case 17541: // 'external' '('
+ case 17542: // 'first' '('
+ case 17543: // 'following' '('
+ case 17544: // 'following-sibling' '('
+ case 17545: // 'for' '('
+ case 17549: // 'ft-option' '('
+ case 17554: // 'ge' '('
+ case 17556: // 'group' '('
+ case 17558: // 'gt' '('
+ case 17559: // 'idiv' '('
+ case 17561: // 'import' '('
+ case 17562: // 'in' '('
+ case 17563: // 'index' '('
+ case 17567: // 'insert' '('
+ case 17568: // 'instance' '('
+ case 17569: // 'integrity' '('
+ case 17570: // 'intersect' '('
+ case 17571: // 'into' '('
+ case 17572: // 'is' '('
+ case 17574: // 'json' '('
+ case 17578: // 'last' '('
+ case 17579: // 'lax' '('
+ case 17580: // 'le' '('
+ case 17582: // 'let' '('
+ case 17584: // 'loop' '('
+ case 17586: // 'lt' '('
+ case 17588: // 'mod' '('
+ case 17589: // 'modify' '('
+ case 17590: // 'module' '('
+ case 17592: // 'namespace' '('
+ case 17594: // 'ne' '('
+ case 17600: // 'nodes' '('
+ case 17602: // 'object' '('
+ case 17606: // 'only' '('
+ case 17607: // 'option' '('
+ case 17608: // 'or' '('
+ case 17609: // 'order' '('
+ case 17610: // 'ordered' '('
+ case 17611: // 'ordering' '('
+ case 17614: // 'parent' '('
+ case 17620: // 'preceding' '('
+ case 17621: // 'preceding-sibling' '('
+ case 17626: // 'rename' '('
+ case 17627: // 'replace' '('
+ case 17628: // 'return' '('
+ case 17629: // 'returning' '('
+ case 17630: // 'revalidation' '('
+ case 17632: // 'satisfies' '('
+ case 17633: // 'schema' '('
+ case 17636: // 'score' '('
+ case 17637: // 'self' '('
+ case 17642: // 'sliding' '('
+ case 17643: // 'some' '('
+ case 17644: // 'stable' '('
+ case 17645: // 'start' '('
+ case 17648: // 'strict' '('
+ case 17656: // 'to' '('
+ case 17657: // 'treat' '('
+ case 17658: // 'try' '('
+ case 17659: // 'tumbling' '('
+ case 17660: // 'type' '('
+ case 17662: // 'union' '('
+ case 17664: // 'unordered' '('
+ case 17665: // 'updating' '('
+ case 17668: // 'validate' '('
+ case 17669: // 'value' '('
+ case 17670: // 'variable' '('
+ case 17671: // 'version' '('
+ case 17674: // 'where' '('
+ case 17675: // 'while' '('
+ case 17678: // 'with' '('
+ case 17682: // 'xquery' '('
+ parse_FunctionCall();
+ break;
+ case 141514: // 'ordered' '{'
+ parse_OrderedExpr();
+ break;
+ case 141568: // 'unordered' '{'
+ parse_UnorderedExpr();
+ break;
+ case 32: // '%'
+ case 78: // 'array'
+ case 120: // 'document-node'
+ case 124: // 'empty-sequence'
+ case 145: // 'function'
+ case 152: // 'if'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 185: // 'namespace-node'
+ case 191: // 'node'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 242: // 'structured-item'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ case 14854: // EQName^Token '#'
+ case 14918: // 'after' '#'
+ case 14920: // 'allowing' '#'
+ case 14921: // 'ancestor' '#'
+ case 14922: // 'ancestor-or-self' '#'
+ case 14923: // 'and' '#'
+ case 14925: // 'append' '#'
+ case 14927: // 'as' '#'
+ case 14928: // 'ascending' '#'
+ case 14929: // 'at' '#'
+ case 14930: // 'attribute' '#'
+ case 14931: // 'base-uri' '#'
+ case 14932: // 'before' '#'
+ case 14933: // 'boundary-space' '#'
+ case 14934: // 'break' '#'
+ case 14936: // 'case' '#'
+ case 14937: // 'cast' '#'
+ case 14938: // 'castable' '#'
+ case 14939: // 'catch' '#'
+ case 14941: // 'child' '#'
+ case 14942: // 'collation' '#'
+ case 14944: // 'comment' '#'
+ case 14945: // 'constraint' '#'
+ case 14946: // 'construction' '#'
+ case 14949: // 'context' '#'
+ case 14950: // 'continue' '#'
+ case 14951: // 'copy' '#'
+ case 14952: // 'copy-namespaces' '#'
+ case 14953: // 'count' '#'
+ case 14954: // 'decimal-format' '#'
+ case 14956: // 'declare' '#'
+ case 14957: // 'default' '#'
+ case 14958: // 'delete' '#'
+ case 14959: // 'descendant' '#'
+ case 14960: // 'descendant-or-self' '#'
+ case 14961: // 'descending' '#'
+ case 14966: // 'div' '#'
+ case 14967: // 'document' '#'
+ case 14969: // 'element' '#'
+ case 14970: // 'else' '#'
+ case 14971: // 'empty' '#'
+ case 14973: // 'encoding' '#'
+ case 14974: // 'end' '#'
+ case 14976: // 'eq' '#'
+ case 14977: // 'every' '#'
+ case 14979: // 'except' '#'
+ case 14980: // 'exit' '#'
+ case 14981: // 'external' '#'
+ case 14982: // 'first' '#'
+ case 14983: // 'following' '#'
+ case 14984: // 'following-sibling' '#'
+ case 14985: // 'for' '#'
+ case 14989: // 'ft-option' '#'
+ case 14994: // 'ge' '#'
+ case 14996: // 'group' '#'
+ case 14998: // 'gt' '#'
+ case 14999: // 'idiv' '#'
+ case 15001: // 'import' '#'
+ case 15002: // 'in' '#'
+ case 15003: // 'index' '#'
+ case 15007: // 'insert' '#'
+ case 15008: // 'instance' '#'
+ case 15009: // 'integrity' '#'
+ case 15010: // 'intersect' '#'
+ case 15011: // 'into' '#'
+ case 15012: // 'is' '#'
+ case 15014: // 'json' '#'
+ case 15018: // 'last' '#'
+ case 15019: // 'lax' '#'
+ case 15020: // 'le' '#'
+ case 15022: // 'let' '#'
+ case 15024: // 'loop' '#'
+ case 15026: // 'lt' '#'
+ case 15028: // 'mod' '#'
+ case 15029: // 'modify' '#'
+ case 15030: // 'module' '#'
+ case 15032: // 'namespace' '#'
+ case 15034: // 'ne' '#'
+ case 15040: // 'nodes' '#'
+ case 15042: // 'object' '#'
+ case 15046: // 'only' '#'
+ case 15047: // 'option' '#'
+ case 15048: // 'or' '#'
+ case 15049: // 'order' '#'
+ case 15050: // 'ordered' '#'
+ case 15051: // 'ordering' '#'
+ case 15054: // 'parent' '#'
+ case 15060: // 'preceding' '#'
+ case 15061: // 'preceding-sibling' '#'
+ case 15064: // 'processing-instruction' '#'
+ case 15066: // 'rename' '#'
+ case 15067: // 'replace' '#'
+ case 15068: // 'return' '#'
+ case 15069: // 'returning' '#'
+ case 15070: // 'revalidation' '#'
+ case 15072: // 'satisfies' '#'
+ case 15073: // 'schema' '#'
+ case 15076: // 'score' '#'
+ case 15077: // 'self' '#'
+ case 15082: // 'sliding' '#'
+ case 15083: // 'some' '#'
+ case 15084: // 'stable' '#'
+ case 15085: // 'start' '#'
+ case 15088: // 'strict' '#'
+ case 15092: // 'text' '#'
+ case 15096: // 'to' '#'
+ case 15097: // 'treat' '#'
+ case 15098: // 'try' '#'
+ case 15099: // 'tumbling' '#'
+ case 15100: // 'type' '#'
+ case 15102: // 'union' '#'
+ case 15104: // 'unordered' '#'
+ case 15105: // 'updating' '#'
+ case 15108: // 'validate' '#'
+ case 15109: // 'value' '#'
+ case 15110: // 'variable' '#'
+ case 15111: // 'version' '#'
+ case 15114: // 'where' '#'
+ case 15115: // 'while' '#'
+ case 15118: // 'with' '#'
+ case 15122: // 'xquery' '#'
+ parse_FunctionItemExpr();
+ break;
+ case -10:
+ case 27412: // '{' ';'
+ parse_BlockExpr();
+ break;
+ case -11:
+ parse_ObjectConstructor();
+ break;
+ case 68: // '['
+ parse_ArrayConstructor();
+ break;
+ case 278: // '{|'
+ parse_JSONSimpleObjectUnion();
+ break;
+ default:
+ parse_Constructor();
+ }
+ eventHandler.endNonterminal("PrimaryExpr", e0);
+ }
+
+ function try_PrimaryExpr()
+ {
+ switch (l1)
+ {
+ case 184: // 'namespace'
+ lookahead2W(255); // NCName^Token | S^WS | '#' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 216: // 'processing-instruction'
+ lookahead2W(253); // NCName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 276: // '{'
+ lookahead2W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ break;
+ case 82: // 'attribute'
+ case 121: // 'element'
+ lookahead2W(258); // EQName^Token | S^WS | '#' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ break;
+ case 96: // 'comment'
+ case 244: // 'text'
+ lookahead2W(93); // S^WS | '#' | '(:' | '{'
+ break;
+ case 119: // 'document'
+ case 202: // 'ordered'
+ case 256: // 'unordered'
+ lookahead2W(139); // S^WS | '#' | '(' | '(:' | '{'
+ break;
+ case 6: // EQName^Token
+ case 70: // 'after'
+ case 72: // 'allowing'
+ case 73: // 'ancestor'
+ case 74: // 'ancestor-or-self'
+ case 75: // 'and'
+ case 77: // 'append'
+ case 79: // 'as'
+ case 80: // 'ascending'
+ case 81: // 'at'
+ case 83: // 'base-uri'
+ case 84: // 'before'
+ case 85: // 'boundary-space'
+ case 86: // 'break'
+ case 88: // 'case'
+ case 89: // 'cast'
+ case 90: // 'castable'
+ case 91: // 'catch'
+ case 93: // 'child'
+ case 94: // 'collation'
+ case 97: // 'constraint'
+ case 98: // 'construction'
+ case 101: // 'context'
+ case 102: // 'continue'
+ case 103: // 'copy'
+ case 104: // 'copy-namespaces'
+ case 105: // 'count'
+ case 106: // 'decimal-format'
+ case 108: // 'declare'
+ case 109: // 'default'
+ case 110: // 'delete'
+ case 111: // 'descendant'
+ case 112: // 'descendant-or-self'
+ case 113: // 'descending'
+ case 118: // 'div'
+ case 122: // 'else'
+ case 123: // 'empty'
+ case 125: // 'encoding'
+ case 126: // 'end'
+ case 128: // 'eq'
+ case 129: // 'every'
+ case 131: // 'except'
+ case 132: // 'exit'
+ case 133: // 'external'
+ case 134: // 'first'
+ case 135: // 'following'
+ case 136: // 'following-sibling'
+ case 137: // 'for'
+ case 141: // 'ft-option'
+ case 146: // 'ge'
+ case 148: // 'group'
+ case 150: // 'gt'
+ case 151: // 'idiv'
+ case 153: // 'import'
+ case 154: // 'in'
+ case 155: // 'index'
+ case 159: // 'insert'
+ case 160: // 'instance'
+ case 161: // 'integrity'
+ case 162: // 'intersect'
+ case 163: // 'into'
+ case 164: // 'is'
+ case 166: // 'json'
+ case 170: // 'last'
+ case 171: // 'lax'
+ case 172: // 'le'
+ case 174: // 'let'
+ case 176: // 'loop'
+ case 178: // 'lt'
+ case 180: // 'mod'
+ case 181: // 'modify'
+ case 182: // 'module'
+ case 186: // 'ne'
+ case 192: // 'nodes'
+ case 194: // 'object'
+ case 198: // 'only'
+ case 199: // 'option'
+ case 200: // 'or'
+ case 201: // 'order'
+ case 203: // 'ordering'
+ case 206: // 'parent'
+ case 212: // 'preceding'
+ case 213: // 'preceding-sibling'
+ case 218: // 'rename'
+ case 219: // 'replace'
+ case 220: // 'return'
+ case 221: // 'returning'
+ case 222: // 'revalidation'
+ case 224: // 'satisfies'
+ case 225: // 'schema'
+ case 228: // 'score'
+ case 229: // 'self'
+ case 234: // 'sliding'
+ case 235: // 'some'
+ case 236: // 'stable'
+ case 237: // 'start'
+ case 240: // 'strict'
+ case 248: // 'to'
+ case 249: // 'treat'
+ case 250: // 'try'
+ case 251: // 'tumbling'
+ case 252: // 'type'
+ case 254: // 'union'
+ case 257: // 'updating'
+ case 260: // 'validate'
+ case 261: // 'value'
+ case 262: // 'variable'
+ case 263: // 'version'
+ case 266: // 'where'
+ case 267: // 'while'
+ case 270: // 'with'
+ case 274: // 'xquery'
+ lookahead2W(92); // S^WS | '#' | '(' | '(:'
+ break;
+ default:
+ lk = l1;
+ }
+ if (lk == 2836 // '{' Wildcard
+ || lk == 3348 // '{' EQName^Token
+ || lk == 4372 // '{' IntegerLiteral
+ || lk == 4884 // '{' DecimalLiteral
+ || lk == 5396 // '{' DoubleLiteral
+ || lk == 5908 // '{' StringLiteral
+ || lk == 16148 // '{' '$'
+ || lk == 16660 // '{' '%'
+ || lk == 17684 // '{' '('
+ || lk == 18196 // '{' '(#'
+ || lk == 20756 // '{' '+'
+ || lk == 21780 // '{' '-'
+ || lk == 22804 // '{' '.'
+ || lk == 23316 // '{' '..'
+ || lk == 23828 // '{' '/'
+ || lk == 24340 // '{' '//'
+ || lk == 27924 // '{' '<'
+ || lk == 28436 // '{' '<!--'
+ || lk == 30484 // '{' '<?'
+ || lk == 34068 // '{' '@'
+ || lk == 35092 // '{' '['
+ || lk == 36116 // '{' 'after'
+ || lk == 37140 // '{' 'allowing'
+ || lk == 37652 // '{' 'ancestor'
+ || lk == 38164 // '{' 'ancestor-or-self'
+ || lk == 38676 // '{' 'and'
+ || lk == 39700 // '{' 'append'
+ || lk == 40212 // '{' 'array'
+ || lk == 40724 // '{' 'as'
+ || lk == 41236 // '{' 'ascending'
+ || lk == 41748 // '{' 'at'
+ || lk == 42260 // '{' 'attribute'
+ || lk == 42772 // '{' 'base-uri'
+ || lk == 43284 // '{' 'before'
+ || lk == 43796 // '{' 'boundary-space'
+ || lk == 44308 // '{' 'break'
+ || lk == 45332 // '{' 'case'
+ || lk == 45844 // '{' 'cast'
+ || lk == 46356 // '{' 'castable'
+ || lk == 46868 // '{' 'catch'
+ || lk == 47892 // '{' 'child'
+ || lk == 48404 // '{' 'collation'
+ || lk == 49428 // '{' 'comment'
+ || lk == 49940 // '{' 'constraint'
+ || lk == 50452 // '{' 'construction'
+ || lk == 51988 // '{' 'context'
+ || lk == 52500 // '{' 'continue'
+ || lk == 53012 // '{' 'copy'
+ || lk == 53524 // '{' 'copy-namespaces'
+ || lk == 54036 // '{' 'count'
+ || lk == 54548 // '{' 'decimal-format'
+ || lk == 55572 // '{' 'declare'
+ || lk == 56084 // '{' 'default'
+ || lk == 56596 // '{' 'delete'
+ || lk == 57108 // '{' 'descendant'
+ || lk == 57620 // '{' 'descendant-or-self'
+ || lk == 58132 // '{' 'descending'
+ || lk == 60692 // '{' 'div'
+ || lk == 61204 // '{' 'document'
+ || lk == 61716 // '{' 'document-node'
+ || lk == 62228 // '{' 'element'
+ || lk == 62740 // '{' 'else'
+ || lk == 63252 // '{' 'empty'
+ || lk == 63764 // '{' 'empty-sequence'
+ || lk == 64276 // '{' 'encoding'
+ || lk == 64788 // '{' 'end'
+ || lk == 65812 // '{' 'eq'
+ || lk == 66324 // '{' 'every'
+ || lk == 67348 // '{' 'except'
+ || lk == 67860 // '{' 'exit'
+ || lk == 68372 // '{' 'external'
+ || lk == 68884 // '{' 'first'
+ || lk == 69396 // '{' 'following'
+ || lk == 69908 // '{' 'following-sibling'
+ || lk == 70420 // '{' 'for'
+ || lk == 72468 // '{' 'ft-option'
+ || lk == 74516 // '{' 'function'
+ || lk == 75028 // '{' 'ge'
+ || lk == 76052 // '{' 'group'
+ || lk == 77076 // '{' 'gt'
+ || lk == 77588 // '{' 'idiv'
+ || lk == 78100 // '{' 'if'
+ || lk == 78612 // '{' 'import'
+ || lk == 79124 // '{' 'in'
+ || lk == 79636 // '{' 'index'
+ || lk == 81684 // '{' 'insert'
+ || lk == 82196 // '{' 'instance'
+ || lk == 82708 // '{' 'integrity'
+ || lk == 83220 // '{' 'intersect'
+ || lk == 83732 // '{' 'into'
+ || lk == 84244 // '{' 'is'
+ || lk == 84756 // '{' 'item'
+ || lk == 85268 // '{' 'json'
+ || lk == 85780 // '{' 'json-item'
+ || lk == 87316 // '{' 'last'
+ || lk == 87828 // '{' 'lax'
+ || lk == 88340 // '{' 'le'
+ || lk == 89364 // '{' 'let'
+ || lk == 90388 // '{' 'loop'
+ || lk == 91412 // '{' 'lt'
+ || lk == 92436 // '{' 'mod'
+ || lk == 92948 // '{' 'modify'
+ || lk == 93460 // '{' 'module'
+ || lk == 94484 // '{' 'namespace'
+ || lk == 94996 // '{' 'namespace-node'
+ || lk == 95508 // '{' 'ne'
+ || lk == 98068 // '{' 'node'
+ || lk == 98580 // '{' 'nodes'
+ || lk == 99604 // '{' 'object'
+ || lk == 101652 // '{' 'only'
+ || lk == 102164 // '{' 'option'
+ || lk == 102676 // '{' 'or'
+ || lk == 103188 // '{' 'order'
+ || lk == 103700 // '{' 'ordered'
+ || lk == 104212 // '{' 'ordering'
+ || lk == 105748 // '{' 'parent'
+ || lk == 108820 // '{' 'preceding'
+ || lk == 109332 // '{' 'preceding-sibling'
+ || lk == 110868 // '{' 'processing-instruction'
+ || lk == 111892 // '{' 'rename'
+ || lk == 112404 // '{' 'replace'
+ || lk == 112916 // '{' 'return'
+ || lk == 113428 // '{' 'returning'
+ || lk == 113940 // '{' 'revalidation'
+ || lk == 114964 // '{' 'satisfies'
+ || lk == 115476 // '{' 'schema'
+ || lk == 115988 // '{' 'schema-attribute'
+ || lk == 116500 // '{' 'schema-element'
+ || lk == 117012 // '{' 'score'
+ || lk == 117524 // '{' 'self'
+ || lk == 120084 // '{' 'sliding'
+ || lk == 120596 // '{' 'some'
+ || lk == 121108 // '{' 'stable'
+ || lk == 121620 // '{' 'start'
+ || lk == 123156 // '{' 'strict'
+ || lk == 124180 // '{' 'structured-item'
+ || lk == 124692 // '{' 'switch'
+ || lk == 125204 // '{' 'text'
+ || lk == 127252 // '{' 'to'
+ || lk == 127764 // '{' 'treat'
+ || lk == 128276 // '{' 'try'
+ || lk == 128788 // '{' 'tumbling'
+ || lk == 129300 // '{' 'type'
+ || lk == 129812 // '{' 'typeswitch'
+ || lk == 130324 // '{' 'union'
+ || lk == 131348 // '{' 'unordered'
+ || lk == 131860 // '{' 'updating'
+ || lk == 133396 // '{' 'validate'
+ || lk == 133908 // '{' 'value'
+ || lk == 134420 // '{' 'variable'
+ || lk == 134932 // '{' 'version'
+ || lk == 136468 // '{' 'where'
+ || lk == 136980 // '{' 'while'
+ || lk == 138516 // '{' 'with'
+ || lk == 140564 // '{' 'xquery'
+ || lk == 141588 // '{' '{'
+ || lk == 142612 // '{' '{|'
+ || lk == 144660) // '{' '}'
+ {
+ lk = memoized(14, e0);
+ if (lk == 0)
+ {
+ var b0A = b0; var e0A = e0; var l1A = l1;
+ var b1A = b1; var e1A = e1; var l2A = l2;
+ var b2A = b2; var e2A = e2;
+ try
+ {
+ try_BlockExpr();
+ memoize(14, e0A, -10);
+ lk = -14;
+ }
+ catch (p10A)
+ {
+ lk = -11;
+ b0 = b0A; e0 = e0A; l1 = l1A; if (l1 == 0) {end = e0A;} else {
+ b1 = b1A; e1 = e1A; l2 = l2A; if (l2 == 0) {end = e1A;} else {
+ b2 = b2A; e2 = e2A; end = e2A; }}
+ memoize(14, e0A, -11);
+ }
+ }
+ }
+ switch (lk)
+ {
+ case 8: // IntegerLiteral
+ case 9: // DecimalLiteral
+ case 10: // DoubleLiteral
+ case 11: // StringLiteral
+ try_Literal();
+ break;
+ case 31: // '$'
+ try_VarRef();
+ break;
+ case 34: // '('
+ try_ParenthesizedExpr();
+ break;
+ case 44: // '.'
+ try_ContextItemExpr();
+ break;
+ case 17414: // EQName^Token '('
+ case 17478: // 'after' '('
+ case 17480: // 'allowing' '('
+ case 17481: // 'ancestor' '('
+ case 17482: // 'ancestor-or-self' '('
+ case 17483: // 'and' '('
+ case 17485: // 'append' '('
+ case 17487: // 'as' '('
+ case 17488: // 'ascending' '('
+ case 17489: // 'at' '('
+ case 17491: // 'base-uri' '('
+ case 17492: // 'before' '('
+ case 17493: // 'boundary-space' '('
+ case 17494: // 'break' '('
+ case 17496: // 'case' '('
+ case 17497: // 'cast' '('
+ case 17498: // 'castable' '('
+ case 17499: // 'catch' '('
+ case 17501: // 'child' '('
+ case 17502: // 'collation' '('
+ case 17505: // 'constraint' '('
+ case 17506: // 'construction' '('
+ case 17509: // 'context' '('
+ case 17510: // 'continue' '('
+ case 17511: // 'copy' '('
+ case 17512: // 'copy-namespaces' '('
+ case 17513: // 'count' '('
+ case 17514: // 'decimal-format' '('
+ case 17516: // 'declare' '('
+ case 17517: // 'default' '('
+ case 17518: // 'delete' '('
+ case 17519: // 'descendant' '('
+ case 17520: // 'descendant-or-self' '('
+ case 17521: // 'descending' '('
+ case 17526: // 'div' '('
+ case 17527: // 'document' '('
+ case 17530: // 'else' '('
+ case 17531: // 'empty' '('
+ case 17533: // 'encoding' '('
+ case 17534: // 'end' '('
+ case 17536: // 'eq' '('
+ case 17537: // 'every' '('
+ case 17539: // 'except' '('
+ case 17540: // 'exit' '('
+ case 17541: // 'external' '('
+ case 17542: // 'first' '('
+ case 17543: // 'following' '('
+ case 17544: // 'following-sibling' '('
+ case 17545: // 'for' '('
+ case 17549: // 'ft-option' '('
+ case 17554: // 'ge' '('
+ case 17556: // 'group' '('
+ case 17558: // 'gt' '('
+ case 17559: // 'idiv' '('
+ case 17561: // 'import' '('
+ case 17562: // 'in' '('
+ case 17563: // 'index' '('
+ case 17567: // 'insert' '('
+ case 17568: // 'instance' '('
+ case 17569: // 'integrity' '('
+ case 17570: // 'intersect' '('
+ case 17571: // 'into' '('
+ case 17572: // 'is' '('
+ case 17574: // 'json' '('
+ case 17578: // 'last' '('
+ case 17579: // 'lax' '('
+ case 17580: // 'le' '('
+ case 17582: // 'let' '('
+ case 17584: // 'loop' '('
+ case 17586: // 'lt' '('
+ case 17588: // 'mod' '('
+ case 17589: // 'modify' '('
+ case 17590: // 'module' '('
+ case 17592: // 'namespace' '('
+ case 17594: // 'ne' '('
+ case 17600: // 'nodes' '('
+ case 17602: // 'object' '('
+ case 17606: // 'only' '('
+ case 17607: // 'option' '('
+ case 17608: // 'or' '('
+ case 17609: // 'order' '('
+ case 17610: // 'ordered' '('
+ case 17611: // 'ordering' '('
+ case 17614: // 'parent' '('
+ case 17620: // 'preceding' '('
+ case 17621: // 'preceding-sibling' '('
+ case 17626: // 'rename' '('
+ case 17627: // 'replace' '('
+ case 17628: // 'return' '('
+ case 17629: // 'returning' '('
+ case 17630: // 'revalidation' '('
+ case 17632: // 'satisfies' '('
+ case 17633: // 'schema' '('
+ case 17636: // 'score' '('
+ case 17637: // 'self' '('
+ case 17642: // 'sliding' '('
+ case 17643: // 'some' '('
+ case 17644: // 'stable' '('
+ case 17645: // 'start' '('
+ case 17648: // 'strict' '('
+ case 17656: // 'to' '('
+ case 17657: // 'treat' '('
+ case 17658: // 'try' '('
+ case 17659: // 'tumbling' '('
+ case 17660: // 'type' '('
+ case 17662: // 'union' '('
+ case 17664: // 'unordered' '('
+ case 17665: // 'updating' '('
+ case 17668: // 'validate' '('
+ case 17669: // 'value' '('
+ case 17670: // 'variable' '('
+ case 17671: // 'version' '('
+ case 17674: // 'where' '('
+ case 17675: // 'while' '('
+ case 17678: // 'with' '('
+ case 17682: // 'xquery' '('
+ try_FunctionCall();
+ break;
+ case 141514: // 'ordered' '{'
+ try_OrderedExpr();
+ break;
+ case 141568: // 'unordered' '{'
+ try_UnorderedExpr();
+ break;
+ case 32: // '%'
+ case 78: // 'array'
+ case 120: // 'document-node'
+ case 124: // 'empty-sequence'
+ case 145: // 'function'
+ case 152: // 'if'
+ case 165: // 'item'
+ case 167: // 'json-item'
+ case 185: // 'namespace-node'
+ case 191: // 'node'
+ case 226: // 'schema-attribute'
+ case 227: // 'schema-element'
+ case 242: // 'structured-item'
+ case 243: // 'switch'
+ case 253: // 'typeswitch'
+ case 14854: // EQName^Token '#'
+ case 14918: // 'after' '#'
+ case 14920: // 'allowing' '#'
+ case 14921: // 'ancestor' '#'
+ case 14922: // 'ancestor-or-self' '#'
+ case 14923: // 'and' '#'
+ case 14925: // 'append' '#'
+ case 14927: // 'as' '#'
+ case 14928: // 'ascending' '#'
+ case 14929: // 'at' '#'
+ case 14930: // 'attribute' '#'
+ case 14931: // 'base-uri' '#'
+ case 14932: // 'before' '#'
+ case 14933: // 'boundary-space' '#'
+ case 14934: // 'break' '#'
+ case 14936: // 'case' '#'
+ case 14937: // 'cast' '#'
+ case 14938: // 'castable' '#'
+ case 14939: // 'catch' '#'
+ case 14941: // 'child' '#'
+ case 14942: // 'collation' '#'
+ case 14944: // 'comment' '#'
+ case 14945: // 'constraint' '#'
+ case 14946: // 'construction' '#'
+ case 14949: // 'context' '#'
+ case 14950: // 'continue' '#'
+ case 14951: // 'copy' '#'
+ case 14952: // 'copy-namespaces' '#'
+ case 14953: // 'count' '#'
+ case 14954: // 'decimal-format' '#'
+ case 14956: // 'declare' '#'
+ case 14957: // 'default' '#'
+ case 14958: // 'delete' '#'
+ case 14959: // 'descendant' '#'
+ case 14960: // 'descendant-or-self' '#'
+ case 14961: // 'descending' '#'
+ case 14966: // 'div' '#'
+ case 14967: // 'document' '#'
+ case 14969: // 'element' '#'
+ case 14970: // 'else' '#'
+ case 14971: // 'empty' '#'
+ case 14973: // 'encoding' '#'
+ case 14974: // 'end' '#'
+ case 14976: // 'eq' '#'
+ case 14977: // 'every' '#'
+ case 14979: // 'except' '#'
+ case 14980: // 'exit' '#'
+ case 14981: // 'external' '#'
+ case 14982: // 'first' '#'
+ case 14983: // 'following' '#'
+ case 14984: // 'following-sibling' '#'
+ case 14985: // 'for' '#'
+ case 14989: // 'ft-option' '#'
+ case 14994: // 'ge' '#'
+ case 14996: // 'group' '#'
+ case 14998: // 'gt' '#'
+ case 14999: // 'idiv' '#'
+ case 15001: // 'import' '#'
+ case 15002: // 'in' '#'
+ case 15003: // 'index' '#'
+ case 15007: // 'insert' '#'
+ case 15008: // 'instance' '#'
+ case 15009: // 'integrity' '#'
+ case 15010: // 'intersect' '#'
+ case 15011: // 'into' '#'
+ case 15012: // 'is' '#'
+ case 15014: // 'json' '#'
+ case 15018: // 'last' '#'
+ case 15019: // 'lax' '#'
+ case 15020: // 'le' '#'
+ case 15022: // 'let' '#'
+ case 15024: // 'loop' '#'
+ case 15026: // 'lt' '#'
+ case 15028: // 'mod' '#'
+ case 15029: // 'modify' '#'
+ case 15030: // 'module' '#'
+ case 15032: // 'namespace' '#'
+ case 15034: // 'ne' '#'
+ case 15040: // 'nodes' '#'
+ case 15042: // 'object' '#'
+ case 15046: // 'only' '#'
+ case 15047: // 'option' '#'
+ case 15048: // 'or' '#'
+ case 15049: // 'order' '#'
+ case 15050: // 'ordered' '#'
+ case 15051: // 'ordering' '#'
+ case 15054: // 'parent' '#'
+ case 15060: // 'preceding' '#'
+ case 15061: // 'preceding-sibling' '#'
+ case 15064: // 'processing-instruction' '#'
+ case 15066: // 'rename' '#'
+ case 15067: // 'replace' '#'
+ case 15068: // 'return' '#'
+ case 15069: // 'returning' '#'
+ case 15070: // 'revalidation' '#'
+ case 15072: // 'satisfies' '#'
+ case 15073: // 'schema' '#'
+ case 15076: // 'score' '#'
+ case 15077: // 'self' '#'
+ case 15082: // 'sliding' '#'
+ case 15083: // 'some' '#'
+ case 15084: // 'stable' '#'
+ case 15085: // 'start' '#'
+ case 15088: // 'strict' '#'
+ case 15092: // 'text' '#'
+ case 15096: // 'to' '#'
+ case 15097: // 'treat' '#'
+ case 15098: // 'try' '#'
+ case 15099: // 'tumbling' '#'
+ case 15100: // 'type' '#'
+ case 15102: // 'union' '#'
+ case 15104: // 'unordered' '#'
+ case 15105: // 'updating' '#'
+ case 15108: // 'validate' '#'
+ case 15109: // 'value' '#'
+ case 15110: // 'variable' '#'
+ case 15111: // 'version' '#'
+ case 15114: // 'where' '#'
+ case 15115: // 'while' '#'
+ case 15118: // 'with' '#'
+ case 15122: // 'xquery' '#'
+ try_FunctionItemExpr();
+ break;
+ case -10:
+ case 27412: // '{' ';'
+ try_BlockExpr();
+ break;
+ case -11:
+ try_ObjectConstructor();
+ break;
+ case 68: // '['
+ try_ArrayConstructor();
+ break;
+ case 278: // '{|'
+ try_JSONSimpleObjectUnion();
+ break;
+ case -14:
+ break;
+ default:
+ try_Constructor();
+ }
+ }
+
+ function parse_JSONSimpleObjectUnion()
+ {
+ eventHandler.startNonterminal("JSONSimpleObjectUnion", e0);
+ shift(278); // '{|'
+ lookahead1W(272); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 281) // '|}'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(281); // '|}'
+ eventHandler.endNonterminal("JSONSimpleObjectUnion", e0);
+ }
+
+ function try_JSONSimpleObjectUnion()
+ {
+ shiftT(278); // '{|'
+ lookahead1W(272); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 281) // '|}'
+ {
+ try_Expr();
+ }
+ shiftT(281); // '|}'
+ }
+
+ function parse_ObjectConstructor()
+ {
+ eventHandler.startNonterminal("ObjectConstructor", e0);
+ shift(276); // '{'
+ lookahead1W(273); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 282) // '}'
+ {
+ whitespace();
+ parse_PairConstructorList();
+ }
+ shift(282); // '}'
+ eventHandler.endNonterminal("ObjectConstructor", e0);
+ }
+
+ function try_ObjectConstructor()
+ {
+ shiftT(276); // '{'
+ lookahead1W(273); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 282) // '}'
+ {
+ try_PairConstructorList();
+ }
+ shiftT(282); // '}'
+ }
+
+ function parse_PairConstructorList()
+ {
+ eventHandler.startNonterminal("PairConstructorList", e0);
+ parse_PairConstructor();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shift(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_PairConstructor();
+ }
+ eventHandler.endNonterminal("PairConstructorList", e0);
+ }
+
+ function try_PairConstructorList()
+ {
+ try_PairConstructor();
+ for (;;)
+ {
+ if (l1 != 41) // ','
+ {
+ break;
+ }
+ shiftT(41); // ','
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_PairConstructor();
+ }
+ }
+
+ function parse_PairConstructor()
+ {
+ eventHandler.startNonterminal("PairConstructor", e0);
+ parse_ExprSingle();
+ shift(49); // ':'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_ExprSingle();
+ eventHandler.endNonterminal("PairConstructor", e0);
+ }
+
+ function try_PairConstructor()
+ {
+ try_ExprSingle();
+ shiftT(49); // ':'
+ lookahead1W(266); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_ExprSingle();
+ }
+
+ function parse_ArrayConstructor()
+ {
+ eventHandler.startNonterminal("ArrayConstructor", e0);
+ shift(68); // '['
+ lookahead1W(271); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 69) // ']'
+ {
+ whitespace();
+ parse_Expr();
+ }
+ shift(69); // ']'
+ eventHandler.endNonterminal("ArrayConstructor", e0);
+ }
+
+ function try_ArrayConstructor()
+ {
+ shiftT(68); // '['
+ lookahead1W(271); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ if (l1 != 69) // ']'
+ {
+ try_Expr();
+ }
+ shiftT(69); // ']'
+ }
+
+ function parse_BlockExpr()
+ {
+ eventHandler.startNonterminal("BlockExpr", e0);
+ shift(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_StatementsAndOptionalExpr();
+ shift(282); // '}'
+ eventHandler.endNonterminal("BlockExpr", e0);
+ }
+
+ function try_BlockExpr()
+ {
+ shiftT(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ try_StatementsAndOptionalExpr();
+ shiftT(282); // '}'
+ }
+
+ function parse_FunctionDecl()
+ {
+ eventHandler.startNonterminal("FunctionDecl", e0);
+ shift(145); // 'function'
+ lookahead1W(254); // EQName^Token | S^WS | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_EQName();
+ lookahead1W(22); // S^WS | '(' | '(:'
+ shift(34); // '('
+ lookahead1W(94); // S^WS | '$' | '(:' | ')'
+ if (l1 == 31) // '$'
+ {
+ whitespace();
+ parse_ParamList();
+ }
+ shift(37); // ')'
+ lookahead1W(148); // S^WS | '(:' | 'as' | 'external' | '{'
+ if (l1 == 79) // 'as'
+ {
+ whitespace();
+ parse_ReturnType();
+ }
+ lookahead1W(118); // S^WS | '(:' | 'external' | '{'
+ switch (l1)
+ {
+ case 276: // '{'
+ shift(276); // '{'
+ lookahead1W(276); // Wildcard | EQName^Token | IntegerLiteral | DecimalLiteral | DoubleLiteral |
+ whitespace();
+ parse_StatementsAndOptionalExpr();
+ shift(282); // '}'
+ break;
+ default:
+ shift(133); // 'external'
+ }
+ eventHandler.endNonterminal("FunctionDecl", e0);
+ }
+
+ function parse_ReturnType()
+ {
+ eventHandler.startNonterminal("ReturnType", e0);
+ shift(79); // 'as'
+ lookahead1W(259); // EQName^Token | S^WS | '%' | '(' | '(:' | 'after' | 'allowing' | 'ancestor' |
+ whitespace();
+ parse_SequenceType();
+ eventHandler.endNonterminal("ReturnType", e0);
+ }
+
+ function shift(t)
+ {
+ if (l1 == t)
+ {
+ whitespace();
+ eventHandler.terminal(XQueryParser.TOKEN[l1], b1, e1 > size ? size : e1);
+ b0 = b1; e0 = e1; l1 = l2; if (l1 != 0) {
+ b1 = b2; e1 = e2; l2 = 0; }
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function shiftT(t)
+ {
+ if (l1 == t)
+ {
+ b0 = b1; e0 = e1; l1 = l2; if (l1 != 0) {
+ b1 = b2; e1 = e2; l2 = 0; }
+ }
+ else
+ {
+ error(b1, e1, 0, l1, t);
+ }
+ }
+
+ function skip(code)
+ {
+ var b0W = b0; var e0W = e0; var l1W = l1;
+ var b1W = b1; var e1W = e1;
+
+ l1 = code; b1 = begin; e1 = end;
+ l2 = 0;
+
+ try_Whitespace();
+
+ b0 = b0W; e0 = e0W; l1 = l1W; if (l1 != 0) {
+ b1 = b1W; e1 = e1W; }
+ }
+
+ function whitespace()
+ {
+ if (e0 != b1)
+ {
+ eventHandler.whitespace(e0, b1);
+ e0 = b1;
+ }
+ }
+
+ function matchW(set)
+ {
+ var code;
+ for (;;)
+ {
+ code = match(set);
+ if (code != 22) // S^WS
+ {
+ if (code != 36) // '(:'
+ {
+ break;
+ }
+ skip(code);
+ }
+ }
+ return code;
+ }
+
+ function lookahead1W(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = matchW(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead2W(set)
+ {
+ if (l2 == 0)
+ {
+ l2 = matchW(set);
+ b2 = begin;
+ e2 = end;
+ }
+ lk = (l2 << 9) | l1;
+ }
+
+ function lookahead1(set)
+ {
+ if (l1 == 0)
+ {
+ l1 = match(set);
+ b1 = begin;
+ e1 = end;
+ }
+ }
+
+ function lookahead2(set)
+ {
+ if (l2 == 0)
+ {
+ l2 = match(set);
+ b2 = begin;
+ e2 = end;
+ }
+ lk = (l2 << 9) | l1;
+ }
+
+ function error(b, e, s, l, t)
+ {
+ if (e >= ex)
+ {
+ bx = b;
+ ex = e;
+ sx = s;
+ lx = l;
+ tx = t;
+ }
+ throw new self.ParseException(bx, ex, sx, lx, tx);
+ }
+
+ var lk, b0, e0;
+ var l1, b1, e1;
+ var l2, b2, e2;
+ var bx, ex, sx, lx, tx;
+ var eventHandler;
+ var memo;
+
+ function memoize(i, e, v)
+ {
+ memo[(e << 4) + i] = v;
+ }
+
+ function memoized(i, e)
+ {
+ var v = memo[(e << 4) + i];
+ return typeof v != "undefined" ? v : 0;
+ }
+
+ var input;
+ var size;
+ var begin;
+ var end;
+
+ function match(tokenSetId)
+ {
+ var nonbmp = false;
+ begin = end;
+ var current = end;
+ var result = XQueryParser.INITIAL[tokenSetId];
+ var state = 0;
+
+ for (var code = result & 4095; code != 0; )
+ {
+ var charclass;
+ var c0 = current < size ? input.charCodeAt(current) : 0;
+ ++current;
+ if (c0 < 0x80)
+ {
+ charclass = XQueryParser.MAP0[c0];
+ }
+ else if (c0 < 0xd800)
+ {
+ var c1 = c0 >> 4;
+ charclass = XQueryParser.MAP1[(c0 & 15) + XQueryParser.MAP1[(c1 & 31) + XQueryParser.MAP1[c1 >> 5]]];
+ }
+ else
+ {
+ if (c0 < 0xdc00)
+ {
+ var c1 = current < size ? input.charCodeAt(current) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000)
+ {
+ ++current;
+ c0 = ((c0 & 0x3ff) << 10) + (c1 & 0x3ff) + 0x10000;
+ nonbmp = true;
+ }
+ }
+ var lo = 0, hi = 5;
+ for (var m = 3; ; m = (hi + lo) >> 1)
+ {
+ if (XQueryParser.MAP2[m] > c0) hi = m - 1;
+ else if (XQueryParser.MAP2[6 + m] < c0) lo = m + 1;
+ else {charclass = XQueryParser.MAP2[12 + m]; break;}
+ if (lo > hi) {charclass = 0; break;}
+ }
+ }
+
+ state = code;
+ var i0 = (charclass << 12) + code - 1;
+ code = XQueryParser.TRANSITION[(i0 & 15) + XQueryParser.TRANSITION[i0 >> 4]];
+
+ if (code > 4095)
+ {
+ result = code;
+ code &= 4095;
+ end = current;
+ }
+ }
+
+ result >>= 12;
+ if (result == 0)
+ {
+ end = current - 1;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ return error(begin, end, state, -1, -1);
+ }
+
+ if (nonbmp)
+ {
+ for (var i = result >> 9; i > 0; --i)
+ {
+ --end;
+ var c1 = end < size ? input.charCodeAt(end) : 0;
+ if (c1 >= 0xdc00 && c1 < 0xe000) --end;
+ }
+ }
+ else
+ {
+ end -= result >> 9;
+ }
+
+ return (result & 511) - 1;
+ }
+}
+
+XQueryParser.getTokenSet = function(tokenSetId)
+{
+ var set = [];
+ var s = tokenSetId < 0 ? - tokenSetId : XQueryParser.INITIAL[tokenSetId] & 4095;
+ for (var i = 0; i < 284; i += 32)
+ {
+ var j = i;
+ var i0 = (i >> 5) * 3612 + s - 1;
+ var i1 = i0 >> 2;
+ var i2 = i1 >> 2;
+ var f = XQueryParser.EXPECTED[(i0 & 3) + XQueryParser.EXPECTED[(i1 & 3) + XQueryParser.EXPECTED[(i2 & 15) + XQueryParser.EXPECTED[i2 >> 4]]]];
+ for ( ; f != 0; f >>>= 1, ++j)
+ {
+ if ((f & 1) != 0)
+ {
+ set.push(XQueryParser.TOKEN[j]);
+ }
+ }
+ }
+ return set;
+};
+
+XQueryParser.MAP0 =
+[ 70, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 26, 30, 30, 30, 30, 30, 31, 32, 33, 30, 30, 34, 30, 30, 35, 30, 30, 30, 36, 30, 30, 37, 38, 39, 38, 30, 38, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 38, 38
+];
+
+XQueryParser.MAP1 =
+[ 108, 124, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 156, 181, 181, 181, 181, 181, 214, 215, 213, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 214, 247, 261, 277, 293, 309, 355, 371, 387, 423, 423, 423, 415, 339, 331, 339, 331, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 440, 440, 440, 440, 440, 440, 440, 324, 339, 339, 339, 339, 339, 339, 339, 339, 401, 423, 423, 424, 422, 423, 423, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 338, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 339, 423, 70, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 26, 30, 30, 30, 30, 30, 31, 32, 33, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 38, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 34, 30, 30, 35, 30, 30, 30, 36, 30, 30, 37, 38, 39, 38, 30, 38, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 30, 30, 38, 38, 38, 38, 38, 38, 38, 69, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69, 69
+];
+
+XQueryParser.MAP2 =
+[ 57344, 63744, 64976, 65008, 65536, 983040, 63743, 64975, 65007, 65533, 983039, 1114111, 38, 30, 38, 30, 30, 38
+];
+
+XQueryParser.INITIAL =
+[ 1, 12290, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 255, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, 285, 286
+];
+
+XQueryParser.TRANSITION =
+[ 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25307, 18176, 18180, 18180, 18180, 18210, 18180, 18180, 18180, 18180, 18222, 18180, 18180, 18180, 18180, 18198, 18180, 18182, 18238, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 38623, 20771, 20784, 20796, 20808, 43870, 38625, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 28718, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19553, 19028, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22954, 20869, 38672, 38672, 38672, 37958, 38672, 38672, 36976, 20909, 20888, 38672, 38672, 38672, 38672, 39926, 20282, 20925, 20958, 38672, 38672, 38672, 43215, 38672, 38672, 25928, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 20997, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 21013, 21118, 38672, 38672, 38672, 24651, 38672, 38672, 44696, 38672, 42922, 38824, 21095, 21058, 21048, 21080, 21111, 48022, 20832, 38672, 38672, 38672, 43215, 21139, 38672, 25530, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 21157, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 18776, 18792, 20360, 18810, 18830, 18835, 19257, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38666, 38672, 38672, 38672, 21880, 38671, 38672, 36460, 38672, 21173, 38661, 21224, 38672, 21231, 38672, 42738, 42750, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 21247, 38672, 38672, 38672, 28875, 38672, 38672, 21266, 38672, 38672, 21288, 21300, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 31059, 38672, 38672, 38672, 38672, 38672, 38672, 24860, 21316, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 18988, 50434, 18503, 18525, 21353, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 24749, 21390, 38672, 38672, 38672, 23220, 38672, 38672, 49687, 45814, 21411, 38672, 38672, 38672, 38672, 41859, 18366, 21448, 21478, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 21515, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 46185, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 21462, 21573, 21537, 21537, 21537, 21580, 21532, 21537, 21542, 21615, 21558, 21644, 21596, 21609, 21631, 21657, 21669, 21681, 20832, 38672, 38672, 38672, 21337, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 21697, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 30462, 38672, 38672, 38672, 22025, 23251, 38672, 22249, 23257, 42922, 30462, 38672, 21719, 21725, 21741, 21766, 21750, 21795, 38672, 38672, 38672, 46035, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 30475, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 24785, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 37115, 50393, 21856, 21832, 21850, 21834, 21872, 21896, 21908, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 21924, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 37301, 25812, 27394, 21985, 22003, 21985, 22017, 27392, 21987, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 42072, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 20981, 38672, 38672, 38672, 30470, 24643, 38672, 48413, 22054, 26165, 22041, 22070, 22074, 22074, 22090, 20979, 48442, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22114, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 47221, 22137, 22155, 22137, 22169, 47219, 22139, 22193, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 22230, 38672, 22247, 38672, 29641, 22265, 42072, 33771, 38672, 38672, 38672, 38672, 26929, 22475, 35267, 22475, 22475, 36544, 42277, 22411, 22411, 33858, 26727, 37227, 26727, 26727, 35540, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 18609, 24891, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 21432, 38031, 38672, 38672, 38672, 38672, 38672, 22291, 38672, 26931, 22311, 22475, 22475, 22475, 22475, 33849, 22352, 22411, 35447, 22411, 22411, 33324, 22381, 26727, 45449, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 30028, 38672, 38672, 22475, 36607, 22475, 22475, 28015, 33854, 22411, 22410, 22411, 22411, 27851, 26727, 45441, 26727, 26727, 22521, 33795, 38672, 38672, 22807, 38672, 38672, 28255, 22475, 22475, 38505, 29442, 22411, 22411, 34626, 26485, 26727, 26727, 26860, 26998, 22647, 38672, 38672, 22428, 26931, 48359, 22475, 42142, 32794, 22411, 28347, 37402, 26727, 22521, 32486, 38672, 18915, 38672, 22451, 22474, 36860, 37042, 22411, 22492, 22517, 22520, 26312, 34036, 26929, 42625, 42144, 35207, 26975, 22537, 26310, 35759, 22589, 36765, 22624, 22640, 22663, 22685, 22706, 39617, 42139, 28345, 26456, 39814, 47009, 22727, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 23092, 42922, 38672, 38672, 38672, 38672, 38672, 31140, 31152, 22751, 38672, 38672, 38672, 43215, 38672, 38672, 26131, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 27937, 27268, 22230, 38672, 38672, 38672, 29641, 38672, 40144, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 36544, 22411, 22411, 22411, 33858, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 18609, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 22803, 38672, 38672, 38672, 22886, 38672, 38672, 38672, 38672, 42922, 36439, 22823, 22844, 22866, 22878, 36438, 22828, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 41329, 38672, 22902, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 22923, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 23115, 42922, 38672, 38672, 38672, 38672, 38672, 26339, 22940, 22970, 38672, 38672, 38672, 43215, 38672, 38672, 23007, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 47631, 27268, 22230, 38672, 38672, 38672, 29641, 38672, 48650, 23029, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 36544, 22411, 22411, 22411, 33858, 26727, 26727, 26727, 26727, 30990, 42723, 23085, 38672, 38672, 38672, 38672, 38672, 23048, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 23072, 23108, 38672, 38672, 38672, 38672, 38672, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 46833, 22411, 22411, 22411, 22411, 22411, 47864, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 43252, 33854, 22411, 22411, 22411, 22411, 48185, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 18878, 38672, 38672, 38672, 35592, 32963, 38672, 38672, 23153, 42922, 37950, 35335, 23190, 23196, 23212, 38672, 41919, 23236, 23274, 38672, 38672, 45078, 23291, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 25157, 23483, 23350, 24209, 23309, 45351, 38672, 18269, 42564, 28228, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19821, 23376, 23336, 23369, 23392, 24203, 23434, 23465, 24172, 23726, 19833, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 18729, 23481, 23642, 24581, 23499, 23504, 24048, 23353, 23520, 23933, 23353, 24164, 23917, 24518, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 23536, 23854, 23815, 23561, 23577, 23632, 24450, 24255, 23689, 23658, 23674, 23716, 23742, 24268, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 23773, 23804, 23842, 24040, 23870, 23886, 23449, 23700, 23902, 23320, 23949, 23992, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 24027, 23545, 23592, 24064, 24137, 24459, 24094, 24110, 23407, 20069, 47383, 20010, 46515, 35979, 20039, 20679, 24126, 24567, 24482, 24153, 24188, 23616, 24225, 20191, 20207, 20223, 20259, 20298, 20337, 24284, 24078, 24374, 24300, 24330, 24314, 23418, 20424, 20452, 20468, 24361, 23826, 23606, 24390, 24419, 20532, 24435, 24475, 24498, 24628, 20608, 23750, 23928, 24403, 20644, 23757, 24508, 20660, 20054, 24345, 20695, 24537, 24597, 24613, 24552, 23788, 24240, 23964, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 39906, 38672, 38672, 38672, 30470, 24672, 38672, 38672, 24667, 26611, 24688, 24695, 24695, 24695, 24711, 26910, 24735, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 24765, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 20739, 24828, 48943, 18855, 18871, 18894, 40258, 24858, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19087, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 24876, 24922, 24938, 19905, 19631, 19046, 24954, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 24970, 18446, 19976, 19994, 19525, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 21250, 35576, 24999, 24999, 24999, 35584, 31668, 31680, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 25271, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 19887, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 50381, 27744, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 40452, 25015, 25015, 25015, 25023, 27746, 40454, 20832, 25047, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 25065, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 20310, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 50286, 50295, 38672, 38672, 38672, 23056, 38672, 38672, 38672, 38672, 42922, 44048, 25088, 25088, 25088, 25096, 46630, 44050, 25120, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 18699, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 25136, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 25152, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25173, 38672, 38672, 38672, 38672, 30470, 25218, 38672, 38672, 21395, 32346, 38672, 38672, 38672, 25210, 25237, 21393, 25221, 25256, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 22214, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19206, 20349, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 38672, 41563, 25293, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 48405, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 34976, 38672, 38672, 22475, 22475, 22475, 22475, 33754, 33854, 22411, 22411, 22411, 22411, 31454, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 25437, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 48405, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 33754, 33854, 22411, 22411, 22411, 22411, 31454, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 48405, 30057, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 33754, 33854, 22411, 22411, 22411, 22411, 31454, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 48405, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 25455, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 33754, 33854, 22411, 22411, 22411, 22411, 31454, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 40102, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 49130, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 48405, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 33754, 33854, 22411, 22411, 22411, 22411, 31454, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25482, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25500, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38220, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 25563, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 28464, 25582, 25594, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 21426, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25610, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 44752, 25631, 25649, 25671, 25683, 44753, 25633, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 35735, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 25717, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 38672, 38672, 24860, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 31997, 38672, 25754, 25760, 25776, 23293, 41839, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 25800, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 25828, 20548, 20592, 20589, 50171, 25844, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 25049, 38672, 38672, 38672, 22098, 25865, 25896, 25377, 25881, 25913, 30410, 30418, 25964, 25978, 25990, 26006, 26018, 25344, 45647, 38672, 26034, 48091, 26052, 33210, 26086, 26116, 26153, 26223, 35321, 26181, 25701, 26211, 26248, 26264, 43583, 44602, 26280, 26296, 26329, 38672, 38672, 38672, 30176, 26355, 38925, 41958, 22850, 24803, 38672, 44654, 30480, 22475, 22475, 22475, 36601, 25393, 22411, 22411, 43601, 22690, 26727, 26727, 26727, 39641, 30990, 39463, 38672, 43148, 28319, 38672, 29724, 26374, 19326, 38672, 38672, 32428, 40296, 38574, 45608, 22475, 22475, 26394, 26439, 26475, 26509, 22411, 37859, 28780, 26529, 38451, 26727, 26727, 43300, 45056, 22573, 30349, 25414, 26545, 38672, 26563, 38672, 40287, 48411, 38672, 26599, 35364, 28653, 26627, 31403, 45616, 49789, 33849, 44356, 22411, 30609, 28411, 41138, 33324, 35718, 26727, 47625, 44193, 29223, 41749, 42781, 38094, 28940, 38672, 21816, 21032, 26644, 38672, 47420, 26664, 22475, 41307, 22336, 31195, 39296, 22411, 22411, 26685, 31454, 47988, 26726, 26727, 30787, 32911, 36940, 26744, 38697, 46064, 38672, 26779, 26799, 26821, 22787, 22475, 23131, 26837, 37515, 22411, 36778, 26853, 26876, 26727, 33519, 46887, 26926, 38672, 38672, 26931, 37355, 35081, 26947, 38899, 38878, 26969, 48550, 26727, 26994, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 38555, 27014, 22600, 47761, 48246, 27057, 27076, 27094, 27113, 28343, 26456, 27133, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 27153, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 39378, 27172, 38672, 27196, 27202, 27218, 27234, 27246, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 27262, 42259, 26453, 27284, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 46100, 48405, 27326, 25277, 38672, 38672, 28258, 22475, 22475, 22475, 37137, 27346, 22411, 22411, 22411, 22411, 39760, 37334, 26727, 26727, 26727, 26727, 27410, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 41804, 38672, 38672, 27435, 38672, 38672, 33108, 38672, 49441, 22475, 22475, 22475, 38002, 42895, 22411, 22411, 22411, 22411, 27454, 27481, 26727, 26727, 26727, 43058, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 46997, 37168, 35831, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 27504, 38672, 38672, 22098, 38672, 27541, 38672, 27559, 23976, 27578, 27586, 27602, 27617, 27629, 27645, 27657, 25344, 38672, 38672, 27676, 44992, 38672, 22924, 38672, 38672, 38672, 38672, 38672, 38672, 27673, 50511, 27692, 47251, 26513, 26453, 41246, 27710, 25375, 29768, 38672, 38672, 32334, 38672, 27740, 38672, 27762, 27784, 38672, 25948, 27789, 27805, 27821, 22475, 22475, 27840, 27878, 22411, 22411, 22690, 27915, 27931, 26727, 26727, 30990, 39463, 44557, 38672, 38672, 44934, 38672, 38225, 48405, 33126, 27953, 38672, 38672, 27694, 47073, 35424, 37245, 22475, 35786, 48497, 47338, 42686, 30280, 22411, 37334, 37394, 27977, 27995, 43743, 26727, 32919, 30349, 25414, 38672, 38672, 24003, 38672, 30096, 48411, 38672, 38672, 26931, 22475, 22475, 22475, 28013, 28031, 33849, 22411, 22411, 22411, 28053, 28070, 33324, 26727, 26727, 26727, 28092, 28109, 32918, 41804, 28131, 38672, 38672, 49206, 38672, 28149, 38672, 22475, 22475, 22475, 22780, 33754, 33854, 22411, 22411, 42031, 22411, 31454, 26727, 26727, 26727, 28171, 22521, 33795, 38672, 38672, 31346, 38672, 46687, 21493, 22475, 28191, 22475, 23131, 22411, 30274, 22411, 36778, 26727, 35228, 26727, 31599, 28213, 38672, 38672, 38672, 28250, 28274, 47411, 42142, 28296, 31494, 28347, 36728, 31954, 22521, 26313, 38672, 38672, 28317, 27136, 22475, 28335, 22411, 36897, 26977, 26727, 22564, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 28363, 28379, 28427, 28480, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 28504, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 24521, 38672, 38672, 22098, 38672, 28530, 45484, 38672, 46575, 28549, 28557, 28573, 28587, 28595, 28611, 28623, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 19750, 26547, 38672, 26546, 19755, 28639, 42141, 48492, 27360, 44280, 27268, 25375, 29257, 27180, 28679, 29641, 21703, 38672, 25730, 38672, 38083, 42329, 28697, 28734, 27137, 27824, 36531, 43498, 28750, 22608, 46434, 28774, 46408, 28796, 28814, 28833, 26727, 28849, 39463, 38672, 38672, 38672, 25738, 38672, 29761, 48405, 38672, 38672, 38672, 19698, 28258, 22475, 22475, 22475, 27023, 35786, 22411, 22411, 22411, 22411, 28891, 37334, 26727, 26727, 26727, 26727, 28912, 43066, 28929, 28956, 38672, 38672, 33876, 38672, 28992, 48411, 38672, 38672, 29009, 29030, 27032, 22475, 22475, 22669, 33849, 29109, 45393, 22411, 22411, 32729, 33324, 29133, 37067, 26727, 26727, 34717, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 29157, 38672, 29181, 22475, 22475, 29202, 33754, 43112, 22411, 22411, 32083, 22411, 34472, 29222, 26727, 26727, 29239, 22521, 33795, 38672, 29256, 29273, 38672, 29294, 28255, 32383, 27117, 29315, 23131, 44876, 34578, 42252, 36778, 44915, 26727, 29337, 26998, 46887, 21810, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 29370, 38672, 27136, 22475, 29387, 22411, 41041, 26977, 26727, 43751, 26312, 34036, 26929, 22475, 42144, 22411, 29411, 29240, 26310, 35759, 22476, 22411, 26978, 48196, 29430, 26953, 38544, 39617, 34809, 33567, 37775, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38673, 29464, 38672, 22098, 22435, 29483, 38672, 29506, 26195, 29530, 29540, 29556, 29570, 29582, 29598, 29610, 25344, 38672, 29626, 25072, 29668, 50094, 29711, 40102, 40331, 29748, 21064, 29784, 29812, 29843, 29873, 29903, 29919, 29957, 26423, 29973, 30010, 25375, 30044, 30091, 38782, 30112, 30134, 26137, 30161, 38672, 38672, 26583, 38672, 26929, 39099, 30212, 36878, 44806, 30228, 43650, 28758, 46842, 30244, 46765, 30296, 30317, 30336, 30384, 39463, 20089, 31354, 30434, 38799, 41183, 30450, 30496, 38672, 30542, 30564, 29278, 30580, 39823, 30631, 28663, 42103, 30647, 30685, 30712, 30766, 30811, 30837, 34161, 30878, 30901, 34681, 30930, 30980, 31006, 31022, 25414, 31049, 38672, 18321, 49090, 31075, 31094, 31128, 34195, 32584, 46802, 31168, 22475, 33645, 42347, 31190, 47486, 31211, 22411, 47598, 49959, 31232, 32841, 31257, 26727, 39569, 42011, 31278, 31335, 49499, 35851, 39273, 31370, 43966, 34186, 21188, 33468, 37601, 29186, 31389, 31426, 42239, 40895, 22411, 31442, 31481, 31454, 31519, 31539, 30795, 31561, 31595, 33795, 38672, 48757, 39401, 38672, 30196, 28255, 39519, 43549, 31615, 23131, 34822, 47675, 31635, 36778, 22546, 47769, 31572, 26998, 46887, 39201, 31656, 18290, 31696, 31734, 31750, 31772, 31808, 31845, 31869, 31903, 37385, 31919, 31970, 26378, 18593, 32021, 48908, 39526, 44237, 32042, 32063, 32099, 48723, 41712, 26312, 41270, 26929, 22475, 32144, 22411, 32167, 44894, 26310, 32185, 46276, 40692, 44326, 31465, 20435, 32208, 32228, 32248, 32274, 32295, 32319, 32362, 32399, 32415, 28257, 28345, 26459, 32457, 32473, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 32509, 38672, 22098, 32530, 32548, 43771, 30190, 32600, 32630, 38672, 32616, 32654, 32662, 32678, 32690, 25344, 38672, 38672, 48277, 43215, 38672, 38672, 38672, 38672, 29732, 38672, 38672, 32706, 29731, 26036, 33631, 42208, 32724, 38438, 44280, 27268, 25375, 21272, 38672, 38672, 31985, 38672, 38672, 38672, 26576, 32745, 36837, 38672, 26929, 32766, 22475, 22475, 22475, 32810, 32857, 22411, 22411, 22690, 27419, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 48405, 38672, 38672, 40108, 38672, 28258, 22475, 22475, 22475, 42113, 35786, 22411, 22411, 22411, 22411, 32877, 37334, 26727, 26727, 26727, 26728, 26727, 32919, 30349, 25414, 38672, 38672, 38672, 38672, 38672, 48411, 32026, 38672, 26931, 22475, 22475, 46869, 22475, 22475, 33849, 22411, 22411, 39678, 22411, 22411, 33324, 26727, 26727, 41099, 26727, 26727, 32918, 41804, 38672, 38672, 38672, 38672, 38672, 30118, 38672, 22475, 22475, 22475, 42121, 33754, 33854, 22411, 22411, 48685, 22411, 31454, 26727, 26727, 26727, 46758, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 23131, 22411, 22411, 22411, 36778, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 36404, 38672, 38672, 38672, 44299, 22475, 42143, 31823, 22411, 32169, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 27097, 32897, 36362, 47020, 32935, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 25031, 38672, 38672, 43445, 32979, 32987, 33003, 33009, 33025, 33041, 33053, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 29467, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 33069, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 33103, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 33124, 38672, 18284, 28258, 22475, 22475, 22475, 22475, 40837, 22411, 22411, 22411, 22411, 22411, 34394, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 33142, 38672, 33163, 42808, 38672, 42803, 38566, 22475, 22475, 37994, 22475, 22475, 33849, 22411, 22411, 47479, 22411, 22411, 33324, 26727, 26727, 31312, 26727, 26727, 41720, 33181, 38672, 38672, 34958, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 34949, 49071, 38672, 28255, 22475, 22475, 29048, 29442, 22411, 22411, 43834, 26485, 26727, 26727, 49882, 26998, 33184, 33200, 40222, 33234, 22991, 22475, 33277, 33313, 50063, 43479, 33349, 26727, 33377, 32128, 26313, 33405, 26648, 22985, 33423, 33443, 35387, 48797, 34523, 33492, 40922, 33514, 26312, 34036, 46959, 32375, 33535, 33554, 33575, 35236, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 28488, 33591, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 32005, 38672, 38672, 33617, 38672, 38672, 38672, 30064, 38672, 30073, 38672, 30064, 33661, 30069, 38721, 42958, 22411, 33692, 33700, 33716, 25375, 38672, 38672, 25941, 29641, 33732, 20082, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 33752, 25393, 22411, 22411, 23137, 22690, 26727, 26727, 26727, 49362, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25615, 38672, 33770, 28258, 22475, 22475, 22475, 22475, 40491, 22411, 22411, 22411, 22411, 22411, 40736, 26727, 26727, 26727, 26727, 26727, 33787, 33803, 33407, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 33819, 48351, 22475, 22475, 22475, 22475, 33849, 46363, 22411, 22411, 22411, 22411, 33324, 48523, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 48282, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 33840, 33854, 22411, 22411, 22411, 28403, 27851, 26727, 26727, 26727, 43360, 22521, 33795, 38672, 38672, 42813, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 33874, 21141, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 33892, 34036, 21208, 22475, 46215, 22411, 33914, 26727, 33935, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 42795, 38672, 22098, 25439, 25194, 32493, 40646, 40656, 38304, 38312, 33959, 33974, 33986, 34002, 34014, 25344, 38672, 38672, 38672, 49261, 33079, 38672, 38672, 23275, 34030, 34052, 38672, 34078, 34127, 34177, 34211, 38408, 34239, 34258, 29354, 34285, 25375, 38672, 38672, 36069, 29641, 38672, 34301, 38672, 38672, 38672, 34327, 24011, 26929, 47957, 34366, 22475, 34410, 34439, 34460, 34488, 32881, 44853, 22711, 39788, 26727, 49664, 34508, 39463, 38672, 28969, 45656, 28681, 19706, 18253, 38672, 26070, 26232, 47650, 46594, 28258, 42618, 22475, 45107, 34547, 44588, 22411, 34575, 22411, 34594, 34618, 34642, 27997, 26727, 35481, 34668, 34697, 32919, 33803, 38672, 38672, 38672, 44387, 34733, 34759, 38672, 38672, 38672, 26931, 34796, 22475, 22475, 22475, 34845, 34862, 31216, 22411, 22411, 37262, 22411, 34878, 31262, 26727, 26727, 28913, 26727, 34894, 33802, 38672, 34931, 35005, 30145, 35033, 35049, 30548, 35079, 26669, 35097, 35117, 35142, 44418, 22411, 35167, 35192, 43624, 31718, 26727, 43013, 39321, 47169, 35252, 30750, 31033, 38672, 35289, 35307, 35357, 32192, 22475, 35380, 35403, 34559, 22411, 35440, 35463, 30821, 35479, 35497, 35530, 35556, 35608, 38672, 38672, 24906, 47811, 35630, 37839, 28037, 35670, 48379, 27078, 35705, 48704, 22521, 26313, 33898, 38672, 35734, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 28514, 35751, 26929, 35782, 35802, 36916, 32303, 49941, 26310, 49171, 22476, 22411, 26978, 48196, 35867, 35883, 35899, 35915, 42139, 28345, 26456, 28257, 28343, 26456, 35951, 36348, 35941, 33538, 36362, 36357, 34905, 35967, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 33252, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 20573, 33260, 46302, 45557, 36019, 36031, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 34780, 22475, 25393, 22411, 22411, 36047, 22690, 26727, 26727, 36130, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 20243, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 36066, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 45849, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 36085, 22475, 22475, 22475, 22475, 33849, 36106, 22411, 22411, 22411, 22411, 33324, 36126, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 19729, 38672, 22098, 38672, 39473, 38672, 44217, 36146, 36184, 36196, 36212, 36218, 36234, 36250, 36262, 25344, 38672, 36278, 38672, 43215, 38672, 25421, 18575, 38672, 27438, 38672, 38672, 46139, 36299, 48111, 34141, 26409, 36335, 39145, 44169, 36378, 36420, 36455, 38672, 29371, 36476, 38672, 27543, 38672, 36498, 35844, 31373, 34743, 36516, 40527, 36565, 29321, 36586, 36623, 36646, 22411, 36676, 29093, 36714, 29346, 28817, 43388, 36750, 36802, 37724, 36836, 38672, 38672, 38672, 26061, 38672, 38672, 38672, 38672, 38672, 28258, 36853, 42951, 22475, 36876, 38513, 34492, 36894, 36913, 40984, 22411, 43282, 35514, 28798, 26727, 43717, 26727, 36932, 33803, 38672, 38672, 36956, 38672, 38672, 18909, 32575, 38672, 38672, 26931, 22475, 22475, 41976, 35273, 36992, 33849, 22411, 22411, 45307, 44424, 37025, 33324, 26727, 26727, 40875, 39885, 37058, 32918, 33802, 34967, 38672, 38672, 32750, 38672, 38672, 38672, 22475, 38401, 22475, 22475, 28015, 33854, 34444, 22411, 22411, 22411, 27851, 26727, 37091, 26727, 26727, 22521, 33795, 37110, 34940, 38672, 46173, 45770, 29014, 37131, 22475, 22475, 37153, 29988, 22411, 22411, 37195, 37219, 26727, 26727, 36392, 46887, 38346, 38672, 39265, 26931, 22475, 37243, 42142, 22411, 37261, 28347, 26727, 37278, 22521, 26313, 38672, 37296, 38672, 27136, 22475, 37317, 22411, 48861, 26977, 26727, 48595, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 35925, 29395, 39608, 37350, 37371, 26459, 33538, 37783, 48331, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 41939, 38672, 22098, 38672, 25566, 38672, 38672, 29887, 39046, 39054, 37418, 37432, 37440, 37456, 37468, 25500, 38672, 37493, 38672, 43215, 38672, 28533, 38672, 38672, 27562, 38672, 38672, 37494, 37484, 23258, 20853, 42141, 37510, 47612, 44280, 27268, 25375, 38672, 29490, 38672, 29641, 38672, 37531, 37550, 38672, 38672, 38672, 37570, 27517, 39732, 22475, 40520, 37590, 25393, 37627, 22412, 37898, 37646, 31523, 26727, 48530, 31241, 31792, 37683, 37699, 24812, 38672, 37723, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 37740, 22475, 37799, 22475, 35786, 45030, 31853, 36110, 22411, 22411, 37334, 31545, 34712, 40790, 26727, 26727, 32919, 33803, 38672, 21024, 48965, 38672, 38672, 33943, 28155, 37816, 38672, 26931, 46335, 37834, 22475, 27041, 22475, 34377, 49011, 37855, 22411, 33297, 22411, 27890, 39339, 37875, 26727, 27899, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 48203, 38672, 38672, 38672, 26931, 29057, 22475, 42142, 32786, 22411, 28347, 22555, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 37895, 26977, 49110, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 37914, 31619, 41895, 26978, 37938, 37974, 41757, 45432, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 36549, 37075, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 25240, 38672, 24719, 38672, 46651, 38018, 25104, 38054, 38118, 38157, 38142, 38161, 38126, 38177, 38189, 25344, 38672, 45759, 49561, 49547, 38205, 49199, 38672, 38241, 38259, 34062, 38289, 38328, 38371, 38273, 38387, 38424, 38467, 39556, 38529, 27268, 25375, 40213, 38672, 38672, 38590, 21779, 38672, 38614, 38641, 21123, 43234, 38689, 38713, 41522, 39725, 26628, 22475, 25393, 38737, 22411, 29117, 22690, 32232, 31319, 26727, 38753, 34652, 38772, 35341, 38672, 38798, 38815, 38672, 38672, 40618, 38672, 38672, 38672, 38840, 33601, 40485, 22475, 38858, 22475, 35786, 47683, 38876, 40856, 22411, 22411, 37334, 32114, 26727, 42187, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 24776, 38672, 36500, 33087, 26755, 48300, 22475, 22475, 22475, 46796, 41600, 49410, 22411, 22411, 22411, 38894, 29994, 47730, 26727, 26727, 26727, 46465, 44085, 32918, 33802, 38915, 38949, 38972, 38992, 38672, 39015, 39031, 44824, 39070, 29039, 39086, 28015, 33854, 39115, 39131, 22365, 39171, 27851, 40395, 48234, 48581, 49654, 22521, 39190, 33147, 39225, 26763, 39254, 38337, 41515, 31410, 48668, 36570, 39289, 44624, 49920, 36050, 39312, 46490, 26727, 39337, 39355, 46887, 39394, 38672, 20942, 22766, 22475, 39417, 21499, 22411, 39448, 25398, 26727, 39489, 22521, 47568, 38672, 38672, 46680, 45512, 39505, 42143, 39542, 32076, 39585, 39633, 39657, 35567, 35614, 26929, 29075, 42144, 39674, 26975, 39694, 26310, 35759, 35126, 47451, 29414, 27465, 39712, 39748, 39776, 39804, 46246, 41657, 47873, 28257, 28343, 26456, 28257, 28345, 26459, 39839, 39865, 36357, 34905, 30398, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 39901, 22098, 38672, 30368, 39922, 38672, 45211, 39942, 39950, 39966, 39980, 39988, 40004, 40016, 25344, 35063, 40032, 40048, 40074, 25784, 40124, 38672, 40160, 20023, 50351, 40199, 40238, 40274, 40312, 49237, 40347, 40363, 36660, 40411, 40427, 25375, 38672, 40443, 18661, 36161, 37534, 38672, 18669, 43864, 38672, 38672, 44690, 26929, 22475, 37009, 40470, 40507, 25393, 22411, 40543, 31503, 45950, 26727, 47993, 40578, 40601, 30990, 39463, 38672, 44715, 38672, 38672, 40617, 29165, 40634, 41441, 21201, 19353, 22907, 40672, 45368, 47429, 22475, 22475, 40708, 37034, 28896, 40724, 22411, 47891, 41633, 40762, 35506, 40782, 26727, 47175, 32919, 22394, 40806, 38672, 38654, 32566, 38672, 38672, 38672, 38672, 48740, 26931, 22475, 38860, 22475, 40833, 22475, 33849, 22411, 41060, 22411, 40853, 22411, 33324, 26727, 38756, 26727, 40872, 26727, 32918, 33802, 38672, 38672, 20973, 45998, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 22458, 40891, 22411, 22411, 22411, 22411, 40911, 26727, 26727, 26727, 26727, 22501, 33795, 23174, 18332, 38672, 38672, 38672, 40938, 22475, 40962, 22475, 40684, 22411, 40981, 22411, 31782, 26727, 49841, 26727, 26998, 28442, 38672, 38672, 38672, 26931, 41000, 41019, 42142, 41039, 41057, 28347, 41076, 41095, 22521, 44039, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 34915, 34036, 27330, 41115, 29084, 41137, 35817, 26727, 27724, 35759, 41154, 41218, 41701, 41262, 41286, 47258, 44155, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 28115, 33538, 27862, 36357, 34905, 46290, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 26904, 22098, 38672, 38672, 41323, 22275, 41345, 40139, 38672, 26358, 41381, 41394, 41410, 41422, 25344, 38672, 38672, 45842, 43215, 38672, 38672, 38672, 41438, 50256, 38672, 22231, 41440, 45848, 38672, 34773, 41457, 34829, 39879, 41487, 27268, 25375, 38102, 38672, 38672, 29641, 38672, 41538, 41554, 33261, 38672, 38672, 36430, 26929, 41579, 35101, 34846, 45533, 41616, 41649, 40556, 45401, 41673, 41736, 41773, 26727, 41789, 40746, 42656, 41831, 38672, 41855, 41875, 32532, 32708, 46542, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 41594, 22475, 35786, 22411, 22411, 22411, 41893, 22411, 37334, 26727, 26727, 37094, 26727, 26727, 32919, 27373, 41911, 29299, 38672, 38672, 38672, 41935, 25466, 38672, 41955, 26931, 22475, 41121, 41974, 22475, 22475, 34152, 22411, 46370, 41992, 22411, 22411, 30778, 26727, 31887, 42009, 26727, 26727, 32918, 33802, 38243, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 48461, 22475, 28015, 42027, 22411, 22411, 42047, 22411, 37764, 26727, 26727, 48819, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 22208, 38672, 18340, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 28175, 42067, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 30944, 42088, 42137, 42160, 42180, 48196, 42203, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 31078, 38672, 38672, 32435, 32438, 32441, 42224, 25897, 46967, 28280, 42275, 42293, 31579, 27268, 42319, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 46624, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 41023, 22411, 22411, 22411, 22411, 22411, 42864, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 42345, 42143, 29941, 22411, 26977, 42363, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 44743, 22177, 38672, 38672, 27385, 38672, 45876, 42383, 22121, 42412, 42425, 42433, 42449, 42461, 25344, 38672, 32955, 42527, 43215, 18706, 42477, 42499, 33244, 42519, 38672, 42543, 40174, 42559, 42580, 42605, 42641, 42672, 40377, 42708, 42766, 25375, 38672, 38672, 38672, 42829, 42880, 42911, 43973, 27961, 38672, 38672, 23013, 42938, 22475, 42974, 41003, 39432, 42995, 32861, 22411, 36698, 35176, 43029, 43292, 26727, 43049, 43082, 43138, 38672, 38672, 38672, 25328, 43172, 43191, 38672, 43210, 28234, 38672, 43231, 48341, 22475, 43250, 22475, 22325, 43268, 47118, 39174, 22411, 22411, 43316, 43332, 43358, 40585, 26727, 37280, 43376, 43410, 33803, 38672, 38672, 41815, 45184, 39238, 30360, 38672, 43434, 50186, 43461, 43495, 48777, 43514, 43538, 22475, 43573, 43599, 31640, 43617, 43640, 22411, 43666, 43692, 49367, 43710, 43733, 26727, 47922, 33802, 43767, 38672, 38672, 43787, 43812, 38672, 43850, 50024, 43886, 43557, 22475, 28015, 33854, 43908, 34242, 22411, 22411, 27851, 46470, 43935, 44079, 26727, 39658, 43953, 38672, 43989, 21331, 38672, 38672, 33824, 22475, 22475, 49385, 34223, 22411, 22411, 22411, 44011, 26727, 26727, 26727, 44027, 46887, 19958, 38672, 38672, 50007, 22475, 22475, 28197, 22411, 22411, 44066, 26727, 26727, 44101, 26313, 20872, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26890, 47793, 44124, 44140, 44185, 44209, 20435, 28340, 26976, 33389, 44233, 44253, 44277, 44296, 28343, 26456, 28257, 28345, 26459, 44315, 44342, 38482, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 18636, 22098, 44386, 29857, 38069, 44372, 44403, 44440, 44464, 44480, 44494, 44510, 44526, 44538, 25344, 44554, 46908, 38672, 40088, 38672, 38672, 41365, 38672, 43156, 26783, 26781, 47212, 47203, 34311, 44573, 42979, 44618, 41232, 44280, 27268, 44640, 44676, 38672, 44712, 29827, 28456, 38672, 38672, 38672, 44731, 44769, 38672, 40058, 44785, 40965, 44822, 22475, 44840, 44869, 48063, 22411, 22690, 39155, 44892, 44910, 26727, 30990, 39463, 38672, 44931, 38672, 44950, 44971, 38672, 38672, 38672, 38672, 38672, 44987, 28258, 45008, 41301, 22475, 22475, 37611, 28054, 22411, 45028, 22411, 22411, 45046, 30301, 30320, 26727, 26727, 28093, 30742, 33803, 38672, 38672, 45072, 32638, 30075, 38672, 46548, 37818, 38672, 42396, 22475, 22475, 47037, 45094, 33476, 49452, 22411, 22411, 49585, 32047, 36630, 35654, 26727, 26727, 39696, 33919, 26493, 44108, 45157, 32514, 38672, 49604, 38672, 38672, 38672, 45200, 22475, 22475, 43892, 45227, 28015, 33854, 22411, 41993, 40562, 22411, 27851, 26727, 26727, 32834, 45248, 22521, 33795, 38672, 22295, 45267, 19361, 38672, 28255, 36090, 22475, 45286, 43473, 42051, 22411, 45304, 43005, 43694, 26727, 49877, 26998, 46887, 38672, 50299, 46144, 45323, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 49054, 26313, 45345, 36168, 40817, 45367, 22475, 45384, 22411, 30669, 26977, 26727, 45417, 45465, 36482, 45500, 45528, 32279, 22411, 44261, 26727, 45549, 35759, 34423, 35689, 37179, 48196, 20435, 28340, 26976, 27310, 33427, 47309, 26456, 32258, 46222, 29141, 45599, 45573, 45589, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 42503, 22098, 38672, 38672, 19843, 38672, 45632, 29682, 29695, 45672, 45688, 45703, 45719, 45731, 25344, 25697, 36820, 25484, 43215, 48936, 33218, 45747, 38933, 25691, 45794, 45830, 45905, 45865, 45892, 45921, 30595, 45937, 41471, 45980, 45966, 25375, 45996, 46014, 46030, 34093, 38672, 38672, 46051, 24794, 46090, 46124, 46160, 46201, 46238, 46262, 46318, 46334, 46351, 46386, 26710, 46424, 30615, 39597, 40389, 46450, 46486, 30259, 41502, 46506, 46564, 38672, 46591, 46610, 46646, 38672, 45270, 33165, 46667, 46703, 46719, 46781, 46818, 46866, 45012, 35786, 47344, 42692, 28076, 22411, 34531, 37334, 42303, 43342, 43676, 26727, 37661, 41688, 46885, 38672, 46904, 39209, 44660, 46924, 28976, 46946, 38672, 30957, 20847, 49903, 46983, 47036, 22475, 47053, 33288, 31829, 47089, 22411, 22411, 47105, 35219, 43394, 47140, 26727, 26727, 47156, 32918, 33802, 47191, 38672, 41877, 37707, 38672, 50210, 38598, 47237, 45288, 47274, 47290, 28015, 43827, 47306, 47325, 28394, 29934, 30696, 36786, 37667, 47360, 43033, 22521, 43418, 47376, 50112, 38672, 38355, 49147, 28255, 47399, 22475, 22475, 47445, 47467, 34602, 22411, 47502, 47526, 50046, 26727, 47556, 46887, 36283, 49516, 38672, 48840, 29206, 44799, 47584, 47703, 30662, 30727, 45251, 31880, 34269, 39367, 47647, 38672, 49567, 38494, 40946, 47666, 47699, 47719, 39849, 48630, 47746, 32945, 47785, 47809, 47827, 47850, 47889, 47907, 48880, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 49752, 49772, 47949, 47973, 48009, 48038, 49034, 30862, 33538, 36362, 36357, 47933, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 48079, 38672, 38672, 48107, 38672, 19671, 30510, 30518, 48127, 30518, 30526, 48143, 48155, 25344, 38672, 38672, 38672, 44955, 38672, 29647, 38672, 38672, 38672, 38672, 29652, 46888, 38672, 38672, 45329, 35643, 48171, 30851, 45141, 48219, 48262, 38672, 38672, 38672, 29641, 38672, 38672, 50200, 50208, 38672, 38672, 38672, 48298, 33458, 22475, 22475, 22475, 48316, 48375, 22411, 22411, 28301, 37203, 26727, 26727, 26727, 30914, 41169, 48395, 38672, 34989, 34103, 38672, 38672, 38672, 48429, 38672, 34985, 36969, 28258, 49732, 31174, 47066, 48458, 46734, 22411, 37326, 35682, 48477, 41625, 48513, 26727, 48546, 48566, 33498, 48611, 32919, 33803, 38672, 32557, 38672, 48646, 38672, 38672, 38672, 19786, 38672, 26931, 22475, 48666, 22475, 22475, 22475, 32777, 22411, 48684, 22411, 22411, 22411, 31945, 26727, 48701, 26727, 26727, 26727, 32918, 33361, 38672, 45778, 38672, 38672, 38672, 38672, 41194, 35417, 22475, 22475, 22475, 28015, 42844, 22411, 22411, 22411, 22411, 27851, 48720, 26727, 26727, 26727, 22521, 33795, 48739, 38672, 38672, 48756, 38672, 35766, 48773, 22475, 22475, 45119, 48793, 22411, 42164, 43122, 48813, 26727, 43937, 26998, 46887, 48835, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 43522, 42144, 48856, 26975, 48877, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 20436, 32151, 30885, 28257, 28345, 26459, 33538, 22735, 48896, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 48924, 48962, 36314, 45181, 38672, 50538, 38672, 45169, 48959, 38038, 34111, 48981, 48993, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 27525, 42141, 49009, 31292, 44280, 27268, 25375, 38672, 36812, 40252, 29641, 38672, 38672, 38672, 38672, 43194, 38672, 38672, 26929, 45232, 22475, 37800, 22475, 25393, 49027, 22411, 46850, 22690, 27979, 26727, 26727, 49050, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 49070, 38672, 38672, 49087, 38672, 28258, 22475, 49810, 22475, 22475, 35786, 22411, 22411, 34386, 22411, 22411, 37334, 26727, 26727, 49106, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 49126, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 49146, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 49163, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 49187, 38672, 21516, 38672, 20816, 49222, 49253, 38672, 49277, 49291, 49304, 49320, 49332, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 31934, 32212, 26453, 47540, 49348, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 43175, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 35291, 38672, 38672, 38672, 36319, 22475, 22475, 22475, 22475, 22475, 31707, 22411, 22411, 22411, 22411, 22411, 45130, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38842, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 49383, 22475, 49401, 33854, 22411, 42856, 22411, 47124, 27851, 26727, 41079, 26727, 26727, 49426, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25610, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 41202, 49468, 49480, 25344, 38672, 38672, 38672, 43215, 49496, 38672, 49515, 38672, 38672, 46071, 46074, 38672, 49532, 28993, 37922, 42141, 49583, 32824, 44280, 27268, 25375, 38672, 38672, 46108, 29641, 46524, 46533, 49601, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 49620, 37001, 25393, 22411, 29448, 22411, 49639, 26727, 26727, 48625, 36734, 30990, 43097, 49680, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 49703, 38672, 38672, 26931, 22475, 22475, 49727, 22475, 22475, 48053, 22411, 22411, 49748, 22411, 22411, 46748, 26727, 26727, 49768, 26727, 26727, 32918, 33802, 20903, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 49788, 22475, 22475, 28015, 33854, 26700, 22411, 22411, 22411, 27851, 42367, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 45477, 38672, 38672, 43215, 38672, 38672, 49711, 38672, 38672, 38672, 49707, 38672, 38672, 27156, 49805, 37753, 37630, 26453, 49986, 49826, 25375, 38672, 20236, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 28133, 26929, 22475, 22475, 22475, 47834, 25393, 22411, 22411, 22411, 49862, 26727, 26727, 26727, 37879, 30990, 39463, 38672, 45808, 38672, 38672, 38672, 38672, 38672, 38672, 29514, 38672, 38672, 28258, 49898, 22475, 31756, 22475, 35786, 22411, 49919, 22411, 36688, 22411, 37334, 40766, 26727, 26727, 49936, 26727, 32919, 33803, 38672, 25655, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 37984, 22475, 22475, 22475, 35151, 22411, 46398, 22411, 22411, 22411, 43919, 26727, 31302, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38999, 38672, 22475, 22475, 26805, 22475, 49623, 33854, 22411, 22411, 49957, 22411, 49975, 26727, 26727, 47510, 26727, 49846, 33795, 38672, 38672, 18612, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 30025, 38672, 38672, 50002, 26931, 50023, 22475, 27060, 22411, 22411, 28347, 50040, 26727, 22521, 26313, 38672, 40323, 38672, 27136, 29066, 42143, 22411, 50062, 26977, 27488, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 25323, 38672, 38672, 38672, 38672, 22098, 38672, 38672, 38672, 38672, 42922, 41360, 38672, 38672, 38672, 44448, 27298, 33333, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 25375, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 25393, 22411, 22411, 22411, 22690, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 34339, 19585, 19583, 40183, 33676, 50079, 27766, 27768, 50110, 33673, 34350, 50128, 50140, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 25515, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 20613, 18794, 19200, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 18475, 50434, 18503, 18525, 50156, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 20273, 38672, 42922, 31104, 31112, 50226, 50240, 50248, 42483, 50272, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 50505, 38672, 38672, 38672, 25547, 38672, 38672, 25544, 18953, 18958, 18794, 35998, 18531, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19406, 50434, 18503, 18525, 18547, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 42589, 38672, 38672, 38672, 38672, 24842, 35017, 50315, 50319, 50335, 50343, 43995, 50367, 20832, 38672, 38672, 38672, 43215, 38672, 38672, 25359, 38672, 38672, 23171, 38672, 38672, 38672, 23167, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 29641, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 19075, 50434, 18503, 18525, 50409, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 20424, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 20532, 20548, 20592, 20589, 50171, 20608, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 20939, 38672, 38672, 38672, 38672, 30470, 38672, 38672, 38672, 38672, 42922, 38672, 38672, 38672, 38672, 38672, 38672, 24860, 25344, 38672, 38672, 38672, 43215, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28256, 42141, 22411, 26453, 44280, 27268, 22230, 38672, 38672, 38672, 29641, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26929, 22475, 22475, 22475, 22475, 36544, 22411, 22411, 22411, 33858, 26727, 26727, 26727, 26727, 30990, 39463, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 28258, 22475, 22475, 22475, 22475, 35786, 22411, 22411, 22411, 22411, 22411, 37334, 26727, 26727, 26727, 26727, 26727, 32919, 33803, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 26931, 22475, 22475, 22475, 22475, 22475, 33849, 22411, 22411, 22411, 22411, 22411, 33324, 26727, 26727, 26727, 26727, 26727, 32918, 33802, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 22475, 22475, 22475, 22475, 28015, 33854, 22411, 22411, 22411, 22411, 27851, 26727, 26727, 26727, 26727, 22521, 33795, 38672, 38672, 38672, 38672, 38672, 28255, 22475, 22475, 22475, 29442, 22411, 22411, 22411, 26485, 26727, 26727, 26727, 26998, 46887, 38672, 38672, 38672, 26931, 22475, 22475, 42142, 22411, 22411, 28347, 26727, 26727, 22521, 26313, 38672, 38672, 38672, 27136, 22475, 42143, 22411, 22411, 26977, 26727, 22520, 26312, 34036, 26929, 22475, 42144, 22411, 26975, 26727, 26310, 35759, 22476, 22411, 26978, 48196, 20435, 28340, 26976, 39617, 42139, 28345, 26456, 28257, 28343, 26456, 28257, 28345, 26459, 33538, 36362, 36357, 34905, 28863, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38956, 38672, 38672, 29796, 50456, 50460, 50460, 50482, 38955, 50476, 50498, 38672, 38672, 38672, 38672, 38672, 38672, 50505, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 18953, 18958, 18794, 35998, 19418, 35990, 45351, 38672, 18269, 42564, 38672, 38672, 40144, 38672, 23032, 18306, 18356, 18382, 18387, 18403, 18422, 18462, 20670, 18475, 50434, 18503, 18525, 50156, 19412, 50440, 18509, 36003, 19232, 20563, 38672, 46930, 18591, 38672, 38672, 37574, 18609, 18628, 33736, 18652, 18685, 18722, 18753, 18745, 18769, 18406, 25849, 18792, 20360, 18810, 18830, 18835, 19138, 18794, 20364, 18814, 18794, 18839, 19540, 19955, 37554, 48943, 18855, 18871, 18894, 40258, 38672, 38976, 18931, 18947, 18974, 19016, 19062, 19169, 19103, 19129, 20726, 19934, 19154, 19185, 19222, 19248, 20726, 19934, 19154, 19185, 19222, 19273, 19000, 30964, 19299, 19315, 28712, 19342, 25187, 19377, 19393, 19434, 19464, 19495, 19569, 19608, 24938, 19905, 19631, 19046, 19601, 24931, 19898, 19624, 19039, 19647, 19687, 43796, 19722, 19792, 19745, 19771, 19808, 19113, 19859, 19875, 19921, 18446, 19976, 19994, 24983, 18444, 19974, 19992, 20321, 18562, 47383, 20010, 46515, 35979, 20039, 20679, 20105, 20160, 20116, 20132, 20159, 20115, 20176, 19479, 20207, 20223, 20259, 20298, 20337, 20380, 20402, 21368, 20386, 20408, 21374, 19283, 50527, 20452, 20468, 20484, 20497, 50424, 20500, 20516, 26100, 20548, 20592, 20589, 50171, 18953, 19547, 18794, 18487, 20629, 20143, 19945, 20660, 18437, 21954, 20695, 20711, 21969, 19448, 21939, 20755, 19510, 19659, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 38672, 94505, 94505, 90408, 90408, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 1, 12290, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 0, 94505, 90408, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 364, 94505, 90408, 94505, 94505, 94505, 94505, 94505, 94505, 94505, 69632, 73728, 94505, 94505, 94505, 94505, 94505, 65536, 94505, 3, 0, 0, 2183168, 0, 0, 0, 90408, 94505, 298, 299, 0, 2134016, 302, 303, 0, 0, 0, 0, 0, 1636, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1645, 0, 0, 2732032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2904064, 2908160, 0, 0, 0, 0, 0, 1699, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2963, 0, 0, 0, 0, 0, 2424832, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2625536, 0, 0, 0, 0, 0, 2045, 0, 0, 0, 0, 2049, 0, 0, 0, 0, 0, 0, 0, 2711, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2976, 0, 534, 534, 534, 534, 534, 2699264, 2715648, 0, 0, 2772992, 2805760, 2830336, 0, 2863104, 2920448, 0, 0, 0, 0, 0, 0, 0, 303, 303, 303, 303, 0, 303, 303, 303, 303, 0, 2805760, 2920448, 0, 0, 0, 0, 0, 2920448, 0, 0, 0, 0, 0, 0, 0, 2732032, 0, 2179072, 2179072, 2179072, 2179072, 2424832, 2433024, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3125248, 2625536, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2699264, 2179072, 2715648, 2179072, 2723840, 2179072, 2732032, 2772992, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 2592768, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2551808, 2125824, 2125824, 2125824, 2125824, 2125824, 2637824, 2125824, 2179072, 2179072, 2805760, 2179072, 2830336, 2179072, 2179072, 2863104, 2179072, 2179072, 2179072, 2179072, 2920448, 2179072, 2179072, 2179072, 0, 0, 2125824, 2125824, 2125824, 2125824, 2125824, 2424832, 2433024, 2125824, 2125824, 2125824, 2125824, 0, 2502656, 0, 0, 3010560, 0, 0, 0, 0, 2990080, 2179072, 2179072, 2699264, 2125824, 2715648, 2125824, 2723840, 2125824, 2732032, 2772992, 2125824, 2125824, 2125824, 2805760, 2125824, 2830336, 2125824, 2125824, 2863104, 2125824, 2125824, 2125824, 2125824, 2920448, 2863104, 2125824, 2125824, 2125824, 2125824, 2920448, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 1142784, 0, 2179072, 2125824, 2125824, 2125824, 3117056, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 0, 975, 2125824, 0, 0, 0, 0, 0, 0, 2510848, 2514944, 0, 0, 2547712, 2596864, 0, 0, 0, 0, 0, 0, 735, 0, 0, 0, 0, 735, 0, 741, 0, 0, 0, 2789376, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3137, 0, 0, 2142208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2733, 0, 2662400, 0, 2813952, 0, 0, 0, 0, 2375680, 0, 0, 0, 0, 0, 0, 0, 0, 0, 350, 351, 352, 0, 0, 0, 0, 2584576, 0, 0, 0, 0, 2838528, 0, 0, 2838528, 0, 0, 0, 0, 0, 0, 0, 0, 1122, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1186, 0, 0, 0, 0, 0, 0, 0, 2891776, 0, 0, 0, 0, 0, 2392064, 2412544, 0, 0, 2838528, 0, 0, 0, 0, 0, 0, 262144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 706, 0, 0, 0, 0, 0, 0, 0, 0, 2179072, 2179072, 2179072, 2408448, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 0, 2126724, 2126724, 2617344, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2662400, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2584576, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2801664, 2813952, 2179072, 2838528, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 1798, 2125824, 2125824, 2125824, 2408448, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2662400, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2801664, 2813952, 2125824, 2838528, 2125824, 2813952, 2125824, 2838528, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3125248, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 2822144, 0, 0, 2883584, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3080192, 3100672, 3104768, 0, 0, 0, 0, 3186688, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 305, 306, 0, 0, 0, 0, 0, 0, 2797568, 0, 0, 0, 0, 0, 0, 0, 2850816, 2867200, 0, 0, 2883584, 0, 0, 0, 0, 0, 2072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3134, 0, 0, 0, 0, 2465792, 0, 0, 2719744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3014656, 3207168, 0, 2691072, 0, 0, 3215360, 0, 0, 0, 0, 0, 0, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 2179072, 2179072, 2179072, 2179072, 2179072, 2461696, 2465792, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2523136, 2179072, 2179072, 2179072, 0, 1342, 2125824, 2125824, 2125824, 2125824, 2125824, 2424832, 2433024, 2125824, 2125824, 2125824, 2125824, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2473984, 2478080, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2600960, 2179072, 2179072, 2179072, 2179072, 2641920, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 1047, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3035136, 2125824, 2125824, 3072000, 2125824, 2125824, 2125824, 3121152, 2125824, 2125824, 3141632, 2125824, 2125824, 2125824, 3170304, 2179072, 2179072, 2719744, 2179072, 2179072, 2179072, 2179072, 2179072, 2768896, 2777088, 2781184, 2797568, 2822144, 2179072, 2179072, 2179072, 0, 900, 2125824, 2125824, 2125824, 2125824, 2125824, 2424832, 2433024, 2125824, 2125824, 2125824, 2125824, 298, 0, 299, 0, 302, 0, 303, 0, 0, 0, 2473984, 2478080, 2179072, 3063808, 2179072, 2179072, 2179072, 2179072, 3100672, 2179072, 2179072, 3133440, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2551808, 2179072, 2179072, 2179072, 2179072, 2179072, 2637824, 2179072, 2179072, 2179072, 2179072, 3207168, 2179072, 0, 0, 0, 0, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 0, 2125824, 2125824, 2125824, 2408448, 2125824, 2125824, 2125824, 2719744, 2125824, 2125824, 2125824, 2125824, 2125824, 2768896, 2777088, 2781184, 2797568, 2822144, 2125824, 2125824, 2125824, 2883584, 2179072, 2912256, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3039232, 2125824, 2912256, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3039232, 2125824, 2125824, 0, 2125824, 2126799, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 245760, 0, 0, 2179072, 2125824, 2125824, 3063808, 2125824, 2125824, 2125824, 2125824, 2125824, 3100672, 2125824, 2125824, 3133440, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 2179072, 2125824, 2125824, 2457600, 2179072, 2179072, 2179072, 2179072, 2457600, 2125824, 2125824, 2125824, 3207168, 2125824, 0, 0, 0, 0, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 1894, 2125824, 2125824, 2125824, 2408448, 2125824, 2125824, 2125824, 2125824, 2125824, 3207168, 2125824, 2179072, 2125824, 2125824, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 0, 2486272, 0, 0, 0, 0, 0, 2678784, 2854912, 3006464, 0, 2924544, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3162112, 3170304, 0, 0, 3219456, 3035136, 0, 0, 0, 0, 0, 3072000, 2650112, 0, 0, 2809856, 0, 0, 0, 0, 0, 0, 0, 1650, 0, 0, 0, 0, 0, 0, 1654, 0, 2686976, 2736128, 0, 0, 2531328, 2707456, 0, 3190784, 0, 0, 2576384, 0, 0, 0, 0, 0, 0, 0, 1688, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2742, 0, 0, 0, 0, 0, 0, 0, 3121152, 3141632, 0, 0, 0, 2924544, 0, 2682880, 0, 0, 0, 0, 0, 0, 3112960, 2387968, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2453504, 2179072, 2473984, 2482176, 2179072, 2179072, 2179072, 0, 901, 2125824, 2125824, 2125824, 2125824, 2125824, 2424832, 2433024, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 0, 0, 2179072, 2125824, 2125824, 2179072, 2179072, 2179072, 2531328, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2605056, 2179072, 2629632, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2527232, 2125824, 2125824, 2125824, 2125824, 2125824, 3092480, 2125824, 2527232, 2125824, 2650112, 2179072, 2179072, 2179072, 2707456, 2179072, 2736128, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2887680, 2179072, 2125824, 2125824, 2125824, 2125824, 2441216, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2932736, 2179072, 2924544, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3035136, 2179072, 2179072, 3072000, 2179072, 2125824, 2658304, 2973696, 2125824, 2125824, 2658304, 2973696, 2125824, 2711552, 2560000, 2179072, 2560000, 2125824, 2560000, 2125824, 2125824, 2125824, 2125824, 2125824, 3223552, 975, 0, 2125824, 2125824, 2416640, 2125824, 2125824, 2125824, 2445312, 2125824, 2125824, 2125824, 2125824, 2179072, 2125824, 2125824, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 1047, 0, 0, 2179072, 2125824, 2125824, 2179072, 3121152, 2179072, 2179072, 3141632, 2179072, 2179072, 2179072, 3170304, 2179072, 2179072, 3190784, 3194880, 2179072, 0, 0, 0, 0, 0, 0, 1134592, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1134592, 2125824, 2125824, 3190784, 3194880, 2125824, 0, 0, 0, 0, 0, 0, 2387968, 2125824, 2125824, 2125824, 2420736, 2125824, 2125824, 2125824, 2125824, 2125824, 2453504, 2125824, 2707456, 2125824, 2736128, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2887680, 2125824, 2125824, 2924544, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3141632, 2125824, 2125824, 2125824, 3170304, 2125824, 2125824, 3190784, 3194880, 2125824, 2179072, 2125824, 2125824, 2179072, 2125824, 2125824, 2179072, 2125824, 2125824, 2985984, 2985984, 2985984, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 419, 419, 0, 0, 65536, 419, 2179072, 3112960, 3219456, 2125824, 2125824, 3112960, 3219456, 2125824, 2125824, 3112960, 3219456, 0, 0, 0, 0, 0, 0, 0, 1701, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1624, 0, 0, 0, 0, 0, 0, 0, 3022848, 0, 0, 3145728, 0, 3203072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 335, 336, 0, 0, 0, 0, 0, 0, 0, 0, 3067904, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 787, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2445312, 0, 2842624, 0, 0, 0, 2637824, 0, 0, 0, 0, 2621440, 0, 0, 0, 0, 0, 2100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2727936, 0, 0, 0, 3084288, 3182592, 2899968, 0, 2961408, 0, 0, 2179072, 2179072, 2416640, 2179072, 2179072, 2179072, 2445312, 2179072, 2179072, 2179072, 0, 901, 2126724, 2126724, 2126724, 2126724, 2126724, 2425732, 2433924, 2126724, 2126724, 2126724, 2126724, 2458574, 2126798, 2126798, 2126798, 2126798, 2183168, 0, 0, 0, 0, 0, 0, 0, 396, 0, 0, 0, 0, 0, 396, 0, 0, 2179072, 2179072, 2179072, 2727936, 2752512, 2179072, 2179072, 2179072, 2842624, 2846720, 2179072, 2895872, 2916352, 2179072, 2179072, 2945024, 2179072, 2179072, 2994176, 2179072, 3002368, 2179072, 2179072, 3022848, 2179072, 3067904, 3084288, 3096576, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 237568, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2605056, 2125824, 2629632, 2125824, 2125824, 2650112, 2125824, 2125824, 2125824, 2707456, 2125824, 2736128, 2125824, 2125824, 2125824, 2125824, 2179072, 2179072, 2179072, 3223552, 0, 0, 2125824, 2125824, 2416640, 2125824, 2125824, 2125824, 2445312, 2125824, 2125824, 2125824, 2125824, 2125824, 2600960, 2125824, 2125824, 2125824, 2125824, 2641920, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3010560, 2125824, 2125824, 2125824, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2940, 0, 2637824, 2125824, 2125824, 2125824, 2125824, 2727936, 2752512, 2125824, 2125824, 2125824, 2125824, 2842624, 2846720, 2125824, 2895872, 2916352, 2125824, 2125824, 2125824, 2125824, 2945024, 2125824, 2125824, 2994176, 2125824, 3002368, 2125824, 2125824, 3022848, 2125824, 3067904, 3084288, 2125824, 3096576, 2125824, 2125824, 0, 0, 0, 2928640, 0, 0, 0, 3059712, 0, 2543616, 2666496, 0, 2633728, 0, 0, 0, 0, 0, 0, 766, 767, 0, 0, 0, 754, 0, 0, 774, 0, 2179072, 2179072, 2179072, 2494464, 2179072, 2179072, 2514944, 2179072, 2179072, 2179072, 2543616, 2547712, 2179072, 2179072, 2596864, 2179072, 2126724, 2126724, 2126724, 2126724, 2126724, 2593668, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126798, 0, 0, 0, 0, 0, 0, 2510848, 2514944, 0, 0, 2547712, 2596864, 0, 0, 0, 0, 0, 0, 1164, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1564, 0, 1566, 0, 0, 0, 2179072, 2179072, 3059712, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3178496, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2928640, 2125824, 2125824, 2125824, 2998272, 2125824, 2125824, 2125824, 2125824, 3059712, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3178496, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3010560, 2125824, 2125824, 2125824, 2125824, 2125824, 2502656, 2125824, 2125824, 2125824, 2494464, 2125824, 2125824, 2514944, 2125824, 2125824, 2125824, 2543616, 2547712, 2125824, 2125824, 2596864, 2125824, 2125824, 2125824, 2125824, 2125824, 3059712, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3178496, 2179072, 2125824, 2125824, 2179072, 2126724, 2126724, 2126798, 2126798, 2441216, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2932736, 2965504, 0, 0, 3076096, 0, 0, 2695168, 3174400, 2646016, 2613248, 2703360, 0, 0, 0, 0, 2977792, 0, 0, 3047424, 3129344, 0, 2981888, 2396160, 0, 3153920, 0, 0, 0, 2740224, 0, 0, 0, 0, 0, 0, 1106, 0, 0, 0, 0, 0, 0, 0, 0, 0, 334, 0, 0, 0, 0, 0, 0, 0, 0, 2793472, 0, 0, 0, 0, 0, 2469888, 2506752, 2756608, 0, 0, 2580480, 0, 0, 0, 0, 0, 0, 1146880, 0, 1146880, 0, 0, 0, 0, 0, 0, 0, 302, 302, 302, 302, 0, 302, 302, 302, 302, 0, 2396160, 2400256, 2179072, 2179072, 2441216, 2179072, 2469888, 2179072, 2179072, 2179072, 2519040, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 241664, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3223552, 2179072, 2125824, 2125824, 2179072, 2179072, 2125824, 2125824, 2125824, 2588672, 2179072, 2613248, 2646016, 2179072, 2179072, 2695168, 2756608, 2179072, 2179072, 2179072, 2932736, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 245760, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2584576, 2125824, 2125824, 2125824, 2125824, 2125824, 2617344, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2662400, 2179072, 2179072, 2179072, 3129344, 2179072, 2179072, 3153920, 3166208, 3174400, 2396160, 2400256, 2125824, 2125824, 2441216, 2125824, 2469888, 2125824, 2125824, 2125824, 2519040, 2125824, 2125824, 2125824, 2125824, 2125824, 2519040, 2125824, 2125824, 2125824, 2125824, 2588672, 2125824, 2613248, 2646016, 2125824, 2125824, 2695168, 2756608, 2125824, 2125824, 2125824, 2125824, 2932736, 2125824, 0, 3108864, 3198976, 0, 0, 3043328, 0, 3149824, 2936832, 0, 2760704, 3132, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3503, 2953216, 0, 0, 2826240, 3158016, 2428928, 0, 3018752, 2764800, 2572288, 0, 0, 3051520, 2179072, 2428928, 2437120, 2179072, 2486272, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2654208, 2678784, 2760704, 2764800, 2854912, 2969600, 2179072, 3006464, 2179072, 3018752, 2179072, 2179072, 2179072, 3149824, 2125824, 2428928, 2437120, 2125824, 2486272, 2125824, 2125824, 2125824, 2125824, 2125824, 2654208, 2678784, 2760704, 2764800, 2785280, 2854912, 2969600, 2125824, 3006464, 2125824, 3018752, 2125824, 2125824, 2125824, 2125824, 3149824, 2179072, 3051520, 2125824, 3051520, 2125824, 3051520, 0, 2490368, 2498560, 0, 0, 0, 0, 2875392, 0, 0, 0, 3132, 0, 0, 2834432, 0, 3227648, 2568192, 2564096, 0, 2940928, 2179072, 2179072, 2498560, 2179072, 2179072, 2179072, 2555904, 2564096, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3137536, 2125824, 2125824, 2125824, 2125824, 2457600, 2125824, 2125824, 2125824, 2125824, 2183168, 0, 0, 0, 0, 0, 0, 0, 333, 0, 0, 0, 0, 0, 333, 0, 0, 2125824, 3137536, 2125824, 2125824, 2498560, 2125824, 2125824, 2125824, 2555904, 2564096, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3132, 0, 0, 0, 0, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2126725, 2125824, 2125824, 2125824, 2502656, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3010560, 2179072, 2179072, 2125824, 2125824, 2502656, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3010560, 2179072, 2179072, 2126724, 2126724, 2503556, 0, 0, 0, 0, 2179072, 2179072, 2179072, 2179072, 2179072, 2592768, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3117056, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2928640, 2179072, 2179072, 2179072, 2998272, 2179072, 2179072, 3031040, 0, 0, 0, 2179072, 2449408, 2179072, 2535424, 2179072, 2609152, 2179072, 2859008, 2179072, 2179072, 2179072, 3031040, 2125824, 2449408, 2125824, 2535424, 2125824, 2609152, 2125824, 2859008, 2125824, 2125824, 2125824, 3031040, 2125824, 2125824, 2449408, 2125824, 2125824, 2125824, 2125824, 2461696, 2465792, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2523136, 2125824, 2125824, 2125824, 298, 0, 0, 0, 298, 0, 299, 0, 0, 0, 299, 0, 302, 2125824, 2125824, 2125824, 3026944, 2404352, 2125824, 2125824, 2125824, 2125824, 3026944, 2539520, 0, 2949120, 2179072, 2658304, 2973696, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 452, 452, 111044, 452, 452, 452, 452, 452, 452, 452, 452, 452, 452, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 452, 111044, 111044, 111044, 111044, 111044, 0, 0, 0, 0, 0, 0, 0, 0, 0, 360, 0, 0, 0, 0, 0, 360, 3, 0, 0, 2183168, 0, 0, 0, 0, 0, 298, 299, 0, 2134016, 302, 303, 0, 0, 0, 0, 0, 2124, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 847, 534, 534, 861, 534, 534, 0, 302, 118784, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3127, 0, 0, 0, 302, 0, 0, 0, 302, 119197, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 0, 2403, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 302, 302, 0, 0, 0, 0, 302, 302, 302, 302, 302, 302, 0, 0, 0, 0, 0, 302, 0, 302, 1, 12290, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2966, 0, 3, 0, 0, 2183168, 0, 0, 0, 0, 0, 33396, 299, 0, 2134016, 49784, 303, 0, 0, 0, 0, 0, 2428, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 298, 0, 0, 0, 302, 0, 0, 0, 2424832, 2433024, 0, 0, 2457600, 2105631, 12290, 3, 0, 0, 293, 0, 0, 0, 0, 293, 0, 0, 0, 0, 0, 0, 0, 2024, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2455, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 0, 0, 122880, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 785, 0, 790, 0, 793, 0, 0, 0, 122880, 0, 122880, 122880, 122880, 0, 0, 0, 0, 0, 122880, 0, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 122880, 0, 0, 122880, 0, 0, 0, 0, 0, 0, 0, 0, 122880, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1216, 0, 0, 0, 0, 147456, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3148, 0, 0, 0, 0, 1067, 1071, 0, 0, 1075, 1079, 0, 2424832, 2433024, 0, 0, 2457600, 0, 0, 0, 131072, 0, 0, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 0, 2479, 2437, 0, 0, 0, 0, 0, 2484, 0, 0, 0, 0, 0, 0, 1675, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3260, 0, 0, 534, 534, 534, 131072, 0, 0, 131072, 131072, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 131072, 0, 0, 131072, 0, 0, 0, 0, 0, 135168, 135168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 225708, 0, 0, 0, 135168, 0, 0, 135168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1096, 0, 0, 0, 0, 0, 0, 0, 135168, 0, 135168, 135168, 135168, 135168, 135168, 135168, 0, 135168, 135168, 135168, 135168, 135168, 135168, 0, 0, 0, 0, 0, 135168, 0, 135168, 1, 12290, 3, 0, 0, 2183168, 0, 0, 0, 0, 0, 629, 630, 0, 2134016, 633, 634, 0, 0, 0, 0, 0, 2725, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2200245, 2200245, 2200245, 0, 0, 2125824, 3117056, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 0, 1434, 2125824, 2125824, 2125824, 2125824, 2932736, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3129344, 2125824, 2125824, 3153920, 3166208, 3174400, 2506752, 2506752, 2506752, 0, 303, 139264, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 266240, 0, 0, 0, 0, 0, 303, 0, 0, 0, 303, 69632, 139681, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 0, 2738, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2013, 0, 0, 0, 0, 303, 303, 303, 303, 303, 303, 0, 0, 0, 0, 0, 303, 0, 303, 1, 12290, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 300, 3, 0, 0, 2183168, 0, 0, 0, 0, 0, 298, 33399, 0, 2134016, 302, 49787, 0, 0, 0, 0, 0, 2763, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 3020, 556, 556, 556, 61440, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 360, 300, 300, 300, 143660, 370, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 143660, 300, 300, 143660, 300, 300, 300, 143730, 300, 300, 300, 143730, 69632, 73728, 300, 300, 143660, 300, 300, 65536, 300, 300, 0, 0, 300, 300, 143660, 300, 300, 300, 300, 300, 300, 300, 300, 300, 365, 300, 0, 143660, 300, 300, 300, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 300, 300, 143660, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 300, 143730, 300, 300, 300, 300, 300, 300, 300, 300, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 300, 300, 300, 300, 300, 300, 300, 300, 143660, 300, 143660, 143660, 143660, 143660, 300, 143660, 143660, 143660, 143660, 143660, 143660, 300, 0, 300, 0, 300, 300, 300, 143660, 300, 143660, 143660, 143660, 143660, 143660, 143730, 143660, 143730, 143730, 143730, 143730, 143730, 143730, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 143660, 1, 12290, 0, 0, 0, 0, 2200245, 2200245, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1153, 1154, 0, 0, 0, 0, 0, 0, 155648, 155648, 0, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 155648, 0, 0, 0, 0, 155648, 0, 0, 0, 0, 0, 155648, 155648, 0, 155648, 155648, 0, 12290, 0, 0, 0, 0, 155648, 0, 155648, 0, 0, 0, 0, 0, 155648, 0, 0, 0, 0, 0, 0, 1148, 0, 0, 0, 0, 0, 0, 0, 0, 1157, 3, 0, 0, 2183168, 126976, 0, 0, 0, 0, 298, 299, 0, 2134016, 302, 303, 0, 0, 0, 0, 0, 2934, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2446, 0, 0, 0, 0, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 163840, 159744, 159744, 159744, 159744, 0, 0, 159744, 0, 0, 0, 0, 0, 0, 0, 0, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 159744, 163840, 159744, 159744, 159744, 159744, 159744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 0, 0, 0, 131072, 131072, 25155, 0, 0, 0, 159744, 0, 0, 0, 25155, 25155, 25155, 159744, 25155, 25155, 25155, 25155, 25155, 25155, 25155, 159744, 159744, 159744, 159744, 25155, 159744, 25155, 1, 12290, 2125824, 3117056, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 24576, 975, 2125824, 2125824, 2125824, 2125824, 3092480, 0, 0, 0, 2404352, 2179072, 2179072, 2179072, 2179072, 3026944, 2404352, 2125824, 2125824, 2125824, 2125824, 2592768, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2449408, 0, 2535424, 2125824, 2609152, 2125824, 2859008, 2125824, 2125824, 2125824, 3031040, 2125824, 2527232, 0, 0, 0, 2179072, 2527232, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 1, 12290, 167936, 167936, 167936, 0, 0, 167936, 0, 0, 0, 0, 0, 0, 0, 0, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 0, 0, 0, 155648, 0, 172032, 172032, 0, 172032, 0, 0, 172032, 172032, 0, 172032, 0, 0, 0, 0, 172032, 172032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172032, 0, 0, 0, 172032, 172032, 0, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 292, 0, 0, 0, 0, 1, 288, 3, 0, 0, 0, 294, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 348, 0, 0, 0, 0, 0, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 1, 0, 176128, 176128, 176128, 0, 0, 176128, 0, 0, 0, 0, 0, 0, 0, 0, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 292, 0, 0, 0, 347, 3, 78114, 78114, 292, 0, 627, 0, 0, 0, 298, 299, 0, 2134016, 302, 303, 0, 0, 0, 0, 0, 2946, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 245760, 0, 0, 0, 0, 78114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 672, 0, 1102, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 155648, 0, 0, 0, 0, 1146, 0, 0, 0, 0, 1151, 0, 0, 0, 0, 0, 0, 0, 346, 0, 404, 0, 0, 0, 0, 0, 404, 0, 0, 0, 2098, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2717, 0, 0, 534, 2135, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2147, 534, 534, 534, 534, 534, 534, 1775, 534, 534, 534, 1780, 534, 534, 534, 534, 534, 534, 534, 2545, 534, 534, 534, 534, 534, 534, 0, 2549, 2220, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2232, 556, 556, 556, 556, 556, 556, 2590, 556, 556, 556, 556, 556, 556, 2598, 556, 556, 2307, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2319, 580, 580, 580, 0, 0, 0, 2006, 0, 1069, 0, 0, 0, 2008, 0, 1073, 0, 2573, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1396, 0, 0, 2955, 0, 0, 0, 2959, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 371, 0, 0, 372, 0, 0, 0, 534, 3150, 534, 534, 534, 3153, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2547, 534, 534, 534, 0, 0, 3161, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 580, 3206, 580, 580, 580, 3209, 580, 580, 580, 580, 580, 580, 580, 580, 2679, 580, 580, 580, 534, 580, 556, 534, 580, 580, 3217, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 580, 580, 3309, 580, 580, 580, 580, 3310, 3311, 580, 580, 580, 580, 580, 580, 580, 580, 2875, 580, 580, 580, 580, 580, 580, 580, 580, 3071, 580, 580, 580, 580, 580, 580, 580, 580, 3233, 580, 580, 580, 580, 534, 580, 556, 1993, 534, 534, 534, 1997, 556, 556, 556, 2001, 534, 534, 534, 3339, 534, 534, 534, 534, 534, 534, 3345, 534, 534, 534, 534, 556, 3407, 556, 3409, 556, 556, 556, 556, 556, 556, 556, 556, 1373, 556, 556, 556, 556, 556, 556, 556, 3364, 556, 580, 580, 580, 580, 580, 580, 3370, 580, 580, 580, 580, 580, 580, 3376, 580, 580, 580, 3380, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2925, 0, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 3391, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2198, 534, 2200, 534, 534, 534, 534, 534, 534, 3406, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 556, 556, 556, 556, 3422, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1449, 580, 580, 580, 580, 580, 580, 580, 3522, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 534, 534, 534, 534, 3585, 534, 556, 556, 3, 78114, 78114, 292, 0, 0, 0, 0, 0, 298, 299, 0, 2134016, 302, 303, 0, 0, 0, 0, 0, 2973, 0, 0, 2975, 0, 0, 534, 534, 2980, 534, 534, 534, 534, 534, 534, 2532, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2793, 534, 534, 534, 534, 534, 0, 0, 0, 304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2732, 0, 0, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 0, 192965, 0, 1, 12290, 192965, 192965, 192965, 0, 0, 192965, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1201, 0, 0, 0, 0, 0, 0, 0, 0, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 0, 192965, 192965, 192965, 192965, 192965, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 304, 0, 0, 0, 0, 0, 0, 0, 0, 196608, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1582, 0, 0, 0, 301, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 727, 406, 406, 406, 406, 406, 406, 0, 0, 0, 0, 0, 406, 0, 406, 1, 12290, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 118784, 298, 3, 78114, 78114, 292, 0, 0, 0, 0, 0, 298, 299, 0, 301, 302, 303, 0, 0, 0, 0, 0, 3142, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2978, 534, 534, 534, 534, 0, 0, 0, 0, 733, 406, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1240, 0, 0, 0, 1244, 0, 0, 1175, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2871296, 0, 0, 1171, 1171, 0, 0, 0, 1175, 1650, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 253952, 0, 0, 0, 0, 580, 580, 580, 1540, 2005, 0, 0, 0, 0, 1546, 2007, 0, 0, 0, 0, 1552, 0, 0, 0, 1558, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 405, 0, 0, 0, 0, 0, 2009, 0, 0, 0, 0, 1558, 2011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 406, 0, 0, 0, 0, 0, 534, 534, 534, 534, 2549, 0, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1410, 556, 556, 556, 556, 556, 0, 306, 0, 306, 0, 0, 0, 0, 0, 0, 0, 0, 0, 306, 0, 0, 0, 0, 0, 0, 1155072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2705, 0, 0, 0, 0, 0, 204800, 204800, 0, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 204800, 205106, 204800, 204800, 205105, 205106, 204800, 205105, 205105, 204800, 204800, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 299, 0, 0, 0, 0, 0, 3, 0, 0, 2183794, 0, 0, 0, 0, 0, 298, 299, 151552, 2134016, 302, 303, 0, 0, 0, 0, 0, 155648, 155648, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 655, 212992, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 757, 0, 151552, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 286720, 2179072, 2179072, 2179072, 2179072, 2179072, 2126724, 2126724, 2126724, 2126724, 2126724, 0, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3036110, 2126798, 2126798, 3072974, 2126798, 2126798, 2126798, 3122126, 2700164, 2126724, 2716548, 2126724, 2724740, 2126724, 2732932, 2773892, 2126724, 2126724, 2126724, 2806660, 2126724, 2831236, 2126724, 2126724, 973, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2864004, 2126724, 2126724, 2126724, 2126724, 2921348, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2626436, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3117956, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 0, 0, 975, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3224526, 2179072, 2126798, 2126724, 2179072, 2179072, 2126724, 2126724, 2126798, 2126798, 0, 2486272, 0, 0, 0, 0, 0, 2678784, 2854912, 3006464, 2126798, 2126798, 2126798, 2626510, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2700238, 2126798, 2716622, 2126798, 2724814, 2126798, 2126798, 2126798, 2126798, 2126798, 2454478, 2126798, 2474958, 2483150, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2532302, 2733006, 2773966, 2126798, 2126798, 2126798, 2806734, 2126798, 2831310, 2126798, 2126798, 2864078, 2126798, 2126798, 2126798, 2126798, 2921422, 2126724, 2409348, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2814852, 2126724, 2839428, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3126148, 2126724, 2126724, 2126724, 2126724, 2126798, 2126798, 2585550, 2126798, 2126798, 2126798, 2126798, 2126798, 2618318, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2663374, 2179072, 2179072, 2179072, 3207168, 2179072, 0, 0, 0, 0, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2552708, 2126724, 2126724, 2126724, 2126724, 2126724, 2638724, 2126724, 2126724, 2720644, 2126724, 2126724, 2126724, 2126724, 2126724, 2769796, 2777988, 2782084, 2798468, 2823044, 2126724, 2126724, 2126724, 2884484, 2126724, 2913156, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3040132, 2126724, 2126724, 2126724, 2728836, 2753412, 2126724, 2126724, 2126724, 2126724, 2843524, 2847620, 2126724, 2896772, 2917252, 2126724, 2126724, 2126724, 2126724, 3150724, 2126798, 2429902, 2438094, 2126798, 2487246, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2929614, 2126798, 2126798, 2126798, 2999246, 2126798, 3064708, 2126724, 2126724, 2126724, 2126724, 2126724, 3101572, 2126724, 2126724, 3134340, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2585476, 2126724, 2126724, 2126724, 2126724, 2126724, 2618244, 2126724, 2126724, 2126724, 2126798, 2720718, 2126798, 2126798, 2126798, 2126798, 2126798, 2769870, 2778062, 2782158, 2798542, 2823118, 2126798, 2126798, 2126798, 2884558, 2126798, 2913230, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3040206, 2126798, 2126798, 2126798, 2126798, 2126798, 2601934, 2126798, 2126798, 2126798, 2126798, 2642894, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2606030, 2126798, 2630606, 2126798, 2126798, 2651086, 2126798, 2126798, 2126798, 3064782, 2126798, 2126798, 2126798, 2126798, 2126798, 3101646, 2126798, 2126798, 3134414, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 0, 2179072, 2126798, 2126724, 2457600, 2179072, 2179072, 2179072, 2179072, 2458500, 2126798, 2126798, 2126798, 3208142, 2126798, 2179072, 2126798, 2126724, 2179072, 2179072, 2179072, 2179072, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3011460, 2126724, 2126724, 2126724, 2126798, 2126798, 2503630, 0, 0, 0, 0, 2388868, 2126724, 2126724, 2126724, 2421636, 2126724, 2126724, 2126724, 2126724, 2126724, 2454404, 2126724, 2126724, 2126724, 3027844, 2405326, 2126798, 2126798, 2126798, 2126798, 3027918, 2539520, 0, 2949120, 2179072, 2658304, 2973696, 2474884, 2483076, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2532228, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2601860, 2126724, 2126724, 2126724, 2126724, 2642820, 2126724, 2126724, 2126724, 2126724, 2126724, 2655108, 2679684, 2761604, 2765700, 2786180, 2855812, 2970500, 2126724, 3007364, 2126724, 3019652, 2605956, 2126724, 2630532, 2126724, 2126724, 2651012, 2126724, 2126724, 2126724, 2708356, 2126724, 2737028, 2126724, 2126724, 2126724, 2126724, 2462596, 2466692, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2524036, 2126724, 2126724, 2126724, 2126724, 3036036, 2126724, 2126724, 3072900, 2126724, 2126724, 2126724, 3122052, 2126724, 2126724, 3142532, 2126724, 2126724, 2126724, 3171204, 2126724, 2126724, 3191684, 3195780, 2126724, 0, 0, 0, 0, 0, 0, 2388942, 2126798, 2126798, 2126798, 2421710, 2708430, 2126798, 2737102, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2888654, 2126798, 2126798, 2925518, 2126798, 2126798, 2126798, 2126798, 2179072, 2126798, 2126724, 2179072, 2179072, 2179072, 2179072, 2126724, 2126724, 2126724, 2126724, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2802638, 2814926, 2126798, 2839502, 2126798, 2126798, 2126798, 3142606, 2126798, 2126798, 2126798, 3171278, 2126798, 2126798, 3191758, 3195854, 2126798, 2179072, 2126798, 2126724, 2179072, 2126724, 2126798, 2179072, 2126724, 2126798, 2179072, 2126724, 2126798, 2985984, 2986884, 2986958, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 315, 316, 316, 421, 422, 65536, 429, 2179072, 3112960, 3219456, 2126724, 2126724, 3113860, 3220356, 2126798, 2126798, 3113934, 3220430, 0, 0, 0, 0, 0, 0, 0, 2046, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1238, 0, 0, 0, 0, 0, 0, 2179072, 2179072, 2179072, 3223552, 0, 0, 2126724, 2126724, 2417540, 2126724, 2126724, 2126724, 2446212, 2126724, 2126724, 2126724, 2126724, 2888580, 2126724, 2126724, 2925444, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 0, 0, 2126798, 2126798, 2126798, 2409422, 2126798, 2126798, 2945924, 2126724, 2126724, 2995076, 2126724, 3003268, 2126724, 2126724, 3023748, 2126724, 3068804, 3085188, 2126724, 3097476, 2126724, 2126724, 2126724, 2519940, 2126724, 2126724, 2126724, 2126724, 2589572, 2126724, 2614148, 2646916, 2126724, 2126724, 2696068, 2757508, 2638798, 2126798, 2126798, 2126798, 2126798, 2728910, 2753486, 2126798, 2126798, 2126798, 2126798, 2843598, 2847694, 2126798, 2896846, 2917326, 2126798, 2126798, 2945998, 2126798, 2126798, 2995150, 2126798, 3003342, 2126798, 2126798, 3023822, 2126798, 3068878, 3085262, 2126798, 3097550, 2179072, 2179072, 3059712, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3178496, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3224452, 0, 0, 2126798, 2126798, 2417614, 2126798, 2126798, 2126798, 2446286, 2126798, 2126724, 2126724, 3060612, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3179396, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3126222, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3118030, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2495438, 2126798, 2126798, 2515918, 2126798, 2126798, 2126798, 2544590, 2548686, 2126798, 2126798, 2597838, 2126798, 2126798, 2126798, 2126798, 2425806, 2433998, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 0, 0, 0, 2179072, 2126798, 2126724, 2126798, 2126798, 2126798, 3060686, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3179470, 2179072, 2126798, 2126724, 2179072, 2126724, 2659204, 2974596, 2126724, 2126798, 2659278, 2974670, 2126798, 2711552, 2560000, 2179072, 2560900, 2126724, 2560974, 2126798, 2126798, 2126798, 2126798, 2462670, 2466766, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2524110, 2126798, 2126798, 2126798, 2126798, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2473984, 2478080, 2179072, 2179072, 2179072, 3129344, 2179072, 2179072, 3153920, 3166208, 3174400, 2397060, 2401156, 2126724, 2126724, 2442116, 2126724, 2470788, 3154820, 3167108, 3175300, 2397134, 2401230, 2126798, 2126798, 2442190, 2126798, 2470862, 2126798, 2126798, 2126798, 2520014, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3130318, 2126798, 2126798, 3154894, 3167182, 3175374, 2506752, 2507726, 2507652, 2126798, 2126798, 2589646, 2126798, 2614222, 2646990, 2126798, 2126798, 2696142, 2757582, 2126798, 2126798, 2126798, 2126798, 2933710, 2126798, 2126798, 2126798, 2126798, 2593742, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2449408, 0, 2535424, 2179072, 3006464, 2179072, 3018752, 2179072, 2179072, 2179072, 3149824, 2126724, 2429828, 2438020, 2126724, 2487172, 2126724, 2126724, 2126724, 2126724, 2933636, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 3130244, 2126724, 2126724, 2126798, 2126798, 2655182, 2679758, 2761678, 2765774, 2786254, 2855886, 2970574, 2126798, 3007438, 2126798, 3019726, 2126798, 2126798, 2126798, 2126798, 0, 2502656, 0, 0, 3010560, 0, 0, 0, 0, 2990080, 2179072, 2179072, 2126798, 3150798, 2179072, 3051520, 2126724, 3052420, 2126798, 3052494, 0, 2490368, 2498560, 0, 0, 0, 0, 2875392, 2179072, 2179072, 2179072, 2555904, 2564096, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 3137536, 2126724, 2126724, 2126724, 3208068, 2126724, 0, 0, 0, 0, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2552782, 2126798, 2126798, 2126798, 2126798, 2126798, 2126724, 2499460, 2126724, 2126724, 2126724, 2556804, 2564996, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2929540, 2126724, 2126724, 2126724, 2999172, 2126724, 2126724, 2126724, 3138436, 2126798, 2126798, 2499534, 2126798, 2126798, 2126798, 2556878, 2565070, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 2126798, 3011534, 2126798, 2126798, 2126798, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 322, 323, 0, 2126724, 2450308, 2126724, 2536324, 2126724, 2610052, 2126724, 2859908, 2126724, 2126724, 2126724, 3031940, 2126724, 2126798, 2450382, 2126798, 2126798, 2126798, 2126798, 3093454, 0, 0, 0, 2404352, 2179072, 2179072, 2179072, 2179072, 3026944, 2405252, 2126724, 2126724, 2495364, 2126724, 2126724, 2515844, 2126724, 2126724, 2126724, 2544516, 2548612, 2126724, 2126724, 2597764, 2126724, 2126724, 2126724, 2663300, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2126724, 2802564, 2536398, 2126798, 2610126, 2126798, 2859982, 2126798, 2126798, 2126798, 3032014, 2126798, 2527232, 0, 0, 0, 2179072, 2527232, 2179072, 2179072, 2179072, 2179072, 2179072, 2126724, 2528132, 2126724, 2126724, 2126724, 2126724, 2126724, 3093380, 2126798, 2528206, 2126798, 2126798, 2126798, 2126798, 3138510, 2940928, 2941828, 2941902, 0, 0, 0, 0, 0, 2748416, 2879488, 0, 0, 0, 0, 0, 172032, 0, 172032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 0, 122880, 122880, 0, 0, 0, 221184, 221184, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221184, 221184, 0, 0, 221184, 221184, 221184, 0, 0, 0, 0, 0, 0, 221184, 0, 0, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 338, 292, 0, 0, 0, 0, 0, 0, 221184, 0, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 221184, 1, 12290, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 139264, 299, 0, 0, 2142208, 0, 0, 0, 98304, 0, 0, 0, 53248, 0, 0, 0, 0, 0, 0, 0, 2061, 2062, 0, 0, 0, 0, 0, 0, 0, 0, 159744, 0, 0, 0, 0, 0, 0, 0, 0, 1198, 0, 0, 0, 0, 0, 0, 0, 0, 1212, 0, 0, 0, 0, 0, 0, 0, 0, 1578, 0, 0, 0, 577536, 0, 0, 1583, 0, 0, 0, 302, 0, 303, 0, 0, 0, 303, 0, 0, 0, 2461696, 0, 0, 0, 0, 0, 0, 1159168, 416, 416, 0, 0, 0, 0, 0, 416, 0, 0, 98304, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 12290, 2179072, 3121152, 2179072, 2179072, 3141632, 2179072, 2179072, 2179072, 3170304, 2179072, 2179072, 3190784, 3194880, 2179072, 901, 0, 0, 0, 0, 0, 229376, 0, 0, 0, 0, 0, 0, 0, 0, 1666, 0, 0, 0, 0, 0, 2958, 0, 0, 0, 0, 2962, 0, 0, 0, 0, 2967, 0, 0, 901, 0, 2387968, 2125824, 2125824, 2125824, 2420736, 2125824, 2125824, 2125824, 2125824, 2125824, 2453504, 2125824, 2473984, 2482176, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2531328, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3190784, 3194880, 2125824, 975, 0, 0, 0, 975, 0, 2387968, 2125824, 2125824, 2125824, 2420736, 2179072, 2179072, 2179072, 3223552, 901, 0, 2125824, 2125824, 2416640, 2125824, 2125824, 2125824, 2445312, 2125824, 2125824, 2125824, 2125824, 2125824, 3223552, 0, 0, 2125824, 2125824, 2416640, 2125824, 2125824, 2125824, 2445312, 2125824, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 0, 0, 0, 0, 0, 0, 0, 0, 0, 379, 0, 0, 0, 0, 0, 0, 0, 217088, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 307, 308, 0, 0, 0, 114688, 0, 241664, 258048, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 676, 677, 678, 0, 0, 0, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 0, 0, 0, 0, 0, 0, 0, 0, 0, 386, 0, 0, 0, 0, 0, 386, 0, 0, 0, 2183168, 0, 0, 270336, 0, 0, 298, 299, 0, 2134016, 302, 303, 200704, 0, 0, 180224, 0, 0, 0, 0, 0, 0, 0, 0, 2424832, 2433024, 0, 0, 2457600, 20480, 0, 0, 0, 0, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2126724, 2126724, 2126724, 2126724, 2126724, 1, 12290, 2113825, 0, 0, 0, 0, 0, 0, 295, 0, 0, 0, 295, 0, 0, 0, 0, 0, 0, 2387968, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 330, 381, 383, 0, 0, 0, 0, 0, 266240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 266240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 12290, 0, 0, 266240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 338, 339, 340, 2113825, 0, 0, 2183168, 0, 0, 0, 0, 0, 298, 299, 0, 2134016, 302, 303, 0, 0, 0, 0, 0, 237568, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1657, 0, 0, 0, 0, 274432, 274432, 274432, 274432, 274432, 274432, 0, 0, 0, 0, 0, 274432, 0, 274432, 1, 12290, 3, 0, 0, 0, 0, 0, 0, 0, 90408, 90408, 90408, 90408, 0, 94505, 1, 12290, 3, 78114, 292, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1611, 0, 0, 0, 3, 78114, 78114, 292, 0, 0, 0, 0, 0, 298, 299, 0, 0, 302, 303, 0, 0, 0, 0, 0, 2134016, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1163264, 78114, 1066, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 308, 307, 534, 534, 534, 1341, 901, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 3062, 580, 580, 2009, 0, 0, 0, 0, 0, 2011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 722, 0, 0, 0, 0, 0, 0, 2954, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 330, 0, 0, 1650, 0, 0, 0, 0, 0, 0, 0, 0, 2089, 0, 0, 0, 0, 0, 0, 0, 2086, 0, 0, 0, 0, 0, 2092, 0, 0, 290, 1066, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 680, 681, 3, 78114, 78449, 292, 0, 0, 0, 0, 0, 298, 299, 0, 0, 302, 303, 0, 0, 0, 0, 0, 2134016, 0, 0, 0, 0, 0, 0, 0, 0, 1138688, 0, 0, 0, 0, 0, 2134016, 0, 0, 0, 0, 0, 0, 0, 739, 0, 0, 0, 0, 0, 0, 1150976, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 385, 337, 0, 581, 557, 557, 557, 557, 557, 557, 557, 581, 581, 581, 534, 581, 581, 581, 581, 581, 581, 581, 557, 557, 534, 557, 581, 557, 581, 1, 12290, 1, 12290, 3, 78115, 292, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1680, 0, 0, 0, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 1, 12290, 282624, 282624, 282624, 0, 0, 282624, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2027, 0, 0, 0, 0, 0, 0, 0, 0, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 0, 282624, 282624, 282624, 282624, 282624, 0, 0, 0, 0, 0, 0, 0, 0, 0, 637, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 641, 0, 0, 0, 0, 0, 3047424, 3129344, 0, 2981888, 2396160, 0, 3153920, 3132, 0, 0, 2740224, 0, 0, 0, 0, 0, 0, 1181, 1183, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1608, 1609, 1610, 0, 0, 0, 0, 0, 0, 0, 286720, 286720, 0, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 286720, 0, 0, 0, 0, 0, 0, 0, 0, 0, 705, 0, 0, 0, 709, 0, 0, 0, 3108864, 3198976, 0, 0, 3043328, 0, 3149824, 2936832, 0, 2760704, 3252, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 167936, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 3329, 0, 0, 2834432, 0, 3227648, 2568192, 2564096, 0, 2940928, 2179072, 2179072, 2498560, 3329, 0, 0, 0, 0, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 0, 2125824, 2125824, 0, 0, 0, 308, 0, 0, 0, 0, 0, 307, 0, 307, 308, 0, 307, 307, 0, 0, 0, 307, 307, 308, 308, 0, 0, 0, 0, 0, 0, 307, 407, 308, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 783, 0, 0, 0, 308, 412, 0, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 0, 2134016, 0, 0, 0, 0, 0, 0, 57344, 0, 0, 0, 0, 0, 0, 1120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1239, 0, 0, 0, 0, 0, 456, 456, 456, 482, 482, 456, 482, 482, 482, 482, 482, 482, 482, 507, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 482, 527, 482, 482, 482, 482, 482, 535, 558, 535, 558, 535, 535, 558, 535, 582, 558, 558, 558, 558, 558, 558, 558, 582, 582, 582, 535, 582, 582, 582, 582, 582, 582, 582, 558, 558, 535, 558, 582, 558, 582, 1, 12290, 0, 667, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 769, 0, 697, 0, 0, 0, 0, 0, 0, 0, 704, 0, 0, 0, 0, 0, 0, 0, 0, 1639, 0, 0, 0, 0, 0, 0, 0, 0, 1660, 1661, 0, 1663, 0, 0, 0, 0, 0, 729, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 740, 0, 0, 0, 0, 0, 0, 2834432, 0, 3227648, 2568192, 2564096, 0, 2940928, 2179072, 2179072, 2498560, 0, 0, 0, 638, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 755, 0, 0, 0, 0, 0, 2134749, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1169, 734, 0, 0, 0, 0, 0, 0, 761, 0, 0, 765, 0, 0, 0, 0, 772, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 172032, 0, 0, 0, 0, 65536, 0, 0, 0, 641, 0, 0, 0, 0, 0, 0, 804, 0, 0, 0, 780, 0, 0, 0, 0, 0, 327, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 821, 776, 0, 0, 0, 0, 0, 825, 826, 776, 776, 0, 0, 0, 0, 0, 0, 0, 780, 0, 0, 0, 0, 0, 0, 0, 0, 1677, 0, 1679, 0, 0, 0, 0, 0, 0, 776, 729, 776, 0, 534, 534, 836, 840, 534, 534, 534, 534, 534, 534, 866, 534, 871, 534, 878, 534, 881, 534, 534, 895, 534, 534, 556, 556, 556, 909, 913, 1018, 580, 1025, 580, 1028, 580, 580, 1042, 580, 580, 0, 0, 0, 840, 987, 913, 836, 1052, 881, 534, 534, 909, 1057, 954, 556, 556, 0, 983, 1062, 1028, 580, 580, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 78114, 1066, 0, 0, 1068, 1072, 0, 0, 1076, 1080, 0, 0, 0, 0, 0, 0, 0, 406, 406, 406, 406, 0, 406, 406, 406, 406, 0, 0, 1144, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 508, 515, 515, 0, 0, 0, 1634, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3126, 0, 0, 1769, 534, 534, 1772, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1784, 534, 534, 534, 534, 534, 884, 534, 534, 534, 534, 534, 556, 556, 903, 556, 556, 0, 580, 580, 580, 984, 580, 990, 580, 580, 1003, 580, 580, 1014, 580, 534, 534, 534, 534, 1789, 534, 534, 534, 534, 534, 534, 534, 1341, 1799, 556, 556, 0, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 0, 534, 534, 556, 556, 556, 1806, 556, 556, 556, 556, 556, 1812, 556, 556, 556, 556, 556, 556, 0, 0, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2370, 580, 580, 580, 580, 580, 580, 556, 556, 556, 1825, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 955, 556, 556, 556, 1885, 556, 556, 556, 556, 556, 556, 556, 26009, 1895, 580, 580, 580, 580, 580, 1902, 2017, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 787, 0, 0, 0, 2042, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2051, 0, 0, 0, 0, 0, 0, 1196, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1223, 0, 0, 0, 0, 0, 2109, 2110, 0, 0, 2112, 0, 0, 0, 2110, 0, 0, 2117, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 221184, 0, 0, 0, 0, 65536, 0, 2150, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1313, 0, 0, 0, 2464, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3135, 0, 0, 534, 534, 534, 534, 2502, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2510, 534, 534, 534, 2601, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2611, 556, 556, 556, 556, 556, 2563, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1388, 556, 556, 556, 556, 1393, 556, 556, 556, 556, 2632, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1967, 0, 0, 0, 2698, 0, 0, 0, 0, 0, 0, 2703, 0, 0, 0, 0, 0, 0, 0, 2115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2729, 0, 0, 0, 0, 0, 0, 2749, 2750, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 789, 0, 0, 0, 0, 0, 0, 0, 2762, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2521, 534, 534, 534, 534, 534, 2773, 534, 534, 2777, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2786, 556, 2820, 556, 556, 2824, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2833, 580, 580, 580, 2869, 580, 580, 2873, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2899, 580, 580, 580, 580, 580, 580, 2882, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2890, 580, 580, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 0, 3324, 0, 0, 0, 0, 0, 346, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221184, 0, 221184, 0, 0, 0, 0, 2931, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 3010, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 3412, 556, 556, 556, 556, 556, 556, 3051, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3091, 580, 3093, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 556, 556, 580, 3132, 3387, 0, 3389, 0, 534, 3392, 534, 3394, 534, 534, 534, 534, 534, 534, 534, 534, 1777, 534, 534, 534, 534, 534, 534, 534, 534, 2157, 534, 534, 534, 534, 534, 534, 534, 534, 2182, 534, 534, 534, 534, 2187, 534, 534, 534, 534, 3448, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 3023, 556, 3461, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 580, 3064, 580, 3475, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 0, 3561, 534, 0, 3490, 0, 3492, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2794, 534, 534, 0, 0, 3533, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1281, 309, 310, 311, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 640, 0, 0, 0, 0, 420, 0, 0, 0, 0, 443, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1109, 0, 1111, 1112, 0, 0, 0, 0, 0, 0, 443, 443, 420, 443, 443, 443, 443, 443, 443, 443, 443, 443, 443, 443, 443, 443, 526, 443, 526, 526, 526, 443, 526, 526, 526, 526, 443, 536, 559, 536, 559, 536, 536, 559, 536, 583, 559, 559, 559, 559, 559, 559, 559, 583, 583, 583, 536, 583, 583, 583, 583, 583, 583, 583, 559, 559, 609, 614, 583, 614, 620, 1, 12290, 534, 534, 874, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 0, 580, 580, 580, 580, 580, 580, 1021, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 534, 580, 580, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3445, 534, 0, 0, 0, 1657, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3262, 534, 534, 1785, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1341, 0, 556, 556, 0, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1006, 580, 580, 580, 0, 0, 1544, 0, 0, 0, 0, 0, 1550, 0, 0, 0, 0, 0, 0, 347, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 167936, 580, 580, 1970, 580, 580, 580, 580, 580, 1977, 580, 580, 580, 580, 580, 580, 580, 1444, 580, 580, 580, 580, 580, 1456, 580, 580, 0, 0, 2425, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 654, 0, 0, 2612, 556, 556, 556, 556, 0, 2615, 0, 0, 0, 0, 580, 580, 580, 580, 580, 534, 556, 580, 0, 3382, 0, 0, 3385, 0, 0, 0, 580, 2621, 580, 580, 580, 580, 2625, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3221, 580, 580, 580, 580, 580, 0, 0, 0, 312, 313, 314, 315, 316, 317, 318, 319, 320, 321, 0, 0, 0, 0, 0, 0, 1249, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 850, 534, 534, 534, 534, 534, 0, 312, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1172, 0, 0, 0, 315, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 655, 0, 0, 422, 430, 421, 430, 0, 312, 430, 444, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 457, 478, 483, 483, 494, 483, 483, 483, 483, 483, 483, 483, 483, 509, 509, 522, 522, 523, 523, 523, 523, 523, 523, 523, 523, 523, 523, 523, 509, 523, 523, 523, 523, 523, 537, 560, 537, 560, 537, 537, 560, 537, 584, 560, 560, 560, 560, 560, 560, 560, 584, 584, 584, 606, 584, 584, 584, 584, 584, 584, 607, 608, 608, 606, 608, 607, 608, 607, 1, 12290, 0, 0, 811, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 679, 0, 0, 0, 695, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1720, 534, 534, 882, 534, 534, 556, 556, 955, 556, 556, 0, 580, 580, 1029, 580, 580, 534, 534, 556, 556, 580, 580, 0, 0, 0, 3322, 0, 0, 3325, 0, 0, 0, 0, 1161, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 249856, 0, 0, 0, 0, 0, 0, 0, 1193, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1134592, 0, 0, 0, 0, 0, 1206, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1218, 0, 0, 534, 534, 1254, 534, 1257, 534, 534, 534, 534, 534, 534, 534, 534, 1271, 534, 1276, 534, 534, 1280, 534, 534, 1283, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1294, 534, 534, 534, 534, 534, 1341, 901, 556, 556, 1345, 556, 556, 1349, 556, 556, 556, 556, 556, 0, 0, 0, 0, 0, 0, 580, 580, 580, 580, 580, 0, 3580, 0, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 1363, 556, 1368, 556, 556, 1372, 556, 556, 1375, 556, 556, 556, 556, 556, 0, 2296, 0, 0, 580, 580, 580, 580, 580, 580, 580, 2355, 580, 580, 580, 580, 2360, 580, 580, 580, 580, 1437, 580, 580, 1441, 580, 580, 580, 580, 580, 580, 580, 580, 1455, 580, 1460, 580, 580, 1464, 580, 580, 1467, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 188416, 534, 580, 556, 1669, 0, 0, 0, 0, 0, 0, 1676, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1199, 1200, 0, 0, 0, 0, 0, 580, 1923, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1459, 580, 580, 1936, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1919, 580, 534, 2176, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 0, 0, 534, 534, 534, 534, 2192, 2193, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 3022, 556, 2262, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1819, 556, 556, 556, 2278, 2279, 2280, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1846, 556, 556, 556, 1851, 556, 2349, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1985, 580, 580, 580, 2365, 2366, 2367, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 3558, 0, 3560, 534, 534, 0, 2399, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1243, 0, 0, 0, 0, 0, 2465, 2466, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2090, 0, 0, 0, 0, 580, 580, 580, 2663, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 3105, 534, 534, 534, 534, 534, 2790, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 3019, 556, 556, 556, 556, 2917, 0, 0, 0, 0, 0, 2923, 0, 0, 0, 0, 0, 0, 0, 2927, 0, 0, 0, 0, 0, 2200246, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1617, 0, 0, 0, 0, 0, 0, 0, 0, 2972, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2987, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 899, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3027, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1432, 26009, 1341, 975, 580, 0, 3139, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1597, 0, 534, 534, 534, 534, 3175, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3438, 0, 3439, 0, 0, 0, 0, 0, 0, 0, 534, 3446, 534, 3447, 534, 534, 534, 3451, 534, 534, 534, 534, 534, 534, 534, 556, 3459, 556, 556, 556, 556, 556, 2589, 556, 556, 2593, 556, 556, 556, 556, 556, 556, 556, 2606, 556, 556, 556, 556, 556, 556, 556, 556, 2269, 556, 556, 556, 556, 556, 556, 556, 3460, 556, 556, 556, 3464, 556, 556, 556, 556, 556, 556, 556, 556, 580, 3473, 580, 0, 0, 2920, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2926, 0, 0, 0, 0, 0, 1147, 0, 1149, 0, 0, 0, 0, 0, 0, 0, 0, 534, 557, 534, 557, 534, 534, 557, 534, 3474, 580, 580, 580, 3478, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 534, 534, 3583, 3584, 534, 534, 556, 556, 3596, 556, 556, 556, 3598, 580, 580, 580, 3600, 0, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 3244, 0, 0, 0, 0, 0, 323, 323, 373, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 725, 0, 0, 0, 0, 373, 0, 432, 438, 0, 445, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 458, 484, 484, 495, 484, 484, 484, 484, 484, 484, 484, 484, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 510, 538, 561, 538, 561, 538, 538, 561, 538, 585, 561, 561, 561, 561, 561, 561, 561, 585, 585, 585, 538, 585, 585, 585, 585, 585, 585, 585, 561, 561, 538, 561, 585, 561, 585, 1, 12290, 787, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 859, 534, 534, 534, 534, 534, 534, 2139, 534, 534, 2142, 534, 534, 534, 534, 534, 534, 534, 1760, 1761, 1762, 534, 534, 1765, 1766, 534, 534, 1114, 1115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1613, 0, 1100, 0, 1231, 0, 0, 0, 0, 0, 1115, 0, 0, 0, 0, 0, 1214, 0, 0, 0, 0, 0, 3088384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 752, 0, 0, 0, 0, 0, 0, 1246, 1114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 1255, 534, 534, 534, 1341, 901, 556, 556, 1346, 556, 556, 556, 556, 556, 556, 556, 556, 1389, 556, 556, 556, 556, 556, 556, 556, 556, 1397, 556, 556, 556, 1401, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1880, 556, 556, 556, 556, 556, 580, 1438, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1934, 580, 580, 580, 1465, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1491, 580, 580, 1478, 580, 580, 580, 580, 580, 580, 580, 1487, 580, 580, 1489, 580, 580, 580, 1493, 1517, 580, 580, 580, 580, 580, 0, 534, 580, 556, 534, 534, 534, 534, 534, 556, 580, 534, 556, 580, 534, 556, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 135168, 135168, 0, 0, 65536, 135168, 556, 556, 556, 556, 1872, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1832, 556, 556, 556, 556, 1968, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2362, 580, 580, 2004, 0, 2005, 0, 0, 0, 0, 0, 2007, 0, 0, 0, 0, 0, 0, 0, 2418, 0, 0, 0, 0, 0, 2422, 0, 0, 2009, 0, 0, 0, 0, 0, 2011, 0, 0, 0, 0, 0, 2014, 0, 0, 0, 0, 0, 0, 1576, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2077, 0, 0, 0, 0, 0, 2067, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 827, 2121, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 2770, 534, 534, 534, 534, 2137, 534, 534, 534, 534, 2141, 534, 534, 534, 534, 534, 534, 534, 534, 2518, 534, 534, 534, 534, 534, 534, 534, 534, 2803, 534, 534, 534, 534, 534, 534, 534, 534, 2989, 534, 534, 534, 534, 534, 534, 534, 534, 3165, 534, 534, 534, 534, 534, 534, 534, 534, 3270, 534, 534, 534, 534, 534, 534, 534, 534, 3280, 556, 556, 556, 556, 556, 556, 556, 1426, 556, 556, 556, 556, 26009, 1341, 975, 580, 556, 556, 2222, 556, 556, 556, 556, 2226, 556, 556, 556, 556, 556, 556, 556, 556, 1405, 556, 556, 556, 556, 556, 556, 556, 580, 580, 2309, 580, 580, 580, 580, 2313, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3527, 580, 580, 580, 0, 3531, 0, 0, 2462, 0, 0, 0, 0, 0, 2467, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1640, 0, 0, 0, 0, 0, 0, 534, 534, 534, 2489, 2490, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2522, 534, 534, 534, 534, 534, 534, 2529, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2993, 534, 534, 2620, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2376, 2660, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3316, 2707, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1100, 0, 0, 0, 0, 2724, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1686, 0, 0, 0, 0, 0, 0, 0, 2752, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2028, 0, 0, 0, 534, 534, 534, 534, 534, 2800, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1307, 534, 534, 534, 534, 534, 2891, 580, 580, 580, 580, 580, 580, 580, 2897, 580, 580, 580, 580, 580, 580, 580, 1471, 580, 580, 580, 580, 580, 580, 580, 580, 1045, 580, 0, 0, 0, 534, 580, 556, 3128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1128, 534, 534, 534, 534, 534, 3176, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 3511, 556, 3513, 556, 556, 556, 556, 580, 556, 556, 3297, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3374, 580, 580, 3132, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 3397, 534, 534, 534, 534, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1392, 556, 556, 556, 556, 556, 325, 326, 327, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 741, 0, 0, 0, 0, 0, 324, 372, 327, 371, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1110, 0, 0, 0, 0, 0, 324, 0, 0, 371, 371, 401, 0, 327, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1678, 0, 0, 0, 0, 0, 0, 0, 0, 0, 326, 0, 0, 0, 446, 459, 459, 459, 459, 459, 459, 459, 459, 472, 459, 459, 459, 459, 459, 459, 459, 459, 459, 459, 459, 459, 485, 485, 459, 485, 485, 500, 502, 485, 485, 500, 485, 511, 511, 511, 511, 511, 511, 511, 511, 511, 511, 511, 511, 511, 511, 528, 511, 511, 511, 511, 511, 539, 562, 539, 562, 539, 539, 562, 539, 586, 562, 562, 562, 562, 562, 562, 562, 586, 586, 586, 539, 586, 586, 586, 586, 586, 586, 586, 562, 562, 539, 562, 586, 562, 586, 1, 12290, 0, 651, 652, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 663, 664, 0, 0, 0, 0, 364, 364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 723, 0, 0, 0, 0, 0, 0, 0, 0, 0, 682, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 364, 364, 0, 0, 0, 0, 0, 355, 0, 0, 466, 466, 466, 466, 466, 466, 466, 466, 471, 466, 466, 466, 466, 466, 466, 466, 466, 466, 466, 466, 471, 0, 713, 0, 0, 0, 0, 0, 0, 720, 0, 0, 0, 724, 0, 0, 0, 0, 0, 0, 1621, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 769, 0, 0, 0, 0, 0, 0, 0, 0, 0, 762, 763, 0, 0, 0, 0, 0, 771, 0, 773, 0, 0, 0, 0, 0, 0, 1637, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1095, 0, 0, 0, 0, 0, 0, 0, 0, 0, 790, 793, 0, 0, 0, 793, 793, 790, 0, 0, 0, 0, 0, 0, 0, 106496, 0, 106496, 0, 0, 0, 0, 106496, 106496, 0, 0, 0, 773, 0, 785, 0, 802, 0, 0, 0, 0, 793, 0, 700, 0, 0, 0, 0, 364, 364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1141, 0, 810, 0, 0, 0, 0, 0, 810, 810, 813, 0, 0, 0, 773, 0, 0, 0, 0, 0, 375, 0, 0, 0, 0, 367, 0, 384, 0, 350, 0, 0, 0, 0, 822, 0, 0, 0, 0, 0, 0, 0, 0, 0, 771, 0, 0, 0, 0, 0, 385, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 822, 802, 822, 0, 534, 534, 837, 534, 843, 534, 534, 856, 534, 534, 867, 534, 872, 534, 534, 880, 883, 888, 534, 896, 534, 534, 556, 556, 556, 910, 556, 556, 556, 556, 556, 2604, 2605, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3189, 556, 556, 556, 556, 556, 556, 916, 556, 556, 929, 556, 556, 940, 556, 945, 556, 556, 953, 956, 961, 556, 969, 1019, 580, 580, 1027, 1030, 1035, 580, 1043, 580, 580, 0, 0, 0, 534, 580, 556, 556, 556, 556, 556, 2825, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2284, 556, 556, 556, 556, 556, 837, 534, 1053, 888, 534, 910, 556, 1058, 961, 556, 0, 984, 580, 1063, 1035, 580, 0, 2919, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2458, 0, 0, 0, 0, 1087, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1097, 0, 0, 0, 0, 0, 0, 1659, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 751, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2032, 0, 0, 0, 0, 0, 1104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2078, 0, 0, 0, 1129, 0, 0, 0, 364, 364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2471, 0, 0, 0, 0, 0, 1143, 0, 0, 0, 0, 0, 0, 0, 0, 1152, 0, 0, 0, 0, 0, 0, 0, 2442, 0, 0, 0, 0, 0, 0, 0, 2450, 1121, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1189, 0, 0, 0, 0, 364, 364, 0, 0, 0, 0, 0, 0, 0, 1139, 0, 0, 0, 0, 0, 328, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2757, 2758, 0, 0, 0, 534, 1282, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1297, 1337, 534, 534, 1341, 901, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1354, 556, 556, 1419, 556, 556, 556, 556, 556, 556, 1429, 556, 556, 26009, 1341, 975, 580, 580, 580, 580, 1523, 580, 0, 534, 580, 556, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 2837, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1862, 1863, 556, 556, 556, 556, 1461, 580, 580, 580, 1466, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1915, 580, 580, 580, 580, 580, 580, 1481, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1933, 580, 580, 580, 1495, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1511, 580, 580, 580, 0, 2005, 0, 0, 0, 0, 0, 2007, 0, 0, 0, 0, 0, 0, 0, 2074, 0, 0, 0, 0, 0, 0, 0, 0, 342, 0, 0, 0, 0, 0, 0, 0, 580, 580, 580, 1521, 580, 580, 0, 534, 580, 556, 534, 534, 534, 534, 534, 556, 580, 534, 556, 580, 3610, 3611, 3612, 534, 556, 580, 0, 0, 0, 0, 0, 0, 307, 442, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, 0, 0, 1585, 0, 0, 1588, 1589, 1590, 0, 1592, 1593, 0, 0, 0, 0, 1598, 1631, 1632, 0, 0, 0, 0, 0, 0, 0, 0, 1641, 1642, 0, 0, 0, 0, 0, 0, 0, 155648, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1212, 534, 534, 534, 0, 0, 0, 0, 1648, 0, 0, 1650, 0, 0, 0, 0, 1652, 1653, 0, 0, 0, 0, 0, 441, 0, 0, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 467, 552, 575, 552, 575, 552, 552, 575, 552, 0, 0, 1671, 1672, 1673, 1674, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2483, 0, 0, 0, 0, 0, 1683, 0, 0, 1686, 0, 0, 0, 0, 0, 1690, 0, 0, 0, 1694, 1695, 1706, 1566, 1566, 1708, 534, 1710, 534, 1711, 1712, 534, 1714, 534, 534, 534, 1718, 534, 534, 534, 534, 534, 886, 534, 534, 534, 534, 534, 556, 556, 908, 556, 556, 556, 556, 556, 2254, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1431, 556, 26009, 1341, 975, 1435, 534, 534, 1739, 534, 1741, 534, 534, 534, 534, 534, 534, 534, 534, 1749, 1750, 1752, 534, 1786, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1797, 1341, 0, 1802, 556, 556, 556, 556, 556, 3041, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3200, 556, 556, 556, 556, 556, 556, 1804, 556, 1805, 556, 1807, 556, 1809, 556, 556, 556, 1813, 556, 556, 556, 556, 556, 0, 0, 0, 0, 0, 0, 580, 580, 2618, 580, 580, 556, 556, 556, 556, 1826, 556, 556, 556, 556, 1830, 556, 556, 556, 556, 1834, 556, 556, 556, 556, 556, 3055, 556, 556, 556, 556, 556, 580, 580, 580, 3063, 580, 580, 580, 580, 1724, 1915, 1819, 534, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 0, 0, 2692, 0, 0, 1836, 556, 556, 556, 556, 556, 556, 556, 556, 1844, 1845, 1847, 556, 556, 556, 556, 556, 0, 2297, 0, 0, 580, 580, 580, 580, 580, 580, 580, 2667, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2653, 580, 580, 580, 580, 2657, 580, 556, 556, 556, 1855, 1856, 1857, 556, 556, 1860, 1861, 556, 556, 556, 556, 556, 556, 0, 0, 580, 580, 580, 2862, 580, 580, 580, 580, 556, 1869, 556, 556, 556, 1873, 556, 556, 556, 556, 556, 556, 556, 1882, 556, 556, 0, 580, 580, 580, 580, 580, 580, 580, 1002, 580, 580, 580, 580, 580, 580, 3555, 3556, 580, 580, 0, 0, 3559, 0, 534, 534, 1903, 580, 1905, 580, 580, 580, 1909, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3528, 580, 580, 0, 0, 0, 1922, 580, 580, 580, 580, 1926, 580, 580, 580, 580, 1930, 580, 1932, 580, 580, 580, 580, 580, 1524, 0, 1270, 1454, 1362, 534, 534, 534, 534, 534, 556, 1952, 1953, 580, 580, 1956, 1957, 580, 580, 580, 580, 580, 580, 580, 1965, 580, 580, 534, 534, 556, 556, 580, 580, 3321, 0, 0, 0, 3323, 0, 0, 0, 0, 0, 0, 2114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2605056, 0, 0, 0, 0, 2887680, 580, 1969, 580, 580, 580, 580, 580, 580, 580, 1978, 580, 580, 580, 580, 580, 580, 0, 534, 580, 556, 534, 534, 534, 534, 534, 556, 580, 580, 580, 1989, 534, 580, 556, 1766, 534, 1995, 534, 1861, 556, 1999, 556, 1957, 580, 2003, 580, 0, 2005, 0, 0, 0, 0, 0, 2007, 0, 0, 0, 0, 0, 0, 0, 2702, 0, 0, 0, 0, 0, 0, 0, 2706, 0, 2018, 0, 0, 2021, 2022, 0, 0, 0, 2026, 0, 0, 0, 0, 0, 0, 0, 414, 414, 0, 0, 0, 0, 0, 414, 0, 0, 0, 2069, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 742, 0, 0, 0, 1650, 0, 0, 0, 0, 0, 0, 0, 2088, 0, 0, 0, 0, 0, 0, 0, 451, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 1147348, 2095, 0, 2097, 0, 0, 0, 0, 0, 0, 0, 0, 2106, 0, 0, 0, 0, 0, 0, 0, 184725, 184925, 184925, 184925, 0, 184925, 184925, 184925, 184925, 184925, 184925, 0, 0, 0, 0, 0, 184925, 0, 184925, 1, 12290, 534, 534, 534, 2153, 534, 2155, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1746, 534, 534, 534, 534, 534, 534, 2204, 2205, 534, 534, 0, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2558, 556, 556, 556, 556, 2238, 556, 2240, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2231, 556, 556, 556, 556, 556, 2291, 2292, 556, 556, 0, 0, 0, 0, 580, 580, 580, 580, 580, 580, 580, 1506, 580, 580, 580, 580, 580, 1513, 580, 580, 580, 580, 2325, 580, 2327, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2318, 580, 580, 580, 580, 580, 2378, 2379, 580, 580, 2145, 2317, 2230, 534, 2385, 534, 534, 556, 2389, 556, 556, 0, 580, 580, 580, 580, 580, 580, 997, 580, 580, 580, 580, 580, 580, 2328, 580, 2330, 580, 580, 580, 580, 580, 580, 580, 2342, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1474, 580, 580, 580, 580, 580, 580, 580, 2393, 580, 580, 2005, 0, 2007, 0, 2009, 0, 2011, 0, 0, 0, 0, 0, 0, 0, 2727, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1579, 0, 0, 0, 0, 0, 0, 0, 2437, 2438, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1089, 0, 0, 534, 2526, 534, 534, 534, 2531, 534, 534, 534, 534, 534, 534, 534, 2538, 534, 534, 534, 534, 534, 534, 2169, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2782, 534, 534, 2785, 534, 534, 534, 534, 534, 534, 534, 2543, 534, 534, 534, 534, 534, 534, 534, 534, 0, 2549, 556, 556, 2587, 556, 556, 556, 556, 2591, 556, 556, 556, 2596, 556, 556, 556, 556, 556, 0, 2615, 0, 0, 0, 0, 580, 580, 580, 580, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 3386, 556, 556, 556, 2603, 556, 556, 556, 556, 556, 556, 556, 556, 2609, 556, 556, 556, 556, 556, 556, 3042, 556, 3044, 556, 556, 556, 556, 556, 556, 556, 1404, 556, 556, 1411, 556, 556, 556, 556, 556, 580, 580, 580, 2623, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1451, 580, 580, 580, 580, 580, 580, 2635, 580, 2637, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1914, 580, 580, 580, 580, 580, 580, 580, 2662, 580, 580, 580, 580, 580, 580, 580, 2669, 580, 580, 580, 580, 580, 580, 2895, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1046, 0, 0, 0, 534, 580, 556, 580, 580, 580, 2675, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 2913, 556, 2915, 580, 534, 534, 534, 2798, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3348, 534, 556, 556, 556, 556, 556, 2846, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2245, 556, 556, 556, 556, 0, 2943, 2944, 0, 2945, 0, 2947, 0, 0, 0, 0, 2949, 0, 0, 0, 0, 0, 0, 0, 225883, 225883, 225883, 225883, 225734, 225883, 225883, 225883, 225883, 225883, 225883, 225734, 225734, 225734, 225734, 225734, 225899, 225734, 225899, 1, 12290, 2968, 2969, 0, 2971, 0, 0, 2974, 0, 0, 0, 2977, 534, 534, 534, 534, 534, 0, 0, 0, 0, 556, 2214, 556, 556, 556, 556, 556, 0, 0, 0, 0, 0, 0, 580, 2617, 580, 580, 580, 534, 2984, 534, 534, 534, 534, 534, 2988, 534, 534, 534, 534, 534, 534, 534, 2994, 534, 534, 534, 534, 534, 3000, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1763, 534, 534, 534, 534, 534, 3009, 3011, 534, 534, 534, 3014, 534, 3016, 3017, 534, 556, 556, 556, 556, 556, 556, 0, 0, 580, 2861, 580, 580, 580, 580, 580, 580, 0, 1267, 1451, 1359, 534, 534, 534, 1530, 534, 556, 3024, 556, 556, 556, 556, 556, 3028, 556, 556, 556, 556, 556, 556, 556, 3034, 556, 556, 556, 556, 556, 3185, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2229, 556, 556, 2233, 556, 556, 556, 556, 556, 556, 3040, 556, 556, 3043, 556, 556, 556, 556, 556, 556, 556, 556, 1829, 556, 556, 556, 556, 556, 556, 556, 3050, 3052, 556, 556, 556, 556, 3056, 556, 3058, 3059, 556, 580, 580, 580, 580, 580, 580, 3083, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2331, 580, 580, 580, 580, 2335, 580, 580, 3066, 580, 580, 580, 580, 580, 3070, 580, 580, 580, 580, 580, 580, 580, 3076, 580, 3092, 3094, 580, 580, 580, 580, 3098, 580, 3100, 3101, 580, 534, 580, 556, 534, 534, 534, 534, 534, 887, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 0, 0, 0, 2299, 580, 580, 580, 580, 580, 580, 580, 3084, 580, 3086, 580, 580, 580, 580, 580, 580, 3106, 556, 3108, 580, 3110, 0, 0, 0, 0, 0, 0, 3116, 0, 0, 3119, 0, 0, 0, 0, 364, 364, 0, 0, 0, 0, 0, 1096, 0, 0, 0, 0, 0, 0, 0, 286720, 0, 0, 0, 0, 0, 0, 0, 0, 0, 643, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3140, 3141, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2107, 0, 0, 0, 556, 556, 556, 556, 3184, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2272, 556, 556, 556, 556, 556, 556, 556, 3195, 556, 556, 556, 556, 556, 556, 556, 556, 3203, 556, 556, 556, 556, 556, 556, 3197, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2594, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 3208, 580, 580, 580, 580, 580, 580, 580, 3213, 580, 580, 580, 580, 1907, 580, 580, 580, 580, 580, 580, 580, 580, 1918, 580, 580, 580, 580, 580, 3096, 580, 580, 3099, 580, 580, 580, 534, 580, 556, 534, 534, 534, 534, 534, 534, 3278, 534, 534, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3515, 556, 556, 580, 556, 3296, 556, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3214, 3326, 3327, 0, 3132, 0, 3331, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 2766, 534, 534, 534, 534, 534, 2771, 534, 534, 534, 3405, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 960, 556, 556, 556, 556, 556, 3420, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1452, 580, 580, 580, 580, 580, 3436, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3502, 534, 534, 534, 534, 534, 3450, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 3281, 556, 556, 556, 3284, 556, 556, 556, 3463, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 3302, 580, 580, 580, 580, 580, 580, 580, 3477, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3486, 3487, 0, 0, 0, 0, 364, 364, 0, 0, 0, 0, 1137, 1095, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 266240, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 0, 3493, 3494, 3495, 534, 534, 534, 3498, 534, 3500, 534, 534, 534, 534, 534, 534, 534, 3269, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2781, 534, 534, 534, 534, 534, 534, 534, 3505, 3506, 3507, 556, 556, 556, 3510, 556, 3512, 556, 556, 556, 556, 3517, 3518, 3519, 3520, 580, 580, 580, 3523, 580, 3525, 580, 580, 580, 580, 3530, 0, 0, 0, 0, 0, 0, 1687, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 783, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3562, 534, 534, 534, 3566, 556, 556, 3568, 556, 556, 556, 3572, 556, 580, 580, 3574, 580, 580, 580, 3578, 580, 0, 0, 0, 534, 534, 534, 534, 534, 534, 556, 556, 580, 580, 0, 3111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 398, 0, 0, 0, 0, 0, 0, 0, 0, 328, 329, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2409, 0, 0, 0, 0, 368, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1629, 0, 0, 0, 0, 368, 0, 0, 0, 376, 378, 0, 0, 0, 0, 0, 0, 0, 0, 2025, 0, 0, 0, 0, 0, 0, 0, 0, 2047, 0, 0, 0, 0, 0, 0, 0, 0, 2087, 0, 0, 0, 0, 0, 0, 0, 0, 2127, 0, 0, 534, 534, 534, 534, 534, 0, 0, 411, 0, 0, 0, 411, 69632, 73728, 0, 368, 368, 0, 423, 65536, 368, 0, 0, 368, 423, 492, 496, 492, 492, 501, 492, 492, 492, 501, 492, 423, 423, 329, 423, 0, 0, 423, 423, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2048, 0, 0, 0, 0, 0, 0, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 423, 540, 563, 540, 563, 540, 540, 563, 540, 587, 563, 563, 563, 563, 563, 563, 563, 587, 587, 587, 540, 587, 587, 587, 587, 587, 587, 587, 563, 563, 540, 563, 587, 563, 587, 1, 12290, 0, 769, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1644, 0, 556, 556, 556, 556, 933, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2285, 556, 2287, 556, 556, 0, 0, 1207, 0, 1096, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2447, 0, 0, 0, 534, 534, 534, 534, 1260, 534, 534, 534, 534, 534, 1272, 534, 534, 534, 534, 534, 0, 0, 0, 2212, 556, 556, 556, 556, 556, 556, 556, 3029, 556, 556, 556, 556, 556, 556, 556, 556, 3030, 556, 556, 556, 556, 556, 556, 556, 534, 534, 534, 1341, 901, 556, 556, 556, 556, 556, 556, 556, 556, 1352, 556, 556, 0, 580, 580, 580, 580, 580, 580, 998, 580, 580, 580, 580, 580, 580, 2650, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2315, 580, 2317, 580, 580, 580, 580, 556, 556, 556, 1364, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1378, 1380, 556, 556, 556, 556, 556, 1871, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1413, 556, 556, 1417, 534, 534, 534, 534, 534, 3567, 556, 556, 556, 556, 556, 556, 556, 3573, 580, 580, 580, 580, 580, 2677, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 534, 534, 556, 556, 556, 556, 580, 534, 3597, 556, 556, 556, 3599, 580, 580, 580, 0, 534, 534, 556, 556, 580, 580, 0, 0, 0, 3243, 0, 0, 0, 0, 0, 0, 0, 657, 0, 0, 0, 0, 0, 0, 0, 0, 306, 306, 306, 0, 0, 0, 0, 0, 424, 424, 0, 424, 433, 0, 424, 424, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 460, 486, 486, 460, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 486, 541, 564, 541, 564, 541, 541, 564, 541, 588, 564, 564, 564, 564, 564, 564, 564, 588, 588, 588, 541, 588, 588, 588, 588, 588, 588, 588, 564, 564, 541, 564, 588, 564, 588, 1, 12290, 78114, 1066, 0, 0, 1069, 1073, 0, 0, 1077, 1081, 0, 0, 0, 0, 0, 0, 0, 703, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2104, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1194, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2472, 0, 0, 0, 0, 1670, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1667, 0, 0, 0, 0, 0, 2044, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2704, 0, 0, 0, 0, 2068, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1681, 1682, 2392, 580, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2928, 0, 0, 0, 2932, 0, 0, 0, 0, 0, 2938, 0, 0, 0, 0, 0, 0, 0, 719, 0, 0, 0, 0, 0, 0, 0, 0, 0, 721, 0, 0, 0, 0, 0, 0, 2953, 0, 0, 2956, 0, 0, 0, 0, 0, 2961, 0, 0, 0, 0, 0, 0, 0, 748, 0, 0, 0, 0, 0, 0, 0, 0, 333, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1204, 2995, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3004, 534, 534, 534, 534, 534, 0, 0, 2211, 0, 556, 556, 556, 556, 556, 556, 556, 2268, 556, 556, 556, 556, 2273, 556, 556, 556, 534, 534, 534, 3012, 534, 534, 3015, 534, 534, 534, 3018, 556, 556, 556, 556, 556, 0, 0, 0, 0, 580, 580, 580, 580, 580, 580, 580, 556, 556, 534, 556, 580, 556, 580, 1, 12290, 556, 556, 556, 556, 3054, 556, 556, 3057, 556, 556, 556, 3060, 580, 580, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 2396, 0, 0, 0, 3077, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3087, 580, 580, 580, 580, 0, 0, 0, 0, 0, 0, 3442, 0, 3444, 0, 534, 534, 0, 3120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2015, 0, 0, 534, 534, 3151, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3458, 556, 556, 534, 534, 534, 534, 3163, 534, 534, 534, 534, 534, 534, 534, 3168, 534, 3170, 534, 534, 534, 534, 534, 1261, 534, 534, 534, 1270, 534, 534, 534, 534, 534, 534, 534, 2493, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2196, 534, 534, 534, 534, 534, 534, 556, 556, 556, 580, 580, 3207, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1962, 580, 580, 580, 580, 580, 580, 3227, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 2912, 534, 2914, 556, 2916, 3275, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 556, 556, 3287, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3293, 556, 556, 556, 556, 556, 556, 3466, 556, 556, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3306, 3587, 3588, 556, 556, 580, 580, 3591, 3592, 580, 580, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1716, 534, 534, 534, 0, 683, 684, 0, 0, 0, 0, 689, 0, 0, 0, 364, 364, 364, 0, 0, 0, 0, 0, 534, 830, 534, 534, 534, 534, 534, 534, 860, 534, 534, 534, 534, 534, 534, 2180, 2181, 534, 534, 534, 534, 534, 534, 2188, 534, 0, 751, 0, 0, 0, 0, 0, 751, 751, 0, 0, 816, 0, 0, 0, 0, 0, 0, 0, 1134592, 0, 0, 0, 0, 0, 0, 1134592, 0, 0, 0, 0, 970, 556, 0, 580, 580, 580, 580, 988, 580, 580, 580, 580, 580, 580, 580, 580, 1044, 580, 0, 0, 0, 841, 988, 914, 534, 534, 534, 534, 897, 556, 556, 556, 556, 970, 0, 580, 580, 580, 580, 1044, 0, 0, 0, 1145, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2408448, 0, 0, 534, 1318, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 0, 2549, 1696, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1190, 580, 580, 1988, 580, 534, 580, 556, 534, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2122, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 2768, 534, 2769, 534, 534, 2540, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 0, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 0, 0, 975, 580, 0, 3129, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2053, 0, 3235, 534, 3237, 556, 3239, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3124, 3125, 0, 0, 0, 556, 556, 556, 3298, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2359, 580, 580, 580, 580, 3317, 580, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2076, 0, 0, 0, 0, 0, 0, 461, 461, 479, 487, 487, 479, 487, 487, 487, 487, 487, 487, 487, 487, 512, 520, 520, 520, 520, 520, 520, 520, 520, 520, 520, 520, 520, 520, 520, 529, 520, 520, 520, 520, 520, 542, 565, 542, 565, 542, 542, 565, 542, 589, 565, 565, 565, 565, 565, 565, 565, 589, 589, 589, 542, 589, 589, 589, 589, 589, 589, 589, 565, 565, 542, 565, 589, 565, 589, 1, 12290, 0, 0, 760, 0, 0, 764, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 0, 778, 0, 0, 0, 0, 0, 0, 0, 782, 0, 0, 0, 0, 0, 0, 0, 779, 0, 0, 0, 0, 788, 0, 0, 0, 0, 0, 0, 800, 0, 0, 0, 0, 0, 0, 805, 0, 0, 0, 782, 0, 0, 0, 0, 364, 364, 0, 0, 0, 1136, 0, 0, 0, 0, 0, 0, 0, 1606, 0, 0, 0, 0, 0, 0, 0, 0, 553, 576, 553, 576, 553, 553, 576, 553, 0, 805, 0, 0, 0, 0, 0, 805, 805, 0, 0, 0, 0, 782, 0, 0, 0, 0, 0, 534, 831, 534, 534, 534, 846, 534, 534, 534, 534, 534, 0, 2210, 0, 0, 556, 556, 556, 556, 556, 556, 556, 1893, 26009, 0, 1898, 580, 1900, 580, 1901, 580, 0, 0, 0, 0, 823, 778, 0, 0, 823, 0, 0, 0, 0, 0, 0, 0, 0, 2468, 0, 0, 0, 0, 0, 0, 0, 0, 2022, 0, 2116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 823, 534, 534, 534, 534, 844, 534, 852, 534, 534, 534, 534, 0, 0, 556, 556, 556, 556, 556, 2815, 556, 2816, 556, 556, 917, 556, 925, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2583, 556, 971, 556, 0, 580, 580, 580, 580, 580, 991, 580, 999, 580, 580, 580, 580, 580, 580, 3097, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 534, 534, 1054, 898, 556, 556, 556, 1059, 971, 0, 580, 580, 580, 1064, 1045, 0, 1159, 0, 0, 0, 0, 0, 0, 0, 1167, 0, 0, 0, 0, 0, 0, 0, 789, 0, 0, 0, 0, 0, 0, 770, 0, 0, 0, 1219, 0, 0, 0, 0, 0, 0, 0, 0, 1224, 0, 0, 0, 0, 0, 0, 0, 1134592, 0, 364, 0, 0, 0, 1134592, 0, 0, 0, 1134592, 1134592, 0, 0, 1134592, 0, 0, 1134592, 0, 1134592, 534, 534, 1284, 534, 534, 534, 534, 534, 534, 534, 1292, 534, 534, 534, 534, 534, 0, 2209, 0, 0, 556, 556, 556, 556, 556, 556, 556, 1842, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 1896, 580, 580, 580, 580, 580, 580, 534, 534, 534, 1321, 534, 534, 1325, 534, 534, 534, 534, 534, 1331, 534, 534, 534, 534, 534, 534, 534, 3342, 534, 3344, 534, 534, 534, 534, 534, 556, 1338, 534, 534, 1341, 901, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2568, 556, 556, 556, 556, 556, 1357, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1376, 556, 556, 556, 556, 556, 0, 2615, 0, 0, 0, 0, 580, 580, 580, 2619, 580, 556, 556, 556, 1384, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1816, 1817, 556, 556, 580, 580, 580, 1522, 580, 580, 0, 534, 580, 556, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 3196, 556, 3198, 556, 556, 556, 556, 556, 556, 556, 556, 1878, 1879, 556, 556, 556, 556, 556, 556, 534, 534, 534, 534, 1773, 534, 534, 534, 534, 534, 534, 1781, 534, 534, 534, 534, 0, 0, 556, 556, 556, 2813, 556, 556, 556, 556, 556, 2818, 556, 556, 1823, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2842, 556, 556, 556, 1853, 556, 556, 556, 556, 1859, 556, 556, 556, 556, 556, 556, 556, 556, 2840, 556, 556, 556, 556, 556, 556, 556, 1868, 556, 556, 556, 556, 556, 556, 1876, 556, 556, 556, 556, 556, 556, 556, 556, 2850, 556, 556, 556, 556, 556, 556, 556, 556, 1886, 1888, 556, 556, 556, 556, 556, 26009, 0, 580, 580, 580, 580, 580, 580, 0, 1525, 1526, 1527, 534, 534, 1529, 534, 534, 556, 580, 580, 580, 1955, 580, 580, 580, 580, 580, 580, 580, 580, 1964, 580, 580, 580, 580, 580, 1940, 1941, 1943, 580, 580, 580, 580, 580, 580, 580, 1951, 580, 580, 580, 1972, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1982, 1984, 580, 580, 580, 580, 1925, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2372, 580, 2374, 580, 580, 0, 0, 0, 2057, 0, 0, 0, 0, 0, 2063, 0, 0, 0, 0, 0, 0, 0, 1089, 0, 0, 0, 0, 1241, 1242, 0, 0, 0, 0, 0, 0, 2071, 0, 0, 0, 0, 0, 0, 0, 0, 2079, 0, 0, 0, 0, 0, 534, 833, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1306, 534, 534, 534, 534, 534, 534, 2134, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2146, 534, 534, 534, 534, 534, 534, 534, 3453, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 2826, 556, 556, 556, 556, 556, 556, 556, 556, 556, 949, 556, 556, 556, 556, 967, 556, 2189, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1314, 2203, 534, 534, 534, 534, 0, 0, 0, 0, 556, 556, 556, 556, 556, 556, 2219, 2290, 556, 556, 556, 556, 0, 0, 0, 0, 580, 580, 580, 580, 580, 580, 2306, 2377, 580, 580, 580, 580, 2146, 2318, 2231, 534, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 0, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 0, 0, 3246, 0, 0, 0, 0, 0, 2413, 2414, 0, 0, 2417, 0, 2419, 0, 0, 0, 0, 0, 0, 0, 0, 2712, 0, 0, 0, 0, 0, 0, 0, 0, 2728, 0, 0, 0, 0, 0, 0, 0, 0, 2429, 0, 0, 0, 0, 0, 0, 0, 0, 2406, 0, 0, 0, 0, 0, 0, 0, 0, 2454, 0, 0, 0, 0, 0, 0, 0, 0, 1587, 0, 0, 0, 0, 0, 0, 0, 1595, 1596, 0, 0, 0, 2424, 0, 0, 2427, 0, 0, 0, 0, 0, 0, 2431, 0, 0, 0, 0, 0, 0, 0, 1159168, 0, 1159168, 0, 0, 0, 0, 1159168, 1159168, 0, 0, 0, 2452, 0, 0, 0, 0, 0, 0, 0, 2456, 2457, 0, 0, 2460, 0, 0, 2463, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2473, 0, 0, 0, 0, 0, 639, 0, 0, 0, 0, 644, 645, 646, 647, 648, 649, 534, 2487, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3008, 534, 534, 534, 2515, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1293, 534, 534, 534, 534, 2527, 534, 534, 534, 534, 534, 534, 2534, 534, 534, 534, 534, 534, 534, 534, 534, 3343, 534, 534, 534, 534, 534, 534, 556, 534, 534, 2541, 534, 534, 534, 2544, 534, 534, 534, 534, 534, 534, 534, 0, 0, 0, 0, 556, 556, 556, 556, 2217, 556, 556, 556, 2574, 556, 556, 556, 556, 556, 556, 2579, 556, 556, 556, 556, 556, 556, 556, 1427, 1428, 556, 556, 556, 26009, 1341, 975, 580, 2585, 556, 556, 556, 556, 556, 556, 2592, 556, 556, 556, 556, 556, 556, 2599, 556, 556, 556, 556, 556, 3290, 556, 556, 556, 556, 3291, 3292, 556, 556, 556, 556, 556, 0, 0, 2298, 0, 580, 580, 580, 580, 580, 580, 580, 2886, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3312, 580, 580, 580, 580, 580, 580, 2673, 580, 580, 580, 2676, 580, 580, 580, 580, 580, 580, 580, 2681, 2682, 2683, 534, 534, 534, 534, 534, 1289, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2185, 534, 534, 534, 534, 2720, 2721, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2080, 0, 0, 0, 2736, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2746, 0, 0, 0, 0, 0, 667, 0, 0, 0, 0, 0, 729, 0, 780, 0, 0, 0, 0, 0, 305, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1565, 0, 0, 0, 0, 0, 0, 2751, 0, 0, 0, 2753, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2109, 534, 534, 534, 534, 534, 2787, 2788, 534, 534, 534, 534, 2791, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 3178, 556, 556, 556, 556, 2796, 534, 534, 534, 2799, 534, 2801, 534, 534, 534, 534, 534, 534, 2805, 534, 534, 534, 534, 534, 534, 2492, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1745, 534, 534, 534, 534, 534, 534, 2834, 2835, 556, 556, 556, 556, 2838, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2257, 556, 556, 556, 556, 556, 556, 556, 2844, 556, 556, 556, 2847, 556, 2849, 556, 556, 556, 556, 556, 556, 556, 2854, 580, 2867, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1949, 580, 580, 580, 2883, 2884, 580, 580, 580, 580, 2887, 580, 580, 580, 580, 580, 580, 580, 1928, 580, 580, 580, 580, 580, 580, 580, 580, 1912, 1913, 580, 580, 580, 580, 1920, 580, 580, 580, 580, 2893, 580, 580, 580, 2896, 580, 2898, 580, 580, 580, 580, 580, 580, 1190, 534, 580, 556, 534, 534, 534, 534, 534, 556, 580, 2903, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 556, 556, 580, 580, 0, 0, 3242, 0, 0, 0, 0, 0, 0, 0, 0, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 225734, 0, 0, 0, 0, 0, 0, 0, 0, 0, 366, 0, 0, 0, 0, 0, 0, 580, 2918, 0, 0, 2921, 2922, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3132, 0, 0, 3255, 0, 534, 534, 534, 534, 2986, 534, 534, 534, 534, 534, 534, 534, 2992, 534, 534, 534, 534, 534, 534, 891, 534, 534, 534, 534, 556, 556, 556, 556, 556, 0, 0, 0, 0, 580, 580, 2302, 580, 580, 580, 580, 556, 556, 556, 3026, 556, 556, 556, 556, 556, 556, 556, 3032, 556, 556, 556, 556, 556, 556, 1841, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3357, 556, 3359, 556, 556, 556, 556, 580, 580, 580, 580, 3068, 580, 580, 580, 580, 580, 580, 580, 3074, 580, 580, 580, 580, 580, 2311, 580, 580, 2314, 580, 580, 580, 580, 580, 580, 2322, 3138, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1191, 3247, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 2767, 534, 534, 534, 534, 534, 534, 534, 534, 3265, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1341, 0, 556, 556, 534, 534, 3276, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 3283, 556, 556, 556, 556, 556, 3299, 580, 580, 580, 580, 580, 580, 580, 3304, 580, 580, 580, 580, 580, 3479, 580, 3481, 580, 580, 3483, 580, 580, 0, 0, 0, 0, 0, 0, 1210, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2421, 0, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 3399, 534, 3401, 3402, 534, 3404, 534, 556, 556, 556, 556, 556, 556, 556, 556, 3414, 556, 3416, 3417, 556, 3419, 556, 3421, 580, 580, 580, 580, 580, 580, 580, 580, 3430, 580, 3432, 3433, 580, 3435, 580, 3437, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 3499, 534, 3501, 534, 534, 580, 580, 580, 3553, 580, 3554, 580, 580, 580, 580, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 3538, 534, 3539, 534, 534, 534, 3604, 3605, 3606, 534, 556, 580, 534, 556, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 3211264, 0, 0, 0, 2179072, 2179072, 2179072, 2179072, 2179072, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 3117056, 2125824, 2125824, 2125824, 2125824, 590, 566, 566, 566, 566, 566, 566, 566, 590, 590, 590, 543, 590, 590, 590, 590, 590, 590, 590, 566, 566, 543, 566, 590, 566, 590, 1, 12290, 556, 556, 1398, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2853, 556, 0, 0, 730, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1126, 1127, 0, 534, 534, 534, 534, 2138, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2784, 534, 534, 534, 556, 556, 556, 2223, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1849, 556, 556, 556, 580, 580, 580, 2310, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1490, 580, 580, 580, 402, 0, 0, 0, 0, 380, 0, 69632, 73728, 0, 0, 0, 0, 425, 65536, 0, 0, 0, 0, 364, 364, 1133, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3133, 0, 0, 0, 3136, 0, 425, 425, 0, 425, 0, 439, 425, 425, 462, 462, 462, 469, 462, 462, 462, 462, 462, 462, 462, 462, 469, 462, 462, 462, 462, 462, 462, 462, 462, 476, 462, 488, 488, 462, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 488, 531, 544, 567, 544, 567, 544, 544, 567, 544, 591, 567, 567, 567, 567, 567, 567, 567, 591, 591, 591, 544, 591, 591, 591, 591, 591, 591, 591, 567, 567, 544, 567, 591, 567, 591, 1, 12290, 0, 0, 0, 653, 654, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2939, 0, 0, 2941, 0, 0, 0, 654, 0, 654, 0, 0, 0, 0, 814, 0, 0, 0, 654, 0, 0, 0, 0, 374, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 2130, 534, 534, 534, 556, 919, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 957, 556, 556, 556, 556, 556, 556, 3545, 556, 3546, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 0, 0, 0, 534, 534, 534, 534, 534, 534, 556, 556, 534, 534, 884, 534, 534, 556, 556, 957, 556, 556, 0, 580, 580, 1031, 580, 580, 580, 580, 580, 2907, 580, 580, 534, 580, 556, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 0, 0, 0, 3117, 0, 0, 0, 290, 1066, 0, 0, 1069, 1073, 0, 0, 1077, 1081, 0, 0, 0, 0, 0, 0, 0, 1094, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 192965, 0, 0, 0, 1088, 1089, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 131072, 0, 0, 0, 1130, 0, 0, 364, 364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3132, 0, 3254, 0, 0, 1089, 1088, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2093, 0, 1088, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 1253, 534, 534, 534, 534, 534, 1303, 534, 534, 1305, 534, 534, 534, 1309, 534, 534, 534, 0, 901, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3549, 580, 580, 580, 534, 534, 534, 534, 1287, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2804, 534, 534, 2807, 534, 534, 1320, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1334, 534, 534, 534, 534, 534, 1323, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2509, 534, 534, 534, 534, 534, 534, 534, 1341, 901, 556, 1344, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2283, 556, 556, 556, 556, 556, 556, 556, 556, 1358, 1365, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1379, 556, 556, 0, 580, 580, 580, 985, 989, 992, 580, 1000, 580, 580, 580, 1015, 1017, 556, 556, 556, 1399, 556, 556, 556, 556, 556, 556, 556, 1412, 556, 556, 556, 556, 556, 556, 1858, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1402, 556, 556, 556, 556, 556, 556, 556, 1416, 556, 1436, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1450, 1457, 580, 580, 580, 580, 580, 3069, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1510, 580, 580, 580, 580, 580, 580, 1518, 580, 580, 580, 580, 0, 1266, 1450, 1358, 534, 534, 1320, 534, 534, 556, 556, 556, 556, 556, 3354, 556, 556, 556, 556, 556, 556, 3360, 556, 556, 556, 556, 556, 556, 2615, 0, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2626, 580, 580, 580, 580, 580, 580, 556, 1412, 556, 556, 580, 580, 1504, 580, 580, 1066, 0, 0, 0, 0, 0, 0, 0, 1107, 0, 0, 0, 0, 0, 0, 0, 0, 658, 0, 0, 661, 0, 0, 0, 0, 1570, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1228, 1721, 1722, 534, 534, 534, 534, 1729, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 3177, 556, 556, 556, 3180, 556, 534, 1770, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1311, 534, 556, 556, 1824, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3204, 556, 556, 556, 1838, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3294, 556, 580, 1987, 580, 580, 534, 580, 556, 534, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 0, 0, 0, 0, 2694, 2029, 0, 2030, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2039, 0, 0, 0, 0, 0, 0, 1700, 0, 0, 0, 0, 0, 0, 0, 0, 0, 298, 0, 0, 0, 0, 0, 0, 534, 534, 2190, 534, 534, 534, 534, 534, 2195, 534, 534, 534, 534, 534, 534, 534, 1326, 534, 534, 534, 534, 534, 534, 534, 534, 1291, 534, 534, 534, 534, 534, 534, 534, 556, 2276, 556, 556, 556, 556, 556, 556, 2282, 556, 556, 556, 556, 556, 556, 556, 1810, 556, 556, 556, 556, 556, 556, 556, 556, 3188, 556, 556, 556, 556, 556, 556, 556, 580, 2363, 580, 580, 580, 580, 580, 580, 2369, 580, 580, 580, 580, 580, 580, 580, 2329, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3557, 0, 0, 0, 0, 534, 534, 580, 580, 2634, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1948, 580, 580, 0, 0, 0, 0, 2699, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 163840, 0, 0, 0, 534, 534, 534, 534, 534, 2778, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1779, 534, 534, 534, 534, 534, 534, 2809, 534, 534, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 2817, 556, 556, 556, 556, 556, 3465, 556, 3467, 556, 556, 3469, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3373, 580, 3375, 580, 556, 556, 556, 2858, 556, 556, 0, 0, 580, 580, 580, 580, 580, 580, 580, 580, 1445, 580, 580, 580, 1454, 580, 580, 580, 2866, 580, 580, 580, 580, 580, 580, 2874, 580, 580, 580, 580, 580, 580, 580, 580, 1473, 580, 580, 580, 580, 580, 580, 580, 534, 2996, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1767, 1768, 3036, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2275, 580, 3078, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1966, 580, 0, 0, 0, 0, 3130, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 167936, 0, 0, 0, 534, 534, 3174, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 1828, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 0, 580, 580, 580, 580, 580, 580, 0, 0, 0, 0, 3535, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2991, 534, 534, 534, 3542, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3550, 580, 580, 580, 580, 580, 3082, 580, 580, 3085, 580, 580, 580, 580, 580, 580, 580, 1911, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3072, 580, 580, 580, 580, 580, 580, 463, 463, 463, 447, 447, 463, 447, 447, 447, 447, 447, 447, 447, 447, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, 545, 568, 545, 568, 545, 545, 568, 545, 592, 568, 568, 568, 568, 568, 568, 568, 592, 592, 592, 545, 592, 592, 592, 592, 592, 592, 592, 568, 568, 545, 568, 592, 568, 592, 1, 12290, 0, 0, 0, 655, 0, 655, 0, 0, 0, 0, 0, 0, 0, 0, 655, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 556, 920, 556, 556, 934, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2841, 556, 556, 556, 556, 0, 0, 1160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1155, 0, 0, 0, 0, 0, 1177, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2461696, 0, 0, 0, 0, 0, 1232, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2801664, 0, 0, 534, 534, 534, 534, 1322, 534, 534, 534, 534, 534, 1329, 534, 534, 534, 534, 534, 534, 534, 2505, 534, 2507, 534, 534, 534, 534, 534, 534, 534, 1793, 534, 534, 534, 534, 1341, 0, 556, 556, 556, 556, 1359, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 965, 556, 556, 556, 556, 556, 1421, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 580, 580, 580, 1974, 1975, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2641, 580, 580, 580, 2644, 580, 556, 556, 1534, 556, 580, 580, 580, 1538, 580, 1066, 0, 1542, 0, 0, 0, 1548, 0, 0, 0, 1554, 0, 0, 0, 1560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2444, 0, 0, 0, 2448, 0, 0, 1599, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1569, 534, 534, 1723, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1734, 534, 534, 534, 534, 534, 534, 892, 534, 534, 534, 534, 556, 556, 556, 556, 556, 0, 0, 2298, 0, 0, 0, 580, 580, 580, 580, 580, 580, 3480, 580, 580, 580, 580, 580, 580, 0, 0, 0, 534, 3582, 534, 534, 534, 534, 556, 3586, 1754, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1316, 0, 2096, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2108, 0, 534, 534, 534, 534, 2154, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3006, 534, 534, 534, 556, 556, 556, 2239, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1864, 556, 556, 1867, 580, 580, 580, 2326, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1512, 580, 580, 580, 556, 556, 3194, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1414, 556, 556, 0, 0, 3328, 3132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 851, 534, 534, 534, 534, 534, 580, 580, 3379, 580, 580, 534, 556, 580, 0, 0, 0, 3384, 0, 0, 0, 0, 0, 0, 306, 204800, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 298, 0, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 534, 534, 534, 534, 3395, 534, 534, 534, 534, 534, 534, 534, 2156, 534, 2158, 534, 534, 534, 534, 534, 534, 534, 2170, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2546, 534, 534, 534, 534, 0, 2549, 387, 389, 339, 0, 0, 0, 0, 0, 0, 338, 0, 0, 339, 0, 0, 0, 0, 0, 0, 2023, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 359, 0, 0, 0, 0, 0, 0, 0, 0, 386, 0, 0, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 393, 394, 0, 395, 0, 0, 0, 0, 0, 395, 0, 0, 0, 0, 0, 1209, 0, 0, 0, 0, 1214, 0, 0, 0, 0, 0, 0, 0, 2405, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1094, 0, 0, 0, 0, 1099, 0, 0, 0, 338, 0, 0, 440, 0, 0, 464, 464, 464, 464, 464, 464, 464, 464, 546, 569, 546, 569, 546, 546, 569, 546, 475, 464, 464, 464, 493, 470, 493, 493, 493, 493, 493, 493, 493, 493, 464, 464, 470, 464, 464, 464, 464, 464, 464, 464, 464, 464, 464, 464, 474, 474, 464, 475, 464, 464, 464, 593, 569, 569, 569, 569, 569, 569, 569, 593, 593, 593, 546, 593, 593, 593, 593, 593, 593, 593, 569, 569, 546, 569, 593, 569, 593, 1, 12290, 0, 0, 0, 699, 0, 0, 0, 0, 0, 0, 0, 0, 708, 0, 710, 0, 0, 0, 0, 431, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1643, 0, 0, 0, 0, 743, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2411, 0, 0, 759, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 656, 0, 775, 0, 0, 0, 0, 0, 824, 0, 0, 0, 0, 0, 0, 779, 656, 0, 0, 796, 0, 0, 0, 0, 699, 0, 0, 0, 0, 0, 0, 799, 0, 0, 0, 0, 434, 0, 0, 331, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 461, 796, 779, 0, 0, 801, 0, 660, 0, 775, 0, 0, 0, 0, 0, 0, 0, 0, 2755, 0, 0, 0, 0, 0, 0, 0, 0, 2937, 0, 0, 0, 0, 0, 0, 0, 0, 2741, 0, 0, 0, 2745, 0, 2747, 0, 0, 0, 775, 801, 0, 801, 796, 0, 0, 0, 815, 0, 0, 0, 656, 818, 828, 0, 0, 0, 0, 534, 832, 534, 534, 534, 848, 534, 534, 862, 534, 534, 534, 534, 534, 534, 2504, 534, 534, 534, 534, 534, 534, 534, 534, 534, 898, 534, 556, 556, 556, 556, 556, 534, 534, 875, 534, 534, 534, 534, 893, 534, 534, 534, 556, 556, 904, 556, 556, 0, 580, 580, 976, 580, 580, 580, 580, 580, 580, 1007, 580, 580, 580, 580, 580, 1908, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1921, 556, 921, 556, 556, 935, 556, 556, 556, 556, 948, 556, 556, 556, 556, 966, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 0, 3594, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3156, 534, 534, 534, 534, 534, 534, 534, 2802, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1795, 534, 534, 1341, 1800, 556, 556, 580, 1022, 580, 580, 580, 580, 1040, 580, 580, 580, 0, 0, 0, 534, 580, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 3428, 580, 580, 580, 580, 580, 534, 556, 580, 3381, 0, 3383, 0, 0, 0, 0, 0, 0, 0, 2126, 0, 0, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1717, 534, 534, 0, 0, 1131, 0, 364, 364, 0, 1134, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2481, 0, 0, 0, 0, 0, 0, 0, 1174, 0, 0, 0, 0, 0, 0, 1091, 0, 0, 0, 0, 0, 0, 0, 0, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 111044, 1, 12290, 1093, 0, 0, 0, 0, 0, 0, 1197, 0, 0, 0, 0, 1202, 0, 0, 0, 0, 0, 0, 2033, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 131072, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 324, 0, 0, 0, 0, 1131, 0, 0, 1237, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2713, 0, 0, 0, 0, 0, 0, 1216, 0, 0, 0, 0, 1248, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 841, 534, 534, 534, 534, 534, 534, 534, 556, 556, 1360, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1382, 580, 580, 1497, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2334, 580, 580, 556, 1533, 556, 556, 580, 580, 1537, 580, 580, 1066, 0, 0, 0, 0, 0, 0, 0, 1121, 0, 0, 1124, 1125, 0, 0, 0, 0, 1584, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1614, 0, 0, 0, 1602, 0, 0, 1605, 0, 1607, 0, 0, 0, 0, 0, 0, 0, 0, 122880, 0, 122880, 122880, 122880, 122880, 122880, 0, 0, 1697, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2423, 0, 534, 1755, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2162, 534, 556, 1822, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3049, 556, 556, 556, 556, 2265, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3031, 556, 556, 556, 556, 0, 0, 0, 0, 2402, 0, 2404, 0, 0, 2407, 0, 0, 0, 0, 0, 0, 0, 1165, 0, 0, 0, 0, 0, 0, 0, 0, 0, 750, 0, 0, 0, 0, 0, 0, 2412, 0, 0, 0, 2415, 2416, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 106496, 0, 0, 0, 0, 0, 0, 0, 0, 2426, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2912256, 0, 3207168, 0, 0, 0, 0, 2440, 0, 2441, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2470, 0, 0, 0, 0, 0, 2461, 0, 0, 0, 0, 0, 0, 0, 0, 2469, 0, 0, 0, 0, 0, 2475, 0, 0, 0, 0, 2478, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2486, 0, 0, 0, 0, 435, 0, 0, 447, 463, 463, 463, 463, 463, 463, 463, 463, 463, 473, 463, 463, 463, 463, 463, 463, 534, 2500, 2501, 534, 534, 534, 534, 534, 2506, 534, 2508, 534, 534, 534, 534, 2512, 2525, 534, 534, 534, 534, 534, 534, 2533, 534, 534, 534, 534, 2537, 534, 534, 534, 534, 534, 534, 1262, 534, 534, 534, 534, 534, 534, 1277, 534, 534, 556, 556, 556, 2561, 556, 556, 2564, 2565, 556, 556, 556, 556, 556, 2570, 556, 2572, 556, 556, 556, 556, 2576, 556, 556, 556, 556, 556, 556, 556, 556, 2582, 556, 556, 0, 580, 580, 977, 580, 580, 580, 993, 580, 580, 580, 580, 580, 580, 1443, 580, 580, 580, 1447, 580, 580, 1458, 580, 580, 556, 556, 2602, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1833, 556, 556, 2685, 534, 534, 556, 2687, 556, 556, 580, 2689, 580, 580, 0, 0, 0, 0, 0, 0, 0, 2936, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2036, 0, 0, 0, 0, 0, 0, 0, 0, 2708, 0, 0, 0, 0, 0, 0, 0, 2714, 2715, 2716, 0, 0, 0, 0, 0, 0, 2060, 0, 0, 0, 0, 0, 2064, 0, 0, 2066, 0, 2735, 0, 2737, 0, 0, 0, 2740, 0, 0, 2743, 0, 0, 0, 0, 0, 0, 0, 2960, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2430, 0, 0, 0, 0, 0, 2435, 534, 534, 2810, 534, 0, 0, 2811, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2566, 556, 556, 556, 556, 556, 556, 556, 2856, 556, 556, 2859, 556, 0, 0, 2860, 580, 580, 580, 580, 580, 580, 580, 2651, 580, 580, 580, 580, 580, 580, 2658, 580, 580, 2892, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2321, 580, 2902, 580, 580, 2905, 580, 580, 2908, 580, 2909, 2910, 2911, 534, 534, 556, 556, 580, 580, 0, 0, 0, 0, 0, 3115, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 420, 0, 65536, 0, 2929, 2930, 0, 0, 0, 0, 2935, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2730, 0, 0, 0, 0, 0, 534, 534, 2997, 534, 2999, 534, 534, 534, 534, 534, 534, 3005, 534, 534, 3007, 534, 534, 534, 534, 534, 1324, 534, 534, 534, 534, 534, 534, 534, 534, 1335, 1336, 556, 3037, 556, 3039, 556, 556, 556, 556, 556, 556, 556, 3046, 556, 556, 3048, 556, 556, 556, 556, 580, 580, 580, 580, 580, 1066, 0, 0, 0, 0, 0, 0, 0, 377, 0, 380, 0, 0, 0, 380, 0, 0, 580, 580, 3079, 580, 3081, 580, 580, 580, 580, 580, 580, 580, 3088, 580, 580, 3090, 534, 534, 534, 534, 534, 3164, 534, 534, 534, 534, 534, 534, 534, 3169, 534, 534, 534, 534, 534, 534, 2779, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3167, 534, 534, 534, 534, 534, 3181, 3182, 556, 556, 556, 556, 3186, 3187, 556, 556, 556, 556, 556, 3191, 556, 556, 0, 580, 580, 978, 580, 580, 580, 995, 580, 580, 1009, 580, 580, 580, 580, 580, 2353, 2354, 580, 580, 580, 580, 580, 580, 2361, 580, 580, 556, 556, 556, 580, 580, 580, 580, 580, 580, 580, 3210, 3211, 580, 580, 580, 580, 580, 1442, 580, 580, 580, 580, 1448, 580, 580, 580, 580, 580, 580, 3524, 580, 3526, 580, 580, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 3215, 3216, 580, 580, 580, 580, 580, 3220, 580, 580, 580, 580, 580, 580, 580, 580, 1507, 580, 580, 580, 580, 580, 580, 580, 3226, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 2684, 556, 556, 556, 3288, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2258, 556, 556, 556, 3307, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2347, 2348, 3132, 0, 0, 0, 0, 534, 534, 3393, 534, 534, 534, 534, 3398, 534, 534, 534, 534, 534, 534, 1290, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1267, 534, 534, 534, 534, 534, 534, 534, 3403, 534, 534, 556, 556, 3408, 556, 556, 556, 556, 3413, 556, 556, 556, 556, 556, 556, 1874, 556, 556, 556, 556, 556, 1881, 556, 556, 556, 3418, 556, 556, 556, 580, 580, 3424, 580, 580, 580, 580, 3429, 580, 580, 580, 580, 580, 1468, 580, 580, 580, 580, 580, 580, 580, 1476, 580, 580, 3434, 580, 580, 580, 0, 0, 0, 0, 0, 3441, 0, 0, 0, 0, 534, 534, 534, 534, 3497, 534, 534, 534, 534, 534, 534, 534, 534, 1731, 534, 534, 534, 534, 1735, 534, 534, 534, 3563, 3564, 534, 534, 556, 556, 556, 3569, 3570, 556, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3212, 580, 580, 580, 3575, 3576, 580, 580, 580, 0, 0, 0, 534, 534, 534, 534, 534, 534, 556, 556, 0, 580, 580, 979, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2358, 580, 580, 580, 580, 580, 341, 342, 343, 344, 345, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 221184, 0, 0, 0, 0, 0, 0, 390, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 302, 0, 0, 0, 344, 344, 345, 344, 0, 343, 344, 448, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 465, 480, 489, 489, 497, 489, 499, 489, 489, 499, 499, 489, 499, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 514, 547, 570, 547, 570, 547, 547, 570, 547, 594, 570, 570, 570, 570, 570, 570, 570, 594, 594, 594, 547, 594, 594, 594, 594, 594, 594, 594, 570, 570, 547, 570, 594, 570, 594, 1, 12290, 650, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 665, 666, 0, 668, 669, 0, 0, 0, 0, 0, 675, 0, 0, 0, 0, 0, 0, 0, 1220, 1250, 1251, 0, 1220, 0, 534, 534, 534, 0, 0, 0, 685, 0, 0, 0, 0, 0, 0, 692, 364, 364, 364, 0, 0, 0, 0, 0, 687, 0, 0, 0, 0, 0, 364, 364, 364, 0, 0, 0, 0, 0, 734, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1691, 0, 0, 0, 0, 712, 0, 714, 0, 716, 0, 0, 0, 0, 0, 0, 0, 0, 0, 726, 0, 0, 0, 0, 436, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2138112, 0, 0, 0, 0, 0, 0, 639, 745, 746, 747, 0, 0, 0, 0, 0, 753, 754, 0, 0, 0, 0, 0, 748, 0, 0, 803, 0, 0, 0, 0, 0, 0, 0, 0, 1134592, 0, 0, 1134592, 0, 0, 0, 0, 0, 685, 0, 0, 665, 0, 685, 0, 797, 668, 716, 0, 685, 798, 0, 0, 0, 0, 0, 1090, 1091, 1092, 1093, 0, 0, 0, 0, 0, 0, 0, 0, 2948, 0, 0, 0, 0, 0, 2951, 0, 0, 0, 754, 0, 0, 0, 0, 0, 0, 0, 0, 747, 807, 808, 0, 0, 0, 0, 0, 1119, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3055616, 0, 0, 0, 3133440, 0, 0, 0, 0, 747, 0, 0, 812, 692, 0, 0, 0, 817, 0, 0, 0, 0, 0, 0, 2073, 0, 2075, 0, 0, 0, 0, 0, 0, 0, 0, 1702, 0, 0, 1703, 0, 0, 1704, 0, 819, 0, 0, 0, 685, 692, 0, 0, 685, 817, 817, 0, 0, 0, 0, 0, 0, 0, 3131, 0, 0, 0, 0, 0, 0, 0, 0, 749, 0, 0, 0, 0, 0, 0, 756, 870, 873, 534, 534, 534, 885, 889, 534, 534, 534, 534, 556, 556, 556, 911, 915, 918, 556, 926, 556, 556, 556, 941, 943, 946, 556, 556, 556, 958, 962, 556, 556, 0, 580, 580, 980, 986, 580, 580, 580, 580, 1004, 580, 580, 580, 580, 580, 1469, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2627, 580, 580, 2630, 2631, 580, 1020, 580, 580, 580, 1032, 1036, 580, 580, 580, 580, 0, 0, 0, 1048, 1049, 1050, 838, 534, 885, 889, 1055, 911, 556, 958, 962, 1060, 0, 985, 580, 1032, 1036, 1065, 1101, 0, 0, 0, 0, 1105, 0, 0, 1108, 0, 0, 0, 0, 0, 0, 0, 0, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 249856, 1, 12290, 1298, 534, 534, 1302, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1312, 534, 534, 534, 534, 534, 1727, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1796, 534, 1341, 0, 556, 556, 534, 1319, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1332, 534, 534, 534, 534, 534, 534, 1304, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1266, 1273, 534, 534, 534, 534, 534, 556, 1383, 556, 556, 556, 556, 556, 556, 556, 1390, 556, 556, 1394, 556, 556, 556, 556, 556, 1385, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2595, 556, 556, 556, 556, 556, 580, 580, 580, 1482, 580, 580, 1486, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1929, 580, 580, 580, 580, 580, 580, 580, 1496, 580, 580, 1503, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1516, 1615, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1655, 0, 0, 0, 1647, 0, 1649, 0, 0, 0, 1651, 0, 741, 0, 0, 0, 0, 0, 0, 330, 0, 0, 0, 0, 0, 0, 0, 330, 0, 0, 69632, 73728, 0, 418, 418, 0, 0, 65536, 418, 0, 0, 0, 534, 1709, 534, 534, 534, 534, 534, 534, 1715, 534, 534, 534, 534, 0, 0, 556, 2812, 556, 556, 556, 556, 556, 556, 556, 556, 3356, 556, 556, 556, 556, 556, 556, 556, 534, 534, 1787, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1341, 0, 556, 1803, 556, 556, 556, 556, 1839, 556, 556, 556, 1843, 556, 556, 1848, 556, 556, 556, 556, 556, 556, 1892, 556, 26009, 0, 580, 580, 580, 580, 580, 580, 0, 1269, 1453, 1361, 534, 534, 534, 534, 534, 556, 580, 580, 580, 1906, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1917, 580, 580, 580, 1935, 580, 580, 580, 1939, 580, 580, 1944, 580, 580, 580, 580, 580, 580, 580, 580, 1945, 580, 580, 580, 580, 580, 580, 580, 0, 0, 2010, 0, 1077, 0, 0, 0, 2012, 0, 1081, 0, 0, 0, 0, 0, 0, 0, 3144, 0, 0, 0, 0, 0, 0, 3147, 0, 534, 534, 534, 2177, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1341, 1800, 556, 556, 556, 556, 2263, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1850, 556, 556, 580, 580, 2350, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2346, 580, 580, 0, 2550, 0, 1800, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2569, 556, 2571, 556, 556, 2613, 556, 556, 556, 0, 0, 0, 2616, 0, 1896, 580, 580, 580, 580, 580, 580, 3219, 580, 580, 580, 580, 580, 580, 580, 580, 3225, 0, 0, 2761, 0, 0, 0, 534, 2765, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3166, 534, 534, 534, 534, 534, 3171, 534, 534, 2789, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1295, 534, 534, 556, 556, 2836, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1865, 556, 556, 534, 534, 2985, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1310, 534, 534, 534, 534, 534, 2998, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1341, 1801, 556, 556, 556, 3025, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3205, 556, 556, 3038, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2247, 556, 556, 580, 580, 3067, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2643, 580, 580, 580, 580, 580, 3080, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2345, 580, 580, 580, 534, 534, 534, 534, 534, 3267, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2159, 534, 534, 534, 534, 2163, 3285, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2289, 3336, 534, 534, 534, 534, 3340, 534, 534, 534, 534, 534, 3346, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 580, 1066, 0, 0, 0, 1545, 0, 0, 0, 0, 0, 1620, 0, 0, 1623, 0, 1625, 0, 0, 0, 0, 0, 0, 0, 2480, 0, 0, 0, 0, 0, 0, 0, 0, 555, 578, 555, 578, 555, 555, 578, 555, 556, 556, 3351, 556, 556, 556, 556, 3355, 556, 556, 556, 556, 556, 3361, 556, 556, 0, 580, 580, 981, 580, 580, 580, 580, 580, 580, 1010, 1012, 580, 580, 580, 580, 1029, 580, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 3377, 580, 580, 580, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3251, 0, 3132, 3253, 0, 0, 3256, 3132, 0, 0, 0, 0, 534, 534, 534, 534, 534, 3396, 534, 534, 534, 3400, 534, 534, 534, 534, 534, 1742, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2536, 534, 534, 534, 534, 534, 388, 0, 0, 0, 392, 388, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 233472, 0, 0, 0, 0, 0, 0, 0, 404, 0, 346, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 437, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 636, 0, 0, 0, 0, 515, 515, 515, 515, 0, 0, 0, 0, 0, 0, 0, 0, 0, 515, 515, 515, 515, 515, 515, 515, 515, 548, 571, 548, 571, 548, 548, 571, 548, 595, 571, 571, 571, 571, 571, 571, 571, 595, 595, 595, 548, 595, 595, 595, 595, 595, 595, 595, 571, 571, 610, 615, 595, 615, 621, 1, 12290, 0, 0, 744, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1668, 534, 534, 876, 534, 534, 534, 534, 894, 534, 534, 534, 556, 556, 905, 556, 556, 0, 580, 580, 982, 580, 580, 580, 580, 1001, 1005, 1011, 580, 1016, 580, 580, 1023, 580, 580, 580, 580, 1041, 580, 580, 580, 0, 0, 0, 534, 580, 556, 556, 556, 556, 580, 580, 580, 580, 580, 1066, 0, 0, 1544, 0, 0, 0, 0, 0, 0, 2764, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1268, 534, 534, 534, 534, 534, 534, 0, 0, 0, 0, 1162, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1173, 0, 0, 0, 1178, 0, 0, 0, 0, 1094, 0, 0, 0, 0, 0, 0, 0, 0, 274432, 274432, 274432, 0, 274432, 274432, 274432, 274432, 1256, 534, 534, 534, 534, 534, 534, 534, 534, 1269, 534, 534, 534, 534, 1279, 534, 534, 534, 534, 534, 1757, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2197, 534, 534, 534, 534, 534, 534, 534, 534, 1341, 901, 556, 556, 556, 1347, 556, 556, 556, 556, 556, 556, 556, 1877, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 0, 580, 1899, 580, 580, 580, 580, 556, 556, 1361, 556, 556, 556, 556, 1371, 556, 556, 556, 556, 556, 556, 556, 556, 3468, 556, 556, 3470, 556, 580, 580, 580, 556, 556, 556, 556, 1422, 556, 556, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 580, 580, 580, 1990, 1991, 1992, 534, 1994, 534, 534, 556, 1998, 556, 556, 580, 580, 580, 3367, 580, 580, 580, 580, 3371, 580, 580, 580, 580, 580, 580, 3232, 580, 580, 580, 580, 580, 580, 534, 580, 556, 2384, 534, 534, 534, 2388, 556, 556, 556, 580, 580, 1439, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1453, 580, 580, 580, 580, 580, 2381, 2382, 2383, 534, 534, 534, 534, 556, 556, 556, 556, 3410, 556, 556, 556, 556, 556, 556, 556, 580, 1463, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1477, 580, 580, 1498, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1514, 580, 580, 580, 580, 2005, 0, 2007, 0, 2009, 0, 2011, 0, 0, 0, 0, 0, 0, 0, 2034, 2035, 0, 2037, 2038, 0, 0, 0, 0, 0, 0, 0, 1555, 0, 0, 0, 1561, 0, 0, 0, 0, 0, 0, 0, 0, 0, 286720, 286720, 0, 286720, 286720, 1, 12290, 0, 0, 0, 1586, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 303, 0, 0, 0, 0, 1600, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2434, 0, 556, 1852, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3363, 0, 1556, 0, 0, 0, 0, 0, 1562, 0, 0, 0, 0, 0, 0, 0, 0, 305, 204800, 204800, 0, 205105, 204800, 1, 12290, 0, 0, 0, 2070, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 337, 0, 0, 0, 0, 0, 2111, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1188, 0, 0, 534, 2165, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2173, 534, 2250, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2584, 2337, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2375, 580, 2211, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2597, 556, 556, 556, 556, 556, 556, 2588, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2831, 556, 556, 556, 534, 3107, 556, 3109, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2138112, 1170, 0, 0, 0, 0, 0, 3132, 3330, 0, 0, 3332, 0, 0, 0, 0, 0, 534, 3335, 534, 534, 534, 534, 534, 1774, 534, 534, 534, 1778, 534, 534, 534, 534, 534, 534, 534, 1776, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2535, 534, 534, 534, 534, 534, 534, 534, 3337, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 556, 3350, 556, 556, 3352, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2852, 556, 556, 556, 556, 556, 580, 3366, 580, 580, 3368, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1946, 580, 580, 580, 580, 580, 580, 3132, 0, 3388, 0, 3390, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 902, 556, 556, 0, 0, 0, 783, 0, 783, 0, 0, 0, 0, 0, 0, 0, 0, 783, 0, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 2557, 556, 556, 556, 556, 556, 556, 2848, 556, 556, 556, 556, 556, 556, 556, 556, 556, 947, 556, 556, 556, 556, 556, 556, 556, 922, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1381, 556, 556, 972, 0, 580, 580, 580, 580, 580, 580, 996, 580, 580, 580, 580, 580, 580, 1910, 580, 580, 580, 580, 1916, 580, 580, 580, 580, 78114, 1066, 0, 0, 1070, 1074, 0, 0, 1078, 1082, 0, 0, 0, 0, 0, 0, 0, 1222, 0, 0, 0, 0, 1225, 0, 1181, 0, 534, 3162, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2201, 534, 580, 580, 580, 3218, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2629, 580, 580, 580, 347, 347, 349, 347, 0, 0, 347, 347, 0, 0, 0, 0, 348, 0, 0, 0, 0, 0, 0, 2125, 0, 0, 2128, 0, 534, 534, 2131, 534, 534, 0, 0, 0, 347, 347, 349, 347, 347, 347, 347, 347, 347, 506, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 347, 549, 572, 549, 572, 549, 549, 572, 549, 596, 572, 572, 572, 572, 572, 572, 572, 596, 596, 596, 549, 596, 596, 596, 596, 596, 596, 596, 572, 572, 549, 572, 596, 572, 596, 1, 12290, 0, 0, 0, 715, 0, 717, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1147348, 0, 0, 0, 0, 0, 0, 0, 732, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 353, 354, 355, 356, 758, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 673, 674, 0, 0, 0, 0, 0, 0, 0, 794, 795, 0, 0, 0, 0, 795, 0, 0, 0, 0, 0, 795, 0, 0, 794, 809, 0, 803, 0, 657, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3117056, 0, 0, 0, 0, 820, 0, 0, 0, 0, 0, 0, 795, 0, 0, 0, 0, 0, 0, 0, 0, 1159168, 364, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 795, 534, 534, 839, 534, 534, 534, 534, 857, 534, 534, 534, 534, 534, 534, 1728, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3272, 534, 534, 534, 3273, 3274, 534, 534, 877, 879, 534, 534, 890, 534, 534, 534, 534, 556, 556, 906, 912, 556, 556, 556, 556, 580, 580, 580, 580, 580, 1066, 0, 1543, 0, 0, 0, 1549, 556, 556, 556, 930, 556, 556, 556, 556, 556, 950, 952, 556, 556, 963, 556, 556, 556, 556, 556, 1840, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1831, 556, 556, 556, 556, 1835, 580, 1024, 1026, 580, 580, 1037, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 556, 556, 556, 580, 580, 580, 580, 580, 1066, 1540, 0, 0, 0, 1546, 0, 0, 0, 0, 0, 131072, 0, 131072, 131072, 131072, 131072, 0, 131072, 131072, 131072, 131072, 131072, 131072, 0, 0, 0, 0, 0, 131072, 0, 131072, 1, 12290, 839, 879, 534, 890, 534, 912, 952, 556, 963, 556, 0, 986, 1026, 580, 1037, 580, 580, 580, 580, 2005, 0, 2007, 0, 2009, 0, 2011, 0, 0, 2397, 0, 0, 0, 0, 0, 330, 331, 332, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2083, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2731, 0, 0, 0, 0, 0, 0, 1132, 364, 364, 0, 0, 1135, 0, 0, 0, 1138, 0, 1140, 0, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 2556, 556, 556, 556, 556, 556, 556, 2577, 556, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 1897, 580, 580, 580, 580, 580, 580, 1142, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1156, 0, 0, 0, 0, 556, 556, 556, 556, 556, 556, 2555, 556, 556, 556, 556, 2559, 1158, 0, 0, 0, 0, 1163, 0, 0, 0, 0, 1168, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 0, 1247, 0, 0, 0, 0, 0, 0, 0, 1168, 534, 534, 534, 534, 534, 534, 1743, 534, 534, 534, 534, 534, 534, 534, 534, 534, 897, 534, 556, 556, 556, 556, 914, 534, 534, 534, 1286, 1288, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 907, 556, 556, 534, 534, 534, 1341, 901, 556, 556, 556, 556, 1348, 556, 556, 556, 556, 556, 556, 0, 2298, 580, 580, 580, 580, 580, 580, 580, 580, 2640, 580, 580, 580, 580, 580, 580, 2645, 580, 580, 580, 1440, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2670, 2671, 580, 580, 1494, 580, 580, 580, 580, 580, 580, 580, 1508, 580, 580, 580, 580, 580, 580, 580, 2678, 580, 580, 580, 580, 534, 580, 556, 534, 534, 534, 1996, 556, 556, 556, 2000, 580, 580, 1519, 1520, 580, 580, 580, 0, 534, 580, 556, 534, 1528, 534, 534, 1531, 556, 556, 556, 556, 580, 580, 580, 580, 580, 1066, 1541, 0, 0, 0, 1547, 0, 0, 0, 0, 556, 556, 556, 2553, 556, 2554, 556, 556, 556, 556, 556, 556, 0, 0, 580, 580, 580, 580, 2863, 580, 580, 580, 1532, 556, 556, 1535, 580, 1536, 580, 580, 1539, 1066, 0, 0, 0, 0, 0, 0, 0, 1577, 0, 0, 0, 0, 0, 0, 0, 0, 0, 770, 0, 0, 0, 0, 0, 0, 0, 0, 1617, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1203, 0, 0, 0, 0, 1633, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1217, 0, 0, 0, 0, 0, 0, 1658, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 364, 364, 0, 0, 0, 0, 1698, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1226, 0, 0, 534, 1738, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2207, 2549, 534, 534, 534, 1788, 534, 534, 534, 534, 1794, 534, 534, 534, 1341, 0, 556, 556, 556, 556, 556, 1891, 556, 556, 26009, 1896, 580, 580, 580, 580, 580, 580, 1470, 1472, 580, 580, 580, 580, 580, 580, 580, 580, 1960, 580, 580, 1963, 580, 580, 580, 580, 556, 556, 1870, 556, 556, 556, 1875, 556, 556, 556, 556, 556, 556, 556, 556, 1884, 556, 556, 556, 556, 1890, 556, 556, 556, 26009, 0, 580, 580, 580, 580, 580, 580, 1927, 580, 580, 580, 580, 1931, 580, 580, 580, 580, 580, 1904, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2672, 580, 580, 580, 1971, 580, 580, 580, 580, 580, 580, 580, 580, 1980, 580, 580, 580, 580, 580, 1504, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2316, 580, 580, 2320, 580, 580, 1986, 580, 580, 580, 534, 580, 556, 534, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 0, 0, 0, 2693, 0, 0, 0, 0, 0, 2099, 0, 2101, 2102, 2103, 0, 2105, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 0, 424, 65536, 0, 0, 0, 0, 2123, 0, 0, 0, 0, 0, 0, 0, 2129, 534, 534, 534, 534, 0, 2211, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3045, 556, 556, 556, 556, 556, 534, 534, 2136, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1333, 534, 534, 534, 534, 534, 2166, 534, 2168, 534, 2171, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3271, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2178, 534, 534, 534, 534, 534, 2184, 534, 534, 534, 534, 534, 534, 534, 2792, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2519, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2206, 0, 0, 0, 0, 2213, 556, 556, 556, 556, 556, 556, 939, 556, 944, 556, 951, 556, 954, 556, 556, 968, 556, 2221, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1415, 556, 556, 556, 2251, 556, 2253, 556, 2256, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2607, 556, 556, 556, 2610, 556, 556, 556, 556, 556, 2264, 556, 556, 556, 556, 556, 2270, 556, 556, 556, 556, 556, 556, 1369, 556, 556, 556, 1374, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2293, 0, 0, 0, 0, 2300, 580, 580, 580, 580, 580, 580, 1942, 580, 580, 580, 1947, 580, 580, 580, 580, 580, 580, 2308, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2880, 580, 580, 580, 2338, 580, 2340, 580, 2343, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1961, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2351, 580, 580, 580, 580, 580, 2357, 580, 580, 580, 580, 580, 580, 1958, 1959, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3234, 580, 580, 580, 534, 580, 556, 0, 0, 2400, 2401, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 399, 0, 0, 0, 2436, 0, 0, 2439, 0, 0, 0, 0, 2443, 0, 0, 0, 0, 0, 0, 0, 0, 2818048, 2846720, 0, 2916352, 0, 0, 3002368, 0, 0, 0, 2451, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2459, 0, 0, 0, 0, 556, 556, 2552, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2851, 556, 556, 556, 556, 556, 556, 0, 0, 0, 2477, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2485, 0, 0, 0, 0, 0, 1195, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 111044, 0, 0, 0, 0, 534, 534, 534, 534, 534, 2503, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2520, 534, 534, 534, 534, 534, 556, 556, 556, 556, 2562, 556, 556, 556, 556, 556, 2567, 556, 556, 556, 556, 556, 0, 0, 0, 0, 580, 580, 580, 580, 2304, 580, 580, 580, 2633, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2901, 580, 534, 534, 534, 2686, 556, 556, 556, 2688, 580, 580, 580, 2690, 2691, 0, 0, 0, 0, 0, 0, 2453, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1185, 0, 0, 0, 0, 0, 0, 0, 0, 2709, 0, 2710, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1159168, 0, 0, 0, 0, 2855, 556, 556, 556, 556, 556, 0, 0, 580, 580, 580, 580, 580, 2864, 580, 2865, 580, 580, 2904, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 556, 556, 580, 580, 0, 0, 0, 3113, 0, 0, 0, 0, 0, 0, 0, 0, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 254407, 1, 12290, 556, 556, 556, 3053, 556, 556, 556, 556, 556, 556, 556, 580, 3061, 580, 580, 580, 580, 580, 2649, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2371, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3095, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 2386, 2387, 556, 556, 2390, 2391, 534, 534, 3338, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3347, 534, 534, 3349, 556, 556, 556, 556, 3353, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3362, 556, 556, 556, 556, 580, 580, 580, 580, 580, 3427, 580, 580, 580, 3431, 580, 580, 580, 580, 1031, 580, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 556, 556, 3365, 580, 580, 580, 580, 3369, 580, 580, 580, 580, 580, 580, 580, 580, 2356, 580, 580, 580, 580, 580, 580, 580, 580, 3378, 580, 580, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 0, 402, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 3449, 534, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 3179, 556, 556, 556, 556, 556, 3462, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 3300, 580, 580, 580, 3303, 580, 580, 580, 580, 580, 3476, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 0, 0, 3491, 0, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3158, 534, 534, 534, 534, 534, 3565, 534, 556, 556, 556, 556, 556, 3571, 556, 556, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3372, 580, 580, 580, 580, 580, 580, 3577, 580, 580, 3579, 0, 3581, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 2224, 556, 556, 2227, 556, 556, 556, 556, 556, 556, 2235, 400, 0, 0, 0, 0, 0, 367, 375, 403, 0, 0, 0, 0, 0, 367, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2054, 408, 410, 0, 0, 367, 375, 0, 69632, 73728, 0, 0, 0, 0, 426, 65536, 0, 0, 0, 0, 556, 2551, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2271, 556, 556, 556, 556, 556, 426, 426, 0, 426, 0, 410, 426, 449, 0, 0, 0, 0, 0, 0, 0, 0, 534, 556, 534, 556, 534, 534, 556, 534, 367, 0, 0, 395, 0, 0, 0, 0, 0, 350, 0, 0, 367, 0, 0, 395, 0, 408, 0, 490, 490, 0, 490, 490, 490, 490, 490, 490, 490, 490, 516, 516, 516, 516, 449, 449, 449, 449, 524, 449, 449, 525, 449, 516, 530, 516, 516, 516, 530, 516, 516, 516, 516, 532, 550, 573, 550, 573, 550, 550, 573, 550, 597, 573, 573, 573, 573, 573, 573, 573, 597, 597, 597, 550, 597, 597, 597, 597, 597, 597, 597, 573, 573, 611, 616, 597, 616, 622, 1, 12290, 0, 0, 636, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1567, 1568, 0, 789, 0, 0, 0, 0, 534, 834, 534, 534, 534, 534, 534, 534, 863, 865, 534, 534, 534, 534, 534, 1790, 1792, 534, 534, 534, 534, 534, 1341, 0, 556, 556, 0, 580, 580, 580, 983, 987, 580, 580, 580, 580, 580, 580, 1013, 580, 556, 556, 556, 556, 936, 938, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2829, 556, 556, 2832, 556, 556, 78114, 1066, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1083, 0, 0, 0, 0, 0, 1234, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2050, 0, 0, 0, 0, 1085, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1098, 0, 0, 0, 0, 0, 1235, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 122880, 0, 0, 0, 0, 0, 0, 1116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1581, 1582, 0, 0, 0, 0, 1085, 1208, 0, 0, 0, 0, 0, 0, 1215, 0, 0, 0, 0, 0, 0, 347, 348, 349, 0, 0, 0, 0, 0, 0, 0, 0, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 282624, 0, 0, 0, 1220, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1220, 1229, 534, 534, 534, 1259, 534, 534, 534, 1263, 534, 534, 1274, 534, 534, 1278, 534, 534, 534, 534, 534, 534, 3001, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1327, 534, 534, 534, 534, 534, 534, 534, 1299, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2497, 534, 534, 534, 534, 1341, 901, 556, 556, 556, 556, 556, 556, 556, 1351, 556, 556, 556, 556, 556, 1423, 556, 556, 556, 1430, 556, 556, 26009, 1341, 975, 580, 1355, 556, 556, 1366, 556, 556, 1370, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2828, 556, 556, 556, 556, 556, 556, 1462, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3315, 580, 1479, 580, 580, 580, 1483, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2877, 580, 580, 580, 580, 0, 1571, 1572, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1612, 0, 0, 0, 0, 0, 0, 1603, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 364, 364, 0, 696, 0, 1616, 0, 1618, 0, 0, 0, 1622, 0, 0, 0, 1626, 0, 0, 0, 1630, 0, 0, 0, 0, 1572, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 364, 364, 695, 0, 534, 534, 534, 1724, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1782, 1783, 534, 534, 556, 1837, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1818, 556, 556, 556, 556, 1889, 556, 556, 556, 556, 26009, 0, 580, 580, 580, 580, 580, 580, 1976, 580, 580, 580, 580, 580, 1981, 580, 580, 580, 0, 0, 0, 2031, 0, 2032, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2200246, 151552, 2200246, 0, 0, 2175, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2186, 534, 534, 534, 534, 534, 534, 1758, 534, 534, 534, 534, 1764, 534, 534, 534, 534, 0, 0, 556, 556, 556, 556, 2814, 556, 556, 556, 556, 556, 0, 0, 0, 0, 580, 2301, 580, 580, 580, 580, 580, 1038, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 580, 580, 2394, 2395, 0, 1544, 0, 1550, 0, 1556, 0, 1562, 0, 0, 0, 0, 0, 0, 374, 0, 0, 0, 0, 0, 0, 0, 359, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2052, 0, 0, 2476, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2482, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 345, 344, 65536, 343, 534, 534, 534, 534, 2530, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1275, 534, 534, 534, 534, 580, 2661, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3075, 580, 580, 0, 0, 2722, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1665, 0, 0, 534, 2797, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2511, 534, 556, 556, 2845, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2259, 556, 556, 0, 0, 2970, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 534, 855, 534, 534, 534, 534, 0, 0, 0, 0, 3122, 3123, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2424832, 2433024, 0, 0, 2457600, 3149, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1737, 3172, 534, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 2242, 556, 556, 556, 556, 556, 556, 556, 556, 1406, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 3229, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 556, 556, 556, 580, 580, 580, 580, 3426, 580, 580, 580, 580, 580, 580, 580, 2639, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2344, 580, 580, 580, 580, 580, 580, 534, 3236, 556, 3238, 580, 3240, 3241, 0, 0, 0, 0, 3245, 0, 0, 0, 0, 0, 0, 640, 0, 0, 0, 0, 0, 0, 0, 0, 0, 323, 397, 0, 0, 0, 323, 0, 0, 0, 3258, 0, 0, 0, 0, 0, 0, 0, 0, 3261, 0, 534, 534, 534, 534, 534, 534, 534, 3154, 3155, 534, 534, 534, 534, 3159, 3160, 3263, 534, 534, 534, 3266, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1330, 534, 534, 534, 534, 580, 580, 3318, 534, 3319, 556, 3320, 580, 0, 0, 0, 0, 0, 0, 0, 0, 543, 566, 543, 566, 543, 543, 566, 543, 556, 556, 3543, 556, 3544, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 3551, 580, 3552, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 0, 0, 534, 534, 3536, 534, 3537, 534, 534, 534, 534, 534, 534, 534, 1730, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2183, 534, 534, 534, 534, 534, 534, 409, 355, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 0, 0, 65536, 0, 0, 0, 0, 638, 0, 0, 641, 642, 0, 0, 0, 0, 0, 0, 0, 0, 1591, 0, 0, 1594, 0, 0, 0, 0, 466, 477, 466, 0, 0, 466, 0, 0, 0, 0, 0, 0, 0, 0, 517, 517, 521, 521, 521, 521, 466, 466, 466, 466, 466, 466, 466, 471, 466, 521, 517, 521, 521, 517, 521, 521, 521, 521, 533, 551, 574, 551, 574, 551, 551, 574, 551, 598, 574, 574, 574, 574, 574, 574, 574, 598, 598, 598, 551, 598, 598, 598, 598, 598, 598, 598, 574, 574, 612, 617, 598, 617, 623, 1, 12290, 0, 0, 731, 0, 0, 0, 637, 731, 0, 737, 738, 637, 0, 0, 0, 0, 0, 0, 656, 0, 0, 659, 660, 0, 0, 0, 0, 0, 0, 0, 2754, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2420, 0, 0, 0, 0, 0, 0, 777, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 786, 0, 791, 0, 0, 0, 0, 0, 1575, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 303, 303, 0, 0, 0, 0, 0, 0, 0, 0, 791, 0, 0, 0, 0, 0, 0, 791, 0, 0, 0, 0, 0, 0, 672, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2016, 0, 0, 0, 0, 806, 0, 0, 0, 0, 0, 637, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 349, 347, 65536, 0, 0, 0, 0, 777, 0, 0, 0, 0, 0, 0, 0, 777, 777, 0, 637, 0, 0, 0, 786, 0, 791, 0, 777, 0, 806, 0, 0, 0, 658, 0, 777, 791, 829, 0, 534, 835, 534, 534, 534, 534, 854, 858, 864, 534, 869, 556, 556, 927, 931, 937, 556, 942, 556, 556, 556, 556, 556, 959, 556, 556, 556, 556, 556, 1424, 556, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 534, 534, 886, 534, 534, 556, 556, 959, 556, 556, 0, 580, 580, 1033, 580, 580, 580, 580, 1033, 580, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 0, 1086, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2449, 0, 0, 0, 0, 1103, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1113, 0, 0, 0, 1117, 1118, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 364, 364, 208896, 0, 0, 0, 0, 0, 0, 1179, 0, 1182, 0, 0, 0, 0, 0, 1187, 0, 0, 0, 0, 0, 0, 2726, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 784, 0, 0, 0, 0, 0, 0, 0, 0, 1205, 0, 0, 1086, 0, 0, 0, 1211, 0, 1213, 0, 0, 0, 0, 0, 0, 0, 1638, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1123, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1221, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1227, 0, 0, 0, 0, 654, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2964, 2965, 0, 0, 1230, 1187, 0, 1211, 1233, 0, 1236, 0, 0, 0, 0, 0, 1117, 0, 0, 0, 0, 0, 0, 2739, 0, 0, 0, 0, 2744, 0, 0, 0, 0, 0, 0, 299, 0, 0, 0, 303, 2424832, 2433024, 0, 0, 2457600, 0, 1245, 0, 0, 0, 0, 0, 1245, 0, 0, 1136, 1245, 0, 1252, 534, 534, 534, 534, 534, 534, 3279, 534, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3514, 556, 556, 556, 580, 534, 534, 1258, 534, 534, 534, 534, 1264, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3455, 534, 534, 3457, 556, 556, 556, 534, 534, 1285, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1296, 534, 534, 534, 534, 534, 534, 3341, 534, 534, 534, 534, 534, 534, 534, 534, 556, 580, 3607, 3608, 3609, 534, 556, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 333, 0, 0, 333, 0, 0, 333, 0, 0, 0, 534, 534, 1301, 534, 534, 534, 534, 534, 534, 534, 534, 1308, 534, 534, 534, 1315, 1317, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2149, 534, 1339, 534, 1341, 901, 1343, 556, 556, 556, 556, 556, 1350, 556, 556, 556, 556, 556, 556, 2225, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2244, 556, 556, 556, 556, 2248, 556, 1356, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1377, 556, 556, 556, 556, 556, 556, 2241, 556, 2243, 556, 556, 556, 556, 556, 556, 556, 1425, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 556, 556, 556, 556, 1400, 556, 556, 556, 1407, 1409, 556, 556, 556, 556, 556, 556, 1386, 556, 556, 556, 556, 556, 556, 556, 1395, 556, 1480, 580, 580, 580, 580, 1485, 580, 580, 580, 580, 580, 580, 580, 580, 1492, 580, 580, 580, 580, 2352, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2628, 580, 580, 580, 580, 580, 580, 1499, 1501, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2878, 580, 580, 2881, 1550, 0, 0, 0, 1556, 0, 0, 0, 1562, 0, 0, 0, 0, 0, 0, 0, 0, 2957312, 0, 0, 0, 0, 0, 0, 0, 0, 1150, 0, 0, 0, 0, 0, 0, 0, 0, 1166, 0, 0, 0, 0, 0, 0, 0, 0, 1179, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2094, 0, 0, 0, 1573, 1574, 0, 0, 0, 0, 0, 1580, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 0, 0, 373, 0, 65536, 0, 0, 0, 1601, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1677, 0, 0, 0, 0, 0, 0, 1619, 0, 0, 0, 0, 0, 0, 0, 1627, 1628, 0, 0, 0, 0, 0, 1604, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 254407, 0, 0, 0, 0, 0, 0, 0, 0, 1635, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 382, 0, 0, 0, 386, 0, 0, 0, 1685, 0, 0, 0, 0, 0, 1689, 0, 0, 1692, 0, 0, 0, 0, 0, 0, 3143, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2756, 0, 0, 2759, 0, 0, 0, 0, 0, 0, 1689, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1705, 0, 1707, 1681, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1719, 534, 534, 534, 534, 534, 1791, 534, 534, 534, 534, 534, 534, 1341, 0, 556, 556, 556, 556, 556, 2295, 0, 0, 0, 580, 580, 580, 580, 580, 580, 580, 2666, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1446, 580, 580, 580, 580, 580, 580, 534, 534, 534, 1725, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1736, 534, 534, 534, 534, 534, 2179, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2143, 534, 2145, 534, 534, 534, 534, 534, 534, 1740, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1751, 534, 534, 534, 534, 534, 2207, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 1403, 556, 556, 556, 556, 556, 556, 556, 556, 1408, 556, 556, 556, 556, 556, 556, 556, 534, 534, 1756, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2172, 534, 534, 2002, 580, 580, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 696, 0, 0, 2019, 2020, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 662, 0, 0, 0, 2055, 2056, 0, 0, 2058, 2059, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2617344, 0, 0, 0, 0, 2081, 0, 0, 0, 0, 2084, 2085, 0, 0, 0, 0, 0, 2091, 0, 0, 0, 0, 0, 0, 3259, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 534, 849, 534, 534, 534, 534, 534, 534, 534, 2152, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2161, 534, 534, 534, 534, 534, 534, 3452, 534, 3454, 534, 534, 3456, 534, 556, 556, 556, 556, 3509, 556, 556, 556, 556, 556, 556, 556, 556, 556, 580, 580, 580, 580, 580, 580, 0, 0, 0, 3595, 534, 534, 2164, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2174, 534, 534, 534, 2191, 534, 534, 534, 2194, 534, 534, 534, 534, 2199, 534, 534, 534, 534, 534, 534, 1759, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1732, 534, 534, 534, 534, 534, 534, 556, 2237, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2246, 556, 556, 2249, 556, 556, 2277, 556, 556, 556, 556, 2281, 556, 556, 556, 556, 2286, 556, 556, 556, 556, 556, 1808, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2608, 556, 556, 556, 556, 556, 580, 2324, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2333, 580, 580, 2336, 580, 580, 2364, 580, 580, 580, 580, 2368, 580, 580, 580, 580, 2373, 580, 580, 580, 580, 580, 2665, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1979, 580, 580, 580, 580, 580, 2398, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2408, 0, 0, 0, 0, 0, 0, 687, 0, 0, 0, 770, 0, 0, 0, 0, 789, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 176128, 534, 534, 2488, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2496, 534, 534, 534, 534, 534, 882, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 3411, 556, 556, 556, 3415, 556, 556, 534, 534, 2514, 534, 534, 2516, 534, 2517, 534, 534, 534, 534, 534, 534, 534, 2524, 534, 534, 2528, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2539, 556, 556, 2560, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3472, 580, 580, 556, 556, 556, 2575, 556, 556, 556, 2578, 556, 556, 2580, 556, 2581, 556, 556, 556, 556, 556, 1827, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1814, 556, 556, 556, 556, 1820, 580, 2646, 580, 2647, 580, 580, 580, 580, 580, 580, 580, 580, 2655, 580, 580, 2659, 0, 2696, 2697, 0, 0, 2700, 2701, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3178496, 2670592, 0, 2744320, 0, 0, 2772, 534, 2775, 534, 534, 534, 534, 2780, 534, 534, 534, 2783, 534, 534, 534, 534, 534, 534, 534, 3002, 3003, 534, 534, 534, 534, 534, 534, 534, 534, 2494, 534, 534, 534, 534, 534, 534, 534, 534, 1744, 534, 534, 534, 1748, 534, 534, 1753, 2808, 534, 534, 534, 0, 0, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3358, 556, 556, 556, 556, 556, 2819, 556, 2822, 556, 556, 556, 556, 2827, 556, 556, 556, 2830, 556, 556, 556, 556, 556, 556, 2255, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2228, 556, 2230, 556, 556, 556, 556, 556, 556, 2857, 556, 556, 556, 0, 0, 580, 580, 580, 580, 580, 580, 580, 580, 2652, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2868, 580, 2871, 580, 580, 580, 580, 2876, 580, 580, 580, 2879, 580, 580, 580, 580, 1034, 580, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 580, 580, 580, 580, 2906, 580, 580, 580, 534, 580, 556, 534, 534, 556, 556, 580, 580, 0, 0, 3112, 0, 3114, 0, 0, 0, 3118, 0, 0, 534, 534, 534, 534, 3013, 534, 534, 534, 534, 534, 556, 556, 556, 3021, 556, 556, 556, 556, 556, 2266, 2267, 556, 556, 556, 556, 556, 556, 2274, 556, 556, 0, 580, 580, 580, 580, 580, 580, 994, 580, 580, 1008, 580, 580, 580, 580, 580, 2341, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 0, 0, 733, 534, 580, 556, 0, 0, 3121, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1693, 0, 0, 534, 3173, 534, 534, 534, 534, 534, 534, 534, 556, 556, 556, 556, 556, 556, 556, 2839, 556, 556, 556, 556, 556, 556, 556, 556, 1811, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3183, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3033, 556, 556, 556, 556, 3193, 556, 556, 556, 556, 556, 556, 3199, 556, 3201, 556, 556, 556, 556, 556, 0, 0, 0, 0, 580, 580, 580, 2303, 580, 2305, 580, 580, 580, 3228, 580, 3230, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 556, 556, 556, 580, 3423, 580, 3425, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2888, 580, 580, 580, 580, 580, 580, 0, 0, 0, 3248, 0, 0, 0, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3334, 534, 534, 0, 3257, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 2982, 534, 534, 3264, 534, 534, 534, 3268, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1328, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3277, 534, 534, 534, 556, 556, 556, 556, 556, 3282, 556, 556, 556, 556, 556, 2294, 0, 0, 0, 580, 580, 580, 580, 580, 580, 580, 580, 3482, 580, 580, 3484, 580, 0, 0, 0, 556, 3286, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1883, 556, 3295, 556, 556, 556, 556, 580, 580, 580, 580, 580, 3301, 580, 580, 580, 3305, 580, 580, 580, 580, 2380, 534, 580, 556, 534, 534, 534, 534, 556, 556, 556, 556, 580, 580, 580, 580, 0, 534, 3601, 556, 3602, 580, 3603, 3489, 0, 0, 0, 534, 534, 534, 3496, 534, 534, 534, 534, 534, 534, 534, 534, 1265, 534, 534, 534, 534, 534, 534, 534, 3504, 556, 556, 556, 3508, 556, 556, 556, 556, 556, 556, 556, 556, 3516, 556, 580, 580, 580, 580, 2624, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1475, 580, 580, 580, 580, 580, 580, 3521, 580, 580, 580, 580, 580, 580, 580, 580, 3529, 580, 0, 0, 0, 0, 0, 0, 122880, 122880, 122880, 122880, 122880, 0, 122880, 0, 2105631, 12290, 0, 3532, 0, 3534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 3540, 3541, 534, 534, 534, 534, 534, 2208, 0, 0, 0, 556, 556, 556, 556, 556, 556, 556, 1387, 556, 556, 556, 1391, 556, 556, 556, 556, 556, 357, 358, 0, 0, 0, 0, 0, 0, 0, 364, 0, 292, 0, 0, 0, 0, 0, 0, 688, 0, 0, 0, 0, 364, 364, 364, 0, 0, 0, 0, 0, 391, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 722, 0, 735, 654, 467, 467, 481, 0, 0, 481, 358, 358, 358, 503, 358, 358, 358, 358, 467, 467, 599, 575, 575, 575, 575, 575, 575, 575, 599, 599, 599, 552, 599, 599, 599, 599, 599, 599, 599, 575, 575, 552, 575, 599, 575, 599, 1, 12290, 556, 556, 928, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 964, 556, 556, 556, 556, 556, 2294, 2615, 0, 0, 0, 0, 580, 580, 580, 580, 580, 534, 556, 580, 0, 0, 0, 0, 0, 0, 0, 0, 2924, 0, 0, 0, 0, 0, 0, 534, 534, 534, 891, 534, 556, 556, 556, 964, 556, 0, 580, 580, 580, 1038, 580, 580, 580, 580, 2636, 580, 2638, 580, 580, 580, 580, 2642, 580, 580, 580, 580, 0, 0, 0, 3440, 0, 0, 0, 3443, 0, 0, 534, 534, 78114, 1066, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1084, 0, 0, 0, 0, 670, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2432, 0, 0, 0, 1184, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 2132, 2133, 534, 534, 1340, 1341, 901, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1353, 556, 556, 556, 556, 580, 3590, 580, 580, 580, 580, 0, 0, 0, 534, 534, 534, 534, 534, 534, 1713, 534, 534, 534, 534, 534, 534, 534, 2140, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2990, 534, 534, 534, 534, 534, 534, 556, 556, 1362, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3047, 556, 556, 556, 0, 1551, 0, 0, 0, 1557, 0, 0, 0, 1563, 0, 0, 0, 0, 0, 0, 0, 1650, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 172032, 0, 1656, 0, 0, 0, 0, 0, 0, 0, 0, 1662, 0, 1664, 0, 0, 0, 0, 0, 0, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 172032, 1, 12290, 534, 534, 1771, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2523, 534, 534, 556, 556, 1854, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1866, 556, 556, 556, 556, 932, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 1815, 556, 556, 556, 556, 556, 1887, 556, 556, 556, 556, 556, 556, 26009, 0, 580, 580, 580, 580, 580, 580, 2312, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1488, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1924, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3073, 580, 580, 580, 580, 580, 1937, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1950, 580, 580, 580, 580, 2648, 580, 580, 580, 580, 580, 580, 580, 580, 2656, 580, 580, 580, 580, 580, 3231, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 580, 580, 580, 1973, 580, 580, 580, 580, 580, 580, 580, 580, 580, 1983, 580, 580, 580, 580, 1484, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3222, 580, 580, 580, 580, 0, 0, 0, 2043, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 733, 1171, 0, 0, 534, 2151, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2795, 534, 2236, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2600, 2323, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3089, 580, 580, 580, 580, 2622, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3224, 580, 580, 2695, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2120, 2734, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2719, 534, 2774, 534, 2776, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2160, 534, 534, 534, 556, 2821, 556, 2823, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3190, 556, 556, 556, 580, 580, 580, 2870, 580, 2872, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2654, 580, 580, 580, 580, 580, 0, 0, 0, 0, 2933, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 2981, 534, 556, 556, 556, 556, 3289, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3202, 556, 556, 556, 556, 580, 3308, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3314, 580, 580, 556, 556, 3589, 556, 580, 580, 580, 580, 3593, 580, 0, 0, 0, 534, 534, 534, 3152, 534, 534, 534, 534, 534, 534, 534, 3157, 534, 534, 534, 0, 0, 359, 0, 0, 0, 0, 0, 0, 364, 0, 292, 0, 0, 0, 0, 0, 0, 702, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2600960, 0, 0, 2768896, 2777088, 2781184, 0, 0, 369, 0, 0, 369, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2040, 2041, 0, 600, 576, 576, 576, 576, 576, 576, 576, 600, 600, 600, 553, 600, 600, 600, 600, 600, 600, 600, 576, 576, 553, 576, 600, 576, 600, 1, 12290, 556, 923, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2234, 556, 556, 556, 556, 556, 1367, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3547, 3548, 556, 556, 580, 580, 580, 580, 580, 1500, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3102, 3103, 3104, 534, 1646, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2748, 0, 0, 1684, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2065, 0, 0, 580, 580, 580, 1938, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3223, 580, 580, 580, 0, 0, 0, 2723, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 734, 0, 0, 0, 2942, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2760, 0, 0, 0, 0, 3249, 0, 3250, 0, 0, 0, 0, 3132, 0, 0, 0, 0, 0, 0, 0, 3333, 0, 534, 534, 534, 0, 0, 0, 360, 361, 362, 363, 0, 0, 364, 0, 292, 0, 0, 0, 0, 0, 0, 718, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2445, 0, 0, 0, 0, 0, 0, 361, 0, 360, 0, 0, 0, 69632, 73728, 0, 0, 0, 0, 427, 65536, 0, 0, 0, 0, 685, 534, 534, 838, 842, 845, 534, 853, 534, 534, 534, 868, 427, 427, 0, 427, 0, 361, 427, 450, 0, 0, 0, 0, 0, 0, 0, 0, 690, 691, 0, 364, 364, 364, 0, 0, 0, 0, 0, 491, 491, 0, 498, 498, 498, 498, 504, 505, 498, 498, 518, 518, 518, 518, 450, 450, 450, 450, 450, 450, 450, 450, 450, 518, 518, 518, 518, 518, 518, 518, 518, 554, 577, 554, 577, 554, 554, 577, 554, 601, 577, 577, 577, 577, 577, 577, 577, 601, 601, 601, 554, 601, 601, 601, 601, 601, 601, 601, 577, 577, 613, 618, 601, 618, 624, 1, 12290, 534, 534, 887, 534, 534, 556, 556, 960, 556, 556, 0, 580, 580, 1034, 580, 580, 580, 580, 1502, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2332, 580, 580, 580, 580, 534, 2513, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2806, 534, 534, 534, 534, 2542, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 0, 0, 0, 0, 556, 556, 556, 2216, 556, 2218, 556, 580, 2674, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 534, 580, 556, 534, 534, 534, 534, 534, 2491, 534, 534, 534, 534, 2495, 534, 534, 534, 534, 534, 0, 0, 0, 0, 556, 556, 2215, 556, 556, 556, 556, 602, 578, 578, 578, 578, 578, 578, 578, 602, 602, 602, 555, 602, 602, 602, 602, 602, 602, 602, 578, 578, 555, 578, 602, 578, 602, 1, 12290, 0, 0, 698, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2410, 0, 0, 728, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2952, 0, 0, 0, 728, 0, 784, 0, 0, 0, 0, 0, 0, 0, 0, 784, 0, 0, 0, 0, 686, 0, 0, 0, 0, 0, 0, 364, 364, 364, 0, 0, 0, 0, 0, 671, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3145, 3146, 0, 0, 0, 556, 924, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2260, 2261, 0, 0, 1176, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2433, 0, 0, 534, 1300, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2548, 0, 0, 1418, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 580, 580, 580, 2664, 580, 580, 580, 580, 2668, 580, 580, 580, 580, 580, 580, 1505, 580, 580, 1509, 580, 580, 580, 580, 580, 1515, 0, 0, 1553, 0, 0, 0, 1559, 0, 0, 0, 0, 0, 0, 0, 0, 0, 299, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2082, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 736, 0, 0, 0, 0, 0, 0, 0, 534, 534, 534, 534, 2167, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1733, 534, 534, 534, 534, 556, 556, 556, 2252, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3471, 580, 580, 580, 580, 580, 580, 2339, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3485, 0, 0, 3488, 2499, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2202, 0, 0, 0, 0, 736, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 1747, 534, 534, 534, 534, 1051, 534, 534, 892, 534, 1056, 556, 556, 965, 556, 0, 1061, 580, 580, 1039, 580, 580, 580, 580, 2885, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2680, 534, 580, 556, 534, 556, 556, 1420, 556, 556, 556, 556, 556, 556, 556, 556, 556, 26009, 1341, 975, 580, 580, 580, 580, 2894, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2900, 580, 580, 580, 580, 534, 534, 534, 534, 1726, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2144, 534, 534, 2148, 534, 1821, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2843, 580, 580, 1954, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 3313, 580, 580, 580, 580, 556, 2586, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 2288, 556, 556, 556, 556, 556, 2614, 0, 0, 0, 0, 0, 0, 580, 580, 580, 580, 580, 1039, 580, 580, 580, 580, 0, 0, 0, 534, 580, 556, 0, 0, 0, 0, 2957, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 534, 2979, 534, 534, 534, 2983, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 534, 2498, 3065, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 580, 2889, 580, 580, 580, 580, 580, 3192, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, 3035, 1134592, 0, 1134592, 0, 0, 0, 1134592, 1135007, 1135007, 0, 0, 0, 0, 0, 1135007, 0, 0, 0, 0, 700, 701, 0, 0, 0, 0, 0, 707, 0, 0, 0, 711, 0, 1134592, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2718, 0, 0, 1134592, 1134592, 0, 0, 0, 0, 1135196, 1135196, 1135196, 1135196, 1134592, 1135196, 1135196, 1135196, 1135196, 1135196, 1135196, 0, 1134592, 1134592, 1134592, 1134592, 1135196, 1134592, 1135196, 1, 12290, 2125824, 3117056, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 0, 0, 2125824, 2125824, 2125824, 2125824, 3137536, 2940928, 2940928, 2940928, 0, 0, 0, 0, 0, 2748416, 2879488, 0, 0, 0, 0, 0, 2113, 0, 0, 0, 2113, 0, 0, 2118, 2119, 0, 0, 0, 0, 0, 1180, 0, 0, 0, 1184, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2474, 0, 1147348, 1147348, 1147348, 451, 451, 1147348, 451, 451, 451, 451, 451, 451, 451, 451, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 1147399, 0, 0, 0, 0, 0, 0, 0, 0, 768, 0, 0, 0, 0, 0, 0, 0, 451, 0, 0, 0, 0, 0, 1147348, 1147348, 1147348, 1147399, 1147399, 1147348, 1147399, 1147399, 1, 12290, 3, 0, 0, 0, 0, 0, 253952, 0, 0, 0, 253952, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2950, 0, 0, 0, 0, 1159168, 0, 1159168, 1159168, 0, 1159168, 1159168, 0, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 0, 0, 0, 0, 0, 0, 0, 0, 781, 0, 0, 0, 0, 0, 792, 0, 0, 1159168, 0, 0, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1159168, 1, 12290, 3, 0, 0, 0, 0, 249856, 0, 0, 0, 249856, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 163840, 0, 0, 0, 0, 65536, 0, 2125824, 3117056, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 0, 0, 974, 2125824, 2125824, 2125824, 2125824, 3149824, 2125824, 2428928, 2437120, 2125824, 2486272, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2625536, 2125824, 2125824, 2125824, 2125824, 2125824, 2125824, 2699264, 2125824, 2715648, 2125824, 2723840, 2125824, 0, 106496, 106496, 0, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 0, 0, 106496, 0, 0, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 106496, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2183168, 0, 0, 0, 0, 0, 0, 0, 0, 2134016, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 695, 0, 0, 0, 0, 0, 3108864, 3198976, 0, 0, 3043328, 0, 3149824, 2936832, 0, 2760704, 0, 0, 0, 0, 0, 0, 0, 69632, 73728, 0, 369, 369, 0, 0, 65536, 369
+];
+
+XQueryParser.EXPECTED =
+[ 127, 143, 342, 950, 172, 201, 188, 217, 769, 963, 247, 263, 279, 295, 311, 327, 1395, 373, 1083, 374, 374, 374, 374, 374, 374, 374, 374, 374, 419, 391, 407, 466, 435, 589, 1682, 909, 574, 156, 1220, 451, 495, 511, 527, 543, 559, 634, 1096, 678, 694, 755, 649, 785, 801, 817, 833, 849, 865, 881, 897, 937, 979, 995, 1023, 1039, 1055, 479, 1112, 1128, 1473, 1144, 1160, 1206, 1236, 357, 662, 1266, 709, 1282, 1292, 1308, 1324, 1339, 1355, 1411, 1427, 1443, 618, 1459, 724, 1489, 604, 1518, 1528, 231, 1070, 1544, 1560, 1576, 1592, 1622, 1250, 1638, 1654, 1606, 921, 1670, 739, 1698, 1714, 1820, 1190, 1730, 1746, 1502, 1758, 1774, 1790, 1806, 1175, 1850, 1860, 1836, 1009, 1370, 1876, 1385, 375, 1892, 1896, 1903, 1903, 1903, 1898, 1902, 1903, 1910, 1907, 1914, 1918, 1922, 1926, 1929, 1933, 1937, 1941, 1945, 4040, 4040, 4040, 4106, 4040, 4040, 2020, 2279, 4040, 1949, 4040, 4040, 4040, 2429, 2379, 4040, 4040, 4040, 4040, 2438, 4040, 4040, 3112, 2651, 3443, 2444, 1955, 1984, 1994, 1998, 4040, 4040, 4040, 4040, 4040, 2017, 2042, 4040, 4040, 4040, 2024, 2285, 2030, 2034, 4040, 4040, 4040, 4040, 4040, 2041, 4040, 4040, 3002, 2285, 2285, 2285, 2285, 2285, 2111, 1988, 1988, 1988, 1988, 1988, 1990, 1955, 1955, 1955, 1955, 1955, 2101, 3099, 1988, 1988, 1988, 1988, 1988, 2120, 1955, 1955, 1955, 1955, 1955, 2046, 2055, 4040, 4040, 2212, 2349, 4040, 4040, 4040, 4137, 3441, 4040, 4040, 4040, 4040, 3531, 4040, 2745, 1988, 1988, 1988, 2066, 1955, 1955, 1955, 1957, 2073, 4040, 4040, 2473, 3002, 2285, 2285, 2026, 1988, 1988, 3101, 1955, 1955, 1956, 2072, 4040, 2471, 4040, 2284, 2285, 3098, 1988, 1988, 2078, 1955, 2068, 2129, 2446, 3554, 2285, 2112, 1988, 2120, 1955, 2083, 2281, 2286, 1988, 2067, 2089, 2095, 2113, 2049, 2107, 3097, 2114, 2079, 3096, 3100, 2079, 3096, 2114, 2051, 2118, 2126, 2135, 2139, 2143, 2156, 2160, 2170, 2170, 2170, 2163, 2167, 2170, 2173, 2177, 2181, 2185, 2189, 2193, 2197, 2201, 2205, 2209, 2216, 4040, 4040, 4040, 2131, 4040, 4040, 4040, 2220, 4040, 2226, 4040, 2283, 2287, 1988, 1954, 2122, 2098, 1961, 4040, 4040, 4040, 1970, 4040, 2474, 1980, 4040, 2321, 3139, 4040, 2440, 3145, 4427, 2277, 3219, 2796, 3151, 3505, 3155, 4040, 3263, 3161, 2906, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4041, 2255, 2259, 2262, 2266, 2270, 2274, 3465, 2291, 4040, 4040, 4040, 4040, 3213, 2296, 2312, 2303, 2396, 2240, 2243, 2309, 2316, 2320, 2649, 4006, 4040, 2726, 2326, 3670, 4040, 4040, 4040, 4040, 2231, 3466, 4040, 4040, 4040, 3429, 2237, 4040, 2618, 3123, 2249, 2253, 3877, 2348, 4040, 4040, 4013, 2355, 4040, 2359, 4040, 4040, 4040, 4040, 3173, 2321, 2227, 2367, 3192, 4040, 4040, 2459, 4040, 4040, 3192, 4040, 4040, 4348, 2989, 2882, 2918, 3129, 2349, 4040, 3014, 2311, 2670, 2331, 3577, 4417, 2336, 2379, 4040, 4040, 2549, 2340, 4040, 4040, 4040, 2984, 4040, 4040, 4040, 4040, 3591, 2979, 4040, 4040, 4040, 3390, 4180, 4419, 3131, 4040, 3190, 3194, 4040, 2950, 2989, 2918, 3210, 4040, 2469, 2788, 3212, 4040, 4005, 3283, 3279, 4282, 4040, 3281, 4226, 4226, 2601, 4283, 3283, 3283, 1966, 3282, 3279, 1966, 4227, 3283, 4191, 2462, 2478, 4040, 4040, 4040, 4040, 2588, 2522, 4040, 4040, 4040, 2007, 2858, 2484, 3025, 2492, 2495, 2498, 2502, 2503, 2507, 2511, 2515, 4040, 2521, 4040, 4040, 2526, 4040, 3968, 2913, 2541, 2545, 3867, 2553, 2563, 2574, 2578, 4040, 3387, 3385, 4040, 2582, 4040, 3458, 2587, 4040, 3120, 4040, 4040, 4040, 3174, 2074, 2409, 2537, 2432, 4040, 4040, 4040, 2536, 2416, 4040, 2373, 2377, 4040, 4040, 4040, 4040, 4255, 2378, 4040, 4040, 4040, 4040, 4256, 2379, 4040, 2838, 3503, 4040, 4040, 4040, 4040, 2839, 3504, 3974, 3509, 4040, 4040, 3730, 3536, 4040, 3349, 2906, 4040, 3326, 2556, 3181, 3383, 3394, 3403, 4040, 4397, 4040, 3553, 3551, 3545, 4040, 2668, 2912, 3478, 3399, 2548, 2592, 3456, 3471, 2600, 4040, 4040, 4040, 4242, 4040, 3147, 4040, 3818, 4040, 4037, 3923, 3990, 3561, 4003, 4040, 2655, 4039, 4040, 4040, 4040, 3167, 4040, 4040, 4040, 3331, 3171, 4040, 4040, 4040, 4040, 3632, 3179, 4040, 2638, 2611, 2615, 4040, 2388, 2622, 4040, 4040, 4040, 4040, 2389, 2349, 4040, 4040, 4040, 2397, 2390, 4040, 4040, 4040, 3141, 4040, 4040, 3846, 4040, 4040, 2630, 2517, 4070, 2637, 2412, 2989, 4040, 4040, 4040, 4040, 2344, 4040, 4040, 4040, 4040, 4040, 3269, 2989, 2380, 3207, 4040, 3463, 4040, 4040, 4040, 3861, 3470, 4040, 4040, 4040, 3475, 4040, 3482, 4040, 4040, 2631, 3905, 4040, 4040, 4040, 4040, 2631, 3905, 2424, 3909, 4040, 2152, 2595, 3785, 3915, 2631, 4365, 2642, 4040, 4040, 4040, 4040, 4085, 2646, 4040, 4040, 4040, 4040, 4085, 2646, 4040, 4040, 2464, 4040, 4040, 2285, 2285, 2285, 2285, 2025, 1988, 1988, 1988, 1988, 1988, 2120, 3610, 3833, 4040, 4040, 4040, 4365, 2656, 4040, 4040, 4040, 2660, 2665, 3980, 2516, 3196, 2674, 2678, 3830, 2685, 4040, 4040, 3830, 2685, 4040, 4040, 2299, 2690, 4040, 3184, 3458, 2004, 3969, 3197, 3312, 3251, 2696, 4040, 2037, 2690, 4040, 3251, 2696, 4040, 2702, 2709, 3195, 4000, 2713, 2717, 4040, 2715, 4040, 2679, 2723, 4040, 2730, 2734, 2739, 3644, 4040, 2705, 2583, 3646, 2583, 2749, 2753, 2704, 3203, 2944, 2566, 2570, 2956, 2945, 3843, 2568, 2568, 2761, 3815, 3641, 2765, 3607, 2769, 2773, 2775, 2779, 2783, 2787, 4040, 4040, 4040, 3316, 4040, 4040, 3564, 2792, 3570, 2800, 2804, 2808, 2810, 2814, 2818, 2821, 2823, 2824, 4040, 4040, 3315, 4040, 3428, 2828, 3896, 3248, 2833, 2843, 2434, 2453, 3918, 2849, 2907, 2853, 4040, 2150, 2148, 4040, 4040, 4040, 4040, 2405, 2349, 4040, 4040, 4040, 4040, 2405, 2349, 4040, 4040, 4040, 4040, 2362, 3442, 4040, 4040, 4040, 4040, 2363, 3773, 3950, 4040, 4040, 4040, 2857, 4040, 2559, 2968, 3853, 2862, 2937, 4379, 2869, 3988, 3295, 4040, 2873, 4040, 4040, 4040, 3554, 2285, 2285, 2285, 2285, 1987, 1988, 1988, 1988, 1989, 1955, 1955, 1955, 1955, 1956, 2103, 4040, 4040, 4040, 2472, 4040, 2109, 2285, 2285, 2285, 2113, 3527, 2877, 4040, 4040, 4040, 2886, 2890, 4040, 4040, 4040, 4040, 2980, 4040, 3336, 2829, 3897, 2895, 2899, 4040, 2911, 2917, 4040, 4040, 2922, 4040, 4040, 4040, 4040, 2844, 2923, 4040, 4040, 2626, 4289, 4040, 3453, 3038, 4353, 4386, 3183, 4040, 4040, 4041, 4370, 4040, 4040, 2845, 2924, 4040, 4040, 4040, 4040, 4040, 2990, 4040, 2558, 2928, 4420, 2935, 4040, 2943, 2949, 4040, 2970, 2954, 4040, 4040, 4040, 4040, 3855, 2960, 4040, 4040, 4040, 4040, 3855, 2960, 4040, 4040, 4040, 4040, 3389, 4040, 2966, 3897, 2974, 2327, 4275, 4040, 3590, 2978, 4040, 3535, 3379, 3488, 3521, 3230, 4040, 4040, 3540, 4040, 4040, 4040, 3439, 4040, 4040, 4040, 4364, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4378, 4040, 4040, 4040, 2605, 4040, 4040, 2245, 4040, 4040, 3459, 4040, 4040, 4038, 3923, 4040, 2013, 3616, 2411, 4040, 3631, 2988, 4040, 4040, 3631, 2988, 4040, 4040, 4040, 2994, 4040, 4040, 2350, 4262, 2381, 3617, 4040, 4040, 4346, 4040, 4040, 3000, 4040, 4040, 4346, 4040, 2350, 4208, 3615, 2881, 4040, 2795, 3174, 3112, 3180, 3024, 3111, 3180, 3180, 3933, 3014, 3113, 3113, 3006, 3181, 3014, 3013, 3014, 3175, 4047, 3018, 3029, 3053, 4040, 4040, 4040, 4040, 3634, 4040, 4221, 4040, 3650, 4040, 4040, 4040, 4040, 2631, 3651, 4040, 4040, 4040, 4040, 3648, 4287, 4291, 4040, 4010, 4017, 4303, 4022, 2632, 3182, 4040, 4032, 4040, 1950, 4012, 4040, 2865, 4045, 4051, 3043, 3047, 4064, 3061, 3065, 3069, 3073, 3077, 3081, 3105, 3084, 4040, 4040, 3633, 4040, 4040, 3443, 2444, 4040, 4040, 4040, 2450, 4040, 4040, 4040, 4349, 4040, 4040, 3014, 3276, 2487, 2961, 2691, 4276, 3109, 1976, 3117, 3127, 3289, 3135, 3305, 4040, 3324, 3322, 4040, 4040, 3734, 3779, 3739, 3744, 3969, 4040, 3748, 3754, 3761, 3943, 3887, 3765, 4057, 4040, 2488, 2962, 2692, 3163, 3224, 3188, 3412, 4040, 4040, 2085, 3201, 4040, 4040, 4040, 4040, 2343, 3217, 3223, 3228, 4040, 4040, 4040, 3234, 4040, 4040, 4040, 4040, 4040, 3238, 4040, 4040, 4040, 4040, 3422, 4040, 2529, 2686, 4354, 3245, 4040, 4040, 4040, 4342, 4040, 4040, 4040, 4040, 1972, 4040, 4040, 4040, 4040, 4040, 3255, 4040, 4040, 4040, 3423, 3952, 2686, 4355, 3261, 4040, 4040, 3267, 4040, 4040, 4040, 1974, 4040, 4040, 4040, 3273, 4040, 4220, 3981, 2680, 4356, 3895, 4040, 3287, 4040, 4040, 3293, 4040, 4040, 2062, 4040, 4220, 3953, 3299, 2146, 4040, 3303, 4040, 2607, 4040, 4040, 2061, 4040, 4248, 3309, 3894, 3498, 4040, 4360, 4040, 4040, 4040, 4369, 4040, 4374, 3056, 4383, 3622, 4040, 4040, 4390, 4040, 4040, 4424, 2742, 4040, 2633, 4040, 3056, 4040, 3039, 3157, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 2455, 4325, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 3320, 4040, 3330, 3911, 3335, 3629, 3588, 4213, 3943, 3587, 4213, 4213, 4040, 3341, 3589, 3589, 3628, 4214, 3341, 3340, 3341, 3630, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 4040, 3836, 2349, 3347, 4040, 3354, 3001, 4080, 4404, 3358, 3362, 3366, 3369, 3373, 3373, 3377, 4040, 4040, 3835, 4091, 3410, 4040, 4040, 3416, 4040, 4040, 3420, 3427, 4040, 3433, 4040, 4331, 3447, 4040, 4040, 3797, 4040, 3795, 4040, 4040, 4345, 4040, 2350, 1964, 4040, 2879, 4040, 3397, 4040, 2904, 4040, 3350, 3488, 4040, 3486, 2535, 3492, 3496, 4040, 4040, 4040, 3502, 4040, 4040, 4040, 4127, 4028, 2010, 4131, 4141, 4145, 4149, 4153, 4157, 4161, 4165, 4169, 4173, 4134, 4377, 4293, 2534, 3516, 4040, 4040, 4040, 2839, 3504, 4040, 4040, 4040, 4040, 2931, 3442, 4040, 3450, 4040, 2902, 4040, 3799, 4363, 3520, 4196, 3525, 3406, 2349, 2757, 2305, 2996, 4393, 4347, 3544, 4040, 3549, 4040, 4040, 3549, 4040, 4040, 3558, 2756, 2305, 4077, 4395, 3960, 4040, 3568, 4040, 3823, 2349, 4040, 3997, 3750, 3574, 3884, 3961, 4269, 4040, 4270, 4040, 3581, 3944, 3585, 3595, 3931, 3600, 2001, 3930, 3604, 3604, 4211, 3614, 3932, 3621, 3626, 3662, 3638, 3655, 3656, 3660, 3667, 3674, 3678, 3682, 3685, 4040, 4040, 4040, 3840, 2596, 3740, 3850, 2668, 2332, 3343, 4040, 3859, 4040, 4040, 4040, 2233, 3865, 2891, 3735, 2465, 2351, 3690, 3698, 3874, 3702, 3705, 3709, 3713, 3717, 3721, 3725, 3729, 4040, 2423, 2421, 3241, 3772, 4040, 4040, 2939, 3777, 3783, 3789, 3793, 4136, 2698, 3342, 2633, 2425, 3803, 4040, 4040, 3808, 2349, 4040, 4040, 4186, 3812, 4040, 4040, 4040, 3009, 3822, 3827, 4040, 3871, 2532, 4318, 3881, 4040, 3891, 3773, 4040, 4040, 4040, 4040, 3901, 4040, 4040, 4040, 4040, 4040, 2385, 4040, 4040, 4040, 4040, 3014, 4040, 2394, 4040, 2401, 2379, 4035, 3922, 4040, 4040, 2292, 3927, 4040, 4040, 4040, 4040, 3937, 4040, 4040, 4040, 4040, 2091, 3941, 3948, 4040, 3957, 3757, 3966, 2835, 3112, 4040, 4040, 2222, 3979, 4040, 4040, 2719, 3973, 2632, 3183, 3021, 4040, 4055, 4040, 4061, 2419, 4040, 3023, 4068, 4074, 4084, 4112, 4089, 4095, 3596, 4100, 4308, 4099, 4104, 4110, 4099, 4113, 4119, 3257, 4117, 4123, 4040, 4040, 4040, 4040, 4177, 4184, 2836, 3686, 4190, 3693, 4195, 4200, 4410, 4205, 4218, 4040, 3090, 2735, 4225, 3093, 4231, 4040, 4040, 4040, 3631, 4235, 2661, 4040, 2681, 4429, 2369, 4040, 4239, 4040, 4040, 4040, 4040, 3804, 4246, 4040, 4040, 4040, 4252, 4040, 4040, 4040, 2631, 4260, 4266, 4040, 4040, 4040, 4025, 4185, 2837, 2686, 2480, 4274, 4040, 4280, 4040, 4040, 4040, 4040, 4201, 3978, 4018, 4303, 3768, 4040, 3050, 4040, 4040, 3985, 4040, 4040, 3994, 4040, 4322, 4385, 4329, 4040, 4040, 4040, 4040, 4335, 4040, 4040, 4040, 4040, 3663, 4339, 4040, 4040, 4297, 4040, 3057, 3087, 4301, 3962, 3032, 4040, 4040, 4040, 4040, 2624, 4307, 4040, 4040, 4040, 4040, 2624, 4312, 4315, 4040, 2322, 3436, 2837, 2058, 4040, 4040, 3035, 4040, 4401, 4408, 3694, 4040, 4040, 3512, 4040, 2631, 4414, 4040, 3511, 4558, 4433, 6024, 6027, 4439, 4466, 4468, 4468, 4446, 4455, 4467, 4468, 4468, 4468, 4468, 4468, 4468, 4473, 4468, 4468, 4463, 4457, 4459, 4479, 4477, 4483, 4468, 4469, 4493, 4496, 4506, 4510, 4524, 4519, 4511, 4500, 4502, 4502, 4518, 4519, 4498, 4515, 4523, 4528, 4532, 4536, 4539, 4547, 4546, 4543, 4551, 4554, 4556, 4566, 5097, 4574, 6086, 5003, 5101, 5101, 5101, 4593, 4599, 4602, 4602, 4602, 4602, 4608, 4640, 4568, 4622, 4628, 5101, 4434, 5101, 5099, 5101, 6713, 5101, 6256, 5101, 5101, 4584, 5992, 5101, 5101, 4729, 5101, 5473, 6277, 5101, 5007, 4602, 5693, 4609, 5696, 5699, 5699, 5699, 5699, 4601, 4602, 5699, 4602, 4619, 4621, 4623, 4627, 6087, 5101, 4434, 6165, 6164, 5101, 5101, 6380, 6242, 5096, 5101, 4576, 5101, 6463, 5101, 5101, 5635, 4488, 5366, 6275, 5101, 4581, 5101, 4590, 5411, 5123, 5123, 5123, 5697, 5699, 4603, 4621, 4621, 4622, 4627, 4627, 4628, 5101, 4583, 5448, 6513, 5474, 5101, 5008, 5101, 5101, 4602, 4632, 5123, 5699, 4602, 4602, 4602, 5704, 5121, 4602, 4621, 4627, 5101, 4583, 6563, 5101, 4584, 6017, 5101, 5101, 5699, 5701, 4602, 4602, 4602, 4632, 4640, 5705, 5101, 5101, 5101, 4734, 5700, 4602, 4602, 4602, 5705, 4643, 5701, 5101, 5101, 4824, 5651, 4602, 4650, 5101, 5101, 4824, 6512, 5010, 5695, 5123, 5123, 5698, 5690, 4602, 4608, 5696, 5700, 5703, 5101, 4602, 5101, 5101, 5121, 5123, 5123, 5123, 5699, 5699, 5699, 5702, 5123, 5698, 5699, 5702, 4602, 4602, 5704, 4607, 4602, 5705, 5123, 5697, 5704, 5101, 5101, 4816, 4822, 5699, 4602, 5704, 5695, 5698, 5702, 5694, 5701, 4651, 4652, 4650, 5101, 4592, 5101, 5101, 5815, 5567, 5101, 5101, 5106, 6519, 6761, 6550, 6560, 4662, 4695, 4656, 4660, 4693, 4666, 4673, 4670, 4680, 4684, 4691, 4693, 4693, 4693, 4693, 4694, 4676, 4699, 4693, 4703, 4708, 4714, 4704, 4726, 4740, 4744, 4687, 4751, 4753, 4748, 4787, 4789, 4789, 4791, 4757, 4759, 4761, 4763, 4776, 4776, 4770, 4767, 4774, 4717, 4675, 4710, 4780, 4784, 4795, 4797, 4801, 4805, 4809, 5101, 4592, 6198, 6202, 4990, 5007, 5230, 6461, 5101, 6373, 5101, 5101, 4824, 6698, 4831, 5101, 5101, 5101, 4736, 5108, 5108, 5101, 5101, 4826, 6485, 5490, 5979, 4838, 5101, 4720, 4985, 5101, 4720, 5101, 5101, 4853, 5311, 4857, 5333, 4876, 4902, 4906, 4906, 4906, 4906, 4908, 4915, 4917, 4912, 4921, 4925, 4928, 4931, 4934, 4939, 4938, 4943, 4944, 4959, 4949, 4948, 4953, 4956, 4963, 5101, 5107, 5101, 4892, 5101, 5007, 5101, 5101, 5695, 5123, 5123, 5123, 5123, 5696, 5699, 5988, 5101, 5101, 5101, 4825, 5300, 5101, 5608, 5101, 4811, 5449, 6426, 4969, 5101, 5101, 4988, 6219, 5101, 5018, 4987, 5101, 5101, 4860, 5101, 5101, 4995, 5015, 5101, 6412, 5034, 5101, 5101, 5101, 4893, 6751, 6138, 5101, 5101, 5101, 4894, 6729, 5101, 5101, 5101, 4965, 5055, 5068, 5081, 5086, 5091, 5076, 5095, 5101, 4824, 5933, 5929, 5376, 5087, 4434, 5101, 5101, 5101, 4979, 5008, 6409, 5996, 5101, 5999, 5151, 5987, 5376, 5101, 4826, 6502, 6738, 6204, 5101, 6730, 5101, 5101, 4891, 5101, 4570, 5101, 5115, 5127, 5074, 4442, 5096, 5101, 5101, 5101, 4975, 5538, 5411, 5986, 5281, 5101, 4840, 5628, 5355, 5382, 4434, 4736, 5101, 4973, 5101, 5101, 5101, 4840, 5687, 5132, 5075, 5140, 5890, 5072, 5076, 5141, 6462, 4888, 5101, 5101, 4895, 5101, 5343, 5073, 6582, 4451, 5101, 4894, 5101, 5101, 6416, 5101, 5101, 5101, 6191, 5101, 5415, 5892, 5074, 6583, 5096, 5101, 5101, 4898, 5999, 5411, 5280, 5101, 5101, 4974, 4978, 5134, 5157, 5101, 5101, 5007, 5101, 5132, 5075, 5159, 5101, 4897, 5101, 5871, 4980, 5101, 5949, 5135, 5159, 5101, 4976, 5101, 5101, 5010, 5101, 5101, 5169, 4434, 5101, 5101, 5009, 5101, 5101, 5101, 4613, 4614, 4975, 5101, 4614, 5101, 5411, 4978, 6164, 6391, 5101, 4977, 6380, 5395, 5376, 5188, 4872, 5243, 5197, 5197, 5194, 5197, 5199, 5203, 5205, 5207, 5209, 5209, 5209, 5213, 5213, 5213, 5213, 5214, 5213, 5213, 5215, 5219, 5221, 5101, 5101, 5101, 5036, 5101, 5059, 5063, 5372, 5101, 5101, 5101, 6378, 6010, 5101, 4978, 6569, 5101, 4980, 5101, 5417, 5101, 5101, 5101, 5891, 5074, 5240, 5101, 5351, 6463, 5247, 5101, 5101, 5257, 5101, 5101, 5101, 5068, 5263, 6448, 5875, 5101, 4981, 5101, 5101, 5876, 6281, 5416, 5275, 4435, 5874, 5101, 4990, 6089, 5406, 5410, 5101, 5265, 5407, 5285, 5101, 5101, 5297, 6402, 5101, 5101, 5304, 5309, 5101, 5101, 5101, 5057, 5371, 5101, 5101, 5101, 5059, 5330, 4833, 5427, 5101, 5010, 4978, 5101, 5415, 5358, 5101, 5101, 5101, 5100, 5883, 5359, 5101, 5101, 5102, 6015, 4893, 5258, 5101, 5342, 5432, 5101, 5348, 5101, 5024, 6570, 5977, 5382, 4434, 5101, 5101, 5102, 6113, 5726, 5101, 6379, 5101, 5101, 5101, 5102, 5101, 5101, 6462, 5101, 4561, 5876, 5101, 6422, 6426, 5381, 6381, 6423, 6427, 5382, 5101, 5031, 5101, 5101, 4866, 4885, 4811, 5438, 6425, 5399, 6381, 5479, 5101, 5101, 5101, 5104, 5106, 5060, 5064, 5101, 5035, 5101, 5101, 5051, 5101, 5350, 5101, 5879, 4896, 5431, 5101, 5101, 5101, 5106, 5101, 4975, 5471, 5101, 5101, 5101, 5107, 6430, 5101, 5101, 5101, 5108, 4890, 6429, 6381, 5101, 5101, 5102, 6446, 5479, 5101, 5101, 5453, 5269, 5410, 5101, 4614, 5101, 5101, 6380, 5153, 5101, 5101, 5732, 5268, 5470, 5101, 5101, 5102, 6697, 5459, 5468, 6381, 5101, 5041, 5046, 5045, 5478, 5101, 5101, 5453, 4614, 5101, 5101, 5101, 5111, 6088, 5350, 5877, 5413, 5538, 5101, 5101, 5047, 5047, 5047, 5461, 5101, 6088, 6119, 5106, 5267, 5271, 5101, 5047, 6213, 5101, 5101, 5404, 4990, 5404, 5408, 5404, 4990, 5404, 5962, 5423, 5961, 5101, 6084, 5423, 5233, 6104, 5101, 4990, 5232, 5230, 5101, 5232, 4989, 5232, 5232, 5232, 5231, 6488, 5101, 5101, 5101, 5168, 5876, 5722, 5483, 4434, 5099, 5101, 5101, 6498, 6279, 5487, 5101, 4886, 6166, 5489, 5856, 5494, 5500, 5498, 5504, 5504, 5504, 5504, 5506, 5513, 5510, 5517, 5519, 5519, 5519, 5521, 5519, 5525, 5525, 5525, 5525, 5527, 6280, 5415, 5319, 5672, 5101, 5005, 6438, 5101, 5101, 5103, 5101, 5101, 5101, 6361, 6199, 5571, 5101, 5101, 5101, 5176, 5626, 6498, 5551, 5101, 6442, 5561, 5101, 5814, 5566, 5575, 5101, 5101, 5101, 5181, 6167, 5004, 6438, 5101, 5102, 6092, 6381, 5580, 5101, 5101, 5004, 6127, 5600, 5863, 5606, 5862, 5605, 5101, 5101, 5235, 5101, 5101, 5101, 5424, 5102, 6128, 5601, 5864, 5607, 5101, 5101, 5101, 5224, 5101, 6167, 5101, 5006, 6440, 5101, 5569, 5101, 5102, 6180, 5148, 5101, 5101, 5996, 5101, 6283, 5464, 5101, 5101, 5101, 5228, 5101, 5620, 5101, 5101, 5101, 5232, 5176, 5626, 6753, 5665, 5101, 5101, 5632, 5321, 4434, 5101, 5102, 6362, 6200, 5027, 5562, 5101, 5570, 5101, 5101, 5223, 5746, 5463, 5101, 5101, 5101, 5266, 4989, 5621, 5101, 5101, 5101, 5278, 6754, 5666, 5101, 5101, 5265, 5407, 6755, 5376, 5101, 5101, 4990, 5101, 5612, 5415, 5320, 6393, 5101, 5101, 5176, 5639, 5646, 4577, 5568, 5410, 5640, 5664, 5101, 5101, 5101, 5293, 5175, 5639, 5663, 5376, 5659, 5376, 5101, 5101, 5101, 4980, 5657, 5676, 5101, 5101, 5288, 5037, 5658, 5101, 5101, 5101, 5411, 5123, 5098, 5101, 5423, 5101, 5102, 6471, 6477, 5098, 5101, 5424, 5101, 5101, 5426, 5098, 5424, 5101, 5102, 6558, 5101, 5101, 5101, 6393, 5101, 5426, 5424, 5568, 5424, 5233, 5101, 5101, 5102, 6562, 5101, 5104, 5101, 5101, 5101, 4974, 6215, 5710, 4879, 5101, 6496, 5376, 5101, 5105, 5101, 5424, 5424, 5099, 5101, 5105, 5101, 5101, 5101, 5720, 4722, 5730, 5742, 5751, 5757, 5766, 5764, 5767, 5755, 5761, 5771, 5774, 5776, 5778, 5790, 5782, 5785, 5789, 5790, 5791, 5796, 5795, 5801, 5797, 5806, 5101, 5108, 4976, 5101, 5110, 6702, 5101, 5111, 6707, 5101, 5123, 5123, 5123, 5698, 5699, 5699, 5700, 4602, 5801, 5802, 5801, 5801, 4998, 5101, 5098, 5101, 5101, 5425, 5101, 5101, 5812, 5819, 5557, 5101, 5145, 5281, 5101, 4844, 5876, 4852, 5595, 5101, 4888, 5101, 5950, 5136, 4434, 5101, 4615, 5101, 5101, 5823, 5848, 5941, 5101, 5101, 5363, 5101, 5472, 5373, 5101, 5101, 5386, 5101, 5860, 4888, 5868, 5887, 5011, 5011, 5101, 5101, 5414, 5101, 6528, 5376, 5101, 5101, 5414, 6347, 5545, 5908, 6527, 4732, 5904, 6529, 5101, 5101, 5423, 5101, 5101, 5100, 5942, 5101, 5101, 5101, 5426, 5101, 5101, 5101, 5479, 5912, 5924, 5101, 5101, 5423, 5163, 5158, 5101, 5101, 5101, 4989, 5101, 5350, 5929, 5376, 5101, 5101, 5454, 5270, 6215, 5393, 5374, 5101, 5168, 5173, 5101, 5101, 5101, 5021, 5109, 5101, 5411, 5101, 5853, 5101, 6347, 5101, 5100, 5101, 5102, 5947, 5925, 5101, 5101, 5530, 4980, 4811, 5650, 5954, 5376, 4812, 5959, 5955, 5101, 5184, 5539, 6436, 5879, 5098, 5102, 5538, 5101, 6166, 5101, 5102, 5447, 5442, 4585, 5993, 5101, 5101, 5538, 6089, 5099, 4592, 5101, 5101, 5546, 5903, 4584, 5993, 5101, 5101, 5649, 5940, 5102, 4586, 5994, 5101, 5231, 4887, 5101, 4974, 5100, 5101, 5101, 6712, 5101, 5101, 4584, 5995, 5101, 5101, 5706, 5898, 4585, 5995, 5101, 5101, 5808, 5101, 5106, 5101, 5413, 6346, 5102, 6004, 5101, 5101, 5833, 5840, 6392, 5107, 5412, 5876, 4894, 5152, 5101, 5035, 5576, 5101, 5101, 5106, 6016, 5101, 5101, 5837, 5841, 5101, 5101, 5338, 5101, 6015, 5101, 5101, 5101, 5547, 5412, 5101, 5101, 5101, 5612, 5101, 6161, 5101, 5101, 5101, 5679, 5101, 5101, 6367, 5101, 5101, 5842, 6096, 5101, 6282, 5101, 4486, 6021, 6046, 6045, 6046, 6046, 6043, 6046, 6050, 6054, 6058, 6062, 6071, 6066, 6070, 6071, 6071, 6075, 6075, 6075, 6075, 6078, 6082, 5101, 5101, 5842, 6097, 5103, 5234, 5101, 5101, 5880, 5305, 5101, 5101, 5047, 5101, 5101, 6102, 5109, 6108, 5101, 5236, 5101, 5101, 5325, 5101, 6117, 5101, 6123, 5101, 5249, 6209, 6202, 5101, 6493, 5101, 5101, 5897, 5101, 5101, 6142, 6181, 5096, 5843, 6097, 5101, 5101, 5966, 5101, 5101, 5996, 5101, 5101, 5101, 5876, 5103, 6174, 5101, 5101, 5416, 5421, 5101, 5101, 5251, 6200, 6204, 5101, 5101, 5101, 5949, 6147, 6152, 6000, 4980, 4980, 4980, 5101, 5292, 4635, 5101, 5299, 5101, 5101, 5058, 5062, 5371, 6361, 5737, 5101, 5101, 5975, 4848, 5988, 6137, 5101, 5101, 5101, 5882, 5102, 5734, 5738, 5101, 5317, 6462, 5349, 6382, 5101, 6160, 6159, 5101, 6173, 5101, 5101, 5999, 5101, 5101, 6667, 5106, 4894, 6247, 4978, 5101, 5101, 6004, 5101, 6361, 6199, 6203, 5101, 5101, 5101, 5896, 6382, 6382, 5101, 5101, 6111, 5418, 5101, 5101, 6668, 4893, 6186, 5101, 6769, 5879, 5101, 5101, 5529, 6188, 5101, 5101, 6126, 5599, 5102, 6197, 6201, 6205, 5419, 6182, 4434, 5101, 5101, 6089, 5252, 6201, 6205, 5585, 5101, 5101, 5101, 6007, 6455, 4450, 5101, 5101, 6133, 5101, 5101, 5101, 5695, 6454, 4449, 4434, 5101, 5350, 5101, 5878, 5101, 6280, 4886, 4988, 6229, 5101, 5101, 6162, 4614, 5101, 6378, 4434, 5101, 5375, 5101, 4562, 6229, 5101, 4978, 6214, 6161, 4980, 5101, 5101, 6162, 5101, 5101, 5101, 5655, 5640, 6234, 5101, 5101, 5101, 6089, 5101, 6258, 4434, 6240, 5101, 6258, 4434, 5101, 5404, 5962, 5101, 5102, 5437, 6424, 6235, 5101, 5101, 5568, 5410, 5101, 5101, 6236, 5101, 6165, 5101, 5101, 5101, 6259, 5101, 5101, 6164, 5101, 5101, 5101, 5648, 5849, 5942, 5101, 6260, 5101, 6165, 5101, 5405, 5409, 5101, 5057, 5268, 5409, 5101, 5101, 5102, 6742, 5253, 5101, 5101, 5101, 6260, 5101, 5101, 6259, 5101, 6167, 6258, 5101, 5101, 5101, 6112, 6259, 5101, 6259, 6165, 4847, 5987, 5376, 5568, 6497, 6259, 5568, 6497, 6168, 6257, 6257, 6261, 6251, 6254, 6254, 5101, 5101, 5101, 6169, 5118, 5101, 5916, 5101, 5414, 5538, 5101, 5101, 5918, 4896, 5553, 4884, 5037, 6272, 6287, 6305, 6299, 6305, 6303, 6299, 6309, 6293, 6290, 6295, 6322, 6313, 6327, 6316, 6319, 6323, 6332, 6331, 6339, 6339, 6340, 6339, 6339, 6339, 6336, 6344, 5101, 5101, 5101, 6178, 5224, 5747, 5376, 5101, 5101, 5415, 5101, 5101, 6351, 4893, 4893, 4882, 5230, 5001, 5101, 6372, 5101, 5101, 6214, 4980, 5101, 6357, 5969, 5101, 5417, 5419, 6353, 6366, 4434, 5101, 6371, 6390, 6397, 6401, 5101, 5418, 4636, 5647, 6434, 5101, 5101, 5101, 6192, 5943, 5101, 5008, 5101, 4978, 5101, 4979, 5101, 5416, 5101, 6351, 4893, 5419, 6352, 4894, 6268, 6367, 5002, 5101, 5101, 6279, 5641, 5101, 5101, 5290, 5101, 6452, 5101, 5101, 5101, 6223, 5101, 6470, 6459, 6480, 6475, 6479, 6205, 5101, 5423, 5407, 5101, 5057, 5061, 5390, 6481, 5101, 5101, 5101, 6228, 5589, 5588, 5587, 5101, 5436, 5442, 6428, 5402, 5101, 5101, 5102, 6143, 6182, 5106, 5745, 6520, 5101, 5455, 5409, 5101, 5057, 5061, 5370, 6267, 5101, 5410, 5101, 5535, 5101, 5101, 5177, 5640, 5423, 5999, 5101, 5101, 6360, 5736, 6738, 6204, 5101, 5101, 6378, 5101, 5224, 5077, 5101, 5008, 6265, 5555, 5101, 5415, 5070, 5082, 5622, 5101, 5101, 6278, 6165, 5233, 5101, 5377, 6377, 6386, 5103, 5101, 5679, 5101, 5538, 5101, 5101, 5101, 5534, 5538, 4826, 5935, 6737, 6204, 4827, 5936, 6535, 6204, 6191, 6191, 5101, 5101, 6378, 6393, 5232, 5101, 5036, 5101, 5543, 5259, 5326, 6190, 5101, 5101, 5101, 6278, 5443, 6506, 4434, 5101, 5568, 6236, 5101, 5101, 5568, 5101, 5102, 6511, 5134, 6507, 5164, 4451, 5101, 5101, 6392, 5101, 6165, 5101, 6192, 6192, 6192, 5101, 5101, 6378, 6392, 5101, 5101, 6517, 5376, 5101, 5583, 5101, 5101, 5101, 6011, 6524, 5101, 6278, 5101, 5101, 5101, 5037, 6155, 5101, 5101, 5101, 6382, 6533, 6549, 5101, 5101, 5101, 6379, 6393, 5101, 6544, 6381, 5101, 5593, 5101, 5101, 5229, 5634, 5101, 6676, 6549, 5101, 5616, 6230, 5101, 5351, 5877, 4895, 5411, 5432, 5101, 5101, 5101, 5031, 5101, 6675, 6548, 5101, 5101, 5101, 6391, 5101, 6539, 5426, 5101, 5101, 5417, 5920, 4896, 5101, 5648, 6722, 5416, 6462, 5101, 5562, 5101, 6554, 6381, 5101, 5680, 5101, 5101, 6381, 5101, 5101, 5101, 5101, 4583, 5101, 6540, 5425, 5101, 5426, 5101, 5101, 6709, 5417, 4895, 5102, 4595, 5101, 5101, 6406, 5101, 4594, 5403, 6540, 5101, 5714, 5003, 4991, 6090, 6568, 5101, 5101, 6464, 4988, 5101, 6091, 6381, 5101, 5842, 5037, 5998, 5996, 5996, 5413, 4893, 5101, 5101, 5101, 6419, 5101, 6091, 5101, 5101, 6492, 6491, 5101, 6091, 5101, 4895, 4561, 4896, 5101, 5101, 6090, 6089, 4896, 5101, 5101, 6494, 6256, 4559, 5101, 5101, 6090, 5101, 5101, 6090, 4561, 6089, 4561, 5101, 6089, 4560, 5537, 6089, 5101, 5537, 6574, 6752, 4888, 4577, 5716, 5997, 6579, 5101, 5844, 5037, 5101, 5101, 5101, 6196, 5101, 6462, 6465, 6463, 4869, 5826, 5829, 6587, 4489, 4646, 6598, 6591, 6597, 6593, 6605, 6602, 6607, 6611, 6613, 6617, 6619, 6628, 6625, 6632, 6621, 6635, 6639, 6640, 6644, 6647, 6654, 6653, 6651, 6658, 6661, 6665, 5101, 6574, 6723, 5101, 5876, 6281, 5670, 5418, 5421, 5101, 5101, 5101, 6469, 5107, 5101, 4975, 5101, 4976, 6672, 5101, 5101, 5101, 6682, 6494, 5101, 5101, 5101, 6695, 6680, 5313, 6686, 5101, 5877, 5684, 4434, 6246, 5101, 5101, 6163, 5101, 5101, 5101, 6692, 5101, 5101, 6495, 5101, 5101, 6703, 5101, 5101, 5101, 6713, 5101, 5101, 6718, 6717, 4834, 6722, 5101, 5418, 5422, 5101, 6727, 6734, 5101, 5881, 5357, 5337, 6746, 5101, 5101, 5101, 6495, 6378, 5101, 6222, 6745, 5101, 5889, 5128, 5074, 4442, 6224, 6747, 5101, 5877, 5615, 5671, 5876, 5101, 5879, 5101, 5899, 6230, 5101, 5101, 6089, 5101, 5101, 4892, 5101, 5412, 5002, 6734, 5101, 5101, 6711, 5101, 5101, 5253, 5101, 5877, 5877, 5877, 5101, 5101, 5101, 6771, 5101, 5101, 6575, 5642, 4635, 5411, 6089, 5101, 4889, 5258, 5101, 5252, 4561, 5101, 5101, 6090, 5252, 4561, 5876, 5876, 5101, 5101, 5101, 5914, 6353, 6148, 5106, 4974, 5101, 5101, 5972, 5101, 4989, 5101, 6165, 5425, 5101, 6688, 5107, 5101, 6111, 5724, 6759, 5725, 4561, 5101, 5101, 5983, 5994, 5101, 5190, 5879, 5101, 5101, 5101, 5344, 5376, 5106, 5101, 5101, 5413, 6463, 5879, 5102, 6775, 6767, 5101, 5101, 5997, 5101, 5101, 5101, 4811, 4583, 6765, 5101, 5101, 5101, 5101, 6098, 5420, 5101, 5998, 5101, 5101, 5101, 4818, 5109, 5101, 5413, 5537, 5101, 5101, 6165, 5101, 6111, 6564, 5101, 5998, 5101, 6769, 5101, 5101, 6132, 6137, 5101, 6098, 5101, 5101, 6033, 6031, 6039, 5105, 5101, 5109, 5101, 4863, 5101, 6776, 5101, 5101, 5101, 6035, 4434, 5101, 6161, 5536, 5101, 5036, 5102, 5101, 5101, 6088, 5101, 5101, 5412, 6089, 1048576, 1073741824, 0, 0, 0, -872415232, 4194560, 4196352, 270532608, 2097152, 4194304, 117440512, 134217728, 4194304, 16777216, 4194432, 3145728, 16777216, 134217728, 536870912, 1073741824, 0, 541065216, 541065216, -2143289344, -2143289344, 4194304, 4194304, 4196352, -2143289344, 4194304, 4194432, 37748736, 541065216, -2143289344, 4194304, 4194304, 4194304, 4194304, 37748736, 4194304, 4194304, 4198144, 4196352, 8540160, 4194304, 4194304, 4194304, 4196352, 276901888, 4194304, 4194304, 8425488, 4194304, 1, 0, 1024, 1024, 0, 1024, 742391808, 239075328, -1405091840, 742391808, 742391808, 775946240, 239075328, 171966464, 775946240, 171966464, 171966464, 171966464, 171966464, -1405091840, 775946240, 775946240, -1405091840, -1371537408, 775946240, 775946240, 775946240, 171966464, 239075328, 239075328, 171966464, 775946240, -1371537408, 775946240, 775946240, -1371537408, 239075328, 775946240, 775946240, 775946240, 775946240, 4718592, 64, 4718592, 2097216, 4720640, 541589504, 4194368, 541589504, 4194400, 4194368, 541065280, 4194368, -2143289280, 4194368, -2143285440, -2143285408, -2143285408, -2109730976, -2143285408, -2143285408, -2143285408, -2143285408, 776470528, -2143285408, -2109730976, 775946336, 775946304, 776470528, 775946304, -1908404384, 2, 4, 8, 262144, 0, 0, 0, 0x80000000, 8, 262144, 262144, 1048576, 0, 128, 4096, 0, 4194304, 128, 128, 0, 1048576, 0, 0, 1536, 1792, 0, 0, 1, 2, 4, 128, 2097152, 8192, 8392704, 0, 0, 1, 4, 8, 262144, 536870912, 64, 64, 32, 96, 96, 96, 96, 128, 1536, 524288, 96, 64, 524288, 524288, 1536, 1024, 0, 0, 0, 29, 96, 1048576, 128, 128, 128, 128, 2048, 2048, 2048, 2048, 2048, 2048, 0, 96, 524288, 96, 64, 0, 0, 128, 1024, 524288, 64, 64, 96, 96, 524288, 524288, 4100, 1024, 100680704, 96, 524288, 64, 96, 524288, 64, 80, 528, 524304, 1048592, 2097168, 268435472, 16, 16, 2, 536936448, 16, 262160, 16, 536936448, 16, 17, 17, 20, 16, 48, 16, 16, 20, 560, 24, 560, 48, 2097680, 3145744, 1048592, 1048592, 2097168, 16, 1049104, 2228784, 2097168, 2097168, 16, 16, 16, 16, 20, 48, 48, 3146256, 2097680, 1048592, 16, 16, 16, 28, 0, 2097552, 3146256, 16, 16, 16, 21, 16, 16, 28, 16, 0, 16, 0, -2046820352, 0, 0, 2, 2, 2, 2098064, 17, 21, 266240, 1048576, 67108864, 0x80000000, 0, 0, 64, 65536, 1048576, 0, 16, 16, 163577856, 17, 528, 528, 16, 528, -161430188, -161429676, -161429676, -161430188, -161429680, -161430188, -161430188, -161429680, -161429676, -161349072, -161429675, -161349072, -161349072, -161349072, -161349072, -161347728, -161347728, -161347728, -161347728, -161298572, -160774288, -160299084, -161298572, -161298576, -160299088, -161298576, -160774284, -160774284, -161298572, -161298572, -161298572, -161298572, 112, 21, 53, 146804757, 146812949, 146862101, 146863389, -161429676, -160905388, -161429676, -161429676, -161429676, -161429676, -161429675, -161349072, 146863421, 148960541, 146863389, 146863389, 148960541, 146863421, 148960541, 148960541, -161429740, -161429676, -160905388, -161298572, -161298572, -18860267, -160774284, -18729163, 0, 0, 1, 6, 8, 16, 262144, 0, 0, 1, 8, 0, 24, 0, 0, 1, 14, 16, 32, 1024, 32768, 100663296, -1073741824, 0, 0, 0, 150528, 131072, 16777216, 0, 0, 1, 102, 1, 32768, 131328, 131072, 524288, 2097152, 8388608, 16777216, 164096, 0, 0, 0, 1007, 0, 1073741825, 0x80000000, 0x80000000, 1073741824, 8, 0, 0, 58368, 0, 0, 65536, 1048576, 4096, 1048576, 512, 512, 9476, 134218240, 0, 1073741824, 2621440, 1073741824, 0x80000000, 0x80000000, 0, 0, 66048, 0, 0, 0, 67108864, 0, 0, 0, 16384, 0, 0, 0, 8, 0, 0, 0, 9, 4456448, 8, 16777216, 1073774592, 1226014816, 100665360, 100665360, 100665360, 100665360, -2046818288, 1091799136, 1091799136, 1091803360, 1091799136, 1091799136, -2044196848, 1091799136, 1091799136, 1091799136, 1091799136, 1091799136, 1158908000, 1158908001, 1192462432, 1192462448, 1192462448, 1192462448, 1192462448, 1200851056, 1091799393, 1200851056, 1200851056, 1091799393, 1200851056, 1200851056, 1200851056, 1192462448, 1870638912, 1870638912, 1870655296, 1870638912, 1870655296, 1870655296, 1870655296, 1870655296, 1870655296, 1870655312, 1870655316, 1870655316, 1870655316, 1870655317, 1870655348, 1870655316, 1870655316, 1870655312, 1870655312, 1879027568, 1879043952, 1870655316, 1870655316, 1870655316, 1870638928, 1879043952, 1879043956, 0, 0, 1, 12288, 0, 229440, 1048576, 1224736768, 100663296, 0, 0, 0, 1024, 0, 0, 8192, 0, 0, 0, 576, 0, 231488, 1090519040, 0, 0, 0, 2048, 0, 0, 134217728, 0, 1157627904, 1191182336, 0, 0, 131584, 268435456, 49152, 0, 0, 0, 134217728, 0, 0, 0, 16, 0, 0, 0, 13, 0, 9437184, 231744, 0, 0, 235712, 0, 0, 131328, 0, 0, 131072, 32768, 0, 0, 134217728, 0, 520000, 7864320, 1862270976, 0, 0, 0, 4096, 0, 0, 0, 1862270976, 1862270976, 1862270976, 0, 16252928, 0, 0, 0, 8192, 64, 98304, 1048576, 150994944, 83886080, 117440512, 0, 0, 2, 4, 16, 32, 256, 1024, 8192, 33554432, 0, 0, 64, 256, 3584, 8192, 16384, 65536, 262144, 524288, 1048576, 2097152, 4194304, 0x80000000, 8192, 98304, 393216, 524288, 1048576, 1048576, 2097152, 4194304, 251658240, 536870912, 8192, 16384, 98304, 393216, 251658240, 536870912, 1073741824, 0, 0, 2097152, 0, 0, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 3, 240, 0, 83886080, 117440512, 64, 0, 2, 0, 0, 524288, 524288, 524288, 524288, 256, 1536, 2048, 8192, 16384, 256, 1536, 8192, 65536, 262144, 524288, 2097152, 67108864, 4194304, 16777216, 100663296, 134217728, 536870912, 524288, 2097152, 134217728, 268435456, 536870912, 1073741824, 0, 0, 524288, 2097152, 0, 0, 1048576, 2097152, 67108864, 1073741824, 0, 0, 1536, 65536, 262144, 524288, 33554432, 0, 1024, 65536, 262144, 2097152, 2097152, 1073741824, 0, 0, 2, 8, 16, 32, 0, 8192, 4096, 0, 0, 605503, 1066401792, 9476, 512, 0, 32, 384, 8192, 4194312, 4194312, 541065224, 4194312, 4194312, 4194312, 4194312, 4194344, -869654016, -869654016, 4203820, -869654016, -869654016, -869654016, -869654016, 1279402504, 1279402504, 1279402504, 1279402504, 2143549415, 2143549415, 2143549415, 2143549415, 2143549423, 2143549423, 2143549423, 2143549423, 2143549423, 2143549423, 0, 0, 2, 16384, 32768, 260, 512, 0, 0, 0, 65536, 0, 0, 0, 384, 8192, 0, 32, 512, 0, 1050624, 262144, 512, 1275208192, 139264, 1275068416, 0, 0, 4, 128, 1024, 2048, 16384, 262144, 8, 4194304, 0, 0, 0, 82432, 0, 40, 0, 0, 4, 256, 1024, 98304, 131072, 16777216, 268435456, 0, 0, 300, 4203520, 0, 0, 2097152, 1073741824, 0x80000000, 0, 0, 520, 4333568, 1275068416, 0, 0, 4194304, 1024, 0, 4096, 8192, 0, 0, 0, 520, 520, 0, 0, 0, 164096, 999, 29619200, 2113929216, 0, 0, 0, 1007, 1007, 1007, 0, 0, 8, 124160, 32, 512, 0, 2048, 524288, 0, 536870912, 0, 139264, 0, 0, 0, 139264, 0, 40, 0, 2621440, 0, 0, 0x80000000, 1610612736, 0, 0, 0, 229376, 0, 40, 0, 524288, 2097152, 1073741824, 44, 0, 0, 0, 262144, 0, 0, 16384, 229376, 4194304, 25165824, 100663296, 402653184, 1610612736, 0, 110, 110, 110, 0, 0, 8388608, 8388608, 8192, 33554432, 67108864, 134217728, 1073741824, 0, 0x80000000, 0, 0, 0, 12545, 25165824, 33554432, 67108864, 402653184, 536870912, 0, 104, 104, 104, 8192, 33554432, 134217728, 0, 0, 8388608, 134217728, 1073741824, 0, 229376, 25165824, 33554432, 402653184, 536870912, 0, 0, 256, 1024, 65536, 16777216, 268435456, 0, 0, 0, 524288, 0, 0, 0, 64, 0, 0, 0, 128, 0, 0, 0, 256, 0, 0, 0, 300, 524288, 2097152, 0x80000000, 0, 0, 1, 6, 32, 64, 256, 512, 256, 1024, 4096, 8192, 65536, 2, 4, 32, 64, 256, 1024, 0, 2, 4, 256, 1024, 65536, 4, 64, 256, 1024, 0, 0, 8, 8388608, 0, 98304, 131072, 25165824, 268435456, 536870912, 0, 0, 8388608, 4096, 0, 0, 8, 8, 8, 0, 2048, 524288, 67108864, 536870912, 32, 4100, 67108864, 0, 32768, 0, 32768, 0, 1049088, 0, 134348800, 270532608, 0, 1049088, 1049088, 8192, 1049088, 12845065, 12845065, 12845065, 12845065, 147193865, 5505537, 5591557, 5587465, 5587457, 5587457, 147202057, 5587457, 5587457, 5591557, 5587457, 13894153, 13894153, 13894153, 13894153, 81003049, 13894153, -1881791493, -1881791493, -1881791493, -1881791493, 0, 0, 8, 33554432, 262144, 0, 33554432, 1024, 0, 4, 0, 0, 0, 867647, 1, 5505024, 0, 0, 15, 16, 32, 192, 86528, 9, 0, 0, 16, 8192, 0, 0, 23, 0, 75497472, 0, 0, 0, 1048576, 5505024, -1887436800, 0, 0, 0, 2097152, 268435456, 0, 0, 4096, 8192, 67108864, 0, 0, 262144, 4194304, 8388608, 0, 0, 33554432, 8192, 0, 0, 288, 8388608, 0, 0, 0, 81920, 0, 0, 24, 282624, 64, 896, 8192, 131072, 262144, 1048576, 16777216, 33554432, -1946157056, 0, 0, 0, 2621440, 0, 131072, 0, 32, 0, 0, 2048, 3145728, 0, 16384, 65536, 0, 0, 268435456, 32, 64, 384, 512, 5120, 8192, 0, 64, 0, 2048, 1048576, 0, 0, 32, 64, 384, 8192, 131072, 0, 0, 32768, 134217728, 0, 0, 8, 32, 64, 1024, 2048, 0, 2, 8, 32, 384, 8192, 131072, 33554432, 131072, 1048576, 33554432, 134217728, 0x80000000, 0, 0, 2048, 524288, 536870912, 0, 1073741824, 0, 131072, 33554432, 0x80000000, 0, 0, 33554432, 1073741824, 0, 32, 0, 524288, 0, 0, 67108864, 64, 64, 0, 96, 96, 0, 524288, 524288, 524288, 64, 64, 64, 64, 96, 96, 96, 0, 0, 0, 28, 0, 8396800, 4194304, 134217728, 2048, 134217728, 0, 0, 32, 1, 0, 8396800, 0, 0, 32, 64, 128, 1024, 2048, 262144, 0, 16384, 0, 2, 4, 64, 128, 3840, 16384, 19922944, 2080374784, 0, 16384, 16384, 16777216, 16384, 32768, 1048576, 2097152, 4194304, 16777216, 524288, 268567040, 16384, 2113544, 68489237, 72618005, 68423701, 68423701, 68423701, 68489237, 68423701, -2079059883, -2079059947, 68423701, 85200917, 68423701, 68423701, 68423701, 68423701, 68423765, -2079059883, 68425749, 68423703, 69488664, 85200919, 69488664, 69488664, 69488664, 69488664, 70537244, 70537245, 70537245, 70537245, 70537309, 70537245, -2076946339, -2076946403, 70537245, -2076946339, 70537245, 70537245, 70537245, 70537245, 70539293, -2022351745, -2022351745, -2022351617, -2022351745, -2022351617, -2022351617, -2022351617, -2022351617, -2022351617, -2022351617, -2022351745, -2022351617, -2022351617, 0, 0, 40, 67108864, 331776, 83886080, 0, 0, 59, 140224, 5505024, 5242880, -2080374784, -2080374784, 268288, 29, 0, 284672, 0, 0, 68157440, 137363456, 0, 66, 66, 0, 63, 64, 351232, 63, 192, 351232, 7340032, -2030043136, 0, 0, 0, 4194304, 1, 1024, 32, 64, 256, 32768, 65536, 512, 131072, 268435456, 0, 0, 134348800, 134348800, 16, 4096, 262144, 1048576, 4194304, 8388608, 16777216, 33554432, 5242880, 0, 7, 0, 0, 142606336, 0, -872415232, 0, 0, 0, 131072, 0, 0, 0, 999, 259072, 4194304, 25165824, 0, 20480, 0, 0, 64, 256, 1536, 8192, 16384, 0, 12, 3145728, 0, 0, 0, 3145728, 64, 3072, 20480, 65536, 262144, 32, 192, 3072, 20480, 4, 1048576, 0, 0, 128, 131072, 0, 134218752, 0, 0, 128, 134217728, 5242880, 0, 6, 0, 0, 16384, 65536, 7340032, 50331648, 32, 192, 1024, 2048, 4096, 8192, 65536, 32768, 65536, 4194304, 16777216, 0x80000000, 0, 0, 1, 4, 0, 0, 256, 1536, 65536, 65536, 2097152, 4194304, 50331648, 0x80000000, 32, 192, 1024, 65536, 268435456, 0, 0, 32768, 4194304, 16777216, 0, 0, 184549376, 0, 0, 243269632, 0, 0, 32768, 131072, 131072, 0, 32768, 32768, 1, 2, 4, 2097152, 16777216, 134217728, 268435456, 1073741824, 0x80000000, 128, 2097152, 4194304, 50331648, 0, 0, 0, 8388608, 0, 0, 0, 768, 2, 4, 50331648, 0, 0, 536870912, 9216, 0, 0, 0, 49152, 2, 4, 128, 50331648, 0, 0, 4096, 4194304, 268435456, 0, 0, 1075838976, 2097152, 2097152, 268435456, 4194432, 268435968, 268435968, 1073743872, 268435968, 0, 128, 6144, 0, 229376, 128, 268435968, 268436032, 256, 256, 536871168, 256, 256, 256, 256, 257, 256, 384, -1879046336, -1879046334, 1073744256, -1879046334, -1879046326, -1879046334, -1879046334, -1879046326, -1879046326, -1845491902, -1878784182, 268444480, 268444480, 268436288, 268436288, 268436288, 268436288, 268436289, 268444480, 268444480, 268444480, 268444480, 2100318149, 2100318149, 2100318149, 2100318149, 2100326341, 2100326341, 2100318149, 2100326341, 2100326341, 0, 0, 256, 2048, 2048, 0, 0, 0, 4, 8, 262144, 134217728, 1, 1024, 0, 4096, 0, 64, 1856, 0x80000000, 0, 0, 256, 65536, 2432, 0, 1864, 0, 1, 2, 16, 32, 64, 0, 301989888, 0, 262144, 131072, 0, 0, 832, 8192, 0, 1, 2, 56, 64, 896, 0, 1, 4036, 19939328, 2080374784, 2080374784, 0, 0, 0, 16252928, 1, 16, 32, 128, 512, 2304, 0, 8, 0, 512, 301989888, 0, 0, 262144, 524288, 134217728, 536870912, 0, 24576, 0, 0, 0, 33554432, 0, 0, 0, 32768, 0, 0, 2097152, 134217728, 0, 32768, 196608, 0, 0, 0, 1, 128, 512, 2048, 524288, 268435456, 536870912, 0, 33554432, 262144, 8192, 0, 0, 256, 8388608, 0, 0, 1, 4, 128, 3584, 16384, 3145728, 16777216, 67108864, 134217728, 805306368, 1073741824, 0, 0, 1024, 2048, 16384, 3145728, 0, 8192, 0, 8192, 0, 536870912, 524288, 536870912, 1073741824, 0, 1, 2, 112, 128, 3072, 2048, 3145728, 16777216, 536870912, 1073741824, 0, 0, 2097152, 16777216, 1073741824, 0, 0, 0, 8192, 8192, 8192, 9216, 33554432, 32768, 33554432, 0, 0, 262144, 0, 16777216, 0, 16777216, 16777216, 16777216, 16777216, 0, 0, 2097152, 16777216, 0, 0, 16777216, 268500992, 4243456, 0, 0, 512, 65536, 0, 4096, 4096, 0, 4096, 4096, 4096, 4096, 0, 0, 0, 32, 0, 0, 0, 41, 0, 4243456, 4096, 12289, 1073754113, 12289, 12289, 1124073472, 12289, 12289, 1098920193, 1098920193, 1124073488, 1124073472, 1124073472, 1258292224, 1124073472, 1124073474, 1124073472, 1124073472, 1124073472, 1124073472, 1124073472, 1392574464, 1124073472, 12289, 1124085761, 1124085761, 1124085761, 1124085761, 1132474625, 1098920209, 1132474625, 1132474625, 1098920209, 1132474625, 1132474625, 1132474625, 1132474625, 1400975617, 1124085777, 1124085761, 1124085761, 1258304513, 2132360255, 2132360255, 2132622399, 2132360255, 2132622399, 2132622399, 2140749119, 2141011263, 2132622399, 2132622399, 2132622399, 2132622399, 2132360255, 2141011263, 2141011263, 0, 0, 512, 131072, 0, 128, 131072, 1024, 134217728, 0, 0, 0, 50331648, 1073741824, 0, 1, 4, 64, 128, 3584, 318767104, 0, 0, 0, 268435456, 0, 12289, 0, 0, 0, 159383552, 25165824, 0, 0, 0, 536870912, 0, 0, 0, 24576, 58720256, 0, 0, 12305, 13313, 0, 0, 0, 1073741824, 0, 0, 0, 12561, 0, 78081, 327155712, 0, 0, 0, 1275068416, 0, 605247, 1058013184, 1073741824, 1073741824, 8388608, 0, 0, 503616, 7864320, 867391, 1058013184, 1073741824, 0, 1, 6, 96, 384, 512, 1024, 4096, 8192, 16384, 229376, 25165824, 33554432, 268435456, 536870912, 0, 867647, 1066401792, 0, 0, 0, 512, 1048576, 0, 0, 9, 8388608, 12288, 0, 0, 0, 512, 2760704, 77824, 0, 0, 0, 1024, 2048, 3145728, 2048, 77824, 524288, 1048576, 0, 0, 0, 512, 0, 1048576, 0, 1, 30, 32, 1024, 2048, 1024, 2048, 339968, 524288, 1048576, 16777216, 100663296, 134217728, 805306368, 1073741824, 1024, 2048, 12288, 65536, 0, 65536, 0, 0, 19947520, 0, 0, 0, 16777216, 0, 0, 0, 5, 1024, 2048, 12288, 327680, 524288, 33554432, 134217728, 536870912, 1073741824, 14, 16, 1024, 4096, 8192, 229376, 0, 2, 16384, 4194304, 0x80000000, 0, 0, 0, 8, 0, 65536, 262144, 7340032, 50331648, 67108864, 0x80000000, 4096, 65536, 262144, 524288, 1048576, 33554432, 256, 0, 256, 0, 256, 1, 12, 1024, 134217728, 262144, 134217728, 536870912, 0, 0, 268435456, 1, 4, 8, 134217728, 4, 8, 536870912, 0, 2, 16, 64, 128, 0, 0, 262144, 536870912, 0, 0, 1073741824, 32768, 0, 8, 32, 512, 4096, 9437184, 0, 0, 1048576, 2097152, 4194304, 67108864, 134217728, 0, 1024, 137363456, 66, 25165824, 26214400, 92274688, 92274688, 25165952, 92274688, 25165824, 25165824, 92274688, 25165824, 25165824, 92274688, 92274688, 92274720, 92274688, 25165824, 92274688, 93323264, 25165890, 100721664, 100721664, 25165890, 100721928, 100721928, 100787464, 100853000, 100721928, 100721928, 125977600, 125977600, 125977600, 125977600, 127026176, 125977600, 125846528, 125846528, 125846560, 125846528, 125846528, 125846528, 126895104, 125846528, 125977600, 127026176, 125977600, 125977600, 127026176, 127026176, 281843, 281843, 1330419, 281843, 1330419, 281843, 1330419, 1330419, 281843, 281843, 281843, 5524723, 39079155, 72633587, 5524723, 5524723, 5524723, 5524723, 93605107, 72633587, 72633587, 92556531, 93605107, 127290611, 127290611, 97799411, 127290611, 131484915, 0, 0, 1536, 0x80000000, 0, 0, 17408, 33554432, 0, 1, 12, 1024, 262144, 0, 58624, 0, 0, 1536, 0, 189696, 0, 0, 0, 1792, 0x80000000, 0, 148480, 50331648, 0, 1, 14, 1024, 4096, 65536, 524288, 240, 19456, 262144, 0, 0, 19456, 262144, 0, 4194304, 0, 0, 1024, 2097152, 0, 0, 0, 150528, 0, 0, 0, 512, 4096, 8192, 131072, 0, 57344, 0, 0, 0, 2048, 100663296, 0, 0, 256, 0, 65536, 524288, 1048576, 33554432, 67108864, 2, 48, 64, 128, 3072, 16384, 262144, 0, 0, 32, 4096, 8192, 131072, 1048576, 8388608, 33554432, 134217728, 2048, 262144, 0, 0, 2048, 268435456, 16, 64, 128, 262144, 0, 0, 32768, 65536, 131072, 0, 1, 2, 16, 64, 0
+];
+
+XQueryParser.TOKEN =
+[
+ "(0)",
+ "PragmaContents",
+ "DirCommentContents",
+ "DirPIContents",
+ "CDataSection",
+ "Wildcard",
+ "EQName",
+ "URILiteral",
+ "IntegerLiteral",
+ "DecimalLiteral",
+ "DoubleLiteral",
+ "StringLiteral",
+ "PredefinedEntityRef",
+ "'\"\"'",
+ "EscapeApos",
+ "ElementContentChar",
+ "QuotAttrContentChar",
+ "AposAttrContentChar",
+ "PITarget",
+ "NCName",
+ "QName",
+ "S",
+ "S",
+ "CharRef",
+ "CommentContents",
+ "EOF",
+ "'!'",
+ "'!='",
+ "'\"'",
+ "'#'",
+ "'#)'",
+ "'$'",
+ "'%'",
+ "''''",
+ "'('",
+ "'(#'",
+ "'(:'",
+ "')'",
+ "'*'",
+ "'*'",
+ "'+'",
+ "','",
+ "'-'",
+ "'-->'",
+ "'.'",
+ "'..'",
+ "'/'",
+ "'//'",
+ "'/>'",
+ "':'",
+ "':)'",
+ "'::'",
+ "':='",
+ "';'",
+ "'<'",
+ "'<!--'",
+ "'</'",
+ "'<<'",
+ "'<='",
+ "'<?'",
+ "'='",
+ "'>'",
+ "'>='",
+ "'>>'",
+ "'?'",
+ "'?>'",
+ "'@'",
+ "'NaN'",
+ "'['",
+ "']'",
+ "'after'",
+ "'all'",
+ "'allowing'",
+ "'ancestor'",
+ "'ancestor-or-self'",
+ "'and'",
+ "'any'",
+ "'append'",
+ "'array'",
+ "'as'",
+ "'ascending'",
+ "'at'",
+ "'attribute'",
+ "'base-uri'",
+ "'before'",
+ "'boundary-space'",
+ "'break'",
+ "'by'",
+ "'case'",
+ "'cast'",
+ "'castable'",
+ "'catch'",
+ "'check'",
+ "'child'",
+ "'collation'",
+ "'collection'",
+ "'comment'",
+ "'constraint'",
+ "'construction'",
+ "'contains'",
+ "'content'",
+ "'context'",
+ "'continue'",
+ "'copy'",
+ "'copy-namespaces'",
+ "'count'",
+ "'decimal-format'",
+ "'decimal-separator'",
+ "'declare'",
+ "'default'",
+ "'delete'",
+ "'descendant'",
+ "'descendant-or-self'",
+ "'descending'",
+ "'diacritics'",
+ "'different'",
+ "'digit'",
+ "'distance'",
+ "'div'",
+ "'document'",
+ "'document-node'",
+ "'element'",
+ "'else'",
+ "'empty'",
+ "'empty-sequence'",
+ "'encoding'",
+ "'end'",
+ "'entire'",
+ "'eq'",
+ "'every'",
+ "'exactly'",
+ "'except'",
+ "'exit'",
+ "'external'",
+ "'first'",
+ "'following'",
+ "'following-sibling'",
+ "'for'",
+ "'foreach'",
+ "'foreign'",
+ "'from'",
+ "'ft-option'",
+ "'ftand'",
+ "'ftnot'",
+ "'ftor'",
+ "'function'",
+ "'ge'",
+ "'greatest'",
+ "'group'",
+ "'grouping-separator'",
+ "'gt'",
+ "'idiv'",
+ "'if'",
+ "'import'",
+ "'in'",
+ "'index'",
+ "'infinity'",
+ "'inherit'",
+ "'insensitive'",
+ "'insert'",
+ "'instance'",
+ "'integrity'",
+ "'intersect'",
+ "'into'",
+ "'is'",
+ "'item'",
+ "'json'",
+ "'json-item'",
+ "'key'",
+ "'language'",
+ "'last'",
+ "'lax'",
+ "'le'",
+ "'least'",
+ "'let'",
+ "'levels'",
+ "'loop'",
+ "'lowercase'",
+ "'lt'",
+ "'minus-sign'",
+ "'mod'",
+ "'modify'",
+ "'module'",
+ "'most'",
+ "'namespace'",
+ "'namespace-node'",
+ "'ne'",
+ "'next'",
+ "'no'",
+ "'no-inherit'",
+ "'no-preserve'",
+ "'node'",
+ "'nodes'",
+ "'not'",
+ "'object'",
+ "'occurs'",
+ "'of'",
+ "'on'",
+ "'only'",
+ "'option'",
+ "'or'",
+ "'order'",
+ "'ordered'",
+ "'ordering'",
+ "'paragraph'",
+ "'paragraphs'",
+ "'parent'",
+ "'pattern-separator'",
+ "'per-mille'",
+ "'percent'",
+ "'phrase'",
+ "'position'",
+ "'preceding'",
+ "'preceding-sibling'",
+ "'preserve'",
+ "'previous'",
+ "'processing-instruction'",
+ "'relationship'",
+ "'rename'",
+ "'replace'",
+ "'return'",
+ "'returning'",
+ "'revalidation'",
+ "'same'",
+ "'satisfies'",
+ "'schema'",
+ "'schema-attribute'",
+ "'schema-element'",
+ "'score'",
+ "'self'",
+ "'sensitive'",
+ "'sentence'",
+ "'sentences'",
+ "'skip'",
+ "'sliding'",
+ "'some'",
+ "'stable'",
+ "'start'",
+ "'stemming'",
+ "'stop'",
+ "'strict'",
+ "'strip'",
+ "'structured-item'",
+ "'switch'",
+ "'text'",
+ "'then'",
+ "'thesaurus'",
+ "'times'",
+ "'to'",
+ "'treat'",
+ "'try'",
+ "'tumbling'",
+ "'type'",
+ "'typeswitch'",
+ "'union'",
+ "'unique'",
+ "'unordered'",
+ "'updating'",
+ "'uppercase'",
+ "'using'",
+ "'validate'",
+ "'value'",
+ "'variable'",
+ "'version'",
+ "'weight'",
+ "'when'",
+ "'where'",
+ "'while'",
+ "'wildcards'",
+ "'window'",
+ "'with'",
+ "'without'",
+ "'word'",
+ "'words'",
+ "'xquery'",
+ "'zero-digit'",
+ "'{'",
+ "'{{'",
+ "'{|'",
+ "'|'",
+ "'||'",
+ "'|}'",
+ "'}'",
+ "'}}'"
+];
+
+},{}],"/node_modules/xqlint/lib/tree_ops.js":[function(_dereq_,module,exports){
+'use strict';
+
+exports.TreeOps = {
+ flatten: function(node){
+ var that = this;
+ var value = '';
+ if(!node) {
+ throw new Error('Invalid node found');
+ } else if (node.value === undefined) {
+ node.children.forEach(function(child){
+ value += that.flatten(child);
+ });
+ } else {
+ value += node.value;
+ }
+ return value;
+ },
+
+ concat: function(obj1, obj2, copy){
+ var result = copy ? {} : obj1;
+ if(copy){
+ Object.keys(obj1).forEach(function(key){
+ result[key] = obj1[key];
+ });
+ }
+ var keys = Object.keys(obj2);
+ keys.forEach(function(key){
+ result[key] = obj2[key];
+ });
+ return result;
+ },
+
+ removeParentPtr: function(ast){
+ if(ast.getParent !== undefined) {
+ delete ast.getParent;
+ }
+ for(var i in ast.children) {
+ var child = ast.children[i];
+ this.removeParentPtr(child);
+ }
+ },
+
+ inRange: function(p, pos, exclusive){
+ if(p && p.sl <= pos.line && pos.line <= p.el) {
+ if(p.sl < pos.line && pos.line < p.el) {
+ return true;
+ } else if(p.sl === pos.line && pos.line < p.el) {
+ return p.sc <= pos.col;
+ } else if(p.sl === pos.line && p.el === pos.line) {
+ return p.sc <= pos.col && pos.col <= p.ec + (exclusive ? 1 : 0);
+ } else if(p.sl < pos.line && p.el === pos.line) {
+ return pos.col <= p.ec + (exclusive ? 1 : 0);
+ }
+ }
+ },
+
+ findNode: function(ast, pos) {
+ if(!ast) {
+ return;
+ }
+ var p = ast.pos;
+ if(this.inRange(p, pos) === true) {
+ for(var i in ast.children) {
+ var child = ast.children[i];
+ var n = this.findNode(child, pos);
+ if(n !== undefined) {
+ return n;
+ }
+ }
+ return ast;
+ } else {
+ return;
+ }
+ },
+
+ astAsXML: function(node, indent){
+ var result = '';
+ indent = indent ? indent : '';
+ if(node.value) {
+ result += (indent + '<' + node.name + '>' + node.value + '</' + node.name + '>\n');
+ }
+ result += indent + '<' + node.name + '>\n';
+ var that = this;
+ node.children.forEach(function(child){
+ result += that.astAsXML(child, indent + ' ');
+ });
+ result += indent + '</' + node.name + '>\n';
+ return result;
+ }
+};
+},{}],"/node_modules/xqlint/lib/xqdoc/parse_comment.js":[function(_dereq_,module,exports){
+'use strict';
+
+exports.parseComment = function(comment){
+ comment = comment.trim();
+ var isXQDoc = comment.substring(0, 3) === '(:~';
+ if(isXQDoc){
+ var lines = comment.split('\n');
+ var ann = {
+ description: ''
+ };
+ lines.forEach(function(line, index){
+ if(index === 0) {
+ line = line.substring(3);
+ }
+ line = line.trim();
+ if(line[0] === ':') {
+ line = line.substring(1);
+ }
+ line = line.trim();
+ ann.description += ' ' + line;
+ });
+ ann.description = ann.description.trim();
+ ann.description = ann.description.substring(0, ann.description.length - 2).trim();
+ return ann;
+ }
+};
+},{}],"/node_modules/xqlint/lib/xqdoc/xqdoc.js":[function(_dereq_,module,exports){
+var _ = _dereq_('lodash');
+var parseComment = _dereq_('./parse_comment').parseComment;
+
+exports.XQDoc = function(ast){
+ 'use strict';
+
+ var doc = {};
+
+ this.getDoc = function(){
+ return doc;
+ };
+
+ this.WS = function(node){
+ if(node.value.trim().substring(0, 3) === '(:~') {
+ node.getParent.comment = parseComment(node.value);
+ }
+ };
+
+ this.AnnotatedDecl = function(node){
+ this.visitChildren(node);
+ node.comment = node.getParent.comment;
+ node.getParent.comment = undefined;
+ };
+
+ this.XQuery = function(node){
+ this.visitChildren(node);
+ };
+
+ this.getXQDoc = function(sctx){
+ var doc = {
+ moduleNamespace: sctx.moduleNamespace,
+ description: sctx.description,
+ variables: [],
+ functions: []
+ };
+
+ _.forEach(sctx.variables, function(variable){
+ var varDecl = _.cloneDeep(variable.qname);
+ varDecl.annotations = variable.annotations;
+ varDecl.description = variable.description;
+ varDecl.type = variable.type;
+ varDecl.occurrence = variable.occurrence;
+ doc.variables.push(varDecl);
+ });
+
+ _.forEach(sctx.functions, function(fn, key){
+ if(key.substring(0, 'http://www.w3.org/2001/XMLSchema#'.length) === 'http://www.w3.org/2001/XMLSchema#') {
+ return;
+ }
+
+ var tokens = key.split('#');
+ doc.functions.push({
+ name: tokens[0],
+ uri: tokens[1],
+ params: fn.params
+ });
+ });
+
+ return doc;
+ };
+
+ this.visit = function (node) {
+ var name = node.name;
+ var skip = false;
+
+ if (typeof this[name] === 'function') {
+ skip = this[name](node) === true;
+ }
+
+ if (!skip) {
+ this.visitChildren(node);
+ }
+ };
+
+ this.visitChildren = function (node, handler) {
+ for (var i = 0; i < node.children.length; i++) {
+ var child = node.children[i];
+ if (handler !== undefined && typeof handler[child.name] === 'function') {
+ handler[child.name](child);
+ } else {
+ this.visit(child);
+ }
+ }
+ };
+
+ this.visit(ast);
+};
+
+},{"./parse_comment":"/node_modules/xqlint/lib/xqdoc/parse_comment.js","lodash":"/node_modules/xqlint/node_modules/lodash/index.js"}],"/node_modules/xqlint/lib/xqlint.js":[function(_dereq_,module,exports){
+'use strict';
+
+var _ = _dereq_('lodash');
+
+var JSONiqParser = _dereq_('./parsers/JSONiqParser').JSONiqParser;
+var XQueryParser = _dereq_('./parsers/XQueryParser').XQueryParser;
+var JSONParseTreeHandler = _dereq_('./parsers/JSONParseTreeHandler').JSONParseTreeHandler;
+var Translator = _dereq_('./compiler/translator').Translator;
+var StyleChecker = _dereq_('./formatter/style_checker').StyleChecker;
+var XQDoc = _dereq_('./xqdoc/xqdoc').XQDoc;
+var completer = _dereq_('../lib/completion/completer');
+var TreeOps = _dereq_('./tree_ops').TreeOps;
+
+var createStaticContext = exports.createStaticContext = function(){
+ var StaticContext = _dereq_('./compiler/static_context').StaticContext;
+ return new StaticContext();
+};
+
+var convertPosition = function (code, begin, end) {
+ var before = code.substring(0, begin);
+ var after = code.substring(0, end);
+ var startline = before.split('\n').length;
+ var startcolumn = begin - before.lastIndexOf('\n');
+ var endline = after.split('\n').length;
+ var endcolumn = end - after.lastIndexOf('\n');
+ var pos = {
+ sl: startline - 1,
+ sc: startcolumn - 1,
+ el: endline - 1,
+ ec: endcolumn - 1
+ };
+ return pos;
+};
+
+exports.JSONiqLexer = _dereq_('./lexers/jsoniq_lexer').JSONiqLexer;
+exports.XQueryLexer = _dereq_('./lexers/xquery_lexer').XQueryLexer;
+exports.XQLint = function (source, opts) {
+ if(_.defaults) {
+ opts = _.defaults(opts ? opts : {}, { styleCheck: false });
+ }
+
+ var ast, xqdoc;
+ var sctx = opts.staticContext ? opts.staticContext : createStaticContext();
+
+ this.getAST = function () {
+ return ast;
+ };
+
+ this.printAST = function () {
+ return TreeOps.astAsXML(ast, ' ');
+ };
+
+ this.getXQDoc = function () {
+ return xqdoc.getXQDoc(sctx);
+ };
+
+ var markers = [];
+ this.getMarkers = function () {
+ return markers;
+ };
+
+ this.getMarkers = function(type){
+ var m = [];
+ markers.forEach(function(marker){
+ if(marker.type === type || type === undefined){
+ m.push(marker);
+ }
+ });
+ return m;
+ };
+
+ this.getErrors = function(){
+ return this.getMarkers('error');
+ };
+
+ this.getWarnings = function(){
+ return this.getMarkers('warning');
+ };
+
+ this.getCompletions = function(pos){
+ return completer.complete(source, ast, sctx, pos);
+ };
+
+ var syntaxError = false;
+ this.hasSyntaxError = function () {
+ return syntaxError;
+ };
+
+ var file = opts.fileName ? opts.fileName : '';
+ var isJSONiq = ((file.substring(file.length - '.jq'.length).indexOf('.jq') !== -1) && source.indexOf('xquery version') !== 0) || source.indexOf('jsoniq version') === 0;
+ var h = new JSONParseTreeHandler(source);
+ var parser = isJSONiq ? new JSONiqParser(source, h) : new XQueryParser(source, h);
+ try {
+ parser.parse_XQuery();
+ } catch (e) {
+ if (e instanceof parser.ParseException) {
+ syntaxError = true;
+ h.closeParseTree();
+ var pos = convertPosition(source, e.getBegin(), e.getEnd());
+ var message = parser.getErrorMessage(e);
+ if (pos.sc === pos.ec) {
+ pos.ec++;
+ }
+ markers.push({
+ pos: pos,
+ type: 'error',
+ level: 'error',
+ message: message
+ });
+ } else {
+ throw e;
+ }
+ }
+ ast = h.getParseTree();
+ if(opts.styleCheck) {
+ markers = markers.concat(new StyleChecker(ast, source).getMarkers());
+ }
+ xqdoc = new XQDoc(ast);
+ var translator = new Translator(sctx, ast);
+ markers = markers.concat(translator.getMarkers());
+};
+
+},{"../lib/completion/completer":"/node_modules/xqlint/lib/completion/completer.js","./compiler/static_context":"/node_modules/xqlint/lib/compiler/static_context.js","./compiler/translator":"/node_modules/xqlint/lib/compiler/translator.js","./formatter/style_checker":"/node_modules/xqlint/lib/formatter/style_checker.js","./lexers/jsoniq_lexer":"/node_modules/xqlint/lib/lexers/jsoniq_lexer.js","./lexers/xquery_lexer":"/node_modules/xqlint/lib/lexers/xquery_lexer.js","./parsers/JSONParseTreeHandler":"/node_modules/xqlint/lib/parsers/JSONParseTreeHandler.js","./parsers/JSONiqParser":"/node_modules/xqlint/lib/parsers/JSONiqParser.js","./parsers/XQueryParser":"/node_modules/xqlint/lib/parsers/XQueryParser.js","./tree_ops":"/node_modules/xqlint/lib/tree_ops.js","./xqdoc/xqdoc":"/node_modules/xqlint/lib/xqdoc/xqdoc.js","lodash":"/node_modules/xqlint/node_modules/lodash/index.js"}],"/node_modules/xqlint/node_modules/lodash/index.js":[function(_dereq_,module,exports){
+(function (global){
+;(function() {
+ var undefined;
+ var VERSION = '3.10.1';
+ var BIND_FLAG = 1,
+ BIND_KEY_FLAG = 2,
+ CURRY_BOUND_FLAG = 4,
+ CURRY_FLAG = 8,
+ CURRY_RIGHT_FLAG = 16,
+ PARTIAL_FLAG = 32,
+ PARTIAL_RIGHT_FLAG = 64,
+ ARY_FLAG = 128,
+ REARG_FLAG = 256;
+ var DEFAULT_TRUNC_LENGTH = 30,
+ DEFAULT_TRUNC_OMISSION = '...';
+ var HOT_COUNT = 150,
+ HOT_SPAN = 16;
+ var LARGE_ARRAY_SIZE = 200;
+ var LAZY_FILTER_FLAG = 1,
+ LAZY_MAP_FLAG = 2;
+ var FUNC_ERROR_TEXT = 'Expected a function';
+ var PLACEHOLDER = '__lodash_placeholder__';
+ var argsTag = '[object Arguments]',
+ arrayTag = '[object Array]',
+ boolTag = '[object Boolean]',
+ dateTag = '[object Date]',
+ errorTag = '[object Error]',
+ funcTag = '[object Function]',
+ mapTag = '[object Map]',
+ numberTag = '[object Number]',
+ objectTag = '[object Object]',
+ regexpTag = '[object RegExp]',
+ setTag = '[object Set]',
+ stringTag = '[object String]',
+ weakMapTag = '[object WeakMap]';
+
+ var arrayBufferTag = '[object ArrayBuffer]',
+ float32Tag = '[object Float32Array]',
+ float64Tag = '[object Float64Array]',
+ int8Tag = '[object Int8Array]',
+ int16Tag = '[object Int16Array]',
+ int32Tag = '[object Int32Array]',
+ uint8Tag = '[object Uint8Array]',
+ uint8ClampedTag = '[object Uint8ClampedArray]',
+ uint16Tag = '[object Uint16Array]',
+ uint32Tag = '[object Uint32Array]';
+ var reEmptyStringLeading = /\b__p \+= '';/g,
+ reEmptyStringMiddle = /\b(__p \+=) '' \+/g,
+ reEmptyStringTrailing = /(__e\(.*?\)|\b__t\)) \+\n'';/g;
+ var reEscapedHtml = /&(?:amp|lt|gt|quot|#39|#96);/g,
+ reUnescapedHtml = /[&<>"'`]/g,
+ reHasEscapedHtml = RegExp(reEscapedHtml.source),
+ reHasUnescapedHtml = RegExp(reUnescapedHtml.source);
+ var reEscape = /<%-([\s\S]+?)%>/g,
+ reEvaluate = /<%([\s\S]+?)%>/g,
+ reInterpolate = /<%=([\s\S]+?)%>/g;
+ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\n\\]|\\.)*?\1)\]/,
+ reIsPlainProp = /^\w*$/,
+ rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\n\\]|\\.)*?)\2)\]/g;
+ var reRegExpChars = /^[:!,]|[\\^$.*+?()[\]{}|\/]|(^[0-9a-fA-Fnrtuvx])|([\n\r\u2028\u2029])/g,
+ reHasRegExpChars = RegExp(reRegExpChars.source);
+ var reComboMark = /[\u0300-\u036f\ufe20-\ufe23]/g;
+ var reEscapeChar = /\\(\\)?/g;
+ var reEsTemplate = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g;
+ var reFlags = /\w*$/;
+ var reHasHexPrefix = /^0[xX]/;
+ var reIsHostCtor = /^\[object .+?Constructor\]$/;
+ var reIsUint = /^\d+$/;
+ var reLatin1 = /[\xc0-\xd6\xd8-\xde\xdf-\xf6\xf8-\xff]/g;
+ var reNoMatch = /($^)/;
+ var reUnescapedString = /['\n\r\u2028\u2029\\]/g;
+ var reWords = (function() {
+ var upper = '[A-Z\\xc0-\\xd6\\xd8-\\xde]',
+ lower = '[a-z\\xdf-\\xf6\\xf8-\\xff]+';
+
+ return RegExp(upper + '+(?=' + upper + lower + ')|' + upper + '?' + lower + '|' + upper + '+|[0-9]+', 'g');
+ }());
+ var contextProps = [
+ 'Array', 'ArrayBuffer', 'Date', 'Error', 'Float32Array', 'Float64Array',
+ 'Function', 'Int8Array', 'Int16Array', 'Int32Array', 'Math', 'Number',
+ 'Object', 'RegExp', 'Set', 'String', '_', 'clearTimeout', 'isFinite',
+ 'parseFloat', 'parseInt', 'setTimeout', 'TypeError', 'Uint8Array',
+ 'Uint8ClampedArray', 'Uint16Array', 'Uint32Array', 'WeakMap'
+ ];
+ var templateCounter = -1;
+ var typedArrayTags = {};
+ typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =
+ typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =
+ typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =
+ typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =
+ typedArrayTags[uint32Tag] = true;
+ typedArrayTags[argsTag] = typedArrayTags[arrayTag] =
+ typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =
+ typedArrayTags[dateTag] = typedArrayTags[errorTag] =
+ typedArrayTags[funcTag] = typedArrayTags[mapTag] =
+ typedArrayTags[numberTag] = typedArrayTags[objectTag] =
+ typedArrayTags[regexpTag] = typedArrayTags[setTag] =
+ typedArrayTags[stringTag] = typedArrayTags[weakMapTag] = false;
+ var cloneableTags = {};
+ cloneableTags[argsTag] = cloneableTags[arrayTag] =
+ cloneableTags[arrayBufferTag] = cloneableTags[boolTag] =
+ cloneableTags[dateTag] = cloneableTags[float32Tag] =
+ cloneableTags[float64Tag] = cloneableTags[int8Tag] =
+ cloneableTags[int16Tag] = cloneableTags[int32Tag] =
+ cloneableTags[numberTag] = cloneableTags[objectTag] =
+ cloneableTags[regexpTag] = cloneableTags[stringTag] =
+ cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =
+ cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
+ cloneableTags[errorTag] = cloneableTags[funcTag] =
+ cloneableTags[mapTag] = cloneableTags[setTag] =
+ cloneableTags[weakMapTag] = false;
+ var deburredLetters = {
+ '\xc0': 'A', '\xc1': 'A', '\xc2': 'A', '\xc3': 'A', '\xc4': 'A', '\xc5': 'A',
+ '\xe0': 'a', '\xe1': 'a', '\xe2': 'a', '\xe3': 'a', '\xe4': 'a', '\xe5': 'a',
+ '\xc7': 'C', '\xe7': 'c',
+ '\xd0': 'D', '\xf0': 'd',
+ '\xc8': 'E', '\xc9': 'E', '\xca': 'E', '\xcb': 'E',
+ '\xe8': 'e', '\xe9': 'e', '\xea': 'e', '\xeb': 'e',
+ '\xcC': 'I', '\xcd': 'I', '\xce': 'I', '\xcf': 'I',
+ '\xeC': 'i', '\xed': 'i', '\xee': 'i', '\xef': 'i',
+ '\xd1': 'N', '\xf1': 'n',
+ '\xd2': 'O', '\xd3': 'O', '\xd4': 'O', '\xd5': 'O', '\xd6': 'O', '\xd8': 'O',
+ '\xf2': 'o', '\xf3': 'o', '\xf4': 'o', '\xf5': 'o', '\xf6': 'o', '\xf8': 'o',
+ '\xd9': 'U', '\xda': 'U', '\xdb': 'U', '\xdc': 'U',
+ '\xf9': 'u', '\xfa': 'u', '\xfb': 'u', '\xfc': 'u',
+ '\xdd': 'Y', '\xfd': 'y', '\xff': 'y',
+ '\xc6': 'Ae', '\xe6': 'ae',
+ '\xde': 'Th', '\xfe': 'th',
+ '\xdf': 'ss'
+ };
+ var htmlEscapes = {
+ '&': '&amp;',
+ '<': '&lt;',
+ '>': '&gt;',
+ '"': '&quot;',
+ "'": '&#39;',
+ '`': '&#96;'
+ };
+ var htmlUnescapes = {
+ '&amp;': '&',
+ '&lt;': '<',
+ '&gt;': '>',
+ '&quot;': '"',
+ '&#39;': "'",
+ '&#96;': '`'
+ };
+ var objectTypes = {
+ 'function': true,
+ 'object': true
+ };
+ var regexpEscapes = {
+ '0': 'x30', '1': 'x31', '2': 'x32', '3': 'x33', '4': 'x34',
+ '5': 'x35', '6': 'x36', '7': 'x37', '8': 'x38', '9': 'x39',
+ 'A': 'x41', 'B': 'x42', 'C': 'x43', 'D': 'x44', 'E': 'x45', 'F': 'x46',
+ 'a': 'x61', 'b': 'x62', 'c': 'x63', 'd': 'x64', 'e': 'x65', 'f': 'x66',
+ 'n': 'x6e', 'r': 'x72', 't': 'x74', 'u': 'x75', 'v': 'x76', 'x': 'x78'
+ };
+ var stringEscapes = {
+ '\\': '\\',
+ "'": "'",
+ '\n': 'n',
+ '\r': 'r',
+ '\u2028': 'u2028',
+ '\u2029': 'u2029'
+ };
+ var freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports;
+ var freeModule = objectTypes[typeof module] && module && !module.nodeType && module;
+ var freeGlobal = freeExports && freeModule && typeof global == 'object' && global && global.Object && global;
+ var freeSelf = objectTypes[typeof self] && self && self.Object && self;
+ var freeWindow = objectTypes[typeof window] && window && window.Object && window;
+ var moduleExports = freeModule && freeModule.exports === freeExports && freeExports;
+ var root = freeGlobal || ((freeWindow !== (this && this.window)) && freeWindow) || freeSelf || this;
+ function baseCompareAscending(value, other) {
+ if (value !== other) {
+ var valIsNull = value === null,
+ valIsUndef = value === undefined,
+ valIsReflexive = value === value;
+
+ var othIsNull = other === null,
+ othIsUndef = other === undefined,
+ othIsReflexive = other === other;
+
+ if ((value > other && !othIsNull) || !valIsReflexive ||
+ (valIsNull && !othIsUndef && othIsReflexive) ||
+ (valIsUndef && othIsReflexive)) {
+ return 1;
+ }
+ if ((value < other && !valIsNull) || !othIsReflexive ||
+ (othIsNull && !valIsUndef && valIsReflexive) ||
+ (othIsUndef && valIsReflexive)) {
+ return -1;
+ }
+ }
+ return 0;
+ }
+ function baseFindIndex(array, predicate, fromRight) {
+ var length = array.length,
+ index = fromRight ? length : -1;
+
+ while ((fromRight ? index-- : ++index < length)) {
+ if (predicate(array[index], index, array)) {
+ return index;
+ }
+ }
+ return -1;
+ }
+ function baseIndexOf(array, value, fromIndex) {
+ if (value !== value) {
+ return indexOfNaN(array, fromIndex);
+ }
+ var index = fromIndex - 1,
+ length = array.length;
+
+ while (++index < length) {
+ if (array[index] === value) {
+ return index;
+ }
+ }
+ return -1;
+ }
+ function baseIsFunction(value) {
+ return typeof value == 'function' || false;
+ }
+ function baseToString(value) {
+ return value == null ? '' : (value + '');
+ }
+ function charsLeftIndex(string, chars) {
+ var index = -1,
+ length = string.length;
+
+ while (++index < length && chars.indexOf(string.charAt(index)) > -1) {}
+ return index;
+ }
+ function charsRightIndex(string, chars) {
+ var index = string.length;
+
+ while (index-- && chars.indexOf(string.charAt(index)) > -1) {}
+ return index;
+ }
+ function compareAscending(object, other) {
+ return baseCompareAscending(object.criteria, other.criteria) || (object.index - other.index);
+ }
+ function compareMultiple(object, other, orders) {
+ var index = -1,
+ objCriteria = object.criteria,
+ othCriteria = other.criteria,
+ length = objCriteria.length,
+ ordersLength = orders.length;
+
+ while (++index < length) {
+ var result = baseCompareAscending(objCriteria[index], othCriteria[index]);
+ if (result) {
+ if (index >= ordersLength) {
+ return result;
+ }
+ var order = orders[index];
+ return result * ((order === 'asc' || order === true) ? 1 : -1);
+ }
+ }
+ return object.index - other.index;
+ }
+ function deburrLetter(letter) {
+ return deburredLetters[letter];
+ }
+ function escapeHtmlChar(chr) {
+ return htmlEscapes[chr];
+ }
+ function escapeRegExpChar(chr, leadingChar, whitespaceChar) {
+ if (leadingChar) {
+ chr = regexpEscapes[chr];
+ } else if (whitespaceChar) {
+ chr = stringEscapes[chr];
+ }
+ return '\\' + chr;
+ }
+ function escapeStringChar(chr) {
+ return '\\' + stringEscapes[chr];
+ }
+ function indexOfNaN(array, fromIndex, fromRight) {
+ var length = array.length,
+ index = fromIndex + (fromRight ? 0 : -1);
+
+ while ((fromRight ? index-- : ++index < length)) {
+ var other = array[index];
+ if (other !== other) {
+ return index;
+ }
+ }
+ return -1;
+ }
+ function isObjectLike(value) {
+ return !!value && typeof value == 'object';
+ }
+ function isSpace(charCode) {
+ return ((charCode <= 160 && (charCode >= 9 && charCode <= 13) || charCode == 32 || charCode == 160) || charCode == 5760 || charCode == 6158 ||
+ (charCode >= 8192 && (charCode <= 8202 || charCode == 8232 || charCode == 8233 || charCode == 8239 || charCode == 8287 || charCode == 12288 || charCode == 65279)));
+ }
+ function replaceHolders(array, placeholder) {
+ var index = -1,
+ length = array.length,
+ resIndex = -1,
+ result = [];
+
+ while (++index < length) {
+ if (array[index] === placeholder) {
+ array[index] = PLACEHOLDER;
+ result[++resIndex] = index;
+ }
+ }
+ return result;
+ }
+ function sortedUniq(array, iteratee) {
+ var seen,
+ index = -1,
+ length = array.length,
+ resIndex = -1,
+ result = [];
+
+ while (++index < length) {
+ var value = array[index],
+ computed = iteratee ? iteratee(value, index, array) : value;
+
+ if (!index || seen !== computed) {
+ seen = computed;
+ result[++resIndex] = value;
+ }
+ }
+ return result;
+ }
+ function trimmedLeftIndex(string) {
+ var index = -1,
+ length = string.length;
+
+ while (++index < length && isSpace(string.charCodeAt(index))) {}
+ return index;
+ }
+ function trimmedRightIndex(string) {
+ var index = string.length;
+
+ while (index-- && isSpace(string.charCodeAt(index))) {}
+ return index;
+ }
+ function unescapeHtmlChar(chr) {
+ return htmlUnescapes[chr];
+ }
+ function runInContext(context) {
+ context = context ? _.defaults(root.Object(), context, _.pick(root, contextProps)) : root;
+ var Array = context.Array,
+ Date = context.Date,
+ Error = context.Error,
+ Function = context.Function,
+ Math = context.Math,
+ Number = context.Number,
+ Object = context.Object,
+ RegExp = context.RegExp,
+ String = context.String,
+ TypeError = context.TypeError;
+ var arrayProto = Array.prototype,
+ objectProto = Object.prototype,
+ stringProto = String.prototype;
+ var fnToString = Function.prototype.toString;
+ var hasOwnProperty = objectProto.hasOwnProperty;
+ var idCounter = 0;
+ var objToString = objectProto.toString;
+ var oldDash = root._;
+ var reIsNative = RegExp('^' +
+ fnToString.call(hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g, '\\$&')
+ .replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
+ );
+ var ArrayBuffer = context.ArrayBuffer,
+ clearTimeout = context.clearTimeout,
+ parseFloat = context.parseFloat,
+ pow = Math.pow,
+ propertyIsEnumerable = objectProto.propertyIsEnumerable,
+ Set = getNative(context, 'Set'),
+ setTimeout = context.setTimeout,
+ splice = arrayProto.splice,
+ Uint8Array = context.Uint8Array,
+ WeakMap = getNative(context, 'WeakMap');
+ var nativeCeil = Math.ceil,
+ nativeCreate = getNative(Object, 'create'),
+ nativeFloor = Math.floor,
+ nativeIsArray = getNative(Array, 'isArray'),
+ nativeIsFinite = context.isFinite,
+ nativeKeys = getNative(Object, 'keys'),
+ nativeMax = Math.max,
+ nativeMin = Math.min,
+ nativeNow = getNative(Date, 'now'),
+ nativeParseInt = context.parseInt,
+ nativeRandom = Math.random;
+ var NEGATIVE_INFINITY = Number.NEGATIVE_INFINITY,
+ POSITIVE_INFINITY = Number.POSITIVE_INFINITY;
+ var MAX_ARRAY_LENGTH = 4294967295,
+ MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1,
+ HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1;
+ var MAX_SAFE_INTEGER = 9007199254740991;
+ var metaMap = WeakMap && new WeakMap;
+ var realNames = {};
+ function lodash(value) {
+ if (isObjectLike(value) && !isArray(value) && !(value instanceof LazyWrapper)) {
+ if (value instanceof LodashWrapper) {
+ return value;
+ }
+ if (hasOwnProperty.call(value, '__chain__') && hasOwnProperty.call(value, '__wrapped__')) {
+ return wrapperClone(value);
+ }
+ }
+ return new LodashWrapper(value);
+ }
+ function baseLodash() {
+ }
+ function LodashWrapper(value, chainAll, actions) {
+ this.__wrapped__ = value;
+ this.__actions__ = actions || [];
+ this.__chain__ = !!chainAll;
+ }
+ var support = lodash.support = {};
+ lodash.templateSettings = {
+ 'escape': reEscape,
+ 'evaluate': reEvaluate,
+ 'interpolate': reInterpolate,
+ 'variable': '',
+ 'imports': {
+ '_': lodash
+ }
+ };
+ function LazyWrapper(value) {
+ this.__wrapped__ = value;
+ this.__actions__ = [];
+ this.__dir__ = 1;
+ this.__filtered__ = false;
+ this.__iteratees__ = [];
+ this.__takeCount__ = POSITIVE_INFINITY;
+ this.__views__ = [];
+ }
+ function lazyClone() {
+ var result = new LazyWrapper(this.__wrapped__);
+ result.__actions__ = arrayCopy(this.__actions__);
+ result.__dir__ = this.__dir__;
+ result.__filtered__ = this.__filtered__;
+ result.__iteratees__ = arrayCopy(this.__iteratees__);
+ result.__takeCount__ = this.__takeCount__;
+ result.__views__ = arrayCopy(this.__views__);
+ return result;
+ }
+ function lazyReverse() {
+ if (this.__filtered__) {
+ var result = new LazyWrapper(this);
+ result.__dir__ = -1;
+ result.__filtered__ = true;
+ } else {
+ result = this.clone();
+ result.__dir__ *= -1;
+ }
+ return result;
+ }
+ function lazyValue() {
+ var array = this.__wrapped__.value(),
+ dir = this.__dir__,
+ isArr = isArray(array),
+ isRight = dir < 0,
+ arrLength = isArr ? array.length : 0,
+ view = getView(0, arrLength, this.__views__),
+ start = view.start,
+ end = view.end,
+ length = end - start,
+ index = isRight ? end : (start - 1),
+ iteratees = this.__iteratees__,
+ iterLength = iteratees.length,
+ resIndex = 0,
+ takeCount = nativeMin(length, this.__takeCount__);
+
+ if (!isArr || arrLength < LARGE_ARRAY_SIZE || (arrLength == length && takeCount == length)) {
+ return baseWrapperValue((isRight && isArr) ? array.reverse() : array, this.__actions__);
+ }
+ var result = [];
+
+ outer:
+ while (length-- && resIndex < takeCount) {
+ index += dir;
+
+ var iterIndex = -1,
+ value = array[index];
+
+ while (++iterIndex < iterLength) {
+ var data = iteratees[iterIndex],
+ iteratee = data.iteratee,
+ type = data.type,
+ computed = iteratee(value);
+
+ if (type == LAZY_MAP_FLAG) {
+ value = computed;
+ } else if (!computed) {
+ if (type == LAZY_FILTER_FLAG) {
+ continue outer;
+ } else {
+ break outer;
+ }
+ }
+ }
+ result[resIndex++] = value;
+ }
+ return result;
+ }
+ function MapCache() {
+ this.__data__ = {};
+ }
+ function mapDelete(key) {
+ return this.has(key) && delete this.__data__[key];
+ }
+ function mapGet(key) {
+ return key == '__proto__' ? undefined : this.__data__[key];
+ }
+ function mapHas(key) {
+ return key != '__proto__' && hasOwnProperty.call(this.__data__, key);
+ }
+ function mapSet(key, value) {
+ if (key != '__proto__') {
+ this.__data__[key] = value;
+ }
+ return this;
+ }
+ function SetCache(values) {
+ var length = values ? values.length : 0;
+
+ this.data = { 'hash': nativeCreate(null), 'set': new Set };
+ while (length--) {
+ this.push(values[length]);
+ }
+ }
+ function cacheIndexOf(cache, value) {
+ var data = cache.data,
+ result = (typeof value == 'string' || isObject(value)) ? data.set.has(value) : data.hash[value];
+
+ return result ? 0 : -1;
+ }
+ function cachePush(value) {
+ var data = this.data;
+ if (typeof value == 'string' || isObject(value)) {
+ data.set.add(value);
+ } else {
+ data.hash[value] = true;
+ }
+ }
+ function arrayConcat(array, other) {
+ var index = -1,
+ length = array.length,
+ othIndex = -1,
+ othLength = other.length,
+ result = Array(length + othLength);
+
+ while (++index < length) {
+ result[index] = array[index];
+ }
+ while (++othIndex < othLength) {
+ result[index++] = other[othIndex];
+ }
+ return result;
+ }
+ function arrayCopy(source, array) {
+ var index = -1,
+ length = source.length;
+
+ array || (array = Array(length));
+ while (++index < length) {
+ array[index] = source[index];
+ }
+ return array;
+ }
+ function arrayEach(array, iteratee) {
+ var index = -1,
+ length = array.length;
+
+ while (++index < length) {
+ if (iteratee(array[index], index, array) === false) {
+ break;
+ }
+ }
+ return array;
+ }
+ function arrayEachRight(array, iteratee) {
+ var length = array.length;
+
+ while (length--) {
+ if (iteratee(array[length], length, array) === false) {
+ break;
+ }
+ }
+ return array;
+ }
+ function arrayEvery(array, predicate) {
+ var index = -1,
+ length = array.length;
+
+ while (++index < length) {
+ if (!predicate(array[index], index, array)) {
+ return false;
+ }
+ }
+ return true;
+ }
+ function arrayExtremum(array, iteratee, comparator, exValue) {
+ var index = -1,
+ length = array.length,
+ computed = exValue,
+ result = computed;
+
+ while (++index < length) {
+ var value = array[index],
+ current = +iteratee(value);
+
+ if (comparator(current, computed)) {
+ computed = current;
+ result = value;
+ }
+ }
+ return result;
+ }
+ function arrayFilter(array, predicate) {
+ var index = -1,
+ length = array.length,
+ resIndex = -1,
+ result = [];
+
+ while (++index < length) {
+ var value = array[index];
+ if (predicate(value, index, array)) {
+ result[++resIndex] = value;
+ }
+ }
+ return result;
+ }
+ function arrayMap(array, iteratee) {
+ var index = -1,
+ length = array.length,
+ result = Array(length);
+
+ while (++index < length) {
+ result[index] = iteratee(array[index], index, array);
+ }
+ return result;
+ }
+ function arrayPush(array, values) {
+ var index = -1,
+ length = values.length,
+ offset = array.length;
+
+ while (++index < length) {
+ array[offset + index] = values[index];
+ }
+ return array;
+ }
+ function arrayReduce(array, iteratee, accumulator, initFromArray) {
+ var index = -1,
+ length = array.length;
+
+ if (initFromArray && length) {
+ accumulator = array[++index];
+ }
+ while (++index < length) {
+ accumulator = iteratee(accumulator, array[index], index, array);
+ }
+ return accumulator;
+ }
+ function arrayReduceRight(array, iteratee, accumulator, initFromArray) {
+ var length = array.length;
+ if (initFromArray && length) {
+ accumulator = array[--length];
+ }
+ while (length--) {
+ accumulator = iteratee(accumulator, array[length], length, array);
+ }
+ return accumulator;
+ }
+ function arraySome(array, predicate) {
+ var index = -1,
+ length = array.length;
+
+ while (++index < length) {
+ if (predicate(array[index], index, array)) {
+ return true;
+ }
+ }
+ return false;
+ }
+ function arraySum(array, iteratee) {
+ var length = array.length,
+ result = 0;
+
+ while (length--) {
+ result += +iteratee(array[length]) || 0;
+ }
+ return result;
+ }
+ function assignDefaults(objectValue, sourceValue) {
+ return objectValue === undefined ? sourceValue : objectValue;
+ }
+ function assignOwnDefaults(objectValue, sourceValue, key, object) {
+ return (objectValue === undefined || !hasOwnProperty.call(object, key))
+ ? sourceValue
+ : objectValue;
+ }
+ function assignWith(object, source, customizer) {
+ var index = -1,
+ props = keys(source),
+ length = props.length;
+
+ while (++index < length) {
+ var key = props[index],
+ value = object[key],
+ result = customizer(value, source[key], key, object, source);
+
+ if ((result === result ? (result !== value) : (value === value)) ||
+ (value === undefined && !(key in object))) {
+ object[key] = result;
+ }
+ }
+ return object;
+ }
+ function baseAssign(object, source) {
+ return source == null
+ ? object
+ : baseCopy(source, keys(source), object);
+ }
+ function baseAt(collection, props) {
+ var index = -1,
+ isNil = collection == null,
+ isArr = !isNil && isArrayLike(collection),
+ length = isArr ? collection.length : 0,
+ propsLength = props.length,
+ result = Array(propsLength);
+
+ while(++index < propsLength) {
+ var key = props[index];
+ if (isArr) {
+ result[index] = isIndex(key, length) ? collection[key] : undefined;
+ } else {
+ result[index] = isNil ? undefined : collection[key];
+ }
+ }
+ return result;
+ }
+ function baseCopy(source, props, object) {
+ object || (object = {});
+
+ var index = -1,
+ length = props.length;
+
+ while (++index < length) {
+ var key = props[index];
+ object[key] = source[key];
+ }
+ return object;
+ }
+ function baseCallback(func, thisArg, argCount) {
+ var type = typeof func;
+ if (type == 'function') {
+ return thisArg === undefined
+ ? func
+ : bindCallback(func, thisArg, argCount);
+ }
+ if (func == null) {
+ return identity;
+ }
+ if (type == 'object') {
+ return baseMatches(func);
+ }
+ return thisArg === undefined
+ ? property(func)
+ : baseMatchesProperty(func, thisArg);
+ }
+ function baseClone(value, isDeep, customizer, key, object, stackA, stackB) {
+ var result;
+ if (customizer) {
+ result = object ? customizer(value, key, object) : customizer(value);
+ }
+ if (result !== undefined) {
+ return result;
+ }
+ if (!isObject(value)) {
+ return value;
+ }
+ var isArr = isArray(value);
+ if (isArr) {
+ result = initCloneArray(value);
+ if (!isDeep) {
+ return arrayCopy(value, result);
+ }
+ } else {
+ var tag = objToString.call(value),
+ isFunc = tag == funcTag;
+
+ if (tag == objectTag || tag == argsTag || (isFunc && !object)) {
+ result = initCloneObject(isFunc ? {} : value);
+ if (!isDeep) {
+ return baseAssign(result, value);
+ }
+ } else {
+ return cloneableTags[tag]
+ ? initCloneByTag(value, tag, isDeep)
+ : (object ? value : {});
+ }
+ }
+ stackA || (stackA = []);
+ stackB || (stackB = []);
+
+ var length = stackA.length;
+ while (length--) {
+ if (stackA[length] == value) {
+ return stackB[length];
+ }
+ }
+ stackA.push(value);
+ stackB.push(result);
+ (isArr ? arrayEach : baseForOwn)(value, function(subValue, key) {
+ result[key] = baseClone(subValue, isDeep, customizer, key, value, stackA, stackB);
+ });
+ return result;
+ }
+ var baseCreate = (function() {
+ function object() {}
+ return function(prototype) {
+ if (isObject(prototype)) {
+ object.prototype = prototype;
+ var result = new object;
+ object.prototype = undefined;
+ }
+ return result || {};
+ };
+ }());
+ function baseDelay(func, wait, args) {
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ return setTimeout(function() { func.apply(undefined, args); }, wait);
+ }
+ function baseDifference(array, values) {
+ var length = array ? array.length : 0,
+ result = [];
+
+ if (!length) {
+ return result;
+ }
+ var index = -1,
+ indexOf = getIndexOf(),
+ isCommon = indexOf == baseIndexOf,
+ cache = (isCommon && values.length >= LARGE_ARRAY_SIZE) ? createCache(values) : null,
+ valuesLength = values.length;
+
+ if (cache) {
+ indexOf = cacheIndexOf;
+ isCommon = false;
+ values = cache;
+ }
+ outer:
+ while (++index < length) {
+ var value = array[index];
+
+ if (isCommon && value === value) {
+ var valuesIndex = valuesLength;
+ while (valuesIndex--) {
+ if (values[valuesIndex] === value) {
+ continue outer;
+ }
+ }
+ result.push(value);
+ }
+ else if (indexOf(values, value, 0) < 0) {
+ result.push(value);
+ }
+ }
+ return result;
+ }
+ var baseEach = createBaseEach(baseForOwn);
+ var baseEachRight = createBaseEach(baseForOwnRight, true);
+ function baseEvery(collection, predicate) {
+ var result = true;
+ baseEach(collection, function(value, index, collection) {
+ result = !!predicate(value, index, collection);
+ return result;
+ });
+ return result;
+ }
+ function baseExtremum(collection, iteratee, comparator, exValue) {
+ var computed = exValue,
+ result = computed;
+
+ baseEach(collection, function(value, index, collection) {
+ var current = +iteratee(value, index, collection);
+ if (comparator(current, computed) || (current === exValue && current === result)) {
+ computed = current;
+ result = value;
+ }
+ });
+ return result;
+ }
+ function baseFill(array, value, start, end) {
+ var length = array.length;
+
+ start = start == null ? 0 : (+start || 0);
+ if (start < 0) {
+ start = -start > length ? 0 : (length + start);
+ }
+ end = (end === undefined || end > length) ? length : (+end || 0);
+ if (end < 0) {
+ end += length;
+ }
+ length = start > end ? 0 : (end >>> 0);
+ start >>>= 0;
+
+ while (start < length) {
+ array[start++] = value;
+ }
+ return array;
+ }
+ function baseFilter(collection, predicate) {
+ var result = [];
+ baseEach(collection, function(value, index, collection) {
+ if (predicate(value, index, collection)) {
+ result.push(value);
+ }
+ });
+ return result;
+ }
+ function baseFind(collection, predicate, eachFunc, retKey) {
+ var result;
+ eachFunc(collection, function(value, key, collection) {
+ if (predicate(value, key, collection)) {
+ result = retKey ? key : value;
+ return false;
+ }
+ });
+ return result;
+ }
+ function baseFlatten(array, isDeep, isStrict, result) {
+ result || (result = []);
+
+ var index = -1,
+ length = array.length;
+
+ while (++index < length) {
+ var value = array[index];
+ if (isObjectLike(value) && isArrayLike(value) &&
+ (isStrict || isArray(value) || isArguments(value))) {
+ if (isDeep) {
+ baseFlatten(value, isDeep, isStrict, result);
+ } else {
+ arrayPush(result, value);
+ }
+ } else if (!isStrict) {
+ result[result.length] = value;
+ }
+ }
+ return result;
+ }
+ var baseFor = createBaseFor();
+ var baseForRight = createBaseFor(true);
+ function baseForIn(object, iteratee) {
+ return baseFor(object, iteratee, keysIn);
+ }
+ function baseForOwn(object, iteratee) {
+ return baseFor(object, iteratee, keys);
+ }
+ function baseForOwnRight(object, iteratee) {
+ return baseForRight(object, iteratee, keys);
+ }
+ function baseFunctions(object, props) {
+ var index = -1,
+ length = props.length,
+ resIndex = -1,
+ result = [];
+
+ while (++index < length) {
+ var key = props[index];
+ if (isFunction(object[key])) {
+ result[++resIndex] = key;
+ }
+ }
+ return result;
+ }
+ function baseGet(object, path, pathKey) {
+ if (object == null) {
+ return;
+ }
+ if (pathKey !== undefined && pathKey in toObject(object)) {
+ path = [pathKey];
+ }
+ var index = 0,
+ length = path.length;
+
+ while (object != null && index < length) {
+ object = object[path[index++]];
+ }
+ return (index && index == length) ? object : undefined;
+ }
+ function baseIsEqual(value, other, customizer, isLoose, stackA, stackB) {
+ if (value === other) {
+ return true;
+ }
+ if (value == null || other == null || (!isObject(value) && !isObjectLike(other))) {
+ return value !== value && other !== other;
+ }
+ return baseIsEqualDeep(value, other, baseIsEqual, customizer, isLoose, stackA, stackB);
+ }
+ function baseIsEqualDeep(object, other, equalFunc, customizer, isLoose, stackA, stackB) {
+ var objIsArr = isArray(object),
+ othIsArr = isArray(other),
+ objTag = arrayTag,
+ othTag = arrayTag;
+
+ if (!objIsArr) {
+ objTag = objToString.call(object);
+ if (objTag == argsTag) {
+ objTag = objectTag;
+ } else if (objTag != objectTag) {
+ objIsArr = isTypedArray(object);
+ }
+ }
+ if (!othIsArr) {
+ othTag = objToString.call(other);
+ if (othTag == argsTag) {
+ othTag = objectTag;
+ } else if (othTag != objectTag) {
+ othIsArr = isTypedArray(other);
+ }
+ }
+ var objIsObj = objTag == objectTag,
+ othIsObj = othTag == objectTag,
+ isSameTag = objTag == othTag;
+
+ if (isSameTag && !(objIsArr || objIsObj)) {
+ return equalByTag(object, other, objTag);
+ }
+ if (!isLoose) {
+ var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),
+ othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');
+
+ if (objIsWrapped || othIsWrapped) {
+ return equalFunc(objIsWrapped ? object.value() : object, othIsWrapped ? other.value() : other, customizer, isLoose, stackA, stackB);
+ }
+ }
+ if (!isSameTag) {
+ return false;
+ }
+ stackA || (stackA = []);
+ stackB || (stackB = []);
+
+ var length = stackA.length;
+ while (length--) {
+ if (stackA[length] == object) {
+ return stackB[length] == other;
+ }
+ }
+ stackA.push(object);
+ stackB.push(other);
+
+ var result = (objIsArr ? equalArrays : equalObjects)(object, other, equalFunc, customizer, isLoose, stackA, stackB);
+
+ stackA.pop();
+ stackB.pop();
+
+ return result;
+ }
+ function baseIsMatch(object, matchData, customizer) {
+ var index = matchData.length,
+ length = index,
+ noCustomizer = !customizer;
+
+ if (object == null) {
+ return !length;
+ }
+ object = toObject(object);
+ while (index--) {
+ var data = matchData[index];
+ if ((noCustomizer && data[2])
+ ? data[1] !== object[data[0]]
+ : !(data[0] in object)
+ ) {
+ return false;
+ }
+ }
+ while (++index < length) {
+ data = matchData[index];
+ var key = data[0],
+ objValue = object[key],
+ srcValue = data[1];
+
+ if (noCustomizer && data[2]) {
+ if (objValue === undefined && !(key in object)) {
+ return false;
+ }
+ } else {
+ var result = customizer ? customizer(objValue, srcValue, key) : undefined;
+ if (!(result === undefined ? baseIsEqual(srcValue, objValue, customizer, true) : result)) {
+ return false;
+ }
+ }
+ }
+ return true;
+ }
+ function baseMap(collection, iteratee) {
+ var index = -1,
+ result = isArrayLike(collection) ? Array(collection.length) : [];
+
+ baseEach(collection, function(value, key, collection) {
+ result[++index] = iteratee(value, key, collection);
+ });
+ return result;
+ }
+ function baseMatches(source) {
+ var matchData = getMatchData(source);
+ if (matchData.length == 1 && matchData[0][2]) {
+ var key = matchData[0][0],
+ value = matchData[0][1];
+
+ return function(object) {
+ if (object == null) {
+ return false;
+ }
+ return object[key] === value && (value !== undefined || (key in toObject(object)));
+ };
+ }
+ return function(object) {
+ return baseIsMatch(object, matchData);
+ };
+ }
+ function baseMatchesProperty(path, srcValue) {
+ var isArr = isArray(path),
+ isCommon = isKey(path) && isStrictComparable(srcValue),
+ pathKey = (path + '');
+
+ path = toPath(path);
+ return function(object) {
+ if (object == null) {
+ return false;
+ }
+ var key = pathKey;
+ object = toObject(object);
+ if ((isArr || !isCommon) && !(key in object)) {
+ object = path.length == 1 ? object : baseGet(object, baseSlice(path, 0, -1));
+ if (object == null) {
+ return false;
+ }
+ key = last(path);
+ object = toObject(object);
+ }
+ return object[key] === srcValue
+ ? (srcValue !== undefined || (key in object))
+ : baseIsEqual(srcValue, object[key], undefined, true);
+ };
+ }
+ function baseMerge(object, source, customizer, stackA, stackB) {
+ if (!isObject(object)) {
+ return object;
+ }
+ var isSrcArr = isArrayLike(source) && (isArray(source) || isTypedArray(source)),
+ props = isSrcArr ? undefined : keys(source);
+
+ arrayEach(props || source, function(srcValue, key) {
+ if (props) {
+ key = srcValue;
+ srcValue = source[key];
+ }
+ if (isObjectLike(srcValue)) {
+ stackA || (stackA = []);
+ stackB || (stackB = []);
+ baseMergeDeep(object, source, key, baseMerge, customizer, stackA, stackB);
+ }
+ else {
+ var value = object[key],
+ result = customizer ? customizer(value, srcValue, key, object, source) : undefined,
+ isCommon = result === undefined;
+
+ if (isCommon) {
+ result = srcValue;
+ }
+ if ((result !== undefined || (isSrcArr && !(key in object))) &&
+ (isCommon || (result === result ? (result !== value) : (value === value)))) {
+ object[key] = result;
+ }
+ }
+ });
+ return object;
+ }
+ function baseMergeDeep(object, source, key, mergeFunc, customizer, stackA, stackB) {
+ var length = stackA.length,
+ srcValue = source[key];
+
+ while (length--) {
+ if (stackA[length] == srcValue) {
+ object[key] = stackB[length];
+ return;
+ }
+ }
+ var value = object[key],
+ result = customizer ? customizer(value, srcValue, key, object, source) : undefined,
+ isCommon = result === undefined;
+
+ if (isCommon) {
+ result = srcValue;
+ if (isArrayLike(srcValue) && (isArray(srcValue) || isTypedArray(srcValue))) {
+ result = isArray(value)
+ ? value
+ : (isArrayLike(value) ? arrayCopy(value) : []);
+ }
+ else if (isPlainObject(srcValue) || isArguments(srcValue)) {
+ result = isArguments(value)
+ ? toPlainObject(value)
+ : (isPlainObject(value) ? value : {});
+ }
+ else {
+ isCommon = false;
+ }
+ }
+ stackA.push(srcValue);
+ stackB.push(result);
+
+ if (isCommon) {
+ object[key] = mergeFunc(result, srcValue, customizer, stackA, stackB);
+ } else if (result === result ? (result !== value) : (value === value)) {
+ object[key] = result;
+ }
+ }
+ function baseProperty(key) {
+ return function(object) {
+ return object == null ? undefined : object[key];
+ };
+ }
+ function basePropertyDeep(path) {
+ var pathKey = (path + '');
+ path = toPath(path);
+ return function(object) {
+ return baseGet(object, path, pathKey);
+ };
+ }
+ function basePullAt(array, indexes) {
+ var length = array ? indexes.length : 0;
+ while (length--) {
+ var index = indexes[length];
+ if (index != previous && isIndex(index)) {
+ var previous = index;
+ splice.call(array, index, 1);
+ }
+ }
+ return array;
+ }
+ function baseRandom(min, max) {
+ return min + nativeFloor(nativeRandom() * (max - min + 1));
+ }
+ function baseReduce(collection, iteratee, accumulator, initFromCollection, eachFunc) {
+ eachFunc(collection, function(value, index, collection) {
+ accumulator = initFromCollection
+ ? (initFromCollection = false, value)
+ : iteratee(accumulator, value, index, collection);
+ });
+ return accumulator;
+ }
+ var baseSetData = !metaMap ? identity : function(func, data) {
+ metaMap.set(func, data);
+ return func;
+ };
+ function baseSlice(array, start, end) {
+ var index = -1,
+ length = array.length;
+
+ start = start == null ? 0 : (+start || 0);
+ if (start < 0) {
+ start = -start > length ? 0 : (length + start);
+ }
+ end = (end === undefined || end > length) ? length : (+end || 0);
+ if (end < 0) {
+ end += length;
+ }
+ length = start > end ? 0 : ((end - start) >>> 0);
+ start >>>= 0;
+
+ var result = Array(length);
+ while (++index < length) {
+ result[index] = array[index + start];
+ }
+ return result;
+ }
+ function baseSome(collection, predicate) {
+ var result;
+
+ baseEach(collection, function(value, index, collection) {
+ result = predicate(value, index, collection);
+ return !result;
+ });
+ return !!result;
+ }
+ function baseSortBy(array, comparer) {
+ var length = array.length;
+
+ array.sort(comparer);
+ while (length--) {
+ array[length] = array[length].value;
+ }
+ return array;
+ }
+ function baseSortByOrder(collection, iteratees, orders) {
+ var callback = getCallback(),
+ index = -1;
+
+ iteratees = arrayMap(iteratees, function(iteratee) { return callback(iteratee); });
+
+ var result = baseMap(collection, function(value) {
+ var criteria = arrayMap(iteratees, function(iteratee) { return iteratee(value); });
+ return { 'criteria': criteria, 'index': ++index, 'value': value };
+ });
+
+ return baseSortBy(result, function(object, other) {
+ return compareMultiple(object, other, orders);
+ });
+ }
+ function baseSum(collection, iteratee) {
+ var result = 0;
+ baseEach(collection, function(value, index, collection) {
+ result += +iteratee(value, index, collection) || 0;
+ });
+ return result;
+ }
+ function baseUniq(array, iteratee) {
+ var index = -1,
+ indexOf = getIndexOf(),
+ length = array.length,
+ isCommon = indexOf == baseIndexOf,
+ isLarge = isCommon && length >= LARGE_ARRAY_SIZE,
+ seen = isLarge ? createCache() : null,
+ result = [];
+
+ if (seen) {
+ indexOf = cacheIndexOf;
+ isCommon = false;
+ } else {
+ isLarge = false;
+ seen = iteratee ? [] : result;
+ }
+ outer:
+ while (++index < length) {
+ var value = array[index],
+ computed = iteratee ? iteratee(value, index, array) : value;
+
+ if (isCommon && value === value) {
+ var seenIndex = seen.length;
+ while (seenIndex--) {
+ if (seen[seenIndex] === computed) {
+ continue outer;
+ }
+ }
+ if (iteratee) {
+ seen.push(computed);
+ }
+ result.push(value);
+ }
+ else if (indexOf(seen, computed, 0) < 0) {
+ if (iteratee || isLarge) {
+ seen.push(computed);
+ }
+ result.push(value);
+ }
+ }
+ return result;
+ }
+ function baseValues(object, props) {
+ var index = -1,
+ length = props.length,
+ result = Array(length);
+
+ while (++index < length) {
+ result[index] = object[props[index]];
+ }
+ return result;
+ }
+ function baseWhile(array, predicate, isDrop, fromRight) {
+ var length = array.length,
+ index = fromRight ? length : -1;
+
+ while ((fromRight ? index-- : ++index < length) && predicate(array[index], index, array)) {}
+ return isDrop
+ ? baseSlice(array, (fromRight ? 0 : index), (fromRight ? index + 1 : length))
+ : baseSlice(array, (fromRight ? index + 1 : 0), (fromRight ? length : index));
+ }
+ function baseWrapperValue(value, actions) {
+ var result = value;
+ if (result instanceof LazyWrapper) {
+ result = result.value();
+ }
+ var index = -1,
+ length = actions.length;
+
+ while (++index < length) {
+ var action = actions[index];
+ result = action.func.apply(action.thisArg, arrayPush([result], action.args));
+ }
+ return result;
+ }
+ function binaryIndex(array, value, retHighest) {
+ var low = 0,
+ high = array ? array.length : low;
+
+ if (typeof value == 'number' && value === value && high <= HALF_MAX_ARRAY_LENGTH) {
+ while (low < high) {
+ var mid = (low + high) >>> 1,
+ computed = array[mid];
+
+ if ((retHighest ? (computed <= value) : (computed < value)) && computed !== null) {
+ low = mid + 1;
+ } else {
+ high = mid;
+ }
+ }
+ return high;
+ }
+ return binaryIndexBy(array, value, identity, retHighest);
+ }
+ function binaryIndexBy(array, value, iteratee, retHighest) {
+ value = iteratee(value);
+
+ var low = 0,
+ high = array ? array.length : 0,
+ valIsNaN = value !== value,
+ valIsNull = value === null,
+ valIsUndef = value === undefined;
+
+ while (low < high) {
+ var mid = nativeFloor((low + high) / 2),
+ computed = iteratee(array[mid]),
+ isDef = computed !== undefined,
+ isReflexive = computed === computed;
+
+ if (valIsNaN) {
+ var setLow = isReflexive || retHighest;
+ } else if (valIsNull) {
+ setLow = isReflexive && isDef && (retHighest || computed != null);
+ } else if (valIsUndef) {
+ setLow = isReflexive && (retHighest || isDef);
+ } else if (computed == null) {
+ setLow = false;
+ } else {
+ setLow = retHighest ? (computed <= value) : (computed < value);
+ }
+ if (setLow) {
+ low = mid + 1;
+ } else {
+ high = mid;
+ }
+ }
+ return nativeMin(high, MAX_ARRAY_INDEX);
+ }
+ function bindCallback(func, thisArg, argCount) {
+ if (typeof func != 'function') {
+ return identity;
+ }
+ if (thisArg === undefined) {
+ return func;
+ }
+ switch (argCount) {
+ case 1: return function(value) {
+ return func.call(thisArg, value);
+ };
+ case 3: return function(value, index, collection) {
+ return func.call(thisArg, value, index, collection);
+ };
+ case 4: return function(accumulator, value, index, collection) {
+ return func.call(thisArg, accumulator, value, index, collection);
+ };
+ case 5: return function(value, other, key, object, source) {
+ return func.call(thisArg, value, other, key, object, source);
+ };
+ }
+ return function() {
+ return func.apply(thisArg, arguments);
+ };
+ }
+ function bufferClone(buffer) {
+ var result = new ArrayBuffer(buffer.byteLength),
+ view = new Uint8Array(result);
+
+ view.set(new Uint8Array(buffer));
+ return result;
+ }
+ function composeArgs(args, partials, holders) {
+ var holdersLength = holders.length,
+ argsIndex = -1,
+ argsLength = nativeMax(args.length - holdersLength, 0),
+ leftIndex = -1,
+ leftLength = partials.length,
+ result = Array(leftLength + argsLength);
+
+ while (++leftIndex < leftLength) {
+ result[leftIndex] = partials[leftIndex];
+ }
+ while (++argsIndex < holdersLength) {
+ result[holders[argsIndex]] = args[argsIndex];
+ }
+ while (argsLength--) {
+ result[leftIndex++] = args[argsIndex++];
+ }
+ return result;
+ }
+ function composeArgsRight(args, partials, holders) {
+ var holdersIndex = -1,
+ holdersLength = holders.length,
+ argsIndex = -1,
+ argsLength = nativeMax(args.length - holdersLength, 0),
+ rightIndex = -1,
+ rightLength = partials.length,
+ result = Array(argsLength + rightLength);
+
+ while (++argsIndex < argsLength) {
+ result[argsIndex] = args[argsIndex];
+ }
+ var offset = argsIndex;
+ while (++rightIndex < rightLength) {
+ result[offset + rightIndex] = partials[rightIndex];
+ }
+ while (++holdersIndex < holdersLength) {
+ result[offset + holders[holdersIndex]] = args[argsIndex++];
+ }
+ return result;
+ }
+ function createAggregator(setter, initializer) {
+ return function(collection, iteratee, thisArg) {
+ var result = initializer ? initializer() : {};
+ iteratee = getCallback(iteratee, thisArg, 3);
+
+ if (isArray(collection)) {
+ var index = -1,
+ length = collection.length;
+
+ while (++index < length) {
+ var value = collection[index];
+ setter(result, value, iteratee(value, index, collection), collection);
+ }
+ } else {
+ baseEach(collection, function(value, key, collection) {
+ setter(result, value, iteratee(value, key, collection), collection);
+ });
+ }
+ return result;
+ };
+ }
+ function createAssigner(assigner) {
+ return restParam(function(object, sources) {
+ var index = -1,
+ length = object == null ? 0 : sources.length,
+ customizer = length > 2 ? sources[length - 2] : undefined,
+ guard = length > 2 ? sources[2] : undefined,
+ thisArg = length > 1 ? sources[length - 1] : undefined;
+
+ if (typeof customizer == 'function') {
+ customizer = bindCallback(customizer, thisArg, 5);
+ length -= 2;
+ } else {
+ customizer = typeof thisArg == 'function' ? thisArg : undefined;
+ length -= (customizer ? 1 : 0);
+ }
+ if (guard && isIterateeCall(sources[0], sources[1], guard)) {
+ customizer = length < 3 ? undefined : customizer;
+ length = 1;
+ }
+ while (++index < length) {
+ var source = sources[index];
+ if (source) {
+ assigner(object, source, customizer);
+ }
+ }
+ return object;
+ });
+ }
+ function createBaseEach(eachFunc, fromRight) {
+ return function(collection, iteratee) {
+ var length = collection ? getLength(collection) : 0;
+ if (!isLength(length)) {
+ return eachFunc(collection, iteratee);
+ }
+ var index = fromRight ? length : -1,
+ iterable = toObject(collection);
+
+ while ((fromRight ? index-- : ++index < length)) {
+ if (iteratee(iterable[index], index, iterable) === false) {
+ break;
+ }
+ }
+ return collection;
+ };
+ }
+ function createBaseFor(fromRight) {
+ return function(object, iteratee, keysFunc) {
+ var iterable = toObject(object),
+ props = keysFunc(object),
+ length = props.length,
+ index = fromRight ? length : -1;
+
+ while ((fromRight ? index-- : ++index < length)) {
+ var key = props[index];
+ if (iteratee(iterable[key], key, iterable) === false) {
+ break;
+ }
+ }
+ return object;
+ };
+ }
+ function createBindWrapper(func, thisArg) {
+ var Ctor = createCtorWrapper(func);
+
+ function wrapper() {
+ var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
+ return fn.apply(thisArg, arguments);
+ }
+ return wrapper;
+ }
+ function createCache(values) {
+ return (nativeCreate && Set) ? new SetCache(values) : null;
+ }
+ function createCompounder(callback) {
+ return function(string) {
+ var index = -1,
+ array = words(deburr(string)),
+ length = array.length,
+ result = '';
+
+ while (++index < length) {
+ result = callback(result, array[index], index);
+ }
+ return result;
+ };
+ }
+ function createCtorWrapper(Ctor) {
+ return function() {
+ var args = arguments;
+ switch (args.length) {
+ case 0: return new Ctor;
+ case 1: return new Ctor(args[0]);
+ case 2: return new Ctor(args[0], args[1]);
+ case 3: return new Ctor(args[0], args[1], args[2]);
+ case 4: return new Ctor(args[0], args[1], args[2], args[3]);
+ case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]);
+ case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);
+ case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);
+ }
+ var thisBinding = baseCreate(Ctor.prototype),
+ result = Ctor.apply(thisBinding, args);
+ return isObject(result) ? result : thisBinding;
+ };
+ }
+ function createCurry(flag) {
+ function curryFunc(func, arity, guard) {
+ if (guard && isIterateeCall(func, arity, guard)) {
+ arity = undefined;
+ }
+ var result = createWrapper(func, flag, undefined, undefined, undefined, undefined, undefined, arity);
+ result.placeholder = curryFunc.placeholder;
+ return result;
+ }
+ return curryFunc;
+ }
+ function createDefaults(assigner, customizer) {
+ return restParam(function(args) {
+ var object = args[0];
+ if (object == null) {
+ return object;
+ }
+ args.push(customizer);
+ return assigner.apply(undefined, args);
+ });
+ }
+ function createExtremum(comparator, exValue) {
+ return function(collection, iteratee, thisArg) {
+ if (thisArg && isIterateeCall(collection, iteratee, thisArg)) {
+ iteratee = undefined;
+ }
+ iteratee = getCallback(iteratee, thisArg, 3);
+ if (iteratee.length == 1) {
+ collection = isArray(collection) ? collection : toIterable(collection);
+ var result = arrayExtremum(collection, iteratee, comparator, exValue);
+ if (!(collection.length && result === exValue)) {
+ return result;
+ }
+ }
+ return baseExtremum(collection, iteratee, comparator, exValue);
+ };
+ }
+ function createFind(eachFunc, fromRight) {
+ return function(collection, predicate, thisArg) {
+ predicate = getCallback(predicate, thisArg, 3);
+ if (isArray(collection)) {
+ var index = baseFindIndex(collection, predicate, fromRight);
+ return index > -1 ? collection[index] : undefined;
+ }
+ return baseFind(collection, predicate, eachFunc);
+ };
+ }
+ function createFindIndex(fromRight) {
+ return function(array, predicate, thisArg) {
+ if (!(array && array.length)) {
+ return -1;
+ }
+ predicate = getCallback(predicate, thisArg, 3);
+ return baseFindIndex(array, predicate, fromRight);
+ };
+ }
+ function createFindKey(objectFunc) {
+ return function(object, predicate, thisArg) {
+ predicate = getCallback(predicate, thisArg, 3);
+ return baseFind(object, predicate, objectFunc, true);
+ };
+ }
+ function createFlow(fromRight) {
+ return function() {
+ var wrapper,
+ length = arguments.length,
+ index = fromRight ? length : -1,
+ leftIndex = 0,
+ funcs = Array(length);
+
+ while ((fromRight ? index-- : ++index < length)) {
+ var func = funcs[leftIndex++] = arguments[index];
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ if (!wrapper && LodashWrapper.prototype.thru && getFuncName(func) == 'wrapper') {
+ wrapper = new LodashWrapper([], true);
+ }
+ }
+ index = wrapper ? -1 : length;
+ while (++index < length) {
+ func = funcs[index];
+
+ var funcName = getFuncName(func),
+ data = funcName == 'wrapper' ? getData(func) : undefined;
+
+ if (data && isLaziable(data[0]) && data[1] == (ARY_FLAG | CURRY_FLAG | PARTIAL_FLAG | REARG_FLAG) && !data[4].length && data[9] == 1) {
+ wrapper = wrapper[getFuncName(data[0])].apply(wrapper, data[3]);
+ } else {
+ wrapper = (func.length == 1 && isLaziable(func)) ? wrapper[funcName]() : wrapper.thru(func);
+ }
+ }
+ return function() {
+ var args = arguments,
+ value = args[0];
+
+ if (wrapper && args.length == 1 && isArray(value) && value.length >= LARGE_ARRAY_SIZE) {
+ return wrapper.plant(value).value();
+ }
+ var index = 0,
+ result = length ? funcs[index].apply(this, args) : value;
+
+ while (++index < length) {
+ result = funcs[index].call(this, result);
+ }
+ return result;
+ };
+ };
+ }
+ function createForEach(arrayFunc, eachFunc) {
+ return function(collection, iteratee, thisArg) {
+ return (typeof iteratee == 'function' && thisArg === undefined && isArray(collection))
+ ? arrayFunc(collection, iteratee)
+ : eachFunc(collection, bindCallback(iteratee, thisArg, 3));
+ };
+ }
+ function createForIn(objectFunc) {
+ return function(object, iteratee, thisArg) {
+ if (typeof iteratee != 'function' || thisArg !== undefined) {
+ iteratee = bindCallback(iteratee, thisArg, 3);
+ }
+ return objectFunc(object, iteratee, keysIn);
+ };
+ }
+ function createForOwn(objectFunc) {
+ return function(object, iteratee, thisArg) {
+ if (typeof iteratee != 'function' || thisArg !== undefined) {
+ iteratee = bindCallback(iteratee, thisArg, 3);
+ }
+ return objectFunc(object, iteratee);
+ };
+ }
+ function createObjectMapper(isMapKeys) {
+ return function(object, iteratee, thisArg) {
+ var result = {};
+ iteratee = getCallback(iteratee, thisArg, 3);
+
+ baseForOwn(object, function(value, key, object) {
+ var mapped = iteratee(value, key, object);
+ key = isMapKeys ? mapped : key;
+ value = isMapKeys ? value : mapped;
+ result[key] = value;
+ });
+ return result;
+ };
+ }
+ function createPadDir(fromRight) {
+ return function(string, length, chars) {
+ string = baseToString(string);
+ return (fromRight ? string : '') + createPadding(string, length, chars) + (fromRight ? '' : string);
+ };
+ }
+ function createPartial(flag) {
+ var partialFunc = restParam(function(func, partials) {
+ var holders = replaceHolders(partials, partialFunc.placeholder);
+ return createWrapper(func, flag, undefined, partials, holders);
+ });
+ return partialFunc;
+ }
+ function createReduce(arrayFunc, eachFunc) {
+ return function(collection, iteratee, accumulator, thisArg) {
+ var initFromArray = arguments.length < 3;
+ return (typeof iteratee == 'function' && thisArg === undefined && isArray(collection))
+ ? arrayFunc(collection, iteratee, accumulator, initFromArray)
+ : baseReduce(collection, getCallback(iteratee, thisArg, 4), accumulator, initFromArray, eachFunc);
+ };
+ }
+ function createHybridWrapper(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity) {
+ var isAry = bitmask & ARY_FLAG,
+ isBind = bitmask & BIND_FLAG,
+ isBindKey = bitmask & BIND_KEY_FLAG,
+ isCurry = bitmask & CURRY_FLAG,
+ isCurryBound = bitmask & CURRY_BOUND_FLAG,
+ isCurryRight = bitmask & CURRY_RIGHT_FLAG,
+ Ctor = isBindKey ? undefined : createCtorWrapper(func);
+
+ function wrapper() {
+ var length = arguments.length,
+ index = length,
+ args = Array(length);
+
+ while (index--) {
+ args[index] = arguments[index];
+ }
+ if (partials) {
+ args = composeArgs(args, partials, holders);
+ }
+ if (partialsRight) {
+ args = composeArgsRight(args, partialsRight, holdersRight);
+ }
+ if (isCurry || isCurryRight) {
+ var placeholder = wrapper.placeholder,
+ argsHolders = replaceHolders(args, placeholder);
+
+ length -= argsHolders.length;
+ if (length < arity) {
+ var newArgPos = argPos ? arrayCopy(argPos) : undefined,
+ newArity = nativeMax(arity - length, 0),
+ newsHolders = isCurry ? argsHolders : undefined,
+ newHoldersRight = isCurry ? undefined : argsHolders,
+ newPartials = isCurry ? args : undefined,
+ newPartialsRight = isCurry ? undefined : args;
+
+ bitmask |= (isCurry ? PARTIAL_FLAG : PARTIAL_RIGHT_FLAG);
+ bitmask &= ~(isCurry ? PARTIAL_RIGHT_FLAG : PARTIAL_FLAG);
+
+ if (!isCurryBound) {
+ bitmask &= ~(BIND_FLAG | BIND_KEY_FLAG);
+ }
+ var newData = [func, bitmask, thisArg, newPartials, newsHolders, newPartialsRight, newHoldersRight, newArgPos, ary, newArity],
+ result = createHybridWrapper.apply(undefined, newData);
+
+ if (isLaziable(func)) {
+ setData(result, newData);
+ }
+ result.placeholder = placeholder;
+ return result;
+ }
+ }
+ var thisBinding = isBind ? thisArg : this,
+ fn = isBindKey ? thisBinding[func] : func;
+
+ if (argPos) {
+ args = reorder(args, argPos);
+ }
+ if (isAry && ary < args.length) {
+ args.length = ary;
+ }
+ if (this && this !== root && this instanceof wrapper) {
+ fn = Ctor || createCtorWrapper(func);
+ }
+ return fn.apply(thisBinding, args);
+ }
+ return wrapper;
+ }
+ function createPadding(string, length, chars) {
+ var strLength = string.length;
+ length = +length;
+
+ if (strLength >= length || !nativeIsFinite(length)) {
+ return '';
+ }
+ var padLength = length - strLength;
+ chars = chars == null ? ' ' : (chars + '');
+ return repeat(chars, nativeCeil(padLength / chars.length)).slice(0, padLength);
+ }
+ function createPartialWrapper(func, bitmask, thisArg, partials) {
+ var isBind = bitmask & BIND_FLAG,
+ Ctor = createCtorWrapper(func);
+
+ function wrapper() {
+ var argsIndex = -1,
+ argsLength = arguments.length,
+ leftIndex = -1,
+ leftLength = partials.length,
+ args = Array(leftLength + argsLength);
+
+ while (++leftIndex < leftLength) {
+ args[leftIndex] = partials[leftIndex];
+ }
+ while (argsLength--) {
+ args[leftIndex++] = arguments[++argsIndex];
+ }
+ var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;
+ return fn.apply(isBind ? thisArg : this, args);
+ }
+ return wrapper;
+ }
+ function createRound(methodName) {
+ var func = Math[methodName];
+ return function(number, precision) {
+ precision = precision === undefined ? 0 : (+precision || 0);
+ if (precision) {
+ precision = pow(10, precision);
+ return func(number * precision) / precision;
+ }
+ return func(number);
+ };
+ }
+ function createSortedIndex(retHighest) {
+ return function(array, value, iteratee, thisArg) {
+ var callback = getCallback(iteratee);
+ return (iteratee == null && callback === baseCallback)
+ ? binaryIndex(array, value, retHighest)
+ : binaryIndexBy(array, value, callback(iteratee, thisArg, 1), retHighest);
+ };
+ }
+ function createWrapper(func, bitmask, thisArg, partials, holders, argPos, ary, arity) {
+ var isBindKey = bitmask & BIND_KEY_FLAG;
+ if (!isBindKey && typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ var length = partials ? partials.length : 0;
+ if (!length) {
+ bitmask &= ~(PARTIAL_FLAG | PARTIAL_RIGHT_FLAG);
+ partials = holders = undefined;
+ }
+ length -= (holders ? holders.length : 0);
+ if (bitmask & PARTIAL_RIGHT_FLAG) {
+ var partialsRight = partials,
+ holdersRight = holders;
+
+ partials = holders = undefined;
+ }
+ var data = isBindKey ? undefined : getData(func),
+ newData = [func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity];
+
+ if (data) {
+ mergeData(newData, data);
+ bitmask = newData[1];
+ arity = newData[9];
+ }
+ newData[9] = arity == null
+ ? (isBindKey ? 0 : func.length)
+ : (nativeMax(arity - length, 0) || 0);
+
+ if (bitmask == BIND_FLAG) {
+ var result = createBindWrapper(newData[0], newData[2]);
+ } else if ((bitmask == PARTIAL_FLAG || bitmask == (BIND_FLAG | PARTIAL_FLAG)) && !newData[4].length) {
+ result = createPartialWrapper.apply(undefined, newData);
+ } else {
+ result = createHybridWrapper.apply(undefined, newData);
+ }
+ var setter = data ? baseSetData : setData;
+ return setter(result, newData);
+ }
+ function equalArrays(array, other, equalFunc, customizer, isLoose, stackA, stackB) {
+ var index = -1,
+ arrLength = array.length,
+ othLength = other.length;
+
+ if (arrLength != othLength && !(isLoose && othLength > arrLength)) {
+ return false;
+ }
+ while (++index < arrLength) {
+ var arrValue = array[index],
+ othValue = other[index],
+ result = customizer ? customizer(isLoose ? othValue : arrValue, isLoose ? arrValue : othValue, index) : undefined;
+
+ if (result !== undefined) {
+ if (result) {
+ continue;
+ }
+ return false;
+ }
+ if (isLoose) {
+ if (!arraySome(other, function(othValue) {
+ return arrValue === othValue || equalFunc(arrValue, othValue, customizer, isLoose, stackA, stackB);
+ })) {
+ return false;
+ }
+ } else if (!(arrValue === othValue || equalFunc(arrValue, othValue, customizer, isLoose, stackA, stackB))) {
+ return false;
+ }
+ }
+ return true;
+ }
+ function equalByTag(object, other, tag) {
+ switch (tag) {
+ case boolTag:
+ case dateTag:
+ return +object == +other;
+
+ case errorTag:
+ return object.name == other.name && object.message == other.message;
+
+ case numberTag:
+ return (object != +object)
+ ? other != +other
+ : object == +other;
+
+ case regexpTag:
+ case stringTag:
+ return object == (other + '');
+ }
+ return false;
+ }
+ function equalObjects(object, other, equalFunc, customizer, isLoose, stackA, stackB) {
+ var objProps = keys(object),
+ objLength = objProps.length,
+ othProps = keys(other),
+ othLength = othProps.length;
+
+ if (objLength != othLength && !isLoose) {
+ return false;
+ }
+ var index = objLength;
+ while (index--) {
+ var key = objProps[index];
+ if (!(isLoose ? key in other : hasOwnProperty.call(other, key))) {
+ return false;
+ }
+ }
+ var skipCtor = isLoose;
+ while (++index < objLength) {
+ key = objProps[index];
+ var objValue = object[key],
+ othValue = other[key],
+ result = customizer ? customizer(isLoose ? othValue : objValue, isLoose? objValue : othValue, key) : undefined;
+ if (!(result === undefined ? equalFunc(objValue, othValue, customizer, isLoose, stackA, stackB) : result)) {
+ return false;
+ }
+ skipCtor || (skipCtor = key == 'constructor');
+ }
+ if (!skipCtor) {
+ var objCtor = object.constructor,
+ othCtor = other.constructor;
+ if (objCtor != othCtor &&
+ ('constructor' in object && 'constructor' in other) &&
+ !(typeof objCtor == 'function' && objCtor instanceof objCtor &&
+ typeof othCtor == 'function' && othCtor instanceof othCtor)) {
+ return false;
+ }
+ }
+ return true;
+ }
+ function getCallback(func, thisArg, argCount) {
+ var result = lodash.callback || callback;
+ result = result === callback ? baseCallback : result;
+ return argCount ? result(func, thisArg, argCount) : result;
+ }
+ var getData = !metaMap ? noop : function(func) {
+ return metaMap.get(func);
+ };
+ function getFuncName(func) {
+ var result = func.name,
+ array = realNames[result],
+ length = array ? array.length : 0;
+
+ while (length--) {
+ var data = array[length],
+ otherFunc = data.func;
+ if (otherFunc == null || otherFunc == func) {
+ return data.name;
+ }
+ }
+ return result;
+ }
+ function getIndexOf(collection, target, fromIndex) {
+ var result = lodash.indexOf || indexOf;
+ result = result === indexOf ? baseIndexOf : result;
+ return collection ? result(collection, target, fromIndex) : result;
+ }
+ var getLength = baseProperty('length');
+ function getMatchData(object) {
+ var result = pairs(object),
+ length = result.length;
+
+ while (length--) {
+ result[length][2] = isStrictComparable(result[length][1]);
+ }
+ return result;
+ }
+ function getNative(object, key) {
+ var value = object == null ? undefined : object[key];
+ return isNative(value) ? value : undefined;
+ }
+ function getView(start, end, transforms) {
+ var index = -1,
+ length = transforms.length;
+
+ while (++index < length) {
+ var data = transforms[index],
+ size = data.size;
+
+ switch (data.type) {
+ case 'drop': start += size; break;
+ case 'dropRight': end -= size; break;
+ case 'take': end = nativeMin(end, start + size); break;
+ case 'takeRight': start = nativeMax(start, end - size); break;
+ }
+ }
+ return { 'start': start, 'end': end };
+ }
+ function initCloneArray(array) {
+ var length = array.length,
+ result = new array.constructor(length);
+ if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {
+ result.index = array.index;
+ result.input = array.input;
+ }
+ return result;
+ }
+ function initCloneObject(object) {
+ var Ctor = object.constructor;
+ if (!(typeof Ctor == 'function' && Ctor instanceof Ctor)) {
+ Ctor = Object;
+ }
+ return new Ctor;
+ }
+ function initCloneByTag(object, tag, isDeep) {
+ var Ctor = object.constructor;
+ switch (tag) {
+ case arrayBufferTag:
+ return bufferClone(object);
+
+ case boolTag:
+ case dateTag:
+ return new Ctor(+object);
+
+ case float32Tag: case float64Tag:
+ case int8Tag: case int16Tag: case int32Tag:
+ case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag:
+ var buffer = object.buffer;
+ return new Ctor(isDeep ? bufferClone(buffer) : buffer, object.byteOffset, object.length);
+
+ case numberTag:
+ case stringTag:
+ return new Ctor(object);
+
+ case regexpTag:
+ var result = new Ctor(object.source, reFlags.exec(object));
+ result.lastIndex = object.lastIndex;
+ }
+ return result;
+ }
+ function invokePath(object, path, args) {
+ if (object != null && !isKey(path, object)) {
+ path = toPath(path);
+ object = path.length == 1 ? object : baseGet(object, baseSlice(path, 0, -1));
+ path = last(path);
+ }
+ var func = object == null ? object : object[path];
+ return func == null ? undefined : func.apply(object, args);
+ }
+ function isArrayLike(value) {
+ return value != null && isLength(getLength(value));
+ }
+ function isIndex(value, length) {
+ value = (typeof value == 'number' || reIsUint.test(value)) ? +value : -1;
+ length = length == null ? MAX_SAFE_INTEGER : length;
+ return value > -1 && value % 1 == 0 && value < length;
+ }
+ function isIterateeCall(value, index, object) {
+ if (!isObject(object)) {
+ return false;
+ }
+ var type = typeof index;
+ if (type == 'number'
+ ? (isArrayLike(object) && isIndex(index, object.length))
+ : (type == 'string' && index in object)) {
+ var other = object[index];
+ return value === value ? (value === other) : (other !== other);
+ }
+ return false;
+ }
+ function isKey(value, object) {
+ var type = typeof value;
+ if ((type == 'string' && reIsPlainProp.test(value)) || type == 'number') {
+ return true;
+ }
+ if (isArray(value)) {
+ return false;
+ }
+ var result = !reIsDeepProp.test(value);
+ return result || (object != null && value in toObject(object));
+ }
+ function isLaziable(func) {
+ var funcName = getFuncName(func);
+ if (!(funcName in LazyWrapper.prototype)) {
+ return false;
+ }
+ var other = lodash[funcName];
+ if (func === other) {
+ return true;
+ }
+ var data = getData(other);
+ return !!data && func === data[0];
+ }
+ function isLength(value) {
+ return typeof value == 'number' && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
+ }
+ function isStrictComparable(value) {
+ return value === value && !isObject(value);
+ }
+ function mergeData(data, source) {
+ var bitmask = data[1],
+ srcBitmask = source[1],
+ newBitmask = bitmask | srcBitmask,
+ isCommon = newBitmask < ARY_FLAG;
+
+ var isCombo =
+ (srcBitmask == ARY_FLAG && bitmask == CURRY_FLAG) ||
+ (srcBitmask == ARY_FLAG && bitmask == REARG_FLAG && data[7].length <= source[8]) ||
+ (srcBitmask == (ARY_FLAG | REARG_FLAG) && bitmask == CURRY_FLAG);
+ if (!(isCommon || isCombo)) {
+ return data;
+ }
+ if (srcBitmask & BIND_FLAG) {
+ data[2] = source[2];
+ newBitmask |= (bitmask & BIND_FLAG) ? 0 : CURRY_BOUND_FLAG;
+ }
+ var value = source[3];
+ if (value) {
+ var partials = data[3];
+ data[3] = partials ? composeArgs(partials, value, source[4]) : arrayCopy(value);
+ data[4] = partials ? replaceHolders(data[3], PLACEHOLDER) : arrayCopy(source[4]);
+ }
+ value = source[5];
+ if (value) {
+ partials = data[5];
+ data[5] = partials ? composeArgsRight(partials, value, source[6]) : arrayCopy(value);
+ data[6] = partials ? replaceHolders(data[5], PLACEHOLDER) : arrayCopy(source[6]);
+ }
+ value = source[7];
+ if (value) {
+ data[7] = arrayCopy(value);
+ }
+ if (srcBitmask & ARY_FLAG) {
+ data[8] = data[8] == null ? source[8] : nativeMin(data[8], source[8]);
+ }
+ if (data[9] == null) {
+ data[9] = source[9];
+ }
+ data[0] = source[0];
+ data[1] = newBitmask;
+
+ return data;
+ }
+ function mergeDefaults(objectValue, sourceValue) {
+ return objectValue === undefined ? sourceValue : merge(objectValue, sourceValue, mergeDefaults);
+ }
+ function pickByArray(object, props) {
+ object = toObject(object);
+
+ var index = -1,
+ length = props.length,
+ result = {};
+
+ while (++index < length) {
+ var key = props[index];
+ if (key in object) {
+ result[key] = object[key];
+ }
+ }
+ return result;
+ }
+ function pickByCallback(object, predicate) {
+ var result = {};
+ baseForIn(object, function(value, key, object) {
+ if (predicate(value, key, object)) {
+ result[key] = value;
+ }
+ });
+ return result;
+ }
+ function reorder(array, indexes) {
+ var arrLength = array.length,
+ length = nativeMin(indexes.length, arrLength),
+ oldArray = arrayCopy(array);
+
+ while (length--) {
+ var index = indexes[length];
+ array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined;
+ }
+ return array;
+ }
+ var setData = (function() {
+ var count = 0,
+ lastCalled = 0;
+
+ return function(key, value) {
+ var stamp = now(),
+ remaining = HOT_SPAN - (stamp - lastCalled);
+
+ lastCalled = stamp;
+ if (remaining > 0) {
+ if (++count >= HOT_COUNT) {
+ return key;
+ }
+ } else {
+ count = 0;
+ }
+ return baseSetData(key, value);
+ };
+ }());
+ function shimKeys(object) {
+ var props = keysIn(object),
+ propsLength = props.length,
+ length = propsLength && object.length;
+
+ var allowIndexes = !!length && isLength(length) &&
+ (isArray(object) || isArguments(object));
+
+ var index = -1,
+ result = [];
+
+ while (++index < propsLength) {
+ var key = props[index];
+ if ((allowIndexes && isIndex(key, length)) || hasOwnProperty.call(object, key)) {
+ result.push(key);
+ }
+ }
+ return result;
+ }
+ function toIterable(value) {
+ if (value == null) {
+ return [];
+ }
+ if (!isArrayLike(value)) {
+ return values(value);
+ }
+ return isObject(value) ? value : Object(value);
+ }
+ function toObject(value) {
+ return isObject(value) ? value : Object(value);
+ }
+ function toPath(value) {
+ if (isArray(value)) {
+ return value;
+ }
+ var result = [];
+ baseToString(value).replace(rePropName, function(match, number, quote, string) {
+ result.push(quote ? string.replace(reEscapeChar, '$1') : (number || match));
+ });
+ return result;
+ }
+ function wrapperClone(wrapper) {
+ return wrapper instanceof LazyWrapper
+ ? wrapper.clone()
+ : new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__, arrayCopy(wrapper.__actions__));
+ }
+ function chunk(array, size, guard) {
+ if (guard ? isIterateeCall(array, size, guard) : size == null) {
+ size = 1;
+ } else {
+ size = nativeMax(nativeFloor(size) || 1, 1);
+ }
+ var index = 0,
+ length = array ? array.length : 0,
+ resIndex = -1,
+ result = Array(nativeCeil(length / size));
+
+ while (index < length) {
+ result[++resIndex] = baseSlice(array, index, (index += size));
+ }
+ return result;
+ }
+ function compact(array) {
+ var index = -1,
+ length = array ? array.length : 0,
+ resIndex = -1,
+ result = [];
+
+ while (++index < length) {
+ var value = array[index];
+ if (value) {
+ result[++resIndex] = value;
+ }
+ }
+ return result;
+ }
+ var difference = restParam(function(array, values) {
+ return (isObjectLike(array) && isArrayLike(array))
+ ? baseDifference(array, baseFlatten(values, false, true))
+ : [];
+ });
+ function drop(array, n, guard) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (guard ? isIterateeCall(array, n, guard) : n == null) {
+ n = 1;
+ }
+ return baseSlice(array, n < 0 ? 0 : n);
+ }
+ function dropRight(array, n, guard) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (guard ? isIterateeCall(array, n, guard) : n == null) {
+ n = 1;
+ }
+ n = length - (+n || 0);
+ return baseSlice(array, 0, n < 0 ? 0 : n);
+ }
+ function dropRightWhile(array, predicate, thisArg) {
+ return (array && array.length)
+ ? baseWhile(array, getCallback(predicate, thisArg, 3), true, true)
+ : [];
+ }
+ function dropWhile(array, predicate, thisArg) {
+ return (array && array.length)
+ ? baseWhile(array, getCallback(predicate, thisArg, 3), true)
+ : [];
+ }
+ function fill(array, value, start, end) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (start && typeof start != 'number' && isIterateeCall(array, value, start)) {
+ start = 0;
+ end = length;
+ }
+ return baseFill(array, value, start, end);
+ }
+ var findIndex = createFindIndex();
+ var findLastIndex = createFindIndex(true);
+ function first(array) {
+ return array ? array[0] : undefined;
+ }
+ function flatten(array, isDeep, guard) {
+ var length = array ? array.length : 0;
+ if (guard && isIterateeCall(array, isDeep, guard)) {
+ isDeep = false;
+ }
+ return length ? baseFlatten(array, isDeep) : [];
+ }
+ function flattenDeep(array) {
+ var length = array ? array.length : 0;
+ return length ? baseFlatten(array, true) : [];
+ }
+ function indexOf(array, value, fromIndex) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return -1;
+ }
+ if (typeof fromIndex == 'number') {
+ fromIndex = fromIndex < 0 ? nativeMax(length + fromIndex, 0) : fromIndex;
+ } else if (fromIndex) {
+ var index = binaryIndex(array, value);
+ if (index < length &&
+ (value === value ? (value === array[index]) : (array[index] !== array[index]))) {
+ return index;
+ }
+ return -1;
+ }
+ return baseIndexOf(array, value, fromIndex || 0);
+ }
+ function initial(array) {
+ return dropRight(array, 1);
+ }
+ var intersection = restParam(function(arrays) {
+ var othLength = arrays.length,
+ othIndex = othLength,
+ caches = Array(length),
+ indexOf = getIndexOf(),
+ isCommon = indexOf == baseIndexOf,
+ result = [];
+
+ while (othIndex--) {
+ var value = arrays[othIndex] = isArrayLike(value = arrays[othIndex]) ? value : [];
+ caches[othIndex] = (isCommon && value.length >= 120) ? createCache(othIndex && value) : null;
+ }
+ var array = arrays[0],
+ index = -1,
+ length = array ? array.length : 0,
+ seen = caches[0];
+
+ outer:
+ while (++index < length) {
+ value = array[index];
+ if ((seen ? cacheIndexOf(seen, value) : indexOf(result, value, 0)) < 0) {
+ var othIndex = othLength;
+ while (--othIndex) {
+ var cache = caches[othIndex];
+ if ((cache ? cacheIndexOf(cache, value) : indexOf(arrays[othIndex], value, 0)) < 0) {
+ continue outer;
+ }
+ }
+ if (seen) {
+ seen.push(value);
+ }
+ result.push(value);
+ }
+ }
+ return result;
+ });
+ function last(array) {
+ var length = array ? array.length : 0;
+ return length ? array[length - 1] : undefined;
+ }
+ function lastIndexOf(array, value, fromIndex) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return -1;
+ }
+ var index = length;
+ if (typeof fromIndex == 'number') {
+ index = (fromIndex < 0 ? nativeMax(length + fromIndex, 0) : nativeMin(fromIndex || 0, length - 1)) + 1;
+ } else if (fromIndex) {
+ index = binaryIndex(array, value, true) - 1;
+ var other = array[index];
+ if (value === value ? (value === other) : (other !== other)) {
+ return index;
+ }
+ return -1;
+ }
+ if (value !== value) {
+ return indexOfNaN(array, index, true);
+ }
+ while (index--) {
+ if (array[index] === value) {
+ return index;
+ }
+ }
+ return -1;
+ }
+ function pull() {
+ var args = arguments,
+ array = args[0];
+
+ if (!(array && array.length)) {
+ return array;
+ }
+ var index = 0,
+ indexOf = getIndexOf(),
+ length = args.length;
+
+ while (++index < length) {
+ var fromIndex = 0,
+ value = args[index];
+
+ while ((fromIndex = indexOf(array, value, fromIndex)) > -1) {
+ splice.call(array, fromIndex, 1);
+ }
+ }
+ return array;
+ }
+ var pullAt = restParam(function(array, indexes) {
+ indexes = baseFlatten(indexes);
+
+ var result = baseAt(array, indexes);
+ basePullAt(array, indexes.sort(baseCompareAscending));
+ return result;
+ });
+ function remove(array, predicate, thisArg) {
+ var result = [];
+ if (!(array && array.length)) {
+ return result;
+ }
+ var index = -1,
+ indexes = [],
+ length = array.length;
+
+ predicate = getCallback(predicate, thisArg, 3);
+ while (++index < length) {
+ var value = array[index];
+ if (predicate(value, index, array)) {
+ result.push(value);
+ indexes.push(index);
+ }
+ }
+ basePullAt(array, indexes);
+ return result;
+ }
+ function rest(array) {
+ return drop(array, 1);
+ }
+ function slice(array, start, end) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (end && typeof end != 'number' && isIterateeCall(array, start, end)) {
+ start = 0;
+ end = length;
+ }
+ return baseSlice(array, start, end);
+ }
+ var sortedIndex = createSortedIndex();
+ var sortedLastIndex = createSortedIndex(true);
+ function take(array, n, guard) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (guard ? isIterateeCall(array, n, guard) : n == null) {
+ n = 1;
+ }
+ return baseSlice(array, 0, n < 0 ? 0 : n);
+ }
+ function takeRight(array, n, guard) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (guard ? isIterateeCall(array, n, guard) : n == null) {
+ n = 1;
+ }
+ n = length - (+n || 0);
+ return baseSlice(array, n < 0 ? 0 : n);
+ }
+ function takeRightWhile(array, predicate, thisArg) {
+ return (array && array.length)
+ ? baseWhile(array, getCallback(predicate, thisArg, 3), false, true)
+ : [];
+ }
+ function takeWhile(array, predicate, thisArg) {
+ return (array && array.length)
+ ? baseWhile(array, getCallback(predicate, thisArg, 3))
+ : [];
+ }
+ var union = restParam(function(arrays) {
+ return baseUniq(baseFlatten(arrays, false, true));
+ });
+ function uniq(array, isSorted, iteratee, thisArg) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ if (isSorted != null && typeof isSorted != 'boolean') {
+ thisArg = iteratee;
+ iteratee = isIterateeCall(array, isSorted, thisArg) ? undefined : isSorted;
+ isSorted = false;
+ }
+ var callback = getCallback();
+ if (!(iteratee == null && callback === baseCallback)) {
+ iteratee = callback(iteratee, thisArg, 3);
+ }
+ return (isSorted && getIndexOf() == baseIndexOf)
+ ? sortedUniq(array, iteratee)
+ : baseUniq(array, iteratee);
+ }
+ function unzip(array) {
+ if (!(array && array.length)) {
+ return [];
+ }
+ var index = -1,
+ length = 0;
+
+ array = arrayFilter(array, function(group) {
+ if (isArrayLike(group)) {
+ length = nativeMax(group.length, length);
+ return true;
+ }
+ });
+ var result = Array(length);
+ while (++index < length) {
+ result[index] = arrayMap(array, baseProperty(index));
+ }
+ return result;
+ }
+ function unzipWith(array, iteratee, thisArg) {
+ var length = array ? array.length : 0;
+ if (!length) {
+ return [];
+ }
+ var result = unzip(array);
+ if (iteratee == null) {
+ return result;
+ }
+ iteratee = bindCallback(iteratee, thisArg, 4);
+ return arrayMap(result, function(group) {
+ return arrayReduce(group, iteratee, undefined, true);
+ });
+ }
+ var without = restParam(function(array, values) {
+ return isArrayLike(array)
+ ? baseDifference(array, values)
+ : [];
+ });
+ function xor() {
+ var index = -1,
+ length = arguments.length;
+
+ while (++index < length) {
+ var array = arguments[index];
+ if (isArrayLike(array)) {
+ var result = result
+ ? arrayPush(baseDifference(result, array), baseDifference(array, result))
+ : array;
+ }
+ }
+ return result ? baseUniq(result) : [];
+ }
+ var zip = restParam(unzip);
+ function zipObject(props, values) {
+ var index = -1,
+ length = props ? props.length : 0,
+ result = {};
+
+ if (length && !values && !isArray(props[0])) {
+ values = [];
+ }
+ while (++index < length) {
+ var key = props[index];
+ if (values) {
+ result[key] = values[index];
+ } else if (key) {
+ result[key[0]] = key[1];
+ }
+ }
+ return result;
+ }
+ var zipWith = restParam(function(arrays) {
+ var length = arrays.length,
+ iteratee = length > 2 ? arrays[length - 2] : undefined,
+ thisArg = length > 1 ? arrays[length - 1] : undefined;
+
+ if (length > 2 && typeof iteratee == 'function') {
+ length -= 2;
+ } else {
+ iteratee = (length > 1 && typeof thisArg == 'function') ? (--length, thisArg) : undefined;
+ thisArg = undefined;
+ }
+ arrays.length = length;
+ return unzipWith(arrays, iteratee, thisArg);
+ });
+ function chain(value) {
+ var result = lodash(value);
+ result.__chain__ = true;
+ return result;
+ }
+ function tap(value, interceptor, thisArg) {
+ interceptor.call(thisArg, value);
+ return value;
+ }
+ function thru(value, interceptor, thisArg) {
+ return interceptor.call(thisArg, value);
+ }
+ function wrapperChain() {
+ return chain(this);
+ }
+ function wrapperCommit() {
+ return new LodashWrapper(this.value(), this.__chain__);
+ }
+ var wrapperConcat = restParam(function(values) {
+ values = baseFlatten(values);
+ return this.thru(function(array) {
+ return arrayConcat(isArray(array) ? array : [toObject(array)], values);
+ });
+ });
+ function wrapperPlant(value) {
+ var result,
+ parent = this;
+
+ while (parent instanceof baseLodash) {
+ var clone = wrapperClone(parent);
+ if (result) {
+ previous.__wrapped__ = clone;
+ } else {
+ result = clone;
+ }
+ var previous = clone;
+ parent = parent.__wrapped__;
+ }
+ previous.__wrapped__ = value;
+ return result;
+ }
+ function wrapperReverse() {
+ var value = this.__wrapped__;
+
+ var interceptor = function(value) {
+ return (wrapped && wrapped.__dir__ < 0) ? value : value.reverse();
+ };
+ if (value instanceof LazyWrapper) {
+ var wrapped = value;
+ if (this.__actions__.length) {
+ wrapped = new LazyWrapper(this);
+ }
+ wrapped = wrapped.reverse();
+ wrapped.__actions__.push({ 'func': thru, 'args': [interceptor], 'thisArg': undefined });
+ return new LodashWrapper(wrapped, this.__chain__);
+ }
+ return this.thru(interceptor);
+ }
+ function wrapperToString() {
+ return (this.value() + '');
+ }
+ function wrapperValue() {
+ return baseWrapperValue(this.__wrapped__, this.__actions__);
+ }
+ var at = restParam(function(collection, props) {
+ return baseAt(collection, baseFlatten(props));
+ });
+ var countBy = createAggregator(function(result, value, key) {
+ hasOwnProperty.call(result, key) ? ++result[key] : (result[key] = 1);
+ });
+ function every(collection, predicate, thisArg) {
+ var func = isArray(collection) ? arrayEvery : baseEvery;
+ if (thisArg && isIterateeCall(collection, predicate, thisArg)) {
+ predicate = undefined;
+ }
+ if (typeof predicate != 'function' || thisArg !== undefined) {
+ predicate = getCallback(predicate, thisArg, 3);
+ }
+ return func(collection, predicate);
+ }
+ function filter(collection, predicate, thisArg) {
+ var func = isArray(collection) ? arrayFilter : baseFilter;
+ predicate = getCallback(predicate, thisArg, 3);
+ return func(collection, predicate);
+ }
+ var find = createFind(baseEach);
+ var findLast = createFind(baseEachRight, true);
+ function findWhere(collection, source) {
+ return find(collection, baseMatches(source));
+ }
+ var forEach = createForEach(arrayEach, baseEach);
+ var forEachRight = createForEach(arrayEachRight, baseEachRight);
+ var groupBy = createAggregator(function(result, value, key) {
+ if (hasOwnProperty.call(result, key)) {
+ result[key].push(value);
+ } else {
+ result[key] = [value];
+ }
+ });
+ function includes(collection, target, fromIndex, guard) {
+ var length = collection ? getLength(collection) : 0;
+ if (!isLength(length)) {
+ collection = values(collection);
+ length = collection.length;
+ }
+ if (typeof fromIndex != 'number' || (guard && isIterateeCall(target, fromIndex, guard))) {
+ fromIndex = 0;
+ } else {
+ fromIndex = fromIndex < 0 ? nativeMax(length + fromIndex, 0) : (fromIndex || 0);
+ }
+ return (typeof collection == 'string' || !isArray(collection) && isString(collection))
+ ? (fromIndex <= length && collection.indexOf(target, fromIndex) > -1)
+ : (!!length && getIndexOf(collection, target, fromIndex) > -1);
+ }
+ var indexBy = createAggregator(function(result, value, key) {
+ result[key] = value;
+ });
+ var invoke = restParam(function(collection, path, args) {
+ var index = -1,
+ isFunc = typeof path == 'function',
+ isProp = isKey(path),
+ result = isArrayLike(collection) ? Array(collection.length) : [];
+
+ baseEach(collection, function(value) {
+ var func = isFunc ? path : ((isProp && value != null) ? value[path] : undefined);
+ result[++index] = func ? func.apply(value, args) : invokePath(value, path, args);
+ });
+ return result;
+ });
+ function map(collection, iteratee, thisArg) {
+ var func = isArray(collection) ? arrayMap : baseMap;
+ iteratee = getCallback(iteratee, thisArg, 3);
+ return func(collection, iteratee);
+ }
+ var partition = createAggregator(function(result, value, key) {
+ result[key ? 0 : 1].push(value);
+ }, function() { return [[], []]; });
+ function pluck(collection, path) {
+ return map(collection, property(path));
+ }
+ var reduce = createReduce(arrayReduce, baseEach);
+ var reduceRight = createReduce(arrayReduceRight, baseEachRight);
+ function reject(collection, predicate, thisArg) {
+ var func = isArray(collection) ? arrayFilter : baseFilter;
+ predicate = getCallback(predicate, thisArg, 3);
+ return func(collection, function(value, index, collection) {
+ return !predicate(value, index, collection);
+ });
+ }
+ function sample(collection, n, guard) {
+ if (guard ? isIterateeCall(collection, n, guard) : n == null) {
+ collection = toIterable(collection);
+ var length = collection.length;
+ return length > 0 ? collection[baseRandom(0, length - 1)] : undefined;
+ }
+ var index = -1,
+ result = toArray(collection),
+ length = result.length,
+ lastIndex = length - 1;
+
+ n = nativeMin(n < 0 ? 0 : (+n || 0), length);
+ while (++index < n) {
+ var rand = baseRandom(index, lastIndex),
+ value = result[rand];
+
+ result[rand] = result[index];
+ result[index] = value;
+ }
+ result.length = n;
+ return result;
+ }
+ function shuffle(collection) {
+ return sample(collection, POSITIVE_INFINITY);
+ }
+ function size(collection) {
+ var length = collection ? getLength(collection) : 0;
+ return isLength(length) ? length : keys(collection).length;
+ }
+ function some(collection, predicate, thisArg) {
+ var func = isArray(collection) ? arraySome : baseSome;
+ if (thisArg && isIterateeCall(collection, predicate, thisArg)) {
+ predicate = undefined;
+ }
+ if (typeof predicate != 'function' || thisArg !== undefined) {
+ predicate = getCallback(predicate, thisArg, 3);
+ }
+ return func(collection, predicate);
+ }
+ function sortBy(collection, iteratee, thisArg) {
+ if (collection == null) {
+ return [];
+ }
+ if (thisArg && isIterateeCall(collection, iteratee, thisArg)) {
+ iteratee = undefined;
+ }
+ var index = -1;
+ iteratee = getCallback(iteratee, thisArg, 3);
+
+ var result = baseMap(collection, function(value, key, collection) {
+ return { 'criteria': iteratee(value, key, collection), 'index': ++index, 'value': value };
+ });
+ return baseSortBy(result, compareAscending);
+ }
+ var sortByAll = restParam(function(collection, iteratees) {
+ if (collection == null) {
+ return [];
+ }
+ var guard = iteratees[2];
+ if (guard && isIterateeCall(iteratees[0], iteratees[1], guard)) {
+ iteratees.length = 1;
+ }
+ return baseSortByOrder(collection, baseFlatten(iteratees), []);
+ });
+ function sortByOrder(collection, iteratees, orders, guard) {
+ if (collection == null) {
+ return [];
+ }
+ if (guard && isIterateeCall(iteratees, orders, guard)) {
+ orders = undefined;
+ }
+ if (!isArray(iteratees)) {
+ iteratees = iteratees == null ? [] : [iteratees];
+ }
+ if (!isArray(orders)) {
+ orders = orders == null ? [] : [orders];
+ }
+ return baseSortByOrder(collection, iteratees, orders);
+ }
+ function where(collection, source) {
+ return filter(collection, baseMatches(source));
+ }
+ var now = nativeNow || function() {
+ return new Date().getTime();
+ };
+ function after(n, func) {
+ if (typeof func != 'function') {
+ if (typeof n == 'function') {
+ var temp = n;
+ n = func;
+ func = temp;
+ } else {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ }
+ n = nativeIsFinite(n = +n) ? n : 0;
+ return function() {
+ if (--n < 1) {
+ return func.apply(this, arguments);
+ }
+ };
+ }
+ function ary(func, n, guard) {
+ if (guard && isIterateeCall(func, n, guard)) {
+ n = undefined;
+ }
+ n = (func && n == null) ? func.length : nativeMax(+n || 0, 0);
+ return createWrapper(func, ARY_FLAG, undefined, undefined, undefined, undefined, n);
+ }
+ function before(n, func) {
+ var result;
+ if (typeof func != 'function') {
+ if (typeof n == 'function') {
+ var temp = n;
+ n = func;
+ func = temp;
+ } else {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ }
+ return function() {
+ if (--n > 0) {
+ result = func.apply(this, arguments);
+ }
+ if (n <= 1) {
+ func = undefined;
+ }
+ return result;
+ };
+ }
+ var bind = restParam(function(func, thisArg, partials) {
+ var bitmask = BIND_FLAG;
+ if (partials.length) {
+ var holders = replaceHolders(partials, bind.placeholder);
+ bitmask |= PARTIAL_FLAG;
+ }
+ return createWrapper(func, bitmask, thisArg, partials, holders);
+ });
+ var bindAll = restParam(function(object, methodNames) {
+ methodNames = methodNames.length ? baseFlatten(methodNames) : functions(object);
+
+ var index = -1,
+ length = methodNames.length;
+
+ while (++index < length) {
+ var key = methodNames[index];
+ object[key] = createWrapper(object[key], BIND_FLAG, object);
+ }
+ return object;
+ });
+ var bindKey = restParam(function(object, key, partials) {
+ var bitmask = BIND_FLAG | BIND_KEY_FLAG;
+ if (partials.length) {
+ var holders = replaceHolders(partials, bindKey.placeholder);
+ bitmask |= PARTIAL_FLAG;
+ }
+ return createWrapper(key, bitmask, object, partials, holders);
+ });
+ var curry = createCurry(CURRY_FLAG);
+ var curryRight = createCurry(CURRY_RIGHT_FLAG);
+ function debounce(func, wait, options) {
+ var args,
+ maxTimeoutId,
+ result,
+ stamp,
+ thisArg,
+ timeoutId,
+ trailingCall,
+ lastCalled = 0,
+ maxWait = false,
+ trailing = true;
+
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ wait = wait < 0 ? 0 : (+wait || 0);
+ if (options === true) {
+ var leading = true;
+ trailing = false;
+ } else if (isObject(options)) {
+ leading = !!options.leading;
+ maxWait = 'maxWait' in options && nativeMax(+options.maxWait || 0, wait);
+ trailing = 'trailing' in options ? !!options.trailing : trailing;
+ }
+
+ function cancel() {
+ if (timeoutId) {
+ clearTimeout(timeoutId);
+ }
+ if (maxTimeoutId) {
+ clearTimeout(maxTimeoutId);
+ }
+ lastCalled = 0;
+ maxTimeoutId = timeoutId = trailingCall = undefined;
+ }
+
+ function complete(isCalled, id) {
+ if (id) {
+ clearTimeout(id);
+ }
+ maxTimeoutId = timeoutId = trailingCall = undefined;
+ if (isCalled) {
+ lastCalled = now();
+ result = func.apply(thisArg, args);
+ if (!timeoutId && !maxTimeoutId) {
+ args = thisArg = undefined;
+ }
+ }
+ }
+
+ function delayed() {
+ var remaining = wait - (now() - stamp);
+ if (remaining <= 0 || remaining > wait) {
+ complete(trailingCall, maxTimeoutId);
+ } else {
+ timeoutId = setTimeout(delayed, remaining);
+ }
+ }
+
+ function maxDelayed() {
+ complete(trailing, timeoutId);
+ }
+
+ function debounced() {
+ args = arguments;
+ stamp = now();
+ thisArg = this;
+ trailingCall = trailing && (timeoutId || !leading);
+
+ if (maxWait === false) {
+ var leadingCall = leading && !timeoutId;
+ } else {
+ if (!maxTimeoutId && !leading) {
+ lastCalled = stamp;
+ }
+ var remaining = maxWait - (stamp - lastCalled),
+ isCalled = remaining <= 0 || remaining > maxWait;
+
+ if (isCalled) {
+ if (maxTimeoutId) {
+ maxTimeoutId = clearTimeout(maxTimeoutId);
+ }
+ lastCalled = stamp;
+ result = func.apply(thisArg, args);
+ }
+ else if (!maxTimeoutId) {
+ maxTimeoutId = setTimeout(maxDelayed, remaining);
+ }
+ }
+ if (isCalled && timeoutId) {
+ timeoutId = clearTimeout(timeoutId);
+ }
+ else if (!timeoutId && wait !== maxWait) {
+ timeoutId = setTimeout(delayed, wait);
+ }
+ if (leadingCall) {
+ isCalled = true;
+ result = func.apply(thisArg, args);
+ }
+ if (isCalled && !timeoutId && !maxTimeoutId) {
+ args = thisArg = undefined;
+ }
+ return result;
+ }
+ debounced.cancel = cancel;
+ return debounced;
+ }
+ var defer = restParam(function(func, args) {
+ return baseDelay(func, 1, args);
+ });
+ var delay = restParam(function(func, wait, args) {
+ return baseDelay(func, wait, args);
+ });
+ var flow = createFlow();
+ var flowRight = createFlow(true);
+ function memoize(func, resolver) {
+ if (typeof func != 'function' || (resolver && typeof resolver != 'function')) {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ var memoized = function() {
+ var args = arguments,
+ key = resolver ? resolver.apply(this, args) : args[0],
+ cache = memoized.cache;
+
+ if (cache.has(key)) {
+ return cache.get(key);
+ }
+ var result = func.apply(this, args);
+ memoized.cache = cache.set(key, result);
+ return result;
+ };
+ memoized.cache = new memoize.Cache;
+ return memoized;
+ }
+ var modArgs = restParam(function(func, transforms) {
+ transforms = baseFlatten(transforms);
+ if (typeof func != 'function' || !arrayEvery(transforms, baseIsFunction)) {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ var length = transforms.length;
+ return restParam(function(args) {
+ var index = nativeMin(args.length, length);
+ while (index--) {
+ args[index] = transforms[index](args[index]);
+ }
+ return func.apply(this, args);
+ });
+ });
+ function negate(predicate) {
+ if (typeof predicate != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ return function() {
+ return !predicate.apply(this, arguments);
+ };
+ }
+ function once(func) {
+ return before(2, func);
+ }
+ var partial = createPartial(PARTIAL_FLAG);
+ var partialRight = createPartial(PARTIAL_RIGHT_FLAG);
+ var rearg = restParam(function(func, indexes) {
+ return createWrapper(func, REARG_FLAG, undefined, undefined, undefined, baseFlatten(indexes));
+ });
+ function restParam(func, start) {
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ start = nativeMax(start === undefined ? (func.length - 1) : (+start || 0), 0);
+ return function() {
+ var args = arguments,
+ index = -1,
+ length = nativeMax(args.length - start, 0),
+ rest = Array(length);
+
+ while (++index < length) {
+ rest[index] = args[start + index];
+ }
+ switch (start) {
+ case 0: return func.call(this, rest);
+ case 1: return func.call(this, args[0], rest);
+ case 2: return func.call(this, args[0], args[1], rest);
+ }
+ var otherArgs = Array(start + 1);
+ index = -1;
+ while (++index < start) {
+ otherArgs[index] = args[index];
+ }
+ otherArgs[start] = rest;
+ return func.apply(this, otherArgs);
+ };
+ }
+ function spread(func) {
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ return function(array) {
+ return func.apply(this, array);
+ };
+ }
+ function throttle(func, wait, options) {
+ var leading = true,
+ trailing = true;
+
+ if (typeof func != 'function') {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ if (options === false) {
+ leading = false;
+ } else if (isObject(options)) {
+ leading = 'leading' in options ? !!options.leading : leading;
+ trailing = 'trailing' in options ? !!options.trailing : trailing;
+ }
+ return debounce(func, wait, { 'leading': leading, 'maxWait': +wait, 'trailing': trailing });
+ }
+ function wrap(value, wrapper) {
+ wrapper = wrapper == null ? identity : wrapper;
+ return createWrapper(wrapper, PARTIAL_FLAG, undefined, [value], []);
+ }
+ function clone(value, isDeep, customizer, thisArg) {
+ if (isDeep && typeof isDeep != 'boolean' && isIterateeCall(value, isDeep, customizer)) {
+ isDeep = false;
+ }
+ else if (typeof isDeep == 'function') {
+ thisArg = customizer;
+ customizer = isDeep;
+ isDeep = false;
+ }
+ return typeof customizer == 'function'
+ ? baseClone(value, isDeep, bindCallback(customizer, thisArg, 1))
+ : baseClone(value, isDeep);
+ }
+ function cloneDeep(value, customizer, thisArg) {
+ return typeof customizer == 'function'
+ ? baseClone(value, true, bindCallback(customizer, thisArg, 1))
+ : baseClone(value, true);
+ }
+ function gt(value, other) {
+ return value > other;
+ }
+ function gte(value, other) {
+ return value >= other;
+ }
+ function isArguments(value) {
+ return isObjectLike(value) && isArrayLike(value) &&
+ hasOwnProperty.call(value, 'callee') && !propertyIsEnumerable.call(value, 'callee');
+ }
+ var isArray = nativeIsArray || function(value) {
+ return isObjectLike(value) && isLength(value.length) && objToString.call(value) == arrayTag;
+ };
+ function isBoolean(value) {
+ return value === true || value === false || (isObjectLike(value) && objToString.call(value) == boolTag);
+ }
+ function isDate(value) {
+ return isObjectLike(value) && objToString.call(value) == dateTag;
+ }
+ function isElement(value) {
+ return !!value && value.nodeType === 1 && isObjectLike(value) && !isPlainObject(value);
+ }
+ function isEmpty(value) {
+ if (value == null) {
+ return true;
+ }
+ if (isArrayLike(value) && (isArray(value) || isString(value) || isArguments(value) ||
+ (isObjectLike(value) && isFunction(value.splice)))) {
+ return !value.length;
+ }
+ return !keys(value).length;
+ }
+ function isEqual(value, other, customizer, thisArg) {
+ customizer = typeof customizer == 'function' ? bindCallback(customizer, thisArg, 3) : undefined;
+ var result = customizer ? customizer(value, other) : undefined;
+ return result === undefined ? baseIsEqual(value, other, customizer) : !!result;
+ }
+ function isError(value) {
+ return isObjectLike(value) && typeof value.message == 'string' && objToString.call(value) == errorTag;
+ }
+ function isFinite(value) {
+ return typeof value == 'number' && nativeIsFinite(value);
+ }
+ function isFunction(value) {
+ return isObject(value) && objToString.call(value) == funcTag;
+ }
+ function isObject(value) {
+ var type = typeof value;
+ return !!value && (type == 'object' || type == 'function');
+ }
+ function isMatch(object, source, customizer, thisArg) {
+ customizer = typeof customizer == 'function' ? bindCallback(customizer, thisArg, 3) : undefined;
+ return baseIsMatch(object, getMatchData(source), customizer);
+ }
+ function isNaN(value) {
+ return isNumber(value) && value != +value;
+ }
+ function isNative(value) {
+ if (value == null) {
+ return false;
+ }
+ if (isFunction(value)) {
+ return reIsNative.test(fnToString.call(value));
+ }
+ return isObjectLike(value) && reIsHostCtor.test(value);
+ }
+ function isNull(value) {
+ return value === null;
+ }
+ function isNumber(value) {
+ return typeof value == 'number' || (isObjectLike(value) && objToString.call(value) == numberTag);
+ }
+ function isPlainObject(value) {
+ var Ctor;
+ if (!(isObjectLike(value) && objToString.call(value) == objectTag && !isArguments(value)) ||
+ (!hasOwnProperty.call(value, 'constructor') && (Ctor = value.constructor, typeof Ctor == 'function' && !(Ctor instanceof Ctor)))) {
+ return false;
+ }
+ var result;
+ baseForIn(value, function(subValue, key) {
+ result = key;
+ });
+ return result === undefined || hasOwnProperty.call(value, result);
+ }
+ function isRegExp(value) {
+ return isObject(value) && objToString.call(value) == regexpTag;
+ }
+ function isString(value) {
+ return typeof value == 'string' || (isObjectLike(value) && objToString.call(value) == stringTag);
+ }
+ function isTypedArray(value) {
+ return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[objToString.call(value)];
+ }
+ function isUndefined(value) {
+ return value === undefined;
+ }
+ function lt(value, other) {
+ return value < other;
+ }
+ function lte(value, other) {
+ return value <= other;
+ }
+ function toArray(value) {
+ var length = value ? getLength(value) : 0;
+ if (!isLength(length)) {
+ return values(value);
+ }
+ if (!length) {
+ return [];
+ }
+ return arrayCopy(value);
+ }
+ function toPlainObject(value) {
+ return baseCopy(value, keysIn(value));
+ }
+ var merge = createAssigner(baseMerge);
+ var assign = createAssigner(function(object, source, customizer) {
+ return customizer
+ ? assignWith(object, source, customizer)
+ : baseAssign(object, source);
+ });
+ function create(prototype, properties, guard) {
+ var result = baseCreate(prototype);
+ if (guard && isIterateeCall(prototype, properties, guard)) {
+ properties = undefined;
+ }
+ return properties ? baseAssign(result, properties) : result;
+ }
+ var defaults = createDefaults(assign, assignDefaults);
+ var defaultsDeep = createDefaults(merge, mergeDefaults);
+ var findKey = createFindKey(baseForOwn);
+ var findLastKey = createFindKey(baseForOwnRight);
+ var forIn = createForIn(baseFor);
+ var forInRight = createForIn(baseForRight);
+ var forOwn = createForOwn(baseForOwn);
+ var forOwnRight = createForOwn(baseForOwnRight);
+ function functions(object) {
+ return baseFunctions(object, keysIn(object));
+ }
+ function get(object, path, defaultValue) {
+ var result = object == null ? undefined : baseGet(object, toPath(path), path + '');
+ return result === undefined ? defaultValue : result;
+ }
+ function has(object, path) {
+ if (object == null) {
+ return false;
+ }
+ var result = hasOwnProperty.call(object, path);
+ if (!result && !isKey(path)) {
+ path = toPath(path);
+ object = path.length == 1 ? object : baseGet(object, baseSlice(path, 0, -1));
+ if (object == null) {
+ return false;
+ }
+ path = last(path);
+ result = hasOwnProperty.call(object, path);
+ }
+ return result || (isLength(object.length) && isIndex(path, object.length) &&
+ (isArray(object) || isArguments(object)));
+ }
+ function invert(object, multiValue, guard) {
+ if (guard && isIterateeCall(object, multiValue, guard)) {
+ multiValue = undefined;
+ }
+ var index = -1,
+ props = keys(object),
+ length = props.length,
+ result = {};
+
+ while (++index < length) {
+ var key = props[index],
+ value = object[key];
+
+ if (multiValue) {
+ if (hasOwnProperty.call(result, value)) {
+ result[value].push(key);
+ } else {
+ result[value] = [key];
+ }
+ }
+ else {
+ result[value] = key;
+ }
+ }
+ return result;
+ }
+ var keys = !nativeKeys ? shimKeys : function(object) {
+ var Ctor = object == null ? undefined : object.constructor;
+ if ((typeof Ctor == 'function' && Ctor.prototype === object) ||
+ (typeof object != 'function' && isArrayLike(object))) {
+ return shimKeys(object);
+ }
+ return isObject(object) ? nativeKeys(object) : [];
+ };
+ function keysIn(object) {
+ if (object == null) {
+ return [];
+ }
+ if (!isObject(object)) {
+ object = Object(object);
+ }
+ var length = object.length;
+ length = (length && isLength(length) &&
+ (isArray(object) || isArguments(object)) && length) || 0;
+
+ var Ctor = object.constructor,
+ index = -1,
+ isProto = typeof Ctor == 'function' && Ctor.prototype === object,
+ result = Array(length),
+ skipIndexes = length > 0;
+
+ while (++index < length) {
+ result[index] = (index + '');
+ }
+ for (var key in object) {
+ if (!(skipIndexes && isIndex(key, length)) &&
+ !(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {
+ result.push(key);
+ }
+ }
+ return result;
+ }
+ var mapKeys = createObjectMapper(true);
+ var mapValues = createObjectMapper();
+ var omit = restParam(function(object, props) {
+ if (object == null) {
+ return {};
+ }
+ if (typeof props[0] != 'function') {
+ var props = arrayMap(baseFlatten(props), String);
+ return pickByArray(object, baseDifference(keysIn(object), props));
+ }
+ var predicate = bindCallback(props[0], props[1], 3);
+ return pickByCallback(object, function(value, key, object) {
+ return !predicate(value, key, object);
+ });
+ });
+ function pairs(object) {
+ object = toObject(object);
+
+ var index = -1,
+ props = keys(object),
+ length = props.length,
+ result = Array(length);
+
+ while (++index < length) {
+ var key = props[index];
+ result[index] = [key, object[key]];
+ }
+ return result;
+ }
+ var pick = restParam(function(object, props) {
+ if (object == null) {
+ return {};
+ }
+ return typeof props[0] == 'function'
+ ? pickByCallback(object, bindCallback(props[0], props[1], 3))
+ : pickByArray(object, baseFlatten(props));
+ });
+ function result(object, path, defaultValue) {
+ var result = object == null ? undefined : object[path];
+ if (result === undefined) {
+ if (object != null && !isKey(path, object)) {
+ path = toPath(path);
+ object = path.length == 1 ? object : baseGet(object, baseSlice(path, 0, -1));
+ result = object == null ? undefined : object[last(path)];
+ }
+ result = result === undefined ? defaultValue : result;
+ }
+ return isFunction(result) ? result.call(object) : result;
+ }
+ function set(object, path, value) {
+ if (object == null) {
+ return object;
+ }
+ var pathKey = (path + '');
+ path = (object[pathKey] != null || isKey(path, object)) ? [pathKey] : toPath(path);
+
+ var index = -1,
+ length = path.length,
+ lastIndex = length - 1,
+ nested = object;
+
+ while (nested != null && ++index < length) {
+ var key = path[index];
+ if (isObject(nested)) {
+ if (index == lastIndex) {
+ nested[key] = value;
+ } else if (nested[key] == null) {
+ nested[key] = isIndex(path[index + 1]) ? [] : {};
+ }
+ }
+ nested = nested[key];
+ }
+ return object;
+ }
+ function transform(object, iteratee, accumulator, thisArg) {
+ var isArr = isArray(object) || isTypedArray(object);
+ iteratee = getCallback(iteratee, thisArg, 4);
+
+ if (accumulator == null) {
+ if (isArr || isObject(object)) {
+ var Ctor = object.constructor;
+ if (isArr) {
+ accumulator = isArray(object) ? new Ctor : [];
+ } else {
+ accumulator = baseCreate(isFunction(Ctor) ? Ctor.prototype : undefined);
+ }
+ } else {
+ accumulator = {};
+ }
+ }
+ (isArr ? arrayEach : baseForOwn)(object, function(value, index, object) {
+ return iteratee(accumulator, value, index, object);
+ });
+ return accumulator;
+ }
+ function values(object) {
+ return baseValues(object, keys(object));
+ }
+ function valuesIn(object) {
+ return baseValues(object, keysIn(object));
+ }
+ function inRange(value, start, end) {
+ start = +start || 0;
+ if (end === undefined) {
+ end = start;
+ start = 0;
+ } else {
+ end = +end || 0;
+ }
+ return value >= nativeMin(start, end) && value < nativeMax(start, end);
+ }
+ function random(min, max, floating) {
+ if (floating && isIterateeCall(min, max, floating)) {
+ max = floating = undefined;
+ }
+ var noMin = min == null,
+ noMax = max == null;
+
+ if (floating == null) {
+ if (noMax && typeof min == 'boolean') {
+ floating = min;
+ min = 1;
+ }
+ else if (typeof max == 'boolean') {
+ floating = max;
+ noMax = true;
+ }
+ }
+ if (noMin && noMax) {
+ max = 1;
+ noMax = false;
+ }
+ min = +min || 0;
+ if (noMax) {
+ max = min;
+ min = 0;
+ } else {
+ max = +max || 0;
+ }
+ if (floating || min % 1 || max % 1) {
+ var rand = nativeRandom();
+ return nativeMin(min + (rand * (max - min + parseFloat('1e-' + ((rand + '').length - 1)))), max);
+ }
+ return baseRandom(min, max);
+ }
+ var camelCase = createCompounder(function(result, word, index) {
+ word = word.toLowerCase();
+ return result + (index ? (word.charAt(0).toUpperCase() + word.slice(1)) : word);
+ });
+ function capitalize(string) {
+ string = baseToString(string);
+ return string && (string.charAt(0).toUpperCase() + string.slice(1));
+ }
+ function deburr(string) {
+ string = baseToString(string);
+ return string && string.replace(reLatin1, deburrLetter).replace(reComboMark, '');
+ }
+ function endsWith(string, target, position) {
+ string = baseToString(string);
+ target = (target + '');
+
+ var length = string.length;
+ position = position === undefined
+ ? length
+ : nativeMin(position < 0 ? 0 : (+position || 0), length);
+
+ position -= target.length;
+ return position >= 0 && string.indexOf(target, position) == position;
+ }
+ function escape(string) {
+ string = baseToString(string);
+ return (string && reHasUnescapedHtml.test(string))
+ ? string.replace(reUnescapedHtml, escapeHtmlChar)
+ : string;
+ }
+ function escapeRegExp(string) {
+ string = baseToString(string);
+ return (string && reHasRegExpChars.test(string))
+ ? string.replace(reRegExpChars, escapeRegExpChar)
+ : (string || '(?:)');
+ }
+ var kebabCase = createCompounder(function(result, word, index) {
+ return result + (index ? '-' : '') + word.toLowerCase();
+ });
+ function pad(string, length, chars) {
+ string = baseToString(string);
+ length = +length;
+
+ var strLength = string.length;
+ if (strLength >= length || !nativeIsFinite(length)) {
+ return string;
+ }
+ var mid = (length - strLength) / 2,
+ leftLength = nativeFloor(mid),
+ rightLength = nativeCeil(mid);
+
+ chars = createPadding('', rightLength, chars);
+ return chars.slice(0, leftLength) + string + chars;
+ }
+ var padLeft = createPadDir();
+ var padRight = createPadDir(true);
+ function parseInt(string, radix, guard) {
+ if (guard ? isIterateeCall(string, radix, guard) : radix == null) {
+ radix = 0;
+ } else if (radix) {
+ radix = +radix;
+ }
+ string = trim(string);
+ return nativeParseInt(string, radix || (reHasHexPrefix.test(string) ? 16 : 10));
+ }
+ function repeat(string, n) {
+ var result = '';
+ string = baseToString(string);
+ n = +n;
+ if (n < 1 || !string || !nativeIsFinite(n)) {
+ return result;
+ }
+ do {
+ if (n % 2) {
+ result += string;
+ }
+ n = nativeFloor(n / 2);
+ string += string;
+ } while (n);
+
+ return result;
+ }
+ var snakeCase = createCompounder(function(result, word, index) {
+ return result + (index ? '_' : '') + word.toLowerCase();
+ });
+ var startCase = createCompounder(function(result, word, index) {
+ return result + (index ? ' ' : '') + (word.charAt(0).toUpperCase() + word.slice(1));
+ });
+ function startsWith(string, target, position) {
+ string = baseToString(string);
+ position = position == null
+ ? 0
+ : nativeMin(position < 0 ? 0 : (+position || 0), string.length);
+
+ return string.lastIndexOf(target, position) == position;
+ }
+ function template(string, options, otherOptions) {
+ var settings = lodash.templateSettings;
+
+ if (otherOptions && isIterateeCall(string, options, otherOptions)) {
+ options = otherOptions = undefined;
+ }
+ string = baseToString(string);
+ options = assignWith(baseAssign({}, otherOptions || options), settings, assignOwnDefaults);
+
+ var imports = assignWith(baseAssign({}, options.imports), settings.imports, assignOwnDefaults),
+ importsKeys = keys(imports),
+ importsValues = baseValues(imports, importsKeys);
+
+ var isEscaping,
+ isEvaluating,
+ index = 0,
+ interpolate = options.interpolate || reNoMatch,
+ source = "__p += '";
+ var reDelimiters = RegExp(
+ (options.escape || reNoMatch).source + '|' +
+ interpolate.source + '|' +
+ (interpolate === reInterpolate ? reEsTemplate : reNoMatch).source + '|' +
+ (options.evaluate || reNoMatch).source + '|$'
+ , 'g');
+ var sourceURL = '//# sourceURL=' +
+ ('sourceURL' in options
+ ? options.sourceURL
+ : ('lodash.templateSources[' + (++templateCounter) + ']')
+ ) + '\n';
+
+ string.replace(reDelimiters, function(match, escapeValue, interpolateValue, esTemplateValue, evaluateValue, offset) {
+ interpolateValue || (interpolateValue = esTemplateValue);
+ source += string.slice(index, offset).replace(reUnescapedString, escapeStringChar);
+ if (escapeValue) {
+ isEscaping = true;
+ source += "' +\n__e(" + escapeValue + ") +\n'";
+ }
+ if (evaluateValue) {
+ isEvaluating = true;
+ source += "';\n" + evaluateValue + ";\n__p += '";
+ }
+ if (interpolateValue) {
+ source += "' +\n((__t = (" + interpolateValue + ")) == null ? '' : __t) +\n'";
+ }
+ index = offset + match.length;
+ return match;
+ });
+
+ source += "';\n";
+ var variable = options.variable;
+ if (!variable) {
+ source = 'with (obj) {\n' + source + '\n}\n';
+ }
+ source = (isEvaluating ? source.replace(reEmptyStringLeading, '') : source)
+ .replace(reEmptyStringMiddle, '$1')
+ .replace(reEmptyStringTrailing, '$1;');
+ source = 'function(' + (variable || 'obj') + ') {\n' +
+ (variable
+ ? ''
+ : 'obj || (obj = {});\n'
+ ) +
+ "var __t, __p = ''" +
+ (isEscaping
+ ? ', __e = _.escape'
+ : ''
+ ) +
+ (isEvaluating
+ ? ', __j = Array.prototype.join;\n' +
+ "function print() { __p += __j.call(arguments, '') }\n"
+ : ';\n'
+ ) +
+ source +
+ 'return __p\n}';
+
+ var result = attempt(function() {
+ return Function(importsKeys, sourceURL + 'return ' + source).apply(undefined, importsValues);
+ });
+ result.source = source;
+ if (isError(result)) {
+ throw result;
+ }
+ return result;
+ }
+ function trim(string, chars, guard) {
+ var value = string;
+ string = baseToString(string);
+ if (!string) {
+ return string;
+ }
+ if (guard ? isIterateeCall(value, chars, guard) : chars == null) {
+ return string.slice(trimmedLeftIndex(string), trimmedRightIndex(string) + 1);
+ }
+ chars = (chars + '');
+ return string.slice(charsLeftIndex(string, chars), charsRightIndex(string, chars) + 1);
+ }
+ function trimLeft(string, chars, guard) {
+ var value = string;
+ string = baseToString(string);
+ if (!string) {
+ return string;
+ }
+ if (guard ? isIterateeCall(value, chars, guard) : chars == null) {
+ return string.slice(trimmedLeftIndex(string));
+ }
+ return string.slice(charsLeftIndex(string, (chars + '')));
+ }
+ function trimRight(string, chars, guard) {
+ var value = string;
+ string = baseToString(string);
+ if (!string) {
+ return string;
+ }
+ if (guard ? isIterateeCall(value, chars, guard) : chars == null) {
+ return string.slice(0, trimmedRightIndex(string) + 1);
+ }
+ return string.slice(0, charsRightIndex(string, (chars + '')) + 1);
+ }
+ function trunc(string, options, guard) {
+ if (guard && isIterateeCall(string, options, guard)) {
+ options = undefined;
+ }
+ var length = DEFAULT_TRUNC_LENGTH,
+ omission = DEFAULT_TRUNC_OMISSION;
+
+ if (options != null) {
+ if (isObject(options)) {
+ var separator = 'separator' in options ? options.separator : separator;
+ length = 'length' in options ? (+options.length || 0) : length;
+ omission = 'omission' in options ? baseToString(options.omission) : omission;
+ } else {
+ length = +options || 0;
+ }
+ }
+ string = baseToString(string);
+ if (length >= string.length) {
+ return string;
+ }
+ var end = length - omission.length;
+ if (end < 1) {
+ return omission;
+ }
+ var result = string.slice(0, end);
+ if (separator == null) {
+ return result + omission;
+ }
+ if (isRegExp(separator)) {
+ if (string.slice(end).search(separator)) {
+ var match,
+ newEnd,
+ substring = string.slice(0, end);
+
+ if (!separator.global) {
+ separator = RegExp(separator.source, (reFlags.exec(separator) || '') + 'g');
+ }
+ separator.lastIndex = 0;
+ while ((match = separator.exec(substring))) {
+ newEnd = match.index;
+ }
+ result = result.slice(0, newEnd == null ? end : newEnd);
+ }
+ } else if (string.indexOf(separator, end) != end) {
+ var index = result.lastIndexOf(separator);
+ if (index > -1) {
+ result = result.slice(0, index);
+ }
+ }
+ return result + omission;
+ }
+ function unescape(string) {
+ string = baseToString(string);
+ return (string && reHasEscapedHtml.test(string))
+ ? string.replace(reEscapedHtml, unescapeHtmlChar)
+ : string;
+ }
+ function words(string, pattern, guard) {
+ if (guard && isIterateeCall(string, pattern, guard)) {
+ pattern = undefined;
+ }
+ string = baseToString(string);
+ return string.match(pattern || reWords) || [];
+ }
+ var attempt = restParam(function(func, args) {
+ try {
+ return func.apply(undefined, args);
+ } catch(e) {
+ return isError(e) ? e : new Error(e);
+ }
+ });
+ function callback(func, thisArg, guard) {
+ if (guard && isIterateeCall(func, thisArg, guard)) {
+ thisArg = undefined;
+ }
+ return isObjectLike(func)
+ ? matches(func)
+ : baseCallback(func, thisArg);
+ }
+ function constant(value) {
+ return function() {
+ return value;
+ };
+ }
+ function identity(value) {
+ return value;
+ }
+ function matches(source) {
+ return baseMatches(baseClone(source, true));
+ }
+ function matchesProperty(path, srcValue) {
+ return baseMatchesProperty(path, baseClone(srcValue, true));
+ }
+ var method = restParam(function(path, args) {
+ return function(object) {
+ return invokePath(object, path, args);
+ };
+ });
+ var methodOf = restParam(function(object, args) {
+ return function(path) {
+ return invokePath(object, path, args);
+ };
+ });
+ function mixin(object, source, options) {
+ if (options == null) {
+ var isObj = isObject(source),
+ props = isObj ? keys(source) : undefined,
+ methodNames = (props && props.length) ? baseFunctions(source, props) : undefined;
+
+ if (!(methodNames ? methodNames.length : isObj)) {
+ methodNames = false;
+ options = source;
+ source = object;
+ object = this;
+ }
+ }
+ if (!methodNames) {
+ methodNames = baseFunctions(source, keys(source));
+ }
+ var chain = true,
+ index = -1,
+ isFunc = isFunction(object),
+ length = methodNames.length;
+
+ if (options === false) {
+ chain = false;
+ } else if (isObject(options) && 'chain' in options) {
+ chain = options.chain;
+ }
+ while (++index < length) {
+ var methodName = methodNames[index],
+ func = source[methodName];
+
+ object[methodName] = func;
+ if (isFunc) {
+ object.prototype[methodName] = (function(func) {
+ return function() {
+ var chainAll = this.__chain__;
+ if (chain || chainAll) {
+ var result = object(this.__wrapped__),
+ actions = result.__actions__ = arrayCopy(this.__actions__);
+
+ actions.push({ 'func': func, 'args': arguments, 'thisArg': object });
+ result.__chain__ = chainAll;
+ return result;
+ }
+ return func.apply(object, arrayPush([this.value()], arguments));
+ };
+ }(func));
+ }
+ }
+ return object;
+ }
+ function noConflict() {
+ root._ = oldDash;
+ return this;
+ }
+ function noop() {
+ }
+ function property(path) {
+ return isKey(path) ? baseProperty(path) : basePropertyDeep(path);
+ }
+ function propertyOf(object) {
+ return function(path) {
+ return baseGet(object, toPath(path), path + '');
+ };
+ }
+ function range(start, end, step) {
+ if (step && isIterateeCall(start, end, step)) {
+ end = step = undefined;
+ }
+ start = +start || 0;
+ step = step == null ? 1 : (+step || 0);
+
+ if (end == null) {
+ end = start;
+ start = 0;
+ } else {
+ end = +end || 0;
+ }
+ var index = -1,
+ length = nativeMax(nativeCeil((end - start) / (step || 1)), 0),
+ result = Array(length);
+
+ while (++index < length) {
+ result[index] = start;
+ start += step;
+ }
+ return result;
+ }
+ function times(n, iteratee, thisArg) {
+ n = nativeFloor(n);
+ if (n < 1 || !nativeIsFinite(n)) {
+ return [];
+ }
+ var index = -1,
+ result = Array(nativeMin(n, MAX_ARRAY_LENGTH));
+
+ iteratee = bindCallback(iteratee, thisArg, 1);
+ while (++index < n) {
+ if (index < MAX_ARRAY_LENGTH) {
+ result[index] = iteratee(index);
+ } else {
+ iteratee(index);
+ }
+ }
+ return result;
+ }
+ function uniqueId(prefix) {
+ var id = ++idCounter;
+ return baseToString(prefix) + id;
+ }
+ function add(augend, addend) {
+ return (+augend || 0) + (+addend || 0);
+ }
+ var ceil = createRound('ceil');
+ var floor = createRound('floor');
+ var max = createExtremum(gt, NEGATIVE_INFINITY);
+ var min = createExtremum(lt, POSITIVE_INFINITY);
+ var round = createRound('round');
+ function sum(collection, iteratee, thisArg) {
+ if (thisArg && isIterateeCall(collection, iteratee, thisArg)) {
+ iteratee = undefined;
+ }
+ iteratee = getCallback(iteratee, thisArg, 3);
+ return iteratee.length == 1
+ ? arraySum(isArray(collection) ? collection : toIterable(collection), iteratee)
+ : baseSum(collection, iteratee);
+ }
+ lodash.prototype = baseLodash.prototype;
+
+ LodashWrapper.prototype = baseCreate(baseLodash.prototype);
+ LodashWrapper.prototype.constructor = LodashWrapper;
+
+ LazyWrapper.prototype = baseCreate(baseLodash.prototype);
+ LazyWrapper.prototype.constructor = LazyWrapper;
+ MapCache.prototype['delete'] = mapDelete;
+ MapCache.prototype.get = mapGet;
+ MapCache.prototype.has = mapHas;
+ MapCache.prototype.set = mapSet;
+ SetCache.prototype.push = cachePush;
+ memoize.Cache = MapCache;
+ lodash.after = after;
+ lodash.ary = ary;
+ lodash.assign = assign;
+ lodash.at = at;
+ lodash.before = before;
+ lodash.bind = bind;
+ lodash.bindAll = bindAll;
+ lodash.bindKey = bindKey;
+ lodash.callback = callback;
+ lodash.chain = chain;
+ lodash.chunk = chunk;
+ lodash.compact = compact;
+ lodash.constant = constant;
+ lodash.countBy = countBy;
+ lodash.create = create;
+ lodash.curry = curry;
+ lodash.curryRight = curryRight;
+ lodash.debounce = debounce;
+ lodash.defaults = defaults;
+ lodash.defaultsDeep = defaultsDeep;
+ lodash.defer = defer;
+ lodash.delay = delay;
+ lodash.difference = difference;
+ lodash.drop = drop;
+ lodash.dropRight = dropRight;
+ lodash.dropRightWhile = dropRightWhile;
+ lodash.dropWhile = dropWhile;
+ lodash.fill = fill;
+ lodash.filter = filter;
+ lodash.flatten = flatten;
+ lodash.flattenDeep = flattenDeep;
+ lodash.flow = flow;
+ lodash.flowRight = flowRight;
+ lodash.forEach = forEach;
+ lodash.forEachRight = forEachRight;
+ lodash.forIn = forIn;
+ lodash.forInRight = forInRight;
+ lodash.forOwn = forOwn;
+ lodash.forOwnRight = forOwnRight;
+ lodash.functions = functions;
+ lodash.groupBy = groupBy;
+ lodash.indexBy = indexBy;
+ lodash.initial = initial;
+ lodash.intersection = intersection;
+ lodash.invert = invert;
+ lodash.invoke = invoke;
+ lodash.keys = keys;
+ lodash.keysIn = keysIn;
+ lodash.map = map;
+ lodash.mapKeys = mapKeys;
+ lodash.mapValues = mapValues;
+ lodash.matches = matches;
+ lodash.matchesProperty = matchesProperty;
+ lodash.memoize = memoize;
+ lodash.merge = merge;
+ lodash.method = method;
+ lodash.methodOf = methodOf;
+ lodash.mixin = mixin;
+ lodash.modArgs = modArgs;
+ lodash.negate = negate;
+ lodash.omit = omit;
+ lodash.once = once;
+ lodash.pairs = pairs;
+ lodash.partial = partial;
+ lodash.partialRight = partialRight;
+ lodash.partition = partition;
+ lodash.pick = pick;
+ lodash.pluck = pluck;
+ lodash.property = property;
+ lodash.propertyOf = propertyOf;
+ lodash.pull = pull;
+ lodash.pullAt = pullAt;
+ lodash.range = range;
+ lodash.rearg = rearg;
+ lodash.reject = reject;
+ lodash.remove = remove;
+ lodash.rest = rest;
+ lodash.restParam = restParam;
+ lodash.set = set;
+ lodash.shuffle = shuffle;
+ lodash.slice = slice;
+ lodash.sortBy = sortBy;
+ lodash.sortByAll = sortByAll;
+ lodash.sortByOrder = sortByOrder;
+ lodash.spread = spread;
+ lodash.take = take;
+ lodash.takeRight = takeRight;
+ lodash.takeRightWhile = takeRightWhile;
+ lodash.takeWhile = takeWhile;
+ lodash.tap = tap;
+ lodash.throttle = throttle;
+ lodash.thru = thru;
+ lodash.times = times;
+ lodash.toArray = toArray;
+ lodash.toPlainObject = toPlainObject;
+ lodash.transform = transform;
+ lodash.union = union;
+ lodash.uniq = uniq;
+ lodash.unzip = unzip;
+ lodash.unzipWith = unzipWith;
+ lodash.values = values;
+ lodash.valuesIn = valuesIn;
+ lodash.where = where;
+ lodash.without = without;
+ lodash.wrap = wrap;
+ lodash.xor = xor;
+ lodash.zip = zip;
+ lodash.zipObject = zipObject;
+ lodash.zipWith = zipWith;
+ lodash.backflow = flowRight;
+ lodash.collect = map;
+ lodash.compose = flowRight;
+ lodash.each = forEach;
+ lodash.eachRight = forEachRight;
+ lodash.extend = assign;
+ lodash.iteratee = callback;
+ lodash.methods = functions;
+ lodash.object = zipObject;
+ lodash.select = filter;
+ lodash.tail = rest;
+ lodash.unique = uniq;
+ mixin(lodash, lodash);
+ lodash.add = add;
+ lodash.attempt = attempt;
+ lodash.camelCase = camelCase;
+ lodash.capitalize = capitalize;
+ lodash.ceil = ceil;
+ lodash.clone = clone;
+ lodash.cloneDeep = cloneDeep;
+ lodash.deburr = deburr;
+ lodash.endsWith = endsWith;
+ lodash.escape = escape;
+ lodash.escapeRegExp = escapeRegExp;
+ lodash.every = every;
+ lodash.find = find;
+ lodash.findIndex = findIndex;
+ lodash.findKey = findKey;
+ lodash.findLast = findLast;
+ lodash.findLastIndex = findLastIndex;
+ lodash.findLastKey = findLastKey;
+ lodash.findWhere = findWhere;
+ lodash.first = first;
+ lodash.floor = floor;
+ lodash.get = get;
+ lodash.gt = gt;
+ lodash.gte = gte;
+ lodash.has = has;
+ lodash.identity = identity;
+ lodash.includes = includes;
+ lodash.indexOf = indexOf;
+ lodash.inRange = inRange;
+ lodash.isArguments = isArguments;
+ lodash.isArray = isArray;
+ lodash.isBoolean = isBoolean;
+ lodash.isDate = isDate;
+ lodash.isElement = isElement;
+ lodash.isEmpty = isEmpty;
+ lodash.isEqual = isEqual;
+ lodash.isError = isError;
+ lodash.isFinite = isFinite;
+ lodash.isFunction = isFunction;
+ lodash.isMatch = isMatch;
+ lodash.isNaN = isNaN;
+ lodash.isNative = isNative;
+ lodash.isNull = isNull;
+ lodash.isNumber = isNumber;
+ lodash.isObject = isObject;
+ lodash.isPlainObject = isPlainObject;
+ lodash.isRegExp = isRegExp;
+ lodash.isString = isString;
+ lodash.isTypedArray = isTypedArray;
+ lodash.isUndefined = isUndefined;
+ lodash.kebabCase = kebabCase;
+ lodash.last = last;
+ lodash.lastIndexOf = lastIndexOf;
+ lodash.lt = lt;
+ lodash.lte = lte;
+ lodash.max = max;
+ lodash.min = min;
+ lodash.noConflict = noConflict;
+ lodash.noop = noop;
+ lodash.now = now;
+ lodash.pad = pad;
+ lodash.padLeft = padLeft;
+ lodash.padRight = padRight;
+ lodash.parseInt = parseInt;
+ lodash.random = random;
+ lodash.reduce = reduce;
+ lodash.reduceRight = reduceRight;
+ lodash.repeat = repeat;
+ lodash.result = result;
+ lodash.round = round;
+ lodash.runInContext = runInContext;
+ lodash.size = size;
+ lodash.snakeCase = snakeCase;
+ lodash.some = some;
+ lodash.sortedIndex = sortedIndex;
+ lodash.sortedLastIndex = sortedLastIndex;
+ lodash.startCase = startCase;
+ lodash.startsWith = startsWith;
+ lodash.sum = sum;
+ lodash.template = template;
+ lodash.trim = trim;
+ lodash.trimLeft = trimLeft;
+ lodash.trimRight = trimRight;
+ lodash.trunc = trunc;
+ lodash.unescape = unescape;
+ lodash.uniqueId = uniqueId;
+ lodash.words = words;
+ lodash.all = every;
+ lodash.any = some;
+ lodash.contains = includes;
+ lodash.eq = isEqual;
+ lodash.detect = find;
+ lodash.foldl = reduce;
+ lodash.foldr = reduceRight;
+ lodash.head = first;
+ lodash.include = includes;
+ lodash.inject = reduce;
+
+ mixin(lodash, (function() {
+ var source = {};
+ baseForOwn(lodash, function(func, methodName) {
+ if (!lodash.prototype[methodName]) {
+ source[methodName] = func;
+ }
+ });
+ return source;
+ }()), false);
+ lodash.sample = sample;
+
+ lodash.prototype.sample = function(n) {
+ if (!this.__chain__ && n == null) {
+ return sample(this.value());
+ }
+ return this.thru(function(value) {
+ return sample(value, n);
+ });
+ };
+ lodash.VERSION = VERSION;
+ arrayEach(['bind', 'bindKey', 'curry', 'curryRight', 'partial', 'partialRight'], function(methodName) {
+ lodash[methodName].placeholder = lodash;
+ });
+ arrayEach(['drop', 'take'], function(methodName, index) {
+ LazyWrapper.prototype[methodName] = function(n) {
+ var filtered = this.__filtered__;
+ if (filtered && !index) {
+ return new LazyWrapper(this);
+ }
+ n = n == null ? 1 : nativeMax(nativeFloor(n) || 0, 0);
+
+ var result = this.clone();
+ if (filtered) {
+ result.__takeCount__ = nativeMin(result.__takeCount__, n);
+ } else {
+ result.__views__.push({ 'size': n, 'type': methodName + (result.__dir__ < 0 ? 'Right' : '') });
+ }
+ return result;
+ };
+
+ LazyWrapper.prototype[methodName + 'Right'] = function(n) {
+ return this.reverse()[methodName](n).reverse();
+ };
+ });
+ arrayEach(['filter', 'map', 'takeWhile'], function(methodName, index) {
+ var type = index + 1,
+ isFilter = type != LAZY_MAP_FLAG;
+
+ LazyWrapper.prototype[methodName] = function(iteratee, thisArg) {
+ var result = this.clone();
+ result.__iteratees__.push({ 'iteratee': getCallback(iteratee, thisArg, 1), 'type': type });
+ result.__filtered__ = result.__filtered__ || isFilter;
+ return result;
+ };
+ });
+ arrayEach(['first', 'last'], function(methodName, index) {
+ var takeName = 'take' + (index ? 'Right' : '');
+
+ LazyWrapper.prototype[methodName] = function() {
+ return this[takeName](1).value()[0];
+ };
+ });
+ arrayEach(['initial', 'rest'], function(methodName, index) {
+ var dropName = 'drop' + (index ? '' : 'Right');
+
+ LazyWrapper.prototype[methodName] = function() {
+ return this.__filtered__ ? new LazyWrapper(this) : this[dropName](1);
+ };
+ });
+ arrayEach(['pluck', 'where'], function(methodName, index) {
+ var operationName = index ? 'filter' : 'map',
+ createCallback = index ? baseMatches : property;
+
+ LazyWrapper.prototype[methodName] = function(value) {
+ return this[operationName](createCallback(value));
+ };
+ });
+
+ LazyWrapper.prototype.compact = function() {
+ return this.filter(identity);
+ };
+
+ LazyWrapper.prototype.reject = function(predicate, thisArg) {
+ predicate = getCallback(predicate, thisArg, 1);
+ return this.filter(function(value) {
+ return !predicate(value);
+ });
+ };
+
+ LazyWrapper.prototype.slice = function(start, end) {
+ start = start == null ? 0 : (+start || 0);
+
+ var result = this;
+ if (result.__filtered__ && (start > 0 || end < 0)) {
+ return new LazyWrapper(result);
+ }
+ if (start < 0) {
+ result = result.takeRight(-start);
+ } else if (start) {
+ result = result.drop(start);
+ }
+ if (end !== undefined) {
+ end = (+end || 0);
+ result = end < 0 ? result.dropRight(-end) : result.take(end - start);
+ }
+ return result;
+ };
+
+ LazyWrapper.prototype.takeRightWhile = function(predicate, thisArg) {
+ return this.reverse().takeWhile(predicate, thisArg).reverse();
+ };
+
+ LazyWrapper.prototype.toArray = function() {
+ return this.take(POSITIVE_INFINITY);
+ };
+ baseForOwn(LazyWrapper.prototype, function(func, methodName) {
+ var checkIteratee = /^(?:filter|map|reject)|While$/.test(methodName),
+ retUnwrapped = /^(?:first|last)$/.test(methodName),
+ lodashFunc = lodash[retUnwrapped ? ('take' + (methodName == 'last' ? 'Right' : '')) : methodName];
+
+ if (!lodashFunc) {
+ return;
+ }
+ lodash.prototype[methodName] = function() {
+ var args = retUnwrapped ? [1] : arguments,
+ chainAll = this.__chain__,
+ value = this.__wrapped__,
+ isHybrid = !!this.__actions__.length,
+ isLazy = value instanceof LazyWrapper,
+ iteratee = args[0],
+ useLazy = isLazy || isArray(value);
+
+ if (useLazy && checkIteratee && typeof iteratee == 'function' && iteratee.length != 1) {
+ isLazy = useLazy = false;
+ }
+ var interceptor = function(value) {
+ return (retUnwrapped && chainAll)
+ ? lodashFunc(value, 1)[0]
+ : lodashFunc.apply(undefined, arrayPush([value], args));
+ };
+
+ var action = { 'func': thru, 'args': [interceptor], 'thisArg': undefined },
+ onlyLazy = isLazy && !isHybrid;
+
+ if (retUnwrapped && !chainAll) {
+ if (onlyLazy) {
+ value = value.clone();
+ value.__actions__.push(action);
+ return func.call(value);
+ }
+ return lodashFunc.call(undefined, this.value())[0];
+ }
+ if (!retUnwrapped && useLazy) {
+ value = onlyLazy ? value : new LazyWrapper(this);
+ var result = func.apply(value, args);
+ result.__actions__.push(action);
+ return new LodashWrapper(result, chainAll);
+ }
+ return this.thru(interceptor);
+ };
+ });
+ arrayEach(['join', 'pop', 'push', 'replace', 'shift', 'sort', 'splice', 'split', 'unshift'], function(methodName) {
+ var func = (/^(?:replace|split)$/.test(methodName) ? stringProto : arrayProto)[methodName],
+ chainName = /^(?:push|sort|unshift)$/.test(methodName) ? 'tap' : 'thru',
+ retUnwrapped = /^(?:join|pop|replace|shift)$/.test(methodName);
+
+ lodash.prototype[methodName] = function() {
+ var args = arguments;
+ if (retUnwrapped && !this.__chain__) {
+ return func.apply(this.value(), args);
+ }
+ return this[chainName](function(value) {
+ return func.apply(value, args);
+ });
+ };
+ });
+ baseForOwn(LazyWrapper.prototype, function(func, methodName) {
+ var lodashFunc = lodash[methodName];
+ if (lodashFunc) {
+ var key = lodashFunc.name,
+ names = realNames[key] || (realNames[key] = []);
+
+ names.push({ 'name': methodName, 'func': lodashFunc });
+ }
+ });
+
+ realNames[createHybridWrapper(undefined, BIND_KEY_FLAG).name] = [{ 'name': 'wrapper', 'func': undefined }];
+ LazyWrapper.prototype.clone = lazyClone;
+ LazyWrapper.prototype.reverse = lazyReverse;
+ LazyWrapper.prototype.value = lazyValue;
+ lodash.prototype.chain = wrapperChain;
+ lodash.prototype.commit = wrapperCommit;
+ lodash.prototype.concat = wrapperConcat;
+ lodash.prototype.plant = wrapperPlant;
+ lodash.prototype.reverse = wrapperReverse;
+ lodash.prototype.toString = wrapperToString;
+ lodash.prototype.run = lodash.prototype.toJSON = lodash.prototype.valueOf = lodash.prototype.value = wrapperValue;
+ lodash.prototype.collect = lodash.prototype.map;
+ lodash.prototype.head = lodash.prototype.first;
+ lodash.prototype.select = lodash.prototype.filter;
+ lodash.prototype.tail = lodash.prototype.rest;
+
+ return lodash;
+ }
+ var _ = runInContext();
+ if (typeof define == 'function' && typeof define.amd == 'object' && define.amd) {
+ root._ = _;
+ ace.define(function() {
+ return _;
+ });
+ }
+ else if (freeExports && freeModule) {
+ if (moduleExports) {
+ (freeModule.exports = _)._ = _;
+ }
+ else {
+ freeExports._ = _;
+ }
+ }
+ else {
+ root._ = _;
+ }
+}.call(this));
+
+}).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
+},{}]},{},["/node_modules/xqlint/lib/xqlint.js"]);
+
+});
+
+ace.define("ace/mode/xquery_worker",["require","exports","module","ace/lib/oop","ace/worker/mirror","ace/mode/xquery/xqlint"], function(require, exports, module) {
+"use strict";
+
+var oop = require("../lib/oop");
+var Mirror = require("../worker/mirror").Mirror;
+var XQLintLib = require("./xquery/xqlint");
+var XQLint = XQLintLib.XQLint;
+
+var getModuleResolverFromModules = function(modules){
+ return function(uri){
+ var index = modules;
+ var mod = index[uri];
+ var variables = {};
+ var functions = {};
+ mod.functions.forEach(function(fn){
+ functions[uri + '#' + fn.name + '#' + fn.arity] = {
+ params: []
+ };
+ fn.parameters.forEach(function(param){
+ functions[uri + '#' + fn.name + '#' + fn.arity].params.push('$' + param.name);
+ });
+ });
+ mod.variables.forEach(function(variable){
+ var name = variable.name.substring(variable.name.indexOf(':') + 1);
+ variables[uri + '#' + name] = { type: 'VarDecl', annotations: [] };
+ });
+ return {
+ variables: variables,
+ functions: functions
+ };
+ };
+};
+
+var XQueryWorker = exports.XQueryWorker = function(sender) {
+ Mirror.call(this, sender);
+ this.setTimeout(200);
+ var that = this;
+
+ this.sender.on("complete", function(e){
+ if(that.xqlint) {
+ var pos = { line: e.data.pos.row, col: e.data.pos.column };
+ var proposals = that.xqlint.getCompletions(pos);
+ that.sender.emit("complete", proposals);
+ }
+ });
+
+ this.sender.on("setAvailableModuleNamespaces", function(e){
+ that.availableModuleNamespaces = e.data;
+ });
+
+ this.sender.on("setFileName", function(e){
+ that.fileName = e.data;
+ });
+
+ this.sender.on("setModuleResolver", function(e){
+ that.moduleResolver = getModuleResolverFromModules(e.data);
+ });
+};
+
+oop.inherits(XQueryWorker, Mirror);
+
+(function() {
+
+ this.onUpdate = function() {
+ this.sender.emit("start");
+ var value = this.doc.getValue();
+ var sctx = XQLintLib.createStaticContext();
+ if(this.moduleResolver) {
+ sctx.setModuleResolver(this.moduleResolver);
+ }
+ if(this.availableModuleNamespaces) {
+ sctx.availableModuleNamespaces = this.availableModuleNamespaces;
+ }
+ var opts = {
+ styleCheck: this.styleCheck,
+ staticContext: sctx,
+ fileName: this.fileName
+ };
+ this.xqlint = new XQLint(value, opts);
+ this.sender.emit("markers", this.xqlint.getMarkers());
+ };
+}).call(XQueryWorker.prototype);
+
+});
+
+ace.define("ace/lib/es5-shim",["require","exports","module"], function(require, exports, module) {
+
+function Empty() {}
+
+if (!Function.prototype.bind) {
+ Function.prototype.bind = function bind(that) { // .length is 1
+ var target = this;
+ if (typeof target != "function") {
+ throw new TypeError("Function.prototype.bind called on incompatible " + target);
+ }
+ var args = slice.call(arguments, 1); // for normal call
+ var bound = function () {
+
+ if (this instanceof bound) {
+
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+
+ }
+
+ };
+ if(target.prototype) {
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+ return bound;
+ };
+}
+var call = Function.prototype.call;
+var prototypeOfArray = Array.prototype;
+var prototypeOfObject = Object.prototype;
+var slice = prototypeOfArray.slice;
+var _toString = call.bind(prototypeOfObject.toString);
+var owns = call.bind(prototypeOfObject.hasOwnProperty);
+var defineGetter;
+var defineSetter;
+var lookupGetter;
+var lookupSetter;
+var supportsAccessors;
+if ((supportsAccessors = owns(prototypeOfObject, "__defineGetter__"))) {
+ defineGetter = call.bind(prototypeOfObject.__defineGetter__);
+ defineSetter = call.bind(prototypeOfObject.__defineSetter__);
+ lookupGetter = call.bind(prototypeOfObject.__lookupGetter__);
+ lookupSetter = call.bind(prototypeOfObject.__lookupSetter__);
+}
+if ([1,2].splice(0).length != 2) {
+ if(function() { // test IE < 9 to splice bug - see issue #138
+ function makeArray(l) {
+ var a = new Array(l+2);
+ a[0] = a[1] = 0;
+ return a;
+ }
+ var array = [], lengthBefore;
+
+ array.splice.apply(array, makeArray(20));
+ array.splice.apply(array, makeArray(26));
+
+ lengthBefore = array.length; //46
+ array.splice(5, 0, "XXX"); // add one element
+
+ lengthBefore + 1 == array.length
+
+ if (lengthBefore + 1 == array.length) {
+ return true;// has right splice implementation without bugs
+ }
+ }()) {//IE 6/7
+ var array_splice = Array.prototype.splice;
+ Array.prototype.splice = function(start, deleteCount) {
+ if (!arguments.length) {
+ return [];
+ } else {
+ return array_splice.apply(this, [
+ start === void 0 ? 0 : start,
+ deleteCount === void 0 ? (this.length - start) : deleteCount
+ ].concat(slice.call(arguments, 2)))
+ }
+ };
+ } else {//IE8
+ Array.prototype.splice = function(pos, removeCount){
+ var length = this.length;
+ if (pos > 0) {
+ if (pos > length)
+ pos = length;
+ } else if (pos == void 0) {
+ pos = 0;
+ } else if (pos < 0) {
+ pos = Math.max(length + pos, 0);
+ }
+
+ if (!(pos+removeCount < length))
+ removeCount = length - pos;
+
+ var removed = this.slice(pos, pos+removeCount);
+ var insert = slice.call(arguments, 2);
+ var add = insert.length;
+ if (pos === length) {
+ if (add) {
+ this.push.apply(this, insert);
+ }
+ } else {
+ var remove = Math.min(removeCount, length - pos);
+ var tailOldPos = pos + remove;
+ var tailNewPos = tailOldPos + add - remove;
+ var tailCount = length - tailOldPos;
+ var lengthAfterRemove = length - remove;
+
+ if (tailNewPos < tailOldPos) { // case A
+ for (var i = 0; i < tailCount; ++i) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } else if (tailNewPos > tailOldPos) { // case B
+ for (i = tailCount; i--; ) {
+ this[tailNewPos+i] = this[tailOldPos+i];
+ }
+ } // else, add == remove (nothing to do)
+
+ if (add && pos === lengthAfterRemove) {
+ this.length = lengthAfterRemove; // truncate array
+ this.push.apply(this, insert);
+ } else {
+ this.length = lengthAfterRemove + add; // reserves space
+ for (i = 0; i < add; ++i) {
+ this[pos+i] = insert[i];
+ }
+ }
+ }
+ return removed;
+ };
+ }
+}
+if (!Array.isArray) {
+ Array.isArray = function isArray(obj) {
+ return _toString(obj) == "[object Array]";
+ };
+}
+var boxedString = Object("a"),
+ splitString = boxedString[0] != "a" || !(0 in boxedString);
+
+if (!Array.prototype.forEach) {
+ Array.prototype.forEach = function forEach(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ thisp = arguments[1],
+ i = -1,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(); // TODO message
+ }
+
+ while (++i < length) {
+ if (i in self) {
+ fun.call(thisp, self[i], i, object);
+ }
+ }
+ };
+}
+if (!Array.prototype.map) {
+ Array.prototype.map = function map(fun /*, thisp*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = Array(length),
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self)
+ result[i] = fun.call(thisp, self[i], i, object);
+ }
+ return result;
+ };
+}
+if (!Array.prototype.filter) {
+ Array.prototype.filter = function filter(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ result = [],
+ value,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self) {
+ value = self[i];
+ if (fun.call(thisp, value, i, object)) {
+ result.push(value);
+ }
+ }
+ }
+ return result;
+ };
+}
+if (!Array.prototype.every) {
+ Array.prototype.every = function every(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && !fun.call(thisp, self[i], i, object)) {
+ return false;
+ }
+ }
+ return true;
+ };
+}
+if (!Array.prototype.some) {
+ Array.prototype.some = function some(fun /*, thisp */) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0,
+ thisp = arguments[1];
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+
+ for (var i = 0; i < length; i++) {
+ if (i in self && fun.call(thisp, self[i], i, object)) {
+ return true;
+ }
+ }
+ return false;
+ };
+}
+if (!Array.prototype.reduce) {
+ Array.prototype.reduce = function reduce(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+
+ var i = 0;
+ var result;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i++];
+ break;
+ }
+ if (++i >= length) {
+ throw new TypeError("reduce of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ for (; i < length; i++) {
+ if (i in self) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ }
+
+ return result;
+ };
+}
+if (!Array.prototype.reduceRight) {
+ Array.prototype.reduceRight = function reduceRight(fun /*, initial*/) {
+ var object = toObject(this),
+ self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ object,
+ length = self.length >>> 0;
+ if (_toString(fun) != "[object Function]") {
+ throw new TypeError(fun + " is not a function");
+ }
+ if (!length && arguments.length == 1) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+
+ var result, i = length - 1;
+ if (arguments.length >= 2) {
+ result = arguments[1];
+ } else {
+ do {
+ if (i in self) {
+ result = self[i--];
+ break;
+ }
+ if (--i < 0) {
+ throw new TypeError("reduceRight of empty array with no initial value");
+ }
+ } while (true);
+ }
+
+ do {
+ if (i in this) {
+ result = fun.call(void 0, result, self[i], i, object);
+ }
+ } while (i--);
+
+ return result;
+ };
+}
+if (!Array.prototype.indexOf || ([0, 1].indexOf(1, 2) != -1)) {
+ Array.prototype.indexOf = function indexOf(sought /*, fromIndex */ ) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+
+ var i = 0;
+ if (arguments.length > 1) {
+ i = toInteger(arguments[1]);
+ }
+ i = i >= 0 ? i : Math.max(0, length + i);
+ for (; i < length; i++) {
+ if (i in self && self[i] === sought) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Array.prototype.lastIndexOf || ([0, 1].lastIndexOf(0, -3) != -1)) {
+ Array.prototype.lastIndexOf = function lastIndexOf(sought /*, fromIndex */) {
+ var self = splitString && _toString(this) == "[object String]" ?
+ this.split("") :
+ toObject(this),
+ length = self.length >>> 0;
+
+ if (!length) {
+ return -1;
+ }
+ var i = length - 1;
+ if (arguments.length > 1) {
+ i = Math.min(i, toInteger(arguments[1]));
+ }
+ i = i >= 0 ? i : length - Math.abs(i);
+ for (; i >= 0; i--) {
+ if (i in self && sought === self[i]) {
+ return i;
+ }
+ }
+ return -1;
+ };
+}
+if (!Object.getPrototypeOf) {
+ Object.getPrototypeOf = function getPrototypeOf(object) {
+ return object.__proto__ || (
+ object.constructor ?
+ object.constructor.prototype :
+ prototypeOfObject
+ );
+ };
+}
+if (!Object.getOwnPropertyDescriptor) {
+ var ERR_NON_OBJECT = "Object.getOwnPropertyDescriptor called on a " +
+ "non-object: ";
+ Object.getOwnPropertyDescriptor = function getOwnPropertyDescriptor(object, property) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT + object);
+ if (!owns(object, property))
+ return;
+
+ var descriptor, getter, setter;
+ descriptor = { enumerable: true, configurable: true };
+ if (supportsAccessors) {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+
+ var getter = lookupGetter(object, property);
+ var setter = lookupSetter(object, property);
+ object.__proto__ = prototype;
+
+ if (getter || setter) {
+ if (getter) descriptor.get = getter;
+ if (setter) descriptor.set = setter;
+ return descriptor;
+ }
+ }
+ descriptor.value = object[property];
+ return descriptor;
+ };
+}
+if (!Object.getOwnPropertyNames) {
+ Object.getOwnPropertyNames = function getOwnPropertyNames(object) {
+ return Object.keys(object);
+ };
+}
+if (!Object.create) {
+ var createEmpty;
+ if (Object.prototype.__proto__ === null) {
+ createEmpty = function () {
+ return { "__proto__": null };
+ };
+ } else {
+ createEmpty = function () {
+ var empty = {};
+ for (var i in empty)
+ empty[i] = null;
+ empty.constructor =
+ empty.hasOwnProperty =
+ empty.propertyIsEnumerable =
+ empty.isPrototypeOf =
+ empty.toLocaleString =
+ empty.toString =
+ empty.valueOf =
+ empty.__proto__ = null;
+ return empty;
+ }
+ }
+
+ Object.create = function create(prototype, properties) {
+ var object;
+ if (prototype === null) {
+ object = createEmpty();
+ } else {
+ if (typeof prototype != "object")
+ throw new TypeError("typeof prototype["+(typeof prototype)+"] != 'object'");
+ var Type = function () {};
+ Type.prototype = prototype;
+ object = new Type();
+ object.__proto__ = prototype;
+ }
+ if (properties !== void 0)
+ Object.defineProperties(object, properties);
+ return object;
+ };
+}
+
+function doesDefinePropertyWork(object) {
+ try {
+ Object.defineProperty(object, "sentinel", {});
+ return "sentinel" in object;
+ } catch (exception) {
+ }
+}
+if (Object.defineProperty) {
+ var definePropertyWorksOnObject = doesDefinePropertyWork({});
+ var definePropertyWorksOnDom = typeof document == "undefined" ||
+ doesDefinePropertyWork(document.createElement("div"));
+ if (!definePropertyWorksOnObject || !definePropertyWorksOnDom) {
+ var definePropertyFallback = Object.defineProperty;
+ }
+}
+
+if (!Object.defineProperty || definePropertyFallback) {
+ var ERR_NON_OBJECT_DESCRIPTOR = "Property description must be an object: ";
+ var ERR_NON_OBJECT_TARGET = "Object.defineProperty called on non-object: "
+ var ERR_ACCESSORS_NOT_SUPPORTED = "getters & setters can not be defined " +
+ "on this javascript engine";
+
+ Object.defineProperty = function defineProperty(object, property, descriptor) {
+ if ((typeof object != "object" && typeof object != "function") || object === null)
+ throw new TypeError(ERR_NON_OBJECT_TARGET + object);
+ if ((typeof descriptor != "object" && typeof descriptor != "function") || descriptor === null)
+ throw new TypeError(ERR_NON_OBJECT_DESCRIPTOR + descriptor);
+ if (definePropertyFallback) {
+ try {
+ return definePropertyFallback.call(Object, object, property, descriptor);
+ } catch (exception) {
+ }
+ }
+ if (owns(descriptor, "value")) {
+
+ if (supportsAccessors && (lookupGetter(object, property) ||
+ lookupSetter(object, property)))
+ {
+ var prototype = object.__proto__;
+ object.__proto__ = prototypeOfObject;
+ delete object[property];
+ object[property] = descriptor.value;
+ object.__proto__ = prototype;
+ } else {
+ object[property] = descriptor.value;
+ }
+ } else {
+ if (!supportsAccessors)
+ throw new TypeError(ERR_ACCESSORS_NOT_SUPPORTED);
+ if (owns(descriptor, "get"))
+ defineGetter(object, property, descriptor.get);
+ if (owns(descriptor, "set"))
+ defineSetter(object, property, descriptor.set);
+ }
+
+ return object;
+ };
+}
+if (!Object.defineProperties) {
+ Object.defineProperties = function defineProperties(object, properties) {
+ for (var property in properties) {
+ if (owns(properties, property))
+ Object.defineProperty(object, property, properties[property]);
+ }
+ return object;
+ };
+}
+if (!Object.seal) {
+ Object.seal = function seal(object) {
+ return object;
+ };
+}
+if (!Object.freeze) {
+ Object.freeze = function freeze(object) {
+ return object;
+ };
+}
+try {
+ Object.freeze(function () {});
+} catch (exception) {
+ Object.freeze = (function freeze(freezeObject) {
+ return function freeze(object) {
+ if (typeof object == "function") {
+ return object;
+ } else {
+ return freezeObject(object);
+ }
+ };
+ })(Object.freeze);
+}
+if (!Object.preventExtensions) {
+ Object.preventExtensions = function preventExtensions(object) {
+ return object;
+ };
+}
+if (!Object.isSealed) {
+ Object.isSealed = function isSealed(object) {
+ return false;
+ };
+}
+if (!Object.isFrozen) {
+ Object.isFrozen = function isFrozen(object) {
+ return false;
+ };
+}
+if (!Object.isExtensible) {
+ Object.isExtensible = function isExtensible(object) {
+ if (Object(object) === object) {
+ throw new TypeError(); // TODO message
+ }
+ var name = '';
+ while (owns(object, name)) {
+ name += '?';
+ }
+ object[name] = true;
+ var returnValue = owns(object, name);
+ delete object[name];
+ return returnValue;
+ };
+}
+if (!Object.keys) {
+ var hasDontEnumBug = true,
+ dontEnums = [
+ "toString",
+ "toLocaleString",
+ "valueOf",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor"
+ ],
+ dontEnumsLength = dontEnums.length;
+
+ for (var key in {"toString": null}) {
+ hasDontEnumBug = false;
+ }
+
+ Object.keys = function keys(object) {
+
+ if (
+ (typeof object != "object" && typeof object != "function") ||
+ object === null
+ ) {
+ throw new TypeError("Object.keys called on a non-object");
+ }
+
+ var keys = [];
+ for (var name in object) {
+ if (owns(object, name)) {
+ keys.push(name);
+ }
+ }
+
+ if (hasDontEnumBug) {
+ for (var i = 0, ii = dontEnumsLength; i < ii; i++) {
+ var dontEnum = dontEnums[i];
+ if (owns(object, dontEnum)) {
+ keys.push(dontEnum);
+ }
+ }
+ }
+ return keys;
+ };
+
+}
+if (!Date.now) {
+ Date.now = function now() {
+ return new Date().getTime();
+ };
+}
+var ws = "\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003" +
+ "\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028" +
+ "\u2029\uFEFF";
+if (!String.prototype.trim || ws.trim()) {
+ ws = "[" + ws + "]";
+ var trimBeginRegexp = new RegExp("^" + ws + ws + "*"),
+ trimEndRegexp = new RegExp(ws + ws + "*$");
+ String.prototype.trim = function trim() {
+ return String(this).replace(trimBeginRegexp, "").replace(trimEndRegexp, "");
+ };
+}
+
+function toInteger(n) {
+ n = +n;
+ if (n !== n) { // isNaN
+ n = 0;
+ } else if (n !== 0 && n !== (1/0) && n !== -(1/0)) {
+ n = (n > 0 || -1) * Math.floor(Math.abs(n));
+ }
+ return n;
+}
+
+function isPrimitive(input) {
+ var type = typeof input;
+ return (
+ input === null ||
+ type === "undefined" ||
+ type === "boolean" ||
+ type === "number" ||
+ type === "string"
+ );
+}
+
+function toPrimitive(input) {
+ var val, valueOf, toString;
+ if (isPrimitive(input)) {
+ return input;
+ }
+ valueOf = input.valueOf;
+ if (typeof valueOf === "function") {
+ val = valueOf.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ toString = input.toString;
+ if (typeof toString === "function") {
+ val = toString.call(input);
+ if (isPrimitive(val)) {
+ return val;
+ }
+ }
+ throw new TypeError();
+}
+var toObject = function (o) {
+ if (o == null) { // this matches both null and undefined
+ throw new TypeError("can't convert "+o+" to object");
+ }
+ return Object(o);
+};
+
+});
diff --git a/www/wiki/extensions/CodeEditor/modules/ext.codeEditor.js b/www/wiki/extensions/CodeEditor/modules/ext.codeEditor.js
new file mode 100644
index 00000000..7f77ff31
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/ext.codeEditor.js
@@ -0,0 +1,36 @@
+/**
+ * MediaWiki:Gadget-codeeditor.js
+ * (c) 2011 Brion Vibber <brion @ pobox.com>
+ * GPLv2 or later
+ *
+ * Syntax highlighting, auto-indenting code editor widget for on-wiki JS and CSS pages.
+ * Uses embedded Ajax.org Cloud9 Editor: https://ace.c9.io/
+ *
+ * Known issues:
+ * - extension version doesn't have optional bits correct
+ * - ties into WikiEditor, so doesn't work on classic toolbar
+ * - background worker for JS syntax check doesn't load in non-debug mode (probably also fails if extension assets are offsite)
+ * - copy/paste not available from context menu (Firefox, Chrome on Linux -- kbd & main menu commands ok)
+ * - accessibility: tab/shift-tab are overridden. is there a consistent alternative for keyboard-reliant users?
+ * - accessibility: accesskey on the original textarea needs to be moved over or otherwise handled
+ * - 'discard your changes?' check on tab close doesn't trigger
+ * - scrollbar initializes too wide; need to trigger resize check after that's filled
+ * - cursor/scroll position not maintained over previews/show changes
+ */
+/*
+ * JavaScript for WikiEditor Table of Contents
+ */
+
+$( function () {
+ var $wpTextbox1 = $( '#wpTextbox1' );
+
+ // Code is supposed to be always LTR. See bug 39364.
+ $wpTextbox1.parent().prop( 'dir', 'ltr' );
+
+ // Add code editor module
+ $wpTextbox1.wikiEditor( 'addModule', 'codeEditor' );
+
+ $wpTextbox1.on( 'wikiEditor-toolbar-doneInitialSections', function () {
+ $wpTextbox1.data( 'wikiEditor-context' ).fn.codeEditorMonitorFragment();
+ } );
+} );
diff --git a/www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.js b/www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.js
new file mode 100644
index 00000000..8ab5bd6c
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.js
@@ -0,0 +1,851 @@
+/* Ace syntax-highlighting code editor extension for wikiEditor */
+/* global ace */
+( function ( $, mw, OO ) {
+ $.wikiEditor.modules.codeEditor = {
+ /**
+ * Core Requirements
+ */
+ req: [ 'codeEditor' ],
+ /**
+ * Configuration
+ */
+ cfg: {
+ //
+ },
+ /**
+ * API accessible functions
+ */
+ api: {
+ //
+ },
+ /**
+ * Event handlers
+ */
+ evt: {
+ //
+ },
+ /**
+ * Internally used functions
+ */
+ fn: {
+ }
+
+ };
+
+ $.wikiEditor.extensions.codeEditor = function ( context ) {
+ var saveAndExtend,
+ textSelectionFn,
+ hasErrorsOnSave = false,
+ selectedLine = 0,
+ cookieEnabled,
+ returnFalse = function () { return false; },
+ api = new mw.Api();
+
+ // Initialize state
+ cookieEnabled = parseInt( mw.cookie.get( 'codeEditor-' + context.instance + '-showInvisibleChars' ), 10 );
+ context.showInvisibleChars = ( cookieEnabled === 1 );
+ cookieEnabled = parseInt( mw.cookie.get( 'codeEditor-' + context.instance + '-lineWrappingActive' ), 10 );
+ context.lineWrappingActive = ( cookieEnabled === 1 );
+ context.showSearchReplace = 0;
+
+ /*
+ * Event Handlers
+ *
+ * WikiEditor inspects the 'evt' object for event names and uses them if present as additional
+ * event handlers that fire before the default handling.
+ * To prevent WikiEditor from running its own handling, handlers should return false.
+ *
+ * This is also where we can attach some extra information to the events.
+ */
+ context.evt = $.extend( context.evt, {
+ keydown: returnFalse,
+ change: returnFalse,
+ delayedChange: returnFalse,
+ cut: returnFalse,
+ paste: returnFalse,
+ ready: returnFalse,
+ codeEditorSubmit: function () {
+ var form = this;
+ context.evt.codeEditorSync();
+ if ( hasErrorsOnSave ) {
+ hasErrorsOnSave = false;
+ OO.ui.confirm( mw.msg( 'codeeditor-save-with-errors' ) ).done( function ( confirmed ) {
+ if ( confirmed ) {
+ // Programmatic submit doesn't retrigger this event listener
+ form.submit();
+ }
+ } );
+ return false;
+ }
+ return true;
+ },
+ codeEditorSave: function () {
+ var i,
+ annotations = context.codeEditor.getSession().getAnnotations();
+ for ( i = 0; i < annotations.length; i++ ) {
+ if ( annotations[ i ].type === 'error' ) {
+ hasErrorsOnSave = true;
+ break;
+ }
+ }
+ },
+ codeEditorSync: function () {
+ context.$textarea.val( context.$textarea.textSelection( 'getContents' ) );
+
+ }
+ } );
+
+ // Make sure to cast '0' to false
+ context.codeEditorActive = !!Number( mw.user.options.get( 'usecodeeditor' ) );
+
+ /**
+ * Internally used functions
+ */
+ context.fn = $.extend( context.fn, {
+ isCodeEditorActive: function () {
+ return context.codeEditorActive;
+ },
+ isShowInvisibleChars: function () {
+ return context.showInvisibleChars;
+ },
+ isLineWrappingActive: function () {
+ return context.lineWrappingActive;
+ },
+ changeCookieValue: function ( cookieName, value ) {
+ mw.cookie.set(
+ 'codeEditor-' + context.instance + '-' + cookieName,
+ value
+ );
+ },
+ aceGotoLineColumn: function () {
+ OO.ui.prompt( mw.msg( 'codeeditor-gotoline-prompt' ), {
+ textInput: { placeholder: mw.msg( 'codeeditor-gotoline-placeholder' ) }
+ } ).done( function ( result ) {
+ var matches, line, column;
+
+ if ( !result ) {
+ return;
+ }
+
+ matches = result.split( ':' );
+ line = 0;
+ column = 0;
+
+ if ( matches.length > 0 ) {
+ line = +matches[ 0 ];
+ if ( isNaN( line ) ) {
+ return;
+ } else {
+ // Lines are zero-indexed
+ line--;
+ }
+ }
+ if ( matches.length > 1 ) {
+ column = +matches[ 1 ];
+ if ( isNaN( column ) ) {
+ column = 0;
+ }
+ }
+ context.codeEditor.navigateTo( line, column );
+ // Scroll up a bit to give some context
+ context.codeEditor.scrollToRow( line - 4 );
+ } );
+ },
+ setupCodeEditorToolbar: function () {
+ var toggleEditor,
+ toggleInvisibleChars,
+ toggleSearchReplace,
+ toggleLineWrapping,
+ indent, outdent, gotoLine;
+
+ toggleEditor = function ( context ) {
+ context.codeEditorActive = !context.codeEditorActive;
+
+ context.fn.setCodeEditorPreference( context.codeEditorActive );
+ context.fn.updateCodeEditorToolbarButton();
+
+ if ( context.codeEditorActive ) {
+ // set it back up!
+ context.fn.setupCodeEditor();
+ } else {
+ context.fn.disableCodeEditor();
+ }
+ };
+ toggleInvisibleChars = function ( context ) {
+ context.showInvisibleChars = !context.showInvisibleChars;
+
+ context.fn.changeCookieValue( 'showInvisibleChars', context.showInvisibleChars ? 1 : 0 );
+ context.fn.updateInvisibleCharsButton();
+
+ context.codeEditor.setShowInvisibles( context.showInvisibleChars );
+ };
+ toggleSearchReplace = function ( context ) {
+ context.showSearchReplace = !context.showSearchReplace;
+
+ if ( context.showSearchReplace ) {
+ ace.config.loadModule( 'ace/ext/searchbox', function ( e ) {
+ // ace.editor.searchBox.show();
+ e.Search( context.codeEditor, !0 );
+ } );
+ } else {
+ context.codeEditor.searchBox.hide();
+ }
+ };
+ toggleLineWrapping = function ( context ) {
+ context.lineWrappingActive = !context.lineWrappingActive;
+
+ context.fn.changeCookieValue( 'lineWrappingActive', context.lineWrappingActive ? 1 : 0 );
+ context.fn.updateLineWrappingButton();
+
+ context.codeEditor.getSession().setUseWrapMode( context.lineWrappingActive );
+ };
+ indent = function ( context ) {
+ context.codeEditor.execCommand( 'indent' );
+ };
+ outdent = function ( context ) {
+ context.codeEditor.execCommand( 'outdent' );
+ };
+ gotoLine = function ( context ) {
+ context.codeEditor.execCommand( 'gotolinecolumn' );
+ };
+
+ context.api.addToToolbar( context, {
+ section: 'main',
+ groups: {
+ 'codeeditor-main': {
+ tools: {
+ codeEditor: {
+ labelMsg: 'codeeditor-toolbar-toggle',
+ type: 'button',
+ oouiIcon: 'markup',
+ action: {
+ type: 'callback',
+ execute: toggleEditor
+ }
+ }
+ }
+ },
+ 'codeeditor-format': {
+ tools: {
+ indent: {
+ labelMsg: 'codeeditor-indent',
+ type: 'button',
+ oouiIcon: 'indent',
+ action: {
+ type: 'callback',
+ execute: indent
+ }
+ },
+ outdent: {
+ labelMsg: 'codeeditor-outdent',
+ type: 'button',
+ oouiIcon: 'outdent',
+ action: {
+ type: 'callback',
+ execute: outdent
+ }
+ }
+
+ }
+ },
+ 'codeeditor-style': {
+ tools: {
+ invisibleChars: {
+ labelMsg: 'codeeditor-invisibleChars-toggle',
+ type: 'button',
+ oouiIcon: 'pilcrow',
+ action: {
+ type: 'callback',
+ execute: toggleInvisibleChars
+ }
+ },
+ lineWrapping: {
+ labelMsg: 'codeeditor-lineWrapping-toggle',
+ type: 'button',
+ oouiIcon: 'wrapping',
+ action: {
+ type: 'callback',
+ execute: toggleLineWrapping
+ }
+ },
+ gotoLine: {
+ labelMsg: 'codeeditor-gotoline',
+ type: 'button',
+ oouiIcon: 'gotoLine',
+ action: {
+ type: 'callback',
+ execute: gotoLine
+ }
+ },
+ toggleSearchReplace: {
+ labelMsg: 'codeeditor-searchReplace-toggle',
+ type: 'button',
+ oouiIcon: 'articleSearch',
+ action: {
+ type: 'callback',
+ execute: toggleSearchReplace
+ }
+ }
+ }
+ }
+ }
+ } );
+ context.fn.updateCodeEditorToolbarButton();
+ context.fn.updateInvisibleCharsButton();
+ context.fn.updateLineWrappingButton();
+ $( '.group-codeeditor-style' ).prependTo( '.section-main' );
+ $( '.group-codeeditor-format' ).prependTo( '.section-main' );
+ $( '.group-codeeditor-main' ).prependTo( '.section-main' );
+ },
+ updateButtonIcon: function ( targetName, iconFn ) {
+ var target = '.tool[rel=' + targetName + ']',
+ $button = context.modules.toolbar.$toolbar.find( target );
+
+ $button.data( 'setActive' )( iconFn() );
+ },
+ updateCodeEditorToolbarButton: function () {
+ context.fn.updateButtonIcon( 'codeEditor', context.fn.isCodeEditorActive );
+ },
+ updateInvisibleCharsButton: function () {
+ context.fn.updateButtonIcon( 'invisibleChars', context.fn.isShowInvisibleChars );
+ },
+ updateLineWrappingButton: function () {
+ context.fn.updateButtonIcon( 'lineWrapping', context.fn.isLineWrappingActive );
+ },
+ setCodeEditorPreference: function ( prefValue ) {
+ // Do not try to save options for anonymous user
+ if ( mw.user.isAnon() ) {
+ return;
+ }
+
+ // Abort any previous request
+ api.abort();
+
+ api.saveOption( 'usecodeeditor', prefValue ? 1 : 0 )
+ .fail( function ( code, result ) {
+ var message;
+
+ if ( code === 'http' && result.textStatus === 'abort' ) {
+ // Request was aborted. Ignore error
+ return;
+ }
+
+ message = 'Failed to set code editor preference: ' + code;
+ if ( result.error && result.error.info ) {
+ message += '\n' + result.error.info;
+ }
+ mw.log.warn( message );
+ } );
+ },
+ /**
+ * Sets up the iframe in place of the textarea to allow more advanced operations
+ */
+ setupCodeEditor: function () {
+ var box, lang, basePath, container, editdiv, session;
+
+ box = context.$textarea;
+ lang = mw.config.get( 'wgCodeEditorCurrentLanguage' );
+ basePath = mw.config.get( 'wgExtensionAssetsPath', '' );
+ if ( basePath.slice( 0, 2 ) === '//' ) {
+ // ACE uses web workers, which have importScripts, which don't like relative links.
+ // This is a problem only when the assets are on another server, so this rewrite should suffice
+ // Protocol relative
+ basePath = window.location.protocol + basePath;
+ }
+ ace.config.set( 'basePath', basePath + '/CodeEditor/modules/ace' );
+
+ if ( lang ) {
+ // Ace doesn't like replacing a textarea directly.
+ // We'll stub this out to sit on top of it...
+ // line-height is needed to compensate for oddity in WikiEditor extension, which zeroes the line-height on a parent container
+ container = context.$codeEditorContainer = $( '<div style="position: relative"><div class="editor" style="line-height: 1.5em; top: 0; left: 0; right: 0; bottom: 0; position: absolute;"></div></div>' ).insertAfter( box );
+ editdiv = container.find( '.editor' );
+
+ box.css( 'display', 'none' );
+ container.height( box.height() );
+
+ // Non-lazy loaded dependencies: Enable code completion
+ ace.require( 'ace/ext/language_tools' );
+
+ // Load the editor now
+ context.codeEditor = ace.edit( editdiv[ 0 ] );
+ context.codeEditor.getSession().setValue( box.val() );
+ box.textSelection( 'register', textSelectionFn );
+
+ // Disable some annoying commands
+ context.codeEditor.commands.removeCommand( 'replace' ); // ctrl+R
+ context.codeEditor.commands.removeCommand( 'transposeletters' ); // ctrl+T
+ context.codeEditor.commands.removeCommand( 'gotoline' ); // ctrl+L
+
+ context.codeEditor.setReadOnly( box.prop( 'readonly' ) );
+ context.codeEditor.setShowInvisibles( context.showInvisibleChars );
+
+ // The options to enable
+ context.codeEditor.setOptions( {
+ enableBasicAutocompletion: true,
+ enableSnippets: true
+ } );
+
+ context.codeEditor.commands.addCommand( {
+ name: 'gotolinecolumn',
+ bindKey: { mac: 'Command-Shift-L', windows: 'Ctrl-Alt-L' },
+ exec: context.fn.aceGotoLineColumn,
+ readOnly: true
+ } );
+
+ box.closest( 'form' )
+ .submit( context.evt.codeEditorSubmit )
+ .find( '#wpSave' ).click( context.evt.codeEditorSave );
+
+ session = context.codeEditor.getSession();
+
+ // Use proper tabs
+ session.setUseSoftTabs( false );
+ session.setUseWrapMode( context.lineWrappingActive );
+
+ mw.hook( 'codeEditor.configure' ).fire( session );
+
+ ace.config.loadModule( 'ace/ext/modelist', function ( modelist ) {
+ if ( !modelist || !modelist.modesByName[ lang ] ) {
+ lang = 'text';
+ }
+ session.setMode( 'ace/mode/' + lang );
+ } );
+
+ // Use jquery.ui.resizable so user can make the box taller too
+ container.resizable( {
+ handles: 's',
+ minHeight: box.height(),
+ resize: function () {
+ context.codeEditor.resize();
+ }
+ } );
+ $( '.wikiEditor-ui-toolbar' ).addClass( 'codeEditor-ui-toolbar' );
+
+ if ( selectedLine > 0 ) {
+ // Line numbers in CodeEditor are zero-based
+ context.codeEditor.navigateTo( selectedLine - 1, 0 );
+ // Scroll up a bit to give some context
+ context.codeEditor.scrollToRow( selectedLine - 4 );
+ }
+
+ context.fn.setupStatusBar();
+
+ // Let modules know we're ready to start working with the content
+ context.fn.trigger( 'ready' );
+ }
+ },
+
+ /**
+ * Turn off the code editor view and return to the plain textarea.
+ * May be needed by some folks with funky browsers, or just to compare.
+ */
+ disableCodeEditor: function () {
+ // Kills it!
+ context.$textarea.closest( 'form' )
+ .off( 'submit', context.evt.codeEditorSubmit )
+ .find( '#wpSave' ).off( 'click', context.evt.codeEditorSave );
+
+ // Save contents
+ context.$textarea.textSelection( 'unregister' );
+ context.$textarea.val( textSelectionFn.getContents() );
+
+ // @todo fetch cursor, scroll position
+
+ // Drop the fancy editor widget...
+ context.fn.removeStatusBar();
+ context.$codeEditorContainer.remove();
+ context.$codeEditorContainer = undefined;
+ context.codeEditor = undefined;
+
+ // Restore textarea
+ context.$textarea.show();
+ // Restore toolbar
+ $( '.wikiEditor-ui-toolbar' ).removeClass( 'codeEditor-ui-toolbar' );
+
+ // @todo restore cursor, scroll position
+ },
+
+ /**
+ * Start monitoring the fragment of the current window for hash change
+ * events. If the hash is already set, handle it as a new event.
+ */
+ codeEditorMonitorFragment: function () {
+ function onHashChange() {
+ var regexp, result;
+
+ regexp = /#mw-ce-l(\d+)/;
+ result = regexp.exec( window.location.hash );
+
+ if ( result === null ) {
+ return;
+ }
+
+ selectedLine = parseInt( result[ 1 ], 10 );
+ if ( context.codeEditor && selectedLine > 0 ) {
+ // Line numbers in CodeEditor are zero-based
+ context.codeEditor.navigateTo( selectedLine - 1, 0 );
+ // Scroll up a bit to give some context
+ context.codeEditor.scrollToRow( selectedLine - 4 );
+ }
+ }
+
+ onHashChange();
+ $( window ).on( 'hashchange', onHashChange );
+ },
+ /**
+ * This creates a Statusbar, that allows you to see a count of the
+ * errors, warnings and the warning of the current line, as well as
+ * the position of the cursor.
+ */
+ setupStatusBar: function () {
+ var shouldUpdateAnnotations,
+ shouldUpdateSelection,
+ shouldUpdateLineInfo,
+ nextAnnotation,
+ delayedUpdate,
+ editor = context.codeEditor,
+ lang = ace.require( 'ace/lib/lang' ),
+ $errors = $( '<span class="codeEditor-status-worker-cell ace_gutter-cell ace_error">0</span>' ),
+ $warnings = $( '<span class="codeEditor-status-worker-cell ace_gutter-cell ace_warning">0</span>' ),
+ $infos = $( '<span class="codeEditor-status-worker-cell ace_gutter-cell ace_info">0</span>' ),
+ $message = $( '<div>' ).addClass( 'codeEditor-status-message' ),
+ $lineAndMode = $( '<div>' ).addClass( 'codeEditor-status-line' ),
+ $workerStatus = $( '<div>' )
+ .addClass( 'codeEditor-status-worker' )
+ .attr( 'title', mw.msg( 'codeeditor-next-annotation' ) )
+ .append( $errors )
+ .append( $warnings )
+ .append( $infos );
+
+ context.$statusBar = $( '<div>' )
+ .addClass( 'codeEditor-status' )
+ .append( $workerStatus )
+ .append( $message )
+ .append( $lineAndMode );
+
+ /* Help function to concatenate strings with different separators */
+ function addToStatus( status, str, separator ) {
+ if ( str ) {
+ status.push( str, separator || '|' );
+ }
+ }
+
+ /**
+ * Update all the information in the status bar
+ */
+ function updateStatusBar() {
+ var i, c, r,
+ status,
+ annotation,
+ errors = 0,
+ warnings = 0,
+ infos = 0,
+ distance,
+ shortestDistance = Infinity,
+ closestAnnotation,
+ currentLine = editor.selection.lead.row,
+ annotations = editor.getSession().getAnnotations(),
+ closestType;
+
+ // Reset the next annotation
+ nextAnnotation = null;
+
+ for ( i = 0; i < annotations.length; i++ ) {
+ annotation = annotations[ i ];
+ distance = Math.abs( currentLine - annotation.row );
+
+ if ( distance < shortestDistance ) {
+ shortestDistance = distance;
+ closestAnnotation = annotation;
+ }
+ if ( nextAnnotation === null && annotation.row > currentLine ) {
+ nextAnnotation = annotation;
+ }
+
+ switch ( annotations[ i ].type ) {
+ case 'error':
+ errors++;
+ break;
+ case 'warning':
+ warnings++;
+ break;
+ case 'info':
+ infos++;
+ break;
+ }
+ }
+ // Wrap around to the beginning for nextAnnotation
+ if ( nextAnnotation === null && annotations.length > 0 ) {
+ nextAnnotation = annotations[ 0 ];
+ }
+ // Update the annotation counts
+ if ( shouldUpdateAnnotations ) {
+ $errors.text( errors );
+ $warnings.text( warnings );
+ $infos.text( infos );
+ }
+
+ // Show the message of the current line, if we have not already done so
+ if ( closestAnnotation &&
+ currentLine === closestAnnotation.row &&
+ closestAnnotation !== $message.data( 'annotation' ) ) {
+ $message.data( 'annotation', closestAnnotation );
+ closestType =
+ closestAnnotation.type.charAt( 0 ).toUpperCase() +
+ closestAnnotation.type.slice( 1 );
+
+ $message.text( closestType + ': ' + closestAnnotation.text );
+ } else if ( $message.data( 'annotation' ) !== null &&
+ ( !closestAnnotation || currentLine !== closestAnnotation.row ) ) {
+ // If we are on a different line without an annotation, then blank the message
+ $message.data( 'annotation', null );
+ $message.text( '' );
+ }
+
+ // The cursor position has changed
+ if ( shouldUpdateSelection || shouldUpdateLineInfo ) {
+ // Adapted from Ajax.org's ace/ext/statusbar module
+ status = [];
+
+ if ( editor.$vimModeHandler ) {
+ addToStatus( status, editor.$vimModeHandler.getStatusText() );
+ } else if ( editor.commands.recording ) {
+ addToStatus( status, 'REC' );
+ }
+
+ c = editor.selection.lead;
+ addToStatus( status, ( c.row + 1 ) + ':' + c.column, '' );
+ if ( !editor.selection.isEmpty() ) {
+ r = editor.getSelectionRange();
+ addToStatus( status, '(' + ( r.end.row - r.start.row ) + ':' + ( r.end.column - r.start.column ) + ')' );
+ }
+ status.pop();
+ $lineAndMode.text( status.join( '' ) );
+ }
+
+ shouldUpdateLineInfo = shouldUpdateSelection = shouldUpdateAnnotations = false;
+ }
+
+ // Function to delay/debounce updates for the StatusBar
+ delayedUpdate = lang.delayedCall( function () {
+ updateStatusBar( editor );
+ } );
+
+ /**
+ * Click handler that allows you to skip to the next annotation
+ */
+ $workerStatus.on( 'click', function ( e ) {
+ if ( nextAnnotation ) {
+ context.codeEditor.navigateTo( nextAnnotation.row, nextAnnotation.column );
+ // Scroll up a bit to give some context
+ context.codeEditor.scrollToRow( nextAnnotation.row - 3 );
+ e.preventDefault();
+ }
+ } );
+
+ editor.getSession().on( 'changeAnnotation', function () {
+ shouldUpdateAnnotations = true;
+ delayedUpdate.schedule( 100 );
+ } );
+ editor.on( 'changeStatus', function () {
+ shouldUpdateLineInfo = true;
+ delayedUpdate.schedule( 100 );
+ } );
+ editor.on( 'changeSelection', function () {
+ shouldUpdateSelection = true;
+ delayedUpdate.schedule( 100 );
+ } );
+
+ // Force update
+ shouldUpdateLineInfo = shouldUpdateSelection = shouldUpdateAnnotations = true;
+ updateStatusBar( editor );
+
+ context.$statusBar.insertAfter( $( '.wikiEditor-ui-view-wikitext .wikiEditor-ui-bottom' ) );
+ },
+ removeStatusBar: function () {
+ context.codeEditor.getSession().removeListener( 'changeAnnotation' );
+ context.codeEditor.removeListener( 'changeSelection' );
+ context.codeEditor.removeListener( 'changeStatus' );
+ context.nextAnnotation = null;
+ context.$statusBar = null;
+
+ $( '.codeEditor-status' ).remove();
+ }
+
+ } );
+
+ /**
+ * Override the base functions in a way that lets
+ * us fall back to the originals when we turn off.
+ *
+ * @param {Object} base
+ * @param {Object} extended
+ */
+ saveAndExtend = function ( base, extended ) {
+ $.map( extended, function ( func, name ) {
+ var orig;
+ if ( name in base ) {
+ orig = base[ name ];
+ base[ name ] = function () {
+ if ( context.codeEditorActive ) {
+ return func.apply( this, arguments );
+ }
+ if ( orig ) {
+ return orig.apply( this, arguments );
+ }
+ throw new Error( 'CodeEditor: no original function to call for ' + name );
+ };
+ } else {
+ base[ name ] = func;
+ }
+ } );
+ };
+
+ saveAndExtend( context.fn, {
+ saveSelection: function () {
+ mw.log( 'codeEditor stub function saveSelection called' );
+ },
+ restoreSelection: function () {
+ mw.log( 'codeEditor stub function restoreSelection called' );
+ },
+
+ /**
+ * Scroll an element to the top of the iframe
+ */
+ scrollToTop: function () {
+ mw.log( 'codeEditor stub function scrollToTop called' );
+ }
+ } );
+
+ /**
+ * Compatibility with the $.textSelection jQuery plug-in. When the iframe is in use, these functions provide
+ * equivalant functionality to the otherwise textarea-based functionality.
+ */
+ textSelectionFn = {
+
+ /* Needed for search/replace */
+ getContents: function () {
+ return context.codeEditor.getSession().getValue();
+ },
+
+ setContents: function ( newContents ) {
+ context.codeEditor.getSession().setValue( newContents );
+ },
+
+ /**
+ * Gets the currently selected text in the content
+ * DO NOT CALL THIS DIRECTLY, use $.textSelection( 'functionname', options ) instead
+ *
+ * @return {string}
+ */
+ getSelection: function () {
+ return context.codeEditor.getCopyText();
+ },
+
+ /**
+ * Inserts text at the begining and end of a text selection, optionally inserting text at the caret when
+ * selection is empty.
+ * DO NOT CALL THIS DIRECTLY, use $.textSelection( 'functionname', options ) instead
+ *
+ * @param {Object} options
+ * @return {jQuery}
+ */
+ encapsulateSelection: function ( options ) {
+ var sel, range, selText, isSample, text;
+
+ // Does not yet handle 'ownline', 'splitlines' option
+ sel = context.codeEditor.getSelection();
+ range = sel.getRange();
+ selText = textSelectionFn.getSelection();
+ isSample = false;
+
+ if ( !selText ) {
+ selText = options.peri;
+ isSample = true;
+ } else if ( options.replace ) {
+ selText = options.peri;
+ }
+
+ text = options.pre;
+ text += selText;
+ text += options.post;
+ context.codeEditor.insert( text );
+ if ( isSample && options.selectPeri && !options.splitlines ) {
+ // May esplode if anything has newlines, be warned. :)
+ range.setStart( range.start.row, range.start.column + options.pre.length );
+ range.setEnd( range.start.row, range.start.column + selText.length );
+ sel.setSelectionRange( range );
+ }
+ return context.$textarea;
+ },
+
+ /**
+ * Gets the position (in resolution of bytes not nessecarily characters) in a textarea
+ * DO NOT CALL THIS DIRECTLY, use $.textSelection( 'functionname', options ) instead
+ */
+ getCaretPosition: function () {
+ mw.log( 'codeEditor stub function getCaretPosition called' );
+ },
+
+ /**
+ * Sets the selection of the content
+ * DO NOT CALL THIS DIRECTLY, use $.textSelection( 'functionname', options ) instead
+ *
+ * @param {Object} options
+ * @return {jQuery}
+ */
+ setSelection: function ( options ) {
+ var doc, lines, offsetToPos, start, end, sel, range;
+
+ // Ace stores positions for ranges as row/column pairs.
+ // To convert from character offsets, we'll need to iterate through the document
+ doc = context.codeEditor.getSession().getDocument();
+ lines = doc.getAllLines();
+
+ offsetToPos = function ( offset ) {
+ var row, col, pos;
+
+ row = 0;
+ col = 0;
+ pos = 0;
+
+ while ( row < lines.length && pos + lines[ row ].length < offset ) {
+ pos += lines[ row ].length;
+ pos++; // for the newline
+ row++;
+ }
+ col = offset - pos;
+ return { row: row, column: col };
+ };
+ start = offsetToPos( options.start );
+ end = offsetToPos( options.end );
+
+ sel = context.codeEditor.getSelection();
+ range = sel.getRange();
+ range.setStart( start.row, start.column );
+ range.setEnd( end.row, end.column );
+ sel.setSelectionRange( range );
+ return context.$textarea;
+ },
+
+ /**
+ * Scroll a textarea to the current cursor position. You can set the cursor position with setSelection()
+ * DO NOT CALL THIS DIRECTLY, use $.textSelection( 'functionname', options ) instead
+ *
+ * @return {jQuery}
+ */
+ scrollToCaretPosition: function () {
+ mw.log( 'codeEditor stub function scrollToCaretPosition called' );
+ return context.$textarea;
+ }
+ };
+
+ /* Setup the editor */
+ context.fn.setupCodeEditorToolbar();
+ if ( context.codeEditorActive ) {
+ context.fn.setupCodeEditor();
+ }
+
+ };
+}( jQuery, mediaWiki, OO ) );
diff --git a/www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.less b/www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.less
new file mode 100644
index 00000000..296455aa
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/modules/jquery.codeEditor.less
@@ -0,0 +1,75 @@
+@import 'mediawiki.mixins';
+
+.group-codeeditor-format,
+.group-codeeditor-style,
+.codeEditor-ui-toolbar .group-insert,
+.codeEditor-ui-toolbar .group-format,
+.codeEditor-ui-toolbar .tabs span.tab-advanced,
+.codeEditor-ui-toolbar .tabs span.tab-characters,
+.codeEditor-ui-toolbar .tabs span.tab-help,
+.codeEditor-ui-toolbar .sections {
+ display: none;
+}
+
+.codeEditor-ui-toolbar .group-codeeditor-format,
+.codeEditor-ui-toolbar .group-codeeditor-style {
+ display: block;
+}
+
+.wikiEditor-ui .ace_editor {
+ /* Same as mw-editfont-monospace, repeated for higher specificity */
+ font-size: 13px;
+ font-family: monospace, monospace;
+}
+
+.wikiEditor-ui-toolbar .group-codeeditor-style {
+ border-right: 0;
+}
+
+.ace_editor textarea,
+.ace_editor input {
+ /* Inherit directionality from editor, not sitedir (T186329) */
+ direction: inherit;
+}
+
+.codeEditor-status {
+ clear: both;
+ width: 100%;
+ background-color: #f8f9fa;
+ border-top: 1px solid #c8ccd1;
+ display: table;
+}
+
+.codeEditor-status .codeEditor-status-worker-cell.ace_gutter-cell {
+ background-position: 0 center;
+}
+
+.codeEditor-status-worker {
+ padding: 0 0.3em;
+ user-select: none;
+ cursor: pointer;
+ display: table-cell;
+}
+
+.codeEditor-status-message {
+ border-left: 1px solid #c8ccd1;
+ border-right: 1px solid #c8ccd1;
+ padding: 0 0.3em;
+ width: 100%;
+ display: table-cell;
+}
+
+.codeEditor-status-line {
+ padding: 0 0.3em;
+ text-align: right;
+ white-space: nowrap;
+ display: table-cell;
+}
+
+/* Hide vanilla MediaWiki's "Editing help" link, as we provide it in the toolbar */
+/* Copied from the same code in WikiEditor */
+.client-js .editButtons {
+ .editHelp {
+ display: none;
+ }
+}
diff --git a/www/wiki/extensions/CodeEditor/tests/phan/config.php b/www/wiki/extensions/CodeEditor/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/CodeEditor/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/ConfirmEdit/ConfirmEdit.alias.php b/www/wiki/extensions/ConfirmEdit/ConfirmEdit.alias.php
index 353c8647..2b992cb8 100644
--- a/www/wiki/extensions/ConfirmEdit/ConfirmEdit.alias.php
+++ b/www/wiki/extensions/ConfirmEdit/ConfirmEdit.alias.php
@@ -118,6 +118,11 @@ $specialPageAliases['tr'] = [
'Captcha' => [ 'GüvenlikKodu' ],
];
+/** Urdu (اردو) */
+$specialPageAliases['ur'] = [
+ 'Captcha' => [ 'کیپچا' ],
+];
+
/** Cantonese (粵語) */
$specialPageAliases['yue'] = [
'Captcha' => [ '驗證碼' ],
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/ApiFancyCaptchaReload.php b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/ApiFancyCaptchaReload.php
index d53d7baa..f3e0d11b 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/ApiFancyCaptchaReload.php
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/ApiFancyCaptchaReload.php
@@ -23,6 +23,7 @@ class ApiFancyCaptchaReload extends ApiBase {
/**
* @see ApiBase::getExamplesMessages()
+ * @return array
*/
protected function getExamplesMessages() {
return [
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/FancyCaptcha.class.php b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/FancyCaptcha.class.php
index 8224ce7e..3010374f 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/FancyCaptcha.class.php
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/FancyCaptcha.class.php
@@ -81,7 +81,7 @@ class FancyCaptcha extends SimpleCaptcha {
}
/**
- * @param array $resultArr
+ * @param array &$resultArr
*/
function addCaptchaAPI( &$resultArr ) {
$info = $this->pickImage();
@@ -111,27 +111,22 @@ class FancyCaptcha extends SimpleCaptcha {
* @return array
*/
function getFormInformation( $tabIndex = 1 ) {
- global $wgEnableAPI;
$modules = [];
$title = SpecialPage::getTitleFor( 'Captcha', 'image' );
$info = $this->getCaptcha();
$index = $this->storeCaptcha( $info );
- if ( $wgEnableAPI ) {
- // Loaded only if JS is enabled
- $modules[] = 'ext.confirmEdit.fancyCaptcha';
+ // Loaded only for clients with JS enabled
+ $modules[] = 'ext.confirmEdit.fancyCaptcha';
- $captchaReload = Html::element(
- 'small',
- [
- 'class' => 'confirmedit-captcha-reload fancycaptcha-reload'
- ],
- wfMessage( 'fancycaptcha-reload-text' )->text()
- );
- } else {
- $captchaReload = '';
- }
+ $captchaReload = Html::element(
+ 'small',
+ [
+ 'class' => 'confirmedit-captcha-reload fancycaptcha-reload'
+ ],
+ wfMessage( 'fancycaptcha-reload-text' )->text()
+ );
$form = Html::openElement( 'div' ) .
Html::element( 'label', [
@@ -198,9 +193,9 @@ class FancyCaptcha extends SimpleCaptcha {
}
/**
- * @param $directory string
- * @param $levels integer
- * @param $lockouts integer
+ * @param string $directory
+ * @param int $levels
+ * @param int &$lockouts
* @return array|bool
*/
protected function pickImageDir( $directory, $levels, &$lockouts ) {
@@ -251,8 +246,8 @@ class FancyCaptcha extends SimpleCaptcha {
}
/**
- * @param $directory string
- * @param $lockouts integer
+ * @param string $directory
+ * @param int &$lockouts
* @return array|bool
*/
protected function pickImageFromDir( $directory, &$lockouts ) {
@@ -293,9 +288,9 @@ class FancyCaptcha extends SimpleCaptcha {
}
/**
- * @param $directory string
- * @param $files array
- * @param $lockouts integer
+ * @param string $directory
+ * @param array $files
+ * @param int &$lockouts
* @return array|bool
*/
protected function pickImageFromList( $directory, array $files, &$lockouts ) {
@@ -365,8 +360,8 @@ class FancyCaptcha extends SimpleCaptcha {
}
/**
- * @param $salt string
- * @param $hash string
+ * @param string $salt
+ * @param string $hash
* @return string
*/
public function imagePath( $salt, $hash ) {
@@ -382,7 +377,7 @@ class FancyCaptcha extends SimpleCaptcha {
}
/**
- * @param $basename string
+ * @param string $basename
* @return array (salt, hash)
* @throws Exception
*/
@@ -396,7 +391,7 @@ class FancyCaptcha extends SimpleCaptcha {
/**
* Delete a solved captcha image, if $wgCaptchaDeleteOnSolve is true.
- * @inheritdoc
+ * @inheritDoc
*/
protected function passCaptcha( $index, $word ) {
global $wgCaptchaDeleteOnSolve;
@@ -440,7 +435,7 @@ class FancyCaptcha extends SimpleCaptcha {
/**
* @param array $requests
* @param array $fieldInfo
- * @param array $formDescriptor
+ * @param array &$formDescriptor
* @param string $action
*/
public function onAuthChangeFormFields(
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/HTMLFancyCaptchaField.php b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/HTMLFancyCaptchaField.php
index fe8e7da1..52b0da38 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/HTMLFancyCaptchaField.php
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/HTMLFancyCaptchaField.php
@@ -26,25 +26,19 @@ class HTMLFancyCaptchaField extends HTMLFormField {
}
public function getInputHTML( $value ) {
- global $wgEnableAPI;
-
$out = $this->mParent->getOutput();
- // Uses addModuleStyles so it is loaded when JS is disabled.
+ // Uses addModuleStyles so it is loaded even when JS is disabled.
$out->addModuleStyles( 'ext.confirmEdit.fancyCaptcha.styles' );
- if ( $wgEnableAPI ) {
- // Loaded only if JS is enabled
- $out->addModules( 'ext.confirmEdit.fancyCaptcha' );
+ // Loaded only for clients with JS enabled
+ $out->addModules( 'ext.confirmEdit.fancyCaptcha' );
- $captchaReload = Html::element(
- 'small',
- [ 'class' => 'confirmedit-captcha-reload fancycaptcha-reload' ],
- $this->mParent->msg( 'fancycaptcha-reload-text' )->text()
- );
- } else {
- $captchaReload = '';
- }
+ $captchaReload = Html::element(
+ 'small',
+ [ 'class' => 'confirmedit-captcha-reload fancycaptcha-reload' ],
+ $this->mParent->msg( 'fancycaptcha-reload-text' )->text()
+ );
$attribs = [
'type' => 'text',
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/extension.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/extension.json
index a32dd1b1..d69472f5 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/extension.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/extension.json
@@ -6,7 +6,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:ConfirmEdit#FancyCaptcha",
"descriptionmsg": "fancycaptcha-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "antispam",
"APIModules": {
"fancycaptchareload": "ApiFancyCaptchaReload"
@@ -23,7 +23,6 @@
},
"ResourceModules": {
"ext.confirmEdit.fancyCaptcha.styles": {
- "position": "top",
"styles": "ext.confirmEdit.fancyCaptcha.css"
},
"ext.confirmEdit.fancyCaptcha": {
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ais.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ais.json
index 184e5e56..2a1dca59 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ais.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ais.json
@@ -1,11 +1,20 @@
{
"@metadata": {
"authors": [
- "Benel"
+ "Benel",
+ "Bunukwiki"
]
},
+ "fancycaptcha-addurl": "mikawaway-kalumyiti nu misu pisaungay tu baluhay ihekalay a masasiketay.\nsaka mitena’ tatuni’ mikawaway-kalumyiti cengse,pisuliti isasa’ay a sahakuay paazihay a masatekeday sulit ([[Special:Captcha/help|yadahay a cesyun]]):",
+ "fancycaptcha-badlogin": "saka mitena’ mima mihulakay a cense, maydih kisu pisuliti isasa’ay sahakuay maazihay a masatekeday-sulit ([[Special:Captcha/help|kayadahay a cesyun]]):",
"fancycaptcha-captcha": "kazahkezan kinsa",
"fancycaptcha-accountcreate": "payni satena’ lunuk pangangan cengse, pakalibut kami kisuan misuzu i sasaay sahakuay paazihay tu nisulitan. ([[Special:Captcha/help|yadah cesyun]]):",
+ "fancycaptcha-create": "saka mitena’ lunuk patizeng kasabelih a cengse, kanca kisu misulit isasa’ sahakuay paazihay a masatekeday sulit ([[Special:Captcha/help|yadahay a cesyun]]):",
+ "fancycaptcha-edit": "amahica amikawaway-kalumyiti uyni a kasabelih, pisulittan isasa’ay a sahakuay paazihay a masatekeday sulit ([[Special:Captcha/help|yadah cesyun]])",
"fancycaptcha-imgcaptcha-ph": "pisuliti kisu i zunga maazihay i cudad",
- "fancycaptcha-reload-text": "miliyaw misulimet"
+ "fancycaptcha-sendemail": "saka mitena’ tatuni’ mikawaway-kalumyiti a cense, maydih kisu pisuliti isasa’ay sahakuay maazihay a masatekeday-sulit ([[Special:Captcha/help| kayadahay a cesyun]]):",
+ "fancycaptcha-reload-text": "miliyaw misulimet",
+ "apihelp-fancycaptchareload-description": "maala baluhay FancyCaptcha",
+ "apihelp-fancycaptchareload-summary": "maala baluhay FancyCaptcha",
+ "apihelp-fancycaptchareload-example-1": "maala baluhay FancyCaptcha"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/am.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/am.json
index 2d06227e..b7b9bfc6 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/am.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/am.json
@@ -4,5 +4,6 @@
"Codex Sinaiticus"
]
},
- "fancycaptcha-accountcreate": "ያልተፈለገ የመኪናነት አባልነት ለመከላከል፥ አባል ለመሆን በዚህ ምስል የታዩት እንግሊዝኛ ቃላት ወይም ቁጥር መልስ በትክክል መጻፍ ግዴታ ነው። ([[Special:Captcha/help|ይህ ምንድነው?]]) (To help protect against automated spam, you must type in the words or correct number answer exactly as seen beneath here before registering your account:)<br />"
+ "fancycaptcha-accountcreate": "ያልተፈለገ የመኪናነት አባልነት ለመከላከል፥ አባል ለመሆን በዚህ ምስል የታዩት እንግሊዝኛ ቃላት ወይም ቁጥር መልስ በትክክል መጻፍ ግዴታ ነው። ([[Special:Captcha/help|ይህ ምንድነው?]]) (To help protect against automated spam, you must type in the words or correct number answer exactly as seen beneath here before registering your account:)<br />",
+ "fancycaptcha-imgcaptcha-ph": "ከላይ የሚታየውን ጽሁፍ ያስገቡ"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ang.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ang.json
index 4d85b59b..65f9249d 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ang.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ang.json
@@ -4,5 +4,6 @@
"Gott wisst"
]
},
+ "fancycaptcha-imgcaptcha-ph": "Besettan þone traht þe þū sīhst būfan",
"fancycaptcha-reload-text": "Ednīwian"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ar.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ar.json
index 7e4dfcc8..c043aa8b 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ar.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ar.json
@@ -6,14 +6,15 @@
"Meno25",
"Abanima",
"علاء",
- "Hhaboh162002"
+ "Hhaboh162002",
+ "أحمد"
]
},
"fancycaptcha-desc": "مولد فانسي كابتشا لConfirm Edit",
"fancycaptcha-addurl": "تعديلك يتضمن وصلات خارجية جديدة.\nللحماية من السخام الأوتوماتيكي، من فضلك أدخل الكلمات التي تظهر بالأسفل في الصندوق ([[Special:Captcha/help|مزيد من المعلومات]]):",
"fancycaptcha-badlogin": "للمساعدة في الحماية ضد سرقة كلمات السر، من فضلك أدخل الكلمات التي تظهر في الصندوق أدناه ([[Special:Captcha/help|مزيد من المعلومات]]):",
"fancycaptcha-captcha": "تحقق أمني",
- "fancycaptcha-accountcreate": "للمساعدة في منع إنشاء حسابات بطريقة أوتوماتيكية، قم من فضلك بإدخال الكلمات التي تظهر أدناه في الصندوق ([[Special:Captcha/help|مزيد من المعلومات]]):",
+ "fancycaptcha-accountcreate": "لحماية الويكي من الحسابات المنشأة آليا، نرجو منك إدخال الكلمات الظاهرة فيما يلي في الحقل ([[Special:Captcha/help|مزيد من المعلومات]]):",
"fancycaptcha-create": "لإنشاء الصفحة، من فضلك أدخل الكلمات التي تظهر بالأسفل في الصندوق\n([[Special:Captcha/help|مزيد من المعلومات]]):",
"fancycaptcha-edit": "لتعديل هذه الصفحة، من فضلك أدخل الكلمات التي تظهر بالأسفل في الصندوق\n([[Special:Captcha/help|مزيد من المعلومات]]):",
"fancycaptcha-imgcaptcha-ph": "أدخل النص الذي تراه في الصورة",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/av.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/av.json
index 6eacbda3..8dde2834 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/av.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/av.json
@@ -4,5 +4,7 @@
"Gazimagomedov"
]
},
+ "fancycaptcha-captcha": "ХIинкъибукIунгутIиялъул хал гьаби",
+ "fancycaptcha-imgcaptcha-ph": "Дуда тIадехун бихьулеб бугеб текст, хъвай",
"fancycaptcha-reload-text": "ЦӀигьабизе"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bg.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bg.json
index d28baa32..90a279f2 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bg.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bg.json
@@ -4,7 +4,8 @@
"Borislav",
"DCLXVI",
"Plamen",
- "StanProg"
+ "StanProg",
+ "ShockD"
]
},
"fancycaptcha-addurl": "Текущата редакция включва нови външни препратки.\nКато защита на това уики от автоматизиран спам, ви молим да въведете думите, показани по-долу в текстовата кутия ([[Special:Captcha/help|повече информация]]):",
@@ -17,5 +18,6 @@
"fancycaptcha-sendemail": "За да защитим системата от автоматизиран спам, учтиво Ви молим да въведете думите, които виждате в текстовата кутия ([[Special:Captcha/help|повече информация]]):",
"fancycaptcha-reload-text": "Опресняване",
"apihelp-fancycaptchareload-description": "Получаване на нова FancyCaptcha.",
+ "apihelp-fancycaptchareload-summary": "Получаване на нова FancyCaptcha.",
"apihelp-fancycaptchareload-example-1": "Получаване на нова FancyCaptcha"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bto.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bto.json
new file mode 100644
index 00000000..a74181a2
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/bto.json
@@ -0,0 +1,4 @@
+{
+ "@metadata": [],
+ "fancycaptcha-imgcaptcha-ph": "Ibutang a tekstong nababayad mo sa ibabow"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/cdo.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/cdo.json
index 6a17fa25..e7066c19 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/cdo.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/cdo.json
@@ -5,5 +5,7 @@
"唐吉訶德的侍從"
]
},
- "fancycaptcha-badlogin": "為𡅏避免維基百科乞自動化其密碼破解,儂家起動汝拍出下底方框裡勢其驗證碼([[Special:Captcha/help|更価信息]]):"
+ "fancycaptcha-badlogin": "為𡅏避免維基百科乞自動化其密碼破解,儂家起動汝拍出下底方框裡勢其驗證碼([[Special:Captcha/help|更価信息]]):",
+ "fancycaptcha-captcha": "安全檢查",
+ "fancycaptcha-imgcaptcha-ph": "將汝敆圖片上看見其文字拍出來"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ce.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ce.json
index e8ad98b1..4015d0d0 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ce.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ce.json
@@ -4,6 +4,7 @@
"Умар"
]
},
+ "fancycaptcha-desc": "Тамашийна CAPTCHA-генератор тадар чӀагӀдаран",
"fancycaptcha-addurl": "Хьан нисдар чохь керла арахьара хьажоргаш ю. Спамах лардала дехар до лахахь гура чохь гайтан дешнаш язъе ([[Special:Captcha/help|ма-дарра…]]):",
"fancycaptcha-badlogin": "Шашеха паролаш йохорах ларъян Ӏалашонца дехар до, лахарчу гура чохь гайтина дош язде ([[Special:Captcha/help|мадарра…]]):",
"fancycaptcha-captcha": "Кхерамзалла хьажар",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/chr.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/chr.json
new file mode 100644
index 00000000..37d167c0
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/chr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "R12ntech"
+ ]
+ },
+ "fancycaptcha-reload-text": "ᎯᏤᎲᏍᏓ"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-cyrl.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-cyrl.json
new file mode 100644
index 00000000..2015f65a
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-cyrl.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Телюкесизлик контроли",
+ "fancycaptcha-imgcaptcha-ph": "Юкъарыда корьген метнинъизни язынъыз"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-latn.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-latn.json
new file mode 100644
index 00000000..c6849d5c
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/crh-latn.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Telükesizlik kontroli",
+ "fancycaptcha-imgcaptcha-ph": "Yuqarıda körgen metniñizni yazıñız"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/diq.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/diq.json
index f53a1f22..e3ce23e3 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/diq.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/diq.json
@@ -16,7 +16,7 @@
"fancycaptcha-edit": "Qe pel vurnayîşî, ma rica keno çekuyanê ke qutiya cor de înan binuse ([[Special:Captcha/help|enformasyonê bînî]]):",
"fancycaptcha-imgcaptcha-ph": "Nuşteyo ke cor aseno ey resimi ser ke.",
"fancycaptcha-sendemail": "Qe spamê otomayoni ra pawitîşi, ma rica keno çekuyanê ke qutiya cor de înan binuse \n([[Special:Captcha/help|enformasyonê bînî]]):",
- "fancycaptcha-reload-text": "Anewe kı",
+ "fancycaptcha-reload-text": "Newe ke",
"apihelp-fancycaptchareload-description": "Şo newe FancyCaptcha.",
"apihelp-fancycaptchareload-example-1": "Şo newe FancyCaptcha"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ee.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ee.json
new file mode 100644
index 00000000..ade4e9b2
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ee.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Dedienɔnɔ ƒe dodokpɔ",
+ "fancycaptcha-imgcaptcha-ph": "Ŋlɔ nya siwo le etame"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/el.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/el.json
index fc302e0a..724b7fac 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/el.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/el.json
@@ -7,7 +7,8 @@
"Glavkos",
"ZaDiak",
"Evropi",
- "Protnet"
+ "Protnet",
+ "Nikosgranturismogt"
]
},
"fancycaptcha-addurl": "Η επεξεργασία σας περιλαμβάνει νέους εξωτερικούς συνδέσμους.\nΩς βοήθεια για την προστασία του wiki από αυτόματα spam, παρακαλούμε γράψτε τις λέξεις που εμφανίζονται παρακάτω στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
@@ -18,5 +19,8 @@
"fancycaptcha-edit": "Για να επεξεργαστείτε αυτήν την σελίδα, παρακαλούμε εισαγάγετε τις λέξεις που εμφανίζονται παρακάτω μέσα στο πλαίσιο\n([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
"fancycaptcha-imgcaptcha-ph": "Εισάγετε το κείμενο που βλέπετε στην εικόνα",
"fancycaptcha-sendemail": "Ως βοήθεια για την προστασία του wiki από αυτόματα προγράμματα σπασίματος κωδικών, παρακαλούμε γράψτε τις λέξεις που εμφανίζονται παρακάτω στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
- "fancycaptcha-reload-text": "Ανανέωση"
+ "fancycaptcha-reload-text": "Ανανέωση",
+ "apihelp-fancycaptchareload-description": "Πάρτε ένα νέο FancyCaptcha.",
+ "apihelp-fancycaptchareload-summary": "Πάρτε ένα νέο FancyCaptcha.",
+ "apihelp-fancycaptchareload-example-1": "Πάρτε ένα νέο FancyCaptcha."
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/es.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/es.json
index 5f3973e2..f0bfea8e 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/es.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/es.json
@@ -22,5 +22,6 @@
"fancycaptcha-sendemail": "Para proteger el wiki contra el spam automatizado, escribe en el recuadro las palabras que aparecen debajo ([[Special:Captcha/help|más información]]):",
"fancycaptcha-reload-text": "Actualizar",
"apihelp-fancycaptchareload-description": "Obtener un FancyCaptcha nuevo.",
+ "apihelp-fancycaptchareload-summary": "Obtener un FancyCaptcha nuevo.",
"apihelp-fancycaptchareload-example-1": "Obtener un FancyCaptcha nuevo"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fa.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fa.json
index 637ab206..87634841 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fa.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fa.json
@@ -21,5 +21,6 @@
"fancycaptcha-sendemail": "برای کمک به محافظت در برابر هرزه‌نگاری خودکار، ما با احترام از شما می‌خواهیم واژه‌هایی را که در جعبهٔ زیر نمایش داده می‌شوند وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
"fancycaptcha-reload-text": "تازه کردن",
"apihelp-fancycaptchareload-description": "یک FancyCaptcha جدید بیاور.",
+ "apihelp-fancycaptchareload-summary": "کپچای جدید دریافت کن.",
"apihelp-fancycaptchareload-example-1": "یک FancyCaptcha جدید بیاور."
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fr.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fr.json
index c6c63bc6..975ae5de 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fr.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fr.json
@@ -12,8 +12,8 @@
]
},
"fancycaptcha-desc": "Générateur d’images ''captcha'' anti-robots demandant une confirmation humaine des modifications.",
- "fancycaptcha-addurl": "Votre modification inclut de nouveaux liens externes.\nPour protéger le wiki contre les pourriels automatisés, nous vous demandons de bien vouloir entrer les mots qui apparaissent dans la boîte ([[Special:Captcha/help|plus d’informations]]) :",
- "fancycaptcha-badlogin": "Pour protéger le wiki contre le cassage des mots de passe par des automates, nous vous demandons de bien vouloir entrer les mots qui apparaissent dans la boîte ci-dessous ([[Special:Captcha/help|plus d’informations]]) :",
+ "fancycaptcha-addurl": "Votre modification inclut de nouveaux liens externes.\nPour protéger le wiki contre les pourriels automatisés, nous vous demandons de bien vouloir entrer les mots qui apparaissent ci-dessous dans la boîte ([[Special:Captcha/help|plus d’informations]]) :",
+ "fancycaptcha-badlogin": "Pour protéger le wiki contre le forçage des mots de passe par des automates, nous vous demandons de bien vouloir entrer les mots qui apparaissent dans la boîte ci-dessous ([[Special:Captcha/help|plus d’informations]]) :",
"fancycaptcha-captcha": "Contrôle de sécurité",
"fancycaptcha-accountcreate": "Pour protéger le wiki contre les créations automatiques de comptes, nous vous demandons de bien vouloir entrer les mots qui apparaissent dans la boîte ci-dessous ([[Special:Captcha/help|plus d’informations]]) :",
"fancycaptcha-create": "Pour créer la page, veuillez entrer les mots qui apparaissent dans la boîte ci-dessous ([[Special:Captcha|plus d’informations]]) :",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/frp.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/frp.json
index 8015cf71..ad0555b5 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/frp.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/frp.json
@@ -8,7 +8,7 @@
"fancycaptcha-addurl": "Voutron changement encllut de lims de defôr novéls.\nPor nos édiér a combatre contre lo spame ôtomatisâ, volyéd buchiér los mots qu’aparèssont dens la bouèta ce-desot ([[Special:Captcha/help|més d’enformacions]]) :",
"fancycaptcha-badlogin": "Por nos édiér a combatre contre lo cassâjo ôtomatisâ de contresegnos, volyéd buchiér los mots qu’aparèssont dedens la bouèta ce-desot ([[Special:Captcha/help|més d’enformacions]]) :",
"fancycaptcha-captcha": "Contrôlo de sècuritât",
- "fancycaptcha-accountcreate": "Por nos édiér a combatre contre les crèacions ôtomatisâs de comptos, volyéd buchiér los mots qu’aparèssont dens la bouèta ce-desot ([[Special:Captcha/help|més d’enformacions]]) :",
+ "fancycaptcha-accountcreate": "Por protègiér lo vouiqui contre les crèacions ôtomatisâyes de comptios, se vos plét buchiéd los mots qu’aparèssont dedens la bouèta ce-desot ([[Special:Captcha/help|més d’enformacions]]) :",
"fancycaptcha-create": "Por fâre ceta pâge, volyéd buchiér los mots qu’aparèssont dens la bouèta ce-desot ([[Special:Captcha/help|més d’enformacions]]) :",
"fancycaptcha-edit": "Por changiér ceta pâge, volyéd buchiér los mots qu’aparèssont dens la bouèta ce-desot ([[Special:Captcha/help|més d’enformacions]]) :",
"fancycaptcha-imgcaptcha-ph": "Buchiéd lo tèxto que vos vêde sur l’émâge",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fy.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fy.json
index f2441b1b..41d0d95b 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fy.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/fy.json
@@ -4,5 +4,7 @@
"Snakesteuben"
]
},
- "fancycaptcha-badlogin": "As ekstra beskerming tsjin automatysk ûntsiferjen fan wachtwurden wurdt jo frege de ûndersteande letters oer te tikken. ([[Special:Captcha/help|mear ynformaasje]])."
+ "fancycaptcha-badlogin": "As ekstra beskerming tsjin automatysk ûntsiferjen fan wachtwurden wurdt jo frege de ûndersteande letters oer te tikken. ([[Special:Captcha/help|mear ynformaasje]]).",
+ "fancycaptcha-captcha": "Feiligenshifking",
+ "fancycaptcha-imgcaptcha-ph": "Nim de tekst fan hjirboppe oer"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/gcr.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/gcr.json
new file mode 100644
index 00000000..acc2358a
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/gcr.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "fancycaptcha-captcha": "Kontrol di sékirité",
+ "fancycaptcha-accountcreate": "Pou protéjé wiki kont kréyasyon-yan otomatik di kont, nou ka doumandé zòt di byen lé antré mo-ya ki ka aparèt annan bwat-a ki anba ([[Special:Captcha/help|plis enfòrmasyon]]) :",
+ "fancycaptcha-imgcaptcha-ph": "Antré tèks-a ki zòt ka wè asou imaj-a",
+ "fancycaptcha-reload-text": "Atchwalizé"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/got.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/got.json
new file mode 100644
index 00000000..b2fa0b9b
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/got.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gothicspeaker"
+ ]
+ },
+ "fancycaptcha-accountcreate": "𐌳𐌿 𐌷𐌰𐌱𐌰𐌽 𐌼𐌿𐌽𐌳 𐍅𐌹𐌸𐍂𐌰 𐍃𐌹𐌻𐌱𐌰𐍄𐍉𐌾𐌰𐌽𐌳𐌴𐌹𐌽 𐌺𐌰𐍅𐍄𐍃𐌾𐍉𐌲𐌰𐍃𐌺𐌰𐍆𐍄 𐌹𐌽 𐌸𐌰𐌼𐌼𐌰 𐍅𐌹𐌺𐌾𐌰, 𐌱𐌹𐌳𐌾𐌰𐌼 𐌸𐌿𐌺 𐌴𐌹 𐌼𐌴𐌻𐌾𐌰𐌹𐍃 𐍅𐌰𐌿𐍂𐌳 𐌸𐌰𐍄𐌴𐌹 𐌲𐌰𐌱𐌰𐌹𐍂𐌷𐍄𐌴𐌹𐌸 𐌿𐍆 𐌹𐌽 𐌰𐍂𐌺𐌰𐌹 ([[special:captcha/help|𐌼𐌰𐌽𐌰𐌲𐌹𐌶𐍉 𐌺𐌿𐌽𐌸𐌹]]):",
+ "fancycaptcha-imgcaptcha-ph": "𐌼𐌴𐌻𐌴𐌹 𐌱𐍉𐌺𐍉𐍃 𐌸𐍉𐌶𐌴𐌹 𐍃𐌰𐌹𐍈𐌹𐍃 𐌰𐌽𐌰 𐍆𐍂𐌹𐍃𐌰𐌷𐍄𐌰𐌹"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/haw.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/haw.json
new file mode 100644
index 00000000..91514fa9
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/haw.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Hōʻoiana palekana",
+ "fancycaptcha-imgcaptcha-ph": "E kikokiko i ke kikokikona i luna"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hi.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hi.json
index 56dbfbe5..a14fb101 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hi.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hi.json
@@ -5,7 +5,8 @@
"Siddhartha Ghai",
"Hindustanilanguage",
"Sfic",
- "संजीव कुमार"
+ "संजीव कुमार",
+ "Innocentbunny"
]
},
"fancycaptcha-addurl": "आपके सम्पादन में नई बाहरी कड़ियाँ हैं।\nस्वचालित अनचाहे से विकि को बचाने के लिए, हम आपको नीचे के सन्दूक में दिये गये शब्द को लिखने का आग्रह कर रहे हैं ([[Special:Captcha/help|अधिक जानकारी]]):",
@@ -18,5 +19,6 @@
"fancycaptcha-sendemail": "अपने आप होने वाले स्पैम से बचाने के लिए हम आपसे नीचे दिये गए शब्द को भरने के लिए बोल रहे हैं। ([[Special:Captcha/help|अधिक जानकारी]]):",
"fancycaptcha-reload-text": "रिफ़्रेश",
"apihelp-fancycaptchareload-description": "नया लुभावना-कैपचा प्राप्त करें।",
+ "apihelp-fancycaptchareload-summary": "नया लुभावना-कैपचा प्राप्त करें।",
"apihelp-fancycaptchareload-example-1": "नया लुभावना-कैपचा प्राप्त करें।"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hrx.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hrx.json
new file mode 100644
index 00000000..0534d785
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hrx.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Sicherheitsprüfung",
+ "fancycaptcha-imgcaptcha-ph": "Geb den Text ren, den wo du uwe siehst."
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ht.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ht.json
index 2df49572..0b0cc960 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ht.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ht.json
@@ -4,5 +4,7 @@
"Tisave"
]
},
- "fancycaptcha-accountcreate": "Pou anpeche ke kont kreye otomatikman wou wiki, n ap mande ou tanpri souple ekri mo yo ki parèt nan bwat la ([[Special:Captcha/help|more info]]):"
+ "fancycaptcha-captcha": "Verifikasyon sekirite",
+ "fancycaptcha-accountcreate": "Pou anpeche ke kont kreye otomatikman wou wiki, n ap mande ou tanpri souple ekri mo yo ki parèt nan bwat la ([[Special:Captcha/help|more info]]):",
+ "fancycaptcha-imgcaptcha-ph": "Rantre teks ke w anlè a"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hyw.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hyw.json
new file mode 100644
index 00000000..8403abcf
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/hyw.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "ArmenBakkalian"
+ ]
+ },
+ "fancycaptcha-accountcreate": "Պաշտպանելու համար Ուիքին մեքենական ինքնագործ հաշիւներու ստեղծումէն, կը խնդրուի տուփիկին մէջ նշուած բառերը գրել: [[Special:Captcha/help|յաւելեալ տեղեկութիւն]]"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/id.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/id.json
index 4b00e143..e3679681 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/id.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/id.json
@@ -4,7 +4,8 @@
"Bennylin",
"IvanLanin",
"Iwan Novirion",
- "Rachmat.Wahidi"
+ "Rachmat.Wahidi",
+ "Rachmat04"
]
},
"fancycaptcha-addurl": "Suntingan Anda mencantumkan pranala luar baru. Untuk pelindungan terhadap spam otomatis, harap masukkan kata di bawah ini ke dalam kotak yang tersedia ([[Special:Captcha/help|info lengkap]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/io.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/io.json
index 7d97dce8..e9527d4a 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/io.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/io.json
@@ -6,5 +6,6 @@
},
"fancycaptcha-captcha": "Verifiko di sekureso",
"fancycaptcha-accountcreate": "Por protektar la wiki kontre l'automatala kreado di konti, ni bonvole pregas ke vu kopiez la vorti qui aparas en la buxo infre\n([[Special:Captcha/help|plusa informi]]):",
- "fancycaptcha-imgcaptcha-ph": "Skribez la texto qua vu vidas en l'imajo"
+ "fancycaptcha-imgcaptcha-ph": "Skribez la texto qua vu vidas en l'imajo",
+ "fancycaptcha-reload-text": "Rinovigar"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/jv.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/jv.json
index 759d530f..37ff40d1 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/jv.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/jv.json
@@ -12,7 +12,7 @@
"fancycaptcha-accountcreate": "Kanggo ngreksa wiki saka panggawé akun otomatis, tulung tembung sing katon ana ngisor iki panjenengan tulisaké ing kothak ngisor iki ([[Special:Captcha/help|katerangan candhaké]]):",
"fancycaptcha-create": "Suntingan panjenengan ngandhut pranala jaba anyar. Kanggo nggawé kaca iki, mangga isèkna tembung-tembung sing ana ing kothak iki ([[Special:Captcha/help|info jangkep]]):",
"fancycaptcha-edit": "Suntingan panjenengan ngandhut pranala jaba anyar. Kanggo nyunting kaca iki, mangga isèkna tembung-tembung sing ana ing kothak iki ([[Special:Captcha/help|info jangkep]]):",
- "fancycaptcha-imgcaptcha-ph": "Lebokaké tèks sing kokdeleng ing gambar",
+ "fancycaptcha-imgcaptcha-ph": "Isi tèks sing panjenengan deleng ing gambar",
"fancycaptcha-sendemail": "Kanggo ngreksa lawan spam otomatis, tulung lebokna ukara ing ngisor iki menyang sajroning kothak sing wis sumedya ([[Special:Captcha/help|info sabanjuré]]):",
"fancycaptcha-reload-text": "Anyarana",
"apihelp-fancycaptchareload-description": "Golèk FancyCaptcha anyar.",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kg.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kg.json
new file mode 100644
index 00000000..911a44d8
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kg.json
@@ -0,0 +1,4 @@
+{
+ "@metadata": [],
+ "fancycaptcha-imgcaptcha-ph": "Sonika bisono yina kele na zulu"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ku-latn.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ku-latn.json
index 6c178ed9..51a16fbf 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ku-latn.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ku-latn.json
@@ -5,6 +5,6 @@
]
},
"fancycaptcha-captcha": "Kontrola asayîşê",
- "fancycaptcha-imgcaptcha-ph": "Nivîsa ku tu li jor dibînî binivîse",
+ "fancycaptcha-imgcaptcha-ph": "Nivîsa ku tu li ser wêneyê dibînî binivîse",
"fancycaptcha-reload-text": "Nûkirin"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kum.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kum.json
new file mode 100644
index 00000000..4360472c
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kum.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arsenekoumyk",
+ "ArslanX"
+ ]
+ },
+ "fancycaptcha-captcha": "Къавупсузлукъ тергевю",
+ "fancycaptcha-accountcreate": "Викини автоматик бет яратывдан къорумакъ учун тюпдеги къутукъдан сёзлени язмагъа тилейбиз ([[Special:Captcha/help|артыкъ инфо]]):",
+ "fancycaptcha-imgcaptcha-ph": "Суратда гёреген текстни бер",
+ "fancycaptcha-reload-text": "Янгыртмакъ"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kw.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kw.json
index 9f90a8b3..5bcf2f1f 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kw.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/kw.json
@@ -5,5 +5,7 @@
"Nrowe"
]
},
- "fancycaptcha-accountcreate": "Rag gwitha rag gwruthyl akontow yawtomategys, entrewgh an geryow a omdhiskwa a-woles y'n gist ([[Special:Captcha/help|moy kedhlow]]):"
+ "fancycaptcha-captcha": "Gwiryans sekerder",
+ "fancycaptcha-accountcreate": "Rag gwitha rag gwruthyl akontow yawtomategys, entrewgh an geryow a omdhiskwa a-woles y'n gist ([[Special:Captcha/help|moy kedhlow]]):",
+ "fancycaptcha-imgcaptcha-ph": "Entrewgh an tekst a welowgh a-ugh"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ky.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ky.json
index 75b7f65e..082b1227 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ky.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ky.json
@@ -5,6 +5,8 @@
"Janatkg"
]
},
+ "fancycaptcha-captcha": "Коопсуздук текшерүүсү",
+ "fancycaptcha-imgcaptcha-ph": "Жогорудагы текстти териңиз",
"fancycaptcha-sendemail": "Автоматташтырылган спамдан коргонууга жардам катары бул сөздөрдү төмөндөгү көзөнөккө киргизиңиз ([[Special:Captcha/help|more info]]):",
"fancycaptcha-reload-text": "Жаңылоо"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lij.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lij.json
index c1f9e926..6a90f455 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lij.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lij.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Giromin Cangiaxo"
+ "Giromin Cangiaxo",
+ "S4b1nuz E.656"
]
},
"fancycaptcha-addurl": "A to modiffica a l'includde di nœuvi inganci esterni; comme mezua precaoçionâ contra o spam aotomatico, te domandemmo gentilmente d'insei inta casella sottostante e paole che compàn chì de sotta ([[Special:Captcha/help|comm'o funçion-a?]]):",
@@ -12,7 +13,7 @@
"fancycaptcha-edit": "Pe modificâ sta paggina se prega de scrive inta casella e paole che compàn chì aproeuvo ([[Special:Captcha/help|comme l'è ch'o fonçion-a?]]):",
"fancycaptcha-imgcaptcha-ph": "Scrivi quello che ti veddi chì de d'ato",
"fancycaptcha-sendemail": "Pe proteze o wiki da-a spam aotomatizâ, te preghemmo d'insei inta casella sottostante e paole che compàn chì aproeuvo ([[Special:Captcha/help|comme l'è ch'o fonçion-a?]]):",
- "fancycaptcha-reload-text": "Aggiorna",
+ "fancycaptcha-reload-text": "Agiorna",
"apihelp-fancycaptchareload-description": "Otegni un noeuvo FancyCaptcha.",
"apihelp-fancycaptchareload-example-1": "Otegni un noeuvo FancyCaptcha."
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lmo.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lmo.json
new file mode 100644
index 00000000..03eb825f
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lmo.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Contròl de sigürèsa",
+ "fancycaptcha-imgcaptcha-ph": "Mèt dét el tèst che te èdet ché sura"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lrc.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lrc.json
index 5368761d..b65a4495 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lrc.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lrc.json
@@ -4,9 +4,9 @@
"Mogoeilor"
]
},
- "fancycaptcha-captcha": "ڤارئسی أمنیأت دار بییئن",
+ "fancycaptcha-captcha": "ۋارسی ٱمنیتی",
"fancycaptcha-accountcreate": "سی پر و پیم کاری ویکی د ری وه ری حساو راس کنی خود انجوم، ایما وا نازاری دتو میهایم که کلیمه یایی که هان د جعوه ([[Special:رازینه کپچا/هومیاری|دونسمنیا هنی]]):ایچه بنیسیت",
- "fancycaptcha-imgcaptcha-ph": "نیسئسە یی نە کئ د ڤارو مئینیت ڤارئد بأکیت",
+ "fancycaptcha-imgcaptcha-ph": "نیسسٱیی ناٛ کاٛ د ٱسگ مینیت ۋارد بٱکیت",
"fancycaptcha-reload-text": "د نؤ كردن",
"apihelp-fancycaptchareload-description": "یه گل FancyCaptcha نه بیئریت.",
"apihelp-fancycaptchareload-example-1": "یه گل رازینه کپچا نازار تازه بئیرت."
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lt.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lt.json
index a90fcab8..f5e6e714 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lt.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/lt.json
@@ -3,13 +3,14 @@
"authors": [
"Eitvys200",
"Hugo.arg",
- "Albertas"
+ "Albertas",
+ "Tomasdd"
]
},
"fancycaptcha-addurl": "Jūsų pakeitimuose yra nauja išorinė nuoroda.\nKad apsaugotume šį viki nuo automatizuoto brukalo, maloniai prašome jūsų įvesti žemiau nurodytus žodžius į langelį ([[Special:Captcha/help|daugiau informacijos]]):",
"fancycaptcha-badlogin": "Kad apsaugotume viki nuo automatizuoto slaptažodžių nulaužinėjimo, maloniai prašome įvesti žemiau nurodytus žodžius į langelį ([[Special:Captcha/help|daugiau informacijos]]):",
"fancycaptcha-captcha": "Saugumo patikrinimas",
- "fancycaptcha-accountcreate": "Siekiant apsaugoti wiki nuo automatinių paskyrų kūrimo, prašome jus įvesti žodžius, matomus rėmelyje apačioje ([[Special:Captcha/help|plačiau...]]):",
+ "fancycaptcha-accountcreate": "Siekiant apsaugoti viki nuo automatinių paskyrų kūrimo, prašome jus įvesti žodžius, matomus rėmelyje apačioje ([[Special:Captcha/help|plačiau...]]):",
"fancycaptcha-create": "Kad sukurtumėte puslapį, prašome įvesti žemiau nurodytus žodžius į langelį ([[Special:Captcha/help|daugiau informacijos]]):",
"fancycaptcha-edit": "Kad atliktumėte šio puslapio pakeitimą, prašome įvesti žemiau nurodytus žodžius į langelį ([[Special:Captcha/help|daugiau informacijos]]):",
"fancycaptcha-imgcaptcha-ph": "Įveskite tekstą, kurį matote paveikslėlyje",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/map-bms.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/map-bms.json
new file mode 100644
index 00000000..bdef2cf4
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/map-bms.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Priksa keamanan",
+ "fancycaptcha-imgcaptcha-ph": "Lebokna teks sing keton nang dhuwur"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mfe.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mfe.json
new file mode 100644
index 00000000..989a67af
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mfe.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Security check",
+ "fancycaptcha-imgcaptcha-ph": "Ekrir text ki ou pe truve en-ba"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/min.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/min.json
index f3be9daa..a8d95c99 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/min.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/min.json
@@ -4,5 +4,7 @@
"Iwan Novirion"
]
},
- "fancycaptcha-accountcreate": "Untuak palinduangan tahadok pambuek akun otomatis, tolong masuakan kato di bawah ko ka kotak nan tasadio ([[Special:Captcha/help|info labiah lanjuik]]):"
+ "fancycaptcha-captcha": "Pamarisoan kaamanan",
+ "fancycaptcha-accountcreate": "Untuak palinduangan tahadok pambuek akun otomatis, tolong masuakan kato di bawah ko ka kotak nan tasadio ([[Special:Captcha/help|info labiah lanjuik]]):",
+ "fancycaptcha-imgcaptcha-ph": "Masuakan teks nan Sanak caliak di ateh"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mn.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mn.json
new file mode 100644
index 00000000..06408eb6
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mn.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Аюулгүй байдлын хяналт",
+ "fancycaptcha-imgcaptcha-ph": "Дээр харагдаж буй бичвэрийг оруулна уу"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mo.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mo.json
new file mode 100644
index 00000000..0f151d81
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mo.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "TheChampionMan1234"
+ ]
+ },
+ "fancycaptcha-reload-text": "Реынкаркэ"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mwl.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mwl.json
new file mode 100644
index 00000000..fd7191a3
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/mwl.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "fancycaptcha-captcha": "Berificaçon de sigurança",
+ "fancycaptcha-accountcreate": "Pa porteger esta wiki contra la criaçon de cuontas outomatizada, por fabor, poner na caixa ambaixo las palabras apersentadas ([[Special:Captcha/help|mais anformaçones]]):",
+ "fancycaptcha-imgcaptcha-ph": "Screba l testo que stá a ber na eimaige",
+ "fancycaptcha-reload-text": "Atualizar"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/myv.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/myv.json
new file mode 100644
index 00000000..aab7412b
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/myv.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Rueter"
+ ]
+ },
+ "fancycaptcha-reload-text": "Одкстомтомс"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nan.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nan.json
new file mode 100644
index 00000000..6e2ed9a3
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nan.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "An-choân kiám-cha",
+ "fancycaptcha-imgcaptcha-ph": "Kā ē-kha lí khoàⁿ tio̍h--ê bûn-jī phah ji̍p lâi"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nds-nl.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nds-nl.json
index e0fb9a1e..611815f8 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nds-nl.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nds-nl.json
@@ -10,7 +10,7 @@
"fancycaptcha-accountcreate": "Um disse wiki te bescharmen tegen t automaties anmaken van gebrukersprofielen mu'j t woord hieronder invullen ([[Special:Captcha/help|hulpe]]):",
"fancycaptcha-create": "Um n pagina an te maken, mö'j t woord dat hieronder steet invullen\n([[Special:Captcha/help|hulpe]]):",
"fancycaptcha-edit": "Vul de woorden die hieronder staon in um disse zied te bewarken ([[Special:Captcha/help|hulpe]]):",
- "fancycaptcha-imgcaptcha-ph": "Voer de tekste in die'j hierboven zien",
+ "fancycaptcha-imgcaptcha-ph": "Voer de tekste in die'j op de aofbeelding zien",
"fancycaptcha-sendemail": "Voer de woorden die hieronder staon in t invoerveld in as bescharming tegen automatiese ongewunste reklame \n([[Special:Captcha/help|hulpe]]):",
"fancycaptcha-reload-text": "Verniejen"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nl.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nl.json
index 75f0de8c..04576945 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nl.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nl.json
@@ -5,14 +5,15 @@
"Siebrand",
"Esketti",
"Sjoerddebruin",
- "Dinosaur918"
+ "Dinosaur918",
+ "Mar(c)"
]
},
"fancycaptcha-desc": "Generator voor opgedirkte captcha's voor ConfirmEdit",
"fancycaptcha-addurl": "Uw bewerking bevat nieuwe externe koppelingen.\nVoer de woorden die hieronder verschijnen in het invoerveld in als bescherming tegen automatische spam ([[Special:Captcha/help|meer informatie]]):",
"fancycaptcha-badlogin": "Voer de woorden die hieronder getoond worden in het invoerveld in als bescherming tegen het automatisch kraken van wachtwoorden ([[Special:Captcha/help|meer informatie]]):",
"fancycaptcha-captcha": "Veiligheidscontrole",
- "fancycaptcha-accountcreate": "Voer de woorden die hieronder getoond worden in het invoerveld in ter bescherming tegen het geautomatiseerd aanmaken van gebruikers ([[Special:Captcha/help|meer informatie]]):",
+ "fancycaptcha-accountcreate": "Om de wiki te beschermen tegen het geautomatiseerd aanmaken van accounts, vragen wij u de woorden in te voeren die in het vak hieronder getoond worden ([[Special:Captcha/help|meer informatie]]):",
"fancycaptcha-create": "Voer de woorden die hieronder verschijnen in het invoerveld in om de pagina aan te maken ([[Special:Captcha/help|meer informatie]]):",
"fancycaptcha-edit": "Voer de woorden die hieronder verschijnen in het invoerveld in om deze pagina te bewerken ([[Special:Captcha/help|meer informatie]]):",
"fancycaptcha-imgcaptcha-ph": "Geef de tekst die u in de afbeelding ziet",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nys.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nys.json
new file mode 100644
index 00000000..42d5f806
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/nys.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "fancycaptcha-captcha": "Security check",
+ "fancycaptcha-accountcreate": "To protect the wiki against automated account creation, we kindly ask you to enter the words that appear below in the box ([[Special:Captcha/help|more info]]):",
+ "fancycaptcha-imgcaptcha-ph": "Djarbiny text djinang il image",
+ "fancycaptcha-reload-text": "yyinang djinang"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/os.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/os.json
new file mode 100644
index 00000000..dd347c9b
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/os.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Æдасдзинад бæлвырдгæнæн",
+ "fancycaptcha-imgcaptcha-ph": "Уæлдæр цы текст уыныс, уый бафысс"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ppl.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ppl.json
new file mode 100644
index 00000000..bd474c65
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ppl.json
@@ -0,0 +1,4 @@
+{
+ "@metadata": [],
+ "fancycaptcha-imgcaptcha-ph": "Shiktajkwilu ne pajpalabraj tikita ikajku"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ps.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ps.json
index 254e06d8..05dff8bc 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ps.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ps.json
@@ -1,10 +1,11 @@
{
"@metadata": {
"authors": [
- "Ahmed-Najib-Biabani-Ibrahimkhel"
+ "Ahmed-Najib-Biabani-Ibrahimkhel",
+ "Baloch Khan"
]
},
- "fancycaptcha-captcha": "امنيتي جاج",
+ "fancycaptcha-captcha": "امنيتي کتنه",
"fancycaptcha-accountcreate": "په ويکي کې د خپلسري گڼون جوړېدنې د مخنيوي په خاطر موږ له تاسې غوښتنه کوو چې لانديني توري هماغسې په ورکړل شوي بکس کې وټاپئ څنگه چې تاسې ته ښکارېږي ([[Special:Captcha/help|لا نور مالومات]]):",
"fancycaptcha-create": "ددې مخ د جوړلو لپاره، لطفاً ورکړل شوي توري چې څنگه تاسې ته ښکاري هماغسې کټ مټ په لانديني چوکاټ کې وليکی ([[Special:Captcha/help|نور مالومات]]):",
"fancycaptcha-edit": "ددې مخ د سمولو لپاره، لطفاً ورکړل شوي توري چې څنگه تاسې ته ښکاري هماغسې کټ مټ په لانديني چوکاټ کې وليکی ([[Special:Captcha/help|نور مالومات]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/pt.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/pt.json
index 747d872f..52fbdd53 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/pt.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/pt.json
@@ -9,7 +9,7 @@
]
},
"fancycaptcha-desc": "Gerador sofisticado de captcha para o Confirm Edit",
- "fancycaptcha-addurl": "A sua edição introduziu links externos novos.\nPara proteger esta wiki contra o spam automatizado, por favor, introduza na caixa abaixo as palavras apresentadas ([[Special:Captcha/help|mais informações]]):",
+ "fancycaptcha-addurl": "A sua edição introduziu hiperligações externas novas.\nPara proteger esta wiki contra o spam automatizado, por favor, introduza na caixa abaixo as palavras apresentadas ([[Special:Captcha/help|mais informações]]):",
"fancycaptcha-badlogin": "Para proteger esta wiki contra os mecanismos automatizados de descoberta de palavras-passe, por favor, introduza na caixa abaixo as palavras apresentadas ([[Special:Captcha/help|mais informações]]):",
"fancycaptcha-captcha": "Verificação de segurança",
"fancycaptcha-accountcreate": "Para proteger esta wiki contra a criação de contas automatizada, por favor, introduza na caixa abaixo as palavras apresentadas ([[Special:Captcha/help|mais informações]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rmf.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rmf.json
new file mode 100644
index 00000000..978dc628
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rmf.json
@@ -0,0 +1,4 @@
+{
+ "@metadata": [],
+ "fancycaptcha-imgcaptcha-ph": "Ranne tekstos, so tu dikkeha naal"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ro.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ro.json
index 8dd0e81f..9e4e8848 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ro.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ro.json
@@ -4,10 +4,11 @@
"Firilacroco",
"Mihai",
"Minisarm",
- "ImGelu"
+ "ImGelu",
+ "Strainu"
]
},
- "fancycaptcha-addurl": "Modificarea dumneavoastră include legături externe noi.\nPentru a împiedica roboții de spam, vă rugăm să introduceți cuvintele care apar mai jos în căsuță ([[Special:Captcha/help|mai multe detalii]]):",
+ "fancycaptcha-addurl": "Modificarea dumneavoastră include legături externe noi.\nPentru a împiedica roboții de spam, vă rugăm să introduceți cuvintele care apar în căsuță ([[Special:Captcha/help|mai multe detalii]]):",
"fancycaptcha-badlogin": "Pentru a împiedica spargerea automată a parolelor, vă rugăm să introduceți cuvintele care apar mai jos în căsuță ([[Special:Captcha/help|mai multe detalii]]):",
"fancycaptcha-captcha": "Verificare de securitate",
"fancycaptcha-accountcreate": "Pentru a împiedica crearea automată de conturi, vă rugăm să introduceți cuvintele care apar mai jos în căsuță ([[Special:Captcha/help|mai multe detalii]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rup.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rup.json
new file mode 100644
index 00000000..bde6ff13
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/rup.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Duchimie (provâ) di securitati",
+ "fancycaptcha-imgcaptcha-ph": "Bagâ lu textu pi cari lu vedz disuprâ"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sah.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sah.json
index 973be340..e5426ce6 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sah.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sah.json
@@ -5,7 +5,7 @@
]
},
"fancycaptcha-addurl": "Эн көннөрүүҥ тас ыйынньыктаах эбит. Спаамтан көмүскэнэр соруктаах дьайыыны оҥор, манна баар тыллары хатылаа ([[Special:Captcha/help|сиһилии…]]):",
- "fancycaptcha-badlogin": "Киирии тылы аптамаатынан алдьатыыттан көмүскэнэр дьайыыны оҥороргор көрдөһөбүт, манна ойууламмыт буукубалары хатылаа ([[Special:Captcha/help|сиһилии]]):",
+ "fancycaptcha-badlogin": "Аһарыгы аптамаатынан алдьатыыттан көмүскэнэр дьайыыны оҥороргор көрдөһөбүт, манна ойууламмыт буукубалары хатылаа ([[Special:Captcha/help|сиһилии]]):",
"fancycaptcha-captcha": "Куттал суох буолуутун тургутуу",
"fancycaptcha-accountcreate": "Ааттары аптамаатынан бэлиэтиири суох оҥорор туһуттан, аллара көстөр тыллары хатылаа \n([[Special:Captcha/help|сиһилии]]):",
"fancycaptcha-create": "Эн көннөрүүҥ тас ыйынньыктардаах эбит. Спаамтан көмүскэнэр туһуттан манна баар тыллары хатылыыргар көрдөһөбүт ([[Special:Captcha/help|сиһилии…]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sat.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sat.json
index 2651916a..818bcdb2 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sat.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sat.json
@@ -1,10 +1,13 @@
{
"@metadata": {
"authors": [
- "Albinus"
+ "Albinus",
+ "Ramjit Tudu",
+ "Manik Soren"
]
},
- "fancycaptcha-captcha": "Security biḍao",
- "fancycaptcha-imgcaptcha-ph": "Chubire okaṭakem ńelńamet́kan ona olme",
- "fancycaptcha-reload-text": "Phạryạo"
+ "fancycaptcha-captcha": "ᱥᱤᱠᱤᱣᱨᱤᱴᱤ ᱵᱤᱰᱟᱹᱣ",
+ "fancycaptcha-accountcreate": "ᱟᱡᱛᱮ ᱠᱷᱟᱛᱟ ᱛᱮᱭᱟᱨ ᱠᱷᱚᱱ ᱣᱤᱠᱤ ᱵᱟᱧᱪᱟᱣ ᱞᱟᱹᱜᱤᱫᱛᱮ, ᱞᱟᱛᱟᱨ ᱨᱮ ᱧᱮᱞᱚᱜ-ᱠᱟᱱ ᱵᱟᱠᱥᱟ ᱨᱮᱱᱟᱜ ᱚᱞ ᱟᱫᱮᱨ ᱞᱟᱹᱜᱤᱫ ᱞᱮ ᱱᱮᱦᱚᱸᱨᱮᱫ ᱢᱮᱭᱟ ([[Special:Captcha/help|ᱵᱟᱹᱲᱛᱤ ᱠᱟᱛᱷᱟ]]):",
+ "fancycaptcha-imgcaptcha-ph": "ᱪᱤᱛᱟᱹᱨᱨᱮ ᱡᱟᱸᱦᱟᱸᱢ ᱧᱮᱞ ᱫᱟ ᱚᱱᱟ ᱚᱞ ᱢᱮ",
+ "fancycaptcha-reload-text": "ᱯᱷᱟᱨᱱᱟᱣ"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sc.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sc.json
new file mode 100644
index 00000000..d52ca045
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sc.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Còmpudu de siguresa",
+ "fancycaptcha-imgcaptcha-ph": "Inseri su testu chi ses bidende in artu"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ses.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ses.json
new file mode 100644
index 00000000..18dbbf38
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/ses.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Saajaw korošiyan",
+ "fancycaptcha-imgcaptcha-ph": "Hantumoo kaŋ war ga dii y'a beene dam"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/so.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/so.json
index 24dc1637..c397c1ba 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/so.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/so.json
@@ -4,5 +4,7 @@
"Abshirdheere"
]
},
- "fancycaptcha-accountcreate": "Si aad u caawiso dhowritaanka in la iska samaysto Akoon,Fadlan meelaha banaan buux buuxi ee hoostaan ah ([[Special:Captcha/help|Macluumaad dheeraad ah]]):"
+ "fancycaptcha-captcha": "Hubin amni",
+ "fancycaptcha-accountcreate": "Si aad u caawiso dhowritaanka in la iska samaysto Akoon,Fadlan meelaha banaan buux buuxi ee hoostaan ah ([[Special:Captcha/help|Macluumaad dheeraad ah]]):",
+ "fancycaptcha-imgcaptcha-ph": "Gali qoraalka aad kor ku aragto"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sw.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sw.json
new file mode 100644
index 00000000..8020a1b2
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/sw.json
@@ -0,0 +1,5 @@
+{
+ "@metadata": [],
+ "fancycaptcha-captcha": "Kuangalia usalama",
+ "fancycaptcha-imgcaptcha-ph": "Ingiza maandishi unayoyaona hapo juu"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/tl.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/tl.json
index 5afb6bd5..898bd518 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/tl.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/tl.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "AnakngAraw"
+ "AnakngAraw",
+ "LR Guanzon"
]
},
"fancycaptcha-desc": "Kaakit-akit na panlikha ng CAPTCHA para sa Pagtiyak ng Pagbago",
@@ -11,6 +12,6 @@
"fancycaptcha-accountcreate": "Upang makatulong sa pagsasanggalang laban sa kusang paglikha ng kuwenta/akawnt, pakilagay lamang ang mga salitang lumitaw sa ibaba patungo sa loob ng kahon ([[Special:Captcha/help|mas marami pang kabatiran]]):",
"fancycaptcha-create": "Upang malikha ang pahina, pakilagay lamang ang mga salitang lumitaw sa ibaba patungo sa loob ng kahon ([[Special:Captcha/help|mas marami pang kabatiran]]):",
"fancycaptcha-edit": "Upang mabago ang pahinang ito, pakilagay lamang ang mga salitang lumitaw sa ibaba patungo sa loob ng kahon ([[Special:Captcha/help|mas marami pang kabatiran]]):",
- "fancycaptcha-imgcaptcha-ph": "Ilagay ang tekstong makikita sa itaas.",
+ "fancycaptcha-imgcaptcha-ph": "Ilagay ang tekstong makikita sa litrato.",
"fancycaptcha-sendemail": "Upang makatulong sa pagsasanggalang laban sa mga kusang pagsalakay ng ispam, pakilagay lamang ang mga salitang lumilitaw sa ibaba sa loob ng kahong ([[Special:Captcha/help|marami pang kabatiran]]):"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/uz.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/uz.json
index 4d7e1745..d27e9236 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/uz.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/uz.json
@@ -4,5 +4,7 @@
"Sociologist"
]
},
+ "fancycaptcha-captcha": "Xavfsizlik tekshiruvi",
+ "fancycaptcha-imgcaptcha-ph": "Yuqoridagi yozuvni bu yerga kiriting",
"fancycaptcha-reload-text": "Yangilash"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/wa.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/wa.json
index cee58533..e5545b79 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/wa.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/wa.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Srtxg"
+ "Srtxg",
+ "Reptilien.19831209BE1"
]
},
"fancycaptcha-addurl": "Dins vos candjmints i gn a des dfoûtrinnès hårdêyes (URL).\nPo mete li wiki a houte des robots di spam, nos vs dimandans d' bén vleur acertiner ki vos estoz bén ene djin, po çoula tapez les mots k' aparexhèt chal pa dzo ([[Special:Captcha/help|pus di racsegnes]]):",
@@ -10,7 +11,7 @@
"fancycaptcha-accountcreate": "Po mete li wiki a houte des robots k' ahivèt des contes otomaticmint, nos vs dimandans d' bén vleur acertiner ki vos estoz bén ene djin, po çoula tapez les mots k' aparexhèt chal pa dzo ([[Special:Captcha/help|pus di racsegnes]]):",
"fancycaptcha-create": "Por vos poleur ahiver l' pådje, vos dvoz taper les mots k' aparexhèt e l' boesse chal pa dzo ([[Special:Captcha/help|pus di racsegnes]]):",
"fancycaptcha-edit": "Po candjî cisse pådje ci, vos dvoz taper les mots k' aparexhèt e l' boesse chal pa dzo ([[Special:Captcha/help|pus di racsegnes]]):",
- "fancycaptcha-imgcaptcha-ph": "Tapez l' tecse ki vos veyoz chal å dzeur",
+ "fancycaptcha-imgcaptcha-ph": "Tapez l' tecse ki vos veyoz so l' imådje",
"fancycaptcha-sendemail": "Po s' mete a houte des robots di spam, nos vs dimandans d' acertiner ki vos estoz bén ene djin, po çoula tapez les mots k' aparexhèt chal pa dzo ([[Special:Captcha/help|pus di racsegnes]]):",
"fancycaptcha-reload-text": "Rafrister",
"apihelp-fancycaptchareload-description": "Vey èn ôte FancyCaptcha.",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zgh.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zgh.json
new file mode 100644
index 00000000..7749dce1
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zgh.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Brahim-essaidi"
+ ]
+ },
+ "fancycaptcha-imgcaptcha-ph": "ⴰⵔⴰ ⴰⴹⵔⵉⵚ ⴷⴰ ⵜⵥⵔⵔⴰⴷ ⴳ ⵜⵡⵍⴰⴼⵜ",
+ "fancycaptcha-reload-text": "ⵙⵎⴰⵢⵏⵓ"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hans.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hans.json
index b6c4f946..f98cb4a4 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hans.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hans.json
@@ -16,7 +16,7 @@
"fancycaptcha-create": "要创建页面,请输入下面方框中显示的文字([[Special:Captcha/help|更多信息]]):",
"fancycaptcha-edit": "要编辑该页面,请输入下面方框中显示的文字([[Special:Captcha/help|更多信息]]):",
"fancycaptcha-imgcaptcha-ph": "请输入您在图片中看见的文字",
- "fancycaptcha-sendemail": "为保护本wiki免受自动垃圾程序的破坏,我们恳请你输入下面方框中显示的文字([[Special:Captcha/help|更多信息]]):",
+ "fancycaptcha-sendemail": "为保护本wiki免受自动垃圾程序的破坏,我们恳请您输入下面方框中显示的文字([[Special:Captcha/help|更多信息]]):",
"fancycaptcha-reload-text": "刷新",
"apihelp-fancycaptchareload-description": "获得一个新的FancyCaptcha。",
"apihelp-fancycaptchareload-summary": "获得一个新的FancyCaptcha。",
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hant.json b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hant.json
index 03b2612b..5278ee4f 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hant.json
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/i18n/zh-hant.json
@@ -7,7 +7,8 @@
"Waihorace",
"Cwlin0416",
"LNDDYL",
- "Suchichi02"
+ "Suchichi02",
+ "Kly"
]
},
"fancycaptcha-addurl": "您的編輯使用了新的外部連結。\n為了防止垃圾編輯程式,我們要麻煩您輸入在下面的方框中顯示的單字 ([[Special:Captcha/help|更多資訊]]):",
@@ -20,5 +21,6 @@
"fancycaptcha-sendemail": "為了防止垃圾編輯程式,我們要麻煩您輸入在下面的方框中顯示的單字 ([[Special:Captcha/help|更多資訊]]):",
"fancycaptcha-reload-text": "重新整理",
"apihelp-fancycaptchareload-description": "取得新 FancyCaptcha。",
+ "apihelp-fancycaptchareload-summary": "取得新的 FancyCaptcha。",
"apihelp-fancycaptchareload-example-1": "取得新 FancyCaptcha。"
}
diff --git a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/resources/ext.confirmEdit.fancyCaptcha.js b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/resources/ext.confirmEdit.fancyCaptcha.js
index d047b197..689c88ec 100644
--- a/www/wiki/extensions/ConfirmEdit/FancyCaptcha/resources/ext.confirmEdit.fancyCaptcha.js
+++ b/www/wiki/extensions/ConfirmEdit/FancyCaptcha/resources/ext.confirmEdit.fancyCaptcha.js
@@ -24,9 +24,9 @@
$root.find( '[name="wpCaptchaWord"]' ).val( '' ).focus();
}
} )
- .always( function () {
- $this.removeClass( 'fancycaptcha-reload-loading' );
- } );
+ .always( function () {
+ $this.removeClass( 'fancycaptcha-reload-loading' );
+ } );
return false;
} );
diff --git a/www/wiki/extensions/ConfirmEdit/MathCaptcha/MathCaptcha.class.php b/www/wiki/extensions/ConfirmEdit/MathCaptcha/MathCaptcha.class.php
index 4ee178d9..0c7dee0a 100644
--- a/www/wiki/extensions/ConfirmEdit/MathCaptcha/MathCaptcha.class.php
+++ b/www/wiki/extensions/ConfirmEdit/MathCaptcha/MathCaptcha.class.php
@@ -15,7 +15,7 @@ class MathCaptcha extends SimpleCaptcha {
}
/**
- * @param array $resultArr
+ * @param array &$resultArr
*/
function addCaptchaAPI( &$resultArr ) {
list( $sum, $answer ) = $this->pickSum();
@@ -54,7 +54,10 @@ class MathCaptcha extends SimpleCaptcha {
return [ 'html' => $form ];
}
- /** Pick a random sum */
+ /**
+ * Pick a random sum
+ * @return array
+ */
function pickSum() {
$a = mt_rand( 0, 100 );
$b = mt_rand( 0, 10 );
@@ -64,7 +67,11 @@ class MathCaptcha extends SimpleCaptcha {
return [ $sum, $ans ];
}
- /** Fetch the math */
+ /**
+ * Fetch the math
+ * @param int $sum
+ * @return string
+ */
function fetchMath( $sum ) {
if ( class_exists( 'MathRenderer' ) ) {
$math = MathRenderer::getRenderer( $sum, [], 'png' );
@@ -98,7 +105,7 @@ class MathCaptcha extends SimpleCaptcha {
/**
* @param array $requests
* @param array $fieldInfo
- * @param array $formDescriptor
+ * @param array &$formDescriptor
* @param string $action
*/
public function onAuthChangeFormFields( array $requests, array $fieldInfo,
diff --git a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/QuestyCaptcha.class.php b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/QuestyCaptcha.class.php
index adc00bcb..95da1021 100644
--- a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/QuestyCaptcha.class.php
+++ b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/QuestyCaptcha.class.php
@@ -30,7 +30,7 @@ class QuestyCaptcha extends SimpleCaptcha {
}
/**
- * @param array $resultArr
+ * @param array &$resultArr
*/
function addCaptchaAPI( &$resultArr ) {
$captcha = $this->getCaptcha();
@@ -117,7 +117,7 @@ class QuestyCaptcha extends SimpleCaptcha {
/**
* @param array $requests
* @param array $fieldInfo
- * @param array $formDescriptor
+ * @param array &$formDescriptor
* @param string $action
*/
public function onAuthChangeFormFields( array $requests, array $fieldInfo,
diff --git a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/cs.json b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/cs.json
index 889591b1..7ebe2e95 100644
--- a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/cs.json
+++ b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/cs.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Mormegil"
+ "Mormegil",
+ "Ilimanaq29"
]
},
"questycaptcha-addurl": "Vaše editace obsahuje nové externí odkazy.\nV zájmu ochrany této wiki před automatickým spamováním vás prosíme o zodpovězení níže uvedené otázky ([[Special:Captcha/help|další informace]]):",
@@ -10,5 +11,5 @@
"questycaptcha-create": "Abyste mohli založit stránku, musíte zodpovědět níže uvedenou otázku ([[Special:Captcha/help|další informace]]):",
"questycaptcha-edit": "Abyste mohli editovat tuto stránku, musíte zodpovědět níže uvedenou otázku ([[Special:Captcha/help|další informace]]):",
"questycaptcha-sendemail": "V zájmu ochrany této wiki před automatickým spamováním vás prosíme o zodpovězení níže uvedené otázky ([[Special:Captcha/help|další informace]]):",
- "questycaptchahelp-text": "Webové stránky, do kterých mohou přispívat jejich návštěvníci (jako například tato wiki), jsou často terčem spammerů, kteří pomocí automatických nástrojů vkládají své odkazy na velké množství stránek. Přestože lze tento spam odstranit, představuje nepříjemné obtěžování.\n\nNěkdy, zvláště při přidávání nových webových odkazů, vás wiki může požádat o zodpovězení otázky.\nJelikož takovou úlohu lze jen těžko automatizovat, skuteční lidé mohou dále přispívat, zatímco většinu spammerů a jiných robotických útočníků to zastaví.\n\nPokud vám to brání v užitečných příspěvcích a potřebujete pomoc, kontaktujte laskavě [[Special:ListAdmins|správce serveru]].\n\nPro návrat na předchozí stránku stiskněte ve svém prohlížeči tlačítko „zpět“."
+ "questycaptchahelp-text": "Webové stránky, do kterých mohou přispívat jejich návštěvníci (jako například tato wiki), jsou často terčem spammerů, kteří pomocí automatických nástrojů vkládají své odkazy na velké množství stránek. Přestože lze tento spam odstranit, představuje nepříjemné obtěžování.\n\nNěkdy, zvláště při přidávání nových webových odkazů, vás wiki může požádat o zodpovězení otázky.\nJelikož takovou úlohu lze jen těžko automatizovat, skuteční lidé mohou dále přispívat, zatímco většinu spammerů a jiných robotických útočníků to zastaví.\n\nPokud vám to brání v užitečných příspěvcích a potřebujete pomoc, kontaktujte prosím [[Special:ListAdmins|správce serveru]].\n\nPro návrat na předchozí stránku stiskněte ve svém prohlížeči tlačítko „zpět“."
}
diff --git a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/io.json b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/io.json
new file mode 100644
index 00000000..577b8d7c
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/io.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joao Xavier"
+ ]
+ },
+ "questycaptchahelp-text": "Pagini de l'interreto qui aceptas kontributaji del publiko, exemple ica Wiki, freque atakesas dal 'spammers', qui uzas programachi por komputeri qui adjuntas lia ligili a multa retpagini.\nMalgre ke la ligili 'spam' povas efacesar, li esas signifikiva jeno.\n\nKelkafoye, note kande vu adjuntos nova interretala ligili en ula pagino, la Wiki povos questionar vu.\nPro ke esas nefacila automatigar la respondi a la questioni, la questionado impedos la maxim multa ataki da 'spammers' ed altra automatala ataki, dum ke ol permisos la maxim multa homi kontributar.\n\nVoluntez demandar helpo del [[Special:ListAdmins|administreri di ca Wiki]] se ca procedo impedus vu sendor vua yusta kontributaji.\n\nKliktez la butono \"retroirar\" (\"back\") de vua retnavigilo por retroirar a la redakto-pagino."
+}
diff --git a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/lb.json b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/lb.json
index d14cdb40..d2a81535 100644
--- a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/lb.json
+++ b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/lb.json
@@ -12,5 +12,5 @@
"questycaptcha-create": "Fir d'Säit unzeleeën, beäntwert w.e.g. déi Fro hei ënnedrënner ([[Special:Captcha/help|méi Informatiounen]]):",
"questycaptcha-edit": "Fir dës Säit z'änneren, beäntwert w.e.g. déi Fro hei ënnedrënner ([[Special:Captcha/help|méi Informatiounen]]):",
"questycaptcha-sendemail": "Fir ze hëllefe dës Wiki géint automatiséierte Spam ze schütze, beäntwert w.e.g. déi Fro hei ënnendrënner ([[Special:Captcha/help|méi Informatiounen]]):",
- "questycaptchahelp-text": "Websäiten, déi et jiddwerengem erlaben Ännerunge virzehuelen, sou wéi dës Wiki, ginn dacks vu sougenannte Spammer mëssbraucht, déi automatiséiert hir Linken op vill Internetsäite setzen.\nSou Spam-Linke kënne wuel geläscht ginn, mä si sinn trotzdeem eng grouss Plo.\n\nHeiansdo, besonnesch wann nei Internet-Linken op eng Säit derbäigesat ginn, freet dës Wiki Iech eng Fro ze beäntwerten.\nWell dëst eng Aufgab ass déi schwéier z'automatiséieren ass, erlaabt dëst datt Mënschen hir Ännerunge kënnen agi während déi meescht Spammer an aner Roboter-Attacke kënnen ofgewiert ginn.\n\nKontaktéiert w.e.g. d'[[Special:ListAdmins|Administrateure vun dësem Site]] fir Hëllef wann dëst Iech onerwaarter Weis vu legitimen Editen ofhält.\n\nDréckt op den 'Zréck' Knäppche vun ärem Browser fir an d'Beaarbechtungsfënster zréckzekommen."
+ "questycaptchahelp-text": "Websäiten, déi et jiddwerengem erlaben Ännerunge virzehuelen, sou wéi dës Wiki, ginn dacks vu sougenannte Spammer mëssbraucht, déi automatiséiert hir Linken op vill Internetsäite setzen.\nSou Spam-Linke kënne wuel geläscht ginn, mä si sinn trotzdeem eng grouss Plo.\n\nHeiansdo, besonnesch wann nei Internet-Linken op eng Säit dobäigesat ginn, freet dës Wiki Iech eng Fro ze beäntwerten.\nWell dëst eng Aufgab ass déi schwéier z'automatiséieren ass, erlaabt dëst datt Mënschen hir Ännerunge kënnen agi während déi meescht Spammer an aner Roboter-Attacke kënnen ofgewiert ginn.\n\nKontaktéiert w.e.g. d'[[Special:ListAdmins|Administrateure vun dësem Site]] fir Hëllef wann dëst Iech onerwaarter Weis vu legitimen Editten ofhält.\n\nDréckt op den 'Zréck' Knäppche vun ärem Browser fir an d'Beaarbechtungsfënster zréckzekommen."
}
diff --git a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/pt.json b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/pt.json
index c252846f..ff1cf0c3 100644
--- a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/pt.json
+++ b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/pt.json
@@ -4,14 +4,15 @@
"Crazymadlover",
"Giro720",
"Hamilton Abreu",
- "Fúlvio"
+ "Fúlvio",
+ "Athena in Wonderland"
]
},
- "questycaptcha-addurl": "A sua edição introduziu links externos novos.\nPara proteger esta wiki contra o spam automatizado, por favor, responda à questão apresentada abaixo ([[Special:Captcha/help|mais informações]]):",
+ "questycaptcha-addurl": "A sua edição introduziu hiperligações externas novas.\nPara proteger esta wiki contra o spam automatizado, por favor, responda à questão apresentada abaixo ([[Special:Captcha/help|mais informações]]):",
"questycaptcha-badlogin": "Para proteger esta wiki contra mecanismos automatizados de descoberta de palavras-passe, por favor, responda à questão apresentada abaixo ([[Special:Captcha/help|mais informações]]):",
"questycaptcha-createaccount": "Para proteger esta wiki contra a criação de contas automatizada, por favor, responda à questão apresentada abaixo ([[Special:Captcha/help|mais informações]]):",
"questycaptcha-create": "Para criar a página, por favor, responda à questão apresentada abaixo ([[Special:Captcha/help|mais informações]]):",
"questycaptcha-edit": "Para editar esta página, por favor, responda à questão apresentada abaixo ([[Special:Captcha/help|mais informações]]):",
"questycaptcha-sendemail": "Para proteger esta wiki contra o spam automatizado, por favor, responda à seguinte pergunta ([[Special:Captcha/help|mais informações]]):",
- "questycaptchahelp-text": "Sites na internet abertos a edição pública, como é o caso desta wiki, são frequentemente abusados por ''spammers'' que utilizam ferramentas automatizadas para inserção em massa de links em muitos sites.\nEmbora esses links possam ser removidos, representam um incómodo significativo.\n\nPor vezes, especialmente quando introduzir links externos novos numa página, a wiki pedirá que responda a uma pergunta.\nPorque esta é uma tarefa difícil de automatizar, permite que a maioria das pessoas façam as suas edições, ao mesmo tempo que inibe edições feitas por ''spammers'' e outros mecanismos automatizados.\n\nPor favor, contacte os [[Special:ListAdmins|administradores]] para assistência, caso esta funcionalidade esteja a impedi-lo de fazer edições legítimas.\n\nClique o botão 'voltar' do seu browser para voltar à página de edição."
+ "questycaptchahelp-text": "Sítios na Internet abertos a edição pública, como é o caso desta wiki, são frequentemente abusados por ''spammers'' que utilizam ferramentas automatizadas para inserção em massa de hiperligações em muitos sítios.\nEmbora essas hiperligações possam ser removidas, representam um incómodo significativo.\n\nPor vezes, especialmente quando introduzir hiperligações externas novas numa página, a wiki pedirá que responda a uma pergunta.\nPorque esta é uma tarefa difícil de automatizar, permite que a maioria das pessoas façam as suas edições, ao mesmo tempo que inibe edições feitas por ''spammers'' e outros mecanismos automatizados.\n\nPor favor, contacte os [[Special:ListAdmins|administradores]] para assistência, caso esta funcionalidade esteja a impedi-lo de fazer edições legítimas.\n\nClique o botão 'voltar' do seu browser para voltar à página de edição."
}
diff --git a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/zh-hans.json b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/zh-hans.json
index f8afcf4c..c736d078 100644
--- a/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/zh-hans.json
+++ b/www/wiki/extensions/ConfirmEdit/QuestyCaptcha/i18n/zh-hans.json
@@ -11,7 +11,7 @@
"questycaptcha-desc": "用于确认编辑的问题验证码生成器",
"questycaptcha-addurl": "您的编辑包含新的外部链接。为保护本wiki免受自动垃圾程序的破坏,我们恳请您回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
"questycaptcha-badlogin": "为保护本wiki免受自动密码破解的破坏,我们恳请你回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
- "questycaptcha-createaccount": "为保护本wiki免受自动账户创建的破坏,我们恳请你回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
+ "questycaptcha-createaccount": "为保护本wiki免受自动账户创建的破坏,我们恳请您回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
"questycaptcha-create": "要创建页面,请回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
"questycaptcha-edit": "要编辑该页面,请回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
"questycaptcha-sendemail": "为保护本wiki免受自动垃圾程序的破坏,我们恳请您回答下面显示的问题([[Special:Captcha/help|更多信息]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptcha/ReCaptcha.class.php b/www/wiki/extensions/ConfirmEdit/ReCaptcha/ReCaptcha.class.php
index e2b22ade..a62633e0 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptcha/ReCaptcha.class.php
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptcha/ReCaptcha.class.php
@@ -13,6 +13,8 @@ class ReCaptcha extends SimpleCaptcha {
/**
* Displays the reCAPTCHA widget.
* If $this->recaptcha_error is set, it will display an error in the widget.
+ * @param int $tabIndex
+ * @return array
*/
function getFormInformation( $tabIndex = 1 ) {
global $wgReCaptchaPublicKey, $wgReCaptchaTheme;
@@ -72,7 +74,7 @@ class ReCaptcha extends SimpleCaptcha {
}
/**
- * @param array $resultArr
+ * @param array &$resultArr
*/
function addCaptchaAPI( &$resultArr ) {
$resultArr['captcha'] = $this->describeCaptchaType();
@@ -92,8 +94,8 @@ class ReCaptcha extends SimpleCaptcha {
}
/**
- * @param ApiBase $module
- * @param array $params
+ * @param ApiBase &$module
+ * @param array &$params
* @param int $flags
* @return bool
*/
@@ -159,7 +161,7 @@ class ReCaptcha extends SimpleCaptcha {
/**
* @param array $requests
* @param array $fieldInfo
- * @param array $formDescriptor
+ * @param array &$formDescriptor
* @param string $action
*/
public function onAuthChangeFormFields(
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/ja.json b/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/ja.json
index ceb0cac2..62a3a22f 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/ja.json
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/ja.json
@@ -3,7 +3,8 @@
"authors": [
"Shirayuki",
"Otokoume",
- "ネイ"
+ "ネイ",
+ "Yusuke1109"
]
},
"recaptcha-desc": "Confirm Edit 用 reCAPTCHA モジュール",
@@ -12,5 +13,8 @@
"recaptcha-badlogin": "ウィキへの自動パスワードクラック攻撃を防ぐため、お手数をおかけしますが画像に表示されている単語を入力してください。",
"recaptcha-createaccount": "ウィキでのアカウント自動作成を防ぐため、お手数をおかけしますが画像に表示されている単語を入力してください。",
"recaptcha-createaccount-fail": "文字列が正しくない、または入力されていません。",
- "recaptcha-create": "ウィキでのページの自動作成を防ぐため、お手数をおかけしますが画像に表示されている単語を入力してください。"
+ "recaptcha-create": "ウィキでのページの自動作成を防ぐため、お手数をおかけしますが画像に表示されている単語を入力してください。",
+ "recaptcha-info": "ReCaptchaチャレンジを解決し、チャレンジとレスポンスの値をcaptchaIdとcaptchaWordとして返してください。",
+ "recaptcha-apihelp-param-recaptcha_challenge_field": "ReCaptchaウィジェットのフィールド",
+ "recaptcha-apihelp-param-recaptcha_response_field": "ReCaptchaウィジェットのフィールド"
}
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hans.json b/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hans.json
index fb3d80a0..b5e074d2 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hans.json
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hans.json
@@ -8,12 +8,12 @@
]
},
"recaptcha-desc": "用于确认编辑的reCAPTCHA模块",
- "recaptcha-edit": "为了避免垃圾用户自动编辑,请键入框中的单词。",
- "recaptcha-addurl": "您的编辑包含新的外部链接。为了避免垃圾用户自动编辑,请键入框中的单词。",
- "recaptcha-badlogin": "为避免自动密码破解,请键入框中的单词。",
- "recaptcha-createaccount": "为了避免创建自动垃圾用户,请键入框中的单词。",
+ "recaptcha-edit": "为了避免垃圾用户自动编辑,我们恳请您输入在框中看到的字词。",
+ "recaptcha-addurl": "您的编辑包含新的外部链接。为了避免垃圾用户自动编辑,我们恳请您输入框中看到的字词。",
+ "recaptcha-badlogin": "为避免自动密码破解,我们恳请您输入框中看到的字词。",
+ "recaptcha-createaccount": "为了避免创建自动垃圾用户,我们恳请您输入在框中看到的字词。",
"recaptcha-createaccount-fail": "reCAPTCHA 答案不正确或未填写。",
- "recaptcha-create": "为了避免垃圾用户自动创建页面,请键入框中的单词。",
+ "recaptcha-create": "为了避免垃圾用户自动创建页面,我们恳请您输入在框中看到的字词。",
"recaptcha-info": "请解决ReCaptcha挑战,返回挑战并将值作为验证码ID和验证码文字回应。",
"recaptcha-apihelp-param-recaptcha_challenge_field": "来自ReCaptcha小部件的字段",
"recaptcha-apihelp-param-recaptcha_response_field": "来自ReCaptcha小部件的字段",
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hant.json b/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hant.json
index edb0031f..ee21e120 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hant.json
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptcha/i18n/zh-hant.json
@@ -4,13 +4,21 @@
"StephDC",
"Cwlin0416",
"Suchichi02",
- "Liuxinyu970226"
+ "Liuxinyu970226",
+ "Kly"
]
},
- "recaptcha-edit": "為了防止垃圾編輯程式,我們要麻煩您輸入在方塊中顯示的單字。",
- "recaptcha-addurl": "您的編輯使用了新的外部連結。為了防止垃圾編輯程式,我們要麻煩您輸入在方塊中顯示的單字。",
- "recaptcha-badlogin": "為了防止密碼破解程式,我們要麻煩您輸入在方塊中顯示的單字。",
- "recaptcha-createaccount": "為了防止自動註冊程式,我們要麻煩您輸入在方塊中顯示的單字。",
- "recaptcha-createaccount-fail": "不正確或者未輸入 reCAPTCHA 回答。",
- "recaptcha-create": "為了防止自動建立頁面程式,我們要麻煩您輸入在方塊中顯示的單字。"
+ "recaptcha-edit": "為保護 wiki 防止自動化垃圾內容編輯程式,我們要麻煩您輸入在方塊中顯示的單字。",
+ "recaptcha-addurl": "您的編輯使用了新的外部連結。為了防止自動化垃圾內容編輯程式,我們要麻煩您輸入在方塊中顯示的單字。",
+ "recaptcha-badlogin": "為保護 wiki 防止密碼破解程式,我們要麻煩您輸入在方塊中顯示的單字。",
+ "recaptcha-createaccount": "為保護 wiki 防止自動註冊程式,我們要麻煩您輸入在方塊中顯示的單字。",
+ "recaptcha-createaccount-fail": "不正確或者未輸入 reCAPTCHA 答案。",
+ "recaptcha-create": "為了防止自動建立頁面程式,我們要麻煩您輸入在方塊中顯示的單字。",
+ "recaptcha-info": "請解決 ReCaptcha 的盤問,並回傳作為驗證碼 ID、驗證碼文字的盤問值與回應值。",
+ "recaptcha-apihelp-param-recaptcha_challenge_field": "自 ReCaptcha 小工具的欄位",
+ "recaptcha-apihelp-param-recaptcha_response_field": "自 ReCaptcha 小工具的欄位",
+ "recaptcha-id-label": "ReCaptcha 盤問",
+ "recaptcha-id-help": "ReCaptcha 盤問值",
+ "recaptcha-label": "ReCaptcha 處理",
+ "recaptcha-help": "ReCaptcha 處理值"
}
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/ReCaptchaNoCaptcha.class.php b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/ReCaptchaNoCaptcha.class.php
index 15e1c108..19aa1093 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/ReCaptchaNoCaptcha.class.php
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/ReCaptchaNoCaptcha.class.php
@@ -10,6 +10,7 @@ class ReCaptchaNoCaptcha extends SimpleCaptcha {
private $error = null;
/**
* Get the captcha form.
+ * @param int $tabIndex
* @return array
*/
function getFormInformation( $tabIndex = 1 ) {
@@ -59,7 +60,7 @@ HTML;
}
/**
- * @param $info
+ * @param Status|array|string $info
*/
protected function logCheckError( $info ) {
if ( $info instanceof Status ) {
@@ -91,8 +92,8 @@ HTML;
* Based on reference implementation:
* https://github.com/google/recaptcha#php
*
- * @param $_ mixed Not used (ReCaptcha v2 puts index and solution in a single string)
- * @param $word string captcha solution
+ * @param mixed $_ Not used (ReCaptcha v2 puts index and solution in a single string)
+ * @param string $word captcha solution
* @return bool
*/
function passCaptcha( $_, $word ) {
@@ -131,7 +132,7 @@ HTML;
}
/**
- * @param array $resultArr
+ * @param array &$resultArr
*/
function addCaptchaAPI( &$resultArr ) {
$resultArr['captcha'] = $this->describeCaptchaType();
@@ -154,7 +155,7 @@ HTML;
* Show a message asking the user to enter a captcha on edit
* The result will be treated as wiki text
*
- * @param $action string Action being performed
+ * @param string $action Action being performed
* @return string Wikitext
*/
public function getMessage( $action ) {
@@ -166,8 +167,8 @@ HTML;
}
/**
- * @param ApiBase $module
- * @param array $params
+ * @param ApiBase &$module
+ * @param array &$params
* @param int $flags
* @return bool
*/
@@ -220,7 +221,7 @@ HTML;
/**
* @param array $requests
* @param array $fieldInfo
- * @param array $formDescriptor
+ * @param array &$formDescriptor
* @param string $action
*/
public function onAuthChangeFormFields(
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/pt-br.json b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/pt-br.json
new file mode 100644
index 00000000..eddee511
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/pt-br.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eduardo Addad de Oliveira"
+ ]
+ },
+ "renocaptcha-edit": "Para proteger a wiki contra a edição automatizada de spam, pedimos gentilmente que resolva o seguinte código CAPTCHA:",
+ "renocaptcha-addurl": "A sua edição inclui novas ligações externas. Para proteger a wiki contra o spam automático, pedimos gentilmente que resolva o seguinte código CAPTCHA:",
+ "renocaptcha-badlogin": "Para proteger a wiki da quebra de senha automatizada, pedimos que resolva o seguinte CAPTCHA:",
+ "renocaptcha-createaccount": "Para proteger a wiki contra a criação automatizada de conta, pedimos que resolva o seguinte código CAPTCHA:",
+ "renocaptcha-createaccount-fail": "Parece que não resolveu o código CAPTCHA ainda.",
+ "renocaptcha-create": "Para proteger a wiki contra a criação automatizada de páginas novas, pedimos que resolva o seguinte código CAPTCHA:",
+ "renocaptcha-noscript": "Infelizmente desativou o JavaScript, o que nos impossibilita de reconhecer automaticamente se é um humano ou não. Por favor, resolva o código CAPTCHA abaixo e copie o resultado para o campo de texto seguinte:",
+ "renocaptcha-help": "Resolva um desafio ReCaptcha NoCaptcha e devolva o valor da resposta como captchaWord.",
+ "renocaptcha-apihelp-param-g-recaptcha-response": "Campo do <i>widget</i> ReCaptcha."
+}
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/qqq.json b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/qqq.json
index b3119abb..cf0c6cc0 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/qqq.json
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/qqq.json
@@ -1,11 +1,15 @@
{
- "@metadata": [],
- "renocaptcha-edit": "Message above the CAPTCHA for edit action.",
- "renocaptcha-addurl": "Message above the CAPTCHA for addurl (user added new external links to the page) action.",
- "renocaptcha-badlogin": "Message above the CAPTCHA for badlogin action.",
- "renocaptcha-createaccount": "Message above the CAPTCHA for createaccount (user creates a new account) action.",
- "renocaptcha-createaccount-fail": "Error message, when the CAPTCHA isn't solved correctly.",
- "renocaptcha-create": "Message above the CAPTCHA for create (user creates a new page) action.",
+ "@metadata": {
+ "authors": [
+ "Liuxinyu970226"
+ ]
+ },
+ "renocaptcha-edit": "Message above the CAPTCHA for edit action.\n{{related|ConfirmEdit-edit}}",
+ "renocaptcha-addurl": "Message above the CAPTCHA for addurl (user added new external links to the page) action.\n{{related|ConfirmEdit-addurl}}",
+ "renocaptcha-badlogin": "Message above the CAPTCHA for badlogin action.\n{{related|ConfirmEdit-badlogin}}",
+ "renocaptcha-createaccount": "Message above the CAPTCHA for createaccount (user creates a new account) action.\n{{related|ConfirmEdit-createaccount}}",
+ "renocaptcha-createaccount-fail": "Error message, when the CAPTCHA isn't solved correctly.\n{{related|ConfirmEdit-createaccount-fail}}",
+ "renocaptcha-create": "Message above the CAPTCHA for create (user creates a new page) action.\n{{related|ConfirmEdit-create}}",
"renocaptcha-noscript": "This messages is warning you have javascript disabled so you have to manualy input the text into the textbox.",
"renocaptcha-help": "Explanation of how to solve the CAPTCHA for API clients.",
"renocaptcha-apihelp-param-g-recaptcha-response": "{{doc-apihelp-param|description=the \"g-recaptcha-response\" parameter added by [[mw:Extension:ConfirmEdit]]|noseealso=1}}"
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hans.json b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hans.json
index 09bee790..557d77cd 100644
--- a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hans.json
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hans.json
@@ -4,12 +4,12 @@
"Liuxinyu970226"
]
},
- "renocaptcha-edit": "为保护wiki免于自动化编辑破坏,我们希望您输入下面的验证码:",
- "renocaptcha-addurl": "您的编辑包含新的外部链接。为保护wiki免于自动化破坏,我们希望您输入下面的验证码:",
+ "renocaptcha-edit": "为保护wiki免于自动化编辑破坏,我们恳请您输入下面的验证码:",
+ "renocaptcha-addurl": "您的编辑包含新的外部链接。为保护wiki免于自动化破坏,我们恳请您输入下面的验证码:",
"renocaptcha-badlogin": "为保护wiki免于自动化密码破解,我们希望您输入下面的验证码:",
- "renocaptcha-createaccount": "为保护wiki免于自动化账户创建,我们希望您输入下面的验证码:",
+ "renocaptcha-createaccount": "为保护wiki免于自动化账户创建,我们恳请您输入下面的验证码:",
"renocaptcha-createaccount-fail": "看起来您未输入正确的验证码。",
- "renocaptcha-create": "为保护wiki免于自动化页面创建,我们希望您输入下面的验证码:",
+ "renocaptcha-create": "为保护wiki免于自动化页面创建,我们恳请您输入下面的验证码:",
"renocaptcha-noscript": "不幸的是,您禁用了JavaScript,因此我们不能自动识别您是否是一个人。请识别上方的验证码,并将结果文本复制至下面的文本区域:",
"renocaptcha-help": "请识别ReCaptcha无验证码挑战,并将响应值作为验证码文本返回。",
"renocaptcha-apihelp-param-g-recaptcha-response": "来自ReCaptcha小部件的字段。"
diff --git a/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hant.json b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hant.json
new file mode 100644
index 00000000..38eb5d82
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/ReCaptchaNoCaptcha/i18n/zh-hant.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "A2093064",
+ "Kly"
+ ]
+ },
+ "renocaptcha-edit": "為保護 wiki 防止自動化垃圾內容編輯程式,我們希望您輸入下面的驗證碼:",
+ "renocaptcha-addurl": "您的編輯使用了新的外部連結。為了防止自動化垃圾內容編輯程式,我們要麻煩您輸入在下面方塊中顯示的單字。",
+ "renocaptcha-badlogin": "為保護wiki免遭自動化的密碼破解,我們希望您輸入下面的驗證碼:",
+ "renocaptcha-createaccount": "為保護 wiki 防止自動化帳號建立程式,我們希望您輸入下面的驗證碼:",
+ "renocaptcha-createaccount-fail": "看來您的驗證碼似乎不正確。",
+ "renocaptcha-create": "為保護 wiki 防止自動化頁面建立程式,我們希望您輸入下面的驗證碼:",
+ "renocaptcha-noscript": "很遺憾地,因為您停用了 JavaScript 功能,因此我們無法自動識別出您是否是非機器人的正常個人用戶。請解決上方的驗證碼,並複製結果的文字內容到以下文字方框裡:",
+ "renocaptcha-help": "請解決 ReCaptcha NoCaptcha 的盤問並回傳作為驗證碼文字的回應值。",
+ "renocaptcha-apihelp-param-g-recaptcha-response": "自 ReCaptcha 小工具的欄位。"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/SimpleCaptcha/Captcha.php b/www/wiki/extensions/ConfirmEdit/SimpleCaptcha/Captcha.php
index 84a18549..db6c583a 100644
--- a/www/wiki/extensions/ConfirmEdit/SimpleCaptcha/Captcha.php
+++ b/www/wiki/extensions/ConfirmEdit/SimpleCaptcha/Captcha.php
@@ -1,7 +1,6 @@
<?php
use MediaWiki\Auth\AuthenticationRequest;
-use MediaWiki\Logger\LoggerFactory;
/**
* Demo CAPTCHA (not for production usage) and base class for real CAPTCHAs
@@ -39,7 +38,7 @@ class SimpleCaptcha {
/**
* Return the error from the last passCaptcha* call.
* Not implemented but needed by some child classes.
- * @return
+ * @return mixed
*/
public function getError() {
return null;
@@ -67,7 +66,7 @@ class SimpleCaptcha {
}
/**
- * @param array $resultArr
+ * @param array &$resultArr
*/
function addCaptchaAPI( &$resultArr ) {
$captcha = $this->getCaptcha();
@@ -114,7 +113,7 @@ class SimpleCaptcha {
* string html - Main HTML
* array modules (optional) - Array of ResourceLoader module names
* array modulestyles (optional) - Array of ResourceLoader module names to be
- * included as style-only modules.
+ * included as style-only modules.
* array headitems (optional) - Head items (see OutputPage::addHeadItems), as a numeric array
* of raw HTML strings. Do not use unless no other option is feasible.
*/
@@ -187,8 +186,8 @@ class SimpleCaptcha {
/**
* Show error message for missing or incorrect captcha on EditPage.
- * @param EditPage $editPage
- * @param OutputPage $out
+ * @param EditPage &$editPage
+ * @param OutputPage &$out
*/
function showEditFormFields( &$editPage, &$out ) {
$page = $editPage->getArticle()->getPage();
@@ -224,7 +223,7 @@ class SimpleCaptcha {
* Show a message asking the user to enter a captcha on edit
* The result will be treated as wiki text
*
- * @param $action string Action being performed
+ * @param string $action Action being performed
* @return Message
*/
public function getMessage( $action ) {
@@ -240,14 +239,13 @@ class SimpleCaptcha {
/**
* Inject whazawhoo
* @fixme if multiple thingies insert a header, could break
- * @param $form HTMLForm
+ * @param HTMLForm &$form
* @return bool true to keep running callbacks
*/
function injectEmailUser( &$form ) {
- global $wgCaptchaTriggers;
$out = $form->getOutput();
$user = $form->getUser();
- if ( $wgCaptchaTriggers['sendemail'] ) {
+ if ( $this->triggersCaptcha( CaptchaTriggers::SENDEMAIL ) ) {
$this->action = 'sendemail';
if ( $user->isAllowed( 'skipcaptcha' ) ) {
wfDebug( "ConfirmEdit: user group allows skipping captcha on email sending\n" );
@@ -273,11 +271,11 @@ class SimpleCaptcha {
* TODO use Throttler
*/
public function increaseBadLoginCounter( $username ) {
- global $wgCaptchaTriggers, $wgCaptchaBadLoginExpiration,
- $wgCaptchaBadLoginPerUserExpiration;
+ global $wgCaptchaBadLoginExpiration, $wgCaptchaBadLoginPerUserExpiration;
+
$cache = ObjectCache::getLocalClusterInstance();
- if ( $wgCaptchaTriggers['badlogin'] ) {
+ if ( $this->triggersCaptcha( CaptchaTriggers::BAD_LOGIN ) ) {
$key = $this->badLoginKey();
$count = ObjectCache::getLocalClusterInstance()->get( $key );
if ( !$count ) {
@@ -287,7 +285,7 @@ class SimpleCaptcha {
$cache->incr( $key );
}
- if ( $wgCaptchaTriggers['badloginperuser'] && $username ) {
+ if ( $this->triggersCaptcha( CaptchaTriggers::BAD_LOGIN_PER_USER ) && $username ) {
$key = $this->badLoginPerUserKey( $username );
$count = $cache->get( $key );
if ( !$count ) {
@@ -303,9 +301,7 @@ class SimpleCaptcha {
* @param string $username
*/
public function resetBadLoginCounter( $username ) {
- global $wgCaptchaTriggers;
-
- if ( $wgCaptchaTriggers['badloginperuser'] && $username ) {
+ if ( $this->triggersCaptcha( CaptchaTriggers::BAD_LOGIN_PER_USER ) && $username ) {
$cache = ObjectCache::getLocalClusterInstance();
$cache->delete( $this->badLoginPerUserKey( $username ) );
}
@@ -318,26 +314,28 @@ class SimpleCaptcha {
* @access private
*/
public function isBadLoginTriggered() {
- global $wgCaptchaTriggers, $wgCaptchaBadLoginAttempts;
+ global $wgCaptchaBadLoginAttempts;
+
$cache = ObjectCache::getLocalClusterInstance();
- return $wgCaptchaTriggers['badlogin']
+ return $this->triggersCaptcha( CaptchaTriggers::BAD_LOGIN )
&& (int)$cache->get( $this->badLoginKey() ) >= $wgCaptchaBadLoginAttempts;
}
/**
* Is the per-user captcha triggered?
*
- * @param $u User|String User object, or name
+ * @param User|string $u User object, or name
* @return bool|null False: no, null: no, but it will be triggered next time
*/
public function isBadLoginPerUserTriggered( $u ) {
- global $wgCaptchaTriggers, $wgCaptchaBadLoginPerUserAttempts;
+ global $wgCaptchaBadLoginPerUserAttempts;
+
$cache = ObjectCache::getLocalClusterInstance();
if ( is_object( $u ) ) {
$u = $u->getName();
}
- return $wgCaptchaTriggers['badloginperuser']
+ return $this->triggersCaptcha( CaptchaTriggers::BAD_LOGIN_PER_USER )
&& (int)$cache->get( $this->badLoginPerUserKey( $u ) ) >= $wgCaptchaBadLoginPerUserAttempts;
}
@@ -466,23 +464,53 @@ class SimpleCaptcha {
* @param Title $title
* @param string $action (edit/create/addurl...)
* @return bool true if action triggers captcha on $title's namespace
+ * @deprecated since 1.5.1 Use triggersCaptcha instead
+ */
+ public function captchaTriggers( $title, $action ) {
+ return $this->triggersCaptcha( $action, $title );
+ }
+
+ /**
+ * Checks, whether the passed action should trigger a CAPTCHA. The optional $title parameter
+ * will be used to check namespace specific CAPTCHA triggers.
+ *
+ * @param string $action The CAPTCHA trigger to check (see CaptchaTriggers for ConfirmEdit
+ * built-in triggers)
+ * @param Title|null $title An optional Title object, if the namespace specific triggers
+ * should be checked, too.
+ * @return bool True, if the action should trigger a CAPTCHA, false otherwise
*/
- function captchaTriggers( $title, $action ) {
+ public function triggersCaptcha( $action, $title = null ) {
global $wgCaptchaTriggers, $wgCaptchaTriggersOnNamespace;
- // Special config for this NS?
- if ( isset( $wgCaptchaTriggersOnNamespace[$title->getNamespace()][$action] ) ) {
- return $wgCaptchaTriggersOnNamespace[$title->getNamespace()][$action];
+
+ $result = false;
+ $triggers = $wgCaptchaTriggers;
+ $attributeCaptchaTriggers = ExtensionRegistry::getInstance()
+ ->getAttribute( CaptchaTriggers::EXT_REG_ATTRIBUTE_NAME );
+ if ( is_array( $attributeCaptchaTriggers ) ) {
+ $triggers += $attributeCaptchaTriggers;
}
- return ( !empty( $wgCaptchaTriggers[$action] ) ); // Default
+ if ( isset( $triggers[$action] ) ) {
+ $result = $triggers[$action];
+ }
+
+ if (
+ $title !== null &&
+ isset( $wgCaptchaTriggersOnNamespace[$title->getNamespace()][$action] )
+ ) {
+ $result = $wgCaptchaTriggersOnNamespace[$title->getNamespace()][$action];
+ }
+
+ return $result;
}
/**
* @param WikiPage $page
- * @param $content Content|string
- * @param $section string
+ * @param Content|string $content
+ * @param string $section
* @param IContextSource $context
- * @param oldtext string The content of the revision prior to $content When
+ * @param string $oldtext The content of the revision prior to $content When
* null this will be loaded from the database.
* @return bool true if the captcha should run
*/
@@ -523,7 +551,7 @@ class SimpleCaptcha {
$isEmpty = $content === '';
}
- if ( $this->captchaTriggers( $title, 'edit' ) ) {
+ if ( $this->triggersCaptcha( 'edit', $title ) ) {
// Check on all edits
$this->trigger = sprintf( "edit trigger by '%s' at [[%s]]",
$user->getName(),
@@ -533,7 +561,7 @@ class SimpleCaptcha {
return true;
}
- if ( $this->captchaTriggers( $title, 'create' ) && !$title->exists() ) {
+ if ( $this->triggersCaptcha( 'create', $title ) && !$title->exists() ) {
// Check if creating a page
$this->trigger = sprintf( "Create trigger by '%s' at [[%s]]",
$user->getName(),
@@ -552,7 +580,7 @@ class SimpleCaptcha {
return false;
}
- if ( !$isEmpty && $this->captchaTriggers( $title, 'addurl' ) ) {
+ if ( !$isEmpty && $this->triggersCaptcha( 'addurl', $title ) ) {
// Only check edits that add URLs
if ( $content instanceof Content ) {
// Get links from the database
@@ -624,7 +652,7 @@ class SimpleCaptcha {
/**
* Filter callback function for URL whitelisting
- * @param $url string to check
+ * @param string $url string to check
* @return bool true if unknown, false if whitelisted
* @access private
*/
@@ -655,7 +683,7 @@ class SimpleCaptcha {
/**
* Build regex from whitelist
- * @param $lines string from [[MediaWiki:Captcha-addurl-whitelist]]
+ * @param string $lines string from [[MediaWiki:Captcha-addurl-whitelist]]
* @return array Regexes
* @access private
*/
@@ -729,11 +757,11 @@ class SimpleCaptcha {
/**
* Load external links from the externallinks table
- * @param $title Title
+ * @param Title $title
* @return array
*/
function getLinksFromTracker( $title ) {
- $dbr = wfGetDB( DB_SLAVE );
+ $dbr = wfGetDB( DB_REPLICA );
$id = $title->getArticleID(); // should be zero queries
$res = $dbr->select( 'externallinks', [ 'el_to' ],
[ 'el_from' => $id ], __METHOD__ );
@@ -747,8 +775,8 @@ class SimpleCaptcha {
/**
* Backend function for confirmEditMerged()
* @param WikiPage $page
- * @param $newtext string
- * @param $section
+ * @param string $newtext
+ * @param string $section
* @param IContextSource $context
* @return bool false if the CAPTCHA is rejected, true otherwise
*/
@@ -779,9 +807,9 @@ class SimpleCaptcha {
* @param RequestContext $context
* @param Content $content
* @param Status $status
- * @param $summary
- * @param $user
- * @param $minorEdit
+ * @param string $summary
+ * @param User $user
+ * @param bool $minorEdit
* @return bool
*/
function confirmEditMerged( $context, $content, $status, $summary, $user, $minorEdit ) {
@@ -834,10 +862,10 @@ class SimpleCaptcha {
* @return bool true to show captcha, false to skip captcha
*/
public function needCreateAccountCaptcha( User $creatingUser = null ) {
- global $wgCaptchaTriggers, $wgUser;
+ global $wgUser;
$creatingUser = $creatingUser ?: $wgUser;
- if ( $wgCaptchaTriggers['createaccount'] ) {
+ if ( $this->triggersCaptcha( CaptchaTriggers::CREATE_ACCOUNT ) ) {
if ( $creatingUser->isAllowed( 'skipcaptcha' ) ) {
wfDebug( "ConfirmEdit: user group allows skipping captcha on account creation\n" );
return false;
@@ -852,17 +880,17 @@ class SimpleCaptcha {
/**
* Check the captcha on Special:EmailUser
- * @param $from MailAddress
- * @param $to MailAddress
- * @param $subject String
- * @param $text String
- * @param $error String reference
- * @return Bool true to continue saving, false to abort and show a captcha form
+ * @param MailAddress $from
+ * @param MailAddress $to
+ * @param string $subject
+ * @param string $text
+ * @param string &$error
+ * @return bool true to continue saving, false to abort and show a captcha form
*/
function confirmEmailUser( $from, $to, $subject, $text, &$error ) {
- global $wgCaptchaTriggers, $wgUser, $wgRequest;
+ global $wgUser, $wgRequest;
- if ( $wgCaptchaTriggers['sendemail'] ) {
+ if ( $this->triggersCaptcha( CaptchaTriggers::SENDEMAIL ) ) {
if ( $wgUser->isAllowed( 'skipcaptcha' ) ) {
wfDebug( "ConfirmEdit: user group allows skipping captcha on email sending\n" );
return true;
@@ -887,7 +915,7 @@ class SimpleCaptcha {
}
/**
- * @param $module ApiBase
+ * @param ApiBase $module
* @return bool
*/
protected function isAPICaptchaModule( $module ) {
@@ -895,9 +923,9 @@ class SimpleCaptcha {
}
/**
- * @param $module ApiBase
- * @param $params array
- * @param $flags int
+ * @param ApiBase &$module
+ * @param array &$params
+ * @param int $flags
* @return bool
*/
public function APIGetAllowedParams( &$module, &$params, $flags ) {
@@ -1048,6 +1076,7 @@ class SimpleCaptcha {
/**
* Clear out existing captcha info from the session, to ensure
* it can't be reused.
+ * @param string $index
*/
public function clearCaptcha( $index ) {
CaptchaStore::get()->clear( $index );
@@ -1080,8 +1109,8 @@ class SimpleCaptcha {
/**
* Extract a list of all recognized HTTP links in the text.
- * @param $title Title
- * @param $text string
+ * @param Title $title
+ * @param string $text
* @return array of strings
*/
function findLinks( $title, $text ) {
@@ -1119,7 +1148,7 @@ class SimpleCaptcha {
* Modify the apprearance of the captcha field
* @param AuthenticationRequest[] $requests
* @param array $fieldInfo Field description as given by AuthenticationRequest::mergeFieldInfo
- * @param array $formDescriptor A form descriptor suitable for the HTMLForm constructor
+ * @param array &$formDescriptor A form descriptor suitable for the HTMLForm constructor
* @param string $action One of the AuthManager::ACTION_* constants
*/
public function onAuthChangeFormFields(
diff --git a/www/wiki/extensions/ConfirmEdit/composer.json b/www/wiki/extensions/ConfirmEdit/composer.json
index daa26e10..c7805653 100644
--- a/www/wiki/extensions/ConfirmEdit/composer.json
+++ b/www/wiki/extensions/ConfirmEdit/composer.json
@@ -1,16 +1,22 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1"
},
"scripts": {
"test": [
- "parallel-lint . --exclude vendor",
- "phpcs -p -s"
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
],
"fix": [
- "phpcbf"
+ "phpcbf",
+ "minus-x fix ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/ConfirmEdit/extension.json b/www/wiki/extensions/ConfirmEdit/extension.json
index 61ec7af3..3a18b5c5 100644
--- a/www/wiki/extensions/ConfirmEdit/extension.json
+++ b/www/wiki/extensions/ConfirmEdit/extension.json
@@ -1,7 +1,7 @@
{
"@doc": "Please read README.md",
"name": "ConfirmEdit",
- "version": "1.5.0",
+ "version": "1.5.1",
"author": [
"Brion Vibber",
"Florian Schmidt",
@@ -10,7 +10,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:ConfirmEdit",
"descriptionmsg": "captcha-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "antispam",
"requires": {
"MediaWiki": ">= 1.28"
@@ -52,17 +52,17 @@
"AutoloadClasses": {
"ConfirmEditHooks": "includes/ConfirmEditHooks.php",
"SimpleCaptcha": "SimpleCaptcha/Captcha.php",
- "CaptchaStore": "includes/CaptchaStore.php",
- "CaptchaSessionStore": "includes/CaptchaStore.php",
- "CaptchaCacheStore": "includes/CaptchaStore.php",
- "CaptchaHashStore": "includes/CaptchaStore.php",
+ "CaptchaStore": "includes/store/CaptchaStore.php",
+ "CaptchaSessionStore": "includes/store/CaptchaSessionStore.php",
+ "CaptchaCacheStore": "includes/store/CaptchaCacheStore.php",
+ "CaptchaHashStore": "includes/store/CaptchaHashStore.php",
+ "CaptchaTriggers": "includes/CaptchaTriggers.php",
"CaptchaSpecialPage": "includes/specials/SpecialCaptcha.php",
"CaptchaPreAuthenticationProvider": "includes/auth/CaptchaPreAuthenticationProvider.php",
"CaptchaAuthenticationRequest": "includes/auth/CaptchaAuthenticationRequest.php"
},
"ResourceModules": {
"ext.confirmEdit.editPreview.ipwhitelist.styles": {
- "position": "top",
"styles": "ext.confirmEdit.editPreview.ipwhitelist.styles.css"
}
},
@@ -93,7 +93,6 @@
"config": {
"CaptchaWhitelistIP": false,
"Captcha": null,
- "CaptchaClass": "SimpleCaptcha",
"CaptchaTriggers": {
"edit": false,
"create": false,
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/aa.json b/www/wiki/extensions/ConfirmEdit/i18n/aa.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/aa.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ais.json b/www/wiki/extensions/ConfirmEdit/i18n/ais.json
index 24c9cc79..4e45209a 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ais.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ais.json
@@ -2,14 +2,27 @@
"@metadata": {
"authors": [
"Benel",
- "Bunukwiki"
+ "Bunukwiki",
+ "Matma Rex"
]
},
+ "captcha-edit-fail": "CAPTCHA mungangaw saca mahedaw.",
+ "captcha-desc": "nipabeli CAPTCHA sitaneng sapikawa babakahen a sulit atu mizatneg tu mima",
"captcha-label": "CAPTCHA",
"captcha-help": "patukil nu yincenma",
- "captcha-id-label": "yincenma ID",
+ "captcha-info-help": "CAPTCHA ID sapuelac",
+ "captcha-id-label": "CAPTCHA ID",
"captcha-id-help": "yasulyang manakanca panukas akapasumad.",
+ "captcha-createaccount-fail": "CAPTCHA mungangaw saca mahedaw.",
+ "captcha-sendemail-fail": "CAPTCHA mungangaw saca mahedaw.",
+ "captcha-disabledinapi": "tina saungay maydih pisaungay CAPTCHA sawantan, sisa la’cus micaliw API misaungay.",
+ "captcha-error": "nay labuay a mungangaw, CAPTCHA ID malucek mungangaw: $1",
"captchahelp-title": "CAPTCHA buhci tu kamu",
+ "captchahelp-cookies-needed": "maydih kisu miwawah saazihay-sakaluk a Cookies kya kapah pisaungay tina sasahicaan.",
+ "captchahelp-text": "layapen pabinawlan pazepit palatuh a calay-kakacawan(wangcan), maleca tina Wiki, sawsawni apatahtah nu tatuni’ palatuh payakayakay a tademaw pisaungay lunukan sakaluk, i yadah calay-kakacawan(wangcan) pazepit tatuni’ masasiket.\nhaca kapah misipu uyniyay tatuni’ masasiket, uyzasa tina tatenga’ izaw ku libut.\n\nsisa,hatizaay a lawad, uzuma i kasabelih cunus calay-kakacawan(wangcan) masasiket, Wiki apaazih izaw kulikulitan kisu saca malingangu’ sulit a zunga, maydih kisu misulit kya paazihay a sulit.\nu nanu tina saungay utiih malunukay, taneng ngay tatenga’ay a misaungayay pazepit palatuh atu miliyas sayadahay a tatuni’ palatuh payakayakay atu malunukay sakaluk a debungan.\n\nkasaetiman, tina hakay utiih sakay caayka kapah ku mataay saca pisaungay ku sulit palana’an saca ngiha’palana’an a saazihay-sakaluk.\nuyzasa ayzasa caay henay kami nipabeli mibalic tu ngiha’ay a sakaluk.\namahica saungay ilabu’ nu hulic nu misu talibahalay misuayaw tu kelec, pipatakus [[Special:ListAdmins|calay-kakacawan(wangcan) mikuwanay]] papatun miedap.\n\npipecec saazihay-sakaluk a “tatiku” pipenecan kya tatiku kasabelih sakawaw-kalumyiti-sakaluk",
+ "captcha-addurl-whitelist": "#<!-- amana misaimed tina silsil --> <pre>\n#kamu-sakilul kese mahiza isasa’:\n# * amahicahica nay \"#\" tatebanan nu nisulitan angangan katukuh izikuz dayhiw buhci tu kamu \n# * amahicahica caay nayi’ ku cacan silsil dayhiw liyad tatungusay pakatineng a zateng,apahica sasutili’ URL a angangan-kikay\n#</pre> <!-- amana misaimed tina silsil -->",
+ "right-skipcaptcha": "mileku amateka’ CAPTCHA ID a saungay amana milawat CAPTCHA ID cyinyin",
"captcha-apihelp-param-captchaword": "patukil ku yincenma",
+ "captcha-apihelp-param-captchaid": "milunguc nuayaway a kodo nu ID",
"confirmedit-preview-content": "lacul"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/bg.json b/www/wiki/extensions/ConfirmEdit/i18n/bg.json
index cbe45e96..b6a5be29 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/bg.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/bg.json
@@ -18,8 +18,8 @@
"captcha-createaccount-fail": "Погрешен или липсващ код за потвърждение.",
"captcha-create": "За да създадете страницата, моля решете задачата по-долу и въведете отговора в текстовата кутия ([[Special:Captcha/help|повече информация]]):",
"captcha-sendemail-fail": "Погрешен или липсващ код за потвърждение.",
- "captcha-disabledinapi": "Това действие изисква капча, следователно не може да бъде извършено през приложния програмен интерфейс.",
- "captchahelp-title": "Помощ за captcha",
+ "captcha-disabledinapi": "Това действие изисква CAPTCHA, следователно не може да бъде извършено през приложния програмен интерфейс.",
+ "captchahelp-title": "Помощ за CAPTCHA",
"captchahelp-cookies-needed": "За да работи това, необходимо е бисквитките на вашия браузър да са включени.",
- "captchahelp-text": "Уеб сайтовете, които позволяват свободно да се редактира и добавя ново съдържание (като това уики), често са обект на атаки от страна на спамъри, които използват средства за автоматизирано редактиране за публикуване на препратки към много сайтове. Въпреки че тези препратки могат да бъдат премахнати, те са особено неприятни за потребителите.\n\nПонякога, особено когато се добавят нови препратки към страниците, е възможно уикито да покаже картинка с текст, който трябва да бъде въведен в посоченото поле. Тъй като това е стъпка, която е трудно да бъде прескочена при автоматизирано редактиране, тя затруднява и спира повечето спамъри и роботи, но допуска истинските потребителите да правят редакции.\n\nЗа съжаление тази стъпка може да затрудни незрящи потребители или потребители, които използват текстови или речеви браузъри. За момента системата не разполага с възможност за гласова алтернатива. Обърнете се за помощ към [[Special:ListAdmins|администратор на сайта]], ако това изискване на системата ви затруднява да допринасяте легитимно.\n\nНатиснете бутона 'back' на вашия браузър, за да се върнете към редактора на страници."
+ "captchahelp-text": "Уеб сайтовете, които позволяват свободно да се редактира и добавя ново съдържание (като това уики), често са обект на атаки от страна на спамъри, които използват средства за автоматизирано редактиране за публикуване на препратки към много сайтове. Въпреки че тези препратки могат да бъдат премахнати, те са особено неприятни за потребителите.\n\nПонякога, особено когато се добавят нови препратки към страниците, е възможно уикито да покаже картинка с текст, който трябва да бъде въведен в посоченото поле. Тъй като това е стъпка, която е трудно да бъде прескочена при автоматизирано редактиране, тя затруднява и спира повечето спамъри и роботи, но допуска истинските потребителите да правят редакции.\n\nЗа съжаление тази стъпка може да затрудни незрящи потребители или потребители, които използват текстови или речеви браузъри. За момента системата не разполага с възможност за гласова алтернатива. Обърнете се за помощ към [[Special:ListAdmins|администратор на сайта]], ако това изискване на системата ви затруднява да допринасяте легитимно.\n\nНатиснете бутона „back“ на вашия браузър, за да се върнете към редактора на страници."
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/bi.json b/www/wiki/extensions/ConfirmEdit/i18n/bi.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/bi.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ce.json b/www/wiki/extensions/ConfirmEdit/i18n/ce.json
index fc42d0de..57612779 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ce.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ce.json
@@ -5,5 +5,6 @@
]
},
"captcha-desc": "Спамах ларо а, пароль харжа а CAPTCHA таронаш хуьлуьйту",
+ "captcha-label": "CAPTCHA",
"right-skipcaptcha": "CAPTCHA-хьажар кхочушдар, CAPTCHA чекхдалар доцуш"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ch.json b/www/wiki/extensions/ConfirmEdit/i18n/ch.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ch.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/chr.json b/www/wiki/extensions/ConfirmEdit/i18n/chr.json
new file mode 100644
index 00000000..58760534
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/chr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "R12ntech"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/cs.json b/www/wiki/extensions/ConfirmEdit/i18n/cs.json
index d5ddbb72..23622142 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/cs.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/cs.json
@@ -5,7 +5,8 @@
"Li-sung",
"Matěj Grabovský",
"Mormegil",
- "Dvorapa"
+ "Dvorapa",
+ "Ilimanaq29"
]
},
"captcha-edit": "Abyste mohli editovat tuto stránku, musíte vyřešit následující úkol níže a napsat výsledek do políčka ([[Special:Captcha/help|Co tohle znamená?]]):",
@@ -27,7 +28,7 @@
"captcha-error": "Ověření CAPTCHA se nezdařilo kvůli vnitřní chybě: $1",
"captchahelp-title": "Nápověda ke captcha",
"captchahelp-cookies-needed": "Aby to fungovalo, musíte mít ve svém prohlížeči zapnuty cookies.",
- "captchahelp-text": "Webové stránky, do kterých mohou přispívat jejich návštěvníci (jako například tato wiki), jsou často terčem spammerů, kteří pomocí automatických nástrojů vkládají své odkazy na velké množství stránek. Přestože lze tento spam odstranit, představuje nepříjemné obtěžování.\n\nNěkdy, zvláště při přidávání nových webových odkazů, vám může wiki ukázat obrázek barevného či pokrouceného textu a požádat vás o opsání zobrazených znaků. Jelikož takovou úlohu lze jen těžko automatizovat, skuteční lidé mohou dále přispívat, zatímco většinu spammerů a jiných robotických útočníků to zastaví.\n\nBohužel to však může představovat nepříjemný problém pro uživatele se zrakovým postižením či uživatele používající textové prohlížeče či hlasové čtečky. V současné době nemáme alternativní zvukovou verzi. Kontaktujte laskavě [[Special:ListAdmins|správce serveru]], pokud vám to brání v užitečných příspěvcích a potřebujete pomoc.\n\nPro návrat na předchozí stránku stiskněte ve svém prohlížeči tlačítko „zpět“.",
+ "captchahelp-text": "Webové stránky, do kterých mohou přispívat jejich návštěvníci (jako například tato wiki), jsou často terčem spammerů, kteří pomocí automatických nástrojů vkládají své odkazy na velké množství stránek. Přestože lze tento spam odstranit, představuje nepříjemné obtěžování.\n\nNěkdy, zvláště při přidávání nových webových odkazů, vám může wiki ukázat obrázek barevného či pokrouceného textu a požádat vás o opsání zobrazených znaků. Jelikož takovou úlohu lze jen těžko automatizovat, skuteční lidé mohou dále přispívat, zatímco většinu spammerů a jiných robotických útočníků to zastaví.\n\nBohužel to však může představovat nepříjemný problém pro uživatele se zrakovým postižením či uživatele používající textové prohlížeče či hlasové čtečky. V současné době nemáme alternativní zvukovou verzi. Kontaktujte prosím [[Special:ListAdmins|správce serveru]], pokud vám to brání v užitečných příspěvcích a potřebujete pomoc.\n\nPro návrat na předchozí stránku stiskněte ve svém prohlížeči tlačítko „zpět“.",
"captcha-addurl-whitelist": " #<!-- Nechte tento řádek přesně tak jak je --> <pre>\n# Syntaxe je následující:\n# * Všechno od znaku „#“ do konce řádku je komentář\n# * Každý neprázdný řádek je fragment regulárního výrazu, který se aplikuje pouze na název stroje v URL\n #</pre> <!-- Nechte tento řádek přesně tak jak je -->",
"right-skipcaptcha": "Vykonávání akcí spojených s CAPTCHA bez nutnosti jejího řešení",
"captcha-apihelp-param-captchaword": "Odpověď na CAPTCHA",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/el.json b/www/wiki/extensions/ConfirmEdit/i18n/el.json
index a89c5a6b..1c07b31c 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/el.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/el.json
@@ -10,23 +10,35 @@
"Omnipaedista",
"Protnet",
"ZaDiak",
- "Περίεργος"
+ "Περίεργος",
+ "Nikosgranturismogt"
]
},
- "captcha-edit": "Για να επεξεργαστείτε αυτή τη σελίδα, παρακαλούμε υπολογίστε το παρακάτω απλό άθροισμα και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-edit": "Για να επεξεργαστείτε αυτή τη σελίδα, παρακαλούμε υπολογίστε την παρακάτω εργασία και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-edit-fail": "Εσφαλμένο ή αγνοούμενο CAPTCHA.",
"captcha-desc": "Παρέχει τεχνικές CAPTCHA για την προστασία από spam και προσπάθειες σπασίματος κωδικών πρόσβασης",
"captcha-label": "CAPTCHA",
- "captcha-addurl": "Η επεξεργασία σας περιλαμβάνει νέους εξωτερικούς συνδέσμους. Για λόγους προστασίας κατά αυτοματοποιημένων ανεπιθύμητων δημοσιεύσεων, παρακαλούμε υπολογίστε το παρακάτω άθροισμα και γράψτε την απάντηση στο κουτάκι ώστε να αποθηκευτεί η επεξεργασία σας ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
- "captcha-badlogin": "Για την προστασία του wiki απέναντι σε σπάσιμο κωδικών πρόσβασης, παρακαλούμε υπολογίστε το παρακάτω απλό άθροισμα και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
- "captcha-createaccount": "Για την προστασία του wiki απέναντι σε αυτοματοποιημένη δημιουργία λογαριασμών, παρακαλούμε υπολογίστε το παρακάτω απλό άθροισμα και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-help": "Λήση του CAPTCHA.",
+ "captcha-info-help": "Περιγραφή του CAPTCHA.",
+ "captcha-id-label": "Αναγνωριστικό του CAPTCHA",
+ "captcha-addurl": "Η επεξεργασία σας περιλαμβάνει νέους εξωτερικούς συνδέσμους. Για λόγους προστασίας κατά αυτοματοποιημένων ανεπιθύμητων δημοσιεύσεων, παρακαλούμε υπολογίστε την ακόλουθη εργασία και γράψτε την απάντηση στο κουτάκι ώστε να αποθηκευτεί η επεξεργασία σας ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-badlogin": "Για την προστασία του wiki απέναντι σε σπάσιμο κωδικών πρόσβασης, παρακαλούμε λύστε τη παρακάτω εργασία και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-createaccount": "Για την προστασία του wiki απέναντι σε αυτοματοποιημένη δημιουργία λογαριασμών, παρακαλούμε λύστε τη παρακάτω εργασία και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
"captcha-createaccount-fail": "Εσφαλμένος ή μη διαθέσιμο CAPTCHA.",
- "captcha-create": "Για να δημιουργήσετε τη σελίδα, παρακαλούμε υπολογίστε το παρακάτω απλό άθροισμα και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
- "captcha-sendemail": "Για την προστασία του βίκι απέναντι σε αυτοματοποιημένες ανεπιθύμητες δημοσιεύσεις, παρακαλούμε υπολογίστε το παρακάτω απλό άθροισμα και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-create": "Για να δημιουργήσετε τη σελίδα, παρακαλούμε λύστε τη παρακάτω εργασία και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
+ "captcha-sendemail": "Για την προστασία του βίκι απέναντι σε αυτοματοποιημένες ανεπιθύμητες δημοσιεύσεις, παρακαλούμε λύστε την παρακάτω εργασία και γράψτε την απάντηση στο πλαίσιο ([[Special:Captcha/help|περισσότερες πληροφορίες]]):",
"captcha-sendemail-fail": "Λανθασμένος ή μη πληκτρολογημένος κωδικός οπτικής επαλήθευσης (CAPTCHA).",
"captcha-disabledinapi": "Η ενέργεια αυτή απαιτεί επαλήθευση λεκτικού κειμένου και για αυτό δεν μπορεί να γίνει μέσω του API.",
+ "captcha-error": "Η επαλήθευση του CAPTCHA απέτυχε λόγω εσωτερικού σφάλματος: $1",
"captchahelp-title": "Βοήθεια για CAPTCHA",
"captchahelp-cookies-needed": "Θα πρέπει να έχετε τα cookies ενεργοποιημένα στον περιηγητή σας για να εκτελεστεί η λειτουργία.",
"captchahelp-text": "Οι ιστότοποι που επιτρέπουν δημόσια επεξεργασία, όπως αυτό το wiki, παραβιάζονται συχνά από κακόβουλους χρήστες (spammer) που χρησιμοποιούν αυτοματοποιημένα εργαλεία για να δημοσιεύουν μαζικά υπερσυνδέσμους σε πλήθος ιστοτόπων. Αν και αυτοί οι σύνδεσμοι spam μπορούν να αφαιρεθούν, είναι μεγάλος μπελάς.\n\nΜερικές φορές, ειδικά κατά την προσθήκη νέων συνδέσμων σε μια σελίδα, το wiki μπορεί να σας παρουσιάσει μια εικόνα με χρωματισμένο ή διαστρεβλωμένο κείμενο και να σας ζητήσει να πληκτρολογήσετε τις λέξεις που διακρίνετε. Δεδομένου ότι αυτή η εργασία είναι δύσκολο να αυτοματοποιηθεί, θα επιτρέψει στους περισσότερους πραγματικούς ανθρώπους να κάνουν τις δημοσιεύσεις τους, σταματώντας όμως spammer και άλλους ρομποτικά επιτιθέμενους.\n\nΔυστυχώς αυτό μπορεί να προκαλέσει δυσχέρεια σε χρήστες με προβλήματα όρασης τους ή όσους χρησιμοποιούν περιηγητές αποκλειστικά κειμένου ή περιηγητές με ομιλία. Προς το παρόν δεν έχουμε κάποια ηχητική εναλλακτική λύση διαθέσιμη. Παρακαλούμε επικοινωνήστε με τους [[Special:ListAdmins|διαχειριστές]] του ιστοτόπου για βοήθεια, εάν αυτό για κάποιο λόγο σας αποτρέπει να εκτελέσετε θεμιτές ενέργειες.\n\nΠατήστε το κουμπί «πίσω» στον περιηγητή σας για να επιστρέψετε στον επεξεργαστή σελίδων.",
"captcha-addurl-whitelist": " #<!-- αφήστε αυτή την γραμμή ακριβώς όπως είναι --> <pre>\n# Η σύνταξη είναι ως ακολούθως:\n# * Οποιαδήποτε γραμμή ξεκινάει με χαρακτήρα \"#\" είναι σχόλιο\n# * Κάθε μη κενή γραμμή αποτελεί μέρος κανονικής έκφρασης η οποία αντιστοιχεί σε διευθύνσεις URL\n #</pre> <!-- αφήστε αυτή την γραμμή ακριβώς όπως είναι -->",
- "right-skipcaptcha": "Πραγματοποίηση ενεργειών που ενεργοποιούν CAPTCHA χωρίς να χρειάζεται πέρασμα από το CAPTCHA"
+ "right-skipcaptcha": "Πραγματοποίηση ενεργειών που ενεργοποιούν CAPTCHA χωρίς να χρειάζεται πέρασμα από το CAPTCHA",
+ "captcha-apihelp-param-captchaword": "Απάντηση του CAPTCHA",
+ "confirmedit-preview-line": "Αριθμός γραμμής",
+ "confirmedit-preview-content": "Περιεχόμενο",
+ "confirmedit-preview-validity": "Εγκυρότητα",
+ "confirmedit-preview-valid": "ισχύει",
+ "confirmedit-preview-invalid": "Μη έγκυρο"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/fa.json b/www/wiki/extensions/ConfirmEdit/i18n/fa.json
index 37026e65..db9acc74 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/fa.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/fa.json
@@ -5,26 +5,38 @@
"Huji",
"Mjbmr",
"Reza1615",
- "Wayiran"
+ "Wayiran",
+ "Ladsgroup",
+ "Arash"
]
},
- "captcha-edit": "برای ویرایش این مقاله، لطفاً حاصل جمع زیر را حساب کنید و نتیجه را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
+ "captcha-edit": "برای ویرایش این مقاله، لطفاً نتیجهٔ عمل زیر را حساب کنید و آن را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
"captcha-edit-fail": "کد تائیدی نادرست یا ناموجود",
"captcha-desc": "روش‌های مبتنی بر CAPTCHA برای مقابله با هرزنگاری و کشف گذرواژه فراهم می‌کند",
"captcha-label": "کپچا",
- "captcha-addurl": "ویرایش شما شامل پیوندهای تازه‌ای به بیرون است.\nبرای کمک به جلوگیری از ارسال خودکار هرزنامه‌ها، لطفاً حاصل جمع زیر را حساب کنید و نتیجه را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
- "captcha-badlogin": "برای کمک به جلوگیری از شکستن خودکار گذرواژه، لطفاً حاصل جمع زیر را حساب کنید و نتیجه را وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
- "captcha-createaccount": "برای جلوگیری از ایجاد خودکار حساب کاربری، لطفاً حاصل جمع زیر را حساب کنید و نتیجه را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
+ "captcha-help": "پاسخ کپچا",
+ "captcha-info-help": "توضیح کپچا",
+ "captcha-id-label": "شناسه کپچا",
+ "captcha-id-help": "این مقدار بدون تغییر باید بازگردانده شود",
+ "captcha-addurl": "ویرایش شما شامل پیوندهای تازه‌ای به بیرون است.\nبرای کمک به جلوگیری از ارسال خودکار هرزنامه‌ها، لطفاً عملیات زیر را انجام دهید و نتیجه را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
+ "captcha-badlogin": "برای کمک به جلوگیری از شکستن خودکار گذرواژه، لطفاً عملیات زیر را انجام دهید و نتیجه را وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
+ "captcha-createaccount": "برای جلوگیری از ایجاد خودکار حساب کاربری، لطفاً عملیات زیر را انجام دهید و نتیجه را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
"captcha-createaccount-fail": "کد تأییدی وجود ندارد یا نادرست است.",
- "captcha-create": "برای ایجاد صفحه لطفاً حاصل جمع زیر را حساب کنید و نتیجه را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
- "captcha-sendemail": "برای کمک به حفاظت ویکی در برابر هرزنامه‌های خودکار، لطفاً جمع سادهٔ زیر را حل کنید و جواب را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
+ "captcha-create": "برای ایجاد صفحه، لطفاً نتیجهٔ عمل زیر را حساب کنید و آن را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
+ "captcha-sendemail": "برای کمک به حفاظت ویکی در برابر هرزنامه‌های خودکار، لطفاً نتیجهٔ عمل زیر را حساب کنید و آن را در جعبه وارد کنید ([[Special:Captcha/help|اطلاعات بیشتر]]):",
"captcha-sendemail-fail": "کد تأییدی وجود ندارد یا نادرست است.",
"captcha-disabledinapi": "این اقدام به کپچا نیاز دارد، بنابراین نمی‌تواند از طریق رابط برنامه‌نویسی انجام شود.",
+ "captcha-error": "تأییدیهٔ کپچا به‌دلیل خطای داخلی ناموفق بود: $1",
"captchahelp-title": "راهنمای Captcha",
"captchahelp-cookies-needed": "برای کار کردن آن، شما باید کوکی‌های مرورگرتان را فعال کنید.",
"captchahelp-text": "تارنماهایی مثل این ویکی که به عموم اجازهٔ نوشتن مطلب می‌دهند، غالباً مورد سوءاستفادهٔ هرزفرستندگانی می‌شوند که با ابزارهای خودکار پیوندهای بیرونی به تارنماهای موردنظرشان وارد می‌کنند.\nاگر چه این پیوندهای هرز و تبلیغاتی را می‌توان دستی حذف کرد، ولی به هر حال باعث اعصاب‌خردی زیادی می‌شوند.\n\nگاهی اوقات، خصوصاً هنگامی که پیوندهای بیرونی جدیدی به صفحه اضافه می‌شود، ویکی ممکن است به شما تصویری رنگی و کج‌وکوله از متنی نشان بدهد و از شما بخواهد که کلمه‌های نشان‌داده‌شده را تایپ کنید.\nاز آنجا که خودکارسازی این کار دشوار است، انسانهای واقعی می‌توانند پیوندهاشان را وارد کنند ولی برنامه‌های خودکار تبلیغاتی از خرابکاری باز خواهند ماند.\n\nمتأسفانه این امر ممکن است باعث مزاحمت برای کاربرانی شود که چشمشان ضعیف است یا از مرورگرهای متنی یا گفتاری استفاده می‌کنند.\nدر حال حاضر ما جایگزین صوتی‌ای برای این کار نداریم. لطفاً اگر برای واردساختن پیوندهای مشروع دچار مشکل شده‌اید با [[Special:ListAdmins|مدیران این تارنما]] تماس بگیرید.\n\nدکمهٔ «بازگشت» را در مرورگر خود فشار دهید تا به صفحهٔ ویرایش بازگردید.",
"captcha-addurl-whitelist": " #<!-- این سطر را همان‌گونه که هست رها کنید --> <pre>\n# قواعد به این شکل است:\n# * همه‌چیز از «#» تا آخر سطر یک توضیح در نظر گرفته می‌شود.\n# * هر سطری که خالی نباشد یک قطعه در نظر گرفته می‌شود که فقط با نام میزبان اینترنتی سنجیده می‌شود.\n #</pre> <!-- این سطر را همان‌گونه که هست رها کنید -->",
"right-skipcaptcha": "انجام کارهایی که CAPTCHA را فعال می‌کنند بدون نیاز به گذر از CAPTCHA",
"captcha-apihelp-param-captchaword": "پاسخ کپچا را بدهید",
- "captcha-apihelp-param-captchaid": "شناسهٔ کپچا از درخواست قبلی"
+ "captcha-apihelp-param-captchaid": "شناسهٔ کپچا از درخواست قبلی",
+ "confirmedit-preview-line": "شماره خط",
+ "confirmedit-preview-content": "محتوا",
+ "confirmedit-preview-validity": "اعتبار",
+ "confirmedit-preview-valid": "معتبر",
+ "confirmedit-preview-invalid": "نامعتبر"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/fi.json b/www/wiki/extensions/ConfirmEdit/i18n/fi.json
index f14b540e..8396ba69 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/fi.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/fi.json
@@ -13,10 +13,11 @@
"Pxos",
"Jack Phoenix",
"01miki10",
- "Alluk."
+ "Alluk.",
+ "Pahkiqaz"
]
},
- "captcha-edit": "Ratkaise alla oleva laskutoimitus jatkaaksesi ([[Special:Captcha/help|lisätietoja]]):",
+ "captcha-edit": "Ratkaise alla oleva laskutoimitus muokataksesi tätä sivua ([[Special:Captcha/help|lisätietoja]]):",
"captcha-edit-fail": "Virheellinen tai puuttuva CAPTCHA.",
"captcha-desc": "Tarjoaa CAPTCHA-tekniikoita suojaamaan mainoslinkkejä ja salasana-arvailua vastaan.",
"captcha-label": "CAPTCHA",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/fr.json b/www/wiki/extensions/ConfirmEdit/i18n/fr.json
index 8f7bce6b..59c09a8d 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/fr.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/fr.json
@@ -34,13 +34,13 @@
"captcha-create": "Pour créer la page, veuillez résoudre la tâche ci-dessous et inscrire le résultat dans le champ ([[Special:Captcha/help|plus d’informations]]) :",
"captcha-sendemail": "Afin de nous aider à prévenir le pollupostage automatisé, veuillez résoudre la tâche et inscrire le résultat dans le champ ([[Special:Captcha/help|plus d’informations]]) :",
"captcha-sendemail-fail": "CAPTCHA incorrect ou absent.",
- "captcha-disabledinapi": "Cette action requiert un captcha, donc elle ne peut pas être effectuée via l’IPA.",
+ "captcha-disabledinapi": "Cette action requiert un CAPTCHA, donc elle ne peut pas être effectuée via l’API.",
"captcha-error": "La vérification CAPTCHA a échoué avec l'erreur interne: $1",
- "captchahelp-title": "Aide sur le captcha",
- "captchahelp-cookies-needed": "Il vous faudra autoriser les témoins (''cookies'') de votre navigateur pour que cela fonctionne.",
+ "captchahelp-title": "Aide sur le CAPTCHA",
+ "captchahelp-cookies-needed": "Il vous faudra autoriser les témoins (''cookies'') dans votre navigateur pour que cela fonctionne.",
"captchahelp-text": "Les sites web qui acceptent des contributions du public, tels que ce wiki, sont souvent victimes de spammeurs qui utilisent des outils automatisés pour placer de nombreux liens vers leurs sites.\nMême si cette pollution peut être effacée, elle n’en reste pas moins irritante.\n\nParfois, particulièrement lors de l’ajout de nouveaux liens externes dans une page, le wiki peut vous montrer une image d’un texte embrouillé, déformé ou coloré et vous demander de taper les mots indiqués.\nCette tâche étant difficile à accomplir de façon automatisée, cela permet à la plupart des humains de réaliser leurs contributions tout en stoppant la plupart des spammeurs et autres attaquants robotisés.\n\nMalheureusement, cette solution peut gêner les utilisateurs malvoyants ou qui utilisent un navigateur en texte seul ou vocal. Nous ne disposons pas d’alternative audio pour l’instant.\nVeuillez contacter [[Special:ListAdmins|les administrateurs du site]] si cela vous empêche de façon inattendue de faire des contributions légitimes.\n\nCliquez sur le bouton « Précédent » de votre navigateur pour revenir à la page de modification.",
"captcha-addurl-whitelist": " #<!-- laissez cette ligne exactement telle quelle --><pre>\n# La syntaxe est la suivante :\n# * Tout caractère depuis « # » jusqu’à la fin de la ligne est interprété comme un commentaire.\n# * Toute ligne non vide est un fragment d’expression rationnelle qui ne correspondra qu’aux hôtes dans les liens hypertextes.\n #</pre><!-- laissez cette ligne exactement telle quelle -->",
- "right-skipcaptcha": "Réaliser des actions qui déclenchent un captcha sans avoir à passer celui-ci",
+ "right-skipcaptcha": "Réaliser des actions qui déclenchent un CAPTCHA sans avoir à passer celui-ci",
"captcha-apihelp-param-captchaword": "Réponse au CAPTCHA",
"captcha-apihelp-param-captchaid": "Identifiant de CAPTCHA de la requête précédente",
"confirmedit-preview-line": "Numéro de ligne",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/fy.json b/www/wiki/extensions/ConfirmEdit/i18n/fy.json
index 4af7c7a8..debb68cd 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/fy.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/fy.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Snakesteuben",
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
"captcha-label": "CAPTCHA",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/gcr.json b/www/wiki/extensions/ConfirmEdit/i18n/gcr.json
new file mode 100644
index 00000000..3a3c21ec
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/gcr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/gl.json b/www/wiki/extensions/ConfirmEdit/i18n/gl.json
index bde22cf3..36b9068d 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/gl.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/gl.json
@@ -36,6 +36,6 @@
"confirmedit-preview-content": "Contido",
"confirmedit-preview-validity": "Validez",
"confirmedit-preview-valid": "válida",
- "confirmedit-preview-invalid": "inválida",
+ "confirmedit-preview-invalid": "non válida",
"confirmedit-preview-description": "A táboa seguinte amosa a lista de liñas nesta páxina e se é un enderezo IP válido ou un rango de enderezos IP. Se a liña é un enderezo IP válido ou rango de enderezos IP, pasará a unha lista branca para o CAPTCHA, pero as liñas non válidas serán ignoradas. Un exemplo dun rango de enderezos IP válido sería: 69.208.0.0/16 que vai desde 69.208.0.0 ata 69.208.255.255. [https://www.mediawiki.org/wiki/Especial:MyLanguage/Axuda:a gama_bloquea#Calcular_o_sufixo_de CIDR Máis información] sobre como calcular un rango de enderezos IP."
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/hi.json b/www/wiki/extensions/ConfirmEdit/i18n/hi.json
index 91d3d06e..7f3b3d0e 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/hi.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/hi.json
@@ -10,7 +10,8 @@
"Sfic",
"NehalDaveND",
"Jayprakash12345",
- "Anamdas"
+ "Anamdas",
+ "Innocentbunny"
]
},
"captcha-edit": "यह पन्ना संपादित करने के लिये नीचे दिये हुए आसान सवाल को हल करके उत्तर दिए गए बॉक्स में लिखें ([[Special:Captcha/help|अधिक जानकारी]]):",
@@ -28,6 +29,7 @@
"captcha-create": "यह पन्ना बनाने के लिये, नीचे दिये आसान प्रश्न का उत्तर बक्से में लिखें ([[Special:Captcha/help|अधिक जानकारी]]):",
"captcha-sendemail": "स्वचालित स्पैमिंग से बचाव के लिये कृपया नीचे दिये प्रश्न का उत्तर बक्से में लिखें\n([[Special:Captcha/help|अधिक जानकारी]]):",
"captcha-sendemail-fail": "केप्चा गलत या खाली है।",
+ "captcha-disabledinapi": "इस कार्रवाई हेतु CAPTCHA आवश्यक है, अतः एपीआई द्वारा इसे कार्यान्वित नहीं कर सकते हैं।",
"captcha-error": "आंतरिक त्रुटि के कारण कैप्चा सत्यापन विफल रहा: $1",
"captchahelp-title": "कॅप्टचा सहायता",
"captchahelp-cookies-needed": "यह कार्य करने के लिये आपने कूकीज (cookies) एनेबल किया होना आवश्यक हैं।",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/hr.json b/www/wiki/extensions/ConfirmEdit/i18n/hr.json
index 284c8ef1..5068fa22 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/hr.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/hr.json
@@ -7,7 +7,8 @@
"Herr Mlinka",
"Roberta F.",
"SpeedyGonsales",
- "Bugoslav"
+ "Bugoslav",
+ "MaGa"
]
},
"captcha-edit": "Da uredite ovu stranicu, molimo riješite jednostavno zbrajanje ispod i unesite rezultat u rubriku ([[Special:Captcha/help|više informacija]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/is.json b/www/wiki/extensions/ConfirmEdit/i18n/is.json
index c41e3b6f..752884f0 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/is.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/is.json
@@ -7,6 +7,7 @@
]
},
"captcha-edit": "Til að breyta þessari síðu, vinsamlegast leystu verkefnið að neðan og skrifaðu svarið í\nreitinn ([[Special:Captcha/help|frekari upplýsingar]]):",
+ "captcha-edit-fail": "Staðfestingarkóðinn var rangur eða ekki til staðar.",
"captcha-label": "CAPTCHA",
"captcha-addurl": "Breyting þín felur í sér viðbætta ytri tengla. Til að verjast sjálfvirku\nauglýsingarusli, biðjum við þig vinsamlegast að leysa verkefnið að neðan og skrifa svarið í reitinn til að vista breytinguna þína. ([[Special:Captcha/help|frekari upplýsingar]]):",
"captcha-badlogin": "Til að verjast sjálfvirkum leyniorðaárásum, biðjum við þig vinsamlegast að leysa verkefnið að neðan og skrifa svarið í reitinn ([[Special:Captcha/help|frekari upplýsingar]]):",
@@ -19,5 +20,10 @@
"captchahelp-title": "Captcha-hjálp",
"captchahelp-cookies-needed": "Þú verður að leyfa vefkökur til þess að þetta virki.",
"captchahelp-text": "Vefsíður sem að leyfa framlög frá frá almenningi, líkt og þessi wiki-vefur, eru oft misnotaðar af svokölluðum „spömmurum“ sem nota sjálfvirk tól til þess að setja inn tengla á aðrar vefsíður. Aðrir notendur geta fjarlægt þessa tengla en töluverð truflun er af þeim.\n\nStundum þegar þú breytir síðum, sérstaklega ef breytingin felur í sér nýja tengla á aðra vefi, getur gerst að þú sért beðin(n) um að skrifa inn orð sem birtast á lituðum eða óskýrum myndum. Fyrir flesta mannlega notendur er þetta lítið mál en sjálfvirk tól ráða ekki við þetta.\n\nÞví miður kann þetta að valda notendum óþægindum sem hafa skerta sjón eða notast við talmálsvafra. Enn sem komið er eru ekki til aðrir valkostir fyrir þau tilvik. \nVinsamlegast hafðu samband við [[Special:ListAdmins|stjórnanda síðunnar]] til að fá aðstoð ef þetta kemur í veg fyrir lögmætar breytingar af þinni hálfu.\n\nNotaðu „til-baka“-hnapp vafrans til að breyta síðunni.",
- "right-skipcaptcha": "Geta gert aðgerðir án þess að nota kæfuvörn"
+ "right-skipcaptcha": "Geta gert aðgerðir án þess að nota kæfuvörn",
+ "confirmedit-preview-line": "Línunúmer",
+ "confirmedit-preview-content": "Efni",
+ "confirmedit-preview-validity": "Gildi",
+ "confirmedit-preview-valid": "gilt",
+ "confirmedit-preview-invalid": "ógilt"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ja.json b/www/wiki/extensions/ConfirmEdit/i18n/ja.json
index 8e6515d3..e2c95e28 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ja.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ja.json
@@ -8,14 +8,20 @@
"Shirayuki",
"Whym",
"Ridmevo",
- "Otokoume"
+ "Otokoume",
+ "Yusuke1109",
+ "Omotecho"
]
},
- "captcha-edit": "このページを編集するには、下記の簡単な数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|ヘルプ]]):",
+ "captcha-edit": "このページを編集するには、下記の数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|ヘルプ]]):",
"captcha-edit-fail": "CAPTCHA が正しくない、または入力されていません。",
"captcha-desc": "スパム攻撃やパスワード推定攻撃を防ぐための CAPTCHA 技術を提供する",
"captcha-label": "CAPTCHA",
- "captcha-addurl": "あなたは新しい外部リンクを追加しようとしています。\n自動でのスパム攻撃を防ぐため、お手数ですが下記の簡単な数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|ヘルプ]]):",
+ "captcha-help": "CAPTCHAの解決策。",
+ "captcha-info-help": "CAPTCHAの説明。",
+ "captcha-id-label": "CAPTCHA ID",
+ "captcha-id-help": "この値は変更されずに戻されます。",
+ "captcha-addurl": "新しい外部リンクを追加しようとしています。\n自動でのスパム攻撃を防ぐため、お手数ですが下記の数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|ヘルプ]]):",
"captcha-badlogin": "自動でのパスワードクラック攻撃からウィキを保護するため、お手数ですが下記の簡単な数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|詳細]]):",
"captcha-createaccount": "アカウントの自動登録からウィキを保護するため、お手数ですが下記の簡単な数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|ヘルプ]]):",
"captcha-createaccount-fail": "CAPTCHA が正しくない、または入力されていません。",
@@ -23,13 +29,18 @@
"captcha-sendemail": "自動でのスパム攻撃からウィキを保護するため、お手数ですが下記の簡単な数式を計算してその答えを欄に入力してください ([[Special:Captcha/help|詳細]]):",
"captcha-sendemail-fail": "CAPTCHA が正しくない、または入力されていません。",
"captcha-disabledinapi": "この操作には CAPTCHA 認証が必要なため、API では実行できません。",
+ "captcha-error": "内部エラーのためCAPTCHAの確認に失敗しました:$1",
"captchahelp-title": "CAPTCHA (画像認証) ヘルプ",
"captchahelp-cookies-needed": "ブラウザーの Cookie を有効にする必要があります。",
"captchahelp-text": "一般からの投稿を受け付けるこのウィキのようなウェブサイトは、自動投稿ツールを使って多くのサイトにリンクを張ってまわるスパマーにより荒らされがちです。\nこのようなスパムは除去できるものの、その作業は大変に面倒なものです。\n\nこのため、このウィキではときどき、特に新しい外部リンクがページに追加されたときなどに、色の付いた、あるいは形のゆがんだ文字の画像を提示し、何と書いてあるか入力をお願いすることがあります。\nこの作業は自動化が難しいため、スパマーなどのプログラムを用いた攻撃をほぼ阻止しつつ、大半の生身の人間による投稿ができるようにします。\n\nしかし、残念なことに、この方法により、視力が低い利用者や、テキストベースあるいは音声ベースのブラウザーを使用している利用者にご不便をおかけする場合があります。\n現時点では、音声による代替方法はありません。\n正当な操作をするにあたって本機能が障害となっている場合、[[Special:ListAdmins|サイト管理者]]に連絡して協力を求めてください。\n\nページの編集に戻るには、ブラウザーの「戻る」ボタンを押してください。",
"captcha-addurl-whitelist": " #<!-- この行は変更しないでください --> <pre>\n# 構文は以下の通りです:\n# * 「#」文字から行末まではコメントとして扱われます\n# * 空白を含まない行は、URLに含まれるホスト名との一致を検出する正規表現です\n #</pre> <!-- この行は変更しないでください -->",
"right-skipcaptcha": "CAPTCHAが必要な場面でCAPTCHAをスキップして操作を実行",
"captcha-apihelp-param-captchaword": "CAPTCHAに答える",
+ "captcha-apihelp-param-captchaid": "以前のリクエストのCAPTCHA ID",
"confirmedit-preview-line": "行番号",
+ "confirmedit-preview-content": "内容",
+ "confirmedit-preview-validity": "検証",
"confirmedit-preview-valid": "有効",
- "confirmedit-preview-invalid": "無効"
+ "confirmedit-preview-invalid": "無効",
+ "confirmedit-preview-description": "次の表は、このページの行のリストと、有効なIPアドレスかIPアドレスの範囲かを示しています。 回線が有効なIPアドレスまたはIPアドレス範囲の場合、CAPTCHAからホワイトリストになりますが、無効な回線は無視されます。 有効なIPアドレス範囲の例は、69.208.0.0/69.208.0.0/69.208.255.255になります。 IPアドレス範囲の計算については、[https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Range_blocks#Calculating_the_CIDR_suffix 詳細]を参照してください。"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/jv.json b/www/wiki/extensions/ConfirmEdit/i18n/jv.json
index 5fd56cf7..f86f4b24 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/jv.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/jv.json
@@ -7,8 +7,8 @@
"Pras"
]
},
- "captcha-edit": "Kanggo nyunting kaca iki, mangga pecahna tambah-tambahan ing ngisor iki lan lebokna wangsulané ing kothak cedaké ([[Special:Captcha/help|info sabanjuré]]):",
- "captcha-desc": "Nyadhiyakaké tèhnik CAPTCHA kanggo njaga saka spam lan pambedhèk sandhi",
+ "captcha-edit": "Saperlu mbesut kaca iki, sumangga rampungaké ayahan ing ngisor iki lan isi jawabané ing kothaké ([[Special:Captcha/help|katerangan pepaké]]):",
+ "captcha-desc": "Nyepakaké tèknik CAPTCHA kanggo ngreksa saka spam lan pambedhèk-tembung-wadi",
"captcha-label": "CAPTCHA",
"captcha-addurl": "Suntingan panjenengan iku nyertakaké pranala jaba anyar.\nKanggo ngéwangi ngreksa lawan ''spam'' otomatis, tulung pecahna itung-itungan ing ngisor iki lan lebokna kasilna sajroning kothak ([[Special:Captcha/help|info sabanjuré]]):",
"captcha-badlogin": "Kanggo ngreksa lawan parengkahan tembung sandhi otomatis, tulung lebokna tembung utawa kasil itung-itungan gampang ing ngisor sajroning kothak sing wis sumedya ([[Special:Captcha/help|info sabanjuré]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ka.json b/www/wiki/extensions/ConfirmEdit/i18n/ka.json
index 5176ad24..d9a7f9ff 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ka.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ka.json
@@ -24,6 +24,7 @@
"right-skipcaptcha": "CAPTCHA-შემოწმების მოთხოვნილი მოქმედებების შესრულება CAPTCHA-ს გავლის გარეშე",
"captcha-apihelp-param-captchaword": "პასუხი CAPTCHA-ზე",
"captcha-apihelp-param-captchaid": "CAPTCHA-ს ID წინა მოთხოვნიდან",
+ "confirmedit-preview-line": "ხაზის ნომერი",
"confirmedit-preview-content": "შინაარსი",
"confirmedit-preview-validity": "მოქმედების ვადა",
"confirmedit-preview-valid": "სწორი",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/kum.json b/www/wiki/extensions/ConfirmEdit/i18n/kum.json
new file mode 100644
index 00000000..ac70dfad
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/kum.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arsenekoumyk"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/lb.json b/www/wiki/extensions/ConfirmEdit/i18n/lb.json
index 4eac1171..6bb3ef64 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/lb.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/lb.json
@@ -21,7 +21,7 @@
"captcha-disabledinapi": "Dës Aktioun brauch e Captcha, dofir ka se net mat enger API gemaach ginn.",
"captchahelp-title": "Captcha-Hëllef",
"captchahelp-cookies-needed": "Dir musst Cookien an Ärem Browser erlabe fir dat dëst funktionéiert.",
- "captchahelp-text": "Websäiten, déi et jiddwerengem erlaben Ännerunge virzehuelen, sou wéi op dëser Wiki, ginn dacks vu sougenannte Spammer mëssbraucht, déi automatiséiert hir Linken op vill Internetsäite setzen. Sou Spam-Linke kënne wuel geläscht ginn, mä se sinn trotzdem eng grouss Plo.\n\nHeiansdo, besonnesch wann nei Internet-Linken op eng Säit derbäigesat ginn, weist dës Wiki Iech e Bild mat faarwegem oder verzerrtem Text a freet Iech fir déi gewise Wierder anzetipppen. Well dëst eng Aufgab ass déi schwéier ze automatiséieren ass, erlaabt dëst, datt Mënschen hir Ännerunge kënnen agi während déi meescht Spammer an aner Roboter-Attacke kënnen ofgewiert ginn.\n\nLeider kann dat zu Schwierigkeete féiere fir Persounen déi net sou gutt gesinn oder déi text-baséiert oder sprooch-baséiert Browser benotzen.\nZu dësem Zäitpunkt hu mir leider keng audio-Alternativ zu eiser Verfügung.\nKontaktéiert w.e.g. [[Special:ListAdmins|een Administrateur]] fir Hëllef wann dëst iech onerwaarter Weis vu legitimen Editen ofhält.\n\nDréckt op den 'Zréck' Knäppche vun ärem Browser fir an d'Beaarbechtungsfënster zréckzekommen.",
+ "captchahelp-text": "Websäiten, déi et jiddwerengem erlaben Ännerunge virzehuelen, sou wéi op dëser Wiki, ginn dacks vu sougenannte Spammer mëssbraucht, déi automatiséiert hir Linken op vill Internetsäite setzen. Sou Spam-Linke kënne wuel geläscht ginn, mä se sinn trotzdeem eng grouss Plo.\n\nHeiansdo, besonnesch wann nei Internet-Linken op eng Säit dobäigesat ginn, weist dës Wiki Iech e Bild mat faarwegem oder verzerrtem Text a freet Iech fir déi gewise Wierder anzetippen. Well dëst eng Aufgab ass déi schwéier ze automatiséieren ass, erlaabt dëst, datt Mënschen hir Ännerunge kënnen agi während déi meescht Spammer an aner Roboter-Attacke kënnen ofgewiert ginn.\n\nLeider kann dat zu Schwieregkeete féiere fir Persounen déi net sou gutt gesinn oder déi text-baséiert oder sprooch-baséiert Browser benotzen.\nZu dësem Zäitpunkt hu mir leider keng audio-Alternativ zu eiser Verfügung.\nKontaktéiert w.e.g. [[Special:ListAdmins|een Administrateur]] fir Hëllef wann dëst iech onerwaarter Weis vu legitimmen Ännerungen ofhält.\n\nDréckt op den 'Zréck' Knäppche vun ärem Browser fir an d'Beaarbechtungsfënster zréckzekommen.",
"captcha-addurl-whitelist": " #<!-- Dës Linn onverännert loossen --> <pre>\n# Syntax:\n# * Alles vun engem #-Zeechen u bis zum Enn vun där Zeil ass eng Bemierkung\n# * All Zeil déi net eidel ass, ass ee Regex-Fragment, dat nëmme mat Hosten bannent URLe funktionéiert\n #</pre> <!-- Dës Linn onverännert loossen -->",
"right-skipcaptcha": "Aktiounen déi eng Captcha-Aktioun verlaangen ausféieren, ouni dës maachen ze mussen",
"captcha-apihelp-param-captchaword": "Äntwert op de CAPTCHA",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/li.json b/www/wiki/extensions/ConfirmEdit/i18n/li.json
index 062c3442..f1b76159 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/li.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/li.json
@@ -5,13 +5,18 @@
"Ooswesthoesbes"
]
},
- "captcha-edit": "Geer wil dees pazjena bewerke. Veur estebleef 't antjwaord op de óngerstäönde einvawdife som in 't inveurvenster in ([[Special:Captcha/help|mieë informatie]]):",
+ "captcha-edit": "Geer wil dees pazjena bewerke. Veur estebleef 't antjwaord op de óngerstäönde einveljige som in 't inveurvenster in ([[Special:Captcha/help|mieë informatie]]):",
+ "captcha-edit-fail": "Ónjuuste of óntbraekende CAPTCHA.",
"captcha-desc": "Bied CAPTCHA-technieke óm besjörming te beje taenge spam en 't raoje van wachweurd.",
"captcha-label": "CAPTCHA",
- "captcha-addurl": "Uw bewerking bevat nieuwe externe links (URL's). Voer ter bescherming tegen geautomatiseerde spam alstublieft het antwoord op de onderstaande eenvoudige som in in het invoerveld ([[Special:Captcha/help|meer informatie]]):",
- "captcha-badlogin": "Los alstublieft de onderstaande eenvoudige som op en voer het antwoord in het invoervenster in ter bescherming tegen het automatisch kraken van wachtwoorden ([[Special:Captcha/help|meer informatie]]):",
- "captcha-createaccount": "Voer ter bescherming tegen geautomatiseerde spam het antwoord op de onderstaande eenvoudige som in het invoervenster in ([[Special:Captcha/help|meer informatie]]):",
- "captcha-createaccount-fail": "De bevestigingscode ontbreekt of is onjuist.",
+ "captcha-help": "CAPTCHA-oplossing.",
+ "captcha-info-help": "CAPTCHA-ómsjrieving.",
+ "captcha-id-label": "CAPTCHA-id",
+ "captcha-id-help": "Dees waerd mót ónverangerd waere trökgesjik.",
+ "captcha-addurl": "Dien bewirking bevat nuuj extern linke (URL's).\nVeur es besjurming taenge geautomatiseerde spam 't antjwaord op de óngerstäönde opdrach in in 't inveurveld veur dien bewirking op te slaon ([[Special:Captcha/help|mieër infermasie]]):",
+ "captcha-badlogin": "Los de óngerstäönde opdrach op en veur 't antjwaord in in 't inveurvinster ter besjurming taenge 't autematis krake van wachwäörd ([[Special:Captcha/help|mieër informatie]]):",
+ "captcha-createaccount": "Veur t'r besjurming taenge 't aanmake van geautomatiseerde gebroekers 't antjwaord op de óngerstäönde opdrach in in 't inveurvinster ([[Special:Captcha/help|mieër informatie]]):",
+ "captcha-createaccount-fail": "Ónjuuste of óntbraekende CAPTCHA.",
"captcha-create": "U wilt een nieuwe pagina aanmaken. Voer het antwoord op de onderstaande eenvoudige som in het invoervenster in ([[Special:Captcha/help|meer informatie]]):",
"captcha-sendemail": "Veur ter besjerming taege geautomatiseerde spam 't antjwaord op de ongerstaonde einvawdige som in 't inveurvinster in ([[Special:Captcha/help|mier informatie]]):",
"captcha-sendemail-fail": "De bevestigingscode ontbrèk of is ónjuus.",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/lv.json b/www/wiki/extensions/ConfirmEdit/i18n/lv.json
index 7de1c82f..ee637e9f 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/lv.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/lv.json
@@ -16,6 +16,7 @@
"captcha-createaccount": "Lai pasargātos no automātiskas mēstuļošanas, Tev reģistrējoties ir jāieraksta šī vienādojuma rezultāts: <br />([[Special:Captcha/help|Kāpēc tā?]])",
"captcha-createaccount-fail": "Nepareizs apstiprinājuma kods vai arī tas nav ievadīts.",
"captcha-create": "Lai izveidotu šo lapu, atrisini šo vienādojumu un rezulātu ieraksti šajā lodziņā: <br />([[Special:Captcha/help|Kāpēc tā?]])",
+ "captchahelp-title": "CAPTCHA palīdzība",
"captchahelp-cookies-needed": "Lai šis darbotos, pārlūkprogrammā jābūt iespējotām (''enabled'') sīkdatnēm (''cookies'').",
"captchahelp-text": "Interneta lapas, kurās iespējams pievienot tekstu, kā šajā wiki, bieži cieš no mēstuļotājiem, kuri izmanto automatizētus līdzekļus, lai pievienotu savus saites daudzās jo daudzās interneta lapās.\nKaut arī šīs saites var viegli dzēst, tomēr tās ir nozīmīgs traucēklis.\n\nReizēm, jo īpaši pievienojot jaunas interneta saites, wiki programmatūra var parādīt Tev attēlu, kurā ir krāsains vai sagrozīts teksts. Šis teksts ir jāpārraksta un to ir ļoti grūti izdarīt automātiski, tā apgrūtinot lielāko daļu mēstuļotāju, savukārt gandrīz visi parastie lietotāji to var izdarīt bez grūtībām.\n\nDiemžēl tas var apgrūtināt lietotājus, kuriem ir redzes traucējumi vai kuri izmanto teksta pārlūkus vai dzirdes pārlūkus. Šobrīd nav pieejama audio alternatīva, bet sazinies ar [[Special:ListAdmins|wiki administratoriem]], ja tas liedz Tev veikt labi domātus papildinājumus.\n\nSpied pārlūka pogu \"Atpakaļ\" (''Back''), lai atgrieztos iepriekšējā lapā.",
"confirmedit-preview-content": "Saturs",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ml.json b/www/wiki/extensions/ConfirmEdit/i18n/ml.json
index 8f60c023..29c92b4e 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ml.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ml.json
@@ -5,23 +5,33 @@
"Shijualex"
]
},
- "captcha-edit": "ഈ താൾ തിരുത്തുവാൻ, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ലഘു ഗണിത ക്രിയ ചെയ്ത് അതിന്റെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
+ "captcha-edit": "ഈ താൾ തിരുത്തുവാൻ, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ക്രിയ ചെയ്ത് അതിന്റെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
"captcha-edit-fail": "തെറ്റായതോ ലഭ്യമല്ലാത്തതോ ആയ കാപ്ച്ച.",
"captcha-desc": "പാഴെഴുത്ത് ഉൾപ്പെടുത്തലിനും രഹസ്യവാക്ക് ഊഹിക്കലിനുമെതിരെ സംരക്ഷണം തരുന്ന കാപ്ച സംവിധാനം നൽകുന്നു",
"captcha-label": "കാപ്ച",
- "captcha-addurl": "താങ്കളുടെ തിരുത്തലിൽ പുറം കണ്ണികൾ ഉൾപ്പെട്ടിരിക്കുന്നു.\nയാന്ത്രികമായി പാഴെഴുത്തുൾപ്പെടുത്തുന്നതിൽ നിന്നും വിക്കി സം‌രക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ലഘു ഗണിത ക്രിയ ചെയ്ത് അതിന്റെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
- "captcha-badlogin": "യാന്ത്രികമായി രഹസ്യവാക്ക് പൊളിക്കുന്നതിൽ നിന്നും വിക്കി സംരക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ലഘു ഗണിത ക്രിയ ചെയ്ത്, ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
- "captcha-createaccount": "യാന്ത്രികമായി അംഗത്വം സൃഷ്ടിക്കുന്നതിൽ നിന്നും വിക്കി സം‌രക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ലഘു ഗണിത ക്രിയ ചെയ്ത് അതിന്റെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
+ "captcha-help": "കാപ്ചയുടെ ഉത്തരം.",
+ "captcha-info-help": "കാപ്ചയുടെ വിശദീകരണം.",
+ "captcha-id-label": "കാപ്ച ഐ.ഡി.",
+ "captcha-id-help": "ഈ വില മാറ്റമില്ലാതെ തിരിച്ചയക്കേണ്ടതാണ്.",
+ "captcha-addurl": "താങ്കളുടെ തിരുത്തലിൽ പുറം കണ്ണികൾ ഉൾപ്പെട്ടിരിക്കുന്നു.\nയാന്ത്രികമായി പാഴെഴുത്തുൾപ്പെടുത്തുന്നതിൽ നിന്നും വിക്കി സം‌രക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ക്രിയ ചെയ്ത് അതിന്റെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
+ "captcha-badlogin": "യാന്ത്രികമായി രഹസ്യവാക്ക് പൊളിക്കുന്നതിൽ നിന്നും വിക്കി സംരക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ക്രിയ ചെയ്ത്, ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
+ "captcha-createaccount": "യാന്ത്രികമായി അംഗത്വം സൃഷ്ടിക്കുന്നതിൽ നിന്നും വിക്കി സം‌രക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ചെയ്ത് അതിന്റെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ ടൈപ്പു ചെയ്യുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
"captcha-createaccount-fail": "തെറ്റായതോ ലഭ്യമല്ലാത്തതോ ആയ കാപ്ച്ച.",
- "captcha-create": "ഈ താൾ സൃഷ്ടിക്കുവാൻ, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന കൂട്ടൽ ക്രിയയുടെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ എഴുതുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
- "captcha-sendemail": "യാന്ത്രികമായ പാഴെഴുത്ത് ഉൾപ്പെടുത്തുന്നതിൽ നിന്നും വിക്കി സംരക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ലഘു ഗണിത ക്രിയ ചെയ്ത്, ഉത്തരം പെട്ടിയിൽ എഴുതുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
+ "captcha-create": "ഈ താൾ സൃഷ്ടിക്കുവാൻ, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ക്രിയയുടെ ഉത്തരം താഴെയുള്ള പെട്ടിയിൽ എഴുതുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
+ "captcha-sendemail": "യാന്ത്രികമായ പാഴെഴുത്ത് ഉൾപ്പെടുത്തുന്നതിൽ നിന്നും വിക്കി സംരക്ഷിക്കുന്നതിന്റെ ഭാഗമായി, ദയവായി താഴെ കൊടുത്തിരിക്കുന്ന ക്രിയ ചെയ്ത്, ഉത്തരം പെട്ടിയിൽ എഴുതുക ([[Special:Captcha/help|കൂടുതൽ വിവരങ്ങൾ]]):",
"captcha-sendemail-fail": "തെറ്റായതോ ലഭ്യമല്ലാത്തതോ ആയ കാപ്ച്ച.",
"captcha-disabledinapi": "ഈ പ്രവൃത്തി പൂർണ്ണമാകാൻ കാപ്ച ആവശ്യമാണ്, അതുകൊണ്ടിത് എ.പി.ഐ. ഉപയോഗിച്ച് ചെയ്യാൻ കഴിയില്ല.",
+ "captcha-error": "ആന്തരികപിഴവിനാൽ കാപ്ച പരിശോധന പരാജയപ്പെട്ടു:$1",
"captchahelp-title": "കാപ്ച്ച സഹായം",
"captchahelp-cookies-needed": "ഇതു പ്രവർത്തിക്കണമെങ്കിൽ താങ്കളുടെ ബ്രൗസറിൽ കുക്കികൾ സജ്ജീകരിച്ചിരിക്കണം.",
"captchahelp-text": "ഈ വിക്കിപോലെ പൊതുജനങ്ങളിൽ നിന്നും പ്രസിദ്ധപ്പെടുത്തലുകൾ സ്വീകരിക്കുന്ന വെബ്‌‌സൈറ്റുകൾ, സ്വയം പ്രവർത്തിക്കുന്ന ഉപകരണങ്ങൾ ഉപയോഗിച്ച് കണ്ണികളും മറ്റും പ്രസിദ്ധപ്പെടുത്തുന്ന സ്പാമർമാർ സാധാരണ ദുരുപയോഗം ചെയ്യാറുണ്ട്.\nഇത്തരത്തിലുള്ള പാഴെഴുത്ത് കണ്ണികൾ നീക്കംചെയ്യപ്പെട്ടുപോകുമെങ്കിലും, അവ ശരിക്കും ശല്യമാണ്.\n\nചിലപ്പോൾ, പ്രത്യേകിച്ച് ഒരു വെബ് കണ്ണി താളിൽ കൂട്ടിച്ചേർക്കുമ്പോൾ, നിറങ്ങൾ ചേർത്തതോ വികലമാക്കിയതോ ആയ എഴുത്തുകൾ താങ്കളെ കാണിച്ച് അവ ടൈപ്പ് ചെയ്യാൻ താങ്കളോട് ആവശ്യപ്പെട്ടേക്കാം.\nഇത് മനുഷ്യസഹായമില്ലാതെ ചെയ്യാൻ ബുദ്ധിമുട്ടായതിനാൽ, ശരിക്കും മനുഷ്യരായിട്ടുള്ളവർക്ക് തങ്ങളുദ്ദേശിക്കുന്നത് ചേർക്കാനും അതേസമയം ബഹുഭൂരിപക്ഷം സ്പാമർമാരേയും യന്ത്രങ്ങളുപയോഗിച്ച് ആക്രമിക്കുന്നവരേയും തടയാനും കഴിയുന്നതാണ്.\n\nദൗർഭാഗ്യകരമെന്നു പറയട്ടെ ഇത് ചിലപ്പോൾ ദൃഷ്ടിവൈകല്യം കൊണ്ടോ മറ്റോ, എഴുത്തുകൾ മാത്രമനുവദിക്കുന്ന ബ്രൗസറുകൾ ഉപയോഗിക്കുന്നവർ, ശബ്ദം കേട്ട് മനസ്സിലാക്കുന്നവർ തുടങ്ങിയവർക്ക് ബുദ്ധിമുട്ടായേക്കാം.\nഇപ്പോൾ ഞങ്ങൾക്ക് ഇതിനു പകരം ശബ്ദം നൽകുന്ന സംവിധാനമില്ല.\n\nഇത് ന്യായമായ പ്രസിദ്ധപ്പെടുത്തലുകൾ ഇടുന്നതിൽ നിന്നും അപ്രതീക്ഷിതമായി താങ്കളെ തടയുന്നുവെങ്കിൽ ദയവായി [[Special:ListAdmins|സൈറ്റിന്റെ കാര്യനിർവാഹകരെ]] ബന്ധപ്പെടുക.\n\nബ്രൗസറിലെ 'ബാക്ക്' ബട്ടൺ ഞെക്കിയാൽ താങ്കൾക്ക് താൾ തിരുത്തുവാനുള്ള സംവിധാനത്തിലേയ്ക്ക് മടങ്ങിപ്പോകാവുന്നതാണ്.",
"captcha-addurl-whitelist": " #<!-- ഈ വരി ഇതുപോലെ തന്നെ നിലനിർത്തുക --> <pre>\n# സിന്റാക്സ് താഴെ കാണുന്ന പ്രകാരമാണ്‌:\n# * \"#\" എന്ന അക്ഷരത്തിൽ തുടങ്ങുന്ന എല്ലാ വരികളും കുറിപ്പുകളായിരിക്കും\n# * ശൂന്യമല്ലാത്ത എല്ലാ വരികളും യു.ആർ.എല്ലിനു അകത്തെ ഹോസ്റ്റുകളുമായി മാത്രം ഒത്തുനോക്കുന്ന റെജെക്സ് ഘടകങ്ങളായിരിക്കും\n #</pre> <!-- ഈ വരി ഇതുപോലെ തന്നെ നിലനിർത്തുക -->",
"right-skipcaptcha": "കാപ്ച ഉപയോഗിക്കേണ്ട പ്രവൃത്തികൾ കാപ്ചയിലൂടെ കടന്നു പോകാതെ തന്നെ ചെയ്യാൻ കഴിയുക",
"captcha-apihelp-param-captchaword": "കാപ്ച്ചയ്ക്ക് മറുപടി നൽകുക",
- "captcha-apihelp-param-captchaid": "പഴയ അഭ്യർത്ഥനയിൽ നിന്നുള്ള കാപ്ച്ച ഐ.ഡി."
+ "captcha-apihelp-param-captchaid": "പഴയ അഭ്യർത്ഥനയിൽ നിന്നുള്ള കാപ്ച്ച ഐ.ഡി.",
+ "confirmedit-preview-line": "വരികളുടെ ക്രമസംഖ്യ",
+ "confirmedit-preview-content": "ഉള്ളടക്കം",
+ "confirmedit-preview-validity": "സാധുത",
+ "confirmedit-preview-valid": "സാധുതയുള്ളത്",
+ "confirmedit-preview-invalid": "അസാധു"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/mwl.json b/www/wiki/extensions/ConfirmEdit/i18n/mwl.json
new file mode 100644
index 00000000..5ccb1605
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/mwl.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/myv.json b/www/wiki/extensions/ConfirmEdit/i18n/myv.json
new file mode 100644
index 00000000..6859e8e7
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/myv.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Rueter"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/na.json b/www/wiki/extensions/ConfirmEdit/i18n/na.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/na.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/niu.json b/www/wiki/extensions/ConfirmEdit/i18n/niu.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/niu.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/nys.json b/www/wiki/extensions/ConfirmEdit/i18n/nys.json
new file mode 100644
index 00000000..663f8d84
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/nys.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/or.json b/www/wiki/extensions/ConfirmEdit/i18n/or.json
index e7f61d84..e7d50f6c 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/or.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/or.json
@@ -3,7 +3,8 @@
"authors": [
"Jnanaranjan Sahu",
"Psubhashish",
- "Shisir 1945"
+ "Shisir 1945",
+ "Matma Rex"
]
},
"captcha-edit": "ଏହି ପୃଷ୍ଠାଟିକୁ ବଦଳାଇବା ନିମନ୍ତେ, ତଳେ ଥିବା ସହଜ ଅଙ୍କଟିର ସମାଧାନ କରନ୍ତୁ ଓ ଘରଟିରେ ଫଳାଫଳ ଦିଅନ୍ତୁ ([[Special:Captcha/help|ଅଧିକ ଜାଣନ୍ତୁ]]):",
@@ -20,6 +21,6 @@
"captchahelp-title": "CAPTCHA ସହଯୋଗ",
"captchahelp-cookies-needed": "ଏହି କାମଟି କରିବା ପାଇଁ ଆପଣଙ୍କ ବ୍ରାଉଜରରେ କୁକି ସଚଳ କରିବାକୁ ପଡ଼ିବ ।",
"captchahelp-text": "ଏହି ଉଇକି ପରି ଜନସାଧାରଣଙ୍କ ଠାରୁ ଲେଖା ଗ୍ରହଣ କରୁଥିବା ସାଇଟ ସବୁରେ ବହୁବାର ସ୍ପାମମାନେ ଆପେଆପେ ନିଜ ନିଜର ଉପକରଣ ମାଧ୍ୟମରେ ଅଦରକାରୀ ଲିଙ୍କମାନ ଦେଇଥାନ୍ତି ।\nଯଦିଓ ସ୍ପାମ ଲିଙ୍କ ସବୁ ହଟାଇଦିଆଯାଇ ପାରିବ ସେସବୁ ବହୁ ଅସୁବିଧା ତିଆରି କରିଥାଏ ।\n\nବେଳେବେଳେ, ବିଶେଷ କରି ଏକ ପୃଷ୍ଠାରେ ନୂଆ ୱେବ ଲିଙ୍କ ଦେଲାବେଳେ ଉଇକିଟି ଆପଣଙ୍କୁ ଏକ ରଙ୍ଗିନ ବା ଭଙ୍ଗାରୁଜା ଲେଖା ଦେଖାଇ ଆପଣଙ୍କୁ ତାହାକୁ ଟାଇପ କରିବାକୁ କହିଥାଏ ।\nଯେହେତୁ ଏହି କାମକୁ ମଣିଷ ବିନା ଆପେଆପେ କରିବା ସମ୍ଭବପର ନୁହେଁ, ଏହି ବାସ୍ତବ ମଣିଷମାନଙ୍କୁ ଲେଖିବାରେ ସହଯୋଗ କରିଥାଏ ଓ ସ୍ପାମର ଓ ବାକି ରୋବଟ ଆକ୍ରମଣକୁ ପ୍ରତିହତ କରିପାରେ ।\n\nଅପରାପକ୍ଷେ ଏହା ସୀମିତ ଦୃଷ୍ଟିଥିବା ବା ଲେଖା କିମ୍ବା କଥା କୁହ ବ୍ରାଉଜର ବ୍ୟବହାର କରୁଥିବା ସଭ୍ୟମାନଙ୍କୁ ଅସୁବିଧାରେ ପକାଇଥାଏ ।\nଅଧୁନା ଏଠାରେ ଧ୍ୱନିଚଳିତ ବିକଳ୍ପଟିଏ ଦେଇନାହୁଁ ।\nଆପଣଙ୍କୁ ଉପଯୁକ୍ତ ଲେଖା ଦେବାରେ ସହଯୋଗ କରିବା ନିମନ୍ତେ ଦୟାକରି [[Special:ListAdmins|ସାଇଟ ପରିଛା]]ମାନଙ୍କୁ ଯୋହଗାଯୋଗ କରନ୍ତୁ ।\n\nଆପଣଙ୍କ ବ୍ରାଉଜରରେ ଥିବା 'back' ଚିପି ପୃଷ୍ଠା ସମ୍ପାଦକକୁ ଲେଉଟିଯାନ୍ତୁ ।",
- "captcha-addurl-whitelist": " #<!—ଏହି ଧାଡ଼ିଟି ଯେମିତି ଅଛି ସେମିତି ଛାଡ଼ି ଦିଅନ୍ତୁ --> <pre>\n# ତଳେ ସିଣ୍ଟାକ୍ସଟି ଦିଆଗଲା:\n# * ଧାଡ଼ିର ଶେଷରେ \"#\" ଚିହ୍ନ ଦିଆଥିବା ସବୁକିଛି ଏକ ମତାମତ\n# * ପ୍ରତିଟି ଅଣ-ଖାଲି ଧାଡ଼ି ଏକ regex ଖଣ୍ଡ ଯାହା କେବଳ URL ବାହାରେ ଥିବା ହୋଷ୍ଟ ମାନଙ୍କ ସଙ୍ଗେ ମେଲ ଖାଇଥାଏ\n #</pre> <!-- ଏହି ଧାଡ଼ିଟି ଯେମିତି ଅଛି ସେମିତି ଛାଡ଼ି ଦିଅନ୍ତୁ -->",
+ "captcha-addurl-whitelist": " #<!-- ଏହି ଧାଡ଼ିଟି ଯେମିତି ଅଛି ସେମିତି ଛାଡ଼ି ଦିଅନ୍ତୁ --> <pre>\n# ତଳେ ସିଣ୍ଟାକ୍ସଟି ଦିଆଗଲା:\n# * ଧାଡ଼ିର ଶେଷରେ \"#\" ଚିହ୍ନ ଦିଆଥିବା ସବୁକିଛି ଏକ ମତାମତ\n# * ପ୍ରତିଟି ଅଣ-ଖାଲି ଧାଡ଼ି ଏକ regex ଖଣ୍ଡ ଯାହା କେବଳ URL ବାହାରେ ଥିବା ହୋଷ୍ଟ ମାନଙ୍କ ସଙ୍ଗେ ମେଲ ଖାଇଥାଏ\n #</pre> <!-- ଏହି ଧାଡ଼ିଟି ଯେମିତି ଅଛି ସେମିତି ଛାଡ଼ି ଦିଅନ୍ତୁ -->",
"right-skipcaptcha": "CAPTCHA ଭିତରେ ନଯାଇ CAPTCHA ଦେଇ ସଞ୍ଚାଳିତ କାମ କରିବେ"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/pih.json b/www/wiki/extensions/ConfirmEdit/i18n/pih.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/pih.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/pt.json b/www/wiki/extensions/ConfirmEdit/i18n/pt.json
index 8baabf1b..1fb4f4c7 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/pt.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/pt.json
@@ -6,7 +6,8 @@
"Luckas",
"Malafaya",
"555",
- "Vitorvicentevalente"
+ "Vitorvicentevalente",
+ "Athena in Wonderland"
]
},
"captcha-edit": "Para editar esta página resolva a tarefa apresentada abaixo e introduza a resposta na caixa ([[Special:Captcha/help|mais informações]]):",
@@ -17,7 +18,7 @@
"captcha-info-help": "Descrição do CAPTCHA.",
"captcha-id-label": "Identificador do CAPTCHA",
"captcha-id-help": "Este valor deve ser devolvido inalterado.",
- "captcha-addurl": "A sua edição introduziu links externos novos.\nPara proteger a wiki contra sistemas automatizados de inserção de <i>spam</i>, antes de gravar a sua edição pedimos que resolva a tarefa apresentada abaixo e introduza a resposta na caixa ([[Special:Captcha/help|mais informações]]):",
+ "captcha-addurl": "A sua edição introduziu hiperligações externas novas.\nPara proteger a wiki contra sistemas automatizados de inserção de <i>spam</i>, antes de gravar a sua edição pedimos que resolva a tarefa apresentada abaixo e introduza a resposta na caixa ([[Special:Captcha/help|mais informações]]):",
"captcha-badlogin": "Para proteger a wiki contra sistemas automatizados de descoberta de palavras-passe, pedimos que resolva a tarefa apresentada abaixo e introduza a resposta na caixa ([[Special:Captcha/help|mais informações]]):",
"captcha-createaccount": "Para proteger a wiki contra sistemas automatizados de criação de contas, pedimos que resolva a tarefa apresentada abaixo e introduza a resposta na caixa ([[Special:Captcha/help|mais informações]]):",
"captcha-createaccount-fail": "O código CAPTCHA está incorreto ou não foi preenchido.",
@@ -28,7 +29,7 @@
"captcha-error": "A verificação CAPTCHA falhou devido ao erro interno: $1",
"captchahelp-title": "Ajuda sobre o CAPTCHA",
"captchahelp-cookies-needed": "É necessário possibilitar o uso de ''cookies'' no seu browser para que o ''captcha'' funcione.",
- "captchahelp-text": "Sites na internet abertos a edição pública, como é o caso desta wiki, são frequentemente abusados por ''spammers'' que usam ferramentas automatizadas para inserção em massa de links, em muitos sites.\nEmbora esses links possam ser removidos, representam um incómodo significativo.\n\nPor vezes, especialmente quando introduzir links externos novos numa página, a wiki apresentará a imagem de um texto colorido ou distorcido e pedirá que escreva o texto apresentado.\nPorque a interpretação do texto apresentado nas imagens é uma tarefa difícil de automatizar, este pedido feito pela wiki permite que a maioria das pessoas façam as suas edições, ao mesmo tempo que inibe edições feitas por ''spammers'' e outros mecanismos automatizados.\n\nInfelizmente, esta funcionalidade pode revelar-se um inconveniente para utilizadores com limitações visuais ou que utilizam browsers baseados em texto ou voz.\nNeste momento, não temos disponível uma alternativa em áudio.\nCaso esta funcionalidade esteja a impedi-lo de fazer edições legítimas, contacte os [[Special:ListAdmins|administradores]] para assistência, por favor.\n\nClique o botão \"voltar\" do seu browser para voltar à página de edição.",
+ "captchahelp-text": "Sítios na Internet abertos a edição pública, como é o caso desta wiki, são frequentemente abusados por ''spammers'' que usam ferramentas automatizadas para inserção em massa de hiperligações, em muitos sítios.\nEmbora essas hiperligações possam ser removidas, representam um incómodo significativo.\n\nPor vezes, especialmente quando introduzir hiperligações externas novas numa página, a wiki apresentará a imagem de um texto colorido ou distorcido e pedirá que escreva o texto apresentado.\nPorque a interpretação do texto apresentado nas imagens é uma tarefa difícil de automatizar, este pedido feito pela wiki permite que a maioria das pessoas façam as suas edições, ao mesmo tempo que inibe edições feitas por ''spammers'' e outros mecanismos automatizados.\n\nInfelizmente, esta funcionalidade pode revelar-se um inconveniente para utilizadores com limitações visuais ou que utilizam browsers baseados em texto ou voz.\nNeste momento, não temos disponível uma alternativa em áudio.\nCaso esta funcionalidade esteja a impedi-lo de fazer edições legítimas, contacte os [[Special:ListAdmins|administradores]] para assistência, por favor.\n\nClique o botão \"voltar\" do seu browser para voltar à página de edição.",
"captcha-addurl-whitelist": " #<!-- deixe esta linha exactamente como está --> <pre>\n# A sintaxe é a seguinte:\n# * Tudo desde um símbolo de cardinal (#) até ao fim da linha é um comentário\n# * Qualquer linha que não esteja em branco é um fragmento de expressão regular (regex) que será comparado com o servidor dos URL\n #</pre> <!-- deixe esta linha exactamente como está -->",
"right-skipcaptcha": "Executar operações desencadeadoras do CAPTCHA sem ter que passar pelo CAPTCHA",
"captcha-apihelp-param-captchaword": "Resposta ao CAPTCHA",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/qqq.json b/www/wiki/extensions/ConfirmEdit/i18n/qqq.json
index 38e6ac29..0a40bb12 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/qqq.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/qqq.json
@@ -42,7 +42,7 @@
"captcha-apihelp-param-captchaid": "{{doc-apihelp-param|description=the \"captchaid\" parameter added by [[mw:Extension:ConfirmEdit]]|noseealso=1}}\nSee also {{msg-mw|captcha-apihelp-param-captchaword}}",
"confirmedit-preview-line": "Used as a table heading for the edit preview of [[MediaWiki:Captcha-ip-whitelist]] to indicate the line number (1, 2, 3, ...).",
"confirmedit-preview-content": "Used as a table heading for the edit preview of [[MediaWiki:Captcha-ip-whitelist]] to indicate the content of a line.\n{{Identical|Content}}",
- "confirmedit-preview-validity": "Used as a table heading for the edit preview of [[MediaWiki:Captcha-ip-whitelist]] to indicate the validity of a content of a line (if it's an IP address or not).",
+ "confirmedit-preview-validity": "Used as a table heading for the edit preview of [[MediaWiki:Captcha-ip-whitelist]] to indicate the validity of a content of a line (if it's an IP address or not).\n{{Identical|Validity}}",
"confirmedit-preview-valid": "Used to indicate a valid IP address in the edit preview of [[MediaWiki:Captcha-ip-whitelist]].\n{{Identical|Valid}}",
"confirmedit-preview-invalid": "Used to indicate an invalid IP address in the edit preview of [[MediaWiki:Captcha-ip-whitelist]].\n{{Identical|Invalid}}",
"confirmedit-preview-description": "Explains the edit preview of [[MediaWiki:Captcha-ip-whitelist]]."
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ro.json b/www/wiki/extensions/ConfirmEdit/i18n/ro.json
index ab415109..fe842595 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ro.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ro.json
@@ -5,18 +5,19 @@
"Firilacroco",
"KlaudiuMihaila",
"Mihai",
- "Minisarm"
+ "Minisarm",
+ "Strainu"
]
},
- "captcha-edit": "Editarea include legături externe noi. Pentru a evita spam-ul automat, vă rugăm să rezolvați adunarea de mai jos și introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
+ "captcha-edit": "Pentru a edita această pagină, vă rugăm să rezolvați sarcina de mai jos și să introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
"captcha-desc": "Oferă implementare de tip CAPTCHA împotriva spamului și încercărilor de aflare a parolelor",
"captcha-label": "CAPTCHA",
- "captcha-addurl": "Modificarea dumneavoastră include legături externe noi.\nPentru a proteja wikiul împotriva spamului automat, vă rugăm să rezolvați adunarea de mai jos și introduceți rezultatul în căsuță pentru a salva modificarea ([[Special:Captcha/help|detalii]]):",
- "captcha-badlogin": "Ca măsură de protecție împotriva spargerii de parole, vă rugăm să rezolvați adunarea de mai jos și introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
- "captcha-createaccount": "Pentru a evita crearea automată de conturi, vă rugăm să rezolvați adunarea de mai jos și introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
- "captcha-createaccount-fail": "Cod de confirmare incorect sau lipsă.",
- "captcha-create": "Editarea include legături externe noi. Pentru a evita spam-ul automat, vă rugăm să rezolvați adunarea de mai jos și introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
- "captcha-sendemail": "Pentru a proteja wikiul împotriva roboților de spam, vă rugăm să rezolvați operația simplă de mai jos și să introduceți răspunsul în căsuță ([[Special:Captcha/help|mai multe detalii]]):",
+ "captcha-addurl": "Modificarea dumneavoastră include legături externe noi.\nPentru a proteja wikiul împotriva spamului automat, vă rugăm să rezolvați sarcina de mai jos și introduceți rezultatul în căsuță pentru a salva modificarea ([[Special:Captcha/help|detalii]]):",
+ "captcha-badlogin": "Ca măsură de protecție împotriva spargerii de parole, vă rugăm să rezolvați sarcina de mai jos și să introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
+ "captcha-createaccount": "Pentru a evita crearea automată de conturi, vă rugăm să rezolvați sarcina de mai jos și să introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
+ "captcha-createaccount-fail": "CAPTCHA incorect sau lipsă.",
+ "captcha-create": "Pentru a crea pagina, vă rugăm să rezolvați sarcina de mai jos și să introduceți rezultatul în căsuță ([[Special:Captcha/help|detalii]]):",
+ "captcha-sendemail": "Pentru a proteja wikiul împotriva roboților de spam, vă rugăm să rezolvați sarcina de mai jos și să introduceți răspunsul în căsuță ([[Special:Captcha/help|mai multe detalii]]):",
"captcha-sendemail-fail": "Codul de confirmare lipsește sau este incorect.",
"captcha-disabledinapi": "Această acțiune necesită rezolvarea unui captcha, deci nu poate fi efectuată prin API.",
"captchahelp-title": "Despre „Captcha”",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/sah.json b/www/wiki/extensions/ConfirmEdit/i18n/sah.json
index 3d57cf46..947fcf54 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/sah.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/sah.json
@@ -5,10 +5,10 @@
]
},
"captcha-edit": "Сирэйи уларытыаххын баҕардаххына, манна баар примеры суоттаа уонна эппиэтин аналлаах сиргэ суруй ([[Special:Captcha/help|сиһилии]]):",
- "captcha-desc": "CAPTCHA көмөтүнэн спаамтан уонна киирии тылы уорууттан көмүскэли хааччыйар",
+ "captcha-desc": "CAPTCHA көмөтүнэн спаамтан уонна аһарыгы уорууттан көмүскэли хааччыйар",
"captcha-label": "CAPTCHA",
"captcha-addurl": "Тас саайка ыйынньык туруорбуккун; \nспаамтан көмүскэнэр соруктаах суолу толор - ойууга баар буукубалары хатылаа: <br />\n([[Special:Captcha/help|Сиһилии]])",
- "captcha-badlogin": "Киирии тылы аптамаат алдьаппатын туһугар оҥоһуллубут харыстыыр дьайыыны толор, манна баар примеры суоттаа уонна эппиэтин анал сиргэ суруй ([[Special:Captcha/help|сиһилии]]):",
+ "captcha-badlogin": "Аһарыгы аптамаат алдьаппатын туһугар оҥоһуллубут харыстыыр дьайыыны толор, манна баар холобуру суоттаа уонна хоруйун анал сиргэ суруй ([[Special:Captcha/help|сиһилии]]):",
"captcha-createaccount": "Бэлиэтэнэргэр аптамаатынан алдьатыыттан (спаамтан) харыстыыр соруктаах дьайыыны оҥор, ойууга көстөр буукубалары анал сиргэ киллэр:<br />\n([[Special:Captcha/help|Сиһилии]])",
"captcha-createaccount-fail": "Бигэргэтии куода суох эбэтэр атын.",
"captcha-create": "Сирэйи оҥорорго бу примеры суоттаа ([[Special:Captcha/help|сиһилии]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/sat.json b/www/wiki/extensions/ConfirmEdit/i18n/sat.json
new file mode 100644
index 00000000..1a082682
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/sat.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ramjit Tudu"
+ ]
+ },
+ "captcha-label": "CAPTCHA",
+ "confirmedit-preview-line": "ᱫᱷᱟᱹᱲ ᱮᱞ"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/sm.json b/www/wiki/extensions/ConfirmEdit/i18n/sm.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/sm.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/tay.json b/www/wiki/extensions/ConfirmEdit/i18n/tay.json
index 82880fb3..473a5449 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/tay.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/tay.json
@@ -6,5 +6,7 @@
]
},
"captcha-label": "CAPTCHA",
+ "captcha-id-label": "Yencng mima ID",
+ "captcha-apihelp-param-captchaword": "Brwaniy quw yencng ma",
"confirmedit-preview-content": "Tay qsahuy"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/tg-cyrl.json b/www/wiki/extensions/ConfirmEdit/i18n/tg-cyrl.json
index 46ae26f0..2acbd783 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/tg-cyrl.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/tg-cyrl.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Ibrahim"
+ "Ibrahim",
+ "Matma Rex"
]
},
"captcha-edit": "Барои вироиши ин мақола, лутфан ҳосили ҷамъи зеринро ҳисоб кунед ва натиҷаро дар ҷаъба ворид кунед ([[Special:Captcha/help|иттилооти бештар]]):",
@@ -14,5 +15,5 @@
"captchahelp-title": "Роҳнамои Captcha",
"captchahelp-cookies-needed": "Барои кор кардани он, шумо бояд кукиҳои мурургаратонро фаъол кунед.",
"captchahelp-text": "Сомонаҳое, ки имкони тағйир тавассути ҳамагон дар онҳо вуҷуд дорад, монанди ин вики, гоҳ ё ногоҳ тавассути ҳаразнигориҳое, ки тавассути абзорҳои худкор пайванди худро дар чандин сомонаҳо мефиристанд, мавриди сӯъистифода қарор мегиранд.\n\nДар пораи аз маворид, ба вижа замоне, ки як пайванди интернетии ҷадид ба саҳифа изофа мешавад, вики метавонад, як тасвир аз ҳуруфи рангӣ ё матни бенурро ба шумо нишон бидиҳад ва аз шумо ворид кардани калимаи нишондодашударо пурсон мешавад. Ба хотири ин ки анҷоми ин кор ба шакли худкор душвор аст, ин амал ба аксари инсонҳое иҷозат медиҳад, ки ба ирсоли матолиб бипардозанд, дар ҳоле ки бештар роботҳои ҳамлакунанда ва ҳаразнигорҳоро мутавақиф мекунад.\n\nМутассифона ин равиш мумкин аст, корбароне, ки қувваи босираашон суст ё аз мурургарҳои матнӣ ё овозӣ истифода мекунанд, дучори маҳдудиятҳое бикунад. Дар ҳоли ҳозир ҳеҷ чойгузини савтӣ барои ин равиш мавҷуд нест. Чунончи ин масъала шуморо дучори маҳдудияте дур аз интизор дар ирсоли навиштаҳои миҷоз мекунад, бо мудирони сомона оиди кӯмак тамос бигиред.\n\nДар муругаратон тугмаи 'бозгашт'-ро бо пахш кардан ба саҳифаи вироишгар баргардед.",
- "captcha-addurl-whitelist": " #<!—ин сатрро ҳамон гуна, ки ҳаст раҳо кунед --> <pre>\n# Қоида ба ин шакл аст:\n# * Ҳама чиз аз \"#\" то охири сатр як тавзеҳ ба назар гирифта мешавад\n# * Ҳар сатре, ки холӣ набошад як қитъа дар назар гирифта мешавад, ки фақат бо номи мизбони интернетӣ санҷида мешавад\n #</pre> <!-- ин сатрро ҳамон гуна, ки ҳаст раҳо кунед-->"
+ "captcha-addurl-whitelist": " #<!-- ин сатрро ҳамон гуна, ки ҳаст раҳо кунед --> <pre>\n# Қоида ба ин шакл аст:\n# * Ҳама чиз аз \"#\" то охири сатр як тавзеҳ ба назар гирифта мешавад\n# * Ҳар сатре, ки холӣ набошад як қитъа дар назар гирифта мешавад, ки фақат бо номи мизбони интернетӣ санҷида мешавад\n #</pre> <!-- ин сатрро ҳамон гуна, ки ҳаст раҳо кунед-->"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/tg-latn.json b/www/wiki/extensions/ConfirmEdit/i18n/tg-latn.json
index deb1ee0e..fc3f7d5b 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/tg-latn.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/tg-latn.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Liangent"
+ "Liangent",
+ "Matma Rex"
]
},
"captcha-edit": "Baroi viroişi in maqola, lutfan hosili çam'i zerinro hisob kuned va natiçaro dar ça'ba vorid kuned ([[Special:Captcha/help|ittilooti beştar]]):",
@@ -14,5 +15,5 @@
"captchahelp-title": "Rohnamoi Captcha",
"captchahelp-cookies-needed": "Baroi kor kardani on, şumo bojad kukihoi mururgaratonro fa'ol kuned.",
"captchahelp-text": "Somonahoe, ki imkoni taƣjir tavassuti hamagon dar onho vuçud dorad, monandi in viki, goh jo nogoh tavassuti haraznigorihoe, ki tavassuti abzorhoi xudkor pajvandi xudro dar candin somonaho mefiristand, mavridi sū'istifoda qaror megirand.\n\nDar porai az mavorid, ba viƶa zamone, ki jak pajvandi internetiji çadid ba sahifa izofa meşavad, viki metavonad, jak tasvir az hurufi rangī jo matni benurro ba şumo nişon bidihad va az şumo vorid kardani kalimai nişondodaşudaro purson meşavad. Ba xotiri in ki ançomi in kor ba şakli xudkor duşvor ast, in amal ba aksari insonhoe içozat medihad, ki ba irsoli matolib bipardozand, dar hole ki beştar robothoi hamlakunanda va haraznigorhoro mutavaqif mekunad.\n\nMutassifona in raviş mumkin ast, korbarone, ki quvvai bosiraaşon sust jo az mururgarhoi matnī jo ovozī istifoda mekunand, ducori mahdudijathoe bikunad. Dar holi hozir heç cojguzini savtī baroi in raviş mavçud nest. Cunonci in mas'ala şumoro ducori mahdudijate dur az intizor dar irsoli naviştahoi miçoz mekunad, bo mudironi somona oidi kūmak tamos bigired.\n\nDar murugaraton tugmai 'bozgaşt'-ro bo paxş kardan ba sahifai viroişgar bargarded.",
- "captcha-addurl-whitelist": " #<!—in satrro hamon guna, ki hast raho kuned --> <pre>\n# Qoida ba in şakl ast:\n# * Hama ciz az \"#\" to oxiri satr jak tavzeh ba nazar girifta meşavad\n# * Har satre, ki xolī naboşad jak qit'a dar nazar girifta meşavad, ki faqat bo nomi mizboni internetī sançida meşavad\n #</pre> <!-- in satrro hamon guna, ki hast raho kuned-->"
+ "captcha-addurl-whitelist": "#<!-- in satrro hamon guna, ki hast raho kuned --> <pre>\n# Qoida ba in şakl ast:\n# * Hama ciz az \"#\" to oxiri satr jak tavzeh ba nazar girifta meşavad\n# * Har satre, ki xolī naboşad jak qit'a dar nazar girifta meşavad, ki faqat bo nomi mizboni internetī sançida meşavad\n#</pre> <!-- in satrro hamon guna, ki hast raho kuned-->"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/to.json b/www/wiki/extensions/ConfirmEdit/i18n/to.json
new file mode 100644
index 00000000..6f5e7ccd
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/to.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fanjiayi"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/ur.json b/www/wiki/extensions/ConfirmEdit/i18n/ur.json
index e63cfac5..0a4c7ae6 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/ur.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/ur.json
@@ -5,6 +5,27 @@
"Muhammad Shuaib"
]
},
+ "captcha-edit": "اس صفحہ میں ترمیم کرنے کے لیے ذیل میں موجود سوال کو حل کریں اور اس کا جواب تحریر کریں ([[Special:Captcha/help|مزید تفصیل]]):",
+ "captcha-edit-fail": "نادرست یا غیر موجود کیپچا",
"captcha-label": "کیپچا",
- "right-skipcaptcha": " کیپچا سے گزرے بغیر کیپچا فعال کرنے والے اقدمات کی انجام دہی"
+ "captcha-help": "کیپچا کا حل",
+ "captcha-info-help": "کیپچا کی وضاحت",
+ "captcha-id-label": "کیپچا کا شناختی نمبر",
+ "captcha-addurl": "آپ کی ترمیم میں بیرونی روابط شامل ہیں۔\nویکی کو خودکار فاضل کاری سے محفوظ رکھنے کے خاطر آپ کی اس ترمیم کو محفوظ کرنے کے لیے ہماری آپ سے درخواست ہے کہ ذیل میں موجود سوال کو حل کرکے اس کا جواب تحریر کریں ([[Special:Captcha/help|مزید تفصیل]]):",
+ "captcha-badlogin": "ویکی کو خودکار پاس ورڈ چوری سے محفوظ رکھنے کے خاطر ہماری آپ سے درخواست ہے کہ ذیل میں موجود سوال کو حل کرکے اس کا جواب تحریر کریں ([[Special:Captcha/help|مزید تفصیل]]):",
+ "captcha-createaccount": "ویکی کو خودکار تخلیق کھاتہ سے محفوظ رکھنے کے خاطر ہماری آپ سے درخواست ہے کہ ذیل میں موجود سوال کو حل کرکے اس کا جواب تحریر کریں ([[Special:Captcha/help|مزید تفصیل]]):",
+ "captcha-createaccount-fail": "کیپچا نادرست یا غیر موجود",
+ "captcha-create": "اس صفحہ کو بنانے کے لیے براہ کرم ذیل میں موجود سوال حل کرکے اس کا جواب تحریر کریں ([[Special:Captcha/help|مزید تفصیل]]):",
+ "captcha-sendemail": "ویکی کو خودکار فاضل کاری سے محفوظ رکھنے کے خاطر ہماری آپ سے درخواست ہے کہ ذیل میں موجود سوال کو حل کرکے اس کا جواب تحریر کریں ([[Special:Captcha/help|مزید تفصیل]]):",
+ "captcha-sendemail-fail": "کیپچا نادرست یا غیر موجود",
+ "captcha-error": "کسی داخلی نقص کی بنا پر کیپچا کی تصدیق ناکام رہی: $1",
+ "captchahelp-title": "معاونت کیپچا",
+ "captchahelp-cookies-needed": "اسے انجام دینے کے لیے آپ کو اپنے براؤزر کے کوکیز فعال کرنا ہوگا۔",
+ "right-skipcaptcha": " کیپچا سے گزرے بغیر کیپچا فعال کرنے والے اقدمات کی انجام دہی",
+ "captcha-apihelp-param-captchaword": "کیپچا کا جواب دیں",
+ "confirmedit-preview-line": "سطر نمبر",
+ "confirmedit-preview-content": "مندرجات",
+ "confirmedit-preview-validity": "معتبریت",
+ "confirmedit-preview-valid": "معتبر",
+ "confirmedit-preview-invalid": "غیر معتبر"
}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/uz.json b/www/wiki/extensions/ConfirmEdit/i18n/uz.json
new file mode 100644
index 00000000..8aa9337f
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/i18n/uz.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sociologist"
+ ]
+ },
+ "captcha-label": "CAPTCHA"
+}
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/wuu.json b/www/wiki/extensions/ConfirmEdit/i18n/wuu.json
index 5ad7ca0d..002f2cf7 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/wuu.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/wuu.json
@@ -5,7 +5,7 @@
"飞舞回堂前"
]
},
- "captcha-edit": "要编辑该页面,请输入下底简单加法个答案([[Special:Captcha/help|更多资料]]):",
+ "captcha-edit": "要编辑该页面,请完成下底个任务,勒框里输入答案([[Special:Captcha/help|更多资料]]):",
"captcha-label": "验证码",
"captcha-addurl": "侬个编辑包括新个外部链接。为保护本wiki弗受自动垃圾程序个破坏,请答出下底个简单加法个答案([[Special:Captcha/help|更多信息]]):",
"captcha-badlogin": "为仔保护本wiki弗畀自动密码破解程序破坏,请答出一个简单个加法,再勒框内输入([[Special:Captcha/help|更多个资料]]):",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/zh-hans.json b/www/wiki/extensions/ConfirmEdit/i18n/zh-hans.json
index 44a18f2d..9907b68c 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/zh-hans.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/zh-hans.json
@@ -31,7 +31,7 @@
"captcha-error": "由于内部错误,验证码确认失败:$1",
"captchahelp-title": "验证码帮助",
"captchahelp-cookies-needed": "您需要启用您的浏览器的cookie使该程序工作。",
- "captchahelp-text": "接受公众贡献的网站,比如本wiki,经常受到使用自动工具添加垃圾网站链接的垃圾制造者的破坏。尽管这些垃圾链接可以被删除,它们仍然极其麻烦。\n\n有时,特别是给页面添加新的网络链接时,本wiki可能会向你展示一张有多种颜色或扭曲的文字的图像,并要求你输入展示的文字。由于这是一项难以用自动工具完成的任务,它可以允许在大多数真人做出贡献的同时,阻止大多数垃圾制造者和其他自动攻击者。\n\n遗憾地是,这可能会对视力受限或是使用纯文本或阅读浏览器的用户造成不便。目前我们还没替代的声音选择。如果这项措施意外地阻止你进行正常的贡献,请与[[Special:ListAdmins|网站管理员]]联系获取帮助。\n\n点击浏览器的“后退”按钮返回页面编辑器。",
+ "captchahelp-text": "接受公众贡献的网站,比如本wiki,经常受到使用自动工具添加垃圾网站链接的垃圾制造者的破坏。尽管这些垃圾链接可以被删除,它们仍然极其麻烦。\n\n有时,特别是给页面添加新的网络链接时,本wiki可能会向您展示一张有多种颜色或扭曲的文字的图像,并要求您输入展示的文字。由于这是一项难以用自动工具完成的任务,它可以允许在大多数真人做出贡献的同时,阻止大多数垃圾制造者和其他自动攻击者。\n\n遗憾地是,这可能会对视力受限或是使用纯文本或阅读浏览器的用户造成不便。目前我们还没替代的声音选择。如果这项措施意外地阻止您进行正常的贡献,请与[[Special:ListAdmins|网站管理员]]联系获取帮助。\n\n点击浏览器的“后退”按钮返回页面编辑器。",
"captcha-addurl-whitelist": " #<!-- 请将本行保持原样 --> <pre>\n# 语法如下:\n# * 所有以“#”字符开头的行都是注释\n# * 所有非空白行是正则表达式片段,只会对URL中的内容进行匹配\n #</pre> <!-- 请将本行保持原样 -->",
"right-skipcaptcha": "执行触发验证码的操作时无需验证",
"captcha-apihelp-param-captchaword": "回答验证码",
diff --git a/www/wiki/extensions/ConfirmEdit/i18n/zh-hant.json b/www/wiki/extensions/ConfirmEdit/i18n/zh-hant.json
index 1416e151..9df84930 100644
--- a/www/wiki/extensions/ConfirmEdit/i18n/zh-hant.json
+++ b/www/wiki/extensions/ConfirmEdit/i18n/zh-hant.json
@@ -10,10 +10,12 @@
"Cwlin0416",
"LNDDYL",
"Liuxinyu970226",
- "Bowleerin"
+ "Bowleerin",
+ "Wbxshiori",
+ "Kly"
]
},
- "captcha-edit": "要編輯這篇文章,請答出一個簡單的加法,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
+ "captcha-edit": "要編輯這篇文章,請完成以下項目,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
"captcha-edit-fail": "錯誤或未輸入 CAPTCHA",
"captcha-desc": "提供 CAPTCHA 技術來阻止垃圾訊息和密碼猜解",
"captcha-label": "CAPTCHA",
@@ -21,12 +23,12 @@
"captcha-info-help": "驗證碼的描述。",
"captcha-id-label": "驗證碼ID",
"captcha-id-help": "該值應該發回不變。",
- "captcha-addurl": "你編輯的內容中含有一個新的外部連結;為了免受自動垃圾程式的侵擾,請答出一個簡單的加法,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
- "captcha-badlogin": "為防止程式自動破解密碼,請答出一條簡單的加法,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
- "captcha-createaccount": "為防止程式自動註冊,請答出一條簡單的加法,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
+ "captcha-addurl": "你編輯的內容中含有一個新的外部連結;為了免受自動垃圾程式的侵擾,請完成以下項目,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
+ "captcha-badlogin": "為防止程式自動破解密碼,請完成以下項目,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
+ "captcha-createaccount": "為防止程式自動註冊,請完成以下項目,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
"captcha-createaccount-fail": "CAPTCHA 錯誤或遺失。",
- "captcha-create": "要建立頁面,請答出一個簡單的加法,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
- "captcha-sendemail": "為防止程式進行破壞,請答出一條簡單的加法,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
+ "captcha-create": "要建立頁面,請完成以下項目,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
+ "captcha-sendemail": "為防止程式進行破壞,請完成以下項目,然後在框內輸入 ([[Special:Captcha/help|更多資料]]) :",
"captcha-sendemail-fail": "CAPTCHA 錯誤或遺失。",
"captcha-disabledinapi": "此操作需要使用 CAPTCHA 驗証,因此無法透過 API 執行。",
"captcha-error": "由於內部錯誤,驗證碼確認失敗:$1",
@@ -36,5 +38,11 @@
"captcha-addurl-whitelist": " #<!-- 請勿更動此行 --> <pre>\n# 語法格式如下:\n# * 任何以 \"#\" 字元開頭至結尾代表註解\n# * 任何非空白行代表部份正規表示法,會用來比對 URL 中的主機\n #</pre> <!-- 請勿更動此行 -->",
"right-skipcaptcha": "執行會觸發驗證碼的動作時無需經過驗證碼檢驗",
"captcha-apihelp-param-captchaword": "回答驗證碼",
- "captcha-apihelp-param-captchaid": "之前請求的驗證碼ID"
+ "captcha-apihelp-param-captchaid": "之前請求的驗證碼ID",
+ "confirmedit-preview-line": "行號",
+ "confirmedit-preview-content": "內容",
+ "confirmedit-preview-validity": "有效性",
+ "confirmedit-preview-valid": "有效",
+ "confirmedit-preview-invalid": "無效",
+ "confirmedit-preview-description": "以下表格顯示出有關此頁面行數的清單,以及是否為有效的 IP 位址或 IP 位址範圍。如果某行是有效的 IP 位址或 IP 位址範圍,這會從驗證碼流程來被列入在白名單裡,若如果是無效的行則會被忽略。例如:來自於 69.208.0.0 至 69.208.255.255 網段的有效 IP 位址範圍會是 69.208.0.0/16。有關計算 IP 位址範圍更多方面訊息[https://www.mediawiki.org/wiki/Special:MyLanguage/Help:Range_blocks#Calculating_the_CIDR_suffix 可查看此]。"
}
diff --git a/www/wiki/extensions/ConfirmEdit/includes/CaptchaTriggers.php b/www/wiki/extensions/ConfirmEdit/includes/CaptchaTriggers.php
new file mode 100644
index 00000000..d88ca223
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/includes/CaptchaTriggers.php
@@ -0,0 +1,17 @@
+<?php
+
+/**
+ * A class with constants of the CAPTCHA triggers built-in in ConfirmEdit. Other extensions may
+ * add more possible triggers, which are not included in this class.
+ */
+abstract class CaptchaTriggers {
+ const EDIT = 'edit';
+ const CREATE = 'create';
+ const SENDEMAIL = 'sendemail';
+ const ADD_URL = 'addurl';
+ const CREATE_ACCOUNT = 'createaccount';
+ const BAD_LOGIN = 'badlogin';
+ const BAD_LOGIN_PER_USER = 'badloginperuser';
+
+ const EXT_REG_ATTRIBUTE_NAME = 'CaptchaTriggers';
+}
diff --git a/www/wiki/extensions/ConfirmEdit/includes/ConfirmEditHooks.php b/www/wiki/extensions/ConfirmEdit/includes/ConfirmEditHooks.php
index 2769f45e..0b9464f7 100644
--- a/www/wiki/extensions/ConfirmEdit/includes/ConfirmEditHooks.php
+++ b/www/wiki/extensions/ConfirmEdit/includes/ConfirmEditHooks.php
@@ -1,7 +1,5 @@
<?php
-use MediaWiki\Auth\AuthManager;
-
class ConfirmEditHooks {
protected static $instanceCreated = false;
@@ -13,9 +11,13 @@ class ConfirmEditHooks {
public static function getInstance() {
global $wgCaptcha, $wgCaptchaClass;
+ $class = $wgCaptchaClass;
+ if ( $class == null ) {
+ $class = 'SimpleCaptcha';
+ }
if ( !static::$instanceCreated ) {
static::$instanceCreated = true;
- $wgCaptcha = new $wgCaptchaClass;
+ $wgCaptcha = new $class;
}
return $wgCaptcha;
@@ -83,9 +85,6 @@ class ConfirmEditHooks {
self::getInstance()->onAuthChangeFormFields( $requests, $fieldInfo, $formDescriptor, $action );
}
- /**
- * Set up $wgWhitelistRead
- */
public static function confirmEditSetup() {
// @codingStandardsIgnoreStart MediaWiki.NamingConventions.ValidGlobalName.wgPrefix
global $wgCaptchaTriggers, $wgAllowConfirmedEmail,
@@ -112,7 +111,7 @@ class ConfirmEditHooks {
*
* @param Title $title
* @param User $user
- * @param $whitelisted
+ * @param bool &$whitelisted
*/
public static function onTitleReadWhitelist( Title $title, User $user, &$whitelisted ) {
$image = SpecialPage::getTitleFor( 'Captcha', 'image' );
diff --git a/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaCacheStore.php b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaCacheStore.php
new file mode 100644
index 00000000..d6661b3c
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaCacheStore.php
@@ -0,0 +1,30 @@
+<?php
+
+class CaptchaCacheStore extends CaptchaStore {
+ function store( $index, $info ) {
+ global $wgCaptchaSessionExpiration;
+
+ ObjectCache::getMainStashInstance()->set(
+ wfMemcKey( 'captcha', $index ),
+ $info,
+ $wgCaptchaSessionExpiration
+ );
+ }
+
+ function retrieve( $index ) {
+ $info = ObjectCache::getMainStashInstance()->get( wfMemcKey( 'captcha', $index ) );
+ if ( $info ) {
+ return $info;
+ } else {
+ return false;
+ }
+ }
+
+ function clear( $index ) {
+ ObjectCache::getMainStashInstance()->delete( wfMemcKey( 'captcha', $index ) );
+ }
+
+ function cookiesNeeded() {
+ return false;
+ }
+}
diff --git a/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaHashStore.php b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaHashStore.php
new file mode 100644
index 00000000..f28d4314
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaHashStore.php
@@ -0,0 +1,28 @@
+<?php
+
+class CaptchaHashStore extends CaptchaStore {
+ protected $data = [];
+
+ public function store( $index, $info ) {
+ $this->data[$index] = $info;
+ }
+
+ public function retrieve( $index ) {
+ if ( array_key_exists( $index, $this->data ) ) {
+ return $this->data[$index];
+ }
+ return false;
+ }
+
+ public function clear( $index ) {
+ unset( $this->data[$index] );
+ }
+
+ public function cookiesNeeded() {
+ return false;
+ }
+
+ public function clearAll() {
+ $this->data = [];
+ }
+}
diff --git a/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaSessionStore.php b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaSessionStore.php
new file mode 100644
index 00000000..a02f569c
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaSessionStore.php
@@ -0,0 +1,26 @@
+<?php
+
+use MediaWiki\Session\SessionManager;
+
+class CaptchaSessionStore extends CaptchaStore {
+ protected function __construct() {
+ // Make sure the session is started
+ SessionManager::getGlobalSession()->persist();
+ }
+
+ function store( $index, $info ) {
+ SessionManager::getGlobalSession()->set( 'captcha' . $index, $info );
+ }
+
+ function retrieve( $index ) {
+ return SessionManager::getGlobalSession()->get( 'captcha' . $index, false );
+ }
+
+ function clear( $index ) {
+ SessionManager::getGlobalSession()->remove( 'captcha' . $index );
+ }
+
+ function cookiesNeeded() {
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaStore.php b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaStore.php
new file mode 100644
index 00000000..20cb6a26
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/includes/store/CaptchaStore.php
@@ -0,0 +1,66 @@
+<?php
+
+abstract class CaptchaStore {
+ /**
+ * Store the correct answer for a given captcha
+ * @param string $index
+ * @param string $info the captcha result
+ */
+ abstract public function store( $index, $info );
+
+ /**
+ * Retrieve the answer for a given captcha
+ * @param string $index
+ * @return string|false
+ */
+ abstract public function retrieve( $index );
+
+ /**
+ * Delete a result once the captcha has been used, so it cannot be reused
+ * @param string $index
+ */
+ abstract public function clear( $index );
+
+ /**
+ * Whether this type of CaptchaStore needs cookies
+ * @return bool
+ */
+ abstract public function cookiesNeeded();
+
+ /**
+ * The singleton instance
+ * @var CaptchaStore
+ */
+ private static $instance;
+
+ /**
+ * Get somewhere to store captcha data that will persist between requests
+ *
+ * @throws Exception
+ * @return CaptchaStore
+ */
+ final public static function get() {
+ if ( !self::$instance instanceof self ) {
+ global $wgCaptchaStorageClass;
+ if ( in_array( 'CaptchaStore', class_parents( $wgCaptchaStorageClass ) ) ) {
+ self::$instance = new $wgCaptchaStorageClass;
+ } else {
+ throw new Exception( "Invalid CaptchaStore class $wgCaptchaStorageClass" );
+ }
+ }
+ return self::$instance;
+ }
+
+ final public static function unsetInstanceForTests() {
+ if ( !defined( 'MW_PHPUNIT_TEST' ) ) {
+ throw new MWException( 'Cannot unset ' . __CLASS__ . ' instance in operation.' );
+ }
+ self::$instance = null;
+ }
+
+ /**
+ * Protected constructor: no creating instances except through the factory method above
+ */
+ protected function __construct() {
+ }
+}
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaAuthenticationRequestTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaAuthenticationRequestTest.php
index 3513e5b4..380716fe 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaAuthenticationRequestTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaAuthenticationRequestTest.php
@@ -1,8 +1,10 @@
<?php
use MediaWiki\Auth\AuthenticationRequestTestCase;
-use MediaWiki\Auth\AuthManager;
+/**
+ * @covers CaptchaAuthenticationRequest
+ */
class CaptchaAuthenticationRequestTest extends AuthenticationRequestTestCase {
public function setUp() {
parent::setUp();
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaPreAuthenticationProviderTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaPreAuthenticationProviderTest.php
index 9997d8f0..8e56c369 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaPreAuthenticationProviderTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/CaptchaPreAuthenticationProviderTest.php
@@ -5,15 +5,11 @@ use MediaWiki\Auth\UsernameAuthenticationRequest;
use Wikimedia\TestingAccessWrapper;
/**
+ * @covers CaptchaPreAuthenticationProvider
* @group Database
*/
class CaptchaPreAuthenticationProviderTest extends MediaWikiTestCase {
public function setUp() {
- global $wgDisableAuthManager;
- if ( !class_exists( AuthManager::class ) || $wgDisableAuthManager ) {
- $this->markTestSkipped( 'AuthManager is disabled' );
- }
-
parent::setUp();
$this->setMwGlobals( [
'wgCaptchaClass' => SimpleCaptcha::class,
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLFancyCaptchaFieldTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLFancyCaptchaFieldTest.php
index 9c3bbe39..b123d214 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLFancyCaptchaFieldTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLFancyCaptchaFieldTest.php
@@ -2,7 +2,10 @@
require_once __DIR__ . '/../../FancyCaptcha/HTMLFancyCaptchaField.php';
-class HTMLFancyCaptchaFieldTest extends PHPUnit_Framework_TestCase {
+/**
+ * @covers HTMLFancyCaptchaField
+ */
+class HTMLFancyCaptchaFieldTest extends PHPUnit\Framework\TestCase {
public function testGetHTML() {
$html = $this->getForm( [ 'imageUrl' => 'https://example.com/' ] )->getHTML( false );
$this->assertRegExp( '/"fancycaptcha-image"/', $html );
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaFieldTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaFieldTest.php
index 0ec600f9..601168ed 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaFieldTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaFieldTest.php
@@ -2,7 +2,10 @@
require_once __DIR__ . '/../../ReCaptcha/HTMLReCaptchaField.php';
-class HTMLReCaptchaFieldTest extends PHPUnit_Framework_TestCase {
+/**
+ * @covers HTMLReCaptchaField
+ */
+class HTMLReCaptchaFieldTest extends PHPUnit\Framework\TestCase {
public function testSubmit() {
$form = new HTMLForm( [
'foo' => [
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaNoCaptchaFieldTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaNoCaptchaFieldTest.php
index 206f8fa0..e6626f75 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaNoCaptchaFieldTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLReCaptchaNoCaptchaFieldTest.php
@@ -2,7 +2,10 @@
require_once __DIR__ . '/../../ReCaptchaNoCaptcha/HTMLReCaptchaNoCaptchaField.php';
-class HTMLReCaptchaNoCaptchaFieldTest extends PHPUnit_Framework_TestCase {
+/**
+ * @covers HTMLReCaptchaNoCaptchaField
+ */
+class HTMLReCaptchaNoCaptchaFieldTest extends PHPUnit\Framework\TestCase {
public function testSubmit() {
$form = new HTMLForm( [
'foo' => [
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLSubmittedValueFieldTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLSubmittedValueFieldTest.php
index 8fa114c4..70cf2f3c 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLSubmittedValueFieldTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/HTMLSubmittedValueFieldTest.php
@@ -2,7 +2,10 @@
require_once __DIR__ . '/../../ReCaptcha/HTMLSubmittedValueField.php';
-class HTMLSubmittedValueFieldTest extends PHPUnit_Framework_TestCase {
+/**
+ * @covers HTMLSubmittedValueField
+ */
+class HTMLSubmittedValueFieldTest extends PHPUnit\Framework\TestCase {
public function testSubmit() {
$form = new HTMLForm( [
'foo' => [
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/QuestyCaptchaTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/QuestyCaptchaTest.php
index dada6689..e76469ba 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/QuestyCaptchaTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/QuestyCaptchaTest.php
@@ -1,6 +1,19 @@
<?php
+/**
+ * @covers QuestyCaptcha
+ */
class QuestyCaptchaTest extends MediaWikiTestCase {
+
+ public function setUp() {
+ parent::setUp();
+
+ $this->mergeMwGlobalArrayValue(
+ 'wgAutoloadClasses',
+ [ 'QuestyCaptcha' => __DIR__ . '/../../QuestyCaptcha/QuestyCaptcha.class.php' ]
+ );
+ }
+
/**
* @covers QuestyCaptcha::getCaptcha
* @dataProvider provideGetCaptcha
@@ -11,10 +24,6 @@ class QuestyCaptchaTest extends MediaWikiTestCase {
$GLOBALS['wgCaptchaQuestions'] = [];
}
$this->setMwGlobals( 'wgCaptchaQuestions', $config );
- $this->mergeMwGlobalArrayValue(
- 'wgAutoloadClasses',
- [ 'QuestyCaptcha' => __DIR__ . '/../../QuestyCaptcha/QuestyCaptcha.class.php' ]
- );
$qc = new QuestyCaptcha();
$this->assertEquals( $expected, $qc->getCaptcha() );
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaAuthenticationRequestTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaAuthenticationRequestTest.php
index 71fa0586..bc645b89 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaAuthenticationRequestTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaAuthenticationRequestTest.php
@@ -4,6 +4,9 @@ use MediaWiki\Auth\AuthenticationRequestTestCase;
require_once __DIR__ . '/../../ReCaptcha/ReCaptchaAuthenticationRequest.php';
+/**
+ * @covers ReCaptchaAuthenticationRequest
+ */
class ReCaptchaAuthenticationRequestTest extends AuthenticationRequestTestCase {
protected function getInstance( array $args = [] ) {
return new ReCaptchaAuthenticationRequest();
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaNoCaptchaAuthenticationRequestTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaNoCaptchaAuthenticationRequestTest.php
index af81ea23..d4917b51 100644
--- a/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaNoCaptchaAuthenticationRequestTest.php
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/ReCaptchaNoCaptchaAuthenticationRequestTest.php
@@ -4,6 +4,9 @@ use MediaWiki\Auth\AuthenticationRequestTestCase;
require_once __DIR__ . '/../../ReCaptchaNoCaptcha/ReCaptchaNoCaptchaAuthenticationRequest.php';
+/**
+ * @covers ReCaptchaNoCaptchaAuthenticationRequest
+ */
class ReCaptchaNoCaptchaAuthenticationRequestTest extends AuthenticationRequestTestCase {
protected function getInstance( array $args = [] ) {
return new ReCaptchaNoCaptchaAuthenticationRequest();
diff --git a/www/wiki/extensions/ConfirmEdit/tests/phpunit/SimpleCaptcha/CaptchaTest.php b/www/wiki/extensions/ConfirmEdit/tests/phpunit/SimpleCaptcha/CaptchaTest.php
new file mode 100644
index 00000000..6837bfc4
--- /dev/null
+++ b/www/wiki/extensions/ConfirmEdit/tests/phpunit/SimpleCaptcha/CaptchaTest.php
@@ -0,0 +1,116 @@
+<?php
+
+/**
+ * @covers SimpleCaptcha
+ */
+class CaptchaTest extends MediaWikiTestCase {
+ /**
+ * @dataProvider provideSimpleTriggersCaptcha
+ */
+ public function testTriggersCaptcha( $action, $expectedResult ) {
+ $captcha = new SimpleCaptcha();
+ $this->setMwGlobals( [
+ 'wgCaptchaTriggers' => [
+ $action => $expectedResult,
+ ]
+ ] );
+ $this->assertEquals( $expectedResult, $captcha->triggersCaptcha( $action ) );
+ }
+
+ public function provideSimpleTriggersCaptcha() {
+ $data = [];
+ $captchaTriggers = new ReflectionClass( CaptchaTriggers::class );
+ $constants = $captchaTriggers->getConstants();
+ foreach ( $constants as $const ) {
+ $data[] = [ $const, true ];
+ $data[] = [ $const, false ];
+ }
+ return $data;
+ }
+
+ /**
+ * @dataProvider provideNamespaceOverwrites
+ */
+ public function testNamespaceTriggersOverwrite( $trigger, $expected ) {
+ $captcha = new SimpleCaptcha();
+ $this->setMwGlobals( [
+ 'wgCaptchaTriggers' => [
+ $trigger => !$expected,
+ ],
+ 'wgCaptchaTriggersOnNamespace' => [
+ 0 => [
+ $trigger => $expected,
+ ],
+ ],
+ ] );
+ $title = Title::newFromText( 'Main' );
+ $this->assertEquals( $expected, $captcha->triggersCaptcha( $trigger, $title ) );
+ }
+
+ public function provideNamespaceOverwrites() {
+ return [
+ [ 'edit', true ],
+ [ 'edit', false ],
+ ];
+ }
+
+ private function setCaptchaTriggersAttribute( $trigger, $value ) {
+ $info = [
+ 'globals' => [],
+ 'callbacks' => [],
+ 'defines' => [],
+ 'credits' => [],
+ 'attributes' => [
+ 'CaptchaTriggers' => [
+ $trigger => $value
+ ]
+ ],
+ 'autoloaderPaths' => []
+ ];
+ $registry = new ExtensionRegistry();
+ $class = new ReflectionClass( 'ExtensionRegistry' );
+ $instanceProperty = $class->getProperty( 'instance' );
+ $instanceProperty->setAccessible( true );
+ $instanceProperty->setValue( $registry );
+ $method = $class->getMethod( 'exportExtractedData' );
+ $method->setAccessible( true );
+ $method->invokeArgs( $registry, [ $info ] );
+ }
+
+ /**
+ * @dataProvider provideAttributeSet
+ */
+ public function testCaptchaTriggersAttributeSetTrue( $trigger, $value ) {
+ $this->setCaptchaTriggersAttribute( $trigger, $value );
+ $captcha = new SimpleCaptcha();
+ $this->assertEquals( $value, $captcha->triggersCaptcha( $trigger ) );
+ }
+
+ public function provideAttributeSet() {
+ return [
+ [ 'test', true ],
+ [ 'test', false ],
+ ];
+ }
+
+ /**
+ * @dataProvider provideAttributeOverwritten
+ */
+ public function testCaptchaTriggersAttributeGetsOverwritten( $trigger, $expected ) {
+ $this->setMwGlobals( [
+ 'wgCaptchaTriggers' => [
+ $trigger => $expected
+ ]
+ ] );
+ $this->setCaptchaTriggersAttribute( $trigger, !$expected );
+ $captcha = new SimpleCaptcha();
+ $this->assertEquals( $expected, $captcha->triggersCaptcha( $trigger ) );
+ }
+
+ public function provideAttributeOverwritten() {
+ return [
+ [ 'edit', true ],
+ [ 'edit', false ],
+ ];
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/Gadgets.alias.php b/www/wiki/extensions/Gadgets/Gadgets.alias.php
index c71b820d..617e46c7 100644
--- a/www/wiki/extensions/Gadgets/Gadgets.alias.php
+++ b/www/wiki/extensions/Gadgets/Gadgets.alias.php
@@ -361,6 +361,12 @@ $specialPageAliases['uk'] = [
'Gadgets' => [ 'Додатки', 'Гаджеты' ],
];
+/** Urdu (اردو) */
+$specialPageAliases['ur'] = [
+ 'Gadgets' => [ 'آلات' ],
+ 'GadgetUsage' => [ 'آلات_کا_استعمال' ],
+];
+
/** Venetian (vèneto) */
$specialPageAliases['vec'] = [
'Gadgets' => [ 'Strumenti' ],
diff --git a/www/wiki/extensions/Gadgets/Gadgets.namespaces.php b/www/wiki/extensions/Gadgets/Gadgets.namespaces.php
index 16148f87..c1c70b9c 100644
--- a/www/wiki/extensions/Gadgets/Gadgets.namespaces.php
+++ b/www/wiki/extensions/Gadgets/Gadgets.namespaces.php
@@ -149,6 +149,13 @@ $namespaceNames['he'] = [
NS_GADGET_DEFINITION_TALK => 'שיחת_הגדרת_גאדג\'ט',
];
+$namespaceNames['inh'] = [
+ NS_GADGET => 'Гаджет',
+ NS_GADGET_TALK => 'Гаджет_ювцар',
+ NS_GADGET_DEFINITION => 'Гаджета_къоастадар',
+ NS_GADGET_DEFINITION_TALK => 'Гаджета_къоастадар_дувцар',
+];
+
$namespaceNames['is'] = [
NS_GADGET => 'Smától',
NS_GADGET_TALK => 'Smátólaspjall',
@@ -177,6 +184,13 @@ $namespaceNames['lrc'] = [
NS_GADGET_DEFINITION_TALK => 'چأک_چئنە_توضییا_گأجئت',
];
+$namespaceNames['mwl'] = [
+ NS_GADGET => 'Gadget',
+ NS_GADGET_TALK => 'Cumbersa_gadget',
+ NS_GADGET_DEFINITION => 'Defeniçon_gadget',
+ NS_GADGET_DEFINITION_TALK => 'Cumbersa_defeniçon_gadget',
+];
+
$namespaceNames['mzn'] = [
NS_GADGET => 'گجت',
NS_GADGET_TALK => 'گجت_گپ',
@@ -212,6 +226,13 @@ $namespaceNames['pnb'] = [
NS_GADGET_DEFINITION_TALK => 'آلہ_تعریف_گل_بات',
];
+$namespaceNames['sd'] = [
+ NS_GADGET => 'گيجيٽ',
+ NS_GADGET_TALK => 'گيجيٽ_بحث',
+ NS_GADGET_DEFINITION => 'گيجيٽ_وصف',
+ NS_GADGET_DEFINITION_TALK => 'گيجيٽ_وصف_بحث',
+];
+
$namespaceNames['ur'] = [
NS_GADGET => 'آلہ',
NS_GADGET_TALK => 'تبادلۂ_خیال_آلہ',
diff --git a/www/wiki/extensions/Gadgets/composer.json b/www/wiki/extensions/Gadgets/composer.json
index 021a14cb..b822010c 100644
--- a/www/wiki/extensions/Gadgets/composer.json
+++ b/www/wiki/extensions/Gadgets/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/Gadgets/extension.json b/www/wiki/extensions/Gadgets/extension.json
index e7f06a49..141f9eb7 100644
--- a/www/wiki/extensions/Gadgets/extension.json
+++ b/www/wiki/extensions/Gadgets/extension.json
@@ -6,7 +6,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:Gadgets",
"descriptionmsg": "gadgets-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"requires": {
"MediaWiki": ">= 1.28.0"
},
@@ -62,13 +62,13 @@
"GadgetsNamespaces": "Gadgets.namespaces.php"
},
"AutoloadClasses": {
- "ApiQueryGadgetCategories": "api/ApiQueryGadgetCategories.php",
- "ApiQueryGadgets": "api/ApiQueryGadgets.php",
- "Gadget": "Gadgets_body.php",
- "GadgetHooks": "GadgetHooks.php",
+ "ApiQueryGadgetCategories": "includes/api/ApiQueryGadgetCategories.php",
+ "ApiQueryGadgets": "includes/api/ApiQueryGadgets.php",
+ "Gadget": "includes/Gadget.php",
+ "GadgetHooks": "includes/GadgetHooks.php",
"GadgetResourceLoaderModule": "includes/GadgetResourceLoaderModule.php",
- "SpecialGadgets": "SpecialGadgets.php",
- "SpecialGadgetUsage": "SpecialGadgetUsage.php",
+ "SpecialGadgets": "includes/SpecialGadgets.php",
+ "SpecialGadgetUsage": "includes/SpecialGadgetUsage.php",
"GadgetRepo": "includes/GadgetRepo.php",
"GadgetDefinitionNamespaceRepo": "includes/GadgetDefinitionNamespaceRepo.php",
"MediaWikiGadgetsDefinitionRepo": "includes/MediaWikiGadgetsDefinitionRepo.php",
@@ -108,6 +108,9 @@
],
"wgQueryPages": [
"GadgetHooks::onwgQueryPages"
+ ],
+ "DeleteUnknownPreferences": [
+ "GadgetHooks::onDeleteUnknownPreferences"
]
},
"config": {
diff --git a/www/wiki/extensions/Gadgets/i18n/ais.json b/www/wiki/extensions/Gadgets/i18n/ais.json
index 6af09fd4..3df41746 100644
--- a/www/wiki/extensions/Gadgets/i18n/ais.json
+++ b/www/wiki/extensions/Gadgets/i18n/ais.json
@@ -5,13 +5,43 @@
"Benel"
]
},
+ "gadgets-desc": "nay misaungayay kapah tu i [[Special:Preferences#mw-prefsection-gadgets|setin tu kanamuhan]] pakuniza misanga’ [[Special:Gadgets|CSS atu JavaScript a adidi’ay sakaluk]]",
+ "gadgets-prefstext": "isasa’ pasilsil kapah i canghaw nu misu miwawah a sazumaay adidi’ay sakaluk.\nuyniyay adidi’ay sakaluk kayadah pisaungay JavaScript patizeng, sisa saazihay-sakaluk kanca miwawah JavaScript kya taneng malecek misaungay.\nazihen, adidi’ay sakaluk kanca miliyas setin tu kanamuhan kasabelih satu izaw ku laheci.\n\nnaamahiza piazihen, uyniyay sazumaay adidi’ay sakaluk caay mikitinay nu MediaWiki a liyad, sawsawni nay itiniay a Wiki a misaungayay patizeng atu midiput. i paykakacawan mikuwanay kapah tu mikawaway-kalumyiti adidi’ay sakaluk a [[MediaWiki:Gadgets-definition|satetek]] atu [[Special:Gadgets| myawsu]]. cacacacay adidi’ay sakaluk saungay sulyang kapah tu ilabu’ nu [[Special:GadgetUsage|sausi]] matepa",
+ "gadgetusage": "adidi’ay sakaluk pisaungay sausi",
"gadgetusage-usercount": "misaungayay nikayadah",
+ "gadgetusage-noresults": "caay katepa adidi’ay sakaluk.",
+ "gadgetusage-intro": "tina sapat nu sulit buhci tu kamu tina wiki miwawah adidi’ay sakaluk a situngusay nikayadah. i nacila {{PLURAL:$1|cacay demiad|$1 demiad}}namisanga’ mikawaway-kalumyiti a situngusay apalatanitik. tina liseto caay yamalyilu pataayaw tu kawaw sacahamin tademaw miwawah amin tu adidi’ay sakaluk, liyad adidi’ay sakaluk hakay caaytu misaungay satu.",
"gadgetusage-activeusers": "saungay nu binawlan a misaungayay",
"gadgetusage-default": "pataayaw tu kawaw",
"gadgets-title": "adidi’ay a sakaluk",
+ "gadgets-pagetext": "isasa’ pasilsil misaungayay kapah tu itiza [[Special:Preferences#mw-prefsection-gadgets|setin tu kanamuhan kasabelih]] miwawahay a sazumaay adidi’ay sakaluk, tina piazihan-tu-sulit i [[MediaWiki:Gadgets-definition| satetek]] ma satetek.\n\ntina kasabelih taneng kisu misuped-miala satetek adidi’ay sakaluk sapuelac atu cengsema-kodo a sisetyimo palatuh kasabelih.",
"gadgets-uses": "misaungayay",
+ "gadgets-required-rights": "maydih isasa’ay a {{PLURAL:$2|tungus}}:\n\n$1",
+ "gadgets-required-skins": "kapah misanga’ i{{PLURAL:$2|$1 nuhekalan|cudad i sasa nuhekalan: $1}}.",
"gadgets-default": "sacahamin tademaw pataayaw tu kawaw miwawah",
+ "gadgets-legacy": "caay pacumud adidi’ay sakaluk, papisaungay ResourceLoader.\n([https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users) mizateng tu yadah])",
"gadgets-export": "patahkal",
"gadgets-export-title": "patahkal adidi’ay a sakaluk",
+ "gadgets-not-found": "inayi’ adidi’ay sakaluk \"$1\".",
+ "gadgets-export-text": "apatahkal $1 adidi’ay sakaluk, pisapecec \"{{int:gadgets-export-download}}\" pipenecan, atu misuped patasasa’ay a tangan, taayaw papatuzu’an Wiki a Special:Import zumasatu apatapabawan。izikuz sa isasa’ay a sulit pacunus ta MediaWiki:Gadgets-definition kasabelih:\n<pre>$2</pre>\nkanca kisu sipapatuzu’an Wiki a tatengaay a tungus (yamalyilu mikawaway-kalumyiti sisetyimo palatuh a tungus), atu kanca miwawah micaliw tu tangan patapabaw pacumuday a sasahicaan.",
+ "apihelp-query+gadgetcategories-description": "maminay tu adidi’ay sakaluk kakuniza piazihan-tu-sulit.",
+ "apihelp-query+gadgetcategories-param-prop": "amiala u canan adidi’ay sakaluk kakuniza cesyun:\n;name: labuay liyad malecaday a kalungangan\n;title: kakuniza satangahan\n;members: ibalu’ nu kakuniza nikayadah nu adidi’ay a sakaluk.",
+ "apihelp-query+gadgetcategories-param-names": "amaala kakuniza kalungangan.",
+ "apihelp-query+gadgetcategories-example-1": "maala izaway a adidi’ay sakaluk kakuniza piazihan-tu-sulit",
+ "apihelp-query+gadgetcategories-example-2": "maala sacahamin mahizaay kakuniza kalungangan ku \"foo\" atu \"bar\" a cesyun",
+ "apihelp-query+gadgets-description": "maminay tu iniay wiki masaungayay adidi’ay sakaluk piazihan-tu-sulit.",
+ "apihelp-query+gadgets-param-prop": "amiala canan adidi’ay sakaluk cesyun:\n;id: labu adidi’ay sakaluk ID.\n;metadata: adidi’ay sakaluk metadata.\n;desc: adidi’ay sakaluk sapuelac miliyaw ta HTML kese (hakay sasutili’ay haymaw, i maydih a dada’ misaungay).",
+ "apihelp-query+gadgets-param-categories": "nay tina kakuniza maala adidi’ay sakaluk.",
+ "apihelp-query+gadgets-param-ids": "amiala adidi’ay sakaluk a ID.",
+ "apihelp-query+gadgets-param-allowedonly": "pasilsil a cacay nuayzaay a misaungayay taneng pisaungay a adidi’ay sakaluk.",
+ "apihelp-query+gadgets-param-enabledonly": "pasilsil a cacaynay ayzaay misaungayay miwawah a adidi’ay sakaluk.",
+ "apihelp-query+gadgets-example-1": "maala adidi’ay sakaluk atu kya sapuelac piazihan-tu-sulit",
+ "apihelp-query+gadgets-example-2": "maala adidi’ay sakaluk aut kya sacahamin susin piazihan-tu-sulit",
+ "apihelp-query+gadgets-example-3": "maala tungusay nu kakuniza \"foo\" a adidi’ay sakaluk piazihan-tu-sulit",
+ "apihelp-query+gadgets-example-4": "miala mahizaay adidi’ay sakaluk \"foo\" atu \"bar\" a cesyun",
+ "apihelp-query+gadgets-example-5": "maala ayzaay a misaungayay mitekaay a piazihan-tu-sulit nu adidi’ay sakaluk-silsil",
+ "right-gadgets-edit": "mikawaway-kalumyiti adidi’ay sakaluk a JavaScript atu CSS kasabelih",
+ "action-gadgets-edit": "mikawaway-kalumyiti tina adidi’ay sakaluk a JavaScript saca CSS kasabelih",
+ "right-gadgets-definition-edit": "mikawaway-kalumyiti adidiay sakaluk satetek",
"action-gadgets-definition-edit": "mikawaway-kalumyiti tina pasaheci nu adidi’ay sakaluk"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/as.json b/www/wiki/extensions/Gadgets/i18n/as.json
index c1ea2461..49b24de0 100644
--- a/www/wiki/extensions/Gadgets/i18n/as.json
+++ b/www/wiki/extensions/Gadgets/i18n/as.json
@@ -14,6 +14,8 @@
"gadgetusage-gadget": "গেজেট",
"gadgetusage-usercount": "সদস্যৰ সংখ্যা",
"gadgetusage-noresults": "কোনো গেজেট বিচাৰি পোৱা নহ'ল।",
+ "gadgetusage-activeusers": "সক্ৰিয় ব্যৱহাৰকাৰী",
+ "gadgetusage-default": "পুনঃনিৰ্ধাৰিত",
"gadgets-title": "গেজেটসমূহ",
"gadgets-pagetext": "সদস্যসকলে তেওঁলোকৰ [[Special:Preferences#mw-prefsection-gadgets|পছন্দ পৃষ্ঠাত]] সক্ৰিয় কৰিব পৰা আৰু [[MediaWiki:Gadgets-definition|সংজ্ঞা থকা]] বিশেষ গেজেটসমূহৰ তালিকা তলত দিয়া হৈছে।\nএই সাৰাংশই প্ৰতিটো গেজেটৰ বিৱৰণ আৰু সংকেত থকা প্ৰণালী বাৰ্তাসমূহলৈ প্ৰৱেশাধিকাৰ দিয়ে।",
"gadgets-uses": "ব্যৱহাৰ",
diff --git a/www/wiki/extensions/Gadgets/i18n/be.json b/www/wiki/extensions/Gadgets/i18n/be.json
index cbbd69ab..f6017fbb 100644
--- a/www/wiki/extensions/Gadgets/i18n/be.json
+++ b/www/wiki/extensions/Gadgets/i18n/be.json
@@ -1,8 +1,14 @@
{
"@metadata": {
"authors": [
- "Mikalai Udodau"
+ "Mikalai Udodau",
+ "Artsiom91"
]
},
+ "prefs-gadgets": "Гаджэты",
+ "gadgets-prefstext": "Ніжэй прадстаўлены спіс спецыяльных гаджэтаў, якія могуць быць уключаныя з Вашага акаўнта.\nБольшасць гэтых гаджэтаў напісаныя на JavaScript, таму JavaScript павінен падтрымлівацца браўзерам, якім Вы карыстаецеся.\nМайце на ўвазе, што гэтыя гаджэты не будуць працаваць на гэтай старонцы настроек.\n\nТаксама заўважце, што гэтыя спецыяльныя гаджэты не з’яўляюцца часткай праграмнага забеспячэння MediaWiki, і яны звычайна распрацоўваюцца і падтрымліваюцца ў лакальным вікі-праекце.\nАдміністратары лакальнага вікі-праекта могуць правіць [[MediaWiki:Gadgets-definition|вызначэнні]] і [[Special:Gadgets|апісанні]] даступных гаджэтаў. Колькасць удзельнікаў, якія ўжываюць кожны гаджэт у гэтым праекце, можна паглядзець на старонцы [[Special:GadgetUsage|статыстыкі карыстання гаджэтамі]].",
+ "gadgets": "Гаджэты",
+ "gadgetusage": "Статыстыка карыстання гаджэтамі",
+ "gadgetusage-gadget": "Гаджэт",
"gadgets-title": "Гаджэты"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/bg.json b/www/wiki/extensions/Gadgets/i18n/bg.json
index 955ceae0..80975f83 100644
--- a/www/wiki/extensions/Gadgets/i18n/bg.json
+++ b/www/wiki/extensions/Gadgets/i18n/bg.json
@@ -6,14 +6,15 @@
"Spiritia",
"Turin",
"Vodnokon4e",
- "StanProg"
+ "StanProg",
+ "ShockD"
]
},
"gadgets-desc": "Позволява на потребителите да избират и активират [[Special:Gadgets|CSS и JavaScript джаджи]] от своите [[Special:Preferences#mw-prefsection-gadgets|настройки]]",
"prefs-gadgets": "Джаджи",
"gadgets-prefstext": "По-долу е списъкът на специалните джаджи, които можете да активирате на своята потребителска сметка.\nТъй като почти всички джаджи са базирани на JavaScript, трябва да го активирате на браузъра си, за да могат те да работят.\nИмайте предвид, че тези джаджи няма да окажат влияние на тази страница с настройки.\n\nСъщо така, джаджите не са част от софтуера МедияУики, и обикновено се разработват и поддържат от потребители в локалното уики. Локалните администратори могат да редактират наличните джаджи посредством [[MediaWiki:Gadgets-definition|дефинициите]] и [[Special:Gadgets|описанията]]. Броят потребителите на тези джаджи е показан на [[Special:GadgetUsage|Статистика на употребата на джаджи]].",
"gadgets": "Джаджи",
- "gadgetusage": "Статистики за използването на джаджите",
+ "gadgetusage": "Статистика за използването на джаджите",
"gadgetusage-gadget": "Джаджа",
"gadgetusage-usercount": "Брой потребители",
"gadgetusage-noresults": "Не са намерени джаджи.",
@@ -25,17 +26,18 @@
"gadgets-pagetext": "По-долу е списъкът на специалните джаджи, които потребителите могат да активират чрез [[Special:Preferences#mw-prefsection-gadgets|страницата си с настройки]], както е указано на [[MediaWiki:Gadgets-definition]].\nТози списък дава лесен достъп до страниците със системни съобщения, съдържащи описанието и кода на всяка джаджа.",
"gadgets-uses": "Използва",
"gadgets-required-rights": "Изисква {{PLURAL:$2|следното потребителско право|следните потребителски права}}:\n\n$1",
- "gadgets-required-skins": "Джаджата е достъпна в {{PLURAL:$2|облик „$1“|следните облици: $1}}.",
+ "gadgets-required-skins": "Джаджата е достъпна в {{PLURAL:$2|облик „$1“|следните облици: „$1“}}.",
"gadgets-default": "Активирана за всички по подразбиране.",
"gadgets-legacy": "Джаджата не е заредена. Моля, мигрирайте към ResourceLoader. ([https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users) научете повече])",
"gadgets-export": "Изнасяне",
"gadgets-export-title": "Експорт на джаджи",
- "gadgets-not-found": "Джаджа \"$1\" не беше намерена.",
+ "gadgets-not-found": "Джаджа „$1“ не беше намерена.",
"gadgets-export-text": "За да експортирате джаджата $1, щракнете на бутона \"{{int:gadgets-export-download/bg}}\", запазете файла на диска си, отидете на страницата Special:Import в целевото уики и го качете там. След това добавете към страницата MediaWiki:Gadgets-definition:\n<pre>$2</pre>\nВ целевото уики трябва да се ползвате от съответните права (в това число правото да редактирате системни съобщения) и трябва да са разрешени локалните файлови качвания.",
"gadgets-export-download": "Изтегляне",
"apihelp-query+gadgets-description": "Връща списък от джаджите, използвани в това уики.",
"apihelp-query+gadgets-param-allowedonly": "Списък само на джаджите, до които потребителят има достъп.",
"apihelp-query+gadgets-param-enabledonly": "Списък само на джаджите, които потребителят е активирал в профила си.",
"right-gadgets-edit": "Редактиране на JavaScript и CSS страниците на джаджите",
- "right-gadgets-definition-edit": "Редактиране на дефинициите на джаджите"
+ "right-gadgets-definition-edit": "Редактиране на дефинициите на джаджите",
+ "action-gadgets-definition-edit": "редактиране на дефиницията на тази джаджа"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/bho.json b/www/wiki/extensions/Gadgets/i18n/bho.json
index e390ca5d..428eb51c 100644
--- a/www/wiki/extensions/Gadgets/i18n/bho.json
+++ b/www/wiki/extensions/Gadgets/i18n/bho.json
@@ -4,5 +4,8 @@
"SatyamMishra"
]
},
- "gadgets-title": "औजार (गैजेट्स)"
+ "prefs-gadgets": "गैजेट",
+ "gadgets": "गैजेट",
+ "gadgetusage-gadget": "गैजेट",
+ "gadgets-title": "गैजेट"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/ca.json b/www/wiki/extensions/Gadgets/i18n/ca.json
index ca407002..f2fb7bd6 100644
--- a/www/wiki/extensions/Gadgets/i18n/ca.json
+++ b/www/wiki/extensions/Gadgets/i18n/ca.json
@@ -19,7 +19,7 @@
"gadgetusage": "Estadístiques d'ús de ginys",
"gadgetusage-gadget": "Giny",
"gadgetusage-usercount": "Nombre d'usuaris",
- "gadgetusage-summary": "Aquesta taula indica el nombre d'usuaris que tenen activat cada giny en aquest wiki. Pot incloure ginys que ja no estan disponibles.",
+ "gadgetusage-intro": "Aquesta taula indica el nombre d'usuaris que tenen activat cada giny en aquest wiki. Pot incloure ginys que ja no estan disponibles.",
"gadgets-title": "Ginys",
"gadgets-pagetext": "A continuació teniu una llista de ginys especials que els usuaris poden activar a la seva [[Special:Preferences#mw-prefsection-gadgets|pàgina de preferències]], segons les [[MediaWiki:Gadgets-definition|seves definicions]].\nAquesta llista permet un fàcil accés a les pàgines del sistema que defineixen la descripció i el codi de cada giny.",
"gadgets-uses": "Usa",
diff --git a/www/wiki/extensions/Gadgets/i18n/diq.json b/www/wiki/extensions/Gadgets/i18n/diq.json
index 4877c6fb..471388c5 100644
--- a/www/wiki/extensions/Gadgets/i18n/diq.json
+++ b/www/wiki/extensions/Gadgets/i18n/diq.json
@@ -26,7 +26,7 @@
"gadgets-required-rights": "Cêrêni icab kenê {{PLURAL:$2|raşti|raşteya}}:\n\n$1",
"gadgets-required-skins": "Zerrey {{PLURAL:$2|$1 skin|skino ke pawêno: $1}} dı esto.",
"gadgets-default": "Merduman pêron rê aktiv ke.",
- "gadgets-export": "Teber de",
+ "gadgets-export": "Teberdayış",
"gadgets-export-title": "Teberdayışê gadgeti",
"gadgets-not-found": "Gadget \"$1\" nêvineya.",
"gadgets-export-text": "Qande gadgeto $1 teber rê rusnayış ,\"{{int:gadgets-export-download}}\" rê hengnayış kerên,u dosya ke download biyo,star kerên.Wikiyê hedef de şo pela Special:Import rê and download kerên.Bahdo nuşteyê ke cerên de dero pela MediaWiki:Gadgets-definition rê bınuse:\n<pre>$2</pre>\nWikiyê ke hedefo de desturê lazımo (vurnayışê mesacanê sistemi daxilo) u dosya ra zerê rê rusnayışi enabled lazımo.",
diff --git a/www/wiki/extensions/Gadgets/i18n/es.json b/www/wiki/extensions/Gadgets/i18n/es.json
index 53aac584..89fc3384 100644
--- a/www/wiki/extensions/Gadgets/i18n/es.json
+++ b/www/wiki/extensions/Gadgets/i18n/es.json
@@ -40,11 +40,13 @@
"gadgets-validate-notset": "La propiedad <code>$1</code> no está establecida.",
"gadgets-validate-wrongtype": "La propiedad <code>$1</code> debe ser de tipo <code>$2</code> en vez de <code>$3</code>.",
"apihelp-query+gadgetcategories-description": "Devuelve una lista de categorías de accesorios.",
+ "apihelp-query+gadgetcategories-summary": "Devuelve una lista de categorías de accesorios.",
"apihelp-query+gadgetcategories-param-prop": "Qué información de categoría de accesorios se obtendrá:\n;name:Nombre interno de la categoría.\n;title:Título de la categoría.\n;members:Número de accesorios en la categoría.",
"apihelp-query+gadgetcategories-param-names": "Nombres de las categorías que se obtendrán.",
"apihelp-query+gadgetcategories-example-1": "Obtener una lista de las categorías de accesorios existentes",
"apihelp-query+gadgetcategories-example-2": "Obtener toda la información acerca de las categorías llamadas \"foo\" y \"bar\"",
"apihelp-query+gadgets-description": "Devuelve una lista de los accesorios utilizados en este wiki.",
+ "apihelp-query+gadgets-summary": "Devuelve una lista de los accesorios empleados en este wiki.",
"apihelp-query+gadgets-param-prop": "Qué información de accesorios se obtendrá:\n;id:Identificador interno del accesorio.\n;metadata:Los metadatos del accesorio.\n;desc:Descripción del accesorio transformada en HTML (puede ser lento, úsalo solo si es realmente necesario).",
"apihelp-query+gadgets-param-categories": "De qué categorías se obtendrán los accesorios.",
"apihelp-query+gadgets-param-ids": "Identificadores de los accesorios que se obtendrán.",
diff --git a/www/wiki/extensions/Gadgets/i18n/fa.json b/www/wiki/extensions/Gadgets/i18n/fa.json
index 6e1e0303..456acbd0 100644
--- a/www/wiki/extensions/Gadgets/i18n/fa.json
+++ b/www/wiki/extensions/Gadgets/i18n/fa.json
@@ -8,12 +8,13 @@
"Reza1615",
"Wayiran",
"ZxxZxxZ",
- "Mjbmr"
+ "Mjbmr",
+ "Alpineer"
]
},
"gadgets-desc": "به کاربرها امکان انتخاب [[Special:Gadgets|ابزارهای شخصی سی‌اس‌اس و جاوااسکریپت]] را از طریق صفحهٔ [[Special:Preferences#mw-prefsection-gadgets|ترجیحات]] می‌دهد",
"prefs-gadgets": "ابزارها",
- "gadgets-prefstext": "در زیر فهرستی از ابزارهای ویژه‌ای که می‌توانید برای حساب کاربری‌تان فعال کنید را می‌بینید.\nاین ابزارها در بیشتر موارد مبتنی بر جاوااسکریپت هستند، پس برای استفاده از آن‌ها باید جاوااسکرپیت را در مرورگر خودتان فعال کنید.\nتوجه کنید که این ابزارها نمی‌توانند صفحهٔ ترجیحات را تغییر دهند.\n\nدقت داشته باشد که این ابزارها جزئی از نرم‌افزار مدیاویکی نیستند، و معمولاً توسط کاربران هر ویکی ساخته و نگهداری می‌شوند.\nمدیران هر ویکی می‌توانند با استفاده از صفحه‌های [[MediaWiki:Gadgets-definition|تعاریف]] و [[Special:Gadgets|توضیحات]] به ویرایش ابزارها بپردازند.",
+ "gadgets-prefstext": "در زیر فهرستی از ابزارهای ویژه‌ای که می‌توانید برای حساب کاربری‌تان فعال کنید را می‌بینید.\nاین ابزارها در بیشتر موارد مبتنی بر جاوااسکریپت هستند، پس برای استفاده از آن‌ها باید جاوااسکرپیت را در مرورگر خودتان فعال کنید.\nتوجه کنید که این ابزارها نمی‌توانند صفحهٔ ترجیحات را تغییر دهند.\n\nهمچنین دقت داشته باشید که این ابزارها جزئی از نرم‌افزار مدیاویکی نیستند، و معمولاً توسط کاربران هر ویکی ساخته و نگهداری می‌شوند.\nمدیران هر ویکی می‌توانند با استفاده از صفحه‌های [[MediaWiki:Gadgets-definition|تعاریف]] و [[Special:Gadgets|توضیحات]] به ویرایش ابزارها بپردازند. تعداد کاربران هر ابزار در این ویکی در [[Special:GadgetUsage|آمار کاربر ابزارها]] فهرست شده‌است.",
"gadgets": "ابزارها",
"gadgetusage": "آمار استفادهٔ ابزارها",
"gadgetusage-gadget": "ابزار",
@@ -38,6 +39,18 @@
"gadgets-validate-notset": "خصوصیت <code>$1</code> تنظیم نشده‌است.",
"gadgets-validate-wrongtype": "خصوصیت <code>$1</code> به جای نوع <code>$3</code> باید از نوع <code>$2</code> باشد.",
"apihelp-query+gadgetcategories-description": "بازگرداندن فهرست رده‌های ابزار.",
+ "apihelp-query+gadgetcategories-summary": "بازگرداندن فهرست رده‌های ابزارها",
+ "apihelp-query+gadgetcategories-param-names": "نام‌های رده‌ها برای دریافت.",
+ "apihelp-query+gadgetcategories-example-1": "دریافت فهرستی از دسته‌بندی‌های ابزارهای موجود",
+ "apihelp-query+gadgets-description": "فهرست کردن همه ابزارها در این ویکی",
+ "apihelp-query+gadgets-summary": "بازگرداندن فهرست ابزارهای استفاده شده در این ویکی",
+ "apihelp-query+gadgets-param-categories": "رده‌هایی که از آن فهرست ابزارها را می‌خواهید",
+ "apihelp-query+gadgets-param-ids": "شماره گجت‌ها برای دریافت",
+ "apihelp-query+gadgets-param-allowedonly": "فقط فهرست کردن ابزارهایی که کاربر کنونی می‌تواند استفاده کند",
+ "apihelp-query+gadgets-param-enabledonly": "فهرست کردن گجت‌هایی که توسط کاربر کنونی فعال شده‌است.",
+ "apihelp-query+gadgets-example-5": "دریافت فهرستی از ابزارهای فعال‌شدهٔ کاربر جاری",
+ "right-gadgets-edit": "ویرایش صفحه‌های جاوااسکریپت و سی‌اس‌اس ابزار",
+ "action-gadgets-edit": "ویرایش صفحهٔ جاوااسکریپت و سی‌اس‌اس این ابزار",
"right-gadgets-definition-edit": "ویرایش تنظیمات ابزارها",
"action-gadgets-definition-edit": "ویرایش تنظیمات این ابزار"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/he.json b/www/wiki/extensions/Gadgets/i18n/he.json
index 46083a89..e3694691 100644
--- a/www/wiki/extensions/Gadgets/i18n/he.json
+++ b/www/wiki/extensions/Gadgets/i18n/he.json
@@ -2,7 +2,6 @@
"@metadata": {
"authors": [
"Amire80",
- "Guycn1",
"Guycn2",
"Rotem Liss",
"YaronSh"
@@ -10,7 +9,7 @@
},
"gadgets-desc": "אפשרות למשתמשים לבחור [[Special:Gadgets|סקריפטים בקוד JavaScript וסגנונות בקוד CSS]] ב[[Special:Preferences#mw-prefsection-gadgets|העדפות]] שלהם",
"prefs-gadgets": "גאדג'טים",
- "gadgets-prefstext": "להלן רשימה של גאדג'טים מיוחדים שבאפשרותך להפעיל בחשבון שלך.\nהגאדג'טים האלה מבוססים ברובם על שפת JavaScript, ולכן יש להפעיל אותה בדפדפן כדי שהם יעבדו.\nנא לשים לב לכך שלא תהיה לגאדג'טים כל השפעה על דף ההעדפות הזה.\n\nכמו־כן, יש לשים לב לכך שהגאדג'טים אינם חלק מתוכנת מדיה־ויקי, והם בדרך־כלל מפותחים ומתוחזקים על־ידי משתמשים באתר הוויקי המקומי שלכם.\nמפעילי מערכת מקומיים יכולים לערוך את ה[[MediaWiki:Gadgets-definition|הגדרות]] ואת ה[[Special:Gadgets|תיאורים]] של הגאדג'טים הזמינים. מספר המשתמשים של כל גאדג'ט רשום ב[[Special:GadgetUsage|סטטיסטיקות השימוש בגאדג'טים]].",
+ "gadgets-prefstext": "להלן רשימה של גאדג'טים מיוחדים שבאפשרותך להפעיל בחשבון שלך.\nהגאדג'טים האלה מבוססים ברובם על שפת JavaScript, ולכן יש להפעיל אותה בדפדפן כדי שהם יעבדו.\nנא לשים לב לכך שלא תהיה לגאדג'טים כל השפעה על דף ההעדפות הזה.\n\nכמו־כן, יש לשים לב לכך שהגאדג'טים אינם חלק מתוכנת מדיה־ויקי, והם בדרך־כלל מפותחים ומתוחזקים על־ידי משתמשים באתר הוויקי המקומי הזה.\nמפעילי מערכת מקומיים יכולים לערוך את ה[[MediaWiki:Gadgets-definition|הגדרות]] ואת ה[[Special:Gadgets|תיאורים]] של הגאדג'טים הזמינים. מספר המשתמשים של כל גאדג'ט רשום ב[[Special:GadgetUsage|סטטיסטיקות השימוש בגאדג'טים]].",
"gadgets": "גאדג'טים",
"gadgetusage": "סטטיסטיקת השימוש בגאדג'טים",
"gadgetusage-gadget": "גאדג'ט",
@@ -30,7 +29,7 @@
"gadgets-export": "ייצוא",
"gadgets-export-title": "ייצוא גאדג'טים",
"gadgets-not-found": "הגאדג׳ט \"$1\" לא נמצא.",
- "gadgets-export-text": "כדי לייצא את הגאדג׳ט $1, יש ללחוץ על הלחצן \"{{int:gadgets-export-download}}\", לשמור את הקובץ שהתקבל,\nלגשת אל Special:Import באתר הוויקי המיועד ולהעלות אותו. ואז להוסיף את הדברים הבאים לדף MediaWiki:Gadgets-definition:\n<pre>$2</pre>\nעליך להיות עם הרשאות מתאימות באתר הוויקי המיועד (לרבות הרשאות לעריכת הודעות מערכת) והאפשרות לייבוא מקובץ חייבת להיות מופעלת.",
+ "gadgets-export-text": "כדי לייצא את הגאדג'ט $1, יש ללחוץ על הכפתור \"{{int:gadgets-export-download}}\", לשמור את הקובץ שהתקבל,\nלגשת אל הדף Special:Import באתר הוויקי המיועד ולהעלות את הקובץ. לאחר מכן, יש להוסיף את הקוד הבא לדף MediaWiki:Gadgets-definition באתר הוויקי המיועד:\n<pre>$2</pre>\nיש להחזיק בהרשאות מתאימות באתר הוויקי המיועד (לרבות הרשאה לעריכת הודעות מערכת), והאפשרות לייבוא מקובץ חייבת להיות מופעלת.",
"gadgets-export-download": "הורדה",
"gadgets-validate-notset": "המאפיין <code>$1</code> אינו מוגדר.",
"gadgets-validate-wrongtype": "המאפיין <code>$1</code> צריך להיות מסוג <code>$2</code> ולא <code>$3</code>.",
diff --git a/www/wiki/extensions/Gadgets/i18n/hy.json b/www/wiki/extensions/Gadgets/i18n/hy.json
index cf2fb08f..fb498bc2 100644
--- a/www/wiki/extensions/Gadgets/i18n/hy.json
+++ b/www/wiki/extensions/Gadgets/i18n/hy.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Xelgen"
+ "Xelgen",
+ "Aram1985"
]
},
"gadgets-desc": "Թույլ է տալիս օգտագործողներին ընտրել հատուկ [[Special:Gadgets|ՍիԷսԷս և ՋավաՍկիրպտ (CSS and JavaScript) գադջեթներ]] իրանց [[Special:Preferences#mw-prefsection-gadgets|նախընտրությունների]] էջում։",
@@ -12,7 +13,7 @@
"gadgets-uses": "Օգտագործում է",
"gadgets-required-rights": "Անհրաժեշտ են հետևյալ {{PLURAL:$2|իրավունքը|իրավունքները}}:\n\n$1",
"gadgets-required-skins": "Հասանելի է {{PLURAL:$2|$1 արտաքին տեսքով|$1 արտաքին տեսքերով}}։",
- "gadgets-default": "Ի լռելյայն միացված է բոլորի համար։",
+ "gadgets-default": "Լռելյայն միացված է բոլորի համար։",
"gadgets-export": "Արտահանել",
"gadgets-export-title": "Գադջեթի արտահանում",
"gadgets-not-found": "$1 գադջեթը չի գտնվել",
diff --git a/www/wiki/extensions/Gadgets/i18n/id.json b/www/wiki/extensions/Gadgets/i18n/id.json
index e73447ab..3fc8d8a4 100644
--- a/www/wiki/extensions/Gadgets/i18n/id.json
+++ b/www/wiki/extensions/Gadgets/i18n/id.json
@@ -17,7 +17,7 @@
"gadgetusage-gadget": "Perkakas",
"gadgetusage-usercount": "Jumlah pengguna",
"gadgetusage-noresults": "Perkakas tidak ditemukan",
- "gadgetusage-summary": "Tabel ini menunjukkan jumlah pengguna yang telah mengaktifkan perkakas pada wiki ini. Daftar ini tidak memasukkan data perkakas yang telah diaktifkan secara baku, dan juga mungkin termasuk perkakas yang sudah tidak ada.",
+ "gadgetusage-intro": "Tabel ini menunjukkan jumlah pengguna yang telah mengaktifkan perkakas pada wiki ini. Daftar ini tidak memasukkan data perkakas yang telah diaktifkan secara baku, dan juga mungkin termasuk perkakas yang sudah tidak ada.",
"gadgets-title": "Perkakas",
"gadgets-pagetext": "Berikut adalah daftar perkakas istimewa yang dapat diaktifkan pengguna melalui [[Special:Preferences#mw-prefsection-gadgets|halaman preferensi]] mereka sebagaimana didefinisikan oleh [[MediaWiki:Gadgets-definition]]. Tinjauan berikut memberikan kemudahan akses ke dalam halaman pesan sistem yang mendefinisikan deskripsi dan kode masing-masing perkakas.",
"gadgets-uses": "Penggunaan",
diff --git a/www/wiki/extensions/Gadgets/i18n/io.json b/www/wiki/extensions/Gadgets/i18n/io.json
index 4e19f43b..4004be09 100644
--- a/www/wiki/extensions/Gadgets/i18n/io.json
+++ b/www/wiki/extensions/Gadgets/i18n/io.json
@@ -1,8 +1,14 @@
{
"@metadata": {
"authors": [
- "Malafaya"
+ "Malafaya",
+ "Joao Xavier"
]
},
+ "prefs-gadgets": "Utensili",
+ "gadgets-prefstext": "Adinfre esas listo pri specala utensili quin vu povas permisar por vua konto.\nIca utensili kreesis precipue per 'JavaScript', do vu mustas permisar JavaScript en vua retnavigilo por uzar li.\nRegardez ke ica utensili efektigos nule en ica pagino pri preferaji.\n\nAnke regardez ke ta specala utensili NE ESAS PARTO DE LA SOFTWARO* di MediaWiki, ed ordinare kreesas e mantenesas da altra uzeri de vua lokala wiki.\nLokala administreri povas skribar [[MediaWiki:Gadgets-definition|defini]] e [[Special:Gadgets|deskripti]] pri l'existanta utensili ('gadgets'). Listo pri la quanto di uzeri por singla 'gadget' en ica wiki povas videsar en la [[Special:GadgetUsage|statistiki pri uzo di 'Gadget'-i]].",
+ "gadgets": "Aparati:",
+ "gadgetusage-activeusers": "Aktiva uzeri",
+ "gadgets-title": "Aparati",
"gadgets-uses": "Ol uzas"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/is.json b/www/wiki/extensions/Gadgets/i18n/is.json
index 0ae288c0..b5d5ae19 100644
--- a/www/wiki/extensions/Gadgets/i18n/is.json
+++ b/www/wiki/extensions/Gadgets/i18n/is.json
@@ -3,13 +3,16 @@
"authors": [
"Jóna Þórunn",
"Maxí",
- "Snævar"
+ "Snævar",
+ "Sveinn í Felli"
]
},
"gadgets-desc": "Gerir notendum kleift að velja [[Special:Gadgets|CSS og JavaScript-forrit]] í [[Special:Preferences#mw-prefsection-gadgets|stillingum sínum]]",
"prefs-gadgets": "Smáforrit",
"gadgets-prefstext": "Eftirfarandi er listi yfir smáforrit sem þú getur notað á notandareikningi þínum. Þessi forrit eru að mestu byggð á JavaScript svo vafrinn þarf að styðja JavaScript til að þau virki. Athugaðu einnig að forritin hafa engin áhrif á stillingasíðunni.\n\nForritin eru ekki hluti af MediaWiki-hugbúnaðinum heldur eru skrifuð og viðhaldin af notendum á þessu wiki-verkefni. Möppudýr geta breytt forritunum á [[MediaWiki:Gadgets-definition]] og [[Special:Gadgets]]. Fjöldi notenda sem nota hvert smától fyrir sig er skráður á [[Special:GadgetUsage|Notkunarupplýsingar smátóla]].",
"gadgets": "Smáforrit",
+ "gadgetusage-activeusers": "Virkir notendur",
+ "gadgetusage-default": "Sjálfgefið",
"gadgets-title": "Smáforrit",
"gadgets-pagetext": "Eftirfarandi er listi yfir smáforrit sem notendur geta virkjað í [[Special:Preferences#mw-prefsection-gadgets|stillingunum sínum]] og eru tilgreind á [[MediaWiki:Gadgets-definition]].\nÞessi listi veitir auðveldan aðgang að lýsingum á smáforritunum og kóðanum þeirra.",
"gadgets-uses": "Notar",
diff --git a/www/wiki/extensions/Gadgets/i18n/ja.json b/www/wiki/extensions/Gadgets/i18n/ja.json
index 9282fd20..3a6fb421 100644
--- a/www/wiki/extensions/Gadgets/i18n/ja.json
+++ b/www/wiki/extensions/Gadgets/i18n/ja.json
@@ -11,7 +11,8 @@
"SkyDaisy9",
"Sujiniku",
"Otokoume",
- "2nd-player"
+ "2nd-player",
+ "Yusuke1109"
]
},
"gadgets-desc": "利用者が [[Special:Gadgets|CSS や JavaScript のカスタム ガジェット]]を[[Special:Preferences#mw-prefsection-gadgets|{{int:preferences}}]]で選択できるようにする",
@@ -41,11 +42,13 @@
"gadgets-validate-notset": "プロパティ <code>$1</code> が設定されていません。",
"gadgets-validate-wrongtype": "プロパティ <code>$1</code> は型 <code>$3</code> ではなく <code>$2</code> でなければなりません。",
"apihelp-query+gadgetcategories-description": "ガジェットのカテゴリの一覧を返します。",
+ "apihelp-query+gadgetcategories-summary": "ガジェットのカテゴリの一覧を返します。",
"apihelp-query+gadgetcategories-param-prop": "ガジェットのカテゴリのどの情報を取得するかです:\n;name:内部カテゴリ名です。\n;title:カテゴリ名です。\n;members:カテゴリ内のガジェット数です。",
"apihelp-query+gadgetcategories-param-names": "取得するカテゴリの名前です。",
"apihelp-query+gadgetcategories-example-1": "既存のガジェットのカテゴリの一覧を取得",
"apihelp-query+gadgetcategories-example-2": "「foo」および「bar」という名前のカテゴリについてすべての情報を取得",
"apihelp-query+gadgets-description": "このウィキで使用されているガジェットの一覧を返します。",
+ "apihelp-query+gadgets-summary": "このウィキで使用されているガジェットの一覧を返します。",
"apihelp-query+gadgets-param-prop": "ガジェットのどの情報を取得するかです:\n;id:内部ガジェット ID です。\n;metadata:ガジェットのメタデータです。\n;desc:ガジェットの説明を HTML 形式に変換したものです (時間がかかる場合があるため、本当に必要な場合のみ使用してください)。",
"apihelp-query+gadgets-param-categories": "どのカテゴリからガジェットを取得するかです。",
"apihelp-query+gadgets-param-ids": "取得するガジェットの ID です。",
diff --git a/www/wiki/extensions/Gadgets/i18n/jv.json b/www/wiki/extensions/Gadgets/i18n/jv.json
index c9ac0c3c..6d691a38 100644
--- a/www/wiki/extensions/Gadgets/i18n/jv.json
+++ b/www/wiki/extensions/Gadgets/i18n/jv.json
@@ -18,7 +18,7 @@
"gadgetusage-activeusers": "Para nganggo sing giyat",
"gadgetusage-default": "Baku",
"gadgets-title": "Géjet",
- "gadgets-pagetext": "Ing ngisor iki daftar gadget astaméwa sing bisa diaktifaké ing [[Special:Preferences#mw-prefsection-gadgets|kaca prèferènsi]] panganggo, kayadéné didéfinisi déning [[MediaWiki:Gadgets-definition|dhéfinisi]].\nTinjoan iki mènèhi aksès sing gampang menyang kaca-kaca pesen sistem sing ngawedhar saben gadget lan kodhe.",
+ "gadgets-pagetext": "Ing ngisor iki kapacak pratélaning géjet mirunggan sing bisa diurubaké déning saben panganggo saka [[Special:Preferences#mw-prefsection-gadgets|kaca pilalané]], kaya sing diandharaké ing [[MediaWiki:Gadgets-definition|kaca dhéfinisiné]].\nKaterangan iki migunani murih gampangé panjenengan mangerti kaca layang sistem sing ngandharaké dhèskripsi lan kodhe géjet.",
"gadgets-uses": "Guna",
"gadgets-required-rights": "Mbutuhaké {{PLURAL:$2|hak}} ing ngisor iki:\n\n$1",
"gadgets-required-skins": "Ana ing {{PLURAL:$2|ules $1|ules iki: $1}}.",
diff --git a/www/wiki/extensions/Gadgets/i18n/ksh.json b/www/wiki/extensions/Gadgets/i18n/ksh.json
index b7a631b6..7db8506a 100644
--- a/www/wiki/extensions/Gadgets/i18n/ksh.json
+++ b/www/wiki/extensions/Gadgets/i18n/ksh.json
@@ -13,7 +13,7 @@
"gadgetusage-gadget": "Zohbehür",
"gadgetusage-usercount": "Aanzahl Metmaacher",
"gadgetusage-noresults": "Keine Zohbehür jefonge.",
- "gadgetusage-summary": "En dä Tabäll heh es opjeföhrt, wi vill Metmaacher ene beschtemmpte Zohbehür ennjeschalldt han un aam bruche sin. Do es och Zohbehür bei, dä jäz nit mih ze hann es.",
+ "gadgetusage-intro": "En dä Tabäll heh es opjeföhrt, wi vill Metmaacher ene beschtemmpte Zohbehür ennjeschalldt han un aam bruche sin. Do es och Zohbehür bei, dä jäz nit mih ze hann es.",
"gadgets-title": "<i lang=\"en\">Gadgets</i>",
"gadgets-pagetext": "He kütt en Liss met spezielle <i lang=\"en\">Gadgets</i>,\ndi jede Metmaacher övver sing\n[[Special:Preferences#mw-prefsection-gadgets|päsönlije Enstellunge]] enschallte kann.\nSe wääde övver [[MediaWiki:Gadgets-definition]] enjerecht.\nDi Övverseesch hee jit enne direkte Zohjang op di Täxte em Wikki,\nwo de Projramme, un de Erklierunge för de <i lang=\"en\">Gadgets</i> dren enthallde\nsin.",
"gadgets-uses": "Bruch",
diff --git a/www/wiki/extensions/Gadgets/i18n/lb.json b/www/wiki/extensions/Gadgets/i18n/lb.json
index d37523ab..0f4fc1b4 100644
--- a/www/wiki/extensions/Gadgets/i18n/lb.json
+++ b/www/wiki/extensions/Gadgets/i18n/lb.json
@@ -25,7 +25,7 @@
"gadgets-export": "Export",
"gadgets-export-title": "Export vu Gadgeten",
"gadgets-not-found": "Gadget \"$1\" net fonnt.",
- "gadgets-export-text": "Fir de Gadget $1 z'exportéieren klickt w.e.g. op de(n) \"{{int:gadgets-export-download}}\"-Knäppchen, späichert den erofgelueden Fichier, gitt op Spezial:Import op der Zil-Wiki a luet en do erop. Duerno setzt der op d'MediaWiki:Gadgets-Definitiouns Säit dëst derbäi:<pre>$2</pre>\nDir musst déi erfuerdert Rechter(inklusiv d'Recht fir Systemmessagen z'änneren) op der Zil-Wiki hunn an den Import vun eropgelueden Fichiere muss ageschalt sinn.",
+ "gadgets-export-text": "Fir de Gadget $1 z'exportéieren klickt w.e.g. op de(n) \"{{int:gadgets-export-download}}\"-Knäppchen, späichert den erofgelueden Fichier, gitt op Spezial:Import op der Zil-Wiki a luet en do erop. Duerno setzt der op d'MediaWiki:Gadgets-Definitiouns Säit dëst dobäi:<pre>$2</pre>\nDir musst déi erfuerdert Rechter(inklusiv d'Recht fir Systemmessagen z'änneren) op der Zil-Wiki hunn an den Import vun eropgelueden Fichiere muss ageschalt sinn.",
"gadgets-export-download": "Eroflueden",
"apihelp-query+gadgets-param-allowedonly": "Nëmme Gadgeten opzielen déi fir den aktuelle Benotzer erlaabt sinn.",
"apihelp-query+gadgets-example-5": "D'Lëscht vun de Gadgete kréien déi den aktuelle Benotzer aktivéiert huet",
diff --git a/www/wiki/extensions/Gadgets/i18n/mg.json b/www/wiki/extensions/Gadgets/i18n/mg.json
index 921fc533..d7331e65 100644
--- a/www/wiki/extensions/Gadgets/i18n/mg.json
+++ b/www/wiki/extensions/Gadgets/i18n/mg.json
@@ -1,14 +1,24 @@
{
"@metadata": {
"authors": [
- "Jagwar"
+ "Jagwar",
+ "V.narsikar"
]
},
- "gadgets": "Gadget",
+ "prefs-gadgets": "उपकरणे (गॅजेट्स)",
+ "gadgets": "उपकरणे (गॅजेट्स)",
+ "gadgetusage": "उपकरणाच्या वापराची सांख्यिकी",
+ "gadgetusage-gadget": "उपकरण (गॅजेट)",
+ "gadgetusage-usercount": "वापरणाऱ्यांची संख्या",
+ "gadgetusage-noresults": "उपकरणे सापडली नाहीत.",
+ "gadgetusage-activeusers": "सक्रिय सदस्य",
+ "gadgetusage-default": "अविचल",
"gadgets-title": "Gadget",
"gadgets-uses": "Mampiasa",
"gadgets-export": "Hamoaka",
"gadgets-export-title": "Famoahana gadget",
"gadgets-not-found": "Tsy hita ny gadget « $1 ».",
- "gadgets-export-download": "Hampidina"
+ "gadgets-export-download": "Hampidina",
+ "right-gadgets-definition-edit": "उपकरणाच्या व्याख्या संपादा",
+ "action-gadgets-definition-edit": "ही उपकरण व्याख्या संपादा"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/min.json b/www/wiki/extensions/Gadgets/i18n/min.json
index 167bf6ca..07286aa5 100644
--- a/www/wiki/extensions/Gadgets/i18n/min.json
+++ b/www/wiki/extensions/Gadgets/i18n/min.json
@@ -9,7 +9,7 @@
"gadgets-prefstext": "Di bawah ko daftar pakakeh istimewa nan dapek Sanak aktipan untuak akun Sanak. Kasado pakakeh ko sabagian babasis JavaScript dek itu Sanak musti mangaktipan JavaScript pado paramban Sanak untuak dapek manjalankannyo. Paratikan kalau babagai pakakek ko indak ado pangaruahnyo pado laman pangaturan ko.\n\nSalain tu paratikan juo kalau pakakeh ko bukanlah bagian dari parangkaik lunak MediaWiki dan biasonyo dikambangkan dan dijago dek pangguno di Wikipedia. Panguruih lokal dapek manyuntiang pakakeh nan ado malalui [[MediaWiki:Gadgets-definition|laman definisinyo]] ataupun pado [[Special:Gadgets|laman katarangannyo]].",
"gadgets": "Pakakeh",
"gadgetusage": "Statistik panggunoan pakakeh",
- "gadgetusage-summary": "Tabel iko manunjuakkan jumlah pangguno nan alah mangaktipkan pakakeh pado wiki ko. Iko mungkin tamasuak jou pakakeh nan alah indak ado.",
+ "gadgetusage-intro": "Tabel iko manunjuakkan jumlah pangguno nan alah mangaktipkan pakakeh pado wiki ko. Iko mungkin tamasuak jou pakakeh nan alah indak ado.",
"gadgets-title": "Pakakeh",
"gadgets-pagetext": "Di bawah ko daftar pakakeh istimewa nan dapek diaktipan pangguno malalui [[Special:Preferences#mw-prefsection-gadgets|laman pangaturan]] saroman nan didefinisikan dek [[MediaWiki:Gadgets-definition|laman definisinyo]]. Tinjauan nan ko mangagiah akses ka laman pasan sistem nan mandefinisikan deskripsi jo kode masiang-masiang pakakeh.",
"gadgets-uses": "Panggunoan",
diff --git a/www/wiki/extensions/Gadgets/i18n/mr.json b/www/wiki/extensions/Gadgets/i18n/mr.json
index 84c23f06..2385cc96 100644
--- a/www/wiki/extensions/Gadgets/i18n/mr.json
+++ b/www/wiki/extensions/Gadgets/i18n/mr.json
@@ -8,10 +8,10 @@
]
},
"gadgets-desc": "सदस्यांना त्यांच्या [[Special:Preferences#mw-prefsection-gadgets|पसंतीची]] [[Special:Gadgets|CSS व जावास्क्रीप्ट गॅजेट्स]] निवडण्याची परवानगी देते.",
- "prefs-gadgets": "उपकरण(गॅजेट)",
+ "prefs-gadgets": "उपकरण (गॅजेट)",
"gadgets-prefstext": "खाली तुम्ही तुमच्या सदस्यखात्यासाठी वापरू शकत असलेल्या गॅजेट्सची यादी दिलेली आहे. ही गॅजेट्स मुख्यत्वे जावास्क्रीप्टवर अवलंबून असल्यामुळे तुमच्या न्याहाळकात(ब्राउजर) जावास्क्रीप्ट सक्षम(एनेबल) असणे आवश्यक आहे. या गॅजेट्समुळे या पसंतीच्या पानावर कुठलेही परिणाम होणार नाहीत याची कृपया नोंद घ्यावी.\n\nतसेच ही गॅजेट्स मीडियाविकी प्रणालीचा हिस्सा नाहीत, व ही मुख्यत्वे स्थानिक विकिवर सदस्यांद्वारे उपलब्ध केली जातात. \n\nस्थानिक प्रचालक उपलब्ध गॅजेट्स [[MediaWiki:Gadgets-definition|व्याख्या]] व [[Special:Gadgets|वर्णने]] वापरून बदलू शकतात.\nप्रत्येक गॅजेट वापरणाऱ्या सदस्यांच्या संख्येची या विकिवरची यादी [[Special:GadgetUsage|गॅजेट वापराची सांख्यिकी]] येथे आहे .",
"gadgets": "सुविधा (गॅजेट)",
- "gadgetusage": "सुविधा वापरणऱ्यांची सांख्यिकी",
+ "gadgetusage": "सुविधा वापरणाऱ्यांची सांख्यिकी",
"gadgetusage-gadget": "सुविधा (गॅजेट)",
"gadgetusage-usercount": "सदस्यांची संख्या",
"gadgetusage-noresults": "सुविधा सापडल्या नाहीत.",
@@ -31,11 +31,13 @@
"gadgets-export-text": "$1 उपकरण-सुविधा निर्यात करण्याकरिता, \"{{int:gadgets-export-download}}\" कळीवर टिचकी मारा, उतरवलेली संचिका-फाईल जतन करा\nडेस्टिनेशन विकिच्या विशेष:आयात पानावर जाऊन संचिका-फाईल चढवावी.नंतर खालील MediaWiki:Gadgets-definition पान चढवावे :\n<pre>$2</pre>\nतुमच्याकडे डेस्टिनेशन विकिवर (सिस्टीम मेसेजेस सुद्धा संपादीत करण्यासहीत ) सुयोग्य परवानग्या उपलब्ध असणे अत्यावश्यक आहे आणि चढवलेल्या संचिकाकरिता आयात सुविधा सक्षम असणे आवश्यक आहे.",
"gadgets-export-download": "अधिभारण करा",
"apihelp-query+gadgetcategories-description": "उपकरण वर्गाची यादीच्या स्वरुपात परतावा देते.",
+ "apihelp-query+gadgetcategories-summary": "उपकरण वर्गाची यादीच्या स्वरुपात परतावा देते.",
"apihelp-query+gadgetcategories-param-prop": "कोणत्या उपकरण वर्गाची माहिती मिळवायची:\n;name:अंतर्गत वर्गाचे नाव.\n;title:वर्ग शीर्षक.\n;members:वर्गात असलेल्या उपकरणांची संख्या.",
"apihelp-query+gadgetcategories-param-names": "हुडकायच्या वर्गांची नावे.",
"apihelp-query+gadgetcategories-example-1": "अस्तित्वात असलेल्या उपकरण वर्गांची यादी प्राप्त करा",
"apihelp-query+gadgetcategories-example-2": "\"foo\" व \"bar\" या वर्गांबद्दलची संपूर्ण माहिती प्राप्त करा",
"apihelp-query+gadgets-description": "या विकिवर असलेल्या सर्व उपकरणांच्या यादीचा परतावा देते.",
+ "apihelp-query+gadgets-summary": "या विकिवर असलेल्या सर्व उपकरणांच्या यादीचा परतावा देते.",
"apihelp-query+gadgets-param-prop": "कोणत्या उपकरणांची माहिती मिळवायची:\n;id:अंतर्गत उपकरण ओळखण.\n;metadata:त्या उपकरणाचा मेटाडाटा.\n;desc:HTML मध्ये रुपांतरीत उपकरणाचे वर्णन(हे हळु असण्याची शक्यता आहे,खरेच आवश्यक असेल तर वापरा).",
"apihelp-query+gadgets-param-categories": "उपकरणे कोणत्या वर्गांतुन हुडकायची.",
"apihelp-query+gadgets-param-ids": "हुडकायच्या उपकरणांच्या ओळखण्या (IDs)",
diff --git a/www/wiki/extensions/Gadgets/i18n/mwl.json b/www/wiki/extensions/Gadgets/i18n/mwl.json
index 825c3928..36d77081 100644
--- a/www/wiki/extensions/Gadgets/i18n/mwl.json
+++ b/www/wiki/extensions/Gadgets/i18n/mwl.json
@@ -1,14 +1,17 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
"gadgets-desc": "Premite que ls outelizadores selecionen [[Special:Gadgets|''gadgets'' an JavaScript i CSS]] personalizados nas sues [[Special:Preferences#mw-prefsection-gadgets|perfréncias]]",
"prefs-gadgets": "Gadgets",
"gadgets": "Gadgets",
+ "gadgetusage": "Statísticas de la outelizaçon de gadgets",
"gadgets-title": "Gadgets",
"gadgets-pagetext": "Ambaixo hai ua lhista de ''gadgets'' que puoden ser atibados puls outelizadores nas sues [[Special:Preferences#mw-prefsection-gadgets|perfréncias]], cumo stablecido pulas [[MediaWiki:Gadgets-definition|defeniçones]].\nEste resumo proporciona acesso fácele a las páiginas de las mensaiges de l sistema que definen la çcriçon i l código de cada ''gadget''.",
"gadgets-uses": "Outeliza",
+ "gadgets-default": "Atibado pa todos por padron.",
"gadgets-export": "Sportar"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/nl.json b/www/wiki/extensions/Gadgets/i18n/nl.json
index f750baa8..af5e17f0 100644
--- a/www/wiki/extensions/Gadgets/i18n/nl.json
+++ b/www/wiki/extensions/Gadgets/i18n/nl.json
@@ -7,7 +7,9 @@
"Esketti",
"Sjoerddebruin",
"Romaine",
- "Edoderoo"
+ "Edoderoo",
+ "Mainframe98",
+ "Mar(c)"
]
},
"gadgets-desc": "Laat gebruikers [[Special:Gadgets|CSS en JavaScripts]] activeren in hun [[Special:Preferences#mw-prefsection-gadgets|voorkeuren]]",
@@ -37,21 +39,23 @@
"gadgets-validate-notset": "De eigenschap <code>$1</code> is niet ingesteld.",
"gadgets-validate-wrongtype": "De eigenschap <code>$1</code> moet van het type <code>$2</code> zijn in plaats van <code>$3</code>.",
"apihelp-query+gadgetcategories-description": "Geeft een lijst met uitbreidingscategorieën terug.",
+ "apihelp-query+gadgetcategories-summary": "Geeft een lijst met uitbreidingscategorieën terug.",
"apihelp-query+gadgetcategories-param-prop": "Welke uitbreidingscategoriegegevens op te halen:\n;name:Interne naam van de categorie;\n;title:Categorienaam;\n;members:Aantal uitbreidingen in de categorie.",
"apihelp-query+gadgetcategories-param-names": "Namen van op te halen categorieën.",
- "apihelp-query+gadgetcategories-example-1": "Een lijst van bestaande uitbreidingscategorieën",
- "apihelp-query+gadgetcategories-example-2": "Alle informatie opvragen over categorieën met de naam \"foo\" en \"bar\"",
+ "apihelp-query+gadgetcategories-example-1": "Een lijst van bestaande uitbreidingscategorieën opvragen.",
+ "apihelp-query+gadgetcategories-example-2": "Alle informatie over categorieën met de naam \"foo\" en \"bar\" opvragen.",
"apihelp-query+gadgets-description": "Geeft een lijst terug met in deze wiki gebruikte uitbreidingen.",
+ "apihelp-query+gadgets-summary": "Geeft een lijst terug met in deze wiki gebruikte uitbreidingen.",
"apihelp-query+gadgets-param-prop": "Welke uitbreidingsgegevens op te halen:\n;id:Intern uitbreidings-ID;\n;metadata:De metadata van de uitbreiding;\n;desc:Beschrijving van de uitbreiding in HTML (kan langzaam zijn, gebruik alleen als echt nodig).",
"apihelp-query+gadgets-param-categories": "Uitbreidingen uit welke categorieën op te halen.",
"apihelp-query+gadgets-param-ids": "ID's van uitbreidingen om op te halen.",
"apihelp-query+gadgets-param-allowedonly": "Alleen uitbreidingen laten zien die toegestaan zijn voor de huidige gebruiker.",
"apihelp-query+gadgets-param-enabledonly": "Alleen uitbreidingen weergeven die zijn ingeschakeld door de huidige gebruiker.",
- "apihelp-query+gadgets-example-1": "Een lijst ophalen met uitbreidingen met hun beschrijvingen",
- "apihelp-query+gadgets-example-2": "Haal een lijst met uitbreidingen inclusief alle mogelijke eigenschappen op",
- "apihelp-query+gadgets-example-3": "Haal een lijst op met uitbreidingen uit de categorie \"foo\"",
- "apihelp-query+gadgets-example-4": "Gegevens opvragen over de uitbreidingen \"foo\" en \"bar\"",
- "apihelp-query+gadgets-example-5": "Haal een lijst op met uitbreidingen die zijn ingeschakeld door de huidige gebruiker",
+ "apihelp-query+gadgets-example-1": "Een lijst van uitbreidingen met hun beschrijvingen ophalen.",
+ "apihelp-query+gadgets-example-2": "Een lijst van uitbreidingen inclusief alle mogelijke eigenschappen ophalen.",
+ "apihelp-query+gadgets-example-3": "Een lijst van uitbreidingen uit de categorie \"foo\" ophalen.",
+ "apihelp-query+gadgets-example-4": "Gegevens over de uitbreidingen \"foo\" en \"bar\" ophalen.",
+ "apihelp-query+gadgets-example-5": "Een lijst van door de huidige gebruiker ingeschakelde uitbreidingen opvragen.",
"right-gadgets-edit": "JavaScript- en CSS-pagina's voor de uitbreiding bewerken",
"action-gadgets-edit": "deze JavaScript- of CSS-pagina te bewerken",
"right-gadgets-definition-edit": "Uitbreidingsdefinities bewerken",
diff --git a/www/wiki/extensions/Gadgets/i18n/pl.json b/www/wiki/extensions/Gadgets/i18n/pl.json
index c302d2cd..f9e8bfa9 100644
--- a/www/wiki/extensions/Gadgets/i18n/pl.json
+++ b/www/wiki/extensions/Gadgets/i18n/pl.json
@@ -8,7 +8,8 @@
"Sovq",
"Sp5uhe",
"Peter Bowman",
- "Woytecr"
+ "Woytecr",
+ "Railfail536"
]
},
"gadgets-desc": "Pozwala użytkownikom wybrać [[Special:Gadgets|gadżety CSS i JavaScript]] na [[Special:Preferences#mw-prefsection-gadgets|stronie preferencji]]",
@@ -38,11 +39,13 @@
"gadgets-validate-notset": "Właściwość <code>$1</code> nie jest ustawiona.",
"gadgets-validate-wrongtype": "Właściwość <code>$1</code> musi być typem <code>$2</code> zamiast <code>$3</code>.",
"apihelp-query+gadgetcategories-description": "Zwraca listę kategorii gadżetów.",
+ "apihelp-query+gadgetcategories-summary": "Zwraca listę kategorii gadżetów.",
"apihelp-query+gadgetcategories-param-prop": "Jakie informacje o kategorii gadżetów pobrać:\n;name:Wewnętrzna nazwa kategorii.\n;title:Tytuł kategorii.\n;members:Liczba gadżetów w kategorii.",
"apihelp-query+gadgetcategories-param-names": "Nazwy kategorii do pobrania.",
"apihelp-query+gadgetcategories-example-1": "Pobierz listę istniejących kategorii gadżetów",
"apihelp-query+gadgetcategories-example-2": "Pobierz wszystkie informacje na temat kategorii o nazwach „foo” i „bar”",
"apihelp-query+gadgets-description": "Zwraca listę gadżetów używanych na tej wiki.",
+ "apihelp-query+gadgets-summary": "Zwraca listę gadżetów używanych na tej wiki.",
"apihelp-query+gadgets-param-prop": "Jakie informacje o gadżetach pobrać:\n;id:Wewnętrzny ID gadżetu.\n;metadata:Metadane gadżetu.\n;desc:Opis gadżetu przekształcony na HTML (może być powolne, użyj tylko jeśli naprawdę potrzeba).",
"apihelp-query+gadgets-param-categories": "Z jakiej kategorii mają być pobrane informacje o gadżetach.",
"apihelp-query+gadgets-param-ids": "Identyfikatory gadżetów do pobrania.",
diff --git a/www/wiki/extensions/Gadgets/i18n/pt-br.json b/www/wiki/extensions/Gadgets/i18n/pt-br.json
index 39a548ce..be47a0ba 100644
--- a/www/wiki/extensions/Gadgets/i18n/pt-br.json
+++ b/www/wiki/extensions/Gadgets/i18n/pt-br.json
@@ -17,7 +17,7 @@
},
"gadgets-desc": "Permite que os usuários selecionem [[Special:Gadgets|\"gadgets\" JavaScript e CSS]] personalizados nas suas [[Special:Preferences#mw-prefsection-gadgets|preferências]]",
"prefs-gadgets": "Gadgets",
- "gadgets-prefstext": "Segue-se uma lista de \"gadgets\" que podem ser ativados em sua conta.\nTais gadgets normalmente são baseados em JavaScript, o que faz com que seja necessário que o suporte a JavaScript esteja ativado em seu navegador para que eles funcionem.\nNote que os gadgets não possuem efeito nesta página de preferências.\n\nRepare também que tais gadgets não são parte do software MediaWiki, geralmente sendo desenvolvidos e mantidos por usuários da sua wiki local.\nAdministradores locais podem editar os gadgets disponíveis através de [[MediaWiki:Gadgets-definition|definições]] e [[Special:Gadgets|descrições]] de gadgets disponíveis. O número de usuários para cada gadget nesta wiki está listado em [[Special:GadgetUsage|Gadget usage statistics]].",
+ "gadgets-prefstext": "Segue-se uma lista de \"gadgets\" que podem ser ativados em sua conta.\nTais gadgets normalmente são baseados em JavaScript, o que faz com que seja necessário que o suporte a JavaScript esteja ativado em seu navegador para que eles funcionem.\nNote que os gadgets não possuem efeito nesta página de preferências.\n\nRepare também que tais gadgets não são parte do software MediaWiki, geralmente sendo desenvolvidos e mantidos por usuários da sua wiki local.\nAdministradores locais podem editar os gadgets disponíveis através de [[MediaWiki:Gadgets-definition|definições]] e [[Special:Gadgets|descrições]] de gadgets disponíveis. O número de usuários para cada gadget nesta wiki está listado em [[Special:GadgetUsage|estatísticas de uso de gadgets]].",
"gadgets": "Gadgets",
"gadgetusage": "Estatísticas de uso de gadgets",
"gadgetusage-gadget": "Gadgets",
diff --git a/www/wiki/extensions/Gadgets/i18n/ro.json b/www/wiki/extensions/Gadgets/i18n/ro.json
index 38350057..01ce9f19 100644
--- a/www/wiki/extensions/Gadgets/i18n/ro.json
+++ b/www/wiki/extensions/Gadgets/i18n/ro.json
@@ -6,14 +6,19 @@
"KlaudiuMihaila",
"Minisarm",
"Stelistcristi",
- "XXN"
+ "XXN",
+ "Strainu"
]
},
"gadgets-desc": "Permite utilizatorilor să își aleagă [[Special:Gadgets|gadgeturi CSS și JavaScript]] în [[Special:Preferences#mw-prefsection-gadgets|preferințele]] lor",
"prefs-gadgets": "Gadgeturi",
"gadgets": "Gadgeturi",
"gadgetusage": "Statistici de utilizare a gadgeturilor",
+ "gadgetusage-gadget": "Gadget",
"gadgetusage-usercount": "Număr de utilizatori",
+ "gadgetusage-noresults": "Niciun gadget găsit.",
+ "gadgetusage-activeusers": "Utilizatori activi",
+ "gadgetusage-default": "Implicit",
"gadgets-title": "Gadgeturi",
"gadgets-uses": "Utilizări",
"gadgets-required-rights": "Necesită {{PLURAL:$2|următorul drept|următoarele drepturi}}:\n\n$1",
@@ -22,5 +27,15 @@
"gadgets-export": "Exportă",
"gadgets-export-title": "Exportul de gadgeturi",
"gadgets-not-found": "Gadgetul „$1” nu a fost găsit.",
- "gadgets-export-download": "Descarcă"
+ "gadgets-export-download": "Descarcă",
+ "apihelp-query+gadgetcategories-description": "Întoarce o listă de categorii pentru gadgeturi.",
+ "apihelp-query+gadgetcategories-summary": "Întoarce o listă de categorii pentru gadgeturi.",
+ "apihelp-query+gadgetcategories-param-names": "Numele categoriilor de obținut.",
+ "apihelp-query+gadgetcategories-example-1": "Obține o listă a categoriilor de gadgeturi existente",
+ "apihelp-query+gadgets-description": "Întoarce o listă a tuturor gadgeturilor folosite pe acest wiki.",
+ "apihelp-query+gadgets-summary": "Întoarce o listă a tuturor gadgeturilor folosite pe acest wiki.",
+ "apihelp-query+gadgets-param-allowedonly": "Prezintă doar gadgeturile accesibile utilizatorului curent.",
+ "apihelp-query+gadgets-param-enabledonly": "Prezintă doar gadgeturile activate de utilizatorul curent.",
+ "apihelp-query+gadgets-example-1": "Obține o listă de gadgeturi cu descrierile lor",
+ "apihelp-query+gadgets-example-2": "Obține o listă de gadgeturi cu toate propietățile posibile"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/roa-tara.json b/www/wiki/extensions/Gadgets/i18n/roa-tara.json
index 76ea0a70..8bdd5a4b 100644
--- a/www/wiki/extensions/Gadgets/i18n/roa-tara.json
+++ b/www/wiki/extensions/Gadgets/i18n/roa-tara.json
@@ -26,5 +26,10 @@
"gadgets-export-text": "Pe esportà 'u $1 gadget, cazze sus a 'u buttone \"{{int:gadgets-export-download}}\", reggistre 'u file scarecate, veje'a pàgene Special:Import sus 'a Uicchi de destinazione e carechele. Pò aggiunge 'a seguende pàgene MediaWiki:Gadgets-definition:\n<pre>$2</pre>\nTu a ave le permesse appropriate sus 'a Uicchi de destinazione (ingludenne le deritte a cangià le messagge d'u sisteme) e 'a 'mbortazione da file carecate adda essere abbilitate.",
"gadgets-export-download": "Scareche",
"apihelp-query+gadgetcategories-description": "Tuèrne 'n'elenghe de le categorije de le accessore.",
- "apihelp-query+gadgetcategories-summary": "Tuèrne 'n'elenghe de le categorije de le accessore."
+ "apihelp-query+gadgetcategories-summary": "Tuèrne 'n'elenghe de le categorije de le accessore.",
+ "apihelp-query+gadgetcategories-example-1": "Pigghie l'elenghe de le categorije de accessore esistende",
+ "apihelp-query+gadgetcategories-example-2": "Pigghie le 'mbormaziune sus a le categorije chiamate \"foo\" e \"bar\"",
+ "apihelp-query+gadgets-description": "Tuèrne 'n'elenghe de accessore ausate sus a sta uicchi.",
+ "apihelp-query+gadgets-summary": "Tuèrne 'n'elenghe de accessore ausate sus a sta uicchi.",
+ "action-gadgets-definition-edit": "cange 'a definizione de l'accessore"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/ru.json b/www/wiki/extensions/Gadgets/i18n/ru.json
index 0e7a4c02..0754d4d4 100644
--- a/www/wiki/extensions/Gadgets/i18n/ru.json
+++ b/www/wiki/extensions/Gadgets/i18n/ru.json
@@ -14,7 +14,8 @@
"Frhdkazan",
"Лилиә",
"Ping08",
- "Mailman"
+ "Mailman",
+ "Jack who built the house"
]
},
"gadgets-desc": "Позволяет участникам выбирать в своих [[Special:Preferences#mw-prefsection-gadgets|настройках]] те или иные [[Special:Gadgets|CSS- и JavaScript-гаджеты]]",
@@ -39,7 +40,7 @@
"gadgets-export": "Экспортировать",
"gadgets-export-title": "Экспорт гаджета",
"gadgets-not-found": "Гаджет «$1» не найден.",
- "gadgets-export-text": "Для экспорта гаджета $1, нажмите кнопку «{{int:gadgets-export-download}}», сохраните загруженный файл,\nперейдите на страницу Special:Import целевой вики и загрузите файл. Затем добавьте следующие строки на страницу MediaWiki:Gadgets-definition:\n<pre>$2</pre>\nВы должны иметь соответствующие разрешения в целевой вики (в том числе право на редактирование системных сообщений), также на сервере должна быть включена настройка импорта из файлов.",
+ "gadgets-export-text": "Для экспорта гаджета $1 нажмите кнопку «{{int:gadgets-export-download}}», сохраните загруженный файл,\nперейдите на страницу Special:Import целевой вики и загрузите файл. Затем добавьте следующие строки на страницу MediaWiki:Gadgets-definition:\n<pre>$2</pre>\nВы должны иметь соответствующие разрешения в целевой вики (в том числе право на редактирование системных сообщений), также на сервере должна быть включена настройка импорта из файлов.",
"gadgets-export-download": "Скачать",
"gadgets-validate-notset": "Свойство <code>$1</code> не установлено.",
"gadgets-validate-wrongtype": "Свойство <code>$1</code> должна иметь тип <code>$2</code> вместо типа <code>$3</code>.",
diff --git a/www/wiki/extensions/Gadgets/i18n/sd.json b/www/wiki/extensions/Gadgets/i18n/sd.json
index d590d8a9..cd5322ef 100644
--- a/www/wiki/extensions/Gadgets/i18n/sd.json
+++ b/www/wiki/extensions/Gadgets/i18n/sd.json
@@ -4,5 +4,5 @@
"Mehtab ahmed"
]
},
- "gadgetusage-usercount": "يوزرس جي تعداد"
+ "gadgetusage-usercount": "واپرائيندڙن جي تعداد"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/sr-ec.json b/www/wiki/extensions/Gadgets/i18n/sr-ec.json
index 41d2fa1e..a70b8242 100644
--- a/www/wiki/extensions/Gadgets/i18n/sr-ec.json
+++ b/www/wiki/extensions/Gadgets/i18n/sr-ec.json
@@ -6,7 +6,9 @@
"Nikola Smolenski",
"Rancher",
"Жељко Тодоровић",
- "Сербијана"
+ "Сербијана",
+ "Acamicamacaraca",
+ "BadDog"
]
},
"gadgets-desc": "Омогућава корисницима да изаберу прилагођене [[Special:Gadgets|CSS и јаваскрипт справице]] у својим [[Special:Preferences#mw-prefsection-gadgets|подешавањима]]",
@@ -27,7 +29,7 @@
"gadgets-required-rights": "Захтева {{PLURAL:$2|следеће право|следећа права}}:\n\n$1",
"gadgets-required-skins": "Доступно у {{PLURAL:$2|теми $1|следећим темама: $1}}.",
"gadgets-default": "Подразумевано укључен за сваког.",
- "gadgets-legacy": "Геџет није учитан. Молимо вас пребаците га на ResourceLoader. ([https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users) Сазнајте више])",
+ "gadgets-legacy": "Справица није учитана. Молимо Вас пребаците га на ResourceLoader. ([https://www.mediawiki.org/wiki/ResourceLoader/Migration_guide_(users) Сазнајте више])",
"gadgets-export": "Извези",
"gadgets-export-title": "Извоз справице",
"gadgets-not-found": "Справица „$1“ није пронађена.",
diff --git a/www/wiki/extensions/Gadgets/i18n/tay.json b/www/wiki/extensions/Gadgets/i18n/tay.json
index 530f2149..879b5989 100644
--- a/www/wiki/extensions/Gadgets/i18n/tay.json
+++ b/www/wiki/extensions/Gadgets/i18n/tay.json
@@ -4,8 +4,11 @@
"Hitaypayan"
]
},
+ "gadgetusage-usercount": "Kinpira’ hi’ na pptzyuwaw",
+ "gadgetusage-activeusers": "Ini’ hngaw mtzyuwaw na pptyuwaw",
"gadgetusage-default": "Pinnama’ smi’",
"gadgets-title": "Qayqaya’ taykuy",
"gadgets-uses": "Pptzyuwaw",
- "gadgets-export": "Pawsa’"
+ "gadgets-export": "Pawsa’",
+ "gadgets-export-title": "Pawsa’ qayqaya’ taykuy"
}
diff --git a/www/wiki/extensions/Gadgets/i18n/ur.json b/www/wiki/extensions/Gadgets/i18n/ur.json
index 8b5a06a4..93449d20 100644
--- a/www/wiki/extensions/Gadgets/i18n/ur.json
+++ b/www/wiki/extensions/Gadgets/i18n/ur.json
@@ -2,18 +2,22 @@
"@metadata": {
"authors": [
"Muhammad Shuaib",
- "පසිඳු කාවින්ද"
+ "පසිඳු කාවින්ද",
+ "BukhariSaeed"
]
},
"prefs-gadgets": "آلات",
+ "gadgets-prefstext": "ذیل میں خصوصی آلات کی فہرست درج ہے جنہیں آپ اپنے کھاتہ کے لیے فعال کرسکتے ہیں۔ چونکہ یہ آلات زیادہ تر جاوا اسکرپٹ پر مبنی ہیں اس لیے آپ کے براؤزر میں جاوا اسکرپٹ فعال ہونا ضروری ہے۔ خیال رہے کہ یہ آلات ترجیحات کے اس صفحہ پر اثر انداز نہیں ہوتے۔\n\nواضح رہے کہ یہ آلات میڈیاویکی سوفٹ ویئر کا حصہ نہیں ہیں، بلکہ ان کے ترقی دہندگان اور منتظمین آپ کے مقامی ویکی کے صارفین ہوتے ہیں۔ مقامی منتظمین صفحۂ [[MediaWiki:Gadgets-definition|تعریفات]] اور صفحۂ [[Special:Gadgets|توضیحات]] کے ذریعہ دستیاب آلات میں ترمیم کر سکتے ہیں۔ کس آلے کو کتنے صارفین استعمال کر رہے ہیں اس کے اعداد و شمار [[Special:GadgetUsage|یہاں]] دستیاب ہیں۔",
"gadgets": "آلات",
"gadgetusage": "آلات کے استعمال کے اعداد و شمار",
"gadgetusage-gadget": "آلہ",
"gadgetusage-usercount": "صارفین کی تعداد",
"gadgetusage-noresults": "کوئی آلہ نہیں مل سکا۔",
+ "gadgetusage-intro": "اس جدول میں ان صارفین کی تعداد درج ہے جنہوں نے اس ویکی پر آلات فعال کر رکھے ہیں۔ متحرک صارف اسے سمجھا جاتا ہے جس نے گزشتہ {{PLURAL:$1|دن|$1 دنوں}} میں کم از کم ایک ترمیم کی ہو۔\nواضح رہے کہ اس فہرست میں وہ آلات شامل نہیں ہیں جو ابتدائی طور پر تمام صارفین کے لیے فعال ہوں نیز اس بات کا بھی امکان ہے کہ فہرست میں ایسے آلات درج ہوں جو اب دستیاب نہیں ہیں۔",
"gadgetusage-activeusers": "فعال صارفین",
"gadgetusage-default": "طے شدہ",
"gadgets-title": "آلات",
+ "gadgets-pagetext": "ذیل میں خصوصی آلات کی فہرست درج ہے جنھیں صارفین اپنی [[Special:Preferences#mw-prefsection-gadgets|ترجیحات]] سے فعال کر سکتے ہیں، ان آلات کا صفحہ تعریفات [[MediaWiki:Gadgets-definition|یہاں]] موجود ہے۔ اس صفحہ کے ذریعہ ان آلات کے نظامی پیغام اور ان کی اسکرپٹ تک بآسانی رسائی حاصل کی جا سکتی ہے۔",
"gadgets-uses": "استعمال کرتا ہے",
"gadgets-required-rights": "حسب ذیل {{PLURAL:$2|اختیار|اختیارات}} درکار {{PLURAL:$2|ہے|ہیں}}:\n\n$1",
"gadgets-default": "ابتدائی طور پر ہر ایک کے لیے فعال ہے۔",
diff --git a/www/wiki/extensions/Gadgets/i18n/zh-hant.json b/www/wiki/extensions/Gadgets/i18n/zh-hant.json
index 9a059b61..c6336455 100644
--- a/www/wiki/extensions/Gadgets/i18n/zh-hant.json
+++ b/www/wiki/extensions/Gadgets/i18n/zh-hant.json
@@ -14,7 +14,9 @@
"LNDDYL",
"Liuxinyu970226",
"Bowleerin",
- "PhiLiP"
+ "PhiLiP",
+ "Translatealcd",
+ "Kly"
]
},
"gadgets-desc": "讓使用者可以於 [[Special:Preferences#mw-prefsection-gadgets|偏好設定]] 中自訂 [[Special:Gadgets|CSS 與 JavaScript 的小工具]]",
@@ -46,7 +48,7 @@
"apihelp-query+gadgetcategories-example-1": "取得已存在的小工具分類清單",
"apihelp-query+gadgetcategories-example-2": "取得所有有關分類名稱為 \"foo\" 與 \"bar\" 的資訊",
"apihelp-query+gadgets-description": "回傳在此 wiki 使用過的小工具清單。",
- "apihelp-query+gadgets-param-prop": "要取得什麼小工具資訊:\n;id:內部小工具 ID。\n;metadata:小工具 metadata。\n;desc:小工具描述轉換至 HTML 格式 (可能較慢,只在需要時使用)。",
+ "apihelp-query+gadgets-param-prop": "要取得什麼小工具資訊:\n;id:內部小工具 ID。\n;metadata:小工具詮釋資料。\n;desc:小工具描述轉換至 HTML 格式 (可能較慢,只在需要時使用)。",
"apihelp-query+gadgets-param-categories": "自那個分類取得小工具。",
"apihelp-query+gadgets-param-ids": "要取得小工具的 ID。",
"apihelp-query+gadgets-param-allowedonly": "只列出目前使用者可使用的小工具。",
@@ -55,7 +57,7 @@
"apihelp-query+gadgets-example-2": "取得小工具及其所有屬性清單",
"apihelp-query+gadgets-example-3": "取得屬於分類 \"foo\" 的小工具清單",
"apihelp-query+gadgets-example-4": "取得有關小工具 \"foo\" 與 \"bar\" 的資訊",
- "apihelp-query+gadgets-example-5": "取得由目前使用者開竹呚的小工具清單",
+ "apihelp-query+gadgets-example-5": "取得由目前使用者開啟的小工具清單",
"right-gadgets-edit": "編輯小工具的 JavaScript 與 CSS 頁面",
"action-gadgets-edit": "編輯這個小工具的 JavaScript 或 CSS 頁面",
"right-gadgets-definition-edit": "編輯小工具定義",
diff --git a/www/wiki/extensions/Gadgets/includes/Gadget.php b/www/wiki/extensions/Gadgets/includes/Gadget.php
new file mode 100644
index 00000000..245458a9
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/includes/Gadget.php
@@ -0,0 +1,315 @@
+<?php
+/**
+ * Gadgets extension - lets users select custom javascript gadgets
+ *
+ * For more info see https://www.mediawiki.org/wiki/Extension:Gadgets
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Daniel Kinzler, brightbyte.de
+ * @copyright © 2007 Daniel Kinzler
+ * @license GPL-2.0-or-later
+ */
+
+/**
+ * Wrapper for one gadget.
+ */
+class Gadget {
+ /**
+ * Increment this when changing class structure
+ */
+ const GADGET_CLASS_VERSION = 9;
+
+ const CACHE_TTL = 86400;
+
+ private $scripts = [],
+ $styles = [],
+ $dependencies = [],
+ $peers = [],
+ $messages = [],
+ $name,
+ $definition,
+ $resourceLoaded = false,
+ $requiredRights = [],
+ $requiredSkins = [],
+ $targets = [ 'desktop' ],
+ $onByDefault = false,
+ $hidden = false,
+ $type = '',
+ $category;
+
+ public function __construct( array $options ) {
+ foreach ( $options as $member => $option ) {
+ switch ( $member ) {
+ case 'scripts':
+ case 'styles':
+ case 'dependencies':
+ case 'peers':
+ case 'messages':
+ case 'name':
+ case 'definition':
+ case 'resourceLoaded':
+ case 'requiredRights':
+ case 'requiredSkins':
+ case 'targets':
+ case 'onByDefault':
+ case 'type':
+ case 'hidden':
+ case 'category':
+ $this->{$member} = $option;
+ break;
+ default:
+ throw new InvalidArgumentException( "Unrecognized '$member' parameter" );
+ }
+ }
+ }
+
+ /**
+ * Create a object based on the metadata in a GadgetDefinitionContent object
+ *
+ * @param string $id
+ * @param GadgetDefinitionContent $content
+ * @return Gadget
+ */
+ public static function newFromDefinitionContent( $id, GadgetDefinitionContent $content ) {
+ $data = $content->getAssocArray();
+ $prefixGadgetNs = function ( $page ) {
+ return 'Gadget:' . $page;
+ };
+ $info = [
+ 'name' => $id,
+ 'resourceLoaded' => true,
+ 'requiredRights' => $data['settings']['rights'],
+ 'onByDefault' => $data['settings']['default'],
+ 'hidden' => $data['settings']['hidden'],
+ 'requiredSkins' => $data['settings']['skins'],
+ 'category' => $data['settings']['category'],
+ 'scripts' => array_map( $prefixGadgetNs, $data['module']['scripts'] ),
+ 'styles' => array_map( $prefixGadgetNs, $data['module']['styles'] ),
+ 'dependencies' => $data['module']['dependencies'],
+ 'peers' => $data['module']['peers'],
+ 'messages' => $data['module']['messages'],
+ 'type' => $data['module']['type'],
+ ];
+
+ return new self( $info );
+ }
+
+ /**
+ * Get a placeholder object to use if a gadget doesn't exist
+ *
+ * @param string $id name
+ * @return Gadget
+ */
+ public static function newEmptyGadget( $id ) {
+ return new self( [ 'name' => $id ] );
+ }
+
+ /**
+ * Whether the provided gadget id is valid
+ *
+ * @param string $id
+ * @return bool
+ */
+ public static function isValidGadgetID( $id ) {
+ return strlen( $id ) > 0 && ResourceLoader::isValidModuleName( self::getModuleName( $id ) );
+ }
+
+ /**
+ * @return string Gadget name
+ */
+ public function getName() {
+ return $this->name;
+ }
+
+ /**
+ * @return string Gadget description parsed into HTML
+ */
+ public function getDescription() {
+ return wfMessage( "gadget-{$this->getName()}" )->parse();
+ }
+
+ /**
+ * @return string Wikitext of gadget description
+ */
+ public function getRawDescription() {
+ return wfMessage( "gadget-{$this->getName()}" )->plain();
+ }
+
+ /**
+ * @return string Name of category (aka section) our gadget belongs to. Empty string if none.
+ */
+ public function getCategory() {
+ return $this->category;
+ }
+
+ /**
+ * @param string $id Name of gadget
+ * @return string Name of ResourceLoader module for the gadget
+ */
+ public static function getModuleName( $id ) {
+ return "ext.gadget.{$id}";
+ }
+
+ /**
+ * Checks whether this gadget is enabled for given user
+ *
+ * @param User $user user to check against
+ * @return bool
+ */
+ public function isEnabled( $user ) {
+ return (bool)$user->getOption( "gadget-{$this->name}", $this->onByDefault );
+ }
+
+ /**
+ * Checks whether given user has permissions to use this gadget
+ *
+ * @param User $user user to check against
+ * @return bool
+ */
+ public function isAllowed( $user ) {
+ return count( array_intersect( $this->requiredRights, $user->getRights() ) ) ==
+ count( $this->requiredRights )
+ && ( $this->requiredSkins === true
+ || !count( $this->requiredSkins )
+ || in_array( $user->getOption( 'skin' ), $this->requiredSkins )
+ );
+ }
+
+ /**
+ * @return bool Whether this gadget is on by default for everyone
+ * (but can be disabled in preferences)
+ */
+ public function isOnByDefault() {
+ return $this->onByDefault;
+ }
+
+ /**
+ * @return bool
+ */
+ public function isHidden() {
+ return $this->hidden;
+ }
+
+ /**
+ * @return bool Whether all of this gadget's JS components support ResourceLoader
+ */
+ public function supportsResourceLoader() {
+ return $this->resourceLoaded;
+ }
+
+ /**
+ * @return bool Whether this gadget has resources that can be loaded via ResourceLoaderb
+ */
+ public function hasModule() {
+ return count( $this->styles )
+ + ( $this->supportsResourceLoader() ? count( $this->scripts ) : 0 )
+ > 0;
+ }
+
+ /**
+ * @return string Definition for this gadget from MediaWiki:gadgets-definition
+ */
+ public function getDefinition() {
+ return $this->definition;
+ }
+
+ /**
+ * @return array Array of pages with JS (including namespace)
+ */
+ public function getScripts() {
+ return $this->scripts;
+ }
+
+ /**
+ * @return array Array of pages with CSS (including namespace)
+ */
+ public function getStyles() {
+ return $this->styles;
+ }
+
+ /**
+ * @return array Array of all of this gadget's resources
+ */
+ public function getScriptsAndStyles() {
+ return array_merge( $this->scripts, $this->styles );
+ }
+
+ /**
+ * @return array
+ */
+ public function getTargets() {
+ return $this->targets;
+ }
+
+ /**
+ * Returns list of scripts that don't support ResourceLoader
+ * @return Array
+ */
+ public function getLegacyScripts() {
+ if ( $this->supportsResourceLoader() ) {
+ return [];
+ }
+ return $this->scripts;
+ }
+
+ /**
+ * Returns names of resources this gadget depends on
+ * @return Array
+ */
+ public function getDependencies() {
+ return $this->dependencies;
+ }
+
+ /**
+ * Get list of extra modules that should be loaded when this gadget is enabled
+ *
+ * Primary use case is to allow a Gadget that includes JavaScript to also load
+ * a (usually, hidden) styles-type module to be applied to the page. Dependencies
+ * don't work for this use case as those would not be part of page rendering.
+ *
+ * @return Array
+ */
+ public function getPeers() {
+ return $this->peers;
+ }
+
+ /**
+ * @return array
+ */
+ public function getMessages() {
+ return $this->messages;
+ }
+
+ /**
+ * Returns array of permissions required by this gadget
+ * @return Array
+ */
+ public function getRequiredRights() {
+ return $this->requiredRights;
+ }
+
+ /**
+ * Returns array of skins where this gadget works
+ * @return Array
+ */
+ public function getRequiredSkins() {
+ return $this->requiredSkins;
+ }
+
+ /**
+ * Returns the load type of this Gadget's ResourceLoader module
+ * @return string 'styles' or 'general'
+ */
+ public function getType() {
+ if ( $this->type === 'styles' || $this->type === 'general' ) {
+ return $this->type;
+ }
+ // Similar to ResourceLoaderWikiModule default
+ if ( $this->styles && !$this->scripts && !$this->dependencies ) {
+ return 'styles';
+ } else {
+ return 'general';
+ }
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/includes/GadgetDefinitionNamespaceRepo.php b/www/wiki/extensions/Gadgets/includes/GadgetDefinitionNamespaceRepo.php
index 297a58fd..fdecee80 100644
--- a/www/wiki/extensions/Gadgets/includes/GadgetDefinitionNamespaceRepo.php
+++ b/www/wiki/extensions/Gadgets/includes/GadgetDefinitionNamespaceRepo.php
@@ -1,6 +1,8 @@
<?php
+use MediaWiki\Linker\LinkTarget;
use MediaWiki\MediaWikiServices;
+use Wikimedia\Rdbms\Database;
/**
* GadgetRepo implementation where each gadget has a page in
@@ -35,7 +37,7 @@ class GadgetDefinitionNamespaceRepo extends GadgetRepo {
$key,
self::CACHE_TTL,
function ( $oldValue, &$ttl, array &$setOpts ) {
- $dbr = wfGetDB( DB_SLAVE );
+ $dbr = wfGetDB( DB_REPLICA );
$setOpts += Database::getCacheSetOptions( $dbr );
return $dbr->selectFieldValues(
@@ -54,6 +56,34 @@ class GadgetDefinitionNamespaceRepo extends GadgetRepo {
}
/**
+ * @inheritDoc
+ */
+ public function handlePageUpdate( LinkTarget $target ) {
+ if ( $target->inNamespace( NS_GADGET_DEFINITION ) ) {
+ $this->purgeGadgetEntry( $target->getText() );
+ }
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function handlePageCreation( LinkTarget $target ) {
+ if ( $target->inNamespace( NS_GADGET_DEFINITION ) ) {
+ $this->purgeGadgetIdsList();
+ }
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function handlePageDeletion( LinkTarget $target ) {
+ if ( $target->inNamespace( NS_GADGET_DEFINITION ) ) {
+ $this->purgeGadgetIdsList();
+ $this->purgeGadgetEntry( $target->getText() );
+ }
+ }
+
+ /**
* Purge the list of gadget ids when a page is deleted or if a new page is created
*/
public function purgeGadgetIdsList() {
@@ -70,8 +100,11 @@ class GadgetDefinitionNamespaceRepo extends GadgetRepo {
$gadget = $this->wanCache->getWithSetCallback(
$key,
self::CACHE_TTL,
+ /**
+ * @suppress PhanTypeMismatchArgument
+ */
function ( $old, &$ttl, array &$setOpts ) use ( $id ) {
- $setOpts += Database::getCacheSetOptions( wfGetDB( DB_SLAVE ) );
+ $setOpts += Database::getCacheSetOptions( wfGetDB( DB_REPLICA ) );
$title = Title::makeTitleSafe( NS_GADGET_DEFINITION, $id );
if ( !$title ) {
$ttl = WANObjectCache::TTL_UNCACHEABLE;
@@ -124,7 +157,7 @@ class GadgetDefinitionNamespaceRepo extends GadgetRepo {
}
/**
- * @param strng $id
+ * @param string $id
* @return string
*/
private function getGadgetCacheKey( $id ) {
diff --git a/www/wiki/extensions/Gadgets/includes/GadgetHooks.php b/www/wiki/extensions/Gadgets/includes/GadgetHooks.php
new file mode 100644
index 00000000..e493baf7
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/includes/GadgetHooks.php
@@ -0,0 +1,342 @@
+<?php
+
+/**
+ * Copyright © 2007 Daniel Kinzler
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+use Wikimedia\Rdbms\IDatabase;
+use Wikimedia\WrappedString;
+
+class GadgetHooks {
+ /**
+ * PageContentSaveComplete hook handler.
+ *
+ * @param WikiPage $wikiPage
+ * @param User $user
+ * @param Content $content New page content
+ * @return bool
+ */
+ public static function onPageContentSaveComplete( WikiPage $wikiPage, $user, $content ) {
+ // update cache if MediaWiki:Gadgets-definition was edited
+ GadgetRepo::singleton()->handlePageUpdate( $wikiPage->getTitle() );
+ return true;
+ }
+
+ /**
+ * UserGetDefaultOptions hook handler
+ * @param array &$defaultOptions Array of default preference keys and values
+ * @return bool
+ */
+ public static function userGetDefaultOptions( &$defaultOptions ) {
+ $gadgets = GadgetRepo::singleton()->getStructuredList();
+ if ( !$gadgets ) {
+ return true;
+ }
+
+ /**
+ * @var $gadget Gadget
+ */
+ foreach ( $gadgets as $thisSection ) {
+ foreach ( $thisSection as $gadgetId => $gadget ) {
+ if ( $gadget->isOnByDefault() ) {
+ $defaultOptions['gadget-' . $gadgetId] = 1;
+ }
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * GetPreferences hook handler.
+ * @param User $user
+ * @param array &$preferences Preference descriptions
+ * @return bool
+ */
+ public static function getPreferences( $user, &$preferences ) {
+ $gadgets = GadgetRepo::singleton()->getStructuredList();
+ if ( !$gadgets ) {
+ return true;
+ }
+
+ $options = [];
+ $default = [];
+ foreach ( $gadgets as $section => $thisSection ) {
+ $available = [];
+
+ /**
+ * @var $gadget Gadget
+ */
+ foreach ( $thisSection as $gadget ) {
+ if ( !$gadget->isHidden() && $gadget->isAllowed( $user ) ) {
+ $gname = $gadget->getName();
+ # bug 30182: dir="auto" because it's often not translated
+ $desc = '<span dir="auto">' . $gadget->getDescription() . '</span>';
+ $available[$desc] = $gname;
+ if ( $gadget->isEnabled( $user ) ) {
+ $default[] = $gname;
+ }
+ }
+ }
+
+ if ( $section !== '' ) {
+ $section = wfMessage( "gadget-section-$section" )->parse();
+
+ if ( count( $available ) ) {
+ $options[$section] = $available;
+ }
+ } else {
+ $options = array_merge( $options, $available );
+ }
+ }
+
+ $preferences['gadgets-intro'] =
+ [
+ 'type' => 'info',
+ 'label' => '&#160;',
+ 'default' => Xml::tags( 'tr', [],
+ Xml::tags( 'td', [ 'colspan' => 2 ],
+ wfMessage( 'gadgets-prefstext' )->parseAsBlock() ) ),
+ 'section' => 'gadgets',
+ 'raw' => 1,
+ 'rawrow' => 1,
+ 'noglobal' => true,
+ ];
+
+ $preferences['gadgets'] =
+ [
+ 'type' => 'multiselect',
+ 'options' => $options,
+ 'section' => 'gadgets',
+ 'label' => '&#160;',
+ 'prefix' => 'gadget-',
+ 'default' => $default,
+ 'noglobal' => true,
+ ];
+
+ return true;
+ }
+
+ /**
+ * ResourceLoaderRegisterModules hook handler.
+ * @param ResourceLoader &$resourceLoader
+ * @return bool
+ */
+ public static function registerModules( &$resourceLoader ) {
+ $repo = GadgetRepo::singleton();
+ $ids = $repo->getGadgetIds();
+
+ foreach ( $ids as $id ) {
+ $resourceLoader->register( Gadget::getModuleName( $id ), [
+ 'class' => 'GadgetResourceLoaderModule',
+ 'id' => $id,
+ ] );
+ }
+
+ return true;
+ }
+
+ /**
+ * BeforePageDisplay hook handler.
+ * @param OutputPage $out
+ * @return bool
+ */
+ public static function beforePageDisplay( $out ) {
+ $repo = GadgetRepo::singleton();
+ $ids = $repo->getGadgetIds();
+ if ( !$ids ) {
+ return true;
+ }
+
+ $lb = new LinkBatch();
+ $lb->setCaller( __METHOD__ );
+ $enabledLegacyGadgets = [];
+
+ /**
+ * @var $gadget Gadget
+ */
+ $user = $out->getUser();
+ foreach ( $ids as $id ) {
+ try {
+ $gadget = $repo->getGadget( $id );
+ } catch ( InvalidArgumentException $e ) {
+ continue;
+ }
+ $peers = [];
+ foreach ( $gadget->getPeers() as $peerName ) {
+ try {
+ $peers[] = $repo->getGadget( $peerName );
+ } catch ( InvalidArgumentException $e ) {
+ // Ignore
+ // @todo: Emit warning for invalid peer?
+ }
+ }
+ if ( $gadget->isEnabled( $user ) && $gadget->isAllowed( $user ) ) {
+ if ( $gadget->hasModule() ) {
+ if ( $gadget->getType() === 'styles' ) {
+ $out->addModuleStyles( Gadget::getModuleName( $gadget->getName() ) );
+ } else {
+ $out->addModules( Gadget::getModuleName( $gadget->getName() ) );
+ // Load peer modules
+ foreach ( $peers as $peer ) {
+ if ( $peer->getType() === 'styles' ) {
+ $out->addModuleStyles( Gadget::getModuleName( $peer->getName() ) );
+ }
+ // Else, if not type=styles: Use dependencies instead.
+ // Note: No need for recursion as styles modules don't support
+ // either of 'dependencies' and 'peers'.
+ }
+ }
+ }
+
+ if ( $gadget->getLegacyScripts() ) {
+ $enabledLegacyGadgets[] = $id;
+ }
+ }
+ }
+
+ $strings = [];
+ foreach ( $enabledLegacyGadgets as $id ) {
+ $strings[] = self::makeLegacyWarning( $id );
+ }
+ $out->addHTML( WrappedString::join( "\n", $strings ) );
+
+ return true;
+ }
+
+ private static function makeLegacyWarning( $id ) {
+ $special = SpecialPage::getTitleFor( 'Gadgets' );
+
+ return ResourceLoader::makeInlineScript(
+ Xml::encodeJsCall( 'mw.log.warn', [
+ "Gadget \"$id\" was not loaded. Please migrate it to use ResourceLoader. " .
+ 'See <' . $special->getCanonicalURL() . '>.'
+ ] )
+ );
+ }
+
+ /**
+ * Valid gadget definition page after content is modified
+ *
+ * @param IContextSource $context
+ * @param Content $content
+ * @param Status $status
+ * @param string $summary
+ * @throws Exception
+ * @return bool
+ * @suppress PhanUndeclaredMethod
+ */
+ public static function onEditFilterMergedContent( $context, $content, $status, $summary ) {
+ $title = $context->getTitle();
+
+ if ( !$title->inNamespace( NS_GADGET_DEFINITION ) ) {
+ return true;
+ }
+
+ if ( !$content instanceof GadgetDefinitionContent ) {
+ // This should not be possible?
+ throw new Exception(
+ "Tried to save non-GadgetDefinitionContent to {$title->getPrefixedText()}"
+ );
+ }
+
+ $status = $content->validate();
+ if ( !$status->isGood() ) {
+ $status->merge( $status );
+ return false;
+ }
+
+ return true;
+ }
+
+ /**
+ * After a new page is created in the Gadget definition namespace,
+ * invalidate the list of gadget ids
+ *
+ * @param WikiPage $page
+ */
+ public static function onPageContentInsertComplete( WikiPage $page ) {
+ if ( $page->getTitle()->inNamespace( NS_GADGET_DEFINITION ) ) {
+ GadgetRepo::singleton()->handlePageCreation( $page->getTitle() );
+ }
+ }
+
+ /**
+ * Mark the Title as having a content model of javascript or css for pages
+ * in the Gadget namespace based on their file extension
+ *
+ * @param Title $title
+ * @param string &$model
+ * @return bool
+ */
+ public static function onContentHandlerDefaultModelFor( Title $title, &$model ) {
+ if ( $title->inNamespace( NS_GADGET ) ) {
+ preg_match( '!\.(css|js)$!u', $title->getText(), $ext );
+ $ext = isset( $ext[1] ) ? $ext[1] : '';
+ switch ( $ext ) {
+ case 'js':
+ $model = 'javascript';
+ return false;
+ case 'css':
+ $model = 'css';
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Set the CodeEditor language for Gadget definition pages. It already
+ * knows the language for Gadget: namespace pages.
+ *
+ * @param Title $title
+ * @param string &$lang
+ * @return bool
+ */
+ public static function onCodeEditorGetPageLanguage( Title $title, &$lang ) {
+ if ( $title->hasContentModel( 'GadgetDefinition' ) ) {
+ $lang = 'json';
+ return false;
+ }
+
+ return true;
+ }
+
+ /**
+ * Add the GadgetUsage special page to the list of QueryPages.
+ * @param array &$queryPages
+ * @return bool
+ */
+ public static function onwgQueryPages( &$queryPages ) {
+ $queryPages[] = [ 'SpecialGadgetUsage', 'GadgetUsage' ];
+ return true;
+ }
+
+ /**
+ * Prevent gadget preferences from being deleted.
+ * @link https://www.mediawiki.org/wiki/Manual:Hooks/DeleteUnknownPreferences
+ * @suppress PhanParamTooMany
+ * @param string[] &$where Array of where clause conditions to add to.
+ * @param IDatabase $db
+ */
+ public static function onDeleteUnknownPreferences( &$where, IDatabase $db ) {
+ $where[] = 'up_property NOT' . $db->buildLike( 'gadget-', $db->anyString() );
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/includes/GadgetRepo.php b/www/wiki/extensions/Gadgets/includes/GadgetRepo.php
index 76e9deca..11996f8e 100644
--- a/www/wiki/extensions/Gadgets/includes/GadgetRepo.php
+++ b/www/wiki/extensions/Gadgets/includes/GadgetRepo.php
@@ -1,5 +1,7 @@
<?php
+use MediaWiki\Linker\LinkTarget;
+
abstract class GadgetRepo {
/**
@@ -27,6 +29,39 @@ abstract class GadgetRepo {
abstract public function getGadget( $id );
/**
+ * Given that the provided page was updated, invalidate
+ * caches if necessary
+ *
+ * @param LinkTarget $target
+ *
+ * @return void
+ */
+ public function handlePageUpdate( LinkTarget $target ) {
+ }
+
+ /**
+ * Given that the provided page was created, invalidate
+ * caches if necessary
+ *
+ * @param LinkTarget $target
+ *
+ * @return void
+ */
+ public function handlePageCreation( LinkTarget $target ) {
+ }
+
+ /**
+ * Given that the provided page was updated, invalidate
+ * caches if necessary
+ *
+ * @param LinkTarget $target
+ *
+ * @return void
+ */
+ public function handlePageDeletion( LinkTarget $target ) {
+ }
+
+ /**
* Get a list of gadgets sorted by category
*
* @return array [ 'category' => [ 'name' => $gadget ] ]
diff --git a/www/wiki/extensions/Gadgets/includes/GadgetResourceLoaderModule.php b/www/wiki/extensions/Gadgets/includes/GadgetResourceLoaderModule.php
index e1b26022..13d16cdd 100644
--- a/www/wiki/extensions/Gadgets/includes/GadgetResourceLoaderModule.php
+++ b/www/wiki/extensions/Gadgets/includes/GadgetResourceLoaderModule.php
@@ -16,8 +16,6 @@ class GadgetResourceLoaderModule extends ResourceLoaderWikiModule {
private $gadget;
/**
- * Creates an instance of this class
- *
* @param array $options
*/
public function __construct( array $options ) {
diff --git a/www/wiki/extensions/Gadgets/includes/MediaWikiGadgetsDefinitionRepo.php b/www/wiki/extensions/Gadgets/includes/MediaWikiGadgetsDefinitionRepo.php
index 60fb61dc..84c84b6c 100644
--- a/www/wiki/extensions/Gadgets/includes/MediaWikiGadgetsDefinitionRepo.php
+++ b/www/wiki/extensions/Gadgets/includes/MediaWikiGadgetsDefinitionRepo.php
@@ -1,4 +1,6 @@
<?php
+
+use MediaWiki\Linker\LinkTarget;
use MediaWiki\MediaWikiServices;
use Wikimedia\Rdbms\Database;
@@ -10,6 +12,12 @@ class MediaWikiGadgetsDefinitionRepo extends GadgetRepo {
private $definitionCache;
+ /**
+ * @param string $id
+ *
+ * @return Gadget
+ * @throws InvalidArgumentException
+ */
public function getGadget( $id ) {
$gadgets = $this->loadGadgets();
if ( !isset( $gadgets[$id] ) ) {
@@ -28,11 +36,17 @@ class MediaWikiGadgetsDefinitionRepo extends GadgetRepo {
}
}
+ public function handlePageUpdate( LinkTarget $target ) {
+ if ( $target->getNamespace() == NS_MEDIAWIKI && $target->getText() == 'Gadgets-definition' ) {
+ $this->purgeDefinitionCache();
+ }
+ }
+
/**
* Purge the definitions cache, for example if MediaWiki:Gadgets-definition
* was edited.
*/
- public function purgeDefinitionCache() {
+ private function purgeDefinitionCache() {
$cache = MediaWikiServices::getInstance()->getMainWANObjectCache();
$cache->touchCheckKey( $this->getCheckKey() );
}
diff --git a/www/wiki/extensions/Gadgets/includes/SpecialGadgetUsage.php b/www/wiki/extensions/Gadgets/includes/SpecialGadgetUsage.php
new file mode 100644
index 00000000..0601d654
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/includes/SpecialGadgetUsage.php
@@ -0,0 +1,252 @@
+<?php
+/**
+ * Implements Special:GadgetUsage
+ *
+ * Copyright © 2015 Niharika Kohli
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @ingroup SpecialPage
+ * @author Niharika Kohli <niharika@wikimedia.org>
+ */
+
+use Wikimedia\Rdbms\IDatabase;
+use Wikimedia\Rdbms\IResultWrapper;
+
+/**
+ * Special:GadgetUsage - Lists all the gadgets on the wiki along with number of users.
+ * @ingroup SpecialPage
+ */
+class SpecialGadgetUsage extends QueryPage {
+ function __construct( $name = 'GadgetUsage' ) {
+ parent::__construct( $name );
+ $this->limit = 1000; // Show all gadgets
+ $this->shownavigation = false;
+ $this->activeUsers = $this->getConfig()->get( 'SpecialGadgetUsageActiveUsers' );
+ }
+
+ /**
+ * Flag for holding the value of config variable SpecialGadgetUsageActiveUsers
+ *
+ * @var bool $activeUsers
+ */
+ public $activeUsers;
+
+ public function isExpensive() {
+ return true;
+ }
+
+ /**
+ * Define the database query that is used to generate the stats table.
+ * This uses 1 of 2 possible queries, depending on $wgSpecialGadgetUsageActiveUsers.
+ *
+ * The simple query is essentially:
+ * SELECT up_property, SUM(up_value)
+ * FROM user_properties
+ * WHERE up_property LIKE 'gadget-%'
+ * GROUP BY up_property;
+ *
+ * The more expensive query is:
+ * SELECT up_property, SUM(up_value), count(qcc_title)
+ * FROM user_properties
+ * LEFT JOIN user ON up_user = user_id
+ * LEFT JOIN querycachetwo ON user_name = qcc_title AND qcc_type = 'activeusers' AND up_value = 1
+ * WHERE up_property LIKE 'gadget-%'
+ * GROUP BY up_property;
+ * @return array
+ */
+ public function getQueryInfo() {
+ $dbr = wfGetDB( DB_REPLICA );
+ if ( !$this->activeUsers ) {
+ return [
+ 'tables' => [ 'user_properties' ],
+ 'fields' => [
+ 'title' => 'up_property',
+ 'value' => 'SUM( up_value )',
+ 'namespace' => NS_GADGET
+ ],
+ 'conds' => [
+ 'up_property' . $dbr->buildLike( 'gadget-', $dbr->anyString() )
+ ],
+ 'options' => [
+ 'GROUP BY' => [ 'up_property' ]
+ ]
+ ];
+ } else {
+ return [
+ 'tables' => [ 'user_properties', 'user', 'querycachetwo' ],
+ 'fields' => [
+ 'title' => 'up_property',
+ 'value' => 'SUM( up_value )',
+ // Need to pick fields existing in the querycache table so that the results are cachable
+ 'namespace' => 'COUNT( qcc_title )'
+ ],
+ 'conds' => [
+ 'up_property' . $dbr->buildLike( 'gadget-', $dbr->anyString() )
+ ],
+ 'options' => [
+ 'GROUP BY' => [ 'up_property' ]
+ ],
+ 'join_conds' => [
+ 'user' => [
+ 'LEFT JOIN', [
+ 'up_user = user_id'
+ ]
+ ],
+ 'querycachetwo' => [
+ 'LEFT JOIN', [
+ 'user_name = qcc_title',
+ 'qcc_type = "activeusers"',
+ 'up_value = 1'
+ ]
+ ]
+ ]
+ ];
+ }
+ }
+
+ public function getOrderFields() {
+ return [ 'value' ];
+ }
+
+ /**
+ * Output the start of the table
+ * Including opening <table>, and first <tr> with column headers.
+ */
+ protected function outputTableStart() {
+ $html = Html::openElement( 'table', [ 'class' => [ 'sortable', 'wikitable' ] ] );
+ $html .= Html::openElement( 'tr', [] );
+ $headers = [ 'gadgetusage-gadget', 'gadgetusage-usercount' ];
+ if ( $this->activeUsers ) {
+ $headers[] = 'gadgetusage-activeusers';
+ }
+ foreach ( $headers as $h ) {
+ if ( $h == 'gadgetusage-gadget' ) {
+ $html .= Html::element( 'th', [], $this->msg( $h )->text() );
+ } else {
+ $html .= Html::element( 'th', [ 'data-sort-type' => 'number' ],
+ $this->msg( $h )->text() );
+ }
+ }
+ $html .= Html::closeElement( 'tr' );
+ $this->getOutput()->addHTML( $html );
+ }
+
+ /**
+ * @param Skin $skin
+ * @param object $result Result row
+ * @return string|bool String of HTML
+ */
+ public function formatResult( $skin, $result ) {
+ $gadgetTitle = substr( $result->title, 7 );
+ $gadgetUserCount = $this->getLanguage()->formatNum( $result->value );
+ if ( $gadgetTitle ) {
+ $html = Html::openElement( 'tr', [] );
+ $html .= Html::element( 'td', [], $gadgetTitle );
+ $html .= Html::element( 'td', [], $gadgetUserCount );
+ if ( $this->activeUsers == true ) {
+ $activeUserCount = $this->getLanguage()->formatNum( $result->namespace );
+ $html .= Html::element( 'td', [], $activeUserCount );
+ }
+ $html .= Html::closeElement( 'tr' );
+ return $html;
+ }
+ return false;
+ }
+
+ /**
+ * Get a list of default gadgets
+ * @param GadgetRepo $gadgetRepo
+ * @param array $gadgetIds list of gagdet ids registered in the wiki
+ * @return array
+ */
+ protected function getDefaultGadgets( $gadgetRepo, $gadgetIds ) {
+ $gadgetsList = [];
+ foreach ( $gadgetIds as $g ) {
+ $gadget = $gadgetRepo->getGadget( $g );
+ if ( $gadget->isOnByDefault() ) {
+ $gadgetsList[] = $gadget->getName();
+ }
+ }
+ asort( $gadgetsList, SORT_STRING | SORT_FLAG_CASE );
+ return $gadgetsList;
+ }
+
+ /**
+ * Format and output report results using the given information plus
+ * OutputPage
+ *
+ * @param OutputPage $out OutputPage to print to
+ * @param Skin $skin User skin to use
+ * @param IDatabase $dbr Database (read) connection to use
+ * @param IResultWrapper $res Result pointer
+ * @param int $num Number of available result rows
+ * @param int $offset Paging offset
+ */
+ protected function outputResults( $out, $skin, $dbr, $res, $num, $offset ) {
+ $gadgetRepo = GadgetRepo::singleton();
+ $gadgetIds = $gadgetRepo->getGadgetIds();
+ $defaultGadgets = $this->getDefaultGadgets( $gadgetRepo, $gadgetIds );
+ if ( $this->activeUsers ) {
+ $out->addHtml(
+ $this->msg( 'gadgetusage-intro' )
+ ->numParams( $this->getConfig()->get( 'ActiveUserDays' ) )->parseAsBlock()
+ );
+ } else {
+ $out->addHtml(
+ $this->msg( 'gadgetusage-intro-noactive' )->parseAsBlock()
+ );
+ }
+ if ( $num > 0 ) {
+ $this->outputTableStart();
+ // Append default gadgets to the table with 'default' in the total and active user fields
+ foreach ( $defaultGadgets as $default ) {
+ $html = Html::openElement( 'tr', [] );
+ $html .= Html::element( 'td', [], $default );
+ $html .= Html::element( 'td', [], $this->msg( 'gadgetusage-default' )->text() );
+ if ( $this->activeUsers ) {
+ $html .= Html::element( 'td', [], $this->msg( 'gadgetusage-default' )->text() );
+ }
+ $html .= Html::closeElement( 'tr' );
+ $out->addHTML( $html );
+ }
+ foreach ( $res as $row ) {
+ // Remove the 'gadget-' part of the result string and compare if it's present
+ // in $defaultGadgets, if not we format it and add it to the output
+ if ( !in_array( substr( $row->title, 7 ), $defaultGadgets ) ) {
+ // Only pick gadgets which are in the list $gadgetIds to make sure they exist
+ if ( in_array( substr( $row->title, 7 ), $gadgetIds ) ) {
+ $line = $this->formatResult( $skin, $row );
+ if ( $line ) {
+ $out->addHTML( $line );
+ }
+ }
+ }
+ }
+ // Close table element
+ $out->addHtml( Html::closeElement( 'table' ) );
+ } else {
+ $out->addHtml(
+ $this->msg( 'gadgetusage-noresults' )->parseAsBlock()
+ );
+ }
+ }
+
+ protected function getGroupName() {
+ return 'wiki';
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/includes/SpecialGadgets.php b/www/wiki/extensions/Gadgets/includes/SpecialGadgets.php
new file mode 100644
index 00000000..1d374cbf
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/includes/SpecialGadgets.php
@@ -0,0 +1,232 @@
+<?php
+/**
+ * Special:Gadgets, provides a preview of MediaWiki:Gadgets.
+ *
+ * @file
+ * @ingroup SpecialPage
+ * @author Daniel Kinzler, brightbyte.de
+ * @copyright © 2007 Daniel Kinzler
+ * @license GPL-2.0-or-later
+ */
+
+class SpecialGadgets extends SpecialPage {
+ public function __construct() {
+ parent::__construct( 'Gadgets', '', true );
+ }
+
+ /**
+ * Main execution function
+ * @param string $par Parameters passed to the page
+ */
+ public function execute( $par ) {
+ $parts = explode( '/', $par );
+
+ if ( count( $parts ) == 2 && $parts[0] == 'export' ) {
+ $this->showExportForm( $parts[1] );
+ } else {
+ $this->showMainForm();
+ }
+ }
+
+ private function makeAnchor( $gadgetName ) {
+ return 'gadget-' . Sanitizer::escapeId( $gadgetName, [ 'noninitial' ] );
+ }
+
+ /**
+ * Displays form showing the list of installed gadgets
+ */
+ public function showMainForm() {
+ global $wgContLang;
+
+ $output = $this->getOutput();
+ $this->setHeaders();
+ $output->setPageTitle( $this->msg( 'gadgets-title' ) );
+ $output->addWikiMsg( 'gadgets-pagetext' );
+
+ $gadgets = GadgetRepo::singleton()->getStructuredList();
+ if ( !$gadgets ) {
+ return;
+ }
+
+ $output->disallowUserJs();
+ $lang = $this->getLanguage();
+ $langSuffix = "";
+ if ( $lang->getCode() != $wgContLang->getCode() ) {
+ $langSuffix = "/" . $lang->getCode();
+ }
+
+ $listOpen = false;
+
+ $editInterfaceMessage = $this->getUser()->isAllowed( 'editinterface' )
+ ? 'edit'
+ : 'viewsource';
+
+ $linkRenderer = $this->getLinkRenderer();
+ foreach ( $gadgets as $section => $entries ) {
+ if ( $section !== false && $section !== '' ) {
+ $t = Title::makeTitleSafe( NS_MEDIAWIKI, "Gadget-section-$section$langSuffix" );
+ $lnkTarget = $t
+ ? $linkRenderer->makeLink( $t, $this->msg( $editInterfaceMessage )->text(),
+ [], [ 'action' => 'edit' ] )
+ : htmlspecialchars( $section );
+ $lnk = "&#160; &#160; [$lnkTarget]";
+
+ $ttext = $this->msg( "gadget-section-$section" )->parse();
+
+ if ( $listOpen ) {
+ $output->addHTML( Xml::closeElement( 'ul' ) . "\n" );
+ $listOpen = false;
+ }
+
+ $output->addHTML( Html::rawElement( 'h2', [], $ttext . $lnk ) . "\n" );
+ }
+
+ /**
+ * @var $gadget Gadget
+ */
+ foreach ( $entries as $gadget ) {
+ $name = $gadget->getName();
+ $t = Title::makeTitleSafe( NS_MEDIAWIKI, "Gadget-{$name}$langSuffix" );
+ if ( !$t ) {
+ continue;
+ }
+
+ $links = [];
+ $links[] = $linkRenderer->makeLink(
+ $t,
+ $this->msg( $editInterfaceMessage )->text(),
+ [],
+ [ 'action' => 'edit' ]
+ );
+ $links[] = $linkRenderer->makeLink(
+ $this->getPageTitle( "export/{$name}" ),
+ $this->msg( 'gadgets-export' )->text()
+ );
+
+ $ttext = $this->msg( "gadget-{$name}" )->parse();
+
+ if ( !$listOpen ) {
+ $listOpen = true;
+ $output->addHTML( Xml::openElement( 'ul' ) );
+ }
+
+ $actions = '&#160;&#160;' .
+ $this->msg( 'parentheses' )->rawParams( $lang->pipeList( $links ) )->escaped();
+ $output->addHTML(
+ Xml::openElement( 'li', [ 'id' => $this->makeAnchor( $name ) ] ) .
+ $ttext . $actions . "<br />" .
+ $this->msg( 'gadgets-uses' )->escaped() .
+ $this->msg( 'colon-separator' )->escaped()
+ );
+
+ $lnk = [];
+ foreach ( $gadget->getPeers() as $peer ) {
+ $lnk[] = Html::element(
+ 'a',
+ [ 'href' => '#' . $this->makeAnchor( $peer ) ],
+ $peer
+ );
+ }
+ foreach ( $gadget->getScriptsAndStyles() as $codePage ) {
+ $t = Title::newFromText( $codePage );
+
+ if ( !$t ) {
+ continue;
+ }
+
+ $lnk[] = $linkRenderer->makeLink( $t, $t->getText() );
+ }
+ $output->addHTML( $lang->commaList( $lnk ) );
+ if ( $gadget->getLegacyScripts() ) {
+ $output->addHTML( '<br />' . Html::rawElement(
+ 'span',
+ [ 'class' => 'mw-gadget-legacy errorbox' ],
+ $this->msg( 'gadgets-legacy' )->parse()
+ ) );
+ }
+
+ $rights = [];
+ foreach ( $gadget->getRequiredRights() as $right ) {
+ $rights[] = '* ' . $this->msg( "right-$right" )->plain();
+ }
+ if ( count( $rights ) ) {
+ $output->addHTML( '<br />' .
+ $this->msg( 'gadgets-required-rights', implode( "\n", $rights ), count( $rights ) )->parse()
+ );
+ }
+
+ $requiredSkins = $gadget->getRequiredSkins();
+ // $requiredSkins can be an array or true (if all skins are supported)
+ if ( is_array( $requiredSkins ) ) {
+ $skins = [];
+ $validskins = Skin::getSkinNames();
+ foreach ( $requiredSkins as $skinid ) {
+ if ( isset( $validskins[$skinid] ) ) {
+ $skins[] = $this->msg( "skinname-$skinid" )->plain();
+ } else {
+ $skins[] = $skinid;
+ }
+ }
+ if ( count( $skins ) ) {
+ $output->addHTML(
+ '<br />' .
+ $this->msg( 'gadgets-required-skins', $lang->commaList( $skins ) )
+ ->numParams( count( $skins ) )->parse()
+ );
+ }
+ }
+
+ if ( $gadget->isOnByDefault() ) {
+ $output->addHTML( '<br />' . $this->msg( 'gadgets-default' )->parse() );
+ }
+
+ $output->addHTML( Xml::closeElement( 'li' ) . "\n" );
+ }
+ }
+
+ if ( $listOpen ) {
+ $output->addHTML( Xml::closeElement( 'ul' ) . "\n" );
+ }
+ }
+
+ /**
+ * Exports a gadget with its dependencies in a serialized form
+ * @param string $gadget Name of gadget to export
+ */
+ public function showExportForm( $gadget ) {
+ global $wgScript;
+
+ $output = $this->getOutput();
+ try {
+ $g = GadgetRepo::singleton()->getGadget( $gadget );
+ } catch ( InvalidArgumentException $e ) {
+ $output->showErrorPage( 'error', 'gadgets-not-found', [ $gadget ] );
+ return;
+ }
+
+ $this->setHeaders();
+ $output->setPageTitle( $this->msg( 'gadgets-export-title' ) );
+ $output->addWikiMsg( 'gadgets-export-text', $gadget, $g->getDefinition() );
+
+ $exportList = "MediaWiki:gadget-$gadget\n";
+ foreach ( $g->getScriptsAndStyles() as $page ) {
+ $exportList .= "$page\n";
+ }
+
+ $htmlForm = HTMLForm::factory( 'ooui', [], $this->getContext() );
+ $htmlForm
+ ->addHiddenField( 'title', SpecialPage::getTitleFor( 'Export' )->getPrefixedDBKey() )
+ ->addHiddenField( 'pages', $exportList )
+ ->addHiddenField( 'wpDownload', '1' )
+ ->addHiddenField( 'templates', '1' )
+ ->setAction( $wgScript )
+ ->setMethod( 'get' )
+ ->setSubmitText( $this->msg( 'gadgets-export-download' )->text() )
+ ->prepareForm()
+ ->displayForm( false );
+ }
+
+ protected function getGroupName() {
+ return 'wiki';
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgetCategories.php b/www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgetCategories.php
new file mode 100644
index 00000000..489f6650
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgetCategories.php
@@ -0,0 +1,110 @@
+<?php
+/**
+ * Created on 16 April 2011
+ * API for Gadgets extension
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+class ApiQueryGadgetCategories extends ApiQueryBase {
+ /**
+ * @var array
+ */
+ private $props;
+
+ /**
+ * @var array|bool
+ */
+ private $neededNames;
+
+ public function __construct( ApiQuery $queryModule, $moduleName ) {
+ parent::__construct( $queryModule, $moduleName, 'gc' );
+ }
+
+ public function execute() {
+ $params = $this->extractRequestParams();
+ $this->props = array_flip( $params['prop'] );
+ $this->neededNames = isset( $params['names'] )
+ ? array_flip( $params['names'] )
+ : false;
+
+ $this->getMain()->setCacheMode( 'public' );
+
+ $this->getList();
+ }
+
+ private function getList() {
+ $data = [];
+ $result = $this->getResult();
+ $gadgets = GadgetRepo::singleton()->getStructuredList();
+
+ if ( $gadgets ) {
+ foreach ( $gadgets as $category => $list ) {
+ if ( !$this->neededNames || isset( $this->neededNames[$category] ) ) {
+ $row = [];
+ if ( isset( $this->props['name'] ) ) {
+ $row['name'] = $category;
+ }
+
+ if ( $category !== "" ) {
+ if ( isset( $this->props['title'] ) ) {
+ $row['desc'] = $this->msg( "gadget-section-$category" )->parse();
+ }
+ }
+
+ if ( isset( $this->props['members'] ) ) {
+ $row['members'] = count( $list );
+ }
+
+ $data[] = $row;
+ }
+ }
+ }
+ $result->setIndexedTagName( $data, 'category' );
+ $result->addValue( 'query', $this->getModuleName(), $data );
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'prop' => [
+ ApiBase::PARAM_DFLT => 'name',
+ ApiBase::PARAM_ISMULTI => true,
+ ApiBase::PARAM_TYPE => [
+ 'name',
+ 'title',
+ 'members',
+ ],
+ ],
+ 'names' => [
+ ApiBase::PARAM_TYPE => 'string',
+ ApiBase::PARAM_ISMULTI => true,
+ ],
+ ];
+ }
+
+ /**
+ * @see ApiBase::getExamplesMessages()
+ * @return array
+ */
+ protected function getExamplesMessages() {
+ return [
+ 'action=query&list=gadgetcategories'
+ => 'apihelp-query+gadgetcategories-example-1',
+ 'action=query&list=gadgetcategories&gcnames=foo|bar&gcprop=name|title|members'
+ => 'apihelp-query+gadgetcategories-example-2',
+ ];
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgets.php b/www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgets.php
new file mode 100644
index 00000000..618858da
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/includes/api/ApiQueryGadgets.php
@@ -0,0 +1,231 @@
+<?php
+/**
+ * Created on 15 April 2011
+ * API for Gadgets extension
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+class ApiQueryGadgets extends ApiQueryBase {
+ /**
+ * @var array
+ */
+ private $props;
+
+ /**
+ * @var array|bool
+ */
+ private $categories;
+
+ /**
+ * @var array|bool
+ */
+ private $neededIds;
+
+ /**
+ * @var bool
+ */
+ private $listAllowed;
+
+ /**
+ * @var bool
+ */
+ private $listEnabled;
+
+ public function __construct( ApiQuery $queryModule, $moduleName ) {
+ parent::__construct( $queryModule, $moduleName, 'ga' );
+ }
+
+ public function execute() {
+ $params = $this->extractRequestParams();
+ $this->props = array_flip( $params['prop'] );
+ $this->categories = isset( $params['categories'] )
+ ? array_flip( $params['categories'] )
+ : false;
+ $this->neededIds = isset( $params['ids'] )
+ ? array_flip( $params['ids'] )
+ : false;
+ $this->listAllowed = isset( $params['allowedonly'] ) && $params['allowedonly'];
+ $this->listEnabled = isset( $params['enabledonly'] ) && $params['enabledonly'];
+
+ $this->getMain()->setCacheMode( $this->listAllowed || $this->listEnabled
+ ? 'anon-public-user-private' : 'public' );
+
+ $this->applyList( $this->getList() );
+ }
+
+ /**
+ * @return array
+ */
+ private function getList() {
+ $gadgets = GadgetRepo::singleton()->getStructuredList();
+
+ if ( $gadgets === false ) {
+ return [];
+ }
+
+ $result = [];
+ foreach ( $gadgets as $category => $list ) {
+ if ( $this->categories && !isset( $this->categories[$category] ) ) {
+ continue;
+ }
+
+ foreach ( $list as $g ) {
+ if ( $this->isNeeded( $g ) ) {
+ $result[] = $g;
+ }
+ }
+ }
+ return $result;
+ }
+
+ /**
+ * @param array $gadgets
+ */
+ private function applyList( $gadgets ) {
+ $data = [];
+ $result = $this->getResult();
+
+ /**
+ * @var $g Gadget
+ */
+ foreach ( $gadgets as $g ) {
+ $row = [];
+ if ( isset( $this->props['id'] ) ) {
+ $row['id'] = $g->getName();
+ }
+
+ if ( isset( $this->props['metadata'] ) ) {
+ $row['metadata'] = $this->fakeMetadata( $g );
+ $this->setIndexedTagNameForMetadata( $row['metadata'] );
+ }
+
+ if ( isset( $this->props['desc'] ) ) {
+ $row['desc'] = $g->getDescription();
+ }
+
+ $data[] = $row;
+ }
+
+ $result->setIndexedTagName( $data, 'gadget' );
+ $result->addValue( 'query', $this->getModuleName(), $data );
+ }
+
+ /**
+ * @param Gadget $gadget
+ *
+ * @return bool
+ */
+ private function isNeeded( Gadget $gadget ) {
+ $user = $this->getUser();
+
+ return ( $this->neededIds === false || isset( $this->neededIds[$gadget->getName()] ) )
+ && ( !$this->listAllowed || $gadget->isAllowed( $user ) )
+ && ( !$this->listEnabled || $gadget->isEnabled( $user ) );
+ }
+
+ /**
+ * @param Gadget $g
+ * @return array
+ */
+ private function fakeMetadata( Gadget $g ) {
+ return [
+ 'settings' => [
+ 'rights' => $g->getRequiredRights(),
+ 'skins' => $g->getRequiredSkins(),
+ 'default' => $g->isOnByDefault(),
+ 'hidden' => $g->isHidden(),
+ 'shared' => false,
+ 'category' => $g->getCategory(),
+ 'legacyscripts' => (bool)$g->getLegacyScripts(),
+ ],
+ 'module' => [
+ 'scripts' => $g->getScripts(),
+ 'styles' => $g->getStyles(),
+ 'dependencies' => $g->getDependencies(),
+ 'peers' => $g->getPeers(),
+ 'messages' => $g->getMessages(),
+ ]
+ ];
+ }
+
+ private function setIndexedTagNameForMetadata( &$metadata ) {
+ static $tagNames = [
+ 'rights' => 'right',
+ 'skins' => 'skin',
+ 'scripts' => 'script',
+ 'styles' => 'style',
+ 'dependencies' => 'dependency',
+ 'peers' => 'peer',
+ 'messages' => 'message',
+ ];
+
+ $result = $this->getResult();
+ foreach ( $metadata as $data ) {
+ foreach ( $data as $key => $value ) {
+ if ( is_array( $value ) ) {
+ $tag = isset( $tagNames[$key] ) ? $tagNames[$key] : $key;
+ $result->setIndexedTagName( $value, $tag );
+ }
+ }
+ }
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'prop' => [
+ ApiBase::PARAM_DFLT => 'id|metadata',
+ ApiBase::PARAM_ISMULTI => true,
+ ApiBase::PARAM_TYPE => [
+ 'id',
+ 'metadata',
+ 'desc',
+ ],
+ ],
+ 'categories' => [
+ ApiBase::PARAM_ISMULTI => true,
+ ApiBase::PARAM_TYPE => 'string',
+ ],
+ 'ids' => [
+ ApiBase::PARAM_TYPE => 'string',
+ ApiBase::PARAM_ISMULTI => true,
+ ],
+ 'allowedonly' => false,
+ 'enabledonly' => false,
+ ];
+ }
+
+ /**
+ * @see ApiBase::getExamplesMessages()
+ * @return array
+ */
+ protected function getExamplesMessages() {
+ $params = $this->getAllowedParams();
+ $allProps = implode( '|', $params['prop'][ApiBase::PARAM_TYPE] );
+ return [
+ 'action=query&list=gadgets&gaprop=id|desc'
+ => 'apihelp-query+gadgets-example-1',
+ "action=query&list=gadgets&gaprop=$allProps"
+ => 'apihelp-query+gadgets-example-2',
+ 'action=query&list=gadgets&gacategories=foo'
+ => 'apihelp-query+gadgets-example-3',
+ 'action=query&list=gadgets&gaids=foo|bar&gaprop=id|desc|metadata'
+ => 'apihelp-query+gadgets-example-4',
+ 'action=query&list=gadgets&gaenabledonly'
+ => 'apihelp-query+gadgets-example-5',
+ ];
+ }
+}
diff --git a/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionContent.php b/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionContent.php
index 741b2615..0a7b2d9d 100644
--- a/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionContent.php
+++ b/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionContent.php
@@ -84,6 +84,7 @@ class GadgetDefinitionContent extends JsonContent {
* all fields filled out, populating defaults as necessary.
*
* @return array
+ * @suppress PhanUndeclaredMethod
*/
public function getAssocArray() {
$info = wfObjectToArray( $this->getData()->getValue() );
@@ -97,12 +98,12 @@ class GadgetDefinitionContent extends JsonContent {
/**
* @param WikiPage $page
* @param ParserOutput $parserOutput
- * @return DataUpdate[]
+ * @return DeferrableUpdate[]
*/
public function getDeletionUpdates( WikiPage $page, ParserOutput $parserOutput = null ) {
return array_merge(
parent::getDeletionUpdates( $page, $parserOutput ),
- [ new GadgetDefinitionDeletionUpdate( $page->getTitle()->getText() ) ]
+ [ new GadgetDefinitionDeletionUpdate( $page->getTitle() ) ]
);
}
@@ -118,7 +119,7 @@ class GadgetDefinitionContent extends JsonContent {
) {
return array_merge(
parent::getSecondaryDataUpdates( $title, $old, $recursive, $parserOutput ),
- [ new GadgetDefinitionSecondaryDataUpdate( $title->getText() ) ]
+ [ new GadgetDefinitionSecondaryDataUpdate( $title ) ]
);
}
}
diff --git a/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionDeletionUpdate.php b/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionDeletionUpdate.php
index 970f8cbe..97c8d8e8 100644
--- a/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionDeletionUpdate.php
+++ b/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionDeletionUpdate.php
@@ -20,26 +20,24 @@
* @file
*/
+use MediaWiki\Linker\LinkTarget;
+
/**
* DataUpdate to run whenever a page in the Gadget definition
* is deleted.
*/
class GadgetDefinitionDeletionUpdate extends DataUpdate {
/**
- * Gadget id
- * @var string
+ * Page that was deleted
+ * @var LinkTarget
*/
- private $id;
+ private $target;
- public function __construct( $id ) {
- $this->id = $id;
+ public function __construct( LinkTarget $target ) {
+ $this->target = $target;
}
public function doUpdate() {
- $repo = GadgetRepo::singleton();
- if ( $repo instanceof GadgetDefinitionNamespaceRepo ) {
- $repo->purgeGadgetIdsList();
- $repo->purgeGadgetEntry( $this->id );
- }
+ GadgetRepo::singleton()->handlePageDeletion( $this->target );
}
}
diff --git a/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionSecondaryDataUpdate.php b/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionSecondaryDataUpdate.php
index 10af53eb..8a663933 100644
--- a/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionSecondaryDataUpdate.php
+++ b/www/wiki/extensions/Gadgets/includes/content/GadgetDefinitionSecondaryDataUpdate.php
@@ -1,4 +1,5 @@
<?php
+
/**
* Copyright 2014
*
@@ -20,18 +21,20 @@
* @file
*/
+use MediaWiki\Linker\LinkTarget;
+
class GadgetDefinitionSecondaryDataUpdate extends DataUpdate {
- private $id;
+ /**
+ * @var LinkTarget
+ */
+ private $target;
- public function __construct( $id ) {
- $this->id = $id;
+ public function __construct( LinkTarget $target ) {
+ $this->target = $target;
}
public function doUpdate() {
- $repo = GadgetRepo::singleton();
- if ( $repo instanceof GadgetDefinitionNamespaceRepo ) {
- $repo->purgeGadgetEntry( $this->id );
- }
+ GadgetRepo::singleton()->handlePageUpdate( $this->target );
}
}
diff --git a/www/wiki/extensions/Gadgets/tests/phan/config.php b/www/wiki/extensions/Gadgets/tests/phan/config.php
new file mode 100644
index 00000000..6bc24d22
--- /dev/null
+++ b/www/wiki/extensions/Gadgets/tests/phan/config.php
@@ -0,0 +1,7 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+// Namespace constants
+$cfg['file_list'][] = 'Gadgets.namespaces.php';
+
+return $cfg;
diff --git a/www/wiki/extensions/Gadgets/tests/phpunit/GadgetTest.php b/www/wiki/extensions/Gadgets/tests/phpunit/GadgetTest.php
index e0f57684..39a742ec 100644
--- a/www/wiki/extensions/Gadgets/tests/phpunit/GadgetTest.php
+++ b/www/wiki/extensions/Gadgets/tests/phpunit/GadgetTest.php
@@ -5,8 +5,13 @@ use Wikimedia\TestingAccessWrapper;
/**
* @group Gadgets
*/
+class GadgetTest extends MediaWikiTestCase {
+
+ public function tearDown() {
+ GadgetRepo::setSingleton();
+ parent::tearDown();
+ }
-class GadgetsTest extends MediaWikiTestCase {
/**
* @param string $line
* @return Gadget
@@ -14,7 +19,7 @@ class GadgetsTest extends MediaWikiTestCase {
private function create( $line ) {
$repo = new MediaWikiGadgetsDefinitionRepo();
$g = $repo->newFromDefinition( $line, 'misc' );
- $this->assertInstanceOf( 'Gadget', $g );
+ $this->assertInstanceOf( Gadget::class, $g );
return $g;
}
@@ -26,12 +31,21 @@ class GadgetsTest extends MediaWikiTestCase {
return $module;
}
+ /**
+ * @covers MediaWikiGadgetsDefinitionRepo::newFromDefinition
+ */
public function testInvalidLines() {
$repo = new MediaWikiGadgetsDefinitionRepo();
$this->assertFalse( $repo->newFromDefinition( '', 'misc' ) );
$this->assertFalse( $repo->newFromDefinition( '<foo|bar>', 'misc' ) );
}
+ /**
+ * @covers MediaWikiGadgetsDefinitionRepo::newFromDefinition
+ * @covers Gadget::__construct
+ * @covers Gadget::getName
+ * @covers Gadget::getModuleName
+ */
public function testSimpleCases() {
$g = $this->create( '* foo bar| foo.css|foo.js|foo.bar' );
$this->assertEquals( 'foo_bar', $g->getName() );
@@ -45,6 +59,11 @@ class GadgetsTest extends MediaWikiTestCase {
$this->assertTrue( $g->hasModule() );
}
+ /**
+ * @covers MediaWikiGadgetsDefinitionRepo::newFromDefinition
+ * @covers Gadget::supportsResourceLoader
+ * @covers Gadget::getLegacyScripts
+ */
public function testRLtag() {
$g = $this->create( '*foo [ResourceLoader]|foo.js|foo.css' );
$this->assertEquals( 'foo', $g->getName() );
@@ -52,6 +71,10 @@ class GadgetsTest extends MediaWikiTestCase {
$this->assertEquals( 0, count( $g->getLegacyScripts() ) );
}
+ /**
+ * @covers MediaWikiGadgetsDefinitionRepo::newFromDefinition
+ * @covers Gadget::getDependencies
+ */
public function testDependencies() {
$g = $this->create( '* foo[ResourceLoader|dependencies=jquery.ui]|bar.js' );
$this->assertEquals( [ 'MediaWiki:Gadget-bar.js' ], $g->getScripts() );
@@ -126,6 +149,9 @@ class GadgetsTest extends MediaWikiTestCase {
/**
* @dataProvider provideGetType
+ * @covers MediaWikiGadgetsDefinitionRepo::newFromDefinition
+ * @covers Gadget::getType
+ * @covers GadgetResourceLoaderModule::getType
*/
public function testType( $message, $definition, $gType, $mType ) {
$g = $this->create( $definition );
@@ -133,6 +159,10 @@ class GadgetsTest extends MediaWikiTestCase {
$this->assertEquals( $mType, $this->getModule( $g )->getType(), "Module: $message" );
}
+ /**
+ * @covers MediaWikiGadgetsDefinitionRepo::newFromDefinition
+ * @covers Gadget::isHidden
+ */
public function testIsHidden() {
$g = $this->create( '* foo[hidden]|bar.js' );
$this->assertTrue( $g->isHidden() );
@@ -144,6 +174,10 @@ class GadgetsTest extends MediaWikiTestCase {
$this->assertFalse( $g->isHidden() );
}
+ /**
+ * @covers MediaWikiGadgetsDefinitionRepo::fetchStructuredList
+ * @covers GadgetHooks::getPreferences
+ */
public function testPreferences() {
$prefs = [];
$repo = TestingAccessWrapper::newFromObject( new MediaWikiGadgetsDefinitionRepo() );
@@ -169,9 +203,4 @@ class GadgetsTest extends MediaWikiTestCase {
$this->assertArrayHasKey( '⧼gadget-section-keep-section1⧽', $options );
$this->assertArrayHasKey( '⧼gadget-section-keep-section2⧽', $options );
}
-
- public function tearDown() {
- GadgetRepo::setSingleton();
- parent::tearDown();
- }
}
diff --git a/www/wiki/extensions/ImageMap/Gruntfile.js b/www/wiki/extensions/ImageMap/Gruntfile.js
index e4033e51..26ca0c16 100644
--- a/www/wiki/extensions/ImageMap/Gruntfile.js
+++ b/www/wiki/extensions/ImageMap/Gruntfile.js
@@ -17,7 +17,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/ImageMap/composer.json b/www/wiki/extensions/ImageMap/composer.json
index da3ceffe..87a7c028 100644
--- a/www/wiki/extensions/ImageMap/composer.json
+++ b/www/wiki/extensions/ImageMap/composer.json
@@ -8,26 +8,30 @@
"ImageMap"
],
"homepage": "https://www.mediawiki.org/wiki/Extension:ImageMap",
- "license": "GPL-2.0+",
+ "license": "GPL-2.0-or-later",
"require": {
"php": ">=5.4",
"composer/installers": "1.*,>=1.0.1"
},
- "autoload": {
- "classmap": [
- "ImageMap_body.php"
- ]
- },
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
- "parallel-lint . --exclude vendor",
- "phpcs -p -s"
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/ImageMap/extension.json b/www/wiki/extensions/ImageMap/extension.json
index 572c1497..76a8dfd0 100644
--- a/www/wiki/extensions/ImageMap/extension.json
+++ b/www/wiki/extensions/ImageMap/extension.json
@@ -3,7 +3,7 @@
"author": "Tim Starling",
"url": "https://www.mediawiki.org/wiki/Extension:ImageMap",
"descriptionmsg": "imagemap_desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "parserhook",
"MessagesDirs": {
"ImageMap": [
@@ -16,10 +16,7 @@
]
},
"AutoloadClasses": {
- "ImageMap": "ImageMap_body.php"
+ "ImageMap": "includes/ImageMap.php"
},
- "ParserTestFiles": [
- "imageMapParserTests.txt"
- ],
"manifest_version": 1
}
diff --git a/www/wiki/extensions/ImageMap/i18n/ais.json b/www/wiki/extensions/ImageMap/i18n/ais.json
index 45603cfc..c8a98059 100644
--- a/www/wiki/extensions/ImageMap/i18n/ais.json
+++ b/www/wiki/extensions/ImageMap/i18n/ais.json
@@ -1,8 +1,20 @@
{
"@metadata": {
"authors": [
- "Benel"
+ "Benel",
+ "Bunukwiki"
]
},
- "imagemap_description": "mahizaay kuyni a iga"
+ "imagemap_desc": "mahasa kolatando pisaungay <code>&lt;imagemap&gt;</code> aazihen-paya kapah misanga’ sapecec tu misaungayay sasing papo",
+ "imagemap_no_image": "mungangaw: kanca matuzu’ay tu iga i sakacacay a tusil.",
+ "imagemap_invalid_image": "mungangaw:iga caay tatenga’ saca inayi’.",
+ "imagemap_bad_image": "mungangaw: pasilsil tu kasabelih ku iga malangat piazihan-tu-sulit.",
+ "imagemap_no_link": "mungangaw: i saka $1 tusil sazikuzay caay katepah kapahay a siket.",
+ "imagemap_invalid_title": "mungangaw:i saka $1 tusil misiket satangahan la’cus.",
+ "imagemap_missing_coord": "mungangaw:i saka $1 tusil ma’ngadis taenengan palekal tu cacay a bacu.",
+ "imagemap_unrecognised_shape": "mungangaw: i saka $1 tusil izaw ku la’cus taazihan a bacu, paytusil kanca pisaungay isasa’ cacay cebang a sulit miteka: <code>default</code>, <code>rect</code>, <code>circle</code> saca <code>poly</code>.",
+ "imagemap_invalid_coord": "mungangaw: i saka $1 tusil izaw tu caay katatenga’ay a puenengan-bacu, puenengan-bacu kanca ku asip-bacu.",
+ "imagemap_invalid_desc": "mungangaw: caay tatenga’ay tu i desc a lalkuan. kanca u cudad isasa’ sizumaay cacay: <code>$1</code>.",
+ "imagemap_description": "mahizaay kuyni a iga",
+ "imagemap_poly_odd": "mungangaw:i saka $1 tusil matepa cayapiay-asip yadah-nikatatapal puenengan-bacu"
}
diff --git a/www/wiki/extensions/ImageMap/i18n/bg.json b/www/wiki/extensions/ImageMap/i18n/bg.json
index da784608..46299f5f 100644
--- a/www/wiki/extensions/ImageMap/i18n/bg.json
+++ b/www/wiki/extensions/ImageMap/i18n/bg.json
@@ -1,18 +1,19 @@
{
"@metadata": {
"authors": [
- "Spiritia"
+ "Spiritia",
+ "StanProg"
]
},
- "imagemap_no_image": "Error: трябва да се укаже изображение на първия ред",
- "imagemap_invalid_image": "Error: невалидно или липсващо изображение",
- "imagemap_bad_image": "Грешка: има забрана за включване на изображението в тази страница",
- "imagemap_no_link": "Error: липсва валидна препратка в края на ред $1",
- "imagemap_invalid_title": "Error: невалидно заглавие в препратка на ред $1",
- "imagemap_missing_coord": "Error: недостатъчно координати за фигура на ред $1",
- "imagemap_unrecognised_shape": "Error: неразпозната фигура на ред $1; всеки ред трябва да са започва с някое от следните: <code>default</code> (по подразбиране), <code>rect</code> (правоъгълник), <code>circle</code> (кръг) или <code>poly</code> (многоъгълник)",
- "imagemap_invalid_coord": "Error: невалидна координата на ред $1, трябва да бъде число",
- "imagemap_invalid_desc": "Грешка: невалидна спецификация на описанието (desc), което трябва да бъде някое от следните: <code>$1</code>",
+ "imagemap_no_image": "Грешка: трябва да се укаже изображение на първия ред.",
+ "imagemap_invalid_image": "Грешка: невалидно или липсващо изображение.",
+ "imagemap_bad_image": "Грешка: има забрана за включване на изображението в тази страница.",
+ "imagemap_no_link": "Грешка: липсва валидна препратка в края на ред $1.",
+ "imagemap_invalid_title": "Грешка: невалидно заглавие в препратка на ред $1.",
+ "imagemap_missing_coord": "Грешка: недостатъчно координати за фигура на ред $1.",
+ "imagemap_unrecognised_shape": "Грешка: неразпозната фигура на ред $1; всеки ред трябва да са започва с някое от следните: <code>default</code> (по подразбиране), <code>rect</code> (правоъгълник), <code>circle</code> (кръг) или <code>poly</code> (многоъгълник).",
+ "imagemap_invalid_coord": "Грешка: невалидна координата на ред $1, трябва да бъде число.",
+ "imagemap_invalid_desc": "Грешка: невалидна спецификация на описанието (desc), което трябва да бъде някое от следните: <code>$1</code>.",
"imagemap_description": "Информация за изображението",
"imagemap_poly_odd": "Грешка: открит е многоъгълник (poly) с нечетен брой координати на ред $1"
}
diff --git a/www/wiki/extensions/ImageMap/i18n/hu.json b/www/wiki/extensions/ImageMap/i18n/hu.json
index af72f878..f5c80405 100644
--- a/www/wiki/extensions/ImageMap/i18n/hu.json
+++ b/www/wiki/extensions/ImageMap/i18n/hu.json
@@ -3,19 +3,20 @@
"authors": [
"Dani",
"KossuthRad",
- "Tgr"
+ "Tgr",
+ "Tacsipacsi"
]
},
- "imagemap_desc": "Lehetővé teszi kliensoldali imagemap-ek létrehozását a <code>&lt;imagemap&gt;</code> tag segítségével",
- "imagemap_no_image": "Error: kell egy előírt kép az első sorban",
- "imagemap_invalid_image": "Error: érvénytelen vagy nem létező kép",
+ "imagemap_desc": "Lehetővé teszi kliensoldali imagemapek létrehozását az <code>&lt;imagemap&gt;</code> címke segítségével",
+ "imagemap_no_image": "Hiba: kell egy előírt kép az első sorban",
+ "imagemap_invalid_image": "Hiba: érvénytelen vagy nem létező kép",
"imagemap_bad_image": "Hiba: a kép feketelistán van ezen az oldalon",
- "imagemap_no_link": "Error: nincs érvényes link a(z) $1. sor végén",
- "imagemap_invalid_title": "Hiba: érvénytelen cím a linkben, a(z) $1. sorban",
- "imagemap_missing_coord": "Error: nincs elég koordináta az alakításhoz a $1 sorban",
- "imagemap_unrecognised_shape": "Error: ismeretlen alakzat a(z) $1. sorban, mindegyiknek ezek valamelyikével kell kezdődnie: <code>default</code>, <code>rect</code>, <code>circle</code> vagy <code>poly</code>",
+ "imagemap_no_link": "Hiba: nincs érvényes link a(z) $1. sor végén",
+ "imagemap_invalid_title": "Hiba: érvénytelen cím a linkben a(z) $1. sorban",
+ "imagemap_missing_coord": "Hiba: nincs elég koordináta az alakzathoz a(z) $1. sorban",
+ "imagemap_unrecognised_shape": "Hiba: ismeretlen alakzat a(z) $1. sorban, minden sornak a következők valamelyikével kell kezdődnie: <code>default</code>, <code>rect</code>, <code>circle</code> vagy <code>poly</code>",
"imagemap_invalid_coord": "Hiba: érvénytelen koordináta a(z) $1. sorban, számnak kell lennie",
- "imagemap_invalid_desc": "Error: hibás desc leírás, ezek egyike kell: <code>$1</code>",
- "imagemap_description": "Kép leírása",
- "imagemap_poly_odd": "Hiba: az $1. sorban páratlan számú koordináta található"
+ "imagemap_invalid_desc": "Hiba: hibás desc leírás, ezek egyike kell: <code>$1</code>",
+ "imagemap_description": "Erről a képről",
+ "imagemap_poly_odd": "Hiba: a(z) $1. sorban páratlan számú koordináta található"
}
diff --git a/www/wiki/extensions/ImageMap/i18n/id.json b/www/wiki/extensions/ImageMap/i18n/id.json
index ed82034f..a5a071bc 100644
--- a/www/wiki/extensions/ImageMap/i18n/id.json
+++ b/www/wiki/extensions/ImageMap/i18n/id.json
@@ -2,19 +2,20 @@
"@metadata": {
"authors": [
"IvanLanin",
- "Rex"
+ "Rex",
+ "Gombang"
]
},
"imagemap_desc": "Menyediakan peta gambar yang dapat diklik dari klien dengan menggunakan tag <code>&lt;imagemap&gt;</code>",
- "imagemap_no_image": "&lt;imagemap&gt;: harus memberikan suatu gambar di baris pertama",
- "imagemap_invalid_image": "&lt;imagemap&gt;: gambar tidak sah atau tidak ditemukan",
+ "imagemap_no_image": "Kesalahan: silakan tentukan gambar dalam baris pertama",
+ "imagemap_invalid_image": "Kesalahan: Gambar tidak sah atau tidak ditemukan.",
"imagemap_bad_image": "Kesalahan: berkas tidak diperbolehkan pada halaman ini",
- "imagemap_no_link": "&lt;imagemap&gt;: tidak ditemukan pranala yang sah di akhir baris ke $1",
- "imagemap_invalid_title": "&lt;imagemap&gt;: judul tidak sah pada pranala di baris ke $1",
- "imagemap_missing_coord": "&lt;imagemap&gt;: tidak cukup koordinat untuk bentuk pada baris ke $1",
- "imagemap_unrecognised_shape": "&lt;imagemap&gt;: bentuk tak dikenali pada baris ke $1, tiap baris harus dimulai dengan salah satu dari: <code>default</code>, <code>rect</code>, <code>circle</code> atau <code>poly</code>",
- "imagemap_invalid_coord": "&lt;imagemap&gt;: koordinat tidak sah pada baris ke $1, haruslah berupa angka",
- "imagemap_invalid_desc": "&lt;imagemap&gt;: spesifikasi desc tidak sah, harus salah satu dari: $1",
+ "imagemap_no_link": "Kesalahan: tidak ditemukan pranala yang sah di akhir baris ke $1",
+ "imagemap_invalid_title": "Kesalahan: judul tidak sah dalam pranala pada baris ke $1",
+ "imagemap_missing_coord": "Kesalahan: tidak cukup koordinat untuk bentuk pada baris ke $1",
+ "imagemap_unrecognised_shape": "Kesalahan: bentuk pada baris ke $1 tidak dikenali. Tiap baris harus dimulai dengan salah satu dari: <code>default</code>, <code>rect</code>, <code>circle</code> atau <code>poly</code>",
+ "imagemap_invalid_coord": "Kesalahan: koordinat tidak sah pada baris ke $1, haruslah berupa angka",
+ "imagemap_invalid_desc": "Kesalahan: spesifikasi desc tidak sah, harus salah satu dari: $1",
"imagemap_description": "Tentang gambar ini",
"imagemap_poly_odd": "Kesalahan: terdapat poligon dengan nomor koordinat salah pada baris $1"
}
diff --git a/www/wiki/extensions/ImageMap/i18n/ko.json b/www/wiki/extensions/ImageMap/i18n/ko.json
index 61cb75b6..c4770372 100644
--- a/www/wiki/extensions/ImageMap/i18n/ko.json
+++ b/www/wiki/extensions/ImageMap/i18n/ko.json
@@ -5,10 +5,11 @@
"Kwj2772",
"Yknok29",
"아라",
- "Hwangjy9"
+ "Hwangjy9",
+ "Garam"
]
},
- "imagemap_desc": "<code>&lt;imagemap&gt;</code> 태그로 클라이언트 측에서 클릭할 수 있는 이미지 맵을 사용할 수 있습니다",
+ "imagemap_desc": "<code>&lt;imagemap&gt;</code> 태그로 클라이언트 측에서 클릭할 수 있는 영상 지도를 사용할 수 있습니다",
"imagemap_no_image": "오류: 첫 줄에 그림이 제시되어야 합니다.",
"imagemap_invalid_image": "오류: 그림이 잘못되었거나 존재하지 않습니다.",
"imagemap_bad_image": "오류: 그림은 이 문서에서 사용이 금지되어 있습니다.",
diff --git a/www/wiki/extensions/ImageMap/i18n/nb.json b/www/wiki/extensions/ImageMap/i18n/nb.json
index b76b86a7..217231f6 100644
--- a/www/wiki/extensions/ImageMap/i18n/nb.json
+++ b/www/wiki/extensions/ImageMap/i18n/nb.json
@@ -1,5 +1,9 @@
{
- "@metadata": [],
+ "@metadata": {
+ "authors": [
+ "Jon Harald Søby"
+ ]
+ },
"imagemap_desc": "Gjør at man kan bruke klikkbare bilder ved hjelp av <code>&lt;imagemap&gt;</code>.",
"imagemap_no_image": "Error: må angi et bilde i første linje",
"imagemap_invalid_image": "Error: bilde er ugyldig eller ikke-eksisterende",
diff --git a/www/wiki/extensions/ImageMap/i18n/pt.json b/www/wiki/extensions/ImageMap/i18n/pt.json
index 69186bd5..77df7639 100644
--- a/www/wiki/extensions/ImageMap/i18n/pt.json
+++ b/www/wiki/extensions/ImageMap/i18n/pt.json
@@ -9,8 +9,8 @@
"imagemap_no_image": "Erro: é necessário especificar uma imagem na primeira linha",
"imagemap_invalid_image": "Erro: imagem inválida ou inexistente",
"imagemap_bad_image": "Erro: a imagem está na lista negra para esta página",
- "imagemap_no_link": "Erro: não foi encontrada nenhum link válido, ao final da linha $1",
- "imagemap_invalid_title": "Erro: título inválido num link, na linha $1",
+ "imagemap_no_link": "Erro: não foi encontrada nenhuma hiperligação válida ao final da linha $1.",
+ "imagemap_invalid_title": "Erro: título inválido numa hiperligação, na linha $1.",
"imagemap_missing_coord": "Erro: coordenadas insuficientes para formar uma figura, na linha $1",
"imagemap_unrecognised_shape": "Erro: figura não reconhecida, na linha $1 - cada linha tem de começar por: <code>default</code>, <code>rect</code>, <code>circle</code> ou <code>poly</code>",
"imagemap_invalid_coord": "Erro: coordenada inválida, na linha $1 - tem de ser um número",
diff --git a/www/wiki/extensions/ImageMap/i18n/sat.json b/www/wiki/extensions/ImageMap/i18n/sat.json
new file mode 100644
index 00000000..dc837642
--- /dev/null
+++ b/www/wiki/extensions/ImageMap/i18n/sat.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ramjit Tudu"
+ ]
+ },
+ "imagemap_description": "ᱱᱚᱣᱟ ᱪᱤᱛᱟᱹᱨ ᱵᱟᱵᱚᱫᱽᱛᱮ"
+}
diff --git a/www/wiki/extensions/ImageMap/i18n/ur.json b/www/wiki/extensions/ImageMap/i18n/ur.json
new file mode 100644
index 00000000..186e79ca
--- /dev/null
+++ b/www/wiki/extensions/ImageMap/i18n/ur.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "BukhariSaeed"
+ ]
+ },
+ "imagemap_invalid_image": "خطا: تصویر نا درست یا غیر موجود ہے۔",
+ "imagemap_bad_image": "خطا: تصویر اس صفحہ پر بلیک لسٹ ہے۔",
+ "imagemap_no_link": "خطا: سطر $1 کے آخر میں کوئی درست ربط نہیں ملا۔",
+ "imagemap_invalid_title": "خطا: سطر $1 پر ربط میں نادرست عنوان۔",
+ "imagemap_description": "اس تصویر کے متعلق"
+}
diff --git a/www/wiki/extensions/ImageMap/includes/ImageMap.php b/www/wiki/extensions/ImageMap/includes/ImageMap.php
new file mode 100644
index 00000000..05d6531b
--- /dev/null
+++ b/www/wiki/extensions/ImageMap/includes/ImageMap.php
@@ -0,0 +1,406 @@
+<?php
+/**
+ * Main file for extension ImageMap.
+ *
+ * @file
+ * @ingroup Extensions
+ *
+ * Syntax:
+ * <imagemap>
+ * Image:Foo.jpg | 100px | picture of a foo
+ *
+ * rect 0 0 50 50 [[Foo type A]]
+ * circle 50 50 20 [[Foo type B]]
+ *
+ * desc bottom-left
+ * </imagemap>
+ *
+ * Coordinates are relative to the source image, not the thumbnail.
+ */
+
+class ImageMap {
+ public static $id = 0;
+
+ const TOP_RIGHT = 0;
+ const BOTTOM_RIGHT = 1;
+ const BOTTOM_LEFT = 2;
+ const TOP_LEFT = 3;
+ const NONE = 4;
+
+ /**
+ * @param Parser &$parser
+ */
+ public static function onParserFirstCallInit( Parser &$parser ) {
+ $parser->setHook( 'imagemap', [ 'ImageMap', 'render' ] );
+ }
+
+ /**
+ * @param string $input
+ * @param array $params
+ * @param Parser $parser
+ * @return string HTML (Image map, or error message)
+ */
+ public static function render( $input, $params, $parser ) {
+ global $wgUrlProtocols, $wgNoFollowLinks;
+ $config = ConfigFactory::getDefaultInstance()->makeConfig( 'main' );
+
+ $lines = explode( "\n", $input );
+
+ $first = true;
+ $lineNum = 0;
+ $mapHTML = '';
+ $links = [];
+
+ // Define canonical desc types to allow i18n of 'imagemap_desc_types'
+ $descTypesCanonical = 'top-right, bottom-right, bottom-left, top-left, none';
+ $descType = self::BOTTOM_RIGHT;
+ $defaultLinkAttribs = false;
+ $realmap = true;
+ $extLinks = [];
+ foreach ( $lines as $line ) {
+ ++$lineNum;
+ $externLink = false;
+
+ $line = trim( $line );
+ if ( $line == '' || $line[0] == '#' ) {
+ continue;
+ }
+
+ if ( $first ) {
+ $first = false;
+
+ // The first line should have an image specification on it
+ // Extract it and render the HTML
+ $bits = explode( '|', $line, 2 );
+ if ( count( $bits ) == 1 ) {
+ $image = $bits[0];
+ $options = '';
+ } else {
+ list( $image, $options ) = $bits;
+ }
+ $imageTitle = Title::newFromText( $image );
+ if ( !$imageTitle || !$imageTitle->inNamespace( NS_FILE ) ) {
+ return self::error( 'imagemap_no_image' );
+ }
+ if ( wfIsBadImage( $imageTitle->getDBkey(), $parser->mTitle ) ) {
+ return self::error( 'imagemap_bad_image' );
+ }
+ // Parse the options so we can use links and the like in the caption
+ $parsedOptions = $parser->recursiveTagParse( $options );
+ $imageHTML = $parser->makeImage( $imageTitle, $parsedOptions );
+ $parser->replaceLinkHolders( $imageHTML );
+ $imageHTML = $parser->mStripState->unstripBoth( $imageHTML );
+ $imageHTML = Sanitizer::normalizeCharReferences( $imageHTML );
+
+ $domDoc = new DOMDocument();
+ wfSuppressWarnings();
+ $ok = $domDoc->loadXML( $imageHTML );
+ wfRestoreWarnings();
+ if ( !$ok ) {
+ return self::error( 'imagemap_invalid_image' );
+ }
+ $xpath = new DOMXPath( $domDoc );
+ $imgs = $xpath->query( '//img' );
+ if ( !$imgs->length ) {
+ return self::error( 'imagemap_invalid_image' );
+ }
+ $imageNode = $imgs->item( 0 );
+ $thumbWidth = $imageNode->getAttribute( 'width' );
+ $thumbHeight = $imageNode->getAttribute( 'height' );
+
+ $imageObj = wfFindFile( $imageTitle );
+ if ( !$imageObj || !$imageObj->exists() ) {
+ return self::error( 'imagemap_invalid_image' );
+ }
+ // Add the linear dimensions to avoid inaccuracy in the scale
+ // factor when one is much larger than the other
+ // (sx+sy)/(x+y) = s
+ $denominator = $imageObj->getWidth() + $imageObj->getHeight();
+ $numerator = $thumbWidth + $thumbHeight;
+ if ( $denominator <= 0 || $numerator <= 0 ) {
+ return self::error( 'imagemap_invalid_image' );
+ }
+ $scale = $numerator / $denominator;
+ continue;
+ }
+
+ // Handle desc spec
+ $cmd = strtok( $line, " \t" );
+ if ( $cmd == 'desc' ) {
+ $typesText = wfMessage( 'imagemap_desc_types' )->inContentLanguage()->text();
+ if ( $descTypesCanonical != $typesText ) {
+ // i18n desc types exists
+ $typesText = $descTypesCanonical . ', ' . $typesText;
+ }
+ $types = array_map( 'trim', explode( ',', $typesText ) );
+ $type = trim( strtok( '' ) );
+ $descType = array_search( $type, $types );
+ if ( $descType > 4 ) {
+ // A localized descType is used. Subtract 5 to reach the canonical desc type.
+ $descType = $descType - 5;
+ }
+ // <0? In theory never, but paranoia...
+ if ( $descType === false || $descType < 0 ) {
+ return self::error( 'imagemap_invalid_desc', $typesText );
+ }
+ continue;
+ }
+
+ $title = false;
+ // Find the link
+ $link = trim( strstr( $line, '[' ) );
+ $m = [];
+ if ( preg_match( '/^ \[\[ ([^|]*+) \| ([^\]]*+) \]\] \w* $ /x', $link, $m ) ) {
+ $title = Title::newFromText( $m[1] );
+ $alt = trim( $m[2] );
+ } elseif ( preg_match( '/^ \[\[ ([^\]]*+) \]\] \w* $ /x', $link, $m ) ) {
+ $title = Title::newFromText( $m[1] );
+ if ( is_null( $title ) ) {
+ return self::error( 'imagemap_invalid_title', $lineNum );
+ }
+ $alt = $title->getFullText();
+ } elseif ( in_array( substr( $link, 1, strpos( $link, '//' ) + 1 ), $wgUrlProtocols )
+ || in_array( substr( $link, 1, strpos( $link, ':' ) ), $wgUrlProtocols )
+ ) {
+ if ( preg_match( '/^ \[ ([^\s]*+) \s ([^\]]*+) \] \w* $ /x', $link, $m ) ) {
+ $title = $m[1];
+ $alt = trim( $m[2] );
+ $externLink = true;
+ } elseif ( preg_match( '/^ \[ ([^\]]*+) \] \w* $ /x', $link, $m ) ) {
+ $title = $alt = trim( $m[1] );
+ $externLink = true;
+ }
+ } else {
+ return self::error( 'imagemap_no_link', $lineNum );
+ }
+ if ( !$title ) {
+ return self::error( 'imagemap_invalid_title', $lineNum );
+ }
+
+ $shapeSpec = substr( $line, 0, -strlen( $link ) );
+
+ // Tokenize shape spec
+ $shape = strtok( $shapeSpec, " \t" );
+ switch ( $shape ) {
+ case 'default':
+ $coords = [];
+ break;
+ case 'rect':
+ $coords = self::tokenizeCoords( 4, $lineNum );
+ if ( !is_array( $coords ) ) {
+ return $coords;
+ }
+ break;
+ case 'circle':
+ $coords = self::tokenizeCoords( 3, $lineNum );
+ if ( !is_array( $coords ) ) {
+ return $coords;
+ }
+ break;
+ case 'poly':
+ $coords = [];
+ $coord = strtok( " \t" );
+ while ( $coord !== false ) {
+ $coords[] = $coord;
+ $coord = strtok( " \t" );
+ }
+ if ( !count( $coords ) ) {
+ return self::error( 'imagemap_missing_coord', $lineNum );
+ }
+ if ( count( $coords ) % 2 !== 0 ) {
+ return self::error( 'imagemap_poly_odd', $lineNum );
+ }
+ break;
+ default:
+ return self::error( 'imagemap_unrecognised_shape', $lineNum );
+ }
+
+ // Scale the coords using the size of the source image
+ foreach ( $coords as $i => $c ) {
+ $coords[$i] = intval( round( $c * $scale ) );
+ }
+
+ // Construct the area tag
+ $attribs = [];
+ if ( $externLink ) {
+ $attribs['href'] = $title;
+ $attribs['class'] = 'plainlinks';
+ if ( $wgNoFollowLinks ) {
+ $attribs['rel'] = 'nofollow';
+ }
+ } elseif ( $title->getFragment() != '' && $title->getPrefixedDBkey() == '' ) {
+ // XXX: kluge to handle [[#Fragment]] links, should really fix getLocalURL()
+ // in Title.php to return an empty string in this case
+ $attribs['href'] = $title->getFragmentForURL();
+ } else {
+ $attribs['href'] = $title->getLocalURL() . $title->getFragmentForURL();
+ }
+ if ( $shape != 'default' ) {
+ $attribs['shape'] = $shape;
+ }
+ if ( $coords ) {
+ $attribs['coords'] = implode( ',', $coords );
+ }
+ if ( $alt != '' ) {
+ if ( $shape != 'default' ) {
+ $attribs['alt'] = $alt;
+ }
+ $attribs['title'] = $alt;
+ }
+ if ( $shape == 'default' ) {
+ $defaultLinkAttribs = $attribs;
+ } else {
+ $mapHTML .= Xml::element( 'area', $attribs ) . "\n";
+ }
+ if ( $externLink ) {
+ $extLinks[] = $title;
+ } else {
+ $links[] = $title;
+ }
+ }
+
+ if ( $first ) {
+ return self::error( 'imagemap_no_image' );
+ }
+
+ if ( $mapHTML == '' ) {
+ // no areas defined, default only. It's not a real imagemap, so we do not need some tags
+ $realmap = false;
+ }
+
+ if ( $realmap ) {
+ // Construct the map
+ // Add random number to avoid breaking cached HTML fragments that are
+ // later joined together on the one page (bug 16471)
+ $mapName = "ImageMap_" . ++self::$id . '_' . mt_rand( 0, 0x7fffffff );
+ $mapHTML = "<map name=\"$mapName\">\n$mapHTML</map>\n";
+
+ // Alter the image tag
+ $imageNode->setAttribute( 'usemap', "#$mapName" );
+ }
+
+ // Add a surrounding div, remove the default link to the description page
+ $anchor = $imageNode->parentNode;
+ $parent = $anchor->parentNode;
+ $div = $parent->insertBefore( new DOMElement( 'div' ), $anchor );
+ $div->setAttribute( 'class', 'noresize' );
+ if ( $defaultLinkAttribs ) {
+ $defaultAnchor = $div->appendChild( new DOMElement( 'a' ) );
+ foreach ( $defaultLinkAttribs as $name => $value ) {
+ $defaultAnchor->setAttribute( $name, $value );
+ }
+ $imageParent = $defaultAnchor;
+ } else {
+ $imageParent = $div;
+ }
+
+ // Add the map HTML to the div
+ // We used to add it before the div, but that made tidy unhappy
+ if ( $mapHTML != '' ) {
+ $mapDoc = new DOMDocument();
+ $mapDoc->loadXML( $mapHTML );
+ $mapNode = $domDoc->importNode( $mapDoc->documentElement, true );
+ $div->appendChild( $mapNode );
+ }
+
+ $imageParent->appendChild( $imageNode->cloneNode( true ) );
+ $parent->removeChild( $anchor );
+
+ // Determine whether a "magnify" link is present
+ $xpath = new DOMXPath( $domDoc );
+ $magnify = $xpath->query( '//div[@class="magnify"]' );
+ if ( !$magnify->length && $descType != self::NONE ) {
+ // Add image description link
+ if ( $descType == self::TOP_LEFT || $descType == self::BOTTOM_LEFT ) {
+ $marginLeft = 0;
+ } else {
+ $marginLeft = $thumbWidth - 20;
+ }
+ if ( $descType == self::TOP_LEFT || $descType == self::TOP_RIGHT ) {
+ $marginTop = -$thumbHeight;
+ // 1px hack for IE, to stop it poking out the top
+ $marginTop += 1;
+ } else {
+ $marginTop = -20;
+ }
+ $div->setAttribute( 'style', "height: {$thumbHeight}px; width: {$thumbWidth}px; " );
+ $descWrapper = $div->appendChild( new DOMElement( 'div' ) );
+ $descWrapper->setAttribute( 'style',
+ "margin-left: {$marginLeft}px; " .
+ "margin-top: {$marginTop}px; " .
+ "text-align: left;"
+ );
+
+ $descAnchor = $descWrapper->appendChild( new DOMElement( 'a' ) );
+ $descAnchor->setAttribute( 'href', $imageTitle->getLocalURL() );
+ $descAnchor->setAttribute(
+ 'title',
+ wfMessage( 'imagemap_description' )->inContentLanguage()->text()
+ );
+ $descImg = $descAnchor->appendChild( new DOMElement( 'img' ) );
+ $descImg->setAttribute(
+ 'alt',
+ wfMessage( 'imagemap_description' )->inContentLanguage()->text()
+ );
+ $url = $config->get( 'ExtensionAssetsPath' ) . '/ImageMap/desc-20.png';
+ $descImg->setAttribute(
+ 'src',
+ OutputPage::transformResourcePath( $config, $url )
+ );
+ $descImg->setAttribute( 'style', 'border: none;' );
+ }
+
+ // Output the result
+ // We use saveXML() not saveHTML() because then we get XHTML-compliant output.
+ // The disadvantage is that we have to strip out the DTD
+ $output = preg_replace( '/<\?xml[^?]*\?>/', '', $domDoc->saveXML( null, LIBXML_NOEMPTYTAG ) );
+
+ // Register links
+ foreach ( $links as $title ) {
+ if ( $title->isExternal() || $title->getNamespace() == NS_SPECIAL ) {
+ // Don't register special or interwiki links...
+ } elseif ( $title->getNamespace() == NS_MEDIA ) {
+ // Regular Media: links are recorded as image usages
+ $parser->mOutput->addImage( $title->getDBkey() );
+ } else {
+ // Plain ol' link
+ $parser->mOutput->addLink( $title );
+ }
+ }
+ foreach ( $extLinks as $title ) {
+ $parser->mOutput->addExternalLink( $title );
+ }
+ // Armour output against broken parser
+ $output = str_replace( "\n", '', $output );
+ return $output;
+ }
+
+ /**
+ * @param int $count
+ * @param int|string $lineNum
+ * @return array|string String with error (HTML), or array of coordinates
+ */
+ static function tokenizeCoords( $count, $lineNum ) {
+ $coords = [];
+ for ( $i = 0; $i < $count; $i++ ) {
+ $coord = strtok( " \t" );
+ if ( $coord === false ) {
+ return self::error( 'imagemap_missing_coord', $lineNum );
+ }
+ if ( !is_numeric( $coord ) || $coord > 1e9 || $coord < 0 ) {
+ return self::error( 'imagemap_invalid_coord', $lineNum );
+ }
+ $coords[$i] = $coord;
+ }
+ return $coords;
+ }
+
+ /**
+ * @param string $name
+ * @param string|int|bool $line
+ * @return string HTML
+ */
+ static function error( $name, $line = false ) {
+ return '<p class="error">' . wfMessage( $name, $line )->parse() . '</p>';
+ }
+}
diff --git a/www/wiki/extensions/ImageMap/tests/parser/imageMapParserTests.txt b/www/wiki/extensions/ImageMap/tests/parser/imageMapParserTests.txt
new file mode 100644
index 00000000..be49a286
--- /dev/null
+++ b/www/wiki/extensions/ImageMap/tests/parser/imageMapParserTests.txt
@@ -0,0 +1,10 @@
+!! test
+dummy test
+!! input
+<imagemap>
+Image:Foobar.jpg
+</imagemap>
+!! result
+<div class="noresize" style="height: 220px; width: 1941px; "><img alt="Foobar.jpg" src="http://example.com/images/3/3a/Foobar.jpg" width="1941" height="220"></img><div style="margin-left: 1921px; margin-top: -20px; text-align: left;"><a href="/wiki/File:Foobar.jpg" title="About this image"><img alt="About this image" src="/extensions/ImageMap/desc-20.png?15600" style="border: none;"></img></a></div></div>
+
+!! end
diff --git a/www/wiki/extensions/ImageMap/tests/phan/config.php b/www/wiki/extensions/ImageMap/tests/phan/config.php
new file mode 100644
index 00000000..db22766b
--- /dev/null
+++ b/www/wiki/extensions/ImageMap/tests/phan/config.php
@@ -0,0 +1,11 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+
+// Phan gets confused because DOMNode::setAttribute doesn't
+// exist, it's DOMElement::setAttribute, and some functions
+// are documented to return DOMNode but they actually return
+// DOMElement.
+$cfg['suppress_issue_types'][] = 'PhanUndeclaredMethod';
+
+return $cfg;
diff --git a/www/wiki/extensions/InputBox/composer.json b/www/wiki/extensions/InputBox/composer.json
index 021a14cb..b822010c 100644
--- a/www/wiki/extensions/InputBox/composer.json
+++ b/www/wiki/extensions/InputBox/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/InputBox/extension.json b/www/wiki/extensions/InputBox/extension.json
index 01ef0d73..f4cde3b6 100644
--- a/www/wiki/extensions/InputBox/extension.json
+++ b/www/wiki/extensions/InputBox/extension.json
@@ -10,6 +10,9 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:InputBox",
"descriptionmsg": "inputbox-desc",
+ "requires": {
+ "MediaWiki": ">= 1.30.0"
+ },
"license-name": "MIT",
"type": "parserhook",
"MessagesDirs": {
@@ -18,13 +21,12 @@
]
},
"AutoloadClasses": {
- "InputBoxHooks": "InputBox.hooks.php",
- "InputBox": "InputBox.classes.php"
+ "InputBoxHooks": "includes/InputBoxHooks.php",
+ "InputBox": "includes/InputBox.php"
},
"ResourceModules": {
"ext.inputBox.styles": {
"styles": "ext.inputBox.styles.css",
- "position": "top",
"targets": [
"mobile",
"desktop"
@@ -56,8 +58,5 @@
"InputBoxHooks::onSpecialPageBeforeExecute"
]
},
- "ParserTestFiles": [
- "tests/inputBoxParserTests.txt"
- ],
"manifest_version": 1
}
diff --git a/www/wiki/extensions/InputBox/i18n/ais.json b/www/wiki/extensions/InputBox/i18n/ais.json
index 5e93e5ec..40a5f332 100644
--- a/www/wiki/extensions/InputBox/i18n/ais.json
+++ b/www/wiki/extensions/InputBox/i18n/ais.json
@@ -5,10 +5,14 @@
"Benel"
]
},
+ "inputbox-desc": "kapah nicaliwan pataayaw misaheci tuway a HTML sapat nu sulit",
+ "inputbox-error-no-type": "caay henay kisu matuzu’ apatizengay a nikalahizaan nu sulitan nikatatapal.",
+ "inputbox-error-bad-type": "sulitan misabacu nikalahizaan \"$1\" mungangaw.\npisaungay \"create\", \"comment\", \"search\", \"search2\" saca \"fulltext\".",
"inputbox-tryexact": "nipitaneng caay ngangaw sasutili’ay",
"inputbox-searchfulltext": "mikilim tu hamin",
"inputbox-createarticle": "patizeng tu kasabelih",
"inputbox-movearticle": "milimad kasabelih",
"inputbox-postcomment": "baluhay a tusil",
+ "inputbox-postcommenttitle": "baluhay tusil",
"inputbox-ns-main": "angangan"
}
diff --git a/www/wiki/extensions/InputBox/i18n/bg.json b/www/wiki/extensions/InputBox/i18n/bg.json
index 7f6ea35b..80045416 100644
--- a/www/wiki/extensions/InputBox/i18n/bg.json
+++ b/www/wiki/extensions/InputBox/i18n/bg.json
@@ -3,10 +3,11 @@
"authors": [
"DCLXVI",
"Spiritia",
- "Vodnokon4e"
+ "Vodnokon4e",
+ "StanProg"
]
},
- "inputbox-desc": "Позволява вмъкването на HTML формуляри.",
+ "inputbox-desc": "Позволява вмъкването на HTML формуляри",
"inputbox-error-no-type": "Не се посочили типа на кутията за вход, която да бъде създадена.",
"inputbox-error-bad-type": "Неразпознат тип „$1“ на кутията за вход.\nНеобходимо е да се посочи „create“, „comment“, „search“, „search2“ или „fulltext“.",
"inputbox-tryexact": "Пълно и точно съвпадение",
diff --git a/www/wiki/extensions/InputBox/i18n/ckb.json b/www/wiki/extensions/InputBox/i18n/ckb.json
index 4fd88fd1..4c4bc2ae 100644
--- a/www/wiki/extensions/InputBox/i18n/ckb.json
+++ b/www/wiki/extensions/InputBox/i18n/ckb.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Calak",
- "Lost Whispers"
+ "Lost Whispers",
+ "Épine"
]
},
"inputbox-tryexact": "لێکچوونی تەواوەتی تاقی بکەرەوە",
diff --git a/www/wiki/extensions/InputBox/i18n/csb.json b/www/wiki/extensions/InputBox/i18n/csb.json
index cbdacf84..0a1293e1 100644
--- a/www/wiki/extensions/InputBox/i18n/csb.json
+++ b/www/wiki/extensions/InputBox/i18n/csb.json
@@ -1,8 +1,10 @@
{
"@metadata": {
"authors": [
- "Kaszeba"
+ "Kaszeba",
+ "Kirsan"
]
},
- "inputbox-tryexact": "Ùżëjë akùratnegò wësłowia"
+ "inputbox-tryexact": "Ùżëjë akùratnegò wësłowia",
+ "inputbox-createarticle": "Ùsadzë starnã"
}
diff --git a/www/wiki/extensions/InputBox/i18n/frp.json b/www/wiki/extensions/InputBox/i18n/frp.json
index 2d4297f6..2bde67a8 100644
--- a/www/wiki/extensions/InputBox/i18n/frp.json
+++ b/www/wiki/extensions/InputBox/i18n/frp.json
@@ -7,7 +7,7 @@
"inputbox-desc": "Pèrmèt l’encllusion de formulèros HTML prèdèfenis.",
"inputbox-error-no-type": "Vos éd pas spècefiâ lo tipo de la bouèta d’entrâ a fâre.",
"inputbox-error-bad-type": "Tipo de bouèta d’entrâ « $1 » pas recognu.\nVolyéd spècefiar un chouèx permié « create », « comment », « search », « searche2 » ou ben « fulltext ».",
- "inputbox-tryexact": "Èprovâd la corrèspondance ègzacta.",
+ "inputbox-tryexact": "Èprovâd la corrèspondence ègzacta.",
"inputbox-searchfulltext": "Rechèrche en tèxto complèt",
"inputbox-createarticle": "Fâre la pâge",
"inputbox-ns-main": "Principâl"
diff --git a/www/wiki/extensions/InputBox/i18n/gcr.json b/www/wiki/extensions/InputBox/i18n/gcr.json
new file mode 100644
index 00000000..18b1c800
--- /dev/null
+++ b/www/wiki/extensions/InputBox/i18n/gcr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "inputbox-tryexact": "Éséyé korèspondans ègzak-a"
+}
diff --git a/www/wiki/extensions/InputBox/i18n/id.json b/www/wiki/extensions/InputBox/i18n/id.json
index 9a7e6a61..73f450dc 100644
--- a/www/wiki/extensions/InputBox/i18n/id.json
+++ b/www/wiki/extensions/InputBox/i18n/id.json
@@ -4,7 +4,8 @@
"-iNu-",
"Aldnonymous",
"IvanLanin",
- "Rex"
+ "Rex",
+ "Gombang"
]
},
"inputbox-desc": "Memungkinkan penggunaan form HTML yang telah ditentukan",
@@ -13,5 +14,8 @@
"inputbox-tryexact": "Coba pencocokan eksak",
"inputbox-searchfulltext": "Cari di teks lengkap",
"inputbox-createarticle": "Buat halaman",
+ "inputbox-movearticle": "Pindahkan halaman",
+ "inputbox-postcomment": "Bagian baru",
+ "inputbox-postcommenttitle": "Bagian baru",
"inputbox-ns-main": "Utama"
}
diff --git a/www/wiki/extensions/InputBox/i18n/is.json b/www/wiki/extensions/InputBox/i18n/is.json
index 6f8e09d7..6a558194 100644
--- a/www/wiki/extensions/InputBox/i18n/is.json
+++ b/www/wiki/extensions/InputBox/i18n/is.json
@@ -2,12 +2,16 @@
"@metadata": {
"authors": [
"S.Örvarr.S",
- "Snævar"
+ "Snævar",
+ "Sveinn í Felli"
]
},
"inputbox-error-no-type": "Þú hefur ekki tilgreint hverskonar kassa þú villt búa til.",
"inputbox-error-bad-type": "\"$1\" gerð innsetningarkassa þekkist ekki.\nVinsamlegast tilgreindu \"create\", \"comment\", \"search\", \"search2\" eða \"fulltext\".",
"inputbox-tryexact": "Prófa nákvæma samsvörun.",
"inputbox-createarticle": "Búa til síðu",
+ "inputbox-movearticle": "Færa síðu",
+ "inputbox-postcomment": "Nýr hluti",
+ "inputbox-postcommenttitle": "Nýr hluti",
"inputbox-ns-main": "Aðalsíða"
}
diff --git a/www/wiki/extensions/InputBox/i18n/km.json b/www/wiki/extensions/InputBox/i18n/km.json
index 409ff15d..23d7f4e3 100644
--- a/www/wiki/extensions/InputBox/i18n/km.json
+++ b/www/wiki/extensions/InputBox/i18n/km.json
@@ -10,5 +10,9 @@
"inputbox-error-no-type": "អ្នកមិនទាន់បញ្ជាក់ប្រភេទប្រអប់បញ្ចូលដើម្បីបង្កើត។",
"inputbox-tryexact": "ស្វែងរកពាក្យត្រូវគ្នាទាំងស្រុង",
"inputbox-searchfulltext": "ស្វែងរកពាក្យពេញ",
- "inputbox-createarticle": "បង្កើតទំព័រ"
+ "inputbox-createarticle": "បង្កើតទំព័រ",
+ "inputbox-movearticle": "ប្តូរទីតាំងទំព័រ",
+ "inputbox-postcomment": "ផ្នែកថ្មី",
+ "inputbox-postcommenttitle": "ផ្នែកថ្មី",
+ "inputbox-ns-main": "ចម្បង​"
}
diff --git a/www/wiki/extensions/InputBox/i18n/kum.json b/www/wiki/extensions/InputBox/i18n/kum.json
new file mode 100644
index 00000000..8a6ac1be
--- /dev/null
+++ b/www/wiki/extensions/InputBox/i18n/kum.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arsenekoumyk"
+ ]
+ },
+ "inputbox-tryexact": "Мекенли излев"
+}
diff --git a/www/wiki/extensions/InputBox/i18n/mwl.json b/www/wiki/extensions/InputBox/i18n/mwl.json
new file mode 100644
index 00000000..32a66c02
--- /dev/null
+++ b/www/wiki/extensions/InputBox/i18n/mwl.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "inputbox-tryexact": "Tentar la spresson eisata"
+}
diff --git a/www/wiki/extensions/InputBox/i18n/nb.json b/www/wiki/extensions/InputBox/i18n/nb.json
index d7399981..91bf039e 100644
--- a/www/wiki/extensions/InputBox/i18n/nb.json
+++ b/www/wiki/extensions/InputBox/i18n/nb.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"EivindJ",
- "Danmichaelo"
+ "Danmichaelo",
+ "Jon Harald Søby"
]
},
"inputbox-desc": "Tillater inkludering av forhåndsdefinerte HTML-skjemaer",
diff --git a/www/wiki/extensions/InputBox/i18n/nys.json b/www/wiki/extensions/InputBox/i18n/nys.json
new file mode 100644
index 00000000..38e7b49a
--- /dev/null
+++ b/www/wiki/extensions/InputBox/i18n/nys.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "inputbox-tryexact": "Kuttock mokin mokin"
+}
diff --git a/www/wiki/extensions/InputBox/i18n/sat.json b/www/wiki/extensions/InputBox/i18n/sat.json
index 069eb9a8..7395a145 100644
--- a/www/wiki/extensions/InputBox/i18n/sat.json
+++ b/www/wiki/extensions/InputBox/i18n/sat.json
@@ -1,8 +1,9 @@
{
"@metadata": {
"authors": [
- "Albinus"
+ "Albinus",
+ "Manik Soren"
]
},
- "inputbox-tryexact": "Asol sakam milạo kurumuṭueme"
+ "inputbox-tryexact": "ᱡᱚᱛᱷᱟᱛ ᱢᱤᱞᱟᱹᱣ ᱠᱩᱨᱩᱢᱩᱴᱩᱭ ᱢᱮ"
}
diff --git a/www/wiki/extensions/InputBox/i18n/tay.json b/www/wiki/extensions/InputBox/i18n/tay.json
index 19f981d2..a086ecee 100644
--- a/www/wiki/extensions/InputBox/i18n/tay.json
+++ b/www/wiki/extensions/InputBox/i18n/tay.json
@@ -6,6 +6,9 @@
]
},
"inputbox-tryexact": "Tlamiy pspung kin ini’ ptkari’",
+ "inputbox-searchfulltext": "Inblaq mita’ kwara’ binrwan",
+ "inputbox-createarticle": "Ps’rux zzngayan",
+ "inputbox-movearticle": "Hzyaniy quw zngazyan",
"inputbox-postcomment": "New section",
"inputbox-ns-main": "Spzyang balay na zyuwaw"
}
diff --git a/www/wiki/extensions/InputBox/i18n/ur.json b/www/wiki/extensions/InputBox/i18n/ur.json
index 78f689a0..d4e372c5 100644
--- a/www/wiki/extensions/InputBox/i18n/ur.json
+++ b/www/wiki/extensions/InputBox/i18n/ur.json
@@ -2,11 +2,15 @@
"@metadata": {
"authors": [
"පසිඳු කාවින්ද",
- "عثمان خان شاہ"
+ "عثمان خان شاہ",
+ "BukhariSaeed"
]
},
"inputbox-tryexact": "خو بخو ٹیکسٹ کو ملانے کی کوشش کریں",
"inputbox-searchfulltext": "تلاش ِکل متن",
"inputbox-createarticle": "نیا مضمون",
+ "inputbox-movearticle": "منتقلئ صفحہ",
+ "inputbox-postcomment": "نیا قطعہ",
+ "inputbox-postcommenttitle": "نیا قطعہ",
"inputbox-ns-main": "مین"
}
diff --git a/www/wiki/extensions/InputBox/includes/InputBox.php b/www/wiki/extensions/InputBox/includes/InputBox.php
new file mode 100644
index 00000000..469ea24c
--- /dev/null
+++ b/www/wiki/extensions/InputBox/includes/InputBox.php
@@ -0,0 +1,729 @@
+<?php
+/**
+ * Classes for InputBox extension
+ *
+ * @file
+ * @ingroup Extensions
+ */
+
+/**
+ * InputBox class
+ */
+class InputBox {
+
+ /* Fields */
+
+ private $mParser;
+ private $mType = '';
+ private $mWidth = 50;
+ private $mPreload = null;
+ private $mPreloadparams = null;
+ private $mEditIntro = null;
+ private $mUseVE = null;
+ private $mSummary = null;
+ private $mNosummary = null;
+ private $mMinor = null;
+ private $mPage = '';
+ private $mBR = 'yes';
+ private $mDefaultText = '';
+ private $mPlaceholderText = '';
+ private $mBGColor = 'transparent';
+ private $mButtonLabel = '';
+ private $mSearchButtonLabel = '';
+ private $mFullTextButton = '';
+ private $mLabelText = '';
+ private $mHidden = '';
+ private $mNamespaces = '';
+ private $mID = '';
+ private $mInline = false;
+ private $mPrefix = '';
+ private $mDir = '';
+ private $mSearchFilter = '';
+ private $mTour = '';
+
+ /* Functions */
+
+ /**
+ * @param Parser $parser
+ */
+ public function __construct( $parser ) {
+ $this->mParser = $parser;
+ // Default value for dir taken from the page language (bug 37018)
+ $this->mDir = $this->mParser->getTargetLanguage()->getDir();
+ // Split caches by language, to make sure visitors do not see a cached
+ // version in a random language (since labels are in the user language)
+ $this->mParser->getOptions()->getUserLangObj();
+ $this->mParser->getOutput()->addModuleStyles( [
+ 'ext.inputBox.styles',
+ 'mediawiki.ui.input',
+ 'mediawiki.ui.checkbox',
+ ] );
+ }
+
+ public function render() {
+ // Handle various types
+ switch ( $this->mType ) {
+ case 'create':
+ case 'comment':
+ $this->mParser->getOutput()->addModules( 'ext.inputBox' );
+ return $this->getCreateForm();
+ case 'move':
+ return $this->getMoveForm();
+ case 'commenttitle':
+ return $this->getCommentForm();
+ case 'search':
+ return $this->getSearchForm( 'search' );
+ case 'fulltext':
+ return $this->getSearchForm( 'fulltext' );
+ case 'search2':
+ return $this->getSearchForm2();
+ default:
+ return Xml::tags( 'div', null,
+ Xml::element( 'strong',
+ [ 'class' => 'error' ],
+ strlen( $this->mType ) > 0
+ ? wfMessage( 'inputbox-error-bad-type', $this->mType )->text()
+ : wfMessage( 'inputbox-error-no-type' )->text()
+ )
+ );
+ }
+ }
+
+ /**
+ * Returns the action name and value to use in inputboxes which redirects to edit pages.
+ * Decides, if the link should redirect to VE edit page (veaction=edit) or to wikitext editor
+ * (action=edit).
+ *
+ * @return Array Array with name and value data
+ */
+ private function getEditActionArgs() {
+ // default is wikitext editor
+ $args = [
+ 'name' => 'action',
+ 'value' => 'edit',
+ ];
+ // check, if VE is installed and VE editor is requested
+ if ( $this->shouldUseVE() ) {
+ $args = [
+ 'name' => 'veaction',
+ 'value' => 'edit',
+ ];
+ }
+ return $args;
+ }
+
+ /**
+ * Get common classes, that could be added and depend on, if
+ * a line break between a button and an input field is added or not.
+ *
+ * @return String
+ */
+ private function getLinebreakClasses() {
+ return strtolower( $this->mBR ) === '<br />' ? 'mw-inputbox-input ' : '';
+ }
+
+ /**
+ * Generate search form
+ * @param string $type
+ * @return string HTML
+ */
+ public function getSearchForm( $type ) {
+ global $wgContLang, $wgNamespaceAliases;
+
+ // Use button label fallbacks
+ if ( !$this->mButtonLabel ) {
+ $this->mButtonLabel = wfMessage( 'inputbox-tryexact' )->text();
+ }
+ if ( !$this->mSearchButtonLabel ) {
+ $this->mSearchButtonLabel = wfMessage( 'inputbox-searchfulltext' )->text();
+ }
+ if ( $this->mID !== '' ) {
+ $idArray = [ 'id' => Sanitizer::escapeIdForAttribute( $this->mID ) ];
+ } else {
+ $idArray = [];
+ }
+ // We need a unqiue id to link <label> to checkboxes, but also
+ // want multiple <inputbox>'s to not be invalid html
+ $idRandStr = Sanitizer::escapeIdForAttribute( '-' . $this->mID . wfRandom() );
+
+ // Build HTML
+ $htmlOut = Xml::openElement( 'div',
+ [
+ 'class' => 'mw-inputbox-centered',
+ 'style' => $this->bgColorStyle(),
+ ]
+ );
+ $htmlOut .= Xml::openElement( 'form',
+ [
+ 'name' => 'searchbox',
+ 'class' => 'searchbox',
+ 'action' => SpecialPage::getTitleFor( 'Search' )->getLocalUrl(),
+ ] + $idArray
+ );
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'class' => $this->getLinebreakClasses() . 'searchboxInput mw-ui-input mw-ui-input-inline',
+ 'name' => 'search',
+ 'type' => $this->mHidden ? 'hidden' : 'text',
+ 'value' => $this->mDefaultText,
+ 'placeholder' => $this->mPlaceholderText,
+ 'size' => $this->mWidth,
+ 'dir' => $this->mDir,
+ ]
+ );
+
+ if ( $this->mPrefix != '' ) {
+ $htmlOut .= Html::hidden( 'prefix', $this->mPrefix );
+ }
+
+ if ( $this->mSearchFilter != '' ) {
+ $htmlOut .= Html::hidden( 'searchfilter', $this->mSearchFilter );
+ }
+
+ if ( $this->mTour != '' ) {
+ $htmlOut .= Html::hidden( 'tour', $this->mTour );
+ }
+
+ $htmlOut .= $this->mBR;
+
+ // Determine namespace checkboxes
+ $namespacesArray = explode( ',', $this->mNamespaces );
+ if ( $this->mNamespaces ) {
+ $namespaces = $wgContLang->getNamespaces();
+ $nsAliases = array_merge( $wgContLang->getNamespaceAliases(), $wgNamespaceAliases );
+ $showNamespaces = [];
+ $checkedNS = [];
+ // Check for valid namespaces
+ foreach ( $namespacesArray as $userNS ) {
+ $userNS = trim( $userNS ); // no whitespace
+
+ // Namespace needs to be checked if flagged with "**"
+ if ( strpos( $userNS, '**' ) ) {
+ $userNS = str_replace( '**', '', $userNS );
+ $checkedNS[$userNS] = true;
+ }
+
+ $mainMsg = wfMessage( 'inputbox-ns-main' )->inContentLanguage()->text();
+ if ( $userNS == 'Main' || $userNS == $mainMsg ) {
+ $i = 0;
+ } elseif ( array_search( $userNS, $namespaces ) ) {
+ $i = array_search( $userNS, $namespaces );
+ } elseif ( isset( $nsAliases[$userNS] ) ) {
+ $i = $nsAliases[$userNS];
+ } else {
+ continue; // Namespace not recognized, skip
+ }
+ $showNamespaces[$i] = $userNS;
+ if ( isset( $checkedNS[$userNS] ) && $checkedNS[$userNS] ) {
+ $checkedNS[$i] = true;
+ }
+ }
+
+ // Show valid namespaces
+ foreach ( $showNamespaces as $i => $name ) {
+ $checked = [];
+ // Namespace flagged with "**" or if it's the only one
+ if ( ( isset( $checkedNS[$i] ) && $checkedNS[$i] ) || count( $showNamespaces ) == 1 ) {
+ $checked = [ 'checked' => 'checked' ];
+ }
+
+ if ( count( $showNamespaces ) == 1 ) {
+ // Checkbox
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'type' => 'hidden',
+ 'name' => 'ns' . $i,
+ 'value' => 1,
+ 'id' => 'mw-inputbox-ns' . $i . $idRandStr
+ ] + $checked
+ );
+ } else {
+ // Checkbox
+ $htmlOut .= ' <div class="mw-inputbox-element mw-ui-checkbox">';
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'type' => 'checkbox',
+ 'name' => 'ns' . $i,
+ 'value' => 1,
+ 'id' => 'mw-inputbox-ns' . $i . $idRandStr
+ ] + $checked
+ );
+ // Label
+ $htmlOut .= Xml::label( $name, 'mw-inputbox-ns' . $i . $idRandStr );
+ $htmlOut .= '</div> ';
+ }
+ }
+
+ // Line break
+ $htmlOut .= $this->mBR;
+ } elseif ( $type == 'search' ) {
+ // Go button
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'type' => 'submit',
+ 'name' => 'go',
+ 'class' => 'mw-ui-button',
+ 'value' => $this->mButtonLabel
+ ]
+ );
+ $htmlOut .= '&#160;';
+ }
+
+ // Search button
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'type' => 'submit',
+ 'name' => 'fulltext',
+ 'class' => 'mw-ui-button',
+ 'value' => $this->mSearchButtonLabel
+ ]
+ );
+
+ // Hidden fulltext param for IE (bug 17161)
+ if ( $type == 'fulltext' ) {
+ $htmlOut .= Html::hidden( 'fulltext', 'Search' );
+ }
+
+ $htmlOut .= Xml::closeElement( 'form' );
+ $htmlOut .= Xml::closeElement( 'div' );
+
+ // Return HTML
+ return $htmlOut;
+ }
+
+ /**
+ * Generate search form version 2
+ * @return string
+ */
+ public function getSearchForm2() {
+ // Use button label fallbacks
+ if ( !$this->mButtonLabel ) {
+ $this->mButtonLabel = wfMessage( 'inputbox-tryexact' )->text();
+ }
+
+ if ( $this->mID !== '' ) {
+ $unescapedID = $this->mID;
+ } else {
+ // The label element needs a unique id, use
+ // random number to avoid multiple input boxes
+ // having conflicts.
+ $unescapedID = wfRandom();
+ }
+ $id = Sanitizer::escapeIdForAttribute( $unescapedID );
+ $htmlLabel = '';
+ if ( isset( $this->mLabelText ) && strlen( trim( $this->mLabelText ) ) ) {
+ $htmlLabel = Xml::openElement( 'label', [ 'for' => 'bodySearchInput' . $id ] );
+ $htmlLabel .= $this->mParser->recursiveTagParse( $this->mLabelText );
+ $htmlLabel .= Xml::closeElement( 'label' );
+ }
+ $htmlOut = Xml::openElement( 'form',
+ [
+ 'name' => 'bodySearch' . $id,
+ 'id' => 'bodySearch' . $id,
+ 'class' => 'bodySearch' . ( $this->mInline ? ' mw-inputbox-inline' : '' ),
+ 'action' => SpecialPage::getTitleFor( 'Search' )->getLocalUrl(),
+ ]
+ );
+ $htmlOut .= Xml::openElement( 'div',
+ [
+ 'class' => 'bodySearchWrap' . ( $this->mInline ? ' mw-inputbox-inline' : '' ),
+ 'style' => $this->bgColorStyle(),
+ ]
+ );
+ $htmlOut .= $htmlLabel;
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'type' => $this->mHidden ? 'hidden' : 'text',
+ 'name' => 'search',
+ 'class' => 'mw-ui-input mw-ui-input-inline',
+ 'size' => $this->mWidth,
+ 'id' => 'bodySearchInput' . $id,
+ 'dir' => $this->mDir,
+ ]
+ );
+ $htmlOut .= '&#160;' . Xml::element( 'input',
+ [
+ 'type' => 'submit',
+ 'name' => 'go',
+ 'value' => $this->mButtonLabel,
+ 'class' => 'mw-ui-button',
+ ]
+ );
+
+ // Better testing needed here!
+ if ( !empty( $this->mFullTextButton ) ) {
+ $htmlOut .= Xml::element( 'input',
+ [
+ 'type' => 'submit',
+ 'name' => 'fulltext',
+ 'class' => 'mw-ui-button',
+ 'value' => $this->mSearchButtonLabel
+ ]
+ );
+ }
+
+ $htmlOut .= Xml::closeElement( 'div' );
+ $htmlOut .= Xml::closeElement( 'form' );
+
+ // Return HTML
+ return $htmlOut;
+ }
+
+ /**
+ * Generate create page form
+ * @return string
+ */
+ public function getCreateForm() {
+ global $wgScript;
+
+ if ( $this->mType == "comment" ) {
+ if ( !$this->mButtonLabel ) {
+ $this->mButtonLabel = wfMessage( 'inputbox-postcomment' )->text();
+ }
+ } else {
+ if ( !$this->mButtonLabel ) {
+ $this->mButtonLabel = wfMessage( 'inputbox-createarticle' )->text();
+ }
+ }
+
+ $htmlOut = Xml::openElement( 'div',
+ [
+ 'class' => 'mw-inputbox-centered',
+ 'style' => $this->bgColorStyle(),
+ ]
+ );
+ $createBoxParams = [
+ 'name' => 'createbox',
+ 'class' => 'createbox',
+ 'action' => $wgScript,
+ 'method' => 'get'
+ ];
+ if ( $this->mID !== '' ) {
+ $createBoxParams['id'] = Sanitizer::escapeIdForAttribute( $this->mID );
+ }
+ $htmlOut .= Xml::openElement( 'form', $createBoxParams );
+ $editArgs = $this->getEditActionArgs();
+ $htmlOut .= Html::hidden( $editArgs['name'], $editArgs['value'] );
+ if ( $this->mPreload !== null ) {
+ $htmlOut .= Html::hidden( 'preload', $this->mPreload );
+ }
+ if ( is_array( $this->mPreloadparams ) ) {
+ foreach ( $this->mPreloadparams as $preloadparams ) {
+ $htmlOut .= Html::hidden( 'preloadparams[]', $preloadparams );
+ }
+ }
+ if ( $this->mEditIntro !== null ) {
+ $htmlOut .= Html::hidden( 'editintro', $this->mEditIntro );
+ }
+ if ( $this->mSummary !== null ) {
+ $htmlOut .= Html::hidden( 'summary', $this->mSummary );
+ }
+ if ( $this->mNosummary !== null ) {
+ $htmlOut .= Html::hidden( 'nosummary', $this->mNosummary );
+ }
+ if ( $this->mPrefix !== '' ) {
+ $htmlOut .= Html::hidden( 'prefix', $this->mPrefix );
+ }
+ if ( $this->mMinor !== null ) {
+ $htmlOut .= Html::hidden( 'minor', $this->mMinor );
+ }
+ if ( $this->mType == 'comment' ) {
+ $htmlOut .= Html::hidden( 'section', 'new' );
+ }
+ $htmlOut .= Xml::openElement( 'input',
+ [
+ 'type' => $this->mHidden ? 'hidden' : 'text',
+ 'name' => 'title',
+ 'class' => $this->getLinebreakClasses() .
+ 'mw-ui-input mw-ui-input-inline createboxInput',
+ 'value' => $this->mDefaultText,
+ 'placeholder' => $this->mPlaceholderText,
+ 'size' => $this->mWidth,
+ 'dir' => $this->mDir,
+ ]
+ );
+ $htmlOut .= $this->mBR;
+ $htmlOut .= Xml::openElement( 'input',
+ [
+ 'type' => 'submit',
+ 'name' => 'create',
+ 'class' => 'mw-ui-button mw-ui-progressive createboxButton',
+ 'value' => $this->mButtonLabel
+ ]
+ );
+ $htmlOut .= Xml::closeElement( 'form' );
+ $htmlOut .= Xml::closeElement( 'div' );
+
+ // Return HTML
+ return $htmlOut;
+ }
+
+ /**
+ * Generate move page form
+ * @return string
+ */
+ public function getMoveForm() {
+ global $wgScript;
+
+ if ( !$this->mButtonLabel ) {
+ $this->mButtonLabel = wfMessage( 'inputbox-movearticle' )->text();
+ }
+
+ $htmlOut = Xml::openElement( 'div',
+ [
+ 'class' => 'mw-inputbox-centered',
+ 'style' => $this->bgColorStyle(),
+ ]
+ );
+ $moveBoxParams = [
+ 'name' => 'movebox',
+ 'class' => 'mw-movebox',
+ 'action' => $wgScript,
+ 'method' => 'get'
+ ];
+ if ( $this->mID !== '' ) {
+ $moveBoxParams['id'] = Sanitizer::escapeIdForAttribute( $this->mID );
+ }
+ $htmlOut .= Xml::openElement( 'form', $moveBoxParams );
+ $htmlOut .= Html::hidden( 'title',
+ SpecialPage::getTitleFor( 'Movepage', $this->mPage )->getPrefixedText() );
+ $htmlOut .= Html::hidden( 'wpReason', $this->mSummary );
+ $htmlOut .= Html::hidden( 'prefix', $this->mPrefix );
+ $htmlOut .= Xml::openElement( 'input',
+ [
+ 'type' => $this->mHidden ? 'hidden' : 'text',
+ 'name' => 'wpNewTitle',
+ 'class' => $this->getLinebreakClasses() . 'mw-moveboxInput mw-ui-input mw-ui-input-inline',
+ 'value' => $this->mDefaultText,
+ 'placeholder' => $this->mPlaceholderText,
+ 'size' => $this->mWidth,
+ 'dir' => $this->mDir,
+ ]
+ );
+ $htmlOut .= $this->mBR;
+ $htmlOut .= Xml::openElement( 'input',
+ [
+ 'type' => 'submit',
+ 'class' => 'mw-ui-button mw-ui-progressive',
+ 'value' => $this->mButtonLabel
+ ]
+ );
+ $htmlOut .= Xml::closeElement( 'form' );
+ $htmlOut .= Xml::closeElement( 'div' );
+
+ // Return HTML
+ return $htmlOut;
+ }
+
+ /**
+ * Generate new section form
+ * @return string
+ */
+ public function getCommentForm() {
+ global $wgScript;
+
+ if ( !$this->mButtonLabel ) {
+ $this->mButtonLabel = wfMessage( 'inputbox-postcommenttitle' )->text();
+ }
+
+ $htmlOut = Xml::openElement( 'div',
+ [
+ 'class' => 'mw-inputbox-centered',
+ 'style' => $this->bgColorStyle(),
+ ]
+ );
+ $commentFormParams = [
+ 'name' => 'commentbox',
+ 'class' => 'commentbox',
+ 'action' => $wgScript,
+ 'method' => 'get'
+ ];
+ if ( $this->mID !== '' ) {
+ $commentFormParams['id'] = Sanitizer::escapeIdForAttribute( $this->mID );
+ }
+ $htmlOut .= Xml::openElement( 'form', $commentFormParams );
+ $editArgs = $this->getEditActionArgs();
+ $htmlOut .= Html::hidden( $editArgs['name'], $editArgs['value'] );
+ if ( $this->mPreload !== null ) {
+ $htmlOut .= Html::hidden( 'preload', $this->mPreload );
+ }
+ if ( is_array( $this->mPreloadparams ) ) {
+ foreach ( $this->mPreloadparams as $preloadparams ) {
+ $htmlOut .= Html::hidden( 'preloadparams[]', $preloadparams );
+ }
+ }
+ if ( $this->mEditIntro !== null ) {
+ $htmlOut .= Html::hidden( 'editintro', $this->mEditIntro );
+ }
+ $htmlOut .= Xml::openElement( 'input',
+ [
+ 'type' => $this->mHidden ? 'hidden' : 'text',
+ 'name' => 'preloadtitle',
+ 'class' => $this->getLinebreakClasses() . 'commentboxInput mw-ui-input mw-ui-input-inline',
+ 'value' => $this->mDefaultText,
+ 'placeholder' => $this->mPlaceholderText,
+ 'size' => $this->mWidth,
+ 'dir' => $this->mDir,
+ ]
+ );
+ $htmlOut .= Html::hidden( 'section', 'new' );
+ $htmlOut .= Html::hidden( 'title', $this->mPage );
+ $htmlOut .= $this->mBR;
+ $htmlOut .= Xml::openElement( 'input',
+ [
+ 'type' => 'submit',
+ 'name' => 'create',
+ 'class' => 'mw-ui-button mw-ui-progressive',
+ 'value' => $this->mButtonLabel
+ ]
+ );
+ $htmlOut .= Xml::closeElement( 'form' );
+ $htmlOut .= Xml::closeElement( 'div' );
+
+ // Return HTML
+ return $htmlOut;
+ }
+
+ /**
+ * Extract options from a blob of text
+ *
+ * @param string $text Tag contents
+ */
+ public function extractOptions( $text ) {
+ // Parse all possible options
+ $values = [];
+ foreach ( explode( "\n", $text ) as $line ) {
+ if ( strpos( $line, '=' ) === false ) {
+ continue;
+ }
+ list( $name, $value ) = explode( '=', $line, 2 );
+ $name = strtolower( trim( $name ) );
+ $value = Sanitizer::decodeCharReferences( trim( $value ) );
+ if ( $name == 'preloadparams[]' ) {
+ // We have to special-case this one because it's valid for it to appear more than once.
+ $this->mPreloadparams[] = $value;
+ } else {
+ $values[ $name ] = $value;
+ }
+ }
+
+ // Validate the dir value.
+ if ( isset( $values['dir'] ) && !in_array( $values['dir'], [ 'ltr', 'rtl' ] ) ) {
+ unset( $values['dir'] );
+ }
+
+ // Build list of options, with local member names
+ $options = [
+ 'type' => 'mType',
+ 'width' => 'mWidth',
+ 'preload' => 'mPreload',
+ 'page' => 'mPage',
+ 'editintro' => 'mEditIntro',
+ 'useve' => 'mUseVE',
+ 'summary' => 'mSummary',
+ 'nosummary' => 'mNosummary',
+ 'minor' => 'mMinor',
+ 'break' => 'mBR',
+ 'default' => 'mDefaultText',
+ 'placeholder' => 'mPlaceholderText',
+ 'bgcolor' => 'mBGColor',
+ 'buttonlabel' => 'mButtonLabel',
+ 'searchbuttonlabel' => 'mSearchButtonLabel',
+ 'fulltextbutton' => 'mFullTextButton',
+ 'namespaces' => 'mNamespaces',
+ 'labeltext' => 'mLabelText',
+ 'hidden' => 'mHidden',
+ 'id' => 'mID',
+ 'inline' => 'mInline',
+ 'prefix' => 'mPrefix',
+ 'dir' => 'mDir',
+ 'searchfilter' => 'mSearchFilter',
+ 'tour' => 'mTour'
+ ];
+ // Options we should maybe run through lang converter.
+ $convertOptions = [
+ 'default' => true,
+ 'buttonlabel' => true,
+ 'searchbuttonlabel' => true,
+ 'placeholder' => true
+ ];
+ foreach ( $options as $name => $var ) {
+ if ( isset( $values[$name] ) ) {
+ $this->$var = $values[$name];
+ if ( isset( $convertOptions[$name] ) ) {
+ $this->$var = $this->languageConvert( $this->$var );
+ }
+ }
+ }
+
+ // Insert a line break if configured to do so
+ $this->mBR = ( strtolower( $this->mBR ) == "no" ) ? ' ' : '<br />';
+
+ // Validate the width; make sure it's a valid, positive integer
+ $this->mWidth = intval( $this->mWidth <= 0 ? 50 : $this->mWidth );
+
+ // Validate background color
+ if ( !$this->isValidColor( $this->mBGColor ) ) {
+ $this->mBGColor = 'transparent';
+ }
+ }
+
+ /**
+ * Do a security check on the bgcolor parameter
+ * @param string $color
+ * @return bool
+ */
+ public function isValidColor( $color ) {
+ $regex = <<<REGEX
+ /^ (
+ [a-zA-Z]* | # color names
+ \# [0-9a-f]{3} | # short hexadecimal
+ \# [0-9a-f]{6} | # long hexadecimal
+ rgb \s* \( \s* (
+ \d+ \s* , \s* \d+ \s* , \s* \d+ | # rgb integer
+ [0-9.]+% \s* , \s* [0-9.]+% \s* , \s* [0-9.]+% # rgb percent
+ ) \s* \)
+ ) $ /xi
+REGEX;
+ return (bool)preg_match( $regex, $color );
+ }
+
+ private function bgColorStyle() {
+ if ( $this->mBGColor != 'transparent' ) {
+ return 'background-color: ' . $this->mBGColor . ';';
+ }
+ return '';
+ }
+
+ /**
+ * Returns true, if the VisualEditor is requested from the inputbox wikitext definition and
+ * if the VisualEditor extension is actually installed or not, false otherwise.
+ *
+ * @return bool
+ */
+ private function shouldUseVE() {
+ return ExtensionRegistry::getInstance()->isLoaded( 'VisualEditor' ) && $this->mUseVE !== null;
+ }
+
+ /**
+ * For compatability with pre T119158 behaviour
+ *
+ * If a field that is going to be used as an attribute
+ * and it contains "-{" in it, run it through language
+ * converter.
+ *
+ * Its not really clear if it would make more sense to
+ * always convert instead of only if -{ is present. This
+ * function just more or less restores the previous
+ * accidental behaviour.
+ *
+ * @see https://phabricator.wikimedia.org/T180485
+ */
+ private function languageConvert( $text ) {
+ $lang = $this->mParser->getConverterLanguage();
+ if ( $lang->hasVariants() && strpos( $text, '-{' ) !== false ) {
+ $text = $lang->convert( $text );
+ }
+ return $text;
+ }
+}
diff --git a/www/wiki/extensions/InputBox/includes/InputBoxHooks.php b/www/wiki/extensions/InputBox/includes/InputBoxHooks.php
new file mode 100644
index 00000000..75b01464
--- /dev/null
+++ b/www/wiki/extensions/InputBox/includes/InputBoxHooks.php
@@ -0,0 +1,108 @@
+<?php
+/**
+ * Hooks for InputBox extension
+ *
+ * @file
+ * @ingroup Extensions
+ */
+
+/**
+ * InputBox hooks
+ */
+class InputBoxHooks {
+
+ /**
+ * Initialization
+ * @param Parser &$parser
+ * @return true
+ */
+ public static function register( Parser &$parser ) {
+ // Register the hook with the parser
+ $parser->setHook( 'inputbox', [ 'InputBoxHooks', 'render' ] );
+
+ // Continue
+ return true;
+ }
+
+ /**
+ * Prepend prefix to wpNewTitle if necessary
+ * @param SpecialPage $special
+ * @param string $subPage
+ * @return true
+ */
+ public static function onSpecialPageBeforeExecute( $special, $subPage ) {
+ $request = $special->getRequest();
+ $prefix = $request->getText( 'prefix', '' );
+ $title = $request->getText( 'wpNewTitle', '' );
+ $search = $request->getText( 'search', '' );
+ $searchfilter = $request->getText( 'searchfilter', '' );
+ if ( $special->getName() == 'Movepage' && $prefix !== '' && $title !== '' ) {
+ $request->setVal( 'wpNewTitle', $prefix . $title );
+ $request->unsetVal( 'prefix' );
+ }
+ if ( $special->getName() == 'Search' && $searchfilter !== '' ) {
+ $request->setVal( 'search', $search . ' ' . $searchfilter );
+ }
+ return true;
+ }
+
+ /**
+ * Render the input box
+ * @param string $input
+ * @param array $args
+ * @param Parser $parser
+ * @return string
+ */
+ public static function render( $input, $args, Parser $parser ) {
+ // Create InputBox
+ $inputBox = new InputBox( $parser );
+
+ // Configure InputBox
+ $inputBox->extractOptions( $parser->replaceVariables( $input ) );
+
+ // Return output
+ return $inputBox->render();
+ }
+
+ /**
+ * <inputbox type=create...> sends requests with action=edit, and
+ * possibly a &prefix=Foo. So we pick that up here, munge prefix
+ * and title together, and redirect back out to the real page
+ * @param OutputPage $output
+ * @param Article $article
+ * @param Title $title
+ * @param User $user
+ * @param WebRequest $request
+ * @param MediaWiki $wiki
+ * @return bool
+ */
+ public static function onMediaWikiPerformAction(
+ $output,
+ $article,
+ $title,
+ $user,
+ $request,
+ $wiki
+ ) {
+ if ( $wiki->getAction() !== 'edit' && $request->getText( 'veaction' ) !== 'edit' ) {
+ // not our problem
+ return true;
+ }
+ if ( $request->getText( 'prefix', '' ) === '' ) {
+ // Fine
+ return true;
+ }
+
+ $params = $request->getValues();
+ $title = $params['prefix'];
+ if ( isset( $params['title'] ) ) {
+ $title .= $params['title'];
+ }
+ unset( $params['prefix'] );
+ $params['title'] = $title;
+
+ global $wgScript;
+ $output->redirect( wfAppendQuery( $wgScript, $params ), '301' );
+ return false;
+ }
+}
diff --git a/www/wiki/extensions/InputBox/tests/parser/inputBoxParserTests.txt b/www/wiki/extensions/InputBox/tests/parser/inputBoxParserTests.txt
new file mode 100644
index 00000000..0f205670
--- /dev/null
+++ b/www/wiki/extensions/InputBox/tests/parser/inputBoxParserTests.txt
@@ -0,0 +1,240 @@
+!! test
+InputBox type=search
+!! wikitext
+<inputbox>
+type=search
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="searchbox" class="searchbox" action="/wiki/Special:Search"><input class="mw-inputbox-input searchboxInput mw-ui-input mw-ui-input-inline" name="search" type="text" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="go" class="mw-ui-button" value="Try exact match" />&#160;<input type="submit" name="fulltext" class="mw-ui-button" value="Search full text" /></form></div>
+!! end
+
+!! test
+InputBox type=create
+!! wikitext
+<inputbox>
+type=create
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with minor
+!! wikitext
+<inputbox>
+type=create
+minor=1
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="1" name="minor" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with minor=0
+!! wikitext
+<inputbox>
+type=create
+minor=0
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="0" name="minor" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with preloadparams
+!! wikitext
+<inputbox>
+type=create
+preloadparams[]=param1
+preloadparams[]=param2
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="param1" name="preloadparams[]" /><input type="hidden" value="param2" name="preloadparams[]" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with empty preloadparams
+!! wikitext
+<inputbox>
+type=create
+preloadparams[]=
+preloadparams[]=
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" name="preloadparams[]" /><input type="hidden" name="preloadparams[]" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with editintro
+!! wikitext
+<inputbox>
+type=create
+editintro=MediaWiki:Test
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="MediaWiki:Test" name="editintro" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with empty editintro
+!! wikitext
+<inputbox>
+type=create
+editintro=
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" name="editintro" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with summary
+!! wikitext
+<inputbox>
+type=create
+summary=Summary test
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="Summary test" name="summary" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with empty summary
+!! wikitext
+<inputbox>
+type=create
+summary=
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" name="summary" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with nosummary
+!! wikitext
+<inputbox>
+type=create
+nosummary=true
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="true" name="nosummary" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with empty nosummary
+!! wikitext
+<inputbox>
+type=create
+nosummary=
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" name="nosummary" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with prefix
+!! wikitext
+<inputbox>
+type=create
+prefix=Test/
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="Test/" name="prefix" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with empty prefix
+!! wikitext
+<inputbox>
+type=create
+prefix=
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with preload
+!! wikitext
+<inputbox>
+type=create
+preload=test
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="test" name="preload" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=create with empty preload
+!! wikitext
+<inputbox>
+type=create
+preload=
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" name="preload" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Create page" /></form></div>
+!! end
+
+!! test
+InputBox type=comment
+!! wikitext
+<inputbox>
+type=comment
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="hidden" value="new" name="section" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="New section" /></form></div>
+!! end
+
+!! test
+InputBox type=commenttitle
+!! wikitext
+<inputbox>
+type=commenttitle
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="commentbox" class="commentbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="text" name="preloadtitle" class="mw-inputbox-input commentboxInput mw-ui-input mw-ui-input-inline" value="" placeholder="" size="50" dir="ltr" /><input type="hidden" value="new" name="section" /><input type="hidden" name="title" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive" value="New section" /></form></div>
+!! end
+
+!! test
+InputBox type=fulltext
+!! wikitext
+<inputbox>
+type=fulltext
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="searchbox" class="searchbox" action="/wiki/Special:Search"><input class="mw-inputbox-input searchboxInput mw-ui-input mw-ui-input-inline" name="search" type="text" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" name="fulltext" class="mw-ui-button" value="Search full text" /><input type="hidden" value="Search" name="fulltext" /></form></div>
+!! end
+
+!! test
+InputBox type=move
+!! wikitext
+<inputbox>
+type=move
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="movebox" class="mw-movebox" action="/index.php" method="get"><input type="hidden" value="Special:MovePage/" name="title" /><input type="hidden" name="wpReason" /><input type="hidden" name="prefix" /><input type="text" name="wpNewTitle" class="mw-inputbox-input mw-moveboxInput mw-ui-input mw-ui-input-inline" value="" placeholder="" size="50" dir="ltr" /><br /><input type="submit" class="mw-ui-button mw-ui-progressive" value="Move page" /></form></div>
+!! end
+
+!! test
+InputBox type=search with tour
+!! wikitext
+<inputbox>
+type=search
+tour=test
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="searchbox" class="searchbox" action="/wiki/Special:Search"><input class="mw-inputbox-input searchboxInput mw-ui-input mw-ui-input-inline" name="search" type="text" value="" placeholder="" size="50" dir="ltr" /><input type="hidden" value="test" name="tour" /><br /><input type="submit" name="go" class="mw-ui-button" value="Try exact match" />&#160;<input type="submit" name="fulltext" class="mw-ui-button" value="Search full text" /></form></div>
+!! end
+
+!! test
+InputBox langconvert
+!! options
+language=sr variant=sr-el
+!! wikitext
+<inputbox>
+type=create
+default=-{sr-el: Some latin; sr-ec: Not latin }-
+placeholder=-{sr-el: el; sr-ec: ec}-
+</inputbox>
+!! html+tidy
+<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input type="text" name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline createboxInput" value="Some latin" placeholder="el" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive createboxButton" value="Направи страницу" /></form></div>
+!! end
diff --git a/www/wiki/extensions/InputBox/tests/phan/config.php b/www/wiki/extensions/InputBox/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/InputBox/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/Interwiki/Interwiki.css b/www/wiki/extensions/Interwiki/Interwiki.css
index e0d46257..eb7a53ab 100644
--- a/www/wiki/extensions/Interwiki/Interwiki.css
+++ b/www/wiki/extensions/Interwiki/Interwiki.css
@@ -43,7 +43,9 @@ input#mw-interwiki-url {
.mw-interwiki-legend .mw-collapsible-toggle {
font-weight: normal;
}
-table.mw-interwiki-legend {
+
+/* Selector with higher specifity than wikitable */
+table.wikitable.mw-interwiki-legend {
margin-top: 2em;
}
diff --git a/www/wiki/extensions/Interwiki/composer.json b/www/wiki/extensions/Interwiki/composer.json
index 7c63cad5..afa0dc78 100644
--- a/www/wiki/extensions/Interwiki/composer.json
+++ b/www/wiki/extensions/Interwiki/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
- "parallel-lint . --exclude vendor",
- "phpcs -p -s"
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/Interwiki/extension.json b/www/wiki/extensions/Interwiki/extension.json
index afc108ed..733fbff5 100644
--- a/www/wiki/extensions/Interwiki/extension.json
+++ b/www/wiki/extensions/Interwiki/extension.json
@@ -15,7 +15,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:Interwiki",
"descriptionmsg": "interwiki-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "specialpage",
"requires": {
"MediaWiki": ">= 1.26.0"
@@ -39,10 +39,7 @@
},
"ResourceModules": {
"ext.interwiki.specialpage": {
- "styles": "Interwiki.css",
- "dependencies": [
- "jquery.makeCollapsible"
- ]
+ "styles": "Interwiki.css"
}
},
"ResourceFileModulePaths": {
@@ -56,9 +53,9 @@
"InterwikiHooks::onExtensionFunctions"
],
"AutoloadClasses": {
- "InterwikiHooks": "Interwiki_hooks.php",
- "SpecialInterwiki": "Interwiki_body.php",
- "InterwikiLogFormatter": "Interwiki_body.php"
+ "InterwikiHooks": "includes/InterwikiHooks.php",
+ "SpecialInterwiki": "includes/SpecialInterwiki.php",
+ "InterwikiLogFormatter": "includes/InterwikiLogFormatter.php"
},
"manifest_version": 1
}
diff --git a/www/wiki/extensions/Interwiki/i18n/ar.json b/www/wiki/extensions/Interwiki/i18n/ar.json
index 7a9099cf..db7176ca 100644
--- a/www/wiki/extensions/Interwiki/i18n/ar.json
+++ b/www/wiki/extensions/Interwiki/i18n/ar.json
@@ -10,7 +10,8 @@
"interwiki": "عرض وتعديل بيانات الإنترويكي",
"interwiki-title-norights": "عرض بيانات الإنترويكي",
"interwiki-desc": "يضيف [[Special:Interwiki|صفحة خاصة]] لرؤية وتعديل جدول الإنترويكي",
- "interwiki_intro": "هذا عرض عام لجدول الإنترويكي. معاني البيانات في العواميد:",
+ "interwiki_intro": "هذه نظرة عامة على جدول الإنترويكي، الذي يعرِّف اختصارات البادئة المستخدمة للربط بسرعة بمختلف مواقع الويكي والمواقع الخارجية الأخرى، للاستعمال الموصى به; يُرجَى الاطلاع على [//www.mediawiki.org/wiki/Extension:Interwiki دليل المستخدم في MediaWiki.org].",
+ "interwiki-legend-label": "العنوان التفسيري",
"interwiki_prefix": "بادئة",
"interwiki-prefix-label": "البادئة:",
"interwiki_prefix_intro": "بادئة الإنترويكي ليتم استخدامها في صياغة نص الويكي <code>[<nowiki />[prefix:<em>pagename</em>]]</code>.",
@@ -23,18 +24,21 @@
"interwiki_local_1_intro": "يتم التحويل للمسار الهدف المعطى في تعريفات وصلة الإنترويكي (أي تتم معاملتها مثل المراجع في الصفحات المحلية)",
"interwiki_trans": "تضمين",
"interwiki-trans-label": "تضمين:",
- "interwiki_trans_1_intro": "يسمح بالتضمين من الويكي الأجنبي، لو أن تضمينات الإنترويكي مسموح بها عموما في هذا الويكي،",
+ "interwiki_trans_1_intro": "إذا تم استخدام صيغة نص الويكي <code>{<nowiki />{prefix:<em>pagename</em>}}</code> ، ستسمح بتضمين قالب/صفحة من الويكيات الأجنبية إذا تم تمكين تضمينات الإنترويكي بشكل عام ([//www.mediawiki.org/wiki/Manual:$wgEnableScaryTranscluding scary transclusion]).",
"interwiki_trans_0_intro": "لا تسمح ل<code>{<nowiki />{prefix:<em>pagename</em>}}</code> بتضمين قوالب/صفحات أجنبية، بل ابحث عن صفحة محلية في نطاق القوالب.",
"interwiki_1": "نعم",
"interwiki_0": "لا",
"interwiki_error": "خطأ: جدول الإنترويكي فارغ، أو حدث خطأ آخر.",
+ "interwiki-cached": "يتم تخزين بيانات الإنترويكي مؤقتا، تعديل ذاكرة التخزين المؤقت غير ممكن.",
"interwiki_edit": "عدل",
"interwiki_reasonfield": "السبب:",
"interwiki_delquestion": "حذف \"$1\"",
"interwiki_deleting": "أنت تحذف البادئة \"$1\".",
"interwiki_deleted": "تمت إزالة البادئة \"$1\" من جدول الإنترويكي.",
"interwiki_delfailed": "البادئة \"$1\" لم يمكن إزالتها من جدول الإنترويكي.",
+ "interwiki-logtext": "عرض السجل",
"interwiki_addtext": "أضف بادئة إنترويكي أو لغة",
+ "interwiki-addtext-local": "أضف بادئة إنترويكي أو لغة محلية",
"interwiki_addintro": "أنت تضيف بادئة إنترويكي جديدة.\nتذكر أنها لا يمكن أن تحتوي على مسافات ( )، نقطتين فوق بعض (:)، علامة و (&)، أو علامة يساوي (=).",
"interwiki_addbutton": "أضف",
"interwiki_added": "تمت إضافة البادئة \"$1\" إلى جدول الإنترويكي.",
@@ -44,8 +48,20 @@
"interwiki_edited": "تم تعديل البادئة \"$1\" في جدول الإنترويكي.",
"interwiki_editerror": "البادئة \"$1\" لم يمكن تعديلها في جدول الإنترويكي.\nمن المحتمل أنها غير موجودة.",
"interwiki-badprefix": "بادئة إنترويكي محددة \"$1\" تحتوي أحرفا غير صحيحة",
+ "interwiki-submit-empty": "لا يمكن أن تكون البادئة والمسار فارغين.",
+ "interwiki-submit-invalidurl": "بروتوكول المسار غير صالح.",
"log-name-interwiki": "سجل جدول الإنترويكي",
+ "logentry-interwiki-iw_add": "$1 {{GENDER:$2|أصاف|أصافت}} البادئة \"$4\" ($5) (التضمين: $6; المحلي: $7) إلى جدول الإنترويكي",
+ "logentry-interwiki-iw_edit": "$1 {{GENDER:$2|عدل|عدلت}} البادئة \"$4\" ($5) (التضمين: $6; المحلي: $7) في جدول الإنترويكي",
+ "logentry-interwiki-iw_delete": "$1 {{GENDER:$2|أزال|أزالت}} البادئة \"$4\" من جدول الإنترويكي",
"log-description-interwiki": "هذا سجل بالتغييرات في [[Special:Interwiki|جدول الإنترويكي]].",
"right-interwiki": "تعديل بيانات الإنترويكي",
- "action-interwiki": "تغيير مدخلة الإنترويكي هذه"
+ "action-interwiki": "تغيير مدخلة الإنترويكي هذه",
+ "interwiki-global-links": "بادئات الإنترويكي العالمية",
+ "interwiki-global-description": "هذه البادئات موروثة من تكوين عالمي، ولا يمكن تحريرها إلا في الويكي المصدر.",
+ "interwiki-local-links": "بادئات الإنترويكي المحلية",
+ "interwiki-local-description": "هذه البادئات موجودة محليا; أي تكرار مع التكوين العالمي سيتجاوز التعريف العالمي.",
+ "interwiki-links": "بادئات الإنترويكي",
+ "interwiki-language-links": "البادئات بين اللغات",
+ "interwiki-language-description": "تتطابق هذه البادئات مع رموز اللغة المحددة، وسيتم استخدامها لإنشاء قائمة \"{{int: otherlanguages}}\" عند إضافتها إلى الصفحة."
}
diff --git a/www/wiki/extensions/Interwiki/i18n/ast.json b/www/wiki/extensions/Interwiki/i18n/ast.json
index 224147da..a4088416 100644
--- a/www/wiki/extensions/Interwiki/i18n/ast.json
+++ b/www/wiki/extensions/Interwiki/i18n/ast.json
@@ -29,18 +29,18 @@
"interwiki_reasonfield": "Motivu:",
"interwiki_delquestion": "Desaniciando «$1»",
"interwiki_deleting": "Tas desaniciando'l prefixu «$1».",
- "interwiki_deleted": "El prefixu «$1» se desanició correutamente de la tabla d'interwiki.",
+ "interwiki_deleted": "El prefixu «$1» desanicióse de la tabla d'interwikis.",
"interwiki_delfailed": "El prefixu «$1» nun se pudo desaniciar de la tabla d'interwiki.",
"interwiki-logtext": "Ver el rexistru",
"interwiki_addtext": "Amestar un prefixu interwiki o de llingua",
"interwiki-addtext-local": "Amestar un prefixu interwiki o de llingua llocal",
"interwiki_addintro": "Tas amestando un nuevu prefixu interwiki.\nRecuerda que nun pue contener espacios ( ), dos puntos (:), nin los signos (&) nin (=).",
"interwiki_addbutton": "Amestar",
- "interwiki_added": "El prefixu «$1» s'amestó correutamente a la tabla d'interwiki.",
+ "interwiki_added": "El prefixu «$1» amestóse a la tabla d'interwikis.",
"interwiki_addfailed": "El prefixu «$1» nun se pudo amestar a la tabla d'interwiki.\nSeique yá esiste na tabla d'interwiki.",
"interwiki_edittext": "Editar un prefixu d'interwiki",
"interwiki_editintro": "Tas editando un prefixu d'interwiki.\nRecuerda qu'esto pue francer enllaces esistentes.",
- "interwiki_edited": "El prefixu «$1» se camudó correutamente na tabla d'interwiki.",
+ "interwiki_edited": "El prefixu «$1» camudóse na tabla d'interwikis.",
"interwiki_editerror": "El prefixu «$1» nun se pudo camudar na tabla d'interwiki.\nSeique nun esista.",
"interwiki-badprefix": "El prefixu d'interwiki conseñáu «$1» contien caráuteres inválidos",
"interwiki-submit-empty": "El prefixu y la URL nun puen tar baleros.",
diff --git a/www/wiki/extensions/Interwiki/i18n/avk.json b/www/wiki/extensions/Interwiki/i18n/avk.json
index a45fb566..75b469b5 100644
--- a/www/wiki/extensions/Interwiki/i18n/avk.json
+++ b/www/wiki/extensions/Interwiki/i18n/avk.json
@@ -1,13 +1,14 @@
{
"@metadata": {
"authors": [
- "Wikimistusik"
+ "Wikimistusik",
+ "Zoranzoki21"
]
},
"interwiki": "Wira va 'interwiki' orig isu betara",
"interwiki-title-norights": "Wira va 'interwiki' orig",
"interwiki-desc": "Batcoba, ta wira va 'interwiki' origak isu betara, va [[Special:Interwiki|aptafu bu]] loplekur",
- "interwiki_intro": "Ta lo giva icde 'interwiki' origak va [http://www.mediawiki.org/wiki/Interwiki_table MediaWiki.org] wil !",
+ "interwiki_intro": "Ta lo giva icde 'interwiki' origak va [//www.mediawiki.org/wiki/Interwiki_table MediaWiki.org] wil !",
"interwiki_prefix": "Abdueosta",
"interwiki-prefix-label": "Abdueosta:",
"interwiki_error": "ROKLA : 'Interwiki' origak tir vlardaf oke rotaca al sokir.",
diff --git a/www/wiki/extensions/Interwiki/i18n/bg.json b/www/wiki/extensions/Interwiki/i18n/bg.json
index 5e78478b..8b913908 100644
--- a/www/wiki/extensions/Interwiki/i18n/bg.json
+++ b/www/wiki/extensions/Interwiki/i18n/bg.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "DCLXVI"
+ "DCLXVI",
+ "StanProg"
]
},
"interwiki": "Преглед и управление на междууикитата",
@@ -10,8 +11,8 @@
"interwiki_intro": "Това е общ преглед на таблицата с междууикита.",
"interwiki_prefix": "Представка:",
"interwiki-prefix-label": "Представка:",
- "interwiki_local": "Локално",
- "interwiki-local-label": "Локално:",
+ "interwiki_local": "Препращане",
+ "interwiki-local-label": "Препращане:",
"interwiki_1": "да",
"interwiki_0": "не",
"interwiki_error": "ГРЕШКА: Таблицата с междууикита е празна или е възникнала друга грешка.",
@@ -19,12 +20,12 @@
"interwiki_reasonfield": "Причина:",
"interwiki_delquestion": "Изтриване на \"$1\"",
"interwiki_deleting": "Изтриване на представката „$1“.",
- "interwiki_deleted": "„$1“ беше успешно премахнато от таблицата с междууикита.",
+ "interwiki_deleted": "Представка „$1“ беше успешно премахната от таблицата с междууикита.",
"interwiki_delfailed": "„$1“ не може да бъде премахнато от таблицата с междууикита.",
- "interwiki_addtext": "Добавяне на ново междууики",
+ "interwiki_addtext": "Добавяне на междуики или езикова представка",
"interwiki_addintro": "''Забележка:'' Междууикитата не могат да съдържат интервали ( ), двуеточия (:), амперсанд (&) или знак за равенство (=).",
"interwiki_addbutton": "Добавяне",
- "interwiki_added": "„$1“ беше успешно добавено в таблицата с междууикита.",
+ "interwiki_added": "Представката „$1“ беше успешно добавена в таблицата с междууикита.",
"interwiki_addfailed": "„$1“ не може да бъде добавено в таблицата с междууикита. Възможно е вече да е било добавено там.",
"interwiki_edittext": "Редактиране на междууики представка",
"interwiki_edited": "Представката „$1“ беше успешно променена в таблицата с междууикита.",
diff --git a/www/wiki/extensions/Interwiki/i18n/de.json b/www/wiki/extensions/Interwiki/i18n/de.json
index 16a68d00..4bf0f9e8 100644
--- a/www/wiki/extensions/Interwiki/i18n/de.json
+++ b/www/wiki/extensions/Interwiki/i18n/de.json
@@ -14,7 +14,7 @@
},
"interwiki": "Interwikidaten verwalten",
"interwiki-title-norights": "Interwikidaten ansehen",
- "interwiki-desc": "Eine [[Special:Interwiki|Spezialseite]] zur Pflege der Interwikitabelle",
+ "interwiki-desc": "Fügt eine [[Special:Interwiki|Spezialseite]] zur Pflege der Interwikitabelle hinzu",
"interwiki_intro": "Diese Seite bietet einen Überblick des Inhalts der Interwikitabelle dieses Wikis, die die verwendeten Präfixkürzel zur schnellen Verlinkung auf unterschiedliche Wikis und andere externe Websites definiert. Zur empfohlenen Verwendung, siehe bitte [//www.mediawiki.org/wiki/Extension:Interwiki das Handbuch auf MediaWiki.org].",
"interwiki-legend-label": "Legende",
"interwiki_prefix": "Präfix",
diff --git a/www/wiki/extensions/Interwiki/i18n/es.json b/www/wiki/extensions/Interwiki/i18n/es.json
index 61322b61..15d84058 100644
--- a/www/wiki/extensions/Interwiki/i18n/es.json
+++ b/www/wiki/extensions/Interwiki/i18n/es.json
@@ -38,7 +38,7 @@
"interwiki_1": "sí",
"interwiki_0": "no",
"interwiki_error": "Error: La tabla de interwikis está vacía, u otra cosa salió mal.",
- "interwiki-cached": "Los datos de los interwikis se almacenan en la memoria caché. No es posible modificar la caché.",
+ "interwiki-cached": "Los datos de los interwikis se almacenan en la antememoria. No es posible modificar la antememoria.",
"interwiki_edit": "Editar",
"interwiki_reasonfield": "Motivo:",
"interwiki_delquestion": "Borrando «$1»",
diff --git a/www/wiki/extensions/Interwiki/i18n/fa.json b/www/wiki/extensions/Interwiki/i18n/fa.json
index 59be8c3a..b4e9fa30 100644
--- a/www/wiki/extensions/Interwiki/i18n/fa.json
+++ b/www/wiki/extensions/Interwiki/i18n/fa.json
@@ -9,7 +9,8 @@
"Omidh",
"Reza1615",
"Dalba",
- "Alirezaaa"
+ "Alirezaaa",
+ "Ladsgroup"
]
},
"interwiki": "نمایش و ویرایش اطلاعات میان‌ویکی",
@@ -39,16 +40,17 @@
"interwiki_reasonfield": "دلیل:",
"interwiki_delquestion": "حذف «$1»",
"interwiki_deleting": "شما در حال حذف کردن پیشوند «$1» هستید.",
- "interwiki_deleted": "پیشوند «$1» با موفقیت از جدول میان‌ویکی حذف شد.",
+ "interwiki_deleted": "پیشوند «$1» از جدول میان‌ویکی حذف شد.",
"interwiki_delfailed": "پیشوند «$1» را نمی‌توان از جدول میان‌ویکی حذف کرد.",
- "interwiki_addtext": "افزودن یک پیشوند میان‌ویکی",
+ "interwiki-logtext": "نمایش سیاهه",
+ "interwiki_addtext": "افزودن یک پیشوند میان‌ویکی یا زبان",
"interwiki_addintro": "شما در حال ویرایش یک پیشوند میان‌ویکی هستید.\nتوجه داشته باشید که این پیشوند نمی‌تواند شامل فاصله ( )، دو نقطه (:)، علامت آمپرساند (&) یا علامت مساوی (=) باشد.",
"interwiki_addbutton": "افزودن",
- "interwiki_added": "پیشوند «$1» با موفقیت به جدول میان‌ویکی افزوده شد.",
+ "interwiki_added": "پیشوند «$1» به جدول میان‌ویکی افزوده شد.",
"interwiki_addfailed": "پیشوند «$1» را نمی‌توان به جدول میان‌ویکی افزود.\nاحتمالاً این پیشوند از قبل در جدول میان‌ویکی وجود دارد.",
"interwiki_edittext": "ویرایش یک پیشوند میان‌ویکی",
"interwiki_editintro": "شما در حال ویرایش یک پیشوند میان‌ویکی هستید.\nتوجه داشته باشید که این کار می‌تواند پیوندهای موجود را خراب کند.",
- "interwiki_edited": "پیشوند «$1» با موفقیت در جدول میان‌ویکی تغییر داده شد.",
+ "interwiki_edited": "پیشوند «$1» در جدول میان‌ویکی تغییر داده شد.",
"interwiki_editerror": "پیشوند «$1» را نمی‌توان در جدول میان‌ویکی تغییر داد.\nاحتمالاً این پیشوند وجود ندارد.",
"interwiki-badprefix": "پیشوند میان‌ویکی «$1» حاوی نویسه‌های نامجاز است",
"interwiki-submit-empty": "پیشوند و آدرس URL نمی‌توانند خالی باشند.",
@@ -59,5 +61,9 @@
"logentry-interwiki-iw_delete": "$1 {{GENDER:$2|حذف شده}} پیشوند \"$4\" از جدول ویکی داخلی",
"log-description-interwiki": "این یک تاریخچه از تغییرات [[Special:Interwiki|interwiki table]] است.",
"right-interwiki": "ویرایش اطلاعات میان‌ویکی",
- "action-interwiki": "تغییر این مدخل میان‌ویکی"
+ "action-interwiki": "تغییر این مدخل میان‌ویکی",
+ "interwiki-global-links": "پیشوندهای میان‌ویکی سراسری",
+ "interwiki-local-links": "پیشوندهای میان‌ویکی محلی",
+ "interwiki-links": "پیشوندهای میان‌ویکی",
+ "interwiki-language-links": "پیشوندهای بین‌زبانی"
}
diff --git a/www/wiki/extensions/Interwiki/i18n/fy.json b/www/wiki/extensions/Interwiki/i18n/fy.json
index 1aab0e90..b9feee0c 100644
--- a/www/wiki/extensions/Interwiki/i18n/fy.json
+++ b/www/wiki/extensions/Interwiki/i18n/fy.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Snakesteuben",
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
"interwiki-legend-label": "Leginda",
diff --git a/www/wiki/extensions/Interwiki/i18n/got.json b/www/wiki/extensions/Interwiki/i18n/got.json
index 13fbc008..d4802c95 100644
--- a/www/wiki/extensions/Interwiki/i18n/got.json
+++ b/www/wiki/extensions/Interwiki/i18n/got.json
@@ -6,4 +6,4 @@
]
},
"interwiki_reasonfield": "𐍆𐌰𐌹𐍂𐌹𐌽𐌰:"
-} \ No newline at end of file
+}
diff --git a/www/wiki/extensions/Interwiki/i18n/hr.json b/www/wiki/extensions/Interwiki/i18n/hr.json
index a7deb9e7..37c3fe9e 100644
--- a/www/wiki/extensions/Interwiki/i18n/hr.json
+++ b/www/wiki/extensions/Interwiki/i18n/hr.json
@@ -41,7 +41,7 @@
"interwiki_edited": "Prefiks \"$1\" je uspješno promijenjen u interwiki tablici.",
"interwiki_editerror": "Prefiks \"$1\" ne može biti promijenjen u interwiki tablici. Vjerojatno ne postoji.",
"interwiki-badprefix": "Određeni međuwiki prefiks \"$1\" sadrži nedozvoljene znakove",
- "log-name-interwiki": "Evidencije interwiki tablice",
+ "log-name-interwiki": "Evidencija tablice međuwikija",
"log-description-interwiki": "Ovo su evidencije promjena na [[Special:Interwiki|interwiki tablici]].",
"right-interwiki": "Uređivanje interwiki podataka",
"action-interwiki": "uredi ovaj međuwiki zapis",
diff --git a/www/wiki/extensions/Interwiki/i18n/is.json b/www/wiki/extensions/Interwiki/i18n/is.json
index 03fc78b7..61c52be3 100644
--- a/www/wiki/extensions/Interwiki/i18n/is.json
+++ b/www/wiki/extensions/Interwiki/i18n/is.json
@@ -1,12 +1,22 @@
{
"@metadata": {
"authors": [
- "S.Örvarr.S"
+ "S.Örvarr.S",
+ "Sveinn í Felli"
]
},
+ "interwiki-legend-label": "Skýring",
+ "interwiki_prefix": "Forskeyti",
+ "interwiki-prefix-label": "Forskeyti:",
+ "interwiki_url": "Vefslóð",
+ "interwiki-url-label": "Vefslóð:",
+ "interwiki_local": "Áfram",
+ "interwiki-local-label": "Áframsenda:",
"interwiki_1": "já",
"interwiki_0": "nei",
"interwiki_edit": "Breyta",
"interwiki_reasonfield": "Ástæða:",
+ "interwiki_delquestion": "Eyði \"$1\"",
+ "interwiki-logtext": "Skoða aðgerðaskrá",
"interwiki_addbutton": "Bæta við"
}
diff --git a/www/wiki/extensions/Interwiki/i18n/ja.json b/www/wiki/extensions/Interwiki/i18n/ja.json
index 54be0876..716c183a 100644
--- a/www/wiki/extensions/Interwiki/i18n/ja.json
+++ b/www/wiki/extensions/Interwiki/i18n/ja.json
@@ -10,13 +10,14 @@
"青子守歌",
"2nd-player",
"Sujiniku",
- "Azeha"
+ "Azeha",
+ "Yusuke1109"
]
},
"interwiki": "インターウィキデータの閲覧と編集",
"interwiki-title-norights": "インターウィキデータの閲覧",
"interwiki-desc": "インターウィキテーブルの表示と編集を行う[[Special:Interwiki|特別ページ]]を追加する",
- "interwiki_intro": "以下はインターウィキの概要です。これは、すぐに別のウィキや他の外部サイトへのリンクに使用されるプレフィックスのショートカットを定義します。推奨される使用のために、次をご覧ください。[//www.mediawiki.org/wiki/Extension:Interwiki the manual on MediaWiki.org]",
+ "interwiki_intro": "以下はインターウィキの概要です。これは、すぐに別のウィキや他の外部サイトへのリンクに使用されるプレフィックスのショートカットを定義します。推奨される使用のために、次をご覧ください。[//www.mediawiki.org/wiki/Extension:Interwiki MediaWiki.org 上のマニュアル]",
"interwiki-legend-label": "凡例",
"interwiki_prefix": "接頭辞",
"interwiki-prefix-label": "接頭辞:",
diff --git a/www/wiki/extensions/Interwiki/i18n/lb.json b/www/wiki/extensions/Interwiki/i18n/lb.json
index 45ac9f1d..cd15c1b0 100644
--- a/www/wiki/extensions/Interwiki/i18n/lb.json
+++ b/www/wiki/extensions/Interwiki/i18n/lb.json
@@ -9,7 +9,7 @@
},
"interwiki": "Interwiki-Date kucken a veränneren",
"interwiki-title-norights": "Interwiki-Date kucken",
- "interwiki-desc": "Setzt eng [[Special:Interwiki|Spezialsäit]] derbäi fir d'Interwiki-Tabell ze gesinn an z'änneren",
+ "interwiki-desc": "Setzt eng [[Special:Interwiki|Spezialsäit]] dobäi fir d'Interwiki-Tabell ze gesinn an z'änneren",
"interwiki_intro": "Dëst ass en Iwwerbléck iwwer d'Interwikitabell, déi, déi benotzt Prefix-Ofkierzungen weist, fir séier, déi verschidde Wikien, an aner extern Sitten, ze verlinken. Fir déi recommandéiert Benotzung heivun, kuckt w.e.g. [//www.mediawiki.org/wiki/Extension:Interwiki the manual on MediaWiki.org].",
"interwiki-legend-label": "Erklärung",
"interwiki_prefix": "Prefix",
@@ -37,10 +37,10 @@
"interwiki_delfailed": "Prefix \"$1\" konnt net aus der Interwiki-Tabell erausgeholl ginn.",
"interwiki-logtext": "Logbuch weisen",
"interwiki_addtext": "En Interwiki oder e Sproochprefix dobäisetzen",
- "interwiki_addintro": "Dir setzt en neien Interwiki-Prefix derbäi.\nDenkt drun datt keng Espacen ( ), Et-commerciale (&), Gläichzeechen (=) a keng Doppelpunkten (:) däerfen dra sinn.",
+ "interwiki_addintro": "Dir setzt en neien Interwiki-Prefix dobäi.\nDenkt drun datt keng Espacen ( ), Et-commerciale (&), Gläichzeechen (=) a keng Doppelpunkten (:) däerfen dra sinn.",
"interwiki_addbutton": "Derbäisetzen",
- "interwiki_added": "De Prefix \"$1\" gou an d'Interwiki-Tabell derbäigesat.",
- "interwiki_addfailed": "De Prefix \"$1\" konnt net an d'Interwiki-Tabell derbäigesat ginn.\nMéiglecherweis gëtt et e schonn an der Interwiki-Tabell.",
+ "interwiki_added": "De Prefix \"$1\" gouf an d'Interwiki-Tabell dobäigesat.",
+ "interwiki_addfailed": "De Prefix \"$1\" konnt net an d'Interwiki-Tabell dobäigesat ginn.\nMéiglecherweis gëtt et e schonn an der Interwiki-Tabell.",
"interwiki_edittext": "En interwiki Prefix änneren",
"interwiki_editintro": "Dir ännert en Interwiki Prefix.\nDenkt drun, datt dat kann dozou féieren datt Linken déi et scho gëtt net méi funktionéieren.",
"interwiki_edited": "De Prefix \"$1\" gouf an der Interwiki-Tabell geännert.",
@@ -49,7 +49,7 @@
"interwiki-submit-empty": "De Prefix an d'URL kënnen net eidel sinn.",
"interwiki-submit-invalidurl": "De Protokoll vun der URL ass valabel.",
"log-name-interwiki": "Lëscht mat der Interwikitabell",
- "logentry-interwiki-iw_add": "$1 {{GENDER:$2|huet}} de Prefix \"$4\" ($5) (trans: $6; local: $7) an d'Interwikitabell derbäigesat",
+ "logentry-interwiki-iw_add": "$1 {{GENDER:$2|huet}} de Prefix \"$4\" ($5) (trans: $6; local: $7) an d'Interwikitabell dobäigesat",
"logentry-interwiki-iw_edit": "$1 {{GENDER:$2|huet}} de Prefix „$4“ ($5) (trans: $6; local: $7) an der Interwikitabell geännert",
"logentry-interwiki-iw_delete": "$1 {{GENDER:$2|huet}} de Präfix \"$4\" aus der Interwikitabell erausgeholl",
"log-description-interwiki": "Dëst ass eng Lëscht mat den Ännerunge vun der [[Special:Interwiki|Interwikitabell]].",
diff --git a/www/wiki/extensions/Interwiki/i18n/li.json b/www/wiki/extensions/Interwiki/i18n/li.json
index 6e18802f..bccb2701 100644
--- a/www/wiki/extensions/Interwiki/i18n/li.json
+++ b/www/wiki/extensions/Interwiki/i18n/li.json
@@ -1,10 +1,11 @@
{
"@metadata": {
"authors": [
- "Ooswesthoesbes"
+ "Ooswesthoesbes",
+ "Pahles"
]
},
- "interwiki": "Toean en bewirk interwikigegaeves",
+ "interwiki": "Tuin en bewirk interwikigegaeves",
"interwiki-title-norights": "Toean interwikigegaeves",
"interwiki-desc": "Veug 'n [[Special:Interwiki|speciaal pagina]] tou veur de interwikitaofel te betrachte en te bewirke."
}
diff --git a/www/wiki/extensions/Interwiki/i18n/lzh.json b/www/wiki/extensions/Interwiki/i18n/lzh.json
index 385bbf9e..fb72aca9 100644
--- a/www/wiki/extensions/Interwiki/i18n/lzh.json
+++ b/www/wiki/extensions/Interwiki/i18n/lzh.json
@@ -2,12 +2,13 @@
"@metadata": {
"authors": [
"Dimension",
- "Jason924tw"
+ "Jason924tw",
+ "Zoranzoki21"
]
},
"interwiki": "察與修跨維表",
"interwiki-title-norights": "察跨維",
- "interwiki_intro": "閱[http://www.mediawiki.org/wiki/Interwiki_table MediaWiki.org]之。",
+ "interwiki_intro": "閱[//www.mediawiki.org/wiki/Interwiki_table MediaWiki.org]之。",
"interwiki_prefix": "前",
"interwiki-prefix-label": "前:",
"interwiki_local": "定為本維",
diff --git a/www/wiki/extensions/Interwiki/i18n/mk.json b/www/wiki/extensions/Interwiki/i18n/mk.json
index 1de7f58a..e4269682 100644
--- a/www/wiki/extensions/Interwiki/i18n/mk.json
+++ b/www/wiki/extensions/Interwiki/i18n/mk.json
@@ -5,7 +5,7 @@
]
},
"interwiki": "Преглед и уредување на меѓупроектни податоци",
- "interwiki-title-norights": "Податоци за меѓупроектни",
+ "interwiki-title-norights": "Податоци за меѓупроектни податоци",
"interwiki-desc": "Додава [[Special:Interwiki|службена страница]] за преглед и уредување на табелата со меѓупроектни врски",
"interwiki_intro": "Ова е преглед на табелата со јазични врски, која ги задава кратенките-претставки за брзо ставање врска до разни викија и други надворешни страници. Препорака за употребата ќе најдете во [//www.mediawiki.org/wiki/Extension:Interwiki прирачникот на MediaWiki.org].",
"interwiki-legend-label": "Легенда",
@@ -31,18 +31,18 @@
"interwiki_reasonfield": "Причина:",
"interwiki_delquestion": "Бришење на „$1“",
"interwiki_deleting": "Ја бришете претставката „$1“.",
- "interwiki_deleted": "Претставката „$1“ е успешно отстранета од табелата со меѓупроектни.",
+ "interwiki_deleted": "Претставката „$1“ е отстранета од табелата со меѓупроектни.",
"interwiki_delfailed": "Претставката „$1“ не можеше да се отстрани од табелата со меѓупроектни.",
"interwiki-logtext": "Погл. дневник",
"interwiki_addtext": "Додај меѓујазична или јазична претставка",
"interwiki-addtext-local": "Додај месна меѓујазична или јазична претставка",
"interwiki_addintro": "Запомнете дека не смее да содржи празни простори ( ), две точки (:), амперсанди (&) и знаци на равенство (=).",
"interwiki_addbutton": "Додај",
- "interwiki_added": "Претставката „$1“ е успешно додадена кон табелата со меѓупроектните.",
+ "interwiki_added": "Претставката „$1“ е додадена кон табелата со меѓупроектните.",
"interwiki_addfailed": "Претставката „$1“ не можеше да се додаде во табелата со меѓупроектни.\nВеројатно таму веќе постои.",
"interwiki_edittext": "Уредување на меѓујазична претставка",
"interwiki_editintro": "Уредувате меѓујазична претставка.\nЗапомнете дека ова може да ги раскине постоечките врски.",
- "interwiki_edited": "Претставката „$1“ е успешно изменет во табелата со меѓупроектни.",
+ "interwiki_edited": "Претставката „$1“ е изменет во табелата со меѓупроектни.",
"interwiki_editerror": "Претставката „$1“ не може да се менува во табелата со меѓупроектни.\nМожеби не постои.",
"interwiki-badprefix": "Укажаната меѓујазична претставка „$1“ содржи неважечки знаци",
"interwiki-submit-empty": "Претставката и URL-адресата не можат да бидат празни.",
diff --git a/www/wiki/extensions/Interwiki/i18n/mr.json b/www/wiki/extensions/Interwiki/i18n/mr.json
index bb83f509..0aab8024 100644
--- a/www/wiki/extensions/Interwiki/i18n/mr.json
+++ b/www/wiki/extensions/Interwiki/i18n/mr.json
@@ -2,13 +2,14 @@
"@metadata": {
"authors": [
"Kaustubh",
- "V.narsikar"
+ "V.narsikar",
+ "Zoranzoki21"
]
},
"interwiki": "आंतरविकि डाटा पहा व संपादा",
"interwiki-title-norights": "आंतरविकि डाटा पहा",
"interwiki-desc": "आंतरविकि सारणी पाहण्यासाठी व संपादण्यासाठी एक [[Special:Interwiki|विशेष पान]] वाढविते",
- "interwiki_intro": "हा आंतरविकि सारणीबद्दलचा सामान्य सारांश आहे.तो विविध विकिंना व बाह्य संकेतस्थळांना तत्परतेने दुवा देण्यास आवश्यक त्या उपपदाच्या लघुपथाची व्याख्या देतो. अधिक माहितीसाठी [http://www.mediawiki.org/wiki/Interwiki_table MediaWiki.org] पहा.याच्या वापरासाठी ते शिफारस केल्या गेले आहे",
+ "interwiki_intro": "हा आंतरविकि सारणीबद्दलचा सामान्य सारांश आहे.तो विविध विकिंना व बाह्य संकेतस्थळांना तत्परतेने दुवा देण्यास आवश्यक त्या उपपदाच्या लघुपथाची व्याख्या देतो. अधिक माहितीसाठी [//www.mediawiki.org/wiki/Interwiki_table MediaWiki.org] पहा.याच्या वापरासाठी ते शिफारस केल्या गेले आहे",
"interwiki-legend-label": "विवरण",
"interwiki_prefix": "उपपद (पूर्वप्रत्यय)",
"interwiki-prefix-label": "उपपद (पूर्वप्रत्यय):",
diff --git a/www/wiki/extensions/Interwiki/i18n/mwl.json b/www/wiki/extensions/Interwiki/i18n/mwl.json
index 1c7eed22..6b914d82 100644
--- a/www/wiki/extensions/Interwiki/i18n/mwl.json
+++ b/www/wiki/extensions/Interwiki/i18n/mwl.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
"interwiki-title-norights": "Dados de prefixos anterwikis",
diff --git a/www/wiki/extensions/Interwiki/i18n/myv.json b/www/wiki/extensions/Interwiki/i18n/myv.json
index 2b072319..3c5e07e3 100644
--- a/www/wiki/extensions/Interwiki/i18n/myv.json
+++ b/www/wiki/extensions/Interwiki/i18n/myv.json
@@ -1,14 +1,15 @@
{
"@metadata": {
"authors": [
- "Botuzhaleny-sodamo"
+ "Botuzhaleny-sodamo",
+ "Rueter"
]
},
"interwiki_prefix": "Икелькс пене",
"interwiki-prefix-label": "Икелькс пенезэ:",
"interwiki_local": "Пачтямс седе тов",
"interwiki-local-label": "Пачтямс седе тов:",
- "interwiki_edit": "Витнеме-петнеме",
+ "interwiki_edit": "Витнемс-петнемс",
"interwiki_reasonfield": "Тувталось:",
"interwiki_addbutton": "Поладомс"
}
diff --git a/www/wiki/extensions/Interwiki/i18n/pt.json b/www/wiki/extensions/Interwiki/i18n/pt.json
index d55d8c7c..9f013f13 100644
--- a/www/wiki/extensions/Interwiki/i18n/pt.json
+++ b/www/wiki/extensions/Interwiki/i18n/pt.json
@@ -9,22 +9,23 @@
"Waldir",
"555",
"Vitorvicentevalente",
- "Fúlvio"
+ "Fúlvio",
+ "Athena in Wonderland"
]
},
"interwiki": "Ver e manipular dados de interwikis",
"interwiki-title-norights": "Dados de prefixos interwikis",
"interwiki-desc": "[[Special:Interwiki|Página especial]] para ver e editar a tabela de interwikis",
- "interwiki_intro": "Esta é uma visão geral da tabela de interwikis, que define os prefixos usados para criar rapidamente ligações para outras wikis e outros ''sites'' externos. Para recomendações de uso, por favor consulte [//www.mediawiki.org/wiki/Extension:Interwiki o manual na MediaWiki.org].",
+ "interwiki_intro": "Esta é uma visão geral da tabela de interwikis, que define os prefixos usados para criar rapidamente hiperligações para outras wikis e outros sítios externos. Para recomendações de uso, por favor consulte [//www.mediawiki.org/wiki/Extension:Interwiki o manual na MediaWiki.org].",
"interwiki-legend-label": "Legenda",
"interwiki_prefix": "Prefixo",
"interwiki-prefix-label": "Prefixo:",
- "interwiki_prefix_intro": "Prefixo do ''link'' interwikis, para ser usado na sintaxe da notação wiki <code>[<nowiki />[prefixo:<em>nome da página</em>]]</code>.",
+ "interwiki_prefix_intro": "Prefixo da hiperligação interwikis, para ser usado na sintaxe de texto wiki <code>[<nowiki />[prefixo:<em>nome da página</em>]]</code>.",
"interwiki_url_intro": "Valor predefinido para o URL. Nele, o espaço reservado $1 será substituído pelo <em>nome da página</em> em <code>[<nowiki />[prefixo:<em>nome da página</em>]]</code>.",
"interwiki_local": "Encaminhar",
"interwiki-local-label": "Encaminhar:",
"interwiki_local_0_intro": "Pedidos HTTP externos, feitos à wiki local usando este prefixo interwikis no URL, resultam numa página de erro \"{{int:badtitle}}\".",
- "interwiki_local_1_intro": "Pedidos HTTP externos, feitos à wiki local usando este prefixo interwikis, serão redirecionados para o URL de destino (ou seja, serão tratados como ''links'' para páginas locais).",
+ "interwiki_local_1_intro": "Pedidos HTTP externos, feitos à wiki local usando este prefixo interwikis, serão redirecionados para o URL de destino (ou seja, serão tratados como hiperligações para páginas locais).",
"interwiki_trans": "Transcluir",
"interwiki-trans-label": "Transcluir:",
"interwiki_trans_1_intro": "Se for usada a notação <code>{<nowiki />{prefixo:<em>nome da página</em>}}</code>, permitir a transclusão de predefinições e páginas da wiki externa se transclusões interwikis forem permitidas de forma geral nesta wiki ([//www.mediawiki.org/wiki/Manual:$wgEnableScaryTranscluding transclusão interwikis]).",
@@ -32,7 +33,7 @@
"interwiki_1": "sim",
"interwiki_0": "não",
"interwiki_error": "ERRO: A tabela de interwikis está vazia, ou alguma outra coisa não correu bem.",
- "interwiki-cached": "Os dados de interwikis são armazenados na ''cache''. Não é possível modificar a ''cache''.",
+ "interwiki-cached": "Os dados de interwikis são armazenados na cache. Não é possível modificar a cache.",
"interwiki_edit": "Editar",
"interwiki_reasonfield": "Motivo:",
"interwiki_delquestion": "A apagar \"$1\"",
@@ -47,7 +48,7 @@
"interwiki_added": "O prefixo \"$1\" foi adicionado à tabela de interwikis.",
"interwiki_addfailed": "Não foi possível adicionar o prefixo \"$1\" à tabela de interwikis. Possivelmente já existe nessa tabela.",
"interwiki_edittext": "A editar um prefixo interwikis",
- "interwiki_editintro": "Está a editar um prefixo interwikis. Lembre-se de que isto pode quebrar ''links'' existentes.",
+ "interwiki_editintro": "Está a editar um prefixo interwikis. Lembre-se de que isto pode quebrar hiperligações existentes.",
"interwiki_edited": "O prefixo \"$1\" foi modificado na tabela de interwikis.",
"interwiki_editerror": "Não foi possível modificar o prefixo \"$1\" na tabela de interwikis. Possivelmente, não existe.",
"interwiki-badprefix": "O prefixo interwikis \"$1\" contém caracteres inválidos",
diff --git a/www/wiki/extensions/Interwiki/i18n/skr-arab.json b/www/wiki/extensions/Interwiki/i18n/skr-arab.json
new file mode 100644
index 00000000..c35013cf
--- /dev/null
+++ b/www/wiki/extensions/Interwiki/i18n/skr-arab.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Saraiki"
+ ]
+ },
+ "interwiki": "انٹر وکی ڈیٹا وچ تبدیلی کرو تے ݙیکھو",
+ "interwiki-title-norights": "انٹر وکی معلومات ݙیکھو",
+ "interwiki_prefix": "سابقے",
+ "interwiki-prefix-label": "سابقے:",
+ "interwiki_local": "اڳوں تے بھیجو",
+ "interwiki-local-label": "اڳوں تے بھیجو:",
+ "interwiki_1": "جیا",
+ "interwiki_0": "کو",
+ "interwiki_edit": "لکھو",
+ "interwiki_reasonfield": "وجہ:"
+}
diff --git a/www/wiki/extensions/Interwiki/i18n/sr-ec.json b/www/wiki/extensions/Interwiki/i18n/sr-ec.json
index 0b18f38b..81bd0e7a 100644
--- a/www/wiki/extensions/Interwiki/i18n/sr-ec.json
+++ b/www/wiki/extensions/Interwiki/i18n/sr-ec.json
@@ -6,7 +6,8 @@
"Sasa Stefanovic",
"Жељко Тодоровић",
"Михајло Анђелковић",
- "Сербијана"
+ "Сербијана",
+ "Acamicamacaraca"
]
},
"interwiki": "Прегледај и измени податке о међувикију",
@@ -30,7 +31,7 @@
"interwiki_deleting": "Ви бришете префикс „$1“.",
"interwiki_deleted": "Префикс „$1“ је обрисан из табеле међувикија.",
"interwiki_delfailed": "Префикс „$1“ није могао бити обрисан из табеле међувикија.",
- "interwiki-logtext": "Види дневник",
+ "interwiki-logtext": "Погледај дневник",
"interwiki_addtext": "Додај интервики или језички префикс",
"interwiki_addintro": "Ви додајете један интервики префикс.\nИмајте на уму да он не може да садржи размаке ( ), двотачку (:), амерсанд (&), или знак једнакости (=).",
"interwiki_addbutton": "Додај",
diff --git a/www/wiki/extensions/Interwiki/i18n/vo.json b/www/wiki/extensions/Interwiki/i18n/vo.json
index 463da7fb..b744439f 100644
--- a/www/wiki/extensions/Interwiki/i18n/vo.json
+++ b/www/wiki/extensions/Interwiki/i18n/vo.json
@@ -2,13 +2,14 @@
"@metadata": {
"authors": [
"Malafaya",
- "Smeira"
+ "Smeira",
+ "Zoranzoki21"
]
},
"interwiki": "Logön e bevobön nünodis vüvükik",
"interwiki-title-norights": "Logön nünodis vüvükik",
"interwiki-desc": "Läükön [[Special:Interwiki|padi patik]] ad logön e bevobön taibi vüvükik",
- "interwiki_intro": "Logön eli [http://www.mediawiki.org/wiki/Interwiki_table MediaWiki.org] ad tuvön nünis pluik tefü taib vüvükik.",
+ "interwiki_intro": "Logön eli [//www.mediawiki.org/wiki/Interwiki_table MediaWiki.org] ad tuvön nünis pluik tefü taib vüvükik.",
"interwiki_prefix": "Foyümot",
"interwiki-prefix-label": "Foyümot:",
"interwiki_0": "nö",
diff --git a/www/wiki/extensions/Interwiki/i18n/yue.json b/www/wiki/extensions/Interwiki/i18n/yue.json
index 0a523f7a..43fc9476 100644
--- a/www/wiki/extensions/Interwiki/i18n/yue.json
+++ b/www/wiki/extensions/Interwiki/i18n/yue.json
@@ -1,12 +1,13 @@
{
"@metadata": {
"authors": [
- "Antonytse"
+ "Antonytse",
+ "Zoranzoki21"
]
},
"interwiki": "去睇同編輯跨維基資料",
"interwiki-title-norights": "去睇跨維基資料",
- "interwiki_intro": "睇吓[http://www.mediawiki.org/wiki/Interwiki_table MediaWiki.org]有關跨維基表嘅更多資料。",
+ "interwiki_intro": "睇吓[//www.mediawiki.org/wiki/Interwiki_table MediaWiki.org]有關跨維基表嘅更多資料。",
"interwiki_prefix": "前綴",
"interwiki-prefix-label": "前綴:",
"interwiki_local": "定義呢個做一個本地wiki",
diff --git a/www/wiki/extensions/Interwiki/i18n/zh-hans.json b/www/wiki/extensions/Interwiki/i18n/zh-hans.json
index d4374571..f2c873a8 100644
--- a/www/wiki/extensions/Interwiki/i18n/zh-hans.json
+++ b/www/wiki/extensions/Interwiki/i18n/zh-hans.json
@@ -14,7 +14,8 @@
"Yfdyh000",
"Mywood",
"Impersonator 1",
- "范"
+ "范",
+ "Wmr"
]
},
"interwiki": "查看和编辑跨wiki数据",
diff --git a/www/wiki/extensions/Interwiki/i18n/zh-hant.json b/www/wiki/extensions/Interwiki/i18n/zh-hant.json
index 42a130e7..238960f6 100644
--- a/www/wiki/extensions/Interwiki/i18n/zh-hant.json
+++ b/www/wiki/extensions/Interwiki/i18n/zh-hant.json
@@ -11,7 +11,8 @@
"Waihorace",
"Wrightbus",
"Cwlin0416",
- "LNDDYL"
+ "LNDDYL",
+ "Hello903hello"
]
},
"interwiki": "檢視並編輯跨 Wiki 資料",
@@ -39,18 +40,18 @@
"interwiki_reasonfield": "原因:",
"interwiki_delquestion": "正在刪除 \"$1\"",
"interwiki_deleting": "您正在刪除字首 \"$1\"。",
- "interwiki_deleted": "已成功刪除在跨 Wiki 資料表中的字首 \"$1\"。",
+ "interwiki_deleted": "已刪除在跨 Wiki 資料表中的字首「$1」。",
"interwiki_delfailed": "無法刪除跨 Wiki 資料表中的字首 \"$1\"。",
"interwiki-logtext": "檢視日誌",
"interwiki_addtext": "新增一個跨 Wiki 或語言字首",
"interwiki-addtext-local": "新增本地跨 Wiki 或語言字首",
"interwiki_addintro": "您正新增一個跨 Wiki 字首。\n字首不可包含空白 ( )、冒號 (:)、連字號 (&) 或等號 (=)。",
"interwiki_addbutton": "新增",
- "interwiki_added": "已經成功加入字首 \"$1\" 到跨 Wiki 資料表。",
+ "interwiki_added": "已經加入字首「$1」到跨 Wiki 資料表。",
"interwiki_addfailed": "無法新增字首 \"$1\" 到跨 Wiki 資料表。\n可能已存在於跨 Wiki 資料表中。",
"interwiki_edittext": "正在編輯跨 Wiki 字首",
"interwiki_editintro": "您現正編輯跨 Wiki 字首。\n注意,這個動作會中斷現有的連結。",
- "interwiki_edited": "已成功修改在 Interwiki 資料表中的字首 \"$1\"。",
+ "interwiki_edited": "已經修改在跨 Wiki 資料表中的字首「$1」。",
"interwiki_editerror": "無法修改跨 Wiki 資料表中的字首 \"$1\"。\n可能並不存在。",
"interwiki-badprefix": "指定的跨 Wiki 字首 \"$1\" 中包含了無效的字元",
"interwiki-submit-empty": "字首與 URL 不可空白。",
@@ -66,7 +67,7 @@
"interwiki-global-description": "這些字首均繼承自全域設定,且僅可於來源 Wiki 編輯。",
"interwiki-local-links": "本地跨 Wiki 字首",
"interwiki-local-description": "這些字首均存在於本地,任何與全域設定重複的部份會使用全域的設定值覆蓋。",
- "interwiki-links": "跨 Wiki 字首",
+ "interwiki-links": "跨 wiki 字首",
"interwiki-language-links": "跨語言字首",
"interwiki-language-description": "這些字首符合已定義的語言代碼,當加入至頁面時會被用來建立 \"{{int:otherlanguages}}\" 清單。"
}
diff --git a/www/wiki/extensions/Interwiki/includes/InterwikiHooks.php b/www/wiki/extensions/Interwiki/includes/InterwikiHooks.php
new file mode 100644
index 00000000..7502e0ce
--- /dev/null
+++ b/www/wiki/extensions/Interwiki/includes/InterwikiHooks.php
@@ -0,0 +1,54 @@
+<?php
+
+class InterwikiHooks {
+ public static function onExtensionFunctions() {
+ global $wgInterwikiViewOnly;
+
+ if ( $wgInterwikiViewOnly === false ) {
+ global $wgAvailableRights, $wgLogTypes, $wgLogActionsHandlers;
+
+ // New user right, required to modify the interwiki table through Special:Interwiki
+ $wgAvailableRights[] = 'interwiki';
+
+ // Set up the new log type - interwiki actions are logged to this new log
+ $wgLogTypes[] = 'interwiki';
+ // interwiki, iw_add, iw_delete, iw_edit
+ $wgLogActionsHandlers['interwiki/*'] = 'InterwikiLogFormatter';
+ }
+
+ return true;
+ }
+
+ public static function onInterwikiLoadPrefix( $prefix, &$iwData ) {
+ global $wgInterwikiCentralDB;
+ // docs/hooks.txt says: Return true without providing an interwiki to continue interwiki search.
+ if ( $wgInterwikiCentralDB === null || $wgInterwikiCentralDB === wfWikiID() ) {
+ // No global set or this is global, nothing to add
+ return true;
+ }
+ if ( !Language::fetchLanguageName( $prefix ) ) {
+ // Check if prefix exists locally and skip
+ foreach ( Interwiki::getAllPrefixes( null ) as $id => $localPrefixInfo ) {
+ if ( $prefix === $localPrefixInfo['iw_prefix'] ) {
+ return true;
+ }
+ }
+ $dbr = wfGetDB( DB_REPLICA, [], $wgInterwikiCentralDB );
+ $res = $dbr->selectRow(
+ 'interwiki',
+ '*',
+ [ 'iw_prefix' => $prefix ],
+ __METHOD__
+ );
+ if ( !$res ) {
+ return true;
+ }
+ // Excplicitly make this an array since it's expected to be one
+ $iwData = (array)$res;
+ // At this point, we can safely return false because we know that we have something
+ return false;
+ }
+ return true;
+ }
+
+}
diff --git a/www/wiki/extensions/Interwiki/includes/InterwikiLogFormatter.php b/www/wiki/extensions/Interwiki/includes/InterwikiLogFormatter.php
new file mode 100644
index 00000000..ecdce1a4
--- /dev/null
+++ b/www/wiki/extensions/Interwiki/includes/InterwikiLogFormatter.php
@@ -0,0 +1,17 @@
+<?php
+
+/**
+ * Needed to pass the URL as a raw parameter, because it contains $1
+ */
+class InterwikiLogFormatter extends LogFormatter {
+ /**
+ * @return array
+ */
+ protected function getMessageParameters() {
+ $params = parent::getMessageParameters();
+ if ( isset( $params[4] ) ) {
+ $params[4] = Message::rawParam( htmlspecialchars( $params[4] ) );
+ }
+ return $params;
+ }
+}
diff --git a/www/wiki/extensions/Interwiki/includes/SpecialInterwiki.php b/www/wiki/extensions/Interwiki/includes/SpecialInterwiki.php
new file mode 100644
index 00000000..ca18a1cd
--- /dev/null
+++ b/www/wiki/extensions/Interwiki/includes/SpecialInterwiki.php
@@ -0,0 +1,498 @@
+<?php
+/**
+ * Implements Special:Interwiki
+ * @ingroup SpecialPage
+ */
+class SpecialInterwiki extends SpecialPage {
+ /**
+ * Constructor - sets up the new special page
+ */
+ public function __construct() {
+ parent::__construct( 'Interwiki' );
+ }
+
+ public function doesWrites() {
+ return true;
+ }
+
+ /**
+ * Different description will be shown on Special:SpecialPage depending on
+ * whether the user can modify the data.
+ * @return String
+ */
+ function getDescription() {
+ return $this->msg( $this->canModify() ?
+ 'interwiki' : 'interwiki-title-norights' )->plain();
+ }
+
+ public function getSubpagesForPrefixSearch() {
+ // delete, edit both require the prefix parameter.
+ return [ 'add' ];
+ }
+
+ /**
+ * Show the special page
+ *
+ * @param string|null $par parameter passed to the page or null
+ */
+ public function execute( $par ) {
+ $this->setHeaders();
+ $this->outputHeader();
+
+ $out = $this->getOutput();
+ $request = $this->getRequest();
+
+ $out->addModuleStyles( 'ext.interwiki.specialpage' );
+
+ $action = $par ?: $request->getVal( 'action', $par );
+ $return = $this->getPageTitle();
+
+ switch ( $action ) {
+ case 'delete':
+ case 'edit':
+ case 'add':
+ if ( $this->canModify( $out ) ) {
+ $this->showForm( $action );
+ }
+ $out->returnToMain( false, $return );
+ break;
+ case 'submit':
+ if ( !$this->canModify( $out ) ) {
+ // Error msg added by canModify()
+ } elseif ( !$request->wasPosted() ||
+ !$this->getUser()->matchEditToken( $request->getVal( 'wpEditToken' ) )
+ ) {
+ // Prevent cross-site request forgeries
+ $out->addWikiMsg( 'sessionfailure' );
+ } else {
+ $this->doSubmit();
+ }
+ $out->returnToMain( false, $return );
+ break;
+ default:
+ $this->showList();
+ break;
+ }
+ }
+
+ /**
+ * Returns boolean whether the user can modify the data.
+ * @param OutputPage|bool $out If $wgOut object given, it adds the respective error message.
+ * @throws PermissionsError|ReadOnlyError
+ * @return bool
+ */
+ public function canModify( $out = false ) {
+ global $wgInterwikiCache;
+ if ( !$this->getUser()->isAllowed( 'interwiki' ) ) {
+ // Check permissions
+ if ( $out ) {
+ throw new PermissionsError( 'interwiki' );
+ }
+
+ return false;
+ } elseif ( $wgInterwikiCache ) {
+ // Editing the interwiki cache is not supported
+ if ( $out ) {
+ $out->addWikiMsg( 'interwiki-cached' );
+ }
+
+ return false;
+ } elseif ( wfReadOnly() ) {
+ throw new ReadOnlyError;
+ }
+
+ return true;
+ }
+
+ /**
+ * @param string $action The action of the form
+ */
+ protected function showForm( $action ) {
+ $request = $this->getRequest();
+
+ $prefix = $request->getVal( 'prefix' );
+ $wpPrefix = '';
+ $label = [ 'class' => 'mw-label' ];
+ $input = [ 'class' => 'mw-input' ];
+
+ if ( $action === 'delete' ) {
+ $topmessage = $this->msg( 'interwiki_delquestion', $prefix )->text();
+ $intromessage = $this->msg( 'interwiki_deleting', $prefix )->escaped();
+ $wpPrefix = Html::hidden( 'wpInterwikiPrefix', $prefix );
+ $button = 'delete';
+ $formContent = '';
+ } elseif ( $action === 'edit' ) {
+ $dbr = wfGetDB( DB_REPLICA );
+ $row = $dbr->selectRow( 'interwiki', '*', [ 'iw_prefix' => $prefix ], __METHOD__ );
+
+ if ( !$row ) {
+ $this->error( 'interwiki_editerror', $prefix );
+ return;
+ }
+
+ $prefix = $prefixElement = $row->iw_prefix;
+ $defaulturl = $row->iw_url;
+ $trans = $row->iw_trans;
+ $local = $row->iw_local;
+ $wpPrefix = Html::hidden( 'wpInterwikiPrefix', $row->iw_prefix );
+ $topmessage = $this->msg( 'interwiki_edittext' )->text();
+ $intromessage = $this->msg( 'interwiki_editintro' )->escaped();
+ $button = 'edit';
+ } elseif ( $action === 'add' ) {
+ $prefix = $request->getVal( 'wpInterwikiPrefix', $request->getVal( 'prefix' ) );
+ $prefixElement = Xml::input( 'wpInterwikiPrefix', 20, $prefix,
+ [ 'tabindex' => 1, 'id' => 'mw-interwiki-prefix', 'maxlength' => 20 ] );
+ $local = $request->getCheck( 'wpInterwikiLocal' );
+ $trans = $request->getCheck( 'wpInterwikiTrans' );
+ $defaulturl = $request->getVal( 'wpInterwikiURL', $this->msg( 'interwiki-defaulturl' )->text() );
+ $topmessage = $this->msg( 'interwiki_addtext' )->text();
+ $intromessage = $this->msg( 'interwiki_addintro' )->escaped();
+ $button = 'interwiki_addbutton';
+ }
+
+ if ( $action === 'add' || $action === 'edit' ) {
+ $formContent = Html::rawElement( 'tr', null,
+ Html::element( 'td', $label, $this->msg( 'interwiki-prefix-label' )->text() ) .
+ Html::rawElement( 'td', null, '<code>' . $prefixElement . '</code>' )
+ ) . Html::rawElement(
+ 'tr',
+ null,
+ Html::rawElement(
+ 'td',
+ $label,
+ Xml::label( $this->msg( 'interwiki-local-label' )->text(), 'mw-interwiki-local' )
+ ) .
+ Html::rawElement(
+ 'td',
+ $input,
+ Xml::check( 'wpInterwikiLocal', $local, [ 'id' => 'mw-interwiki-local' ] )
+ )
+ ) . Html::rawElement( 'tr', null,
+ Html::rawElement(
+ 'td',
+ $label,
+ Xml::label( $this->msg( 'interwiki-trans-label' )->text(), 'mw-interwiki-trans' )
+ ) .
+ Html::rawElement(
+ 'td',
+ $input, Xml::check( 'wpInterwikiTrans', $trans, [ 'id' => 'mw-interwiki-trans' ] ) )
+ ) . Html::rawElement( 'tr', null,
+ Html::rawElement(
+ 'td',
+ $label,
+ Xml::label( $this->msg( 'interwiki-url-label' )->text(), 'mw-interwiki-url' )
+ ) .
+ Html::rawElement( 'td', $input, Xml::input( 'wpInterwikiURL', 60, $defaulturl,
+ [ 'tabindex' => 1, 'maxlength' => 200, 'id' => 'mw-interwiki-url' ] ) )
+ );
+ }
+
+ $form = Xml::fieldset( $topmessage, Html::rawElement(
+ 'form',
+ [
+ 'id' => "mw-interwiki-{$action}form",
+ 'method' => 'post',
+ 'action' => $this->getPageTitle()->getLocalURL( [
+ 'action' => 'submit',
+ 'prefix' => $prefix
+ ] )
+ ],
+ Html::rawElement( 'p', null, $intromessage ) .
+ Html::rawElement( 'table', [ 'id' => "mw-interwiki-{$action}" ],
+ $formContent . Html::rawElement( 'tr', null,
+ Html::rawElement( 'td', $label, Xml::label( $this->msg( 'interwiki_reasonfield' )->text(),
+ "mw-interwiki-{$action}reason" ) ) .
+ Html::rawElement( 'td', $input, Xml::input( 'wpInterwikiReason', 60, '',
+ [ 'tabindex' => 1, 'id' => "mw-interwiki-{$action}reason", 'maxlength' => 200 ] ) )
+ ) . Html::rawElement( 'tr', null,
+ Html::rawElement( 'td', null, '' ) .
+ Html::rawElement( 'td', [ 'class' => 'mw-submit' ],
+ Xml::submitButton( $this->msg( $button )->text(), [ 'id' => 'mw-interwiki-submit' ] ) )
+ ) . $wpPrefix .
+ Html::hidden( 'wpEditToken', $this->getUser()->getEditToken() ) .
+ Html::hidden( 'wpInterwikiAction', $action )
+ )
+ ) );
+ $this->getOutput()->addHTML( $form );
+ }
+
+ protected function doSubmit() {
+ global $wgContLang;
+
+ $request = $this->getRequest();
+ $prefix = $request->getVal( 'wpInterwikiPrefix' );
+ $do = $request->getVal( 'wpInterwikiAction' );
+ // Show an error if the prefix is invalid (only when adding one).
+ // Invalid characters for a title should also be invalid for a prefix.
+ // Whitespace, ':', '&' and '=' are invalid, too.
+ // (Bug 30599).
+ global $wgLegalTitleChars;
+ $validPrefixChars = preg_replace( '/[ :&=]/', '', $wgLegalTitleChars );
+ if ( $do === 'add' && preg_match( "/\s|[^$validPrefixChars]/", $prefix ) ) {
+ $this->error( 'interwiki-badprefix', htmlspecialchars( $prefix ) );
+ $this->showForm( $do );
+ return;
+ }
+ $reason = $request->getText( 'wpInterwikiReason' );
+ $selfTitle = $this->getPageTitle();
+ $dbw = wfGetDB( DB_MASTER );
+ switch ( $do ) {
+ case 'delete':
+ $dbw->delete( 'interwiki', [ 'iw_prefix' => $prefix ], __METHOD__ );
+
+ if ( $dbw->affectedRows() === 0 ) {
+ $this->error( 'interwiki_delfailed', $prefix );
+ $this->showForm( $do );
+ } else {
+ $this->getOutput()->addWikiMsg( 'interwiki_deleted', $prefix );
+ $log = new LogPage( 'interwiki' );
+ $log->addEntry( 'iw_delete', $selfTitle, $reason, [ $prefix ] );
+ Interwiki::invalidateCache( $prefix );
+ }
+ break;
+ /** @noinspection PhpMissingBreakStatementInspection */
+ case 'add':
+ $prefix = $wgContLang->lc( $prefix );
+ case 'edit':
+ $theurl = $request->getVal( 'wpInterwikiURL' );
+ $local = $request->getCheck( 'wpInterwikiLocal' ) ? 1 : 0;
+ $trans = $request->getCheck( 'wpInterwikiTrans' ) ? 1 : 0;
+ $data = [
+ 'iw_prefix' => $prefix,
+ 'iw_url' => $theurl,
+ 'iw_local' => $local,
+ 'iw_trans' => $trans
+ ];
+
+ if ( $prefix === '' || $theurl === '' ) {
+ $this->error( 'interwiki-submit-empty' );
+ $this->showForm( $do );
+ return;
+ }
+
+ // Simple URL validation: check that the protocol is one of
+ // the supported protocols for this wiki.
+ // (bug 30600)
+ if ( !wfParseUrl( $theurl ) ) {
+ $this->error( 'interwiki-submit-invalidurl' );
+ $this->showForm( $do );
+ return;
+ }
+
+ if ( $do === 'add' ) {
+ $dbw->insert( 'interwiki', $data, __METHOD__, 'IGNORE' );
+ } else { // $do === 'edit'
+ $dbw->update( 'interwiki', $data, [ 'iw_prefix' => $prefix ], __METHOD__, 'IGNORE' );
+ }
+
+ // used here: interwiki_addfailed, interwiki_added, interwiki_edited
+ if ( $dbw->affectedRows() === 0 ) {
+ $this->error( "interwiki_{$do}failed", $prefix );
+ $this->showForm( $do );
+ } else {
+ $this->getOutput()->addWikiMsg( "interwiki_{$do}ed", $prefix );
+ $log = new LogPage( 'interwiki' );
+ $log->addEntry( 'iw_' . $do, $selfTitle, $reason, [ $prefix, $theurl, $trans, $local ] );
+ Interwiki::invalidateCache( $prefix );
+ }
+ break;
+ }
+ }
+
+ protected function showList() {
+ global $wgInterwikiCentralDB, $wgInterwikiViewOnly;
+ $canModify = $this->canModify();
+
+ // Build lists
+ if ( !method_exists( 'Interwiki', 'getAllPrefixes' ) ) {
+ // version 2.0 is not backwards compatible (but will still display a nice error)
+ $this->error( 'interwiki_error' );
+ return;
+ }
+ $iwPrefixes = Interwiki::getAllPrefixes( null );
+ $iwGlobalPrefixes = [];
+ if ( $wgInterwikiCentralDB !== null && $wgInterwikiCentralDB !== wfWikiID() ) {
+ // Fetch list from global table
+ $dbrCentralDB = wfGetDB( DB_REPLICA, [], $wgInterwikiCentralDB );
+ $res = $dbrCentralDB->select( 'interwiki', '*', false, __METHOD__ );
+ $retval = [];
+ foreach ( $res as $row ) {
+ $row = (array)$row;
+ if ( !Language::fetchLanguageName( $row['iw_prefix'] ) ) {
+ $retval[] = $row;
+ }
+ }
+ $iwGlobalPrefixes = $retval;
+ }
+
+ // Split out language links
+ $iwLocalPrefixes = [];
+ $iwLanguagePrefixes = [];
+ foreach ( $iwPrefixes as $iwPrefix ) {
+ if ( Language::fetchLanguageName( $iwPrefix['iw_prefix'] ) ) {
+ $iwLanguagePrefixes[] = $iwPrefix;
+ } else {
+ $iwLocalPrefixes[] = $iwPrefix;
+ }
+ }
+
+ // Page intro content
+ $this->getOutput()->addWikiMsg( 'interwiki_intro' );
+
+ // Add 'view log' link when possible
+ if ( $wgInterwikiViewOnly === false ) {
+ $logLink = Linker::link(
+ SpecialPage::getTitleFor( 'Log', 'interwiki' ),
+ $this->msg( 'interwiki-logtext' )->escaped()
+ );
+ $this->getOutput()->addHTML( '<p class="mw-interwiki-log">' . $logLink . '</p>' );
+ }
+
+ // Add 'add' link
+ if ( $canModify ) {
+ if ( count( $iwGlobalPrefixes ) !== 0 ) {
+ $addtext = $this->msg( 'interwiki-addtext-local' )->escaped();
+ } else {
+ $addtext = $this->msg( 'interwiki_addtext' )->escaped();
+ }
+ $addlink = Linker::linkKnown( $this->getPageTitle( 'add' ), $addtext );
+ $this->getOutput()->addHTML( '<p class="mw-interwiki-addlink">' . $addlink . '</p>' );
+ }
+
+ $this->getOutput()->addWikiMsg( 'interwiki-legend' );
+
+ if ( ( !is_array( $iwPrefixes ) || count( $iwPrefixes ) === 0 ) &&
+ ( !is_array( $iwGlobalPrefixes ) || count( $iwGlobalPrefixes ) === 0 )
+ ) {
+ // If the interwiki table(s) are empty, display an error message
+ $this->error( 'interwiki_error' );
+ return;
+ }
+
+ // Add the global table
+ if ( count( $iwGlobalPrefixes ) !== 0 ) {
+ $this->getOutput()->addHTML(
+ '<h2 id="interwikitable-global">' .
+ $this->msg( 'interwiki-global-links' )->parse() .
+ '</h2>'
+ );
+ $this->getOutput()->addWikiMsg( 'interwiki-global-description' );
+
+ // $canModify is false here because this is just a display of remote data
+ $this->makeTable( false, $iwGlobalPrefixes );
+ }
+
+ // Add the local table
+ if ( count( $iwLocalPrefixes ) !== 0 ) {
+ if ( count( $iwGlobalPrefixes ) !== 0 ) {
+ $this->getOutput()->addHTML(
+ '<h2 id="interwikitable-local">' .
+ $this->msg( 'interwiki-local-links' )->parse() .
+ '</h2>'
+ );
+ $this->getOutput()->addWikiMsg( 'interwiki-local-description' );
+ } else {
+ $this->getOutput()->addHTML(
+ '<h2 id="interwikitable-local">' .
+ $this->msg( 'interwiki-links' )->parse() .
+ '</h2>'
+ );
+ $this->getOutput()->addWikiMsg( 'interwiki-description' );
+ }
+ $this->makeTable( $canModify, $iwLocalPrefixes );
+ }
+
+ // Add the language table
+ if ( count( $iwLanguagePrefixes ) !== 0 ) {
+ $this->getOutput()->addHTML(
+ '<h2 id="interwikitable-language">' .
+ $this->msg( 'interwiki-language-links' )->parse() .
+ '</h2>'
+ );
+ $this->getOutput()->addWikiMsg( 'interwiki-language-description' );
+
+ $this->makeTable( $canModify, $iwLanguagePrefixes );
+ }
+ }
+
+ protected function makeTable( $canModify, $iwPrefixes ) {
+ // Output the existing Interwiki prefixes table header
+ $out = '';
+ $out .= Html::openElement(
+ 'table',
+ [ 'class' => 'mw-interwikitable wikitable sortable body' ]
+ ) . "\n";
+ $out .= Html::openElement( 'tr', [ 'class' => 'interwikitable-header' ] ) .
+ Html::element( 'th', null, $this->msg( 'interwiki_prefix' )->text() ) .
+ Html::element( 'th', null, $this->msg( 'interwiki_url' )->text() ) .
+ Html::element( 'th', null, $this->msg( 'interwiki_local' )->text() ) .
+ Html::element( 'th', null, $this->msg( 'interwiki_trans' )->text() ) .
+ ( $canModify ?
+ Html::element(
+ 'th',
+ [ 'class' => 'unsortable' ],
+ $this->msg( 'interwiki_edit' )->text()
+ ) :
+ ''
+ );
+ $out .= Html::closeElement( 'tr' ) . "\n";
+
+ $selfTitle = $this->getPageTitle();
+
+ // Output the existing Interwiki prefixes table rows
+ foreach ( $iwPrefixes as $iwPrefix ) {
+ $out .= Html::openElement( 'tr', [ 'class' => 'mw-interwikitable-row' ] );
+ $out .= Html::element( 'td', [ 'class' => 'mw-interwikitable-prefix' ],
+ $iwPrefix['iw_prefix'] );
+ $out .= Html::element(
+ 'td',
+ [ 'class' => 'mw-interwikitable-url' ],
+ $iwPrefix['iw_url']
+ );
+ $attribs = [ 'class' => 'mw-interwikitable-local' ];
+ // Green background for cells with "yes".
+ if ( isset( $iwPrefix['iw_local'] ) && $iwPrefix['iw_local'] ) {
+ $attribs['class'] .= ' mw-interwikitable-local-yes';
+ }
+ // The messages interwiki_0 and interwiki_1 are used here.
+ $contents = isset( $iwPrefix['iw_local'] ) ?
+ $this->msg( 'interwiki_' . $iwPrefix['iw_local'] )->text() :
+ '-';
+ $out .= Html::element( 'td', $attribs, $contents );
+ $attribs = [ 'class' => 'mw-interwikitable-trans' ];
+ // Green background for cells with "yes".
+ if ( isset( $iwPrefix['iw_trans'] ) && $iwPrefix['iw_trans'] ) {
+ $attribs['class'] .= ' mw-interwikitable-trans-yes';
+ }
+ // The messages interwiki_0 and interwiki_1 are used here.
+ $contents = isset( $iwPrefix['iw_trans'] ) ?
+ $this->msg( 'interwiki_' . $iwPrefix['iw_trans'] )->text() :
+ '-';
+ $out .= Html::element( 'td', $attribs, $contents );
+
+ // Additional column when the interwiki table can be modified.
+ if ( $canModify ) {
+ $out .= Html::rawElement( 'td', [ 'class' => 'mw-interwikitable-modify' ],
+ Linker::linkKnown( $selfTitle, $this->msg( 'edit' )->escaped(), [],
+ [ 'action' => 'edit', 'prefix' => $iwPrefix['iw_prefix'] ] ) .
+ $this->msg( 'comma-separator' ) .
+ Linker::linkKnown( $selfTitle, $this->msg( 'delete' )->escaped(), [],
+ [ 'action' => 'delete', 'prefix' => $iwPrefix['iw_prefix'] ] )
+ );
+ }
+ $out .= Html::closeElement( 'tr' ) . "\n";
+ }
+ $out .= Html::closeElement( 'table' );
+
+ $this->getOutput()->addHTML( $out );
+ }
+
+ protected function error() {
+ $args = func_get_args();
+ $this->getOutput()->wrapWikiMsg( "<p class='error'>$1</p>", $args );
+ }
+
+ protected function getGroupName() {
+ return 'wiki';
+ }
+}
diff --git a/www/wiki/extensions/Interwiki/tests/phan/config.php b/www/wiki/extensions/Interwiki/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/Interwiki/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/LocalisationUpdate/Gruntfile.js b/www/wiki/extensions/LocalisationUpdate/Gruntfile.js
index e4033e51..26ca0c16 100644
--- a/www/wiki/extensions/LocalisationUpdate/Gruntfile.js
+++ b/www/wiki/extensions/LocalisationUpdate/Gruntfile.js
@@ -17,7 +17,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/LocalisationUpdate/composer.json b/www/wiki/extensions/LocalisationUpdate/composer.json
index 9a88cee5..e49e334b 100644
--- a/www/wiki/extensions/LocalisationUpdate/composer.json
+++ b/www/wiki/extensions/LocalisationUpdate/composer.json
@@ -8,7 +8,7 @@
"localization"
],
"homepage": "https://www.mediawiki.org/wiki/Extension:LocalisationUpdate",
- "license": "GPL-2.0+",
+ "license": "GPL-2.0-or-later",
"authors": [
{
"name": "Roan Kattouw",
@@ -32,17 +32,24 @@
"wiki": "https://www.mediawiki.org/wiki/Extension:LocalisationUpdate"
},
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
"fix": [
- "phpcbf"
+ "phpcbf",
+ "minus-x fix ."
],
"test": [
- "parallel-lint . --exclude vendor",
- "phpcs -p -s"
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/LocalisationUpdate/extension.json b/www/wiki/extensions/LocalisationUpdate/extension.json
index 5d82b8a1..901f66fc 100644
--- a/www/wiki/extensions/LocalisationUpdate/extension.json
+++ b/www/wiki/extensions/LocalisationUpdate/extension.json
@@ -10,7 +10,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:LocalisationUpdate",
"descriptionmsg": "localisationupdate-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "other",
"MessagesDirs": {
"LocalisationUpdate": [
@@ -18,19 +18,19 @@
]
},
"AutoloadClasses": {
- "LocalisationUpdate": "LocalisationUpdate.class.php",
- "LocalisationUpdate\\Updater": "Updater.php",
- "QuickArrayReader": "QuickArrayReader.php",
- "LocalisationUpdate\\Fetcher": "fetcher/Fetcher.php",
- "LocalisationUpdate\\FetcherFactory": "fetcher/FetcherFactory.php",
- "LocalisationUpdate\\FileSystemFetcher": "fetcher/FileSystemFetcher.php",
- "LocalisationUpdate\\GitHubFetcher": "fetcher/GitHubFetcher.php",
- "LocalisationUpdate\\HttpFetcher": "fetcher/HttpFetcher.php",
- "LocalisationUpdate\\Finder": "finder/Finder.php",
- "LocalisationUpdate\\JSONReader": "reader/JSONReader.php",
- "LocalisationUpdate\\PHPReader": "reader/PHPReader.php",
- "LocalisationUpdate\\Reader": "reader/Reader.php",
- "LocalisationUpdate\\ReaderFactory": "reader/ReaderFactory.php"
+ "LocalisationUpdate": "includes/LocalisationUpdate.php",
+ "LocalisationUpdate\\Updater": "includes/Updater.php",
+ "QuickArrayReader": "includes/QuickArrayReader.php",
+ "LocalisationUpdate\\Fetcher": "includes/fetcher/Fetcher.php",
+ "LocalisationUpdate\\FetcherFactory": "includes/fetcher/FetcherFactory.php",
+ "LocalisationUpdate\\FileSystemFetcher": "includes/fetcher/FileSystemFetcher.php",
+ "LocalisationUpdate\\GitHubFetcher": "includes/fetcher/GitHubFetcher.php",
+ "LocalisationUpdate\\HttpFetcher": "includes/fetcher/HttpFetcher.php",
+ "LocalisationUpdate\\Finder": "includes/finder/Finder.php",
+ "LocalisationUpdate\\JSONReader": "includes/reader/JSONReader.php",
+ "LocalisationUpdate\\PHPReader": "includes/reader/PHPReader.php",
+ "LocalisationUpdate\\Reader": "includes/reader/Reader.php",
+ "LocalisationUpdate\\ReaderFactory": "includes/reader/ReaderFactory.php"
},
"Hooks": {
"LocalisationCacheRecache": [
diff --git a/www/wiki/extensions/LocalisationUpdate/i18n/ca.json b/www/wiki/extensions/LocalisationUpdate/i18n/ca.json
index d37e93a9..4b4ac0af 100644
--- a/www/wiki/extensions/LocalisationUpdate/i18n/ca.json
+++ b/www/wiki/extensions/LocalisationUpdate/i18n/ca.json
@@ -1,8 +1,9 @@
{
"@metadata": {
"authors": [
- "Paucabot"
+ "Paucabot",
+ "Fitoschido"
]
},
- "localisationupdate-desc": "Manté els missatges localitzats tan actualitzats com sigui possible"
+ "localisationupdate-desc": "Manté els missatges traduïts tan actualitzats com sigui possible"
}
diff --git a/www/wiki/extensions/LocalisationUpdate/i18n/es.json b/www/wiki/extensions/LocalisationUpdate/i18n/es.json
index 2526e852..aea82b47 100644
--- a/www/wiki/extensions/LocalisationUpdate/i18n/es.json
+++ b/www/wiki/extensions/LocalisationUpdate/i18n/es.json
@@ -1,8 +1,9 @@
{
"@metadata": {
"authors": [
- "Crazymadlover"
+ "Crazymadlover",
+ "Fitoschido"
]
},
- "localisationupdate-desc": "Mantiene los mensajes localizados tan actualizados como sea posible"
+ "localisationupdate-desc": "Mantiene los mensajes traducidos tan actualizados como sea posible"
}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/LocalisationUpdate.php b/www/wiki/extensions/LocalisationUpdate/includes/LocalisationUpdate.php
new file mode 100644
index 00000000..a0b5f044
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/LocalisationUpdate.php
@@ -0,0 +1,73 @@
+<?php
+
+/**
+ * Class for localization update hooks and static methods.
+ */
+class LocalisationUpdate {
+ /**
+ * Hook: LocalisationCacheRecacheFallback
+ * @param LocalisationCache $lc
+ * @param string $code
+ * @param array &$cache
+ * @return true
+ */
+ public static function onRecacheFallback( LocalisationCache $lc, $code, array &$cache ) {
+ $dir = self::getDirectory();
+ if ( !$dir ) {
+ return true;
+ }
+
+ $fileName = "$dir/" . self::getFilename( $code );
+ if ( is_readable( $fileName ) ) {
+ $data = FormatJson::decode( file_get_contents( $fileName ), true );
+ $cache['messages'] = array_merge( $cache['messages'], $data );
+ }
+
+ return true;
+ }
+
+ /**
+ * Hook: LocalisationCacheRecache
+ * @param LocalisationCache $lc
+ * @param string $code
+ * @param array &$cache
+ * @return true
+ */
+ public static function onRecache( LocalisationCache $lc, $code, array &$cache ) {
+ $dir = self::getDirectory();
+ if ( !$dir ) {
+ return true;
+ }
+
+ $codeSequence = array_merge( [ $code ], $cache['fallbackSequence'] );
+ foreach ( $codeSequence as $csCode ) {
+ $fileName = "$dir/" . self::getFilename( $csCode );
+ $cache['deps'][] = new FileDependency( $fileName );
+ }
+
+ return true;
+ }
+
+ /**
+ * Returns a directory where updated translations are stored.
+ *
+ * @return string|false False if not configured.
+ * @since 1.1
+ */
+ public static function getDirectory() {
+ global $wgLocalisationUpdateDirectory, $wgCacheDirectory;
+
+ return $wgLocalisationUpdateDirectory ?: $wgCacheDirectory;
+ }
+
+ /**
+ * Returns a filename where updated translations are stored.
+ *
+ * @param string $language Language tag
+ * @return string
+ * @since 1.1
+ */
+ public static function getFilename( $language ) {
+ return "l10nupdate-$language.json";
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/QuickArrayReader.php b/www/wiki/extensions/LocalisationUpdate/includes/QuickArrayReader.php
new file mode 100644
index 00000000..0314ee68
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/QuickArrayReader.php
@@ -0,0 +1,214 @@
+<?php
+
+/**
+ * Quickie parser class that can happily read the subset of PHP we need
+ * for our localization arrays safely.
+ *
+ * Still an order of magnitude slower than eval().
+ */
+class QuickArrayReader {
+ private $vars = [];
+
+ /**
+ * @param string $string
+ */
+ function __construct( $string ) {
+ $scalarTypes = [
+ T_LNUMBER => true,
+ T_DNUMBER => true,
+ T_STRING => true,
+ T_CONSTANT_ENCAPSED_STRING => true,
+ ];
+ $skipTypes = [
+ T_WHITESPACE => true,
+ T_COMMENT => true,
+ T_DOC_COMMENT => true,
+ ];
+ $tokens = token_get_all( $string );
+ $count = count( $tokens );
+ for ( $i = 0; $i < $count; ) {
+ while ( isset( $skipTypes[$tokens[$i][0]] ) ) {
+ $i++;
+ }
+ switch ( $tokens[$i][0] ) {
+ case T_OPEN_TAG:
+ $i++;
+ break;
+ case T_VARIABLE:
+ // '$messages' -> 'messages'
+ $varname = trim( substr( $tokens[$i][1], 1 ) );
+ $varindex = null;
+
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( $tokens[$i] === '[' ) {
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( isset( $scalarTypes[$tokens[$i][0]] ) ) {
+ $varindex = $this->parseScalar( $tokens[$i] );
+ } else {
+ throw $this->except( $tokens[$i], 'scalar index' );
+ }
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( $tokens[$i] !== ']' ) {
+ throw $this->except( $tokens[$i], ']' );
+ }
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+ }
+
+ if ( $tokens[$i] !== '=' ) {
+ throw $this->except( $tokens[$i], '=' );
+ }
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( isset( $scalarTypes[$tokens[$i][0]] ) ) {
+ $buildval = $this->parseScalar( $tokens[$i] );
+ } elseif ( $tokens[$i][0] === T_ARRAY ) {
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+ if ( $tokens[$i] !== '(' ) {
+ throw $this->except( $tokens[$i], '(' );
+ }
+ $buildval = [];
+ do {
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( $tokens[$i] === ')' ) {
+ break;
+ }
+ if ( isset( $scalarTypes[$tokens[$i][0]] ) ) {
+ $key = $this->parseScalar( $tokens[$i] );
+ }
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( $tokens[$i][0] !== T_DOUBLE_ARROW ) {
+ throw $this->except( $tokens[$i], '=>' );
+ }
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( isset( $scalarTypes[$tokens[$i][0]] ) ) {
+ $val = $this->parseScalar( $tokens[$i] );
+ }
+ wfSuppressWarnings();
+ $buildval[$key] = $val;
+ wfRestoreWarnings();
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+
+ if ( $tokens[$i] === ',' ) {
+ continue;
+ } elseif ( $tokens[$i] === ')' ) {
+ break;
+ } else {
+ throw $this->except( $tokens[$i], ', or )' );
+ }
+ } while ( true );
+ } else {
+ throw $this->except( $tokens[$i], 'scalar or array' );
+ }
+ if ( is_null( $varindex ) ) {
+ $this->vars[$varname] = $buildval;
+ } else {
+ wfSuppressWarnings();
+ $this->vars[$varname][$varindex] = $buildval;
+ wfRestoreWarnings();
+ }
+ while ( isset( $skipTypes[$tokens[++$i][0]] ) ) {
+ }
+ if ( $tokens[$i] !== ';' ) {
+ throw $this->except( $tokens[$i], ';' );
+ }
+ $i++;
+ break;
+ default:
+ throw $this->except( $tokens[$i], 'open tag, whitespace, or variable.' );
+ }
+ }
+ }
+
+ /**
+ * @param string $got
+ * @param string $expected
+ * @return Exception
+ */
+ private function except( $got, $expected ) {
+ if ( is_array( $got ) ) {
+ $got = token_name( $got[0] ) . " ('" . $got[1] . "')";
+ } else {
+ $got = "'" . $got . "'";
+ }
+
+ return new Exception( "Expected $expected, got $got" );
+ }
+
+ /**
+ * Parse a scalar value in PHP
+ *
+ * @param string $token
+ *
+ * @return mixed Parsed value
+ */
+ function parseScalar( $token ) {
+ if ( is_array( $token ) ) {
+ $str = $token[1];
+ } else {
+ $str = $token;
+ }
+ if ( $str !== '' && $str[0] == '\'' ) {
+ // Single-quoted string
+ // @fixme trim() call is due to mystery bug where whitespace gets
+ // appended to the token; without it we ended up reading in the
+ // extra quote on the end!
+ return strtr( substr( trim( $str ), 1, -1 ),
+ [ '\\\'' => '\'', '\\\\' => '\\' ] );
+ }
+
+ wfSuppressWarnings();
+ if ( $str !== '' && $str[0] == '"' ) {
+ // Double-quoted string
+ // @fixme trim() call is due to mystery bug where whitespace gets
+ // appended to the token; without it we ended up reading in the
+ // extra quote on the end!
+ wfRestoreWarnings();
+ return stripcslashes( substr( trim( $str ), 1, -1 ) );
+ }
+ wfRestoreWarnings();
+
+ if ( substr( $str, 0, 4 ) === 'true' ) {
+ return true;
+ }
+
+ if ( substr( $str, 0, 5 ) === 'false' ) {
+ return false;
+ }
+
+ if ( substr( $str, 0, 4 ) === 'null' ) {
+ return null;
+ }
+
+ // Must be some kind of numeric value, so let PHP's weak typing
+ // be useful for a change
+ return $str;
+ }
+
+ /**
+ * @param string $varname
+ * @return null|string|array
+ */
+ function getVar( $varname ) {
+ if ( isset( $this->vars[$varname] ) ) {
+ return $this->vars[$varname];
+ } else {
+ return null;
+ }
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/Updater.php b/www/wiki/extensions/LocalisationUpdate/includes/Updater.php
new file mode 100644
index 00000000..863dc04a
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/Updater.php
@@ -0,0 +1,204 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Executes the localisation update.
+ */
+class Updater {
+ /**
+ * Whether the path is a pattern and thus we need to use appropriate
+ * code for fetching directories.
+ *
+ * @param string $path Url
+ * @return bool
+ */
+ public function isDirectory( $path ) {
+ $filename = basename( $path );
+ return strpos( $filename, '*' ) !== false;
+ }
+
+ /**
+ * Expands repository relative path to full url with the given repository
+ * patterns. Extra variables in $info are used as variables and will be
+ * replaced the pattern.
+ *
+ * @param array $info Component information.
+ * @param array $repos Repository information.
+ * @return string
+ */
+ public function expandRemotePath( $info, $repos ) {
+ $pattern = $repos[$info['repo']];
+ unset( $info['repo'], $info['orig'] );
+
+ // This assumes all other keys are used as variables
+ // in the pattern. For example name -> %NAME%.
+ $keys = [];
+ foreach ( array_keys( $info ) as $key ) {
+ $keys[] = '%' . strtoupper( $key ) . '%';
+ }
+
+ $values = array_values( $info );
+ return str_replace( $keys, $values, $pattern );
+ }
+
+ /**
+ * Parses translations from given list of files.
+ *
+ * @param ReaderFactory $readerFactory Factory to construct parsers.
+ * @param array $files List of files with their contents as array values.
+ * @return array List of translations indexed by language code.
+ */
+ public function readMessages( ReaderFactory $readerFactory, array $files ) {
+ $messages = [];
+
+ foreach ( $files as $filename => $contents ) {
+ $reader = $readerFactory->getReader( $filename );
+ try {
+ $parsed = $reader->parse( $contents );
+ } catch ( \Exception $e ) {
+ trigger_error( __METHOD__ . ": Unable to parse messages from $filename", E_USER_WARNING );
+ continue;
+ }
+
+ foreach ( $parsed as $code => $langMessages ) {
+ if ( !isset( $messages[$code] ) ) {
+ $messages[$code] = [];
+ }
+ $messages[$code] = array_merge( $messages[$code], $langMessages );
+ }
+
+ $c = array_sum( array_map( 'count', $parsed ) );
+ // Useful for debugging, maybe create interface to pass this to the script?
+ # echo "$filename with " . get_class( $reader ) . " and $c\n";
+ }
+
+ return $messages;
+ }
+
+ /**
+ * Find new and changed translations in $remote and returns them.
+ *
+ * @param array $origin
+ * @param array $remote
+ * @param array $blacklist Array of message keys to ignore, keys as as array keys.
+ * @return array
+ */
+ public function findChangedTranslations( $origin, $remote, $blacklist = [] ) {
+ $changed = [];
+ foreach ( $remote as $key => $value ) {
+ if ( isset( $blacklist[$key] ) ) {
+ continue;
+ }
+
+ if ( !isset( $origin[$key] ) || $value !== $origin[$key] ) {
+ $changed[$key] = $value;
+ }
+ }
+ return $changed;
+ }
+
+ /**
+ * Fetches files from given Url pattern.
+ *
+ * @param FetcherFactory $factory Factory to construct fetchers.
+ * @param string $path Url to the file or pattern of files.
+ * @return array List of Urls with file contents as path.
+ */
+ public function fetchFiles( FetcherFactory $factory, $path ) {
+ $fetcher = $factory->getFetcher( $path );
+
+ if ( $this->isDirectory( $path ) ) {
+ $files = $fetcher->fetchDirectory( $path );
+ } else {
+ $files = [ $path => $fetcher->fetchFile( $path ) ];
+ }
+
+ // Remove files which were not found
+ return array_filter( $files );
+ }
+
+ public function execute(
+ Finder $finder,
+ ReaderFactory $readerFactory,
+ FetcherFactory $fetcherFactory,
+ array $repos,
+ $logger
+ ) {
+ $components = $finder->getComponents();
+
+ $updatedMessages = [];
+
+ foreach ( $components as $key => $info ) {
+ $logger->logInfo( "Updating component $key" );
+
+ $originFiles = $this->fetchFiles( $fetcherFactory, $info['orig'] );
+ $remotePath = $this->expandRemotePath( $info, $repos );
+ try {
+ $remoteFiles = $this->fetchFiles( $fetcherFactory, $remotePath );
+ } catch ( \Exception $e ) {
+ $logger->logError( __METHOD__ . ": Unable to fetch messages from $remotePath" );
+ continue;
+ }
+
+ if ( $remoteFiles === [] ) {
+ // Small optimization: if nothing to compare with, skip
+ continue;
+ }
+
+ $originMessages = $this->readMessages( $readerFactory, $originFiles );
+ $remoteMessages = $this->readMessages( $readerFactory, $remoteFiles );
+
+ if ( !isset( $remoteMessages['en'] ) ) {
+ // Could not find remote messages
+ continue;
+ }
+
+ // If remote translation in English is not present or differs, we do not want
+ // translations for other languages for those messages, as they are either not
+ // used in this version of code or can be incompatible.
+ $forbiddenKeys = $this->findChangedTranslations(
+ $originMessages['en'],
+ $remoteMessages['en']
+ );
+
+ // We never accept updates for English strings
+ unset( $originMessages['en'], $remoteMessages['en'] );
+
+ // message: string in all languages; translation: string in one language.
+ foreach ( $remoteMessages as $language => $remoteTranslations ) {
+ // Check for completely new languages
+ $originTranslations = [];
+ if ( isset( $originMessages[$language] ) ) {
+ $originTranslations = $originMessages[$language];
+ }
+
+ $updatedTranslations = $this->findChangedTranslations(
+ $originTranslations,
+ $remoteTranslations,
+ $forbiddenKeys
+ );
+
+ // Avoid empty arrays
+ if ( $updatedTranslations === [] ) {
+ continue;
+ }
+
+ if ( !isset( $updatedMessages[$language] ) ) {
+ $updatedMessages[$language] = [];
+ }
+
+ // In case of conflicts, which should not exist, this prefers the
+ // first translation seen.
+ $updatedMessages[$language] += $updatedTranslations;
+ }
+ }
+
+ return $updatedMessages;
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/fetcher/Fetcher.php b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/Fetcher.php
new file mode 100644
index 00000000..62febac8
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/Fetcher.php
@@ -0,0 +1,30 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Interface for classes which fetch files over different protocols and ways.
+ */
+interface Fetcher {
+ /**
+ * Fetches a single resource.
+ *
+ * @param string $url
+ * @return bool|string False on failure.
+ */
+ public function fetchFile( $url );
+
+ /**
+ * Fetch a list of resources. This has the benefit of being able to pick up
+ * new languages as they appear if languages are stored in separate files.
+ *
+ * @param string $pattern
+ * @return array
+ */
+ public function fetchDirectory( $pattern );
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/fetcher/FetcherFactory.php b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/FetcherFactory.php
new file mode 100644
index 00000000..9273c935
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/FetcherFactory.php
@@ -0,0 +1,25 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Constructs fetchers based on the repository urls.
+ */
+class FetcherFactory {
+ public function getFetcher( $path ) {
+ if ( strpos( $path, 'https://raw.github.com/' ) === 0 ) {
+ return new GitHubFetcher();
+ } elseif ( strpos( $path, 'http://' ) === 0 ) {
+ return new HttpFetcher();
+ } elseif ( strpos( $path, 'https://' ) === 0 ) {
+ return new HttpFetcher();
+ } else {
+ return new FileSystemFetcher();
+ }
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/fetcher/FileSystemFetcher.php b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/FileSystemFetcher.php
new file mode 100644
index 00000000..43daa65d
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/FileSystemFetcher.php
@@ -0,0 +1,47 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Accesses file system directly.
+ */
+class FileSystemFetcher implements Fetcher {
+ /**
+ * @param string $url
+ *
+ * @return bool|string
+ */
+ public function fetchFile( $url ) {
+ // Remove the protocol prefix
+ $url = preg_replace( '~^file://~', '', $url );
+
+ if ( !is_readable( $url ) ) {
+ return false;
+ }
+
+ return file_get_contents( $url );
+ }
+
+ /**
+ * @param string $pattern
+ *
+ * @return array
+ */
+ public function fetchDirectory( $pattern ) {
+ // Remove the protocol prefix
+ $pattern = preg_replace( '~^file://~', '', $pattern );
+
+ $data = [];
+ foreach ( glob( $pattern ) as $file ) {
+ if ( is_readable( $file ) ) {
+ $data["file://$file"] = file_get_contents( $file );
+ }
+ }
+ return $data;
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/fetcher/GitHubFetcher.php b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/GitHubFetcher.php
new file mode 100644
index 00000000..f8bea9c1
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/GitHubFetcher.php
@@ -0,0 +1,47 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * This class uses GitHub api to obtain a list of files present in a directory
+ * to avoid fetching files that don't exist.
+ *
+ * @todo Could use file hashes to 1) avoid fetching files with same hash as
+ * the source. 2) avoid fetching files which haven't changed since last check
+ * if we store them.
+ */
+class GitHubFetcher extends HttpFetcher {
+ /**
+ * @param string $pattern
+ *
+ * @return array
+ * @throws \Exception
+ */
+ public function fetchDirectory( $pattern ) {
+ $domain = preg_quote( 'https://raw.github.com/', '~' );
+ $p = "~^$domain(?P<org>[^/]+)/(?P<repo>[^/]+)/(?P<branch>[^/]+)/(?P<path>.+)/.+$~";
+ preg_match( $p, $pattern, $m );
+
+ $apiURL = "https://api.github.com/repos/{$m['org']}/{$m['repo']}/contents/{$m['path']}";
+ $json = \Http::get( $apiURL );
+ if ( !$json ) {
+ throw new \Exception( "Unable to get directory listing for {$m['org']}/{$m['repo']}" );
+ }
+
+ $files = [];
+ $json = \FormatJson::decode( $json, true );
+ foreach ( $json as $fileinfo ) {
+ $fileurl = dirname( $pattern ) . '/' . $fileinfo['name'];
+ $file = $this->fetchFile( $fileurl );
+ if ( $file ) {
+ $files[$fileurl] = $file;
+ }
+ }
+ return $files;
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/fetcher/HttpFetcher.php b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/HttpFetcher.php
new file mode 100644
index 00000000..72988e98
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/fetcher/HttpFetcher.php
@@ -0,0 +1,49 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Fetches files over HTTP(s).
+ */
+class HttpFetcher implements Fetcher {
+ /**
+ * @param string $url
+ *
+ * @return bool|string
+ */
+ public function fetchFile( $url ) {
+ return \Http::get( $url );
+ }
+
+ /**
+ * This is horribly inefficient. Subclasses have more efficient
+ * implementation of this.
+ * @param string $pattern
+ * @return array
+ */
+ public function fetchDirectory( $pattern ) {
+ $files = [];
+
+ $languages = \Language::fetchLanguageNames( null, 'mwfile' );
+
+ foreach ( array_keys( $languages ) as $code ) {
+ // Hack for core
+ if ( strpos( $pattern, 'Messages*.php' ) !== false ) {
+ $code = ucfirst( strtr( $code, '-', '_' ) );
+ }
+
+ $url = str_replace( '*', $code, $pattern );
+ $file = $this->fetchFile( $url );
+ if ( $file ) {
+ $files[$url] = $file;
+ }
+ }
+
+ return $files;
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/finder/Finder.php b/www/wiki/extensions/LocalisationUpdate/includes/finder/Finder.php
new file mode 100644
index 00000000..acebc42a
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/finder/Finder.php
@@ -0,0 +1,124 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Interface for classes which provide list of components, which should be
+ * included for l10n updates.
+ */
+class Finder {
+
+ /**
+ * @var array
+ */
+ private $php;
+
+ /**
+ * @var array
+ */
+ private $json;
+
+ /**
+ * @var string
+ */
+ private $core;
+ /**
+ * @param array $php See $wgExtensionMessagesFiles
+ * @param array $json See $wgMessagesDirs
+ * @param string $core Absolute path to MediaWiki core
+ */
+ public function __construct( $php, $json, $core ) {
+ $this->php = $php;
+ $this->json = $json;
+ $this->core = $core;
+ }
+
+ /**
+ * @return array
+ */
+ public function getComponents() {
+ $components = [];
+
+ // For older versions of Mediawiki, pull json updates even though its still using php
+ if ( !isset( $this->json['core'] ) ) {
+ $components['core'] = [
+ 'repo' => 'mediawiki',
+ 'orig' => "file://{$this->core}/languages/messages/Messages*.php",
+ 'path' => 'languages/messages/i18n/*.json',
+ ];
+ }
+
+ foreach ( $this->json as $key => $value ) {
+ // Json should take priority if both exist
+ unset( $this->php[$key] );
+
+ foreach ( (array)$value as $subkey => $subvalue ) {
+ // Mediawiki core files
+ $matches = [];
+ if ( preg_match( '~/(?P<path>(?:includes|languages|resources)/.*)$~', $subvalue, $matches ) ) {
+ $components["$key-$subkey"] = [
+ 'repo' => 'mediawiki',
+ 'orig' => "file://$value/*.json",
+ 'path' => "{$matches['path']}/*.json",
+ ];
+ continue;
+ }
+
+ $item = $this->getItem( 'extensions', $subvalue );
+ if ( $item !== null ) {
+ $item['repo'] = 'extension';
+ $components["$key-$subkey"] = $item;
+ continue;
+ }
+
+ $item = $this->getItem( 'skins', $subvalue );
+ if ( $item !== null ) {
+ $item['repo'] = 'skin';
+ $components["$key-$subkey"] = $item;
+ continue;
+ }
+ }
+ }
+
+ foreach ( $this->php as $key => $value ) {
+ $matches = [];
+ $ok = preg_match( '~/extensions/(?P<name>[^/]+)/(?P<path>.*\.i18n\.php)$~', $value, $matches );
+ if ( !$ok ) {
+ continue;
+ }
+
+ $components[$key] = [
+ 'repo' => 'extension',
+ 'name' => $matches['name'],
+ 'orig' => "file://$value",
+ 'path' => $matches['path'],
+ ];
+ }
+
+ return $components;
+ }
+
+ /**
+ * @param string $dir extensions or skins
+ * @param string $subvalue
+ * @return array|null
+ */
+ private function getItem( $dir, $subvalue ) {
+ // This ignores magic, alias etc. non message files
+ $matches = [];
+ if ( !preg_match( "~/$dir/(?P<name>[^/]+)/(?P<path>.*)$~", $subvalue, $matches ) ) {
+ return null;
+ }
+
+ return [
+ 'name' => $matches['name'],
+ 'orig' => "file://$subvalue/*.json",
+ 'path' => "{$matches['path']}/*.json",
+ ];
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/reader/JSONReader.php b/www/wiki/extensions/LocalisationUpdate/includes/reader/JSONReader.php
new file mode 100644
index 00000000..e8613660
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/reader/JSONReader.php
@@ -0,0 +1,37 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Reads MediaWiki JSON i18n files.
+ */
+class JSONReader implements Reader {
+ /// @var string Language tag
+ protected $code;
+
+ public function __construct( $code = null ) {
+ $this->code = $code;
+ }
+
+ /**
+ * @param string $contents
+ *
+ * @return array
+ */
+ public function parse( $contents ) {
+ $messages = \FormatJson::decode( $contents, true );
+ unset( $messages['@metadata'] );
+
+ if ( $this->code ) {
+ return [ $this->code => $messages ];
+ }
+
+ // Assuming that the array is keyed by language codes
+ return $messages;
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/reader/PHPReader.php b/www/wiki/extensions/LocalisationUpdate/includes/reader/PHPReader.php
new file mode 100644
index 00000000..43e4db25
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/reader/PHPReader.php
@@ -0,0 +1,61 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Reads MediaWiki PHP i18n files.
+ */
+class PHPReader implements Reader {
+ /// @var string Language tag
+ protected $code;
+
+ public function __construct( $code = null ) {
+ $this->code = $code;
+ }
+
+ /**
+ * @param string $contents
+ *
+ * @return array
+ */
+ public function parse( $contents ) {
+ if ( strpos( $contents, '$messages' ) === false ) {
+ // This happens for some core languages that only have a fallback.
+ return [];
+ }
+
+ $php = $this->cleanupFile( $contents );
+ $reader = new \QuickArrayReader( "<?php $php" );
+ $messages = $reader->getVar( 'messages' );
+
+ if ( $this->code ) {
+ return [ $this->code => $messages ];
+ }
+
+ // Assuming that the array is keyed by language codes
+ return $messages;
+ }
+
+ /**
+ * Removes all unneeded content from a file and returns it.
+ *
+ * @param string $contents String
+ * @return string PHP code without PHP tags
+ */
+ protected function cleanupFile( $contents ) {
+ // We hate the windows vs linux linebreaks.
+ $contents = preg_replace( '/\r\n?/', "\n", $contents );
+
+ // We only want message arrays.
+ $results = [];
+ preg_match_all( '/\$messages(?:.*\s)*?\);/', $contents, $results );
+
+ // But we want them all in one string.
+ return implode( "\n\n", $results[0] );
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/reader/Reader.php b/www/wiki/extensions/LocalisationUpdate/includes/reader/Reader.php
new file mode 100644
index 00000000..fd37322e
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/reader/Reader.php
@@ -0,0 +1,21 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Interface for file readers.
+ */
+interface Reader {
+ /**
+ * Returns a list of messages indexed by language code. Example
+ * array( 'en' => array( 'key' => 'value' ) );
+ * @param string $contents File contents as a string.
+ * @return array
+ */
+ public function parse( $contents );
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/includes/reader/ReaderFactory.php b/www/wiki/extensions/LocalisationUpdate/includes/reader/ReaderFactory.php
new file mode 100644
index 00000000..44bc5e40
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/includes/reader/ReaderFactory.php
@@ -0,0 +1,38 @@
+<?php
+/**
+ * @file
+ * @author Niklas Laxström
+ * @license GPL-2.0-or-later
+ */
+
+namespace LocalisationUpdate;
+
+/**
+ * Constructs readers for files based on the names.
+ */
+class ReaderFactory {
+ /**
+ * Constructs a suitable reader for a given path.
+ * @param string $filename Usually a relative path to the file name.
+ * @return Reader
+ * @throws Exception
+ */
+ public function getReader( $filename ) {
+ if ( preg_match( '/i18n\.php$/', $filename ) ) {
+ return new PHPReader();
+ }
+
+ // Ugly hack for core i18n files
+ if ( preg_match( '/Messages(.*)\.php$/', $filename ) ) {
+ $code = \Language::getCodeFromFileName( basename( $filename ), 'Messages' );
+ return new PHPReader( $code );
+ }
+
+ if ( preg_match( '/\.json/', $filename ) ) {
+ $code = basename( $filename, '.json' );
+ return new JSONReader( $code );
+ }
+
+ throw new \Exception( "Unknown file format: " . $filename );
+ }
+}
diff --git a/www/wiki/extensions/LocalisationUpdate/tests/phan/config.php b/www/wiki/extensions/LocalisationUpdate/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/LocalisationUpdate/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/UpdaterTest.php b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/UpdaterTest.php
index d3154033..00c45e12 100644
--- a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/UpdaterTest.php
+++ b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/UpdaterTest.php
@@ -2,12 +2,19 @@
/**
* @file
* @author Niklas Laxström
- * @license GPL-2.0+
+ * @license GPL-2.0-or-later
*/
namespace LocalisationUpdate;
-class UpdaterTest extends \PHPUnit_Framework_TestCase {
+use PHPUnit4And6Compat;
+
+/**
+ * @covers \LocalisationUpdate\Updater
+ */
+class UpdaterTest extends \PHPUnit\Framework\TestCase {
+ use PHPUnit4And6Compat;
+
public function testIsDirectory() {
$updater = new Updater();
diff --git a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/finder/FinderTest.php b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/finder/FinderTest.php
index 1b7d786c..1b4db0f4 100644
--- a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/finder/FinderTest.php
+++ b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/finder/FinderTest.php
@@ -2,12 +2,15 @@
/**
* @file
* @author Niklas Laxström
- * @license GPL-2.0+
+ * @license GPL-2.0-or-later
*/
namespace LocalisationUpdate;
-class FinderTest extends \PHPUnit_Framework_TestCase {
+/**
+ * @covers \LocalisationUpdate\Finder
+ */
+class FinderTest extends \PHPUnit\Framework\TestCase {
public function testGetComponents() {
$finder = new Finder(
[
diff --git a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/JSONReaderTest.php b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/JSONReaderTest.php
index bd5c0490..11f0a03b 100644
--- a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/JSONReaderTest.php
+++ b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/JSONReaderTest.php
@@ -2,12 +2,15 @@
/**
* @file
* @author Niklas Laxström
- * @license GPL-2.0+
+ * @license GPL-2.0-or-later
*/
namespace LocalisationUpdate;
-class JSONReaderTest extends \PHPUnit_Framework_TestCase {
+/**
+ * @covers \LocalisationUpdate\JSONReader
+ */
+class JSONReaderTest extends \PHPUnit\Framework\TestCase {
/**
* @dataProvider parseProvider
*/
diff --git a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/ReaderFactoryTest.php b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/ReaderFactoryTest.php
index feeb68cf..86776395 100644
--- a/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/ReaderFactoryTest.php
+++ b/www/wiki/extensions/LocalisationUpdate/tests/phpunit/reader/ReaderFactoryTest.php
@@ -2,12 +2,15 @@
/**
* @file
* @author Niklas Laxström
- * @license GPL-2.0+
+ * @license GPL-2.0-or-later
*/
namespace LocalisationUpdate;
-class ReaderFactoryTest extends \PHPUnit_Framework_TestCase {
+/**
+ * @covers \LocalisationUpdate\ReaderFactory
+ */
+class ReaderFactoryTest extends \PHPUnit\Framework\TestCase {
/**
* @dataProvider getReaderProvider
*/
diff --git a/www/wiki/extensions/LocalisationUpdate/update.php b/www/wiki/extensions/LocalisationUpdate/update.php
index 593a5258..a8ed7ead 100644
--- a/www/wiki/extensions/LocalisationUpdate/update.php
+++ b/www/wiki/extensions/LocalisationUpdate/update.php
@@ -6,7 +6,7 @@ $IP = strval( getenv( 'MW_INSTALL_PATH' ) ) !== ''
require "$IP/maintenance/Maintenance.php";
-class LU extends Maintenance {
+class Update extends Maintenance {
public function __construct() {
parent::__construct();
$this->mDescription = 'Fetches translation updates to MediaWiki core, skins and extensions.';
@@ -16,6 +16,8 @@ class LU extends Maintenance {
false, /*required*/
true /*has arg*/
);
+
+ $this->requireExtension( 'LocalisationUpdate' );
}
public function execute() {
@@ -24,9 +26,7 @@ class LU extends Maintenance {
ini_set( "max_execution_time", 0 );
ini_set( 'memory_limit', -1 );
- // @codingStandardsIgnoreStart Ignore MediaWiki.NamingConventions.ValidGlobalName.wgPrefix
global $IP;
- // @codingStandardsIgnoreEnd
global $wgExtensionMessagesFiles;
global $wgLocalisationUpdateRepositories;
global $wgLocalisationUpdateRepository;
@@ -52,13 +52,18 @@ class LU extends Maintenance {
}
$repos = $wgLocalisationUpdateRepositories[$repoid];
+ // output and error methods are protected, hence we add logInfo and logError
+ // public methods, that hopefully won't conflict in the future with the base class.
+ $logger = $this;
+
// Do it ;)
$updater = new LocalisationUpdate\Updater();
$updatedMessages = $updater->execute(
$finder,
$readerFactory,
$fetcherFactory,
- $repos
+ $repos,
+ $logger
);
// Store it ;)
@@ -74,7 +79,15 @@ class LU extends Maintenance {
}
$this->output( "Saved $count new translations\n" );
}
+
+ public function logInfo( $msg ) {
+ $this->output( $msg . "\n" );
+ }
+
+ public function logError( $msg ) {
+ $this->error( $msg );
+ }
}
-$maintClass = 'LU';
+$maintClass = Update::class;
require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/www/wiki/extensions/Maps/.gitignore b/www/wiki/extensions/Maps/.gitignore
new file mode 100644
index 00000000..5fe6d62c
--- /dev/null
+++ b/www/wiki/extensions/Maps/.gitignore
@@ -0,0 +1,13 @@
+*~
+*.kate-swp
+
+!.*
+.idea/
+
+vendor/
+extensions/
+
+composer.phar
+composer.lock
+
+phpunit.phar \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/.scrutinizer.yml b/www/wiki/extensions/Maps/.scrutinizer.yml
new file mode 100644
index 00000000..19751cec
--- /dev/null
+++ b/www/wiki/extensions/Maps/.scrutinizer.yml
@@ -0,0 +1,12 @@
+inherit: true
+
+tools:
+ external_code_coverage: true
+ php_code_sniffer: true
+ php_cpd: true
+ php_cs_fixer: true
+ php_loc: true
+ php_mess_detector: true
+ php_pdepend: true
+ php_analyzer: true
+ sensiolabs_security_checker: true
diff --git a/www/wiki/extensions/Maps/.travis.install.sh b/www/wiki/extensions/Maps/.travis.install.sh
new file mode 100644
index 00000000..0e60bf2d
--- /dev/null
+++ b/www/wiki/extensions/Maps/.travis.install.sh
@@ -0,0 +1,66 @@
+#! /bin/bash
+
+set -x
+
+originalDirectory=$(pwd)
+
+cd ..
+
+wget https://github.com/wikimedia/mediawiki-core/archive/$MW.tar.gz
+tar -zxf $MW.tar.gz
+mv mediawiki-$MW phase3
+
+cd phase3
+
+composer install --prefer-source
+
+if [ "$DB" == "postgres" ]
+then
+ psql -c 'create database its_a_mw;' -U postgres
+ php maintenance/install.php --dbtype $DBTYPE --dbuser postgres --dbname its_a_mw --pass nyan TravisWiki admin --scriptpath /TravisWiki
+else
+ mysql -e 'create database its_a_mw;'
+ php maintenance/install.php --dbtype $DBTYPE --dbuser root --dbname its_a_mw --dbpath $(pwd) --pass nyan TravisWiki admin --scriptpath /TravisWiki
+fi
+
+cd extensions
+cp -r $originalDirectory Maps
+cd Maps
+composer install --prefer-source
+cd ..
+cd ..
+
+if [ ! -z $SMW ]
+then
+ composer require "mediawiki/semantic-media-wiki=$SMW" --prefer-source
+fi
+
+cat <<EOT >> composer.local.json
+{
+ "extra": {
+ "merge-plugin": {
+ "merge-dev": true,
+ "include": [
+ "extensions/*/composer.json"
+ ]
+ }
+ }
+}
+EOT
+
+composer install --prefer-source
+
+echo 'wfLoadExtension( "Maps" );' >> LocalSettings.php
+
+if [ ! -z $SMW ]
+then
+ echo 'wfLoadExtension( "SemanticMediaWiki" );' >> LocalSettings.php
+fi
+
+echo 'error_reporting(E_ALL| E_STRICT);' >> LocalSettings.php
+echo 'ini_set("display_errors", 1);' >> LocalSettings.php
+echo '$wgShowExceptionDetails = true;' >> LocalSettings.php
+echo '$wgDevelopmentWarnings = true;' >> LocalSettings.php
+echo "putenv( 'MW_INSTALL_PATH=$(pwd)' );" >> LocalSettings.php
+
+php maintenance/update.php --quick
diff --git a/www/wiki/extensions/Maps/.travis.yml b/www/wiki/extensions/Maps/.travis.yml
new file mode 100644
index 00000000..226ea1d5
--- /dev/null
+++ b/www/wiki/extensions/Maps/.travis.yml
@@ -0,0 +1,31 @@
+language: php
+
+sudo: false
+
+matrix:
+ fast_finish: true
+ include:
+ - env: DBTYPE=mysql; MW=1.31.3
+ php: 7.1
+ - env: DBTYPE=mysql; MW=master; SMW=dev-master
+ php: 7.3
+ - env: DBTYPE=sqlite; MW=1.31.3; SMW=3.0.0
+ php: 7.1
+ - env: DBTYPE=sqlite; MW=master; TYPE=coverage
+ php: 7.2
+
+install:
+ - travis_retry composer self-update
+ - bash .travis.install.sh
+
+script: ../phase3/tests/phpunit/phpunit.php -c ../phase3/extensions/Maps/phpunit.xml.dist
+
+after_success:
+ - if [[ "$TYPE" != "coverage" ]]; then exit 0; fi
+ - ../phase3/tests/phpunit/phpunit.php -c ../phase3/extensions/Maps/phpunit.xml.dist --coverage-clover coverage.clover
+ - wget https://scrutinizer-ci.com/ocular.phar
+ - php ocular.phar code-coverage:upload --format=php-clover coverage.clover
+
+cache:
+ directories:
+ - $HOME/.composer/cache
diff --git a/www/wiki/extensions/Maps/COPYING b/www/wiki/extensions/Maps/COPYING
new file mode 100644
index 00000000..ebba08a4
--- /dev/null
+++ b/www/wiki/extensions/Maps/COPYING
@@ -0,0 +1,347 @@
+The license text below "----" applies to all files within this distribution, other
+than those that are in a directory which contains files named "LICENSE" or
+"COPYING", or a subdirectory thereof. For those files, the license text contained in
+said file overrides any license information contained in directories of smaller depth.
+Alternative licenses are typically used for software that is provided by external
+parties, and merely packaged with this software for convenience.
+----
+
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/www/wiki/extensions/Maps/DefaultSettings.php b/www/wiki/extensions/Maps/DefaultSettings.php
new file mode 100644
index 00000000..45053c1b
--- /dev/null
+++ b/www/wiki/extensions/Maps/DefaultSettings.php
@@ -0,0 +1,374 @@
+<?php
+
+// This file lists all settings you can use to configure the Maps extension and their default values.
+// Do not modify this file to change settings. See https://www.semantic-mediawiki.org/wiki/Maps/Configuration
+// Do not include this file in LocalSettings. Instead include Maps_Settings.php.
+
+return [
+ // Mapping services that will be available in the wiki.
+ // These can be used in #display_map with service=leaflet or in #ask with format=leaflet
+ 'egMapsAvailableServices' => [
+ 'leaflet',
+ 'googlemaps3'
+ ],
+
+ // The mapping service that will be used when no service is specified by the user.
+ 'egMapsDefaultService' => 'leaflet',
+
+ // Allows disabling the extension even when it is installed.
+ // CAUTION: this setting is intended for wiki farms. On single wiki installations,
+ // the recommended way to disable maps is to uninstall it via Composer. Disabling
+ // Maps via this setting undermines package management safety: extensions that depend
+ // on Maps will likely either break or disable themselves.
+ 'egMapsDisableExtension' => false,
+
+ // Allows disabling the Semantic MediaWiki integration.
+ 'egMapsDisableSmwIntegration' => false,
+
+
+
+
+
+ /**
+ * GENERAL MAP CONFIGURATION
+ */
+
+ // Integer or string. The default width and height of a map. These values will
+ // only be used when the user does not provide them.
+ 'egMapsMapWidth' => 'auto',
+ 'egMapsMapHeight' => 350,
+
+ // Array. The minimum and maximum width and height for all maps. First min and
+ // max for absolute values, then min and max for percentage values. When the
+ // height or width exceed their limits, they will be changed to the closest
+ // allowed value.
+ 'egMapsSizeRestrictions' => [
+ 'width' => [ 50, 1020, 1, 100 ],
+ 'height' => [ 50, 1000, 1, 100 ],
+ ],
+
+ // Strings. The default content for all pop-ups. This value will only be used
+ // when the user does not provide one.
+ 'egMapsDefaultTitle' => '',
+ 'egMapsDefaultLabel' => '',
+
+ 'egMapsResizableByDefault' => false,
+ 'egMapsRezoomForKML' => false,
+
+ // Boolean. Sets if pages with maps should be put in special category
+ 'egMapsEnableCategory' => false,
+
+ // Integer. Determines the TTL of cached GeoJson.
+ // Default value: 0 (no caching).
+ 'egMapsGeoJsonCacheTtl' => 0,
+
+
+
+
+
+ /**
+ * SEMANTIC MEDIAWIKI INTEGRATION
+ */
+
+ // Boolean. The default value for the showtitle parameter. Will hide the title in the marker pop-ups when set to false.
+ // This value will only be used when the user does not provide one.
+ 'smgQPShowTitle' => true,
+
+ // Boolean. The default value for the hidenamespace parameter. Will hide the namespace in the marker pop-ups when set to true.
+ // This value will only be used when the user does not provide one.
+ 'smgQPHideNamespace' => false,
+
+ // String or false. Allows you to define the content and it's layout of marker pop-ups via a template.
+ // This value will only be used when the user does not provide one.
+ 'smgQPTemplate' => false,
+
+
+
+
+
+ /**
+ * COORDINATE CONFIGURATION
+ */
+
+ // The coordinate notations that should be available.
+ 'egMapsAvailableCoordNotations' => [
+ 'float',
+ 'dms',
+ 'dm',
+ 'dd'
+ ],
+
+ // The default output format of coordinates.
+ // Possible values: float, dms, dm, dd
+ 'egMapsCoordinateNotation' => 'dms',
+
+ // Boolean. Indicates if coordinates should be outputted in directional notation by default.
+ // Recommended to be true for dms and false for float.
+ 'egMapsCoordinateDirectional' => true,
+
+ // The default output format of coordinates when displayed by Semantic MediaWiki.
+ // Possible values: float, dms, dm, dd
+ 'smgQPCoodFormat' => 'dms',
+
+ // Boolean. Indicates if coordinates should be outputted in directional notation by default when
+ // displayed by Semantic MediaWiki.
+ 'smgQPCoodDirectional' => true,
+
+ // Boolean. Sets if direction labels should be translated to their equivalent in the wiki language or not.
+ 'egMapsInternatDirectionLabels' => true,
+
+ // Boolean. When false, the #coordinates parser function will not be enabled.
+ // This is useful for people using the GeoData extension and want to use its #coordinates function instead.
+ 'egMapsEnableCoordinateFunction' => true,
+
+
+
+
+
+ /**
+ * GEOCODING CONFIGURATION
+ */
+
+ // Sets which service should be used to turn addresses into coordinates
+ // Available services: geonames, google, nominatim
+ // The geonames service requires you to specify a geonames user (see below),
+ // if you set this setting to geonames but do not specify the user, Maps will
+ // fall back to using the google service.
+ 'egMapsDefaultGeoService' => 'nominatim',
+
+ // String. GeoNames API user/application name.
+ // Obtain an account here: http://www.geonames.org/login
+ // Do not forget to activate your account for API usage!
+ 'egMapsGeoNamesUser' => '',
+
+ // Boolean. Sets if geocoded addresses should be stored in a cache.
+ 'egMapsEnableGeoCache' => true,
+
+ // Integer. If egMapsEnableGeoCache is true, determines the TTL of cached geocoded addresses.
+ // Default value: 1 day.
+ 'egMapsGeoCacheTtl' => 24 * 3600,
+
+
+
+
+
+ /**
+ * LEAFLET CONFIGURATION
+ */
+
+ // Integer. The default zoom of a map. This value will only be used when the
+ // user does not provide one.
+ 'egMapsLeafletZoom' => 14,
+
+ // String. The default layer for Leaflet. This value will only be
+ // used when the user does not provide one.
+ 'egMapsLeafletLayer' => 'OpenStreetMap',
+ 'egMapsLeafletLayers' => [ 'OpenStreetMap' ],
+
+ 'egMapsLeafletOverlayLayers' => [],
+
+ // The definitions for the layers that should be available for the user.
+ 'egMapsLeafletAvailableLayers' => [
+ 'OpenStreetMap' => true,
+ 'OpenStreetMap.DE' => true,
+ 'OpenStreetMap.BlackAndWhite' => true,
+ 'OpenStreetMap.HOT' => true,
+ 'OpenTopoMap' => true,
+ 'Thunderforest.OpenCycleMap' => true,
+ 'Thunderforest.Transport' => true,
+ 'Thunderforest.TransportDark' => true,
+ 'Thunderforest.SpinalMap' => true,
+ 'Thunderforest.Landscape' => true,
+ 'Thunderforest.Outdoors' => true,
+ 'Thunderforest.Pioneer' => true,
+ 'OpenMapSurfer.Roads' => true,
+ 'OpenMapSurfer.Grayscale' => true,
+ 'Hydda.Full' => true,
+ 'Hydda.Base' => true,
+ //'MapBox' => false, // todo: implement setting api key
+ 'Stamen.Toner' => true,
+ 'Stamen.TonerBackground' => true,
+ 'Stamen.TonerHybrid' => true,
+ 'Stamen.TonerLines' => true,
+ 'Stamen.TonerLabels' => true,
+ 'Stamen.TonerLite' => true,
+ 'Stamen.Watercolor' => true,
+ 'Stamen.Terrain' => true,
+ 'Stamen.TerrainBackground' => true,
+ 'Stamen.TopOSMRelief' => true,
+ 'Stamen.TopOSMFeatures' => true,
+ 'Esri.WorldStreetMap' => true,
+ 'Esri.DeLorme' => true,
+ 'Esri.WorldTopoMap' => true,
+ 'Esri.WorldImagery' => true,
+ 'Esri.WorldTerrain' => true,
+ 'Esri.WorldShadedRelief' => true,
+ 'Esri.WorldPhysical' => true,
+ 'Esri.OceanBasemap' => true,
+ 'Esri.NatGeoWorldMap' => true,
+ 'Esri.WorldGrayCanvas' => true,
+ 'MapQuestOpen' => true,
+ //'HERE' => false, // todo: implement setting api key
+ 'FreeMapSK' => true,
+ 'MtbMap' => true,
+ 'CartoDB.Positron' => true,
+ 'CartoDB.PositronNoLabels' => true,
+ 'CartoDB.PositronOnlyLabels' => true,
+ 'CartoDB.DarkMatter' => true,
+ 'CartoDB.DarkMatterNoLabels' => true,
+ 'CartoDB.DarkMatterOnlyLabels' => true,
+ 'HikeBike.HikeBike' => true,
+ 'HikeBike.HillShading' => true,
+ 'BasemapAT.basemap' => true,
+ 'BasemapAT.grau' => true,
+ 'BasemapAT.overlay' => true,
+ 'BasemapAT.highdpi' => true,
+ 'BasemapAT.orthofoto' => true,
+ 'NASAGIBS.ModisTerraTrueColorCR' => true,
+ 'NASAGIBS.ModisTerraBands367CR' => true,
+ 'NASAGIBS.ViirsEarthAtNight2012' => true,
+ 'NLS' => true,
+ 'GeoportailFrance' => true,
+ 'GeoportailFrance.parcels' => true,
+ 'GeoportailFrance.ignMaps' => true,
+ 'GeoportailFrance.orthos' => true
+ ],
+
+ 'egMapsLeafletAvailableOverlayLayers' => [
+ 'OpenMapSurfer.AdminBounds' => true,
+ 'OpenSeaMap' => true,
+ 'OpenWeatherMap.Clouds' => true,
+ 'OpenWeatherMap.CloudsClassic' => true,
+ 'OpenWeatherMap.Precipitation' => true,
+ 'OpenWeatherMap.PrecipitationClassic' => true,
+ 'OpenWeatherMap.Rain' => true,
+ 'OpenWeatherMap.RainClassic' => true,
+ 'OpenWeatherMap.Pressure' => true,
+ 'OpenWeatherMap.PressureContour' => true,
+ 'OpenWeatherMap.Wind' => true,
+ 'OpenWeatherMap.Temperature' => true,
+ 'OpenWeatherMap.Snow' => true,
+ 'Hydda.RoadsAndLabels' => true,
+ 'NASAGIBS.ModisTerraLSTDay' => true,
+ 'NASAGIBS.ModisTerraSnowCover' => true,
+ 'NASAGIBS.ModisTerraAOD' => true,
+ 'NASAGIBS.ModisTerraChlorophyll' => true
+ ],
+
+ 'egMapsLeafletLayersApiKeys' => [
+ 'MapBox' => '',
+ 'MapQuestOpen' => '',
+ 'Thunderforest' => '',
+ 'GeoportailFrance' => ''
+ ],
+
+ 'egMapsLeafletLayerDependencies' => [
+ 'MapQuestOpen' => 'https://open.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=',
+ ],
+
+
+
+
+
+ /**
+ * GOOGLE MAPS CONFIGURATION
+ */
+
+ // String. Google Maps v3 API Key
+ 'egMapsGMaps3ApiKey' => '',
+
+ // String. Google Maps v3 API version number
+ 'egMapsGMaps3ApiVersion' => '',
+
+ // Integer. The default zoom of a map. This value will only be used when the
+ // user does not provide one.
+ 'egMapsGMaps3Zoom' => 14,
+
+ // Array of String. The Google Maps v3 default map types. This value will only
+ // be used when the user does not provide one.
+ 'egMapsGMaps3Types' => [
+ 'roadmap',
+ 'satellite',
+ 'hybrid',
+ 'terrain'
+ ],
+
+ // String. The default map type. This value will only be used when the user
+ // does not provide one.
+ 'egMapsGMaps3Type' => 'roadmap',
+
+ // Array. List of controls to display onto maps by default.
+ 'egMapsGMaps3Controls' => [
+ 'pan',
+ 'zoom',
+ 'type',
+ 'scale',
+ 'streetview',
+ 'rotate'
+ ],
+
+ // String. The default style for the type control.
+ // horizontal, vertical or default
+ 'egMapsGMaps3DefTypeStyle' => 'default',
+
+ // String. The default style for the zoom control.
+ // small, large or default
+ 'egMapsGMaps3DefZoomStyle' => 'default',
+
+ // Boolean. Open the info windows on load by default?
+ 'egMapsGMaps3AutoInfoWindows' => false,
+
+ // Array. Layers to load by default.
+ // traffic, bicycling and transit
+ 'egMapsGMaps3Layers' => [],
+
+ // Show points of interest or not.
+ 'egMapsShowPOI' => true,
+
+ // String. Set the language when rendering Google Maps.
+ 'egMapsGMaps3Language' => '',
+
+
+
+
+
+ /**
+ * DISTANCE CONFIGURATION
+ */
+
+ // Array. A list of units (keys) and how many meters they represent (value).
+ // No spaces! If the unit consists out of multiple words, just write them together.
+ 'egMapsDistanceUnits' => [
+ 'm' => 1,
+ 'meter' => 1,
+ 'meters' => 1,
+ 'km' => 1000,
+ 'kilometers' => 1000,
+ 'kilometres' => 1000,
+ 'mi' => 1609.344,
+ 'mile' => 1609.344,
+ 'miles' => 1609.344,
+ 'nm' => 1852,
+ 'nauticalmile' => 1852,
+ 'nauticalmiles' => 1852,
+ ],
+
+ // String. The default unit for distances.
+ 'egMapsDistanceUnit' => 'm',
+
+ // Integer. The default amount of fractal digits in a distance.
+ 'egMapsDistanceDecimals' => 2,
+
+
+
+
+
+ /**
+ * DEBUGGING
+ */
+
+ // When true, debugging messages will be logged using mw.log(). Do not use on production wikis.
+ 'egMapsDebugJS' => false,
+
+ 'egMapsGlobalJSVars' => [],
+]; \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/INSTALL.md b/www/wiki/extensions/Maps/INSTALL.md
new file mode 100644
index 00000000..ad84a414
--- /dev/null
+++ b/www/wiki/extensions/Maps/INSTALL.md
@@ -0,0 +1,267 @@
+# Maps installation
+
+These are the installation and configuration instructions for the [Maps extension](README.md).
+
+## Download and installation
+
+See the [installation instructions](https://www.semantic-mediawiki.org/wiki/Maps/Installation)
+
+## Configuration
+
+See the [configuration documentation](https://www.semantic-mediawiki.org/wiki/Maps/Configuration)
+
+## Platform compatibility and release status
+
+The PHP and MediaWiki version ranges listed are those in which Maps is known to work. It might also
+work with more recent versions of PHP and MediaWiki, though this is not guaranteed. Increases of
+minimum requirements are indicated in bold. For a detailed list of changes, see the [release notes](RELEASE-NOTES.md).
+
+<table>
+ <tr>
+ <th>Maps</th>
+ <th>PHP</th>
+ <th>MediaWiki</th>
+ <th>Semantic<br>MediaWiki</th>
+ <th>Release status</th>
+ </tr>
+ <tr>
+ <th>7.4.x</th>
+ <td>7.1 - 7.4+</td>
+ <td>1.31 - 1.33+</td>
+ <td>3.0+</td>
+ <td>Planned Q2 2019</td>
+ </tr>
+ <tr>
+ <th>7.3.x</th>
+ <td>7.1 - 7.4</td>
+ <td>1.31 - 1.33</td>
+ <td>3.0 - 3.1</td>
+ <td><strong>Stable release</strong></td>
+ </tr>
+ <tr>
+ <th>7.2.x</th>
+ <td>7.1 - 7.3</td>
+ <td>1.31 - 1.32</td>
+ <td>3.0.x</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>7.1.x</th>
+ <td>7.1 - 7.3</td>
+ <td>1.31 - 1.32</td>
+ <td>3.0.x</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>7.0.x</th>
+ <td>7.1 - 7.3</td>
+ <td>1.31 - 1.32</td>
+ <td><strong>3.0.x</strong></td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>6.3.x</th>
+ <td>7.1 - 7.2</td>
+ <td>1.31 - 1.32</td>
+ <td>2.4 - 3.0</td>
+ <td>Security fixes only</td>
+ </tr>
+ <tr>
+ <th>6.2.x</th>
+ <td>7.1 - 7.2</td>
+ <td>1.31 - 1.32</td>
+ <td>2.4 - 3.0</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>6.1.x</th>
+ <td>7.1 - 7.2</td>
+ <td>1.31 - 1.32</td>
+ <td>2.4 - 3.0</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>6.0.x</th>
+ <td><strong>7.1</strong> - 7.2</td>
+ <td><strong>1.31</strong> - 1.32</td>
+ <td><strong>2.4</strong> - 3.0</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>5.6.x</th>
+ <td>7.0 - 7.2</td>
+ <td>1.27 - 1.31</td>
+ <td>2.1 - 3.0</td>
+ <td>Security fixes only</td>
+ </tr>
+ <tr>
+ <th>5.5.x</th>
+ <td>7.0 - 7.2</td>
+ <td>1.27 - 1.31</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>5.4.x</th>
+ <td>7.0 - 7.2</td>
+ <td>1.27 - 1.31</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>5.3.x</th>
+ <td>7.0 - 7.2</td>
+ <td>1.27 - 1.30</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>5.2.x</th>
+ <td>7.0 - 7.2</td>
+ <td>1.27 - 1.30</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>5.1.x</th>
+ <td><strong>7.0</strong> - 7.2</td>
+ <td>1.27 - 1.30</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>5.0.x</th>
+ <td>5.6 - 7.1</td>
+ <td>1.27 - 1.30</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>4.4.x</th>
+ <td>5.6 - 7.1</td>
+ <td>1.27 - 1.29</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>4.3.x</th>
+ <td><strong>5.6</strong> - 7.1</td>
+ <td><strong>1.27</strong> - 1.29</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>4.2.x</th>
+ <td>5.5 - 7.1</td>
+ <td>1.23 - 1.29</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>4.1.x</th>
+ <td>5.5 - 7.1</td>
+ <td>1.23 - 1.28</td>
+ <td>2.1 - 2.5</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+ <tr>
+ <th>4.0.x</th>
+ <td>5.5 - 7.0</td>
+ <td>1.23 - 1.28</td>
+ <td>2.1 - 2.4</td>
+ <td>Obsolete release, no support</td>
+ </tr>
+</table>
+
+Older obsolete versions:
+
+<table>
+ <tr>
+ <th>Maps</th>
+ <th>PHP</th>
+ <th>MediaWiki</th>
+ <th>Composer</th>
+ <th>Validator</th>
+ </tr>
+ <tr>
+ <th>3.8.x</th>
+ <td>5.5 - 7.0</td>
+ <td>1.23 - 1.27</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.7.x</th>
+ <td>5.5 - 7.0</td>
+ <td>1.23 - 1.27</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.6.x</th>
+ <td><strong>5.5</strong> - 7.0</td>
+ <td><strong>1.23</strong> - 1.27</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.5.x</th>
+ <td>5.3.2 - 7.0</td>
+ <td>1.18 - 1.27</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.4.x</th>
+ <td>5.3.2 - 7.0</td>
+ <td>1.18 - 1.27</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.3.x</th>
+ <td>5.3.2 - 5.6.x</td>
+ <td>1.18 - 1.25</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.2.x</th>
+ <td>5.3.2 - 5.6.x</td>
+ <td>1.18 - 1.24</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.1.x</th>
+ <td>5.3.2 - 5.6.x</td>
+ <td>1.18 - 1.24</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>3.0.x</th>
+ <td>5.3.2 - 5.6.x</td>
+ <td>1.18 - 1.23</td>
+ <td>Required</td>
+ <td>Handled by Composer</td>
+ </tr>
+ <tr>
+ <th>2.0.x</th>
+ <td><strong>5.3.2</strong> - 5.5.x</td>
+ <td><strong>1.18</strong> - 1.23</td>
+ <td>Not supported</td>
+ <td>0.5.1</td>
+ </tr>
+ <tr>
+ <th>1.0.5</th>
+ <td>5.2.0 - 5.3.x</td>
+ <td>1.17 - 1.19</td>
+ <td>Not supported</td>
+ <td>0.4.13 or 0.4.14</td>
+ </tr>
+</table>
+
+### Database support
+
+All current versions of Maps have full support for all databases that can be used with MediaWiki.
diff --git a/www/wiki/extensions/Maps/ISSUE_TEMPLATE.md b/www/wiki/extensions/Maps/ISSUE_TEMPLATE.md
new file mode 100644
index 00000000..d5e5b0e0
--- /dev/null
+++ b/www/wiki/extensions/Maps/ISSUE_TEMPLATE.md
@@ -0,0 +1,15 @@
+### Setup
+
+- Maps version:
+- MW version:
+- PHP version:
+- SMW version (if applicable):
+
+### Issue
+
+Detailed description of the issue and a [stack trace](https://www.semantic-mediawiki.org/wiki/Help:Identifying_bugs) if applicable:
+
+```
+```
+
+Steps to reproduce the observation (recommendation is to use the [sandbox](https://sandbox.semantic-mediawiki.org)):
diff --git a/www/wiki/extensions/Maps/Maps.php b/www/wiki/extensions/Maps/Maps.php
new file mode 100644
index 00000000..4212ed92
--- /dev/null
+++ b/www/wiki/extensions/Maps/Maps.php
@@ -0,0 +1,14 @@
+<?php
+
+/**
+ * Initialization file for the Maps extension.
+ *
+ * @links https://github.com/JeroenDeDauw/Maps/blob/master/README.md#maps Documentation
+ * @links https://github.com/JeroenDeDauw/Maps/issues Support
+ * @links https://github.com/JeroenDeDauw/Maps Source code
+ *
+ * @license https://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+
+wfLoadExtension( 'Maps' ); \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/Maps.resources.php b/www/wiki/extensions/Maps/Maps.resources.php
new file mode 100644
index 00000000..9c61887b
--- /dev/null
+++ b/www/wiki/extensions/Maps/Maps.resources.php
@@ -0,0 +1,92 @@
+<?php
+
+/**
+ * Definition of Maps resource loader modules.
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Daniel Werner < daniel.a.r.werner@gmail.com >
+ *
+ * @codeCoverageIgnoreStart
+ */
+return call_user_func( function() {
+ $moduleTemplate = [
+ 'position' => 'top',
+ 'group' => 'ext.maps',
+ 'localBasePath' => __DIR__,
+ 'remoteExtPath' => 'Maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ]
+ ];
+
+ return [
+ 'ext.maps.common' => $moduleTemplate + [
+ 'messages' => [
+ 'maps-load-failed',
+ ] ,
+ 'scripts' => [
+ 'resources/ext.maps.common.js',
+ ],
+ ],
+
+ 'ext.maps.resizable' => $moduleTemplate + [
+ 'dependencies' => 'jquery.ui.resizable',
+ ],
+
+ 'mapeditor' => $moduleTemplate + [
+ 'scripts' => [
+ 'resources/editor/js/jquery.miniColors.js',
+ 'resources/editor/js/mapeditor.iefixes.js',
+ 'resources/editor/js/mapeditor.js',
+ ],
+ 'styles' => [
+ 'resources/editor/css/jquery.miniColors.css',
+ 'resources/editor/css/mapeditor.css',
+ ],
+ 'messages' => [
+ 'mapeditor-parser-error',
+ 'mapeditor-none-text',
+ 'mapeditor-done-button',
+ 'mapeditor-remove-button',
+ 'mapeditor-import-button',
+ 'mapeditor-export-button',
+ 'mapeditor-import-button2',
+ 'mapeditor-select-button',
+ 'mapeditor-mapparam-button',
+ 'mapeditor-clear-button',
+ 'mapeditor-imageoverlay-button',
+ ],
+ 'dependencies' => [
+ 'ext.maps.common',
+ 'jquery.ui.autocomplete',
+ 'jquery.ui.slider',
+ 'jquery.ui.dialog',
+ ],
+ ],
+
+ 'ext.maps.services' => $moduleTemplate + [
+ 'scripts' => [
+ 'resources/ext.maps.services.js',
+ ],
+ 'dependencies' => [
+ 'ext.maps.common',
+ ]
+ ],
+
+ 'ext.sm.common' => $moduleTemplate + [
+ 'scripts' => [
+ 'resources/ext.sm.common.js'
+ ],
+ 'dependencies' => [
+ 'ext.maps.common',
+ 'ext.maps.services'
+ ]
+ ],
+ ];
+
+} );
+// @codeCoverageIgnoreEnd
diff --git a/www/wiki/extensions/Maps/MapsRegistration.php b/www/wiki/extensions/Maps/MapsRegistration.php
new file mode 100644
index 00000000..68d0ea05
--- /dev/null
+++ b/www/wiki/extensions/Maps/MapsRegistration.php
@@ -0,0 +1,57 @@
+<?php
+
+use Maps\MapsSetup;
+
+class MapsRegistration {
+
+ public static function onRegistration( array $credits ) {
+ if ( defined( 'Maps_VERSION' ) ) {
+ // Do not initialize more than once.
+ return true;
+ }
+
+ if ( !defined( 'Maps_SETTINGS_LOADED' ) ) {
+ require_once __DIR__ . '/Maps_Settings.php';
+ }
+
+ if ( is_readable( __DIR__ . '/vendor/autoload.php' ) ) {
+ include_once( __DIR__ . '/vendor/autoload.php' );
+ }
+
+ define( 'Maps_VERSION', $credits['version'] );
+ define( 'SM_VERSION', Maps_VERSION );
+
+ if ( !(bool)'Defining PHP constants in JSON is a bad idea and breaks tools' ) {
+ define( 'NS_GEO_JSON', 420 );
+ define( 'NS_GEO_JSON_TALK', 421 );
+ }
+
+ $GLOBALS['wgExtensionFunctions'][] = function() {
+ if ( $GLOBALS['egMapsDisableExtension'] ) {
+ return true;
+ }
+
+ // Only initialize the extension when all dependencies are present.
+ if ( !defined( 'Validator_VERSION' ) ) {
+ throw new Exception( 'You need to have Validator installed in order to use Maps' );
+ }
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.27c', '<' ) ) {
+ throw new Exception(
+ 'This version of Maps requires MediaWiki 1.27 or above; use Maps 4.2.x for older versions.'
+ . ' More information at https://github.com/JeroenDeDauw/Maps/blob/master/INSTALL.md'
+ );
+ }
+
+ ( new MapsSetup( $GLOBALS ) )->setup();
+
+ return true;
+ };
+
+ return true;
+ }
+
+}
+
+
+
diff --git a/www/wiki/extensions/Maps/Maps_Settings.php b/www/wiki/extensions/Maps/Maps_Settings.php
new file mode 100755
index 00000000..0d56a302
--- /dev/null
+++ b/www/wiki/extensions/Maps/Maps_Settings.php
@@ -0,0 +1,17 @@
+<?php
+
+/**
+ * For instructions on how to configure Maps, see
+ * https://www.semantic-mediawiki.org/wiki/Maps/Configuration
+ *
+ * For a list of all available settings and their default values,
+ * see DefaultSettings.php in this directory.
+ */
+
+foreach ( include __DIR__ . '/DefaultSettings.php' as $key => $value ) {
+ $GLOBALS[$key] = $value;
+}
+
+if ( !defined( 'Maps_SETTINGS_LOADED' ) ) {
+ define( 'Maps_SETTINGS_LOADED', true );
+}
diff --git a/www/wiki/extensions/Maps/README.md b/www/wiki/extensions/Maps/README.md
new file mode 100644
index 00000000..230f3183
--- /dev/null
+++ b/www/wiki/extensions/Maps/README.md
@@ -0,0 +1,105 @@
+# Maps
+
+Maps is a [MediaWiki](https://www.mediawiki.org) extension to work with and visualize geographical
+information.
+
+Features:
+
+* Powerful [`#display_map`](https://www.semantic-mediawiki.org/wiki/Extension:Maps/Displaying_maps) parser hook for embedding highly customizable dynamic maps into wiki pages.
+* Support for multiple mapping services: [Leaflet](http://leafletjs.com/), Google Maps and [OpenStreetMap](www.openstreetmap.org/).
+* Integration with [Semantic MediaWiki](https://www.semantic-mediawiki.org) via a [coordinate datatype](https://www.semantic-mediawiki.org/wiki/Help:Type_Geographic_coordinate)
+ * Query your stored coordinates and visualize them on dynamic maps, as tables or as lists
+ * Export your coordinates as KML or RDF
+ * Combine coordinates with other structured data stored in your wiki
+* Geocoding via several supported services with the [`#geocode`](https://www.semantic-mediawiki.org/wiki/Maps/Geocoding) parser function.
+* Coordinate formatting and format conversion via the [`#coordinates`](https://www.semantic-mediawiki.org/wiki/Maps/Coordinates) parser function.
+* Geospatial operations
+ * Calculating the distance between two points with [`#geodistance`](https://www.semantic-mediawiki.org/wiki/Maps/Geodistance)
+ * Finding a destination given a starting point, bearing and distance with [`#finddestination`](https://www.semantic-mediawiki.org/wiki/Maps/Finddestination)
+* Distance formatting and format conversion via the [`#distance`](https://www.semantic-mediawiki.org/wiki/Maps/Distance) parser function.
+* Visual map editor ([Special:MapEditor](https://www.semantic-mediawiki.org/wiki/Special:MapEditor)) to edit [`#display_map`](https://www.semantic-mediawiki.org/wiki/Extension:Maps/Displaying_maps) wikitext (requires Google Maps).
+
+Maps has been maintained since 2009 and is installed on 1000+ wikis. [Professional.Wiki](https://professional.wiki/) provides professional support.
+
+## User manual
+
+### For administrators
+
+* [Installation](https://www.semantic-mediawiki.org/wiki/Maps/Installation)
+* [Configuration](https://www.semantic-mediawiki.org/wiki/Maps/Configuration)
+* [Release notes](RELEASE-NOTES.md) - detailed list of changes per release
+* [Platform compatibility](INSTALL.md#platform-compatibility-and-release-status) - overview of PHP and MediaWiki support per release
+
+### For wiki users
+
+* [Usage instructions](https://www.semantic-mediawiki.org/wiki/Extension:Maps)
+* [Usage examples](https://www.semantic-mediawiki.org/wiki/Category:Maps_examples)
+* [Semantic usage examples](https://www.semantic-mediawiki.org/wiki/Semantic_Maps_examples)
+
+### Getting support
+
+* Professional support and custom development: **[Professional.Wiki](https://professional.wiki/)**
+* Ask a question on [the mailing list](https://www.semantic-mediawiki.org/wiki/Mailing_list)
+* File an issue on [our issue tracker](https://github.com/JeroenDeDauw/Maps/issues)
+
+## Project status
+
+* Latest version &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [![Latest Stable Version](https://poser.pugx.org/mediawiki/maps/version.png)](https://packagist.org/packages/mediawiki/maps)
+* Downloads on [Packagist](https://packagist.org/packages/mediawiki/maps) [![Download count](https://poser.pugx.org/mediawiki/maps/d/total.png)](https://packagist.org/packages/mediawiki/maps)
+* TravisCI &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [![Build Status](https://secure.travis-ci.org/JeroenDeDauw/Maps.png?branch=master)](http://travis-ci.org/JeroenDeDauw/Maps)
+* Code quality &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [![Scrutinizer Quality Score](https://scrutinizer-ci.com/g/JeroenDeDauw/Maps/badges/quality-score.png?s=3881a27e63cb64e7511d766bfec2e2db5d39bec3)](https://scrutinizer-ci.com/g/JeroenDeDauw/Maps/)
+* [Open bugs and feature requests](https://github.com/JeroenDeDauw/Maps/issues)
+* [Maps on OpenHub](https://www.ohloh.net/p/maps/)
+* [Blog posts about Maps](https://www.entropywins.wtf/blog/tag/maps/)
+
+## Contributing
+
+* [File an issue](https://github.com/JeroenDeDauw/Maps/issues)
+* [Submit a pull request](https://github.com/JeroenDeDauw/Maps/pulls) ([tasks for newcomers](https://github.com/JeroenDeDauw/Maps/issues?q=is%3Aissue+is%3Aopen+label%3Anewcomer))
+
+### Project structure
+
+The `src/` contains the PHP code and follows PSR-4 autoloading.
+
+* `src/DataAccess` - implementations of services that use the network, read from disk or persistence services
+* `src/Elements` - Value Objects representing geographical elements (should be devoid of MediaWiki binding)
+* `src/MediaWiki` - MediaWiki hook points, including API modules, special pages and MediaWiki hooks
+* `src/Presentation` - presentation layer code (all code dealing with HTML etc should be here)
+* `src/SemanticMW` - Semantic MediaWiki hook points, including result printers and value descriptions
+
+JavaScript, CSS and other web resources go into `resources/`.
+
+Tests for PHP go into `tests/` where they are grouped by test type (ie unit, integration). Within those test type
+directories the tests should mirror the directory structure in `src/`.
+
+### Running the tests
+
+As setup, run `composer install` inside of the Maps root directory.
+
+You can run the MediaWiki independent tests by executing phpunit in the root directory of maps:
+
+ phpunit
+
+This is possible without having a MediaWiki installation or webserver. A clone of the Maps code suffices.
+
+If you do not have PHPUnit installed, you can download the .phar into the root directory and execute it there:
+
+ wget -O phpunit.phar https://phar.phpunit.de/phpunit-7.phar
+ php phpunit.phar
+
+To run the tests with MediaWiki, change into `tests/phpunit` of your MediaWiki installation and run
+
+ php phpunit.php --wiki wiki -c ../../extensions/Maps/phpunit.xml.dist
+
+Where you either update `wiki` to match your wikis name, or drop the parameter. The above command
+works without modification if you are using the [MediaWiki Vagrant](https://www.mediawiki.org/wiki/MediaWiki-Vagrant).
+
+Beware that due to technical debt, some tests access the network.
+
+## Links
+
+* [Maps on OpenHub](https://www.openhub.net/p/maps/)
+* [Maps on Packagist](https://packagist.org/packages/mediawiki/maps)
+* [Maps on WikiApiary](https://wikiapiary.com/wiki/Extension:Maps)
+* [Maps on MediaWiki.org](https://www.mediawiki.org/wiki/Extension:Maps)
+* [TravisCI build status](https://travis-ci.org/JeroenDeDauw/Maps)
diff --git a/www/wiki/extensions/Maps/RELEASE-NOTES.md b/www/wiki/extensions/Maps/RELEASE-NOTES.md
new file mode 100644
index 00000000..5655f36b
--- /dev/null
+++ b/www/wiki/extensions/Maps/RELEASE-NOTES.md
@@ -0,0 +1,1289 @@
+These are the release notes for the [Maps extension](README.md). For an overview of the
+different releases and which versions of PHP and MediaWiki they support, see the
+[platform compatibility tables](INSTALL.md#platform-compatibility-and-release-status).
+
+
+## Maps 7.3.2
+
+Released on July 25th, 2019.
+
+* Removed broken geocode API module
+
+## Maps 7.3.1
+
+Released on July 20th, 2019.
+
+* Fixed compatibility issue with SMW 3.1+ (thanks @mwjames!)
+
+## Maps 7.3.0
+
+Released on May 27th, 2019.
+
+* Fixed loading of certain Leaflet maps due to JavaScript error
+* Fixed `ajaxquery` result format parameter
+* Removed long broken `pagelinktext` option from KML result format
+
+## Maps 7.2.0
+
+Released on March 5th, 2019.
+
+* Fixed Google Maps KML path issue
+
+## Maps 7.1.0
+
+Released on January 16th, 2019.
+
+* Added `egMapsEnableCoordinateFunction` setting (for people using the GeoData extension)
+* Fixed fatal error on Special:MapEditor (6.1.0 regression) (by @paladox)
+
+## Maps 7.0.0
+
+Released on December 16th, 2018.
+
+* Breaking change: removed OpenLayers service
+* Breaking change: removed `egMapsDefaultServices['qp']` setting (just use `egMapsDefaultService`)
+* Breaking change: removed Google `fusiontables` parameter (Google is retiring this service)
+* Added transit layer support for Google Maps (`layers=transit`) (by @acnetj)
+* Added `egMapsGeoJsonCacheTtl` setting and optional caching for GeoJSON files
+* Fixed display of Maps category on Special:SpecialPages
+* Removed unused `tilt` parameter for Google Maps, including the `egMapsGMaps3DefaultTilt` setting
+
+## Maps 6.3.0
+
+Released on November 29th, 2018.
+
+* The `copycoords` parameter (shows coordinates on right click of marker) now works for Leaflet
+
+## Maps 6.2.2
+
+Released on November 27th, 2018.
+
+* Fixed image loading issues, most notably Leaflet markers (6.1.0 regression)
+
+## Maps 6.2.1
+
+Released on November 26th, 2018.
+
+* Fixed Google Maps 'kml' parameter. It now again works with just the file name rather than the full path
+* Fixed `lines` parameter for Ask queries (it is no longer ignored)
+* Fixed `polygons` parameter for Ask queries (it is no longer ignored)
+* Fixed `circles` parameter for Ask queries (it is no longer ignored)
+* Fixed `rectangles` parameter for Ask queries (it is no longer ignored)
+* Fixed optional list parameters (including `locations` for Ask queries) to ignore invalid values
+
+## Maps 6.2.0
+
+Released on November 23rd, 2018.
+
+* Fixed markers with no text having empty popups (was likely only happening with recent MediaWiki versions)
+* Fixed `link=all` in Ask queries: values are now linked where appropriate
+* Fixed `link=none` and `link=subject` in Ask queries: properties are no longer linked
+* Fixed `headers=hide` in Ask queries: the values now show
+* Fixed KML result format (6.1.0 regression)
+
+## Maps 6.1.0
+
+Released on November 21st, 2018.
+
+* The `rotate` control for Google Maps is now enabled by default (changeable via `$egMapsGMaps3Controls`) (by @acnetj)
+* The `layers` parameter for Google Maps now works again (5.2.0 regression)
+* Files can again be referenced without capitalizing the first letter (3.0.0 regression)
+* Removed broken SMW `_gpo` data type
+
+## Maps 6.0.4
+
+Released on October 20th, 2018.
+
+* Fixed localizaion loading issue (by paladox)
+
+## Maps 6.0.3
+
+Released on October 4th, 2018.
+
+* Fixed double display of markers when using Leaflet (6.0.0 regression)
+
+## Maps 6.0.2
+
+Released on October 1st, 2018.
+
+* Coordinates formatted as Decimal Degrees or Float are now rounded sensibly
+* The `smgQPCoodDirectional` setting is no longer ignored
+
+## Maps 6.0.1
+
+Released on September 5th, 2018.
+
+* Fixed loading of default settings (6.0.0 regression)
+
+## Maps 6.0.0
+
+Released on September 4th, 2018.
+
+* Dropped support for PHP older than 7.1
+* Dropped support for MediaWiki older than 1.31
+* Dropped support for Semantic MediaWiki older than 2.4
+* Added API key support for Leaflet layers via the `egMapsLeafletLayersApiKeys` setting (by Gilles Cébélieu)
+* Updated Leaflet library from version 1.3.1 to version 1.3.4
+
+### GeoJson support
+
+* Added GeoJson namespace. Pages in this namespace can only contain GeoJson
+* The `#display_map` parameter `geojson` now accepts page names of pages in the GeoJson namespace
+
+### Breaking changes
+
+* Maps is no longer automatically loaded when it is installed with Composer. You now need to call `wfLoadExtension( 'Maps' )`
+ (preferred) or include the entry point (`require_once __DIR__ . '/extensions/Maps/Maps.php';`) in `LocalSettings.php`.
+ You will also need to include the default settings before your modify the Maps settings
+ `require_once __DIR__ . '/extensions/Maps/Maps_Settings.php';`
+* Removed unused `egMapsNamespaceIndex` setting
+
+## Maps 5.6.0
+
+Released on July 16th, 2018.
+
+* Added `geojson` parameter to `#display_map`, available only for Leaflet
+* Fixed `#display_map` parameter `imageoverlays`: title, text and link are no longer ignored
+
+## Maps 5.5.5
+
+Released on July 9th, 2018.
+
+* Fixed `#display_map` parameter `polygons` when using Leaflet
+* Fixed regression introduced in 5.5.3 that broke marker icons in some cases when using `visitedicon`
+
+## Maps 5.5.4
+
+Released on July 8th, 2018.
+
+* Fixed popups for lines, polygons, circles and rectangles when using Leaflet
+* Fixed display of popups with no content for Google Maps
+* Fixed fatal error when geocoding fails for addresses in circles and rectangles
+
+## Maps 5.5.3
+
+Released on July 7th, 2018.
+
+* Fixed `#display_map` parameters `icon` and `visitedicon` when using a namespace prefix (ie. File:FileName.png)
+* Fixed `icon` and `visited icon` modifiers of `#display_map` parameter `locations` when using a namespace prefix
+* Fixed `#display_map` parameter `circles` when using Leaflet
+
+## Maps 5.5.2
+
+Released on July 5th, 2018.
+
+* Fixed the `visited icon` modifier of the `#display_map` parameter `locations` (it is no longer ignored)
+
+## Maps 5.5.1
+
+Released on July 4th, 2018.
+
+* Fixed regression introduced in 5.5.0 causing the `#display_map` parameter `service` to often be ignored
+* Fixed fatal error when using `#display_map` parameter `circles`
+* Fixed fatal error when using `#display_map` parameter `rectangles`
+* Fixed `#display_map` parameter `rectangles` fill color modifier (it is no longer ignored)
+* Fixed `#display_map` parameter `rectangles` fill opacity modifier (it is no longer ignored)
+
+## Maps 5.5.0
+
+Released on July 3rd, 2018.
+
+* Added Geoportail (France) layers for Leaflet (by Gilles Cébélieu)
+* Updated Leaflet library from version 1.1.0 to version 1.3.1
+* Updated Leaflet plugins to their latest versions
+* Removed redundant `$egMapsDefaultServices['display_map']` setting
+
+## Maps 5.4.0
+
+Released on June 7th, 2018.
+
+* Improved geocoding service fallback order (by Karsten Hoffmeyer)
+* Improved compatibility with the latest MediaWiki development version (by Timo Tijhof)
+
+## Maps 5.3.0
+
+Released on April 28th, 2018.
+
+* Added `scrollwheelzoom` parameter for GoogleMaps (by hidrarga)
+* Fixed installation issue caused by using a development version of the geocoding library
+
+## Maps 5.2.0
+
+Released on January 30th, 2018.
+
+* Added support for installation of Maps in non standard directories (using `wgExtensionDirectory`) (by Tobias Oetterer)
+* Added `egMapsGeoCacheTtl` setting (by Máté Szabó)
+* Added `scrollwheelzoom` parameter for Leaflet that allows disabling scroll wheel zoom (by hidrarga)
+
+## Maps 5.1.0
+
+Released on November 17th, 2017.
+
+* Dropped support for PHP older than 7.0
+* Improved layer support for Leaflet (by Peter Grassberger)
+ * Leaflet maps now show a layer control when there are multiple layers
+ * The `layer` parameter now accepts multiple values and has been aliased to `layers`
+ * Added `egMapsLeafletLayers` setting
+ * Deprecated `egMapsLeafletLayer` setting in favour of the new `egMapsLeafletLayers`
+* Fixed Leaflet attribution link (by Bernhard Krabina)
+
+## Maps 5.0.2
+
+Released on October 19th, 2017.
+
+* Custom marker icons on Leaflet maps are now scaled correctly (by hidrarga)
+
+## Maps 5.0.1
+
+Released on October 18th, 2017.
+
+Special one-off PHP 7.x optimized release. (requires PHP 7.x)
+
+## Maps 5.0.0
+
+Released on October 16th, 2017.
+
+* Added persistent geocoding cache (by hidrarga)
+* Fixed rendering of wikitext in popups of the map result format when using the `template` parameter (by hidrarga)
+* Fixed random loading failure of Leaflet maps (by Peter Grassberger)
+* Geocoders now respect MediaWiki's network settings such as `wgHTTPProxy`
+* Image overlays used in `#display_map` now support geocoding for their locations
+
+### Breaking changes
+
+* Removed `geoservice` parameters from the `#display_map` parser function
+* Removed `geoservice` and `allowcoordinates` parameters from the `#geocode` parser function
+* Removed `mappingservice` and `geoservice` parameters from the `#geodistance` parser function
+* Removed `mappingservice`, `geoservice` and `allowcoordinates` params from the `#finddestination` parser function
+* Removed `geoservice` parameter from the SMW result formats
+* Removed `service` parameter from the `geocode` API module
+* Removed `egMapsUserGeoOverrides` setting
+* Removed `egMapsAvailableGeoServices` setting
+* Removed `egMapsAllowCoordsGeocoding` setting
+* Removed support for the GeocoderUS geocoding service as it appears to have shut down
+
+## Maps 4.4.0
+
+Released on September 14th, 2017.
+
+* Added layer support for Leaflet (by Peter Grassberger)
+* Added static map support for Leaflet (`static=true`) (by hidrarga)
+* Fixed custom marker icon bug when using Leaflet (by hidrarga)
+
+## Maps 4.3.0
+
+Released on June 10th, 2017.
+
+* Dropped support for MediaWiki older than 1.27
+* Dropped support for PHP older than 5.6
+* Fixed compatibility conflict with the GitHub MediaWiki extension
+
+## Maps 4.2.1
+
+Released on May 20th, 2017.
+
+* Fixed issue occurring when using the `template` parameter in the Google Maps result format more than once on a page
+
+## Maps 4.2.0
+
+Released on May 15th, 2017.
+
+* Fixed bug in Nomatim geocoder that caused page loading to fail when Nomatim is down
+* Fixed bug in Nomatim geocoder that caused page loading to fail when Nomatim returned an invalid response
+* Updated Leaflet from 1.0.0-rc to 1.0.3
+
+## Maps 4.1.0
+
+Released on April 14th, 2017.
+
+* Fixed rendering of area query values (they now work properly in SMW "further result" links)
+* Fixed type warning in `Maps\SemanticMW\ResultPrinters\SMMapPrinter::getMapHTML`
+* Added missing geographical polygon type i18n messages
+
+## Maps 4.0.5
+
+Released on March 5th, 2017.
+
+* Fixed i18n issue in the `mapsdoc` parser hook
+
+## Maps 4.0.4
+
+Released on January 9th, 2017.
+
+* Fixed encoding of special characters in the Google geocoder (by somescout)
+* Improved PHP 7 compatibility (by Andre Klapper)
+
+## Maps 4.0.3
+
+Released on December 6th, 2016.
+
+* Fixed regression introduced in 4.0.2 that caused the JavaScript to not be loaded in some cases
+* The `display_map` parser hook now correctly uses its `geoservice` parameter
+* The `center` parameter for the map result format now takes into account the `geoservice` parameter
+
+## Maps 4.0.2
+
+Released on December 4th, 2016.
+
+* Fixed fatal error caused by double loading of initialization code on some platforms
+
+## Maps 4.0.1
+
+Released on November 19th, 2016.
+
+* The `geocode` parser hook now correctly uses its `geoservice` and `allowcoordinates` parameters
+
+## Maps 4.0
+
+Released on November 16th, 2016. Also see the [Maps 4.0 blog post](https://www.entropywins.wtf/blog/2016/11/09/maps-4-0-0-rc1-released/)
+
+### Highlight: Integrated Semantic MediaWiki support
+
+Merged in most of the features of the Semantic Maps extension. These are enabled automatically when SMW is installed.
+
+* Added a [coordinate datatype](https://www.semantic-mediawiki.org/wiki/Help:Type_Geographic_coordinate)
+* Added a [result format](https://www.semantic-mediawiki.org/wiki/Help:Result_formats) for each mapping service
+* Added a KML result format
+* Added [distance query](https://www.semantic-mediawiki.org/wiki/Semantic_Maps_examples/Distance_query) support
+
+Semantic Maps is discontinued as the features will now be maintained in Maps. The Semantic Maps form input
+has been moved into the [Page Forms](https://www.mediawiki.org/wiki/Extension:Page_Forms) extension.
+
+### Breaking changes
+
+* The default mapping service was changed from Google Maps to Leaflet (can be changed via the `egMapsDefaultService` setting)
+* The Maps tracking category is now disabled by default (can be enabled using the `egMapsEnableCategory` setting)
+
+### Other changes
+
+* Added `egMapsDisableExtension` setting that allows disabling the extension even when it is installed
+* The `egGoogleJsApiKey` setting from Maps 2.x will now be used as Google API key when `egMapsGMaps3ApiKey` is not set
+* Various missing messages where added
+
+## Maps 3.8.2
+
+Released on September 22nd, 2016.
+
+* Fixed incorrect centering of OpenLayers maps (by Peter Grassberger)
+
+## Maps 3.8.1
+
+Released on September 7th, 2016.
+
+* Fixed bug that caused clustering to always be enabled for Leaflet (by Peter Grassberger)
+
+## Maps 3.8
+
+Released on August 24rd, 2016.
+
+Due to changes to Google Maps, an API key now needs to be set. See the
+[installation configuration instructions](https://github.com/JeroenDeDauw/Maps/blob/master/INSTALL.md#configuration).
+
+* Added Google Maps API key `egMapsGMaps3ApiKey` setting (by Peter Grassberger)
+* Added Google Maps API version number `egMapsGMaps3ApiVersion` setting (by Peter Grassberger)
+* Added [Leaflet marker clustering](https://www.semantic-mediawiki.org/wiki/Maps_examples/Leaflet_marker_clustering) (by Peter Grassberger)
+ * `markercluster`: Enables clustering, multiple markers are merged into one marker.
+ * `clustermaxzoom`: The maximum zoom level where clusters may exist.
+ * `clusterzoomonclick`: Whether clicking on a cluster zooms into it.
+ * `clustermaxradius`: The maximum radius that a cluster will cover.
+ * `clusterspiderfy`: At the lowest zoom level markers are separated so you can see them all.
+* Added [Leaflet fullscreen control](https://www.semantic-mediawiki.org/wiki/Maps_examples/Leaflet_fullscreen_control) (by Peter Grassberger)
+* Added [OSM Nominatim Geocoder](https://www.semantic-mediawiki.org/wiki/Maps_examples/Geocode) (by Peter Grassberger)
+* Upgraded Leaflet library to its latest version (1.0.0-r3) (by Peter Grassberger)
+* Made removal of marker clusters more robust (by Peter Grassberger)
+* Unified system messages for several services (by Karsten Hoffmeyer)
+
+## Maps 3.7
+
+Released on June 21st, 2016.
+
+* Added [rotate control support](https://www.semantic-mediawiki.org/wiki/Maps_examples/Google_Maps_with_rotate_control) for Google Maps (by Peter Grassberger)
+* Changed coordinate display on OpenLayers maps from long-lat to lat-long (by Peter Grassberger)
+* Upgraded google marker cluster library to its latest version (2.1.2) (by Peter Grassberger)
+* Upgraded Leaflet library to its latest version (0.7.7) (by Peter Grassberger)
+* Added missing system messages (by Karsten Hoffmeyer)
+* Internal code enhancements (by Peter Grassberger)
+* Removed broken custom map layer functionality. You no longer need to run update.php for full installation.
+
+## Maps 3.6
+
+Released on May 26th, 2016.
+
+* Dropped support for MediaWiki older than 1.23
+* Dropped support for PHP older than 5.5
+* Added cluster properties for Google Maps (by Peter Grassberger)
+ * `clustergridsize`: The grid size of a cluster in pixels
+ * `clustermaxzoom`: The maximum zoom level that a marker can be part of a cluster
+ * `clusterzoomonclick`: Whether the default behaviour of clicking on a cluster is to zoom into it.
+ * `clusteraveragecenter`: Whether the center of each cluster should be the average of all markers in the cluster.
+ * `clusterminsize`: The minimum number of markers required to form a cluster.
+* Fixed missing marker cluster images for Google Maps (by Peter Grassberger)
+* Fixed duplicate markers in OpenLayers maps (by Peter Grassberger)
+* Fixed URL support in the icon parameter (by Peter Grassberger)
+* Various minor MediaWiki compatibility enhancements (by Karsten Hoffmeyer, Siebrand Mazeland and FlorianSW)
+
+## Maps 3.5
+
+Released on April 2nd, 2016.
+
+* Added `egMapsGMaps3Language` setting (by James Hong Kong and Karsten Hoffmeyer)
+* Added `osm-mapquest` layer for OpenLayers (by Bernhard Krabina)
+* Added license lable to display on "Special:Version" (by Karsten Hoffmeyer)
+* Improved Mobile Frontend support (by James Hong Kong)
+* Added missing Leaflet system messages (by Karsten Hoffmeyer)
+
+## Maps 3.4.1
+
+Released on January 30th, 2016.
+
+* Fixed Open Street Map HTTPS support issues (by Karsten Hoffmeyer)
+* Migrated remaining wfMsg* to wfMessage (by Florian Schmidt)
+* Migrated wfRunHooks to Hooks::run (by Adam Shorland)
+
+## Maps 3.4
+
+Released on July 25th, 2015.
+
+* Added KML support for OpenLayers via a new `kml` parameter (by akionux)
+* Fixed Google Maps HTTPS support issues (by Karsten Hoffmeyer)
+
+## Maps 3.3
+
+Released on June 29th, 2015.
+
+* Added `$egMapsEnableCategory` setting (by Bernhard Krabina)
+* Fixed OpenLayers specific path issue (by Simon Heimler)
+
+## Maps 3.2.4
+
+Released on June 21st, 2015.
+
+* Map reside is now triggered when going fullscreen (by Kjetil Volden)
+* Improved styling of the fullscreen button (by Kjetil Volden)
+* Removed no longer working osmarender layer (by Karsten Hoffmeyer)
+* Fixed resource paths for some installation configurations
+
+## Maps 3.2.3
+
+Released on March 23rd, 2015.
+
+* Protocol relative URLs are now used, avoiding HTTPS related problems
+* Selecting OpenLayers markers now works on touch devices
+
+## Maps 3.2.2
+
+Released on January 19th, 2015.
+
+* Fixed fatal error in the KML formatter
+
+## Maps 3.2.1
+
+Released on January 13th, 2015.
+
+* Fixed `geocode` right
+* Fixed coordinate precision issue after breaking changes in DataValues Geo
+
+## Maps 3.2
+
+Released on September 12th, 2014.
+
+* Enhanced compatibility with MediaWiki 1.24
+* Improved the translations
+* Switched to using DataValue Geo 1.x
+
+## Maps 3.1
+
+Released on June 30th, 2014.
+
+* Re added Google Earth support
+* Removed support for the deprecated Google JavaScript API
+* Updated the translations to use the new MediaWiki JSON format
+* Re added support for fill color and fill opacity parameters for circles
+* Re added image overlay support for Google Maps
+
+## Maps 3.0.1
+
+Released on March 27th, 2014.
+
+* Fixed bug that prevented non-px units (%, ex, em) from being used in the width and height parameters.
+* Translation updates
+
+## Maps 3.0
+
+Released on January 18th, 2014.
+
+In this version a big part of the PHP codebase has been rewritten to decrease technical debt and
+thus facilitate maintenance, new feature deployment and debugging. Many tests have been added and a
+lot of bugs have been found and fixed. As an experimental feature, allowing the use of custom image
+layers with OpenLayers has been reintroduced.
+
+#### Compatibility changes
+
+* The extension now needs to be installed with Composer.
+* Changed minimum Validator version from 0.5 to 1.0.
+
+#### New features
+
+* Added leaflet service (by Pavel Astakhov)
+* Added Geocoder.us geoservice support (Ike Hecht)
+* Experimental: Usage of custom image layers defined in "Layer:" namespaced wiki pages.
+ NOTE: This feature has been part of Maps in an old 0.7.x version but got broken shortly after.
+ 3.0 reintroduces the feature in a similar way but old layer definitions are probably not
+ fully compatible for the sake of some advanced features of this rewrite.
+ NOTE: Requires running MediaWiki's maintenance/update.php for database schema updates.
+
+#### Bug fixes
+
+* Fixed autoinfowindows functionality.
+* Fixed various bugs in geocoordinate parsing and formatting.
+
+#### Breaking internal changes
+
+* Moved classes into Maps namespace
+* Removed all Criteria classes
+* Removed all Manipulation classes
+* Removed MapsCoordinateParser
+* Geocoding interfaces changed
+* MapsLocation interface changed
+* Custom image layers related classes (previously broken feature) changed
+
+#### Infrastructure
+
+* Maps is now hosted on GitHub at https://github.com/JeroenDeDauw/Maps
+* Maps now has its tests run on TravisCI at https://travis-ci.org/JeroenDeDauw/Maps
+* Maps code quality is now tracked by ScrutinizerCI at https://scrutinizer-ci.com/g/JeroenDeDauw/Maps/
+* Maps is now available on Packagist at https://packagist.org/packages/mediawiki/maps
+
+## Maps 2.0
+
+Released on October 5, 2012.
+
+#### Compatibility changes
+
+* Changed minimum PHP version from 5.2 to 5.3.
+* Changed minimum MediaWiki version from 1.17 to 1.18.
+* Changed minimum Validator version from 0.4 to 0.5.
+* Removed support for the deprecated Google Maps v2 API.
+* Removed support for the now unsupported Yahoo! Maps API and associated geocoding service.
+* Temporary disabled OSM service (you can still use OSM with the OpenLayers service).
+
+#### New features
+
+* Added support for defining an inline label to markers to GoogleMaps.
+* Added support for marker clustering to Google Maps.
+* Added support for grouping locations.
+* Added support for defining image overlays (ground overlays) in Google Maps.
+* Added support for defining lines, polygons, rectangles and circles using wikitext for Google Maps and OpenLayers.
+* Added a graphical map editing tool that allows exporting to and importing from simple wikitext (Google Maps only).
+* Added "copycoords" parameter to Google Maps and OpenLayers that allows copying coordinates after right clicking a location on a map.
+* Added "minzoom" and "maxzoom" parameters to #display_map.
+* Added support for using the Google JS API key with Google Maps (for increased map display and geocoding call limits).
+* Added support for searching markers (searchmarkers=all/title) in Google Maps and OpenLayers
+* Added support for creating static maps in OpenLayers and GoogleMaps (static=on)
+* Added positional parameter to show polygons only on hover.
+* Added an optional link parameter as an alternative to popup bubble with text and title
+* Added an optional visitedicon parameter (both global and marker parameter), that will change the icon of a marker on click.
+
+#### Other improvements
+
+* Merged display_map and display_point(s) into a single parser function: display_map (display_points is now an alias).
+* Updates parameter definitions from Validator 0.4.x to Validator 0.5.x.
+* Improved script loading.
+* Added various unit tests that caught some bugs and will now prevent regressions.
+
+#### Bug fixes
+
+* Fixed JavaScript error on some special pages due to incorrect order of map initialization.
+* Fixed partially broken kml functionality.
+
+## Maps 1.0.5
+
+Released on Novebmer 30, 2011.
+
+* Fixed display of attribution control for OpenLayers.
+* Fixed to big precision of geographic coordinates in decimal minutes format (bug 32407).
+
+## Maps 1.0.4
+
+Released on October 15, 2011.
+
+* Updated OpenLayers from 2.10 to 2.11.
+* Fixed bug in adding additional markers for Google Maps v3 (mainly affecting the Semantic Maps form input).
+
+## Maps 1.0.3
+
+Released on September 14, 2011.
+
+* Added API module for geocoding.
+* Added 'geocoding' right.
+* Added kmlrezoom parameter for Google Maps v3 and general $egMapsRezoomForKML setting.
+* Fixed Google Maps v3 JavaScript issue occurring on MediaWiki 1.17.
+
+## Maps 1.0.2
+
+Released on August 24, 2011.
+
+* Fixed Google Maps v3 JavaScript issue occurring when using Google Earth on unsupported systems.
+* Fixed internationalization of distances (bug 30467).
+
+## Maps 1.0.1
+
+Released on August 17, 2011.
+
+* Added language parameter to the mapsdoc hook.
+* Use of Validator 0.4.10s setMessage method instead of setDescription for better i18n.
+* Fixed zoom and types parameters for Google Maps v3.
+* Minor improvement to script loading.
+* Added support for Google Earth in Google Maps v3.
+* Added tilt parameter for Google Earth in Google Maps v3.
+
+## Maps 1.0
+
+Released on July 19, 2011.
+
+This version branched from Maps 0.7.x at version 0.7.3.
+
+#### New features
+
+* Added full Google Maps v3 support and set it as the default mapping service.
+* Added new geocoder making use of the new GeoNames API.
+* Added support for the auto-documentation features for parser hooks introduced in Validator 0.4.3.
+* Added resizeable parameter to all mapping services except OSM.
+
+#### Removed features
+
+* Removed compatibility with pre MediaWiki 1.17.
+* Removed overlays parameter for Google Maps v2.
+* Removed the previously deprecated "display map", "display point" and "display points" parser hooks.
+Use their underscored equivalents, ie "display_map".
+
+#### Internal improvements
+
+* Usage of the Resource Loader for all scripts and stylesheets.
+* Rewrote all the map JavaScript to jQuery plugins.
+* Rewrote the way parameters are translated to JavaScript. Now one big PHP object is json_encoded.
+* Improved KML formatter.
+* Use of Google Maps geocoding service v3 instead of v2.
+* Completed coordinate and distance parser/formatter unit tests and made them compliant with the
+MediaWiki unit testing support.
+
+#### Bug fixes
+
+* Fixed geocoding service overriding based on mapping service (merged in from Maps 0.7.5).
+* Fixed fatal error occurring when running maintenance/refreshLinks.php.
+* Fixed DMS coordinate parsing issue (bug 29419).
+* Fixed coordinate normalization issue (bug 29421).
+
+#### Other tweaks
+
+* Improved default width of maps (merged in from Maps 0.7.5).
+
+## Maps 0.7.3
+
+Released on November 30, 2010.
+
+* Some internal improvements and translation updates.
+* Fixed issue occurring when Maps is the only extension adding custom namespaces.
+
+## Maps 0.7.2
+
+Released on October 28, 2010.
+
+#### New features
+
+* Added experimental support for KML layer definitions.
+
+#### Internal improvements
+
+* Extended the layer handling to support different types of layers, each of which can be supported by one or more mapping services.
+
+#### Bug fixes
+
+* Fixed incompatibility with MW 1.15.x.
+* Fixed incorrect parsing of certain DM and DMS coordinates.
+* Fixed small layout issue with pop-ups in Google Maps.
+* Fixed incorrect error on non-existing pages in the Layer namespace.
+
+## Maps 0.7.1
+
+Released on October 20, 2010.
+
+#### New features
+
+* Image layers for OpenLayers maps, defined via pages in the Layer namespace.
+
+#### Bug fixes
+
+* Support for images without namespace prefix in the display points parser hook.
+* Fixed layer oder for OpenLayers maps.
+
+#### Internal improvements
+
+* Rewrote OpenLayers layer handling.
+
+## Maps 0.7
+
+Released on October 15, 2010.
+
+#### New features
+
+* Tag support for these parser hooks (which previously only had parser function support):
+ * Coordinates
+ * Distance
+ * Finddestination
+ * Geocode
+ * Geodistance
+* Thumbs and photos parameters for the OSM service.
+
+#### Bug fixes
+
+* Fixed compatibility with the MW 1.17 resource loader.
+* Fixed i18n issue with the overlays control for Google Maps v2 maps.
+* Fixed default zoom level for Yahoo! Maps maps.
+* Increased the maximum decimals for DMS coordinates from 2 to 20.
+
+#### Removed features
+
+* #geocodelong and #geocodelat parser functions - you can obtain their functionality using #geocode.
+
+#### Internal improvements
+
+* Rewrote the geocoding functionality. It's now an integral part of the extension that can not be just pulled out,
+while the reverse is true for individual geocoders. Geocoder interaction now uses the same model as mapping
+service interaction.
+* Use of Validator 0.4, allowing for more robust and consistent error reporting.
+* Rewrote the parser hooks to use the ParserHook class provided by Validator.
+* Restructured the directory structure of the extension to better match it's architecture.
+* Use of OpenLayers 2.10 instead of 2.9.
+
+## Maps 0.6.6
+
+Released on August 26, 2010.
+
+#### New features
+
+* Support for geocoding over proxies.
+* Added $egMapsInternatDirectionLabels settings, allowing users to disable internationalization of direction labels.
+
+#### Refactoring
+
+* Added MapsMappingServices, which serves as factory for MapsPappingService objects and does away
+with all the globals previously needed for this.
+* Removed the http/curl request code from the geocoder classes - now using Http:get() instead.
+
+#### Bug fixes
+
+* Fixed issue that caused pop-up contents to render incorrectly when it contained wiki markup.
+* Fixed coordinate parsing bug (direction labels did not get recognized) that was introduced in 0.6.4.
+* Fixed spacing issues with several parser functions.
+
+## Maps 0.6.5
+
+Released on July 27, 2010.
+
+#### Refactoring
+
+* Added unit tests for the coordinates parser.
+* Created iMappingFeature interface, from which iMapParserFunctions inherits.
+* Moved map id creation to the mapping service class for all features.
+* Moved marker JavaScript creation for display_points to the mapping service class for all features.
+* Moved default zoom level access method to the mapping service class for all features.
+* Improved the way marker data is turned into JavaScript variables.
+* Improved coordinate recognition regexes.
+
+#### Bug fixes
+
+* Fixed several small coordinate parsing and formatting issues.
+* Fixed a few small distance parsing issues.
+
+## Maps 0.6.4
+
+Released on July 8, 2010.
+
+#### New features
+
+* Added new OSM service based on iframe inclusion of toolserver page that renders OpenStreetMap tiles with Wikipedia overlays.
+* Added internationalization to the OpenLayers service.
+* Added support for including KML files for Google Maps v2.
+* Added 'searchbar' control for Google Maps v2.
+
+#### Refactoring
+
+* Moved more functionality over from feature classes to service classes to prevent crazy code-flow and code duplication.
+
+#### Bug fixes
+
+* Fixed bug in the OpenLayers service causing it to display badly in Chrome.
+* Fixed issue with with and height validation for % values, also causing backward compatibility problems with pre 0.6 setting definitions.
+* Fixed several small bugs in the coordinate parser.
+
+## Maps 0.6.3
+
+Released on June 20, 2010.
+
+#### Refactoring
+
+* Mayor refactoring of the mapping service handling, to make the code flow less messy and be able to do mapping service related things in a more consistent fashion.
+* Upgrade to OpenLayers 2.9.1.
+
+#### Bug fixes
+
+* Fixed severe bug in the coordinate parsing that removed the degree symbol from passes values, resulting in rendering most of them invalid. Presumably present since 0.6.2.
+
+## Maps 0.6.2
+
+Released on June 7, 2010.
+
+#### New features
+
+* Added #distance parser function parse distances using any of the supported units and outputting them in any of these.
+* Made supported distance units configurable and added setting for the default distance unit.
+* Added 'decimals' and 'unit' parameters to #geosiatnce.
+* Default parameter handling improvements (via Validator 0.3.2).
+
+#### Bug fixes
+
+* Re-added parameter name and value insensitivity (via Validator 0.3.2).
+
+## Maps 0.6.1
+
+Released on June 4, 2010.
+
+#### Bug fixes
+
+* Fixed bug that caused geocoding requests to fail when using display_points
+* Fixed bug that had broken the geoservice parameter for display_points and display_map.
+* Fixed bug that made OSM layers in the OpenLayers service fail.
+* Fixed issue that made custom markers on Google Maps not show up on initial page load and centred them wrongly.
+
+## Maps 0.6
+
+Released on May 31, 2010.
+
+#### New features
+
+* Added support for width and height in px, ex, em and %, instead of only px, allowing for maps that
+adjust their size to the screen width and other content.
+* Added full support for both directional and non-directional coordinate notations in DMS, DD, DM
+and float notation.
+* Added #coordinates parser function which allows rewformatting of coordinates to all supported notations.
+* Rewrote the #geocode parser function to work with named parameters and added support for smart
+geocoding. Now takes in all supported coordinate notations, and is able to output in all of them as well.
+* Added #geodistance function (based on the one in MathFunctions) with smart geocoding support.
+* Added #finddestination function with smart geocoding support.
+
+#### Refactoring
+
+* Rewrote the handling of the display_map and display_point(s) parser functions, esp the way the
+service parameter is getting determined and acted upon.
+* Removed the MapsMapFeature class to make the base classes for the features more independent and flexible.
+* Restructured the directory structure to make what the services and features are more clear.
+* Rewrote map divs and added loading message for each map.
+* Rewrote individual map JS to be added to the page header.
+* Mayor clean up of the coordinate handling, to allow for coordinate formatting and to facilitate
+better integration by the GeoCoords data type in Semantic Maps. All this code is now located in MapsCoordinateParser.
+* Use native MW hook system for mapping services and features if possible.
+* Updated the magic words to mw >=1.16 style, and retained backward compatibility.
+* Updated the OpenLayers version from 2.8 to 2.9.
+* Rewrote the parameter definitions to work with Validator 0.3.
+* Rewrote the resource inclusion html to make the code cleaner and more secure.
+
+#### Bug fixes
+
+* Changed parsing of parameters so that '=' signs in values don't cause themselves and
+proceeding characters to be omitted.
+* Add mapping to the language codes that are send to the Google Maps API to null the naming
+differences between MW and the API.
+* Added automatic icon image sizing for Google Maps and Yahoo! Maps markers.
+* Fixed conflict with prototype library that caused compatibility problems with the Halo extension.
+
+## Maps 0.5.5
+
+Released on March 20, 2010.
+
+#### Refactoring
+
+* Stylized the code to conform to MediaWiki's spacing conventions.
+
+#### Bug fixes
+
+* Fixed issue with scrollbar in pop-ups on Google Maps maps.
+* Fixed Google Maps key issue with OpenLayers that arose from the new OpenLayers layer definition system.
+* Fixed JS issue with Google Maps default overlays.
+
+## Maps 0.5.4
+
+Released on March 1, 2010.
+
+#### New features
+
+* Added the ability to define the layers (and their dependencies) that can be added by users to an OpenLayers map.
+* Added the ability to define "layer groups" for OpenLayers layers.
+
+#### Refactoring
+
+* Moved the OpenLayers layer definition validation and selection from JS to PHP.
+
+#### Bug fixes
+
+* Fixed bug causing the default zoom for each mapping service to be off.
+* Fixed potential xss vectors.
+* Fixed minor JS error that was present for all maps except OSM.
+
+## Maps 0.5.3
+
+Released on February 1, 2010.
+
+#### New features
+
+* Added Google Maps v3 support for display_map.
+
+#### Refactoring
+
+* Added service defaulting for features using a hook themselves.
+
+#### Bug fixes
+
+* Fixed JavaScript bug causing all OSM maps to fail.
+
+## Maps 0.5.2
+
+Released on January 20, 2010.
+
+#### New features
+
+* Added icon parameter to display_point(s), allowing you to set the icon for all markers that do not
+have a specific icon assigned.
+
+#### Refactoring
+
+* Usage of Validator 0.2 features for the static map specific parameters.
+
+#### Bug fixes
+
+* Fixed escaping issue causing wikitext in the title and label parameters not to be displayed correctly.
+* Fixed file path for location specific icons.
+
+## Maps 0.5.1
+
+Released on December 25, 2009.
+
+#### New features
+
+* Integrated further with Validator by holding into account the error level for coordinate validation
+in the display_ parser functions.
+
+* Added activatable= parameter to the static map support.
+
+#### Refactoring
+
+* Cleaned up the static map code for OSM display_map.
+* Modified the parameter definitions to work with Validator 0.2
+* Removed redundant (because of Validator 0.2) utility function calls from the mapping classes.
+* Removed redundant (because of Validator 0.2) utility functions from the mapping service files.
+
+#### Bug fixes
+
+* Fixed issue with the hook system that caused code to get executed when it shouldn't.
+
+## Maps 0.5
+
+Released on December 17, 2009.
+
+#### New features
+
+* Added strict parameter validation.
+* Added smart 'autopanzoom' like control for Google Maps and Yahoo! Maps.
+* Added internationalization to the OSM service, and an extra parameter to define per-map languages.
+* Static map support, similar and based upon SlippyMap.
+
+#### Refactoring
+
+* Rewrite the parameter handling to be more centralized and modular.
+** Make it possible to override the info of parameters for mapping services, including
+their aliases, default values and criteria.
+** Make it possible to add and override parameters in each segment of Maps, instead of only
+the mapping services.
+
+* Cleaned up and centralized parser function code.
+* Refactored the marker specific data handling code in every display point class up to
+a central location.
+* Removed backward compatibility (to 0.2.x and earlier) of the earth parameter.
+* Removed support for Google Map API map type names for Google Maps.
+* Added code to unload any services from the service hook that are not present in the list of
+allowed services. This ensures they don't get initialized, and makes any check to see if the
+service is one of the allowed ones further on unneeded.
+* Added checks for extension dependencies that need to be present for Maps to be initialized.
+
+#### Bug fixes
+
+* Fixed bug causing markers not to show up when a specific description was provided.
+
+#### Documenting
+
+* Created screencast demonstrating display_map usage.
+* Creates screencast demonstrating display_point usage.
+* Updated the developer documentation about hooking into and extending Maps to be useful
+for the current version.
+
+## Maps 0.4.2
+
+Released on November 15, 2009.
+
+Changes in 0.4.2 discussed on the authors blog:
+
+* [Maps and Semantic Maps 0.4.2 released](https://www.entropywins.wtf/blog/2009/11/16/maps-and-semantic-maps-0-4-2/)
+* [New in Maps 0.4.2](https://www.entropywins.wtf/blog/2009/11/12/new-in-maps-0-4-2/)
+
+#### New features
+
+* Added overlays to Google Maps. This includes both an 'overlay' control, and a new parameter
+to choose the available and default loaded overlays.
+* Added specific handling for the coordinates= and addresses= parameters for both display_map
+and display_point(s). You can now specify you do not want anything that's not a coordinate on
+your map (so no geocoding) with the coordinates= parameter, or let Maps know everything is
+an address with the addresses= parameter, causing everything to be geocoded. Also modified
+the error messages for wrong addresses and coordinates to fit this new behavior.
+
+#### Refactoring
+
+* Added the version of Maps to the JS files call, to prevent issues when functions or calls
+are changed in new versions.
+* Changed the JavaScript map parameters for Google Maps from individual parameters to a group.
+
+#### Bug fixes
+
+* Fixed inclusion path to the OSM JS file. This bug prevented any OSM maps from showing up.
+* Fixed display_map and the centre parameter of display_point(s). Both are unusable by a bug
+introduced in 0.4.1.
+* Fixed bug causing to many decimal digits in some coordinate notations, making them unrecognisable
+for Maps.
+* Fixed bug causing a form of DD notation not to get recognized.
+
+## Maps 0.4.1
+
+Released on November 10, 2009.
+
+#### Bug fixes
+
+* Fixed problems with the ° sign, caused by wrong file encodings, resulting into problems with
+the DMS notation.
+* Fixed flaw in DMS to float translation, resulting into a map being displayed when the values
+where not separated by a comma.
+
+## Maps 0.4
+
+Released on November 3, 2009.
+
+Changes in 0.4 discussed on the authors blog:
+
+* [Finally! Maps and Semantic Maps 0.4!](https://www.entropywins.wtf/blog/2009/11/03/finally-maps-and-semantic-maps-0-4/)
+
+#### New features
+
+* Added display_map parser function, to display maps without any markers.
+* Added parsing of marker-specific title and label values.
+* Added geocoding support for the centre parameter. This is based on automatic detection of
+non-coordinates to see if geocoding is required, similar to the modified behavior of display_point(s).
+* Added minimum and maximum map size restrictions, like done in SlippyMap.
+* Added OSM mapping service, which uses OL, but only allows OSM layers and is optimized for OSM.
+* Added smart 'autopanzoom' control to OL and OSM services. It will determine for itself if a
+panzoom, panzoombar, or no control should be displayed, depending on the maps height.
+* Added support for DM and DD coordinate notations.
+
+#### Refactoring
+
+* Created a hook system for the parser functions, allowing the adding or removing of additional
+parser function support.
+* Removed redundant absolute script path variable. This absolute value caused problems for some installations.
+* Changed the geocoding functionality into a true feature hook element, enabling easy removal.
+* Created service hook for the geocoding feature, loose from the mapping services hook.
+* Changed display_point(s) and display_address(es) to display_point(s), with auto detect
+functionality to see if the provided value are coordinates or addresses. display_address and
+display_addresses have been retained for backward compatibility, but will be removed from the docs.
+Backward compatibility will be removed at some point, so the use of these functions is discouraged.
+
+#### Bug fixes
+
+* Fixed issue with the default parameter for the display_address(es) parser functions.
+* Fixed major bug in the initialization method causing hook code to get executed at a probably
+wrong moment. This bug can be the cause of some weird problems that surfaced since 0.3.3.
+* Fixed issue with size of pop-ups in Google Maps. They did not stretch far enough vertically
+for large contents.
+
+## Maps 0.3.4
+
+Released on September 12, 2009.
+
+Changes in 0.3.4 discussed on the authors blog:
+
+* [Maps and Semantic Maps 0.3.4 released](https://www.entropywins.wtf/blog/2009/09/12/maps-and-semantic-maps-0-3-4-released/)
+
+#### New features
+
+* Created hook system for features, which now also allows you to specify which features
+should be enabled and which not.
+
+#### Refactoring
+
+* Added old style geocoding request again for people who do not have cURL enabled, plus a
+more consistent fall-back mechanism.
+* Added internationalization for the mapping service names.
+* Added internationalized list notations.
+* Restructured the parser function handling code to work with the new feature hook system.
+* Improved structure of geocoding classes.
+* Moved Semantic Maps JavaScript code from the Maps JS files to new SM JS files.
+* Fixed tiny performance issues all over the code.
+
+#### Bug fixes
+
+* Fixed issue with empty parameters (par=value||par2=value2) that caused the default parameter
+(coordinate(s)/address(es)) to be overridden if it occurred after the default one was set.
+* Fixed wrong error message when you provide a coordinate(s)/address(es) parameter without
+any value (ie |coordinates=|)
+
+## Maps 0.3.3
+
+Released on August 25, 2009.
+
+Changes in 0.3.3 discussed on the authors blog:
+
+* [Maps and Semantic Maps 0.3.3](https://www.entropywins.wtf/blog/2009/08/25/maps-and-semantic-maps-0-3-3/)
+
+#### New features
+
+*Added [Geonames](https://www.geonames.org) geocoding support. This is an open source geocoding
+service, that does not require a licence. It has been made the default geocoding service.
+* Added wiki-text rendering to the values of the title and label parameters, allowing users
+to pass along links, images, and more.
+
+#### Refactoring
+
+* Refactored some common functionality of the geocoder classes up to MapsBaseGeocoder.
+* Minor issue - the OpenLayers default zoom should be closer, when displaying one
+point
+
+#### Bug fixes
+
+* Fixed small bug in MapsMapper::inParamAliases that caused the determination of the
+geoservice to fail in some cases, and set it to the default.
+
+## Maps 0.3.2
+
+Released on August 18, 2009.
+
+Release for consistency. Only changes to Semantic Maps where made in 0.3.2.
+
+## Maps 0.3.1
+
+Released on August 18, 2009.
+
+#### New features
+
+* Users can now define a default service for each feature - parser functions, query printers and form inputs.
+
+#### Refactoring
+
+* Added check to see if the classes array is present in a mapping service info array.
+* Added check to see if a mapping service has handling for parser functions. In 0.3,
+Maps assumed it had, preventing the adding of mapping services that only have a form input or/and query printer.
+* The getValidService function now holds into account that not every service has support for
+both parser functions, query printers and form inputs.
+
+#### Bug fixes
+
+* Added path to extension directory to non local class item in a service's info array,
+since adding the path is impossible in the declaration.
+
+## Maps 0.3
+
+Released on August 14, 2009.
+
+Changes in 0.3 discussed on the authors blog:
+
+* [Final changes for Maps and SM 0.3](https://www.entropywins.wtf/blog/2009/08/13/final-changes-for-maps-and-sm-0-3/)
+* [New features in Maps and SM 0.3](https://www.entropywins.wtf/blog/2009/08/07/new-features-in-maps-and-sm-0-3/)
+* [Structural changes for Maps and SM 0.3](https://www.entropywins.wtf/blog/2009/08/05/structural-changes-for-maps-and-sm-0-3/)
+
+#### New features
+
+* Multi location parser functions. Two completely new parser functions have been added that
+allow the displaying of multiple points on a map.
+* Configurable map type controls. Users can now configure the map type controls of Google
+maps and Yahoo! maps maps. They can set the available map types, and the order they want
+them to be displayed in the map type control.
+* Property names now have aliases. This means you can add several alternative ways to name
+the same parameter, for instance, you can make so that ‘auto zoom’ and ‘auto-zoom’ will do
+excellently the same as the main parameter ‘autozoom’. This is particularly handy for
+parameters such as ‘centre’ (British spelling) and ‘center’ (American spelling).
+* Added Google Maps moon, Mars and sky support.
+* Controls on both Yahoo! Maps and Google Maps map can now be configured by the user with
+the controls parameter. Yahoo! Maps maps already have this option for a limited set of
+controls since version 0.2, but the amount of available controls has now been expanded
+to what the Yahoo! Maps API offers. For Google Maps the change is significantly larger,
+since a lot of new controls can now be added. These included an overview map, a scale
+line, a drop down menu for map types, an automated reverse geocoding location determiner
+and more.
+* Added the ability to specify separate title, label and icon values for each marker
+in the display_points and display_addresses parser functions.
+* Added user friendly notices for when geocoding of an address fails.
+* A whole list of OpenLayers base layers have been added. These include the satellite,
+street and hybrid views for Yahoo! Maps and Bing Maps, but also finally the OpenStreetMap layers.
+
+#### Refactoring
+
+* Created hook system for the mapping services. All hard-coded references to mapping
+services in the core code have been removed. A service is now added by one multi dimensional
+array in Maps.php (note that this can also be done in the initialization file of another
+extension!), which holds the name of the parser functions class and it’s location, the
+aliases for the service name (feature added in 0.2), and their allowed specific parameters
+and their aliases. This architecture allows other people to create their own mapping
+extension using the Maps (and Semantic Maps) ‘API’.
+* Created a class that bundles common functionality from MapsBaseMap and SMFormInput.
+* Rewrote parts of the geocoder base class.
+* Added separated handling for default parameter for each mapping service.
+* Changed the requests in the geocoder classes to CURL requests to avoid security issues.
+* Moved common, parser function specific, functions and variables from MapsMapper to a new MapsParserFunctions class.
+* Moved common code within the mapping services out of the parser function class to a new utility classes.
+
+#### Bug fixes
+
+* Fixed issue preventing the extension description from showing up in 0.2.1 & 0.2.2.
+* Fixed bug that caused Bing maps (for open layers) to not work.
+
+## Maps 0.2
+
+Released on July 29, 2009.
+
+#### New features
+
+* Added Backward compatibility by using the $wgGoogleMapsKey when this one is set and $egGoogleMapsKey isn't.
+* Added hook for [[Extension:Admin_Links|Admin Links]].
+* Added a true aliasing system for service names.
+* Created a centre parameter, that will allow you to set a custom map centre (different from the
+place where the marker will be put).
+* Added pop-ups for the markers with title and label parameters to determine the pop-up contents.
+* Changed the OpenLayers control handling. Make it accept all (36) OL controls by using eval()
+instead of a switch statement in the JavaScript.
+* Added the 'physical' button in the map type control of Google Maps maps when this map type is set.
+* Added Yahoo! geocoder support (for parser functions).
+
+#### Refactoring
+
+* Refactored MapsBaseMap and all it's child classes. This will vastly increase code
+centralization and decrease redundant logic and definitions.
+* Did a major rewrite of the Google Maps and Yahoo! Maps code. The parser function
+classes now only print a call to a JS function with all needed parameters, which then
+does all the logic and creates the map.
+
+#### Bug fixes
+
+* Fixed issue causing aliases for service names getting turned into the default
+service since they are not in the allowed services list.
+* Removed redundant parts of the OpenLayers library.
+
+## Maps 0.1
+
+Released on July 20, 2009.
+
+* Initial release, featuring Google Maps (+ Google Earth), Yahoo! Maps and OpenLayers mapping services.
diff --git a/www/wiki/extensions/Maps/composer.json b/www/wiki/extensions/Maps/composer.json
new file mode 100644
index 00000000..0ff12364
--- /dev/null
+++ b/www/wiki/extensions/Maps/composer.json
@@ -0,0 +1,74 @@
+{
+ "name": "mediawiki/maps",
+ "type": "mediawiki-extension",
+ "description": "Adds various mapping features to MediaWiki",
+ "keywords": [
+ "MediaWiki",
+ "Semantic MediaWiki",
+ "Maps",
+ "Semantic Maps",
+ "Google Maps",
+ "OpenLayers",
+ "OSM",
+ "Leaflet",
+ "Geocode",
+ "Geocoding",
+ "OpenStreetMap"
+ ],
+ "homepage": "https://github.com/JeroenDeDauw/Maps",
+ "license": "GPL-2.0-or-later",
+ "authors": [
+ {
+ "name": "Jeroen De Dauw",
+ "email": "jeroendedauw@gmail.com",
+ "homepage": "https://www.entropywins.wtf",
+ "role": "Creator and lead developer"
+ }
+ ],
+ "support": {
+ "email": "semediawiki-user@lists.sourceforge.net",
+ "irc": "irc://irc.freenode.net/mediawiki",
+ "source": "https://github.com/JeroenDeDauw/Maps"
+ },
+ "require": {
+ "php": ">=7.1",
+ "composer/installers": "^1.0.1",
+ "mediawiki/validator": "~2.2",
+ "mediawiki/parser-hooks": "~1.5",
+ "param-processor/param-processor": "~1.4.2",
+ "data-values/geo": "~4.0|~3.0",
+ "jeroen/file-fetcher": "~6.0|~5.0",
+ "jeroen/file-fetcher-cache": "~1.0",
+ "jeroen/simple-cache": "~2.0",
+ "jeroen/simple-geocoder": "~1.2"
+ },
+ "require-dev": {
+ "data-values/common": "~0.4.1"
+ },
+ "autoload": {
+ "psr-4": {
+ "Maps\\": "src/",
+ "Maps\\Tests\\": "tests/"
+ },
+ "classmap": [
+ "MapsRegistration.php"
+ ]
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "7.x-dev"
+ }
+ },
+ "replace": {
+ "mediawiki/semantic-maps": "*"
+ },
+ "suggest": {
+ "mediawiki/semantic-media-wiki": "Add, edit, aggregate and visualize structured coordinate data stored with Semantic MediaWiki"
+ },
+ "config": {
+ "process-timeout": 0
+ },
+ "scripts":{
+ "ci": "php ../../tests/phpunit/phpunit.php -c phpunit.xml.dist"
+ }
+}
diff --git a/www/wiki/extensions/Maps/extension.json b/www/wiki/extensions/Maps/extension.json
new file mode 100644
index 00000000..a631e18d
--- /dev/null
+++ b/www/wiki/extensions/Maps/extension.json
@@ -0,0 +1,52 @@
+{
+ "name": "Maps",
+ "version": "7.3.2",
+
+ "author": [
+ "[https://www.mediawiki.org/wiki/User:Jeroen_De_Dauw Jeroen De Dauw]",
+ "..."
+ ],
+ "url": "https://github.com/JeroenDeDauw/Maps/blob/master/README.md#maps",
+ "descriptionmsg": "maps-desc",
+ "license-name": "GPL-2.0-or-later",
+ "type": "parserhook",
+
+ "requires": {
+ "MediaWiki": ">= 1.31.0"
+ },
+
+ "MessagesDirs": {
+ "Maps.class": [
+ "i18n"
+ ]
+ },
+ "ExtensionMessagesFiles": {
+ "MapsAlias": "i18n/aliases/Aliases.php",
+ "MapsMagic": "i18n/magic/MagicWords.php"
+ },
+
+ "callback": "MapsRegistration::onRegistration",
+ "ContentHandlers": {
+ "GeoJson": "Maps\\MediaWiki\\Content\\GeoJsonContentHandler"
+ },
+ "namespaces": [
+ {
+ "id": 420,
+ "constant": "NS_GEO_JSON",
+ "name": "GeoJson",
+ "subpages": false,
+ "content": true,
+ "defaultcontentmodel": "GeoJson"
+ },
+ {
+ "id": 421,
+ "constant": "NS_GEO_JSON_TALK",
+ "name": "GeoJson_talk",
+ "subpages": true,
+ "content": false,
+ "defaultcontentmodel": "wikitext"
+ }
+ ],
+ "load_composer_autoloader": true,
+ "manifest_version": 2
+}
diff --git a/www/wiki/extensions/Maps/i18n/af.json b/www/wiki/extensions/Maps/i18n/af.json
new file mode 100644
index 00000000..22b88fad
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/af.json
@@ -0,0 +1,27 @@
+{
+ "@metadata": {
+ "authors": [
+ "Naudefj"
+ ]
+ },
+ "maps_map": "Kaart",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Breedte:",
+ "maps-longitude": "Lengte:",
+ "maps_coordinates_missing": "Geen koördinate is vir die kaart verskaf nie.",
+ "maps_unrecognized_coords": "Die volgende koördinate is nie herken nie: $1.",
+ "maps_unrecognized_coords_for": "Die volgende {{PLURAL:$2|koördinaat|koördinate}} is nie herken nie en is uit die kaart weggelaat:\n$1.",
+ "maps_map_cannot_be_displayed": "Die kaart kan nie vertoon word nie.",
+ "maps_click_to_activate": "Kliek om die kaart te aktiveer",
+ "maps_centred_on": "Kaart gesentreer op $1, $2.",
+ "specialpages-group-maps": "Kaarte",
+ "mapeditor-none-text": "Geen",
+ "mapeditor-link-title-switcher-link-text": "Skakel",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Teks",
+ "mapeditor-form-field-icon": "Ikoon",
+ "mapeditor-form-field-group": "Groep"
+}
diff --git a/www/wiki/extensions/Maps/i18n/aliases/Aliases.php b/www/wiki/extensions/Maps/i18n/aliases/Aliases.php
new file mode 100644
index 00000000..0c89dec3
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/aliases/Aliases.php
@@ -0,0 +1,129 @@
+<?php
+$specialPageAliases = [];
+
+/** English
+ * @author netbrain
+ */
+// @codingStandardsIgnoreFile
+
+$specialPageAliases = [];
+
+/** English (English) */
+$specialPageAliases['en'] = [
+ 'MapEditor' => [ 'MapEditor' ],
+];
+
+/** Arabic (العربية) */
+$specialPageAliases['ar'] = [
+ 'MapEditor' => [ 'محرر_الخريطة' ],
+];
+
+/** Egyptian Arabic (مصرى) */
+$specialPageAliases['arz'] = [
+ 'MapEditor' => [ 'محرر_الخريطه' ],
+];
+
+/** Assamese (অসমীয়া) */
+$specialPageAliases['as'] = [
+ 'MapEditor' => [ 'মানচিত্ৰ_সম্পাদক' ],
+];
+
+/** Western Balochi (بلوچی رخشانی) */
+$specialPageAliases['bgn'] = [
+ 'MapEditor' => [ 'نخشه_ئی_ایڈیٹگر' ],
+];
+
+/** German (Deutsch) */
+$specialPageAliases['de'] = [
+ 'MapEditor' => [ 'Karteneditor' ],
+];
+
+/** Zazaki (Zazaki) */
+$specialPageAliases['diq'] = [
+ 'MapEditor' => [ 'VırneréXerita' ],
+];
+
+/** Greek (Ελληνικά) */
+$specialPageAliases['el'] = [
+ 'MapEditor' => [ 'ΕπεξεργαστήςΧαρτών' ],
+];
+
+/** Persian (فارسی) */
+$specialPageAliases['fa'] = [
+ 'MapEditor' => [ 'ویرایشگر_نقشه' ],
+];
+
+/** Galician (galego) */
+$specialPageAliases['gl'] = [
+ 'MapEditor' => [ 'Editor_do_mapa' ],
+];
+
+/** Hebrew (עברית) */
+$specialPageAliases['he'] = [
+ 'MapEditor' => [ 'עורך_מפה' ],
+];
+
+/** Upper Sorbian (hornjoserbsce) */
+$specialPageAliases['hsb'] = [
+ 'MapEditor' => [ 'Kartowy_editor' ],
+];
+
+/** Italian (italiano) */
+$specialPageAliases['it'] = [
+ 'MapEditor' => [ 'EditorMappa' ],
+];
+
+/** Japanese (日本語) */
+$specialPageAliases['ja'] = [
+ 'MapEditor' => [ '地図編集', 'マップ編集' ],
+];
+
+/** Korean (한국어) */
+$specialPageAliases['ko'] = [
+ 'MapEditor' => [ '지도편집기' ],
+];
+
+/** Luxembourgish (Lëtzebuergesch) */
+$specialPageAliases['lb'] = [
+ 'MapEditor' => [ 'Kaartenediteur' ],
+];
+
+/** Macedonian (македонски) */
+$specialPageAliases['mk'] = [
+ 'MapEditor' => [ 'УредникНаКарти' ],
+];
+
+/** Malayalam (മലയാളം) */
+$specialPageAliases['ml'] = [
+ 'MapEditor' => [ 'ഭൂപടതിരുത്തലുപാധി' ],
+];
+
+/** Dutch (Nederlands) */
+$specialPageAliases['nl'] = [
+ 'MapEditor' => [ 'Kaarteditor' ],
+];
+
+/** Sicilian (sicilianu) */
+$specialPageAliases['scn'] = [
+ 'MapEditor' => [ 'EditorMappa' ],
+];
+
+/** Turkish (Türkçe) */
+$specialPageAliases['tr'] = [
+ 'MapEditor' => [ 'HaritaDüzenleyici', 'HaritaEditörü' ],
+];
+
+/** Vietnamese (Tiếng Việt) */
+$specialPageAliases['vi'] = [
+ 'MapEditor' => [ 'Sửa_đổi_bản_đồ' ],
+];
+
+/** Simplified Chinese (中文(简体)‎) */
+$specialPageAliases['zh-hans'] = [
+ 'MapEditor' => [ '地图编辑器' ],
+];
+
+/** Traditional Chinese (中文(繁體)‎) */
+$specialPageAliases['zh-hant'] = [
+ 'MapEditor' => [ '地圖編輯器' ],
+]; \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/i18n/aln.json b/www/wiki/extensions/Maps/i18n/aln.json
new file mode 100644
index 00000000..3a3ab54c
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/aln.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mdupont"
+ ]
+ },
+ "maps-desc": "Ofron mundësinë për të shfaqur koordinimin e të dhënave në harta, dhe adresat geocode ([http://mapping.referata.com/wiki/Maps_examples demo]). Hartës shërbimet në dispozicion: $1",
+ "maps_map": "Hartë",
+ "maps-loading-map": "Loading Harta ...",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Latitude:",
+ "maps-longitude": "Gjatësi:",
+ "maps-invalid-coordinates": "Vlera $1 nuk është njohur si një grup të vlefshme të kordinatave.",
+ "maps_coordinates_missing": "Nuk ka koordinon parashikuara në hartë.",
+ "maps_geocoding_failed": "Më poshtë {{PLURAL:$2|Adresa|adresat}} nuk mund të geocoded: $1."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ar.json b/www/wiki/extensions/Maps/i18n/ar.json
new file mode 100644
index 00000000..c6d9c13a
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ar.json
@@ -0,0 +1,227 @@
+{
+ "@metadata": {
+ "authors": [
+ "Imksa",
+ "Meno25",
+ "Macofe",
+ "ديفيد"
+ ]
+ },
+ "maps-desc": "يسمح بتضمين خرائط ديناميكية إلى صفحات الويكي، كود العناوين وعمليات جغرافية أخرى",
+ "right-geocode": "الترميز الجغرافي",
+ "action-geocode": "تفعيل الترميز الجغرافي في هذا الويكي",
+ "maps_map": "خريطة",
+ "maps-tracking-category": "الصفحات التي تحتوي على خريطة مقدمة من تمديد الخرائط",
+ "maps-loading-map": "تحميل الخريطة...",
+ "maps-load-failed": "لا يمكن تحميل الخريطة!",
+ "maps-markers": "علامات",
+ "maps-copycoords-prompt": "CTRL+C، ENTER",
+ "maps-searchmarkers-text": "علامات التصفية",
+ "maps-others": "أخرون",
+ "maps-kml-parsing-failed": "أخفق تحليل ملف KML واحد أو أكثر; عادة ما يحدث هذا بسبب فشل أو تلف استرجاع XML.",
+ "maps-ns-layer": "طبقة",
+ "maps-ns-layer-talk": "نقاش الطبقة",
+ "maps-layer-property": "خاصية",
+ "maps-layer-value": "القيمة",
+ "maps-layer-errors": "أخطاء",
+ "maps-layerdef-invalid": "{{PLURAL:$1|تحديد}} غير صالح",
+ "maps-layerdef-invalid-fatal": "تعريف غير صالح قاتل",
+ "maps-layerdef-wrong-namespace": "تعريفات الطبقة صالحة فقط في نطاق \"$1\"",
+ "maps-layerdef-equal-layer-name": "يجب أن تكون أسماء الطبقات فريدة داخل صفحة الطبقة نفسها، يتم بالفعل استخدام \"$1\" من قبل طبقة أخرى.",
+ "maps-layerpage-usage": "الصفحات التي تحتوي على خرائط باستخدام طبقة \"$1\"",
+ "maps-layerpage-nousage": "لا توجد صفحات تستخدم هذه الطبقة في الوقت الحالي.",
+ "maps-error-invalid-layertype": "لا توجد طبقات من نوع \" $1 \". فقط {{PLURAL:$3| هذا النوع هو | هذه الأنواع هي}} المدعومة : $2",
+ "maps-error-no-layertype": "تحتاج إلى تحديد نوع طبقة. {{PLURAL:$2| هذا النوع فقط | هذه الأنواع هي}} المدعومة : $1",
+ "validation-error-invalid-layer": "المعلمة $1 يجب أن تكون طبقة صالحة.",
+ "validation-error-invalid-layers": "المعلمة $1 يجب أن تكون طبقة واحدة أو أكثر صالحة.",
+ "validation-error-no-non-numeric": "يجب أن يكون الوسيط \"$1\" سلسلة غير رقمية.",
+ "validation-error-no-non-numerics": "يجب أن يكون الوسيط \"$1\" واحدة أو أكثر من السلاسل غير الرقمية.",
+ "maps-layer-of-type": "طبقة من نوع $1",
+ "maps-layer-of-type-and-name": "طبقة \"$2\" من نوع \"$1\"",
+ "maps-layer-type-supported-by": "نوع الطبقة هذا يمكن أن {{PLURAL:$2| يمكن استخدامها فقط مع $1 خدمة الخرائط | يمكن استخدامها مع خدمات الخرائط : $1 }}.",
+ "maps-coordinates-description": "ربط محلل بإحداثيات الشكل ، من وإلى أي من الأشكال المدعومة.",
+ "maps-displaymap-description": "عرض الخرائط الجغرافية دون أي علامات ويكي معرفة عليها.",
+ "maps-distance-description": "تحويل المسافة باستخدام وحدة معتمدة معينة إلى ما يعادلها باستخدام وحدة أخرى.",
+ "maps-finddestination-description": "العثور على جهة معينة لنقطة البداية (التي يمكن أن تكون بأية صيغة مدعومة)، تحمل الأولي والمسافة.",
+ "maps-geocode-description": "تمكن الترميز الجغرافي للعناوين، وبعبارة أخرى، تحويل المواقع القابلة للقراءة البشرية إلى مجموعات من الإحداثيات، وهناك دعم لعدة خدمات للترميز الجغرافي، لا ينبغي الخلط بينها وبين خدمات رسم الخرائط.",
+ "maps-geodistance-description": "احسب المسافة الجغرافية بين نقطتين، من وإلى أي من الصيغ المدعومة.",
+ "maps-mapsdoc-description": "عرض جدول بالوسائط لخدمة تعيين محددة مع قيمها وأوصافها الافتراضية.",
+ "maps-layerdefinition-description": "يصف طبقة مخصصة والتي يمكن عرضها مع وظائف خريطة أخرى.",
+ "maps-mapsdoc-par-service": "خدمة رسم الخرائط لعرض توثيق الوسيط.",
+ "maps-mapsdoc-par-language": "اللغة التي يتم بها عرض التوثايق، إذا لم تتوفر مثل هذه الترجمة، سيتم استخدام الإنجليزية بدلا من ذلك.",
+ "maps-coordinates-par-location": "الإحداثيات التي تريد تنسيقها.",
+ "maps-coordinates-par-format": "الصيغة الهدف للإحداثيات.",
+ "maps-coordinates-par-directional": "يشير إلى ما إذا كان ينبغي إخراج الإحداثيات اتجاهيا أم لا.",
+ "maps-par-scrollwheelzoom": "يشير إلى ما إذا كان يجب تمكين تمرير الفأرة أم لا.",
+ "maps-distance-par-distance": "المسافة للتحويل إلى ما يعادلها بوحدة محددة.",
+ "maps-distance-par-decimals": "الحد الأقصى لعدد الأرقام الكسرية التي سيتم استخدامها في القيمة الناتجة.",
+ "maps-distance-par-unit": "وحدة لإخراج المسافة بها.",
+ "maps-finddestination-par-location": "الموقع الأولي.",
+ "maps-finddestination-par-bearing": "التحمل الأولي.",
+ "maps-finddestination-par-distance": "مسافة للسفر.",
+ "maps-finddestination-par-format": "الصيغة التي سيتم بها إخراج الوجهة.",
+ "maps-finddestination-par-directional": "يشير إلى ما إذا كانت صيغة الوجهة يجب أن تكون اتجاهية أم لا.",
+ "maps-geocode-par-location": "العنوان الذي تريد ترميزه جغرافيا.",
+ "maps-geocode-par-format": "صيغة الإحداثيات الناتجة.",
+ "maps-geocode-par-directional": "يشير إلى ما إذا كان ينبغي إخراج الإحداثيات اتجاهيا أم لا.",
+ "maps-geodistance-par-location1": "النقطة الأولى في المجموعة لحساب المسافة.",
+ "maps-geodistance-par-location2": "النقطة الثانية في المجموعة لحساب المسافة.",
+ "maps-geodistance-par-unit": "وحدة لإخراج المسافة بها.",
+ "maps-geodistance-par-decimals": "الحد الأقصى لعدد الأرقام الكسرية التي سيتم استخدامها في القيمة الناتجة.",
+ "maps-displaymap-par-mappingservice": "السماح بتعيين خدمة التعرسم الخرائط التي سيتم استخدامها لإنشاء الخريطة.",
+ "maps-displaymap-par-coordinates": "موقع واحد أو أكثر لعرضه على الخريطة، سيتم الإشارة إليه بعلامة.",
+ "maps-displaymap-par-visitedicon": "اسم ملف صورة لاستخدامها لأيقونات علامة بعد النقر على العلامات الأصلية",
+ "maps-displaymap-par-zoom": "السماح بتحديد مستوى تكبير للخريطة،\nعندما لا يتم التوفير وإيجاد علامات متعددة على الخريطة، سيتم اتخاذ أفضل تكبير مناسب، وليس الافتراضي الشكلي.",
+ "maps-displaymap-par-centre": "يسمح تعيين إحداثيات مركز الخريطة لـdisplay_point(s)،\nيقبل كل من العناوين والإحداثيات،\nعندما لا يتم توفير هذه الخاصية، ستركز الخريطة نفسها على العلامة المقدمة، أو بين العلامات المقدمة.",
+ "maps-displaymap-par-title": "يسماح بتعيين النص الذي سيتم عرضه في النوافذ المنبثقة من جميع العلامات التي ليس لها عنوان محدد،\nعند استخدامها جنبا إلى جنب مع التسمية، سيكون العنوان غامقا وتحته خط.",
+ "maps-displaymap-par-label": "يسمح بتعيين النص الذي سيتم عرضه في النوافذ المنبثقة من جميع العلامات التي لا تحتوي على تسمية محددة.",
+ "maps-displaymap-par-icon": "يسمح بتعيين الأيقونة المستخدمة لجميع العلامات.",
+ "maps-displaymap-par-circles": "دوائر لعرضها",
+ "maps-displaymap-par-copycoords": "عرض مربع حوار عند النقر على موقع يمكن نسخ إحداثياته ​​منه",
+ "maps-displaymap-par-lines": "خطوط لعرضها",
+ "maps-displaymap-par-maxzoom": "الحد الأقصى لمستوى التكبير",
+ "maps-displaymap-par-minzoom": "الحد الأدنى لمستوى التكبير",
+ "maps-displaymap-par-polygons": "مضلعات لعرضها",
+ "maps-displaymap-par-rectangles": "مستطيلات للعرض",
+ "maps-displaymap-par-static": "جعل الخريطة ثابتة",
+ "maps-displaymap-par-wmsoverlay": "استخدم تراكب خدمة خرائط الويب",
+ "maps-displaymap-par-geojson": "مسار ملف أو اسم الصفحة التي تحتوي على بيانات GeoJSON",
+ "maps-fullscreen-button": "تبديل ملء الشاشة",
+ "maps-fullscreen-button-tooltip": "عرض الخريطة على أنها ملء الشاشة أو مضمنة.",
+ "validation-error-invalid-location": "يجب أن يكون الوسيط \"$1\" موقعا صالحا.",
+ "validation-error-invalid-locations": "يجب أن يكون الوسيط \"$1\" واحدا أو أكثر من المواقع الصالحة.",
+ "validation-error-invalid-width": "يجب أن يكون الوسيط \"$1\" عرضا صالحا.",
+ "validation-error-invalid-height": "يجب أن يكون الوسيط \"$1\" ارتفاعا صالحا.",
+ "validation-error-invalid-distance": "يجب أن يكون الوسيط \"$1\" مسافة صالحة.",
+ "validation-error-invalid-distances": "يجب أن يكون الوسيط \"$1\" مسافة صالحة واحدة أو أكثر.",
+ "validation-error-invalid-image": "يجب أن يكون الوسيط \"$1\" صورة صالحة.",
+ "validation-error-invalid-images": "يجب أن يكون الوسيط \"$1\" صورة صالحة واحدة أو أكثر.",
+ "validation-error-invalid-goverlay": "يجب أن يكون الوسيط \"$1\" تراكبا صالحا.",
+ "validation-error-invalid-goverlays": "يجب أن يكون الوسيط \"$1\" واحدا أو أكثر من التراكبات الصالحة.",
+ "maps-abb-north": "شم",
+ "maps-abb-east": "شر",
+ "maps-abb-south": "ج",
+ "maps-abb-west": "غ",
+ "maps-latitude": "دائرة العرض:",
+ "maps-longitude": "خط الطول:",
+ "maps-invalid-coordinates": "لم يتم التعرف على القيمة $1 كمجموعة صالحة للإحداثيات.",
+ "maps_coordinates_missing": "لا إحداثيات موفرة للخريطة.",
+ "maps_geocoding_failed": "{{PLURAL:$2|العنوان التالي|العناوين التالية}} لم يمكن تكويدها جغرافيا: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|العنوان التالي|العناوين التالية}} لم يمكن تكويدها جغرافيا و {{PLURAL:$2|تمت|تمت}} إزالتها من الخريطة:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|الإحداثي التالي|الإحداثيات التالية}} لم يتم التعرف عليها: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|الإحداثي التالي|الإحداثيات التالية}} لم يتم التعرف عليها و {{PLURAL:$2|تمت|تمت}} إزالتها من الخريطة:\n$1",
+ "maps_map_cannot_be_displayed": "الخريطة لا يمكن عرضها.",
+ "maps-geocoder-not-available": "ميزة الترميز الجغرافي للخرائط غير متوفرة; لا يمكن وضع رمز جغرافي لموقعك.",
+ "maps_googlemaps3": "خرائط جوجل v3",
+ "maps_leaflet": "الطبقة",
+ "maps-leaflet-par-defzoom": "يسمح بتعيين مستوى التكبير الافتراضي للخريطة.",
+ "maps-leaflet-par-layers": "الطبقات التي ستكون متاحة في محدد الطبقة، سيتم عرض الطبقة الأولى عند تحميل الخريطة.",
+ "maps-leaflet-par-overlaylayers": "طبقات التراكب التي سيتم عرضها عند تحميل الخريطة.",
+ "maps-leaflet-par-maxclusterradius": "الحد الأقصى لنصف القطر الذي سيغطيه العنقود من العلامة المركزية (بالبكسل).",
+ "maps-leaflet-par-clusterspiderfy": "عند النقر فوق عنقود في مستوى التكبير السفلي سنكبره حتى تتمكن من رؤية كل علاماته.",
+ "maps_click_to_activate": "اضغط لتنشيط الخريطة",
+ "maps_centred_on": "الخريطة مركزها في $1، $2.",
+ "maps-par-mappingservice": "يسمح بتعيين خدمة رسم الخرائط التي سيتم استخدامها لإنشاء الخريطة.",
+ "maps-par-resizable": "يجعل الخريطة قابلة للتغيير عن طريق سحبا في الزاوية السفلية اليمنى.",
+ "maps-par-searchmarkers": "يسمح بالبحث عن علامات محددة عبر حقل مضمن في الخريطة.",
+ "maps-par-zoom": "مستوى التكبير للخريطة، بالنسبة للخرائط التي تحتوي على علامات، سيؤدي هذا إلى الوضع الافتراضي إلى أقصى مستوى من التكبير الذي لا يزال يظهر جميع العلامات.",
+ "maps-par-width": "يسمح بتعيين عرض الخريطة، سيتم افتراض وحدات البكسل الافتراضية على أنها وحدة، ولكن يمكنك تحديد إحدى هذه الوحدات بشكل صريح: px، ex، em.",
+ "maps-par-height": "يسمح بتعيين ارتفاع الخريطة، سيتم افتراض وحدات البكسل الافتراضية على أنها وحدة، ولكن يمكنك تحديد إحدى هذه الوحدات بشكل صريح: px، ex، em.",
+ "maps-par-centre": "الموقع الذي يجب أن تركز عليه الخريطة",
+ "maps-par-enable-fullscreen": "تمكين زر ملء الشاشة",
+ "maps-par-kml": "ملفات KML لتحميلها على الخريطة.",
+ "maps-par-markercluster": "يسمح بدمج عدة علامات قريبة في علامة واحدة",
+ "maps-googlemaps3-incompatbrowser": "متصفحك غير متوافق مع الإصدار الثالث من خرائط جوجل.",
+ "maps-googlemaps3-par-imageoverlays": "يسمح بإضافة صورة ليتم عرضها على الموقع المحدد على الخريطة.",
+ "maps-googlemaps3-par-type": "نوع خريطة ليتم عرضه في البداية.",
+ "maps-googlemaps3-par-types": "أنواع الخريطة التي ستكون متاحة عن طريق التحكم في النوع.",
+ "maps-googlemaps3-par-layers": "طبقات خاصة للتحميل على الخريطة.",
+ "maps-googlemaps3-par-controls": "ضوابط للوضع على الخريطة.",
+ "maps-googlemaps3-par-zoomstyle": "أسلوب التحكم في التكبير.",
+ "maps-googlemaps3-par-typestyle": "أسلوب التحكم في النوع.",
+ "maps-googlemaps3-par-autoinfowindows": "فتح جميع نوافذ المعلومات تلقائيا بعد تحميل الصفحة.",
+ "maps-googlemaps3-par-gkml": "ملفات KML تستضيفها جوجل لتحميلها على الخريطة.",
+ "maps-googlemaps3-par-kmlrezoom": "إعادة تكبير الخريطة بعد تحميل طبقات KML.",
+ "maps-googlemaps3-par-poi": "عرض نقاط الاهتمام.",
+ "maps-googlemaps3-par-clustergridsize": "حجم شبكة العنقود بالبكسل.",
+ "maps-par-clustermaxzoom": "الحد الأقصى لمستوى التكبير حيث قد يوجد عنقود.",
+ "maps-par-clusterzoomonclick": "ما إذا كان السلوك الافتراضي للنقر على عنقود هو تكبيره.",
+ "maps-par-maxclusterradius": "الحد الأقصى لنصف القطر الذي سيغطيه العنقود.",
+ "maps-googlemaps3-par-clusteraveragecenter": "ما إذا كان مركز كل عنقود يجب أن يكون متوسط ​​جميع العلامات في العنقود.",
+ "maps-googlemaps3-par-clusterminsize": "الحد الأدنى لعدد العلامات لتكون في عنقود قبل إخفاء العلامات وإظهار العد.",
+ "mapeditor": "محرر الخرائط",
+ "specialpages-group-maps": "الخرائط",
+ "mapeditor-parser-error": "حدث خطأ أثناء تحليل البيانات الوصفية; يتم تجاهل إدخال المستخدم.",
+ "mapeditor-none-text": "لا شيء",
+ "mapeditor-done-button": "تم",
+ "mapeditor-remove-button": "إزالة",
+ "mapeditor-import-button2": "استيراد",
+ "mapeditor-export-button": "تصدير إلى رمز ويكي",
+ "mapeditor-import-button": "استيراد من رمز ويكي",
+ "mapeditor-select-button": "حدد هذا المضلع",
+ "mapeditor-mapparam-button": "تحرير وسائط الخريطة",
+ "mapeditor-clear-button": "مسح الخريطة",
+ "mapeditor-code-title": "رمز ويكي",
+ "mapeditor-import-title": "استيراد رمز ويكي",
+ "mapeditor-import-note": "تُرجَى ملاحظة أن المحلل يتوقع تنسيقا صارما جدا على رمز الويكي، يجب أن تتطابق الكود المدخل هنا مع الكود الذي تم إخراجه بواسطة وظيفة التصدير.",
+ "mapeditor-form-title": "عدل التفاصيل",
+ "mapeditor-link-title-switcher-popup-text": "انبثق مع النص",
+ "mapeditor-link-title-switcher-link-text": "وصلة",
+ "mapeditor-form-field-title": "العنوان",
+ "mapeditor-form-field-text": "النص",
+ "mapeditor-form-field-link": "الوصلة",
+ "mapeditor-form-field-icon": "الأيقونة",
+ "mapeditor-form-field-group": "المجموعة",
+ "mapeditor-form-field-inlinelabel": "التسمية المضمنة",
+ "mapeditor-form-field-strokecolor": "لون الخط",
+ "mapeditor-form-field-strokeopacity": "تعتيم الخط",
+ "mapeditor-form-field-strokeweight": "وزن الخط",
+ "mapeditor-form-field-fillcolor": "ملء اللون",
+ "mapeditor-form-field-fillopcaity": "ملء التعتيم",
+ "mapeditor-form-field-showonhover": "إظهار على التمرير فقط",
+ "mapeditor-mapparam-title": "تحرير وسائط الخريطة",
+ "mapeditor-mapparam-defoption": "-اختر وسيطا-",
+ "mapeditor-imageoverlay-button": "إضافة تراكب صورة",
+ "mapeditor-form-field-image": "الصورة",
+ "mapeditor-imageoverlay-title": "تفاصيل تراكب الصور",
+ "mapeditor-form-field-visitedicon": "أيقونة تمت زيارتها",
+ "semanticmaps-unrecognizeddistance": "القيمة $1 ليست مسافة صحيحة.",
+ "semanticmaps-kml-link": "عرض ملف KML",
+ "semanticmaps-kml": "كيه إم إل",
+ "semanticmaps-default-kml-pagelink": "عرض الصفحة $1",
+ "semanticmaps-latitude": "دائرة العرض: $1",
+ "semanticmaps-longitude": "خط الطول: $1",
+ "semanticmaps-altitude": "الارتفاع: $1",
+ "semanticmaps-forminput-locations": "المواقع",
+ "semanticmaps-par-staticlocations": "قائمة بالمواقع التي تريد إضافتها إلى الخريطة مع البيانات التي تم الاستعلام عنها، كما هو الحال مع display_points، يمكنك إضافة عنوان ووصف ورمز لكل موقع باستخدام التلدة \"~\" كفاصل.",
+ "semanticmaps-par-showtitle": "عرض عنوان في نافذة معلومات العلامة أو لا، غالبا ما يكون تعطيل هذا الأمر مفيدا عند استخدام قالب لتنسيق محتوى نافذة المعلومات.",
+ "semanticmaps-par-hidenamespace": "عرض عنوان النطاق في نافذة معلومات العلامة",
+ "semanticmaps-par-centre": "مركز الخريطة، عندما لا يتم توفيره، فإن الخريطة تلقائيا تختار المركز الأمثل لعرض كافة العلامات على الخريطة.",
+ "semanticmaps-par-template": "قالب لاستخدامه لتنسيق محتويات نافذة المعلومات.",
+ "semanticmaps-par-geocodecontrol": "عرض تحكم الترميز الجغرافي.",
+ "semanticmaps-par-activeicon": "أيقونة ليتم عرضها بدلا من علامة افتراضية، عندما تكون الصفحة النشطة تساوي نتيجة الاستعلام",
+ "semanticmaps-par-pagelabel": "عند تعيينها لـ\"نعم\"، ستكون لكل علامات \"التسمية المضمنة\" مع وصلة إلى الصفحة التي تحتوي على إحداثيات للعلامة",
+ "semanticmaps-par-ajaxcoordproperty": "اسم خاصية الإحداثيات التي يتم استخدامها لبناء استعلام أجاكس.",
+ "semanticmaps-par-ajaxquery": "الاستعلام الثاني الذي يتم إرساله عبر أجاكس لجلب إحداثيات إضافية.",
+ "semanticmaps-par-userparam": "قيمة تم تمريرها في كل استدعاء قالب، إذا تم استخدام قالب",
+ "semanticmaps-kml-text": "النص المرتبط بكل صفحة، يتم تجاوزه بواسطة الخصائص الإضافية التي تم الاستعلام عنها إن وُجِدت.",
+ "semanticmaps-kml-title": "العنوان الافتراضي للنتائج",
+ "semanticmaps-kml-linkabsolute": "يجب أن تكون الروابط مطلقة (بدلا من النسبية)",
+ "semanticmaps-kml-pagelinktext": "النص الذي سيتم استخدامه للروابط إلى الصفحة، بحيث سيتم استبدال $1 بعنوان الصفحة",
+ "semanticmaps-shapes-improperformat": "تنسيق غير صحيح بقيمة $1; يُرجَى الاطلاع على توثيق التنسيق",
+ "semanticmaps-shapes-missingshape": "لم يتم العثور على أية أشكال مقابل $1; يُرجَى الاطلاع على توثيق الأشكال المتاحة",
+ "validator-type-mapscircle": "الدائرة الجغرافية",
+ "validator-type-mapscircle-list": "قائمة الدوائر",
+ "validator-type-mapsimageoverlay": "تراكب الصور",
+ "validator-type-mapsimageoverlay-list": "قائمة تراكبات الصور",
+ "validator-type-mapsline": "الخط الجغرافي",
+ "validator-type-mapsline-list": "قائمة السطور",
+ "validator-type-mapslocation": "الموقع الجغرافي",
+ "validator-type-mapslocation-list": "قائمة المواقع",
+ "validator-type-mapsrectangle": "المستطيل الجغرافي",
+ "validator-type-mapsrectangle-list": "قائمة المستطيلات",
+ "validator-type-mapspolygon": "المضلع الجغرافي",
+ "validator-type-mapspolygon-list": "قائمة المضلعات الجغرافية",
+ "validator-type-wmsoverlay": "تراكب خدمة خريطة الويب",
+ "validator-type-jsonfile": "نص"
+}
diff --git a/www/wiki/extensions/Maps/i18n/arc.json b/www/wiki/extensions/Maps/i18n/arc.json
new file mode 100644
index 00000000..05c734c5
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/arc.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Basharh"
+ ]
+ },
+ "maps_map": "ܨܘܪܬ ܥܠܡܐ",
+ "maps-layer-property": "ܕܝܠܝܬܐ",
+ "maps-layer-value": "ܛܝܡܐ",
+ "maps-layer-errors": "ܦܘܕ̈ܐ",
+ "maps-abb-north": "ܓܪܒܝܐ",
+ "maps-abb-east": "ܡܕܢܚܐ",
+ "maps-abb-south": "ܬܝܡܢܐ",
+ "maps-abb-west": "ܡܥܪܒܐ"
+}
diff --git a/www/wiki/extensions/Maps/i18n/arz.json b/www/wiki/extensions/Maps/i18n/arz.json
new file mode 100644
index 00000000..aba64ff8
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/arz.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Meno25"
+ ]
+ },
+ "maps-abb-north": "شمال",
+ "maps-abb-east": "شرق",
+ "maps-abb-south": "جنوب",
+ "maps-abb-west": "غرب",
+ "maps-latitude": "دوائر العرض:",
+ "maps-longitude": "خطوط الطول:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ast.json b/www/wiki/extensions/Maps/i18n/ast.json
new file mode 100644
index 00000000..7f11fc02
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ast.json
@@ -0,0 +1,223 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xuacu",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Permite inxertar mapes dinámicos nes páxines wiki, xeocodificación de direiciones y otres operaciones xeográfiques",
+ "right-geocode": "Xeocódigu",
+ "action-geocode": "xeocodificar nesta wiki",
+ "maps_map": "Mapa",
+ "maps-tracking-category": "Páxines con un mapa renderizáu pola estensión Maps",
+ "maps-loading-map": "Cargando'l mapa...",
+ "maps-load-failed": "¡Nun se pudo cargar el mapa!",
+ "maps-markers": "Marcadores",
+ "maps-copycoords-prompt": "CTRL+C, Intro",
+ "maps-searchmarkers-text": "Peñerar marcadores",
+ "maps-others": "otros",
+ "maps-kml-parsing-failed": "Falló l'analís d'un ficheru KML o más, de vezu debío a un fallu na recuperación o a un XML con mal formatu.",
+ "maps-ns-layer": "Capa",
+ "maps-ns-layer-talk": "Alderique de capa",
+ "maps-layer-property": "Propiedá",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Errores",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definición inválida|Definiciones inválides}}",
+ "maps-layerdef-invalid-fatal": "Definición inválida fatal",
+ "maps-layerdef-wrong-namespace": "Les definiciones de capes namái son válides nes páxines del espaciu de nomes «$1»",
+ "maps-layerdef-equal-layer-name": "Los nomes de capa tienen de ser únicos dientro de la mesma páxina de capes. Otra capa yá ta usando «$1».",
+ "maps-layerpage-usage": "Páxines con mapes qu'usen la capa «$1»",
+ "maps-layerpage-nousage": "Nesti momentu denguna páxina ta usando esta capa.",
+ "maps-error-invalid-layertype": "Nun hai capes de tipu \"$1\". Sólo {{PLURAL:$3|tien sofitu esti tipu|tienen sofitu estos tipos}}: $2",
+ "maps-error-no-layertype": "Tienes d'especificar la triba de capa. {{PLURAL:$2|Sólo tien sofitu esta triba|Tienen sofitu estes tribes}}: $1",
+ "validation-error-invalid-layer": "El parámetru $1 tien de ser una capa válida.",
+ "validation-error-invalid-layers": "El parámetru $1 tien de ser una o más capes válides.",
+ "validation-error-no-non-numeric": "El parámetru «$1» tien de ser una cadena non-numbérica.",
+ "validation-error-no-non-numerics": "El parámetru «$1» tien de ser una o más cadenes non-numbériques.",
+ "maps-layer-of-type": "Capa de tipu $1",
+ "maps-layer-of-type-and-name": "Capa «$2» de tipu «$1»",
+ "maps-layer-type-supported-by": "Esta triba de capa pue emplegase {{PLURAL:$2|namái col serviciu de mapes $1|con estos servicios de mapes: $1}}.",
+ "maps-coordinates-description": "Asociador del analizador pa dar formatu a les coordenaes, dende y a cualesquiera de los formatos sofitaos.",
+ "maps-displaymap-description": "Amosar mapes xeográficos ensin dengún marcador definíu na wiki nellos.",
+ "maps-distance-description": "Convertir una distancia usando cierta unidá sofitada al equivalente utilizando otra unidá.",
+ "maps-finddestination-description": "Alcontrar un destín dende un puntu de partida (que pue tar en cualesquiera de los formatos compatibles), una orientación inicial y una distancia.",
+ "maps-geocode-description": "Activa la xeocodificación de direiciones; n'otres pallabres, tresformar llugares lleíbles por humanos en conxuntos de coordenaes. Hai sofitu pa dellos servicios de xeocodificación, que nun tienen de confundise con servicios de mapes.",
+ "maps-geodistance-description": "Calcular la distancia xeográfica ente dos puntos, dende y a cualesquiera de los formatos compatibles.",
+ "maps-mapsdoc-description": "Amosar una tabla colos parámetros d'un serviciu de mapes específicu, xunto colos valores y descripciones predeterminaos.",
+ "maps-layerdefinition-description": "Describe una capa personalizada que se pue amosar con otres funciones de Mapa.",
+ "maps-mapsdoc-par-service": "El serviciu de mapes del que se quier amosar la documentación de parámetros.",
+ "maps-mapsdoc-par-language": "La llingua na que presentar la documentación. Si esa traducción nun tuviera disponible, s'usará la versión n'inglés nel so llugar.",
+ "maps-coordinates-par-location": "Les coordenaes a les que quies dar formatu.",
+ "maps-coordinates-par-format": "El formatu destín de les coordenaes.",
+ "maps-coordinates-par-directional": "Indica si les coordenaes tienen de sacase con formatu direicional o non.",
+ "maps-par-scrollwheelzoom": "Indica si tien d'activase o non la ampliación cola rueda'l mur.",
+ "maps-distance-par-distance": "La distancia a convertir a la so equivalente nuna unidá especificada.",
+ "maps-distance-par-decimals": "El númberu máximu de díxitos fraccionarios a usar nel valor resultante.",
+ "maps-distance-par-unit": "La unidá na que sacar la distancia.",
+ "maps-finddestination-par-location": "El llugar d'aniciu.",
+ "maps-finddestination-par-bearing": "La orientación d'aniciu.",
+ "maps-finddestination-par-distance": "La distancia a percorrer.",
+ "maps-finddestination-par-format": "El formatu nel qu'amosar el destín.",
+ "maps-finddestination-par-directional": "Indica si'l formatu de destín tien de ser direicional o non.",
+ "maps-geocode-par-location": "La direición que quies xeocodificar.",
+ "maps-geocode-par-format": "El formatu pa les coordenaes resultantes.",
+ "maps-geocode-par-directional": "Indica si les coordenaes tienen de sacase con formatu direicional o non.",
+ "maps-geodistance-par-location1": "El primer puntu del conxuntu pa calcular la distancia.",
+ "maps-geodistance-par-location2": "El segundu puntu del conxuntu pa calcular la distancia.",
+ "maps-geodistance-par-unit": "La unidá na que sacar la distancia.",
+ "maps-geodistance-par-decimals": "El númberu máximu de díxitos fraccionarios a usar nel valor resultante.",
+ "maps-displaymap-par-mappingservice": "Permite configurar el serviciu de mapes que s'usará pa xenerar el mapa.",
+ "maps-displaymap-par-coordinates": "El llugar onde apaecerá'l centru'l mapa nel aniciu.",
+ "maps-displaymap-par-visitedicon": "El nome de ficheru d'una imaxe a usar pa los iconos de marcador dempués de facer clic nos marcadores orixinales",
+ "maps-displaymap-par-zoom": "Permite configurar el nivel de zoom do mapa.\nCuando nun se da y hai múltiples marcadores presentes nel mapa, se tomará'l zoom que meyor axuste, non el valor configurable predetermináu.",
+ "maps-displaymap-par-centre": "Permite configurar les coordenaes del centru do mapa pa display_point(s).\nAlmite tanto direiciones como coordenaes.\nCuando nun se da esta propiedá, el mapa centraráse nel marcador proporcionáu, o entre los marcadores proporcionaos.",
+ "maps-displaymap-par-title": "Permite configurar el testu qu'apaecerá nes ventanes emerxentes de tolos marcadores que nun tengan un títulu propiu.\nCuando s'usa xunto cola etiqueta, el títulu tará en negrina y sorrayáu.",
+ "maps-displaymap-par-label": "Permite configurar el testu qu'apaecerá nes ventanes emerxentes de tolos marcadores que nun tengan un títulu propiu.",
+ "maps-displaymap-par-icon": "Permite configurar l'iconu qu'usen tolos marcadores.",
+ "maps-displaymap-par-circles": "Círculos a amosar",
+ "maps-displaymap-par-copycoords": "Amosar un diálogu del que pueden copiase les coordenaes al facer clic nun llugar",
+ "maps-displaymap-par-lines": "Llinies a amosar",
+ "maps-displaymap-par-maxzoom": "El nivel máximu d'ampliación",
+ "maps-displaymap-par-minzoom": "El nivel mínimu d'ampliación",
+ "maps-displaymap-par-polygons": "Polígonos a amosar",
+ "maps-displaymap-par-rectangles": "Rectángulos a amosar",
+ "maps-displaymap-par-static": "Facer el mapa estáticu",
+ "maps-displaymap-par-wmsoverlay": "Usar una superposición WMS",
+ "maps-displaymap-par-geojson": "URL d'un ficheru o nome de la páxina que contien datos GeoJSON",
+ "maps-fullscreen-button": "Conmutar pantalla completa",
+ "maps-fullscreen-button-tooltip": "Ver el mapa como pantalla completa o incrustáu.",
+ "validation-error-invalid-location": "El parámetru $1 tien de ser un llugar válidu.",
+ "validation-error-invalid-locations": "El parámetru $1 tien de ser un o más llugares válidos.",
+ "validation-error-invalid-width": "El parámetru $1 tien de ser un anchor válidu.",
+ "validation-error-invalid-height": "El parámetru $1 tien de ser un altor válidu.",
+ "validation-error-invalid-distance": "El parámetru $1 tien de ser una distancia válida.",
+ "validation-error-invalid-distances": "El parámetru $1 tien de ser una o más distancies válides.",
+ "validation-error-invalid-image": "El parámetru $1 tien de ser una imaxe válida.",
+ "validation-error-invalid-images": "El parámetru $1 tien de ser una o más imaxes válides.",
+ "validation-error-invalid-goverlay": "El parámetru $1 tien de ser una superposición válida.",
+ "validation-error-invalid-goverlays": "El parámetru $1 tien de ser una o más superposiciones válides.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Llatitú:",
+ "maps-longitude": "Llonxitú:",
+ "maps-invalid-coordinates": "El valor $1 nun se reconoció como un conxuntu de coordenaes válidu.",
+ "maps_coordinates_missing": "Nun se proporcionaron coordenaes pal mapa.",
+ "maps_geocoding_failed": "{{PLURAL:$2|La siguiente direición nun se pudo|Les siguientes direiciones nun se pudieron}} xeocodificar: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|La siguiente direición nun se pudo|Les siguientes direiciones nun se pudieron}} xeocodificar y {{PLURAL:$2|s'omitió|s'omitieron}} nel mapa: $1",
+ "maps_unrecognized_coords": "Nun se {{PLURAL:$2|reconoció la siguiente coordenada|reconocieron les siguientes coordenaes}}: $1.",
+ "maps_unrecognized_coords_for": "Nun se {{PLURAL:$2|reconoció la siguiente coordenada|reconocieron les siguientes coordenaes}} y {{PLURAL:$2|s'omitió|s'omitieron}} nel mapa: $1",
+ "maps_map_cannot_be_displayed": "Nun puede amosase'l mapa.",
+ "maps-geocoder-not-available": "La carauterística de xeocodificación de mapes nun ta disponible. Nun se pue xeocodificar la to situación.",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "Permite configurar el nivel predetermináu d'ampliación del mapa.",
+ "maps-leaflet-par-layers": "La capa que va apaecer cuando se cargue'l mapa.",
+ "maps-leaflet-par-overlaylayers": "Les capas sobrepuestes qu'apaecerán cuando se cargue'l mapa.",
+ "maps-leaflet-par-maxclusterradius": "El radiu máximu que cubrirá un grupu dende'l marcador central (en pixels).",
+ "maps-leaflet-par-clusterspiderfy": "Cuando faes click nun grupu al mínimu d'ampliación, espardémoslu pa que puedan vese los marcadores.",
+ "maps_click_to_activate": "Calca p'activar el mapa",
+ "maps_centred_on": "Mapa centráu en $1, $2.",
+ "maps-par-mappingservice": "Permite configurar el serviciu de mapes que s'usará pa xenerar el mapa.",
+ "maps-par-resizable": "Permite redimensionar el mapa arrastrando de la esquina inferior drecha.",
+ "maps-par-searchmarkers": "Permite buscar marcadores específicos con un campu incrustáu nel mapa.",
+ "maps-par-zoom": "Nivel de zoom del mapa. Para los mapes con marcadores el valor predetermináu sedrá el nivel máximu d'ampliación qu'amuese tolos marcadores.",
+ "maps-par-width": "Permite configurar l'anchor del mapa. De mou predetermináu s'asume el pixel como unidá, pero se pue conseñar esplícitamente una d'estes unidaes: px, ex, em, %.",
+ "maps-par-height": "Permite configurar l'altor del mapa. De mou predetermináu s'asume el pixel como unidá, pero se pue conseñar esplícitamente una d'estes unidaes: px, ex, em, %.",
+ "maps-par-centre": "El llugar nel que se tien de centrar el mapa",
+ "maps-par-enable-fullscreen": "Activar el botón de pantalla completa",
+ "maps-par-kml": "Ficheros KML a cargar nel mapa.",
+ "maps-par-markercluster": "Permite fusionar múltiples marcadores cercanos nun solu marcador",
+ "maps-googlemaps3-incompatbrowser": "El to navegador nun ye compatible con Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Permite amestar una imaxe p'amosala nel llugar especificáu del mapa.",
+ "maps-googlemaps3-par-type": "El tipu de mapa a amosar inicialmente.",
+ "maps-googlemaps3-par-types": "Los tipos de mapa que tarán disponibles al traviés del control de tipu.",
+ "maps-googlemaps3-par-layers": "Capes especiales a cargar nel mapa.",
+ "maps-googlemaps3-par-controls": "Controles a poner nel mapa.",
+ "maps-googlemaps3-par-zoomstyle": "El estilu del control de zoom.",
+ "maps-googlemaps3-par-typestyle": "El estilo del control de tipu.",
+ "maps-googlemaps3-par-autoinfowindows": "Abrir automáticamente toles ventanes d'información dempués de que se cargue la páxina.",
+ "maps-googlemaps3-par-gkml": "Ficheros KML agospiaos por Google a cargar nel mapa.",
+ "maps-googlemaps3-par-kmlrezoom": "Axustar el nivel de zoom dempués de que carguen les capes KML.",
+ "maps-googlemaps3-par-poi": "Amosar puntos d'interés.",
+ "maps-googlemaps3-par-clustergridsize": "La midida de rexa d'un grupu en píxeles.",
+ "maps-par-clustermaxzoom": "El nivel máximu d'ampliación nel que pueden esistir grupos.",
+ "maps-par-clusterzoomonclick": "Si'l comportamientu predetermináu al facer click nun grupu ye amplialu.",
+ "maps-par-maxclusterradius": "El radiu máximu que cubrirá un cluster.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Si'l centru de cada grupu tien de ser la media de tolos marcadores del grupu.",
+ "maps-googlemaps3-par-clusterminsize": "El númberu mínimu de marcadores que tán nun grupu primero que se despinten los marcadores y s'amuese un recuentu.",
+ "mapeditor": "Editor de mapes",
+ "specialpages-group-maps": "Mapes",
+ "mapeditor-parser-error": "Hebo un error al analizar los metadatos. Inorando la entrada d'usuariu.",
+ "mapeditor-none-text": "Dengún",
+ "mapeditor-done-button": "Fecho",
+ "mapeditor-remove-button": "Desaniciar",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Esportar a códigu wiki",
+ "mapeditor-import-button": "Importar dende códigu wiki",
+ "mapeditor-select-button": "Seleicionar esti polígonu",
+ "mapeditor-mapparam-button": "Editar los parámetros del mapa",
+ "mapeditor-clear-button": "Llimpiar el mapa",
+ "mapeditor-code-title": "Códigu wiki",
+ "mapeditor-import-title": "Importar códigu wiki",
+ "mapeditor-import-note": "Ten en cuenta que'l analizador espera un formatu de códigu wiki mui estrictu. El códigu escritu equí debe coincidir col códigu producíu pola funcionalidá d'esportación.",
+ "mapeditor-form-title": "Editar detalles",
+ "mapeditor-link-title-switcher-popup-text": "Ventana emerxente con testu",
+ "mapeditor-link-title-switcher-link-text": "Enllaz",
+ "mapeditor-form-field-title": "Títulu",
+ "mapeditor-form-field-text": "Testu",
+ "mapeditor-form-field-link": "Enllaz",
+ "mapeditor-form-field-icon": "Iconu",
+ "mapeditor-form-field-group": "Grupu",
+ "mapeditor-form-field-inlinelabel": "Etiqueta en llinia",
+ "mapeditor-form-field-strokecolor": "Color de trazu",
+ "mapeditor-form-field-strokeopacity": "Opacidá del trazu",
+ "mapeditor-form-field-strokeweight": "Grosor de trazu",
+ "mapeditor-form-field-fillcolor": "Color de rellenu",
+ "mapeditor-form-field-fillopcaity": "Opacidá del rellenu",
+ "mapeditor-form-field-showonhover": "Amosar sólo al pasar el mur por encima",
+ "mapeditor-mapparam-title": "Editar los parámetros del mapa",
+ "mapeditor-mapparam-defoption": "-Seleicionar parámetru-",
+ "mapeditor-imageoverlay-button": "Amestar superposición d'imaxe",
+ "mapeditor-form-field-image": "Imaxe",
+ "mapeditor-imageoverlay-title": "Detalles de superposición d'imaxe",
+ "mapeditor-form-field-visitedicon": "Iconu visitáu",
+ "semanticmaps-unrecognizeddistance": "El valor $1 nun ye una distancia válida.",
+ "semanticmaps-kml-link": "Ver el ficheru KML",
+ "semanticmaps-default-kml-pagelink": "Ver la páxina \"$1\"",
+ "semanticmaps-latitude": "Llatitú: $1",
+ "semanticmaps-longitude": "Llonxitú: $1",
+ "semanticmaps-altitude": "Altitú: $1",
+ "semanticmaps-forminput-locations": "Llugares",
+ "semanticmaps-par-staticlocations": "Llista de llugares p'amestar al mapa xunto colos datos consultaos. Como con display_points, pues amestar un títulu, una descripción y un iconu pa cada llugar usando'l signu \"~\" como separador.",
+ "semanticmaps-par-showtitle": "Amosar o non un títulu na ventana d'información del marcador. De vezu, desactivalo ye útil cuando s'utiliza una plantía pa dar formatu al conteníu de la ventana d'información.",
+ "semanticmaps-par-hidenamespace": "Amosar el títulu del espaciu de nomes na ventana d'información del marcador.",
+ "semanticmaps-par-centre": "El centru del mapa. Cuando nun se proporciona, el mapa escoyerá automáticamente'l meyor centru p'amosar tolos marcadores del mapa.",
+ "semanticmaps-par-template": "Una plantía que s'utiliza pa dar formatu al conteníu de la ventana d'información.",
+ "semanticmaps-par-geocodecontrol": "Amosar el control de xeocodificación.",
+ "semanticmaps-par-activeicon": "Iconu a amosar en llugar del marcador predetermináu, cuando la páxina activa ye igual al resultáu de la consulta",
+ "semanticmaps-par-pagelabel": "Cuando se pon a \"si\", tolos marcadores tendrán una \"inlineLabel\" con un enllaz a la páxina que contien les coordenaes del marcador",
+ "semanticmaps-par-ajaxcoordproperty": "Nome de la propiedá de coordenaes que s'usa pa construir la consulta ajax.",
+ "semanticmaps-par-ajaxquery": "Una segunda consulta que s'unvia con ajax para recuperar otres coordenaes más.",
+ "semanticmaps-par-userparam": "Un valor pasáu en cada llamada de plantía,si s'usa una plantía",
+ "semanticmaps-kml-text": "El testu asociáu con cada páxina. Sustituyíu poles otres propiedaes consultaes, si esisten.",
+ "semanticmaps-kml-title": "El títulu predetermináu pa los resultaos",
+ "semanticmaps-kml-linkabsolute": "Si los títulos tienen de ser absolutos (lo contrario de relativos)",
+ "semanticmaps-kml-pagelinktext": "El testu a usar pa los enllaces a la páxina, onde \"$1\" se sustituye pol títulu de la páxina",
+ "semanticmaps-shapes-improperformat": "Formatu incorreutu de $1. Por favor, consulta la documentación sobre formatos",
+ "semanticmaps-shapes-missingshape": "Nun s'alcontraron formes pa $1. Por favor, consulta la documentación de les formes disponibles",
+ "validator-type-mapscircle": "Círculu xeográficu",
+ "validator-type-mapscircle-list": "Llista de círculos",
+ "validator-type-mapsimageoverlay": "Superposición d'imaxen",
+ "validator-type-mapsimageoverlay-list": "Lista de superposiciones d'imaxen",
+ "validator-type-mapsline": "Llinia xeográfica",
+ "validator-type-mapsline-list": "Llista de llinies",
+ "validator-type-mapslocation": "Allugamientu xeográficu",
+ "validator-type-mapslocation-list": "Llista d'allugamientos",
+ "validator-type-mapsrectangle": "Rectángulu xeográficu",
+ "validator-type-mapsrectangle-list": "Llista de rectángulos",
+ "validator-type-mapspolygon": "Polígonu xeográficu",
+ "validator-type-mapspolygon-list": "Llista de polígonos xeográficos",
+ "validator-type-wmsoverlay": "Superposición de Serviciu de Mapes web",
+ "validator-type-jsonfile": "testu"
+}
diff --git a/www/wiki/extensions/Maps/i18n/az.json b/www/wiki/extensions/Maps/i18n/az.json
new file mode 100644
index 00000000..5c8778f2
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/az.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cekli829"
+ ]
+ },
+ "maps_map": "Xəritə",
+ "maps-loading-map": "Xəritə yüklənir...",
+ "maps-layer-errors": "Xətalar",
+ "maps-abb-north": "Şm",
+ "maps-abb-east": "C",
+ "maps-abb-west": "Q"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ba.json b/www/wiki/extensions/Maps/i18n/ba.json
new file mode 100644
index 00000000..9d6bed5f
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ba.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Haqmar",
+ "Вильданова Гюзель"
+ ]
+ },
+ "maps-leaflet-par-defzoom": "Карталағы күҙәтеүҙе артырыуҙың кимәлен көйләргә мөмкинлек бирә",
+ "mapeditor-form-title": "Үҙгәртеү мәғлүмәттәре",
+ "mapeditor-link-title-switcher-link-text": "Һылтанма",
+ "mapeditor-form-field-title": "Исем",
+ "mapeditor-form-field-text": "Текст",
+ "mapeditor-form-field-link": "Һылтанма",
+ "mapeditor-form-field-group": "Төркөм"
+}
diff --git a/www/wiki/extensions/Maps/i18n/bar.json b/www/wiki/extensions/Maps/i18n/bar.json
new file mode 100644
index 00000000..d56a8d85
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/bar.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mucalexx"
+ ]
+ },
+ "maps-loading-map": "Korten werd gloon ..."
+}
diff --git a/www/wiki/extensions/Maps/i18n/be-tarask.json b/www/wiki/extensions/Maps/i18n/be-tarask.json
new file mode 100644
index 00000000..58b98b66
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/be-tarask.json
@@ -0,0 +1,153 @@
+{
+ "@metadata": {
+ "authors": [
+ "EugeneZelenko",
+ "Jim-by",
+ "Wizardist",
+ "Red Winged Duck",
+ "Macofe",
+ "Renessaince"
+ ]
+ },
+ "maps-desc": "Забясьпечвае магчымасьць убудаваньня дынамічных мапаў у вікі-старонкі, геаграфічнага кадаваньня адрасоў і іншыя геаграфічныя апэрацыі",
+ "right-geocode": "геаграфічнае кадаваньне",
+ "maps_map": "Мапа",
+ "maps-loading-map": "Загрузка мапы…",
+ "maps-load-failed": "Немагчыма загрузіць мапу!",
+ "maps-markers": "Пазнакі",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Фільтраваць маркеры",
+ "maps-others": "іншыя",
+ "maps-ns-layer": "Слой",
+ "maps-ns-layer-talk": "Абмеркаваньне слоя",
+ "maps-layer-property": "Уласьцівасьць",
+ "maps-layer-value": "Значэньне",
+ "maps-layer-errors": "Памылкі",
+ "maps-error-invalid-layertype": "Няма слаёў тыпу «$1». Падтрымліваецца толькі {{PLURAL:$3|1=гэты тып|гэтыя тыпы}}: $2",
+ "maps-error-no-layertype": "Вам неабходна вызначыць тып слою. {{PLURAL:$2|1=Падтрымліваецца толькі гэты тып|Падтрымліваюцца толькі гэтыя тыпы}}: $1",
+ "validation-error-invalid-layer": "Парамэтар $1 мусіць быць слушным слоем.",
+ "validation-error-invalid-layers": "Парамэтар $1 мусіць быць адным ці болей слушнымі слаямі.",
+ "maps-layer-of-type": "Слой тыпу $1",
+ "maps-layer-type-supported-by": "Гэты тып слою можа быць выкарыстаны толькі з {{PLURAL:$2|1=сэрвісам мапаў $1|сэрвісамі мапаў: $1}}.",
+ "maps-coordinates-description": "Перахопнік парсэру для фарматаваньня каардынатаў, з і ў любыя фарматы, якія падтрымліваюцца.",
+ "maps-displaymap-description": "Паказвае геаграфічныя мапы без аніякіх вікі-пазнакаў на іх.",
+ "maps-distance-description": "Канвэртуе адлегласьць выкарыстоўваючы адзінкі, якія падтрымліваюцца, ў іх эквівалент, выкарыстоўваючы іншыя адзінкі.",
+ "maps-finddestination-description": "Знаходзіць пункт прызначэньня з пададзенага пачатковага пункту (можа быць у любым фармаце, якія падтрымліваюцца), пачатковага напрамку і адлегласьці.",
+ "maps-geocode-description": "Уключае геаграфічную кадыроўку адрасу, іншымі словамі, пераўтварае чытальнае для чалавека знаходжаньне ў набор каардынатаў. Тут ёсьць падтрымка для некалькіх сэрвісаў геаграфічнай кадыроўкі, якія не павінны быць блытаныя з сэрвісамі мапаў.",
+ "maps-geodistance-description": "Падлічвае геаграфічную адлегласьць паміж двума пунктамі, з і для любога з фарматаў, якія падтрымліваюцца.",
+ "maps-mapsdoc-description": "Паказвае табліцу з парамэтрамі для пазначанага сэрвісу стварэньня мапаў разам з яго значэньнямі па змоўчваньні і апісаньнямі.",
+ "maps-mapsdoc-par-service": "Сэрвіс стварэньня мапаў, для якога паказваць дакумэнтацыю пра парамэтры.",
+ "maps-mapsdoc-par-language": "Мова, на якой паказваць дакумэнтацыю. Калі перакладу на такую мову няма, замест яе будзе выкарыстоўвацца ангельская.",
+ "maps-coordinates-par-location": "Каардынаты, якія Вы жадаеце фарматаваць.",
+ "maps-coordinates-par-format": "Мэтавы фармат для каардынатаў.",
+ "maps-coordinates-par-directional": "Паказвае, ці павінны каардынаты быць выведзены непасрэдна ці не.",
+ "maps-distance-par-distance": "Адлегласьць для канвэртаваньня ў яе эквівалент у пададзеных адзінках.",
+ "maps-distance-par-decimals": "Максымальная колькасьць лічбаў пасьля дзесятковай коскі для выкарыстаньня ў выніковым значэньні.",
+ "maps-distance-par-unit": "Адзінкі, у якіх будзе выведзеная адлегласьць.",
+ "maps-finddestination-par-location": "Пачатковае месцазнаходжаньне.",
+ "maps-finddestination-par-bearing": "Пачатковы накірунак.",
+ "maps-finddestination-par-distance": "Адлегласьць для падарожжа.",
+ "maps-finddestination-par-format": "Фармат, у якім выводзіць пункт прызначэньня.",
+ "maps-finddestination-par-directional": "Паказвае, калі фармат пункту прызначэньня павінен быць накіраваны ці не.",
+ "maps-geocode-par-location": "Адрас, які Вы жадаеце геаграфічна кадыраваць.",
+ "maps-geocode-par-format": "Фармат для выніковых каардынатаў.",
+ "maps-geocode-par-directional": "Паказвае, ці павінны каардынаты быць выведзены непасрэдна ці не.",
+ "maps-geodistance-par-location1": "Першы пункт для вылічэньня адлегласьці.",
+ "maps-geodistance-par-location2": "Другі пункт для вылічэньня адлегласьці.",
+ "maps-geodistance-par-unit": "Адзінкі, у якіх будзе выведзеная адлегласьць.",
+ "maps-geodistance-par-decimals": "Максымальная колькасьць лічбаў пасьля дзесятковай коскі для выкарыстаньня ў выніковым значэньні.",
+ "maps-displaymap-par-mappingservice": "Дазваляе ўстанаўліваць сэрвіс мапаў, які будзе выкарыстоўвацца для стварэньня мапы.",
+ "maps-displaymap-par-coordinates": "Месцазнаходжаньне, на якім мапа будзе цэнтравацца.",
+ "maps-displaymap-par-zoom": "Дазваляе зьмяняць павелічэньне мапы.\nКалі гэта немагчыма, ці на мапе ёсьць некалькі маркераў, замест пазначанага ў наладах будзе выбранае найбольш слушнае павелічэньне.",
+ "maps-displaymap-par-centre": "Дазваляе ўстанаўліваць каардынаты цэнтру мапы для display_point(s).\nПрымаюцца адрасы і каардынаты.\nКалі гэтая ўласьцівасьць не пададзеная, мапа будзе цэнтравацца на пададзеным маркеры ці паміж пададзенымі маркерамі.",
+ "maps-displaymap-par-title": "Дазваляе ўстанаўліваць тэкст, які будзе паказаны ў разгортваемым тэксьце тых маркераў, якія ня маюць асобных назваў.\nКалі выкарыстоўваецца з меткамі, назва будзе паказаная тлустым тэкстам і падкрэсьленая.",
+ "maps-displaymap-par-label": "Дазваляе ўстанаўліваць тэкст, які будзе паказаны ў разгортваемым тэксьце тых маркераў, якія ня маюць асобных метак.",
+ "maps-displaymap-par-icon": "Дазваляе ўстанаўліваць выявы для ўсіх маркераў.",
+ "validation-error-invalid-location": "Парамэтар $1 мусіць быць слушным знаходжаньнем.",
+ "validation-error-invalid-locations": "Парамэтар $1 мусіць быць адным ці болей слушнымі знаходжаньнямі.",
+ "validation-error-invalid-width": "Парамэтар $1 мусіць быць слушнай шырынёй.",
+ "validation-error-invalid-height": "Парамэтар $1 мусіць быць слушнай вышынёй.",
+ "validation-error-invalid-distance": "Парамэтар $1 мусіць быць слушнай адлегласьцю.",
+ "validation-error-invalid-distances": "Парамэтар $1 мусіць быць адной ці болей слушнымі адлегласьцямі.",
+ "validation-error-invalid-image": "Парамэтар $1 мусіць быць слушнай выявай.",
+ "validation-error-invalid-images": "Парамэтар $1 мусіць быць адной ці болей слушнымі выявамі.",
+ "validation-error-invalid-goverlay": "Парамэтар $1 мусіць быць слушным слоем.",
+ "validation-error-invalid-goverlays": "Парамэтар $1 мусіць быць адным ці болей слушнымі слаямі.",
+ "maps-abb-north": "Пн.",
+ "maps-abb-east": "У.",
+ "maps-abb-south": "Пд.",
+ "maps-abb-west": "З.",
+ "maps-latitude": "Шырата:",
+ "maps-longitude": "Даўгата:",
+ "maps-invalid-coordinates": "Значэньне $1 зьяўляецца недапушчальным наборам каардынатаў.",
+ "maps_coordinates_missing": "Каардынаты для мапы не пазначаныя.",
+ "maps_geocoding_failed": "{{PLURAL:$2|1=Наступны адрас ня можа быць геакадаваны|Наступныя адрасы ня могуць быць геакадаваныя}}: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|1=Наступны адрас ня можа быць геакадаваны і быў выдалены|Наступныя адрасы ня могуць быць геакадаваныя і былі выдаленыя}} з мапы:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|1=Наступная каардыната не была распазнаная|Наступныя каардынаты не былі распазнаныя}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|1=Наступная каардыната не была распазнаная|Наступныя каардынаты не былі распазнаныя}} і {{PLURAL:$2|1=яна не паказаная|яны не паказаныя}} на мапе:\n$1",
+ "maps_map_cannot_be_displayed": "Мапа ня можа быць паказаная.",
+ "maps-geocoder-not-available": "Магчымасьць геаграфічнага кадаваньня для мапаў недаступная. Вашае месцазнаходжаньне ня можа быць геаграфічна закадаванае.",
+ "maps_click_to_activate": "Націсьніце для актывацыі мапы",
+ "maps_centred_on": "Цэнтар мапы — $1, $2.",
+ "maps-par-resizable": "Дазваляе зьмяняць памеры мапы, перацягваючы яе ніжні правы кут.",
+ "maps-par-zoom": "Маштаб мапы. Для мапаў з пазначэньнямі маштаб будзе такім, пры якім яшчэ будуць паказвацца ўсе пазначэньні.",
+ "maps-par-width": "Дазваляе наладжваць шырыню мапы. Па змоўчваньні піксэлі выкарыстоўваюцца як адзінкі вымярэньня, але Вы можаце непасрэдна вызначыць адну з гэтых адзінак вымярэньня: px, ex, em, %.",
+ "maps-par-height": "Дазваляе наладжваць вышыню мапы. Па змоўчваньні піксэлі выкарыстоўваюцца як адзінкі вымярэньня, але Вы можаце непасрэдна вызначыць адну з гэтых адзінак вымярэньня: px, ex, em, %.",
+ "maps-par-kml": "KML-файлы для загрузкі ў мапу.",
+ "maps-googlemaps3-incompatbrowser": "Ваш браўзэр не сумяшчальны з Google Maps v3.",
+ "maps-googlemaps3-par-type": "Тып мапы, які будзе паказвацца ў пачатку.",
+ "maps-googlemaps3-par-types": "Тыпы мапаў, якія будуць даступныя праз элемэнт кіраваньня тыпамі.",
+ "maps-googlemaps3-par-layers": "Спэцыяльныя слаі для загрузкі ў мапу.",
+ "maps-googlemaps3-par-controls": "Элемэнты кіраваньня, якія будуць разьмешчаныя на мапе.",
+ "maps-googlemaps3-par-zoomstyle": "Стыль элемэнта кіраваньня маштабам.",
+ "maps-googlemaps3-par-typestyle": "Стыль элемэнта кіраваньня тыпамі.",
+ "maps-googlemaps3-par-autoinfowindows": "Аўтаматычна адкрываць ўсе інфармацыйныя вокны, пасьля таго, як старонка была загружаная.",
+ "maps-googlemaps3-par-gkml": "Файлы KML разьмешчаныя на Google для загрузкі на мапу.",
+ "maps-googlemaps3-par-kmlrezoom": "Зьмяняць маштаб мапы пасьля загрузкі KML-слаёў.",
+ "maps-googlemaps3-par-poi": "Паказаць выбітныя мясьціны.",
+ "mapeditor": "Рэдактар мап",
+ "specialpages-group-maps": "Мапы",
+ "mapeditor-parser-error": "У час разбору мэтазьвестак адбылася памылка. Ігнаруем уведзеныя зьвесткі.",
+ "mapeditor-none-text": "Нічога",
+ "mapeditor-done-button": "Зроблена",
+ "mapeditor-remove-button": "Выдаліць",
+ "mapeditor-import-button2": "Імпартаваць",
+ "mapeditor-export-button": "Экспартаваць у вікі-код",
+ "mapeditor-import-button": "Імпартаваць зь вікі-коду",
+ "mapeditor-select-button": "Выбраць гэты шматкутнік",
+ "mapeditor-mapparam-button": "Зьмяніць парамэтры мапы",
+ "mapeditor-clear-button": "Ачысьціць мапу",
+ "mapeditor-code-title": "Вікі-код",
+ "mapeditor-import-title": "Імпарт вікі-коду",
+ "mapeditor-import-note": "Заўважце, калі ласка, што парсэр апрацоўвае толькі карэктны вікі-код. Імпартаваны код на ўваходзе мусіць супадаць з экспартаваным кодам.",
+ "mapeditor-form-title": "Рэдагаваньне падрабязнасьцяў",
+ "mapeditor-link-title-switcher-popup-text": "Усплываючая падказка",
+ "mapeditor-link-title-switcher-link-text": "Спасылка",
+ "mapeditor-form-field-title": "Назва",
+ "mapeditor-form-field-text": "Тэкст",
+ "mapeditor-form-field-link": "Спасылка",
+ "mapeditor-form-field-icon": "Ікона",
+ "mapeditor-form-field-group": "Група",
+ "mapeditor-form-field-inlinelabel": "Тэкставая метка",
+ "mapeditor-form-field-strokecolor": "Колер контуру",
+ "mapeditor-form-field-strokeopacity": "Празрыстасьць контуру",
+ "mapeditor-form-field-strokeweight": "Таўшчыня контуру",
+ "mapeditor-form-field-fillcolor": "Колер зафарбоўкі",
+ "mapeditor-form-field-fillopcaity": "Празрыстасьць зафарбоўкі",
+ "mapeditor-form-field-showonhover": "Паказваць толькі пры навядзеньні",
+ "mapeditor-mapparam-title": "Зьмена парамэтраў мапы",
+ "mapeditor-mapparam-defoption": "-Выберыце парамэтар-",
+ "mapeditor-imageoverlay-button": "Накласьці выяву",
+ "mapeditor-form-field-image": "Выява",
+ "mapeditor-imageoverlay-title": "Накладаньне выявы",
+ "mapeditor-form-field-visitedicon": "Значак для наведанага",
+ "semanticmaps-unrecognizeddistance": "Значэньне $1 — няслушная адлегласьць.",
+ "semanticmaps-kml-link": "Паказаць KML-файл",
+ "semanticmaps-default-kml-pagelink": "Паказаць старонку $1",
+ "semanticmaps-forminput-locations": "Месцы",
+ "semanticmaps-par-staticlocations": "Сьпіс месцазнаходжаньняў для даданьня на мапу разам з запытанымі зьвесткамі. Напрыклад, разам з «display_points», Вы можаце дадаць назву, апісаньне і мініятуру для месцазнаходжаньня з дапамогай сымбаля «~» у якасьці разьдзяляльніка.",
+ "semanticmaps-par-showtitle": "Паказваць назву ў акне інфармацыі пра маркер ці не. Адключэньне гэтай функцыі часта карыснае падчас выкарыстаньня шаблёну для фарматаваньня зьместу акна інфармацыі.",
+ "semanticmaps-par-centre": "Цэнтар мапы. Калі ён не пададзены, мапа будзе аўтаматычна выбіраць аптымальны цэнтар для паказу ўсіх маркераў.",
+ "semanticmaps-par-template": "Шаблён для фарматаваньня зьместу акна інфармацыі.",
+ "semanticmaps-par-geocodecontrol": "Паказаць элемэнты кіраваньня геаграфічным кадаваньнем."
+}
diff --git a/www/wiki/extensions/Maps/i18n/bg.json b/www/wiki/extensions/Maps/i18n/bg.json
new file mode 100644
index 00000000..fdee0bff
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/bg.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "DCLXVI",
+ "පසිඳු කාවින්ද",
+ "StanProg",
+ "Plamen"
+ ]
+ },
+ "maps_map": "Карта",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-ns-layer": "Слой",
+ "maps-layer-value": "Стойност",
+ "maps-layer-errors": "Грешки",
+ "maps-abb-north": "С",
+ "maps-abb-east": "И",
+ "maps-abb-south": "Ю",
+ "maps-abb-west": "З",
+ "maps-latitude": "Географска ширина:",
+ "maps-longitude": "Географска дължина:",
+ "maps-googlemaps3-incompatbrowser": "Вашият браузър не е съвместим с Google Maps v3.",
+ "mapeditor": "Редактор на карти",
+ "specialpages-group-maps": "Карти",
+ "mapeditor-done-button": "Готово",
+ "mapeditor-remove-button": "Премахване",
+ "mapeditor-import-button2": "Внасяне",
+ "mapeditor-code-title": "Уики код",
+ "mapeditor-link-title-switcher-link-text": "Препратка",
+ "mapeditor-form-field-title": "Заглавие",
+ "mapeditor-form-field-text": "Текст",
+ "mapeditor-form-field-link": "Препратка",
+ "mapeditor-form-field-group": "Група"
+}
diff --git a/www/wiki/extensions/Maps/i18n/bjn.json b/www/wiki/extensions/Maps/i18n/bjn.json
new file mode 100644
index 00000000..4f1a7884
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/bjn.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ezagren"
+ ]
+ },
+ "maps-abb-north": "U",
+ "maps-abb-east": "T",
+ "maps-abb-south": "S",
+ "maps-abb-west": "B"
+}
diff --git a/www/wiki/extensions/Maps/i18n/bn.json b/www/wiki/extensions/Maps/i18n/bn.json
new file mode 100644
index 00000000..891ea3e4
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/bn.json
@@ -0,0 +1,114 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tauhid16",
+ "Wikitanvir",
+ "Aftabuzzaman",
+ "আজিজ",
+ "আফতাবুজ্জামান"
+ ]
+ },
+ "right-geocode": "জিওকোড",
+ "action-geocode": "এই উইকিতে জিওকোডিং করুন",
+ "maps_map": "মানচিত্র",
+ "maps-loading-map": "মানচিত্র লোড করা হচ্ছে...",
+ "maps-load-failed": "মানচিত্র লোড করা সম্ভব হয়নি!",
+ "maps-markers": "চিহ্নিতকারী",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "ছাকনি চিহ্নিতকারী",
+ "maps-others": "অন্যান্য",
+ "maps-kml-parsing-failed": "একটি অথবা আরও বেশি KML ফাইল পদান্বয় ব্যর্থ। সাধারণত এটি আহরণ ব্যর্থতা বা ত্রুটিপূর্ণ XML-এর কারণে ঘটে।",
+ "maps-ns-layer": "স্তর",
+ "maps-ns-layer-talk": "স্তর আলোচনা",
+ "maps-layer-property": "সম্পত্তি",
+ "maps-layer-value": "মান",
+ "maps-layer-errors": "ত্রুটি",
+ "maps-layerdef-invalid": "অবৈধ {{PLURAL:$1|সংজ্ঞা}}",
+ "maps-layerdef-invalid-fatal": "ধ্বংসাত্মক অবৈধ সংজ্ঞা",
+ "maps-layerdef-wrong-namespace": "স্তর সজ্ঞা শুধুমাত্র \"$1\" নামস্থান পাতাসমূহে বৈধ",
+ "maps-layerdef-equal-layer-name": "স্তরের নামসমূহ একই স্তর পৃষ্ঠার মধ্যে অনন্য হওয়া আবশ্যক। \"$1\" ইতিমধ্যে আরেকটি স্তর দ্বারা ব্যবহৃত হয়েছে।",
+ "maps-layerpage-usage": "\"$1\" স্তর ব্যবহৃত মানচিত্র সহ পৃষ্ঠাসমূহ",
+ "maps-layerpage-nousage": "এই মুহূর্তে কোন পৃষ্ঠায় এই স্তরটি ব্যবহার হয়নি।",
+ "maps-error-invalid-layertype": "সেখানে \"$1\" ধরনের কোন স্তর নেই। শুধু {{PLURAL:$3|এই ধরনের}} স্তর সমর্থিত হবে: $2",
+ "maps-error-no-layertype": "আপনাকে স্তরের ধরন নির্দিষ্ট করতে হবে। শুধু {{PLURAL:$2|এই ধরনের}} স্তর সমর্থিত: $1",
+ "validation-error-invalid-layer": "\"$1\" পরামিতি অবশ্যই বৈধ স্তর হতে হবে।",
+ "validation-error-invalid-layers": "\"$1\" পরামিতি অবশ্যই এক বা একাধিক বৈধ স্তর হতে হবে।",
+ "validation-error-no-non-numeric": "\"$1\" পরামিতি অবশ্যই অ-সাংখ্যিক স্ট্রিং হতে হবে।",
+ "validation-error-no-non-numerics": "\"$1\" পরামিতি অবশ্যই এক বা একাধিক অ-সাংখ্যিক স্ট্রিং হতে হবে।",
+ "maps-layer-of-type": "\"$1\" ধরণের লেয়ার",
+ "maps-layer-of-type-and-name": "\"$2\" স্তরটি \"$1\" ধরণের",
+ "maps-par-scrollwheelzoom": "নির্দেশ করে যদি মাউস স্ক্রোলিং সক্রিয় করা উচিত বা উচিত না।",
+ "maps-finddestination-par-location": "প্রারম্ভিক অবস্থান",
+ "maps-finddestination-par-distance": "ভ্রমণ করার ব্যবধান",
+ "maps-displaymap-par-geojson": "একটি GeoJSON ফাইলের URL",
+ "validation-error-invalid-location": "স্থিতিমাপ \"$1\" একটি বৈধ অবস্থান হতে হবে।",
+ "validation-error-invalid-locations": "\"$1\" পরামিতি অবশ্যই এক বা একাধিক বৈধ অবস্থান হতে হবে।",
+ "validation-error-invalid-width": "\"$1\" পরামিতি অবশ্যই বৈধ প্রস্থ বিশিষ্ঠ হতে হবে।",
+ "validation-error-invalid-height": "\"$1\" পরামিতি অবশ্যই বৈধ উচ্চতা বিশিষ্ঠ হতে হবে।",
+ "validation-error-invalid-distance": "\"$1\" পরামিতি অবশ্যই বৈধ দূরত্ব বিশিষ্ঠ হতে হবে।",
+ "validation-error-invalid-distances": "\"$1\" পরামিতি অবশ্যই এক বা একাধিক বৈধ দূরত্ব বিশিষ্ঠ হতে হবে।",
+ "validation-error-invalid-image": "\"$1\" পরামিতি অবশ্যই বৈধ চিত্র যুক্ত হতে হবে।",
+ "validation-error-invalid-images": "\"$1\" পরামিতি অবশ্যই এক বা একাধিক বৈধ চিত্র যুক্ত হতে হবে।",
+ "validation-error-invalid-goverlay": "\"$1\" পরামিতি অবশ্যই বৈধ আচ্ছদন হতে হবে।",
+ "validation-error-invalid-goverlays": "\"$1\" পরামিতি অবশ্যই এক বা একাধিক বৈধ আচ্ছদন হতে হবে।",
+ "maps-abb-north": "উ",
+ "maps-abb-east": "পূ",
+ "maps-abb-south": "দ",
+ "maps-abb-west": "প",
+ "maps-latitude": "অক্ষাংশ:",
+ "maps-longitude": "দ্রাঘিমাংশ:",
+ "maps_coordinates_missing": "মানচিত্রের জন্য স্থানাঙ্ক প্রদান করা হয়নি।",
+ "maps_map_cannot_be_displayed": "এই মানচিত্রটি প্রদর্শন করা সম্ভব নয়।",
+ "maps-geocoder-not-available": "মানচিত্রে জিওকোডিং বৈশিষ্টটি উপলব্ধ নয়। আপনার অবস্থান জিওকোডেড করা যাবে না।",
+ "maps_leaflet": "প্রচারপত্র",
+ "maps_click_to_activate": "মানচিত্র চালু করতে ক্লিক করুন",
+ "maps_centred_on": "মানচিত্র $1, $2-এ কেন্দ্রীভূত।",
+ "maps-googlemaps3-par-poi": "আগ্রহের বিষয়সমূহ দেখাও।",
+ "mapeditor": "মানচিত্র সম্পাদক",
+ "specialpages-group-maps": "মানচিত্র",
+ "mapeditor-parser-error": "মেটাডেটা বিশ্লেষণ করার সময় একটি ত্রুটি ঘটেছে। ব্যবহারকারীর ইনপুট উপেক্ষা করা হয়েছে।",
+ "mapeditor-none-text": "কিছু নয়",
+ "mapeditor-done-button": "সম্পন্ন",
+ "mapeditor-remove-button": "সরান",
+ "mapeditor-import-button2": "আমদানি",
+ "mapeditor-export-button": "উইকি কোডে রপ্তানি করুন",
+ "mapeditor-import-button": "উইকি কোড থেকে আমদানি করুন",
+ "mapeditor-select-button": "এই বহুভুজ নির্বাচন করুন",
+ "mapeditor-mapparam-button": "মানচিত্রের পরামিতিগুলো সম্পাদনা করুন",
+ "mapeditor-clear-button": "মানচিত্র সাফ করুন",
+ "mapeditor-code-title": "উইকি কোড",
+ "mapeditor-import-title": "উইকি কোড আমদানি করুন",
+ "mapeditor-form-title": "তথ্য সংশোধন করুন",
+ "mapeditor-link-title-switcher-link-text": "সংযোগ",
+ "mapeditor-form-field-title": "শিরোনাম",
+ "mapeditor-form-field-text": "লেখা",
+ "mapeditor-form-field-link": "সংযোগ",
+ "mapeditor-form-field-icon": "আইকন",
+ "mapeditor-form-field-group": "দল",
+ "mapeditor-form-field-strokecolor": "রেখার রং",
+ "mapeditor-form-field-strokeopacity": "রেখার অস্পষ্টতা",
+ "mapeditor-form-field-strokeweight": "রেখার প্রস্থ",
+ "mapeditor-mapparam-title": "মানচিত্রের পরামিতিগুলো সম্পাদনা করুন",
+ "mapeditor-mapparam-defoption": "-পরামিতি বাছাই করুন-",
+ "mapeditor-imageoverlay-button": "চিত্র আচ্ছাদন যোগ করুন",
+ "mapeditor-form-field-image": "চিত্র",
+ "mapeditor-imageoverlay-title": "চিত্র আচ্ছদনের খুঁটিনাটি",
+ "semanticmaps-kml-link": "কেএমএল ফাইল দেখাও",
+ "semanticmaps-default-kml-pagelink": "$1 পাতা প্রদর্শন করো",
+ "semanticmaps-latitude": "অক্ষাংশ: $1",
+ "semanticmaps-longitude": "দ্রাঘিমাংশ: $1",
+ "semanticmaps-altitude": "উচ্চতা: $1",
+ "semanticmaps-forminput-locations": "অবস্থান",
+ "validator-type-mapscircle": "ভৌগলিক বৃত্ত",
+ "validator-type-mapscircle-list": "বৃত্তের তালিকা",
+ "validator-type-mapsimageoverlay": "চিত্র প্রতিস্থাপক",
+ "validator-type-mapsimageoverlay-list": "চিত্র প্রতিস্থাপকের তালিকা",
+ "validator-type-mapsline": "ভৌগলিক রেখা",
+ "validator-type-mapsline-list": "রেখার তালিকা",
+ "validator-type-mapslocation": "ভৌগলিক অবস্থান",
+ "validator-type-mapslocation-list": "অবস্থানগুলির তালিকা",
+ "validator-type-mapsrectangle": "ভৌগলিক আয়তক্ষেত্র",
+ "validator-type-mapsrectangle-list": "আয়তক্ষেত্রের তালিকা",
+ "validator-type-mapspolygon": "ভৌগলিক বহুভুজ",
+ "validator-type-mapspolygon-list": "ভৌগলিক বহুভুজের তালিকা"
+}
diff --git a/www/wiki/extensions/Maps/i18n/br.json b/www/wiki/extensions/Maps/i18n/br.json
new file mode 100644
index 00000000..3e172bb1
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/br.json
@@ -0,0 +1,127 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fohanno",
+ "Fulup",
+ "Y-M D",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Aotren a ra ensoc'hañ kartennoù dinamek er pajennoù wiki, geokodañ chomlec'hioù hag oberiadennoù douaroniel all",
+ "right-geocode": "Geokod",
+ "maps_map": "Kartenn",
+ "maps-loading-map": "O kargañ ar gartenn...",
+ "maps-load-failed": "N'eus ket bet gallet kargañ ar gartenn !",
+ "maps-markers": "Merkerioù",
+ "maps-copycoords-prompt": "CTRL+C, KAS",
+ "maps-searchmarkers-text": "Merkerioù sil",
+ "maps-others": "re all",
+ "maps-ns-layer": "Gwiskad",
+ "maps-ns-layer-talk": "Kaozeadenn ar gwiskad",
+ "maps-layer-property": "Perzh",
+ "maps-layer-value": "Talvoudenn",
+ "maps-layer-errors": "Fazioù",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Termenadur|Termenadurioù}} direizh",
+ "maps-layerpage-usage": "Pajennoù gant kartennoù hag a implij ar gwiskad \"$1\"",
+ "maps-layerpage-nousage": "N'eus pajenn ebet hag a implij ar gwiskad-mañ evit poent.",
+ "maps-error-invalid-layertype": "N'eus ket a wiskad a seurt gant \"$1\". N'eo skoret nemet ar {{PLURAL:$3|seurt-mañ|seurtoù-mañ}} : $2",
+ "maps-error-no-layertype": "Ret eo deoc'h spisaat ar seurt gwiskad. N'eo skoret nemet ar {{PLURAL:$2|seurt-mañ|seurtoù-mañ}} : $1",
+ "validation-error-invalid-layer": "Rankout a ra an arventenn $1 bezañ ur gwiskad reizh.",
+ "validation-error-invalid-layers": "Rankout a ra an arventenn $1 bezañ evit ur gwiskad reizh, pe evit meur a hini.",
+ "maps-layer-of-type": "Gwiskad a seurt $1",
+ "maps-layer-of-type-and-name": "Gwiskad \"$2\" eus ar seurt \"$1\"",
+ "maps-layer-type-supported-by": "N'hall ar seurt gwiskad-mañ {{PLURAL:$2|bezañ implijet nemet gant ar sevij kartennaouiñ $1|bezañ implijet nemet gant ar servijoù kartennaouiñ-mañ : $1}}.",
+ "maps-geodistance-description": "Jediñ an hed douaroniel etre daou bik, adalek ha war-zu ne vern pe furmad skoret.",
+ "maps-coordinates-par-location": "An daveennoù a fell deoc'h furmadiñ.",
+ "maps-finddestination-par-location": "Al lec'hiadur orin.",
+ "maps-finddestination-par-bearing": "An durc'hadur orin.",
+ "maps-finddestination-par-distance": "An hed da vont drezañ.",
+ "maps-geocode-par-location": "Ar chomlec'h da c'heokodiñ.",
+ "maps-geocode-par-format": "Furmad an daveennoù savet da-heul.",
+ "maps-displaymap-par-circles": "Kelc'hioù da ziskwel",
+ "maps-displaymap-par-lines": "Linennoù da ziskwel",
+ "maps-displaymap-par-maxzoom": "Live zoum uhelañ",
+ "maps-displaymap-par-minzoom": "Live zoum izelañ",
+ "maps-displaymap-par-polygons": "Lieskornegoù da ziskwel",
+ "maps-displaymap-par-rectangles": "Hirgarrezennoù da ziskwel",
+ "maps-displaymap-par-static": "Lakaat ar gartenn da vezañ statek",
+ "maps-fullscreen-button": "Gweredekaat ar skramm leun",
+ "validation-error-invalid-location": "Rankout a ra an arventenn $1 bezañ evit ul lec'hiadur reizh.",
+ "validation-error-invalid-locations": "Rankout a ra an arventenn $1 bezañ evit ul lec'hiadur reizh, da nebeutañ.",
+ "validation-error-invalid-width": "Rankout a ra an arventenn $1 bezañ evit ul ledander reizh.",
+ "validation-error-invalid-height": "Rankout a ra an arventenn $1 bezañ evit un uhelder reizh.",
+ "validation-error-invalid-distance": "Rankout a ra an arventenn $1 bezañ evit un hed reizh.",
+ "validation-error-invalid-distances": "Rankout a ra an arventenn $1 bezañ evit un hed reizh, da nebeutañ.",
+ "validation-error-invalid-image": "Rankout a ra an arventenn $1 bezañ ur skeudenn reizh.",
+ "validation-error-invalid-images": "Rankout a ra an arventenn $1 bezañ ur skeudenn reizh, pe meur a hini.",
+ "validation-error-invalid-goverlay": "Rankout a ra an arventenn $1 bezañ evit ur goloadur reizh.",
+ "validation-error-invalid-goverlays": "Rankout a ra an arventenn $1 bezañ evit ur goloadur reizh, da nebeutañ.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "R",
+ "maps-abb-south": "S",
+ "maps-abb-west": "K",
+ "maps-latitude": "Ledred :",
+ "maps-longitude": "Hedred :",
+ "maps-invalid-coordinates": "N'eo ket bet anavezet an dalvoudenn $1 evel ur stroll daveennoù reizh.",
+ "maps_coordinates_missing": "N'eus bet spisaet daveenn ebet evit ar gartenn.",
+ "maps_geocoding_failed": "N'eus ket bet gallet geokodañ ar {{PLURAL:$2|chomlec'h|chomlec'h}} da-heul : $1.\nN'haller ket diskwel ar gartenn.",
+ "maps_geocoding_failed_for": "N'eus ket bet gallet geokodañ ar {{PLURAL:$2|chomlec'h|chomlec'h}} da-heul, setu {{PLURAL:$2|n'eo|n'int}} ket bet lakaet war ar gartenn :\n$1",
+ "maps_unrecognized_coords": "N'eo ket bet anavezet an {{PLURAL:$2|daveenn|daveennoù}} da-heul : $1.",
+ "maps_unrecognized_coords_for": "N'eo ket bet anavezet an {{PLURAL:$2|daveenn|daveennoù}} da-heul ha {{PLURAL:$2|n'eo|n'int}} ket bet lakaet war ar gartenn :\n$1",
+ "maps_map_cannot_be_displayed": "N'hall ket ar gartenn bezañ diskwelet.",
+ "maps-geocoder-not-available": "N'haller ket ober gant arc'hwel geokodañ ar c'hartennoù. N'haller ket geokodañ ho lec'hiadur.",
+ "maps_leaflet": "Plegfollenn",
+ "maps_click_to_activate": "Klikañ evit gweredekaat ar gartenn",
+ "maps_centred_on": "Kartenn kreizet war $1, $2.",
+ "maps-par-enable-fullscreen": "Gweredekaat ar bouton skramm leun",
+ "maps-par-kml": "Restroù KML da gargañ war ar gartenn.",
+ "maps-googlemaps3-incompatbrowser": "N'eo ket kenglotus ho merdeer gant Google Maps v3.",
+ "maps-googlemaps3-par-type": "Ar seurt kartenn da ziskouez da gentañ.",
+ "maps-googlemaps3-par-layers": "Gwiskadoù arbennik da gargañ war ar gartenn.",
+ "maps-googlemaps3-par-controls": "Ar c'hontrolloù da lakaat war ar gartenn.",
+ "maps-googlemaps3-par-zoomstyle": "Stil kontroll ar zoum.",
+ "maps-googlemaps3-par-typestyle": "Stil kontroll ar seurt.",
+ "maps-googlemaps3-par-autoinfowindows": "Digeriñ an holl brenestroù diouzhtu goude bezañ karget ar bajenn.",
+ "maps-googlemaps3-par-poi": "Diskouez al lec'hioù dudius.",
+ "mapeditor": "Aozer kartennoù",
+ "specialpages-group-maps": "Kartennoù",
+ "mapeditor-none-text": "Hini ebet",
+ "mapeditor-done-button": "Graet",
+ "mapeditor-remove-button": "Dilemel",
+ "mapeditor-import-button2": "Enporzhiañ",
+ "mapeditor-select-button": "Diuzañ al liestaleg-mañ",
+ "mapeditor-mapparam-button": "Aozañ arventennoù ar gartenn",
+ "mapeditor-clear-button": "Diverkañ ar gartenn",
+ "mapeditor-code-title": "Kod wiki",
+ "mapeditor-import-title": "Enporzhiañ ar c'hod wiki",
+ "mapeditor-form-title": "Aozañ ar munudoù",
+ "mapeditor-link-title-switcher-link-text": "Liamm",
+ "mapeditor-form-field-title": "Titl",
+ "mapeditor-form-field-text": "Testenn",
+ "mapeditor-form-field-link": "Liamm",
+ "mapeditor-form-field-icon": "Arlun",
+ "mapeditor-form-field-group": "Strollad",
+ "mapeditor-form-field-inlinelabel": "Label enlinenn",
+ "mapeditor-form-field-fillcolor": "Liv leuniañ",
+ "mapeditor-mapparam-title": "Kemmañ arventennoù ar gartenn",
+ "mapeditor-mapparam-defoption": "-Diuzañ un arventenn-",
+ "mapeditor-form-field-image": "Skeudenn",
+ "mapeditor-form-field-visitedicon": "Arlun gweladennet",
+ "semanticmaps-unrecognizeddistance": "An talvoud $1 n'eo ket un hed reizh anezhañ.",
+ "semanticmaps-kml-link": "Gwelet ar restr KML",
+ "semanticmaps-default-kml-pagelink": "Gwelet ar pennad $1",
+ "semanticmaps-latitude": "Ledred : $1",
+ "semanticmaps-longitude": "Hedred : $1",
+ "semanticmaps-altitude": "Uhelder : $1",
+ "semanticmaps-forminput-locations": "Lec'hiadurioù",
+ "semanticmaps-par-template": "Ur patrom d'ober gantañ da furmadiñ boued ar prenestr titouriñ.",
+ "semanticmaps-kml-title": "Titl dre ziouer evit an disoc'hoù",
+ "validator-type-mapscircle": "Kelc'h douaroniel",
+ "validator-type-mapscircle-list": "Roll kelc'hioù",
+ "validator-type-mapsline": "Linenn zouaroniel",
+ "validator-type-mapsline-list": "Roll linennoù",
+ "validator-type-mapslocation": "Lec'hiadur douaroniel",
+ "validator-type-mapslocation-list": "Roll lec'hiadurioù",
+ "validator-type-mapsrectangle": "Higarrezenn zouaroniel",
+ "validator-type-mapsrectangle-list": "Roll hirgarrezennoù"
+}
diff --git a/www/wiki/extensions/Maps/i18n/bs.json b/www/wiki/extensions/Maps/i18n/bs.json
new file mode 100644
index 00000000..86027688
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/bs.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "CERminator",
+ "KWiki",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Daje umetanje dinamičkih mapa u wiki stranice, geokodiranje adresa i druge geografske operacije",
+ "maps_map": "Mapa",
+ "maps-loading-map": "Učitavam kartu...",
+ "maps-markers": "Markeri",
+ "maps-others": "ostali",
+ "maps-ns-layer": "Sloj",
+ "maps-ns-layer-talk": "Razgovor o sloju",
+ "maps-layer-property": "Svojstvo",
+ "maps-layer-value": "Vrijednost",
+ "maps-layer-errors": "Greške",
+ "maps-error-invalid-layertype": "Nema slojeva tipa \"$1\". Samo {{PLURAL:$3|je ovaj tip podržan|su ovi tipovi podržani}}: $2",
+ "maps-error-no-layertype": "Morate odrediti tip sloja. {{PLURAL:$2|Samo ovaj tip je podržan|Ovi tipovi su podržani}}: $1",
+ "validation-error-invalid-layer": "Parametar $1 mora biti valjani sloj.",
+ "validation-error-invalid-layers": "Parametar $1 mora biti jedan ili više valjanih slojeva.",
+ "maps-layer-of-type": "Sloj tipa $1",
+ "maps-layer-type-supported-by": "Ovaj tip sloja može biti korišten {{PLURAL:$2|samo s $1 uslugom kartografiranja|s ovim uslugama kartografiranja: $1}}.",
+ "validation-error-invalid-location": "Parametar $1 mora biti valjana lokacija.",
+ "validation-error-invalid-locations": "Parametar $1 mora biti jedna ili više valjanih lokacija.",
+ "validation-error-invalid-width": "Parametar $1 mora biti valjana širina.",
+ "validation-error-invalid-height": "Parametar $1 mora biti valjana visina.",
+ "validation-error-invalid-distance": "Parametar $1 mora biti ispravno odstojanje.",
+ "validation-error-invalid-distances": "Parametar $1 mora biti jedna ili više valjanih udaljenosti.",
+ "validation-error-invalid-image": "Parametar $1 mora biti valjana slika.",
+ "validation-error-invalid-images": "Parametar $1 mora biti jedna ili više valjanih slika.",
+ "validation-error-invalid-goverlay": "Parametar $1 mora biti valjan sloj.",
+ "validation-error-invalid-goverlays": "Parametar $1 mora biti jedan ili više valjanih slojeva.",
+ "maps-abb-north": "S",
+ "maps-abb-east": "I",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Geografska širina:",
+ "maps-longitude": "Geografska dužina:",
+ "maps-invalid-coordinates": "Vrijednost $1 nije prepoznata kao valjan set koordinati.",
+ "maps_coordinates_missing": "Za mapu nisu navedene koordinate.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Slijedeća adresa nije mogla biti geokodirana|Slijedeće adrese nisu mogle biti geokodirane}}: $1.\nMapa se ne može prikazati.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Slijedeća adresa nije|Slijedeće adrese nisu}} mogle biti geokodiranje i {{PLURAL:$2|izostavljena je|izostavljene su}} iz mape:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Slijedeća koordinata nije prepoznata|Slijedeće koordinate nisu prepoznate}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Slijedeća koordinata nije|Slijedeće koordinate nisu}} prepoznate i {{PLURAL:$2|ignorirana je|ignorirane su}} na karti:\n$1",
+ "maps_map_cannot_be_displayed": "Karta se ne može prikazati.",
+ "maps-geocoder-not-available": "Mogućnost geokodiranja na Mapama nije dostupna. Vaša lokacija ne može biti geokodirana.",
+ "maps_click_to_activate": "Kliknite da aktivirate kartu",
+ "maps_centred_on": "Karta centrirana na $1, $2."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ca.json b/www/wiki/extensions/Maps/i18n/ca.json
new file mode 100644
index 00000000..1d3e73e6
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ca.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Paucabot",
+ "PerroVerd",
+ "Toniher"
+ ]
+ },
+ "maps_map": "Mapa",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definició no vàlida|Definicions no vàlides}}",
+ "maps-layerdef-wrong-namespace": "Les definicions de capes només són vàlides en pàgines de l'espai de noms «$1»",
+ "maps-layerpage-nousage": "Cap pàgina està utilitzant aquesta capa de moment.",
+ "validation-error-no-non-numerics": "El paràmetre «$1» ha de ser una o més cadenes no numèriques.",
+ "maps-layer-of-type-and-name": "Capa «$2» de tipus «$1»",
+ "validation-error-invalid-locations": "El paràmetre «$1» ha de ser una o més ubicacions vàlides.",
+ "validation-error-invalid-width": "El paràmetre «$1» ha de ser una amplada vàlida.",
+ "validation-error-invalid-height": "El paràmetre «$1» ha de ser una alçada vàlida.",
+ "validation-error-invalid-distance": "El paràmetre «$1» ha de ser una distància vàlida.",
+ "validation-error-invalid-distances": "El paràmetre «$1» ha de ser una o més distàncies vàlides.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitud:",
+ "maps-longitude": "Longitud:",
+ "maps_coordinates_missing": "No s'han proporcionat coordenades pel mapa.",
+ "maps_centred_on": "Mapa centrat en $1, $2."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ce.json b/www/wiki/extensions/Maps/i18n/ce.json
new file mode 100644
index 00000000..9e323da3
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ce.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Умар"
+ ]
+ },
+ "maps-others": "кхин",
+ "maps-ns-layer-talk": "ГӀатан дийцаре",
+ "maps-layer-property": "Билгало",
+ "maps-layer-value": "МаьӀна",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Ца магийна билгалдакхар|Ца магийна билгалдакхарш}}",
+ "maps-layerpage-usage": "Картанаш долу агӀоно лелош ю «$1»",
+ "validation-error-invalid-layer": "Параметр $1 нийса хила еза.",
+ "maps-layer-of-type": "Тайпан $1 чкъор",
+ "maps-layer-of-type-and-name": "Тайпан «$1» «$2» чкъор",
+ "validation-error-invalid-image": "Параметр $1 хила еза нийса сурт.",
+ "maps-abb-east": "Цу",
+ "maps-latitude": "Шоралла:",
+ "maps-longitude": "Дохалла:",
+ "mapeditor": "Картанаш тадерг",
+ "specialpages-group-maps": "Карташ",
+ "mapeditor-done-button": "Кийчча ю",
+ "mapeditor-export-button": "Экспорт ян викийоза сана",
+ "mapeditor-import-button": "Импорт ян викийозанах",
+ "mapeditor-mapparam-button": "Картан параметраш нисъе",
+ "mapeditor-clear-button": "ЦӀанде карта",
+ "mapeditor-link-title-switcher-link-text": "Хьажорг",
+ "mapeditor-form-field-title": "ЦӀе",
+ "mapeditor-form-field-link": "Хьажорг",
+ "mapeditor-mapparam-title": "Картан параметраш нисъе",
+ "mapeditor-imageoverlay-button": "ТӀетоха сурт тӀе диллар",
+ "mapeditor-form-field-image": "Сурт",
+ "mapeditor-imageoverlay-title": "Сурт"
+}
diff --git a/www/wiki/extensions/Maps/i18n/cs.json b/www/wiki/extensions/Maps/i18n/cs.json
new file mode 100644
index 00000000..1e2e22c1
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/cs.json
@@ -0,0 +1,91 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mormegil",
+ "Vks",
+ "Utar",
+ "XenoPheX",
+ "Ilimanaq29"
+ ]
+ },
+ "right-geocode": "Geokódování",
+ "maps_map": "Mapa",
+ "maps-markers": "Značky",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "ostatní",
+ "maps-ns-layer": "Vrstva",
+ "maps-ns-layer-talk": "Diskuse k vrstvě",
+ "maps-layer-property": "Vlastnost",
+ "maps-layer-value": "Hodnota",
+ "maps-layer-errors": "Chyby",
+ "maps-layer-of-type": "Vrstvy typu $1",
+ "maps-par-scrollwheelzoom": "Ukazuje, jestli by mělo být posouvání stránky myší povoleno nebo ne.",
+ "maps-finddestination-par-location": "Původní umístění.",
+ "maps-displaymap-par-circles": "Kruhy pro zobrazení",
+ "maps-displaymap-par-lines": "Kruhy ke zobrazení",
+ "maps-displaymap-par-maxzoom": "Maximální přiblížení",
+ "maps-displaymap-par-minzoom": "Minimální přiblížení",
+ "maps-displaymap-par-polygons": "Mnohoúhelníky ke zobrazení",
+ "maps-displaymap-par-rectangles": "Obdélníky ke zobrazení",
+ "validation-error-invalid-location": "Parametr $1 musí být platné umístění.",
+ "validation-error-invalid-locations": "Parametr $1 musí být jedeno nebo více platných umístění.",
+ "validation-error-invalid-width": "Parametr $1 musí být platná šířka.",
+ "validation-error-invalid-height": "Parametr $1 musí být platná výška.",
+ "validation-error-invalid-distance": "Parametr $1 musí být platná vzdálenost.",
+ "validation-error-invalid-distances": "Parametr $1 musí být jedna nebo více platných vzdáleností.",
+ "validation-error-invalid-image": "Parametr $1 musí být platný obrázek.",
+ "validation-error-invalid-images": "Parametr $1 musí být jeden nebo více platných obrázků.",
+ "maps-abb-north": "S",
+ "maps-abb-east": "V",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Zeměpisná šířka:",
+ "maps-longitude": "Zeměpisná délka:",
+ "maps_map_cannot_be_displayed": "Nelze zobrazit mapu.",
+ "maps_click_to_activate": "Mapu aktivujete kliknutím",
+ "maps-googlemaps3-par-poi": "Zobrazit body zájmu.",
+ "mapeditor": "Editor map",
+ "specialpages-group-maps": "Mapy",
+ "mapeditor-none-text": "Nic",
+ "mapeditor-done-button": "Hotovo",
+ "mapeditor-remove-button": "Odstranit",
+ "mapeditor-import-button2": "Importovat",
+ "mapeditor-export-button": "Export do wiki kódu",
+ "mapeditor-import-button": "Import z wiki kódu",
+ "mapeditor-select-button": "Vyberte tento mnohoúhelník",
+ "mapeditor-mapparam-button": "Upravit parametry mapy",
+ "mapeditor-clear-button": "Vyprázdnit mapu",
+ "mapeditor-code-title": "Kód wiki",
+ "mapeditor-import-title": "Importovat wiki kód",
+ "mapeditor-form-title": "Upravit podrobnosti",
+ "mapeditor-link-title-switcher-link-text": "Odkaz",
+ "mapeditor-form-field-title": "Oslovení",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Odkaz",
+ "mapeditor-form-field-icon": "Ikona",
+ "mapeditor-form-field-group": "Skupina",
+ "mapeditor-form-field-strokecolor": "Barva tahu",
+ "mapeditor-form-field-strokeopacity": "Krytí tahu",
+ "mapeditor-form-field-strokeweight": "Váha tahu",
+ "mapeditor-form-field-fillcolor": "Barva výplně",
+ "mapeditor-form-field-fillopcaity": "Krytí výplně",
+ "mapeditor-form-field-showonhover": "Zobrazit pouze pod myší",
+ "mapeditor-form-field-image": "Obrázek",
+ "mapeditor-form-field-visitedicon": "Navštívená ikona",
+ "semanticmaps-unrecognizeddistance": "Hodnota $1 není platná vzdálenost.",
+ "semanticmaps-kml-link": "Zobrazit soubor KML",
+ "semanticmaps-default-kml-pagelink": "Zobrazit stránku $1",
+ "semanticmaps-latitude": "Z. šířka: $1",
+ "semanticmaps-longitude": "Z. délka: $1",
+ "semanticmaps-altitude": "Nadm. výška: $1",
+ "semanticmaps-forminput-locations": "Místa",
+ "semanticmaps-par-staticlocations": "Seznam míst, která se přidají do mapy spolu s dotazovanými daty. Podobně jako u display_points můžete každé místo doplnit o titulek, popis a ikonu, za použití tildy „~“ jako oddělovače.",
+ "semanticmaps-par-showtitle": "Zobrazovat název v info okně značky či ne. Vypnutí je často užitečné, pokud je obsah informačního okna formátován pomocí šablony.",
+ "semanticmaps-par-centre": "Střed mapy. Není-li specifikován, mapa automaticky vybere optimální střed tak, aby byly zobrazeny všechny značky na ní.",
+ "semanticmaps-par-template": "Šablona formátování obsahu informačního okna",
+ "semanticmaps-par-geocodecontrol": "Zobrazit ovladač geocodingu.",
+ "semanticmaps-kml-text": "Text je přidružený ke každé stránce. Je přepsán dodatečnými dotazovanými vlastnostmi, jsou-li nějaké.",
+ "semanticmaps-kml-title": "Výchozí titulek pro výsledky",
+ "semanticmaps-kml-linkabsolute": "Mají být odkazy absolutní či ne (tj. relativní)",
+ "semanticmaps-kml-pagelinktext": "Text, který bude použit pro odkazy na stránku, ve kterém bude $1 nahrazeno názvem stránky"
+}
diff --git a/www/wiki/extensions/Maps/i18n/cu.json b/www/wiki/extensions/Maps/i18n/cu.json
new file mode 100644
index 00000000..8fd970fb
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/cu.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "ОйЛ"
+ ]
+ },
+ "maps-layer-errors": "блаꙁнꙑ"
+}
diff --git a/www/wiki/extensions/Maps/i18n/cv.json b/www/wiki/extensions/Maps/i18n/cv.json
new file mode 100644
index 00000000..dec01b43
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/cv.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chuvash2014"
+ ]
+ },
+ "mapeditor-form-field-image": "Ӳкерчĕк"
+}
diff --git a/www/wiki/extensions/Maps/i18n/da.json b/www/wiki/extensions/Maps/i18n/da.json
new file mode 100644
index 00000000..747f6d39
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/da.json
@@ -0,0 +1,64 @@
+{
+ "@metadata": {
+ "authors": [
+ "Christian List",
+ "Peter Alberti",
+ "Saederup92"
+ ]
+ },
+ "maps_map": "Kort",
+ "maps-loading-map": "Indlæser kort...",
+ "maps-load-failed": "Kunne ikke indlæse kortet!",
+ "maps-markers": "Markører",
+ "maps-others": "andre",
+ "maps-ns-layer": "Lag",
+ "maps-layer-property": "Egenskab",
+ "maps-layer-value": "Værdi",
+ "maps-layer-errors": "Fejl",
+ "maps-layer-of-type": "Lag af typen \"$1\"",
+ "maps-layer-of-type-and-name": "Lag \"$2\" af typen \"$1\"",
+ "maps-displaymap-par-circles": "Cirkler at vise",
+ "maps-displaymap-par-lines": "Linjer at vise",
+ "maps-fullscreen-button": "Slå fuldskærm til eller fra",
+ "maps-abb-north": "N",
+ "maps-abb-east": "Ø",
+ "maps-abb-south": "S",
+ "maps-abb-west": "V",
+ "maps-latitude": "Breddegrad:",
+ "maps-longitude": "Længdegrad:",
+ "maps_map_cannot_be_displayed": "Kortet kan ikke vises.",
+ "maps_click_to_activate": "Tryk for at aktivere kort",
+ "maps-par-enable-fullscreen": "Aktiver fuldskærmknappen",
+ "specialpages-group-maps": "Kort",
+ "mapeditor-none-text": "Ingen",
+ "mapeditor-done-button": "Udført",
+ "mapeditor-remove-button": "Fjern",
+ "mapeditor-import-button2": "Importer",
+ "mapeditor-export-button": "Eksporter til wiki kode",
+ "mapeditor-import-button": "Importer fra wiki kode",
+ "mapeditor-clear-button": "Tøm kort",
+ "mapeditor-code-title": "Wiki kode",
+ "mapeditor-import-title": "Importer wiki kode",
+ "mapeditor-form-title": "Redigér detaljer",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Gruppe",
+ "mapeditor-mapparam-defoption": "-Vælg parameter-",
+ "mapeditor-form-field-image": "Billede",
+ "semanticmaps-unrecognizeddistance": "Værdien $1 er ikke en gyldig afstand.",
+ "semanticmaps-kml-link": "Vis KML-filen",
+ "semanticmaps-default-kml-pagelink": "Se siden $1",
+ "semanticmaps-latitude": "Breddegrad: $1",
+ "semanticmaps-longitude": "Længdegrad: $1",
+ "semanticmaps-altitude": "Højde: $1",
+ "semanticmaps-forminput-locations": "Steder",
+ "semanticmaps-kml-title": "Standardtitlen for resultater",
+ "validator-type-mapscircle-list": "Liste over cirkler",
+ "validator-type-mapsline": "Geografisk linje",
+ "validator-type-mapsline-list": "Liste over linjer",
+ "validator-type-mapslocation-list": "Liste over placeringer",
+ "validator-type-jsonfile": "tekst"
+}
diff --git a/www/wiki/extensions/Maps/i18n/de.json b/www/wiki/extensions/Maps/i18n/de.json
new file mode 100644
index 00000000..71905a10
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/de.json
@@ -0,0 +1,231 @@
+{
+ "@metadata": {
+ "authors": [
+ "Als-Holder",
+ "DaSch",
+ "Imre",
+ "Kghbln",
+ "Metalhead64",
+ "Purodha",
+ "The Evil IP address",
+ "Umherirrender"
+ ]
+ },
+ "maps-desc": "Ermöglicht das Einbinden dynamischer Karten, die Georeferenzierung von Adressen und andere geographische Operationen",
+ "right-geocode": "Georeferenzieren",
+ "action-geocode": "Georeferenzierungen auf diesem Wiki auszuführen",
+ "maps_map": "Karte",
+ "maps-tracking-category": "Seiten mit einer von der Maps-Erweiterung gerenderten Karte",
+ "maps-loading-map": "Die Karte wird geladen …",
+ "maps-load-failed": "Die Karte konnte nicht geladen werden.",
+ "maps-markers": "Markierungen",
+ "maps-copycoords-prompt": "STRG+C, ENTER",
+ "maps-searchmarkers-text": "Markierungen filtern",
+ "maps-others": "andere",
+ "maps-kml-parsing-failed": "Das Parsen einer oder mehrerer KML-Dateien ist fehlgeschlagen. Dies geschieht normalerweise aufgrund eines Abfragefehlers oder aufgrund von fehlerhaftem XML.",
+ "maps-ns-layer": "Ebene",
+ "maps-ns-layer-talk": "Ebene Diskussion",
+ "maps-layer-property": "Attribut",
+ "maps-layer-value": "Wert",
+ "maps-layer-errors": "Fehler",
+ "maps-layerdef-invalid": "Ungültige {{PLURAL:$1|Definition|Definitionen}}",
+ "maps-layerdef-invalid-fatal": "Die Definition ist ungültig und führt zu einem schwerwiegenden Fehler.",
+ "maps-layerdef-wrong-namespace": "Ebenendefinitionen sind nur auf Seiten des Namensraums „$1“ gültig",
+ "maps-layerdef-equal-layer-name": "Ebenennamen müssen auf der gleichen Ebenenseite einmalig sein. „$1“ wird bereits von einer anderen Ebene verwendet.",
+ "maps-layerpage-usage": "Seiten mit Karten, die die Ebene „$1“ verwenden",
+ "maps-layerpage-nousage": "Keine Seite verwendet momentan diese Ebene.",
+ "maps-error-invalid-layertype": "Es gibt keine Ebenen des Typs „$1“. Nur {{PLURAL:$3|dieser Typ wird|diese Typen werden}} unterstützt: $2",
+ "maps-error-no-layertype": "Der Ebenentyp muss angegeben werden. Nur {{PLURAL:$2|dieser Typ wird|diese Typen werden}} unterstützt: $1",
+ "validation-error-invalid-layer": "Der Parameter „$1“ muss einer gültigen Ebene entsprechen.",
+ "validation-error-invalid-layers": "Der Parameter „$1“ muss einer oder mehreren gültigen Ebenen entsprechen.",
+ "validation-error-no-non-numeric": "Der Parameter „$1“ muss eine nicht-numerische Zeichenfolge sein.",
+ "validation-error-no-non-numerics": "Der Parameter „$1“ muss eine oder mehrere nicht-numerische Zeichenfolgen sein.",
+ "maps-layer-of-type": "Ebene des Typs „$1“",
+ "maps-layer-of-type-and-name": "Ebene „$2“ des Typs „$1“",
+ "maps-layer-type-supported-by": "Dieser Ebenentyp kann {{PLURAL:$2|nur mit dem Kartografiedienst $1 genutzt werden|mit diesen Kartografiediensten genutzt werden: $1}}.",
+ "maps-coordinates-description": "Parserhook zur Koordinatenformatierung aus und in alle unterstützte Formate.",
+ "maps-displaymap-description": "Geographische Karten ohne jegliche im Wiki definierte Markierungen anzeigen.",
+ "maps-distance-description": "Konvertiere die Entfernung unter Verwendung einer der unterstützten Einheiten in ihr Äquivalent einer anderen unterstützen Einheit.",
+ "maps-finddestination-description": "Ein Ziel unter Angabe des Ausgangspunkts (kann in jedwedem unterstützten Format angegeben sein), der Peilung sowie der Entfernung ermitteln.",
+ "maps-geocode-description": "Aktiviert das Georeferenzieren von Adressen, also deren Umwandlung in Koordinaten. Mehrere Georeferenzierungsdienste werden unterstützt, was allerdings nicht mit den Kartografiediensten zu verwechseln ist.",
+ "maps-geodistance-description": "Berechne die Entfernung zwischen zwei Punkten von einer der unterstützten Einheiten in ihr Äquivalent einer anderen unterstützten Einheit.",
+ "maps-mapsdoc-description": "Zeigt eine Übersicht aller Parameter mitsamt deren Standardwerten einschließlich ihrer Beschreibung, die im Zusammenhang mit dem angegebenen Kartografiedienst genutzt werden können.",
+ "maps-layerdefinition-description": "Beschreibt eine benutzerdefinierte Ebene, die zusammen mit anderen Kartenfunktionen angezeigt werden kann.",
+ "maps-mapsdoc-par-service": "Der Kartografiedienst zu dessen Parametern die Dokumentation angezeigt werden soll.",
+ "maps-mapsdoc-par-language": "Die Sprache, in der die Dokumentation angezeigt werden soll. Sofern keine Übersetzung verfügbar ist, wird stattdessen Englisch verwendet werden.",
+ "maps-coordinates-par-location": "Die zu formatierenden Koordinaten.",
+ "maps-coordinates-par-format": "Das Zielformat der Koordinaten.",
+ "maps-coordinates-par-directional": "Gibt an, ob die Koordinaten eine Richtungsangabe haben sollen oder nicht.",
+ "maps-par-scrollwheelzoom": "Zeigt an, ob das Mausscrollen aktiviert werden soll oder nicht.",
+ "maps-distance-par-distance": "Die Entfernung zum konvertieren dieser Einheit in ihr Äquivalent einer angegebenen Einheit.",
+ "maps-distance-par-decimals": "Die bei der Ergebnisausgabe zu verwendende Höchstzahl an Nachkommastellen.",
+ "maps-distance-par-unit": "Die Ausgabeeinheit für die Entfernung.",
+ "maps-finddestination-par-location": "Der Ausgangspunkt.",
+ "maps-finddestination-par-bearing": "Die Ausgangspeilung.",
+ "maps-finddestination-par-distance": "Die Reiseentfernung.",
+ "maps-finddestination-par-format": "Das Ausgabeformat für das Ziel.",
+ "maps-finddestination-par-directional": "Gibt an, ob das Ausgabeformat des Ziels eine Richtungsangabe haben soll oder nicht.",
+ "maps-geocode-par-location": "Die Adresse, die geokodiert werden soll.",
+ "maps-geocode-par-format": "Das Ausgabeformat für die Koordinaten.",
+ "maps-geocode-par-directional": "Gibt an, ob die Koordinaten eine Richtungsangabe haben sollen oder nicht.",
+ "maps-geodistance-par-location1": "Der erste von zwei Punkten zwischen denen die Entfernung berechnet werden soll.",
+ "maps-geodistance-par-location2": "Der zweite von zwei Punkten zwischen denen die Entfernung berechnet werden soll.",
+ "maps-geodistance-par-unit": "Die Ausgabeeinheit für die Entfernung.",
+ "maps-geodistance-par-decimals": "Die bei der Ergebnisausgabe zu verwendende Höchstzahl an Nachkommastellen.",
+ "maps-displaymap-par-mappingservice": "Der Kartografiedienst, der zur Generierung der Karte genutzt werden soll",
+ "maps-displaymap-par-coordinates": "Die Postion auf welche die Karte zunächst zentriert werden soll",
+ "maps-displaymap-par-visitedicon": "Der Dateiname des Symbols, das anstelle der ursprünglichen Markierung angezeigt werden soll, sobald die Originalmarkierungen angeklickt wurden",
+ "maps-displaymap-par-zoom": "Der Anzeigestufe (Zoom) der Karte.\nSofern keine angegeben wurde und mehrerer Markierungen auf der Karte vorhanden sind, wird die für deren gemeinsame Darstellung passende Anzeigestufe verwendet und nicht der Standardwert des Kartografiediensts.",
+ "maps-displaymap-par-centre": "Die Koordinaten, die zur Zentrierung der Karte verwendet werden sollen.\nSowohl die direkte Angabe von Koordinaten wie auch die indirekte Angabe einer Adresse ist möglich.\nSofern nichts angegeben wurde, wird sich die Karte um die darzustellende Markierung, bzw. zwischen den darzustellenden Markierungen zentrieren.",
+ "maps-displaymap-par-title": "Der Text, der in den Pop-up-Fenstern zu den Markierungen angezeigt werden soll, die über keinen eigenständigen Titel verfügen. Sofern dieser zusammen mit einer Beschriftung genutzt wird, wird der Titel in Fettschrift und unterstrichen angezeigt.",
+ "maps-displaymap-par-label": "Der Text, der in den Pop-up-Fenstern der Markierungen angezeigt werden soll, die über keine eigenständige Beschriftung verfügen",
+ "maps-displaymap-par-icon": "Das Symbol, das für alle Markierungen genutzt werden soll",
+ "maps-displaymap-par-circles": "Anzuzeigende Kreise",
+ "maps-displaymap-par-copycoords": "Zeigt einen Dialog beim Anklicken eines Standortes an, von dem seine Koordinaten kopiert werden können.",
+ "maps-displaymap-par-lines": "Anzuzeigende Linien",
+ "maps-displaymap-par-maxzoom": "Die maximale Anzeigestufe",
+ "maps-displaymap-par-minzoom": "Die minimale Anzeigestufe",
+ "maps-displaymap-par-polygons": "Anzuzeigende Vielecke",
+ "maps-displaymap-par-rectangles": "Anzuzeigende Rechtecke",
+ "maps-displaymap-par-static": "Die Karte statisch machen",
+ "maps-displaymap-par-wmsoverlay": "Eine Web-Map-Service-Ebene verwenden",
+ "maps-displaymap-par-geojson": "URL einer Datei oder Name der Seite, die GeoJSON-Daten enthält",
+ "maps-fullscreen-button": "Auf Vollbild umschalten",
+ "maps-fullscreen-button-tooltip": "Die Karte als Vollbild oder eingebettet darstellen.",
+ "validation-error-invalid-location": "Parameter $1 muss einem gültigen Standort entsprechen.",
+ "validation-error-invalid-locations": "Parameter $1 muss einem oder mehreren gültigen Standorten entsprechen.",
+ "validation-error-invalid-width": "Parameter $1 muss einer gültigen Breite entsprechen.",
+ "validation-error-invalid-height": "Parameter $1 muss einer gültigen Höhe entsprechen.",
+ "validation-error-invalid-distance": "Parameter $1 muss einer gültigen Entfernung entsprechen.",
+ "validation-error-invalid-distances": "Parameter $1 muss einer oder mehreren gültigen Entfernungen entsprechen.",
+ "validation-error-invalid-image": "Parameter $1 muss einem gültigen Bild entsprechen.",
+ "validation-error-invalid-images": "Parameter $1 muss einem oder mehreren gültigen Bildern entsprechen.",
+ "validation-error-invalid-goverlay": "Parameter $1 muss einer gültigen Überlagerung entsprechen.",
+ "validation-error-invalid-goverlays": "Parameter $1 muss einer oder mehreren gültigen Überlagerungen entsprechen.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Breitengrad:",
+ "maps-longitude": "Längengrad:",
+ "maps-invalid-coordinates": "Der Wert $1 bezeichnet kein gültiges Koordinatenpaar.",
+ "maps_coordinates_missing": "Es wurden keine Koordinaten für die Karte angegeben.",
+ "maps_geocoding_failed": "Die {{PLURAL:$2|folgende Adresse|folgenden Adressen}} konnten nicht geokodiert werden: $1.",
+ "maps_geocoding_failed_for": "Die {{PLURAL:$2|folgende Adresse konnte|folgenden Adressen konnten}} nicht georeferenziert werden und {{PLURAL:$2|wurde|wurden}} auf der Karte nicht berücksichtigt:\n$1",
+ "maps_unrecognized_coords": "Die {{PLURAL:$2|folgende Koordinate wurde|folgenden Koordinaten wurden}} nicht erkannt: $1.",
+ "maps_unrecognized_coords_for": "Die {{PLURAL:$2|folgende Koordinate wurde|folgenden Koordinaten wurden}} nicht erkannt und {{PLURAL:$2|wurde|wurden}} auf der Karte nicht berücksichtigt:\n$1",
+ "maps_map_cannot_be_displayed": "Diese Karte kann nicht angezeigt werden.",
+ "maps-geocoder-not-available": "Die Funktion zum Georeferenzierung von Karten ist nicht verfügbar. Der Standort kann nicht georeferenziert werden.",
+ "maps_googlemaps3": "Karte (Google Maps v3)",
+ "maps_leaflet": "Karte (Leaflet)",
+ "maps-leaflet-par-defzoom": "Erlaubt das Festlegen der Standardvergrößerungsstufe der Karte",
+ "maps-leaflet-par-layers": "Die Ebene, die angezeigt wird, wenn die Karte lädt.",
+ "maps-leaflet-par-overlaylayers": "Die Überlagerungsebenen, die angezeigt werden, wenn die Karte lädt.",
+ "maps-leaflet-par-maxclusterradius": "Der maximale Radius, den ein Cluster ab der Mittelmarkierung abdeckt (in Pixeln).",
+ "maps-leaflet-par-clusterspiderfy": "Bei Klicken auf einen Cluster in einer niedrigen Vergrößerungsstufe wird dieser netzförmig expandiert, so dass alle enthaltenen Markierungen eingesehen werden können.",
+ "maps_click_to_activate": "Klicken, um die Karte zu aktivieren.",
+ "maps_centred_on": "Karte ist auf $1, $2 zentriert.",
+ "maps-par-mappingservice": "Ermöglicht das Festlegen des Kartografiedienstes, der zum Erstellen der Karte verwendet werden soll",
+ "maps-par-resizable": "Die Karte durch Ziehen von der unteren rechten Ecke größenveränderbar machen können",
+ "maps-par-searchmarkers": "Erlaubt die Suche nach speziellen Markierungen über ein in die Karte eingebettetes Feld",
+ "maps-par-zoom": "Die Zoomstufe für die Karte. Karten mit Kennzeichnungen werden standardmäßig auf die Stufe gezoomt in der diese noch alle gemeinsam angezeigt werden können.",
+ "maps-par-width": "Die Kartenbreite, die genutzt werden soll. Standardmäßig wird Pixel (px) als Einheit angenommen. Jedoch kann auch eine der folgenden Einheiten angegeben werden: ex, em und %",
+ "maps-par-height": "Die Kartenhöhe, die genutzt werden soll. Standardmäßig wird Pixel (px) als Einheit angenommen. Jedoch kann auch eine der folgenden Einheiten angegeben werden: ex, em und %",
+ "maps-par-centre": "Die Koordinaten des Standorts (bpsw. <code>50.0093,8.2564</code>), an dem die Karte zentriert werden soll",
+ "maps-par-enable-fullscreen": "Vollbildschaltfläche aktivieren",
+ "maps-par-kml": "Die auf die Karte zu ladenden KML-Dateien.",
+ "maps-par-markercluster": "Erlaubt das Zusammenführen mehrerer benachbarter Markierungen zu einer Markierung",
+ "maps-googlemaps3-incompatbrowser": "Der Browser ist nicht mit Google Maps v3 kompatibel.",
+ "maps-googlemaps3-par-imageoverlays": "Erlaubt das Hinzufügen eines Bildes, das am angegebenen Ort auf der Karte angezeigt wird",
+ "maps-googlemaps3-par-type": "Die zunächst anzuzeigende Kartenart.",
+ "maps-googlemaps3-par-types": "Die Kartenarten, die über die Steuerung zu den Kartenarten verfügbar gemacht werden sollen.",
+ "maps-googlemaps3-par-layers": "Die auf die Karte zu ladenden Sonderebenen.",
+ "maps-googlemaps3-par-controls": "Die auf der Karte anzuzeigenden Steuerelemente.",
+ "maps-googlemaps3-par-zoomstyle": "Der Stil der Zoomsteuerung.",
+ "maps-googlemaps3-par-typestyle": "Der Stil der Steuerung zu den Kartenarten.",
+ "maps-googlemaps3-par-autoinfowindows": "Die Informationsfenster nach dem Laden der Seite automatisch öffnen oder nicht",
+ "maps-googlemaps3-par-gkml": "Die von Google gehosteten KML-Dateien, die auf die Karte geladen werden sollen",
+ "maps-googlemaps3-par-kmlrezoom": "Die Karte erneut zoomen, nachdem die KML-Ebenen geladen wurden.",
+ "maps-googlemaps3-par-poi": "Die Sehenswürdigkeiten anzeigen",
+ "maps-googlemaps3-par-clustergridsize": "Die Rastergröße eines Clusters in Pixeln",
+ "maps-par-clustermaxzoom": "Die maximale Vergrößerungsstufe, in der Cluster vorhanden sein können.",
+ "maps-par-clusterzoomonclick": "Ob das Standardverhalten beim Klicken auf einen Cluster dessen Vergrößerung ist.",
+ "maps-par-maxclusterradius": "Der maximale Radius, den ein Cluster abdeckt.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Ob die Mitte jedes Clusters der Durchschnitt aller Markierungen des Clusters sein soll",
+ "maps-googlemaps3-par-clusterminsize": "Die Mindestzahl der Markierungen, die ein Cluster enthalten soll, bevor die Markierungen versteckt werden und ein Zähler angezeigt wird",
+ "mapeditor": "Karteneditor",
+ "specialpages-group-maps": "Karten",
+ "mapeditor-parser-error": "Ein Fehler ist beim Parsen der Metadaten aufgetreten. Ignoriere Benutzereingaben.",
+ "mapeditor-none-text": "Keine",
+ "mapeditor-done-button": "Fertig",
+ "mapeditor-remove-button": "Entfernen",
+ "mapeditor-import-button2": "Importieren",
+ "mapeditor-export-button": "In Wikicode exportieren",
+ "mapeditor-import-button": "Aus Wikicode importieren",
+ "mapeditor-select-button": "Dieses Vieleck auswählen",
+ "mapeditor-mapparam-button": "Kartenparameter bearbeiten",
+ "mapeditor-clear-button": "Karte leeren",
+ "mapeditor-code-title": "Wikicode",
+ "mapeditor-import-title": "Wikicode importieren",
+ "mapeditor-import-note": "Hinweis: Der Parser erwartet ein sehr strenges Format für den Wikicode. Der hier eingegebene Code sollte mit dem ausgegebenen Code der Exportfunktion übereinstimmen.",
+ "mapeditor-form-title": "Einzelheiten bearbeiten",
+ "mapeditor-link-title-switcher-popup-text": "Pop-up mit Text",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Symbol",
+ "mapeditor-form-field-group": "Gruppe",
+ "mapeditor-form-field-inlinelabel": "Eingebettete Bezeichnung",
+ "mapeditor-form-field-strokecolor": "Farbe der Schrift",
+ "mapeditor-form-field-strokeopacity": "Deckkraft der Schrift",
+ "mapeditor-form-field-strokeweight": "Stärke der Schrift",
+ "mapeditor-form-field-fillcolor": "Farbe der Füllung",
+ "mapeditor-form-field-fillopcaity": "Deckkraft der Füllung",
+ "mapeditor-form-field-showonhover": "Nur beim Darüberfahren anzeigen",
+ "mapeditor-mapparam-title": "Kartenparameter bearbeiten",
+ "mapeditor-mapparam-defoption": "-Parameter auswählen-",
+ "mapeditor-imageoverlay-button": "Bildeinblendung hinzufügen",
+ "mapeditor-form-field-image": "Bild",
+ "mapeditor-imageoverlay-title": "Einzelheiten zur Bildeinblendung",
+ "mapeditor-form-field-visitedicon": "Symbol sofern besucht",
+ "semanticmaps-unrecognizeddistance": "Der Wert $1 ist keine gültige Distanz.",
+ "semanticmaps-kml-link": "KML-Datei ansehen",
+ "semanticmaps-kml": "Export (KML)",
+ "semanticmaps-default-kml-pagelink": "Artikel $1 ansehen",
+ "semanticmaps-latitude": "Breitengrad: $1",
+ "semanticmaps-longitude": "Längengrad: $1",
+ "semanticmaps-altitude": "Höhe: $1",
+ "semanticmaps-forminput-locations": "Standort",
+ "semanticmaps-par-staticlocations": "Die Listen von Standorten, die zusammen mit den abgefragten Daten, der Karte hinzugefügt werden sollen. Analog zu den Anzeigepunkten können je Standort Titel, Beschreibung und Symbol, unter Verwendung einer Tilde „~“ als Trennzeichen, hinzugefügt werden.",
+ "semanticmaps-par-showtitle": "Den Titel im Informationsfenster der Kennzeichnung anzeigen oder nicht. Diese Option zu deaktivieren ist oftmals dann nützlich, sofern eine Vorlage zur Formatierung des Informationsfensterinhalts verwendet wird.",
+ "semanticmaps-par-hidenamespace": "Den Namen des Namensraums im Informationsfenster der Kennzeichnung anzeigen",
+ "semanticmaps-par-centre": "Das Zentrum der Karte. Sofern nicht angegeben wird automatisch das optimale Zentrum zur Darstellung aller Kennzeichnungen auf der Karte gewählt.",
+ "semanticmaps-par-template": "Die zur Formatierung des Informationsfensterinhalts zu verwendende Vorlage.",
+ "semanticmaps-par-geocodecontrol": "Die Steuerungsseite zum Geokodieren anzeigen.",
+ "semanticmaps-par-activeicon": "Das Symbol, das anstelle der Standardmarkierung angezeigt wird, sofern die aktive Seite dem Abfrageergebnis entspricht.",
+ "semanticmaps-par-pagelabel": "Sofern mit „yes“ (ja) festgelegt, verfügen alle Markierungen über eine eingebettete Anzeige mit einem Link zur entsprechenden Seite sowie den entsprechenden Koordinaten.",
+ "semanticmaps-par-ajaxcoordproperty": "Name des Koordinatenattributs, das zur Erstellung der Ajax-Abfrage verwendet wird.",
+ "semanticmaps-par-ajaxquery": "Eine zweite Abfrage, die über Ajax gesendet wird, um zusätzliche Koordinaten abzurufen.",
+ "semanticmaps-par-userparam": "Ein in jedem Vorlagenaufruf zu übergebender Wert, falls eine Vorlage verwendet wird.",
+ "semanticmaps-kml-text": "Der Text, der zu jeder Seite angezeigt wird. Wird im Fall zusätzlich abgefragter Attribute ersetzt.",
+ "semanticmaps-kml-title": "Der Standardtitel für die Ergebnisse",
+ "semanticmaps-kml-linkabsolute": "Die Links sollen absolut sein (anstatt relativ)",
+ "semanticmaps-kml-pagelinktext": "Der Text, der für die Links zur Seite genutzt werden soll. $1 wird dabei durch den Namen der Seite ersetzt.",
+ "semanticmaps-shapes-improperformat": "$1 ist falsch formatiert. Siehe hierzu die Dokumentation bezüglich Formatierungen.",
+ "semanticmaps-shapes-missingshape": "Für $1 wurden keine Formen gefunden. Siehe hierzu die Dokumentation bezüglich verfügbarer Formen.",
+ "validator-type-mapscircle": "Geografischer Kreis",
+ "validator-type-mapscircle-list": "Liste der Kreise",
+ "validator-type-mapsimageoverlay": "Bildüberlagerung",
+ "validator-type-mapsimageoverlay-list": "Liste der Bildüberlagerungen",
+ "validator-type-mapsline": "Geografische Linie",
+ "validator-type-mapsline-list": "Liste der Linien",
+ "validator-type-mapslocation": "Geografischer Standort",
+ "validator-type-mapslocation-list": "Liste der Standorte",
+ "validator-type-mapsrectangle": "Geografisches Rechteck",
+ "validator-type-mapsrectangle-list": "Liste der Rechtecke",
+ "validator-type-mapspolygon": "Geografisches Vieleck",
+ "validator-type-mapspolygon-list": "Liste geografischer Vielecke",
+ "validator-type-wmsoverlay": "Web-Map-Service-Überlagerung",
+ "validator-type-jsonfile": "text"
+}
diff --git a/www/wiki/extensions/Maps/i18n/diq.json b/www/wiki/extensions/Maps/i18n/diq.json
new file mode 100644
index 00000000..67c297e8
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/diq.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Erdemaslancan",
+ "Gorizon",
+ "Mirzali"
+ ]
+ },
+ "maps_map": "Xerita",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-layer-value": "Erc",
+ "maps-abb-north": "Z",
+ "maps-abb-east": "A",
+ "maps-abb-south": "V",
+ "maps-abb-west": "P",
+ "maps-latitude": "Verıniye:",
+ "maps-longitude": "Derganiye:",
+ "maps_coordinates_missing": "Qan dê xerita koordinat nêdebya.",
+ "maps_googlemaps3": "Google Maps v3",
+ "maps_openlayers": "OpenLayers",
+ "mapeditor": "Vurnerê Xerita",
+ "specialpages-group-maps": "Xeritey",
+ "mapeditor-none-text": "Çıniyo",
+ "mapeditor-done-button": "Qeyd ke",
+ "mapeditor-remove-button": "Hewad",
+ "mapeditor-import-button2": "Zerre ke",
+ "mapeditor-code-title": "Wiki kode",
+ "mapeditor-form-title": "Detaya timar ke",
+ "mapeditor-link-title-switcher-link-text": "Gıre",
+ "mapeditor-form-field-title": "Sername",
+ "mapeditor-form-field-text": "Metın",
+ "mapeditor-form-field-link": "Gıre",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Grube",
+ "mapeditor-form-field-image": "Resım"
+}
diff --git a/www/wiki/extensions/Maps/i18n/dsb.json b/www/wiki/extensions/Maps/i18n/dsb.json
new file mode 100644
index 00000000..c68f71e2
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/dsb.json
@@ -0,0 +1,77 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Zmóžnijo zasajźowanje dynamiskich kórtow do wikibokow, geokoděrowanje adresow a druge geografiske akcije",
+ "maps_map": "Karta",
+ "maps-loading-map": "Kórta se zacytujo...",
+ "maps-markers": "Marki",
+ "maps-others": "druge",
+ "maps-ns-layer": "Rownina",
+ "maps-ns-layer-talk": "Diskusija rowniny",
+ "maps-layer-property": "Kakosć",
+ "maps-layer-value": "Gódnota",
+ "maps-layer-errors": "Zmólki",
+ "maps-error-invalid-layertype": "Njejsu žedne rowniny typa \"$1\". Jano {{PLURAL:$3|toś ten typ se pódpěra|toś tej typa se pódpěratej|toś te typy se pódpěraju|toś te typy se pódpěraju}}: $2",
+ "maps-error-no-layertype": "Musyš typ rowniny pódaś. Jano {{PLURAL:$2|toś ten typ se pódpěra|toś tej typa se pódpěratej|toś te typy se pódpěraju|toś te typy se pódpěraju}}: $1",
+ "validation-error-invalid-layer": "Parameter $1 musy płaśiwa rownina byś.",
+ "validation-error-invalid-layers": "Parameter $1 musy jadna płaśiwa rownina abo někotare płaśiwe rowniny byś.",
+ "maps-layer-of-type": "Rownina typa $1",
+ "maps-layer-type-supported-by": "Toś ten typ rowniny dajo se jano {{PLURAL:$2|z kartografiskeju słužbu $1 wužywaś|z toś tymi kartografiskimi słužbami wužywaś: $1}}.",
+ "maps-coordinates-par-location": "Koordinaty, kótarež coš formatěrowaś.",
+ "maps-coordinates-par-format": "Celowy format za koordinaty.",
+ "maps-finddestination-par-location": "Wuchadnišćo.",
+ "maps-finddestination-par-format": "Wudawański format za cel.",
+ "maps-geocode-par-location": "Adresa, kótaruž coš geokoděrowaś.",
+ "maps-geocode-par-format": "Wudawański format za koordinaty.",
+ "validation-error-invalid-location": "Parameter $1 musy płaśiwe městno byś.",
+ "validation-error-invalid-locations": "Parameter $1 musy jadne płaśiwe městno abo někotare płaśiwe městna byś.",
+ "validation-error-invalid-width": "Parameter $1 musy płaśiwa šyrokosć byś.",
+ "validation-error-invalid-height": "Parameter $1 musy płaśiwa wusokosć byś.",
+ "validation-error-invalid-distance": "Gódnota $1 musy płaśiwa distanca byś.",
+ "validation-error-invalid-distances": "Parameter $1 musy jadna płaśiwa distanca abo někotare płaśiwe distance byś.",
+ "validation-error-invalid-image": "Parameter $1 musy płaśiwy wobraz byś.",
+ "validation-error-invalid-images": "Parameter $1 musy jadne płaśiwy wobraz abo někotare płaśiwe wobraze byś.",
+ "validation-error-invalid-goverlay": "Parameter $1 musy płaśiwe pśewarstowanje byś.",
+ "validation-error-invalid-goverlays": "Parameter $1 musy jadne płaśiwe pśewarstowanje abo někotare płaśiwe pśewarstowanja byś.",
+ "maps-abb-north": "PP",
+ "maps-abb-east": "PZ",
+ "maps-abb-south": "PD",
+ "maps-abb-west": "PW",
+ "maps-latitude": "Šyrina:",
+ "maps-longitude": "Dlinina:",
+ "maps-invalid-coordinates": "Gódnota $1 njejo se spóznała ako płaśiwa sajźba koordinatow.",
+ "maps_coordinates_missing": "Za kórtu njejsu koordinaty pódane.",
+ "maps_geocoding_failed": "Geokoděrowanje {{PLURAL:$2|slědujuceje adrese|slědujuceju adresowu|slědujucych adresow|slědujucych adresow}} njejo móžno było: $1. Kórta njedajo se zwobrazniś.",
+ "maps_geocoding_failed_for": "Geokoděrowanje {{PLURAL:$2|slědujuceje adrese|slědujuceju adresowu|slědujucych adresow|slědujucych adresow}} njejo móžno było a togodla toś {{PLURAL:$2|ta adresa wuwóstaja|tej adresy wuwóstajotej|te adrese wuwóstajaju|te adresy wuwóstajaju}} se na kórśe: $1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Slědujuca koordinata njejo se spóznała|Slědujucej koordinaśe njejstej se spóznałej|Slědujuce koordinaty njejsu se spóznali|Slědujuce koordinaty njejsu se spóznali}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Slědujuca koordinata njejo se spóznała|Slědujucej koordinaśe stej se spóznałej|Slědujuce koordinaty su se spóznali|Slědujuce koordinaty su se spóznali}} a {{PLURAL:$2|njejo se wuwóstajiła|njejstej se wuwóstajiłej|njejsu wuwóstajili|njejsu se wuwóstajili}} na kórśe: $1",
+ "maps_map_cannot_be_displayed": "Kórta njedajo se zwobrazniś.",
+ "maps-geocoder-not-available": "Funkcija geokoděrowanja Kórtow njestoj k dispoziciji, twójo městno njedajo se geokoděrowaś.",
+ "maps_click_to_activate": "Klikni, aby kórtu aktiwěrował",
+ "maps_centred_on": "Kórta na $1, $2 centrěrowana.",
+ "semanticmaps-unrecognizeddistance": "Gódnota $1 njejo płaśiwa distanca.",
+ "semanticmaps-kml-link": "KML-dataju se woglědaś",
+ "semanticmaps-default-kml-pagelink": "Bok $1 se woglědaś",
+ "semanticmaps-latitude": "Šyrina: $1",
+ "semanticmaps-longitude": "Dlinina: $1",
+ "semanticmaps-altitude": "Wusokosć: $1",
+ "semanticmaps-forminput-locations": "Městna",
+ "semanticmaps-par-staticlocations": "Lisćina městnow, kótarež maju se zgromadnje z napšašowanymi datami kórśe pśidaś. Ako pla zwobraznjeńskich dypkow móžoš titel, wopisanje a symbol na městno z pomocu tildy \"~\" ako źěleńske znamuško pśidaś.",
+ "semanticmaps-par-showtitle": "Titel w informaciskem woknje marki pokazaś abo nic. Jo cesto wužytne, toś to nastajenje znjemóžniś, gaž pśedłoga se wužywa, aby se wopśimjeśe informaciskego wokna formatěrowało.",
+ "semanticmaps-par-hidenamespace": "Titel mjenjowego ruma w informaciskem woknje marki pokazaś",
+ "semanticmaps-par-centre": "Srjejźišćo kórty. Jolic njejo pódane, buźo kórta awtomatiski optimane srjejźišć wubraś, aby wšykne marki na kórśe zwobrazniła.",
+ "semanticmaps-par-template": "Pśedłoga, kótaraž ma se za formatěrowanje wopśimjeśa infowokna wužywaś,",
+ "semanticmaps-par-geocodecontrol": "Geokoděrowańske wóźenje pokazaś",
+ "semanticmaps-par-activeicon": "Symbol, kótaryž ma se město standardneje marki zwobrazniś, gaž aktiwny bok wótpowědujo napšašowańskemu wuslědkoju.",
+ "semanticmaps-par-pagelabel": "Jolic na \"jo\" stajone, změju wšykne marki \"inlineLabel\" z wótkazom k bokoju, kótaryž wopśimujo koordinaty marki.",
+ "semanticmaps-kml-text": "Tekst, kótaryž jo z kuždym bokom zwězany. Wuměnja se pśez pśidatne napšašowane kakosći, jolic su take.",
+ "semanticmaps-kml-title": "Standardny titel za wuslědki",
+ "semanticmaps-kml-linkabsolute": "Wótkaze by měli absolutne byś (nic relatiwne)",
+ "semanticmaps-kml-pagelinktext": "Tekst, kótaryž ma se za wótkaze k tomu bokoju wužywaś, w kótaremž $1 wuměnja se pśez titel boka",
+ "semanticmaps-shapes-improperformat": "$1 jo se wopak formatěrował. Pšosym glej dokumentaciju za formatěrowanje",
+ "semanticmaps-shapes-missingshape": "Formy za $1 njejsu se namakali. Pšosym glej dokumentaciju za k dispoziciji stojece formy."
+}
diff --git a/www/wiki/extensions/Maps/i18n/el.json b/www/wiki/extensions/Maps/i18n/el.json
new file mode 100644
index 00000000..755e14b0
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/el.json
@@ -0,0 +1,165 @@
+{
+ "@metadata": {
+ "authors": [
+ "Evropi",
+ "Glavkos",
+ "Omnipaedista",
+ "Protnet",
+ "ZaDiak",
+ "Macofe",
+ "Nikosgranturismogt"
+ ]
+ },
+ "maps-desc": "Επιτρέπει την ενσωμάτωση δυναμικών χαρτών σε σελίδες wiki, γεωκωδικοποίηση διευθύνσεων και άλλες γεωγραφικές λειτουργίες",
+ "right-geocode": "Γεωκωδικοποίηση",
+ "action-geocode": "κάνετε γεωκωδικοποίηση σε αυτό το wiki",
+ "maps_map": "Χάρτης",
+ "maps-loading-map": "Φόρτωση χάρτη...",
+ "maps-load-failed": "Δεν ήταν δυνατή η φόρτωση του χάρτη!",
+ "maps-markers": "Σημάδια",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Φιλτράρισμα σημαδιών",
+ "maps-others": "άλλοι",
+ "maps-ns-layer": "Στρώση",
+ "maps-ns-layer-talk": "Συζήτηση στρώσης",
+ "maps-layer-property": "Ιδιότητα",
+ "maps-layer-value": "Τιμή",
+ "maps-layer-errors": "Σφάλματα",
+ "maps-layerpage-nousage": "Δεν υπάρχουν σελίδες που να χρησιμοποιούν αυτή τη στρώση επί του παρόντος.",
+ "maps-error-invalid-layertype": "Δεν υπάρχουν στρώσεις τύπου «$1». {{PLURAL:$3|Ο μόνος τύπος που υποστηρίζεται είναι αυτός|Οι μόνοι τύποι που υποστηρίζονται είναι αυτοί}}: $2",
+ "maps-error-no-layertype": "Χρειάζεται να καθορίσετε τον τύπο της στρώσης. {{PLURAL:$2|Ο μόνος τύπος που υποστηρίζεται είναι αυτός|Οι μόνοι τύποι που υποστηρίζονται είναι αυτοί}}: $1",
+ "validation-error-invalid-layer": "Η παράμετρος $1 πρέπει να είναι ένα έγκυρο στρώμα.",
+ "validation-error-invalid-layers": "Η παράμετρος $1 πρέπει να είναι ένα ή περισσότερα έγκυρα στρώματα.",
+ "validation-error-no-non-numeric": "Η παράμετρος «$1» πρέπει να είναι μη αριθμητική συμβολοσειρά.",
+ "validation-error-no-non-numerics": "Η παράμετρος «$1» πρέπει να είναι μία ή περισσότερες μη αριθμητικές συμβολοσειρές.",
+ "maps-layer-of-type": "Στρώση τύπου «$1»",
+ "maps-layer-of-type-and-name": "Στρώση «$2» τύπου «$1»",
+ "maps-layer-type-supported-by": "Αυτός ο τύπος στρώσης μπορεί να χρησιμοποιηθεί {{PLURAL:$2|μόνο με την υπηρεσία|με αυτές τις υπηρεσίες}} χαρτογράφησης: $1.",
+ "maps-displaymap-description": "Προβολή γεωγραφικών χαρτών χωρίς σημάδια ορισμένα μέσω wiki.",
+ "maps-coordinates-par-location": "Οι συντεταγμένες που θέλετε να μορφοποιήσετε.",
+ "maps-coordinates-par-format": "Η μορφή προορισμού για τις συντεταγμένες.",
+ "maps-coordinates-par-directional": "Δηλώνει εάν οι συντεταγμένες πρέπει να εκφραστούν κατευθυντικά ή όχι.",
+ "maps-distance-par-unit": "Μονάδα μέτρησης με την οποία να εκφράζεται η απόσταση.",
+ "maps-finddestination-par-location": "Η αρχική τοποθεσία.",
+ "maps-finddestination-par-distance": "Η απόσταση που θα διανυθεί.",
+ "maps-finddestination-par-format": "Μορφή με την οποία να εκφραστεί ο προορισμός.",
+ "maps-finddestination-par-directional": "Δηλώνει εάν η μορφή του προορισμού πρέπει να είναι κατευθυντική ή όχι.",
+ "maps-geocode-par-location": "Η διεύθυνση που θέλετε να γεωκωδικοποιήσετε.",
+ "maps-geocode-par-format": "Η μορφή για τις συντεταγμένες που προκύπτουν.",
+ "maps-geocode-par-directional": "Δηλώνει εάν οι συντεταγμένες πρέπει να εκφραστούν κατευθυντικά ή όχι.",
+ "maps-geodistance-par-location1": "Το πρώτο σημείο στο σύνολο για τον υπολογισμό της απόστασης μεταξύ τους.",
+ "maps-geodistance-par-location2": "Το δεύτερο σημείο στο σύνολο για τον υπολογισμό της απόστασης μεταξύ τους.",
+ "maps-geodistance-par-unit": "Η μονάδα μέτρησης με την οποία να εκφράζεται η απόσταση.",
+ "maps-geodistance-par-decimals": "Ο μέγιστος αριθμός δεκαδικών ψηφίων που να χρησιμοποιούνται στην τιμή που θα προκύπτει.",
+ "maps-displaymap-par-coordinates": "Μία ή περισσότερες τοποθεσίες προς εμφάνιση στο χάρτη. Θα υποδεικνύονται με σημάδι.",
+ "maps-displaymap-par-icon": "Επιτρέπει τον ορισμό του εικονιδίου που χρησιμοποιείται για όλα τα σημάδια.",
+ "maps-displaymap-par-circles": "Κύκλοι προς εμφάνιση",
+ "maps-displaymap-par-copycoords": "Εμφάνιση ενός παραθύρου διαλόγου όταν γίνεται κλικ σε μια τοποθεσία από την οποία οι συντεταγμένες της μπορούν να αντιγραφούν",
+ "maps-displaymap-par-lines": "Γραμμές προς εμφάνιση",
+ "maps-displaymap-par-maxzoom": "Το μέγιστο επίπεδο ζουμ",
+ "maps-displaymap-par-minzoom": "Το ελάχιστο επίπεδο ζουμ",
+ "maps-displaymap-par-polygons": "Πολύγωνα προς εμφάνιση",
+ "maps-displaymap-par-rectangles": "Ορθογώνια προς εμφάνιση",
+ "maps-displaymap-par-static": "Να γίνει ο χάρτης στατικός",
+ "maps-displaymap-par-wmsoverlay": "Χρήση μιας υπέρθεσης WMS",
+ "maps-fullscreen-button": "Εναλλαγή πλήρους οθόνης",
+ "maps-fullscreen-button-tooltip": "Προβολή του χάρτη σε πλήρη οθόνη ή ενσωματωμένου.",
+ "validation-error-invalid-location": "Η παράμετρος «$1» πρέπει να είναι μια έγκυρη τοποθεσία.",
+ "validation-error-invalid-locations": "Η παράμετρος «$1» πρέπει να είναι μία ή περισσότερες έγκυρες τοποθεσίες.",
+ "validation-error-invalid-width": "Η παράμετρος «$1» πρέπει να είναι ένα έγκυρο πλάτος.",
+ "validation-error-invalid-height": "Η παράμετρος «$1» πρέπει να είναι ένα έγκυρο ύψος.",
+ "validation-error-invalid-distance": "Η παράμετρος «$1» πρέπει να είναι μια έγκυρη απόσταση.",
+ "validation-error-invalid-distances": "Η παράμετρος «$1» πρέπει να είναι μία ή περισσότερες έγκυρες αποστάσεις.",
+ "validation-error-invalid-image": "Η παράμετρος «$1» πρέπει να είναι μια έγκυρη εικόνα.",
+ "validation-error-invalid-images": "Η παράμετρος «$1» πρέπει να είναι μία ή περισσότερες έγκυρες εικόνες.",
+ "validation-error-invalid-goverlay": "Η παράμετρος «$1» πρέπει να είναι μια έγκυρη υπέρθεση.",
+ "validation-error-invalid-goverlays": "Η παράμετρος «$1» πρέπει να είναι μία ή περισσότερες έγκυρες υπερθέσεις.",
+ "maps-abb-north": "Β",
+ "maps-abb-east": "Α",
+ "maps-abb-south": "Ν",
+ "maps-abb-west": "Δ",
+ "maps-latitude": "Γεωγραφικό πλάτος:",
+ "maps-longitude": "Γεωγραφικό μήκος:",
+ "maps-invalid-coordinates": "Η τιμή $1 δεν αναγνωρίστηκε ως έγκυρο σύνολο συντεταγμένων.",
+ "maps_coordinates_missing": "Δεν δόθηκαν συντεταγμένες για τον χάρτη.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Η ακόλουθη διεύθυνση δεν ήταν δυνατό να γεωκωδικοποιηθεί|Οι ακόλουθες διευθύνσεις δεν ήταν δυνατό να γεωκωδικοποιηθούν}}: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Η ακόλουθη διεύθυνση δεν ήταν δυνατό να γεωκωδικοποιηθεί|Οι ακόλουθες διευθύνσεις δεν ήταν δυνατό να γεωκωδικοποιηθούν}} και {{PLURAL:$2|έχει|έχουν}} παραληφθεί από το χάρτη:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Η ακόλουθη συντεταγμένη δεν αναγνωρίστηκε|Οι ακόλουθες συντεταγμένες δεν αναγνωρίστηκαν}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Η ακόλουθη συντεταγμένη δεν αναγνωρίστηκε|Οι ακόλουθες συντεταγμένες δεν αναγνωρίστηκαν}} και {{PLURAL:$2|έχει|έχουν}} παραληφθεί από το χάρτη:\n$1",
+ "maps_map_cannot_be_displayed": "Ο χάρτης δεν μπορεί να προβληθεί.",
+ "maps-geocoder-not-available": "Το χαρακτηριστικό γεωκωδικοποίησης των Χαρτών δεν είναι διαθέσιμο. Η τοποθεσία σας δεν μπορεί να γεωκωδικοποιηθεί.",
+ "maps_click_to_activate": "Κάντε κλικ για να ενεργοποιήσετε το χάρτη",
+ "maps_centred_on": "Ο χάρτης είναι κεντραρισμένος στο $1, $2.",
+ "maps-par-resizable": "Κάνει το χάρτη να μπορεί να αλλάξει μέγεθος σύροντας την κάτω δεξιά γωνία του.",
+ "maps-par-searchmarkers": "Επιτρέπει την αναζήτηση για συγκεκριμένα σημάδια μέσω πεδίου ενσωματωμένου στο χάρτη.",
+ "maps-par-centre": "Η τοποθεσία στην οποία ο χάρτης θα πρέπει να είναι κεντραρισμένος",
+ "maps-par-enable-fullscreen": "Ενεργοποίηση κουμπιού πλήρους οθόνης",
+ "maps-par-kml": "Αρχεία KML για φόρτωση στο χάρτη.",
+ "maps-par-markercluster": "Επιτρέπει τη συγχώνευση πολλαπλών κοντινών σημαδιών σε ένα σημάδι",
+ "maps-googlemaps3-incompatbrowser": "Το πρόγραμμα περιήγησης δεν είναι συμβατό με την έκδοση 3 των Χαρτών Google.",
+ "maps-googlemaps3-par-imageoverlays": "Επιτρέπει την προσθήκη μιας εικόνας προς εμφάνιση στην καθοριζόμενη θέση στο χάρτη.",
+ "maps-googlemaps3-par-type": "Τύπος χάρτη που να εμφανίζεται αρχικά.",
+ "maps-googlemaps3-par-types": "Τύποι χάρτη που θα είναι διαθέσιμοι μέσω της ρύθμισης τύπου.",
+ "maps-googlemaps3-par-layers": "Ειδικές στρώσεις για φόρτωση επάνω στο χάρτη.",
+ "maps-googlemaps3-par-controls": "Στοιχεία ελέγχου για τοποθέτηση στο χάρτη.",
+ "maps-googlemaps3-par-zoomstyle": "Στυλ του στοιχείου ελέγχου του ζουμ.",
+ "maps-googlemaps3-par-typestyle": "Στυλ του στοιχείου ελέγχου του τύπου.",
+ "maps-googlemaps3-par-autoinfowindows": "Αυτόματο άνοιγμα όλων των παραθύρων πληροφοριών μετά τη φόρτωση της σελίδας.",
+ "maps-googlemaps3-par-gkml": "Αρχεία KML που φιλοξενούνται στη Google για φόρτωση στο χάρτη.",
+ "maps-googlemaps3-par-poi": "Εμφάνιση σημείων ενδιαφέροντος.",
+ "mapeditor": "Πρόγραμμα επεξεργασίας χαρτών",
+ "specialpages-group-maps": "Χάρτες",
+ "mapeditor-none-text": "Κανένα",
+ "mapeditor-done-button": "Ολοκληρώθηκε",
+ "mapeditor-remove-button": "Αφαίρεση",
+ "mapeditor-import-button2": "Εισαγωγή",
+ "mapeditor-export-button": "Εξαγωγή κώδικα wiki",
+ "mapeditor-import-button": "Εισαγωγή από κώδικα wiki",
+ "mapeditor-select-button": "Επιλογή αυτού του πολυγώνου",
+ "mapeditor-mapparam-button": "Επεξεργασία παραμέτρων χάρτη",
+ "mapeditor-clear-button": "Εκκαθάριση χάρτη",
+ "mapeditor-code-title": "Κώδικας wiki",
+ "mapeditor-import-title": "Εισαγωγή κώδικα wiki",
+ "mapeditor-form-title": "Επεξεργασία λεπτομερειών",
+ "mapeditor-link-title-switcher-popup-text": "Αναδυόμενο με κείμενο",
+ "mapeditor-link-title-switcher-link-text": "Σύνδεσμος",
+ "mapeditor-form-field-title": "Τίτλος",
+ "mapeditor-form-field-text": "Κείμενο",
+ "mapeditor-form-field-link": "Σύνδεσμος",
+ "mapeditor-form-field-icon": "Εικονίδιο",
+ "mapeditor-form-field-group": "Ομάδα",
+ "mapeditor-form-field-inlinelabel": "Ενδοκειμενική ετικέτα",
+ "mapeditor-form-field-strokecolor": "Χρώμα περιγράμματος",
+ "mapeditor-form-field-strokeopacity": "Αδιαφάνεια περιγράμματος",
+ "mapeditor-form-field-strokeweight": "Πάχος περιγράμματος",
+ "mapeditor-form-field-fillcolor": "Χρώμα γεμίσματος",
+ "mapeditor-form-field-fillopcaity": "Αδιαφάνεια γεμίσματος",
+ "mapeditor-form-field-showonhover": "Εμφάνιση μόνο με την κατάδειξη",
+ "mapeditor-mapparam-title": "Επεξεργασία παραμέτρων χάρτη",
+ "mapeditor-mapparam-defoption": "-Επιλογή παραμέτρου-",
+ "mapeditor-imageoverlay-button": "Προσθήκη υπέρθεσης εικόνας",
+ "mapeditor-form-field-image": "Εικόνα",
+ "mapeditor-imageoverlay-title": "Λεπτομέρειες υπέρθεσης εικόνας",
+ "mapeditor-form-field-visitedicon": "Επισκεφθέν εικονίδιο",
+ "semanticmaps-unrecognizeddistance": "Η τιμή $1 δεν είναι έγκυρη απόσταση.",
+ "semanticmaps-kml-link": "Προβολή του αρχείου KML",
+ "semanticmaps-default-kml-pagelink": "Προβολή σελίδας $1",
+ "semanticmaps-latitude": "Γεωγραφικό πλάτος: $1",
+ "semanticmaps-longitude": "Γεωγραφικό μήκος: $1",
+ "semanticmaps-altitude": "Υψόμετρο: $1",
+ "semanticmaps-forminput-locations": "Τοποθεσίες",
+ "semanticmaps-par-staticlocations": "Μια λίστα με τοποθεσίες για προσθήκη στο χάρτη μαζί με τα ερωτηθέντα δεδομένα. Όπως και με τα display_points, μπορείτε να προσθέσετε τίτλο, περιγραφή και εικονίδιο ανά τοποθεσία χρησιμοποιώντας την περισπωμένη «~» ως διαχωριστικό.",
+ "semanticmaps-par-showtitle": "Εμφάνιση ή μη του τίτλου στο παράθυρο πληροφοριών δείκτη. Η απενεργοποίησή του είναι συχνά χρήσιμη όταν χρησιμοποιείται πρότυπο για τη μορφοποίηση του περιεχομένου του παραθύρου πληροφοριών.",
+ "semanticmaps-par-hidenamespace": "Εμφάνιση τίτλου ονοματοχώρου στο παράθυρο πληροφοριών δείκτη",
+ "semanticmaps-par-centre": "Το κέντρο του χάρτη. Όταν δεν παρέχεται, ο χάρτης θα επιλέξει αυτόματα το βέλτιστο κέντρο για την προβολή όλων των δεικτών επάνω στο χάρτη.",
+ "semanticmaps-par-template": "Πρότυπο για να το χρησιμοποιήσετε για τη μορφοποίηση των περιεχομένων του παραθύρου πληροφοριών.",
+ "semanticmaps-par-geocodecontrol": "Εμφάνιση στοιχείου ελέγχου γεωκωδικοποίησης.",
+ "semanticmaps-par-activeicon": "Εικονίδιο που θα εμφανίζεται αντί του προεπιλεγμένου δείκτη, όταν η ενεργή σελίδα ισούται με το αποτέλεσμα του ερωτήματος",
+ "semanticmaps-kml-text": "Το κείμενο που σχετίζεται με κάθε σελίδα. Παρακάμπτεται από τις πρόσθετες ερωτηθέντες ιδιότητες αν υπάρχουν.",
+ "semanticmaps-kml-title": "Προεπιλεγμένος τίτλος για αποτελέσματα",
+ "semanticmaps-kml-linkabsolute": "Να είναι οι σύνδεσμοι απόλυτοι (ως αντιπαράθεση με τους σχετικούς)",
+ "semanticmaps-kml-pagelinktext": "Το κείμενο που θα χρησιμοποιείται για τους συνδέσμους προς τη σελίδα, στο οποίο το $1 θα αντικαθίσταται από τον τίτλο της σελίδας",
+ "semanticmaps-shapes-improperformat": "Εσφαλμένη μορφοποίηση του $1, ανατρέξτε στην τεκμηρίωση περί μορφοποίησης",
+ "semanticmaps-shapes-missingshape": "Δεν βρέθηκαν σχήματα για το $1, ανατρέξτε στην τεκμηρίωση για διαθέσιμα σχήματα",
+ "validator-type-jsonfile": "κείμενο"
+}
diff --git a/www/wiki/extensions/Maps/i18n/en-gb.json b/www/wiki/extensions/Maps/i18n/en-gb.json
new file mode 100644
index 00000000..af4e4598
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/en-gb.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bruce89",
+ "Lloffiwr",
+ "Reedy",
+ "Shirayuki"
+ ]
+ },
+ "maps-displaymap-par-centre": "Allows setting the coordinates of the map's centre for display_point(s).\nAccepts both addresses and coordinates.\nWhen this property is not provided, the map will centre itself on the provided marker, or between the provided markers.",
+ "maps-invalid-coordinates": "The value $1 was not recognised as a valid set of coordinates.",
+ "maps_unrecognized_coords": "The following {{PLURAL:$2|coordinate was|coordinates were}} not recognised: $1.",
+ "maps_unrecognized_coords_for": "The following {{PLURAL:$2|coordinate was|coordinates were}} not recognised and {{PLURAL:$2|has|have}} been omitted from the map:\n$1",
+ "maps_centred_on": "Map centred on $1, $2.",
+ "maps-par-centre": "The location on which the map should be centred",
+ "mapeditor-form-field-strokecolor": "Stroke colour",
+ "mapeditor-form-field-fillcolor": "Fill colour",
+ "semanticmaps-par-centre": "The centre of the map. When not provided, the map will automatically pick the optimal centre to display all markers on the map."
+}
diff --git a/www/wiki/extensions/Maps/i18n/en.json b/www/wiki/extensions/Maps/i18n/en.json
new file mode 100644
index 00000000..c26f7bdb
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/en.json
@@ -0,0 +1,225 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jeroen De Dauw",
+ "Karsten Hoffmeyer (kghbln)"
+ ]
+ },
+ "maps-desc": "Enables embedding of dynamic maps into wiki pages, geocoding of addresses and other geographical operations",
+ "right-geocode": "Geocode",
+ "action-geocode": "do geocoding on this wiki",
+ "maps_map": "Map",
+ "maps-tracking-category": "Pages with a map rendered by the Maps extension",
+ "maps-loading-map": "Loading map...",
+ "maps-load-failed": "Could not load the map!",
+ "maps-markers": "Markers",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Filter markers",
+ "maps-others": "others",
+ "maps-kml-parsing-failed": "Failed parsing one or more KML files. Usually this happens because of retrieval failure or malformed XML.",
+ "maps-ns-layer": "Layer",
+ "maps-ns-layer-talk": "Layer talk",
+ "maps-layer-property": "Property",
+ "maps-layer-value": "Value",
+ "maps-layer-errors": "Errors",
+ "maps-layerdef-invalid": "Invalid {{PLURAL:$1|definition|definitions}}",
+ "maps-layerdef-invalid-fatal": "Fatal invalid definition",
+ "maps-layerdef-wrong-namespace": "Layer definitions are only valid on pages of namespace \"$1\"",
+ "maps-layerdef-equal-layer-name": "Layer names must be unique within the same layer page. \"$1\" is already being used by another layer.",
+ "maps-layerpage-usage": "Pages with maps using layer \"$1\"",
+ "maps-layerpage-nousage": "No pages are using this layer at the moment.",
+ "maps-error-invalid-layertype": "There are no layers of type \"$1\". Only {{PLURAL:$3|this type is|these types are}} supported: $2",
+ "maps-error-no-layertype": "You need to specify the layer type. {{PLURAL:$2|Only this type is|These types are}} supported: $1",
+ "validation-error-invalid-layer": "Parameter \"$1\" must be a valid layer.",
+ "validation-error-invalid-layers": "Parameter \"$1\" must be one or more valid layers.",
+ "validation-error-no-non-numeric": "Parameter \"$1\" must be a non-numeric string.",
+ "validation-error-no-non-numerics": "Parameter \"$1\" must be one or more non-numeric strings.",
+ "maps-layer-of-type": "Layer of type \"$1\"",
+ "maps-layer-of-type-and-name": "Layer \"$2\" of type \"$1\"",
+ "maps-layer-type-supported-by": "This layer type can {{PLURAL:$2|only be used with the $1 mapping service|be used with these mapping services: $1}}.",
+ "maps-coordinates-description": "Parser hook to format coordinates, from and to any of the supported formats.",
+ "maps-displaymap-description": "Display geographical maps without any wiki-defined markers on them.",
+ "maps-distance-description": "Convert a distance using a certain supported unit to its equivalent using another unit.",
+ "maps-finddestination-description": "Find a destination given a starting point (that can be in any of the supported formats), an initial bearing and a distance.",
+ "maps-geocode-description": "Enables the geocoding of addresses, in other words, turning human readable locations into sets of coordinates. There is support for several geocoding services, which should not be confused with mapping services.",
+ "maps-geodistance-description": "Calculate the geographical distance between two points, from and to any of the supported formats.",
+ "maps-mapsdoc-description": "Display a table with the parameters for a specified mapping service together with their default values and descriptions.",
+ "maps-layerdefinition-description": "Describes a custom layer which can be displayed with other Map functions.",
+ "maps-mapsdoc-par-service": "The mapping service to display parameter documentation for.",
+ "maps-mapsdoc-par-language": "The language in which to display the documentation. If no such translation is available, English will be used instead.",
+ "maps-coordinates-par-location": "The coordinates you want to format.",
+ "maps-coordinates-par-format": "The target format for the coordinates.",
+ "maps-coordinates-par-directional": "Indicates if the coordinates should be outputted directional or not.",
+ "maps-par-scrollwheelzoom": "Indicates if mouse scrolling should be enabled or not.",
+ "maps-distance-par-distance": "The distance to convert to its equivalent with a specified unit.",
+ "maps-distance-par-decimals": "The maximum number of fractional digits to use in the resulting value.",
+ "maps-distance-par-unit": "The unit to output the distance in.",
+ "maps-finddestination-par-location": "The initial location.",
+ "maps-finddestination-par-bearing": "The initial bearing.",
+ "maps-finddestination-par-distance": "The distance to travel.",
+ "maps-finddestination-par-format": "The format in which to output the destination.",
+ "maps-finddestination-par-directional": "Indicates if the format of the destination should be directional or not.",
+ "maps-geocode-par-location": "The address you want to geocode.",
+ "maps-geocode-par-format": "The format for the resulting coordinates.",
+ "maps-geocode-par-directional": "Indicates if the coordinates should be outputted directional or not.",
+ "maps-geodistance-par-location1": "The first point in the set to calculate the distance between.",
+ "maps-geodistance-par-location2": "The second point in the set to calculate the distance between.",
+ "maps-geodistance-par-unit": "The unit to output the distance in.",
+ "maps-geodistance-par-decimals": "The maximum number of fractional digits to use in the resulting value.",
+ "maps-displaymap-par-mappingservice": "Allows setting the mapping service that will be used to generate the map.",
+ "maps-displaymap-par-coordinates": "One or more locations to display on the map. They will be indicated with a marker.",
+ "maps-displaymap-par-visitedicon": "The filename of an image to be used for marker icons after the original markers have been clicked",
+ "maps-displaymap-par-zoom": "Allows setting the zoom level of the map.\nWhen not provided and multiple markers are present on the map, the best fitting zoom will be taken, not the configurable default.",
+ "maps-displaymap-par-centre": "Allows setting the coordinates of the map's center for display_point(s).\nAccepts both addresses and coordinates.\nWhen this property is not provided, the map will center itself on the provided marker, or between the provided markers.",
+ "maps-displaymap-par-title": "Allows setting text that will be displayed in the pop-ups of all markers that do not have a specific title.\nWhen used together with label, the title will be bold and underlined.",
+ "maps-displaymap-par-label": "Allows setting text that will be displayed in the pop-ups of all markers that do not have a specific label.",
+ "maps-displaymap-par-icon": "Allows setting the icon used for all markers.",
+ "maps-displaymap-par-circles": "Circles to display",
+ "maps-displaymap-par-copycoords": "Show a dialog when clicking on a location from which its coordinates may be copied",
+ "maps-displaymap-par-lines": "Lines to display",
+ "maps-displaymap-par-maxzoom": "The maximum zoom level",
+ "maps-displaymap-par-minzoom": "The minimum zoom level",
+ "maps-displaymap-par-polygons": "Polygons to display",
+ "maps-displaymap-par-rectangles": "Rectangles to display",
+ "maps-displaymap-par-static": "Make the map static",
+ "maps-displaymap-par-wmsoverlay": "Use a WMS overlay",
+ "maps-displaymap-par-geojson": "URL of a file or name of the page containing GeoJSON data",
+ "maps-fullscreen-button": "Toggle fullscreen",
+ "maps-fullscreen-button-tooltip": "View the map as fullscreen or embedded.",
+ "validation-error-invalid-location": "Parameter \"$1\" must be a valid location.",
+ "validation-error-invalid-locations": "Parameter \"$1\" must be one or more valid locations.",
+ "validation-error-invalid-width": "Parameter \"$1\" must be a valid width.",
+ "validation-error-invalid-height": "Parameter \"$1\" must be a valid height.",
+ "validation-error-invalid-distance": "Parameter \"$1\" must be a valid distance.",
+ "validation-error-invalid-distances": "Parameter \"$1\" must be one or more valid distances.",
+ "validation-error-invalid-image": "Parameter \"$1\" must be a valid image.",
+ "validation-error-invalid-images": "Parameter \"$1\" must be one or more valid images.",
+ "validation-error-invalid-goverlay": "Parameter \"$1\" must be a valid overlay.",
+ "validation-error-invalid-goverlays": "Parameter \"$1\" must be one or more valid overlays.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Latitude:",
+ "maps-longitude": "Longitude:",
+ "maps-invalid-coordinates": "The value $1 was not recognized as a valid set of coordinates.",
+ "maps_coordinates_missing": "No coordinates provided for the map.",
+ "maps_geocoding_failed": "The following {{PLURAL:$2|address|addresses}} could not be geocoded: $1.",
+ "maps_geocoding_failed_for": "The following {{PLURAL:$2|address|addresses}} could not be geocoded and {{PLURAL:$2|has|have}} been omitted from the map:\n$1",
+ "maps_unrecognized_coords": "The following {{PLURAL:$2|coordinate was|coordinates were}} not recognized: $1.",
+ "maps_unrecognized_coords_for": "The following {{PLURAL:$2|coordinate was|coordinates were}} not recognized and {{PLURAL:$2|has|have}} been omitted from the map:\n$1",
+ "maps_map_cannot_be_displayed": "The map cannot be displayed.",
+ "maps-geocoder-not-available": "The geocoding feature of Maps is not available. Your location cannot be geocoded.",
+ "maps_googlemaps3": "Google Maps v3",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "Allows setting the default zoom level of the map.",
+ "maps-leaflet-par-layers": "The layers that will be available in the layer selector. The first layer will be shown when the map loads.",
+ "maps-leaflet-par-overlaylayers": "The overlay layers that will be shown when the map loads.",
+ "maps-leaflet-par-maxclusterradius": "The maximum radius that a cluster will cover from the central marker (in pixels).",
+ "maps-leaflet-par-clusterspiderfy": "When you click a cluster at the bottom zoom level we spiderfy it so you can see all of its markers.",
+ "maps_click_to_activate": "Click to activate map",
+ "maps_centred_on": "Map centered on $1, $2.",
+ "maps-par-mappingservice": "Allows setting the mapping service that will be used to generate the map.",
+ "maps-par-resizable": "Makes the map resizable by dragging at its lower right corner.",
+ "maps-par-searchmarkers": "Allows to search for specific markers via a field embedded into the map.",
+ "maps-par-zoom": "The zoom level for the map. For maps with markers this will default to the most zoomed in level that still shows all markers.",
+ "maps-par-width": "Allows setting the width of the map. By default pixels will be assumed as unit, but you can explicitly specify one of these units: px, ex, em, %.",
+ "maps-par-height": "Allows setting the height of the map. By default pixels will be assumed as unit, but you can explicitly specify one of these units: px, ex, em, %.",
+ "maps-par-centre": "The location on which the map should be centered",
+ "maps-par-enable-fullscreen": "Enable fullscreen button",
+ "maps-par-kml": "KML files to load onto the map.",
+ "maps-par-markercluster": "Allows merging of multiple nearby markers into one marker",
+ "maps-googlemaps3-incompatbrowser": "Your browser is not compatible with Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Allows adding an image to be shown on the specified location on the map.",
+ "maps-googlemaps3-par-type": "The map type to initially show.",
+ "maps-googlemaps3-par-types": "The map types that will be available via the type control.",
+ "maps-googlemaps3-par-layers": "Special layers to load onto the map.",
+ "maps-googlemaps3-par-controls": "The controls to place on the map.",
+ "maps-googlemaps3-par-zoomstyle": "The style of the zoom control.",
+ "maps-googlemaps3-par-typestyle": "The style of the type control.",
+ "maps-googlemaps3-par-autoinfowindows": "Automatically open all info windows after the page has loaded.",
+ "maps-googlemaps3-par-gkml": "KML files hosted by Google to load onto the map.",
+ "maps-googlemaps3-par-kmlrezoom": "Rezoom the map after the KML layers have been loaded.",
+ "maps-googlemaps3-par-poi": "Show points of interest.",
+ "maps-googlemaps3-par-clustergridsize": "The grid size of a cluster in pixels.",
+ "maps-par-clustermaxzoom": "The maximum zoom level where clusters may exist.",
+ "maps-par-clusterzoomonclick": "Whether the default behaviour of clicking on a cluster is to zoom into it.",
+ "maps-par-maxclusterradius": "The maximum radius that a cluster will cover.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Whether the center of each cluster should be the average of all markers in the cluster.",
+ "maps-googlemaps3-par-clusterminsize": "The minimum number of markers to be in a cluster before the markers are hidden and a count is shown.",
+ "mapeditor": "Map editor",
+ "specialpages-group-maps": "Maps",
+ "mapeditor-parser-error": "An error occurred when parsing metadata. Ignoring user input.",
+ "mapeditor-none-text": "None",
+ "mapeditor-done-button": "Done",
+ "mapeditor-remove-button": "Remove",
+ "mapeditor-import-button2": "Import",
+ "mapeditor-export-button": "Export to wiki code",
+ "mapeditor-import-button": "Import from wiki code",
+ "mapeditor-select-button": "Select this polygon",
+ "mapeditor-mapparam-button": "Edit map parameters",
+ "mapeditor-clear-button": "Clear map",
+ "mapeditor-code-title": "Wiki code",
+ "mapeditor-import-title": "Import wiki code",
+ "mapeditor-import-note": "Please note that the parser expects a very strict format on the wiki code. The code inputted here should match code outputted by the export functionality.",
+ "mapeditor-form-title": "Edit details",
+ "mapeditor-link-title-switcher-popup-text": "Popup with text",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Title",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Icon",
+ "mapeditor-form-field-group": "Group",
+ "mapeditor-form-field-inlinelabel": "Inline label",
+ "mapeditor-form-field-strokecolor": "Stroke color",
+ "mapeditor-form-field-strokeopacity": "Stroke opacity",
+ "mapeditor-form-field-strokeweight": "Stroke weight",
+ "mapeditor-form-field-fillcolor": "Fill color",
+ "mapeditor-form-field-fillopcaity": "Fill opacity",
+ "mapeditor-form-field-showonhover": "Show only on hover",
+ "mapeditor-mapparam-title": "Edit map parameters",
+ "mapeditor-mapparam-defoption": "-Select parameter-",
+ "mapeditor-imageoverlay-button": "Add image overlay",
+ "mapeditor-form-field-image": "Image",
+ "mapeditor-imageoverlay-title": "Image overlay details",
+ "mapeditor-form-field-visitedicon": "Visited icon",
+ "semanticmaps-unrecognizeddistance": "The value $1 is not a valid distance.",
+ "semanticmaps-kml-link": "View the KML file",
+ "semanticmaps-kml": "KML",
+ "semanticmaps-default-kml-pagelink": "View page $1",
+ "semanticmaps-latitude": "Latitude: $1",
+ "semanticmaps-longitude": "Longitude: $1",
+ "semanticmaps-altitude": "Altitude: $1",
+ "semanticmaps-forminput-locations": "Locations",
+ "semanticmaps-par-staticlocations": "A list of locations to add to the map together with the queried data. Like with display_points, you can add a title, description and icon per location using the tilde \"~\" as separator.",
+ "semanticmaps-par-showtitle": "Show a title in the marker info window or not. Disabling this is often useful when using a template to format the info window content.",
+ "semanticmaps-par-hidenamespace": "Show the namespace title in the marker info window",
+ "semanticmaps-par-centre": "The center of the map. When not provided, the map will automatically pick the optimal center to display all markers on the map.",
+ "semanticmaps-par-template": "A template to use to format the info window contents.",
+ "semanticmaps-par-geocodecontrol": "Show the geocoding control.",
+ "semanticmaps-par-activeicon": "Icon to be displayed instead of default marker, when active page is equal to query result",
+ "semanticmaps-par-pagelabel": "When set to \"yes\", all markers will have an \"inlineLabel\" with a link to the page containing the coordinates for the marker",
+ "semanticmaps-par-ajaxcoordproperty": "Name of the coordinate property which is used to build the ajax query.",
+ "semanticmaps-par-ajaxquery": "A second query that is sent via ajax to fetch additional coordinates.",
+ "semanticmaps-par-userparam": "A value passed into each template call, if a template is used",
+ "semanticmaps-kml-text": "The text associated with each page. Overridden by the additional queried properties if any.",
+ "semanticmaps-kml-title": "The default title for results",
+ "semanticmaps-kml-linkabsolute": "Should links be absolute (as opposed to relative)",
+ "semanticmaps-kml-pagelinktext": "The text to use for the links to the page, in which $1 will be replaced by the page title",
+ "semanticmaps-shapes-improperformat": "Improper formatting of $1. Please see documentation for formatting",
+ "semanticmaps-shapes-missingshape": "No shapes found for $1. Please see documentation for available shapes",
+ "validator-type-mapscircle": "Geographical circle",
+ "validator-type-mapscircle-list": "List of circles",
+ "validator-type-mapsimageoverlay": "Image overlay",
+ "validator-type-mapsimageoverlay-list": "List of image overlays",
+ "validator-type-mapsline": "Geographical line",
+ "validator-type-mapsline-list": "List of lines",
+ "validator-type-mapslocation": "Geographical location",
+ "validator-type-mapslocation-list": "List of locations",
+ "validator-type-mapsrectangle": "Geographical rectangle",
+ "validator-type-mapsrectangle-list": "List of rectangles",
+ "validator-type-mapspolygon": "Geographical polygon",
+ "validator-type-mapspolygon-list": "List of geographical polygons",
+ "validator-type-wmsoverlay": "Web Map Service overlay",
+ "validator-type-jsonfile": "text"
+}
diff --git a/www/wiki/extensions/Maps/i18n/eo.json b/www/wiki/extensions/Maps/i18n/eo.json
new file mode 100644
index 00000000..cd5be1d8
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/eo.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Yekrats"
+ ]
+ },
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "U",
+ "maps-latitude": "Latitudo:",
+ "maps-longitude": "Longitudo:",
+ "maps_map_cannot_be_displayed": "La mapo ne esti montrebla.",
+ "maps_click_to_activate": "Klaku aktivigi mapon"
+}
diff --git a/www/wiki/extensions/Maps/i18n/es.json b/www/wiki/extensions/Maps/i18n/es.json
new file mode 100644
index 00000000..e9eaa1ed
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/es.json
@@ -0,0 +1,233 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armando-Martin",
+ "Ciencia Al Poder",
+ "Crazymadlover",
+ "Dferg",
+ "Diego Grez",
+ "Fitoschido",
+ "Imre",
+ "Locos epraix",
+ "MarcoAurelio",
+ "Pertile",
+ "Peter17",
+ "Sanbec",
+ "Sethladan",
+ "Translationista",
+ "Vivaelcelta",
+ "Macofe",
+ "Themasterriot",
+ "Mor",
+ "Rafael.minuesa",
+ "Indiralena",
+ "Lemondoge",
+ "Rubentl134",
+ "AlvaroMolina",
+ "Dgstranz",
+ "Carlosmg.dg"
+ ]
+ },
+ "maps-desc": "Habilita la inserción de mapas dinámicos en páginas wikis, la geocodificación de direcciones y otras operaciones geográficas",
+ "right-geocode": "Geocodificar",
+ "action-geocode": "hacer geocodificación en este wiki",
+ "maps_map": "Mapa",
+ "maps-tracking-category": "Páginas con un mapa de la extensión Maps",
+ "maps-loading-map": "Cargando el mapa…",
+ "maps-load-failed": "No se pudo cargar el mapa.",
+ "maps-markers": "Marcadores",
+ "maps-copycoords-prompt": "Ctrl+C, Intro",
+ "maps-searchmarkers-text": "Marcadores de filtro",
+ "maps-others": "otros",
+ "maps-kml-parsing-failed": "Falló el análisis de uno o más archivos KML. Por lo general, esto se debe a fallos de recuperación o a XML con formato incorrecto.",
+ "maps-ns-layer": "Capa",
+ "maps-ns-layer-talk": "Discusión de capa",
+ "maps-layer-property": "Propiedad",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Errores",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definición no válida|Definiciones no válidas}}",
+ "maps-layerdef-invalid-fatal": "Definición no válida fatal",
+ "maps-layerdef-wrong-namespace": "Las definiciones de capas solo son válidas en el espacio de nombres «$1».",
+ "maps-layerdef-equal-layer-name": "Los nombres de las capas deben ser únicos dentro de la misma página de capas. Otra capa ya está utilizando «$1».",
+ "maps-layerpage-usage": "Páginas con mapas que usan la capa «$1»",
+ "maps-layerpage-nousage": "No hay páginas que usen esta capa en este momento.",
+ "maps-error-invalid-layertype": "No hay capas de tipo \"$1\". Sólo {{PLURAL:$3|este tipo es compatible|estos tipos son compatibles}} :$2",
+ "maps-error-no-layertype": "Es necesario especificar el tipo de capa. {{PLURAL:$2| Solo este tipo es compatible|Estos tipos son compatibles}}:$1",
+ "validation-error-invalid-layer": "El parámetro $1 debe ser una capa válida.",
+ "validation-error-invalid-layers": "El parámetro $1 debe ser una o más capas válidas.",
+ "validation-error-no-non-numeric": "El parámetro «$1» no debe ser una cadena numérica.",
+ "validation-error-no-non-numerics": "El parámetro «$1» debe ser una o más cadenas no numéricas.",
+ "maps-layer-of-type": "Capa de tipo \"$1\"",
+ "maps-layer-of-type-and-name": "Capa «$2» del tipo «$1»",
+ "maps-layer-type-supported-by": "Este tipo de capa solo puede ser utilizado con {{PLURAL:$2|el servicio de mapas $1|estos servicios de mapas: $1 }}.",
+ "maps-coordinates-description": "Marcador del analizador para formatear las coordenadas, desde y hacia cualquiera de los formatos compatibles.",
+ "maps-displaymap-description": "Mostrar mapas geográficos sin ningún marcador definido por el wiki sobre ellos.",
+ "maps-distance-description": "Convertir una distancia definida en alguna unidad admitida en su equivalente en otra unidad.",
+ "maps-finddestination-description": "Encontrar un destino dado un punto de partida (que puede estar en cualquiera de los formatos compatibles), un orientación inicial y una distancia.",
+ "maps-geocode-description": "Permite la geocodificación de direcciones, en otras palabras, transformando las ubicaciones legibles por humanos en conjuntos de coordenadas. No hay soporte para varios servicios de geocodificación, que no deben confundirse con servicios de mapas.",
+ "maps-geodistance-description": "Calcular la distancia geográfica entre dos puntos, desde y hacia cualquiera de los formatos compatibles.",
+ "maps-mapsdoc-description": "Mostrar una tabla con los parámetros para un servicio de mapas especificado junto con sus valores predeterminados y descripciones.",
+ "maps-layerdefinition-description": "Describe una capa personalizada que puede ser visualizada con otras funciones del Mapa.",
+ "maps-mapsdoc-par-service": "El servicio de mapas desde el que mostrar la documentación del parámetro.",
+ "maps-mapsdoc-par-language": "El idioma en el que mostrar la documentación. Si dicha traducción no está disponible, se utilizará el inglés en su lugar.",
+ "maps-coordinates-par-location": "Las coordenadas a las que desee dar formato.",
+ "maps-coordinates-par-format": "El formato de destino de las coordenadas.",
+ "maps-coordinates-par-directional": "Indica si las coordenadas deben producirse con formato direccional o no.",
+ "maps-par-scrollwheelzoom": "Indica si se debe activar o no el desplazamiento con el ratón.",
+ "maps-distance-par-distance": "La distancia a convertir en su equivalente con una unidad especificada.",
+ "maps-distance-par-decimals": "El número máximo de dígitos fraccionarios a usar en el valor resultante.",
+ "maps-distance-par-unit": "La unidad en la que mostrar la distancia.",
+ "maps-finddestination-par-location": "La ubicación inicial.",
+ "maps-finddestination-par-bearing": "La orientación inicial.",
+ "maps-finddestination-par-distance": "La distancia que recorrer.",
+ "maps-finddestination-par-format": "El formato en el que mostrar el destino.",
+ "maps-finddestination-par-directional": "Indica si el formato de destino debe ser direccional o no.",
+ "maps-geocode-par-location": "La dirección que quieres geocodificar.",
+ "maps-geocode-par-format": "El formato de las coordenadas resultantes.",
+ "maps-geocode-par-directional": "Indica si las coordenadas deben producirse con formato direccional o no.",
+ "maps-geodistance-par-location1": "El primer punto del conjunto para calcular la distancia.",
+ "maps-geodistance-par-location2": "El segundo punto en el conjunto para calcular la distancia.",
+ "maps-geodistance-par-unit": "La unidad en la que mostrar la distancia.",
+ "maps-geodistance-par-decimals": "El número máximo de dígitos fraccionarios a usar en el valor resultante.",
+ "maps-displaymap-par-mappingservice": "Permite configurar el servicio de cartografía que se utilizará para generar el mapa.",
+ "maps-displaymap-par-coordinates": "La localización respecto de la cual el mapa aparecerá inicialmente centrado.",
+ "maps-displaymap-par-visitedicon": "El nombre de archivo de una imagen que será usada como iconos de marca luego de hacer clic en los marcadores originales",
+ "maps-displaymap-par-zoom": "Permite configurar el nivel de zoom del mapa.\nCuando no se proporciona y varios marcadores están presentes en el mapa, se tomará el mejor ajuste de zoom, y no el valor configurado por defecto.",
+ "maps-displaymap-par-centre": "Permite establecer las coordenadas del centro del mapa mediante display_point(s).\nAcepta tanto direcciones como coordenadas.\nCuando esta propiedad no se indica, el mapa se centrará en torno al marcador proporcionado, o entre los marcadores proporcionados.",
+ "maps-displaymap-par-title": "Permite configurar el texto que se mostrará en las ventanas emergentes de todos los marcadores que no tienen un título específico.\nCuando se utiliza junto con la etiqueta, el título aparecerá en negrita y subrayado.",
+ "maps-displaymap-par-label": "Permite establecer el texto que se mostrará en las ventanas emergentes de todos los marcadores que no tienen una etiqueta específica.",
+ "maps-displaymap-par-icon": "Permite configurar el icono utilizado para todos los marcadores.",
+ "maps-displaymap-par-circles": "Círculos que mostrar",
+ "maps-displaymap-par-copycoords": "Mostrar un cuadro de diálogo haciendo clic en una ubicación desde el que podrán ser copiadas sus coordenadas",
+ "maps-displaymap-par-lines": "Líneas que mostrar",
+ "maps-displaymap-par-maxzoom": "El nivel máximo de zoom",
+ "maps-displaymap-par-minzoom": "El nivel mínimo de zoom",
+ "maps-displaymap-par-polygons": "Polígonos que mostrar",
+ "maps-displaymap-par-rectangles": "Rectángulos que mostrar",
+ "maps-displaymap-par-static": "Hacer el mapa estático",
+ "maps-displaymap-par-wmsoverlay": "Utilizar una capa WMS",
+ "maps-displaymap-par-geojson": "URL de un archivo GeoJSON",
+ "maps-fullscreen-button": "Activar o desactivar pantalla completa",
+ "maps-fullscreen-button-tooltip": "Ver el mapa en toda la pantalla o incrustado.",
+ "validation-error-invalid-location": "El parámetro \"$1\" deber ser una ubicación válida.",
+ "validation-error-invalid-locations": "El parámetro \"$1\" debe ser una o más ubicaciones válidas.",
+ "validation-error-invalid-width": "El parámetro «$1» debe ser una anchura válida.",
+ "validation-error-invalid-height": "El parámetro $1 deber ser una altura válida.",
+ "validation-error-invalid-distance": "El parámetro \"$1\" debe ser una distancia válida.",
+ "validation-error-invalid-distances": "El parámetro \"$1\" debe ser una o más distancias válidas.",
+ "validation-error-invalid-image": "El parámetro \"$1\" debe ser una imagen válida.",
+ "validation-error-invalid-images": "El parámetro \"$1\" debe ser una o más imágenes válidas.",
+ "validation-error-invalid-goverlay": "El parámetro \"$1\" debe ser una superposición válida.",
+ "validation-error-invalid-goverlays": "El parámetro \"$1\" debe ser una o más superposiciones válidas.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitud:",
+ "maps-longitude": "Longitud:",
+ "maps-invalid-coordinates": "El valor $1 no fue reconocido como un conjunto válido de coordenadas.",
+ "maps_coordinates_missing": "Sin coordenadas provistas para el mapa.",
+ "maps_geocoding_failed": "Las siguientes {{PLURAL:$2|dirección|direcciones}} no han podido ser geocodificadas: $1.\nNo se puede mostrar el mapa.",
+ "maps_geocoding_failed_for": "No fue posible geocodificar {{PLURAL:$2|la siguiente dirección, que ha sido omitida|las siguientes direcciones, que han sido omitidas}} del mapa:$1.",
+ "maps_unrecognized_coords": "{{PLURAL:$2|La siguiente coordenada no fue reconocida|Las siguientes coordenadas no fueron reconocidas}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|La coordenada siguiente no se reconoce y se ha|Las coordenadas siguientes no se reconocen y se han}} omitido del mapa:\n$1",
+ "maps_map_cannot_be_displayed": "No se puede mostrar el mapa.",
+ "maps-geocoder-not-available": "La funcionalidad de geocodificación de Maps no está disponible. Su ubicación no puede ser geocodificada.",
+ "maps-leaflet-par-defzoom": "Permite establecer el nivel de ampliación predeterminado del mapa.",
+ "maps-leaflet-par-layers": "Las capas que estarán disponibles en el selector de capas. La primera de ellas se mostrará al cargarse el mapa.",
+ "maps_click_to_activate": "Haz clic para activar el mapa",
+ "maps_centred_on": "Mapa centrado en $1, $2.",
+ "maps-par-mappingservice": "Permite configurar el servicio de cartografía que se utilizará para generar el mapa.",
+ "maps-par-resizable": "Hace que se puedan alterar las dimensiones del mapa arrastrando su esquina inferior derecha.",
+ "maps-par-searchmarkers": "Permite buscar marcadores específicos a través de un campo incrustado en el mapa.",
+ "maps-par-zoom": "El nivel de ampliación del mapa. Para mapas con marcadores el valor predeterminado será el máximo que aun muestre todos los marcadores.",
+ "maps-par-width": "Permite establecer la anchura del mapa. De forma predeterminada se emplearán los pixeles como unidad, pero puede especificar explícitamente una de estas unidades: px, ex, em, %.",
+ "maps-par-height": "Permite establecer la altura del mapa. De forma predeterminada se usarán los pixeles como unidad, pero puede especificar explícitamente una de estas unidades: px, ex, em, %.",
+ "maps-par-centre": "La ubicación en la que el mapa debe quedar centrado",
+ "maps-par-enable-fullscreen": "Activar el botón «Pantalla completa»",
+ "maps-par-kml": "Archivos KML para cargar en el mapa.",
+ "maps-par-markercluster": "Permite fusionar múltiples marcadores cercanos en un marcador",
+ "maps-googlemaps3-incompatbrowser": "Su navegador no es compatible con Google Maps v2.",
+ "maps-googlemaps3-par-imageoverlays": "Permite añadir una imagen que mostrar en la ubicación especificada en el mapa.",
+ "maps-googlemaps3-par-type": "El tipo de mapa que mostrar inicialmente.",
+ "maps-googlemaps3-par-types": "Los tipos de mapa que estarán disponibles a través del control de tipo.",
+ "maps-googlemaps3-par-layers": "Capas especiales para cargar en el mapa.",
+ "maps-googlemaps3-par-controls": "Los controles a colocar en el mapa.",
+ "maps-googlemaps3-par-zoomstyle": "El estilo del control de zoom.",
+ "maps-googlemaps3-par-typestyle": "El estilo del control de tipo.",
+ "maps-googlemaps3-par-autoinfowindows": "Abrir automáticamente todas las ventanas de información después de que la página se haya cargado.",
+ "maps-googlemaps3-par-gkml": "Archivos KML alojados por Google para cargar en el mapa.",
+ "maps-googlemaps3-par-kmlrezoom": "Ajustar el nivel de zoom del mapa después de que se hayan cargado las capas KML.",
+ "maps-googlemaps3-par-poi": "Mostrar puntos de interés.",
+ "maps-googlemaps3-par-clustergridsize": "La medida de la cuadrícula de una agrupación en píxeles.",
+ "maps-googlemaps3-par-clusterminsize": "El número mínimo de marcadores que están en una agrupación antes de que los marcadores se oculten y aparezca un recuento.",
+ "mapeditor": "Editor de mapas",
+ "specialpages-group-maps": "Mapas",
+ "mapeditor-parser-error": "Se ha producido un error al analizar los metadatos. Ignorando la entrada del usuario.",
+ "mapeditor-none-text": "Ninguno",
+ "mapeditor-done-button": "Hecho",
+ "mapeditor-remove-button": "Eliminar",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Exportar a código wiki",
+ "mapeditor-import-button": "Importar desde código wiki",
+ "mapeditor-select-button": "Selecciona este polígono",
+ "mapeditor-mapparam-button": "Editar parámetros del mapa",
+ "mapeditor-clear-button": "Limpiar mapa",
+ "mapeditor-code-title": "Código wiki",
+ "mapeditor-import-title": "Importar código wiki",
+ "mapeditor-import-note": "Tenga en cuenta que el analizador espera un formato muy estricto en el código wiki. El código introducido aquí debe coincidir con el código producido por la funcionalidad de exportación.",
+ "mapeditor-form-title": "Editar los detalles",
+ "mapeditor-link-title-switcher-popup-text": "Ventana emergente con texto",
+ "mapeditor-link-title-switcher-link-text": "Enlace",
+ "mapeditor-form-field-title": "Título",
+ "mapeditor-form-field-text": "Texto",
+ "mapeditor-form-field-link": "Enlace",
+ "mapeditor-form-field-icon": "Icono",
+ "mapeditor-form-field-group": "Grupo",
+ "mapeditor-form-field-inlinelabel": "Etiqueta en línea",
+ "mapeditor-form-field-strokecolor": "Color de trazo",
+ "mapeditor-form-field-strokeopacity": "Opacidad del trazo",
+ "mapeditor-form-field-strokeweight": "Grosor de trazo",
+ "mapeditor-form-field-fillcolor": "Color de relleno",
+ "mapeditor-form-field-fillopcaity": "Opacidad de relleno",
+ "mapeditor-form-field-showonhover": "Mostrar solo al posar el ratón por encima",
+ "mapeditor-mapparam-title": "Editar parámetros del mapa",
+ "mapeditor-mapparam-defoption": "-Seleccionar parámetro-",
+ "mapeditor-imageoverlay-button": "Agregar imagen superpuesta",
+ "mapeditor-form-field-image": "Imagen",
+ "mapeditor-imageoverlay-title": "Detalles de la imagen superpuesta",
+ "mapeditor-form-field-visitedicon": "Icono visitado",
+ "semanticmaps-unrecognizeddistance": "El valor $1 no es una distancia válida.",
+ "semanticmaps-kml-link": "Ver el archivo KML",
+ "semanticmaps-default-kml-pagelink": "Ver página $1",
+ "semanticmaps-latitude": "Latitud: $1",
+ "semanticmaps-longitude": "Longitud: $1",
+ "semanticmaps-altitude": "Altitud: $1",
+ "semanticmaps-forminput-locations": "Ubicaciones",
+ "semanticmaps-par-staticlocations": "Una lista de localizaciones para añadir al mapa junto a los datos consultados. De forma similar a display_points, puede añadir un título, una descripción o un icono por localización usando el signo \"~\" como separador.",
+ "semanticmaps-par-showtitle": "Mostrar o no mostrar un título en la ventana de información del marcador. La desactivación de esto es frecuentemente útil al utilizar una plantilla para dar formato al contenido de la ventana de información.",
+ "semanticmaps-par-hidenamespace": "Mostrar el título del espacio de nombres en la ventana de información del marcador.",
+ "semanticmaps-par-centre": "El centro del mapa. Cuando no se proporciona, el mapa escogerá automáticamente el mejor centro para mostrar todos los marcadores en el mapa.",
+ "semanticmaps-par-template": "Una plantilla a usar para dar formato al contenido de la ventana de información.",
+ "semanticmaps-par-geocodecontrol": "Mostrar el control de geocodificación.",
+ "semanticmaps-par-ajaxcoordproperty": "Nombre de la propiedad de coordenada que se utiliza para crear la consulta AJAX.",
+ "semanticmaps-par-ajaxquery": "Una segunda consulta que se envía mediante AJAX para obtener coordenadas adicionales.",
+ "semanticmaps-par-userparam": "Un valor pasado en cada llamada de plantilla,si una plantilla es usada",
+ "semanticmaps-kml-text": "El texto asociado a cada página. Es substituído por las propiedades recuperadas adicionales, si existen.",
+ "semanticmaps-kml-title": "El título predeterminado de los resultados",
+ "semanticmaps-kml-linkabsolute": "Los enlaces deberían ser absolutos (lo opuesto de relativos)",
+ "semanticmaps-kml-pagelinktext": "El texto a usar para los enlaces a la página, en las que $1 será substituído por el título de la página",
+ "semanticmaps-shapes-improperformat": "Formateo incorrecto de $1, por favor consulta la documentación sobre formateo",
+ "semanticmaps-shapes-missingshape": "No se ha encontrado ninguna forma para $1, por favor consulta la documentación sobre formas disponibles",
+ "validator-type-mapscircle": "Círculo geográfico",
+ "validator-type-mapscircle-list": "Lista de círculos",
+ "validator-type-mapsline": "Línea geográfica",
+ "validator-type-mapsline-list": "Lista de líneas",
+ "validator-type-mapslocation": "Ubicación geográfica",
+ "validator-type-mapslocation-list": "Lista de ubicaciones",
+ "validator-type-mapsrectangle": "Rectángulo geográfico",
+ "validator-type-mapsrectangle-list": "Lista de rectángulos",
+ "validator-type-mapspolygon": "Polígono geográfico",
+ "validator-type-mapspolygon-list": "Lista de polígonos geográficos",
+ "validator-type-jsonfile": "texto"
+}
diff --git a/www/wiki/extensions/Maps/i18n/et.json b/www/wiki/extensions/Maps/i18n/et.json
new file mode 100644
index 00000000..76ae0f48
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/et.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Avjoska",
+ "Hendrik",
+ "Pikne"
+ ]
+ },
+ "maps_map": "Kaart",
+ "maps-loading-map": "Kaardi laadimine...",
+ "maps-others": "teised",
+ "maps-geocode-par-location": "Geokodeeritav aadress.",
+ "maps-displaymap-par-maxzoom": "Maksimaalne suumi tase",
+ "maps-displaymap-par-minzoom": "Minimaalne suumi tase",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Laius:",
+ "maps-longitude": "Pikkus:",
+ "maps_map_cannot_be_displayed": "Kaarti ei saa kuvada.",
+ "maps-osm-par-thumbs": "Näita pisipilte",
+ "maps-osm-par-photos": "Näita fotosid",
+ "mapeditor": "Kaardi toimetaja",
+ "specialpages-group-maps": "Kaardid",
+ "mapeditor-none-text": "Puudub",
+ "mapeditor-done-button": "Valmis",
+ "mapeditor-remove-button": "Eemalda",
+ "mapeditor-import-button2": "Impordi",
+ "mapeditor-clear-button": "Tühjenda kaart",
+ "mapeditor-code-title": "Viki kood",
+ "mapeditor-form-title": "Muuda üksikasju",
+ "mapeditor-link-title-switcher-popup-text": "Hüpikaken tekstiga",
+ "mapeditor-form-field-title": "Pealkiri",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Ikoon",
+ "mapeditor-form-field-group": "Rühm",
+ "mapeditor-form-field-image": "Pilt"
+}
diff --git a/www/wiki/extensions/Maps/i18n/eu.json b/www/wiki/extensions/Maps/i18n/eu.json
new file mode 100644
index 00000000..815a4fbd
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/eu.json
@@ -0,0 +1,78 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kobazulo",
+ "පසිඳු කාවින්ද",
+ "Subi",
+ "An13sa",
+ "Mikel Ibaiba"
+ ]
+ },
+ "maps_map": "Mapa",
+ "maps-loading-map": "Mapa kargatzen...",
+ "maps-load-failed": "Ezin da mapa kargatu!",
+ "maps-markers": "Markatzaileak",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Markatzaileak iragazi",
+ "maps-others": "Bestelakoak",
+ "maps-ns-layer": "Geruza",
+ "maps-layer-property": "Propietatea",
+ "maps-layer-value": "Balioa",
+ "maps-layer-errors": "Erroreak",
+ "maps-layer-of-type": "\"$1\" motako geruza",
+ "maps-layer-of-type-and-name": "\"$2\" geruza \"$1\" motatakoa",
+ "maps-finddestination-par-location": "Hasierako kokapena.",
+ "maps-finddestination-par-distance": "Bidaiatzeko distantzia.",
+ "maps-displaymap-par-circles": "Erakusteko zirkuluak",
+ "maps-displaymap-par-lines": "Lerroak erakusteko",
+ "maps-displaymap-par-polygons": "Erakusteko poligonoak",
+ "maps-displaymap-par-rectangles": "Erakusteko laukizuzenak",
+ "maps-abb-north": "I",
+ "maps-abb-east": "E",
+ "maps-abb-south": "H",
+ "maps-abb-west": "M",
+ "maps-latitude": "Latitudea:",
+ "maps-longitude": "Longitudea:",
+ "maps_coordinates_missing": "Ez dago koordenaturik maparentzat.",
+ "maps_map_cannot_be_displayed": "Ezin da mapa erakutsi.",
+ "maps-googlemaps3-incompatbrowser": "Zure nabigatzailea ez da Google Maps v3-rekin bateragarria.",
+ "maps-googlemaps3-par-poi": "Erakutsi interesguneak",
+ "specialpages-group-maps": "Mapak",
+ "mapeditor-none-text": "Bat ere ez",
+ "mapeditor-done-button": "Egina",
+ "mapeditor-remove-button": "Kendu",
+ "mapeditor-import-button2": "Inportatu",
+ "mapeditor-export-button": "Esportatu wiki kodera",
+ "mapeditor-import-button": "Inportatu wiki kodetik",
+ "mapeditor-select-button": "Hautatu poligono hau",
+ "mapeditor-mapparam-button": "Editatu mapako parametroak",
+ "mapeditor-clear-button": "Garbitu mapa",
+ "mapeditor-code-title": "Wiki kodea",
+ "mapeditor-import-title": "Inportatu wiki kodea",
+ "mapeditor-form-title": "Editatu xehetasunak",
+ "mapeditor-link-title-switcher-link-text": "Lotura",
+ "mapeditor-form-field-title": "Izenburua",
+ "mapeditor-form-field-text": "Testua",
+ "mapeditor-form-field-link": "Lotura",
+ "mapeditor-form-field-icon": "Ikonoa",
+ "mapeditor-form-field-group": "Taldea",
+ "mapeditor-mapparam-title": "Editatu mapako parametroak",
+ "mapeditor-mapparam-defoption": "-Hautatu parametroa-",
+ "mapeditor-form-field-image": "Irudi",
+ "semanticmaps-kml-link": "Ikusi KML fitxategia",
+ "semanticmaps-default-kml-pagelink": "Ikusi $1 orrialdea",
+ "semanticmaps-latitude": "Latitudea: $1",
+ "semanticmaps-longitude": "Longitudea: $1",
+ "semanticmaps-altitude": "Altitudea: $1",
+ "semanticmaps-forminput-locations": "Kokapenak",
+ "validator-type-mapscircle": "Zirkulu geografikoa",
+ "validator-type-mapscircle-list": "Zirkuluen zerrenda",
+ "validator-type-mapsline": "Lerro geografikoa",
+ "validator-type-mapsline-list": "Lerroen zerrenda",
+ "validator-type-mapslocation": "Kokapen geografikoa",
+ "validator-type-mapslocation-list": "Kokapen-zerrenda",
+ "validator-type-mapsrectangle": "Laukizuzen geografikoa",
+ "validator-type-mapsrectangle-list": "Laukizuzenen zerrenda",
+ "validator-type-mapspolygon": "Poligono geografikoa",
+ "validator-type-mapspolygon-list": "Poligono geografikoen zerrenda"
+}
diff --git a/www/wiki/extensions/Maps/i18n/fa.json b/www/wiki/extensions/Maps/i18n/fa.json
new file mode 100644
index 00000000..f3e05a6b
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/fa.json
@@ -0,0 +1,194 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armin1392",
+ "Ebraminio",
+ "Mjbmr",
+ "ZxxZxxZ",
+ "Alirezaaa",
+ "Macofe",
+ "Ommmmid"
+ ]
+ },
+ "maps-desc": "فعال کردن قرار دادن نقشه‌های پویا در صفحات ویکی، رمزگذاری جغرافیایی آدرس‌ها و دیگر عملیات جغرافیایی",
+ "right-geocode": "جئوکد",
+ "maps_map": "نقشه",
+ "maps-tracking-category": "صفحات با نقشهٔ‌ ارائه شده توسط گسترهٔ‌ نقشه‌ها",
+ "maps-loading-map": "در حال بارگیری نقشه...",
+ "maps-load-failed": "قادر به بارگیری نقشه نبود!",
+ "maps-markers": "نشانگرها",
+ "maps-copycoords-prompt": "CTRL+C, وارد کنید",
+ "maps-searchmarkers-text": "نشانگرهای فیلتر",
+ "maps-others": "دیگران",
+ "maps-kml-parsing-failed": "عدم موفقیت تجزیهٔ یک یا چند پوشهٔ کا‌ام‌ال، اغلب به علت عدم بازیابی یا ایکس‌ام‌ال ناقص.",
+ "maps-ns-layer": "لایه",
+ "maps-ns-layer-talk": "بحث لایه",
+ "maps-layer-property": "خاصیت",
+ "maps-layer-value": "مقدار",
+ "maps-layer-errors": "خطاها",
+ "maps-layerdef-invalid": "تعریف نامعتبر{{PLURAL:$1||s}}",
+ "maps-layerdef-invalid-fatal": "تعریف نامعتبر مهلک",
+ "maps-layerdef-wrong-namespace": "تعاریف لایه فقط در صفحات فضای نام \"$1\" معتبر هستند",
+ "maps-layerdef-equal-layer-name": "نام‌های لایه باید داخل صفحهٔ‌ لایهٔ مشابه منحصر به فرد باشد. \"$1\" در حال حاضر توسط لایهٔ دیگری استفاده شده‌.",
+ "maps-layerpage-usage": "صفحات دارای نقشه از لایهٔ‌ \"$1\" استفاده می‌کند",
+ "maps-layerpage-nousage": "هیچ صفحه‌ای در حال حاضر از این لایه استفاده نمی‌کند.",
+ "maps-error-invalid-layertype": "هیچ لایه‌ای از نوع «$1» وجود ندارد. فقط {{PLURAL:$3|این نوع|این نوع‌ها}} پشتیبانی می‌شوند: $2",
+ "maps-error-no-layertype": "باید نوع لایه را مشخص کنید. {{PLURAL:$2|فقط این نوع پشتیبانی می‌شود|این نوع‌ها پشتیبانی می‌شوند}}: $1",
+ "validation-error-invalid-layer": "پارامتر $1 باید یک لایهٔ معتبر باشد.",
+ "validation-error-invalid-layers": "پارامتر $1 باید یک یا چند لایهٔ معتبر باشد.",
+ "validation-error-no-non-numeric": "پارامتر \"$1\" باید یک مجموعهٔ غیرعددی باشد.",
+ "validation-error-no-non-numerics": "پارامتر \"$1\" باید یک یا چند مجموعهٔ‌ غیرعددی باشد.",
+ "maps-layer-of-type": "لایه ای از نوع $1",
+ "maps-layer-of-type-and-name": "لایهٔ \"$2\" از نوع \"$1\"",
+ "maps-layer-type-supported-by": "این نوع لایه می‌تواند {{PLURAL:$2|فقط با سرویس نقشه‌برداری $1 استفاده شود|با این سرویس‌های نقشه‌برداری استفاده شود: $1}}.",
+ "maps-coordinates-description": "قلاب تجزیه کننده برای فرمت مختصات، از و به هر فرمت پشتیبانی شده.",
+ "maps-displaymap-description": "نمایش نقشه‌های جغرافیایی بدون هر نشانگر تعریف شده‌ٔ ویکی بر روی آنها.",
+ "maps-distance-description": "تبدیل یک فاصله با استفاده از یک واحد مشخص پشتیبانی شده برابر با استفاده از واحد دیگری.",
+ "maps-finddestination-description": "پیدا کردن یک مقصد که یک نقطهٔ شروع داده (که می‌تواند در هر فرمت پشتیبانی شده‌ای باشد)، وضع اولیه و یک فاصله.",
+ "maps-geocode-description": "فعل کردن آدرس‌های جئوکدینگ، به عبارت دیگر تبدیل مکان‌های انسانی قابل خواندن به مجموعهٔ مختصات. پشتیبانی برای چندین سرویس های جئوکدینگ، که نباید با سرویس‌های نقشه برداری اشتباه شود، وجود دارد.",
+ "maps-geodistance-description": "محاسبهٔ فاصلهٔ جغرافیایی بین دو نقطه، از و به هر فرمت پشتیبانی شده.",
+ "maps-mapsdoc-description": "نمایش یک جدول با پارامتر‌ها برای سرویس نقشه‌برداری تعیین شده باهم با مقادیر پیش‌فرض آنها و توصیفات.",
+ "maps-layerdefinition-description": "توصیف یک لایهٔ عادت که می‌تواند با دیگر مختصات نقشه نمایش داده شود.",
+ "maps-mapsdoc-par-service": "سرویس نقشه برای نمایش مستندات پارامتر.",
+ "maps-mapsdoc-par-language": "زبانی که برای اسناد نمایش داده می‌شود. اگر چنین ترجمه‌ای در دسترس نسیت، به جای آن انگلیسی استفاده خواهد شد.",
+ "maps-coordinates-par-location": "مختصاتی که می‌خواهید شکل‌بندی کنید.",
+ "maps-coordinates-par-format": "شکل موردنظر برای مختصات.",
+ "maps-coordinates-par-directional": "نمایش دادن اینکه مختصات باید خروجی هدایتی باشد یا نباشد.",
+ "maps-distance-par-distance": "فاصله برای تبدیل به نعادل آن با یک واحد مشخص شده.",
+ "maps-distance-par-decimals": "حداکثر تعداد ارقام کسری برای استفاده در نتیجهٔ ارزش.",
+ "maps-distance-par-unit": "بخشی برای عرضه کردن فاصله.",
+ "maps-finddestination-par-location": "مکان اولیه.",
+ "maps-finddestination-par-bearing": "وضع اولیه.",
+ "maps-finddestination-par-distance": "مسافت برای مسافرت.",
+ "maps-finddestination-par-format": "فرمت برای خروجی مقصد.",
+ "maps-finddestination-par-directional": "نمایش اینکه فرمت مقصد باید هدایتی باشد یا نباشد.",
+ "maps-geocode-par-location": "آدرسی را که برای جئوکد می‌خواهید.",
+ "maps-geocode-par-format": "فرمت برای نتیجهٔ مختصات.",
+ "maps-geocode-par-directional": "نمایش اینکه مختصات باید خروجی هدایتی باشد یا نباشد.",
+ "maps-geodistance-par-location1": "اولین نکته در مجموعه برای برای محاسبهٔ‌ بین فاصله‌ها.",
+ "maps-geodistance-par-location2": "دومین نکته در مجموعه برای برای محاسبهٔ‌ بین فاصله‌ها.",
+ "maps-geodistance-par-unit": "بخشی برای عرضه کردن فاصله.",
+ "maps-geodistance-par-decimals": "حداکثر تعداد ارقام کسری برای استفاده در نتیجهٔ ارزش.",
+ "maps-displaymap-par-mappingservice": "اجازهٔ تنظیم سرویس نقشه‌برداری که برای تولید نقشه استفاده خواهد شد.",
+ "maps-displaymap-par-coordinates": "یک یا چند مکان برای نمایش بر روی یک نقشه. آنها با یک علامت نشان داده خواهد شد.",
+ "maps-displaymap-par-visitedicon": "نام پوشهٔ یک صفحه برای علامت آیکون‌ها که پس از علامت‌های اصلی کلیک شده‌است، مورد استفاده قرار می‌گیرد.",
+ "maps-displaymap-par-zoom": "اجازهٔ تنظیم سطح زوم نقشه.\nهنگامی که ارائه نشده و چند علامت بر روی نقشه ارائه شده، بهترین زوم مناسب گرفته خواهد شد، نه پیش‌فرض قابل پیکربندی.",
+ "maps-displaymap-par-centre": "اجازهٔ تنظیم مختصات مرکز نقشه برای display_point(s).\nآدرس‌ها و مختصات هر دو پذیرفته شدند.\nهنگامی که این ویژگی ارائه نشده‌است، نقشه خود بر روی علامت ارائه شده مرکز، یا بین علامت‌های ارائه شده خواهد بود.",
+ "maps-displaymap-par-title": "تنظیم متنی که در پاپ آپس همهٔ علامت‌هایی که یک عنوان خاص ندارند، نمایش داده خواهد شد.\nهنگامی که با برچسب باهم استفاده شود، عنوان پررنگ‌تر و تأکید دار خواهد بود.",
+ "maps-displaymap-par-label": "اجازهٔ تنظیم متنی که در پاپ آپس همهٔ علامت‌هایی که یک برچسب خاص ندارند، نمایش داده خواهد شد.",
+ "maps-displaymap-par-icon": "اجازهٔ تنظیم آیکون مورد استفاده برای همهٔ علامت‌ها.",
+ "maps-displaymap-par-circles": "حوزه‌ها برای نمایش",
+ "maps-displaymap-par-copycoords": "نمایش یک پنجره محاوره‌ای هنگام کلیک روی یک موقعیت که از مختصاتش می‌تواند نسخه‌برداری شود",
+ "maps-displaymap-par-lines": "خطوط برای نمایش",
+ "maps-displaymap-par-maxzoom": "حداکثر سطح زوم",
+ "maps-displaymap-par-minzoom": "حداقل سطح زوم",
+ "maps-displaymap-par-polygons": "چند ضلعی‌ها برای نمایش",
+ "maps-displaymap-par-rectangles": "مستطیل‌ها برای نمایش",
+ "maps-displaymap-par-static": "اگر نقشه‌ها ایستا باشد",
+ "maps-displaymap-par-wmsoverlay": "استفاده از یک پوشش وی‌ام‌اس",
+ "maps-fullscreen-button": "ضامن تمام صفحه",
+ "maps-fullscreen-button-tooltip": "مشاهدهٔ‌ نقشه به عنوان تمام صفحه یا تعبیه شده.",
+ "validation-error-invalid-location": "پارامتر $1 باید یک مکان معتبر باشد.",
+ "validation-error-invalid-locations": "پارامتر $1 باید یک مکان یا مکان‌های بیشتر معتبری باشد.",
+ "validation-error-invalid-width": "پارامتر $1 باید یک عرض معتبر باشد.",
+ "validation-error-invalid-height": "پارامتر $1 باید یک ارتفاع معتبر باشد.",
+ "validation-error-invalid-distance": "پارامتر $1 باید یک فاصلهٔ‌ معتبر باشد.",
+ "validation-error-invalid-distances": "پارامتر $1 باید یک فاصله یا فاصله‌های بیشتر معتبر باشد.",
+ "validation-error-invalid-image": "پارامتر $1 باید یک عکس معتبر باشد.",
+ "validation-error-invalid-images": "پارامتر $1 باید یک عکس یا عکس‌های بیشتر باشد.",
+ "validation-error-invalid-goverlay": "پارامتر $1 باید یک پوشش معتبر باشد.",
+ "validation-error-invalid-goverlays": "پارامتر $1 باید یک پوشش یا پوشش‌های معتبر باشد.",
+ "maps-abb-north": "شمال",
+ "maps-abb-east": "شرق",
+ "maps-abb-south": "جنوب",
+ "maps-abb-west": "غرب",
+ "maps-latitude": "عرض جغرافیایی:",
+ "maps-longitude": "طول جغرافیایی:",
+ "maps-invalid-coordinates": "مقدار $1 به عنوان یک تنظیم مختصات معتبر شناخته نشده.",
+ "maps_coordinates_missing": "هیچ مختصاتی برای نقشه ارائه نشده.",
+ "maps_geocoding_failed": "{{PLURAL:$2|آدرس|آدرس‌های}} زیر نتوانستند رمزگذاری جغرافیایی شوند: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|آدرس|آدرس‌های}} زیر نتوانستند رمزگذاری جغرافیایی شوند و {{PLURAL:$2|has|have}} از نقشه حذف شده‌است: \n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|مختصات بود|مختصات بودند}} زیر شناخته شده نبودند:‌ $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|مختصات بود|مختصات بودند}} زیر نتوانستند شناخته شوند و {{PLURAL:$2|has|have}} از نقشه حذف شده‌است: \n$1",
+ "maps_map_cannot_be_displayed": "نقشه نمی‌تواند نمایش داده شود.",
+ "maps-geocoder-not-available": "رمزگداری ویژگی نقشه در دسترس نیست. مکان شما نمی‌تواند رمزگذاری جغرافیایی شود.",
+ "maps-leaflet-par-layers": "لایه‌هایی که در انتخاب کننده‌ٔ لایه در دسترس خواهند بود. اولین لایه هنگامی نمایش داده خواهد شد که نقشه بازگداری می‌شود.",
+ "maps_click_to_activate": "کلیک کردن برای فعال کردن نقشهٔ.",
+ "maps_centred_on": "نقشهٔ متمرکز شده در $1، $2.",
+ "maps-par-mappingservice": "اجازهٔ تنظیم سرویس نقشه‌برداری که برای تولید نقشه استفاده خواهد شد.",
+ "maps-par-resizable": "درست کردن نقشه‌ای که توسط کشیدن در گوشهٔ پایین سمت راست دوباره قابل ملاحظه باشد.",
+ "maps-par-zoom": "سطح زوم برای نقشه. برای نقشه‌ها با علامت‌های این، برای زوم‌ شدهٔ بیشتر در سطحی که هنوز همهٔ علامت‌ها را نشان می‌دهد،پیش‌فرض خواهد بود.",
+ "maps-par-width": "اجازهٔ تنظیم عرض نقشه. با پیکسل‌های پیش‌فرض، به عنوان واحد فرض خواهد شد، اما شما می‌توانید یکی از این واحدها را به طور واضح مشخص کنید: پی‌ایکس، ای‌ایکس، ای‌ام، ٪.",
+ "maps-par-height": "اجازهٔ تنظیم ارتفاع نقشه. با پیکسل‌های پیش‌فرض، به عنوان واحد فرض خواهد شد، اما شما می‌توانید یکی از این واحدها را به طور واضح مشخص کنید: پی‌ایکس، ای‌ایکس، ای‌ام، ٪.",
+ "maps-par-centre": "مکانی که در نقشه باید مرکز باشد",
+ "maps-par-enable-fullscreen": "فعا کردن دکمهٔ تمام صفحه",
+ "maps-par-kml": "پوشه‌های کا‌ام‌ال برای بارگذاری بر روی نقشه.",
+ "maps-googlemaps3-incompatbrowser": "مرورگر شما با نقشه‌های گوگل وی۳ سازگار نیست.",
+ "maps-googlemaps3-par-type": "نوع نقشه برای ابتدا نشان دادن.",
+ "maps-googlemaps3-par-types": "انواع نقشه‌ای که از طریق کنترل نوع در دسترس خواهد بود.",
+ "maps-googlemaps3-par-layers": "لایه‌های ویژه برای بارگذاری برروی نقشه.",
+ "maps-googlemaps3-par-controls": "کنترل‌ها برای قرار دادن بر روی نقشه.",
+ "maps-googlemaps3-par-zoomstyle": "سبک کنترل زوم.",
+ "maps-googlemaps3-par-typestyle": "سبک کنترل نوع.",
+ "maps-googlemaps3-par-autoinfowindows": "به طور خودکار باز شدن همهٔ صفحات اطلاعات، پس از بارگذاری صفحات.",
+ "maps-googlemaps3-par-gkml": "پوشه‌های کا‌ام‌ال توسط گوگل برای بارگذاری بر روی نقشه میزبانی شده‌.",
+ "maps-googlemaps3-par-kmlrezoom": "زوم مجدد نقشه پس از لایه‌های کا‌ام‌ال که بارگذاری شده‌اند.",
+ "maps-googlemaps3-par-poi": "نمایش نقاط مورد علاقه.",
+ "mapeditor": "تدوین‌گر نقشه",
+ "specialpages-group-maps": "نقشه‌ها",
+ "mapeditor-parser-error": "خطاای هنگام تجزیه‌ٔ فراداده اتفاق افتاد. نادیده گرفتن ورودی کاربر.",
+ "mapeditor-none-text": "هیچ کدام",
+ "mapeditor-done-button": "انجام شد",
+ "mapeditor-remove-button": "حذف",
+ "mapeditor-import-button2": "درون‌ریزی",
+ "mapeditor-export-button": "صادرات به کد ویکی",
+ "mapeditor-import-button": "واردات از کد ویکی",
+ "mapeditor-select-button": "انتخاب این چندضلعی",
+ "mapeditor-mapparam-button": "ویرایش پارامترهای نقشه",
+ "mapeditor-clear-button": "واضح کردن نقشه",
+ "mapeditor-code-title": "کد ویکی",
+ "mapeditor-import-title": "واردات کد ویکی",
+ "mapeditor-import-note": "لطفاً توجه داشته باشید که تجزیه‌کننده، یک فرمت بسیار سخت در کد ویکی انتظار دارد. کد ورودی اینجا باید با کد خروجی توسط اصول صادرات، مطابقت داشته باشد.",
+ "mapeditor-form-title": "ویرایش جزئیات",
+ "mapeditor-link-title-switcher-popup-text": "پوپاپ با متن",
+ "mapeditor-link-title-switcher-link-text": "پیوند",
+ "mapeditor-form-field-title": "عنوان",
+ "mapeditor-form-field-text": "متن",
+ "mapeditor-form-field-link": "پیوند",
+ "mapeditor-form-field-icon": "شمایل",
+ "mapeditor-form-field-group": "گروه",
+ "mapeditor-form-field-inlinelabel": "برچسب اینلاین",
+ "mapeditor-form-field-strokecolor": "رنگ استروک",
+ "mapeditor-form-field-strokeopacity": "کدری استروک",
+ "mapeditor-form-field-strokeweight": "وزن استروک",
+ "mapeditor-form-field-fillcolor": "پر کردن رنگ",
+ "mapeditor-form-field-fillopcaity": "پر کردن کدری",
+ "mapeditor-form-field-showonhover": "نمایش فقط در شناور",
+ "mapeditor-mapparam-title": "ویرایش پارامترهای نقشه",
+ "mapeditor-mapparam-defoption": "-انتخاب پارامتر-",
+ "mapeditor-imageoverlay-button": "افزودن روی هم قرار دادن عکس",
+ "mapeditor-form-field-image": "تصویر",
+ "mapeditor-imageoverlay-title": "جزئیات روی هم قرار دادن عکس",
+ "mapeditor-form-field-visitedicon": "نمادهای بازدید شده",
+ "semanticmaps-unrecognizeddistance": "مقدار $1 یک فاصلهٔ معتبر نیست.",
+ "semanticmaps-kml-link": "مشاهدهٔ پوشهٔ کا‌ام‌ال",
+ "semanticmaps-default-kml-pagelink": "مشاهده صفحهٔ $1",
+ "semanticmaps-latitude": "عرض جغرافیایی: $1",
+ "semanticmaps-longitude": "طول جغرافیایی: $1",
+ "semanticmaps-altitude": "ارتفاع: $1",
+ "semanticmaps-forminput-locations": "مکان‌ها",
+ "semanticmaps-par-staticlocations": "فهرست مکان‌های برای افزودن به نقشه با اطلاعات سوال شده. مانند با display_points، شما می توانید یک عنوان، توصیف و نماد در هر مکان با استفاده از عنوان جدا کننده \"~\".",
+ "semanticmaps-par-showtitle": "نمایش یک عنوان در پنجره اطلاعات نشانگر یا نمایش ندادن آن.غیرفعال کردن این اغلب مفید است هنگام استفاده از الگو برای فرمت کردن محتوای پنجره اطلاعات.",
+ "semanticmaps-par-hidenamespace": "نمایش عنوان فضای نام در پنجره اطلاعات نشانگر",
+ "semanticmaps-par-centre": "مرکز نقشه. هنگامی که ارائه نشد،نقشه به طور خودکار مرکز مطلوب را برای نمایش همه نشانگرها در نقشه انتخاب می‌کند.",
+ "semanticmaps-par-template": "الگو برای استفاده از فرمت محتویات پنجره اطلاعات.",
+ "semanticmaps-par-geocodecontrol": "نشان دادن کنترل جئوکدینگ.",
+ "semanticmaps-par-activeicon": "نماد به جای نشانگر پیش‌فرض نمایش داده می‌شود هنگامی که صفحه فعال برابر با نتیجه پرس‌و‌جوی است",
+ "semanticmaps-par-pagelabel": "هنگامی که به «بله» تنظیم می‌شود، همه نشانگرها، یک «inlineLabel» با یک پیوند به صفحه دارند که شامل مختصات برای نشانگر است",
+ "semanticmaps-kml-text": "متن با هر صفحه مرتبط است. اگر هر خواص پرس‌وجو اضافی وجود داشته باشد، به‌وسیله آن خذف لغو شده.",
+ "semanticmaps-kml-title": "عنوان پیش‌زمینه برای نتایج",
+ "semanticmaps-kml-linkabsolute": "پیوندها باید (به عنوان مخالف به نسبی) مطلق باشند",
+ "semanticmaps-kml-pagelinktext": "متن برای استفاده پیوندها به صفحه، که در آن توسط عنوان صفحه $1 جایگزین خواهد شد",
+ "semanticmaps-shapes-improperformat": "شکل‌بندی نادرست $1. لطفاً مستندات را برای شکل‌بندی مشاهده کنید",
+ "semanticmaps-shapes-missingshape": "هیچ شکلی برای$1 پیدا نشد. لطفاً مستندات را برای شکل‌های دردسترس مشاهده کنید"
+}
diff --git a/www/wiki/extensions/Maps/i18n/fi.json b/www/wiki/extensions/Maps/i18n/fi.json
new file mode 100644
index 00000000..516c2703
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/fi.json
@@ -0,0 +1,158 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beluga",
+ "Cimon Avaro",
+ "Crt",
+ "Nedergard",
+ "Nike",
+ "Str4nd",
+ "ZeiP",
+ "Macofe",
+ "Pahkiqaz",
+ "Pyscowicz"
+ ]
+ },
+ "maps-desc": "Mahdollistaa dynaamisten karttojen upottamisen wikisivuille, osoitteiden geokoodauksen ja muita karttoihin liittyviä toimintoja",
+ "right-geocode": "Geokoodata",
+ "maps_map": "Kartta",
+ "maps-loading-map": "Ladataan karttaa...",
+ "maps-load-failed": "Karttaa ei voitu ladata.",
+ "maps-markers": "Kohdemerkit",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Suodatuksen kohdemerkit",
+ "maps-others": "muut",
+ "maps-kml-parsing-failed": "Yhden tai useamman kml-tiedoston jäsentäminen epäonnistui. Todennäköinen syy on lataamisen epäonnistuminen tai viallinen XML-syntaksi.",
+ "maps-ns-layer": "Taso",
+ "maps-ns-layer-talk": "Keskustelu tasosta",
+ "maps-layer-property": "Ominaisuus",
+ "maps-layer-value": "Arvo",
+ "maps-layer-errors": "Virheet",
+ "maps-error-invalid-layertype": "Tasotyyppiä ”$1” ei ole. Vain {{PLURAL:$3|tätä tyyppiä|näitä tyyppejä}} tuetaan: $2",
+ "maps-error-no-layertype": "Tasotyyppi on määritettävä. Vain {{PLURAL:$2|tätä tyyppiä|näitä tyyppejä}} tuetaan: $1",
+ "validation-error-invalid-layer": "Parametrin $1 on oltava sallittu taso.",
+ "validation-error-invalid-layers": "Parametrin $1 on oltava yksi tai useampi sallittu taso.",
+ "maps-layer-of-type": "Taso, jonka tyyppi on $1",
+ "maps-layer-type-supported-by": "Tätä tasotyyppiä voidaan käyttää vain, jos {{PLURAL:$2|karttapalveluna on $1}}.",
+ "maps-coordinates-description": "Jäsentimen laajennuskoodi kordinaattien muotoiluun. Mikä tahansa tuettu muoto voi olla lähtö- tai tulomuoto.",
+ "maps-geocode-description": "Mahdollistaa osoitteiden geokoodauksen eli muuntaa selkokieliset sijainnit koordinaattisarjaksi. Käytettävissä on joukko geokoodauspalveluja, joita ei pidä kuitenkaan sekoittaa karttapalveluihin.",
+ "maps-mapsdoc-description": "Näyttää taulukon, jossa on määritetyn karttapalvelun parametrit, niiden oletusarvot ja kuvaukset.",
+ "maps-mapsdoc-par-service": "Karttapalvelu jolle parametridokumentaatio näytetään.",
+ "maps-mapsdoc-par-language": "Ohjeistuksen kieli. Jos käännöstä ei ole, näytetään englanninkielinen versio.",
+ "maps-coordinates-par-location": "Muotoiltavat koordinaatit",
+ "maps-coordinates-par-format": "Koordinaattien tulosmuoto.",
+ "maps-distance-par-decimals": "Kohdearvon desimaalien enimmäismäärä.",
+ "maps-distance-par-unit": "Etäisyyden näyttämiseen käytettävä yksikkö.",
+ "maps-finddestination-par-location": "Aloitussijainti.",
+ "maps-finddestination-par-distance": "Kuljettava matka.",
+ "maps-finddestination-par-format": "Kohteen tulostusmuoto",
+ "maps-geocode-par-location": "Geokoodattava osoite.",
+ "maps-geocode-par-format": "Tuloskoordinaattien muoto.",
+ "maps-geocode-par-directional": "Tulostetaanko koordinatit suuntatiedon kanssa vai ei.",
+ "maps-geodistance-par-location1": "Etäisyyden laskemisen ensimmäinen piste.",
+ "maps-geodistance-par-location2": "Etäisyyden laskemisen toinen piste.",
+ "maps-geodistance-par-unit": "Etäisyyden näyttämiseen käytettävä yksikkö.",
+ "maps-geodistance-par-decimals": "Kohdearvon desimaalien enimmäismäärä.",
+ "maps-displaymap-par-mappingservice": "Mahdollistaa kartan tuottavan karttapalvelun määrityksen.",
+ "maps-displaymap-par-coordinates": "Kartalla on yksi tai useampi kohde. Ne osoitetaan kohdemerkillä.",
+ "maps-displaymap-par-zoom": "Mahdollistaa kartan loitonnustason asettamisen.\nJos sitä ei ole asetettu ja kartalla on kohdemerkkejä, loitonnustasoksi valitaan parhaiten sopiva asetusten oletusarvon sijasta.",
+ "maps-displaymap-par-icon": "Mahdollistaa kaikkien kohdemerkkien kuvakkeen asettamisen.",
+ "maps-displaymap-par-circles": "Näytettävät ympyrät",
+ "maps-displaymap-par-lines": "Näytettävät viivat",
+ "maps-displaymap-par-maxzoom": "Suppein loitonnustaso",
+ "maps-displaymap-par-minzoom": "Laajin loitonnustaso",
+ "maps-displaymap-par-polygons": "Näytettävät monikulmiot",
+ "maps-displaymap-par-rectangles": "Näytettävät suorakulmiot",
+ "maps-displaymap-par-static": "Tee kartasta staattinen",
+ "maps-displaymap-par-geojson": "GeoJSON-tiedoston URL-osoite",
+ "maps-fullscreen-button": "Koko näytön tila",
+ "maps-fullscreen-button-tooltip": "Näytä kartta koko näytön tilassa tai upotettuna.",
+ "validation-error-invalid-location": "Parametrin $1 on oltava sallittu sijainti.",
+ "validation-error-invalid-locations": "Parametrin $1 on oltava yksi tai useampi sallittu sijainti.",
+ "validation-error-invalid-width": "Parametrin $1 on oltava sallittu leveys.",
+ "validation-error-invalid-height": "Parametrin $1 on oltava sallittu korkeus.",
+ "validation-error-invalid-distance": "Parametrin $1 on oltava sallittu etäisyys.",
+ "validation-error-invalid-distances": "Parametrin $1 on oltava yksi tai useampi sallittu etäisyys.",
+ "validation-error-invalid-image": "Parametrin $1 on oltava sallittu kuva.",
+ "validation-error-invalid-images": "Parametrin $1 on oltava yksi tai useampi sallittu kuva.",
+ "maps-abb-north": "P",
+ "maps-abb-east": "I",
+ "maps-abb-south": "E",
+ "maps-abb-west": "L",
+ "maps-latitude": "Leveyspiiri",
+ "maps-longitude": "Pituuspiiri",
+ "maps-invalid-coordinates": "Arvoa $1 ei tunnistettu oikeaksi koordinaattisarjaksi.",
+ "maps_coordinates_missing": "Karttaa varten ei tarjottu koordinaatteja.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Seuraavaa osoitetta|Seuraavia osoitteita}} ei voitu geokoodata: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Seuraavaa osoitetta|Seuraavia osoitteita}} ei voitu geokoodata ja {{PLURAL:$2|se|ne}} on jätetty pois kartasta: $1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Seuraavaa koordinaattia|Seuraavia koordinaatteja}} ei tunnistettu: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Seuraavaa koordinaattia|Seuraavia koordinaatteja}} ei tunnistettu ja {{PLURAL:$2|se|ne}} on jätetty pois kartasta:\n$1",
+ "maps_map_cannot_be_displayed": "Karttaa ei voida näyttää.",
+ "maps-geocoder-not-available": "Maps-laajennoksen geokoodausominaisuus ei ole käytössä. Sijaintia ei voitu geokoodata.",
+ "maps_click_to_activate": "Napsauta aktivoidaksesi kartan",
+ "maps_centred_on": "Kartta keskitetty kohtaan $1, $2.",
+ "maps-par-mappingservice": "Mahdollistaa kartan tuottavan karttapalvelun määrityksen.",
+ "maps-par-zoom": "Kartan loitonnustaso. Jos kartalla on kohdemerkkejä, kartta loitonnetaan oletusarvoisesti niin, että kaikki kohdemerkit näkyvät.",
+ "maps-par-width": "Mahdollistaa kartan leveyden asettamisen. Oletusyksikkönä on pikseli, mutta voit erikseen määrittää jonkin seuraavista yksiköistä: px, ex, em, %.",
+ "maps-par-height": "Mahdollistaa kartan korkeuden asettamisen. Oletusyksikkönä on pikseli, mutta voit erikseen määrittää jonkin seuraavista yksiköistä: px, ex, em, %.",
+ "maps-par-centre": "Sijainti, johon kartta keskitetään",
+ "maps-par-enable-fullscreen": "Koko näytön tila -painike",
+ "maps-par-kml": "Kartalle ladattavat KML-tiedostot.",
+ "maps-googlemaps3-incompatbrowser": "Selaimesi ei ole yhteensopiva Google Maps v3:n kanssa.",
+ "maps-googlemaps3-par-type": "Ensimmäiseksi näytettävä karttatyyppi.",
+ "maps-googlemaps3-par-types": "Karttatasovalitsimen käyttämät karttatyypit.",
+ "maps-googlemaps3-par-layers": "Kartalle ladattavat erikoistasot.",
+ "maps-googlemaps3-par-controls": "Kartalle sijoitettavat ohjaimet.",
+ "maps-googlemaps3-par-zoomstyle": "Loitonnusohjaimen tyyli.",
+ "maps-googlemaps3-par-typestyle": "Karttatasovalitsimen tyyli.",
+ "maps-googlemaps3-par-autoinfowindows": "Avaa automaattisesti kaikki tietoikkunat sen jälkeen, kun sivu on ladattu.",
+ "maps-googlemaps3-par-kmlrezoom": "Valitse paras loitonnustaso uudelleen sen jälkeen, kun KML-tasot on ladattu.",
+ "mapeditor": "Kartan muokkausohjelma",
+ "specialpages-group-maps": "Kartat",
+ "mapeditor-parser-error": "Metadatan jäsennys epäonnistui. Käyttäjän antamat tiedot ohitetaan.",
+ "mapeditor-none-text": "Ei mitään",
+ "mapeditor-done-button": "Valmis",
+ "mapeditor-remove-button": "Poista",
+ "mapeditor-import-button2": "Tuo",
+ "mapeditor-export-button": "Vie wikikoodiin",
+ "mapeditor-import-button": "Tuo wikikoodista",
+ "mapeditor-select-button": "Valitse tämä monikulmio",
+ "mapeditor-mapparam-button": "Muokkaa kartan parametreja",
+ "mapeditor-clear-button": "Tyhjennä kartta",
+ "mapeditor-code-title": "Wikikoodi",
+ "mapeditor-import-title": "Tuo wikikoodi",
+ "mapeditor-import-note": "Huomaa, että jäsennin odottaa erittäin täsmällistä wikikoodin muotoa. Kirjoitetun koodin on siksi vastattava vientitoiminnallisuuden tulostamaa koodia.",
+ "mapeditor-form-title": "Muokkaa lisätietoja",
+ "mapeditor-link-title-switcher-popup-text": "Ponnahdusikkuna tekstillä",
+ "mapeditor-link-title-switcher-link-text": "Linkki",
+ "mapeditor-form-field-title": "Otsikko",
+ "mapeditor-form-field-text": "Teksti",
+ "mapeditor-form-field-link": "Linkki",
+ "mapeditor-form-field-icon": "Kuvake",
+ "mapeditor-form-field-group": "Ryhmä",
+ "mapeditor-form-field-fillcolor": "Täyttöväri",
+ "mapeditor-form-field-showonhover": "Näytä työkaluvihjeenä",
+ "mapeditor-mapparam-title": "Kartan parametrien muokkaus",
+ "mapeditor-mapparam-defoption": "-Valitse parametri-",
+ "mapeditor-form-field-image": "Kuva",
+ "semanticmaps-unrecognizeddistance": "Arvoa $1 ei ole sallittu etäisyys.",
+ "semanticmaps-kml-link": "Näytä KLM-tiedosto",
+ "semanticmaps-default-kml-pagelink": "Näytä sivu $1",
+ "semanticmaps-latitude": "Leveyspiiri: $1",
+ "semanticmaps-longitude": "Pituuspiiri: $1",
+ "semanticmaps-altitude": "Korkeus: $1",
+ "semanticmaps-forminput-locations": "Sijainnit",
+ "semanticmaps-par-staticlocations": "Sijaintien luettelo voidaan lisätä karttaan kyselydatan lisäksi. Kuten display_points-parametrissa voit lisätä sijaintikohtaisen otsikon, kuvauksen ja kuvakkeen; erottimena on \"~\".",
+ "semanticmaps-par-showtitle": "Näyttää kohdemerkin tietoikkunan otsikon tai ei. Käytöstä poisto on usein hyödyllistä, jos tietoikkunan sisältö muotoillaan mallineella.",
+ "semanticmaps-par-hidenamespace": "Näytä nimiavaruuden otsikko kohdemerkin tietoikkunassa",
+ "semanticmaps-par-centre": "Kartan keskus. Jos sitä ei määritetä, kartta laskee automaattisesti optimaalisen keskuksen kartalla olevien kohdemerkkien perusteella.",
+ "semanticmaps-par-template": "Tietoikkunan sisällön muotoilussa käytettävä malline.",
+ "semanticmaps-par-geocodecontrol": "Näytä geokoodausohjaimet.",
+ "semanticmaps-kml-text": "Kuhunkin sivuun liittyvä teksti. Jos kyselyllä on lisäominaisuuksia, ne syrjäyttävät tämän.",
+ "semanticmaps-kml-title": "Tulossivun oletusotsikko",
+ "semanticmaps-kml-linkabsolute": "Ovatko linkit absoluuttisia (eivätkä suhteellisia)",
+ "semanticmaps-kml-pagelinktext": "Sivulinkeissä käytettävä teksti, jossa $1 korvataan sivun otsikolla",
+ "semanticmaps-shapes-improperformat": "$1 on muotoiltu väärin. Katso muotoilun dokumentaatiota.",
+ "semanticmaps-shapes-missingshape": "$1: muotoja ei löytynyt. Dokumentaatiossa kerrotaan sallituista muodoista.",
+ "validator-type-mapslocation-list": "Luettelo sijainneista"
+}
diff --git a/www/wiki/extensions/Maps/i18n/fr.json b/www/wiki/extensions/Maps/i18n/fr.json
new file mode 100644
index 00000000..56e5e2bc
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/fr.json
@@ -0,0 +1,243 @@
+{
+ "@metadata": {
+ "authors": [
+ "Brunoperel",
+ "Crochet.david",
+ "DavidL",
+ "Gomoko",
+ "Hashar",
+ "IAlex",
+ "Jean-Frédéric",
+ "McDutchie",
+ "Od1n",
+ "Peter17",
+ "PieRRoMaN",
+ "Sherbrooke",
+ "Verdy p",
+ "Wyz",
+ "Weft",
+ "Jonathan1",
+ "Lbayle",
+ "Yasten",
+ "Trial",
+ "Wladek92",
+ "Urhixidur",
+ "Grondin"
+ ]
+ },
+ "maps-desc": "Permet d’inclure des cartes dynamiques dans les pages du wiki, des adresses géo-codées et d'autres opérations géographiques.",
+ "right-geocode": "Géocode",
+ "action-geocode": "géocoder sur ce wiki",
+ "maps_map": "Carte",
+ "maps-tracking-category": "Pages avec une carte provenant de l’extension Maps",
+ "maps-loading-map": "Chargement de la carte...",
+ "maps-load-failed": "Impossible de charger la carte !",
+ "maps-markers": "Marqueurs",
+ "maps-copycoords-prompt": "CTRL+C, ENTRÉE",
+ "maps-searchmarkers-text": "Marqueurs de filtre",
+ "maps-others": "autres",
+ "maps-kml-parsing-failed": "Échec de l’analyse d’un ou plusieurs fichiers KML, le plus souvent à cause d’échecs de récupération ou de XML mal formé.",
+ "maps-ns-layer": "Couche",
+ "maps-ns-layer-talk": "Page de discussion des couches",
+ "maps-layer-property": "Propriété",
+ "maps-layer-value": "Valeur",
+ "maps-layer-errors": "Erreurs",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Définition non valide|Définitions non valides}}",
+ "maps-layerdef-invalid-fatal": "Définition non valide fatale",
+ "maps-layerdef-wrong-namespace": "Les définitions de couche ne sont valides que sur les pages de l’espace de noms « $1 »",
+ "maps-layerdef-equal-layer-name": "Les noms de couche doivent être uniques dans la même page de couche. « $1 » est déjà utilisé par une autre couche.",
+ "maps-layerpage-usage": "Pages avec des cartes utilisant la couche « $1 »",
+ "maps-layerpage-nousage": "Aucune page n’utilise cette couche pour l’instant.",
+ "maps-error-invalid-layertype": "Il n’y a pas de couche de type « $1 ». Seul {{PLURAL:$3|ce type est|ces types sont}} pris en charge : $2",
+ "maps-error-no-layertype": "Vous devez spécifier le type de couche. {{PLURAL:$2|Seul ce type est|Ces types sont}} pris en charge : $1",
+ "validation-error-invalid-layer": "Le paramètre $1 doit être une couche valide.",
+ "validation-error-invalid-layers": "Le paramètre $1 doit être une ou plusieurs couche(s) valide(s).",
+ "validation-error-no-non-numeric": "Le paramètre « $1 » doit être une chaîne non numérique.",
+ "validation-error-no-non-numerics": "Le paramètre « $1 » doit être une ou plusieurs chaînes non numériques.",
+ "maps-layer-of-type": "Couche de type « $1 »",
+ "maps-layer-of-type-and-name": "Couche « $2 » de type « $1 »",
+ "maps-layer-type-supported-by": "Ce type de couche peut {{PLURAL:$2|être utilisé uniquement avec le service de cartographie $1|être utilisé avec les services de cartographie suivants : $1}}.",
+ "maps-coordinates-description": "Crochet de l’analyseur syntaxique pour formater les coordonnées, depuis et vers n’importe quel format pris en charge.",
+ "maps-displaymap-description": "Affiche les cartes géographiques sans aucun marqueur wiki associé.",
+ "maps-distance-description": "Convertit une distance d'une certaine unité prise en charge à son équivalent utilisant une autre unité.",
+ "maps-finddestination-description": "Trouver une destination à partir d'un point de départ donné (qui peut être dans n’importe lequel des formats pris en charge), d'une orientation initiale et d'une distance.",
+ "maps-geocode-description": "Permet le géocodage d'adresses, en d'autres termes, la transformation des positions humainement lisible en ensembles de coordonnées. Plusieurs services de géocodage sont pris en charge, qui ne doivent pas être confondus avec les services de cartographie.",
+ "maps-geodistance-description": "Calculer la distance géographique entre deux points, depuis et vers n'importe quel format pris en charge.",
+ "maps-mapsdoc-description": "Affiche une table avec les paramètres pour un service de cartographie spécifié, avec leurs valeurs par défaut et leur description.",
+ "maps-layerdefinition-description": "Décrit une couche personnalisée qui peut être affichée avec d’autres fonctions de carte.",
+ "maps-mapsdoc-par-service": "Le service de cartographie pour afficher la documentation concernant les paramètres.",
+ "maps-mapsdoc-par-language": "La langue dans laquelle afficher la documentation. Si aucune traduction n'est disponible, l'anglais sera utilisé à la place.",
+ "maps-coordinates-par-location": "Les coordonnées que vous souhaitez formater.",
+ "maps-coordinates-par-format": "Le format cible pour les coordonnées.",
+ "maps-coordinates-par-directional": "Indique si les coordonnées doivent être imprimées directionnellement ou non.",
+ "maps-par-scrollwheelzoom": "Indique si le défilement à la souris doit être ou non activé.",
+ "maps-distance-par-distance": "La distance à convertir dans son équivalent avec une unité spécifiée.",
+ "maps-distance-par-decimals": "Le nombre maximal de chiffres après la virgule à utiliser dans le résultat.",
+ "maps-distance-par-unit": "L'unité utilisée pour afficher la distance.",
+ "maps-finddestination-par-location": "L'emplacement initial.",
+ "maps-finddestination-par-bearing": "La direction initiale.",
+ "maps-finddestination-par-distance": "La distance à parcourir.",
+ "maps-finddestination-par-format": "Le format dans lequel afficher la destination.",
+ "maps-finddestination-par-directional": "Indique si le format de destination doit être directionnel ou non.",
+ "maps-geocode-par-location": "L'adresse que vous souhaitez géocoder.",
+ "maps-geocode-par-format": "Le format des coordonnées qui en résultent.",
+ "maps-geocode-par-directional": "Indique si les coordonnées doivent être imprimées directionnellement ou non.",
+ "maps-geodistance-par-location1": "Le premier point dans le jeu pour à utiliser pour calculer la distance.",
+ "maps-geodistance-par-location2": "Le deuxième point dans le jeu pour à utiliser pour calculer la distance.",
+ "maps-geodistance-par-unit": "L'unité utilisée pour afficher la distance.",
+ "maps-geodistance-par-decimals": "Le nombre maximal de chiffres après la virgule à utiliser dans le résultat.",
+ "maps-displaymap-par-mappingservice": "Permet de définir le service de cartographie qui sera utilisé pour générer la carte.",
+ "maps-displaymap-par-coordinates": "Un ou plusieurs emplacements à afficher sur la carte. Ils seront représentés par un indicateur.",
+ "maps-displaymap-par-visitedicon": "Le nom de fichier d’une image à utiliser comme icône de marquage une fois que les marqueurs d’origine auront été cliqués",
+ "maps-displaymap-par-zoom": "Permet de définir le niveau de zoom de la carte.\nLorsqu'il n'est pas fourni et que plusieurs marqueurs sont présents sur la carte, le meilleur zoom sera pris, mais non pas la valeur par défaut configurable.",
+ "maps-displaymap-par-centre": "Permet de définir les coordonnées du centre de la carte pour display_point(s).\nAccepte les adresses et les coordonnées.\nLorsque cette propriété n'est pas fournie, la carte se recentre sur le marqueur fourni, ou entre les marqueurs fournis.",
+ "maps-displaymap-par-title": "Permet de définir le texte qui sera affiché dans les pop-ups de tous les marqueurs qui ne disposent pas d'un titre spécifique.\nLorsqu'il est utilisé avec le label, le titre sera en gras et souligné.",
+ "maps-displaymap-par-label": "Permet de définir le texte qui sera affiché dans les fenêtres surgissantes de tous les marqueurs qui n'ont pas d'étiquette spécifique.",
+ "maps-displaymap-par-icon": "Permet de définir l'icône utilisée pour tous les marqueurs.",
+ "maps-displaymap-par-circles": "Cercles à afficher",
+ "maps-displaymap-par-copycoords": "Afficher une boîte de dialogue lors du clic sur un emplacement depuis lequel ses coordonnées peuvent être copiées.",
+ "maps-displaymap-par-lines": "Lignes à afficher",
+ "maps-displaymap-par-maxzoom": "Le niveau maximal de grossissement",
+ "maps-displaymap-par-minzoom": "Le niveau minimal de grossissement",
+ "maps-displaymap-par-polygons": "Polygones à afficher",
+ "maps-displaymap-par-rectangles": "Rectangles à afficher",
+ "maps-displaymap-par-static": "Rendre la carte statique",
+ "maps-displaymap-par-wmsoverlay": "Utiliser une superposition WMS",
+ "maps-displaymap-par-geojson": "URL de fichier ou nom de page contenant des données GeoJSON",
+ "maps-fullscreen-button": "Basculer en plein écran",
+ "maps-fullscreen-button-tooltip": "Visualiser la carte en plein écran ou incorporé.",
+ "validation-error-invalid-location": "Le paramètre « $1 » doit être un emplacement valide.",
+ "validation-error-invalid-locations": "Le paramètre « $1 » doit être un ou plusieurs emplacement(s) valide(s).",
+ "validation-error-invalid-width": "Le paramètre « $1 » doit être une largeur valide.",
+ "validation-error-invalid-height": "Le paramètre « $1 » doit être une hauteur valide.",
+ "validation-error-invalid-distance": "Le paramètre « $1 » doit être une distance valide.",
+ "validation-error-invalid-distances": "Le paramètre « $1 » doit être une ou plusieurs distance(s) valide(s).",
+ "validation-error-invalid-image": "Le paramètre « $1 » doit être une image valide.",
+ "validation-error-invalid-images": "Le paramètre « $1 » doit être une ou plusieurs image(s) valide(s).",
+ "validation-error-invalid-goverlay": "Le paramètre « $1 » doit être un recouvrement valide.",
+ "validation-error-invalid-goverlays": "Le paramètre « $1 » doit être un ou plusieurs recouvrement(s) valide(s).",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitude :",
+ "maps-longitude": "Longitude :",
+ "maps-invalid-coordinates": "La valeur $1 n'a pas été reconnue comme un ensemble valide de coordonnées.",
+ "maps_coordinates_missing": "Aucune coordonnée n'a été fournie pour le plan.",
+ "maps_geocoding_failed": "{{PLURAL:$2|L′adresse suivante n'as pu être géocodée|Les adresses suivantes n'ont pas pu être géocodées}} : $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|L′adresse suivante n’as pu être géocodée|Les adresses suivantes n’ont pas pu être géocodées}} et {{PLURAL:$2|n’est pas affichée|ne sont pas affichées}} sur le plan : \n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|La coordonnée suivante n'a pas été reconnue|Les coordonnées suivantes n'ont pas été reconnues}} : $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|La coordonnée suivante n'a pas été reconnue|Les coordonnées suivantes n'ont pas été reconnues}} et {{PLURAL:$2|a été omise|ont été omises}} sur la carte :\n$1",
+ "maps_map_cannot_be_displayed": "La carte ne peut pas être affichée.",
+ "maps-geocoder-not-available": "La fonctionnalité géocodage des cartes n'est pas disponible. Votre emplacement ne peut être géocodé.",
+ "maps_leaflet": "Dépliant",
+ "maps-leaflet-par-defzoom": "Permet de définir le niveau de zoom par défaut de la carte.",
+ "maps-leaflet-par-layers": "Les couches qui seront disponibles dans le sélecteur de couche. La première est celle qui sera affichée pendant le chargement de la carte.",
+ "maps-leaflet-par-overlaylayers": "Les surcouches qui seront affichées pendant que la carte se charge.",
+ "maps-leaflet-par-maxclusterradius": "Rayon maximal qu'un agrégat peut couvrir en partant du marqueur central (en pixels).",
+ "maps-leaflet-par-clusterspiderfy": "Lorsque vous cliquez sur un cluster à bas niveau de zoom nous l'explicitons afin que vous puissiez voir l'ensemble de ses marqueurs.",
+ "maps_click_to_activate": "Cliquer pour activer la carte",
+ "maps_centred_on": "Carte centrée sur $1, $2.",
+ "maps-par-mappingservice": "Permet de régler le service de cartographie qui sera utilisé pour générer la carte.",
+ "maps-par-resizable": "Rendre la carte redimensionnable en faisant glisser son coin inférieur droit.",
+ "maps-par-searchmarkers": "Permet de rechercher des marqueurs spécifiques via un champ inclus dans la carte.",
+ "maps-par-zoom": "Le niveau de zoom de la carte. Pour les cartes avec des marqueurs, ceci positionne la valeur par défaut du plus grand zoom qui montre encore tous les marqueurs.",
+ "maps-par-width": "Permet de définir la largeur de la carte. Par défaut les pixels seront considérés comme unité, mais vous pouvez spécifier explicitement une de ces unités : px, ex, em, %.",
+ "maps-par-height": "Permet de définir la hauteur de la carte. Par défaut les pixels seront considérés comme unité, mais vous pouvez spécifier explicitement une de ces unités : px, ex, em, %.",
+ "maps-par-centre": "Le lieu sur lequel la carte devra être centrée",
+ "maps-par-enable-fullscreen": "Activer le bouton plein écran",
+ "maps-par-kml": "Fichiers KML à charger sur la carte.",
+ "maps-par-markercluster": "Autoriser la fusion de plusieurs repères à proximité en un seul repère",
+ "maps-googlemaps3-incompatbrowser": "Votre navigateur n'est pas compatible avec Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Permet d'ajouter une image à l'emplacement indiqué sur la carte.",
+ "maps-googlemaps3-par-type": "Le type de carte à afficher initialement.",
+ "maps-googlemaps3-par-types": "Les types de carte qui seront disponibles via le contrôle de type.",
+ "maps-googlemaps3-par-layers": "Couches spéciales à charger sur la carte.",
+ "maps-googlemaps3-par-controls": "Les contrôles à placer sur la carte.",
+ "maps-googlemaps3-par-zoomstyle": "Style du contrôle de zoom.",
+ "maps-googlemaps3-par-typestyle": "Style du contrôle de type.",
+ "maps-googlemaps3-par-autoinfowindows": "Ouvrir automatiquement toutes les fenêtres d'information après le chargement de la page.",
+ "maps-googlemaps3-par-gkml": "Les fichiers KML hébergés par Google à charger sur la carte.",
+ "maps-googlemaps3-par-kmlrezoom": "Zoomer de nouveau la carte une fois que les couches KML ont été chargées.",
+ "maps-googlemaps3-par-poi": "Afficher les points d’intérêt.",
+ "maps-googlemaps3-par-clustergridsize": "La taille de la grille (en pixels) d'un agrégat.",
+ "maps-par-clustermaxzoom": "Niveau maximal de zoom pour lequel des agrégats peuvent exister.",
+ "maps-par-clusterzoomonclick": "Si le comportement par défaut de cliquer sur un agrégat est de zoomer.",
+ "maps-par-maxclusterradius": "Le rayon maximal que ce groupe couvrira.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Si le centre de chaque groupe est le barycentre des marqueurs de l'agrégat.",
+ "maps-googlemaps3-par-clusterminsize": "Le nombre minimum de marqueurs dans un agrégat avant que les marqueurs ne soient cachés et qu'un compteur ne les remplace.",
+ "mapeditor": "Éditeur de carte",
+ "specialpages-group-maps": "Cartes",
+ "mapeditor-parser-error": "Une erreur s'est produite lors de l'analyse des métadonnées. Entrées de l'utilisateur ignorées.",
+ "mapeditor-none-text": "Aucun",
+ "mapeditor-done-button": "Fait",
+ "mapeditor-remove-button": "Supprimer",
+ "mapeditor-import-button2": "Importer",
+ "mapeditor-export-button": "Exporter en code wiki",
+ "mapeditor-import-button": "Importer à partir de code wiki",
+ "mapeditor-select-button": "Sélectionner ce polygone",
+ "mapeditor-mapparam-button": "Modifier les paramètres de la carte",
+ "mapeditor-clear-button": "Effacer la carte",
+ "mapeditor-code-title": "Code wiki",
+ "mapeditor-import-title": "Importer le code wiki",
+ "mapeditor-import-note": "Veuillez noter que l'analyseur syntaxique s'attend à un format très strict sur le code wiki. Le code saisi ici doit correspondre au code généré par la fonctionnalité d'exportation.",
+ "mapeditor-form-title": "Modifier les détails",
+ "mapeditor-link-title-switcher-popup-text": "Popup avec texte",
+ "mapeditor-link-title-switcher-link-text": "Lien",
+ "mapeditor-form-field-title": "Titre",
+ "mapeditor-form-field-text": "Texte",
+ "mapeditor-form-field-link": "Lien",
+ "mapeditor-form-field-icon": "Icône",
+ "mapeditor-form-field-group": "Groupe",
+ "mapeditor-form-field-inlinelabel": "Étiquette en ligne",
+ "mapeditor-form-field-strokecolor": "Couleur de trait",
+ "mapeditor-form-field-strokeopacity": "Opacité du trait",
+ "mapeditor-form-field-strokeweight": "Poids du trait",
+ "mapeditor-form-field-fillcolor": "Couleur de remplissage",
+ "mapeditor-form-field-fillopcaity": "Opacité de remplissage",
+ "mapeditor-form-field-showonhover": "Montrer seulement au survol",
+ "mapeditor-mapparam-title": "Modifier les paramètres de la carte",
+ "mapeditor-mapparam-defoption": "-Sélectionnez un paramètre-",
+ "mapeditor-imageoverlay-button": "Ajouter la couverture d'image",
+ "mapeditor-form-field-image": "Image",
+ "mapeditor-imageoverlay-title": "Détails de la couverture d'image",
+ "mapeditor-form-field-visitedicon": "Icône visitée",
+ "semanticmaps-unrecognizeddistance": "La valeur $1 n'est pas une distance valide.",
+ "semanticmaps-kml-link": "Voir le fichier KML",
+ "semanticmaps-default-kml-pagelink": "Voir l’article $1",
+ "semanticmaps-latitude": "Latitude : $1",
+ "semanticmaps-longitude": "Longitude : $1",
+ "semanticmaps-altitude": "Altitude : $1",
+ "semanticmaps-forminput-locations": "Emplacements",
+ "semanticmaps-par-staticlocations": "Une liste des endroits à ajouter à la carte avec les données demandées. Comme avec display_points, vous pouvez ajouter un titre, une description et une icône par emplacement en utilisant le tilde « ~ » comme séparateur.",
+ "semanticmaps-par-showtitle": "Afficher un titre dans la fenêtre d'informations des marqueurs ou non. La désactivation de ceci est souvent utile lorsque vous utilisez un modèle pour formater le contenu de la fenêtre d'informations.",
+ "semanticmaps-par-hidenamespace": "Afficher le titre de l’espace de noms dans la fenêtre d’information du marqueur",
+ "semanticmaps-par-centre": "Le centre de la carte. Lorsqu'il n'est pas fourni, la carte va choisir automatiquement le centre optimal pour afficher tous les marqueurs sur la carte.",
+ "semanticmaps-par-template": "Un modèle à utiliser pour mettre en forme le contenu de la fenêtre d'informations.",
+ "semanticmaps-par-geocodecontrol": "Afficher le contrôle de géocodage.",
+ "semanticmaps-par-activeicon": "Icône à afficher à la place du marqueur par défaut, quand la page active est égale au résultat de la recherche",
+ "semanticmaps-par-pagelabel": "Quand il vaut « oui », tous les marqueurs auront un « inlineLabel » avec un lien vers la page contenant les coordonnées du marqueur",
+ "semanticmaps-par-ajaxcoordproperty": "Nom de la propriété de coordonnées utilisée pour construire la requête Ajax.",
+ "semanticmaps-par-ajaxquery": "Une seconde requête qui est envoyée via Ajax pour récupérer les coordonnées supplémentaires.",
+ "semanticmaps-par-userparam": "Une valeur passée dans chaque appel de modèle, si un modèle est utilisé",
+ "semanticmaps-kml-text": "Le texte associé avec chaque page. Remplacé par des propriétés récupérées supplémentaires s'il y en a.",
+ "semanticmaps-kml-title": "Le titre par défaut pour les résultats",
+ "semanticmaps-kml-linkabsolute": "Si les titres doivent être absolus (au contraire de relatifs)",
+ "semanticmaps-kml-pagelinktext": "Le texte à utiliser pour les liens vers la page, dans lesquels $1 sera remplacé par le titre de la page",
+ "semanticmaps-shapes-improperformat": "Format de $1 incorrect, veuillez vous reporter à la documentation pour le format attendu",
+ "semanticmaps-shapes-missingshape": "Aucune forme trouvée pour $1; veuillez voir dans la documentation les formes disponibles",
+ "validator-type-mapscircle": "Cercle géographique",
+ "validator-type-mapscircle-list": "Liste des cercles",
+ "validator-type-mapsimageoverlay": "Superposition d’image",
+ "validator-type-mapsimageoverlay-list": "Liste des superpositions d’image",
+ "validator-type-mapsline": "Ligne géographique",
+ "validator-type-mapsline-list": "Liste des lignes",
+ "validator-type-mapslocation": "Emplacement géographique",
+ "validator-type-mapslocation-list": "Liste des emplacements",
+ "validator-type-mapsrectangle": "Rectangle géographique",
+ "validator-type-mapsrectangle-list": "Liste des rectangles",
+ "validator-type-mapspolygon": "Polygone géographique",
+ "validator-type-mapspolygon-list": "Liste des polygones géographiques",
+ "validator-type-wmsoverlay": "Surcouche de Service de Carte web",
+ "validator-type-jsonfile": "texte"
+}
diff --git a/www/wiki/extensions/Maps/i18n/frp.json b/www/wiki/extensions/Maps/i18n/frp.json
new file mode 100644
index 00000000..cf05d3a1
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/frp.json
@@ -0,0 +1,84 @@
+{
+ "@metadata": {
+ "authors": [
+ "ChrisPtDe"
+ ]
+ },
+ "right-geocode": "G·eocode",
+ "maps_map": "Mapa",
+ "maps-loading-map": "Chargement de la mapa...",
+ "maps-load-failed": "Empossiblo de chargiér la mapa !",
+ "maps-markers": "Marcors",
+ "maps-copycoords-prompt": "CTRL+C, ENTRÂ",
+ "maps-searchmarkers-text": "Marquiors de filtro",
+ "maps-others": "ôtros",
+ "maps-ns-layer": "Cuche",
+ "maps-ns-layer-talk": "Discussion cuche",
+ "maps-layer-property": "Propriètât",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Èrrors",
+ "validation-error-invalid-layer": "Lo paramètre $1 dêt étre una cuche valida.",
+ "validation-error-invalid-layers": "Lo paramètre $1 dêt étre yona ou ben un mouél de cuches valides.",
+ "maps-layer-of-type": "Cuche de tipo $1",
+ "maps-finddestination-par-location": "Lo premiér emplacement.",
+ "maps-finddestination-par-bearing": "La premiére dirèccion.",
+ "maps-finddestination-par-distance": "La distance a parcorir.",
+ "maps-displaymap-par-circles": "Cèrcllos a fâre vêre",
+ "maps-displaymap-par-lines": "Legnes a fâre vêre",
+ "maps-displaymap-par-maxzoom": "Lo nivél maximon de zoome",
+ "maps-displaymap-par-minzoom": "Lo nivél minimon de zoome",
+ "maps-displaymap-par-polygons": "Poligonos a fâre vêre",
+ "maps-displaymap-par-rectangles": "Rèctangllos a fâre vêre",
+ "maps-displaymap-par-static": "Se la mapa dêt étre statica",
+ "maps-displaymap-par-wmsoverlay": "Empleyér na supèrposicion WMS",
+ "maps-abb-north": "B",
+ "maps-abb-east": "L",
+ "maps-abb-south": "M",
+ "maps-abb-west": "P",
+ "maps-latitude": "Latituda :",
+ "maps-longitude": "Longituda :",
+ "maps_click_to_activate": "Clicâd por activar la mapa",
+ "maps_centred_on": "Mapa centrâ dessus $1, $2.",
+ "maps-googlemaps3-par-poi": "Montrar los pouents d’entèrèt.",
+ "mapeditor": "Changior de mapa",
+ "specialpages-group-maps": "Mapes",
+ "mapeditor-none-text": "Nion",
+ "mapeditor-done-button": "Fêt",
+ "mapeditor-remove-button": "Enlevar",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Èxportar en code vouiqui",
+ "mapeditor-import-button": "Importar dês lo code vouiqui",
+ "mapeditor-select-button": "Chouèsir ceti poligono",
+ "mapeditor-mapparam-button": "Changiér los paramètros de la mapa",
+ "mapeditor-clear-button": "Èfaciér la mapa",
+ "mapeditor-code-title": "Code vouiqui",
+ "mapeditor-import-title": "Importar lo code vouiqui",
+ "mapeditor-form-title": "Changiér los dètalys",
+ "mapeditor-link-title-switcher-popup-text": "Popup avouéc tèxto",
+ "mapeditor-link-title-switcher-link-text": "Lim",
+ "mapeditor-form-field-title": "Titro",
+ "mapeditor-form-field-text": "Tèxto",
+ "mapeditor-form-field-link": "Lim",
+ "mapeditor-form-field-icon": "Icôna",
+ "mapeditor-form-field-group": "Groupo",
+ "mapeditor-form-field-inlinelabel": "Lambél en legne",
+ "mapeditor-form-field-strokecolor": "Color de trèt",
+ "mapeditor-form-field-strokeopacity": "Opacitât du trèt",
+ "mapeditor-form-field-strokeweight": "Pêds du trèt",
+ "mapeditor-form-field-fillcolor": "Color de remplissâjo",
+ "mapeditor-form-field-fillopcaity": "Opacitât de remplissâjo",
+ "mapeditor-form-field-showonhover": "Fâre vêre solament u survôlo",
+ "mapeditor-mapparam-title": "Changiér los paramètros de la mapa",
+ "mapeditor-mapparam-defoption": "-Chouèsésséd un paramètro-",
+ "mapeditor-imageoverlay-button": "Apondre la cuvèrta d’émâge",
+ "mapeditor-form-field-image": "Émâge",
+ "mapeditor-imageoverlay-title": "Dètalys de la cuvèrta d’émâge",
+ "mapeditor-form-field-visitedicon": "Icôna visitâ",
+ "semanticmaps-unrecognizeddistance": "La valor $1 est pas una distance valida.",
+ "semanticmaps-kml-link": "Vêre lo fichiér KML",
+ "semanticmaps-default-kml-pagelink": "Vêre la pâge $1",
+ "semanticmaps-latitude": "Latituda : $1",
+ "semanticmaps-longitude": "Longituda : $1",
+ "semanticmaps-altitude": "Hôtior : $1",
+ "semanticmaps-forminput-locations": "Emplacements"
+}
diff --git a/www/wiki/extensions/Maps/i18n/fur.json b/www/wiki/extensions/Maps/i18n/fur.json
new file mode 100644
index 00000000..7fec1794
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/fur.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Klenje"
+ ]
+ },
+ "maps-desc": "Al furnìs la possibilitât di mostrâ i dâts de coordinadis e lis direzions geocodificadis intune mape ([http://mapping.referata.com/wiki/Maps_examples demo]).\nServizis di mapis disponibii: $1",
+ "maps_map": "Mape",
+ "maps_coordinates_missing": "Nissune coordenade furnide pe mape.",
+ "maps_geocoding_failed": "{{PLURAL:$2|La direzion ca sot no pues jessi geocodificade|Lis direzions ca sot no puedin jessi geocodificadis}}: $1.\nLa mape no pues jessi mostrade.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|La direzion|Lis direzions}} ca sot no {{PLURAL:$2|pues|puedin}} jessi {{PLURAL:$2|geocodificade|geocodificadis}} e {{PLURAL:$2|no je mostrade|no son mostradis}} te mape:\n$1"
+}
diff --git a/www/wiki/extensions/Maps/i18n/fy.json b/www/wiki/extensions/Maps/i18n/fy.json
new file mode 100644
index 00000000..0ac2a2c7
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/fy.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
+ ]
+ },
+ "maps-layer-property": "Eigenskip",
+ "maps-layer-value": "Wearde",
+ "mapeditor-form-field-image": "Ôfbylding"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ga.json b/www/wiki/extensions/Maps/i18n/ga.json
new file mode 100644
index 00000000..c4bf9b08
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ga.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "mapeditor-none-text": "Tada"
+}
diff --git a/www/wiki/extensions/Maps/i18n/gl.json b/www/wiki/extensions/Maps/i18n/gl.json
new file mode 100644
index 00000000..a69ecd90
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/gl.json
@@ -0,0 +1,220 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gallaecio",
+ "Toliño",
+ "Banjo",
+ "Elisardojm",
+ "Navhy"
+ ]
+ },
+ "maps-desc": "Permite incorporar mapas dinámicos, enderezos xeocodificados e outras operacións xeográficas nas páxinas do wiki",
+ "right-geocode": "Xeocodificar",
+ "action-geocode": "xeocodificar neste wiki",
+ "maps_map": "Mapa",
+ "maps-tracking-category": "Páxinas cun mapa renderizado coa extensión Maps",
+ "maps-loading-map": "Cargando o mapa...",
+ "maps-load-failed": "Non se puido cargar o mapa!",
+ "maps-markers": "Marcadores",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Filtrar os marcadores",
+ "maps-others": "outros",
+ "maps-kml-parsing-failed": "Erro ao analizar un ou máis ficheiros KML. Normalmente, isto débese a un erro de recuperación ou a que o XML non ten o formato axeitado.",
+ "maps-ns-layer": "Capa",
+ "maps-ns-layer-talk": "Conversa capa",
+ "maps-layer-property": "Propiedade",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Erros",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definición non válida|Definicións non válidas}}",
+ "maps-layerdef-invalid-fatal": "Definición non válida fatal",
+ "maps-layerdef-wrong-namespace": "As definicións das capas son válidas unicamente nas páxinas do espazo de nomes \"$1\"",
+ "maps-layerdef-equal-layer-name": "Os nomes das capas deben ser únicos dentro da mesma páxina de capa. \"$1\" xa está en uso noutra capa.",
+ "maps-layerpage-usage": "Páxinas con mapas que usan a capa \"$1\"",
+ "maps-layerpage-nousage": "Nestes intres non hai ningunha páxina que use esta capa.",
+ "maps-error-invalid-layertype": "Non existen capas do tipo \"$1\". Só {{PLURAL:$3|está soportado este tipo|están soportados estes tipos}}: $2",
+ "maps-error-no-layertype": "Cómpre especificar o tipo de capa. {{PLURAL:$3|Só está soportado este tipo|Están soportados estes tipos}}: $1",
+ "validation-error-invalid-layer": "O parámetro \"$1\" debe ser unha capa válida.",
+ "validation-error-invalid-layers": "O parámetro \"$1\" debe ser unha ou máis capas válidas.",
+ "validation-error-no-non-numeric": "O parámetro \"$1\" debe ser unha cadea non numérica.",
+ "validation-error-no-non-numerics": "O parámetro \"$1\" debe ser unha ou máis cadeas non numéricas.",
+ "maps-layer-of-type": "Capa de tipo \"$1\"",
+ "maps-layer-of-type-and-name": "Capa \"$2\" de tipo \"$1\"",
+ "maps-layer-type-supported-by": "Este tipo de capa só se pode empregar {{PLURAL:$2|co servizo de mapas $1|con estes servizos de mapas: $1}}.",
+ "maps-coordinates-description": "Asociador do analizador para dar formato ás coordenadas, desde e cara a calquera formato soportado.",
+ "maps-displaymap-description": "Amosar os mapas xeográficos sen marcadores wiki sobre eles.",
+ "maps-distance-description": "Converter unha distancia nunha certa unidade soportada na súa equivalente noutra unidade.",
+ "maps-finddestination-description": "Atopar un destino a partir dun punto de partida (que pode ser en calquera dos formatos soportados), unha orientación inicial e unha distancia.",
+ "maps-geocode-description": "Permite a xeocodificación de enderezos; noutras palabras, transformar as localizacións lexibles por humanos en conxuntos de coordenadas. Hai soporte para diversos servizos de xeocodificación, que non se deben confundir cos servizos de cartografía.",
+ "maps-geodistance-description": "Calcular a distancia xeográfica entre dous puntos, desde e cara a calquera dos formatos soportados.",
+ "maps-mapsdoc-description": "Mostar unha táboa cos parámetros para un servizo de mapas específico, cos seus valores por defecto e as súas descricións.",
+ "maps-layerdefinition-description": "Describe unha capa personalizada que se pode amosar con outras funcións de mapa.",
+ "maps-mapsdoc-par-service": "O servizo de cartografía do que amosar a documentación do parámetro.",
+ "maps-mapsdoc-par-language": "A lingua na que amosar a documentación. Se non houbera tradución dispoñible, amosarase a versión en inglés.",
+ "maps-coordinates-par-location": "As coordenadas ás que quere dar formato.",
+ "maps-coordinates-par-format": "O formato de destino para as coordenadas.",
+ "maps-coordinates-par-directional": "Indica se as coordenadas deben producirse con formato direccional ou non.",
+ "maps-par-scrollwheelzoom": "Indica se debe activarse ou non o escorregamento co rato.",
+ "maps-distance-par-distance": "A distancia a converter na súa equivalente nunha unidade especificada.",
+ "maps-distance-par-decimals": "O número máximo de díxitos fraccionarios a utilizar no valor resultante.",
+ "maps-distance-par-unit": "A unidade na que amosar a distancia.",
+ "maps-finddestination-par-location": "A localización inicial.",
+ "maps-finddestination-par-bearing": "A dirección inicial.",
+ "maps-finddestination-par-distance": "A distancia a percorrer.",
+ "maps-finddestination-par-format": "O formato no que amosar o destino.",
+ "maps-finddestination-par-directional": "Indica se o formato de destino debe producirse con formato direccional ou non.",
+ "maps-geocode-par-location": "O enderezo que quere xeocodificar.",
+ "maps-geocode-par-format": "O formato das coordenadas resultantes.",
+ "maps-geocode-par-directional": "Indica se as coordenadas deben producirse con formato direccional ou non.",
+ "maps-geodistance-par-location1": "O primeiro punto do conxunto para calcular a distancia.",
+ "maps-geodistance-par-location2": "O segundo punto do conxunto para calcular a distancia.",
+ "maps-geodistance-par-unit": "A unidade utilizada para amosar a distancia.",
+ "maps-geodistance-par-decimals": "O número máximo de díxitos fraccionarios a utilizar no valor resultante.",
+ "maps-displaymap-par-mappingservice": "Permite configurar o servizo de mapas que se empregará para xerar o mapa.",
+ "maps-displaymap-par-coordinates": "Unha ou máis localizacións a amosar no mapa. Indicaranse cun marcador.",
+ "maps-displaymap-par-visitedicon": "O nome de ficheiro dunha imaxe a utilizar como iconas de marcador despois de premer nos marcadores orixinais",
+ "maps-displaymap-par-zoom": "Permite configurar o nivel de zoom do mapa.\nSe non se proporciona e hai presentes no mapa múltiples marcadores, tomarase o mellor axuste de zoom e non o valor configurado por defecto.",
+ "maps-displaymap-par-centre": "Permite configurar as coordenadas do centro do mapa para display_point(s).\nAdmite tanto enderezos como coordenadas.\nCando non se indica esa propiedade, o mapa centrarase no marcador proporcionado ou entre os marcadores proporcionados.",
+ "maps-displaymap-par-title": "Permite configurar o texto que aparecerá na ventás emerxentes de todos os marcadores que non teñen un título específico.\nAo empregalo conxuntamente coa etiqueta, o título aparecerá en negra e suliñado.",
+ "maps-displaymap-par-label": "Permite configurar o texto que aparecerá na ventás emerxentes de todos os marcadores que non teñen unha etiqueta específica.",
+ "maps-displaymap-par-icon": "Permite configurar a icona usada para todos os marcadores.",
+ "maps-displaymap-par-circles": "Círculos a amosar",
+ "maps-displaymap-par-copycoords": "Ao premer nunha localización, amosar un cadro de diálogo desde o que poder copiar as coordenadas do lugar",
+ "maps-displaymap-par-lines": "Liñas a amosar",
+ "maps-displaymap-par-maxzoom": "O nivel máximo de zoom",
+ "maps-displaymap-par-minzoom": "O nivel mínimo de zoom",
+ "maps-displaymap-par-polygons": "Polígonos a amosar",
+ "maps-displaymap-par-rectangles": "Rectángulos a amosar",
+ "maps-displaymap-par-static": "Facer estático o mapa",
+ "maps-displaymap-par-wmsoverlay": "Utilizar unha sobreposición WMS",
+ "maps-displaymap-par-geojson": "URL dun ficheiro ou nome da páxina que contén datos GeoJSON",
+ "maps-fullscreen-button": "Activar ou desactivar a pantalla completa",
+ "maps-fullscreen-button-tooltip": "Amosar o mapa en pantalla completa ou incrustado.",
+ "validation-error-invalid-location": "O parámetro \"$1\" debe ser unha localización válida.",
+ "validation-error-invalid-locations": "O parámetro \"$1\" debe ser unha ou máis localizacións válidas.",
+ "validation-error-invalid-width": "O parámetro \"$1\" debe ser un largo válido.",
+ "validation-error-invalid-height": "O parámetro \"$1\" debe ser unha altura válida.",
+ "validation-error-invalid-distance": "O parámetro \"$1\" debe ser unha distancia válida.",
+ "validation-error-invalid-distances": "O parámetro \"$1\" debe ser unha ou máis distancias válidas.",
+ "validation-error-invalid-image": "O parámetro \"$1\" debe ser unha imaxe válida.",
+ "validation-error-invalid-images": "O parámetro \"$1\" debe ser unha ou máis imaxes válidas.",
+ "validation-error-invalid-goverlay": "O parámetro \"$1\" debe ser unha capa de sobreposición válida.",
+ "validation-error-invalid-goverlays": "O parámetro \"$1\" debe ser unha ou máis capas de sobreposición válidas.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "L",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitude:",
+ "maps-longitude": "Lonxitude:",
+ "maps-invalid-coordinates": "O valor $1 non foi recoñecido como un conxunto de coordenadas válido.",
+ "maps_coordinates_missing": "Non se proporcionou ningunha coordenada para o mapa.",
+ "maps_geocoding_failed": "{{PLURAL:$2|O seguinte enderezo non se puido xeocodificar|Os seguintes enderezos non se puideron xeocodificar}}: $1.\nO mapa non se pode amosar.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|O seguinte enderezo non se puido xeocodificar|Os seguintes enderezos non se puideron xeocodificar}} e {{PLURAL:$2|omitiuse|omitíronse}} no mapa: $1.",
+ "maps_unrecognized_coords": "Non se {{PLURAL:$2|recoñeceu a seguinte coordenada|recoñeceron as seguintes coordenadas}}: $1.",
+ "maps_unrecognized_coords_for": "Non se {{PLURAL:$2|recoñeceu a seguinte coordenada|recoñeceron as seguintes coordenadas}} e {{PLURAL:$2|foi omitida|foron omitidas}} do mapa:\n$1",
+ "maps_map_cannot_be_displayed": "O mapa non se pode amosar.",
+ "maps-geocoder-not-available": "A funcionalidade de xeocodificación de mapas non está dispoñible; non se pode xeocodificar a súa situación.",
+ "maps_leaflet": "Folleto",
+ "maps-leaflet-par-defzoom": "Permite definir o nivel de zoom por defecto do mapa.",
+ "maps-leaflet-par-layers": "As capas que estarán dispoñibles no selector de capas. A primeira delas amosarase ó cargarse o mapa.",
+ "maps-leaflet-par-overlaylayers": "As capas de transparencia que se amosarán cando se cargue o mapa.",
+ "maps_click_to_activate": "Prema para activar o mapa",
+ "maps_centred_on": "Mapa centrado en $1, $2.",
+ "maps-par-mappingservice": "Permite configurar o servizo de mapas que se empregará para xerar o mapa.",
+ "maps-par-resizable": "Fai que se poidan alterar as dimensións do mapa, arrastrando o canto inferior dereito.",
+ "maps-par-searchmarkers": "Permite procurar marcadores específicos a través dun campo integrado no mapa.",
+ "maps-par-zoom": "O nivel de zoom no mapa. Para os mapas con marcadores o valor por defecto usará o nivel máximo de zoom que abranga todos os marcadores.",
+ "maps-par-width": "Permite definir o largo do mapa. Por defecto, os píxeles asúmense como unidade, pero tamén pode especificar unha destas unidades: px, ex, em, %.",
+ "maps-par-height": "Permite definir a altura do mapa. Por defecto, os píxeles asúmense como unidade, pero tamén pode especificar unha destas unidades: px, ex, em, %.",
+ "maps-par-centre": "O lugar no que se debe centrar o mapa",
+ "maps-par-enable-fullscreen": "Activar o botón de pantalla completa",
+ "maps-par-kml": "Ficheiros KML que cargar no mapa.",
+ "maps-par-markercluster": "Permite fusionar múltiples marcadores cercanos nun só marcador",
+ "maps-googlemaps3-incompatbrowser": "O seu navegador é compatible co Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Permite engadir unha imaxe a amosar na situación especificada no mapa.",
+ "maps-googlemaps3-par-type": "O tipo de mapa que amosar inicialmente.",
+ "maps-googlemaps3-par-types": "Os tipos de mapas que estarán dispoñibles a través do control de tipos.",
+ "maps-googlemaps3-par-layers": "As capas especiais que cargar no mapa.",
+ "maps-googlemaps3-par-controls": "Os controis que incluír no mapa.",
+ "maps-googlemaps3-par-zoomstyle": "O estilo do control do zoom.",
+ "maps-googlemaps3-par-typestyle": "O estilo do control do tipo.",
+ "maps-googlemaps3-par-autoinfowindows": "Abrir automaticamente todas as ventás de información tras a carga da páxina.",
+ "maps-googlemaps3-par-gkml": "Ficheiros KML aloxados polo Google que cargar no mapa.",
+ "maps-googlemaps3-par-kmlrezoom": "Axustar o nivel de zoom despois da carga das capas KML.",
+ "maps-googlemaps3-par-poi": "Amosar os puntos de interese.",
+ "maps-googlemaps3-par-clustergridsize": "A medida da reixa dun grupo de píxeles.",
+ "maps-googlemaps3-par-clusterminsize": "O número mínimo de marcadores que están nun grupo antes de que se oculten os marcadores e se amose un contador.",
+ "mapeditor": "Editor de mapa",
+ "specialpages-group-maps": "Mapas",
+ "mapeditor-parser-error": "Houbo un erro ao analizar os metadatos. Ignórase a entrada do usuario.",
+ "mapeditor-none-text": "Ningún",
+ "mapeditor-done-button": "Feito",
+ "mapeditor-remove-button": "Eliminar",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Exportar en código wiki",
+ "mapeditor-import-button": "Importar a partir de código wiki",
+ "mapeditor-select-button": "Seleccione este polígono",
+ "mapeditor-mapparam-button": "Editar os parámetros do mapa",
+ "mapeditor-clear-button": "Limpar o mapa",
+ "mapeditor-code-title": "Código wiki",
+ "mapeditor-import-title": "Importar o código wiki",
+ "mapeditor-import-note": "Teña en conta que o analizador agarda un formato moi estrito no código wiki. O código introducido aquí debe coincidir co código producido pola funcionalidade de exportación.",
+ "mapeditor-form-title": "Editar os detalles",
+ "mapeditor-link-title-switcher-popup-text": "Ventá emerxente co texto",
+ "mapeditor-link-title-switcher-link-text": "Ligazón",
+ "mapeditor-form-field-title": "Título",
+ "mapeditor-form-field-text": "Texto",
+ "mapeditor-form-field-link": "Ligazón",
+ "mapeditor-form-field-icon": "Icona",
+ "mapeditor-form-field-group": "Grupo",
+ "mapeditor-form-field-inlinelabel": "Etiqueta en liña",
+ "mapeditor-form-field-strokecolor": "Cor do trazo",
+ "mapeditor-form-field-strokeopacity": "Opacidade do trazo",
+ "mapeditor-form-field-strokeweight": "Grosor do trazo",
+ "mapeditor-form-field-fillcolor": "Cor do recheo",
+ "mapeditor-form-field-fillopcaity": "Opacidade do recheo",
+ "mapeditor-form-field-showonhover": "Amosar unicamente ao pasar o rato por riba",
+ "mapeditor-mapparam-title": "Editar os parámetros do mapa",
+ "mapeditor-mapparam-defoption": "-Seleccione un parámetro-",
+ "mapeditor-imageoverlay-button": "Engadir a sobreposición da imaxe",
+ "mapeditor-form-field-image": "Imaxe",
+ "mapeditor-imageoverlay-title": "Detalles da sobreposición da imaxe",
+ "mapeditor-form-field-visitedicon": "Icona visitada",
+ "semanticmaps-unrecognizeddistance": "O valor $1 non é unha distancia válida.",
+ "semanticmaps-kml-link": "Ollar o ficheiro KML",
+ "semanticmaps-default-kml-pagelink": "Ver a páxina \"$1\"",
+ "semanticmaps-latitude": "Latitude: $1",
+ "semanticmaps-longitude": "Lonxitude: $1",
+ "semanticmaps-altitude": "Altitude: $1",
+ "semanticmaps-forminput-locations": "Localizacións",
+ "semanticmaps-par-staticlocations": "Unha lista de localizacións para engadir ao mapa xunto aos datos consultados. Como con display_points, pode engadir un título, unha descrición e mais unha icona por localización mediante o signo \"~\" como separador.",
+ "semanticmaps-par-showtitle": "Amosar ou non un título na ventá de información do marcador. Frecuentemente, desactivar isto é útil ao utilizar un modelo para dar formato ao contido da ventá de información.",
+ "semanticmaps-par-hidenamespace": "Amosar o título do espazo de nomes na ventá de información do marcador",
+ "semanticmaps-par-centre": "O centro do mapa. Cando non se proporciona, o mapa ha escoller automaticamente o mellor centro para amosar tódolos marcadores no mapa.",
+ "semanticmaps-par-template": "Un modelo a empregar para dar formato ao contido da ventá de información.",
+ "semanticmaps-par-geocodecontrol": "Amosar o control de xeocodificación.",
+ "semanticmaps-par-activeicon": "Icona a amosar no canto do marcador predeterminado, cando a páxina é igual ao resultado da pescuda",
+ "semanticmaps-par-pagelabel": "Ao definirse en \"si\", todos os macadores terán un \"inlineLabel\" cunha ligazón cara á páxina que conten as coordenadas do marcador",
+ "semanticmaps-par-ajaxcoordproperty": "Nome da propiedade de coordenadas usada para construír a consulta Ajax.",
+ "semanticmaps-par-ajaxquery": "Unha segunda consulta que é enviada vía Ajax para recuperar as coordenadas adicionais.",
+ "semanticmaps-par-userparam": "O valor pasado en cada chamada de modelo, se se empregase algún modelo",
+ "semanticmaps-kml-text": "O texto asociado a cada páxina. Substituído polas propiedades pescudadas adicionais, se existen.",
+ "semanticmaps-kml-title": "O título por defecto para os resultados",
+ "semanticmaps-kml-linkabsolute": "Se as ligazóns deberían ser absolutas (contrario a relativas)",
+ "semanticmaps-kml-pagelinktext": "O texto a usar para as ligazóns cara á páxina, nas que \"$1\" será substituído polo título da páxina",
+ "semanticmaps-shapes-improperformat": "Formato incorrecto de \"$1\"; consulte a documentación sobre os formatos",
+ "semanticmaps-shapes-missingshape": "Non se atopou forma ningunha para \"$1\"; consulte a documentación sobre as formas dispoñibles",
+ "validator-type-mapscircle": "Círculo xeográfico",
+ "validator-type-mapscircle-list": "Lista de círculos",
+ "validator-type-mapsimageoverlay": "Superposición de imaxe",
+ "validator-type-mapsimageoverlay-list": "Lista de superposicións de imaxe",
+ "validator-type-mapsline": "Liña xeográfica",
+ "validator-type-mapsline-list": "Lista de liñas",
+ "validator-type-mapslocation": "Localización xeográfica",
+ "validator-type-mapslocation-list": "Lista de localizacións",
+ "validator-type-mapsrectangle": "Rectángulo xeográfico",
+ "validator-type-mapsrectangle-list": "Lista de rectángulos",
+ "validator-type-mapspolygon": "Polígono xeográfico",
+ "validator-type-mapspolygon-list": "Lista dos polígonos xeográficos",
+ "validator-type-wmsoverlay": "Transparencia de Servizo de Mapa web",
+ "validator-type-jsonfile": "texto"
+}
diff --git a/www/wiki/extensions/Maps/i18n/grc.json b/www/wiki/extensions/Maps/i18n/grc.json
new file mode 100644
index 00000000..ba3592a8
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/grc.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "Β",
+ "maps-abb-east": "Α",
+ "maps-abb-south": "Ν",
+ "maps-abb-west": "Δ",
+ "maps-latitude": "Πλάτος γεωγραφικόν:",
+ "maps-longitude": "Μῆκος γεωγραφικόν:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/gsw.json b/www/wiki/extensions/Maps/i18n/gsw.json
new file mode 100644
index 00000000..95bb7c9c
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/gsw.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Als-Holder"
+ ]
+ },
+ "maps-desc": "Ergänzt d Megligkeit Koordinatedate in Charte un Geocodeadrässe aazzeige. Verfiegbari Chartedienscht: $1. [http://www.mediawiki.org/wiki/Extension:Maps Dokumäntation]. [http://mapping.referata.com/wiki/Maps_examples Demo]",
+ "maps_map": "Charte",
+ "maps-loading-map": "Am Lade vu dr Charte ...",
+ "maps-markers": "Markierige",
+ "maps-others": "anderi",
+ "maps-ns-layer": "Ebeni",
+ "maps-ns-layer-talk": "Ebeni Diskussion",
+ "maps-layer-property": "Eigeschaft",
+ "maps-layer-value": "Wärt",
+ "maps-layer-errors": "Fähler",
+ "maps-error-invalid-layertype": "S git kei Ebene vum Typ „$1“. Nume {{PLURAL:$3|dää Typ wird|die Type wäre}} unterstitzt: $2",
+ "maps-error-no-layertype": "Dr Ebenetyp mueß aagee wäre. Nume {{PLURAL:$2|dää Typ wird|die Typen wäre}} unterstitzt: $1",
+ "validation-error-invalid-layer": "Parameter $1 mueß e giltigi Ebeni syy.",
+ "validation-error-invalid-layers": "Parameter $1 mueß ei oder meh giltigi Ebene syy.",
+ "maps-layer-of-type": "Ebeni vum Typ $1",
+ "maps-layer-type-supported-by": "Dää Ebenetyp cha {{PLURAL:$2|nume bim Kartografidienscht $1 brucht wäre|bi däne Kartografidienscht brucht wäre: $1}}.",
+ "validation-error-invalid-location": "Parameter $1 mueß e giltige Standort syy.",
+ "validation-error-invalid-locations": "Parameter $1 mueß ei oder meh giltigi Standort syy.",
+ "validation-error-invalid-width": "Parameter $1 mueß e giltigi Breiti syy.",
+ "validation-error-invalid-height": "Parameter $1 mueß e giltigi Lengi syy.",
+ "validation-error-invalid-distance": "Parameter $1 mueß e giltigi Entfärnig syy.",
+ "validation-error-invalid-distances": "Parameter $1 mueß ei oder meh giltigi Entfärnige syy.",
+ "validation-error-invalid-image": "Parameter $1 mueß e giltig Bild syy.",
+ "validation-error-invalid-images": "Parameter $1 mueß ei oder meh giltigi Bilder syy.",
+ "validation-error-invalid-goverlay": "Parameter $1 mueß e giltigi Iberlagerig syy.",
+ "validation-error-invalid-goverlays": "Parameter $1 mueß ei oder meh giltigi Iberlagerige syy.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Breiti:",
+ "maps-longitude": "Lengi:",
+ "maps-invalid-coordinates": "Dr Wärt $1 isch nit erkännt wore as giltige Satz vu Koordinate.",
+ "maps_coordinates_missing": "S git kei Koordinate fir die Charte.",
+ "maps_geocoding_failed": "Die {{PLURAL:$2|Adräss het|Adräss hän}} nit chenne georeferänziert wäre: $1. D Charte cha nit aazeigt wäre.",
+ "maps_geocoding_failed_for": "Die {{PLURAL:$2|Adräss het|Adrässe hän}} nit chenne georeferänziert wäre un {{PLURAL:$2|isch|sin}} us dr Charte uusegnuu wore: $1",
+ "maps_unrecognized_coords": "Die {{PLURAL:$2|Koordinate isch|Koordinate sin}} nit erkannt wore: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Die Koordinate isch nit erkannt wore un isch|Die Koordinate sin nit erkannt wore un sin}} wäge däm uusegnuu wore us dr Charte:\n$1",
+ "maps_map_cannot_be_displayed": "D Charte cha nit aazeigt wäre.",
+ "maps-geocoder-not-available": "S Geokodierigs-Feature vu däre Charte isch nit verfiegbar, Dyy Ort cha nit geokodiert wäre.",
+ "maps_click_to_activate": "Klick go d Charte aktiviere",
+ "maps_centred_on": "Charte zäntriert uf $1, $2."
+}
diff --git a/www/wiki/extensions/Maps/i18n/he.json b/www/wiki/extensions/Maps/i18n/he.json
new file mode 100644
index 00000000..5f99e108
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/he.json
@@ -0,0 +1,217 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Ex-Diktator",
+ "Rotemliss",
+ "YaronSh",
+ "Yona b",
+ "Yonidebest",
+ "ערן",
+ "תומר ט",
+ "Inkbug",
+ "Macofe",
+ "Guycn2",
+ "המקיסט",
+ "Erelon"
+ ]
+ },
+ "maps-desc": "הוספת האפשרות להטמעת מפות דינמיות אל תוך דפי ויקי, קידוד גאוגרפי של כתובות ופעולות גאוגרפיות אחרות",
+ "right-geocode": "ביצוע קידודים גאוגרפיים",
+ "action-geocode": "לבצע קידודים גאוגרפיים באתר הוויקי הזה",
+ "maps_map": "מפה",
+ "maps-tracking-category": "דפים עם מפה שהוכנה באמצעות הרחבת המפות",
+ "maps-loading-map": "המפה נטענת...",
+ "maps-load-failed": "טעינת המפה לא הצליחה!",
+ "maps-markers": "סמנים",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "סמני מסנן",
+ "maps-others": "אחרים",
+ "maps-kml-parsing-failed": "פענוח קובץ KML אחד או יותר נכשל. בדרך כלל בגלל בעיה באחזור או בגלל XML בלתי־תקין.",
+ "maps-ns-layer": "שכבה",
+ "maps-ns-layer-talk": "שיחת שכבה",
+ "maps-layer-property": "מאפיין",
+ "maps-layer-value": "ערך",
+ "maps-layer-errors": "שגיאות",
+ "maps-layerdef-invalid": "{{PLURAL:$1|הגדרה בלתי־תקינה|הגדרות בלתי־תקינות}}",
+ "maps-layerdef-invalid-fatal": "הגדרה בלתי־תקינה בעליל",
+ "maps-layerdef-wrong-namespace": "הגדרות שכבות תקינות רק בדפים במרחב השם \"$1\"",
+ "maps-layerdef-equal-layer-name": "שמות השכבות צריכים להיות ייחודיים באותו דף שכבה. \"$1\" כבר משמש בשכבה אחרת.",
+ "maps-layerpage-usage": "דפים עם מפות שמשתמשות בשכבה \"$1\".",
+ "maps-layerpage-nousage": "אין דפים שמשתמשות עכשיו בשכבה הזאת.",
+ "maps-error-invalid-layertype": "אין שכבות מסוג \"$1\". רק {{PLURAL:$3|הסוג הזה נתמך|הסוגים האלה נתמכים}}: $2.",
+ "maps-error-no-layertype": "יש להקליד את סוג השכבה. {{PLURAL:$2|רק הסוג הזה נתמך|הסוגים הנתמכים}}: $1",
+ "validation-error-invalid-layer": "הפרמטר $1 צריך להיות שכבה תקינה.",
+ "validation-error-invalid-layers": "הפרמטר $1 צריך להיות שכבה תקינה אחת או יותר.",
+ "validation-error-no-non-numeric": "הפרמטר \"$1\" חייב להיות מחרוזת שאינה מספרית.",
+ "validation-error-no-non-numerics": "הפרמטר \"$1\" צריך להיות מחרוזת בלתי־מספרית אחת או יותר.",
+ "maps-layer-of-type": "שכבה מסוג $1",
+ "maps-layer-of-type-and-name": "שכבה \"$2\" מסוג \"$1\"",
+ "maps-layer-type-supported-by": "השכבה הזאת יכולה לעבוד רק עם {{PLURAL:$2|שירות המפות הבא|שירותי המפות הבאים}}: $1.",
+ "maps-coordinates-description": "מילת הפעלה לעיצוב נקודות ציון, מכל תסדיר נתמך לכל תסדיר נתמך.",
+ "maps-displaymap-description": "להציג מפות גאוגרפיות ללא שום סמנים מוגדרים בוויקי עליהן.",
+ "maps-distance-description": "להמיר את המרחק ביחידות נתמכות מסוימות לערך מתאים ביחידות אחרות.",
+ "maps-finddestination-description": "למצוא את היעד בהינתן נקודת התחלה (שיכולה להיות בכל פורמט), הכיוון הראשוני והמרחק.",
+ "maps-geocode-description": "מפעיל קידוד גאוגרפי של כתובות, במילים אחרות, הופך מיקומים עם שמות שאנשים יכולים לקרוא לערכות של נקודות ציון. יש תמיכה במספר שירותי קידוד גאוגרפי, ואין להתבלבל בינם לבין שירותי מיפוי.",
+ "maps-geodistance-description": "לחשב את המרחק הגאוגרפי בין שתי נקודת, מכל תסדיר נתמך ולכל תסדיר נתמך.",
+ "maps-mapsdoc-description": "להציג עם פרמטרים עבור שירות המיפוי שצוין יחד עם הערכים והתיאורים ההתחלתיים שלהם.",
+ "maps-layerdefinition-description": "מתאר שכבה מותאמת שאפשר להציג באמצעות פונקציות מפה אחרות.",
+ "maps-mapsdoc-par-service": "שירות המיפוי שעבורו יוצג תיעוד פרמטרים.",
+ "maps-mapsdoc-par-language": "השפה שבה יוצג התיעוד. אם אין תרגום זמין, התיעוד יוצג באנגלית.",
+ "maps-coordinates-par-location": "נקודות הציון שברצונך לעצב.",
+ "maps-coordinates-par-format": "תסדיר היעד לנקודות הציון.",
+ "maps-coordinates-par-directional": "מציין האם לפלוט את נקודות הציון באופן כיווני או לא.",
+ "maps-distance-par-distance": "מרחק שיומר לערך המתאים ביחידות המבוקשות.",
+ "maps-distance-par-decimals": "המספר המקסימלי של ספרות אחרי הנקודה בערך של התוצאה.",
+ "maps-distance-par-unit": "באילו יחידות לפלוט את המרחק.",
+ "maps-finddestination-par-location": "המיקום ההתחלתי.",
+ "maps-finddestination-par-bearing": "הכיוון הראשוני.",
+ "maps-finddestination-par-distance": "מרחק הנסיעה.",
+ "maps-finddestination-par-format": "באיזה תסדיר לפלוט את היעד.",
+ "maps-finddestination-par-directional": "האם תבנית היעד צריכה להיות כיוונית או לא.",
+ "maps-geocode-par-location": "הכתובת שאתם רוצים לעשות לה קידוד גאוגרפי.",
+ "maps-geocode-par-format": "תסדיר נקודות הציון הסופיות.",
+ "maps-geocode-par-directional": "האם לפלוט את נקודות הציון באופן כיווני או לא.",
+ "maps-geodistance-par-location1": "הנקודה הראשונה בקבוצה לחישוב מרחק.",
+ "maps-geodistance-par-location2": "הנקודה השנייה בקבוצה לחישוב מרחק.",
+ "maps-geodistance-par-unit": "באילו יחידות לפלוט את המרחק.",
+ "maps-geodistance-par-decimals": "המספר המרבי של ספרות בשבר בתוצאה.",
+ "maps-displaymap-par-mappingservice": "לאפשר להגדיר שירות מיפוי שישמש ליצרת המפה.",
+ "maps-displaymap-par-coordinates": "באיזה מיקום המפה תתמרכז בתחילה.",
+ "maps-displaymap-par-visitedicon": "שם הקובץ של תמונה שתשתמש לסמלי סימון אחרי לחיצה על הסמנים המקוריים",
+ "maps-displaymap-par-zoom": "מאפשר קביעת קמת התקריב של המפה.\nכאשר נתון זה לא מסופק וסמנים שונים נמצאים על המפה, יילקח התקריב המתאים ביותר, לא ברירת המחדל הניתנת להגדרה.",
+ "maps-displaymap-par-centre": "מאפשר קביעת נקודות ציון של מרכז המפה עבור מופעי display_point.\nמקבל כתובות ונקודות ציון.\nכאשר המאפיין הזה לא מצוין, המפה תמרכז את עצמה על הסמן שצוין או בין סמנים שצוינו.",
+ "maps-displaymap-par-title": "מאפשר קביעת טקסט שיוצג בחלונות קופצים על כל הסמנים שאין להם כותרת מוגדרת.\nכאשר נעשה שימוש בזה יחד עם תווית, הכותרת תהיה בולטת ועם קו תחתי.",
+ "maps-displaymap-par-label": "מאפשר להציב מלל שיוצג בכל החלונות הקופצים של כל הסמנים שאין להם תווית מסוימת.",
+ "maps-displaymap-par-icon": "לאפשר להציב סמל לכל הסמנים.",
+ "maps-displaymap-par-circles": "אילו עיגולים להציג",
+ "maps-displaymap-par-copycoords": "להציג תיבת דו־שיח בעת לחיצה על מיקום שממנו אפשר להעתיק את נקודות הציון שלו",
+ "maps-displaymap-par-lines": "כמה קווים להציג",
+ "maps-displaymap-par-maxzoom": "רמת התקריב המרבית",
+ "maps-displaymap-par-minzoom": "רמת התקריב המזערית",
+ "maps-displaymap-par-polygons": "אילו מצולעים להציג",
+ "maps-displaymap-par-rectangles": "אילו מלבנים להציג",
+ "maps-displaymap-par-static": "להפוך את המפה לסטטית",
+ "maps-displaymap-par-wmsoverlay": "להשתמש בשכבת כיסוי WMS",
+ "maps-displaymap-par-geojson": "כתובת URL של קובץ GeoJSON",
+ "maps-fullscreen-button": "להפעיל מסך מלא",
+ "maps-fullscreen-button-tooltip": "להציג את המפה במסך מלא או מוטבעת",
+ "validation-error-invalid-location": "הערך $1 צריך להיות מיקום תקין.",
+ "validation-error-invalid-locations": "הערך $1 צריך להיות מיקום תקין אחד או יותר.",
+ "validation-error-invalid-width": "הערך $1 צריך להיות רוחב תקין.",
+ "validation-error-invalid-height": "הערך $1 צריך להיות גובה תקין.",
+ "validation-error-invalid-distance": "הערך $1 צריך להיות מרחק תקין.",
+ "validation-error-invalid-distances": "הערך $1 צריך להיות מרחק תקין אחד או יותר.",
+ "validation-error-invalid-image": "הערך $1 צריך להיות קובץ תמונה תקין.",
+ "validation-error-invalid-images": "הערך $1 צריך להיות קובץ תמונה תקין אחד או יותר.",
+ "validation-error-invalid-goverlay": "הערך $1 צריך להיות שכבת כיסוי תקינה.",
+ "validation-error-invalid-goverlays": "הערך $1 צריך להיות שכבת כיסוי תקינה אחת או יותר.",
+ "maps-abb-north": "צפ׳",
+ "maps-abb-east": "מז׳",
+ "maps-abb-south": "דר׳",
+ "maps-abb-west": "מע׳",
+ "maps-latitude": "קו רוחב:",
+ "maps-longitude": "קו אורך:",
+ "maps-invalid-coordinates": "הערך $1 לא זוהה כסדרת קואורדינטות תקינה.",
+ "maps_coordinates_missing": "לא סופקו קואורדינטות למפה.",
+ "maps_geocoding_failed": "לא ניתן לייצר geocode עבור {{PLURAL:$2|הכתובת הבאה|הכתובות הבאות}}: $1.\nלא ניתן להציג את המפה.",
+ "maps_geocoding_failed_for": "לא ניתן לייצר geocode עבור {{PLURAL:$2|הכתובת הבאה|הכתובות הבאות}}, ולכן {{PLURAL:$2|היא הושמטה|הן הושמטו}} מהמפה:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|הקואורדינטה הבאה לא זוהתה|הקואורדינטות הבאות לא זוהו}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|נקודת הציון הבאה לא זוהתה והושמטה|נקודות הציון הבאות לא זוהו והושמטו}} מהמפה: $1",
+ "maps_map_cannot_be_displayed": "לא ניתן להציג את המפה.",
+ "maps-geocoder-not-available": "הקידוד הגאוגרפי של מפות אינו זמין. לא ניתן לקודד את המיקום שנבחר.",
+ "maps_leaflet": "עלון",
+ "maps-leaflet-par-defzoom": "מאפשר להגדיר את רמת המרחק ההתחלתית במפה.",
+ "maps_click_to_activate": "יש ללחוץ כדי להפעיל את המפה",
+ "maps_centred_on": "המפה ממורכזת סביב $1,$2",
+ "maps-par-mappingservice": "מאפשר הגדרת שירות המיפוי שישמש לחילול המפה.",
+ "maps-par-resizable": "מאפשר שינוי גודל מפה באמצעות גרירת הפינה שלה.",
+ "maps-par-searchmarkers": "מאפשר חיפוש סמנים מסוימים דרך שדה שמוטמע במפה",
+ "maps-par-zoom": "רמת התקריב של המפה. למפות עם סמנים ברירת המחדל תהיה רמת תקריב גבוהה ביותר שמציגה את כל הסמנים.",
+ "maps-par-width": "לאפשר הגדרת רוחב המפה. ברירת המחדל היא שהיחידה תהיה פיקסל, אבל אפשר להגדיר במפורש אחת מהיחידות הבאות: px, ex, em, %.",
+ "maps-par-height": "לאפשר הגדרת גובה המפה. ברירת המחדל היא שהיחידה תהיה פיקסל, אבל אפשר להגדיר במפורש אחת מהיחידות הבאות: px, ex, em, %.",
+ "maps-par-centre": "המיקום שבו המפה צריכה להיות ממורכזת",
+ "maps-par-enable-fullscreen": "להפעיל כתפור מסך מלא",
+ "maps-par-kml": "קבצי KML שייטענו אל המפה.",
+ "maps-par-markercluster": "מאפשר מיזוג מספר סמנים קרובים לסמן אחד",
+ "maps-googlemaps3-incompatbrowser": "הדפדפן שלך לא תומך בגוגל מפות גרסה 3.",
+ "maps-googlemaps3-par-imageoverlays": "מאפשר הוספת תמונה שתוצג במיקום מסוים על המפה.",
+ "maps-googlemaps3-par-type": "סוג המפה שיוצג תחילה.",
+ "maps-googlemaps3-par-types": "סוגי המפה שיהיו זמינים דרך בקר הסוג.",
+ "maps-googlemaps3-par-layers": "שכבות מיוחדות שייטענו אל המפה.",
+ "maps-googlemaps3-par-controls": "אילו בקרים להציב על המפה.",
+ "maps-googlemaps3-par-zoomstyle": "סגנון בקר התקריב.",
+ "maps-googlemaps3-par-typestyle": "סגנון בקר הסוג.",
+ "maps-googlemaps3-par-autoinfowindows": "לפתוח את כל חלונות המידע אחרי שהדף נטען.",
+ "maps-googlemaps3-par-gkml": "קבצי KML שמתארחים בגוגל וייטענו אל המפה.",
+ "maps-googlemaps3-par-kmlrezoom": "לקרב מחדש את המפה אחרי ששכבות KML נטענו.",
+ "maps-googlemaps3-par-poi": "הצגת נקודות עניין.",
+ "maps-googlemaps3-par-clustergridsize": "גודל הרשת של האשכול בפיקסלים.",
+ "maps-par-clusterzoomonclick": "האם ההתנהגות הראשונית ללחיצה על אשכולית היא להתקרב לתוכו.",
+ "maps-googlemaps3-par-clusteraveragecenter": "האם המרכז של כל אשכול אמור להיות הממוצע של כל הסמנים באשכול.",
+ "maps-googlemaps3-par-clusterminsize": "המספר המזערי של הסמנים שאמורים להיות באשכול לפני שהסמנים מוסתרים ומוצג מונה.",
+ "mapeditor": "עורך מפות",
+ "specialpages-group-maps": "מפות",
+ "mapeditor-parser-error": "אירעה שגיאה בעת עיבוד מטא־נתונים. קלט ממשתמשים לא יעובד.",
+ "mapeditor-none-text": "אין",
+ "mapeditor-done-button": "בוצע",
+ "mapeditor-remove-button": "הסרה",
+ "mapeditor-import-button2": "ייבוא",
+ "mapeditor-export-button": "ייצוא לקוד ויקי",
+ "mapeditor-import-button": "ייבוא מקוד ויקי",
+ "mapeditor-select-button": "לבחור את המצולע הזה",
+ "mapeditor-mapparam-button": "עריכת הפרמטרים של המפה",
+ "mapeditor-clear-button": "ניקוי מפה",
+ "mapeditor-code-title": "קוד ויקי",
+ "mapeditor-import-title": "ייבוא קוד ויקי",
+ "mapeditor-import-note": "נא לשים לב לכך שהמפענח מצפה לקוד ויקי בתסדיר נוקשה מאוד. הקוד שמוזן כאן צריך להתאים לקוד המיוצא.",
+ "mapeditor-form-title": "עריכת פרטים",
+ "mapeditor-link-title-switcher-popup-text": "חלון קופץ עם טקסט",
+ "mapeditor-link-title-switcher-link-text": "קישור",
+ "mapeditor-form-field-title": "כותרת",
+ "mapeditor-form-field-text": "טקסט",
+ "mapeditor-form-field-link": "קישור",
+ "mapeditor-form-field-icon": "אייקון",
+ "mapeditor-form-field-group": "קבוצה",
+ "mapeditor-form-field-inlinelabel": "תווית פנימית",
+ "mapeditor-form-field-strokecolor": "צבע קו",
+ "mapeditor-form-field-strokeopacity": "אטימות קו",
+ "mapeditor-form-field-strokeweight": "עובי קו",
+ "mapeditor-form-field-fillcolor": "צבע מילוי",
+ "mapeditor-form-field-fillopcaity": "שקיפות מילוי:",
+ "mapeditor-form-field-showonhover": "להציג רק במעבר סמן",
+ "mapeditor-mapparam-title": "עריכת הפרמטרים של המפה",
+ "mapeditor-mapparam-defoption": "-בחירת פרמטר-",
+ "mapeditor-imageoverlay-button": "הוספת שכבת תמונה",
+ "mapeditor-form-field-image": "תמונה",
+ "mapeditor-imageoverlay-title": "פרטי שכבת תמונה",
+ "mapeditor-form-field-visitedicon": "סמל לסימון מקומות שביקרת בהם",
+ "semanticmaps-unrecognizeddistance": "הערך $1 אינו מרחק תקין.",
+ "semanticmaps-kml-link": "הצגת קובץ KML",
+ "semanticmaps-default-kml-pagelink": "הצגת הדף $1",
+ "semanticmaps-latitude": "קו־רוחב: $1",
+ "semanticmaps-longitude": "קו־אורך: $1",
+ "semanticmaps-altitude": "גובה: $1",
+ "semanticmaps-forminput-locations": "מיקומים",
+ "semanticmaps-par-staticlocations": "רשימת מיקומים להוסיף למפה יחד עם הנתונים המבוקשים בשאילתה. כמו עם display_points, אפשר להוסיף כאן כותרת, תיאור וסמל לכל מיקום עם טילדה (~) בתור תו מפריד.",
+ "semanticmaps-par-showtitle": "להציג את הכותרת בחלון המידע על הסמן או לא. הכיבוי של זה שימושי לעתים קרובות כאשר נעשה שימוש בתבנית לעיצוב חלון המידע.",
+ "semanticmaps-par-hidenamespace": "האם להציג את שם המרחב בחלון המידע על סמן.",
+ "semanticmaps-par-centre": "מרכז המפה. אם לא ניתן, המפה תבחר בעצמה את המרכז המיטבי להצגת כל הסמנים על המפה.",
+ "semanticmaps-par-template": "תבנית לעיצוב תוכן חלון המידע.",
+ "semanticmaps-par-geocodecontrol": "הצגת בקר קידוד גאוגרפי.",
+ "semanticmaps-par-activeicon": "סמל שיוצג במקום הסמן הרגיל כאשר הדף הפעיל זהה לתוצאת השאילתה",
+ "semanticmaps-par-pagelabel": "כשזה מכון ל־\"yes\", לכל הסמנים יהיה \"inlineLabel\" עם קישור לדף שמכיל את נקודות הציון עבור הסמן",
+ "semanticmaps-par-ajaxcoordproperty": "שם המאפיין של נקודות הציון שמשמש לבניית שאילתת ה־ajax.",
+ "semanticmaps-par-ajaxquery": "שאילתה שנייה שנשלחת ב־ajax כדי לאחזר נקודות ציון נוספות.",
+ "semanticmaps-par-userparam": "ערך שמועבר לכל קריאה לתבנית, אם משמשת תבנית",
+ "semanticmaps-kml-text": "הטקסט משויך לכל עמוד ועמוד. נדרס במאפיינים אחרים שנעשית עליהם שאילתה, אם יש כאלה.",
+ "semanticmaps-kml-title": "כותרת לתוצאות לפי בררת המחדל.",
+ "semanticmaps-kml-linkabsolute": "האם הקישורים צריכים להיות מוחלטים (או יחסיים)",
+ "semanticmaps-kml-pagelinktext": "הטקסט שישמש לקישורים לדף, כאשר $1 יוחלף בכותרת הדף",
+ "semanticmaps-shapes-improperformat": "עיצוב לא מתאים עבור $1. נא לראות את התיעוד על עיצוב",
+ "semanticmaps-shapes-missingshape": "לא נמצאו צורות עבור $1. נא לראות את התיעוד עבור צורות",
+ "validator-type-mapscircle-list": "רשימת מעגלים",
+ "validator-type-mapsline-list": "רשימת קווים",
+ "validator-type-mapsrectangle-list": "רשימה של משולשים",
+ "validator-type-jsonfile": "טקסט"
+}
diff --git a/www/wiki/extensions/Maps/i18n/hi.json b/www/wiki/extensions/Maps/i18n/hi.json
new file mode 100644
index 00000000..e87d5c30
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/hi.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ansumang",
+ "Siddhartha Ghai",
+ "Sfic"
+ ]
+ },
+ "maps_map": "मानचित्र",
+ "maps-ns-layer": "परत",
+ "maps-layer-errors": "त्रुटि",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "अक्षांश:",
+ "maps-longitude": "रेखांश:",
+ "specialpages-group-maps": "मानचित्र",
+ "mapeditor-none-text": "कोई नहीं",
+ "mapeditor-remove-button": "निकालें",
+ "mapeditor-import-button2": "आयात करें",
+ "mapeditor-form-field-title": "शीर्षक",
+ "mapeditor-form-field-text": "पाठ",
+ "mapeditor-form-field-icon": "आइकन",
+ "mapeditor-form-field-image": "छवि"
+}
diff --git a/www/wiki/extensions/Maps/i18n/hr.json b/www/wiki/extensions/Maps/i18n/hr.json
new file mode 100644
index 00000000..7b10792c
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/hr.json
@@ -0,0 +1,92 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ex13",
+ "Bugoslav",
+ "Tivek"
+ ]
+ },
+ "maps-desc": "Omogućava uključivanje dinamičkih zemljovida u wikistranice, geokodiranje adresa i druge zemljopisne operacije",
+ "right-geocode": "Geokodiranje",
+ "action-geocode": "izvršavanje geokodiranja na ovom wikiju",
+ "maps_map": "Zemljovid",
+ "maps-tracking-category": "Stranica sa zemljovidom iscrtanim pomoću proširenja Zemljovidi (''Maps'')",
+ "maps-loading-map": "Učitavam zemljovid...",
+ "maps-load-failed": "Zemljovid nije bilo moguće učitati!",
+ "maps-markers": "Označivači",
+ "maps-copycoords-prompt": "Pritisnite CTRL+C, pa ENTER",
+ "maps-searchmarkers-text": "Filtriranje označivača",
+ "maps-others": "ostali",
+ "maps-ns-layer": "Sloj",
+ "maps-ns-layer-talk": "Razgovor o sloju",
+ "maps-layer-property": "Svojstvo",
+ "maps-layer-value": "Vrijednost",
+ "maps-layer-errors": "Pogrješke",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Nevrijedeća definicija|Nevrijedeće definicije}}",
+ "maps-layerdef-invalid-fatal": "Kobna nevrijedeća definicija",
+ "maps-layerdef-wrong-namespace": "Definicije sloja valjane su samo na stranicama u imenskom prostoru »$1«",
+ "maps-layerpage-usage": "Stranice sa zemljovidima koji koriste sloj »$1«",
+ "maps-layerpage-nousage": "Trenutačno nema stranica koje rabe ovaj sloj.",
+ "maps-layer-type-supported-by": "Ovaj tip sloja može se rabiti {{PLURAL:$2|samo s kartografskom uslugom $1|s ovim kartografskim uslugama: $1}}.",
+ "maps-geodistance-description": "Izračunava zemljopisnu udaljenost između dvije točke, iz i na neki od podržanih formata.",
+ "maps-layerdefinition-description": "Opisuje prilagođeni sloj koji je moguće prikazati s drugim mogućnostima zemljovoda.",
+ "maps-displaymap-par-polygons": "Mnogokuti za prikaz",
+ "maps-displaymap-par-rectangles": "Pravokutnici za prikaz",
+ "maps-displaymap-par-static": "Postavi zemljovid statičnim",
+ "maps-fullscreen-button-tooltip": "Vidi zemljovid preko cijeloga zaslona ili kao umetak.",
+ "maps-abb-north": "S",
+ "maps-abb-east": "I",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Zemljopisna širina:",
+ "maps-longitude": "Zemljopisna dužina:",
+ "maps_coordinates_missing": "Za kartu nisu dostupne koordinate.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Sljedeća adresa ne može biti geokodirana|Sljedeće adrese ne mogu biti geokodirane}}: $1.\nKarta ne može biti prikazana.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Sljedeća adresa ne može biti geokodirana|Sljedeće adrese ne mogu biti geokodirane}} i {{PLURAL:$2|izostavljena je|izostavljene su}} iz karte:\n$1",
+ "maps_map_cannot_be_displayed": "Zemljovid nije moguće prikazati.",
+ "maps-leaflet-par-defzoom": "Dopuštanje postavljanja predodređenoga stupnja povećanja prikaza zemljovida.",
+ "maps_click_to_activate": "Škljocnite za aktivaciju zemljovida.",
+ "maps_centred_on": "Zemljovid je centriran na $1, $2.",
+ "maps-par-centre": "Lokacija na kojoj zemljovid treba centrirati",
+ "maps-par-kml": "KML datoteke za učitavanje na zemljovid.",
+ "maps-googlemaps3-par-type": "Tip zemljovida koji će prvobitno biti pokazan.",
+ "maps-googlemaps3-par-layers": "Posebni slojevi za učitavanje na zemljovid.",
+ "maps-googlemaps3-par-poi": "Pokazuje točke koje Vas zanimaju.",
+ "mapeditor": "Uređivač zemljovida",
+ "specialpages-group-maps": "Zemljovidi",
+ "mapeditor-none-text": "Nema",
+ "mapeditor-done-button": "Gotovo",
+ "mapeditor-remove-button": "Ukloni",
+ "mapeditor-import-button2": "Uvezi",
+ "mapeditor-export-button": "Izvezi u vikikôdu",
+ "mapeditor-import-button": "Uvezi iz wikikôda",
+ "mapeditor-select-button": "Odaberi mnogokut",
+ "mapeditor-mapparam-button": "Uredi parametre zemljovida",
+ "mapeditor-clear-button": "Očisti zemljovid",
+ "mapeditor-code-title": "Wikikôd",
+ "mapeditor-import-title": "Uvoz wikikôda",
+ "mapeditor-form-title": "Uredi pojedinosti",
+ "mapeditor-link-title-switcher-popup-text": "Prozorčić s tekstom",
+ "mapeditor-link-title-switcher-link-text": "Poveznica",
+ "mapeditor-form-field-title": "Naslov",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Poveznica",
+ "mapeditor-form-field-icon": "Ikona",
+ "mapeditor-form-field-group": "Skupina",
+ "mapeditor-mapparam-title": "Uredi parametre zemljovida",
+ "semanticmaps-unrecognizeddistance": "Vrijednost $1 nije valjana udaljenost.",
+ "semanticmaps-latitude": "Zemljopisna širina: $1",
+ "semanticmaps-longitude": "Zemljopisna dužina: $1",
+ "semanticmaps-altitude": "Nadmorska visina: $1",
+ "semanticmaps-forminput-locations": "Lokacije",
+ "semanticmaps-par-centre": "Središte zemljovida. Ako nije zadano, bit će automatski odabrano optimalno središte za prikaz svih oznaka na zemljovidu.",
+ "validator-type-mapscircle": "Zemljopisna kružnica",
+ "validator-type-mapscircle-list": "Popis kružnica",
+ "validator-type-mapsline": "Zemljopisna linija",
+ "validator-type-mapslocation": "Zemljopisna lokacija",
+ "validator-type-mapsrectangle": "Zemljopisni pravokutnik",
+ "validator-type-mapsrectangle-list": "Popis pravokutnika",
+ "validator-type-mapspolygon": "Zemljopisni mnogokut",
+ "validator-type-mapspolygon-list": "Popis zemljopisnih mnogokuta",
+ "validator-type-jsonfile": "tekst"
+}
diff --git a/www/wiki/extensions/Maps/i18n/hsb.json b/www/wiki/extensions/Maps/i18n/hsb.json
new file mode 100644
index 00000000..943696c7
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/hsb.json
@@ -0,0 +1,172 @@
+{
+ "@metadata": {
+ "authors": [
+ "J budissin",
+ "Michawiki",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Zmóžnja zasadźenje dynamiskich kartow do wikistronow, geokodowanje adresow a druhe geografiske podawki",
+ "right-geocode": "Geokodowanje",
+ "maps_map": "Karta",
+ "maps-tracking-category": "Strony z kartu rysowanej přez rozšěrjenje Maps",
+ "maps-loading-map": "Karta so začituje...",
+ "maps-load-failed": "Karta njeda so začitać!",
+ "maps-markers": "Marki",
+ "maps-copycoords-prompt": "STRG+C, ENTER",
+ "maps-searchmarkers-text": "Filtrowy marki",
+ "maps-others": "druhe",
+ "maps-kml-parsing-failed": "Parsowanje jedneje KML-dataje abo wjacorych KML-datajow je so naprašowanskeho zmylka abo zmylneho XML njeporadźiło.",
+ "maps-ns-layer": "Runina",
+ "maps-ns-layer-talk": "Diskusija runiny",
+ "maps-layer-property": "Kajkosć",
+ "maps-layer-value": "Hódnota",
+ "maps-layer-errors": "Zmylki",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Njepłaćiwa definicija|Njepłaćiwej definiciji|Njepłaćiwe definicije}}",
+ "maps-layerdef-invalid-fatal": "Chutna njepłaćiwa definicija",
+ "maps-layerdef-wrong-namespace": "Runinowe definicije su jenož płaćiwe na stronach z mjenowym rumom \"$1\"",
+ "maps-layerpage-usage": "Strony z kartami, kotrež runinu \"$1\" wužiwaja",
+ "maps-layerpage-nousage": "We wokomiku žane strony tutu runinu njewužiwaja.",
+ "maps-error-invalid-layertype": "Njejsu žane runiny typa \"$1\". Jenož {{PLURAL:$3|tutón typ so podpěruje|tutej typaj so podpěrujetej|tute typy so podpěruja|tute typy so podpěruja}}: $2",
+ "maps-error-no-layertype": "Dyrbiš typ runiny podać: {{PLURAL:$2|Jenož tutón typ so podpěruje|Tutej typaj so podpěrujetej|Tute typy so podpěruja|Tute typy so podpěruja}}: $1",
+ "validation-error-invalid-layer": "Parameter $1 dyrbi płaćiwa runina być.",
+ "validation-error-invalid-layers": "Parameter $1 dyrbi jedna runina abo wjacore runiny być.",
+ "maps-layer-of-type": "Runina typa $1",
+ "maps-layer-of-type-and-name": "Runina \"$2\" typa \"$1\"",
+ "maps-layer-type-supported-by": "Tutón typ runiny móže so {{PLURAL:$2|jenož z kartografiskej słužbu $1|z tutej kartografiskimaj słužbomaj: $1|z tutymi kartografiskimi słužbami: $1|z tutymi kartografiskimi słužbami: $1}}.wužiwać.",
+ "maps-coordinates-description": "Parserowa hóčka za formatowanje koordinatow z a do podpěranych formatow.",
+ "maps-displaymap-description": "Geografiske karty bjez we wikiju definowanych markow na nich zwobraznić.",
+ "maps-distance-description": "Konwertuj distancu z pomocu wěsteje podpěraneje jednotki do jeje ekwiwalenta z pomocu druheje jednotki.",
+ "maps-finddestination-description": "Cil z pomocu podateho startoweho dypka (kotryž móže w někajkim z podpěranych formatow być), spočatneho nasměrjenja a zdalenosće pytać.",
+ "maps-geocode-description": "Zmóžnja geokodowanje adresow, hinak prajene, přetworja wot čłowjeka čitajomne městna do sadźbow koordinatow. Je podpěra za wjacore geokodowanske słužby, kotrež njeměli so z kartowymi słužbami zaměnić.",
+ "maps-geodistance-description": "Wulič geografisku zdalenosć mjez dwěmaj dypkomaj, z a do podpěranych formatow.",
+ "maps-mapsdoc-description": "Tabelu z parametrami za podatu kartěrowansku słužbu hromadźe z jich standardnymi hódnotami a wopisanjemi zwobraznić.",
+ "maps-mapsdoc-par-service": "Kartografiska słužba, za kotrejež parametery dokumentacija ma so zwobraznić.",
+ "maps-mapsdoc-par-language": "Rěč, w kotrejž dokumentacija ma so zwobraznić. Jeli přełožk k dispoziciji njesteji, budźe so jendźelšćina wužiwać.",
+ "maps-coordinates-par-location": "Koordinaty, kotrež chceš formatować.",
+ "maps-coordinates-par-format": "Cilowy format za koordinaty.",
+ "maps-coordinates-par-directional": "Podawa, hač koordinaty maja směrowe podaće měć abo nic.",
+ "maps-distance-par-distance": "Zdalenosć, kotraž ma so do jeje ekwiwalenta z podatej jednotku konwertować.",
+ "maps-distance-par-decimals": "Maksimalna ličba městnow zady komy, kotraž ma so we wuslědku wužiwać.",
+ "maps-distance-par-unit": "Jednotka za wudawanje zdalenosće.",
+ "maps-finddestination-par-location": "Wuchadźišćo.",
+ "maps-finddestination-par-bearing": "Wuchadne nasměrjenje.",
+ "maps-finddestination-par-distance": "Pućowanska zdalenosć.",
+ "maps-finddestination-par-format": "Wudawanski format za cil.",
+ "maps-finddestination-par-directional": "Podawa, hač format cila ma směrowe podaće měć abo nic.",
+ "maps-geocode-par-location": "Adresa, kotruž chceš geokodować.",
+ "maps-geocode-par-format": "Format za wudate koordinaty.",
+ "maps-geocode-par-directional": "Podawa, hač koordinaty maja směrowe podaće měć abo nic.",
+ "maps-geodistance-par-location1": "Prěni dypk z dweju dypkow, mjez kotrymajž ma so zdalenosć wuličić.",
+ "maps-geodistance-par-location2": "Druhi dypk z dweju dypkow, mjez kotrymajž ma so zdalenosć wuličić.",
+ "maps-geodistance-par-unit": "Jednotka, w kotrejž so zdalenosć podawa.",
+ "maps-geodistance-par-decimals": "Maksimalna ličba městnow zady komy, kotraž ma so we wuslědku wužiwać.",
+ "maps-displaymap-par-mappingservice": "Zmóžnja nastajenje kartografiskeje słužby, kotraž ma so za generowanje karty wužiwać,",
+ "maps-displaymap-par-coordinates": "Městno, na kotrež ma so karta spočatnje centrować.",
+ "maps-displaymap-par-visitedicon": "Mjeno wobrazoweje dataje, kotrež ma so za markowe symbole wužiwać, po tym zo je so na prěnjotne marki kliknyło.",
+ "maps-displaymap-par-icon": "Zmóžnja postajenje symbola, kotryž ma so za wšě marki wužiwać.",
+ "maps-displaymap-par-circles": "Kruhi, kotrejž maja so zwobraznić",
+ "maps-displaymap-par-lines": "Linije, kotrež maja so zwobraznić",
+ "maps-displaymap-par-maxzoom": "Maksimalny skalowanski schodźenk",
+ "maps-displaymap-par-minzoom": "Minimalny skalowanski schodźenk",
+ "maps-displaymap-par-polygons": "Wjeleróžki, kotrež maja so zwobraznić",
+ "maps-displaymap-par-rectangles": "Praworóžki, kotrež maja so zwobraznić",
+ "maps-displaymap-par-static": "Jeli karta ma statiska być",
+ "maps-displaymap-par-wmsoverlay": "WMS-naworštowanje wužiwać",
+ "maps-fullscreen-button": "Połnu wobrazowku přepinać",
+ "maps-fullscreen-button-tooltip": "Kartu jako połnu wobrazowku abo zasadźenu pokazać",
+ "validation-error-invalid-location": "Parameter $1 dyrbi płaćiwe městno być.",
+ "validation-error-invalid-locations": "Parameter $1 dyrbi jedne městno abo wjacore městna być.",
+ "validation-error-invalid-width": "Parameter $1 dyrbi płaćiwa šěrokosć być.",
+ "validation-error-invalid-height": "Parameter $1 dyrbi płaćiwa wysokosć być.",
+ "validation-error-invalid-distance": "Parameter $1 dyrbi płaćiwa distanca być.",
+ "validation-error-invalid-distances": "Parameter $1 dyrbi jedna distanca abo wjacore distancy być.",
+ "validation-error-invalid-image": "Parameter $1 dyrbi płaćiwy wobraz być.",
+ "validation-error-invalid-images": "Parameter $1 dyrbi jedyn wobraz abo wjacore wobrazy być.",
+ "validation-error-invalid-goverlay": "Parameter $1 dyrbi płaćiwa woršta być.",
+ "validation-error-invalid-goverlays": "Parameter $1 dyrbi jedna woršta abo wjacore woršty być.",
+ "maps-abb-north": "S",
+ "maps-abb-east": "W",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Šěrina:",
+ "maps-longitude": "Dołhosć:",
+ "maps-invalid-coordinates": "Hódnota $1 njebu jako płaćiwu sadźbu koordinatow spóznata.",
+ "maps_coordinates_missing": "Za kartu njejsu koordinaty podate.",
+ "maps_geocoding_failed": "Geokodowanje {{PLURAL:$2|slědowaceje adresy|slědowaceju adresow|slědowacych adresow|slědowacych adresow}} njebě móžno: $1. Karta njeda so zwobraznić.",
+ "maps_geocoding_failed_for": "Geokodowanje {{PLURAL:$2|slědowaceje adresy|slědowaceju adresow|slědowacych adresow|slědowacych adresow}} njebě móžno a {{PLURAL:$2|tuta adresa|tutej adresy|tute adresy|tute adresy}} so na karće {{PLURAL:$2|wuwostaja|wuwostajetej|wuwostajeja|wuwostajeja}}: $1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Slědowaca koordinata njebu spóznana|Slědowacej koordinaće njebuštej spóznanej|Slědowace koordinaty njebuchu spóznane|Slědowace koordinaty njebuchu spóznane}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Slědowaca koordinata njebu spóznana|Slědowacej koordinaće njebuštej spóznanej|Slědowace koordinaty njebuchu spóznane|Slědowace koordinaty njebuchu spóznane}} a {{PLURAL:$2|bu na karće wuwostajena|buštej na karće wuwostajenej|buchu na karće wuwostajene|buchu na karće wuwostajene}}: $1",
+ "maps_map_cannot_be_displayed": "Karta njeda so zwobraznić.",
+ "maps-geocoder-not-available": "Funkcija geokodowanja Kartow k dispoziciji njesteji, twoje městno njehodźi so geokodować.",
+ "maps_click_to_activate": "Klikń, zo by kartu aktiwizował",
+ "maps_centred_on": "Karta na $1, $2 centrowana.",
+ "maps-par-mappingservice": "Zmóžnja nastajenje kartografiskeje słužby, kotraž ma so za wutworjenje karty wužiwać,",
+ "maps-par-centre": "Městno, hdźež karta ma so centrować",
+ "maps-par-enable-fullscreen": "Tłóčatko połneje wobrazowki zmóžnić",
+ "maps-par-kml": "KML-dataje, kotrež maja so na kartu začitać.",
+ "maps-googlemaps3-incompatbrowser": "Twój wobhladowak njeje kompatibelny z Google Maps v3.",
+ "maps-googlemaps3-par-type": "Kartowy typ, kotryž ma so na spočatku pokazać.",
+ "maps-googlemaps3-par-layers": "Wosebite runiny, kotrež maja so na kartu začitać.",
+ "maps-googlemaps3-par-controls": "Wodźenske elementy, kotrež maja so na karće zwobraznić.",
+ "maps-googlemaps3-par-zoomstyle": "Stil skalowanskeho wodźenja.",
+ "maps-googlemaps3-par-typestyle": "Stil wodźenja za kartowe typy.",
+ "maps-googlemaps3-par-autoinfowindows": "Wšě informaciske wokna awtomatisce wočinić, po tym zo strona je so začitała.",
+ "maps-googlemaps3-par-poi": "Zajimawosće pokazać.",
+ "mapeditor": "Kartowy editor",
+ "specialpages-group-maps": "Karty",
+ "mapeditor-parser-error": "Při parsowanju metadatow je so zmylk wustupił. Zapodaća wužiwarja so ignoruja.",
+ "mapeditor-none-text": "Žana",
+ "mapeditor-done-button": "Dokónčeny",
+ "mapeditor-remove-button": "Wotstronić",
+ "mapeditor-import-button2": "Importować",
+ "mapeditor-export-button": "Do wikikoda eksportować",
+ "mapeditor-import-button": "Z wikikoda importować",
+ "mapeditor-select-button": "Tutón wjeleróžk wubrać",
+ "mapeditor-mapparam-button": "Kartowe parametry wobdźěłać",
+ "mapeditor-clear-button": "Kartu wuprózdnić",
+ "mapeditor-code-title": "Wikikod",
+ "mapeditor-import-title": "Wikikod importować",
+ "mapeditor-form-title": "Podrobnosće wobdźěłać",
+ "mapeditor-link-title-switcher-popup-text": "Wuskakowanski meni z tekstom",
+ "mapeditor-link-title-switcher-link-text": "Wotkaz",
+ "mapeditor-form-field-title": "Titul",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Wotkaz",
+ "mapeditor-form-field-icon": "Symbol",
+ "mapeditor-form-field-group": "Skupina",
+ "mapeditor-form-field-inlinelabel": "Zasadźene pomjenjowanje",
+ "mapeditor-form-field-strokecolor": "Barba smužkow",
+ "mapeditor-form-field-strokeopacity": "Opaknosć smužkow",
+ "mapeditor-form-field-strokeweight": "Smužkowa tołstosć",
+ "mapeditor-form-field-fillcolor": "Pjelnjenska barba",
+ "mapeditor-form-field-fillopcaity": "Opaknosć pjelnjenja",
+ "mapeditor-form-field-showonhover": "Jenož pod znošowacym kursorom pokazać",
+ "mapeditor-mapparam-title": "Kartowe parametry wobdźěłać",
+ "mapeditor-mapparam-defoption": "-Parameter wubrać-",
+ "mapeditor-imageoverlay-button": "Wobrazowe zablendowanje přidać",
+ "mapeditor-form-field-image": "Wobraz",
+ "mapeditor-imageoverlay-title": "Podrobnosće wo wobrazowym zablendowanju",
+ "mapeditor-form-field-visitedicon": "Symbol za wopytany",
+ "semanticmaps-unrecognizeddistance": "Hódnota $1 płaćiwa distanca njeje.",
+ "semanticmaps-kml-link": "KML-dataju sej wobhladać",
+ "semanticmaps-default-kml-pagelink": "Nastawk $1 sej wobhladać",
+ "semanticmaps-latitude": "Šěrokostnik: $1",
+ "semanticmaps-longitude": "Dołhostnik: $1",
+ "semanticmaps-altitude": "Wysokosć: $1",
+ "semanticmaps-forminput-locations": "Městna",
+ "semanticmaps-par-staticlocations": "Lisćina městnow, kotrež maja so zhromadnje z naprašowanymi datami karće přidać. Kaž pola zwobraznjenskich dypkow móžeš titul. wopisanje a symbol na městno z pomocu tildy \"~\" jako dźělatko přidać.",
+ "semanticmaps-par-showtitle": "Titul w informaciskim woknje woznamjenjenja pokazać abo nic. Je husto wužitne, tutu opciju znjemóžnić, hdyž so předłoha wužiwa, zo by so wobsah informaciskeho wokna formatował.",
+ "semanticmaps-par-hidenamespace": "Mjeno mjenoweho ruma w informaciskim woknje woznamjenjenja pokazać.",
+ "semanticmaps-par-centre": "Srjedźišćo karty. Jeli je njepodate, budźe so karta awtomatisce optimalne srjedźišćo wuběrać, zo bychu so wšě woznamjenjenja na karće pokazali.",
+ "semanticmaps-par-template": "Předłoha, kotraž ma so za formatowanje wobsaha infowokna wužiwać,",
+ "semanticmaps-par-geocodecontrol": "Geokodowanske wodźenje pokazać",
+ "semanticmaps-par-activeicon": "Symbol, kotryž ma so město standardneho woznamjenjenja zwobraznić, hdyž aktiwna strona naprašowanskemu wuslědkej wotpowěduje.",
+ "semanticmaps-par-pagelabel": "Jeli na \"haj\" stajene, změju wšě marki \"inlineLabel\" z wotkazom k stronje, kotraž koordinaty marki wobsahuje.",
+ "semanticmaps-kml-text": "Tekst, kotryž je z kóždej stronu zwjazany. Naruna so přez přidatne naprašowane kajkosće, jeli tajke su.",
+ "semanticmaps-kml-title": "Standardny titul za wuslědki",
+ "semanticmaps-kml-linkabsolute": "Wotkazy měli absolutne być (nic relatiwne)",
+ "semanticmaps-kml-pagelinktext": "Tekst, kotryž ma so za wotkazy k tej stronje wužiwać, w kotrejž $1 so přez titul strony naruna",
+ "semanticmaps-shapes-improperformat": "$1 je so wopak formatował. Prošu hlej dokumentaciju za formatowanje",
+ "semanticmaps-shapes-missingshape": "Formy za $1 njejsu so namakali. Prošu hlej dokumentaciju za k dispoziciji stejace formy."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ht.json b/www/wiki/extensions/Maps/i18n/ht.json
new file mode 100644
index 00000000..f2531413
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ht.json
@@ -0,0 +1,7 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W"
+}
diff --git a/www/wiki/extensions/Maps/i18n/hu.json b/www/wiki/extensions/Maps/i18n/hu.json
new file mode 100644
index 00000000..fb1ec7e3
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/hu.json
@@ -0,0 +1,89 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dani",
+ "Dj",
+ "Glanthor Reviol",
+ "Misibacsi",
+ "Máté",
+ "Macofe",
+ "TK-999"
+ ]
+ },
+ "maps-desc": "Lehetővé teszi a dinamikus térképek beágyazását a wiki lapokba, címek geográfiai kódolását és más geográfiai műveleteket",
+ "right-geocode": "geokód",
+ "maps_map": "Térkép",
+ "maps-loading-map": "Térkép betöltése…",
+ "maps-load-failed": "Nem sikerült betölteni a térképet!",
+ "maps-markers": "Markerek",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "egyebek",
+ "maps-ns-layer": "Réteg",
+ "maps-ns-layer-talk": "Rétegvita",
+ "maps-layer-property": "Tulajdonság",
+ "maps-layer-value": "Érték",
+ "maps-layer-errors": "Hibák",
+ "maps-error-invalid-layertype": "Nincs „$1” típusú réteg. Csak {{PLURAL:$3|ez a réteg támogatott|ezek a rétegek támogatottak}}: $2",
+ "maps-error-no-layertype": "Meg kell adnod egy réteg típust. {{PLURAL:$2|Csak ez a réteg támogatott|Ezek a rétegek támogatottak}}: $1",
+ "validation-error-invalid-layer": "$1 paraméternek egy érvényes réteg típusnak kell lennie.",
+ "validation-error-invalid-layers": "$1 paraméternek egy vagy több érvényes réted típusnak kell lennie.",
+ "maps-layer-of-type": "$1 típusú réteg",
+ "validation-error-invalid-location": "A $1 paraméternek valós helynek kell lennie.",
+ "validation-error-invalid-width": "A $1 paraméternek valós szélességnek kell lennie.",
+ "validation-error-invalid-height": "A $1 paraméternek valós magasságnak kell lennie.",
+ "validation-error-invalid-distance": "$1 paraméter érvényes távolságnak kell lennie.",
+ "validation-error-invalid-image": "A(z) $1 paraméter csak érvényes kép lehet.",
+ "validation-error-invalid-images": "A(z) $1 paraméter csak egy vagy több érvényes kép lehet.",
+ "validation-error-invalid-goverlay": "A(z) $1 paraméter csak érvényes réteg lehet.",
+ "validation-error-invalid-goverlays": "A(z) $1 paraméter csak egy vagy több érvényes réteg lehet.",
+ "maps-abb-north": "É",
+ "maps-abb-east": "K",
+ "maps-abb-south": "D",
+ "maps-abb-west": "Ny",
+ "maps-latitude": "Földrajzi szélesség:",
+ "maps-longitude": "Földrajzi hosszúság:",
+ "maps-invalid-coordinates": "A(z) „$1” érték nem érvényes koordinátacsoport.",
+ "maps_coordinates_missing": "Nincsenek megadva koordináták a térképhez.",
+ "maps_geocoding_failed": "A következő {{PLURAL:$2|cím|címek}} nem geokódolhatók: $1.\nA térképet nem lehet megjeleníteni.",
+ "maps_geocoding_failed_for": "A következő {{PLURAL:$2|cím nem geokódolható|címek nem geokódolhatóak}}, és nem {{PLURAL:$2|szerepel|szerepelnek}} a térképen:\n$1",
+ "maps_unrecognized_coords": "A következő {{PLURAL:$2|koordinátát|koordinátákat}} nem sikerült felismerni: $1.",
+ "maps_unrecognized_coords_for": "A következő {{PLURAL:$2|koordinátát|koordinátákat}} nem sikerült felismerni, és el {{PLURAL:$2|lett|lettek}} távolítva a térképről: $1",
+ "maps_map_cannot_be_displayed": "A térképet nem sikerült megjeleníteni.",
+ "maps-geocoder-not-available": "A térképek kiterjesztés geokódoló funkciója nem elérhető. A tartózkodási helyed nem geokódolható.",
+ "maps_click_to_activate": "Kattints a térkép aktiválásához",
+ "maps_centred_on": "Térkép középre igazítva a következő koordináták alapján: $1, $2.",
+ "maps-par-kml": "Betöltendő KML fájlok.",
+ "maps-googlemaps3-incompatbrowser": "A böngésződ nem kompatibilis a Google Maps v3-mal.",
+ "maps-googlemaps3-par-type": "Elsőre megjelenítendő térkép típusa.",
+ "maps-googlemaps3-par-zoomstyle": "A nagyítás irányításának stílusa.",
+ "mapeditor": "Térkép szerkesztő",
+ "specialpages-group-maps": "Térképek",
+ "mapeditor-none-text": "Nincs",
+ "mapeditor-done-button": "Kész",
+ "mapeditor-remove-button": "Eltávolítás",
+ "mapeditor-import-button2": "Importálás",
+ "mapeditor-export-button": "Exportálás wikikódba",
+ "mapeditor-import-button": "Importálás wikikódból",
+ "mapeditor-select-button": "Ezen sokszög kijelelölése",
+ "mapeditor-mapparam-button": "Térkép paraméterek szerkesztése",
+ "mapeditor-clear-button": "Térkép törlése",
+ "mapeditor-code-title": "Wikikód",
+ "mapeditor-form-title": "Részletek szerkesztése",
+ "mapeditor-link-title-switcher-link-text": "Hivatkozás",
+ "mapeditor-form-field-title": "Cím",
+ "mapeditor-form-field-text": "Szöveg",
+ "mapeditor-form-field-link": "Hivatkozás",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Csoport",
+ "mapeditor-form-field-inlinelabel": "Beágyazott címke",
+ "mapeditor-form-field-image": "Kép",
+ "semanticmaps-unrecognizeddistance": "A(z) $1 érték nem egy érvényes távolság.",
+ "semanticmaps-kml-link": "KML fájl megtekintése",
+ "semanticmaps-default-kml-pagelink": "A(z) $1 lap megtekintése",
+ "semanticmaps-latitude": "Szélesség: $1",
+ "semanticmaps-longitude": "Hosszúság: $1",
+ "semanticmaps-altitude": "Tengerszint feletti magasság: $1",
+ "semanticmaps-forminput-locations": "Helyszínek",
+ "semanticmaps-par-staticlocations": "A térképre a lekérdezett adatok mellett felveendő helyek listája. Akárcsak a megjelenítési pontokkal, minden helyhez megadhatsz címet, leírást és ikont hullámvonal (\"~\") elválasztóval.",
+ "semanticmaps-par-showtitle": "Megjelenítse a címet a jelző információs ablakában, vagy ne? Ennek kikapcsolás hasznos lehet, ha sablonnal formázod az információs ablak tartalmát."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ia.json b/www/wiki/extensions/Maps/i18n/ia.json
new file mode 100644
index 00000000..8f57ca02
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ia.json
@@ -0,0 +1,161 @@
+{
+ "@metadata": {
+ "authors": [
+ "McDutchie",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Permitte le incorporation de cartas dynamic in paginas wiki, le geocodification de adresses e altere operationes geographic",
+ "right-geocode": "Geocodificar",
+ "action-geocode": "facer geocodification sur iste wiki",
+ "maps_map": "Carta",
+ "maps-tracking-category": "Paginas con un carta generate per le extension Maps",
+ "maps-loading-map": "Cargamento del carta…",
+ "maps-load-failed": "Non poteva cargar le carta!",
+ "maps-markers": "Marcatores",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Filtrar marcatores",
+ "maps-others": "alteres",
+ "maps-kml-parsing-failed": "Error durante le processamento de un o plus files XML. Isto es generalmente debite a un fallimento de recuperation o a codice XML mal formate.",
+ "maps-ns-layer": "Strato",
+ "maps-ns-layer-talk": "Discussion Strato",
+ "maps-layer-property": "Proprietate",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Errores",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definition|Definitiones}} non valide",
+ "maps-layerdef-invalid-fatal": "Definition non valide fatal",
+ "maps-error-invalid-layertype": "Il non ha stratos del typo \"$1\". Solmente iste {{PLURAL:$3|typo|typos}} es supportate: $2",
+ "maps-error-no-layertype": "Tu debe specificar le typo de strato. {{PLURAL:$2|Solmente iste typo|Iste typos}} es supportate: $1",
+ "validation-error-invalid-layer": "Le parametro \"$1\" debe esser un strato valide.",
+ "validation-error-invalid-layers": "Le parametro \"$1\" debe esser un o plus stratos valide.",
+ "maps-layer-of-type": "Strato del typo $1",
+ "maps-layer-type-supported-by": "Iste typo de strato pote {{PLURAL:$2|solmente esser usate con le servicio cartographic|esser usate con le sequente servicios cartographic:}} $1.",
+ "maps-coordinates-description": "Uncino analysator pro formatar coordinatas, ex e in tote le formatos supportate.",
+ "maps-displaymap-description": "Monstra cartas geographic sin marcatores definite in wiki.",
+ "maps-distance-description": "Converte un distantia in un del unitates supportate a su equivalente in un altere unitate.",
+ "maps-finddestination-description": "Cercar un destination, date un puncto de initio (que pote esser in omne formato supportate), un direction initial e un distantia.",
+ "maps-geocode-description": "Permitte le geocodification de adresses, in altere parolas, converte adresses conventional de locos in gruppos de coordinatas. Existe supporto pro plure servicios de geocodification, le quales non debe esser confundite con servicios cartographic.",
+ "maps-geodistance-description": "Calcula le distantia geographic inter duo punctos, ex e in omne formato supportate.",
+ "maps-mapsdoc-description": "Presenta un tabella con le parametros de un servicio cartographic specificate, insimul con lor valores predefinite e lor descriptiones.",
+ "maps-mapsdoc-par-service": "Le servicio cartographic pro le qual presentar le documentation de parametros.",
+ "maps-mapsdoc-par-language": "Le lingua in le qual presentar le documentation. Si tal traduction non es disponibile, anglese essera usate in su loco.",
+ "maps-coordinates-par-location": "Le coordinatas que tu vole formatar.",
+ "maps-coordinates-par-format": "Le formato in le qual presentar le coordinatas.",
+ "maps-coordinates-par-directional": "Indica si le coordinatas debe esser presentate directional o non.",
+ "maps-distance-par-distance": "Le distantia a converter a su equivalente in un unitate specificate.",
+ "maps-distance-par-decimals": "Le numero maxime de digitos fractional a usar in le valor resultante.",
+ "maps-distance-par-unit": "Le unitate in le qual presentar le distantia.",
+ "maps-finddestination-par-location": "Le position initial.",
+ "maps-finddestination-par-bearing": "Le direction initial.",
+ "maps-finddestination-par-distance": "Le distantia a viagiar.",
+ "maps-finddestination-par-format": "Le formato in le qual producer le destination.",
+ "maps-finddestination-par-directional": "Indica si le formato del destination debe esser directional o non.",
+ "maps-geocode-par-location": "Le adresse que tu vole geocodificar.",
+ "maps-geocode-par-format": "Le formato pro le coordinatas resultante.",
+ "maps-geocode-par-directional": "Indica si le coordinatas debe esser presentate directional o non.",
+ "maps-geodistance-par-location1": "Le prime puncto del gruppo inter le quales calcular le distantia.",
+ "maps-geodistance-par-location2": "Le secunde puncto del gruppo inter le quales calcular le distantia.",
+ "maps-geodistance-par-unit": "Le unitate in le qual presentar le distantia.",
+ "maps-geodistance-par-decimals": "Le numero maxime de digitos fractional a usar in le valor resultante.",
+ "maps-displaymap-par-mappingservice": "Permitte definir le servicio cartographic a usar pro generar le carta.",
+ "maps-displaymap-par-coordinates": "Le loco in le qual le carta essera initialmente centrate.",
+ "maps-displaymap-par-zoom": "Permitte definir le nivello de zoom del carta.\nSi isto non es fornite, e multiple marcatores es presente in le cata, le zoom que los arrangia melio essera prendite, non le predefinition configurabile.",
+ "maps-displaymap-par-centre": "Permitte definir le coordinatas del centro del carta pro display_point(s).\nAccepta e adresses e coordinatas.\nSi iste proprietate non es fornite, le carta se centrara in le marcator fornite, o inter le marcatores fornite.",
+ "maps-displaymap-par-title": "Permitte definir texto que essera monstrate in le pop-ups de tote le marcatores que non ha un titulo specific.\nSi usate con un etiquetta, le titulo essera monstrate in litteras grasse e sublineate.",
+ "maps-displaymap-par-label": "Permitte definir texto que essera monstrate in le pop-ups de tote le marcatores que non ha un etiquetta specific.",
+ "maps-displaymap-par-icon": "Permitte definir le icone usate pro tote le marcatores.",
+ "validation-error-invalid-location": "Le parametro $1 debe esser un loco valide.",
+ "validation-error-invalid-locations": "Le parametro $1 debe esser un o plus locos valide.",
+ "validation-error-invalid-width": "Le parametro $1 debe esser un latitude valide.",
+ "validation-error-invalid-height": "Le parametro $1 debe esser un altitude valide.",
+ "validation-error-invalid-distance": "Le parametro $1 debe esser un distantia valide.",
+ "validation-error-invalid-distances": "Le parametro $1 debe esser un o plus distantias valide.",
+ "validation-error-invalid-image": "Le parametro $1 debe esser un imagine valide.",
+ "validation-error-invalid-images": "Le parametro $1 debe esser un o plus imagines valide.",
+ "validation-error-invalid-goverlay": "Le parametro $1 debe esser un superposition valide.",
+ "validation-error-invalid-goverlays": "Le parametro $1 debe esser un o plus superpositiones valide.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Latitude:",
+ "maps-longitude": "Longitude:",
+ "maps-invalid-coordinates": "Le valor $1 non es recognoscite qua coordinatas valide.",
+ "maps_coordinates_missing": "Nulle coordinata providite pro le mappa.",
+ "maps_geocoding_failed": "Le sequente {{PLURAL:$2|adresse|adresses}} non poteva esser geocodificate: $1.\nLe mappa non pote esser monstrate.",
+ "maps_geocoding_failed_for": "Le sequente {{PLURAL:$2|adresse|adresses}} non poteva esser geocodificate e ha essite omittite del mappa:\n$1",
+ "maps_unrecognized_coords": "Le sequente {{PLURAL:$2|coordinata|coordinatas}} non esseva recognoscite: $1.",
+ "maps_unrecognized_coords_for": "Le sequente {{PLURAL:$2|coordinata|coordinatas}} non esseva recognoscite e ha essite omittite del carta:\n$1",
+ "maps_map_cannot_be_displayed": "Le carta on pote esser monstrate.",
+ "maps-geocoder-not-available": "Le function de geocodification de Maps non es disponibile; tu loco non pote esser geocodificate.",
+ "maps_click_to_activate": "Clicca pro activar le carta",
+ "maps_centred_on": "Carta centrate super $1, $2.",
+ "maps-par-resizable": "Rende le carta redimensionabile per traher lo per su angulo dextre inferior.",
+ "maps-par-zoom": "Le nivello de zoom pro le carta. Pro cartas con marcatores isto es predefinite como le nivello de zoom le plus alte que ancora monstra tote le marcatores.",
+ "maps-par-width": "Permitte fixar le latitude del carta. Le unitate assumite es pixels, ma tu pote specificar un de iste unitates: px, ex, em, %.",
+ "maps-par-height": "Permitte fixar le altitude del carta. Le unitate assumite es pixels, ma tu pote specificar un de iste unitates: px, ex, em, %.",
+ "maps-par-kml": "Files KML pro cargar in le carta.",
+ "maps-googlemaps3-incompatbrowser": "Tu navigator de web non es compatibile con Google Maps version 3.",
+ "maps-googlemaps3-par-type": "Le typo de carta a monstrar initialmente.",
+ "maps-googlemaps3-par-types": "Le typos de carta que essera disponibile via le controlo de typo.",
+ "maps-googlemaps3-par-layers": "Stratos special pro cargar in le carta.",
+ "maps-googlemaps3-par-controls": "Le controlos a placiar super le carta.",
+ "maps-googlemaps3-par-zoomstyle": "Le stilo del controlo de zoom.",
+ "maps-googlemaps3-par-typestyle": "Le stilo del controlo de typo.",
+ "maps-googlemaps3-par-autoinfowindows": "Aperir automaticamente tote le fenestras informative post le cargamento del pagina.",
+ "maps-googlemaps3-par-gkml": "KML files albergate per Google a cargar sur le carta.",
+ "maps-googlemaps3-par-kmlrezoom": "Rezoomar le carta post le cargamento del stratos KML.",
+ "maps-googlemaps3-par-poi": "Monstrar punctos de interesse.",
+ "mapeditor": "Editor cartographic",
+ "specialpages-group-maps": "Cartas",
+ "mapeditor-parser-error": "Un error occurreva durante le processamento del metadatos. Le entrata del usator es ignorate.",
+ "mapeditor-none-text": "Nulle",
+ "mapeditor-done-button": "Facite",
+ "mapeditor-remove-button": "Remover",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Exportar in codice wiki",
+ "mapeditor-import-button": "Importar ex codice wiki",
+ "mapeditor-mapparam-button": "Modificar le parametros del carta",
+ "mapeditor-clear-button": "Rader carta",
+ "mapeditor-code-title": "Codice wiki",
+ "mapeditor-import-title": "Importar codice wiki",
+ "mapeditor-import-note": "Nota ben que le analysator syntactic expecta un formato multo stricte in le codice wiki. Le codice entrate hic debe corresponder al codice producite per le functionalitate de exportation.",
+ "mapeditor-form-title": "Modificar detalios",
+ "mapeditor-link-title-switcher-popup-text": "Pop-up con texto",
+ "mapeditor-link-title-switcher-link-text": "Ligamine",
+ "mapeditor-form-field-title": "Titulo",
+ "mapeditor-form-field-text": "Texto",
+ "mapeditor-form-field-link": "Ligamine",
+ "mapeditor-form-field-icon": "Icone",
+ "mapeditor-form-field-group": "Gruppo",
+ "mapeditor-form-field-inlinelabel": "Etiquetta in linea",
+ "mapeditor-form-field-strokecolor": "Color de tracto",
+ "mapeditor-form-field-strokeopacity": "Opacitate del tracto",
+ "mapeditor-form-field-strokeweight": "Peso del tracto",
+ "mapeditor-form-field-fillcolor": "Color de impletion",
+ "mapeditor-form-field-fillopcaity": "Opacitate de impletion",
+ "mapeditor-form-field-showonhover": "Monstrar solmente quando le cursor passa supra",
+ "mapeditor-mapparam-title": "Modificar le parametros del carta",
+ "mapeditor-mapparam-defoption": "-Selige parametro-",
+ "mapeditor-imageoverlay-button": "Adder un imagine superponite",
+ "mapeditor-form-field-image": "Imagine",
+ "mapeditor-imageoverlay-title": "Detalios del imagine superponite",
+ "mapeditor-form-field-visitedicon": "Icone visitate",
+ "semanticmaps-unrecognizeddistance": "Le valor $1 non es un distantia valide.",
+ "semanticmaps-kml-link": "Vider le file KML",
+ "semanticmaps-default-kml-pagelink": "Vider articulo $1",
+ "semanticmaps-latitude": "Latitude: $1",
+ "semanticmaps-longitude": "Longitude: $1",
+ "semanticmaps-altitude": "Altitude: $1",
+ "semanticmaps-forminput-locations": "Locos",
+ "semanticmaps-par-staticlocations": "Un lista de locos a adder al carta con le datos resultante del consulta. Como con display_points, tu pote adder un titulo, description e icone per loco usante le tilde \"~\" como separator.",
+ "semanticmaps-par-showtitle": "Monstrar un titulo in le fenestra de information de marcator o non. Disactivar isto es sovente utile si un patrono es usate pro formatar le contento del fenestra de information.",
+ "semanticmaps-par-hidenamespace": "Monstrar le titulo del spatio de nomines in le fenestra de information del marcator.",
+ "semanticmaps-par-centre": "Le centro del carta. Si non specificate, le systema selige automaticamente le centro optimal pro monstrar tote le marcatores in le carta.",
+ "semanticmaps-par-template": "Un patrono a usar pro formatar le contento del fenestra de information.",
+ "semanticmaps-par-geocodecontrol": "Monstrar le controlo de geocodification.",
+ "semanticmaps-kml-text": "Le texto associate con cata pagina. Es supplantate per le additional proprietates consultate, si existe.",
+ "semanticmaps-kml-title": "Le titulo predefinite pro resultatos",
+ "semanticmaps-kml-linkabsolute": "Debe ligamines esser absolute (in vice de relative)",
+ "semanticmaps-kml-pagelinktext": "Le texto a usar pro le ligamines al pagina, in le quales $1 essera reimplaciate per le titulo de pagina"
+}
diff --git a/www/wiki/extensions/Maps/i18n/id.json b/www/wiki/extensions/Maps/i18n/id.json
new file mode 100644
index 00000000..afa25d13
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/id.json
@@ -0,0 +1,139 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bennylin",
+ "Farras",
+ "Irwangatot",
+ "IvanLanin",
+ "පසිඳු කාවින්ද",
+ "Macofe",
+ "C5st4wr6ch"
+ ]
+ },
+ "maps-desc": "Mengaktifkan penyertaan peta dinamis dalam halaman wiki, pembuatan geokode alamat, dan operasi geografi lain",
+ "maps_map": "Peta",
+ "maps-loading-map": "Memuat peta...",
+ "maps-load-failed": "Peta tidak dapat dimuat!",
+ "maps-markers": "Tanda",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "lainnya",
+ "maps-ns-layer": "Lapisan",
+ "maps-ns-layer-talk": "Pembicaraan lapisan",
+ "maps-layer-property": "Properti",
+ "maps-layer-value": "Nilai",
+ "maps-layer-errors": "Kesalahan",
+ "maps-error-invalid-layertype": "Tidak ada lapisan jenis \"$1\". {{PLURAL:$3|Jenis|Jenis}} yang didukung: $2",
+ "maps-error-no-layertype": "Anda perlu menentukan jenis lapisan. {{PLURAL:$2|Jenis|Jenis}} yang didukung: $1",
+ "validation-error-invalid-layer": "Parameter $1 harus merupakan lapisan yang sah.",
+ "validation-error-invalid-layers": "Parameter $1 harus berupa satu atau lebih lapisan yang sah.",
+ "maps-layer-of-type": "Lapisan jenis $1",
+ "maps-layer-type-supported-by": "Lapisan ini hanya dapat digunakan oleh layanan pemetaan {{PLURAL:$2|$1|$1}}.",
+ "maps-coordinates-description": "Pengait parser untuk memformat koordinat, dari dan ke salah satu format yang didukung.",
+ "maps-displaymap-description": "Menampilkan peta geografis tanpa mencantumkan penanda wiki terdefinisi.",
+ "maps-distance-description": "Mengubah jarak dengan menggunakan unit terdukung tertentu menjadi setaranya dengan menggunakan unit lain.",
+ "maps-finddestination-description": "Menemukan tujuan dari suatu titik awal (dalam salah satu format yang didukung), arah, dan jarak.",
+ "maps-geocode-description": "Memberikan geokode alamat, atau dengan kata lain, mengubah lokasi yang dapat dibaca manusia ke set koordinat. Tersedia dukungan untuk beberapa layanan geokode, yang berbeda dengan layanan pemetaan.",
+ "maps-geodistance-description": "Menghitung jarak geografis antara dua titik, dari dan ke salah satu format yang didukung.",
+ "maps-coordinates-par-location": "Koordinat yang ingin diformat.",
+ "maps-coordinates-par-format": "Format sasaran untuk koordinat.",
+ "maps-coordinates-par-directional": "Menunjukkan apakah keluaran koordinat perlu disertai arah atau tidak.",
+ "maps-distance-par-distance": "Jarak yang ingin diubah ke setaranya dengan suatu unit tertentu.",
+ "maps-distance-par-decimals": "Jumlah maksimum digit pecahan yang digunakan untuk nilai hasil.",
+ "maps-distance-par-unit": "Unit keluaran jarak.",
+ "maps-finddestination-par-location": "Lokasi awal.",
+ "maps-finddestination-par-bearing": "Arah awal.",
+ "maps-finddestination-par-distance": "Jarak yang ditempuh.",
+ "maps-finddestination-par-format": "Format keluaran tujuan.",
+ "maps-finddestination-par-directional": "Menunjukkan apakah format tujuan disertai arah atau tidak.",
+ "maps-geocode-par-location": "Alamat yang ingin diubah menjadi geokode.",
+ "maps-geocode-par-format": "Format koordinat hasil.",
+ "maps-geocode-par-directional": "Menunjukkan apakah keluaran koordinat perlu disertai arah atau tidak.",
+ "maps-geodistance-par-location1": "Titik pertama dalam himpunan untuk menghitung jarak antara.",
+ "maps-geodistance-par-location2": "Titik kedua dalam himpunan untuk menghitung jarak antara.",
+ "maps-geodistance-par-unit": "Unit keluaran jarak.",
+ "maps-geodistance-par-decimals": "Jumlah maksimum digit pecahan yang digunakan untuk nilai hasil.",
+ "maps-displaymap-par-mappingservice": "Memungkinkan pengaturan layanan pemetaan yang akan digunakan untuk menghasilkan peta.",
+ "maps-displaymap-par-coordinates": "Lokasi pusat awal dari peta.",
+ "maps-displaymap-par-zoom": "Memungkinkan pengaturan tingkat pembesaran peta.\nJika tidak diberikan dan beberapa penanda ada pada peta, akan dipilih pembesaran yang paling muat, bukan bawaan yang disetel.",
+ "maps-displaymap-par-centre": "Memungkinkan pengaturan koordinat pusat peta untuk display_point.\nDapat menerima alamat maupun koordinat.\nJika tidak diberikan, peta akan menentukan pusatnya pada penanda yang ada atau di antara penanda yang diberikan.",
+ "maps-displaymap-par-title": "Memungkinkan pengaturan teks yang akan ditampilkan pada munculan dari semua penanda yang tidak memiliki judul tertentu.\nJika digunakan bersama dengan label, judul akan ditebalkan dan memiliki garis bawah.",
+ "maps-displaymap-par-label": "Memungkinkan pengaturan teks yang akan ditampilkan pada munculan dari semua tanda yang tidak memiliki label tertentu.",
+ "maps-displaymap-par-icon": "Memungkinkan pengaturan ikon yang digunakan semua penanda.",
+ "validation-error-invalid-location": "Parameter $1 harus merupakan lokasi yang sah.",
+ "validation-error-invalid-locations": "Parameter $1 harus berupa satu atau lebih lokasi yang sah.",
+ "validation-error-invalid-width": "Parameter $1 harus merupakan lebar yang sah.",
+ "validation-error-invalid-height": "Parameter $1 harus merupakan tinggi yang sah.",
+ "validation-error-invalid-distance": "Parameter $1 harus merupakan nilai jarak yang sah.",
+ "validation-error-invalid-distances": "Parameter $1 harus berupa satu atau lebih jarak yang sah.",
+ "validation-error-invalid-image": "Parameter $1 harus merupakan berkas yang sah.",
+ "validation-error-invalid-images": "Parameter $1 harus berupa satu atau lebih berkas yang sah.",
+ "validation-error-invalid-goverlay": "Parameter $1 harus merupakan hamparan yang sah.",
+ "validation-error-invalid-goverlays": "Parameter $1 harus berupa satu atau lebih hamparan yang sah.",
+ "maps-abb-north": "U",
+ "maps-abb-east": "T",
+ "maps-abb-south": "S",
+ "maps-abb-west": "B",
+ "maps-latitude": "Lintang:",
+ "maps-longitude": "Bujur:",
+ "maps-invalid-coordinates": "Nilai $1 tidak dikenali sebagai rangkaian koordinat yang sah.",
+ "maps_coordinates_missing": "Tidak koordinat yang disediakan bagi peta.",
+ "maps_geocoding_failed": "{{PLURAL:$2|alamat|alamat}} berikut tidak dapat di Geocode: $1.\nPeta tidak dapat ditampilkan.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|alamat|alamat}} berikut tidak dapat di Geocode dan {{PLURAL:$2|telah|telah}} dihilangkan dari peta: $1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Koordinat|Koordinat}} berikut tidak dikenali: $1.",
+ "maps_unrecognized_coords_for": "Koordinat berikut tidak dikenali dan {{PLURAL:$2|telah|telah}} diabaikan dari peta:\n$1",
+ "maps_map_cannot_be_displayed": "Peta tak dapat ditampilkan.",
+ "maps-geocoder-not-available": "Fitur kodegeo Peta tidak tersedia. Lokasi Anda tidak dapat dikodegeokan",
+ "maps_click_to_activate": "Klik untuk mengaktifkan peta",
+ "maps_centred_on": "Peta dipusatkan di $1, $2.",
+ "maps-par-resizable": "Membuat peta berubah ukuran dengan menyeret pojok kanan bawahnya.",
+ "maps-par-zoom": "Tingkat pembesaran peta. Secara bawaan, peta bertanda akan mengambil tingkat pembesaran yang masih menunjukkan semua tanda.",
+ "maps-par-width": "Memungkinkan pengaturan lebar peta. Secara bawaan, piksel akan dianggap sebagai unit, tetapi Anda dapat menentukan secara eksplisit salah satu unit berikut: px, ex, em, %.",
+ "maps-par-height": "Memungkinkan pengaturan tinggi peta. Secara bawaan, piksel akan dianggap sebagai unit, tetapi Anda dapat menentukan secara eksplisit salah satu unit berikut: px, ex, em, %.",
+ "maps-par-kml": "Berkas KML yang akan dimuat ke dalam peta.",
+ "maps-googlemaps3-incompatbrowser": "Peramban Anda tidak kompatibel dengan Google Maps v3.",
+ "maps-googlemaps3-par-type": "Jenis peta yang ditampilkan saat awal.",
+ "maps-googlemaps3-par-types": "Jenis peta yang akan tersedia melalui kontrol jenis.",
+ "maps-googlemaps3-par-layers": "Lapisan khusus yang akan dimuat ke dalam peta.",
+ "maps-googlemaps3-par-controls": "Kontrol yang akan ditempatkan pada peta.",
+ "maps-googlemaps3-par-zoomstyle": "Gaya kontrol pembesaran.",
+ "maps-googlemaps3-par-typestyle": "Gaya jenis kontrol.",
+ "maps-googlemaps3-par-autoinfowindows": "Otomatis membuka semua jendela info setelah halaman dimuat.",
+ "mapeditor": "Penyunting peta",
+ "specialpages-group-maps": "Peta",
+ "mapeditor-none-text": "Tidak ada",
+ "mapeditor-done-button": "Selesai",
+ "mapeditor-remove-button": "Hapus",
+ "mapeditor-import-button2": "Impor",
+ "mapeditor-export-button": "Ekspor ke kode wiki",
+ "mapeditor-import-button": "Impor dari kode wiki",
+ "mapeditor-select-button": "Pilih poligon ini",
+ "mapeditor-mapparam-button": "Sunting parameter peta",
+ "mapeditor-clear-button": "Hapus peta",
+ "mapeditor-code-title": "Kode wiki",
+ "mapeditor-import-title": "Impor kode wiki",
+ "mapeditor-form-title": "Sunting rincian",
+ "mapeditor-link-title-switcher-link-text": "Tautan",
+ "mapeditor-form-field-title": "Judul",
+ "mapeditor-form-field-text": "Teks",
+ "mapeditor-form-field-link": "Tautan",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Grup",
+ "mapeditor-form-field-strokecolor": "Warna pinggiran",
+ "mapeditor-form-field-strokeopacity": "Transparansi pinggiran",
+ "mapeditor-form-field-strokeweight": "Tebal pinggiran",
+ "mapeditor-form-field-fillcolor": "Warna isi",
+ "mapeditor-form-field-fillopcaity": "Transparansi isi",
+ "mapeditor-mapparam-title": "Sunting parameter peta",
+ "mapeditor-mapparam-defoption": "-Pilih parameter-",
+ "mapeditor-form-field-image": "Gambar",
+ "semanticmaps-unrecognizeddistance": "Nilai $1 bukan jarak yang sah.",
+ "semanticmaps-kml-link": "Lihat berkas KML",
+ "semanticmaps-default-kml-pagelink": "Lihat halaman $1",
+ "semanticmaps-forminput-locations": "Lokasi",
+ "semanticmaps-par-staticlocations": "Daftar lokasi yang akan ditambahkan ke dalam peta, berikut data kueri. Seperti halnya display_points, Anda dapat menambahkan judul, deskripsi, dan ikon per lokasi dengan menggunakan tanda tilde \"~\" sebagai pemisah.",
+ "semanticmaps-par-showtitle": "Tampilkan judul di jendela info penanda. Penonaktifan judul sering berguna ketika menggunakan templat untuk memformat isi jendela info.",
+ "semanticmaps-par-centre": "Pusat peta. Jika tidak disediakan, peta secara otomatis akan memilih pusat optimal untuk menampilkan semua penanda di peta.",
+ "semanticmaps-par-template": "Ttemplat yang digunakan untuk memformat isi jendela info.",
+ "semanticmaps-kml-linkabsolute": "Pranala sebaiknya adalah mutlak (lawan dari relatif)",
+ "semanticmaps-shapes-improperformat": "Format yang kurang tepat untuk $1. Silakan lihat dokumentasi untuk format."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ig.json b/www/wiki/extensions/Maps/i18n/ig.json
new file mode 100644
index 00000000..72ec5033
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ig.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ukabia"
+ ]
+ },
+ "maps_map": "Otú Uzọr"
+}
diff --git a/www/wiki/extensions/Maps/i18n/it.json b/www/wiki/extensions/Maps/i18n/it.json
new file mode 100644
index 00000000..9eecfe15
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/it.json
@@ -0,0 +1,163 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beta16",
+ "Civvì",
+ "Darth Kule",
+ "F. Cosoleto",
+ "Gianfranco",
+ "HalphaZ",
+ "Rosh",
+ "Viscontino",
+ "Matteocng",
+ "Kaspo",
+ "S4b1nuz E.656"
+ ]
+ },
+ "maps-desc": "Consente di includere mappe dinamiche nelle pagine wiki, la geocodifica degli indirizzi ed altre operazioni geografiche",
+ "right-geocode": "Effettua la geocodifica",
+ "maps_map": "Mappa",
+ "maps-loading-map": "Caricamento mappa ...",
+ "maps-load-failed": "Impossibile caricare la mappa!",
+ "maps-markers": "Marcatori",
+ "maps-copycoords-prompt": "CTRL+C, INVIO",
+ "maps-searchmarkers-text": "Filtra marcatori",
+ "maps-others": "altri",
+ "maps-ns-layer": "Livello",
+ "maps-ns-layer-talk": "Discussioni livello",
+ "maps-layer-property": "Proprietà",
+ "maps-layer-value": "Valore",
+ "maps-layer-errors": "Errori",
+ "maps-error-invalid-layertype": "Non c'è alcun livello di tipo \"$1\". Solo {{PLURAL:$3|questo tipo è supportato|questi tipi sono supportati}}: $2",
+ "maps-error-no-layertype": "È necessario specificare il tipo di livello. Solo {{PLURAL:$2|questo tipo è supportato|questi tipi sono supportati}}: $1",
+ "validation-error-invalid-layer": "Il parametro $1 deve essere un livello valido.",
+ "validation-error-invalid-layers": "Il parametro $1 deve essere uno o più livelli validi.",
+ "maps-layer-of-type": "Livello di tipo $1",
+ "maps-layer-type-supported-by": "Questo tipo di livello può essere usato solo con {{PLURAL:$2|il servizio di mappe $1|questi servizi di mappe: $1}}.",
+ "maps-coordinates-description": "Hook del parser per formattare le coordinate, da e verso i formati supportati.",
+ "maps-distance-description": "Convertire una distanza utilizzando una certa unità supportata nel suo equivalente utilizzando un'altra unità.",
+ "maps-coordinates-par-location": "Le coordinate che si desidera formattare.",
+ "maps-coordinates-par-format": "Il formato di destinazione per le coordinate.",
+ "maps-distance-par-unit": "L'unità di misura in cui sarà visualizzata la distanza.",
+ "maps-finddestination-par-location": "La posizione iniziale.",
+ "maps-finddestination-par-bearing": "La direzione iniziale.",
+ "maps-finddestination-par-distance": "La distanza da percorrere.",
+ "maps-geocode-par-format": "Il formato per le coordinate risultanti.",
+ "maps-displaymap-par-coordinates": "Uno o più luoghi da mostrare sulla mappa. Verranno indicati con un marcatore.",
+ "maps-displaymap-par-visitedicon": "Il nome del file di un'immagine da utilizzare come icone per i marcatori dopo che quelli originali sono stati selezionati",
+ "maps-displaymap-par-lines": "Linee da visualizzare",
+ "maps-displaymap-par-maxzoom": "Il livello massimo di zoom",
+ "maps-displaymap-par-minzoom": "Il livello minimo di zoom",
+ "maps-displaymap-par-polygons": "Poligoni da visualizzare",
+ "maps-displaymap-par-rectangles": "Rettangoli da visualizzare",
+ "maps-displaymap-par-static": "Rendi la mappa statica",
+ "validation-error-invalid-location": "Il parametro $1 deve essere una posizione valida.",
+ "validation-error-invalid-locations": "Il parametro $1 deve essere una o più posizioni valide.",
+ "validation-error-invalid-width": "Il parametro $1 deve essere una larghezza valida.",
+ "validation-error-invalid-height": "Il parametro $1 deve essere un'altezza valida.",
+ "validation-error-invalid-distance": "Il parametro $1 deve essere una distanza valida.",
+ "validation-error-invalid-distances": "Il parametro $1 deve essere una o più distanze valide.",
+ "validation-error-invalid-image": "Il parametro $1 deve essere un'immagine valida.",
+ "validation-error-invalid-images": "Il parametro $1 deve essere una o più immagini valide.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitudine:",
+ "maps-longitude": "Longitudine:",
+ "maps-invalid-coordinates": "Il valore $1 non è stato riconosciuto come un set di coordinate valido.",
+ "maps_coordinates_missing": "Non sono state fornite coordinate per la mappa",
+ "maps_geocoding_failed": "Non è stato possibile effettuare la geocodifica per {{PLURAL:$2|il seguente indirizzo|i seguenti indirizzi}}: $1.",
+ "maps_geocoding_failed_for": "Non è stato possibile effettuare la geocodifica {{PLURAL:$2|del seguente indirizzo|dei seguenti indirizzi}} che {{PLURAL:$2|è stato omesso|sono stati omessi}} dalla mappa: $1.",
+ "maps_unrecognized_coords": "{{PLURAL:$2|La seguente coordinata|Le seguenti coordinate}} non sono state riconosciute: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|La seguente coordinata|Le seguenti coordinate}} {{PLURAL:$2|non è stata riconosciuta ed è stata omessa|non sono state riconosciute e sono state omesse}} dalla mappa: $1.",
+ "maps_map_cannot_be_displayed": "La mappa non può essere visualizzata.",
+ "maps-geocoder-not-available": "La funzionalità di geocodifica dell'estensione Maps non è disponibile. La tua posizione non può essere geocodificata.",
+ "maps_leaflet": "Volantino",
+ "maps-leaflet-par-defzoom": "Permette l'impostazione del livello di zoom predefinito della mappa.",
+ "maps_click_to_activate": "Clicca per attivare la mappa.",
+ "maps_centred_on": "Mappa centrata su $1, $2.",
+ "maps-par-enable-fullscreen": "Attiva bottone a tutto schermo",
+ "maps-par-kml": "File KML da caricare sulla mappa.",
+ "maps-googlemaps3-incompatbrowser": "Si sta utilizzando un browser non compatibile con Google Maps v3.",
+ "maps-googlemaps3-par-type": "Il tipo di mappa da mostrare inizialmente.",
+ "maps-googlemaps3-par-layers": "Livelli speciali da caricare sulla mappa.",
+ "maps-googlemaps3-par-controls": "I controlli da posizionare sulla mappa.",
+ "maps-googlemaps3-par-zoomstyle": "Lo stile del controllo dello zoom.",
+ "maps-googlemaps3-par-gkml": "File KML ospitati da Google da caricare sulla mappa.",
+ "maps-googlemaps3-par-poi": "Mostra punti di interesse.",
+ "maps-googlemaps3-par-clustergridsize": "La dimensione della griglia di un cluster in pixels.",
+ "maps-par-clustermaxzoom": "Il massimo livello di zoom in cui i cluster possono esistere.",
+ "maps-par-clusterzoomonclick": "Se il comportamento predefinito quando si clicca su un cluster è di fare lo zoom su di esso.",
+ "maps-par-maxclusterradius": "Il raggio massimo coperto da un cluster.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Se il centro di ogni cluster dovrebbe essere la media di tutti i marcatori del cluster.",
+ "maps-googlemaps3-par-clusterminsize": "Il numero minimo di marcatori presenti in un cluster dopo il quale tutti i marcatori saranno nascosti e sarà mostrato il loro numero.",
+ "mapeditor": "Editor della mappa",
+ "specialpages-group-maps": "Mappe",
+ "mapeditor-parser-error": "Si verificato un errore durante l'analisi dei metadati. Ignorato l'input dell'utente.",
+ "mapeditor-none-text": "Nessuno",
+ "mapeditor-done-button": "Fatto",
+ "mapeditor-remove-button": "Rimuovi",
+ "mapeditor-import-button2": "Importa",
+ "mapeditor-export-button": "Esporta in codice wiki",
+ "mapeditor-import-button": "Importa dal codice wiki",
+ "mapeditor-select-button": "Seleziona questo poligono",
+ "mapeditor-mapparam-button": "Modifica i parametri della mappa",
+ "mapeditor-clear-button": "Pulisci mappa",
+ "mapeditor-code-title": "Codice wiki",
+ "mapeditor-import-title": "Importa codice wiki",
+ "mapeditor-import-note": "Da notare che il parser si aspetta un formato molto rigoroso per il codice wiki. Il codice immesso qui dovrebbe corrispondere al codice emesso dalla funzionalità di esportazione.",
+ "mapeditor-form-title": "Modifica dettagli",
+ "mapeditor-link-title-switcher-popup-text": "Popup con testo",
+ "mapeditor-link-title-switcher-link-text": "Collegamento",
+ "mapeditor-form-field-title": "Titolo",
+ "mapeditor-form-field-text": "Testo",
+ "mapeditor-form-field-link": "Collegamento",
+ "mapeditor-form-field-icon": "Icona",
+ "mapeditor-form-field-group": "Gruppo",
+ "mapeditor-form-field-strokecolor": "Colore del tratto",
+ "mapeditor-form-field-fillcolor": "Colore di riempimento",
+ "mapeditor-form-field-fillopcaity": "Opacità riempimento",
+ "mapeditor-form-field-showonhover": "Visualizza solo al passaggio del mouse",
+ "mapeditor-mapparam-title": "Modifica i parametri della mappa",
+ "mapeditor-mapparam-defoption": "-Selezionare parametro-",
+ "mapeditor-imageoverlay-button": "Aggiungi sovrapposizione dell'immagine",
+ "mapeditor-form-field-image": "Immagine",
+ "mapeditor-imageoverlay-title": "Dettagli di sovrapposizione di immagini",
+ "mapeditor-form-field-visitedicon": "Icona visitato",
+ "semanticmaps-unrecognizeddistance": "Il valore $1 non è una distanza valida.",
+ "semanticmaps-kml-link": "Visualizza il file KML",
+ "semanticmaps-default-kml-pagelink": "Visualizza la pagina $1",
+ "semanticmaps-latitude": "Latitudine: $1",
+ "semanticmaps-longitude": "Longitudine: $1",
+ "semanticmaps-altitude": "Altitudine: $1",
+ "semanticmaps-forminput-locations": "Luoghi",
+ "semanticmaps-par-staticlocations": "Un elenco di luoghi da aggiungere alla mappa unitamente ai dati interrogati. Come con display_points, si può aggiungere un titolo, la descrizione e l'icona per ogni posizione utilizzando la tilde \"~\" come separatore.",
+ "semanticmaps-par-showtitle": "Mostrare oppure no un titolo nella finestra informazioni per l'indicatore. Disattivarlo è spesso utile quando si utilizza un template per la formattazione del contenuto della finestra informazioni.",
+ "semanticmaps-par-hidenamespace": "Mostrare il namespace del titolo nella finestra informazioni per l'indicatore",
+ "semanticmaps-par-centre": "Il centro della mappa. Quando non indicato, la mappa sceglierà automaticamente il centro ottimale per visualizzare tutti gli indicatori sulla mappa.",
+ "semanticmaps-par-template": "Un template da utilizzare per formattare il contenuto della finestra informazioni.",
+ "semanticmaps-par-geocodecontrol": "Mostra il controllo per geocodifica.",
+ "semanticmaps-par-activeicon": "Icona da mostrare al posto dell'indicatore predefinito, quando la pagina attiva è uguale al risultato dell'interrogazione",
+ "semanticmaps-par-pagelabel": "Quando impostato su \"yes\", tutti gli indicatori avranno un \"inlineLabel\" con un collegamento alla pagina che contiene le coordinate per l'indicatore",
+ "semanticmaps-par-userparam": "Un valore passato in ogni chiamata a template, se un template è utilizzato",
+ "semanticmaps-kml-text": "Il testo associato per ogni pagina. Sovrascritto dall'eventuale proprietà dell'interrogazione aggiuntiva.",
+ "semanticmaps-kml-title": "Il titolo predefinito per i risultati",
+ "semanticmaps-kml-linkabsolute": "I collegamenti dovranno essere assoluti (anziché relativi)",
+ "semanticmaps-kml-pagelinktext": "Il testo da utilizzare per i collegamenti alla pagina, in cui $1 verrà sostituito dal titolo della pagina",
+ "semanticmaps-shapes-improperformat": "Formattazione impropria di $1. Per favore controlla la documentazione sulla formattazione",
+ "semanticmaps-shapes-missingshape": "Nessuna forma trovata per $1. Per favore controlla la documentazione sulle forme disponibili",
+ "validator-type-mapscircle": "Cerchio geografico",
+ "validator-type-mapscircle-list": "Elenco di cerchi",
+ "validator-type-mapsimageoverlay": "Sovrapposizione di immagini",
+ "validator-type-mapsimageoverlay-list": "Elenco delle sovrapposizioni di immagini",
+ "validator-type-mapsline": "Linea geografica",
+ "validator-type-mapsline-list": "Elenco di linee",
+ "validator-type-mapslocation": "Posizione geografica",
+ "validator-type-mapslocation-list": "Elenco delle località",
+ "validator-type-mapsrectangle": "Rettangolo geografico",
+ "validator-type-mapsrectangle-list": "Elenco di rettangoli",
+ "validator-type-mapspolygon": "Poligono geografico",
+ "validator-type-mapspolygon-list": "Elenco dei poligoni geografici",
+ "validator-type-jsonfile": "testo"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ja.json b/www/wiki/extensions/Maps/i18n/ja.json
new file mode 100644
index 00000000..7fa54348
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ja.json
@@ -0,0 +1,176 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aotake",
+ "Fryed-peach",
+ "Shirayuki",
+ "Yanajin66",
+ "青子守歌",
+ "Schu",
+ "Suyama",
+ "Omotecho"
+ ]
+ },
+ "maps-desc": "ウィキページへの動的な地図の埋め込み、住所の座標データへの変換、その他の地図関連の操作ができるようにする。",
+ "right-geocode": "ジオコーディング",
+ "action-geocode": "このウィキでのジオコーディングの実行",
+ "maps_map": "地図",
+ "maps-tracking-category": "Maps拡張機能がレンダリングした地図があるページ",
+ "maps-loading-map": "地図を読み込み中...",
+ "maps-load-failed": "地図を読み込めませんでした。",
+ "maps-markers": "マーカー",
+ "maps-copycoords-prompt": "Ctrl+C、Enter",
+ "maps-searchmarkers-text": "マーカーを絞り込む",
+ "maps-others": "その他",
+ "maps-kml-parsing-failed": "1 件以上の KML ファイルを構文解析できませんでした。これは通常、取得失敗または XML の破損で発生します。",
+ "maps-ns-layer": "レイヤー",
+ "maps-ns-layer-talk": "レイヤー・トーク",
+ "maps-layer-property": "プロパティ",
+ "maps-layer-value": "値",
+ "maps-layer-errors": "エラー",
+ "maps-layerdef-invalid": "{{PLURAL:$1|definition|定義}}が無効です",
+ "maps-layerdef-wrong-namespace": "レイヤー設定は「$1」名前空間のページ限定で有効です",
+ "maps-layerdef-equal-layer-name": "同じレイヤーページ内の複数のレイヤー名はそれぞれ違う必要があります。「$1」は既に他のレイヤー名に使用中です。",
+ "maps-layerpage-usage": "「$1」レイヤーを使った地図のあるページ",
+ "maps-layerpage-nousage": "現在、このレイヤーを使用中のページはありません。",
+ "maps-error-invalid-layertype": "種類「$1」のレイヤーはありません。{{PLURAL:$3|以下の}}種類のみに対応しています: $2",
+ "maps-error-no-layertype": "レイヤーの種類を指定する必要があります。{{PLURAL:$2|この種類のみ|これらの種類}}に対応しています: $1",
+ "validation-error-invalid-layer": "引数「$1」には有効なレイヤーを指定してください。",
+ "validation-error-invalid-layers": "引数「$1」には有効なレイヤーを 1 つ以上指定してください。",
+ "validation-error-no-non-numeric": "引数「$1」には数字以外の文字列を指定してください。",
+ "validation-error-no-non-numerics": "引数「$1」には最低1文字の数字以外の文字列を指定してください。",
+ "maps-layer-of-type": "種類「$1」のレイヤー",
+ "maps-layer-of-type-and-name": "「$1」タイプの「$2」レイヤー",
+ "maps-layer-type-supported-by": "このレイヤーの種類は、{{PLURAL:$2|$1地図サービスでのみ使用できます。|以下の地図サービスで使用できます: $1}}",
+ "maps-coordinates-description": "対応している座標形式間で相互に変換するパーサーフック",
+ "maps-displaymap-description": "ウィキ定義をしたマーカーを使わない地図を表示します。",
+ "maps-distance-description": "サポートする特定の単位で表示した距離を、別の単位に換算します。",
+ "maps-finddestination-description": "出発地点から方位と距離の条件に当てはまる目的地を探します(サポートする選択肢のどのフォーマットでも可能)。",
+ "maps-geodistance-description": "サポートする単位の選択肢の組み合わせに従って、地図上の2地点間の距離を換算します。",
+ "maps-layerdefinition-description": "地図の他の機能と同時に表示できる特別なレイヤーを説明します。",
+ "maps-distance-par-distance": "指定した単位に換算する距離を指定します。",
+ "maps-distance-par-unit": "距離を表示する単位です。",
+ "maps-finddestination-par-location": "最初に表示される場所です。",
+ "maps-finddestination-par-distance": "移動距離です。",
+ "maps-geodistance-par-location1": "距離を計測する2点のうちの第1地点",
+ "maps-geodistance-par-unit": "距離を出力する単位です。",
+ "maps-displaymap-par-coordinates": "地図に表示する 1 か所以上の場所です。これらの場所にはマーカーが付きます。",
+ "maps-displaymap-par-visitedicon": "元のマーカー アイコンがクリックされた後にマーカー アイコンに使用される画像のファイル名",
+ "maps-displaymap-par-label": "ラベルを設定していないマーカーに対して必ずポップアップ表示する、文字列を設定できます。",
+ "maps-displaymap-par-circles": "表示する円形",
+ "maps-displaymap-par-lines": "表示する線",
+ "maps-displaymap-par-maxzoom": "最大ズーム レベル",
+ "maps-displaymap-par-minzoom": "最小ズーム レベル",
+ "maps-displaymap-par-polygons": "表示する多角形",
+ "maps-displaymap-par-rectangles": "表示する矩形",
+ "maps-displaymap-par-wmsoverlay": "WMS オーバーレイを使用",
+ "maps-displaymap-par-geojson": "GeoJSONデータがあるファイルのURLまたはページ名",
+ "maps-fullscreen-button": "全画面表示を切り替え",
+ "maps-fullscreen-button-tooltip": "地図の表示を全画面または埋め込みに切り替えます。",
+ "validation-error-invalid-location": "引数「$1」には有効な場所を指定してください。",
+ "validation-error-invalid-locations": "引数「$1」には有効な場所を 1 つ以上指定してください。",
+ "validation-error-invalid-width": "引数「$1」には有効な幅を指定してください。",
+ "validation-error-invalid-height": "引数「$1」には有効な高さを指定してください。",
+ "validation-error-invalid-distance": "引数「$1」には有効な距離を指定してください。",
+ "validation-error-invalid-distances": "引数「$1」には有効な距離を 1 つ以上指定してください。",
+ "validation-error-invalid-image": "引数「$1」には有効な画像を指定してください。",
+ "validation-error-invalid-images": "引数「$1」には有効な画像を 1 つ以上指定してください。",
+ "validation-error-invalid-goverlay": "引数「$1」には有効なオーバーレイを指定してください。",
+ "validation-error-invalid-goverlays": "引数「$1」には有効なオーバーレイを 1 つ以上指定してください。",
+ "maps-abb-north": "北",
+ "maps-abb-east": "東",
+ "maps-abb-south": "南",
+ "maps-abb-west": "西",
+ "maps-latitude": "緯度:",
+ "maps-longitude": "経度:",
+ "maps-invalid-coordinates": "値 $1 は座標の有効な組み合わせとして認識されませんでした。",
+ "maps_coordinates_missing": "地図に座標が指定されていません。",
+ "maps_geocoding_failed": "以下の{{PLURAL:$2|住所}}を座標に変換できませんでした: $1",
+ "maps_geocoding_failed_for": "指定された{{PLURAL:$2|住所|複数の住所}}の座標への変換に失敗したため、それらを地図から除外して表示します。$1",
+ "maps_unrecognized_coords": "以下の{{PLURAL:$2|座標}}を認識できませんでした: $1",
+ "maps_unrecognized_coords_for": "以下の{{PLURAL:$2|座標}}を認識できなかったため、地図に表示して{{PLURAL:$2|いません}}:\n$1",
+ "maps_map_cannot_be_displayed": "地図を表示できません。",
+ "maps-geocoder-not-available": "地図のジオコーディング機能は利用できません。指定した位置をジオコーディングできません。",
+ "maps_googlemaps3": "Google マップ v3",
+ "maps-leaflet-par-layers": "レイヤー選択機能で利用できるレイヤー。地図を読み込んだとき1番目のレイヤーを表示します。",
+ "maps-leaflet-par-overlaylayers": "地図を読み込むと表示されるオーバーレイのレイヤー。",
+ "maps_click_to_activate": "クリックして地図をアクティブに",
+ "maps_centred_on": "地図の中心は $1、$2。",
+ "maps-par-searchmarkers": "地図の埋め込みフィールドを使い、特定のマーカーの検索を行います。",
+ "maps-par-zoom": "地図の拡大率。マーカーを設定した地図の場合、すべてのマーカーを表示できる最大の拡大率を既定で選びます。",
+ "maps-par-centre": "地図の中心にしたい場所",
+ "maps-par-enable-fullscreen": "全画面表示のボタンを有効にする",
+ "maps-par-kml": "地図に読み込む KML ファイルです。",
+ "maps-par-markercluster": "近接する複数のマーカーを1点に統合できます",
+ "maps-googlemaps3-incompatbrowser": "あなたのブラウザーは Google マップ v3 と互換性がありません。",
+ "maps-googlemaps3-par-type": "最初に表示する地図の種類です。",
+ "maps-googlemaps3-par-types": "種類コントロールで利用できる、地図の種類です。",
+ "maps-googlemaps3-par-layers": "地図に読み込む特別なレイヤーです。",
+ "maps-googlemaps3-par-controls": "地図上に配置するコントロールです。",
+ "maps-googlemaps3-par-zoomstyle": "ズーム コントロールのスタイルです。",
+ "maps-googlemaps3-par-typestyle": "種類コントロールのスタイルです。",
+ "maps-googlemaps3-par-kmlrezoom": "KMLレイヤーを読み込むとマップを再度ズームし直します。",
+ "mapeditor": "地図の編集",
+ "specialpages-group-maps": "地図",
+ "mapeditor-parser-error": "メタデータの構文解析でエラーが発生しました。利用者の入力を無視しています。",
+ "mapeditor-none-text": "なし",
+ "mapeditor-done-button": "完了",
+ "mapeditor-remove-button": "除去",
+ "mapeditor-import-button2": "取り込み",
+ "mapeditor-export-button": "ウィキコードに書き出し",
+ "mapeditor-import-button": "ウィキコードから取り込み",
+ "mapeditor-select-button": "この多角形を選択",
+ "mapeditor-mapparam-button": "地図のパラメーターを編集",
+ "mapeditor-clear-button": "地図を消去",
+ "mapeditor-code-title": "ウィキコード",
+ "mapeditor-import-title": "ウィキコードの取り込み",
+ "mapeditor-form-title": "詳細を編集",
+ "mapeditor-link-title-switcher-popup-text": "テキスト付きポップアップ",
+ "mapeditor-link-title-switcher-link-text": "リンク",
+ "mapeditor-form-field-title": "タイトル",
+ "mapeditor-form-field-text": "テキスト",
+ "mapeditor-form-field-link": "リンク",
+ "mapeditor-form-field-icon": "アイコン",
+ "mapeditor-form-field-group": "グループ",
+ "mapeditor-form-field-inlinelabel": "インライン ラベル",
+ "mapeditor-form-field-strokecolor": "線の色",
+ "mapeditor-form-field-strokeopacity": "線の不透明度",
+ "mapeditor-form-field-strokeweight": "線幅",
+ "mapeditor-form-field-fillcolor": "塗りつぶしの色",
+ "mapeditor-form-field-fillopcaity": "塗りつぶしの不透明度",
+ "mapeditor-form-field-showonhover": "ホバー時のみ表示",
+ "mapeditor-mapparam-title": "地図のパラメーターの編集",
+ "mapeditor-mapparam-defoption": "-パラメーターを選択-",
+ "mapeditor-imageoverlay-button": "画像オーバーレイを追加",
+ "mapeditor-form-field-image": "画像",
+ "mapeditor-imageoverlay-title": "画像オーバーレイの詳細",
+ "mapeditor-form-field-visitedicon": "訪問済みアイコン",
+ "semanticmaps-unrecognizeddistance": "値$1は有効な距離ではありません。",
+ "semanticmaps-kml-link": "KMLファイルを閲覧",
+ "semanticmaps-default-kml-pagelink": "ページ$1を表示",
+ "semanticmaps-latitude": "緯度: $1",
+ "semanticmaps-longitude": "経度: $1",
+ "semanticmaps-altitude": "高度: $1",
+ "semanticmaps-forminput-locations": "場所",
+ "semanticmaps-par-staticlocations": "問い合わせたデータと共に地図に追加する場所の列挙です。display_points と同様に、区切り文字としてチルダ「~」を使用して、場所ごとにタイトル、説明、アイコンを追加できます。",
+ "semanticmaps-par-showtitle": "マーカーの情報ウィンドウのタイトルを表示するかどうか。情報ウィンドウのコンテンツをフォーマットするためにテンプレートを使用するとき、これを無効にすると便利です。",
+ "semanticmaps-par-hidenamespace": "マーカー情報ウィンドウに名前空間名を表示する",
+ "semanticmaps-par-centre": "地図の中心。提供されていないときは、自動的に地図上のすべてのマーカーを表示するための最適な中心が選択されます。",
+ "semanticmaps-par-template": "情報ウィンドウのコンテンツの整形に使用するテンプレートです。",
+ "semanticmaps-par-geocodecontrol": "ジオコーディングコントロールを表示します。",
+ "semanticmaps-par-activeicon": "アクティブなページがクエリ結果と等しい場合に、デフォルトのアイコンの代わりに表示されるアイコン",
+ "semanticmaps-par-pagelabel": "「はい」に設定すると、マーカーの緯度経度を含むページにリンクされた「インライン ラベル」がすべてのマーカーに付きます。",
+ "semanticmaps-par-userparam": "テンプレートを使用している場合に、各テンプレート呼出しに渡す値",
+ "semanticmaps-kml-text": "各ページに関連付けられたテキストです。クエリに追加的なプロパティがある場合は上書きされます。",
+ "semanticmaps-kml-title": "結果の既定のタイトル",
+ "semanticmaps-kml-linkabsolute": "リンクは絶対表記 (= 相対表記の対義語) にしてください。",
+ "semanticmaps-kml-pagelinktext": "ページへのリンクに使用するテキスト ($1 はページ名に置換される)",
+ "semanticmaps-shapes-improperformat": "$1 を不適切な形式に整形しようとしました。整形の説明文書を参照してください。",
+ "semanticmaps-shapes-missingshape": "$1 の図形が見つかりません。利用できる図形について説明文書を参照してください。",
+ "validator-type-mapsimageoverlay": "画像オーバーレイ",
+ "validator-type-mapsimageoverlay-list": "画像オーバーレイの一覧",
+ "validator-type-mapslocation-list": "位置の一覧",
+ "validator-type-mapspolygon": "地図ポリゴン",
+ "validator-type-mapspolygon-list": "地図ポリゴンの一覧",
+ "validator-type-jsonfile": "テキスト"
+}
diff --git a/www/wiki/extensions/Maps/i18n/jv.json b/www/wiki/extensions/Maps/i18n/jv.json
new file mode 100644
index 00000000..6581003b
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/jv.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "L",
+ "maps-abb-east": "W",
+ "maps-abb-south": "Kdl",
+ "maps-abb-west": "Kln",
+ "maps-latitude": "Latituda:",
+ "maps-longitude": "Longituda:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ka.json b/www/wiki/extensions/Maps/i18n/ka.json
new file mode 100644
index 00000000..13a82651
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ka.json
@@ -0,0 +1,75 @@
+{
+ "@metadata": {
+ "authors": [
+ "David1010",
+ "Temuri rajavi"
+ ]
+ },
+ "right-geocode": "გეოკოდირება",
+ "maps_map": "რუკა",
+ "maps-loading-map": "იტვირთება რუკა...",
+ "maps-load-failed": "რუკის ჩატვირთვა შეუძლებელია!",
+ "maps-markers": "ნიშნები",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "ნიშნების ფილტრი",
+ "maps-others": "სხვები",
+ "maps-ns-layer": "ფენა",
+ "maps-ns-layer-talk": "ფენის განხილვა",
+ "maps-layer-property": "თვისება",
+ "maps-layer-value": "მნიშვნელობა",
+ "maps-layer-errors": "შეცდომები",
+ "validation-error-invalid-layer": "პარამეტრი $1 უნდა იყოს კორექტული ფენა.",
+ "validation-error-invalid-layers": "პარამეტრი $1 უნდა იყოს ერთი ან მეტი კორექტული ფენა.",
+ "maps-layer-of-type": "$1 ტიპის ფენა",
+ "maps-finddestination-par-location": "საწყისი მდებარეობა.",
+ "maps-finddestination-par-bearing": "საწყისი მიმართულება.",
+ "maps-finddestination-par-distance": "სამოგზაურო მანძილი.",
+ "maps-geocode-par-location": "მისამართი რომლის გეოკოდირებაც გსურთ.",
+ "maps-displaymap-par-maxzoom": "გადიდების მაქსიმალური დონე",
+ "maps-displaymap-par-minzoom": "შემცირების მაქსიმალური დონე",
+ "validation-error-invalid-location": "პარამეტრი $1 უნდა იყოს ნამდვილი მდებარეობის.",
+ "validation-error-invalid-locations": "პარამეტრი $1 უნდა შეიცავდეს ერთ ან რამდენიმე ნამდვილ მდებარეობას.",
+ "validation-error-invalid-width": "პარამეტრი $1 უნდა იყოს ნამდვილი სიგანის.",
+ "validation-error-invalid-height": "პარამეტრი $1 უნდა იყოს ნამდვილი სიმაღლის.",
+ "validation-error-invalid-distance": "პარამეტრი $1 უნდა იყოს ნამდვილი მანძილი.",
+ "validation-error-invalid-distances": "პარამეტრი $1 უნდა შეიცავდეს ერთ ან რამდენიმე ნამდვილ მანძილს.",
+ "validation-error-invalid-image": "პარამეტრი $1 უნდა იყოს ნამდვილი სურათი.",
+ "validation-error-invalid-images": "პარამეტრი $1 უნდა იყოს ერთი ან მეტი ნამდვილი სურათი.",
+ "maps-abb-north": "ჩ",
+ "maps-abb-east": "ა",
+ "maps-abb-south": "ს",
+ "maps-abb-west": "დ",
+ "maps-latitude": "განედი:",
+ "maps-longitude": "გრძედი:",
+ "maps_coordinates_missing": "რუკის კოორდინატები არ არის მითითებული.",
+ "maps_click_to_activate": "დააჭირეთ რუკის გასააქტიურებლად",
+ "maps_centred_on": "რუკის ცენტრი — $1, $2.",
+ "maps-googlemaps3-incompatbrowser": "თქვენი ბრაუზერი არ არის თავსებადი Google Maps v3-თან.",
+ "maps-googlemaps3-par-poi": "ღირსშესანიშნაობების ჩვენება.",
+ "mapeditor": "რუკის რედაქტორი",
+ "specialpages-group-maps": "რუკები",
+ "mapeditor-none-text": "არა",
+ "mapeditor-done-button": "გაკეთდა",
+ "mapeditor-remove-button": "წაშლა",
+ "mapeditor-import-button2": "იმპორტი",
+ "mapeditor-clear-button": "რუკის გასუფთავება",
+ "mapeditor-code-title": "ვიკი კოდი",
+ "mapeditor-form-title": "დეტალების რედაქტირება",
+ "mapeditor-link-title-switcher-link-text": "ბმული",
+ "mapeditor-form-field-title": "სათაური",
+ "mapeditor-form-field-text": "ტექსტი",
+ "mapeditor-form-field-link": "ბმული",
+ "mapeditor-form-field-icon": "ხატულა",
+ "mapeditor-form-field-group": "ჯგუფი",
+ "mapeditor-form-field-showonhover": "მხოლოდ მიტანისას ჩვენება",
+ "mapeditor-mapparam-title": "რუკის პარამეტრების რედაქტირება",
+ "mapeditor-mapparam-defoption": "-აირჩიეთ პარამეტრი-",
+ "mapeditor-form-field-image": "სურათი",
+ "semanticmaps-kml-link": "KML ფაილის ხილვა",
+ "semanticmaps-default-kml-pagelink": "გვერდი $1 ხილვა",
+ "semanticmaps-latitude": "განედი: $1",
+ "semanticmaps-longitude": "გრძედი: $1",
+ "semanticmaps-altitude": "სიმაღლე: $1",
+ "semanticmaps-forminput-locations": "მდებარეობები",
+ "semanticmaps-kml-title": "საწყისი სათაური შედეგებისათვის"
+}
diff --git a/www/wiki/extensions/Maps/i18n/km.json b/www/wiki/extensions/Maps/i18n/km.json
new file mode 100644
index 00000000..c5eb0860
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/km.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "គីមស៊្រុន"
+ ]
+ },
+ "maps_map": "ផែនទី",
+ "maps-loading-map": "កំពុងផ្ទុកផែនទី...",
+ "maps-load-failed": "ផ្ទុកផែនទីមិនបានសម្រេចទេ!",
+ "maps-markers": "សញ្ញាសម្គាល់",
+ "maps-others": "ផ្សេងទៀត",
+ "maps-abb-north": "ជ",
+ "maps-abb-east": "ក",
+ "maps-abb-south": "ត",
+ "maps-abb-west": "ល",
+ "maps-latitude": "រយៈទទឹង៖",
+ "maps-longitude": "រយៈបណ្តោយ៖"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ko.json b/www/wiki/extensions/Maps/i18n/ko.json
new file mode 100644
index 00000000..b687427b
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ko.json
@@ -0,0 +1,208 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hym411",
+ "Jskang",
+ "Priviet",
+ "아라",
+ "Revi",
+ "Macofe",
+ "Ykhwong",
+ "Garam"
+ ]
+ },
+ "maps-desc": "위키 문서에 동적 지도를 넣고, 주소의 좌표화와 다른 지리적 작업을 할 수 있습니다",
+ "right-geocode": "좌표화",
+ "maps_map": "지도",
+ "maps-tracking-category": "지도를 지도 확장 기능으로 표시하는 문서",
+ "maps-loading-map": "지도를 불러오는 중...",
+ "maps-load-failed": "지도를 불러올 수 없습니다!",
+ "maps-markers": "표시",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "표시를 필터",
+ "maps-others": "기타",
+ "maps-kml-parsing-failed": "하나 이상의 KML 파일을 구문 분석하는 데 실패했습니다. 일반적으로 이것은 얻기 실패나 잘못된 형식의 XML이기 때문에 일어납니다.",
+ "maps-ns-layer": "레이어",
+ "maps-ns-layer-talk": "레이어 토론",
+ "maps-layer-property": "속성",
+ "maps-layer-value": "값",
+ "maps-layer-errors": "오류",
+ "maps-layerdef-invalid": "유효하지 않은 정의{{PLURAL:$1|}}",
+ "maps-layerdef-invalid-fatal": "치명적으로 잘못된 정의",
+ "maps-layerdef-wrong-namespace": "레이어 정의가 \"$1\" 이름공간의 문서에만 유효하지 않습니다",
+ "maps-layerdef-equal-layer-name": "같은 레이어 문서 안에서 레이어 이름은 고유해야 합니다. \"$1\"은 이미 다른 레이어의 이름으로 사용되고 있습니다.",
+ "maps-layerpage-usage": "\"$1\" 레이어를 사용하는 지도와 문서",
+ "maps-layerpage-nousage": "현재 이 레이어를 사용하는 문서가 없습니다.",
+ "maps-error-invalid-layertype": "\"$1\" 레이어 종류가 없습니다. {{PLURAL:$3|다음 종류}}만 지원합니다: $2",
+ "maps-error-no-layertype": "레이어 종류를 지정해야 합니다. {{PLURAL:$2|다음 종류만|다음 종류를}} 지원합니다: $1",
+ "validation-error-invalid-layer": "$1 변수는 올바른 레이어여야 합니다.",
+ "validation-error-invalid-layers": "$1 변수는 하나 이상의 올바른 레이어여야 합니다.",
+ "validation-error-no-non-numeric": "\"$1\" 매개변수는 숫자를 포함하지 않는 문자열이어야 합니다.",
+ "validation-error-no-non-numerics": "\"$1\" 매개변수는 하나 또는 그 이상의 숫자가 아닌 문자열이어야 합니다.",
+ "maps-layer-of-type": "$1 종류의 레이어",
+ "maps-layer-of-type-and-name": "\"$1\" 형식의 \"$2\" 레이어",
+ "maps-layer-type-supported-by": "이 레이어 유형은 {{PLURAL:$2|$1 매핑 서비스에서만 사용할 수 있습니다.|다음 매핑 서비스에서 사용할 수 있습니다: $1}}",
+ "maps-coordinates-description": "지원되는 좌표 형식간에 서로 변환하는 파서 훅입니다.",
+ "maps-displaymap-description": "지도에 위키 정의한 표시 없이 지리적 지도를 표시합니다.",
+ "maps-distance-description": "다른 단위를 사용하여 해당하는 특정 지원되는 단위를 사용하여 거리를 변환합니다.",
+ "maps-finddestination-description": "주어진 시작점과 (지원되는 형식을 사용할 수 있습니다) 초기 방위, 거리로 목적지를 찾습니다.",
+ "maps-geocode-description": "주소, 즉 좌표 집합으로 인간이 읽을 수 있는 위치를 전환하는 좌표화를 활성화합니다. 매핑 서비스와 혼동하지 않아야 하는 여러 좌표화 서비스에 대한 지원이 있습니다.",
+ "maps-geodistance-description": "지원하는 형식으로 두 점 사이의 지리적 거리를 계산합니다.",
+ "maps-mapsdoc-description": "기본 값과 설명과 함께 지정된 좌표화 서비스에 대한 변수로 테이블을 표시합니다.",
+ "maps-layerdefinition-description": "지도기능으로 표시할 수 있는 사용자 정의 레이어를 설명하세요.",
+ "maps-mapsdoc-par-service": "변수 설명문서를 표시할 좌표화 서비스입니다.",
+ "maps-mapsdoc-par-language": "설명문을 표시할 언어입니다. 이러한 번역을 사용할 수 없으면 영어가 대신 사용됩니다.",
+ "maps-coordinates-par-location": "형식을 지정할 좌표입니다.",
+ "maps-coordinates-par-format": "죄표에 대한 대상 형식입니다.",
+ "maps-coordinates-par-directional": "좌표가 방향이 출력되어야 할 것인지를 나타냅니다.",
+ "maps-par-scrollwheelzoom": "마우스 스크롤링을 활성화하는 것이 좋은지의 여부를 표시합니다.",
+ "maps-distance-par-distance": "지정된 단위로 해당하는 변환할 거리입니다.",
+ "maps-distance-par-decimals": "결과 값에 사용할 최대 소수 자릿수입니다.",
+ "maps-distance-par-unit": "거리를 출력할 단위입니다.",
+ "maps-finddestination-par-location": "처음 위치입니다.",
+ "maps-finddestination-par-bearing": "초기 방위입니다.",
+ "maps-finddestination-par-distance": "이동 거리입니다.",
+ "maps-finddestination-par-format": "목적지를 출력할 형식입니다.",
+ "maps-finddestination-par-directional": "대상의 형식이 방향성이 있어야 할 것인지를 나타냅니다.",
+ "maps-geocode-par-location": "좌표화를 원하는 주소입니다.",
+ "maps-geocode-par-format": "결과 좌표에 대한 형식입니다.",
+ "maps-geocode-par-directional": "좌표가 방향이 출력되어야 할 것인지를 나타냅니다.",
+ "maps-geodistance-par-location1": "집합에서 사이의 거리를 계산하는 첫 번째 지점입니다.",
+ "maps-geodistance-par-location2": "집합에서 사이의 거리를 계산하는 두 번째 지점입니다.",
+ "maps-geodistance-par-unit": "거리를 출력할 단위입니다.",
+ "maps-geodistance-par-decimals": "결과 값에 사용할 최대 소수 자릿수입니다.",
+ "maps-displaymap-par-mappingservice": "지도를 생성하는데 사용될 매핑 서비스를 설정할 수 있습니다.",
+ "maps-displaymap-par-coordinates": "지도에 표시할 하나 이상의 위치입니다. 표시로 표시됩니다.",
+ "maps-displaymap-par-visitedicon": "원래의 마커가 클릭된 후 마커 아이콘에 사용될 영상 파일 이름입니다",
+ "maps-displaymap-par-zoom": "지도의 확대 수준을 설정할 수 있습니다.\n제공하지 않고 여러 표시가 지도에 존재하지 않으면 설정한 기본값이 아닌 최고의 맞춤 확대로 설정됩니다.",
+ "maps-displaymap-par-centre": "display_point에 대한 지도의 중심 좌표를 설정할 수 있습니다.\n주소와 좌표를 모두 사용할 수 있습니다.\n이 속성이 제공되어 있지 않은 경우 지도는 제공한 표시에 대한 자체 중심에 있거나 제공한 표시 사이에 있습니다.",
+ "maps-displaymap-par-title": "특정 제목이 없는 모든 표시의 팝업에 보여줄 텍스트를 설정할 수 있습니다.\n레이블과 함께 사용하면 제목은 굵고 밑줄이 그어집니다.",
+ "maps-displaymap-par-label": "특정 레이블이 없는 마든 표시의 팝업에 보여줄 텍스트를 설정할 수 있습니다.",
+ "maps-displaymap-par-icon": "모든 표시에 사용하는 아이콘을 설정할 수 있게 합니다.",
+ "maps-displaymap-par-circles": "표시할 동그라미",
+ "maps-displaymap-par-copycoords": "좌표를 복사한 위치를 클릭할 때 대화상자를 표시합니다.",
+ "maps-displaymap-par-lines": "표시할 선",
+ "maps-displaymap-par-maxzoom": "최대 확대 수준",
+ "maps-displaymap-par-minzoom": "최소 확대 수준",
+ "maps-displaymap-par-polygons": "표시할 다각형",
+ "maps-displaymap-par-rectangles": "표시할 직사각형",
+ "maps-displaymap-par-static": "지도를 정적으로 만듭니다.",
+ "maps-displaymap-par-wmsoverlay": "WMS 중첩 사용",
+ "maps-displaymap-par-geojson": "GeoJSON 데이터가 포함된 파일의 URL 또는 문서 이름",
+ "maps-fullscreen-button": "전체화면으로 전환",
+ "maps-fullscreen-button-tooltip": "지도를 전체 화면 또는 삽입된 형태로 보기",
+ "validation-error-invalid-location": "$1 변수는 올바른 위치여야 합니다.",
+ "validation-error-invalid-locations": "$1 변수는 하나 이상의 올바른 위치여야 합니다.",
+ "validation-error-invalid-width": "$1 변수는 올바른 너비여야 합니다.",
+ "validation-error-invalid-height": "$1 변수는 올바른 높이여야 합니다.",
+ "validation-error-invalid-distance": "$1 변수는 올바른 거리여야 합니다.",
+ "validation-error-invalid-distances": "$1 변수는 하나 이상의 올바른 거리여야 합니다.",
+ "validation-error-invalid-image": "$1 변수는 올바른 그림이어야 합니다.",
+ "validation-error-invalid-images": "$1 변수는 하나 이상의 올바른 그림이어야 합니다.",
+ "validation-error-invalid-goverlay": "$1 변수는 올바른 오버레이여야 합니다.",
+ "validation-error-invalid-goverlays": "$1 변수는 하나 이상의 올바른 오버레이여야 합니다.",
+ "maps-abb-north": "북",
+ "maps-abb-east": "동",
+ "maps-abb-south": "남",
+ "maps-abb-west": "서",
+ "maps-latitude": "위도:",
+ "maps-longitude": "경도:",
+ "maps-invalid-coordinates": "$1 값은 죄표의 올바른 값으로 인식되지 않았습니다.",
+ "maps_coordinates_missing": "지도에 제공한 좌표가 없습니다.",
+ "maps_geocoding_failed": "다음 {{PLURAL:$2|주소}}는 좌표화할 수 없습니다: $1.",
+ "maps_geocoding_failed_for": "다음 {{PLURAL:$2|주소}}는 좌표화할 수 없고 지도에서 생략{{PLURAL:$2|되었습니다}}:\n$1",
+ "maps_unrecognized_coords": "다음 {{PLURAL:$2|좌표}}는 인식할 수 없습니다: $1.",
+ "maps_unrecognized_coords_for": "다음 {{PLURAL:$2|좌표}}는 인식할 수 없고 지도에서 생략{{PLURAL:$2|되었습니다}}:\n$1",
+ "maps_map_cannot_be_displayed": "지도를 보여줄 수 없습니다.",
+ "maps-geocoder-not-available": "지도의 좌표화 기능을 사용할 수 없습니다. 당신의 위치는 좌표화할 수 없습니다.",
+ "maps_googlemaps3": "Google 지도 v3",
+ "maps-leaflet-par-layers": "레이서 선택기에서 사용할 수 있는 레이어입니다. 첫 레이어는 지도를 불러올 때 보여줍니다.",
+ "maps_click_to_activate": "지도를 활성화하려면 클릭하세요",
+ "maps_centred_on": "$1, $2 지도 중심",
+ "maps-par-mappingservice": "지도를 생성하는데 사용될 매핑 서비스를 설정할 수 있습니다.",
+ "maps-par-resizable": "지도의 오른쪽 아래 모서리에 드래그하여 지도 크기를 조절할 수 있도록 합니다.",
+ "maps-par-zoom": "지도에 대한 확대 수준입니다. 표시로 된 지도에 대해서는 여전히 모든 표시를 보여주는 수준으로 대부분 확대되도록 기본 설정됩니다.",
+ "maps-par-width": "지도의 너비을 설정할 수 있습니다. 기본적으로 픽셀은 단위로 간주되지만, 명시적으로 이러한 단위 중 하나를 지정할 수 있습니다: px, ex, em, %.",
+ "maps-par-height": "지도의 높이를 설정할 수 있습니다. 기본적으로 픽셀은 단위로 간주되지만, 명시적으로 이러한 단위 중 하나를 지정할 수 있습니다: px, ex, em, %.",
+ "maps-par-centre": "지도의 중심으로 할 위치",
+ "maps-par-enable-fullscreen": "전체 화면 버튼 활성화",
+ "maps-par-kml": "지도에 불러올 KML 파일입니다.",
+ "maps-googlemaps3-incompatbrowser": "브라우저는 Google 지도 v3와 호환되지 않습니다.",
+ "maps-googlemaps3-par-type": "처음 보여줄 지도 종류입니다.",
+ "maps-googlemaps3-par-types": "종류 컨트롤을 통해 사용할 수 있는 지도 종류입니다.",
+ "maps-googlemaps3-par-layers": "지도에 불러오는 특수 레이어입니다.",
+ "maps-googlemaps3-par-controls": "지도에 놓을 컨트롤입니다.",
+ "maps-googlemaps3-par-zoomstyle": "줌 컨트롤의 스타일입니다.",
+ "maps-googlemaps3-par-typestyle": "종류 컨트롤의 스타일입니다.",
+ "maps-googlemaps3-par-autoinfowindows": "문서를 불러오고 나서 모든 정보 창을 자동으로 엽니다.",
+ "maps-googlemaps3-par-gkml": "지도에 불러올 Google이 호스트하는 KML 파일입니다.",
+ "maps-googlemaps3-par-kmlrezoom": "KML 레이어를 불러오고 나서 지도를 다시 확대합니다.",
+ "maps-googlemaps3-par-poi": "관심 지점을 보여줍니다.",
+ "mapeditor": "지도 편집기",
+ "specialpages-group-maps": "지도",
+ "mapeditor-parser-error": "메타데이터를 구문 분석하는 동안 오류가 발생했습니다. 사용자 입력을 무시합니다.",
+ "mapeditor-none-text": "없음",
+ "mapeditor-done-button": "완료",
+ "mapeditor-remove-button": "제거",
+ "mapeditor-import-button2": "가져오기",
+ "mapeditor-export-button": "위키 코드로 내보내기",
+ "mapeditor-import-button": "위키 코드에서 가져오기",
+ "mapeditor-select-button": "이 다각형 선택",
+ "mapeditor-mapparam-button": "지도 변수 편집",
+ "mapeditor-clear-button": "지도 지우기",
+ "mapeditor-code-title": "위키 코드",
+ "mapeditor-import-title": "위키 코드 가져오기",
+ "mapeditor-import-note": "파서는 위키 코드에 매우 엄격한 형식을 예상하는 것에 주의하세요. 여기에 입력한 코드는 내보내기 기능으로 출력되는 코드와 일치해야 합니다.",
+ "mapeditor-form-title": "자세한 사항 편집",
+ "mapeditor-link-title-switcher-popup-text": "텍스트 팝업",
+ "mapeditor-link-title-switcher-link-text": "링크",
+ "mapeditor-form-field-title": "제목",
+ "mapeditor-form-field-text": "텍스트",
+ "mapeditor-form-field-link": "링크",
+ "mapeditor-form-field-icon": "아이콘",
+ "mapeditor-form-field-group": "그룹",
+ "mapeditor-form-field-inlinelabel": "레이블 안쪽",
+ "mapeditor-form-field-strokecolor": "선 색",
+ "mapeditor-form-field-strokeopacity": "선 투명토",
+ "mapeditor-form-field-strokeweight": "선 굵기",
+ "mapeditor-form-field-fillcolor": "채우기 색",
+ "mapeditor-form-field-fillopcaity": "채우기 투명도",
+ "mapeditor-form-field-showonhover": "가리켰을 때에만 보이기",
+ "mapeditor-mapparam-title": "지도 변수 편집",
+ "mapeditor-mapparam-defoption": "-변수 선택-",
+ "mapeditor-imageoverlay-button": "그림 배치 추가",
+ "mapeditor-form-field-image": "그림",
+ "mapeditor-imageoverlay-title": "그림 배치 자세한 사항",
+ "mapeditor-form-field-visitedicon": "방문한 아이콘",
+ "semanticmaps-unrecognizeddistance": "$1 값은 올바른 거리가 아닙니다.",
+ "semanticmaps-kml-link": "KML 파일 보기",
+ "semanticmaps-default-kml-pagelink": "$1 문서 보기",
+ "semanticmaps-latitude": "위도: $1",
+ "semanticmaps-longitude": "경도: $1",
+ "semanticmaps-altitude": "고도: $1",
+ "semanticmaps-forminput-locations": "위치",
+ "semanticmaps-par-staticlocations": "쿼리된 데이터와 함께 지도를 추가하는 위치의 목록입니다. display_points와 같이, 구분자로 물결표 \"~\"를 사용하여 위치마다 제목과 설명, 아이콘을 추가할 수 있습니다.",
+ "semanticmaps-par-showtitle": "표시 정보 창에서 제목에 보여주거나 보여주지 않습니다. 정보 창 내용의 형식에 틀을 사용할 때 이를 비활성화하면 편리합니다.",
+ "semanticmaps-par-hidenamespace": "표시 정보 창의 이름공간 제목 보이기",
+ "semanticmaps-par-centre": "지도의 가운데입니다. 제공하지 않으면, 지도는 자동으로 지도에서 모든 표시를 표시할 최적의 가운데를 선택합니다.",
+ "semanticmaps-par-template": "정보 창 내용을 형식에 사용하는 틀입니다.",
+ "semanticmaps-par-geocodecontrol": "좌표화 컨트롤을 보여줍니다.",
+ "semanticmaps-par-activeicon": "활성화된 문서는 쿼리 결과와 같을 때 아이콘이 기본값 표시기 대신에 표시해야 합니다",
+ "semanticmaps-par-pagelabel": "\"yes\"로 설정하면, 모든 마커가 마커의 좌표를 포함하는 문서로 연결된 링크와 \"inlineLabel\"을 가집니다.",
+ "semanticmaps-par-userparam": "틀이 사용되는 경우 각 틀 호출에 전달되는 값입니다",
+ "semanticmaps-kml-text": "각 문서와 연관된 텍스트입니다. 추가적인 쿼리된 속성이 있으면 덮어씁니다.",
+ "semanticmaps-kml-title": "결과에 대한 기본 제목",
+ "semanticmaps-kml-linkabsolute": "링크는 (상대적와 반대인) 절대적이어야 합니다",
+ "semanticmaps-kml-pagelinktext": "$1 문서는 문서 제목으로 바뀔 문서의 링크에 사용하는 텍스트",
+ "semanticmaps-shapes-improperformat": "$1의 부적절한 형식입니다. 형식에 대해서는 설명서를 참조하세요.",
+ "semanticmaps-shapes-missingshape": "$1에 대한 모양을 찾을 수 없습니다. 사용할 수 있는 모양에 대해서는 설명서를 참조하세요",
+ "validator-type-mapscircle-list": "원 목록",
+ "validator-type-mapsimageoverlay": "영상 중첩",
+ "validator-type-mapsimageoverlay-list": "영상 중첩 목록",
+ "validator-type-mapsline-list": "선 목록",
+ "validator-type-mapslocation": "지리적 위치",
+ "validator-type-mapslocation-list": "위치 목록",
+ "validator-type-mapsrectangle-list": "직사각형 목록",
+ "validator-type-wmsoverlay": "웹 지도 서비스 오버레이",
+ "validator-type-jsonfile": "텍스트"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ksh.json b/www/wiki/extensions/Maps/i18n/ksh.json
new file mode 100644
index 00000000..943d2e78
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ksh.json
@@ -0,0 +1,69 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Määt et müjjelesch, bewääschlesche Landkaate en Sigge em Wiki aanzezeije, Addräße en Koodinaate op de Ääd ömzerääschne, un ander esu en Funxjuhne",
+ "maps_map": "Kaat",
+ "maps-loading-map": "Mer sen en Kaat aam lahde&nbsp;…",
+ "maps-markers": "Makeeronge",
+ "maps-searchmarkers-text": "Makkehronge ußsöhke",
+ "maps-others": "sönß wää",
+ "maps-layer-property": "Eijeschaff",
+ "maps-layer-value": "Wäät",
+ "maps-layer-errors": "Fähler",
+ "maps-distance-par-unit": "De Einheit för der Afschtand dren ußzejävve.",
+ "maps-displaymap-par-coordinates": "Dä Plaz, dä aanfänglesch en de Medde vun dä Kaat lijje sull.",
+ "maps-displaymap-par-visitedicon": "Dä Nahme vun dä Dattei med enem Belldsche, wat jezeisch weed, wann obb et orschprönglesche Belldsche jeklek woode es.",
+ "maps-displaymap-par-icon": "Määd et müjjelesch, e Minni_Belldsche faßzelääje, waoh met all de Makeerunge jezeish wääde.",
+ "maps-displaymap-par-copycoords": "Zeisch e Finstersche, öm de Ko'odenahte om Johbus druß ze koppehre, wam_mer obb ene Plaz klek.",
+ "validation-error-invalid-location": "Dä Parameeter $1 mos ene jölteje Plaz sin.",
+ "validation-error-invalid-locations": "Dä Parameeter $1 moß eine jölteje Plaz udder an Aanzahl jöltijje Pläz sin.",
+ "validation-error-invalid-width": "Dä Parameeter $1 mos en jölteje Breedt sin.",
+ "validation-error-invalid-height": "Dä Parameeter $1 mos en jölteje Hühde sin.",
+ "validation-error-invalid-distance": "Dä Parameeter $1 mos ene jölteje Affshtand sin.",
+ "validation-error-invalid-distances": "Dä Parameeter $1 moß eine jölteje Affshtand udder an Aanzahl jöltijje Affshtänd sin.",
+ "validation-error-invalid-image": "Dä Parameeter $1 mos e jöltesch Beld sin.",
+ "validation-error-invalid-images": "Dä Parameeter $1 moß ei jöltesch Beld udder an Aanzahl jöltijje Belder sin.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Breedt om Jlobus:",
+ "maps-longitude": "Längde om Jlobus:",
+ "maps-invalid-coordinates": "Dä Wäät $1 künne mer nit als ene Saz vun Koodinahte vershtonn.",
+ "maps_coordinates_missing": "Mer han kein Koodinaate för di Kaat.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Di Koodinaat|De Koodinaate|Kein Koodinaat}} om Jlobus för di {{PLURAL:$2|aanjejovve Adräß wohr|aanjejovve Adräße wohre|kein aanjejovve Adräß wohr}} Kappes: $1. Di Kaat künne mer su nit aanzeije.",
+ "maps_geocoding_failed_for": "De Koodinaate om Jlobus för {{PLURAL:$2|ein|paa|kein}} vun dä aanjejovve Adräße {{PLURAL:$2|es|wohre|Fähler!}} Kappes. Di {{PLURAL:$2|es|sin|Fähler!}} dröm nit op dä Kaat. De fottjelohße {{PLURAL:$2|es|sin|Fähler!}}: $1",
+ "maps_unrecognized_coords": "He di Koordinate kunnte mer nit verschtonn: $1.",
+ "maps_unrecognized_coords_for": "He di {{PLURAL:$2|Koordinat kunnt|Koordinate kunnte}} mer nit verschtonn un dröm {{PLURAL:$2|es|sin}} se nit en de Kaat opjenumme woode:\n$1",
+ "maps_map_cannot_be_displayed": "Di Kaat künne mer nit aanzeije.",
+ "maps_googlemaps3": "<i lang=\"en\">Google-Maps-v3</i>-Kaat",
+ "maps_click_to_activate": "Donn klecke, öm op di Kaat ze jonn",
+ "maps_centred_on": "De Kaat met $1, $2 en de Medde.",
+ "maps-par-markercluster": "Määd et müjjelesch, benaachbaate Makehronge zesamme ze faße.",
+ "maps-googlemaps3-par-imageoverlays": "Määd et müjjelesch, e Beld obb em aanjejovve Plaz op dä Kaat aanzeije ze lohße.",
+ "maps-googlemaps3-par-kmlrezoom": "Donn di Kaat norr_ens zoome, nohdäm de layers vum KLM jelaade sin.",
+ "semanticmaps-unrecognizeddistance": "Dä Wäät „$1“ es keine jölteje Afschtand.",
+ "semanticmaps-kml-link": "De KML-Dattei belooere",
+ "semanticmaps-kml": "Äxpoot als KML",
+ "semanticmaps-default-kml-pagelink": "De Sigg „$1“ belooere",
+ "semanticmaps-latitude": "Dä Breedejrad om Jloobos: $1",
+ "semanticmaps-longitude": "Dä Längejraad om Jloobos: $1",
+ "semanticmaps-altitude": "De Hühde: $1",
+ "semanticmaps-forminput-locations": "Oote",
+ "semanticmaps-par-staticlocations": "En Leß met Pläz, di zosamme met dä nohjefrochte Aanjabe op di Kaat sulle. Wi bei <code lang=\"en\">display_points</code> kam_mer ene Tittel, ene Täx doh zoh, un e Minni_Belldsche\nför jeede Plaz aanjävve, med enem Schlängelsche (~) doh zwesche.",
+ "semanticmaps-par-showtitle": "Donn en Övverschreff en däm Finster met Infomazjuhne övver de Makeerong aanzeije udder nit. De Övverschreff afzeschallde es öff joot, wam_mer en Schabloon nemmp för dä Enhallt vum Finster zerääsch ze possumenteere.",
+ "semanticmaps-par-hidenamespace": "Zeisch dä Name vum Appachtemang em marker info Finster udder nit.",
+ "semanticmaps-par-centre": "Der Meddelpunk vun dä Kaat. Wann keine aanjejovve_n_es jeiht dä automattesch op der optesche Meddelpunk vun all dä Makeerunge en dä Kaat.",
+ "semanticmaps-par-template": "En Schablohn för der Enhalt vum Finster met de Enfommazjuhne ze jeschtallte",
+ "semanticmaps-par-geocodecontrol": "Donn dat Bedeenelemänt aanzeije för de Ko'odinaate op de Ääd ze beärbeide",
+ "semanticmaps-kml-text": "Dä Täx, dä met jeder Sigg aanjezeisch weed. Wann extra Eijeschaffte afjefroocht wääde, kumme di schtatt däm Täx.",
+ "semanticmaps-kml-title": "Dä Schtandatttittel för wad eruß küt.",
+ "semanticmaps-kml-linkabsolute": "Sulle Lenks absoluud udder relatief sin?",
+ "semanticmaps-kml-pagelinktext": "Ene Täx, dä för Lenks op di Sigg jebuch weed. $1 schteiht dobei för dä Sigg ier Övverschreff.",
+ "semanticmaps-shapes-improperformat": "dat Fommaat för $1 paß nit. Loor em Handbooch noh de Fommaate.",
+ "semanticmaps-shapes-missingshape": "Mer han kein Forme för $1 jefonge. Loor en et Handbohch, doh schtonn de Forme dren."
+}
diff --git a/www/wiki/extensions/Maps/i18n/ku-latn.json b/www/wiki/extensions/Maps/i18n/ku-latn.json
new file mode 100644
index 00000000..bf1af05d
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ku-latn.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "George Animal"
+ ]
+ },
+ "maps_map": "Nexşe",
+ "mapeditor-link-title-switcher-link-text": "Girêdan",
+ "mapeditor-form-field-title": "Sernav",
+ "mapeditor-form-field-link": "Girêdan",
+ "mapeditor-form-field-group": "Kom",
+ "mapeditor-form-field-image": "Wêne"
+}
diff --git a/www/wiki/extensions/Maps/i18n/lad.json b/www/wiki/extensions/Maps/i18n/lad.json
new file mode 100644
index 00000000..8113e980
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/lad.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Universal Life"
+ ]
+ },
+ "maps_map": "Mapa",
+ "maps-loading-map": "Cargando la mapa...",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O"
+}
diff --git a/www/wiki/extensions/Maps/i18n/lb.json b/www/wiki/extensions/Maps/i18n/lb.json
new file mode 100644
index 00000000..387ab13a
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/lb.json
@@ -0,0 +1,123 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robby",
+ "Soued031",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Gëtt d'Méiglechkeet fir d'Date vun de Koordinaten op Kaarten a Geocode Adressen an aner geographesch Operatiounen ze weisen",
+ "right-geocode": "Geocode",
+ "action-geocode": "Geocoding op dëser Wiki maachen",
+ "maps_map": "Kaart",
+ "maps-loading-map": "D'Kaart gëtt gelueden…",
+ "maps-load-failed": "D'Kaart konnt net geluede ginn!",
+ "maps-markers": "Markéierungen",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Markéierunge fir Filteren",
+ "maps-others": "anerer",
+ "maps-layer-property": "Eegenschaft",
+ "maps-layer-value": "Wäert",
+ "maps-layer-errors": "Feeler",
+ "maps-layerdef-invalid": "Net valabel {{PLURAL:$1|Definitioun|Definitiounen}}",
+ "maps-layerdef-invalid-fatal": "Fatal net valabel Definitioun",
+ "maps-layer-of-type": "Layer vum Typ \"$1\"",
+ "maps-geodistance-description": "Déi geographesch Distanz tëscht zwéi Punkte berechnen, vun an an iergendeent vun den ënnerstëtzte Formater.",
+ "maps-mapsdoc-par-language": "D'Sprooch an där d'Dokumentatioun gewise gi soll. Wann déi Iwwersetzung net disponibel ass, da gëtt Englesch an där Plaz benotzt.",
+ "maps-coordinates-par-location": "D'Koordinaten déi Dir formatéiere wëllt.",
+ "maps-coordinates-par-format": "D'Zilformat vun de Koordinaten.",
+ "maps-distance-par-decimals": "Déi maximal Zuel vu Kommastellen déi am Resultat benotzt gi soll.",
+ "maps-distance-par-unit": "D'Eenheet fir d'Distanz.",
+ "maps-finddestination-par-location": "Déi initial Plaz.",
+ "maps-finddestination-par-distance": "D'Distanz vun der Rees.",
+ "maps-finddestination-par-format": "D'Format an deem d'Zil gewise soll ginn.",
+ "maps-geocode-par-location": "D'Adress déi Dir geocodéiere wëllt.",
+ "maps-geocode-par-format": "De Format fir d'Koordinaten.",
+ "maps-geodistance-par-location1": "Den éischte Punkt vun deem aus eng Distanz berechent gi soll.",
+ "maps-geodistance-par-unit": "D'Eenheet fir d'Distanz.",
+ "maps-geodistance-par-decimals": "Déi maximal Zuel vu Kommastellen déi am Resultat benotzt gi soll.",
+ "maps-displaymap-par-coordinates": "Déi Plaz op déi d'Kaart am Ufank zentréiert gëtt.",
+ "maps-displaymap-par-circles": "Kreesser fir ze weisen",
+ "maps-displaymap-par-lines": "Linne fir ze weisen",
+ "maps-displaymap-par-maxzoom": "De maximalen Niveau vum Zoom",
+ "maps-displaymap-par-minzoom": "De minimalen Niveau vum Zoom",
+ "maps-displaymap-par-polygons": "Polygonen fir ze weisen",
+ "maps-displaymap-par-rectangles": "Rechtecker fir ze weisen",
+ "maps-displaymap-par-static": "D'Kaart statesch maachen",
+ "validation-error-invalid-location": "Parameter $1 muss eng valabel Plaz sinn.",
+ "validation-error-invalid-locations": "Parameter $1 muss eng oder méi valabel Plaze sinn.",
+ "validation-error-invalid-width": "Parameter $1 muss eng valabel Breet sinn.",
+ "validation-error-invalid-height": "Parameter $1 muss eng valabel Héicht sinn.",
+ "validation-error-invalid-distance": "Parameter $1 muss eng valabel Distanz sinn.",
+ "validation-error-invalid-distances": "Parameter $1 muss eng oder méi valabel Distanze sinn.",
+ "validation-error-invalid-image": "Parameter $1 muss e valabelt Bild sinn.",
+ "validation-error-invalid-images": "Parameter $1 muss eent oder méi valabel Biller sinn.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Breedegrad:",
+ "maps-longitude": "Längtegrad:",
+ "maps-invalid-coordinates": "De Wäert $1 gouf net als valabel Set vu Koordinaten erkannt.",
+ "maps_coordinates_missing": "Et goufe keng Koordinate fir d'Kaart uginn.",
+ "maps_geocoding_failed": "Dës {{PLURAL:$2|Adress konnt|Adresse konnten}} net geocodéiert ginn: $1",
+ "maps_geocoding_failed_for": "Dës {{PLURAL:$2|Adress|Adresse}} konnten net geocodéiert ginn an {{PLURAL:$2|huet|hu}} missen op der Kaart ewechgelooss ginn:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Dëse Koordinate gouf|Dës Koordinate goufen}} net erkannt: $1",
+ "maps_unrecognized_coords_for": "Dës {{PLURAL:$2|Koordinate|Koordinate}} goufen net erkannt a vun der Kaart ignoréiert:\n$1",
+ "maps_map_cannot_be_displayed": "D'Kaart kann net gewise ginn.",
+ "maps-geocoder-not-available": "D'Funktioun vun der Geocodéierung vu Kaarten ass net disponibel. Äre Standuert konnt net geocodéiert ginn.",
+ "maps_leaflet": "Depliant",
+ "maps-leaflet-par-layers": "De Layer dee gewise gëtt wann d'Kaart geluede gëtt.",
+ "maps_click_to_activate": "Klickt fir d'kaart z'aktivéieren",
+ "maps_centred_on": "D'Kaart ass zentréiert op $1, $2",
+ "maps-par-enable-fullscreen": "'Fullscreen'-Knäppchen aschalten",
+ "maps-par-kml": "KML-Fichieren déi op d'Kaart musse geluede ginn.",
+ "maps-googlemaps3-incompatbrowser": "Äre Browser ass net mat Google Maps v3 kompatibel.",
+ "maps-googlemaps3-par-type": "Den Typ vu Kaart den am Ufank gewise gëtt.",
+ "maps-googlemaps3-par-autoinfowindows": "Automatesch all Fënstere mat Informatiounen opmaachen nodeem d'Säit geluede gouf.",
+ "maps-googlemaps3-par-poi": "Kuckeswäertes weisen",
+ "specialpages-group-maps": "Kaarten",
+ "mapeditor-none-text": "Keen",
+ "mapeditor-done-button": "Fäerdeg",
+ "mapeditor-remove-button": "Ewechhuelen",
+ "mapeditor-import-button2": "Importéieren",
+ "mapeditor-export-button": "A Wikicode exportéieren",
+ "mapeditor-mapparam-button": "Parametere vun der Kaart änneren",
+ "mapeditor-clear-button": "Kaart eidelmaachen",
+ "mapeditor-code-title": "Wikicode",
+ "mapeditor-import-title": "Wikicode importéieren",
+ "mapeditor-form-title": "Detailer änneren",
+ "mapeditor-link-title-switcher-popup-text": "Popup mat Text",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-group": "Grupp",
+ "mapeditor-form-field-fillcolor": "Faarf fir opzefëllen",
+ "mapeditor-form-field-showonhover": "Nëmme weise wann een driwwer fiert",
+ "mapeditor-mapparam-title": "Parametere vun der Kaart änneren",
+ "mapeditor-mapparam-defoption": "-Parameter eraussichen-",
+ "mapeditor-form-field-image": "Bild",
+ "semanticmaps-unrecognizeddistance": "De Wäert $1 ass keng valabel Distanz.",
+ "semanticmaps-kml-link": "KML-Fichier weisen",
+ "semanticmaps-default-kml-pagelink": "Säit $1 weisen",
+ "semanticmaps-latitude": "Breedegrad: $1",
+ "semanticmaps-longitude": "Längtegrad: $1",
+ "semanticmaps-altitude": "Héicht: $1",
+ "semanticmaps-forminput-locations": "Plazen",
+ "semanticmaps-kml-title": "De Standard-Titel fir Resultater",
+ "semanticmaps-kml-linkabsolute": "Solle Linken absolut sinn (am Géigesaz zu relativ)",
+ "validator-type-mapscircle": "Geographesche Krees",
+ "validator-type-mapscircle-list": "Lëscht vun de Kreesser",
+ "validator-type-mapsimageoverlay": "Bildiwwerlagerung",
+ "validator-type-mapsimageoverlay-list": "Lëscht vun de Bildiwwerlagerungen",
+ "validator-type-mapsline": "Geographesch Linn",
+ "validator-type-mapsline-list": "Lëscht vu Linnen",
+ "validator-type-mapslocation": "Geographesch Plaz",
+ "validator-type-mapslocation-list": "Lëscht vu Plazen",
+ "validator-type-mapsrectangle": "Geographesche Rechteck",
+ "validator-type-mapsrectangle-list": "Lëscht vun de Rechtecken",
+ "validator-type-mapspolygon": "Geographesche Polygon",
+ "validator-type-mapspolygon-list": "Lëscht vun de geographesche Polygonen",
+ "validator-type-jsonfile": "Text"
+}
diff --git a/www/wiki/extensions/Maps/i18n/lt.json b/www/wiki/extensions/Maps/i18n/lt.json
new file mode 100644
index 00000000..a54d50ee
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/lt.json
@@ -0,0 +1,119 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eitvys200",
+ "Hugo.arg",
+ "Aswanas",
+ "Zygimantus",
+ "Agne1992"
+ ]
+ },
+ "maps-desc": "Suteikia galimybę atvaizduoti koordinačių duomenis žemėlapiuose ir geografinio kodavimo adresus ([http://mapping.referata.com/wiki/Maps_examples demo]).\nKatrografavimo paslaugos pasiekiamos: $1",
+ "action-geocode": " šioje wiki atlikite geokodavimą",
+ "maps_map": "Žemėlapis",
+ "maps-loading-map": "Kraunamas žemėlapis ...",
+ "maps-load-failed": "Nepavyko įkelti žemėlapio!",
+ "maps-markers": "Žymekliai",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "kita",
+ "maps-ns-layer": "Sluoksnis",
+ "maps-ns-layer-talk": "Sluoksnio aptarimas",
+ "maps-layer-property": "Savybė",
+ "maps-layer-value": "Vertė",
+ "maps-layer-errors": "Klaidos",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Negalimas apibrėžimas|Negalimi apibrėžimai}}",
+ "maps-layerdef-invalid-fatal": "Galutinis negalimas apibrėžimas",
+ "maps-layerpage-usage": "Puslapiai su žemėlapiais, naudojantys sluoksnį „$1“",
+ "maps-layerpage-nousage": "Šiuo metu nėra puslapių, naudojančiu šį sluoksnį",
+ "maps-error-invalid-layertype": "Nėra „$1“ tipo sluoksnių. Tik {{PLURAL:$3|šis tipas|šie tipai}} yra palaikomi: $2",
+ "maps-error-no-layertype": "Turite nurodyti sluoksnio tipą. {{PLURAL:$2|Tik šis tipas|Tik šie tipai}} yra palaikomi: $1",
+ "validation-error-invalid-layer": "Parametras „$1“ turi būti galimas sluoksnis.",
+ "validation-error-invalid-layers": "Parametras „$1“ turi būti vienas ar daugiau galimų sluoksnių.",
+ "maps-layer-of-type": "„$1“ tipo sluoksnis",
+ "maps-layer-of-type-and-name": "„$1“ tipo sluoksnis „$2“",
+ "maps-coordinates-par-location": "Koordinatės, kurias norite formatuoti.",
+ "maps-finddestination-par-location": "Pradinė vieta.",
+ "maps-finddestination-par-distance": "Kelionės atstumas.",
+ "maps-displaymap-par-circles": "Rodomi apskritimai",
+ "maps-displaymap-par-lines": "Rodomos linijos",
+ "maps-displaymap-par-maxzoom": "Didžiausias priartinimo lygis",
+ "maps-displaymap-par-minzoom": "Mažiausias priartinimo lygis",
+ "maps-displaymap-par-polygons": "Rodomi daugiakampiai",
+ "maps-displaymap-par-rectangles": "Rodomi stačiakampiai",
+ "maps-displaymap-par-static": "Padaryti žemėlapį statinį",
+ "maps-displaymap-par-wmsoverlay": "Naudoti WMS perdangą",
+ "maps-fullscreen-button": "Perjungti į visą ekraną",
+ "maps-fullscreen-button-tooltip": "Peržiūrėti žemėlapį visame ekrane arba kaip integruotą",
+ "validation-error-invalid-location": "Parametras „$1“ turi būti galima vieta.",
+ "validation-error-invalid-locations": "Parametras „$1“ turi būti viena ar kelios galimos vietos.",
+ "validation-error-invalid-width": "Parametras „$1“ turi būti galimas plotis.",
+ "validation-error-invalid-height": "Parametras „$1“ turi būti galimas aukštis.",
+ "validation-error-invalid-distance": "Parametras „$1“ turi būti galimas atstumas.",
+ "validation-error-invalid-distances": "Parametras „$1“ turi būti vienas ar keli galimi atstumai.",
+ "validation-error-invalid-image": "Parametras „$1“ turi būti galimas paveikslėlis.",
+ "validation-error-invalid-images": "Parametras „$1“ turi būti vienas ar keli galimi paveikslėliai.",
+ "maps-abb-north": "Š",
+ "maps-abb-east": "R",
+ "maps-abb-south": "P",
+ "maps-abb-west": "V",
+ "maps-latitude": "Platuma:",
+ "maps-longitude": "Ilguma:",
+ "maps-invalid-coordinates": "Vertė $1 nepripažįstama kaip galiojančios koordinatės.",
+ "maps_coordinates_missing": "Nesudarytos koordinatės žemėlapiui.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Šis adresas|Šie adresai}} negali būti kartografuoti: $1.",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Ši koordinatė|Šios koordinatės}} nebuvo atpažintos: $1.",
+ "maps_map_cannot_be_displayed": "Žemėlapis negal būti parodytas.",
+ "maps_leaflet": "Lankstinukas",
+ "maps-leaflet-par-defzoom": "Leidžia nustatyti numatytąjį žemėlapio priartinimo lygį.",
+ "maps-leaflet-par-layers": "Sluoksniai, kuriuos bus galima rasti sluoksnių pasirinkimuose. Pirmasis sluoksnis bus rodomas įkėlus žemėlapį.",
+ "maps_click_to_activate": "Spustelėkite, norėdami įjungti žemėlapį",
+ "maps_centred_on": "Žemėlapis centruotas link $1, $2.",
+ "maps-par-enable-fullscreen": "Įgalinti viso ekrano mygtuką",
+ "maps-par-markercluster": "Leidžia sujungti kelius netoliese esančius žymeklius į vieną žymeklį",
+ "maps-googlemaps3-incompatbrowser": "Jūsų naršyklė nėra suderinama su Google Maps v3.",
+ "maps-googlemaps3-par-type": "Pradinis žemėlapio tipas.",
+ "mapeditor": "Žemėlapio redaktorius",
+ "specialpages-group-maps": "Žemėlapiai",
+ "mapeditor-none-text": "Nėra",
+ "mapeditor-done-button": "Atlikta",
+ "mapeditor-remove-button": "Pašalinti",
+ "mapeditor-import-button2": "Importuoti",
+ "mapeditor-export-button": "Eksportuoti į viki kodą",
+ "mapeditor-import-button": "Importuoti iš viki kodo",
+ "mapeditor-select-button": "Pasirinkti šį daugiakampį",
+ "mapeditor-mapparam-button": "Redaguoti žemėlapio parametrus",
+ "mapeditor-clear-button": "Valyti žemėlapį",
+ "mapeditor-code-title": "Viki kodas",
+ "mapeditor-import-title": "Importuoti vikį kodą",
+ "mapeditor-form-title": "Redaguoti informaciją",
+ "mapeditor-link-title-switcher-popup-text": "Iššokantis langas su tekstu",
+ "mapeditor-link-title-switcher-link-text": "Nuoroda",
+ "mapeditor-form-field-title": "Pavadinimas",
+ "mapeditor-form-field-text": "Tekstas",
+ "mapeditor-form-field-link": "Nuoroda",
+ "mapeditor-form-field-icon": "Ikona",
+ "mapeditor-form-field-group": "Grupė",
+ "mapeditor-form-field-strokecolor": "Potėpio spalva",
+ "mapeditor-form-field-strokeopacity": "Potėpio matomumas",
+ "mapeditor-form-field-strokeweight": "Potėpio svoris",
+ "mapeditor-form-field-fillcolor": "Užpildo spalva",
+ "mapeditor-form-field-fillopcaity": "Užpildo matomumas",
+ "mapeditor-form-field-showonhover": "Rodyti tik užvedus pelytę",
+ "mapeditor-mapparam-title": "Redaguoti žemėlapio parametrus",
+ "mapeditor-mapparam-defoption": "-Pasirinkti parametrą-",
+ "mapeditor-form-field-image": "Paveikslėlis",
+ "semanticmaps-kml-link": "Žiūrėti KML failą",
+ "semanticmaps-default-kml-pagelink": "Žiūrėti puslapį $1",
+ "semanticmaps-latitude": "Platuma: $1",
+ "semanticmaps-longitude": "Ilguma: $1",
+ "semanticmaps-altitude": "Aukštis: $1",
+ "semanticmaps-forminput-locations": "Vietovės",
+ "validator-type-mapscircle": "Geografinis apskritimas",
+ "validator-type-mapscircle-list": "Apskritimų sąrašas",
+ "validator-type-mapsline": "Geografinė linija",
+ "validator-type-mapsline-list": "Linijų sąrašas",
+ "validator-type-mapslocation": "Geografinė vieta",
+ "validator-type-mapslocation-list": "Vietų sąrašas",
+ "validator-type-mapsrectangle": "Geografinis stačiakampis",
+ "validator-type-mapsrectangle-list": "Stačiakampių sąrašas"
+}
diff --git a/www/wiki/extensions/Maps/i18n/lv.json b/www/wiki/extensions/Maps/i18n/lv.json
new file mode 100644
index 00000000..e6513e59
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/lv.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "GreenZeb"
+ ]
+ },
+ "maps-abb-north": "Z",
+ "maps-abb-east": "A",
+ "maps-abb-south": "D",
+ "maps-abb-west": "R",
+ "maps-latitude": "Platums:",
+ "maps-longitude": "Garums:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/magic/MagicWords.php b/www/wiki/extensions/Maps/i18n/magic/MagicWords.php
new file mode 100644
index 00000000..b7065cee
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/magic/MagicWords.php
@@ -0,0 +1,387 @@
+<?php
+
+/**
+ * Internationalisation file for Maps extension.
+ */
+
+$magicWords = [];
+
+/** English (English) */
+$magicWords['en'] = [
+ 'display_map' => [ 0, 'display_map' ],
+ 'display_point' => [ 0, 'display_point' ],
+ 'display_points' => [ 0, 'display_points' ],
+ 'display_line' => [ 0, 'display_line' ],
+ 'geocode' => [ 0, 'geocode' ],
+ 'geodistance' => [ 0, 'geodistance' ],
+ 'finddestination' => [ 0, 'finddestination' ],
+ 'coordinates' => [ 0, 'coordinates' ],
+ 'distance' => [ 0, 'distance' ],
+ 'mapsdoc' => [ 0, 'mapsdoc' ],
+];
+
+/** Afrikaans (Afrikaans) */
+$magicWords['af'] = [
+ 'geocode' => [ 0, 'geokode', 'geocode' ],
+ 'coordinates' => [ 0, 'koördinate', 'coordinates' ],
+];
+
+/** Arabic (العربية) */
+$magicWords['ar'] = [
+ 'display_map' => [ 0, 'عرض_الخريطة' ],
+ 'display_point' => [ 0, 'نقطة_العرض' ],
+ 'display_points' => [ 0, 'نقاط_العرض' ],
+ 'display_line' => [ 0, 'خط_العرض' ],
+ 'geocode' => [ 0, 'كود_جغرافي' ],
+ 'geodistance' => [ 0, 'مسافة_جغرافية' ],
+ 'finddestination' => [ 0, 'إيجاد_الوجهة' ],
+ 'coordinates' => [ 0, 'إحداثيات' ],
+ 'distance' => [ 0, 'مسافة' ],
+ 'mapsdoc' => [ 0, 'توثيق_الخرائط' ],
+];
+
+/** Egyptian Arabic (مصرى) */
+$magicWords['arz'] = [
+ 'display_map' => [ 0, 'عرض_الخريطه', 'عرض_الخريطة' ],
+ 'display_point' => [ 0, 'نقطه_العرض' ],
+ 'display_points' => [ 0, 'نقط_العرض' ],
+ 'display_line' => [ 0, 'خط_العرض' ],
+ 'geocode' => [ 0, 'كود_جغرافي' ],
+ 'geodistance' => [ 0, 'مسافه_جغرافيه', 'مسافة_جغرافية' ],
+ 'finddestination' => [ 0, 'إيجاد_الوجهه', 'إيجاد_الوجهة' ],
+ 'coordinates' => [ 0, 'إحداثيات' ],
+ 'distance' => [ 0, 'مسافه' ],
+ 'mapsdoc' => [ 0, 'توثيق_الخرايط' ],
+];
+
+/** Assamese (অসমীয়া) */
+$magicWords['as'] = [
+ 'display_point' => [ 0, 'মানচিত্ৰ_প্ৰদৰ্শন' ],
+];
+
+/** Breton (brezhoneg) */
+$magicWords['br'] = [
+ 'coordinates' => [ 0, 'daveennoù' ],
+ 'distance' => [ 0, 'hed' ],
+];
+
+/** Chechen (нохчийн) */
+$magicWords['ce'] = [
+ 'geocode' => [ 0, 'геагишар', 'геокод' ],
+];
+
+/** German (Deutsch) */
+$magicWords['de'] = [
+ 'display_map' => [ 0, 'zeige_karte' ],
+ 'display_point' => [ 0, 'zeige_punkt' ],
+ 'display_points' => [ 0, 'zeige_punkte' ],
+ 'display_line' => [ 0, 'zeige_linie' ],
+ 'geocode' => [ 0, 'geokodiere' ],
+ 'geodistance' => [ 0, 'geoentfernung' ],
+ 'finddestination' => [ 0, 'finde_ziel' ],
+ 'coordinates' => [ 0, 'koordinaten' ],
+ 'distance' => [ 0, 'entfernung' ],
+ 'mapsdoc' => [ 0, 'mapsdok' ],
+];
+
+/** Zazaki (Zazaki) */
+$magicWords['diq'] = [
+ 'display_map' => [ 0, 'aseniya_ğerita' ],
+ 'display_point' => [ 0, 'aseniya_dewti' ],
+ 'display_points' => [ 0, 'aseniya_dawıtan' ],
+ 'display_line' => [ 0, 'aseniya_ğeter' ],
+ 'geocode' => [ 0, 'herunkodi' ],
+ 'geodistance' => [ 0, 'heruna_mesafi' ],
+ 'finddestination' => [ 0, 'menzilvinayış' ],
+ 'coordinates' => [ 0, 'koordinati' ],
+ 'distance' => [ 0, 'mesafe' ],
+ 'mapsdoc' => [ 0, 'dokumanéğerita' ],
+];
+
+/** Esperanto (Esperanto) */
+$magicWords['eo'] = [
+ 'coordinates' => [ 0, 'koordinatoj' ],
+ 'distance' => [ 0, 'distanco' ],
+];
+
+/** Spanish (español) */
+$magicWords['es'] = [
+ 'display_point' => [ 0, 'mostrar_punto' ],
+ 'geocode' => [ 0, 'geocodificar' ],
+ 'coordinates' => [ 0, 'coordenadas' ],
+ 'distance' => [ 0, 'distancia' ],
+];
+
+/** French (français) */
+$magicWords['fr'] = [
+ 'display_map' => [ 0, 'afficher_carte' ],
+ 'display_point' => [ 0, 'afficher_point' ],
+ 'display_points' => [ 0, 'afficher_points' ],
+ 'display_line' => [ 0, 'afficher_ligne' ],
+ 'geocode' => [ 0, 'codegéo' ],
+ 'geodistance' => [ 0, 'distancegéo' ],
+ 'finddestination' => [ 0, 'trouverdestination' ],
+ 'coordinates' => [ 0, 'coordonnées' ],
+ 'distance' => [ 0, 'distance' ],
+ 'mapsdoc' => [ 0, 'doccartes' ],
+];
+
+/** Hebrew (עברית) */
+$magicWords['he'] = [
+ 'distance' => [ 0, 'מרחק' ],
+];
+
+/** Indonesian (Bahasa Indonesia) */
+$magicWords['id'] = [
+ 'finddestination' => [ 0, 'petunjukarah' ],
+ 'coordinates' => [ 0, 'koordinat' ],
+ 'distance' => [ 0, 'jarak' ],
+];
+
+/** Igbo (Igbo) */
+$magicWords['ig'] = [
+ 'display_map' => [ 0, 'zí_otúzọr', 'display_map' ],
+];
+
+/** Italian (italiano) */
+$magicWords['it'] = [
+ 'display_map' => [ 0, 'mostra_mappa' ],
+ 'display_point' => [ 0, 'mostra_punto' ],
+ 'display_points' => [ 0, 'mostra_punti' ],
+ 'geocode' => [ 0, 'geocodice' ],
+ 'geodistance' => [ 0, 'geodistanza' ],
+ 'finddestination' => [ 0, 'trovadestinazione' ],
+ 'coordinates' => [ 0, 'coordinate' ],
+ 'distance' => [ 0, 'distanza' ],
+ 'mapsdoc' => [ 0, 'docmappe' ],
+];
+
+/** Japanese (日本語) */
+$magicWords['ja'] = [
+ 'display_map' => [ 0, '地図表示' ],
+ 'display_point' => [ 0, '地図点' ],
+ 'geocode' => [ 0, '地理的コード' ],
+ 'geodistance' => [ 0, '地理的距離' ],
+ 'finddestination' => [ 0, '目的地検索' ],
+ 'coordinates' => [ 0, '座標' ],
+ 'distance' => [ 0, '距離' ],
+];
+
+/** Georgian (ქართული) */
+$magicWords['ka'] = [
+ 'coordinates' => [ 0, 'კოორდინატები' ],
+ 'distance' => [ 0, 'მანძილი' ],
+];
+
+/** Korean (한국어) */
+$magicWords['ko'] = [
+ 'display_map' => [ 0, '지도_표시' ],
+ 'display_point' => [ 0, '포인트_표시' ],
+ 'display_points' => [ 0, '포인트목록_표시' ],
+ 'display_line' => [ 0, '선_표시' ],
+ 'geocode' => [ 0, '지리코드' ],
+ 'geodistance' => [ 0, '지리거리' ],
+ 'finddestination' => [ 0, '목적지찾기' ],
+ 'coordinates' => [ 0, '좌표' ],
+ 'distance' => [ 0, '거리' ],
+ 'mapsdoc' => [ 0, '지도문서' ],
+];
+
+/** Kurdish (Latin script) (Kurdî (latînî)‎) */
+$magicWords['ku-latn'] = [
+ 'coordinates' => [ 0, 'koordînat' ],
+];
+
+/** Ladino (Ladino) */
+$magicWords['lad'] = [
+ 'distance' => [ 0, 'distancia', 'distance' ],
+];
+
+/** Luxembourgish (Lëtzebuergesch) */
+$magicWords['lb'] = [
+ 'coordinates' => [ 0, 'Koordinaten' ],
+ 'distance' => [ 0, 'Distanz' ],
+];
+
+/** Minangkabau (Baso Minangkabau) */
+$magicWords['min'] = [
+ 'finddestination' => [ 0, 'petunjukarah' ],
+ 'coordinates' => [ 0, 'koordinat' ],
+ 'distance' => [ 0, 'jarak' ],
+];
+
+/** Macedonian (македонски) */
+$magicWords['mk'] = [
+ 'display_map' => [ 0, 'прикажи_карта' ],
+ 'display_point' => [ 0, 'прикажи_точка' ],
+ 'display_points' => [ 0, 'прикажи_точки' ],
+ 'display_line' => [ 0, 'прикажи_линија' ],
+ 'geocode' => [ 0, 'геокод' ],
+ 'geodistance' => [ 0, 'георастојание' ],
+ 'finddestination' => [ 0, 'најдиодредница' ],
+ 'coordinates' => [ 0, 'координати' ],
+ 'distance' => [ 0, 'растојание' ],
+ 'mapsdoc' => [ 0, 'докумкарти' ],
+];
+
+/** Malayalam (മലയാളം) */
+$magicWords['ml'] = [
+ 'display_map' => [ 0, 'ഭൂപടം_പ്രദർശിപ്പിക്കുക' ],
+ 'display_point' => [ 0, 'ബിന്ദു_പ്രദർശിപ്പിക്കുക' ],
+ 'display_points' => [ 0, 'ബിന്ദുക്കൾ_പ്രദർശിപ്പിക്കുക' ],
+ 'display_line' => [ 0, 'രേഖ_പ്രദർശിപ്പിക്കുക' ],
+ 'geocode' => [ 0, 'ജിയോകോഡ്' ],
+ 'geodistance' => [ 0, 'ഭൗമദൂരം' ],
+ 'finddestination' => [ 0, 'ലക്ഷ്യംതിരയുക' ],
+ 'coordinates' => [ 0, 'നിർദ്ദേശാങ്കങ്ങൾ' ],
+ 'distance' => [ 0, 'ദൂരം' ],
+];
+
+/** Marathi (मराठी) */
+$magicWords['mr'] = [
+ 'distance' => [ 0, 'अंतर' ],
+];
+
+/** Low Saxon (Netherlands) (Nedersaksies) */
+$magicWords['nds-nl'] = [
+ 'display_map' => [ 0, 'kaorte_laoten_zien' ],
+ 'geocode' => [ 0, 'geokoderen' ],
+ 'geodistance' => [ 0, 'geo-aofstaand' ],
+ 'finddestination' => [ 0, 'bestemmingzeuken' ],
+ 'coordinates' => [ 0, 'koordinaoten' ],
+ 'distance' => [ 0, 'aofstaand' ],
+];
+
+/** Dutch (Nederlands) */
+$magicWords['nl'] = [
+ 'display_map' => [ 0, 'kaart_weergeven' ],
+ 'display_point' => [ 0, 'punt_weergeven' ],
+ 'display_points' => [ 0, 'punten_weergeven' ],
+ 'display_line' => [ 0, 'lijn_weergeven' ],
+ 'geocode' => [ 0, 'geocoderen' ],
+ 'geodistance' => [ 0, 'geoafstand' ],
+ 'finddestination' => [ 0, 'bestemmingzoeken' ],
+ 'coordinates' => [ 0, 'coordinaten' ],
+ 'distance' => [ 0, 'afstand' ],
+ 'mapsdoc' => [ 0, 'kaartdoc' ],
+];
+
+/** Polish (polski) */
+$magicWords['pl'] = [
+ 'display_map' => [ 0, 'wyświetl_mapę' ],
+ 'coordinates' => [ 0, 'współrzędne' ],
+ 'distance' => [ 0, 'odległość' ],
+];
+
+/** Pashto (پښتو) */
+$magicWords['ps'] = [
+ 'distance' => [ 0, 'واټن', 'distance' ],
+];
+
+/** Portuguese (português) */
+$magicWords['pt'] = [
+ 'display_map' => [ 0, 'mostrar_mapa' ],
+ 'display_point' => [ 0, 'mostrar_ponto' ],
+ 'display_points' => [ 0, 'mostrar_pontos' ],
+ 'geocode' => [ 0, 'geocódigo' ],
+ 'geodistance' => [ 0, 'geodistância' ],
+ 'finddestination' => [ 0, 'encontrardestino' ],
+ 'coordinates' => [ 0, 'coordenadas' ],
+ 'distance' => [ 0, 'distância' ],
+];
+
+/** Russian (русский) */
+$magicWords['ru'] = [
+ 'display_map' => [ 0, 'показать_карту' ],
+ 'display_point' => [ 0, 'показать_точку' ],
+ 'display_points' => [ 0, 'показать_точки' ],
+ 'display_line' => [ 0, 'показать_линию' ],
+ 'geocode' => [ 0, 'геокод' ],
+ 'geodistance' => [ 0, 'георасстояние' ],
+ 'finddestination' => [ 0, 'найти_местоположение' ],
+ 'coordinates' => [ 0, 'координаты' ],
+ 'distance' => [ 0, 'расстояние' ],
+];
+
+/** Sinhala (සිංහල) */
+$magicWords['si'] = [
+ 'finddestination' => [ 0, 'ගමනාන්තය_සෙවීම', 'finddestination' ],
+ 'coordinates' => [ 0, 'ඛණ්ඩාංක', 'coordinates' ],
+ 'distance' => [ 0, 'දුර', 'distance' ],
+];
+
+/** Serbian (Cyrillic script) (српски (ћирилица)‎) */
+$magicWords['sr-ec'] = [
+ 'display_map' => [ 0, 'прикажи_мапу' ],
+ 'display_point' => [ 0, 'прикажи_тачку', 'прикажи_тачке' ],
+ 'finddestination' => [ 0, 'пронађиодредиште', 'пронађи_одредиште' ],
+ 'coordinates' => [ 0, 'координате' ],
+ 'distance' => [ 0, 'раздаљина' ],
+];
+
+/** Serbian (Latin script) (srpski (latinica)‎) */
+$magicWords['sr-el'] = [
+ 'display_map' => [ 0, 'prikaži_mapu' ],
+ 'display_point' => [ 0, 'prikaži_tačku', 'prikaži_tačke' ],
+ 'geocode' => [ 0, 'geografski_kod' ],
+ 'geodistance' => [ 0, 'geografska_razdaljina' ],
+ 'finddestination' => [ 0, 'pronađi_odredište' ],
+ 'coordinates' => [ 0, 'koordinate' ],
+ 'distance' => [ 0, 'razdaljina' ],
+];
+
+/** Talysh (толышә зывон) */
+$magicWords['tly'] = [
+ 'display_map' => [ 0, 'хәритә_нишо_дој' ],
+];
+
+/** Ukrainian (українська) */
+$magicWords['uk'] = [
+ 'display_map' => [ 0, 'показати_карту' ],
+ 'display_point' => [ 0, 'показати_точку' ],
+ 'display_points' => [ 0, 'показати_точки' ],
+ 'geodistance' => [ 0, 'геовідстань' ],
+ 'finddestination' => [ 0, 'знайти_місцезнаходження' ],
+ 'coordinates' => [ 0, 'координати' ],
+ 'distance' => [ 0, 'відстань' ],
+];
+
+/** Uzbek (oʻzbekcha/ўзбекча) */
+$magicWords['uz'] = [
+ 'coordinates' => [ 0, 'koordinatalar' ],
+];
+
+/** Vietnamese (Tiếng Việt) */
+$magicWords['vi'] = [
+ 'display_map' => [ 0, 'hiển_thị_bản_đồ', 'hiểnthịbảnđồ' ],
+ 'geocode' => [ 0, 'mã_hóa_địa_lý', 'mãhóađịalý', 'mã_hoá_địa_lý', 'mãhoáđịalý', 'mã_hóa_địa_lí', 'mãhóađịalí', 'mã_hoá_địa_lí', 'mãhoáđịalí' ],
+ 'coordinates' => [ 0, 'tọa_độ', 'tọađộ' ],
+];
+
+/** Simplified Chinese (中文(简体)‎) */
+$magicWords['zh-hans'] = [
+ 'display_map' => [ 0, '显示地图' ],
+ 'display_point' => [ 0, '显示点' ],
+ 'display_points' => [ 0, '显示多个点' ],
+ 'display_line' => [ 0, '显示线' ],
+ 'geocode' => [ 0, '地理编码' ],
+ 'geodistance' => [ 0, '地理距离' ],
+ 'finddestination' => [ 0, '寻找目的地' ],
+ 'coordinates' => [ 0, '坐标' ],
+ 'distance' => [ 0, '距离' ],
+ 'mapsdoc' => [ 0, '地图文档' ],
+];
+
+/** Traditional Chinese (中文(繁體)‎) */
+$magicWords['zh-hant'] = [
+ 'display_map' => [ 0, '顯示地圖' ],
+ 'display_point' => [ 0, '顯示位置' ],
+ 'display_points' => [ 0, '顯示多個位置' ],
+ 'display_line' => [ 0, '顯示線' ],
+ 'geocode' => [ 0, '地理編碼' ],
+ 'geodistance' => [ 0, '地理距離' ],
+ 'finddestination' => [ 0, '搜尋目的地' ],
+ 'coordinates' => [ 0, '坐標' ],
+ 'distance' => [ 0, '距離' ],
+ 'mapsdoc' => [ 0, '地圖檔案' ],
+]; \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/i18n/map-bms.json b/www/wiki/extensions/Maps/i18n/map-bms.json
new file mode 100644
index 00000000..fe74234d
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/map-bms.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "StefanusRA"
+ ]
+ },
+ "maps-abb-north": "L",
+ "maps-abb-east": "W",
+ "maps-abb-south": "Kdl",
+ "maps-abb-west": "Kln",
+ "maps-latitude": "Latituda:",
+ "maps-longitude": "Longituda:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/mg.json b/www/wiki/extensions/Maps/i18n/mg.json
new file mode 100644
index 00000000..48eda710
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/mg.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jagwar"
+ ]
+ },
+ "maps-layerdef-invalid-fatal": "Famaritana ny tsy azo ampiasaina mahajanona",
+ "maps-layerdef-wrong-namespace": "Azo ekena ao amin'ny eran'anarana \"$1\" ihany ny famaritan-tsosona",
+ "maps-layerdef-equal-layer-name": "Tsy maintsy tokana ao amin'ny pejy sosona ny anaran-tsosona. Efa ampiasaina anaty sosona hafa \"$1\"",
+ "maps-layerpage-usage": "Pejy misy sarintany mampiasa ny sosona \"$1\"",
+ "maps-layerpage-nousage": "Tsy misy pejy mampiasa ity sosona ity amin'izao fotoana izao.",
+ "validation-error-invalid-layer": "Tsy maintsy sosona azo ampiasaina ny parametatra \"$1\"",
+ "validation-error-invalid-layers": "Tsy maintsy parametatra azo ekena iray na mihoatra ny parametatra \"$1\".",
+ "validation-error-no-non-numerics": "Tsy maintsy tohin-dohavy iray na maro ny parametatra \"$1\".",
+ "maps-layer-of-type": "Karazan-tsosona \"$1\"",
+ "maps-layerdefinition-description": "Mamaritra sosona manokana izay mety aseho amin'ny alalan'ny lefan-tsaritany hafa.",
+ "validation-error-invalid-location": "Tsy maintsy toerana azo ekena ny parametatra \"$1\".",
+ "validation-error-invalid-width": "Tsy maintsy habe azo ekena ny parametatra \"$1\".",
+ "validation-error-invalid-height": "Tsy maintsy haavo azo ekena ny parametatra \"$1\".",
+ "validation-error-invalid-distances": "Tsy maintsy halavirana azo ekena ny parametatra \"$1\".",
+ "validation-error-invalid-image": "Tsy maintsy sary azo ekena ny parametatra \"$1\".",
+ "validation-error-invalid-goverlay": "Tsy maintsy azo ampiasaina ny mpanosona \"$1\".",
+ "validation-error-invalid-goverlays": "Tsy maintsy mpanosona azo ekena iray na mihoatra ny parametatra \"$1\"."
+}
diff --git a/www/wiki/extensions/Maps/i18n/mk.json b/www/wiki/extensions/Maps/i18n/mk.json
new file mode 100644
index 00000000..78a20ef8
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/mk.json
@@ -0,0 +1,226 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06",
+ "McDutchie",
+ "Macofe",
+ "Vlad5250"
+ ]
+ },
+ "maps-desc": "Дава можност за вметнување на динамички карти во викистраници, геокодирање на адреси и други географски постапки",
+ "right-geocode": "Геокод",
+ "action-geocode": "вршење на геокодирање на ова вики",
+ "maps_map": "Карта",
+ "maps-tracking-category": "Страници со карта исцртана со додатокот „Карти“",
+ "maps-loading-map": "Ја вчитувам картата...",
+ "maps-load-failed": "Не можев да ја вчитам картата!",
+ "maps-markers": "Обележувачи",
+ "maps-copycoords-prompt": "Стиснете CTRL+C, па ENTER",
+ "maps-searchmarkers-text": "Филтрирање на одбележувачи",
+ "maps-others": "други",
+ "maps-kml-parsing-failed": "Не можев да расчленам една или повеќе KML-податотеки. Ова обично се должи на нивна недостапност или лошо обликуван XML.",
+ "maps-ns-layer": "Слој",
+ "maps-ns-layer-talk": "Разговор за слој",
+ "maps-layer-property": "Својство",
+ "maps-layer-value": "Вредност",
+ "maps-layer-errors": "Грешки",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Неважечка одредба|Неважечки одредби}}",
+ "maps-layerdef-invalid-fatal": "Кобна неважечка одредба",
+ "maps-layerdef-wrong-namespace": "Одредбите на слоевите се важечки само на страници од именскиот простор „$1“",
+ "maps-layerdef-equal-layer-name": "Имињата на слоевите не може да се повторуваат на една иста страница со слоеви. Веќе има слој со име „$1“.",
+ "maps-layerpage-usage": "Страници со карти што го користат слојот „$1“",
+ "maps-layerpage-nousage": "Засега нема страници што го користат овој слој.",
+ "maps-error-invalid-layertype": "Нема слоеви од типот „$1“. {{PLURAL:$3|Поддржан е само овој тип|Поддржани се само следниве типови}}: $2",
+ "maps-error-no-layertype": "Ќе треба да наведете тип на слој. {{PLURAL:$2|Поддржан е само овој тип|Поддржани се само следниве типови}}: $1",
+ "validation-error-invalid-layer": "Параметарот $1 мора да биде важечки слој.",
+ "validation-error-invalid-layers": "Параметарот $1 мора да биде еден или повеќе важечки слоеви.",
+ "validation-error-no-non-numeric": "Параметарот „$1“ мора да биде небројчена низа.",
+ "validation-error-no-non-numerics": "Параметарот „$1“ мора да биде една или повеќе небројчени низи.",
+ "maps-layer-of-type": "Слој од типот $1",
+ "maps-layer-of-type-and-name": "Слој „$2“ од типот „$1“",
+ "maps-layer-type-supported-by": "Овој тип на слој може да се користи {{PLURAL:$2|само со картографската служба $1|само со следниве картографски служби: $1}}.",
+ "maps-coordinates-description": "Расчленувачкиот пресретник за форматирање на координати. Ги претвора сите поддржани формати.",
+ "maps-displaymap-description": "Приказ на географски карти без никакви обележувачи на нив определени од викито.",
+ "maps-distance-description": "Претворање на растојание од една во друга поддржана единица.",
+ "maps-finddestination-description": "Пронаоѓање на одредница со зададена почетна точка (која може да биде во било кој поддржан формат), првична насока и растојание",
+ "maps-geocode-description": "Овозможува геокодирање на адреси, што значи дека претвора места во координати. Има поддршка за неколку служби за геокодирање (не е исто што и картографски служби).",
+ "maps-geodistance-description": "Пресметување на географското растојание помеѓу две точки (сите поддржани формати).",
+ "maps-mapsdoc-description": "Приказ на табела со параметри за назначена карторафска служба заедно со нивните основни вредности и описи.",
+ "maps-layerdefinition-description": "Опишува прилагоден слој што се прикажува со други функции за карта.",
+ "maps-mapsdoc-par-service": "Картографската служба за која се прикажува параметарска документација.",
+ "maps-mapsdoc-par-language": "На кој јазик да се прикаже документацијата. Ако го нема тој превод, ќе се прикаже англиската верзија.",
+ "maps-coordinates-par-location": "Координатите што сакате да ги форматирате.",
+ "maps-coordinates-par-format": "Целниот формат за координатите.",
+ "maps-coordinates-par-directional": "Покажува дали координатите треба да се испишат со или без насока.",
+ "maps-par-scrollwheelzoom": "Покажува дали е вклучено тркалцето на глушецот.",
+ "maps-distance-par-distance": "Растојанието во кое претворате е истоветно со единицата што се укажува.",
+ "maps-distance-par-decimals": "Највеќе децимални места што ќе се користат во изводната вредност.",
+ "maps-distance-par-unit": "Единица на испишаното растојание во изводот.",
+ "maps-finddestination-par-location": "Првичната местоположба.",
+ "maps-finddestination-par-bearing": "Првичната насока.",
+ "maps-finddestination-par-distance": "Растојанието што треба да се помине.",
+ "maps-finddestination-par-format": "Во кој формат да се испише одредницата.",
+ "maps-finddestination-par-directional": "Покажува дали форматот на одредницата треба да има насока.",
+ "maps-geocode-par-location": "Адресата што сакате да ја геокодирате.",
+ "maps-geocode-par-format": "Форматот на добиените координати.",
+ "maps-geocode-par-directional": "Покажува дали координатите треба да се испишат со или без насока.",
+ "maps-geodistance-par-location1": "Првата точка во пресметката на растојанието.",
+ "maps-geodistance-par-location2": "Втората точка во пресметката на растојанието.",
+ "maps-geodistance-par-unit": "Во која единица да се испише растојанието.",
+ "maps-geodistance-par-decimals": "Допуштениот број на децимални места за добиената вредност.",
+ "maps-displaymap-par-mappingservice": "Овозможува задавање на картографска служба што ќе се користи за создавање на картата.",
+ "maps-displaymap-par-coordinates": "На кое место картата ќе биде првично сосредоточена.",
+ "maps-displaymap-par-visitedicon": "Податотечното име на сликата што ќе се користи на обележувачите откако ќе стиснете на изворните обележувачи",
+ "maps-displaymap-par-zoom": "Овозможува задавање на приближеност на картата.\nАко ова не е зададено, а на картата има повеќе обележувачи, тогаш ќе ви се прикаже приближеноста што најмногу одговара на екранот, наместо прилагодливата стандардна приближеност.",
+ "maps-displaymap-par-centre": "Овозможува укажување на координати на средиштето на картата за display_point(s).\nСе прифаќаат и адреси и координати.\nАко ова не е зададено, тогаш картата ќе се сосредоточи во дадениот обележувач, или помеѓу дадените обележувачи.",
+ "maps-displaymap-par-title": "Овозможува задавање на текст што ќе се прикажува во скокачките прозорчиња на сите обележувачи што немаат конкретен наслов.\nАко се користат заедно со ознака, насловот ќе биде задебелен и ќе има линија под него.",
+ "maps-displaymap-par-label": "Овозможува задавање на текст што ќе се прикажува во скокачките прозорчиња на сите обележувачи што немаат конкретна ознака.",
+ "maps-displaymap-par-icon": "Овозможува задавање на икона што ќе се користи за сите обележувачи.",
+ "maps-displaymap-par-circles": "Кругови за приказ",
+ "maps-displaymap-par-copycoords": "Прикажувај прозорче со координатите на местото при стискање на место од кајшто можат да се прекопираат.",
+ "maps-displaymap-par-lines": "Линии за приказ",
+ "maps-displaymap-par-maxzoom": "Најголема приближеност",
+ "maps-displaymap-par-minzoom": "Најмала приближеност",
+ "maps-displaymap-par-polygons": "Многуаголници за приказ",
+ "maps-displaymap-par-rectangles": "Правоаголници за приказ",
+ "maps-displaymap-par-static": "Напарви ја картата неподвижна",
+ "maps-displaymap-par-wmsoverlay": "Користи WMS-облога",
+ "maps-displaymap-par-geojson": "URL на податотеката или името на страницата со GeoJSON-податоци",
+ "maps-fullscreen-button": "Префрли на широк екран",
+ "maps-fullscreen-button-tooltip": "Поглед на картата на цел екран или вгнездено.",
+ "validation-error-invalid-location": "Параметарот $1 мора да претставува важечка местоположба.",
+ "validation-error-invalid-locations": "Параметарот $1 мора да претставува една или повеќе важечки местоположби.",
+ "validation-error-invalid-width": "Параметарот $1 мора да претставува важечка ширина.",
+ "validation-error-invalid-height": "Параметарот $1 мора да претставува важечка висина.",
+ "validation-error-invalid-distance": "Параметарот $1 мора да претставува важечко растојание.",
+ "validation-error-invalid-distances": "Параметарот $1 мора да претставува едно или повеќе важечки растојанија.",
+ "validation-error-invalid-image": "Параметарот $1 мора да биде важечка слика.",
+ "validation-error-invalid-images": "Параметарот $1 мора да биде една или повеќе важечки слики.",
+ "validation-error-invalid-goverlay": "Параметарот $1 мора да претставува важечка облога.",
+ "validation-error-invalid-goverlays": "Параметарот $1 мора да претставува една или повеќе важечки облоги.",
+ "maps-abb-north": "С",
+ "maps-abb-east": "И",
+ "maps-abb-south": "Ј",
+ "maps-abb-west": "З",
+ "maps-latitude": "Геог. ширина",
+ "maps-longitude": "Геог. должина:",
+ "maps-invalid-coordinates": "Вредноста $1 не беше препознаена како правилен збир координати.",
+ "maps_coordinates_missing": "Нема координати за картата.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Следнава адреса не можеше да се геокодира|Следниве адреси не можеа да се геокодираат}}: $1.\nКартата не може да се прикаже.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Следнава адреса не можеше да се геокодира|Следниве адреси не можеа да се геокодираат}} и затоа {{PLURAL:$2|беше изоставена|беа изоставени}} од картата:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Следнава координата не е препознаена|Следниве координати не се препознаени}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Следнава координата не беше препознаена|Следниве координати не беа препознаени}} и {{PLURAL:$2|беше изоставена|беа изоставени}} од картата:\n$1",
+ "maps_map_cannot_be_displayed": "Картата не може да се прикаже.",
+ "maps-geocoder-not-available": "Функцијата за геокодирање на Карти е недостапна. Вашата местоположба не може да се геокодира.",
+ "maps_googlemaps3": "Google Карти вер. 2",
+ "maps_leaflet": "Леток",
+ "maps-leaflet-par-defzoom": "Овозможува задавање на основен степен на приближеност на картата.",
+ "maps-leaflet-par-layers": "Слојот што ќе се покажува кога се вчитува картата.",
+ "maps-leaflet-par-overlaylayers": "Слоеви на облогата што ќе се покажуваат кога се вчитува картата.",
+ "maps-leaflet-par-maxclusterradius": "Најголемиот полупречник што може да го покрие еден грозд од средишниот обележувач (во пиксели).",
+ "maps-leaflet-par-clusterspiderfy": "Кога ќе стиснете на грозд при најслаба приближеност, истиот ќе се разграни за да можете да ги видите сите негови обележувачи.",
+ "maps_click_to_activate": "Стиснете за активирање на картата",
+ "maps_centred_on": "Средиште на картата во $1, $2.",
+ "maps-par-mappingservice": "Овозможува назначување на картографска служба што ќе се користи за создавање на картата.",
+ "maps-par-resizable": "Дава можност за менување на големината на картите со влечење на долниот десен агол.",
+ "maps-par-searchmarkers": "Овозможува пребарување на поединечни бележници од поле вметнато во картата.",
+ "maps-par-zoom": "Степенот на приближеност на картата. Картите со обележувачи по основно се прикажуваат во најголем степен на приближеност што воедно ги прикажува сите обележувачи.",
+ "maps-par-width": "Овозможува задавање на ширина на картата во пиксели по основно, но по желба можете да изберете една од следниве единици: px, ex, em, %.",
+ "maps-par-height": "Овозможува задавање на висина на картата во пиксели по основно, но по желба можете да изберете една од следниве единици: px, ex, em, %.",
+ "maps-par-centre": "На која местоположба да се сосредоточи картата",
+ "maps-par-enable-fullscreen": "Овозможи копче за цел екран",
+ "maps-par-kml": "KML-податотеки за вчитување во картата.",
+ "maps-par-markercluster": "Овозможува спојување на повеќе соседни бележници во еден",
+ "maps-googlemaps3-incompatbrowser": "Вашиот прелистувач не е погоден за Google Карти вер. 3.",
+ "maps-googlemaps3-par-imageoverlays": "Овозможува додавање на слика што ќе се прикажува на укажаното место на картата.",
+ "maps-googlemaps3-par-type": "Типот на карта за првичниот приказ.",
+ "maps-googlemaps3-par-types": "Типовите на карти што ќе бидат достапни преку контролата за тип.",
+ "maps-googlemaps3-par-layers": "Посебни слоеви за вчитување во картата.",
+ "maps-googlemaps3-par-controls": "Контролите што сакате да стојат на картата.",
+ "maps-googlemaps3-par-zoomstyle": "Стил на контролата за приближување.",
+ "maps-googlemaps3-par-typestyle": "Стилот на контролата за тип.",
+ "maps-googlemaps3-par-autoinfowindows": "Автоматски отворај ги сите инфопрозорци откако ќе се вчита страницата.",
+ "maps-googlemaps3-par-gkml": "KML-податотеки вдомени од Google за вчитување на карта.",
+ "maps-googlemaps3-par-kmlrezoom": "Приближи ја картата повторно откако ќе се вчитаат KML-слоевите.",
+ "maps-googlemaps3-par-poi": "Прикажи точки од интерес.",
+ "maps-googlemaps3-par-clustergridsize": "Решеткаста големина на грозд во пиксели.",
+ "maps-par-clustermaxzoom": "Најголемиот степен на приближеност при кој можат да постојат гроздови.",
+ "maps-par-clusterzoomonclick": "Дали, по основно, стискањето на грозд ќе го приближи истиот.",
+ "maps-par-maxclusterradius": "Најголемиот полупречник што може да го покрие еден грозд.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Дали средиштето на секој гроз треба да биде просек од сите обележувачи во гроздот.",
+ "maps-googlemaps3-par-clusterminsize": "Најмалиот број на обележувачи што ќе бидат во грозд пред истите да бидат скриени и да се прикаже нивната бројка.",
+ "mapeditor": "Уредник на карти",
+ "specialpages-group-maps": "Карти",
+ "mapeditor-parser-error": "Се појави грешка при расчленувањето на метаподатоците. Го занемарувам уделот на корисникот.",
+ "mapeditor-none-text": "Нема",
+ "mapeditor-done-button": "Готово",
+ "mapeditor-remove-button": "Отстрани",
+ "mapeditor-import-button2": "Увези",
+ "mapeditor-export-button": "Извези во викикод",
+ "mapeditor-import-button": "Увези од викикод",
+ "mapeditor-select-button": "Одберете го многуаголников",
+ "mapeditor-mapparam-button": "Уреди параметри на картата",
+ "mapeditor-clear-button": "Исчисти ја картата",
+ "mapeditor-code-title": "Викикод",
+ "mapeditor-import-title": "Увези викикод",
+ "mapeditor-import-note": "Имајте предвид дека расчленувачот очекува многу строг формат на викикодот. Тука внесениот код треба да се совпаѓа со излезниот код на функцијата за извоз.",
+ "mapeditor-form-title": "Уреди подробности",
+ "mapeditor-link-title-switcher-popup-text": "Отскок со текст",
+ "mapeditor-link-title-switcher-link-text": "Врска",
+ "mapeditor-form-field-title": "Наслов",
+ "mapeditor-form-field-text": "Текст",
+ "mapeditor-form-field-link": "Врска",
+ "mapeditor-form-field-icon": "Икона",
+ "mapeditor-form-field-group": "Група",
+ "mapeditor-form-field-inlinelabel": "Вметната ознака",
+ "mapeditor-form-field-strokecolor": "Боја на буквите",
+ "mapeditor-form-field-strokeopacity": "Непроѕирност на буквите",
+ "mapeditor-form-field-strokeweight": "Јачина на буквите",
+ "mapeditor-form-field-fillcolor": "Боја на пополнувањето",
+ "mapeditor-form-field-fillopcaity": "Непроѕирност на пополнувањето",
+ "mapeditor-form-field-showonhover": "Прикажи само при минување врз него",
+ "mapeditor-mapparam-title": "Уреди параметри на картата",
+ "mapeditor-mapparam-defoption": "-Изберете параметар-",
+ "mapeditor-imageoverlay-button": "Додај облога од слика",
+ "mapeditor-form-field-image": "Слика",
+ "mapeditor-imageoverlay-title": "Поединости за облога од слика",
+ "mapeditor-form-field-visitedicon": "Икона за посетено",
+ "semanticmaps-unrecognizeddistance": "Вредноста $1 не претставува важечко растојание.",
+ "semanticmaps-kml-link": "Преглед на KML-податотеката",
+ "semanticmaps-default-kml-pagelink": "Преглед на статијата $1",
+ "semanticmaps-latitude": "Геог. ширина: $1",
+ "semanticmaps-longitude": "Геог. должина: $1",
+ "semanticmaps-altitude": "Надм. вис: $1",
+ "semanticmaps-forminput-locations": "Места",
+ "semanticmaps-par-staticlocations": "Список на места за додавање во картатата заедно со побараните податоци. Како и со „display_points“, тука можете да додадете наслов, опис и икона за секое место, користејќи тилда (~) како одделувач.",
+ "semanticmaps-par-showtitle": "Дали да се прикажува насловот на инфопрозорецот на ознаката. Оневозможете го кога користите шаблон за форматирање на содржината на инфопрозорецот.",
+ "semanticmaps-par-hidenamespace": "Дали да се прикажува називот на именскиот простор во инфопрозорецот за ознаката.",
+ "semanticmaps-par-centre": "Средиштето на картата. Ако не е укажано, картата автоматски ќе го одбере средиштето кајшто оптимално ќе се прикажат сите одбележувачи на картата.",
+ "semanticmaps-par-template": "Шаблон за форматирање на содржината на инфопрозорецот.",
+ "semanticmaps-par-geocodecontrol": "Прикажи геокодни котроли.",
+ "semanticmaps-par-activeicon": "Икона за приказ наместо стандардниот бележник, кога активна страница се совпаѓа со бараното",
+ "semanticmaps-par-pagelabel": "Ако му е зададено „да“, сите обележувачи ќе имаат „inlineLabel“ со врска до страницата што ги содржат координатите за обележувачот",
+ "semanticmaps-par-ajaxcoordproperty": "Назив на координатното својство со кое ќе се срочи барање со Ajax.",
+ "semanticmaps-par-ajaxquery": "Второ барање што се праша преку Ajax за добивање на дополнителни координати.",
+ "semanticmaps-par-userparam": "Вредност која се дава при секое повикување на шаблон, ако се користи",
+ "semanticmaps-kml-text": "Текстот на секоја страница. Се презапишува ако има дополнителни барани својства.",
+ "semanticmaps-kml-title": "Стандарден наслов за исходот",
+ "semanticmaps-kml-linkabsolute": "Дали врските да бидат апсолутни (наспроти релативни)",
+ "semanticmaps-kml-pagelinktext": "Текстот на врските на страницата, каде $1 ќе се замени со насловот на страницата",
+ "semanticmaps-shapes-improperformat": "Несоодветно форматирање на $1. Погледајте во документацијата како треба да се форматира.",
+ "semanticmaps-shapes-missingshape": "Не пронајдов облици за $1. Погледајте во документацијата кои облици ви се на располагање.",
+ "validator-type-mapscircle": "Географски круг",
+ "validator-type-mapscircle-list": "Список на кругови",
+ "validator-type-mapsimageoverlay": "Обложна слика",
+ "validator-type-mapsimageoverlay-list": "Список на обложни слики",
+ "validator-type-mapsline": "Географска линија",
+ "validator-type-mapsline-list": "Список на линии",
+ "validator-type-mapslocation": "Географска месност",
+ "validator-type-mapslocation-list": "Список на месности",
+ "validator-type-mapsrectangle": "Географски правоаголник",
+ "validator-type-mapsrectangle-list": "Список на правоаголници",
+ "validator-type-mapspolygon": "Географски многуаголник",
+ "validator-type-mapspolygon-list": "Список на географски многуаголници",
+ "validator-type-wmsoverlay": "Облога Web Map Service",
+ "validator-type-jsonfile": "текст"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ml.json b/www/wiki/extensions/Maps/i18n/ml.json
new file mode 100644
index 00000000..db56e536
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ml.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "വടക്ക്",
+ "maps-abb-east": "കിഴക്ക്",
+ "maps-abb-south": "തെക്ക്",
+ "maps-abb-west": "പടിഞ്ഞാറ്‌",
+ "maps-latitude": "അക്ഷാംശം:",
+ "maps-longitude": "രേഖാംശം:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/mr.json b/www/wiki/extensions/Maps/i18n/mr.json
new file mode 100644
index 00000000..9f40b7e9
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/mr.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "अक्षांश:",
+ "maps-longitude": "रेखांश:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ms.json b/www/wiki/extensions/Maps/i18n/ms.json
new file mode 100644
index 00000000..bdc7c527
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ms.json
@@ -0,0 +1,158 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia",
+ "Pizza1016",
+ "Macofe",
+ "Jeluang Terluang"
+ ]
+ },
+ "maps-desc": "Membolehkan pembenaman petak dinamik pada laman wiki, pembuatan geokod alamat dan bermacam-macam lagi operasi geografi",
+ "right-geocode": "Geokod",
+ "maps_map": "Peta",
+ "maps-loading-map": "Peta sedang dimuatkan...",
+ "maps-load-failed": "Peta tidak dapat dimuatkan!",
+ "maps-markers": "Penanda",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Penanda penapis",
+ "maps-others": "lain-lain",
+ "maps-ns-layer": "Lapisan",
+ "maps-ns-layer-talk": "Perbincangan lapisan",
+ "maps-layer-property": "Sifat",
+ "maps-layer-value": "Nilai",
+ "maps-layer-errors": "Ralat",
+ "maps-layerdef-invalid": "Definisi{{PLURAL:$1||-definisi}} tidak sah",
+ "maps-error-invalid-layertype": "Tiada lapisan jenis \"$1\". {{PLURAL:$3|Jenis|Jenis-jenis}} ini sahaja yang disokong: $2",
+ "maps-error-no-layertype": "Anda perlu menentukan jenis lapisan. {{PLURAL:$2|Jenis|Jenis-jenis}} ini sahaja yang disokong: $1",
+ "validation-error-invalid-layer": "Parameter $1 mestilah lapisan yang sah.",
+ "validation-error-invalid-layers": "Parameter $1 mestilah sekurang-kurangnya satu lapisan yang sah.",
+ "validation-error-no-non-numeric": "Parameter \"$1\" mestilah rentetan bukan nombor.",
+ "maps-layer-of-type": "Lapisan jenis $1",
+ "maps-layer-of-type-and-name": "Lapisan \"$2\" jenis \"$1\"",
+ "maps-layer-type-supported-by": "Jenis lapisan ini {{PLURAL:$2|hanya boleh digunakan dengan perkhidmatan pemetaan $1|boleh digunakan dengan perkhidmatan-perkhidmatan pemetaan yang berikut: $1}}.",
+ "maps-coordinates-description": "Cangkuk penghurai untuk memformatkan koordinat daripada/kepada sebarang format yang disokong.",
+ "maps-displaymap-description": "Memaparkan peta geografi tanpa sebarang penanda tentuan wiki padanya.",
+ "maps-distance-description": "Menukar nilai jarak yang menggunakan unit disokong yang tertentu kepada setaraannya yang menggunakan unit yang lain.",
+ "maps-finddestination-description": "Mencari tujuan dari satu titik permulaan (yang boleh dinyatakan dalam sebarang format yang disokong), bearing permulaan dan jarak.",
+ "maps-geocode-description": "Membolehkan pembuatan geokod alamat, iaitu menukar lokasi yang boleh dibaca oleh manusia kepada peranggu koordinat. Wujudnya sokongan untuk beberapa perkhidmatan geokod yang tidak boleh disamakan dengan perkhidmatan pemetaan.",
+ "maps-geodistance-description": "Menghitung jarak geografi antara dua titik, daripada/kepada sebarang format yang disokong.",
+ "maps-mapsdoc-description": "Memaparkan jadual parameter untuk perkhidmatan pemetaan tertentu bersama nilai-nilai asali dan keterangannya.",
+ "maps-mapsdoc-par-service": "Perkhidmatan pemetaan untuk memaparkan pendokumenan parameter.",
+ "maps-mapsdoc-par-language": "Bahasa untuk memaparkan pendokumenan. Jika tiada terjemahannya, Bahasa Inggeris digunakan pula.",
+ "maps-coordinates-par-location": "Koordinat yang ingin diformatkan.",
+ "maps-coordinates-par-format": "Format sasaran untuk koordinat.",
+ "maps-coordinates-par-directional": "Menunjukkan sama ada koordinat wajar ditunjukkan berarah atau tidak.",
+ "maps-distance-par-distance": "Nilai jarak yang ingin ditukar kepada setaraannya dengan unit yang tertentu.",
+ "maps-distance-par-decimals": "Bilangan maksimum angka pecahan untuk digunakan dalam nilai hasil.",
+ "maps-distance-par-unit": "Unit paparan nilai jarak.",
+ "maps-finddestination-par-location": "Lokasi permulaan.",
+ "maps-finddestination-par-bearing": "Bearing permulaan.",
+ "maps-finddestination-par-distance": "Jarak perjalanan.",
+ "maps-finddestination-par-format": "Format untuk memaparkan destinasi.",
+ "maps-finddestination-par-directional": "Menunjukkan sama ada format destinasi wajar berarah atau tidak.",
+ "maps-geocode-par-location": "Alamat yang ingin dibuatkan geokod.",
+ "maps-geocode-par-format": "Format koordinat yang terhasil.",
+ "maps-geocode-par-directional": "Menunjukkan sama ada koordinat wajar ditunjukkan berarah atau tidak.",
+ "maps-geodistance-par-location1": "Titik pertama dalam peranggu untuk mengira jarak antara.",
+ "maps-geodistance-par-location2": "Titik kedua dalam peranggu untuk mengira jarak antara.",
+ "maps-geodistance-par-unit": "Unit paparan nilai jarak.",
+ "maps-geodistance-par-decimals": "Bilangan maksimum angka pecahan untuk digunakan dalam nilai hasil.",
+ "maps-displaymap-par-mappingservice": "Membolehkan penetapan perkhidmatan pemetaan yang akan digunakan untuk menghasilkan peta.",
+ "maps-displaymap-par-coordinates": "Lokasi yang akan dijadikan pusat peta pada mulanya.",
+ "maps-displaymap-par-visitedicon": "Lokal fail untuk digunakan sebagai ikon dilawat",
+ "maps-displaymap-par-zoom": "Membolehkan penetapan tahap zum peta.\nApabila tidak diberikan sementara wujudnya berbilang penanda pada peta, zom yang paling muat akan diambil, bukan nilai asali yang terkonfigurasi.",
+ "maps-displaymap-par-centre": "Membolehkan penetapan koordinat pusat peta untuk display_point.\nMenerima alamat dan koordinat sekali.\nApabila sifat ini tidak dinyatakan, peta akan menentukan pusatnya sendiri pada penanda yang diberikan, ataupun di antara penanda-penanda yang diberikan.",
+ "maps-displaymap-par-title": "Membolehkan penetapan teks yang akan dipaparkan dalam tetimbul semua penanda yang tiada tajuk tertentu.\nApabila digunakan bersama label, tajuknya akan berupa tebal dan bergaris bawah.",
+ "maps-displaymap-par-label": "Membolehkan penetapan teks yang akan dipaparkan dalam tetimbul semua penanda yang tiada label tertentu.",
+ "maps-displaymap-par-icon": "Membolehkan penetapan ikon yang digunakan untuk semua penanda.",
+ "maps-displaymap-par-circles": "Bulatan untuk dipaparkan",
+ "maps-displaymap-par-copycoords": "Jika dialog dari mana koordinat sesuatu lokasi harus dipaparkan apabila mengklik sesuatu",
+ "maps-displaymap-par-lines": "Garisan untuk dipaparkan",
+ "maps-displaymap-par-maxzoom": "Takat zum maksimum",
+ "maps-displaymap-par-minzoom": "Takat zum minimum",
+ "maps-displaymap-par-polygons": "Poligon untuk dipaparkan",
+ "maps-displaymap-par-rectangles": "Segiempat untuk dipaparkan",
+ "maps-displaymap-par-static": "Jika peta seharusnya statik",
+ "maps-displaymap-par-wmsoverlay": "Gunakan tindanan WMS",
+ "validation-error-invalid-location": "Parameter $1 mestilah lokasi yang sah.",
+ "validation-error-invalid-locations": "Parameter $1 mestilah sekurang-kurangnya satu lokasi yang sah.",
+ "validation-error-invalid-width": "Parameter $1 mestilah lebar yang sah.",
+ "validation-error-invalid-height": "Parameter $1 mestilah tinggi yang sah.",
+ "validation-error-invalid-distance": "Parameter $1 mestilah jarak yang sah.",
+ "validation-error-invalid-distances": "Parameter $1 mestilah sekurang-kurangnya satu jarak yang sah.",
+ "validation-error-invalid-image": "Parameter $1 mestilah imej yang sah.",
+ "validation-error-invalid-images": "Parameter $1 mestilah sekurang-kurangnya satu imej yang sah.",
+ "validation-error-invalid-goverlay": "Parameter $1 mestilah tindanan yang sah.",
+ "validation-error-invalid-goverlays": "Parameter $1 mestilah sekurang-kurangnya satu tindanan yang sah.",
+ "maps-abb-north": "U",
+ "maps-abb-east": "T",
+ "maps-abb-south": "S",
+ "maps-abb-west": "B",
+ "maps-latitude": "Garis lintang:",
+ "maps-longitude": "Garis bujur:",
+ "maps-invalid-coordinates": "Nilai $1 tidak dikenali sebagai peranggu koordinat yang sah.",
+ "maps_coordinates_missing": "Tiada koordinat diberikan bagi peta.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Alamat|Alamat-alamat}} yang berikut tidak dapat dijadikan geokod: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Alamat|Alamat-alamat}} yang berikut tidak dapat dijadikan geokod dan digugurkan dari peta:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Koordinat|Koordinat-koordinat}} yang berikut tidak dikenali: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Koordinat|Koordinat-koordinat}} yang berikut tidak dikenali dan digugurkan dari peta:\n$1",
+ "maps_map_cannot_be_displayed": "Peta tidak dapat dipaparkan.",
+ "maps-geocoder-not-available": "Tiada ciri geokod Peta. Lokasi anda tidak boleh diberi geokod.",
+ "maps_click_to_activate": "Klik untuk mengaktifkan peta",
+ "maps_centred_on": "Peta berpusat di $1, $2.",
+ "maps-par-mappingservice": "Membolehkan penetapan perkhidmatan pemetaan yang akan digunakan untuk menghasilkan peta.",
+ "maps-par-resizable": "Membolehkan pelarasan saiz peta dengan menyeret sudut kanan bawahnya.",
+ "maps-par-zoom": "Tahap zum peta. Untuk peta yang ada penanda, ini akan berpangkal kepada tahap paling kerap dizumkan yang masih memaparkan semua penanda.",
+ "maps-par-width": "Membolehkan penetapan lebar peta. Pada asali, piksel dianggap sebagai unit, tetapi anda boleh menetapkan mana-mana unit yang berikut: px, ex, em, %.",
+ "maps-par-height": "Membolehkan penetapan tinggi peta. Pada asali, piksel dianggap sebagai unit, tetapi anda boleh menetapkan mana-mana unit yang berikut: px, ex, em, %.",
+ "maps-par-centre": "Lokasi yang hendak dijadikan pusat peta",
+ "maps-par-kml": "Fail-fail KML untuk dimuatkan kepada peta.",
+ "maps-googlemaps3-incompatbrowser": "Pelayar anda tidak serasi dengan Peta Google v3.",
+ "maps-googlemaps3-par-type": "Jenis peta untuk dipaparkan pada mulanya.",
+ "maps-googlemaps3-par-types": "Jenis-jenis peta yang tersedia melalui kawalan jenis.",
+ "maps-googlemaps3-par-layers": "Lapisan khas untuk dimuatkan kepada peta.",
+ "maps-googlemaps3-par-controls": "Alat kawalan untuk diletakkan pada peta.",
+ "maps-googlemaps3-par-zoomstyle": "Gaya kawalan zum.",
+ "maps-googlemaps3-par-typestyle": "Gaya kawalan jenis.",
+ "maps-googlemaps3-par-autoinfowindows": "Membuka semua tetingkap maklumat secara automatik selepas laman dimuatkan.",
+ "maps-googlemaps3-par-gkml": "Fail-fail KML yang dihoskan oleh Google untuk dimuatkan pada peta.",
+ "maps-googlemaps3-par-kmlrezoom": "Zumkan semula peta selepas lapisan-lapisan KML dimuatkan.",
+ "maps-googlemaps3-par-poi": "Tunjukkan tempat-tempat menarik.",
+ "mapeditor": "Editor peta",
+ "specialpages-group-maps": "Peta",
+ "mapeditor-parser-error": "Timbulnya ralat ketika menghuraikan metadata. Input pengguna diabaikan.",
+ "mapeditor-none-text": "Tiada",
+ "mapeditor-done-button": "Siap",
+ "mapeditor-remove-button": "Padamkan",
+ "mapeditor-import-button2": "Import",
+ "mapeditor-export-button": "Eksport ke kod wiki",
+ "mapeditor-import-button": "Import dari kod wiki",
+ "mapeditor-select-button": "Pilih poligon ini",
+ "mapeditor-mapparam-button": "Sunting parameter peta",
+ "mapeditor-clear-button": "Padamkan peta",
+ "mapeditor-code-title": "Kod wiki",
+ "mapeditor-import-title": "Import kod wiki",
+ "mapeditor-import-note": "Sila ambil perhatian bahawa penghurai mengharapkan format yang amat ketat pada kod wiki. Kod yang dimasukkan di sini mestilah sepadan dengan kod yang dikeluarkan oleh kefungsian eksport",
+ "mapeditor-form-title": "Sunting butiran",
+ "mapeditor-link-title-switcher-popup-text": "Tetimbul dengan teks",
+ "mapeditor-link-title-switcher-link-text": "Pautan",
+ "mapeditor-form-field-title": "Tajuk",
+ "mapeditor-form-field-text": "Teks",
+ "mapeditor-form-field-link": "Pautan",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Kumpulan",
+ "mapeditor-form-field-inlinelabel": "Label sebaris",
+ "mapeditor-form-field-strokecolor": "Warna coret",
+ "mapeditor-form-field-strokeopacity": "Kelegapan coret",
+ "mapeditor-form-field-strokeweight": "Berat coret",
+ "mapeditor-form-field-fillcolor": "Warna isi",
+ "mapeditor-form-field-fillopcaity": "Kelegapan isi",
+ "mapeditor-form-field-showonhover": "Tunjukkan dalam keadaan terapung sahaja",
+ "mapeditor-mapparam-title": "Sunting parameter peta",
+ "mapeditor-mapparam-defoption": "-Pilih parameter-",
+ "mapeditor-imageoverlay-button": "Tambah tindihan imej",
+ "mapeditor-form-field-image": "Imej",
+ "mapeditor-imageoverlay-title": "Butiran tindihan imej",
+ "mapeditor-form-field-visitedicon": "Ikon dikunjungi",
+ "semanticmaps-forminput-locations": "Lokasi"
+}
diff --git a/www/wiki/extensions/Maps/i18n/mt.json b/www/wiki/extensions/Maps/i18n/mt.json
new file mode 100644
index 00000000..8335d9f0
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/mt.json
@@ -0,0 +1,48 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chrisportelli"
+ ]
+ },
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "oħrajn",
+ "maps-ns-layer": "Livell",
+ "maps-ns-layer-talk": "Diskussjoni livell",
+ "maps-layer-property": "Proprjetà",
+ "maps-layer-value": "Valur",
+ "maps-layer-errors": "Żbalji",
+ "maps-error-invalid-layertype": "M'hemm l-ebda livell tat-tip \"$1\". {{PLURAL:$3|Dan it-tip biss huwa appoġġjat|Dawn it-tipi biss huma appoġġjati}}: $2",
+ "maps-error-no-layertype": "Trid tispeċifika t-tip ta' livell. {{PLURAL:$2|Dan it-tip biss huwa appoġġjat|Dawn it-tipi biss huma appoġġjati}}: $1",
+ "validation-error-invalid-layer": "Il-parametru $1 irid ikun livell validu.",
+ "validation-error-invalid-layers": "Il-parametru $1 irid ikun wieħed jew iktar livelli validi.",
+ "maps-layer-of-type": "Livell tat-tip $1",
+ "maps-googlemaps3-incompatbrowser": "Il-browżer li qiegħed tuża' mhuwiex kompatibbli ma' Google Maps v3.",
+ "maps-googlemaps3-par-controls": "Il-kontrolli li trid tpoġġi fuq il-mappa.",
+ "maps-googlemaps3-par-poi": "Uri l-punti ta' interess.",
+ "maps-osm-par-thumbs": "Uri l-minjaturi",
+ "maps-osm-par-photos": "Uri r-ritratti",
+ "mapeditor": "Editur tal-mappa",
+ "specialpages-group-maps": "Mapep",
+ "mapeditor-none-text": "L-ebda",
+ "mapeditor-done-button": "Lest",
+ "mapeditor-remove-button": "Neħħi",
+ "mapeditor-import-button2": "Importa",
+ "mapeditor-export-button": "Esporta għal kodiċi wiki",
+ "mapeditor-import-button": "Importa minn kodiċi wiki",
+ "mapeditor-select-button": "Agħżel dan il-poligonu",
+ "mapeditor-mapparam-button": "Immodifika l-parametri tal-mappa",
+ "mapeditor-clear-button": "Naddaf il-mappa",
+ "mapeditor-code-title": "Kodiċi wiki",
+ "mapeditor-import-title": "Importa l-kodiċi wiki",
+ "mapeditor-form-title": "Immodifika d-dettalji",
+ "mapeditor-link-title-switcher-link-text": "Ħolqa",
+ "mapeditor-form-field-title": "Titlu",
+ "mapeditor-form-field-text": "Test",
+ "mapeditor-form-field-link": "Ħolqa",
+ "mapeditor-form-field-icon": "Ikona",
+ "mapeditor-form-field-group": "Grupp",
+ "mapeditor-form-field-fillcolor": "Kulur ta' ġewwa",
+ "mapeditor-form-field-fillopcaity": "Opaċità ta' ġewwa",
+ "mapeditor-mapparam-defoption": "-Agħżel parametru-",
+ "mapeditor-form-field-image": "Stampa"
+}
diff --git a/www/wiki/extensions/Maps/i18n/myv.json b/www/wiki/extensions/Maps/i18n/myv.json
new file mode 100644
index 00000000..ca7ba283
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/myv.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "Веньэльйонкс",
+ "maps-abb-east": "Чилисемайонкс",
+ "maps-abb-south": "Чиньэльйонкс",
+ "maps-abb-west": "Чивалгомайонкс",
+ "maps-latitude": "Келезэ:",
+ "maps-longitude": "Кувалмозо:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/nah.json b/www/wiki/extensions/Maps/i18n/nah.json
new file mode 100644
index 00000000..18f11140
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/nah.json
@@ -0,0 +1,6 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "M",
+ "maps-abb-east": "T",
+ "maps-abb-south": "H"
+}
diff --git a/www/wiki/extensions/Maps/i18n/nb.json b/www/wiki/extensions/Maps/i18n/nb.json
new file mode 100644
index 00000000..7da896db
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/nb.json
@@ -0,0 +1,228 @@
+{
+ "@metadata": {
+ "authors": [
+ "Event",
+ "Kim Eik",
+ "Nghtwlkr",
+ "Danmichaelo",
+ "Macofe",
+ "EvenT",
+ "Jon Harald Søby"
+ ]
+ },
+ "maps-desc": "Gir mulighet for å bygge inn dynamiske kart i wikisider, geokoding av adresser og andre geografiske operasjoner",
+ "right-geocode": "Geokode",
+ "action-geocode": "utføre geokoding på denne wikien",
+ "maps_map": "Kart",
+ "maps-tracking-category": "Sider med kart som vises med kartutvidelsen",
+ "maps-loading-map": "Laster kart...",
+ "maps-load-failed": "Klarte ikke laste kartet.",
+ "maps-markers": "Markører",
+ "maps-copycoords-prompt": "Chrl+C, Enter",
+ "maps-searchmarkers-text": "Filtrer markører",
+ "maps-others": "andre",
+ "maps-kml-parsing-failed": "Klarte ikke å parse én eller flere KML-filer. Dette skjer vanligvis på grunn av en hentingsfeil eller ugyldig XML.",
+ "maps-ns-layer": "Lag",
+ "maps-ns-layer-talk": "Lagdiskusjon",
+ "maps-layer-property": "Egenskap",
+ "maps-layer-value": "Verdi",
+ "maps-layer-errors": "Feil",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Ugyldig definisjon|Ugyldige definisjoner}}",
+ "maps-layerdef-invalid-fatal": "Katastrofalt ugyldig definisjon",
+ "maps-layerdef-wrong-namespace": "Lagdefinisjoner er kun gyldige på sider i navnerommet «$1»",
+ "maps-layerdef-equal-layer-name": "Lagnavn må være unike innen samme lagside. «$1» brukes allerede av et annet lag.",
+ "maps-layerpage-usage": "Sider med kart som bruker laget «$1»",
+ "maps-layerpage-nousage": "Ingen sider bruker dette laget for tiden.",
+ "maps-error-invalid-layertype": "Det er ingen lag av typen «$1». Bare {{PLURAL:$3|denne typen|disse typene}} er støttet: $2",
+ "maps-error-no-layertype": "Du må angi en lagtype. Bare {{PLURAL:$2|denne typen|disse typene}} er støttet: $1",
+ "validation-error-invalid-layer": "Parameter $1 må været et gyldig lag.",
+ "validation-error-invalid-layers": "Parameter $1 må være et eller flere gyldige lag.",
+ "validation-error-no-non-numeric": "Parameteren «$1» må være en ikke-numerisk streng.",
+ "validation-error-no-non-numerics": "Parameteren «$1» må være én eller flere ikke-numeriske strenger.",
+ "maps-layer-of-type": "Lagtype $1",
+ "maps-layer-of-type-and-name": "Lag «$2» av typen «$1»",
+ "maps-layer-type-supported-by": "Denne lagtypen kan bare brukes med {{PLURAL:$2|karttjenesten $1|disse karttjenestene: $1}}.",
+ "maps-coordinates-description": "Parser-hook for å formatere koordinater, fra og til vilkårlige av de støttede formatene.",
+ "maps-displaymap-description": "Vis geografiske kart uten wiki-spesifiserte markører.",
+ "maps-distance-description": "Gjør om en distanse basert på en viss støttet enhet til tilsvarende verdi i en annen enhet.",
+ "maps-finddestination-description": "Finn et mål med gitt startpunkt (som kan være i ett av de støttede formatene), en initial retning og distanse.",
+ "maps-geocode-description": "Gjør tilgjengelig geokoding av adresser, dvs. gjør menneskelesbare lokasjoner til koordinatsett. Det finnes støtte for flere geokodingstjenester, som ikke må forveksles med mappingtjenester.",
+ "maps-geodistance-description": "Beregn den geografiske avstanden mellom to punkter, fra og til et vilkårlig av de støttede formatene.",
+ "maps-mapsdoc-description": "Vis en tabell med parametrene for en spesifisert mappingstjeneste sammen med deres standardverdier og beskrivelser.",
+ "maps-layerdefinition-description": "Beskriver et egendefinert lag som kan vises med andre kartfunksjoner.",
+ "maps-mapsdoc-par-service": "Mappingstjenesten for å vise parameterdokumentasjon.",
+ "maps-mapsdoc-par-language": "Språket for å vise dokumentasjonen. Hvis ingen slik oversettelse er tilgjengelig, blir engelsk brukt.",
+ "maps-coordinates-par-location": "Koordinatene du ønsker å formatere.",
+ "maps-coordinates-par-format": "Målformatet for koordinatene.",
+ "maps-coordinates-par-directional": "Angir om koordinatene burde vises med retning eller ikke.",
+ "maps-par-scrollwheelzoom": "Angir om musbasert skrolling skal aktiveres eller ikke.",
+ "maps-distance-par-distance": "Avstanden som skal omregnes til en bestemt enhet.",
+ "maps-distance-par-decimals": "Maksimalt antall desimalsifre som skal brukes for resulterende verdi.",
+ "maps-distance-par-unit": "Enhet for visning av avstand.",
+ "maps-finddestination-par-location": "Opprinnelig lokasjon.",
+ "maps-finddestination-par-bearing": "Startpeiling.",
+ "maps-finddestination-par-distance": "Reiseavstand",
+ "maps-finddestination-par-format": "Utdataformat for målposisjonen.",
+ "maps-finddestination-par-directional": "Angir om formatet for målposisjonen skal være retningsbasert eller ikke.",
+ "maps-geocode-par-location": "Adressen du ønsker å geokode.",
+ "maps-geocode-par-format": "Formatet for de resulterende koordinatene.",
+ "maps-geocode-par-directional": "Angir om koordinatene skal vises med retning eller ikke.",
+ "maps-geodistance-par-location1": "Første punktet i settet for å beregne avstand.",
+ "maps-geodistance-par-location2": "Andre punktet i settet for å beregne avstand.",
+ "maps-geodistance-par-unit": "Enheten avstanden skal måles i.",
+ "maps-geodistance-par-decimals": "Maksimalt antall desimalsifre som skal brukes i resultatverdien.",
+ "maps-displaymap-par-mappingservice": "Tillater å sette karttjenesten som vil brukes for å skape kartet.",
+ "maps-displaymap-par-coordinates": "En eller flere steder til å markeres på kartet. De blir angitt med en markør.",
+ "maps-displaymap-par-visitedicon": "Filnavnet for bildet som skal brukes som markørikon etter at de opprinnelige markørene har blitt klikket.",
+ "maps-displaymap-par-zoom": "Tillater innstilling av zoom-nivået for kartet.\nHvis nivået ikke er valgt og det er flere markører til stede på kartet, vil det mest passende zoom-nivået bli valgt, ikke standardverdien fra konfigureringen.",
+ "maps-displaymap-par-centre": "Tillater innstilling av koordinatene for sentrum av kartet for display_point(s).\nAksepter både adresser og koordinater.\nHvis denne egenskapene ikke er angitt, vil kartet sentrere seg selv rundt en tilgjengelig markør eller mellom disse om det finnes flere.",
+ "maps-displaymap-par-title": "Tillater å angi tekst som skal vises i popup-vindu for alle markører som mangler en særskilt tittel.\nNår dette anvendes sammen med en etikett, blir tittelen fet og understreket.",
+ "maps-displaymap-par-label": "Tillater å angi tekst som skal vises i popup-vinduet for de markørene som mangler en særskilt etikett.",
+ "maps-displaymap-par-icon": "Tillater å sette ikonet som brukes for alle markørene.",
+ "maps-displaymap-par-circles": "Sirkler å vise",
+ "maps-displaymap-par-copycoords": "Viser en dialog når du klikker på et sted hvorfra du kan kopiere koordinatene.",
+ "maps-displaymap-par-lines": "Linjer å vise",
+ "maps-displaymap-par-maxzoom": "Maksimalt zoomnivå",
+ "maps-displaymap-par-minzoom": "Minste zoomnivå",
+ "maps-displaymap-par-polygons": "Polygoner å vise",
+ "maps-displaymap-par-rectangles": "Rektangler å vise",
+ "maps-displaymap-par-static": "Gjør kartet statisk",
+ "maps-displaymap-par-wmsoverlay": "Legger på et WMS-lag",
+ "maps-displaymap-par-geojson": "URL-en til ei GeoJSON-fil",
+ "maps-fullscreen-button": "Slå av/på fullskjerm",
+ "maps-fullscreen-button-tooltip": "Vis kartet som fullskjerm eller innbygd.",
+ "validation-error-invalid-location": "Parameter $1 må være en gyldig lokasjon.",
+ "validation-error-invalid-locations": "Parameter $1 må være en eller flere gyldige lokasjoner.",
+ "validation-error-invalid-width": "Parameter $1 må være en gyldig bredde.",
+ "validation-error-invalid-height": "Parameter $1 må være en gyldig høyde.",
+ "validation-error-invalid-distance": "Parameter $1 må være en gyldig avstand.",
+ "validation-error-invalid-distances": "Parameter $1 må være en eller flere gyldige avstander.",
+ "validation-error-invalid-image": "Parameter $1 må være et gyldig bilde.",
+ "validation-error-invalid-images": "Parameter $1 må være et eller flere gyldige bilder.",
+ "validation-error-invalid-goverlay": "Parameter $1 må være et gyldig overlegg.",
+ "validation-error-invalid-goverlays": "Parameter $1 må være et eller flere gyldige overlegg.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "Ø",
+ "maps-abb-south": "S",
+ "maps-abb-west": "V",
+ "maps-latitude": "Breddegrad:",
+ "maps-longitude": "Lengdegrad:",
+ "maps-invalid-coordinates": "Verdien $1 ble ikke gjenkjent som et gyldig sett med koordinater.",
+ "maps_coordinates_missing": "Ingen koordinater oppgitt for kartet.",
+ "maps_geocoding_failed": "Følgende {{PLURAL:$2|adresse|adresser}} kunne ikke geokodes: $1.",
+ "maps_geocoding_failed_for": "Følgende {{PLURAL:$2|adresse|adresser}} kunne ikke geokodes og har blitt utelatt fra kartet:\n$1",
+ "maps_unrecognized_coords": "Følgende {{PLURAL:$2|koordinat|koordinat}} ble ikke gjenkjent: $1.",
+ "maps_unrecognized_coords_for": "Følgende {{PLURAL:$2|koordinat|koordinater}} ble ikke gjenkjent og har blitt utelatt fra kartet:\n$1",
+ "maps_map_cannot_be_displayed": "Kartet kan ikke vises.",
+ "maps-geocoder-not-available": "Geokodingsfunksjonen i Maps er ikke tilgjengelig. Din plassering kan ikke geokodes.",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "Tillater å sette standard zoom-nivå for kartet.",
+ "maps-leaflet-par-layers": "Laget som vil vises mens kartet laster.",
+ "maps-leaflet-par-overlaylayers": "Overleggslagene som vises mens kartet lastes.",
+ "maps-leaflet-par-maxclusterradius": "Minimum radius som et kluster dekker fra den sentrale markøren (angitt i piksler)",
+ "maps-leaflet-par-clusterspiderfy": "Når du klikker et kluster ved laveste zoom-nivå, så spres den ut slik at du kan se alle dens markører.",
+ "maps_click_to_activate": "Klikk for å aktivere kartet",
+ "maps_centred_on": "Kart sentrert om $1, $2.",
+ "maps-par-mappingservice": "Tillater å sette karttjenesten som vil brukes for å skape kartet.",
+ "maps-par-resizable": "Gjør at kartets størrelse kan endres ved å dra idets nedre hjørne.",
+ "maps-par-searchmarkers": "Tillater å søke etter spesifikke markører via et felt som er innfestet i kartet.",
+ "maps-par-zoom": "Zoomnivået for kartet. For kart med markører vil standardverdien være den med mest høyest zoom som viser alle markørene.",
+ "maps-par-width": "Tillater at kartbredden angis. Standard enhet er pixler /(px), men du kan alternativt angi ex, em, %.",
+ "maps-par-height": "Tillater at karthøyden angis. Standard enhet er pixler /(px), men du kan alternativt angi ex, em, %.",
+ "maps-par-centre": "Stedet som kartet sentreres rundt",
+ "maps-par-enable-fullscreen": "Aktiver fullskjermknappen",
+ "maps-par-kml": "KML-filer som lastes inn på kortet.",
+ "maps-par-markercluster": "Tillater å slå sammen flere nærliggende markører til en samlet markør",
+ "maps-googlemaps3-incompatbrowser": "Din nettleser er ikke kompatibel med Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Tillater å legge inn et bilde som vises på det angitte stedet på kartet.",
+ "maps-googlemaps3-par-type": "Karttypen som vises initialt.",
+ "maps-googlemaps3-par-types": "Karttypene som vil bli tilgjengelig via typevelger.",
+ "maps-googlemaps3-par-layers": "Spesielle lag som kan lastes inn på kartet.",
+ "maps-googlemaps3-par-controls": "Velgerne som kan plasseres på kartet.",
+ "maps-googlemaps3-par-zoomstyle": "Stilen for zoom-velgeren.",
+ "maps-googlemaps3-par-typestyle": "Stilen for typevelgeren.",
+ "maps-googlemaps3-par-autoinfowindows": "Åpne automatisk alle informasjonsvinduer etter at siden er blitt lastet.",
+ "maps-googlemaps3-par-gkml": "KML-filer, forvaltet av Google, til å legge inn på kartet.",
+ "maps-googlemaps3-par-kmlrezoom": "Zoom tilbake til kartet etter at KML-lagene har blitt lastet.",
+ "maps-googlemaps3-par-poi": "Vis plasser av interesse.",
+ "maps-googlemaps3-par-clustergridsize": "Rutenettstørrelsen for et kluster angitt i piksler.",
+ "maps-par-clustermaxzoom": "Det maksimale zoomnivået der et kluster kan eksistere.",
+ "maps-par-clusterzoomonclick": "Angir at standardoppførselen ved å klikke på et kluster er å zoome inn på det.",
+ "maps-par-maxclusterradius": "Maksimal radius som et kluster kan dekke.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Angir at sentrum for alle kluster bør være middelposisjonen av alle markører i klustret.",
+ "maps-googlemaps3-par-clusterminsize": "Minimalt antall markører i et kluster før markørene skjules og kun antallet vises.",
+ "mapeditor": "Kart tegner",
+ "specialpages-group-maps": "Kart",
+ "mapeditor-parser-error": "En feil oppstod under parsing av data.",
+ "mapeditor-none-text": "Ingen",
+ "mapeditor-done-button": "Ferdig",
+ "mapeditor-remove-button": "Fjern",
+ "mapeditor-import-button2": "Importer",
+ "mapeditor-export-button": "Eksporter til wiki kode",
+ "mapeditor-import-button": "Importer fra wiki kode",
+ "mapeditor-select-button": "Velg dette polygonet",
+ "mapeditor-mapparam-button": "Rediger kart parametere",
+ "mapeditor-clear-button": "Tøm kart",
+ "mapeditor-code-title": "Wiki kode",
+ "mapeditor-import-title": "Importer wiki kode",
+ "mapeditor-import-note": "Vennligst merk at tolkeren krever veldig streng format på wiki koden. Koden bør være lik i struktur som ved eksport funksjonaliteten.",
+ "mapeditor-form-title": "Rediger detaljer",
+ "mapeditor-link-title-switcher-popup-text": "Popup m/tekst",
+ "mapeditor-link-title-switcher-link-text": "Lenke",
+ "mapeditor-form-field-title": "Tittel",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Lenke",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Gruppe",
+ "mapeditor-form-field-inlinelabel": "Merkelapp",
+ "mapeditor-form-field-strokecolor": "Kant farge",
+ "mapeditor-form-field-strokeopacity": "Kant gjennomsiktighet",
+ "mapeditor-form-field-strokeweight": "Kant tykkelse",
+ "mapeditor-form-field-fillcolor": "Fyll farge",
+ "mapeditor-form-field-fillopcaity": "Fyll gjennomsiktighet",
+ "mapeditor-form-field-showonhover": "Vis bare når peker er over.",
+ "mapeditor-mapparam-title": "Rediger kart parametere",
+ "mapeditor-mapparam-defoption": "-Velg parameter-",
+ "mapeditor-imageoverlay-button": "Legg til bilde",
+ "mapeditor-form-field-image": "Bilde",
+ "mapeditor-imageoverlay-title": "Bilde lag detaljer",
+ "mapeditor-form-field-visitedicon": "Besøkt ikon",
+ "semanticmaps-unrecognizeddistance": "Verdien $1 er ikke en gyldig avstand.",
+ "semanticmaps-kml-link": "Vis KML-filen",
+ "semanticmaps-default-kml-pagelink": "Vis siden $1",
+ "semanticmaps-latitude": "Breddegrad: $1",
+ "semanticmaps-longitude": "Lengdegrad: $1",
+ "semanticmaps-altitude": "Høyde over havet: $1",
+ "semanticmaps-forminput-locations": "Lokasjoner",
+ "semanticmaps-par-staticlocations": "En lokasjonsliste til å legge inn i kartet sammen med data fra spørringen. Som med display_points, kan du legge inn en tittel, en beskrivelse og et ikon per lokasjon med tilde \"~\" som skilletegn.",
+ "semanticmaps-par-showtitle": "Vise tittel i markørinfovinduet eller ikke. Deaktivering er ofte nyttig når en bruker en mal for å formatere innholdet i infovinduet.",
+ "semanticmaps-par-hidenamespace": "Vis tittelen for navnerommet i markørens informasjonsboks",
+ "semanticmaps-par-centre": "Kartets sentrum. Hvis dette ikke er angitt, vil kartet automatisk velge det optimale senteret for å vise alle kartmarkørene.",
+ "semanticmaps-par-template": "Mal som brukes for å formatere innholdet i infovinduet.",
+ "semanticmaps-par-geocodecontrol": "Vis geokodingsstyringen",
+ "semanticmaps-par-activeicon": "Ikon som vises istedenfor standardmarkøren, når aktiv side er lik resultatet av spørringen",
+ "semanticmaps-par-pagelabel": "Når satt til \"ja\", vil alle markører ha en \"inlineLabel\" med en lenke til siden som inneholder markørens koordinater",
+ "semanticmaps-par-ajaxcoordproperty": "Navnet på posisjonsegenskapen som vil brukes for å bygge ajax-spørringen.",
+ "semanticmaps-par-ajaxquery": "Den andre spørringen som sendes via ajax for å hente ytterligere koordinater.",
+ "semanticmaps-par-userparam": "Verdi som sendes til hvert malkall, hvis en mal brukes",
+ "semanticmaps-kml-text": "Teksten knyttes til hver side. Overstyrt av spørringer på ekstra egenskaper, om noen.",
+ "semanticmaps-kml-title": "Standard resultatoverskrift",
+ "semanticmaps-kml-linkabsolute": "Skal lenker være absolutte (eller relative)",
+ "semanticmaps-kml-pagelinktext": "Teksten som skal brukes for lenker til siden, der $1 erstattes av sidetittelen",
+ "semanticmaps-shapes-improperformat": "Ulovlig formatering av $1. Vennligst les dokumentasjonen for å korrigere",
+ "semanticmaps-shapes-missingshape": "Ingen figurer funnet for $1. Vennlig bruk tilgjengelige figurer fra dokumentasjonen",
+ "validator-type-mapscircle": "Geografisk sirkel",
+ "validator-type-mapscircle-list": "Liste over sirkler",
+ "validator-type-mapsimageoverlay": "Bildeoverlegg",
+ "validator-type-mapsimageoverlay-list": "Liste over bildeoverlegg",
+ "validator-type-mapsline": "Geografisk linje",
+ "validator-type-mapsline-list": "Liste over linjer",
+ "validator-type-mapslocation": "Geografisk sted",
+ "validator-type-mapslocation-list": "Liste over steder",
+ "validator-type-mapsrectangle": "Geografisk rektangel",
+ "validator-type-mapsrectangle-list": "Liste over rektangler",
+ "validator-type-mapspolygon": "Geografisk polygon",
+ "validator-type-mapspolygon-list": "Liste over geografiske polygoner",
+ "validator-type-wmsoverlay": "Webmappetjensteoverlegg",
+ "validator-type-jsonfile": "URL"
+}
diff --git a/www/wiki/extensions/Maps/i18n/nds.json b/www/wiki/extensions/Maps/i18n/nds.json
new file mode 100644
index 00000000..52c347b7
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/nds.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joachim Mos"
+ ]
+ },
+ "maps_map": "Koort",
+ "maps-layer-property": "Egenschop",
+ "maps-layer-errors": "Fählers",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "mapeditor-none-text": "Keen",
+ "mapeditor-done-button": "Färtig",
+ "mapeditor-code-title": "Wikicode",
+ "mapeditor-link-title-switcher-link-text": "Lenk",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Lenk",
+ "mapeditor-form-field-icon": "Symbool",
+ "mapeditor-form-field-group": "Köppel",
+ "mapeditor-form-field-image": "Bild"
+}
diff --git a/www/wiki/extensions/Maps/i18n/nl-informal.json b/www/wiki/extensions/Maps/i18n/nl-informal.json
new file mode 100644
index 00000000..ad0f967a
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/nl-informal.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Siebrand"
+ ]
+ },
+ "maps-error-no-layertype": "Je moet het laagtype opgeven. Alleen {{PLURAL:$2|dit type wordt|deze typen worden}} ondersteund: $1",
+ "maps-geocoder-not-available": "Geocoderen via Maps is niet beschikbaar. Het geocoderen van je locatie is niet mogelijk.",
+ "maps-par-width": "Maakt het mogelijk om de breedte van de kaart in te stellen. Standaard worden pixels als eenheid gebruikt, maar je kunt expliciet een van deze eenheden opgeven: px, ex, em, %.",
+ "maps-par-height": "Maakt het mogelijk om de hoogte van de kaart in te stellen. Standaard worden pixels als eenheid gebruikt, maar je kunt expliciet een van deze eenheden aangeven: px, ex, em, %.",
+ "maps-googlemaps3-incompatbrowser": "Je browser kan niet werken met Google Maps v3."
+}
diff --git a/www/wiki/extensions/Maps/i18n/nl.json b/www/wiki/extensions/Maps/i18n/nl.json
new file mode 100644
index 00000000..53b3c869
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/nl.json
@@ -0,0 +1,206 @@
+{
+ "@metadata": {
+ "authors": [
+ "AvatarTeam",
+ "Kjell",
+ "Konovalov",
+ "SPQRobin",
+ "Siebrand",
+ "Sjoerddebruin",
+ "Esketti",
+ "MrLeopold",
+ "Hex",
+ "Mainframe98"
+ ]
+ },
+ "maps-desc": "Maakt het insluiten van dynamische kaarten in de wikipagina's, het geocoderen van adressen en andere geografische activiteiten mogelijk",
+ "right-geocode": "Geocoderen",
+ "action-geocode": "doe geocoding op deze wiki",
+ "maps_map": "Kaart",
+ "maps-tracking-category": "Pagina's met een kaart die gerenderd is door de uitbreiding Maps",
+ "maps-loading-map": "Bezig met het laden van de kaart...",
+ "maps-load-failed": "De kaart kon niet geladen worden!",
+ "maps-markers": "Markeringen",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Filtermarkeringen",
+ "maps-others": "anderen",
+ "maps-kml-parsing-failed": "Eén of meer KML-bestanden konden niet verwerkt worden. Dit is meestal te wijten aan het niet kunnen ophalen van het bestand of ongeldige XML.",
+ "maps-ns-layer": "Laag",
+ "maps-ns-layer-talk": "Overleg_laag",
+ "maps-layer-property": "Eigenschap",
+ "maps-layer-value": "Waarde",
+ "maps-layer-errors": "Fouten",
+ "maps-layerdef-invalid": "Ongeldige definitie{{PLURAL:$1||s}}",
+ "maps-layerdef-invalid-fatal": "Fatale ongeldige definitie",
+ "maps-layerdef-wrong-namespace": "Lagendefinities zijn alleen geldig op pagina's van de naamruimte \"$1\"",
+ "maps-layerdef-equal-layer-name": "Lagennamen moeten uniek zijn binnen dezelfde lagenpagina. \"$1'wordt al gebruikt door een andere laag.",
+ "maps-layerpage-usage": "Pagina's met kaarten die laag \"$1\" gebruiken",
+ "maps-layerpage-nousage": "Er zijn op het moment geen pagina's die deze laag gebruiken.",
+ "maps-error-invalid-layertype": "Er zijn geen lagen van het type \"$1\". Alleen {{PLURAL:$3|dit type wordt|deze typen worden}} ondersteund: $2",
+ "maps-error-no-layertype": "U moet het laagtype opgeven. Alleen {{PLURAL:$2|dit type wordt|deze typen worden}} ondersteund: $1",
+ "validation-error-invalid-layer": "Parameter $1 moet een geldige laag zijn.",
+ "validation-error-invalid-layers": "Parameter $1 moet een of meer geldige lagen zijn.",
+ "validation-error-no-non-numeric": "Parameter \"$1\" moet een niet-numerieke tekenreeks zijn.",
+ "validation-error-no-non-numerics": "Parameter \"$1\" moet één of meer niet-numerieke tekenreeksen zijn.",
+ "maps-layer-of-type": "Laag van het type $1",
+ "maps-layer-of-type-and-name": "Laag \"$2\" van het type \"$1\"",
+ "maps-layer-type-supported-by": "Dit laagtype kan {{PLURAL:$2|alleen gebruikt worden met de kaartdienst $1|gebruikt worden met de kaartdiensten $1}}.",
+ "maps-coordinates-description": "Parserhook om coördinaten op te maken, van en naar alle ondersteunde notaties.",
+ "maps-displaymap-description": "Geografische kaarten weergeven zonder in de wiki gedefinieerde markeringen.",
+ "maps-distance-description": "Converteren naar een afstand met behulp van een bepaalde ondersteunde eenheid naar een equivalent in een andere eenheid.",
+ "maps-finddestination-description": "Een bestemming vinden via een gegeven beginpunt (in elke ondersteunde notatie), een richting en een afstand.",
+ "maps-geocode-description": "Maakt het geocoderen van adressen mogelijk, dat wil zeggen dat leesbare locaties worden omgezet in verzamelingen coördinaten. Er is ondersteuning voor verschillende geocoderingsdiensten die niet verward moeten worden met kaartdiensten.",
+ "maps-geodistance-description": "De geografische afstand tussen twee punten berekenen, van en naar alle ondersteunde notaties.",
+ "maps-mapsdoc-description": "Een tabel met de parameters voor een bepaalde kaartdienst weergeven samen met hun standaardwaarde en beschrijving.",
+ "maps-layerdefinition-description": "Beschrijft een aangepaste laag die weergegeven kan worden met andere Kaart-functies.",
+ "maps-mapsdoc-par-service": "De kaartdienst waarvoor parameterdocumentatie weergegeven moet worden.",
+ "maps-mapsdoc-par-language": "De taal waarin de documentatie wordt weergegeven. Indien er geen vertaling beschikbaar is, wordt Engels gebruikt.",
+ "maps-coordinates-par-location": "De op te maken coördinaten.",
+ "maps-coordinates-par-format": "Gewenste notatie voor de coördinaten.",
+ "maps-coordinates-par-directional": "Geeft aan of de coördinaten wel of niet directioneel uitgestuurd moeten worden.",
+ "maps-distance-par-distance": "De afstand om te converteren naar haar equivalent in een opgegeven eenheid.",
+ "maps-distance-par-decimals": "Het maximale aantal te gebruiken decimalen in de resultaatwaarde.",
+ "maps-distance-par-unit": "De eenheid waarin de afstand weergegeven moet worden.",
+ "maps-finddestination-par-location": "De initiële locatie.",
+ "maps-finddestination-par-bearing": "De initiële richting.",
+ "maps-finddestination-par-distance": "De te reizen afstand.",
+ "maps-finddestination-par-format": "De notatie waarin de bestemming weergegeven moet worden.",
+ "maps-finddestination-par-directional": "Geeft aan of de notatie van de bestemming directioneel moet zijn of niet.",
+ "maps-geocode-par-location": "Het te geocoderen adres.",
+ "maps-geocode-par-format": "De notatie voor de resulterende coördinaten.",
+ "maps-geocode-par-directional": "Geeft aan of de coördinaten directioneel uitgevoerd moeten worden of niet.",
+ "maps-geodistance-par-location1": "Het eerste punt in de verzameling om de afstand tussen te berekenen.",
+ "maps-geodistance-par-location2": "Het tweede punt in de verzameling om de afstand tussen te berekenen.",
+ "maps-geodistance-par-unit": "De eenheid om de afstand in weer te geven.",
+ "maps-geodistance-par-decimals": "Het maximale aantal te gebruiken decimalen in de resulterende waarde.",
+ "maps-displaymap-par-mappingservice": "Maakt het mogelijk om de kaartdienst in te stellen die wordt gebruikt om de kaart te maken.",
+ "maps-displaymap-par-coordinates": "De locatie die zich bij de eerste keer laden in het centrum van de kaart bevindt.",
+ "maps-displaymap-par-visitedicon": "De bestandsnaam van een afbeelding voen gebruik als markeringspictogrammen nadat op de oorspronkelijke markeringen is geklikt",
+ "maps-displaymap-par-zoom": "Maakt het mogelijk het schaalniveau van de kaart in te stellen.\nAls deze waarde niet wordt ingesteld en er staan meerdere markers op de kaart, dan wordt het best passende schaalniveau gekozen, niet het instelbare standaardniveau.",
+ "maps-displaymap-par-centre": "Maakt het mogelijk de coördinaten voor het midden van de kaart in te stellen voor display_point(s).\nKan ingesteld worden met adressen en coördinaten.\nAls deze waarde niet wordt ingesteld, wordt de kaart gecentreerd op of tussen de opgegeven marker(s).",
+ "maps-displaymap-par-title": "Maakt het mogelijk om tekst in te stellen die wordt weergegeven in de pop-ups van alle markeringen zonder gespecificeerde naam.\nAls dit samen met een label wordt gebruikt, wordt de titel vetgedrukt en onderstreept weergegeven.",
+ "maps-displaymap-par-label": "Maakt het mogelijk om tekst in te stellen die wordt weergegeven in de pop-ups van alle markeringen zonder gespecificeerd label.",
+ "maps-displaymap-par-icon": "Maakt het mogelijk het pictogram voor alle markers in te stellen.",
+ "maps-displaymap-par-circles": "Weer te geven cirkels",
+ "maps-displaymap-par-copycoords": "Dialoogvenster weergeven na klikken op een locatie waarvan de coördinaten gekopieerd kunnen worden",
+ "maps-displaymap-par-lines": "Weer te geven regels",
+ "maps-displaymap-par-maxzoom": "Het maximale zoomniveau",
+ "maps-displaymap-par-minzoom": "Het minimale zoomniveau",
+ "maps-displaymap-par-polygons": "Weer te geven polygonen",
+ "maps-displaymap-par-rectangles": "Weer te geven rechthoeken",
+ "maps-displaymap-par-static": "Maak de kaart statisch",
+ "maps-displaymap-par-wmsoverlay": "WMS-overlay gebruiken",
+ "maps-fullscreen-button": "Volledig scherm in- of uitschakelen",
+ "maps-fullscreen-button-tooltip": "De kaart als volledig scherm of ingesloten bekijken.",
+ "validation-error-invalid-location": "Parameter $1 moet een geldige locatie zijn.",
+ "validation-error-invalid-locations": "Parameter $1 moet een of meer geldige locaties zijn.",
+ "validation-error-invalid-width": "Parameter $1 moet een geldige breedte zijn.",
+ "validation-error-invalid-height": "Parameter $1 moet een geldige hoogte zijn.",
+ "validation-error-invalid-distance": "Parameter $1 moet een geldige afstand zijn.",
+ "validation-error-invalid-distances": "Parameter $1 moet een of meer geldige afstanden zijn.",
+ "validation-error-invalid-image": "Parameter $1 moet een geldige afbeelding zijn.",
+ "validation-error-invalid-images": "Parameter $1 moet een of meer geldige afbeeldingen zijn.",
+ "validation-error-invalid-goverlay": "Parameter $1 moet een geldige overlay zijn.",
+ "validation-error-invalid-goverlays": "Parameter $1 moet een of meer geldige overlays zijn.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "Z",
+ "maps-abb-west": "W",
+ "maps-latitude": "Breedtegraad:",
+ "maps-longitude": "Lengtegraad:",
+ "maps-invalid-coordinates": "De waarde \"$1\" is niet herkend als geldige coördinaten.",
+ "maps_coordinates_missing": "Er zijn geen coördinaten opgegeven voor de kaart.",
+ "maps_geocoding_failed": "Voor {{PLURAL:$2|het volgende adres|de volgende adressen}} was geocodering niet mogelijk: $1\nDe kaart kan niet worden weergegeven.",
+ "maps_geocoding_failed_for": "Voor {{PLURAL:$2|het volgende adres|de volgende adressen}} was geocodering niet mogelijk en {{PLURAL:$2|dit is|deze zijn}} weggelaten uit de kaart:\n$1",
+ "maps_unrecognized_coords": "De volgende {{PLURAL:$2|coördinaat is|coördinaten zijn}} niet herkend: $1.",
+ "maps_unrecognized_coords_for": "De volgende {{PLURAL:$2|coördinaat is niet herkend en is|coördinaten zijn niet herkend en zijn}} weggelaten uit de kaart:\n$1.",
+ "maps_map_cannot_be_displayed": "De kaart kan niet weergegeven worden.",
+ "maps-geocoder-not-available": "Geocoderen via Maps is niet beschikbaar. Het geocoderen van uw locatie is niet mogelijk.",
+ "maps_click_to_activate": "Klik om de kaart te activeren",
+ "maps_centred_on": "Kaart gecentreerd op $1, $2.",
+ "maps-par-mappingservice": "Maakt het mogelijk om de kaartdienst in te stellen die wordt gebruikt om de kaart te maken.",
+ "maps-par-resizable": "Maakt het mogelijk de afmetingen van de kaart te wijzigen door aan de rechter onderhoek te trekken.",
+ "maps-par-searchmarkers": "Maakt het mogelijk om te zoeken naar specifieke markers via een veld ingebed in de kaart.",
+ "maps-par-zoom": "Het zoomniveau van de kaart. Voor kaarten met markers is dit standaard op de meest ingezoomde niveau waarop nog steeds alle markers zichtbaar zijn.",
+ "maps-par-width": "Maakt het mogelijk om de breedte van de kaart in te stellen. Standaard worden pixels als eenheid gebruikt, maar u kunt expliciet een van deze eenheden opgeven: px, ex, em, %.",
+ "maps-par-height": "Maakt het mogelijk om de hoogte van de kaart in te stellen. Standaard worden pixels als eenheid gebruikt, maar u kunt expliciet een van deze eenheden opgeven: px, ex, em, %.",
+ "maps-par-centre": "De locatie waar de kaart op gecentreerd moet worden",
+ "maps-par-enable-fullscreen": "Knop voor volledig scherm inschakelen",
+ "maps-par-kml": "Op de kaart te laden KML-bestanden.",
+ "maps-par-markercluster": "Laat het samenvoegen van meerdere markers in de buurt in één markering",
+ "maps-googlemaps3-incompatbrowser": "Uw browser kan niet werken met Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Laat het toevoegen van een afbeelding worden weergegeven op de opgegeven locatie op de kaart.",
+ "maps-googlemaps3-par-type": "Het initieel weer te geven kaarttype.",
+ "maps-googlemaps3-par-types": "De kaarttypen die beschikbaar zijn in via het besturingselement type.",
+ "maps-googlemaps3-par-layers": "Op de kaart te laden speciale lagen.",
+ "maps-googlemaps3-par-controls": "De op de kaart te plaatsen besturingselementen.",
+ "maps-googlemaps3-par-zoomstyle": "De stijl van het besturingselement zoom.",
+ "maps-googlemaps3-par-typestyle": "De stijl van het besturingselement type.",
+ "maps-googlemaps3-par-autoinfowindows": "Automatisch alle informatievensters openen na het laden van een pagina.",
+ "maps-googlemaps3-par-gkml": "KML-bestanden die gehost worden door Google om op de kaart te laden.",
+ "maps-googlemaps3-par-kmlrezoom": "Het zoomniveau van de kaart opnieuw instellen als de KML-lagen geladen zijn.",
+ "maps-googlemaps3-par-poi": "Interessante plaatsen weergeven.",
+ "maps-par-clustermaxzoom": "Het maximale zoomniveau waar clusters kunnen bestaan.",
+ "mapeditor": "Kaarteditor",
+ "specialpages-group-maps": "Kaarten",
+ "mapeditor-parser-error": "Er is een fout opgetreden tijdens het verwerken van metagegevens. De gebruikersinvoer wordt genegeerd.",
+ "mapeditor-none-text": "Geen",
+ "mapeditor-done-button": "Afgerond",
+ "mapeditor-remove-button": "Verwijderen",
+ "mapeditor-import-button2": "Importeren",
+ "mapeditor-export-button": "Exporteren naar wikicode",
+ "mapeditor-import-button": "Importeren vanuit wikicode",
+ "mapeditor-select-button": "Deze polygoon selecteren",
+ "mapeditor-mapparam-button": "Kaartparameters bewerken",
+ "mapeditor-clear-button": "Kaartmarkeringen wissen",
+ "mapeditor-code-title": "Wikicode",
+ "mapeditor-import-title": "Wikicode importeren",
+ "mapeditor-import-note": "Let op: de parser verwacht een strikte opmaak van de wikicode. De hier opgegeven code moet gelijk zijn aan de code die wordt uitgevoerd door de exportfunctie.",
+ "mapeditor-form-title": "Details bewerken",
+ "mapeditor-link-title-switcher-popup-text": "Pop-up met tekst",
+ "mapeditor-link-title-switcher-link-text": "Koppeling",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Koppeling",
+ "mapeditor-form-field-icon": "Pictogram",
+ "mapeditor-form-field-group": "Groep",
+ "mapeditor-form-field-inlinelabel": "Inline label",
+ "mapeditor-form-field-strokecolor": "Lijnkleur",
+ "mapeditor-form-field-strokeopacity": "Lijndoorzichtigheid",
+ "mapeditor-form-field-strokeweight": "Lijngewicht",
+ "mapeditor-form-field-fillcolor": "Opvulkleur",
+ "mapeditor-form-field-fillopcaity": "Opvulkleurdoorzichtigheid",
+ "mapeditor-form-field-showonhover": "Alleen weergeven bij erboven zweven",
+ "mapeditor-mapparam-title": "Kaartparameters bewerken",
+ "mapeditor-mapparam-defoption": "- Selecteer een parameter -",
+ "mapeditor-imageoverlay-button": "Afbeeldingslaag toevoegen",
+ "mapeditor-form-field-image": "Afbeelding",
+ "mapeditor-imageoverlay-title": "Gegevens over afbeeldingslaag",
+ "mapeditor-form-field-visitedicon": "Pictogram voor bezocht",
+ "semanticmaps-unrecognizeddistance": "De waarde \"$1\" is geen geldige afstand.",
+ "semanticmaps-kml-link": "KML-bestand bekijken",
+ "semanticmaps-default-kml-pagelink": "Pagina $1 bekijken",
+ "semanticmaps-latitude": "Breedtegraad: $1",
+ "semanticmaps-longitude": "Lengtegraad: $1",
+ "semanticmaps-altitude": "Hoogte: $1",
+ "semanticmaps-forminput-locations": "Locaties",
+ "semanticmaps-par-staticlocations": "Een lijst met aan de kaart toe te voegen locaties samen met de opgegeven gegevens. Zoals bij display_points, kunt u een naam, beschrijving en pictogram per locatie toevoegen door de tilde (\"~\") als scheidingsteken te gebruiken.",
+ "semanticmaps-par-showtitle": "Een naam weergeven in het gegevensvenster van de markering of niet. Dit uitschakelen is vaak handig als er een sjabloon wordt gebruikt om de inhoud van het gegevensvenster vorm te geven.",
+ "semanticmaps-par-hidenamespace": "De naamruimtenaam in het informatievenster van de marker weergeven",
+ "semanticmaps-par-centre": "Het centrum van de kaart. Als deze waarde niet wordt opgegeven, wordt automatisch een keuze gemaakt voor een centrum op basis van alle markeringen op de kaart.",
+ "semanticmaps-par-template": "Een te gebruiken sjabloon om de inhoud van het gegevensvenster op te maken.",
+ "semanticmaps-par-geocodecontrol": "Besturingselement voor geocodering weergeven.",
+ "semanticmaps-par-activeicon": "Pictogram dat wordt weergegeven in plaats van de standaard marker, als de actieve pagina gelijk is aan het zoekresultaat",
+ "semanticmaps-par-pagelabel": "Wanneer dit is ingesteld op \"yes\", krijgen alle markers een \"inlineLabel\" met een koppeling naar de pagina waarop de coördinaten voor de marker staan",
+ "semanticmaps-kml-text": "De tekst die gekoppeld is aan iedere pagina. Als er extra opgegeven eigenschappen zijn, wordt deze tekst daardoor overschreven.",
+ "semanticmaps-kml-title": "De standaard titel voor resultaten",
+ "semanticmaps-kml-linkabsolute": "Moeten koppelingen absoluut zijn (in tegenstelling tot relatief)",
+ "semanticmaps-kml-pagelinktext": "De tekst om te gebruiken voor de koppelingen naar de pagina, waarin $1 vervangen wordt door de paginanaam",
+ "semanticmaps-shapes-improperformat": "Onjuiste opmaak van $1. Raadpleeg de documentatie voor de juiste opmaak",
+ "semanticmaps-shapes-missingshape": "Geen vormen gevonden voor $1. Raadpleeg de documentatie voor beschikbare vormen",
+ "validator-type-mapscircle-list": "Lijst van circels",
+ "validator-type-mapsline-list": "Lijst met lijnen",
+ "validator-type-mapslocation-list": "Lijst met locaties",
+ "validator-type-mapsrectangle-list": "Lijst met rechthoeken",
+ "validator-type-jsonfile": "tekst"
+}
diff --git a/www/wiki/extensions/Maps/i18n/nn.json b/www/wiki/extensions/Maps/i18n/nn.json
new file mode 100644
index 00000000..d2ce8781
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/nn.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Harald Khan",
+ "Njardarlogar"
+ ]
+ },
+ "maps_map": "Kart",
+ "maps-abb-north": "N",
+ "maps-abb-east": "A",
+ "maps-abb-south": "S",
+ "maps-abb-west": "V",
+ "maps-latitude": "Breiddegrad:",
+ "maps-longitude": "Lengdegrad:",
+ "maps_coordinates_missing": "Ingen koordinatar vart oppgjevne for kartet.",
+ "maps_unrecognized_coords": "Dei fylgjande koordinatane vart ikkje kjende att: $1.",
+ "maps_map_cannot_be_displayed": "Kartet kan ikkje verta vist.",
+ "maps_click_to_activate": "Trykk for å aktivera kartet",
+ "maps_centred_on": "Kart sentrert på $1, $2."
+}
diff --git a/www/wiki/extensions/Maps/i18n/oc.json b/www/wiki/extensions/Maps/i18n/oc.json
new file mode 100644
index 00000000..5560c7b4
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/oc.json
@@ -0,0 +1,74 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Permet d'afichar de mapas dinamicas dins las paginas del wiki, d'adreças geoencodadas e d'autras operacions geograficas",
+ "right-geocode": "Geocòde",
+ "maps_map": "Mapa",
+ "maps-loading-map": "Cargament de la mapa...",
+ "maps-load-failed": "Impossible de cargar la mapa !",
+ "maps-markers": "Marcadors",
+ "maps-copycoords-prompt": "CTRL+C, ENTRADA",
+ "maps-searchmarkers-text": "Marcadors de filtre",
+ "maps-others": "autres",
+ "maps-ns-layer": "Jaç",
+ "maps-ns-layer-talk": "Discussion jaç",
+ "maps-layer-property": "Proprietat",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Errors",
+ "validation-error-no-non-numerics": "Lo paramètre « $1 » deu èsser una o mantuna cadenas non numericas.",
+ "validation-error-invalid-locations": "Lo paramètre $1 deu èsser un o mantun emplaçament valid(s).",
+ "validation-error-invalid-width": "Lo paramètre $1 deu èsser una largor valida.",
+ "validation-error-invalid-height": "Lo paramètre $1 deu èsser una nautor valida.",
+ "validation-error-invalid-distance": "Lo paramètre $1 deu èsser una distància valida.",
+ "validation-error-invalid-distances": "Lo paramètre $1 deu èsser una o mantuna distància valida(s).",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitud :",
+ "maps-longitude": "Longitud :",
+ "maps_coordinates_missing": "Cap de coordenada es pas estada provesida pel plan.",
+ "maps_geocoding_failed": "{{PLURAL:$2|L'adreça seguenta a pas pogut èsser geoencodada|Las adreças seguentas an pas pogut èsser geoencodadas}} : $1.\nLo plan pòt pas èsser afichat.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|L'adreça seguenta a pas pogut èsser geoencodada|Las adreças seguentas an pas pogut èsser geoencodadas}} e {{PLURAL:$2|es pas afichada|son pas afichadas}} sul plan : $1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|La coordenada seguenta es pas estada reconeguda|Las coordenadas seguentas son pas estadas reconegudas}} : $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|La coordenada seguenta es pas estada reconeguda|Las coordenadas seguentas son pas estadas reconegudas}} e {{PLURAL:$2|es estada omesa|son estadas omesas}} sus la mapa :\n$1",
+ "maps_map_cannot_be_displayed": "La mapa pòt pas èsser afichada.",
+ "maps_leaflet": "Desplegant",
+ "maps_click_to_activate": "Clicar per activar la mapa",
+ "maps_centred_on": "Mapa centrada sus $1, $2.",
+ "mapeditor": "Editor de mapa",
+ "specialpages-group-maps": "Mapas",
+ "mapeditor-none-text": "Pas cap",
+ "mapeditor-done-button": "Fait",
+ "mapeditor-remove-button": "Suprimir",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Exportar en còdi wiki",
+ "mapeditor-import-button": "Importar a partir de còdi wiki",
+ "mapeditor-link-title-switcher-link-text": "Ligam",
+ "mapeditor-form-field-title": "Títol",
+ "mapeditor-form-field-text": "Tèxte",
+ "mapeditor-form-field-link": "Ligam",
+ "mapeditor-form-field-icon": "Icòna",
+ "mapeditor-form-field-group": "Grop",
+ "mapeditor-form-field-inlinelabel": "Etiqueta en linha",
+ "mapeditor-form-field-strokecolor": "Color de trait",
+ "mapeditor-form-field-strokeopacity": "Opacitat del trait",
+ "mapeditor-form-field-strokeweight": "Grossor de trait",
+ "mapeditor-form-field-image": "Imatge",
+ "semanticmaps-unrecognizeddistance": "La valor $1 es pas una distància valida",
+ "semanticmaps-kml-link": "Veire lo fichièr KML",
+ "semanticmaps-default-kml-pagelink": "Veire l’article $1",
+ "semanticmaps-latitude": "Latitud : $1",
+ "semanticmaps-longitude": "Longitud : $1",
+ "semanticmaps-altitude": "Altitud : $1",
+ "semanticmaps-forminput-locations": "Emplaçaments",
+ "semanticmaps-par-staticlocations": "Una lista dels endreches d'apondre a la mapa amb las donadas demandadas. Coma amb display_points, podètz apondre un títol, una descripcion e una icòna per emplaçament en utilizant la tilda « ~ » coma separador.",
+ "semanticmaps-par-geocodecontrol": "Afichar lo contraròtle de geoencodatge.",
+ "semanticmaps-kml-title": "Lo títol per defaut pels resultats",
+ "validator-type-mapslocation-list": "Lista dels emplaçaments",
+ "validator-type-mapsrectangle-list": "Lista dels rectangles"
+}
diff --git a/www/wiki/extensions/Maps/i18n/or.json b/www/wiki/extensions/Maps/i18n/or.json
new file mode 100644
index 00000000..defcdd93
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/or.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Odisha1"
+ ]
+ },
+ "maps-others": "ବାକିସବୁ",
+ "maps-ns-layer": "ସ୍ତର",
+ "maps-layer-value": "ମୂଲ୍ୟ"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pa.json b/www/wiki/extensions/Maps/i18n/pa.json
new file mode 100644
index 00000000..cfb243c4
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pa.json
@@ -0,0 +1,72 @@
+{
+ "@metadata": {
+ "authors": [
+ "Babanwalia"
+ ]
+ },
+ "right-geocode": "ਜੀਓਕੋਡ",
+ "maps_map": "ਨਕਸ਼ਾ",
+ "maps-loading-map": "ਨਕਸ਼ਾ ਲੋਡ ਹੋ ਰਿਹਾ ਹੈ...",
+ "maps-load-failed": "ਨਕਸ਼ਾ ਲੋਡ ਨਾ ਹੋ ਸਕਿਆ!",
+ "maps-markers": "ਮਾਰਕਰ",
+ "maps-copycoords-prompt": "CTRL+C, ਐਂਟਰ",
+ "maps-searchmarkers-text": "ਮਾਰਕਰ ਛਾਣੋ",
+ "maps-others": "ਹੋਰ",
+ "maps-ns-layer": "ਪਰਤ",
+ "maps-ns-layer-talk": "ਤਹਿਨੁਮਾ ਗੱਲਬਾਤ",
+ "maps-layer-property": "ਮਲਕੀਅਤ",
+ "maps-layer-value": "ਮੁੱਲ",
+ "maps-layer-errors": "ਦੋਸ਼",
+ "validation-error-invalid-layer": "ਮਾਪਦੰਡ $1 ਇੱਕ ਸਹੀ ਪਰਤ ਹੋਣੀ ਚਾਹੀਦੀ ਹੈ।",
+ "maps-layer-of-type": "$1 ਕਿਸਮ ਦੀ ਪਰਤ",
+ "maps-distance-par-unit": "ਵਿੱਥ ਵਿਖਾਉਣ ਲਈ ਇਕਾਈ",
+ "maps-finddestination-par-location": "ਮੁਢਲੀ ਸਥਿਤੀ",
+ "maps-finddestination-par-bearing": "ਮੁਢਲੀ ਦਿਸ਼ਾ",
+ "maps-finddestination-par-distance": "ਗਾਹੁਣ ਲਈ ਵਿੱਥ",
+ "maps-geocode-par-location": "ਉਹ ਪਤਾ ਜਿਹਨੂੰ ਤੁਸੀਂ ਜੀਓਕੋਡ ਕਰਨਾ ਚਾਹੁੰਦੇ ਹੋ",
+ "maps-geodistance-par-unit": "ਵਿੱਥ ਵਿਖਾਉਣ ਲਈ ਇਕਾਈ",
+ "maps-displaymap-par-circles": "ਵਿਖਾਉਣ ਲਈ ਚੱਕਰ",
+ "maps-displaymap-par-lines": "ਵਿਖਾਉਣ ਲਈ ਰੇਖਾਵਾਂ",
+ "maps-displaymap-par-maxzoom": "ਵੱਧ ਤੋਂ ਵੱਧ ਜ਼ੂਮ ਪੱਧਰ",
+ "maps-displaymap-par-minzoom": "ਘੱਟੋ ਘੱਟ ਜ਼ੂਮ ਪੱਧਰ",
+ "maps-displaymap-par-polygons": "ਵਿਖਾਉਣ ਲਈ ਬਹੁਭੁਜ",
+ "maps-displaymap-par-rectangles": "ਵਿਖਾਉਣ ਲਈ ਚਤੁਰਭੁਜ",
+ "maps-abb-north": "ਉ",
+ "maps-abb-east": "ਪੂ",
+ "maps-abb-south": "ਦ",
+ "maps-abb-west": "ਪ",
+ "maps-latitude": "ਅਕਸ਼ਾਂਸ਼:",
+ "maps-longitude": "ਰੇਖਾਂਸ਼:",
+ "maps_coordinates_missing": "ਇਸ ਨਕਸ਼ੇ ਲਈ ਕੋਈ ਗੁਣਕ ਨਹੀਂ ਹਨ।",
+ "maps_map_cannot_be_displayed": "ਇਹ ਨਕਸ਼ਾ ਵਿਖਾਇਆ ਨਹੀਂ ਜਾ ਸਕਦਾ।",
+ "maps_click_to_activate": "ਨਕਸ਼ਾ ਕਿਰਿਆਸ਼ੀਲ ਬਣਾਉਣ ਲਈ ਕਲਿੱਕ ਕਰੋ",
+ "maps_centred_on": "$1, $2 ਉੱਤੇ ਕੇਂਦਰਤ ਨਕਸ਼ਾ।",
+ "maps-par-centre": "ਉਹ ਥਾਂ ਜਿਸ ਉੱਤੇ ਨਕਸ਼ਾ ਕੇਂਦਰਤ ਹੋਣਾ ਚਾਹੀਦਾ ਹੈ",
+ "maps-googlemaps3-incompatbrowser": "ਤੁਹਾਡਾ ਬਰਾਊਜ਼ਰ Google Maps v3 ਨਾਲ਼ ਕੰਮ ਕਰਨ ਲਈ ਅਨੁਕੂਲ ਨਹੀਂ ਹੈ।",
+ "maps-googlemaps3-par-layers": "ਨਕਸ਼ੇ ਉੱਤੇ ਲੋਡ ਕਰਨ ਲਈ ਖ਼ਾਸ ਪਰਤਾਂ।",
+ "mapeditor": "ਨਕਸ਼ਾ ਸੰਪਾਦਕ",
+ "specialpages-group-maps": "ਨਕਸ਼ੇ",
+ "mapeditor-none-text": "ਕੋਈ ਨਹੀਂ",
+ "mapeditor-done-button": "ਹੋ ਗਿਆ",
+ "mapeditor-remove-button": "ਹਟਾਓ",
+ "mapeditor-import-button2": "ਮੰਗਾਓ",
+ "mapeditor-export-button": "ਵਿਕੀ ਕੋਡ ਨੂੰ ਭੇਜੋ",
+ "mapeditor-import-button": "ਵਿਕੀ ਕੋਡ ਤੋਂ ਮੰਗਾਓ",
+ "mapeditor-select-button": "ਇਹ ਬਹੁਭੁਜ ਚੁਣੋ",
+ "mapeditor-mapparam-button": "ਨਕਸ਼ੇ ਦੇ ਮਾਪਦੰਡ ਸੋਧੋ",
+ "mapeditor-clear-button": "ਨਕਸ਼ਾ ਸਾਫ਼ ਕਰੋ",
+ "mapeditor-code-title": "ਵਿਕੀ ਕੋਡ",
+ "mapeditor-import-title": "ਵਿਕੀ ਕੋਡ ਮੰਗਾਓ",
+ "mapeditor-form-title": "ਸੋਧ ਦਾ ਬਿਉਰਾ",
+ "mapeditor-link-title-switcher-link-text": "ਕੜੀ",
+ "mapeditor-form-field-title": "ਸਿਰਲੇਖ",
+ "mapeditor-form-field-text": "ਲਿਖਤ",
+ "mapeditor-form-field-link": "ਕੜੀ",
+ "mapeditor-form-field-icon": "ਆਇਕਨ",
+ "mapeditor-form-field-group": "ਟੋਲੀ",
+ "mapeditor-form-field-fillcolor": "ਰੰਗ ਭਰੋ",
+ "mapeditor-form-field-showonhover": "ਸਿਰਫ਼ ਉੱਤੇ ਮੰਡਰਾਉਣ 'ਤੇ ਵਿਖਾਓ",
+ "mapeditor-mapparam-title": "ਨਕਸ਼ੇ ਦੇ ਮਾਪਦੰਡ ਸੋਧੋ",
+ "mapeditor-mapparam-defoption": "-ਮਾਪਦੰਡ ਚੁਣੋ-",
+ "mapeditor-form-field-image": "ਤਸਵੀਰ"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pdc.json b/www/wiki/extensions/Maps/i18n/pdc.json
new file mode 100644
index 00000000..3c5335d5
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pdc.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xqt"
+ ]
+ },
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pfl.json b/www/wiki/extensions/Maps/i18n/pfl.json
new file mode 100644
index 00000000..dd936687
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pfl.json
@@ -0,0 +1,53 @@
+{
+ "@metadata": {
+ "authors": [
+ "Manuae"
+ ]
+ },
+ "maps_map": "Kaad",
+ "maps-loading-map": "Die Kaad werd glaade …",
+ "maps-load-failed": "Die Kaad hod net glaade were kenne.",
+ "maps-markers": "Kennzaischnunge",
+ "maps-copycoords-prompt": "STRG+C, ENTER",
+ "maps-others": "onnare",
+ "maps-ns-layer": "Ewene",
+ "maps-layer-property": "Aischeschafd",
+ "maps-layer-value": "Werd",
+ "maps-error-invalid-layertype": "S'hod kä Ewene vunde Ard „$1“. Bloß {{PLURAL:$3|die Ard werd|die Arde weren}} unaschdidzd: $2",
+ "maps-error-no-layertype": "Du mugschd die Ard vunde Ewene ogewe. Bloß {{PLURAL:$2|die Ard werd|die Arde weren}} unaschdidzd: $1",
+ "validation-error-invalid-layer": "Parameter $1 muss ä gildische Ewene soi.",
+ "validation-error-invalid-layers": "Parameter $1 muss minischdns ä gildische Ewene soi.",
+ "maps-layer-of-type": "Ewene vunde Ard $1",
+ "maps-layer-type-supported-by": "Die Ard vun Ewene konn {{PLURAL:$2|bloß baim Kaadeweese $1 bnudzd were|bai dene Kaadeweese bnudzd were: $1}}.",
+ "maps-distance-description": "Nemmä unaschdidzdi Greeß un wondl die Dischdonz inän enschbrechende, awa onare Werd um.",
+ "maps-finddestination-par-location": "De Ausgongspungd",
+ "maps-finddestination-par-bearing": "Die Ausgongspailung",
+ "maps-finddestination-par-distance": "Wie waid weg bischd.",
+ "validation-error-invalid-location": "Parameter $1 mussn gildische Schdondord soi.",
+ "validation-error-invalid-locations": "Parameter $1 muss minischdns än gildische Schdondord soi.",
+ "validation-error-invalid-width": "Parameter $1 muss ä gildischi Braid soi.",
+ "validation-error-invalid-height": "Parameter $1 muss ä gildische Hee soi.",
+ "validation-error-invalid-distance": "Parameter $1 muss ä gildischi Dischdonz soi.",
+ "validation-error-invalid-distances": "Parameter $1 muss minischdns ä gildischi Dischdonz soi.",
+ "validation-error-invalid-image": "Parameter $1 muss ä gildisches Bild soi.",
+ "validation-error-invalid-images": "Parameter $1 muss minischdns ä gildisches Bild soi.",
+ "validation-error-invalid-goverlay": "Parameter $1 mussn gildischi Iwalachachung soi.",
+ "validation-error-invalid-goverlays": "Parameter $1 muss minischdns ä gildischi Iwalachachung soi.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "O",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Braidegrad:",
+ "maps-longitude": "Längegrad:",
+ "maps-invalid-coordinates": "De Werd $1 isch kä gildisches Paa vun Koordinaade.",
+ "maps_coordinates_missing": "S'hod kä Koordinaade uff de Kaad.",
+ "maps_geocoding_failed": "Die {{PLURAL:$2|folschnd Adress hod|folschnde Adresse hawen}} ned umgwondld were kenne: $1.",
+ "maps_geocoding_failed_for": "Die {{PLURAL:$2||folschnd Adress hod|folschnde Adresse hawen}} ned gfunne were kenne un {{PLURAL:$2|isch|sin}} uff de Kaad ned druff:\n$1",
+ "maps_unrecognized_coords": "Die {{PLURAL:$2|folschnd Koordinaad|folschnde Koordinaade}} hodma ned erkennd: $1.",
+ "maps_unrecognized_coords_for": "Die {{PLURAL:$2|folschnd Koordinaad|folschnde Koordinaade}} hodma ned erkennd un {{PLURAL:$2|isch|sin}} uff de Kaad ned druff:\n$1",
+ "maps_map_cannot_be_displayed": "Die Kaad komma ned zaische.",
+ "maps_click_to_activate": "Um die Kaad oazuschalde, mugschd druffdrigge",
+ "maps_centred_on": "Die Kaad isch uff $1, $2 inde Midd.",
+ "maps-googlemaps3-par-kmlrezoom": "Nomol die Kaad vagreeßere, wonn die KML-Ewene druff glaade worre sin.",
+ "maps-osm-par-photos": "Fodografieje zaische"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pl.json b/www/wiki/extensions/Maps/i18n/pl.json
new file mode 100644
index 00000000..54a813bf
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pl.json
@@ -0,0 +1,168 @@
+{
+ "@metadata": {
+ "authors": [
+ "BeginaFelicysym",
+ "Chrumps",
+ "Sp5uhe",
+ "Ty221",
+ "Yarl",
+ "Alan ffm",
+ "Macofe",
+ "Deejay1",
+ "Railfail536"
+ ]
+ },
+ "maps-desc": "Umożliwia zamieszczanie na stronach wiki map dynamicznych, geokodowanych adresów i innych danych geograficznych",
+ "right-geocode": "Geokodowanie",
+ "maps_map": "Mapa",
+ "maps-loading-map": "Wczytywanie mapy…",
+ "maps-load-failed": "Nie można załadować mapy!",
+ "maps-markers": "Zaznaczenia",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "inne",
+ "maps-kml-parsing-failed": "Błąd podczas parsowania jednego lub więcej plików KML, najczęściej jest to wynik błędnego XML",
+ "maps-ns-layer": "Warstwa",
+ "maps-ns-layer-talk": "Dyskusja warstwy",
+ "maps-layer-property": "Własność",
+ "maps-layer-value": "Wartość",
+ "maps-layer-errors": "Błędy",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Nieprawidłowa definicja|Nieprawidłowe definicje}}",
+ "maps-layerpage-usage": "Strony z mapami z warstwą „$1”",
+ "maps-layerpage-nousage": "Nie ma stron, które używają w tej chwili tej warstwy.",
+ "maps-error-invalid-layertype": "Brak warstw typu „$1”. {{PLURAL:$3|Wspierany jest wyłącznie typ|Wspierane są wyłącznie typy:}} $2",
+ "maps-error-no-layertype": "Musisz określić typ warstwy. {{PLURAL:$2|Wspierany jest wyłącznie typ|Wspierane są wyłącznie typy:}} $1",
+ "validation-error-invalid-layer": "Parametr $1 musi określać prawidłową warstwę.",
+ "validation-error-invalid-layers": "Parametr $1 musi wskazywać jedną lub więcej prawidłowych warstw.",
+ "validation-error-no-non-numeric": "Parametr „$1” musi być ciągiem nienumerycznym.",
+ "maps-layer-of-type": "Warstwa typu $1",
+ "maps-layer-of-type-and-name": "Warstwa „$2” typu „$1”",
+ "maps-layer-type-supported-by": "Tego typu warstwa może być używana wyłącznie z {{PLURAL:$2|serwisem map|serwisami map:}} $1.",
+ "maps-coordinates-description": "Przechwycenie analizatora do formatowania współrzędnych z i na dowolny z obsługiwanych formatów.",
+ "maps-displaymap-description": "Wyświetlanie map geograficznych bez żadnych naniesionych na nich znaczników na wiki.",
+ "maps-distance-description": "Konwertuj odległości za pomocą pewnych obsługiwanych jednostek do ich odpowiedników w innych jednostkach.",
+ "maps-finddestination-description": "Znajdź drogę do celu z podanego punktu początkowego, (który może być w dowolnym z obsługiwanych formatów), początkowy namiar i odległości.",
+ "maps-geocode-description": "Umożliwia geokodowanie adresów, innymi słowy, przekształcenie zapisu miejsca czytelnego dla ludzi w zbiory współrzędnych. Obsługiwane jest kilka usług geokodowania, których nie należy mylić z usługami dostarczania map.",
+ "maps-geodistance-description": "Oblicz odległość geograficzną między dwoma punktami wskazanymi w jednym z obsługiwanych formatów.",
+ "maps-mapsdoc-description": "Wyświetl tabelę parametrów dla określonej usługi dostarczania map wraz z ich wartościami domyślnymi i opisami.",
+ "maps-mapsdoc-par-service": "Usługa dostarczania map do wyświetlenia dokumentacji parametru.",
+ "maps-mapsdoc-par-language": "Język wyświetlania dokumentacji. Jeśli takie tłumaczenie nie jest dostępne, zostanie użyty angielski.",
+ "maps-coordinates-par-location": "Współrzędne, które chcesz sformatować.",
+ "maps-coordinates-par-format": "Format docelowy dla współrzędnych.",
+ "maps-coordinates-par-directional": "Wskazuje, czy współrzędne powinny być wyświetlone kierunkowo czy nie.",
+ "maps-distance-par-distance": "Odległość do konwersji na odpowiednik w określonych jednostkach.",
+ "maps-distance-par-decimals": "Maksymalna liczba cyfr części ułamkowej w wartości wynikowej.",
+ "maps-distance-par-unit": "Jednostka wynikowa odległości.",
+ "maps-finddestination-par-location": "Położenie początkowe.",
+ "maps-finddestination-par-bearing": "Kierunek początkowy.",
+ "maps-finddestination-par-distance": "Odległość podróży.",
+ "maps-geocode-par-location": "Adres, który chcesz geokodować.",
+ "maps-geocode-par-format": "Format wynikowych współrzędnych.",
+ "maps-geodistance-par-unit": "Jednostka wynikowa odległości.",
+ "maps-geodistance-par-decimals": "Maksymalna liczba cyfr części ułamkowej w wartości wynikowej.",
+ "maps-displaymap-par-coordinates": "Jedna lub więcej lokalizacji do wyświetlenia na mapie. Zostaną oznaczone znacznikiem.",
+ "maps-displaymap-par-circles": "Okręgi do wyświetlenia",
+ "maps-displaymap-par-lines": "Linie do wyświetlenia",
+ "maps-displaymap-par-maxzoom": "Maksymalny poziom powiększenia",
+ "maps-displaymap-par-minzoom": "Minimalny poziom powiększenia",
+ "maps-displaymap-par-polygons": "Wielokąty do wyświetlenia",
+ "maps-displaymap-par-rectangles": "Prostokąty do wyświetlenia",
+ "maps-displaymap-par-static": "Uczyń mapę statyczną",
+ "maps-displaymap-par-wmsoverlay": "Użyj nakładki WMS",
+ "maps-displaymap-par-geojson": "Adres URL pliku lub nazwa strony zawierającej dane GeoJSON",
+ "maps-fullscreen-button": "Przełącz na tryb pełnoekranowy",
+ "maps-fullscreen-button-tooltip": "Zobacz mapę jako pełnoekranową lub osadzoną.",
+ "validation-error-invalid-location": "Parametr $1 musi wskazywać prawidłową lokalizację.",
+ "validation-error-invalid-locations": "Parametr $1 musi wskazywać jedną lub więcej prawidłowych lokalizacji.",
+ "validation-error-invalid-width": "Parametr $1 musi określać prawidłową szerokość.",
+ "validation-error-invalid-height": "Parametr $1 musi określać prawidłową wysokość.",
+ "validation-error-invalid-distance": "Parametr $1 musi określać prawidłową odległość.",
+ "validation-error-invalid-distances": "Parametr $1 musi określać jedną lub więcej prawidłowych odległości.",
+ "validation-error-invalid-image": "Parametr $1 musi określać prawidłową grafikę.",
+ "validation-error-invalid-images": "Parametr $1 musi wskazywać jedną lub więcej prawidłowych grafik.",
+ "validation-error-invalid-goverlay": "Parametr $1 musi być prawidłową nakładką.",
+ "validation-error-invalid-goverlays": "Parametr $1 musi być jedną lub więcej prawidłową nakładką.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Szerokość geograficzna",
+ "maps-longitude": "Długość geograficzna",
+ "maps-invalid-coordinates": "Wartość $1 nie została rozpoznana jako prawidłowe współrzędne.",
+ "maps_coordinates_missing": "Brak współrzędnych dla mapy.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Następującego adresu nie można odnaleźć na mapie|Następujących adresów nie można odnaleźć na mapie:}} $1.\nMapa nie może zostać wyświetlona.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Następujący adres został pominięty, ponieważ nie można go odnaleźć na mapie|Następujące adresy zostały pominięte, ponieważ nie można ich odnaleźć na mapie:}} $1.",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Następująca współrzędna nie została rozpoznana –|Następujące współrzędne nie zostały rozpoznane:}} $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Następującą współrzędną|Następujące współrzędne}} pominięto, ponieważ nie {{PLURAL:$2|została rozpoznana|zostały rozpoznane}}:\n$1",
+ "maps_map_cannot_be_displayed": "Mapa nie może zostać wyświetlona.",
+ "maps-geocoder-not-available": "Funkcja geokodowania map nie jest dostępna. Lokalizacja nie może zostać zakodowana.",
+ "maps-leaflet-par-defzoom": "Umożliwia ustawienie domyślnego poziomu powiększenia mapy.",
+ "maps-leaflet-par-layers": "Warstwa, która będzie wyświetlana podczas ładowania mapy.",
+ "maps-leaflet-par-overlaylayers": "Nakładane warstwy, które będą wyświetlane podczas ładowania mapy.",
+ "maps_click_to_activate": "Kliknij, aby aktywować mapę",
+ "maps_centred_on": "Środek mapy – $1, $2.",
+ "maps-par-resizable": "Zmienia rozmiar mapy przez przeciąganie prawego dolnego rogu.",
+ "maps-par-centre": "Lokalizacja, w której mapa powinna być wyśrodkowana",
+ "maps-par-enable-fullscreen": "Włącz przycisk trybu pełnoekranowego",
+ "maps-par-kml": "Pliki KML do załadowania na mapie.",
+ "maps-googlemaps3-incompatbrowser": "Twoja przeglądarka nie jest zgodna z Google Maps v3.",
+ "maps-googlemaps3-par-type": "Typ mapy do wyświetlenia na początku.",
+ "maps-googlemaps3-par-types": "Typy map, które będą dostępne za pośrednictwem formantu typu.",
+ "maps-googlemaps3-par-layers": "Specjalne warstwy do załadowania na mapie.",
+ "maps-googlemaps3-par-controls": "Formanty do umieszczenia na mapie.",
+ "maps-googlemaps3-par-zoomstyle": "Styl formantu powiększenia.",
+ "maps-googlemaps3-par-typestyle": "Styl formantu typu.",
+ "maps-googlemaps3-par-autoinfowindows": "Automatycznie otwórz wszystkie okna informacyjne po załadowaniu strony.",
+ "maps-googlemaps3-par-gkml": "Pliki KML udostępniane przez serwery Google do załadowania na mapie.",
+ "maps-googlemaps3-par-poi": "Pokaż atrakcje.",
+ "maps-googlemaps3-par-clustergridsize": "Rozmiar siatki klastra w pikselach.",
+ "maps-par-clustermaxzoom": "Maksymalny poziom powiększenia, w którym klaster może istnieć.",
+ "maps-par-maxclusterradius": "Maksymalny promień, który obejmuje klaster.",
+ "mapeditor": "Edytor map",
+ "specialpages-group-maps": "Mapy",
+ "mapeditor-none-text": "Brak",
+ "mapeditor-done-button": "Gotowe",
+ "mapeditor-remove-button": "Usuń",
+ "mapeditor-import-button2": "Importuj",
+ "mapeditor-export-button": "Eksport do kodu wiki",
+ "mapeditor-import-button": "Import z kodu wiki",
+ "mapeditor-select-button": "Wybierz ten wielokąt",
+ "mapeditor-mapparam-button": "Edytuj parametry mapy",
+ "mapeditor-clear-button": "Wyczyść mapę",
+ "mapeditor-code-title": "Kod wiki",
+ "mapeditor-import-title": "Import kodu wiki",
+ "mapeditor-import-note": "Zwróć uwagę że parser oczekuje kodu wiki w bardzo określonym formacie. Umieszczone tutaj źródło powinno odpowiadać kodowy wygenerowanemu przez narzędzie do eksportu mapy.",
+ "mapeditor-form-title": "Edytuj szczegóły",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Tytuł",
+ "mapeditor-form-field-text": "Tekst",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Ikona",
+ "mapeditor-form-field-group": "Grupa",
+ "mapeditor-form-field-fillcolor": "Kolor wypełnienia",
+ "mapeditor-form-field-showonhover": "Pokaż tylko po najechaniu",
+ "mapeditor-mapparam-title": "Edytuj ustawienia mapy",
+ "mapeditor-mapparam-defoption": "-Wybierz parametr-",
+ "mapeditor-form-field-image": "Grafika",
+ "semanticmaps-unrecognizeddistance": "Wartość $1 nie jest poprawną odległością.",
+ "semanticmaps-kml-link": "Wyświetla plik KML",
+ "semanticmaps-default-kml-pagelink": "Pokaż stronę $1",
+ "semanticmaps-latitude": "Szerokość geograficzna: $1",
+ "semanticmaps-longitude": "Długość geograficzna: $1",
+ "semanticmaps-altitude": "Wysokość: $1",
+ "semanticmaps-forminput-locations": "Miejsca",
+ "semanticmaps-par-geocodecontrol": "Pokaż kontrolę geokodowania.",
+ "semanticmaps-par-ajaxcoordproperty": "Nazwa właściwości współrzędnych, która jest używana do tworzenia zapytania AJAX.",
+ "semanticmaps-kml-title": "Domyślny tytuł wyników",
+ "validator-type-mapscircle": "Koło geograficzne",
+ "validator-type-mapscircle-list": "Lista kół",
+ "validator-type-mapsimageoverlay": "Nakładanie obrazu",
+ "validator-type-mapsline": "Linia geograficzna",
+ "validator-type-mapsline-list": "Lista linii",
+ "validator-type-mapslocation": "Położenie geograficzne",
+ "validator-type-mapslocation-list": "Lista lokalizacji",
+ "validator-type-mapsrectangle": "Prostokąt geograficzny",
+ "validator-type-mapsrectangle-list": "Lista prostokątów",
+ "validator-type-mapspolygon": "Wielokąt geograficzny",
+ "validator-type-mapspolygon-list": "Lista wielokątów geograficznych",
+ "validator-type-jsonfile": "tekst"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pms.json b/www/wiki/extensions/Maps/i18n/pms.json
new file mode 100644
index 00000000..5e8b86b2
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pms.json
@@ -0,0 +1,174 @@
+{
+ "@metadata": {
+ "authors": [
+ "Borichèt",
+ "Dragonòt",
+ "McDutchie",
+ "පසිඳු කාවින්ද",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "A abìlita l'anseriment dle carte dinàmiche ant le pàgine ëd la wiki, dj'adrësse geocodificà e d'àutre operassion geogràfiche",
+ "right-geocode": "Geocodìfica",
+ "maps_map": "Pian",
+ "maps-loading-map": "Cariament ëd la carta...",
+ "maps-load-failed": "As peul pa cariesse la carta!",
+ "maps-markers": "Marcador",
+ "maps-copycoords-prompt": "CTRL+C, A CAP",
+ "maps-searchmarkers-text": "Marcador ëd filtr",
+ "maps-others": "àutri",
+ "maps-ns-layer": "Livel",
+ "maps-ns-layer-talk": "Ciaciarada ëd livel",
+ "maps-layer-property": "Propietà",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Eror",
+ "maps-error-invalid-layertype": "A-i é pa gnun livej ëd sòrt \"$1\". A {{PLURAL:$3|l'é mach mantùa costa|a son mach mantnùe coste}} sòrt: $2",
+ "maps-error-no-layertype": "A dev specifiché la sòrt ëd livel. Mach {{PLURAL:$2|sta sòrt a l'é mantnùa|ste sòrt a son mantnùe}}: $1",
+ "validation-error-invalid-layer": "Ël paràmetr $1 a dev esse un livel bon.",
+ "validation-error-invalid-layers": "Ël paràmetr $1 a dev esse un o pi livej bon.",
+ "maps-layer-of-type": "Livel ëd sòrt $1",
+ "maps-layer-type-supported-by": "Costa sòrt ëd livel a peul {{PLURAL:$2|mach esse dovrà con ël servissi ëd cartografìa $1|esse dovrà con sti servissi ëd cartografìa: $1}}.",
+ "maps-coordinates-description": "Gancio ëd l'analisator për formaté le coordinà, da e vers qualsëssìa dij formà mantnù.",
+ "maps-displaymap-description": "Visualisé le carte geogràfiche sensa gnun marcador definì ëd wiki ansima a lor.",
+ "maps-distance-description": "Convertì na distansa dovrand na serta unità mantnùa an sò equivalent dovrand n'àutra unità.",
+ "maps-finddestination-description": "Trové na destinassion dàit un pont ëd partensa (che a peul esse an qualsëssìa dij formà mantnù), n'orientassion inissial e na distansa.",
+ "maps-geocode-description": "A abìlita la geocodìfica d'adrësse, an d'àutre paròle, la trasformassion dle posission lesìbij da n'uman an ansema ëd coordinà. Vàire sërvissi ëd geocodìfica a son mantnù, lòn che a dev nen esse confondù con ij sërvissi ëd cartografìa.",
+ "maps-geodistance-description": "Calcolé la distansa geogràfica tra doi pont, da e vers qualsëssìa dij formà mantnù.",
+ "maps-mapsdoc-description": "Visualisé na tàula con ij paràmetr për un servissi specìfich ëd cartografìa ansema con ij sò valor predefinì e soe descrission.",
+ "maps-mapsdoc-par-service": "Ël sërvissi ëd cartografìaa për mostré la documentassion dij paràmetr.",
+ "maps-mapsdoc-par-language": "La lenga ant la qual mostré la documentassion. Se gnun-a tradussion a l'é disponìbil, al pòst a sarà dovrà l'Anglèis.",
+ "maps-coordinates-par-location": "Le coordinà ch'it veule formaté.",
+ "maps-coordinates-par-format": "Ël formà destinassion për le coordinà.",
+ "maps-coordinates-par-directional": "A ìndica se le coordinà a devo esse stampà diressionaj o nò.",
+ "maps-distance-par-distance": "La distansa da convertì a sò equivalent con n'unità specificà.",
+ "maps-distance-par-decimals": "Ël nùmer màssim ëd gifre frassionaj da dovré ant ël valor arzultant.",
+ "maps-distance-par-unit": "L'unità pr'ëstampé la distansa.",
+ "maps-finddestination-par-location": "La locassion inissial.",
+ "maps-finddestination-par-bearing": "La posission inissial.",
+ "maps-finddestination-par-distance": "La distansa da viagé.",
+ "maps-finddestination-par-format": "Ël formà ant ël qual ësmon-e la destinassion.",
+ "maps-finddestination-par-directional": "A ìndica se ël formà dla destinassion a dev esse diressional o pa.",
+ "maps-geocode-par-location": "L'adrëssa ch'it veule geocodifiché.",
+ "maps-geocode-par-format": "Ël formà për le coordinà arzultante.",
+ "maps-geocode-par-directional": "A ìndica se le coordinà a devo esse stampà diressionaj o nò.",
+ "maps-geodistance-par-location1": "Ël prim pont ant l'ansema për calcolé la distansa.",
+ "maps-geodistance-par-location2": "Lë scond pont ant l'ansema për calcolé la distansa.",
+ "maps-geodistance-par-unit": "L'unità da dovré për mostré la distansa.",
+ "maps-geodistance-par-decimals": "Ël nùmer màssim ëd gifre frassionaj da dovré ant ël valor arzultant.",
+ "maps-displaymap-par-mappingservice": "A përmët d'amposté ël sërvissi ëd cartografìa che a sarà dovrà për generé la carta.",
+ "maps-displaymap-par-coordinates": "Un-a o pi locassion da smon-e an sla carta. A saran mostrà con na marca.",
+ "maps-displaymap-par-visitedicon": "L'element local ëd n'archivi da dovré com plancia visità",
+ "maps-displaymap-par-zoom": "A përmët d'amposté ël livel d'angrandiment ëd la carta.\nQuand nen dàit e pi marche a son presente an sla carta, a sarà dovrà ël mej angrandiment, pa la configurassion predefinìa.",
+ "maps-displaymap-par-centre": "A përmët d'amposté le coordinà dël sénter ëd la carta për display_point(s).\nA aceta sia adrësse che coordinà.\nQuand sta propietà a l'é pa fornìa, la carta as sentrerà an sla marca dàita, o tra le marche dàite.",
+ "maps-displaymap-par-title": "A përmët d'amposté dël test che a sarà smonì ant le fnestre ch'as duverto ëd tute le marche che a l'han pa un tìtol specificà.\nQuand a l'é dovrà con la tichëtta, ël tìtol a sarà an grassèt e sotlinià.",
+ "maps-displaymap-par-label": "A përmët d'amposté dël test che a sarà smonù ant le fnestre ch'as duverto ëd tute le marche che a l'han pa na tichëtta spessìfica.",
+ "maps-displaymap-par-icon": "A përmët d'amposté la plancia dovrà për tuti ij marcador.",
+ "maps-displaymap-par-circles": "Sercc da mostré",
+ "maps-displaymap-par-copycoords": "Se na casela ëd diàlogh anté che le coordinà ëd na locassion a devo esse smonùe quand a së sgnaca su quaicòs",
+ "maps-displaymap-par-lines": "Linie da smon-e",
+ "maps-displaymap-par-maxzoom": "Ël livel d'angrandiment màssim",
+ "maps-displaymap-par-minzoom": "Ël livel d'angrandiment mìnim",
+ "maps-displaymap-par-polygons": "Polìgon da smon-e",
+ "maps-displaymap-par-rectangles": "Retàngoj da smon-e",
+ "maps-displaymap-par-static": "Se la carta a dev esse stàtica",
+ "maps-displaymap-par-wmsoverlay": "Dovré na covertura WMS",
+ "validation-error-invalid-location": "Ël paràmetr $1 a dev esse na locassion bon-a.",
+ "validation-error-invalid-locations": "Ël paràmetr $1 a dev esse un-a o pi locassion bon-e.",
+ "validation-error-invalid-width": "Ël paràmetr $1 a dev esse na larghëssa bon-a.",
+ "validation-error-invalid-height": "Ël paràmetr $1 a dev esse n'autëssa bon-a.",
+ "validation-error-invalid-distance": "Ël valor $1 a deuv esse na distansa bon-a.",
+ "validation-error-invalid-distances": "Ël paràmetr $1 a dev esse un-a o pi distanse bon-e.",
+ "validation-error-invalid-image": "Ël paràmetr $1 a dev esse na figura bon-a.",
+ "validation-error-invalid-images": "Ël paràmetr $1 a dev esse un-a o pi figure bon-e.",
+ "validation-error-invalid-goverlay": "Ël paràmetr $1 a dev esse un coatament bon.",
+ "validation-error-invalid-goverlays": "Ël paràmetr $1 a dev esse un o pi coatament bon.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "W",
+ "maps-latitude": "Latitùdin:",
+ "maps-longitude": "Longitùdin:",
+ "maps-invalid-coordinates": "Ël valor $1 a l'é pa stàit arconossù con n'ansema bon ëd coordinà.",
+ "maps_coordinates_missing": "Pa gnun-e coordinà dàite për la mapa.",
+ "maps_geocoding_failed": "{{PLURAL:$2|L'adrëssa|J'adrësse}} sì sota a peulo pa esse sota geocode: $1.\nLa mapa a peul pa esse visualisà.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|L'adrëssa|J'adrësse}} sì sota a peula pa esse sota geocode e a {{PLURAL:$2|l'é pa stàita|son pa stàite}} butà ant la mapa: $1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|La coordinà sota a l'é pa stàita arconossùa|Le coordinà sota a son pa stàite arconossùe}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|La coordinatà sota a l'é pa stàita arconossùa|Le coordinà sota a son pa stàite arconossùe}} e a {{PLURAL:$2|l'é stàita|a son stàite}} pa butà ant la carta:\n$1",
+ "maps_map_cannot_be_displayed": "La carta a peul pa esse mostrà.",
+ "maps-geocoder-not-available": "La possibilità ëd geocodìfica dle carte a l'é pa disponìbil. Soa locassion a peul pa esse geocodificà.",
+ "maps_click_to_activate": "Sgnaca për ativé la carta",
+ "maps_centred_on": "Carta sentrà su $1, $2.",
+ "maps-par-mappingservice": "A përmët d'amposté ël sërvissi ëd cartografìa che a sarà dovrà për generé la carta.",
+ "maps-par-resizable": "A rend la carta ridimensionàbil an spostand sò canton an bass a drita.",
+ "maps-par-zoom": "Ël livel d'angrandiment për la carta. Për le carte con dij marcador cost-sì as predefinirà al livel pi agrandì che a smon anco' tuti ij marcador.",
+ "maps-par-width": "A përmët d'amposté la larghëssa dla carta. Për predefinission ij pontin a saran contà com unità, ma a peul specifiché ëd fasson esplìssita un-a ëd coste unità: px, ex, em, %.",
+ "maps-par-height": "A përmët d'amposté l'autëssa dla carta. Për predefinission ij pontin a saran considerà com unità, ma a peul ëspessifiché ëd fasson esplìssita un-a ëd coste unità: px, ex, em, %.",
+ "maps-par-centre": "Ël pòst anté che la carta a dovrà esse sentrà",
+ "maps-par-kml": "Archivi KML da carié dzora a la carta.",
+ "maps-googlemaps3-incompatbrowser": "Tò navigator a l'é pa compatìbil con Google Maps v3.",
+ "maps-googlemaps3-par-type": "La sòrt ëd carta da smon-e inissialment.",
+ "maps-googlemaps3-par-types": "La sòrt ëd carta che a sarà disponìbil travers al contròl ëd sòrt.",
+ "maps-googlemaps3-par-layers": "Seuli speciaj da carié an sla carta.",
+ "maps-googlemaps3-par-controls": "Ël control da piassé an sla carta.",
+ "maps-googlemaps3-par-zoomstyle": "Lë stil dël contròl d'angrandiment.",
+ "maps-googlemaps3-par-typestyle": "Lë stil dël contròl ëd sòrt.",
+ "maps-googlemaps3-par-autoinfowindows": "Duverté automaticament tute le fnestre d'anformassion apress che la pàgina a l'é cariasse.",
+ "maps-googlemaps3-par-gkml": "Archivi KML ospità da Google da carié dzor la carta.",
+ "maps-googlemaps3-par-kmlrezoom": "Angrandì torna la carta na vira che ij seuj KML a son stàit carià.",
+ "maps-googlemaps3-par-poi": "Smon-e ij pont d'anteresse.",
+ "mapeditor": "Editor ëd carta",
+ "specialpages-group-maps": "Carte",
+ "mapeditor-parser-error": "A l'é capitaje n'eror an analisand dij metadat. Ignorà l'anseriment ëd l'utent.",
+ "mapeditor-none-text": "Gnun",
+ "mapeditor-done-button": "Fàit",
+ "mapeditor-remove-button": "Gava",
+ "mapeditor-import-button2": "Ampòrta",
+ "mapeditor-export-button": "Esporté an còdes wiki",
+ "mapeditor-import-button": "Ampòrta da còdes wiki",
+ "mapeditor-select-button": "Selessioné ës polìgon",
+ "mapeditor-mapparam-button": "Modifiché ij paràmetr ëd la carta",
+ "mapeditor-clear-button": "Scancelé la carta",
+ "mapeditor-code-title": "Còdes wiki",
+ "mapeditor-import-title": "Amporté ël còdes wiki",
+ "mapeditor-import-note": "Për piasì, ch'a nòta che l'analisator a së speta un formà motobin limità an sël còdes wiki. Ël còdes anserì ambelessì a dovrìa corisponde al còdes generà da la fonsionalità d'esportassion.",
+ "mapeditor-form-title": "Modifiché ij detaj",
+ "mapeditor-link-title-switcher-popup-text": "Fnestra ch'as duverta con test",
+ "mapeditor-link-title-switcher-link-text": "Anliura",
+ "mapeditor-form-field-title": "Tìtol",
+ "mapeditor-form-field-text": "Test",
+ "mapeditor-form-field-link": "Anliura",
+ "mapeditor-form-field-icon": "Plancia",
+ "mapeditor-form-field-group": "Partìa",
+ "mapeditor-form-field-inlinelabel": "Tichëtta an linia",
+ "mapeditor-form-field-strokecolor": "Color dël trat",
+ "mapeditor-form-field-strokeopacity": "Opassità dël trat",
+ "mapeditor-form-field-strokeweight": "Pèis dël trat",
+ "mapeditor-form-field-fillcolor": "Color d'ampiniment",
+ "mapeditor-form-field-fillopcaity": "Opassità d'ampiniment",
+ "mapeditor-form-field-showonhover": "Mostré mach cand a-i passa ël rat dëdzora",
+ "mapeditor-mapparam-title": "Modifiché ij paràmetr ëd la carta",
+ "mapeditor-mapparam-defoption": "-Ch'a selession-a un paràmetr-",
+ "mapeditor-imageoverlay-button": "Gionté la dzorposission ëd plancia",
+ "mapeditor-form-field-image": "Figura",
+ "mapeditor-imageoverlay-title": "Detaj dla dzorposission ëd plancia",
+ "mapeditor-form-field-visitedicon": "Plancia visità",
+ "semanticmaps-unrecognizeddistance": "Ël valor $1 a l'é pa na distansa bon-a.",
+ "semanticmaps-kml-link": "Vëdde l'archivi KML",
+ "semanticmaps-default-kml-pagelink": "Lese la pàgina $1",
+ "semanticmaps-latitude": "Latitùdin: $1",
+ "semanticmaps-longitude": "Longitùdin: $1",
+ "semanticmaps-altitude": "Autitùdin: $1",
+ "semanticmaps-forminput-locations": "Locassion",
+ "semanticmaps-par-staticlocations": "Na lista ëd locassion da gionté a la carta ansema ai dat ciamà. Com con dispay_points, a peul gionté un tìtol, na descrission e na plancia për locassion an dovrand la tilde \"~\" com separator.",
+ "semanticmaps-par-showtitle": "Smon-e un tìtol ant la fnesta d'anformassion dël marcator opura nò. La disabilitassion ëd sòn a l'é soens ùtil quand as deuvra në stamp për formaté ël contnù dla fnesta d'anformassion.",
+ "semanticmaps-par-hidenamespace": "Mostré ël tìtol dlë spassi nominal ant la fnestra d'anformassion dël marcador.",
+ "semanticmaps-par-centre": "Ël sènter ëd la carta. Quand a l'é pa dàit, la carta a trovrà automaticament ël sènter otimal për smon-e tùit ij marcador an sla carta.",
+ "semanticmaps-par-template": "Në stamp da dovré deje a forma ai contnù dla fnesta d'anformassion.",
+ "semanticmaps-par-geocodecontrol": "Smon-e ël contròl ëd geocodìfica.",
+ "semanticmaps-kml-text": "Ël test associà con minca pagina. Coatà da le propietà adissionaj ciamà s'a-i në j'é.",
+ "semanticmaps-kml-title": "Ël tìtol predefinì për j'arzultà",
+ "semanticmaps-kml-linkabsolute": "Si le liure a devo esse assolùe o nò (visadì relativ)",
+ "semanticmaps-kml-pagelinktext": "Ël test da dovré për le liure a la pàgina, dont $1 a sarà rimpiassà da 'l tìtol ëd la pàgina",
+ "semanticmaps-shapes-improperformat": "Formatà ëd $1 nen bon. Për piasì, ch'a fasa arferiment a la documentassion për ël formà vorsù",
+ "semanticmaps-shapes-missingshape": "Gnun-e forme trovà për $1. Për piasì, ch'a varda la documentassion për le forme disponìbij"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ps.json b/www/wiki/extensions/Maps/i18n/ps.json
new file mode 100644
index 00000000..26b6d102
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ps.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ahmed-Najib-Biabani-Ibrahimkhel"
+ ]
+ },
+ "maps_map": "کښېده",
+ "maps-others": "نور",
+ "maps-layer-property": "ځانتيا",
+ "maps-layer-value": "ارزښت",
+ "maps-layer-errors": "تېروتنې",
+ "maps-abb-north": "سهـ",
+ "maps-abb-east": "خ",
+ "maps-abb-south": "سو",
+ "maps-abb-west": "ل",
+ "maps-osm-par-photos": "انځورونه ښکاره کول",
+ "mapeditor-none-text": "هېڅ",
+ "mapeditor-done-button": "ترسره شو",
+ "mapeditor-remove-button": "غورځول",
+ "mapeditor-link-title-switcher-link-text": "تړنه",
+ "mapeditor-form-field-title": "سرليک",
+ "mapeditor-form-field-text": "متن",
+ "mapeditor-form-field-link": "تړنه",
+ "mapeditor-form-field-group": "ډله",
+ "mapeditor-form-field-image": "انځور"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pt-br.json b/www/wiki/extensions/Maps/i18n/pt-br.json
new file mode 100644
index 00000000..75526cd6
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pt-br.json
@@ -0,0 +1,231 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cainamarques",
+ "Eduardo.mps",
+ "Giro720",
+ "Luckas",
+ "Luckas Blade",
+ "555",
+ "Macofe",
+ "Jaideraf",
+ "Eduardo Addad de Oliveira",
+ "Felipe L. Ewald"
+ ]
+ },
+ "maps-desc": "Permite a incorporação de mapas dinâmicos em páginas wiki, geocodificação de endereços e outras operações geográficas",
+ "right-geocode": "Geocodificar",
+ "action-geocode": "fazer geocodificação nesta wiki",
+ "maps_map": "Mapa",
+ "maps-tracking-category": "Páginas com um mapa composto pela extensão Maps",
+ "maps-loading-map": "Carregando mapa...",
+ "maps-load-failed": "Não foi possível carregar o mapa!",
+ "maps-markers": "Marcadores",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Filtrar marcadores",
+ "maps-others": "outros",
+ "maps-kml-parsing-failed": "Falha na análise sintática de um ou mais ficheiros KML. Normalmente isto sucede devido a uma falha na importação ou devido a XML malformado.",
+ "maps-ns-layer": "Camada",
+ "maps-ns-layer-talk": "Camada Discussão",
+ "maps-layer-property": "Propriedade",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Erros",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definição inválida|Definições inválidas}}",
+ "maps-layerdef-invalid-fatal": "Definição inválida fatal",
+ "maps-layerdef-wrong-namespace": "As definições de camadas só são válidas em páginas do espaço nominal \"$1\"",
+ "maps-layerdef-equal-layer-name": "Os nomes das camadas devem ser únicos dentro da mesma página de camadas. \"$1\" já está a ser utilizado por outra camada.",
+ "maps-layerpage-usage": "Páginas com mapas que usam a camada \"$1\"",
+ "maps-layerpage-nousage": "Esta camada não está a ser usada por nenhuma página de momento.",
+ "maps-error-invalid-layertype": "Não existem camadas do tipo \"$1\". Só {{PLURAL:$3|é suportado o tipo|são suportados os tipos}}: $2",
+ "maps-error-no-layertype": "Você precisa especificar o tipo de camada. {{PLURAL:$2|Só é suportado o tipo|São suportados os tipos}}: $1",
+ "validation-error-invalid-layer": "O parâmetro $1 precisa ser uma camada válida.",
+ "validation-error-invalid-layers": "O parâmetro $1 precisa ser uma ou mais camada(s) válida(s).",
+ "validation-error-no-non-numeric": "O parâmetro \"$1\" tem de ser um texto não numérico.",
+ "validation-error-no-non-numerics": "O parâmetro \"$1\" tem de ser um ou mais textos não numéricos.",
+ "maps-layer-of-type": "Camada de tipo $1",
+ "maps-layer-of-type-and-name": "Camada \"$2\" do tipo \"$1\"",
+ "maps-layer-type-supported-by": "Este tipo de camada só pode ser usado com {{PLURAL:$2|o serviço de cartografia $1|os serviços de cartografia: $1}}.",
+ "maps-coordinates-description": "Hook do analisador sintático para formatar coordenadas, a partir de qualquer um dos formatos suportados para qualquer outro formato suportado.",
+ "maps-displaymap-description": "Apresentar os mapas sem qualquer marcador definido na wiki.",
+ "maps-distance-description": "Converter uma distância numa unidade suportada para a distância equivalente noutra unidade.",
+ "maps-finddestination-description": "Encontrar um destino a partir de um ponto de partida (expresso em qualquer um dos formatos suportados), uma orientação inicial e uma distância.",
+ "maps-geocode-description": "Permite a geocodificação de moradas; por outras palavras, transforma locais legíveis por seres humanos em conjuntos de coordenadas. Há apoio para vários serviços de geocodificação, que não devem ser confundidos com serviços de cartografia.",
+ "maps-geodistance-description": "Calcula a distância geográfica entre dois pontos, a partir e para qualquer um dos formatos suportados.",
+ "maps-mapsdoc-description": "Apresentar uma tabela com os parâmetros de um serviço de cartografia especificado, em conjunto com os respetivos valores por omissão e descrições.",
+ "maps-layerdefinition-description": "Descreve uma camada personalizada que pode ser apresentada com outras funções Mapa.",
+ "maps-mapsdoc-par-service": "O serviço de cartografia para o qual será apresentada a documentação dos parâmetros.",
+ "maps-mapsdoc-par-language": "A língua de apresentação da documentação. Se essa tradução não estiver disponível, será usado o inglês.",
+ "maps-coordinates-par-location": "As coordenadas que quer formatar.",
+ "maps-coordinates-par-format": "O formato em que quer as coordenadas.",
+ "maps-coordinates-par-directional": "Indica se as coordenadas devem ser produzidas com formato direccional ou não.",
+ "maps-par-scrollwheelzoom": "Indica se a rolagem do mouse deve ser ativada ou não.",
+ "maps-distance-par-distance": "A distância para converter para a equivalente numa unidade especificada.",
+ "maps-distance-par-decimals": "O número máximo de casas decimais para usar no resultado.",
+ "maps-distance-par-unit": "A unidade na qual a distância será retornada.",
+ "maps-finddestination-par-location": "A localização inicial.",
+ "maps-finddestination-par-bearing": "A direção inicial.",
+ "maps-finddestination-par-distance": "A distância para percorrer.",
+ "maps-finddestination-par-format": "O formato em que sairá o destino.",
+ "maps-finddestination-par-directional": "Indica se o formato do destino deve ser direcional ou não.",
+ "maps-geocode-par-location": "O endereço que você deseja geocodificar.",
+ "maps-geocode-par-format": "O formato das coordenadas resultantes.",
+ "maps-geocode-par-directional": "Indica se as coordenadas devem ser produzidas com formato direcional ou não.",
+ "maps-geodistance-par-location1": "O primeiro ponto do conjunto para calcular a distância entre dois pontos.",
+ "maps-geodistance-par-location2": "O segundo ponto do conjunto para calcular a distância entre dois pontos.",
+ "maps-geodistance-par-unit": "A unidade na qual a distância será retornada.",
+ "maps-geodistance-par-decimals": "O número máximo de casas decimais para usar no resultado.",
+ "maps-displaymap-par-mappingservice": "Permite definir o serviço de cartografia que será usado para gerar o mapa.",
+ "maps-displaymap-par-coordinates": "A localização na qual o mapa será inicialmente centrado.",
+ "maps-displaymap-par-visitedicon": "O nome de arquivo de uma imagem a ser usada como ícones de marcação depois de os marcadores originais terem sido clicados",
+ "maps-displaymap-par-zoom": "Permite definir o nível de zoom.\nQuando este não for fornecido e existirem vários marcadores no mapa, será usado o zoom que resulte no melhor dimensionamento, não o valor padrão configurado.",
+ "maps-displaymap-par-centre": "Permite definir as coordenadas do centro do mapa para display_point(s).\nAceita tanto endereços como coordenadas.\nQuando esta propriedade não for fornecida, o mapa será centrado no marcador fornecido, ou entre os marcadores fornecidos.",
+ "maps-displaymap-par-title": "Permite a configuração do texto que será apresentado nos pop-ups de todos os marcadores que não têm um título específico.\nQuando usado em conjunto com um rótulo, o título aparecerá a negrito e sublinhado.",
+ "maps-displaymap-par-label": "Permite a configuração do texto que será apresentado nos pop-ups de todos os marcadores que não têm um rótulo específico.",
+ "maps-displaymap-par-icon": "Permite configurar o ícone usado para todos os marcadores.",
+ "maps-displaymap-par-circles": "Círculos para exibir",
+ "maps-displaymap-par-copycoords": "Mostrar uma caixa de diálogo quando clica numa localização da qual as coordenadas da mesma podem ser copiadas",
+ "maps-displaymap-par-lines": "Linhas para mostrar",
+ "maps-displaymap-par-maxzoom": "O nível máximo de zoom",
+ "maps-displaymap-par-minzoom": "O nível mínimo de zoom",
+ "maps-displaymap-par-polygons": "Polígonos para exibir",
+ "maps-displaymap-par-rectangles": "Retângulos para exibir",
+ "maps-displaymap-par-static": "Tornar o mapa estático",
+ "maps-displaymap-par-wmsoverlay": "Usar uma sobreposição WMS",
+ "maps-displaymap-par-geojson": "URL de um arquivo ou nome da página que contém dados GeoJSON",
+ "maps-fullscreen-button": "Ativar ou desativar a tela completa",
+ "maps-fullscreen-button-tooltip": "Ver o mapa em toda tela ou incorporada.",
+ "validation-error-invalid-location": "O parâmetro $1 precisa ser uma localização válida.",
+ "validation-error-invalid-locations": "O parâmetro $1 precisa ser uma ou mais localização(ões) válida(s).",
+ "validation-error-invalid-width": "O parâmetro $1 precisa ser uma largura válida.",
+ "validation-error-invalid-height": "O parâmetro $1 precisa ser uma altura válida.",
+ "validation-error-invalid-distance": "O parâmetro $1 precisa ser uma distância válida.",
+ "validation-error-invalid-distances": "O parâmetro $1 deve ser uma ou mais distância(s) válida(s).",
+ "validation-error-invalid-image": "O parâmetro $1 precisa ser uma imagem válida.",
+ "validation-error-invalid-images": "O parâmetro $1 precisa ser uma ou mais imagem(ns) válida(s).",
+ "validation-error-invalid-goverlay": "O parâmetro $1 precisa ser uma sobreposição válida.",
+ "validation-error-invalid-goverlays": "O parâmetro $1 precisa ser uma ou mais sobreposição(ões) válida(s).",
+ "maps-abb-north": "N",
+ "maps-abb-east": "L",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitude:",
+ "maps-longitude": "Longitude:",
+ "maps-invalid-coordinates": "O valor $1 não foi reconhecido como um conjunto de coordenadas válido.",
+ "maps_coordinates_missing": "Não foram fornecidas coordenadas para o mapa.",
+ "maps_geocoding_failed": "{{PLURAL:$2|O seguinte endereço não pode|Os seguintes endereços não puderam}} ser {{PLURAL:$2|geocodificado|geocodificados}}: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|O seguinte endereço não pode|Os seguintes endereços não puderam}} ser {{PLURAL:$2|geocodificado e foi omitido|geocodificados e foram omitidos}} do mapa:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|A seguinte coordenada não foi reconhecida|As seguintes coordenadas não foram reconhecidas}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|A seguinte coordenada não foi reconhecida e foi omitida|As seguintes coordenadas não foram reconhecidas e foram omitidas}} do mapa:\n$1",
+ "maps_map_cannot_be_displayed": "O mapa não pode ser mostrado.",
+ "maps-geocoder-not-available": "A funcionalidade de georeferenciação do Mapas está indisponível; a sua localização não pode ser georeferenciada.",
+ "maps_leaflet": "Folheto",
+ "maps-leaflet-par-defzoom": "Permite definir o nível de zoom predefinido do mapa.",
+ "maps-leaflet-par-layers": "A camada que será mostrada quando o mapa é carregado.",
+ "maps-leaflet-par-overlaylayers": "As camadas de sobreposição que serão mostradas quando o mapa é carregado.",
+ "maps-leaflet-par-maxclusterradius": "O raio máximo que um agregado irá cobrir a partir do marcador central (em píxeis).",
+ "maps-leaflet-par-clusterspiderfy": "Quando clica um agregado no nível de zoom mais baixo os marcadores são enteados para que possa vê-los todos.",
+ "maps_click_to_activate": "Clique para ativar o mapa",
+ "maps_centred_on": "Mapa centrado nas coordenadas $1, $2.",
+ "maps-par-mappingservice": "Permite definir o serviço de cartografia que será usado para gerar o mapa.",
+ "maps-par-resizable": "Permite alterar as dimensões do mapa, arrastando o canto inferior direito.",
+ "maps-par-searchmarkers": "Permite pesquisar marcadores específicos usando um campo incorporado no mapa.",
+ "maps-par-zoom": "O nível de zoom do mapa. Nos mapas com marcadores será usado o maior zoom que, mesmo assim, mostre todos os marcadores.",
+ "maps-par-width": "Permite definir a largura do mapa. A unidade por omissão é o píxel, mas pode defini-la explicitamente como: px, ex, em, %.",
+ "maps-par-height": "Permite definir a altura do mapa. A unidade por omissão é o píxel, mas pode defini-la explicitamente como: px, ex, em, %.",
+ "maps-par-centre": "A localização na qual o mapa deve estar centrado",
+ "maps-par-enable-fullscreen": "Ativar o botão de tela cheia",
+ "maps-par-kml": "Arquivos KML que serão carregados no mapa.",
+ "maps-par-markercluster": "Permite fundir vários marcadores próximos num único marcador",
+ "maps-googlemaps3-incompatbrowser": "O seu browser não é compatível com o Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Permite adicionar uma imagem a ser mostrada na localização especificada do mapa.",
+ "maps-googlemaps3-par-type": "O tipo de mapa para mostrar inicialmente.",
+ "maps-googlemaps3-par-types": "Os tipos de mapas que estarão disponíveis através do controlo de tipos.",
+ "maps-googlemaps3-par-layers": "As camadas especiais que serão carregadas no mapa.",
+ "maps-googlemaps3-par-controls": "Os controles que serão colocados no mapa.",
+ "maps-googlemaps3-par-zoomstyle": "O estilo do controle de zoom.",
+ "maps-googlemaps3-par-typestyle": "O estilo do controle de tipos.",
+ "maps-googlemaps3-par-autoinfowindows": "Abrir automaticamente todas as janelas informativas depois de carregar a página.",
+ "maps-googlemaps3-par-gkml": "Arquivos KML alojados pelo Google que serão carregados no mapa.",
+ "maps-googlemaps3-par-kmlrezoom": "Voltar a ajustar o zoom do mapa depois de ter carregado as camadas KML.",
+ "maps-googlemaps3-par-poi": "Mostrar pontos de interesse.",
+ "maps-googlemaps3-par-clustergridsize": "A dimensão de grelha de um agregado, em píxeis.",
+ "maps-par-clustermaxzoom": "O nível máximo de zoom onde podem existir agregados.",
+ "maps-par-clusterzoomonclick": "Indica se o comportamento por omissão quando um agregado for clicado, é usar o zoom para aproximá-lo.",
+ "maps-par-maxclusterradius": "O raio máximo que um agregado irá cobrir.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Indica se o centro de cada agregado deve ser o baricentro de todos os marcadores desse agregado.",
+ "maps-googlemaps3-par-clusterminsize": "O número mínimo de marcadores num agregado antes que os marcadores sejam ocultados e seja mostrada uma contagem.",
+ "mapeditor": "Editor de mapas",
+ "specialpages-group-maps": "Mapas",
+ "mapeditor-parser-error": "Ocorreu um erro durante a análise de metadados. A entrada de utilizador será ignorada.",
+ "mapeditor-none-text": "Nenhum",
+ "mapeditor-done-button": "Feito",
+ "mapeditor-remove-button": "Remover",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Exportar para código wiki",
+ "mapeditor-import-button": "Importar de código wiki",
+ "mapeditor-select-button": "Seleciona este polígono",
+ "mapeditor-mapparam-button": "Editar parâmetros do mapa",
+ "mapeditor-clear-button": "Limpar mapa",
+ "mapeditor-code-title": "Código wiki",
+ "mapeditor-import-title": "Importar código wiki",
+ "mapeditor-import-note": "Note, por favor, que o analisador espera um formato muito rigoroso no código wiki. O código inserido aqui deve corresponder ao código gerado pela funcionalidade de exportação.",
+ "mapeditor-form-title": "Editar detalhes",
+ "mapeditor-link-title-switcher-popup-text": "<i>Popup</i> com texto",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Título",
+ "mapeditor-form-field-text": "Texto",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Ícone",
+ "mapeditor-form-field-group": "Grupo",
+ "mapeditor-form-field-inlinelabel": "Etiqueta em linha",
+ "mapeditor-form-field-strokecolor": "Cor de traço",
+ "mapeditor-form-field-strokeopacity": "Opacidade do traço",
+ "mapeditor-form-field-strokeweight": "Espessura do traço",
+ "mapeditor-form-field-fillcolor": "Cor de preenchimento",
+ "mapeditor-form-field-fillopcaity": "Opacidade do preenchimento",
+ "mapeditor-form-field-showonhover": "Mostrar só ao passar o ponteiro do mouse por cima",
+ "mapeditor-mapparam-title": "Editar parâmetros do mapa",
+ "mapeditor-mapparam-defoption": "-Selecionar parâmetro-",
+ "mapeditor-imageoverlay-button": "Adicionar sobreposição de imagem",
+ "mapeditor-form-field-image": "Imagem",
+ "mapeditor-imageoverlay-title": "Detalhes da sobreposição de imagem",
+ "mapeditor-form-field-visitedicon": "Ícone visitado",
+ "semanticmaps-unrecognizeddistance": "O valor $1 não é uma distância válida.",
+ "semanticmaps-kml-link": "Ver o arquivo KML",
+ "semanticmaps-default-kml-pagelink": "Ver a página $1",
+ "semanticmaps-latitude": "Latitude: $1",
+ "semanticmaps-longitude": "Longitude: $1",
+ "semanticmaps-altitude": "Altitude: $1",
+ "semanticmaps-forminput-locations": "Locais",
+ "semanticmaps-par-staticlocations": "Uma lista de localizações para adicionar ao mapa junto aos dados consultados. Assim como nos pontos a serem exibidos (\"display_points\"), você pode adicionar um título, descrição e ícone por localização, usando o til (\"~\") como separador.",
+ "semanticmaps-par-showtitle": "Mostrar, ou não, um título na janela informativa do marcador. É frequentemente desejável desativar este recurso quando estiver usando uma predefinição para formatar o conteúdo da janela informativa.",
+ "semanticmaps-par-hidenamespace": "Mostrar o título do domínio na janela de informações do marcador",
+ "semanticmaps-par-centre": "O centro do mapa. Quando este não for definido, o mapa escolherá automaticamente o centro ideal para apresentar todos os marcadores do mapa.",
+ "semanticmaps-par-template": "Uma predefinição que será usada para formatar o conteúdo da janela informativa.",
+ "semanticmaps-par-geocodecontrol": "Exibir o controle de geocodificação.",
+ "semanticmaps-par-activeicon": "Ícone a ser exibido ao invés do marcador padrão, quando a página ativa é igual ao resultado da consulta",
+ "semanticmaps-par-pagelabel": "Quando configurado para \"yes\", todos os marcadores terão um \"inlineLabel\" com um link para a página que contém as coordenadas para o marcador",
+ "semanticmaps-par-ajaxcoordproperty": "Nome da propriedade das coordenadas que é usada para construir a consulta ajax.",
+ "semanticmaps-par-ajaxquery": "Uma segunda consulta que é enviada via ajax para obter coordenadas adicionais.",
+ "semanticmaps-par-userparam": "Valor fornecido a cada chamada da predefinição, se uma predefinição for utilizada",
+ "semanticmaps-kml-text": "O texto associado a cada página. Será substituído quando propriedades adicionais consultadas existirem.",
+ "semanticmaps-kml-title": "O título padrão para os resultados",
+ "semanticmaps-kml-linkabsolute": "Os links deverão ser absolutos (ao contrário de relativos)",
+ "semanticmaps-kml-pagelinktext": "O texto a ser usado nos links para a página, onde $1 será substituído pelo título da página",
+ "semanticmaps-shapes-improperformat": "Formatação imprópria em $1. Por favor, veja a documentação para formatação",
+ "semanticmaps-shapes-missingshape": "Nenhuma forma foi encontrada para $1. Por favor, veja a documentação para formas disponíveis",
+ "validator-type-mapscircle": "Círculo geográfico",
+ "validator-type-mapscircle-list": "Lista de círculos",
+ "validator-type-mapsimageoverlay": "Sobreposição de imagem",
+ "validator-type-mapsimageoverlay-list": "Lista de sobreposições de imagem",
+ "validator-type-mapsline": "Linha geográfica",
+ "validator-type-mapsline-list": "Lista de linhas",
+ "validator-type-mapslocation": "Localização geográfica",
+ "validator-type-mapslocation-list": "Lista de locais",
+ "validator-type-mapsrectangle": "Retângulo geográfico",
+ "validator-type-mapsrectangle-list": "Lista de retângulos",
+ "validator-type-mapspolygon": "Polígono geográfico",
+ "validator-type-mapspolygon-list": "Lista de polígonos geográficos",
+ "validator-type-wmsoverlay": "Sobreposição Web Map Service",
+ "validator-type-jsonfile": "texto"
+}
diff --git a/www/wiki/extensions/Maps/i18n/pt.json b/www/wiki/extensions/Maps/i18n/pt.json
new file mode 100644
index 00000000..7bf9b166
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/pt.json
@@ -0,0 +1,233 @@
+{
+ "@metadata": {
+ "authors": [
+ "Alchimista",
+ "Giro720",
+ "GoEThe",
+ "Hamilton Abreu",
+ "Lijealso",
+ "Luckas",
+ "Waldir",
+ "Vitorvicentevalente",
+ "Macofe",
+ "Malafaya",
+ "Fúlvio",
+ "Athena in Wonderland"
+ ]
+ },
+ "maps-desc": "Permite incorporar mapas dinâmicos nas páginas da wiki, converter endereços em geocódigos e outras operações geográficas",
+ "right-geocode": "Geocodificar",
+ "action-geocode": "fazer geocodificação nesta wiki",
+ "maps_map": "Mapa",
+ "maps-tracking-category": "Páginas com um mapa composto pela extensão Maps",
+ "maps-loading-map": "A carregar o mapa...",
+ "maps-load-failed": "Não foi possível carregar o mapa!",
+ "maps-markers": "Marcadores",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Filtrar marcadores",
+ "maps-others": "outros",
+ "maps-kml-parsing-failed": "Falha na análise sintática de um ou mais ficheiros KML. Normalmente isto sucede devido a uma falha na importação ou devido a XML malformado.",
+ "maps-ns-layer": "Camada",
+ "maps-ns-layer-talk": "Camada Discussão",
+ "maps-layer-property": "Propriedade",
+ "maps-layer-value": "Valor",
+ "maps-layer-errors": "Erros",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Definição inválida|Definições inválidas}}",
+ "maps-layerdef-invalid-fatal": "Definição inválida fatal",
+ "maps-layerdef-wrong-namespace": "As definições de camadas só são válidas em páginas do espaço nominal \"$1\"",
+ "maps-layerdef-equal-layer-name": "Os nomes das camadas devem ser únicos dentro da mesma página de camadas. \"$1\" já está a ser utilizado por outra camada.",
+ "maps-layerpage-usage": "Páginas com mapas que usam a camada \"$1\"",
+ "maps-layerpage-nousage": "Esta camada não está a ser usada por nenhuma página de momento.",
+ "maps-error-invalid-layertype": "Não existem camadas do tipo \"$1\". Só {{PLURAL:$3|é suportado o tipo|são suportados os tipos}}: $2",
+ "maps-error-no-layertype": "Tem de especificar o tipo da camada. {{PLURAL:$2|Só é suportado este tipo|São suportados os tipos}}: $1",
+ "validation-error-invalid-layer": "O parâmetro \"$1\" tem de ser uma camada válida.",
+ "validation-error-invalid-layers": "O parâmetro \"$1\" tem de ser uma ou mais camadas válidas.",
+ "validation-error-no-non-numeric": "O parâmetro \"$1\" tem de ser um texto não numérico.",
+ "validation-error-no-non-numerics": "O parâmetro \"$1\" tem de ser um ou mais textos não numéricos.",
+ "maps-layer-of-type": "Camada do tipo \"$1\"",
+ "maps-layer-of-type-and-name": "Camada \"$2\" do tipo \"$1\"",
+ "maps-layer-type-supported-by": "Este tipo de camada só pode ser usado com {{PLURAL:$2|o serviço de cartografia $1|os serviços de cartografia: $1}}.",
+ "maps-coordinates-description": "Hook do analisador sintático para formatar coordenadas, a partir de qualquer um dos formatos suportados para qualquer outro formato suportado.",
+ "maps-displaymap-description": "Apresentar os mapas sem qualquer marcador definido na wiki.",
+ "maps-distance-description": "Converter uma distância numa unidade suportada para a distância equivalente noutra unidade.",
+ "maps-finddestination-description": "Encontrar um destino a partir de um ponto de partida (expresso em qualquer um dos formatos suportados), uma orientação inicial e uma distância.",
+ "maps-geocode-description": "Permite a geocodificação de moradas; por outras palavras, transforma locais legíveis por seres humanos em conjuntos de coordenadas. Há apoio para vários serviços de geocodificação, que não devem ser confundidos com serviços de cartografia.",
+ "maps-geodistance-description": "Calcula a distância geográfica entre dois pontos, a partir e para qualquer um dos formatos suportados.",
+ "maps-mapsdoc-description": "Apresentar uma tabela com os parâmetros de um serviço de cartografia especificado, em conjunto com os respetivos valores por omissão e descrições.",
+ "maps-layerdefinition-description": "Descreve uma camada personalizada que pode ser apresentada com outras funções Mapa.",
+ "maps-mapsdoc-par-service": "O serviço de cartografia para o qual será apresentada a documentação dos parâmetros.",
+ "maps-mapsdoc-par-language": "A língua de apresentação da documentação. Se essa tradução não estiver disponível, será usado o inglês.",
+ "maps-coordinates-par-location": "As coordenadas que quer formatar.",
+ "maps-coordinates-par-format": "O formato em que quer as coordenadas.",
+ "maps-coordinates-par-directional": "Indica se as coordenadas devem ser produzidas com formato direccional ou não.",
+ "maps-par-scrollwheelzoom": "Indica se o deslizamento do rato deve ser ativado ou não.",
+ "maps-distance-par-distance": "A distância para converter para a equivalente numa unidade especificada.",
+ "maps-distance-par-decimals": "O número máximo de casas decimais a usar no valor resultante.",
+ "maps-distance-par-unit": "As unidades em que a distância será produzida.",
+ "maps-finddestination-par-location": "A localização inicial.",
+ "maps-finddestination-par-bearing": "A direção inicial.",
+ "maps-finddestination-par-distance": "A distância a percorrer.",
+ "maps-finddestination-par-format": "O formato em que sairá o destino.",
+ "maps-finddestination-par-directional": "Indica se o formato do destino deve ser direccional ou não.",
+ "maps-geocode-par-location": "A morada que quer geocodificar.",
+ "maps-geocode-par-format": "O formato das coordenadas resultantes.",
+ "maps-geocode-par-directional": "Indica se as coordenadas devem ser produzidas com formato direccional ou não.",
+ "maps-geodistance-par-location1": "O primeiro ponto do conjunto para calcular a distância entre dois pontos.",
+ "maps-geodistance-par-location2": "O segundo ponto do conjunto para calcular a distância entre dois pontos.",
+ "maps-geodistance-par-unit": "As unidades em que a distância será produzida.",
+ "maps-geodistance-par-decimals": "O número máximo de casas decimais a usar no valor resultante.",
+ "maps-displaymap-par-mappingservice": "Permite definir o serviço de cartografia que será usado para gerar o mapa.",
+ "maps-displaymap-par-coordinates": "A localização na qual o mapa será inicialmente centrado.",
+ "maps-displaymap-par-visitedicon": "O nome de ficheiro de uma imagem a ser usada como ícones de marcação depois de os marcadores originais terem sido clicados",
+ "maps-displaymap-par-zoom": "Permite definir o nível de zoom.\nQuando este não for fornecido e existirem vários marcadores no mapa, será usado o zoom que resulte no melhor dimensionamento, não o valor padrão configurado.",
+ "maps-displaymap-par-centre": "Permite definir as coordenadas do centro do mapa para display_point(s).\nAceita tanto endereços como coordenadas.\nQuando esta propriedade não for fornecida, o mapa será centrado no marcador fornecido, ou entre os marcadores fornecidos.",
+ "maps-displaymap-par-title": "Permite a configuração do texto que será apresentado nos pop-ups de todos os marcadores que não têm um título específico.\nQuando usado em conjunto com um rótulo, o título aparecerá a negrito e sublinhado.",
+ "maps-displaymap-par-label": "Permite a configuração do texto que será apresentado nos pop-ups de todos os marcadores que não têm um rótulo específico.",
+ "maps-displaymap-par-icon": "Permite configurar o ícone usado para todos os marcadores.",
+ "maps-displaymap-par-circles": "Círculos a serem apresentados",
+ "maps-displaymap-par-copycoords": "Mostrar uma caixa de diálogo quando clica numa localização da qual as coordenadas da mesma podem ser copiadas",
+ "maps-displaymap-par-lines": "Linhas a serem apresentadas",
+ "maps-displaymap-par-maxzoom": "O nível máximo de zoom",
+ "maps-displaymap-par-minzoom": "O nível mínimo de zoom",
+ "maps-displaymap-par-polygons": "Polígonos a serem apresentados",
+ "maps-displaymap-par-rectangles": "Retângulos a serem apresentados",
+ "maps-displaymap-par-static": "Tornar o mapa estático",
+ "maps-displaymap-par-wmsoverlay": "Usar uma sobreposição WMS",
+ "maps-displaymap-par-geojson": "URL de um ficheiro, ou nome da página, que contém dados GeoJSON",
+ "maps-fullscreen-button": "Ativar ou desativar ecrã completo",
+ "maps-fullscreen-button-tooltip": "Ver o mapa em todo o ecrã ou incorporado.",
+ "validation-error-invalid-location": "O parâmetro \"$1\" tem de ser uma localização válida.",
+ "validation-error-invalid-locations": "O parâmetro \"$1\" tem de ser uma ou mais localizações válidas.",
+ "validation-error-invalid-width": "O parâmetro \"$1\" tem de ser uma largura válida.",
+ "validation-error-invalid-height": "O parâmetro \"$1\" tem de ser uma altura válida.",
+ "validation-error-invalid-distance": "O parâmetro \"$1\" tem de ser uma distância válida.",
+ "validation-error-invalid-distances": "O parâmetro \"$1\" tem de ser uma ou mais distâncias válidas.",
+ "validation-error-invalid-image": "O parâmetro \"$1\" tem de ser uma imagem válida.",
+ "validation-error-invalid-images": "O parâmetro \"$1\" tem de ser uma ou mais imagens válidas.",
+ "validation-error-invalid-goverlay": "O parâmetro \"$1\" tem de ser uma sobreposição válida.",
+ "validation-error-invalid-goverlays": "O parâmetro \"$1\" tem de ser uma ou mais sobreposições válidas.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitude:",
+ "maps-longitude": "Longitude:",
+ "maps-invalid-coordinates": "O valor $1 não foi reconhecido como um conjunto de coordenadas válido.",
+ "maps_coordinates_missing": "Não foram fornecidas coordenadas para o mapa.",
+ "maps_geocoding_failed": "Não foi possível geocodificar {{PLURAL:$2|o seguinte endereço|os seguintes endereços}}: $1.",
+ "maps_geocoding_failed_for": "Não foi possível geocodificar {{PLURAL:$2|o seguinte endereço, que foi omitido|os seguintes endereços, que foram omitidos}} do mapa:\n$1.",
+ "maps_unrecognized_coords": "{{PLURAL:$2|A seguinte coordenada não foi reconhecida|As seguintes coordenadas não foram reconhecidas}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|A seguinte coordenada não foi reconhecida e foi omitida|As seguintes coordenadas não foram reconhecidas e foram omitidas}} do mapa:\n$1",
+ "maps_map_cannot_be_displayed": "Não é possível apresentar o mapa.",
+ "maps-geocoder-not-available": "A funcionalidade de geocodificação do Mapas está indisponível; a sua localização não pode ser geocodificada.",
+ "maps_leaflet": "Folheto",
+ "maps-leaflet-par-defzoom": "Permite definir o nível de zoom predefinido do mapa.",
+ "maps-leaflet-par-layers": "A camada que será mostrada quando o mapa é carregado.",
+ "maps-leaflet-par-overlaylayers": "As camadas de sobreposição que serão mostradas quando o mapa é carregado.",
+ "maps-leaflet-par-maxclusterradius": "O raio máximo que um agregado irá cobrir a partir do marcador central (em píxeis).",
+ "maps-leaflet-par-clusterspiderfy": "Quando clica um agregado no nível de zoom mais baixo os marcadores são enteados para que possa vê-los todos.",
+ "maps_click_to_activate": "Clique para ativar o mapa",
+ "maps_centred_on": "Mapa centrado nas coordenadas $1, $2.",
+ "maps-par-mappingservice": "Permite definir o serviço de cartografia que será usado para gerar o mapa.",
+ "maps-par-resizable": "Permite alterar as dimensões do mapa, arrastando o canto inferior direito.",
+ "maps-par-searchmarkers": "Permite pesquisar marcadores específicos usando um campo incorporado no mapa.",
+ "maps-par-zoom": "O nível de zoom do mapa. Nos mapas com marcadores será usado o maior zoom que, mesmo assim, mostre todos os marcadores.",
+ "maps-par-width": "Permite definir a largura do mapa. A unidade por omissão é o píxel, mas pode defini-la explicitamente como: px, ex, em, %.",
+ "maps-par-height": "Permite definir a altura do mapa. A unidade por omissão é o píxel, mas pode defini-la explicitamente como: px, ex, em, %.",
+ "maps-par-centre": "A localização na qual o mapa deve estar centrado",
+ "maps-par-enable-fullscreen": "Ativar o botão de ecrã completo",
+ "maps-par-kml": "Ficheiros KML que serão carregados no mapa.",
+ "maps-par-markercluster": "Permite fundir vários marcadores próximos num único marcador",
+ "maps-googlemaps3-incompatbrowser": "O seu browser não é compatível com o Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Permite adicionar uma imagem a ser mostrada na localização especificada do mapa.",
+ "maps-googlemaps3-par-type": "O tipo de mapa que será apresentado inicialmente.",
+ "maps-googlemaps3-par-types": "Os tipos de mapas que estarão disponíveis através do controlo de tipos.",
+ "maps-googlemaps3-par-layers": "As camadas especiais que serão carregadas no mapa.",
+ "maps-googlemaps3-par-controls": "Os controlos que serão colocados no mapa.",
+ "maps-googlemaps3-par-zoomstyle": "O estilo do controlo de zoom.",
+ "maps-googlemaps3-par-typestyle": "O estilo do controlo de tipos.",
+ "maps-googlemaps3-par-autoinfowindows": "Abrir automaticamente todas as janelas informativas depois de carregar a página.",
+ "maps-googlemaps3-par-gkml": "Ficheiros KML alojados pelo Google que serão carregados no mapa.",
+ "maps-googlemaps3-par-kmlrezoom": "Voltar a ajustar o zoom do mapa depois de ter carregado as camadas KML.",
+ "maps-googlemaps3-par-poi": "Mostrar pontos de interesse.",
+ "maps-googlemaps3-par-clustergridsize": "A dimensão de grelha de um agregado, em píxeis.",
+ "maps-par-clustermaxzoom": "O nível máximo de zoom onde podem existir agregados.",
+ "maps-par-clusterzoomonclick": "Indica se o comportamento por omissão quando um agregado for clicado, é usar o zoom para aproximá-lo.",
+ "maps-par-maxclusterradius": "O raio máximo que um agregado irá cobrir.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Indica se o centro de cada agregado deve ser o baricentro de todos os marcadores desse agregado.",
+ "maps-googlemaps3-par-clusterminsize": "O número mínimo de marcadores num agregado antes que os marcadores sejam ocultados e seja mostrada uma contagem.",
+ "mapeditor": "Editor de mapas",
+ "specialpages-group-maps": "Mapas",
+ "mapeditor-parser-error": "Ocorreu um erro durante a análise de metadados. A entrada de utilizador será ignorada.",
+ "mapeditor-none-text": "Nenhum",
+ "mapeditor-done-button": "Concluído",
+ "mapeditor-remove-button": "Remover",
+ "mapeditor-import-button2": "Importar",
+ "mapeditor-export-button": "Exportar para código wiki",
+ "mapeditor-import-button": "Importar de código wiki",
+ "mapeditor-select-button": "Selecionar este polígono",
+ "mapeditor-mapparam-button": "Editar parâmetros do mapa",
+ "mapeditor-clear-button": "Limpar mapa",
+ "mapeditor-code-title": "Código wiki",
+ "mapeditor-import-title": "Importar código wiki",
+ "mapeditor-import-note": "Note, por favor, que o analisador espera um formato muito rigoroso no código wiki. O código inserido aqui deve corresponder ao código gerado pela funcionalidade de exportação.",
+ "mapeditor-form-title": "Editar detalhes",
+ "mapeditor-link-title-switcher-popup-text": "<i>Popup</i> com texto",
+ "mapeditor-link-title-switcher-link-text": "Hiperligação",
+ "mapeditor-form-field-title": "Título",
+ "mapeditor-form-field-text": "Texto",
+ "mapeditor-form-field-link": "Hiperligação",
+ "mapeditor-form-field-icon": "Ícone",
+ "mapeditor-form-field-group": "Grupo",
+ "mapeditor-form-field-inlinelabel": "Etiqueta em linha",
+ "mapeditor-form-field-strokecolor": "Cor de traço",
+ "mapeditor-form-field-strokeopacity": "Opacidade do traço",
+ "mapeditor-form-field-strokeweight": "Espessura do traço",
+ "mapeditor-form-field-fillcolor": "Cor de preenchimento",
+ "mapeditor-form-field-fillopcaity": "Opacidade do preenchimento",
+ "mapeditor-form-field-showonhover": "Mostrar só ao passar o ponteiro do rato por cima",
+ "mapeditor-mapparam-title": "Editar parâmetros do mapa",
+ "mapeditor-mapparam-defoption": "-Selecione o parâmetro-",
+ "mapeditor-imageoverlay-button": "Adicionar sobreposição de imagem",
+ "mapeditor-form-field-image": "Imagem",
+ "mapeditor-imageoverlay-title": "Detalhes da sobreposição de imagem",
+ "mapeditor-form-field-visitedicon": "Ícone visitado",
+ "semanticmaps-unrecognizeddistance": "O valor $1 não é uma distância válida.",
+ "semanticmaps-kml-link": "Ver o ficheiro KML",
+ "semanticmaps-default-kml-pagelink": "Ver a página $1",
+ "semanticmaps-latitude": "Latitude: $1",
+ "semanticmaps-longitude": "Longitude: $1",
+ "semanticmaps-altitude": "Altitude: $1",
+ "semanticmaps-forminput-locations": "Locais",
+ "semanticmaps-par-staticlocations": "Uma lista de locais para acrescentar ao mapa em conjunto com os dados consultados. Tal como nos pontos a apresentar (\"display_points\"), pode adicionar um título, descrição e ícone por local, usando o til \"~\" como separador.",
+ "semanticmaps-par-showtitle": "Mostrar, ou não, um título na janela informativa do marcador. É frequentemente desejável desativar esta funcionalidade quando usar uma predefinição para formatar o conteúdo da janela informativa.",
+ "semanticmaps-par-hidenamespace": "Mostrar o título do espaço nominal na janela informativa do marcador",
+ "semanticmaps-par-centre": "O centro do mapa. Quando este não for fornecido, o mapa escolherá automaticamente o centro ótimo para apresentar todos os marcadores do mapa.",
+ "semanticmaps-par-template": "Uma predefinição que será usada para formatar o conteúdo da janela informativa.",
+ "semanticmaps-par-geocodecontrol": "Mostrar o controlo de geocodificação.",
+ "semanticmaps-par-activeicon": "Ícone para ser apresentado em vez do marcador padrão, quando a página ativa é igual ao resultado da consulta",
+ "semanticmaps-par-pagelabel": "Quando definido como \"yes\", todos os marcadores terão um rótulo em linha (\"inlineLabel\") com uma hiperligação para a página que contém as coordenadas do marcador",
+ "semanticmaps-par-ajaxcoordproperty": "Nome da propriedade das coordenadas que é usada para construir a consulta ajax.",
+ "semanticmaps-par-ajaxquery": "Uma segunda consulta que é enviada via ajax para obter coordenadas adicionais.",
+ "semanticmaps-par-userparam": "Um valor passado a cada chamada da predefinição, se for usada uma predefinição",
+ "semanticmaps-kml-text": "O texto associado a cada página. Substituído pelas propriedades adicionais consultadas, se existirem.",
+ "semanticmaps-kml-title": "O título padrão para os resultados",
+ "semanticmaps-kml-linkabsolute": "Indica se as hiperligações devem ser absolutas (em vez de relativas)",
+ "semanticmaps-kml-pagelinktext": "O texto a utilizar nas hiperligações para a página, onde $1 será substituído pelo título da página",
+ "semanticmaps-shapes-improperformat": "Formato indevido de $1. Consulte a documentação sobre formatação, por favor",
+ "semanticmaps-shapes-missingshape": "Não foram encontradas nenhumas formas para $1. Consulte a documentação sobre as formas disponíveis, por favor",
+ "validator-type-mapscircle": "Círculo geográfico",
+ "validator-type-mapscircle-list": "Lista de círculos",
+ "validator-type-mapsimageoverlay": "Sobreposição de imagem",
+ "validator-type-mapsimageoverlay-list": "Lista de sobreposições de imagem",
+ "validator-type-mapsline": "Linha geográfica",
+ "validator-type-mapsline-list": "Lista de linhas",
+ "validator-type-mapslocation": "Localização geográfica",
+ "validator-type-mapslocation-list": "Lista de locais",
+ "validator-type-mapsrectangle": "Retângulo geográfico",
+ "validator-type-mapsrectangle-list": "Lista de retângulos",
+ "validator-type-mapspolygon": "Polígono geográfico",
+ "validator-type-mapspolygon-list": "Lista de polígonos geográficos",
+ "validator-type-wmsoverlay": "Sobreposição Web Map Service",
+ "validator-type-jsonfile": "texto"
+}
diff --git a/www/wiki/extensions/Maps/i18n/qqq.json b/www/wiki/extensions/Maps/i18n/qqq.json
new file mode 100644
index 00000000..89298677
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/qqq.json
@@ -0,0 +1,235 @@
+{
+ "@metadata": {
+ "authors": [
+ "EugeneZelenko",
+ "Fryed-peach",
+ "Kghbln",
+ "Purodha",
+ "Raymond",
+ "Shirayuki",
+ "Siebrand",
+ "Umherirrender",
+ "Тест",
+ "아라",
+ "Liuxinyu970226",
+ "Nike",
+ "Lloffiwr",
+ "Robby"
+ ]
+ },
+ "maps-desc": "{{desc|name=Maps|url=https://www.semantic-mediawiki.org/wiki/Extension:Maps}}",
+ "right-geocode": "{{doc-right|geocode}}",
+ "action-geocode": "{{doc-action|geocode}}",
+ "maps_map": "{{Identical|Map}}",
+ "maps-tracking-category": "The name of a category for all pages which use the <code><nowiki>#display_map</nowiki></code> parser function or <code><nowiki>display_map</nowiki></code> tag.",
+ "maps-loading-map": "This is an informatory message.",
+ "maps-load-failed": "This is an error message.",
+ "maps-markers": "{{Identical|Marker}}",
+ "maps-copycoords-prompt": "This is the text displayed in JavaScript prompt to indicate first press ctrl+c to copy text, and press enter to close prompt.",
+ "maps-searchmarkers-text": "{{doc-important|Translate \"Filter\" as being a word.}}\nThis message is located within an input box to assist users with the input. This functionality allows to filter the markers based on the input one provides. See the [https://www.semantic-mediawiki.org/wiki/Maps_examples/OpenLayers_searchmarkers live example].",
+ "maps-others": "{{Identical|Other}}",
+ "maps-kml-parsing-failed": "This is an error message.",
+ "maps-ns-layer": "This is the name of the \"Layer\" namespace. The term \"Layer\" should be identical to the one used for the corresponding namespace. See {{msg-mw|Maps-ns-layer-talk}}\n\n{{Identical|Layer}}",
+ "maps-ns-layer-talk": "This is the name of the talk page for the \"Layer\" namespace. The term \"Layer\" should be identical to the one used for the corresponding namespace. See {{msg-mw|Maps-ns-layer}}\n\n{{Identical|Layer}}",
+ "maps-layer-property": "{{Identical|Property}}",
+ "maps-layer-value": "{{Identical|Value}}",
+ "maps-layer-errors": "{{Identical|Error}}",
+ "maps-layerdef-invalid": "This is an error message.\n\nParameter:\n* $1 - number of definitions",
+ "maps-layerdef-invalid-fatal": "This is an error message.",
+ "maps-layerdef-wrong-namespace": "This is an error message.\n\nParameter:\n* $1 - namespace name",
+ "maps-layerdef-equal-layer-name": "This is an error message.\n\nParameter:\n* $1 - layer name",
+ "maps-layerpage-usage": "This is an informatory message.\n\nParameter:\n* $1 - layer name",
+ "maps-layerpage-nousage": "This is an informatory message.",
+ "maps-error-invalid-layertype": "This is an error message.\n\nParameters:\n* $1 - a layer type\n* $2 - list of available layer types\n* $3 - number of available layer types",
+ "maps-error-no-layertype": "This is an error message.\n\nParameters:\n* $1 - list of available layer types\n* $2 - number of available layer types",
+ "validation-error-invalid-layer": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-layers": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-no-non-numeric": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-no-non-numerics": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "maps-layer-of-type": "This is used as an <code><nowiki><h3></nowiki></code> heading.\n\nParameter:\n* $1 - layer type",
+ "maps-layer-of-type-and-name": "This is used as an <code><nowiki><h3></nowiki></code> heading.\n\nParameters:\n* $1 - layer type\n* $2 - layer name",
+ "maps-layer-type-supported-by": "This is an informatory and/or error message.\n\nParameters:\n* $1 - list of supported services (geonames and/or google).\n* $2 - number of supported services\n\n{{doc-important|Do not localise the supported services shown in parameter $1!}}",
+ "maps-coordinates-description": "This message describes the <code><nowiki>#coordinates</nowiki></code> parser function as well as the <code><nowiki>coordinates</nowiki></code> tag.",
+ "maps-displaymap-description": "This message describes the <code><nowiki>#display_map</nowiki></code> parser function as well as the <code><nowiki>display_map</nowiki></code> tag.",
+ "maps-distance-description": "This message describes the <code><nowiki>#distance</nowiki></code> parser function as well as the <code><nowiki>distance</nowiki></code> tag.",
+ "maps-finddestination-description": "This message describes the <code><nowiki>#finddestination</nowiki></code> parser function as well as the <code><nowiki>finddestination</nowiki></code> tag.",
+ "maps-geocode-description": "This message describes the <code><nowiki>#geocode</nowiki></code> parser function as well as the <code><nowiki>geocode</nowiki></code> tag.",
+ "maps-geodistance-description": "This message describes the <code><nowiki>#geodistance</nowiki></code> parser function as well as the <code><nowiki>geodistance</nowiki></code> tag.",
+ "maps-mapsdoc-description": "This message describes the <code><nowiki>#mapsdoc</nowiki></code> parser function as well as the <code><nowiki>mapsdoc</nowiki></code> tag.",
+ "maps-layerdefinition-description": "This message describes the <code><nowiki>#layerdifinition</nowiki></code> parser function as well as the <code><nowiki>layerdefinition</nowiki></code> tag.",
+ "maps-mapsdoc-par-service": "{{maps-par|mapsdoc|service}}",
+ "maps-mapsdoc-par-language": "{{maps-par|mapsdoc|language}}",
+ "maps-coordinates-par-location": "{{maps-par|coordinates|location}}",
+ "maps-coordinates-par-format": "{{maps-par|coordinates|format}}",
+ "maps-coordinates-par-directional": "{{maps-par|coordinates|directional}}",
+ "maps-par-scrollwheelzoom": "{{maps-par|coordinates|scrollwheelzoom}}",
+ "maps-distance-par-distance": "{{maps-par|distance|distance}}",
+ "maps-distance-par-decimals": "{{maps-par|distance|decimals}}",
+ "maps-distance-par-unit": "{{maps-par|distance|unit}}",
+ "maps-finddestination-par-location": "{{maps-par|finddestination|location}}",
+ "maps-finddestination-par-bearing": "{{maps-par|finddestination|bearing}}",
+ "maps-finddestination-par-distance": "{{maps-par|finddestination|distance}}",
+ "maps-finddestination-par-format": "{{maps-par|finddestination|format}}",
+ "maps-finddestination-par-directional": "{{maps-par|finddestination|directional}}",
+ "maps-geocode-par-location": "{{maps-par|geocode|location}}",
+ "maps-geocode-par-format": "{{maps-par|geocode|format}}",
+ "maps-geocode-par-directional": "{{maps-par|geocode|directional}}",
+ "maps-geodistance-par-location1": "{{Maps-par|geodistance|location1}}",
+ "maps-geodistance-par-location2": "{{Maps-par|geodistance|location2}}",
+ "maps-geodistance-par-unit": "{{Maps-par|geodistance|unit}}",
+ "maps-geodistance-par-decimals": "{{Maps-par|geodistance|decimals}}",
+ "maps-displaymap-par-mappingservice": "{{Maps-par|displaymap|mappingservice}}",
+ "maps-displaymap-par-coordinates": "{{Maps-par|displaymap|coordinates}}",
+ "maps-displaymap-par-visitedicon": "{{Maps-par|displaymap|visitedicon}}",
+ "maps-displaymap-par-zoom": "{{Maps-par|displaymap|zoom}}",
+ "maps-displaymap-par-centre": "{{Maps-par|displaymap|centre}}",
+ "maps-displaymap-par-title": "{{Maps-par|displaymap|title}}",
+ "maps-displaymap-par-label": "{{Maps-par|displaymap|label}}",
+ "maps-displaymap-par-icon": "{{Maps-par|displaymap|icon}}",
+ "maps-displaymap-par-circles": "{{Maps-par|displaymap|circles}}",
+ "maps-displaymap-par-copycoords": "{{Maps-par|displaymap|copycoords}}",
+ "maps-displaymap-par-lines": "{{Maps-par|displaymap|lines}}",
+ "maps-displaymap-par-maxzoom": "{{Maps-par|displaymap|maxzoom}}",
+ "maps-displaymap-par-minzoom": "{{Maps-par|displaymap|minzoom}}",
+ "maps-displaymap-par-polygons": "{{Maps-par|displaymap|polygons}}",
+ "maps-displaymap-par-rectangles": "{{Maps-par|displaymap|rectangles}}",
+ "maps-displaymap-par-static": "{{Maps-par|displaymap|static}}",
+ "maps-displaymap-par-wmsoverlay": "{{Maps-par|displaymap|wmsoverlay}}\n\nWMS stands for [[wikipedia:en:Web_Map_Service|Web Map Service]].",
+ "maps-displaymap-par-geojson": "{{Maps-par|displaymap|geojson}}",
+ "maps-fullscreen-button": "This is the text of a switch.\n\nSee also:\n* {{msg-mw|Maps-fullscreen-button-tooltip}}.",
+ "maps-fullscreen-button-tooltip": "This is the text of a tooltip popup.\n\nSee also:\n* {{msg-mw|Maps-fullscreen-button}}.",
+ "validation-error-invalid-location": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-locations": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-width": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-height": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-distance": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-distances": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-image": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-images": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-goverlay": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "validation-error-invalid-goverlays": "This is an error message.\n\nParameter:\n* $1 - parameter name\n\n{{Related|Maps-validation}}",
+ "maps-abb-north": "Symbol for representing \"north\" in geolocation coordinates.",
+ "maps-abb-east": "Symbol for representing \"east\" in geolocation coordinates.",
+ "maps-abb-south": "Symbol for representing \"south\" in geolocation coordinates.",
+ "maps-abb-west": "Symbol for representing \"west\" in geolocation coordinates.",
+ "maps-latitude": "This is a field label.\n\n{{Identical|Latitude}}",
+ "maps-longitude": "This is a field label.\n\n{{Identical|Longitude}}",
+ "maps-invalid-coordinates": "This is an error message.\n\nParameter:\n* $1 - value",
+ "maps_coordinates_missing": "This is an error message.",
+ "maps_geocoding_failed": "This is an error message.\n\nParameters:\n* $1 - list of addresses\n* $2 - number of addresses",
+ "maps_geocoding_failed_for": "This is an error message.\n\nParameters:\n* $1 - list of items\n* $2 - number of items, for PLURAL support",
+ "maps_unrecognized_coords": "This is an error message.\n\nParameters:\n* $1 - list of coordinates\n* $2 - number of coordinates\n\nSee also:\n* {{msg-mw|Maps unrecognized coords for}}",
+ "maps_unrecognized_coords_for": "This is an error message.\n\nParameters:\n* $1 - list of coordinates\n* $2 - number of coordinates\n\nSee also:\n* {{msg-mw|Maps unrecognized coords}}",
+ "maps_map_cannot_be_displayed": "This is an error message.",
+ "maps-geocoder-not-available": "This is an informatory and/or error message.",
+ "maps_googlemaps3": "Lable for a result format on SMW's special page \"Ask\".\n\n{{optional}}",
+ "maps_leaflet": "This is a field label.\n\n{{optional}}",
+ "maps-leaflet-par-defzoom": "{{maps-par|leaflet|defzoom}}",
+ "maps-leaflet-par-layers": "{{maps-par|leaflet|layers}}",
+ "maps-leaflet-par-overlaylayers": "{{maps-par|leaflet|overlaylayers}}",
+ "maps-leaflet-par-maxclusterradius": "{{maps-par|leaflet|maxclusterradius}}",
+ "maps-leaflet-par-clusterspiderfy": "{{maps-par|leaflet|clusterspiderfy}}",
+ "maps_click_to_activate": "This is an informatory message.",
+ "maps_centred_on": "This is an informatory message.\n\nParameters:\n* $1 - latitude\n* $2 - longitude",
+ "maps-par-mappingservice": "{{maps-par-all|mappingservice}}",
+ "maps-par-resizable": "System message used by several maps services:\n\n{{maps-par|googlemaps3|resizable}}\n{{maps-par|leaflet|resizable}}",
+ "maps-par-searchmarkers": "System message used by serveral maps services:\n\n{{maps-par|googlemaps3|searchmarkers}}\n{{maps-par|leaflet|searchmarkers}}",
+ "maps-par-zoom": "System message used by serveral maps services:\n\n{{maps-par|googlemaps3|zoom}}\n{{maps-par|leaflet|zoom}}",
+ "maps-par-width": "{{maps-par-all|width}}",
+ "maps-par-height": "{{maps-par-all|height}}",
+ "maps-par-centre": "{{maps-par-all|centre}}",
+ "maps-par-enable-fullscreen": "{{maps-par-all|enablefullscreen}}",
+ "maps-par-kml": "System message used by several maps services:\n\n{{maps-par|googlemaps3|kml}}",
+ "maps-par-markercluster": "{{maps-par-all|markercluster}}",
+ "maps-googlemaps3-incompatbrowser": "This is an error message shown to the user instead of a map.",
+ "maps-googlemaps3-par-imageoverlays": "{{maps-par|googlemaps3|imageoverlays}}",
+ "maps-googlemaps3-par-type": "{{maps-par|googlemaps3|type}}",
+ "maps-googlemaps3-par-types": "{{maps-par|googlemaps3|types}}",
+ "maps-googlemaps3-par-layers": "{{maps-par|googlemaps3|layers}}",
+ "maps-googlemaps3-par-controls": "{{maps-par|googlemaps3|controls}}",
+ "maps-googlemaps3-par-zoomstyle": "{{maps-par|googlemaps3|zoomstyle}}",
+ "maps-googlemaps3-par-typestyle": "{{maps-par|googlemaps3|typestyle}}",
+ "maps-googlemaps3-par-autoinfowindows": "{{maps-par|googlemaps3|autoinfowindows}}",
+ "maps-googlemaps3-par-gkml": "{{maps-par|googlemaps3|gkml}}",
+ "maps-googlemaps3-par-kmlrezoom": "{{maps-par|googlemaps3|kmlrezoom}}\n\nKML stands for [[w:Keyhole Markup Language|Keyhole Markup Language]].",
+ "maps-googlemaps3-par-poi": "{{maps-par|googlemaps3|poi}}",
+ "maps-googlemaps3-par-clustergridsize": "{{maps-par|googlemaps3|clustergridsize}}",
+ "maps-par-clustermaxzoom": "{{maps-par|googlemaps3|clustermaxzoom}}",
+ "maps-par-clusterzoomonclick": "{{maps-par|googlemaps3|clusterzoomonclick}}",
+ "maps-par-maxclusterradius": "{{maps-par|googlemaps3|clustermaxradius}}",
+ "maps-googlemaps3-par-clusteraveragecenter": "{{maps-par|googlemaps3|clusteraveragecenter}}",
+ "maps-googlemaps3-par-clusterminsize": "{{maps-par|googlemaps3|clusterminsize}}",
+ "mapeditor": "{{doc-special-group|like=[[Special:MapEditor]]}}",
+ "specialpages-group-maps": "{{doc-special-group|like=[[Special:MapEditor]]}}\n\n{{Identical|Map}}",
+ "mapeditor-parser-error": "This is an error message.",
+ "mapeditor-none-text": "This is an informatory message.\n\n{{Identical|None}}",
+ "mapeditor-done-button": "This is the text on a button.",
+ "mapeditor-remove-button": "This is the text on a button.",
+ "mapeditor-import-button2": "This is the text on a button.\n\n{{Identical|Import}}",
+ "mapeditor-export-button": "This is the text on a button.",
+ "mapeditor-import-button": "This is the text on a button.",
+ "mapeditor-select-button": "This is the text on a button.",
+ "mapeditor-mapparam-button": "This is the text on a button.",
+ "mapeditor-clear-button": "This is the text on a button.",
+ "mapeditor-code-title": "This is the title of a dialogue.",
+ "mapeditor-import-title": "This is the title of a dialogue.",
+ "mapeditor-import-note": "This is an informatory message.",
+ "mapeditor-form-title": "This is the title of a dialogue.",
+ "mapeditor-link-title-switcher-popup-text": "This is the text of a switch with a popup.",
+ "mapeditor-link-title-switcher-link-text": "This is the text for a switch with a link.\n\n{{Identical|Link}}",
+ "mapeditor-form-field-title": "This is and form field name.\n\n{{Identical|Title}}",
+ "mapeditor-form-field-text": "This is and form field name.\n\n{{Identical|Text}}",
+ "mapeditor-form-field-link": "This is and form field name.\n\n{{Identical|Link}}",
+ "mapeditor-form-field-icon": "This is and form field name.\n\n{{Identical|Icon}}",
+ "mapeditor-form-field-group": "This is and form field name.\n\n{{Identical|Group}}",
+ "mapeditor-form-field-inlinelabel": "This is and form field name.",
+ "mapeditor-form-field-strokecolor": "This is and form field name.",
+ "mapeditor-form-field-strokeopacity": "This is and form field name.",
+ "mapeditor-form-field-strokeweight": "This is and form field name.",
+ "mapeditor-form-field-fillcolor": "This is and form field name.\n\n{{Identical|Fill color}}",
+ "mapeditor-form-field-fillopcaity": "This is and form field name.",
+ "mapeditor-form-field-showonhover": "This is the text for a checkbox.",
+ "mapeditor-mapparam-title": "This is the title of a dialogue.",
+ "mapeditor-mapparam-defoption": "This is the default option in a select list.\n\n{{Identical|Select parameter}}",
+ "mapeditor-imageoverlay-button": "This is the text on a button.",
+ "mapeditor-form-field-image": "This is and form field name.\n\n{{Identical|Image}}",
+ "mapeditor-imageoverlay-title": "This is the title of a dialogue.",
+ "mapeditor-form-field-visitedicon": "This is and form field name.",
+ "semanticmaps-unrecognizeddistance": "This is an error message.\n\nParameter:\n* $1 - distance",
+ "semanticmaps-kml-link": "This is the label of a link.",
+ "semanticmaps-kml": "{{optional}}",
+ "semanticmaps-default-kml-pagelink": "Used as default value for \"pagelinktext\" input box.\nSee example: [{{canonicalurl:Special:Ask|format=kml}} Special:Ask]\n\n<code>$1</code> is not a parameter (appears as is), but it will be replaced by the page title.\n\nSee also:\n* {{msg-mw|Semanticmaps-kml-pagelinktext}}\n{{Identical|View page}}",
+ "semanticmaps-latitude": "Parameters:\n* $1 - latitude\nSee also:\n* {{msg-mw|Semanticmaps-longitude}}\n* {{msg-mw|Semanticmaps-altitude}}\n{{Identical|Latitude}}",
+ "semanticmaps-longitude": "Parameters:\n* $1 - longitude\nSee also:\n* {{msg-mw|Semanticmaps-latitude}}\n* {{msg-mw|Semanticmaps-altitude}}\n{{Identical|Longitude}}",
+ "semanticmaps-altitude": "Parameters:\n* $1 - altitude\nSee also:\n* {{msg-mw|Semanticmaps-latitude}}\n* {{msg-mw|Semanticmaps-longitude}}",
+ "semanticmaps-forminput-locations": "This is a button label.\n\n{{Identical|Location}}",
+ "semanticmaps-par-staticlocations": "{{doc-paramdesc|staticlocations}}",
+ "semanticmaps-par-showtitle": "{{doc-paramdesc|showtitle}}",
+ "semanticmaps-par-hidenamespace": "{{doc-paramdesc|hidenamespace}}",
+ "semanticmaps-par-centre": "{{doc-paramdesc|centre}}",
+ "semanticmaps-par-template": "{{doc-paramdesc|template}}",
+ "semanticmaps-par-geocodecontrol": "{{doc-paramdesc|geocodecontrol}}",
+ "semanticmaps-par-activeicon": "{{doc-paramdesc|activeicon}}",
+ "semanticmaps-par-pagelabel": "{{doc-paramdesc|pagelabel}}\n\n{{doc-important|Do not translate the parameter value \"yes\".}}",
+ "semanticmaps-par-ajaxcoordproperty": "{{doc-paramdesc|ajaxcoordproperty}}",
+ "semanticmaps-par-ajaxquery": "{{doc-paramdesc|ajaxquery}}",
+ "semanticmaps-par-userparam": "{{doc-paramdesc|userparam}}",
+ "semanticmaps-kml-text": "{{doc-paramdesc|text}}",
+ "semanticmaps-kml-title": "{{doc-paramdesc|title}}",
+ "semanticmaps-kml-linkabsolute": "{{doc-paramdesc|absolute}}",
+ "semanticmaps-kml-pagelinktext": "Used as description for \"pagelinktext\" input box.\nSee example: [{{canonicalurl:Special:Ask|format=kml}} Special:Ask]\n\n<code>$1</code> is not a parameter, and appears as is.\n\nDefault value for the input box is {{msg-mw|Semanticmaps-default-kml-pagelink}}.",
+ "semanticmaps-shapes-improperformat": "This is an error message.\n\nParameter:\n* $1 - improper text",
+ "semanticmaps-shapes-missingshape": "This is an error message.\n\nParameter:\n* $1 - name of the shape",
+ "validator-type-mapscircle": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapscircle-list": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapsimageoverlay": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapsimageoverlay-list": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapsline": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapsline-list": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapslocation": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapslocation-list": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapsrectangle": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-mapsrectangle-list": "This is the name of a type of values that may be assigned to a parameter.",
+ "validator-type-wmsoverlay": "This is the name of a type of values that may be assigned to a parameter. WMS stands for [[wikipedia:en:Web_Map_Service|Web Map Service]].",
+ "validator-type-jsonfile": "{{Identical|Text}}"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ro.json b/www/wiki/extensions/Maps/i18n/ro.json
new file mode 100644
index 00000000..88911cdb
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ro.json
@@ -0,0 +1,96 @@
+{
+ "@metadata": {
+ "authors": [
+ "Firilacroco",
+ "KlaudiuMihaila",
+ "Minisarm",
+ "Stelistcristi",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Permite încorporarea hărților dinamice în paginile wiki, precum și geocodificarea adreselor ori efectuarea altor operațiuni de ordin geografic",
+ "right-geocode": "Geocod",
+ "maps_map": "Hartă",
+ "maps-loading-map": "Se încarcă harta...",
+ "maps-load-failed": "Imposibil de încărcat harta!",
+ "maps-markers": "Marcatori",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Marcaje pentru filtre",
+ "maps-others": "altele",
+ "maps-ns-layer": "Strat",
+ "maps-layer-property": "Proprietate",
+ "maps-layer-value": "Valoare",
+ "maps-layer-errors": "Erori",
+ "maps-error-invalid-layertype": "Nu există straturi de tip „$1”. Se acceptă doar {{PLURAL:$3|acest tip|aceste tipuri}}: $2",
+ "maps-error-no-layertype": "Trebuie să specificați tipul stratului. Se acceptă doar {{PLURAL:$2|acest tip|aceste tipuri}}: $1",
+ "validation-error-invalid-layer": "Parametrul $1 trebuie să fie un strat valabil.",
+ "validation-error-invalid-layers": "Parametrul $1 trebuie să fie una sau mai multe straturi valide.",
+ "maps-layer-of-type": "Strat de tip $1",
+ "maps-finddestination-par-location": "Amplasare inițială.",
+ "maps-displaymap-par-circles": "Cercuri de afișat",
+ "maps-displaymap-par-lines": "Linii de afișat",
+ "maps-displaymap-par-maxzoom": "Nivelul maxim de apropiere",
+ "maps-displaymap-par-minzoom": "Nivelul minim de apropiere",
+ "maps-displaymap-par-polygons": "Poligoane de afișat",
+ "maps-displaymap-par-rectangles": "Dreptunghiuri de afișat",
+ "validation-error-invalid-location": "Parametrul $1 trebuie să fie o locaţie validă.",
+ "validation-error-invalid-locations": "Parametrul $1 trebuie să fie una sau mai multe locaţii valide.",
+ "validation-error-invalid-width": "Parametrul $1 trebuie să fie o lățime validă.",
+ "validation-error-invalid-height": "Parametrul $1 trebuie să fie o înălțime validă.",
+ "validation-error-invalid-distance": "Parametrul $1 trebuie să reprezinte o distanță validă.",
+ "validation-error-invalid-distances": "Parametrul $1 trebuie să fie una sau mai multe distanțe valide.",
+ "validation-error-invalid-image": "Parametrul $1 trebuie să fie o imagine validă.",
+ "validation-error-invalid-images": "Parametrul $1 trebuie să fie una sau mai multe imagini valide.",
+ "validation-error-invalid-goverlay": "Parametrul $1 trebuie să fie o suprapunere validă.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "V",
+ "maps-latitude": "Latitudine:",
+ "maps-longitude": "Longitudine:",
+ "maps-invalid-coordinates": "Valoarea $1 nu a fost recunoscută ca un set valid de coordonate.",
+ "maps_coordinates_missing": "Nu au fost furnizate coordonate pentru hartă.",
+ "maps_geocoding_failed": "{{PLURAL:$2|Următoarea|Următoarele}} {{PLURAL:$2|adresă|adrese}} nu {{PLURAL:$2|a|au}} putut fi {{PLURAL:$2|geocodificată|geocodificate}}: $1.\nHarta nu poate fi afișată.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|Următoarea|Următoarele}} {{PLURAL:$2|adresă|adrese}} nu {{PLURAL:$2|a|au}} putut fi {{PLURAL:$2|geocodificată|geocodificate}} și {{PLURAL:$2|a|au}} fost {{PLURAL:$2|omisă|omise}} de pe hartă:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|Următorul|Următoarele}} {{PLURAL:$2|set|seturi}} de coordonate nu {{PLURAL:$2|a|au}} putut fi {{PLURAL:$2|recunoscut|recunoscute}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|Următorul|Următoarele}} {{PLURAL:$2|set|seturi}} de coordonate nu {{PLURAL:$2|a|au}} putut fi {{PLURAL:$2|recunoscut|recunoscute}} și {{PLURAL:$2|a|au}} fost {{PLURAL:$2|omis|omise}}: $1",
+ "maps_map_cannot_be_displayed": "Harta nu poate fi afișată.",
+ "maps-geocoder-not-available": "Opțiunea de geocodare pentru Hărți nu este disponibilă. Locația dumneavoastră nu a putut fi geocodată.",
+ "maps_click_to_activate": "Apăsați pentru a activa harta",
+ "maps_centred_on": "Hartă centrată la $1, $2.",
+ "mapeditor": "Editor de hărți",
+ "specialpages-group-maps": "Hărți",
+ "mapeditor-none-text": "Nimic",
+ "mapeditor-done-button": "Realizat",
+ "mapeditor-remove-button": "Elimină",
+ "mapeditor-import-button2": "Importă",
+ "mapeditor-export-button": "Exportare în cod wiki",
+ "mapeditor-import-button": "Importare din cod wiki",
+ "mapeditor-select-button": "Selectează acest poligon",
+ "mapeditor-mapparam-button": "Modifică parametrii hărții",
+ "mapeditor-clear-button": "Curăță harta",
+ "mapeditor-code-title": "Cod wiki",
+ "mapeditor-import-title": "Importare cod wiki",
+ "mapeditor-form-title": "Modificare detalii",
+ "mapeditor-link-title-switcher-popup-text": "Fereastră popup cu text",
+ "mapeditor-link-title-switcher-link-text": "Legătură",
+ "mapeditor-form-field-title": "Titlu",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Legătură",
+ "mapeditor-form-field-icon": "Pictogramă",
+ "mapeditor-form-field-group": "Grup",
+ "mapeditor-form-field-inlinelabel": "Etichetă în linie",
+ "mapeditor-form-field-strokecolor": "Culoarea conturului",
+ "mapeditor-form-field-strokeopacity": "Opacitatea conturului",
+ "mapeditor-form-field-strokeweight": "Grosimea conturului",
+ "mapeditor-form-field-fillcolor": "Culoarea umplerii",
+ "mapeditor-form-field-fillopcaity": "Opacitatea umplerii",
+ "mapeditor-form-field-showonhover": "Arată numai când mausul este deasupra",
+ "mapeditor-mapparam-title": "Modificare parametrii hartă",
+ "mapeditor-mapparam-defoption": "-Alegeți parametrul-",
+ "mapeditor-imageoverlay-button": "Adaugă suprapunerea de imagine",
+ "mapeditor-form-field-image": "Imagine",
+ "mapeditor-imageoverlay-title": "Detalii suprapunere imagine",
+ "mapeditor-form-field-visitedicon": "Pictogramă vizitată",
+ "semanticmaps-forminput-locations": "Locuri"
+}
diff --git a/www/wiki/extensions/Maps/i18n/roa-tara.json b/www/wiki/extensions/Maps/i18n/roa-tara.json
new file mode 100644
index 00000000..5fa0db84
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/roa-tara.json
@@ -0,0 +1,65 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Abbilite 'u 'ngapsulamende de le mappe dinameche jndr'à le pàggene de Uicchi, geocodificate e indirizzate a otre operaziune sciugrafeche",
+ "right-geocode": "Geocodece",
+ "maps_map": "Mappe",
+ "maps-loading-map": "Stoche a careche 'a mappe...",
+ "maps-load-failed": "Non ge pozze carecà 'a mappe!",
+ "maps-markers": "Marcature",
+ "maps-copycoords-prompt": "CTRL+C, INVIE",
+ "maps-others": "otre",
+ "maps-ns-layer": "Strate",
+ "maps-layer-property": "Probbietà",
+ "maps-layer-value": "Valore",
+ "maps-layer-errors": "Errore",
+ "maps-displaymap-par-circles": "Circole da fà 'ndrucà",
+ "maps-displaymap-par-maxzoom": "Levèlle de zoom massime",
+ "maps-displaymap-par-minzoom": "Levèlle de zoom minime",
+ "maps-displaymap-par-polygons": "Poligoni da fà vedè",
+ "maps-displaymap-par-rectangles": "Rettangole da fà vedè",
+ "validation-error-invalid-location": "'U parametre \"$1\" adda essere 'na posiziona valide.",
+ "validation-error-invalid-locations": "'U parametre \"$1\" adda essere une o cchiù posiziune valide.",
+ "validation-error-invalid-width": "'U parametre \"$1\" adda essere 'na larghezza valide.",
+ "validation-error-invalid-height": "'U parametre \"$1\" adda essere 'n'altezza valide.",
+ "validation-error-invalid-distance": "'U parametre \"$1\" adda essere 'na ditanza valide.",
+ "validation-error-invalid-distances": "'U parametre \"$1\" adda essere une o cchiù distanze valide.",
+ "validation-error-invalid-image": "'U parametre \"$1\" adda essere 'n'immaggine valide.",
+ "validation-error-invalid-images": "'U parametre \"$1\" adda essere une o cchiù immaggine valide.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "E",
+ "maps-abb-south": "S",
+ "maps-abb-west": "O",
+ "maps-latitude": "Latitudine:",
+ "maps-longitude": "Longitudine:",
+ "specialpages-group-maps": "Mappe",
+ "mapeditor-none-text": "Ninde",
+ "mapeditor-done-button": "Fatte",
+ "mapeditor-remove-button": "Live",
+ "mapeditor-import-button2": "'Mborte",
+ "mapeditor-link-title-switcher-link-text": "Collegamende",
+ "mapeditor-form-field-title": "Titole",
+ "mapeditor-form-field-text": "Teste",
+ "mapeditor-form-field-link": "Collegamende",
+ "mapeditor-form-field-icon": "Icone",
+ "mapeditor-form-field-group": "Gruppe",
+ "mapeditor-form-field-image": "Immaggine",
+ "semanticmaps-kml-link": "'Ndruche 'u file KML",
+ "semanticmaps-default-kml-pagelink": "Vide 'a pàgene $1",
+ "semanticmaps-latitude": "Latitudine: $1",
+ "semanticmaps-longitude": "Longitudine: $1",
+ "semanticmaps-altitude": "Iertezze: $1",
+ "semanticmaps-forminput-locations": "Luèche",
+ "validator-type-mapsline": "Linèe sciugrafeche",
+ "validator-type-mapsline-list": "Elenghe de linèe",
+ "validator-type-mapslocation": "Posizione sciugrafeche",
+ "validator-type-mapslocation-list": "Elenghe de le posiziune",
+ "validator-type-mapsrectangle": "Rettangole sciugrafeche",
+ "validator-type-mapsrectangle-list": "Elenghe de le rettangole",
+ "validator-type-mapspolygon": "Poligone sciugrafeche",
+ "validator-type-mapspolygon-list": "Elenghe de le poligone sciugrafece"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ru.json b/www/wiki/extensions/Maps/i18n/ru.json
new file mode 100644
index 00000000..08a7acf6
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ru.json
@@ -0,0 +1,251 @@
+{
+ "@metadata": {
+ "authors": [
+ "Adata80",
+ "Base",
+ "DCamer",
+ "Haffman",
+ "KPu3uC B Poccuu",
+ "Kaganer",
+ "Kalan",
+ "Lockal",
+ "MaxSem",
+ "McDutchie",
+ "Okras",
+ "Yuriy Apostol",
+ "Александр Сигачёв",
+ "Macofe",
+ "Perevod16",
+ "Alexandr Efremov",
+ "Cat1987",
+ "Туллук",
+ "Pastakhov",
+ "Putnik",
+ "Smigles",
+ "Patrick Star",
+ "Happy13241",
+ "Movses",
+ "Ole Yves",
+ "Stjn",
+ "Vlad5250",
+ "Shaleych",
+ "NBS",
+ "Diralik"
+ ]
+ },
+ "maps-desc": "Позволяет встраивать динамические карты в вики-страницы, геокодировать адреса и выполнять другие географические действия",
+ "right-geocode": "Геокодирование",
+ "action-geocode": "выполнение геокодирования в этой вики",
+ "maps_map": "Карта",
+ "maps-tracking-category": "Страницы с картой, сгенерированной расширением Maps",
+ "maps-loading-map": "Идёт загрузка карты…",
+ "maps-load-failed": "Невозможно загрузить карту!",
+ "maps-markers": "Маркеры",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Маркеры фильтра",
+ "maps-others": "другие",
+ "maps-kml-parsing-failed": "Не удалось выполнить разбор одного или нескольких KML-файлов, обычно вследствие отказа в получении или некорректного XML.",
+ "maps-ns-layer": "Слой",
+ "maps-ns-layer-talk": "Обсуждение слоя",
+ "maps-layer-property": "Свойство",
+ "maps-layer-value": "Значение",
+ "maps-layer-errors": "Ошибки",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Недопустимое определение|Недопустимые определения}}",
+ "maps-layerdef-invalid-fatal": "Фатальное недопустимое определение",
+ "maps-layerdef-wrong-namespace": "Определения слоёв действительны только на страницах пространства имён «$1»",
+ "maps-layerdef-equal-layer-name": "Имена слоёв должны быть уникальными в пределах одной и той же страницы слоёв. «$1» уже используется другим слоем.",
+ "maps-layerpage-usage": "Страницы с картами, использующие слой «$1»",
+ "maps-layerpage-nousage": "Нет страниц, использующих этот слой в данный момент.",
+ "maps-error-invalid-layertype": "Не существует слоя типа «$1». {{PLURAL:$3|1=Поддерживается только следующий тип|Поддерживаются только следующие типы}}: $2",
+ "maps-error-no-layertype": "Вам нужно указать тип слоя. {{PLURAL:$2|1=Поддерживается только следующий тип|Поддерживаются следующие типы}}: $1",
+ "validation-error-invalid-layer": "Параметр $1 должен быть корректным слоем.",
+ "validation-error-invalid-layers": "Параметр $1 должен содержать один или несколько корректных слоёв.",
+ "validation-error-no-non-numeric": "Параметр «$1» должен быть нецифровой строкой.",
+ "validation-error-no-non-numerics": "Параметр «$1» должен быть одной или несколькими нецифровыми строками.",
+ "maps-layer-of-type": "Слой типа $1",
+ "maps-layer-of-type-and-name": "Слой «$2» типа «$1»",
+ "maps-layer-type-supported-by": "Этот тип слоя может быть использован {{PLURAL:$2|1=только с картографической службой|только со следующими картографическими службами:}} $1",
+ "maps-coordinates-description": "Перехватчик синтаксического анализатора для форматирования координат из любого и в любой поддерживаемый формат.",
+ "maps-displaymap-description": "Отображение географических карт без каких-либо вики-маркеров на них.",
+ "maps-distance-description": "Преобразование расстояния, выраженного в определенных поддерживаемых единицах, в его эквивалент в других единицах.",
+ "maps-finddestination-description": "Найти место назначения от заданной начальной точки (может быть в любом формате из поддерживаемых), начальное направление и расстояние.",
+ "maps-geocode-description": "Включает геокодирование адресов. Иными словами, преобразует понятные человеку названия мест в наборы координат. Поддерживается несколько сервисов геокодирования, которые не следует путать с картографическими сервисами.",
+ "maps-geodistance-description": "Рассчитать географическое расстояние между двумя точками, из любого и в любой поддерживаемый формат.",
+ "maps-mapsdoc-description": "Показывает таблицу с параметрами для указанного картографического сервиса вместе с их значениями по умолчанию и описаниями.",
+ "maps-layerdefinition-description": "Описывает пользовательский слой, который может отображаться с другими функциями карты.",
+ "maps-mapsdoc-par-service": "Картографический сервис, для которого отображать документацию по параметрам.",
+ "maps-mapsdoc-par-language": "Язык, на котором отображается документация. Если перевод не доступен, вместо него будет использоваться английский язык.",
+ "maps-coordinates-par-location": "Координаты, которые требуется отформатировать.",
+ "maps-coordinates-par-format": "Целевой формат координат.",
+ "maps-coordinates-par-directional": "Указывает, должны ли координаты выводиться непосредственно или нет.",
+ "maps-par-scrollwheelzoom": "Отображает, включена ли прокрутка мышью.",
+ "maps-distance-par-distance": "Расстояние для преобразования в эквивалентное в указанных единицах.",
+ "maps-distance-par-decimals": "Максимальное количество цифр дробной части в результирующем значении.",
+ "maps-distance-par-unit": "Единицы, в которых будет отображено расстояние.",
+ "maps-finddestination-par-location": "Исходное положение.",
+ "maps-finddestination-par-bearing": "Начальное направление.",
+ "maps-finddestination-par-distance": "Протяжённость путешествия.",
+ "maps-finddestination-par-format": "Формат, в котором отображается пункт назначения.",
+ "maps-finddestination-par-directional": "Указывает, должен ли формат назначения быть направленным или нет.",
+ "maps-geocode-par-location": "Адрес, который вы желаете геокодировать.",
+ "maps-geocode-par-format": "Формат получаемых координат.",
+ "maps-geocode-par-directional": "Указывает, должны ли координаты выводиться непосредственно или нет.",
+ "maps-geodistance-par-location1": "Первая точка в наборе для расчёта расстояния.",
+ "maps-geodistance-par-location2": "Вторая точка в наборе для расчёта расстояния.",
+ "maps-geodistance-par-unit": "Единица измерения расстояния.",
+ "maps-geodistance-par-decimals": "Наибольшее количество цифр в дробной части результата.",
+ "maps-displaymap-par-mappingservice": "Позволяет выбрать сервис карт, который будет использоваться.",
+ "maps-displaymap-par-coordinates": "Одно или несколько мест для отображения на карте. Они будут обозначаться маркером.",
+ "maps-displaymap-par-visitedicon": "Имя файла для изображения, которое будет использоваться для значков-маркеров после того, как на сами маркеры нажмут",
+ "maps-displaymap-par-zoom": "Позволяет задать уровень масштабирования карты.\nКогда не указан, и на карте присутствуют несколько маркеров, будет выбран наиболее подходящий масштаб, а не тот, что настроен по умолчанию.",
+ "maps-displaymap-par-centre": "Позволяет задать координаты центра карты для display_point.\nПозволяет использовать и адреса, и координаты.\nКогда это свойство не задано, карта будет центрироваться сама по предоставленному маркеру или между предоставленных маркеров.",
+ "maps-displaymap-par-title": "Позволяет задать текст, который будет отображаться во всплывающих окнах всех маркеров, у которых нет определенного заголовка.\nПри использовании совместно с подписью, название будет выделено жирным шрифтом и подчеркнуто.",
+ "maps-displaymap-par-label": "Позволяет задать текст, который будет отображаться во всплывающих окнах всех маркеров, у которых нет определенных подписей.",
+ "maps-displaymap-par-icon": "Позволяет установить значок, используемый для всех маркеров.",
+ "maps-displaymap-par-circles": "Кружки для отображения",
+ "maps-displaymap-par-copycoords": "Показывать ли при нажатии на место диалоговое окно, из которого могут быть скопированы его координаты",
+ "maps-displaymap-par-lines": "Линии для отображения",
+ "maps-displaymap-par-maxzoom": "Максимальный уровень масштабирования",
+ "maps-displaymap-par-minzoom": "Минимальный уровень масштабирования",
+ "maps-displaymap-par-polygons": "Полигоны для отображения",
+ "maps-displaymap-par-rectangles": "Прямоугольники для отображения",
+ "maps-displaymap-par-static": "Сделать карту статичной",
+ "maps-displaymap-par-wmsoverlay": "Использовать слой WMS",
+ "maps-displaymap-par-geojson": "URL файла или название страницы, содержащей данные GeoJSON",
+ "maps-fullscreen-button": "Переключить полноэкранный режим",
+ "maps-fullscreen-button-tooltip": "Посмотреть карту в полноэкранном или встроенном режиме.",
+ "validation-error-invalid-location": "Параметр $1 должен быть корректным местоположением.",
+ "validation-error-invalid-locations": "Параметр $1 должен содержать одно или несколько корректных местоположений.",
+ "validation-error-invalid-width": "Параметр $1 должен быть корректной шириной.",
+ "validation-error-invalid-height": "Параметр $1 должен быть корректной высотой.",
+ "validation-error-invalid-distance": "Параметр $1 должен быть корректным расстоянием.",
+ "validation-error-invalid-distances": "Параметр $1 должен содержать одно или несколько корректных расстояний.",
+ "validation-error-invalid-image": "Параметр $1 должен быть корректным изображением.",
+ "validation-error-invalid-images": "Параметр $1 должен содержать одно или несколько корректных изображений.",
+ "validation-error-invalid-goverlay": "Параметр $1 должен быть корректным наложением.",
+ "validation-error-invalid-goverlays": "Параметр $1 должен содержать одно или несколько корректных наложений.",
+ "maps-abb-north": "С",
+ "maps-abb-east": "В",
+ "maps-abb-south": "Ю",
+ "maps-abb-west": "З",
+ "maps-latitude": "Широта:",
+ "maps-longitude": "Долгота:",
+ "maps-invalid-coordinates": "Значение $1 не признано допустимым набором координат.",
+ "maps_coordinates_missing": "Не указаны координаты для карты.",
+ "maps_geocoding_failed": "{{PLURAL:$2|1=Следующий адрес не может быть геокодирован|Следующие адреса не могут быть геокодированы}}: $1.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|1=Следующий адрес не может быть геокодирован и был удалён|Следующие адреса не могут быть геокодированы и были удалены}} с карты:\n$1",
+ "maps_unrecognized_coords": "{{PLURAL:$2|1=Следующая пара координат не была опознана|Следующие координаты не были опознаны}}: $1.",
+ "maps_unrecognized_coords_for": "{{PLURAL:$2|1=Следующая пара координат не была опознана, она не показана|Следующие координаты не были опознаны, они не показаны}} на карте:\n$1",
+ "maps_map_cannot_be_displayed": "Карта не может быть показана.",
+ "maps-geocoder-not-available": "Функция геокодирования карт недоступна, ваше местоположение не может быть геокодировано.",
+ "maps_leaflet": "Листовка",
+ "maps-leaflet-par-defzoom": "Позволяет задавать масштаб карты по умолчанию.",
+ "maps-leaflet-par-layers": "Слои, которые будут доступны при выборе. Первый слой будет отображаться при загрузке карты.",
+ "maps-leaflet-par-overlaylayers": "Слои подложки, которые будут показаны при загрузке карты.",
+ "maps-leaflet-par-maxclusterradius": "Максимальный радиус, который кластер будет покрывать от центрального маркера (в пикселях).",
+ "maps-leaflet-par-clusterspiderfy": "Когда вы нажимаете кластер в нижнем уровне масштабирования, мы spiderfy его, чтобы вы могли видеть все его маркеры.",
+ "maps_click_to_activate": "Нажмите для активации карты",
+ "maps_centred_on": "Центр карты — $1, $2.",
+ "maps-par-mappingservice": "Позволяет выбрать сервис карт, который будет использоваться.",
+ "maps-par-resizable": "Даёт возможность изменять размер карты, потащив её за правый нижний угол.",
+ "maps-par-searchmarkers": "Позволяет искать определённые маркеры с помощью поля, встроенного в карту.",
+ "maps-par-zoom": "Уровень масштабирования карты. Для карт с маркерами это будет по умолчанию наиболее приближенный уровень, при котором всё ещё будут видны все маркеры.",
+ "maps-par-width": "Позволяет задать ширину карты. По умолчанию единицей измерения будет считаться пиксель, но можно явно указать одну из следующих единиц: px, ex, em, %.",
+ "maps-par-height": "Позволяет задать высоту карты. По умолчанию единицей измерения будет считаться пиксель, но можно явно указать одну из следующих единиц: px, ex, em, %.",
+ "maps-par-centre": "Расположение на карте, по которому она должна быть отцентрована",
+ "maps-par-enable-fullscreen": "Включить кнопку полноэкранного режима",
+ "maps-par-kml": "KML файлы для загрузки на карту.",
+ "maps-par-markercluster": "Позволяет объединить несколько находящихся рядом маркеров в один маркер",
+ "maps-googlemaps3-incompatbrowser": "Ваш браузер несовместим с Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Позволяет добавить изображение, которое будет показано в определённом месте карты.",
+ "maps-googlemaps3-par-type": "Тип карты для начального отображения.",
+ "maps-googlemaps3-par-types": "Типы карты, которые будут доступны через элемент управления типом карты.",
+ "maps-googlemaps3-par-layers": "Специальные слои для загрузки на карту.",
+ "maps-googlemaps3-par-controls": "Элементы управления для размещения на карте.",
+ "maps-googlemaps3-par-zoomstyle": "Стиль элемента управления масштабом.",
+ "maps-googlemaps3-par-typestyle": "Стиль элемента управления типа.",
+ "maps-googlemaps3-par-autoinfowindows": "Автоматически открывает все информационные окна после загрузки страницы.",
+ "maps-googlemaps3-par-gkml": "KML файлы, хранящиеся в Google для загрузки на карту.",
+ "maps-googlemaps3-par-kmlrezoom": "Перемасштабировать карту после загрузки слоёв KML.",
+ "maps-googlemaps3-par-poi": "Показать достопримечательности.",
+ "maps-googlemaps3-par-clustergridsize": "Размер сетки кластера в пикселях.",
+ "maps-par-clustermaxzoom": "Максимальный уровень увеличения, при котором может существовать кластер.",
+ "maps-par-clusterzoomonclick": "Является ли поведение по умолчанию нажатием на кластер, чтобы увеличить его.",
+ "maps-par-maxclusterradius": "Максимальный радиус, охватываемый кластером.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Должен ли центр каждого кластера быть средним по всем маркерам в кластере.",
+ "maps-googlemaps3-par-clusterminsize": "Минимальное количество маркеров, которые должны быть в кластере до того, как маркеры будут скрыты, и будет показано количество.",
+ "mapeditor": "Редактор карт",
+ "specialpages-group-maps": "Карты",
+ "mapeditor-parser-error": "Произошла ошибка обработки метаданных. Введённые данные проигнорированы.",
+ "mapeditor-none-text": "Пусто",
+ "mapeditor-done-button": "Готово",
+ "mapeditor-remove-button": "Удалить",
+ "mapeditor-import-button2": "Импортировать",
+ "mapeditor-export-button": "Экспортировать в вики-текст",
+ "mapeditor-import-button": "Импортировать из викитекста",
+ "mapeditor-select-button": "Выберите этот полигон",
+ "mapeditor-mapparam-button": "Править параметры карты",
+ "mapeditor-clear-button": "Очистить карту",
+ "mapeditor-code-title": "Вики-текст",
+ "mapeditor-import-title": "Импорт викитекста",
+ "mapeditor-import-note": "Обратите внимание, что обработчик ожидает очень строго отформатированный вики-текст. Вики-текст, введённый здесь, должен точно соответствовать тому вики-тексту, который был сгенерирован при экспорте.",
+ "mapeditor-form-title": "Правка деталей",
+ "mapeditor-link-title-switcher-popup-text": "Всплывающая подсказка",
+ "mapeditor-link-title-switcher-link-text": "Ссылка",
+ "mapeditor-form-field-title": "Название",
+ "mapeditor-form-field-text": "Текст",
+ "mapeditor-form-field-link": "Ссылка",
+ "mapeditor-form-field-icon": "Иконка",
+ "mapeditor-form-field-group": "Группа",
+ "mapeditor-form-field-inlinelabel": "Текстовая метка",
+ "mapeditor-form-field-strokecolor": "Цвет контура",
+ "mapeditor-form-field-strokeopacity": "Прозрачность контура",
+ "mapeditor-form-field-strokeweight": "Толщина контура",
+ "mapeditor-form-field-fillcolor": "Цвет заливки",
+ "mapeditor-form-field-fillopcaity": "Прозрачность заливки",
+ "mapeditor-form-field-showonhover": "Показывать только при наведении",
+ "mapeditor-mapparam-title": "Править параметры карты",
+ "mapeditor-mapparam-defoption": "-Выберите параметр-",
+ "mapeditor-imageoverlay-button": "Добавить наложение изображения",
+ "mapeditor-form-field-image": "Изображение",
+ "mapeditor-imageoverlay-title": "Изображение",
+ "mapeditor-form-field-visitedicon": "Иконка для посещённого",
+ "semanticmaps-unrecognizeddistance": "Значение $1 — это недопустимое расстояние.",
+ "semanticmaps-kml-link": "Просмотреть файл KML",
+ "semanticmaps-default-kml-pagelink": "Просмотреть страницу $1",
+ "semanticmaps-latitude": "Широта: $1",
+ "semanticmaps-longitude": "Долгота: $1",
+ "semanticmaps-altitude": "Высота: $1",
+ "semanticmaps-forminput-locations": "Места",
+ "semanticmaps-par-staticlocations": "Список мест для добавления на карту вместе с запрашиваемыми данными. Например, к display_points можно добавить название, описание и значок, используя тильду ~ в качестве разделителя.",
+ "semanticmaps-par-showtitle": "Показывать или нет заголовок в окне информации маркера. Его отключение часто бывает полезно при использовании шаблона для форматирования содержимого окна информация.",
+ "semanticmaps-par-hidenamespace": "Показывать название пространства имён в информационном окне маркера",
+ "semanticmaps-par-centre": "Центр карты. Если не задан, карта автоматически выберет оптимальный центр, позволяющий отобразить все маркеры на карте.",
+ "semanticmaps-par-template": "Шаблон для форматирования содержимого окна информация.",
+ "semanticmaps-par-geocodecontrol": "Показать панель управления геокодированием.",
+ "semanticmaps-par-activeicon": "Значок, который будет отображаться вместо стандартного маркера в случаях, когда активная страница совпадает с результатом запроса",
+ "semanticmaps-par-pagelabel": "Если задано значение «yes» («да»), все маркеры будут иметь «inlineLabel» со ссылкой на страницу, содержащую координаты для маркера",
+ "semanticmaps-par-ajaxcoordproperty": "Имя свойства координат, которое используется для построения запроса ajax.",
+ "semanticmaps-par-ajaxquery": "Второй запрос, который отправляется через ajax для извлечения дополнительных координат.",
+ "semanticmaps-par-userparam": "Значение, которое передается за каждый вызов шаблона, если шаблон используется",
+ "semanticmaps-kml-text": "Текст, связанный с каждой страницы. Переопределяется дополнительными запрашиваемыми свойствами, если таковые имеются.",
+ "semanticmaps-kml-title": "Заголовок по умолчанию для результатов",
+ "semanticmaps-kml-linkabsolute": "Ссылки должны быть абсолютными (а не относительными)",
+ "semanticmaps-kml-pagelinktext": "Текст, используемый для ссылки на страницу, в которой $1 будет заменён названием страницы.",
+ "semanticmaps-shapes-improperformat": "Неправильное форматирование $1. Обратитесь к документации по форматированию.",
+ "semanticmaps-shapes-missingshape": "Фигуры для $1 не найдены. Пожалуйста, обратитесь к документации по доступным фигурам",
+ "validator-type-mapscircle": "Географический круг",
+ "validator-type-mapscircle-list": "Список кругов",
+ "validator-type-mapsimageoverlay": "Наложение изображений",
+ "validator-type-mapsimageoverlay-list": "Список наложений изображений",
+ "validator-type-mapsline": "Географическая линия",
+ "validator-type-mapsline-list": "Список линий",
+ "validator-type-mapslocation": "Географическое положение",
+ "validator-type-mapslocation-list": "Список местоположений",
+ "validator-type-mapsrectangle": "Географический прямоугольник",
+ "validator-type-mapsrectangle-list": "Список прямоугольников",
+ "validator-type-mapspolygon": "Географический полигон",
+ "validator-type-mapspolygon-list": "Перечень географических полигонов",
+ "validator-type-wmsoverlay": "Оверлей веб-карты",
+ "validator-type-jsonfile": "текст"
+}
diff --git a/www/wiki/extensions/Maps/i18n/rue.json b/www/wiki/extensions/Maps/i18n/rue.json
new file mode 100644
index 00000000..e5ab3801
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/rue.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gazeb"
+ ]
+ },
+ "maps_map": "Мапа",
+ "maps-loading-map": "Награваня мапы. . .",
+ "maps-abb-north": "С",
+ "maps-abb-east": "В",
+ "maps-abb-south": "Ю",
+ "maps-abb-west": "З"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sco.json b/www/wiki/extensions/Maps/i18n/sco.json
new file mode 100644
index 00000000..9503059b
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sco.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "John Reid"
+ ]
+ },
+ "maps-geodistance-par-geoservice": "The mapping service this parser function is uised thegather wi.\nThis can affect the default geocoding service value.",
+ "maps-displaymap-par-visitedicon": "The filename o aen eemage tae be uised fer maurker icons efter the oreeginal maurkers hae been clap't"
+}
diff --git a/www/wiki/extensions/Maps/i18n/si.json b/www/wiki/extensions/Maps/i18n/si.json
new file mode 100644
index 00000000..03bef201
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/si.json
@@ -0,0 +1,109 @@
+{
+ "@metadata": {
+ "authors": [
+ "තඹරු විජේසේකර",
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "right-geocode": "භූකේතය",
+ "maps_map": "සිතියම",
+ "maps-loading-map": "සිතියම පුරණය වෙමින් පවතී...",
+ "maps-load-failed": "සිතියම පූරණය කල නොහැක!",
+ "maps-markers": "සලකුණු කාරක",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "පෙරහන් සලකුණු කාරක",
+ "maps-others": "අනෙකුන්",
+ "maps-ns-layer": "ස්තරය",
+ "maps-ns-layer-talk": "ස්තර කතබහ",
+ "maps-layer-property": "ගුණාංගය",
+ "maps-layer-value": "අගය",
+ "maps-layer-errors": "දෝෂ",
+ "validation-error-invalid-layer": "$1 පරාමිතිය වලංගු ස්ථරයක් විය යුතුය.",
+ "validation-error-invalid-layers": "$1 පරාමිතිය වලංගු එක් හෝ තවත් ස්ථරයක් විය යුතුය.",
+ "maps-layer-of-type": "$1 වර්ගයේ ස්තරය",
+ "maps-coordinates-par-location": "ඔබට ආකෘතිකරණය කල යුතු ඛණ්ඩාංක.",
+ "maps-coordinates-par-format": "ඛණ්ඩාංක සඳහා ඉලක්කගත ආකෘතිය.",
+ "maps-finddestination-par-location": "ආරම්භක ස්ථානය.",
+ "maps-finddestination-par-bearing": "ආරම්භක දිගංශය.",
+ "maps-finddestination-par-distance": "ගමන් කිරීමට ඇති දුර.",
+ "maps-finddestination-par-format": "ගමනාන්තය ප්‍රතිදානය කල යුතු ආකෘතිය.",
+ "maps-geocode-par-location": "ඔබට භූකේතීකරණය කල යුතු ලිපිනය.",
+ "maps-geocode-par-format": "එලිත ඛණ්ඩාංක සඳහා ආකෘතිය.",
+ "maps-displaymap-par-circles": "පෙන්වීමට ඇති වක්‍ර",
+ "maps-displaymap-par-lines": "පෙන්වීමට ඇති රේඛා",
+ "maps-displaymap-par-maxzoom": "උපරිම විශාලන මට්ටම",
+ "maps-displaymap-par-minzoom": "අවම විශාලන මට්ටම",
+ "maps-displaymap-par-polygons": "පෙන්වීමට ඇති බහුඅස‍්‍ර",
+ "maps-displaymap-par-rectangles": "පෙන්වීමට ඇති ඍජුකෝණාශ්‍ර",
+ "maps-displaymap-par-static": "සිතියම ස්ථිතික විය යුතු වුවහොත්",
+ "maps-displaymap-par-wmsoverlay": "WMS වසාලනය භාවිතා කරන්න",
+ "validation-error-invalid-location": "$1 පරාමිතිය වලංගු ස්ථානයක් විය යුතුය.",
+ "validation-error-invalid-locations": "$1 පරාමිතිය එක් හෝ තවත් වලංගු ස්ථාන විය යුතුය.",
+ "validation-error-invalid-width": "$1 පරාමිතිය වලංගු පළලක් විය යුතුය.",
+ "validation-error-invalid-height": "$1 පරාමිතිය වලංගු උසක් විය යුතුය.",
+ "validation-error-invalid-distance": "$1 පරාමිතිය වලංගු දුරක් විය යුතුය.",
+ "validation-error-invalid-distances": "$1 පරාමිතිය එක් හෝ තවත් වලංගු දුරක් විය යුතුය.",
+ "validation-error-invalid-image": "$1 පරාමිතිය වලංගු පින්තූරයක් විය යුතුය.",
+ "validation-error-invalid-images": "$1 පරාමිතිය එක් හෝ තවත් වලංගු පින්තූරයක් විය යුතුය.",
+ "validation-error-invalid-goverlay": "$1 පරාමිතිය වලංගු වසාලනයක් විය යුතුය.",
+ "validation-error-invalid-goverlays": "$1 පරාමිතිය එක් හෝ තවත් වලංගු වසාලනයක් විය යුතුය.",
+ "maps-abb-north": "උ",
+ "maps-abb-east": "නැ",
+ "maps-abb-south": "ද",
+ "maps-abb-west": "බ",
+ "maps-latitude": "අක්ෂාංශය:",
+ "maps-longitude": "දේශාංශය:",
+ "maps_coordinates_missing": "සිතියම සඳහා ඛණ්ඩාංක කිසිවක් ඉදිරිපත් කොට නොමැත.",
+ "maps_map_cannot_be_displayed": "සිතියම සංදර්ශනය කල නොහැක.",
+ "maps_click_to_activate": "සිතියම සක්‍රිය කිරීම සඳහා ක්ලික් කරන්න",
+ "maps_centred_on": "$1 හිදී සිතියම මධ්‍යගත වේ, $2.",
+ "maps-par-kml": "සිතියම මත පැටවිය යුතු KML ගොනු.",
+ "maps-googlemaps3-par-type": "ආරම්භක වශයෙන් පෙන්විය යුතු සිතියම් වර්ගය.",
+ "maps-googlemaps3-par-layers": "සිතියම මත පැටවිය යුතු විශේෂ ස්ථර.",
+ "maps-googlemaps3-par-zoomstyle": "විශාලන පාලකයේ ශෛලිය.",
+ "maps-googlemaps3-par-typestyle": "වර්ග පාලකයේ ශෛලිය.",
+ "maps-googlemaps3-par-poi": "අභිරුචි ලක්ෂ්‍ය පෙන්වන්න.",
+ "mapeditor": "සිතියම් සංස්කාරක",
+ "specialpages-group-maps": "සිතියම්",
+ "mapeditor-none-text": "කිසිවක් නොමැත",
+ "mapeditor-done-button": "හරි",
+ "mapeditor-remove-button": "ඉවත් කරන්න",
+ "mapeditor-import-button2": "ආයාත කරන්න",
+ "mapeditor-export-button": "විකිකේතය වෙත නිර්යාත කරන්න",
+ "mapeditor-import-button": "විකිකේතය වෙතින් ආයාත කරන්න",
+ "mapeditor-select-button": "මෙම බහුඅස‍්‍රය තෝරාගන්න",
+ "mapeditor-mapparam-button": "සිතියම් පරාමිතීන් සංස්කරණය කරන්න",
+ "mapeditor-clear-button": "සිතියම හිස් කරන්න",
+ "mapeditor-code-title": "විකි කේතය",
+ "mapeditor-import-title": "විකිකේතය ආයාත කරන්න",
+ "mapeditor-form-title": "විස්තර සංස්කරණය කරන්න",
+ "mapeditor-link-title-switcher-popup-text": "පාඨයක් සමඟ Popup",
+ "mapeditor-link-title-switcher-link-text": "සබැඳුම",
+ "mapeditor-form-field-title": "ශීර්ෂය",
+ "mapeditor-form-field-text": "පෙළ",
+ "mapeditor-form-field-link": "සබැඳුම",
+ "mapeditor-form-field-icon": "අයිකනය",
+ "mapeditor-form-field-group": "කාණ්ඩය",
+ "mapeditor-form-field-inlinelabel": "එක් තල ලේබලය",
+ "mapeditor-form-field-strokecolor": "ආඝාත වර්ණය",
+ "mapeditor-form-field-strokeopacity": "ආඝාත පාරාන්ධතාව",
+ "mapeditor-form-field-strokeweight": "ආඝාත බර",
+ "mapeditor-form-field-fillcolor": "පිරවුම් වර්ණය",
+ "mapeditor-form-field-fillopcaity": "පිරවුම් පාරාන්ධතාව",
+ "mapeditor-form-field-showonhover": "ගැවසෙන විට පමණක් පෙන්වන්න",
+ "mapeditor-mapparam-title": "සිතියම් පරාමිතීන් සංස්කරණය කරන්න",
+ "mapeditor-mapparam-defoption": "-පරාමිතිය තෝරාගන්න-",
+ "mapeditor-imageoverlay-button": "පින්තූර වසාලනයක් එක් කරන්න",
+ "mapeditor-form-field-image": "පිංතූරය",
+ "mapeditor-imageoverlay-title": "පින්තූර වසාලන විස්තර",
+ "mapeditor-form-field-visitedicon": "ගොඩ වැදුණු අයිකනය",
+ "semanticmaps-unrecognizeddistance": "$1 අගය වලංගු දුර ප්‍රමාණයක් නොවේ.",
+ "semanticmaps-kml-link": "KML ගොනුව නරඹන්න",
+ "semanticmaps-default-kml-pagelink": "$1 පිටුව නරඹන්න",
+ "semanticmaps-latitude": "අක්ෂාංශය: $1",
+ "semanticmaps-longitude": "දේශාංශය: $1",
+ "semanticmaps-altitude": "උන්නතාංශය: $1",
+ "semanticmaps-forminput-locations": "ස්ථාන",
+ "semanticmaps-par-geocodecontrol": "භූකේතීකරණ පාලකය පෙන්වන්න.",
+ "semanticmaps-kml-title": "ප්‍රතිඑල සඳහා සාමාන්‍ය ශීර්ෂය"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sk.json b/www/wiki/extensions/Maps/i18n/sk.json
new file mode 100644
index 00000000..a8a7284a
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sk.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Helix84",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Umožňuje vkladať dynamické mapy do wiki stránok, geokódovať adresy a ďalšie geografické operácie",
+ "maps_map": "Mapa",
+ "maps-abb-north": "S",
+ "maps-abb-east": "V",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Zem. dĺžka:",
+ "maps-longitude": "Zem. šírka:",
+ "maps_coordinates_missing": "Neboli poskytnuté žiadne súradnice.",
+ "maps_geocoding_failed": "Nebolo možné určiť súradnice {{PLURAL:$2|nasledovnej adresy|nasledovných adries}}: $1.",
+ "maps_geocoding_failed_for": "Nebolo možné určiť súradnice {{PLURAL:$2|nasledovnej adresy|nasledovných adries}} a {{PLURAL:$2|bola vynechaná|boli vynechané}} z mapy: $1."
+}
diff --git a/www/wiki/extensions/Maps/i18n/sl.json b/www/wiki/extensions/Maps/i18n/sl.json
new file mode 100644
index 00000000..da19374e
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sl.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dbc334",
+ "Eleassar",
+ "Lesko987",
+ "Macofe"
+ ]
+ },
+ "maps-desc": "Omogoča vključevanje dinamičnih zemljevidov na wikistrani, geokodiranje naslovov in druge geografske posege",
+ "right-geocode": "Geokodiranje",
+ "maps_map": "Zemljevid",
+ "maps-loading-map": "Nakladanje zemljevida...",
+ "maps-load-failed": "Zemljevid ni bilo mogoče naložiti.",
+ "maps-kml-parsing-failed": "Razčlenjevanje ene ali več datotek KML ni uspelo. Navadno je vzrok neuspešen priklic ali slabo oblikovan XML.",
+ "maps-fullscreen-button": "Vklopi celozaslonski prikaz",
+ "maps-fullscreen-button-tooltip": "Celozaslonski ali vključeni prikaz zemljevida.",
+ "maps-googlemaps3-par-enable-fullscreen": "Omogoči gumb za celozaslonski prikaz",
+ "maps-abb-north": "S",
+ "maps-abb-east": "V",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Zemljepisna širina:",
+ "maps-longitude": "Zemljepisna dolžina:",
+ "maps_googlemaps3": "Google Maps v3",
+ "maps_openlayers": "OpenLayers",
+ "maps_osm": "OpenStreetMap"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sq.json b/www/wiki/extensions/Maps/i18n/sq.json
new file mode 100644
index 00000000..8a5cafe2
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sq.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ammartivari"
+ ]
+ },
+ "mapeditor": "Redaktor hartash"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sr-ec.json b/www/wiki/extensions/Maps/i18n/sr-ec.json
new file mode 100644
index 00000000..863eef89
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sr-ec.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01",
+ "Rancher",
+ "Михајло Анђелковић"
+ ]
+ },
+ "maps_map": "Мапа",
+ "maps-loading-map": "Учитавање мапе...",
+ "validation-error-invalid-location": "Параметар $1 мора бити валидна локација",
+ "validation-error-invalid-locations": "Параметар $1 мора бити једна или више важећих локација.",
+ "validation-error-invalid-width": "Параметар $1 мора бити валидна ширина.",
+ "validation-error-invalid-height": "Параметар $1 мора бити валидна висина.",
+ "validation-error-invalid-distance": "Параметар $1 мора бити валидно растојање.",
+ "validation-error-invalid-distances": "Параметар $1 мора бити једно или више валидних растојања.",
+ "validation-error-invalid-image": "Параметар $1 мора бити валидна слика.",
+ "validation-error-invalid-images": "Параметар $1 мора бити једна или више валидних слика.",
+ "maps-abb-north": "С",
+ "maps-abb-east": "И",
+ "maps-abb-south": "Ј",
+ "maps-abb-west": "З",
+ "maps-latitude": "Географска ширина:",
+ "maps-longitude": "Географска дужина:",
+ "maps_googlemaps3": "Гугл мапе, треће издање",
+ "maps_openlayers": "Опенлејерс",
+ "maps_osm": "OpenStreetMap"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sr-el.json b/www/wiki/extensions/Maps/i18n/sr-el.json
new file mode 100644
index 00000000..733e43fd
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sr-el.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01"
+ ]
+ },
+ "maps_map": "Mapa",
+ "maps-loading-map": "Učitavanje mape...",
+ "validation-error-invalid-location": "Parametar $1 mora biti validna lokacija",
+ "validation-error-invalid-locations": "Parametar $1 mora biti jedna ili više važećih lokacija.",
+ "validation-error-invalid-width": "Parametar $1 mora biti validna širina.",
+ "validation-error-invalid-height": "Parametar $1 mora biti validna visina.",
+ "validation-error-invalid-distance": "Parametar $1 mora biti validno rastojanje.",
+ "validation-error-invalid-distances": "Parametar $1 mora biti jedno ili više validnih rastojanja.",
+ "validation-error-invalid-image": "Parametar $1 mora biti validna slika.",
+ "validation-error-invalid-images": "Parametar $1 mora biti jedna ili više validnih slika.",
+ "maps-abb-north": "S",
+ "maps-abb-east": "I",
+ "maps-abb-south": "J",
+ "maps-abb-west": "Z",
+ "maps-latitude": "Geografska širina:",
+ "maps-longitude": "Geografska dužina:",
+ "maps_googlemaps3": "Gugl mape, treće izdanje",
+ "maps_openlayers": "Openlejers",
+ "maps_osm": "OpenStreetMap"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sv.json b/www/wiki/extensions/Maps/i18n/sv.json
new file mode 100644
index 00000000..0e40304e
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sv.json
@@ -0,0 +1,232 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ainali",
+ "Dafer45",
+ "Fader",
+ "Fluff",
+ "Jopparn",
+ "Lokal Profil",
+ "Per",
+ "Rotsee",
+ "WikiPhoenix",
+ "Macofe",
+ "Martinwiss"
+ ]
+ },
+ "maps-desc": "Ger möjlighet att bädda in dynamiska kartor i wiki-sidor, geokoding av adresser och andra geografiska åtgärder",
+ "right-geocode": "Geokod",
+ "action-geocode": "utför geokoding på denna wiki",
+ "maps_map": "Karta",
+ "maps-tracking-category": "Sidor med en karta som renderats med Karttillägget",
+ "maps-loading-map": "Laddar karta ...",
+ "maps-load-failed": "Kunde inte läsa in kartan!",
+ "maps-markers": "Markörer",
+ "maps-copycoords-prompt": "Ctrl-C, Enter",
+ "maps-searchmarkers-text": "Filtrera markörer",
+ "maps-others": "andra",
+ "maps-kml-parsing-failed": "Misslyckades med att analysera en eller flera KML-filer, oftast på grund av hämtningsfel eller felaktigt XML.",
+ "maps-ns-layer": "Lager",
+ "maps-ns-layer-talk": "Lagerdiskussion",
+ "maps-layer-property": "Egenskap",
+ "maps-layer-value": "Värde",
+ "maps-layer-errors": "Fel",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Ogiltig definition|Ogiltiga definitioner}}",
+ "maps-layerdef-invalid-fatal": "Katastrofalt ogiltig definition",
+ "maps-layerdef-wrong-namespace": "Lagerdefinitioner är enbart giltiga i namnrymden \"$1\"",
+ "maps-layerdef-equal-layer-name": "Lagernamn måste vara unika inom samma lagersida. \"$1\" används redan av ett annat lager.",
+ "maps-layerpage-usage": "Sidor med kartor som använder lager \"$1\"",
+ "maps-layerpage-nousage": "Inga sidor använder för närvarande detta lager",
+ "maps-error-invalid-layertype": "Det finns inga lager av typen \"$1\". Endast {{PLURAL:$3|denna typ|denna typer}} stöds: $2",
+ "maps-error-no-layertype": "Du måste ange lagertypen. {{PLURAL:$2|Endast denna typ|Dessa typer}} stöds: $1",
+ "validation-error-invalid-layer": "Parameter \"$1\" måste vara ett giltig lager.",
+ "validation-error-invalid-layers": "Parameter \"$1\" måste vara ett eller flera giltiga lager.",
+ "validation-error-no-non-numeric": "Parameter \"$1\" måste vara en icke-numerisk sträng.",
+ "validation-error-no-non-numerics": "Parameter \"$1\" måste vara en eller fler icke-numeriska strängar.",
+ "maps-layer-of-type": "Lager av typen \"$1\"",
+ "maps-layer-of-type-and-name": "Lager \"$2\" av typen \"$1\"",
+ "maps-layer-type-supported-by": "Denna lagertyp kan endast användas med {{PLURAL:$2|kartläggningstjänsten $1|dessa kartläggningstjänster: $1}}.",
+ "maps-coordinates-description": "Tolk-hook för att formatera koordinater, från och till något av de format som stöds.",
+ "maps-displaymap-description": "Visa geografiska kartor utan några wiki-definierade markörer på dem.",
+ "maps-distance-description": "Konvertera ett avstånd mätt i en giltig enhet till en annan enhet.",
+ "maps-finddestination-description": "Hitta ett mål utifrån en given startpunkt (på något giltigt format), en inledande bäring och ett avstånd.",
+ "maps-geocode-description": "Aktiverar geokodning av adresser, med andra ord, konvertering av mänskligt läsbara platser till en uppsättning koordinater. det finns stöd för flera geokodningstjänster, som inte bör förväxlas med karttjänster.",
+ "maps-geodistance-description": "Beräkna det geografiska avståndet mellan två punkter, från och till något av de stödda formaten.",
+ "maps-mapsdoc-description": "Visa en tabell med parametrarna för en angiven karttjänst tillsammans med deras standardvärden och beskrivningar.",
+ "maps-layerdefinition-description": "Beskriver ett anpassat lager som kan visas med andra Kartfunktioner.",
+ "maps-mapsdoc-par-service": "Kartläggningstjänsten för att visa parameterdokumentation.",
+ "maps-mapsdoc-par-language": "Språket som du vill visa dokumentationen i. Om det finns någon sådan översättning kommer engelska att användas istället.",
+ "maps-coordinates-par-location": "Koordinaterna du vill formatera.",
+ "maps-coordinates-par-format": "Målformatet för koordinaterna.",
+ "maps-coordinates-par-directional": "Anger om koordinaterna ska matas ut riktat eller inte.",
+ "maps-par-scrollwheelzoom": "Indikerar om musrullning borde vara aktiverat eller inte.",
+ "maps-distance-par-distance": "Avståndet att konvertera till är lika med en bestämd enhet.",
+ "maps-distance-par-decimals": "Det maximala antalet decimalsiffror som ska användas i det resulterande värdet.",
+ "maps-distance-par-unit": "Enheten för utmatning av avståndet.",
+ "maps-finddestination-par-location": "Startplats",
+ "maps-finddestination-par-bearing": "Inledande bäring.",
+ "maps-finddestination-par-distance": "Reseavståndet.",
+ "maps-finddestination-par-format": "Formatet för utmatning av destinationen.",
+ "maps-finddestination-par-directional": "Anger om formatet på destinationen ska vara riktat eller inte.",
+ "maps-geocode-par-location": "Adressen som du vill geokoda.",
+ "maps-geocode-par-format": "Formatet för de resulterande koordinaterna.",
+ "maps-geocode-par-directional": "Anger om koordinaterna ska matas ut riktat eller inte.",
+ "maps-geodistance-par-location1": "Den första punkten i setet för att beräkna avståndet mellan.",
+ "maps-geodistance-par-location2": "Den andra punkten i setet för att beräkna avståndet mellan.",
+ "maps-geodistance-par-unit": "Enheten för utmatning av avståndet.",
+ "maps-geodistance-par-decimals": "Det maximala antalet decimalsiffror som ska användas i det resulterande värdet.",
+ "maps-displaymap-par-mappingservice": "Tillåter att karttjänsten som kommer att användas för att skapa kartan anges.",
+ "maps-displaymap-par-coordinates": "En eller fler platser att markera på kartan. De kommer att anges med en markör.",
+ "maps-displaymap-par-visitedicon": "Filnamnet för en bild som ska användas för markörikoner efter att de ursprungliga markörerna har klickats",
+ "maps-displaymap-par-zoom": "Tillåter inställning av zoomnivån för kartan.\nNär det inte tillhandahålls och det finns flera markörer på kartan, används den bäst passande zoomnivån, inte det konfigurerbara standardvärdet.",
+ "maps-displaymap-par-centre": "Tillåter inställning av koordinaterna för kartans centrum för display_point(s).\nAccepterar både adresser och koordinater.\nNär den här egenskapen inte finns, kommer kartan att centrera sig på den tillhandahållna markören, eller mellan tillhandahållna markörer.",
+ "maps-displaymap-par-title": "Gör det möjligt att ange text som ska visas i popup-fönster för alla markörer som saknar en särskild titel.\nNär detta används tillsammans med en etikett kommer titeln att vara fet och understruken.",
+ "maps-displaymap-par-label": "Gör det möjligt att ange text som ska visas i popup-fönster för alla markörer som saknar en särskild etikett.",
+ "maps-displaymap-par-icon": "Tillåter inställning av ikonerna som används av markörerna.",
+ "maps-displaymap-par-circles": "Cirklar att visa",
+ "maps-displaymap-par-copycoords": "Visa en dialogruta när du klickar på en plats som dess koordinater kan kopieras från",
+ "maps-displaymap-par-lines": "Rader att visa",
+ "maps-displaymap-par-maxzoom": "Maximala zoomnivån",
+ "maps-displaymap-par-minzoom": "Minimala zoomnivån",
+ "maps-displaymap-par-polygons": "Polygoner att visa",
+ "maps-displaymap-par-rectangles": "Rektanglar att visa",
+ "maps-displaymap-par-static": "Gör kartan statisk",
+ "maps-displaymap-par-wmsoverlay": "Använd ett WMS-överdrag",
+ "maps-displaymap-par-geojson": "Webbadressen till en fil eller namnet på sidan som innehåller GeoJSON-data",
+ "maps-fullscreen-button": "Växla fullskärmsläge",
+ "maps-fullscreen-button-tooltip": "Visa kartan i helskärm eller som inbäddad.",
+ "validation-error-invalid-location": "Parameter $1 måste vara en giltig plats.",
+ "validation-error-invalid-locations": "Parameter $1 måste vara en eller flera giltiga platser.",
+ "validation-error-invalid-width": "Parameter $1 måste vara en giltig bredd.",
+ "validation-error-invalid-height": "Parameter $1 måste vara en giltig höjd.",
+ "validation-error-invalid-distance": "Parameter $1 måste vara ett giltigt avstånd.",
+ "validation-error-invalid-distances": "Parameter $1 måste vara en eller flera giltiga avstånd.",
+ "validation-error-invalid-image": "Parameter $1 måste vara en giltig bild.",
+ "validation-error-invalid-images": "Parameter $1 måste vara en eller flera giltiga bilder.",
+ "validation-error-invalid-goverlay": "Parameter $1 måste vara ett giltigt lager.",
+ "validation-error-invalid-goverlays": "Parameter $1 måste vara en eller flera giltiga lager.",
+ "maps-abb-north": "N",
+ "maps-abb-east": "Ö",
+ "maps-abb-south": "S",
+ "maps-abb-west": "V",
+ "maps-latitude": "Breddgrad:",
+ "maps-longitude": "Längdgrad:",
+ "maps-invalid-coordinates": "Värdet $1 identifierades inte som en giltig uppsättning koordinater.",
+ "maps_coordinates_missing": "Inga koordinater angivna för kartan.",
+ "maps_geocoding_failed": "Följande {{PLURAL:$2|adress|adresser}} kunde inte geokodas: $1.\nKartan kan inte visas.",
+ "maps_geocoding_failed_for": "Följande {{PLURAL:$2|adress|adresser}}kunde inte geokodas och {{PLURAL:$2|har|har}} uteslutits från kartan: $1",
+ "maps_unrecognized_coords": "Följande {{PLURAL:$2|koordinat|koordinater}} kändes inte igen: $1.",
+ "maps_unrecognized_coords_for": "Följande {{PLURAL:$2|koordinat|koordinater}} kändes inte igen och {{PLURAL:$2|har|har}} utelämnats från kartan:\n$1",
+ "maps_map_cannot_be_displayed": "Kartan kan inte visas.",
+ "maps-geocoder-not-available": "Geokodningsfunktionen av Maps är inte tillgänglig. Din plats kan inte geokodas.",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "Gör det möjligt att ändra standardzoomnivån för kartan.",
+ "maps-leaflet-par-layers": "Lagret som kommer att visas när kartan läser in.",
+ "maps-leaflet-par-overlaylayers": "Överläggslagret som kommer att visas när kartan läser in.",
+ "maps-leaflet-par-maxclusterradius": "Den maximala radien som ett kluster kommer att täcka från centrummarkören (i bildpunkter)",
+ "maps-leaflet-par-clusterspiderfy": "När du klickar på ett kluster på den lägsta zoomnivån sprider vi ut den så du kan se alla dess markörer.",
+ "maps_click_to_activate": "Klicka för att aktivera karta",
+ "maps_centred_on": "Karta centrerad på $1, $2.",
+ "maps-par-mappingservice": "Tillåter att karttjänsten som kommer att användas för att skapa kartan anges.",
+ "maps-par-resizable": "Gör att kartans storlek kan ändras genom att dra i dess nedre högra hörnet.",
+ "maps-par-searchmarkers": "Gör det möjligt att söka efter specifika markörer via ett fält som är inbäddat i kartan.",
+ "maps-par-zoom": "Zoomnivån för kartan. För kartor med markörer kommer som standard den mest inzoomade nivå som visar alla markörer att användas.",
+ "maps-par-width": "Tillåter att kartans bredd ställs in. Som standard kommer pixlar att antas som enhet, men du kan uttryckligen ange en av dessa enheter: px, ex, em, %.",
+ "maps-par-height": "Tillåter att kartans höjd ställs in. Som standard kommer pixlar att antas som enhet, men du kan uttryckligen ange en av dessa enheter: px, ex, em, %.",
+ "maps-par-centre": "Platsen där kartan ska vara centrerad",
+ "maps-par-enable-fullscreen": "Aktivera helskärmsknappen",
+ "maps-par-kml": "KML-filer att ladda upp på kartan.",
+ "maps-par-markercluster": "Gör det möjligt att sammanfoga flera närliggande markörer till en enda markör",
+ "maps-googlemaps3-incompatbrowser": "Din webbläsare är inte kompatibel med Google Maps v3.",
+ "maps-googlemaps3-par-imageoverlays": "Gör det möjligt att lägga till en bild att visas på den specifika platsen på kartan.",
+ "maps-googlemaps3-par-type": "Karttyp att visa initialt",
+ "maps-googlemaps3-par-types": "De karttyper som kommer att finnas tillgänglig via typ-reglaget.",
+ "maps-googlemaps3-par-layers": "Särskilda lager att ladda på kartan.",
+ "maps-googlemaps3-par-controls": "Kontroller att placera på kartan.",
+ "maps-googlemaps3-par-zoomstyle": "Stilen för zoomreglaget.",
+ "maps-googlemaps3-par-typestyle": "Stilen för typreglaget.",
+ "maps-googlemaps3-par-autoinfowindows": "Öppna automatiskt alla informationsfönster när sidan har lästs in.",
+ "maps-googlemaps3-par-gkml": "KML-filer, tillhandahållna av Google, att ladda på kartan.",
+ "maps-googlemaps3-par-kmlrezoom": "Zooma tillbaka till kartan efter att KML-lager har lästs in.",
+ "maps-googlemaps3-par-poi": "Visa platser av intresse.",
+ "maps-googlemaps3-par-clustergridsize": "Rutnätsstorleken för ett kluster i bildpunkter.",
+ "maps-par-clustermaxzoom": "Den maximala zoomnivån där kluster kan finnas.",
+ "maps-par-clusterzoomonclick": "Om standardbeteendet för att klicka på ett kluster är att zooma in på det.",
+ "maps-par-maxclusterradius": "Den maximala radien som ett kluster kommer att täcka.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Om centrum för varje kluster bör vara medelvärdet för alla markörer i klustret.",
+ "maps-googlemaps3-par-clusterminsize": "Det minimala antalet markörer i ett kluster innan markörerna döljs och ett sifferantal visas.",
+ "mapeditor": "Kartredigerare",
+ "specialpages-group-maps": "Kartor",
+ "mapeditor-parser-error": "Ett fel uppstod när metadata tolkades. Ignorerar data från användaren.",
+ "mapeditor-none-text": "Ingen",
+ "mapeditor-done-button": "Klar",
+ "mapeditor-remove-button": "Ta bort",
+ "mapeditor-import-button2": "Importera",
+ "mapeditor-export-button": "Exportera till wikikod",
+ "mapeditor-import-button": "Importera från wikikod",
+ "mapeditor-select-button": "Välj denna polygon",
+ "mapeditor-mapparam-button": "Redigera kartparametrar",
+ "mapeditor-clear-button": "Rensa karta",
+ "mapeditor-code-title": "Wikikod",
+ "mapeditor-import-title": "Importera wikikod",
+ "mapeditor-import-note": "Observera att tolken förväntar sig ett mycket strikt format på wiki-koden. Koden som anges här ska matcha kod som produceras av exportfunktionen.",
+ "mapeditor-form-title": "Redigera detaljer",
+ "mapeditor-link-title-switcher-popup-text": "Poppupp med text",
+ "mapeditor-link-title-switcher-link-text": "Länk",
+ "mapeditor-form-field-title": "Titel",
+ "mapeditor-form-field-text": "Text",
+ "mapeditor-form-field-link": "Länk",
+ "mapeditor-form-field-icon": "Ikon",
+ "mapeditor-form-field-group": "Grupp",
+ "mapeditor-form-field-inlinelabel": "Infogad etikett",
+ "mapeditor-form-field-strokecolor": "Linjefärg",
+ "mapeditor-form-field-strokeopacity": "Linjegenomskinlighet",
+ "mapeditor-form-field-strokeweight": "Linjebredd",
+ "mapeditor-form-field-fillcolor": "Fyllningsfärg",
+ "mapeditor-form-field-fillopcaity": "Fyllningsgenomskinlighet",
+ "mapeditor-form-field-showonhover": "Visa endast vid hovring",
+ "mapeditor-mapparam-title": "Redigera kartparametrar",
+ "mapeditor-mapparam-defoption": "-Välj parameter-",
+ "mapeditor-imageoverlay-button": "Lägg till bildöverdrag",
+ "mapeditor-form-field-image": "Bild",
+ "mapeditor-imageoverlay-title": "Bildöverdragsdetaljer",
+ "mapeditor-form-field-visitedicon": "Besökt ikon",
+ "semanticmaps-unrecognizeddistance": "Värdet $1 är inte ett giltigt avstånd.",
+ "semanticmaps-kml-link": "Visa KML-filen",
+ "semanticmaps-default-kml-pagelink": "Visa sida $1",
+ "semanticmaps-latitude": "Breddgrad: $1",
+ "semanticmaps-longitude": "Längdgrad: $1",
+ "semanticmaps-altitude": "Höjd över havet: $1",
+ "semanticmaps-forminput-locations": "Platser",
+ "semanticmaps-par-staticlocations": "En lista med platser som man kan placera på kartan tillsammans med efterfrågad data. Precis som för display_points, så kan du lägga till en titel, en beskrivning och en ikon för varje plats med hjälp av tilde \"~\" som avgränsare.",
+ "semanticmaps-par-showtitle": "Visa en titel i markörens informationsruta eller inte. Det är ofta lämpligt att inte använda denna funktion när en mall används för informationsrutans innehåll.",
+ "semanticmaps-par-hidenamespace": "Visa namnrymdens titel i markörens informationsruta.",
+ "semanticmaps-par-centre": "Kartans mitt. Om inte angiven så kommer kartan automatiskt att hitta markörernas mittpunkt.",
+ "semanticmaps-par-template": "En mall som ska användas för informationsrutorna.",
+ "semanticmaps-par-geocodecontrol": "Visa formulär för geokodning.",
+ "semanticmaps-par-activeicon": "Ikon som bör visas istället för standardmarkören när den aktiva sidan är samma som resultatet från förfrågan",
+ "semanticmaps-par-pagelabel": "När satt till \"yes\" (ja), kommer alla markörer att ha en \"inlineLabel\" med en länk till sidan som innehåller koordinaterna för den markören",
+ "semanticmaps-par-ajaxcoordproperty": "Namn på koordinatsegenskapen som kommer att användas för att bygga ajax-frågan.",
+ "semanticmaps-par-ajaxquery": "En andra fråga som skickas via ajax för att hämta ytterligare koordinater.",
+ "semanticmaps-par-userparam": "Ett värde som skickas till varje mall, om mallar används",
+ "semanticmaps-kml-text": "Texten som hör ihop med varje sida. Om det finns efterfrågade egenskaper så tar de överhand.",
+ "semanticmaps-kml-title": "Förvald titel för resultaten",
+ "semanticmaps-kml-linkabsolute": "Ska länkar vara absoluta (i motsats till relativa)",
+ "semanticmaps-kml-pagelinktext": "Texten som ska användas för länkar till sidan, där $1 kommer att bytas ut med sidtiteln",
+ "semanticmaps-shapes-improperformat": "Felaktig formatering av $1. Se dokumentationen för formatering",
+ "semanticmaps-shapes-missingshape": "Inga former hittade för $1. Se dokumentationen för tillgängliga former",
+ "validator-type-mapscircle": "Geografisk cirkel",
+ "validator-type-mapscircle-list": "Lista över cirklar",
+ "validator-type-mapsimageoverlay": "Bildöverlägg",
+ "validator-type-mapsimageoverlay-list": "Lista över bildöverlägg",
+ "validator-type-mapsline": "Geografisk linje",
+ "validator-type-mapsline-list": "Lista över linjer",
+ "validator-type-mapslocation": "Geografisk plats",
+ "validator-type-mapslocation-list": "Lista över platser",
+ "validator-type-mapsrectangle": "Geografisk rektangel",
+ "validator-type-mapsrectangle-list": "Lista över rektanglar",
+ "validator-type-mapspolygon": "Geografisk polygon",
+ "validator-type-mapspolygon-list": "Lista över geografiska polygoner",
+ "validator-type-wmsoverlay": "Webbmappstjänst-överlägg",
+ "validator-type-jsonfile": "text"
+}
diff --git a/www/wiki/extensions/Maps/i18n/sw.json b/www/wiki/extensions/Maps/i18n/sw.json
new file mode 100644
index 00000000..84fbcfa8
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/sw.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kipala"
+ ]
+ },
+ "maps-googlemaps3-par-imageoverlays": "Inaruhusu kuongeza picha mahali panapoonyeshwa"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ta.json b/www/wiki/extensions/Maps/i18n/ta.json
new file mode 100644
index 00000000..789c1307
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ta.json
@@ -0,0 +1,63 @@
+{
+ "@metadata": {
+ "authors": [
+ "Karthi.dr",
+ "Shanmugamp7",
+ "மதனாஹரன்"
+ ]
+ },
+ "maps_map": "வரைபடம்",
+ "maps-loading-map": "வரைபடத்தை ஏற்றுகிறது....",
+ "maps-load-failed": "வரைபடத்தை ஏற்ற இயலவில்லை!",
+ "maps-copycoords-prompt": "கட்டுப்பாட்டு விசை+C, உள்வழி விசை",
+ "maps-others": "ஏனையவை",
+ "maps-layer-property": "உடமை",
+ "maps-layer-value": "மதிப்பு",
+ "maps-layer-errors": "பிழைகள்",
+ "maps-finddestination-par-distance": "பயணிக்க வேண்டிய தூரம்.",
+ "maps-displaymap-par-maxzoom": "அதிகபட்ச பெரிதாக்குதல் அளவு",
+ "maps-displaymap-par-minzoom": "குறைந்தபட்ச பெரிதாக்குதல் அளவு",
+ "validation-error-invalid-location": "அளவுரு $1 ஒரு செல்லத்தக்க இடமாக இருக்க வேண்டும்.",
+ "validation-error-invalid-locations": "அளவுரு $1 ஒன்று அல்லது அதற்கு மேற்பட்ட செல்லத்தக்க இடங்களாக இருக்க வேண்டும்.",
+ "validation-error-invalid-width": "அளவுரு $1 ஒரு செல்லத்தக்க அகலமாக இருக்க வேண்டும்.",
+ "validation-error-invalid-height": "அளவுரு $1 ஒரு செல்லத்தக்க உயரமாக இருக்க வேண்டும்.",
+ "validation-error-invalid-distance": "அளவுரு $1 ஒரு செல்லத்தக்க தூரமாக இருக்க வேண்டும்.",
+ "validation-error-invalid-distances": "அளவுரு $1 ஒன்று அல்லது அதற்கு மேற்பட்ட செல்லத்தக்க தூரங்களாக இருக்க வேண்டும்.",
+ "validation-error-invalid-image": "அளவுரு $1 ஒரு செல்லத்தக்க படிமமாக இருக்க வேண்டும்.",
+ "validation-error-invalid-images": "அளவுரு $1 ஒன்று அல்லது அதற்கு மேற்பட்ட படிமங்களாக இருக்க வேண்டும்.",
+ "maps-abb-north": "வ",
+ "maps-abb-east": "கி",
+ "maps-abb-south": "தெ",
+ "maps-abb-west": "மே",
+ "maps-latitude": "அட்சரேகை:",
+ "maps-longitude": "தீர்க்க ரேகை:",
+ "maps_map_cannot_be_displayed": "வரைபடத்தைக் காட்ட இயலவில்லை.",
+ "mapeditor": "வரைபட தொகுப்பாளர்",
+ "specialpages-group-maps": "வரைபடங்கள்",
+ "mapeditor-parser-error": "மேல்நிலைத் தரவைப் பாகுபடுத்தலில் பிழை ஏற்பட்டுள்ளது. பயனர் உள்ளீடு புறக்கணிக்கப்படுகிறது.",
+ "mapeditor-none-text": "எதுவுமில்லை",
+ "mapeditor-done-button": "முடிந்தது",
+ "mapeditor-remove-button": "நீக்குக",
+ "mapeditor-import-button2": "இறக்குமதி",
+ "mapeditor-export-button": "விக்கி குறியீட்டிற்கு ஏற்றுமதி செய்",
+ "mapeditor-import-button": "விக்கி குறியீட்டிலிருந்து இறக்குமதி செய்",
+ "mapeditor-mapparam-button": "வரைபட அளவுருக்களை தொகுக்கவும்",
+ "mapeditor-clear-button": "வரைபடத்தை வெறுமையாக்கு",
+ "mapeditor-code-title": "விக்கி குறியீடு",
+ "mapeditor-import-title": "விக்கி குறியீடு இறக்குமதி",
+ "mapeditor-import-note": "பாகுபடுத்தி ( parser) மிகவும் சரியான விக்கி குறியீடு வடிவமைப்பை எதிர்பார்க்கும் என்பதை குறித்துக் கொள்ளவும். இங்கு உள்ளிடப்பட்ட குறியீடு ஏற்றுமதி செயல்பாடு மூலம் வெளியிடப்பட்ட குறியீட்டுடன் ஒத்துப்போக வேண்டும்.",
+ "mapeditor-form-title": "தொகுப்பு விவரங்கள்",
+ "mapeditor-link-title-switcher-popup-text": "உரையுடன் உலாவல் சட்டம்",
+ "mapeditor-link-title-switcher-link-text": "இணைப்பு",
+ "mapeditor-form-field-title": "தலைப்பு",
+ "mapeditor-form-field-text": "உரை",
+ "mapeditor-form-field-link": "இணைப்பு",
+ "mapeditor-form-field-icon": "படவுரு",
+ "mapeditor-form-field-group": "குழு",
+ "mapeditor-form-field-image": "படம்",
+ "semanticmaps-default-kml-pagelink": "பக்கம் $1 ஐ காண்க",
+ "semanticmaps-latitude": "அட்சரேகை: $1",
+ "semanticmaps-longitude": "தீர்க்கரேகை: $1",
+ "semanticmaps-altitude": "குத்துயரம்: $1",
+ "semanticmaps-forminput-locations": "இடங்கள்"
+}
diff --git a/www/wiki/extensions/Maps/i18n/te.json b/www/wiki/extensions/Maps/i18n/te.json
new file mode 100644
index 00000000..d0ceb85d
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/te.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Veeven"
+ ]
+ },
+ "maps_map": "పటం",
+ "maps-others": "ఇతరాలు",
+ "maps-layer-property": "లక్షణం",
+ "maps-layer-value": "విలువ",
+ "maps-layer-errors": "పొరపాట్లు",
+ "maps-abb-north": "ఉ",
+ "maps-abb-east": "తూ",
+ "maps-abb-south": "ద",
+ "maps-abb-west": "ప",
+ "maps-latitude": "అక్షాంశం:",
+ "maps-longitude": "రేఖాంశం:",
+ "specialpages-group-maps": "పటములు",
+ "mapeditor-none-text": "ఏమీలేదు",
+ "mapeditor-link-title-switcher-link-text": "లంకె",
+ "mapeditor-form-field-title": "శీర్షిక",
+ "mapeditor-form-field-text": "పాఠ్యం",
+ "mapeditor-form-field-link": "లంకె",
+ "mapeditor-form-field-icon": "ప్రతీకం"
+}
diff --git a/www/wiki/extensions/Maps/i18n/th.json b/www/wiki/extensions/Maps/i18n/th.json
new file mode 100644
index 00000000..046e9bb0
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/th.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Woraponboonkerd"
+ ]
+ },
+ "maps-desc": "ให้ความสามารถในการแสดงพิกัดในแผนที่ และที่อยู่ที่เป็นรหัสทางภูมิศาสตร์([http://mapping.referata.com/wiki/Maps_examples demo]).\n<br />บริการแผนที่ที่มีอยู่: $1",
+ "maps_coordinates_missing": "ไม่ได้กำหนดพิกัดของแผนที่มาให้"
+}
diff --git a/www/wiki/extensions/Maps/i18n/tl.json b/www/wiki/extensions/Maps/i18n/tl.json
new file mode 100644
index 00000000..c08811e0
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/tl.json
@@ -0,0 +1,158 @@
+{
+ "@metadata": {
+ "authors": [
+ "AnakngAraw",
+ "Jojit fb"
+ ]
+ },
+ "maps-desc": "Nagpapagana ng pagbabaon ng gumagalaw na mga mapa papaloob sa mga pahina ng wiki, pagkokodigong pangheograpiya ng mga tirahan at ibang mga gawaing pangheograpiya. ([http://mapping.referata.com/wiki/Examples mga pagpapatunghay])\n\nkakayahang ipakita ang dato ng tugmaang-pampook sa loob ng mga mapa, at mga triahan ([http://mapping.referata.com/wiki/Maps_examples mga pagpapatunghay])",
+ "right-geocode": "Kodigong pangheograpiya",
+ "maps_map": "Mapa",
+ "maps-loading-map": "Ikinakarga ang mapa...",
+ "maps-load-failed": "Hindi maikarga ang mapa!",
+ "maps-markers": "Mga palatandaan",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Mga pangmarka ng pansala",
+ "maps-others": "iba pa",
+ "maps-ns-layer": "Patong",
+ "maps-ns-layer-talk": "Usapan sa patong",
+ "maps-layer-property": "Ari-arian",
+ "maps-layer-value": "Halaga",
+ "maps-layer-errors": "Mga kamalian",
+ "maps-error-invalid-layertype": "Walang mga patong ng uring \"$1\". Tanging {{PLURAL:$3|ganitong uri|ganitong mga uri}} lamang ang tinatangkilik: $2",
+ "maps-error-no-layertype": "Kailangan mong tukuyin ang uri ng patong. {{PLURAL:$2|Ganitong uri lamang ang|Ganitong mga uri ang}} tinatangkilik: $1",
+ "validation-error-invalid-layer": "Ang parametrong $1 ay dapat na isang tanggap na patong.",
+ "validation-error-invalid-layers": "Ang parametrong $1 ay dapat na isa o mahigit pang katanggap-tanggap na mga patong.",
+ "maps-layer-of-type": "Patong ng uring $1",
+ "maps-layer-type-supported-by": "Ang ganitong uri ng patong ay {{PLURAL:$2|magagamit lamang sa $1 na palingkuran ng pagmamapa|magagamit lamang sa ganitong mga palingkuran ng pagmamapa: $1}}.",
+ "maps-coordinates-description": "Kawint ng banghay upang maianyo ang mga tugmaang-pampook, magmula at papunta sa anuman sa tinatangkilik na mga anyo.",
+ "maps-displaymap-description": "Ipakita ang mga mapang pangheograpiya na walang anumang tinukoy na pangwiking mga pananda sa ibabaw nila.",
+ "maps-distance-description": "Palitan ang isang kalayuan na ginagamit ang isang partikular na sinusuportahang yunit papunta sa katumbas nito na ginagamit ang isa pang yunit.",
+ "maps-finddestination-description": "Maghanap ng isang patutunguhan na binigyan ng tuldok ng pagsisimula (na maaaring nasa loob ng anuman sa tinatangkilik na mga anyo), isang paunang kapupuntahan at isang layo.",
+ "maps-geocode-description": "Nagpapagana ng pagsasakodigo na pangheograpiya ng mga tirahan, na sa ibang pananalita ay ang pagpapaglit ng mga kinalalagyan na mababasa ng tao upang maging mga pangkat ng mga tugmaang pampook. Mayroong suporta para sa ilang mga paglilingkod na pangkodigo ng heograpiya, na hindi dapat ikalito sa mga paglilingkod ng pagmamapa.",
+ "maps-geodistance-description": "Tuusin ang pangheograpiyang layo sa pagitan ng dalawang mga tuldok, magmula at papunta sa anumang tinatangkilik na mga anyo.",
+ "maps-mapsdoc-description": "Magpakita ng isang talahanayan na mayroong mga parametro para sa isang tinukoy na palingkuran ng pagmamapa na kasama ang kanilang likas na nakatakdang mga halaga at mga paglalarawan.",
+ "maps-mapsdoc-par-service": "Ang palingkuran ng pagmamapa na pagpapakitaan ng kasulatan ng parametro.",
+ "maps-mapsdoc-par-language": "Ang wikang pagpapakitaan ng kasulatan. Kung walang ganiyang salinwikang makukuha, Ingles sa halip niyan ang gagamitin.",
+ "maps-coordinates-par-location": "Ang mga tugmaang-pampook na nais mong iayos ang anyo.",
+ "maps-coordinates-par-format": "Ang pinupukol na anyo para sa mga tugmaang-pampook.",
+ "maps-coordinates-par-directional": "Nagpapahiwatig kung ang mga tugmaang-pampook ay dapat na ilabas bilang pangpatutunguhan o hindi.",
+ "maps-distance-par-distance": "Ang layo na gagawing katumbas nito na may tinukoy na yunit.",
+ "maps-distance-par-decimals": "Ang pinakamataas na bilang ng kakarampot na mga tambilang na gagamitin sa kalalabasang halaga.",
+ "maps-distance-par-unit": "Ang yunit na kalalabasan ng layo.",
+ "maps-finddestination-par-location": "Ang paunang kinalalagyan.",
+ "maps-finddestination-par-bearing": "Ang paunang patutunguhan.",
+ "maps-finddestination-par-distance": "Ang layo ng lalakbayin.",
+ "maps-finddestination-par-format": "Ang anyo kung paano ilalabas ang patutunguhan.",
+ "maps-finddestination-par-directional": "Nagpapahiwatig kung ang anyo ng patutunguhan ay dapat na maka kapupuntahan o hindi.",
+ "maps-geocode-par-location": "Ang tirahan na nais mong ikodigong pangheograpiya.",
+ "maps-geocode-par-format": "Ang anyo para sa kinalalabasang mga tugmaang pampook.",
+ "maps-geocode-par-directional": "Nagpapahiwatig kung ang mga tugmaang-pampook ay dapat na ilabas bilang pangpatutunguhan o hindi.",
+ "maps-geodistance-par-location1": "Ang unang tuldok sa loob ng isang pangkat upang tuusin ang layo sa pagitan.",
+ "maps-geodistance-par-location2": "Ang pangalawang tuldok sa loob ng isang pangkat upang tuusin ang layo sa pagitan.",
+ "maps-geodistance-par-unit": "Ang yunit na kinapapalooban ng kinalalabasan ng layo.",
+ "maps-geodistance-par-decimals": "Ang pinakamataas na bilang ng kakarampot na mga tambilang na gagamitin sa kalalabasang halaga.",
+ "maps-displaymap-par-mappingservice": "Nagpapahintulot na maitakda ang palingkuran ng pagmamapa na gagamitin upang likhain ang mapa.",
+ "maps-displaymap-par-coordinates": "Ang kinalalagyan na paunang pagpapagitnaan ng mapa.",
+ "maps-displaymap-par-zoom": "Nagpapahintulot sa pagtatakda ng antas ng paglapit ng mapa.\nKapag hindi ibinigay at mayroong maramihang mga pananda sa ibabaw ng mapa, kukunin ang pinakaangkop na paglapit, hindi ang maiaayos na likas na katakdaan.",
+ "maps-displaymap-par-centre": "Nagbibigay-daan sa pagtatakda ng mga tugmaang pampook ng gitna ng mapa para sa (mga) tuldok_na_ipapakita.\nTumatanggap kapwa ng mga tirahan o mga tugmaang pampook.\nKapag hindi ibinigay ang pag-aaring ito, igigitna ng mapa ang kanyang sarili sa ibinigay na pangmarka, o sa gitna ng ibinigay na mga pananda.",
+ "maps-displaymap-par-title": "Nagpapahintulot sa pagtatakda ng teksto na ipapakita sa loob ng mga pagsulpot ng lahat ng mga pangmarka na walang tiyak na pamagat.\nKapag ginamit na kasama ng katatakan, ang pamagat ay magiging makapal at mayroong salungguhit.",
+ "maps-displaymap-par-label": "Nagpapahintulot sa pagtatakda ng teksto na ipapakita sa loob ng mga pagsulpot ng lahat ng mga pangmarka na walang tiyak na katatakan.",
+ "maps-displaymap-par-icon": "Nagpapahintulot sa pagtatakda ng ginagamit na kinatawang larawang para sa lahat ng mga pananda.",
+ "validation-error-invalid-location": "Ang parametrong $1 ay dapat na isang tanggap na lokasyon.",
+ "validation-error-invalid-locations": "Ang parametrong $1 ay dapat na isa o mahigit pang tanggap na mga lokasyon.",
+ "validation-error-invalid-width": "Ang parametrong $1 ay dapat na isang tanggap na lapad.",
+ "validation-error-invalid-height": "Ang parametrong $1 ay dapat na isang tanggap na taas.",
+ "validation-error-invalid-distance": "Ang parametrong $1 ay dapat na isang tanggap na layo.",
+ "validation-error-invalid-distances": "Ang parametrong $1 ay dapat na isa o mahigit pang tanggap na mga layo.",
+ "validation-error-invalid-image": "Ang parametrong $1 ay dapat na isang katanggap-tanggap na larawan.",
+ "validation-error-invalid-images": "Ang parametrong $1 ay dapat na isa o mahigit pang katanggap-tanggap na mga larawan.",
+ "validation-error-invalid-goverlay": "Ang parametrong $1 ay dapat na isang tanggap na patong.",
+ "validation-error-invalid-goverlays": "Ang parametrong $1 ay dapat na isa o mahigit pang katanggap-tanggap na mga patong.",
+ "maps-abb-north": "H",
+ "maps-abb-east": "S",
+ "maps-abb-south": "T",
+ "maps-abb-west": "K",
+ "maps-latitude": "Latitud:",
+ "maps-longitude": "Longhitud:",
+ "maps-invalid-coordinates": "Hindi kinilala ang halagang $1 bilang isang tanggap na pangkat ng mga tugmaang-pampook.",
+ "maps_coordinates_missing": "Walang mga tugmaang-pampook na ibinigay para sa mapa.",
+ "maps_geocoding_failed": "Hindi mageokodigo ang sumusunod na {{PLURAL:$2|tirahan|mga tirahan}}: $1.",
+ "maps_geocoding_failed_for": "Hindi mageokodigo ang sumusunod na {{PLURAL:$2|tirahan|mga tirahan}} at {{PLURAL:$2|tinanggal|mga tinanggal}} na mula sa mapa:\n$1",
+ "maps_unrecognized_coords": "Hindi kinilala ang sumusunod na {{PLURAL:$2|tugmaan|mga tugmaan}}: $1.",
+ "maps_unrecognized_coords_for": "Hindi nakilala ang sumusunod na {{PLURAL:$2|tugmaang pampook|mga tugmaang pampook}} at {{PLURAL:$2|inalis|mga inalis}} na mula sa mapa:\n$1",
+ "maps_map_cannot_be_displayed": "Hindi maipapakita ang mapa.",
+ "maps-geocoder-not-available": "Wala ang katangiang-kasangkapang pang-geokodigo ng Mga Mapa. Hindi mageokodigo ang lokasyon mo.",
+ "maps_googlemaps3": "Google Maps v3",
+ "maps_click_to_activate": "Pindutin upang mabuhay ang mapa",
+ "maps_centred_on": "Nakagitna ang mapa sa $1, $2.",
+ "maps-par-resizable": "Nakagagawang mababago ang sukat ng mapa sa pamamagitan ng pagkaladkad doon sa pang-ibabang kanang sulok nito.",
+ "maps-par-zoom": "Ang antas ng paglapit para sa mapa. Para sa mga mapang mayroong mga pangmarka, ito ay likas na nakatakda sa pinaka malapit na antas ng pagkakatutok na nagpapakita pa rin ng lahat ng mga pangmarka.",
+ "maps-par-width": "Nagpapahintulot ng pagtatakda ng lapad ng mapa. Ayon sa likas na pagkakatakda, ang mga piksel ay ipapalagay bilang yunit, subalit maaari mong maliwanag na tukuyin ang isa sa mga yunit na ito: px, ex, em, %.",
+ "maps-par-height": "Nagpapahintulot ng pagtatakda ng taas ng mapa. Ayon sa likas na pagkakatakda, ang mga piksel ay ipapalagay bilang yunit, subalit maaari mong maliwanag na tukuyin ang isa sa mga yunit na ito: px, ex, em, %.",
+ "maps-par-kml": "Mga talaksan ng Wikang Pangmarka ng Butas ng Susian (Keyhole Markup Language, KML) na ikakarga sa ibabaw ng mapa.",
+ "maps-googlemaps3-incompatbrowser": "Ang pantingin-tingin mo ay hindi katambal ng Mga Mapa ng Google v3.",
+ "maps-googlemaps3-par-type": "Ang uri ng mapa na unang ipapakita.",
+ "maps-googlemaps3-par-types": "Ang mga uri ng mapa na magiging makukuha sa pamamagitan ng pantaban ng uri.",
+ "maps-googlemaps3-par-layers": "Natatanging mga patong na ikakarga sa ibabaw ng mapa.",
+ "maps-googlemaps3-par-controls": "Ang mga pantaban na ilalagay sa ibabaw ng mapa.",
+ "maps-googlemaps3-par-zoomstyle": "Ang estilo ng pantaban ng paglapit.",
+ "maps-googlemaps3-par-typestyle": "Ang estilo ng pantaban ng uri.",
+ "maps-googlemaps3-par-autoinfowindows": "Kusang buksan ang lahat ng mga dungawan ng kabatiran pagkaraang maikarga ang pahina.",
+ "maps-googlemaps3-par-gkml": "Mga talaksan ng Wikang Pangmarka ng Butas ng Susian (Keyhole Markup Language, KML) na pinasisinayahan ng Google upang ikarga sa ibabaw ng mapa.",
+ "maps-googlemaps3-par-kmlrezoom": "Muling ilapit ang mapa pagkaraang maikarga na ang mga patong ng Wika ng Pangmarka ng Butas ng Susian (Keyhole Markup Language, KML).",
+ "maps-googlemaps3-par-poi": "Ipakita ang mga tuldok na mapagtutuunan ng pansin.",
+ "mapeditor": "Patnugot ng mapa",
+ "specialpages-group-maps": "Mga mapa",
+ "mapeditor-parser-error": "Naganap ang isang kamalian noong binabanghay ang metadato. Hindi papansinin ang ipinasok ng tagagamit.",
+ "mapeditor-none-text": "Wala",
+ "mapeditor-done-button": "Nagawa na",
+ "mapeditor-remove-button": "Tanggalin",
+ "mapeditor-import-button2": "Angkatin",
+ "mapeditor-export-button": "Iluwas na papunta sa kodigo ng wiki",
+ "mapeditor-import-button": "Angkatin magmula sa kodigo ng wiki",
+ "mapeditor-mapparam-button": "Baguhin ang mga parametro ng mapa",
+ "mapeditor-clear-button": "Hawiin ang mapa",
+ "mapeditor-code-title": "Kodigo ng wiki",
+ "mapeditor-import-title": "Angkatin ang kodigo ng wiki",
+ "mapeditor-import-note": "Paki tandaan na ang pambanghay ay umaasa ng isang napaka higpit na kaanyuan sa kodigo ng wiki. Ang ipinasok na kodigo rito ay dapat na tumugma sa kodigong inilibas ng panunungkulan ng pagluluwas.",
+ "mapeditor-form-title": "Baguhin ang mga detalye",
+ "mapeditor-link-title-switcher-popup-text": "Pagsulpot na mayroong teksto",
+ "mapeditor-link-title-switcher-link-text": "Link",
+ "mapeditor-form-field-title": "Pamagat",
+ "mapeditor-form-field-text": "Teksto",
+ "mapeditor-form-field-link": "Link",
+ "mapeditor-form-field-icon": "Kinatawang larawan",
+ "mapeditor-form-field-group": "Pangkat",
+ "mapeditor-form-field-inlinelabel": "Katatakang nasa guhit",
+ "mapeditor-form-field-strokecolor": "Kulay ng hagod",
+ "mapeditor-form-field-strokeopacity": "Kalabuan ng hagod",
+ "mapeditor-form-field-strokeweight": "Bigat ng hagod",
+ "mapeditor-form-field-fillcolor": "Kulay ng buhos",
+ "mapeditor-form-field-fillopcaity": "Kalabuan ng buhos",
+ "mapeditor-form-field-showonhover": "Ipakita lamang sa pag-aligid",
+ "mapeditor-mapparam-title": "Baguhin ang mga parametro ng mapa",
+ "mapeditor-mapparam-defoption": "-Piliin ang parametro-",
+ "mapeditor-imageoverlay-button": "Idagdag ang kalupkop ng larawan",
+ "mapeditor-form-field-image": "Larawan",
+ "mapeditor-imageoverlay-title": "Mga detalye ng kalupkop ng larawan",
+ "mapeditor-form-field-visitedicon": "Kinatawang larawan ng pagka nadalaw",
+ "semanticmaps-unrecognizeddistance": "Hindi isang tanggap na layo ang halagang $1.",
+ "semanticmaps-kml-link": "Tingnan ang talaksang KML",
+ "semanticmaps-kml": "KML",
+ "semanticmaps-default-kml-pagelink": "Tingnan ang pahinang $1",
+ "semanticmaps-latitude": "Latitud: $1",
+ "semanticmaps-longitude": "Longhitud: $1",
+ "semanticmaps-altitude": "Altitud: $1",
+ "semanticmaps-forminput-locations": "Mga kinalalagyan",
+ "semanticmaps-par-staticlocations": "Isang listahan ng mga lokasyon na idaragdag sa mapa na kasama ng inusisang dato. Katulad ng sa tuldok_ng_pagpapakita, makapagdaragdag ka ng isang pamagat, paglalarawan at kinatawang larawan sa bawat lokasyon na ginagamit ang tilde \"~\" bilang panghiwalay.",
+ "semanticmaps-par-showtitle": "Magpapakita o hindi magpapakita ng isang pamagat sa loob ng pangmarkang bintana ng impormasyon. Ang hindi pagpapagana nito ay kadasalang mas kapakipakinabang kapag gumagamit ng isang suleras upang maiayos ang nilalaman ng bintana ng kabatiran.",
+ "semanticmaps-par-hidenamespace": "Ipakita o huwag ipakita ang pamagat ng puwang na pampangalan sa loob ng pangmarkang bintana ng impormasyon.",
+ "semanticmaps-par-centre": "Ang gitna ng mapa. Kapag hindi ibinigay, kusang pipiliin ng mapa ang pinakamabuting gitna na pagpapakitaan ng lahat ng mga pangmarka",
+ "semanticmaps-par-template": "Isang suleras na gagamit upang iayos ang mga nilalaman ng bintana ng kabatiran.",
+ "semanticmaps-par-geocodecontrol": "Ipakita ang pantaban ng pagkokodigong pangheograpiya.",
+ "semanticmaps-kml-text": "Umuugnay ang teksto sa bawat isang pahina. Pinangingibabawan ng karagdagang sinisiyasat na mga katangiang angkin kung mayroon.",
+ "semanticmaps-kml-title": "Ang likas na nakatakdang pamagat para sa mga resulta",
+ "semanticmaps-kml-linkabsolute": "Kung ang mga kawing ay magiging lubos o hindi (iyong nauukol)",
+ "semanticmaps-kml-pagelinktext": "Ang tekstong gagamitin para sa mga kawing sa pahina, kung saan ang $1 ay mapapalitan ng pamagat ng pahina"
+}
diff --git a/www/wiki/extensions/Maps/i18n/tr.json b/www/wiki/extensions/Maps/i18n/tr.json
new file mode 100644
index 00000000..1548a801
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/tr.json
@@ -0,0 +1,84 @@
+{
+ "@metadata": {
+ "authors": [
+ "Emperyan",
+ "Joseph",
+ "Manco Capac",
+ "Meelo",
+ "Trncmvsr",
+ "Vito Genovese",
+ "McAang",
+ "Hbseren",
+ "Sadrettin",
+ "Incelemeelemani"
+ ]
+ },
+ "right-geocode": "Coğrafi kod",
+ "maps_map": "Harita",
+ "maps-loading-map": "Harita yükleniyor...",
+ "maps-load-failed": "Harita yüklenemiyor!",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-others": "diğerleri",
+ "maps-ns-layer": "Katman",
+ "maps-ns-layer-talk": "Katman tartışması",
+ "maps-layer-property": "Özellik",
+ "maps-layer-value": "Değer",
+ "maps-layer-errors": "Hatalar",
+ "maps-layerdef-invalid": "Hatalı tanımlama{{PLURAL:$1||lar}}",
+ "validation-error-invalid-location": "$1 parametresi geçerli bir konum olmalıdır.",
+ "validation-error-invalid-locations": "$1 parametresi geçerli bir (veya daha fazla) konum olmalıdır.",
+ "validation-error-invalid-width": "$1 parametresi geçerli bir genişlik olmalıdır.",
+ "validation-error-invalid-height": "$1 parametresi geçerli bir yükseklik olmalıdır.",
+ "validation-error-invalid-distance": "$1 parametresi geçerli bir mesafe değeri olmalıdır.",
+ "validation-error-invalid-distances": "$1 parametresi geçerli bir (veya daha fazla) mesafe değeri olmalıdır.",
+ "validation-error-invalid-image": "$1 parametresi geçerli bir resim olmalıdır.",
+ "validation-error-invalid-images": "$1 parametresi geçerli bir (veya daha fazla) resim olmalıdır.",
+ "maps-abb-north": "K",
+ "maps-abb-east": "D",
+ "maps-abb-south": "G",
+ "maps-abb-west": "B",
+ "maps-latitude": "Enlem:",
+ "maps-longitude": "Boylam:",
+ "maps-invalid-coordinates": "$1 değeri geçerli bir koordinat olarak algılanmadı.",
+ "maps_coordinates_missing": "Harita için koordinat girilmedi.",
+ "maps_geocoding_failed": "Takip eden {{PLURAL:$2|adres|adresler}} coğrafi olarak kodlanamadı: $1",
+ "maps_unrecognized_coords": "Şu {{PLURAL:$2|koordinat|koordinatlar}} tanınamadı: $1",
+ "maps_map_cannot_be_displayed": "Harita görüntülenemiyor.",
+ "maps-geocoder-not-available": "Haritanın coğrafi kodlama özelliği etkin değil. Konumunuz kodlanamıyor.",
+ "maps-leaflet-par-defzoom": "Haritanın varsayılan yakınlaştırma düzeyini ayarlamaya olanak sağlar.",
+ "maps_click_to_activate": "Haritayı etkinleştirmek için tıkla",
+ "maps_centred_on": "Harita, $1 $2 koordinatlarında ortalandı.",
+ "mapeditor": "Harita düzenleyici",
+ "specialpages-group-maps": "Haritalar",
+ "mapeditor-parser-error": "Metaveri ayrıştırılırken bir hata oluştu. Kullanıcı girişi yok sayılıyor.",
+ "mapeditor-none-text": "Hiçbiri",
+ "mapeditor-done-button": "Yapıldı",
+ "mapeditor-remove-button": "Kaldır",
+ "mapeditor-import-button2": "İçe aktar",
+ "mapeditor-export-button": "Viki kodu dışa aktar",
+ "mapeditor-import-button": "Viki kodunu içe aktar",
+ "mapeditor-select-button": "Bu çokgeni seçin",
+ "mapeditor-mapparam-button": "Harita parametrelerini düzenle",
+ "mapeditor-clear-button": "Haritayı temizle",
+ "mapeditor-code-title": "Viki kodu",
+ "mapeditor-import-title": "Viki kodunu içe aktar",
+ "mapeditor-form-title": "Ayrıntıları düzenle",
+ "mapeditor-form-field-title": "Başlık",
+ "mapeditor-form-field-text": "Metin",
+ "mapeditor-form-field-link": "Bağlantı",
+ "mapeditor-form-field-icon": "Simge",
+ "mapeditor-form-field-group": "Grup",
+ "mapeditor-form-field-inlinelabel": "Satır içi etiket",
+ "mapeditor-form-field-strokecolor": "Çizgi rengi",
+ "mapeditor-form-field-strokeopacity": "Çizgi saydamlığı",
+ "mapeditor-form-field-strokeweight": "Çizgi kalınlığı",
+ "mapeditor-form-field-fillcolor": "Dolgu rengi",
+ "mapeditor-form-field-fillopcaity": "Dolgu saydamlığı",
+ "mapeditor-form-field-showonhover": "Yalnızca vurgulu olanı göster",
+ "mapeditor-mapparam-title": "Harita parametrelerini düzenle",
+ "mapeditor-mapparam-defoption": "-Parametre seçiniz-",
+ "mapeditor-imageoverlay-button": "Resim katmanı ekle",
+ "mapeditor-form-field-image": "Resim",
+ "mapeditor-imageoverlay-title": "Resim katmanı ayrıntıları",
+ "semanticmaps-forminput-locations": "Konumlar"
+}
diff --git a/www/wiki/extensions/Maps/i18n/tzm.json b/www/wiki/extensions/Maps/i18n/tzm.json
new file mode 100644
index 00000000..164afe5a
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/tzm.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tifinaghes"
+ ]
+ },
+ "maps_map": "ⵜⴰⴽⵔⵟⴰ"
+}
diff --git a/www/wiki/extensions/Maps/i18n/uk.json b/www/wiki/extensions/Maps/i18n/uk.json
new file mode 100644
index 00000000..24dffd97
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/uk.json
@@ -0,0 +1,232 @@
+{
+ "@metadata": {
+ "authors": [
+ "Andriykopanytsia",
+ "Arturyatsko",
+ "Base",
+ "Ата",
+ "Тест",
+ "Olion",
+ "Piramidion",
+ "Alex Khimich",
+ "SteveR",
+ "Movses",
+ "Vlad5250"
+ ]
+ },
+ "maps-desc": "Дає змогу вбудовування динамічних карт у сторінки вікі, геокодування адрес та інші географічні операції",
+ "right-geocode": "геокод",
+ "action-geocode": "виконання геокодування у цій вікі",
+ "maps_map": "Мапа",
+ "maps-tracking-category": "Сторінки з картою, створеною розширенням карти",
+ "maps-loading-map": "Завантаження мапи...",
+ "maps-load-failed": "Неможливо завантажити карту!",
+ "maps-markers": "Відмітки",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "Фільтрувати маркери",
+ "maps-others": "інші",
+ "maps-kml-parsing-failed": "Помилка аналізу одного або декількох файлів kml, як правило, через отриманий несправний або некоректний XML.",
+ "maps-ns-layer": "Шар",
+ "maps-ns-layer-talk": "Обговорення шару",
+ "maps-layer-property": "Властивість",
+ "maps-layer-value": "Значення",
+ "maps-layer-errors": "Помилки",
+ "maps-layerdef-invalid": "{{PLURAL:$1|Недопустиме визначення|Недопустимі визначення}}",
+ "maps-layerdef-invalid-fatal": "Фатальне недопустиме визначення",
+ "maps-layerdef-wrong-namespace": "Визначення шарів дійсні тільки на сторінках простору імен «$1»",
+ "maps-layerdef-equal-layer-name": "Назви шарів мають бути унікальними у межах однієї сторінки шарів. \"$1\" вже використано іншим шаром.",
+ "maps-layerpage-usage": "Сторінки з картами, які використовують шар \"$1\"",
+ "maps-layerpage-nousage": "Немає сторінок з цим шаром на даний момент.",
+ "maps-error-invalid-layertype": "Не існують шари типу «$1». {{PLURAL:$3|1=Підтримується лише наступний тип|Підтримуються лише наступні типи}}: $2",
+ "maps-error-no-layertype": "Вам потрібно вказати тип шару. {{PLURAL:$2|1=Тільки такий тип|Такі типи}} підтримуються: $1",
+ "validation-error-invalid-layer": "Параметр $1 повинен бути коректним шаром.",
+ "validation-error-invalid-layers": "Параметри $1 повинні містити один чи більше коректних шарів.",
+ "validation-error-no-non-numeric": "Параметр \"$1\" повинен бути нечисловим рядком.",
+ "validation-error-no-non-numerics": "Параметр \"$1\" повинен бути одним або декількома нечисловими рядками.",
+ "maps-layer-of-type": "Шар типу $1",
+ "maps-layer-of-type-and-name": "Шар \"$2\" типу \"$1\"",
+ "maps-layer-type-supported-by": "Цей тип шару може бути використано {{PLURAL:$2|1=лише із картографічним сервісом|лише із наступними картографічними сервісами:}} $1",
+ "maps-coordinates-description": "Перехопиник парсеру для форматування координат із будь-якого у будьякий формат, що підтримується.",
+ "maps-displaymap-description": "Відображення географічних карт без жодних вікі-маркерів на них.",
+ "maps-distance-description": "Перетворення відстані, вираженої в одних одиницях, у їх еквівалент у інших одиницях.",
+ "maps-finddestination-description": "Знаходить місце призначення від заданої початкової точки (може бути у будь якому із підтримуваних форматів), початкового нарямку і відстані.",
+ "maps-geocode-description": "Дозволяє геокодування адрес, іншими словами перетворює зрозумілі для людини розташування у набори координат. Підтримується декілька сервісів геокодування, які не варто плутати з сервісами картографування.",
+ "maps-geodistance-description": "Розрахувати географічну відстань між двома точками, з будь-якого і у будь-який підтримуваний формат.",
+ "maps-mapsdoc-description": "Відобразити таблицю параметрів вказаного сервісу картографування з їх стандартними значеннями і описом.",
+ "maps-layerdefinition-description": "Описує користувацький шар, який може бути відображений з іншими функціями карти.",
+ "maps-mapsdoc-par-service": "Сервіс картографування, для якого відобразиться документація параметрів.",
+ "maps-mapsdoc-par-language": "Мова, якою показувати документацію. Якщо перекладу на таку немає, буде використано англійську.",
+ "maps-coordinates-par-location": "Координати, які Ви бажаєте відформатувати.",
+ "maps-coordinates-par-format": "Цільовий формат координат.",
+ "maps-coordinates-par-directional": "Вказує на те, чи координати повинні бути виведені безпосередньо, чи ні.",
+ "maps-par-scrollwheelzoom": "Вказує, чи увімкнена прокрутка мишею.",
+ "maps-distance-par-distance": "Відстань для перетворення на еквівалентну у вказаних одиницях.",
+ "maps-distance-par-decimals": "Максимальна кількість цифр дробової частини у значенні результату.",
+ "maps-distance-par-unit": "Одиниці, в яких буде наведено відстань.",
+ "maps-finddestination-par-location": "Початкове розташування.",
+ "maps-finddestination-par-bearing": "Початковий напрямок.",
+ "maps-finddestination-par-distance": "Протяжність подорожі.",
+ "maps-finddestination-par-format": "Формат, у якому буде виведено місце призначення.",
+ "maps-finddestination-par-directional": "Вказує, чи має формат місця призначення має бути спрямованим, чи ні.",
+ "maps-geocode-par-location": "Адреса, яку Ви хочете геокодувати.",
+ "maps-geocode-par-format": "Формат кінцевих координат.",
+ "maps-geocode-par-directional": "Вказує, якщо координати повинні бути виведені безпосередньо чи ні.",
+ "maps-geodistance-par-location1": "Перша точка у наборі для розрахунку відстані.",
+ "maps-geodistance-par-location2": "Друга точка у наборі для розрахунку відстані.",
+ "maps-geodistance-par-unit": "Одиниця вимірювання відстані.",
+ "maps-geodistance-par-decimals": "Найбільша кількість цифр у дробовій частині результату.",
+ "maps-displaymap-par-mappingservice": "Дозволяє налаштувати картографічний сервіс, який буде використовуватися для генерації карти.",
+ "maps-displaymap-par-coordinates": "Один або більше об'єктів для відображення на карті. Вони будуть помічені маркером.",
+ "maps-displaymap-par-visitedicon": "Назва файлу зображення, яке буде використовуватися для позначення значків після того, як самі маркери були натиснені",
+ "maps-displaymap-par-zoom": "Дозволяє встановити рівень масштабування карти.\nКоли не передбачено і кілька маркери присутні на карті, буде вибрано найкращий і найбільш відповідний масштаб, який не конфігурується за замовчуванням.",
+ "maps-displaymap-par-centre": "Дозволяє задати координати центру карти для display_point(s).\nПриймає обидві адреси і координати.\nКоли ця властивість не передбачена, карта центруватиметься сама на наданому маркері або між обома маркерами.",
+ "maps-displaymap-par-title": "Дозволяє задати текст, який буде відображатися у спливних вікнах всіх маркерів, які не мають конкретної назви.\nКоли використовується спільно з міткою, заголовок буде виділений напівжирним підкресленим шрифтом.",
+ "maps-displaymap-par-label": "Дозволяє задати текст, який буде відображатися у спливних вікнах всіх маркерів, які не мають певної мітки.",
+ "maps-displaymap-par-icon": "Дозволяє встановити значок, використовуваний для всіх маркерів.",
+ "maps-displaymap-par-circles": "Кола для відображення",
+ "maps-displaymap-par-copycoords": "Показувати при натисканні на точку мапи діалогове вікно, з якого можна скопіювати координати розташування",
+ "maps-displaymap-par-lines": "Лінії для відображення",
+ "maps-displaymap-par-maxzoom": "Максимальний рівень наближення",
+ "maps-displaymap-par-minzoom": "Мінімальний рівень наближення",
+ "maps-displaymap-par-polygons": "Багатокутники для показу",
+ "maps-displaymap-par-rectangles": "Прямокутники для показу",
+ "maps-displaymap-par-static": "Зробити карту статичною",
+ "maps-displaymap-par-wmsoverlay": "Використовувати накладення WMS",
+ "maps-displaymap-par-geojson": "URL файлу або назва сторінки, яка містить дані GeoJSON",
+ "maps-fullscreen-button": "Перемкнути повноекранний режим",
+ "maps-fullscreen-button-tooltip": "Переглянути мапу на весь екран або як вбудовану.",
+ "validation-error-invalid-location": "Параметр $1 повинен бути коректним місцем розташування.",
+ "validation-error-invalid-locations": "Параметр $1 повинен бути одним або більше коректних місць розташування.",
+ "validation-error-invalid-width": "Параметр $1 повинен бути коректною шириною.",
+ "validation-error-invalid-height": "Параметр $1 повинен бути коректною висотою.",
+ "validation-error-invalid-distance": "Параметр $1 повинен бути дійсною відстанню.",
+ "validation-error-invalid-distances": "Параметр $1 повинен бути однією або більше коректними відстаннями.",
+ "validation-error-invalid-image": "Параметр $1 повинен бути коректним зображенням.",
+ "validation-error-invalid-images": "Параметр $1 повинен бути одним або більше коректними зображеннями.",
+ "validation-error-invalid-goverlay": "Параметр $1 повинен бути коректним накладенням.",
+ "validation-error-invalid-goverlays": "Параметр $1 повинен бути одним або більше коректних накладень.",
+ "maps-abb-north": "Пн",
+ "maps-abb-east": "Сх",
+ "maps-abb-south": "Пд",
+ "maps-abb-west": "Зх",
+ "maps-latitude": "Широта:",
+ "maps-longitude": "Довгота:",
+ "maps-invalid-coordinates": "Значення $1 не є дійсним набором координат.",
+ "maps_coordinates_missing": "Не вказані координати для мапи.",
+ "maps_geocoding_failed": "{{PLURAL:$2|1=Ця адреса не може бути геокодована|Ці адреси не можуть бути геокодовані}}: $1.\nМапа не може бути відображена.",
+ "maps_geocoding_failed_for": "{{PLURAL:$2|1=Наступна адреса не може бути геокодована та була видалена|Наступні адреси не можуть бути геокодовані та були видалені}} з мапи:\n$1",
+ "maps_unrecognized_coords": "Ці {{PLURAL:$2|1=координати|координати}} не були розпізнані: $1.",
+ "maps_unrecognized_coords_for": "Наступні координати не були розпізнані, {{PLURAL:$2|1=вони|вони}} не показані на мапі:\n$1",
+ "maps_map_cannot_be_displayed": "Мапа не може бути відображена.",
+ "maps-geocoder-not-available": "Функція геокодування мап недоступна. Ваше місце розташування не може бути геокодоване.",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "Дозволяє задавати масштаб карти за замовчуванням.",
+ "maps-leaflet-par-layers": "Шари, які будуть доступні в селекторі шару. Перший шар буде показано під час завантаження карти.",
+ "maps-leaflet-par-overlaylayers": "Накладення шарів, що будуть показані, коли завантажиться мапа.",
+ "maps-leaflet-par-maxclusterradius": "Максимальний радіус, що буде покритий кластером від центрального маркера (в пікселях).",
+ "maps-leaflet-par-clusterspiderfy": "При клацанні на кластер при нижньому рівні масштабу ми розгортаємо його так, щоб Ви могли побачити всі його маркери.",
+ "maps_click_to_activate": "Натисність, щоб активувати мапу",
+ "maps_centred_on": "Центр мапи — $1, $2.",
+ "maps-par-mappingservice": "Дозволяє налаштувати картографічний сервіс, який буде використовуватися для генерації карти.",
+ "maps-par-resizable": "Робить карту змінного розміру, перетяганням в правому нижньому куті.",
+ "maps-par-searchmarkers": "Дозволяє шукати специфічні маркери через поле, вбудоване в карту.",
+ "maps-par-zoom": "Рівень масштабування карти. Для карт з маркерами він типово буде найменшим рівнем, який показує всі маркери.",
+ "maps-par-width": "Дозволяє задати ширину карти. За замовчуванням пікселі прийняті як одиниці, але ви можете вибрати одну з цих одиниць: px, ex, em, %.",
+ "maps-par-height": "Дозволяє задати висоту карти. За замовчуванням пікселі прийняті як одиниці, але ви можете вибрати одну з цих одиниць: px, ex, em, %.",
+ "maps-par-centre": "Місцевість відносно якої карта має центруватися",
+ "maps-par-enable-fullscreen": "Увімкнути кнопку повноекранного режиму",
+ "maps-par-kml": "Файли KML для завантаження на карту.",
+ "maps-par-markercluster": "Дозволяє об'єднувати декілька прилеглих маркерів в один маркер",
+ "maps-googlemaps3-incompatbrowser": "Веб-переглядач несумісний із Картами Google версії 3.",
+ "maps-googlemaps3-par-imageoverlays": "Дозволяє додати зображення, яке буде показано в зазначеному місці на карті.",
+ "maps-googlemaps3-par-type": "Тим карти, який буде показуватись спочатку.",
+ "maps-googlemaps3-par-types": "Типи карти, які будуть доступні через керування типом.",
+ "maps-googlemaps3-par-layers": "Спеціальні шари для завантаження у карту.",
+ "maps-googlemaps3-par-controls": "Елементи керування, які буде розміщено на карті.",
+ "maps-googlemaps3-par-zoomstyle": "Стиль елементу керування масштабом.",
+ "maps-googlemaps3-par-typestyle": "Стиль елементу керування типом.",
+ "maps-googlemaps3-par-autoinfowindows": "Автоматично відкрити всі інформаційні вікна, після завантаження сторінки.",
+ "maps-googlemaps3-par-gkml": "Файли KML, розташовані на серверах Google для завантаження на карту.",
+ "maps-googlemaps3-par-kmlrezoom": "Масштабування карти після завантаження KML шарів.",
+ "maps-googlemaps3-par-poi": "Показати визначні пам'ятки.",
+ "maps-googlemaps3-par-clustergridsize": "Розмір сітки кластера в пікселях.",
+ "maps-par-clustermaxzoom": "Максимальний рівень наближення, де кластери можуть існувати.",
+ "maps-par-clusterzoomonclick": "Чи є збільшення до кластеру поведінкою за замовчуванням при натисканні на нього.",
+ "maps-par-maxclusterradius": "Максимальний радіус, який буде покритий кластером.",
+ "maps-googlemaps3-par-clusteraveragecenter": "Чи повинен центр кожного кластеру бути середнім усіх міток у ньому.",
+ "maps-googlemaps3-par-clusterminsize": "Мінімальне число міток у кластері, починаючи з якого мітки сховані, а показано їх число.",
+ "mapeditor": "Редактор карт",
+ "specialpages-group-maps": "Карти",
+ "mapeditor-parser-error": "Сталася помилка при обробці метаданих. Ігноруються введені дані.",
+ "mapeditor-none-text": "Нічого",
+ "mapeditor-done-button": "Готово",
+ "mapeditor-remove-button": "Вилучити",
+ "mapeditor-import-button2": "Імпортувати",
+ "mapeditor-export-button": "Експортувати у вікітекст",
+ "mapeditor-import-button": "Імпортувати із вікітексту",
+ "mapeditor-select-button": "Обрати багатокутник",
+ "mapeditor-mapparam-button": "Редагувати параметри карти",
+ "mapeditor-clear-button": "Очистити карту",
+ "mapeditor-code-title": "Вікітекст",
+ "mapeditor-import-title": "Імпорт вікітексту",
+ "mapeditor-import-note": "Зверніть увагу, що обробник очікує дуже строго відформатований вікітекст. Вікітекст, введений тут, повинен точно відповідати тому вікітексту, який був згенерований при експорті.",
+ "mapeditor-form-title": "Редагуння деталей",
+ "mapeditor-link-title-switcher-popup-text": "Вспливаюча підказка",
+ "mapeditor-link-title-switcher-link-text": "Посилання",
+ "mapeditor-form-field-title": "Назва",
+ "mapeditor-form-field-text": "Текст",
+ "mapeditor-form-field-link": "Посилання",
+ "mapeditor-form-field-icon": "Іконка",
+ "mapeditor-form-field-group": "Група",
+ "mapeditor-form-field-inlinelabel": "Текстова мітка",
+ "mapeditor-form-field-strokecolor": "Колір контуру",
+ "mapeditor-form-field-strokeopacity": "Прозорість контуру",
+ "mapeditor-form-field-strokeweight": "Товщина контуру",
+ "mapeditor-form-field-fillcolor": "Колір заливки",
+ "mapeditor-form-field-fillopcaity": "Прозорість заливки",
+ "mapeditor-form-field-showonhover": "Показувати лише при наведенні",
+ "mapeditor-mapparam-title": "Редагувати параметри карти",
+ "mapeditor-mapparam-defoption": "-Оберіть параметр-",
+ "mapeditor-imageoverlay-button": "Додати накладення зображення",
+ "mapeditor-form-field-image": "Зображення",
+ "mapeditor-imageoverlay-title": "Деталі накладання зображення",
+ "mapeditor-form-field-visitedicon": "Іконка для відвіданого",
+ "semanticmaps-unrecognizeddistance": "Значення $1 є недопустимою відстанню.",
+ "semanticmaps-kml-link": "Переглянути KML-файл",
+ "semanticmaps-default-kml-pagelink": "Переглянути сторінку $1",
+ "semanticmaps-latitude": "Широта: $1",
+ "semanticmaps-longitude": "Довгота: $1",
+ "semanticmaps-altitude": "Висота над рівнем моря: $1",
+ "semanticmaps-forminput-locations": "Місця",
+ "semanticmaps-par-staticlocations": "Перелік місць для додавання на карту разом із запитуваними даними. Наприклад, до display_points можна додати назву, опис та піктограму, використовуючи тильду „~“ в якості роздільника.",
+ "semanticmaps-par-showtitle": "Показує чи не показує заголовок в інформаційному вікні маркера. Вимикання цього корисне при використанні шаблону для форматування інформаційного вмісту вікна.",
+ "semanticmaps-par-hidenamespace": "Показувати заголовок простору назв у інформаційному вікні маркера",
+ "semanticmaps-par-centre": "Центр карти. Якщо не задано, то карта автоматично вибере оптимальний центр, який дозволяє відобразити всі маркери на карті.",
+ "semanticmaps-par-template": "Шаблон для форматування вмісту інформаційного вікна.",
+ "semanticmaps-par-geocodecontrol": "Показати управління геокодуваням.",
+ "semanticmaps-par-activeicon": "Піктограма, яка буде відображатися замість типового маркера, коли активна сторінка рівна результату запиту",
+ "semanticmaps-par-pagelabel": "Коли задано \"так\", то усі маркери матимуть \"inlineLabel\" з посиланням на сторінку, яка містить координати для маркера",
+ "semanticmaps-par-ajaxcoordproperty": "Назва властивості координат, яка використовується для побудови ajax-запиту.",
+ "semanticmaps-par-ajaxquery": "Другий запит, що надсилається через ajax для отримання додаткових координат.",
+ "semanticmaps-par-userparam": "Значення, що передається в кожен виклик шаблону, якщо шаблон використовується",
+ "semanticmaps-kml-text": "Текст, пов'язаний з кожною сторінкою. Нехтується запитаними додатковими властивостями, якщо такі є.",
+ "semanticmaps-kml-title": "Типовий заголовок для результатів",
+ "semanticmaps-kml-linkabsolute": "Посилання мають бути абсолютними (на відміну від відносних)",
+ "semanticmaps-kml-pagelinktext": "Текст, який використовується для посилань на сторінку, в яких $1 буде замінено на назву сторінки",
+ "semanticmaps-shapes-improperformat": "Неправильне форматування з $1. Будь ласка, дивіться документацію для форматування",
+ "semanticmaps-shapes-missingshape": "Немає форм для $1, див. документацію за доступними формами",
+ "validator-type-mapscircle": "Географічне коло",
+ "validator-type-mapscircle-list": "Список кіл",
+ "validator-type-mapsimageoverlay": "Накладення зображення",
+ "validator-type-mapsimageoverlay-list": "Список накладень зображень",
+ "validator-type-mapsline": "Географічна лінія",
+ "validator-type-mapsline-list": "Список ліній",
+ "validator-type-mapslocation": "Географічна місцевість",
+ "validator-type-mapslocation-list": "Список місцевостей",
+ "validator-type-mapsrectangle": "Географічний прямокутник",
+ "validator-type-mapsrectangle-list": "Список прямокутників",
+ "validator-type-mapspolygon": "Географічний багатокутник",
+ "validator-type-mapspolygon-list": "Список географічних багатокутників",
+ "validator-type-wmsoverlay": "Накладення Web Map Service",
+ "validator-type-jsonfile": "текст"
+}
diff --git a/www/wiki/extensions/Maps/i18n/ur.json b/www/wiki/extensions/Maps/i18n/ur.json
new file mode 100644
index 00000000..17305d09
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/ur.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tahir mq",
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "maps_map": "نقشہ",
+ "maps-loading-map": "نقشہ لوڈ ہو رہا ہے...",
+ "maps-markers": "مارکر",
+ "maps-searchmarkers-text": "فلٹر مارکر",
+ "maps-others": "دوسروں",
+ "maps-ns-layer": "تہہ",
+ "maps-layer-property": "پراپرٹی",
+ "maps-layer-value": "قدر",
+ "maps-layer-errors": "غلطیاں",
+ "maps-mapsdoc-par-service": "کے لئے پیرامیٹر کی دستاویزات کو ظاہر کرنے کے لئے تعریفیں سروس.",
+ "maps-coordinates-par-location": "نقاط آپ تشکيل کرنے کے لئے چاہتے ہیں.",
+ "maps-distance-par-distance": "ایک مخصوص یونٹ کے ساتھ اس کے برابر کرنے کے لئے تبدیل کرنے کے لئے مسافت.",
+ "maps-latitude": "عرض البلد:",
+ "maps-longitude": "طول البلد:",
+ "maps_map_cannot_be_displayed": "نقشے کو دکھایا جائے نہیں کر سکتے ہیں.",
+ "maps_click_to_activate": "نقشہ کو چالو کرنے کے لئے کلک کریں",
+ "maps-googlemaps3-par-type": "ابتدائی طور پر ظاہر کرنے کے لئے نقشہ قسم.",
+ "maps-googlemaps3-par-controls": "نقشے پر جگہ کنٹرول.",
+ "maps-googlemaps3-par-zoomstyle": "زوم کے کنٹرول کے انداز.",
+ "maps-googlemaps3-par-typestyle": "قسم کے کنٹرول کے انداز.",
+ "maps-googlemaps3-par-poi": "دلچسپی کے پوائنٹس دکھائیں ۔",
+ "maps-openlayers-par-layers": "کی تہوں ہے کہ پرت کے رکھیں میں دستیاب ہو جائے گا. کے پرت کے سب سے پہلے دکھایا جائے گا جب نقشہ بوجھ.",
+ "maps-osm-par-photos": "شو کی تصاویر",
+ "mapeditor": "ایڈیٹر کا نقشہ",
+ "specialpages-group-maps": "نقشہ جات",
+ "mapeditor-none-text": "کوئی بھی نہیں",
+ "mapeditor-done-button": "کیا کیا",
+ "mapeditor-remove-button": "حذف کریں",
+ "mapeditor-import-button2": "درآمد",
+ "mapeditor-clear-button": "واضح نقشہ",
+ "mapeditor-form-title": "تفصیلات میں ترمیم کریں",
+ "mapeditor-form-field-title": "عنوان",
+ "mapeditor-form-field-text": "ٹیکسٹ",
+ "mapeditor-form-field-link": "لنک",
+ "mapeditor-form-field-group": "گروپ",
+ "mapeditor-form-field-image": "تصویر"
+}
diff --git a/www/wiki/extensions/Maps/i18n/vep.json b/www/wiki/extensions/Maps/i18n/vep.json
new file mode 100644
index 00000000..604c2257
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/vep.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "Pohj.",
+ "maps-abb-east": "Päivl.",
+ "maps-abb-south": "Suvi",
+ "maps-abb-west": "Päivn.",
+ "maps-latitude": "Leveduz:",
+ "maps-longitude": "Piduz:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/vi.json b/www/wiki/extensions/Maps/i18n/vi.json
new file mode 100644
index 00000000..fa1873d0
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/vi.json
@@ -0,0 +1,107 @@
+{
+ "@metadata": {
+ "authors": [
+ "Baonguyen21022003",
+ "Minh Nguyen",
+ "Vinhtantran",
+ "Withoutaname",
+ "Dinhxuanduyet",
+ "Macofe",
+ "Nhatminh01"
+ ]
+ },
+ "maps-desc": "Cung cấp khả năng nhúng bản đồ động vào trang wiki, mã hóa địa lý các địa chỉ, và thực hiện các tác vụ địa lý khác",
+ "right-geocode": "Mã hóa địa lý",
+ "maps_map": "Bản đồ",
+ "maps-loading-map": "Đang tải bản đồ…",
+ "maps-load-failed": "Không thể tải bản đồ!",
+ "maps-markers": "Chú thích",
+ "maps-copycoords-prompt": "Ctrl+C, Enter (⌘C ↩ trên Mac)",
+ "maps-others": "khác",
+ "maps-ns-layer": "Lớp",
+ "maps-ns-layer-talk": "Thảo luận Lớp",
+ "maps-layer-property": "Thuộc tính",
+ "maps-layer-value": "Giá trị",
+ "maps-layer-errors": "Lỗi",
+ "maps-error-invalid-layertype": "Không có lớp nào kiểu “$1”. Chỉ có {{PLURAL:$3|loại|các loại}} này được hỗ trợ: $2",
+ "maps-error-no-layertype": "Cần phải định rõ kiểu lớp. {{PLURAL:$2|Kiểu|Các kiểu}} này được hỗ trợ: $1",
+ "validation-error-invalid-layer": "Tham số $1 phải là một lớp hợp lệ.",
+ "validation-error-invalid-layers": "Tham số $1 phải là một hoặc nhiều lớp hợp lệ.",
+ "maps-layer-of-type": "Lớp kiểu $1",
+ "maps-layer-type-supported-by": "{{PLURAL:$2|Có thể|Chỉ có thể}} sử dụng kiểu lớp này với {{PLURAL:$2|dịch vụ bản đồ $1|các dịch vụ bản đồ: $1}}.",
+ "maps-coordinates-par-location": "Tọa độ để định dạng hóa.",
+ "maps-coordinates-par-format": "Định dạng cho ra tọa độ.",
+ "maps-coordinates-par-directional": "Nên cho ra hướng với tọa độ hay không.",
+ "maps-distance-par-decimals": "Đa số chữ số thập phân trong giá trị kết quả.",
+ "maps-distance-par-unit": "Đơn vị của tầm xa được cho ra.",
+ "maps-finddestination-par-location": "Vị trí ban đầu.",
+ "maps-finddestination-par-bearing": "Hướng ban đầu.",
+ "maps-finddestination-par-distance": "Tầm xa để chạy.",
+ "maps-finddestination-par-format": "Định dạng cho ra nơi đến",
+ "maps-geocode-par-location": "Địa chỉ để mã hóa địa lý.",
+ "maps-displaymap-par-wmsoverlay": "Sử dụng lớp phủ WMS",
+ "validation-error-invalid-location": "Tham số $1 phải là một vị trí hợp lệ.",
+ "validation-error-invalid-locations": "Tham số $1 phải là một hoặc nhiều vị trí hợp lệ.",
+ "validation-error-invalid-width": "Tham số $1 phải là một chiều rộng hợp lệ.",
+ "validation-error-invalid-height": "Tham số $1 phải là một chiều cao hợp lệ.",
+ "validation-error-invalid-distance": "Tham số $1 phải là một tầm hợp lệ.",
+ "validation-error-invalid-distances": "Tham số $1 phải là một hoặc nhiều vị trí hợp lệ.",
+ "validation-error-invalid-image": "Tham số $1 phải là một hình ảnh hợp lệ.",
+ "validation-error-invalid-images": "Tham số $1 phải là một hoặc nhiều hình ảnh hợp lệ.",
+ "validation-error-invalid-goverlay": "Tham số $1 phải là một lớp phủ hợp lệ.",
+ "validation-error-invalid-goverlays": "Tham số $1 phải là một hoặc nhiều lấp hợp lệ.",
+ "maps-abb-north": "B",
+ "maps-abb-east": "Đ",
+ "maps-abb-south": "N",
+ "maps-abb-west": "T",
+ "maps-latitude": "Vĩ độ:",
+ "maps-longitude": "Kinh độ:",
+ "maps-invalid-coordinates": "Giá trị $1 không được nhận ra là tọa độ hợp lệ.",
+ "maps_coordinates_missing": "Chưa định rõ tọa độ cho bản đồ.",
+ "maps_geocoding_failed": "Không thể tính ra mã địa lý của {{PLURAL:$2|địa chỉ|các địa chỉ}} sau: $1.\nKhông thể hiển thị bản đồ.",
+ "maps_geocoding_failed_for": "Không thể tính ra mã địa lý của {{PLURAL:$2|địa chỉ|các địa chỉ}} sau nên bản đồ bỏ qua nó:\n$1",
+ "maps_unrecognized_coords": "Không thể nhận ra {{PLURAL:$2|tọa độ|các tọa độ}} sau: $1.",
+ "maps_unrecognized_coords_for": "Không thể nhận ra {{PLURAL:$2|tọa độ|các tọa độ}} sau nên bản đồ bỏ qua nó:\n$1",
+ "maps_map_cannot_be_displayed": "Không thể hiển thị bản đồ.",
+ "maps-geocoder-not-available": "Không thể mã hóa vị trí của bạn vì tính năng mã hóa địa lý của Bản đồ không có sẵn.",
+ "maps_click_to_activate": "Nhấn chuột vào bản đồ để kích hoạt",
+ "maps_centred_on": "Bản đồ với trung tậm tại $1, $2.",
+ "mapeditor": "Sửa đổi bản đồ",
+ "specialpages-group-maps": "Bản đồ",
+ "mapeditor-none-text": "Không có",
+ "mapeditor-done-button": "Lưu",
+ "mapeditor-remove-button": "Dời",
+ "mapeditor-import-button2": "Nhập",
+ "mapeditor-export-button": "Xuất ra mã wiki",
+ "mapeditor-import-button": "Nhập từ mã wiki",
+ "mapeditor-mapparam-button": "Sửa tham số bản đồ",
+ "mapeditor-clear-button": "Xóa bản đồ",
+ "mapeditor-code-title": "Mã wiki",
+ "mapeditor-import-title": "Nhập mã wiki",
+ "mapeditor-form-title": "Sửa chi tiết",
+ "mapeditor-link-title-switcher-popup-text": "Cửa sổ nổi lên có văn bản",
+ "mapeditor-link-title-switcher-link-text": "Liên kết",
+ "mapeditor-form-field-title": "Tên",
+ "mapeditor-form-field-text": "Văn bản",
+ "mapeditor-form-field-link": "Liên kết",
+ "mapeditor-form-field-icon": "Hình tượng",
+ "mapeditor-form-field-group": "Nhóm",
+ "mapeditor-form-field-inlinelabel": "Nhãn nội dòng",
+ "mapeditor-form-field-strokecolor": "Màu nét",
+ "mapeditor-form-field-fillcolor": "Màu tô đậm",
+ "mapeditor-mapparam-title": "Sửa tham số bản đồ",
+ "mapeditor-mapparam-defoption": "—Chọn tham số—",
+ "mapeditor-imageoverlay-button": "Thêm lớp phủ hình ảnh",
+ "mapeditor-form-field-image": "Hình ảnh",
+ "mapeditor-imageoverlay-title": "Chi tiết lớp phủ hình ảnh",
+ "semanticmaps-unrecognizeddistance": "Giá trị $1 không phải là tầm hợp lệ.",
+ "semanticmaps-kml-link": "Xem tập tin KML",
+ "semanticmaps-default-kml-pagelink": "Xem trang $1",
+ "semanticmaps-forminput-locations": "Các vị trí",
+ "semanticmaps-par-staticlocations": "Danh sách các vị trí để thêm vào bản đồ cùng với dữ liệu được truy vấn. Giống như với display_points, bạn có thể đặt tên, miêu tả, và hình tượng cho mỗi đánh dấu bằng cách phân tách dùng dấu ngã (~).",
+ "semanticmaps-par-showtitle": "Tên tùy chọn của cửa sổ thông tin đánh dấu. Có thể để trống để định dạng nội dung cửa sổ thông tin dùng bản mẫu.",
+ "semanticmaps-par-centre": "Trung tâm của bản đồ. Nếu không có, bản đồ sẽ tự động chọn trung tâm tối ưu bao gồm tất cả các dấu trên bản đồ.",
+ "semanticmaps-par-template": "Bản đồ dùng để định dạng nội dung của cửa sổ thông tin.",
+ "semanticmaps-par-geocodecontrol": "Hiện điều khiển mã hóa địa lý.",
+ "validator-type-jsonfile": "chữ"
+}
diff --git a/www/wiki/extensions/Maps/i18n/vo.json b/www/wiki/extensions/Maps/i18n/vo.json
new file mode 100644
index 00000000..484b0641
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/vo.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": [],
+ "maps-abb-north": "N",
+ "maps-abb-east": "L",
+ "maps-abb-south": "S",
+ "maps-abb-west": "V",
+ "maps-latitude": "Videt:",
+ "maps-longitude": "Lunet:"
+}
diff --git a/www/wiki/extensions/Maps/i18n/wa.json b/www/wiki/extensions/Maps/i18n/wa.json
new file mode 100644
index 00000000..30675972
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/wa.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Srtxg"
+ ]
+ },
+ "specialpages-group-maps": "Mapes"
+}
diff --git a/www/wiki/extensions/Maps/i18n/yi.json b/www/wiki/extensions/Maps/i18n/yi.json
new file mode 100644
index 00000000..481c569c
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/yi.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "maps-layer-value": "ווערט",
+ "mapeditor-remove-button": "אַראָפּנעמען",
+ "mapeditor-import-button2": "אימפארט",
+ "mapeditor-form-field-group": "גרופע"
+}
diff --git a/www/wiki/extensions/Maps/i18n/zh-hans.json b/www/wiki/extensions/Maps/i18n/zh-hans.json
new file mode 100644
index 00000000..13fc0e63
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/zh-hans.json
@@ -0,0 +1,235 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hydra",
+ "Hzy980512",
+ "Kuailong",
+ "Liuxinyu970226",
+ "PhiLiP",
+ "Qiyue2001",
+ "Xiaomingyan",
+ "Yfdyh000",
+ "Byfserag",
+ "Linforest",
+ "阿pp",
+ "Hanyanbo98",
+ "夢蝶葬花",
+ "Angrydog001"
+ ]
+ },
+ "maps-desc": "允许嵌入动态地图到wiki页面,将地址转换为地理编码,及进行其他地理学操作",
+ "right-geocode": "地理编码",
+ "action-geocode": "在此wiki进行地理编码",
+ "maps_map": "地图",
+ "maps-tracking-category": "有由地图扩展描绘地图的页面",
+ "maps-loading-map": "正在载入地图...",
+ "maps-load-failed": "无法加载地图!",
+ "maps-markers": "标记",
+ "maps-copycoords-prompt": "CTRL+C, ENTER",
+ "maps-searchmarkers-text": "筛选标记",
+ "maps-others": "其他",
+ "maps-kml-parsing-failed": "解析一个或多个KML文件失败。这通常是因为检索失败或格式不正确的XML。",
+ "maps-ns-layer": "图层",
+ "maps-ns-layer-talk": "图层讨论",
+ "maps-layer-property": "属性",
+ "maps-layer-value": "值",
+ "maps-layer-errors": "错误",
+ "maps-layerdef-invalid": "$1个无效定义",
+ "maps-layerdef-invalid-fatal": "致命的无效定义",
+ "maps-layerdef-wrong-namespace": "图层定义仅在“$1”名字空间的页面有效",
+ "maps-layerdef-equal-layer-name": "图层名称在相同图层页面中必须唯一。“$1”已被另一图层使用。",
+ "maps-layerpage-usage": "带有使用图层“$1”的地图页面",
+ "maps-layerpage-nousage": "目前没有页面使用此图层。",
+ "maps-error-invalid-layertype": "没有类型“$1”的图层。只支持{{PLURAL:$3|此|这些}}类型:$2",
+ "maps-error-no-layertype": "您需要指定图层类型。只支持{{PLURAL:$2|此|这些}}类型:$1",
+ "validation-error-invalid-layer": "参数“$1”必须是一个有效图层。",
+ "validation-error-invalid-layers": "参数“$1”必须是一个或多个有效图层。",
+ "validation-error-no-non-numeric": "参数“$1”必须是一个非数值字符串。",
+ "validation-error-no-non-numerics": "参数“$1”必须是一个或多个非数值字符串。",
+ "maps-layer-of-type": "图层类型“$1”",
+ "maps-layer-of-type-and-name": "类型“$1”的图层“$2”",
+ "maps-layer-type-supported-by": "此图层类型{{PLURAL:$2|只能与$1映射服务一起使用|可与这些映射服务一起使用:$1}}。",
+ "maps-coordinates-description": "要格式化坐标的解析器钩,来自并转换至任何支持的格式。",
+ "maps-displaymap-description": "显示地理地图,而不需要在上面显示任何wiki定义的标记。",
+ "maps-distance-description": "将使用某个受支持单位的距离转换为其使用其他单位的等值。",
+ "maps-finddestination-description": "提供起点(可以是任意支持的格式)、起始方位角和一段距离来查找目的地。",
+ "maps-geocode-description": "启用地址的地理编码,换句话说,将人类可读的位置变成一组坐标。这支持几种地理编码服务,而这不应与映射服务相混淆。",
+ "maps-geodistance-description": "计算两点之间的地理距离,可使用任何支持的格式作为起点和终点。",
+ "maps-mapsdoc-description": "显示带参数的表格,用以显示指定的映射服务与其默认值和描述。",
+ "maps-layerdefinition-description": "描述一个可以通过其他地图功能显示的自定义图册。",
+ "maps-mapsdoc-par-service": "显示参数文档的映射服务。",
+ "maps-mapsdoc-par-language": "显示文档的语言。如果没有翻译可用,将使用英语。",
+ "maps-coordinates-par-location": "您希望格式化的坐标。",
+ "maps-coordinates-par-format": "目标坐标的格式。",
+ "maps-coordinates-par-directional": "指示坐标是否应输出方向。",
+ "maps-par-scrollwheelzoom": "表明是否应启用鼠标滚动。",
+ "maps-distance-par-distance": "要转换至其使用指定单位的等值的距离。",
+ "maps-distance-par-decimals": "结果值中使用的小数位数最大数。",
+ "maps-distance-par-unit": "输出的距离单位。",
+ "maps-finddestination-par-location": "初始位置。",
+ "maps-finddestination-par-bearing": "最初的影响。",
+ "maps-finddestination-par-distance": "旅行的距离。",
+ "maps-finddestination-par-format": "输出目的地的格式。",
+ "maps-finddestination-par-directional": "指示目的地格式是否应有方向性。",
+ "maps-geocode-par-location": "您希望进行地理编码的地址。",
+ "maps-geocode-par-format": "生成坐标的格式。",
+ "maps-geocode-par-directional": "指示坐标是否应输出方向。",
+ "maps-geodistance-par-location1": "要计算间距的集中第一个点。",
+ "maps-geodistance-par-location2": "要计算间距的集中第二个点。",
+ "maps-geodistance-par-unit": "要输出的距离单位。",
+ "maps-geodistance-par-decimals": "结果值中使用的小数位数最大数。",
+ "maps-displaymap-par-mappingservice": "允许设置将被用于生成地图的映射服务。",
+ "maps-displaymap-par-coordinates": "要在地图上显示的一个或多个位置。它们将以标记显示。",
+ "maps-displaymap-par-visitedicon": "原始标记被点击后,要被用作标记图标的图片文件名",
+ "maps-displaymap-par-zoom": "允许设置地图的缩放级别。当未提供并且地图上存在多个标记时,将使用最合适缩放级别而非默认配置。",
+ "maps-displaymap-par-centre": "允许设置地图中心点的坐标以用于display_point。同时接受地址和坐标。当此属性未提供时,地图将集中于提供的标记上,或提供的标记之间。",
+ "maps-displaymap-par-title": "允许设置将在所有没有具体标题的标记弹窗中显示的文本。当与标签一起使用时,标题将被加粗,并加下划线。",
+ "maps-displaymap-par-label": "允许设置将在所有标记中的弹出窗口显示的文本,只要它们不包含特定标签的话。",
+ "maps-displaymap-par-icon": "允许设置图标用于所有标记。",
+ "maps-displaymap-par-circles": "圈起以显示",
+ "maps-displaymap-par-copycoords": "当点击可以复制坐标的位置时显示对话框",
+ "maps-displaymap-par-lines": "要显示的行",
+ "maps-displaymap-par-maxzoom": "最大缩放级别",
+ "maps-displaymap-par-minzoom": "最小缩放级别",
+ "maps-displaymap-par-polygons": "要显示的多边形",
+ "maps-displaymap-par-rectangles": "要显示的矩形",
+ "maps-displaymap-par-static": "使地图静态",
+ "maps-displaymap-par-wmsoverlay": "使用一个WMS覆盖",
+ "maps-displaymap-par-geojson": "GeoJSON文件的URL",
+ "maps-fullscreen-button": "切换全屏显示",
+ "maps-fullscreen-button-tooltip": "全屏查看地图或嵌入。",
+ "validation-error-invalid-location": "参数 $1 必须是一个有效的位置。",
+ "validation-error-invalid-locations": "参数 $1 必须有一个或多个有效的位置。",
+ "validation-error-invalid-width": "参数 $1 必须是一个有效的宽度。",
+ "validation-error-invalid-height": "参数 $1 必须是一个有效的高度。",
+ "validation-error-invalid-distance": "参数“$1”必须是一个有效的距离。",
+ "validation-error-invalid-distances": "参数“$1”必须是一个或多个有效距离。",
+ "validation-error-invalid-image": "参数“$1”必须是一个有效的图片。",
+ "validation-error-invalid-images": "参数“$1”必须是一个或多个有效的图像。",
+ "validation-error-invalid-goverlay": "参数“$1”必须是一个有效的重叠。",
+ "validation-error-invalid-goverlays": "参数“$1”必须是一个或多个有效重叠。",
+ "maps-abb-north": "北",
+ "maps-abb-east": "东",
+ "maps-abb-south": "南",
+ "maps-abb-west": "西",
+ "maps-latitude": "纬度:",
+ "maps-longitude": "经度:",
+ "maps-invalid-coordinates": "值$1未视作有效的坐标值集。",
+ "maps_coordinates_missing": "地图上没有提供坐标。",
+ "maps_geocoding_failed": "以下$2个地址无法编码:$1。",
+ "maps_geocoding_failed_for": "以下$2个地址不能编码并且已在地图中忽略:\n$1",
+ "maps_unrecognized_coords": "以下$2个坐标不被认可:$1。",
+ "maps_unrecognized_coords_for": "以下$2个坐标不被认可并{{PLURAL:$2|已}}被地图忽略:$1。",
+ "maps_map_cannot_be_displayed": "该地图无法显示。",
+ "maps-geocoder-not-available": "地图的地理编码功能不可用。您所在地区不能被编码。",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "允许设置地图的默认缩放级别。",
+ "maps-leaflet-par-layers": "将在图层选择器中可用的图层。第一个图层将在地图加载时显示。",
+ "maps-leaflet-par-overlaylayers": "在地图加载时将显示的覆盖图层。",
+ "maps-leaflet-par-maxclusterradius": "群集将从中心标记处遮住的最大半径(像素)。",
+ "maps-leaflet-par-clusterspiderfy": "当您在下方缩放级别点击群集时,我们使其蜘蛛化,这样您可以看见它所有的标记。",
+ "maps_click_to_activate": "点击激活地图",
+ "maps_centred_on": "地图居中在$1,$2。",
+ "maps-par-mappingservice": "允许设置将被用于生成地图的映射服务。",
+ "maps-par-resizable": "通过拖放右下角使地图大小可变。",
+ "maps-par-searchmarkers": "允许通过嵌入在地图中的字段搜索特定标记。",
+ "maps-par-zoom": "地图的缩放级别。对于带标记的地图,这将默认放大到仍可显示所有标记的最大级别。",
+ "maps-par-width": "允许设置地图宽度。默认情况下像素将被假定为单位,但您可以明确指定这些单位之一:px、ex、em、%。",
+ "maps-par-height": "允许设置地图高度。默认情况下像素将被假定为单位,但您可以明确指定这些单位之一:px、ex、em、%。",
+ "maps-par-centre": "地图上的位置应该居中",
+ "maps-par-enable-fullscreen": "启用全屏按钮",
+ "maps-par-kml": "加载地图上的KML文件。",
+ "maps-par-markercluster": "允许将多个附近标记合并为一个标记",
+ "maps-googlemaps3-incompatbrowser": "您的浏览器不兼容Google Maps v3。",
+ "maps-googlemaps3-par-imageoverlays": "允许添加图片以在地图的特定地点显示。",
+ "maps-googlemaps3-par-type": "首先显示的地图类型。",
+ "maps-googlemaps3-par-types": "将通过类型控制可用的地图类型。",
+ "maps-googlemaps3-par-layers": "要加载在地图上的特殊图层。",
+ "maps-googlemaps3-par-controls": "要放置地图上的控件。",
+ "maps-googlemaps3-par-zoomstyle": "缩放控制的样式。",
+ "maps-googlemaps3-par-typestyle": "类型控制的样式。",
+ "maps-googlemaps3-par-autoinfowindows": "在页面加载后,自动打开所有信息窗口。",
+ "maps-googlemaps3-par-gkml": "由Google运营的加载地图上的KML文件。",
+ "maps-googlemaps3-par-kmlrezoom": "在KML图层加载后重新缩放地图。",
+ "maps-googlemaps3-par-poi": "显示感兴趣的点。",
+ "maps-googlemaps3-par-clustergridsize": "群集的网格大小(像素)。",
+ "maps-par-clustermaxzoom": "可能存在群集的最大缩放级别。",
+ "maps-par-clusterzoomonclick": "在群集上默认的点击行为是否为放大。",
+ "maps-par-maxclusterradius": "群集将覆盖的半径最大值。",
+ "maps-googlemaps3-par-clusteraveragecenter": "每个集群的中心是否应为集群中所有标记的平均值。",
+ "maps-googlemaps3-par-clusterminsize": "在标记被隐藏并且显示计数时,集群中标记的最小值。",
+ "mapeditor": "地图编辑器",
+ "specialpages-group-maps": "地图",
+ "mapeditor-parser-error": "解析元数据时出错。忽略用户输入。",
+ "mapeditor-none-text": "无",
+ "mapeditor-done-button": "完成",
+ "mapeditor-remove-button": "移除",
+ "mapeditor-import-button2": "导入",
+ "mapeditor-export-button": "汇出到 wiki 代码",
+ "mapeditor-import-button": "从wiki代码导入",
+ "mapeditor-select-button": "选择此多边形",
+ "mapeditor-mapparam-button": "编辑地图参数",
+ "mapeditor-clear-button": "明确地图",
+ "mapeditor-code-title": "维基代码",
+ "mapeditor-import-title": "导入维基代码",
+ "mapeditor-import-note": "请注意解析器期望在wiki代码上应用非常严格的格式。这里输入的代码应匹配由导出功能输出的代码。",
+ "mapeditor-form-title": "编辑详情",
+ "mapeditor-link-title-switcher-popup-text": "带文本的弹出菜单",
+ "mapeditor-link-title-switcher-link-text": "链接",
+ "mapeditor-form-field-title": "标题",
+ "mapeditor-form-field-text": "文字",
+ "mapeditor-form-field-link": "链接",
+ "mapeditor-form-field-icon": "图标",
+ "mapeditor-form-field-group": "组",
+ "mapeditor-form-field-inlinelabel": "内联标签",
+ "mapeditor-form-field-strokecolor": "描边颜色",
+ "mapeditor-form-field-strokeopacity": "描线不透明度",
+ "mapeditor-form-field-strokeweight": "描边粗细",
+ "mapeditor-form-field-fillcolor": "填充颜色",
+ "mapeditor-form-field-fillopcaity": "填充不透明度",
+ "mapeditor-form-field-showonhover": "只在悬停时显示",
+ "mapeditor-mapparam-title": "编辑地图参数",
+ "mapeditor-mapparam-defoption": "-选择参数-",
+ "mapeditor-imageoverlay-button": "加入图像覆盖",
+ "mapeditor-form-field-image": "图片",
+ "mapeditor-imageoverlay-title": "图像覆盖详细信息",
+ "mapeditor-form-field-visitedicon": "已浏览图标",
+ "semanticmaps-unrecognizeddistance": "取值$1不是有效的距离。",
+ "semanticmaps-kml-link": "查看KML文件",
+ "semanticmaps-default-kml-pagelink": "查看页面 $1",
+ "semanticmaps-latitude": "纬度:$1",
+ "semanticmaps-longitude": "经度:$1",
+ "semanticmaps-altitude": "绝对海拔高度:$1",
+ "semanticmaps-forminput-locations": "位置",
+ "semanticmaps-par-staticlocations": "要添加至地图的位置及查询的数据的列表。如同display_points,你可以给每个位置添加标题、说明,用浪纹分隔“~”。",
+ "semanticmaps-par-showtitle": "是否在标记信息窗口之中显示标题。当采用模板对信息窗口内容进行格式编排的时候,关闭此项往往会有所帮助。",
+ "semanticmaps-par-hidenamespace": "在标记信息窗口中显示名字空间标题",
+ "semanticmaps-par-centre": "地图的中心。当未加提供的时候,地图会自动挑选最佳的中心,从而在地图上显示所有的标记。",
+ "semanticmaps-par-template": "用来对信息窗口内容进行格式编排的模板。",
+ "semanticmaps-par-geocodecontrol": "显示地理编码控件。",
+ "semanticmaps-par-activeicon": "当活跃页面等于查询结果时将显示选定标记而不是默认标记",
+ "semanticmaps-par-pagelabel": "当您设置为“yes”时,所有标记将拥有一个“inlineLabel”带有一个链接至包含坐标标记的页面",
+ "semanticmaps-par-ajaxcoordproperty": "用于构造ajax查询的坐标属性名称。",
+ "semanticmaps-par-ajaxquery": "通过ajax发送以取得额外坐标的第二查询。",
+ "semanticmaps-par-userparam": "当模板被使用时,传递到每个模板调用的值",
+ "semanticmaps-kml-text": "与每个页面相关联的文本。会被额外的查询属性(如果有的话)所覆盖。",
+ "semanticmaps-kml-title": "结果的默认标题",
+ "semanticmaps-kml-linkabsolute": "链接究竟应当是绝对地址还是相对地址",
+ "semanticmaps-kml-pagelinktext": "用于那些指向该页面的链接的文本;其中,页面标题将取代$1",
+ "semanticmaps-shapes-improperformat": "$1 的格式不正确。请参阅文档格式",
+ "semanticmaps-shapes-missingshape": "找不到用于$1的形状。请参见文档以查看可用形状",
+ "validator-type-mapscircle": "地理圈",
+ "validator-type-mapscircle-list": "圈列表",
+ "validator-type-mapsimageoverlay": "图片覆盖",
+ "validator-type-mapsimageoverlay-list": "图片覆盖列表",
+ "validator-type-mapsline": "地理线",
+ "validator-type-mapsline-list": "线列表",
+ "validator-type-mapslocation": "地理位置",
+ "validator-type-mapslocation-list": "位置列表",
+ "validator-type-mapsrectangle": "地理矩形",
+ "validator-type-mapsrectangle-list": "矩形列表",
+ "validator-type-mapspolygon": "地理多边形",
+ "validator-type-mapspolygon-list": "地理多边形列表",
+ "validator-type-wmsoverlay": "网络地图服务覆盖",
+ "validator-type-jsonfile": "文本"
+}
diff --git a/www/wiki/extensions/Maps/i18n/zh-hant.json b/www/wiki/extensions/Maps/i18n/zh-hant.json
new file mode 100644
index 00000000..e96f3010
--- /dev/null
+++ b/www/wiki/extensions/Maps/i18n/zh-hant.json
@@ -0,0 +1,235 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cwlin0416",
+ "EagerLin",
+ "Horacewai2",
+ "Justincheng12345",
+ "Mark85296341",
+ "Shirayuki",
+ "Simon Shek",
+ "Waihorace",
+ "LNDDYL",
+ "Macofe",
+ "1233thehongkonger",
+ "Liuxinyu970226",
+ "Oapbtommy",
+ "Kly"
+ ]
+ },
+ "maps-desc": "可讓 Wiki 頁面嵌入動態地圖,支援使用地理編碼標記位置,以及地理相關操作",
+ "right-geocode": "地理編碼",
+ "action-geocode": "在此 wiki 上進行地理編碼",
+ "maps_map": "地圖",
+ "maps-tracking-category": "使用地圖擴充套件顯示地圖的頁面",
+ "maps-loading-map": "讀取地圖中...",
+ "maps-load-failed": "無法讀取地圖!",
+ "maps-markers": "標記",
+ "maps-copycoords-prompt": "CTRL+C,ENTER",
+ "maps-searchmarkers-text": "搜尋標記",
+ "maps-others": "其他",
+ "maps-kml-parsing-failed": "分析一個或多個 KML 檔案失敗,通常因為檔案接收失敗,或者 XML 格式不正確。",
+ "maps-ns-layer": "圖層",
+ "maps-ns-layer-talk": "圖層對話",
+ "maps-layer-property": "屬性",
+ "maps-layer-value": "值",
+ "maps-layer-errors": "錯誤",
+ "maps-layerdef-invalid": "無效的定義 {{PLURAL:$1| |s}}",
+ "maps-layerdef-invalid-fatal": "嚴重無效的定義",
+ "maps-layerdef-wrong-namespace": "圖層定義僅在命名空間 \"$1\" 中的頁面有效",
+ "maps-layerdef-equal-layer-name": "圖層名稱不可與其他圖層頁面相同。\"$1\" 已被其他圖層使用。",
+ "maps-layerpage-usage": "地圖使用圖層 \"$1\" 的頁面",
+ "maps-layerpage-nousage": "目前沒有任何頁面使用此圖層。",
+ "maps-error-invalid-layertype": "不支援圖層類型 \"$1\",僅支援的{{PLURAL:$3|類型|類型}}為:$2",
+ "maps-error-no-layertype": "您必須指定圖層類型,{{PLURAL:$2|僅支援|支援}}的圖層類型為:$1",
+ "validation-error-invalid-layer": "參數 \"$1\" 必須是一個有效的圖層。",
+ "validation-error-invalid-layers": "參數 \"$1\" 必須是一個或多個有效的圖層。",
+ "validation-error-no-non-numeric": "參數 \"$1\" 必須是一個非數字的字串。",
+ "validation-error-no-non-numerics": "參數 \"$1\" 必須是一個或多個非數字的字串。",
+ "maps-layer-of-type": "圖層類型 \"$1\"",
+ "maps-layer-of-type-and-name": "類型為 \"$1\" 的圖層 \"$2\"",
+ "maps-layer-type-supported-by": "此類型圖層{{PLURAL:$2|只可使用 $1 地圖服務|可使用以下地圖服務:$1}}。",
+ "maps-coordinates-description": "用來格式化座標的分析器連結(Hook),可在支援的格式之間轉換。",
+ "maps-displaymap-description": "顯示地理地圖,不顯示任何 Wiki 定義的標記於地圖上。",
+ "maps-distance-description": "可以使用任何支援的單位轉換距離的單位",
+ "maps-finddestination-description": "根據起點 (可使用支援的任何格式)、初始方位與距離找尋目的地。",
+ "maps-geocode-description": "開啟地圖編碼位置,將可閱讀的位置名稱轉換為座標。地圖編碼有許多不同服務可選擇,與地圖服務不同。",
+ "maps-geodistance-description": "計算地圖兩點之間的距離,可使用任何支援的格式作為起點與終點。",
+ "maps-mapsdoc-description": "顯示帶有參數的表格,用於指定的地圖服務與其該預設值及描述。",
+ "maps-layerdefinition-description": "描述自訂圖層,可以顯示其他地圖功能。",
+ "maps-mapsdoc-par-service": "顯示參數文件的地圖服務。",
+ "maps-mapsdoc-par-language": "文件顯示的語言,如果沒有可用翻譯的話,會以英語取代。",
+ "maps-coordinates-par-location": "您希望格式化的座標。",
+ "maps-coordinates-par-format": "座標的目標格式。",
+ "maps-coordinates-par-directional": "指示座標是否應輸出方向。",
+ "maps-par-scrollwheelzoom": "指示是否應啟用滑鼠滾動。",
+ "maps-distance-par-distance": "轉換成與指定單位等值的距離。",
+ "maps-distance-par-decimals": "用於結果值中小數位數的最大值。",
+ "maps-distance-par-unit": "輸出距離的單位。",
+ "maps-finddestination-par-location": "初始位置。",
+ "maps-finddestination-par-bearing": "初始方位。",
+ "maps-finddestination-par-distance": "移動距離。",
+ "maps-finddestination-par-format": "輸出目的地的格式。",
+ "maps-finddestination-par-directional": "指示目的地格式是否要包含方向。",
+ "maps-geocode-par-location": "您想要地理編碼的地址。",
+ "maps-geocode-par-format": "座標結果的格式。",
+ "maps-geocode-par-directional": "指示座標是否應輸出方向。",
+ "maps-geodistance-par-location1": "設定裡用來計算間距的第一個點。",
+ "maps-geodistance-par-location2": "設定裡用來計算間距的第二個點。",
+ "maps-geodistance-par-unit": "輸出距離的單位。",
+ "maps-geodistance-par-decimals": "用於結果值中小數位數的最大值。",
+ "maps-displaymap-par-mappingservice": "允許設定用於產生地圖的地圖服務。",
+ "maps-displaymap-par-coordinates": "顯示在地圖上的一個或多個位置,它們會被指示成標記。",
+ "maps-displaymap-par-visitedicon": "在原有標記被點擊時,用於標記圖標的圖片檔案名稱。",
+ "maps-displaymap-par-zoom": "允許設定地圖的縮放層級。\n若不提供且多個標記有呈現在地圖上時,將會採用最適宜的縮放而非設置的預設值。",
+ "maps-displaymap-par-centre": "允許設定用於 display_point(s) 的地圖中心座標。\n可同時接受地址與坐標。\n當此屬性未提供時,地圖將會在所提供標記裡至中,或是在所提供的標記之間。",
+ "maps-displaymap-par-title": "允許設定顯示於所有標記的彈跳視窗顯示文字,若該標記不包含特定標籤的話。\n當與標籤一同使用時,標題將會以粗體並附上底線呈現。",
+ "maps-displaymap-par-label": "允許設定顯示於所有標記的彈跳視窗顯示文字,若該標記不包含特定標籤的話。",
+ "maps-displaymap-par-icon": "允許設定用於所有標記的圖標。",
+ "maps-displaymap-par-circles": "要顯示的圓形",
+ "maps-displaymap-par-copycoords": "當點擊來自可讓座標複製的位置時顯示對話框",
+ "maps-displaymap-par-lines": "要顯示的直線",
+ "maps-displaymap-par-maxzoom": "縮放層級上限",
+ "maps-displaymap-par-minzoom": "縮放層級下限",
+ "maps-displaymap-par-polygons": "要顯示的多邊形",
+ "maps-displaymap-par-rectangles": "要顯示的矩形",
+ "maps-displaymap-par-static": "讓地圖為靜態",
+ "maps-displaymap-par-wmsoverlay": "使用 WMS 圖層",
+ "maps-displaymap-par-geojson": "包含 GeoJSON 資料的檔案或頁面名稱之 URL",
+ "maps-fullscreen-button": "切換全螢幕",
+ "maps-fullscreen-button-tooltip": "使用全螢幕或嵌入方式檢視地圖。",
+ "validation-error-invalid-location": "參數 \"$1\" 必須是一個有效的位置。",
+ "validation-error-invalid-locations": "參數 \"$1\" 必須有一個或多個有效的位置。",
+ "validation-error-invalid-width": "參數 \"$1\" 必須是一個有效的寬度。",
+ "validation-error-invalid-height": "參數 \"$1\" 必須是一個有效的高度。",
+ "validation-error-invalid-distance": "參數 \"$1\" 必須是一個有效的距離。",
+ "validation-error-invalid-distances": "參數 \"$1\" 必須是一個或多個有效距離。",
+ "validation-error-invalid-image": "參數 \"$1\" 必須是一個有效的圖片。",
+ "validation-error-invalid-images": "參數 \"$1\" 必須是一個或多個有效的圖片。",
+ "validation-error-invalid-goverlay": "參數 \"$1\" 必須是一個有效的圖層。",
+ "validation-error-invalid-goverlays": "參數 \"$1\" 必須是一個或多個有效的圖層。",
+ "maps-abb-north": "北",
+ "maps-abb-east": "東",
+ "maps-abb-south": "南",
+ "maps-abb-west": "西",
+ "maps-latitude": "緯度:",
+ "maps-longitude": "經度:",
+ "maps-invalid-coordinates": "值 $1 不被接受為座標的設定值",
+ "maps_coordinates_missing": "地圖上沒有提供座標。",
+ "maps_geocoding_failed": "以下{{PLURAL:$2|個地址|個地址}}無法作出地理編碼:$1。",
+ "maps_geocoding_failed_for": "以下{{PLURAL:$2|個地址|個地址}}無法作出地理編碼且該{{PLURAL:$2|個地址已|個地址已}}從地圖裡捨去:$1。",
+ "maps_unrecognized_coords": "以下{{PLURAL:$2|個座標|個座標}}不被接受:$1。",
+ "maps_unrecognized_coords_for": "以下{{PLURAL:$2|個座標|個座標}}不被接受且該{{PLURAL:$2|個座標已|個座標已}}從地圖裡捨去:$1。",
+ "maps_map_cannot_be_displayed": "該地圖無法顯示。",
+ "maps-geocoder-not-available": "地圖的地理編碼功能不可用,您所在地區無法編碼。",
+ "maps_leaflet": "Leaflet",
+ "maps-leaflet-par-defzoom": "允許設定地圖的預設縮放層級。",
+ "maps-leaflet-par-layers": "此圖層將於地圖加載時顯示",
+ "maps-leaflet-par-overlaylayers": "此覆蓋圖層將於地圖加載時顯示。",
+ "maps-leaflet-par-maxclusterradius": "叢集自中央標記起會涵蓋的最大半徑(像素)。",
+ "maps-leaflet-par-clusterspiderfy": "當您在下方縮放層級點擊叢集時,我們會將其放射狀化來讓您可以查看所有的標記。",
+ "maps_click_to_activate": "按一下以啟動地圖",
+ "maps_centred_on": "地圖以 $1, $2 為中心。",
+ "maps-par-mappingservice": "允許設定用於產生地圖的地圖服務。",
+ "maps-par-resizable": "透過拖拉到右下角來變化地圖大小。",
+ "maps-par-searchmarkers": "允許透過內嵌在地圖的欄位來搜尋特定標記。",
+ "maps-par-zoom": "用於地圖的縮放層級。可用在帶標記的地圖,預設會放大到最高層級並顯示所有標記。",
+ "maps-par-width": "允許設定地圖寬度。預設會以像素為單位,而您可明確指定以下單位之一:px、ex、em、%。",
+ "maps-par-height": "允許設定地圖寬度。預設會以像素為單位,而您可明確指定以下單位之一:px、ex、em、%。",
+ "maps-par-centre": "在地圖上的位置應置中",
+ "maps-par-enable-fullscreen": "開啟全螢幕的按鈕",
+ "maps-par-kml": "載入到地圖的 KML 檔案。",
+ "maps-par-markercluster": "允許合併多個附近標記成一個標記",
+ "maps-googlemaps3-incompatbrowser": "您的瀏覽器不相容 Google 地圖 v3。",
+ "maps-googlemaps3-par-imageoverlays": "允許添加顯示在地圖特定位置的圖片。",
+ "maps-googlemaps3-par-type": "首要顯示的地圖類型。",
+ "maps-googlemaps3-par-types": "透過類型控制的可用地圖類型。",
+ "maps-googlemaps3-par-layers": "載入到地圖上的特殊圖層。",
+ "maps-googlemaps3-par-controls": "在地圖上的地點控制。",
+ "maps-googlemaps3-par-zoomstyle": "縮放控制的樣式。",
+ "maps-googlemaps3-par-typestyle": "類型控制的樣式。",
+ "maps-googlemaps3-par-autoinfowindows": "在頁面載入後,自動開啟所有訊息視窗。",
+ "maps-googlemaps3-par-gkml": "由 Google 託管載入到地圖的 KML 檔案。",
+ "maps-googlemaps3-par-kmlrezoom": "在 KML 圖層被載入後會重新縮放地圖。",
+ "maps-googlemaps3-par-poi": "顯示興趣點",
+ "maps-googlemaps3-par-clustergridsize": "像素叢集的網格大小。",
+ "maps-par-clustermaxzoom": "叢集裡可能存有的最大縮放層級。",
+ "maps-par-clusterzoomonclick": "在點擊叢集時的是否預設將其縮放。",
+ "maps-par-maxclusterradius": "叢集會涵蓋的最大半徑。",
+ "maps-googlemaps3-par-clusteraveragecenter": "任一叢集中心是否應為該叢集裡所有標記的平均值。",
+ "maps-googlemaps3-par-clusterminsize": "在標記被隱藏以及計數顯示之前,於叢集裡的標記最小值。",
+ "mapeditor": "地圖編輯器",
+ "specialpages-group-maps": "地圖",
+ "mapeditor-parser-error": "分析詮釋資料錯誤,忽略使用者輸入。",
+ "mapeditor-none-text": "無",
+ "mapeditor-done-button": "完成",
+ "mapeditor-remove-button": "移除",
+ "mapeditor-import-button2": "匯入",
+ "mapeditor-export-button": "匯出為 wiki 代碼",
+ "mapeditor-import-button": "自 wiki 代碼匯入",
+ "mapeditor-select-button": "選擇此多邊形",
+ "mapeditor-mapparam-button": "編輯地圖參數",
+ "mapeditor-clear-button": "清空地圖",
+ "mapeditor-code-title": "wiki 代碼",
+ "mapeditor-import-title": "匯入 Wiki 代碼",
+ "mapeditor-import-note": "請注意,解析器在 wiki 代碼裡會要求相當嚴格的格式。在此輸入的代碼應要符合透過解析器功能輸出的代碼內容。",
+ "mapeditor-form-title": "編輯詳細資料",
+ "mapeditor-link-title-switcher-popup-text": "顯示文字訊息",
+ "mapeditor-link-title-switcher-link-text": "連結",
+ "mapeditor-form-field-title": "標題",
+ "mapeditor-form-field-text": "文字",
+ "mapeditor-form-field-link": "連結",
+ "mapeditor-form-field-icon": "圖示",
+ "mapeditor-form-field-group": "群組",
+ "mapeditor-form-field-inlinelabel": "行內標籤",
+ "mapeditor-form-field-strokecolor": "筆畫色彩",
+ "mapeditor-form-field-strokeopacity": "筆畫透明度",
+ "mapeditor-form-field-strokeweight": "筆畫粗細",
+ "mapeditor-form-field-fillcolor": "填滿色彩",
+ "mapeditor-form-field-fillopcaity": "填滿透明度",
+ "mapeditor-form-field-showonhover": "只在滑鼠經過時顯示",
+ "mapeditor-mapparam-title": "編輯地圖參數",
+ "mapeditor-mapparam-defoption": "-請選擇參數-",
+ "mapeditor-imageoverlay-button": "新增圖片圖層",
+ "mapeditor-form-field-image": "圖片",
+ "mapeditor-imageoverlay-title": "圖片圖層詳細資料",
+ "mapeditor-form-field-visitedicon": "已瀏覽的圖示",
+ "semanticmaps-unrecognizeddistance": "數值 $1 不是有效的距離。",
+ "semanticmaps-kml-link": "檢視 KML 檔案",
+ "semanticmaps-default-kml-pagelink": "檢視頁面 $1",
+ "semanticmaps-latitude": "緯度:$1",
+ "semanticmaps-longitude": "經度:$1",
+ "semanticmaps-altitude": "海拔:$1",
+ "semanticmaps-forminput-locations": "位置",
+ "semanticmaps-par-staticlocations": "與查詢的資料一起新增到地圖的位置清單。 如 display_points,您可新增每個位置的標題、描述與圖示使用波浪號 \"~\" 作為分隔符號。",
+ "semanticmaps-par-showtitle": "是否在標記資訊視窗之中顯示標題。當使用模板對資訊視窗內容進行格式編排的時,關閉此選項通常會有所幫助。",
+ "semanticmaps-par-hidenamespace": "在標記資訊視窗中顯示命名空間的標題",
+ "semanticmaps-par-centre": "地圖的中心位置。若不指定,地圖會自動挑選可顯示所有標記於地圖上的最佳中心位置。",
+ "semanticmaps-par-template": "用來對資訊視窗內容進行格式編排的模板。",
+ "semanticmaps-par-geocodecontrol": "顯示地理編碼控制元件。",
+ "semanticmaps-par-activeicon": "當使用的頁面為查詢結果時,用來替代預設標記要顯示的圖示",
+ "semanticmaps-par-pagelabel": "當設為 \"是\" 時,所有的標記會有 \"inlineLabel\" 並連結至含有標記座標的頁面。",
+ "semanticmaps-par-ajaxcoordproperty": "使用於建置 ajax 查詢的座標屬性名稱。",
+ "semanticmaps-par-ajaxquery": "透過 ajax 發送來索取額外座標的第二個查詢。",
+ "semanticmaps-par-userparam": "在使用模板時,傳遞給各模板呼叫時的值",
+ "semanticmaps-kml-text": "與每個頁面關聯的文字。可被額外的查詢屬性所覆蓋 (若有設定)。",
+ "semanticmaps-kml-title": "查詢結果的預設標題",
+ "semanticmaps-kml-linkabsolute": "連結應為絕對位址 (相反於相對位址)",
+ "semanticmaps-kml-pagelinktext": "連結至頁面要使用的文字,文字中的 $1 會取代為頁面標題",
+ "semanticmaps-shapes-improperformat": "$1 的格式有誤,請參考格式說明文件",
+ "semanticmaps-shapes-missingshape": "查無 $1 的形狀。請查看說明文件瞭解可用的形狀",
+ "validator-type-mapscircle": "地理圓形",
+ "validator-type-mapscircle-list": "圓形清單",
+ "validator-type-mapsimageoverlay": "圖片疊加",
+ "validator-type-mapsimageoverlay-list": "圖片疊加清單",
+ "validator-type-mapsline": "地理線形",
+ "validator-type-mapsline-list": "線形清單",
+ "validator-type-mapslocation": "地理座標",
+ "validator-type-mapslocation-list": "位置清單",
+ "validator-type-mapsrectangle": "地理矩形",
+ "validator-type-mapsrectangle-list": "矩形清單",
+ "validator-type-mapspolygon": "地理多邊形",
+ "validator-type-mapspolygon-list": "地理多邊形清單",
+ "validator-type-wmsoverlay": "網路地圖服務疊加",
+ "validator-type-jsonfile": "文字"
+}
diff --git a/www/wiki/extensions/Maps/phpunit.xml.dist b/www/wiki/extensions/Maps/phpunit.xml.dist
new file mode 100644
index 00000000..57a6b7fc
--- /dev/null
+++ b/www/wiki/extensions/Maps/phpunit.xml.dist
@@ -0,0 +1,29 @@
+<phpunit backupGlobals="false"
+ backupStaticAttributes="false"
+ bootstrap="tests/bootstrap.php"
+ cacheTokens="false"
+ colors="true"
+ convertErrorsToExceptions="true"
+ convertNoticesToExceptions="true"
+ convertWarningsToExceptions="true"
+ stopOnError="false"
+ stopOnFailure="false"
+ stopOnIncomplete="false"
+ stopOnSkipped="false">
+ <testsuites>
+ <testsuite name="MapsUnit">
+ <directory>tests/Unit</directory>
+ </testsuite>
+ <testsuite name="MapsIntegration">
+ <directory>tests/Integration</directory>
+ </testsuite>
+ <testsuite name="MapsSystem">
+ <directory>tests/System</directory>
+ </testsuite>
+ </testsuites>
+ <filter>
+ <whitelist addUncoveredFilesFromWhitelist="true">
+ <directory suffix=".php">src</directory>
+ </whitelist>
+ </filter>
+</phpunit>
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/ext.maps.googlemaps3.js b/www/wiki/extensions/Maps/resources/GoogleMaps/ext.maps.googlemaps3.js
new file mode 100644
index 00000000..ce5880c2
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/ext.maps.googlemaps3.js
@@ -0,0 +1,25 @@
+/**
+ * JavaScript for Google Maps v3 maps in the Maps extension.
+ * @see https://www.mediawiki.org/wiki/Extension:Maps
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw <jeroendedauw at gmail dot com>
+ */
+(function( $, mw ) {
+
+ $( document ).ready( function() {
+
+ if ( typeof google === 'undefined' ) {
+ $( '.maps-googlemaps3' ).text( mw.msg( 'maps-googlemaps3-incompatbrowser' ) );
+ }
+ else {
+ $( '.maps-googlemaps3' ).each( function() {
+ var $this = $( this );
+ var map = $this.googlemaps( $.parseJSON( $this.find( 'div').text() ) );
+ window.maps.googlemapsList.push(map);
+ } );
+ }
+
+ } );
+
+})( window.jQuery, mediaWiki );
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/ext.sm.googlemaps3ajax.js b/www/wiki/extensions/Maps/resources/GoogleMaps/ext.sm.googlemaps3ajax.js
new file mode 100644
index 00000000..9f8c658a
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/ext.sm.googlemaps3ajax.js
@@ -0,0 +1,48 @@
+/**
+ * JavaScript for Google Maps v3 maps in the Semantic Maps extension.
+ * @see https://www.mediawiki.org/wiki/Extension:Semantic_Maps
+ *
+ * @licence GNU GPL v2+
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+
+
+(function( $, sm ) {
+ var ajaxRequest = null;
+ var mapEvents = ['dragend', 'zoom_changed'];
+
+ $( document ).ready( function() {
+ // todo: find a way to remove setTimeout.
+ setTimeout( function() {
+ if( typeof google === 'undefined' ) {
+ return;
+ }
+ $( window.maps.googlemapsList ).each( function( index, map ) {
+ if( !map.options.ajaxquery || !map.options.ajaxcoordproperty ) {
+ return;
+ }
+ $( mapEvents ).each( function( index, event ) {
+ google.maps.event.addListener( map.map, event, function() {
+ var bounds = map.map.getBounds();
+ var query = sm.buildQueryString(
+ decodeURIComponent( map.options.ajaxquery.replace( /\+/g, ' ' ) ),
+ map.options.ajaxcoordproperty,
+ bounds.getNorthEast().lat(),
+ bounds.getNorthEast().lng(),
+ bounds.getSouthWest().lat(),
+ bounds.getSouthWest().lng()
+ );
+
+ if( ajaxRequest !== null ) {
+ ajaxRequest.abort();
+ }
+ ajaxRequest = sm.ajaxUpdateMarker( map, query, map.options.icon ).done( function() {
+ map.createMarkerCluster();
+ ajaxRequest = null;
+ } );
+ } );
+ } );
+ } );
+ }, 500 );
+ } );
+})( window.jQuery, window.sm );
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ProjectedOverlay.js b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ProjectedOverlay.js
new file mode 100644
index 00000000..4056c2c3
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ProjectedOverlay.js
@@ -0,0 +1,139 @@
+// Create an overlay on the map from a projected image - Maps v3...
+// Author. John D. Coryat 05/2009
+// USNaviguide LLC - http://www.usnaviguide.com
+// Thanks go to Mile Williams EInsert: http://econym.googlepages.com/einsert.js, Google's GOverlay Example and Bratliff's suggestion...
+// Opacity code from TPhoto: http://gmaps.tommangan.us/addtphoto.html
+// This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
+//
+// Parameters:
+// map: This Map
+// imageUrl: URL of the image (Mandatory)
+// bounds: Bounds object of image destination (Mandatory)
+// Options:
+// addZoom: Added Zoom factor as a parameter to the imageUrl (include complete parameter, including separater like '?zoom='
+// percentOpacity: Default 50, percent opacity to use when the image is loaded 0-100.
+// id: Default imageUrl, ID of the div
+//
+
+function ProjectedOverlay(map, imageUrl, bounds, opts)
+{
+ google.maps.OverlayView.call(this);
+
+ this.map_ = map;
+ this.url_ = imageUrl ;
+ this.bounds_ = bounds ;
+ this.addZ_ = opts.addZoom || '' ; // Add the zoom to the image as a parameter
+ this.id_ = opts.id || this.url_ ; // Added to allow for multiple images
+ this.percentOpacity_ = opts.percentOpacity || 50 ;
+
+ this.setMap(map);
+}
+
+ProjectedOverlay.prototype = new google.maps.OverlayView();
+
+ProjectedOverlay.prototype.createElement = function()
+{
+ var panes = this.getPanes() ;
+ var div = this.div_ ;
+
+ if (!div)
+ {
+ div = this.div_ = document.createElement("div");
+ div.style.position = "absolute" ;
+ div.setAttribute('id',this.id_) ;
+ this.div_ = div ;
+ this.lastZoom_ = -1 ;
+ if( this.percentOpacity_ )
+ {
+ this.setOpacity(this.percentOpacity_) ;
+ }
+ panes.overlayLayer.appendChild(div);
+ }
+}
+
+// Remove the main DIV from the map pane
+
+ProjectedOverlay.prototype.remove = function()
+{
+ if (this.div_)
+ {
+ this.div_.parentNode.removeChild(this.div_);
+ this.div_ = null;
+ this.setMap(null);
+ }
+}
+
+// Redraw based on the current projection and zoom level...
+
+ProjectedOverlay.prototype.draw = function(firstTime)
+{
+ // Creates the element if it doesn't exist already.
+
+ this.createElement();
+
+ if (!this.div_)
+ {
+ return ;
+ }
+
+ var c1 = this.get('projection').fromLatLngToDivPixel(this.bounds_.getSouthWest());
+ var c2 = this.get('projection').fromLatLngToDivPixel(this.bounds_.getNorthEast());
+
+ if (!c1 || !c2) return;
+
+ // Now position our DIV based on the DIV coordinates of our bounds
+
+ this.div_.style.width = Math.abs(c2.x - c1.x) + "px";
+ this.div_.style.height = Math.abs(c2.y - c1.y) + "px";
+ this.div_.style.left = Math.min(c2.x, c1.x) + "px";
+ this.div_.style.top = Math.min(c2.y, c1.y) + "px";
+
+ // Do the rest only if the zoom has changed...
+
+ if ( this.lastZoom_ == this.map_.getZoom() )
+ {
+ return ;
+ }
+
+ this.lastZoom_ = this.map_.getZoom() ;
+
+ var url = this.url_ ;
+
+ if ( this.addZ_ )
+ {
+ url += this.addZ_ + this.map_.getZoom() ;
+ }
+
+ this.div_.innerHTML = '<img src="' + url + '" width=' + this.div_.style.width + ' height=' + this.div_.style.height + ' >' ;
+}
+
+ProjectedOverlay.prototype.setOpacity=function(opacity)
+{
+ if (opacity < 0)
+ {
+ opacity = 0 ;
+ }
+ if(opacity > 100)
+ {
+ opacity = 100 ;
+ }
+ var c = opacity/100 ;
+
+ if (typeof(this.div_.style.filter) =='string')
+ {
+ this.div_.style.filter = 'alpha(opacity:' + opacity + ')' ;
+ }
+ if (typeof(this.div_.style.KHTMLOpacity) == 'string' )
+ {
+ this.div_.style.KHTMLOpacity = c ;
+ }
+ if (typeof(this.div_.style.MozOpacity) == 'string')
+ {
+ this.div_.style.MozOpacity = c ;
+ }
+ if (typeof(this.div_.style.opacity) == 'string')
+ {
+ this.div_.style.opacity = c ;
+ }
+}
+
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/README b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/README
new file mode 100644
index 00000000..a82f556e
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/README
@@ -0,0 +1,5 @@
+geoxml3.js and ZipFile.complete.js has been fetched from the googlecode project : http://code.google.com/p/geoxml3/
+from the branch kmz (which seems to be the branch containing the most features)
+http://code.google.com/p/geoxml3/source/browse/#svn%2Fbranches%2Fkmz
+
+The latest version fetched when writing this was rev 79. \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ZipFile.complete.js b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ZipFile.complete.js
new file mode 100644
index 00000000..d49bb056
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/ZipFile.complete.js
@@ -0,0 +1,2172 @@
+// ZipFile.complete.js
+//
+// 2/17/2012
+//
+// =======================================================
+//
+
+// JSIO.core.js
+// ------------------------------------------------------------------
+//
+// core methods for Javascript IO.
+//
+// =======================================================
+//
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+
+(function(){
+ if (typeof JSIO == "object"){
+ var e1 = new Error("JSIO is already defined");
+ e1.source = "JSIO.core.js";
+ throw e1;
+ }
+
+ JSIO = {};
+
+ JSIO.version = "2.0 2012Feb";
+
+ JSIO.throwError = function(msg, source, sub) {
+ var error = new Error("Error: " + msg);
+ error.source = (source || this._typename || 'JSIO') + (sub ? '.'+sub : '');
+ throw error;
+ }
+
+ // Format a number as hex. Quantities over 7ffffff will be displayed properly.
+ JSIO.decimalToHexString = function(number, digits) {
+ if (number < 0) {
+ number = 0xFFFFFFFF + number + 1;
+ }
+ var r1 = number.toString(16).toUpperCase();
+ if (digits) {
+ r1 = "00000000" + r1;
+ r1 = r1.substring(r1.length - digits);
+ }
+ return r1;
+ };
+
+ JSIO.FileType = {
+ Text : 0,
+ Binary : 1,
+ XML : 2,
+ Unknown : 3
+ };
+
+
+ JSIO.guessFileType = function(name) {
+ if (name == "makefile") { return JSIO.FileType.Text; }
+
+ var lastDot = name.lastIndexOf(".");
+ if (lastDot <= 0) { return JSIO.FileType.Unknown; }
+
+ var ext= name.substring(lastDot);
+ if (ext == ".zip") { return JSIO.FileType.Binary; }
+ if (ext == ".xlsx") { return JSIO.FileType.Binary; }
+ if (ext == ".docx") { return JSIO.FileType.Binary; }
+ if (ext == ".dll") { return JSIO.FileType.Binary; }
+ if (ext == ".obj") { return JSIO.FileType.Binary; }
+ if (ext == ".pdb") { return JSIO.FileType.Binary; }
+ if (ext == ".exe") { return JSIO.FileType.Binary; }
+ if (ext == ".kmz") { return JSIO.FileType.Binary; }
+
+ if (ext == ".xml") { return JSIO.FileType.XML; }
+ if (ext == ".xsl") { return JSIO.FileType.XML; }
+ if (ext == ".kml") { return JSIO.FileType.XML; }
+ if (ext == ".csproj") { return JSIO.FileType.XML; }
+ if (ext == ".vbproj") { return JSIO.FileType.XML; }
+ if (ext == ".shfbproj") { return JSIO.FileType.XML; }
+ if (ext == ".resx") { return JSIO.FileType.XML; }
+ if (ext == ".xslt") { return JSIO.FileType.XML; }
+
+ if (ext == ".sln") { return JSIO.FileType.Text; }
+ if (ext == ".htm") { return JSIO.FileType.Text; }
+ if (ext == ".html") { return JSIO.FileType.Text; }
+ if (ext == ".js") { return JSIO.FileType.Text; }
+ if (ext == ".vb") { return JSIO.FileType.Text; }
+ if (ext == ".txt") { return JSIO.FileType.Text; }
+ if (ext == ".rels") { return JSIO.FileType.Text; }
+ if (ext == ".css") { return JSIO.FileType.Text; }
+ if (ext == ".cs") { return JSIO.FileType.Text; }
+ if (ext == ".asp") { return JSIO.FileType.Text; }
+
+ return JSIO.FileType.Unknown;
+ };
+
+ JSIO.stringOfLength = function (charCode, length) {
+ var s3 = "";
+ for (var i = 0; i < length; i++) {
+ s3 += String.fromCharCode(charCode);
+ }
+ return s3;
+ };
+
+ JSIO.formatByteArray = function(b) {
+ var s1 = "0000 ";
+ var s2 = "";
+ for (var i = 0; i < b.length; i++) {
+ if (i !== 0 && i % 16 === 0) {
+ s1 += " " + s2 +"\n" + JSIO.decimalToHexString(i, 4) + " ";
+ s2 = "";
+ }
+ s1 += JSIO.decimalToHexString(b[i], 2) + " ";
+ if (b[i] >=32 && b[i] <= 126) {
+ s2 += String.fromCharCode(b[i]);
+ } else {
+ s2 += ".";
+ }
+ }
+ if (s2.length > 0) {
+ s1 += JSIO.stringOfLength(32, ((i%16>0)? ((16 - i%16) * 3) : 0) + 4) + s2;
+ }
+ return s1;
+ };
+
+ JSIO.htmlEscape = function(str) {
+ return str
+ .replace(new RegExp( "&", "g" ), "&amp;")
+ .replace(new RegExp( "<", "g" ), "&lt;")
+ .replace(new RegExp( ">", "g" ), "&gt;")
+ .replace(new RegExp( "\x13", "g" ), "<br/>")
+ .replace(new RegExp( "\x10", "g" ), "<br/>");
+ };
+
+ JSIO.massApply = function(func, funcThis, arr, needReturn) {
+ var arrayLimit = 99999; // Chrome has an apply/array limit of 99999; Firefox = 491519
+ if (arr.length < arrayLimit) return func.apply(funcThis, arr);
+ else {
+ var newThis = funcThis;
+ var offset = 0;
+ var end = 99999;
+
+ while (offset < arr.length) {
+ var arrSlice;
+ if (arr.subarray) arrSlice = arr.subarray(offset, end);
+ else if (arr.slice) arrSlice = arr.slice(offset, end);
+
+ if (needReturn) newThis += func.apply(newThis, arrSlice);
+ else func.apply(funcThis, arrSlice);
+
+ offset += arrayLimit;
+ end += arrayLimit;
+ end = Math.min(arr.length, end);
+ }
+ return newThis;
+ }
+ }
+
+})();
+
+/// JSIO.core.js ends
+
+
+// JSIO.BasicByteReaders.js
+// ------------------------------------------------------------------
+//
+// Part of the JSIO library. Adds a couple basic ByteReaders to JSIO.
+// ByteReaders are forward-only byte-wise readers. They read one byte at
+// a time from a source.
+//
+// =======================================================
+//
+// A ByteReader exposes an interface with these functions:
+//
+// readByte()
+// must return null when EOF is reached.
+//
+// readToEnd()
+// returns an array of all bytes read, to EOF
+//
+// beginReadToEnd(callback)
+// async version of the above
+//
+// readBytes(n)
+// returns an array of the next n bytes from the source
+//
+// beginReadBytes(n, callback)
+// async version of the above
+//
+// =======================================================
+//
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+
+(function(){
+ var version = "2.0 2012Feb";
+
+ if (typeof JSIO !== "object") { JSIO = {}; }
+ if ((typeof JSIO.version !== "string")) {
+ JSIO.version = version;
+ }
+ else if ((JSIO.version.length < 3) ||
+ (JSIO.version.substring(0,3) !== "2.0")) {
+ JSIO.version += " " + version;
+ }
+
+ // =======================================================
+ // the base object, used as the prototype of all ByteReader objects.
+ var _byteReaderBase = function () {
+ this.position = 0;
+ // position must be incremented in .readByte() for all derived classes
+ };
+
+ _byteReaderBase.prototype._throwError = JSIO.throwError;
+
+ _byteReaderBase.prototype._limitCheck = function(len, startPos) {
+ var LOE = {
+ len: len,
+ pos: startPos,
+ end: startPos+len
+ };
+
+ if (len === 0) return {len:0, pos:0, end:0};
+ if (len < 0) this._throwError("Invalid read length");
+ if (!this.length) return {len:len, pos:this.position, end:len+this.position};
+ if (!startPos >= 0) LOE.pos = this.position;
+ if (this.length <= LOE.pos) this._throwError("EOF reached");
+
+ LOE.end = LOE.pos+len;
+ if (this.length < LOE.end) LOE.end = LOE.pos+(LOE.len = this.length-this.position);
+ return LOE;
+ }
+
+ JSIO.SeekOrigin = {
+ Begin : 0,
+ Current : 1,
+ End : 2,
+ SEEK_SET : 0,
+ SEEK_CUR : 1,
+ SEEK_END : 2
+ };
+
+ _byteReaderBase.prototype.seek = function(offset, origin) {
+ switch (origin) {
+ case JSIO.SeekOrigin.Begin:
+ if (offset == this.position) return this.position;
+ if (!this.length) {
+ if (offset < this.position) this._throwError('Uni-directional stream cannot seek backwards', null, 'seek');
+ else if (offset > this.position) return this.read(offset - this.position); // read will limit check
+ }
+ else {
+ if (this.length < offset) this._throwError('Cannot seek past reader length', null, 'seek');
+ this.position = offset;
+ }
+ break;
+ case JSIO.SeekOrigin.Current:
+ return this.seek(this.position + offset, JSIO.SeekOrigin.Begin);
+ break;
+ case JSIO.SeekOrigin.End:
+ if (!this.length) this._throwError('Uni-directional stream has no known end length for seek', null, 'seek');
+ return this.seek(this.length - 1 + offset, JSIO.SeekOrigin.Begin);
+ break;
+ default:
+ this._throwError('Invalid seek method', null, 'seek');
+ break;
+ }
+
+ return this.position;
+ };
+
+ _byteReaderBase.prototype.read = function(len, startPos) {
+ var LOE = this._limitCheck(len, startPos);
+ if (LOE.len === 0) return [];
+ if (LOE.pos != this.position) this.seek(LOE.pos, JSIO.SeekOrigin.Begin);
+
+ var bytesRead = [];
+
+ // Faster methods with an array or stream
+ if (this.array && this.array.subarray) bytesRead = this.array.subarray(LOE.pos, LOE.end);
+ else if (this.array && this.array.slice) bytesRead = this.array.slice(LOE.pos, LOE.end);
+ else if (this.stream) bytesRead = this.stream.read(LOE.len, LOE.pos);
+ else if (this.length) { // Random-access stream
+ for(var i=LOE.pos; i<LOE.end; i++) { bytesRead.push(this.readByteAt(i)); }
+ }
+ else { // Uni-directional stream
+ for(var i=LOE.pos; i<LOE.end; i++) {
+ var b = this.readByte();
+ if (b === null || b === undefined) break;
+ bytesRead.push(b);
+ }
+ }
+ this.position = LOE.end;
+ return bytesRead;
+ };
+
+ _byteReaderBase.prototype.beginRead = function(len, startPos, callback) {
+ var LOE = this._limitCheck(len, startPos);
+ if (LOE.len === 0) return setTimeout(function() { callback([]); }, 1);
+ if (LOE.pos != this.position) this.seek(LOE.pos, JSIO.SeekOrigin.Begin);
+
+ var bytesRead = [];
+ var thisReader = this;
+ var leftToRead = LOE.len;
+
+ var readBatchAsync = function() {
+ var c = 0;
+ var pos = thisReader.position;
+
+ // read a 32k batch
+ var l = (leftToRead >= 32768) ? 32768 : leftToRead;
+ var newBytes = thisReader.read(l);
+ JSIO.massApply(bytesRead.push, bytesRead, newBytes);
+ c += l;
+ leftToRead -= l;
+ if (newBytes.length < l) leftToRead = 0;
+
+ if (leftToRead>0) setTimeout(readBatchAsync, 1);
+ else callback(bytesRead);
+ };
+
+ // kickoff
+ setTimeout(readBatchAsync, 1); // always async, in ALL situations
+ return null;
+ };
+
+ _byteReaderBase.prototype.readToEnd = function() {
+ if (this.array && this.array.subarray) return this.array.subarray(this.position);
+ else if (this.array && this.array.slice) return this.array.slice(this.position);
+ else if (this.length) return this.read(this.length - this.position);
+ else return this.read(9000 * 9000); // over 9000
+ };
+
+ _byteReaderBase.prototype.beginReadToEnd = function(callback) {
+ if (this.array && this.array.subarray) setTimeout(function() { callback( this.array.subarray(this.position) ); }, 1);
+ else if (this.array && this.array.slice) setTimeout(function() { callback( this.array.slice(this.position) ); }, 1);
+ else if (this.length) return this.beginRead(this.length - this.position, this.position, callback);
+ else return this.beginRead(9000 * 9000, this.position, callback);
+ };
+
+ // Generic routines; one of these two MUST be overloaded (preferrably both)
+ _byteReaderBase.prototype.readByte = function(){
+ if (this.length && this.position >= this.length) return null; // EOF
+
+ var byte;
+ if (this.array) byte = this.array[this.position++];
+ else if (this.length) byte = this.readByteAt(this.position++);
+ else if (this.stream) byte = this.stream.read(1)[0];
+ else byte = this.read(1)[0];
+ return (byte === null || byte === undefined) ? null : byte;
+ };
+ _byteReaderBase.prototype.readByteAt = function(i) {
+ var pos = this.position; // no position changes on this one
+ if (i === null || i === undefined) i = this.position;
+
+ var byte;
+ if (this.array) byte = this.array[i];
+ else if (i === pos) byte = this.readByte();
+ else if (this.stream) byte = this.stream.read(1, i)[0];
+ else byte = this.read(1, i)[0];
+
+ this.position = pos;
+ return (byte === null || byte === undefined) ? null : byte;
+ }
+
+ _byteReaderBase.prototype.readBytes = _byteReaderBase.prototype.read;
+ _byteReaderBase.prototype.beginReadBytes = function(len, callback) { return this.beginRead(len, this.position, callback); };
+
+ _byteReaderBase.prototype.readNumber = function(len, startPos){
+ var LOE = this._limitCheck(len, startPos);
+ if (LOE.len === 0) LOE.len = 1;
+ if (LOE.pos != this.position) this.seek(LOE.pos, JSIO.SeekOrigin.Begin);
+
+ var result = 0;
+ var bytes = this.read(LOE.len, LOE.pos);
+ for (var i=bytes.length-1; i>=0; i--) {
+ // IE only supports 32-bit integer shifting
+ //result = result << 8 | bytes[i];
+ result = result*256 + bytes[i];
+ }
+ return result;
+ };
+
+ _byteReaderBase.prototype.readString = function(len, startPos){
+ var LOE = this._limitCheck(len, startPos);
+ if (LOE.len === 0) return '';
+ if (LOE.pos != this.position) this.seek(LOE.pos, JSIO.SeekOrigin.Begin);
+
+ var result = '';
+ var bytes = this.read(LOE.len, LOE.pos);
+ for(var i=0; i<bytes.length; i++){
+ result += String.fromCharCode(bytes[i]);
+ }
+ return result;
+ };
+
+ _byteReaderBase.prototype.readNullTerminatedString = function(startPos){
+ var pos = startPos || this.position;
+ if (this.length && this.length < pos) this._throwError('EOF reached', null, 'readNullTerminatedString');
+ if (pos != this.position) this.seek(pos, JSIO.SeekOrigin.Begin);
+
+ var slarge = "";
+ var s = "";
+ var c = 0;
+
+ // Faster method with an array
+ if (this.array && this.array.indexOf) {
+ var len = pos - this.array.indexOf(0, pos);
+ if (len > 0) return this.readString(len, pos);
+ }
+
+ var ch;
+ while(1) {
+ ch = String.fromCharCode(this.readByteAt(pos+c));
+ if (ch === null) break;
+
+ s += ch;
+ c++;
+ if(c >= 32768) {
+ slarge += s;
+ s = "";
+ pos += c;
+ this.position += c;
+ c = 0;
+ }
+ };
+ this.position = pos + c;
+ return slarge + s;
+ };
+
+ _byteReaderBase.prototype.beginReadNullTerminatedString = function(callback, startPos){
+ var pos = startPos || this.position;
+ if (this.length && this.length < pos) this._throwError('EOF reached', null, 'beginReadNullTerminatedString');
+
+ var slarge = "";
+ var s = "";
+ var thisBinStream = this;
+
+ var readBatchAsync = function() {
+ var c = 0;
+
+ var ch;
+ while(1) {
+ ch = String.fromCharCode(this.readByteAt(pos+c));
+ if (ch === null) break;
+
+ s += ch;
+ c++;
+ if(c >= 32768) {
+ slarge += s;
+ s = "";
+ pos += c;
+ this.position += c;
+ c = 0;
+ }
+ };
+
+ thisBinStream.position = pos + c;
+ if (ch!==null) setTimeout(readBatchAsync, 1);
+ else callback(slarge+s);
+ };
+
+ // Faster method with an array
+ if (this.array && this.array.indexOf) {
+ var len = pos - this.array.indexOf(0, pos);
+ if (len > 0) readBatchASync = function() { callback(thisBinStream.readString(len, pos)); };
+ }
+
+ // kickoff
+ setTimeout(readBatchAsync, 1); // always async, in ALL situations
+ return null;
+ };
+
+
+
+ JSIO._ByteReaderBase = _byteReaderBase;
+ // =======================================================
+
+
+
+
+ // =======================================================
+ // reads from an array of bytes.
+ // This basically wraps a readByte() fn onto array access.
+ var _arrayReader = function(array) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.ArrayReader', 'ctor');
+ this.position = 0;
+ this.array = array;
+ this.length = array.length;
+ this._typename = "JSIO.ArrayReader";
+ this._version = version;
+ return this;
+ };
+
+ _arrayReader.prototype = new JSIO._ByteReaderBase();
+
+ _arrayReader.prototype.readByte = function() {
+ if (this.position >= this.array.length) return null; // EOF
+ return this.array[this.position++];
+ };
+ _arrayReader.prototype.readByteAt = function(i) {
+ return this.array[i];
+ };
+
+ // =======================================================
+
+
+ // =======================================================
+ // reads bytes at a time from a defined segment of a stream.
+ var _streamSegmentReader = function(stream, offset, len) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.StreamSegmentReader', 'ctor');
+ if (!stream) this._throwError('You must pass a non-null stream', 'JSIO.StreamSegmentReader', 'ctor');
+
+ if (!(offset >= 1)) offset = 0;
+ if (!(len >= 1)) len = 0;
+
+ this.stream = stream;
+ this.array = null;
+ if (stream.array) {
+ var end = len ? offset + len : null;
+ if (stream.array.subarray) this.array = stream.array.subarray(offset, end);
+ else if (stream.array.slice) this.array = stream.array.slice(offset, end);
+ }
+ this.length = this.array ? this.array.length : (stream.length ? stream.length - offset : null);
+ this.offset = offset;
+ this.limit = len;
+ this.position = 0;
+ this._typeName = 'JSIO.StreamSegmentReader';
+ this._version = version;
+
+ if (this.array) {
+ this.readByte = _arrayReader.prototype.readByte;
+ this.readByteAt = _arrayReader.prototype.readByteAt;
+ }
+ return this;
+ };
+
+ _streamSegmentReader.prototype = new JSIO._ByteReaderBase();
+
+ _streamSegmentReader.prototype.readByte = function() {
+ if (this.limit && this.position >= this.limit) return null; // EOF
+ this.position++;
+ return this.stream.readByteAt(this.offset + this.position - 1);
+ };
+ _streamSegmentReader.prototype.readByteAt = function(i) {
+ if (this.limit && i >= this.limit) return null; // EOF
+ return this.stream.readByteAt(this.offset + i);
+ };
+
+ // =======================================================
+
+ JSIO.ArrayReader = _arrayReader;
+ JSIO.StreamReader = _streamSegmentReader;
+ JSIO.StreamSegmentReader = _streamSegmentReader;
+
+})();
+
+
+/// JSIO.BasicByteReaders.js ends
+
+// JSIO.BinaryUrlStream.js
+// ------------------------------------------------------------------
+//
+// a class that acts as a stream wrapper around binary files obtained from URLs.
+//
+// =======================================================
+//
+// Copyleft (c) 2008, Andy G.P. Na <nagoon97@naver.com> via an MIT-style license
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+(function(){
+ var version = "2.0 2012Feb";
+ var typename = "JSIO.BinaryUrlStream";
+
+ if ((typeof JSIO !== "object") ||
+ (typeof JSIO.version !== "string") ||
+ (JSIO.version.length < 3) ||
+ (JSIO.version.substring(0,3) !== "2.0"))
+ JSIO.throwError('This extension requires JSIO.core.js v2.0', typename);
+
+ if (typeof JSIO._ByteReaderBase !== "function")
+ JSIO.throwError('This extension requires JSIO.BasicByteReaders.js', typename);
+
+ if (/msie/i.test(navigator.userAgent) && !/opera/i.test(navigator.userAgent)) {
+ var IEBinaryToArray_ByteStr_Script =
+ "<!-- IEBinaryToArray_ByteStr -->\r\n"+
+ "<script type='text/vbscript'>\r\n"+
+ "Function IEBinaryToArray_ByteStr(Binary)\r\n"+
+ " IEBinaryToArray_ByteStr = CStr(Binary)\r\n"+
+ "End Function\r\n"+
+ "Function IEBinaryToArray_ByteAsc_Last(Binary)\r\n"+
+ " Dim lastIndex\r\n"+
+ " lastIndex = LenB(Binary)\r\n"+
+ " if lastIndex mod 2 Then\r\n"+
+ " IEBinaryToArray_ByteAsc_Last = AscB( MidB( Binary, lastIndex, 1 ) )\r\n"+
+ " Else\r\n"+
+ " IEBinaryToArray_ByteAsc_Last = -1\r\n"+
+ " End If\r\n"+
+ "End Function\r\n"+
+ "</script>\r\n";
+
+ // inject VBScript
+ document.write(IEBinaryToArray_ByteStr_Script);
+ }
+
+ JSIO.IEByteMapping = null;
+
+ var bus = function(url, callback) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.BinaryUrlStream', 'ctor');
+
+ this.callback = callback;
+ this.position = 0;
+ this.length = null;
+ this.readByte = JSIO.ArrayReader.prototype.readByte;
+ this.readByteAt = JSIO.ArrayReader.prototype.readByteAt;
+ this.req = null;
+ this._typename = typename;
+ this._version = version;
+ this.status = "-none-";
+
+ var _IeGetBinResource = function(fileURL){
+ var binStream = this;
+ // http://stackoverflow.com/questions/1919972/how-do-i-access-xhr-responsebody-for-binary-data-from-javascript-in-ie
+
+ // my helper to convert from responseBody to a byte array
+ var convertResponseBodyToArray = function (binary) {
+ var byteArray = new Array;
+
+ try {
+ // very fast; very little work involved
+ byteArray = new VBArray(binary).toArray();
+ }
+ catch(err) {
+ // use the BinaryToArray VBScript
+ if (!JSIO.IEByteMapping) {
+ JSIO.IEByteMapping = {};
+ for ( var i = 0; i < 256; i++ ) {
+ for ( var j = 0; j < 256; j++ ) {
+ JSIO.IEByteMapping[ String.fromCharCode( i + j * 256 ) ] = [ i, j ];
+ }
+ }
+ }
+ var rawBytes = IEBinaryToArray_ByteStr(binary);
+ var lastAsc = IEBinaryToArray_ByteAsc_Last(binary);
+
+ for ( var i = 0; i < rawBytes.length; i++ ) {
+ byteArray.push.apply(byteArray, JSIO.IEByteMapping[ rawBytes.substr(i,1) ]);
+ }
+ if (lastAsc >= 0) byteArray.push(lastAsc);
+ }
+
+ return byteArray;
+ };
+
+ this.req = (function() {
+ if (window.XMLHttpRequest) return new window.XMLHttpRequest();
+ else if (window.ActiveXObject) {
+ // the many versions of IE's XML fetchers
+ var AXOs = [
+ 'MSXML2.XMLHTTP.6.0',
+ 'MSXML2.XMLHTTP.5.0',
+ 'MSXML2.XMLHTTP.4.0',
+ 'MSXML2.XMLHTTP.3.0',
+ 'MSXML2.XMLHTTP',
+ 'Microsoft.XMLHTTP',
+ 'MSXML.XMLHTTP'
+ ];
+ for (var i = 0; i < AXOs.length; i++) {
+ try { return new ActiveXObject(AXOs[i]); }
+ catch(e) { continue; }
+ }
+ }
+ return null;
+ })();
+ this.req.open("GET", fileURL, true);
+ this.req.setRequestHeader("Accept-Charset", "x-user-defined");
+ this.req.onreadystatechange = function(event){
+ if (binStream.req.readyState == 4) {
+ binStream.status = "Status: " + binStream.req.status + ' ' + binStream.req.statusText;
+ if (binStream.req.status == 200) {
+ binStream.array = convertResponseBodyToArray(binStream.req.responseBody);
+ binStream.length = binStream.array.length;
+ if (binStream.length < 0) this._throwError('Failed to load "'+ fileURL + '" after converting');
+
+ if (typeof binStream.callback == "function") binStream.callback(binStream);
+ }
+ else {
+ binStream._throwError('Failed to load "'+ fileURL + '": HTTP ' + binStream.status);
+ }
+ }
+ };
+ this.req.send();
+ };
+
+ var _NormalGetBinResource = function(fileURL){
+ var binStream= this;
+ this.req = new XMLHttpRequest();
+ this.req.open('GET', fileURL, true);
+ this.req.onreadystatechange = function(aEvt) {
+ if (binStream.req.readyState == 4) {
+ binStream.status = "Status: " + binStream.req.status + ' ' + binStream.req.statusText;
+ if(binStream.req.status == 200){
+ var fileContents = binStream.req.responseText;
+ binStream.length = fileContents.byteLength;
+ binStream.array = fileContents.split('');
+ for ( var i = 0; i < binStream.array.length; i++ ) {
+ binStream.array[i] = binStream.array[i].charCodeAt(0) & 0xff;
+ }
+
+ if (typeof binStream.callback == "function") binStream.callback(binStream);
+ }
+ else {
+ binStream._throwError('Failed to load "'+ fileURL + '": HTTP ' + binStream.status);
+ }
+ }
+ };
+ //XHR binary charset opt by Marcus Granado 2006 [http://mgran.blogspot.com]
+ this.req.overrideMimeType('text/plain; charset=x-user-defined');
+ this.req.send(null);
+ };
+
+ // http://stackoverflow.com/questions/327685/is-there-a-way-to-read-binary-data-into-javascript
+ var _ArrayBufferGetBinResource = function(fileURL){
+ var binStream= this;
+ this.req = new XMLHttpRequest();
+ this.req.open('GET', fileURL, true);
+ this.req.onreadystatechange = function(aEvt) {
+ if (binStream.req.readyState == 4) {
+ binStream.status = "Status: " + binStream.req.status + ' ' + binStream.req.statusText;
+ if(binStream.req.status == 200){
+ var fileContents = binStream.req.response;
+ binStream.length = fileContents.byteLength;
+ binStream.array = new Uint8Array(fileContents);
+
+ if (typeof binStream.callback == "function") binStream.callback(binStream);
+ }
+ else {
+ binStream._throwError('Failed to load "'+ fileURL + '": HTTP ' + binStream.status);
+ }
+ }
+ };
+ this.req.responseType = 'arraybuffer';
+ this.req.overrideMimeType('text/plain; charset=x-user-defined');
+ this.req.send(null);
+ };
+
+
+ if (typeof ArrayBuffer !== 'undefined') _ArrayBufferGetBinResource.apply(this, [url]);
+ else if (/msie/i.test(navigator.userAgent) && !/opera/i.test(navigator.userAgent)) _IeGetBinResource.apply(this, [url]);
+ else _NormalGetBinResource.apply(this, [url]);
+ };
+
+ bus.prototype = new JSIO._ByteReaderBase();
+
+ bus.prototype.readByte = function(){
+ var byte = this.readByteAt(this.position++);
+ return (byte === null || byte === undefined) ? null : byte;
+ };
+
+ JSIO.BinaryUrlStream = bus;
+
+})();
+
+/// JSIO.BinaryUrlStream.js ends
+
+// JSIO.TextDecoder.js
+// ------------------------------------------------------------------
+//
+// Part of the JSIO library. Adds text decoders, for UTF-8 and UTF-16,
+// and plain text.
+//
+// =======================================================
+//
+// Derived in part from work by notmasteryet.
+// http://www.codeproject.com/KB/scripting/Javascript_binaryenc.aspx
+
+// Copyleft (c) 2008, notmasteryet via an MIT-style license
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+(function(){
+ var version = "2.0 2012Feb";
+ var typename = "JSIO.TextDecoder";
+
+ if ((typeof JSIO !== "object") ||
+ (typeof JSIO.version !== "string") ||
+ (JSIO.version.length < 3) ||
+ (JSIO.version.substring(0,3) !== "2.0"))
+ JSIO.throwError('This extension requires JSIO.core.js v2.0', typename);
+
+ if (typeof JSIO._ByteReaderBase !== "function")
+ JSIO.throwError('This extension requires JSIO.BasicByteReaders.js', typename);
+
+ var _ansi = function(reader) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.TextDecoder.ANSI', 'ctor');
+ this.byteReader = reader;
+ this.charWidth = 1;
+ this._version = version;
+ this._typename = typename + ".ANSI";
+ return this;
+ };
+
+ _ansi.prototype.readChar = function() {
+ var code = this.byteReader.readByte();
+ return (code < 0) ? null : String.fromCharCode(code);
+ };
+
+ _ansi.prototype.parseChar = function(code) {
+ return (code < 0) ? null : String.fromCharCode(code);
+ };
+
+ var _utf16 = function(reader) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.TextDecoder.UTF16', 'ctor');
+ this.byteReader = reader;
+ this.charWidth = 2;
+ this.bomState = 0;
+ this._version = version;
+ this._typename = typename + ".UTF16";
+ return this;
+ };
+
+ _utf16.prototype.readChar = function() {
+ var b1 = this.byteReader.readByte();
+ if (b1 < 0) return null;
+ var b2 = this.byteReader.readByte();
+ if (b2 < 0) this._throwError('Incomplete UTF16 character', null, 'readChar');
+
+ if ((this.bomState === 0) && ((b1 + b2) == 509)) {
+ this.bomState = (b2 == 254) ? 1 : 2;
+
+ b1 = this.byteReader.readByte();
+ if (b1 < 0) return null;
+ b2 = this.byteReader.readByte();
+ if (b2 < 0) this._throwError('Incomplete UTF16 character', null, 'readChar');
+ }
+ else {
+ this.bomState = 1;
+ }
+ return this.parseChar(b1, b2);
+ };
+
+ _utf16.prototype.parseChar = function(b1, b2) {
+ return String.fromCharCode( this.bomState == 1 ? (b2 << 8 | b1) : (b1 << 8 | b2) );
+ }
+
+ /* RFC 3629 */
+ var _utf8 = function(reader) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.TextDecoder.UTF8', 'ctor');
+ this.byteReader = reader;
+ this.charWidth = null;
+ this.waitBom = true;
+ this.strict = false;
+ this.pendingChar = null;
+ this._version = version;
+ this._typename = typename + ".UTF8";
+ return this;
+ };
+
+ _utf8.prototype.readChar = function() {
+ var ch = null;
+ do {
+ if (this.pendingChar !== null) {
+ ch = this.pendingChar;
+ this.pendingChar = null;
+ }
+ else {
+ var b1 = this.byteReader.readByte();
+ if (b1 === null) return null;
+
+ if ((b1 & 0x80) === 0) ch = String.fromCharCode(b1);
+ else {
+ var currentPrefix = 0xC0;
+ var ttlBytes = 0;
+ do {
+ var mask = currentPrefix >> 1 | 0x80;
+ if((b1 & mask) == currentPrefix) break;
+ currentPrefix = currentPrefix >> 1 | 0x80;
+ } while(++ttlBytes < 5);
+
+ if (ttlBytes > 0) {
+ var code;
+ if (ttlBytes === 1) code = (b1 & 0x1F) << 6 | (this.byteReader.readByte() & 0x3F);
+ else {
+ code = code << 6*ttlBytes
+ var bytes = this.byteReader.read(ttlBytes);
+ for (var i = 0; i > ttlBytes; i++) {
+ var bi = bytes[i];
+ if ((bi & 0xC0) != 0x80) this._throwError('Invalid sequence character', null, 'readChar');
+ code = (code << 6) | (bi & 0x3F);
+ }
+ }
+
+ if (code <= 0xFFFF) {
+ ch = (code == 0xFEFF && this.waitBom) ? null : String.fromCharCode(code);
+ }
+ else {
+ var v = code - 0x10000;
+ var w1 = 0xD800 | ((v >> 10) & 0x3FF);
+ var w2 = 0xDC00 | (v & 0x3FF);
+ this.pendingChar = String.fromCharCode(w2);
+ ch = String.fromCharCode(w1);
+ }
+ }
+ else {
+ // a byte higher than 0x80.
+ if (this.strict) this._throwError('Invalid character', null, 'readChar');
+ // fall back to "super ascii" (eg IBM-437)
+ else ch = String.fromCharCode(b1);
+ }
+ }
+ }
+ this.waitBom = false;
+ } while(ch === null);
+ return ch;
+ };
+
+ JSIO.TextDecoder = {
+ Default : _ansi,
+ ANSI : _ansi,
+ UTF16 : _utf16,
+ UTF8 : _utf8
+ };
+
+})();
+
+
+/// JSIO.TextDecoder.js ends
+
+// JSIO.TextReader.js
+// ------------------------------------------------------------------
+//
+// A reader class that decodes text as it reads.
+//
+// =======================================================
+//
+// Methods:
+// readChar() = read 1 char
+// read(n) = read n chars
+// readLine() = read one line of data (to \n)
+// unreadChar(ch) = unread one char
+// readToEnd() = read all data in the reader;
+// return a string.
+// beginReadToEnd(cb) = asynchronously read all data.
+//
+// =======================================================
+//
+// Derived in part from work by notmasteryet.
+// http://www.codeproject.com/KB/scripting/Javascript_binaryenc.aspx
+//
+// Copyleft (c) 2008, notmasteryet via an MIT-style license
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+
+(function(){
+ var version = "2.0 2012Feb";
+ var typename = "JSIO.TextReader";
+
+ if (typeof JSIO._ByteReaderBase !== "function")
+ JSIO.throwError('This extension requires JSIO.BasicByteReaders.js', typename);
+
+ var tr = function(textDecoder) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', typename, 'ctor');
+ this.decoder = textDecoder;
+ this._version = version;
+ this._typename = typename;
+ this.unreads = [];
+ };
+
+ // read one char
+ tr.prototype.readChar = function() {
+ return (this.unreads.length > 0) ? this.unreads.pop() : this.decoder.readChar();
+ };
+
+ // read a length of data
+ tr.prototype.read = function(n) {
+ // ANSI makes this easy
+ if (this.decoder.charWidth === 1) return JSIO.massApply(String.fromCharCode, new String, this.decoder.byteReader.read(n), true);
+
+ var s = "";
+ for (vari=0; i<n; i++) {
+ var ch = this.readChar();
+ if (ch !== null) s+= ch;
+ else break;
+ }
+ return s;
+ };
+
+ tr.prototype.unreadChar = function(ch) {
+ this.unreads.push(ch);
+ };
+
+ tr.prototype.readToEnd = function() {
+ // ANSI makes this easy
+ if (this.decoder.charWidth === 1) return JSIO.massApply(String.fromCharCode, new String, this.decoder.byteReader.readToEnd(n), true);
+
+ var slarge = "";
+ var s = "";
+ var c = 0;
+ var ch = this.readChar();
+ while(ch !== null) {
+ s += ch;
+ c++;
+ if(c >= 32768) {
+ slarge += s;
+ s = "";
+ c = 0;
+ }
+ ch = this.readChar();
+ }
+ return slarge + s;
+ };
+
+ tr.prototype.beginReadToEnd = function(callback) {
+ // ANSI makes this easy
+ if (this.decoder.charWidth === 1) {
+ this.decoder.byteReader.beginReadToEnd(function (bytes) {
+ callback( JSIO.massApply(String.fromCharCode, new String, bytes, true) );
+ });
+ return null;
+ }
+
+ var slarge = "";
+ var s = "";
+ var txtrdr = this;
+
+ var readBatchAsync = function() {
+ var c = 0;
+ var ch = txtrdr.readChar();
+ while(ch !== null) {
+ s += ch;c++;
+ if(c >= 32768) {
+ slarge += s;
+ s = "";
+ break;
+ }
+ ch = txtrdr.readChar();
+ }
+ if (ch!==null){
+ setTimeout(readBatchAsync, 1);
+ }
+ else {
+ callback(slarge+s);
+ }
+ };
+
+ // kickoff
+ setTimeout(readBatchAsync, 1); // always async, in ALL situations
+ return null;
+ };
+
+ tr.prototype.readLine = function() {
+ var s = "";
+ var ch = this.readChar();
+ if (ch === null) return null;
+
+ while(ch != "\r" && ch != "\n") {
+ s += ch;
+ ch = this.readChar();
+ if (ch === null) return s;
+ }
+ if(ch == "\r") {
+ ch = this.readChar();
+ if(ch !== null && ch != "\n"){
+ this.unreadChar(ch);
+ }
+ }
+ return s;
+ };
+
+ JSIO.TextReader = tr;
+
+})();
+
+
+/// JSIO.TextReader.js ends
+
+// JSIO.Crc32.js
+//
+// Part of the JSIO library. This adds an CRC32-calculating
+// ByteReader to JSIO.
+//
+// =======================================================
+//
+// A ByteReader exposes an interface with these functions:
+//
+// readByte()
+// must return null when EOF is reached.
+//
+// readToEnd()
+// returns an array of all bytes read, to EOF
+//
+// beginReadToEnd(callback)
+// async version of the above
+//
+// readBytes(n)
+// returns an array of all n bytes read from the source
+//
+// beginReadBytes(n, callback)
+// async version of the above
+//
+// =======================================================
+//
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+(function(){
+ var version = "2.0 2012Feb";
+ var typename = "JSIO.Crc32";
+
+ if (typeof JSIO._ByteReaderBase !== "function")
+ JSIO.throwError('This extension requires JSIO.BasicByteReaders.js', typename);
+
+ JSIO.crc32Table = null;
+ JSIO.crc32Polynomial = 0xEDB88320;
+
+ var crc32TableCalc = function () {
+ // do this once only, for all instances
+ if (JSIO.crc32Table) return;
+ JSIO.crc32Table = new Array(256);
+ for (var i = 0; i < 256; i++) {
+ var c=i;
+ for (var k = 0; k < 8; k++) {
+ if ((c & 1) == 1) c = JSIO.crc32Polynomial ^ (c>>>1);
+ else c >>>= 1;
+ }
+ JSIO.crc32Table[i] = c;
+ }
+ };
+
+ JSIO.computeCrc32 = function(str) {
+ crc32TableCalc(); // once
+ var c = 0xFFFFFFFF;
+ var sL = str.length;
+ if (typeof str == "object") {
+ for (var n1=0; n1<sL; n1++) {
+ c = JSIO.crc32Table[(c&0xff) ^ str[n1]] ^ (c>>>8);
+ }
+ } else {
+ for (var n2=0; n2<sL; n2++) {
+ c = JSIO.crc32Table[(c&0xff) ^ str.charCodeAt(n2)] ^ (c>>>8);
+ }
+ }
+ c ^= 0xFFFFFFFF;
+ if (c < 0) c += 0xFFFFFFFF+1;
+ return c;
+ };
+
+ // =======================================================
+ var _crc32 = function() {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', typename, 'ctor');
+ crc32TableCalc(); // once
+ this._typename = typename;
+ this._version = version;
+ this._runningCrc32 = 0xFFFFFFFF;
+ };
+
+ _crc32.prototype.slurpByte = function(b) {
+ var r = this._runningCrc32;
+ this._runningCrc32 = r>>>8 ^ JSIO.crc32Table[b ^ (r & 0x000000FF)];
+ };
+
+ _crc32.prototype.result = function() {
+ var c = this._runningCrc32 ^ 0xFFFFFFFF;
+ if (c < 0) c += 0xFFFFFFFF+1;
+ return c;
+ };
+ // =======================================================
+
+
+
+ var _crc32CalculatingReader = function(reader) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', 'JSIO.Crc32Reader', 'ctor');
+ this._byteReader = reader;
+ this._typename = "JSIO.Crc32Reader";
+ this._version = version;
+ this._crc32 = new JSIO.Crc32();
+ };
+
+ _crc32CalculatingReader.prototype = new JSIO._ByteReaderBase();
+
+ _crc32CalculatingReader.prototype.readByte = function() {
+ var b = this._byteReader.readByte();
+ if (b !== null) this._crc32.slurpByte(b);
+ this.position++;
+ return b;
+ };
+
+ _crc32CalculatingReader.prototype.read = function(len) {
+ if (len === 0) return [];
+ var bytes = this._byteReader.read(len);
+ len = bytes.length;
+
+ var tbl = JSIO.crc32Table;
+ var r = this._crc32._runningCrc32;
+ var t;
+ for (var i = 0; i < len; i++) {
+ t = tbl[ bytes[i] ^ (r & 0x000000FF) ];
+ r = (r >>> 8) ^ t;
+ }
+ this._crc32._runningCrc32 = r;
+
+ this.position += len;
+ return bytes;
+ }
+
+ _crc32CalculatingReader.prototype.crc32 = function() {
+ return this._crc32.result();
+ };
+
+ JSIO.Crc32 = _crc32;
+ JSIO.Crc32Reader = _crc32CalculatingReader;
+
+})();
+
+/// JSIO.CRC32.js ends
+// JSIO.InflatingReader.js
+// ------------------------------------------------------------------
+//
+// Part of the JSIO library. This adds an Inflating ByteReader to
+// JSIO.
+//
+// =======================================================
+//
+// A ByteReader exposes an interface with these functions:
+//
+// readByte()
+// must return null when EOF is reached.
+//
+// readToEnd()
+// returns an array of all bytes read, to EOF
+//
+// beginReadToEnd(callback)
+// async version of the above
+//
+// readBytes(n)
+// returns an array of all n bytes read from the source
+//
+// beginReadBytes(n, callback)
+// async version of the above
+//
+// =======================================================
+//
+// Derived in part from work by notmasteryet.
+// http://www.codeproject.com/KB/scripting/Javascript_binaryenc.aspx
+//
+// Copyleft (c) 2008, notmasteryet via an MIT-style license
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+
+(function(){
+ var version = "2.0 2012Feb";
+ var typename = "JSIO.InflatingReader";
+
+ if (typeof JSIO._ByteReaderBase !== "function")
+ JSIO.throwError('This extension requires JSIO.BasicByteReaders.js', typename);
+
+ // =======================================================
+ // _InternalBitReader is used internally in the InflatingReader class.
+ //
+
+ JSIO.bitShiftTable = null;
+
+ var bitShiftTableCalc = function () {
+ // do this once only, for all instances
+ if (JSIO.bitShiftTable) return;
+
+ var bits = 8;
+ JSIO.bitShiftTable = {
+ LSB: new Array(bits),
+ MSB: new Array(bits)
+ }
+ for (var bp = 0; bp < bits; bp++) {
+ var lim = bits - bp;
+ JSIO.bitShiftTable.LSB[bp] = new Array(lim);
+ JSIO.bitShiftTable.MSB[bp] = new Array(lim);
+
+ var maskLSB = 1 << bp;
+ var maskMSB = 1 << lim-1;
+ for (var len = 1; len <= lim; len++) {
+ JSIO.bitShiftTable.LSB[bp][len-1] = maskLSB;
+ JSIO.bitShiftTable.MSB[bp][len-1] = maskMSB;
+ maskLSB |= 1 << bp+len;
+ maskMSB |= 1 << lim-len-1;
+ }
+ }
+ };
+
+ var _InternalBitReader = function(reader) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', typename + '._InternalBitReader.ctor');
+ this.bitsLength = 0;
+ this.bits = 0;
+ this.byteReader = reader;
+ this._typeName = typename + "._InternalBitReader";
+ this._version = version;
+ bitShiftTableCalc();
+ };
+
+ _InternalBitReader.prototype._throwError = JSIO.throwError;
+
+ _InternalBitReader.prototype.readBit = function() {
+ if (this.bitsLength === 0) {
+ var nextByte = this.byteReader.readByte();
+ if (nextByte === null) this._throwError('Unexpected end of stream', null, 'readBit');
+ this.bits = nextByte;
+ this.bitsLength = 8;
+ }
+
+ var bit = (this.bits & 1 << 8-this.bitsLength) !== 0;
+ this.bitsLength--;
+ return bit;
+ };
+
+ _InternalBitReader.prototype.align = function() { this.bitsLength = 0; };
+
+ _InternalBitReader.prototype.readBits = function(len, type) {
+ var data = 0;
+ type = type || 'LSB';
+ var tbl = JSIO.bitShiftTable[type];
+ var dl = 0;
+ while (len > 0) {
+ if (this.bitsLength === 0) {
+ var nextByte = this.byteReader.readByte();
+ if (nextByte === null) this._throwError('Unexpected end of stream', null, 'read'+type);
+ this.bits = nextByte;
+ this.bitsLength = 8;
+ }
+
+ var maskLen = (this.bitsLength >= len) ? len : this.bitsLength;
+ var bitsPos = 8-this.bitsLength;
+ data |= (this.bits & tbl[bitsPos][maskLen-1]) >>> bitsPos << dl;
+
+ dl += maskLen;
+ len -= maskLen;
+ this.bitsLength -= maskLen;
+ };
+ return data;
+ };
+
+ _InternalBitReader.prototype.readLSB = function(len) { return this.readBits(len, 'LSB'); }
+ _InternalBitReader.prototype.readMSB = function(len) { return this.readBits(len, 'MSB'); }
+
+ //
+ // =======================================================
+
+
+ /* inflating ByteReader - RFC 1951 */
+ var _inflatingReader = function(reader) {
+ if (! (this instanceof arguments.callee) ) this._throwError('You must use new to instantiate this class', typename, 'ctor');
+ this._byteReader = reader;
+ this._bitReader = new _InternalBitReader(reader);
+ this._buffer = [];
+ this._bufferPosition = 0;
+ this._state = 0;
+ this._blockFinal = false;
+ this._typeName = typename;
+ this._version = version;
+ return this;
+ };
+
+
+ // shared fns and variables
+
+ var staticCodes = null;
+ var staticDistances = null;
+
+ var clenMap = [16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15];
+
+ var buildCodes = function(lengths){
+ var i=0;
+ var codes = new Array(lengths.length);
+ var maxBits = lengths[0];
+ for (i=1; i<lengths.length; i++) {
+ if (maxBits < lengths[i]) maxBits = lengths[i];
+ }
+
+ var bitLengthsCount = new Array(maxBits + 1);
+ for (i=0; i<=maxBits; i++) bitLengthsCount[i]=0;
+
+ for (i=0; i<lengths.length; i++) {
+ ++bitLengthsCount[lengths[i]];
+ }
+
+ var nextCode = new Array(maxBits + 1);
+ var code = 0;
+ bitLengthsCount[0] = 0;
+ for (var bits=1; bits<=maxBits; bits++) {
+ code = (code + bitLengthsCount[bits - 1]) << 1;
+ nextCode[bits] = code;
+ }
+
+ for (i=0; i<codes.length; i++) {
+ var len = lengths[i];
+ if (len !== 0) {
+ codes[i] = nextCode[len];
+ nextCode[len]++;
+ }
+ }
+ return codes;
+ };
+
+ var buildTree = function(codes, lengths){
+ var nonEmptyCodes = [];
+ for(var i=0; i<codes.length; ++i) {
+ if(lengths[i] > 0) {
+ var code = {};
+ code.bits = codes[i];
+ code.length = lengths[i];
+ code.index = i;
+ nonEmptyCodes.push(code);
+ }
+ }
+ return buildTreeBranch(nonEmptyCodes, 0, 0);
+ };
+
+
+ var buildTreeBranch = function(codes, prefix, prefixLength){
+ if (codes.length === 0) return null;
+
+ var zeros = [];
+ var ones = [];
+ var branch = {};
+ branch.isLeaf = false;
+ for(var i=0; i<codes.length; ++i) {
+ if (codes[i].length == prefixLength && codes[i].bits == prefix) {
+ branch.isLeaf = true;
+ branch.index = codes[i].index;
+ break;
+ }
+ else {
+ var nextBit = ((codes[i].bits >> (codes[i].length - prefixLength - 1)) & 1) > 0;
+ if (nextBit) ones.push(codes[i]);
+ else zeros.push(codes[i]);
+ }
+ }
+ if(!branch.isLeaf) {
+ branch.zero = buildTreeBranch(zeros, (prefix << 1), prefixLength + 1);
+ branch.one = buildTreeBranch(ones, (prefix << 1) | 1, prefixLength + 1);
+ }
+ return branch;
+ };
+
+
+ var encodedLengthStart = [3,4,5,6,7,8,9,10,
+ 11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,
+ 115,131,163,195,227,258];
+
+ var encodedLengthAdditionalBits = [0,0,0,0,0,0,0,0,
+ 1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0];
+
+ var encodedDistanceStart = [1,2,3,4, 5,7,9, 13,17,25, 33,49,65,
+ 97,129,193,257,385,513,769,1025,1537,2049,
+ 3073,4097,6145,8193,12289,16385,24577];
+
+ var encodedDistanceAdditionalBits = [0,0,0,0,1,1,2,2,3,3,4,4,
+ 5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13];
+
+
+ var readDynamicTrees = function(bitReader){
+ var hlit = bitReader.readLSB(5) + 257;
+ var hdist = bitReader.readLSB(5) + 1;
+ var hclen = bitReader.readLSB(4) + 4;
+ var clen = new Array(19);
+ var i;
+ for (i=0; i<clen.length; i++) { clen[i] = 0; }
+ for (i=0; i<hclen; i++) { clen[clenMap[i]] = bitReader.readLSB(3); }
+
+ var clenCodes = buildCodes(clen);
+ var clenTree = buildTree(clenCodes, clen);
+
+ var lengthsSequence = [];
+ while(lengthsSequence.length < hlit + hdist) {
+ var p = clenTree;
+ while(!p.isLeaf) { p = bitReader.readBit() ? p.one : p.zero; }
+
+ var code = p.index;
+ if (code <= 15) lengthsSequence.push(code);
+ else if (code == 16) {
+ // TODO: replace with faster repeat algorythm
+ var repeat = bitReader.readLSB(2) + 3;
+ for(var q=0; q<repeat; ++q){
+ lengthsSequence.push(lengthsSequence[lengthsSequence.length - 1]);
+ }
+ }
+ else if (code == 17) {
+ var repeat1 = bitReader.readLSB(3) + 3;
+ for(var q1=0; q1<repeat1; ++q1) {
+ lengthsSequence.push(0);
+ }
+ }
+ else if (code == 18) {
+ var repeat2 = bitReader.readLSB(7) + 11;
+ for(var q2=0; q2<repeat2; ++q2){
+ lengthsSequence.push(0);
+ }
+ }
+ }
+
+ var codesLengths = lengthsSequence.slice(0, hlit);
+ var codes = buildCodes(codesLengths);
+ var distancesLengths = lengthsSequence.slice(hlit, hlit + hdist);
+ var distances = buildCodes(distancesLengths);
+
+ return {
+ codesTree : buildTree(codes, codesLengths),
+ distancesTree : buildTree(distances, distancesLengths)
+ };
+ };
+
+
+ _inflatingReader.prototype = new JSIO._ByteReaderBase();
+
+
+ // internal instance fns
+ _inflatingReader.prototype._decodeItem = function() {
+ if (this._state == 2) return null; // end-of-blocks
+
+ var item;
+ if(this._state === 0) {
+ this._blockFinal = this._bitReader.readBit();
+ var blockType = this._bitReader.readLSB(2);
+ switch(blockType) {
+ case 0:
+ this._bitReader.align();
+ var len = this._bitReader.readLSB(16); // low-byte first, as opposed to readNumber's HBF
+ var nlen = this._bitReader.readLSB(16);
+ if ((len & ~nlen) != len) this._throwError('Invalid block type 0 length', null, '_decodeItem');
+
+ item = {};
+ item.itemType = 0;
+ item.array = this._bitReader.byteReader.read(len);
+ if (item.array.length < len) this._throwError('Incomplete block', null, '_decodeItem');
+ if (this._blockFinal) this._state = 2;
+ return item;
+ case 1:
+ this._codesTree = staticCodes;
+ this._distancesTree = staticDistances;
+ this._state = 1;
+ break;
+ case 2:
+ var dTrees = readDynamicTrees(this._bitReader);
+ this._codesTree = dTrees.codesTree;
+ this._distancesTree = dTrees.distancesTree;
+ this._state = 1;
+ break;
+ default:
+ this._throwError('Invalid block type ('+ blockType +')', null, '_decodeItem');
+ }
+ }
+
+ item = {};
+
+ var p = this._codesTree;
+ while (!p.isLeaf) { p = this._bitReader.readBit() ? p.one : p.zero; }
+ if(p.index < 256) {
+ item.itemType = 2;
+ item.symbol = p.index;
+ } else if(p.index > 256) {
+ var lengthCode = p.index;
+ if(lengthCode > 285) this._throwError('Invalid length code', null, '_decodeItem');
+
+ var length = encodedLengthStart[lengthCode - 257];
+ if(encodedLengthAdditionalBits[lengthCode - 257] > 0) {
+ length += this._bitReader.readLSB(encodedLengthAdditionalBits[lengthCode - 257]);
+ }
+
+ p = this._distancesTree;
+ while (!p.isLeaf) { p = this._bitReader.readBit() ? p.one : p.zero; }
+
+ var distanceCode = p.index;
+ var distance = encodedDistanceStart[distanceCode];
+ if (encodedDistanceAdditionalBits[distanceCode] > 0)
+ distance += this._bitReader.readLSB(encodedDistanceAdditionalBits[distanceCode]);
+
+ item.itemType = 3;
+ item.distance = distance;
+ item.length = length;
+ } else {
+ item.itemType = 1;
+ this._state = this._blockFinal ? 2 : 0; // EOB
+ }
+ return item;
+ };
+
+
+
+ // public instance functions
+
+ _inflatingReader.prototype.readByte = function() {
+ var byte = this.read(1)[0];
+ return (byte === null || byte === undefined) ? null : byte;
+ };
+
+ _inflatingReader.prototype.read = function(len) {
+ var b = this._buffer; // (since we use this so much...)
+
+ // Keep reading until we get to the right length
+ while (this._bufferPosition+len > b.length) {
+ var item = this._decodeItem();
+ if (item === null) { // EOF
+ len = b.length - this._bufferPosition;
+ break;
+ }
+ switch(item.itemType) {
+ case 0:
+ JSIO.massApply(b.push, b, item.array);
+ break;
+ case 2:
+ b.push(item.symbol);
+ break;
+ case 3:
+ var j = b.length - item.distance;
+ if (item.distance >= item.length)
+ JSIO.massApply(b.push, b, b.slice(j, j+item.length));
+ // sometimes DEFLATE tries some trickery with "look-ahead" compression
+ else {
+ // this is basically just a repetition of the same string, plus some possible cutoff
+ var count = parseInt(item.length / item.distance);
+ var repArr = b.slice(j);
+ // http://stackoverflow.com/questions/202605/repeat-string-javascript/5450113#5450113
+ while (count > 0) {
+ if (count & 1) JSIO.massApply( b.push, b, repArr);
+ if (count >>= 1) JSIO.massApply(repArr.push, repArr, repArr);
+ }
+ // add any remaining cutoff
+ var r;
+ if (r = item.length % item.distance)
+ JSIO.massApply(b.push, b, b.slice(j, j+r));
+ }
+ break;
+ }
+ }
+ var bytes = b.slice(this._bufferPosition, this._bufferPosition+len);
+ this._bufferPosition += len;
+ this.position += len;
+
+ if (this._bufferPosition > 0xC000) {
+ var shift = b.length - 0x8000;
+ if (shift > this._bufferPosition) shift = this._bufferPosition;
+ b.splice(0, shift);
+ this._bufferPosition -= shift;
+ }
+
+ return bytes;
+ };
+
+ // initialization routine - once per type
+ (function(){
+
+ var codes = new Array(288);
+ var codesLengths = new Array(288);
+ var i=0;
+ for ( i = 0; i <= 143; i++) {
+ codes[i] = 0x0030 + i;
+ codesLengths[i] = 8;
+ }
+ for ( i = 144; i <= 255; i++) {
+ codes[i] = 0x0190 + i - 144;
+ codesLengths[i] = 9;
+ }
+ for ( i = 256; i <= 279; i++) {
+ codes[i] = 0x0000 + i - 256;
+ codesLengths[i] = 7;
+ }
+ for ( i = 280; i <= 287; i++) {
+ codes[i] = 0x00C0 + i - 280;
+ codesLengths[i] = 8;
+ }
+ staticCodes = buildTree(codes, codesLengths);
+
+ var distances = new Array(32);
+ var distancesLengths = new Array(32);
+ for ( i = 0; i <= 31; i++) {
+ distances[i] = i;
+ distancesLengths[i] = 5;
+ }
+ staticDistances = buildTree(distances, distancesLengths);
+ })();
+
+
+ JSIO.InflatingReader = _inflatingReader;
+
+})();
+
+
+/// JSIO.InflatingReader.js ends
+
+// Zipfile.js
+// ------------------------------------------------------------------
+//
+// A class that reads Zip files.
+// Depends on the JSIO library functions.
+//
+// =======================================================
+//
+// Copyleft (c) 2010, Dino Chiesa via MS-PL
+// Copyleft (c) 2012, Brendan Byrd via GPL
+//
+// This work is licensed under the GPLv3.
+
+(function(){
+ var version = "2.0 2012Feb";
+ var typename = "Zipfile";
+
+ if (typeof JSIO.BinaryUrlStream !== "function") JSIO.throwError('This extension requires JSIO.BinaryUrlStream.js v2.0', typename);
+ if (typeof JSIO.TextDecoder !== "object") JSIO.throwError('This extension requires JSIO.TextDecoder.js v2.0', typename);
+ if (typeof JSIO.TextReader !== "function") JSIO.throwError('This extension requires JSIO.TextReader.js v2.0', typename);
+ if (typeof JSIO.Crc32 !== "function") JSIO.throwError('This extension requires JSIO.Crc32.js v2.0', typename);
+ if (typeof JSIO.InflatingReader !== "function") JSIO.throwError('This extension requires JSIO.InflatingReader.js v2.0', typename);
+
+ // =======================================================
+ function ZipEntry(zip) {
+ this.zipfile = zip;
+ this._typename = "ZipEntry";
+ this._version = version;
+ this._crcCalculator = null;
+ }
+
+ ZipEntry.prototype._throwError = JSIO.throwError;
+
+ // return byte array or string
+ ZipEntry.prototype.extract = function(callback, asString) {
+ this.contentType = JSIO.guessFileType(this.name);
+ asString = asString || ( this.contentType == JSIO.FileType.Text ||
+ this.contentType == JSIO.FileType.XML);
+ var thisEntry = this;
+
+ if (this.compressionMethod !== 0 && this.compressionMethod != 8)
+ this._throwError('Unsupported compression method: ' + this.compressionMethod, null, 'extract');
+
+ var reader = (asString) ? this.openTextReader(thisEntry.utf8 ? JSIO.TextDecoder.UTF8 : JSIO.TextDecoder.ANSI) : this.openBinaryReader();
+
+ // diagnostic purpose only; tag the reader with the entry name
+ reader.zipEntryName = thisEntry.name;
+
+ if (typeof callback != "function") {
+ // synchronous
+ var result = reader.readToEnd();
+ this.verifyCrc32();
+ return result;
+ }
+
+ // asynchronous
+ reader.beginReadToEnd(function(result){
+ try {
+ thisEntry.verifyCrc32();
+ callback(thisEntry, result);
+ }
+ catch (exc1) {
+ callback(thisEntry, exc1);
+ }
+ });
+ return null;
+ };
+
+
+ // open a ByteReader on the entry, which will read binary
+ // content from the compressed stream.
+ ZipEntry.prototype.openBinaryReader = function() {
+ var reader =
+ new JSIO.StreamSegmentReader(this.zipfile.binaryStream,
+ this.offset + this.lengthOfHeader,
+ this.compressedSize);
+ if (this.compressionMethod === 0) {
+ this._crcCalculator = new JSIO.Crc32Reader(reader);
+ }
+ else {
+ var inflator = new JSIO.InflatingReader(reader);
+ this._crcCalculator = new JSIO.Crc32Reader(inflator);
+ }
+ // Whether compressed or not, the source ByteReader in each case
+ // is wrapped in a second ByteReader object that calculates CRC
+ // as it reads. That way, after all reading is complete, the
+ // caller can check the calcuated CRC against the expected CRC.
+ return this._crcCalculator;
+ };
+
+ // open a TextReader on the entry, to read text from the
+ // compressed stream.
+ ZipEntry.prototype.openTextReader = function(decoderKind) {
+ var reader = this.openBinaryReader();
+ decoderKind = decoderKind || JSIO.TextDecoder.UTF8;
+ var d = new decoderKind(reader);
+ var textReader = new JSIO.TextReader(d);
+ d._parent = textReader; // store a reference, for diagnostic purposes only
+ return textReader;
+ };
+
+ // verify the CRC on the entry.
+ // call this after all bytes have been read.
+ ZipEntry.prototype.verifyCrc32 = function() {
+ var computedCrc = this._crcCalculator.crc32();
+ var rc = false; // CRC FAIL
+ if (this.crc32 != computedCrc) {
+ var msg = "WARNING: CRC check failed: " +
+ "entry(" + this.name + ") " +
+ "computed(" + JSIO.decimalToHexString(computedCrc,8) + ") " +
+ "expected(" + JSIO.decimalToHexString(this.crc32,8) + ") ";
+ this.zipfile.status.push(msg);
+ } else {
+ rc = true; // OK
+ if (this.zipfile.verbose>2) {
+ this.zipfile.status.push("INFO: CRC check ok: 0x" +
+ JSIO.decimalToHexString(this.crc32,8));
+ }
+ }
+ return rc;
+ };
+
+
+ // ctor
+ ZipFile = function(fileUrl, callback, verbosity) {
+ if (! (this instanceof arguments.callee) ) JSIO.throwError('You must use new to instantiate this class', typename, 'ctor');
+
+ this.verbose = verbosity || 0;
+ this.entries = [];
+ this.entryNames = [];
+ this.status = [];
+ this._version = version;
+ this._typename = "ZipFile";
+ this._throwError = JSIO.throwError;
+
+ var thisZipFile = this;
+
+ // Could use a back-tracking reader for the central directory, but
+ // there's no point, since all the zip data is held in memory anyway.
+
+ /* function ReadCentralDirectory(){
+ var posn = thisZipFile.binaryStream.length - 64;
+ var maxSeekback = Math.Max(s.Length - 0x4000, 10);
+ var success = false;
+ var nTries = 0;
+ do
+ {
+ thisZipFile.binaryStream.Seek(posn, SeekOrigin.Begin);
+ var bytesRead = thisZipFile.binaryStream.findSignature(thisZipFile.Signatures.EndOfCentralDirectory);
+ if (bytesRead != -1)
+ success = true;
+ else
+ {
+ nTries++;
+ // increasingly larger
+ posn -= (32 * (nTries + 1) * nTries);
+ if (posn < 0) posn = 0; // BOF
+ }
+ }
+ while (!success && posn > maxSeekback);
+ if (!success) {
+ thisZipFile.status.push("cannot find End of Central Directory");
+ return;
+ }
+ } */
+
+
+ function DateFromPackedFormat(packed) {
+ if (packed == 0xFFFF || packed === 0) return new Date(1995, 0, 1, 0,0,0,0);
+
+ var packedTime = packed & 0x0000ffff;
+ var packedDate = ((packed & 0xffff0000) >> 16);
+
+ var year = 1980 + ((packedDate & 0xFE00) >> 9);
+ var month = ((packedDate & 0x01E0) >> 5) -1;
+ var day = packedDate & 0x001F;
+
+ var hour = (packedTime & 0xF800) >> 11;
+ var minute = (packedTime & 0x07E0) >> 5;
+ var second = (packedTime & 0x001F) * 2;
+
+ // Validation and error checking.
+ // This is not foolproof but will catch most errors.
+
+ // I can't believe how many different ways applications
+ // can mess up a simple date format.
+
+ if (second >= 60) { minute++; second = 0; }
+ if (minute >= 60) { hour++; minute = 0; }
+ if (hour >= 24) { day++; hour = 0; }
+ var success = false;
+ var d;
+ try {
+ d = new Date(year, month, day, hour, minute, second, 0);
+ success= true;
+ }
+ catch (exc1) {
+ if (year == 1980 && (month === 0 || day === 0)) {
+ try {
+ d = new Date(1980, 0, 1, hour, minute, second, 0);
+ success= true;
+ }
+ catch (exc2) {
+ try {
+ d = new Date(1980, 0, 1, 0, 0, 0, 0);
+ success= true;
+ }
+ catch (exc3) { } // how could this fail??
+ }
+ }
+ else {
+ try {
+ if (year < 1980) year = 1980;
+ if (year > 2030) year = 2030;
+ if (month < 1) month = 1;
+ if (month > 12) month = 12;
+ if (day < 1) day = 1;
+ if (day > 31) day = 31;
+ if (minute < 0) minute = 0;
+ if (minute > 59) minute = 59;
+ if (second < 0) second = 0;
+ if (second > 59) second = 59;
+ d = new Date(year, month-1, day, hour, minute, second, 0);
+ success= true;
+ }
+ catch (exc4){}
+ }
+ }
+ if (!success) this._throwError('Bad date/time value in this ZIP file', null, 'DateFromPackedFormat');
+ return d;
+ }
+
+
+ function ReadZipEntries () {
+ // read only once
+ if (thisZipFile.entryNames.length === 0){
+ var e;
+ while ((e = ReadZipEntry()) !== null) {
+ thisZipFile.entries.push(e);
+ thisZipFile.entryNames.push(e.name);
+ }
+ }
+ }
+
+
+ function ReadZipEntry () {
+ var offset = thisZipFile.binaryStream.position;
+ var sig = thisZipFile.binaryStream.readNumber(4);
+ if (sig == ZipFile.Signatures.DirEntry) {
+ // after all entries, comes the central directory
+ if (thisZipFile.verbose > 0) {
+ thisZipFile.status.push("INFO: at offset 0x" +
+ JSIO.decimalToHexString(offset) +
+ ", found start of Zip Directory.");
+ }
+ // all done reading
+ return null;
+ }
+ if (sig != ZipFile.Signatures.Entry) {
+ thisZipFile.status.push("WARNING: at offset 0x" +
+ JSIO.decimalToHexString(offset) +
+ ", found unexpected signature: 0x" +
+ JSIO.decimalToHexString(sig));
+ return null;
+ }
+
+ var entry = new ZipEntry(thisZipFile);
+ entry.offset = offset;
+ entry.versionNeeded = thisZipFile.binaryStream.readNumber(2);
+ entry.bitField = thisZipFile.binaryStream.readNumber(2);
+ entry.compressionMethod = thisZipFile.binaryStream.readNumber(2);
+ var timeBlob = thisZipFile.binaryStream.readNumber(4);
+ entry.lastModified = DateFromPackedFormat(timeBlob);
+ entry.crc32 = thisZipFile.binaryStream.readNumber(4);
+ entry.compressedSize = thisZipFile.binaryStream.readNumber(4);
+ entry.uncompressedSize = thisZipFile.binaryStream.readNumber(4);
+
+ if ((entry.bitField & 0x01) == 0x01){
+ thisZipFile.status.push("This zipfile uses Encryption, which is not supported by ZipFile.js.");
+ return null;
+ }
+
+ entry.utf8 = ((entry.bitField & 0x0800) == 0x0800);
+
+ if ((entry.bitField & 0x0008) == 0x0008){
+ thisZipFile.status.push("This zipfile uses a bit 3 trailing data descriptor, which is not supported by ZipFile.js.");
+ return null;
+ }
+
+ if (entry.compressedSize == 0xFFFFFFFF ||
+ entry.uncompressedSize == 0xFFFFFFFF) {
+ thisZipFile.status.push("This zipfile uses ZIP64, which is not supported by ZipFile.js");
+ return null;
+ }
+
+ var filenameLength = thisZipFile.binaryStream.readNumber(2);
+ var extraFieldLength = thisZipFile.binaryStream.readNumber(2);
+
+ thisZipFile.status.push("INFO: filename length= " + filenameLength);
+
+ // we've read 30 bytes of metadata so far
+ var bytesRead = 30 + filenameLength + extraFieldLength;
+
+ if (entry.utf8) {
+ thisZipFile.status.push("INFO: before filename, position= 0x" +
+ JSIO.decimalToHexString( thisZipFile.binaryStream.position ));
+ var binReader =
+ new JSIO.StreamSegmentReader(thisZipFile.binaryStream,
+ thisZipFile.binaryStream.position,
+ filenameLength);
+ var utf8Decoder = new JSIO.TextDecoder.UTF8(binReader);
+ var textReader = new JSIO.TextReader(utf8Decoder);
+ entry.name = textReader.readToEnd();
+
+ // advance the filepointer:
+ thisZipFile.binaryStream.seek(filenameLength,
+ JSIO.SeekOrigin.Current,
+ thisZipFile);
+
+ thisZipFile.status.push("INFO: after filename, position= 0x" +
+ JSIO.decimalToHexString( thisZipFile.binaryStream.position ));
+ }
+ else {
+ entry.name = thisZipFile.binaryStream.readString(filenameLength);
+ }
+
+ // There are a bunch of things in the "extra" header, thisZipFile we
+ // could parse, like timestamps and other things. This class
+ // only identifies and separates them.
+
+ // More info here: http://www.pkware.com/documents/casestudies/APPNOTE.TXT
+
+ var extraPos = 0;
+ entry.extra = [];
+ while (extraPos < extraFieldLength) {
+ var extraBlock = {
+ type: thisZipFile.binaryStream.readNumber(2),
+ size: thisZipFile.binaryStream.readNumber(2)
+ };
+ extraBlock.typeDescription = ZipFile.ExtraFieldTypes[extraBlock.type];
+ extraBlock.data = thisZipFile.binaryStream.read(extraBlock.size);
+ entry.extra.push(extraBlock);
+ extraPos += 4 + extraBlock.size;
+ }
+
+ if (thisZipFile.verbose > 1) {
+ thisZipFile.status.push("INFO: at offset 0x" +
+ JSIO.decimalToHexString(entry.offset) +
+ ", found entry '" + entry.name + "' fnl(" +
+ filenameLength + ") efl(" +
+ extraFieldLength +")");
+ }
+
+ if (extraFieldLength > 0) {
+ if (thisZipFile.verbose > 0) {
+ thisZipFile.status.push("INFO: entry " + entry.name + " has " +
+ extraFieldLength + " bytes of " +
+ "extra metadata (ID'd but ignored)");
+ }
+ }
+
+ entry.lengthOfHeader = bytesRead;
+ entry.totalEntrySize = entry.lengthOfHeader + entry.compressedSize;
+
+ // seek past the data without reading it. We will read on Extract()
+ if (thisZipFile.verbose > 1) {
+ thisZipFile.status.push("INFO: seek 0x" +
+ JSIO.decimalToHexString(entry.compressedSize) +
+ " (" + entry.compressedSize + ") bytes");
+ }
+
+ thisZipFile.binaryStream.seek(entry.compressedSize,
+ JSIO.SeekOrigin.Current,
+ thisZipFile);
+
+ return entry;
+ }
+
+
+ var parseZipFile = function(bfr){
+ try {
+ if (bfr.req.status == 200) {
+ var sig = thisZipFile.binaryStream.readNumber(4);
+ if (sig != ZipFile.Signatures.Entry){
+ thisZipFile.status.push("WARNING: this file does not appear to be a zip file");
+ } else {
+ thisZipFile.binaryStream.seek(0, JSIO.SeekOrigin.Begin);
+ ReadZipEntries();
+ if (thisZipFile.verbose > 0) {
+ thisZipFile.status.push("INFO: read " + thisZipFile.entries.length + " entries");
+ }
+ }
+ }
+ else {
+ thisZipFile.status.push("ERROR: the URL could not be read (" +
+ bfr.req.status + " " + bfr.req.statusText + ")");
+ }
+ callback(thisZipFile);
+ }
+ catch (exc1)
+ {
+ thisZipFile.status.push("Exception: " + exc1.message);
+ callback(thisZipFile);
+ }
+ };
+
+ this.binaryStream = new JSIO.BinaryUrlStream(fileUrl, parseZipFile);
+
+ return this;
+ };
+
+
+ ZipFile.Signatures = {
+ Entry : 0x04034b50,
+ EndOfCentralDirectory : 0x06054b50,
+ DirEntry : 0x02014b50
+ };
+
+ ZipFile.Version = version;
+
+ ZipFile.EncryptionAlgorithm = {
+ None : 0,
+ PkzipWeak : 1,
+ WinZipAes : 2
+ };
+
+ ZipFile.ExtraFieldTypes = {};
+ ZipFile.ExtraFieldTypes[0x0001] = 'Zip64 Extended Info';
+ ZipFile.ExtraFieldTypes[0x0007] = 'AV Info';
+ ZipFile.ExtraFieldTypes[0x0008] = 'Extended Language Encoding Data (PFS)';
+ ZipFile.ExtraFieldTypes[0x0009] = 'OS/2';
+ ZipFile.ExtraFieldTypes[0x000a] = 'NTFS ';
+ ZipFile.ExtraFieldTypes[0x000c] = 'OpenVMS';
+ ZipFile.ExtraFieldTypes[0x000d] = 'UNIX';
+ ZipFile.ExtraFieldTypes[0x000e] = 'File Stream and Fork Descriptors';
+ ZipFile.ExtraFieldTypes[0x000f] = 'Patch Descriptor';
+ ZipFile.ExtraFieldTypes[0x0014] = 'PKCS#7 Store for X.509 Certificates';
+ ZipFile.ExtraFieldTypes[0x0015] = 'X.509 Certificate ID and Signature (Individual File)';
+ ZipFile.ExtraFieldTypes[0x0016] = 'X.509 Certificate ID (Central Directory)';
+ ZipFile.ExtraFieldTypes[0x0017] = 'Strong Encryption Header';
+ ZipFile.ExtraFieldTypes[0x0018] = 'Record Management Controls';
+ ZipFile.ExtraFieldTypes[0x0019] = 'PKCS#7 Encryption Recipient Certificate List';
+ ZipFile.ExtraFieldTypes[0x0065] = 'IBM S/390 (Z390), AS/400 (I400) attributes (uncompressed)';
+ ZipFile.ExtraFieldTypes[0x0066] = 'IBM S/390 (Z390), AS/400 (I400) attributes (compressed)';
+ ZipFile.ExtraFieldTypes[0x4690] = 'POSZIP 4690 (reserved) ';
+ ZipFile.ExtraFieldTypes[0x07c8] = 'Macintosh';
+ ZipFile.ExtraFieldTypes[0x2605] = 'ZipIt Macintosh';
+ ZipFile.ExtraFieldTypes[0x2705] = 'ZipIt Macintosh 1.3.5+';
+ ZipFile.ExtraFieldTypes[0x2805] = 'ZipIt Macintosh 1.3.5+';
+ ZipFile.ExtraFieldTypes[0x334d] = 'Info-ZIP Macintosh';
+ ZipFile.ExtraFieldTypes[0x4341] = 'Acorn/SparkFS ';
+ ZipFile.ExtraFieldTypes[0x4453] = 'Windows NT security descriptor (binary ACL)';
+ ZipFile.ExtraFieldTypes[0x4704] = 'VM/CMS';
+ ZipFile.ExtraFieldTypes[0x470f] = 'MVS';
+ ZipFile.ExtraFieldTypes[0x4b46] = 'FWKCS MD5';
+ ZipFile.ExtraFieldTypes[0x4c41] = 'OS/2 access control list (text ACL)';
+ ZipFile.ExtraFieldTypes[0x4d49] = 'Info-ZIP OpenVMS';
+ ZipFile.ExtraFieldTypes[0x4f4c] = 'Xceed original location extra field';
+ ZipFile.ExtraFieldTypes[0x5356] = 'AOS/VS (ACL)';
+ ZipFile.ExtraFieldTypes[0x5455] = 'extended timestamp';
+ ZipFile.ExtraFieldTypes[0x554e] = 'Xceed unicode extra field';
+ ZipFile.ExtraFieldTypes[0x5855] = 'Info-ZIP UNIX (original, also OS/2, NT, etc)';
+ ZipFile.ExtraFieldTypes[0x6375] = 'Info-ZIP Unicode Comment Extra Field';
+ ZipFile.ExtraFieldTypes[0x6542] = 'BeOS/BeBox';
+ ZipFile.ExtraFieldTypes[0x7075] = 'Info-ZIP Unicode Path Extra Field';
+ ZipFile.ExtraFieldTypes[0x756e] = 'ASi UNIX';
+ ZipFile.ExtraFieldTypes[0x7855] = 'Info-ZIP UNIX (new)';
+ ZipFile.ExtraFieldTypes[0xa220] = 'Microsoft Open Packaging Growth Hint';
+ ZipFile.ExtraFieldTypes[0xfd4a] = 'SMS/QDOS';
+
+})();
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/geoxml3.js b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/geoxml3.js
new file mode 100644
index 00000000..6cc72d79
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/geoxml3/geoxml3.js
@@ -0,0 +1,1855 @@
+/**
+ * @fileOverview Renders KML on the Google Maps JavaScript API Version 3
+ * @name GeoXML3
+ * @author Sterling Udell, Larry Ross, Brendan Byrd
+ * @see http://code.google.com/p/geoxml3/
+ *
+ * geoxml3.js
+ *
+ * Renders KML on the Google Maps JavaScript API Version 3
+ * http://code.google.com/p/geoxml3/
+ *
+ * Copyright 2010 Sterling Udell, Larry Ross
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+if (!String.prototype.trim) {
+/**
+ * Remove leading and trailing whitespace.
+ *
+ * @augments String
+ * @return {String}
+ */
+ String.prototype.trim = function () {
+ return this.replace(/^\s+|\s+$/g, '');
+ };
+}
+
+/**
+ * @namespace The GeoXML3 namespace.
+ */
+geoXML3 = window.geoXML3 || {instances: []};
+
+/**
+ * Constructor for the root KML parser object.
+ *
+ * <p>All top-level objects and functions are declared under a namespace of geoXML3.
+ * The core object is geoXML3.parser; typically, you'll instantiate a one parser
+ * per map.</p>
+ *
+ * @class Main XML parser.
+ * @param {geoXML3.parserOptions} options
+ */
+geoXML3.parser = function (options) {
+ // Private variables
+ var parserOptions = new geoXML3.parserOptions(options);
+ var docs = []; // Individual KML documents
+ var docsByUrl = {}; // Same docs as an hash by cleanURL
+ var kmzMetaData = {}; // Extra files from KMZ data
+ var styles = {}; // Global list of styles
+ var lastPlacemark;
+ var parserName;
+ if (!parserOptions.infoWindow && parserOptions.singleInfoWindow)
+ parserOptions.infoWindow = new google.maps.InfoWindow();
+
+ var parseKmlString = function (kmlString, docSet) {
+ // Internal values for the set of documents as a whole
+ var internals = {
+ parser: this,
+ docSet: docSet || [],
+ remaining: 1,
+ parseOnly: !(parserOptions.afterParse || parserOptions.processStyles)
+ };
+ thisDoc = new Object();
+ thisDoc.internals = internals;
+ internals.docSet.push(thisDoc);
+ render(geoXML3.xmlParse(kmlString),thisDoc);
+ }
+
+ var parse = function (urls, docSet) {
+ // Process one or more KML documents
+ if (!parserName) {
+ parserName = 'geoXML3.instances[' + (geoXML3.instances.push(this) - 1) + ']';
+ }
+
+ if (typeof urls === 'string') {
+ // Single KML document
+ urls = [urls];
+ }
+
+ // Internal values for the set of documents as a whole
+ var internals = {
+ parser: this,
+ docSet: docSet || [],
+ remaining: urls.length,
+ parseOnly: !(parserOptions.afterParse || parserOptions.processStyles)
+ };
+ var thisDoc, j;
+ for (var i = 0; i < urls.length; i++) {
+ var baseUrl = cleanURL(defileURL(location.pathname), urls[i]);
+ if (docsByUrl[baseUrl]) {
+ // Reloading an existing document
+ thisDoc = docsByUrl[baseUrl];
+ thisDoc.reload = true;
+ }
+ else {
+ thisDoc = new Object();
+ thisDoc.baseUrl = baseUrl;
+ internals.docSet.push(thisDoc);
+ }
+ thisDoc.url = urls[i];
+ thisDoc.internals = internals;
+ fetchDoc(thisDoc.url, thisDoc);
+ }
+ };
+
+ function fetchDoc(url, doc, resFunc) {
+ resFunc = resFunc || function (responseXML) { render(responseXML, doc); };
+
+ if (typeof ZipFile === 'function' && typeof JSIO === 'object' && typeof JSIO.guessFileType === 'function') { // KMZ support requires these modules loaded
+ contentType = JSIO.guessFileType(doc.baseUrl);
+ if (contentType == JSIO.FileType.Binary || contentType == JSIO.FileType.Unknown) {
+ doc.isCompressed = true;
+ doc.baseDir = doc.baseUrl + '/';
+ geoXML3.fetchZIP(url, resFunc, doc.internals.parser);
+ return;
+ }
+ }
+ doc.isCompressed = false;
+ doc.baseDir = defileURL(doc.baseUrl);
+ geoXML3.fetchXML(url, resFunc);
+ }
+
+ var hideDocument = function (doc) {
+ if (!doc) doc = docs[0];
+ // Hide the map objects associated with a document
+ var i;
+ if (!!doc.markers) {
+ for (i = 0; i < doc.markers.length; i++) {
+ if(!!doc.markers[i].infoWindow) doc.markers[i].infoWindow.close();
+ doc.markers[i].setVisible(false);
+ }
+ }
+ if (!!doc.ggroundoverlays) {
+ for (i = 0; i < doc.ggroundoverlays.length; i++) {
+ doc.ggroundoverlays[i].setOpacity(0);
+ }
+ }
+ if (!!doc.gpolylines) {
+ for (i=0;i<doc.gpolylines.length;i++) {
+ if(!!doc.gpolylines[i].infoWindow) doc.gpolylines[i].infoWindow.close();
+ doc.gpolylines[i].setMap(null);
+ }
+ }
+ if (!!doc.gpolygons) {
+ for (i=0;i<doc.gpolygons.length;i++) {
+ if(!!doc.gpolygons[i].infoWindow) doc.gpolygons[i].infoWindow.close();
+ doc.gpolygons[i].setMap(null);
+ }
+ }
+ };
+
+ var showDocument = function (doc) {
+ if (!doc) doc = docs[0];
+ // Show the map objects associated with a document
+ var i;
+ if (!!doc.markers) {
+ for (i = 0; i < doc.markers.length; i++) {
+ doc.markers[i].setVisible(true);
+ }
+ }
+ if (!!doc.ggroundoverlays) {
+ for (i = 0; i < doc.ggroundoverlays.length; i++) {
+ doc.ggroundoverlays[i].setOpacity(doc.ggroundoverlays[i].percentOpacity_);
+ }
+ }
+ if (!!doc.gpolylines) {
+ for (i=0;i<doc.gpolylines.length;i++) {
+ doc.gpolylines[i].setMap(parserOptions.map);
+ }
+ }
+ if (!!doc.gpolygons) {
+ for (i=0;i<doc.gpolygons.length;i++) {
+ doc.gpolygons[i].setMap(parserOptions.map);
+ }
+ }
+ };
+
+ var defaultStyle = {
+ balloon: {
+ bgColor: 'ffffffff',
+ textColor: 'ff000000',
+ text: "<h3>$[name]</h3>\n<div>$[description]</div>\n<div>$[geDirections]</div>",
+ displayMode: 'default'
+ },
+ icon: {
+ scale: 1.0,
+ dim: {
+ x: 0,
+ y: 0,
+ w: -1,
+ h: -1
+ },
+ hotSpot: {
+ x: 0.5,
+ y: 0.5,
+ xunits: 'fraction',
+ yunits: 'fraction'
+ }
+ },
+ line: {
+ color: 'ffffffff', // white (KML default)
+ colorMode: 'normal',
+ width: 1.0
+ },
+ poly: {
+ color: 'ffffffff', // white (KML default)
+ colorMode: 'normal',
+ fill: true,
+ outline: true
+ }
+ };
+
+ var kmlNS = 'http://www.opengis.net/kml/2.2';
+ var gxNS = 'http://www.google.com/kml/ext/2.2';
+ var nodeValue = geoXML3.nodeValue;
+ var getBooleanValue = geoXML3.getBooleanValue;
+ var getElementsByTagNameNS = geoXML3.getElementsByTagNameNS;
+ var getElementsByTagName = geoXML3.getElementsByTagName;
+
+function processStyleUrl(node) {
+ var styleUrlStr = nodeValue(getElementsByTagName(node, 'styleUrl')[0]);
+ if (!!styleUrlStr && styleUrlStr.indexOf('#') != -1)
+ var styleUrl = styleUrlStr.split('#');
+ else var styleUrl = ["",""];
+ return styleUrl;
+}
+
+ function processStyle(thisNode, baseUrl, styleID, baseDir) {
+ var style = (baseUrl === '{inline}') ? clone(defaultStyle) : (styles[baseUrl][styleID] = styles[baseUrl][styleID] || clone(defaultStyle));
+
+ var styleNodes = getElementsByTagName(thisNode, 'BalloonStyle');
+ if (!!styleNodes && styleNodes.length > 0) {
+ style.balloon.bgColor = nodeValue(getElementsByTagName(styleNodes[0], 'bgColor')[0], style.balloon.bgColor);
+ style.balloon.textColor = nodeValue(getElementsByTagName(styleNodes[0], 'textColor')[0], style.balloon.textColor);
+ style.balloon.text = nodeValue(getElementsByTagName(styleNodes[0], 'text')[0], style.balloon.text);
+ style.balloon.displayMode = nodeValue(getElementsByTagName(styleNodes[0], 'displayMode')[0], style.balloon.displayMode);
+ }
+
+ // style.list = (unsupported; doesn't make sense in Google Maps)
+
+ var styleNodes = getElementsByTagName(thisNode, 'IconStyle');
+ if (!!styleNodes && styleNodes.length > 0) {
+ var icon = style.icon;
+
+ icon.scale = parseFloat(nodeValue(getElementsByTagName(styleNodes[0], 'scale')[0], icon.scale));
+ // style.icon.heading = (unsupported; not supported in API)
+ // style.icon.color = (unsupported; not supported in API)
+ // style.icon.colorMode = (unsupported; not supported in API)
+
+ styleNodes = getElementsByTagName(thisNode, 'Icon');
+ if (!!styleNodes && styleNodes.length > 0) {
+ icon.href = nodeValue(getElementsByTagName(styleNodes[0], 'href')[0]);
+ icon.url = cleanURL(baseDir, icon.href);
+ // Detect images buried in KMZ files (and use a base64 encoded URL)
+ if (kmzMetaData[icon.url]) icon.url = kmzMetaData[icon.url].dataUrl;
+
+ // Support for icon palettes and exact size dimensions
+ icon.dim = {
+ x: parseInt(nodeValue(getElementsByTagNameNS(styleNodes[0], gxNS, 'x')[0], icon.dim.x)),
+ y: parseInt(nodeValue(getElementsByTagNameNS(styleNodes[0], gxNS, 'y')[0], icon.dim.y)),
+ w: parseInt(nodeValue(getElementsByTagNameNS(styleNodes[0], gxNS, 'w')[0], icon.dim.w)),
+ h: parseInt(nodeValue(getElementsByTagNameNS(styleNodes[0], gxNS, 'h')[0], icon.dim.h))
+ };
+
+ styleNodes = getElementsByTagName(styleNodes[0], 'hotSpot')[0];
+ if (!!styleNodes && styleNodes.length > 0) {
+ icon.hotSpot = {
+ x: styleNodes[0].getAttribute('x'),
+ y: styleNodes[0].getAttribute('y'),
+ xunits: styleNodes[0].getAttribute('xunits'),
+ yunits: styleNodes[0].getAttribute('yunits')
+ };
+ }
+
+ // certain occasions where we need the pixel size of the image (like the default settings...)
+ // (NOTE: Scale is applied to entire image, not just the section of the icon palette. So,
+ // if we need scaling, we'll need the img dimensions no matter what.)
+ if ( (icon.dim.w < 0 || icon.dim.h < 0) && (icon.xunits != 'pixels' || icon.yunits == 'fraction') || icon.scale != 1.0) {
+ // (hopefully, this will load by the time we need it...)
+ icon.img = new Image();
+ icon.img.onload = function() {
+ if (icon.dim.w < 0 || icon.dim.h < 0) {
+ icon.dim.w = this.width;
+ icon.dim.h = this.height;
+ }
+ };
+ icon.img.src = icon.url;
+
+ // sometimes the file is already cached and it never calls onLoad
+ if (icon.img.width > 0) {
+ icon.dim.w = icon.img.width;
+ icon.dim.h = icon.img.height;
+ }
+ }
+ }
+ }
+
+ // style.label = (unsupported; may be possible but not with API)
+
+ styleNodes = getElementsByTagName(thisNode, 'LineStyle');
+ if (!!styleNodes && styleNodes.length > 0) {
+ style.line.color = nodeValue(getElementsByTagName(styleNodes[0], 'color')[0], style.line.color);
+ style.line.colorMode = nodeValue(getElementsByTagName(styleNodes[0], 'colorMode')[0], style.line.colorMode);
+ style.line.width = nodeValue(getElementsByTagName(styleNodes[0], 'width')[0], style.line.width);
+ // style.line.outerColor = (unsupported; not supported in API)
+ // style.line.outerWidth = (unsupported; not supported in API)
+ // style.line.physicalWidth = (unsupported; unnecessary in Google Maps)
+ // style.line.labelVisibility = (unsupported; possible to implement)
+ }
+
+ styleNodes = getElementsByTagName(thisNode, 'PolyStyle');
+ if (!!styleNodes && styleNodes.length > 0) {
+ style.poly.color = nodeValue( getElementsByTagName(styleNodes[0], 'color')[0], style.poly.color);
+ style.poly.colorMode = nodeValue( getElementsByTagName(styleNodes[0], 'colorMode')[0], style.poly.colorMode);
+ style.poly.outline = getBooleanValue(getElementsByTagName(styleNodes[0], 'outline')[0], style.poly.outline);
+ style.poly.fill = getBooleanValue(getElementsByTagName(styleNodes[0], 'fill')[0], style.poly.fill);
+ }
+ return style;
+ }
+
+ // from http://stackoverflow.com/questions/122102/what-is-the-most-efficient-way-to-clone-a-javascript-object
+ // http://keithdevens.com/weblog/archive/2007/Jun/07/javascript.clone
+ function clone(obj){
+ if(obj == null || typeof(obj) != 'object') return obj;
+ if (obj.cloneNode) return obj.cloneNode(true);
+ var temp = new obj.constructor();
+ for(var key in obj) temp[key] = clone(obj[key]);
+ return temp;
+ }
+
+ function processStyleMap(thisNode, baseUrl, styleID, baseDir) {
+ var pairs = getElementsByTagName(thisNode, 'Pair');
+ var map = new Object();
+
+ // add each key to the map
+ for (var pr=0;pr<pairs.length;pr++) {
+ var pairKey = nodeValue(getElementsByTagName(pairs[pr], 'key')[0]);
+ var pairStyle = nodeValue(getElementsByTagName(pairs[pr], 'Style')[0]);
+ var pairStyleUrl = processStyleUrl(pairs[pr]);
+ var pairStyleBaseUrl = pairStyleUrl[0] ? cleanURL(baseDir, pairStyleUrl[0]) : baseUrl;
+ var pairStyleID = pairStyleUrl[1];
+
+ if (!!pairStyle) {
+ map[pairKey] = processStyle(pairStyle, pairStyleBaseUrl, pairStyleID);
+ } else if (!!pairStyleID && !!styles[pairStyleBaseUrl][pairStyleID]) {
+ map[pairKey] = clone(styles[pairStyleBaseUrl][pairStyleID]);
+ }
+ }
+ if (!!map["normal"]) {
+ styles[baseUrl][styleID] = clone(map["normal"]);
+ } else {
+ styles[baseUrl][styleID] = clone(defaultStyle);
+ }
+ if (!!map["highlight"]) {
+ processStyleID(map["highlight"]);
+ }
+ styles[baseUrl][styleID].map = clone(map);
+ }
+
+ function processPlacemarkCoords(node, tag) {
+ var parent = getElementsByTagName(node, tag);
+ var coordListA = [];
+ for (var i=0; i<parent.length; i++) {
+ var coordNodes = getElementsByTagName(parent[i], 'coordinates');
+ if (!coordNodes) {
+ if (coordListA.length > 0) {
+ break;
+ } else {
+ return [{coordinates: []}];
+ }
+ }
+
+ for (var j=0; j<coordNodes.length;j++) {
+ var coords = nodeValue(coordNodes[j]).trim();
+ coords = coords.replace(/,\s+/g, ',');
+ var path = coords.split(/\s+/g);
+ var pathLength = path.length;
+ var coordList = [];
+ for (var k = 0; k < pathLength; k++) {
+ coords = path[k].split(',');
+ if (!isNaN(coords[0]) && !isNaN(coords[1])) {
+ coordList.push({
+ lat: parseFloat(coords[1]),
+ lng: parseFloat(coords[0]),
+ alt: parseFloat(coords[2])
+ });
+ }
+ }
+ coordListA.push({coordinates: coordList});
+ }
+ }
+ return coordListA;
+ }
+
+ var render = function (responseXML, doc) {
+ // Callback for retrieving a KML document: parse the KML and display it on the map
+ if (!responseXML) {
+ // Error retrieving the data
+ geoXML3.log('Unable to retrieve ' + doc.url);
+ if (parserOptions.failedParse) parserOptions.failedParse(doc);
+ doc.failed = true;
+ return;
+ } else if (responseXML.parseError && responseXML.parseError.errorCode != 0) {
+ // IE parse error
+ var err = responseXML.parseError;
+ var msg = 'Parse error in line ' + err.line + ', col ' + err.linePos + ' (error code: ' + err.errorCode + ")\n" +
+ "\nError Reason: " + err.reason +
+ 'Error Line: ' + err.srcText;
+
+ geoXML3.log('Unable to retrieve ' + doc.url + ': ' + msg);
+ if (parserOptions.failedParse) parserOptions.failedParse(doc);
+ doc.failed = true;
+ return;
+ } else if (responseXML.documentElement && responseXML.documentElement.nodeName == 'parsererror') {
+ // Firefox parse error
+ geoXML3.log('Unable to retrieve ' + doc.url + ': ' + responseXML.documentElement.childNodes[0].nodeValue);
+ if (parserOptions.failedParse) parserOptions.failedParse(doc);
+ doc.failed = true;
+ return;
+ } else if (!doc) {
+ throw 'geoXML3 internal error: render called with null document';
+ } else { //no errors
+ var i;
+ doc.placemarks = [];
+ doc.groundoverlays = [];
+ doc.ggroundoverlays = [];
+ doc.networkLinks = [];
+ doc.gpolygons = [];
+ doc.gpolylines = [];
+
+ // Check for dependent KML files
+ var nodes = getElementsByTagName(responseXML, 'styleUrl');
+ var docSet = doc.internals.docSet;
+
+ for (var i = 0; i < nodes.length; i++) {
+ var url = nodeValue(nodes[i]).split('#')[0];
+ if (!url) continue; // #id (inside doc)
+ var rUrl = cleanURL( doc.baseDir, url );
+ if (rUrl === doc.baseUrl) continue; // self
+ if (docsByUrl[rUrl]) continue; // already loaded
+
+ var thisDoc;
+ var j = docSet.indexOfObjWithItem('baseUrl', rUrl);
+ if (j != -1) {
+ // Already listed to be loaded, but probably in the wrong order.
+ // Load it right away to immediately resolve dependency.
+ thisDoc = docSet[j];
+ if (thisDoc.failed) continue; // failed to load last time; don't retry it again
+ }
+ else {
+ // Not listed at all; add it in
+ thisDoc = new Object();
+ thisDoc.url = rUrl; // url can't be trusted inside KMZ files, since it may .. outside of the archive
+ thisDoc.baseUrl = rUrl;
+ thisDoc.internals = doc.internals;
+
+ doc.internals.docSet.push(thisDoc);
+ doc.internals.remaining++;
+ }
+
+ // render dependent KML first then re-run renderer
+ fetchDoc(rUrl, thisDoc, function (thisResXML) {
+ render(thisResXML, thisDoc);
+ render(responseXML, doc);
+ });
+
+ // to prevent cross-dependency issues, just load the one
+ // file first and re-check the rest later
+ return;
+ }
+
+ // Parse styles
+ doc.styles = styles[doc.baseUrl] = styles[doc.baseUrl] || {};
+ var styleID, styleNodes;
+ nodes = getElementsByTagName(responseXML, 'Style');
+ nodeCount = nodes.length;
+ for (i = 0; i < nodeCount; i++) {
+ thisNode = nodes[i];
+ var styleID = thisNode.getAttribute('id');
+ if (!!styleID) processStyle(thisNode, doc.baseUrl, styleID, doc.baseDir);
+ }
+ // Parse StyleMap nodes
+ nodes = getElementsByTagName(responseXML, 'StyleMap');
+ for (i = 0; i < nodes.length; i++) {
+ thisNode = nodes[i];
+ var styleID = thisNode.getAttribute('id');
+ if (!!styleID) processStyleMap(thisNode, doc.baseUrl, styleID, doc.baseDir);
+ }
+
+ if (!!parserOptions.processStyles || !parserOptions.createMarker) {
+ // Convert parsed styles into GMaps equivalents
+ processStyles(doc);
+ }
+
+ // Parse placemarks
+ if (!!doc.reload && !!doc.markers) {
+ for (i = 0; i < doc.markers.length; i++) {
+ doc.markers[i].active = false;
+ }
+ }
+ var placemark, node, coords, path, marker, poly;
+ var placemark, coords, path, pathLength, marker, polygonNodes, coordList;
+ var placemarkNodes = getElementsByTagName(responseXML, 'Placemark');
+ for (pm = 0; pm < placemarkNodes.length; pm++) {
+ // Init the placemark object
+ node = placemarkNodes[pm];
+ var styleUrl = processStyleUrl(node);
+ placemark = {
+ name: nodeValue(getElementsByTagName(node, 'name')[0]),
+ description: nodeValue(getElementsByTagName(node, 'description')[0]),
+ styleUrl: styleUrl.join('#'),
+ styleBaseUrl: styleUrl[0] ? cleanURL(doc.baseDir, styleUrl[0]) : doc.baseUrl,
+ styleID: styleUrl[1],
+ visibility: getBooleanValue(getElementsByTagName(node, 'visibility')[0], true),
+ balloonVisibility: getBooleanValue(getElementsByTagNameNS(node, gxNS, 'balloonVisibility')[0], !parserOptions.suppressInfoWindows)
+ };
+ placemark.style = (styles[placemark.styleBaseUrl] && styles[placemark.styleBaseUrl][placemark.styleID]) || clone(defaultStyle);
+ // inline style overrides shared style
+ var inlineStyles = getElementsByTagName(node, 'Style');
+ if (inlineStyles && (inlineStyles.length > 0)) {
+ var style = processStyle(node, '{inline}', '{inline}');
+ processStyleID(style);
+ if (style) placemark.style = style;
+ }
+
+ if (/^https?:\/\//.test(placemark.description)) {
+ placemark.description = ['<a href="', placemark.description, '">', placemark.description, '</a>'].join('');
+ }
+
+ // record list of variables for substitution
+ placemark.vars = {
+ display: {
+ name: 'Name',
+ description: 'Description',
+ address: 'Street Address',
+ id: 'ID',
+ Snippet: 'Snippet',
+ geDirections: 'Directions'
+ },
+ val: {
+ name: placemark.name || '',
+ description: placemark.description || '',
+ address: nodeValue(getElementsByTagName(node, 'address')[0], ''),
+ id: node.getAttribute('id') || '',
+ Snippet: nodeValue(getElementsByTagName(node, 'Snippet')[0], '')
+ },
+ directions: [
+ 'f=d',
+ 'source=GeoXML3'
+ ]
+ };
+
+ // add extended data to variables
+ var extDataNodes = getElementsByTagName(node, 'ExtendedData');
+ if (!!extDataNodes && extDataNodes.length > 0) {
+ var dataNodes = getElementsByTagName(extDataNodes[0], 'Data');
+ for (var d = 0; d < dataNodes.length; d++) {
+ var dn = dataNodes[d];
+ var name = dn.getAttribute('name');
+ if (!name) continue;
+ var dName = nodeValue(getElementsByTagName(dn, 'displayName')[0], name);
+ var val = nodeValue(getElementsByTagName(dn, 'value')[0]);
+
+ placemark.vars.val[name] = val;
+ placemark.vars.display[name] = dName;
+ }
+ }
+
+ // process MultiGeometry
+ var GeometryNodes = getElementsByTagName(node, 'coordinates');
+ var Geometry = null;
+ if (!!GeometryNodes && (GeometryNodes.length > 0)) {
+ for (var gn=0;gn<GeometryNodes.length;gn++) {
+ if (GeometryNodes[gn].parentNode &&
+ GeometryNodes[gn].parentNode.nodeName) {
+ var GeometryPN = GeometryNodes[gn].parentNode;
+ Geometry = GeometryPN.nodeName;
+
+ // Extract the coordinates
+ // What sort of placemark?
+ switch(Geometry) {
+ case "Point":
+ placemark.Point = processPlacemarkCoords(node, "Point")[0];
+ placemark.latlng = new google.maps.LatLng(placemark.Point.coordinates[0].lat, placemark.Point.coordinates[0].lng);
+ pathLength = 1;
+ break;
+ case "LinearRing":
+ // Polygon/line
+ polygonNodes = getElementsByTagName(node, 'Polygon');
+ // Polygon
+ if (!placemark.Polygon)
+ placemark.Polygon = [{
+ outerBoundaryIs: {coordinates: []},
+ innerBoundaryIs: [{coordinates: []}]
+ }];
+ for (var pg=0;pg<polygonNodes.length;pg++) {
+ placemark.Polygon[pg] = {
+ outerBoundaryIs: {coordinates: []},
+ innerBoundaryIs: [{coordinates: []}]
+ }
+ placemark.Polygon[pg].outerBoundaryIs = processPlacemarkCoords(polygonNodes[pg], "outerBoundaryIs");
+ placemark.Polygon[pg].innerBoundaryIs = processPlacemarkCoords(polygonNodes[pg], "innerBoundaryIs");
+ }
+ coordList = placemark.Polygon[0].outerBoundaryIs;
+ break;
+
+ case "LineString":
+ pathLength = 0;
+ placemark.LineString = processPlacemarkCoords(node,"LineString");
+ break;
+
+ default:
+ break;
+ }
+ }
+ }
+ }
+
+ // call the custom placemark parse function if it is defined
+ if (!!parserOptions.pmParseFn) parserOptions.pmParseFn(node, placemark);
+ doc.placemarks.push(placemark);
+
+ // single marker
+ if (placemark.Point) {
+ if (!!google.maps) {
+ doc.bounds = doc.bounds || new google.maps.LatLngBounds();
+ doc.bounds.extend(placemark.latlng);
+ }
+
+ // Potential user-defined marker handler
+ var pointCreateFunc = parserOptions.createMarker || createMarker;
+ var found = false;
+ if (!parserOptions.createMarker) {
+ // Check to see if this marker was created on a previous load of this document
+ if (!!doc) {
+ doc.markers = doc.markers || [];
+ if (doc.reload) {
+ for (var j = 0; j < doc.markers.length; j++) {
+ if (doc.markers[j].getPosition().equals(placemark.latlng)) {
+ found = doc.markers[j].active = true;
+ break;
+ }
+ }
+ }
+ }
+ }
+ if (!found) {
+ // Call the marker creator
+ var marker = pointCreateFunc(placemark, doc);
+ if (marker) marker.active = placemark.visibility;
+ }
+ }
+ // polygon/line
+ var poly, line;
+ if (!!doc) {
+ if (placemark.Polygon) doc.gpolygons = doc.gpolygons || [];
+ if (placemark.LineString) doc.gpolylines = doc.gpolylines || [];
+ }
+
+ var polyCreateFunc = parserOptions.createPolygon || createPolygon;
+ var lineCreateFunc = parserOptions.createLineString || createPolyline;
+ if (placemark.Polygon) {
+ poly = polyCreateFunc(placemark,doc);
+ if (poly) poly.active = placemark.visibility;
+ }
+ if (placemark.LineString) {
+ line = lineCreateFunc(placemark,doc);
+ if (line) line.active = placemark.visibility;
+ }
+ if (!!google.maps) {
+ doc.bounds = doc.bounds || new google.maps.LatLngBounds();
+ if (poly) doc.bounds.union(poly.bounds);
+ if (line) doc.bounds.union(line.bounds);
+ }
+
+ } // placemark loop
+
+ if (!!doc.reload && !!doc.markers) {
+ for (i = doc.markers.length - 1; i >= 0 ; i--) {
+ if (!doc.markers[i].active) {
+ if (!!doc.markers[i].infoWindow) {
+ doc.markers[i].infoWindow.close();
+ }
+ doc.markers[i].setMap(null);
+ doc.markers.splice(i, 1);
+ }
+ }
+ }
+
+ // Parse ground overlays
+ if (!!doc.reload && !!doc.groundoverlays) {
+ for (i = 0; i < doc.groundoverlays.length; i++) {
+ doc.groundoverlays[i].active = false;
+ }
+ }
+
+ if (!!doc) {
+ doc.groundoverlays = doc.groundoverlays || [];
+ }
+ // doc.groundoverlays =[];
+ var groundOverlay, color, transparency, overlay;
+ var groundNodes = getElementsByTagName(responseXML, 'GroundOverlay');
+ for (i = 0; i < groundNodes.length; i++) {
+ node = groundNodes[i];
+
+ // Detect images buried in KMZ files (and use a base64 encoded URL)
+ var gnUrl = cleanURL( doc.baseDir, nodeValue(getElementsByTagName(node, 'href')[0]) );
+ if (kmzMetaData[gnUrl]) gnUrl = kmzMetaData[gnUrl].dataUrl;
+
+ // Init the ground overlay object
+ groundOverlay = {
+ name: nodeValue(getElementsByTagName(node, 'name')[0]),
+ description: nodeValue(getElementsByTagName(node, 'description')[0]),
+ icon: { href: gnUrl },
+ latLonBox: {
+ north: parseFloat(nodeValue(getElementsByTagName(node, 'north')[0])),
+ east: parseFloat(nodeValue(getElementsByTagName(node, 'east')[0])),
+ south: parseFloat(nodeValue(getElementsByTagName(node, 'south')[0])),
+ west: parseFloat(nodeValue(getElementsByTagName(node, 'west')[0]))
+ }
+ };
+ if (!!google.maps) {
+ doc.bounds = doc.bounds || new google.maps.LatLngBounds();
+ doc.bounds.union(new google.maps.LatLngBounds(
+ new google.maps.LatLng(groundOverlay.latLonBox.south, groundOverlay.latLonBox.west),
+ new google.maps.LatLng(groundOverlay.latLonBox.north, groundOverlay.latLonBox.east)
+ ));
+ }
+
+ // Opacity is encoded in the color node
+ var colorNode = getElementsByTagName(node, 'color');
+ if (colorNode && colorNode.length > 0) {
+ groundOverlay.opacity = geoXML3.getOpacity(nodeValue(colorNode[0]));
+ } else {
+ groundOverlay.opacity = 1.0; // KML default
+ }
+
+ doc.groundoverlays.push(groundOverlay);
+ if (!!parserOptions.createOverlay) {
+ // User-defined overlay handler
+ parserOptions.createOverlay(groundOverlay, doc);
+ } else {
+ // Check to see if this overlay was created on a previous load of this document
+ var found = false;
+ if (!!doc) {
+ doc.groundoverlays = doc.groundoverlays || [];
+ if (doc.reload) {
+ overlayBounds = new google.maps.LatLngBounds(
+ new google.maps.LatLng(groundOverlay.latLonBox.south, groundOverlay.latLonBox.west),
+ new google.maps.LatLng(groundOverlay.latLonBox.north, groundOverlay.latLonBox.east)
+ );
+ var overlays = doc.groundoverlays;
+ for (i = overlays.length; i--;) {
+ if ((overlays[i].bounds().equals(overlayBounds)) &&
+ (overlays.url_ === groundOverlay.icon.href)) {
+ found = overlays[i].active = true;
+ break;
+ }
+ }
+ }
+ }
+
+ if (!found) {
+ // Call the built-in overlay creator
+ overlay = createOverlay(groundOverlay, doc);
+ overlay.active = true;
+ }
+ }
+ if (!!doc.reload && !!doc.groundoverlays && !!doc.groundoverlays.length) {
+ var overlays = doc.groundoverlays;
+ for (i = overlays.length; i--;) {
+ if (!overlays[i].active) {
+ overlays[i].remove();
+ overlays.splice(i, 1);
+ }
+ }
+ doc.groundoverlays = overlays;
+ }
+ }
+
+ // Parse network links
+ var networkLink;
+ var docPath = document.location.pathname.split('/');
+ docPath = docPath.splice(0, docPath.length - 1).join('/');
+ var linkNodes = getElementsByTagName(responseXML, 'NetworkLink');
+ for (i = 0; i < linkNodes.length; i++) {
+ node = linkNodes[i];
+
+ // Init the network link object
+ networkLink = {
+ name: nodeValue(getElementsByTagName(node, 'name')[0]),
+ link: {
+ href: nodeValue(getElementsByTagName(node, 'href')[0]),
+ refreshMode: nodeValue(getElementsByTagName(node, 'refreshMode')[0])
+ }
+ };
+
+ // Establish the specific refresh mode
+ if (!networkLink.link.refreshMode) {
+ networkLink.link.refreshMode = 'onChange';
+ }
+ if (networkLink.link.refreshMode === 'onInterval') {
+ networkLink.link.refreshInterval = parseFloat(nodeValue(getElementsByTagName(node, 'refreshInterval')[0]));
+ if (isNaN(networkLink.link.refreshInterval)) {
+ networkLink.link.refreshInterval = 0;
+ }
+ } else if (networkLink.link.refreshMode === 'onChange') {
+ networkLink.link.viewRefreshMode = nodeValue(getElementsByTagName(node, 'viewRefreshMode')[0]);
+ if (!networkLink.link.viewRefreshMode) {
+ networkLink.link.viewRefreshMode = 'never';
+ }
+ if (networkLink.link.viewRefreshMode === 'onStop') {
+ networkLink.link.viewRefreshTime = nodeValue(getElementsByTagName(node, 'refreshMode')[0]);
+ networkLink.link.viewFormat = nodeValue(getElementsByTagName(node, 'refreshMode')[0]);
+ if (!networkLink.link.viewFormat) {
+ networkLink.link.viewFormat = 'BBOX=[bboxWest],[bboxSouth],[bboxEast],[bboxNorth]';
+ }
+ }
+ }
+
+ if (!/^[\/|http]/.test(networkLink.link.href)) {
+ // Fully-qualify the HREF
+ networkLink.link.href = docPath + '/' + networkLink.link.href;
+ }
+
+ // Apply the link
+ if ((networkLink.link.refreshMode === 'onInterval') &&
+ (networkLink.link.refreshInterval > 0)) {
+ // Reload at regular intervals
+ setInterval(parserName + '.parse("' + networkLink.link.href + '")',
+ 1000 * networkLink.link.refreshInterval);
+ } else if (networkLink.link.refreshMode === 'onChange') {
+ if (networkLink.link.viewRefreshMode === 'never') {
+ // Load the link just once
+ doc.internals.parser.parse(networkLink.link.href, doc.internals.docSet);
+ } else if (networkLink.link.viewRefreshMode === 'onStop') {
+ // Reload when the map view changes
+
+ }
+ }
+ }
+ }
+
+ if (!!doc.bounds) {
+ doc.internals.bounds = doc.internals.bounds || new google.maps.LatLngBounds();
+ doc.internals.bounds.union(doc.bounds);
+ }
+ if (!!doc.markers || !!doc.groundoverlays || !!doc.gpolylines || !!doc.gpolygons) {
+ doc.internals.parseOnly = false;
+ }
+
+ if (!doc.internals.parseOnly) {
+ // geoXML3 is not being used only as a real-time parser, so keep the processed documents around
+ if (!docsByUrl[doc.baseUrl]) {
+ docs.push(doc);
+ docsByUrl[doc.baseUrl] = doc;
+ }
+ else {
+ // internal replacement, which keeps the same memory ref loc in docs and docsByUrl
+ for (var i in docsByUrl[doc.baseUrl]) {
+ docsByUrl[doc.baseUrl][i] = doc[i];
+ }
+ }
+ }
+
+ doc.internals.remaining--;
+ if (doc.internals.remaining === 0) {
+ // We're done processing this set of KML documents
+ // Options that get invoked after parsing completes
+ if (parserOptions.zoom && !!doc.internals.bounds) {
+ parserOptions.map.fitBounds(doc.internals.bounds);
+ }
+ if (parserOptions.afterParse) {
+ parserOptions.afterParse(doc.internals.docSet);
+ }
+ }
+ };
+
+ var kmlColor = function (kmlIn, colorMode) {
+ var kmlColor = {};
+ kmlIn = kmlIn || 'ffffffff'; // white (KML 2.2 default)
+
+ var aa = kmlIn.substr(0,2);
+ var bb = kmlIn.substr(2,2);
+ var gg = kmlIn.substr(4,2);
+ var rr = kmlIn.substr(6,2);
+
+ kmlColor.opacity = parseInt(aa, 16) / 256;
+ kmlColor.color = (colorMode === 'random') ? randomColor(rr, gg, bb) : '#' + rr + gg + bb;
+ return kmlColor;
+ };
+
+ // Implemented per KML 2.2 <ColorStyle> specs
+ var randomColor = function(rr, gg, bb) {
+ var col = { rr: rr, gg: gg, bb: bb };
+ for (var k in col) {
+ var v = col[k];
+ if (v == null) v = 'ff';
+
+ // RGB values are limiters for random numbers (ie: 7f would be a random value between 0 and 7f)
+ v = Math.round(Math.random() * parseInt(rr, 16)).toString(16);
+ if (v.length === 1) v = '0' + v;
+ col[k] = v;
+ }
+
+ return '#' + col.rr + col.gg + col.bb;
+ };
+
+ var processStyleID = function (style) {
+ var icon = style.icon;
+ if (!icon.href) return;
+
+ if (icon.img && !icon.img.complete) {
+ // we're still waiting on the image loading (probably because we've been blocking since the declaration)
+ // so, let's queue this function on the onload stack
+ icon.markerBacklog = [];
+ icon.img.onload = function() {
+ if (icon.dim.w < 0 || icon.dim.h < 0) {
+ icon.dim.w = this.width;
+ icon.dim.h = this.height;
+ }
+ processStyleID(style);
+
+ // we will undoubtedly get some createMarker queuing, so set this up in advance
+ for (var i = 0; i < icon.markerBacklog.length; i++) {
+ var p = icon.markerBacklog[i][0];
+ var d = icon.markerBacklog[i][1];
+ createMarker(p, d);
+ if (p.marker) p.marker.active = true;
+ }
+ delete icon.markerBacklog;
+ };
+ return;
+ }
+ else if (icon.dim.w < 0 || icon.dim.h < 0) {
+ if (icon.img && icon.img.complete) {
+ // sometimes the file is already cached and it never calls onLoad
+ icon.dim.w = icon.img.width;
+ icon.dim.h = icon.img.height;
+ }
+ else {
+ // settle for a default of 32x32
+ icon.dim.whGuess = true;
+ icon.dim.w = 32;
+ icon.dim.h = 32;
+ }
+ }
+
+ // pre-scaled variables
+ var rnd = Math.round;
+ var scaled = {
+ x: icon.dim.x * icon.scale,
+ y: icon.dim.y * icon.scale,
+ w: icon.dim.w * icon.scale,
+ h: icon.dim.h * icon.scale,
+ aX: icon.hotSpot.x * icon.scale,
+ aY: icon.hotSpot.y * icon.scale,
+ iW: (icon.img ? icon.img.width : icon.dim.w) * icon.scale,
+ iH: (icon.img ? icon.img.height : icon.dim.h) * icon.scale
+ };
+
+ // Figure out the anchor spot
+ var aX, aY;
+ switch (icon.hotSpot.xunits) {
+ case 'fraction': aX = rnd(scaled.aX * icon.dim.w); break;
+ case 'insetPixels': aX = rnd(icon.dim.w * icon.scale - scaled.aX); break;
+ default: aX = rnd(scaled.aX); break; // already pixels
+ }
+ aY = rnd( ((icon.hotSpot.yunits === 'fraction') ? icon.dim.h : 1) * scaled.aY ); // insetPixels Y = pixels Y
+ var iconAnchor = new google.maps.Point(aX, aY);
+
+ // Sizes
+ // (NOTE: Scale is applied to entire image, not just the section of the icon palette.)
+ var iconSize = icon.dim.whGuess ? null : new google.maps.Size(rnd(scaled.w), rnd(scaled.h));
+ var iconScale = icon.scale == 1.0 ? null :
+ icon.dim.whGuess ? new google.maps.Size(rnd(scaled.w), rnd(scaled.h))
+ : new google.maps.Size(rnd(scaled.iW), rnd(scaled.iH));
+ var iconOrigin = new google.maps.Point(rnd(scaled.x), rnd(scaled.y));
+
+ // Detect images buried in KMZ files (and use a base64 encoded URL)
+ if (kmzMetaData[icon.url]) icon.url = kmzMetaData[icon.url].dataUrl;
+
+ // Init the style object with the KML icon
+ icon.marker = new google.maps.MarkerImage(
+ icon.url, // url
+ iconSize, // size
+ iconOrigin, // origin
+ iconAnchor, // anchor
+ iconScale // scaledSize
+ );
+
+ // Look for a predictable shadow
+ var stdRegEx = /\/(red|blue|green|yellow|lightblue|purple|pink|orange)(-dot)?\.png/;
+ var shadowSize = new google.maps.Size(59, 32);
+ var shadowPoint = new google.maps.Point(16, 32);
+ if (stdRegEx.test(icon.href)) {
+ // A standard GMap-style marker icon
+ icon.shadow = new google.maps.MarkerImage(
+ 'http://maps.google.com/mapfiles/ms/micons/msmarker.shadow.png', // url
+ shadowSize, // size
+ null, // origin
+ shadowPoint, // anchor
+ shadowSize // scaledSize
+ );
+ } else if (icon.href.indexOf('-pushpin.png') > -1) {
+ // Pushpin marker icon
+ icon.shadow = new google.maps.MarkerImage(
+ 'http://maps.google.com/mapfiles/ms/micons/pushpin_shadow.png', // url
+ shadowSize, // size
+ null, // origin
+ shadowPoint, // anchor
+ shadowSize // scaledSize
+ );
+ } /* else {
+ // Other MyMaps KML standard icon
+ icon.shadow = new google.maps.MarkerImage(
+ icon.href.replace('.png', '.shadow.png'), // url
+ shadowSize, // size
+ null, // origin
+ anchorPoint, // anchor
+ shadowSize // scaledSize
+ );
+ } */
+ }
+
+ var processStyles = function (doc) {
+ for (var styleID in doc.styles) {
+ processStyleID(doc.styles[styleID]);
+ }
+ };
+
+ var createMarker = function (placemark, doc) {
+ // create a Marker to the map from a placemark KML object
+ var icon = placemark.style.icon;
+
+ if ( !icon.marker && icon.img ) {
+ // yay, single point of failure is holding up multiple markers...
+ icon.markerBacklog = icon.markerBacklog || [];
+ icon.markerBacklog.push([placemark, doc]);
+ return;
+ }
+
+ // Load basic marker properties
+ var markerOptions = geoXML3.combineOptions(parserOptions.markerOptions, {
+ map: parserOptions.map,
+ position: new google.maps.LatLng(placemark.Point.coordinates[0].lat, placemark.Point.coordinates[0].lng),
+ title: placemark.name,
+ zIndex: Math.round(placemark.Point.coordinates[0].lat * -100000)<<5,
+ icon: icon.marker,
+ shadow: icon.shadow,
+ flat: !icon.shadow,
+ visible: placemark.visibility
+ });
+
+ // Create the marker on the map
+ var marker = new google.maps.Marker(markerOptions);
+ if (!!doc) doc.markers.push(marker);
+
+ // Set up and create the infowindow if it is not suppressed
+ createInfoWindow(placemark, doc, marker);
+ placemark.marker = marker;
+ return marker;
+ };
+
+ var createOverlay = function (groundOverlay, doc) {
+ // Add a ProjectedOverlay to the map from a groundOverlay KML object
+
+ if (!window.ProjectedOverlay) {
+ throw 'geoXML3 error: ProjectedOverlay not found while rendering GroundOverlay from KML';
+ }
+
+ var bounds = new google.maps.LatLngBounds(
+ new google.maps.LatLng(groundOverlay.latLonBox.south, groundOverlay.latLonBox.west),
+ new google.maps.LatLng(groundOverlay.latLonBox.north, groundOverlay.latLonBox.east)
+ );
+ var overlayOptions = geoXML3.combineOptions(parserOptions.overlayOptions, {percentOpacity: groundOverlay.opacity*100});
+ var overlay = new ProjectedOverlay(parserOptions.map, groundOverlay.icon.href, bounds, overlayOptions);
+
+ if (!!doc) {
+ doc.ggroundoverlays = doc.ggroundoverlays || [];
+ doc.ggroundoverlays.push(overlay);
+ }
+
+ return overlay;
+ };
+
+ // Create Polyline
+ var createPolyline = function(placemark, doc) {
+ var path = [];
+ for (var j=0; j<placemark.LineString.length; j++) {
+ var coords = placemark.LineString[j].coordinates;
+ var bounds = new google.maps.LatLngBounds();
+ for (var i=0;i<coords.length;i++) {
+ var pt = new google.maps.LatLng(coords[i].lat, coords[i].lng);
+ path.push(pt);
+ bounds.extend(pt);
+ }
+ }
+ // point to open the infowindow if triggered
+ var point = path[Math.floor(path.length/2)];
+ // Load basic polyline properties
+ var kmlStrokeColor = kmlColor(placemark.style.line.color, placemark.style.line.colorMode);
+ var polyOptions = geoXML3.combineOptions(parserOptions.polylineOptions, {
+ map: parserOptions.map,
+ path: path,
+ strokeColor: kmlStrokeColor.color,
+ strokeWeight: placemark.style.line.width,
+ strokeOpacity: kmlStrokeColor.opacity,
+ title: placemark.name,
+ visible: placemark.visibility
+ });
+ var p = new google.maps.Polyline(polyOptions);
+ p.bounds = bounds;
+
+ // setup and create the infoWindow if it is not suppressed
+ createInfoWindow(placemark, doc, p);
+ if (!!doc) doc.gpolylines.push(p);
+ placemark.polyline = p;
+ return p;
+ }
+
+ // Create Polygon
+ var createPolygon = function(placemark, doc) {
+ var bounds = new google.maps.LatLngBounds();
+ var pathsLength = 0;
+ var paths = [];
+ for (var polygonPart=0;polygonPart<placemark.Polygon.length;polygonPart++) {
+ for (var j=0; j<placemark.Polygon[polygonPart].outerBoundaryIs.length; j++) {
+ var coords = placemark.Polygon[polygonPart].outerBoundaryIs[j].coordinates;
+ var path = [];
+ for (var i=0;i<coords.length;i++) {
+ var pt = new google.maps.LatLng(coords[i].lat, coords[i].lng);
+ path.push(pt);
+ bounds.extend(pt);
+ }
+ paths.push(path);
+ pathsLength += path.length;
+ }
+ for (var j=0; j<placemark.Polygon[polygonPart].innerBoundaryIs.length; j++) {
+ var coords = placemark.Polygon[polygonPart].innerBoundaryIs[j].coordinates;
+ var path = [];
+ for (var i=0;i<coords.length;i++) {
+ var pt = new google.maps.LatLng(coords[i].lat, coords[i].lng);
+ path.push(pt);
+ bounds.extend(pt);
+ }
+ paths.push(path);
+ pathsLength += path.length;
+ }
+ }
+
+ // Load basic polygon properties
+ var kmlStrokeColor = kmlColor(placemark.style.line.color, placemark.style.line.colorMode);
+ var kmlFillColor = kmlColor(placemark.style.poly.color, placemark.style.poly.colorMode);
+ if (!placemark.style.poly.fill) kmlFillColor.opacity = 0.0;
+ var strokeWeight = placemark.style.line.width;
+ if (!placemark.style.poly.outline) {
+ strokeWeight = 0;
+ kmlStrokeColor.opacity = 0.0;
+ }
+ var polyOptions = geoXML3.combineOptions(parserOptions.polygonOptions, {
+ map: parserOptions.map,
+ paths: paths,
+ title: placemark.name,
+ strokeColor: kmlStrokeColor.color,
+ strokeWeight: strokeWeight,
+ strokeOpacity: kmlStrokeColor.opacity,
+ fillColor: kmlFillColor.color,
+ fillOpacity: kmlFillColor.opacity,
+ visible: placemark.visibility
+ });
+ var p = new google.maps.Polygon(polyOptions);
+ p.bounds = bounds;
+
+ createInfoWindow(placemark, doc, p);
+ if (!!doc) doc.gpolygons.push(p);
+ placemark.polygon = p;
+ return p;
+ }
+
+ var createInfoWindow = function(placemark, doc, gObj) {
+ var bStyle = placemark.style.balloon;
+ var vars = placemark.vars;
+
+ if (!placemark.balloonVisibility || bStyle.displayMode === 'hide') return;
+
+ // define geDirections
+ if (placemark.latlng) {
+ vars.directions.push('sll=' + placemark.latlng.toUrlValue());
+
+ var url = 'http://maps.google.com/maps?' + vars.directions.join('&');
+ var address = encodeURIComponent( vars.val.address || placemark.latlng.toUrlValue() ).replace(/\%20/g, '+');
+
+ vars.val.geDirections = '<a href="' + url + '&daddr=' + address + '" target=_blank>To Here</a> - <a href="' + url + '&saddr=' + address + '" target=_blank>From Here</a>';
+ }
+ else vars.val.geDirections = '';
+
+ // add in the variables
+ var iwText = bStyle.text.replace(/\$\[(\w+(\/displayName)?)\]/g, function(txt, n, dn) { return dn ? vars.display[n] : vars.val[n]; });
+ var classTxt = 'geoxml3_infowindow geoxml3_style_' + placemark.styleID;
+
+ // color styles
+ var styleArr = [];
+ if (bStyle.bgColor != 'ffffffff') styleArr.push('background: ' + kmlColor(bStyle.bgColor ).color + ';');
+ if (bStyle.textColor != 'ff000000') styleArr.push('color: ' + kmlColor(bStyle.textColor).color + ';');
+ var styleProp = styleArr.length ? ' style="' + styleArr.join(' ') + '"' : '';
+
+ var infoWindowOptions = geoXML3.combineOptions(parserOptions.infoWindowOptions, {
+ content: '<div class="' + classTxt + '"' + styleProp + '>' + iwText + '</div>',
+ pixelOffset: new google.maps.Size(0, 2)
+ });
+
+ gObj.infoWindow = parserOptions.infoWindow || new google.maps.InfoWindow(infoWindowOptions);
+ gObj.infoWindowOptions = infoWindowOptions;
+
+ // Info Window-opening event handler
+ google.maps.event.addListener(gObj, 'click', function(e) {
+ var iW = this.infoWindow;
+ iW.close();
+ iW.setOptions(this.infoWindowOptions);
+
+ if (e && e.latLng) iW.setPosition(e.latLng);
+ else if (this.bounds) iW.setPosition(this.bounds.getCenter());
+
+ iW.open(this.map, this.bounds ? null : this);
+ });
+
+ }
+
+ return {
+ // Expose some properties and methods
+
+ options: parserOptions,
+ docs: docs,
+ docsByUrl: docsByUrl,
+ kmzMetaData: kmzMetaData,
+
+ parse: parse,
+ parseKmlString: parseKmlString,
+ hideDocument: hideDocument,
+ showDocument: showDocument,
+ processStyles: processStyles,
+ createMarker: createMarker,
+ createOverlay: createOverlay,
+ createPolyline: createPolyline,
+ createPolygon: createPolygon
+ };
+};
+// End of KML Parser
+
+// Helper objects and functions
+geoXML3.getOpacity = function (kmlColor) {
+ // Extract opacity encoded in a KML color value. Returns a number between 0 and 1.
+ if (!!kmlColor &&
+ (kmlColor !== '') &&
+ (kmlColor.length == 8)) {
+ var transparency = parseInt(kmlColor.substr(0, 2), 16);
+ return transparency / 255;
+ } else {
+ return 1;
+ }
+};
+
+// Log a message to the debugging console, if one exists
+geoXML3.log = function(msg) {
+ if (!!window.console) {
+ console.log(msg);
+ } else { alert("log:"+msg); }
+};
+
+/**
+ * Creates a new parserOptions object.
+ * @class GeoXML3 parser options.
+ * @param {Object} overrides Any options you want to declare outside of the defaults should be included here.
+ * @property {google.maps.Map} map The API map on which geo objects should be rendered.
+ * @property {google.maps.MarkerOptions} markerOptions If the parser is adding Markers to the map itself, any options specified here will be applied to them.
+ * @property {google.maps.InfoWindowOptions} infoWindowOptions If the parser is adding Markers to the map itself, any options specified here will be applied to their attached InfoWindows.
+ * @property {ProjectedOverlay.options} overlayOptions If the parser is adding ProjectedOverlays to the map itself, any options specified here will be applied to them.
+ */
+geoXML3.parserOptions = function (overrides) {
+ this.map = null,
+ /** If true, the parser will automatically move the map to a best-fit of the geodata after parsing of a KML document completes.
+ * @type Boolean
+ * @default true
+ */
+ this.zoom = true,
+ /**#@+ @type Boolean
+ * @default false */
+ /** If true, only a single Marker created by the parser will be able to have its InfoWindow open at once (simulating the behavior of GMaps API v2). */
+ this.singleInfoWindow = false,
+ /** If true, suppresses the rendering of info windows. */
+ this.suppressInfoWindows = false,
+ /**
+ * Control whether to process styles now or later.
+ *
+ * <p>By default, the parser only processes KML &lt;Style&gt; elements into their GMaps equivalents
+ * if it will be creating its own Markers (the createMarker option is null). Setting this option
+ * to true will force such processing to happen anyway, useful if you're going to be calling parser.createMarker
+ * yourself later. OTOH, leaving this option false removes runtime dependency on the GMaps API, enabling
+ * the use of geoXML3 as a standalone KML parser.</p>
+ */
+ this.processStyles = false,
+ /**#@-*/
+
+ this.markerOptions = {},
+ this.infoWindowOptions = {},
+ this.overlayOptions = {},
+
+ /**#@+ @event */
+ /** This function will be called when parsing of a KML document is complete.
+ * @param {geoXML3.parser#docs} doc Parsed KML data. */
+ this.afterParse = null,
+ /** This function will be called when parsing of a KML document is complete.
+ * @param {geoXML3.parser#docs} doc Parsed KML data. */
+ this.failedParse = null,
+ /**
+ * If supplied, this function will be called once for each marker <Placemark> in the KML document, instead of the parser adding its own Marker to the map.
+ * @param {geoXML3.parser.render#placemark} placemark Placemark object.
+ * @param {geoXML3.parser#docs} doc Parsed KML data.
+ */
+ this.createMarker = null,
+ /**
+ * If supplied, this function will be called once for each <GroundOverlay> in the KML document, instead of the parser adding its own ProjectedOverlay to the map.
+ * @param {geoXML3.parser.render#groundOverlay} groundOverlay GroundOverlay object.
+ * @param {geoXML3.parser#docs} doc Parsed KML data.
+ */
+ this.createOverlay = null
+ /**#@-*/
+
+ if (overrides) {
+ for (var prop in overrides) {
+ if (overrides.hasOwnProperty(prop)) this[prop] = overrides[prop];
+ }
+ }
+ return this;
+};
+
+/**
+ * Combine two options objects: a set of default values and a set of override values.
+ *
+ * @deprecated This has been replaced with {@link geoXML3.parserOptions#combineOptions}.
+ * @param {geoXML3.parserOptions|Object} overrides Override values.
+ * @param {geoXML3.parserOptions|Object} defaults Default values.
+ * @return {geoXML3.parserOptions} Combined result.
+ */
+geoXML3.combineOptions = function (overrides, defaults) {
+ var result = {};
+ if (!!overrides) {
+ for (var prop in overrides) {
+ if (overrides.hasOwnProperty(prop)) result[prop] = overrides[prop];
+ }
+ }
+ if (!!defaults) {
+ for (prop in defaults) {
+ if (defaults.hasOwnProperty(prop) && result[prop] === undefined) result[prop] = defaults[prop];
+ }
+ }
+ return result;
+};
+
+/**
+ * Combine two options objects: a set of default values and a set of override values.
+ *
+ * @function
+ * @param {geoXML3.parserOptions|Object} overrides Override values.
+ * @param {geoXML3.parserOptions|Object} defaults Default values.
+ * @return {geoXML3.parserOptions} Combined result.
+ */
+geoXML3.parserOptions.prototype.combineOptions = geoXML3.combineOptions;
+
+// Retrieve an XML document from url and pass it to callback as a DOM document
+geoXML3.fetchers = [];
+
+/**
+ * Parses a XML string.
+ *
+ * <p>Parses the given XML string and returns the parsed document in a
+ * DOM data structure. This function will return an empty DOM node if
+ * XML parsing is not supported in this browser.</p>
+ *
+ * @param {String} str XML string.
+ * @return {Element|Document} DOM.
+ */
+geoXML3.xmlParse = function (str) {
+ if (!!window.DOMParser) return (new DOMParser()).parseFromString(str, 'text/xml');
+ else if (!!window.ActiveXObject) {
+ var doc;
+
+ // the many versions of IE's DOM parsers
+ var AXOs = [
+ 'MSXML2.DOMDocument.6.0',
+ 'MSXML2.DOMDocument.5.0',
+ 'MSXML2.DOMDocument.4.0',
+ 'MSXML2.DOMDocument.3.0',
+ 'MSXML2.DOMDocument',
+ 'Microsoft.XMLDOM',
+ 'MSXML.DOMDocument'
+ ];
+ for (var i = 0; i < AXOs.length; i++) {
+ try { doc = new ActiveXObject(AXOs[i]); break; }
+ catch(e) { continue; }
+ }
+ if (!doc) return createElement('div', null);
+
+ if (doc.async) doc.async = false;
+ doc.loadXML(str);
+ return doc;
+ }
+
+ return createElement('div', null);
+}
+
+/**
+ * Fetches a XML document.
+ *
+ * <p>Fetches/parses the given XML URL and passes the parsed document (in a
+ * DOM data structure) to the given callback. Documents are downloaded
+ * and parsed asynchronously.</p>
+ *
+ * @param {String} url URL of XML document. Must be uncompressed XML only.
+ * @param {Function(Document)} callback Function to call when the document is processed.
+ */
+geoXML3.fetchXML = function (url, callback) {
+ function timeoutHandler() { callback(); };
+
+ var xhrFetcher = new Object();
+ if (!!geoXML3.fetchers.length) xhrFetcher = geoXML3.fetchers.pop();
+ else if (!!window.XMLHttpRequest) xhrFetcher.fetcher = new window.XMLHttpRequest(); // Most browsers
+ else if (!!window.ActiveXObject) { // Some IE
+ // the many versions of IE's XML fetchers
+ var AXOs = [
+ 'MSXML2.XMLHTTP.6.0',
+ 'MSXML2.XMLHTTP.5.0',
+ 'MSXML2.XMLHTTP.4.0',
+ 'MSXML2.XMLHTTP.3.0',
+ 'MSXML2.XMLHTTP',
+ 'Microsoft.XMLHTTP',
+ 'MSXML.XMLHTTP'
+ ];
+ for (var i = 0; i < AXOs.length; i++) {
+ try { xhrFetcher.fetcher = new ActiveXObject(AXOs[i]); break; }
+ catch(e) { continue; }
+ }
+ if (!xhrFetcher.fetcher) {
+ geoXML3.log('Unable to create XHR object');
+ callback(null);
+ return null;
+ }
+ }
+
+ if (!!xhrFetcher.fetcher.overrideMimeType) xhrFetcher.fetcher.overrideMimeType('text/xml');
+ xhrFetcher.fetcher.open('GET', url, true);
+ xhrFetcher.fetcher.onreadystatechange = function () {
+ if (xhrFetcher.fetcher.readyState === 4) {
+ // Retrieval complete
+ if (!!xhrFetcher.xhrtimeout) clearTimeout(xhrFetcher.xhrtimeout);
+ if (xhrFetcher.fetcher.status >= 400) {
+ geoXML3.log('HTTP error ' + xhrFetcher.fetcher.status + ' retrieving ' + url);
+ callback();
+ }
+ // Returned successfully
+ else {
+ if (xhrFetcher.fetcher.responseXML) {
+ // Sometimes IE will get the data, but won't bother loading it as an XML doc
+ var xmlDoc = xhrFetcher.fetcher.responseXML;
+ if (xmlDoc && !xmlDoc.documentElement && !xmlDoc.ownerElement) xmlDoc.loadXML(xhrFetcher.fetcher.responseText);
+ callback(xmlDoc);
+ } else // handle valid xml sent with wrong MIME type
+ callback(geoXML3.xmlParse(xhrFetcher.fetcher.responseText));
+ }
+
+ // We're done with this fetcher object
+ geoXML3.fetchers.push(xhrFetcher);
+ }
+ };
+
+ xhrFetcher.xhrtimeout = setTimeout(timeoutHandler, 60000);
+ xhrFetcher.fetcher.send(null);
+ return null;
+};
+
+/**
+ * Fetches a KMZ document.
+ *
+ * <p>Fetches/parses the given ZIP URL, parses each image file, and passes
+ * the parsed KML document to the given callback. Documents are downloaded
+ * and parsed asynchronously, though the KML file is always passed after the
+ * images have been processed, in case the callback requires the image data.</p>
+ *
+ * @requires ZipFile.complete.js
+ * @param {String} url URL of KMZ document. Must be a valid KMZ/ZIP archive.
+ * @param {Function(Document)} callback Function to call when the document is processed.
+ * @param {geoXML3.parser} parser A geoXML3.parser object. This is used to populate the KMZ image data.
+ * @author Brendan Byrd
+ * @see http://code.google.com/apis/kml/documentation/kmzarchives.html
+ */
+geoXML3.fetchZIP = function (url, callback, parser) {
+ // Just need a single 'new' declaration with a really long function...
+ var zipFile = new ZipFile(url, function (zip) {
+ // Retrieval complete
+
+ // Check for ERRORs in zip.status
+ for (var i = 0; i < zip.status.length; i++) {
+ var msg = zip.status[i];
+ if (msg.indexOf("ERROR") == 0) {
+ geoXML3.log('HTTP/ZIP error retrieving ' + url + ': ' + msg);
+ callback();
+ return;
+ }
+ else if (msg.indexOf("WARNING") == 0) { // non-fatal, but still might be useful
+ geoXML3.log('HTTP/ZIP warning retrieving ' + url + ': ' + msg);
+ }
+ }
+
+ // Make sure KMZ structure is according to spec (with a single KML file in the root dir)
+ var KMLCount = 0;
+ var KML;
+ for (var i = 0; i < zip.entries.length; i++) {
+ var name = zip.entries[i].name;
+ if (!/\.kml$/.test(name)) continue;
+
+ KMLCount++;
+ if (KMLCount == 1) KML = i;
+ else {
+ geoXML3.log('KMZ warning retrieving ' + url + ': found extra KML "' + name + '" in KMZ; discarding...');
+ }
+ }
+
+ // Returned successfully, but still needs extracting
+ var baseUrl = cleanURL(defileURL(url), url) + '/';
+ var kmlProcessing = { // this is an object just so it gets passed properly
+ timer: null,
+ extractLeft: 0,
+ timerCalls: 0
+ };
+ var extractCb = function(entry, entryContent) {
+ var mdUrl = cleanURL(baseUrl, entry.name);
+ var ext = entry.name.substring(entry.name.lastIndexOf(".") + 1).toLowerCase();
+ kmlProcessing.extractLeft--;
+
+ if ((typeof entryContent.description == "string") && (entryContent.name == "Error")) {
+ geoXML3.log('KMZ error extracting ' + mdUrl + ': ' + entryContent.description);
+ callback();
+ return;
+ }
+
+ // MIME types that can be used in KML
+ var mime;
+ if (ext === 'jpg') ext = 'jpeg';
+ if (/^(gif|jpeg|png)$/.test(ext)) mime = 'image/' + ext;
+ else if (ext === 'mp3') mime = 'audio/mpeg';
+ else if (ext === 'm4a') mime = 'audio/mp4';
+ else if (ext === 'm4a') mime = 'audio/MP4-LATM';
+ else mime = 'application/octet-stream';
+
+ parser.kmzMetaData[mdUrl] = {};
+ parser.kmzMetaData[mdUrl].entry = entry;
+ // data:image/gif;base64,R0lGODlhEAAOALMA...
+ parser.kmzMetaData[mdUrl].dataUrl = 'data:' + mime + ';base64,' + base64Encode(entryContent);
+
+ // IE cannot handle GET requests beyond 2071 characters, even if it's an inline image
+ if (/msie/i.test(navigator.userAgent) && !/opera/i.test(navigator.userAgent) && parser.kmzMetaData[mdUrl].dataUrl.length > 2071)
+ parser.kmzMetaData[mdUrl].dataUrl =
+ // this is a simple IE icon; to hint at the problem...
+ 'data:image/gif;base64,R0lGODlhDwAQAOMPADBPvSpQ1Dpoyz1p6FhwvU2A6ECP63CM04CWxYCk+V6x+UK++Jao3rvC3fj7+v///yH5BAEKAA8ALAAAAAAPABAAAASC8Mk5mwCAUMlWwcLRHEelLA' +
+ 'oGDMgzSsiyGCAhCETDPMh5XQCBwYBrNBIKWmg0MCQHj8MJU5IoroYCY6AAAgrDIbbQDGIK6DR5UPhlNo0JAlSUNAiDgH7eNAxEDWAKCQM2AAFheVxYAA0AIkFOJ1gBcQQaUQKKA5w7LpcEBwkJaKMUEQA7';
+ };
+ var kmlExtractCb = function(entry, entryContent) {
+ if ((typeof entryContent.description == "string") && (entryContent.name == "Error")) {
+ geoXML3.log('KMZ error extracting ' + mdUrl + ': ' + entryContent.description);
+ callback();
+ return;
+ }
+
+ // check to see if the KML is the last file extracted
+ clearTimeout(kmlProcessing.timer);
+ if (kmlProcessing.extractLeft <= 1) {
+ kmlProcessing.extractLeft--;
+ callback(geoXML3.xmlParse(entryContent));
+ return;
+ }
+ else {
+ // KML file isn't last yet; it may need to use those files, so wait a bit (100ms)
+ kmlProcessing.timerCalls++;
+ if (kmlProcessing.timerCalls < 100) {
+ kmlProcessing.timer = setTimeout(function() { kmlExtractCb(entry, entryContent); }, 100);
+ }
+ else {
+ geoXML3.log('KMZ warning extracting ' + url + ': entire ZIP has not been extracted after 10 seconds; running through KML, anyway...');
+ kmlProcessing.extractLeft--;
+ callback(geoXML3.xmlParse(entryContent));
+ }
+ }
+ return;
+ };
+ for (var i = 0; i < zip.entries.length; i++) {
+ var entry = zip.entries[i];
+ var ext = entry.name.substring(entry.name.lastIndexOf(".") + 1).toLowerCase();
+ if (!/^(gif|jpe?g|png|kml)$/.test(ext)) continue; // not going to bother to extract files we don't support
+ if (ext === "kml" && i != KML) continue; // extra KMLs get discarded
+ if (!parser && ext != "kml") continue; // cannot store images without a parser object
+
+ // extract asynchronously
+ kmlProcessing.extractLeft++;
+ if (ext === "kml") entry.extract(kmlExtractCb);
+ else entry.extract(extractCb);
+ }
+ });
+
+};
+
+/**
+ * Extract the text value of a DOM node, with leading and trailing whitespace trimmed.
+ *
+ * @param {Element} node XML node/element.
+ * @param {Any} delVal Default value if the node doesn't exist.
+ * @return {String|Null}
+ */
+geoXML3.nodeValue = function(node, defVal) {
+ var retStr="";
+ if (!node) {
+ return (typeof defVal === 'undefined' || defVal === null) ? null : defVal;
+ }
+ if(node.nodeType==3||node.nodeType==4||node.nodeType==2){
+ retStr+=node.nodeValue;
+ }else if(node.nodeType==1||node.nodeType==9||node.nodeType==11){
+ for(var i=0;i<node.childNodes.length;++i){
+ retStr+=arguments.callee(node.childNodes[i]);
+ }
+ }
+ return retStr;
+};
+
+/**
+ * Loosely translate various values of a DOM node to a boolean.
+ *
+ * @param {Element} node XML node/element.
+ * @param {Boolean} delVal Default value if the node doesn't exist.
+ * @return {Boolean|Null}
+ */
+geoXML3.getBooleanValue = function(node, defVal) {
+ var nodeContents = geoXML3.nodeValue(node);
+ if (nodeContents === null) return defVal || false;
+ nodeContents = parseInt(nodeContents);
+ if (isNaN(nodeContents)) return true;
+ if (nodeContents == 0) return false;
+ else return true;
+}
+
+/**
+ * Browser-normalized version of getElementsByTagNameNS.
+ *
+ * <p>Required because IE8 doesn't define it.</p>
+ *
+ * @param {Element|Document} node DOM object.
+ * @param {String} namespace Full namespace URL to search against.
+ * @param {String} tagname XML local tag name.
+ * @return {Array of Elements}
+ * @author Brendan Byrd
+ */
+geoXML3.getElementsByTagNameNS = function(node, namespace, tagname) {
+ if (node && typeof node.getElementsByTagNameNS != 'undefined') return node.getElementsByTagNameNS(namespace, tagname);
+ if (!node) return [];
+
+ var root = node.documentElement || node.ownerDocument && node.ownerDocument.documentElement;
+ if (!root || !root.attributes) return [];
+
+ // search for namespace prefix
+ for (var i = 0; i < root.attributes.length; i++) {
+ var attr = root.attributes[i];
+ if (attr.prefix === 'xmlns' && attr.nodeValue === namespace) return node.getElementsByTagName(attr.baseName + ':' + tagname);
+ else if (attr.nodeName === 'xmlns' && attr.nodeValue === namespace) {
+ // default namespace
+ if (typeof node.selectNodes != 'undefined') {
+ // Newer IEs have the SelectionNamespace property that can be used with selectNodes
+ if (!root.ownerDocument.getProperty('SelectionNamespaces'))
+ root.ownerDocument.setProperty('SelectionNamespaces', "xmlns:defaultNS='" + namespace + "'");
+ return node.selectNodes('.//defaultNS:' + tagname);
+ }
+ else {
+ // Otherwise, you can still try to tack on the 'xmlns' attribute to root
+ root.setAttribute('xmlns:defaultNS', namespace);
+ return node.getElementsByTagName('defaultNS:' + tagname);
+ }
+ }
+ }
+ return geoXML3.getElementsByTagName(node, tagname); // try the unqualified version
+};
+
+/**
+ * Browser-normalized version of getElementsByTagName.
+ *
+ * <p>Required because MSXML 6.0 will treat this function as a NS-qualified function,
+ * despite the missing NS parameter.</p>
+ *
+ * @param {Element|Document} node DOM object.
+ * @param {String} tagname XML local tag name.
+ * @return {Array of Elements}
+ * @author Brendan Byrd
+ */
+geoXML3.getElementsByTagName = function(node, tagname) {
+ if (node && typeof node.getElementsByTagNameNS != 'undefined') return node.getElementsByTagName(tagname); // if it has both functions, it should be accurate
+// if (node && typeof node.selectNodes != 'undefined') return node.selectNodes(".//*[local-name()='" + tagname + "']");
+ return node.getElementsByTagName(tagname); // hope for the best...
+}
+
+/**
+ * Turn a directory + relative URL into an absolute one.
+ *
+ * @private
+ * @param {String} d Base directory.
+ * @param {String} s Relative URL.
+ * @return {String} Absolute URL.
+ * @author Brendan Byrd
+ */
+var toAbsURL = function (d, s) {
+ var p, f, i;
+ var h = location.protocol + "://" + location.host;
+
+ if (!s.length) return '';
+ if (/^\w+:/.test(s)) return s;
+ if (s.indexOf('/') == 0) return h + s;
+
+ p = d.replace(/\/[^\/]*$/, '');
+ f = s.match(/\.\.\//g);
+ if (f) {
+ s = s.substring(f.length * 3);
+ for (i = f.length; i--;) { p = p.substring(0, p.lastIndexOf('/')); }
+ }
+
+ return h + p + '/' + s;
+}
+
+/**
+ * Remove current host from URL
+ *
+ * @private
+ * @param {String} s Absolute or relative URL.
+ * @return {String} Root-based relative URL.
+ * @author Brendan Byrd
+ */
+var dehostURL = function (s) {
+ var h = location.protocol + "://" + location.host;
+ h = h.replace(/([\.\\\+\*\?\[\^\]\$\(\)])/g, '\\$1'); // quotemeta
+ return s.replace(new RegExp('^' + h, 'i'), '');
+}
+
+/**
+ * Removes all query strings, #IDs, '../' references, and
+ * hosts from a URL.
+ *
+ * @private
+ * @param {String} d Base directory.
+ * @param {String} s Absolute or relative URL.
+ * @return {String} Root-based relative URL.
+ * @author Brendan Byrd
+ */
+var cleanURL = function (d, s) { return dehostURL(toAbsURL(d ? d.split('#')[0].split('?')[0] : defileURL(location.pathname), s ? s.split('#')[0].split('?')[0] : '')); }
+/**
+ * Remove filename from URL
+ *
+ * @private
+ * @param {String} s Relative URL.
+ * @return {String} Base directory.
+ * @author Brendan Byrd
+ */
+var defileURL = function (s) { return s ? s.substr(0, s.lastIndexOf('/') + 1) : '/'; }
+
+
+// Some extra Array subs for ease of use
+// http://stackoverflow.com/questions/143847/best-way-to-find-an-item-in-a-javascript-array
+Array.prototype.hasObject = (
+ !Array.indexOf ? function (obj) {
+ var l = this.length + 1;
+ while (l--) {
+ if (this[l - 1] === obj) return true;
+ }
+ return false;
+ } : function (obj) {
+ return (this.indexOf(obj) !== -1);
+ }
+);
+Array.prototype.hasItemInObj = function (name, item) {
+ var l = this.length + 1;
+ while (l--) {
+ if (this[l - 1][name] === item) return true;
+ }
+ return false;
+};
+if (!Array.prototype.indexOf) {
+ Array.prototype.indexOf = function (obj, fromIndex) {
+ if (fromIndex == null) {
+ fromIndex = 0;
+ } else if (fromIndex < 0) {
+ fromIndex = Math.max(0, this.length + fromIndex);
+ }
+ for (var i = fromIndex, j = this.length; i < j; i++) {
+ if (this[i] === obj) return i;
+ }
+ return -1;
+ };
+}
+Array.prototype.indexOfObjWithItem = function (name, item, fromIndex) {
+ if (fromIndex == null) {
+ fromIndex = 0;
+ } else if (fromIndex < 0) {
+ fromIndex = Math.max(0, this.length + fromIndex);
+ }
+ for (var i = fromIndex, j = this.length; i < j; i++) {
+ if (this[i][name] === item) return i;
+ }
+ return -1;
+};
+
+/**
+ * Borrowed from jquery.base64.js, with some "Array as input" corrections
+ *
+ * @private
+ * @param {Array of charCodes} input An array of byte ASCII codes (0-255).
+ * @return {String} A base64-encoded string.
+ * @author Brendan Byrd
+ */
+var base64Encode = function(input) {
+ var keyString = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
+ var output = "";
+ var chr1, chr2, chr3, enc1, enc2, enc3, enc4;
+ var i = 0;
+ while (i < input.length) {
+ chr1 = input[i++];
+ chr2 = input[i++];
+ chr3 = input[i++];
+ enc1 = chr1 >> 2;
+ enc2 = ((chr1 & 3) << 4) | (chr2 >> 4);
+ enc3 = ((chr2 & 15) << 2) | (chr3 >> 6);
+ enc4 = chr3 & 63;
+
+ if (chr2 == undefined) enc3 = enc4 = 64;
+ else if (chr3 == undefined) enc4 = 64;
+
+ output = output + keyString.charAt(enc1) + keyString.charAt(enc2) + keyString.charAt(enc3) + keyString.charAt(enc4);
+ }
+ return output;
+};
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/README b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/README
new file mode 100644
index 00000000..64a2208c
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/README
@@ -0,0 +1,6 @@
+==markerclusterer.js and markerwithlabel.js==
+Is fetched from trunk @ https://github.com/googlemaps/v3-utility-library
+
+On update don't forget to add the following line at the end of the file:
+
+ window.MarkerClusterer = MarkerClusterer;
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/googleearth-compiled.js b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/googleearth-compiled.js
new file mode 100644
index 00000000..e1870183
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/googleearth-compiled.js
@@ -0,0 +1,20 @@
+(function(){var j=window,k=document,l=Math;function n(a,b){return a.width=b}function o(a,b){return a.position=b}function p(a,b){return a.height=b}function q(a,b){return a.zIndex=b}var r="appendChild",s="createElement",t="getCoordinates",u="getView",w="pushLatLngAlt",x="setTimeout",y="style",z="addListener",A="getFeatures",B="InfoWindow",C="maps",D="getPosition",E="setStyleSelector",F="earth",H="prototype",I="setGeometry",J="substring",K="parentNode",L="event";
+function M(a){if(!google||!google[F])throw"google.earth not loaded";if(!google[F].isSupported())throw"Google Earth API is not supported on this system";if(!google[F].isInstalled())throw"Google Earth API is not installed on this system";this.l="//maps.google.com/mapfiles/kml/paddle/red-circle.png";this.b=a;this.k=a.getDiv();this.d=!1;this.f="Earth";this.i=[];this.e={};this.j=null;this.g=0;aa(this);ba(this)}j.GoogleEarth=M;M.MAP_TYPE_ID="GoogleEarthAPI";M[H].o=function(){return this.a};
+M[H].getInstance=M[H].o;
+function aa(a){var b=a.b,c={tileSize:new google[C].Size(256,256),maxZoom:19,name:a.f,alt:a.f,getTile:function(a,b,c){return c[s]("DIV")}};b.mapTypes.set("GoogleEarthAPI",c);b.setOptions({mapTypeControlOptions:{mapTypeIds:[google[C].MapTypeId.ROADMAP,google[C].MapTypeId.SATELLITE,"GoogleEarthAPI"]}});google[C][L][z](b,"maptypeid_changed",function(){if(a.b.getMapTypeId()=="GoogleEarthAPI"){var b;a:{b=RegExp("title=['\"]?"+a.f+"[\"']?");for(var c=a.c[K].childNodes,e=0,g;g=c[e];e++)if(b.test(g.innerHTML)){b=g;
+ break a}b=void 0}c=b;e=c[y].zIndex;g=a.c[K].childNodes;for(var h=0,i;i=g[h];h++)i.__gme_ozi=i[y].zIndex,q(i[y],-1);c.__gme_ozi=e;q(a.c[y],q(c[y],0));c=a.h=k[s]("IFRAME");c.src="javascript:false;";c.scrolling="no";c.frameBorder="0";e=c[y];q(e,-1E5);n(e,p(e,"100%"));o(e,"absolute");e.left=e.top=0;b[r](c);a.c[y].display="";a.d=!0;a.a?N(a):ca(a)}else da(a)})}
+function N(a){a.e={};O(a,!0);for(var b=a.a[A]();b.getFirstChild();)b.removeChild(b.getFirstChild());a.g++;for(var b=0,c;c=a.i[b];b++)google[C][L].removeListener(c);b={};c=P;for(var d=0,f;f=c[d];d++)b[f]=Q(a,f);for(c=0;d=b.Marker[c];c++)ea(a,d);for(c=0;d=b.Polygon[c];c++){var e=a,g=d,d=e.a;f=S(e,g);var h=d.createPolygon("");f[I](h);e=T(e,g);f[E](e);e=d.createLinearRing("");h.setOuterBoundary(e);for(var h=e[t](),g=g.getPath().getArray(),e=0,i=void 0;i=g[e];e++)h[w](i.lat(),i.lng(),0);d[A]()[r](f)}for(c=
+ 0;d=b.Polyline[c];c++){h=a;g=d;d=h.a;f=S(h,g);e=d.createLineString("");e.setTessellate(!0);f[I](e);h=T(h,g);f[E](h);h=e[t]();g=g.getPath().getArray();e=0;for(i=void 0;i=g[e];e++)h[w](i.lat(),i.lng(),0);d[A]()[r](f)}for(c=0;d=b.Rectangle[c];c++){var g=a,m=d,d=g.a,h=m.getBounds();f=h.getNorthEast();h=h.getSouthWest();e=S(g,m);e[I](d.createPolygon(""));i=d.createLinearRing("");g=T(g,m);e[E](g);g=i[t]();g[w](f.lat(),f.lng(),0);g[w](f.lat(),h.lng(),0);g[w](h.lat(),h.lng(),0);g[w](h.lat(),f.lng(),0);g[w](f.lat(),
+ f.lng(),0);e.getGeometry().setOuterBoundary(i);e.setName("placemark");d[A]()[r](e)}for(c=0;d=b.Circle[c];c++){i=a;m=d;d=i.a;f=m.getCenter();g=m.getRadius();h=S(i,m);h[I](d.createPolygon(""));e=d.createLinearRing("");i=T(i,m);h[E](i);for(i=0;i<25;i++){var R=f,v=g,m=14.4*i;v/=6378137;m*=l.PI/180;var G=R.lat()*(l.PI/180),R=R.lng()*(l.PI/180),X=l.cos(v),v=l.sin(v),Y=l.sin(G),G=l.cos(G),Z=X*Y+v*G*l.cos(m),m=new google[C].LatLng(l.asin(Z)/(l.PI/180),(R+l.atan2(v*G*l.sin(m),X-Y*Z))/(l.PI/180));e[t]()[w](m.lat(),
+ m.lng(),0)}h.getGeometry().setOuterBoundary(e);h.setName("placemark");d[A]()[r](h)}for(c=0;d=b.KmlLayer[c];c++)fa(a,d.getUrl());for(c=0;d=b.GroundOverlay[c];c++)g=d.getBounds(),f=g.getNorthEast(),g=g.getSouthWest(),h=a.a,e=h.createGroundOverlay(""),e.setLatLonBox(h.createLatLonBox("")),e.getLatLonBox().setBox(f.lat(),g.lat(),f.lng(),g.lng(),0),e.setIcon(h.createIcon("")),e.getIcon().setHref(d.getUrl()),h[A]()[r](e)}
+function O(a,b){var c=a.b.getCenter(),d=a.a.createLookAt("");d.setRange(l.pow(2,27-a.b.getZoom()));d.setLatitude(c.lat());d.setLongitude(c.lng());d.setHeading(0);d.setAltitude(0);var f=a.a;b?(f.getOptions().setFlyToSpeed(5),f[u]().setAbstractView(d),d.setTilt(15),f.getOptions().setFlyToSpeed(0.75),j[x](function(){f[u]().setAbstractView(d)},200),j[x](function(){f.getOptions().setFlyToSpeed(1)},250)):f[u]().setAbstractView(d)}
+function U(a,b){a[0]=="#"&&(a=a[J](1,9));typeof b=="undefined"?b="FF":(b=parseInt(parseFloat(b)*255,10).toString(16),b.length==1&&(b="0"+b));return[b,a[J](4,6),a[J](2,4),a[J](0,2)].join("")}function S(a,b){var c=a.g+"GEV3_"+b.__gme_id;a.e[c]=b;return a.a.createPlacemark(c)}function fa(a,b){var c=a.a;google[F].fetchKml(c,b,function(a){a?c[A]()[r](a):j[x](function(){alert("Bad or null KML.")},0)})}
+function ea(a,b){if(b[D]()){var c=a.a,d=S(a,b);b.getTitle()&&d.setName(b.getTitle());var f=c.createIcon("");b.getIcon()?f.setHref(b.getIcon()):f.setHref(a.l);var e=c.createStyle("");e.getIconStyle().setIcon(f);d[E](e);f=c.createPoint("");f.setLatitude(b[D]().lat());f.setLongitude(b[D]().lng());d[I](f);c[A]()[r](d);a.i.push(google[C][L][z](b,"position_changed",function(){var c=a.g+"GEV3_"+b.__gme_id,d=a.e[c],c=a.a.getElementById(c).getGeometry(),d=d[D]();c.setLatitude(d.lat());c.setLongitude(d.lng())}))}}
+function T(a,b){var c=a.a.createStyle(""),d=c.getPolyStyle(),f=c.getLineStyle();f.setWidth(V(b,"strokeWeight",3));var e=V(b,"strokeOpacity",1),g=V(b,"fillOpacity",0.3),h=V(b,"strokeColor","#000000"),i=V(b,"fillColor","#000000");f.getColor().set(U(h,e));d.getColor().set(U(i,g));return c}function V(a,b,c){a=a.get(b);return typeof a=="undefined"?c:a}
+function ca(a){google[F].createInstance(a.m,function(b){a.a=b;ga(a);N(a)},function(b){ha(a);a.b.setMapTypeId(google[C].MapTypeId.ROADMAP);throw"Google Earth API failed to initialize: "+b;})}
+function ga(a){var b=a.a;b.getWindow().setVisibility(!0);var c=b.getNavigationControl();c.setVisibility(b.VISIBILITY_AUTO);c=c.getScreenXY();c.setYUnits(b.UNITS_INSET_PIXELS);c.setXUnits(b.UNITS_PIXELS);c=b.getLayerRoot();c.enableLayerById(b.LAYER_BORDERS,!0);c.enableLayerById(b.LAYER_ROADS,!0);google[C][L][z](a.b,"GEInfoWindowOpened",function(b){if(a.d){var c=a.a.createHtmlStringBalloon("");c.setFeature(a.j);c.setContentString(b.getContent());a.a.setBalloon(c)}});google[F].addEventListener(b.getGlobe(),
+ "click",function(b){var c=b.getTarget(),e=a.e[c.getId()];if(e){b.preventDefault();for(var b=Q(a,"InfoWindow"),g=0,h;h=b[g];g++)h.close();a.j=c;google[C][L].trigger(e,"click")}})}function ia(a){var b=a.a[u]().copyAsLookAt(a.a.ALTITUDE_RELATIVE_TO_GROUND),c=b.getRange(),c=l.round(27-l.log(c)/l.log(2));!a.b.getZoom()==c?a.b.setZoom(c-1):a.b.setZoom(c);a.b.panTo(new google[C].LatLng(b.getLatitude(),b.getLongitude()))}function da(a){a.d&&(ia(a),j[x](function(){O(a)},50),j[x](function(){ha(a)},2200))}
+function ha(a){for(var b=a.c[K].childNodes,c=0,d;d=b[c];c++)q(d[y],d.__gme_ozi);a.h[K].removeChild(a.h);a.h=null;a.c[y].display="none";a.d=!1}
+function ba(a){var b=a.k,c=a.c=k[s]("DIV");o(c[y],"absolute");n(c[y],0);p(c[y],0);c.index=0;c[y].display="none";var d=a.n=k[s]("DIV");n(d[y],b.clientWidth+"px");p(d[y],b.clientHeight+"px");o(d[y],"absolute");c[r](d);b=a.m=k[s]("DIV");o(b[y],"absolute");n(b[y],"100%");p(b[y],"100%");d[r](b);a.b.controls[google[C].ControlPosition.TOP_LEFT].push(c);google[C][L][z](a.b,"resize",function(){var b=a.n[y],c=a.k;n(b,c.clientWidth+"px");p(b,c.clientHeight+"px")})}
+function Q(a,b){var c=[],d=W[b],f;for(f in d)if(d.hasOwnProperty(f)){var e=d[f];e.get("map")==a.b&&c.push(e)}return c}var W={};function ja(){var a=$,b=google[C][a][H];b.__gme_setMapOriginal=b.setMap;W[a]={};google[C][a][H].setMap=function(b){if(b){if(!this.__gme_id)this.__gme_id=ka++,W[a][this.__gme_id]=this}else delete W[a][this.__gme_id],this.__gme_id=void 0;this.__gme_setMapOriginal(b)}}
+for(var P="Marker,Polyline,Polygon,Rectangle,Circle,KmlLayer,GroundOverlay,InfoWindow".split(","),ka=0,la=P,ma=0,$;$=la[ma];ma++)if(ja(),$=="InfoWindow")google[C][B][H].p=google[C][B][H].open,W.InfoWindow={},google[C][B][H].open=function(a,b){if(a){if(!this.__gme_id)this.__gme_id=ka++,W[B][this.__gme_id]=this}else delete W[B][this.__gme_id],this.__gme_id=void 0;google[C][L].trigger(a,"GEInfoWindowOpened",this);this.p(a,b)};})();
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerclusterer.js b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerclusterer.js
new file mode 100644
index 00000000..e5379c62
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerclusterer.js
@@ -0,0 +1,1637 @@
+/*jslint browser: true, confusion: true, sloppy: true, vars: true, nomen: false, plusplus: false, indent: 2 */
+/*global window,google */
+
+/**
+ * @name MarkerClustererPlus for Google Maps V3
+ * @version 2.1.2 [May 28, 2014]
+ * @author Gary Little
+ * @fileoverview
+ * The library creates and manages per-zoom-level clusters for large amounts of markers.
+ * <p>
+ * This is an enhanced V3 implementation of the
+ * <a href="http://gmaps-utility-library-dev.googlecode.com/svn/tags/markerclusterer/"
+ * >V2 MarkerClusterer</a> by Xiaoxi Wu. It is based on the
+ * <a href="http://google-maps-utility-library-v3.googlecode.com/svn/tags/markerclusterer/"
+ * >V3 MarkerClusterer</a> port by Luke Mahe. MarkerClustererPlus was created by Gary Little.
+ * <p>
+ * v2.0 release: MarkerClustererPlus v2.0 is backward compatible with MarkerClusterer v1.0. It
+ * adds support for the <code>ignoreHidden</code>, <code>title</code>, <code>batchSizeIE</code>,
+ * and <code>calculator</code> properties as well as support for four more events. It also allows
+ * greater control over the styling of the text that appears on the cluster marker. The
+ * documentation has been significantly improved and the overall code has been simplified and
+ * polished. Very large numbers of markers can now be managed without causing Javascript timeout
+ * errors on Internet Explorer. Note that the name of the <code>clusterclick</code> event has been
+ * deprecated. The new name is <code>click</code>, so please change your application code now.
+ */
+
+/**
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+/**
+ * @name ClusterIconStyle
+ * @class This class represents the object for values in the <code>styles</code> array passed
+ * to the {@link MarkerClusterer} constructor. The element in this array that is used to
+ * style the cluster icon is determined by calling the <code>calculator</code> function.
+ *
+ * @property {string} url The URL of the cluster icon image file. Required.
+ * @property {number} height The display height (in pixels) of the cluster icon. Required.
+ * @property {number} width The display width (in pixels) of the cluster icon. Required.
+ * @property {Array} [anchorText] The position (in pixels) from the center of the cluster icon to
+ * where the text label is to be centered and drawn. The format is <code>[yoffset, xoffset]</code>
+ * where <code>yoffset</code> increases as you go down from center and <code>xoffset</code>
+ * increases to the right of center. The default is <code>[0, 0]</code>.
+ * @property {Array} [anchorIcon] The anchor position (in pixels) of the cluster icon. This is the
+ * spot on the cluster icon that is to be aligned with the cluster position. The format is
+ * <code>[yoffset, xoffset]</code> where <code>yoffset</code> increases as you go down and
+ * <code>xoffset</code> increases to the right of the top-left corner of the icon. The default
+ * anchor position is the center of the cluster icon.
+ * @property {string} [textColor="black"] The color of the label text shown on the
+ * cluster icon.
+ * @property {number} [textSize=11] The size (in pixels) of the label text shown on the
+ * cluster icon.
+ * @property {string} [textDecoration="none"] The value of the CSS <code>text-decoration</code>
+ * property for the label text shown on the cluster icon.
+ * @property {string} [fontWeight="bold"] The value of the CSS <code>font-weight</code>
+ * property for the label text shown on the cluster icon.
+ * @property {string} [fontStyle="normal"] The value of the CSS <code>font-style</code>
+ * property for the label text shown on the cluster icon.
+ * @property {string} [fontFamily="Arial,sans-serif"] The value of the CSS <code>font-family</code>
+ * property for the label text shown on the cluster icon.
+ * @property {string} [backgroundPosition="0 0"] The position of the cluster icon image
+ * within the image defined by <code>url</code>. The format is <code>"xpos ypos"</code>
+ * (the same format as for the CSS <code>background-position</code> property). You must set
+ * this property appropriately when the image defined by <code>url</code> represents a sprite
+ * containing multiple images. Note that the position <i>must</i> be specified in px units.
+ */
+/**
+ * @name ClusterIconInfo
+ * @class This class is an object containing general information about a cluster icon. This is
+ * the object that a <code>calculator</code> function returns.
+ *
+ * @property {string} text The text of the label to be shown on the cluster icon.
+ * @property {number} index The index plus 1 of the element in the <code>styles</code>
+ * array to be used to style the cluster icon.
+ * @property {string} title The tooltip to display when the mouse moves over the cluster icon.
+ * If this value is <code>undefined</code> or <code>""</code>, <code>title</code> is set to the
+ * value of the <code>title</code> property passed to the MarkerClusterer.
+ */
+/**
+ * A cluster icon.
+ *
+ * @constructor
+ * @extends google.maps.OverlayView
+ * @param {Cluster} cluster The cluster with which the icon is to be associated.
+ * @param {Array} [styles] An array of {@link ClusterIconStyle} defining the cluster icons
+ * to use for various cluster sizes.
+ * @private
+ */
+function ClusterIcon(cluster, styles) {
+ cluster.getMarkerClusterer().extend(ClusterIcon, google.maps.OverlayView);
+
+ this.cluster_ = cluster;
+ this.className_ = cluster.getMarkerClusterer().getClusterClass();
+ this.styles_ = styles;
+ this.center_ = null;
+ this.div_ = null;
+ this.sums_ = null;
+ this.visible_ = false;
+
+ this.setMap(cluster.getMap()); // Note: this causes onAdd to be called
+}
+
+
+/**
+ * Adds the icon to the DOM.
+ */
+ClusterIcon.prototype.onAdd = function () {
+ var cClusterIcon = this;
+ var cMouseDownInCluster;
+ var cDraggingMapByCluster;
+
+ this.div_ = document.createElement("div");
+ this.div_.className = this.className_;
+ if (this.visible_) {
+ this.show();
+ }
+
+ this.getPanes().overlayMouseTarget.appendChild(this.div_);
+
+ // Fix for Issue 157
+ this.boundsChangedListener_ = google.maps.event.addListener(this.getMap(), "bounds_changed", function () {
+ cDraggingMapByCluster = cMouseDownInCluster;
+ });
+
+ google.maps.event.addDomListener(this.div_, "mousedown", function () {
+ cMouseDownInCluster = true;
+ cDraggingMapByCluster = false;
+ });
+
+ google.maps.event.addDomListener(this.div_, "click", function (e) {
+ cMouseDownInCluster = false;
+ if (!cDraggingMapByCluster) {
+ var theBounds;
+ var mz;
+ var mc = cClusterIcon.cluster_.getMarkerClusterer();
+ /**
+ * This event is fired when a cluster marker is clicked.
+ * @name MarkerClusterer#click
+ * @param {Cluster} c The cluster that was clicked.
+ * @event
+ */
+ google.maps.event.trigger(mc, "click", cClusterIcon.cluster_);
+ google.maps.event.trigger(mc, "clusterclick", cClusterIcon.cluster_); // deprecated name
+
+ // The default click handler follows. Disable it by setting
+ // the zoomOnClick property to false.
+ if (mc.getZoomOnClick()) {
+ // Zoom into the cluster.
+ mz = mc.getMaxZoom();
+ theBounds = cClusterIcon.cluster_.getBounds();
+ mc.getMap().fitBounds(theBounds);
+ // There is a fix for Issue 170 here:
+ setTimeout(function () {
+ mc.getMap().fitBounds(theBounds);
+ // Don't zoom beyond the max zoom level
+ if (mz !== null && (mc.getMap().getZoom() > mz)) {
+ mc.getMap().setZoom(mz + 1);
+ }
+ }, 100);
+ }
+
+ // Prevent event propagation to the map:
+ e.cancelBubble = true;
+ if (e.stopPropagation) {
+ e.stopPropagation();
+ }
+ }
+ });
+
+ google.maps.event.addDomListener(this.div_, "mouseover", function () {
+ var mc = cClusterIcon.cluster_.getMarkerClusterer();
+ /**
+ * This event is fired when the mouse moves over a cluster marker.
+ * @name MarkerClusterer#mouseover
+ * @param {Cluster} c The cluster that the mouse moved over.
+ * @event
+ */
+ google.maps.event.trigger(mc, "mouseover", cClusterIcon.cluster_);
+ });
+
+ google.maps.event.addDomListener(this.div_, "mouseout", function () {
+ var mc = cClusterIcon.cluster_.getMarkerClusterer();
+ /**
+ * This event is fired when the mouse moves out of a cluster marker.
+ * @name MarkerClusterer#mouseout
+ * @param {Cluster} c The cluster that the mouse moved out of.
+ * @event
+ */
+ google.maps.event.trigger(mc, "mouseout", cClusterIcon.cluster_);
+ });
+};
+
+
+/**
+ * Removes the icon from the DOM.
+ */
+ClusterIcon.prototype.onRemove = function () {
+ if (this.div_ && this.div_.parentNode) {
+ this.hide();
+ google.maps.event.removeListener(this.boundsChangedListener_);
+ google.maps.event.clearInstanceListeners(this.div_);
+ this.div_.parentNode.removeChild(this.div_);
+ this.div_ = null;
+ }
+};
+
+
+/**
+ * Draws the icon.
+ */
+ClusterIcon.prototype.draw = function () {
+ if (this.visible_) {
+ var pos = this.getPosFromLatLng_(this.center_);
+ this.div_.style.top = pos.y + "px";
+ this.div_.style.left = pos.x + "px";
+ }
+};
+
+
+/**
+ * Hides the icon.
+ */
+ClusterIcon.prototype.hide = function () {
+ if (this.div_) {
+ this.div_.style.display = "none";
+ }
+ this.visible_ = false;
+};
+
+
+/**
+ * Positions and shows the icon.
+ */
+ClusterIcon.prototype.show = function () {
+ if (this.div_) {
+ var img = "";
+ // NOTE: values must be specified in px units
+ var bp = this.backgroundPosition_.split(" ");
+ var spriteH = parseInt(bp[0].replace(/^\s+|\s+$/g, ""), 10);
+ var spriteV = parseInt(bp[1].replace(/^\s+|\s+$/g, ""), 10);
+ var pos = this.getPosFromLatLng_(this.center_);
+ this.div_.style.cssText = this.createCss(pos);
+ img = "<img src='" + this.url_ + "' style='position: absolute; top: " + spriteV + "px; left: " + spriteH + "px; ";
+ if (!this.cluster_.getMarkerClusterer().enableRetinaIcons_) {
+ img += "clip: rect(" + (-1 * spriteV) + "px, " + ((-1 * spriteH) + this.width_) + "px, " +
+ ((-1 * spriteV) + this.height_) + "px, " + (-1 * spriteH) + "px);";
+ }
+ img += "'>";
+ this.div_.innerHTML = img + "<div style='" +
+ "position: absolute;" +
+ "top: " + this.anchorText_[0] + "px;" +
+ "left: " + this.anchorText_[1] + "px;" +
+ "color: " + this.textColor_ + ";" +
+ "font-size: " + this.textSize_ + "px;" +
+ "font-family: " + this.fontFamily_ + ";" +
+ "font-weight: " + this.fontWeight_ + ";" +
+ "font-style: " + this.fontStyle_ + ";" +
+ "text-decoration: " + this.textDecoration_ + ";" +
+ "text-align: center;" +
+ "width: " + this.width_ + "px;" +
+ "line-height:" + this.height_ + "px;" +
+ "'>" + this.sums_.text + "</div>";
+ if (typeof this.sums_.title === "undefined" || this.sums_.title === "") {
+ this.div_.title = this.cluster_.getMarkerClusterer().getTitle();
+ } else {
+ this.div_.title = this.sums_.title;
+ }
+ this.div_.style.display = "";
+ }
+ this.visible_ = true;
+};
+
+
+/**
+ * Sets the icon styles to the appropriate element in the styles array.
+ *
+ * @param {ClusterIconInfo} sums The icon label text and styles index.
+ */
+ClusterIcon.prototype.useStyle = function (sums) {
+ this.sums_ = sums;
+ var index = Math.max(0, sums.index - 1);
+ index = Math.min(this.styles_.length - 1, index);
+ var style = this.styles_[index];
+ this.url_ = style.url;
+ this.height_ = style.height;
+ this.width_ = style.width;
+ this.anchorText_ = style.anchorText || [0, 0];
+ this.anchorIcon_ = style.anchorIcon || [parseInt(this.height_ / 2, 10), parseInt(this.width_ / 2, 10)];
+ this.textColor_ = style.textColor || "black";
+ this.textSize_ = style.textSize || 11;
+ this.textDecoration_ = style.textDecoration || "none";
+ this.fontWeight_ = style.fontWeight || "bold";
+ this.fontStyle_ = style.fontStyle || "normal";
+ this.fontFamily_ = style.fontFamily || "Arial,sans-serif";
+ this.backgroundPosition_ = style.backgroundPosition || "0 0";
+};
+
+
+/**
+ * Sets the position at which to center the icon.
+ *
+ * @param {google.maps.LatLng} center The latlng to set as the center.
+ */
+ClusterIcon.prototype.setCenter = function (center) {
+ this.center_ = center;
+};
+
+
+/**
+ * Creates the cssText style parameter based on the position of the icon.
+ *
+ * @param {google.maps.Point} pos The position of the icon.
+ * @return {string} The CSS style text.
+ */
+ClusterIcon.prototype.createCss = function (pos) {
+ var style = [];
+ style.push("cursor: pointer;");
+ style.push("position: absolute; top: " + pos.y + "px; left: " + pos.x + "px;");
+ style.push("width: " + this.width_ + "px; height: " + this.height_ + "px;");
+ return style.join("");
+};
+
+
+/**
+ * Returns the position at which to place the DIV depending on the latlng.
+ *
+ * @param {google.maps.LatLng} latlng The position in latlng.
+ * @return {google.maps.Point} The position in pixels.
+ */
+ClusterIcon.prototype.getPosFromLatLng_ = function (latlng) {
+ var pos = this.getProjection().fromLatLngToDivPixel(latlng);
+ pos.x -= this.anchorIcon_[1];
+ pos.y -= this.anchorIcon_[0];
+ pos.x = parseInt(pos.x, 10);
+ pos.y = parseInt(pos.y, 10);
+ return pos;
+};
+
+
+/**
+ * Creates a single cluster that manages a group of proximate markers.
+ * Used internally, do not call this constructor directly.
+ * @constructor
+ * @param {MarkerClusterer} mc The <code>MarkerClusterer</code> object with which this
+ * cluster is associated.
+ */
+function Cluster(mc) {
+ this.markerClusterer_ = mc;
+ this.map_ = mc.getMap();
+ this.gridSize_ = mc.getGridSize();
+ this.minClusterSize_ = mc.getMinimumClusterSize();
+ this.averageCenter_ = mc.getAverageCenter();
+ this.markers_ = [];
+ this.center_ = null;
+ this.bounds_ = null;
+ this.clusterIcon_ = new ClusterIcon(this, mc.getStyles());
+}
+
+
+/**
+ * Returns the number of markers managed by the cluster. You can call this from
+ * a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
+ * for the <code>MarkerClusterer</code> object.
+ *
+ * @return {number} The number of markers in the cluster.
+ */
+Cluster.prototype.getSize = function () {
+ return this.markers_.length;
+};
+
+
+/**
+ * Returns the array of markers managed by the cluster. You can call this from
+ * a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
+ * for the <code>MarkerClusterer</code> object.
+ *
+ * @return {Array} The array of markers in the cluster.
+ */
+Cluster.prototype.getMarkers = function () {
+ return this.markers_;
+};
+
+
+/**
+ * Returns the center of the cluster. You can call this from
+ * a <code>click</code>, <code>mouseover</code>, or <code>mouseout</code> event handler
+ * for the <code>MarkerClusterer</code> object.
+ *
+ * @return {google.maps.LatLng} The center of the cluster.
+ */
+Cluster.prototype.getCenter = function () {
+ return this.center_;
+};
+
+
+/**
+ * Returns the map with which the cluster is associated.
+ *
+ * @return {google.maps.Map} The map.
+ * @ignore
+ */
+Cluster.prototype.getMap = function () {
+ return this.map_;
+};
+
+
+/**
+ * Returns the <code>MarkerClusterer</code> object with which the cluster is associated.
+ *
+ * @return {MarkerClusterer} The associated marker clusterer.
+ * @ignore
+ */
+Cluster.prototype.getMarkerClusterer = function () {
+ return this.markerClusterer_;
+};
+
+
+/**
+ * Returns the bounds of the cluster.
+ *
+ * @return {google.maps.LatLngBounds} the cluster bounds.
+ * @ignore
+ */
+Cluster.prototype.getBounds = function () {
+ var i;
+ var bounds = new google.maps.LatLngBounds(this.center_, this.center_);
+ var markers = this.getMarkers();
+ for (i = 0; i < markers.length; i++) {
+ bounds.extend(markers[i].getPosition());
+ }
+ return bounds;
+};
+
+
+/**
+ * Removes the cluster from the map.
+ *
+ * @ignore
+ */
+Cluster.prototype.remove = function () {
+ this.clusterIcon_.setMap(null);
+ this.markers_ = [];
+ delete this.markers_;
+};
+
+
+/**
+ * Adds a marker to the cluster.
+ *
+ * @param {google.maps.Marker} marker The marker to be added.
+ * @return {boolean} True if the marker was added.
+ * @ignore
+ */
+Cluster.prototype.addMarker = function (marker) {
+ var i;
+ var mCount;
+ var mz;
+
+ if (this.isMarkerAlreadyAdded_(marker)) {
+ return false;
+ }
+
+ if (!this.center_) {
+ this.center_ = marker.getPosition();
+ this.calculateBounds_();
+ } else {
+ if (this.averageCenter_) {
+ var l = this.markers_.length + 1;
+ var lat = (this.center_.lat() * (l - 1) + marker.getPosition().lat()) / l;
+ var lng = (this.center_.lng() * (l - 1) + marker.getPosition().lng()) / l;
+ this.center_ = new google.maps.LatLng(lat, lng);
+ this.calculateBounds_();
+ }
+ }
+
+ marker.isAdded = true;
+ this.markers_.push(marker);
+
+ mCount = this.markers_.length;
+ mz = this.markerClusterer_.getMaxZoom();
+ if (mz !== null && this.map_.getZoom() > mz) {
+ // Zoomed in past max zoom, so show the marker.
+ if (marker.getMap() !== this.map_) {
+ marker.setMap(this.map_);
+ }
+ } else if (mCount < this.minClusterSize_) {
+ // Min cluster size not reached so show the marker.
+ if (marker.getMap() !== this.map_) {
+ marker.setMap(this.map_);
+ }
+ } else if (mCount === this.minClusterSize_) {
+ // Hide the markers that were showing.
+ for (i = 0; i < mCount; i++) {
+ this.markers_[i].setMap(null);
+ }
+ } else {
+ marker.setMap(null);
+ }
+
+ this.updateIcon_();
+ return true;
+};
+
+
+/**
+ * Determines if a marker lies within the cluster's bounds.
+ *
+ * @param {google.maps.Marker} marker The marker to check.
+ * @return {boolean} True if the marker lies in the bounds.
+ * @ignore
+ */
+Cluster.prototype.isMarkerInClusterBounds = function (marker) {
+ return this.bounds_.contains(marker.getPosition());
+};
+
+
+/**
+ * Calculates the extended bounds of the cluster with the grid.
+ */
+Cluster.prototype.calculateBounds_ = function () {
+ var bounds = new google.maps.LatLngBounds(this.center_, this.center_);
+ this.bounds_ = this.markerClusterer_.getExtendedBounds(bounds);
+};
+
+
+/**
+ * Updates the cluster icon.
+ */
+Cluster.prototype.updateIcon_ = function () {
+ var mCount = this.markers_.length;
+ var mz = this.markerClusterer_.getMaxZoom();
+
+ if (mz !== null && this.map_.getZoom() > mz) {
+ this.clusterIcon_.hide();
+ return;
+ }
+
+ if (mCount < this.minClusterSize_) {
+ // Min cluster size not yet reached.
+ this.clusterIcon_.hide();
+ return;
+ }
+
+ var numStyles = this.markerClusterer_.getStyles().length;
+ var sums = this.markerClusterer_.getCalculator()(this.markers_, numStyles);
+ this.clusterIcon_.setCenter(this.center_);
+ this.clusterIcon_.useStyle(sums);
+ this.clusterIcon_.show();
+};
+
+
+/**
+ * Determines if a marker has already been added to the cluster.
+ *
+ * @param {google.maps.Marker} marker The marker to check.
+ * @return {boolean} True if the marker has already been added.
+ */
+Cluster.prototype.isMarkerAlreadyAdded_ = function (marker) {
+ var i;
+ if (this.markers_.indexOf) {
+ return this.markers_.indexOf(marker) !== -1;
+ } else {
+ for (i = 0; i < this.markers_.length; i++) {
+ if (marker === this.markers_[i]) {
+ return true;
+ }
+ }
+ }
+ return false;
+};
+
+
+/**
+ * @name MarkerClustererOptions
+ * @class This class represents the optional parameter passed to
+ * the {@link MarkerClusterer} constructor.
+ * @property {number} [gridSize=60] The grid size of a cluster in pixels. The grid is a square.
+ * @property {number} [maxZoom=null] The maximum zoom level at which clustering is enabled or
+ * <code>null</code> if clustering is to be enabled at all zoom levels.
+ * @property {boolean} [zoomOnClick=true] Whether to zoom the map when a cluster marker is
+ * clicked. You may want to set this to <code>false</code> if you have installed a handler
+ * for the <code>click</code> event and it deals with zooming on its own.
+ * @property {boolean} [averageCenter=false] Whether the position of a cluster marker should be
+ * the average position of all markers in the cluster. If set to <code>false</code>, the
+ * cluster marker is positioned at the location of the first marker added to the cluster.
+ * @property {number} [minimumClusterSize=2] The minimum number of markers needed in a cluster
+ * before the markers are hidden and a cluster marker appears.
+ * @property {boolean} [ignoreHidden=false] Whether to ignore hidden markers in clusters. You
+ * may want to set this to <code>true</code> to ensure that hidden markers are not included
+ * in the marker count that appears on a cluster marker (this count is the value of the
+ * <code>text</code> property of the result returned by the default <code>calculator</code>).
+ * If set to <code>true</code> and you change the visibility of a marker being clustered, be
+ * sure to also call <code>MarkerClusterer.repaint()</code>.
+ * @property {string} [title=""] The tooltip to display when the mouse moves over a cluster
+ * marker. (Alternatively, you can use a custom <code>calculator</code> function to specify a
+ * different tooltip for each cluster marker.)
+ * @property {function} [calculator=MarkerClusterer.CALCULATOR] The function used to determine
+ * the text to be displayed on a cluster marker and the index indicating which style to use
+ * for the cluster marker. The input parameters for the function are (1) the array of markers
+ * represented by a cluster marker and (2) the number of cluster icon styles. It returns a
+ * {@link ClusterIconInfo} object. The default <code>calculator</code> returns a
+ * <code>text</code> property which is the number of markers in the cluster and an
+ * <code>index</code> property which is one higher than the lowest integer such that
+ * <code>10^i</code> exceeds the number of markers in the cluster, or the size of the styles
+ * array, whichever is less. The <code>styles</code> array element used has an index of
+ * <code>index</code> minus 1. For example, the default <code>calculator</code> returns a
+ * <code>text</code> value of <code>"125"</code> and an <code>index</code> of <code>3</code>
+ * for a cluster icon representing 125 markers so the element used in the <code>styles</code>
+ * array is <code>2</code>. A <code>calculator</code> may also return a <code>title</code>
+ * property that contains the text of the tooltip to be used for the cluster marker. If
+ * <code>title</code> is not defined, the tooltip is set to the value of the <code>title</code>
+ * property for the MarkerClusterer.
+ * @property {string} [clusterClass="cluster"] The name of the CSS class defining general styles
+ * for the cluster markers. Use this class to define CSS styles that are not set up by the code
+ * that processes the <code>styles</code> array.
+ * @property {Array} [styles] An array of {@link ClusterIconStyle} elements defining the styles
+ * of the cluster markers to be used. The element to be used to style a given cluster marker
+ * is determined by the function defined by the <code>calculator</code> property.
+ * The default is an array of {@link ClusterIconStyle} elements whose properties are derived
+ * from the values for <code>imagePath</code>, <code>imageExtension</code>, and
+ * <code>imageSizes</code>.
+ * @property {boolean} [enableRetinaIcons=false] Whether to allow the use of cluster icons that
+ * have sizes that are some multiple (typically double) of their actual display size. Icons such
+ * as these look better when viewed on high-resolution monitors such as Apple's Retina displays.
+ * Note: if this property is <code>true</code>, sprites cannot be used as cluster icons.
+ * @property {number} [batchSize=MarkerClusterer.BATCH_SIZE] Set this property to the
+ * number of markers to be processed in a single batch when using a browser other than
+ * Internet Explorer (for Internet Explorer, use the batchSizeIE property instead).
+ * @property {number} [batchSizeIE=MarkerClusterer.BATCH_SIZE_IE] When Internet Explorer is
+ * being used, markers are processed in several batches with a small delay inserted between
+ * each batch in an attempt to avoid Javascript timeout errors. Set this property to the
+ * number of markers to be processed in a single batch; select as high a number as you can
+ * without causing a timeout error in the browser. This number might need to be as low as 100
+ * if 15,000 markers are being managed, for example.
+ * @property {string} [imagePath=MarkerClusterer.IMAGE_PATH]
+ * The full URL of the root name of the group of image files to use for cluster icons.
+ * The complete file name is of the form <code>imagePath</code>n.<code>imageExtension</code>
+ * where n is the image file number (1, 2, etc.).
+ * @property {string} [imageExtension=MarkerClusterer.IMAGE_EXTENSION]
+ * The extension name for the cluster icon image files (e.g., <code>"png"</code> or
+ * <code>"jpg"</code>).
+ * @property {Array} [imageSizes=MarkerClusterer.IMAGE_SIZES]
+ * An array of numbers containing the widths of the group of
+ * <code>imagePath</code>n.<code>imageExtension</code> image files.
+ * (The images are assumed to be square.)
+ */
+/**
+ * Creates a MarkerClusterer object with the options specified in {@link MarkerClustererOptions}.
+ * @constructor
+ * @extends google.maps.OverlayView
+ * @param {google.maps.Map} map The Google map to attach to.
+ * @param {Array.<google.maps.Marker>} [opt_markers] The markers to be added to the cluster.
+ * @param {MarkerClustererOptions} [opt_options] The optional parameters.
+ */
+function MarkerClusterer(map, opt_markers, opt_options) {
+ // MarkerClusterer implements google.maps.OverlayView interface. We use the
+ // extend function to extend MarkerClusterer with google.maps.OverlayView
+ // because it might not always be available when the code is defined so we
+ // look for it at the last possible moment. If it doesn't exist now then
+ // there is no point going ahead :)
+ this.extend(MarkerClusterer, google.maps.OverlayView);
+
+ opt_markers = opt_markers || [];
+ opt_options = opt_options || {};
+
+ this.markers_ = [];
+ this.clusters_ = [];
+ this.listeners_ = [];
+ this.activeMap_ = null;
+ this.ready_ = false;
+
+ this.gridSize_ = opt_options.gridSize || 60;
+ this.minClusterSize_ = opt_options.minimumClusterSize || 2;
+ this.maxZoom_ = opt_options.maxZoom || null;
+ this.styles_ = opt_options.styles || [];
+ this.title_ = opt_options.title || "";
+ this.zoomOnClick_ = true;
+ if (opt_options.zoomOnClick !== undefined) {
+ this.zoomOnClick_ = opt_options.zoomOnClick;
+ }
+ this.averageCenter_ = false;
+ if (opt_options.averageCenter !== undefined) {
+ this.averageCenter_ = opt_options.averageCenter;
+ }
+ this.ignoreHidden_ = false;
+ if (opt_options.ignoreHidden !== undefined) {
+ this.ignoreHidden_ = opt_options.ignoreHidden;
+ }
+ this.enableRetinaIcons_ = false;
+ if (opt_options.enableRetinaIcons !== undefined) {
+ this.enableRetinaIcons_ = opt_options.enableRetinaIcons;
+ }
+ this.imagePath_ = opt_options.imagePath || MarkerClusterer.IMAGE_PATH;
+ this.imageExtension_ = opt_options.imageExtension || MarkerClusterer.IMAGE_EXTENSION;
+ this.imageSizes_ = opt_options.imageSizes || MarkerClusterer.IMAGE_SIZES;
+ this.calculator_ = opt_options.calculator || MarkerClusterer.CALCULATOR;
+ this.batchSize_ = opt_options.batchSize || MarkerClusterer.BATCH_SIZE;
+ this.batchSizeIE_ = opt_options.batchSizeIE || MarkerClusterer.BATCH_SIZE_IE;
+ this.clusterClass_ = opt_options.clusterClass || "cluster";
+
+ if (navigator.userAgent.toLowerCase().indexOf("msie") !== -1) {
+ // Try to avoid IE timeout when processing a huge number of markers:
+ this.batchSize_ = this.batchSizeIE_;
+ }
+
+ this.setupStyles_();
+
+ this.addMarkers(opt_markers, true);
+ this.setMap(map); // Note: this causes onAdd to be called
+}
+
+
+/**
+ * Implementation of the onAdd interface method.
+ * @ignore
+ */
+MarkerClusterer.prototype.onAdd = function () {
+ var cMarkerClusterer = this;
+
+ this.activeMap_ = this.getMap();
+ this.ready_ = true;
+
+ this.repaint();
+
+ // Add the map event listeners
+ this.listeners_ = [
+ google.maps.event.addListener(this.getMap(), "zoom_changed", function () {
+ cMarkerClusterer.resetViewport_(false);
+ // Workaround for this Google bug: when map is at level 0 and "-" of
+ // zoom slider is clicked, a "zoom_changed" event is fired even though
+ // the map doesn't zoom out any further. In this situation, no "idle"
+ // event is triggered so the cluster markers that have been removed
+ // do not get redrawn. Same goes for a zoom in at maxZoom.
+ if (this.getZoom() === (this.get("minZoom") || 0) || this.getZoom() === this.get("maxZoom")) {
+ google.maps.event.trigger(this, "idle");
+ }
+ }),
+ google.maps.event.addListener(this.getMap(), "idle", function () {
+ cMarkerClusterer.redraw_();
+ })
+ ];
+};
+
+
+/**
+ * Implementation of the onRemove interface method.
+ * Removes map event listeners and all cluster icons from the DOM.
+ * All managed markers are also put back on the map.
+ * @ignore
+ */
+MarkerClusterer.prototype.onRemove = function () {
+ var i;
+
+ // Put all the managed markers back on the map:
+ for (i = 0; i < this.markers_.length; i++) {
+ if (this.markers_[i].getMap() !== this.activeMap_) {
+ this.markers_[i].setMap(this.activeMap_);
+ }
+ }
+
+ // Remove all clusters:
+ for (i = 0; i < this.clusters_.length; i++) {
+ this.clusters_[i].remove();
+ }
+ this.clusters_ = [];
+
+ // Remove map event listeners:
+ for (i = 0; i < this.listeners_.length; i++) {
+ google.maps.event.removeListener(this.listeners_[i]);
+ }
+ this.listeners_ = [];
+
+ this.activeMap_ = null;
+ this.ready_ = false;
+};
+
+
+/**
+ * Implementation of the draw interface method.
+ * @ignore
+ */
+MarkerClusterer.prototype.draw = function () {};
+
+
+/**
+ * Sets up the styles object.
+ */
+MarkerClusterer.prototype.setupStyles_ = function () {
+ var i, size;
+ if (this.styles_.length > 0) {
+ return;
+ }
+
+ for (i = 0; i < this.imageSizes_.length; i++) {
+ size = this.imageSizes_[i];
+ this.styles_.push({
+ url: this.imagePath_ + (i + 1) + "." + this.imageExtension_,
+ height: size,
+ width: size
+ });
+ }
+};
+
+
+/**
+ * Fits the map to the bounds of the markers managed by the clusterer.
+ */
+MarkerClusterer.prototype.fitMapToMarkers = function () {
+ var i;
+ var markers = this.getMarkers();
+ var bounds = new google.maps.LatLngBounds();
+ for (i = 0; i < markers.length; i++) {
+ bounds.extend(markers[i].getPosition());
+ }
+
+ this.getMap().fitBounds(bounds);
+};
+
+
+/**
+ * Returns the value of the <code>gridSize</code> property.
+ *
+ * @return {number} The grid size.
+ */
+MarkerClusterer.prototype.getGridSize = function () {
+ return this.gridSize_;
+};
+
+
+/**
+ * Sets the value of the <code>gridSize</code> property.
+ *
+ * @param {number} gridSize The grid size.
+ */
+MarkerClusterer.prototype.setGridSize = function (gridSize) {
+ this.gridSize_ = gridSize;
+};
+
+
+/**
+ * Returns the value of the <code>minimumClusterSize</code> property.
+ *
+ * @return {number} The minimum cluster size.
+ */
+MarkerClusterer.prototype.getMinimumClusterSize = function () {
+ return this.minClusterSize_;
+};
+
+/**
+ * Sets the value of the <code>minimumClusterSize</code> property.
+ *
+ * @param {number} minimumClusterSize The minimum cluster size.
+ */
+MarkerClusterer.prototype.setMinimumClusterSize = function (minimumClusterSize) {
+ this.minClusterSize_ = minimumClusterSize;
+};
+
+
+/**
+ * Returns the value of the <code>maxZoom</code> property.
+ *
+ * @return {number} The maximum zoom level.
+ */
+MarkerClusterer.prototype.getMaxZoom = function () {
+ return this.maxZoom_;
+};
+
+
+/**
+ * Sets the value of the <code>maxZoom</code> property.
+ *
+ * @param {number} maxZoom The maximum zoom level.
+ */
+MarkerClusterer.prototype.setMaxZoom = function (maxZoom) {
+ this.maxZoom_ = maxZoom;
+};
+
+
+/**
+ * Returns the value of the <code>styles</code> property.
+ *
+ * @return {Array} The array of styles defining the cluster markers to be used.
+ */
+MarkerClusterer.prototype.getStyles = function () {
+ return this.styles_;
+};
+
+
+/**
+ * Sets the value of the <code>styles</code> property.
+ *
+ * @param {Array.<ClusterIconStyle>} styles The array of styles to use.
+ */
+MarkerClusterer.prototype.setStyles = function (styles) {
+ this.styles_ = styles;
+};
+
+
+/**
+ * Returns the value of the <code>title</code> property.
+ *
+ * @return {string} The content of the title text.
+ */
+MarkerClusterer.prototype.getTitle = function () {
+ return this.title_;
+};
+
+
+/**
+ * Sets the value of the <code>title</code> property.
+ *
+ * @param {string} title The value of the title property.
+ */
+MarkerClusterer.prototype.setTitle = function (title) {
+ this.title_ = title;
+};
+
+
+/**
+ * Returns the value of the <code>zoomOnClick</code> property.
+ *
+ * @return {boolean} True if zoomOnClick property is set.
+ */
+MarkerClusterer.prototype.getZoomOnClick = function () {
+ return this.zoomOnClick_;
+};
+
+
+/**
+ * Sets the value of the <code>zoomOnClick</code> property.
+ *
+ * @param {boolean} zoomOnClick The value of the zoomOnClick property.
+ */
+MarkerClusterer.prototype.setZoomOnClick = function (zoomOnClick) {
+ this.zoomOnClick_ = zoomOnClick;
+};
+
+
+/**
+ * Returns the value of the <code>averageCenter</code> property.
+ *
+ * @return {boolean} True if averageCenter property is set.
+ */
+MarkerClusterer.prototype.getAverageCenter = function () {
+ return this.averageCenter_;
+};
+
+
+/**
+ * Sets the value of the <code>averageCenter</code> property.
+ *
+ * @param {boolean} averageCenter The value of the averageCenter property.
+ */
+MarkerClusterer.prototype.setAverageCenter = function (averageCenter) {
+ this.averageCenter_ = averageCenter;
+};
+
+
+/**
+ * Returns the value of the <code>ignoreHidden</code> property.
+ *
+ * @return {boolean} True if ignoreHidden property is set.
+ */
+MarkerClusterer.prototype.getIgnoreHidden = function () {
+ return this.ignoreHidden_;
+};
+
+
+/**
+ * Sets the value of the <code>ignoreHidden</code> property.
+ *
+ * @param {boolean} ignoreHidden The value of the ignoreHidden property.
+ */
+MarkerClusterer.prototype.setIgnoreHidden = function (ignoreHidden) {
+ this.ignoreHidden_ = ignoreHidden;
+};
+
+
+/**
+ * Returns the value of the <code>enableRetinaIcons</code> property.
+ *
+ * @return {boolean} True if enableRetinaIcons property is set.
+ */
+MarkerClusterer.prototype.getEnableRetinaIcons = function () {
+ return this.enableRetinaIcons_;
+};
+
+
+/**
+ * Sets the value of the <code>enableRetinaIcons</code> property.
+ *
+ * @param {boolean} enableRetinaIcons The value of the enableRetinaIcons property.
+ */
+MarkerClusterer.prototype.setEnableRetinaIcons = function (enableRetinaIcons) {
+ this.enableRetinaIcons_ = enableRetinaIcons;
+};
+
+
+/**
+ * Returns the value of the <code>imageExtension</code> property.
+ *
+ * @return {string} The value of the imageExtension property.
+ */
+MarkerClusterer.prototype.getImageExtension = function () {
+ return this.imageExtension_;
+};
+
+
+/**
+ * Sets the value of the <code>imageExtension</code> property.
+ *
+ * @param {string} imageExtension The value of the imageExtension property.
+ */
+MarkerClusterer.prototype.setImageExtension = function (imageExtension) {
+ this.imageExtension_ = imageExtension;
+};
+
+
+/**
+ * Returns the value of the <code>imagePath</code> property.
+ *
+ * @return {string} The value of the imagePath property.
+ */
+MarkerClusterer.prototype.getImagePath = function () {
+ return this.imagePath_;
+};
+
+
+/**
+ * Sets the value of the <code>imagePath</code> property.
+ *
+ * @param {string} imagePath The value of the imagePath property.
+ */
+MarkerClusterer.prototype.setImagePath = function (imagePath) {
+ this.imagePath_ = imagePath;
+};
+
+
+/**
+ * Returns the value of the <code>imageSizes</code> property.
+ *
+ * @return {Array} The value of the imageSizes property.
+ */
+MarkerClusterer.prototype.getImageSizes = function () {
+ return this.imageSizes_;
+};
+
+
+/**
+ * Sets the value of the <code>imageSizes</code> property.
+ *
+ * @param {Array} imageSizes The value of the imageSizes property.
+ */
+MarkerClusterer.prototype.setImageSizes = function (imageSizes) {
+ this.imageSizes_ = imageSizes;
+};
+
+
+/**
+ * Returns the value of the <code>calculator</code> property.
+ *
+ * @return {function} the value of the calculator property.
+ */
+MarkerClusterer.prototype.getCalculator = function () {
+ return this.calculator_;
+};
+
+
+/**
+ * Sets the value of the <code>calculator</code> property.
+ *
+ * @param {function(Array.<google.maps.Marker>, number)} calculator The value
+ * of the calculator property.
+ */
+MarkerClusterer.prototype.setCalculator = function (calculator) {
+ this.calculator_ = calculator;
+};
+
+
+/**
+ * Returns the value of the <code>batchSizeIE</code> property.
+ *
+ * @return {number} the value of the batchSizeIE property.
+ */
+MarkerClusterer.prototype.getBatchSizeIE = function () {
+ return this.batchSizeIE_;
+};
+
+
+/**
+ * Sets the value of the <code>batchSizeIE</code> property.
+ *
+ * @param {number} batchSizeIE The value of the batchSizeIE property.
+ */
+MarkerClusterer.prototype.setBatchSizeIE = function (batchSizeIE) {
+ this.batchSizeIE_ = batchSizeIE;
+};
+
+
+/**
+ * Returns the value of the <code>clusterClass</code> property.
+ *
+ * @return {string} the value of the clusterClass property.
+ */
+MarkerClusterer.prototype.getClusterClass = function () {
+ return this.clusterClass_;
+};
+
+
+/**
+ * Sets the value of the <code>clusterClass</code> property.
+ *
+ * @param {string} clusterClass The value of the clusterClass property.
+ */
+MarkerClusterer.prototype.setClusterClass = function (clusterClass) {
+ this.clusterClass_ = clusterClass;
+};
+
+
+/**
+ * Returns the array of markers managed by the clusterer.
+ *
+ * @return {Array} The array of markers managed by the clusterer.
+ */
+MarkerClusterer.prototype.getMarkers = function () {
+ return this.markers_;
+};
+
+
+/**
+ * Returns the number of markers managed by the clusterer.
+ *
+ * @return {number} The number of markers.
+ */
+MarkerClusterer.prototype.getTotalMarkers = function () {
+ return this.markers_.length;
+};
+
+
+/**
+ * Returns the current array of clusters formed by the clusterer.
+ *
+ * @return {Array} The array of clusters formed by the clusterer.
+ */
+MarkerClusterer.prototype.getClusters = function () {
+ return this.clusters_;
+};
+
+
+/**
+ * Returns the number of clusters formed by the clusterer.
+ *
+ * @return {number} The number of clusters formed by the clusterer.
+ */
+MarkerClusterer.prototype.getTotalClusters = function () {
+ return this.clusters_.length;
+};
+
+
+/**
+ * Adds a marker to the clusterer. The clusters are redrawn unless
+ * <code>opt_nodraw</code> is set to <code>true</code>.
+ *
+ * @param {google.maps.Marker} marker The marker to add.
+ * @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
+ */
+MarkerClusterer.prototype.addMarker = function (marker, opt_nodraw) {
+ this.pushMarkerTo_(marker);
+ if (!opt_nodraw) {
+ this.redraw_();
+ }
+};
+
+
+/**
+ * Adds an array of markers to the clusterer. The clusters are redrawn unless
+ * <code>opt_nodraw</code> is set to <code>true</code>.
+ *
+ * @param {Array.<google.maps.Marker>} markers The markers to add.
+ * @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
+ */
+MarkerClusterer.prototype.addMarkers = function (markers, opt_nodraw) {
+ var key;
+ for (key in markers) {
+ if (markers.hasOwnProperty(key)) {
+ this.pushMarkerTo_(markers[key]);
+ }
+ }
+ if (!opt_nodraw) {
+ this.redraw_();
+ }
+};
+
+
+/**
+ * Pushes a marker to the clusterer.
+ *
+ * @param {google.maps.Marker} marker The marker to add.
+ */
+MarkerClusterer.prototype.pushMarkerTo_ = function (marker) {
+ // If the marker is draggable add a listener so we can update the clusters on the dragend:
+ if (marker.getDraggable()) {
+ var cMarkerClusterer = this;
+ google.maps.event.addListener(marker, "dragend", function () {
+ if (cMarkerClusterer.ready_) {
+ this.isAdded = false;
+ cMarkerClusterer.repaint();
+ }
+ });
+ }
+ marker.isAdded = false;
+ this.markers_.push(marker);
+};
+
+
+/**
+ * Removes a marker from the cluster. The clusters are redrawn unless
+ * <code>opt_nodraw</code> is set to <code>true</code>. Returns <code>true</code> if the
+ * marker was removed from the clusterer.
+ *
+ * @param {google.maps.Marker} marker The marker to remove.
+ * @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
+ * @return {boolean} True if the marker was removed from the clusterer.
+ */
+MarkerClusterer.prototype.removeMarker = function (marker, opt_nodraw) {
+ var removed = this.removeMarker_(marker);
+
+ if (!opt_nodraw && removed) {
+ this.repaint();
+ }
+
+ return removed;
+};
+
+
+/**
+ * Removes an array of markers from the cluster. The clusters are redrawn unless
+ * <code>opt_nodraw</code> is set to <code>true</code>. Returns <code>true</code> if markers
+ * were removed from the clusterer.
+ *
+ * @param {Array.<google.maps.Marker>} markers The markers to remove.
+ * @param {boolean} [opt_nodraw] Set to <code>true</code> to prevent redrawing.
+ * @return {boolean} True if markers were removed from the clusterer.
+ */
+MarkerClusterer.prototype.removeMarkers = function (markers, opt_nodraw) {
+ var i, r;
+ var removed = false;
+
+ for (i = 0; i < markers.length; i++) {
+ r = this.removeMarker_(markers[i]);
+ removed = removed || r;
+ }
+
+ if (!opt_nodraw && removed) {
+ this.repaint();
+ }
+
+ return removed;
+};
+
+
+/**
+ * Removes a marker and returns true if removed, false if not.
+ *
+ * @param {google.maps.Marker} marker The marker to remove
+ * @return {boolean} Whether the marker was removed or not
+ */
+MarkerClusterer.prototype.removeMarker_ = function (marker) {
+ var i;
+ var index = -1;
+ if (this.markers_.indexOf) {
+ index = this.markers_.indexOf(marker);
+ } else {
+ for (i = 0; i < this.markers_.length; i++) {
+ if (marker === this.markers_[i]) {
+ index = i;
+ break;
+ }
+ }
+ }
+
+ if (index === -1) {
+ // Marker is not in our list of markers, so do nothing:
+ return false;
+ }
+
+ marker.setMap(null);
+ this.markers_.splice(index, 1); // Remove the marker from the list of managed markers
+ return true;
+};
+
+
+/**
+ * Removes all clusters and markers from the map and also removes all markers
+ * managed by the clusterer.
+ */
+MarkerClusterer.prototype.clearMarkers = function () {
+ this.resetViewport_(true);
+ this.markers_ = [];
+};
+
+
+/**
+ * Recalculates and redraws all the marker clusters from scratch.
+ * Call this after changing any properties.
+ */
+MarkerClusterer.prototype.repaint = function () {
+ var oldClusters = this.clusters_.slice();
+ this.clusters_ = [];
+ this.resetViewport_(false);
+ this.redraw_();
+
+ // Remove the old clusters.
+ // Do it in a timeout to prevent blinking effect.
+ setTimeout(function () {
+ var i;
+ for (i = 0; i < oldClusters.length; i++) {
+ oldClusters[i].remove();
+ }
+ }, 0);
+};
+
+
+/**
+ * Returns the current bounds extended by the grid size.
+ *
+ * @param {google.maps.LatLngBounds} bounds The bounds to extend.
+ * @return {google.maps.LatLngBounds} The extended bounds.
+ * @ignore
+ */
+MarkerClusterer.prototype.getExtendedBounds = function (bounds) {
+ var projection = this.getProjection();
+
+ // Turn the bounds into latlng.
+ var tr = new google.maps.LatLng(bounds.getNorthEast().lat(),
+ bounds.getNorthEast().lng());
+ var bl = new google.maps.LatLng(bounds.getSouthWest().lat(),
+ bounds.getSouthWest().lng());
+
+ // Convert the points to pixels and the extend out by the grid size.
+ var trPix = projection.fromLatLngToDivPixel(tr);
+ trPix.x += this.gridSize_;
+ trPix.y -= this.gridSize_;
+
+ var blPix = projection.fromLatLngToDivPixel(bl);
+ blPix.x -= this.gridSize_;
+ blPix.y += this.gridSize_;
+
+ // Convert the pixel points back to LatLng
+ var ne = projection.fromDivPixelToLatLng(trPix);
+ var sw = projection.fromDivPixelToLatLng(blPix);
+
+ // Extend the bounds to contain the new bounds.
+ bounds.extend(ne);
+ bounds.extend(sw);
+
+ return bounds;
+};
+
+
+/**
+ * Redraws all the clusters.
+ */
+MarkerClusterer.prototype.redraw_ = function () {
+ this.createClusters_(0);
+};
+
+
+/**
+ * Removes all clusters from the map. The markers are also removed from the map
+ * if <code>opt_hide</code> is set to <code>true</code>.
+ *
+ * @param {boolean} [opt_hide] Set to <code>true</code> to also remove the markers
+ * from the map.
+ */
+MarkerClusterer.prototype.resetViewport_ = function (opt_hide) {
+ var i, marker;
+ // Remove all the clusters
+ for (i = 0; i < this.clusters_.length; i++) {
+ this.clusters_[i].remove();
+ }
+ this.clusters_ = [];
+
+ // Reset the markers to not be added and to be removed from the map.
+ for (i = 0; i < this.markers_.length; i++) {
+ marker = this.markers_[i];
+ marker.isAdded = false;
+ if (opt_hide) {
+ marker.setMap(null);
+ }
+ }
+};
+
+
+/**
+ * Calculates the distance between two latlng locations in km.
+ *
+ * @param {google.maps.LatLng} p1 The first lat lng point.
+ * @param {google.maps.LatLng} p2 The second lat lng point.
+ * @return {number} The distance between the two points in km.
+ * @see http://www.movable-type.co.uk/scripts/latlong.html
+ */
+MarkerClusterer.prototype.distanceBetweenPoints_ = function (p1, p2) {
+ var R = 6371; // Radius of the Earth in km
+ var dLat = (p2.lat() - p1.lat()) * Math.PI / 180;
+ var dLon = (p2.lng() - p1.lng()) * Math.PI / 180;
+ var a = Math.sin(dLat / 2) * Math.sin(dLat / 2) +
+ Math.cos(p1.lat() * Math.PI / 180) * Math.cos(p2.lat() * Math.PI / 180) *
+ Math.sin(dLon / 2) * Math.sin(dLon / 2);
+ var c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
+ var d = R * c;
+ return d;
+};
+
+
+/**
+ * Determines if a marker is contained in a bounds.
+ *
+ * @param {google.maps.Marker} marker The marker to check.
+ * @param {google.maps.LatLngBounds} bounds The bounds to check against.
+ * @return {boolean} True if the marker is in the bounds.
+ */
+MarkerClusterer.prototype.isMarkerInBounds_ = function (marker, bounds) {
+ return bounds.contains(marker.getPosition());
+};
+
+
+/**
+ * Adds a marker to a cluster, or creates a new cluster.
+ *
+ * @param {google.maps.Marker} marker The marker to add.
+ */
+MarkerClusterer.prototype.addToClosestCluster_ = function (marker) {
+ var i, d, cluster, center;
+ var distance = 40000; // Some large number
+ var clusterToAddTo = null;
+ for (i = 0; i < this.clusters_.length; i++) {
+ cluster = this.clusters_[i];
+ center = cluster.getCenter();
+ if (center) {
+ d = this.distanceBetweenPoints_(center, marker.getPosition());
+ if (d < distance) {
+ distance = d;
+ clusterToAddTo = cluster;
+ }
+ }
+ }
+
+ if (clusterToAddTo && clusterToAddTo.isMarkerInClusterBounds(marker)) {
+ clusterToAddTo.addMarker(marker);
+ } else {
+ cluster = new Cluster(this);
+ cluster.addMarker(marker);
+ this.clusters_.push(cluster);
+ }
+};
+
+
+/**
+ * Creates the clusters. This is done in batches to avoid timeout errors
+ * in some browsers when there is a huge number of markers.
+ *
+ * @param {number} iFirst The index of the first marker in the batch of
+ * markers to be added to clusters.
+ */
+MarkerClusterer.prototype.createClusters_ = function (iFirst) {
+ var i, marker;
+ var mapBounds;
+ var cMarkerClusterer = this;
+ if (!this.ready_) {
+ return;
+ }
+
+ // Cancel previous batch processing if we're working on the first batch:
+ if (iFirst === 0) {
+ /**
+ * This event is fired when the <code>MarkerClusterer</code> begins
+ * clustering markers.
+ * @name MarkerClusterer#clusteringbegin
+ * @param {MarkerClusterer} mc The MarkerClusterer whose markers are being clustered.
+ * @event
+ */
+ google.maps.event.trigger(this, "clusteringbegin", this);
+
+ if (typeof this.timerRefStatic !== "undefined") {
+ clearTimeout(this.timerRefStatic);
+ delete this.timerRefStatic;
+ }
+ }
+
+ // Get our current map view bounds.
+ // Create a new bounds object so we don't affect the map.
+ //
+ // See Comments 9 & 11 on Issue 3651 relating to this workaround for a Google Maps bug:
+ if (this.getMap().getZoom() > 3) {
+ mapBounds = new google.maps.LatLngBounds(this.getMap().getBounds().getSouthWest(),
+ this.getMap().getBounds().getNorthEast());
+ } else {
+ mapBounds = new google.maps.LatLngBounds(new google.maps.LatLng(85.02070771743472, -178.48388434375), new google.maps.LatLng(-85.08136444384544, 178.00048865625));
+ }
+ var bounds = this.getExtendedBounds(mapBounds);
+
+ var iLast = Math.min(iFirst + this.batchSize_, this.markers_.length);
+
+ for (i = iFirst; i < iLast; i++) {
+ marker = this.markers_[i];
+ if (!marker.isAdded && this.isMarkerInBounds_(marker, bounds)) {
+ if (!this.ignoreHidden_ || (this.ignoreHidden_ && marker.getVisible())) {
+ this.addToClosestCluster_(marker);
+ }
+ }
+ }
+
+ if (iLast < this.markers_.length) {
+ this.timerRefStatic = setTimeout(function () {
+ cMarkerClusterer.createClusters_(iLast);
+ }, 0);
+ } else {
+ delete this.timerRefStatic;
+
+ /**
+ * This event is fired when the <code>MarkerClusterer</code> stops
+ * clustering markers.
+ * @name MarkerClusterer#clusteringend
+ * @param {MarkerClusterer} mc The MarkerClusterer whose markers are being clustered.
+ * @event
+ */
+ google.maps.event.trigger(this, "clusteringend", this);
+ }
+};
+
+
+/**
+ * Extends an object's prototype by another's.
+ *
+ * @param {Object} obj1 The object to be extended.
+ * @param {Object} obj2 The object to extend with.
+ * @return {Object} The new extended object.
+ * @ignore
+ */
+MarkerClusterer.prototype.extend = function (obj1, obj2) {
+ return (function (object) {
+ var property;
+ for (property in object.prototype) {
+ this.prototype[property] = object.prototype[property];
+ }
+ return this;
+ }).apply(obj1, [obj2]);
+};
+
+
+/**
+ * The default function for determining the label text and style
+ * for a cluster icon.
+ *
+ * @param {Array.<google.maps.Marker>} markers The array of markers represented by the cluster.
+ * @param {number} numStyles The number of marker styles available.
+ * @return {ClusterIconInfo} The information resource for the cluster.
+ * @constant
+ * @ignore
+ */
+MarkerClusterer.CALCULATOR = function (markers, numStyles) {
+ var index = 0;
+ var title = "";
+ var count = markers.length.toString();
+
+ var dv = count;
+ while (dv !== 0) {
+ dv = parseInt(dv / 10, 10);
+ index++;
+ }
+
+ index = Math.min(index, numStyles);
+ return {
+ text: count,
+ index: index,
+ title: title
+ };
+};
+
+
+/**
+ * The number of markers to process in one batch.
+ *
+ * @type {number}
+ * @constant
+ */
+MarkerClusterer.BATCH_SIZE = 2000;
+
+
+/**
+ * The number of markers to process in one batch (IE only).
+ *
+ * @type {number}
+ * @constant
+ */
+MarkerClusterer.BATCH_SIZE_IE = 500;
+
+
+/**
+ * The default root name for the marker cluster images.
+ *
+ * @type {string}
+ * @constant
+ */
+MarkerClusterer.IMAGE_PATH = "../images/m";
+
+
+/**
+ * The default extension name for the marker cluster images.
+ *
+ * @type {string}
+ * @constant
+ */
+MarkerClusterer.IMAGE_EXTENSION = "png";
+
+
+/**
+ * The default array of sizes for the marker cluster images.
+ *
+ * @type {Array.<number>}
+ * @constant
+ */
+MarkerClusterer.IMAGE_SIZES = [53, 56, 66, 78, 90];
+
+window.MarkerClusterer = MarkerClusterer;
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.css b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.css
new file mode 100644
index 00000000..5ba559de
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.css
@@ -0,0 +1,13 @@
+.markerwithlabel {
+ color: black;
+ background-color: white;
+ font-family: "Lucida Grande", "Arial", sans-serif;
+ font-size: 12px;
+ text-align: center;
+ white-space: nowrap;
+ padding: 3px;
+ border-radius: 4px;
+ -moz-border-radius: 4px;
+ -webkit-border-radius: 4px;
+ border: 1px solid darkred;
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.js b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.js
new file mode 100644
index 00000000..90efe70e
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/gm3-util-library/markerwithlabel.js
@@ -0,0 +1,568 @@
+/**
+ * @name MarkerWithLabel for V3
+ * @version 1.1.5 [July 11, 2011]
+ * @author Gary Little (inspired by code from Marc Ridey of Google).
+ * @copyright Copyright 2010 Gary Little [gary at luxcentral.com]
+ * @fileoverview MarkerWithLabel extends the Google Maps JavaScript API V3
+ * <code>google.maps.Marker</code> class.
+ * <p>
+ * MarkerWithLabel allows you to define markers with associated labels. As you would expect,
+ * if the marker is draggable, so too will be the label. In addition, a marker with a label
+ * responds to all mouse events in the same manner as a regular marker. It also fires mouse
+ * events and "property changed" events just as a regular marker would. Version 1.1 adds
+ * support for the raiseOnDrag feature introduced in API V3.3.
+ * <p>
+ * If you drag a marker by its label, you can cancel the drag and return the marker to its
+ * original position by pressing the <code>Esc</code> key. This doesn't work if you drag the marker
+ * itself because this feature is not (yet) supported in the <code>google.maps.Marker</code> class.
+ */
+
+/*!
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/*jslint browser:true */
+/*global document,google */
+
+/**
+ * This constructor creates a label and associates it with a marker.
+ * It is for the private use of the MarkerWithLabel class.
+ * @constructor
+ * @param {Marker} marker The marker with which the label is to be associated.
+ * @param {string} crossURL The URL of the cross image =.
+ * @param {string} handCursor The URL of the hand cursor.
+ * @private
+ */
+function MarkerLabel_(marker, crossURL, handCursorURL) {
+ this.marker_ = marker;
+ this.handCursorURL_ = marker.handCursorURL;
+
+ this.labelDiv_ = document.createElement("div");
+ this.labelDiv_.style.cssText = "position: absolute; overflow: hidden;";
+
+ // Set up the DIV for handling mouse events in the label. This DIV forms a transparent veil
+ // in the "overlayMouseTarget" pane, a veil that covers just the label. This is done so that
+ // events can be captured even if the label is in the shadow of a google.maps.InfoWindow.
+ // Code is included here to ensure the veil is always exactly the same size as the label.
+ this.eventDiv_ = document.createElement("div");
+ this.eventDiv_.style.cssText = this.labelDiv_.style.cssText;
+
+ // This is needed for proper behavior on MSIE:
+ this.eventDiv_.setAttribute("onselectstart", "return false;");
+ this.eventDiv_.setAttribute("ondragstart", "return false;");
+
+ // Get the DIV for the "X" to be displayed when the marker is raised.
+ this.crossDiv_ = MarkerLabel_.getSharedCross(crossURL);
+}
+
+// MarkerLabel_ inherits from OverlayView:
+MarkerLabel_.prototype = new google.maps.OverlayView();
+
+/**
+ * Returns the DIV for the cross used when dragging a marker when the
+ * raiseOnDrag parameter set to true. One cross is shared with all markers.
+ * @param {string} crossURL The URL of the cross image =.
+ * @private
+ */
+MarkerLabel_.getSharedCross = function (crossURL) {
+ var div;
+ if (typeof MarkerLabel_.getSharedCross.crossDiv === "undefined") {
+ div = document.createElement("img");
+ div.style.cssText = "position: absolute; z-index: 1000002; display: none;";
+ // Hopefully Google never changes the standard "X" attributes:
+ div.style.marginLeft = "-8px";
+ div.style.marginTop = "-9px";
+ div.src = crossURL;
+ MarkerLabel_.getSharedCross.crossDiv = div;
+ }
+ return MarkerLabel_.getSharedCross.crossDiv;
+};
+
+/**
+ * Adds the DIV representing the label to the DOM. This method is called
+ * automatically when the marker's <code>setMap</code> method is called.
+ * @private
+ */
+MarkerLabel_.prototype.onAdd = function () {
+ var me = this;
+ var cMouseIsDown = false;
+ var cDraggingLabel = false;
+ var cSavedZIndex;
+ var cLatOffset, cLngOffset;
+ var cIgnoreClick;
+ var cRaiseEnabled;
+ var cStartPosition;
+ var cStartCenter;
+ // Constants:
+ var cRaiseOffset = 20;
+ var cDraggingCursor = "url(" + this.handCursorURL_ + ")";
+
+ // Stops all processing of an event.
+ //
+ var cAbortEvent = function (e) {
+ if (e.preventDefault) {
+ e.preventDefault();
+ }
+ e.cancelBubble = true;
+ if (e.stopPropagation) {
+ e.stopPropagation();
+ }
+ };
+
+ var cStopBounce = function () {
+ me.marker_.setAnimation(null);
+ };
+
+ this.getPanes().overlayImage.appendChild(this.labelDiv_);
+ this.getPanes().overlayMouseTarget.appendChild(this.eventDiv_);
+ // One cross is shared with all markers, so only add it once:
+ if (typeof MarkerLabel_.getSharedCross.processed === "undefined") {
+ this.getPanes().overlayImage.appendChild(this.crossDiv_);
+ MarkerLabel_.getSharedCross.processed = true;
+ }
+
+ this.listeners_ = [
+ google.maps.event.addDomListener(this.eventDiv_, "mouseover", function (e) {
+ if (me.marker_.getDraggable() || me.marker_.getClickable()) {
+ this.style.cursor = "pointer";
+ google.maps.event.trigger(me.marker_, "mouseover", e);
+ }
+ }),
+ google.maps.event.addDomListener(this.eventDiv_, "mouseout", function (e) {
+ if ((me.marker_.getDraggable() || me.marker_.getClickable()) && !cDraggingLabel) {
+ this.style.cursor = me.marker_.getCursor();
+ google.maps.event.trigger(me.marker_, "mouseout", e);
+ }
+ }),
+ google.maps.event.addDomListener(this.eventDiv_, "mousedown", function (e) {
+ cDraggingLabel = false;
+ if (me.marker_.getDraggable()) {
+ cMouseIsDown = true;
+ this.style.cursor = cDraggingCursor;
+ }
+ if (me.marker_.getDraggable() || me.marker_.getClickable()) {
+ google.maps.event.trigger(me.marker_, "mousedown", e);
+ cAbortEvent(e); // Prevent map pan when starting a drag on a label
+ }
+ }),
+ google.maps.event.addDomListener(document, "mouseup", function (mEvent) {
+ var position;
+ if (cMouseIsDown) {
+ cMouseIsDown = false;
+ me.eventDiv_.style.cursor = "pointer";
+ google.maps.event.trigger(me.marker_, "mouseup", mEvent);
+ }
+ if (cDraggingLabel) {
+ if (cRaiseEnabled) { // Lower the marker & label
+ position = me.getProjection().fromLatLngToDivPixel(me.marker_.getPosition());
+ position.y += cRaiseOffset;
+ me.marker_.setPosition(me.getProjection().fromDivPixelToLatLng(position));
+ // This is not the same bouncing style as when the marker portion is dragged,
+ // but it will have to do:
+ try { // Will fail if running Google Maps API earlier than V3.3
+ me.marker_.setAnimation(google.maps.Animation.BOUNCE);
+ setTimeout(cStopBounce, 1406);
+ } catch (e) {}
+ }
+ me.crossDiv_.style.display = "none";
+ me.marker_.setZIndex(cSavedZIndex);
+ cIgnoreClick = true; // Set flag to ignore the click event reported after a label drag
+ cDraggingLabel = false;
+ mEvent.latLng = me.marker_.getPosition();
+ google.maps.event.trigger(me.marker_, "dragend", mEvent);
+ }
+ }),
+ google.maps.event.addListener(me.marker_.getMap(), "mousemove", function (mEvent) {
+ var position;
+ if (cMouseIsDown) {
+ if (cDraggingLabel) {
+ // Change the reported location from the mouse position to the marker position:
+ mEvent.latLng = new google.maps.LatLng(mEvent.latLng.lat() - cLatOffset, mEvent.latLng.lng() - cLngOffset);
+ position = me.getProjection().fromLatLngToDivPixel(mEvent.latLng);
+ if (cRaiseEnabled) {
+ me.crossDiv_.style.left = position.x + "px";
+ me.crossDiv_.style.top = position.y + "px";
+ me.crossDiv_.style.display = "";
+ position.y -= cRaiseOffset;
+ }
+ me.marker_.setPosition(me.getProjection().fromDivPixelToLatLng(position));
+ if (cRaiseEnabled) { // Don't raise the veil; this hack needed to make MSIE act properly
+ me.eventDiv_.style.top = (position.y + cRaiseOffset) + "px";
+ }
+ google.maps.event.trigger(me.marker_, "drag", mEvent);
+ } else {
+ // Calculate offsets from the click point to the marker position:
+ cLatOffset = mEvent.latLng.lat() - me.marker_.getPosition().lat();
+ cLngOffset = mEvent.latLng.lng() - me.marker_.getPosition().lng();
+ cSavedZIndex = me.marker_.getZIndex();
+ cStartPosition = me.marker_.getPosition();
+ cStartCenter = me.marker_.getMap().getCenter();
+ cRaiseEnabled = me.marker_.get("raiseOnDrag");
+ cDraggingLabel = true;
+ me.marker_.setZIndex(1000000); // Moves the marker & label to the foreground during a drag
+ mEvent.latLng = me.marker_.getPosition();
+ google.maps.event.trigger(me.marker_, "dragstart", mEvent);
+ }
+ }
+ }),
+ google.maps.event.addDomListener(document, "keydown", function (e) {
+ if (cDraggingLabel) {
+ if (e.keyCode === 27) { // Esc key
+ cRaiseEnabled = false;
+ me.marker_.setPosition(cStartPosition);
+ me.marker_.getMap().setCenter(cStartCenter);
+ google.maps.event.trigger(document, "mouseup", e);
+ }
+ }
+ }),
+ google.maps.event.addDomListener(this.eventDiv_, "click", function (e) {
+ if (me.marker_.getDraggable() || me.marker_.getClickable()) {
+ if (cIgnoreClick) { // Ignore the click reported when a label drag ends
+ cIgnoreClick = false;
+ } else {
+ google.maps.event.trigger(me.marker_, "click", e);
+ cAbortEvent(e); // Prevent click from being passed on to map
+ }
+ }
+ }),
+ google.maps.event.addDomListener(this.eventDiv_, "dblclick", function (e) {
+ if (me.marker_.getDraggable() || me.marker_.getClickable()) {
+ google.maps.event.trigger(me.marker_, "dblclick", e);
+ cAbortEvent(e); // Prevent map zoom when double-clicking on a label
+ }
+ }),
+ google.maps.event.addListener(this.marker_, "dragstart", function (mEvent) {
+ if (!cDraggingLabel) {
+ cRaiseEnabled = this.get("raiseOnDrag");
+ }
+ }),
+ google.maps.event.addListener(this.marker_, "drag", function (mEvent) {
+ if (!cDraggingLabel) {
+ if (cRaiseEnabled) {
+ me.setPosition(cRaiseOffset);
+ // During a drag, the marker's z-index is temporarily set to 1000000 to
+ // ensure it appears above all other markers. Also set the label's z-index
+ // to 1000000 (plus or minus 1 depending on whether the label is supposed
+ // to be above or below the marker).
+ me.labelDiv_.style.zIndex = 1000000 + (this.get("labelInBackground") ? -1 : +1);
+ }
+ }
+ }),
+ google.maps.event.addListener(this.marker_, "dragend", function (mEvent) {
+ if (!cDraggingLabel) {
+ if (cRaiseEnabled) {
+ me.setPosition(0); // Also restores z-index of label
+ }
+ }
+ }),
+ google.maps.event.addListener(this.marker_, "position_changed", function () {
+ me.setPosition();
+ }),
+ google.maps.event.addListener(this.marker_, "zindex_changed", function () {
+ me.setZIndex();
+ }),
+ google.maps.event.addListener(this.marker_, "visible_changed", function () {
+ me.setVisible();
+ }),
+ google.maps.event.addListener(this.marker_, "labelvisible_changed", function () {
+ me.setVisible();
+ }),
+ google.maps.event.addListener(this.marker_, "title_changed", function () {
+ me.setTitle();
+ }),
+ google.maps.event.addListener(this.marker_, "labelcontent_changed", function () {
+ me.setContent();
+ }),
+ google.maps.event.addListener(this.marker_, "labelanchor_changed", function () {
+ me.setAnchor();
+ }),
+ google.maps.event.addListener(this.marker_, "labelclass_changed", function () {
+ me.setStyles();
+ }),
+ google.maps.event.addListener(this.marker_, "labelstyle_changed", function () {
+ me.setStyles();
+ })
+ ];
+};
+
+/**
+ * Removes the DIV for the label from the DOM. It also removes all event handlers.
+ * This method is called automatically when the marker's <code>setMap(null)</code>
+ * method is called.
+ * @private
+ */
+MarkerLabel_.prototype.onRemove = function () {
+ var i;
+ this.labelDiv_.parentNode.removeChild(this.labelDiv_);
+ this.eventDiv_.parentNode.removeChild(this.eventDiv_);
+
+ // Remove event listeners:
+ for (i = 0; i < this.listeners_.length; i++) {
+ google.maps.event.removeListener(this.listeners_[i]);
+ }
+};
+
+/**
+ * Draws the label on the map.
+ * @private
+ */
+MarkerLabel_.prototype.draw = function () {
+ this.setContent();
+ this.setTitle();
+ this.setStyles();
+};
+
+/**
+ * Sets the content of the label.
+ * The content can be plain text or an HTML DOM node.
+ * @private
+ */
+MarkerLabel_.prototype.setContent = function () {
+ var content = this.marker_.get("labelContent");
+ if (typeof content.nodeType === "undefined") {
+ this.labelDiv_.innerHTML = content;
+ this.eventDiv_.innerHTML = this.labelDiv_.innerHTML;
+ } else {
+ this.labelDiv_.innerHTML = ""; // Remove current content
+ this.labelDiv_.appendChild(content);
+ content = content.cloneNode(true);
+ this.eventDiv_.appendChild(content);
+ }
+};
+
+/**
+ * Sets the content of the tool tip for the label. It is
+ * always set to be the same as for the marker itself.
+ * @private
+ */
+MarkerLabel_.prototype.setTitle = function () {
+ this.eventDiv_.title = this.marker_.getTitle() || "";
+};
+
+/**
+ * Sets the style of the label by setting the style sheet and applying
+ * other specific styles requested.
+ * @private
+ */
+MarkerLabel_.prototype.setStyles = function () {
+ var i, labelStyle;
+
+ // Apply style values from the style sheet defined in the labelClass parameter:
+ this.labelDiv_.className = this.marker_.get("labelClass");
+ this.eventDiv_.className = this.labelDiv_.className;
+
+ // Clear existing inline style values:
+ this.labelDiv_.style.cssText = "";
+ this.eventDiv_.style.cssText = "";
+ // Apply style values defined in the labelStyle parameter:
+ labelStyle = this.marker_.get("labelStyle");
+ for (i in labelStyle) {
+ if (labelStyle.hasOwnProperty(i)) {
+ this.labelDiv_.style[i] = labelStyle[i];
+ this.eventDiv_.style[i] = labelStyle[i];
+ }
+ }
+ this.setMandatoryStyles();
+};
+
+/**
+ * Sets the mandatory styles to the DIV representing the label as well as to the
+ * associated event DIV. This includes setting the DIV position, z-index, and visibility.
+ * @private
+ */
+MarkerLabel_.prototype.setMandatoryStyles = function () {
+ this.labelDiv_.style.position = "absolute";
+ this.labelDiv_.style.overflow = "hidden";
+ // Make sure the opacity setting causes the desired effect on MSIE:
+ if (typeof this.labelDiv_.style.opacity !== "undefined" && this.labelDiv_.style.opacity !== "") {
+ this.labelDiv_.style.filter = "alpha(opacity=" + (this.labelDiv_.style.opacity * 100) + ")";
+ }
+
+ this.eventDiv_.style.position = this.labelDiv_.style.position;
+ this.eventDiv_.style.overflow = this.labelDiv_.style.overflow;
+ this.eventDiv_.style.opacity = 0.01; // Don't use 0; DIV won't be clickable on MSIE
+ this.eventDiv_.style.filter = "alpha(opacity=1)"; // For MSIE
+
+ this.setAnchor();
+ this.setPosition(); // This also updates z-index, if necessary.
+ this.setVisible();
+};
+
+/**
+ * Sets the anchor point of the label.
+ * @private
+ */
+MarkerLabel_.prototype.setAnchor = function () {
+ var anchor = this.marker_.get("labelAnchor");
+ this.labelDiv_.style.marginLeft = -anchor.x + "px";
+ this.labelDiv_.style.marginTop = -anchor.y + "px";
+ this.eventDiv_.style.marginLeft = -anchor.x + "px";
+ this.eventDiv_.style.marginTop = -anchor.y + "px";
+};
+
+/**
+ * Sets the position of the label. The z-index is also updated, if necessary.
+ * @private
+ */
+MarkerLabel_.prototype.setPosition = function (yOffset) {
+ var position = this.getProjection().fromLatLngToDivPixel(this.marker_.getPosition());
+ if (typeof yOffset === "undefined") {
+ yOffset = 0;
+ }
+ this.labelDiv_.style.left = Math.round(position.x) + "px";
+ this.labelDiv_.style.top = Math.round(position.y - yOffset) + "px";
+ this.eventDiv_.style.left = this.labelDiv_.style.left;
+ this.eventDiv_.style.top = this.labelDiv_.style.top;
+
+ this.setZIndex();
+};
+
+/**
+ * Sets the z-index of the label. If the marker's z-index property has not been defined, the z-index
+ * of the label is set to the vertical coordinate of the label. This is in keeping with the default
+ * stacking order for Google Maps: markers to the south are in front of markers to the north.
+ * @private
+ */
+MarkerLabel_.prototype.setZIndex = function () {
+ var zAdjust = (this.marker_.get("labelInBackground") ? -1 : +1);
+ if (typeof this.marker_.getZIndex() === "undefined") {
+ this.labelDiv_.style.zIndex = parseInt(this.labelDiv_.style.top, 10) + zAdjust;
+ this.eventDiv_.style.zIndex = this.labelDiv_.style.zIndex;
+ } else {
+ this.labelDiv_.style.zIndex = this.marker_.getZIndex() + zAdjust;
+ this.eventDiv_.style.zIndex = this.labelDiv_.style.zIndex;
+ }
+};
+
+/**
+ * Sets the visibility of the label. The label is visible only if the marker itself is
+ * visible (i.e., its visible property is true) and the labelVisible property is true.
+ * @private
+ */
+MarkerLabel_.prototype.setVisible = function () {
+ if (this.marker_.get("labelVisible")) {
+ this.labelDiv_.style.display = this.marker_.getVisible() ? "block" : "none";
+ } else {
+ this.labelDiv_.style.display = "none";
+ }
+ this.eventDiv_.style.display = this.labelDiv_.style.display;
+};
+
+/**
+ * @name MarkerWithLabelOptions
+ * @class This class represents the optional parameter passed to the {@link MarkerWithLabel} constructor.
+ * The properties available are the same as for <code>google.maps.Marker</code> with the addition
+ * of the properties listed below. To change any of these additional properties after the labeled
+ * marker has been created, call <code>google.maps.Marker.set(propertyName, propertyValue)</code>.
+ * <p>
+ * When any of these properties changes, a property changed event is fired. The names of these
+ * events are derived from the name of the property and are of the form <code>propertyname_changed</code>.
+ * For example, if the content of the label changes, a <code>labelcontent_changed</code> event
+ * is fired.
+ * <p>
+ * @property {string|Node} [labelContent] The content of the label (plain text or an HTML DOM node).
+ * @property {Point} [labelAnchor] By default, a label is drawn with its anchor point at (0,0) so
+ * that its top left corner is positioned at the anchor point of the associated marker. Use this
+ * property to change the anchor point of the label. For example, to center a 50px-wide label
+ * beneath a marker, specify a <code>labelAnchor</code> of <code>google.maps.Point(25, 0)</code>.
+ * (Note: x-values increase to the right and y-values increase to the top.)
+ * @property {string} [labelClass] The name of the CSS class defining the styles for the label.
+ * Note that style values for <code>position</code>, <code>overflow</code>, <code>top</code>,
+ * <code>left</code>, <code>zIndex</code>, <code>display</code>, <code>marginLeft</code>, and
+ * <code>marginTop</code> are ignored; these styles are for internal use only.
+ * @property {Object} [labelStyle] An object literal whose properties define specific CSS
+ * style values to be applied to the label. Style values defined here override those that may
+ * be defined in the <code>labelClass</code> style sheet. If this property is changed after the
+ * label has been created, all previously set styles (except those defined in the style sheet)
+ * are removed from the label before the new style values are applied.
+ * Note that style values for <code>position</code>, <code>overflow</code>, <code>top</code>,
+ * <code>left</code>, <code>zIndex</code>, <code>display</code>, <code>marginLeft</code>, and
+ * <code>marginTop</code> are ignored; these styles are for internal use only.
+ * @property {boolean} [labelInBackground] A flag indicating whether a label that overlaps its
+ * associated marker should appear in the background (i.e., in a plane below the marker).
+ * The default is <code>false</code>, which causes the label to appear in the foreground.
+ * @property {boolean} [labelVisible] A flag indicating whether the label is to be visible.
+ * The default is <code>true</code>. Note that even if <code>labelVisible</code> is
+ * <code>true</code>, the label will <i>not</i> be visible unless the associated marker is also
+ * visible (i.e., unless the marker's <code>visible</code> property is <code>true</code>).
+ * @property {boolean} [raiseOnDrag] A flag indicating whether the label and marker are to be
+ * raised when the marker is dragged. The default is <code>true</code>. If a draggable marker is
+ * being created and a version of Google Maps API earlier than V3.3 is being used, this property
+ * must be set to <code>false</code>.
+ * @property {boolean} [optimized] A flag indicating whether rendering is to be optimized for the
+ * marker. <b>Important: The optimized rendering technique is not supported by MarkerWithLabel,
+ * so the value of this parameter is always forced to <code>false</code>.
+ * @property {string} [crossImage="http://maps.gstatic.com/intl/en_us/mapfiles/drag_cross_67_16.png"]
+ * The URL of the cross image to be displayed while dragging a marker.
+ * @property {string} [handCursor="http://maps.gstatic.com/intl/en_us/mapfiles/closedhand_8_8.cur"]
+ * The URL of the cursor to be displayed while dragging a marker.
+ */
+/**
+ * Creates a MarkerWithLabel with the options specified in {@link MarkerWithLabelOptions}.
+ * @constructor
+ * @param {MarkerWithLabelOptions} [opt_options] The optional parameters.
+ */
+function MarkerWithLabel(opt_options) {
+ opt_options = opt_options || {};
+ opt_options.labelContent = opt_options.labelContent || "";
+ opt_options.labelAnchor = opt_options.labelAnchor || new google.maps.Point(0, 0);
+ opt_options.labelClass = opt_options.labelClass || "markerLabels";
+ opt_options.labelStyle = opt_options.labelStyle || {};
+ opt_options.labelInBackground = opt_options.labelInBackground || false;
+ if (typeof opt_options.labelVisible === "undefined") {
+ opt_options.labelVisible = true;
+ }
+ if (typeof opt_options.raiseOnDrag === "undefined") {
+ opt_options.raiseOnDrag = true;
+ }
+ if (typeof opt_options.clickable === "undefined") {
+ opt_options.clickable = true;
+ }
+ if (typeof opt_options.draggable === "undefined") {
+ opt_options.draggable = false;
+ }
+ if (typeof opt_options.optimized === "undefined") {
+ opt_options.optimized = false;
+ }
+ opt_options.crossImage = opt_options.crossImage || "//maps.gstatic.com/intl/en_us/mapfiles/drag_cross_67_16.png";
+ opt_options.handCursor = opt_options.handCursor || "//maps.gstatic.com/intl/en_us/mapfiles/closedhand_8_8.cur";
+ opt_options.optimized = false; // Optimized rendering is not supported
+
+ this.label = new MarkerLabel_(this, opt_options.crossImage, opt_options.handCursor); // Bind the label to the marker
+
+ // Call the parent constructor. It calls Marker.setValues to initialize, so all
+ // the new parameters are conveniently saved and can be accessed with get/set.
+ // Marker.set triggers a property changed event (called "propertyname_changed")
+ // that the marker label listens for in order to react to state changes.
+ google.maps.Marker.apply(this, arguments);
+}
+
+// MarkerWithLabel inherits from <code>Marker</code>:
+MarkerWithLabel.prototype = new google.maps.Marker();
+
+/**
+ * Overrides the standard Marker setMap function.
+ * @param {Map} marker The map to which the marker is to be added.
+ * @private
+ */
+MarkerWithLabel.prototype.setMap = function (theMap) {
+
+ // Call the inherited function...
+ google.maps.Marker.prototype.setMap.apply(this, arguments);
+
+ // ... then deal with the label:
+ this.label.setMap(theMap);
+};
+
+window.MarkerWithLabel = MarkerWithLabel;
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/img/blue-dot.png b/www/wiki/extensions/Maps/resources/GoogleMaps/img/blue-dot.png
new file mode 100644
index 00000000..845055e7
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/img/blue-dot.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/GoogleMaps/jquery.googlemap.js b/www/wiki/extensions/Maps/resources/GoogleMaps/jquery.googlemap.js
new file mode 100644
index 00000000..d0317d16
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/GoogleMaps/jquery.googlemap.js
@@ -0,0 +1,900 @@
+/**
+ * JavaScript for Google Maps v3 maps in the Maps extension.
+ * @see http://www.mediawiki.org/wiki/Extension:Maps
+ *
+ * @author Jeroen De Dauw <jeroendedauw at gmail dot com>
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+
+(function ($, mw) {
+ $.fn.googlemaps = function (options) {
+
+ var _this = this;
+ this.map = null;
+ this.markercluster = null;
+ this.options = options;
+
+ /**
+ * All markers that are currently on the map.
+ * @type {Array}
+ * @private
+ */
+ this.markers = [];
+
+ /**
+ * All Polylines currently on the map,
+ * @type {Array}
+ * @private
+ */
+ this.lines = [];
+
+ /**
+ * All polygons currently on the map,
+ */
+ this.polygons = [];
+
+
+ /**
+ * All circles on the map
+ */
+ this.circles = [];
+
+
+ /**
+ * All rectangles on the map
+ */
+ this.rectangles = [];
+
+
+ /**
+ * All image overlays on the map
+ */
+ this.imageoverlays = [];
+
+
+ var getBounds = function() {
+ if (( options.centre === false || options.zoom === false ) && options.locations.length > 1) {
+ var bounds = new google.maps.LatLngBounds();
+
+ for (var i = _this.markers.length - 1; i >= 0; i--) {
+ bounds.extend(_this.markers[i].getPosition());
+ }
+ return bounds;
+ }
+ return null;
+ };
+
+ var setZoom = function(bounds) {
+ if (options.zoom === false) {
+ _this.map.fitBounds(bounds);
+ }
+ else {
+ _this.map.setZoom(options.zoom);
+ }
+ };
+
+
+ /**
+ * Creates a new marker with the provided data,
+ * adds it to the map, and returns it.
+ * @param {Object} markerData Contains the fields lat, lon, title, text and icon
+ * @return {google.maps.Marker}
+ */
+ this.addMarker = function (markerData) {
+ var markerOptions = {
+ position: new google.maps.LatLng(markerData.lat, markerData.lon),
+ title: markerData.title,
+ text: markerData.text,
+ labelContent: markerData.inlineLabel,
+ labelAnchor: new google.maps.Point(-15, 34),
+ labelClass: 'markerwithlabel'
+ };
+
+ if ( markerOptions.text !== '' ) {
+ markerOptions.text = $('<div>' + markerOptions.text + '</div>').text();
+ }
+
+ if (!markerData.hasOwnProperty('icon') || markerData.icon !== '') {
+ markerOptions.icon = markerData.icon;
+ }
+
+ if (markerData.visitedicon !== '') {
+ if(markerData.visitedicon === 'on'){
+ //when keyword 'on' is set, set visitedicon to a default official marker
+ markerOptions.visitedicon = mw.config.get('wgScriptPath')+'/extensions/Maps/resources/GoogleMaps/img/blue-dot.png';
+ }else{
+ markerOptions.visitedicon = markerData.visitedicon;
+ }
+ }
+
+ var addToMapAndHandlers = function( marker ) {
+ //Add onclick listener
+ google.maps.event.addListener(marker, 'click', function (e) {
+ if (e.target !== undefined && (e.target instanceof HTMLAnchorElement || e.target.tagName == 'A')) {
+ //click link defined in inlinelabel
+ window.location.href = e.target.href;
+ } else {
+ openBubbleOrLink.call(this, markerData, e, marker);
+ }
+
+ if (markerOptions.visitedicon) {
+ marker.setIcon(markerOptions.visitedicon);
+ markerOptions.visitedicon = undefined;
+ }
+ });
+
+ marker.setMap( _this.map );
+ _this.markers.push( marker );
+
+ return marker;
+ };
+
+ var marker;
+ if (markerData.inlineLabel === undefined || markerData.inlineLabel === null || markerData.inlineLabel.length == 0) {
+ marker = new google.maps.Marker( markerOptions );
+ return addToMapAndHandlers( marker );
+ } else {
+ mw.loader.using(
+ 'ext.maps.gm3.markerwithlabel',
+ function() {
+ marker = new MarkerWithLabel( markerOptions );
+ addToMapAndHandlers( marker );
+ setZoom(getBounds());
+ }
+ );
+ }
+ };
+
+ /**
+ * Removes a single marker from the map.
+ * @param {google.maps.Marker} marker The marker to remove.
+ */
+ this.removeMarker = function (marker) {
+ marker.setMap(null);
+
+ for (var i = this.markers.length - 1; i >= 0; i--) {
+ if (this.markers[i] === marker) {
+ delete this.markers[i];
+ break;
+ }
+ }
+
+ delete marker;
+ };
+
+ /**
+ * Removes all markers from the map.
+ */
+ this.removeMarkers = function () {
+ if (this.markercluster) {
+ this.markercluster.setMap(null);
+ this.markercluster = null;
+ }
+ for (var i = this.markers.length - 1; i >= 0; i--) {
+ this.markers[i].setMap(null);
+ }
+ this.markers = [];
+ };
+
+ /**
+ * Remove the "earth" type from options.types if it's present.
+ *
+ * @since 1.0.1
+ */
+ this.removeEarthType = function () {
+ if (Array.prototype.filter) {
+ options.types = options.types.filter(function (element, index, array) {
+ return element !== 'earth';
+ });
+ }
+ else {
+ // Seems someone is using the o-so-awesome browser that is IE.
+ var types = [];
+
+ for (i in options.types) {
+ if (typeof( options.types[i] ) !== 'function' && options.types[i] !== 'earth') {
+ types.push(options.types[i]);
+ }
+ }
+
+ options.types = types;
+ }
+ };
+
+ this.addOverlays = function () {
+ // Add the Google KML/KMZ layers.
+ for (i = options.gkml.length - 1; i >= 0; i--) {
+ var kmlLayer = new google.maps.KmlLayer(
+ options.gkml[i],
+ {
+ map:this.map,
+ preserveViewport:!options.kmlrezoom
+ }
+ );
+ }
+
+ // If there are any non-Google KML/KMZ layers, load the geoxml library and use it to add these layers.
+ if (options.kml.length != 0) {
+ mw.loader.using('ext.maps.gm3.geoxml', function () {
+
+ function addToCopyCoords(doc){
+ if(options.copycoords){
+ for(var i = 0; i < doc.length; i++){
+ addCopyCoordsOnRightClick([
+ doc[i].gpolygons,
+ doc[i].gpolylines,
+ doc[i].ggroundoverlays
+ ]);
+ }
+ }
+ }
+
+
+ var geoXml = new geoXML3.parser({
+ map:_this.map,
+ zoom:options.kmlrezoom,
+ failedParse:function(){
+ alert(mw.msg('maps-kml-parsing-failed'));
+ }
+ });
+ geoXml.options.afterParse = function(docs){
+ //add toggle functionality
+ var toggleDiv = document.createElement('div');
+ toggleDiv.style.backgroundColor = 'white';
+ toggleDiv.style.marginTop = '5px';
+ toggleDiv.style.padding = '5px';
+ toggleDiv.style.border = '1px solid grey';
+ for(var i = docs.length-1; i >= 0; i--){
+ (function(doc){
+ var label = document.createElement('label');
+ label.style.display = 'block';
+ var text = document.createTextNode(doc.baseUrl.substring(doc.baseDir.length));
+ var checkbox = document.createElement('input');
+ checkbox.setAttribute('type','checkbox');
+ checkbox.style.verticalAlign = '-0.2em';
+ checkbox.checked = true;
+ checkbox.onclick = function(){
+ if(this.checked){
+ geoXml.showDocument(doc);
+ }else{
+ geoXml.hideDocument(doc);
+ }
+ };
+ label.appendChild(checkbox);
+ label.appendChild(text);
+
+ toggleDiv.appendChild(label);
+ })(docs[i]);
+ }
+ _this.map.controls[google.maps.ControlPosition.TOP_RIGHT].push(toggleDiv);
+ };
+
+ geoXml.parse(options.kml);
+ });
+ }
+ };
+
+ this.addLine = function (properties) {
+ var paths = new google.maps.MVCArray();
+ for (var x = 0; x < properties.pos.length; x++) {
+ paths.push(new google.maps.LatLng(properties.pos[x].lat, properties.pos[x].lon));
+ }
+
+ var line = new google.maps.Polyline({
+ map:this.map,
+ path:paths,
+ strokeColor:properties.strokeColor,
+ strokeOpacity:properties.strokeOpacity,
+ strokeWeight:properties.strokeWeight
+ });
+ this.lines.push(line);
+
+ google.maps.event.addListener(line, "click", function (event) {
+ openBubbleOrLink.call(this, properties, event, line);
+ });
+ };
+
+ this.removeLine = function (line) {
+ line.setMap(null);
+
+ for (var i = this.line.length - 1; i >= 0; i--) {
+ if (this.line[i] === line) {
+ delete this.line[i];
+ break;
+ }
+ }
+
+ delete line;
+ };
+
+ this.removeLines = function () {
+ for (var i = this.lines.length - 1; i >= 0; i--) {
+ this.lines[i].setMap(null);
+ }
+ this.lines = [];
+ };
+
+ this.addPolygon = function (properties) {
+ var paths = new google.maps.MVCArray();
+ for (var x = 0; x < properties.pos.length; x++) {
+ paths.push(new google.maps.LatLng(properties.pos[x].lat, properties.pos[x].lon));
+ }
+
+ var polygon = new google.maps.Polygon({
+ map:this.map,
+ path:paths,
+ strokeColor:properties.strokeColor,
+ strokeOpacity:properties.strokeOpacity,
+ strokeWeight:properties.strokeWeight,
+ fillColor:properties.fillColor,
+ fillOpacity:properties.fillOpacity
+ });
+ this.polygons.push(polygon);
+
+ //add hover event/effect
+ if (properties.onlyVisibleOnHover === true) {
+
+ function hidePolygon(polygon) {
+ polygon.setOptions({
+ fillOpacity:0,
+ strokeOpacity:0
+ });
+ }
+
+ hidePolygon(polygon);
+
+ google.maps.event.addListener(polygon, "mouseover", function () {
+ this.setOptions({
+ fillOpacity:properties.fillOpacity,
+ strokeOpacity:properties.strokeOpacity
+ });
+ });
+
+ google.maps.event.addListener(polygon, "mouseout", function () {
+ hidePolygon(this);
+ });
+
+ }
+
+ //add click event
+ google.maps.event.addListener(polygon, "click", function (event) {
+ openBubbleOrLink.call(this, properties, event, polygon);
+ });
+ };
+
+ this.addCircle = function (properties) {
+ var circle = new google.maps.Circle({
+ map:this.map,
+ center:new google.maps.LatLng(properties.centre.lat, properties.centre.lon),
+ radius:properties.radius,
+ fillColor:properties.fillColor,
+ fillOpacity:properties.fillOpacity,
+ strokeColor:properties.strokeColor,
+ strokeOpacity:properties.strokeOpacity,
+ strokeWeight:properties.strokeWeight
+ });
+ this.circles.push(circle);
+
+ //add click event
+ google.maps.event.addListener(circle, "click", function (event) {
+ openBubbleOrLink.call(this, properties, event, circle);
+ });
+ };
+
+
+ this.addRectangle = function (properties) {
+ var rectangle = new google.maps.Rectangle({
+ map:this.map,
+ bounds:new google.maps.LatLngBounds(
+ new google.maps.LatLng(properties.sw.lat, properties.sw.lon), //sw
+ new google.maps.LatLng(properties.ne.lat, properties.ne.lon) //ne
+ ),
+ fillColor:properties.fillColor,
+ fillOpacity:properties.fillOpacity,
+ strokeColor:properties.strokeColor,
+ strokeOpacity:properties.strokeOpacity,
+ strokeWeight:properties.strokeWeight
+ });
+ this.rectangles.push(rectangle);
+
+ //add click event
+ google.maps.event.addListener(rectangle, "click", function (event) {
+ openBubbleOrLink.call(this, properties, event, rectangle);
+ });
+ };
+
+ this.addImageOverlay = function(properties){
+ var imageBounds = new google.maps.LatLngBounds(
+ new google.maps.LatLng(properties.sw.lat,properties.sw.lon),
+ new google.maps.LatLng(properties.ne.lat,properties.ne.lon)
+ );
+
+ var image = new google.maps.GroundOverlay(properties.image,imageBounds);
+ image.setMap(this.map);
+
+ this.imageoverlays.push(image);
+
+ //add click event
+ google.maps.event.addListener(image, "click", function (event) {
+ openBubbleOrLink.call(this, properties, event, image);
+ });
+ };
+
+
+ this.removePolygon = function (polygon) {
+ polygon.setMap(null);
+
+ for (var i = this.polygon.length - 1; i >= 0; i--) {
+ if (this.polygon[i] === polygon) {
+ delete this.polygon[i];
+ break;
+ }
+ }
+
+ delete polygon;
+ };
+
+ this.removePolygons = function () {
+ for (var i = this.polygon.length - 1; i >= 0; i--) {
+ this.polygon[i].setMap(null);
+ }
+ this.polygon = [];
+ };
+
+ //Rezoom's the map to show all visible markers.
+ this.reZoom = function(){
+ var bounds = new google.maps.LatLngBounds();
+ for(var x = 0; x < this.markers.length; x++){
+ var marker = this.markers[x];
+ if (marker.getVisible() === true) {
+ bounds.extend(marker.getPosition());
+ }
+ }
+ this.map.fitBounds(bounds);
+ };
+
+ this.createMarkerCluster = function() {
+ if ( !options.markercluster ) {
+ return;
+ }
+ if (this.markercluster) {
+ this.markercluster.setMap(null);
+ this.markercluster = null;
+ }
+ this.markercluster = new MarkerClusterer( this.map, this.markers, {
+ imagePath: mw.config.get( 'wgScriptPath' ) +
+ '/extensions/Maps/resources/leaflet/cluster/m',
+ gridSize: this.options.clustergridsize,
+ maxZoom: this.options.clustermaxzoom,
+ zoomOnClick: this.options.clusterzoomonclick,
+ averageCenter: this.options.clusteraveragecenter,
+ minimumClusterSize: this.options.clusterminsize
+ } );
+ };
+
+ this.initializeMap = function () {
+ var mapOptions = {
+ disableDefaultUI:true,
+ mapTypeId:options.type == 'earth' ? google.maps.MapTypeId.SATELLITE : google.maps.MapTypeId[ options.type ]
+ };
+
+ // Map controls
+ mapOptions.panControl = $.inArray('pan', options.controls) != -1;
+ mapOptions.zoomControl = $.inArray('zoom', options.controls) != -1;
+ mapOptions.mapTypeControl = $.inArray('type', options.controls) != -1;
+ mapOptions.scaleControl = $.inArray('scale', options.controls) != -1;
+ mapOptions.streetViewControl = $.inArray('streetview', options.controls) != -1;
+ mapOptions.rotateControl = $.inArray('rotate', options.controls) != -1;
+
+ for (i in options.types) {
+ if (typeof( options.types[i] ) !== 'function') {
+ options.types[i] = google.maps.MapTypeId[ options.types[i].toUpperCase() ];
+ }
+ }
+
+ // Map control styles
+ mapOptions.zoomControlOptions = { style:google.maps.ZoomControlStyle[ options.zoomstyle ] };
+ mapOptions.mapTypeControlOptions = {
+ style:google.maps.MapTypeControlStyle[ options.typestyle ],
+ mapTypeIds:options.types
+ };
+
+
+ //max/min -zoom
+ mapOptions.maxZoom = options.maxzoom === false ? null : options.maxzoom;
+ mapOptions.minZoom = options.minzoom === false ? null : options.minzoom;
+
+ //static mode
+ if (options['static']) {
+ mapOptions.draggable = false;
+ mapOptions.disableDoubleClickZoom = true;
+ mapOptions.panControl = false;
+ mapOptions.rotateControl = false;
+ mapOptions.zoomControl = false;
+ mapOptions.scrollwheel = false;
+ mapOptions.streetViewControl = false;
+ mapOptions.overviewMapControl = false;
+ mapOptions.mapTypeControl = false;
+ }
+
+ if (options.scrollwheelzoom === true) {
+ mapOptions.gestureHandling = 'greedy';
+ }
+
+ var map = new google.maps.Map(this.get(0), mapOptions);
+
+ google.maps.event.addListenerOnce(map, 'tilesloaded', function () {
+ _this.addOverlays();
+ });
+
+
+ this.map = map;
+
+ if (options.poi === false) {
+ map.setOptions({ styles:[
+ {
+ featureType:"poi",
+ stylers:[
+ { visibility:"off" }
+ ]
+ }
+ ] });
+ }
+
+ if (!options.locations) {
+ options.locations = [];
+ }
+
+ // Add the markers.
+ for (var i = options.locations.length - 1; i >= 0; i--) {
+ this.addMarker(options.locations[i]);
+ }
+
+ for (i = options.layers.length - 1; i >= 0; i--) {
+ if ( options.layers[i] === 'traffic' ) {
+ ( new google.maps.TrafficLayer() ).setMap(map);
+ }
+ else if ( options.layers[i] === 'bicycling' ) {
+ ( new google.maps.BicyclingLayer() ).setMap(map);
+ }
+ else if ( options.layers[i] === 'transit' ) {
+ ( new google.maps.TransitLayer() ).setMap(map);
+ }
+ }
+
+ var bounds = getBounds();
+
+ setZoom(bounds);
+
+ var centre;
+
+ if (options.centre === false) {
+ if (options.locations.length > 1) {
+ centre = bounds.getCenter();
+ }
+ else if (options.locations.length == 1) {
+ centre = new google.maps.LatLng(options.locations[0].lat, options.locations[0].lon);
+ }
+ else {
+ centre = new google.maps.LatLng(0, 0);
+ }
+ }
+ else {
+ centre = new google.maps.LatLng(options.centre.lat, options.centre.lon);
+ }
+
+ map.setCenter(centre);
+
+ setTimeout(
+ function() {
+ if ( options.autoinfowindows ) {
+ for ( var i = _this.markers.length - 1; i >= 0; i-- ) {
+ google.maps.event.trigger( _this.markers[i], 'click', {} );
+ }
+ }
+ },
+ 500 // If we wait a bit, the map will re-position to accommodate for the info windows.
+ );
+
+ if (options.resizable) {
+ mw.loader.using('ext.maps.resizable', function () {
+ _this.resizable();
+ });
+ }
+
+ /**
+ * used in display_line functionality
+ * draws paths between markers
+ */
+ if (options.lines) {
+ for (var i = 0; i < options.lines.length; i++) {
+ this.addLine(options.lines[i]);
+ }
+ }
+
+ /**
+ * used in display_line to draw polygons
+ */
+ if (options.polygons) {
+ for (var i = 0; i < options.polygons.length; i++) {
+ this.addPolygon(options.polygons[i]);
+ }
+ }
+
+ /**
+ * used in display_line to draw circles
+ */
+ if (options.circles) {
+ for (var i = 0; i < options.circles.length; i++) {
+ this.addCircle(options.circles[i]);
+ }
+ }
+
+ /**
+ * used in display_line to draw rectangles
+ */
+ if (options.rectangles) {
+ for (var i = 0; i < options.rectangles.length; i++) {
+ this.addRectangle(options.rectangles[i]);
+ }
+ }
+
+ /**
+ * Allows grouping of markers.
+ */
+ this.createMarkerCluster();
+
+
+ if (options.searchmarkers) {
+ var searchBoxValue = mw.msg('maps-searchmarkers-text');
+ var searchBox = $('<input type="text" value="' + searchBoxValue + '" />');
+ var searchContainer = document.createElement('div');
+ searchContainer.style.padding = '5px';
+ searchContainer.index = 1;
+ searchBox.appendTo(searchContainer);
+ map.controls[google.maps.ControlPosition.TOP_RIGHT].push(searchContainer);
+
+ //prevents markers and other map objects to be placed beneath searchfield
+ google.maps.event.addListenerOnce(map, 'bounds_changed', function () {
+ map.panBy(0,-30);
+ });
+
+
+ searchBox.on('keyup',function (e) {
+ for (var i = 0; i < _this.markers.length; i++) {
+ var haystack = '';
+ var marker = _this.markers[i];
+ if (options.searchmarkers == 'title') {
+ haystack = marker.title;
+ } else {
+ haystack = marker.title + marker.text;
+ }
+
+ var visible = haystack.toLowerCase().indexOf(e.target.value.toLowerCase()) != -1;
+ marker.setVisible(visible);
+ }
+ _this.reZoom();
+ }).on('focusin',function () {
+ if ($(this).val() === searchBoxValue) {
+ $(this).val('');
+ }
+ }).on('focusout', function () {
+ if ($(this).val() === '') {
+ $(this).val(searchBoxValue);
+ }
+ });
+ }
+
+ if(options.imageoverlays){
+ for (var i = 0; i < options.imageoverlays.length; i++) {
+ this.addImageOverlay(options.imageoverlays[i]);
+ }
+ }
+
+ if (options.copycoords) {
+
+ addCopyCoordsOnRightClick([
+ this.lines,
+ this.circles,
+ this.polygons,
+ this.markers,
+ this.rectangles,
+ this.imageoverlays,
+ this.map
+ ]);
+ }
+
+ if (options.wmsoverlay) {
+ var wmsOptions = {
+ alt: "OpenLayers",
+ getTileUrl:function (tile, zoom) {
+ var projection = _this.map.getProjection();
+ var zpow = Math.pow(2, zoom);
+ var ul = new google.maps.Point(tile.x * 256.0 / zpow, (tile.y + 1) * 256.0 / zpow);
+ var lr = new google.maps.Point((tile.x + 1) * 256.0 / zpow, (tile.y) * 256.0 / zpow);
+ var ulw = projection.fromPointToLatLng(ul);
+ var lrw = projection.fromPointToLatLng(lr);
+ //The user will enter the address to the public WMS layer here. The data must be in WGS84
+ var baseURL = options.wmsoverlay.wmsServerUrl;
+ //The layer ID. Can be found when using the layers properties tool in ArcMap or from the WMS settings
+ var layers = options.wmsoverlay.wmsLayerName;
+
+ var style = options.wmsoverlay.wmsStyleName;
+ //With the 1.3.0 version the coordinates are read in LatLon, as opposed to LonLat in previous versions
+ var bbox = ulw.lat() + "," + ulw.lng() + "," + lrw.lat() + "," + lrw.lng();
+ //Establish the baseURL. Several elements, including &EXCEPTIONS=INIMAGE and &Service are unique to openLayers addresses.
+ var url = baseURL + "version=1.3.0&EXCEPTIONS=INIMAGE&Service=WMS" +
+ "&request=GetMap&Styles=" + encodeURI(style) + "&format=image%2Fjpeg&CRS=EPSG:4326" +
+ "&width=256&height=256" + "&Layers=" + layers + "&BBOX=" + bbox;
+ return url;
+ },
+ isPng: false,
+ maxZoom: 17,
+ minZoom: 1,
+ name: "OpenLayers",
+ tileSize: new google.maps.Size(256, 256)
+
+ };
+
+
+
+ //Creating the object to create the ImageMapType that will call the WMS Layer Options.
+
+ openlayersWMS = new google.maps.ImageMapType(wmsOptions);
+
+
+ //Layers to appear on Map A. The first string will give the map the map a name in the dropdown and the second object calls the map type
+
+ map.mapTypes.set('OpenLayers', openlayersWMS);
+ map.setMapTypeId('OpenLayers');
+ }
+
+ //Add custom controls
+ // - Fullscreen
+ if(options.enablefullscreen){
+ this.map.controls[google.maps.ControlPosition.TOP_RIGHT].push(new FullscreenControl(this.map));
+ }
+ };
+
+ this.setup = function () {
+
+ var showEarth = $.inArray('earth', options.types) !== -1 || options.type == 'earth';
+
+ // If there are any non-Google KML/KMZ layers, load the geoxml library and use it to add these layers.
+ if (showEarth) {
+ this.removeEarthType();
+ $.getScript(
+ 'https://www.google.com/jsapi',
+ function (data, textStatus) {
+ google.load('earth', '1', { callback:function () {
+ mw.loader.using('ext.maps.gm3.earth', function () {
+ _this.initializeMap();
+ if (google.earth.isSupported()) {
+ _this.ge = new GoogleEarth(_this.map);
+ }
+ });
+ } });
+ }
+ );
+ }else{
+ this.initializeMap();
+ }
+
+
+ };
+
+ function FullscreenControl(map) {
+
+ var controlDiv = document.createElement('div');
+ controlDiv.style.padding = '5px';
+ controlDiv.index = 1;
+
+ var controlUI = document.createElement('div');
+ controlUI.style.backgroundColor = 'white';
+ controlUI.style.borderStyle = 'solid';
+ controlUI.style.borderColor = 'rgba(0, 0, 0, 0.14902)';
+ controlUI.style.borderWidth = '1px';
+ controlUI.style.borderRadius = '2px';
+ controlUI.style.cursor = 'pointer';
+ controlUI.style.textAlign = 'center';
+ controlUI.style.boxShadow = 'rgba(0, 0, 0, 0.298039) 0px 1px 4px -1px';
+ controlUI.style.backgroundClip = 'padding-box';
+ controlUI.title = mw.msg('maps-fullscreen-button-tooltip');
+ controlDiv.appendChild(controlUI);
+
+ var controlText = document.createElement('div');
+ controlText.style.fontFamily = 'Roboto, Arial, sans-serif';
+ controlText.style.fontSize = '11px';
+ controlText.style.fontWeight = '400';
+ controlText.style.color = 'rgb(86, 86, 86)';
+ controlText.style.padding = '1px 6px';
+ controlText.innerHTML = mw.msg('maps-fullscreen-button');
+ controlUI.appendChild(controlText);
+
+ google.maps.event.addDomListener(controlUI, 'click', function() {
+ var mapDiv = $(map.getDiv());
+ if(mapDiv.data('preFullscreenCss') != null){
+ mapDiv.css(mapDiv.data('preFullscreenCss'));
+ mapDiv.removeData('preFullscreenCss');
+ }else{
+ var fullscreenCss = {
+ position:'fixed',
+ top: 0,
+ left:0,
+ width:'100%',
+ height:'100%',
+ zIndex:10000
+ };
+ var oldState = {};
+ for(var cssProp in fullscreenCss){
+ oldState[cssProp] = mapDiv.css(cssProp);
+ }
+ mapDiv.data('preFullscreenCss',oldState);
+ mapDiv.css(fullscreenCss);
+ }
+
+ google.maps.event.trigger(map, "resize");
+ });
+
+ return controlDiv;
+ }
+
+
+ function openBubbleOrLink(markerData, event, obj) {
+ if (markerData.link) {
+ window.location.href = markerData.link;
+ } else if (markerData.text.trim() !== '') {
+ openBubble.call(this, markerData, event, obj);
+ }
+ }
+
+ function openBubble( markerData, event, obj ) {
+ if ( this.openWindow !== undefined ) {
+ this.openWindow.close();
+ }
+
+ this.openWindow = new google.maps.InfoWindow();
+ this.openWindow.setContent( markerData.text );
+
+ if ( event.latLng !== undefined ) {
+ this.openWindow.setPosition( event.latLng );
+ }
+
+ this.openWindow.closeclick = function () {
+ obj.openWindow = undefined;
+ };
+
+ if ( event.latLng === undefined ) {
+ this.openWindow.open( _this.map, this );
+ }
+ else {
+ this.openWindow.open( _this.map );
+ }
+ }
+
+ function addCopyCoordsOnRightClick(object) {
+ if(object instanceof Array){
+ for (var x = 0; x < object.length; x++) {
+ addCopyCoordsOnRightClick(object[x]);
+ }
+ }else{
+ google.maps.event.addListener(object, 'rightclick', function (event) {
+ prompt(mw.msg('maps-copycoords-prompt'), event.latLng.lat() + ',' + event.latLng.lng());
+ });
+ }
+ }
+
+ //Complete path to OpenLayers WMS layer
+
+ if (!options.markercluster) {
+ this.setup();
+ } else {
+ mw.loader.using( 'ext.maps.gm3.markercluster', function() {
+ _this.setup();
+ } );
+ }
+
+ return this;
+
+ };
+})(jQuery, window.mediaWiki);
diff --git a/www/wiki/extensions/Maps/resources/editor/css/jquery.miniColors.css b/www/wiki/extensions/Maps/resources/editor/css/jquery.miniColors.css
new file mode 100644
index 00000000..664c2fd4
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/css/jquery.miniColors.css
@@ -0,0 +1,70 @@
+.miniColors-trigger {
+ height: 22px;
+ width: 22px;
+ /* @embed */
+ background: url(../images/trigger.png) center no-repeat;
+ vertical-align: middle;
+ margin: 0 .25em;
+ display: inline-block;
+ outline: none;
+}
+
+.miniColors-selector {
+ position: absolute;
+ width: 175px;
+ height: 150px;
+ background: #FFF;
+ border: solid 1px #BBB;
+ -moz-box-shadow: 0 0 6px rgba(0, 0, 0, .25);
+ -webkit-box-shadow: 0 0 6px rgba(0, 0, 0, .25);
+ box-shadow: 0 0 6px rgba(0, 0, 0, .25);
+ -moz-border-radius: 5px;
+ -webkit-border-radius: 5px;
+ border-radius: 5px;
+ padding: 5px;
+ z-index: 999999;
+}
+
+.miniColors-selector.black {
+ background: #000;
+ border-color: #000;
+}
+
+.miniColors-colors {
+ position: absolute;
+ top: 5px;
+ left: 5px;
+ width: 150px;
+ height: 150px;
+ /* @embed */
+ background: url(../images/gradient.png) center no-repeat;
+ cursor: crosshair;
+}
+
+.miniColors-hues {
+ position: absolute;
+ top: 5px;
+ left: 160px;
+ width: 20px;
+ height: 150px;
+ /* @embed */
+ background: url(../images/rainbow.png) center no-repeat;
+ cursor: crosshair;
+}
+
+.miniColors-colorPicker {
+ position: absolute;
+ width: 11px;
+ height: 11px;
+ /* @embed */
+ background: url(../images/circle.gif) center no-repeat;
+}
+
+.miniColors-huePicker {
+ position: absolute;
+ left: -3px;
+ width: 26px;
+ height: 3px;
+ /* @embed */
+ background: url(../images/line.gif) center no-repeat;
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/editor/css/mapeditor.css b/www/wiki/extensions/Maps/resources/editor/css/mapeditor.css
new file mode 100644
index 00000000..9c3fe7c4
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/css/mapeditor.css
@@ -0,0 +1,79 @@
+#code-output-container, #code-input-container,#code-input {
+ height: 100% !important;
+ width: 100%;
+}
+
+#code-output-container {
+ overflow: visible;
+}
+
+textarea#code-input, textarea#code-output {
+ resize: none;
+}
+
+#code-output {
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ border: none;
+ padding: 10px;
+}
+
+#map-canvas {
+ width: 100%;
+ height: 500px;
+}
+
+#map-canvas,#code-input {
+ display: block;
+}
+
+.mapeditor-dialog-form fieldset label{
+ display: block;
+}
+
+.mapeditor-dialog-form fieldset input{
+ width: 200px;
+}
+
+.mapeditor-dialog-form fieldset input[type="checkbox"]{
+ width: auto;
+}
+
+.mapeditor-dialog-form fieldset input[name="strokeColor"],.mapeditor-dialog-form fieldset input[name="fillColor"]{
+ width: 100px;
+}
+
+.mapeditor-dialog-form .ui-slider{
+ margin: 5px 2px;
+ width: 200px;
+}
+
+.link-title-switcher {
+ margin: 5px;
+}
+
+#map-parameter-form{
+ text-align: center;
+}
+
+.mapeditor-controls{
+ padding: 5px;
+}
+
+.mapeditor-control-element{
+ background-color:white;
+ border: 1px solid #717B87;
+ cursor: pointer;
+ text-align: center;
+ float: left;
+ padding: 2px;
+}
+
+.mapeditor-control-text{
+ font-family:"Arial","sans-serif";
+ font-size: 12px;
+ padding-left: 4px;
+ padding-right: 4px;
+ font-weight: bold;
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/editor/images/circle.gif b/www/wiki/extensions/Maps/resources/editor/images/circle.gif
new file mode 100644
index 00000000..599f7f13
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/images/circle.gif
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/editor/images/gradient.png b/www/wiki/extensions/Maps/resources/editor/images/gradient.png
new file mode 100644
index 00000000..486a9f6d
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/images/gradient.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/editor/images/line.gif b/www/wiki/extensions/Maps/resources/editor/images/line.gif
new file mode 100644
index 00000000..9eb19837
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/images/line.gif
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/editor/images/rainbow.png b/www/wiki/extensions/Maps/resources/editor/images/rainbow.png
new file mode 100644
index 00000000..d16fcd86
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/images/rainbow.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/editor/images/trigger.png b/www/wiki/extensions/Maps/resources/editor/images/trigger.png
new file mode 100644
index 00000000..20ec282b
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/images/trigger.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/editor/js/README b/www/wiki/extensions/Maps/resources/editor/js/README
new file mode 100644
index 00000000..53598d48
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/js/README
@@ -0,0 +1,3 @@
+== jquery.miniColors.js ==
+Is dual licensed under the MIT / GPLv2 licenses
+https://github.com/claviska/jquery-miniColors \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/editor/js/jquery.miniColors.js b/www/wiki/extensions/Maps/resources/editor/js/jquery.miniColors.js
new file mode 100644
index 00000000..dfbce542
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/js/jquery.miniColors.js
@@ -0,0 +1,567 @@
+/*
+ * jQuery miniColors: A small color selector
+ *
+ * Copyright 2011 Cory LaViska for A Beautiful Site, LLC. (http://abeautifulsite.net/)
+ *
+ * Dual licensed under the MIT or GPL Version 2 licenses
+ *
+*/
+if(jQuery) (function($) {
+
+ $.extend($.fn, {
+
+ miniColors: function(o, data) {
+
+ var create = function(input, o, data) {
+ //
+ // Creates a new instance of the miniColors selector
+ //
+
+ // Determine initial color (defaults to white)
+ var color = expandHex(input.val());
+ if( !color ) color = 'ffffff';
+ var hsb = hex2hsb(color);
+
+ // Create trigger
+ var trigger = $('<a class="miniColors-trigger" style="background-color: #' + color + '" href="#"></a>');
+ trigger.insertAfter(input);
+
+ // Set input data and update attributes
+ input
+ .addClass('miniColors')
+ .data('original-maxlength', input.attr('maxlength') || null)
+ .data('original-autocomplete', input.attr('autocomplete') || null)
+ .data('letterCase', 'uppercase')
+ .data('trigger', trigger)
+ .data('hsb', hsb)
+ .data('change', o.change ? o.change : null)
+ .attr('maxlength', 7)
+ .attr('autocomplete', 'off')
+ .val('#' + convertCase(color, o.letterCase));
+
+ // Handle options
+ if( o.readonly ) input.prop('readonly', true);
+ if( o.disabled ) disable(input);
+
+ // Show selector when trigger is clicked
+ trigger.bind('click.miniColors', function(event) {
+ event.preventDefault();
+ if( input.val() === '' ) input.val('#');
+ show(input);
+
+ });
+
+ // Show selector when input receives focus
+ input.bind('focus.miniColors', function(event) {
+ if( input.val() === '' ) input.val('#');
+ show(input);
+ });
+
+ // Hide on blur
+ input.bind('blur.miniColors', function(event) {
+ var hex = expandHex(input.val());
+ input.val( hex ? '#' + convertCase(hex, input.data('letterCase')) : '' );
+ });
+
+ // Hide when tabbing out of the input
+ input.bind('keydown.miniColors', function(event) {
+ if( event.keyCode === 9 ) hide(input);
+ });
+
+ // Update when color is typed in
+ input.bind('keyup.miniColors', function(event) {
+ setColorFromInput(input);
+ });
+
+ // Handle pasting
+ input.bind('paste.miniColors', function(event) {
+ // Short pause to wait for paste to complete
+ setTimeout( function() {
+ setColorFromInput(input);
+ }, 5);
+ });
+
+ };
+
+ var destroy = function(input) {
+ //
+ // Destroys an active instance of the miniColors selector
+ //
+
+ hide();
+ input = $(input);
+
+ // Restore to original state
+ input.data('trigger').remove();
+ input
+ .attr('autocomplete', input.data('original-autocomplete'))
+ .attr('maxlength', input.data('original-maxlength'))
+ .removeData()
+ .removeClass('miniColors')
+ .unbind('.miniColors');
+ $(document).unbind('.miniColors');
+ };
+
+ var enable = function(input) {
+ //
+ // Enables the input control and the selector
+ //
+ input
+ .prop('disabled', false)
+ .data('trigger')
+ .css('opacity', 1);
+ };
+
+ var disable = function(input) {
+ //
+ // Disables the input control and the selector
+ //
+ hide(input);
+ input
+ .prop('disabled', true)
+ .data('trigger')
+ .css('opacity', 0.5);
+ };
+
+ var show = function(input) {
+ //
+ // Shows the miniColors selector
+ //
+ if( input.prop('disabled') ) return false;
+
+ // Hide all other instances
+ hide();
+
+ // Generate the selector
+ var selector = $('<div class="miniColors-selector"></div>');
+ selector
+ .append('<div class="miniColors-colors" style="background-color: #FFF;"><div class="miniColors-colorPicker"></div></div>')
+ .append('<div class="miniColors-hues"><div class="miniColors-huePicker"></div></div>')
+ .css({
+ top: input.is(':visible') ? input.offset().top + input.outerHeight() : input.data('trigger').offset().top + input.data('trigger').outerHeight(),
+ left: input.is(':visible') ? input.offset().left : input.data('trigger').offset().left,
+ display: 'none'
+ })
+ .addClass( input.attr('class') );
+
+ // Set background for colors
+ var hsb = input.data('hsb');
+ selector
+ .find('.miniColors-colors')
+ .css('backgroundColor', '#' + hsb2hex({ h: hsb.h, s: 100, b: 100 }));
+
+ // Set colorPicker position
+ var colorPosition = input.data('colorPosition');
+ if( !colorPosition ) colorPosition = getColorPositionFromHSB(hsb);
+ selector.find('.miniColors-colorPicker')
+ .css('top', colorPosition.y + 'px')
+ .css('left', colorPosition.x + 'px');
+
+ // Set huePicker position
+ var huePosition = input.data('huePosition');
+ if( !huePosition ) huePosition = getHuePositionFromHSB(hsb);
+ selector.find('.miniColors-huePicker').css('top', huePosition.y + 'px');
+
+ // Set input data
+ input
+ .data('selector', selector)
+ .data('huePicker', selector.find('.miniColors-huePicker'))
+ .data('colorPicker', selector.find('.miniColors-colorPicker'))
+ .data('mousebutton', 0);
+
+ $('BODY').append(selector);
+ selector.fadeIn(100);
+
+ // Prevent text selection in IE
+ selector.bind('selectstart', function() { return false; });
+
+ $(document).bind('mousedown.miniColors touchstart.miniColors', function(event) {
+
+ input.data('mousebutton', 1);
+
+ if( $(event.target).parents().andSelf().hasClass('miniColors-colors') ) {
+ event.preventDefault();
+ input.data('moving', 'colors');
+ moveColor(input, event);
+ }
+
+ if( $(event.target).parents().andSelf().hasClass('miniColors-hues') ) {
+ event.preventDefault();
+ input.data('moving', 'hues');
+ moveHue(input, event);
+ }
+
+ if( $(event.target).parents().andSelf().hasClass('miniColors-selector') ) {
+ event.preventDefault();
+ return;
+ }
+
+ if( $(event.target).parents().andSelf().hasClass('miniColors') ) return;
+
+ hide(input);
+ });
+
+ $(document)
+ .bind('mouseup.miniColors touchend.miniColors', function(event) {
+ event.preventDefault();
+ input.data('mousebutton', 0).removeData('moving');
+ })
+ .bind('mousemove.miniColors touchmove.miniColors', function(event) {
+ event.preventDefault();
+ if( input.data('mousebutton') === 1 ) {
+ if( input.data('moving') === 'colors' ) moveColor(input, event);
+ if( input.data('moving') === 'hues' ) moveHue(input, event);
+ }
+ });
+
+ };
+
+ var hide = function(input) {
+
+ //
+ // Hides one or more miniColors selectors
+ //
+
+ // Hide all other instances if input isn't specified
+ if( !input ) input = '.miniColors';
+
+ $(input).each( function() {
+ var selector = $(this).data('selector');
+ $(this).removeData('selector');
+ $(selector).fadeOut(100, function() {
+ $(this).remove();
+ });
+ });
+
+ $(document).unbind('.miniColors');
+
+ };
+
+ var moveColor = function(input, event) {
+
+ var colorPicker = input.data('colorPicker');
+
+ colorPicker.hide();
+
+ var position = {
+ x: event.pageX,
+ y: event.pageY
+ };
+
+ // Touch support
+ if( event.originalEvent.changedTouches ) {
+ position.x = event.originalEvent.changedTouches[0].pageX;
+ position.y = event.originalEvent.changedTouches[0].pageY;
+ }
+ position.x = position.x - input.data('selector').find('.miniColors-colors').offset().left - 5;
+ position.y = position.y - input.data('selector').find('.miniColors-colors').offset().top - 5;
+ if( position.x <= -5 ) position.x = -5;
+ if( position.x >= 144 ) position.x = 144;
+ if( position.y <= -5 ) position.y = -5;
+ if( position.y >= 144 ) position.y = 144;
+
+ input.data('colorPosition', position);
+ colorPicker.css('left', position.x).css('top', position.y).show();
+
+ // Calculate saturation
+ var s = Math.round((position.x + 5) * 0.67);
+ if( s < 0 ) s = 0;
+ if( s > 100 ) s = 100;
+
+ // Calculate brightness
+ var b = 100 - Math.round((position.y + 5) * 0.67);
+ if( b < 0 ) b = 0;
+ if( b > 100 ) b = 100;
+
+ // Update HSB values
+ var hsb = input.data('hsb');
+ hsb.s = s;
+ hsb.b = b;
+
+ // Set color
+ setColor(input, hsb, true);
+ };
+
+ var moveHue = function(input, event) {
+
+ var huePicker = input.data('huePicker');
+
+ huePicker.hide();
+
+ var position = {
+ y: event.pageY
+ };
+
+ // Touch support
+ if( event.originalEvent.changedTouches ) {
+ position.y = event.originalEvent.changedTouches[0].pageY;
+ }
+
+ position.y = position.y - input.data('selector').find('.miniColors-colors').offset().top - 1;
+ if( position.y <= -1 ) position.y = -1;
+ if( position.y >= 149 ) position.y = 149;
+ input.data('huePosition', position);
+ huePicker.css('top', position.y).show();
+
+ // Calculate hue
+ var h = Math.round((150 - position.y - 1) * 2.4);
+ if( h < 0 ) h = 0;
+ if( h > 360 ) h = 360;
+
+ // Update HSB values
+ var hsb = input.data('hsb');
+ hsb.h = h;
+
+ // Set color
+ setColor(input, hsb, true);
+
+ };
+
+ var setColor = function(input, hsb, updateInput) {
+ input.data('hsb', hsb);
+ var hex = hsb2hex(hsb);
+ if( updateInput ) input.val( '#' + convertCase(hex, input.data('letterCase')) );
+ input.data('trigger').css('backgroundColor', '#' + hex);
+ if( input.data('selector') ) input.data('selector').find('.miniColors-colors').css('backgroundColor', '#' + hsb2hex({ h: hsb.h, s: 100, b: 100 }));
+
+ // Fire change callback
+ if( input.data('change') ) {
+ if( hex === input.data('lastChange') ) return;
+ input.data('change').call(input.get(0), '#' + hex, hsb2rgb(hsb));
+ input.data('lastChange', hex);
+ }
+
+ };
+
+ var setColorFromInput = function(input) {
+
+ input.val('#' + cleanHex(input.val()));
+ var hex = expandHex(input.val());
+ if( !hex ) return false;
+
+ // Get HSB equivalent
+ var hsb = hex2hsb(hex);
+
+ // If color is the same, no change required
+ var currentHSB = input.data('hsb');
+ if( hsb.h === currentHSB.h && hsb.s === currentHSB.s && hsb.b === currentHSB.b ) return true;
+
+ // Set colorPicker position
+ var colorPosition = getColorPositionFromHSB(hsb);
+ var colorPicker = $(input.data('colorPicker'));
+ colorPicker.css('top', colorPosition.y + 'px').css('left', colorPosition.x + 'px');
+ input.data('colorPosition', colorPosition);
+
+ // Set huePosition position
+ var huePosition = getHuePositionFromHSB(hsb);
+ var huePicker = $(input.data('huePicker'));
+ huePicker.css('top', huePosition.y + 'px');
+ input.data('huePosition', huePosition);
+
+ setColor(input, hsb);
+
+ return true;
+
+ };
+
+ var convertCase = function(string, letterCase) {
+ if( letterCase === 'lowercase' ) return string.toLowerCase();
+ if( letterCase === 'uppercase' ) return string.toUpperCase();
+ return string;
+ };
+
+ var getColorPositionFromHSB = function(hsb) {
+ var x = Math.ceil(hsb.s / 0.67);
+ if( x < 0 ) x = 0;
+ if( x > 150 ) x = 150;
+ var y = 150 - Math.ceil(hsb.b / 0.67);
+ if( y < 0 ) y = 0;
+ if( y > 150 ) y = 150;
+ return { x: x - 5, y: y - 5 };
+ };
+
+ var getHuePositionFromHSB = function(hsb) {
+ var y = 150 - (hsb.h / 2.4);
+ if( y < 0 ) h = 0;
+ if( y > 150 ) h = 150;
+ return { y: y - 1 };
+ };
+
+ var cleanHex = function(hex) {
+ return hex.replace(/[^A-F0-9]/ig, '');
+ };
+
+ var expandHex = function(hex) {
+ hex = cleanHex(hex);
+ if( !hex ) return null;
+ if( hex.length === 3 ) hex = hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2];
+ return hex.length === 6 ? hex : null;
+ };
+
+ var hsb2rgb = function(hsb) {
+ var rgb = {};
+ var h = Math.round(hsb.h);
+ var s = Math.round(hsb.s*255/100);
+ var v = Math.round(hsb.b*255/100);
+ if(s === 0) {
+ rgb.r = rgb.g = rgb.b = v;
+ } else {
+ var t1 = v;
+ var t2 = (255 - s) * v / 255;
+ var t3 = (t1 - t2) * (h % 60) / 60;
+ if( h === 360 ) h = 0;
+ if( h < 60 ) { rgb.r = t1; rgb.b = t2; rgb.g = t2 + t3; }
+ else if( h < 120 ) {rgb.g = t1; rgb.b = t2; rgb.r = t1 - t3; }
+ else if( h < 180 ) {rgb.g = t1; rgb.r = t2; rgb.b = t2 + t3; }
+ else if( h < 240 ) {rgb.b = t1; rgb.r = t2; rgb.g = t1 - t3; }
+ else if( h < 300 ) {rgb.b = t1; rgb.g = t2; rgb.r = t2 + t3; }
+ else if( h < 360 ) {rgb.r = t1; rgb.g = t2; rgb.b = t1 - t3; }
+ else { rgb.r = 0; rgb.g = 0; rgb.b = 0; }
+ }
+ return {
+ r: Math.round(rgb.r),
+ g: Math.round(rgb.g),
+ b: Math.round(rgb.b)
+ };
+ };
+
+ var rgb2hex = function(rgb) {
+ var hex = [
+ rgb.r.toString(16),
+ rgb.g.toString(16),
+ rgb.b.toString(16)
+ ];
+ $.each(hex, function(nr, val) {
+ if (val.length === 1) hex[nr] = '0' + val;
+ });
+ return hex.join('');
+ };
+
+ var hex2rgb = function(hex) {
+ hex = parseInt(((hex.indexOf('#') > -1) ? hex.substring(1) : hex), 16);
+
+ return {
+ r: hex >> 16,
+ g: (hex & 0x00FF00) >> 8,
+ b: (hex & 0x0000FF)
+ };
+ };
+
+ var rgb2hsb = function(rgb) {
+ var hsb = { h: 0, s: 0, b: 0 };
+ var min = Math.min(rgb.r, rgb.g, rgb.b);
+ var max = Math.max(rgb.r, rgb.g, rgb.b);
+ var delta = max - min;
+ hsb.b = max;
+ hsb.s = max !== 0 ? 255 * delta / max : 0;
+ if( hsb.s !== 0 ) {
+ if( rgb.r === max ) {
+ hsb.h = (rgb.g - rgb.b) / delta;
+ } else if( rgb.g === max ) {
+ hsb.h = 2 + (rgb.b - rgb.r) / delta;
+ } else {
+ hsb.h = 4 + (rgb.r - rgb.g) / delta;
+ }
+ } else {
+ hsb.h = -1;
+ }
+ hsb.h *= 60;
+ if( hsb.h < 0 ) {
+ hsb.h += 360;
+ }
+ hsb.s *= 100/255;
+ hsb.b *= 100/255;
+ return hsb;
+ };
+
+ var hex2hsb = function(hex) {
+ var hsb = rgb2hsb(hex2rgb(hex));
+ // Zero out hue marker for black, white, and grays (saturation === 0)
+ if( hsb.s === 0 ) hsb.h = 360;
+ return hsb;
+ };
+
+ var hsb2hex = function(hsb) {
+ return rgb2hex(hsb2rgb(hsb));
+ };
+
+
+ // Handle calls to $([selector]).miniColors()
+ switch(o) {
+
+ case 'readonly':
+
+ $(this).each( function() {
+ if( !$(this).hasClass('miniColors') ) return;
+ $(this).prop('readonly', data);
+ });
+
+ return $(this);
+
+ case 'disabled':
+
+ $(this).each( function() {
+ if( !$(this).hasClass('miniColors') ) return;
+ if( data ) {
+ disable($(this));
+ } else {
+ enable($(this));
+ }
+ });
+
+ return $(this);
+
+ case 'value':
+
+ // Getter
+ if( data === undefined ) {
+ if( !$(this).hasClass('miniColors') ) return;
+ var input = $(this),
+ hex = expandHex(input.val());
+ return hex ? '#' + convertCase(hex, input.data('letterCase')) : null;
+ }
+
+ // Setter
+ $(this).each( function() {
+ if( !$(this).hasClass('miniColors') ) return;
+ $(this).val(data);
+ setColorFromInput($(this));
+ });
+
+ return $(this);
+
+ case 'destroy':
+
+ $(this).each( function() {
+ if( !$(this).hasClass('miniColors') ) return;
+ destroy($(this));
+ });
+
+ return $(this);
+
+ default:
+
+ if( !o ) o = {};
+
+ $(this).each( function() {
+
+ // Must be called on an input element
+ if( $(this)[0].tagName.toLowerCase() !== 'input' ) return;
+
+ // If a trigger is present, the control was already created
+ if( $(this).data('trigger') ) return;
+
+ // Create the control
+ create($(this), o, data);
+
+ });
+
+ return $(this);
+
+ }
+
+ }
+
+ });
+
+})(jQuery); \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/editor/js/mapeditor.iefixes.js b/www/wiki/extensions/Maps/resources/editor/js/mapeditor.iefixes.js
new file mode 100644
index 00000000..a49e42fb
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/js/mapeditor.iefixes.js
@@ -0,0 +1,28 @@
+if (!Array.prototype.indexOf)
+{
+ Array.prototype.indexOf = function(elt /*, from*/)
+ {
+ var len = this.length >>> 0;
+
+ var from = Number(arguments[1]) || 0;
+ from = (from < 0)
+ ? Math.ceil(from)
+ : Math.floor(from);
+ if (from < 0)
+ from += len;
+
+ for (; from < len; from++)
+ {
+ if (from in this &&
+ this[from] === elt)
+ return from;
+ }
+ return -1;
+ };
+}
+
+if(typeof String.prototype.trim !== 'function') {
+ String.prototype.trim = function() {
+ return this.replace(/^\s+|\s+$/g, '');
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/editor/js/mapeditor.js b/www/wiki/extensions/Maps/resources/editor/js/mapeditor.js
new file mode 100644
index 00000000..795fcc53
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/editor/js/mapeditor.js
@@ -0,0 +1,919 @@
+var mapEditor = {
+ __map:null,
+ __drawingManager:null,
+ __mapObjects:[],
+ __controlsDiv:null,
+ __options:{
+ canvas:'map-canvas',
+ onRightClick:function(){}
+ },
+ __mapObjectOptions: {
+ marker:{
+ draggable:true
+ },
+ polyline:{
+ strokeWeight:2,
+ strokeOpacity:1,
+ strokeColor:'#FF0000',
+ editable:true
+ },
+ circle:{
+ strokeWeight:2,
+ strokeOpacity:1,
+ strokeColor:'#FF0000',
+ fillColor:'#FF0000',
+ fillOpacity:0.5,
+ editable:true
+ },
+ rectangle:{
+ strokeWeight:2,
+ strokeOpacity:1,
+ strokeColor:'#FF0000',
+ fillColor:'#FF0000',
+ fillOpacity:0.5,
+ editable:true
+ },
+ polygon:{
+ strokeWeight:2,
+ strokeOpacity:1,
+ strokeColor:'#FF0000',
+ fillColor:'#FF0000',
+ fillOpacity:0.5,
+ editable:true
+ },
+ imageoverlay:{
+ strokeWeight:1,
+ strokeOpacity:0.5,
+ strokeColor:'#000',
+ fillOpacity:0.0,
+ editable:true
+ }
+ },
+ __mapParameters:{
+ mappingservice: {
+ values:mw.config.get( 'egMapsAvailableServices' )
+ },
+ copycoords: {
+ values:['on','off']
+ },
+ markercluster: {
+ values:['on','off']
+ },
+ searchmarkers:{
+ values:['title','all']
+ },
+ 'static':{
+ values:['on','off']
+ },
+ maxzoom: {
+ values:[]
+ },
+ minzoom: {
+ values:[]
+ },
+ zoom:{
+ values:[]
+ },
+ centre:{
+ values:[]
+ },
+ title:{
+ values:[]
+ },
+ label:{
+ values:[]
+ },
+ icon:{
+ values:[]
+ },
+ type:{
+ values:[]
+ },
+ types:{
+ values:[]
+ },
+ layers:{
+ values:[]
+ },
+ controls:{
+ values:[]
+ },
+ zoomstyle:{
+ values:['default','small','large']
+ },
+ typestyle:{
+ values:[]
+ },
+ autoinfowindows:{
+ values:['on','off']
+ },
+ kml:{
+ values:[]
+ },
+ gkml:{
+ values:[]
+ },
+ resizable:{
+ values:[]
+ },
+ tilt:{
+ values:[]
+ },
+ kmlrezoom:{
+ values:['on','off']
+ },
+ poi:{
+ values:['on','off']
+ },
+ visitedicon:{
+ values:[]
+ }
+ },
+ __addMapObject:function(o){
+ var idx = this.__mapObjects.indexOf(o);
+ if(idx === -1){
+ this.__mapObjects.push(o);
+ o.overlay.setMap(this.__map);
+ }
+ },
+ __removeMapObject:function(o){
+ var idx = this.__mapObjects.indexOf(o);
+ if(idx !== -1){
+ this.__mapObjects[idx].overlay.setMap(null);
+ this.__mapObjects.splice(idx,1);
+ }
+ },
+ __createOrUpdateImageOverlay:function(e,imageUrl){
+ //remove old image overlay if exists
+ this.__removeMapObject(e.imageoverlay);
+
+ //set to new type so it doesn't collide with rectangle
+ e.type = 'imageoverlaybounds';
+
+ //add map objects
+ this.__addMapObject(e);
+ var image = new google.maps.GroundOverlay(imageUrl, e.overlay.getBounds());
+ var imageOverlay = {
+ overlay:image,
+ type:'imageoverlay'
+ };
+ this.__addMapObject(imageOverlay);
+ e.imageoverlay = imageOverlay;
+ imageOverlay.metadata = e.metadata;
+
+ //register right click listener if not already done
+ if(e.rightClickListener !== true){
+ google.maps.event.addListener(e.overlay, 'rightclick', function () {
+ mapEditor.__options.onRightClick(e);
+ });
+ e.rightClickListener = true;
+ }
+
+ //register bounds change listener if not already done
+ if(e.boundsChangedListener !== true){
+ google.maps.event.addListener(e.overlay, 'bounds_changed', function () {
+ //destroy and recreate imageoverlay (due to no e.imageoverlay.setBounds() method)
+ mapEditor.__createOrUpdateImageOverlay(e, e.imageoverlay.overlay.getUrl());
+ });
+ e.boundsChangedListener = true;
+ }
+
+ return imageOverlay;
+ },
+ __initControls:function(){
+ //Create root controls element
+ var controlDiv = this.__controlsDiv = document.createElement('div');
+ controlDiv.setAttribute('class','mapeditor-controls');
+ controlDiv.index = 1;
+
+ this.__map.controls[google.maps.ControlPosition.BOTTOM_CENTER].push(controlDiv);
+ },
+ __initMap:function(){
+ var myOptions = {
+ center:new google.maps.LatLng(0, 0),
+ zoom:1,
+ mapTypeId:google.maps.MapTypeId.ROADMAP
+ };
+
+ this.__map = new google.maps.Map(document.getElementById(this.__options.canvas),myOptions);
+
+ //noinspection JSUnresolvedVariable
+ var drawingManager = this.__drawingManager = new google.maps.drawing.DrawingManager({
+ drawingMode:null,
+ drawingControl:true,
+ drawingControlOptions:{
+ position:google.maps.ControlPosition.TOP_CENTER
+ },
+ markerOptions:this.__mapObjectOptions.marker,
+ circleOptions:this.__mapObjectOptions.circle,
+ rectangleOptions:this.__mapObjectOptions.rectangle,
+ polygonOptions:this.__mapObjectOptions.polygon,
+ polylineOptions:this.__mapObjectOptions.polyline
+ });
+ drawingManager.setMap(this.__map);
+
+ google.maps.event.addListener(drawingManager, 'overlaycomplete', function (e) {
+ mapEditor.__addMapObject(e);
+ mapEditor.__registerRightClickListener(e);
+ google.maps.event.trigger(e.overlay, 'rightclick');
+ });
+ },
+ __readMapObjectOptionsFromMetadata:function(e){
+ var options = $.extend({},this.__mapObjectOptions[e.type]);
+ for(var key in e.metadata){
+ var data = e.metadata[key];
+ if(data.value.trim() !== ''){
+ options[data.name] = data.value;
+ }
+ }
+ try{
+ e.overlay.setOptions(options);
+ return true;
+ }catch(e){
+ return false;
+ }
+ },
+ __writeMetaDataToMapObject:function(e,metadata){
+ e.metadata = this.__arrayToObject(metadata);
+ },
+ __convertPositionalParametersToMetaData:function(positionalArray){
+ var positionalNames = [
+ 'title',
+ 'text',
+ 'strokeColor',
+ 'strokeOpacity',
+ 'strokeWeight',
+ 'fillColor',
+ 'fillOpacity',
+ 'showOnHover'
+ ];
+
+ if(positionalArray !== undefined && positionalArray.length > 0){
+ if(positionalArray[0].trim().indexOf('link:') === 0){
+ positionalNames.splice(0,1);
+ positionalNames[0] = 'link';
+ }
+ }
+
+ for(var x = 0; x < positionalArray.length; x++){
+ positionalArray[x] = {
+ name:positionalNames[x],
+ value:positionalArray[x].trim()
+ };
+ }
+ return this.__arrayToObject(positionalArray);
+ },
+ __arrayToObject:function(arr){
+ var o = {};
+ for (var i = 0; i < arr.length; ++i){
+ o[i] = arr[i];
+ }
+ return o;
+ },
+ __registerRightClickListener:function(e){
+ google.maps.event.addListener(e.overlay, 'rightclick', function () {
+ mapEditor.__options.onRightClick(e);
+ });
+ },
+ __generateWikiCode:function( separators ){
+ var code = separators.codeStart;
+
+ var markers = '';
+ var circles = '';
+ var polygons = '';
+ var lines = '';
+ var rectangles = '';
+ var imageoverlays = '';
+
+ for(var x = 0; x < this.__mapObjects.length; x++){
+ var mapObject = this.__mapObjects[x].overlay;
+ var mapObjectType = this.__mapObjects[x].type;
+ var mapObjectMeta = this.__mapObjects[x].metadata;
+
+ var metadata = '';
+ if(mapObjectMeta !== undefined){
+ var delimiterPosition = '';
+ for(var key in mapObjectMeta){
+ var data = mapObjectMeta[key];
+ delimiterPosition += delimiterPosition.length > 0 ? ' ~' : '~';
+ if(data.value !== ''){
+ if(data.name === 'link' && data.value.indexOf('link:') === -1){
+ data.value = 'link:'+data.value;
+ }
+ if(!(mapObjectType === 'imageoverlay' && data.name === 'image')){
+ metadata += delimiterPosition+data.value;
+ delimiterPosition = '';
+ }
+ }
+ }
+ }
+
+ var serializedData = mapObject+metadata;
+ if (mapObjectType === 'marker') {
+ markers += markers === '' ? serializedData : '; '+serializedData;
+ } else if (mapObjectType === 'circle') {
+ circles += circles === '' ? serializedData : '; '+serializedData;
+ } else if (mapObjectType === 'polygon') {
+ polygons += polygons === '' ? serializedData : '; '+serializedData;
+ } else if (mapObjectType === 'polyline') {
+ lines += lines === '' ? serializedData : '; '+serializedData;
+ } else if (mapObjectType === 'rectangle') {
+ rectangles += rectangles === '' ? serializedData : '; '+serializedData;
+ }else if(mapObjectType === 'imageoverlay'){
+ imageoverlays += imageoverlays === '' ? serializedData : '; '+serializedData;
+ }
+ }
+
+
+ code += markers !== '' ? markers : '';
+ code += circles !== '' ? separators.separator+'circles='+circles : '';
+ code += polygons !== '' ? separators.separator+'polygons='+polygons : '';
+ code += lines !== '' ? separators.separator+'lines='+lines : '';
+ code += rectangles !== '' ? separators.separator+'rectangles='+rectangles : '';
+ code += imageoverlays !== '' ? separators.separator+'imageoverlays='+imageoverlays : '';
+
+ //add map parameters
+ for(var param in this.__mapParameters){
+ var value = this.__mapParameters[param].value;
+ if(value === undefined || value === ''){
+ continue;
+ }
+ code += '\n|'+param+'='+value;
+ }
+
+ code += separators.codeEnd;
+ return code;
+ },
+ __importWikiCode:function(rawData){
+ var syntaxPattern = /^\{\{#display_map:[\s\S]*\}\}[\s\n]*$/i;
+ if(rawData.match(syntaxPattern) === null){ //NO MATCH
+ return false;
+ }else{
+ try{
+ var patterns = {
+ marker: /^\{\{#display_map:\s*(.*)/i,
+ polyline: /\|\s*lines=(.*)/i,
+ circle:/\|\s*circles=(.*)/i,
+ polygon:/\|\s*polygons=(.*)/i,
+ rectangle:/\|\s*rectangles=(.*)/i,
+ imageoverlay:/\|\s*imageoverlays=(.*)/i,
+ parameter:/\|\s*(.*)=(.*)/i
+ };
+ var mapObjects = [];
+ rawData = rawData.split('\n');
+ for(var j = 0; j < rawData.length; j++){
+ for (var key in patterns){
+ var match = rawData[j].match(patterns[key]);
+ if(match !== null && match[1].trim().length !== 0){
+ var isMapObject = false;
+ if(key !== 'parameter'){
+ var data = match[1].split(';');
+ for(var i = 0; i < data.length; i++){
+
+ var metadata = data[i].split('~');
+ metadata.splice(0,1);
+ if(metadata.length > 0){
+ data[i] = data[i].substring(0,data[i].indexOf('~'));
+ }
+ metadata = this.__convertPositionalParametersToMetaData(metadata);
+
+ var options = this.__mapObjectOptions[key];
+ var mapObject = null;
+ if (key === 'marker') {
+ var position = data[i].split(',');
+ //noinspection JSValidateTypes
+ options = $.extend({
+ position: new google.maps.LatLng(position[0],position[1])
+ },options);
+ mapObject = new google.maps.Marker(options);
+ } else if (key === 'circle') {
+ var parts = data[i].split(':');
+ var radius = parts[1];
+ var position = parts[0].split(',');
+ //noinspection JSValidateTypes
+ options = $.extend({
+ center: new google.maps.LatLng(position[0],position[1]),
+ radius: parseFloat(radius)
+ },options);
+ mapObject = new google.maps.Circle(options);
+ } else if (key === 'polygon') {
+ var paths = data[i].split(':');
+ for(var x = 0; x < paths.length; x++){
+ var position = paths[x].split(',');
+ paths[x] = new google.maps.LatLng(position[0],position[1]);
+ }
+ paths = new google.maps.MVCArray(paths);
+ //noinspection JSValidateTypes
+ options = $.extend({
+ paths: paths
+ },options);
+ mapObject = new google.maps.Polygon(options);
+ } else if (key === 'polyline') {
+ var paths = data[i].split(':');
+ for(var x = 0; x < paths.length; x++){
+ var position = paths[x].split(',');
+ paths[x] = new google.maps.LatLng(position[0],position[1]);
+ }
+ paths = new google.maps.MVCArray(paths);
+ //noinspection JSValidateTypes
+ options = $.extend({
+ path: paths
+ },options);
+ mapObject = new google.maps.Polyline(options);
+ } else if (key === 'rectangle') {
+ var parts = data[i].split(':');
+ var ne = parts[0].split(',');
+ var sw = parts[1].split(',');
+ sw = new google.maps.LatLng(sw[0],sw[1]);
+ ne = new google.maps.LatLng(ne[0],ne[1]);
+ //noinspection JSValidateTypes
+ options = $.extend({
+ bounds: new google.maps.LatLngBounds(sw,ne)
+ },options);
+ mapObject = new google.maps.Rectangle(options);
+ }else if (key === 'imageoverlay'){
+ var parts = data[i].split(':');
+ var ne = parts[0].split(',');
+ var sw = parts[1].split(',');
+ var imageUrl = parts[2];
+ sw = new google.maps.LatLng(sw[0],sw[1]);
+ ne = new google.maps.LatLng(ne[0],ne[1]);
+
+ options = $.extend({
+ bounds: new google.maps.LatLngBounds(sw,ne)
+ },options);
+ var rectangle = new google.maps.Rectangle(options);
+
+ //add image url as metadata entry
+ metadata.image = {
+ name:'image',value:imageUrl
+ };
+
+ mapObject = {
+ type:'imageoverlaybounds',
+ overlay:rectangle,
+ metadata:metadata
+ };
+
+ this.__createOrUpdateImageOverlay(mapObject,imageUrl);
+ this.__readMapObjectOptionsFromMetadata(mapObject);
+
+ }
+ if(mapObject !== null){
+ //imageoverlay needs special handling
+ if(key !== 'imageoverlay' ){
+ mapObject = {
+ type:key,
+ overlay:mapObject,
+ metadata:metadata
+ };
+
+ this.__registerRightClickListener(mapObject);
+ this.__addMapObject(mapObject);
+ this.__readMapObjectOptionsFromMetadata(mapObject);
+ }
+
+ isMapObject = true;
+
+ }
+ }
+ }else if(!isMapObject){
+ //handle global map parameters
+ if(this.__mapParameters[match[1]] === undefined){
+ this.__mapParameters[match[1]] = {};
+ }
+ this.__mapParameters[match[1]].value = match[2];
+ }
+ }
+ }
+ }
+ }catch(e){
+ console.log('An error occurred when parsing data');
+ return false;
+ }
+ return true;
+ }
+ },
+ addControlButton:function (text, onclick){
+ // Set CSS for the control border
+ var controlUI = $('<div class="mapeditor-control-element"></div>');
+ $(controlUI).click(function(){
+ onclick.call(this);
+ }).appendTo(this.__controlsDiv);
+
+ // Set CSS for the control interior
+ var controlText = $('<span class="mapeditor-control-text"></span>')
+ .text(text).appendTo(controlUI);
+ },
+ setup:function(o){
+ //extend options
+ $.extend(this.__options,o);
+
+ //Override tostring methods for wiki code generation
+ google.maps.LatLng.prototype.toString = function(){
+ return this.lat()+','+this.lng();
+ };
+
+ google.maps.Rectangle.prototype.toString = function(){
+ var bounds = this.getBounds();
+ var ne = bounds.getNorthEast();
+ var sw = bounds.getSouthWest();
+ return ne+':'+sw;
+ };
+
+ google.maps.Marker.prototype.toString = function(){
+ var position = this.getPosition();
+ return position.lat()+','+position.lng();
+ };
+
+ google.maps.Circle.prototype.toString = function(){
+ var center = this.getCenter();
+ var radius = this.getRadius();
+ return center.lat()+','+center.lng()+':'+radius;
+ };
+
+ google.maps.Polygon.prototype.toString = function(){
+ var polygons = '';
+ this.getPath().forEach(function(e){
+ polygons += ':'+e;
+ });
+ return polygons.substr(1);
+ };
+
+ google.maps.Polyline.prototype.toString = function(){
+ var lines = '';
+ this.getPath().forEach(function(e){
+ lines += ':'+e;
+ });
+ return lines.substr(1);
+ };
+
+ google.maps.GroundOverlay.prototype.toString = function(){
+ var bounds = this.getBounds();
+ var sw = bounds.getSouthWest();
+ var ne = bounds.getNorthEast();
+ return [ne,sw,this.getUrl()].join(':');
+ };
+
+ //initialize rest
+ this.__initMap();
+ this.__initControls();
+ }
+};
+
+$(document).ready(function(){
+
+
+ function openDialog(e){
+ if(e.metadata !== undefined){
+ for(var key in e.metadata){
+ var data = e.metadata[key];
+ $(this).find('form input[name="'+data.name+'"]').val(data.value);
+ }
+ }
+ var i18nButtons = {};
+ i18nButtons[mw.msg('mapeditor-done-button')] = function () {
+ var form = $(this).find('form');
+ form.find('.miniColors').each(function(){
+ if($(this).val() === '#'){
+ $(this).val('');
+ }
+ });
+ mapEditor.__writeMetaDataToMapObject(e,form.serializeArray());
+ $(this).dialog("close");
+ if(!mapEditor.__readMapObjectOptionsFromMetadata(e)){
+ alert(mw.msg('mapeditor-parser-error'));
+ }
+ };
+ i18nButtons[mw.msg('mapeditor-remove-button')] = function () {
+ mapEditor.__removeMapObject(e);
+ $(this).dialog("close");
+ };
+
+ this.dialog({
+ modal:true,
+ buttons:i18nButtons,
+ open:function(){
+ if(e.metadata !== undefined){
+ var isText = true;
+ for(var key in e.metadata){
+ var data = e.metadata[key];
+ if(data.name === 'link' && data.value.length > 0){
+ isText = false;
+ break;
+ }
+ }
+ //depending on existing metadata,
+ //show either form with title/text fields or just link field
+ if(isText){
+ $(this).find('input[value="text"]').trigger('click');
+ }else{
+ $(this).find('input[value="link"]').trigger('click');
+ }
+ }else{
+ //default trigger click on text radio button
+ $(this).find('input[value="text"]').trigger('click');
+ }
+
+
+ },
+ beforeClose:function(){
+ //reset the form
+ var form = $(this).find('form');
+ form[0].reset();
+ form.find('.opacity-data-holder').text(mw.msg('mapeditor-none-text'));
+ form.find('.ui-slider').slider('value',-1);
+ form.find('.miniColors').miniColors('value','#fff').val('');
+ }
+ });
+ }
+
+ function openImageOverlayDialog(e,callback){
+
+ var form = $('#imageoverlay-form');
+
+ var i18nButtons = {};
+ i18nButtons[mw.msg('mapeditor-done-button')] = function(){
+ var imageUrl = $(this).find('input[name="image"]').val();
+ mapEditor.__createOrUpdateImageOverlay(e,imageUrl);
+
+ var metadata = form.find('form').serializeArray();
+ mapEditor.__writeMetaDataToMapObject(e,metadata);
+ mapEditor.__writeMetaDataToMapObject(e.imageoverlay,metadata);
+
+ form.dialog("close");
+ };
+
+ i18nButtons[mw.msg('mapeditor-remove-button')] = function () {
+ mapEditor.__removeMapObject(e.imageoverlay);
+ e.imageoverlay = undefined;
+ form.dialog("close");
+ };
+
+ form.dialog({
+ modal:true,
+ buttons:i18nButtons,
+ open:function(){
+ //restore data from previous edits
+ if(e.metadata !== undefined){
+ var isText = true;
+ for(var key in e.metadata){
+ var data = e.metadata[key];
+ if(data.name === 'link' && data.value.length > 0){
+ isText = false;
+ }
+ form.find('form input[name="'+data.name+'"]').val(data.value);
+ }
+ //depending on existing metadata,
+ //show either form with title/text fields or just link field
+ if(isText){
+ form.find('input[value="text"]').trigger('click');
+ }else{
+ form.find('input[value="link"]').trigger('click');
+ }
+ }else{
+ //default trigger click on text radio button
+ form.find('input[value="text"]').trigger('click');
+ }
+ },
+ beforeClose:function(){
+ mapEditor.__drawingManager.setMap(mapEditor.__map); //re-enable standard drawing manager
+ if(e.imageoverlay === undefined){
+ mapEditor.__removeMapObject(e);
+ }
+
+ //reset the form
+ var formElement = form.find('form');
+ formElement[0].reset();
+
+ if(callback !== undefined && typeof(callback) === 'function'){
+ callback();
+ }
+
+ }
+ });
+ }
+
+ mapEditor.setup({
+ onRightClick:function(e){
+ if (e.type === 'marker') {
+ openDialog.call($('#marker-form'),e);
+ } else if (e.type === 'circle') {
+ openDialog.call($('#fillable-form'),e);
+ } else if (e.type === 'polygon') {
+ openDialog.call($('#polygon-form'),e);
+ } else if (e.type === 'polyline') {
+ openDialog.call($('#strokable-form'),e);
+ } else if (e.type === 'rectangle') {
+ openDialog.call($('#fillable-form'),e);
+ } else if (e.type === 'imageoverlaybounds') {
+ openImageOverlayDialog(e);
+ }
+ }
+ });
+
+ //add custom controls
+ if( $('#map-canvas').attr('context') != 'forminput' ) { //for Special:MapEditor
+ var editorMarkers = {
+ 'codeStart' : '{{#display_map: ',
+ 'separator' : '\n|',
+ 'codeEnd' : '\n}}\n'
+ };
+ mapEditor.addControlButton(mw.msg('mapeditor-export-button'),function(){
+ var code = mapEditor.__generateWikiCode( editorMarkers );
+ if(navigator.appName == 'Microsoft Internet Explorer'){
+ //if IE replace /n with /r/n so it is displayed properly
+ code = code.split('\n').join('\r\n');
+ }
+ $('#code-output').text(code);
+ $('#code-output-container').dialog({
+ modal:true,
+ width:'80%',
+ open:function(){
+ $('#code-output').focus();
+ }
+ });
+ });
+
+ mapEditor.addControlButton(mw.msg('mapeditor-import-button'), function(){
+ var i18nButtons = {};
+ i18nButtons[mw.msg('mapeditor-import-button2')] = function () {
+ var data = $('#code-input').val();
+ if(mapEditor.__importWikiCode(data)){
+ $(this).dialog('close');
+ }else{
+ alert('Could not parse input! make sure the input has the same structure as exported wiki code');
+ }
+ };
+ $('#code-input-container').dialog({
+ modal:true,
+ width:'80%',
+ buttons: i18nButtons
+ });
+ });
+ } else { //for form input
+ var forminputMarkers = {
+ 'codeStart' : '',
+ 'separator' : '',
+ 'codeEnd' : ''
+ };
+ mapEditor.addControlButton(mw.msg('mapeditor-export-button'),function(){
+ var code = mapEditor.__generateWikiCode( forminputMarkers );
+ if(navigator.appName == 'Microsoft Internet Explorer'){
+ //if IE replace /n with /r/n so it is displayed properly
+ code = code.split('\n').join('\r\n');
+ }
+ $('#map-polygon').text(code);
+ });
+ }
+
+ mapEditor.addControlButton(mw.msg('mapeditor-mapparam-button'), function(){
+ var i18nButtons = {};
+ i18nButtons[mw.msg('mapeditor-done-button')] = function(){
+ var data = $(this).find('form input').not('select').serializeArray();
+ for(var x = 0; x < data.length; x++){
+ mapEditor.__mapParameters[data[x].name].value = data[x].value;
+ }
+ $(this).dialog('close');
+ };
+ $('#map-parameter-form').dialog({
+ modal:true,
+ width: 500,
+ buttons:i18nButtons
+ });
+ });
+
+ mapEditor.addControlButton(mw.msg('mapeditor-clear-button'), function(){
+ while(mapEditor.__mapObjects.length > 0){
+ var mapObj = mapEditor.__mapObjects.pop();
+ mapObj.overlay.setMap(null);
+ }
+ for(var param in mapEditor.__mapParameters){
+ mapEditor.__mapParameters[param].value = undefined;
+ }
+ });
+
+ mapEditor.addControlButton(mw.msg('mapeditor-imageoverlay-button'), function(){
+ var button = $(this);
+ if(button.data('clicked') === true){
+ return; //already clicked, disregard this click
+ }else{
+ button.data('clicked',true);
+ }
+
+ mapEditor.__drawingManager.setMap(null); //disable current drawing manager
+
+ var drawingManager = new google.maps.drawing.DrawingManager({
+ drawingMode:google.maps.drawing.OverlayType.RECTANGLE,
+ drawingControl:false,
+ rectangleOptions:mapEditor.__mapObjectOptions.imageoverlay
+ });
+ drawingManager.setMap(mapEditor.__map);
+
+ google.maps.event.addListener(drawingManager, 'overlaycomplete', function (e) {
+ mapEditor.__addMapObject(e); //add if it doesn't already exist.
+
+ drawingManager.setMap(null);
+
+ openImageOverlayDialog(e,function(){
+ //re-enable button
+ button.data('clicked',false);
+ });
+
+ });
+
+ });
+
+
+
+ //init map parameters
+ var formselect = $('#map-parameter-form select[name="key"]');
+ formselect.on('change',function(){
+ var option = $(this);
+ var key = option.val();
+ var value = mapEditor.__mapParameters[key].value;
+ if(value === undefined){
+ value = '';
+ }
+
+ var parent = option.parent();
+ var input = $('<input type="text" name="'+key+'" value="'+value+'"></input>');
+ var removeButton = $('<a href="#">[x]</a>');
+ var option2 = option.clone(true);
+ var container = $('<div></div>');
+
+ option2.find('option[value="'+key+'"]').remove();
+ option.attr('disabled',true);
+ removeButton.on('click',function(){
+ var removedKey = $(this).prevAll('select').val();
+ var activeSelect = $(this).parent().parent().find('select').not('select[disabled="disabled"]');
+ var option = $('<option value="'+removedKey+'">'+removedKey+'</option>');
+ activeSelect.children().first().after(option);
+ $(this).parent().remove();
+ mapEditor.__mapParameters[key].value = undefined;
+ return false;
+ });
+
+ parent.append(input);
+ parent.append(removeButton);
+ parent.parent().append(container);
+ container.append(option2);
+
+ input.autocomplete({
+ source: mapEditor.__mapParameters[key].values,
+ minLength: 0,
+ autoFocus: true
+ });
+ input.autocomplete('search','');
+ });
+
+ for(var parameter in mapEditor.__mapParameters){
+ var option = $('<option value="'+parameter+'">'+parameter+'</option>');
+ formselect.append(option);
+ }
+
+ //hide link input initially
+ $('input[name="link"]').attr('disabled',true).hide().prev().hide();
+
+ //init text/link switcher
+ $('input[name="switch"]').on('click',function(){
+ if($(this).val() === 'link'){
+ $(this).parent().next().find('input[name="title"],input[name="text"]').attr('disabled',true).hide().prev().hide();
+ $(this).parent().next().find('input[name="link"]').attr('disabled',false).show().prev().show();
+ }else{
+ $(this).parent().next().find('input[name="title"],input[name="text"]').attr('disabled',false).show().prev().show();
+ $(this).parent().next().find('input[name="link"]').attr('disabled',true).hide().prev().hide();
+ }
+ });
+
+ //init enter keypress to press done on dialog.
+ $('.mapeditor-dialog').on('keypress',function(e){
+ if(e.keyCode === 13){
+ $(this).dialog('option','buttons').Done.call(this);
+ }
+ });
+
+ //init sliders
+ $('input[name="strokeOpacity"],input[name="fillOpacity"]').each(function(){
+ var input = $(this);
+ var dataHolder = $('<span class="opacity-data-holder">'+mw.msg('mapeditor-none-text')+'</span>');
+ dataHolder.css({fontSize: 12});
+ var slider = $('<div></div>').slider({
+ min: -1,
+ slide: function(event, ui){
+ if(ui.value === -1){
+ input.val('');
+ dataHolder.text(mw.msg('mapeditor-none-text'));
+ }else{
+ input.val( ui.value/100 );
+ dataHolder.text(ui.value+'%');
+ }
+ }
+ });
+ input.before(dataHolder);
+ input.after(slider);
+ });
+
+ //init color pickers
+ $('input[name="strokeColor"],input[name="fillColor"]').miniColors().miniColors('value','').val('');
+});
diff --git a/www/wiki/extensions/Maps/resources/ext.maps.common.js b/www/wiki/extensions/Maps/resources/ext.maps.common.js
new file mode 100644
index 00000000..8e0180b4
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/ext.maps.common.js
@@ -0,0 +1,4 @@
+window.maps = new ( function() {
+ this.googlemapsList = [];
+ this.leafletList = [];
+} )();
diff --git a/www/wiki/extensions/Maps/resources/ext.maps.services.js b/www/wiki/extensions/Maps/resources/ext.maps.services.js
new file mode 100644
index 00000000..a23ff0c8
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/ext.maps.services.js
@@ -0,0 +1,86 @@
+/*global jQuery, mediaWiki, maps */
+/*global confirm */
+( function ( $, mw, maps ) {
+ 'use strict';
+
+ /**
+ * @since 3.5
+ *
+ * @param {object} container
+ * @return {this}
+ */
+ var services = function ( container ) {
+
+ if ( $.type( container ) !== 'object' ) {
+ throw new Error( 'The container is not of the correct type ' + $.type( container ) );
+ }
+
+ this.container = container;
+
+ return this;
+ };
+
+ /* Public methods */
+
+ services.prototype = {
+
+ constructor: services,
+
+ /**
+ * @since 3.5
+ *
+ * @param {string} service
+ */
+ render: function( service ) {
+ if ( service === 'googlemaps' || service === 'maps' || service === 'googlemaps3' ) {
+ this.google();
+ }
+
+ if ( service === 'leaflet' || service === 'leafletmaps' ) {
+ this.leaflet();
+ }
+ },
+
+ /**
+ * Google service
+ *
+ * @since 3.5
+ */
+ google: function() {
+
+ var self = this;
+
+ // https://www.mediawiki.org/wiki/ResourceLoader/Modules#mw.loader.using
+ mw.loader.using( 'ext.maps.googlemaps3' ).done( function () {
+
+ if ( typeof google === 'undefined' ) {
+ throw new Error( 'The google map service is unknown, please ensure that the API or module is loaded correctly.' );
+ }
+
+ self.container.find( '.maps-googlemaps3' ).each( function() {
+ var $this = $( this );
+ $this.googlemaps( $.parseJSON( $this.find( 'div').text() ) );
+ } );
+ } );
+ },
+
+ /**
+ * Leaflet service
+ *
+ * @since 3.5
+ */
+ leaflet: function() {
+ mw.loader.using( 'ext.maps.leaflet' ).done( function () {
+ $( '.maps-leaflet' ).each( function() {
+ var $this = $( this );
+ maps.leafletList.push(
+ $this.leafletmaps( $.parseJSON( $this.find( 'div').text() ) )
+ );
+ } );
+ } );
+ }
+ };
+
+ maps.services = services;
+
+}( jQuery, mediaWiki, maps ) );
diff --git a/www/wiki/extensions/Maps/resources/ext.sm.common.js b/www/wiki/extensions/Maps/resources/ext.sm.common.js
new file mode 100644
index 00000000..373c1dd9
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/ext.sm.common.js
@@ -0,0 +1,76 @@
+/**
+ * JavaScript the Semantic Maps extension.
+ * @see https://www.mediawiki.org/wiki/Extension:Semantic_Maps
+ *
+ * @licence GNU GPL v2++
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+window.sm = new ( function( $, mw ) {
+
+ this.buildQueryString = function( query, ajaxcoordproperty, top, right, bottom, left ) {
+ var isCompoundQuery = query.indexOf( '|' ) > -1;
+ var query = query.split( '|' );
+ $.each( query, function( index ) {
+ query[index] += ' [[' + ajaxcoordproperty + '::+]] ';
+ query[index] += '[[' + ajaxcoordproperty + '::>' + bottom + '°, ' + left + '°]] ';
+ query[index] += '[[' + ajaxcoordproperty + '::<' + top + '°, ' + right + '°]]';
+ if( !isCompoundQuery ) {
+ query[index] += '|?' + ajaxcoordproperty;
+ } else {
+ query[index] += ';?' + ajaxcoordproperty;
+ }
+ } );
+ return query.join( ' | ' );
+ };
+
+ /**
+ * Detects semicolons `;` not in square brackets `[]`.
+ *
+ * @param string
+ * @returns {boolean}
+ */
+ this.hasCompoundQuerySemicolon = function( string ) {
+ return /;(?![^[]*])/g.test( string );
+ };
+
+ this.sendQuery = function( query ) {
+ var action = this.hasCompoundQuerySemicolon( query ) ? 'compoundquery' : 'ask';
+ return $.ajax( {
+ method: 'GET',
+ url: mw.util.wikiScript( 'api' ),
+ data: {
+ 'action': action,
+ 'query': query,
+ 'format': 'json'
+ },
+ dataType: 'json'
+ } );
+ };
+
+ this.ajaxUpdateMarker = function( map, query, icon ) {
+ return this.sendQuery( query ).done( function( data ) {
+ if( !data.hasOwnProperty( 'query' ) ||
+ !data.query.hasOwnProperty( 'results' ) ) {
+ return;
+ }
+ // todo: don't remove and recreate all markers..
+ // only add new ones.
+ map.removeMarkers();
+ for( var property in data.query.results ) {
+ if( data.query.results.hasOwnProperty( property ) ) {
+ var location = data.query.results[property];
+ var coordinates = location.printouts[map.options.ajaxcoordproperty][0];
+ var markerOptions = {
+ lat: coordinates.lat,
+ lon: coordinates.lon,
+ title: location.fulltext,
+ text: '<b><a href="' + location.fullurl + '">' + location.fulltext + '</a></b>',
+ icon: icon
+ };
+ map.addMarker( markerOptions );
+ }
+ }
+ } );
+ };
+
+} )( jQuery, mediaWiki );
diff --git a/www/wiki/extensions/Maps/resources/leaflet/cluster/m1.png b/www/wiki/extensions/Maps/resources/leaflet/cluster/m1.png
new file mode 100644
index 00000000..329ff524
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/cluster/m1.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/cluster/m2.png b/www/wiki/extensions/Maps/resources/leaflet/cluster/m2.png
new file mode 100644
index 00000000..b999cbcf
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/cluster/m2.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/cluster/m3.png b/www/wiki/extensions/Maps/resources/leaflet/cluster/m3.png
new file mode 100644
index 00000000..9f30b309
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/cluster/m3.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/cluster/m4.png b/www/wiki/extensions/Maps/resources/leaflet/cluster/m4.png
new file mode 100644
index 00000000..0d3f8263
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/cluster/m4.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/cluster/m5.png b/www/wiki/extensions/Maps/resources/leaflet/cluster/m5.png
new file mode 100644
index 00000000..61387d2a
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/cluster/m5.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/ext.maps.leaflet.js b/www/wiki/extensions/Maps/resources/leaflet/ext.maps.leaflet.js
new file mode 100644
index 00000000..ce3e757f
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/ext.maps.leaflet.js
@@ -0,0 +1,3 @@
+window.jQuery( document ).ready( function() {
+ ( new maps.services( window.jQuery( document ) ) ).leaflet();
+} ); \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/leaflet/ext.sm.leafletajax.js b/www/wiki/extensions/Maps/resources/leaflet/ext.sm.leafletajax.js
new file mode 100644
index 00000000..fb9f7341
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/ext.sm.leafletajax.js
@@ -0,0 +1,44 @@
+/**
+ * JavaScript for Leaflet in the Semantic Maps extension.
+ * @see https://www.mediawiki.org/wiki/Extension:Semantic_Maps
+ *
+ * @licence GNU GPL v2+
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+
+
+(function( $, sm ) {
+ var ajaxRequest = null;
+
+ var mapEvents = ['dragend', 'zoomend'];
+
+ $( document ).ready( function() {
+ // todo: find a way to remove setTimeout.
+ setTimeout( function() {
+ $( window.maps.leafletList ).each( function( index, map ) {
+ if( !map.options.ajaxquery || !map.options.ajaxcoordproperty ) {
+ return;
+ }
+ map.map.on( mapEvents.join( ' ' ), function() {
+ var bounds = map.map.getBounds();
+ var query = sm.buildQueryString(
+ decodeURIComponent( map.options.ajaxquery.replace( /\+/g, ' ' ) ),
+ map.options.ajaxcoordproperty,
+ bounds.getNorthEast().lat,
+ bounds.getNorthEast().lng,
+ bounds.getSouthWest().lat,
+ bounds.getSouthWest().lng
+ );
+
+ if( ajaxRequest !== null ) {
+ ajaxRequest.abort();
+ }
+ ajaxRequest = sm.ajaxUpdateMarker( map, query, map.options.icon ).done( function() {
+ map.createMarkerCluster();
+ ajaxRequest = null;
+ } );
+ } );
+ } );
+ }, 1000 );
+ } );
+})( window.jQuery, window.sm );
diff --git a/www/wiki/extensions/Maps/resources/leaflet/jquery.leaflet.js b/www/wiki/extensions/Maps/resources/leaflet/jquery.leaflet.js
new file mode 100644
index 00000000..3483ec3a
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/jquery.leaflet.js
@@ -0,0 +1,434 @@
+/**
+ * JavaScript for Leaflet in the Maps extension.
+ * @see https://www.mediawiki.org/wiki/Extension:Maps
+ *
+ * @author Pavel Astakhov < pastakhov@yandex.ru >
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+(function ($, mw, L, MQ) {
+ $.fn.leafletmaps = function ( options ) {
+ var _this = this;
+ this.map = null;
+ this.options = options;
+ this.markers = [];
+ this.markercluster = null;
+ var apikeys = mw.config.get('egMapsLeafletLayersApiKeys') ;
+
+ /**
+ * array point of all map elements (markers, lines, polygons, etc.)
+ * for map fit
+ */
+ this.points = [];
+
+ /**
+ * Creates a new marker with the provided data and returns it.
+ * @param {Object} properties Contains the fields lat, lon, title, text and icon
+ * @return {L.Marker}
+ */
+ this.createMarker = function (properties) {
+ this.points.push( new L.LatLng(properties.lat, properties.lon) );
+
+ var markerOptions = {
+ title:properties.title
+ };
+
+ var marker = L.marker( [properties.lat, properties.lon], markerOptions );
+
+ if (properties.hasOwnProperty('icon') && properties.icon !== '') {
+ marker.setOpacity(0);
+
+ var img = new Image();
+ img.onload = function() {
+ var icon = new L.Icon({
+ iconUrl: properties.icon,
+ iconSize: [ img.width, img.height ],
+ iconAnchor: [ img.width / 2, img.height ],
+ popupAnchor: [ -img.width % 2, -img.height*2/3 ]
+ });
+
+ marker.setIcon(icon);
+ marker.setOpacity(1);
+ };
+ img.src = properties.icon;
+ }
+
+ if( properties.hasOwnProperty('text') && properties.text.length > 0 ) {
+ marker.bindPopup( properties.text );
+ }
+
+ if ( options.copycoords ) {
+ marker.on(
+ 'contextmenu',
+ function( e ) {
+ prompt(mw.msg('maps-copycoords-prompt'), e.latlng.lat + ',' + e.latlng.lng);
+ }
+ );
+ }
+
+ return marker;
+ };
+
+ /**
+ * Creates a new marker with the provided data, adds it to the map
+ * and returns it.
+ * @param {Object} properties Contains the fields lat, lon, title, text and icon
+ * @return {L.Marker}
+ */
+ this.addMarker = function (properties) {
+ var marker = this.createMarker(properties);
+ if (!this.options.markercluster) {
+ marker.addTo( this.map );
+ }
+ this.markers.push( marker );
+ return marker;
+ };
+
+ this.removeMarker = function (marker) {
+ this.map.removeLayer(marker);
+ this.points = [];
+ this.markers = this.markers.filter(function(object) {
+ return object !== marker;
+ });
+ };
+
+ this.removeMarkers = function () {
+ if (this.markercluster) {
+ this.map.removeLayer(this.markercluster);
+ this.markercluster = null;
+ }
+ var map = this.map;
+ $.each(this.markers, function(index, marker) {
+ map.removeLayer(marker);
+ });
+
+ this.points = [];
+ this.markers = [];
+ };
+
+ this.addLine = function (properties) {
+ var options = {
+ color: properties.strokeColor,
+ weight:properties.strokeWeight,
+ opacity:properties.strokeOpacity
+ };
+
+ var latlngs = [];
+ for (var x = 0; x < properties.pos.length; x++) {
+ latlngs.push([properties.pos[x].lat, properties.pos[x].lon]);
+ this.points.push( new L.LatLng(properties.pos[x].lat, properties.pos[x].lon) );
+ }
+
+ var line = L.polyline(latlngs, options).addTo(this.map);
+
+ if( properties.hasOwnProperty('text') && properties.text.trim().length > 0 ) {
+ line.bindPopup( properties.text );
+ }
+ };
+
+ this.addPolygon = function (properties) {
+ properties.pos.forEach(function(position) {
+ _this.points.push( new L.LatLng(position.lat, position.lon) );
+ });
+
+ var polygon = L.polygon(
+ properties.pos.map(function(position) {
+ return [position.lat, position.lon];
+ }),
+ {
+ color: properties.strokeColor,
+ weight:properties.strokeWeight,
+ opacity:properties.strokeOpacity,
+ fillColor:properties.fillColor,
+ fillOpacity:properties.fillOpacity
+ }
+ );
+
+ polygon.addTo(this.map);
+
+ if( properties.hasOwnProperty('text') && properties.text.trim().length > 0 ) {
+ console.log(properties.text);
+ polygon.bindPopup( properties.text );
+ }
+ };
+
+ this.addCircle = function (properties) {
+ var circle = L.circle(
+ [properties.centre.lat, properties.centre.lon],
+ {
+ radius: properties.radius,
+ color: properties.strokeColor,
+ weight:properties.strokeWeight,
+ opacity:properties.strokeOpacity,
+ fillColor:properties.fillColor,
+ fillOpacity:properties.fillOpacity,
+ }
+ ).addTo(this.map);
+
+ this.points.push( new L.LatLng(properties.centre.lat, properties.centre.lon) );
+
+ if( properties.hasOwnProperty('text') && properties.text.trim().length > 0 ) {
+ circle.bindPopup( properties.text );
+ }
+ };
+
+ this.addRectangle = function (properties) {
+ this.points.push( new L.LatLng(properties.sw.lat, properties.sw.lon) );
+ this.points.push( new L.LatLng(properties.ne.lat, properties.ne.lon) );
+
+ var options = {
+ color: properties.strokeColor,
+ weight:properties.strokeWeight,
+ opacity:properties.strokeOpacity,
+ fillColor:properties.fillColor,
+ fillOpacity:properties.fillOpacity
+ };
+
+ var bounds = [[properties.sw.lat, properties.sw.lon], [properties.ne.lat, properties.ne.lon]];
+
+ var rectangle = L.rectangle( bounds, options ).addTo(this.map);
+
+ if( properties.hasOwnProperty('text') && properties.text.trim().length > 0 ) {
+ rectangle.bindPopup( properties.text );
+ }
+ };
+
+ this.createMarkerCluster = function () {
+ if ( !options.markercluster ) {
+ return;
+ }
+ var markers = this.markers;
+
+ var markercluster = new L.MarkerClusterGroup({
+ maxClusterRadius: options.clustermaxradius,
+ disableClusteringAtZoom: options.clustermaxzoom + 1,
+ zoomToBoundsOnClick: options.clusterzoomonclick,
+ spiderfyOnMaxZoom: options.clusterspiderfy,
+ iconCreateFunction: function(cluster) {
+ var childCount = cluster.getChildCount();
+
+ var imagePath = mw.config.get( 'egMapsScriptPath' ) + '/resources/leaflet/cluster/';
+
+ var styles = [
+ {
+ iconUrl: imagePath + 'm1.png',
+ iconSize: [53, 52]
+ },
+ {
+ iconUrl: imagePath + 'm2.png',
+ iconSize: [56, 55]
+ },
+ {
+ iconUrl: imagePath + 'm3.png',
+ iconSize: [66, 65]
+ },
+ {
+ iconUrl: imagePath + 'm4.png',
+ iconSize: [78, 77]
+ },
+ {
+ iconUrl: imagePath + 'm5.png',
+ iconSize: [90, 89]
+ }
+ ];
+
+ var index = 0;
+ var dv = childCount;
+ while (dv !== 0) {
+ dv = parseInt(dv / 10, 10);
+ index++;
+ }
+ var index = Math.min(index, styles.length);
+ index = Math.max(0, index - 1);
+ index = Math.min(styles.length - 1, index);
+ var style = styles[index];
+
+ return new L.divIcon({
+ iconSize: style.iconSize,
+ className: '',
+ html: '<img style="' +
+ '" src="' + style.iconUrl + '" />' +
+ '<span style="' +
+ 'position: absolute; font-size: 11px; font-weight: bold; text-align: center; ' +
+ 'top: 0; left: 0; ' +
+ 'line-height: ' + style.iconSize[1] + 'px;' +
+ 'width: ' + style.iconSize[0] + 'px;' +
+ '">' + childCount + '</span>'
+ });
+ }
+ });
+ $.each(this.markers, function(index, marker) {
+ markercluster.addLayer(marker);
+ });
+ if (this.markercluster) {
+ this.map.removeLayer(this.markercluster);
+ this.markercluster = null;
+ }
+ this.map.addLayer(markercluster);
+ this.markercluster = markercluster;
+ };
+
+ this.addGeoJson = function(options) {
+ if (options.geojson !== '') {
+ var geoJson = options.geojson;
+ var geoJsonLayer = L.geoJSON( geoJson ).addTo( this.map );
+
+ this.points.push( geoJsonLayer.getBounds().getNorthEast() );
+ this.points.push( geoJsonLayer.getBounds().getSouthWest() );
+ }
+ };
+
+ this.setup = function () {
+
+ var mapOptions = {};
+ if (options.minzoom !== false ) mapOptions.minZoom = options.minzoom;
+ if (options.maxzoom !== false ) mapOptions.maxZoom = options.maxzoom;
+
+ if (options.enablefullscreen) {
+ mapOptions.fullscreenControl = true;
+ mapOptions.fullscreenControlOptions= {
+ position: 'topleft'
+ };
+ }
+
+ mapOptions.scrollWheelZoom = options.scrollwheelzoom;
+
+ if (options.static) {
+ mapOptions.scrollWheelZoom = false;
+ mapOptions.doubleClickZoom = false;
+ mapOptions.touchZoom = false;
+ mapOptions.boxZoom = false;
+ mapOptions.tap = false;
+ mapOptions.keyboard = false;
+ mapOptions.zoomControl = false;
+ mapOptions.dragging = false;
+ }
+
+ var map = L.map( this.get(0), mapOptions ).fitWorld();
+ this.map = map;
+
+ var layers = {};
+ $.each(options.layers.reverse(), function(index, layerName) {
+ var options = {} ;
+ var providerName = layerName.split('.')[0] ;
+ if (apikeys.hasOwnProperty(providerName) && apikeys[providerName] !== '') {
+ options.apikey = apikeys[providerName] ;
+ }
+ if (layerName === 'MapQuestOpen') {
+ layers[layerName] = new MQ.TileLayer().addTo(map);
+ } else {
+ layers[layerName] = new L.tileLayer.provider(layerName,options).addTo(map);
+ }
+ });
+
+ var overlaylayers = {};
+ $.each(options.overlaylayers, function(index, overlaylayerName) {
+ overlaylayers[overlaylayerName] = new L.tileLayer.provider(overlaylayerName).addTo(_this.map);
+ });
+
+ if (options.layers.length > 1) {
+ L.control.layers(layers, overlaylayers).addTo(map);
+ }
+
+ if (options.resizable) {
+ //TODO: Fix moving map when resized
+ _this.resizable();
+ }
+
+ if (!options.locations) {
+ options.locations = [];
+ }
+
+ // Add the markers.
+ for (var i = options.locations.length - 1; i >= 0; i--) {
+ this.addMarker(options.locations[i]);
+ }
+
+ // Add markercluster
+ if (options.markercluster) {
+ this.createMarkerCluster();
+ }
+
+ // Add lines
+ if (options.lines) {
+ for (var i = 0; i < options.lines.length; i++) {
+ this.addLine(options.lines[i]);
+ }
+ }
+
+ // Add polygons
+ if (options.polygons) {
+ for (var i = 0; i < options.polygons.length; i++) {
+ this.addPolygon(options.polygons[i]);
+ }
+ }
+
+ // Add circles
+ if (options.circles) {
+ for (var i = 0; i < options.circles.length; i++) {
+ this.addCircle(options.circles[i]);
+ }
+ }
+
+ // Add rectangles
+ if (options.rectangles) {
+ for (var i = 0; i < options.rectangles.length; i++) {
+ this.addRectangle(options.rectangles[i]);
+ }
+ }
+
+ this.addGeoJson(options);
+
+ // Set map position (centre and zoom)
+ var centre;
+ if (options.centre === false) {
+ switch ( this.points.length ) {
+ case 0:
+ centre = new L.LatLng(0, 0);
+ break;
+ case 1:
+ centre = this.points[0];
+ break;
+ default:
+ var bounds = new L.LatLngBounds( this.points );
+ if (options.zoom === false) {
+ map.fitBounds( bounds );
+ centre = false;
+ } else {
+ centre = bounds.getCenter();
+ }
+ break;
+ }
+ this.points = [];
+ } else {
+ centre = new L.LatLng(options.centre.lat, options.centre.lon);
+ }
+ if(centre) {
+ map.setView( centre, options.zoom !== false ? options.zoom : options.defzoom );
+ }
+ };
+
+ this.getDependencies = function ( options ) {
+ var dependencies = [];
+ if (options.layers !== ['MapQuestOpen'] || options.overlaylayers.length > 0) {
+ dependencies.push( 'ext.maps.leaflet.providers' );
+ }
+ if (options.enablefullscreen) {
+ dependencies.push( 'ext.maps.leaflet.fullscreen' );
+ }
+ if (options.resizable) {
+ dependencies.push( 'ext.maps.resizable' );
+ }
+ if (options.markercluster) {
+ dependencies.push( 'ext.maps.leaflet.markercluster' );
+ }
+ return dependencies;
+ };
+
+ mw.loader.using( this.getDependencies( options ) ).then( function() {
+ _this.setup();
+ } );
+
+ return this;
+
+ };
+})(jQuery, window.mediaWiki, L, window.MQ);
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet-providers/leaflet-providers.js b/www/wiki/extensions/Maps/resources/leaflet/leaflet-providers/leaflet-providers.js
new file mode 100644
index 00000000..5437f1f1
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet-providers/leaflet-providers.js
@@ -0,0 +1,774 @@
+(function (root, factory) {
+ if (typeof define === 'function' && define.amd) {
+ // AMD. Register as an anonymous module.
+ define(['leaflet'], factory);
+ } else if (typeof modules === 'object' && module.exports) {
+ // define a Common JS module that relies on 'leaflet'
+ module.exports = factory(require('leaflet'));
+ } else {
+ // Assume Leaflet is loaded into global object L already
+ factory(L);
+ }
+}(this, function (L) {
+ 'use strict';
+
+ L.TileLayer.Provider = L.TileLayer.extend({
+ initialize: function (arg, options) {
+ var providers = L.TileLayer.Provider.providers;
+
+ var parts = arg.split('.');
+
+ var providerName = parts[0];
+ var variantName = parts[1];
+
+ if (!providers[providerName]) {
+ throw 'No such provider (' + providerName + ')';
+ }
+
+ var provider = {
+ url: providers[providerName].url,
+ options: providers[providerName].options
+ };
+
+ // overwrite values in provider from variant.
+ if (variantName && 'variants' in providers[providerName]) {
+ if (!(variantName in providers[providerName].variants)) {
+ throw 'No such variant of ' + providerName + ' (' + variantName + ')';
+ }
+ var variant = providers[providerName].variants[variantName];
+ var variantOptions;
+ if (typeof variant === 'string') {
+ variantOptions = {
+ variant: variant
+ };
+ } else {
+ variantOptions = variant.options;
+ }
+ provider = {
+ url: variant.url || provider.url,
+ options: L.Util.extend({}, provider.options, variantOptions)
+ };
+ }
+
+ // replace attribution placeholders with their values from toplevel provider attribution,
+ // recursively
+ var attributionReplacer = function (attr) {
+ if (attr.indexOf('{attribution.') === -1) {
+ return attr;
+ }
+ return attr.replace(/\{attribution.(\w*)\}/,
+ function (match, attributionName) {
+ return attributionReplacer(providers[attributionName].options.attribution);
+ }
+ );
+ };
+ provider.options.attribution = attributionReplacer(provider.options.attribution);
+
+ // Compute final options combining provider options with any user overrides
+ var layerOpts = L.Util.extend({}, provider.options, options);
+ L.TileLayer.prototype.initialize.call(this, provider.url, layerOpts);
+ }
+ });
+
+ /**
+ * Definition of providers.
+ * see http://leafletjs.com/reference.html#tilelayer for options in the options map.
+ */
+
+ L.TileLayer.Provider.providers = {
+ OpenStreetMap: {
+ url: 'https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 19,
+ attribution:
+ '&copy; <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a>'
+ },
+ variants: {
+ Mapnik: {},
+ BlackAndWhite: {
+ url: 'http://{s}.tiles.wmflabs.org/bw-mapnik/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 18
+ }
+ },
+ DE: {
+ url: 'https://{s}.tile.openstreetmap.de/tiles/osmde/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 18
+ }
+ },
+ CH: {
+ url: 'https://tile.osm.ch/switzerland/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 18,
+ bounds: [[45, 5], [48, 11]]
+ }
+ },
+ France: {
+ url: 'https://{s}.tile.openstreetmap.fr/osmfr/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 20,
+ attribution: '&copy; Openstreetmap France | {attribution.OpenStreetMap}'
+ }
+ },
+ HOT: {
+ url: 'https://{s}.tile.openstreetmap.fr/hot/{z}/{x}/{y}.png',
+ options: {
+ attribution: '{attribution.OpenStreetMap}, Tiles courtesy of <a href="http://hot.openstreetmap.org/" target="_blank">Humanitarian OpenStreetMap Team</a>'
+ }
+ },
+ BZH: {
+ url: 'https://tile.openstreetmap.bzh/br/{z}/{x}/{y}.png',
+ options: {
+ attribution: '{attribution.OpenStreetMap}, Tiles courtesy of <a href="http://www.openstreetmap.bzh/" target="_blank">Breton OpenStreetMap Team</a>',
+ bounds: [[46.2, -5.5], [50, 0.7]]
+ }
+ }
+ }
+ },
+ OpenInfraMap: {
+ url: 'https://tiles-{s}.openinframap.org/{variant}/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 18,
+ attribution:
+ '{attribution.OpenStreetMap}, <a href="http://www.openinframap.org/about.html">About OpenInfraMap</a>'
+ },
+ variants: {
+ Power: 'power',
+ Telecom: 'telecoms',
+ Petroleum: 'petroleum',
+ Water: 'water'
+ }
+ },
+ OpenSeaMap: {
+ url: 'https://tiles.openseamap.org/seamark/{z}/{x}/{y}.png',
+ options: {
+ attribution: 'Map data: &copy; <a href="http://www.openseamap.org">OpenSeaMap</a> contributors'
+ }
+ },
+ OpenPtMap: {
+ url: 'http://openptmap.org/tiles/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 17,
+ attribution: 'Map data: &copy; <a href="http://www.openptmap.org">OpenPtMap</a> contributors'
+ }
+ },
+ OpenTopoMap: {
+ url: 'https://{s}.tile.opentopomap.org/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 17,
+ attribution: 'Map data: {attribution.OpenStreetMap}, <a href="http://viewfinderpanoramas.org">SRTM</a> | Map style: &copy; <a href="https://opentopomap.org">OpenTopoMap</a> (<a href="https://creativecommons.org/licenses/by-sa/3.0/">CC-BY-SA</a>)'
+ }
+ },
+ OpenRailwayMap: {
+ url: 'https://{s}.tiles.openrailwaymap.org/standard/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 19,
+ attribution: 'Map data: {attribution.OpenStreetMap} | Map style: &copy; <a href="https://www.OpenRailwayMap.org">OpenRailwayMap</a> (<a href="https://creativecommons.org/licenses/by-sa/3.0/">CC-BY-SA</a>)'
+ }
+ },
+ OpenFireMap: {
+ url: 'http://openfiremap.org/hytiles/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 19,
+ attribution: 'Map data: {attribution.OpenStreetMap} | Map style: &copy; <a href="http://www.openfiremap.org">OpenFireMap</a> (<a href="https://creativecommons.org/licenses/by-sa/3.0/">CC-BY-SA</a>)'
+ }
+ },
+ SafeCast: {
+ url: 'https://s3.amazonaws.com/te512.safecast.org/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 16,
+ attribution: 'Map data: {attribution.OpenStreetMap} | Map style: &copy; <a href="https://blog.safecast.org/about/">SafeCast</a> (<a href="https://creativecommons.org/licenses/by-sa/3.0/">CC-BY-SA</a>)'
+ }
+ },
+ Thunderforest: {
+ url: 'https://{s}.tile.thunderforest.com/{variant}/{z}/{x}/{y}.png?apikey={apikey}',
+ options: {
+ attribution:
+ '&copy; <a href="http://www.thunderforest.com/">Thunderforest</a>, {attribution.OpenStreetMap}',
+ variant: 'cycle',
+ apikey: '<insert your api key here>',
+ maxZoom: 22
+ },
+ variants: {
+ OpenCycleMap: 'cycle',
+ Transport: {
+ options: {
+ variant: 'transport'
+ }
+ },
+ TransportDark: {
+ options: {
+ variant: 'transport-dark'
+ }
+ },
+ SpinalMap: {
+ options: {
+ variant: 'spinal-map'
+ }
+ },
+ Landscape: 'landscape',
+ Outdoors: 'outdoors',
+ Pioneer: 'pioneer'
+ }
+ },
+ OpenMapSurfer: {
+ url: 'https://korona.geog.uni-heidelberg.de/tiles/{variant}/x={x}&y={y}&z={z}',
+ options: {
+ maxZoom: 20,
+ variant: 'roads',
+ attribution: 'Imagery from <a href="http://giscience.uni-hd.de/">GIScience Research Group @ University of Heidelberg</a> &mdash; Map data {attribution.OpenStreetMap}'
+ },
+ variants: {
+ Roads: 'roads',
+ AdminBounds: {
+ options: {
+ variant: 'adminb',
+ maxZoom: 19
+ }
+ },
+ Grayscale: {
+ options: {
+ variant: 'roadsg',
+ maxZoom: 19
+ }
+ }
+ }
+ },
+ Hydda: {
+ url: 'https://{s}.tile.openstreetmap.se/hydda/{variant}/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 18,
+ variant: 'full',
+ attribution: 'Tiles courtesy of <a href="http://openstreetmap.se/" target="_blank">OpenStreetMap Sweden</a> &mdash; Map data {attribution.OpenStreetMap}'
+ },
+ variants: {
+ Full: 'full',
+ Base: 'base',
+ RoadsAndLabels: 'roads_and_labels'
+ }
+ },
+ MapBox: {
+ url: 'https://api.tiles.mapbox.com/v4/{id}/{z}/{x}/{y}{r}.png?access_token={accessToken}',
+ options: {
+ attribution:
+ 'Imagery from <a href="http://mapbox.com/about/maps/">MapBox</a> &mdash; ' +
+ 'Map data {attribution.OpenStreetMap}',
+ subdomains: 'abcd',
+ id: 'streets',
+ accessToken: '<insert your access token here>',
+ }
+ },
+ Stamen: {
+ url: 'https://stamen-tiles-{s}.a.ssl.fastly.net/{variant}/{z}/{x}/{y}{r}.{ext}',
+ options: {
+ attribution:
+ 'Map tiles by <a href="http://stamen.com">Stamen Design</a>, ' +
+ '<a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a> &mdash; ' +
+ 'Map data {attribution.OpenStreetMap}',
+ subdomains: 'abcd',
+ minZoom: 0,
+ maxZoom: 20,
+ variant: 'toner',
+ ext: 'png'
+ },
+ variants: {
+ Toner: 'toner',
+ TonerBackground: 'toner-background',
+ TonerHybrid: 'toner-hybrid',
+ TonerLines: 'toner-lines',
+ TonerLabels: 'toner-labels',
+ TonerLite: 'toner-lite',
+ Watercolor: {
+ url: 'https://stamen-tiles-{s}.a.ssl.fastly.net/{variant}/{z}/{x}/{y}.{ext}',
+ options: {
+ variant: 'watercolor',
+ minZoom: 1,
+ maxZoom: 16
+ }
+ },
+ Terrain: {
+ options: {
+ variant: 'terrain',
+ minZoom: 0,
+ maxZoom: 18
+ }
+ },
+ TerrainBackground: {
+ options: {
+ variant: 'terrain-background',
+ minZoom: 0,
+ maxZoom: 18
+ }
+ },
+ TopOSMRelief: {
+ url: 'https://stamen-tiles-{s}.a.ssl.fastly.net/{variant}/{z}/{x}/{y}.{ext}',
+ options: {
+ variant: 'toposm-color-relief',
+ ext: 'jpg',
+ bounds: [[22, -132], [51, -56]]
+ }
+ },
+ TopOSMFeatures: {
+ options: {
+ variant: 'toposm-features',
+ bounds: [[22, -132], [51, -56]],
+ opacity: 0.9
+ }
+ }
+ }
+ },
+ Esri: {
+ url: 'https://server.arcgisonline.com/ArcGIS/rest/services/{variant}/MapServer/tile/{z}/{y}/{x}',
+ options: {
+ variant: 'World_Street_Map',
+ attribution: 'Tiles &copy; Esri'
+ },
+ variants: {
+ WorldStreetMap: {
+ options: {
+ attribution:
+ '{attribution.Esri} &mdash; ' +
+ 'Source: Esri, DeLorme, NAVTEQ, USGS, Intermap, iPC, NRCAN, Esri Japan, METI, Esri China (Hong Kong), Esri (Thailand), TomTom, 2012'
+ }
+ },
+ DeLorme: {
+ options: {
+ variant: 'Specialty/DeLorme_World_Base_Map',
+ minZoom: 1,
+ maxZoom: 11,
+ attribution: '{attribution.Esri} &mdash; Copyright: &copy;2012 DeLorme'
+ }
+ },
+ WorldTopoMap: {
+ options: {
+ variant: 'World_Topo_Map',
+ attribution:
+ '{attribution.Esri} &mdash; ' +
+ 'Esri, DeLorme, NAVTEQ, TomTom, Intermap, iPC, USGS, FAO, NPS, NRCAN, GeoBase, Kadaster NL, Ordnance Survey, Esri Japan, METI, Esri China (Hong Kong), and the GIS User Community'
+ }
+ },
+ WorldImagery: {
+ options: {
+ variant: 'World_Imagery',
+ attribution:
+ '{attribution.Esri} &mdash; ' +
+ 'Source: Esri, i-cubed, USDA, USGS, AEX, GeoEye, Getmapping, Aerogrid, IGN, IGP, UPR-EGP, and the GIS User Community'
+ }
+ },
+ WorldTerrain: {
+ options: {
+ variant: 'World_Terrain_Base',
+ maxZoom: 13,
+ attribution:
+ '{attribution.Esri} &mdash; ' +
+ 'Source: USGS, Esri, TANA, DeLorme, and NPS'
+ }
+ },
+ WorldShadedRelief: {
+ options: {
+ variant: 'World_Shaded_Relief',
+ maxZoom: 13,
+ attribution: '{attribution.Esri} &mdash; Source: Esri'
+ }
+ },
+ WorldPhysical: {
+ options: {
+ variant: 'World_Physical_Map',
+ maxZoom: 8,
+ attribution: '{attribution.Esri} &mdash; Source: US National Park Service'
+ }
+ },
+ OceanBasemap: {
+ options: {
+ variant: 'Ocean_Basemap',
+ maxZoom: 13,
+ attribution: '{attribution.Esri} &mdash; Sources: GEBCO, NOAA, CHS, OSU, UNH, CSUMB, National Geographic, DeLorme, NAVTEQ, and Esri'
+ }
+ },
+ NatGeoWorldMap: {
+ options: {
+ variant: 'NatGeo_World_Map',
+ maxZoom: 16,
+ attribution: '{attribution.Esri} &mdash; National Geographic, Esri, DeLorme, NAVTEQ, UNEP-WCMC, USGS, NASA, ESA, METI, NRCAN, GEBCO, NOAA, iPC'
+ }
+ },
+ WorldGrayCanvas: {
+ options: {
+ variant: 'Canvas/World_Light_Gray_Base',
+ maxZoom: 16,
+ attribution: '{attribution.Esri} &mdash; Esri, DeLorme, NAVTEQ'
+ }
+ }
+ }
+ },
+ OpenWeatherMap: {
+ url: 'http://{s}.tile.openweathermap.org/map/{variant}/{z}/{x}/{y}.png?appid={apiKey}',
+ options: {
+ maxZoom: 19,
+ attribution: 'Map data &copy; <a href="http://openweathermap.org">OpenWeatherMap</a>',
+ apiKey:'<insert your api key here>',
+ opacity: 0.5
+ },
+ variants: {
+ Clouds: 'clouds',
+ CloudsClassic: 'clouds_cls',
+ Precipitation: 'precipitation',
+ PrecipitationClassic: 'precipitation_cls',
+ Rain: 'rain',
+ RainClassic: 'rain_cls',
+ Pressure: 'pressure',
+ PressureContour: 'pressure_cntr',
+ Wind: 'wind',
+ Temperature: 'temp',
+ Snow: 'snow'
+ }
+ },
+ HERE: {
+ /*
+ * HERE maps, formerly Nokia maps.
+ * These basemaps are free, but you need an API key. Please sign up at
+ * http://developer.here.com/getting-started
+ *
+ * Note that the base urls contain '.cit' whichs is HERE's
+ * 'Customer Integration Testing' environment. Please remove for production
+ * envirionments.
+ */
+ url:
+ 'https://{s}.{base}.maps.cit.api.here.com/maptile/2.1/' +
+ '{type}/{mapID}/{variant}/{z}/{x}/{y}/{size}/{format}?' +
+ 'app_id={app_id}&app_code={app_code}&lg={language}',
+ options: {
+ attribution:
+ 'Map &copy; 1987-2014 <a href="http://developer.here.com">HERE</a>',
+ subdomains: '1234',
+ mapID: 'newest',
+ 'app_id': '<insert your app_id here>',
+ 'app_code': '<insert your app_code here>',
+ base: 'base',
+ variant: 'normal.day',
+ maxZoom: 20,
+ type: 'maptile',
+ language: 'eng',
+ format: 'png8',
+ size: '256'
+ },
+ variants: {
+ normalDay: 'normal.day',
+ normalDayCustom: 'normal.day.custom',
+ normalDayGrey: 'normal.day.grey',
+ normalDayMobile: 'normal.day.mobile',
+ normalDayGreyMobile: 'normal.day.grey.mobile',
+ normalDayTransit: 'normal.day.transit',
+ normalDayTransitMobile: 'normal.day.transit.mobile',
+ normalNight: 'normal.night',
+ normalNightMobile: 'normal.night.mobile',
+ normalNightGrey: 'normal.night.grey',
+ normalNightGreyMobile: 'normal.night.grey.mobile',
+
+ basicMap: {
+ options: {
+ type: 'basetile'
+ }
+ },
+ mapLabels: {
+ options: {
+ type: 'labeltile',
+ format: 'png'
+ }
+ },
+ trafficFlow: {
+ options: {
+ base: 'traffic',
+ type: 'flowtile'
+ }
+ },
+ carnavDayGrey: 'carnav.day.grey',
+ hybridDay: {
+ options: {
+ base: 'aerial',
+ variant: 'hybrid.day'
+ }
+ },
+ hybridDayMobile: {
+ options: {
+ base: 'aerial',
+ variant: 'hybrid.day.mobile'
+ }
+ },
+ pedestrianDay: 'pedestrian.day',
+ pedestrianNight: 'pedestrian.night',
+ satelliteDay: {
+ options: {
+ base: 'aerial',
+ variant: 'satellite.day'
+ }
+ },
+ terrainDay: {
+ options: {
+ base: 'aerial',
+ variant: 'terrain.day'
+ }
+ },
+ terrainDayMobile: {
+ options: {
+ base: 'aerial',
+ variant: 'terrain.day.mobile'
+ }
+ }
+ }
+ },
+ FreeMapSK: {
+ url: 'http://t{s}.freemap.sk/T/{z}/{x}/{y}.jpeg',
+ options: {
+ minZoom: 8,
+ maxZoom: 16,
+ subdomains: '1234',
+ bounds: [[47.204642, 15.996093], [49.830896, 22.576904]],
+ attribution:
+ '{attribution.OpenStreetMap}, vizualization CC-By-SA 2.0 <a href="http://freemap.sk">Freemap.sk</a>'
+ }
+ },
+ MtbMap: {
+ url: 'http://tile.mtbmap.cz/mtbmap_tiles/{z}/{x}/{y}.png',
+ options: {
+ attribution:
+ '{attribution.OpenStreetMap} &amp; USGS'
+ }
+ },
+ CartoDB: {
+ url: 'https://cartodb-basemaps-{s}.global.ssl.fastly.net/{variant}/{z}/{x}/{y}{r}.png',
+ options: {
+ attribution: '{attribution.OpenStreetMap} &copy; <a href="http://cartodb.com/attributions">CartoDB</a>',
+ subdomains: 'abcd',
+ maxZoom: 19,
+ variant: 'light_all'
+ },
+ variants: {
+ Positron: 'light_all',
+ PositronNoLabels: 'light_nolabels',
+ PositronOnlyLabels: 'light_only_labels',
+ DarkMatter: 'dark_all',
+ DarkMatterNoLabels: 'dark_nolabels',
+ DarkMatterOnlyLabels: 'dark_only_labels',
+ Voyager: 'rastertiles/voyager',
+ VoyagerNoLabels: 'rastertiles/voyager_nolabels',
+ VoyagerOnlyLabels: 'rastertiles/voyager_only_labels',
+ VoyagerLabelsUnder: 'rastertiles/voyager_labels_under'
+ }
+ },
+ HikeBike: {
+ url: 'http://{s}.tiles.wmflabs.org/{variant}/{z}/{x}/{y}.png',
+ options: {
+ maxZoom: 19,
+ attribution: '{attribution.OpenStreetMap}',
+ variant: 'hikebike'
+ },
+ variants: {
+ HikeBike: {},
+ HillShading: {
+ options: {
+ maxZoom: 15,
+ variant: 'hillshading'
+ }
+ }
+ }
+ },
+ BasemapAT: {
+ url: 'https://maps{s}.wien.gv.at/basemap/{variant}/normal/google3857/{z}/{y}/{x}.{format}',
+ options: {
+ maxZoom: 19,
+ attribution: 'Datenquelle: <a href="https://www.basemap.at">basemap.at</a>',
+ subdomains: ['', '1', '2', '3', '4'],
+ format: 'png',
+ bounds: [[46.358770, 8.782379], [49.037872, 17.189532]],
+ variant: 'geolandbasemap'
+ },
+ variants: {
+ basemap: {
+ options: {
+ maxZoom: 20, // currently only in Vienna
+ variant: 'geolandbasemap'
+ }
+ },
+ grau: 'bmapgrau',
+ overlay: 'bmapoverlay',
+ highdpi: {
+ options: {
+ variant: 'bmaphidpi',
+ format: 'jpeg'
+ }
+ },
+ orthofoto: {
+ options: {
+ maxZoom: 20, // currently only in Vienna
+ variant: 'bmaporthofoto30cm',
+ format: 'jpeg'
+ }
+ }
+ }
+ },
+ nlmaps: {
+ url: 'https://geodata.nationaalgeoregister.nl/tiles/service/wmts/{variant}/EPSG:3857/{z}/{x}/{y}.png',
+ options: {
+ minZoom: 6,
+ maxZoom: 19,
+ bounds: [[50.5, 3.25], [54, 7.6]],
+ attribution: 'Kaartgegevens &copy; <a href="kadaster.nl">Kadaster</a>'
+ },
+ variants: {
+ 'standaard': 'brtachtergrondkaart',
+ 'pastel': 'brtachtergrondkaartpastel',
+ 'grijs': 'brtachtergrondkaartgrijs',
+ 'luchtfoto': {
+ 'url': 'https://geodata.nationaalgeoregister.nl/luchtfoto/rgb/wmts/1.0.0/2016_ortho25/EPSG:3857/{z}/{x}/{y}.png',
+ }
+ }
+ },
+ NASAGIBS: {
+ url: 'https://map1.vis.earthdata.nasa.gov/wmts-webmerc/{variant}/default/{time}/{tilematrixset}{maxZoom}/{z}/{y}/{x}.{format}',
+ options: {
+ attribution:
+ 'Imagery provided by services from the Global Imagery Browse Services (GIBS), operated by the NASA/GSFC/Earth Science Data and Information System ' +
+ '(<a href="https://earthdata.nasa.gov">ESDIS</a>) with funding provided by NASA/HQ.',
+ bounds: [[-85.0511287776, -179.999999975], [85.0511287776, 179.999999975]],
+ minZoom: 1,
+ maxZoom: 9,
+ format: 'jpg',
+ time: '',
+ tilematrixset: 'GoogleMapsCompatible_Level'
+ },
+ variants: {
+ ModisTerraTrueColorCR: 'MODIS_Terra_CorrectedReflectance_TrueColor',
+ ModisTerraBands367CR: 'MODIS_Terra_CorrectedReflectance_Bands367',
+ ViirsEarthAtNight2012: {
+ options: {
+ variant: 'VIIRS_CityLights_2012',
+ maxZoom: 8
+ }
+ },
+ ModisTerraLSTDay: {
+ options: {
+ variant: 'MODIS_Terra_Land_Surface_Temp_Day',
+ format: 'png',
+ maxZoom: 7,
+ opacity: 0.75
+ }
+ },
+ ModisTerraSnowCover: {
+ options: {
+ variant: 'MODIS_Terra_Snow_Cover',
+ format: 'png',
+ maxZoom: 8,
+ opacity: 0.75
+ }
+ },
+ ModisTerraAOD: {
+ options: {
+ variant: 'MODIS_Terra_Aerosol',
+ format: 'png',
+ maxZoom: 6,
+ opacity: 0.75
+ }
+ },
+ ModisTerraChlorophyll: {
+ options: {
+ variant: 'MODIS_Terra_Chlorophyll_A',
+ format: 'png',
+ maxZoom: 7,
+ opacity: 0.75
+ }
+ }
+ }
+ },
+ NLS: {
+ // NLS maps are copyright National library of Scotland.
+ // http://maps.nls.uk/projects/api/index.html
+ // Please contact NLS for anything other than non-commercial low volume usage
+ //
+ // Map sources: Ordnance Survey 1:1m to 1:63K, 1920s-1940s
+ // z0-9 - 1:1m
+ // z10-11 - quarter inch (1:253440)
+ // z12-18 - one inch (1:63360)
+ url: 'https://nls-{s}.tileserver.com/nls/{z}/{x}/{y}.jpg',
+ options: {
+ attribution: '<a href="http://geo.nls.uk/maps/">National Library of Scotland Historic Maps</a>',
+ bounds: [[49.6, -12], [61.7, 3]],
+ minZoom: 1,
+ maxZoom: 18,
+ subdomains: '0123',
+ }
+ },
+ JusticeMap: {
+ // Justice Map (http://www.justicemap.org/)
+ // Visualize race and income data for your community, county and country.
+ // Includes tools for data journalists, bloggers and community activists.
+ url: 'http://www.justicemap.org/tile/{size}/{variant}/{z}/{x}/{y}.png',
+ options: {
+ attribution: '<a href="http://www.justicemap.org/terms.php">Justice Map</a>',
+ // one of 'county', 'tract', 'block'
+ size: 'county',
+ // Bounds for USA, including Alaska and Hawaii
+ bounds: [[14, -180], [72, -56]]
+ },
+ variants: {
+ income: 'income',
+ americanIndian: 'indian',
+ asian: 'asian',
+ black: 'black',
+ hispanic: 'hispanic',
+ multi: 'multi',
+ nonWhite: 'nonwhite',
+ white: 'white',
+ plurality: 'plural'
+ }
+ },
+ Wikimedia: {
+ url: 'https://maps.wikimedia.org/osm-intl/{z}/{x}/{y}{r}.png',
+ options: {
+ attribution: '<a href="https://wikimediafoundation.org/wiki/Maps_Terms_of_Use">Wikimedia</a>',
+ minZoom: 1,
+ maxZoom: 19
+ }
+ },
+ GeoportailFrance: {
+ url: 'https://wxs.ign.fr/{apikey}/geoportail/wmts?REQUEST=GetTile&SERVICE=WMTS&VERSION=1.0.0&STYLE={style}&TILEMATRIXSET=PM&FORMAT={format}&LAYER={variant}&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}',
+ options: {
+ attribution: '<a target="_blank" href="https://www.geoportail.gouv.fr/">Geoportail France</a>',
+ bounds: [[-75, -180], [81, 180]],
+ minZoom: 2,
+ maxZoom: 18,
+ // Get your own geoportail apikey here : http://professionnels.ign.fr/ign/contrats/
+ // NB : 'choisirgeoportail' is a demonstration key that comes with no guarantee
+ apikey: 'choisirgeoportail',
+ format: 'image/jpeg',
+ style : 'normal',
+ variant: 'GEOGRAPHICALGRIDSYSTEMS.MAPS.SCAN-EXPRESS.STANDARD'
+ },
+ variants: {
+ parcels: {
+ options : {
+ variant: 'CADASTRALPARCELS.PARCELS',
+ maxZoom: 20,
+ style : 'bdparcellaire',
+ format: 'image/png'
+ }
+ },
+ ignMaps: 'GEOGRAPHICALGRIDSYSTEMS.MAPS',
+ maps: 'GEOGRAPHICALGRIDSYSTEMS.MAPS.SCAN-EXPRESS.STANDARD',
+ orthos: {
+ options: {
+ maxZoom: 19,
+ variant: 'ORTHOIMAGERY.ORTHOPHOTOS'
+ }
+ }
+ }
+ }
+ };
+
+ L.tileLayer.provider = function (provider, options) {
+ return new L.TileLayer.Provider(provider, options);
+ };
+
+ return L;
+}));
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.editable/Leaflet.Editable.js b/www/wiki/extensions/Maps/resources/leaflet/leaflet.editable/Leaflet.Editable.js
new file mode 100644
index 00000000..e259a14c
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.editable/Leaflet.Editable.js
@@ -0,0 +1,1945 @@
+'use strict';
+(function (factory, window) {// 1.2 alpha
+ /*globals define, module, require*/
+
+ // define an AMD module that relies on 'leaflet'
+ if (typeof define === 'function' && define.amd) {
+ define(['leaflet'], factory);
+
+
+ // define a Common JS module that relies on 'leaflet'
+ } else if (typeof exports === 'object') {
+ module.exports = factory(require('leaflet'));
+ }
+
+ // attach your plugin to the global 'L' variable
+ if(typeof window !== 'undefined' && window.L){
+ factory(window.L);
+ }
+
+}(function (L) {
+ // 🍂miniclass CancelableEvent (Event objects)
+ // 🍂method cancel()
+ // Cancel any subsequent action.
+
+ // 🍂miniclass VertexEvent (Event objects)
+ // 🍂property vertex: VertexMarker
+ // The vertex that fires the event.
+
+ // 🍂miniclass ShapeEvent (Event objects)
+ // 🍂property shape: Array
+ // The shape (LatLngs array) subject of the action.
+
+ // 🍂miniclass CancelableVertexEvent (Event objects)
+ // 🍂inherits VertexEvent
+ // 🍂inherits CancelableEvent
+
+ // 🍂miniclass CancelableShapeEvent (Event objects)
+ // 🍂inherits ShapeEvent
+ // 🍂inherits CancelableEvent
+
+ // 🍂miniclass LayerEvent (Event objects)
+ // 🍂property layer: object
+ // The Layer (Marker, Polyline…) subject of the action.
+
+ // 🍂namespace Editable; 🍂class Editable; 🍂aka L.Editable
+ // Main edition handler. By default, it is attached to the map
+ // as `map.editTools` property.
+ // Leaflet.Editable is made to be fully extendable. You have three ways to customize
+ // the behaviour: using options, listening to events, or extending.
+ L.Editable = L.Evented.extend({
+
+ statics: {
+ FORWARD: 1,
+ BACKWARD: -1
+ },
+
+ options: {
+
+ // You can pass them when creating a map using the `editOptions` key.
+ // 🍂option zIndex: int = 1000
+ // The default zIndex of the editing tools.
+ zIndex: 1000,
+
+ // 🍂option polygonClass: class = L.Polygon
+ // Class to be used when creating a new Polygon.
+ polygonClass: L.Polygon,
+
+ // 🍂option polylineClass: class = L.Polyline
+ // Class to be used when creating a new Polyline.
+ polylineClass: L.Polyline,
+
+ // 🍂option markerClass: class = L.Marker
+ // Class to be used when creating a new Marker.
+ markerClass: L.Marker,
+
+ // 🍂option rectangleClass: class = L.Rectangle
+ // Class to be used when creating a new Rectangle.
+ rectangleClass: L.Rectangle,
+
+ // 🍂option circleClass: class = L.Circle
+ // Class to be used when creating a new Circle.
+ circleClass: L.Circle,
+
+ // 🍂option drawingCSSClass: string = 'leaflet-editable-drawing'
+ // CSS class to be added to the map container while drawing.
+ drawingCSSClass: 'leaflet-editable-drawing',
+
+ // 🍂option drawingCursor: const = 'crosshair'
+ // Cursor mode set to the map while drawing.
+ drawingCursor: 'crosshair',
+
+ // 🍂option editLayer: Layer = new L.LayerGroup()
+ // Layer used to store edit tools (vertex, line guide…).
+ editLayer: undefined,
+
+ // 🍂option featuresLayer: Layer = new L.LayerGroup()
+ // Default layer used to store drawn features (Marker, Polyline…).
+ featuresLayer: undefined,
+
+ // 🍂option polylineEditorClass: class = PolylineEditor
+ // Class to be used as Polyline editor.
+ polylineEditorClass: undefined,
+
+ // 🍂option polygonEditorClass: class = PolygonEditor
+ // Class to be used as Polygon editor.
+ polygonEditorClass: undefined,
+
+ // 🍂option markerEditorClass: class = MarkerEditor
+ // Class to be used as Marker editor.
+ markerEditorClass: undefined,
+
+ // 🍂option rectangleEditorClass: class = RectangleEditor
+ // Class to be used as Rectangle editor.
+ rectangleEditorClass: undefined,
+
+ // 🍂option circleEditorClass: class = CircleEditor
+ // Class to be used as Circle editor.
+ circleEditorClass: undefined,
+
+ // 🍂option lineGuideOptions: hash = {}
+ // Options to be passed to the line guides.
+ lineGuideOptions: {},
+
+ // 🍂option skipMiddleMarkers: boolean = false
+ // Set this to true if you don't want middle markers.
+ skipMiddleMarkers: false
+
+ },
+
+ initialize: function (map, options) {
+ L.setOptions(this, options);
+ this._lastZIndex = this.options.zIndex;
+ this.map = map;
+ this.editLayer = this.createEditLayer();
+ this.featuresLayer = this.createFeaturesLayer();
+ this.forwardLineGuide = this.createLineGuide();
+ this.backwardLineGuide = this.createLineGuide();
+ },
+
+ fireAndForward: function (type, e) {
+ e = e || {};
+ e.editTools = this;
+ this.fire(type, e);
+ this.map.fire(type, e);
+ },
+
+ createLineGuide: function () {
+ var options = L.extend({dashArray: '5,10', weight: 1, interactive: false}, this.options.lineGuideOptions);
+ return L.polyline([], options);
+ },
+
+ createVertexIcon: function (options) {
+ return L.Browser.mobile && L.Browser.touch ? new L.Editable.TouchVertexIcon(options) : new L.Editable.VertexIcon(options);
+ },
+
+ createEditLayer: function () {
+ return this.options.editLayer || new L.LayerGroup().addTo(this.map);
+ },
+
+ createFeaturesLayer: function () {
+ return this.options.featuresLayer || new L.LayerGroup().addTo(this.map);
+ },
+
+ moveForwardLineGuide: function (latlng) {
+ if (this.forwardLineGuide._latlngs.length) {
+ this.forwardLineGuide._latlngs[1] = latlng;
+ this.forwardLineGuide._bounds.extend(latlng);
+ this.forwardLineGuide.redraw();
+ }
+ },
+
+ moveBackwardLineGuide: function (latlng) {
+ if (this.backwardLineGuide._latlngs.length) {
+ this.backwardLineGuide._latlngs[1] = latlng;
+ this.backwardLineGuide._bounds.extend(latlng);
+ this.backwardLineGuide.redraw();
+ }
+ },
+
+ anchorForwardLineGuide: function (latlng) {
+ this.forwardLineGuide._latlngs[0] = latlng;
+ this.forwardLineGuide._bounds.extend(latlng);
+ this.forwardLineGuide.redraw();
+ },
+
+ anchorBackwardLineGuide: function (latlng) {
+ this.backwardLineGuide._latlngs[0] = latlng;
+ this.backwardLineGuide._bounds.extend(latlng);
+ this.backwardLineGuide.redraw();
+ },
+
+ attachForwardLineGuide: function () {
+ this.editLayer.addLayer(this.forwardLineGuide);
+ },
+
+ attachBackwardLineGuide: function () {
+ this.editLayer.addLayer(this.backwardLineGuide);
+ },
+
+ detachForwardLineGuide: function () {
+ this.forwardLineGuide.setLatLngs([]);
+ this.editLayer.removeLayer(this.forwardLineGuide);
+ },
+
+ detachBackwardLineGuide: function () {
+ this.backwardLineGuide.setLatLngs([]);
+ this.editLayer.removeLayer(this.backwardLineGuide);
+ },
+
+ blockEvents: function () {
+ // Hack: force map not to listen to other layers events while drawing.
+ if (!this._oldTargets) {
+ this._oldTargets = this.map._targets;
+ this.map._targets = {};
+ }
+ },
+
+ unblockEvents: function () {
+ if (this._oldTargets) {
+ // Reset, but keep targets created while drawing.
+ this.map._targets = L.extend(this.map._targets, this._oldTargets);
+ delete this._oldTargets;
+ }
+ },
+
+ registerForDrawing: function (editor) {
+ if (this._drawingEditor) this.unregisterForDrawing(this._drawingEditor);
+ this.blockEvents();
+ editor.reset(); // Make sure editor tools still receive events.
+ this._drawingEditor = editor;
+ this.map.on('mousemove touchmove', editor.onDrawingMouseMove, editor);
+ this.map.on('mousedown', this.onMousedown, this);
+ this.map.on('mouseup', this.onMouseup, this);
+ L.DomUtil.addClass(this.map._container, this.options.drawingCSSClass);
+ this.defaultMapCursor = this.map._container.style.cursor;
+ this.map._container.style.cursor = this.options.drawingCursor;
+ },
+
+ unregisterForDrawing: function (editor) {
+ this.unblockEvents();
+ L.DomUtil.removeClass(this.map._container, this.options.drawingCSSClass);
+ this.map._container.style.cursor = this.defaultMapCursor;
+ editor = editor || this._drawingEditor;
+ if (!editor) return;
+ this.map.off('mousemove touchmove', editor.onDrawingMouseMove, editor);
+ this.map.off('mousedown', this.onMousedown, this);
+ this.map.off('mouseup', this.onMouseup, this);
+ if (editor !== this._drawingEditor) return;
+ delete this._drawingEditor;
+ if (editor._drawing) editor.cancelDrawing();
+ },
+
+ onMousedown: function (e) {
+ this._mouseDown = e;
+ this._drawingEditor.onDrawingMouseDown(e);
+ },
+
+ onMouseup: function (e) {
+ if (this._mouseDown) {
+ var editor = this._drawingEditor,
+ mouseDown = this._mouseDown;
+ this._mouseDown = null;
+ editor.onDrawingMouseUp(e);
+ if (this._drawingEditor !== editor) return; // onDrawingMouseUp may call unregisterFromDrawing.
+ var origin = L.point(mouseDown.originalEvent.clientX, mouseDown.originalEvent.clientY);
+ var distance = L.point(e.originalEvent.clientX, e.originalEvent.clientY).distanceTo(origin);
+ if (Math.abs(distance) < 9 * (window.devicePixelRatio || 1)) this._drawingEditor.onDrawingClick(e);
+ }
+ },
+
+ // 🍂section Public methods
+ // You will generally access them by the `map.editTools`
+ // instance:
+ //
+ // `map.editTools.startPolyline();`
+
+ // 🍂method drawing(): boolean
+ // Return true if any drawing action is ongoing.
+ drawing: function () {
+ return this._drawingEditor && this._drawingEditor.drawing();
+ },
+
+ // 🍂method stopDrawing()
+ // When you need to stop any ongoing drawing, without needing to know which editor is active.
+ stopDrawing: function () {
+ this.unregisterForDrawing();
+ },
+
+ // 🍂method commitDrawing()
+ // When you need to commit any ongoing drawing, without needing to know which editor is active.
+ commitDrawing: function (e) {
+ if (!this._drawingEditor) return;
+ this._drawingEditor.commitDrawing(e);
+ },
+
+ connectCreatedToMap: function (layer) {
+ return this.featuresLayer.addLayer(layer);
+ },
+
+ // 🍂method startPolyline(latlng: L.LatLng, options: hash): L.Polyline
+ // Start drawing a Polyline. If `latlng` is given, a first point will be added. In any case, continuing on user click.
+ // If `options` is given, it will be passed to the Polyline class constructor.
+ startPolyline: function (latlng, options) {
+ var line = this.createPolyline([], options);
+ line.enableEdit(this.map).newShape(latlng);
+ return line;
+ },
+
+ // 🍂method startPolygon(latlng: L.LatLng, options: hash): L.Polygon
+ // Start drawing a Polygon. If `latlng` is given, a first point will be added. In any case, continuing on user click.
+ // If `options` is given, it will be passed to the Polygon class constructor.
+ startPolygon: function (latlng, options) {
+ var polygon = this.createPolygon([], options);
+ polygon.enableEdit(this.map).newShape(latlng);
+ return polygon;
+ },
+
+ // 🍂method startMarker(latlng: L.LatLng, options: hash): L.Marker
+ // Start adding a Marker. If `latlng` is given, the Marker will be shown first at this point.
+ // In any case, it will follow the user mouse, and will have a final `latlng` on next click (or touch).
+ // If `options` is given, it will be passed to the Marker class constructor.
+ startMarker: function (latlng, options) {
+ latlng = latlng || this.map.getCenter().clone();
+ var marker = this.createMarker(latlng, options);
+ marker.enableEdit(this.map).startDrawing();
+ return marker;
+ },
+
+ // 🍂method startRectangle(latlng: L.LatLng, options: hash): L.Rectangle
+ // Start drawing a Rectangle. If `latlng` is given, the Rectangle anchor will be added. In any case, continuing on user drag.
+ // If `options` is given, it will be passed to the Rectangle class constructor.
+ startRectangle: function(latlng, options) {
+ var corner = latlng || L.latLng([0, 0]);
+ var bounds = new L.LatLngBounds(corner, corner);
+ var rectangle = this.createRectangle(bounds, options);
+ rectangle.enableEdit(this.map).startDrawing();
+ return rectangle;
+ },
+
+ // 🍂method startCircle(latlng: L.LatLng, options: hash): L.Circle
+ // Start drawing a Circle. If `latlng` is given, the Circle anchor will be added. In any case, continuing on user drag.
+ // If `options` is given, it will be passed to the Circle class constructor.
+ startCircle: function (latlng, options) {
+ latlng = latlng || this.map.getCenter().clone();
+ var circle = this.createCircle(latlng, options);
+ circle.enableEdit(this.map).startDrawing();
+ return circle;
+ },
+
+ startHole: function (editor, latlng) {
+ editor.newHole(latlng);
+ },
+
+ createLayer: function (klass, latlngs, options) {
+ options = L.Util.extend({editOptions: {editTools: this}}, options);
+ var layer = new klass(latlngs, options);
+ // 🍂namespace Editable
+ // 🍂event editable:created: LayerEvent
+ // Fired when a new feature (Marker, Polyline…) is created.
+ this.fireAndForward('editable:created', {layer: layer});
+ return layer;
+ },
+
+ createPolyline: function (latlngs, options) {
+ return this.createLayer(options && options.polylineClass || this.options.polylineClass, latlngs, options);
+ },
+
+ createPolygon: function (latlngs, options) {
+ return this.createLayer(options && options.polygonClass || this.options.polygonClass, latlngs, options);
+ },
+
+ createMarker: function (latlng, options) {
+ return this.createLayer(options && options.markerClass || this.options.markerClass, latlng, options);
+ },
+
+ createRectangle: function (bounds, options) {
+ return this.createLayer(options && options.rectangleClass || this.options.rectangleClass, bounds, options);
+ },
+
+ createCircle: function (latlng, options) {
+ return this.createLayer(options && options.circleClass || this.options.circleClass, latlng, options);
+ }
+
+ });
+
+ L.extend(L.Editable, {
+
+ makeCancellable: function (e) {
+ e.cancel = function () {
+ e._cancelled = true;
+ };
+ }
+
+ });
+
+ // 🍂namespace Map; 🍂class Map
+ // Leaflet.Editable add options and events to the `L.Map` object.
+ // See `Editable` events for the list of events fired on the Map.
+ // 🍂example
+ //
+ // ```js
+ // var map = L.map('map', {
+ // editable: true,
+ // editOptions: {
+ // …
+ // }
+ // });
+ // ```
+ // 🍂section Editable Map Options
+ L.Map.mergeOptions({
+
+ // 🍂namespace Map
+ // 🍂section Map Options
+ // 🍂option editToolsClass: class = L.Editable
+ // Class to be used as vertex, for path editing.
+ editToolsClass: L.Editable,
+
+ // 🍂option editable: boolean = false
+ // Whether to create a L.Editable instance at map init.
+ editable: false,
+
+ // 🍂option editOptions: hash = {}
+ // Options to pass to L.Editable when instantiating.
+ editOptions: {}
+
+ });
+
+ L.Map.addInitHook(function () {
+
+ this.whenReady(function () {
+ if (this.options.editable) {
+ this.editTools = new this.options.editToolsClass(this, this.options.editOptions);
+ }
+ });
+
+ });
+
+ L.Editable.VertexIcon = L.DivIcon.extend({
+
+ options: {
+ iconSize: new L.Point(8, 8)
+ }
+
+ });
+
+ L.Editable.TouchVertexIcon = L.Editable.VertexIcon.extend({
+
+ options: {
+ iconSize: new L.Point(20, 20)
+ }
+
+ });
+
+
+ // 🍂namespace Editable; 🍂class VertexMarker; Handler for dragging path vertices.
+ L.Editable.VertexMarker = L.Marker.extend({
+
+ options: {
+ draggable: true,
+ className: 'leaflet-div-icon leaflet-vertex-icon'
+ },
+
+
+ // 🍂section Public methods
+ // The marker used to handle path vertex. You will usually interact with a `VertexMarker`
+ // instance when listening for events like `editable:vertex:ctrlclick`.
+
+ initialize: function (latlng, latlngs, editor, options) {
+ // We don't use this._latlng, because on drag Leaflet replace it while
+ // we want to keep reference.
+ this.latlng = latlng;
+ this.latlngs = latlngs;
+ this.editor = editor;
+ L.Marker.prototype.initialize.call(this, latlng, options);
+ this.options.icon = this.editor.tools.createVertexIcon({className: this.options.className});
+ this.latlng.__vertex = this;
+ this.editor.editLayer.addLayer(this);
+ this.setZIndexOffset(editor.tools._lastZIndex + 1);
+ },
+
+ onAdd: function (map) {
+ L.Marker.prototype.onAdd.call(this, map);
+ this.on('drag', this.onDrag);
+ this.on('dragstart', this.onDragStart);
+ this.on('dragend', this.onDragEnd);
+ this.on('mouseup', this.onMouseup);
+ this.on('click', this.onClick);
+ this.on('contextmenu', this.onContextMenu);
+ this.on('mousedown touchstart', this.onMouseDown);
+ this.on('mouseover', this.onMouseOver);
+ this.on('mouseout', this.onMouseOut);
+ this.addMiddleMarkers();
+ },
+
+ onRemove: function (map) {
+ if (this.middleMarker) this.middleMarker.delete();
+ delete this.latlng.__vertex;
+ this.off('drag', this.onDrag);
+ this.off('dragstart', this.onDragStart);
+ this.off('dragend', this.onDragEnd);
+ this.off('mouseup', this.onMouseup);
+ this.off('click', this.onClick);
+ this.off('contextmenu', this.onContextMenu);
+ this.off('mousedown touchstart', this.onMouseDown);
+ this.off('mouseover', this.onMouseOver);
+ this.off('mouseout', this.onMouseOut);
+ L.Marker.prototype.onRemove.call(this, map);
+ },
+
+ onDrag: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerDrag(e);
+ var iconPos = L.DomUtil.getPosition(this._icon),
+ latlng = this._map.layerPointToLatLng(iconPos);
+ this.latlng.update(latlng);
+ this._latlng = this.latlng; // Push back to Leaflet our reference.
+ this.editor.refresh();
+ if (this.middleMarker) this.middleMarker.updateLatLng();
+ var next = this.getNext();
+ if (next && next.middleMarker) next.middleMarker.updateLatLng();
+ },
+
+ onDragStart: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerDragStart(e);
+ },
+
+ onDragEnd: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerDragEnd(e);
+ },
+
+ onClick: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerClick(e);
+ },
+
+ onMouseup: function (e) {
+ L.DomEvent.stop(e);
+ e.vertex = this;
+ this.editor.map.fire('mouseup', e);
+ },
+
+ onContextMenu: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerContextMenu(e);
+ },
+
+ onMouseDown: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerMouseDown(e);
+ },
+
+ onMouseOver: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerMouseOver(e);
+ },
+
+ onMouseOut: function (e) {
+ e.vertex = this;
+ this.editor.onVertexMarkerMouseOut(e);
+ },
+
+ // 🍂method delete()
+ // Delete a vertex and the related LatLng.
+ delete: function () {
+ var next = this.getNext(); // Compute before changing latlng
+ this.latlngs.splice(this.getIndex(), 1);
+ this.editor.editLayer.removeLayer(this);
+ this.editor.onVertexDeleted({latlng: this.latlng, vertex: this});
+ if (!this.latlngs.length) this.editor.deleteShape(this.latlngs);
+ if (next) next.resetMiddleMarker();
+ this.editor.refresh();
+ },
+
+ // 🍂method getIndex(): int
+ // Get the index of the current vertex among others of the same LatLngs group.
+ getIndex: function () {
+ return this.latlngs.indexOf(this.latlng);
+ },
+
+ // 🍂method getLastIndex(): int
+ // Get last vertex index of the LatLngs group of the current vertex.
+ getLastIndex: function () {
+ return this.latlngs.length - 1;
+ },
+
+ // 🍂method getPrevious(): VertexMarker
+ // Get the previous VertexMarker in the same LatLngs group.
+ getPrevious: function () {
+ if (this.latlngs.length < 2) return;
+ var index = this.getIndex(),
+ previousIndex = index - 1;
+ if (index === 0 && this.editor.CLOSED) previousIndex = this.getLastIndex();
+ var previous = this.latlngs[previousIndex];
+ if (previous) return previous.__vertex;
+ },
+
+ // 🍂method getNext(): VertexMarker
+ // Get the next VertexMarker in the same LatLngs group.
+ getNext: function () {
+ if (this.latlngs.length < 2) return;
+ var index = this.getIndex(),
+ nextIndex = index + 1;
+ if (index === this.getLastIndex() && this.editor.CLOSED) nextIndex = 0;
+ var next = this.latlngs[nextIndex];
+ if (next) return next.__vertex;
+ },
+
+ addMiddleMarker: function (previous) {
+ if (!this.editor.hasMiddleMarkers()) return;
+ previous = previous || this.getPrevious();
+ if (previous && !this.middleMarker) this.middleMarker = this.editor.addMiddleMarker(previous, this, this.latlngs, this.editor);
+ },
+
+ addMiddleMarkers: function () {
+ if (!this.editor.hasMiddleMarkers()) return;
+ var previous = this.getPrevious();
+ if (previous) this.addMiddleMarker(previous);
+ var next = this.getNext();
+ if (next) next.resetMiddleMarker();
+ },
+
+ resetMiddleMarker: function () {
+ if (this.middleMarker) this.middleMarker.delete();
+ this.addMiddleMarker();
+ },
+
+ // 🍂method split()
+ // Split the vertex LatLngs group at its index, if possible.
+ split: function () {
+ if (!this.editor.splitShape) return; // Only for PolylineEditor
+ this.editor.splitShape(this.latlngs, this.getIndex());
+ },
+
+ // 🍂method continue()
+ // Continue the vertex LatLngs from this vertex. Only active for first and last vertices of a Polyline.
+ continue: function () {
+ if (!this.editor.continueBackward) return; // Only for PolylineEditor
+ var index = this.getIndex();
+ if (index === 0) this.editor.continueBackward(this.latlngs);
+ else if (index === this.getLastIndex()) this.editor.continueForward(this.latlngs);
+ }
+
+ });
+
+ L.Editable.mergeOptions({
+
+ // 🍂namespace Editable
+ // 🍂option vertexMarkerClass: class = VertexMarker
+ // Class to be used as vertex, for path editing.
+ vertexMarkerClass: L.Editable.VertexMarker
+
+ });
+
+ L.Editable.MiddleMarker = L.Marker.extend({
+
+ options: {
+ opacity: 0.5,
+ className: 'leaflet-div-icon leaflet-middle-icon',
+ draggable: true
+ },
+
+ initialize: function (left, right, latlngs, editor, options) {
+ this.left = left;
+ this.right = right;
+ this.editor = editor;
+ this.latlngs = latlngs;
+ L.Marker.prototype.initialize.call(this, this.computeLatLng(), options);
+ this._opacity = this.options.opacity;
+ this.options.icon = this.editor.tools.createVertexIcon({className: this.options.className});
+ this.editor.editLayer.addLayer(this);
+ this.setVisibility();
+ },
+
+ setVisibility: function () {
+ var leftPoint = this._map.latLngToContainerPoint(this.left.latlng),
+ rightPoint = this._map.latLngToContainerPoint(this.right.latlng),
+ size = L.point(this.options.icon.options.iconSize);
+ if (leftPoint.distanceTo(rightPoint) < size.x * 3) this.hide();
+ else this.show();
+ },
+
+ show: function () {
+ this.setOpacity(this._opacity);
+ },
+
+ hide: function () {
+ this.setOpacity(0);
+ },
+
+ updateLatLng: function () {
+ this.setLatLng(this.computeLatLng());
+ this.setVisibility();
+ },
+
+ computeLatLng: function () {
+ var leftPoint = this.editor.map.latLngToContainerPoint(this.left.latlng),
+ rightPoint = this.editor.map.latLngToContainerPoint(this.right.latlng),
+ y = (leftPoint.y + rightPoint.y) / 2,
+ x = (leftPoint.x + rightPoint.x) / 2;
+ return this.editor.map.containerPointToLatLng([x, y]);
+ },
+
+ onAdd: function (map) {
+ L.Marker.prototype.onAdd.call(this, map);
+ L.DomEvent.on(this._icon, 'mousedown touchstart', this.onMouseDown, this);
+ map.on('zoomend', this.setVisibility, this);
+ },
+
+ onRemove: function (map) {
+ delete this.right.middleMarker;
+ L.DomEvent.off(this._icon, 'mousedown touchstart', this.onMouseDown, this);
+ map.off('zoomend', this.setVisibility, this);
+ L.Marker.prototype.onRemove.call(this, map);
+ },
+
+ onMouseDown: function (e) {
+ var iconPos = L.DomUtil.getPosition(this._icon),
+ latlng = this.editor.map.layerPointToLatLng(iconPos);
+ e = {
+ originalEvent: e,
+ latlng: latlng
+ };
+ if (this.options.opacity === 0) return;
+ L.Editable.makeCancellable(e);
+ this.editor.onMiddleMarkerMouseDown(e);
+ if (e._cancelled) return;
+ this.latlngs.splice(this.index(), 0, e.latlng);
+ this.editor.refresh();
+ var icon = this._icon;
+ var marker = this.editor.addVertexMarker(e.latlng, this.latlngs);
+ this.editor.onNewVertex(marker);
+ /* Hack to workaround browser not firing touchend when element is no more on DOM */
+ var parent = marker._icon.parentNode;
+ parent.removeChild(marker._icon);
+ marker._icon = icon;
+ parent.appendChild(marker._icon);
+ marker._initIcon();
+ marker._initInteraction();
+ marker.setOpacity(1);
+ /* End hack */
+ // Transfer ongoing dragging to real marker
+ L.Draggable._dragging = false;
+ marker.dragging._draggable._onDown(e.originalEvent);
+ this.delete();
+ },
+
+ delete: function () {
+ this.editor.editLayer.removeLayer(this);
+ },
+
+ index: function () {
+ return this.latlngs.indexOf(this.right.latlng);
+ }
+
+ });
+
+ L.Editable.mergeOptions({
+
+ // 🍂namespace Editable
+ // 🍂option middleMarkerClass: class = VertexMarker
+ // Class to be used as middle vertex, pulled by the user to create a new point in the middle of a path.
+ middleMarkerClass: L.Editable.MiddleMarker
+
+ });
+
+ // 🍂namespace Editable; 🍂class BaseEditor; 🍂aka L.Editable.BaseEditor
+ // When editing a feature (Marker, Polyline…), an editor is attached to it. This
+ // editor basically knows how to handle the edition.
+ L.Editable.BaseEditor = L.Handler.extend({
+
+ initialize: function (map, feature, options) {
+ L.setOptions(this, options);
+ this.map = map;
+ this.feature = feature;
+ this.feature.editor = this;
+ this.editLayer = new L.LayerGroup();
+ this.tools = this.options.editTools || map.editTools;
+ },
+
+ // 🍂method enable(): this
+ // Set up the drawing tools for the feature to be editable.
+ addHooks: function () {
+ if (this.isConnected()) this.onFeatureAdd();
+ else this.feature.once('add', this.onFeatureAdd, this);
+ this.onEnable();
+ this.feature.on(this._getEvents(), this);
+ },
+
+ // 🍂method disable(): this
+ // Remove the drawing tools for the feature.
+ removeHooks: function () {
+ this.feature.off(this._getEvents(), this);
+ if (this.feature.dragging) this.feature.dragging.disable();
+ this.editLayer.clearLayers();
+ this.tools.editLayer.removeLayer(this.editLayer);
+ this.onDisable();
+ if (this._drawing) this.cancelDrawing();
+ },
+
+ // 🍂method drawing(): boolean
+ // Return true if any drawing action is ongoing with this editor.
+ drawing: function () {
+ return !!this._drawing;
+ },
+
+ reset: function () {},
+
+ onFeatureAdd: function () {
+ this.tools.editLayer.addLayer(this.editLayer);
+ if (this.feature.dragging) this.feature.dragging.enable();
+ },
+
+ hasMiddleMarkers: function () {
+ return !this.options.skipMiddleMarkers && !this.tools.options.skipMiddleMarkers;
+ },
+
+ fireAndForward: function (type, e) {
+ e = e || {};
+ e.layer = this.feature;
+ this.feature.fire(type, e);
+ this.tools.fireAndForward(type, e);
+ },
+
+ onEnable: function () {
+ // 🍂namespace Editable
+ // 🍂event editable:enable: Event
+ // Fired when an existing feature is ready to be edited.
+ this.fireAndForward('editable:enable');
+ },
+
+ onDisable: function () {
+ // 🍂namespace Editable
+ // 🍂event editable:disable: Event
+ // Fired when an existing feature is not ready anymore to be edited.
+ this.fireAndForward('editable:disable');
+ },
+
+ onEditing: function () {
+ // 🍂namespace Editable
+ // 🍂event editable:editing: Event
+ // Fired as soon as any change is made to the feature geometry.
+ this.fireAndForward('editable:editing');
+ },
+
+ onStartDrawing: function () {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:start: Event
+ // Fired when a feature is to be drawn.
+ this.fireAndForward('editable:drawing:start');
+ },
+
+ onEndDrawing: function () {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:end: Event
+ // Fired when a feature is not drawn anymore.
+ this.fireAndForward('editable:drawing:end');
+ },
+
+ onCancelDrawing: function () {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:cancel: Event
+ // Fired when user cancel drawing while a feature is being drawn.
+ this.fireAndForward('editable:drawing:cancel');
+ },
+
+ onCommitDrawing: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:commit: Event
+ // Fired when user finish drawing a feature.
+ this.fireAndForward('editable:drawing:commit', e);
+ },
+
+ onDrawingMouseDown: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:mousedown: Event
+ // Fired when user `mousedown` while drawing.
+ this.fireAndForward('editable:drawing:mousedown', e);
+ },
+
+ onDrawingMouseUp: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:mouseup: Event
+ // Fired when user `mouseup` while drawing.
+ this.fireAndForward('editable:drawing:mouseup', e);
+ },
+
+ startDrawing: function () {
+ if (!this._drawing) this._drawing = L.Editable.FORWARD;
+ this.tools.registerForDrawing(this);
+ this.onStartDrawing();
+ },
+
+ commitDrawing: function (e) {
+ this.onCommitDrawing(e);
+ this.endDrawing();
+ },
+
+ cancelDrawing: function () {
+ // If called during a vertex drag, the vertex will be removed before
+ // the mouseup fires on it. This is a workaround. Maybe better fix is
+ // To have L.Draggable reset it's status on disable (Leaflet side).
+ L.Draggable._dragging = false;
+ this.onCancelDrawing();
+ this.endDrawing();
+ },
+
+ endDrawing: function () {
+ this._drawing = false;
+ this.tools.unregisterForDrawing(this);
+ this.onEndDrawing();
+ },
+
+ onDrawingClick: function (e) {
+ if (!this.drawing()) return;
+ L.Editable.makeCancellable(e);
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:click: CancelableEvent
+ // Fired when user `click` while drawing, before any internal action is being processed.
+ this.fireAndForward('editable:drawing:click', e);
+ if (e._cancelled) return;
+ if (!this.isConnected()) this.connect(e);
+ this.processDrawingClick(e);
+ },
+
+ isConnected: function () {
+ return this.map.hasLayer(this.feature);
+ },
+
+ connect: function () {
+ this.tools.connectCreatedToMap(this.feature);
+ this.tools.editLayer.addLayer(this.editLayer);
+ },
+
+ onMove: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:move: Event
+ // Fired when `move` mouse while drawing, while dragging a marker, and while dragging a vertex.
+ this.fireAndForward('editable:drawing:move', e);
+ },
+
+ onDrawingMouseMove: function (e) {
+ this.onMove(e);
+ },
+
+ _getEvents: function () {
+ return {
+ dragstart: this.onDragStart,
+ drag: this.onDrag,
+ dragend: this.onDragEnd,
+ remove: this.disable
+ };
+ },
+
+ onDragStart: function (e) {
+ this.onEditing();
+ // 🍂namespace Editable
+ // 🍂event editable:dragstart: Event
+ // Fired before a path feature is dragged.
+ this.fireAndForward('editable:dragstart', e);
+ },
+
+ onDrag: function (e) {
+ this.onMove(e);
+ // 🍂namespace Editable
+ // 🍂event editable:drag: Event
+ // Fired when a path feature is being dragged.
+ this.fireAndForward('editable:drag', e);
+ },
+
+ onDragEnd: function (e) {
+ // 🍂namespace Editable
+ // 🍂event editable:dragend: Event
+ // Fired after a path feature has been dragged.
+ this.fireAndForward('editable:dragend', e);
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class MarkerEditor; 🍂aka L.Editable.MarkerEditor
+ // 🍂inherits BaseEditor
+ // Editor for Marker.
+ L.Editable.MarkerEditor = L.Editable.BaseEditor.extend({
+
+ onDrawingMouseMove: function (e) {
+ L.Editable.BaseEditor.prototype.onDrawingMouseMove.call(this, e);
+ if (this._drawing) this.feature.setLatLng(e.latlng);
+ },
+
+ processDrawingClick: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Drawing events
+ // 🍂event editable:drawing:clicked: Event
+ // Fired when user `click` while drawing, after all internal actions.
+ this.fireAndForward('editable:drawing:clicked', e);
+ this.commitDrawing(e);
+ },
+
+ connect: function (e) {
+ // On touch, the latlng has not been updated because there is
+ // no mousemove.
+ if (e) this.feature._latlng = e.latlng;
+ L.Editable.BaseEditor.prototype.connect.call(this, e);
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class PathEditor; 🍂aka L.Editable.PathEditor
+ // 🍂inherits BaseEditor
+ // Base class for all path editors.
+ L.Editable.PathEditor = L.Editable.BaseEditor.extend({
+
+ CLOSED: false,
+ MIN_VERTEX: 2,
+
+ addHooks: function () {
+ L.Editable.BaseEditor.prototype.addHooks.call(this);
+ if (this.feature) this.initVertexMarkers();
+ return this;
+ },
+
+ initVertexMarkers: function (latlngs) {
+ if (!this.enabled()) return;
+ latlngs = latlngs || this.getLatLngs();
+ if (isFlat(latlngs)) this.addVertexMarkers(latlngs);
+ else for (var i = 0; i < latlngs.length; i++) this.initVertexMarkers(latlngs[i]);
+ },
+
+ getLatLngs: function () {
+ return this.feature.getLatLngs();
+ },
+
+ // 🍂method reset()
+ // Rebuild edit elements (Vertex, MiddleMarker, etc.).
+ reset: function () {
+ this.editLayer.clearLayers();
+ this.initVertexMarkers();
+ },
+
+ addVertexMarker: function (latlng, latlngs) {
+ return new this.tools.options.vertexMarkerClass(latlng, latlngs, this);
+ },
+
+ onNewVertex: function (vertex) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:new: VertexEvent
+ // Fired when a new vertex is created.
+ this.fireAndForward('editable:vertex:new', {latlng: vertex.latlng, vertex: vertex});
+ },
+
+ addVertexMarkers: function (latlngs) {
+ for (var i = 0; i < latlngs.length; i++) {
+ this.addVertexMarker(latlngs[i], latlngs);
+ }
+ },
+
+ refreshVertexMarkers: function (latlngs) {
+ latlngs = latlngs || this.getDefaultLatLngs();
+ for (var i = 0; i < latlngs.length; i++) {
+ latlngs[i].__vertex.update();
+ }
+ },
+
+ addMiddleMarker: function (left, right, latlngs) {
+ return new this.tools.options.middleMarkerClass(left, right, latlngs, this);
+ },
+
+ onVertexMarkerClick: function (e) {
+ L.Editable.makeCancellable(e);
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:click: CancelableVertexEvent
+ // Fired when a `click` is issued on a vertex, before any internal action is being processed.
+ this.fireAndForward('editable:vertex:click', e);
+ if (e._cancelled) return;
+ if (this.tools.drawing() && this.tools._drawingEditor !== this) return;
+ var index = e.vertex.getIndex(), commit;
+ if (e.originalEvent.ctrlKey) {
+ this.onVertexMarkerCtrlClick(e);
+ } else if (e.originalEvent.altKey) {
+ this.onVertexMarkerAltClick(e);
+ } else if (e.originalEvent.shiftKey) {
+ this.onVertexMarkerShiftClick(e);
+ } else if (e.originalEvent.metaKey) {
+ this.onVertexMarkerMetaKeyClick(e);
+ } else if (index === e.vertex.getLastIndex() && this._drawing === L.Editable.FORWARD) {
+ if (index >= this.MIN_VERTEX - 1) commit = true;
+ } else if (index === 0 && this._drawing === L.Editable.BACKWARD && this._drawnLatLngs.length >= this.MIN_VERTEX) {
+ commit = true;
+ } else if (index === 0 && this._drawing === L.Editable.FORWARD && this._drawnLatLngs.length >= this.MIN_VERTEX && this.CLOSED) {
+ commit = true; // Allow to close on first point also for polygons
+ } else {
+ this.onVertexRawMarkerClick(e);
+ }
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:clicked: VertexEvent
+ // Fired when a `click` is issued on a vertex, after all internal actions.
+ this.fireAndForward('editable:vertex:clicked', e);
+ if (commit) this.commitDrawing(e);
+ },
+
+ onVertexRawMarkerClick: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:rawclick: CancelableVertexEvent
+ // Fired when a `click` is issued on a vertex without any special key and without being in drawing mode.
+ this.fireAndForward('editable:vertex:rawclick', e);
+ if (e._cancelled) return;
+ if (!this.vertexCanBeDeleted(e.vertex)) return;
+ e.vertex.delete();
+ },
+
+ vertexCanBeDeleted: function (vertex) {
+ return vertex.latlngs.length > this.MIN_VERTEX;
+ },
+
+ onVertexDeleted: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:deleted: VertexEvent
+ // Fired after a vertex has been deleted by user.
+ this.fireAndForward('editable:vertex:deleted', e);
+ },
+
+ onVertexMarkerCtrlClick: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:ctrlclick: VertexEvent
+ // Fired when a `click` with `ctrlKey` is issued on a vertex.
+ this.fireAndForward('editable:vertex:ctrlclick', e);
+ },
+
+ onVertexMarkerShiftClick: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:shiftclick: VertexEvent
+ // Fired when a `click` with `shiftKey` is issued on a vertex.
+ this.fireAndForward('editable:vertex:shiftclick', e);
+ },
+
+ onVertexMarkerMetaKeyClick: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:metakeyclick: VertexEvent
+ // Fired when a `click` with `metaKey` is issued on a vertex.
+ this.fireAndForward('editable:vertex:metakeyclick', e);
+ },
+
+ onVertexMarkerAltClick: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:altclick: VertexEvent
+ // Fired when a `click` with `altKey` is issued on a vertex.
+ this.fireAndForward('editable:vertex:altclick', e);
+ },
+
+ onVertexMarkerContextMenu: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:contextmenu: VertexEvent
+ // Fired when a `contextmenu` is issued on a vertex.
+ this.fireAndForward('editable:vertex:contextmenu', e);
+ },
+
+ onVertexMarkerMouseDown: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:mousedown: VertexEvent
+ // Fired when user `mousedown` a vertex.
+ this.fireAndForward('editable:vertex:mousedown', e);
+ },
+
+ onVertexMarkerMouseOver: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:mouseover: VertexEvent
+ // Fired when a user's mouse enters the vertex
+ this.fireAndForward('editable:vertex:mouseover', e);
+ },
+
+ onVertexMarkerMouseOut: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:mouseout: VertexEvent
+ // Fired when a user's mouse leaves the vertex
+ this.fireAndForward('editable:vertex:mouseout', e);
+ },
+
+ onMiddleMarkerMouseDown: function (e) {
+ // 🍂namespace Editable
+ // 🍂section MiddleMarker events
+ // 🍂event editable:middlemarker:mousedown: VertexEvent
+ // Fired when user `mousedown` a middle marker.
+ this.fireAndForward('editable:middlemarker:mousedown', e);
+ },
+
+ onVertexMarkerDrag: function (e) {
+ this.onMove(e);
+ if (this.feature._bounds) this.extendBounds(e);
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:drag: VertexEvent
+ // Fired when a vertex is dragged by user.
+ this.fireAndForward('editable:vertex:drag', e);
+ },
+
+ onVertexMarkerDragStart: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:dragstart: VertexEvent
+ // Fired before a vertex is dragged by user.
+ this.fireAndForward('editable:vertex:dragstart', e);
+ },
+
+ onVertexMarkerDragEnd: function (e) {
+ // 🍂namespace Editable
+ // 🍂section Vertex events
+ // 🍂event editable:vertex:dragend: VertexEvent
+ // Fired after a vertex is dragged by user.
+ this.fireAndForward('editable:vertex:dragend', e);
+ },
+
+ setDrawnLatLngs: function (latlngs) {
+ this._drawnLatLngs = latlngs || this.getDefaultLatLngs();
+ },
+
+ startDrawing: function () {
+ if (!this._drawnLatLngs) this.setDrawnLatLngs();
+ L.Editable.BaseEditor.prototype.startDrawing.call(this);
+ },
+
+ startDrawingForward: function () {
+ this.startDrawing();
+ },
+
+ endDrawing: function () {
+ this.tools.detachForwardLineGuide();
+ this.tools.detachBackwardLineGuide();
+ if (this._drawnLatLngs && this._drawnLatLngs.length < this.MIN_VERTEX) this.deleteShape(this._drawnLatLngs);
+ L.Editable.BaseEditor.prototype.endDrawing.call(this);
+ delete this._drawnLatLngs;
+ },
+
+ addLatLng: function (latlng) {
+ if (this._drawing === L.Editable.FORWARD) this._drawnLatLngs.push(latlng);
+ else this._drawnLatLngs.unshift(latlng);
+ this.feature._bounds.extend(latlng);
+ var vertex = this.addVertexMarker(latlng, this._drawnLatLngs);
+ this.onNewVertex(vertex);
+ this.refresh();
+ },
+
+ newPointForward: function (latlng) {
+ this.addLatLng(latlng);
+ this.tools.attachForwardLineGuide();
+ this.tools.anchorForwardLineGuide(latlng);
+ },
+
+ newPointBackward: function (latlng) {
+ this.addLatLng(latlng);
+ this.tools.anchorBackwardLineGuide(latlng);
+ },
+
+ // 🍂namespace PathEditor
+ // 🍂method push()
+ // Programmatically add a point while drawing.
+ push: function (latlng) {
+ if (!latlng) return console.error('L.Editable.PathEditor.push expect a valid latlng as parameter');
+ if (this._drawing === L.Editable.FORWARD) this.newPointForward(latlng);
+ else this.newPointBackward(latlng);
+ },
+
+ removeLatLng: function (latlng) {
+ latlng.__vertex.delete();
+ this.refresh();
+ },
+
+ // 🍂method pop(): L.LatLng or null
+ // Programmatically remove last point (if any) while drawing.
+ pop: function () {
+ if (this._drawnLatLngs.length <= 1) return;
+ var latlng;
+ if (this._drawing === L.Editable.FORWARD) latlng = this._drawnLatLngs[this._drawnLatLngs.length - 1];
+ else latlng = this._drawnLatLngs[0];
+ this.removeLatLng(latlng);
+ if (this._drawing === L.Editable.FORWARD) this.tools.anchorForwardLineGuide(this._drawnLatLngs[this._drawnLatLngs.length - 1]);
+ else this.tools.anchorForwardLineGuide(this._drawnLatLngs[0]);
+ return latlng;
+ },
+
+ processDrawingClick: function (e) {
+ if (e.vertex && e.vertex.editor === this) return;
+ if (this._drawing === L.Editable.FORWARD) this.newPointForward(e.latlng);
+ else this.newPointBackward(e.latlng);
+ this.fireAndForward('editable:drawing:clicked', e);
+ },
+
+ onDrawingMouseMove: function (e) {
+ L.Editable.BaseEditor.prototype.onDrawingMouseMove.call(this, e);
+ if (this._drawing) {
+ this.tools.moveForwardLineGuide(e.latlng);
+ this.tools.moveBackwardLineGuide(e.latlng);
+ }
+ },
+
+ refresh: function () {
+ this.feature.redraw();
+ this.onEditing();
+ },
+
+ // 🍂namespace PathEditor
+ // 🍂method newShape(latlng?: L.LatLng)
+ // Add a new shape (Polyline, Polygon) in a multi, and setup up drawing tools to draw it;
+ // if optional `latlng` is given, start a path at this point.
+ newShape: function (latlng) {
+ var shape = this.addNewEmptyShape();
+ if (!shape) return;
+ this.setDrawnLatLngs(shape[0] || shape); // Polygon or polyline
+ this.startDrawingForward();
+ // 🍂namespace Editable
+ // 🍂section Shape events
+ // 🍂event editable:shape:new: ShapeEvent
+ // Fired when a new shape is created in a multi (Polygon or Polyline).
+ this.fireAndForward('editable:shape:new', {shape: shape});
+ if (latlng) this.newPointForward(latlng);
+ },
+
+ deleteShape: function (shape, latlngs) {
+ var e = {shape: shape};
+ L.Editable.makeCancellable(e);
+ // 🍂namespace Editable
+ // 🍂section Shape events
+ // 🍂event editable:shape:delete: CancelableShapeEvent
+ // Fired before a new shape is deleted in a multi (Polygon or Polyline).
+ this.fireAndForward('editable:shape:delete', e);
+ if (e._cancelled) return;
+ shape = this._deleteShape(shape, latlngs);
+ if (this.ensureNotFlat) this.ensureNotFlat(); // Polygon.
+ this.feature.setLatLngs(this.getLatLngs()); // Force bounds reset.
+ this.refresh();
+ this.reset();
+ // 🍂namespace Editable
+ // 🍂section Shape events
+ // 🍂event editable:shape:deleted: ShapeEvent
+ // Fired after a new shape is deleted in a multi (Polygon or Polyline).
+ this.fireAndForward('editable:shape:deleted', {shape: shape});
+ return shape;
+ },
+
+ _deleteShape: function (shape, latlngs) {
+ latlngs = latlngs || this.getLatLngs();
+ if (!latlngs.length) return;
+ var self = this,
+ inplaceDelete = function (latlngs, shape) {
+ // Called when deleting a flat latlngs
+ shape = latlngs.splice(0, Number.MAX_VALUE);
+ return shape;
+ },
+ spliceDelete = function (latlngs, shape) {
+ // Called when removing a latlngs inside an array
+ latlngs.splice(latlngs.indexOf(shape), 1);
+ if (!latlngs.length) self._deleteShape(latlngs);
+ return shape;
+ };
+ if (latlngs === shape) return inplaceDelete(latlngs, shape);
+ for (var i = 0; i < latlngs.length; i++) {
+ if (latlngs[i] === shape) return spliceDelete(latlngs, shape);
+ else if (latlngs[i].indexOf(shape) !== -1) return spliceDelete(latlngs[i], shape);
+ }
+ },
+
+ // 🍂namespace PathEditor
+ // 🍂method deleteShapeAt(latlng: L.LatLng): Array
+ // Remove a path shape at the given `latlng`.
+ deleteShapeAt: function (latlng) {
+ var shape = this.feature.shapeAt(latlng);
+ if (shape) return this.deleteShape(shape);
+ },
+
+ // 🍂method appendShape(shape: Array)
+ // Append a new shape to the Polygon or Polyline.
+ appendShape: function (shape) {
+ this.insertShape(shape);
+ },
+
+ // 🍂method prependShape(shape: Array)
+ // Prepend a new shape to the Polygon or Polyline.
+ prependShape: function (shape) {
+ this.insertShape(shape, 0);
+ },
+
+ // 🍂method insertShape(shape: Array, index: int)
+ // Insert a new shape to the Polygon or Polyline at given index (default is to append).
+ insertShape: function (shape, index) {
+ this.ensureMulti();
+ shape = this.formatShape(shape);
+ if (typeof index === 'undefined') index = this.feature._latlngs.length;
+ this.feature._latlngs.splice(index, 0, shape);
+ this.feature.redraw();
+ if (this._enabled) this.reset();
+ },
+
+ extendBounds: function (e) {
+ this.feature._bounds.extend(e.vertex.latlng);
+ },
+
+ onDragStart: function (e) {
+ this.editLayer.clearLayers();
+ L.Editable.BaseEditor.prototype.onDragStart.call(this, e);
+ },
+
+ onDragEnd: function (e) {
+ this.initVertexMarkers();
+ L.Editable.BaseEditor.prototype.onDragEnd.call(this, e);
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class PolylineEditor; 🍂aka L.Editable.PolylineEditor
+ // 🍂inherits PathEditor
+ L.Editable.PolylineEditor = L.Editable.PathEditor.extend({
+
+ startDrawingBackward: function () {
+ this._drawing = L.Editable.BACKWARD;
+ this.startDrawing();
+ },
+
+ // 🍂method continueBackward(latlngs?: Array)
+ // Set up drawing tools to continue the line backward.
+ continueBackward: function (latlngs) {
+ if (this.drawing()) return;
+ latlngs = latlngs || this.getDefaultLatLngs();
+ this.setDrawnLatLngs(latlngs);
+ if (latlngs.length > 0) {
+ this.tools.attachBackwardLineGuide();
+ this.tools.anchorBackwardLineGuide(latlngs[0]);
+ }
+ this.startDrawingBackward();
+ },
+
+ // 🍂method continueForward(latlngs?: Array)
+ // Set up drawing tools to continue the line forward.
+ continueForward: function (latlngs) {
+ if (this.drawing()) return;
+ latlngs = latlngs || this.getDefaultLatLngs();
+ this.setDrawnLatLngs(latlngs);
+ if (latlngs.length > 0) {
+ this.tools.attachForwardLineGuide();
+ this.tools.anchorForwardLineGuide(latlngs[latlngs.length - 1]);
+ }
+ this.startDrawingForward();
+ },
+
+ getDefaultLatLngs: function (latlngs) {
+ latlngs = latlngs || this.feature._latlngs;
+ if (!latlngs.length || latlngs[0] instanceof L.LatLng) return latlngs;
+ else return this.getDefaultLatLngs(latlngs[0]);
+ },
+
+ ensureMulti: function () {
+ if (this.feature._latlngs.length && isFlat(this.feature._latlngs)) {
+ this.feature._latlngs = [this.feature._latlngs];
+ }
+ },
+
+ addNewEmptyShape: function () {
+ if (this.feature._latlngs.length) {
+ var shape = [];
+ this.appendShape(shape);
+ return shape;
+ } else {
+ return this.feature._latlngs;
+ }
+ },
+
+ formatShape: function (shape) {
+ if (isFlat(shape)) return shape;
+ else if (shape[0]) return this.formatShape(shape[0]);
+ },
+
+ // 🍂method splitShape(latlngs?: Array, index: int)
+ // Split the given `latlngs` shape at index `index` and integrate new shape in instance `latlngs`.
+ splitShape: function (shape, index) {
+ if (!index || index >= shape.length - 1) return;
+ this.ensureMulti();
+ var shapeIndex = this.feature._latlngs.indexOf(shape);
+ if (shapeIndex === -1) return;
+ var first = shape.slice(0, index + 1),
+ second = shape.slice(index);
+ // We deal with reference, we don't want twice the same latlng around.
+ second[0] = L.latLng(second[0].lat, second[0].lng, second[0].alt);
+ this.feature._latlngs.splice(shapeIndex, 1, first, second);
+ this.refresh();
+ this.reset();
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class PolygonEditor; 🍂aka L.Editable.PolygonEditor
+ // 🍂inherits PathEditor
+ L.Editable.PolygonEditor = L.Editable.PathEditor.extend({
+
+ CLOSED: true,
+ MIN_VERTEX: 3,
+
+ newPointForward: function (latlng) {
+ L.Editable.PathEditor.prototype.newPointForward.call(this, latlng);
+ if (!this.tools.backwardLineGuide._latlngs.length) this.tools.anchorBackwardLineGuide(latlng);
+ if (this._drawnLatLngs.length === 2) this.tools.attachBackwardLineGuide();
+ },
+
+ addNewEmptyHole: function (latlng) {
+ this.ensureNotFlat();
+ var latlngs = this.feature.shapeAt(latlng);
+ if (!latlngs) return;
+ var holes = [];
+ latlngs.push(holes);
+ return holes;
+ },
+
+ // 🍂method newHole(latlng?: L.LatLng, index: int)
+ // Set up drawing tools for creating a new hole on the Polygon. If the `latlng` param is given, a first point is created.
+ newHole: function (latlng) {
+ var holes = this.addNewEmptyHole(latlng);
+ if (!holes) return;
+ this.setDrawnLatLngs(holes);
+ this.startDrawingForward();
+ if (latlng) this.newPointForward(latlng);
+ },
+
+ addNewEmptyShape: function () {
+ if (this.feature._latlngs.length && this.feature._latlngs[0].length) {
+ var shape = [];
+ this.appendShape(shape);
+ return shape;
+ } else {
+ return this.feature._latlngs;
+ }
+ },
+
+ ensureMulti: function () {
+ if (this.feature._latlngs.length && isFlat(this.feature._latlngs[0])) {
+ this.feature._latlngs = [this.feature._latlngs];
+ }
+ },
+
+ ensureNotFlat: function () {
+ if (!this.feature._latlngs.length || isFlat(this.feature._latlngs)) this.feature._latlngs = [this.feature._latlngs];
+ },
+
+ vertexCanBeDeleted: function (vertex) {
+ var parent = this.feature.parentShape(vertex.latlngs),
+ idx = L.Util.indexOf(parent, vertex.latlngs);
+ if (idx > 0) return true; // Holes can be totally deleted without removing the layer itself.
+ return L.Editable.PathEditor.prototype.vertexCanBeDeleted.call(this, vertex);
+ },
+
+ getDefaultLatLngs: function () {
+ if (!this.feature._latlngs.length) this.feature._latlngs.push([]);
+ return this.feature._latlngs[0];
+ },
+
+ formatShape: function (shape) {
+ // [[1, 2], [3, 4]] => must be nested
+ // [] => must be nested
+ // [[]] => is already nested
+ if (isFlat(shape) && (!shape[0] || shape[0].length !== 0)) return [shape];
+ else return shape;
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class RectangleEditor; 🍂aka L.Editable.RectangleEditor
+ // 🍂inherits PathEditor
+ L.Editable.RectangleEditor = L.Editable.PathEditor.extend({
+
+ CLOSED: true,
+ MIN_VERTEX: 4,
+
+ options: {
+ skipMiddleMarkers: true
+ },
+
+ extendBounds: function (e) {
+ var index = e.vertex.getIndex(),
+ next = e.vertex.getNext(),
+ previous = e.vertex.getPrevious(),
+ oppositeIndex = (index + 2) % 4,
+ opposite = e.vertex.latlngs[oppositeIndex],
+ bounds = new L.LatLngBounds(e.latlng, opposite);
+ // Update latlngs by hand to preserve order.
+ previous.latlng.update([e.latlng.lat, opposite.lng]);
+ next.latlng.update([opposite.lat, e.latlng.lng]);
+ this.updateBounds(bounds);
+ this.refreshVertexMarkers();
+ },
+
+ onDrawingMouseDown: function (e) {
+ L.Editable.PathEditor.prototype.onDrawingMouseDown.call(this, e);
+ this.connect();
+ var latlngs = this.getDefaultLatLngs();
+ // L.Polygon._convertLatLngs removes last latlng if it equals first point,
+ // which is the case here as all latlngs are [0, 0]
+ if (latlngs.length === 3) latlngs.push(e.latlng);
+ var bounds = new L.LatLngBounds(e.latlng, e.latlng);
+ this.updateBounds(bounds);
+ this.updateLatLngs(bounds);
+ this.refresh();
+ this.reset();
+ // Stop dragging map.
+ // L.Draggable has two workflows:
+ // - mousedown => mousemove => mouseup
+ // - touchstart => touchmove => touchend
+ // Problem: L.Map.Tap does not allow us to listen to touchstart, so we only
+ // can deal with mousedown, but then when in a touch device, we are dealing with
+ // simulated events (actually simulated by L.Map.Tap), which are no more taken
+ // into account by L.Draggable.
+ // Ref.: https://github.com/Leaflet/Leaflet.Editable/issues/103
+ e.originalEvent._simulated = false;
+ this.map.dragging._draggable._onUp(e.originalEvent);
+ // Now transfer ongoing drag action to the bottom right corner.
+ // Should we refine which corner will handle the drag according to
+ // drag direction?
+ latlngs[3].__vertex.dragging._draggable._onDown(e.originalEvent);
+ },
+
+ onDrawingMouseUp: function (e) {
+ this.commitDrawing(e);
+ e.originalEvent._simulated = false;
+ L.Editable.PathEditor.prototype.onDrawingMouseUp.call(this, e);
+ },
+
+ onDrawingMouseMove: function (e) {
+ e.originalEvent._simulated = false;
+ L.Editable.PathEditor.prototype.onDrawingMouseMove.call(this, e);
+ },
+
+
+ getDefaultLatLngs: function (latlngs) {
+ return latlngs || this.feature._latlngs[0];
+ },
+
+ updateBounds: function (bounds) {
+ this.feature._bounds = bounds;
+ },
+
+ updateLatLngs: function (bounds) {
+ var latlngs = this.getDefaultLatLngs(),
+ newLatlngs = this.feature._boundsToLatLngs(bounds);
+ // Keep references.
+ for (var i = 0; i < latlngs.length; i++) {
+ latlngs[i].update(newLatlngs[i]);
+ }
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class CircleEditor; 🍂aka L.Editable.CircleEditor
+ // 🍂inherits PathEditor
+ L.Editable.CircleEditor = L.Editable.PathEditor.extend({
+
+ MIN_VERTEX: 2,
+
+ options: {
+ skipMiddleMarkers: true
+ },
+
+ initialize: function (map, feature, options) {
+ L.Editable.PathEditor.prototype.initialize.call(this, map, feature, options);
+ this._resizeLatLng = this.computeResizeLatLng();
+ },
+
+ computeResizeLatLng: function () {
+ // While circle is not added to the map, _radius is not set.
+ var delta = (this.feature._radius || this.feature._mRadius) * Math.cos(Math.PI / 4),
+ point = this.map.project(this.feature._latlng);
+ return this.map.unproject([point.x + delta, point.y - delta]);
+ },
+
+ updateResizeLatLng: function () {
+ this._resizeLatLng.update(this.computeResizeLatLng());
+ this._resizeLatLng.__vertex.update();
+ },
+
+ getLatLngs: function () {
+ return [this.feature._latlng, this._resizeLatLng];
+ },
+
+ getDefaultLatLngs: function () {
+ return this.getLatLngs();
+ },
+
+ onVertexMarkerDrag: function (e) {
+ if (e.vertex.getIndex() === 1) this.resize(e);
+ else this.updateResizeLatLng(e);
+ L.Editable.PathEditor.prototype.onVertexMarkerDrag.call(this, e);
+ },
+
+ resize: function (e) {
+ var radius = this.feature._latlng.distanceTo(e.latlng);
+ this.feature.setRadius(radius);
+ },
+
+ onDrawingMouseDown: function (e) {
+ L.Editable.PathEditor.prototype.onDrawingMouseDown.call(this, e);
+ this._resizeLatLng.update(e.latlng);
+ this.feature._latlng.update(e.latlng);
+ this.connect();
+ // Stop dragging map.
+ e.originalEvent._simulated = false;
+ this.map.dragging._draggable._onUp(e.originalEvent);
+ // Now transfer ongoing drag action to the radius handler.
+ this._resizeLatLng.__vertex.dragging._draggable._onDown(e.originalEvent);
+ },
+
+ onDrawingMouseUp: function (e) {
+ this.commitDrawing(e);
+ e.originalEvent._simulated = false;
+ L.Editable.PathEditor.prototype.onDrawingMouseUp.call(this, e);
+ },
+
+ onDrawingMouseMove: function (e) {
+ e.originalEvent._simulated = false;
+ L.Editable.PathEditor.prototype.onDrawingMouseMove.call(this, e);
+ },
+
+ onDrag: function (e) {
+ L.Editable.PathEditor.prototype.onDrag.call(this, e);
+ this.feature.dragging.updateLatLng(this._resizeLatLng);
+ }
+
+ });
+
+ // 🍂namespace Editable; 🍂class EditableMixin
+ // `EditableMixin` is included to `L.Polyline`, `L.Polygon`, `L.Rectangle`, `L.Circle`
+ // and `L.Marker`. It adds some methods to them.
+ // *When editing is enabled, the editor is accessible on the instance with the
+ // `editor` property.*
+ var EditableMixin = {
+
+ createEditor: function (map) {
+ map = map || this._map;
+ var tools = (this.options.editOptions || {}).editTools || map.editTools;
+ if (!tools) throw Error('Unable to detect Editable instance.');
+ var Klass = this.options.editorClass || this.getEditorClass(tools);
+ return new Klass(map, this, this.options.editOptions);
+ },
+
+ // 🍂method enableEdit(map?: L.Map): this.editor
+ // Enable editing, by creating an editor if not existing, and then calling `enable` on it.
+ enableEdit: function (map) {
+ if (!this.editor) this.createEditor(map);
+ this.editor.enable();
+ return this.editor;
+ },
+
+ // 🍂method editEnabled(): boolean
+ // Return true if current instance has an editor attached, and this editor is enabled.
+ editEnabled: function () {
+ return this.editor && this.editor.enabled();
+ },
+
+ // 🍂method disableEdit()
+ // Disable editing, also remove the editor property reference.
+ disableEdit: function () {
+ if (this.editor) {
+ this.editor.disable();
+ delete this.editor;
+ }
+ },
+
+ // 🍂method toggleEdit()
+ // Enable or disable editing, according to current status.
+ toggleEdit: function () {
+ if (this.editEnabled()) this.disableEdit();
+ else this.enableEdit();
+ },
+
+ _onEditableAdd: function () {
+ if (this.editor) this.enableEdit();
+ }
+
+ };
+
+ var PolylineMixin = {
+
+ getEditorClass: function (tools) {
+ return (tools && tools.options.polylineEditorClass) ? tools.options.polylineEditorClass : L.Editable.PolylineEditor;
+ },
+
+ shapeAt: function (latlng, latlngs) {
+ // We can have those cases:
+ // - latlngs are just a flat array of latlngs, use this
+ // - latlngs is an array of arrays of latlngs, loop over
+ var shape = null;
+ latlngs = latlngs || this._latlngs;
+ if (!latlngs.length) return shape;
+ else if (isFlat(latlngs) && this.isInLatLngs(latlng, latlngs)) shape = latlngs;
+ else for (var i = 0; i < latlngs.length; i++) if (this.isInLatLngs(latlng, latlngs[i])) return latlngs[i];
+ return shape;
+ },
+
+ isInLatLngs: function (l, latlngs) {
+ if (!latlngs) return false;
+ var i, k, len, part = [], p,
+ w = this._clickTolerance();
+ this._projectLatlngs(latlngs, part, this._pxBounds);
+ part = part[0];
+ p = this._map.latLngToLayerPoint(l);
+
+ if (!this._pxBounds.contains(p)) { return false; }
+ for (i = 1, len = part.length, k = 0; i < len; k = i++) {
+
+ if (L.LineUtil.pointToSegmentDistance(p, part[k], part[i]) <= w) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ };
+
+ var PolygonMixin = {
+
+ getEditorClass: function (tools) {
+ return (tools && tools.options.polygonEditorClass) ? tools.options.polygonEditorClass : L.Editable.PolygonEditor;
+ },
+
+ shapeAt: function (latlng, latlngs) {
+ // We can have those cases:
+ // - latlngs are just a flat array of latlngs, use this
+ // - latlngs is an array of arrays of latlngs, this is a simple polygon (maybe with holes), use the first
+ // - latlngs is an array of arrays of arrays, this is a multi, loop over
+ var shape = null;
+ latlngs = latlngs || this._latlngs;
+ if (!latlngs.length) return shape;
+ else if (isFlat(latlngs) && this.isInLatLngs(latlng, latlngs)) shape = latlngs;
+ else if (isFlat(latlngs[0]) && this.isInLatLngs(latlng, latlngs[0])) shape = latlngs;
+ else for (var i = 0; i < latlngs.length; i++) if (this.isInLatLngs(latlng, latlngs[i][0])) return latlngs[i];
+ return shape;
+ },
+
+ isInLatLngs: function (l, latlngs) {
+ var inside = false, l1, l2, j, k, len2;
+
+ for (j = 0, len2 = latlngs.length, k = len2 - 1; j < len2; k = j++) {
+ l1 = latlngs[j];
+ l2 = latlngs[k];
+
+ if (((l1.lat > l.lat) !== (l2.lat > l.lat)) &&
+ (l.lng < (l2.lng - l1.lng) * (l.lat - l1.lat) / (l2.lat - l1.lat) + l1.lng)) {
+ inside = !inside;
+ }
+ }
+
+ return inside;
+ },
+
+ parentShape: function (shape, latlngs) {
+ latlngs = latlngs || this._latlngs;
+ if (!latlngs) return;
+ var idx = L.Util.indexOf(latlngs, shape);
+ if (idx !== -1) return latlngs;
+ for (var i = 0; i < latlngs.length; i++) {
+ idx = L.Util.indexOf(latlngs[i], shape);
+ if (idx !== -1) return latlngs[i];
+ }
+ }
+
+ };
+
+
+ var MarkerMixin = {
+
+ getEditorClass: function (tools) {
+ return (tools && tools.options.markerEditorClass) ? tools.options.markerEditorClass : L.Editable.MarkerEditor;
+ }
+
+ };
+
+ var RectangleMixin = {
+
+ getEditorClass: function (tools) {
+ return (tools && tools.options.rectangleEditorClass) ? tools.options.rectangleEditorClass : L.Editable.RectangleEditor;
+ }
+
+ };
+
+ var CircleMixin = {
+
+ getEditorClass: function (tools) {
+ return (tools && tools.options.circleEditorClass) ? tools.options.circleEditorClass : L.Editable.CircleEditor;
+ }
+
+ };
+
+ var keepEditable = function () {
+ // Make sure you can remove/readd an editable layer.
+ this.on('add', this._onEditableAdd);
+ };
+
+ var isFlat = L.LineUtil.isFlat || L.LineUtil._flat || L.Polyline._flat; // <=> 1.1 compat.
+
+
+ if (L.Polyline) {
+ L.Polyline.include(EditableMixin);
+ L.Polyline.include(PolylineMixin);
+ L.Polyline.addInitHook(keepEditable);
+ }
+ if (L.Polygon) {
+ L.Polygon.include(EditableMixin);
+ L.Polygon.include(PolygonMixin);
+ }
+ if (L.Marker) {
+ L.Marker.include(EditableMixin);
+ L.Marker.include(MarkerMixin);
+ L.Marker.addInitHook(keepEditable);
+ }
+ if (L.Rectangle) {
+ L.Rectangle.include(EditableMixin);
+ L.Rectangle.include(RectangleMixin);
+ }
+ if (L.Circle) {
+ L.Circle.include(EditableMixin);
+ L.Circle.include(CircleMixin);
+ }
+
+ L.LatLng.prototype.update = function (latlng) {
+ latlng = L.latLng(latlng);
+ this.lat = latlng.lat;
+ this.lng = latlng.lng;
+ }
+
+}, window));
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.editor.js b/www/wiki/extensions/Maps/resources/leaflet/leaflet.editor.js
new file mode 100644
index 00000000..6aadad18
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.editor.js
@@ -0,0 +1,15 @@
+(function( $, mw ) {
+
+ $( document ).ready( function() {
+ var map = L.map('GeoJsonMap'/*, {editable: true}*/);
+
+ L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
+ attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
+ }).addTo(map);
+
+ var geoJsonLayer = L.geoJSON(GeoJson).addTo(map);
+
+ map.fitBounds(geoJsonLayer.getBounds());
+ } );
+
+})( window.jQuery, mediaWiki );
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/.jshintrc b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/.jshintrc
new file mode 100644
index 00000000..b7636119
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/.jshintrc
@@ -0,0 +1,12 @@
+{
+ "browser": true,
+ "curly": true,
+ "eqeqeq": true,
+ "undef": true,
+ "quotmark": "single",
+ "trailing": true,
+ "globals": {
+ "L": true,
+ "jQuery": true
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.css b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.css
new file mode 100644
index 00000000..c93b1bf9
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.css
@@ -0,0 +1,4 @@
+.leaflet-control-zoom-fullscreen { background-image: url(icon-fullscreen.png); }
+.leaflet-retina .leaflet-control-zoom-fullscreen { background-image: url(icon-fullscreen-2x.png); background-size: 26px 26px; }
+.leaflet-container:-webkit-full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
+.leaflet-pseudo-fullscreen { position: fixed !important; width: 100% !important; height: 100% !important; top: 0px !important; left: 0px !important; z-index: 99999; } \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.js b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.js
new file mode 100644
index 00000000..f1cd7ccc
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/Control.FullScreen.js
@@ -0,0 +1,164 @@
+(function() {
+
+L.Control.FullScreen = L.Control.extend({
+ options: {
+ position: 'topleft',
+ title: 'Full Screen',
+ forceSeparateButton: false,
+ forcePseudoFullscreen: false
+ },
+
+ onAdd: function (map) {
+ var className = 'leaflet-control-zoom-fullscreen', container;
+
+ if (map.zoomControl && !this.options.forceSeparateButton) {
+ container = map.zoomControl._container;
+ } else {
+ container = L.DomUtil.create('div', 'leaflet-bar');
+ }
+
+ this._createButton(this.options.title, className, container, this.toggleFullScreen, this);
+
+ return container;
+ },
+
+ _createButton: function (title, className, container, fn, context) {
+ var link = L.DomUtil.create('a', className, container);
+ link.href = '#';
+ link.title = title;
+
+ L.DomEvent
+ .addListener(link, 'click', L.DomEvent.stopPropagation)
+ .addListener(link, 'click', L.DomEvent.preventDefault)
+ .addListener(link, 'click', fn, context);
+
+ L.DomEvent
+ .addListener(container, fullScreenApi.fullScreenEventName, L.DomEvent.stopPropagation)
+ .addListener(container, fullScreenApi.fullScreenEventName, L.DomEvent.preventDefault)
+ .addListener(container, fullScreenApi.fullScreenEventName, this._handleEscKey, context);
+
+ L.DomEvent
+ .addListener(document, fullScreenApi.fullScreenEventName, L.DomEvent.stopPropagation)
+ .addListener(document, fullScreenApi.fullScreenEventName, L.DomEvent.preventDefault)
+ .addListener(document, fullScreenApi.fullScreenEventName, this._handleEscKey, context);
+
+ return link;
+ },
+
+ toggleFullScreen: function () {
+ var map = this._map;
+ map._exitFired = false;
+ if (map._isFullscreen) {
+ if (fullScreenApi.supportsFullScreen && !this.options.forcePseudoFullscreen) {
+ fullScreenApi.cancelFullScreen(map._container);
+ } else {
+ L.DomUtil.removeClass(map._container, 'leaflet-pseudo-fullscreen');
+ }
+ map.invalidateSize();
+ map.fire('exitFullscreen');
+ map._exitFired = true;
+ map._isFullscreen = false;
+ }
+ else {
+ if (fullScreenApi.supportsFullScreen && !this.options.forcePseudoFullscreen) {
+ fullScreenApi.requestFullScreen(map._container);
+ } else {
+ L.DomUtil.addClass(map._container, 'leaflet-pseudo-fullscreen');
+ }
+ map.invalidateSize();
+ map.fire('enterFullscreen');
+ map._isFullscreen = true;
+ }
+ },
+
+ _handleEscKey: function () {
+ var map = this._map;
+ if (!fullScreenApi.isFullScreen(map) && !map._exitFired) {
+ map.fire('exitFullscreen');
+ map._exitFired = true;
+ map._isFullscreen = false;
+ }
+ }
+});
+
+L.Map.addInitHook(function () {
+ if (this.options.fullscreenControl) {
+ this.fullscreenControl = L.control.fullscreen(this.options.fullscreenControlOptions);
+ this.addControl(this.fullscreenControl);
+ }
+});
+
+L.control.fullscreen = function (options) {
+ return new L.Control.FullScreen(options);
+};
+
+/*
+Native FullScreen JavaScript API
+-------------
+Assumes Mozilla naming conventions instead of W3C for now
+
+source : http://johndyer.name/native-fullscreen-javascript-api-plus-jquery-plugin/
+
+*/
+
+ var
+ fullScreenApi = {
+ supportsFullScreen: false,
+ isFullScreen: function() { return false; },
+ requestFullScreen: function() {},
+ cancelFullScreen: function() {},
+ fullScreenEventName: '',
+ prefix: ''
+ },
+ browserPrefixes = 'webkit moz o ms khtml'.split(' ');
+
+ // check for native support
+ if (typeof document.exitFullscreen !== 'undefined') {
+ fullScreenApi.supportsFullScreen = true;
+ } else {
+ // check for fullscreen support by vendor prefix
+ for (var i = 0, il = browserPrefixes.length; i < il; i++ ) {
+ fullScreenApi.prefix = browserPrefixes[i];
+ if (typeof document[fullScreenApi.prefix + 'CancelFullScreen' ] !== 'undefined' ) {
+ fullScreenApi.supportsFullScreen = true;
+ break;
+ }
+ }
+ }
+
+ // update methods to do something useful
+ if (fullScreenApi.supportsFullScreen) {
+ fullScreenApi.fullScreenEventName = fullScreenApi.prefix + 'fullscreenchange';
+ fullScreenApi.isFullScreen = function() {
+ switch (this.prefix) {
+ case '':
+ return document.fullScreen;
+ case 'webkit':
+ return document.webkitIsFullScreen;
+ default:
+ return document[this.prefix + 'FullScreen'];
+ }
+ };
+ fullScreenApi.requestFullScreen = function(el) {
+ return (this.prefix === '') ? el.requestFullscreen() : el[this.prefix + 'RequestFullScreen']();
+ };
+ fullScreenApi.cancelFullScreen = function(el) {
+ return (this.prefix === '') ? document.exitFullscreen() : document[this.prefix + 'CancelFullScreen']();
+ };
+ }
+
+ // jQuery plugin
+ if (typeof jQuery !== 'undefined') {
+ jQuery.fn.requestFullScreen = function() {
+ return this.each(function() {
+ var el = jQuery(this);
+ if (fullScreenApi.supportsFullScreen) {
+ fullScreenApi.requestFullScreen(el);
+ }
+ });
+ };
+ }
+
+ // export api
+ window.fullScreenApi = fullScreenApi;
+})();
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/LICENSE b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/LICENSE
new file mode 100644
index 00000000..07ddddcc
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2013, Bruno Bergot
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without modification, are
+permitted provided that the following conditions are met:
+
+ 1. Redistributions of source code must retain the above copyright notice, this list of
+ conditions and the following disclaimer.
+
+ 2. Redistributions in binary form must reproduce the above copyright notice, this list
+ of conditions and the following disclaimer in the documentation and/or other materials
+ provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
+EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
+TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/README.md b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/README.md
new file mode 100644
index 00000000..a111801f
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/README.md
@@ -0,0 +1,68 @@
+Leaflet.Control.FullScreen
+============
+
+What ?
+------
+
+Simple plugin for Leaflet that adds fullscreen button to your maps.
+
+Inspired by http://elidupuis.github.com/leaflet.zoomfs/
+
+Use the native javascript fullscreen API http://johndyer.name/native-fullscreen-javascript-api-plus-jquery-plugin/
+
+Released under the MIT License http://opensource.org/licenses/mit-license.php
+
+How ?
+------
+
+Include Control.FullScreen.js and Control.FullScreen.css in your page:
+
+``` html
+ <link rel="stylesheet" href="Control.FullScreen.css" />
+ <script src="Control.FullScreen.js"></script>
+```
+
+Add the fullscreen control to the map:
+
+``` js
+var map = new L.Map('map', {
+ fullscreenControl: true,
+ fullscreenControlOptions: {
+ position: 'topleft'
+ }
+});
+```
+
+If your map have a zoomControl the fullscreen button will be added at the bottom of this one.
+
+If your map doesn't have a zoomContron the fullscreen button will be added to topleft corner of the map (same as the zoomcontrol).
+
+__Events and options__:
+
+``` js
+// create a fullscreen button and add it to the map
+L.control.fullscreen({
+ position: 'topleft', // change the position of the button can be topleft, topright, bottomright or bottomleft, defaut topleft
+ title: 'Show me the fullscreen !', // change the title of the button, default Full Screen
+ forceSeparateButton: true, // force seperate button to detach from zoom buttons, default false
+ forcePseudoFullscreen: true // force use of pseudo full screen even if full screen API is available, default false
+}).addTo(map);
+
+// events are fired when entering or exiting fullscreen.
+map.on('enterFullscreen', function(){
+ console.log('entered fullscreen');
+});
+
+map.on('exitFullscreen', function(){
+ console.log('exited fullscreen');
+});
+```
+
+Where ?
+------
+
+Source code : https://github.com/brunob/leaflet.fullscreen
+
+Downloads : https://github.com/brunob/leaflet.fullscreen/releases
+
+Demo : http://brunob.github.com/leaflet.fullscreen/
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/bower.json b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/bower.json
new file mode 100644
index 00000000..6de9eee8
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/bower.json
@@ -0,0 +1,30 @@
+{
+ "name": "leaflet.fullscreen",
+ "version": "1.1.4",
+ "homepage": "https://github.com/brunob/leaflet.fullscreen",
+ "authors": [
+ "brunob <brunobergot@gmail.com>"
+ ],
+ "description": "Leaflet.Control.FullScreen for Leaflet",
+ "main": [
+ "Control.FullScreen.js",
+ "Control.FullScreen.css",
+ "icon-fullscreen.png",
+ "icon-fullscreen-2x.png"
+ ],
+ "keywords": [
+ "leaflet",
+ "plugins",
+ "maps",
+ "fullscreen"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests",
+ "index.html"
+ ]
+}
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen-2x.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen-2x.png
new file mode 100644
index 00000000..7320d953
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen-2x.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen.png
new file mode 100644
index 00000000..17478145
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/icon-fullscreen.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/index.html b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/index.html
new file mode 100644
index 00000000..87b345c4
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/index.html
@@ -0,0 +1,48 @@
+<!DOCTYPE html>
+<html>
+<head>
+ <meta charset='utf-8'>
+ <title>Leaflet.Control.FullScreen Demo</title>
+ <link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7/leaflet.css" />
+ <style type="text/css">
+ #map { width: 700px; height: 433px; }
+ .leaflet-control-zoom-fullscreen { background-image: url(icon-fullscreen.png); }
+ /* on selector per rule as explained here : http://www.sitepoint.com/html5-full-screen-api/ */
+ #map:-webkit-full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
+ #map:-moz-full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
+ #map:full-screen { width: 100% !important; height: 100% !important; z-index: 99999; }
+ .leaflet-pseudo-fullscreen { position: fixed !important; width: 100% !important; height: 100% !important; top: 0px !important; left: 0px !important; z-index: 99999; }
+ </style>
+ <script src="http://cdn.leafletjs.com/leaflet-0.7/leaflet.js"></script>
+ <script src="Control.FullScreen.js"></script>
+</head>
+<body>
+
+ <div id="map"></div>
+
+ <script>
+ var base = new L.TileLayer('http://{s}.www.toolserver.org/tiles/bw-mapnik/{z}/{x}/{y}.png', {
+ maxZoom: 18,
+ attribution: '&copy; <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, <a href="http://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>'
+ });
+
+ var map = new L.Map('map', {
+ layers: [base],
+ center: new L.LatLng(48.5, -4.5),
+ zoom: 5,
+ fullscreenControl: true,
+ fullscreenControlOptions: { // optional
+ title:"Show me the fullscreen !"
+ }
+ });
+
+ // detect fullscreen toggling
+ map.on('enterFullscreen', function(){
+ if(window.console) window.console.log('enterFullscreen');
+ });
+ map.on('exitFullscreen', function(){
+ if(window.console) window.console.log('exitFullscreen');
+ });
+ </script>
+</body>
+</html>
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/package.json b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/package.json
new file mode 100644
index 00000000..e0c9aa7b
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.fullscreen/package.json
@@ -0,0 +1,25 @@
+{
+ "name": "leaflet.fullscreen",
+ "version": "1.1.4",
+ "description": "Simple plugin for Leaflet that adds fullscreen button to your maps.",
+ "main": "Control.FullScreen.js",
+ "scripts": {
+ "test": "jshint Control.FullScreen.js"
+ },
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/brunob/leaflet.fullscreen.git"
+ },
+ "keywords": [
+ "leaflet",
+ "plugins",
+ "maps",
+ "fullscreen"
+ ],
+ "devDependencies": {
+ "jshint": "2.5.0"
+ },
+ "author": "b_b",
+ "license": "MIT License",
+ "readmeFilename": "README.md"
+}
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/MarkerCluster.css b/www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/MarkerCluster.css
new file mode 100644
index 00000000..c60d71b7
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/MarkerCluster.css
@@ -0,0 +1,14 @@
+.leaflet-cluster-anim .leaflet-marker-icon, .leaflet-cluster-anim .leaflet-marker-shadow {
+ -webkit-transition: -webkit-transform 0.3s ease-out, opacity 0.3s ease-in;
+ -moz-transition: -moz-transform 0.3s ease-out, opacity 0.3s ease-in;
+ -o-transition: -o-transform 0.3s ease-out, opacity 0.3s ease-in;
+ transition: transform 0.3s ease-out, opacity 0.3s ease-in;
+}
+
+.leaflet-cluster-spider-leg {
+ /* stroke-dashoffset (duration and function) should match with leaflet-marker-icon transform in order to track it exactly */
+ -webkit-transition: -webkit-stroke-dashoffset 0.3s ease-out, -webkit-stroke-opacity 0.3s ease-in;
+ -moz-transition: -moz-stroke-dashoffset 0.3s ease-out, -moz-stroke-opacity 0.3s ease-in;
+ -o-transition: -o-stroke-dashoffset 0.3s ease-out, -o-stroke-opacity 0.3s ease-in;
+ transition: stroke-dashoffset 0.3s ease-out, stroke-opacity 0.3s ease-in;
+}
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/leaflet.markercluster.js b/www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/leaflet.markercluster.js
new file mode 100644
index 00000000..ed22dc07
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet.markercluster/leaflet.markercluster.js
@@ -0,0 +1,3 @@
+!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e.Leaflet=e.Leaflet||{},e.Leaflet.markercluster=e.Leaflet.markercluster||{}))}(this,function(e){"use strict";var t=L.MarkerClusterGroup=L.FeatureGroup.extend({options:{maxClusterRadius:80,iconCreateFunction:null,clusterPane:L.Marker.prototype.options.pane,spiderfyOnMaxZoom:!0,showCoverageOnHover:!0,zoomToBoundsOnClick:!0,singleMarkerMode:!1,disableClusteringAtZoom:null,removeOutsideVisibleBounds:!0,animate:!0,animateAddingMarkers:!1,spiderfyDistanceMultiplier:1,spiderLegPolylineOptions:{weight:1.5,color:"#222",opacity:.5},chunkedLoading:!1,chunkInterval:200,chunkDelay:50,chunkProgress:null,polygonOptions:{}},initialize:function(e){L.Util.setOptions(this,e),this.options.iconCreateFunction||(this.options.iconCreateFunction=this._defaultIconCreateFunction),this._featureGroup=L.featureGroup(),this._featureGroup.addEventParent(this),this._nonPointGroup=L.featureGroup(),this._nonPointGroup.addEventParent(this),this._inZoomAnimation=0,this._needsClustering=[],this._needsRemoving=[],this._currentShownBounds=null,this._queue=[],this._childMarkerEventHandlers={dragstart:this._childMarkerDragStart,move:this._childMarkerMoved,dragend:this._childMarkerDragEnd};var t=L.DomUtil.TRANSITION&&this.options.animate;L.extend(this,t?this._withAnimation:this._noAnimation),this._markerCluster=t?L.MarkerCluster:L.MarkerClusterNonAnimated},addLayer:function(e){if(e instanceof L.LayerGroup)return this.addLayers([e]);if(!e.getLatLng)return this._nonPointGroup.addLayer(e),this.fire("layeradd",{layer:e}),this;if(!this._map)return this._needsClustering.push(e),this.fire("layeradd",{layer:e}),this;if(this.hasLayer(e))return this;this._unspiderfy&&this._unspiderfy(),this._addLayer(e,this._maxZoom),this.fire("layeradd",{layer:e}),this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons();var t=e,i=this._zoom;if(e.__parent)for(;t.__parent._zoom>=i;)t=t.__parent;return this._currentShownBounds.contains(t.getLatLng())&&(this.options.animateAddingMarkers?this._animationAddLayer(e,t):this._animationAddLayerNonAnimated(e,t)),this},removeLayer:function(e){return e instanceof L.LayerGroup?this.removeLayers([e]):e.getLatLng?this._map?e.__parent?(this._unspiderfy&&(this._unspiderfy(),this._unspiderfyLayer(e)),this._removeLayer(e,!0),this.fire("layerremove",{layer:e}),this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons(),e.off(this._childMarkerEventHandlers,this),this._featureGroup.hasLayer(e)&&(this._featureGroup.removeLayer(e),e.clusterShow&&e.clusterShow()),this):this:(!this._arraySplice(this._needsClustering,e)&&this.hasLayer(e)&&this._needsRemoving.push({layer:e,latlng:e._latlng}),this.fire("layerremove",{layer:e}),this):(this._nonPointGroup.removeLayer(e),this.fire("layerremove",{layer:e}),this)},addLayers:function(e,t){if(!L.Util.isArray(e))return this.addLayer(e);var i,n=this._featureGroup,r=this._nonPointGroup,s=this.options.chunkedLoading,o=this.options.chunkInterval,a=this.options.chunkProgress,h=e.length,l=0,u=!0;if(this._map){var _=(new Date).getTime(),d=L.bind(function(){for(var c=(new Date).getTime();h>l;l++){if(s&&0===l%200){var p=(new Date).getTime()-c;if(p>o)break}if(i=e[l],i instanceof L.LayerGroup)u&&(e=e.slice(),u=!1),this._extractNonGroupLayers(i,e),h=e.length;else if(i.getLatLng){if(!this.hasLayer(i)&&(this._addLayer(i,this._maxZoom),t||this.fire("layeradd",{layer:i}),i.__parent&&2===i.__parent.getChildCount())){var f=i.__parent.getAllChildMarkers(),m=f[0]===i?f[1]:f[0];n.removeLayer(m)}}else r.addLayer(i),t||this.fire("layeradd",{layer:i})}a&&a(l,h,(new Date).getTime()-_),l===h?(this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons(),this._topClusterLevel._recursivelyAddChildrenToMap(null,this._zoom,this._currentShownBounds)):setTimeout(d,this.options.chunkDelay)},this);d()}else for(var c=this._needsClustering;h>l;l++)i=e[l],i instanceof L.LayerGroup?(u&&(e=e.slice(),u=!1),this._extractNonGroupLayers(i,e),h=e.length):i.getLatLng?this.hasLayer(i)||c.push(i):r.addLayer(i);return this},removeLayers:function(e){var t,i,n=e.length,r=this._featureGroup,s=this._nonPointGroup,o=!0;if(!this._map){for(t=0;n>t;t++)i=e[t],i instanceof L.LayerGroup?(o&&(e=e.slice(),o=!1),this._extractNonGroupLayers(i,e),n=e.length):(this._arraySplice(this._needsClustering,i),s.removeLayer(i),this.hasLayer(i)&&this._needsRemoving.push({layer:i,latlng:i._latlng}),this.fire("layerremove",{layer:i}));return this}if(this._unspiderfy){this._unspiderfy();var a=e.slice(),h=n;for(t=0;h>t;t++)i=a[t],i instanceof L.LayerGroup?(this._extractNonGroupLayers(i,a),h=a.length):this._unspiderfyLayer(i)}for(t=0;n>t;t++)i=e[t],i instanceof L.LayerGroup?(o&&(e=e.slice(),o=!1),this._extractNonGroupLayers(i,e),n=e.length):i.__parent?(this._removeLayer(i,!0,!0),this.fire("layerremove",{layer:i}),r.hasLayer(i)&&(r.removeLayer(i),i.clusterShow&&i.clusterShow())):(s.removeLayer(i),this.fire("layerremove",{layer:i}));return this._topClusterLevel._recalculateBounds(),this._refreshClustersIcons(),this._topClusterLevel._recursivelyAddChildrenToMap(null,this._zoom,this._currentShownBounds),this},clearLayers:function(){return this._map||(this._needsClustering=[],delete this._gridClusters,delete this._gridUnclustered),this._noanimationUnspiderfy&&this._noanimationUnspiderfy(),this._featureGroup.clearLayers(),this._nonPointGroup.clearLayers(),this.eachLayer(function(e){e.off(this._childMarkerEventHandlers,this),delete e.__parent},this),this._map&&this._generateInitialClusters(),this},getBounds:function(){var e=new L.LatLngBounds;this._topClusterLevel&&e.extend(this._topClusterLevel._bounds);for(var t=this._needsClustering.length-1;t>=0;t--)e.extend(this._needsClustering[t].getLatLng());return e.extend(this._nonPointGroup.getBounds()),e},eachLayer:function(e,t){var i,n,r,s=this._needsClustering.slice(),o=this._needsRemoving;for(this._topClusterLevel&&this._topClusterLevel.getAllChildMarkers(s),n=s.length-1;n>=0;n--){for(i=!0,r=o.length-1;r>=0;r--)if(o[r].layer===s[n]){i=!1;break}i&&e.call(t,s[n])}this._nonPointGroup.eachLayer(e,t)},getLayers:function(){var e=[];return this.eachLayer(function(t){e.push(t)}),e},getLayer:function(e){var t=null;return e=parseInt(e,10),this.eachLayer(function(i){L.stamp(i)===e&&(t=i)}),t},hasLayer:function(e){if(!e)return!1;var t,i=this._needsClustering;for(t=i.length-1;t>=0;t--)if(i[t]===e)return!0;for(i=this._needsRemoving,t=i.length-1;t>=0;t--)if(i[t].layer===e)return!1;return!(!e.__parent||e.__parent._group!==this)||this._nonPointGroup.hasLayer(e)},zoomToShowLayer:function(e,t){"function"!=typeof t&&(t=function(){});var i=function(){!e._icon&&!e.__parent._icon||this._inZoomAnimation||(this._map.off("moveend",i,this),this.off("animationend",i,this),e._icon?t():e.__parent._icon&&(this.once("spiderfied",t,this),e.__parent.spiderfy()))};e._icon&&this._map.getBounds().contains(e.getLatLng())?t():e.__parent._zoom<Math.round(this._map._zoom)?(this._map.on("moveend",i,this),this._map.panTo(e.getLatLng())):(this._map.on("moveend",i,this),this.on("animationend",i,this),e.__parent.zoomToBounds())},onAdd:function(e){this._map=e;var t,i,n;if(!isFinite(this._map.getMaxZoom()))throw"Map has no maxZoom specified";for(this._featureGroup.addTo(e),this._nonPointGroup.addTo(e),this._gridClusters||this._generateInitialClusters(),this._maxLat=e.options.crs.projection.MAX_LATITUDE,t=0,i=this._needsRemoving.length;i>t;t++)n=this._needsRemoving[t],n.newlatlng=n.layer._latlng,n.layer._latlng=n.latlng;for(t=0,i=this._needsRemoving.length;i>t;t++)n=this._needsRemoving[t],this._removeLayer(n.layer,!0),n.layer._latlng=n.newlatlng;this._needsRemoving=[],this._zoom=Math.round(this._map._zoom),this._currentShownBounds=this._getExpandedVisibleBounds(),this._map.on("zoomend",this._zoomEnd,this),this._map.on("moveend",this._moveEnd,this),this._spiderfierOnAdd&&this._spiderfierOnAdd(),this._bindEvents(),i=this._needsClustering,this._needsClustering=[],this.addLayers(i,!0)},onRemove:function(e){e.off("zoomend",this._zoomEnd,this),e.off("moveend",this._moveEnd,this),this._unbindEvents(),this._map._mapPane.className=this._map._mapPane.className.replace(" leaflet-cluster-anim",""),this._spiderfierOnRemove&&this._spiderfierOnRemove(),delete this._maxLat,this._hideCoverage(),this._featureGroup.remove(),this._nonPointGroup.remove(),this._featureGroup.clearLayers(),this._map=null},getVisibleParent:function(e){for(var t=e;t&&!t._icon;)t=t.__parent;return t||null},_arraySplice:function(e,t){for(var i=e.length-1;i>=0;i--)if(e[i]===t)return e.splice(i,1),!0},_removeFromGridUnclustered:function(e,t){for(var i=this._map,n=this._gridUnclustered,r=Math.floor(this._map.getMinZoom());t>=r&&n[t].removeObject(e,i.project(e.getLatLng(),t));t--);},_childMarkerDragStart:function(e){e.target.__dragStart=e.target._latlng},_childMarkerMoved:function(e){if(!this._ignoreMove&&!e.target.__dragStart){var t=e.target._popup&&e.target._popup.isOpen();this._moveChild(e.target,e.oldLatLng,e.latlng),t&&e.target.openPopup()}},_moveChild:function(e,t,i){e._latlng=t,this.removeLayer(e),e._latlng=i,this.addLayer(e)},_childMarkerDragEnd:function(e){e.target.__dragStart&&this._moveChild(e.target,e.target.__dragStart,e.target._latlng),delete e.target.__dragStart},_removeLayer:function(e,t,i){var n=this._gridClusters,r=this._gridUnclustered,s=this._featureGroup,o=this._map,a=Math.floor(this._map.getMinZoom());t&&this._removeFromGridUnclustered(e,this._maxZoom);var h,l=e.__parent,u=l._markers;for(this._arraySplice(u,e);l&&(l._childCount--,l._boundsNeedUpdate=!0,!(l._zoom<a));)t&&l._childCount<=1?(h=l._markers[0]===e?l._markers[1]:l._markers[0],n[l._zoom].removeObject(l,o.project(l._cLatLng,l._zoom)),r[l._zoom].addObject(h,o.project(h.getLatLng(),l._zoom)),this._arraySplice(l.__parent._childClusters,l),l.__parent._markers.push(h),h.__parent=l.__parent,l._icon&&(s.removeLayer(l),i||s.addLayer(h))):l._iconNeedsUpdate=!0,l=l.__parent;delete e.__parent},_isOrIsParent:function(e,t){for(;t;){if(e===t)return!0;t=t.parentNode}return!1},fire:function(e,t,i){if(t&&t.layer instanceof L.MarkerCluster){if(t.originalEvent&&this._isOrIsParent(t.layer._icon,t.originalEvent.relatedTarget))return;e="cluster"+e}L.FeatureGroup.prototype.fire.call(this,e,t,i)},listens:function(e,t){return L.FeatureGroup.prototype.listens.call(this,e,t)||L.FeatureGroup.prototype.listens.call(this,"cluster"+e,t)},_defaultIconCreateFunction:function(e){var t=e.getChildCount(),i=" marker-cluster-";return i+=10>t?"small":100>t?"medium":"large",new L.DivIcon({html:"<div><span>"+t+"</span></div>",className:"marker-cluster"+i,iconSize:new L.Point(40,40)})},_bindEvents:function(){var e=this._map,t=this.options.spiderfyOnMaxZoom,i=this.options.showCoverageOnHover,n=this.options.zoomToBoundsOnClick;(t||n)&&this.on("clusterclick",this._zoomOrSpiderfy,this),i&&(this.on("clustermouseover",this._showCoverage,this),this.on("clustermouseout",this._hideCoverage,this),e.on("zoomend",this._hideCoverage,this))},_zoomOrSpiderfy:function(e){for(var t=e.layer,i=t;1===i._childClusters.length;)i=i._childClusters[0];i._zoom===this._maxZoom&&i._childCount===t._childCount&&this.options.spiderfyOnMaxZoom?t.spiderfy():this.options.zoomToBoundsOnClick&&t.zoomToBounds(),e.originalEvent&&13===e.originalEvent.keyCode&&this._map._container.focus()},_showCoverage:function(e){var t=this._map;this._inZoomAnimation||(this._shownPolygon&&t.removeLayer(this._shownPolygon),e.layer.getChildCount()>2&&e.layer!==this._spiderfied&&(this._shownPolygon=new L.Polygon(e.layer.getConvexHull(),this.options.polygonOptions),t.addLayer(this._shownPolygon)))},_hideCoverage:function(){this._shownPolygon&&(this._map.removeLayer(this._shownPolygon),this._shownPolygon=null)},_unbindEvents:function(){var e=this.options.spiderfyOnMaxZoom,t=this.options.showCoverageOnHover,i=this.options.zoomToBoundsOnClick,n=this._map;(e||i)&&this.off("clusterclick",this._zoomOrSpiderfy,this),t&&(this.off("clustermouseover",this._showCoverage,this),this.off("clustermouseout",this._hideCoverage,this),n.off("zoomend",this._hideCoverage,this))},_zoomEnd:function(){this._map&&(this._mergeSplitClusters(),this._zoom=Math.round(this._map._zoom),this._currentShownBounds=this._getExpandedVisibleBounds())},_moveEnd:function(){if(!this._inZoomAnimation){var e=this._getExpandedVisibleBounds();this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),this._zoom,e),this._topClusterLevel._recursivelyAddChildrenToMap(null,Math.round(this._map._zoom),e),this._currentShownBounds=e}},_generateInitialClusters:function(){var e=Math.ceil(this._map.getMaxZoom()),t=Math.floor(this._map.getMinZoom()),i=this.options.maxClusterRadius,n=i;"function"!=typeof i&&(n=function(){return i}),null!==this.options.disableClusteringAtZoom&&(e=this.options.disableClusteringAtZoom-1),this._maxZoom=e,this._gridClusters={},this._gridUnclustered={};for(var r=e;r>=t;r--)this._gridClusters[r]=new L.DistanceGrid(n(r)),this._gridUnclustered[r]=new L.DistanceGrid(n(r));this._topClusterLevel=new this._markerCluster(this,t-1)},_addLayer:function(e,t){var i,n,r=this._gridClusters,s=this._gridUnclustered,o=Math.floor(this._map.getMinZoom());for(this.options.singleMarkerMode&&this._overrideMarkerIcon(e),e.on(this._childMarkerEventHandlers,this);t>=o;t--){i=this._map.project(e.getLatLng(),t);var a=r[t].getNearObject(i);if(a)return a._addChild(e),e.__parent=a,void 0;if(a=s[t].getNearObject(i)){var h=a.__parent;h&&this._removeLayer(a,!1);var l=new this._markerCluster(this,t,a,e);r[t].addObject(l,this._map.project(l._cLatLng,t)),a.__parent=l,e.__parent=l;var u=l;for(n=t-1;n>h._zoom;n--)u=new this._markerCluster(this,n,u),r[n].addObject(u,this._map.project(a.getLatLng(),n));return h._addChild(u),this._removeFromGridUnclustered(a,t),void 0}s[t].addObject(e,i)}this._topClusterLevel._addChild(e),e.__parent=this._topClusterLevel},_refreshClustersIcons:function(){this._featureGroup.eachLayer(function(e){e instanceof L.MarkerCluster&&e._iconNeedsUpdate&&e._updateIcon()})},_enqueue:function(e){this._queue.push(e),this._queueTimeout||(this._queueTimeout=setTimeout(L.bind(this._processQueue,this),300))},_processQueue:function(){for(var e=0;e<this._queue.length;e++)this._queue[e].call(this);this._queue.length=0,clearTimeout(this._queueTimeout),this._queueTimeout=null},_mergeSplitClusters:function(){var e=Math.round(this._map._zoom);this._processQueue(),this._zoom<e&&this._currentShownBounds.intersects(this._getExpandedVisibleBounds())?(this._animationStart(),this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),this._zoom,this._getExpandedVisibleBounds()),this._animationZoomIn(this._zoom,e)):this._zoom>e?(this._animationStart(),this._animationZoomOut(this._zoom,e)):this._moveEnd()},_getExpandedVisibleBounds:function(){return this.options.removeOutsideVisibleBounds?L.Browser.mobile?this._checkBoundsMaxLat(this._map.getBounds()):this._checkBoundsMaxLat(this._map.getBounds().pad(1)):this._mapBoundsInfinite},_checkBoundsMaxLat:function(e){var t=this._maxLat;return void 0!==t&&(e.getNorth()>=t&&(e._northEast.lat=1/0),e.getSouth()<=-t&&(e._southWest.lat=-1/0)),e},_animationAddLayerNonAnimated:function(e,t){if(t===e)this._featureGroup.addLayer(e);else if(2===t._childCount){t._addToMap();var i=t.getAllChildMarkers();this._featureGroup.removeLayer(i[0]),this._featureGroup.removeLayer(i[1])}else t._updateIcon()},_extractNonGroupLayers:function(e,t){var i,n=e.getLayers(),r=0;for(t=t||[];r<n.length;r++)i=n[r],i instanceof L.LayerGroup?this._extractNonGroupLayers(i,t):t.push(i);return t},_overrideMarkerIcon:function(e){var t=e.options.icon=this.options.iconCreateFunction({getChildCount:function(){return 1},getAllChildMarkers:function(){return[e]}});return t}});L.MarkerClusterGroup.include({_mapBoundsInfinite:new L.LatLngBounds(new L.LatLng(-1/0,-1/0),new L.LatLng(1/0,1/0))}),L.MarkerClusterGroup.include({_noAnimation:{_animationStart:function(){},_animationZoomIn:function(e,t){this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),e),this._topClusterLevel._recursivelyAddChildrenToMap(null,t,this._getExpandedVisibleBounds()),this.fire("animationend")},_animationZoomOut:function(e,t){this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),e),this._topClusterLevel._recursivelyAddChildrenToMap(null,t,this._getExpandedVisibleBounds()),this.fire("animationend")},_animationAddLayer:function(e,t){this._animationAddLayerNonAnimated(e,t)}},_withAnimation:{_animationStart:function(){this._map._mapPane.className+=" leaflet-cluster-anim",this._inZoomAnimation++},_animationZoomIn:function(e,t){var i,n=this._getExpandedVisibleBounds(),r=this._featureGroup,s=Math.floor(this._map.getMinZoom());this._ignoreMove=!0,this._topClusterLevel._recursively(n,e,s,function(s){var o,a=s._latlng,h=s._markers;for(n.contains(a)||(a=null),s._isSingleParent()&&e+1===t?(r.removeLayer(s),s._recursivelyAddChildrenToMap(null,t,n)):(s.clusterHide(),s._recursivelyAddChildrenToMap(a,t,n)),i=h.length-1;i>=0;i--)o=h[i],n.contains(o._latlng)||r.removeLayer(o)}),this._forceLayout(),this._topClusterLevel._recursivelyBecomeVisible(n,t),r.eachLayer(function(e){e instanceof L.MarkerCluster||!e._icon||e.clusterShow()}),this._topClusterLevel._recursively(n,e,t,function(e){e._recursivelyRestoreChildPositions(t)}),this._ignoreMove=!1,this._enqueue(function(){this._topClusterLevel._recursively(n,e,s,function(e){r.removeLayer(e),e.clusterShow()}),this._animationEnd()})},_animationZoomOut:function(e,t){this._animationZoomOutSingle(this._topClusterLevel,e-1,t),this._topClusterLevel._recursivelyAddChildrenToMap(null,t,this._getExpandedVisibleBounds()),this._topClusterLevel._recursivelyRemoveChildrenFromMap(this._currentShownBounds,Math.floor(this._map.getMinZoom()),e,this._getExpandedVisibleBounds())},_animationAddLayer:function(e,t){var i=this,n=this._featureGroup;n.addLayer(e),t!==e&&(t._childCount>2?(t._updateIcon(),this._forceLayout(),this._animationStart(),e._setPos(this._map.latLngToLayerPoint(t.getLatLng())),e.clusterHide(),this._enqueue(function(){n.removeLayer(e),e.clusterShow(),i._animationEnd()})):(this._forceLayout(),i._animationStart(),i._animationZoomOutSingle(t,this._map.getMaxZoom(),this._zoom)))}},_animationZoomOutSingle:function(e,t,i){var n=this._getExpandedVisibleBounds(),r=Math.floor(this._map.getMinZoom());e._recursivelyAnimateChildrenInAndAddSelfToMap(n,r,t+1,i);var s=this;this._forceLayout(),e._recursivelyBecomeVisible(n,i),this._enqueue(function(){if(1===e._childCount){var o=e._markers[0];this._ignoreMove=!0,o.setLatLng(o.getLatLng()),this._ignoreMove=!1,o.clusterShow&&o.clusterShow()}else e._recursively(n,i,r,function(e){e._recursivelyRemoveChildrenFromMap(n,r,t+1)});s._animationEnd()})},_animationEnd:function(){this._map&&(this._map._mapPane.className=this._map._mapPane.className.replace(" leaflet-cluster-anim","")),this._inZoomAnimation--,this.fire("animationend")},_forceLayout:function(){L.Util.falseFn(document.body.offsetWidth)}}),L.markerClusterGroup=function(e){return new L.MarkerClusterGroup(e)};var i=L.MarkerCluster=L.Marker.extend({options:L.Icon.prototype.options,initialize:function(e,t,i,n){L.Marker.prototype.initialize.call(this,i?i._cLatLng||i.getLatLng():new L.LatLng(0,0),{icon:this,pane:e.options.clusterPane}),this._group=e,this._zoom=t,this._markers=[],this._childClusters=[],this._childCount=0,this._iconNeedsUpdate=!0,this._boundsNeedUpdate=!0,this._bounds=new L.LatLngBounds,i&&this._addChild(i),n&&this._addChild(n)},getAllChildMarkers:function(e){e=e||[];for(var t=this._childClusters.length-1;t>=0;t--)this._childClusters[t].getAllChildMarkers(e);for(var i=this._markers.length-1;i>=0;i--)e.push(this._markers[i]);return e},getChildCount:function(){return this._childCount},zoomToBounds:function(e){for(var t,i=this._childClusters.slice(),n=this._group._map,r=n.getBoundsZoom(this._bounds),s=this._zoom+1,o=n.getZoom();i.length>0&&r>s;){s++;var a=[];for(t=0;t<i.length;t++)a=a.concat(i[t]._childClusters);i=a}r>s?this._group._map.setView(this._latlng,s):o>=r?this._group._map.setView(this._latlng,o+1):this._group._map.fitBounds(this._bounds,e)},getBounds:function(){var e=new L.LatLngBounds;return e.extend(this._bounds),e},_updateIcon:function(){this._iconNeedsUpdate=!0,this._icon&&this.setIcon(this)},createIcon:function(){return this._iconNeedsUpdate&&(this._iconObj=this._group.options.iconCreateFunction(this),this._iconNeedsUpdate=!1),this._iconObj.createIcon()},createShadow:function(){return this._iconObj.createShadow()},_addChild:function(e,t){this._iconNeedsUpdate=!0,this._boundsNeedUpdate=!0,this._setClusterCenter(e),e instanceof L.MarkerCluster?(t||(this._childClusters.push(e),e.__parent=this),this._childCount+=e._childCount):(t||this._markers.push(e),this._childCount++),this.__parent&&this.__parent._addChild(e,!0)},_setClusterCenter:function(e){this._cLatLng||(this._cLatLng=e._cLatLng||e._latlng)},_resetBounds:function(){var e=this._bounds;e._southWest&&(e._southWest.lat=1/0,e._southWest.lng=1/0),e._northEast&&(e._northEast.lat=-1/0,e._northEast.lng=-1/0)},_recalculateBounds:function(){var e,t,i,n,r=this._markers,s=this._childClusters,o=0,a=0,h=this._childCount;if(0!==h){for(this._resetBounds(),e=0;e<r.length;e++)i=r[e]._latlng,this._bounds.extend(i),o+=i.lat,a+=i.lng;for(e=0;e<s.length;e++)t=s[e],t._boundsNeedUpdate&&t._recalculateBounds(),this._bounds.extend(t._bounds),i=t._wLatLng,n=t._childCount,o+=i.lat*n,a+=i.lng*n;this._latlng=this._wLatLng=new L.LatLng(o/h,a/h),this._boundsNeedUpdate=!1}},_addToMap:function(e){e&&(this._backupLatlng=this._latlng,this.setLatLng(e)),this._group._featureGroup.addLayer(this)},_recursivelyAnimateChildrenIn:function(e,t,i){this._recursively(e,this._group._map.getMinZoom(),i-1,function(e){var i,n,r=e._markers;for(i=r.length-1;i>=0;i--)n=r[i],n._icon&&(n._setPos(t),n.clusterHide())},function(e){var i,n,r=e._childClusters;for(i=r.length-1;i>=0;i--)n=r[i],n._icon&&(n._setPos(t),n.clusterHide())})},_recursivelyAnimateChildrenInAndAddSelfToMap:function(e,t,i,n){this._recursively(e,n,t,function(r){r._recursivelyAnimateChildrenIn(e,r._group._map.latLngToLayerPoint(r.getLatLng()).round(),i),r._isSingleParent()&&i-1===n?(r.clusterShow(),r._recursivelyRemoveChildrenFromMap(e,t,i)):r.clusterHide(),r._addToMap()})},_recursivelyBecomeVisible:function(e,t){this._recursively(e,this._group._map.getMinZoom(),t,null,function(e){e.clusterShow()})},_recursivelyAddChildrenToMap:function(e,t,i){this._recursively(i,this._group._map.getMinZoom()-1,t,function(n){if(t!==n._zoom)for(var r=n._markers.length-1;r>=0;r--){var s=n._markers[r];i.contains(s._latlng)&&(e&&(s._backupLatlng=s.getLatLng(),s.setLatLng(e),s.clusterHide&&s.clusterHide()),n._group._featureGroup.addLayer(s))}},function(t){t._addToMap(e)})},_recursivelyRestoreChildPositions:function(e){for(var t=this._markers.length-1;t>=0;t--){var i=this._markers[t];i._backupLatlng&&(i.setLatLng(i._backupLatlng),delete i._backupLatlng)}if(e-1===this._zoom)for(var n=this._childClusters.length-1;n>=0;n--)this._childClusters[n]._restorePosition();else for(var r=this._childClusters.length-1;r>=0;r--)this._childClusters[r]._recursivelyRestoreChildPositions(e)},_restorePosition:function(){this._backupLatlng&&(this.setLatLng(this._backupLatlng),delete this._backupLatlng)},_recursivelyRemoveChildrenFromMap:function(e,t,i,n){var r,s;this._recursively(e,t-1,i-1,function(e){for(s=e._markers.length-1;s>=0;s--)r=e._markers[s],n&&n.contains(r._latlng)||(e._group._featureGroup.removeLayer(r),r.clusterShow&&r.clusterShow())},function(e){for(s=e._childClusters.length-1;s>=0;s--)r=e._childClusters[s],n&&n.contains(r._latlng)||(e._group._featureGroup.removeLayer(r),r.clusterShow&&r.clusterShow())})},_recursively:function(e,t,i,n,r){var s,o,a=this._childClusters,h=this._zoom;if(h>=t&&(n&&n(this),r&&h===i&&r(this)),t>h||i>h)for(s=a.length-1;s>=0;s--)o=a[s],e.intersects(o._bounds)&&o._recursively(e,t,i,n,r)},_isSingleParent:function(){return this._childClusters.length>0&&this._childClusters[0]._childCount===this._childCount}});L.Marker.include({clusterHide:function(){return this.options.opacityWhenUnclustered=this.options.opacity||1,this.setOpacity(0)},clusterShow:function(){var e=this.setOpacity(this.options.opacity||this.options.opacityWhenUnclustered);return delete this.options.opacityWhenUnclustered,e}}),L.DistanceGrid=function(e){this._cellSize=e,this._sqCellSize=e*e,this._grid={},this._objectPoint={}},L.DistanceGrid.prototype={addObject:function(e,t){var i=this._getCoord(t.x),n=this._getCoord(t.y),r=this._grid,s=r[n]=r[n]||{},o=s[i]=s[i]||[],a=L.Util.stamp(e);this._objectPoint[a]=t,o.push(e)},updateObject:function(e,t){this.removeObject(e),this.addObject(e,t)},removeObject:function(e,t){var i,n,r=this._getCoord(t.x),s=this._getCoord(t.y),o=this._grid,a=o[s]=o[s]||{},h=a[r]=a[r]||[];for(delete this._objectPoint[L.Util.stamp(e)],i=0,n=h.length;n>i;i++)if(h[i]===e)return h.splice(i,1),1===n&&delete a[r],!0},eachObject:function(e,t){var i,n,r,s,o,a,h,l=this._grid;for(i in l){o=l[i];for(n in o)for(a=o[n],r=0,s=a.length;s>r;r++)h=e.call(t,a[r]),h&&(r--,s--)}},getNearObject:function(e){var t,i,n,r,s,o,a,h,l=this._getCoord(e.x),u=this._getCoord(e.y),_=this._objectPoint,d=this._sqCellSize,c=null;for(t=u-1;u+1>=t;t++)if(r=this._grid[t])for(i=l-1;l+1>=i;i++)if(s=r[i])for(n=0,o=s.length;o>n;n++)a=s[n],h=this._sqDist(_[L.Util.stamp(a)],e),(d>h||d>=h&&null===c)&&(d=h,c=a);return c},_getCoord:function(e){var t=Math.floor(e/this._cellSize);return isFinite(t)?t:e},_sqDist:function(e,t){var i=t.x-e.x,n=t.y-e.y;return i*i+n*n}},function(){L.QuickHull={getDistant:function(e,t){var i=t[1].lat-t[0].lat,n=t[0].lng-t[1].lng;return n*(e.lat-t[0].lat)+i*(e.lng-t[0].lng)},findMostDistantPointFromBaseLine:function(e,t){var i,n,r,s=0,o=null,a=[];for(i=t.length-1;i>=0;i--)n=t[i],r=this.getDistant(n,e),r>0&&(a.push(n),r>s&&(s=r,o=n));return{maxPoint:o,newPoints:a}},buildConvexHull:function(e,t){var i=[],n=this.findMostDistantPointFromBaseLine(e,t);return n.maxPoint?(i=i.concat(this.buildConvexHull([e[0],n.maxPoint],n.newPoints)),i=i.concat(this.buildConvexHull([n.maxPoint,e[1]],n.newPoints))):[e[0]]},getConvexHull:function(e){var t,i=!1,n=!1,r=!1,s=!1,o=null,a=null,h=null,l=null,u=null,_=null;for(t=e.length-1;t>=0;t--){var d=e[t];(i===!1||d.lat>i)&&(o=d,i=d.lat),(n===!1||d.lat<n)&&(a=d,n=d.lat),(r===!1||d.lng>r)&&(h=d,r=d.lng),(s===!1||d.lng<s)&&(l=d,s=d.lng)}n!==i?(_=a,u=o):(_=l,u=h);var c=[].concat(this.buildConvexHull([_,u],e),this.buildConvexHull([u,_],e));return c}}}(),L.MarkerCluster.include({getConvexHull:function(){var e,t,i=this.getAllChildMarkers(),n=[];for(t=i.length-1;t>=0;t--)e=i[t].getLatLng(),n.push(e);return L.QuickHull.getConvexHull(n)}}),L.MarkerCluster.include({_2PI:2*Math.PI,_circleFootSeparation:25,_circleStartAngle:0,_spiralFootSeparation:28,_spiralLengthStart:11,_spiralLengthFactor:5,_circleSpiralSwitchover:9,spiderfy:function(){if(this._group._spiderfied!==this&&!this._group._inZoomAnimation){var e,t=this.getAllChildMarkers(),i=this._group,n=i._map,r=n.latLngToLayerPoint(this._latlng);this._group._unspiderfy(),this._group._spiderfied=this,t.length>=this._circleSpiralSwitchover?e=this._generatePointsSpiral(t.length,r):(r.y+=10,e=this._generatePointsCircle(t.length,r)),this._animationSpiderfy(t,e)}},unspiderfy:function(e){this._group._inZoomAnimation||(this._animationUnspiderfy(e),this._group._spiderfied=null)},_generatePointsCircle:function(e,t){var i,n,r=this._group.options.spiderfyDistanceMultiplier*this._circleFootSeparation*(2+e),s=r/this._2PI,o=this._2PI/e,a=[];for(s=Math.max(s,35),a.length=e,i=0;e>i;i++)n=this._circleStartAngle+i*o,a[i]=new L.Point(t.x+s*Math.cos(n),t.y+s*Math.sin(n))._round();return a},_generatePointsSpiral:function(e,t){var i,n=this._group.options.spiderfyDistanceMultiplier,r=n*this._spiralLengthStart,s=n*this._spiralFootSeparation,o=n*this._spiralLengthFactor*this._2PI,a=0,h=[];for(h.length=e,i=e;i>=0;i--)e>i&&(h[i]=new L.Point(t.x+r*Math.cos(a),t.y+r*Math.sin(a))._round()),a+=s/r+5e-4*i,r+=o/a;return h},_noanimationUnspiderfy:function(){var e,t,i=this._group,n=i._map,r=i._featureGroup,s=this.getAllChildMarkers();for(i._ignoreMove=!0,this.setOpacity(1),t=s.length-1;t>=0;t--)e=s[t],r.removeLayer(e),e._preSpiderfyLatlng&&(e.setLatLng(e._preSpiderfyLatlng),delete e._preSpiderfyLatlng),e.setZIndexOffset&&e.setZIndexOffset(0),e._spiderLeg&&(n.removeLayer(e._spiderLeg),delete e._spiderLeg);i.fire("unspiderfied",{cluster:this,markers:s}),i._ignoreMove=!1,i._spiderfied=null}}),L.MarkerClusterNonAnimated=L.MarkerCluster.extend({_animationSpiderfy:function(e,t){var i,n,r,s,o=this._group,a=o._map,h=o._featureGroup,l=this._group.options.spiderLegPolylineOptions;for(o._ignoreMove=!0,i=0;i<e.length;i++)s=a.layerPointToLatLng(t[i]),n=e[i],r=new L.Polyline([this._latlng,s],l),a.addLayer(r),n._spiderLeg=r,n._preSpiderfyLatlng=n._latlng,n.setLatLng(s),n.setZIndexOffset&&n.setZIndexOffset(1e6),h.addLayer(n);this.setOpacity(.3),o._ignoreMove=!1,o.fire("spiderfied",{cluster:this,markers:e})},_animationUnspiderfy:function(){this._noanimationUnspiderfy()}}),L.MarkerCluster.include({_animationSpiderfy:function(e,t){var i,n,r,s,o,a,h=this,l=this._group,u=l._map,_=l._featureGroup,d=this._latlng,c=u.latLngToLayerPoint(d),p=L.Path.SVG,f=L.extend({},this._group.options.spiderLegPolylineOptions),m=f.opacity;for(void 0===m&&(m=L.MarkerClusterGroup.prototype.options.spiderLegPolylineOptions.opacity),p?(f.opacity=0,f.className=(f.className||"")+" leaflet-cluster-spider-leg"):f.opacity=m,l._ignoreMove=!0,i=0;i<e.length;i++)n=e[i],a=u.layerPointToLatLng(t[i]),r=new L.Polyline([d,a],f),u.addLayer(r),n._spiderLeg=r,p&&(s=r._path,o=s.getTotalLength()+.1,s.style.strokeDasharray=o,s.style.strokeDashoffset=o),n.setZIndexOffset&&n.setZIndexOffset(1e6),n.clusterHide&&n.clusterHide(),_.addLayer(n),n._setPos&&n._setPos(c);for(l._forceLayout(),l._animationStart(),i=e.length-1;i>=0;i--)a=u.layerPointToLatLng(t[i]),n=e[i],n._preSpiderfyLatlng=n._latlng,n.setLatLng(a),n.clusterShow&&n.clusterShow(),p&&(r=n._spiderLeg,s=r._path,s.style.strokeDashoffset=0,r.setStyle({opacity:m}));this.setOpacity(.3),l._ignoreMove=!1,setTimeout(function(){l._animationEnd(),l.fire("spiderfied",{cluster:h,markers:e})},200)},_animationUnspiderfy:function(e){var t,i,n,r,s,o,a=this,h=this._group,l=h._map,u=h._featureGroup,_=e?l._latLngToNewLayerPoint(this._latlng,e.zoom,e.center):l.latLngToLayerPoint(this._latlng),d=this.getAllChildMarkers(),c=L.Path.SVG;for(h._ignoreMove=!0,h._animationStart(),this.setOpacity(1),i=d.length-1;i>=0;i--)t=d[i],t._preSpiderfyLatlng&&(t.closePopup(),t.setLatLng(t._preSpiderfyLatlng),delete t._preSpiderfyLatlng,o=!0,t._setPos&&(t._setPos(_),o=!1),t.clusterHide&&(t.clusterHide(),o=!1),o&&u.removeLayer(t),c&&(n=t._spiderLeg,r=n._path,s=r.getTotalLength()+.1,r.style.strokeDashoffset=s,n.setStyle({opacity:0})));h._ignoreMove=!1,setTimeout(function(){var e=0;for(i=d.length-1;i>=0;i--)t=d[i],t._spiderLeg&&e++;for(i=d.length-1;i>=0;i--)t=d[i],t._spiderLeg&&(t.clusterShow&&t.clusterShow(),t.setZIndexOffset&&t.setZIndexOffset(0),e>1&&u.removeLayer(t),l.removeLayer(t._spiderLeg),delete t._spiderLeg);h._animationEnd(),h.fire("unspiderfied",{cluster:a,markers:d})},200)}}),L.MarkerClusterGroup.include({_spiderfied:null,unspiderfy:function(){this._unspiderfy.apply(this,arguments)},_spiderfierOnAdd:function(){this._map.on("click",this._unspiderfyWrapper,this),this._map.options.zoomAnimation&&this._map.on("zoomstart",this._unspiderfyZoomStart,this),this._map.on("zoomend",this._noanimationUnspiderfy,this),L.Browser.touch||this._map.getRenderer(this)},_spiderfierOnRemove:function(){this._map.off("click",this._unspiderfyWrapper,this),this._map.off("zoomstart",this._unspiderfyZoomStart,this),this._map.off("zoomanim",this._unspiderfyZoomAnim,this),this._map.off("zoomend",this._noanimationUnspiderfy,this),this._noanimationUnspiderfy()
+},_unspiderfyZoomStart:function(){this._map&&this._map.on("zoomanim",this._unspiderfyZoomAnim,this)},_unspiderfyZoomAnim:function(e){L.DomUtil.hasClass(this._map._mapPane,"leaflet-touching")||(this._map.off("zoomanim",this._unspiderfyZoomAnim,this),this._unspiderfy(e))},_unspiderfyWrapper:function(){this._unspiderfy()},_unspiderfy:function(e){this._spiderfied&&this._spiderfied.unspiderfy(e)},_noanimationUnspiderfy:function(){this._spiderfied&&this._spiderfied._noanimationUnspiderfy()},_unspiderfyLayer:function(e){e._spiderLeg&&(this._featureGroup.removeLayer(e),e.clusterShow&&e.clusterShow(),e.setZIndexOffset&&e.setZIndexOffset(0),this._map.removeLayer(e._spiderLeg),delete e._spiderLeg)}}),L.MarkerClusterGroup.include({refreshClusters:function(e){return e?e instanceof L.MarkerClusterGroup?e=e._topClusterLevel.getAllChildMarkers():e instanceof L.LayerGroup?e=e._layers:e instanceof L.MarkerCluster?e=e.getAllChildMarkers():e instanceof L.Marker&&(e=[e]):e=this._topClusterLevel.getAllChildMarkers(),this._flagParentsIconsNeedUpdate(e),this._refreshClustersIcons(),this.options.singleMarkerMode&&this._refreshSingleMarkerModeMarkers(e),this},_flagParentsIconsNeedUpdate:function(e){var t,i;for(t in e)for(i=e[t].__parent;i;)i._iconNeedsUpdate=!0,i=i.__parent},_refreshSingleMarkerModeMarkers:function(e){var t,i;for(t in e)i=e[t],this.hasLayer(i)&&i.setIcon(this._overrideMarkerIcon(i))}}),L.Marker.include({refreshIconOptions:function(e,t){var i=this.options.icon;return L.setOptions(i,e),this.setIcon(i),t&&this.__parent&&this.__parent._group.refreshClusters(this),this}}),e.MarkerClusterGroup=t,e.MarkerCluster=i});
+//# sourceMappingURL=leaflet.markercluster.js.map \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers-2x.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers-2x.png
new file mode 100644
index 00000000..200c333d
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers-2x.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers.png
new file mode 100644
index 00000000..1a72e578
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/layers.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon-2x.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon-2x.png
new file mode 100644
index 00000000..e4abba3b
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon-2x.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon.png
new file mode 100644
index 00000000..950edf24
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-icon.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-shadow.png b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-shadow.png
new file mode 100644
index 00000000..9fd29795
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/images/marker-shadow.png
Binary files differ
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.css b/www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.css
new file mode 100644
index 00000000..a0932d57
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.css
@@ -0,0 +1,635 @@
+/* required styles */
+
+.leaflet-pane,
+.leaflet-tile,
+.leaflet-marker-icon,
+.leaflet-marker-shadow,
+.leaflet-tile-container,
+.leaflet-pane > svg,
+.leaflet-pane > canvas,
+.leaflet-zoom-box,
+.leaflet-image-layer,
+.leaflet-layer {
+ position: absolute;
+ left: 0;
+ top: 0;
+ }
+.leaflet-container {
+ overflow: hidden;
+ }
+.leaflet-tile,
+.leaflet-marker-icon,
+.leaflet-marker-shadow {
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ user-select: none;
+ -webkit-user-drag: none;
+ }
+/* Safari renders non-retina tile on retina better with this, but Chrome is worse */
+.leaflet-safari .leaflet-tile {
+ image-rendering: -webkit-optimize-contrast;
+ }
+/* hack that prevents hw layers "stretching" when loading new tiles */
+.leaflet-safari .leaflet-tile-container {
+ width: 1600px;
+ height: 1600px;
+ -webkit-transform-origin: 0 0;
+ }
+.leaflet-marker-icon,
+.leaflet-marker-shadow {
+ display: block;
+ }
+/* .leaflet-container svg: reset svg max-width decleration shipped in Joomla! (joomla.org) 3.x */
+/* .leaflet-container img: map is broken in FF if you have max-width: 100% on tiles */
+.leaflet-container .leaflet-overlay-pane svg,
+.leaflet-container .leaflet-marker-pane img,
+.leaflet-container .leaflet-shadow-pane img,
+.leaflet-container .leaflet-tile-pane img,
+.leaflet-container img.leaflet-image-layer,
+.leaflet-container .leaflet-tile {
+ max-width: none !important;
+ max-height: none !important;
+ }
+
+.leaflet-container.leaflet-touch-zoom {
+ -ms-touch-action: pan-x pan-y;
+ touch-action: pan-x pan-y;
+ }
+.leaflet-container.leaflet-touch-drag {
+ -ms-touch-action: pinch-zoom;
+ /* Fallback for FF which doesn't support pinch-zoom */
+ touch-action: none;
+ touch-action: pinch-zoom;
+}
+.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom {
+ -ms-touch-action: none;
+ touch-action: none;
+}
+.leaflet-container {
+ -webkit-tap-highlight-color: transparent;
+}
+.leaflet-container a {
+ -webkit-tap-highlight-color: rgba(51, 181, 229, 0.4);
+}
+.leaflet-tile {
+ filter: inherit;
+ visibility: hidden;
+ }
+.leaflet-tile-loaded {
+ visibility: inherit;
+ }
+.leaflet-zoom-box {
+ width: 0;
+ height: 0;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ z-index: 800;
+ }
+/* workaround for https://bugzilla.mozilla.org/show_bug.cgi?id=888319 */
+.leaflet-overlay-pane svg {
+ -moz-user-select: none;
+ }
+
+.leaflet-pane { z-index: 400; }
+
+.leaflet-tile-pane { z-index: 200; }
+.leaflet-overlay-pane { z-index: 400; }
+.leaflet-shadow-pane { z-index: 500; }
+.leaflet-marker-pane { z-index: 600; }
+.leaflet-tooltip-pane { z-index: 650; }
+.leaflet-popup-pane { z-index: 700; }
+
+.leaflet-map-pane canvas { z-index: 100; }
+.leaflet-map-pane svg { z-index: 200; }
+
+.leaflet-vml-shape {
+ width: 1px;
+ height: 1px;
+ }
+.lvml {
+ behavior: url(#default#VML);
+ display: inline-block;
+ position: absolute;
+ }
+
+
+/* control positioning */
+
+.leaflet-control {
+ position: relative;
+ z-index: 800;
+ pointer-events: visiblePainted; /* IE 9-10 doesn't have auto */
+ pointer-events: auto;
+ }
+.leaflet-top,
+.leaflet-bottom {
+ position: absolute;
+ z-index: 1000;
+ pointer-events: none;
+ }
+.leaflet-top {
+ top: 0;
+ }
+.leaflet-right {
+ right: 0;
+ }
+.leaflet-bottom {
+ bottom: 0;
+ }
+.leaflet-left {
+ left: 0;
+ }
+.leaflet-control {
+ float: left;
+ clear: both;
+ }
+.leaflet-right .leaflet-control {
+ float: right;
+ }
+.leaflet-top .leaflet-control {
+ margin-top: 10px;
+ }
+.leaflet-bottom .leaflet-control {
+ margin-bottom: 10px;
+ }
+.leaflet-left .leaflet-control {
+ margin-left: 10px;
+ }
+.leaflet-right .leaflet-control {
+ margin-right: 10px;
+ }
+
+
+/* zoom and fade animations */
+
+.leaflet-fade-anim .leaflet-tile {
+ will-change: opacity;
+ }
+.leaflet-fade-anim .leaflet-popup {
+ opacity: 0;
+ -webkit-transition: opacity 0.2s linear;
+ -moz-transition: opacity 0.2s linear;
+ transition: opacity 0.2s linear;
+ }
+.leaflet-fade-anim .leaflet-map-pane .leaflet-popup {
+ opacity: 1;
+ }
+.leaflet-zoom-animated {
+ -webkit-transform-origin: 0 0;
+ -ms-transform-origin: 0 0;
+ transform-origin: 0 0;
+ }
+.leaflet-zoom-anim .leaflet-zoom-animated {
+ will-change: transform;
+ }
+.leaflet-zoom-anim .leaflet-zoom-animated {
+ -webkit-transition: -webkit-transform 0.25s cubic-bezier(0,0,0.25,1);
+ -moz-transition: -moz-transform 0.25s cubic-bezier(0,0,0.25,1);
+ transition: transform 0.25s cubic-bezier(0,0,0.25,1);
+ }
+.leaflet-zoom-anim .leaflet-tile,
+.leaflet-pan-anim .leaflet-tile {
+ -webkit-transition: none;
+ -moz-transition: none;
+ transition: none;
+ }
+
+.leaflet-zoom-anim .leaflet-zoom-hide {
+ visibility: hidden;
+ }
+
+
+/* cursors */
+
+.leaflet-interactive {
+ cursor: pointer;
+ }
+.leaflet-grab {
+ cursor: -webkit-grab;
+ cursor: -moz-grab;
+ cursor: grab;
+ }
+.leaflet-crosshair,
+.leaflet-crosshair .leaflet-interactive {
+ cursor: crosshair;
+ }
+.leaflet-popup-pane,
+.leaflet-control {
+ cursor: auto;
+ }
+.leaflet-dragging .leaflet-grab,
+.leaflet-dragging .leaflet-grab .leaflet-interactive,
+.leaflet-dragging .leaflet-marker-draggable {
+ cursor: move;
+ cursor: -webkit-grabbing;
+ cursor: -moz-grabbing;
+ cursor: grabbing;
+ }
+
+/* marker & overlays interactivity */
+.leaflet-marker-icon,
+.leaflet-marker-shadow,
+.leaflet-image-layer,
+.leaflet-pane > svg path,
+.leaflet-tile-container {
+ pointer-events: none;
+ }
+
+.leaflet-marker-icon.leaflet-interactive,
+.leaflet-image-layer.leaflet-interactive,
+.leaflet-pane > svg path.leaflet-interactive {
+ pointer-events: visiblePainted; /* IE 9-10 doesn't have auto */
+ pointer-events: auto;
+ }
+
+/* visual tweaks */
+
+.leaflet-container {
+ background: #ddd;
+ outline: 0;
+ }
+.leaflet-container a {
+ color: #0078A8;
+ }
+.leaflet-container a.leaflet-active {
+ outline: 2px solid orange;
+ }
+.leaflet-zoom-box {
+ border: 2px dotted #38f;
+ background: rgba(255,255,255,0.5);
+ }
+
+
+/* general typography */
+.leaflet-container {
+ font: 12px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif;
+ }
+
+
+/* general toolbar styles */
+
+.leaflet-bar {
+ box-shadow: 0 1px 5px rgba(0,0,0,0.65);
+ border-radius: 4px;
+ }
+.leaflet-bar a,
+.leaflet-bar a:hover {
+ background-color: #fff;
+ border-bottom: 1px solid #ccc;
+ width: 26px;
+ height: 26px;
+ line-height: 26px;
+ display: block;
+ text-align: center;
+ text-decoration: none;
+ color: black;
+ }
+.leaflet-bar a,
+.leaflet-control-layers-toggle {
+ background-position: 50% 50%;
+ background-repeat: no-repeat;
+ display: block;
+ }
+.leaflet-bar a:hover {
+ background-color: #f4f4f4;
+ }
+.leaflet-bar a:first-child {
+ border-top-left-radius: 4px;
+ border-top-right-radius: 4px;
+ }
+.leaflet-bar a:last-child {
+ border-bottom-left-radius: 4px;
+ border-bottom-right-radius: 4px;
+ border-bottom: none;
+ }
+.leaflet-bar a.leaflet-disabled {
+ cursor: default;
+ background-color: #f4f4f4;
+ color: #bbb;
+ }
+
+.leaflet-touch .leaflet-bar a {
+ width: 30px;
+ height: 30px;
+ line-height: 30px;
+ }
+.leaflet-touch .leaflet-bar a:first-child {
+ border-top-left-radius: 2px;
+ border-top-right-radius: 2px;
+ }
+.leaflet-touch .leaflet-bar a:last-child {
+ border-bottom-left-radius: 2px;
+ border-bottom-right-radius: 2px;
+ }
+
+/* zoom control */
+
+.leaflet-control-zoom-in,
+.leaflet-control-zoom-out {
+ font: bold 18px 'Lucida Console', Monaco, monospace;
+ text-indent: 1px;
+ }
+
+.leaflet-touch .leaflet-control-zoom-in, .leaflet-touch .leaflet-control-zoom-out {
+ font-size: 22px;
+ }
+
+
+/* layers control */
+
+.leaflet-control-layers {
+ box-shadow: 0 1px 5px rgba(0,0,0,0.4);
+ background: #fff;
+ border-radius: 5px;
+ }
+.leaflet-control-layers-toggle {
+ background-image: url(images/layers.png);
+ width: 36px;
+ height: 36px;
+ }
+.leaflet-retina .leaflet-control-layers-toggle {
+ background-image: url(images/layers-2x.png);
+ background-size: 26px 26px;
+ }
+.leaflet-touch .leaflet-control-layers-toggle {
+ width: 44px;
+ height: 44px;
+ }
+.leaflet-control-layers .leaflet-control-layers-list,
+.leaflet-control-layers-expanded .leaflet-control-layers-toggle {
+ display: none;
+ }
+.leaflet-control-layers-expanded .leaflet-control-layers-list {
+ display: block;
+ position: relative;
+ }
+.leaflet-control-layers-expanded {
+ padding: 6px 10px 6px 6px;
+ color: #333;
+ background: #fff;
+ }
+.leaflet-control-layers-scrollbar {
+ overflow-y: scroll;
+ overflow-x: hidden;
+ padding-right: 5px;
+ }
+.leaflet-control-layers-selector {
+ margin-top: 2px;
+ position: relative;
+ top: 1px;
+ }
+.leaflet-control-layers label {
+ display: block;
+ }
+.leaflet-control-layers-separator {
+ height: 0;
+ border-top: 1px solid #ddd;
+ margin: 5px -10px 5px -6px;
+ }
+
+/* Default icon URLs */
+.leaflet-default-icon-path {
+ background-image: url(images/marker-icon.png);
+ }
+
+
+/* attribution and scale controls */
+
+.leaflet-container .leaflet-control-attribution {
+ background: #fff;
+ background: rgba(255, 255, 255, 0.7);
+ margin: 0;
+ }
+.leaflet-control-attribution,
+.leaflet-control-scale-line {
+ padding: 0 5px;
+ color: #333;
+ }
+.leaflet-control-attribution a {
+ text-decoration: none;
+ }
+.leaflet-control-attribution a:hover {
+ text-decoration: underline;
+ }
+.leaflet-container .leaflet-control-attribution,
+.leaflet-container .leaflet-control-scale {
+ font-size: 11px;
+ }
+.leaflet-left .leaflet-control-scale {
+ margin-left: 5px;
+ }
+.leaflet-bottom .leaflet-control-scale {
+ margin-bottom: 5px;
+ }
+.leaflet-control-scale-line {
+ border: 2px solid #777;
+ border-top: none;
+ line-height: 1.1;
+ padding: 2px 5px 1px;
+ font-size: 11px;
+ white-space: nowrap;
+ overflow: hidden;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+
+ background: #fff;
+ background: rgba(255, 255, 255, 0.5);
+ }
+.leaflet-control-scale-line:not(:first-child) {
+ border-top: 2px solid #777;
+ border-bottom: none;
+ margin-top: -2px;
+ }
+.leaflet-control-scale-line:not(:first-child):not(:last-child) {
+ border-bottom: 2px solid #777;
+ }
+
+.leaflet-touch .leaflet-control-attribution,
+.leaflet-touch .leaflet-control-layers,
+.leaflet-touch .leaflet-bar {
+ box-shadow: none;
+ }
+.leaflet-touch .leaflet-control-layers,
+.leaflet-touch .leaflet-bar {
+ border: 2px solid rgba(0,0,0,0.2);
+ background-clip: padding-box;
+ }
+
+
+/* popup */
+
+.leaflet-popup {
+ position: absolute;
+ text-align: center;
+ margin-bottom: 20px;
+ }
+.leaflet-popup-content-wrapper {
+ padding: 1px;
+ text-align: left;
+ border-radius: 12px;
+ }
+.leaflet-popup-content {
+ margin: 13px 19px;
+ line-height: 1.4;
+ }
+.leaflet-popup-content p {
+ margin: 18px 0;
+ }
+.leaflet-popup-tip-container {
+ width: 40px;
+ height: 20px;
+ position: absolute;
+ left: 50%;
+ margin-left: -20px;
+ overflow: hidden;
+ pointer-events: none;
+ }
+.leaflet-popup-tip {
+ width: 17px;
+ height: 17px;
+ padding: 1px;
+
+ margin: -10px auto 0;
+
+ -webkit-transform: rotate(45deg);
+ -moz-transform: rotate(45deg);
+ -ms-transform: rotate(45deg);
+ transform: rotate(45deg);
+ }
+.leaflet-popup-content-wrapper,
+.leaflet-popup-tip {
+ background: white;
+ color: #333;
+ box-shadow: 0 3px 14px rgba(0,0,0,0.4);
+ }
+.leaflet-container a.leaflet-popup-close-button {
+ position: absolute;
+ top: 0;
+ right: 0;
+ padding: 4px 4px 0 0;
+ border: none;
+ text-align: center;
+ width: 18px;
+ height: 14px;
+ font: 16px/14px Tahoma, Verdana, sans-serif;
+ color: #c3c3c3;
+ text-decoration: none;
+ font-weight: bold;
+ background: transparent;
+ }
+.leaflet-container a.leaflet-popup-close-button:hover {
+ color: #999;
+ }
+.leaflet-popup-scrolled {
+ overflow: auto;
+ border-bottom: 1px solid #ddd;
+ border-top: 1px solid #ddd;
+ }
+
+.leaflet-oldie .leaflet-popup-content-wrapper {
+ zoom: 1;
+ }
+.leaflet-oldie .leaflet-popup-tip {
+ width: 24px;
+ margin: 0 auto;
+
+ -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";
+ filter: progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678);
+ }
+.leaflet-oldie .leaflet-popup-tip-container {
+ margin-top: -1px;
+ }
+
+.leaflet-oldie .leaflet-control-zoom,
+.leaflet-oldie .leaflet-control-layers,
+.leaflet-oldie .leaflet-popup-content-wrapper,
+.leaflet-oldie .leaflet-popup-tip {
+ border: 1px solid #999;
+ }
+
+
+/* div icon */
+
+.leaflet-div-icon {
+ background: #fff;
+ border: 1px solid #666;
+ }
+
+
+/* Tooltip */
+/* Base styles for the element that has a tooltip */
+.leaflet-tooltip {
+ position: absolute;
+ padding: 6px;
+ background-color: #fff;
+ border: 1px solid #fff;
+ border-radius: 3px;
+ color: #222;
+ white-space: nowrap;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+ user-select: none;
+ pointer-events: none;
+ box-shadow: 0 1px 3px rgba(0,0,0,0.4);
+ }
+.leaflet-tooltip.leaflet-clickable {
+ cursor: pointer;
+ pointer-events: auto;
+ }
+.leaflet-tooltip-top:before,
+.leaflet-tooltip-bottom:before,
+.leaflet-tooltip-left:before,
+.leaflet-tooltip-right:before {
+ position: absolute;
+ pointer-events: none;
+ border: 6px solid transparent;
+ background: transparent;
+ content: "";
+ }
+
+/* Directions */
+
+.leaflet-tooltip-bottom {
+ margin-top: 6px;
+}
+.leaflet-tooltip-top {
+ margin-top: -6px;
+}
+.leaflet-tooltip-bottom:before,
+.leaflet-tooltip-top:before {
+ left: 50%;
+ margin-left: -6px;
+ }
+.leaflet-tooltip-top:before {
+ bottom: 0;
+ margin-bottom: -12px;
+ border-top-color: #fff;
+ }
+.leaflet-tooltip-bottom:before {
+ top: 0;
+ margin-top: -12px;
+ margin-left: -6px;
+ border-bottom-color: #fff;
+ }
+.leaflet-tooltip-left {
+ margin-left: -6px;
+}
+.leaflet-tooltip-right {
+ margin-left: 6px;
+}
+.leaflet-tooltip-left:before,
+.leaflet-tooltip-right:before {
+ top: 50%;
+ margin-top: -6px;
+ }
+.leaflet-tooltip-left:before {
+ right: 0;
+ margin-right: -12px;
+ border-left-color: #fff;
+ }
+.leaflet-tooltip-right:before {
+ left: 0;
+ margin-left: -12px;
+ border-right-color: #fff;
+ }
diff --git a/www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.js b/www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.js
new file mode 100644
index 00000000..3b628aba
--- /dev/null
+++ b/www/wiki/extensions/Maps/resources/leaflet/leaflet/leaflet.js
@@ -0,0 +1,5 @@
+/* @preserve
+ * Leaflet 1.3.4+Detached: 0e566b2ad5e696ba9f79a9d48a7e51c8f4892441.0e566b2, a JS library for interactive maps. http://leafletjs.com
+ * (c) 2010-2018 Vladimir Agafonkin, (c) 2010-2011 CloudMade
+ */
+!function(t,i){"object"==typeof exports&&"undefined"!=typeof module?i(exports):"function"==typeof define&&define.amd?define(["exports"],i):i(t.L={})}(this,function(t){"use strict";function i(t){var i,e,n,o;for(e=1,n=arguments.length;e<n;e++){o=arguments[e];for(i in o)t[i]=o[i]}return t}function e(t,i){var e=Array.prototype.slice;if(t.bind)return t.bind.apply(t,e.call(arguments,1));var n=e.call(arguments,2);return function(){return t.apply(i,n.length?n.concat(e.call(arguments)):arguments)}}function n(t){return t._leaflet_id=t._leaflet_id||++ei,t._leaflet_id}function o(t,i,e){var n,o,s,r;return r=function(){n=!1,o&&(s.apply(e,o),o=!1)},s=function(){n?o=arguments:(t.apply(e,arguments),setTimeout(r,i),n=!0)}}function s(t,i,e){var n=i[1],o=i[0],s=n-o;return t===n&&e?t:((t-o)%s+s)%s+o}function r(){return!1}function a(t,i){var e=Math.pow(10,void 0===i?6:i);return Math.round(t*e)/e}function h(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}function u(t){return h(t).split(/\s+/)}function l(t,i){t.hasOwnProperty("options")||(t.options=t.options?ii(t.options):{});for(var e in i)t.options[e]=i[e];return t.options}function c(t,i,e){var n=[];for(var o in t)n.push(encodeURIComponent(e?o.toUpperCase():o)+"="+encodeURIComponent(t[o]));return(i&&-1!==i.indexOf("?")?"&":"?")+n.join("&")}function _(t,i){return t.replace(ni,function(t,e){var n=i[e];if(void 0===n)throw new Error("No value provided for variable "+t);return"function"==typeof n&&(n=n(i)),n})}function d(t,i){for(var e=0;e<t.length;e++)if(t[e]===i)return e;return-1}function p(t){return window["webkit"+t]||window["moz"+t]||window["ms"+t]}function m(t){var i=+new Date,e=Math.max(0,16-(i-ri));return ri=i+e,window.setTimeout(t,e)}function f(t,i,n){if(!n||ai!==m)return ai.call(window,e(t,i));t.call(i)}function g(t){t&&hi.call(window,t)}function v(){}function y(t){if("undefined"!=typeof L&&L&&L.Mixin){t=oi(t)?t:[t];for(var i=0;i<t.length;i++)t[i]===L.Mixin.Events&&console.warn("Deprecated include of L.Mixin.Events: this property will be removed in future releases, please inherit from L.Evented instead.",(new Error).stack)}}function x(t,i,e){this.x=e?Math.round(t):t,this.y=e?Math.round(i):i}function w(t,i,e){return t instanceof x?t:oi(t)?new x(t[0],t[1]):void 0===t||null===t?t:"object"==typeof t&&"x"in t&&"y"in t?new x(t.x,t.y):new x(t,i,e)}function P(t,i){if(t)for(var e=i?[t,i]:t,n=0,o=e.length;n<o;n++)this.extend(e[n])}function b(t,i){return!t||t instanceof P?t:new P(t,i)}function T(t,i){if(t)for(var e=i?[t,i]:t,n=0,o=e.length;n<o;n++)this.extend(e[n])}function z(t,i){return t instanceof T?t:new T(t,i)}function M(t,i,e){if(isNaN(t)||isNaN(i))throw new Error("Invalid LatLng object: ("+t+", "+i+")");this.lat=+t,this.lng=+i,void 0!==e&&(this.alt=+e)}function C(t,i,e){return t instanceof M?t:oi(t)&&"object"!=typeof t[0]?3===t.length?new M(t[0],t[1],t[2]):2===t.length?new M(t[0],t[1]):null:void 0===t||null===t?t:"object"==typeof t&&"lat"in t?new M(t.lat,"lng"in t?t.lng:t.lon,t.alt):void 0===i?null:new M(t,i,e)}function S(t,i,e,n){if(oi(t))return this._a=t[0],this._b=t[1],this._c=t[2],void(this._d=t[3]);this._a=t,this._b=i,this._c=e,this._d=n}function Z(t,i,e,n){return new S(t,i,e,n)}function E(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}function k(t,i){var e,n,o,s,r,a,h="";for(e=0,o=t.length;e<o;e++){for(n=0,s=(r=t[e]).length;n<s;n++)a=r[n],h+=(n?"L":"M")+a.x+" "+a.y;h+=i?Ji?"z":"x":""}return h||"M0 0"}function A(t){return navigator.userAgent.toLowerCase().indexOf(t)>=0}function B(t,i,e,n){return"touchstart"===i?O(t,e,n):"touchmove"===i?W(t,e,n):"touchend"===i&&H(t,e,n),this}function I(t,i,e){var n=t["_leaflet_"+i+e];return"touchstart"===i?t.removeEventListener(te,n,!1):"touchmove"===i?t.removeEventListener(ie,n,!1):"touchend"===i&&(t.removeEventListener(ee,n,!1),t.removeEventListener(ne,n,!1)),this}function O(t,i,n){var o=e(function(t){if("mouse"!==t.pointerType&&t.MSPOINTER_TYPE_MOUSE&&t.pointerType!==t.MSPOINTER_TYPE_MOUSE){if(!(oe.indexOf(t.target.tagName)<0))return;Pt(t)}j(t,i)});t["_leaflet_touchstart"+n]=o,t.addEventListener(te,o,!1),re||(document.documentElement.addEventListener(te,R,!0),document.documentElement.addEventListener(ie,N,!0),document.documentElement.addEventListener(ee,D,!0),document.documentElement.addEventListener(ne,D,!0),re=!0)}function R(t){se[t.pointerId]=t,ae++}function N(t){se[t.pointerId]&&(se[t.pointerId]=t)}function D(t){delete se[t.pointerId],ae--}function j(t,i){t.touches=[];for(var e in se)t.touches.push(se[e]);t.changedTouches=[t],i(t)}function W(t,i,e){var n=function(t){(t.pointerType!==t.MSPOINTER_TYPE_MOUSE&&"mouse"!==t.pointerType||0!==t.buttons)&&j(t,i)};t["_leaflet_touchmove"+e]=n,t.addEventListener(ie,n,!1)}function H(t,i,e){var n=function(t){j(t,i)};t["_leaflet_touchend"+e]=n,t.addEventListener(ee,n,!1),t.addEventListener(ne,n,!1)}function F(t,i,e){function n(t){var i;if(Vi){if(!bi||"mouse"===t.pointerType)return;i=ae}else i=t.touches.length;if(!(i>1)){var e=Date.now(),n=e-(s||e);r=t.touches?t.touches[0]:t,a=n>0&&n<=h,s=e}}function o(t){if(a&&!r.cancelBubble){if(Vi){if(!bi||"mouse"===t.pointerType)return;var e,n,o={};for(n in r)e=r[n],o[n]=e&&e.bind?e.bind(r):e;r=o}r.type="dblclick",i(r),s=null}}var s,r,a=!1,h=250;return t[le+he+e]=n,t[le+ue+e]=o,t[le+"dblclick"+e]=i,t.addEventListener(he,n,!1),t.addEventListener(ue,o,!1),t.addEventListener("dblclick",i,!1),this}function U(t,i){var e=t[le+he+i],n=t[le+ue+i],o=t[le+"dblclick"+i];return t.removeEventListener(he,e,!1),t.removeEventListener(ue,n,!1),bi||t.removeEventListener("dblclick",o,!1),this}function V(t){return"string"==typeof t?document.getElementById(t):t}function q(t,i){var e=t.style[i]||t.currentStyle&&t.currentStyle[i];if((!e||"auto"===e)&&document.defaultView){var n=document.defaultView.getComputedStyle(t,null);e=n?n[i]:null}return"auto"===e?null:e}function G(t,i,e){var n=document.createElement(t);return n.className=i||"",e&&e.appendChild(n),n}function K(t){var i=t.parentNode;i&&i.removeChild(t)}function Y(t){for(;t.firstChild;)t.removeChild(t.firstChild)}function X(t){var i=t.parentNode;i.lastChild!==t&&i.appendChild(t)}function J(t){var i=t.parentNode;i.firstChild!==t&&i.insertBefore(t,i.firstChild)}function $(t,i){if(void 0!==t.classList)return t.classList.contains(i);var e=et(t);return e.length>0&&new RegExp("(^|\\s)"+i+"(\\s|$)").test(e)}function Q(t,i){if(void 0!==t.classList)for(var e=u(i),n=0,o=e.length;n<o;n++)t.classList.add(e[n]);else if(!$(t,i)){var s=et(t);it(t,(s?s+" ":"")+i)}}function tt(t,i){void 0!==t.classList?t.classList.remove(i):it(t,h((" "+et(t)+" ").replace(" "+i+" "," ")))}function it(t,i){void 0===t.className.baseVal?t.className=i:t.className.baseVal=i}function et(t){return void 0===t.className.baseVal?t.className:t.className.baseVal}function nt(t,i){"opacity"in t.style?t.style.opacity=i:"filter"in t.style&&ot(t,i)}function ot(t,i){var e=!1,n="DXImageTransform.Microsoft.Alpha";try{e=t.filters.item(n)}catch(t){if(1===i)return}i=Math.round(100*i),e?(e.Enabled=100!==i,e.Opacity=i):t.style.filter+=" progid:"+n+"(opacity="+i+")"}function st(t){for(var i=document.documentElement.style,e=0;e<t.length;e++)if(t[e]in i)return t[e];return!1}function rt(t,i,e){var n=i||new x(0,0);t.style[ce]=(Ri?"translate("+n.x+"px,"+n.y+"px)":"translate3d("+n.x+"px,"+n.y+"px,0)")+(e?" scale("+e+")":"")}function at(t,i){t._leaflet_pos=i,ji?rt(t,i):(t.style.left=i.x+"px",t.style.top=i.y+"px")}function ht(t){return t._leaflet_pos||new x(0,0)}function ut(){mt(window,"dragstart",Pt)}function lt(){ft(window,"dragstart",Pt)}function ct(t){for(;-1===t.tabIndex;)t=t.parentNode;t.style&&(_t(),me=t,fe=t.style.outline,t.style.outline="none",mt(window,"keydown",_t))}function _t(){me&&(me.style.outline=fe,me=void 0,fe=void 0,ft(window,"keydown",_t))}function dt(t){do{t=t.parentNode}while(!(t.offsetWidth&&t.offsetHeight||t===document.body));return t}function pt(t){var i=t.getBoundingClientRect();return{x:i.width/t.offsetWidth||1,y:i.height/t.offsetHeight||1,boundingClientRect:i}}function mt(t,i,e,n){if("object"==typeof i)for(var o in i)gt(t,o,i[o],e);else for(var s=0,r=(i=u(i)).length;s<r;s++)gt(t,i[s],e,n);return this}function ft(t,i,e,n){if("object"==typeof i)for(var o in i)vt(t,o,i[o],e);else if(i)for(var s=0,r=(i=u(i)).length;s<r;s++)vt(t,i[s],e,n);else{for(var a in t[ye])vt(t,a,t[ye][a]);delete t[ye]}return this}function gt(t,i,e,o){var s=i+n(e)+(o?"_"+n(o):"");if(t[ye]&&t[ye][s])return this;var r=function(i){return e.call(o||t,i||window.event)},a=r;Vi&&0===i.indexOf("touch")?B(t,i,r,s):!qi||"dblclick"!==i||!F||Vi&&Ei?"addEventListener"in t?"mousewheel"===i?t.addEventListener("onwheel"in t?"wheel":"mousewheel",r,!1):"mouseenter"===i||"mouseleave"===i?(r=function(i){i=i||window.event,Ct(t,i)&&a(i)},t.addEventListener("mouseenter"===i?"mouseover":"mouseout",r,!1)):("click"===i&&zi&&(r=function(t){St(t,a)}),t.addEventListener(i,r,!1)):"attachEvent"in t&&t.attachEvent("on"+i,r):F(t,r,s),t[ye]=t[ye]||{},t[ye][s]=r}function vt(t,i,e,o){var s=i+n(e)+(o?"_"+n(o):""),r=t[ye]&&t[ye][s];if(!r)return this;Vi&&0===i.indexOf("touch")?I(t,i,s):!qi||"dblclick"!==i||!U||Vi&&Ei?"removeEventListener"in t?"mousewheel"===i?t.removeEventListener("onwheel"in t?"wheel":"mousewheel",r,!1):t.removeEventListener("mouseenter"===i?"mouseover":"mouseleave"===i?"mouseout":i,r,!1):"detachEvent"in t&&t.detachEvent("on"+i,r):U(t,s),t[ye][s]=null}function yt(t){return t.stopPropagation?t.stopPropagation():t.originalEvent?t.originalEvent._stopped=!0:t.cancelBubble=!0,Mt(t),this}function xt(t){return gt(t,"mousewheel",yt),this}function wt(t){return mt(t,"mousedown touchstart dblclick",yt),gt(t,"click",zt),this}function Pt(t){return t.preventDefault?t.preventDefault():t.returnValue=!1,this}function Lt(t){return Pt(t),yt(t),this}function bt(t,i){if(!i)return new x(t.clientX,t.clientY);var e=pt(i),n=e.boundingClientRect;return new x((t.clientX-n.left)/e.x-i.clientLeft,(t.clientY-n.top)/e.y-i.clientTop)}function Tt(t){return bi?t.wheelDeltaY/2:t.deltaY&&0===t.deltaMode?-t.deltaY/xe:t.deltaY&&1===t.deltaMode?20*-t.deltaY:t.deltaY&&2===t.deltaMode?60*-t.deltaY:t.deltaX||t.deltaZ?0:t.wheelDelta?(t.wheelDeltaY||t.wheelDelta)/2:t.detail&&Math.abs(t.detail)<32765?20*-t.detail:t.detail?t.detail/-32765*60:0}function zt(t){we[t.type]=!0}function Mt(t){var i=we[t.type];return we[t.type]=!1,i}function Ct(t,i){var e=i.relatedTarget;if(!e)return!0;try{for(;e&&e!==t;)e=e.parentNode}catch(t){return!1}return e!==t}function St(t,i){var e=t.timeStamp||t.originalEvent&&t.originalEvent.timeStamp,n=ge&&e-ge;n&&n>100&&n<500||t.target._simulatedClick&&!t._simulated?Lt(t):(ge=e,i(t))}function Zt(t,i){if(!i||!t.length)return t.slice();var e=i*i;return t=Bt(t,e),t=kt(t,e)}function Et(t,i,e){return Math.sqrt(Dt(t,i,e,!0))}function kt(t,i){var e=t.length,n=new(typeof Uint8Array!=void 0+""?Uint8Array:Array)(e);n[0]=n[e-1]=1,At(t,n,i,0,e-1);var o,s=[];for(o=0;o<e;o++)n[o]&&s.push(t[o]);return s}function At(t,i,e,n,o){var s,r,a,h=0;for(r=n+1;r<=o-1;r++)(a=Dt(t[r],t[n],t[o],!0))>h&&(s=r,h=a);h>e&&(i[s]=1,At(t,i,e,n,s),At(t,i,e,s,o))}function Bt(t,i){for(var e=[t[0]],n=1,o=0,s=t.length;n<s;n++)Nt(t[n],t[o])>i&&(e.push(t[n]),o=n);return o<s-1&&e.push(t[s-1]),e}function It(t,i,e,n,o){var s,r,a,h=n?ke:Rt(t,e),u=Rt(i,e);for(ke=u;;){if(!(h|u))return[t,i];if(h&u)return!1;a=Rt(r=Ot(t,i,s=h||u,e,o),e),s===h?(t=r,h=a):(i=r,u=a)}}function Ot(t,i,e,n,o){var s,r,a=i.x-t.x,h=i.y-t.y,u=n.min,l=n.max;return 8&e?(s=t.x+a*(l.y-t.y)/h,r=l.y):4&e?(s=t.x+a*(u.y-t.y)/h,r=u.y):2&e?(s=l.x,r=t.y+h*(l.x-t.x)/a):1&e&&(s=u.x,r=t.y+h*(u.x-t.x)/a),new x(s,r,o)}function Rt(t,i){var e=0;return t.x<i.min.x?e|=1:t.x>i.max.x&&(e|=2),t.y<i.min.y?e|=4:t.y>i.max.y&&(e|=8),e}function Nt(t,i){var e=i.x-t.x,n=i.y-t.y;return e*e+n*n}function Dt(t,i,e,n){var o,s=i.x,r=i.y,a=e.x-s,h=e.y-r,u=a*a+h*h;return u>0&&((o=((t.x-s)*a+(t.y-r)*h)/u)>1?(s=e.x,r=e.y):o>0&&(s+=a*o,r+=h*o)),a=t.x-s,h=t.y-r,n?a*a+h*h:new x(s,r)}function jt(t){return!oi(t[0])||"object"!=typeof t[0][0]&&void 0!==t[0][0]}function Wt(t){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),jt(t)}function Ht(t,i,e){var n,o,s,r,a,h,u,l,c,_=[1,4,2,8];for(o=0,u=t.length;o<u;o++)t[o]._code=Rt(t[o],i);for(r=0;r<4;r++){for(l=_[r],n=[],o=0,s=(u=t.length)-1;o<u;s=o++)a=t[o],h=t[s],a._code&l?h._code&l||((c=Ot(h,a,l,i,e))._code=Rt(c,i),n.push(c)):(h._code&l&&((c=Ot(h,a,l,i,e))._code=Rt(c,i),n.push(c)),n.push(a));t=n}return t}function Ft(t,i){var e,n,o,s,r="Feature"===t.type?t.geometry:t,a=r?r.coordinates:null,h=[],u=i&&i.pointToLayer,l=i&&i.coordsToLatLng||Ut;if(!a&&!r)return null;switch(r.type){case"Point":return e=l(a),u?u(t,e):new $e(e);case"MultiPoint":for(o=0,s=a.length;o<s;o++)e=l(a[o]),h.push(u?u(t,e):new $e(e));return new Ke(h);case"LineString":case"MultiLineString":return n=Vt(a,"LineString"===r.type?0:1,l),new nn(n,i);case"Polygon":case"MultiPolygon":return n=Vt(a,"Polygon"===r.type?1:2,l),new on(n,i);case"GeometryCollection":for(o=0,s=r.geometries.length;o<s;o++){var c=Ft({geometry:r.geometries[o],type:"Feature",properties:t.properties},i);c&&h.push(c)}return new Ke(h);default:throw new Error("Invalid GeoJSON object.")}}function Ut(t){return new M(t[1],t[0],t[2])}function Vt(t,i,e){for(var n,o=[],s=0,r=t.length;s<r;s++)n=i?Vt(t[s],i-1,e):(e||Ut)(t[s]),o.push(n);return o}function qt(t,i){return i="number"==typeof i?i:6,void 0!==t.alt?[a(t.lng,i),a(t.lat,i),a(t.alt,i)]:[a(t.lng,i),a(t.lat,i)]}function Gt(t,i,e,n){for(var o=[],s=0,r=t.length;s<r;s++)o.push(i?Gt(t[s],i-1,e,n):qt(t[s],n));return!i&&e&&o.push(o[0]),o}function Kt(t,e){return t.feature?i({},t.feature,{geometry:e}):Yt(e)}function Yt(t){return"Feature"===t.type||"FeatureCollection"===t.type?t:{type:"Feature",properties:{},geometry:t}}function Xt(t,i){return new sn(t,i)}function Jt(t,i){return new mn(t,i)}function $t(t){return Xi?new vn(t):null}function Qt(t){return Ji||$i?new Pn(t):null}var ti=Object.freeze;Object.freeze=function(t){return t};var ii=Object.create||function(){function t(){}return function(i){return t.prototype=i,new t}}(),ei=0,ni=/\{ *([\w_-]+) *\}/g,oi=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)},si="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=",ri=0,ai=window.requestAnimationFrame||p("RequestAnimationFrame")||m,hi=window.cancelAnimationFrame||p("CancelAnimationFrame")||p("CancelRequestAnimationFrame")||function(t){window.clearTimeout(t)},ui=(Object.freeze||Object)({freeze:ti,extend:i,create:ii,bind:e,lastId:ei,stamp:n,throttle:o,wrapNum:s,falseFn:r,formatNum:a,trim:h,splitWords:u,setOptions:l,getParamString:c,template:_,isArray:oi,indexOf:d,emptyImageUrl:si,requestFn:ai,cancelFn:hi,requestAnimFrame:f,cancelAnimFrame:g});v.extend=function(t){var e=function(){this.initialize&&this.initialize.apply(this,arguments),this.callInitHooks()},n=e.__super__=this.prototype,o=ii(n);o.constructor=e,e.prototype=o;for(var s in this)this.hasOwnProperty(s)&&"prototype"!==s&&"__super__"!==s&&(e[s]=this[s]);return t.statics&&(i(e,t.statics),delete t.statics),t.includes&&(y(t.includes),i.apply(null,[o].concat(t.includes)),delete t.includes),o.options&&(t.options=i(ii(o.options),t.options)),i(o,t),o._initHooks=[],o.callInitHooks=function(){if(!this._initHooksCalled){n.callInitHooks&&n.callInitHooks.call(this),this._initHooksCalled=!0;for(var t=0,i=o._initHooks.length;t<i;t++)o._initHooks[t].call(this)}},e},v.include=function(t){return i(this.prototype,t),this},v.mergeOptions=function(t){return i(this.prototype.options,t),this},v.addInitHook=function(t){var i=Array.prototype.slice.call(arguments,1),e="function"==typeof t?t:function(){this[t].apply(this,i)};return this.prototype._initHooks=this.prototype._initHooks||[],this.prototype._initHooks.push(e),this};var li={on:function(t,i,e){if("object"==typeof t)for(var n in t)this._on(n,t[n],i);else for(var o=0,s=(t=u(t)).length;o<s;o++)this._on(t[o],i,e);return this},off:function(t,i,e){if(t)if("object"==typeof t)for(var n in t)this._off(n,t[n],i);else for(var o=0,s=(t=u(t)).length;o<s;o++)this._off(t[o],i,e);else delete this._events;return this},_on:function(t,i,e){this._events=this._events||{};var n=this._events[t];n||(n=[],this._events[t]=n),e===this&&(e=void 0);for(var o={fn:i,ctx:e},s=n,r=0,a=s.length;r<a;r++)if(s[r].fn===i&&s[r].ctx===e)return;s.push(o)},_off:function(t,i,e){var n,o,s;if(this._events&&(n=this._events[t]))if(i){if(e===this&&(e=void 0),n)for(o=0,s=n.length;o<s;o++){var a=n[o];if(a.ctx===e&&a.fn===i)return a.fn=r,this._firingCount&&(this._events[t]=n=n.slice()),void n.splice(o,1)}}else{for(o=0,s=n.length;o<s;o++)n[o].fn=r;delete this._events[t]}},fire:function(t,e,n){if(!this.listens(t,n))return this;var o=i({},e,{type:t,target:this,sourceTarget:e&&e.sourceTarget||this});if(this._events){var s=this._events[t];if(s){this._firingCount=this._firingCount+1||1;for(var r=0,a=s.length;r<a;r++){var h=s[r];h.fn.call(h.ctx||this,o)}this._firingCount--}}return n&&this._propagateEvent(o),this},listens:function(t,i){var e=this._events&&this._events[t];if(e&&e.length)return!0;if(i)for(var n in this._eventParents)if(this._eventParents[n].listens(t,i))return!0;return!1},once:function(t,i,n){if("object"==typeof t){for(var o in t)this.once(o,t[o],i);return this}var s=e(function(){this.off(t,i,n).off(t,s,n)},this);return this.on(t,i,n).on(t,s,n)},addEventParent:function(t){return this._eventParents=this._eventParents||{},this._eventParents[n(t)]=t,this},removeEventParent:function(t){return this._eventParents&&delete this._eventParents[n(t)],this},_propagateEvent:function(t){for(var e in this._eventParents)this._eventParents[e].fire(t.type,i({layer:t.target,propagatedFrom:t.target},t),!0)}};li.addEventListener=li.on,li.removeEventListener=li.clearAllEventListeners=li.off,li.addOneTimeEventListener=li.once,li.fireEvent=li.fire,li.hasEventListeners=li.listens;var ci=v.extend(li),_i=Math.trunc||function(t){return t>0?Math.floor(t):Math.ceil(t)};x.prototype={clone:function(){return new x(this.x,this.y)},add:function(t){return this.clone()._add(w(t))},_add:function(t){return this.x+=t.x,this.y+=t.y,this},subtract:function(t){return this.clone()._subtract(w(t))},_subtract:function(t){return this.x-=t.x,this.y-=t.y,this},divideBy:function(t){return this.clone()._divideBy(t)},_divideBy:function(t){return this.x/=t,this.y/=t,this},multiplyBy:function(t){return this.clone()._multiplyBy(t)},_multiplyBy:function(t){return this.x*=t,this.y*=t,this},scaleBy:function(t){return new x(this.x*t.x,this.y*t.y)},unscaleBy:function(t){return new x(this.x/t.x,this.y/t.y)},round:function(){return this.clone()._round()},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},floor:function(){return this.clone()._floor()},_floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.clone()._ceil()},_ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},trunc:function(){return this.clone()._trunc()},_trunc:function(){return this.x=_i(this.x),this.y=_i(this.y),this},distanceTo:function(t){var i=(t=w(t)).x-this.x,e=t.y-this.y;return Math.sqrt(i*i+e*e)},equals:function(t){return(t=w(t)).x===this.x&&t.y===this.y},contains:function(t){return t=w(t),Math.abs(t.x)<=Math.abs(this.x)&&Math.abs(t.y)<=Math.abs(this.y)},toString:function(){return"Point("+a(this.x)+", "+a(this.y)+")"}},P.prototype={extend:function(t){return t=w(t),this.min||this.max?(this.min.x=Math.min(t.x,this.min.x),this.max.x=Math.max(t.x,this.max.x),this.min.y=Math.min(t.y,this.min.y),this.max.y=Math.max(t.y,this.max.y)):(this.min=t.clone(),this.max=t.clone()),this},getCenter:function(t){return new x((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,t)},getBottomLeft:function(){return new x(this.min.x,this.max.y)},getTopRight:function(){return new x(this.max.x,this.min.y)},getTopLeft:function(){return this.min},getBottomRight:function(){return this.max},getSize:function(){return this.max.subtract(this.min)},contains:function(t){var i,e;return(t="number"==typeof t[0]||t instanceof x?w(t):b(t))instanceof P?(i=t.min,e=t.max):i=e=t,i.x>=this.min.x&&e.x<=this.max.x&&i.y>=this.min.y&&e.y<=this.max.y},intersects:function(t){t=b(t);var i=this.min,e=this.max,n=t.min,o=t.max,s=o.x>=i.x&&n.x<=e.x,r=o.y>=i.y&&n.y<=e.y;return s&&r},overlaps:function(t){t=b(t);var i=this.min,e=this.max,n=t.min,o=t.max,s=o.x>i.x&&n.x<e.x,r=o.y>i.y&&n.y<e.y;return s&&r},isValid:function(){return!(!this.min||!this.max)}},T.prototype={extend:function(t){var i,e,n=this._southWest,o=this._northEast;if(t instanceof M)i=t,e=t;else{if(!(t instanceof T))return t?this.extend(C(t)||z(t)):this;if(i=t._southWest,e=t._northEast,!i||!e)return this}return n||o?(n.lat=Math.min(i.lat,n.lat),n.lng=Math.min(i.lng,n.lng),o.lat=Math.max(e.lat,o.lat),o.lng=Math.max(e.lng,o.lng)):(this._southWest=new M(i.lat,i.lng),this._northEast=new M(e.lat,e.lng)),this},pad:function(t){var i=this._southWest,e=this._northEast,n=Math.abs(i.lat-e.lat)*t,o=Math.abs(i.lng-e.lng)*t;return new T(new M(i.lat-n,i.lng-o),new M(e.lat+n,e.lng+o))},getCenter:function(){return new M((this._southWest.lat+this._northEast.lat)/2,(this._southWest.lng+this._northEast.lng)/2)},getSouthWest:function(){return this._southWest},getNorthEast:function(){return this._northEast},getNorthWest:function(){return new M(this.getNorth(),this.getWest())},getSouthEast:function(){return new M(this.getSouth(),this.getEast())},getWest:function(){return this._southWest.lng},getSouth:function(){return this._southWest.lat},getEast:function(){return this._northEast.lng},getNorth:function(){return this._northEast.lat},contains:function(t){t="number"==typeof t[0]||t instanceof M||"lat"in t?C(t):z(t);var i,e,n=this._southWest,o=this._northEast;return t instanceof T?(i=t.getSouthWest(),e=t.getNorthEast()):i=e=t,i.lat>=n.lat&&e.lat<=o.lat&&i.lng>=n.lng&&e.lng<=o.lng},intersects:function(t){t=z(t);var i=this._southWest,e=this._northEast,n=t.getSouthWest(),o=t.getNorthEast(),s=o.lat>=i.lat&&n.lat<=e.lat,r=o.lng>=i.lng&&n.lng<=e.lng;return s&&r},overlaps:function(t){t=z(t);var i=this._southWest,e=this._northEast,n=t.getSouthWest(),o=t.getNorthEast(),s=o.lat>i.lat&&n.lat<e.lat,r=o.lng>i.lng&&n.lng<e.lng;return s&&r},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(t,i){return!!t&&(t=z(t),this._southWest.equals(t.getSouthWest(),i)&&this._northEast.equals(t.getNorthEast(),i))},isValid:function(){return!(!this._southWest||!this._northEast)}},M.prototype={equals:function(t,i){return!!t&&(t=C(t),Math.max(Math.abs(this.lat-t.lat),Math.abs(this.lng-t.lng))<=(void 0===i?1e-9:i))},toString:function(t){return"LatLng("+a(this.lat,t)+", "+a(this.lng,t)+")"},distanceTo:function(t){return pi.distance(this,C(t))},wrap:function(){return pi.wrapLatLng(this)},toBounds:function(t){var i=180*t/40075017,e=i/Math.cos(Math.PI/180*this.lat);return z([this.lat-i,this.lng-e],[this.lat+i,this.lng+e])},clone:function(){return new M(this.lat,this.lng,this.alt)}};var di={latLngToPoint:function(t,i){var e=this.projection.project(t),n=this.scale(i);return this.transformation._transform(e,n)},pointToLatLng:function(t,i){var e=this.scale(i),n=this.transformation.untransform(t,e);return this.projection.unproject(n)},project:function(t){return this.projection.project(t)},unproject:function(t){return this.projection.unproject(t)},scale:function(t){return 256*Math.pow(2,t)},zoom:function(t){return Math.log(t/256)/Math.LN2},getProjectedBounds:function(t){if(this.infinite)return null;var i=this.projection.bounds,e=this.scale(t);return new P(this.transformation.transform(i.min,e),this.transformation.transform(i.max,e))},infinite:!1,wrapLatLng:function(t){var i=this.wrapLng?s(t.lng,this.wrapLng,!0):t.lng;return new M(this.wrapLat?s(t.lat,this.wrapLat,!0):t.lat,i,t.alt)},wrapLatLngBounds:function(t){var i=t.getCenter(),e=this.wrapLatLng(i),n=i.lat-e.lat,o=i.lng-e.lng;if(0===n&&0===o)return t;var s=t.getSouthWest(),r=t.getNorthEast();return new T(new M(s.lat-n,s.lng-o),new M(r.lat-n,r.lng-o))}},pi=i({},di,{wrapLng:[-180,180],R:6371e3,distance:function(t,i){var e=Math.PI/180,n=t.lat*e,o=i.lat*e,s=Math.sin((i.lat-t.lat)*e/2),r=Math.sin((i.lng-t.lng)*e/2),a=s*s+Math.cos(n)*Math.cos(o)*r*r,h=2*Math.atan2(Math.sqrt(a),Math.sqrt(1-a));return this.R*h}}),mi={R:6378137,MAX_LATITUDE:85.0511287798,project:function(t){var i=Math.PI/180,e=this.MAX_LATITUDE,n=Math.max(Math.min(e,t.lat),-e),o=Math.sin(n*i);return new x(this.R*t.lng*i,this.R*Math.log((1+o)/(1-o))/2)},unproject:function(t){var i=180/Math.PI;return new M((2*Math.atan(Math.exp(t.y/this.R))-Math.PI/2)*i,t.x*i/this.R)},bounds:function(){var t=6378137*Math.PI;return new P([-t,-t],[t,t])}()};S.prototype={transform:function(t,i){return this._transform(t.clone(),i)},_transform:function(t,i){return i=i||1,t.x=i*(this._a*t.x+this._b),t.y=i*(this._c*t.y+this._d),t},untransform:function(t,i){return i=i||1,new x((t.x/i-this._b)/this._a,(t.y/i-this._d)/this._c)}};var fi,gi,vi,yi=i({},pi,{code:"EPSG:3857",projection:mi,transformation:function(){var t=.5/(Math.PI*mi.R);return Z(t,.5,-t,.5)}()}),xi=i({},yi,{code:"EPSG:900913"}),wi=document.documentElement.style,Pi="ActiveXObject"in window,Li=Pi&&!document.addEventListener,bi="msLaunchUri"in navigator&&!("documentMode"in document),Ti=A("webkit"),zi=A("android"),Mi=A("android 2")||A("android 3"),Ci=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),Si=zi&&A("Google")&&Ci<537&&!("AudioNode"in window),Zi=!!window.opera,Ei=A("chrome"),ki=A("gecko")&&!Ti&&!Zi&&!Pi,Ai=!Ei&&A("safari"),Bi=A("phantom"),Ii="OTransition"in wi,Oi=0===navigator.platform.indexOf("Win"),Ri=Pi&&"transition"in wi,Ni="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!Mi,Di="MozPerspective"in wi,ji=!window.L_DISABLE_3D&&(Ri||Ni||Di)&&!Ii&&!Bi,Wi="undefined"!=typeof orientation||A("mobile"),Hi=Wi&&Ti,Fi=Wi&&Ni,Ui=!window.PointerEvent&&window.MSPointerEvent,Vi=!(!window.PointerEvent&&!Ui),qi=!window.L_NO_TOUCH&&(Vi||"ontouchstart"in window||window.DocumentTouch&&document instanceof window.DocumentTouch),Gi=Wi&&Zi,Ki=Wi&&ki,Yi=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,Xi=!!document.createElement("canvas").getContext,Ji=!(!document.createElementNS||!E("svg").createSVGRect),$i=!Ji&&function(){try{var t=document.createElement("div");t.innerHTML='<v:shape adj="1"/>';var i=t.firstChild;return i.style.behavior="url(#default#VML)",i&&"object"==typeof i.adj}catch(t){return!1}}(),Qi=(Object.freeze||Object)({ie:Pi,ielt9:Li,edge:bi,webkit:Ti,android:zi,android23:Mi,androidStock:Si,opera:Zi,chrome:Ei,gecko:ki,safari:Ai,phantom:Bi,opera12:Ii,win:Oi,ie3d:Ri,webkit3d:Ni,gecko3d:Di,any3d:ji,mobile:Wi,mobileWebkit:Hi,mobileWebkit3d:Fi,msPointer:Ui,pointer:Vi,touch:qi,mobileOpera:Gi,mobileGecko:Ki,retina:Yi,canvas:Xi,svg:Ji,vml:$i}),te=Ui?"MSPointerDown":"pointerdown",ie=Ui?"MSPointerMove":"pointermove",ee=Ui?"MSPointerUp":"pointerup",ne=Ui?"MSPointerCancel":"pointercancel",oe=["INPUT","SELECT","OPTION"],se={},re=!1,ae=0,he=Ui?"MSPointerDown":Vi?"pointerdown":"touchstart",ue=Ui?"MSPointerUp":Vi?"pointerup":"touchend",le="_leaflet_",ce=st(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),_e=st(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),de="webkitTransition"===_e||"OTransition"===_e?_e+"End":"transitionend";if("onselectstart"in document)fi=function(){mt(window,"selectstart",Pt)},gi=function(){ft(window,"selectstart",Pt)};else{var pe=st(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);fi=function(){if(pe){var t=document.documentElement.style;vi=t[pe],t[pe]="none"}},gi=function(){pe&&(document.documentElement.style[pe]=vi,vi=void 0)}}var me,fe,ge,ve=(Object.freeze||Object)({TRANSFORM:ce,TRANSITION:_e,TRANSITION_END:de,get:V,getStyle:q,create:G,remove:K,empty:Y,toFront:X,toBack:J,hasClass:$,addClass:Q,removeClass:tt,setClass:it,getClass:et,setOpacity:nt,testProp:st,setTransform:rt,setPosition:at,getPosition:ht,disableTextSelection:fi,enableTextSelection:gi,disableImageDrag:ut,enableImageDrag:lt,preventOutline:ct,restoreOutline:_t,getSizedParentNode:dt,getScale:pt}),ye="_leaflet_events",xe=Oi&&Ei?2*window.devicePixelRatio:ki?window.devicePixelRatio:1,we={},Pe=(Object.freeze||Object)({on:mt,off:ft,stopPropagation:yt,disableScrollPropagation:xt,disableClickPropagation:wt,preventDefault:Pt,stop:Lt,getMousePosition:bt,getWheelDelta:Tt,fakeStop:zt,skipped:Mt,isExternalTarget:Ct,addListener:mt,removeListener:ft}),Le=ci.extend({run:function(t,i,e,n){this.stop(),this._el=t,this._inProgress=!0,this._duration=e||.25,this._easeOutPower=1/Math.max(n||.5,.2),this._startPos=ht(t),this._offset=i.subtract(this._startPos),this._startTime=+new Date,this.fire("start"),this._animate()},stop:function(){this._inProgress&&(this._step(!0),this._complete())},_animate:function(){this._animId=f(this._animate,this),this._step()},_step:function(t){var i=+new Date-this._startTime,e=1e3*this._duration;i<e?this._runFrame(this._easeOut(i/e),t):(this._runFrame(1),this._complete())},_runFrame:function(t,i){var e=this._startPos.add(this._offset.multiplyBy(t));i&&e._round(),at(this._el,e),this.fire("step")},_complete:function(){g(this._animId),this._inProgress=!1,this.fire("end")},_easeOut:function(t){return 1-Math.pow(1-t,this._easeOutPower)}}),be=ci.extend({options:{crs:yi,center:void 0,zoom:void 0,minZoom:void 0,maxZoom:void 0,layers:[],maxBounds:void 0,renderer:void 0,zoomAnimation:!0,zoomAnimationThreshold:4,fadeAnimation:!0,markerZoomAnimation:!0,transform3DLimit:8388608,zoomSnap:1,zoomDelta:1,trackResize:!0},initialize:function(t,i){i=l(this,i),this._initContainer(t),this._initLayout(),this._onResize=e(this._onResize,this),this._initEvents(),i.maxBounds&&this.setMaxBounds(i.maxBounds),void 0!==i.zoom&&(this._zoom=this._limitZoom(i.zoom)),i.center&&void 0!==i.zoom&&this.setView(C(i.center),i.zoom,{reset:!0}),this._handlers=[],this._layers={},this._zoomBoundLayers={},this._sizeChanged=!0,this.callInitHooks(),this._zoomAnimated=_e&&ji&&!Gi&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),mt(this._proxy,de,this._catchTransitionEnd,this)),this._addLayers(this.options.layers)},setView:function(t,e,n){return e=void 0===e?this._zoom:this._limitZoom(e),t=this._limitCenter(C(t),e,this.options.maxBounds),n=n||{},this._stop(),this._loaded&&!n.reset&&!0!==n&&(void 0!==n.animate&&(n.zoom=i({animate:n.animate},n.zoom),n.pan=i({animate:n.animate,duration:n.duration},n.pan)),this._zoom!==e?this._tryAnimatedZoom&&this._tryAnimatedZoom(t,e,n.zoom):this._tryAnimatedPan(t,n.pan))?(clearTimeout(this._sizeTimer),this):(this._resetView(t,e),this)},setZoom:function(t,i){return this._loaded?this.setView(this.getCenter(),t,{zoom:i}):(this._zoom=t,this)},zoomIn:function(t,i){return t=t||(ji?this.options.zoomDelta:1),this.setZoom(this._zoom+t,i)},zoomOut:function(t,i){return t=t||(ji?this.options.zoomDelta:1),this.setZoom(this._zoom-t,i)},setZoomAround:function(t,i,e){var n=this.getZoomScale(i),o=this.getSize().divideBy(2),s=(t instanceof x?t:this.latLngToContainerPoint(t)).subtract(o).multiplyBy(1-1/n),r=this.containerPointToLatLng(o.add(s));return this.setView(r,i,{zoom:e})},_getBoundsCenterZoom:function(t,i){i=i||{},t=t.getBounds?t.getBounds():z(t);var e=w(i.paddingTopLeft||i.padding||[0,0]),n=w(i.paddingBottomRight||i.padding||[0,0]),o=this.getBoundsZoom(t,!1,e.add(n));if((o="number"==typeof i.maxZoom?Math.min(i.maxZoom,o):o)===1/0)return{center:t.getCenter(),zoom:o};var s=n.subtract(e).divideBy(2),r=this.project(t.getSouthWest(),o),a=this.project(t.getNorthEast(),o);return{center:this.unproject(r.add(a).divideBy(2).add(s),o),zoom:o}},fitBounds:function(t,i){if(!(t=z(t)).isValid())throw new Error("Bounds are not valid.");var e=this._getBoundsCenterZoom(t,i);return this.setView(e.center,e.zoom,i)},fitWorld:function(t){return this.fitBounds([[-90,-180],[90,180]],t)},panTo:function(t,i){return this.setView(t,this._zoom,{pan:i})},panBy:function(t,i){if(t=w(t).round(),i=i||{},!t.x&&!t.y)return this.fire("moveend");if(!0!==i.animate&&!this.getSize().contains(t))return this._resetView(this.unproject(this.project(this.getCenter()).add(t)),this.getZoom()),this;if(this._panAnim||(this._panAnim=new Le,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),i.noMoveStart||this.fire("movestart"),!1!==i.animate){Q(this._mapPane,"leaflet-pan-anim");var e=this._getMapPanePos().subtract(t).round();this._panAnim.run(this._mapPane,e,i.duration||.25,i.easeLinearity)}else this._rawPanBy(t),this.fire("move").fire("moveend");return this},flyTo:function(t,i,e){function n(t){var i=(g*g-m*m+(t?-1:1)*x*x*v*v)/(2*(t?g:m)*x*v),e=Math.sqrt(i*i+1)-i;return e<1e-9?-18:Math.log(e)}function o(t){return(Math.exp(t)-Math.exp(-t))/2}function s(t){return(Math.exp(t)+Math.exp(-t))/2}function r(t){return o(t)/s(t)}function a(t){return m*(s(w)/s(w+y*t))}function h(t){return m*(s(w)*r(w+y*t)-o(w))/x}function u(t){return 1-Math.pow(1-t,1.5)}function l(){var e=(Date.now()-P)/b,n=u(e)*L;e<=1?(this._flyToFrame=f(l,this),this._move(this.unproject(c.add(_.subtract(c).multiplyBy(h(n)/v)),p),this.getScaleZoom(m/a(n),p),{flyTo:!0})):this._move(t,i)._moveEnd(!0)}if(!1===(e=e||{}).animate||!ji)return this.setView(t,i,e);this._stop();var c=this.project(this.getCenter()),_=this.project(t),d=this.getSize(),p=this._zoom;t=C(t),i=void 0===i?p:i;var m=Math.max(d.x,d.y),g=m*this.getZoomScale(p,i),v=_.distanceTo(c)||1,y=1.42,x=y*y,w=n(0),P=Date.now(),L=(n(1)-w)/y,b=e.duration?1e3*e.duration:1e3*L*.8;return this._moveStart(!0,e.noMoveStart),l.call(this),this},flyToBounds:function(t,i){var e=this._getBoundsCenterZoom(t,i);return this.flyTo(e.center,e.zoom,i)},setMaxBounds:function(t){return(t=z(t)).isValid()?(this.options.maxBounds&&this.off("moveend",this._panInsideMaxBounds),this.options.maxBounds=t,this._loaded&&this._panInsideMaxBounds(),this.on("moveend",this._panInsideMaxBounds)):(this.options.maxBounds=null,this.off("moveend",this._panInsideMaxBounds))},setMinZoom:function(t){var i=this.options.minZoom;return this.options.minZoom=t,this._loaded&&i!==t&&(this.fire("zoomlevelschange"),this.getZoom()<this.options.minZoom)?this.setZoom(t):this},setMaxZoom:function(t){var i=this.options.maxZoom;return this.options.maxZoom=t,this._loaded&&i!==t&&(this.fire("zoomlevelschange"),this.getZoom()>this.options.maxZoom)?this.setZoom(t):this},panInsideBounds:function(t,i){this._enforcingBounds=!0;var e=this.getCenter(),n=this._limitCenter(e,this._zoom,z(t));return e.equals(n)||this.panTo(n,i),this._enforcingBounds=!1,this},invalidateSize:function(t){if(!this._loaded)return this;t=i({animate:!1,pan:!0},!0===t?{animate:!0}:t);var n=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var o=this.getSize(),s=n.divideBy(2).round(),r=o.divideBy(2).round(),a=s.subtract(r);return a.x||a.y?(t.animate&&t.pan?this.panBy(a):(t.pan&&this._rawPanBy(a),this.fire("move"),t.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(e(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:n,newSize:o})):this},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(t){if(t=this._locateOptions=i({timeout:1e4,watch:!1},t),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var n=e(this._handleGeolocationResponse,this),o=e(this._handleGeolocationError,this);return t.watch?this._locationWatchId=navigator.geolocation.watchPosition(n,o,t):navigator.geolocation.getCurrentPosition(n,o,t),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(t){var i=t.code,e=t.message||(1===i?"permission denied":2===i?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:i,message:"Geolocation error: "+e+"."})},_handleGeolocationResponse:function(t){var i=new M(t.coords.latitude,t.coords.longitude),e=i.toBounds(2*t.coords.accuracy),n=this._locateOptions;if(n.setView){var o=this.getBoundsZoom(e);this.setView(i,n.maxZoom?Math.min(o,n.maxZoom):o)}var s={latlng:i,bounds:e,timestamp:t.timestamp};for(var r in t.coords)"number"==typeof t.coords[r]&&(s[r]=t.coords[r]);this.fire("locationfound",s)},addHandler:function(t,i){if(!i)return this;var e=this[t]=new i(this);return this._handlers.push(e),this.options[t]&&e.enable(),this},remove:function(){if(this._initEvents(!0),this._containerId!==this._container._leaflet_id)throw new Error("Map container is being reused by another instance");try{delete this._container._leaflet_id,delete this._containerId}catch(t){this._container._leaflet_id=void 0,this._containerId=void 0}void 0!==this._locationWatchId&&this.stopLocate(),this._stop(),K(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(g(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var t;for(t in this._layers)this._layers[t].remove();for(t in this._panes)K(this._panes[t]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(t,i){var e=G("div","leaflet-pane"+(t?" leaflet-"+t.replace("Pane","")+"-pane":""),i||this._mapPane);return t&&(this._panes[t]=e),e},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter:this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var t=this.getPixelBounds();return new T(this.unproject(t.getBottomLeft()),this.unproject(t.getTopRight()))},getMinZoom:function(){return void 0===this.options.minZoom?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return void 0===this.options.maxZoom?void 0===this._layersMaxZoom?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(t,i,e){t=z(t),e=w(e||[0,0]);var n=this.getZoom()||0,o=this.getMinZoom(),s=this.getMaxZoom(),r=t.getNorthWest(),a=t.getSouthEast(),h=this.getSize().subtract(e),u=b(this.project(a,n),this.project(r,n)).getSize(),l=ji?this.options.zoomSnap:1,c=h.x/u.x,_=h.y/u.y,d=i?Math.max(c,_):Math.min(c,_);return n=this.getScaleZoom(d,n),l&&(n=Math.round(n/(l/100))*(l/100),n=i?Math.ceil(n/l)*l:Math.floor(n/l)*l),Math.max(o,Math.min(s,n))},getSize:function(){return this._size&&!this._sizeChanged||(this._size=new x(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(t,i){var e=this._getTopLeftPoint(t,i);return new P(e,e.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(t){return this.options.crs.getProjectedBounds(void 0===t?this.getZoom():t)},getPane:function(t){return"string"==typeof t?this._panes[t]:t},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(t,i){var e=this.options.crs;return i=void 0===i?this._zoom:i,e.scale(t)/e.scale(i)},getScaleZoom:function(t,i){var e=this.options.crs;i=void 0===i?this._zoom:i;var n=e.zoom(t*e.scale(i));return isNaN(n)?1/0:n},project:function(t,i){return i=void 0===i?this._zoom:i,this.options.crs.latLngToPoint(C(t),i)},unproject:function(t,i){return i=void 0===i?this._zoom:i,this.options.crs.pointToLatLng(w(t),i)},layerPointToLatLng:function(t){var i=w(t).add(this.getPixelOrigin());return this.unproject(i)},latLngToLayerPoint:function(t){return this.project(C(t))._round()._subtract(this.getPixelOrigin())},wrapLatLng:function(t){return this.options.crs.wrapLatLng(C(t))},wrapLatLngBounds:function(t){return this.options.crs.wrapLatLngBounds(z(t))},distance:function(t,i){return this.options.crs.distance(C(t),C(i))},containerPointToLayerPoint:function(t){return w(t).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(t){return w(t).add(this._getMapPanePos())},containerPointToLatLng:function(t){var i=this.containerPointToLayerPoint(w(t));return this.layerPointToLatLng(i)},latLngToContainerPoint:function(t){return this.layerPointToContainerPoint(this.latLngToLayerPoint(C(t)))},mouseEventToContainerPoint:function(t){return bt(t,this._container)},mouseEventToLayerPoint:function(t){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(t))},mouseEventToLatLng:function(t){return this.layerPointToLatLng(this.mouseEventToLayerPoint(t))},_initContainer:function(t){var i=this._container=V(t);if(!i)throw new Error("Map container not found.");if(i._leaflet_id)throw new Error("Map container is already initialized.");mt(i,"scroll",this._onScroll,this),this._containerId=n(i)},_initLayout:function(){var t=this._container;this._fadeAnimated=this.options.fadeAnimation&&ji,Q(t,"leaflet-container"+(qi?" leaflet-touch":"")+(Yi?" leaflet-retina":"")+(Li?" leaflet-oldie":"")+(Ai?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var i=q(t,"position");"absolute"!==i&&"relative"!==i&&"fixed"!==i&&(t.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var t=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),at(this._mapPane,new x(0,0)),this.createPane("tilePane"),this.createPane("shadowPane"),this.createPane("overlayPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(Q(t.markerPane,"leaflet-zoom-hide"),Q(t.shadowPane,"leaflet-zoom-hide"))},_resetView:function(t,i){at(this._mapPane,new x(0,0));var e=!this._loaded;this._loaded=!0,i=this._limitZoom(i),this.fire("viewprereset");var n=this._zoom!==i;this._moveStart(n,!1)._move(t,i)._moveEnd(n),this.fire("viewreset"),e&&this.fire("load")},_moveStart:function(t,i){return t&&this.fire("zoomstart"),i||this.fire("movestart"),this},_move:function(t,i,e){void 0===i&&(i=this._zoom);var n=this._zoom!==i;return this._zoom=i,this._lastCenter=t,this._pixelOrigin=this._getNewPixelOrigin(t),(n||e&&e.pinch)&&this.fire("zoom",e),this.fire("move",e)},_moveEnd:function(t){return t&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return g(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(t){at(this._mapPane,this._getMapPanePos().subtract(t))},_getZoomSpan:function(){return this.getMaxZoom()-this.getMinZoom()},_panInsideMaxBounds:function(){this._enforcingBounds||this.panInsideBounds(this.options.maxBounds)},_checkIfLoaded:function(){if(!this._loaded)throw new Error("Set map center and zoom first.")},_initEvents:function(t){this._targets={},this._targets[n(this._container)]=this;var i=t?ft:mt;i(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress",this._handleDOMEvent,this),this.options.trackResize&&i(window,"resize",this._onResize,this),ji&&this.options.transform3DLimit&&(t?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){g(this._resizeRequest),this._resizeRequest=f(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var t=this._getMapPanePos();Math.max(Math.abs(t.x),Math.abs(t.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(t,i){for(var e,o=[],s="mouseout"===i||"mouseover"===i,r=t.target||t.srcElement,a=!1;r;){if((e=this._targets[n(r)])&&("click"===i||"preclick"===i)&&!t._simulated&&this._draggableMoved(e)){a=!0;break}if(e&&e.listens(i,!0)){if(s&&!Ct(r,t))break;if(o.push(e),s)break}if(r===this._container)break;r=r.parentNode}return o.length||a||s||!Ct(r,t)||(o=[this]),o},_handleDOMEvent:function(t){if(this._loaded&&!Mt(t)){var i=t.type;"mousedown"!==i&&"keypress"!==i||ct(t.target||t.srcElement),this._fireDOMEvent(t,i)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(t,e,n){if("click"===t.type){var o=i({},t);o.type="preclick",this._fireDOMEvent(o,o.type,n)}if(!t._stopped&&(n=(n||[]).concat(this._findEventTargets(t,e))).length){var s=n[0];"contextmenu"===e&&s.listens(e,!0)&&Pt(t);var r={originalEvent:t};if("keypress"!==t.type){var a=s.getLatLng&&(!s._radius||s._radius<=10);r.containerPoint=a?this.latLngToContainerPoint(s.getLatLng()):this.mouseEventToContainerPoint(t),r.layerPoint=this.containerPointToLayerPoint(r.containerPoint),r.latlng=a?s.getLatLng():this.layerPointToLatLng(r.layerPoint)}for(var h=0;h<n.length;h++)if(n[h].fire(e,r,!0),r.originalEvent._stopped||!1===n[h].options.bubblingMouseEvents&&-1!==d(this._mouseEvents,e))return}},_draggableMoved:function(t){return(t=t.dragging&&t.dragging.enabled()?t:this).dragging&&t.dragging.moved()||this.boxZoom&&this.boxZoom.moved()},_clearHandlers:function(){for(var t=0,i=this._handlers.length;t<i;t++)this._handlers[t].disable()},whenReady:function(t,i){return this._loaded?t.call(i||this,{target:this}):this.on("load",t,i),this},_getMapPanePos:function(){return ht(this._mapPane)||new x(0,0)},_moved:function(){var t=this._getMapPanePos();return t&&!t.equals([0,0])},_getTopLeftPoint:function(t,i){return(t&&void 0!==i?this._getNewPixelOrigin(t,i):this.getPixelOrigin()).subtract(this._getMapPanePos())},_getNewPixelOrigin:function(t,i){var e=this.getSize()._divideBy(2);return this.project(t,i)._subtract(e)._add(this._getMapPanePos())._round()},_latLngToNewLayerPoint:function(t,i,e){var n=this._getNewPixelOrigin(e,i);return this.project(t,i)._subtract(n)},_latLngBoundsToNewLayerBounds:function(t,i,e){var n=this._getNewPixelOrigin(e,i);return b([this.project(t.getSouthWest(),i)._subtract(n),this.project(t.getNorthWest(),i)._subtract(n),this.project(t.getSouthEast(),i)._subtract(n),this.project(t.getNorthEast(),i)._subtract(n)])},_getCenterLayerPoint:function(){return this.containerPointToLayerPoint(this.getSize()._divideBy(2))},_getCenterOffset:function(t){return this.latLngToLayerPoint(t).subtract(this._getCenterLayerPoint())},_limitCenter:function(t,i,e){if(!e)return t;var n=this.project(t,i),o=this.getSize().divideBy(2),s=new P(n.subtract(o),n.add(o)),r=this._getBoundsOffset(s,e,i);return r.round().equals([0,0])?t:this.unproject(n.add(r),i)},_limitOffset:function(t,i){if(!i)return t;var e=this.getPixelBounds(),n=new P(e.min.add(t),e.max.add(t));return t.add(this._getBoundsOffset(n,i))},_getBoundsOffset:function(t,i,e){var n=b(this.project(i.getNorthEast(),e),this.project(i.getSouthWest(),e)),o=n.min.subtract(t.min),s=n.max.subtract(t.max);return new x(this._rebound(o.x,-s.x),this._rebound(o.y,-s.y))},_rebound:function(t,i){return t+i>0?Math.round(t-i)/2:Math.max(0,Math.ceil(t))-Math.max(0,Math.floor(i))},_limitZoom:function(t){var i=this.getMinZoom(),e=this.getMaxZoom(),n=ji?this.options.zoomSnap:1;return n&&(t=Math.round(t/n)*n),Math.max(i,Math.min(e,t))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){tt(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(t,i){var e=this._getCenterOffset(t)._trunc();return!(!0!==(i&&i.animate)&&!this.getSize().contains(e))&&(this.panBy(e,i),!0)},_createAnimProxy:function(){var t=this._proxy=G("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(t),this.on("zoomanim",function(t){var i=ce,e=this._proxy.style[i];rt(this._proxy,this.project(t.center,t.zoom),this.getZoomScale(t.zoom,1)),e===this._proxy.style[i]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",function(){var t=this.getCenter(),i=this.getZoom();rt(this._proxy,this.project(t,i),this.getZoomScale(i,1))},this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){K(this._proxy),delete this._proxy},_catchTransitionEnd:function(t){this._animatingZoom&&t.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(t,i,e){if(this._animatingZoom)return!0;if(e=e||{},!this._zoomAnimated||!1===e.animate||this._nothingToAnimate()||Math.abs(i-this._zoom)>this.options.zoomAnimationThreshold)return!1;var n=this.getZoomScale(i),o=this._getCenterOffset(t)._divideBy(1-1/n);return!(!0!==e.animate&&!this.getSize().contains(o))&&(f(function(){this._moveStart(!0,!1)._animateZoom(t,i,!0)},this),!0)},_animateZoom:function(t,i,n,o){this._mapPane&&(n&&(this._animatingZoom=!0,this._animateToCenter=t,this._animateToZoom=i,Q(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:t,zoom:i,noUpdate:o}),setTimeout(e(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&tt(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom),f(function(){this._moveEnd(!0)},this))}}),Te=v.extend({options:{position:"topright"},initialize:function(t){l(this,t)},getPosition:function(){return this.options.position},setPosition:function(t){var i=this._map;return i&&i.removeControl(this),this.options.position=t,i&&i.addControl(this),this},getContainer:function(){return this._container},addTo:function(t){this.remove(),this._map=t;var i=this._container=this.onAdd(t),e=this.getPosition(),n=t._controlCorners[e];return Q(i,"leaflet-control"),-1!==e.indexOf("bottom")?n.insertBefore(i,n.firstChild):n.appendChild(i),this},remove:function(){return this._map?(K(this._container),this.onRemove&&this.onRemove(this._map),this._map=null,this):this},_refocusOnMap:function(t){this._map&&t&&t.screenX>0&&t.screenY>0&&this._map.getContainer().focus()}}),ze=function(t){return new Te(t)};be.include({addControl:function(t){return t.addTo(this),this},removeControl:function(t){return t.remove(),this},_initControlPos:function(){function t(t,o){var s=e+t+" "+e+o;i[t+o]=G("div",s,n)}var i=this._controlCorners={},e="leaflet-",n=this._controlContainer=G("div",e+"control-container",this._container);t("top","left"),t("top","right"),t("bottom","left"),t("bottom","right")},_clearControlPos:function(){for(var t in this._controlCorners)K(this._controlCorners[t]);K(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var Me=Te.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(t,i,e,n){return e<n?-1:n<e?1:0}},initialize:function(t,i,e){l(this,e),this._layerControlInputs=[],this._layers=[],this._lastZIndex=0,this._handlingClick=!1;for(var n in t)this._addLayer(t[n],n);for(n in i)this._addLayer(i[n],n,!0)},onAdd:function(t){this._initLayout(),this._update(),this._map=t,t.on("zoomend",this._checkDisabledLayers,this);for(var i=0;i<this._layers.length;i++)this._layers[i].layer.on("add remove",this._onLayerChange,this);return this._container},addTo:function(t){return Te.prototype.addTo.call(this,t),this._expandIfNotCollapsed()},onRemove:function(){this._map.off("zoomend",this._checkDisabledLayers,this);for(var t=0;t<this._layers.length;t++)this._layers[t].layer.off("add remove",this._onLayerChange,this)},addBaseLayer:function(t,i){return this._addLayer(t,i),this._map?this._update():this},addOverlay:function(t,i){return this._addLayer(t,i,!0),this._map?this._update():this},removeLayer:function(t){t.off("add remove",this._onLayerChange,this);var i=this._getLayer(n(t));return i&&this._layers.splice(this._layers.indexOf(i),1),this._map?this._update():this},expand:function(){Q(this._container,"leaflet-control-layers-expanded"),this._form.style.height=null;var t=this._map.getSize().y-(this._container.offsetTop+50);return t<this._form.clientHeight?(Q(this._form,"leaflet-control-layers-scrollbar"),this._form.style.height=t+"px"):tt(this._form,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return tt(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var t="leaflet-control-layers",i=this._container=G("div",t),e=this.options.collapsed;i.setAttribute("aria-haspopup",!0),wt(i),xt(i);var n=this._form=G("form",t+"-list");e&&(this._map.on("click",this.collapse,this),zi||mt(i,{mouseenter:this.expand,mouseleave:this.collapse},this));var o=this._layersLink=G("a",t+"-toggle",i);o.href="#",o.title="Layers",qi?(mt(o,"click",Lt),mt(o,"click",this.expand,this)):mt(o,"focus",this.expand,this),e||this.expand(),this._baseLayersList=G("div",t+"-base",n),this._separator=G("div",t+"-separator",n),this._overlaysList=G("div",t+"-overlays",n),i.appendChild(n)},_getLayer:function(t){for(var i=0;i<this._layers.length;i++)if(this._layers[i]&&n(this._layers[i].layer)===t)return this._layers[i]},_addLayer:function(t,i,n){this._map&&t.on("add remove",this._onLayerChange,this),this._layers.push({layer:t,name:i,overlay:n}),this.options.sortLayers&&this._layers.sort(e(function(t,i){return this.options.sortFunction(t.layer,i.layer,t.name,i.name)},this)),this.options.autoZIndex&&t.setZIndex&&(this._lastZIndex++,t.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;Y(this._baseLayersList),Y(this._overlaysList),this._layerControlInputs=[];var t,i,e,n,o=0;for(e=0;e<this._layers.length;e++)n=this._layers[e],this._addItem(n),i=i||n.overlay,t=t||!n.overlay,o+=n.overlay?0:1;return this.options.hideSingleBase&&(t=t&&o>1,this._baseLayersList.style.display=t?"":"none"),this._separator.style.display=i&&t?"":"none",this},_onLayerChange:function(t){this._handlingClick||this._update();var i=this._getLayer(n(t.target)),e=i.overlay?"add"===t.type?"overlayadd":"overlayremove":"add"===t.type?"baselayerchange":null;e&&this._map.fire(e,i)},_createRadioElement:function(t,i){var e='<input type="radio" class="leaflet-control-layers-selector" name="'+t+'"'+(i?' checked="checked"':"")+"/>",n=document.createElement("div");return n.innerHTML=e,n.firstChild},_addItem:function(t){var i,e=document.createElement("label"),o=this._map.hasLayer(t.layer);t.overlay?((i=document.createElement("input")).type="checkbox",i.className="leaflet-control-layers-selector",i.defaultChecked=o):i=this._createRadioElement("leaflet-base-layers",o),this._layerControlInputs.push(i),i.layerId=n(t.layer),mt(i,"click",this._onInputClick,this);var s=document.createElement("span");s.innerHTML=" "+t.name;var r=document.createElement("div");return e.appendChild(r),r.appendChild(i),r.appendChild(s),(t.overlay?this._overlaysList:this._baseLayersList).appendChild(e),this._checkDisabledLayers(),e},_onInputClick:function(){var t,i,e=this._layerControlInputs,n=[],o=[];this._handlingClick=!0;for(var s=e.length-1;s>=0;s--)t=e[s],i=this._getLayer(t.layerId).layer,t.checked?n.push(i):t.checked||o.push(i);for(s=0;s<o.length;s++)this._map.hasLayer(o[s])&&this._map.removeLayer(o[s]);for(s=0;s<n.length;s++)this._map.hasLayer(n[s])||this._map.addLayer(n[s]);this._handlingClick=!1,this._refocusOnMap()},_checkDisabledLayers:function(){for(var t,i,e=this._layerControlInputs,n=this._map.getZoom(),o=e.length-1;o>=0;o--)t=e[o],i=this._getLayer(t.layerId).layer,t.disabled=void 0!==i.options.minZoom&&n<i.options.minZoom||void 0!==i.options.maxZoom&&n>i.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expand:function(){return this.expand()},_collapse:function(){return this.collapse()}}),Ce=Te.extend({options:{position:"topleft",zoomInText:"+",zoomInTitle:"Zoom in",zoomOutText:"&#x2212;",zoomOutTitle:"Zoom out"},onAdd:function(t){var i="leaflet-control-zoom",e=G("div",i+" leaflet-bar"),n=this.options;return this._zoomInButton=this._createButton(n.zoomInText,n.zoomInTitle,i+"-in",e,this._zoomIn),this._zoomOutButton=this._createButton(n.zoomOutText,n.zoomOutTitle,i+"-out",e,this._zoomOut),this._updateDisabled(),t.on("zoomend zoomlevelschange",this._updateDisabled,this),e},onRemove:function(t){t.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(t){!this._disabled&&this._map._zoom<this._map.getMaxZoom()&&this._map.zoomIn(this._map.options.zoomDelta*(t.shiftKey?3:1))},_zoomOut:function(t){!this._disabled&&this._map._zoom>this._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(t.shiftKey?3:1))},_createButton:function(t,i,e,n,o){var s=G("a",e,n);return s.innerHTML=t,s.href="#",s.title=i,s.setAttribute("role","button"),s.setAttribute("aria-label",i),wt(s),mt(s,"click",Lt),mt(s,"click",o,this),mt(s,"click",this._refocusOnMap,this),s},_updateDisabled:function(){var t=this._map,i="leaflet-disabled";tt(this._zoomInButton,i),tt(this._zoomOutButton,i),(this._disabled||t._zoom===t.getMinZoom())&&Q(this._zoomOutButton,i),(this._disabled||t._zoom===t.getMaxZoom())&&Q(this._zoomInButton,i)}});be.mergeOptions({zoomControl:!0}),be.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new Ce,this.addControl(this.zoomControl))});var Se=Te.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(t){var i=G("div","leaflet-control-scale"),e=this.options;return this._addScales(e,"leaflet-control-scale-line",i),t.on(e.updateWhenIdle?"moveend":"move",this._update,this),t.whenReady(this._update,this),i},onRemove:function(t){t.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(t,i,e){t.metric&&(this._mScale=G("div",i,e)),t.imperial&&(this._iScale=G("div",i,e))},_update:function(){var t=this._map,i=t.getSize().y/2,e=t.distance(t.containerPointToLatLng([0,i]),t.containerPointToLatLng([this.options.maxWidth,i]));this._updateScales(e)},_updateScales:function(t){this.options.metric&&t&&this._updateMetric(t),this.options.imperial&&t&&this._updateImperial(t)},_updateMetric:function(t){var i=this._getRoundNum(t),e=i<1e3?i+" m":i/1e3+" km";this._updateScale(this._mScale,e,i/t)},_updateImperial:function(t){var i,e,n,o=3.2808399*t;o>5280?(i=o/5280,e=this._getRoundNum(i),this._updateScale(this._iScale,e+" mi",e/i)):(n=this._getRoundNum(o),this._updateScale(this._iScale,n+" ft",n/o))},_updateScale:function(t,i,e){t.style.width=Math.round(this.options.maxWidth*e)+"px",t.innerHTML=i},_getRoundNum:function(t){var i=Math.pow(10,(Math.floor(t)+"").length-1),e=t/i;return e=e>=10?10:e>=5?5:e>=3?3:e>=2?2:1,i*e}}),Ze=Te.extend({options:{position:"bottomright",prefix:'<a href="http://leafletjs.com" title="A JS library for interactive maps">Leaflet</a>'},initialize:function(t){l(this,t),this._attributions={}},onAdd:function(t){t.attributionControl=this,this._container=G("div","leaflet-control-attribution"),wt(this._container);for(var i in t._layers)t._layers[i].getAttribution&&this.addAttribution(t._layers[i].getAttribution());return this._update(),this._container},setPrefix:function(t){return this.options.prefix=t,this._update(),this},addAttribution:function(t){return t?(this._attributions[t]||(this._attributions[t]=0),this._attributions[t]++,this._update(),this):this},removeAttribution:function(t){return t?(this._attributions[t]&&(this._attributions[t]--,this._update()),this):this},_update:function(){if(this._map){var t=[];for(var i in this._attributions)this._attributions[i]&&t.push(i);var e=[];this.options.prefix&&e.push(this.options.prefix),t.length&&e.push(t.join(", ")),this._container.innerHTML=e.join(" | ")}}});be.mergeOptions({attributionControl:!0}),be.addInitHook(function(){this.options.attributionControl&&(new Ze).addTo(this)});Te.Layers=Me,Te.Zoom=Ce,Te.Scale=Se,Te.Attribution=Ze,ze.layers=function(t,i,e){return new Me(t,i,e)},ze.zoom=function(t){return new Ce(t)},ze.scale=function(t){return new Se(t)},ze.attribution=function(t){return new Ze(t)};var Ee=v.extend({initialize:function(t){this._map=t},enable:function(){return this._enabled?this:(this._enabled=!0,this.addHooks(),this)},disable:function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},enabled:function(){return!!this._enabled}});Ee.addTo=function(t,i){return t.addHandler(i,this),this};var ke,Ae={Events:li},Be=qi?"touchstart mousedown":"mousedown",Ie={mousedown:"mouseup",touchstart:"touchend",pointerdown:"touchend",MSPointerDown:"touchend"},Oe={mousedown:"mousemove",touchstart:"touchmove",pointerdown:"touchmove",MSPointerDown:"touchmove"},Re=ci.extend({options:{clickTolerance:3},initialize:function(t,i,e,n){l(this,n),this._element=t,this._dragStartTarget=i||t,this._preventOutline=e},enable:function(){this._enabled||(mt(this._dragStartTarget,Be,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&(Re._dragging===this&&this.finishDrag(),ft(this._dragStartTarget,Be,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(t){if(!t._simulated&&this._enabled&&(this._moved=!1,!$(this._element,"leaflet-zoom-anim")&&!(Re._dragging||t.shiftKey||1!==t.which&&1!==t.button&&!t.touches||(Re._dragging=this,this._preventOutline&&ct(this._element),ut(),fi(),this._moving)))){this.fire("down");var i=t.touches?t.touches[0]:t,e=dt(this._element);this._startPoint=new x(i.clientX,i.clientY),this._parentScale=pt(e),mt(document,Oe[t.type],this._onMove,this),mt(document,Ie[t.type],this._onUp,this)}},_onMove:function(t){if(!t._simulated&&this._enabled)if(t.touches&&t.touches.length>1)this._moved=!0;else{var i=t.touches&&1===t.touches.length?t.touches[0]:t,e=new x(i.clientX,i.clientY)._subtract(this._startPoint);(e.x||e.y)&&(Math.abs(e.x)+Math.abs(e.y)<this.options.clickTolerance||(e.x/=this._parentScale.x,e.y/=this._parentScale.y,Pt(t),this._moved||(this.fire("dragstart"),this._moved=!0,this._startPos=ht(this._element).subtract(e),Q(document.body,"leaflet-dragging"),this._lastTarget=t.target||t.srcElement,window.SVGElementInstance&&this._lastTarget instanceof SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),Q(this._lastTarget,"leaflet-drag-target")),this._newPos=this._startPos.add(e),this._moving=!0,g(this._animRequest),this._lastEvent=t,this._animRequest=f(this._updatePosition,this,!0)))}},_updatePosition:function(){var t={originalEvent:this._lastEvent};this.fire("predrag",t),at(this._element,this._newPos),this.fire("drag",t)},_onUp:function(t){!t._simulated&&this._enabled&&this.finishDrag()},finishDrag:function(){tt(document.body,"leaflet-dragging"),this._lastTarget&&(tt(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null);for(var t in Oe)ft(document,Oe[t],this._onMove,this),ft(document,Ie[t],this._onUp,this);lt(),gi(),this._moved&&this._moving&&(g(this._animRequest),this.fire("dragend",{distance:this._newPos.distanceTo(this._startPos)})),this._moving=!1,Re._dragging=!1}}),Ne=(Object.freeze||Object)({simplify:Zt,pointToSegmentDistance:Et,closestPointOnSegment:function(t,i,e){return Dt(t,i,e)},clipSegment:It,_getEdgeIntersection:Ot,_getBitCode:Rt,_sqClosestPointOnSegment:Dt,isFlat:jt,_flat:Wt}),De=(Object.freeze||Object)({clipPolygon:Ht}),je={project:function(t){return new x(t.lng,t.lat)},unproject:function(t){return new M(t.y,t.x)},bounds:new P([-180,-90],[180,90])},We={R:6378137,R_MINOR:6356752.314245179,bounds:new P([-20037508.34279,-15496570.73972],[20037508.34279,18764656.23138]),project:function(t){var i=Math.PI/180,e=this.R,n=t.lat*i,o=this.R_MINOR/e,s=Math.sqrt(1-o*o),r=s*Math.sin(n),a=Math.tan(Math.PI/4-n/2)/Math.pow((1-r)/(1+r),s/2);return n=-e*Math.log(Math.max(a,1e-10)),new x(t.lng*i*e,n)},unproject:function(t){for(var i,e=180/Math.PI,n=this.R,o=this.R_MINOR/n,s=Math.sqrt(1-o*o),r=Math.exp(-t.y/n),a=Math.PI/2-2*Math.atan(r),h=0,u=.1;h<15&&Math.abs(u)>1e-7;h++)i=s*Math.sin(a),i=Math.pow((1-i)/(1+i),s/2),a+=u=Math.PI/2-2*Math.atan(r*i)-a;return new M(a*e,t.x*e/n)}},He=(Object.freeze||Object)({LonLat:je,Mercator:We,SphericalMercator:mi}),Fe=i({},pi,{code:"EPSG:3395",projection:We,transformation:function(){var t=.5/(Math.PI*We.R);return Z(t,.5,-t,.5)}()}),Ue=i({},pi,{code:"EPSG:4326",projection:je,transformation:Z(1/180,1,-1/180,.5)}),Ve=i({},di,{projection:je,transformation:Z(1,0,-1,0),scale:function(t){return Math.pow(2,t)},zoom:function(t){return Math.log(t)/Math.LN2},distance:function(t,i){var e=i.lng-t.lng,n=i.lat-t.lat;return Math.sqrt(e*e+n*n)},infinite:!0});di.Earth=pi,di.EPSG3395=Fe,di.EPSG3857=yi,di.EPSG900913=xi,di.EPSG4326=Ue,di.Simple=Ve;var qe=ci.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(t){return t.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(t){return t&&t.removeLayer(this),this},getPane:function(t){return this._map.getPane(t?this.options[t]||t:this.options.pane)},addInteractiveTarget:function(t){return this._map._targets[n(t)]=this,this},removeInteractiveTarget:function(t){return delete this._map._targets[n(t)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(t){var i=t.target;if(i.hasLayer(this)){if(this._map=i,this._zoomAnimated=i._zoomAnimated,this.getEvents){var e=this.getEvents();i.on(e,this),this.once("remove",function(){i.off(e,this)},this)}this.onAdd(i),this.getAttribution&&i.attributionControl&&i.attributionControl.addAttribution(this.getAttribution()),this.fire("add"),i.fire("layeradd",{layer:this})}}});be.include({addLayer:function(t){if(!t._layerAdd)throw new Error("The provided object is not a Layer.");var i=n(t);return this._layers[i]?this:(this._layers[i]=t,t._mapToAdd=this,t.beforeAdd&&t.beforeAdd(this),this.whenReady(t._layerAdd,t),this)},removeLayer:function(t){var i=n(t);return this._layers[i]?(this._loaded&&t.onRemove(this),t.getAttribution&&this.attributionControl&&this.attributionControl.removeAttribution(t.getAttribution()),delete this._layers[i],this._loaded&&(this.fire("layerremove",{layer:t}),t.fire("remove")),t._map=t._mapToAdd=null,this):this},hasLayer:function(t){return!!t&&n(t)in this._layers},eachLayer:function(t,i){for(var e in this._layers)t.call(i,this._layers[e]);return this},_addLayers:function(t){for(var i=0,e=(t=t?oi(t)?t:[t]:[]).length;i<e;i++)this.addLayer(t[i])},_addZoomLimit:function(t){!isNaN(t.options.maxZoom)&&isNaN(t.options.minZoom)||(this._zoomBoundLayers[n(t)]=t,this._updateZoomLevels())},_removeZoomLimit:function(t){var i=n(t);this._zoomBoundLayers[i]&&(delete this._zoomBoundLayers[i],this._updateZoomLevels())},_updateZoomLevels:function(){var t=1/0,i=-1/0,e=this._getZoomSpan();for(var n in this._zoomBoundLayers){var o=this._zoomBoundLayers[n].options;t=void 0===o.minZoom?t:Math.min(t,o.minZoom),i=void 0===o.maxZoom?i:Math.max(i,o.maxZoom)}this._layersMaxZoom=i===-1/0?void 0:i,this._layersMinZoom=t===1/0?void 0:t,e!==this._getZoomSpan()&&this.fire("zoomlevelschange"),void 0===this.options.maxZoom&&this._layersMaxZoom&&this.getZoom()>this._layersMaxZoom&&this.setZoom(this._layersMaxZoom),void 0===this.options.minZoom&&this._layersMinZoom&&this.getZoom()<this._layersMinZoom&&this.setZoom(this._layersMinZoom)}});var Ge=qe.extend({initialize:function(t,i){l(this,i),this._layers={};var e,n;if(t)for(e=0,n=t.length;e<n;e++)this.addLayer(t[e])},addLayer:function(t){var i=this.getLayerId(t);return this._layers[i]=t,this._map&&this._map.addLayer(t),this},removeLayer:function(t){var i=t in this._layers?t:this.getLayerId(t);return this._map&&this._layers[i]&&this._map.removeLayer(this._layers[i]),delete this._layers[i],this},hasLayer:function(t){return!!t&&(t in this._layers||this.getLayerId(t)in this._layers)},clearLayers:function(){return this.eachLayer(this.removeLayer,this)},invoke:function(t){var i,e,n=Array.prototype.slice.call(arguments,1);for(i in this._layers)(e=this._layers[i])[t]&&e[t].apply(e,n);return this},onAdd:function(t){this.eachLayer(t.addLayer,t)},onRemove:function(t){this.eachLayer(t.removeLayer,t)},eachLayer:function(t,i){for(var e in this._layers)t.call(i,this._layers[e]);return this},getLayer:function(t){return this._layers[t]},getLayers:function(){var t=[];return this.eachLayer(t.push,t),t},setZIndex:function(t){return this.invoke("setZIndex",t)},getLayerId:function(t){return n(t)}}),Ke=Ge.extend({addLayer:function(t){return this.hasLayer(t)?this:(t.addEventParent(this),Ge.prototype.addLayer.call(this,t),this.fire("layeradd",{layer:t}))},removeLayer:function(t){return this.hasLayer(t)?(t in this._layers&&(t=this._layers[t]),t.removeEventParent(this),Ge.prototype.removeLayer.call(this,t),this.fire("layerremove",{layer:t})):this},setStyle:function(t){return this.invoke("setStyle",t)},bringToFront:function(){return this.invoke("bringToFront")},bringToBack:function(){return this.invoke("bringToBack")},getBounds:function(){var t=new T;for(var i in this._layers){var e=this._layers[i];t.extend(e.getBounds?e.getBounds():e.getLatLng())}return t}}),Ye=v.extend({options:{popupAnchor:[0,0],tooltipAnchor:[0,0]},initialize:function(t){l(this,t)},createIcon:function(t){return this._createIcon("icon",t)},createShadow:function(t){return this._createIcon("shadow",t)},_createIcon:function(t,i){var e=this._getIconUrl(t);if(!e){if("icon"===t)throw new Error("iconUrl not set in Icon options (see the docs).");return null}var n=this._createImg(e,i&&"IMG"===i.tagName?i:null);return this._setIconStyles(n,t),n},_setIconStyles:function(t,i){var e=this.options,n=e[i+"Size"];"number"==typeof n&&(n=[n,n]);var o=w(n),s=w("shadow"===i&&e.shadowAnchor||e.iconAnchor||o&&o.divideBy(2,!0));t.className="leaflet-marker-"+i+" "+(e.className||""),s&&(t.style.marginLeft=-s.x+"px",t.style.marginTop=-s.y+"px"),o&&(t.style.width=o.x+"px",t.style.height=o.y+"px")},_createImg:function(t,i){return i=i||document.createElement("img"),i.src=t,i},_getIconUrl:function(t){return Yi&&this.options[t+"RetinaUrl"]||this.options[t+"Url"]}}),Xe=Ye.extend({options:{iconUrl:"marker-icon.png",iconRetinaUrl:"marker-icon-2x.png",shadowUrl:"marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[16,-28],shadowSize:[41,41]},_getIconUrl:function(t){return Xe.imagePath||(Xe.imagePath=this._detectIconPath()),(this.options.imagePath||Xe.imagePath)+Ye.prototype._getIconUrl.call(this,t)},_detectIconPath:function(){var t=G("div","leaflet-default-icon-path",document.body),i=q(t,"background-image")||q(t,"backgroundImage");return document.body.removeChild(t),i=null===i||0!==i.indexOf("url")?"":i.replace(/^url\(["']?/,"").replace(/marker-icon\.png["']?\)$/,"")}}),Je=Ee.extend({initialize:function(t){this._marker=t},addHooks:function(){var t=this._marker._icon;this._draggable||(this._draggable=new Re(t,t,!0)),this._draggable.on({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).enable(),Q(t,"leaflet-marker-draggable")},removeHooks:function(){this._draggable.off({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).disable(),this._marker._icon&&tt(this._marker._icon,"leaflet-marker-draggable")},moved:function(){return this._draggable&&this._draggable._moved},_adjustPan:function(t){var i=this._marker,e=i._map,n=this._marker.options.autoPanSpeed,o=this._marker.options.autoPanPadding,s=ht(i._icon),r=e.getPixelBounds(),a=e.getPixelOrigin(),h=b(r.min._subtract(a).add(o),r.max._subtract(a).subtract(o));if(!h.contains(s)){var u=w((Math.max(h.max.x,s.x)-h.max.x)/(r.max.x-h.max.x)-(Math.min(h.min.x,s.x)-h.min.x)/(r.min.x-h.min.x),(Math.max(h.max.y,s.y)-h.max.y)/(r.max.y-h.max.y)-(Math.min(h.min.y,s.y)-h.min.y)/(r.min.y-h.min.y)).multiplyBy(n);e.panBy(u,{animate:!1}),this._draggable._newPos._add(u),this._draggable._startPos._add(u),at(i._icon,this._draggable._newPos),this._onDrag(t),this._panRequest=f(this._adjustPan.bind(this,t))}},_onDragStart:function(){this._oldLatLng=this._marker.getLatLng(),this._marker.closePopup().fire("movestart").fire("dragstart")},_onPreDrag:function(t){this._marker.options.autoPan&&(g(this._panRequest),this._panRequest=f(this._adjustPan.bind(this,t)))},_onDrag:function(t){var i=this._marker,e=i._shadow,n=ht(i._icon),o=i._map.layerPointToLatLng(n);e&&at(e,n),i._latlng=o,t.latlng=o,t.oldLatLng=this._oldLatLng,i.fire("move",t).fire("drag",t)},_onDragEnd:function(t){g(this._panRequest),delete this._oldLatLng,this._marker.fire("moveend").fire("dragend",t)}}),$e=qe.extend({options:{icon:new Xe,interactive:!0,keyboard:!0,title:"",alt:"",zIndexOffset:0,opacity:1,riseOnHover:!1,riseOffset:250,pane:"markerPane",bubblingMouseEvents:!1,draggable:!1,autoPan:!1,autoPanPadding:[50,50],autoPanSpeed:10},initialize:function(t,i){l(this,i),this._latlng=C(t)},onAdd:function(t){this._zoomAnimated=this._zoomAnimated&&t.options.markerZoomAnimation,this._zoomAnimated&&t.on("zoomanim",this._animateZoom,this),this._initIcon(),this.update()},onRemove:function(t){this.dragging&&this.dragging.enabled()&&(this.options.draggable=!0,this.dragging.removeHooks()),delete this.dragging,this._zoomAnimated&&t.off("zoomanim",this._animateZoom,this),this._removeIcon(),this._removeShadow()},getEvents:function(){return{zoom:this.update,viewreset:this.update}},getLatLng:function(){return this._latlng},setLatLng:function(t){var i=this._latlng;return this._latlng=C(t),this.update(),this.fire("move",{oldLatLng:i,latlng:this._latlng})},setZIndexOffset:function(t){return this.options.zIndexOffset=t,this.update()},setIcon:function(t){return this.options.icon=t,this._map&&(this._initIcon(),this.update()),this._popup&&this.bindPopup(this._popup,this._popup.options),this},getElement:function(){return this._icon},update:function(){if(this._icon&&this._map){var t=this._map.latLngToLayerPoint(this._latlng).round();this._setPos(t)}return this},_initIcon:function(){var t=this.options,i="leaflet-zoom-"+(this._zoomAnimated?"animated":"hide"),e=t.icon.createIcon(this._icon),n=!1;e!==this._icon&&(this._icon&&this._removeIcon(),n=!0,t.title&&(e.title=t.title),"IMG"===e.tagName&&(e.alt=t.alt||"")),Q(e,i),t.keyboard&&(e.tabIndex="0"),this._icon=e,t.riseOnHover&&this.on({mouseover:this._bringToFront,mouseout:this._resetZIndex});var o=t.icon.createShadow(this._shadow),s=!1;o!==this._shadow&&(this._removeShadow(),s=!0),o&&(Q(o,i),o.alt=""),this._shadow=o,t.opacity<1&&this._updateOpacity(),n&&this.getPane().appendChild(this._icon),this._initInteraction(),o&&s&&this.getPane("shadowPane").appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),K(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&K(this._shadow),this._shadow=null},_setPos:function(t){at(this._icon,t),this._shadow&&at(this._shadow,t),this._zIndex=t.y+this.options.zIndexOffset,this._resetZIndex()},_updateZIndex:function(t){this._icon.style.zIndex=this._zIndex+t},_animateZoom:function(t){var i=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center).round();this._setPos(i)},_initInteraction:function(){if(this.options.interactive&&(Q(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),Je)){var t=this.options.draggable;this.dragging&&(t=this.dragging.enabled(),this.dragging.disable()),this.dragging=new Je(this),t&&this.dragging.enable()}},setOpacity:function(t){return this.options.opacity=t,this._map&&this._updateOpacity(),this},_updateOpacity:function(){var t=this.options.opacity;nt(this._icon,t),this._shadow&&nt(this._shadow,t)},_bringToFront:function(){this._updateZIndex(this.options.riseOffset)},_resetZIndex:function(){this._updateZIndex(0)},_getPopupAnchor:function(){return this.options.icon.options.popupAnchor},_getTooltipAnchor:function(){return this.options.icon.options.tooltipAnchor}}),Qe=qe.extend({options:{stroke:!0,color:"#3388ff",weight:3,opacity:1,lineCap:"round",lineJoin:"round",dashArray:null,dashOffset:null,fill:!1,fillColor:null,fillOpacity:.2,fillRule:"evenodd",interactive:!0,bubblingMouseEvents:!0},beforeAdd:function(t){this._renderer=t.getRenderer(this)},onAdd:function(){this._renderer._initPath(this),this._reset(),this._renderer._addPath(this)},onRemove:function(){this._renderer._removePath(this)},redraw:function(){return this._map&&this._renderer._updatePath(this),this},setStyle:function(t){return l(this,t),this._renderer&&this._renderer._updateStyle(this),this},bringToFront:function(){return this._renderer&&this._renderer._bringToFront(this),this},bringToBack:function(){return this._renderer&&this._renderer._bringToBack(this),this},getElement:function(){return this._path},_reset:function(){this._project(),this._update()},_clickTolerance:function(){return(this.options.stroke?this.options.weight/2:0)+this._renderer.options.tolerance}}),tn=Qe.extend({options:{fill:!0,radius:10},initialize:function(t,i){l(this,i),this._latlng=C(t),this._radius=this.options.radius},setLatLng:function(t){return this._latlng=C(t),this.redraw(),this.fire("move",{latlng:this._latlng})},getLatLng:function(){return this._latlng},setRadius:function(t){return this.options.radius=this._radius=t,this.redraw()},getRadius:function(){return this._radius},setStyle:function(t){var i=t&&t.radius||this._radius;return Qe.prototype.setStyle.call(this,t),this.setRadius(i),this},_project:function(){this._point=this._map.latLngToLayerPoint(this._latlng),this._updateBounds()},_updateBounds:function(){var t=this._radius,i=this._radiusY||t,e=this._clickTolerance(),n=[t+e,i+e];this._pxBounds=new P(this._point.subtract(n),this._point.add(n))},_update:function(){this._map&&this._updatePath()},_updatePath:function(){this._renderer._updateCircle(this)},_empty:function(){return this._radius&&!this._renderer._bounds.intersects(this._pxBounds)},_containsPoint:function(t){return t.distanceTo(this._point)<=this._radius+this._clickTolerance()}}),en=tn.extend({initialize:function(t,e,n){if("number"==typeof e&&(e=i({},n,{radius:e})),l(this,e),this._latlng=C(t),isNaN(this.options.radius))throw new Error("Circle radius cannot be NaN");this._mRadius=this.options.radius},setRadius:function(t){return this._mRadius=t,this.redraw()},getRadius:function(){return this._mRadius},getBounds:function(){var t=[this._radius,this._radiusY||this._radius];return new T(this._map.layerPointToLatLng(this._point.subtract(t)),this._map.layerPointToLatLng(this._point.add(t)))},setStyle:Qe.prototype.setStyle,_project:function(){var t=this._latlng.lng,i=this._latlng.lat,e=this._map,n=e.options.crs;if(n.distance===pi.distance){var o=Math.PI/180,s=this._mRadius/pi.R/o,r=e.project([i+s,t]),a=e.project([i-s,t]),h=r.add(a).divideBy(2),u=e.unproject(h).lat,l=Math.acos((Math.cos(s*o)-Math.sin(i*o)*Math.sin(u*o))/(Math.cos(i*o)*Math.cos(u*o)))/o;(isNaN(l)||0===l)&&(l=s/Math.cos(Math.PI/180*i)),this._point=h.subtract(e.getPixelOrigin()),this._radius=isNaN(l)?0:h.x-e.project([u,t-l]).x,this._radiusY=h.y-r.y}else{var c=n.unproject(n.project(this._latlng).subtract([this._mRadius,0]));this._point=e.latLngToLayerPoint(this._latlng),this._radius=this._point.x-e.latLngToLayerPoint(c).x}this._updateBounds()}}),nn=Qe.extend({options:{smoothFactor:1,noClip:!1},initialize:function(t,i){l(this,i),this._setLatLngs(t)},getLatLngs:function(){return this._latlngs},setLatLngs:function(t){return this._setLatLngs(t),this.redraw()},isEmpty:function(){return!this._latlngs.length},closestLayerPoint:function(t){for(var i,e,n=1/0,o=null,s=Dt,r=0,a=this._parts.length;r<a;r++)for(var h=this._parts[r],u=1,l=h.length;u<l;u++){var c=s(t,i=h[u-1],e=h[u],!0);c<n&&(n=c,o=s(t,i,e))}return o&&(o.distance=Math.sqrt(n)),o},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");var t,i,e,n,o,s,r,a=this._rings[0],h=a.length;if(!h)return null;for(t=0,i=0;t<h-1;t++)i+=a[t].distanceTo(a[t+1])/2;if(0===i)return this._map.layerPointToLatLng(a[0]);for(t=0,n=0;t<h-1;t++)if(o=a[t],s=a[t+1],e=o.distanceTo(s),(n+=e)>i)return r=(n-i)/e,this._map.layerPointToLatLng([s.x-r*(s.x-o.x),s.y-r*(s.y-o.y)])},getBounds:function(){return this._bounds},addLatLng:function(t,i){return i=i||this._defaultShape(),t=C(t),i.push(t),this._bounds.extend(t),this.redraw()},_setLatLngs:function(t){this._bounds=new T,this._latlngs=this._convertLatLngs(t)},_defaultShape:function(){return jt(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(t){for(var i=[],e=jt(t),n=0,o=t.length;n<o;n++)e?(i[n]=C(t[n]),this._bounds.extend(i[n])):i[n]=this._convertLatLngs(t[n]);return i},_project:function(){var t=new P;this._rings=[],this._projectLatlngs(this._latlngs,this._rings,t);var i=this._clickTolerance(),e=new x(i,i);this._bounds.isValid()&&t.isValid()&&(t.min._subtract(e),t.max._add(e),this._pxBounds=t)},_projectLatlngs:function(t,i,e){var n,o,s=t[0]instanceof M,r=t.length;if(s){for(o=[],n=0;n<r;n++)o[n]=this._map.latLngToLayerPoint(t[n]),e.extend(o[n]);i.push(o)}else for(n=0;n<r;n++)this._projectLatlngs(t[n],i,e)},_clipPoints:function(){var t=this._renderer._bounds;if(this._parts=[],this._pxBounds&&this._pxBounds.intersects(t))if(this.options.noClip)this._parts=this._rings;else{var i,e,n,o,s,r,a,h=this._parts;for(i=0,n=0,o=this._rings.length;i<o;i++)for(e=0,s=(a=this._rings[i]).length;e<s-1;e++)(r=It(a[e],a[e+1],t,e,!0))&&(h[n]=h[n]||[],h[n].push(r[0]),r[1]===a[e+1]&&e!==s-2||(h[n].push(r[1]),n++))}},_simplifyPoints:function(){for(var t=this._parts,i=this.options.smoothFactor,e=0,n=t.length;e<n;e++)t[e]=Zt(t[e],i)},_update:function(){this._map&&(this._clipPoints(),this._simplifyPoints(),this._updatePath())},_updatePath:function(){this._renderer._updatePoly(this)},_containsPoint:function(t,i){var e,n,o,s,r,a,h=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(e=0,s=this._parts.length;e<s;e++)for(n=0,o=(r=(a=this._parts[e]).length)-1;n<r;o=n++)if((i||0!==n)&&Et(t,a[o],a[n])<=h)return!0;return!1}});nn._flat=Wt;var on=nn.extend({options:{fill:!0},isEmpty:function(){return!this._latlngs.length||!this._latlngs[0].length},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");var t,i,e,n,o,s,r,a,h,u=this._rings[0],l=u.length;if(!l)return null;for(s=r=a=0,t=0,i=l-1;t<l;i=t++)e=u[t],n=u[i],o=e.y*n.x-n.y*e.x,r+=(e.x+n.x)*o,a+=(e.y+n.y)*o,s+=3*o;return h=0===s?u[0]:[r/s,a/s],this._map.layerPointToLatLng(h)},_convertLatLngs:function(t){var i=nn.prototype._convertLatLngs.call(this,t),e=i.length;return e>=2&&i[0]instanceof M&&i[0].equals(i[e-1])&&i.pop(),i},_setLatLngs:function(t){nn.prototype._setLatLngs.call(this,t),jt(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return jt(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var t=this._renderer._bounds,i=this.options.weight,e=new x(i,i);if(t=new P(t.min.subtract(e),t.max.add(e)),this._parts=[],this._pxBounds&&this._pxBounds.intersects(t))if(this.options.noClip)this._parts=this._rings;else for(var n,o=0,s=this._rings.length;o<s;o++)(n=Ht(this._rings[o],t,!0)).length&&this._parts.push(n)},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(t){var i,e,n,o,s,r,a,h,u=!1;if(!this._pxBounds||!this._pxBounds.contains(t))return!1;for(o=0,a=this._parts.length;o<a;o++)for(s=0,r=(h=(i=this._parts[o]).length)-1;s<h;r=s++)e=i[s],n=i[r],e.y>t.y!=n.y>t.y&&t.x<(n.x-e.x)*(t.y-e.y)/(n.y-e.y)+e.x&&(u=!u);return u||nn.prototype._containsPoint.call(this,t,!0)}}),sn=Ke.extend({initialize:function(t,i){l(this,i),this._layers={},t&&this.addData(t)},addData:function(t){var i,e,n,o=oi(t)?t:t.features;if(o){for(i=0,e=o.length;i<e;i++)((n=o[i]).geometries||n.geometry||n.features||n.coordinates)&&this.addData(n);return this}var s=this.options;if(s.filter&&!s.filter(t))return this;var r=Ft(t,s);return r?(r.feature=Yt(t),r.defaultOptions=r.options,this.resetStyle(r),s.onEachFeature&&s.onEachFeature(t,r),this.addLayer(r)):this},resetStyle:function(t){return t.options=i({},t.defaultOptions),this._setLayerStyle(t,this.options.style),this},setStyle:function(t){return this.eachLayer(function(i){this._setLayerStyle(i,t)},this)},_setLayerStyle:function(t,i){"function"==typeof i&&(i=i(t.feature)),t.setStyle&&t.setStyle(i)}}),rn={toGeoJSON:function(t){return Kt(this,{type:"Point",coordinates:qt(this.getLatLng(),t)})}};$e.include(rn),en.include(rn),tn.include(rn),nn.include({toGeoJSON:function(t){var i=!jt(this._latlngs),e=Gt(this._latlngs,i?1:0,!1,t);return Kt(this,{type:(i?"Multi":"")+"LineString",coordinates:e})}}),on.include({toGeoJSON:function(t){var i=!jt(this._latlngs),e=i&&!jt(this._latlngs[0]),n=Gt(this._latlngs,e?2:i?1:0,!0,t);return i||(n=[n]),Kt(this,{type:(e?"Multi":"")+"Polygon",coordinates:n})}}),Ge.include({toMultiPoint:function(t){var i=[];return this.eachLayer(function(e){i.push(e.toGeoJSON(t).geometry.coordinates)}),Kt(this,{type:"MultiPoint",coordinates:i})},toGeoJSON:function(t){var i=this.feature&&this.feature.geometry&&this.feature.geometry.type;if("MultiPoint"===i)return this.toMultiPoint(t);var e="GeometryCollection"===i,n=[];return this.eachLayer(function(i){if(i.toGeoJSON){var o=i.toGeoJSON(t);if(e)n.push(o.geometry);else{var s=Yt(o);"FeatureCollection"===s.type?n.push.apply(n,s.features):n.push(s)}}}),e?Kt(this,{geometries:n,type:"GeometryCollection"}):{type:"FeatureCollection",features:n}}});var an=Xt,hn=qe.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(t,i,e){this._url=t,this._bounds=z(i),l(this,e)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(Q(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){K(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(t){return this.options.opacity=t,this._image&&this._updateOpacity(),this},setStyle:function(t){return t.opacity&&this.setOpacity(t.opacity),this},bringToFront:function(){return this._map&&X(this._image),this},bringToBack:function(){return this._map&&J(this._image),this},setUrl:function(t){return this._url=t,this._image&&(this._image.src=t),this},setBounds:function(t){return this._bounds=z(t),this._map&&this._reset(),this},getEvents:function(){var t={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(t.zoomanim=this._animateZoom),t},setZIndex:function(t){return this.options.zIndex=t,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var t="IMG"===this._url.tagName,i=this._image=t?this._url:G("img");Q(i,"leaflet-image-layer"),this._zoomAnimated&&Q(i,"leaflet-zoom-animated"),this.options.className&&Q(i,this.options.className),i.onselectstart=r,i.onmousemove=r,i.onload=e(this.fire,this,"load"),i.onerror=e(this._overlayOnError,this,"error"),(this.options.crossOrigin||""===this.options.crossOrigin)&&(i.crossOrigin=!0===this.options.crossOrigin?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),t?this._url=i.src:(i.src=this._url,i.alt=this.options.alt)},_animateZoom:function(t){var i=this._map.getZoomScale(t.zoom),e=this._map._latLngBoundsToNewLayerBounds(this._bounds,t.zoom,t.center).min;rt(this._image,e,i)},_reset:function(){var t=this._image,i=new P(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),e=i.getSize();at(t,i.min),t.style.width=e.x+"px",t.style.height=e.y+"px"},_updateOpacity:function(){nt(this._image,this.options.opacity)},_updateZIndex:function(){this._image&&void 0!==this.options.zIndex&&null!==this.options.zIndex&&(this._image.style.zIndex=this.options.zIndex)},_overlayOnError:function(){this.fire("error");var t=this.options.errorOverlayUrl;t&&this._url!==t&&(this._url=t,this._image.src=t)}}),un=hn.extend({options:{autoplay:!0,loop:!0},_initImage:function(){var t="VIDEO"===this._url.tagName,i=this._image=t?this._url:G("video");if(Q(i,"leaflet-image-layer"),this._zoomAnimated&&Q(i,"leaflet-zoom-animated"),i.onselectstart=r,i.onmousemove=r,i.onloadeddata=e(this.fire,this,"load"),t){for(var n=i.getElementsByTagName("source"),o=[],s=0;s<n.length;s++)o.push(n[s].src);this._url=n.length>0?o:[i.src]}else{oi(this._url)||(this._url=[this._url]),i.autoplay=!!this.options.autoplay,i.loop=!!this.options.loop;for(var a=0;a<this._url.length;a++){var h=G("source");h.src=this._url[a],i.appendChild(h)}}}}),ln=qe.extend({options:{offset:[0,7],className:"",pane:"popupPane"},initialize:function(t,i){l(this,t),this._source=i},onAdd:function(t){this._zoomAnimated=t._zoomAnimated,this._container||this._initLayout(),t._fadeAnimated&&nt(this._container,0),clearTimeout(this._removeTimeout),this.getPane().appendChild(this._container),this.update(),t._fadeAnimated&&nt(this._container,1),this.bringToFront()},onRemove:function(t){t._fadeAnimated?(nt(this._container,0),this._removeTimeout=setTimeout(e(K,void 0,this._container),200)):K(this._container)},getLatLng:function(){return this._latlng},setLatLng:function(t){return this._latlng=C(t),this._map&&(this._updatePosition(),this._adjustPan()),this},getContent:function(){return this._content},setContent:function(t){return this._content=t,this.update(),this},getElement:function(){return this._container},update:function(){this._map&&(this._container.style.visibility="hidden",this._updateContent(),this._updateLayout(),this._updatePosition(),this._container.style.visibility="",this._adjustPan())},getEvents:function(){var t={zoom:this._updatePosition,viewreset:this._updatePosition};return this._zoomAnimated&&(t.zoomanim=this._animateZoom),t},isOpen:function(){return!!this._map&&this._map.hasLayer(this)},bringToFront:function(){return this._map&&X(this._container),this},bringToBack:function(){return this._map&&J(this._container),this},_updateContent:function(){if(this._content){var t=this._contentNode,i="function"==typeof this._content?this._content(this._source||this):this._content;if("string"==typeof i)t.innerHTML=i;else{for(;t.hasChildNodes();)t.removeChild(t.firstChild);t.appendChild(i)}this.fire("contentupdate")}},_updatePosition:function(){if(this._map){var t=this._map.latLngToLayerPoint(this._latlng),i=w(this.options.offset),e=this._getAnchor();this._zoomAnimated?at(this._container,t.add(e)):i=i.add(t).add(e);var n=this._containerBottom=-i.y,o=this._containerLeft=-Math.round(this._containerWidth/2)+i.x;this._container.style.bottom=n+"px",this._container.style.left=o+"px"}},_getAnchor:function(){return[0,0]}}),cn=ln.extend({options:{maxWidth:300,minWidth:50,maxHeight:null,autoPan:!0,autoPanPaddingTopLeft:null,autoPanPaddingBottomRight:null,autoPanPadding:[5,5],keepInView:!1,closeButton:!0,autoClose:!0,closeOnEscapeKey:!0,className:""},openOn:function(t){return t.openPopup(this),this},onAdd:function(t){ln.prototype.onAdd.call(this,t),t.fire("popupopen",{popup:this}),this._source&&(this._source.fire("popupopen",{popup:this},!0),this._source instanceof Qe||this._source.on("preclick",yt))},onRemove:function(t){ln.prototype.onRemove.call(this,t),t.fire("popupclose",{popup:this}),this._source&&(this._source.fire("popupclose",{popup:this},!0),this._source instanceof Qe||this._source.off("preclick",yt))},getEvents:function(){var t=ln.prototype.getEvents.call(this);return(void 0!==this.options.closeOnClick?this.options.closeOnClick:this._map.options.closePopupOnClick)&&(t.preclick=this._close),this.options.keepInView&&(t.moveend=this._adjustPan),t},_close:function(){this._map&&this._map.closePopup(this)},_initLayout:function(){var t="leaflet-popup",i=this._container=G("div",t+" "+(this.options.className||"")+" leaflet-zoom-animated"),e=this._wrapper=G("div",t+"-content-wrapper",i);if(this._contentNode=G("div",t+"-content",e),wt(e),xt(this._contentNode),mt(e,"contextmenu",yt),this._tipContainer=G("div",t+"-tip-container",i),this._tip=G("div",t+"-tip",this._tipContainer),this.options.closeButton){var n=this._closeButton=G("a",t+"-close-button",i);n.href="#close",n.innerHTML="&#215;",mt(n,"click",this._onCloseButtonClick,this)}},_updateLayout:function(){var t=this._contentNode,i=t.style;i.width="",i.whiteSpace="nowrap";var e=t.offsetWidth;e=Math.min(e,this.options.maxWidth),e=Math.max(e,this.options.minWidth),i.width=e+1+"px",i.whiteSpace="",i.height="";var n=t.offsetHeight,o=this.options.maxHeight;o&&n>o?(i.height=o+"px",Q(t,"leaflet-popup-scrolled")):tt(t,"leaflet-popup-scrolled"),this._containerWidth=this._container.offsetWidth},_animateZoom:function(t){var i=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center),e=this._getAnchor();at(this._container,i.add(e))},_adjustPan:function(){if(!(!this.options.autoPan||this._map._panAnim&&this._map._panAnim._inProgress)){var t=this._map,i=parseInt(q(this._container,"marginBottom"),10)||0,e=this._container.offsetHeight+i,n=this._containerWidth,o=new x(this._containerLeft,-e-this._containerBottom);o._add(ht(this._container));var s=t.layerPointToContainerPoint(o),r=w(this.options.autoPanPadding),a=w(this.options.autoPanPaddingTopLeft||r),h=w(this.options.autoPanPaddingBottomRight||r),u=t.getSize(),l=0,c=0;s.x+n+h.x>u.x&&(l=s.x+n-u.x+h.x),s.x-l-a.x<0&&(l=s.x-a.x),s.y+e+h.y>u.y&&(c=s.y+e-u.y+h.y),s.y-c-a.y<0&&(c=s.y-a.y),(l||c)&&t.fire("autopanstart").panBy([l,c])}},_onCloseButtonClick:function(t){this._close(),Lt(t)},_getAnchor:function(){return w(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}});be.mergeOptions({closePopupOnClick:!0}),be.include({openPopup:function(t,i,e){return t instanceof cn||(t=new cn(e).setContent(t)),i&&t.setLatLng(i),this.hasLayer(t)?this:(this._popup&&this._popup.options.autoClose&&this.closePopup(),this._popup=t,this.addLayer(t))},closePopup:function(t){return t&&t!==this._popup||(t=this._popup,this._popup=null),t&&this.removeLayer(t),this}}),qe.include({bindPopup:function(t,i){return t instanceof cn?(l(t,i),this._popup=t,t._source=this):(this._popup&&!i||(this._popup=new cn(i,this)),this._popup.setContent(t)),this._popupHandlersAdded||(this.on({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!0),this},unbindPopup:function(){return this._popup&&(this.off({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!1,this._popup=null),this},openPopup:function(t,i){if(t instanceof qe||(i=t,t=this),t instanceof Ke)for(var e in this._layers){t=this._layers[e];break}return i||(i=t.getCenter?t.getCenter():t.getLatLng()),this._popup&&this._map&&(this._popup._source=t,this._popup.update(),this._map.openPopup(this._popup,i)),this},closePopup:function(){return this._popup&&this._popup._close(),this},togglePopup:function(t){return this._popup&&(this._popup._map?this.closePopup():this.openPopup(t)),this},isPopupOpen:function(){return!!this._popup&&this._popup.isOpen()},setPopupContent:function(t){return this._popup&&this._popup.setContent(t),this},getPopup:function(){return this._popup},_openPopup:function(t){var i=t.layer||t.target;this._popup&&this._map&&(Lt(t),i instanceof Qe?this.openPopup(t.layer||t.target,t.latlng):this._map.hasLayer(this._popup)&&this._popup._source===i?this.closePopup():this.openPopup(i,t.latlng))},_movePopup:function(t){this._popup.setLatLng(t.latlng)},_onKeyPress:function(t){13===t.originalEvent.keyCode&&this._openPopup(t)}});var _n=ln.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,interactive:!1,opacity:.9},onAdd:function(t){ln.prototype.onAdd.call(this,t),this.setOpacity(this.options.opacity),t.fire("tooltipopen",{tooltip:this}),this._source&&this._source.fire("tooltipopen",{tooltip:this},!0)},onRemove:function(t){ln.prototype.onRemove.call(this,t),t.fire("tooltipclose",{tooltip:this}),this._source&&this._source.fire("tooltipclose",{tooltip:this},!0)},getEvents:function(){var t=ln.prototype.getEvents.call(this);return qi&&!this.options.permanent&&(t.preclick=this._close),t},_close:function(){this._map&&this._map.closeTooltip(this)},_initLayout:function(){var t="leaflet-tooltip "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=G("div",t)},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(t){var i=this._map,e=this._container,n=i.latLngToContainerPoint(i.getCenter()),o=i.layerPointToContainerPoint(t),s=this.options.direction,r=e.offsetWidth,a=e.offsetHeight,h=w(this.options.offset),u=this._getAnchor();"top"===s?t=t.add(w(-r/2+h.x,-a+h.y+u.y,!0)):"bottom"===s?t=t.subtract(w(r/2-h.x,-h.y,!0)):"center"===s?t=t.subtract(w(r/2+h.x,a/2-u.y+h.y,!0)):"right"===s||"auto"===s&&o.x<n.x?(s="right",t=t.add(w(h.x+u.x,u.y-a/2+h.y,!0))):(s="left",t=t.subtract(w(r+u.x-h.x,a/2-u.y-h.y,!0))),tt(e,"leaflet-tooltip-right"),tt(e,"leaflet-tooltip-left"),tt(e,"leaflet-tooltip-top"),tt(e,"leaflet-tooltip-bottom"),Q(e,"leaflet-tooltip-"+s),at(e,t)},_updatePosition:function(){var t=this._map.latLngToLayerPoint(this._latlng);this._setPosition(t)},setOpacity:function(t){this.options.opacity=t,this._container&&nt(this._container,t)},_animateZoom:function(t){var i=this._map._latLngToNewLayerPoint(this._latlng,t.zoom,t.center);this._setPosition(i)},_getAnchor:function(){return w(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}});be.include({openTooltip:function(t,i,e){return t instanceof _n||(t=new _n(e).setContent(t)),i&&t.setLatLng(i),this.hasLayer(t)?this:this.addLayer(t)},closeTooltip:function(t){return t&&this.removeLayer(t),this}}),qe.include({bindTooltip:function(t,i){return t instanceof _n?(l(t,i),this._tooltip=t,t._source=this):(this._tooltip&&!i||(this._tooltip=new _n(i,this)),this._tooltip.setContent(t)),this._initTooltipInteractions(),this._tooltip.options.permanent&&this._map&&this._map.hasLayer(this)&&this.openTooltip(),this},unbindTooltip:function(){return this._tooltip&&(this._initTooltipInteractions(!0),this.closeTooltip(),this._tooltip=null),this},_initTooltipInteractions:function(t){if(t||!this._tooltipHandlersAdded){var i=t?"off":"on",e={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?e.add=this._openTooltip:(e.mouseover=this._openTooltip,e.mouseout=this.closeTooltip,this._tooltip.options.sticky&&(e.mousemove=this._moveTooltip),qi&&(e.click=this._openTooltip)),this[i](e),this._tooltipHandlersAdded=!t}},openTooltip:function(t,i){if(t instanceof qe||(i=t,t=this),t instanceof Ke)for(var e in this._layers){t=this._layers[e];break}return i||(i=t.getCenter?t.getCenter():t.getLatLng()),this._tooltip&&this._map&&(this._tooltip._source=t,this._tooltip.update(),this._map.openTooltip(this._tooltip,i),this._tooltip.options.interactive&&this._tooltip._container&&(Q(this._tooltip._container,"leaflet-clickable"),this.addInteractiveTarget(this._tooltip._container))),this},closeTooltip:function(){return this._tooltip&&(this._tooltip._close(),this._tooltip.options.interactive&&this._tooltip._container&&(tt(this._tooltip._container,"leaflet-clickable"),this.removeInteractiveTarget(this._tooltip._container))),this},toggleTooltip:function(t){return this._tooltip&&(this._tooltip._map?this.closeTooltip():this.openTooltip(t)),this},isTooltipOpen:function(){return this._tooltip.isOpen()},setTooltipContent:function(t){return this._tooltip&&this._tooltip.setContent(t),this},getTooltip:function(){return this._tooltip},_openTooltip:function(t){var i=t.layer||t.target;this._tooltip&&this._map&&this.openTooltip(i,this._tooltip.options.sticky?t.latlng:void 0)},_moveTooltip:function(t){var i,e,n=t.latlng;this._tooltip.options.sticky&&t.originalEvent&&(i=this._map.mouseEventToContainerPoint(t.originalEvent),e=this._map.containerPointToLayerPoint(i),n=this._map.layerPointToLatLng(e)),this._tooltip.setLatLng(n)}});var dn=Ye.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(t){var i=t&&"DIV"===t.tagName?t:document.createElement("div"),e=this.options;if(i.innerHTML=!1!==e.html?e.html:"",e.bgPos){var n=w(e.bgPos);i.style.backgroundPosition=-n.x+"px "+-n.y+"px"}return this._setIconStyles(i,"icon"),i},createShadow:function(){return null}});Ye.Default=Xe;var pn=qe.extend({options:{tileSize:256,opacity:1,updateWhenIdle:Wi,updateWhenZooming:!0,updateInterval:200,zIndex:1,bounds:null,minZoom:0,maxZoom:void 0,maxNativeZoom:void 0,minNativeZoom:void 0,noWrap:!1,pane:"tilePane",className:"",keepBuffer:2},initialize:function(t){l(this,t)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView(),this._update()},beforeAdd:function(t){t._addZoomLimit(this)},onRemove:function(t){this._removeAllTiles(),K(this._container),t._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(X(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(J(this._container),this._setAutoZIndex(Math.min)),this},getContainer:function(){return this._container},setOpacity:function(t){return this.options.opacity=t,this._updateOpacity(),this},setZIndex:function(t){return this.options.zIndex=t,this._updateZIndex(),this},isLoading:function(){return this._loading},redraw:function(){return this._map&&(this._removeAllTiles(),this._update()),this},getEvents:function(){var t={viewprereset:this._invalidateAll,viewreset:this._resetView,zoom:this._resetView,moveend:this._onMoveEnd};return this.options.updateWhenIdle||(this._onMove||(this._onMove=o(this._onMoveEnd,this.options.updateInterval,this)),t.move=this._onMove),this._zoomAnimated&&(t.zoomanim=this._animateZoom),t},createTile:function(){return document.createElement("div")},getTileSize:function(){var t=this.options.tileSize;return t instanceof x?t:new x(t,t)},_updateZIndex:function(){this._container&&void 0!==this.options.zIndex&&null!==this.options.zIndex&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(t){for(var i,e=this.getPane().children,n=-t(-1/0,1/0),o=0,s=e.length;o<s;o++)i=e[o].style.zIndex,e[o]!==this._container&&i&&(n=t(n,+i));isFinite(n)&&(this.options.zIndex=n+t(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!Li){nt(this._container,this.options.opacity);var t=+new Date,i=!1,e=!1;for(var n in this._tiles){var o=this._tiles[n];if(o.current&&o.loaded){var s=Math.min(1,(t-o.loaded)/200);nt(o.el,s),s<1?i=!0:(o.active?e=!0:this._onOpaqueTile(o),o.active=!0)}}e&&!this._noPrune&&this._pruneTiles(),i&&(g(this._fadeFrame),this._fadeFrame=f(this._updateOpacity,this))}},_onOpaqueTile:r,_initContainer:function(){this._container||(this._container=G("div","leaflet-layer "+(this.options.className||"")),this._updateZIndex(),this.options.opacity<1&&this._updateOpacity(),this.getPane().appendChild(this._container))},_updateLevels:function(){var t=this._tileZoom,i=this.options.maxZoom;if(void 0!==t){for(var e in this._levels)this._levels[e].el.children.length||e===t?(this._levels[e].el.style.zIndex=i-Math.abs(t-e),this._onUpdateLevel(e)):(K(this._levels[e].el),this._removeTilesAtZoom(e),this._onRemoveLevel(e),delete this._levels[e]);var n=this._levels[t],o=this._map;return n||((n=this._levels[t]={}).el=G("div","leaflet-tile-container leaflet-zoom-animated",this._container),n.el.style.zIndex=i,n.origin=o.project(o.unproject(o.getPixelOrigin()),t).round(),n.zoom=t,this._setZoomTransform(n,o.getCenter(),o.getZoom()),n.el.offsetWidth,this._onCreateLevel(n)),this._level=n,n}},_onUpdateLevel:r,_onRemoveLevel:r,_onCreateLevel:r,_pruneTiles:function(){if(this._map){var t,i,e=this._map.getZoom();if(e>this.options.maxZoom||e<this.options.minZoom)this._removeAllTiles();else{for(t in this._tiles)(i=this._tiles[t]).retain=i.current;for(t in this._tiles)if((i=this._tiles[t]).current&&!i.active){var n=i.coords;this._retainParent(n.x,n.y,n.z,n.z-5)||this._retainChildren(n.x,n.y,n.z,n.z+2)}for(t in this._tiles)this._tiles[t].retain||this._removeTile(t)}}},_removeTilesAtZoom:function(t){for(var i in this._tiles)this._tiles[i].coords.z===t&&this._removeTile(i)},_removeAllTiles:function(){for(var t in this._tiles)this._removeTile(t)},_invalidateAll:function(){for(var t in this._levels)K(this._levels[t].el),this._onRemoveLevel(t),delete this._levels[t];this._removeAllTiles(),this._tileZoom=void 0},_retainParent:function(t,i,e,n){var o=Math.floor(t/2),s=Math.floor(i/2),r=e-1,a=new x(+o,+s);a.z=+r;var h=this._tileCoordsToKey(a),u=this._tiles[h];return u&&u.active?(u.retain=!0,!0):(u&&u.loaded&&(u.retain=!0),r>n&&this._retainParent(o,s,r,n))},_retainChildren:function(t,i,e,n){for(var o=2*t;o<2*t+2;o++)for(var s=2*i;s<2*i+2;s++){var r=new x(o,s);r.z=e+1;var a=this._tileCoordsToKey(r),h=this._tiles[a];h&&h.active?h.retain=!0:(h&&h.loaded&&(h.retain=!0),e+1<n&&this._retainChildren(o,s,e+1,n))}},_resetView:function(t){var i=t&&(t.pinch||t.flyTo);this._setView(this._map.getCenter(),this._map.getZoom(),i,i)},_animateZoom:function(t){this._setView(t.center,t.zoom,!0,t.noUpdate)},_clampZoom:function(t){var i=this.options;return void 0!==i.minNativeZoom&&t<i.minNativeZoom?i.minNativeZoom:void 0!==i.maxNativeZoom&&i.maxNativeZoom<t?i.maxNativeZoom:t},_setView:function(t,i,e,n){var o=this._clampZoom(Math.round(i));(void 0!==this.options.maxZoom&&o>this.options.maxZoom||void 0!==this.options.minZoom&&o<this.options.minZoom)&&(o=void 0);var s=this.options.updateWhenZooming&&o!==this._tileZoom;n&&!s||(this._tileZoom=o,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),void 0!==o&&this._update(t),e||this._pruneTiles(),this._noPrune=!!e),this._setZoomTransforms(t,i)},_setZoomTransforms:function(t,i){for(var e in this._levels)this._setZoomTransform(this._levels[e],t,i)},_setZoomTransform:function(t,i,e){var n=this._map.getZoomScale(e,t.zoom),o=t.origin.multiplyBy(n).subtract(this._map._getNewPixelOrigin(i,e)).round();ji?rt(t.el,o,n):at(t.el,o)},_resetGrid:function(){var t=this._map,i=t.options.crs,e=this._tileSize=this.getTileSize(),n=this._tileZoom,o=this._map.getPixelWorldBounds(this._tileZoom);o&&(this._globalTileRange=this._pxBoundsToTileRange(o)),this._wrapX=i.wrapLng&&!this.options.noWrap&&[Math.floor(t.project([0,i.wrapLng[0]],n).x/e.x),Math.ceil(t.project([0,i.wrapLng[1]],n).x/e.y)],this._wrapY=i.wrapLat&&!this.options.noWrap&&[Math.floor(t.project([i.wrapLat[0],0],n).y/e.x),Math.ceil(t.project([i.wrapLat[1],0],n).y/e.y)]},_onMoveEnd:function(){this._map&&!this._map._animatingZoom&&this._update()},_getTiledPixelBounds:function(t){var i=this._map,e=i._animatingZoom?Math.max(i._animateToZoom,i.getZoom()):i.getZoom(),n=i.getZoomScale(e,this._tileZoom),o=i.project(t,this._tileZoom).floor(),s=i.getSize().divideBy(2*n);return new P(o.subtract(s),o.add(s))},_update:function(t){var i=this._map;if(i){var e=this._clampZoom(i.getZoom());if(void 0===t&&(t=i.getCenter()),void 0!==this._tileZoom){var n=this._getTiledPixelBounds(t),o=this._pxBoundsToTileRange(n),s=o.getCenter(),r=[],a=this.options.keepBuffer,h=new P(o.getBottomLeft().subtract([a,-a]),o.getTopRight().add([a,-a]));if(!(isFinite(o.min.x)&&isFinite(o.min.y)&&isFinite(o.max.x)&&isFinite(o.max.y)))throw new Error("Attempted to load an infinite number of tiles");for(var u in this._tiles){var l=this._tiles[u].coords;l.z===this._tileZoom&&h.contains(new x(l.x,l.y))||(this._tiles[u].current=!1)}if(Math.abs(e-this._tileZoom)>1)this._setView(t,e);else{for(var c=o.min.y;c<=o.max.y;c++)for(var _=o.min.x;_<=o.max.x;_++){var d=new x(_,c);if(d.z=this._tileZoom,this._isValidTile(d)){var p=this._tiles[this._tileCoordsToKey(d)];p?p.current=!0:r.push(d)}}if(r.sort(function(t,i){return t.distanceTo(s)-i.distanceTo(s)}),0!==r.length){this._loading||(this._loading=!0,this.fire("loading"));var m=document.createDocumentFragment();for(_=0;_<r.length;_++)this._addTile(r[_],m);this._level.el.appendChild(m)}}}}},_isValidTile:function(t){var i=this._map.options.crs;if(!i.infinite){var e=this._globalTileRange;if(!i.wrapLng&&(t.x<e.min.x||t.x>e.max.x)||!i.wrapLat&&(t.y<e.min.y||t.y>e.max.y))return!1}if(!this.options.bounds)return!0;var n=this._tileCoordsToBounds(t);return z(this.options.bounds).overlaps(n)},_keyToBounds:function(t){return this._tileCoordsToBounds(this._keyToTileCoords(t))},_tileCoordsToNwSe:function(t){var i=this._map,e=this.getTileSize(),n=t.scaleBy(e),o=n.add(e);return[i.unproject(n,t.z),i.unproject(o,t.z)]},_tileCoordsToBounds:function(t){var i=this._tileCoordsToNwSe(t),e=new T(i[0],i[1]);return this.options.noWrap||(e=this._map.wrapLatLngBounds(e)),e},_tileCoordsToKey:function(t){return t.x+":"+t.y+":"+t.z},_keyToTileCoords:function(t){var i=t.split(":"),e=new x(+i[0],+i[1]);return e.z=+i[2],e},_removeTile:function(t){var i=this._tiles[t];i&&(K(i.el),delete this._tiles[t],this.fire("tileunload",{tile:i.el,coords:this._keyToTileCoords(t)}))},_initTile:function(t){Q(t,"leaflet-tile");var i=this.getTileSize();t.style.width=i.x+"px",t.style.height=i.y+"px",t.onselectstart=r,t.onmousemove=r,Li&&this.options.opacity<1&&nt(t,this.options.opacity),zi&&!Mi&&(t.style.WebkitBackfaceVisibility="hidden")},_addTile:function(t,i){var n=this._getTilePos(t),o=this._tileCoordsToKey(t),s=this.createTile(this._wrapCoords(t),e(this._tileReady,this,t));this._initTile(s),this.createTile.length<2&&f(e(this._tileReady,this,t,null,s)),at(s,n),this._tiles[o]={el:s,coords:t,current:!0},i.appendChild(s),this.fire("tileloadstart",{tile:s,coords:t})},_tileReady:function(t,i,n){i&&this.fire("tileerror",{error:i,tile:n,coords:t});var o=this._tileCoordsToKey(t);(n=this._tiles[o])&&(n.loaded=+new Date,this._map._fadeAnimated?(nt(n.el,0),g(this._fadeFrame),this._fadeFrame=f(this._updateOpacity,this)):(n.active=!0,this._pruneTiles()),i||(Q(n.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:n.el,coords:t})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),Li||!this._map._fadeAnimated?f(this._pruneTiles,this):setTimeout(e(this._pruneTiles,this),250)))},_getTilePos:function(t){return t.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(t){var i=new x(this._wrapX?s(t.x,this._wrapX):t.x,this._wrapY?s(t.y,this._wrapY):t.y);return i.z=t.z,i},_pxBoundsToTileRange:function(t){var i=this.getTileSize();return new P(t.min.unscaleBy(i).floor(),t.max.unscaleBy(i).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var t in this._tiles)if(!this._tiles[t].loaded)return!1;return!0}}),mn=pn.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1},initialize:function(t,i){this._url=t,(i=l(this,i)).detectRetina&&Yi&&i.maxZoom>0&&(i.tileSize=Math.floor(i.tileSize/2),i.zoomReverse?(i.zoomOffset--,i.minZoom++):(i.zoomOffset++,i.maxZoom--),i.minZoom=Math.max(0,i.minZoom)),"string"==typeof i.subdomains&&(i.subdomains=i.subdomains.split("")),zi||this.on("tileunload",this._onTileRemove)},setUrl:function(t,i){return this._url=t,i||this.redraw(),this},createTile:function(t,i){var n=document.createElement("img");return mt(n,"load",e(this._tileOnLoad,this,i,n)),mt(n,"error",e(this._tileOnError,this,i,n)),(this.options.crossOrigin||""===this.options.crossOrigin)&&(n.crossOrigin=!0===this.options.crossOrigin?"":this.options.crossOrigin),n.alt="",n.setAttribute("role","presentation"),n.src=this.getTileUrl(t),n},getTileUrl:function(t){var e={r:Yi?"@2x":"",s:this._getSubdomain(t),x:t.x,y:t.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var n=this._globalTileRange.max.y-t.y;this.options.tms&&(e.y=n),e["-y"]=n}return _(this._url,i(e,this.options))},_tileOnLoad:function(t,i){Li?setTimeout(e(t,this,null,i),0):t(null,i)},_tileOnError:function(t,i,e){var n=this.options.errorTileUrl;n&&i.getAttribute("src")!==n&&(i.src=n),t(e,i)},_onTileRemove:function(t){t.tile.onload=null},_getZoomForUrl:function(){var t=this._tileZoom,i=this.options.maxZoom,e=this.options.zoomReverse,n=this.options.zoomOffset;return e&&(t=i-t),t+n},_getSubdomain:function(t){var i=Math.abs(t.x+t.y)%this.options.subdomains.length;return this.options.subdomains[i]},_abortLoading:function(){var t,i;for(t in this._tiles)this._tiles[t].coords.z!==this._tileZoom&&((i=this._tiles[t].el).onload=r,i.onerror=r,i.complete||(i.src=si,K(i),delete this._tiles[t]))},_removeTile:function(t){var i=this._tiles[t];if(i)return Si||i.el.setAttribute("src",si),pn.prototype._removeTile.call(this,t)},_tileReady:function(t,i,e){if(this._map&&(!e||e.getAttribute("src")!==si))return pn.prototype._tileReady.call(this,t,i,e)}}),fn=mn.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(t,e){this._url=t;var n=i({},this.defaultWmsParams);for(var o in e)o in this.options||(n[o]=e[o]);var s=(e=l(this,e)).detectRetina&&Yi?2:1,r=this.getTileSize();n.width=r.x*s,n.height=r.y*s,this.wmsParams=n},onAdd:function(t){this._crs=this.options.crs||t.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var i=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[i]=this._crs.code,mn.prototype.onAdd.call(this,t)},getTileUrl:function(t){var i=this._tileCoordsToNwSe(t),e=this._crs,n=b(e.project(i[0]),e.project(i[1])),o=n.min,s=n.max,r=(this._wmsVersion>=1.3&&this._crs===Ue?[o.y,o.x,s.y,s.x]:[o.x,o.y,s.x,s.y]).join(","),a=mn.prototype.getTileUrl.call(this,t);return a+c(this.wmsParams,a,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+r},setParams:function(t,e){return i(this.wmsParams,t),e||this.redraw(),this}});mn.WMS=fn,Jt.wms=function(t,i){return new fn(t,i)};var gn=qe.extend({options:{padding:.1,tolerance:0},initialize:function(t){l(this,t),n(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),this._zoomAnimated&&Q(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var t={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(t.zoomanim=this._onAnimZoom),t},_onAnimZoom:function(t){this._updateTransform(t.center,t.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(t,i){var e=this._map.getZoomScale(i,this._zoom),n=ht(this._container),o=this._map.getSize().multiplyBy(.5+this.options.padding),s=this._map.project(this._center,i),r=this._map.project(t,i).subtract(s),a=o.multiplyBy(-e).add(n).add(o).subtract(r);ji?rt(this._container,a,e):at(this._container,a)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var t in this._layers)this._layers[t]._reset()},_onZoomEnd:function(){for(var t in this._layers)this._layers[t]._project()},_updatePaths:function(){for(var t in this._layers)this._layers[t]._update()},_update:function(){var t=this.options.padding,i=this._map.getSize(),e=this._map.containerPointToLayerPoint(i.multiplyBy(-t)).round();this._bounds=new P(e,e.add(i.multiplyBy(1+2*t)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),vn=gn.extend({getEvents:function(){var t=gn.prototype.getEvents.call(this);return t.viewprereset=this._onViewPreReset,t},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){gn.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var t=this._container=document.createElement("canvas");mt(t,"mousemove",o(this._onMouseMove,32,this),this),mt(t,"click dblclick mousedown mouseup contextmenu",this._onClick,this),mt(t,"mouseout",this._handleMouseOut,this),this._ctx=t.getContext("2d")},_destroyContainer:function(){g(this._redrawRequest),delete this._ctx,K(this._container),ft(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){this._redrawBounds=null;for(var t in this._layers)this._layers[t]._update();this._redraw()}},_update:function(){if(!this._map._animatingZoom||!this._bounds){this._drawnLayers={},gn.prototype._update.call(this);var t=this._bounds,i=this._container,e=t.getSize(),n=Yi?2:1;at(i,t.min),i.width=n*e.x,i.height=n*e.y,i.style.width=e.x+"px",i.style.height=e.y+"px",Yi&&this._ctx.scale(2,2),this._ctx.translate(-t.min.x,-t.min.y),this.fire("update")}},_reset:function(){gn.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(t){this._updateDashArray(t),this._layers[n(t)]=t;var i=t._order={layer:t,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=i),this._drawLast=i,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(t){this._requestRedraw(t)},_removePath:function(t){var i=t._order,e=i.next,o=i.prev;e?e.prev=o:this._drawLast=o,o?o.next=e:this._drawFirst=e,delete this._drawnLayers[t._leaflet_id],delete t._order,delete this._layers[n(t)],this._requestRedraw(t)},_updatePath:function(t){this._extendRedrawBounds(t),t._project(),t._update(),this._requestRedraw(t)},_updateStyle:function(t){this._updateDashArray(t),this._requestRedraw(t)},_updateDashArray:function(t){if("string"==typeof t.options.dashArray){var i,e=t.options.dashArray.split(/[, ]+/),n=[];for(i=0;i<e.length;i++)n.push(Number(e[i]));t.options._dashArray=n}else t.options._dashArray=t.options.dashArray},_requestRedraw:function(t){this._map&&(this._extendRedrawBounds(t),this._redrawRequest=this._redrawRequest||f(this._redraw,this))},_extendRedrawBounds:function(t){if(t._pxBounds){var i=(t.options.weight||0)+1;this._redrawBounds=this._redrawBounds||new P,this._redrawBounds.extend(t._pxBounds.min.subtract([i,i])),this._redrawBounds.extend(t._pxBounds.max.add([i,i]))}},_redraw:function(){this._redrawRequest=null,this._redrawBounds&&(this._redrawBounds.min._floor(),this._redrawBounds.max._ceil()),this._clear(),this._draw(),this._redrawBounds=null},_clear:function(){var t=this._redrawBounds;if(t){var i=t.getSize();this._ctx.clearRect(t.min.x,t.min.y,i.x,i.y)}else this._ctx.clearRect(0,0,this._container.width,this._container.height)},_draw:function(){var t,i=this._redrawBounds;if(this._ctx.save(),i){var e=i.getSize();this._ctx.beginPath(),this._ctx.rect(i.min.x,i.min.y,e.x,e.y),this._ctx.clip()}this._drawing=!0;for(var n=this._drawFirst;n;n=n.next)t=n.layer,(!i||t._pxBounds&&t._pxBounds.intersects(i))&&t._updatePath();this._drawing=!1,this._ctx.restore()},_updatePoly:function(t,i){if(this._drawing){var e,n,o,s,r=t._parts,a=r.length,h=this._ctx;if(a){for(this._drawnLayers[t._leaflet_id]=t,h.beginPath(),e=0;e<a;e++){for(n=0,o=r[e].length;n<o;n++)s=r[e][n],h[n?"lineTo":"moveTo"](s.x,s.y);i&&h.closePath()}this._fillStroke(h,t)}}},_updateCircle:function(t){if(this._drawing&&!t._empty()){var i=t._point,e=this._ctx,n=Math.max(Math.round(t._radius),1),o=(Math.max(Math.round(t._radiusY),1)||n)/n;this._drawnLayers[t._leaflet_id]=t,1!==o&&(e.save(),e.scale(1,o)),e.beginPath(),e.arc(i.x,i.y/o,n,0,2*Math.PI,!1),1!==o&&e.restore(),this._fillStroke(e,t)}},_fillStroke:function(t,i){var e=i.options;e.fill&&(t.globalAlpha=e.fillOpacity,t.fillStyle=e.fillColor||e.color,t.fill(e.fillRule||"evenodd")),e.stroke&&0!==e.weight&&(t.setLineDash&&t.setLineDash(i.options&&i.options._dashArray||[]),t.globalAlpha=e.opacity,t.lineWidth=e.weight,t.strokeStyle=e.color,t.lineCap=e.lineCap,t.lineJoin=e.lineJoin,t.stroke())},_onClick:function(t){for(var i,e,n=this._map.mouseEventToLayerPoint(t),o=this._drawFirst;o;o=o.next)(i=o.layer).options.interactive&&i._containsPoint(n)&&!this._map._draggableMoved(i)&&(e=i);e&&(zt(t),this._fireEvent([e],t))},_onMouseMove:function(t){if(this._map&&!this._map.dragging.moving()&&!this._map._animatingZoom){var i=this._map.mouseEventToLayerPoint(t);this._handleMouseHover(t,i)}},_handleMouseOut:function(t){var i=this._hoveredLayer;i&&(tt(this._container,"leaflet-interactive"),this._fireEvent([i],t,"mouseout"),this._hoveredLayer=null)},_handleMouseHover:function(t,i){for(var e,n,o=this._drawFirst;o;o=o.next)(e=o.layer).options.interactive&&e._containsPoint(i)&&(n=e);n!==this._hoveredLayer&&(this._handleMouseOut(t),n&&(Q(this._container,"leaflet-interactive"),this._fireEvent([n],t,"mouseover"),this._hoveredLayer=n)),this._hoveredLayer&&this._fireEvent([this._hoveredLayer],t)},_fireEvent:function(t,i,e){this._map._fireDOMEvent(i,e||i.type,t)},_bringToFront:function(t){var i=t._order,e=i.next,n=i.prev;e&&(e.prev=n,n?n.next=e:e&&(this._drawFirst=e),i.prev=this._drawLast,this._drawLast.next=i,i.next=null,this._drawLast=i,this._requestRedraw(t))},_bringToBack:function(t){var i=t._order,e=i.next,n=i.prev;n&&(n.next=e,e?e.prev=n:n&&(this._drawLast=n),i.prev=null,i.next=this._drawFirst,this._drawFirst.prev=i,this._drawFirst=i,this._requestRedraw(t))}}),yn=function(){try{return document.namespaces.add("lvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("<lvml:"+t+' class="lvml">')}}catch(t){return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}}(),xn={_initContainer:function(){this._container=G("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(gn.prototype._update.call(this),this.fire("update"))},_initPath:function(t){var i=t._container=yn("shape");Q(i,"leaflet-vml-shape "+(this.options.className||"")),i.coordsize="1 1",t._path=yn("path"),i.appendChild(t._path),this._updateStyle(t),this._layers[n(t)]=t},_addPath:function(t){var i=t._container;this._container.appendChild(i),t.options.interactive&&t.addInteractiveTarget(i)},_removePath:function(t){var i=t._container;K(i),t.removeInteractiveTarget(i),delete this._layers[n(t)]},_updateStyle:function(t){var i=t._stroke,e=t._fill,n=t.options,o=t._container;o.stroked=!!n.stroke,o.filled=!!n.fill,n.stroke?(i||(i=t._stroke=yn("stroke")),o.appendChild(i),i.weight=n.weight+"px",i.color=n.color,i.opacity=n.opacity,n.dashArray?i.dashStyle=oi(n.dashArray)?n.dashArray.join(" "):n.dashArray.replace(/( *, *)/g," "):i.dashStyle="",i.endcap=n.lineCap.replace("butt","flat"),i.joinstyle=n.lineJoin):i&&(o.removeChild(i),t._stroke=null),n.fill?(e||(e=t._fill=yn("fill")),o.appendChild(e),e.color=n.fillColor||n.color,e.opacity=n.fillOpacity):e&&(o.removeChild(e),t._fill=null)},_updateCircle:function(t){var i=t._point.round(),e=Math.round(t._radius),n=Math.round(t._radiusY||e);this._setPath(t,t._empty()?"M0 0":"AL "+i.x+","+i.y+" "+e+","+n+" 0,23592600")},_setPath:function(t,i){t._path.v=i},_bringToFront:function(t){X(t._container)},_bringToBack:function(t){J(t._container)}},wn=$i?yn:E,Pn=gn.extend({getEvents:function(){var t=gn.prototype.getEvents.call(this);return t.zoomstart=this._onZoomStart,t},_initContainer:function(){this._container=wn("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=wn("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){K(this._container),ft(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_onZoomStart:function(){this._update()},_update:function(){if(!this._map._animatingZoom||!this._bounds){gn.prototype._update.call(this);var t=this._bounds,i=t.getSize(),e=this._container;this._svgSize&&this._svgSize.equals(i)||(this._svgSize=i,e.setAttribute("width",i.x),e.setAttribute("height",i.y)),at(e,t.min),e.setAttribute("viewBox",[t.min.x,t.min.y,i.x,i.y].join(" ")),this.fire("update")}},_initPath:function(t){var i=t._path=wn("path");t.options.className&&Q(i,t.options.className),t.options.interactive&&Q(i,"leaflet-interactive"),this._updateStyle(t),this._layers[n(t)]=t},_addPath:function(t){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(t._path),t.addInteractiveTarget(t._path)},_removePath:function(t){K(t._path),t.removeInteractiveTarget(t._path),delete this._layers[n(t)]},_updatePath:function(t){t._project(),t._update()},_updateStyle:function(t){var i=t._path,e=t.options;i&&(e.stroke?(i.setAttribute("stroke",e.color),i.setAttribute("stroke-opacity",e.opacity),i.setAttribute("stroke-width",e.weight),i.setAttribute("stroke-linecap",e.lineCap),i.setAttribute("stroke-linejoin",e.lineJoin),e.dashArray?i.setAttribute("stroke-dasharray",e.dashArray):i.removeAttribute("stroke-dasharray"),e.dashOffset?i.setAttribute("stroke-dashoffset",e.dashOffset):i.removeAttribute("stroke-dashoffset")):i.setAttribute("stroke","none"),e.fill?(i.setAttribute("fill",e.fillColor||e.color),i.setAttribute("fill-opacity",e.fillOpacity),i.setAttribute("fill-rule",e.fillRule||"evenodd")):i.setAttribute("fill","none"))},_updatePoly:function(t,i){this._setPath(t,k(t._parts,i))},_updateCircle:function(t){var i=t._point,e=Math.max(Math.round(t._radius),1),n="a"+e+","+(Math.max(Math.round(t._radiusY),1)||e)+" 0 1,0 ",o=t._empty()?"M0 0":"M"+(i.x-e)+","+i.y+n+2*e+",0 "+n+2*-e+",0 ";this._setPath(t,o)},_setPath:function(t,i){t._path.setAttribute("d",i)},_bringToFront:function(t){X(t._path)},_bringToBack:function(t){J(t._path)}});$i&&Pn.include(xn),be.include({getRenderer:function(t){var i=t.options.renderer||this._getPaneRenderer(t.options.pane)||this.options.renderer||this._renderer;return i||(i=this._renderer=this._createRenderer()),this.hasLayer(i)||this.addLayer(i),i},_getPaneRenderer:function(t){if("overlayPane"===t||void 0===t)return!1;var i=this._paneRenderers[t];return void 0===i&&(i=this._createRenderer({pane:t}),this._paneRenderers[t]=i),i},_createRenderer:function(t){return this.options.preferCanvas&&$t(t)||Qt(t)}});var Ln=on.extend({initialize:function(t,i){on.prototype.initialize.call(this,this._boundsToLatLngs(t),i)},setBounds:function(t){return this.setLatLngs(this._boundsToLatLngs(t))},_boundsToLatLngs:function(t){return t=z(t),[t.getSouthWest(),t.getNorthWest(),t.getNorthEast(),t.getSouthEast()]}});Pn.create=wn,Pn.pointsToPath=k,sn.geometryToLayer=Ft,sn.coordsToLatLng=Ut,sn.coordsToLatLngs=Vt,sn.latLngToCoords=qt,sn.latLngsToCoords=Gt,sn.getFeature=Kt,sn.asFeature=Yt,be.mergeOptions({boxZoom:!0});var bn=Ee.extend({initialize:function(t){this._map=t,this._container=t._container,this._pane=t._panes.overlayPane,this._resetStateTimeout=0,t.on("unload",this._destroy,this)},addHooks:function(){mt(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){ft(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){K(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){0!==this._resetStateTimeout&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(t){if(!t.shiftKey||1!==t.which&&1!==t.button)return!1;this._clearDeferredResetState(),this._resetState(),fi(),ut(),this._startPoint=this._map.mouseEventToContainerPoint(t),mt(document,{contextmenu:Lt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(t){this._moved||(this._moved=!0,this._box=G("div","leaflet-zoom-box",this._container),Q(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(t);var i=new P(this._point,this._startPoint),e=i.getSize();at(this._box,i.min),this._box.style.width=e.x+"px",this._box.style.height=e.y+"px"},_finish:function(){this._moved&&(K(this._box),tt(this._container,"leaflet-crosshair")),gi(),lt(),ft(document,{contextmenu:Lt,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(t){if((1===t.which||1===t.button)&&(this._finish(),this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(e(this._resetState,this),0);var i=new T(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(i).fire("boxzoomend",{boxZoomBounds:i})}},_onKeyDown:function(t){27===t.keyCode&&this._finish()}});be.addInitHook("addHandler","boxZoom",bn),be.mergeOptions({doubleClickZoom:!0});var Tn=Ee.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(t){var i=this._map,e=i.getZoom(),n=i.options.zoomDelta,o=t.originalEvent.shiftKey?e-n:e+n;"center"===i.options.doubleClickZoom?i.setZoom(o):i.setZoomAround(t.containerPoint,o)}});be.addInitHook("addHandler","doubleClickZoom",Tn),be.mergeOptions({dragging:!0,inertia:!Mi,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var zn=Ee.extend({addHooks:function(){if(!this._draggable){var t=this._map;this._draggable=new Re(t._mapPane,t._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),t.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),t.on("zoomend",this._onZoomEnd,this),t.whenReady(this._onZoomEnd,this))}Q(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){tt(this._map._container,"leaflet-grab"),tt(this._map._container,"leaflet-touch-drag"),this._draggable.disable()},moved:function(){return this._draggable&&this._draggable._moved},moving:function(){return this._draggable&&this._draggable._moving},_onDragStart:function(){var t=this._map;if(t._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var i=z(this._map.options.maxBounds);this._offsetLimit=b(this._map.latLngToContainerPoint(i.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(i.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;t.fire("movestart").fire("dragstart"),t.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(t){if(this._map.options.inertia){var i=this._lastTime=+new Date,e=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(e),this._times.push(i),this._prunePositions(i)}this._map.fire("move",t).fire("drag",t)},_prunePositions:function(t){for(;this._positions.length>1&&t-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var t=this._map.getSize().divideBy(2),i=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=i.subtract(t).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(t,i){return t-(t-i)*this._viscosity},_onPreDragLimit:function(){if(this._viscosity&&this._offsetLimit){var t=this._draggable._newPos.subtract(this._draggable._startPos),i=this._offsetLimit;t.x<i.min.x&&(t.x=this._viscousLimit(t.x,i.min.x)),t.y<i.min.y&&(t.y=this._viscousLimit(t.y,i.min.y)),t.x>i.max.x&&(t.x=this._viscousLimit(t.x,i.max.x)),t.y>i.max.y&&(t.y=this._viscousLimit(t.y,i.max.y)),this._draggable._newPos=this._draggable._startPos.add(t)}},_onPreDragWrap:function(){var t=this._worldWidth,i=Math.round(t/2),e=this._initialWorldOffset,n=this._draggable._newPos.x,o=(n-i+e)%t+i-e,s=(n+i+e)%t-i-e,r=Math.abs(o+e)<Math.abs(s+e)?o:s;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=r},_onDragEnd:function(t){var i=this._map,e=i.options,n=!e.inertia||this._times.length<2;if(i.fire("dragend",t),n)i.fire("moveend");else{this._prunePositions(+new Date);var o=this._lastPos.subtract(this._positions[0]),s=(this._lastTime-this._times[0])/1e3,r=e.easeLinearity,a=o.multiplyBy(r/s),h=a.distanceTo([0,0]),u=Math.min(e.inertiaMaxSpeed,h),l=a.multiplyBy(u/h),c=u/(e.inertiaDeceleration*r),_=l.multiplyBy(-c/2).round();_.x||_.y?(_=i._limitOffset(_,i.options.maxBounds),f(function(){i.panBy(_,{duration:c,easeLinearity:r,noMoveStart:!0,animate:!0})})):i.fire("moveend")}}});be.addInitHook("addHandler","dragging",zn),be.mergeOptions({keyboard:!0,keyboardPanDelta:80});var Mn=Ee.extend({keyCodes:{left:[37],right:[39],down:[40],up:[38],zoomIn:[187,107,61,171],zoomOut:[189,109,54,173]},initialize:function(t){this._map=t,this._setPanDelta(t.options.keyboardPanDelta),this._setZoomDelta(t.options.zoomDelta)},addHooks:function(){var t=this._map._container;t.tabIndex<=0&&(t.tabIndex="0"),mt(t,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.on({focus:this._addHooks,blur:this._removeHooks},this)},removeHooks:function(){this._removeHooks(),ft(this._map._container,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.off({focus:this._addHooks,blur:this._removeHooks},this)},_onMouseDown:function(){if(!this._focused){var t=document.body,i=document.documentElement,e=t.scrollTop||i.scrollTop,n=t.scrollLeft||i.scrollLeft;this._map._container.focus(),window.scrollTo(n,e)}},_onFocus:function(){this._focused=!0,this._map.fire("focus")},_onBlur:function(){this._focused=!1,this._map.fire("blur")},_setPanDelta:function(t){var i,e,n=this._panKeys={},o=this.keyCodes;for(i=0,e=o.left.length;i<e;i++)n[o.left[i]]=[-1*t,0];for(i=0,e=o.right.length;i<e;i++)n[o.right[i]]=[t,0];for(i=0,e=o.down.length;i<e;i++)n[o.down[i]]=[0,t];for(i=0,e=o.up.length;i<e;i++)n[o.up[i]]=[0,-1*t]},_setZoomDelta:function(t){var i,e,n=this._zoomKeys={},o=this.keyCodes;for(i=0,e=o.zoomIn.length;i<e;i++)n[o.zoomIn[i]]=t;for(i=0,e=o.zoomOut.length;i<e;i++)n[o.zoomOut[i]]=-t},_addHooks:function(){mt(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){ft(document,"keydown",this._onKeyDown,this)},_onKeyDown:function(t){if(!(t.altKey||t.ctrlKey||t.metaKey)){var i,e=t.keyCode,n=this._map;if(e in this._panKeys)n._panAnim&&n._panAnim._inProgress||(i=this._panKeys[e],t.shiftKey&&(i=w(i).multiplyBy(3)),n.panBy(i),n.options.maxBounds&&n.panInsideBounds(n.options.maxBounds));else if(e in this._zoomKeys)n.setZoom(n.getZoom()+(t.shiftKey?3:1)*this._zoomKeys[e]);else{if(27!==e||!n._popup||!n._popup.options.closeOnEscapeKey)return;n.closePopup()}Lt(t)}}});be.addInitHook("addHandler","keyboard",Mn),be.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var Cn=Ee.extend({addHooks:function(){mt(this._map._container,"mousewheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){ft(this._map._container,"mousewheel",this._onWheelScroll,this)},_onWheelScroll:function(t){var i=Tt(t),n=this._map.options.wheelDebounceTime;this._delta+=i,this._lastMousePos=this._map.mouseEventToContainerPoint(t),this._startTime||(this._startTime=+new Date);var o=Math.max(n-(+new Date-this._startTime),0);clearTimeout(this._timer),this._timer=setTimeout(e(this._performZoom,this),o),Lt(t)},_performZoom:function(){var t=this._map,i=t.getZoom(),e=this._map.options.zoomSnap||0;t._stop();var n=this._delta/(4*this._map.options.wheelPxPerZoomLevel),o=4*Math.log(2/(1+Math.exp(-Math.abs(n))))/Math.LN2,s=e?Math.ceil(o/e)*e:o,r=t._limitZoom(i+(this._delta>0?s:-s))-i;this._delta=0,this._startTime=null,r&&("center"===t.options.scrollWheelZoom?t.setZoom(i+r):t.setZoomAround(this._lastMousePos,i+r))}});be.addInitHook("addHandler","scrollWheelZoom",Cn),be.mergeOptions({tap:!0,tapTolerance:15});var Sn=Ee.extend({addHooks:function(){mt(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){ft(this._map._container,"touchstart",this._onDown,this)},_onDown:function(t){if(t.touches){if(Pt(t),this._fireClick=!0,t.touches.length>1)return this._fireClick=!1,void clearTimeout(this._holdTimeout);var i=t.touches[0],n=i.target;this._startPos=this._newPos=new x(i.clientX,i.clientY),n.tagName&&"a"===n.tagName.toLowerCase()&&Q(n,"leaflet-active"),this._holdTimeout=setTimeout(e(function(){this._isTapValid()&&(this._fireClick=!1,this._onUp(),this._simulateEvent("contextmenu",i))},this),1e3),this._simulateEvent("mousedown",i),mt(document,{touchmove:this._onMove,touchend:this._onUp},this)}},_onUp:function(t){if(clearTimeout(this._holdTimeout),ft(document,{touchmove:this._onMove,touchend:this._onUp},this),this._fireClick&&t&&t.changedTouches){var i=t.changedTouches[0],e=i.target;e&&e.tagName&&"a"===e.tagName.toLowerCase()&&tt(e,"leaflet-active"),this._simulateEvent("mouseup",i),this._isTapValid()&&this._simulateEvent("click",i)}},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_onMove:function(t){var i=t.touches[0];this._newPos=new x(i.clientX,i.clientY),this._simulateEvent("mousemove",i)},_simulateEvent:function(t,i){var e=document.createEvent("MouseEvents");e._simulated=!0,i.target._simulatedClick=!0,e.initMouseEvent(t,!0,!0,window,1,i.screenX,i.screenY,i.clientX,i.clientY,!1,!1,!1,!1,0,null),i.target.dispatchEvent(e)}});qi&&!Vi&&be.addInitHook("addHandler","tap",Sn),be.mergeOptions({touchZoom:qi&&!Mi,bounceAtZoomLimits:!0});var Zn=Ee.extend({addHooks:function(){Q(this._map._container,"leaflet-touch-zoom"),mt(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){tt(this._map._container,"leaflet-touch-zoom"),ft(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(t){var i=this._map;if(t.touches&&2===t.touches.length&&!i._animatingZoom&&!this._zooming){var e=i.mouseEventToContainerPoint(t.touches[0]),n=i.mouseEventToContainerPoint(t.touches[1]);this._centerPoint=i.getSize()._divideBy(2),this._startLatLng=i.containerPointToLatLng(this._centerPoint),"center"!==i.options.touchZoom&&(this._pinchStartLatLng=i.containerPointToLatLng(e.add(n)._divideBy(2))),this._startDist=e.distanceTo(n),this._startZoom=i.getZoom(),this._moved=!1,this._zooming=!0,i._stop(),mt(document,"touchmove",this._onTouchMove,this),mt(document,"touchend",this._onTouchEnd,this),Pt(t)}},_onTouchMove:function(t){if(t.touches&&2===t.touches.length&&this._zooming){var i=this._map,n=i.mouseEventToContainerPoint(t.touches[0]),o=i.mouseEventToContainerPoint(t.touches[1]),s=n.distanceTo(o)/this._startDist;if(this._zoom=i.getScaleZoom(s,this._startZoom),!i.options.bounceAtZoomLimits&&(this._zoom<i.getMinZoom()&&s<1||this._zoom>i.getMaxZoom()&&s>1)&&(this._zoom=i._limitZoom(this._zoom)),"center"===i.options.touchZoom){if(this._center=this._startLatLng,1===s)return}else{var r=n._add(o)._divideBy(2)._subtract(this._centerPoint);if(1===s&&0===r.x&&0===r.y)return;this._center=i.unproject(i.project(this._pinchStartLatLng,this._zoom).subtract(r),this._zoom)}this._moved||(i._moveStart(!0,!1),this._moved=!0),g(this._animRequest);var a=e(i._move,i,this._center,this._zoom,{pinch:!0,round:!1});this._animRequest=f(a,this,!0),Pt(t)}},_onTouchEnd:function(){this._moved&&this._zooming?(this._zooming=!1,g(this._animRequest),ft(document,"touchmove",this._onTouchMove),ft(document,"touchend",this._onTouchEnd),this._map.options.zoomAnimation?this._map._animateZoom(this._center,this._map._limitZoom(this._zoom),!0,this._map.options.zoomSnap):this._map._resetView(this._center,this._map._limitZoom(this._zoom))):this._zooming=!1}});be.addInitHook("addHandler","touchZoom",Zn),be.BoxZoom=bn,be.DoubleClickZoom=Tn,be.Drag=zn,be.Keyboard=Mn,be.ScrollWheelZoom=Cn,be.Tap=Sn,be.TouchZoom=Zn,Object.freeze=ti,t.version="1.3.4+HEAD.0e566b2",t.Control=Te,t.control=ze,t.Browser=Qi,t.Evented=ci,t.Mixin=Ae,t.Util=ui,t.Class=v,t.Handler=Ee,t.extend=i,t.bind=e,t.stamp=n,t.setOptions=l,t.DomEvent=Pe,t.DomUtil=ve,t.PosAnimation=Le,t.Draggable=Re,t.LineUtil=Ne,t.PolyUtil=De,t.Point=x,t.point=w,t.Bounds=P,t.bounds=b,t.Transformation=S,t.transformation=Z,t.Projection=He,t.LatLng=M,t.latLng=C,t.LatLngBounds=T,t.latLngBounds=z,t.CRS=di,t.GeoJSON=sn,t.geoJSON=Xt,t.geoJson=an,t.Layer=qe,t.LayerGroup=Ge,t.layerGroup=function(t,i){return new Ge(t,i)},t.FeatureGroup=Ke,t.featureGroup=function(t){return new Ke(t)},t.ImageOverlay=hn,t.imageOverlay=function(t,i,e){return new hn(t,i,e)},t.VideoOverlay=un,t.videoOverlay=function(t,i,e){return new un(t,i,e)},t.DivOverlay=ln,t.Popup=cn,t.popup=function(t,i){return new cn(t,i)},t.Tooltip=_n,t.tooltip=function(t,i){return new _n(t,i)},t.Icon=Ye,t.icon=function(t){return new Ye(t)},t.DivIcon=dn,t.divIcon=function(t){return new dn(t)},t.Marker=$e,t.marker=function(t,i){return new $e(t,i)},t.TileLayer=mn,t.tileLayer=Jt,t.GridLayer=pn,t.gridLayer=function(t){return new pn(t)},t.SVG=Pn,t.svg=Qt,t.Renderer=gn,t.Canvas=vn,t.canvas=$t,t.Path=Qe,t.CircleMarker=tn,t.circleMarker=function(t,i){return new tn(t,i)},t.Circle=en,t.circle=function(t,i,e){return new en(t,i,e)},t.Polyline=nn,t.polyline=function(t,i){return new nn(t,i)},t.Polygon=on,t.polygon=function(t,i){return new on(t,i)},t.Rectangle=Ln,t.rectangle=function(t,i){return new Ln(t,i)},t.Map=be,t.map=function(t,i){return new be(t,i)};var En=window.L;t.noConflict=function(){return window.L=En,this},window.L=t}); \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/DataAccess/CachingGeocoder.php b/www/wiki/extensions/Maps/src/DataAccess/CachingGeocoder.php
new file mode 100644
index 00000000..b27bbc92
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/DataAccess/CachingGeocoder.php
@@ -0,0 +1,46 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\DataAccess;
+
+use BagOStuff;
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoder;
+
+/**
+ * @since 5.0
+ *
+ * @licence GNU GPL v2+
+ * @author HgO < hgo@batato.be >
+ */
+class CachingGeocoder implements Geocoder {
+
+ private $geocoder;
+ private $cache;
+ private $cacheTtl;
+
+ public function __construct( Geocoder $geocoder, BagOStuff $cache, int $cacheTtl ) {
+ $this->geocoder = $geocoder;
+ $this->cache = $cache;
+ $this->cacheTtl = $cacheTtl;
+ }
+
+ /**
+ * @return LatLongValue|null
+ */
+ public function geocode( string $address ) {
+ $key = $this->cache->makeKey( __CLASS__, $address );
+
+ $coordinates = $this->cache->get( $key );
+
+ // There was no entry in the cache, so we retrieve the coordinates
+ if ( $coordinates === false ) {
+ $coordinates = $this->geocoder->geocode( $address );
+
+ $this->cache->set( $key, $coordinates, $this->cacheTtl );
+ }
+
+ return $coordinates;
+ }
+}
diff --git a/www/wiki/extensions/Maps/src/DataAccess/JsonFileParser.php b/www/wiki/extensions/Maps/src/DataAccess/JsonFileParser.php
new file mode 100644
index 00000000..81d6cfa0
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/DataAccess/JsonFileParser.php
@@ -0,0 +1,79 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\DataAccess;
+
+use FileFetcher\FileFetcher;
+use FileFetcher\FileFetchingException;
+use Maps\MapsFactory;
+use ValueParsers\ParseException;
+use ValueParsers\ValueParser;
+
+/**
+ * Returns the content of the JSON file at the specified location as array.
+ * Empty array is returned on failure.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class JsonFileParser implements ValueParser {
+
+ private $fileFetcher;
+ private $pageContentFetcher;
+ private $defaultNamespace;
+
+ public function __construct( $fileFetcher = null, PageContentFetcher $pageContentFetcher = null ) {
+ $this->fileFetcher = $fileFetcher instanceof FileFetcher
+ ? $fileFetcher : MapsFactory::newDefault()->getGeoJsonFileFetcher();
+
+ $this->pageContentFetcher = $pageContentFetcher instanceof PageContentFetcher
+ ? $pageContentFetcher : MapsFactory::newDefault()->getPageContentFetcher();
+
+ $this->defaultNamespace = NS_GEO_JSON;
+ }
+
+ /**
+ * @param string $fileLocation
+ *
+ * @return array
+ * @throws ParseException
+ */
+ public function parse( $fileLocation ) {
+ $jsonString = $this->getJsonString( $fileLocation );
+
+ if ( $jsonString === null ) {
+ return [];
+ }
+
+ $json = json_decode( $jsonString, true );
+
+ if ( $json === null ) {
+ return [];
+ }
+
+ return $json;
+ }
+
+ private function getJsonString( string $fileLocation ): ?string {
+ $content = $this->pageContentFetcher->getPageContent( $fileLocation, $this->defaultNamespace );
+
+ if ( $content instanceof \JsonContent ) {
+ return $content->getNativeData();
+ }
+
+ // Prevent reading JSON files on the server
+ if( !filter_var( $fileLocation, FILTER_VALIDATE_URL) ) {
+ return null;
+ }
+
+ try {
+ return $this->fileFetcher->fetchFile( $fileLocation );
+ }
+ catch ( FileFetchingException $ex ) {
+ return null;
+ }
+ }
+
+
+}
diff --git a/www/wiki/extensions/Maps/src/DataAccess/MapsFileFetcher.php b/www/wiki/extensions/Maps/src/DataAccess/MapsFileFetcher.php
new file mode 100644
index 00000000..79d7f07f
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/DataAccess/MapsFileFetcher.php
@@ -0,0 +1,26 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\DataAccess;
+
+use FileFetcher\FileFetcher;
+use FileFetcher\FileFetchingException;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsFileFetcher implements FileFetcher {
+
+ public function fetchFile( string $fileUrl ): string {
+ $result = \Http::get( $fileUrl );
+
+ if ( !is_string( $result ) ) {
+ throw new FileFetchingException( $fileUrl );
+ }
+
+ return $result;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/DataAccess/MediaWikiFileUrlFinder.php b/www/wiki/extensions/Maps/src/DataAccess/MediaWikiFileUrlFinder.php
new file mode 100644
index 00000000..aabb5f38
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/DataAccess/MediaWikiFileUrlFinder.php
@@ -0,0 +1,31 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\DataAccess;
+
+use ImagePage;
+use Maps\FileUrlFinder;
+use Title;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MediaWikiFileUrlFinder implements FileUrlFinder {
+
+ public function getUrlForFileName( string $fileName ): string {
+ $colonPosition = strpos( $fileName, ':' );
+
+ $titleWithoutPrefix = $colonPosition === false ? $fileName : substr( $fileName, $colonPosition + 1 );
+
+ $title = Title::newFromText( trim( $titleWithoutPrefix ), NS_FILE );
+
+ if ( $title !== null && $title->exists() ) {
+ return ( new ImagePage( $title ) )->getDisplayedFile()->getURL();
+ }
+
+ return trim( $fileName );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/DataAccess/PageContentFetcher.php b/www/wiki/extensions/Maps/src/DataAccess/PageContentFetcher.php
new file mode 100644
index 00000000..514cfe0a
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/DataAccess/PageContentFetcher.php
@@ -0,0 +1,40 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\DataAccess;
+
+use MediaWiki\Storage\RevisionLookup;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class PageContentFetcher {
+
+ private $titleParser;
+ private $revisionLookup;
+
+ public function __construct( \TitleParser $titleParser, RevisionLookup $revisionLookup ) {
+ $this->titleParser = $titleParser;
+ $this->revisionLookup = $revisionLookup;
+ }
+
+ public function getPageContent( string $pageTitle, int $defaultNamespace = NS_MAIN ): ?\Content {
+ try {
+ $title = $this->titleParser->parseTitle( $pageTitle, $defaultNamespace );
+ }
+ catch ( \MalformedTitleException $e ) {
+ return null;
+ }
+
+ $revision = $this->revisionLookup->getRevisionByTitle( $title );
+
+ if ( $revision === null ) {
+ return null;
+ }
+
+ return $revision->getContent( 'main' );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/BaseElement.php b/www/wiki/extensions/Maps/src/Elements/BaseElement.php
new file mode 100644
index 00000000..2e36c3b4
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/BaseElement.php
@@ -0,0 +1,57 @@
+<?php
+
+namespace Maps\Elements;
+
+/**
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+abstract class BaseElement {
+
+ private $title;
+ private $text;
+ private $link;
+
+ public function setTitle( string $title ) {
+ $this->title = trim( $title );
+ }
+
+ public function setText( string $text ) {
+ $this->text = trim( $text );
+ }
+
+ public function setLink( string $link ) {
+ $this->link = $link;
+ }
+
+ public function getArrayValue() {
+ return $this->getJSONObject();
+ }
+
+ /**
+ * @deprecated
+ */
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ return [
+ 'text' => $this->text ?? $defText,
+ 'title' => $this->title ?? $defTitle,
+ 'link' => $this->link ?? '',
+ ];
+ }
+
+ public function getText(): string {
+ return $this->text ?? '';
+ }
+
+ public function getTitle(): string {
+ return $this->title ?? '';
+ }
+
+ public function getLink(): string {
+ return $this->link ?? '';
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/BaseFillableElement.php b/www/wiki/extensions/Maps/src/Elements/BaseFillableElement.php
new file mode 100644
index 00000000..cf740fc8
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/BaseFillableElement.php
@@ -0,0 +1,45 @@
+<?php
+
+namespace Maps\Elements;
+
+/**
+ * @since 2.0
+ */
+class BaseFillableElement extends BaseStrokableElement {
+
+ protected $fillColor;
+ protected $fillOpacity;
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $parentArray = parent::getJSONObject( $defText, $defTitle );
+ $array = [
+ 'fillColor' => $this->hasFillColor() ? $this->getFillColor() : '#FF0000',
+ 'fillOpacity' => $this->hasFillOpacity() ? $this->getFillOpacity() : '0.5',
+ ];
+ return array_merge( $parentArray, $array );
+ }
+
+ public function hasFillColor() {
+ return !is_null( $this->fillColor ) && $this->fillColor !== '';
+ }
+
+ public function getFillColor() {
+ return $this->fillColor;
+ }
+
+ public function setFillColor( $fillColor ) {
+ $this->fillColor = trim( $fillColor );
+ }
+
+ public function hasFillOpacity() {
+ return !is_null( $this->fillOpacity ) && $this->fillOpacity !== '';
+ }
+
+ public function getFillOpacity() {
+ return $this->fillOpacity;
+ }
+
+ public function setFillOpacity( $fillOpacity ) {
+ $this->fillOpacity = trim( $fillOpacity );
+ }
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/BaseStrokableElement.php b/www/wiki/extensions/Maps/src/Elements/BaseStrokableElement.php
new file mode 100644
index 00000000..79befa2f
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/BaseStrokableElement.php
@@ -0,0 +1,63 @@
+<?php
+
+namespace Maps\Elements;
+
+/**
+ * @since 2.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ */
+class BaseStrokableElement extends BaseElement {
+
+ protected $strokeColor;
+ protected $strokeOpacity;
+ protected $strokeWeight;
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $parentArray = parent::getJSONObject( $defText, $defTitle );
+ $array = [
+ 'strokeColor' => $this->hasStrokeColor() ? $this->getStrokeColor() : '#FF0000',
+ 'strokeOpacity' => $this->hasStrokeOpacity() ? $this->getStrokeOpacity() : '1',
+ 'strokeWeight' => $this->hasStrokeWeight() ? $this->getStrokeWeight() : '2'
+ ];
+ return array_merge( $parentArray, $array );
+ }
+
+ public function hasStrokeColor() {
+ return !is_null( $this->strokeColor ) && $this->strokeColor !== '';
+ }
+
+ public function getStrokeColor() {
+ return $this->strokeColor;
+ }
+
+ public function setStrokeColor( $strokeColor ) {
+ $this->strokeColor = trim( $strokeColor );
+ }
+
+ public function hasStrokeOpacity() {
+ return !is_null( $this->strokeOpacity ) && $this->strokeOpacity !== '';
+ }
+
+ public function getStrokeOpacity() {
+ return $this->strokeOpacity;
+ }
+
+ public function setStrokeOpacity( $strokeOpacity ) {
+ $this->strokeOpacity = trim( $strokeOpacity );
+ }
+
+ public function hasStrokeWeight() {
+ return !is_null( $this->strokeWeight ) && $this->strokeWeight !== '';
+ }
+
+ public function getStrokeWeight() {
+ return $this->strokeWeight;
+ }
+
+ public function setStrokeWeight( $strokeWeight ) {
+ $this->strokeWeight = trim( $strokeWeight );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/Circle.php b/www/wiki/extensions/Maps/src/Elements/Circle.php
new file mode 100644
index 00000000..5b5f9172
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/Circle.php
@@ -0,0 +1,62 @@
+<?php
+
+namespace Maps\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use InvalidArgumentException;
+
+/**
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class Circle extends \Maps\Elements\BaseFillableElement {
+
+ private $circleCentre;
+ private $circleRadius;
+
+ public function __construct( LatLongValue $circleCentre, float $circleRadius ) {
+ if ( !is_float( $circleRadius ) && !is_int( $circleRadius ) ) {
+ throw new InvalidArgumentException( '$circleRadius must be a float or int' );
+ }
+
+ if ( $circleRadius <= 0 ) {
+ throw new InvalidArgumentException( '$circleRadius must be greater than zero' );
+ }
+
+ $this->setCircleCentre( $circleCentre );
+ $this->setCircleRadius( $circleRadius );
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ return array_merge(
+ parent::getJSONObject( $defText, $defTitle ),
+ [
+ 'centre' => [
+ 'lon' => $this->getCircleCentre()->getLongitude(),
+ 'lat' => $this->getCircleCentre()->getLatitude()
+ ],
+ 'radius' => intval( $this->getCircleRadius() ),
+ ]
+ );
+ }
+
+ public function getCircleCentre(): LatLongValue {
+ return $this->circleCentre;
+ }
+
+ public function setCircleCentre( LatLongValue $circleCentre ) {
+ $this->circleCentre = $circleCentre;
+ }
+
+ public function getCircleRadius(): float {
+ return $this->circleRadius;
+ }
+
+ public function setCircleRadius( float $circleRadius ) {
+ $this->circleRadius = $circleRadius;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/ImageOverlay.php b/www/wiki/extensions/Maps/src/Elements/ImageOverlay.php
new file mode 100644
index 00000000..4e48f098
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/ImageOverlay.php
@@ -0,0 +1,36 @@
+<?php
+
+namespace Maps\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+
+/**
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class ImageOverlay extends Rectangle {
+
+ private $imageUrl;
+
+ public function __construct( LatLongValue $boundsNorthEast, LatLongValue $boundsSouthWest, string $image ) {
+ parent::__construct( $boundsNorthEast, $boundsSouthWest );
+
+ $this->imageUrl = $image;
+ }
+
+ public function getImage(): string {
+ return $this->imageUrl;
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $data = parent::getJSONObject( $defText, $defTitle );
+
+ $data['image'] = $this->imageUrl;
+
+ return $data;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/Line.php b/www/wiki/extensions/Maps/src/Elements/Line.php
new file mode 100644
index 00000000..2ea4ccda
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/Line.php
@@ -0,0 +1,69 @@
+<?php
+
+namespace Maps\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use InvalidArgumentException;
+
+/**
+ * Class representing a collection of LatLongValue objects forming a line.
+ *
+ * @since 3.0
+ *
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class Line extends \Maps\Elements\BaseStrokableElement {
+
+ /**
+ * @since 3.0
+ *
+ * @var LatLongValue[]
+ */
+ protected $coordinates;
+
+ /**
+ * @since 3.0
+ *
+ * @param LatLongValue[] $coordinates
+ *
+ * @throws InvalidArgumentException
+ */
+ public function __construct( array $coordinates = [] ) {
+ foreach ( $coordinates as $coordinate ) {
+ if ( !( $coordinate instanceof LatLongValue ) ) {
+ throw new InvalidArgumentException( 'Can only construct Line with LatLongValue objects' );
+ }
+ }
+
+ $this->coordinates = $coordinates;
+ }
+
+ /**
+ * @since 3.0
+ *
+ * @return LatLongValue[]
+ */
+ public function getLineCoordinates() {
+ return $this->coordinates;
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $parentArray = parent::getJSONObject( $defText, $defTitle );
+ $posArray = [];
+
+ foreach ( $this->coordinates as $mapLocation ) {
+ $posArray[] = [
+ 'lat' => $mapLocation->getLatitude(),
+ 'lon' => $mapLocation->getLongitude()
+ ];
+ }
+
+ $posArray = [ 'pos' => $posArray ];
+
+ return array_merge( $parentArray, $posArray );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/Location.php b/www/wiki/extensions/Maps/src/Elements/Location.php
new file mode 100644
index 00000000..6ea8c4be
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/Location.php
@@ -0,0 +1,157 @@
+<?php
+
+namespace Maps\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+
+/**
+ * Class describing a single location (geographical point).
+ *
+ * TODO: rethink the design of this class after deciding on what actual role it has
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Daniel Werner
+ */
+class Location extends BaseElement {
+
+ /**
+ * @var LatLongValue
+ */
+ private $coordinates;
+
+ /**
+ * @var string
+ */
+ private $address;
+
+ /**
+ * @var string
+ */
+ private $icon = '';
+
+ /**
+ * @var string
+ */
+ private $group = '';
+
+ /**
+ * @var string
+ */
+ private $inlineLabel = '';
+
+ /**
+ * @var string
+ */
+ private $visitedIcon = '';
+
+ public function __construct( LatLongValue $coordinates, string $title = '', string $text = '' ) {
+ $this->coordinates = $coordinates;
+ $this->setTitle( $title );
+ $this->setText( $text );
+ }
+
+ public static function newFromLatLon( float $lat, float $lon ): self {
+ return new self( new LatLongValue( $lat, $lon ) );
+ }
+
+ public function getCoordinates(): LatLongValue {
+ return $this->coordinates;
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '', string $defIconUrl = '',
+ string $defGroup = '', string $defInlineLabel = '', string $defVisitedIcon = '' ): array {
+
+ $parentArray = parent::getJSONObject( $defText, $defTitle );
+
+ $array = [
+ 'lat' => $this->coordinates->getLatitude(),
+ 'lon' => $this->coordinates->getLongitude(),
+ 'icon' => $this->hasIcon() ? \Maps\MapsFunctions::getFileUrl( $this->getIcon() ) : $defIconUrl,
+ ];
+ $val = $this->getAddress();
+ if ( $val !== '' ) {
+ $array['address'] = $val;
+ }
+ $val = $this->hasGroup() ? $this->getGroup() : $defGroup;
+ if ( !empty( $val ) ) {
+ $array['group'] = $val;
+ }
+ $val = $this->hasInlineLabel() ? $this->getInlineLabel() : $defInlineLabel;
+ if ( !empty( $val ) ) {
+ $array['inlineLabel'] = $val;
+ }
+ $val = $this->hasVisitedIcon() ? $this->getVisitedIcon() : $defVisitedIcon;
+ if ( !empty( $val ) ) {
+ $array['visitedicon'] = $val;
+ }
+
+ return array_merge( $parentArray, $array );
+ }
+
+ public function hasIcon(): bool {
+ return $this->icon !== '';
+ }
+
+ public function getIcon(): string {
+ return $this->icon;
+ }
+
+ public function setIcon( string $icon ) {
+ $this->icon = $icon;
+ }
+
+ /**
+ * Returns the address corresponding to this location.
+ * If there is none, and empty sting is returned.
+ */
+ public function getAddress(): string {
+ if ( is_null( $this->address ) ) {
+ $this->address = '';
+ }
+
+ return $this->address;
+ }
+
+ /**
+ * Returns whether Location is assigned to a group.
+ */
+ public function hasGroup(): bool {
+ return $this->group !== '';
+ }
+
+ public function getGroup(): string {
+ return $this->group;
+ }
+
+ public function setGroup( string $group ) {
+ $this->group = trim( $group );
+ }
+
+ public function hasInlineLabel(): bool {
+ return $this->inlineLabel !== '';
+ }
+
+ public function getInlineLabel(): string {
+ return $this->inlineLabel;
+ }
+
+ public function setInlineLabel( string $label ) {
+ $this->inlineLabel = $label;
+ }
+
+ public function hasVisitedIcon(): bool {
+ return $this->visitedIcon !== '';
+ }
+
+ public function getVisitedIcon(): string {
+ return $this->visitedIcon;
+ }
+
+ public function setVisitedIcon( string $visitedIcon ) {
+ $this->visitedIcon = $visitedIcon;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/Polygon.php b/www/wiki/extensions/Maps/src/Elements/Polygon.php
new file mode 100644
index 00000000..bd7289ec
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/Polygon.php
@@ -0,0 +1,44 @@
+<?php
+
+namespace Maps\Elements;
+
+/**
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class Polygon extends Line {
+
+ private $onlyVisibleOnHover = false;
+ private $fillOpacity = '0.5';
+ private $fillColor = '#FF0000';
+
+ public function isOnlyVisibleOnHover(): bool {
+ return $this->onlyVisibleOnHover;
+ }
+
+ public function setOnlyVisibleOnHover( bool $visible ) {
+ $this->onlyVisibleOnHover = $visible;
+ }
+
+ public function setFillOpacity( string $fillOpacity ) {
+ $this->fillOpacity = $fillOpacity;
+ }
+
+ public function setFillColor( string $fillColor ) {
+ $this->fillColor = $fillColor;
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $json = parent::getJSONObject( $defText, $defTitle );
+
+ $json['onlyVisibleOnHover'] = $this->onlyVisibleOnHover;
+ $json['fillColor'] = $this->fillColor;
+ $json['fillOpacity'] = $this->fillOpacity;
+
+ return $json;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/Rectangle.php b/www/wiki/extensions/Maps/src/Elements/Rectangle.php
new file mode 100644
index 00000000..d8392f70
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/Rectangle.php
@@ -0,0 +1,80 @@
+<?php
+
+namespace Maps\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use InvalidArgumentException;
+
+/**
+ * @since 3.0
+ *
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik < kim@heldig.org >
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class Rectangle extends \Maps\Elements\BaseFillableElement {
+
+ /**
+ * @since 3.0
+ * @var LatLongValue
+ */
+ protected $rectangleNorthEast;
+
+ /**
+ * @since 3.0
+ * @var LatLongValue
+ */
+ protected $rectangleSouthWest;
+
+ /**
+ * @since 3.0
+ *
+ * @param LatLongValue $rectangleNorthEast
+ * @param LatLongValue $rectangleSouthWest
+ *
+ * @throws InvalidArgumentException
+ */
+ public function __construct( LatLongValue $rectangleNorthEast, LatLongValue $rectangleSouthWest ) {
+ if ( $rectangleNorthEast->equals( $rectangleSouthWest ) ) {
+ throw new InvalidArgumentException( '$rectangleNorthEast cannot be equal to $rectangleSouthWest' );
+ }
+
+ // TODO: validate bounds are correct, if not, flip
+ $this->setRectangleNorthEast( $rectangleNorthEast );
+ $this->setRectangleSouthWest( $rectangleSouthWest );
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $parentArray = parent::getJSONObject( $defText, $defTitle );
+ $array = [
+ 'ne' => [
+ 'lon' => $this->getRectangleNorthEast()->getLongitude(),
+ 'lat' => $this->getRectangleNorthEast()->getLatitude()
+ ],
+ 'sw' => [
+ 'lon' => $this->getRectangleSouthWest()->getLongitude(),
+ 'lat' => $this->getRectangleSouthWest()->getLatitude()
+ ],
+ ];
+
+ return array_merge( $parentArray, $array );
+ }
+
+ public function getRectangleNorthEast(): LatLongValue {
+ return $this->rectangleNorthEast;
+ }
+
+ public function setRectangleNorthEast( LatLongValue $rectangleNorthEast ) {
+ $this->rectangleNorthEast = $rectangleNorthEast;
+ }
+
+ public function getRectangleSouthWest(): LatLongValue {
+ return $this->rectangleSouthWest;
+ }
+
+ public function setRectangleSouthWest( LatLongValue $rectangleSouthWest ) {
+ $this->rectangleSouthWest = $rectangleSouthWest;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Elements/WmsOverlay.php b/www/wiki/extensions/Maps/src/Elements/WmsOverlay.php
new file mode 100644
index 00000000..fa3c95f9
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Elements/WmsOverlay.php
@@ -0,0 +1,71 @@
+<?php
+
+namespace Maps\Elements;
+
+/**
+ * Class that holds metadata on WMS overlay layers on map
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Mathias Lidal < mathiaslidal@gmail.com >
+ */
+class WmsOverlay extends BaseElement {
+
+ /**
+ * @var String Base url to WMS server
+ */
+ private $wmsServerUrl;
+
+ /**
+ * @var String WMS Layer name
+ */
+ private $wmsLayerName;
+
+ /**
+ * @var String WMS Style name (default value: 'default')
+ */
+ private $wmsStyleName;
+
+ public function __construct( string $wmsServerUrl, string $wmsLayerName, string $wmsStyleName = "default" ) {
+ $this->setWmsServerUrl( $wmsServerUrl );
+ $this->setWmsLayerName( $wmsLayerName );
+ $this->setWmsStyleName( $wmsStyleName );
+ }
+
+ public function getJSONObject( string $defText = '', string $defTitle = '' ): array {
+ $parentArray = parent::getJSONObject( $defText, $defTitle );
+
+ $array = [
+ 'wmsServerUrl' => $this->getWmsServerUrl(),
+ 'wmsLayerName' => $this->getWmsLayerName(),
+ 'wmsStyleName' => $this->getWmsStyleName()
+ ];
+ return array_merge( $parentArray, $array );
+ }
+
+ public function getWmsServerUrl(): string {
+ return $this->wmsServerUrl;
+ }
+
+ public function setWmsServerUrl( string $wmsServerUrl ) {
+ $this->wmsServerUrl = $wmsServerUrl;
+ }
+
+ public function getWmsLayerName(): string {
+ return $this->wmsLayerName;
+ }
+
+ public function setWmsLayerName( string $wmsLayerName ) {
+ $this->wmsLayerName = $wmsLayerName;
+ }
+
+ public function getWmsStyleName(): string {
+ return $this->wmsStyleName;
+ }
+
+ public function setWmsStyleName( string $wmsStyleName ) {
+ $this->wmsStyleName = $wmsStyleName;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/FileUrlFinder.php b/www/wiki/extensions/Maps/src/FileUrlFinder.php
new file mode 100644
index 00000000..c4894d53
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/FileUrlFinder.php
@@ -0,0 +1,18 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+interface FileUrlFinder {
+
+ /**
+ * Resolves the url of images provided as wiki page; leaves others alone.
+ */
+ public function getUrlForFileName( string $fileName ): string;
+
+}
diff --git a/www/wiki/extensions/Maps/src/GeoFunctions.php b/www/wiki/extensions/Maps/src/GeoFunctions.php
new file mode 100644
index 00000000..75a92791
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/GeoFunctions.php
@@ -0,0 +1,99 @@
+<?php
+
+namespace Maps;
+
+use DataValues\Geo\Values\LatLongValue;
+
+/**
+ * Static class containing geographical functions.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Pnelnik
+ * @author Matěj Grabovský
+ */
+final class GeoFunctions {
+
+ // The approximate radius of the earth in meters, according to http://en.wikipedia.org/wiki/Earth_radius.
+ private const EARTH_RADIUS = 6371000;
+
+ /**
+ * Returns the geographical distance between two coordinates.
+ * See http://en.wikipedia.org/wiki/Geographical_distance
+ *
+ * @since 2.0
+ *
+ * @param LatLongValue $start
+ * @param LatLongValue $end
+ *
+ * @return float Distance in m.
+ */
+ public static function calculateDistance( LatLongValue $start, LatLongValue $end ) {
+ $northRad1 = deg2rad( $start->getLatitude() );
+ $eastRad1 = deg2rad( $start->getLongitude() );
+
+ $cosNorth1 = cos( $northRad1 );
+ $cosEast1 = cos( $eastRad1 );
+
+ $sinNorth1 = sin( $northRad1 );
+ $sinEast1 = sin( $eastRad1 );
+
+ $northRad2 = deg2rad( $end->getLatitude() );
+ $eastRad2 = deg2rad( $end->getLongitude() );
+
+ $cosNorth2 = cos( $northRad2 );
+ $cosEast2 = cos( $eastRad2 );
+
+ $sinNorth2 = sin( $northRad2 );
+ $sinEast2 = sin( $eastRad2 );
+
+ $term1 = $cosNorth1 * $sinEast1 - $cosNorth2 * $sinEast2;
+ $term2 = $cosNorth1 * $cosEast1 - $cosNorth2 * $cosEast2;
+ $term3 = $sinNorth1 - $sinNorth2;
+
+ $distThruSquared = $term1 * $term1 + $term2 * $term2 + $term3 * $term3;
+
+ $distance = 2 * self::EARTH_RADIUS * asin( sqrt( $distThruSquared ) / 2 );
+
+ assert( $distance >= 0 );
+
+ return $distance;
+ }
+
+ /**
+ * Finds a destination given a starting location, bearing and distance.
+ *
+ * @since 2.0
+ *
+ * @param LatLongValue $startingCoordinates
+ * @param float $bearing The initial bearing in degrees.
+ * @param float $distance The distance to travel in km.
+ *
+ * @return array The destination coordinates, as non-directional floats in an array with lat and lon keys.
+ */
+ public static function findDestination( LatLongValue $startingCoordinates, $bearing, $distance ) {
+ $startingCoordinates = [
+ 'lat' => deg2rad( $startingCoordinates->getLatitude() ),
+ 'lon' => deg2rad( $startingCoordinates->getLongitude() ),
+ ];
+
+ $radBearing = deg2rad( (float)$bearing );
+ $angularDistance = $distance / self::EARTH_RADIUS;
+
+ $lat = asin(
+ sin( $startingCoordinates['lat'] ) * cos( $angularDistance ) + cos( $startingCoordinates['lat'] ) * sin(
+ $angularDistance
+ ) * cos( $radBearing )
+ );
+ $lon = $startingCoordinates['lon'] + atan2(
+ sin( $radBearing ) * sin( $angularDistance ) * cos( $startingCoordinates['lat'] ),
+ cos( $angularDistance ) - sin( $startingCoordinates['lat'] ) * sin( $lat )
+ );
+
+ return [
+ 'lat' => rad2deg( $lat ),
+ 'lon' => rad2deg( $lon )
+ ];
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/GoogleMapsService.php b/www/wiki/extensions/Maps/src/GoogleMapsService.php
new file mode 100644
index 00000000..9c1b91b9
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/GoogleMapsService.php
@@ -0,0 +1,314 @@
+<?php
+
+namespace Maps;
+
+use Html;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+class GoogleMapsService implements MappingService {
+
+ /**
+ * Maps user input map types to the Google Maps names for the map types.
+ */
+ private const MAP_TYPES = [
+ 'normal' => 'ROADMAP',
+ 'roadmap' => 'ROADMAP',
+ 'satellite' => 'SATELLITE',
+ 'hybrid' => 'HYBRID',
+ 'terrain' => 'TERRAIN',
+ 'physical' => 'TERRAIN',
+ 'earth' => 'earth'
+ ];
+
+ private const TYPE_CONTROL_STYLES = [
+ 'default' => 'DEFAULT',
+ 'horizontal' => 'HORIZONTAL_BAR',
+ 'dropdown' => 'DROPDOWN_MENU'
+ ];
+
+ private $addedDependencies = [];
+
+ public function getName(): string {
+ return 'googlemaps3';
+ }
+
+ public function getAliases(): array {
+ return [ 'googlemaps', 'google' ];
+ }
+
+ public function hasAlias( string $alias ): bool {
+ return in_array( $alias, [ 'googlemaps', 'google' ] );
+ }
+
+ public function getParameterInfo(): array {
+ global $egMapsGMaps3Type, $egMapsGMaps3Types, $egMapsGMaps3Controls, $egMapsGMaps3Layers;
+ global $egMapsGMaps3DefTypeStyle, $egMapsGMaps3DefZoomStyle, $egMapsGMaps3AutoInfoWindows;
+ global $egMapsResizableByDefault;
+
+ $params = [];
+
+ $params['zoom'] = [
+ 'type' => 'integer',
+ 'range' => [ 0, 20 ],
+ 'default' => $GLOBALS['egMapsGMaps3Zoom'],
+ 'message' => 'maps-par-zoom',
+ ];
+
+ $params['type'] = [
+ 'default' => $egMapsGMaps3Type,
+ 'values' => self::getTypeNames(),
+ 'message' => 'maps-googlemaps3-par-type',
+ 'post-format' => function ( $value ) {
+ return GoogleMapsService::MAP_TYPES[strtolower( $value )];
+ },
+ ];
+
+ $params['types'] = [
+ 'dependencies' => 'type',
+ 'default' => $egMapsGMaps3Types,
+ 'values' => self::getTypeNames(),
+ 'message' => 'maps-googlemaps3-par-types',
+ 'islist' => true,
+ 'post-format' => function ( array $value ) {
+ foreach ( $value as &$part ) {
+ $part = self::MAP_TYPES[strtolower( $part )];
+ }
+
+ return $value;
+ },
+ ];
+
+ $params['layers'] = [
+ 'default' => $egMapsGMaps3Layers,
+ 'values' => [
+ 'traffic',
+ 'bicycling',
+ 'transit'
+ ],
+ 'message' => 'maps-googlemaps3-par-layers',
+ 'islist' => true,
+ ];
+
+ $params['controls'] = [
+ 'default' => $egMapsGMaps3Controls,
+ 'values' => [
+ 'pan',
+ 'zoom',
+ 'type',
+ 'scale',
+ 'streetview',
+ 'rotate'
+ ],
+ 'message' => 'maps-googlemaps3-par-controls',
+ 'islist' => true,
+ 'post-format' => function ( $value ) {
+ return array_map( 'strtolower', $value );
+ },
+ ];
+
+ $params['zoomstyle'] = [
+ 'default' => $egMapsGMaps3DefZoomStyle,
+ 'values' => [ 'default', 'small', 'large' ],
+ 'message' => 'maps-googlemaps3-par-zoomstyle',
+ 'post-format' => 'strtoupper',
+ ];
+
+ $params['typestyle'] = [
+ 'default' => $egMapsGMaps3DefTypeStyle,
+ 'values' => array_keys( self::TYPE_CONTROL_STYLES ),
+ 'message' => 'maps-googlemaps3-par-typestyle',
+ 'post-format' => function ( $value ) {
+ return self::TYPE_CONTROL_STYLES[strtolower( $value )];
+ },
+ ];
+
+ $params['autoinfowindows'] = [
+ 'type' => 'boolean',
+ 'default' => $egMapsGMaps3AutoInfoWindows,
+ 'message' => 'maps-googlemaps3-par-autoinfowindows',
+ ];
+
+ $params['resizable'] = [
+ 'type' => 'boolean',
+ 'default' => $egMapsResizableByDefault,
+ 'message' => 'maps-par-resizable',
+ ];
+
+ $params['kmlrezoom'] = [
+ 'type' => 'boolean',
+ 'default' => $GLOBALS['egMapsRezoomForKML'],
+ 'message' => 'maps-googlemaps3-par-kmlrezoom',
+ ];
+
+ $params['poi'] = [
+ 'type' => 'boolean',
+ 'default' => $GLOBALS['egMapsShowPOI'],
+ 'message' => 'maps-googlemaps3-par-poi',
+ ];
+
+ $params['markercluster'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ 'message' => 'maps-par-markercluster',
+ ];
+
+ $params['clustergridsize'] = [
+ 'type' => 'integer',
+ 'default' => 60,
+ 'message' => 'maps-googlemaps3-par-clustergridsize',
+ ];
+
+ $params['clustermaxzoom'] = [
+ 'type' => 'integer',
+ 'default' => 20,
+ 'message' => 'maps-par-clustermaxzoom',
+ ];
+
+ $params['clusterzoomonclick'] = [
+ 'type' => 'boolean',
+ 'default' => true,
+ 'message' => 'maps-par-clusterzoomonclick',
+ ];
+
+ $params['clusteraveragecenter'] = [
+ 'type' => 'boolean',
+ 'default' => true,
+ 'message' => 'maps-googlemaps3-par-clusteraveragecenter',
+ ];
+
+ $params['clusterminsize'] = [
+ 'type' => 'integer',
+ 'default' => 2,
+ 'message' => 'maps-googlemaps3-par-clusterminsize',
+ ];
+
+ $params['imageoverlays'] = [
+ 'type' => 'mapsimageoverlay',
+ 'default' => [],
+ 'delimiter' => ';',
+ 'islist' => true,
+ 'message' => 'maps-googlemaps3-par-imageoverlays',
+ ];
+
+ $params['kml'] = [
+ 'default' => [],
+ 'message' => 'maps-par-kml',
+ 'islist' => true,
+ 'post-format' => function( array $kmlFileNames ) {
+ return array_map(
+ function( string $fileName ) {
+ return wfExpandUrl( MapsFunctions::getFileUrl( $fileName ) );
+ },
+ $kmlFileNames
+ );
+ }
+ ];
+
+ $params['gkml'] = [
+ 'default' => [],
+ 'message' => 'maps-googlemaps3-par-gkml',
+ 'islist' => true,
+ ];
+
+ $params['searchmarkers'] = [
+ 'default' => '',
+ 'message' => 'maps-par-searchmarkers',
+ // new CriterionSearchMarkers() FIXME
+ ];
+
+ $params['enablefullscreen'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ 'message' => 'maps-par-enable-fullscreen',
+ ];
+
+ $params['scrollwheelzoom'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ 'message' => 'maps-par-scrollwheelzoom',
+ ];
+
+ return $params;
+ }
+
+ /**
+ * Returns the names of all supported map types.
+ */
+ private function getTypeNames(): array {
+ return array_keys( self::MAP_TYPES );
+ }
+
+ public function newMapId(): string {
+ static $mapsOnThisPage = 0;
+
+ $mapsOnThisPage++;
+
+ return 'map_google3_' . $mapsOnThisPage;
+ }
+
+ public function getResourceModules(): array {
+ return [ 'ext.maps.googlemaps3', 'ext.sm.googlemaps3ajax' ];
+ }
+
+ public static function getApiScript( $langCode, array $urlArgs = [] ) {
+ $urlArgs = array_merge(
+ [
+ 'language' => self::getMappedLanguageCode( $langCode )
+ ],
+ $urlArgs
+ );
+ if ( $GLOBALS['egMapsGMaps3ApiKey'] !== '' ) {
+ $urlArgs['key'] = $GLOBALS['egMapsGMaps3ApiKey'];
+ }
+ if ( $GLOBALS['egMapsGMaps3ApiVersion'] !== '' ) {
+ $urlArgs['v'] = $GLOBALS['egMapsGMaps3ApiVersion'];
+ }
+
+ return Html::linkedScript( '//maps.googleapis.com/maps/api/js?' . wfArrayToCgi( $urlArgs ) );
+ }
+
+ /**
+ * Maps language codes to Google Maps API v3 compatible values.
+ */
+ private static function getMappedLanguageCode( string $code ): string {
+ $mappings = [
+ 'en_gb' => 'en-gb',// v3 supports en_gb - but wants us to call it en-gb
+ 'he' => 'iw', // iw is googlish for hebrew
+ 'fj' => 'fil', // google does not support Fijian - use Filipino as close(?) supported relative
+ ];
+
+ if ( array_key_exists( $code, $mappings ) ) {
+ return $mappings[$code];
+ }
+
+ return $code;
+ }
+
+ public function getDependencyHtml( array $params ): string {
+ $dependencies = [];
+
+ // Only add dependencies that have not yet been added.
+ foreach ( $this->getDependencies() as $dependency ) {
+ if ( !in_array( $dependency, $this->addedDependencies ) ) {
+ $dependencies[] = $dependency;
+ $this->addedDependencies[] = $dependency;
+ }
+ }
+
+ // If there are dependencies, put them all together in a string, otherwise return false.
+ return $dependencies !== [] ? implode( '', $dependencies ) : false;
+ }
+
+ private function getDependencies(): array {
+ return [
+ self::getApiScript(
+ is_string( $GLOBALS['egMapsGMaps3Language'] ) ?
+ $GLOBALS['egMapsGMaps3Language'] : $GLOBALS['egMapsGMaps3Language']->getCode()
+ )
+ ];
+ }
+}
diff --git a/www/wiki/extensions/Maps/src/LeafletService.php b/www/wiki/extensions/Maps/src/LeafletService.php
new file mode 100644
index 00000000..0e41d670
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/LeafletService.php
@@ -0,0 +1,184 @@
+<?php
+
+namespace Maps;
+
+use Html;
+
+/**
+ * @licence GNU GPL v2+
+ */
+class LeafletService implements MappingService {
+
+ private $addedDependencies = [];
+
+ public function getName(): string {
+ return 'leaflet';
+ }
+
+ public function getAliases(): array {
+ return [ 'leafletmaps', 'leaflet' ]; // TODO: main name should not be in here?
+ }
+
+ public function hasAlias( string $alias ): bool {
+ return in_array( $alias, [ 'leafletmaps', 'leaflet' ] );
+ }
+
+ public function getParameterInfo(): array {
+ global $GLOBALS;
+
+ $params = [];
+
+ $params['zoom'] = [
+ 'type' => 'integer',
+ 'range' => [ 0, 20 ],
+ 'default' => false,
+ 'message' => 'maps-par-zoom'
+ ];
+
+ $params['defzoom'] = [
+ 'type' => 'integer',
+ 'range' => [ 0, 20 ],
+ 'default' => self::getDefaultZoom(),
+ 'message' => 'maps-leaflet-par-defzoom'
+ ];
+
+ $params['layers'] = [
+ 'aliases' => 'layer',
+ 'type' => 'string',
+ 'values' => array_keys( $GLOBALS['egMapsLeafletAvailableLayers'], true, true ),
+ 'default' => $GLOBALS['egMapsLeafletLayers'],
+ 'message' => 'maps-leaflet-par-layers',
+ 'islist' => true,
+ ];
+
+ $params['overlaylayers'] = [
+ 'type' => 'string',
+ 'values' => array_keys( $GLOBALS['egMapsLeafletAvailableOverlayLayers'], true, true ),
+ 'default' => $GLOBALS['egMapsLeafletOverlayLayers'],
+ 'message' => 'maps-leaflet-par-overlaylayers',
+ 'islist' => true,
+ ];
+
+ $params['resizable'] = [
+ 'type' => 'boolean',
+ 'default' => $GLOBALS['egMapsResizableByDefault'],
+ 'message' => 'maps-par-resizable'
+ ];
+
+ $params['enablefullscreen'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ 'message' => 'maps-par-enable-fullscreen',
+ ];
+
+ $params['scrollwheelzoom'] = [
+ 'type' => 'boolean',
+ 'default' => true,
+ 'message' => 'maps-par-scrollwheelzoom',
+ ];
+
+ $params['markercluster'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ 'message' => 'maps-par-markercluster',
+ ];
+
+ $params['clustermaxzoom'] = [
+ 'type' => 'integer',
+ 'default' => 20,
+ 'message' => 'maps-par-clustermaxzoom',
+ ];
+
+ $params['clusterzoomonclick'] = [
+ 'type' => 'boolean',
+ 'default' => true,
+ 'message' => 'maps-par-clusterzoomonclick',
+ ];
+
+ $params['clustermaxradius'] = [
+ 'type' => 'integer',
+ 'default' => 80,
+ 'message' => 'maps-par-maxclusterradius',
+ ];
+
+ $params['clusterspiderfy'] = [
+ 'type' => 'boolean',
+ 'default' => true,
+ 'message' => 'maps-leaflet-par-clusterspiderfy',
+ ];
+
+ $params['geojson'] = [
+ 'type' => 'jsonfile',
+ 'default' => '',
+ 'message' => 'maps-displaymap-par-geojson',
+ ];
+
+ return $params;
+ }
+
+ /**
+ * @since 3.0
+ */
+ public function getDefaultZoom() {
+ return $GLOBALS['egMapsLeafletZoom'];
+ }
+
+ public function newMapId(): string {
+ static $mapsOnThisPage = 0;
+
+ $mapsOnThisPage++;
+
+ return 'map_leaflet_' . $mapsOnThisPage;
+ }
+
+ public function getResourceModules(): array {
+ return [ 'ext.maps.leaflet', 'ext.sm.leafletajax' ];
+ }
+
+ public function getDependencyHtml( array $params ): string {
+ $dependencies = [];
+
+ // Only add dependencies that have not yet been added.
+ foreach ( $this->getDependencies( $params ) as $dependency ) {
+ if ( !in_array( $dependency, $this->addedDependencies ) ) {
+ $dependencies[] = $dependency;
+ $this->addedDependencies[] = $dependency;
+ }
+ }
+
+ // If there are dependencies, put them all together in a string, otherwise return false.
+ return $dependencies !== [] ? implode( '', $dependencies ) : false;
+ }
+
+ private function getDependencies( array $params ): array {
+ $leafletPath = $GLOBALS['wgScriptPath'] . '/extensions/Maps/resources/leaflet/leaflet';
+
+ return array_merge(
+ [
+ Html::linkedStyle( "$leafletPath/leaflet.css" ),
+ Html::linkedScript( "$leafletPath/leaflet.js" ),
+ ],
+ $this->getLayerDependencies( $params )
+ );
+ }
+
+ private function getLayerDependencies( array $params ) {
+ global $egMapsLeafletLayerDependencies, $egMapsLeafletAvailableLayers,
+ $egMapsLeafletLayersApiKeys;
+
+ $layerDependencies = [];
+
+ foreach ( $params['layers'] as $layerName ) {
+ if ( array_key_exists( $layerName, $egMapsLeafletAvailableLayers )
+ && $egMapsLeafletAvailableLayers[$layerName]
+ && array_key_exists( $layerName, $egMapsLeafletLayersApiKeys )
+ && array_key_exists( $layerName, $egMapsLeafletLayerDependencies ) ) {
+ $layerDependencies[] = '<script src="' . $egMapsLeafletLayerDependencies[$layerName] .
+ $egMapsLeafletLayersApiKeys[$layerName] . '"></script>';
+ }
+ }
+
+ return array_unique( $layerDependencies );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MappingService.php b/www/wiki/extensions/Maps/src/MappingService.php
new file mode 100644
index 00000000..184ef712
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MappingService.php
@@ -0,0 +1,33 @@
+<?php
+
+namespace Maps;
+
+use ParamProcessor\ParamDefinition;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+interface MappingService {
+
+ public function getName(): string;
+
+ public function getAliases(): array;
+
+ public function hasAlias( string $alias ): bool;
+
+ /**
+ * @return array[]|ParamDefinition[]
+ */
+ public function getParameterInfo(): array;
+
+ public function getDependencyHtml( array $params ): string;
+
+ /**
+ * Returns the resource modules that need to be loaded to use this mapping service.
+ */
+ public function getResourceModules(): array;
+
+ public function newMapId();
+
+}
diff --git a/www/wiki/extensions/Maps/src/MappingServices.php b/www/wiki/extensions/Maps/src/MappingServices.php
new file mode 100644
index 00000000..295a7299
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MappingServices.php
@@ -0,0 +1,82 @@
+<?php
+
+namespace Maps;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+final class MappingServices {
+
+ /**
+ * @var MappingService[]
+ */
+ private $nameToServiceMap = [];
+
+ /**
+ * @var string Name of the default service, which is used as fallback
+ */
+ private $defaultService;
+
+ /**
+ * @param string[] $availableServices
+ * @param string $defaultService
+ * @param MappingService ...$services
+ * @throws \InvalidArgumentException
+ */
+ public function __construct( array $availableServices, string $defaultService, MappingService ...$services ) {
+ $this->defaultService = $defaultService;
+
+ foreach ( $services as $service ) {
+ if ( in_array( $service->getName(), $availableServices ) ) {
+ $this->nameToServiceMap[$service->getName()] = $service;
+
+ foreach ( $service->getAliases() as $alias ) {
+ $this->nameToServiceMap[$alias] = $service;
+ }
+ }
+ }
+
+ if ( !$this->nameIsKnown( $defaultService ) ) {
+ throw new \InvalidArgumentException( 'The default mapping service needs to be available' );
+ }
+ }
+
+ /**
+ * @param string $name Name or alias of a service
+ * @return bool
+ */
+ public function nameIsKnown( string $name ): bool {
+ return array_key_exists( $name, $this->nameToServiceMap );
+ }
+
+ /**
+ * @param string $name Name or alias of a service
+ * @return MappingService
+ * @throws \OutOfBoundsException
+ */
+ public function getService( string $name ): MappingService {
+ if ( !$this->nameIsKnown( $name ) ) {
+ throw new \OutOfBoundsException();
+ }
+
+ return $this->nameToServiceMap[$name];
+ }
+
+ /**
+ * @param string $name Name or alias of a service
+ * @return MappingService
+ */
+ public function getServiceOrDefault( string $name ): MappingService {
+ if ( $this->nameIsKnown( $name ) ) {
+ return $this->nameToServiceMap[$name];
+ }
+
+ return $this->nameToServiceMap[$this->defaultService];
+ }
+
+ public function getAllNames(): array {
+ return array_keys( $this->nameToServiceMap );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MapsFactory.php b/www/wiki/extensions/Maps/src/MapsFactory.php
new file mode 100644
index 00000000..6ab23d5d
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MapsFactory.php
@@ -0,0 +1,168 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps;
+
+use FileFetcher\Cache\Factory as CacheFactory;
+use FileFetcher\FileFetcher;
+use Jeroen\SimpleGeocoder\Geocoder;
+use Jeroen\SimpleGeocoder\Geocoders\Decorators\CoordinateFriendlyGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\FileFetchers\GeoNamesGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\FileFetchers\GoogleGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\FileFetchers\NominatimGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\NullGeocoder;
+use Maps\DataAccess\CachingGeocoder;
+use Maps\DataAccess\MapsFileFetcher;
+use Maps\DataAccess\MediaWikiFileUrlFinder;
+use Maps\DataAccess\PageContentFetcher;
+use Maps\MediaWiki\ParserHooks\DisplayMapFunction;
+use Maps\Presentation\CoordinateFormatter;
+use Maps\Presentation\WikitextParsers\LocationParser;
+use MediaWiki\MediaWikiServices;
+use SimpleCache\Cache\Cache;
+use SimpleCache\Cache\MediaWikiCache;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsFactory {
+
+ private $settings;
+ private $mediaWikiServices;
+
+ private function __construct( array $settings, MediaWikiServices $mediaWikiServices ) {
+ $this->settings = $settings;
+ $this->mediaWikiServices = $mediaWikiServices;
+ }
+
+ public static function newDefault(): self {
+ return new self( $GLOBALS, MediaWikiServices::getInstance() );
+ }
+
+ /**
+ * Only for legacy code where dependency injection is not possible
+ */
+ public static function globalInstance(): self {
+ static $instance = null;
+
+ if ( $instance === null ) {
+ $instance = self::newDefault();
+ }
+
+ return $instance;
+ }
+
+ public function newLocationParser(): LocationParser {
+ return LocationParser::newInstance(
+ $this->getGeocoder(),
+ $this->getFileUrlFinder()
+ );
+ }
+
+ public function getGeocoder(): Geocoder {
+ $geocoder = new CoordinateFriendlyGeocoder( $this->newCoreGeocoder() );
+
+ if ( $this->settings['egMapsEnableGeoCache'] ) {
+ return new CachingGeocoder(
+ $geocoder,
+ $this->getMediaWikiCache(),
+ $this->settings['egMapsGeoCacheTtl']
+ );
+ }
+
+ return $geocoder;
+ }
+
+ private function newCoreGeocoder(): Geocoder {
+ switch ( $this->settings['egMapsDefaultGeoService'] ) {
+ case 'geonames':
+ if ( $this->settings['egMapsGeoNamesUser'] === '' ) {
+ return $this->newGoogleGeocoder();
+ }
+
+ return new GeoNamesGeocoder(
+ $this->newFileFetcher(),
+ $this->settings['egMapsGeoNamesUser']
+ );
+ case 'google':
+ return $this->newGoogleGeocoder();
+ case 'nominatim':
+ return new NominatimGeocoder(
+ $this->newFileFetcher()
+ );
+ default:
+ return new NullGeocoder();
+ }
+ }
+
+ private function newGoogleGeocoder(): Geocoder {
+ return new GoogleGeocoder(
+ $this->newFileFetcher(),
+ $this->settings['egMapsGMaps3ApiKey'],
+ $this->settings['egMapsGMaps3ApiVersion']
+ );
+ }
+
+ public function getFileFetcher(): FileFetcher {
+ return $this->newFileFetcher();
+ }
+
+ private function newFileFetcher(): FileFetcher {
+ return new MapsFileFetcher();
+ }
+
+ public function getGeoJsonFileFetcher(): FileFetcher {
+ if ( $this->settings['egMapsGeoJsonCacheTtl'] === 0 ) {
+ return $this->getFileFetcher();
+ }
+
+ return ( new CacheFactory() )->newJeroenSimpleCacheFetcher(
+ $this->getFileFetcher(),
+ $this->getMediaWikiSimpleCache( $this->settings['egMapsGeoJsonCacheTtl'] )
+ );
+ }
+
+ private function getMediaWikiSimpleCache( int $ttlInSeconds ): Cache {
+ return new MediaWikiCache(
+ $this->getMediaWikiCache(),
+ $ttlInSeconds
+ );
+ }
+
+ private function getMediaWikiCache(): \BagOStuff {
+ return wfGetCache( CACHE_ANYTHING );
+ }
+
+ public function getPageContentFetcher(): PageContentFetcher {
+ return new PageContentFetcher(
+ $this->mediaWikiServices->getTitleParser(),
+ $this->mediaWikiServices->getRevisionLookup()
+ );
+ }
+
+ public function getCoordinateFormatter(): CoordinateFormatter {
+ return new CoordinateFormatter();
+ }
+
+ public function getFileUrlFinder(): FileUrlFinder {
+ return new MediaWikiFileUrlFinder();
+ }
+
+ public function getMappingServices(): MappingServices {
+ return new MappingServices(
+ $this->settings['egMapsAvailableServices'],
+ $this->settings['egMapsDefaultService'],
+ new GoogleMapsService(),
+ new LeafletService()
+ );
+ }
+
+ public function getDisplayMapFunction(): DisplayMapFunction {
+ return new DisplayMapFunction(
+ $this->getMappingServices()
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MapsFunctions.php b/www/wiki/extensions/Maps/src/MapsFunctions.php
new file mode 100644
index 00000000..47cd1358
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MapsFunctions.php
@@ -0,0 +1,218 @@
+<?php
+
+namespace Maps;
+
+use Xml;
+
+/**
+ * A class that holds static helper functions for generic mapping-related functions.
+ *
+ * @deprecated
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+final class MapsFunctions {
+
+ /**
+ * Encode a variable of unknown type to JavaScript.
+ * Arrays are converted to JS arrays, objects are converted to JS associative
+ * arrays (objects). So cast your PHP associative arrays to objects before
+ * passing them to here.
+ *
+ * This is a copy of
+ *
+ * @see Xml::encodeJsVar
+ * which fixes incorrect behaviour with floats.
+ *
+ * @since 0.7.1
+ *
+ * @param mixed $value
+ *
+ * @return string
+ */
+ public static function encodeJsVar( $value ) {
+ if ( is_bool( $value ) ) {
+ $s = $value ? 'true' : 'false';
+ } elseif ( is_null( $value ) ) {
+ $s = 'null';
+ } elseif ( is_int( $value ) || is_float( $value ) ) {
+ $s = $value;
+ } elseif ( is_array( $value ) && // Make sure it's not associative.
+ array_keys( $value ) === range( 0, count( $value ) - 1 ) ||
+ count( $value ) == 0
+ ) {
+ $s = '[';
+ foreach ( $value as $elt ) {
+ if ( $s != '[' ) {
+ $s .= ', ';
+ }
+ $s .= self::encodeJsVar( $elt );
+ }
+ $s .= ']';
+ } elseif ( is_object( $value ) || is_array( $value ) ) {
+ // Objects and associative arrays
+ $s = '{';
+ foreach ( (array)$value as $name => $elt ) {
+ if ( $s != '{' ) {
+ $s .= ', ';
+ }
+ $s .= '"' . Xml::encodeJsVar( $name ) . '": ' .
+ self::encodeJsVar( $elt );
+ }
+ $s .= '}';
+ } else {
+ $s = '"' . Xml::encodeJsVar( $value ) . '"';
+ }
+ return $s;
+ }
+
+ /**
+ * This function returns the definitions for the parameters used by every map feature.
+ *
+ * @return array
+ */
+ public static function getCommonParameters() {
+ $params = [];
+
+ $params['mappingservice'] = [
+ 'type' => 'string',
+ 'aliases' => 'service',
+ 'default' => $GLOBALS['egMapsDefaultService'],
+ 'values' => MapsFactory::globalInstance()->getMappingServices()->getAllNames(),
+ ];
+
+ $params['width'] = [
+ 'type' => 'dimension',
+ 'allowauto' => true,
+ 'units' => [ 'px', 'ex', 'em', '%', '' ],
+ 'default' => $GLOBALS['egMapsMapWidth'],
+ ];
+
+ $params['height'] = [
+ 'type' => 'dimension',
+ 'units' => [ 'px', 'ex', 'em', '' ],
+ 'default' => $GLOBALS['egMapsMapHeight'],
+ ];
+
+ $params['centre'] = [
+ 'type' => 'string',
+ 'aliases' => [ 'center' ],
+ 'default' => false,
+ 'manipulatedefault' => false,
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-par-mappingservice, maps-par-geoservice, maps-par-width,
+ // maps-par-height, maps-par-centre
+ foreach ( $params as $name => &$data ) {
+ $data['name'] = $name;
+ $data['message'] = 'maps-par-' . $name;
+ }
+
+ $params['title'] = [
+ 'name' => 'title',
+ 'default' => $GLOBALS['egMapsDefaultTitle'],
+ ];
+
+ $params['label'] = [
+ 'default' => $GLOBALS['egMapsDefaultLabel'],
+ 'aliases' => 'text',
+ ];
+
+ $params['icon'] = [
+ 'default' => '',
+ ];
+
+ $params['visitedicon'] = [
+ 'default' => '',
+ ];
+
+ $params['lines'] = [
+ 'type' => 'mapsline',
+ 'default' => [],
+ 'delimiter' => ';',
+ 'islist' => true,
+ ];
+
+ $params['polygons'] = [
+ 'type' => 'mapspolygon',
+ 'default' => [],
+ 'delimiter' => ';',
+ 'islist' => true,
+ ];
+
+ $params['circles'] = [
+ 'type' => 'mapscircle',
+ 'default' => [],
+ 'delimiter' => ';',
+ 'islist' => true,
+ ];
+
+ $params['rectangles'] = [
+ 'type' => 'mapsrectangle',
+ 'default' => [],
+ 'delimiter' => ';',
+ 'islist' => true,
+ ];
+
+ $params['wmsoverlay'] = [
+ 'type' => 'wmsoverlay',
+ 'default' => false,
+ 'delimiter' => ' ',
+ ];
+
+ $params['maxzoom'] = [
+ 'type' => 'integer',
+ 'default' => false,
+ 'manipulatedefault' => false,
+ 'dependencies' => 'minzoom',
+ ];
+
+ $params['minzoom'] = [
+ 'type' => 'integer',
+ 'default' => false,
+ 'manipulatedefault' => false,
+ 'lowerbound' => 0,
+ ];
+
+ $params['copycoords'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ ];
+
+ $params['static'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-displaymap-par-title, maps-displaymap-par-label, maps-displaymap-par-icon,
+ // maps-displaymap-par-visitedicon, aps-displaymap-par-lines, maps-displaymap-par-polygons,
+ // maps-displaymap-par-circles, maps-displaymap-par-rectangles, maps-displaymap-par-wmsoverlay,
+ // maps-displaymap-par-maxzoom, maps-displaymap-par-minzoom, maps-displaymap-par-copycoords,
+ // maps-displaymap-par-static
+ foreach ( $params as $name => &$param ) {
+ if ( !array_key_exists( 'message', $param ) ) {
+ $param['message'] = 'maps-displaymap-par-' . $name;
+ }
+ }
+
+ return $params;
+ }
+
+ /**
+ * Resolves the url of images provided as wiki page; leaves others alone.
+ *
+ * @since 1.0
+ * @deprecated
+ *
+ * @param string $file
+ *
+ * @return string
+ */
+ public static function getFileUrl( $file ): string {
+ return MapsFactory::globalInstance()->getFileUrlFinder()->getUrlForFileName( $file );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MapsSetup.php b/www/wiki/extensions/Maps/src/MapsSetup.php
new file mode 100644
index 00000000..d397e632
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MapsSetup.php
@@ -0,0 +1,462 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps;
+
+use DataValues\Geo\Parsers\LatLongParser;
+use Maps\DataAccess\JsonFileParser;
+use Maps\MediaWiki\Content\GeoJsonContent;
+use Maps\MediaWiki\Content\GeoJsonContentHandler;
+use Maps\MediaWiki\ParserHooks\CoordinatesFunction;
+use Maps\MediaWiki\ParserHooks\DisplayMapFunction;
+use Maps\MediaWiki\ParserHooks\DistanceFunction;
+use Maps\MediaWiki\ParserHooks\FindDestinationFunction;
+use Maps\MediaWiki\ParserHooks\GeocodeFunction;
+use Maps\MediaWiki\ParserHooks\GeoDistanceFunction;
+use Maps\MediaWiki\ParserHooks\MapsDocFunction;
+use Maps\Presentation\WikitextParsers\CircleParser;
+use Maps\Presentation\WikitextParsers\DistanceParser;
+use Maps\Presentation\WikitextParsers\ImageOverlayParser;
+use Maps\Presentation\WikitextParsers\LineParser;
+use Maps\Presentation\WikitextParsers\LocationParser;
+use Maps\Presentation\WikitextParsers\PolygonParser;
+use Maps\Presentation\WikitextParsers\RectangleParser;
+use Maps\Presentation\WikitextParsers\WmsOverlayParser;
+use Parser;
+use PPFrame;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsSetup {
+
+ private $mwGlobals;
+
+ public function __construct( array &$mwGlobals ) {
+ $this->mwGlobals = $mwGlobals;
+ }
+
+ public function setup() {
+ $this->defaultSettings();
+ $this->registerAllTheThings();
+
+ if ( !$this->mwGlobals['egMapsDisableSmwIntegration'] && defined( 'SMW_VERSION' ) ) {
+ SemanticMaps::newFromMediaWikiGlobals( $this->mwGlobals )->initExtension();
+ }
+ }
+
+ private function registerAllTheThings() {
+ $this->registerWebResources();
+ $this->registerParserHooks();
+ $this->registerMappingServices();
+ $this->registerPermissions();
+ $this->registerParameterTypes();
+ $this->registerHooks();
+
+ $this->mwGlobals['wgContentHandlers'][GeoJsonContent::CONTENT_MODEL_ID] = GeoJsonContentHandler::class;
+ }
+
+ private function defaultSettings() {
+ if ( $this->mwGlobals['egMapsGMaps3Language'] === '' ) {
+ $this->mwGlobals['egMapsGMaps3Language'] = $this->mwGlobals['wgLang'];
+ }
+
+ if ( in_array( 'googlemaps3', $this->mwGlobals['egMapsAvailableServices'] ) ) {
+ $this->mwGlobals['wgSpecialPages']['MapEditor'] = 'Maps\MediaWiki\Specials\SpecialMapEditor';
+ $this->mwGlobals['wgSpecialPageGroups']['MapEditor'] = 'maps';
+ }
+
+ if ( $this->mwGlobals['egMapsGMaps3ApiKey'] === '' && array_key_exists(
+ 'egGoogleJsApiKey',
+ $this->mwGlobals
+ ) ) {
+ $this->mwGlobals['egMapsGMaps3ApiKey'] = $this->mwGlobals['egGoogleJsApiKey'];
+ }
+ }
+
+ private function registerWebResources() {
+ $this->mwGlobals['wgResourceModules'] = array_merge(
+ $this->mwGlobals['wgResourceModules'],
+ include __DIR__ . '/../Maps.resources.php'
+ );
+ }
+
+ private function registerParserHooks() {
+ if ( $this->mwGlobals['egMapsEnableCoordinateFunction'] ) {
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ return ( new CoordinatesFunction() )->init( $parser );
+ };
+ }
+
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ foreach ( [ 'display_map', 'display_point', 'display_points', 'display_line' ] as $hookName ) {
+ $parser->setFunctionHook(
+ $hookName,
+ function ( Parser $parser, PPFrame $frame, array $arguments ) {
+ $mapHtml = MapsFactory::newDefault()->getDisplayMapFunction()->getMapHtmlForKeyValueStrings(
+ $parser,
+ array_map(
+ function ( $argument ) use ( $frame ) {
+ return $frame->expand( $argument );
+ },
+ $arguments
+ )
+ );
+
+ return [
+ $mapHtml,
+ 'noparse' => true,
+ 'isHTML' => true,
+ ];
+ },
+ Parser::SFH_OBJECT_ARGS
+ );
+
+ $parser->setHook(
+ $hookName,
+ function ( $text, array $arguments, Parser $parser ) {
+ if ( $text !== null ) {
+ $defaultParameters = DisplayMapFunction::getHookDefinition( "\n" )->getDefaultParameters();
+ $defaultParam = array_shift( $defaultParameters );
+
+ // If there is a first default parameter, set the tag contents as its value.
+ if ( $defaultParam !== null ) {
+ $arguments[$defaultParam] = $text;
+ }
+ }
+
+ return MapsFactory::newDefault()->getDisplayMapFunction()->getMapHtmlForParameterList( $parser, $arguments );
+ }
+ );
+ }
+ };
+
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ return ( new DistanceFunction() )->init( $parser );
+ };
+
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ return ( new FindDestinationFunction() )->init( $parser );
+ };
+
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ return ( new GeocodeFunction() )->init( $parser );
+ };
+
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ return ( new GeoDistanceFunction() )->init( $parser );
+ };
+
+ $this->mwGlobals['wgHooks']['ParserFirstCallInit'][] = function ( Parser &$parser ) {
+ return ( new MapsDocFunction() )->init( $parser );
+ };
+ }
+
+ private function registerMappingServices() {
+ $localBasePath = __DIR__ . '/../resources';
+ $remoteExtPath = 'Maps/resources';
+
+ $this->registerGoogleMapsModules( $localBasePath, $remoteExtPath );
+
+ $this->registerLeafletModules( $localBasePath, $remoteExtPath );
+ }
+
+ private function registerGoogleMapsModules( string $localBasePath, string $remoteExtPath ) {
+ global $wgResourceModules;
+
+ $localBasePath = $localBasePath . '/GoogleMaps';
+ $remoteExtPath = $remoteExtPath . '/GoogleMaps';
+
+ $wgResourceModules['ext.maps.googlemaps3'] = [
+ 'dependencies' => [ 'ext.maps.common' ],
+ 'localBasePath' => $localBasePath,
+ 'remoteExtPath' => $remoteExtPath,
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'jquery.googlemap.js',
+ 'ext.maps.googlemaps3.js'
+ ],
+ 'messages' => [
+ 'maps-googlemaps3-incompatbrowser',
+ 'maps-copycoords-prompt',
+ 'maps-searchmarkers-text',
+ 'maps-fullscreen-button',
+ 'maps-fullscreen-button-tooltip',
+ ]
+ ];
+
+ $wgResourceModules['ext.maps.gm3.markercluster'] = [
+ 'localBasePath' => $localBasePath . '/gm3-util-library',
+ 'remoteExtPath' => $remoteExtPath . '/gm3-util-library',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'markerclusterer.js',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.gm3.markerwithlabel'] = [
+ 'localBasePath' => $localBasePath . '/gm3-util-library',
+ 'remoteExtPath' => $remoteExtPath . '/gm3-util-library',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'markerwithlabel.js',
+ ],
+ 'styles' => [
+ 'markerwithlabel.css',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.gm3.geoxml'] = [
+ 'localBasePath' => $localBasePath . '/geoxml3',
+ 'remoteExtPath' => $remoteExtPath . '/geoxml3',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'geoxml3.js',
+ 'ZipFile.complete.js', //kmz handling
+ 'ProjectedOverlay.js', //Overlay handling
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.gm3.earth'] = [
+ 'localBasePath' => $localBasePath . '/gm3-util-library',
+ 'remoteExtPath' => $remoteExtPath . '/gm3-util-library',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'googleearth-compiled.js',
+ ],
+ ];
+
+ $wgResourceModules['ext.sm.googlemaps3ajax'] = [
+ 'localBasePath' => $localBasePath,
+ 'remoteExtPath' => $remoteExtPath,
+ 'group' => 'ext.maps',
+ 'dependencies' => [
+ 'ext.maps.googlemaps3',
+ 'ext.sm.common'
+ ],
+ 'scripts' => [
+ 'ext.sm.googlemaps3ajax.js'
+ ]
+ ];
+ }
+
+ private function registerLeafletModules( string $localBasePath, string $remoteExtPath ) {
+ global $wgResourceModules;
+
+ $localBasePath = $localBasePath . '/leaflet';
+ $remoteExtPath = $remoteExtPath . '/leaflet';
+
+ $wgResourceModules['ext.maps.leaflet.base'] = [
+ 'localBasePath' => $localBasePath . '/leaflet',
+ 'remoteExtPath' => $remoteExtPath . '/leaflet',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'leaflet.js',
+ ],
+ 'styles' => [
+ 'leaflet.css',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.leaflet'] = [
+ 'dependencies' => [
+ 'ext.maps.common',
+ 'ext.maps.services',
+ 'ext.maps.leaflet.base'
+ ],
+ 'localBasePath' => $localBasePath,
+ 'remoteExtPath' => $remoteExtPath,
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'jquery.leaflet.js',
+ 'ext.maps.leaflet.js',
+ ],
+ 'messages' => [
+ 'maps-markers',
+ 'maps-copycoords-prompt',
+ 'maps-searchmarkers-text',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.leaflet.fullscreen'] = [
+ 'dependencies' => [ 'ext.maps.leaflet' ],
+ 'localBasePath' => $localBasePath . '/leaflet.fullscreen',
+ 'remoteExtPath' => $remoteExtPath . '/leaflet.fullscreen',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'Control.FullScreen.js',
+ ],
+ 'styles' => [
+ 'Control.FullScreen.css',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.leaflet.markercluster'] = [
+ 'dependencies' => [ 'ext.maps.leaflet' ],
+ 'localBasePath' => $localBasePath . '/leaflet.markercluster',
+ 'remoteExtPath' => $remoteExtPath . '/leaflet.markercluster',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'leaflet.markercluster.js',
+ ],
+ 'styles' => [
+ 'MarkerCluster.css',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.leaflet.providers'] = [
+ 'dependencies' => [ 'ext.maps.leaflet' ],
+ 'localBasePath' => $localBasePath . '/leaflet-providers',
+ 'remoteExtPath' => $remoteExtPath . '/leaflet-providers',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'leaflet-providers.js',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.leaflet.editable'] = [
+ 'dependencies' => [ 'ext.maps.leaflet.base' ],
+ 'localBasePath' => $localBasePath . '/leaflet.editable',
+ 'remoteExtPath' => $remoteExtPath . '/leaflet.editable',
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'Leaflet.Editable.js',
+ ],
+ ];
+
+ $wgResourceModules['ext.maps.leaflet.editor'] = [
+ 'dependencies' => [
+ 'ext.maps.leaflet.base',
+ //'ext.maps.leaflet.editable'
+ ],
+ 'localBasePath' => $localBasePath,
+ 'remoteExtPath' => $remoteExtPath,
+ 'group' => 'ext.maps',
+ 'targets' => [
+ 'mobile',
+ 'desktop'
+ ],
+ 'scripts' => [
+ 'leaflet.editor.js',
+ ],
+ ];
+
+ $wgResourceModules['ext.sm.leafletajax'] = [
+ 'localBasePath' => $localBasePath,
+ 'remoteExtPath' => $remoteExtPath,
+ 'group' => 'ext.maps',
+ 'dependencies' => [
+ 'ext.maps.leaflet',
+ 'ext.sm.common'
+ ],
+ 'scripts' => [
+ 'ext.sm.leafletajax.js'
+ ]
+ ];
+ }
+
+ private function registerPermissions() {
+ $this->mwGlobals['wgAvailableRights'][] = 'geocode';
+
+ // Users that can geocode. By default the same as those that can edit.
+ foreach ( $this->mwGlobals['wgGroupPermissions'] as $group => $rights ) {
+ if ( array_key_exists( 'edit', $rights ) ) {
+ $this->mwGlobals['wgGroupPermissions'][$group]['geocode'] = $this->mwGlobals['wgGroupPermissions'][$group]['edit'];
+ }
+ }
+ }
+
+ private function registerParameterTypes() {
+ $this->mwGlobals['wgParamDefinitions']['coordinate'] = [
+ 'string-parser' => LatLongParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['mapslocation'] = [
+ 'string-parser' => LocationParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['mapsline'] = [
+ 'string-parser' => LineParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['mapscircle'] = [
+ 'string-parser' => CircleParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['mapsrectangle'] = [
+ 'string-parser' => RectangleParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['mapspolygon'] = [
+ 'string-parser' => PolygonParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['distance'] = [
+ 'string-parser' => DistanceParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['wmsoverlay'] = [
+ 'string-parser' => WmsOverlayParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['mapsimageoverlay'] = [
+ 'string-parser' => ImageOverlayParser::class,
+ ];
+
+ $this->mwGlobals['wgParamDefinitions']['jsonfile'] = [
+ 'string-parser' => JsonFileParser::class,
+ ];
+ }
+
+ private function registerHooks() {
+ $this->mwGlobals['wgHooks']['AdminLinks'][] = 'Maps\MediaWiki\MapsHooks::addToAdminLinks';
+ $this->mwGlobals['wgHooks']['MakeGlobalVariablesScript'][] = 'Maps\MediaWiki\MapsHooks::onMakeGlobalVariablesScript';
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContent.php b/www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContent.php
new file mode 100644
index 00000000..72a89b04
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContent.php
@@ -0,0 +1,49 @@
+<?php
+
+namespace Maps\MediaWiki\Content;
+
+use Html;
+use ParserOptions;
+use ParserOutput;
+use Title;
+
+class GeoJsonContent extends \JsonContent {
+
+ public const CONTENT_MODEL_ID = 'GeoJSON';
+
+ public function __construct( string $text, string $modelId = self::CONTENT_MODEL_ID ) {
+ parent::__construct( $text, $modelId );
+ }
+
+ protected function fillParserOutput( Title $title, $revId, ParserOptions $options,
+ $generateHtml, ParserOutput &$output ) {
+
+ if ( $generateHtml && $this->isValid() ) {
+ $output->setText( $this->getMapHtml( $this->beautifyJSON() ) );
+ $output->addModules( 'ext.maps.leaflet.editor' );
+ } else {
+ $output->setText( '' );
+ }
+ }
+
+ private function getMapHtml( string $jsonString ): string {
+ return
+ Html::element(
+ 'div',
+ [
+ 'id' => 'GeoJsonMap',
+ 'class' => 'GeoJsonMap',
+ ]
+ )
+ . '<style>'
+ . '.GeoJsonMap {width: "100%"; height: 600px; display: "inline-block"}'
+ . '</style>'
+ .
+ Html::element(
+ 'script',
+ [],
+ 'var GeoJson =' . $jsonString . ';'
+ );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContentHandler.php b/www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContentHandler.php
new file mode 100644
index 00000000..b192a9c3
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/Content/GeoJsonContentHandler.php
@@ -0,0 +1,15 @@
+<?php
+
+namespace Maps\MediaWiki\Content;
+
+class GeoJsonContentHandler extends \JsonContentHandler {
+
+ public function __construct( $modelId = GeoJsonContent::CONTENT_MODEL_ID ) {
+ parent::__construct( $modelId );
+ }
+
+ protected function getContentClass() {
+ return GeoJsonContent::class;
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/MapsHooks.php b/www/wiki/extensions/Maps/src/MediaWiki/MapsHooks.php
new file mode 100644
index 00000000..e2a8ad95
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/MapsHooks.php
@@ -0,0 +1,68 @@
+<?php
+
+namespace Maps\MediaWiki;
+
+use AlItem;
+use ALTree;
+
+/**
+ * Static class for hooks handled by the Maps extension.
+ *
+ * @since 0.7
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+final class MapsHooks {
+
+ /**
+ * Adds a link to Admin Links page.
+ *
+ * @since 0.7
+ *
+ * @param ALTree $admin_links_tree
+ *
+ * @return boolean
+ */
+ public static function addToAdminLinks( ALTree &$admin_links_tree ) {
+ $displaying_data_section = $admin_links_tree->getSection(
+ wfMessage( 'smw_adminlinks_displayingdata' )->text()
+ );
+
+ // Escape if SMW hasn't added links.
+ if ( is_null( $displaying_data_section ) ) {
+ return true;
+ }
+
+ $smw_docu_row = $displaying_data_section->getRow( 'smw' );
+
+ $maps_docu_label = wfMessage( 'adminlinks_documentation', 'Maps' )->text();
+ $smw_docu_row->addItem(
+ AlItem::newFromExternalLink( 'https://www.semantic-mediawiki.org/wiki/Extension:Maps', $maps_docu_label )
+ );
+
+ return true;
+ }
+
+ /**
+ * Adds global JavaScript variables.
+ *
+ * @since 1.0
+ * @see http://www.mediawiki.org/wiki/Manual:Hooks/MakeGlobalVariablesScript
+ *
+ * @param array &$vars Variables to be added into the output
+ *
+ * @return boolean true in all cases
+ */
+ public static function onMakeGlobalVariablesScript( array &$vars ) {
+ $vars['egMapsScriptPath'] = $GLOBALS['wgScriptPath'] . '/extensions/Maps/'; // TODO: wgExtensionDirectory?
+ $vars['egMapsDebugJS'] = $GLOBALS['egMapsDebugJS'];
+ $vars['egMapsAvailableServices'] = $GLOBALS['egMapsAvailableServices'];
+ $vars['egMapsLeafletLayersApiKeys'] = $GLOBALS['egMapsLeafletLayersApiKeys'];
+
+ $vars += $GLOBALS['egMapsGlobalJSVars'];
+
+ return true;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/CoordinatesFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/CoordinatesFunction.php
new file mode 100644
index 00000000..94051571
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/CoordinatesFunction.php
@@ -0,0 +1,102 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use Maps\MapsFactory;
+use ParserHook;
+
+/**
+ * Class for the 'coordinates' parser hooks,
+ * which can transform the notation of a set of coordinates.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CoordinatesFunction extends ParserHook {
+
+ /**
+ * Renders and returns the output.
+ *
+ * @see ParserHook::render
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ public function render( array $parameters ) {
+ return MapsFactory::globalInstance()->getCoordinateFormatter()->format(
+ $parameters['location'],
+ $parameters['format'],
+ $parameters['directional']
+ );
+ }
+
+ /**
+ * @see ParserHook::getMessage()
+ */
+ public function getMessage() {
+ return 'maps-coordinates-description';
+ }
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @see ParserHook::getName
+ *
+ * @return string
+ */
+ protected function getName() {
+ return 'coordinates';
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @see ParserHook::getParameterInfo
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ global $egMapsAvailableCoordNotations;
+ global $egMapsCoordinateNotation;
+ global $egMapsCoordinateDirectional;
+
+ $params = [];
+
+ $params['location'] = [
+ 'type' => 'coordinate',
+ ];
+
+ $params['format'] = [
+ 'default' => $egMapsCoordinateNotation,
+ 'values' => $egMapsAvailableCoordNotations,
+ 'aliases' => 'notation',
+ 'tolower' => true,
+ ];
+
+ $params['directional'] = [
+ 'type' => 'boolean',
+ 'default' => $egMapsCoordinateDirectional,
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-coordinates-par-location, maps-coordinates-par-format, maps-coordinates-par-directional
+ foreach ( $params as $name => &$param ) {
+ $param['message'] = 'maps-coordinates-par-' . $name;
+ }
+
+ return $params;
+ }
+
+ /**
+ * Returns the list of default parameters.
+ *
+ * @see ParserHook::getDefaultParameters
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return [ 'location', 'format', 'directional' ];
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapFunction.php
new file mode 100644
index 00000000..bad0d842
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapFunction.php
@@ -0,0 +1,171 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use Maps;
+use Maps\MapsFunctions;
+use Maps\MappingServices;
+use Maps\Presentation\ParameterExtractor;
+use MWException;
+use ParamProcessor;
+use ParamProcessor\ProcessedParam;
+use Parser;
+
+/**
+ * Class for the 'display_map' parser hooks.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class DisplayMapFunction {
+
+ private $services;
+
+ private $renderer;
+
+ public function __construct( MappingServices $services ) {
+ $this->services = $services;
+
+ $this->renderer = new DisplayMapRenderer();
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string[] $parameters Values of the array can be named parameters ("key=value") or unnamed.
+ * They are not normalized, so can be "key = value "
+ *
+ * @return string
+ * @throws MWException
+ */
+ public function getMapHtmlForKeyValueStrings( Parser $parser, array $parameters ): string {
+ $processor = new \ParamProcessor\Processor( new \ParamProcessor\Options() );
+
+ $service = $this->services->getServiceOrDefault(
+ $this->extractServiceName(
+ Maps\Presentation\ParameterExtractor::extractFromKeyValueStrings( $parameters )
+ )
+ );
+
+ $this->renderer->service = $service;
+
+ $processor->setFunctionParams(
+ $parameters,
+ array_merge(
+ self::getHookDefinition( ';' )->getParameters(),
+ $service->getParameterInfo()
+ ),
+ self::getHookDefinition( ';' )->getDefaultParameters()
+ );
+
+ return $this->getMapHtmlFromProcessor( $parser, $processor );
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string[] $parameters Key value list of parameters. Unnamed parameters have numeric keys.
+ * Both keys and values have not been normalized.
+ *
+ * @return string
+ * @throws MWException
+ */
+ public function getMapHtmlForParameterList( Parser $parser, array $parameters ) {
+ $processor = new \ParamProcessor\Processor( new \ParamProcessor\Options() );
+
+ $service = $this->services->getServiceOrDefault( $this->extractServiceName( $parameters ) );
+
+ $this->renderer->service = $service;
+
+ $processor->setParameters(
+ $parameters,
+ array_merge(
+ self::getHookDefinition( "\n" )->getParameters(),
+ $service->getParameterInfo()
+ )
+ );
+
+ return $this->getMapHtmlFromProcessor( $parser, $processor );
+ }
+
+ private function getMapHtmlFromProcessor( Parser $parser, ParamProcessor\Processor $processor ) {
+ $params = $processor->processParameters()->getParameters();
+
+ $this->defaultMapZoom( $params );
+
+ $this->trackMap( $parser );
+
+ return $this->renderer->renderMap(
+ $this->processedParametersToKeyValueArray( $params ),
+ $parser
+ );
+ }
+
+ private function extractServiceName( array $parameters ): string {
+ $service = ( new ParameterExtractor() )->extract(
+ [ 'mappingservice', 'service' ],
+ $parameters
+ );
+
+ return $service ?? '';
+ }
+
+ private function processedParametersToKeyValueArray( array $params ): array {
+ $parameters = [];
+
+ foreach ( $params as $parameter ) {
+ $parameters[$parameter->getName()] = $parameter->getValue();
+ }
+
+ return $parameters;
+ }
+
+ public static function getHookDefinition( string $locationDelimiter ): \ParserHooks\HookDefinition {
+ return new \ParserHooks\HookDefinition(
+ [ 'display_map', 'display_point', 'display_points', 'display_line' ],
+ self::getParameterDefinitions( $locationDelimiter ),
+ [ 'coordinates' ]
+ );
+ }
+
+ private static function getParameterDefinitions( $locationDelimiter ): array {
+ $params = MapsFunctions::getCommonParameters();
+
+ $params['coordinates'] = [
+ 'type' => 'string',
+ 'aliases' => [ 'coords', 'location', 'address', 'addresses', 'locations', 'points' ],
+ 'default' => [],
+ 'islist' => true,
+ 'delimiter' => $locationDelimiter,
+ 'message' => 'maps-displaymap-par-coordinates',
+ ];
+
+ return $params;
+ }
+
+ /**
+ * @param ProcessedParam[] $parameters
+ */
+ private function defaultMapZoom( array &$parameters ) {
+ if ( array_key_exists( 'zoom', $parameters ) && $parameters['zoom']->wasSetToDefault() && count(
+ $parameters['coordinates']->getValue()
+ ) > 1 ) {
+ $parameters['zoom'] = $this->getParameterWithValue( $parameters['zoom'], false );
+ }
+ }
+
+ private function getParameterWithValue( ProcessedParam $param, $value ) {
+ return new ProcessedParam(
+ $param->getName(),
+ $value,
+ $param->wasSetToDefault(),
+ $param->getOriginalName(),
+ $param->getOriginalValue()
+ );
+ }
+
+ private function trackMap( Parser $parser ) {
+ if ( $GLOBALS['egMapsEnableCategory'] ) {
+ $parser->addTrackingCategory( 'maps-tracking-category' );
+ }
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapRenderer.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapRenderer.php
new file mode 100644
index 00000000..25a80683
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DisplayMapRenderer.php
@@ -0,0 +1,205 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use FormatJson;
+use Html;
+use Maps\DataAccess\MediaWikiFileUrlFinder;
+use Maps\Elements\Location;
+use Maps\MappingService;
+use Maps\Presentation\ElementJsonSerializer;
+use Maps\Presentation\WikitextParser;
+use Maps\Presentation\WikitextParsers\LocationParser;
+use Parser;
+
+/**
+ * Class handling the #display_map rendering.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Kim Eik
+ */
+class DisplayMapRenderer {
+
+ public $service;
+
+ /**
+ * @var LocationParser
+ */
+ private $locationParser;
+
+ /**
+ * @var MediaWikiFileUrlFinder
+ */
+ private $fileUrlFinder;
+
+ /**
+ * @var WikitextParser
+ */
+ private $wikitextParser;
+ /**
+ * @var ElementJsonSerializer
+ */
+ private $elementSerializer;
+
+ public function __construct( MappingService $service = null ) {
+ $this->service = $service;
+ }
+
+ /**
+ * Handles the request from the parser hook by doing the work that's common for all
+ * mapping services, calling the specific methods and finally returning the resulting output.
+ *
+ * @param array $params
+ * @param Parser $parser
+ *
+ * @return string
+ */
+ public final function renderMap( array $params, Parser $parser ) {
+ $factory = \Maps\MapsFactory::newDefault();
+
+ $this->locationParser = $factory->newLocationParser();
+ $this->fileUrlFinder = $factory->getFileUrlFinder();
+
+ $this->wikitextParser = new WikitextParser( clone $parser );
+ $this->elementSerializer = new ElementJsonSerializer( $this->wikitextParser );
+
+ $this->handleMarkerData( $params );
+
+ $output = $this->getMapHTML(
+ $params,
+ $this->service->newMapId()
+ );
+
+ $dependencies = $this->service->getDependencyHtml( $params );
+
+ // Only add a head item when there are dependencies.
+ if ( $dependencies ) {
+ $parser->getOutput()->addHeadItem( $dependencies );
+ }
+
+ $parser->getOutput()->addModules( $this->service->getResourceModules() );
+
+ return $output;
+ }
+
+ /**
+ * Converts the data in the coordinates parameter to JSON-ready objects.
+ * These get stored in the locations parameter, and the coordinates on gets deleted.
+ */
+ private function handleMarkerData( array &$params ) {
+ $params['centre'] = $this->getCenter( $params['centre'] );
+
+ if ( is_object( $params['wmsoverlay'] ) ) {
+ $params['wmsoverlay'] = $params['wmsoverlay']->getJSONObject();
+ }
+
+ $params['locations'] = $this->getLocationJson( $params );
+
+ unset( $params['coordinates'] );
+
+ $this->handleShapeData( $params );
+ }
+
+ private function getCenter( $coordinatesOrAddress ) {
+ if ( $coordinatesOrAddress === false ) {
+ return false;
+ }
+
+ try {
+ // FIXME: a Location makes no sense here, since the non-coordinate data is not used
+ $location = $this->locationParser->parse( $coordinatesOrAddress );
+ }
+ catch ( \Exception $ex ) {
+ // TODO: somehow report this to the user
+ return false;
+ }
+
+ return $location->getJSONObject();
+ }
+
+ private function getLocationJson( array $params ) {
+ $iconUrl = $this->fileUrlFinder->getUrlForFileName( $params['icon'] );
+ $visitedIconUrl = $this->fileUrlFinder->getUrlForFileName( $params['visitedicon'] );
+
+ $locationJsonObjects = [];
+
+ foreach ( $params['coordinates'] as $coordinatesOrAddress ) {
+ try {
+ $location = $this->locationParser->parse( $coordinatesOrAddress );
+ }
+ catch ( \Exception $ex ) {
+ // TODO: somehow report this to the user
+ continue;
+ }
+
+ $locationJsonObjects[] = $this->getLocationJsonObject(
+ $location,
+ $params,
+ $iconUrl,
+ $visitedIconUrl
+ );
+ }
+
+ return $locationJsonObjects;
+ }
+
+ private function getLocationJsonObject( Location $location, array $params, $iconUrl, $visitedIconUrl ) {
+ $jsonObj = $location->getJSONObject( $params['title'], $params['label'], $iconUrl, '', '', $visitedIconUrl );
+
+ $this->elementSerializer->titleAndText( $jsonObj );
+
+ if ( isset( $jsonObj['inlineLabel'] ) ) {
+ $jsonObj['inlineLabel'] = strip_tags(
+ $this->wikitextParser->wikitextToHtml( $jsonObj['inlineLabel'] ),
+ '<a><img>'
+ );
+ }
+
+ return $jsonObj;
+ }
+
+ private function handleShapeData( array &$params ) {
+ $textContainers = [
+ &$params['lines'],
+ &$params['polygons'],
+ &$params['circles'],
+ &$params['rectangles'],
+ &$params['imageoverlays'], // FIXME: this is Google Maps specific!!
+ ];
+
+ foreach ( $textContainers as &$textContainer ) {
+ if ( is_array( $textContainer ) ) {
+ foreach ( $textContainer as &$obj ) {
+ $obj = $this->elementSerializer->elementToJson( $obj );
+ }
+ }
+ }
+ }
+
+ /**
+ * Returns the HTML to display the map.
+ *
+ * @param array $params
+ * @param string $mapName
+ *
+ * @return string
+ */
+ protected function getMapHTML( array $params, $mapName ) {
+ return Html::rawElement(
+ 'div',
+ [
+ 'id' => $mapName,
+ 'style' => "width: {$params['width']}; height: {$params['height']}; background-color: #cccccc; overflow: hidden;",
+ 'class' => 'maps-map maps-' . $this->service->getName()
+ ],
+ wfMessage( 'maps-loading-map' )->inContentLanguage()->escaped() .
+ Html::element(
+ 'div',
+ [ 'style' => 'display:none', 'class' => 'mapdata' ],
+ FormatJson::encode( $params )
+ )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DistanceFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DistanceFunction.php
new file mode 100644
index 00000000..84b11c2b
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/DistanceFunction.php
@@ -0,0 +1,100 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use Maps\Presentation\MapsDistanceParser;
+use ParserHook;
+
+/**
+ * Class for the 'distance' parser hooks,
+ * which can transform the notation of a distance.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class DistanceFunction extends ParserHook {
+
+ /**
+ * Renders and returns the output.
+ *
+ * @see ParserHook::render
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ public function render( array $parameters ) {
+ return MapsDistanceParser::formatDistance(
+ $parameters['distance'],
+ $parameters['unit'],
+ $parameters['decimals']
+ );
+ }
+
+ /**
+ * @see ParserHook::getMessage()
+ */
+ public function getMessage() {
+ return 'maps-distance-description';
+ }
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @see ParserHook::getName
+ *
+ * @return string
+ */
+ protected function getName() {
+ return 'distance';
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @see ParserHook::getParameterInfo
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ global $egMapsDistanceUnit, $egMapsDistanceDecimals;
+
+ $params = [];
+
+ $params['distance'] = [
+ 'type' => 'distance',
+ ];
+
+ $params['unit'] = [
+ 'default' => $egMapsDistanceUnit,
+ 'values' => MapsDistanceParser::getUnits(),
+ ];
+
+ $params['decimals'] = [
+ 'type' => 'integer',
+ 'default' => $egMapsDistanceDecimals,
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-distance-par-distance, maps-distance-par-unit, maps-distance-par-decimals
+ foreach ( $params as $name => &$param ) {
+ $param['message'] = 'maps-distance-par-' . $name;
+ }
+
+ return $params;
+ }
+
+ /**
+ * Returns the list of default parameters.
+ *
+ * @see ParserHook::getDefaultParameters
+ *
+ * @param $type
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return [ 'distance', 'unit', 'decimals' ];
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/FindDestinationFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/FindDestinationFunction.php
new file mode 100644
index 00000000..e7cb319c
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/FindDestinationFunction.php
@@ -0,0 +1,120 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\MapsFactory;
+use Maps\GeoFunctions;
+use ParserHook;
+
+/**
+ * Class for the 'finddestination' parser hooks, which can find a
+ * destination given a starting point, an initial bearing and a distance.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class FindDestinationFunction extends ParserHook {
+
+ /**
+ * Renders and returns the output.
+ *
+ * @see ParserHook::render
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ public function render( array $parameters ) {
+ $destination = GeoFunctions::findDestination(
+ $parameters['location']->getCoordinates(),
+ $parameters['bearing'],
+ $parameters['distance']
+ );
+
+ return MapsFactory::globalInstance()->getCoordinateFormatter()->format(
+ new LatLongValue( $destination['lat'], $destination['lon'] ),
+ $parameters['format'],
+ $parameters['directional']
+ );
+ }
+
+ /**
+ * @see ParserHook::getMessage()
+ */
+ public function getMessage() {
+ return 'maps-finddestination-description';
+ }
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @see ParserHook::getName
+ *
+ * @return string
+ */
+ protected function getName() {
+ return 'finddestination';
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @see ParserHook::getParameterInfo
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ global $egMapsAvailableCoordNotations;
+ global $egMapsCoordinateNotation, $egMapsCoordinateDirectional;
+
+ $params = [];
+
+ $params['location'] = [
+ 'type' => 'mapslocation',
+ ];
+
+ $params['format'] = [
+ 'default' => $egMapsCoordinateNotation,
+ 'values' => $egMapsAvailableCoordNotations,
+ 'aliases' => 'notation',
+ 'tolower' => true,
+ ];
+
+ $params['directional'] = [
+ 'type' => 'boolean',
+ 'default' => $egMapsCoordinateDirectional,
+ ];
+
+ $params['bearing'] = [
+ 'type' => 'float',
+ ];
+
+ $params['distance'] = [
+ 'type' => 'distance',
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-finddestination-par-location, maps-finddestination-par-format,
+ // maps-finddestination-par-directional, maps-finddestination-par-bearing,
+ // maps-finddestination-par-distance, maps-finddestination-par-mappingservice,
+ // maps-finddestination-par-geoservice, maps-finddestination-par-allowcoordinates
+ foreach ( $params as $name => &$param ) {
+ $param['message'] = 'maps-finddestination-par-' . $name;
+ }
+
+ return $params;
+ }
+
+ /**
+ * Returns the list of default parameters.
+ *
+ * @see ParserHook::getDefaultParameters
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return [ 'location', 'bearing', 'distance' ];
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeoDistanceFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeoDistanceFunction.php
new file mode 100644
index 00000000..f7afc393
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeoDistanceFunction.php
@@ -0,0 +1,117 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use Maps\GeoFunctions;
+use Maps\Presentation\MapsDistanceParser;
+use MWException;
+use ParserHook;
+
+/**
+ * Class for the 'geodistance' parser hooks, which can
+ * calculate the geographical distance between two points.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class GeoDistanceFunction extends ParserHook {
+
+ /**
+ * Renders and returns the output.
+ *
+ * @see ParserHook::render
+ *
+ * @param array $parameters
+ *
+ * @return string
+ * @throws MWException
+ */
+ public function render( array $parameters ) {
+ /**
+ * @var \DataValues\Geo\Values\LatLongValue $coordinates1
+ * @var \DataValues\Geo\Values\LatLongValue $coordinates2
+ */
+ $coordinates1 = $parameters['location1']->getCoordinates();
+ $coordinates2 = $parameters['location2']->getCoordinates();
+
+ $distance = GeoFunctions::calculateDistance( $coordinates1, $coordinates2 );
+ $output = MapsDistanceParser::formatDistance( $distance, $parameters['unit'], $parameters['decimals'] );
+
+ return $output;
+ }
+
+ /**
+ * @see ParserHook::getMessage
+ */
+ public function getMessage() {
+ return 'maps-geodistance-description';
+ }
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @see ParserHook::getName
+ *
+ * @return string
+ */
+ protected function getName() {
+ return 'geodistance';
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @see ParserHook::getParameterInfo
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ global $egMapsDistanceUnit, $egMapsDistanceDecimals;
+
+ $params = [];
+
+ $params['unit'] = [
+ 'default' => $egMapsDistanceUnit,
+ 'values' => MapsDistanceParser::getUnits(),
+ ];
+
+ $params['decimals'] = [
+ 'type' => 'integer',
+ 'default' => $egMapsDistanceDecimals,
+ ];
+
+ $params['location1'] = [
+ 'type' => 'mapslocation',
+ 'aliases' => 'from',
+ ];
+
+ $params['location2'] = [
+ 'type' => 'mapslocation',
+ 'aliases' => 'to',
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-geodistance-par-mappingservice, maps-geodistance-par-geoservice,
+ // maps-geodistance-par-unit, maps-geodistance-par-decimals,
+ // maps-geodistance-par-location1, maps-geodistance-par-location2
+ foreach ( $params as $name => &$param ) {
+ $param['message'] = 'maps-geodistance-par-' . $name;
+ }
+
+ return $params;
+ }
+
+ /**
+ * Returns the list of default parameters.
+ *
+ * @see ParserHook::getDefaultParameters
+ *
+ * @param $type
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return [ 'location1', 'location2', 'unit', 'decimals' ];
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeocodeFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeocodeFunction.php
new file mode 100644
index 00000000..5f70ef24
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/GeocodeFunction.php
@@ -0,0 +1,113 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use Jeroen\SimpleGeocoder\Geocoder;
+use Maps\MapsFactory;
+use ParserHook;
+
+/**
+ * Class for the 'geocode' parser hooks, which can turn
+ * human readable locations into sets of coordinates.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class GeocodeFunction extends ParserHook {
+
+ private $geocoder;
+
+ public function __construct( Geocoder $geocoder = null ) {
+ $this->geocoder = $geocoder ?? \Maps\MapsFactory::newDefault()->getGeocoder();
+ parent::__construct();
+ }
+
+ /**
+ * Renders and returns the output.
+ *
+ * @see ParserHook::render
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ public function render( array $parameters ) {
+ $coordinates = $this->geocoder->geocode( $parameters['location'] );
+
+ if ( $coordinates === null ) {
+ return 'Geocoding failed'; // TODO: i18n
+ }
+
+ return MapsFactory::globalInstance()->getCoordinateFormatter()->format(
+ $coordinates,
+ $parameters['format'],
+ $parameters['directional']
+ );
+ }
+
+ /**
+ * @see ParserHook::getMessage()
+ */
+ public function getMessage() {
+ return 'maps-geocode-description';
+ }
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @see ParserHook::getName
+ *
+ * @return string
+ */
+ protected function getName() {
+ return 'geocode';
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @see ParserHook::getParameterInfo
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ global $egMapsAvailableCoordNotations;
+ global $egMapsCoordinateNotation;
+ global $egMapsCoordinateDirectional;
+
+ $params = [];
+
+ $params['location'] = [
+ 'type' => 'string',
+ 'message' => 'maps-geocode-par-location',
+ ];
+
+ $params['format'] = [
+ 'default' => $egMapsCoordinateNotation,
+ 'values' => $egMapsAvailableCoordNotations,
+ 'aliases' => 'notation',
+ 'tolower' => true,
+ 'message' => 'maps-geocode-par-format',
+ ];
+
+ $params['directional'] = [
+ 'type' => 'boolean',
+ 'default' => $egMapsCoordinateDirectional,
+ 'message' => 'maps-geocode-par-directional',
+ ];
+
+ return $params;
+ }
+
+ /**
+ * Returns the list of default parameters.
+ *
+ * @see ParserHook::getDefaultParameters
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return [ 'location' ];
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/MapsDocFunction.php b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/MapsDocFunction.php
new file mode 100644
index 00000000..6a365378
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/ParserHooks/MapsDocFunction.php
@@ -0,0 +1,200 @@
+<?php
+
+namespace Maps\MediaWiki\ParserHooks;
+
+use Maps\MappingServices;
+use Maps\MapsFactory;
+use ParamProcessor\ParamDefinition;
+use ParserHook;
+
+/**
+ * Class for the 'mapsdoc' parser hooks,
+ * which displays documentation for a specified mapping service.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsDocFunction extends ParserHook {
+
+ /**
+ * Field to store the value of the language parameter.
+ *
+ * @var string
+ */
+ protected $language;
+
+ /**
+ * Renders and returns the output.
+ *
+ * @see ParserHook::render
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ public function render( array $parameters ) {
+ $this->language = $parameters['language'];
+
+ $params = $this->getServiceParameters( $parameters['service'] );
+
+ return $this->getParameterTable( $params );
+ }
+
+ private function getServiceParameters( $service ) {
+ return array_merge(
+ [
+ 'zoom' => [
+ 'type' => 'integer',
+ 'message' => 'maps-par-zoom',
+ ]
+ ],
+ MapsFactory::globalInstance()->getMappingServices()->getService( $service )->getParameterInfo()
+ );
+ }
+
+ /**
+ * Returns the wikitext for a table listing the provided parameters.
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ private function getParameterTable( array $parameters ) {
+ $tableRows = [];
+
+ $parameters = ParamDefinition::getCleanDefinitions( $parameters );
+
+ foreach ( $parameters as $parameter ) {
+ $tableRows[] = $this->getDescriptionRow( $parameter );
+ }
+
+ $table = '';
+
+ if ( count( $tableRows ) > 0 ) {
+ $tableRows = array_merge(
+ [
+ '!' . $this->msg( 'validator-describe-header-parameter' ) . "\n" .
+ //'!' . $this->msg( 'validator-describe-header-aliases' ) ."\n" .
+ '!' . $this->msg( 'validator-describe-header-type' ) . "\n" .
+ '!' . $this->msg( 'validator-describe-header-default' ) . "\n" .
+ '!' . $this->msg( 'validator-describe-header-description' )
+ ],
+ $tableRows
+ );
+
+ $table = implode( "\n|-\n", $tableRows );
+
+ $table =
+ '{| class="wikitable sortable"' . "\n" .
+ $table .
+ "\n|}";
+ }
+
+ return $table;
+ }
+
+ /**
+ * Returns the wikitext for a table row describing a single parameter.
+ *
+ * @param ParamDefinition $parameter
+ *
+ * @return string
+ */
+ private function getDescriptionRow( ParamDefinition $parameter ) {
+ $description = $this->msg( $parameter->getMessage() );
+
+ $type = $this->msg( $parameter->getTypeMessage() );
+
+ $default = $parameter->isRequired() ? "''" . $this->msg(
+ 'validator-describe-required'
+ ) . "''" : $parameter->getDefault();
+ if ( is_array( $default ) ) {
+ $default = implode( ', ', $default );
+ } elseif ( is_bool( $default ) ) {
+ $default = $default ? 'yes' : 'no';
+ }
+
+ if ( $default === '' ) {
+ $default = "''" . $this->msg( 'validator-describe-empty' ) . "''";
+ }
+
+ return <<<EOT
+| {$parameter->getName()}
+| {$type}
+| {$default}
+| {$description}
+EOT;
+ }
+
+ /**
+ * Message function that takes into account the language parameter.
+ *
+ * @param string $key
+ * @param ... $args
+ *
+ * @return string
+ */
+ private function msg() {
+ $args = func_get_args();
+ $key = array_shift( $args );
+ return wfMessage( $key, $args )->inLanguage( $this->language )->text();
+ }
+
+ /**
+ * @see ParserHook::getDescription()
+ */
+ public function getMessage() {
+ return 'maps-mapsdoc-description';
+ }
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @see ParserHook::getName
+ *
+ * @return string
+ */
+ protected function getName() {
+ return 'mapsdoc';
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @see ParserHook::getParameterInfo
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ $params = [];
+
+ $params['service'] = [
+ 'values' => $GLOBALS['egMapsAvailableServices'],
+ 'tolower' => true,
+ ];
+
+ $params['language'] = [
+ 'default' => $GLOBALS['wgLanguageCode'],
+ ];
+
+ // Give grep a chance to find the usages:
+ // maps-geocode-par-service, maps-geocode-par-language
+ foreach ( $params as $name => &$param ) {
+ $param['message'] = 'maps-geocode-par-' . $name;
+ }
+
+ return $params;
+ }
+
+ /**
+ * Returns the list of default parameters.
+ *
+ * @see ParserHook::getDefaultParameters
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return [ 'service', 'language' ];
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/SemanticMapsHooks.php b/www/wiki/extensions/Maps/src/MediaWiki/SemanticMapsHooks.php
new file mode 100644
index 00000000..4c929b42
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/SemanticMapsHooks.php
@@ -0,0 +1,115 @@
+<?php
+
+namespace Maps\MediaWiki;
+
+use AlItem;
+use ALTree;
+use Maps\SemanticMW\DataValues\CoordinateValue;
+use Maps\SemanticMW\DataValues\GeoPolygonValue;
+use SMW\DataTypeRegistry;
+use SMWDataItem;
+use SMWPrintRequest;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+final class SemanticMapsHooks {
+
+ /**
+ * Adds a link to Admin Links page.
+ *
+ * @since 0.7
+ *
+ * @param ALTree $admin_links_tree
+ *
+ * @return boolean
+ */
+ public static function addToAdminLinks( ALTree &$admin_links_tree ) {
+ $displaying_data_section = $admin_links_tree->getSection(
+ wfMessage( 'smw_adminlinks_displayingdata' )->text()
+ );
+
+ // Escape if SMW hasn't added links.
+ if ( is_null( $displaying_data_section ) ) {
+ return true;
+ }
+
+ $smw_docu_row = $displaying_data_section->getRow( 'smw' );
+
+ $sm_docu_label = wfMessage( 'adminlinks_documentation', 'Semantic Maps' )->text();
+ $smw_docu_row->addItem(
+ AlItem::newFromExternalLink( 'https://www.semantic-mediawiki.org/wiki/Semantic_Maps', $sm_docu_label )
+ );
+
+ return true;
+ }
+
+ /**
+ * Adds support for the geographical coordinates and shapes data type to Semantic MediaWiki.
+ *
+ * @since 2.0
+ *
+ * @return boolean
+ */
+ public static function initGeoDataTypes() {
+ DataTypeRegistry::getInstance()->registerDatatype(
+ '_geo',
+ CoordinateValue::class,
+ SMWDataItem::TYPE_GEO
+ );
+
+ return true;
+ }
+
+ /**
+ * Set the default format to 'map' when the requested properties are
+ * of type geographic coordinates.
+ *
+ * TODO: have a setting to turn this off and have it off by default for #show
+ *
+ * @since 1.0
+ *
+ * @param $format Mixed: The format (string), or false when not set yet
+ * @param SMWPrintRequest[] $printRequests The print requests made
+ *
+ * @return boolean
+ */
+ public static function addGeoCoordsDefaultFormat( &$format, array $printRequests ) {
+ // Only set the format when not set yet. This allows other extensions to override the Maps behavior.
+ if ( $format === false ) {
+ // Only apply when there is more then one print request.
+ // This way requests comming from #show are ignored.
+ if ( count( $printRequests ) > 1 ) {
+ $allValid = true;
+ $hasCoords = false;
+
+ // Loop through the print requests to determine their types.
+ foreach ( $printRequests as $printRequest ) {
+ // Skip the first request, as it's the object.
+ if ( $printRequest->getMode() == SMWPrintRequest::PRINT_THIS ) {
+ continue;
+ }
+
+ $typeId = $printRequest->getTypeID();
+
+ if ( $typeId == '_geo' ) {
+ $hasCoords = true;
+ } else {
+ $allValid = false;
+ break;
+ }
+ }
+
+ // If they are all coordinates, set the result format to 'map'.
+ if ( $allValid && $hasCoords ) {
+ $format = 'map';
+ }
+ }
+
+ }
+
+ return true;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/Specials/MapEditorHTML.php b/www/wiki/extensions/Maps/src/MediaWiki/Specials/MapEditorHTML.php
new file mode 100644
index 00000000..60409041
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/Specials/MapEditorHTML.php
@@ -0,0 +1,221 @@
+<?php
+
+namespace Maps\MediaWiki\Specials;
+
+use ContextSource;
+use Html;
+
+/**
+ * Class to Handle HTML generation for Special:MapEditor
+ *
+ * @since 2.1
+ *
+ * @licence GNU GPL v2+
+ * @author Nischayn22
+ */
+class MapEditorHtml extends ContextSource {
+
+ /**
+ * Array holding the additional attributes for the canvas div.
+ *
+ * @var array()
+ * @since 2.1
+ */
+ protected $attribs;
+
+ public function __construct( $attribs = [] ) {
+ $this->attribs = $attribs;
+ }
+
+ /**
+ * Returns the HTML for the MapEditor.
+ *
+ * @return string
+ * @since 2.1
+ */
+ public function getEditorHTML() {
+
+ $output = <<<EOT
+ {$this->getCanvasDiv()}<div style="display: none;">
+ <div id="code-output-container" title="%1\$s">
+ <textarea id="code-output" rows="15" readonly></textarea>
+ </div>
+ <div id="code-input-container" title="%2\$s" >
+ <p>%3\$s</p>
+ <textarea id="code-input" rows="15"></textarea>
+ </div>
+ <div id="marker-form" class="mapeditor-dialog" title="%4\$s">
+ <div class="link-title-switcher">
+ <input type="radio" name="switch" value="text" /> %5\$s
+ <input type="radio" name="switch" value="link" /> %6\$s
+ </div>
+ <form class="mapeditor-dialog-form">
+ <fieldset>
+ <label for="m-title">%7\$s</label>
+ <input type="text" name="title" id="m-title" class="text ui-widget-content ui-corner-all"/>
+ <label for="m-text">%8\$s</label>
+ <input type="text" name="text" id="m-text" class="text ui-widget-content ui-corner-all"/>
+ <label for="m-link">%9\$s</label>
+ <input type="text" name="link" id="m-link" class="text ui-widget-content ui-corner-all"/>
+ <label for="m-icon">%10\$s</label>
+ <input type="text" name="icon" id="m-icon" class="text ui-widget-content ui-corner-all"/>
+ <label for="m-group">%11\$s</label>
+ <input type="text" name="group" id="m-group" class="text ui-widget-content ui-corner-all"/>
+ <label for="m-inlinelabel">%12\$s</label>
+ <input type="text" name="inlinelabel" id="m-inlinelabel" class="text ui-widget-content ui-corner-all"/>
+ <label for="m-visitedicon">%23\$s</label>
+ <input type="text" name="visitedicon" id="m-visitedicon" class="text ui-widget-content ui-corner-all"/>
+ </fieldset>
+ </form>
+ </div>
+
+ <div id="strokable-form" class="mapeditor-dialog" title="%4\$s">
+ <div class="link-title-switcher">
+ <input type="radio" name="switch" value="text" /> %5\$s
+ <input type="radio" name="switch" value="link" /> %6\$s
+ </div>
+ <form class="mapeditor-dialog-form">
+ <fieldset>
+ <label for="s-title">%7\$s</label>
+ <input type="text" name="title" id="s-title" class="text ui-widget-content ui-corner-all"/>
+ <label for="s-text">%8\$s</label>
+ <input type="text" name="text" id="s-text" value="" class="text ui-widget-content ui-corner-all"/>
+ <label for="s-link">%9\$s</label>
+ <input type="text" name="link" id="s-link" class="text ui-widget-content ui-corner-all"/>
+ <label for="s-strokecolor">%13\$s</label>
+ <input type="text" name="strokeColor" id="s-strokecolor" class="text ui-widget-content ui-corner-all"/>
+ <label for="s-strokeopacity">%14\$s</label>
+ <input type="hidden" name="strokeOpacity" id="s-strokeopacity" class="text ui-widget-content ui-corner-all"/>
+ <label for="s-strokeweight">%15\$s</label>
+ <input type="text" name="strokeWeight" id="s-strokeweight" class="text ui-widget-content ui-corner-all"/>
+ </fieldset>
+ </form>
+ </div>
+
+ <div id="fillable-form" class="mapeditor-dialog" title="%4\$s">
+ <div class="link-title-switcher">
+ <input type="radio" name="switch" value="text" /> %5\$s
+ <input type="radio" name="switch" value="link" /> %6\$s
+ </div>
+ <form class="mapeditor-dialog-form">
+ <fieldset>
+ <label for="f-title">%7\$s</label>
+ <input type="text" name="title" id="f-title" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-text">%8\$s</label>
+ <input type="text" name="text" id="f-text" value="" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-link">%9\$s</label>
+ <input type="text" name="link" id="f-link" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-strokecolor">%13\$s</label>
+ <input type="text" name="strokeColor" id="f-strokecolor" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-strokeopacity">%14\$s</label>
+ <input type="hidden" name="strokeOpacity" id="f-strokeopacity" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-strokeweight">%15\$s</label>
+ <input type="text" name="strokeWeight" id="f-strokeweight" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-fillcolor">%16\$s</label>
+ <input type="text" name="fillColor" id="f-fillcolor" class="text ui-widget-content ui-corner-all"/>
+ <label for="f-fillopacity">%17\$s</label>
+ <input type="hidden" name="fillOpacity" id="f-fillopacity" class="text ui-widget-content ui-corner-all"/>
+ </fieldset>
+ </form>
+ </div>
+
+ <div id="polygon-form" class="mapeditor-dialog" title="%4\$s">
+ <div class="link-title-switcher">
+ <input type="radio" name="switch" value="text" /> %5\$s
+ <input type="radio" name="switch" value="link" /> %6\$s
+ </div>
+ <form class="mapeditor-dialog-form">
+ <fieldset>
+ <label for="p-title">%7\$s</label>
+ <input type="text" name="title" id="p-title" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-text">%8\$s</label>
+ <input type="text" name="text" id="p-text" value="" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-link">%9\$s</label>
+ <input type="text" name="link" id="p-link" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-strokecolor">%13\$s</label>
+ <input type="text" name="strokeColor" id="p-strokecolor" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-strokeopacity">%14\$s</label>
+ <input type="hidden" name="strokeOpacity" id="p-strokeopacity" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-strokeweight">%15\$s</label>
+ <input type="text" name="strokeWeight" id="p-strokeweight" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-fillcolor">%16\$s</label>
+ <input type="text" name="fillColor" id="p-fillcolor" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-fillopacity">%17\$s</label>
+ <input type="hidden" name="fillOpacity" id="p-fillopacity" class="text ui-widget-content ui-corner-all"/>
+ <label for="p-showonhover">%18\$s</label>
+ <input type="checkbox" name="showOnHover" id="p-showonhover" class="text ui-widget-content ui-corner-all"/>
+ </fieldset>
+ </form>
+ </div>
+ <div id="map-parameter-form" class="mapeditor-dialog" title="%19\$s">
+ <form class="mapeditor-dialog-form">
+ <div>
+ <select name="key">
+ <option value="">%20\$s</option>
+ </select>
+ </div>
+ </form>
+ </div>
+ <div id="imageoverlay-form" title="%22\$s">
+ <div class="link-title-switcher">
+ <input type="radio" name="switch" value="text" /> %5\$s
+ <input type="radio" name="switch" value="link" /> %6\$s
+ </div>
+ <form class="mapeditor-dialog-form">
+ <fieldset>
+ <label for="i-title">%7\$s</label>
+ <input type="text" name="title" id="i-title" class="text ui-widget-content ui-corner-all"/>
+ <label for="i-text">%8\$s</label>
+ <input type="text" name="text" id="i-text" class="text ui-widget-content ui-corner-all"/>
+ <label for="i-link">%9\$s</label>
+ <input type="text" name="link" id="i-link" class="text ui-widget-content ui-corner-all"/>
+ <label for="i-image">%21\$s</label>
+ <input type="text" name="image" id="i-image" class="text ui-widget-content ui-corner-all"/>
+ </fieldset>
+ </form>
+ </div>
+</div>
+EOT;
+
+ $html = sprintf(
+ $output,
+ $this->msg( 'mapeditor-code-title' ),
+ $this->msg( 'mapeditor-import-title' ),
+ $this->msg( 'mapeditor-import-note' ),
+ $this->msg( 'mapeditor-form-title' ),
+ $this->msg( 'mapeditor-link-title-switcher-popup-text' ),
+ $this->msg( 'mapeditor-link-title-switcher-link-text' ),
+ $this->msg( 'mapeditor-form-field-title' ),
+ $this->msg( 'mapeditor-form-field-text' ),
+ $this->msg( 'mapeditor-form-field-link' ),
+ $this->msg( 'mapeditor-form-field-icon' ),
+ $this->msg( 'mapeditor-form-field-group' ),
+ $this->msg( 'mapeditor-form-field-inlinelabel' ),
+ $this->msg( 'mapeditor-form-field-strokecolor' ),
+ $this->msg( 'mapeditor-form-field-strokeopacity' ),
+ $this->msg( 'mapeditor-form-field-strokeweight' ),
+ $this->msg( 'mapeditor-form-field-fillcolor' ),
+ $this->msg( 'mapeditor-form-field-fillopcaity' ),
+ $this->msg( 'mapeditor-form-field-showonhover' ),
+ $this->msg( 'mapeditor-mapparam-title' ),
+ $this->msg( 'mapeditor-mapparam-defoption' ),
+ $this->msg( 'mapeditor-form-field-image' ),
+ $this->msg( 'mapeditor-imageoverlay-title' ),
+ $this->msg( 'mapeditor-form-field-visitedicon' )
+ );
+
+ return $html;
+ }
+
+ /**
+ * @return string
+ * @since 2.1
+ */
+ public function getCanvasDiv() {
+ return Html::element(
+ 'div',
+ $this->attribs
+ );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/MediaWiki/Specials/SpecialMapEditor.php b/www/wiki/extensions/Maps/src/MediaWiki/Specials/SpecialMapEditor.php
new file mode 100644
index 00000000..76b5dad5
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/MediaWiki/Specials/SpecialMapEditor.php
@@ -0,0 +1,69 @@
+<?php
+
+namespace Maps\MediaWiki\Specials;
+
+use Maps\GoogleMapsService;
+use Maps\MediaWiki\Specials\MapEditorHtml;
+use SpecialPage;
+
+/**
+ * Special page with map editor interface using Google Maps.
+ *
+ * @since 2.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class SpecialMapEditor extends SpecialPage {
+
+ /**
+ * @see SpecialPage::__construct
+ *
+ * @since 2.0
+ */
+ public function __construct() {
+ parent::__construct( 'MapEditor' );
+ }
+
+ /**
+ * @see SpecialPage::execute
+ *
+ * @since 2.0
+ *
+ * @param null|string $subPage
+ */
+ public function execute( $subPage ) {
+ $this->setHeaders();
+
+ $outputPage = $this->getOutput();
+
+ $outputPage->addHtml(
+ GoogleMapsService::getApiScript(
+ $this->getLanguage()->getCode(),
+ [ 'libraries' => 'drawing' ]
+ )
+ );
+
+ $outputPage->addModules( 'mapeditor' );
+ $editorHtml = new MapEditorHtml( $this->getAttribs() );
+ $html = $editorHtml->getEditorHtml();
+ $outputPage->addHTML( $html );
+ }
+
+ /**
+ * @since 2.1
+ *
+ * @return array
+ */
+ protected function getAttribs() {
+ return [
+ 'id' => 'map-canvas',
+ 'context' => 'Maps\MediaWiki\Specials\SpecialMapEditor'
+ ];
+ }
+
+ protected function getGroupName() {
+ return 'maps';
+ }
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/CoordinateFormatter.php b/www/wiki/extensions/Maps/src/Presentation/CoordinateFormatter.php
new file mode 100644
index 00000000..6b5d413d
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/CoordinateFormatter.php
@@ -0,0 +1,36 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Presentation;
+
+use DataValues\Geo\Formatters\LatLongFormatter;
+use DataValues\Geo\Values\LatLongValue;
+use ValueFormatters\FormatterOptions;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CoordinateFormatter {
+
+ private const PRECISION_MAP = [
+ 'dms' => 1 / 360000,
+ 'dm' => 1 / 600000,
+ 'dd' => 1 / 1000000,
+ 'float' => 1 / 1000000,
+ ];
+
+ public function format( LatLongValue $latLong, string $format, bool $directional ) {
+ $formatter = new LatLongFormatter( new FormatterOptions(
+ [
+ LatLongFormatter::OPT_FORMAT => $format,
+ LatLongFormatter::OPT_DIRECTIONAL => $directional,
+ LatLongFormatter::OPT_PRECISION => self::PRECISION_MAP[$format]
+ ]
+ ) );
+
+ return $formatter->format( $latLong );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/ElementJsonSerializer.php b/www/wiki/extensions/Maps/src/Presentation/ElementJsonSerializer.php
new file mode 100644
index 00000000..6c4e33c5
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/ElementJsonSerializer.php
@@ -0,0 +1,35 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Presentation;
+
+
+use Maps\Elements\BaseElement;
+
+class ElementJsonSerializer {
+
+ private $parser;
+
+ public function __construct( WikitextParser $parser ) {
+ $this->parser = $parser;
+ }
+
+ public function elementToJson( BaseElement $element ): array {
+ $json = $element->getArrayValue();
+
+ $this->titleAndText( $json );
+
+ return $json;
+ }
+
+ public function titleAndText( array &$elementJson ) {
+ $elementJson['title'] = $this->parser->wikitextToHtml( $elementJson['title'] );
+ $elementJson['text'] = $this->parser->wikitextToHtml( $elementJson['text'] );
+
+ $hasTitleAndText = $elementJson['title'] !== '' && $elementJson['text'] !== '';
+ $elementJson['text'] = ( $hasTitleAndText ? '<b>' . $elementJson['title'] . '</b>' : $elementJson['title'] ) . $elementJson['text'];
+ $elementJson['title'] = strip_tags( $elementJson['title'] );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/Presentation/KmlFormatter.php b/www/wiki/extensions/Maps/src/Presentation/KmlFormatter.php
new file mode 100644
index 00000000..90df6d1e
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/KmlFormatter.php
@@ -0,0 +1,78 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Presentation;
+
+use Maps\Elements\Location;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class KmlFormatter {
+
+ /**
+ * Builds and returns KML representing the set geographical objects.
+ */
+ public function formatLocationsAsKml( Location ...$locations ): string {
+ $elements = $this->getKmlForLocations( $locations );
+
+ // http://earth.google.com/kml/2.2
+ return <<<EOT
+<?xml version="1.0" encoding="UTF-8"?>
+<kml xmlns="http://www.opengis.net/kml/2.2">
+ <Document>
+$elements
+ </Document>
+</kml>
+EOT;
+ }
+
+ private function getKmlForLocations( array $locations ): string {
+ return implode(
+ "\n",
+ array_map(
+ function( Location $location ) {
+ return $this->locationToKmlPlacemark( $location );
+ },
+ $locations
+ )
+ );
+ }
+
+
+ private function locationToKmlPlacemark( Location $location ): string {
+ // TODO: escaping?
+ $name = '<name><![CDATA[' . $location->getTitle() . ']]></name>';
+
+ // TODO: escaping?
+ $description = '<description><![CDATA[' . $location->getText() . ']]></description>';
+
+ $coordinates = '<coordinates>'
+ . $this->escapeValue( $this->getCoordinateString( $location ) )
+ . '</coordinates>';
+
+ return <<<EOT
+ <Placemark>
+ $name
+ $description
+ <Point>
+ $coordinates
+ </Point>
+ </Placemark>
+EOT;
+ }
+
+ private function getCoordinateString( Location $location ): string {
+ // lon,lat[,alt]
+ return $location->getCoordinates()->getLongitude()
+ . ',' . $location->getCoordinates()->getLatitude()
+ . ',0';
+ }
+
+ private function escapeValue( string $value ): string {
+ return htmlspecialchars( $value, ENT_NOQUOTES );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/MapsDistanceParser.php b/www/wiki/extensions/Maps/src/Presentation/MapsDistanceParser.php
new file mode 100644
index 00000000..c8fb0ef1
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/MapsDistanceParser.php
@@ -0,0 +1,133 @@
+<?php
+
+namespace Maps\Presentation;
+
+/**
+ * Static class for distance validation and parsing. Internal representations are in meters.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsDistanceParser {
+
+ private static $validatedDistanceUnit = false;
+
+ private static $unitRegex = false;
+
+ public static function parseAndFormat( string $distance, string $unit = null, int $decimals = 2 ): string {
+ return self::formatDistance( self::parseDistance( $distance ), $unit, $decimals );
+ }
+
+ /**
+ * Formats a given distance in meters to a distance in an optionally specified notation.
+ */
+ public static function formatDistance( float $meters, string $unit = null, int $decimals = 2 ): string {
+ global $wgContLang;
+ $meters = $wgContLang->formatNum( round( $meters / self::getUnitRatio( $unit ), $decimals ) );
+ return "$meters $unit";
+ }
+
+ /**
+ * Returns the unit to meter ratio in a safe way, by first resolving the unit.
+ */
+ public static function getUnitRatio( string $unit = null ): float {
+ global $egMapsDistanceUnits;
+ return $egMapsDistanceUnits[self::getValidUnit( $unit )];
+ }
+
+ /**
+ * Returns a valid unit. If the provided one is invalid, the default will be used.
+ */
+ public static function getValidUnit( string $unit = null ): string {
+ global $egMapsDistanceUnit, $egMapsDistanceUnits;
+
+ // This ensures the value for $egMapsDistanceUnit is correct, and caches the result.
+ if ( self::$validatedDistanceUnit === false ) {
+ if ( !array_key_exists( $egMapsDistanceUnit, $egMapsDistanceUnits ) ) {
+ $units = array_keys( $egMapsDistanceUnits );
+ $egMapsDistanceUnit = $units[0];
+ }
+
+ self::$validatedDistanceUnit = true;
+ }
+
+ if ( $unit == null || !array_key_exists( $unit, $egMapsDistanceUnits ) ) {
+ $unit = $egMapsDistanceUnit;
+ }
+
+ return $unit;
+ }
+
+ /**
+ * Parses a distance optionally containing a unit to a float value in meters.
+ *
+ * @param string $distance
+ *
+ * @return float|false The distance in meters or false on failure
+ */
+ public static function parseDistance( string $distance ) {
+ if ( !self::isDistance( $distance ) ) {
+ return false;
+ }
+
+ $distance = self::normalizeDistance( $distance );
+
+ self::initUnitRegex();
+
+ $matches = [];
+ preg_match( '/^\d+(\.\d+)?\s?(' . self::$unitRegex . ')?$/', $distance, $matches );
+
+ $value = (float)( $matches[0] . $matches[1] );
+ $value *= self::getUnitRatio( $matches[2] );
+
+ return $value;
+ }
+
+ public static function isDistance( string $distance ): bool {
+ $distance = self::normalizeDistance( $distance );
+
+ self::initUnitRegex();
+
+ return (bool)preg_match( '/^\d+(\.\d+)?\s?(' . self::$unitRegex . ')?$/', $distance );
+ }
+
+ /**
+ * Normalizes a potential distance by removing spaces and turning comma's into dots.
+ */
+ protected static function normalizeDistance( string $distance ): string {
+ $distance = trim( (string)$distance );
+ $strlen = strlen( $distance );
+
+ for ( $i = 0; $i < $strlen; $i++ ) {
+ if ( !ctype_digit( $distance{$i} ) && !in_array( $distance{$i}, [ ',', '.' ] ) ) {
+ $value = substr( $distance, 0, $i );
+ $unit = substr( $distance, $i );
+ break;
+ }
+ }
+
+ $value = str_replace( ',', '.', isset( $value ) ? $value : $distance );
+
+ if ( isset( $unit ) ) {
+ $value .= ' ' . str_replace( [ ' ', "\t" ], '', $unit );
+ }
+
+ return $value;
+ }
+
+ private static function initUnitRegex() {
+ if ( self::$unitRegex === false ) {
+ global $egMapsDistanceUnits;
+ self::$unitRegex = implode( '|', array_keys( $egMapsDistanceUnits ) ) . '|';
+ }
+ }
+
+ /**
+ * Returns a list of all supported units.
+ */
+ public static function getUnits(): array {
+ global $egMapsDistanceUnits;
+ return array_keys( $egMapsDistanceUnits );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/ParameterExtractor.php b/www/wiki/extensions/Maps/src/Presentation/ParameterExtractor.php
new file mode 100644
index 00000000..33a93658
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/ParameterExtractor.php
@@ -0,0 +1,47 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Presentation;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class ParameterExtractor {
+
+ /**
+ * Extracts the value of a parameter from a parameter list.
+ *
+ * @param string[] $parameterNames Name and aliases of the parameter. First match gets used
+ * @param string[] $rawParameters Parameters that did not get processed further than being put in a key-value map
+ *
+ * @return string|null
+ */
+ public function extract( array $parameterNames, array $rawParameters ) {
+ foreach( $parameterNames as $parameterName ) {
+ foreach ( $rawParameters as $rawName => $rawValue ) {
+ if ( trim( strtolower( $rawName ) ) === $parameterName ) {
+ return trim( $rawValue );
+ }
+ }
+ }
+
+ return null;
+ }
+
+ public static function extractFromKeyValueStrings( array $keyValueStrings ) {
+ $rawParameters = [];
+
+ foreach ( $keyValueStrings as $keyValueString ) {
+ $parts = explode( '=', $keyValueString, 2 );
+
+ if ( count( $parts ) === 2 ) {
+ $rawParameters[$parts[0]] = $parts[1];
+ }
+ }
+
+ return $rawParameters;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParser.php
new file mode 100644
index 00000000..e0c2601a
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParser.php
@@ -0,0 +1,30 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Presentation;
+
+use Parser;
+use ParserOptions;
+
+class WikitextParser {
+
+ private $parser;
+
+ public function __construct( Parser $parser ) {
+ $this->parser = $parser;
+ }
+
+ public function wikitextToHtml( string $text ): string {
+ if ( trim( $text ) === '' ) {
+ return '';
+ }
+
+ return $this->parser->parse(
+ $text,
+ $this->parser->getTitle(),
+ new ParserOptions()
+ )->getText();
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/CircleParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/CircleParser.php
new file mode 100644
index 00000000..110064c0
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/CircleParser.php
@@ -0,0 +1,86 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoder;
+use Maps\Elements\Circle;
+use Maps\MapsFactory;
+use ValueParsers\ParseException;
+use ValueParsers\StringValueParser;
+use ValueParsers\ValueParser;
+
+/**
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CircleParser implements ValueParser {
+
+ private $metaDataSeparator = '~';
+
+ private $geocoder;
+
+ public function __construct( $geocoder = null ) {
+ $this->geocoder = $geocoder instanceof Geocoder ? $geocoder : MapsFactory::newDefault()->getGeocoder();
+ }
+
+ /**
+ * @see StringValueParser::stringParse
+ *
+ * @since 3.0
+ *
+ * @param string $value
+ *
+ * @return Circle
+ */
+ public function parse( $value ) {
+ $metaData = explode( $this->metaDataSeparator, $value );
+ $circleData = explode( ':', array_shift( $metaData ) );
+
+ $circle = new Circle( $this->stringToLatLongValue( $circleData[0] ), (float)$circleData[1] );
+
+ if ( $metaData !== [] ) {
+ $circle->setTitle( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $circle->setText( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $circle->setStrokeColor( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $circle->setStrokeOpacity( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $circle->setStrokeWeight( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $circle->setFillColor( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $circle->setFillOpacity( array_shift( $metaData ) );
+ }
+
+ return $circle;
+ }
+
+ private function stringToLatLongValue( string $location ): LatLongValue {
+ $latLong = $this->geocoder->geocode( $location );
+
+ if ( $latLong === null ) {
+ throw new ParseException( 'Failed to parse or geocode' );
+ }
+
+ return $latLong;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/DistanceParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/DistanceParser.php
new file mode 100644
index 00000000..2f90e9fc
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/DistanceParser.php
@@ -0,0 +1,38 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use ValueParsers\ParseException;
+use ValueParsers\StringValueParser;
+
+/**
+ * ValueParser that parses the string representation of a distance.
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class DistanceParser extends StringValueParser {
+
+ /**
+ * @see StringValueParser::stringParse
+ *
+ * @since 3.0
+ *
+ * @param string $value
+ *
+ * @return float
+ * @throws ParseException
+ */
+ public function stringParse( $value ) {
+ $distance = \Maps\Presentation\MapsDistanceParser::parseDistance( $value );
+
+ if ( is_float( $distance ) ) {
+ return $distance;
+ }
+
+ throw new ParseException( 'Not a distance' );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/ImageOverlayParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/ImageOverlayParser.php
new file mode 100644
index 00000000..c2d81591
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/ImageOverlayParser.php
@@ -0,0 +1,83 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoder;
+use Maps\Elements\ImageOverlay;
+use Maps\MapsFactory;
+use ValueParsers\ParseException;
+use ValueParsers\ValueParser;
+
+/**
+ * @since 3.1
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class ImageOverlayParser implements ValueParser {
+
+ private $geocoder;
+
+ public function __construct( $geocoder = null ) {
+ $this->geocoder = $geocoder instanceof Geocoder ? $geocoder : MapsFactory::newDefault()->getGeocoder();
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param string $value
+ *
+ * @return ImageOverlay
+ * @throws ParseException
+ */
+ public function parse( $value ) {
+ $metaData = explode( '~', $value );
+ $imageParameters = explode( ':', array_shift( $metaData ), 3 );
+
+ if ( count( $imageParameters ) !== 3 ) {
+ throw new ParseException( 'Need 3 parameters for an image overlay' );
+ }
+
+ $boundsNorthEast = $this->stringToLatLongValue( $imageParameters[0] );
+ $boundsSouthWest = $this->stringToLatLongValue( $imageParameters[1] );
+ $imageUrl = \Maps\MapsFunctions::getFileUrl( $imageParameters[2] );
+
+ $overlay = new ImageOverlay( $boundsNorthEast, $boundsSouthWest, $imageUrl );
+
+ if ( $metaData !== [] ) {
+ $overlay->setTitle( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $overlay->setText( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $overlay->setLink( $this->getUrlFromLinkString( array_shift( $metaData ) ) );
+ }
+
+ return $overlay;
+ }
+
+ private function getUrlFromLinkString( string $linkString ): string {
+ $linkPrefix = 'link:';
+
+ if ( substr( $linkString, 0, strlen( $linkPrefix ) ) === $linkPrefix ) {
+ return substr( $linkString, strlen( $linkPrefix ) );
+ }
+
+ return $linkString;
+ }
+
+ private function stringToLatLongValue( string $location ): LatLongValue {
+ $latLong = $this->geocoder->geocode( $location );
+
+ if ( $latLong === null ) {
+ throw new ParseException( 'Failed to parse or geocode' );
+ }
+
+ return $latLong;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LineParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LineParser.php
new file mode 100644
index 00000000..4e25a1f7
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LineParser.php
@@ -0,0 +1,163 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoder;
+use Maps\Elements\Line;
+use Maps\MapsFactory;
+use ValueParsers\StringValueParser;
+use ValueParsers\ValueParser;
+
+/**
+ * ValueParser that parses the string representation of a line.
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class LineParser implements ValueParser {
+
+ private $metaDataSeparator = '~';
+
+ private $geocoder = null;
+
+ public function setGeocoder( Geocoder $geocoder ) {
+ $this->geocoder = $geocoder;
+ }
+
+ private function getGeocoder(): Geocoder {
+ if ( $this->geocoder == null ) {
+ $this->geocoder = MapsFactory::newDefault()->getGeocoder();
+ }
+
+ return $this->geocoder;
+ }
+
+ /**
+ * @see StringValueParser::stringParse
+ *
+ * @since 3.0
+ *
+ * @param string $value
+ *
+ * @return Line
+ */
+ public function parse( $value ) {
+ $parts = explode( $this->metaDataSeparator, $value );
+
+ $line = $this->constructShapeFromLatLongValues(
+ $this->parseCoordinates(
+ explode( ':', array_shift( $parts ) )
+ )
+ );
+
+ $this->handleCommonParams( $parts, $line );
+
+ return $line;
+ }
+
+ protected function constructShapeFromLatLongValues( array $locations ) {
+ return new Line( $locations );
+ }
+
+ /**
+ * @since 3.0
+ *
+ * @param string[] $coordinateStrings
+ *
+ * @return LatLongValue[]
+ */
+ protected function parseCoordinates( array $coordinateStrings ): array {
+ $coordinates = [];
+
+ foreach ( $coordinateStrings as $coordinateString ) {
+ $coordinate = $this->getGeocoder()->geocode( $coordinateString );
+
+ if ( $coordinate === null ) {
+ // TODO: good if the user knows something has been omitted
+ } else {
+ $coordinates[] = $coordinate;
+ }
+ }
+
+ return $coordinates;
+ }
+
+ /**
+ * This method requires that parameters are positionally correct,
+ * 1. Link (one parameter) or bubble data (two parameters)
+ * 2. Stroke data (three parameters)
+ * 3. Fill data (two parameters)
+ * e.g ...title~text~strokeColor~strokeOpacity~strokeWeight~fillColor~fillOpacity
+ *
+ * @since 3.0
+ *
+ * @param array $params
+ * @param Line $line
+ */
+ protected function handleCommonParams( array &$params, Line &$line ) {
+ //Handle bubble and link parameters
+
+ //create link data
+ $linkOrTitle = array_shift( $params );
+ if ( $link = $this->isLinkParameter( $linkOrTitle ) ) {
+ $this->setLinkFromParameter( $line, $link );
+ } else {
+ //create bubble data
+ $this->setBubbleDataFromParameter( $line, $params, $linkOrTitle );
+ }
+
+ //handle stroke parameters
+ if ( $color = array_shift( $params ) ) {
+ $line->setStrokeColor( $color );
+ }
+
+ if ( $opacity = array_shift( $params ) ) {
+ $line->setStrokeOpacity( $opacity );
+ }
+
+ if ( $weight = array_shift( $params ) ) {
+ $line->setStrokeWeight( $weight );
+ }
+ }
+
+ /**
+ * Checks if a string is prefixed with link:
+ *
+ * @static
+ *
+ * @param $link
+ *
+ * @return bool|string
+ * @since 2.0
+ */
+ private function isLinkParameter( $link ) {
+ if ( strpos( $link, 'link:' ) === 0 ) {
+ return substr( $link, 5 );
+ }
+
+ return false;
+ }
+
+ protected function setLinkFromParameter( Line &$line, $link ) {
+ if ( filter_var( $link, FILTER_VALIDATE_URL, FILTER_FLAG_SCHEME_REQUIRED ) ) {
+ $line->setLink( $link );
+ } else {
+ $title = \Title::newFromText( $link );
+ $line->setLink( $title->getFullURL() );
+ }
+ }
+
+ protected function setBubbleDataFromParameter( Line &$line, &$params, $title ) {
+ if ( $title ) {
+ $line->setTitle( $title );
+ }
+ if ( $text = array_shift( $params ) ) {
+ $line->setText( $text );
+ }
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LocationParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LocationParser.php
new file mode 100644
index 00000000..26af76ef
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/LocationParser.php
@@ -0,0 +1,147 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use DataValues\Geo\Parsers\LatLongParser;
+use Jeroen\SimpleGeocoder\Geocoder;
+use Maps\Elements\Location;
+use Maps\FileUrlFinder;
+use Maps\MapsFactory;
+use Title;
+use ValueParsers\ParseException;
+use ValueParsers\StringValueParser;
+use ValueParsers\ValueParser;
+
+/**
+ * ValueParser that parses the string representation of a location.
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class LocationParser implements ValueParser {
+
+ private $geocoder;
+ private $fileUrlFinder;
+ private $useAddressAsTitle;
+
+ /**
+ * @deprecated Use newInstance instead
+ */
+ public function __construct( $enableLegacyCrud = true ) {
+ if ( $enableLegacyCrud ) {
+ $this->geocoder = MapsFactory::globalInstance()->getGeocoder();
+ $this->fileUrlFinder = MapsFactory::globalInstance()->getFileUrlFinder();
+ $this->useAddressAsTitle = false;
+ }
+ }
+
+ public static function newInstance( Geocoder $geocoder, FileUrlFinder $fileUrlFinder, bool $useAddressAsTitle = false ): self {
+ $instance = new self( false );
+ $instance->geocoder = $geocoder;
+ $instance->fileUrlFinder = $fileUrlFinder;
+ $instance->useAddressAsTitle = $useAddressAsTitle;
+ return $instance;
+ }
+
+ /**
+ * @see StringValueParser::stringParse
+ *
+ * @since 3.0
+ *
+ * @param string $value
+ *
+ * @return Location
+ * @throws ParseException
+ */
+ public function parse( $value ) {
+ $separator = '~';
+
+ $metaData = explode( $separator, $value );
+
+ $coordinatesOrAddress = array_shift( $metaData );
+ $coordinates = $this->geocoder->geocode( $coordinatesOrAddress );
+
+ if ( $coordinates === null ) {
+ throw new ParseException( 'Location is not a parsable coordinate and not a geocodable address' );
+ }
+
+ $location = new Location( $coordinates );
+
+ if ( $metaData !== [] ) {
+ $this->setTitleOrLink( $location, array_shift( $metaData ) );
+ } else {
+ if ( $this->useAddressAsTitle && $this->isAddress( $coordinatesOrAddress ) ) {
+ $location->setTitle( $coordinatesOrAddress );
+ }
+ }
+
+ if ( $metaData !== [] ) {
+ $location->setText( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $location->setIcon( $this->fileUrlFinder->getUrlForFileName( array_shift( $metaData ) ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $location->setGroup( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $location->setInlineLabel( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $location->setVisitedIcon( $this->fileUrlFinder->getUrlForFileName( array_shift( $metaData ) ) ) ;
+ }
+
+ return $location;
+ }
+
+ private function setTitleOrLink( Location $location, $titleOrLink ) {
+ if ( $this->isLink( $titleOrLink ) ) {
+ $this->setLink( $location, $titleOrLink );
+ } else {
+ $location->setTitle( $titleOrLink );
+ }
+ }
+
+ private function isLink( $value ) {
+ return strpos( $value, 'link:' ) === 0;
+ }
+
+ private function setLink( Location $location, $link ) {
+ $link = substr( $link, 5 );
+ $location->setLink( $this->getExpandedLink( $link ) );
+ }
+
+ private function getExpandedLink( $link ) {
+ if ( filter_var( $link, FILTER_VALIDATE_URL ) ) {
+ return $link;
+ }
+
+ $title = Title::newFromText( $link );
+
+ if ( $title === null ) {
+ return '';
+ }
+
+ return $title->getFullURL();
+ }
+
+ private function isAddress( string $coordsOrAddress ): bool {
+ $coordinateParser = new LatLongParser();
+
+ try {
+ $coordinateParser->parse( $coordsOrAddress );
+ }
+ catch ( ParseException $parseException ) {
+ return true;
+ }
+
+ return false;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/PolygonParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/PolygonParser.php
new file mode 100644
index 00000000..1bf14a7f
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/PolygonParser.php
@@ -0,0 +1,41 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use Maps\Elements\Line;
+use Maps\Elements\Polygon;
+
+/**
+ * ValueParser that parses the string representation of a polygon.
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class PolygonParser extends LineParser {
+
+ protected function constructShapeFromLatLongValues( array $locations ) {
+ return new Polygon( $locations );
+ }
+
+ protected function handleCommonParams( array &$params, Line &$line ) {
+ parent::handleCommonParams( $params, $line );
+ $this->handlePolygonParams( $params, $line );
+ }
+
+ protected function handlePolygonParams( array &$params, Polygon &$polygon ) {
+ if ( $fillColor = array_shift( $params ) ) {
+ $polygon->setFillColor( $fillColor );
+ }
+
+ if ( $fillOpacity = array_shift( $params ) ) {
+ $polygon->setFillOpacity( $fillOpacity );
+ }
+
+ if ( $showOnlyOnHover = array_shift( $params ) ) {
+ $polygon->setOnlyVisibleOnHover( strtolower( trim( $showOnlyOnHover ) ) === 'on' );
+ }
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/RectangleParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/RectangleParser.php
new file mode 100644
index 00000000..1b694a27
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/RectangleParser.php
@@ -0,0 +1,89 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoder;
+use Maps\Elements\Rectangle;
+use Maps\MapsFactory;
+use ValueParsers\ParseException;
+use ValueParsers\StringValueParser;
+use ValueParsers\ValueParser;
+
+/**
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Kim Eik
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class RectangleParser implements ValueParser {
+
+ private $metaDataSeparator = '~';
+
+ private $geocoder;
+
+ public function __construct( $geocoder = null ) {
+ $this->geocoder = $geocoder instanceof Geocoder ? $geocoder : MapsFactory::newDefault()->getGeocoder();
+ }
+
+ /**
+ * @see StringValueParser::stringParse
+ *
+ * @since 3.0
+ *
+ * @param string $value
+ *
+ * @return Rectangle
+ */
+ public function parse( $value ) {
+ $metaData = explode( $this->metaDataSeparator, $value );
+ $rectangleData = explode( ':', array_shift( $metaData ) );
+
+ $rectangle = new Rectangle(
+ $this->stringToLatLongValue( $rectangleData[0] ),
+ $this->stringToLatLongValue( $rectangleData[1] )
+ );
+
+ if ( $metaData !== [] ) {
+ $rectangle->setTitle( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $rectangle->setText( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $rectangle->setStrokeColor( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $rectangle->setStrokeOpacity( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $rectangle->setStrokeWeight( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $rectangle->setFillColor( array_shift( $metaData ) );
+ }
+
+ if ( $metaData !== [] ) {
+ $rectangle->setFillOpacity( array_shift( $metaData ) );
+ }
+
+ return $rectangle;
+ }
+
+ private function stringToLatLongValue( string $location ): LatLongValue {
+ $latLong = $this->geocoder->geocode( $location );
+
+ if ( $latLong === null ) {
+ throw new ParseException( 'Failed to parse or geocode' );
+ }
+
+ return $latLong;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/WmsOverlayParser.php b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/WmsOverlayParser.php
new file mode 100644
index 00000000..b2b784b9
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/Presentation/WikitextParsers/WmsOverlayParser.php
@@ -0,0 +1,49 @@
+<?php
+
+namespace Maps\Presentation\WikitextParsers;
+
+use Maps\Elements\WmsOverlay;
+use ValueParsers\ParseException;
+use ValueParsers\ValueParser;
+
+/**
+ * ValueParser that parses the string representation of a WMS layer
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class WmsOverlayParser implements ValueParser {
+
+ /**
+ * Parses the provided string and returns the result.
+ *
+ * @since 3.0
+ *
+ * @param string $value
+ *
+ * @return WmsOverlay
+ * @throws ParseException
+ */
+ public function parse( $value ) {
+ if ( !is_string( $value ) ) {
+ throw new ParseException( 'Not a string' );
+ }
+
+ $separator = " ";
+ $metaData = explode( $separator, $value );
+
+ if ( count( $metaData ) >= 2 ) {
+ $wmsOverlay = new WmsOverlay( $metaData[0], $metaData[1] );
+ if ( count( $metaData ) == 3 ) {
+ $wmsOverlay->setWmsStyleName( $metaData[2] );
+ }
+
+ return $wmsOverlay;
+ }
+
+ throw new ParseException( 'Need at least two parameters, url to WMS server and map layer name' );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/SemanticMW/DataValues/CoordinateValue.php b/www/wiki/extensions/Maps/src/SemanticMW/DataValues/CoordinateValue.php
new file mode 100644
index 00000000..47de2632
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMW/DataValues/CoordinateValue.php
@@ -0,0 +1,266 @@
+<?php
+
+namespace Maps\SemanticMW\DataValues;
+
+use DataValues\Geo\Parsers\LatLongParser;
+use DataValues\Geo\Values\LatLongValue;
+use InvalidArgumentException;
+use Maps\MapsFactory;
+use Maps\Presentation\MapsDistanceParser;
+use SMW\Query\Language\Description;
+use SMW\Query\Language\ThingDescription;
+use SMW\Query\QueryComparator;
+use SMWDataItem;
+use SMWDataValue;
+use SMWDIGeoCoord;
+use SMWOutputs;
+use ValueParsers\ParseException;
+
+/**
+ * @property SMWDIGeoCoord m_dataitem
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Markus Krötzsch
+ */
+class CoordinateValue extends SMWDataValue {
+
+ private $wikiValue;
+
+ /**
+ * Overwrite SMWDataValue::getQueryDescription() to be able to process
+ * comparators between all values.
+ *
+ * @param string $value
+ *
+ * @return Description
+ * @throws InvalidArgumentException
+ */
+ public function getQueryDescription( $value ) {
+ if ( !is_string( $value ) ) {
+ throw new InvalidArgumentException( '$value needs to be a string' );
+ }
+
+ list( $distance, $comparator ) = $this->parseUserValue( $value );
+ $distance = $this->parserDistance( $distance );
+
+ $this->setUserValue( $value );
+
+ switch ( true ) {
+ case !$this->isValid():
+ return new ThingDescription();
+ case $distance !== false:
+ return new \Maps\SemanticMW\ValueDescriptions\AreaDescription(
+ $this->getDataItem(),
+ $comparator,
+ $distance
+ );
+ default:
+ return new \Maps\SemanticMW\ValueDescriptions\CoordinateDescription(
+ $this->getDataItem(),
+ null,
+ $comparator
+ );
+ }
+ }
+
+ /**
+ * @see SMWDataValue::parseUserValue
+ */
+ protected function parseUserValue( $value ) {
+ if ( !is_string( $value ) ) {
+ throw new InvalidArgumentException( '$value needs to be a string' );
+ }
+
+ $this->wikiValue = $value;
+
+ $comparator = SMW_CMP_EQ;
+ $distance = false;
+
+ if ( $value === '' ) {
+ $this->addError( wfMessage( 'smw_novalues' )->text() );
+ } else {
+ $comparator = QueryComparator::getInstance()->extractComparatorFromString( $value );
+
+ list( $coordinates, $distance ) = $this->findValueParts( $value );
+
+ $this->tryParseAndSetDataItem( $coordinates );
+ }
+
+ return [ $distance, $comparator ];
+ }
+
+ private function findValueParts( string $value ): array {
+ $parts = explode( '(', $value );
+
+ $coordinates = trim( array_shift( $parts ) );
+ $distance = count( $parts ) > 0 ? trim( array_shift( $parts ) ) : false;
+
+ return [ $coordinates, $distance ];
+ }
+
+ private function tryParseAndSetDataItem( string $coordinates ) {
+ $parser = new LatLongParser();
+
+ try {
+ $value = $parser->parse( $coordinates );
+ $this->m_dataitem = new SMWDIGeoCoord( $value->getLatitude(), $value->getLongitude() );
+ }
+ catch ( ParseException $parseException ) {
+ $this->addError( wfMessage( 'maps_unrecognized_coords', $coordinates, 1 )->text() );
+
+ // Make sure this is always set
+ // TODO: Why is this needed?!
+ $this->m_dataitem = new SMWDIGeoCoord( [ 'lat' => 0, 'lon' => 0 ] );
+ }
+ }
+
+ private function parserDistance( $distance ) {
+ if ( $distance !== false ) {
+ $distance = substr( trim( $distance ), 0, -1 );
+
+ if ( !MapsDistanceParser::isDistance( $distance ) ) {
+ $this->addError( wfMessage( 'semanticmaps-unrecognizeddistance', $distance )->text() );
+ $distance = false;
+ }
+ }
+
+ return $distance;
+ }
+
+ /**
+ * @see SMWDataValue::getShortHTMLText
+ *
+ * @since 0.6
+ */
+ public function getShortHTMLText( $linker = null ) {
+ return $this->getShortWikiText( $linker );
+ }
+
+ /**
+ * @see SMWDataValue::getShortWikiText
+ */
+ public function getShortWikiText( $linked = null ) {
+ if ( $this->isValid() ) {
+ if ( $this->m_caption === false ) {
+ return $this->getFormattedCoord( $this->m_dataitem );
+ }
+
+ return $this->m_caption;
+ }
+
+ return $this->getErrorText();
+ }
+
+ /**
+ * @param SMWDIGeoCoord $dataItem
+ * @param string|null $format
+ *
+ * @return string|null
+ */
+ private function getFormattedCoord( SMWDIGeoCoord $dataItem, string $format = null ) {
+ return MapsFactory::globalInstance()->getCoordinateFormatter()->format(
+ new LatLongValue(
+ $dataItem->getLatitude(),
+ $dataItem->getLongitude()
+ ),
+ $format ?? $GLOBALS['smgQPCoodFormat'],
+ $GLOBALS['smgQPCoodDirectional']
+ );
+ }
+
+ /**
+ * @see SMWDataValue::getLongHTMLText
+ */
+ public function getLongHTMLText( $linker = null ) {
+ return $this->getLongWikiText( $linker );
+ }
+
+ /**
+ * @see SMWDataValue::getLongWikiText
+ *
+ * @since 0.6
+ */
+ public function getLongWikiText( $linked = null ) {
+ if ( $this->isValid() ) {
+ SMWOutputs::requireHeadItem( SMW_HEADER_TOOLTIP );
+
+ // TODO: fix lang keys so they include the space and coordinates.
+ $coordinateSet = $this->m_dataitem->getCoordinateSet();
+
+ $text = $this->getFormattedCoord( $this->m_dataitem );
+
+ $lines = [
+ wfMessage( 'semanticmaps-latitude', $coordinateSet['lat'] )->inContentLanguage()->escaped(),
+ wfMessage( 'semanticmaps-longitude', $coordinateSet['lon'] )->inContentLanguage()->escaped(),
+ ];
+
+ if ( array_key_exists( 'alt', $coordinateSet ) ) {
+ $lines[] = wfMessage( 'semanticmaps-altitude', $coordinateSet['alt'] )->inContentLanguage()->escaped();
+ }
+
+ return '<span class="smwttinline">' . htmlspecialchars( $text ) . '<span class="smwttcontent">' .
+ implode( '<br />', $lines ) .
+ '</span></span>';
+ } else {
+ return $this->getErrorText();
+ }
+ }
+
+ /**
+ * @see SMWDataValue::getWikiValue
+ */
+ public function getWikiValue() {
+ return $this->wikiValue;
+ }
+
+ /**
+ * @see SMWDataValue::setDataItem
+ *
+ * @param SMWDataItem $dataItem
+ *
+ * @return boolean
+ */
+ protected function loadDataItem( SMWDataItem $dataItem ) {
+ if ( $dataItem instanceof SMWDIGeoCoord ) {
+ $formattedValue = $this->getFormattedCoord( $dataItem );
+
+ if ( $formattedValue !== null ) {
+ $this->wikiValue = $formattedValue;
+ $this->m_dataitem = $dataItem;
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Create links to mapping services based on a wiki-editable message. The parameters
+ * available to the message are:
+ *
+ * $1: The location in non-directional float notation.
+ * $2: The location in directional DMS notation.
+ * $3: The latitude in non-directional float notation.
+ * $4 The longitude in non-directional float notation.
+ *
+ * @return array
+ */
+ protected function getServiceLinkParams() {
+ $coordinateSet = $this->m_dataitem->getCoordinateSet();
+ return [
+ $this->getFormattedCoord( $this->m_dataitem, 'float' ), // TODO
+ $this->getFormattedCoord( $this->m_dataitem, 'dms' ), // TODO
+ $coordinateSet['lat'],
+ $coordinateSet['lon']
+ ];
+ }
+
+ /**
+ * @return SMWDIGeoCoord|\SMWDIError
+ */
+ public function getDataItem() {
+ return parent::getDataItem();
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/KmlPrinter.php b/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/KmlPrinter.php
new file mode 100644
index 00000000..1bda31c6
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/KmlPrinter.php
@@ -0,0 +1,146 @@
+<?php
+
+namespace Maps\SemanticMW\ResultPrinters;
+
+use Maps\Presentation\KmlFormatter;
+use ParamProcessor\ParamDefinition;
+use SMW\Query\ResultPrinters\FileExportPrinter;
+use SMWQueryResult;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class KmlPrinter extends FileExportPrinter {
+
+ /**
+ * @param SMWQueryResult $res
+ * @param int $outputMode
+ *
+ * @return string
+ */
+ public function getResultText( SMWQueryResult $res, $outputMode ) {
+ if ( $outputMode == SMW_OUTPUT_FILE ) {
+ return $this->getKML( $res, $outputMode );
+ }
+
+ return $this->getKMLLink( $res, $outputMode );
+ }
+
+ private function getKML( SMWQueryResult $res, int $outputMode ): string {
+ $queryHandler = new QueryHandler( $res, $outputMode, $this->params['linkabsolute'] );
+ $queryHandler->setText( $this->params['text'] );
+ $queryHandler->setTitle( $this->params['title'] );
+ $queryHandler->setSubjectSeparator( '' );
+
+ $formatter = new KmlFormatter();
+ return $formatter->formatLocationsAsKml( ...$queryHandler->getLocations() );
+ }
+
+ /**
+ * Returns a link (HTML) pointing to a query that returns the actual KML file.
+ */
+ private function getKMLLink( SMWQueryResult $res, int $outputMode ): string {
+ $searchLabel = $this->getSearchLabel( $outputMode );
+ $link = $res->getQueryLink(
+ $searchLabel ? $searchLabel : wfMessage( 'semanticmaps-kml-link' )->inContentLanguage()->text()
+ );
+ $link->setParameter( 'kml', 'format' );
+ $link->setParameter( $this->params['linkabsolute'] ? 'yes' : 'no', 'linkabsolute' );
+
+ if ( $this->params['title'] !== '' ) {
+ $link->setParameter( $this->params['title'], 'title' );
+ }
+
+ if ( $this->params['text'] !== '' ) {
+ $link->setParameter( $this->params['text'], 'text' );
+ }
+
+ // Fix for offset-error in getQueryLink()
+ // (getQueryLink by default sets offset to point to the next
+ // result set, fix by setting it to 0 if now explicitly set)
+ if ( array_key_exists( 'offset', $this->params ) ) {
+ $link->setParameter( $this->params['offset'], 'offset' );
+ } else {
+ $link->setParameter( 0, 'offset' );
+ }
+
+ if ( array_key_exists( 'limit', $this->params ) ) {
+ $link->setParameter( $this->params['limit'], 'limit' );
+ } else { // Use a reasonable default limit.
+ $link->setParameter( 20, 'limit' );
+ }
+
+ $this->isHTML = ( $outputMode == SMW_OUTPUT_HTML );
+
+ return $link->getText( $outputMode, $this->mLinker );
+ }
+
+ /**
+ * @see SMWResultPrinter::getParamDefinitions
+ *
+ * @param ParamDefinition[] $definitions
+ *
+ * @return array
+ */
+ public function getParamDefinitions( array $definitions ) {
+ global $egMapsDefaultLabel, $egMapsDefaultTitle;
+
+ $definitions['text'] = [
+ 'message' => 'semanticmaps-kml-text',
+ 'default' => $egMapsDefaultLabel,
+ ];
+
+ $definitions['title'] = [
+ 'message' => 'semanticmaps-kml-title',
+ 'default' => $egMapsDefaultTitle,
+ ];
+
+ $definitions['linkabsolute'] = [
+ 'message' => 'semanticmaps-kml-linkabsolute',
+ 'type' => 'boolean',
+ 'default' => true,
+ ];
+
+ return $definitions;
+ }
+
+ /**
+ * @see SMWIExportPrinter::getMimeType
+ *
+ * @param SMWQueryResult $queryResult
+ *
+ * @return string
+ */
+ public function getMimeType( SMWQueryResult $queryResult ) {
+ return 'application/vnd.google-earth.kml+xml';
+ }
+
+ /**
+ * @see SMWIExportPrinter::getFileName
+ *
+ * @param SMWQueryResult $queryResult
+ *
+ * @return string|boolean
+ */
+ public function getFileName( SMWQueryResult $queryResult ) {
+ return 'kml.kml';
+ }
+
+ /**
+ * @see SMWResultPrinter::getName()
+ */
+ public final function getName() {
+ return wfMessage( 'semanticmaps-kml' )->text();
+ }
+
+ /**
+ * @see SMWResultPrinter::handleParameters
+ *
+ * @param array $params
+ * @param $outputMode
+ */
+ protected function handleParameters( array $params, $outputMode ) {
+ $this->params = $params;
+ }
+}
diff --git a/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/MapPrinter.php b/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/MapPrinter.php
new file mode 100644
index 00000000..d3b17adb
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/MapPrinter.php
@@ -0,0 +1,423 @@
+<?php
+
+namespace Maps\SemanticMW\ResultPrinters;
+
+use FormatJson;
+use Html;
+use Linker;
+use Maps\Elements\BaseElement;
+use Maps\Elements\Location;
+use Maps\FileUrlFinder;
+use Maps\MappingService;
+use Maps\MapsFunctions;
+use Maps\Presentation\ElementJsonSerializer;
+use Maps\Presentation\WikitextParser;
+use Maps\Presentation\WikitextParsers\LocationParser;
+use ParamProcessor\ParamDefinition;
+use Parser;
+use SMW\Query\ResultPrinters\ResultPrinter;
+use SMWOutputs;
+use SMWQueryResult;
+use Title;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+class MapPrinter extends ResultPrinter {
+
+ private static $services = [];
+
+ /**
+ * @var LocationParser
+ */
+ private $locationParser;
+
+ /**
+ * @var FileUrlFinder
+ */
+ private $fileUrlFinder;
+
+ /**
+ * @var MappingService
+ */
+ private $service;
+
+ /**
+ * @var WikitextParser
+ */
+ private $wikitextParser;
+
+ /**
+ * @var ElementJsonSerializer
+ */
+ private $elementSerializer;
+
+ /**
+ * @var string|boolean
+ */
+ private $fatalErrorMsg = false;
+
+ /**
+ * @param string $format
+ * @param bool $inline
+ */
+ public function __construct( $format, $inline = true ) {
+ $this->service = self::$services[$format];
+
+ parent::__construct( $format, $inline );
+ }
+
+ /**
+ * @since 3.4
+ * FIXME: this is a temporary hack that should be replaced when SMW allows for dependency
+ * injection in query printers.
+ *
+ * @param MappingService $service
+ */
+ public static function registerService( MappingService $service ) {
+ self::$services[$service->getName()] = $service;
+ }
+
+ public static function registerDefaultService( $serviceName ) {
+ self::$services['map'] = self::$services[$serviceName];
+ }
+
+ private function getParser(): Parser {
+ $parser = $GLOBALS['wgParser'];
+
+ if ( $parser instanceof \StubObject ) {
+ return $parser->_newObject();
+ }
+
+ return $parser;
+ }
+
+ private function getParserClone(): Parser {
+ $parser = $this->getParser();
+ return clone $parser;
+ }
+
+ /**
+ * Builds up and returns the HTML for the map, with the queried coordinate data on it.
+ *
+ * @param SMWQueryResult $res
+ * @param int $outputMode
+ *
+ * @return string
+ */
+ public final function getResultText( SMWQueryResult $res, $outputMode ) {
+ if ( $this->fatalErrorMsg !== false ) {
+ return $this->fatalErrorMsg;
+ }
+
+ $factory = \Maps\MapsFactory::newDefault();
+ $this->locationParser = $factory->newLocationParser();
+ $this->fileUrlFinder = $factory->getFileUrlFinder();
+
+ $this->wikitextParser = new WikitextParser( $this->getParserClone() );
+ $this->elementSerializer = new ElementJsonSerializer( $this->wikitextParser );
+
+ $this->addTrackingCategoryIfNeeded();
+
+ $params = $this->params;
+
+ $queryHandler = new QueryHandler( $res, $outputMode );
+ $queryHandler->setLinkStyle( $params['link'] );
+ $queryHandler->setHeaderStyle( $params['headers'] );
+ $queryHandler->setShowSubject( $params['showtitle'] );
+ $queryHandler->setTemplate( $params['template'] );
+ $queryHandler->setUserParam( $params['userparam'] );
+ $queryHandler->setHideNamespace( $params['hidenamespace'] );
+ $queryHandler->setActiveIcon( $params['activeicon'] );
+
+ $this->handleMarkerData( $params, $queryHandler );
+
+ $params['lines'] = $this->elementsToJson( $params['lines'] );
+ $params['polygons'] = $this->elementsToJson( $params['polygons'] );
+ $params['circles'] = $this->elementsToJson( $params['circles'] );
+ $params['rectangles'] = $this->elementsToJson( $params['rectangles'] );
+
+ $params['ajaxquery'] = urlencode( $params['ajaxquery'] );
+
+ if ( $params['locations'] === [] ) {
+ return $params['default'];
+ }
+
+ // We can only take care of the zoom defaulting here,
+ // as not all locations are available in whats passed to Validator.
+ if ( $this->fullParams['zoom']->wasSetToDefault() && count( $params['locations'] ) > 1 ) {
+ $params['zoom'] = false;
+ }
+
+ $mapName = $this->service->newMapId();
+
+ SMWOutputs::requireHeadItem(
+ $mapName,
+ $this->service->getDependencyHtml( $params )
+ );
+
+ foreach ( $this->service->getResourceModules() as $resourceModule ) {
+ SMWOutputs::requireResource( $resourceModule );
+ }
+
+ if ( array_key_exists( 'source', $params ) ) {
+ unset( $params['source'] );
+ }
+
+ return $this->getMapHTML( $params, $mapName );
+ }
+
+ private function elementsToJson( array $elements ) {
+ return array_map(
+ function( BaseElement $element ) {
+ return $this->elementSerializer->elementToJson( $element );
+ },
+ $elements
+ );
+ }
+
+ private function addTrackingCategoryIfNeeded() {
+ /**
+ * @var Parser $wgParser
+ */
+ global $wgParser;
+
+ if ( $GLOBALS['egMapsEnableCategory'] && $wgParser->getOutput() !== null ) {
+ $wgParser->addTrackingCategory( 'maps-tracking-category' );
+ }
+ }
+
+ /**
+ * Converts the data in the coordinates parameter to JSON-ready objects.
+ * These get stored in the locations parameter, and the coordinates on gets deleted.
+ *
+ * @param array &$params
+ * @param QueryHandler $queryHandler
+ */
+ private function handleMarkerData( array &$params, QueryHandler $queryHandler ) {
+ $params['centre'] = $this->getCenter( $params['centre'] );
+
+ $iconUrl = $this->fileUrlFinder->getUrlForFileName( $params['icon'] );
+ $visitedIconUrl = $this->fileUrlFinder->getUrlForFileName( $params['visitedicon'] );
+
+ $params['locations'] = $this->getJsonForStaticLocations(
+ $params['staticlocations'],
+ $params,
+ $iconUrl,
+ $visitedIconUrl
+ );
+
+ unset( $params['staticlocations'] );
+
+ $params['locations'] = array_merge(
+ $params['locations'],
+ $this->getJsonForLocations(
+ $queryHandler->getLocations(),
+ $params,
+ $iconUrl,
+ $visitedIconUrl
+ )
+ );
+ }
+
+ private function getCenter( $coordinatesOrAddress ) {
+ if ( $coordinatesOrAddress === false ) {
+ return false;
+ }
+
+ try {
+ // FIXME: a Location makes no sense here, since the non-coordinate data is not used
+ $location = $this->locationParser->parse( $coordinatesOrAddress );
+ }
+ catch ( \Exception $ex ) {
+ // TODO: somehow report this to the user
+ return false;
+ }
+
+ return $location->getJSONObject();
+ }
+
+ private function getJsonForStaticLocations( array $staticLocations, array $params, $iconUrl, $visitedIconUrl ) {
+ $locationsJson = [];
+
+ foreach ( $staticLocations as $location ) {
+ $locationsJson[] = $this->getJsonForStaticLocation(
+ $location,
+ $params,
+ $iconUrl,
+ $visitedIconUrl
+ );
+ }
+
+ return $locationsJson;
+ }
+
+ private function getJsonForStaticLocation( Location $location, array $params, $iconUrl, $visitedIconUrl ) {
+ $jsonObj = $location->getJSONObject( $params['title'], $params['label'], $iconUrl, '', '', $visitedIconUrl );
+
+ $this->elementSerializer->titleAndText( $jsonObj );
+
+ if ( $params['pagelabel'] ) {
+ $jsonObj['inlineLabel'] = Linker::link( Title::newFromText( $jsonObj['title'] ) );
+ }
+
+ return $jsonObj;
+ }
+
+ /**
+ * @param Location[] $locations
+ * @param array $params
+ * @param string $iconUrl
+ * @param string $visitedIconUrl
+ *
+ * @return array
+ */
+ private function getJsonForLocations( iterable $locations, array $params, string $iconUrl, string $visitedIconUrl ): array {
+ $locationsJson = [];
+
+ foreach ( $locations as $location ) {
+ $jsonObj = $location->getJSONObject(
+ $params['title'],
+ $params['label'],
+ $iconUrl,
+ '',
+ '',
+ $visitedIconUrl
+ );
+
+ $jsonObj['title'] = strip_tags( $jsonObj['title'] );
+
+ $locationsJson[] = $jsonObj;
+ }
+
+ return $locationsJson;
+ }
+
+ /**
+ * Returns the HTML to display the map.
+ *
+ * @param array $params
+ * @param string $mapName
+ *
+ * @return string
+ */
+ private function getMapHTML( array $params, string $mapName ): string {
+ return Html::rawElement(
+ 'div',
+ [
+ 'id' => $mapName,
+ 'style' => "width: {$params['width']}; height: {$params['height']}; background-color: #cccccc; overflow: hidden;",
+ 'class' => 'maps-map maps-' . $this->service->getName()
+ ],
+ wfMessage( 'maps-loading-map' )->inContentLanguage()->escaped() .
+ Html::element(
+ 'div',
+ [ 'style' => 'display:none', 'class' => 'mapdata' ],
+ FormatJson::encode( $params )
+ )
+ );
+ }
+
+ /**
+ * Returns the internationalized name of the mapping service.
+ *
+ * @return string
+ */
+ public final function getName() {
+ return wfMessage( 'maps_' . $this->service->getName() )->text();
+ }
+
+ /**
+ * Returns a list of parameter information, for usage by Special:Ask and others.
+ *
+ * @return array
+ */
+ public function getParameters() {
+ $params = parent::getParameters();
+ $paramInfo = $this->getParameterInfo();
+
+ // Do not display this as an option, as the format already determines it
+ // TODO: this can probably be done cleaner with some changes in Maps
+ unset( $paramInfo['mappingservice'] );
+
+ $params = array_merge( $params, $paramInfo );
+
+ return $params;
+ }
+
+ /**
+ * Returns an array containing the parameter info.
+ *
+ * @return array
+ */
+ private function getParameterInfo() {
+ global $smgQPShowTitle, $smgQPTemplate, $smgQPHideNamespace;
+
+ $params = array_merge(
+ ParamDefinition::getCleanDefinitions( MapsFunctions::getCommonParameters() ),
+ $this->service->getParameterInfo()
+ );
+
+ $params['staticlocations'] = [
+ 'type' => 'mapslocation',
+ 'aliases' => [ 'locations', 'points' ],
+ 'default' => [],
+ 'islist' => true,
+ 'delimiter' => ';',
+ 'message' => 'semanticmaps-par-staticlocations',
+ ];
+
+ $params['showtitle'] = [
+ 'type' => 'boolean',
+ 'aliases' => 'show title',
+ 'default' => $smgQPShowTitle,
+ ];
+
+ $params['hidenamespace'] = [
+ 'type' => 'boolean',
+ 'aliases' => 'hide namespace',
+ 'default' => $smgQPHideNamespace,
+ ];
+
+ $params['template'] = [
+ 'default' => $smgQPTemplate,
+ ];
+
+ $params['userparam'] = [
+ 'default' => '',
+ ];
+
+ $params['activeicon'] = [
+ 'type' => 'string',
+ 'default' => '',
+ ];
+
+ $params['pagelabel'] = [
+ 'type' => 'boolean',
+ 'default' => false,
+ ];
+
+ $params['ajaxcoordproperty'] = [
+ 'default' => '',
+ ];
+
+ $params['ajaxquery'] = [
+ 'default' => '',
+ 'type' => 'string'
+ ];
+
+ // Messages:
+ // semanticmaps-par-staticlocations, semanticmaps-par-showtitle, semanticmaps-par-hidenamespace,
+ // semanticmaps-par-template, semanticmaps-par-userparam, semanticmaps-par-activeicon,
+ // semanticmaps-par-pagelabel, semanticmaps-par-ajaxcoordproperty semanticmaps-par-ajaxquery
+ foreach ( $params as $name => &$data ) {
+ if ( is_array( $data ) && !array_key_exists( 'message', $data ) ) {
+ $data['message'] = 'semanticmaps-par-' . $name;
+ }
+ }
+
+ return $params;
+ }
+}
diff --git a/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/QueryHandler.php b/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/QueryHandler.php
new file mode 100644
index 00000000..af4d2421
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMW/ResultPrinters/QueryHandler.php
@@ -0,0 +1,511 @@
+<?php
+
+namespace Maps\SemanticMW\ResultPrinters;
+
+use Html;
+use Linker;
+use Maps\Elements\Location;
+use Maps\MapsFunctions;
+use Maps\SemanticMW\DataValues\CoordinateValue;
+use SMWDataValue;
+use SMWDIGeoCoord;
+use SMWPrintRequest;
+use SMWQueryResult;
+use SMWResultArray;
+use SMWWikiPageValue;
+use Title;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class QueryHandler {
+
+ /**
+ * The global icon.
+ * @var string
+ */
+ public $icon = '';
+
+ /**
+ * The global text.
+ * @var string
+ */
+ public $text = '';
+
+ /**
+ * The global title.
+ * @var string
+ */
+ public $title = '';
+
+ private $queryResult;
+
+ private $outputMode;
+
+ /**
+ * The template to use for the text, or false if there is none.
+ * @var string|boolean false
+ */
+ private $template = false;
+
+ /**
+ * Should link targets be made absolute (instead of relative)?
+ * @var boolean
+ */
+ private $linkAbsolute;
+
+ /**
+ * A separator to use between the subject and properties in the text field.
+ * @var string
+ */
+ private $subjectSeparator = '<hr />';
+
+ /**
+ * Show the subject in the text or not?
+ * @var boolean
+ */
+ private $showSubject = true;
+
+ /**
+ * Hide the namespace or not.
+ * @var boolean
+ */
+ private $hideNamespace = false;
+
+ /**
+ * Defines which article names in the result are hyperlinked, all normally is the default
+ * none, subject, all
+ */
+ private $linkStyle = 'all';
+
+ /*
+ * Show headers (with links), show headers (just text) or hide them. show is default
+ * show, plain, hide
+ */
+ private $headerStyle = 'show';
+
+ /**
+ * Marker icon to show when marker equals active page
+ * @var string|null
+ */
+ private $activeIcon = null;
+
+ /**
+ * @var string
+ */
+ private $userParam = '';
+
+ public function __construct( SMWQueryResult $queryResult, int $outputMode, bool $linkAbsolute = false ) {
+ $this->queryResult = $queryResult;
+ $this->outputMode = $outputMode;
+ $this->linkAbsolute = $linkAbsolute;
+ }
+
+ public function setTemplate( string $template ) {
+ $this->template = $template === '' ? false : $template;
+ }
+
+ public function setUserParam( string $userParam ) {
+ $this->userParam = $userParam;
+ }
+
+ /**
+ * Sets the global icon.
+ */
+ public function setIcon( string $icon ) {
+ $this->icon = $icon;
+ }
+
+ /**
+ * Sets the global title.
+ */
+ public function setTitle( string $title ) {
+ $this->title = $title;
+ }
+
+ /**
+ * Sets the global text.
+ */
+ public function setText( string $text ) {
+ $this->text = $text;
+ }
+
+ public function setSubjectSeparator( string $subjectSeparator ) {
+ $this->subjectSeparator = $subjectSeparator;
+ }
+
+ public function setShowSubject( bool $showSubject ) {
+ $this->showSubject = $showSubject;
+ }
+
+ public function setLinkStyle( string $link ) {
+ $this->linkStyle = $link;
+ }
+
+ public function setHeaderStyle( string $headers ) {
+ $this->headerStyle = $headers;
+ }
+
+ /**
+ * @return Location[]
+ */
+ public function getLocations(): iterable {
+ while ( ( $row = $this->queryResult->getNext() ) !== false ) {
+ yield from $this->handlePageResult( $row );
+ }
+ }
+
+ /**
+ * @param SMWResultArray[] $row
+ * @return Location[]
+ */
+ private function handlePageResult( array $row ): array {
+ [ $title, $text ] = $this->getTitleAndText( $row[0] );
+ [ $locations, $properties ] = $this->getLocationsAndProperties( $row );
+
+ if ( $properties !== [] && $text !== '' ) {
+ $text .= $this->subjectSeparator;
+ }
+
+ $icon = $this->getLocationIcon( $row );
+
+ return $this->buildLocationsList(
+ $locations,
+ $text,
+ $icon,
+ $properties,
+ Title::newFromText( $title )
+ );
+ }
+
+ private function getTitleAndText( SMWResultArray $resultArray ): array {
+ while ( ( $dataValue = $resultArray->getNextDataValue() ) !== false ) {
+ if ( $dataValue instanceof SMWWikiPageValue ) {
+ return [
+ $dataValue->getLongText( $this->outputMode, null ),
+ $this->getResultSubjectText( $dataValue )
+ ];
+ }
+
+ if ( $dataValue->getTypeID() == '_str' ) {
+ return [
+ $dataValue->getLongText( $this->outputMode, null ),
+ $dataValue->getLongText( $this->outputMode, smwfGetLinker() )
+ ];
+ }
+ }
+
+ return [ '', '' ];
+ }
+
+ /**
+ * @param SMWResultArray[] $row
+ * @return array
+ */
+ private function getLocationsAndProperties( array $row ): array {
+ $locations = [];
+ $properties = [];
+
+ // Loop through all fields of the record.
+ foreach ( $row as $i => $resultArray ) {
+ if ( $i === 0 ) {
+ continue;
+ }
+
+ // Loop through all the parts of the field value.
+ while ( ( $dataValue = $resultArray->getNextDataValue() ) !== false ) {
+ if ( $dataValue instanceof \SMWRecordValue ) {
+ foreach ( $dataValue->getDataItems() as $dataItem ) {
+ if ( $dataItem instanceof \SMWDIGeoCoord ) {
+ $locations[] = $this->locationFromDataItem( $dataItem );
+ }
+ }
+ } elseif ( $dataValue instanceof CoordinateValue ) {
+ $locations[] = $this->locationFromDataItem( $dataValue->getDataItem() );
+ }
+ else {
+ $properties[] = $this->handleResultProperty(
+ $dataValue,
+ $resultArray->getPrintRequest()
+ );
+ }
+ }
+ }
+
+ return [ $locations, $properties ];
+ }
+
+ private function locationFromDataItem( SMWDIGeoCoord $dataItem ): Location {
+ return Location::newFromLatLon(
+ $dataItem->getLatitude(),
+ $dataItem->getLongitude()
+ );
+ }
+
+ /**
+ * Handles a SMWWikiPageValue subject value.
+ * Gets the plain text title and creates the HTML text with headers and the like.
+ *
+ * @param SMWWikiPageValue $object
+ *
+ * @return string
+ */
+ private function getResultSubjectText( SMWWikiPageValue $object ): string {
+ if ( !$this->showSubject ) {
+ return '';
+ }
+
+ $dataItem = $object->getDataItem();
+
+ if ( $this->showArticleLink() ) {
+ if ( $this->linkAbsolute ) {
+ $text = Html::element(
+ 'a',
+ [ 'href' => $dataItem->getTitle()->getFullUrl() ],
+ $this->hideNamespace ? $object->getText() : $dataItem->getTitle()->getFullText()
+ );
+ } else {
+ if ( $this->hideNamespace ) {
+ $text = $object->getShortHTMLText( smwfGetLinker() );
+ } else {
+ $text = $object->getLongHTMLText( smwfGetLinker() );
+ }
+ }
+ } else {
+ $text = $this->hideNamespace ? $object->getText() : $dataItem->getTitle()->getFullText();
+ }
+
+ return '<b>' . $text . '</b>';
+ }
+
+ private function showArticleLink() {
+ return $this->linkStyle !== 'none';
+ }
+
+ /**
+ * Handles a single property (SMWPrintRequest) to be displayed for a record (SMWDataValue).
+ */
+ private function handleResultProperty( SMWDataValue $object, SMWPrintRequest $printRequest ): string {
+ if ( $this->hasTemplate() ) {
+ if ( $object instanceof SMWWikiPageValue ) {
+ return $object->getDataItem()->getTitle()->getPrefixedText();
+ }
+
+ return $object->getLongText( SMW_OUTPUT_WIKI, null );
+ }
+
+ $propertyName = $this->getPropertyName( $printRequest );
+ return $propertyName . ( $propertyName === '' ? '' : ': ' ) . $this->getPropertyValue( $object );
+ }
+
+ private function getPropertyName( SMWPrintRequest $printRequest ): string {
+ if ( $this->headerStyle === 'hide' ) {
+ return '';
+ }
+
+ if ( $this->linkAbsolute ) {
+ $titleText = $printRequest->getText( null );
+ $t = Title::newFromText( $titleText, SMW_NS_PROPERTY );
+
+ if ( $t instanceof Title && $t->exists() ) {
+ return Html::element(
+ 'a',
+ [ 'href' => $t->getFullUrl() ],
+ $printRequest->getHTMLText( null )
+ );
+ }
+
+ return $titleText;
+ }
+
+ return $printRequest->getHTMLText( $this->getPropertyLinker() );
+ }
+
+ private function getPropertyLinker(): ?Linker {
+ return $this->headerStyle === 'show' && $this->linkStyle !== 'none' ? smwfGetLinker() : null;
+ }
+
+ private function getValueLinker(): ?Linker {
+ return $this->linkStyle === 'all' ? smwfGetLinker() : null;
+ }
+
+ private function getPropertyValue( SMWDataValue $object ): string {
+ if ( !$this->linkAbsolute ) {
+ return $object->getLongHTMLText(
+ $this->getValueLinker()
+ );
+ }
+
+ if ( $this->hasPage( $object ) ) {
+ return Html::element(
+ 'a',
+ [
+ 'href' => Title::newFromText(
+ $object->getLongText( $this->outputMode, null ),
+ NS_MAIN
+ )->getFullUrl()
+ ],
+ $object->getLongText( $this->outputMode, null )
+ );
+ }
+
+ return $object->getLongText( $this->outputMode, null );
+ }
+
+ private function hasPage( SMWDataValue $object ): bool {
+ $hasPage = $object->getTypeID() == '_wpg';
+
+ if ( $hasPage ) {
+ $t = Title::newFromText( $object->getLongText( $this->outputMode, null ), NS_MAIN );
+ $hasPage = $t !== null && $t->exists();
+ }
+
+ return $hasPage;
+ }
+
+ private function hasTemplate() {
+ return is_string( $this->template );
+ }
+
+ /**
+ * Get the icon for a row.
+ *
+ * @param array $row
+ *
+ * @return string
+ */
+ private function getLocationIcon( array $row ) {
+ $icon = '';
+ $legendLabels = [];
+
+ //Check for activeicon parameter
+
+ if ( $this->shouldGetActiveIconUrlFor( $row[0]->getResultSubject()->getTitle() ) ) {
+ $icon = MapsFunctions::getFileUrl( $this->activeIcon );
+ }
+
+ // Look for display_options field, which can be set by Semantic Compound Queries
+ // the location of this field changed in SMW 1.5
+ $display_location = method_exists( $row[0], 'getResultSubject' ) ? $row[0]->getResultSubject() : $row[0];
+
+ if ( property_exists( $display_location, 'display_options' ) && is_array(
+ $display_location->display_options
+ ) ) {
+ $display_options = $display_location->display_options;
+ if ( array_key_exists( 'icon', $display_options ) ) {
+ $icon = $display_options['icon'];
+
+ // This is somewhat of a hack - if a legend label has been set, we're getting it for every point, instead of just once per icon
+ if ( array_key_exists( 'legend label', $display_options ) ) {
+
+ $legend_label = $display_options['legend label'];
+
+ if ( !array_key_exists( $icon, $legendLabels ) ) {
+ $legendLabels[$icon] = $legend_label;
+ }
+ }
+ }
+ } // Icon can be set even for regular, non-compound queries If it is, though, we have to translate the name into a URL here
+ elseif ( $this->icon !== '' ) {
+ $icon = MapsFunctions::getFileUrl( $this->icon );
+ }
+
+ return $icon;
+ }
+
+ private function shouldGetActiveIconUrlFor( Title $title ) {
+ global $wgTitle;
+
+ return isset( $this->activeIcon ) && is_object( $wgTitle )
+ && $wgTitle->equals( $title );
+ }
+
+ /**
+ * Builds a set of locations with the provided title, text and icon.
+ *
+ * @param Location[] $locations
+ * @param string $text
+ * @param string $icon
+ * @param array $properties
+ * @param Title|null $title
+ *
+ * @return Location[]
+ */
+ private function buildLocationsList( array $locations, $text, $icon, array $properties, Title $title = null ): array {
+ if ( !$this->hasTemplate() ) {
+ $text .= implode( '<br />', $properties );
+ }
+
+ $titleOutput = $this->getTitleOutput( $title );
+
+ foreach ( $locations as &$location ) {
+ if ( $this->hasTemplate() ) {
+ $segments = array_merge(
+ [
+ $this->template,
+ 'title=' . $titleOutput,
+ 'latitude=' . $location->getCoordinates()->getLatitude(),
+ 'longitude=' . $location->getCoordinates()->getLongitude(),
+ 'userparam=' . $this->userParam
+ ],
+ $properties
+ );
+
+ $text .= $this->getParser()->recursiveTagParseFully(
+ '{{' . implode( '|', $segments ) . '}}'
+ );
+ }
+
+ $location->setTitle( $titleOutput );
+ $location->setText( $text );
+ $location->setIcon( trim( $icon ) );
+ }
+
+ return $locations;
+ }
+
+ private function getTitleOutput( Title $title = null ) {
+ if ( $title === null ) {
+ return '';
+ }
+
+ return $this->hideNamespace ? $title->getText() : $title->getFullText();
+ }
+
+ /**
+ * @return \Parser
+ */
+ private function getParser() {
+ return $GLOBALS['wgParser'];
+ }
+
+ /**
+ * @return boolean
+ */
+ public function getHideNamespace() {
+ return $this->hideNamespace;
+ }
+
+ /**
+ * @param boolean $hideNamespace
+ */
+ public function setHideNamespace( $hideNamespace ) {
+ $this->hideNamespace = $hideNamespace;
+ }
+
+ /**
+ * @return string
+ */
+ public function getActiveIcon() {
+ return $this->activeIcon;
+ }
+
+ /**
+ * @param string $activeIcon
+ */
+ public function setActiveIcon( $activeIcon ) {
+ $this->activeIcon = $activeIcon;
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/AreaDescription.php b/www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/AreaDescription.php
new file mode 100644
index 00000000..e0f62d3b
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/AreaDescription.php
@@ -0,0 +1,146 @@
+<?php
+
+namespace Maps\SemanticMW\ValueDescriptions;
+
+use DatabaseBase;
+use DataValues\Geo\Values\LatLongValue;
+use InvalidArgumentException;
+use Maps\GeoFunctions;
+use Maps\Presentation\MapsDistanceParser;
+use SMW\DataValueFactory;
+use SMW\DIProperty;
+use SMW\Query\Language\ValueDescription;
+use SMWDataItem;
+use SMWDIGeoCoord;
+use SMWThingDescription;
+
+/**
+ * Description of a geographical area defined by a coordinates set and a distance to the bounds.
+ * The bounds are a 'rectangle' (but bend due to the earths curvature), as the resulting query
+ * would otherwise be to resource intensive.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class AreaDescription extends ValueDescription {
+
+ /**
+ * @var SMWDIGeoCoord
+ */
+ private $center;
+
+ private $radius;
+
+ public function __construct( SMWDataItem $areaCenter, int $comparator, string $radius, DIProperty $property = null ) {
+ if ( !( $areaCenter instanceof SMWDIGeoCoord ) ) {
+ throw new InvalidArgumentException( '$areaCenter needs to be a SMWDIGeoCoord' );
+ }
+
+ parent::__construct( $areaCenter, $property, $comparator );
+
+ $this->center = $areaCenter;
+ $this->radius = $radius;
+ }
+
+ /**
+ * @see Description::prune
+ */
+ public function prune( &$maxsize, &$maxdepth, &$log ) {
+ if ( ( $maxsize < $this->getSize() ) || ( $maxdepth < $this->getDepth() ) ) {
+ $log[] = $this->getQueryString();
+
+ $result = new SMWThingDescription();
+ $result->setPrintRequests( $this->getPrintRequests() );
+
+ return $result;
+ }
+
+ $maxsize = $maxsize - $this->getSize();
+ $maxdepth = $maxdepth - $this->getDepth();
+
+ return $this;
+ }
+
+ public function getQueryString( $asValue = false ) {
+ $centerString = DataValueFactory::getInstance()->newDataValueByItem(
+ $this->center,
+ $this->getProperty()
+ )->getWikiValue();
+
+ $queryString = "$centerString ({$this->radius})";
+
+ return $asValue ? $queryString : "[[$queryString]]";
+ }
+
+ /**
+ * @see Description::getSQLCondition
+ *
+ * FIXME: store specific code should be in the store component
+ *
+ * @param string $tableName
+ * @param array $fieldNames
+ * @param DatabaseBase $dbs
+ *
+ * @return string|false
+ */
+ public function getSQLCondition( $tableName, array $fieldNames, DatabaseBase $dbs ) {
+ if ( $this->center->getDIType() != SMWDataItem::TYPE_GEO ) {
+ throw new \LogicException( 'Constructor should have prevented this' );
+ }
+
+ if ( !$this->comparatorIsSupported() ) {
+ return false;
+ }
+
+ $bounds = $this->getBoundingBox();
+
+ $north = $dbs->addQuotes( $bounds['north'] );
+ $east = $dbs->addQuotes( $bounds['east'] );
+ $south = $dbs->addQuotes( $bounds['south'] );
+ $west = $dbs->addQuotes( $bounds['west'] );
+
+ $isEq = $this->getComparator() == SMW_CMP_EQ;
+
+ $smallerThen = $isEq ? '<' : '>=';
+ $biggerThen = $isEq ? '>' : '<=';
+ $joinCond = $isEq ? 'AND' : 'OR';
+
+ $conditions = [];
+
+ $conditions[] = "{$tableName}.$fieldNames[1] $smallerThen $north";
+ $conditions[] = "{$tableName}.$fieldNames[1] $biggerThen $south";
+ $conditions[] = "{$tableName}.$fieldNames[2] $smallerThen $east";
+ $conditions[] = "{$tableName}.$fieldNames[2] $biggerThen $west";
+
+ return implode( " $joinCond ", $conditions );
+ }
+
+ private function comparatorIsSupported(): bool {
+ return $this->getComparator() === SMW_CMP_EQ || $this->getComparator() === SMW_CMP_NEQ;
+ }
+
+ /**
+ * @return float[] An associative array containing the limits with keys north, east, south and west.
+ */
+ public function getBoundingBox(): array {
+ $center = new LatLongValue(
+ $this->center->getLatitude(),
+ $this->center->getLongitude()
+ );
+
+ $radiusInMeters = MapsDistanceParser::parseDistance( $this->radius ); // TODO: this can return false
+
+ $north = GeoFunctions::findDestination( $center, 0, $radiusInMeters );
+ $east = GeoFunctions::findDestination( $center, 90, $radiusInMeters );
+ $south = GeoFunctions::findDestination( $center, 180, $radiusInMeters );
+ $west = GeoFunctions::findDestination( $center, 270, $radiusInMeters );
+
+ return [
+ 'north' => $north['lat'],
+ 'east' => $east['lon'],
+ 'south' => $south['lat'],
+ 'west' => $west['lon'],
+ ];
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/CoordinateDescription.php b/www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/CoordinateDescription.php
new file mode 100644
index 00000000..815a540f
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMW/ValueDescriptions/CoordinateDescription.php
@@ -0,0 +1,74 @@
+<?php
+
+namespace Maps\SemanticMW\ValueDescriptions;
+
+use DatabaseBase;
+use SMW\DataValueFactory;
+use SMW\Query\Language\ValueDescription;
+use SMWDIGeoCoord;
+
+/**
+ * Description of one data value of type Geographical Coordinates.
+ *
+ * @author Jeroen De Dauw
+ */
+class CoordinateDescription extends ValueDescription {
+
+ public function getQueryString( $asValue = false ) {
+ $queryString = DataValueFactory::getInstance()->newDataValueByItem(
+ $this->getDataItem(),
+ $this->getProperty()
+ )->getWikiValue();
+
+ return $asValue ? $queryString : "[[$queryString]]";
+ }
+
+ /**
+ * @see SMWDescription::getSQLCondition
+ *
+ * FIXME: store specific code should be in the store component
+ *
+ * @param string $tableName
+ * @param array $fieldNames
+ * @param DatabaseBase $dbs
+ *
+ * @return string|false
+ */
+ public function getSQLCondition( $tableName, array $fieldNames, DatabaseBase $dbs ) {
+ $dataItem = $this->getDataItem();
+
+ // Only execute the query when the description's type is geographical coordinates,
+ // the description is valid, and the near comparator is used.
+ if ( $dataItem instanceof SMWDIGeoCoord ) {
+ switch ( $this->getComparator() ) {
+ case SMW_CMP_EQ:
+ $comparator = '=';
+ break;
+ case SMW_CMP_LEQ:
+ $comparator = '<=';
+ break;
+ case SMW_CMP_GEQ:
+ $comparator = '>=';
+ break;
+ case SMW_CMP_NEQ:
+ $comparator = '!=';
+ break;
+ default:
+ return false;
+ }
+
+ $lat = $dbs->addQuotes( $dataItem->getLatitude() );
+ $lon = $dbs->addQuotes( $dataItem->getLongitude() );
+
+ $conditions = [];
+
+ $conditions[] = "{$tableName}.$fieldNames[1] $comparator $lat";
+ $conditions[] = "{$tableName}.$fieldNames[2] $comparator $lon";
+
+ return implode( ' AND ', $conditions );
+ }
+
+ return false;
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/src/SemanticMaps.php b/www/wiki/extensions/Maps/src/SemanticMaps.php
new file mode 100644
index 00000000..8d48dc56
--- /dev/null
+++ b/www/wiki/extensions/Maps/src/SemanticMaps.php
@@ -0,0 +1,74 @@
+<?php
+
+namespace Maps;
+
+use Maps\SemanticMW\ResultPrinters\KmlPrinter;
+use Maps\SemanticMW\ResultPrinters\MapPrinter;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class SemanticMaps {
+
+ private $mwGlobals;
+
+ private function __construct( array &$mwGlobals ) {
+ $this->mwGlobals =& $mwGlobals;
+ }
+
+ public static function newFromMediaWikiGlobals( array &$mwGlobals ) {
+ return new self( $mwGlobals );
+ }
+
+ public function initExtension() {
+ // Hook for initializing the Geographical Data types.
+ $this->mwGlobals['wgHooks']['SMW::DataType::initTypes'][] = 'Maps\MediaWiki\SemanticMapsHooks::initGeoDataTypes';
+
+ // Hook for defining the default query printer for queries that ask for geographical coordinates.
+ $this->mwGlobals['wgHooks']['SMWResultFormat'][] = 'Maps\MediaWiki\SemanticMapsHooks::addGeoCoordsDefaultFormat';
+
+ // Hook for adding a Semantic Maps links to the Admin Links extension.
+ $this->mwGlobals['wgHooks']['AdminLinks'][] = 'Maps\MediaWiki\SemanticMapsHooks::addToAdminLinks';
+
+ $this->registerGoogleMaps();
+ $this->registerLeaflet();
+
+ $this->mwGlobals['smwgResultFormats']['kml'] = KmlPrinter::class;
+
+ $this->mwGlobals['smwgResultAliases'][$this->mwGlobals['egMapsDefaultService']][] = 'map';
+ MapPrinter::registerDefaultService( $this->mwGlobals['egMapsDefaultService'] );
+
+ // Internationalization
+ $this->mwGlobals['wgMessagesDirs']['SemanticMaps'] = __DIR__ . '/i18n';
+ }
+
+ private function registerGoogleMaps() {
+ // TODO: inject
+ $services = MapsFactory::globalInstance()->getMappingServices();
+
+ if ( $services->nameIsKnown( 'googlemaps3' ) ) {
+ $googleMaps = $services->getService( 'googlemaps3' );
+
+ MapPrinter::registerService( $googleMaps );
+
+ $this->mwGlobals['smwgResultFormats'][$googleMaps->getName()] = MapPrinter::class;
+ $this->mwGlobals['smwgResultAliases'][$googleMaps->getName()] = $googleMaps->getAliases();
+ }
+ }
+
+ private function registerLeaflet() {
+ // TODO: inject
+ $services = MapsFactory::globalInstance()->getMappingServices();
+
+ if ( $services->nameIsKnown( 'leaflet' ) ) {
+ $leaflet = $services->getService( 'leaflet' );
+
+ MapPrinter::registerService( $leaflet );
+
+ $this->mwGlobals['smwgResultFormats'][$leaflet->getName()] = MapPrinter::class;
+ $this->mwGlobals['smwgResultAliases'][$leaflet->getName()] = $leaflet->getAliases();
+ }
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/DataAccess/MediaWikiFileUrlFinderTest.php b/www/wiki/extensions/Maps/tests/Integration/DataAccess/MediaWikiFileUrlFinderTest.php
new file mode 100644
index 00000000..648c8c94
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/DataAccess/MediaWikiFileUrlFinderTest.php
@@ -0,0 +1,33 @@
+<?php
+
+namespace Maps\Tests\Integration\DataAccess;
+
+use Maps\DataAccess\MediaWikiFileUrlFinder;
+use Maps\FileUrlFinder;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\DataAccess\MediaWikiFileUrlFinder
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MediaWikiFileUrlFinderTest extends TestCase {
+
+ /**
+ * @var FileUrlFinder
+ */
+ private $urlFinder;
+
+ public function setUp() {
+ $this->urlFinder = new MediaWikiFileUrlFinder();
+ }
+
+ public function testGivenUrl_urlIsReturnedAsProvided() {
+ $this->assertSame(
+ 'http://example.com/such',
+ $this->urlFinder->getUrlForFileName( 'http://example.com/such' )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/InitializationTest.php b/www/wiki/extensions/Maps/tests/Integration/InitializationTest.php
new file mode 100644
index 00000000..5d94e291
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/InitializationTest.php
@@ -0,0 +1,20 @@
+<?php
+
+namespace Maps\Tests\Integration;
+
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class InitializationTest extends TestCase {
+
+ public function testVersionConstantIsDefined() {
+ $this->assertInternalType( 'string', Maps_VERSION );
+ $this->assertInternalType( 'string', SM_VERSION );
+ $this->assertSame( Maps_VERSION, SM_VERSION );
+ $this->assertNotEmpty( Maps_VERSION );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/MapsDistanceParserTest.php b/www/wiki/extensions/Maps/tests/Integration/MapsDistanceParserTest.php
new file mode 100644
index 00000000..e5b04787
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MapsDistanceParserTest.php
@@ -0,0 +1,177 @@
+<?php
+
+namespace Maps\Tests\Integration;
+
+use Maps\Presentation\MapsDistanceParser;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers MapsDistanceParser
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsDistanceParserTest extends TestCase {
+
+ public static $distances = [
+ '1' => 1,
+ '1m' => 1,
+ '1 m' => 1,
+ ' 1 m ' => 1,
+ '1.1' => 1.1,
+ '1,1' => 1.1,
+ '1 km' => 1000,
+ '42 km' => 42000,
+ '4.2 km' => 4200,
+ '4,20km' => 4200,
+ '1 mile' => 1609.344,
+ '10 nauticalmiles' => 18520,
+ '1.0nautical mile' => 1852,
+ ];
+ public static $formatTests = [
+ 'm' => [
+ '1 m' => 1,
+ '1000 m' => 1000.00,
+ '42.42 m' => 42.42,
+ '42.4242 m' => 42.4242,
+ ],
+ 'km' => [
+ //'0.001 km' => 1,
+ '1 km' => 1000,
+ '4.24 km' => 4242,
+ ],
+ 'kilometers' => [
+ '0.001 kilometers' => 1,
+ '1 kilometers' => 1000,
+ '4.24 kilometers' => 4242,
+ ],
+ ];
+ /**
+ * Invalid distances.
+ *
+ * @var array
+ */
+ public static $fakeDistances = [
+ 'IN YOUR CODE, BEING TOTALLY RIDICULOUS',
+ '0x20 km',
+ 'km 42',
+ '42 42 km',
+ '42 km km',
+ '42 foo',
+ '3.4.2 km'
+ ];
+
+ public function setUp() {
+ if ( !defined( 'MEDIAWIKI' ) ) {
+ $this->markTestSkipped( 'MediaWiki is not available' );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::parseDistance()
+ */
+ public function testParseDistance() {
+ foreach ( self::$distances as $rawValue => $parsedValue ) {
+ $this->assertEquals(
+ $parsedValue,
+ MapsDistanceParser::parseDistance( $rawValue ),
+ "'$rawValue' was not parsed to '$parsedValue':"
+ );
+ }
+
+ foreach ( self::$fakeDistances as $fakeDistance ) {
+ $this->assertFalse(
+ MapsDistanceParser::parseDistance( $fakeDistance ),
+ "'$fakeDistance' should not be recognized:"
+ );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::formatDistance()
+ */
+ public function testFormatDistance() {
+ foreach ( self::$formatTests['km'] as $rawValue => $parsedValue ) {
+ $this->assertEquals(
+ $rawValue,
+ MapsDistanceParser::formatDistance( $parsedValue, 'km' ),
+ "'$parsedValue' was not formatted to '$rawValue':"
+ );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::parseAndFormat()
+ */
+ public function testParseAndFormat() {
+ $conversions = [
+ '42 km' => '42000 m'
+ ];
+
+ foreach ( array_merge( $conversions, array_reverse( $conversions ) ) as $source => $target ) {
+ global $wgContLang;
+ $unit = explode( ' ', $target, 2 );
+ $unit = $unit[1];
+ $this->assertEquals(
+ $wgContLang->formatNum( $target ),
+ MapsDistanceParser::parseAndFormat( $source, $unit ),
+ "'$source' was not parsed and formatted to '$target':"
+ );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::isDistance()
+ */
+ public function testIsDistance() {
+ foreach ( self::$fakeDistances as $fakeDistance ) {
+ $this->assertFalse(
+ MapsDistanceParser::isDistance( $fakeDistance ),
+ "'$fakeDistance' should not be recognized:"
+ );
+ }
+
+ foreach ( self::$distances as $distance ) {
+ $this->assertTrue( MapsDistanceParser::isDistance( $distance ), "'$distance' was not be recognized:" );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::getUnitRatio()
+ */
+ public function testGetUnitRatio() {
+ foreach ( $GLOBALS['egMapsDistanceUnits'] as $unit => $ratio ) {
+ $r = MapsDistanceParser::getUnitRatio( $unit );
+ $this->assertEquals( $ratio, $r, "The ratio for '$unit' should be '$ratio' but was '$r'" );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::getValidUnit()
+ */
+ public function testGetValidUnit() {
+ foreach ( $GLOBALS['egMapsDistanceUnits'] as $unit => $ratio ) {
+ $u = MapsDistanceParser::getValidUnit( $unit );
+ $this->assertEquals( $unit, $u, "The valid unit for '$unit' should be '$unit' but was '$u'" );
+ }
+
+ global $egMapsDistanceUnit;
+
+ foreach ( [ '0', 'swfwdffdhy', 'dxwgdrfh' ] as $unit ) {
+ $u = MapsDistanceParser::getValidUnit( $unit );
+ $this->assertEquals(
+ $egMapsDistanceUnit,
+ $u,
+ "The valid unit for '$unit' should be '$egMapsDistanceUnit' but was '$u'"
+ );
+ }
+ }
+
+ /**
+ * Tests Maps\Presentation\MapsDistanceParser::getUnits()
+ */
+ public function testGetUnits() {
+ $this->assertEquals( array_keys( $GLOBALS['egMapsDistanceUnits'] ), MapsDistanceParser::getUnits() );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/MapsMapperTest.php b/www/wiki/extensions/Maps/tests/Integration/MapsMapperTest.php
new file mode 100644
index 00000000..4760db5f
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MapsMapperTest.php
@@ -0,0 +1,42 @@
+<?php
+
+namespace Maps\Tests\Integration;
+
+use Maps\MapsFunctions;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers MapsFunctions
+ *
+ * @licence GNU GPL v2+
+ * @author Peter Grassberger < petertheone@gmail.com >
+ */
+class MapsMapperTest extends TestCase {
+
+ public function setUp() {
+ if ( !defined( 'MEDIAWIKI' ) ) {
+ $this->markTestSkipped( 'MediaWiki is not available' );
+ }
+ }
+
+ public function imageUrlProvider() {
+ return [
+ [ 'markerImage.png', 'markerImage.png' ],
+ [ '/w/images/c/ce/Green_marker.png', '/w/images/c/ce/Green_marker.png' ],
+ [
+ '//semantic-mediawiki.org/w/images/c/ce/Green_marker.png',
+ '//semantic-mediawiki.org/w/images/c/ce/Green_marker.png'
+ ],
+ [ 'Cat2.jpg', 'Cat2.jpg' ],
+ ];
+ }
+
+ /**
+ * Tests MapsMapperTest::getFileUrl()
+ *
+ * @dataProvider imageUrlProvider
+ */
+ public function testGetFileUrl( $file, $expected ) {
+ $this->assertSame( $expected, MapsFunctions::getFileUrl( $file ) );
+ }
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/CoordinatesTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/CoordinatesTest.php
new file mode 100644
index 00000000..9ee324fe
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/CoordinatesTest.php
@@ -0,0 +1,125 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\MediaWiki\ParserHooks\CoordinatesFunction;
+use ParamProcessor\ParamDefinition;
+
+/**
+ * @covers CoordinatesFunction
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CoordinatesTest extends ParserHookTest {
+
+ /**
+ * @see ParserHookTest::parametersProvider
+ */
+ public function parametersProvider() {
+ $paramLists = [];
+
+ $paramLists[] = [
+ [
+ 'location' => '4,2',
+ 'format' => 'dms',
+ 'directional' => 'no',
+ ],
+ '4° 0\' 0.00", 2° 0\' 0.00"'
+ ];
+
+ $paramLists[] = [
+ [
+ 'location' => '55 S, 37.6176330 W',
+ 'format' => 'dms',
+ 'directional' => 'no',
+ ],
+ '-55° 0\' 0.00", -37° 37\' 3.48"'
+ ];
+
+ $paramLists[] = [
+ [
+ 'location' => '4,2',
+ 'format' => 'float',
+ 'directional' => 'no',
+ ],
+ '4, 2'
+ ];
+
+ $paramLists[] = [
+ [
+ 'location' => '-4,-2',
+ 'format' => 'float',
+ 'directional' => 'yes',
+ ],
+ '4 S, 2 W'
+ ];
+
+ $paramLists[] = [
+ [
+ 'location' => '55 S, 37.6176330 W',
+ 'directional' => 'yes',
+ ],
+ '55° 0\' 0.00" S, 37° 37\' 3.48" W'
+ ];
+
+ return $paramLists;
+ }
+
+ /**
+ * @see ParserHookTest::processingProvider
+ */
+ public function processingProvider() {
+ $definitions = ParamDefinition::getCleanDefinitions( $this->getInstance()->getParamDefinitions() );
+ $argLists = [];
+
+ $values = [
+ 'location' => '4,2',
+ ];
+
+ $expected = [
+ 'location' => new LatLongValue( 4, 2 ),
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ $values = [
+ 'location' => '4,2',
+ 'directional' => $definitions['directional']->getDefault() ? 'no' : 'yes',
+ 'format' => 'dd',
+ ];
+
+ $expected = [
+ 'location' => new LatLongValue( 4, 2 ),
+ 'directional' => !$definitions['directional']->getDefault(),
+ 'format' => 'dd',
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ $values = [
+ 'location' => '4,2',
+ 'directional' => $definitions['directional']->getDefault() ? 'NO' : 'YES',
+ 'format' => ' DD ',
+ ];
+
+ $expected = [
+ 'location' => new LatLongValue( 4, 2 ),
+ 'directional' => !$definitions['directional']->getDefault(),
+ 'format' => 'dd',
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ return $argLists;
+ }
+
+ /**
+ * @see ParserHookTest::getInstance
+ */
+ protected function getInstance() {
+ return new \Maps\MediaWiki\ParserHooks\CoordinatesFunction();
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/DistanceTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/DistanceTest.php
new file mode 100644
index 00000000..3e3889c8
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/DistanceTest.php
@@ -0,0 +1,91 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use Maps\MediaWiki\ParserHooks\DistanceFunction;
+
+/**
+ * @covers DistanceFunction
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class DistanceTest extends ParserHookTest {
+
+ private $distances = [
+ '42' => 42,
+ '42m' => 42,
+ '42 m' => 42,
+ '42 km' => 42000,
+ '4.2 km' => 4200,
+ '4.2 m' => 4.2,
+ ];
+
+ /**
+ * @see ParserHookTest::parametersProvider
+ */
+ public function parametersProvider() {
+ $paramLists = [];
+
+ foreach ( array_keys( $this->distances ) as $distance ) {
+ $paramLists[] = [ 'distance' => (string)$distance ];
+ }
+
+ return $this->arrayWrap( $paramLists );
+ }
+
+ /**
+ * @see ParserHookTest::processingProvider
+ */
+ public function processingProvider() {
+ $argLists = [];
+
+ foreach ( $this->distances as $input => $output ) {
+ $values = [
+ 'distance' => (string)$input,
+ ];
+
+ $expected = [
+ 'distance' => $output,
+ ];
+
+ $argLists[] = [ $values, $expected ];
+ }
+
+ $values = [
+ 'distance' => '42m',
+ 'unit' => 'km',
+ 'decimals' => '1',
+ ];
+
+ $expected = [
+ 'distance' => 42,
+ 'unit' => 'km',
+ 'decimals' => 1,
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ $values = [
+ 'distance' => '42m',
+ 'unit' => '~=[,,_,,]:3',
+ 'decimals' => 'foobar',
+ ];
+
+ $expected = [
+ 'distance' => 42,
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ return $argLists;
+ }
+
+ /**
+ * @see ParserHookTest::getInstance
+ */
+ protected function getInstance() {
+ return new \Maps\MediaWiki\ParserHooks\DistanceFunction();
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/FinddestinationTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/FinddestinationTest.php
new file mode 100644
index 00000000..811d16e2
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/FinddestinationTest.php
@@ -0,0 +1,94 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use DataValues\Geo\Parsers\LatLongParser;
+use Maps\Elements\Location;
+use Maps\MediaWiki\ParserHooks\FindDestinationFunction;
+
+/**
+ * @covers FindDestinationFunction
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class FinddestinationTest extends ParserHookTest {
+
+ /**
+ * @var string[]
+ */
+ private $locations = [
+ '4,2',
+ '4.2,-42',
+ ];
+
+ private $bearings = [
+ 1,
+ 42,
+ -42,
+ 0,
+ 4.2,
+ ];
+
+ private $distances = [
+ '42' => 42,
+ '0' => 0,
+ '42 m' => 42,
+ '42 km' => 42000,
+ '4.2 km' => 4200,
+ ];
+
+ /**
+ * @see ParserHookTest::parametersProvider
+ */
+ public function parametersProvider() {
+ $paramLists = [];
+
+ $paramLists[] = [
+ 'location' => '4,2',
+ 'bearing' => '1',
+ 'distance' => '42 km'
+ ];
+
+ return $this->arrayWrap( $paramLists );
+ }
+
+ /**
+ * @see ParserHookTest::processingProvider
+ */
+ public function processingProvider() {
+ $argLists = [];
+
+ $coordinateParser = new LatLongParser();
+
+ foreach ( $this->distances as $distance => $expectedDistance ) {
+ foreach ( $this->bearings as $bearing ) {
+ foreach ( $this->locations as $locationString ) {
+ $values = [
+ 'distance' => (string)$distance,
+ 'bearing' => (string)$bearing,
+ 'location' => (string)$locationString,
+ ];
+
+ $expected = [
+ 'distance' => $expectedDistance,
+ 'bearing' => (float)$bearing,
+ 'location' => new Location( $coordinateParser->parse( $locationString )->getValue() ),
+ ];
+
+ $argLists[] = [ $values, $expected ];
+ }
+ }
+ }
+
+ return $argLists;
+ }
+
+ /**
+ * @see ParserHookTest::getInstance
+ */
+ protected function getInstance() {
+ return new \Maps\MediaWiki\ParserHooks\FindDestinationFunction();
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeocodeTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeocodeTest.php
new file mode 100644
index 00000000..0469650c
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeocodeTest.php
@@ -0,0 +1,64 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoders\InMemoryGeocoder;
+use Maps\MediaWiki\ParserHooks\GeocodeFunction;
+
+/**
+ * @covers GeocodeFunction
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class GeocodeTest extends ParserHookTest {
+
+ /**
+ * @see ParserHookTest::parametersProvider
+ */
+ public function parametersProvider() {
+ $paramLists = [];
+
+ $paramLists[] = [ 'location' => 'New York', '4, 2' ];
+ $paramLists[] = [ 'location' => 'Brussels', '2, 3' ];
+ $paramLists[] = [ 'location' => 'I am a tomato', 'Geocoding failed' ];
+
+ return $this->arrayWrap( $paramLists );
+ }
+
+ /**
+ * @see ParserHookTest::processingProvider
+ */
+ public function processingProvider() {
+ $argLists = [];
+
+ $argLists[] = [
+ [
+ 'location' => '4,2',
+ 'directional' => 'yes',
+ ],
+ [
+ 'location' => '4,2',
+ 'directional' => true,
+ ]
+ ];
+
+ return $argLists;
+ }
+
+ /**
+ * @see ParserHookTest::getInstance
+ */
+ protected function getInstance() {
+ return new \Maps\MediaWiki\ParserHooks\GeocodeFunction(
+ new InMemoryGeocoder(
+ [
+ 'New York' => new LatLongValue( 4, 2 ),
+ 'Brussels' => new LatLongValue( 2, 3 ),
+ ]
+ )
+ );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeodistanceTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeodistanceTest.php
new file mode 100644
index 00000000..59489371
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/GeodistanceTest.php
@@ -0,0 +1,81 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\Elements\Location;
+use Maps\MediaWiki\ParserHooks\GeoDistanceFunction;
+
+/**
+ * @covers GeoDistanceFunction
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class GeodistanceTest extends ParserHookTest {
+
+ /**
+ * @see ParserHookTest::parametersProvider
+ */
+ public function parametersProvider() {
+ $paramLists = [];
+
+ $paramLists[] = [
+ 'location1' => '4,2',
+ 'location2' => '42,0',
+ ];
+
+ $paramLists[] = [
+ '4,2',
+ '42,0',
+ ];
+
+ return $this->arrayWrap( $paramLists );
+ }
+
+ /**
+ * @see ParserHookTest::processingProvider
+ * @since 3.0
+ * @return array
+ */
+ public function processingProvider() {
+ $argLists = [];
+
+ $values = [
+ 'location1' => '4,2',
+ 'location2' => '42,0',
+ ];
+
+ $expected = [
+ 'location1' => new Location( new LatLongValue( 4, 2 ) ),
+ 'location2' => new Location( new LatLongValue( 42, 0 ) ),
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ $values = [
+ 'location1' => '4,2',
+ 'location2' => '42,0',
+ 'unit' => '~=[,,_,,]:3',
+ 'decimals' => '1',
+ ];
+
+ $expected = [
+ 'location1' => new Location( new LatLongValue( 4, 2 ) ),
+ 'location2' => new Location( new LatLongValue( 42, 0 ) ),
+ 'decimals' => 1,
+ ];
+
+ $argLists[] = [ $values, $expected ];
+
+ return $argLists;
+ }
+
+ /**
+ * @see ParserHookTest::getInstance
+ */
+ protected function getInstance() {
+ return new \Maps\MediaWiki\ParserHooks\GeoDistanceFunction();
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/MapsDocTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/MapsDocTest.php
new file mode 100644
index 00000000..96a06ca7
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/MapsDocTest.php
@@ -0,0 +1,54 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use Maps\MediaWiki\ParserHooks\MapsDocFunction;
+
+/**
+ * @covers MapsDocFunction
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapsDocTest extends ParserHookTest {
+
+ /**
+ * @see ParserHookTest::parametersProvider
+ */
+ public function parametersProvider() {
+ $paramLists = [];
+
+ $paramLists[] = [];
+
+ return $this->arrayWrap( $paramLists );
+ }
+
+ /**
+ * @see ParserHookTest::processingProvider
+ */
+ public function processingProvider() {
+ $argLists = [];
+
+ $values = [ 'service' => 'googlemaps3' ];
+
+ $expected = [ 'service' => 'googlemaps3' ];
+
+ $argLists[] = [ $values, $expected ];
+
+ $values = [ 'service' => 'GOOGLEmaps3' ];
+
+ $expected = [ 'service' => 'googlemaps3' ];
+
+ $argLists[] = [ $values, $expected ];
+
+ return $argLists;
+ }
+
+ /**
+ * @see ParserHookTest::getInstance
+ */
+ protected function getInstance() {
+ return new \Maps\MediaWiki\ParserHooks\MapsDocFunction();
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/ParserHookTest.php b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/ParserHookTest.php
new file mode 100644
index 00000000..eeb19d61
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/MediaWiki/ParserHooks/ParserHookTest.php
@@ -0,0 +1,133 @@
+<?php
+
+namespace Maps\Tests\Integration\MediaWiki\ParserHooks;
+
+use ParamProcessor\ParamDefinition;
+use ParamProcessor\Processor;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+abstract class ParserHookTest extends TestCase {
+
+ public static function setUpBeforeClass() {
+ if ( !defined( 'MEDIAWIKI' ) ) {
+ self::markTestSkipped( 'MediaWiki is not available' );
+ }
+ }
+
+ /**
+ * @since 2.0
+ * @return array
+ */
+ public abstract function parametersProvider();
+
+ /**
+ * Triggers the render process with different sets of parameters to see if
+ * no errors or notices are thrown and the result indeed is a string.
+ *
+ * @dataProvider parametersProvider
+ * @since 2.0
+ *
+ * @param array $parameters
+ * @param string|null $expected
+ */
+ public function testRender( array $parameters, $expected = null ) {
+ $parserHook = $this->getInstance();
+
+ $parser = new \Parser();
+ $parser->mOptions = new \ParserOptions();
+ $parser->clearState();
+ $parser->setTitle( \Title::newMainPage() );
+
+ $renderResult = call_user_func_array(
+ [ $parserHook, 'renderFunction' ],
+ array_merge( [ &$parser ], $parameters )
+ );
+
+ if ( is_string( $renderResult ) ) {
+ $this->assertTrue( true );
+ } else {
+ $this->assertInternalType( 'array', $renderResult );
+ $this->assertInternalType( 'string', $renderResult[0] );
+ }
+
+ if ( $expected !== null ) {
+ $this->assertEquals( $expected, $renderResult[0] );
+ }
+ }
+
+ /**
+ * @since 2.0
+ * @return \ParserHook
+ */
+ protected abstract function getInstance();
+
+ public function processingProvider() {
+ return [];
+ }
+
+ /**
+ * @dataProvider processingProvider
+ * @since 3.0
+ */
+ public function testParamProcessing( array $parameters, array $expectedValues ) {
+ $definitions = $this->getInstance()->getParamDefinitions();
+
+ $processor = Processor::newDefault();
+ $processor->setParameters( $parameters, $definitions );
+
+ $result = $processor->processParameters();
+
+ if ( $result->hasFatal() ) {
+ $this->fail(
+ 'Fatal error occurred during the param processing: ' . $processor->hasFatalError()->getMessage()
+ );
+ }
+
+ $actual = $result->getParameters();
+
+ $expectedValues = array_merge( $this->getDefaultValues(), $expectedValues );
+
+ foreach ( $expectedValues as $name => $expected ) {
+ $this->assertArrayHasKey( $name, $actual );
+
+ $this->assertEquals(
+ $expected,
+ $actual[$name]->getValue(),
+ 'Expected ' . var_export( $expected, true )
+ . ' should match actual '
+ . var_export( $actual[$name]->getValue(), true )
+ );
+ }
+ }
+
+ /**
+ * Returns an array with the default values of the parameters.
+ */
+ private function getDefaultValues() {
+ $definitions = ParamDefinition::getCleanDefinitions( $this->getInstance()->getParamDefinitions() );
+
+ $defaults = [];
+
+ foreach ( $definitions as $definition ) {
+ if ( !$definition->isRequired() ) {
+ $defaults[$definition->getName()] = $definition->getDefault();
+ }
+ }
+
+ return $defaults;
+ }
+
+ protected function arrayWrap( array $elements ) {
+ return array_map(
+ function ( $element ) {
+ return [ $element ];
+ },
+ $elements
+ );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/Parser/CoordinatesTest.php b/www/wiki/extensions/Maps/tests/Integration/Parser/CoordinatesTest.php
new file mode 100644
index 00000000..4ec71630
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/Parser/CoordinatesTest.php
@@ -0,0 +1,96 @@
+<?php
+
+namespace Maps\Tests\Integration\Parser;
+
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CoordinatesTest extends TestCase {
+
+ private function parse( string $textToParse ): string {
+ $parser = new \Parser();
+
+ return $parser->parse( $textToParse, \Title::newMainPage(), new \ParserOptions() )->getText();
+ }
+
+ public function testGivenInvalidCoordinates_errorIsShown() {
+ $this->assertContains(
+ '<span class="errorbox">',
+ $this->parse( '{{#coordinates:nope}}' )
+ );
+ }
+
+ public function testGivenNoCoordinates_errorIsShown() {
+ $this->assertContains(
+ '<span class="errorbox">',
+ $this->parse( '{{#coordinates:}}' )
+ );
+ }
+
+ public function testGivenValidCoordinates_theyAreFormatted() {
+ $this->assertContains(
+ '1° 0\' 0.00" N, 1° 0\' 0.00" E',
+ $this->parse( '{{#coordinates:1,1}}' )
+ );
+ }
+
+ public function testGivenFormat_coordinatesAreConvertedToIt() {
+ $this->assertContains(
+ '1.000000° N, 1.000000° E',
+ $this->parse( '{{#coordinates:1,1|format=dd}}' )
+ );
+ }
+
+ public function testGivenDirectionalParameter_itGetsUsed() {
+ $this->assertContains(
+ '1° 0\' 0.00", 1° 0\' 0.00"',
+ $this->parse( '{{#coordinates:1,1|directional=no}}' )
+ );
+ }
+
+ public function testCoordinatesInNonDms_theyGetParsed() {
+ $this->assertContains(
+ '1° 20\' 13.20" N, 4° 12\' 0.00" W',
+ $this->parse( '{{#coordinates:1.337°, -4.2°}}' )
+ );
+ }
+
+ public function testGivenInvalidFormat_defaultFormatGetsUsed() {
+ $this->assertContains(
+ '1° 0\' 0.00" N, 1° 0\' 0.00" E',
+ $this->parse( '{{#coordinates:1,1|format=such}}' )
+ );
+ }
+
+ public function testRoundingWhenFormattingAsFloat() {
+ $this->assertContains(
+ '52.136945 N, 0.466722 W',
+ $this->parse( '{{#coordinates:52.136945,-0.466722|format=float}}' )
+ );
+ }
+
+ public function testRoundingWhenFormattingAsDMS() {
+ $this->assertContains(
+ '52° 8\' 13.00" N, 0° 28\' 0.20" W',
+ $this->parse( '{{#coordinates:52.136945,-0.466722|format=dms}}' )
+ );
+ }
+
+ public function testRoundingWhenFormattingAsDD() {
+ $this->assertContains(
+ '52.136945° N, 0.466722° W',
+ $this->parse( '{{#coordinates:52.136945,-0.466722|format=dd}}' )
+ );
+ }
+
+ public function testRoundingWhenFormattingAsDM() {
+ $this->assertContains(
+ '52° 8.2167\' N, 0° 28.0033\' W',
+ $this->parse( '{{#coordinates:52.136945,-0.466722|format=dm}}' )
+ );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/Parser/DisplayMapTest.php b/www/wiki/extensions/Maps/tests/Integration/Parser/DisplayMapTest.php
new file mode 100644
index 00000000..ef841f13
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/Parser/DisplayMapTest.php
@@ -0,0 +1,192 @@
+<?php
+
+namespace Maps\Tests\Integration\Parser;
+
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class DisplayMapTest extends TestCase {
+
+ public function testMapIdIsSet() {
+ $this->assertContains(
+ 'id="map_leaflet_',
+ $this->parse( '{{#display_map:1,1|service=leaflet}}' )
+ );
+ }
+
+ private function parse( string $textToParse ): string {
+ $parser = new \Parser();
+
+ return $parser->parse( $textToParse, \Title::newMainPage(), new \ParserOptions() )->getText();
+ }
+
+ public function testServiceSelectionWorks() {
+ $this->assertContains(
+ 'maps-googlemaps3',
+ $this->parse( '{{#display_map:1,1|service=google}}' )
+ );
+ }
+
+ public function testSingleCoordinatesAreIncluded() {
+ $this->assertContains(
+ '"lat":1,"lon":1',
+ $this->parse( '{{#display_map:1,1}}' )
+ );
+ }
+
+ public function testMultipleCoordinatesAreIncluded() {
+ $result = $this->parse( '{{#display_map:1,1; 4,2}}' );
+
+ $this->assertContains( '"lat":1,"lon":1', $result );
+ $this->assertContains( '"lat":4,"lon":2', $result );
+ }
+
+ public function testWhenValidZoomIsSpecified_itGetsUsed() {
+ $this->assertContains(
+ '"zoom":5',
+ $this->parse( '{{#display_map:1,1|service=google|zoom=5}}' )
+ );
+ }
+
+ public function testWhenZoomIsNotSpecifiedAndThereIsOnlyOneLocation_itIsDefaulted() {
+ $this->assertContains(
+ '"zoom":' . $GLOBALS['egMapsGMaps3Zoom'],
+ $this->parse( '{{#display_map:1,1|service=google}}' )
+ );
+ }
+
+ public function testWhenZoomIsNotSpecifiedAndThereAreMultipleLocations_itIsDefaulted() {
+ $this->assertContains(
+ '"zoom":false',
+ $this->parse( '{{#display_map:1,1;2,2|service=google}}' )
+ );
+ }
+
+ public function testWhenZoomIsInvalid_itIsDefaulted() {
+ $this->assertContains(
+ '"zoom":' . $GLOBALS['egMapsGMaps3Zoom'],
+ $this->parse( '{{#display_map:1,1|service=google|zoom=tomato}}' )
+ );
+ }
+
+ public function testTagIsRendered() {
+ $this->assertContains(
+ '"lat":1,"lon":1',
+ $this->parse( '<display_map>1,1</display_map>' )
+ );
+ }
+
+ public function testTagServiceParameterIsUsed() {
+ $this->assertContains(
+ 'maps-googlemaps3',
+ $this->parse( '<display_map service="google">1,1</display_map>' )
+ );
+ }
+
+ public function testWhenThereAreNoLocations_locationsArrayIsEmpty() {
+ $this->assertContains(
+ '"locations":[]',
+ $this->parse( '{{#display_map:}}' )
+ );
+ }
+
+ public function testLocationTitleGetsIncluded() {
+ $this->assertContains(
+ '"title":"title',
+ $this->parse( '{{#display_map:1,1~title}}' )
+ );
+ }
+
+ public function testLocationDescriptionGetsIncluded() {
+ $this->assertContains(
+ 'such description',
+ $this->parse( '{{#display_map:1,1~title~such description}}' )
+ );
+ }
+
+ public function testRectangleDisplay() {
+ $this->assertContains(
+ '"title":"title',
+ $this->parse( '{{#display_map:rectangles=1,1:2,2~title}}' )
+ );
+ }
+
+ public function testCircleDisplay() {
+ $this->assertContains(
+ '"title":"title',
+ $this->parse( '{{#display_map:circles=1,1:2~title}}' )
+ );
+ }
+
+ public function testRectangleFillOpacityIsUsed() {
+ $this->assertContains(
+ '"fillOpacity":"fill opacity"',
+ $this->parse( '{{#display_map:rectangles=1,1:2,2~title~text~color~opacity~thickness~fill color~fill opacity}}' )
+ );
+ }
+
+ public function testRectangleFillColorIsUsed() {
+ $this->assertContains(
+ '"fillColor":"fill color"',
+ $this->parse( '{{#display_map:rectangles=1,1:2,2~title~text~color~opacity~thickness~fill color~fill opacity}}' )
+ );
+ }
+
+ public function testServiceSelectionWorksWhenItIsPrecededByMultipleParameters() {
+ $this->assertContains(
+ 'maps-googlemaps3',
+ $this->parse(
+ "{{#display_map:rectangles=\n 1,1:2,2~title~text~color\n| scrollwheelzoom=off\n| service = google}}"
+ )
+ );
+ }
+
+ // TODO: need DI to test
+// public function testWhenLocationHasVisitedIconModifier_itIsUsed() {
+// $this->assertContains(
+// '"visitedicon":"VisitedIcon.png"',
+// $this->parse( '{{#display_map:1,1~title~text~icon~group~inline label~VisitedIcon.png}}' )
+// );
+// }
+//
+// public function testWhenLocationHasVisitedIconModifierWithNamespacePrefix_thePrefixGetsRemoved() {
+// $this->assertContains(MapsMapperTest
+// '"visitedicon":"VisitedIcon.png"',
+// $this->parse( '{{#display_map:1,1~title~text~icon~group~inline label~File:VisitedIcon.png}}' )
+// );
+// }
+//
+// public function testWhenVisitedIconParameterIsProvidedWithNamespacePrefix_thePrefixGetsRemoved() {
+// $this->assertContains(
+// '"visitedicon":"VisitedIcon.png"',
+// $this->parse( '{{#display_map:1,1|visitedicon=File:VisitedIcon.png}}' )
+// );
+// }
+//
+// public function testWhenLocationHasIconModifierWithNamespacePrefix_thePrefixGetsRemoved() {
+// $this->assertContains(
+// '"icon":"Icon.png"',
+// $this->parse( '{{#display_map:1,1~title~text~File:Icon.png}}' )
+// );
+// }
+
+ public function testWhenIconParameterIsProvidedButEmpty_itIsDefaulted() {
+ $this->assertContains(
+ '"icon":"","inlineLabel":"Ghent',
+ $this->parse(
+ "{{#display_map:Gent, Belgie~The city Ghent~Ghent is awesome~ ~ ~Ghent}}"
+ )
+ );
+ }
+
+ public function testWhenLocationHasNoTitleAndText_textFieldIsEmptyString() {
+ $this->assertContains(
+ '"text":""',
+ $this->parse( '{{#display_map:1,1}}' )
+ );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Maps/tests/Integration/Semantic/ValueDescriptions/AreaDescriptionTest.php b/www/wiki/extensions/Maps/tests/Integration/Semantic/ValueDescriptions/AreaDescriptionTest.php
new file mode 100644
index 00000000..9950b7d3
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/Semantic/ValueDescriptions/AreaDescriptionTest.php
@@ -0,0 +1,81 @@
+<?php
+
+namespace Maps\Tests\Semantic\ValueDescriptions;
+
+use CoordinateValue;
+use Maps\SemanticMW\ValueDescriptions\AreaDescription;
+use PHPUnit\Framework\TestCase;
+use SMWDIGeoCoord;
+
+/**
+ * @covers \Maps\SemanticMW\ValueDescriptions\AreaDescription
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class AreaDescriptionTest extends TestCase {
+
+ public function setUp() {
+ if ( !defined( 'SMW_VERSION' ) ) {
+ $this->markTestSkipped( 'SMW is not available' );
+ }
+ }
+
+ public function testGetBoundingBox() {
+ $area = new AreaDescription(
+ new SMWDIGeoCoord( 0, 5 ),
+ SMW_CMP_EQ,
+ '10 km'
+ );
+
+ $this->assertEquals(
+ [
+ 'north' => 0.089932160591873,
+ 'east' => 5.089932160591873,
+ 'south' => -0.089932160591873,
+ 'west' => 4.9100678394081
+ ],
+ $area->getBoundingBox()
+ );
+ }
+
+ public function testGetSQLCondition() {
+ $area = new AreaDescription(
+ new SMWDIGeoCoord( 0, 5 ),
+ SMW_CMP_EQ,
+ '10 km'
+ );
+
+ $this->assertSame(
+ 'geo_table.lat_field < \'0.089932160591873\' AND geo_table.lat_field > \'-0.089932160591873\' '
+ . 'AND geo_table.long_field < \'5.0899321605919\' AND geo_table.long_field > \'4.9100678394081\'',
+ $area->getSQLCondition( 'geo_table', [ 'id_field', 'lat_field', 'long_field' ], wfGetDB( DB_MASTER ) )
+ );
+ }
+
+ public function testWhenComparatorIsNotSupported_getSQLConditionReturnsFalse() {
+ $area = new AreaDescription(
+ new SMWDIGeoCoord( 0, 5 ),
+ SMW_CMP_LIKE,
+ '10 km'
+ );
+
+ $this->assertFalse(
+ $area->getSQLCondition( 'geo_table', [ 'id_field', 'lat_field', 'long_field' ], wfGetDB( DB_MASTER ) )
+ );
+ }
+
+ public function testGetQueryString() {
+ $area = new AreaDescription(
+ new SMWDIGeoCoord( 1, 5 ),
+ SMW_CMP_EQ,
+ '10 km'
+ );
+
+ $this->assertSame(
+ '[[1° 0\' 0.00" N, 5° 0\' 0.00" E (10 km)]]',
+ $area->getQueryString()
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/CircleParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/CircleParserTest.php
new file mode 100644
index 00000000..9009947b
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/CircleParserTest.php
@@ -0,0 +1,43 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoders\Decorators\CoordinateFriendlyGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\NullGeocoder;
+use Maps\Elements\Circle;
+use Maps\Presentation\WikitextParsers\CircleParser;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Presentation\WikitextParsers\CircleParser
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CircleParserTest extends TestCase {
+
+ public function testGivenCoordinateAndRadius_parserReturnsCircle() {
+ $parser = new CircleParser( new CoordinateFriendlyGeocoder( new NullGeocoder() ) );
+
+ $circle = $parser->parse( '57.421,23.90625:32684.605182' );
+
+ $this->assertInstanceOf( Circle::class, $circle );
+
+ $expectedLatLong = new LatLongValue( 57.421, 23.90625 );
+ $this->assertTrue( $expectedLatLong->equals( $circle->getCircleCentre() ) );
+
+ $this->assertSame( 32684.605182, $circle->getCircleRadius() );
+ }
+
+ public function testGivenTitleAndText_circleHasProvidedMetaData() {
+ $parser = new CircleParser( new CoordinateFriendlyGeocoder( new NullGeocoder() ) );
+
+ $circle = $parser->parse( '57.421,23.90625:32684.605182~title~text' );
+
+ $this->assertInstanceOf( Circle::class, $circle );
+
+ $this->assertSame( 'title', $circle->getTitle() );
+ $this->assertSame( 'text', $circle->getText() );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/DistanceParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/DistanceParserTest.php
new file mode 100644
index 00000000..f402d966
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/DistanceParserTest.php
@@ -0,0 +1,66 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use Maps\Presentation\WikitextParsers\DistanceParser;
+use PHPUnit\Framework\TestCase;
+use PHPUnit4And6Compat;
+use ValueParsers\ParseException;
+
+/**
+ * @covers \Maps\Presentation\WikitextParsers\DistanceParser
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class DistanceParserTest extends TestCase {
+ use PHPUnit4And6Compat;
+
+ /**
+ * @dataProvider validInputProvider
+ */
+ public function testValidInputs( $input, $expected ) {
+ $this->assertSame(
+ $expected,
+ ( new DistanceParser() )->parse( $input )
+ );
+ }
+
+ public function validInputProvider() {
+ return [
+ [ '1', 1.0 ],
+ [ '1m', 1.0 ],
+ [ '42 km', 42000.0 ],
+ [ '4.2 km', 4200.0 ],
+ [ '4.2 m', 4.2 ],
+ [ '4.02 m', 4.02 ],
+ [ '4.02 km', 4020.0 ],
+ [ '0.001 km', 1.0 ],
+ ];
+ }
+
+ /**
+ * @dataProvider invalidInputProvider
+ */
+ public function testGivenInvalidInput_exceptionIsThrown( $input ) {
+ $parser = new DistanceParser();
+
+ $this->expectException( ParseException::class );
+ $parser->parse( $input );
+ }
+
+ public function invalidInputProvider() {
+ return [
+ [ '' ],
+ [ 'kittens' ],
+ [ '1 kittens' ],
+ [ '-1m' ],
+ [ 'foo m' ],
+ [ '1m foo' ],
+ [ 'foo 1m' ],
+ [ 'm1' ],
+ [ '4. m' ],
+ [ '4.2.1 m' ],
+ ];
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/JsonFileParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/JsonFileParserTest.php
new file mode 100644
index 00000000..a169beb1
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/JsonFileParserTest.php
@@ -0,0 +1,120 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use FileFetcher\FileFetcher;
+use FileFetcher\NullFileFetcher;
+use FileFetcher\SimpleFileFetcher;
+use FileFetcher\StubFileFetcher;
+use FileFetcher\ThrowingFileFetcher;
+use Maps\DataAccess\JsonFileParser;
+use Maps\MediaWiki\Content\GeoJsonContent;
+use PHPUnit\Framework\TestCase;
+use PHPUnit4And6Compat;
+use Title;
+
+/**
+ * @covers \Maps\DataAccess\JsonFileParser
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class JsonFileParserTest extends TestCase {
+ use PHPUnit4And6Compat;
+
+ private const VALID_FILE_JSON = [
+ 'such' => 'string',
+ 42 => 13.37,
+ 'array' => [
+ '~[,,_,,]:3'
+ ]
+ ];
+
+ private const VALID_PAGE_JSON = [
+ 'foo' => 'bar',
+ 1 => 2.3,
+ 'array' => [
+ '~[,,_,,]:3'
+ ]
+ ];
+
+ private const EXISTING_GEO_JSON_PAGE = 'Such';
+ private const EXISTING_GEO_JSON_PAGE_WITH_PREFIX = 'GeoJson:Such';
+ private const NON_EXISTING_GEO_JSON_PAGE = 'GeoJson:Nope';
+
+ /**
+ * @var FileFetcher
+ */
+ private $fileFetcher;
+
+ public function setUp() {
+ $this->fileFetcher = new StubFileFetcher( json_encode( self::VALID_FILE_JSON ) );
+
+ $page = new \WikiPage( Title::newFromText( self::EXISTING_GEO_JSON_PAGE_WITH_PREFIX ) );
+ $page->doEditContent( new GeoJsonContent( json_encode( self::VALID_PAGE_JSON ) ), '' );
+ }
+
+ private function newJsonFileParser(): JsonFileParser {
+ return new JsonFileParser(
+ $this->fileFetcher,
+ null
+ );
+ }
+
+ public function testWhenFileRetrievalFails_emptyJsonIsReturned() {
+ $this->fileFetcher = new ThrowingFileFetcher();
+
+ $this->assertSame(
+ [],
+ $this->newJsonFileParser()->parse( 'http://such.a/file' )
+ );
+ }
+
+ public function testWhenFileHasValidJson_jsonIsReturned() {
+ $this->fileFetcher = new StubFileFetcher( json_encode( self::VALID_FILE_JSON ) );
+
+ $this->assertEquals(
+ self::VALID_FILE_JSON,
+ $this->newJsonFileParser()->parse( 'http://such.a/file' )
+ );
+ }
+
+ public function testWhenFileIsEmpty_emptyJsonIsReturned() {
+ $this->fileFetcher = new NullFileFetcher();
+
+ $this->assertSame(
+ [],
+ $this->newJsonFileParser()->parse( 'http://such.a/file' )
+ );
+ }
+
+ public function testWhenFileLocationIsNotUrl_emptyJsonIsReturned() {
+ $this->fileFetcher = new SimpleFileFetcher();
+
+ $jsonFilePath = __DIR__ . '/../../../composer.json';
+ $this->assertFileExists( $jsonFilePath );
+
+ $this->assertSame( [], $this->newJsonFileParser()->parse( $jsonFilePath ) );
+ }
+
+ public function testWhenPageExists_itsContentsIsReturned() {
+ $this->assertSame(
+ self::VALID_PAGE_JSON,
+ $this->newJsonFileParser()->parse( self::EXISTING_GEO_JSON_PAGE_WITH_PREFIX )
+ );
+ }
+
+ public function testWhenPageDoesNotExist_emptyJsonIsReturned() {
+ $this->assertSame(
+ [],
+ $this->newJsonFileParser()->parse( self::NON_EXISTING_GEO_JSON_PAGE )
+ );
+ }
+
+ public function testWhenExistingPageIsSpecifiedWithoutPrefix_itsContentsIsReturned() {
+ $this->assertSame(
+ self::VALID_PAGE_JSON,
+ $this->newJsonFileParser()->parse( self::EXISTING_GEO_JSON_PAGE )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/LineParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/LineParserTest.php
new file mode 100644
index 00000000..39b149da
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/LineParserTest.php
@@ -0,0 +1,77 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoders\InMemoryGeocoder;
+use Maps\Elements\Line;
+use Maps\Presentation\WikitextParsers\LineParser;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Presentation\WikitextParsers\LineParser
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class LineParserTest extends TestCase {
+
+ public function testGivenOneCoordinate_lineWithOneCoordinateIsReturned() {
+ $parser = $this->newParser();
+
+ $this->assertEquals(
+ new Line( [ new LatLongValue( 4, 2 ) ] ),
+ $parser->parse( '4,2' )
+ );
+ }
+
+ /**
+ * @return \Maps\Presentation\WikitextParsers\LineParser
+ */
+ private function newParser() {
+ $parser = new LineParser();
+
+ $parser->setGeocoder(
+ new InMemoryGeocoder(
+ [
+ '4,2' => new LatLongValue( 4, 2 ),
+ '2,3' => new LatLongValue( 2, 3 ),
+ ]
+ )
+ );
+
+ return $parser;
+ }
+
+ public function testGivenTwoCoordinates_lineWithBothCoordinateIsReturned() {
+ $parser = $this->newParser();
+
+ $this->assertEquals(
+ new Line(
+ [
+ new LatLongValue( 4, 2 ),
+ new LatLongValue( 2, 3 )
+ ]
+ ),
+ $parser->parse( '4,2:2,3' )
+ );
+ }
+
+ public function testTitleAndTextGetSetWhenPresent() {
+ $parser = $this->newParser();
+
+ $expectedLine = new Line(
+ [
+ new LatLongValue( 4, 2 ),
+ new LatLongValue( 2, 3 )
+ ]
+ );
+ $expectedLine->setTitle( 'title' );
+ $expectedLine->setText( 'text' );
+
+ $this->assertEquals(
+ $expectedLine,
+ $parser->parse( '4,2:2,3~title~text' )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/LocationParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/LocationParserTest.php
new file mode 100644
index 00000000..60f93284
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/LocationParserTest.php
@@ -0,0 +1,119 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoders\StubGeocoder;
+use Maps\DataAccess\MediaWikiFileUrlFinder;
+use Maps\Elements\Location;
+use Maps\Presentation\WikitextParsers\LocationParser;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Presentation\WikitextParsers\LocationParser
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class LocationParserTest extends TestCase {
+
+ private $geocoder;
+ private $fileUrlFinder;
+ private $useAddressAsTitle;
+
+ public function setUp() {
+ $this->geocoder = new StubGeocoder( new LatLongValue( 1, 2 ) );
+ $this->fileUrlFinder = new MediaWikiFileUrlFinder();
+ $this->useAddressAsTitle = false;
+ }
+
+ private function newLocationParser() {
+ return LocationParser::newInstance( $this->geocoder, $this->fileUrlFinder, $this->useAddressAsTitle );
+ }
+
+ /**
+ * @dataProvider titleProvider
+ */
+ public function testGivenTitleThatIsNotLink_titleIsSetAndLinkIsNot( $title ) {
+ $location = $this->newLocationParser()->parse( '4,2~' . $title );
+
+ $this->assertTitleAndLinkAre( $location, $title, '' );
+ }
+
+ protected function assertTitleAndLinkAre( Location $location, $title, $link ) {
+ $this->assertHasJsonKeyWithValue( $location, 'title', $title );
+ $this->assertHasJsonKeyWithValue( $location, 'link', $link );
+ }
+
+ protected function assertHasJsonKeyWithValue( Location $polygon, $key, $value ) {
+ $json = $polygon->getJSONObject();
+
+ $this->assertArrayHasKey( $key, $json );
+ $this->assertEquals( $value, $json[$key] );
+ }
+
+ public function titleProvider() {
+ return [
+ [ '' ],
+ [ 'Title' ],
+ [ 'Some title' ],
+ [ 'link' ],
+ [ 'links:foo' ],
+ ];
+ }
+
+ /**
+ * @dataProvider linkProvider
+ */
+ public function testGivenTitleThatIsLink_linkIsSetAndTitleIsNot( $link ) {
+ $location = $this->newLocationParser()->parse( '4,2~link:' . $link );
+
+ $this->assertTitleAndLinkAre( $location, '', $link );
+ }
+
+ public function linkProvider() {
+ return [
+ [ 'https://www.semantic-mediawiki.org' ],
+ [ 'irc://freenode.net' ],
+ ];
+ }
+
+// /**
+// * @dataProvider titleLinkProvider
+// */
+// public function testGivenPageTitleAsLink_pageTitleIsTurnedIntoUrl( $link ) {
+// $parser = new LocationParser();
+// $location = $parser->parse( '4,2~link:' . $link );
+//
+// $linkUrl = Title::newFromText( $link )->getFullURL();
+// $this->assertTitleAndLinkAre( $location, '', $linkUrl );
+// }
+//
+// public function titleLinkProvider() {
+// return array(
+// array( 'Foo' ),
+// array( 'Some_Page' ),
+// );
+// }
+
+ public function testGivenAddressAndNoTitle_addressIsSetAsTitle() {
+ $this->useAddressAsTitle = true;
+ $location = $this->newLocationParser()->parse( 'Tempelhofer Ufer 42' );
+
+ $this->assertSame( 'Tempelhofer Ufer 42', $location->getTitle() );
+ }
+
+ public function testGivenAddressAndTitle_addressIsNotUsedAsTitle() {
+ $this->useAddressAsTitle = true;
+ $location = $this->newLocationParser()->parse( 'Tempelhofer Ufer 42~Great title of doom' );
+
+ $this->assertSame( 'Great title of doom', $location->getTitle() );
+ }
+
+ public function testGivenCoordinatesAndNoTitle_noTitleIsSet() {
+ $this->useAddressAsTitle = true;
+ $location = $this->newLocationParser()->parse( '4,2' );
+
+ $this->assertSame( '', $location->getTitle() );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/RectlangleParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/RectlangleParserTest.php
new file mode 100644
index 00000000..027bdb07
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/RectlangleParserTest.php
@@ -0,0 +1,44 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoders\Decorators\CoordinateFriendlyGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\NullGeocoder;
+use Maps\Elements\Rectangle;
+use Maps\Presentation\WikitextParsers\RectangleParser;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Presentation\WikitextParsers\RectangleParser
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class RectangleParserTest extends TestCase {
+
+ public function testGivenBoundingBox_parserReturnsRectangle() {
+ $parser = new RectangleParser( new CoordinateFriendlyGeocoder( new NullGeocoder() ) );
+
+ $rectangle = $parser->parse( '51.8357775,33.83789:46,23.37890625' );
+
+ $this->assertInstanceOf( Rectangle::class, $rectangle );
+
+ $expectedNorthEast = new LatLongValue( 51.8357775, 33.83789 );
+ $this->assertTrue( $expectedNorthEast->equals( $rectangle->getRectangleNorthEast() ) );
+
+ $expectedSouthWest = new LatLongValue( 46, 23.37890625 );
+ $this->assertTrue( $expectedSouthWest->equals( $rectangle->getRectangleSouthWest() ) );
+ }
+
+ public function testGivenTitleAndText_rectangleHasProvidedMetaData() {
+ $parser = new RectangleParser( new CoordinateFriendlyGeocoder( new NullGeocoder() ) );
+
+ $rectangle = $parser->parse( "51.8357775,33.83789:46,23.37890625~I'm a square~of doom" );
+
+ $this->assertInstanceOf( Rectangle::class, $rectangle );
+
+ $this->assertSame( "I'm a square", $rectangle->getTitle() );
+ $this->assertSame( 'of doom', $rectangle->getText() );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Integration/parsers/WmsOverlayParserTest.php b/www/wiki/extensions/Maps/tests/Integration/parsers/WmsOverlayParserTest.php
new file mode 100644
index 00000000..4787f263
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Integration/parsers/WmsOverlayParserTest.php
@@ -0,0 +1,54 @@
+<?php
+
+namespace Maps\Tests\Integration\parsers;
+
+use Maps\Presentation\WikitextParsers\WmsOverlayParser;
+use PHPUnit\Framework\TestCase;
+use PHPUnit4And6Compat;
+use ValueParsers\ParseException;
+
+/**
+ * @covers \Maps\Presentation\WikitextParsers\WmsOverlayParser
+ * @licence GNU GPL v2+
+ * @author Mathias Mølster Lidal <mathiaslidal@gmail.com>
+ */
+class WmsOverlayParserTest extends TestCase {
+ use PHPUnit4And6Compat;
+
+ public function testGivenValidInput_parserReturnsOverlayObject() {
+ $parser = new WmsOverlayParser();
+
+ $overlay = $parser->parse( 'http://demo.cubewerx.com/demo/cubeserv/cubeserv.cgi? Foundation.GTOPO30' );
+
+ $this->assertSame(
+ 'http://demo.cubewerx.com/demo/cubeserv/cubeserv.cgi?',
+ $overlay->getWmsServerUrl()
+ );
+
+ $this->assertSame(
+ 'Foundation.GTOPO30',
+ $overlay->getWmsLayerName()
+ );
+ }
+
+ public function testWhenStyleNameIsSpecified_getStyleNameReturnsIt() {
+ $parser = new WmsOverlayParser();
+
+ $overlay = $parser->parse(
+ 'http://maps.imr.no:80/geoserver/wms? vulnerable_areas:Identified_coral_area coral_identified_areas'
+ );
+
+ $this->assertSame(
+ 'coral_identified_areas',
+ $overlay->getWmsStyleName()
+ );
+ }
+
+ public function testWhenThereAreLessThanTwoSegments_parseExceptionIsThrown() {
+ $parser = new WmsOverlayParser();
+
+ $this->expectException( ParseException::class );
+ $parser->parse( 'Such' );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/System/SemanticMW/MapQueryTest.php b/www/wiki/extensions/Maps/tests/System/SemanticMW/MapQueryTest.php
new file mode 100644
index 00000000..be04fb44
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/System/SemanticMW/MapQueryTest.php
@@ -0,0 +1,93 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Tests\System\SemanticMW;
+
+use Maps\DataAccess\PageContentFetcher;
+use Maps\MapsFactory;
+use Maps\Tests\Util\PageCreator;
+use Maps\Tests\Util\TestFactory;
+use PHPUnit\Framework\TestCase;
+use Title;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MapQueryTest extends TestCase {
+
+ /**
+ * @var PageCreator
+ */
+ private $pageCreator;
+
+ /**
+ * @var PageContentFetcher
+ */
+ private $contentFetcher;
+
+ public function setUp() {
+ if ( !defined( 'SMW_VERSION' ) ) {
+ $this->markTestSkipped( 'SMW is not available' );
+ }
+
+ $this->pageCreator = TestFactory::newInstance()->getPageCreator();
+ $this->contentFetcher = MapsFactory::newDefault()->getPageContentFetcher();
+ }
+
+ public function testMapQuery() {
+ $this->createPages();
+
+ $this->pageCreator->createPage(
+ 'MapQuery',
+ '{{#ask:[[Coordinates::+]]|?Coordinates|?Description|?URL|format=map}}'
+ );
+
+ // TODO: saner way
+ $content = $this->contentFetcher->getPageContent( 'MapQuery' )->getParserOutput( Title::newFromText( 'MapQuery' ) )->getText();
+
+ $this->assertContains(
+ '<div id="map_',
+ $content
+ );
+
+ $this->assertContains(
+ '<div id="map_',
+ $content
+ );
+ }
+
+ private function createPages() {
+ $this->pageCreator->createPage(
+ 'Property:Coordinates',
+ '[[Has type::Geographic coordinate|geographic coordinate]]'
+ );
+
+ $this->pageCreator->createPage(
+ 'Property:Description',
+ '[[Has type::Text]]'
+ );
+
+ $this->pageCreator->createPage(
+ 'Property:URL',
+ '[[Has type::URL]]'
+ );
+
+ $this->pageCreator->createPage(
+ 'Berlin',
+ '[[Coordinates::52° 31\' 0", 13° 24\' 0"]] [[Description::Capital of Germany]] [[URL::http://example.com/Berlin]]'
+ );
+
+ $this->pageCreator->createPage(
+ 'Brussels',
+ '[[Coordinates::50° 51\' 1", 4° 21\' 6"]] [[Description::Capital of Belgium]]'
+ );
+
+ $this->pageCreator->createPage(
+ 'Hamburg',
+ '[[Coordinates::53° 33\' 4", 9° 59\' 37"]]'
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/BaseElementTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/BaseElementTest.php
new file mode 100644
index 00000000..bda1c9bd
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/BaseElementTest.php
@@ -0,0 +1,85 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use InvalidArgumentException;
+use PHPUnit\Framework\TestCase;
+use PHPUnit4And6Compat;
+
+/**
+ * Base class for unit tests classes for the Maps\BaseElement deriving objects.
+ *
+ * @since 3.0
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+abstract class BaseElementTest extends TestCase {
+ use PHPUnit4And6Compat;
+
+ public function invalidConstructorProvider() {
+ return [];
+ }
+
+ /**
+ * Creates and returns a new instance of the concrete class.
+ *
+ * @since 3.0
+ *
+ * @return mixed
+ */
+ public function newInstance() {
+ $reflector = new \ReflectionClass( $this->getClass() );
+ $args = func_get_args();
+ $instance = $reflector->newInstanceArgs( $args );
+ return $instance;
+ }
+
+ /**
+ * Returns the name of the concrete class tested by this test.
+ *
+ * @since 3.0
+ *
+ * @return string
+ */
+ public abstract function getClass();
+
+ /**
+ * @since 3.0
+ *
+ * @return array [instance, constructor args]
+ */
+ public function instanceProvider() {
+ $phpFails = [ $this, 'newInstance' ];
+
+ return array_map(
+ function ( array $args ) use ( $phpFails ) {
+ return [ call_user_func_array( $phpFails, $args ), $args ];
+ },
+ $this->validConstructorProvider()
+ );
+ }
+
+ public abstract function validConstructorProvider();
+
+ /**
+ * @dataProvider validConstructorProvider
+ *
+ * @since 3.0
+ */
+ public function testGivenValidArguments_constructorDoesNotThrowException() {
+ $instance = call_user_func_array( [ $this, 'newInstance' ], func_get_args() );
+ $this->assertInstanceOf( $this->getClass(), $instance );
+ }
+
+ /**
+ * @dataProvider invalidConstructorProvider
+ *
+ * @since 3.0
+ */
+ public function testGivenInvalidArguments_constructorThrowsException() {
+ $this->expectException( InvalidArgumentException::class );
+ call_user_func_array( [ $this, 'newInstance' ], func_get_args() );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/CircleTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/CircleTest.php
new file mode 100644
index 00000000..3800f059
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/CircleTest.php
@@ -0,0 +1,70 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\Elements\Circle;
+
+/**
+ * @covers \Maps\Elements\Circle
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CircleTest extends BaseElementTest {
+
+ /**
+ * @see BaseElementTest::getClass
+ *
+ * @since 3.0
+ *
+ * @return string
+ */
+ public function getClass() {
+ return Circle::class;
+ }
+
+ public function validConstructorProvider() {
+ $argLists = [];
+
+ $argLists[] = [ new LatLongValue( 4, 2 ), 42 ];
+ $argLists[] = [ new LatLongValue( 42, 2.2 ), 9000.1 ];
+ $argLists[] = [ new LatLongValue( 4, 2 ), 1 ];
+ $argLists[] = [ new LatLongValue( 4, 2 ), 0.1 ];
+
+ return $argLists;
+ }
+
+ public function invalidConstructorProvider() {
+ $argLists = [];
+
+ $argLists[] = [ new LatLongValue( 4, 2 ), 0 ];
+ $argLists[] = [ new LatLongValue( 4, 2 ), -42 ];
+
+ return $argLists;
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ *
+ * @param Circle $circle
+ * @param array $arguments
+ */
+ public function testGetCircleCentre( Circle $circle, array $arguments ) {
+ $this->assertTrue( $circle->getCircleCentre()->equals( $arguments[0] ) );
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ *
+ * @param Circle $circle
+ * @param array $arguments
+ */
+ public function testGetCircleRadius( Circle $circle, array $arguments ) {
+ $this->assertEquals( $arguments[1], $circle->getCircleRadius() );
+ }
+
+}
+
+
+
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/ImageOverlayTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/ImageOverlayTest.php
new file mode 100644
index 00000000..21c43c31
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/ImageOverlayTest.php
@@ -0,0 +1,52 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use Jeroen\SimpleGeocoder\Geocoders\Decorators\CoordinateFriendlyGeocoder;
+use Jeroen\SimpleGeocoder\Geocoders\NullGeocoder;
+use Maps\Elements\ImageOverlay;
+use Maps\Presentation\WikitextParsers\ImageOverlayParser;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Elements\ImageOverlay
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class ImageOverlayTest extends TestCase {
+
+ public function testGetImage() {
+ $imageOverlay = new ImageOverlay(
+ new LatLongValue( 4, 2 ),
+ new LatLongValue( -4, -2 ),
+ 'Foo.png'
+ );
+
+ $this->assertSame( 'Foo.png', $imageOverlay->getImage() );
+ }
+
+ public function testGivenMetaData_overlayHasProvidedMetaData() {
+ $parser = new ImageOverlayParser( new CoordinateFriendlyGeocoder( new NullGeocoder() ) );
+
+ $overlay = $parser->parse( "1,2:3,4:https://such.an/image.png~Semantic MediaWiki~World domination imminent!~https://such.link" );
+
+ $this->assertSame( 'https://such.an/image.png', $overlay->getImage() );
+ $this->assertSame( 'Semantic MediaWiki', $overlay->getTitle() );
+ $this->assertSame( 'World domination imminent!', $overlay->getText() );
+ $this->assertSame( 'https://such.link', $overlay->getLink() );
+ }
+
+ public function testGivenLinkWithPrefix_linkIsParsedAndPrefixIsRemoved() {
+ $parser = new ImageOverlayParser( new CoordinateFriendlyGeocoder( new NullGeocoder() ) );
+
+ $overlay = $parser->parse( "1,2:3,4:https://such.an/image.png~Semantic MediaWiki~World domination imminent!~link:https://such.link" );
+
+ $this->assertSame( 'https://such.link', $overlay->getLink() );
+ }
+
+}
+
+
+
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/LineTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/LineTest.php
new file mode 100644
index 00000000..5ca462ff
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/LineTest.php
@@ -0,0 +1,74 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\Elements\Line;
+
+/**
+ * @covers \Maps\Elements\Line
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class LineTest extends BaseElementTest {
+
+ /**
+ * @see BaseElementTest::getClass
+ *
+ * @since 3.0
+ *
+ * @return string
+ */
+ public function getClass() {
+ return Line::class;
+ }
+
+ public function validConstructorProvider() {
+ $argLists = [];
+
+ $argLists[] = [ [] ];
+ $argLists[] = [ [ new LatLongValue( 4, 2 ) ] ];
+
+ $argLists[] = [
+ [
+ new LatLongValue( 4, 2 ),
+ new LatLongValue( 2, 4 ),
+ new LatLongValue( 42, 42 ),
+ ]
+ ];
+
+ return $argLists;
+ }
+
+ public function invalidConstructorProvider() {
+ $argLists = [];
+
+ $argLists[] = [ [ '~=[,,_,,]:3' ] ];
+ $argLists[] = [ [ new LatLongValue( 4, 2 ), '~=[,,_,,]:3' ] ];
+ $argLists[] = [ [ '~=[,,_,,]:3', new LatLongValue( 4, 2 ) ] ];
+
+ return $argLists;
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ *
+ * @param Line $line
+ * @param array $arguments
+ */
+ public function testGetLineCoordinates( Line $line, array $arguments ) {
+ $coordinates = $line->getLineCoordinates();
+
+ $this->assertInternalType( 'array', $coordinates );
+ $this->assertEquals( count( $arguments[0] ), count( $coordinates ) );
+
+ foreach ( $coordinates as $geoCoordinate ) {
+ $this->assertInstanceOf( LatLongValue::class, $geoCoordinate );
+ }
+ }
+
+}
+
+
+
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/LocationTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/LocationTest.php
new file mode 100644
index 00000000..57041e07
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/LocationTest.php
@@ -0,0 +1,36 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\Elements\Location;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Elements\Location
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class LocationTest extends TestCase {
+
+ public function latLongValueProvider() {
+ $argLists = [];
+
+ $argLists[] = [ new LatLongValue( 0, 0 ) ];
+ $argLists[] = [ new LatLongValue( 4, 2 ) ];
+ $argLists[] = [ new LatLongValue( 42, 42 ) ];
+ $argLists[] = [ new LatLongValue( -4.2, -42 ) ];
+
+ return $argLists;
+ }
+
+ /**
+ * @dataProvider latLongValueProvider
+ */
+ public function testGivenLatLongInConstructor_getCoordinatesReturnsIt( LatLongValue $latLong ) {
+ $location = new Location( $latLong );
+ $this->assertTrue( $latLong->equals( $location->getCoordinates() ) );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/PolygonTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/PolygonTest.php
new file mode 100644
index 00000000..f1c8f513
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/PolygonTest.php
@@ -0,0 +1,68 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use Maps\Elements\Polygon;
+
+/**
+ * @covers \Maps\Elements\Polygon
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class PolygonTest extends LineTest {
+
+ /**
+ * @see BaseElementTest::getClass
+ *
+ * @since 3.0
+ *
+ * @return string
+ */
+ public function getClass() {
+ return Polygon::class;
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ */
+ public function testSetOnlyVisibleOnHover( Polygon $polygon ) {
+ $this->assertFalse( $polygon->isOnlyVisibleOnHover() );
+
+ $polygon->setOnlyVisibleOnHover( true );
+ $this->assertTrue( $polygon->isOnlyVisibleOnHover() );
+
+ $polygon->setOnlyVisibleOnHover( false );
+ $this->assertFalse( $polygon->isOnlyVisibleOnHover() );
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ */
+ public function testSetFillOpacity( Polygon $polygon ) {
+ $polygon->setFillOpacity( '0.42' );
+ $this->assertHasJsonKeyWithValue( $polygon, 'fillOpacity', '0.42' );
+ }
+
+ protected function assertHasJsonKeyWithValue( Polygon $polygon, $key, $value ) {
+ $json = $polygon->getJSONObject();
+
+ $this->assertArrayHasKey( $key, $json );
+ $this->assertEquals(
+ $value,
+ $json[$key]
+ );
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ */
+ public function testSetFillColor( Polygon $polygon ) {
+ $polygon->setFillColor( '#FFCCCC' );
+ $this->assertHasJsonKeyWithValue( $polygon, 'fillColor', '#FFCCCC' );
+ }
+
+}
+
+
+
diff --git a/www/wiki/extensions/Maps/tests/Unit/Elements/RectangleTest.php b/www/wiki/extensions/Maps/tests/Unit/Elements/RectangleTest.php
new file mode 100644
index 00000000..daed71cb
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Elements/RectangleTest.php
@@ -0,0 +1,73 @@
+<?php
+
+namespace Maps\Tests\Unit\Elements;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\Elements\Rectangle;
+
+/**
+ * @covers \Maps\Elements\Rectangle
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class RectangleTest extends BaseElementTest {
+
+ /**
+ * @see BaseElementTest::getClass
+ *
+ * @since 3.0
+ *
+ * @return string
+ */
+ public function getClass() {
+ return Rectangle::class;
+ }
+
+ public function validConstructorProvider() {
+ $argLists = [];
+
+ $argLists[] = [ new LatLongValue( 4, 2 ), new LatLongValue( -4, -2 ) ];
+ $argLists[] = [ new LatLongValue( -42, -42 ), new LatLongValue( -4, -2 ) ];
+
+ return $argLists;
+ }
+
+ public function invalidConstructorProvider() {
+ $argLists = [];
+
+ $argLists[] = [ new LatLongValue( 4, 2 ), new LatLongValue( 4, 2 ) ];
+
+ return $argLists;
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ */
+ public function testGetCorners( Rectangle $rectangle, array $arguments ) {
+ $this->assertTrue( $rectangle->getRectangleNorthEast()->equals( $arguments[0] ) );
+ $this->assertTrue( $rectangle->getRectangleSouthWest()->equals( $arguments[1] ) );
+ }
+
+ /**
+ * @dataProvider instanceProvider
+ */
+ public function testSetCorners( Rectangle $rectangle ) {
+ $coordinates = [
+ new LatLongValue( 42, 42 ),
+ new LatLongValue( 0, 0 )
+ ];
+
+ foreach ( $coordinates as $coordinate ) {
+ $rectangle->setRectangleNorthEast( $coordinate );
+ $this->assertTrue( $rectangle->getRectangleNorthEast()->equals( $coordinate ) );
+
+ $rectangle->setRectangleSouthWest( $coordinate );
+ $this->assertTrue( $rectangle->getRectangleSouthWest()->equals( $coordinate ) );
+ }
+ }
+
+}
+
+
+
diff --git a/www/wiki/extensions/Maps/tests/Unit/Presentation/KmlFormatterTest.php b/www/wiki/extensions/Maps/tests/Unit/Presentation/KmlFormatterTest.php
new file mode 100644
index 00000000..cc88f005
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Presentation/KmlFormatterTest.php
@@ -0,0 +1,88 @@
+<?php
+
+namespace Maps\Tests\Unit\Presentation;
+
+use DataValues\Geo\Values\LatLongValue;
+use Maps\Elements\Location;
+use Maps\Presentation\KmlFormatter;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Presentation\KmlFormatter
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class KmlFormatterTest extends TestCase {
+
+ public function testEmptyList() {
+ $this->assertSame(
+ '<?xml version="1.0" encoding="UTF-8"?>
+<kml xmlns="http://www.opengis.net/kml/2.2">
+ <Document>
+
+ </Document>
+</kml>',
+ ( new KmlFormatter() )->formatLocationsAsKml()
+ );
+ }
+
+ public function testSeveralLocations() {
+ $this->assertSame(
+ '<?xml version="1.0" encoding="UTF-8"?>
+<kml xmlns="http://www.opengis.net/kml/2.2">
+ <Document>
+ <Placemark>
+ <name><![CDATA[first title]]></name>
+ <description><![CDATA[first text]]></description>
+ <Point>
+ <coordinates>23,42.42,0</coordinates>
+ </Point>
+ </Placemark>
+ <Placemark>
+ <name><![CDATA[second title]]></name>
+ <description><![CDATA[second text]]></description>
+ <Point>
+ <coordinates>0,-1,0</coordinates>
+ </Point>
+ </Placemark>
+ </Document>
+</kml>',
+ ( new KmlFormatter() )->formatLocationsAsKml(
+ new Location(
+ new LatLongValue( 42.42,23 ),
+ 'first title',
+ 'first text'
+ ),
+ new Location(
+ new LatLongValue( -1,0 ),
+ 'second title',
+ 'second text'
+ )
+ )
+ );
+ }
+
+ public function testLocationWithoutTitleAndText() {
+ $this->assertSame(
+ '<?xml version="1.0" encoding="UTF-8"?>
+<kml xmlns="http://www.opengis.net/kml/2.2">
+ <Document>
+ <Placemark>
+ <name><![CDATA[]]></name>
+ <description><![CDATA[]]></description>
+ <Point>
+ <coordinates>23,42.42,0</coordinates>
+ </Point>
+ </Placemark>
+ </Document>
+</kml>',
+ ( new KmlFormatter() )->formatLocationsAsKml(
+ new Location(
+ new LatLongValue( 42.42,23 )
+ )
+ )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Unit/Presentation/ParameterExtractorTest.php b/www/wiki/extensions/Maps/tests/Unit/Presentation/ParameterExtractorTest.php
new file mode 100644
index 00000000..2e526809
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Presentation/ParameterExtractorTest.php
@@ -0,0 +1,80 @@
+<?php
+
+namespace Maps\Tests\Unit\Presentation;
+
+use Maps\Presentation\ParameterExtractor;
+use PHPUnit\Framework\TestCase;
+
+/**
+ * @covers \Maps\Presentation\ParameterExtractor
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class ParameterExtractorTest extends TestCase {
+
+ public function testGivenNoParameters_nullIsReturned() {
+ $this->assertNull( ( new ParameterExtractor() )->extract( [ 'name' ], [] ) );
+ }
+
+ public function testGivenWhenPrimaryNameIsPresent_itsValueIsReturned() {
+ $this->assertSame(
+ 'value',
+ ( new ParameterExtractor() )->extract(
+ [ 'name' ],
+ [ 'foo' => 'bar', 'name' => 'value', 'baz' => 'bah' ]
+ )
+ );
+ }
+
+ public function testGivenAliasIsPresent_itsValueIsReturned() {
+ $this->assertSame(
+ 'value',
+ ( new ParameterExtractor() )->extract(
+ [ 'name', 'secondary', 'alias' ],
+ [ 'foo' => 'bar', 'alias' => 'value', 'baz' => 'bah' ]
+ )
+ );
+ }
+
+ public function testWhenAliasAndPrimaryArePresent_thePrimariesValueIsReturned() {
+ $this->assertSame(
+ 'value',
+ ( new ParameterExtractor() )->extract(
+ [ 'name', 'secondary', 'alias' ],
+ [ 'foo' => 'bar', 'alias' => 'wrong', 'name' => 'value' ]
+ )
+ );
+ }
+
+ public function testValueIsTrimmed() {
+ $this->assertSame(
+ 'value',
+ ( new ParameterExtractor() )->extract(
+ [ 'name' ],
+ [ 'name' => " value\t " ]
+ )
+ );
+ }
+
+ public function testWhenUpperCaseIsUsedInTheName_itIsStillFound() {
+ $this->assertSame(
+ 'value',
+ ( new ParameterExtractor() )->extract(
+ [ 'name' ],
+ [ 'nAmE' => 'value' ]
+ )
+ );
+ }
+
+ public function testNameHasSpacesAroundIt_itIsStillFound() {
+ $this->assertSame(
+ 'value',
+ ( new ParameterExtractor() )->extract(
+ [ 'name' ],
+ [ ' name ' => 'value' ]
+ )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Unit/Semantic/DataValues/CoordinateValueTest.php b/www/wiki/extensions/Maps/tests/Unit/Semantic/DataValues/CoordinateValueTest.php
new file mode 100644
index 00000000..bbf8d0f1
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Unit/Semantic/DataValues/CoordinateValueTest.php
@@ -0,0 +1,113 @@
+<?php
+
+namespace Maps\Tests\Unit\Semantic\DataValues;
+
+use Maps\SemanticMW\DataValues\CoordinateValue;
+use Maps\SemanticMW\ValueDescriptions\AreaDescription;
+use Maps\SemanticMW\ValueDescriptions\CoordinateDescription;
+use PHPUnit\Framework\TestCase;
+use SMW\DataValueFactory;
+use SMWDataItem;
+use SMWDIGeoCoord;
+
+/**
+ * @covers \Maps\SemanticMW\ValueDescriptions\CoordinateValue
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class CoordinateValueTest extends TestCase {
+
+ public function setUp() {
+ if ( !defined( 'SMW_VERSION' ) ) {
+ $this->markTestSkipped( 'SMW is not available' );
+ }
+ }
+
+ public function testConstruct() {
+ $geoDI = new SMWDIGeoCoord( 23, 42 );
+
+ /**
+ * @var CoordinateValue $geoValue
+ */
+ $geoValue = DataValueFactory::newDataItemValue( $geoDI );
+
+ $this->assertInstanceOf( CoordinateValue::class, $geoValue );
+
+ $this->assertEquals( $geoDI, $geoValue->getDataItem() );
+ $this->assertSame( '23° 0\' 0.00" N, 42° 0\' 0.00" E', $geoValue->getShortWikiText() );
+ }
+
+ /**
+ * @dataProvider coordinateProvider
+ */
+ public function testGetQueryDescription( $lat, $long, $serialization ) {
+ $geoValue = $this->newInstance();
+
+ $description = $geoValue->getQueryDescription( $serialization );
+
+ $this->assertIsCorrectCoordValue( $description, $lat, $long );
+ }
+
+ protected function newInstance() {
+ return new CoordinateValue( SMWDataItem::TYPE_GEO );
+ }
+
+ private function assertIsCorrectCoordValue( $description, $lat, $long ) {
+ /**
+ * @var CoordinateDescription $description
+ */
+ $this->assertInstanceOf( CoordinateDescription::class, $description );
+ $this->assertEquals( $lat, $description->getDataItem()->getLatitude() );
+ $this->assertEquals( $long, $description->getDataItem()->getLongitude() );
+ }
+
+ public function coordinateProvider() {
+ return [
+ [
+ 23,
+ 42,
+ '23° 0\' 0", 42° 0\' 0"',
+ ],
+ [
+ 0,
+ 0,
+ '0° 0\' 0", 0° 0\' 0"',
+ ],
+ [
+ -23.5,
+ -42.5,
+ '-23° 30\' 0", -42° 30\' 0"',
+ ],
+ ];
+ }
+
+ /**
+ * @dataProvider coordinateWithDistanceProvider
+ */
+ public function testGetQueryDescriptionForArea( $serialization ) {
+ $geoValue = $this->newInstance();
+
+ $description = $geoValue->getQueryDescription( $serialization );
+
+ $this->assertInstanceOf( AreaDescription::class, $description );
+ }
+
+ public function coordinateWithDistanceProvider() {
+ return [
+ [
+ '23° 0\' 0", 42° 0\' 0"(1km)',
+ 1000,
+ ],
+ [
+ '0° 0\' 0", 0° 0\' 0" ( 1 m )',
+ 1,
+ ],
+ [
+ '-23° 30\' 0", -42° 30\' 0" (9001m)',
+ 9001,
+ ],
+ ];
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Util/PageCreator.php b/www/wiki/extensions/Maps/tests/Util/PageCreator.php
new file mode 100644
index 00000000..ca5ba675
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Util/PageCreator.php
@@ -0,0 +1,24 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Tests\Util;
+
+use Title;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class PageCreator {
+
+ public function createPage( string $title, string $content = null ) {
+ $page = new \WikiPage( Title::newFromText( $title ) );
+
+ $page->doEditContent(
+ new \WikitextContent( $content ?? 'Content of ' . $title ),
+ __CLASS__ . ' creating page ' . $title
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/Util/TestFactory.php b/www/wiki/extensions/Maps/tests/Util/TestFactory.php
new file mode 100644
index 00000000..286272d1
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/Util/TestFactory.php
@@ -0,0 +1,21 @@
+<?php
+
+declare( strict_types = 1 );
+
+namespace Maps\Tests\Util;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class TestFactory {
+
+ public static function newInstance(): self {
+ return new self();
+ }
+
+ public function getPageCreator(): PageCreator {
+ return new PageCreator();
+ }
+
+}
diff --git a/www/wiki/extensions/Maps/tests/bootstrap.php b/www/wiki/extensions/Maps/tests/bootstrap.php
new file mode 100644
index 00000000..1b0e39e5
--- /dev/null
+++ b/www/wiki/extensions/Maps/tests/bootstrap.php
@@ -0,0 +1,33 @@
+<?php
+
+if ( PHP_SAPI !== 'cli' ) {
+ die( 'Not an entry point' );
+}
+
+if ( defined( 'MEDIAWIKI' ) ) {
+ // If testing against an older version of MediaWiki, define
+ // an empty trait to avoid fatal errors.
+ if ( !trait_exists( PHPUnit4And6Compat::class ) ) {
+ trait PHPUnit4And6Compat {
+ public function expectException( string $exception ) {
+ $this->setExpectedException( $exception );
+ }
+ }
+ }
+
+ return;
+}
+
+if ( !trait_exists( PHPUnit4And6Compat::class ) ) {
+ trait PHPUnit4And6Compat {
+ }
+}
+
+error_reporting( -1 );
+ini_set( 'display_errors', 1 );
+
+if ( !is_readable( __DIR__ . '/../vendor/autoload.php' ) ) {
+ die( 'You need to install this package with Composer before you can run the tests' );
+}
+
+require __DIR__ . '/../vendor/autoload.php'; \ No newline at end of file
diff --git a/www/wiki/extensions/MultimediaViewer/.eslintrc.json b/www/wiki/extensions/MultimediaViewer/.eslintrc.json
new file mode 100644
index 00000000..488ab054
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.eslintrc.json
@@ -0,0 +1,15 @@
+{
+ "extends": "wikimedia",
+ "env": {
+ "browser": true,
+ "jquery": true,
+ "qunit": true
+ },
+ "globals": {
+ "OO": false,
+ "mediaWiki": false
+ },
+ "rules": {
+ "dot-notation": [ "error", { "allowKeywords": true } ]
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/.gitignore b/www/wiki/extensions/MultimediaViewer/.gitignore
new file mode 100644
index 00000000..574eea50
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.gitignore
@@ -0,0 +1,5 @@
+docs/
+node_modules/
+vendor/
+/composer.lock
+tests/phan/issues
diff --git a/www/wiki/extensions/MultimediaViewer/.gitreview b/www/wiki/extensions/MultimediaViewer/.gitreview
new file mode 100644
index 00000000..b156b5f0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.gitreview
@@ -0,0 +1,6 @@
+[gerrit]
+host=gerrit.wikimedia.org
+port=29418
+project=mediawiki/extensions/MultimediaViewer.git
+track=1
+defaultrebase=0 \ No newline at end of file
diff --git a/www/wiki/extensions/MultimediaViewer/.phpcs.xml b/www/wiki/extensions/MultimediaViewer/.phpcs.xml
new file mode 100644
index 00000000..93acceed
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.phpcs.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0"?>
+<ruleset>
+ <rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki">
+ <exclude name="MediaWiki.Commenting.FunctionComment.MissingDocumentationPublic" />
+ </rule>
+ <file>.</file>
+ <arg name="extensions" value="php,php5,inc" />
+ <arg name="encoding" value="UTF-8" />
+</ruleset>
diff --git a/www/wiki/extensions/MultimediaViewer/.rubocop.yml b/www/wiki/extensions/MultimediaViewer/.rubocop.yml
new file mode 100644
index 00000000..f4e4cba6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.rubocop.yml
@@ -0,0 +1,24 @@
+inherit_from: .rubocop_todo.yml
+
+AllCops:
+ # Only enforce rules that have an entry in the style guide
+ StyleGuideCopsOnly: true
+
+# uncomment when the offense is fixed
+# Metrics/LineLength:
+# Max: 100
+
+Metrics/MethodLength:
+ Enabled: false
+
+Style/Alias:
+ Enabled: false
+
+Style/SignalException:
+ Enabled: false
+
+Style/StringLiterals:
+ EnforcedStyle: single_quotes
+
+Style/TrivialAccessors:
+ ExactNameMatch: true
diff --git a/www/wiki/extensions/MultimediaViewer/.rubocop_todo.yml b/www/wiki/extensions/MultimediaViewer/.rubocop_todo.yml
new file mode 100644
index 00000000..f90453c4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.rubocop_todo.yml
@@ -0,0 +1,40 @@
+# This configuration was generated by
+# `rubocop --auto-gen-config`
+# on 2017-12-04 16:52:05 +0100 using RuboCop version 0.51.0.
+# The point is for the user to remove these configuration records
+# one by one as the offenses are removed from the code base.
+# Note that changes in the inspected code, or installation of new
+# versions of RuboCop, may require this file to be generated again.
+
+# Offense count: 1
+Lint/RescueWithoutErrorClass:
+ Exclude:
+ - 'tests/browser/features/step_definitions/mmv_steps.rb'
+
+# Offense count: 71
+# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
+# URISchemes: http, https
+Metrics/LineLength:
+ Max: 249
+
+# Offense count: 2
+# Configuration parameters: EnforcedStyle, SupportedStyles.
+# SupportedStyles: lowercase, uppercase
+Naming/HeredocDelimiterCase:
+ Exclude:
+ - 'tests/browser/features/support/pages/commons_page.rb'
+
+# Offense count: 4
+# Cop supports --auto-correct.
+Style/Encoding:
+ Exclude:
+ - 'tests/browser/features/step_definitions/mmv_download_steps.rb'
+ - 'tests/browser/features/step_definitions/mmv_navigation_steps.rb'
+ - 'tests/browser/features/step_definitions/mmv_options_steps.rb'
+ - 'tests/browser/features/step_definitions/mmv_steps.rb'
+
+# Offense count: 3
+# Configuration parameters: AllowedVariables.
+Style/GlobalVars:
+ Exclude:
+ - 'tests/browser/features/step_definitions/mmv_performance_steps.rb'
diff --git a/www/wiki/extensions/MultimediaViewer/.stylelintrc.json b/www/wiki/extensions/MultimediaViewer/.stylelintrc.json
new file mode 100644
index 00000000..cae35a02
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/.stylelintrc.json
@@ -0,0 +1,6 @@
+{
+ "extends": "stylelint-config-wikimedia",
+ "rules": {
+ "no-descending-specificity": null
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/AUTHORS b/www/wiki/extensions/MultimediaViewer/AUTHORS
new file mode 100644
index 00000000..f6bb5b1d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/AUTHORS
@@ -0,0 +1,24 @@
+* Mark Holmquist <mtraceur@member.fsf.org>
+* Gilles Dubuc <gdubuc@wikimedia.org>
+* Gergő Tisza <tgr.huwiki@gmail.com>
+* Aaron Arcos <aarcos.wiki@gmail.com>
+* Zeljko Filipin <zeljko.filipin@gmail.com>
+* Pau Giner <pau.giner@gmail.com>
+* theopolisme <theopolismewiki@gmail.com>
+* MatmaRex <matma.rex@gmail.com>
+* apsdehal <amanpreet.iitr2013@gmail.com>
+* vldandrew <vldandrew@gmail.com>
+* Ebrahim Byagowi <ebrahim@gnu.org>
+* Dereckson <dereckson@espace-win.org>
+* Brion VIBBER <brion@wikimedia.org>
+* Yuki Shira <shirayuking@gmail.com>
+* Yaroslav Melnychuk <yaroslavmelnuchuk@gmail.com>
+* tonythomas01 <01tonythomas@gmail.com>
+* raymond <raimond.spekking@gmail.com>
+* Kunal Mehta <legoktm@gmail.com>
+* Jeff Hall <jhall@wikimedia.org>
+* Christian Aistleitner <christian@quelltextlich.at>
+* Amir E. Aharoni <amir.aharoni@mail.huji.ac.il>
+
+Generated with git log --format='%aN <%aE>' | awk '{arr[$0]++} END{for (i in arr){print arr[i], i;}}' | sort -rn | cut -d\ -f2-
+Manually pruned for bots and duplicates
diff --git a/www/wiki/extensions/MultimediaViewer/CODE_OF_CONDUCT.md b/www/wiki/extensions/MultimediaViewer/CODE_OF_CONDUCT.md
new file mode 100644
index 00000000..d8e5d087
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/CODE_OF_CONDUCT.md
@@ -0,0 +1 @@
+The development of this software is covered by a [Code of Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
diff --git a/www/wiki/extensions/MultimediaViewer/COPYING b/www/wiki/extensions/MultimediaViewer/COPYING
new file mode 100644
index 00000000..d159169d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/COPYING
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/www/wiki/extensions/MultimediaViewer/Gemfile b/www/wiki/extensions/MultimediaViewer/Gemfile
new file mode 100644
index 00000000..591fd6bc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/Gemfile
@@ -0,0 +1,5 @@
+source 'https://rubygems.org'
+
+gem 'mediawiki_selenium', '~> 1.8'
+gem 'rake', '~> 11.1', '>= 11.1.1'
+gem 'rubocop', '~> 0.51.0', require: false
diff --git a/www/wiki/extensions/MultimediaViewer/Gemfile.lock b/www/wiki/extensions/MultimediaViewer/Gemfile.lock
new file mode 100644
index 00000000..1b16d93e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/Gemfile.lock
@@ -0,0 +1,113 @@
+GEM
+ remote: https://rubygems.org/
+ specs:
+ ast (2.3.0)
+ builder (3.2.3)
+ childprocess (0.6.2)
+ ffi (~> 1.0, >= 1.0.11)
+ cucumber (1.3.20)
+ builder (>= 2.1.2)
+ diff-lcs (>= 1.1.3)
+ gherkin (~> 2.12)
+ multi_json (>= 1.7.5, < 2.0)
+ multi_test (>= 0.1.2)
+ data_magic (1.0)
+ faker (>= 1.1.2)
+ yml_reader (>= 0.6)
+ diff-lcs (1.3)
+ domain_name (0.5.20170223)
+ unf (>= 0.0.5, < 1.0.0)
+ faker (1.7.3)
+ i18n (~> 0.5)
+ faraday (0.11.0)
+ multipart-post (>= 1.2, < 3)
+ faraday-cookie_jar (0.0.6)
+ faraday (>= 0.7.4)
+ http-cookie (~> 1.0.0)
+ faraday_middleware (0.11.0.1)
+ faraday (>= 0.7.4, < 1.0)
+ ffi (1.9.17)
+ gherkin (2.12.2)
+ multi_json (~> 1.3)
+ headless (2.3.1)
+ http-cookie (1.0.3)
+ domain_name (~> 0.5)
+ i18n (0.8.1)
+ json (2.0.3)
+ mediawiki_api (0.7.1)
+ faraday (~> 0.9, >= 0.9.0)
+ faraday-cookie_jar (~> 0.0, >= 0.0.6)
+ faraday_middleware (~> 0.10, >= 0.10.0)
+ mediawiki_selenium (1.8.0)
+ cucumber (~> 1.3, >= 1.3.20)
+ headless (~> 2.0, >= 2.1.0)
+ json (~> 2.0, >= 2.0.2)
+ mediawiki_api (~> 0.7, >= 0.7.0)
+ page-object (~> 2.0)
+ rest-client (~> 1.6, >= 1.6.7)
+ rspec-core (~> 2.14, >= 2.14.4)
+ rspec-expectations (~> 2.14, >= 2.14.4)
+ selenium-webdriver (~> 3.1.0)
+ syntax (~> 1.2, >= 1.2.0)
+ thor (~> 0.19, >= 0.19.1)
+ mime-types (2.99.3)
+ multi_json (1.12.1)
+ multi_test (0.1.2)
+ multipart-post (2.0.0)
+ net-http-persistent (2.9.4)
+ netrc (0.11.0)
+ page-object (2.0.0)
+ net-http-persistent (~> 2.9.4)
+ page_navigation (>= 0.9)
+ selenium-webdriver (~> 3.0)
+ watir (~> 6.0)
+ page_navigation (0.10)
+ data_magic (>= 0.22)
+ parallel (1.12.0)
+ parser (2.4.0.2)
+ ast (~> 2.3)
+ powerpack (0.1.1)
+ rainbow (2.2.2)
+ rake
+ rake (11.1.1)
+ rest-client (1.8.0)
+ http-cookie (>= 1.0.2, < 2.0)
+ mime-types (>= 1.16, < 3.0)
+ netrc (~> 0.7)
+ rspec-core (2.99.2)
+ rspec-expectations (2.99.2)
+ diff-lcs (>= 1.1.3, < 2.0)
+ rubocop (0.51.0)
+ parallel (~> 1.10)
+ parser (>= 2.3.3.1, < 3.0)
+ powerpack (~> 0.1)
+ rainbow (>= 2.2.2, < 3.0)
+ ruby-progressbar (~> 1.7)
+ unicode-display_width (~> 1.0, >= 1.0.1)
+ ruby-progressbar (1.9.0)
+ rubyzip (1.2.1)
+ selenium-webdriver (3.1.0)
+ childprocess (~> 0.5)
+ rubyzip (~> 1.0)
+ websocket (~> 1.0)
+ syntax (1.2.1)
+ thor (0.19.4)
+ unf (0.1.4)
+ unf_ext
+ unf_ext (0.0.7.2)
+ unicode-display_width (1.3.0)
+ watir (6.2.0)
+ selenium-webdriver (~> 3.0)
+ websocket (1.2.4)
+ yml_reader (0.7)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ mediawiki_selenium (~> 1.8)
+ rake (~> 11.1, >= 11.1.1)
+ rubocop (~> 0.51.0)
+
+BUNDLED WITH
+ 1.16.0
diff --git a/www/wiki/extensions/MultimediaViewer/Gruntfile.js b/www/wiki/extensions/MultimediaViewer/Gruntfile.js
new file mode 100644
index 00000000..fe6aacc5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/Gruntfile.js
@@ -0,0 +1,72 @@
+/* eslint-env node */
+
+module.exports = function ( grunt ) {
+ var conf = grunt.file.readJSON( 'extension.json' );
+
+ grunt.loadNpmTasks( 'grunt-banana-checker' );
+ grunt.loadNpmTasks( 'grunt-eslint' );
+ grunt.loadNpmTasks( 'grunt-jsonlint' );
+ grunt.loadNpmTasks( 'grunt-stylelint' );
+ grunt.loadNpmTasks( 'grunt-svgmin' );
+
+ grunt.initConfig( {
+ banana: conf.MessagesDirs,
+ jsonlint: {
+ all: [
+ '**/*.json',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ },
+ eslint: {
+ all: [
+ '*.js',
+ 'resources/mmv/**/*.js',
+ 'tests/**/*.js'
+ ]
+ },
+ stylelint: {
+ options: {
+ syntax: 'less'
+ },
+ src: 'resources/mmv/**/*.{css,less}'
+ },
+ // Image Optimization
+ svgmin: {
+ options: {
+ js2svg: {
+ pretty: true
+ },
+ plugins: [ {
+ cleanupIDs: false
+ }, {
+ removeDesc: false
+ }, {
+ removeRasterImages: true
+ }, {
+ removeTitle: false
+ }, {
+ removeViewBox: false
+ }, {
+ removeXMLProcInst: false
+ }, {
+ sortAttrs: true
+ } ]
+ },
+ all: {
+ files: [ {
+ expand: true,
+ cwd: 'resources',
+ src: [
+ '**/*.svg'
+ ],
+ dest: 'resources/',
+ ext: '.svg'
+ } ]
+ }
+ }
+ } );
+
+ grunt.registerTask( 'test', [ 'eslint', 'stylelint', 'svgmin', 'jsonlint', 'banana' ] );
+ grunt.registerTask( 'default', 'test' );
+};
diff --git a/www/wiki/extensions/MultimediaViewer/MultimediaViewer.php b/www/wiki/extensions/MultimediaViewer/MultimediaViewer.php
new file mode 100644
index 00000000..fbeaa54f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/MultimediaViewer.php
@@ -0,0 +1,132 @@
+<?php
+/**
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * @file
+ * @ingroup extensions
+ * @author Mark Holmquist <mtraceur@member.fsf.org>
+ * @copyright Copyright © 2013, Mark Holmquist
+ */
+
+if ( function_exists( 'wfLoadExtension' ) ) {
+ wfLoadExtension( 'MultimediaViewer' );
+ // Keep i18n globals so mergeMessageFileList.php doesn't break
+ $wgMessagesDirs['MultimediaViewer'] = __DIR__ . '/i18n';
+ /* wfWarn(
+ 'Deprecated PHP entry point used for MultimediaViewer extension. ' .
+ 'Please use wfLoadExtension instead, ' .
+ 'see https://www.mediawiki.org/wiki/Extension_registration for more details.'
+ ); */
+ return;
+} else {
+ die( 'This version of the MultimediaViewer extension requires MediaWiki 1.25+' );
+}
+
+// The following is for the purposes of IDEs and documentation. It is not
+// executed.
+
+/**
+ * If set, records image load network performance via
+ * EventLogging once per this many requests. False if unset.
+ *
+ * @var int|bool
+ */
+$wgMediaViewerNetworkPerformanceSamplingFactor = false;
+
+/**
+ * If set, records loading times via EventLogging. A value of 1000 means there will be an
+ * 1:1000 chance to log the duration event.
+ * False if unset.
+ * @var int|bool
+ */
+$wgMediaViewerDurationLoggingSamplingFactor = false;
+
+/**
+ * If set, records loading times via EventLogging with factor specific to loggedin users.
+ * A value of 1000 means there will be an 1:1000 chance to log the duration event.
+ * False if unset.
+ * @var int|bool
+ */
+$wgMediaViewerDurationLoggingLoggedinSamplingFactor = false;
+
+/**
+ * If set, records whether image attribution data was available.
+ * A value of 1000 means there will be an 1:1000 chance to log the attribution event.
+ * False if unset.
+ * @var int|bool
+ */
+$wgMediaViewerAttributionLoggingSamplingFactor = false;
+
+/**
+ * If set, records whether image dimension data was available.
+ * A value of 1000 means there will be an 1:1000 chance to log the dimension event.
+ * False if unset.
+ * @var int|bool
+ */
+$wgMediaViewerDimensionLoggingSamplingFactor = false;
+
+/**
+ * If set, records user actions via EventLogging and applies a sampling factor according
+ * to the map. A "default" key in the map must be set.
+ * False if unset.
+ * @var array|bool
+ */
+$wgMediaViewerActionLoggingSamplingFactorMap = false;
+
+/**
+ * If set, Media Viewer will try to use BetaFeatures. False if unset.
+ * @var bool
+ */
+$wgMediaViewerIsInBeta = false;
+
+/**
+ * When this is enabled, MediaViewer will try to guess image URLs instead of making an
+ * imageinfo API to get them from the server. This speeds up image loading, but will
+ * result in 404s when $wgGenerateThumbnailOnParse (so the thumbnails are only generated
+ * as a result of the API request). MediaViewer will catch such 404 errors and fall back
+ * to the API request, but depending on how the site is set up, the 404 might get cached,
+ * or redirected, causing the image load to fail. The safe way to use URL guessing is
+ * with a 404 handler: https://www.mediawiki.org/wiki/Manual:Thumb.php#404_Handler
+ *
+ * @var bool
+ */
+$wgMediaViewerUseThumbnailGuessing = false;
+
+/**
+ * If trueish, and $wgMediaViewerIsInBeta is unset,
+ * Media Viewer will be turned on by default.
+ * @var bool
+ */
+$wgMediaViewerEnableByDefault = true;
+
+/**
+ * Overrides $wgMediaViewerEnableByDefault for anonymous users. If
+ * set to null, will fall back to value of $wgMediaViewerEnableByDefault
+ * @var bool|null
+ */
+$wgMediaViewerEnableByDefaultForAnonymous = null;
+
+/**
+ * If set, adds a query parameter to image requests made by Media Viewer
+ * @var string|bool
+ */
+$wgMediaViewerImageQueryParameter = false;
+
+/**
+ * If set, records a virtual view via the provided beacon URI.
+ * @var string|bool
+ */
+$wgMediaViewerRecordVirtualViewBeaconURI = false;
diff --git a/www/wiki/extensions/MultimediaViewer/Rakefile b/www/wiki/extensions/MultimediaViewer/Rakefile
new file mode 100644
index 00000000..2877bf69
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/Rakefile
@@ -0,0 +1,17 @@
+require 'bundler/setup'
+
+require 'rubocop/rake_task'
+RuboCop::RakeTask.new(:rubocop) do |task|
+ # if you use mediawiki-vagrant, rubocop will by default use it's .rubocop.yml
+ # the next line makes it explicit that you want .rubocop.yml from the directory
+ # where `bundle exec rake` is executed
+ task.options = ['-c', '.rubocop.yml']
+end
+
+require 'mediawiki_selenium/rake_task'
+MediawikiSelenium::RakeTask.new
+
+task default: [:test]
+
+desc 'Run all build/tests commands (CI entry point)'
+task test: [:rubocop]
diff --git a/www/wiki/extensions/MultimediaViewer/composer.json b/www/wiki/extensions/MultimediaViewer/composer.json
new file mode 100644
index 00000000..0107a5d4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/composer.json
@@ -0,0 +1,20 @@
+{
+ "require-dev": {
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
+ },
+ "scripts": {
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
+ "test": [
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
+ ]
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/extension.json b/www/wiki/extensions/MultimediaViewer/extension.json
new file mode 100644
index 00000000..0ae6b5ad
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/extension.json
@@ -0,0 +1,444 @@
+{
+ "name": "MultimediaViewer",
+ "author": [
+ "MarkTraceur (Mark Holmquist)",
+ "Gilles Dubuc",
+ "Gergő Tisza",
+ "Aaron Arcos",
+ "Zeljko Filipin",
+ "Pau Giner",
+ "theopolisme",
+ "MatmaRex",
+ "apsdehal",
+ "vldandrew",
+ "Ebrahim Byagowi",
+ "Dereckson",
+ "Brion VIBBER",
+ "Yuki Shira",
+ "Yaroslav Melnychuk",
+ "tonythomas01",
+ "Raimond Spekking",
+ "Kunal Mehta",
+ "Jeff Hall",
+ "Christian Aistleitner",
+ "Amir E. Aharoni"
+ ],
+ "url": "https://mediawiki.org/wiki/Extension:MultimediaViewer",
+ "descriptionmsg": "multimediaviewer-desc",
+ "license-name": "GPL-2.0-or-later",
+ "type": "other",
+ "ExtensionFunctions": [
+ "MultimediaViewerHooks::onExtensionFunctions"
+ ],
+ "MessagesDirs": {
+ "MultimediaViewer": [
+ "i18n"
+ ]
+ },
+ "AutoloadClasses": {
+ "MultimediaViewerHooks": "includes/MultimediaViewerHooks.php"
+ },
+ "ResourceModules": {
+ "mmv": {
+ "scripts": [
+ "mmv/logging/mmv.logging.Api.js",
+ "mmv/logging/mmv.logging.AttributionLogger.js",
+ "mmv/logging/mmv.logging.DimensionLogger.js",
+ "mmv/logging/mmv.logging.ViewLogger.js",
+ "mmv/logging/mmv.logging.PerformanceLogger.js",
+ "mmv/routing/mmv.routing.js",
+ "mmv/routing/mmv.routing.Route.js",
+ "mmv/routing/mmv.routing.ThumbnailRoute.js",
+ "mmv/routing/mmv.routing.MainFileRoute.js",
+ "mmv/routing/mmv.routing.Router.js",
+ "mmv/model/mmv.model.js",
+ "mmv/model/mmv.model.IwTitle.js",
+ "mmv/model/mmv.model.License.js",
+ "mmv/model/mmv.model.Image.js",
+ "mmv/model/mmv.model.Repo.js",
+ "mmv/model/mmv.model.Thumbnail.js",
+ "mmv/model/mmv.model.TaskQueue.js",
+ "mmv/model/mmv.model.ThumbnailWidth.js",
+ "mmv/mmv.lightboximage.js",
+ "mmv/provider/mmv.provider.Api.js",
+ "mmv/provider/mmv.provider.ImageInfo.js",
+ "mmv/provider/mmv.provider.FileRepoInfo.js",
+ "mmv/provider/mmv.provider.ThumbnailInfo.js",
+ "mmv/provider/mmv.provider.GuessedThumbnailInfo.js",
+ "mmv/provider/mmv.provider.Image.js",
+ "mmv/mmv.ThumbnailWidthCalculator.js",
+ "mmv/ui/mmv.ui.js",
+ "mmv/ui/mmv.ui.dialog.js",
+ "mmv/ui/mmv.ui.reuse.dialog.js",
+ "mmv/ui/mmv.ui.download.js",
+ "mmv/ui/mmv.ui.download.dialog.js",
+ "mmv/ui/mmv.ui.description.js",
+ "mmv/ui/mmv.ui.viewingOptions.js",
+ "mmv/ui/mmv.ui.canvas.js",
+ "mmv/ui/mmv.ui.canvasButtons.js",
+ "mmv/ui/mmv.ui.permission.js",
+ "mmv/ui/mmv.ui.progressBar.js",
+ "mmv/ui/mmv.ui.stripeButtons.js",
+ "mmv/ui/mmv.ui.truncatableTextField.js",
+ "mmv/ui/mmv.ui.metadataPanel.js",
+ "mmv/ui/mmv.ui.metadataPanelScroller.js",
+ "mmv/mmv.lightboxinterface.js",
+ "mmv/mmv.js"
+ ],
+ "styles": [
+ "mmv/ui/mmv.ui.dialog.less",
+ "mmv/ui/mmv.ui.reuse.dialog.less",
+ "mmv/ui/mmv.ui.download.dialog.less",
+ "mmv/ui/mmv.ui.viewingOptions.less",
+ "mmv/ui/mmv.ui.canvas.less",
+ "mmv/ui/mmv.ui.canvasButtons.less",
+ "mmv/ui/mmv.ui.permission.less",
+ "mmv/ui/mmv.ui.progressBar.less",
+ "mmv/ui/mmv.ui.stripeButtons.less",
+ "mmv/ui/mmv.ui.truncatableTextField.less",
+ "mmv/ui/mmv.ui.metadataPanel.less",
+ "mmv/ui/mmv.ui.metadataPanelScroller.less",
+ "mmv/mmv.lightboxinterface.less"
+ ],
+ "dependencies": [
+ "mediawiki.api",
+ "mediawiki.Title",
+ "mediawiki.Uri",
+ "mediawiki.jqueryMsg",
+ "mediawiki.storage",
+ "oojs",
+ "jquery.fullscreen",
+ "jquery.hidpi",
+ "jquery.throttle-debounce",
+ "jquery.color",
+ "jquery.tipsy",
+ "mmv.bootstrap",
+ "mmv.head"
+ ],
+ "messages": [
+ "multimediaviewer-file-page",
+ "multimediaviewer-options-learn-more",
+ "multimediaviewer-options-dialog-header",
+ "multimediaviewer-option-submit-button",
+ "multimediaviewer-option-cancel-button",
+ "multimediaviewer-options-text-header",
+ "multimediaviewer-enable-alert",
+ "multimediaviewer-options-text-body",
+ "multimediaviewer-disable-confirmation-header",
+ "multimediaviewer-disable-confirmation-text",
+ "multimediaviewer-enable-dialog-header",
+ "multimediaviewer-enable-text-header",
+ "multimediaviewer-enable-submit-button",
+ "multimediaviewer-enable-confirmation-header",
+ "multimediaviewer-enable-confirmation-text",
+ "multimediaviewer-thumbnail-error",
+ "multimediaviewer-thumbnail-error-description",
+ "multimediaviewer-thumbnail-error-retry",
+ "multimediaviewer-report-issue-url",
+ "multimediaviewer-thumbnail-error-report",
+ "multimediaviewer-errorreport-privacywarning",
+ "multimediaviewer-download-link",
+ "multimediaviewer-reuse-link",
+ "multimediaviewer-options-tooltip",
+ "multimediaviewer-close-popup-text",
+ "multimediaviewer-fullscreen-popup-text",
+ "multimediaviewer-defullscreen-popup-text",
+ "multimediaviewer-next-image-alt-text",
+ "multimediaviewer-prev-image-alt-text",
+ "multimediaviewer-commons-subtitle",
+ "multimediaviewer-credit",
+ "multimediaviewer-credit-fallback",
+ "multimediaviewer-multiple-authors",
+ "multimediaviewer-multiple-authors-combine",
+ "multimediaviewer-datetime-created",
+ "multimediaviewer-datetime-uploaded",
+ "multimediaviewer-permission-link",
+ "multimediaviewer-permission-link-hide",
+ "multimediaviewer-restriction-2257",
+ "multimediaviewer-restriction-aus-reserve",
+ "multimediaviewer-restriction-communist",
+ "multimediaviewer-restriction-costume",
+ "multimediaviewer-restriction-currency",
+ "multimediaviewer-restriction-design",
+ "multimediaviewer-restriction-fan-art",
+ "multimediaviewer-restriction-ihl",
+ "multimediaviewer-restriction-insignia",
+ "multimediaviewer-restriction-ita-mibac",
+ "multimediaviewer-restriction-nazi",
+ "multimediaviewer-restriction-personality",
+ "multimediaviewer-restriction-trademarked",
+ "multimediaviewer-restriction-default",
+ "multimediaviewer-restriction-default-and-others",
+ "multimediaviewer-reuse-warning-deletion",
+ "multimediaviewer-reuse-warning-nonfree",
+ "multimediaviewer-reuse-warning-noattribution",
+ "multimediaviewer-reuse-warning-generic",
+ "multimediaviewer-geoloc-north",
+ "multimediaviewer-geoloc-east",
+ "multimediaviewer-geoloc-south",
+ "multimediaviewer-geoloc-west",
+ "multimediaviewer-geoloc-coord",
+ "multimediaviewer-geoloc-coords",
+ "multimediaviewer-geolocation",
+ "multimediaviewer-about-mmv",
+ "multimediaviewer-discuss-mmv",
+ "multimediaviewer-help-mmv",
+ "multimediaviewer-optout-mmv",
+ "multimediaviewer-optin-mmv",
+ "multimediaviewer-optout-pending-mmv",
+ "multimediaviewer-optin-pending-mmv",
+ "multimediaviewer-optout-help",
+ "multimediaviewer-optin-help",
+ "mypreferences",
+ "multimediaviewer-metadata-error",
+ "multimediaviewer-title-popup-text",
+ "multimediaviewer-credit-popup-text",
+ "multimediaviewer-title-popup-text-more",
+ "multimediaviewer-credit-popup-text-more",
+ "multimediaviewer-permission-title",
+ "multimediaviewer-permission-viewmore",
+ "multimediaviewer-description-page-button-text",
+ "multimediaviewer-description-page-popup-text",
+ "multimediaviewer-repository-local",
+ "multimediaviewer-license-cc-by-1.0",
+ "multimediaviewer-license-cc-sa-1.0",
+ "multimediaviewer-license-cc-by-sa-1.0",
+ "multimediaviewer-license-cc-by-2.0",
+ "multimediaviewer-license-cc-by-sa-2.0",
+ "multimediaviewer-license-cc-by-2.1",
+ "multimediaviewer-license-cc-by-sa-2.1",
+ "multimediaviewer-license-cc-by-2.5",
+ "multimediaviewer-license-cc-by-sa-2.5",
+ "multimediaviewer-license-cc-by-3.0",
+ "multimediaviewer-license-cc-by-sa-3.0",
+ "multimediaviewer-license-cc-by-4.0",
+ "multimediaviewer-license-cc-by-sa-4.0",
+ "multimediaviewer-license-cc-pd",
+ "multimediaviewer-license-cc-zero",
+ "multimediaviewer-license-pd",
+ "multimediaviewer-license-default"
+ ]
+ },
+ "mmv.ui.ondemandshareddependencies": {
+ "scripts": [
+ "mmv/model/mmv.model.EmbedFileInfo.js",
+ "mmv/mmv.EmbedFileFormatter.js",
+ "mmv/ui/mmv.ui.utils.js"
+ ],
+ "dependencies": [
+ "mmv.head",
+ "mmv",
+ "oojs",
+ "oojs-ui"
+ ],
+ "messages": [
+ "multimediaviewer-credit",
+ "multimediaviewer-text-embed-credit-text-bl",
+ "multimediaviewer-text-embed-credit-text-b",
+ "multimediaviewer-text-embed-credit-text-l",
+ "multimediaviewer-html-embed-credit-text-bl",
+ "multimediaviewer-html-embed-credit-text-b",
+ "multimediaviewer-html-embed-credit-text-l",
+ "multimediaviewer-html-embed-credit-link-text"
+ ]
+ },
+ "mmv.ui.download.pane": {
+ "scripts": [
+ "mmv/ui/mmv.ui.download.pane.js"
+ ],
+ "styles": [
+ "mmv/ui/mmv.ui.download.pane.less"
+ ],
+ "dependencies": [
+ "mediawiki.ui",
+ "mediawiki.ui.button",
+ "mmv",
+ "mmv.ui.ondemandshareddependencies",
+ "oojs",
+ "oojs-ui"
+ ],
+ "messages": [
+ "multimediaviewer-download-preview-link-title",
+ "multimediaviewer-download-original-button-name",
+ "multimediaviewer-download-small-button-name",
+ "multimediaviewer-download-medium-button-name",
+ "multimediaviewer-download-large-button-name",
+ "multimediaviewer-embed-dimensions",
+ "multimediaviewer-embed-dimensions-with-file-format",
+ "multimediaviewer-download-attribution-cta-header",
+ "multimediaviewer-download-optional-attribution-cta-header",
+ "multimediaviewer-download-attribution-cta",
+ "multimediaviewer-download-attribution-copy",
+ "multimediaviewer-attr-plain",
+ "multimediaviewer-attr-html"
+ ]
+ },
+ "mmv.ui.reuse.shareembed": {
+ "scripts": [
+ "mmv/ui/mmv.ui.reuse.tab.js",
+ "mmv/ui/mmv.ui.reuse.share.js",
+ "mmv/ui/mmv.ui.reuse.embed.js"
+ ],
+ "styles": [
+ "mmv/ui/mmv.ui.reuse.share.less",
+ "mmv/ui/mmv.ui.reuse.embed.less",
+ "mmv/ui/mmv.ui.reuse.shareembed.less"
+ ],
+ "dependencies": [
+ "jquery.tipsy",
+ "oojs",
+ "oojs-ui",
+ "mediawiki.user",
+ "mmv.ui.ondemandshareddependencies"
+ ],
+ "messages": [
+ "multimediaviewer-reuse-loading-placeholder",
+ "multimediaviewer-share-tab",
+ "multimediaviewer-share-explanation",
+ "multimediaviewer-link-to-file",
+ "multimediaviewer-link-to-page",
+ "multimediaviewer-reuse-loading-placeholder",
+ "multimediaviewer-reuse-copy-share",
+ "multimediaviewer-reuse-copy-embed",
+ "multimediaviewer-embed-tab",
+ "multimediaviewer-embed-html",
+ "multimediaviewer-embed-wt",
+ "multimediaviewer-embed-explanation",
+ "multimediaviewer-embed-byline",
+ "multimediaviewer-embed-license",
+ "multimediaviewer-embed-via",
+ "multimediaviewer-default-embed-dimensions",
+ "multimediaviewer-original-embed-dimensions",
+ "multimediaviewer-large-embed-dimensions",
+ "multimediaviewer-medium-embed-dimensions",
+ "multimediaviewer-small-embed-dimensions",
+ "multimediaviewer-embed-dimensions",
+ "multimediaviewer-embed-dimensions-separated"
+ ]
+ },
+ "mmv.ui.tipsyDialog": {
+ "scripts": [
+ "mmv/ui/mmv.ui.tipsyDialog.js"
+ ],
+ "styles": [
+ "mmv/ui/mmv.ui.tipsyDialog.less"
+ ],
+ "dependencies": [
+ "mmv",
+ "oojs",
+ "jquery.tipsy"
+ ]
+ },
+ "mmv.bootstrap": {
+ "scripts": [
+ "mmv/mmv.Config.js",
+ "mmv/mmv.HtmlUtils.js",
+ "mmv/mmv.bootstrap.js",
+ "mmv/logging/mmv.logging.Logger.js",
+ "mmv/logging/mmv.logging.ActionLogger.js",
+ "mmv/logging/mmv.logging.DurationLogger.js",
+ "jquery.hashchange/jquery.hashchange.js"
+ ],
+ "styles": [
+ "mmv/mmv.bootstrap.less"
+ ],
+ "dependencies": [
+ "mediawiki.api",
+ "mediawiki.api.options",
+ "mediawiki.ui.button",
+ "mediawiki.ui.icon",
+ "mediawiki.Title",
+ "mediawiki.user",
+ "mediawiki.storage",
+ "mmv.head",
+ "oojs"
+ ],
+ "messages": [
+ "multimediaviewer-view-expanded",
+ "multimediaviewer-view-config",
+ "multimediaviewer-disable-info-title",
+ "multimediaviewer-disable-info"
+ ]
+ },
+ "mmv.bootstrap.autostart": {
+ "scripts": [
+ "mmv/mmv.bootstrap.autostart.js"
+ ],
+ "dependencies": [
+ "mmv.head",
+ "mmv.bootstrap"
+ ]
+ },
+ "mmv.head": {
+ "scripts": [
+ "mmv/mmv.base.js",
+ "mmv/mmv.head.js"
+ ],
+ "dependencies": [
+ "mediawiki.user",
+ "mediawiki.storage"
+ ],
+ "position": "top"
+ }
+ },
+ "ResourceFileModulePaths": {
+ "localBasePath": "resources",
+ "remoteExtPath": "MultimediaViewer/resources"
+ },
+ "Hooks": {
+ "EventLoggingRegisterSchemas": [
+ "MultimediaViewerHooks::onEventLoggingRegisterSchemas"
+ ],
+ "UserGetDefaultOptions": [
+ "MultimediaViewerHooks::onUserGetDefaultOptions"
+ ],
+ "GetPreferences": [
+ "MultimediaViewerHooks::getPreferences"
+ ],
+ "GetBetaFeaturePreferences": [
+ "MultimediaViewerHooks::getBetaPreferences"
+ ],
+ "BeforePageDisplay": [
+ "MultimediaViewerHooks::getModulesForArticle"
+ ],
+ "CategoryPageView": [
+ "MultimediaViewerHooks::getModulesForCategory"
+ ],
+ "ResourceLoaderGetConfigVars": [
+ "MultimediaViewerHooks::resourceLoaderGetConfigVars"
+ ],
+ "MakeGlobalVariablesScript": [
+ "MultimediaViewerHooks::makeGlobalVariablesScript"
+ ],
+ "ResourceLoaderTestModules": [
+ "MultimediaViewerHooks::getTestModules"
+ ],
+ "ThumbnailBeforeProduceHTML": [
+ "MultimediaViewerHooks::thumbnailBeforeProduceHTML"
+ ]
+ },
+ "config": {
+ "MediaViewerExtensions": {
+ "jpg": "default",
+ "jpeg": "default",
+ "gif": "default",
+ "svg": "default",
+ "png": "default",
+ "tiff": "default",
+ "tif": "default"
+ },
+ "MediaViewerNetworkPerformanceSamplingFactor": false,
+ "MediaViewerDurationLoggingSamplingFactor": false,
+ "MediaViewerDurationLoggingLoggedinSamplingFactor": false,
+ "MediaViewerAttributionLoggingSamplingFactor": false,
+ "MediaViewerDimensionLoggingSamplingFactor": false,
+ "MediaViewerActionLoggingSamplingFactorMap": false,
+ "MediaViewerIsInBeta": false,
+ "MediaViewerUseThumbnailGuessing": false,
+ "MediaViewerEnableByDefault": true,
+ "MediaViewerEnableByDefaultForAnonymous": null,
+ "MediaViewerImageQueryParameter": false,
+ "MediaViewerRecordVirtualViewBeaconURI": false
+ },
+ "manifest_version": 1
+}
diff --git a/www/wiki/extensions/MultimediaViewer/gitinfo.json b/www/wiki/extensions/MultimediaViewer/gitinfo.json
new file mode 100644
index 00000000..88dd2ef0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/gitinfo.json
@@ -0,0 +1 @@
+{"headSHA1": "1273d3e0b2189e33fed0567f589a3e7bc4ae6d4e\n", "head": "1273d3e0b2189e33fed0567f589a3e7bc4ae6d4e\n", "remoteURL": "https://gerrit.wikimedia.org/r/mediawiki/extensions/MultimediaViewer", "branch": "1273d3e0b2189e33fed0567f589a3e7bc4ae6d4e\n", "headCommitDate": "1526068630"} \ No newline at end of file
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/af.json b/www/wiki/extensions/MultimediaViewer/i18n/af.json
new file mode 100644
index 00000000..a6b160ab
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/af.json
@@ -0,0 +1,103 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fwolff"
+ ]
+ },
+ "multimediaviewer-pref": "Mediakyker",
+ "multimediaviewer-optin-pref": "Aktiveer <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Mediakyker]</span>",
+ "multimediaviewer-file-page": "Besoek die ooreenstemmende lêerbladsy",
+ "multimediaviewer-repository-local": "Meer besonderhede",
+ "multimediaviewer-datetime-created": "Geskep: $1",
+ "multimediaviewer-datetime-uploaded": "Opgelaai: $1",
+ "multimediaviewer-credit-fallback": "Bekyk outeurinligting",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|nog een outeur|nog $1 outeurs}}",
+ "multimediaviewer-multiple-authors-combine": "$1 en $2",
+ "multimediaviewer-metadata-error": "Kon nie die beeld se besonderhede laai nie (fout: $1)",
+ "multimediaviewer-thumbnail-error": "Jammer! Die lêer kan nie vertoon word nie",
+ "multimediaviewer-thumbnail-error-retry": "probeer weer",
+ "multimediaviewer-license-cc-pd": "Publieke domein",
+ "multimediaviewer-license-pd": "Publieke domein",
+ "multimediaviewer-license-default": "Sien lisensie",
+ "multimediaviewer-permission-title": "Detail van toestemming",
+ "multimediaviewer-permission-link": "sien voorwaardes",
+ "multimediaviewer-permission-link-hide": "versteek voorwaardes",
+ "multimediaviewer-permission-viewmore": "Wys meer",
+ "multimediaviewer-about-mmv": "Aangaande",
+ "multimediaviewer-discuss-mmv": "Bespreking",
+ "multimediaviewer-help-mmv": "Hulp",
+ "multimediaviewer-optout-mmv": "Deaktiveer Mediakyker",
+ "multimediaviewer-optin-mmv": "Aktiveer Mediakyker",
+ "multimediaviewer-optout-pending-mmv": "Deaktiveer tans Mediakyker",
+ "multimediaviewer-optin-pending-mmv": "Aktiveer tans Mediakyker",
+ "multimediaviewer-optout-help": "Mediakyker sal nie meer gebruik word om beelde te wys nie. Om dit weer te gebruik, klik op die \"{{int:multimediaviewer-view-expanded}}\"-knop langs enige beeld. Klik dan op \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Mediakyker sal gebruik word om beelde te wys.",
+ "multimediaviewer-geolocation": "Ligging: $1",
+ "multimediaviewer-reuse-link": "Deel dié lêer of bed dit in",
+ "multimediaviewer-reuse-loading-placeholder": "Laai tans…",
+ "multimediaviewer-reuse-copy-share": "Merk en kopieer (indien ondersteun) die skakel om dié lêer te deel",
+ "multimediaviewer-reuse-copy-embed": "Merk en kopieer (indien ondersteun) die skakel om dié lêer in te bed",
+ "multimediaviewer-share-tab": "Deel",
+ "multimediaviewer-embed-tab": "Bed in",
+ "multimediaviewer-download-link": "Laai dié lêer af",
+ "multimediaviewer-download-preview-link-title": "Bekyk in blaaier",
+ "multimediaviewer-download-original-button-name": "Laai oorspronklike lêer af",
+ "multimediaviewer-download-small-button-name": "Laai klein grootte af",
+ "multimediaviewer-download-medium-button-name": "Laai mediumgrootte af",
+ "multimediaviewer-download-large-button-name": "Laai groot grootte af",
+ "multimediaviewer-link-to-page": "Skakel na die lêer se beskrywingsblad",
+ "multimediaviewer-link-to-file": "Skakel na oorspronklike lêer",
+ "multimediaviewer-share-explanation": "Kopieer en deel gerus die skakel",
+ "multimediaviewer-embed-wt": "Wikiteks",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Gebruik dié kode om die lêer in te bed",
+ "multimediaviewer-text-embed-credit-text-bl": "Deur $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Deur $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Deur $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Deur $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Skakel",
+ "multimediaviewer-embed-byline": "Deur $1",
+ "multimediaviewer-embed-license": "Gelisensieer onderhewig aan $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Verstekgrootte vir duimnael",
+ "multimediaviewer-original-embed-dimensions": "Oorspronklike lêer $1",
+ "multimediaviewer-large-embed-dimensions": "Groot $1",
+ "multimediaviewer-medium-embed-dimensions": "Medium $1",
+ "multimediaviewer-small-embed-dimensions": "Klein $1",
+ "multimediaviewer-description-page-button-text": "Meer besonderhede oor dié lêer",
+ "multimediaviewer-description-page-popup-text": "Meer besonderhede oor dié lêer by $1",
+ "multimediaviewer-commons-subtitle": "Die vry mediastoorplek",
+ "multimediaviewer-view-expanded": "Open in Mediakyker",
+ "multimediaviewer-view-config": "Instellings",
+ "multimediaviewer-close-popup-text": "Sluit dié aansig (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Wys in volle skerm",
+ "multimediaviewer-defullscreen-popup-text": "Verlaat volle skerm",
+ "multimediaviewer-next-image-alt-text": "Wys volgende beeld",
+ "multimediaviewer-prev-image-alt-text": "Wys vorige beeld",
+ "multimediaviewer-title-popup-text": "Beskrywing",
+ "multimediaviewer-credit-popup-text": "Outeur- en broninligting",
+ "multimediaviewer-title-popup-text-more": "Sien volle beskrywing",
+ "multimediaviewer-credit-popup-text-more": "Sien volle outeur en bron",
+ "multimediaviewer-download-attribution-cta-header": "Die outeur se naam moet vermeld word",
+ "multimediaviewer-download-optional-attribution-cta-header": "Die outeur se naam kan vermeld word",
+ "multimediaviewer-download-attribution-cta": "Wys my hoe",
+ "multimediaviewer-download-attribution-copy": "Merk en kopieer (indien ondersteun) die die outeursvermelding vir dié lêer",
+ "multimediaviewer-attr-plain": "Eenvoudig",
+ "multimediaviewer-options-tooltip": "Aktiveer of deaktiveer Mediakyker",
+ "multimediaviewer-options-dialog-header": "Deaktiveer Mediakyker?",
+ "multimediaviewer-options-text-header": "Slaan hierdie aansig vir alle lêers oor.",
+ "multimediaviewer-options-text-body": "Dit kan later weer geaktiveer word op die lêer se besonderhedebladsy.",
+ "multimediaviewer-options-learn-more": "Meer inligting",
+ "multimediaviewer-option-submit-button": "Deaktiveer Mediakyker",
+ "multimediaviewer-option-cancel-button": "Kanselleer",
+ "multimediaviewer-disable-confirmation-header": "Mediakyker is gedeaktiveer",
+ "multimediaviewer-disable-confirmation-text": "Met die volgende klik op 'n duimnael op $1, sal u direk die lêerbesonderhede sien.",
+ "multimediaviewer-enable-dialog-header": "Aktiveer Mediakyker?",
+ "multimediaviewer-enable-text-header": "Aktiveer dié manier om media te kyk by verstek vir alle lêers.",
+ "multimediaviewer-enable-submit-button": "Aktiveer Mediakyker",
+ "multimediaviewer-enable-confirmation-header": "Mediakyker is geaktiveer vir alle lêers",
+ "multimediaviewer-enable-confirmation-text": "Met die volgende klik op 'n duimnael op $1 sal Mediakyker gebruik word.",
+ "multimediaviewer-enable-alert": "Mediakyker is nou gedaktiveerd",
+ "multimediaviewer-disable-info-title": "Mediakyker is gedeaktiveer",
+ "multimediaviewer-disable-info": "Dit is steeds moontlik om individuele lêers met Mediakyker te bekyk."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ais.json b/www/wiki/extensions/MultimediaViewer/i18n/ais.json
new file mode 100644
index 00000000..6f73fe43
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ais.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Benel"
+ ]
+ },
+ "multimediaviewer-geolocation": "kahicelaan: $1",
+ "multimediaviewer-reuse-loading-placeholder": "miasip henay ayza...",
+ "multimediaviewer-embed-wt": "Wikitext"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ar.json b/www/wiki/extensions/MultimediaViewer/i18n/ar.json
new file mode 100644
index 00000000..c4e45550
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ar.json
@@ -0,0 +1,133 @@
+{
+ "@metadata": {
+ "authors": [
+ "Claw eg",
+ "Tarawneh",
+ "مشعل الحربي",
+ "زكريا",
+ "OsamaK",
+ "محمد أحمد عبد الفتاح",
+ "Maroen1990",
+ "ديفيد"
+ ]
+ },
+ "multimediaviewer-desc": "زيادة حجم الصور المصغرة في واجهة ملء الشاشة.",
+ "multimediaviewer-pref": "عارض الوسائط",
+ "multimediaviewer-pref-desc": "حسن تجربة مشاهدة الوسائط المتعددة بهذه الأداة الجديدة، حيث تعمل على عرض الصور بحجم أكبر على الصفحات التي تحتوي صورا مصغرة. وتظهر الصور في صندوق منبثق أجمل، ويمكن أيضا عرضها بالحجم الكامل.",
+ "multimediaviewer-optin-pref": "تمكين <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About عارض الوسائط]</span>",
+ "multimediaviewer-file-page": "الذهاب إلى الصفحة التابعة للملف",
+ "multimediaviewer-repository-local": "مزيد من التفاصيل",
+ "multimediaviewer-datetime-created": "الإنشاء: $1",
+ "multimediaviewer-datetime-uploaded": "الرفع: $1",
+ "multimediaviewer-credit-fallback": "اعرض معلومات المؤلف",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|مؤلف واحد آخر|$1 مؤلفين آخرين}}",
+ "multimediaviewer-multiple-authors-combine": "$1 و$2",
+ "multimediaviewer-metadata-error": "خطأ: تعذر تحميل بيانات الصورة(خطا: $1)",
+ "multimediaviewer-thumbnail-error": "خطأ: تعذر تحميل الملف معطل",
+ "multimediaviewer-thumbnail-error-description": "يبدو أن هناك مشكلة فنية، يمكنك $1 أو $3 إذا استمرت، الخطأ: $2",
+ "multimediaviewer-thumbnail-error-retry": "أعد المحاولة",
+ "multimediaviewer-thumbnail-error-report": "أبلغ عن المشكلة",
+ "multimediaviewer-license-cc-pd": "ملكية عامة",
+ "multimediaviewer-license-pd": "ملكية عامة",
+ "multimediaviewer-license-default": "عرض الترخيص",
+ "multimediaviewer-permission-title": "تفاصيل الترخيص",
+ "multimediaviewer-permission-link": "راجع الشروط",
+ "multimediaviewer-permission-link-hide": "أخف الشروط",
+ "multimediaviewer-permission-viewmore": "عرض المزيد",
+ "multimediaviewer-restriction-aus-reserve": "تم تصوير هذه الصورة في محمية كومنولث الأسترالية ولا يمكن استخدامها لتحقيق مكاسب تجارية دون تصريح.",
+ "multimediaviewer-restriction-communist": "تحتوي هذه الصورة على شارات شيوعية يمكن حظرها في بعض الدول.",
+ "multimediaviewer-restriction-costume": "تعرض هذه الصورة إلباسا وقد تخضع لقيود قانونية.",
+ "multimediaviewer-restriction-currency": "تمثل هذه الصورة صورة لوحدة عملة وقد تخضع لقيود قانونية.",
+ "multimediaviewer-restriction-design": "قد يكون تصميم موضوع هذه الصورة محميا بحقوق الطبع والنشر وخاضعا لقيود قانونية.",
+ "multimediaviewer-restriction-fan-art": "هذه الصورة عمل فني للمعجبين، وقد تخضع إعادة الاستخدام لقيود قانونية.",
+ "multimediaviewer-restriction-ihl": "تحتوي هذه الصورة على رموز مقيدة بموجب القانون الدولي الإنساني.",
+ "multimediaviewer-restriction-insignia": "تحتوي هذه الصورة على شارة رسمية قد تخضع لقيود قانونية.",
+ "multimediaviewer-restriction-ita-mibac": "تستنسخ هذه الصورة ملكية تابعة للتراث الثقافي الإيطالي وتقتصر على القانون الإيطالي.",
+ "multimediaviewer-restriction-nazi": "تحتوي هذه الصورة على شارات نازية أو فاشية أخرى قد يتم حظرها في بعض الدول.",
+ "multimediaviewer-restriction-personality": "تحتوي هذه الصورة على أشخاص قد تكون لهم حقوق تقيد بشكل قانوني استخدامات معينة من الصورة بدون موافقة.",
+ "multimediaviewer-restriction-trademarked": "هذه الصورة تتضمن محتوى قد يخضع لقوانين العلامات التجارية.",
+ "multimediaviewer-restriction-default": "قد تكون هذه الصورة مقيدة بأحكام قانونية خارج قانون حقوق النشر، انظر صفحة وصف الملف للتفاصيل.",
+ "multimediaviewer-restriction-default-and-others": "يمكن تقييد هذه الصورة بمقتضى أحكام قانونية أخرى خارج قانون حقوق النشر، انظر صفحة وصف الملف للتفاصيل.",
+ "multimediaviewer-about-mmv": "حول",
+ "multimediaviewer-discuss-mmv": "نقاش",
+ "multimediaviewer-help-mmv": "مساعدة",
+ "multimediaviewer-optout-mmv": "تعطيل عارض الوسائط",
+ "multimediaviewer-optin-mmv": "مكّن عارض الوسائط",
+ "multimediaviewer-optout-pending-mmv": "يُعطّل عارض الوسائط",
+ "multimediaviewer-optin-pending-mmv": "يُفعّل عارض الوسائط",
+ "multimediaviewer-optout-help": "لن يستخدم عارض الوسائط لإظهار الصور، لتستخدمه مجددا انقر زر \"{{int:multimediaviewer-view-expanded}}\" بجانب أية صورة ثم انقر \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "سيُستخدَم عارض الوسائط لمشاهدة الصور.",
+ "multimediaviewer-geolocation": "المكان: $1",
+ "multimediaviewer-reuse-link": "شارك أو ضمن هذا الملف",
+ "multimediaviewer-reuse-loading-placeholder": "تحميل...",
+ "multimediaviewer-reuse-copy-share": "حدد وانسخ (إذا كان مدعوما) الرابط لمشاركة هذا الملف",
+ "multimediaviewer-reuse-copy-embed": "حدد وانسخ (إذا كان مدعوما) رمز تضمين هذا الملف",
+ "multimediaviewer-share-tab": "شارك",
+ "multimediaviewer-embed-tab": "ضمّن",
+ "multimediaviewer-download-link": "نزّل هذا الملف",
+ "multimediaviewer-download-preview-link-title": "اعرض في المتصفح",
+ "multimediaviewer-download-original-button-name": "نزّل الملف الأصلي",
+ "multimediaviewer-download-small-button-name": "نزّل بحجم صغير",
+ "multimediaviewer-download-medium-button-name": "نزّل بحجم متوسط",
+ "multimediaviewer-download-large-button-name": "نزّل بحجم كبير",
+ "multimediaviewer-link-to-page": "وصلة لصفحة وصف الملف",
+ "multimediaviewer-link-to-file": "وصلة للملف الأصلي",
+ "multimediaviewer-share-explanation": "انسخ الرابط وانشره",
+ "multimediaviewer-embed-wt": "نص ويكي",
+ "multimediaviewer-embed-html": "إتش تي إم إل",
+ "multimediaviewer-embed-explanation": "استخدم هذا الكود لتضمين الملف",
+ "multimediaviewer-text-embed-credit-text-bl": "بواسطة $1 و$2 و$3",
+ "multimediaviewer-text-embed-credit-text-b": "بواسطة $1 و$2",
+ "multimediaviewer-html-embed-credit-text-bl": "بواسطة $1 و$2 و$3",
+ "multimediaviewer-html-embed-credit-text-b": "بواسطة $1 و$2",
+ "multimediaviewer-html-embed-credit-link-text": "رابط",
+ "multimediaviewer-embed-byline": "صاحب العمل: $1",
+ "multimediaviewer-embed-license": "الترخيص: $1",
+ "multimediaviewer-embed-via": "المصدر: $1",
+ "multimediaviewer-default-embed-dimensions": "الحجم الافتراضي للصورة المصغرة",
+ "multimediaviewer-original-embed-dimensions": "الملف الأصلي $1",
+ "multimediaviewer-large-embed-dimensions": "كبير $1",
+ "multimediaviewer-medium-embed-dimensions": "متوسط $1",
+ "multimediaviewer-small-embed-dimensions": "صغير $1",
+ "multimediaviewer-description-page-button-text": "المزيد من التفاصيل عن هذا الملف",
+ "multimediaviewer-description-page-popup-text": "تفاصيل أكثر عن هذا الملف على $1",
+ "multimediaviewer-commons-subtitle": "مستودع الوسائط الحر",
+ "multimediaviewer-view-expanded": "افتح في عارض الوسائط",
+ "multimediaviewer-view-config": "ضبط",
+ "multimediaviewer-close-popup-text": "إغلاق هذه الأداة (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "إظهار ملء كاملة",
+ "multimediaviewer-defullscreen-popup-text": "إغلاق ملء الشاشة",
+ "multimediaviewer-next-image-alt-text": "إظهار الصورة التالية",
+ "multimediaviewer-prev-image-alt-text": "عرض الصورة السابقة",
+ "multimediaviewer-title-popup-text": "الوصف",
+ "multimediaviewer-credit-popup-text": "معلومات المؤلف والمصدر",
+ "multimediaviewer-title-popup-text-more": "اعرض الوصف الكامل",
+ "multimediaviewer-credit-popup-text-more": "اعرض المؤلف والمصدر كاملين",
+ "multimediaviewer-download-attribution-cta-header": "يجب أن تنسب للمؤلف",
+ "multimediaviewer-download-optional-attribution-cta-header": "يمكنك أن تنسب للمؤلف",
+ "multimediaviewer-download-attribution-cta": "أرني كيف",
+ "multimediaviewer-download-attribution-copy": "حدد وانسخ (إذا كان مدعوما) نص الإحالة لهذا الملف",
+ "multimediaviewer-reuse-warning-deletion": "تم اقتراح حذف هذا الملف.",
+ "multimediaviewer-reuse-warning-nonfree": "لا يحتوي هذا الملف على ترخيص حر.",
+ "multimediaviewer-reuse-warning-noattribution": "لا يحتوي هذا الملف على معلومات إحالة.",
+ "multimediaviewer-reuse-warning-generic": "تحقق من [$1 تفاصيله] قبل استخدامه.",
+ "multimediaviewer-attr-plain": "عادي",
+ "multimediaviewer-options-tooltip": "فعل أو عطل عارض الوسائط",
+ "multimediaviewer-options-dialog-header": "تعطيل عارض الوسائط؟",
+ "multimediaviewer-options-text-header": "تخطي ميزة العرض هذه لجميع الملفات.",
+ "multimediaviewer-options-text-body": "يمكنك تمكينه لاحقا من خلال صفحة تفاصيل الملف.",
+ "multimediaviewer-options-learn-more": "تعرف على المزيد",
+ "multimediaviewer-option-submit-button": "عطل عارض الوسائط",
+ "multimediaviewer-option-cancel-button": "ألغ",
+ "multimediaviewer-disable-confirmation-header": "لقد عطلت عارض الوسائط",
+ "multimediaviewer-disable-confirmation-text": "في المرة التالية التي تنقر فيها على الصورة المصغرة في $1، ستقوم بعرض كل تفاصيل الملف مباشرة.",
+ "multimediaviewer-enable-dialog-header": "تفعيل عارض الوسائط؟",
+ "multimediaviewer-enable-text-header": "تمكين ميزة عرض الوسائط هذه لجميع الملفات افتراضيا.",
+ "multimediaviewer-enable-submit-button": "تفعيل عارض الوسائط",
+ "multimediaviewer-enable-confirmation-header": "لقد فعلت عارض الوسائط لكل الملفات",
+ "multimediaviewer-enable-confirmation-text": "في المرة التالية التي تنقر فيها على الصورة المصغرة في $1 ، سيتم استخدام عارض الوسائط.",
+ "multimediaviewer-enable-alert": "عارض الوسائط غير مفعل الآن",
+ "multimediaviewer-disable-info-title": "لقد عطلت عارض الوسائط",
+ "multimediaviewer-disable-info": "ما زال بإمكانك عرض الملفات المنفردة بعارض الوسائط.",
+ "multimediaviewer-errorreport-privacywarning": "يتم إرفاق تفاصيل الخطأ بالتقرير، والذي سيكون قابلا للعرض للجمهور، إذا لم تكن مرتاحا لذلك، فيمكنك تحرير التقرير أدناه وإزالة جميع البيانات التي لا تريد مشاركتها."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/as.json b/www/wiki/extensions/MultimediaViewer/i18n/as.json
new file mode 100644
index 00000000..8a691464
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/as.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bishnu Saikia",
+ "Dibya Dutta"
+ ]
+ },
+ "multimediaviewer-thumbnail-error-description": "কিবা কৌশলগত সমস্যা থাকিব পাৰে। আপুনি $1 বা $3 কৰিব পাৰে। ক্ৰুটি: $2",
+ "multimediaviewer-thumbnail-error-report": "সমস্যাটো অভিযোগ কৰক",
+ "multimediaviewer-share-tab": "বিতৰণ",
+ "multimediaviewer-download-preview-link-title": "ডাউনল’ড",
+ "multimediaviewer-download-original-button-name": "প্ৰকৃত আকৃতি ডাউনল’ড কৰক",
+ "multimediaviewer-download-large-button-name": "ডাঙৰ আকৃতি ডাউনল’ড কৰক",
+ "multimediaviewer-embed-wt": "ৱিকিপাঠ্য",
+ "multimediaviewer-embed-byline": "$1 ৰ দ্বাৰা",
+ "multimediaviewer-title-popup-text": "বিৱৰণ",
+ "multimediaviewer-title-popup-text-more": "সম্পূৰ্ণ বিৱৰণ চাওক"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ast.json b/www/wiki/extensions/MultimediaViewer/i18n/ast.json
new file mode 100644
index 00000000..ddce17a5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ast.json
@@ -0,0 +1,127 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xuacu"
+ ]
+ },
+ "multimediaviewer-desc": "Espande les miniatures a mayor tamañu nuna interfaz a pantalla completa.",
+ "multimediaviewer-pref": "Visor de medios",
+ "multimediaviewer-pref-desc": "Ameyore la esperiencia al ver multimedia con esta nueva ferramienta. Amuesa les imaxes a mayor tamañu nes páxines que tienen miniatures. Les imaxes vense nuna guapa capa a pantalla completa, y puen vese tamién a tamañu completu.",
+ "multimediaviewer-optin-pref": "Activar el <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About visor de multimedia]</span>",
+ "multimediaviewer-file-page": "Dir a la páxina del ficheru correspondiente",
+ "multimediaviewer-repository-local": "Más detalles",
+ "multimediaviewer-datetime-created": "Creáu: $1",
+ "multimediaviewer-datetime-uploaded": "Xubíu: $1",
+ "multimediaviewer-credit-fallback": "Ver información del autor",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|un autor más|$1 autores más}}",
+ "multimediaviewer-multiple-authors-combine": "$1 y $2",
+ "multimediaviewer-metadata-error": "Nun pudieron cargase los datos de la imaxe (error: $1)",
+ "multimediaviewer-thumbnail-error": "Nun ye posible amosar el ficheru",
+ "multimediaviewer-thumbnail-error-description": "Paez qu'hai un problema téunicu. Pues $1 o $3 si siguiera produciéndose. Error: $2",
+ "multimediaviewer-thumbnail-error-retry": "reintentar",
+ "multimediaviewer-thumbnail-error-report": "informar del problema",
+ "multimediaviewer-license-cc-pd": "Dominiu públicu",
+ "multimediaviewer-license-pd": "Dominiu públicu",
+ "multimediaviewer-license-default": "Ver la llicencia",
+ "multimediaviewer-permission-title": "Detalles del permisu",
+ "multimediaviewer-permission-link": "ver los términos",
+ "multimediaviewer-permission-link-hide": "anubrir condiciones",
+ "multimediaviewer-permission-viewmore": "Ver más",
+ "multimediaviewer-restriction-2257": "Esta imaxe tien conteníu sexual esplícitu que podría tar suxetu al ''Child Protection and Obscenity Enforcement Act'' nos Estaos Xunios d'América.",
+ "multimediaviewer-restriction-aus-reserve": "Esta imaxe tomóse n'una reserva de la Commonwealth Australiana y nun pué usase pa tener ganancies comerciales sin permisu.",
+ "multimediaviewer-restriction-communist": "Esta imaxe contien insinies comunistes que podríen tar torgaes en determinaos paises.",
+ "multimediaviewer-restriction-costume": "Esta imaxe amuesa vistidures y podría tar suxeta a torgues llegales.",
+ "multimediaviewer-restriction-currency": "Esta imaxe amuesa una imaxe d'una unidá monetaria y podría tar suxeta a torgues llegales.",
+ "multimediaviewer-restriction-design": "El diseñu del tema d'esta imaxe pué tener drechos d'autor y tar suxetu a torgues llegales.",
+ "multimediaviewer-restriction-fan-art": "Esta imaxe ye un trabayu artísticu d'un fan, y re-usala podría tar suxeto a torgues llegales.",
+ "multimediaviewer-restriction-ihl": "Esta imaxe contien símbolos torgaos pol Drechu Humanitariu Internacional.",
+ "multimediaviewer-restriction-insignia": "Esta imaxe amuesa insinies oficiales y podría tar suxeta a torgues llegales.",
+ "multimediaviewer-restriction-ita-mibac": "Esta imaxe reproduz una propiedá que pertenez al patrimoniu cultural italianu y ta torgada pola llei italiana.",
+ "multimediaviewer-restriction-nazi": "Esta imaxe contien insinies nazis o fascistes que podríen tar torgaes en determinaos paises.",
+ "multimediaviewer-restriction-personality": "Esta imaxe contien persones que puen tener drechos que torguen llegalmente ciertes re-utilizaciones de la imaxe sin el so consentimientu.",
+ "multimediaviewer-restriction-trademarked": "Esta imaxe tien conteníu que pué tar suxetu a les lleis de marques rexistraes.",
+ "multimediaviewer-restriction-default": "Esta imaxe pué tar torgada por otres disposiciones llegales distintes de la llei de propiedá intelectual. Mira la páxina de descripción del ficheru pa más detalles.",
+ "multimediaviewer-restriction-default-and-others": "Esta imaxe pué tar inda más torgada por otres disposiciones llegales distintes de la llei de propiedá intelectual. Mira la páxina de descripción del ficheru pa más detalles.",
+ "multimediaviewer-about-mmv": "Tocante a",
+ "multimediaviewer-discuss-mmv": "Alderique",
+ "multimediaviewer-help-mmv": "Ayuda",
+ "multimediaviewer-optout-mmv": "Desactivar el visor de multimedia",
+ "multimediaviewer-optin-mmv": "Activar el visor de multimedia",
+ "multimediaviewer-optout-pending-mmv": "Desactivando el visor de multimedia",
+ "multimediaviewer-optin-pending-mmv": "Activando el visor de multimedia",
+ "multimediaviewer-optout-help": "El Visor de multimedia yá nun s'usará pa ver les imaxes. Pa volver a usalu, fai clic nel botón «{{int:multimediaviewer-view-expanded}}» cabo cada imaxe. Darréu fai clic en «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Agora les imaxes abriránse col visor de multimedia.",
+ "multimediaviewer-geolocation": "Allugamientu: $1",
+ "multimediaviewer-reuse-link": "Compartir o incrustar esti ficheru",
+ "multimediaviewer-reuse-loading-placeholder": "Cargando...",
+ "multimediaviewer-reuse-copy-share": "Seleicionar y copiar (si hai encontu) l'enllaz pa compartir esti ficheru",
+ "multimediaviewer-reuse-copy-embed": "Seleicionar y copiar (si hai encontu) el códigu pa embrivir esti ficheru",
+ "multimediaviewer-share-tab": "Compartir",
+ "multimediaviewer-embed-tab": "Incrustar",
+ "multimediaviewer-download-link": "Descargar esti ficheru",
+ "multimediaviewer-download-preview-link-title": "Ver nel navegador",
+ "multimediaviewer-download-original-button-name": "Descargar el ficheru orixinal",
+ "multimediaviewer-download-small-button-name": "Descargar el tamañu pequeñu",
+ "multimediaviewer-download-medium-button-name": "Descargar el tamañu medianu",
+ "multimediaviewer-download-large-button-name": "Descargar el tamañu grande",
+ "multimediaviewer-link-to-page": "Enllaz a la páxina de descripción del ficheru",
+ "multimediaviewer-link-to-file": "Enllaz al ficheru orixinal",
+ "multimediaviewer-share-explanation": "Copiar y compartir llibremente l'enllaz",
+ "multimediaviewer-embed-wt": "Testu wiki",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Usar esti códigu pa incrustar el ficheru",
+ "multimediaviewer-text-embed-credit-text-bl": "Por $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Por $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Por $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Por $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Enllaz",
+ "multimediaviewer-embed-byline": "Por $1",
+ "multimediaviewer-embed-license": "Baxo la llicencia $1.",
+ "multimediaviewer-embed-via": "Vía $1.",
+ "multimediaviewer-default-embed-dimensions": "Tamañu de miniatura predetermináu",
+ "multimediaviewer-original-embed-dimensions": "Ficheru orixinal $1",
+ "multimediaviewer-large-embed-dimensions": "Grande $1",
+ "multimediaviewer-medium-embed-dimensions": "Medianu $1",
+ "multimediaviewer-small-embed-dimensions": "Pequeñu $1",
+ "multimediaviewer-description-page-button-text": "Más detalles d'esti ficheru",
+ "multimediaviewer-description-page-popup-text": "Más detalles d'esti ficheru en $1",
+ "multimediaviewer-commons-subtitle": "El depósitu de multimedia llibre",
+ "multimediaviewer-view-expanded": "Abrir nel visor de multimedia",
+ "multimediaviewer-view-config": "Configuración",
+ "multimediaviewer-close-popup-text": "Zarrar esta ferramienta (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Ver a pantalla completa",
+ "multimediaviewer-defullscreen-popup-text": "Colar de pantalla completa",
+ "multimediaviewer-next-image-alt-text": "Amosar la imaxe siguiente",
+ "multimediaviewer-prev-image-alt-text": "Amosar la imaxe anterior",
+ "multimediaviewer-title-popup-text": "Descripción",
+ "multimediaviewer-credit-popup-text": "Información del autor y la fonte",
+ "multimediaviewer-title-popup-text-more": "Ver la descripción completa",
+ "multimediaviewer-credit-popup-text-more": "Ver completos l'autor y la fonte",
+ "multimediaviewer-download-attribution-cta-header": "Ye necesario da-y reconocimientu al autor",
+ "multimediaviewer-download-optional-attribution-cta-header": "Puedes dar reconocimientu al autor",
+ "multimediaviewer-download-attribution-cta": "Amosame cómo",
+ "multimediaviewer-download-attribution-copy": "Seleicionar y copiar (si hai encontu) el testu d'atribución d'esti ficheru",
+ "multimediaviewer-reuse-warning-deletion": "Ta considerándose'l borráu d'esti ficheru.",
+ "multimediaviewer-reuse-warning-nonfree": "Esti ficheru nun tien una llicencia llibre.",
+ "multimediaviewer-reuse-warning-noattribution": "Esti ficheru nun tien información d'atribución.",
+ "multimediaviewer-reuse-warning-generic": "Comprueba [$1 los detalles] antes d'utilizalu.",
+ "multimediaviewer-attr-plain": "Testu planu",
+ "multimediaviewer-options-tooltip": "Activar o desactivar el Visor de multimedia",
+ "multimediaviewer-options-dialog-header": "¿Desactivar el visor de multimedia?",
+ "multimediaviewer-options-text-header": "Saltar esta función de visión pa tolos ficheros.",
+ "multimediaviewer-options-text-body": "Pues activalla más sero na páxina de detalles del ficheru.",
+ "multimediaviewer-options-learn-more": "Más información",
+ "multimediaviewer-option-submit-button": "Desactivar el visor de multimedia",
+ "multimediaviewer-option-cancel-button": "Encaboxar",
+ "multimediaviewer-disable-confirmation-header": "Desactivasti el visor de multimedia",
+ "multimediaviewer-disable-confirmation-text": "La siguiente vez que faigas clic n'una miniatura en $1, verás direutamente los detalles del ficheru.",
+ "multimediaviewer-enable-dialog-header": "¿Activar el visor de multimedia?",
+ "multimediaviewer-enable-text-header": "Activar esta función de visión pa tolos ficheros de mou predetermináu.",
+ "multimediaviewer-enable-submit-button": "Activar el visor de multimedia",
+ "multimediaviewer-enable-confirmation-header": "Activasti el visor de multimedia pa tolos ficheros",
+ "multimediaviewer-enable-confirmation-text": "La siguiente vez que faigas clic n'una miniatura en $1, usaráse'l Visor de multimedia.",
+ "multimediaviewer-enable-alert": "El Visor de multimedia agora ta desactiváu",
+ "multimediaviewer-disable-info-title": "Desactivasti el visor de multimedia",
+ "multimediaviewer-disable-info": "Inda pues ver los ficheros individualmente col Visor de multimedia.",
+ "multimediaviewer-errorreport-privacywarning": "Los detalles del error axúntense al informe, que va ser visible públicamente. Si nun tas cómodu con eso, pues editar l'informe más abaxo y desaniciar tolos datos que nun quixeras compartir."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/atj.json b/www/wiki/extensions/MultimediaViewer/i18n/atj.json
new file mode 100644
index 00000000..2f394562
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/atj.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Benoit Rochon"
+ ]
+ },
+ "multimediaviewer-about-mmv": "Enko nehe",
+ "multimediaviewer-title-popup-text": "E witcikemakak"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/av.json b/www/wiki/extensions/MultimediaViewer/i18n/av.json
new file mode 100644
index 00000000..171ccdef
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/av.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Аль-Гимравий"
+ ]
+ },
+ "multimediaviewer-discuss-mmv": "Гьоркьоб лъей"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/az.json b/www/wiki/extensions/MultimediaViewer/i18n/az.json
new file mode 100644
index 00000000..05cbaeac
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/az.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Serkanland",
+ "Wertuose"
+ ]
+ },
+ "multimediaviewer-help-mmv": "Kömək",
+ "multimediaviewer-optin-mmv": "Media nümayişetdiricisini işə sal"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/bcl.json b/www/wiki/extensions/MultimediaViewer/i18n/bcl.json
new file mode 100644
index 00000000..6f65ee9e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/bcl.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Geopoet"
+ ]
+ },
+ "multimediaviewer-permission-title": "Mga detalye kan Lisensiya",
+ "multimediaviewer-permission-link": "Hilngon an mga termino",
+ "multimediaviewer-optin-help": "Parapahiling sa Media gagamiton sa pagpapahiling nin mga imahe."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/be-tarask.json b/www/wiki/extensions/MultimediaViewer/i18n/be-tarask.json
new file mode 100644
index 00000000..d2c31bb1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/be-tarask.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Red Winged Duck"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Уключыць <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About мэдыяпраглядальнік]</span>",
+ "multimediaviewer-repository-local": "Падрабязьней",
+ "multimediaviewer-datetime-created": "Створаны: $1",
+ "multimediaviewer-permission-link": "паказаць умовы",
+ "multimediaviewer-about-mmv": "Апісаньне",
+ "multimediaviewer-discuss-mmv": "Абмеркаваньне",
+ "multimediaviewer-help-mmv": "Даведка",
+ "multimediaviewer-optin-mmv": "Уключыць мэдыяпраглядальнік",
+ "multimediaviewer-geolocation": "Месцазнаходжаньне: $1",
+ "multimediaviewer-reuse-link": "Падзяліцца або выкарыстаць гэты файл",
+ "multimediaviewer-share-tab": "Падзяліцца",
+ "multimediaviewer-embed-tab": "Выкарыстаць",
+ "multimediaviewer-download-link": "Спампаваць гэты файл",
+ "multimediaviewer-share-explanation": "Скапіюйце і свабодна дзяліцеся спасылкай",
+ "multimediaviewer-embed-wt": "Вікітэкст",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Выкарыстоўвайце гэты код для ўстаўкі файла",
+ "multimediaviewer-default-embed-dimensions": "Памер мініятуры па змоўчаньні",
+ "multimediaviewer-original-embed-dimensions": "Першапачатковы файл $1",
+ "multimediaviewer-large-embed-dimensions": "Вялікі памер $1",
+ "multimediaviewer-medium-embed-dimensions": "Сярэдні памер $1",
+ "multimediaviewer-small-embed-dimensions": "Малы памер $1",
+ "multimediaviewer-view-expanded": "Адкрыць у мэдыяпраглядальніку",
+ "multimediaviewer-close-popup-text": "Закрыць гэты інструмэнт (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Паказаць на ўвесь экран",
+ "multimediaviewer-options-tooltip": "Уключыць або выключыць мэдыяпраглядальнік",
+ "multimediaviewer-options-dialog-header": "Адключыць мэдыяпраглядальнік?",
+ "multimediaviewer-options-text-header": "Адключыць гэтую функцыю прагляду для ўсіх файлаў.",
+ "multimediaviewer-options-text-body": "Вы можаце потым уключыць яго на старонцы зьвестак пра файл.",
+ "multimediaviewer-options-learn-more": "Даведацца болей",
+ "multimediaviewer-option-submit-button": "Адключыць мэдыяпраглядальнік",
+ "multimediaviewer-option-cancel-button": "Адмяніць",
+ "multimediaviewer-disable-confirmation-header": "Вы адключылі мэдыяпраглядальнік",
+ "multimediaviewer-disable-confirmation-text": "Наступны раз, калі вы націсьніце на мініятуру на сайце $1, вы наўпрост пабачыце ўсе зьвесткі пра файл.",
+ "multimediaviewer-enable-text-header": "Уключыць гэтую функцыю мэдыяпрагляду па змоўчаньні для ўсіх файлаў.",
+ "multimediaviewer-enable-submit-button": "Уключыць мэдыяпраглядальнік",
+ "multimediaviewer-enable-confirmation-header": "Вы ўключылі мэдыяпраглядальнік для ўсіх файлаў",
+ "multimediaviewer-enable-confirmation-text": "Наступны раз, калі вы націсьніце на мініятуру на сайце $1, будзе выкарыстаны мэдыяпраглядальнік.",
+ "multimediaviewer-enable-alert": "Мэдыяпраглядальнік цяпер адключаны"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/be.json b/www/wiki/extensions/MultimediaViewer/i18n/be.json
new file mode 100644
index 00000000..0f6f23a8
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/be.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Artsiom91"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Уключыць <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Праглядчык медыяфайлаў]</span>",
+ "multimediaviewer-optin-mmv": "Уключыць «Праглядчык медыяфайлаў»"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/bg.json b/www/wiki/extensions/MultimediaViewer/i18n/bg.json
new file mode 100644
index 00000000..55ecd376
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/bg.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mitzev",
+ "DCLXVI",
+ "Vodnokon4e",
+ "StanProg",
+ "ShockD"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Включване на <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-datetime-created": "Създадено: $1",
+ "multimediaviewer-permission-title": "Информация за лиценза",
+ "multimediaviewer-permission-link": "вижте условията",
+ "multimediaviewer-permission-viewmore": "Вижте още",
+ "multimediaviewer-optin-mmv": "Включване на Media Viewer",
+ "multimediaviewer-share-tab": "Споделяне",
+ "multimediaviewer-title-popup-text": "Описание",
+ "multimediaviewer-title-popup-text-more": "Разгледай пълно описание",
+ "multimediaviewer-credit-popup-text-more": "Покажи пълна информация за автора и източника"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/bgn.json b/www/wiki/extensions/MultimediaViewer/i18n/bgn.json
new file mode 100644
index 00000000..945328e7
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/bgn.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ibrahim khashrowdi"
+ ]
+ },
+ "multimediaviewer-about-mmv": "بِه باره‌ئا",
+ "multimediaviewer-discuss-mmv": "حبر/گپ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/bn.json b/www/wiki/extensions/MultimediaViewer/i18n/bn.json
new file mode 100644
index 00000000..68978576
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/bn.json
@@ -0,0 +1,130 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aftab1995",
+ "Tauhid16",
+ "Aftabuzzaman",
+ "Macofe"
+ ]
+ },
+ "multimediaviewer-desc": "একটি পূর্ণস্ক্রিন ইন্টারফেসের মধ্যে একটি বড় মাপের থাম্বনেল প্রসারিত করে।",
+ "multimediaviewer-pref": "মিডিয়া ভিউয়ার",
+ "multimediaviewer-pref-desc": "এই নতুন সরঞ্জামটি দিয়ে মাল্টিমিডিয়া দেখার নতুন অভিজ্ঞতা নিন। এটা থাম্বনেল আছে এমন পাতায় বড় মাপের চিত্র প্রদর্শন করে। চিত্র পর্দা জুড়ে প্রদর্শন ইন্টারফেস বাক্সে প্রদর্শিত হয়, এছাড়াও পূর্ণ মাপ দেখা যাবে।",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About মিডিয়া ভিউয়ার]</span> সক্রিয় করো",
+ "multimediaviewer-file-page": "সংশ্লিষ্ট ফাইল পৃষ্ঠাতে যান",
+ "multimediaviewer-repository-local": "আরো বিস্তারিত",
+ "multimediaviewer-datetime-created": "তৈরী হয়েছে: $1",
+ "multimediaviewer-datetime-uploaded": "আপলোড হয়েছে: $1",
+ "multimediaviewer-credit-fallback": "প্রণেতার তথ্য দেখুন",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|আরও একজন প্রণেতা|আরও $1 জন প্রণেতা}}",
+ "multimediaviewer-multiple-authors-combine": "$1 এবং $2",
+ "multimediaviewer-metadata-error": "চিত্রের বিস্তারিত লোড করা যায়নি (ত্রুটি: $1)",
+ "multimediaviewer-thumbnail-error": "দুঃখিত, ফাইলটি প্রদর্শন করা যাবে না",
+ "multimediaviewer-thumbnail-error-description": "এখানে একটি প্রযুক্তিগত সমস্যা আছে বলে মনে হচ্ছে। যদি এটি চলতেই থাকে তাহলে আপনি $1 করতে বা $3 পারেন। ত্রুটি: $2",
+ "multimediaviewer-thumbnail-error-retry": "পুনঃচেষ্টা",
+ "multimediaviewer-thumbnail-error-report": "সমস্যা প্রতিবেদন করতে",
+ "multimediaviewer-license-cc-by-1.0": "সিসি বাই ১.০",
+ "multimediaviewer-license-cc-sa-1.0": "সিসি এসএ ১.০",
+ "multimediaviewer-license-cc-by-sa-1.0": "সিসি বাই-এসএ ১.০",
+ "multimediaviewer-license-cc-by-2.0": "সিসি বাই ২.০",
+ "multimediaviewer-license-cc-by-sa-2.0": "সিসি বাই-এস ২.০",
+ "multimediaviewer-license-cc-by-2.1": "সিসি বাই ২.১",
+ "multimediaviewer-license-cc-by-sa-2.1": "সিসি বাই-এসএ ২.১",
+ "multimediaviewer-license-cc-by-2.5": "সিসি বাই ২.৫",
+ "multimediaviewer-license-cc-by-sa-2.5": "সিসি বাই-এসএ ২.৫",
+ "multimediaviewer-license-cc-by-3.0": "সিসি বাই ৩.০",
+ "multimediaviewer-license-cc-by-sa-3.0": "সিসি বাই-এসএ ৩.০",
+ "multimediaviewer-license-cc-by-4.0": "সিসি বাই ৪.০",
+ "multimediaviewer-license-cc-by-sa-4.0": "সিসি বাই-এসএ ৪.০",
+ "multimediaviewer-license-cc-pd": "পাবলিক ডোমেইন",
+ "multimediaviewer-license-cc-zero": "সিসি ০",
+ "multimediaviewer-license-pd": "পাবলিক ডোমেইন",
+ "multimediaviewer-license-default": "লাইসেন্স দেখুন",
+ "multimediaviewer-permission-title": "অনুমতির বিবরণ",
+ "multimediaviewer-permission-link": "শর্তাবলী দেখুন",
+ "multimediaviewer-permission-link-hide": "শর্তাবলী আড়াল করুন",
+ "multimediaviewer-permission-viewmore": "আরও দেখুন",
+ "multimediaviewer-restriction-ihl": "এই ছবিতে আন্তর্জাতিক মানবিক আইন কর্তৃক সীমাবদ্ধ চিহ্ন রয়েছে।",
+ "multimediaviewer-restriction-nazi": "এই চিত্রে নাৎসি বা অন্যান্য ফ্যাসিবাদী পরিচয়চিহ্ন রয়েছে যা কিছু দেশে নিষিদ্ধ হতে পারে।",
+ "multimediaviewer-restriction-trademarked": "এই চিত্রে সামগ্রী রয়েছে যা ট্রেডমার্ক সংক্রান্ত আইনের সঙ্গে সামঞ্জস্যপূর্ণ হতে পারে।",
+ "multimediaviewer-about-mmv": "সম্পর্কে",
+ "multimediaviewer-discuss-mmv": "আলোচনা",
+ "multimediaviewer-help-mmv": "সাহায্য",
+ "multimediaviewer-optout-mmv": "মিডিয়া ভিউয়ার নিষ্ক্রিয় করো",
+ "multimediaviewer-optin-mmv": "মিডিয়া ভিউয়ার সক্রিয় করো",
+ "multimediaviewer-optout-pending-mmv": "মিডিয়া ভিউয়ার নিষ্ক্রিয় করো",
+ "multimediaviewer-optin-pending-mmv": "মিডিয়া ভিউয়ার সক্রিয় করা হচ্ছে",
+ "multimediaviewer-optout-help": "মিডিয়া ভিউয়ার চিত্রগুলি দেখানোর জন্য আর ব্যবহার করা হবে না। এটি আবার ব্যবহার করতে, যে কোন চিত্রের নিচে \"{{int:multimediaviewer-view-expanded}}\" বোতামে ক্লিক করুন। এরপর \"{{int:multimediaviewer-optin-mmv}}\"তে ক্লিক করুন।",
+ "multimediaviewer-optin-help": "মিডিয়া ভিউয়ার চিত্রগুলি দেখানোর জন্য ব্যবহার করা হবে।",
+ "multimediaviewer-geoloc-north": "উ",
+ "multimediaviewer-geoloc-east": "পূ",
+ "multimediaviewer-geoloc-south": "দ",
+ "multimediaviewer-geoloc-west": "প",
+ "multimediaviewer-geolocation": "অবস্থান: $1",
+ "multimediaviewer-reuse-link": "এই ফাইলটি শেয়ার বা এম্বেড করুন",
+ "multimediaviewer-reuse-loading-placeholder": "লোড হচ্ছে...",
+ "multimediaviewer-share-tab": "শেয়ার",
+ "multimediaviewer-embed-tab": "এম্বেড",
+ "multimediaviewer-download-link": "এই ফাইলটি ডাউনলোড করুন",
+ "multimediaviewer-download-preview-link-title": "ব্রাউজারে দেখুন",
+ "multimediaviewer-download-original-button-name": "মূল ফাইলটি ডাউনলোড করুন",
+ "multimediaviewer-download-small-button-name": "ছোট আকার ডাউনলোড করুন",
+ "multimediaviewer-download-medium-button-name": "মাঝারি আকার ডাউনলোড করুন",
+ "multimediaviewer-download-large-button-name": "বড় আকার ডাউনলোড করুন",
+ "multimediaviewer-link-to-page": "বিবরণ পাতায় ফাইল লিঙ্ক করুন",
+ "multimediaviewer-link-to-file": "মূল ফাইলে লিঙ্ক করুন",
+ "multimediaviewer-share-explanation": "অনুলিপি করুন এবং অবাধে লিঙ্ক শেয়ার করুন",
+ "multimediaviewer-embed-wt": "উইকিটেক্সট",
+ "multimediaviewer-embed-html": "এইচটিএমএল",
+ "multimediaviewer-embed-explanation": "ফাইল এম্বেড করার জন্য এই কোড ব্যবহার করুন",
+ "multimediaviewer-text-embed-credit-text-bl": "$1 কর্তৃক, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "$1 কর্তৃক, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "$1 কর্তৃক, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "$1 কর্তৃক, $2",
+ "multimediaviewer-html-embed-credit-link-text": "সংযোগ",
+ "multimediaviewer-embed-byline": "$1 কর্তৃক",
+ "multimediaviewer-embed-license": "$1-এর অধীনে লাইসেন্সকৃত।",
+ "multimediaviewer-embed-via": "$1 হয়ে।",
+ "multimediaviewer-default-embed-dimensions": "ডিফল্ট থাম্বনেইল আকার",
+ "multimediaviewer-original-embed-dimensions": "মূল ফাইল $1",
+ "multimediaviewer-large-embed-dimensions": "বড় $1",
+ "multimediaviewer-medium-embed-dimensions": "মাঝারি $1",
+ "multimediaviewer-small-embed-dimensions": "ছোট $1",
+ "multimediaviewer-description-page-button-text": "এই ফাইল সম্পর্কে আরও বিস্তারিত",
+ "multimediaviewer-description-page-popup-text": "$1-এ এই ফাইল সম্পর্কে আরো বিস্তারিত",
+ "multimediaviewer-commons-subtitle": "মুক্ত মিডিয়া ভাণ্ডার",
+ "multimediaviewer-view-expanded": "মিডিয়া ভিউয়ারে খুলুন",
+ "multimediaviewer-view-config": "কনফিগারেশন",
+ "multimediaviewer-close-popup-text": "এই সরঞ্জামটি বন্ধ করুন (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "পূর্ণ স্ক্রিনে দেখান",
+ "multimediaviewer-defullscreen-popup-text": "পূর্ণ স্ক্রিন প্রস্থান করুন",
+ "multimediaviewer-next-image-alt-text": "পরবর্তী চিত্র দেখান",
+ "multimediaviewer-prev-image-alt-text": "পূর্ববর্তী চিত্র দেখান",
+ "multimediaviewer-title-popup-text": "বিবরণ",
+ "multimediaviewer-credit-popup-text": "প্রণেতা এবং উৎসের তথ্য",
+ "multimediaviewer-title-popup-text-more": "সম্পূর্ণ বিবরণ দেখুন",
+ "multimediaviewer-credit-popup-text-more": "পূর্ণ প্রণেতা এবং উৎস দেখুন",
+ "multimediaviewer-download-attribution-cta-header": "আপনার প্রণেতাকে আরোপ করা প্রয়োজন",
+ "multimediaviewer-download-optional-attribution-cta-header": "আপনি প্রণেতাকে আরোপ করতে পারেন",
+ "multimediaviewer-download-attribution-cta": "কিভাবে আমাকে দেখান",
+ "multimediaviewer-reuse-warning-nonfree": "এই ফাইলটিতে একটি উন্মুক্ত লাইসেন্স নেই।",
+ "multimediaviewer-reuse-warning-generic": "এটি ব্যবহার করার আগে [$1 এর বিস্তারিত] পরীক্ষা করুন।",
+ "multimediaviewer-attr-plain": "সাধারণ",
+ "multimediaviewer-options-tooltip": "মিডিয়া ভিউয়ার সক্রিয় অথবা নিষ্ক্রিয় করুন",
+ "multimediaviewer-options-dialog-header": "মিডিয়া ভিউয়ার নিষ্ক্রিয় করবেন?",
+ "multimediaviewer-options-text-header": "সব ফাইলের জন্য এই দেখার বৈশিষ্ট্য এড়িয়ে যান।",
+ "multimediaviewer-options-text-body": "আপনি পরে ফাইলের বিবরণ পাতার মাধ্যমে এটি সক্রিয় করতে পারবেন।",
+ "multimediaviewer-options-learn-more": "আরও জানুন",
+ "multimediaviewer-option-submit-button": "মিডিয়া ভিউয়ার নিষ্ক্রিয় করো",
+ "multimediaviewer-option-cancel-button": "বাতিল",
+ "multimediaviewer-disable-confirmation-header": "আপনি মিডিয়া ভিউয়ার নিষ্ক্রিয় করেছেন",
+ "multimediaviewer-disable-confirmation-text": "পরবর্তী সময় আপনি যখন $1-এর একটি থাম্বনেইলে ক্লিক করবেন, আপনি সরাসরি ফাইলের সব বিবরণ দেখতে পাবেন।",
+ "multimediaviewer-enable-dialog-header": "মিডিয়া ভিউয়ার সক্রিয় করবেন?",
+ "multimediaviewer-enable-text-header": "ডিফল্ট হিসাবে সব ফাইলের জন্য এই মিডিয়া দেখার বৈশিষ্ট্য সক্রিয় করুন।",
+ "multimediaviewer-enable-submit-button": "মিডিয়া ভিউয়ার সক্রিয় করো",
+ "multimediaviewer-enable-confirmation-header": "আপনি সকল ফাইলের জন্য মিডিয়া ভিউয়ার সক্রিয় করেছেন",
+ "multimediaviewer-enable-confirmation-text": "পরবর্তী সময় আপনি যখন $1-এর একটি থাম্বনেইলে ক্লিক করবেন, তখন মিডিয়া ভিউয়ার ব্যবহার করা হবে।",
+ "multimediaviewer-enable-alert": "মিডিয়া ভিউয়ার এখন নিষ্ক্রিয়",
+ "multimediaviewer-disable-info-title": "আপনি মিডিয়া ভিউয়ার নিষ্ক্রিয় করেছেন",
+ "multimediaviewer-disable-info": "আপনি এখনও মিডিয়া ভিউয়ার দিয়ে পৃথক ফাইল দেখতে পারবেন।"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/br.json b/www/wiki/extensions/MultimediaViewer/i18n/br.json
new file mode 100644
index 00000000..72db21b0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/br.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fulup",
+ "Y-M D",
+ "Fohanno"
+ ]
+ },
+ "multimediaviewer-repository-local": "Gouzout hiroc'h diwar-benn ar restr-mañ",
+ "multimediaviewer-datetime-created": "Krouet d'an $1",
+ "multimediaviewer-datetime-uploaded": "Enporzhiet d'an $1",
+ "multimediaviewer-multiple-authors-combine": "$1 ha $2",
+ "multimediaviewer-license-cc-pd": "Domani foran",
+ "multimediaviewer-license-pd": "Domani foran",
+ "multimediaviewer-license-default": "Gwelet an aotre-implijout",
+ "multimediaviewer-permission-title": "Munudoù an aotre-implijout",
+ "multimediaviewer-permission-viewmore": "Gwelet muioc'h",
+ "multimediaviewer-help-mmv": "Skoazell",
+ "multimediaviewer-geolocation": "Lec'hiadur : $1",
+ "multimediaviewer-reuse-link": "Implijout ar restr-mañ",
+ "multimediaviewer-reuse-loading-placeholder": "O kargañ...",
+ "multimediaviewer-share-tab": "Rannañ",
+ "multimediaviewer-embed-tab": "Enframmañ",
+ "multimediaviewer-download-link": "Pellgargañ",
+ "multimediaviewer-download-preview-link-title": "Gwelet er merdeer",
+ "multimediaviewer-download-original-button-name": "Pellgargañ ar restr orin",
+ "multimediaviewer-link-to-file": "Liamm war-zu ar restr orin",
+ "multimediaviewer-embed-wt": "Wikitestenn",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-byline": "Gant $1",
+ "multimediaviewer-embed-license": "Dindan an aotre-implijout $1.",
+ "multimediaviewer-embed-via": "Eus $1.",
+ "multimediaviewer-original-embed-dimensions": "Ment orin $1",
+ "multimediaviewer-small-embed-dimensions": "Bihan $1",
+ "multimediaviewer-description-page-button-text": "Muioc'h a ditouroù diwar-benn ar restr-mañ",
+ "multimediaviewer-description-page-popup-text": "Muioc'h a ditouroù diwar-benn ar restr-mañ war $1",
+ "multimediaviewer-view-expanded": "Diskweladur astennet",
+ "multimediaviewer-fullscreen-popup-text": "Diskouez er skramm leun",
+ "multimediaviewer-defullscreen-popup-text": "Kuitaat ar skramm leun",
+ "multimediaviewer-title-popup-text": "Anv ar restr",
+ "multimediaviewer-title-popup-text-more": "Klikañ da welet anv klok ar restr",
+ "multimediaviewer-download-attribution-cta": "Diskouez din penaos ober",
+ "multimediaviewer-attr-plain": "Plaen"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/bs.json b/www/wiki/extensions/MultimediaViewer/i18n/bs.json
new file mode 100644
index 00000000..08d751f4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/bs.json
@@ -0,0 +1,80 @@
+{
+ "@metadata": {
+ "authors": [
+ "DzWiki",
+ "Palapa",
+ "Srdjan m",
+ "Obsuser"
+ ]
+ },
+ "multimediaviewer-pref": "Preglednik medijskih datoteka",
+ "multimediaviewer-optin-pref": "Uključi <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Medijski preglednik]</span>",
+ "multimediaviewer-file-page": "Idi na odgovarajuću stranicu datoteke",
+ "multimediaviewer-repository-local": "Više detalja",
+ "multimediaviewer-datetime-created": "Napravljeno: $1",
+ "multimediaviewer-datetime-uploaded": "Postavljeno: $1",
+ "multimediaviewer-credit-fallback": "Prikaži informacije o autoru",
+ "multimediaviewer-thumbnail-error-description": "Izgleda da postoji tehnički problem. Možete $1 ili $3 ako se nastavi. Greška: $2",
+ "multimediaviewer-thumbnail-error-retry": "probati opet",
+ "multimediaviewer-thumbnail-error-report": "prijaviti problem",
+ "multimediaviewer-license-cc-pd": "Javno vlasništvo",
+ "multimediaviewer-license-pd": "Javno vlasništvo",
+ "multimediaviewer-license-default": "Vidi licencu",
+ "multimediaviewer-permission-title": "Detalji dozvole",
+ "multimediaviewer-permission-link": "vidi uslove",
+ "multimediaviewer-permission-viewmore": "Prikaži još",
+ "multimediaviewer-about-mmv": "O pregledniku",
+ "multimediaviewer-help-mmv": "Pomoć",
+ "multimediaviewer-optout-mmv": "Onemogući preglednik multimedijskih datoteka",
+ "multimediaviewer-optin-mmv": "Omogući preglednik multimedijskih datoteka",
+ "multimediaviewer-geolocation": "Lokacija: $1",
+ "multimediaviewer-reuse-link": "Dijeli ili ugnijezdi ovu datoteku",
+ "multimediaviewer-reuse-loading-placeholder": "Učitavam…",
+ "multimediaviewer-share-tab": "Dijeli",
+ "multimediaviewer-embed-tab": "Ugradi",
+ "multimediaviewer-download-link": "Preuzmi ovu datoteku",
+ "multimediaviewer-download-preview-link-title": "Vidi u web pregledniku",
+ "multimediaviewer-download-original-button-name": "Preuzmi originalnu datoteku",
+ "multimediaviewer-download-small-button-name": "Preuzmi u maloj veličini",
+ "multimediaviewer-download-medium-button-name": "Preuzmi u srednjoj veličini",
+ "multimediaviewer-download-large-button-name": "Preuzmi veliku sliku",
+ "multimediaviewer-link-to-page": "Veza na stranicu s informacijama o datoteki",
+ "multimediaviewer-link-to-file": "Veza na izvornu datoteku",
+ "multimediaviewer-share-explanation": "Kopirajte i slobodno dijelite ovu vezu",
+ "multimediaviewer-embed-wt": "Wikitekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Koristite ovaj kôd da biste ugradili datoteku",
+ "multimediaviewer-original-embed-dimensions": "Izvorna datoteka $1",
+ "multimediaviewer-large-embed-dimensions": "Velika $1",
+ "multimediaviewer-medium-embed-dimensions": "Srednja $1",
+ "multimediaviewer-small-embed-dimensions": "Mala $1",
+ "multimediaviewer-commons-subtitle": "Spremište slobodnih medijskih datoteka",
+ "multimediaviewer-view-expanded": "Otvori u medijskom pregledniku",
+ "multimediaviewer-view-config": "Konfiguracija",
+ "multimediaviewer-close-popup-text": "Zatvori alat (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Prikaži preko cijelog ekrana",
+ "multimediaviewer-defullscreen-popup-text": "Izađi iz prikaza preko cijelog ekrana",
+ "multimediaviewer-title-popup-text": "Opis",
+ "multimediaviewer-credit-popup-text": "Autor i informacije o izvoru",
+ "multimediaviewer-title-popup-text-more": "Prikaži cijeli opis",
+ "multimediaviewer-download-attribution-cta-header": "Trebate navesti autora",
+ "multimediaviewer-download-attribution-cta": "Pokaži mi kako",
+ "multimediaviewer-attr-plain": "Običan tekst",
+ "multimediaviewer-options-tooltip": "Omogući ili onemogući preglednik multimedijskih datoteka",
+ "multimediaviewer-options-dialog-header": "Isključite preglednik medija?",
+ "multimediaviewer-options-text-header": "Isključi ovu mogućnost za sve datoteke.",
+ "multimediaviewer-options-text-body": "Naknadno je možete uključiti na stranici s pojedinostima datoteke.",
+ "multimediaviewer-options-learn-more": "Saznaj više",
+ "multimediaviewer-option-submit-button": "Isključite preglednik",
+ "multimediaviewer-option-cancel-button": "Otkaži",
+ "multimediaviewer-disable-confirmation-header": "Isključili ste preglednik medija",
+ "multimediaviewer-disable-confirmation-text": "Sljedeći put kad kliknete na umanjenu sliku na projektu $1, odmah ćete vidjeti pojedinosti datoteke.",
+ "multimediaviewer-enable-dialog-header": "Omogući preglednik multimedijskih datoteka?",
+ "multimediaviewer-enable-text-header": "Uključi ovu mogućnost ubuduće kao podrazumijevanu za sve datoteke.",
+ "multimediaviewer-enable-submit-button": "Uključi preglednik medija",
+ "multimediaviewer-enable-confirmation-header": "Uključili ste preglednik medija za sve datoteke",
+ "multimediaviewer-enable-confirmation-text": "Sljedeći put kad kliknete na smanjenu sliku na projektu $1, koristit će se preglednik.",
+ "multimediaviewer-enable-alert": "Preglednik medija je trenutno isključen",
+ "multimediaviewer-disable-info-title": "Onemogućili ste preglednik multimedijskih datoteka",
+ "multimediaviewer-disable-info": "Još uvijek možete koristiti preglednik multimedijskih datoteka za pojedinačne datoteke."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ca.json b/www/wiki/extensions/MultimediaViewer/i18n/ca.json
new file mode 100644
index 00000000..e825e608
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ca.json
@@ -0,0 +1,83 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fitoschido",
+ "QuimGil",
+ "Vriullop",
+ "Ssola",
+ "Macofe",
+ "Pginer",
+ "F3RaN"
+ ]
+ },
+ "multimediaviewer-desc": "Amplia les miniatures en una interfície a pantalla completa.",
+ "multimediaviewer-pref": "Visualitzador multimèdia",
+ "multimediaviewer-pref-desc": "Milloreu la vostra experiència de visualització multimèdia amb aquesta nova eina. Mostra imatges a mida més gran en les pàgines que tenen miniatures. Les imatges es mostren en una pantalla completa més agradable, i també es poden veure a mida completa.",
+ "multimediaviewer-optin-pref": "Activa el <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About visor multimèdia]</span>",
+ "multimediaviewer-file-page": "Vés a la pàgina corresponent del fitxer",
+ "multimediaviewer-repository-local": "Més informació",
+ "multimediaviewer-datetime-created": "Creat: $1",
+ "multimediaviewer-datetime-uploaded": "Carregat: $1",
+ "multimediaviewer-metadata-error": "Error: no hem pogut carregar les dades de la imatge. $1",
+ "multimediaviewer-thumbnail-error": "Error: No hem pogut carregar les dades de les miniatures. $1",
+ "multimediaviewer-license-cc-pd": "Domini públic",
+ "multimediaviewer-license-pd": "Domini públic",
+ "multimediaviewer-license-default": "Mostra la llicència",
+ "multimediaviewer-permission-title": "Detalls de la llicència",
+ "multimediaviewer-permission-link": "Vegeu les condicions",
+ "multimediaviewer-permission-viewmore": "Mostra'n més",
+ "multimediaviewer-restriction-2257": "Aquesta imatge conté contingut sexual explícit que pot estar subjecte a la Llei de Protecció d'Infants i l'Obscenitat d'aplicació als Estats Units.",
+ "multimediaviewer-restriction-communist": "Aquesta imatge conté insignes comunistes susceptibles de ser prohibides en determinats països.",
+ "multimediaviewer-restriction-costume": "Aquesta imatge mostra vestuari i és susceptible d'estar subjecte a restriccions legals.",
+ "multimediaviewer-restriction-currency": "Aquesta imatge representa el detall d'una moneda i pot estar subjecte a restriccions legals.",
+ "multimediaviewer-restriction-design": "La configuració temàtica d'aquesta imatge pot contenir drets d'autor i estar subjecte a restriccions legals.",
+ "multimediaviewer-restriction-ihl": "Aquesta imatge conté símbols restringits pel Dret Humanitari Internacional.",
+ "multimediaviewer-restriction-insignia": "Aquesta imatge conté insígnies oficials susceptibles d'estar subjectes a restriccions legals.",
+ "multimediaviewer-restriction-ita-mibac": "Aquesta imatge reprodueix una propietat de patrimoni cultural italià i està restringida per la justícia italiana.",
+ "multimediaviewer-restriction-nazi": "Aquesta imatge conté símbols nazi o feixistes que poden ser prohibits en determinats països.",
+ "multimediaviewer-restriction-personality": "Aquesta imatge conté persones que poden tenir drets que legalment restringeixin determinats re-usos de la imatge sense el seu consentiment.",
+ "multimediaviewer-restriction-default": "Aquesta imatge encara és susceptible de ser restringida degut a altres disposicions legals fora de la llei de propietat intel·lectual. Vegeu la pàgina de descripció del fitxer per a més detalls.",
+ "multimediaviewer-restriction-default-and-others": "Aquesta imatge encara és susceptible de ser restringida degut a altres disposicions legals fora de la llei de propietat intel·lectual. Vegeu la pàgina de descripció del fitxer per a més detalls.",
+ "multimediaviewer-about-mmv": "Quant al visor multimèdia",
+ "multimediaviewer-discuss-mmv": "Comenta aquesta funcionalitat",
+ "multimediaviewer-help-mmv": "Ajuda",
+ "multimediaviewer-optout-mmv": "Desactiva el visor multimèdia",
+ "multimediaviewer-optin-mmv": "Activa el visor multimèdia",
+ "multimediaviewer-optout-pending-mmv": "Desactivant el visor multimèdia",
+ "multimediaviewer-optin-pending-mmv": "Activant el visor multimèdia",
+ "multimediaviewer-optout-help": "Les imatges ja no es mostraran amb el visor multimèdia. Per utilitzar-lo de nou, cliqueu el botó \"Amplia\" al costat d'una imatge. Desprès cliqueu \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Les imatges es mostraran amb el visor multimèdia.",
+ "multimediaviewer-geolocation": "Emplaçament: $1",
+ "multimediaviewer-reuse-link": "Utilitza aquest fitxer",
+ "multimediaviewer-reuse-loading-placeholder": "S'està carregant...",
+ "multimediaviewer-share-tab": "Comparteix",
+ "multimediaviewer-embed-tab": "Insereix",
+ "multimediaviewer-download-link": "Descarrega",
+ "multimediaviewer-download-preview-link-title": "Visualitza en el navegador",
+ "multimediaviewer-download-original-button-name": "Descarrega el fitxer original",
+ "multimediaviewer-download-small-button-name": "Descarrega en mida petita",
+ "multimediaviewer-download-medium-button-name": "Descarrega en mida mitjana",
+ "multimediaviewer-download-large-button-name": "Descarrega en mida gran",
+ "multimediaviewer-link-to-page": "Enllaç a la pàgina de descripció del fitxer",
+ "multimediaviewer-link-to-file": "Enllaç al fitxer original",
+ "multimediaviewer-share-explanation": "Copiar i compartir lliurement l'enllaç",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Utilitzar aquest codi per incrustar l'arxiu",
+ "multimediaviewer-embed-byline": "Per $1",
+ "multimediaviewer-embed-license": "Sota la llicència $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Mida de la miniatura per defecte",
+ "multimediaviewer-original-embed-dimensions": "Fitxer original $1",
+ "multimediaviewer-large-embed-dimensions": "Gran $1",
+ "multimediaviewer-medium-embed-dimensions": "Mitjana $1",
+ "multimediaviewer-small-embed-dimensions": "Petita $1",
+ "multimediaviewer-description-page-button-text": "Més detalls",
+ "multimediaviewer-description-page-popup-text": "Més informació sobre aquest fitxer a $1",
+ "multimediaviewer-commons-subtitle": "El repositori multimèdia lliure",
+ "multimediaviewer-view-expanded": "Amplia la visualització",
+ "multimediaviewer-close-popup-text": "Tanca aquesta eina (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Mostra a pantalla completa",
+ "multimediaviewer-defullscreen-popup-text": "Surt del mode de pantalla completa",
+ "multimediaviewer-title-popup-text": "Descripció"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ce.json b/www/wiki/extensions/MultimediaViewer/i18n/ce.json
new file mode 100644
index 00000000..b7cd70df
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ce.json
@@ -0,0 +1,95 @@
+{
+ "@metadata": {
+ "authors": [
+ "Умар",
+ "Исмаил Садуев"
+ ]
+ },
+ "multimediaviewer-desc": "Схьадосту суьрташ юьззина экран.",
+ "multimediaviewer-pref": "Медиа-хьожург",
+ "multimediaviewer-pref-desc": "Мультимедиа-файлашка хьажар хаза кечдина гойту.",
+ "multimediaviewer-optin-pref": "Латае <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Медиа-хьожург]</span>",
+ "multimediaviewer-file-page": "Йолуш йолу файлан агӀонга дехьавала",
+ "multimediaviewer-repository-local": "Ма-дарра",
+ "multimediaviewer-datetime-created": "Кхоьллина: $1",
+ "multimediaviewer-datetime-uploaded": "Чуяьккхина: $1",
+ "multimediaviewer-credit-fallback": "Авторах лаьцна хьажа",
+ "multimediaviewer-multiple-authors-combine": "$1 $2 тӀе",
+ "multimediaviewer-metadata-error": "ГӀалат: Суьртан хаамаш гайта цабелира. $1",
+ "multimediaviewer-thumbnail-error": "ГӀалат: Эскизан хаамаш гайта цабелира. $1",
+ "multimediaviewer-thumbnail-error-description": "Техникин гӀалат даьллачух тера ду. Из гӀалат юха а хилахь хьан йиш ю $1 я $3. ГӀалат: $2",
+ "multimediaviewer-thumbnail-error-retry": "юхагӀорта",
+ "multimediaviewer-thumbnail-error-report": "гӀалатех хаам бар",
+ "multimediaviewer-license-cc-pd": "Юкъараллин рицӀкъ",
+ "multimediaviewer-license-pd": "Юкъараллин рицӀкъ",
+ "multimediaviewer-license-default": "Лицензига хьажар",
+ "multimediaviewer-permission-title": "Лецензех лаьцна",
+ "multimediaviewer-permission-link": "хьоле хьажар",
+ "multimediaviewer-permission-viewmore": "Хьажа мадарра",
+ "multimediaviewer-about-mmv": "Медиа-хьожучух лаьцна",
+ "multimediaviewer-discuss-mmv": "Йийца хӀара функци",
+ "multimediaviewer-help-mmv": "ГӀо",
+ "multimediaviewer-optout-mmv": "ДӀаяйа Медиа-хьожург",
+ "multimediaviewer-optin-mmv": "Латае медиа-хьожург",
+ "multimediaviewer-optout-pending-mmv": "ДӀаяйа медиа-хьожург",
+ "multimediaviewer-optin-pending-mmv": "Медиа-хьожург латор",
+ "multimediaviewer-optout-help": "Медиа-хьожург кхий лелош яц. Юху и лелаян муьлху а суьртан уллера кнопка тӀетаӀае \"{{INT: multimediaviewer-Optin-MMV}}\".",
+ "multimediaviewer-optin-help": "ХӀинца медиа-хьожург лелор ю суьрташка хьожуш.",
+ "multimediaviewer-geolocation": "Географин йолу меттиг: $1",
+ "multimediaviewer-reuse-link": "Лелае хӀара файл",
+ "multimediaviewer-reuse-loading-placeholder": "Чуйолуш...",
+ "multimediaviewer-share-tab": "Екха",
+ "multimediaviewer-embed-tab": "АгӀонг йилла",
+ "multimediaviewer-download-link": "Чуяккха хӀара файл",
+ "multimediaviewer-download-preview-link-title": "Браузер чохь хьажар",
+ "multimediaviewer-download-original-button-name": "ДӀайолалун барамехь схьаэца",
+ "multimediaviewer-download-small-button-name": "Схьаэца жима барамехь",
+ "multimediaviewer-download-medium-button-name": "Схьаэца юкъара барамехь",
+ "multimediaviewer-download-large-button-name": "Схьаэца йоккха барамехь",
+ "multimediaviewer-link-to-page": "Файлах лаьцна дерг долу агӀона тӀе хьажорг",
+ "multimediaviewer-link-to-file": "ДӀайолалун файлан тӀе хьажорг",
+ "multimediaviewer-share-explanation": "Копи яккхин маьрша лелае хьажорг",
+ "multimediaviewer-embed-wt": "Викийоза",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Лелае хӀара код файл агӀонг юьлуш",
+ "multimediaviewer-embed-byline": "Декъашхой $1",
+ "multimediaviewer-embed-license": "Лицензица $1.",
+ "multimediaviewer-embed-via": "$1 чухула.",
+ "multimediaviewer-default-embed-dimensions": "Эскизан Ӏадйитаран кепаца болу барам",
+ "multimediaviewer-original-embed-dimensions": "ДӀайолалун файл $1",
+ "multimediaviewer-large-embed-dimensions": "Йоккханиг $1",
+ "multimediaviewer-medium-embed-dimensions": "Юккъерниг $1",
+ "multimediaviewer-small-embed-dimensions": "Жимниг $1",
+ "multimediaviewer-description-page-button-text": "Мадарра",
+ "multimediaviewer-description-page-popup-text": "Мадарра ду $1 чохь",
+ "multimediaviewer-commons-subtitle": "Медиа-файлаш латайо меттиг",
+ "multimediaviewer-view-expanded": "Схьадаста хьажар",
+ "multimediaviewer-view-config": "Нисяр",
+ "multimediaviewer-close-popup-text": "ДӀачӀагӀа хӀара гӀирс (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Йокха гайта",
+ "multimediaviewer-defullscreen-popup-text": "Жима гайта",
+ "multimediaviewer-title-popup-text": "Цуьнах лаьцна",
+ "multimediaviewer-credit-popup-text": "Авторах а хьостах а лаьцна хаам",
+ "multimediaviewer-title-popup-text-more": "Хьажа цунах лаьцна мадарра",
+ "multimediaviewer-credit-popup-text-more": "Авторах а, хьостах а лаьцна мадарра хьажа",
+ "multimediaviewer-download-attribution-cta-header": "ДӀаязъе авторан цӀе",
+ "multimediaviewer-download-attribution-cta": "Гайта соьга, санна",
+ "multimediaviewer-attr-plain": "Атта",
+ "multimediaviewer-options-tooltip": "Латор я дӀаяйар Медиа-хьожург",
+ "multimediaviewer-options-dialog-header": "ДӀаяйа Медиа-хьожург?",
+ "multimediaviewer-options-text-header": "Латае хӀара хьажаран функци массо файлашна.",
+ "multimediaviewer-options-text-body": "Хьан йиш ю и тӀаьхьо латаян файлах лаьцна хаам болу агӀонгахь.",
+ "multimediaviewer-options-learn-more": "Цул совнаха хаа",
+ "multimediaviewer-option-submit-button": "ДӀаяйа Медиа-хьожург",
+ "multimediaviewer-option-cancel-button": "Цаоьшу",
+ "multimediaviewer-disable-confirmation-header": "Ахьа дӀаяйина Медиа-хьожург",
+ "multimediaviewer-disable-confirmation-text": "Кхечу хенахь $1 сайтехь файлан тӀе таӀийча хьана файлан хаам хьажа йиш хира ю.",
+ "multimediaviewer-enable-dialog-header": "Латае медиа-хьожург?",
+ "multimediaviewer-enable-text-header": "Латае медиа-хьожург массо файлашна.",
+ "multimediaviewer-enable-submit-button": "Латае медиа-хьожург",
+ "multimediaviewer-enable-confirmation-header": "Ахьа латийна медиа-хьожург массо файлашна.",
+ "multimediaviewer-enable-confirmation-text": "Кхечу хенахь $1 сайтехь файлан тӀе таӀийча хьана медиа-хьожург лелор ю.",
+ "multimediaviewer-enable-alert": "Медиа-хьожург хӀинца яйина ю",
+ "multimediaviewer-disable-info-title": "Ахьа дӀаяйина Медиа-хьожург",
+ "multimediaviewer-disable-info": "Хьа хӀинца а йиш ю цхьайолу файлашка медиа-хьожургцан хьажа."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ckb.json b/www/wiki/extensions/MultimediaViewer/i18n/ckb.json
new file mode 100644
index 00000000..6809e11f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ckb.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Asoxor",
+ "Pirehelokan",
+ "Sarchia",
+ "Lost Whispers",
+ "Épine"
+ ]
+ },
+ "multimediaviewer-pref": "نیشاندەری میدیا",
+ "multimediaviewer-repository-local": "وردەکاریی زیاتر",
+ "multimediaviewer-datetime-created": "دروست کراوە لە: $1",
+ "multimediaviewer-datetime-uploaded": "بارکراوە لە: $1",
+ "multimediaviewer-credit-fallback": "زانیاری سەبارەت بە بەرھەمھێنەر",
+ "multimediaviewer-multiple-authors-combine": "$1 و $2",
+ "multimediaviewer-thumbnail-error-retry": "ھەوڵدانەوە",
+ "multimediaviewer-license-cc-pd": "پاوانی گشتی",
+ "multimediaviewer-license-pd": "پاوانی گشتی",
+ "multimediaviewer-license-default": "مۆڵەتنامەکەی ببینە",
+ "multimediaviewer-permission-viewmore": "زیاتر ببینە",
+ "multimediaviewer-restriction-communist": "ئەم وێنەیە ئاڵای کۆمۆنیستی تێدایە کە ڕەنگە لە بڕێک وڵاتەکاندا قەدەغەکراو بێت.",
+ "multimediaviewer-restriction-costume": "ئەم وێنەیە کاستومینگ پیشان دەدات و ڕەنگە کێشەی یاسایی ھەبێت.",
+ "multimediaviewer-restriction-currency": "ئەم پەڕەیە یەکینەی پارەیەک پیشان دەدات کە ڕەنگە قەدەغەکراو بێت.",
+ "multimediaviewer-restriction-design": " ڕەنگە داڕشتنی ناوەرۆکی ئەم وێنەیە لە ژێر مافی کۆپیدا بێت و کێشەی یاسایی ھەبێت.",
+ "multimediaviewer-restriction-fan-art": "ئەم وێنەیە کاری ھۆگرێکی ھونەرە و ڕەنگە بەکارھێنانەوەی کێشەی یاسایی ھەبێت.",
+ "multimediaviewer-restriction-ihl": "ئەم وێنەیە بڕێک نیشانەی تێدایە کە لە لایەن یاسای نێودەوڵەتیی مرۆڤایەتییەوە قەدەغە کراوە.",
+ "multimediaviewer-restriction-nazi": "ئەم وێنەیە ئاڵای نازی یان ناوەرۆکی فاشیستیی تری تێدایە کە ڕەنگە لە بڕێک وڵاتەکاندا قەدەغەکراو بێت.",
+ "multimediaviewer-restriction-default": "ڕەنگە ئەم وێنەیە کێشەی یاسایی ببێت سەبارەت بە مافی کۆپی کردنەوە. بۆ زانیاریی زیاتر پەڕەی وەسفی فایلەکە ببینە.",
+ "multimediaviewer-discuss-mmv": "وتووێژ",
+ "multimediaviewer-help-mmv": "یارمەتی",
+ "multimediaviewer-optin-mmv": "چالاککردنی نیشاندەری میدیا",
+ "multimediaviewer-geolocation": "شوێن: $1",
+ "multimediaviewer-reuse-loading-placeholder": "بارکردن...",
+ "multimediaviewer-download-link": "ئەم پەڕگەیە دابگرە",
+ "multimediaviewer-embed-via": "لە ڕێگەی $1ـەوە.",
+ "multimediaviewer-large-embed-dimensions": "گەورە $1",
+ "multimediaviewer-medium-embed-dimensions": "نێونجی $1",
+ "multimediaviewer-small-embed-dimensions": "بچووک $1",
+ "multimediaviewer-view-expanded": "کردنەوە لە نیشاندەری میدیادا",
+ "multimediaviewer-close-popup-text": "ئەم ئامرازە دا بخە (Esc)",
+ "multimediaviewer-title-popup-text": "وەسف",
+ "multimediaviewer-credit-popup-text": "زانیاریی بەرھەمھێنەر و سەرچاوە",
+ "multimediaviewer-title-popup-text-more": "وەسفی تەواو ببینە",
+ "multimediaviewer-credit-popup-text-more": "بەرھەمھێنەر و سەرچاوە بە تەواوی ببینە",
+ "multimediaviewer-download-attribution-cta": "نیشانم بدە چۆن",
+ "multimediaviewer-attr-plain": "ئاسایی",
+ "multimediaviewer-options-learn-more": "زۆرتر بزانە",
+ "multimediaviewer-enable-dialog-header": "چالاککردنی نیشاندەری میدیا؟",
+ "multimediaviewer-enable-submit-button": "چالاککردنی نیشاندەری میدیا"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/cs.json b/www/wiki/extensions/MultimediaViewer/i18n/cs.json
new file mode 100644
index 00000000..6220ad2a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/cs.json
@@ -0,0 +1,139 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mormegil",
+ "Paxt",
+ "Rosnicka.kacka",
+ "Utar",
+ "Dominikmatus",
+ "Littledogboy",
+ "Macofe"
+ ]
+ },
+ "multimediaviewer-desc": "Zvětší náhledy obrázků do celoobrazovkového rozhraní.",
+ "multimediaviewer-pref": "Prohlížeč médií",
+ "multimediaviewer-pref-desc": "Pomocí tohoto nástroje si můžete zpříjemnit prohlížení multimédií. Na stránkách, na kterých se používají náhledy obrázků, umožňuje prohlížení těchto obrázků ve větší velikosti. Obrázky se zobrazí v hezčím celoobrazovkovém rozhraní a lze si je prohlédnout také v plné velikosti.",
+ "multimediaviewer-optin-pref": "Aktivovat <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Prohlížeč médií]</span>",
+ "multimediaviewer-file-page": "Přejít na stránku s popisem souboru",
+ "multimediaviewer-repository-local": "Více informací",
+ "multimediaviewer-datetime-created": "Vytvořeno: $1",
+ "multimediaviewer-datetime-uploaded": "Načteno: $1",
+ "multimediaviewer-credit": "$1 – $2",
+ "multimediaviewer-credit-fallback": "Zobrazit informace o autorovi",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|jeden další autor|$1 další autoři|$1 dalších autorů}}",
+ "multimediaviewer-multiple-authors-combine": "$1 a $2",
+ "multimediaviewer-metadata-error": "Nelze načíst podrobnosti k obrázku (chyba: $1)",
+ "multimediaviewer-thumbnail-error": "Je nám líto, soubor nelze zobrazit",
+ "multimediaviewer-thumbnail-error-description": "Vypadá to na technické potíže. Můžete to $1 nebo $3, pokud se to nezlepší. Chyba: $2",
+ "multimediaviewer-thumbnail-error-retry": "zkusit znovu",
+ "multimediaviewer-thumbnail-error-report": "problém nahlásit",
+ "multimediaviewer-license-cc-pd": "Volné dílo",
+ "multimediaviewer-license-pd": "Volné dílo",
+ "multimediaviewer-license-default": "Zobrazit licenci",
+ "multimediaviewer-permission-title": "Podrobnosti o svolení",
+ "multimediaviewer-permission-link": "zobrazit podmínky",
+ "multimediaviewer-permission-link-hide": "skrýt podmínky",
+ "multimediaviewer-permission-viewmore": "Zobrazit více",
+ "multimediaviewer-restriction-2257": "Tento obrázek zahrnuje sexuálně explicitní obsah, který může být ve Spojených státech předmětem zákona Child Protection and Obscenity Enforcement Act",
+ "multimediaviewer-restriction-aus-reserve": "Tento obrázek byl vyfotografován v australské přírodní rezervaci a je zakázáno užívat ho ke komerčním účelům bez povolení.",
+ "multimediaviewer-restriction-communist": "Tento obrázek obsahuje komunistické symboly, které mohou být v některých zemích zakázány.",
+ "multimediaviewer-restriction-costume": "Tento soubor vyobrazuje kostým a může být předmětem zákonných omezení.",
+ "multimediaviewer-restriction-currency": "Tento soubor vyobrazuje platidlo a může být předmětem zákonných omezení.",
+ "multimediaviewer-restriction-design": "Design předmětu tohoto obrázku může být chráněn autorským právem či podléhat jiným právním omezením.",
+ "multimediaviewer-restriction-fan-art": "Tento obrázek je dílo typu „fan art“ a jeho další užití může být předmětem zákonných omezení.",
+ "multimediaviewer-restriction-ihl": "Tento obrázek obsahuje symboly omezené mezinárodním humanitárním právem.",
+ "multimediaviewer-restriction-insignia": "Tento obrázek obsahuje oficiální znak, který může být předmětem zákonných omezení.",
+ "multimediaviewer-restriction-ita-mibac": "Tento obrázek reprodukuje majetek patřící mezi italské kulturní památky a je omezen italskými zákony.",
+ "multimediaviewer-restriction-nazi": "Tento obrázek obsahuje nacistické nebo jiné fašistické symboly, které mohou být v některých zemích zakázány.",
+ "multimediaviewer-restriction-personality": "Tento obrázek obsahuje osoby, které mohou mít práva omezující některá užití tohoto obrázku bez svolení.",
+ "multimediaviewer-restriction-trademarked": "Obsah tohoto obrázku může být předmětem známkoprávní ochrany.",
+ "multimediaviewer-restriction-default": "Tento obrázek může být omezen právními předpisy mimo autorské právo. Podrobnosti najdete na stránce s popisem souboru.",
+ "multimediaviewer-restriction-default-and-others": "Tento obrázek může být dále omezen jinými právními předpisy mimo autorské právo. Podrobnosti najdete na stránce s popisem souboru.",
+ "multimediaviewer-about-mmv": "O prohlížeči",
+ "multimediaviewer-discuss-mmv": "Diskuse",
+ "multimediaviewer-help-mmv": "Nápověda",
+ "multimediaviewer-optout-mmv": "Vypnout Prohlížeč médií",
+ "multimediaviewer-optin-mmv": "Zapnout Prohlížeč médií",
+ "multimediaviewer-optout-pending-mmv": "Prohlížeč médií se vypíná",
+ "multimediaviewer-optin-pending-mmv": "Prohlížeč médií se zapíná",
+ "multimediaviewer-optout-help": "K zobrazování obrázků se již nebude používat Prohlížeč médií. Pokud ho budete chtít znovu použít, klikněte na tlačítko „{{int:multimediaviewer-view-expanded}}“ u libovolného obrázku. Poté klikněte na „{{int:multimediaviewer-optin-mmv}}“.",
+ "multimediaviewer-optin-help": "K zobrazování obrázků se bude používat Prohlížeč médií.",
+ "multimediaviewer-geoloc-north": "s.&nbsp;š.",
+ "multimediaviewer-geoloc-east": "v.&nbsp;d.",
+ "multimediaviewer-geoloc-south": "j.&nbsp;š.",
+ "multimediaviewer-geoloc-west": "z.&nbsp;d.",
+ "multimediaviewer-geolocation": "Místo: $1",
+ "multimediaviewer-reuse-link": "Sdílet nebo vložit tento soubor",
+ "multimediaviewer-reuse-loading-placeholder": "Načítám…",
+ "multimediaviewer-reuse-copy-share": "Vybrat a zkopírovat (pokud je podporováno) odkaz pro sdílení tohoto souboru",
+ "multimediaviewer-reuse-copy-embed": "Vybrat a zkopírovat (pokud je podporováno) odkaz pro vložení tohoto souboru",
+ "multimediaviewer-share-tab": "Sdílet",
+ "multimediaviewer-embed-tab": "Vložit",
+ "multimediaviewer-download-link": "Stáhnout tento soubor",
+ "multimediaviewer-download-preview-link-title": "Zobrazit v prohlížeči",
+ "multimediaviewer-download-original-button-name": "Stáhnout původní soubor",
+ "multimediaviewer-download-small-button-name": "Stáhnout v malé velikosti",
+ "multimediaviewer-download-medium-button-name": "Stáhnout ve střední velikosti",
+ "multimediaviewer-download-large-button-name": "Stáhnout ve velké velikosti",
+ "multimediaviewer-link-to-page": "Odkaz na stránku s popisem souboru",
+ "multimediaviewer-link-to-file": "Odkaz na původní soubor",
+ "multimediaviewer-share-explanation": "Kopírujte a volně sdílejte odkaz",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "K vložení tohoto souboru použijte tento kód",
+ "multimediaviewer-text-embed-credit-text-bl": "Autor: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Autor: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Autor: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Autor: $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Odkaz",
+ "multimediaviewer-embed-byline": "Od $1",
+ "multimediaviewer-embed-license": "Licencováno pod $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Výchozí velikost náhledu",
+ "multimediaviewer-original-embed-dimensions": "Původní soubor $1",
+ "multimediaviewer-large-embed-dimensions": "Velký $1",
+ "multimediaviewer-medium-embed-dimensions": "Střední $1",
+ "multimediaviewer-small-embed-dimensions": "Malý $1",
+ "multimediaviewer-embed-dimensions-separated": "– $1",
+ "multimediaviewer-description-page-button-text": "Více informací o tomto souboru",
+ "multimediaviewer-description-page-popup-text": "Více informací o tomto souboru na {{grammar:6sg|$1}}",
+ "multimediaviewer-commons-subtitle": "Úložiště volných médií",
+ "multimediaviewer-view-expanded": "Otevřít v prohlížeči médií",
+ "multimediaviewer-view-config": "Konfigurace",
+ "multimediaviewer-close-popup-text": "Zavřít tento nástroj (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Zobrazit přes celou obrazovku",
+ "multimediaviewer-defullscreen-popup-text": "Ukončit celou obrazovku",
+ "multimediaviewer-next-image-alt-text": "Zobrazit následující obrázek",
+ "multimediaviewer-prev-image-alt-text": "Zobrazit předchozí obrázek",
+ "multimediaviewer-title-popup-text": "Popis",
+ "multimediaviewer-credit-popup-text": "Informace o autorovi a zdroji",
+ "multimediaviewer-title-popup-text-more": "Zobrazit úplný popis",
+ "multimediaviewer-credit-popup-text-more": "Zobrazit úplné informace o autorovi a zdroji",
+ "multimediaviewer-download-attribution-cta-header": "Musíte uvést autora",
+ "multimediaviewer-download-optional-attribution-cta-header": "Můžete uvést autora",
+ "multimediaviewer-download-attribution-cta": "Ukažte mi, jak",
+ "multimediaviewer-download-attribution-copy": "Vybrat a zkopírovat (pokud je podporováno) text uvádějící autorství tohoto souboru",
+ "multimediaviewer-reuse-warning-deletion": "Tento soubor byl navržen na smazání.",
+ "multimediaviewer-reuse-warning-nonfree": "Tento soubor nemá svobodnou licenci.",
+ "multimediaviewer-reuse-warning-noattribution": "Tento soubor nemá informace o autorovi.",
+ "multimediaviewer-reuse-warning-generic": "Před jeho použitím zkontrolujte [$1 podrobnosti].",
+ "multimediaviewer-attr-plain": "Prostý text",
+ "multimediaviewer-options-tooltip": "Zapnout nebo vypnout Prohlížeč médií",
+ "multimediaviewer-options-dialog-header": "Vypnout Prohlížeč médií?",
+ "multimediaviewer-options-text-header": "Vypnout tento prohlížeč u všech souborů.",
+ "multimediaviewer-options-text-body": "Později ho můžete zapnout na stránce s popisem souboru.",
+ "multimediaviewer-options-learn-more": "Více informací",
+ "multimediaviewer-option-submit-button": "Vypnout Prohlížeč médií",
+ "multimediaviewer-option-cancel-button": "Storno",
+ "multimediaviewer-disable-confirmation-header": "Vypnuli jste Prohlížeč médií",
+ "multimediaviewer-disable-confirmation-text": "Když příště na {{grammar:6sg|$1}} kliknete na náhled, zobrazí se rovnou všechny podrobnosti o souboru.",
+ "multimediaviewer-enable-dialog-header": "Zapnout Prohlížeč médií?",
+ "multimediaviewer-enable-text-header": "Zapnout tento prohlížeč pro implicitní zobrazení všech souborů.",
+ "multimediaviewer-enable-submit-button": "Zapnout Prohlížeč médií",
+ "multimediaviewer-enable-confirmation-header": "Zapnuli jste Prohlížeč médií pro všechny soubory",
+ "multimediaviewer-enable-confirmation-text": "Když příště na {{grammar:6sg|$1}} kliknete na náhled, použije se Prohlížeč médií.",
+ "multimediaviewer-enable-alert": "Prohlížeč médií je teď vypnut",
+ "multimediaviewer-disable-info-title": "Vypnuli jste Prohlížeč médií",
+ "multimediaviewer-disable-info": "I nadále si můžete Prohlížečem médií prohlížet jednotlivé soubory.",
+ "multimediaviewer-errorreport-privacywarning": "Podrobnosti o chybě jsou připojeny k hlášení, které bude veřejně dostupné. Pokud se vám to nelíbí, můžete níže hlášení upravit a odstranit všechny údaje, které nechcete sdílet."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/cu.json b/www/wiki/extensions/MultimediaViewer/i18n/cu.json
new file mode 100644
index 00000000..933cb0a6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/cu.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "ОйЛ"
+ ]
+ },
+ "multimediaviewer-discuss-mmv": "бєсѣда"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/cy.json b/www/wiki/extensions/MultimediaViewer/i18n/cy.json
new file mode 100644
index 00000000..ecc06379
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/cy.json
@@ -0,0 +1,27 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lloffiwr",
+ "Robin Owain"
+ ]
+ },
+ "multimediaviewer-datetime-created": "Gwnaethpwyd: $1",
+ "multimediaviewer-datetime-uploaded": "Uwchlwythwyd: $1",
+ "multimediaviewer-license-cc-pd": "Parth Cyhoeddus",
+ "multimediaviewer-license-pd": "Parth Cyhoeddus",
+ "multimediaviewer-license-default": "Gweld y drwydded",
+ "multimediaviewer-permission-title": "Manylion hawliau",
+ "multimediaviewer-permission-link": "gweld y termau",
+ "multimediaviewer-permission-viewmore": "Gweld mwy",
+ "multimediaviewer-about-mmv": "Am Media Viewer",
+ "multimediaviewer-discuss-mmv": "Trafod y nodwedd hon",
+ "multimediaviewer-help-mmv": "Cymorth",
+ "multimediaviewer-optout-mmv": "Analluoger Media Viewer",
+ "multimediaviewer-optin-mmv": "Galluoger Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Wrthi'n analluogi Media Viewer",
+ "multimediaviewer-optin-pending-mmv": "Wrthi'n galluogi Media Viewer",
+ "multimediaviewer-geolocation": "Lleoliad: $1",
+ "multimediaviewer-reuse-loading-placeholder": "Wrthi'n llwytho",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-view-expanded": "Agorer yn Media Viewer"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/da.json b/www/wiki/extensions/MultimediaViewer/i18n/da.json
new file mode 100644
index 00000000..52b60fee
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/da.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Christian List"
+ ]
+ },
+ "multimediaviewer-desc": "Udvid miniaturebilleder i en større størrelse på en fuld skærm.",
+ "multimediaviewer-pref": "Medieviser",
+ "multimediaviewer-pref-desc": "Med dette nye værktøj kan du forbedre din multimedieoplevelse. Det viser billeder i større størrelse på sider, der har miniaturer. Billederne er vist i et pænere fuldskærmsformat, og kan også ses i fuld størrelse.",
+ "multimediaviewer-file-page": "Gå til tilsvarende filside",
+ "multimediaviewer-repository-local": "Lær mere",
+ "multimediaviewer-datetime-created": "Oprettet den $1",
+ "multimediaviewer-datetime-uploaded": "Uploadet den $1",
+ "multimediaviewer-license-cc-pd": "Offentlig ejendom",
+ "multimediaviewer-license-default": "Se licens",
+ "multimediaviewer-about-mmv": "Om Medieviser",
+ "multimediaviewer-discuss-mmv": "Giv feedback",
+ "multimediaviewer-geolocation": "Sted: $1",
+ "multimediaviewer-reuse-link": "Brug denne fil"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/de-ch.json b/www/wiki/extensions/MultimediaViewer/i18n/de-ch.json
new file mode 100644
index 00000000..9de2aacd
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/de-ch.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Filzstift"
+ ]
+ },
+ "multimediaviewer-desc": "Ermöglicht die Darstellung von Vorschaubildern in einer Vollbildschnittstelle"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/de-formal.json b/www/wiki/extensions/MultimediaViewer/i18n/de-formal.json
new file mode 100644
index 00000000..f7ed3027
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/de-formal.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kghbln"
+ ]
+ },
+ "multimediaviewer-optout-help": "Der Medienbetrachter wird nicht mehr zur Anzeige von Bildern verwendet. Um ihn wieder zu nutzen, klicken Sie zunächst auf die Schaltfläche „{{int:multimediaviewer-view-expanded}}“ neben einem beliebigen Bild. Klicken Sie dann auf „{{int:multimediaviewer-optin-mmv}}“.",
+ "multimediaviewer-download-attribution-cta-header": "Sie müssen den Urheber angeben",
+ "multimediaviewer-download-attribution-cta": "Zeigen Sie mir wie"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/de.json b/www/wiki/extensions/MultimediaViewer/i18n/de.json
new file mode 100644
index 00000000..cc364404
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/de.json
@@ -0,0 +1,137 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kghbln",
+ "Metalhead64",
+ "Snatcher",
+ "Inkowik",
+ "Steinsplitter",
+ "Keegan",
+ "WhatamIdoing",
+ "DerHexer",
+ "Envlh"
+ ]
+ },
+ "multimediaviewer-desc": "Ermöglicht die Darstellung von Vorschaubildern in einer Vollbildschnittstelle",
+ "multimediaviewer-pref": "Medienbetrachter",
+ "multimediaviewer-pref-desc": "Dieses neue Werkzeug ändert die Ansicht von Multimediadateien. Es zeigt Bilder auf Seiten größer an, die Vorschaubilder haben. Die Bilder werden in einem den Artikel überlagernden Kasten angezeigt und können auch als Vollbild dargestellt werden.",
+ "multimediaviewer-optin-pref": "Den <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Medienbetrachter]</span> nutzen",
+ "multimediaviewer-file-page": "Gehe zur zugehörigen Dateiseite",
+ "multimediaviewer-repository-local": "Weitere Einzelheiten",
+ "multimediaviewer-datetime-created": "Erstellt: $1",
+ "multimediaviewer-datetime-uploaded": "Hochgeladen: $1",
+ "multimediaviewer-credit-fallback": "Autoreninformationen ansehen",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ein weiterer|$1 weitere}} Urheber",
+ "multimediaviewer-multiple-authors-combine": "$1 und $2",
+ "multimediaviewer-metadata-error": "Die Einzelheiten des Bildes konnten nicht geladen werden (Fehler: $1)",
+ "multimediaviewer-thumbnail-error": "Leider kann die Datei nicht angezeigt werden",
+ "multimediaviewer-thumbnail-error-description": "Es scheint ein technisches Problem zu geben. Du kannst es $1 oder $3, falls es weiterhin besteht. Fehler: $2",
+ "multimediaviewer-thumbnail-error-retry": "erneut versuchen",
+ "multimediaviewer-thumbnail-error-report": "das Problem melden",
+ "multimediaviewer-license-cc-by-4.0": "CC-BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Gemeinfrei",
+ "multimediaviewer-license-pd": "Gemeinfrei",
+ "multimediaviewer-license-default": "Lizenz ansehen",
+ "multimediaviewer-permission-title": "Einzelheiten zur Genehmigung",
+ "multimediaviewer-permission-link": "Hinweise zur Weiternutzung",
+ "multimediaviewer-permission-link-hide": "Weiternutzungshinweise ausblenden",
+ "multimediaviewer-permission-viewmore": "Mehr",
+ "multimediaviewer-restriction-2257": "Dieses Bild enthält eindeutigen sexuellen Inhalt, der Gegenstand des „Child Protection and Obscenity Enforcement Act“ der Vereinigten Staaten sein könnte.",
+ "multimediaviewer-restriction-aus-reserve": "Dieses Bild wurde in einem australischen Commonwealth-Reservat fotografiert und kann ohne Genehmigung nicht zu kommerziellen Zwecken verwendet werden.",
+ "multimediaviewer-restriction-communist": "Dieses Bild enthält kommunistische Abzeichen, die in einigen Staaten verboten sein könnten.",
+ "multimediaviewer-restriction-costume": "Dieses Bild stellt Kostümierungen dar und könnte Gegenstand rechtlicher Beschränkungen sein.",
+ "multimediaviewer-restriction-currency": "Dieses Bild stellt eine Abbildung einer Währungseinheit dar und könnte Gegenstand rechtlicher Beschränkungen sein.",
+ "multimediaviewer-restriction-design": "Das Design des Gegenstands dieses Bildes könnte urheberrechtlich geschützt und Thema rechtlicher Beschränkungen sein.",
+ "multimediaviewer-restriction-fan-art": "Dieses Bild ist ein Werk von Fankunst und die Weiterverwendung könnte Gegenstand rechtlicher Beschränkungen sein.",
+ "multimediaviewer-restriction-ihl": "Dieses Bild enthält Symbole, die durch internationales humanitäres Recht geschützt sind.",
+ "multimediaviewer-restriction-insignia": "Dieses Bild enthält offizielle Abzeichen, die Gegenstand rechtlicher Beschränkungen sein könnten.",
+ "multimediaviewer-restriction-ita-mibac": "Dieses Bild reproduziert ein Eigentum des italienischen Kulturerbes und ist durch italienisches Recht beschränkt.",
+ "multimediaviewer-restriction-nazi": "Dieses Bild enthält nationalsozialistische oder andere faschistische Abzeichen, die in einigen Staaten verboten sein könnten.",
+ "multimediaviewer-restriction-personality": "Die Persönlichkeitsrechte der abgebildeten Person(en) beschränken bestimmte Weiterverwendungen des Bildes ohne dessen/deren vorherige Zustimmung.",
+ "multimediaviewer-restriction-trademarked": "Dieses Bild enthält einen Inhalt, der Thema von Markenrechten sein könnte.",
+ "multimediaviewer-restriction-default": "Dieses Bild könnte durch rechtliche Bestimmungen außerhalb des Urheberrechts beschränkt sein. Siehe die Dateibeschreibungsseite für Einzelheiten.",
+ "multimediaviewer-restriction-default-and-others": "Dieses Bild könnte durch andere rechtliche Bestimmungen außerhalb des Urheberrechts beschränkt sein. Siehe die Dateibeschreibungsseite für Einzelheiten.",
+ "multimediaviewer-about-mmv": "Über",
+ "multimediaviewer-discuss-mmv": "Diskutieren",
+ "multimediaviewer-help-mmv": "Hilfe",
+ "multimediaviewer-optout-mmv": "Medienbetrachter deaktivieren",
+ "multimediaviewer-optin-mmv": "Medienbetrachter aktivieren",
+ "multimediaviewer-optout-pending-mmv": "Deaktiviere den Medienbetrachter …",
+ "multimediaviewer-optin-pending-mmv": "Aktiviere den Medienbetrachter …",
+ "multimediaviewer-optout-help": "Der Medienbetrachter wird nicht mehr zur Anzeige von Bildern verwendet. Um ihn wieder zu nutzen, klicke zunächst auf die Schaltfläche „{{int:multimediaviewer-view-expanded}}“ neben einem beliebigen Bild. Klicke dann auf „{{int:multimediaviewer-optin-mmv}}“.",
+ "multimediaviewer-optin-help": "Der Medienbetrachter wird zur Anzeige von Bildern verwendet.",
+ "multimediaviewer-geolocation": "Standort: $1",
+ "multimediaviewer-reuse-link": "Diese Datei teilen oder einbetten",
+ "multimediaviewer-reuse-loading-placeholder": "Lade …",
+ "multimediaviewer-reuse-copy-share": "Wähle den Link zum Teilen dieser Datei aus und kopiere ihn (falls unterstützt)",
+ "multimediaviewer-reuse-copy-embed": "Wähle den Code zum Einbetten dieser Datei aus und kopiere ihn (falls unterstützt)",
+ "multimediaviewer-share-tab": "Teilen",
+ "multimediaviewer-embed-tab": "Einbetten",
+ "multimediaviewer-download-link": "Diese Datei herunterladen",
+ "multimediaviewer-download-preview-link-title": "Im Browser ansehen",
+ "multimediaviewer-download-original-button-name": "Originaldatei herunterladen",
+ "multimediaviewer-download-small-button-name": "In kleiner Größe herunterladen",
+ "multimediaviewer-download-medium-button-name": "In mittlerer Größe herunterladen",
+ "multimediaviewer-download-large-button-name": "In großer Größe herunterladen",
+ "multimediaviewer-link-to-page": "Link zur Dateibeschreibungsseite",
+ "multimediaviewer-link-to-file": "Link zur Originaldatei",
+ "multimediaviewer-share-explanation": "Kopieren und den Link teilen",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Diesen Code zum Einbetten der Datei verwenden",
+ "multimediaviewer-text-embed-credit-text-bl": "Von $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Von $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Von $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Von $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Link",
+ "multimediaviewer-embed-byline": "Von $1",
+ "multimediaviewer-embed-license": "Lizenziert unter $1.",
+ "multimediaviewer-embed-via": "Über $1.",
+ "multimediaviewer-default-embed-dimensions": "Standardvorschaubildgröße",
+ "multimediaviewer-original-embed-dimensions": "Originaldatei $1",
+ "multimediaviewer-large-embed-dimensions": "Groß $1",
+ "multimediaviewer-medium-embed-dimensions": "Mittel $1",
+ "multimediaviewer-small-embed-dimensions": "Klein $1",
+ "multimediaviewer-description-page-button-text": "Weitere Einzelheiten zu dieser Datei",
+ "multimediaviewer-description-page-popup-text": "Weitere Einzelheiten zu dieser Datei auf $1",
+ "multimediaviewer-commons-subtitle": "Das freie Medienarchiv",
+ "multimediaviewer-view-expanded": "Im Medienbetrachter öffnen",
+ "multimediaviewer-view-config": "Konfiguration",
+ "multimediaviewer-close-popup-text": "Dieses Werkzeug schließen (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Vollbildansicht aktivieren",
+ "multimediaviewer-defullscreen-popup-text": "Vollbildansicht deaktivieren",
+ "multimediaviewer-next-image-alt-text": "Nächstes Bild anzeigen",
+ "multimediaviewer-prev-image-alt-text": "Vorheriges Bild anzeigen",
+ "multimediaviewer-title-popup-text": "Beschreibung",
+ "multimediaviewer-credit-popup-text": "Informationen zu Urheber und Quelle",
+ "multimediaviewer-title-popup-text-more": "Vollständige Beschreibung anzeigen",
+ "multimediaviewer-credit-popup-text-more": "Vollständigen Urheber und Quelle anzeigen",
+ "multimediaviewer-download-attribution-cta-header": "Du musst den Urheber angeben",
+ "multimediaviewer-download-optional-attribution-cta-header": "Du kannst den Urheber angeben",
+ "multimediaviewer-download-attribution-cta": "Zeig mir wie",
+ "multimediaviewer-download-attribution-copy": "Wähle den Namensnennungstext für diese Datei aus und kopiere ihn (falls unterstützt)",
+ "multimediaviewer-reuse-warning-deletion": "Diese Datei wurde zur Löschung vorgeschlagen.",
+ "multimediaviewer-reuse-warning-nonfree": "Diese Datei hat keine freie Lizenz.",
+ "multimediaviewer-reuse-warning-noattribution": "Diese Datei hat keine Informationen zur Namensnennung.",
+ "multimediaviewer-reuse-warning-generic": "Überprüfe [$1 ihre Einzelheiten], bevor du sie verwendest.",
+ "multimediaviewer-attr-plain": "Klartext",
+ "multimediaviewer-options-tooltip": "Medienbetrachter aktivieren oder deaktivieren",
+ "multimediaviewer-options-dialog-header": "Medienbetrachter deaktivieren?",
+ "multimediaviewer-options-text-header": "Diese Betrachtungsfunktion für alle Dateien überspringen.",
+ "multimediaviewer-options-text-body": "Du kannst den Medienbetrachter später durch die Dateibeschreibungsseite aktivieren.",
+ "multimediaviewer-options-learn-more": "Weitere Informationen",
+ "multimediaviewer-option-submit-button": "Medienbetrachter deaktivieren",
+ "multimediaviewer-option-cancel-button": "Abbrechen",
+ "multimediaviewer-disable-confirmation-header": "Du hast den Medienbetrachter deaktiviert",
+ "multimediaviewer-disable-confirmation-text": "Wenn du das nächste Mal auf ein Vorschaubild auf $1 klickst, wirst du direkt alle Einzelheiten zur Datei ansehen können.",
+ "multimediaviewer-enable-dialog-header": "Medienbetrachter aktivieren?",
+ "multimediaviewer-enable-text-header": "Diese Medienbetrachtungsfunktion für alle Dateien standardmäßig aktivieren.",
+ "multimediaviewer-enable-submit-button": "Medienbetrachter aktivieren",
+ "multimediaviewer-enable-confirmation-header": "Du hast den Medienbetrachter für alle Dateien aktiviert",
+ "multimediaviewer-enable-confirmation-text": "Wenn du das nächste Mal auf ein Vorschaubild auf $1 klickst, wird der Medienbetrachter verwendet.",
+ "multimediaviewer-enable-alert": "Der Medienbetrachter ist jetzt deaktiviert",
+ "multimediaviewer-disable-info-title": "Du hast den Medienbetrachter deaktiviert",
+ "multimediaviewer-disable-info": "Du kannst dennoch einzelne Dateien mit dem Medienbetrachter ansehen.",
+ "multimediaviewer-errorreport-privacywarning": "Einzelheiten zum Fehler werden dem Bericht beigefügt, die öffentlich sichtbar sind. Falls du mit diesem Vorgehen nicht einverstanden bist, kannst du den Bericht unten bearbeiten und alle Daten entfernen, die du nicht teilen möchtest."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/diq.json b/www/wiki/extensions/MultimediaViewer/i18n/diq.json
new file mode 100644
index 00000000..40bd8e7c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/diq.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mirzali",
+ "Asmen",
+ "1917 Ekim Devrimi"
+ ]
+ },
+ "multimediaviewer-permission-viewmore": "Zêde bıvêne",
+ "multimediaviewer-discuss-mmv": "Werênayış",
+ "multimediaviewer-option-cancel-button": "Bıtexelne"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/dsb.json b/www/wiki/extensions/MultimediaViewer/i18n/dsb.json
new file mode 100644
index 00000000..b0c22b8a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/dsb.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "multimediaviewer-desc": "Miniaturki w pówjerchu połneje wobrazowki powětsyś.",
+ "multimediaviewer-pref": "Medijowy wobglědowak",
+ "multimediaviewer-pref-desc": "Polěpš swójo dožywjenje multimedijowego woglědowanja z toś tym rědom. Zwobraznja wobraze we wětšej wjelikosći na bokach, kótarež maju miniaturki. Wobraze pokazuju se w rědnjejšem pówjerchu połneje wobrazowki a daju se w połnej wjelikosći pśedstajiś.",
+ "multimediaviewer-file-page": "K pśisłušnemu datajowemu bokoju",
+ "multimediaviewer-repository-local": "Dalšne informacije",
+ "multimediaviewer-datetime-created": "Napórany $1",
+ "multimediaviewer-datetime-uploaded": "Nagraty $1",
+ "multimediaviewer-license-cc-pd": "Zjawnosći pśistupny",
+ "multimediaviewer-license-default": "Licencu se woglědaś",
+ "multimediaviewer-about-mmv": "Wó medijowem wobglědowaku",
+ "multimediaviewer-discuss-mmv": "Wo toś tej funkciji diskutěrowaś",
+ "multimediaviewer-geolocation": "Městno: $1",
+ "multimediaviewer-reuse-link": "Toś tu dataju wužywaś"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/el.json b/www/wiki/extensions/MultimediaViewer/i18n/el.json
new file mode 100644
index 00000000..783f1e81
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/el.json
@@ -0,0 +1,99 @@
+{
+ "@metadata": {
+ "authors": [
+ "Astralnet",
+ "Geraki",
+ "Nikosguard",
+ "Indoril",
+ "Evropi",
+ "Protnet",
+ "Xaris333",
+ "Glavkos",
+ "Nikosgranturismogt"
+ ]
+ },
+ "multimediaviewer-desc": "Επεκτείνετε τις μικρογραφίες σε μεγαλύτερο μέγεθος σε ένα περιβάλλον εργασίας πλήρους οθόνης.",
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-pref-desc": "Βελτιώστε την εμπειρία σας στην εμφάνιση πολυμέσων με αυτό το νέο εργαλείο. Εμφανίζει εικόνες σε μεγαλύτερο μέγεθος σε σελίδες που έχουν μικρογραφίες. Οι εικόνες εμφανίζονται σε μια καλύτερη πλήρους οθόνης διεπαφή επικάλυψης, και μπορούν επίσης να εμφανιστούν σε πλήρες μέγεθος.",
+ "multimediaviewer-optin-pref": "Ενεργοποίηση <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Μεταβείτε στην αντίστοιχη σελίδα του αρχείου",
+ "multimediaviewer-repository-local": "Περισσότερες λεπτομέρειες",
+ "multimediaviewer-datetime-created": "Δημιουργήθηκε: $1",
+ "multimediaviewer-datetime-uploaded": "Μεταφορτώθηκε:$1",
+ "multimediaviewer-metadata-error": "Σφάλμα: Δεν ήταν δυνατή η φόρτωση δεδομένων εικόνας. $1",
+ "multimediaviewer-thumbnail-error": "Σφάλμα: Δεν ήταν δυνατή η φόρτωση δεδομένων μικρογραφίας. $1",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Κοινό κτήμα",
+ "multimediaviewer-license-pd": "Κοινό Κτήμα",
+ "multimediaviewer-license-default": "Δείτε την άδεια",
+ "multimediaviewer-permission-title": "Λεπτομέρειες άδειας χρήσης",
+ "multimediaviewer-permission-link": "δείτε όρους",
+ "multimediaviewer-permission-viewmore": "Προβολή περισσοτέρων",
+ "multimediaviewer-about-mmv": "Σχετικά",
+ "multimediaviewer-discuss-mmv": "Συζήτηση",
+ "multimediaviewer-help-mmv": "Βοήθεια",
+ "multimediaviewer-optout-mmv": "Απενεργοποίηση Media Viewer",
+ "multimediaviewer-optin-mmv": "Ενεργοποίηση Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Απενεργοποίηση Media Viewer",
+ "multimediaviewer-optin-pending-mmv": "Ενεργοποίηση Media Viewer",
+ "multimediaviewer-optout-help": "Ο Media Viewer δεν θα χρησιμοποιείται πλέον για την εμφάνιση εικόνων. Για να το χρησιμοποιήσετε ξανά, κάντε κλικ στο «{{int:multimediaviewer-view-expanded}}» που βρίσκεται δίπλα σε κάθε εικόνα. Στη συνέχεια, κάντε κλικ στο «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Το Media Viewer θα χρησιμοποιείται για την εμφάνιση εικόνων.",
+ "multimediaviewer-geolocation": "Τοποθεσία: $1",
+ "multimediaviewer-reuse-link": "Μοιραστείτε ή ενσωματώστε αυτό το αρχείο",
+ "multimediaviewer-reuse-loading-placeholder": "Φόρτωση σε εξέλιξη...",
+ "multimediaviewer-share-tab": "Κοινοποίηση",
+ "multimediaviewer-embed-tab": "Ενσωμάτωση",
+ "multimediaviewer-download-link": "Λήψη αυτού του αρχείου",
+ "multimediaviewer-download-preview-link-title": "Προβολή στον περιηγητή",
+ "multimediaviewer-download-original-button-name": "Κατέβασμα αρχικού αρχείου",
+ "multimediaviewer-download-small-button-name": "Λήψη μικρού μεγέθους",
+ "multimediaviewer-download-medium-button-name": "Λήψη μεσαίου μεγέθους",
+ "multimediaviewer-download-large-button-name": "Λήψη μεγάλου μεγέθους",
+ "multimediaviewer-link-to-page": "Σύνδεση με τη σελίδα περιγραφής αρχείου",
+ "multimediaviewer-link-to-file": "Σύνδεση με το αρχικό αρχείο",
+ "multimediaviewer-share-explanation": "Αντιγράψετε και μοιραστείτε ελεύθερα το σύνδεσμο",
+ "multimediaviewer-embed-wt": "Κώδικας wiki",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Χρησιμοποιήσετε αυτόν τον κώδικα για να ενσωματώσετε το αρχείο",
+ "multimediaviewer-embed-byline": "Από $1",
+ "multimediaviewer-embed-license": "Υπό την άδεια $1.",
+ "multimediaviewer-embed-via": "Μέσω $1.",
+ "multimediaviewer-default-embed-dimensions": "Προεπιλεγμένο μέγεθος μικρογραφίας",
+ "multimediaviewer-original-embed-dimensions": "Πρωτότυπο αρχείο $1",
+ "multimediaviewer-large-embed-dimensions": "Μεγάλο $1",
+ "multimediaviewer-medium-embed-dimensions": "Μεσαίο $1",
+ "multimediaviewer-small-embed-dimensions": "Μικρό $1",
+ "multimediaviewer-description-page-button-text": "Περισσότερες λεπτομέρειες σχετικά με αυτό το αρχείο",
+ "multimediaviewer-description-page-popup-text": "Περισσότερες λεπτομέρειες σχετικά με αυτό το αρχείο στο $1",
+ "multimediaviewer-commons-subtitle": "Το ελεύθερο αποθετήριο πολυμέσων",
+ "multimediaviewer-view-expanded": "Άνοιγμα στο Media Viewer",
+ "multimediaviewer-view-config": "Διαμόρφωση",
+ "multimediaviewer-close-popup-text": "Κλείσιμο αυτού του εργαλείου (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Εμφάνιση σε πλήρη οθόνη",
+ "multimediaviewer-defullscreen-popup-text": "Έξοδος από πλήρη οθόνη",
+ "multimediaviewer-title-popup-text": "Περιγραφή",
+ "multimediaviewer-credit-popup-text": "Δημιουργός και πληροφορίες πηγής",
+ "multimediaviewer-title-popup-text-more": "Εμφάνιση πλήρους περιγραφής",
+ "multimediaviewer-credit-popup-text-more": "Πλήρης εμφάνιση συγγραφέα και πηγής",
+ "multimediaviewer-download-attribution-cta-header": "Θα πρέπει να αναφέρετε το δημιουργό",
+ "multimediaviewer-download-attribution-cta": "Δείξτε μου πώς",
+ "multimediaviewer-attr-plain": "Απλό",
+ "multimediaviewer-options-tooltip": "Ενεργοποίηση ή απενεργοποίηση του Media Viewer",
+ "multimediaviewer-options-dialog-header": "Απενεργοποίηση Media Viewer;",
+ "multimediaviewer-options-text-header": "Παραλείψτε αυτή τη δυνατότητα προβολής για όλα τα αρχεία.",
+ "multimediaviewer-options-text-body": "Μπορείτε να τον ενεργοποιήσετε αργότερα μέσω της σελίδας λεπτομερειών αρχείου.",
+ "multimediaviewer-options-learn-more": "Μάθετε περισσότερα",
+ "multimediaviewer-option-submit-button": "Απενεργοποίηση Media Viewer",
+ "multimediaviewer-option-cancel-button": "Ακύρωση",
+ "multimediaviewer-disable-confirmation-header": "Έχετε απενεργοποιήσει το Media Viewer",
+ "multimediaviewer-disable-confirmation-text": "Την επόμενη φορά που κάνετε κλικ σε μια μικρογραφία στο $1, θα μπορείτε άμεσα να προβάλετε όλες τις λεπτομέρειες του αρχείου.",
+ "multimediaviewer-enable-dialog-header": "Ενεργοποίηση Media Viewer;",
+ "multimediaviewer-enable-text-header": "Ενεργοποιήστε αυτή τη δυνατότητα προβολής πολυμέσων για όλα τα αρχεία από προεπιλογή.",
+ "multimediaviewer-enable-submit-button": "Ενεργοποίηση Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "Έχετε ενεργοποιημένο το Media Viewer για όλα τα αρχεία",
+ "multimediaviewer-enable-confirmation-text": "Την επόμενη φορά που θα κάνετε κλικ σε μια μικρογραφία στο $1, το Media Viewer θα χρησιμοποιηθεί.",
+ "multimediaviewer-enable-alert": "Ο Media Viewer είναι απενεργοποιημένος τώρα",
+ "multimediaviewer-disable-info-title": "Έχετε απενεργοποιήσει το Media Viewer",
+ "multimediaviewer-disable-info": "Μπορείτε ακόμα να προβάλετε μεμονωμένα αρχεία με το Media Viewer."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/eml.json b/www/wiki/extensions/MultimediaViewer/i18n/eml.json
new file mode 100644
index 00000000..875700a2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/eml.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gloria sah"
+ ]
+ },
+ "multimediaviewer-discuss-mmv": "Discusiòun"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/en-gb.json b/www/wiki/extensions/MultimediaViewer/i18n/en-gb.json
new file mode 100644
index 00000000..b6df0fb7
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/en-gb.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Shirayuki",
+ "Caliburn"
+ ]
+ },
+ "multimediaviewer-license-default": "View licence",
+ "multimediaviewer-permission-title": "Permission details",
+ "multimediaviewer-embed-license": "Licenced under $1."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/en.json b/www/wiki/extensions/MultimediaViewer/i18n/en.json
new file mode 100644
index 00000000..5f793f41
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/en.json
@@ -0,0 +1,156 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mark Holmquist <mtraceur@member.fsf.org>"
+ ]
+ },
+ "multimediaviewer-desc": "Expand thumbnails in a larger size in a fullscreen interface",
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-pref-desc": "Improve your multimedia viewing experience with this new tool. It displays images in larger size on pages that have thumbnails. Images are shown in a nicer fullscreen interface overlay, and can also be viewed in full-size.",
+ "multimediaviewer-optin-pref": "Enable <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Go to corresponding file page",
+ "multimediaviewer-repository-local": "More details",
+ "multimediaviewer-datetime-created": "Created: $1",
+ "multimediaviewer-datetime-uploaded": "Uploaded: $1",
+ "multimediaviewer-credit": "$1 - $2",
+ "multimediaviewer-credit-fallback": "View author information",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|one more author|$1 more authors}}",
+ "multimediaviewer-multiple-authors-combine": "$1 and $2",
+ "multimediaviewer-metadata-error": "Could not load image details (error: $1)",
+ "multimediaviewer-thumbnail-error": "Sorry, the file cannot be displayed",
+ "multimediaviewer-thumbnail-error-description": "There seems to be a technical issue. You can $1 or $3 if it persists. Error: $2",
+ "multimediaviewer-thumbnail-error-retry": "retry",
+ "multimediaviewer-thumbnail-error-report": "report the issue",
+ "multimediaviewer-report-issue-url": "https://phabricator.wikimedia.org/maniphest/task/create/?projects=PHID-PROJ-cabyqp5sf4hyvauln3sq&description=$1",
+ "multimediaviewer-license-cc-by-1.0": "CC BY 1.0",
+ "multimediaviewer-license-cc-sa-1.0": "CC SA 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC BY 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Public Domain",
+ "multimediaviewer-license-cc-zero": "CC 0",
+ "multimediaviewer-license-pd": "Public Domain",
+ "multimediaviewer-license-default": "View license",
+ "multimediaviewer-permission-title": "Permission details",
+ "multimediaviewer-permission-link": "view terms",
+ "multimediaviewer-permission-link-hide": "hide terms",
+ "multimediaviewer-permission-viewmore": "View more",
+ "multimediaviewer-restriction-2257": "This image contains sexually explicit content which may be subject to the Child Protection and Obscenity Enforcement Act in the United States.",
+ "multimediaviewer-restriction-aus-reserve": "This image was photographed in an Australian Commonwealth reserve and cannot be used for commercial gain without a permit.",
+ "multimediaviewer-restriction-communist": "This image contains Communist insignia which may be banned in some countries.",
+ "multimediaviewer-restriction-costume": "This image depicts costuming and may be subject to legal restrictions.",
+ "multimediaviewer-restriction-currency": "This image represents a depiction of a unit of currency and may be subject to legal restrictions.",
+ "multimediaviewer-restriction-design": "The design of the subject of this image may be copyrighted and subject to legal restrictions.",
+ "multimediaviewer-restriction-fan-art": "This image is a work of fan art, and re-use may be subject to legal restrictions.",
+ "multimediaviewer-restriction-ihl": "This image contains symbols restricted by International Humanitarian Law.",
+ "multimediaviewer-restriction-insignia": "This image contains official insignia which may be subject to legal restrictions.",
+ "multimediaviewer-restriction-ita-mibac": "This image reproduces a property belonging to Italian cultural heritage and is restricted by Italian law.",
+ "multimediaviewer-restriction-nazi": "This image contains Nazi or other fascist insignia which may be banned in some countries.",
+ "multimediaviewer-restriction-personality": "This image contains persons who may have rights that legally restrict certain re-uses of the image without consent.",
+ "multimediaviewer-restriction-trademarked": "This image contains content which may be subject to trademark laws.",
+ "multimediaviewer-restriction-default": "This image may be restricted by legal provisions outside of copyright law. See the file description page for details.",
+ "multimediaviewer-restriction-default-and-others": "This image may be further restricted by other legal provisions outside of copyright law. See the file description page for details.",
+ "multimediaviewer-about-mmv": "About",
+ "multimediaviewer-discuss-mmv": "Discussion",
+ "multimediaviewer-help-mmv": "Help",
+ "multimediaviewer-optout-mmv": "Disable Media Viewer",
+ "multimediaviewer-optin-mmv": "Enable Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Disabling Media Viewer",
+ "multimediaviewer-optin-pending-mmv": "Enabling Media Viewer",
+ "multimediaviewer-optout-help": "Media Viewer will no longer be used to show images. To use it again, click on the \"{{int:multimediaviewer-view-expanded}}\" button next to any image. Then click on \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Media Viewer will be used to show images.",
+ "multimediaviewer-geoloc-north": "N",
+ "multimediaviewer-geoloc-east": "E",
+ "multimediaviewer-geoloc-south": "S",
+ "multimediaviewer-geoloc-west": "W",
+ "multimediaviewer-geoloc-coord": "$1° $2′ $3″ $4",
+ "multimediaviewer-geoloc-coords": "$1, $2",
+ "multimediaviewer-geolocation": "Location: $1",
+ "multimediaviewer-reuse-link": "Share or embed this file",
+ "multimediaviewer-reuse-loading-placeholder": "Loading…",
+ "multimediaviewer-reuse-copy-share": "Select and copy (if supported) the link for sharing this file",
+ "multimediaviewer-reuse-copy-embed": "Select and copy (if supported) the code for embedding this file",
+ "multimediaviewer-share-tab": "Share",
+ "multimediaviewer-embed-tab": "Embed",
+ "multimediaviewer-download-link": "Download this file",
+ "multimediaviewer-download-preview-link-title": "View in browser",
+ "multimediaviewer-download-original-button-name": "Download original file",
+ "multimediaviewer-download-small-button-name": "Download small size",
+ "multimediaviewer-download-medium-button-name": "Download medium size",
+ "multimediaviewer-download-large-button-name": "Download large size",
+ "multimediaviewer-link-to-page": "Link to file description page",
+ "multimediaviewer-link-to-file": "Link to original file",
+ "multimediaviewer-share-explanation": "Copy and freely share the link",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Use this code to embed the file",
+ "multimediaviewer-text-embed-credit-text-bl": "By $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "By $1, $2",
+ "multimediaviewer-text-embed-credit-text-l": "$1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "By $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "By $1, $2",
+ "multimediaviewer-html-embed-credit-text-l": "$1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Link",
+ "multimediaviewer-embed-byline": "By $1",
+ "multimediaviewer-embed-license": "Licensed under $1.",
+ "multimediaviewer-embed-license-nonfree": "$1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Default thumbnail size",
+ "multimediaviewer-original-embed-dimensions": "Original file $1",
+ "multimediaviewer-large-embed-dimensions": "Large $1",
+ "multimediaviewer-medium-embed-dimensions": "Medium $1",
+ "multimediaviewer-small-embed-dimensions": "Small $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 px",
+ "multimediaviewer-embed-dimensions-separated": "- $1",
+ "multimediaviewer-embed-dimensions-with-file-format": "$1 $2",
+ "multimediaviewer-description-page-button-text": "More details about this file",
+ "multimediaviewer-description-page-popup-text": "More details about this file on $1",
+ "multimediaviewer-commons-subtitle": "The free media repository",
+ "multimediaviewer-view-expanded": "Open in Media Viewer",
+ "multimediaviewer-view-config": "Configuration",
+ "multimediaviewer-close-popup-text": "Close this tool (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Show in full screen",
+ "multimediaviewer-defullscreen-popup-text": "Exit full screen",
+ "multimediaviewer-next-image-alt-text": "Show next image",
+ "multimediaviewer-prev-image-alt-text": "Show previous image",
+ "multimediaviewer-title-popup-text": "Description",
+ "multimediaviewer-credit-popup-text": "Author and source information",
+ "multimediaviewer-title-popup-text-more": "View full description",
+ "multimediaviewer-credit-popup-text-more": "View full author and source",
+ "multimediaviewer-download-attribution-cta-header": "You need to attribute the author",
+ "multimediaviewer-download-optional-attribution-cta-header": "You can attribute the author",
+ "multimediaviewer-download-attribution-cta": "Show me how",
+ "multimediaviewer-download-attribution-copy": "Select and copy (if supported) the attribution text for this file",
+ "multimediaviewer-reuse-warning-deletion": "This file is considered for deletion.",
+ "multimediaviewer-reuse-warning-nonfree": "This file does not have a free license.",
+ "multimediaviewer-reuse-warning-noattribution": "This file has no attribution information.",
+ "multimediaviewer-reuse-warning-generic": "Check [$1 its details] before using it.",
+ "multimediaviewer-attr-plain": "Plain",
+ "multimediaviewer-attr-html": "HTML",
+ "multimediaviewer-options-tooltip": "Enable or disable Media Viewer",
+ "multimediaviewer-options-dialog-header": "Disable Media Viewer?",
+ "multimediaviewer-options-text-header": "Skip this viewing feature for all files.",
+ "multimediaviewer-options-text-body": "You can enable it later through the file details page.",
+ "multimediaviewer-options-learn-more": "Learn more",
+ "multimediaviewer-option-submit-button": "Disable Media Viewer",
+ "multimediaviewer-option-cancel-button": "Cancel",
+ "multimediaviewer-disable-confirmation-header": "You have disabled Media Viewer",
+ "multimediaviewer-disable-confirmation-text": "Next time you click on a thumbnail on $1, you will directly view all file details.",
+ "multimediaviewer-enable-dialog-header": "Enable Media Viewer?",
+ "multimediaviewer-enable-text-header": "Enable this media viewing feature for all files by default.",
+ "multimediaviewer-enable-submit-button": "Enable Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "You have enabled Media Viewer for all files",
+ "multimediaviewer-enable-confirmation-text": "Next time you click on a thumbnail on $1, Media Viewer will be used.",
+ "multimediaviewer-enable-alert": "Media Viewer is now disabled",
+ "multimediaviewer-disable-info-title": "You have disabled Media Viewer",
+ "multimediaviewer-disable-info": "You can still view individual files with Media Viewer.",
+ "multimediaviewer-errorreport-privacywarning": "Details of the error are attached to the report, which will be publicly viewable. If you are not comfortable with that, you can edit the report below and remove all the data you don't want to share."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/eo.json b/www/wiki/extensions/MultimediaViewer/i18n/eo.json
new file mode 100644
index 00000000..a7541f92
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/eo.json
@@ -0,0 +1,103 @@
+{
+ "@metadata": {
+ "authors": [
+ "KuboF",
+ "Tlustulimu",
+ "Macofe",
+ "Robin van der Vliet"
+ ]
+ },
+ "multimediaviewer-desc": "Etendi miniaturojn al larĝa grandeco en plenekrana interfaco.",
+ "multimediaviewer-pref": "Media Montrilo",
+ "multimediaviewer-pref-desc": "Plibonigi vian spektadon de plurmediaĵoj per tiu ĉi nova ilo. En paĝoj kie estas uzataj miniaturoj, ĝi montras bildojn pli grande. Bildoj estas montrataj en pli bela plenekrana interfaco kaj eblas ilin spekti en plena grandeco.",
+ "multimediaviewer-optin-pref": "Ŝalti <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Median Montrilon]</span>",
+ "multimediaviewer-file-page": "Iri al la paĝo kun priskribo de la dosiero",
+ "multimediaviewer-repository-local": "Pliaj detaloj",
+ "multimediaviewer-datetime-created": "Kreita: $1",
+ "multimediaviewer-datetime-uploaded": "Alŝutita: $1",
+ "multimediaviewer-credit-fallback": "Montri informojn pri aŭtoro",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|unu plia aŭtoro|$1 pliaj aŭtoroj}}",
+ "multimediaviewer-multiple-authors-combine": "$1 kaj $2",
+ "multimediaviewer-metadata-error": "Ne eblas ŝuti detalojn pri la bildo (eraro: $1)",
+ "multimediaviewer-thumbnail-error": "Pardonu, la dosiero ne povas esti montrita",
+ "multimediaviewer-thumbnail-error-description": "Tio ĉi ŝajnas esti teĥnika problemo. Vi povas $1 aŭ $3 se ĝi persistas. Eraro: $2",
+ "multimediaviewer-thumbnail-error-retry": "reprovi",
+ "multimediaviewer-thumbnail-error-report": "raporti la problemon",
+ "multimediaviewer-license-cc-pd": "Publika havaĵo",
+ "multimediaviewer-license-pd": "Publika havaĵo",
+ "multimediaviewer-license-default": "Montri permesilon",
+ "multimediaviewer-permission-title": "Detaloj pri permesilo",
+ "multimediaviewer-permission-link": "montri kondiĉojn",
+ "multimediaviewer-permission-link-hide": "kaŝi kondiĉojn",
+ "multimediaviewer-permission-viewmore": "Montri pli",
+ "multimediaviewer-restriction-communist": "Tiu ĉi bildo enhavas komunismajn insignojn, kiuj povas estis malpermesitaj en iuj landoj.",
+ "multimediaviewer-restriction-trademarked": "Enhavo de tiu ĉi bildo povas esti protektata per komercmarkaj leĝoj.",
+ "multimediaviewer-about-mmv": "Pri",
+ "multimediaviewer-discuss-mmv": "Diskuti tiun ĉi funkcion",
+ "multimediaviewer-help-mmv": "Helpo",
+ "multimediaviewer-optout-mmv": "Malŝalti Median Montrilon",
+ "multimediaviewer-optin-mmv": "Ŝalti Median Montrilon",
+ "multimediaviewer-optout-pending-mmv": "Media Montrilo malŝaltiĝas",
+ "multimediaviewer-optin-pending-mmv": "Media Montrilo ŝaltiĝas",
+ "multimediaviewer-optout-help": "Media Montrilo ne plu estos uzata por montri bildojn. Por denove ekuzi ĝin, klaku al la butono \"{{int:multimediaviewer-view-expanded}}\" tuj apud ajna bildo. Poste klaku al \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Media Montrilo estos uzata por montrado bildojn",
+ "multimediaviewer-geolocation": "Loko: $1",
+ "multimediaviewer-reuse-link": "Kunhavigi aŭ enkonstrui tiun ĉi dosieron",
+ "multimediaviewer-reuse-loading-placeholder": "Ŝutado...",
+ "multimediaviewer-share-tab": "Kunhavigi",
+ "multimediaviewer-embed-tab": "Enkonstrui",
+ "multimediaviewer-download-link": "Elŝuti tiun ĉi dosieron",
+ "multimediaviewer-download-preview-link-title": "Malfermi en retumilo",
+ "multimediaviewer-download-original-button-name": "Elŝuti originan dosieron",
+ "multimediaviewer-download-small-button-name": "Elŝuti malgrandan dosieron",
+ "multimediaviewer-download-medium-button-name": "Elŝuti mezgrandan dosieron",
+ "multimediaviewer-download-large-button-name": "Elŝuti grandan dosieron",
+ "multimediaviewer-link-to-page": "Ligilo al paĝo kun priskribo de la dosiero",
+ "multimediaviewer-link-to-file": "Ligilo al origina dosiero",
+ "multimediaviewer-share-explanation": "Kopiu kaj libere kunhavigu la ligilon",
+ "multimediaviewer-embed-wt": "Vikiteksto",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Uzu tiun ĉi kodon por enkonstrui la dosieron",
+ "multimediaviewer-html-embed-credit-link-text": "Ligilo",
+ "multimediaviewer-embed-byline": "De $1",
+ "multimediaviewer-embed-license": "Licencita laŭ $1.",
+ "multimediaviewer-embed-via": "De $1.",
+ "multimediaviewer-default-embed-dimensions": "Defaŭlta grandeco de miniaturo",
+ "multimediaviewer-original-embed-dimensions": "Origina dosiero $1",
+ "multimediaviewer-large-embed-dimensions": "Granda $1",
+ "multimediaviewer-medium-embed-dimensions": "Mezgranda $1",
+ "multimediaviewer-small-embed-dimensions": "Malgranda $1",
+ "multimediaviewer-description-page-button-text": "Pliaj detaloj pri tiu ĉi dosiero",
+ "multimediaviewer-description-page-popup-text": "Pliaj detaloj pri tiu ĉi dosiero en $1",
+ "multimediaviewer-commons-subtitle": "Libera doser-deponejo",
+ "multimediaviewer-view-expanded": "Malfermi en Media Montrilo",
+ "multimediaviewer-view-config": "Agordoj",
+ "multimediaviewer-close-popup-text": "Fermi tiun ĉi ilon (Esk)",
+ "multimediaviewer-fullscreen-popup-text": "Montri plenekrane",
+ "multimediaviewer-defullscreen-popup-text": "Eliri plenekranon",
+ "multimediaviewer-title-popup-text": "Priskribo",
+ "multimediaviewer-credit-popup-text": "Informoj pri aŭtoro kaj fonto",
+ "multimediaviewer-title-popup-text-more": "Montri plenan priskribon",
+ "multimediaviewer-credit-popup-text-more": "Montri plenajn informojn pri aŭtoro kaj fonto",
+ "multimediaviewer-download-attribution-cta-header": "Vi devas atribui la aŭtoron",
+ "multimediaviewer-download-optional-attribution-cta-header": "Vi povas atribui la aŭtoron",
+ "multimediaviewer-download-attribution-cta": "Montru al mi kiel",
+ "multimediaviewer-attr-plain": "Plata teksto",
+ "multimediaviewer-options-tooltip": "Ŝalti aŭ malŝalti Median Montrilon",
+ "multimediaviewer-options-dialog-header": "Ĉu malŝalti Median Montrilon?",
+ "multimediaviewer-options-text-header": "Tio malŝaltos tiun ĉi montro-funkcion por ĉiuj dosieroj.",
+ "multimediaviewer-options-text-body": "Vi povas ĝin denove ŝalti en la paĝo kun detaloj pri dosiero.",
+ "multimediaviewer-options-learn-more": "Lernu pli",
+ "multimediaviewer-option-submit-button": "Malŝalti Median Montrilon",
+ "multimediaviewer-option-cancel-button": "Nuligi",
+ "multimediaviewer-disable-confirmation-header": "Vi malŝaltis Median Montrilon",
+ "multimediaviewer-disable-confirmation-text": "Sekvafoje kiam vi klakos al miniaturo en $1, vi rekte vidos ĉiujn dosierajn detalojn.",
+ "multimediaviewer-enable-dialog-header": "Ĉu ŝalti Median Montrilon?",
+ "multimediaviewer-enable-text-header": "Ŝalti tiun ĉi medi-montran funkcion defaŭlte por ĉiuj dosieroj.",
+ "multimediaviewer-enable-submit-button": "Ŝalti Median Montrilon",
+ "multimediaviewer-enable-confirmation-header": "Vi ŝaltis Median Montrilon por ĉiuj dosieroj",
+ "multimediaviewer-enable-confirmation-text": "Sekvafoje kiam vi klakos al miniaturo en $1, estos uzata Media Montrilo.",
+ "multimediaviewer-enable-alert": "Media Montrilo nun estas malŝaltita.",
+ "multimediaviewer-disable-info-title": "Vi malŝaltis Median Montrilon",
+ "multimediaviewer-disable-info": "Vi daŭre povas vidigi unuopajn dosierojn per Media Montrilo."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/es-formal.json b/www/wiki/extensions/MultimediaViewer/i18n/es-formal.json
new file mode 100644
index 00000000..91b45a6f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/es-formal.json
@@ -0,0 +1,57 @@
+{
+ "@metadata": {
+ "authors": [
+ "DJ Nietzsche",
+ "Jduranboger",
+ "Baffo"
+ ]
+ },
+ "multimediaviewer-desc": "Expande las miniaturas a un tamaño mayor en modo de pantalla completa.",
+ "multimediaviewer-pref": "Visor Multimedia",
+ "multimediaviewer-pref-desc": "Mejora tu experienecia de visualización multimedia con ésta nueva herramienta. El Visor Multimedia muestra las imágenes más grandes en las páginas que tienen miniaturas. Las imágenes se muestran en una interfaz de pantalla completa más agradable, y también pueden verse a tamaño completo.",
+ "multimediaviewer-optin-pref": "Habilita nueva experiencia de visualización multimedia",
+ "multimediaviewer-file-page": "Ir a la página del archivo",
+ "multimediaviewer-repository-local": "Aprende más",
+ "multimediaviewer-datetime-created": "Creado en $1",
+ "multimediaviewer-datetime-uploaded": "Subido en $1",
+ "multimediaviewer-metadata-error": "Error: No se puede cargar datos de la imagen. $1",
+ "multimediaviewer-thumbnail-error": "Error: No se puede cargar datos de la miniatura. $1",
+ "multimediaviewer-license-cc-pd": "Dominio Público",
+ "multimediaviewer-license-pd": "Dominio Público",
+ "multimediaviewer-license-default": "Ver licencia",
+ "multimediaviewer-permission-title": "Detalles de la licencia",
+ "multimediaviewer-permission-link": "ver términos",
+ "multimediaviewer-permission-viewmore": "Ver más",
+ "multimediaviewer-about-mmv": "Acerca del Visor Multimedia",
+ "multimediaviewer-discuss-mmv": "Dejar comentarios",
+ "multimediaviewer-help-mmv": "Ayuda",
+ "multimediaviewer-geolocation": "Ubicación: $1",
+ "multimediaviewer-reuse-link": "Compartir o Insertar este archivo",
+ "multimediaviewer-reuse-loading-placeholder": "Cargando...",
+ "multimediaviewer-share-tab": "Compartir",
+ "multimediaviewer-embed-tab": "Incrustar",
+ "multimediaviewer-download-link": "Descargar",
+ "multimediaviewer-download-preview-link-title": "Previsualizar en navegador",
+ "multimediaviewer-download-original-button-name": "Descargar tamaño original",
+ "multimediaviewer-download-small-button-name": "Descargar tamaño pequeño",
+ "multimediaviewer-download-medium-button-name": "Descargar tamaño mediano",
+ "multimediaviewer-download-large-button-name": "Descargar tamaño grande",
+ "multimediaviewer-link-to-page": "Enlace a la página de descripción del archivo",
+ "multimediaviewer-link-to-file": "Enlace al archivo original",
+ "multimediaviewer-share-explanation": "Copiar y compartir el enlace",
+ "multimediaviewer-embed-wt": "Wikitexto",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Utiliza este código para incrustar el archivo",
+ "multimediaviewer-embed-byline": "Por $1",
+ "multimediaviewer-embed-license": "Disponible bajo licencia $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Tamaño de miniaturas predeterminado",
+ "multimediaviewer-original-embed-dimensions": "Tamaño original $1",
+ "multimediaviewer-large-embed-dimensions": "Grande $1",
+ "multimediaviewer-medium-embed-dimensions": "Mediano $1",
+ "multimediaviewer-small-embed-dimensions": "Pequeño $1",
+ "multimediaviewer-description-page-button-text": "Más detalles",
+ "multimediaviewer-description-page-popup-text": "Más detalles en $1",
+ "multimediaviewer-commons-subtitle": "El repositorio multimedia libre",
+ "multimediaviewer-view-expanded": "Vista expandida"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/es.json b/www/wiki/extensions/MultimediaViewer/i18n/es.json
new file mode 100644
index 00000000..8b948e7d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/es.json
@@ -0,0 +1,138 @@
+{
+ "@metadata": {
+ "authors": [
+ "Benfutbol10",
+ "Carlitosag",
+ "Ciencia Al Poder",
+ "Csbotero",
+ "Fitoschido",
+ "PoLuX124",
+ "DJ Nietzsche",
+ "Jduranboger",
+ "Macofe",
+ "Themasterriot",
+ "Dgstranz"
+ ]
+ },
+ "multimediaviewer-desc": "Expande las miniaturas a un tamaño mayor en una vista de pantalla completa.",
+ "multimediaviewer-pref": "Visor multimedia",
+ "multimediaviewer-pref-desc": "Mejora tu experiencia de visualización multimedia con esta herramienta. Las imágenes se muestran en una vista a pantalla completa que incluye información relevante de las mismas.",
+ "multimediaviewer-optin-pref": "Activar el <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About visor multimedia]</span>",
+ "multimediaviewer-file-page": "Ir a la página del archivo correspondiente",
+ "multimediaviewer-repository-local": "Más detalles",
+ "multimediaviewer-datetime-created": "Creado el: $1",
+ "multimediaviewer-datetime-uploaded": "Subido el: $1",
+ "multimediaviewer-credit-fallback": "Ver información del autor",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|un autor más|$1 autores más}}",
+ "multimediaviewer-multiple-authors-combine": "$1 y $2",
+ "multimediaviewer-metadata-error": "No se pueden cargar detalles de la imagen (error: $1)",
+ "multimediaviewer-thumbnail-error": "No se puede mostrar el archivo",
+ "multimediaviewer-thumbnail-error-description": "Parece que hay un problema técnico. Puedes $1 o $3 si persiste. Error: $2",
+ "multimediaviewer-thumbnail-error-retry": "reintentar",
+ "multimediaviewer-thumbnail-error-report": "reportar el problema",
+ "multimediaviewer-license-cc-pd": "Dominio público",
+ "multimediaviewer-license-pd": "Dominio público",
+ "multimediaviewer-license-default": "Ver licencia",
+ "multimediaviewer-permission-title": "Detalles de permisos",
+ "multimediaviewer-permission-link": "ver términos",
+ "multimediaviewer-permission-link-hide": "ocultar términos",
+ "multimediaviewer-permission-viewmore": "Ver más",
+ "multimediaviewer-restriction-2257": "Esta imagen contiene contenido sexual explícito, el cual podría someterse a las estipulaciones de la Ley de Protección Infantil y Material Obsceno de los Estados Unidos.",
+ "multimediaviewer-restriction-aus-reserve": "Esta fotografía fue capturada en una reserva federal australiana y no puede utilizarse con fines comerciales sin previa autorización.",
+ "multimediaviewer-restriction-communist": "Esta imagen contiene simbología comunista que puede estar prohibida en algunos países.",
+ "multimediaviewer-restriction-costume": "Esta imagen muestra vestuarios y puede estar sujeta a restricciones legales.",
+ "multimediaviewer-restriction-currency": "Esta imagen constituye una representación de una unidad monetaria y puede estar sujeta a restricciones legales.",
+ "multimediaviewer-restriction-design": "El diseño del objeto representado en esta imagen puede tener derechos de autor y estar sujeta a restricciones legales.",
+ "multimediaviewer-restriction-fan-art": "Esta imagen es una obra de arte creado por fanáticos cuya reutilización puede estar sujeta a restricciones legales.",
+ "multimediaviewer-restriction-ihl": "Esta imagen contiene símbolos restringidos por el derecho internacional humanitario.",
+ "multimediaviewer-restriction-insignia": "Esta imagen contiene simbología oficial que puede estar sujeta a restricciones legales.",
+ "multimediaviewer-restriction-ita-mibac": "Esta imagen reproduce una propiedad del patrimonio cultural italiano y está restringida por las leyes italianas.",
+ "multimediaviewer-restriction-nazi": "Esta imagen contiene simbología nazi o fascista que puede estar prohibida en algunos países.",
+ "multimediaviewer-restriction-personality": "Esta imagen contiene personas que pueden tener derechos que restrinjan legalmente la reutilización sin consentimiento de esta imagen.",
+ "multimediaviewer-restriction-trademarked": "Esta imagen incluye contenido que puede estar sujeto a leyes sobre registro de marcas.",
+ "multimediaviewer-restriction-default": "Esta imagen puede estar restringida por disposiciones legales no relacionadas con la propiedad intelectual. Consulta la página de descripción para obtener detalles.",
+ "multimediaviewer-restriction-default-and-others": "Esta imagen puede estar aún restringida por disposiciones legales no relacionadas con la propiedad intelectual. Consulta la página de descripción del archivo para obtener detalles.",
+ "multimediaviewer-about-mmv": "Acerca de",
+ "multimediaviewer-discuss-mmv": "Discusión",
+ "multimediaviewer-help-mmv": "Ayuda",
+ "multimediaviewer-optout-mmv": "Desactivar el visor multimedia",
+ "multimediaviewer-optin-mmv": "Activar el visor multimedia",
+ "multimediaviewer-optout-pending-mmv": "Desactivando el visor multimedia",
+ "multimediaviewer-optin-pending-mmv": "Activando el visor multimedia",
+ "multimediaviewer-optout-help": "El Visor multimedia ya no se usará para mostrar imágenes. Para volver a usarlo, haz clic en el botón «{{int:multimediaviewer-view-expanded}}» junto a cada imagen. Luego haz clic en «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Las imágenes se abrirán ahora con el visor multimedia.",
+ "multimediaviewer-geolocation": "Ubicación: $1",
+ "multimediaviewer-reuse-link": "Compartir o incrustar este archivo",
+ "multimediaviewer-reuse-loading-placeholder": "Cargando…",
+ "multimediaviewer-reuse-copy-share": "Selecciona y copia (si se permite) el enlace para compartir este archivo",
+ "multimediaviewer-reuse-copy-embed": "Selecciona y copia (si se permite) el código para incrustar este archivo",
+ "multimediaviewer-share-tab": "Compartir",
+ "multimediaviewer-embed-tab": "Incrustar",
+ "multimediaviewer-download-link": "Descargar este archivo",
+ "multimediaviewer-download-preview-link-title": "Ver en el navegador",
+ "multimediaviewer-download-original-button-name": "Descargar el archivo original",
+ "multimediaviewer-download-small-button-name": "Descargar tamaño pequeño",
+ "multimediaviewer-download-medium-button-name": "Descargar tamaño mediano",
+ "multimediaviewer-download-large-button-name": "Descargar tamaño grande",
+ "multimediaviewer-link-to-page": "Enlace a la página de descripción del archivo",
+ "multimediaviewer-link-to-file": "Enlace al archivo original",
+ "multimediaviewer-share-explanation": "Copiar y compartir el enlace",
+ "multimediaviewer-embed-wt": "Wikitexto",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Utiliza este código para incrustar el archivo",
+ "multimediaviewer-text-embed-credit-text-bl": "De $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "De $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "De $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "De $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Enlace",
+ "multimediaviewer-embed-byline": "Por $1",
+ "multimediaviewer-embed-license": "Disponible bajo la licencia $1.",
+ "multimediaviewer-embed-via": "Vía $1.",
+ "multimediaviewer-default-embed-dimensions": "Tamaño de miniaturas predeterminado",
+ "multimediaviewer-original-embed-dimensions": "Archivo original, $1",
+ "multimediaviewer-large-embed-dimensions": "Grande, $1",
+ "multimediaviewer-medium-embed-dimensions": "Mediano, $1",
+ "multimediaviewer-small-embed-dimensions": "Pequeño, $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 px",
+ "multimediaviewer-description-page-button-text": "Más detalles sobre este archivo",
+ "multimediaviewer-description-page-popup-text": "Más detalles sobre este archivo en $1",
+ "multimediaviewer-commons-subtitle": "El repositorio de multimedia libre",
+ "multimediaviewer-view-expanded": "Abrir en el visor multimedia",
+ "multimediaviewer-view-config": "Configuración",
+ "multimediaviewer-close-popup-text": "Cerrar esta herramienta (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Mostrar a pantalla completa",
+ "multimediaviewer-defullscreen-popup-text": "Salir de pantalla completa",
+ "multimediaviewer-next-image-alt-text": "Mostrar imagen siguiente",
+ "multimediaviewer-prev-image-alt-text": "Mostrar imagen anterior",
+ "multimediaviewer-title-popup-text": "Descripción",
+ "multimediaviewer-credit-popup-text": "Información de autor y fuente",
+ "multimediaviewer-title-popup-text-more": "Ver descripción completa",
+ "multimediaviewer-credit-popup-text-more": "Ver la fuente y el autor completos",
+ "multimediaviewer-download-attribution-cta-header": "Es necesario dar reconocimiento al autor",
+ "multimediaviewer-download-optional-attribution-cta-header": "Puedes dar reconocimiento al autor",
+ "multimediaviewer-download-attribution-cta": "Mostrarme cómo",
+ "multimediaviewer-download-attribution-copy": "Selecciona y copia (si es posible) el texto de atribución de este archivo",
+ "multimediaviewer-reuse-warning-deletion": "Se está considerando el borrado de este archivo.",
+ "multimediaviewer-reuse-warning-nonfree": "Este archivo no está disponible bajo una licencia libre.",
+ "multimediaviewer-reuse-warning-noattribution": "Este archivo no tiene información de atribución.",
+ "multimediaviewer-reuse-warning-generic": "Comprueba [$1 sus detalles] antes de utilizarlo.",
+ "multimediaviewer-attr-plain": "Texto sin formato",
+ "multimediaviewer-options-tooltip": "Activar o desactivar el Visor multimedia",
+ "multimediaviewer-options-dialog-header": "¿Desactivar el visor multimedia?",
+ "multimediaviewer-options-text-header": "Omitir esta función de visualización para todos los archivos.",
+ "multimediaviewer-options-text-body": "Puedes activarlo más tarde mediante la página de detalles de archivos.",
+ "multimediaviewer-options-learn-more": "Más información",
+ "multimediaviewer-option-submit-button": "Desactivar el visor multimedia",
+ "multimediaviewer-option-cancel-button": "Cancelar",
+ "multimediaviewer-disable-confirmation-header": "Has desactivado el visor multimedia",
+ "multimediaviewer-disable-confirmation-text": "La próxima vez que haga clic en una miniatura en $1, verá de manera directa los detalles del archivo.",
+ "multimediaviewer-enable-dialog-header": "¿Activar el visor multimedia?",
+ "multimediaviewer-enable-text-header": "Activar esta función de visualización para todos los archivos de manera predeterminada.",
+ "multimediaviewer-enable-submit-button": "Activar el visor multimedia",
+ "multimediaviewer-enable-confirmation-header": "Has activado el visor multimedia para todos los archivos",
+ "multimediaviewer-enable-confirmation-text": "La próxima vez que hagas clic sobre una miniatura en $1, se usará el visor multimedia.",
+ "multimediaviewer-enable-alert": "Se ha desactivo el visor multimedia",
+ "multimediaviewer-disable-info-title": "Has desactivado el visor multimedia",
+ "multimediaviewer-disable-info": "Aún puede ver archivos individuales con el Visor Multimedia.",
+ "multimediaviewer-errorreport-privacywarning": "El informe contiene detalles del error que serán visibles públicamente. Si ello no te inspira confianza, puedes modificar el informe para quitarle cualquier dato que no quieras compartir."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/et.json b/www/wiki/extensions/MultimediaViewer/i18n/et.json
new file mode 100644
index 00000000..e34b6858
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/et.json
@@ -0,0 +1,116 @@
+{
+ "@metadata": {
+ "authors": [
+ "Pikne",
+ "WikedKentaur",
+ "Metsavend",
+ "Macofe"
+ ]
+ },
+ "multimediaviewer-desc": "Võimaldab vaadata pisipilte täisekraaniliideses.",
+ "multimediaviewer-pref": "Failivaatur",
+ "multimediaviewer-pref-desc": "Täienda meediafailide vaatamise võimalusi selle uue tööriistaga. See võimaldab kuvada pisipiltidega lehekülgedel pildid suuremana. Pilte saab näidata kenamas täisekraaniliideses ja ka täissuuruses.",
+ "multimediaviewer-optin-pref": "Kasuta <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About failivaaturit]</span>",
+ "multimediaviewer-file-page": "Mine failileheküljele",
+ "multimediaviewer-repository-local": "Rohkem üksikasju",
+ "multimediaviewer-datetime-created": "Valmistatud: $1",
+ "multimediaviewer-datetime-uploaded": "Üles laaditud: $1",
+ "multimediaviewer-credit": "$1 – $2",
+ "multimediaviewer-credit-fallback": "Vaata autoriteavet",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|veel üks autor|veel $1 autorit}}",
+ "multimediaviewer-multiple-authors-combine": "$1 ja $2",
+ "multimediaviewer-metadata-error": "Pildi üksikasju ei õnnestunud laadida (tõrge: $1)",
+ "multimediaviewer-thumbnail-error": "Failinime kahjuks ei õnnestu kuvada",
+ "multimediaviewer-thumbnail-error-description": "Paistab, et tegu on tehnilise probleemiga. Saad $1 või $3, kui see on püsiv. Tõrge: $2",
+ "multimediaviewer-thumbnail-error-retry": "uuesti proovida",
+ "multimediaviewer-thumbnail-error-report": "probleemist teatada",
+ "multimediaviewer-license-cc-pd": "Avalik omand",
+ "multimediaviewer-license-pd": "Avalik omand",
+ "multimediaviewer-license-default": "Vaata litsentsi",
+ "multimediaviewer-permission-title": "Loa üksikasjad",
+ "multimediaviewer-permission-link": "vaata tingimusi",
+ "multimediaviewer-permission-link-hide": "peida tingimused",
+ "multimediaviewer-permission-viewmore": "Vaata rohkem",
+ "multimediaviewer-restriction-insignia": "See pilt sisaldab ametlikku märki, mille suhtes võivad kohalduda õiguslikud piirangud.",
+ "multimediaviewer-restriction-personality": "Sellel pildil on kujutatud isikuid, kellel võivad olla õigused, mis piiravad õiguslikult pildi nõusolekuta edasikasutust.",
+ "multimediaviewer-restriction-trademarked": "Sellel pildil on elemente, mille suhtes võidakse kohaldada kaubamärgiseadusi.",
+ "multimediaviewer-restriction-default": "Selle pildi kasutus võib olla piiratud õiguslike sätetega, mis ei tulene autoriõiguse seadusest. Üksikasjade kohta vaata pildi kirjeldusleheküljelt.",
+ "multimediaviewer-restriction-default-and-others": "Selle pildi kasutust võivad piirata ka õiguslikud sätted, mis ei tulene autoriõiguse seadusest. Üksikasjade kohta vaata pildi kirjeldusleheküljelt.",
+ "multimediaviewer-about-mmv": "Teave",
+ "multimediaviewer-discuss-mmv": "arutelu",
+ "multimediaviewer-help-mmv": "abi",
+ "multimediaviewer-optout-mmv": "Keela failivaatur",
+ "multimediaviewer-optin-mmv": "Luba failivaatur",
+ "multimediaviewer-optout-pending-mmv": "Failivaaturi keelamine...",
+ "multimediaviewer-optin-pending-mmv": "Failivaaturi lubamine...",
+ "multimediaviewer-optout-help": "Piltide näitamiseks ei kasutata enam failivaaturit. Et seda uuesti kasutada, klõpsa ükskõik millise pildi juures nuppu \"{{int:Multimediaviewer-view-expanded}}\". Seejärel klõpsa \"{{int:Multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Piltide näitamiseks kasutatakse edaspidi failivaaturit.",
+ "multimediaviewer-geolocation": "Asukoht: $1",
+ "multimediaviewer-reuse-link": "Jaga või kasuta seda faili",
+ "multimediaviewer-reuse-loading-placeholder": "Laadimine...",
+ "multimediaviewer-reuse-copy-share": "Vali ja kopeeri link, et faili jagada (ei tööta mõnes brauseris)",
+ "multimediaviewer-reuse-copy-embed": "Vali ja kopeeri kood, et fail manustada (ei tööta mõnes brauseris)",
+ "multimediaviewer-share-tab": "Jagamine",
+ "multimediaviewer-embed-tab": "Manustamine",
+ "multimediaviewer-download-link": "Allalaadimine",
+ "multimediaviewer-download-preview-link-title": "Vaata brauseris",
+ "multimediaviewer-download-original-button-name": "Laadi alla algsuuruses",
+ "multimediaviewer-download-small-button-name": "Laadi alla väike pilt",
+ "multimediaviewer-download-medium-button-name": "Laadi alla keskmises suuruses",
+ "multimediaviewer-download-large-button-name": "Laadi alla suur pilt",
+ "multimediaviewer-link-to-page": "Link faili kirjelduslehele",
+ "multimediaviewer-link-to-file": "Link algse faili juurde",
+ "multimediaviewer-share-explanation": "Kopeeri ja jaga vabalt seda linki.",
+ "multimediaviewer-embed-wt": "Vikitekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Kasuta seda koodi, et fail manustada.",
+ "multimediaviewer-text-embed-credit-text-bl": "$1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "$1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "$1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "$1, $2",
+ "multimediaviewer-embed-byline": "Autor: $1",
+ "multimediaviewer-embed-license": "Avaldatud litsentsi $1 all.",
+ "multimediaviewer-embed-via": "Avaldatud saidil $1.",
+ "multimediaviewer-default-embed-dimensions": "Pisipildi vaikesuurus",
+ "multimediaviewer-original-embed-dimensions": "Algsuurus $1",
+ "multimediaviewer-large-embed-dimensions": "Suur $1",
+ "multimediaviewer-medium-embed-dimensions": "Keskmine $1",
+ "multimediaviewer-small-embed-dimensions": "Väike $1",
+ "multimediaviewer-embed-dimensions-separated": "– $1",
+ "multimediaviewer-description-page-button-text": "Veel üksikasju selle faili kohta",
+ "multimediaviewer-description-page-popup-text": "Veel üksikasju selle faili kohta asukohas $1",
+ "multimediaviewer-commons-subtitle": "Vabade meediafailide varamu",
+ "multimediaviewer-view-expanded": "Ava failivaaturis",
+ "multimediaviewer-view-config": "Häälestus",
+ "multimediaviewer-close-popup-text": "Sule see tööriist (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Näita täisekraanil",
+ "multimediaviewer-defullscreen-popup-text": "Sule täisekraan",
+ "multimediaviewer-next-image-alt-text": "Näita järgmist pilti",
+ "multimediaviewer-prev-image-alt-text": "Näita eelmist pilti",
+ "multimediaviewer-title-popup-text": "Kirjeldus",
+ "multimediaviewer-credit-popup-text": "Autori- ja allikateave",
+ "multimediaviewer-title-popup-text-more": "Vaata kogu kirjeldust",
+ "multimediaviewer-credit-popup-text-more": "Vaata kogu autori- ja allikateavet",
+ "multimediaviewer-download-attribution-cta-header": "Sul tuleb viidata autorile",
+ "multimediaviewer-download-optional-attribution-cta-header": "Saad autorile viidata",
+ "multimediaviewer-download-attribution-cta": "Näita, kuidas",
+ "multimediaviewer-download-attribution-copy": "Vali ja kopeeri tekst, millega fail autorile omistada (ei tööta mõnes brauseris)",
+ "multimediaviewer-attr-plain": "Lihttekst",
+ "multimediaviewer-options-tooltip": "Luba või keela failivaatur",
+ "multimediaviewer-options-dialog-header": "Kas keelad failivaaturi?",
+ "multimediaviewer-options-text-header": "Seda vaaturit ei kasutata siis ühegi faili juures.",
+ "multimediaviewer-options-text-body": "Saad faili üksikasjade leheküljel selle hiljem lubada.",
+ "multimediaviewer-options-learn-more": "Lisateave",
+ "multimediaviewer-option-submit-button": "Keela failivaatur",
+ "multimediaviewer-option-cancel-button": "Loobu",
+ "multimediaviewer-disable-confirmation-header": "Oled failivaaturi keelanud",
+ "multimediaviewer-disable-confirmation-text": "Järgmine kord, kui võrgukohas $1 pisipildil klõpsad, näed kohe kõiki faili üksikasju.",
+ "multimediaviewer-enable-dialog-header": "Kas lubad failivaaturi?",
+ "multimediaviewer-enable-text-header": "Saad kõigi failide juures vaikimisi seda vaaturit kasutada.",
+ "multimediaviewer-enable-submit-button": "Luba failivaatur",
+ "multimediaviewer-enable-confirmation-header": "Oled failivaaturi kõigi failide jaoks sisse lülitanud.",
+ "multimediaviewer-enable-confirmation-text": "Järgmine kord, kui võrgukohas $1 pisipildil klõpsad, kasutatakse failivaaturit.",
+ "multimediaviewer-enable-alert": "Failivaatur on praegu keelatud",
+ "multimediaviewer-disable-info-title": "Oled failivaaturi keelanud",
+ "multimediaviewer-disable-info": "Saad endiselt iga üksikut pilti failivaaturiga vaadata."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/eu.json b/www/wiki/extensions/MultimediaViewer/i18n/eu.json
new file mode 100644
index 00000000..e5efdf42
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/eu.json
@@ -0,0 +1,28 @@
+{
+ "@metadata": {
+ "authors": [
+ "Subi",
+ "Sator"
+ ]
+ },
+ "multimediaviewer-repository-local": "Xehetasun gehiago",
+ "multimediaviewer-credit-fallback": "Egileari buruzko informazioa ikusi",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|egile bat gehiago|$1 egile gehiago}}",
+ "multimediaviewer-multiple-authors-combine": "$1 eta $2",
+ "multimediaviewer-thumbnail-error-retry": "saiatu berriro",
+ "multimediaviewer-license-cc-pd": "Jabetza Publikoa",
+ "multimediaviewer-license-pd": "Jabetza Publikoa",
+ "multimediaviewer-license-default": "Lizentzia ikusi",
+ "multimediaviewer-permission-title": "Baimenaren xehetasunak",
+ "multimediaviewer-permission-link": "ikusi baldintzak",
+ "multimediaviewer-permission-link-hide": "ezkutatu baldintzak",
+ "multimediaviewer-permission-viewmore": "Ikusi gehiago",
+ "multimediaviewer-help-mmv": "Laguntza",
+ "multimediaviewer-reuse-loading-placeholder": "Kargatzen...",
+ "multimediaviewer-download-preview-link-title": "Nabigatzailean ikusi",
+ "multimediaviewer-html-embed-credit-link-text": "Lotura",
+ "multimediaviewer-view-expanded": "Media Viewerren ireki",
+ "multimediaviewer-download-attribution-cta": "Erakuts iezadazu nola",
+ "multimediaviewer-options-learn-more": "Gehiago ikasi",
+ "multimediaviewer-option-cancel-button": "Utzi"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/fa.json b/www/wiki/extensions/MultimediaViewer/i18n/fa.json
new file mode 100644
index 00000000..d58e1107
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/fa.json
@@ -0,0 +1,126 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armin1392",
+ "Ebraminio",
+ "Mcuteangel",
+ "Omidh",
+ "Reza1615",
+ "Omid.koli",
+ "Alirezaaa",
+ "Macofe",
+ "Ladsgroup"
+ ]
+ },
+ "multimediaviewer-desc": "تصاویر بندانگشتی در اندازهٔ بزرگ‌تر داخل یک رابط کاربری تمام‌صفحه گسترش یابند.",
+ "multimediaviewer-pref": "نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-pref-desc": "تجربهٔ بازدید چندرسانه‌ای شما با این ابزار جدید بهبود می‌یابد و تصاویر را در اندازهٔ بزرگتر در صفحه‌هایی که تصویر بندانگشتی دارند نمایش می‌دهد. تصاویر در پوشش سبک زیباتری نمایش داده می‌شوند و همچنین می‌توانند در اندازهٔ اصلی نمایش داده شوند.",
+ "multimediaviewer-optin-pref": "فعال کردن <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About نمایشگر رسانه‌ای]</span>",
+ "multimediaviewer-file-page": "رفتن به صفحهٔ مرتبط با پرونده",
+ "multimediaviewer-repository-local": "جزئیات بیشتر",
+ "multimediaviewer-datetime-created": "ایجادشده: $1",
+ "multimediaviewer-datetime-uploaded": "بارگذاری‌شده: $1",
+ "multimediaviewer-credit-fallback": "مشاهدهٔ اطلاعات نویسنده",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|یک نویسنده بیشتر|$1 نویسنده بیشتر}}",
+ "multimediaviewer-multiple-authors-combine": "$1 و $2",
+ "multimediaviewer-metadata-error": "نمی‌توان جزئیات تصویر را بارگیری کرد (خطا: $1)",
+ "multimediaviewer-thumbnail-error": "متأسفیم، پرونده نمی‌تواند نمایش یابد",
+ "multimediaviewer-thumbnail-error-description": "به نظر می‌رسد مشکل فنی وجود داشته‌باشد. شما می‌توانید $1 یا $3 اگر همچنان ادامه دارد. خطا: $2",
+ "multimediaviewer-thumbnail-error-retry": "تلاش دوباره",
+ "multimediaviewer-thumbnail-error-report": "مشکل را گزارش دهید",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-pd": "مالکیت عمومی",
+ "multimediaviewer-license-pd": "مالکیت عمومی",
+ "multimediaviewer-license-default": "مشاهده پروانه",
+ "multimediaviewer-permission-title": "جزئیات اجازه‌نامه",
+ "multimediaviewer-permission-link": "مشاهدهٔ شرایط",
+ "multimediaviewer-permission-link-hide": "پنهان‌سازی شرایط",
+ "multimediaviewer-permission-viewmore": "مشاهدهٔ بیشتر",
+ "multimediaviewer-restriction-2257": "این تصویر دارای محتوای جنسی است که ممکن است توسط قوانین حمایت از کودک منع شده‌باشد.",
+ "multimediaviewer-restriction-trademarked": "این تصویر شامل محتوایی است که ممکن است تحت قوانین علامت تجاری باشد.",
+ "multimediaviewer-about-mmv": "درباره",
+ "multimediaviewer-discuss-mmv": "بحث",
+ "multimediaviewer-help-mmv": "کمک",
+ "multimediaviewer-optout-mmv": "غیرفعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-optin-mmv": "فعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-optout-pending-mmv": "غیرفعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-optin-pending-mmv": "فعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-optout-help": "نمایش‌دهندهٔ رسانه دیگر برای نمایش تصاویر استفاده نخواهد شد. برای استفادهٔ دوباره از آن، روی دکمهٔ «{{int:multimediaviewer-view-expanded}}» کنار هر تصویر کلیک کنید. سپس روی «{{int:multimediaviewer-optin-mmv}}» کلیک کنید.",
+ "multimediaviewer-optin-help": "نمایشگر رسانه برای نمایش تصاویر استفاده خواهد شد.",
+ "multimediaviewer-geoloc-north": "نو",
+ "multimediaviewer-geoloc-east": "شرق",
+ "multimediaviewer-geoloc-south": "S",
+ "multimediaviewer-geoloc-west": "غرب",
+ "multimediaviewer-geoloc-coords": "$1، $2",
+ "multimediaviewer-geolocation": "مکان: $1",
+ "multimediaviewer-reuse-link": "این پرونده را به اشتراک بگذارید یا جاسازی کنید",
+ "multimediaviewer-reuse-loading-placeholder": "در حال بارگیری...",
+ "multimediaviewer-share-tab": "اشتراک‌گذاری",
+ "multimediaviewer-embed-tab": "جاسازی‌کردن",
+ "multimediaviewer-download-link": "دریافت این پرونده",
+ "multimediaviewer-download-preview-link-title": "مشاهده در مرورگر",
+ "multimediaviewer-download-original-button-name": "دریافت پروندهٔ اصلی",
+ "multimediaviewer-download-small-button-name": "دریافت اندازهٔ کوچک",
+ "multimediaviewer-download-medium-button-name": "دریافت اندازهٔ متوسط",
+ "multimediaviewer-download-large-button-name": "دریافت اندازهٔ بزرگ",
+ "multimediaviewer-link-to-page": "پیوند به صفحهٔ توضیحات پرونده",
+ "multimediaviewer-link-to-file": "پیوند به پروندهٔ اصلی",
+ "multimediaviewer-share-explanation": "نسخه بردارید و به آزادی پیوند را به اشتراک بگذارید",
+ "multimediaviewer-embed-wt": "ویکی‌متن",
+ "multimediaviewer-embed-html": "اچ‌تی‌ام‌ال",
+ "multimediaviewer-embed-explanation": "از این کد برای جاسازی‌کردن پرونده استفاده کنید",
+ "multimediaviewer-text-embed-credit-text-bl": "توسط $1، $2، $3",
+ "multimediaviewer-text-embed-credit-text-b": "توسط $1، $2",
+ "multimediaviewer-text-embed-credit-text-l": "$1، $2",
+ "multimediaviewer-html-embed-credit-text-bl": "توسط $1، $2، $3",
+ "multimediaviewer-html-embed-credit-text-b": "توسط $1، $2",
+ "multimediaviewer-html-embed-credit-text-l": "$1، $2",
+ "multimediaviewer-html-embed-credit-link-text": "پیوند",
+ "multimediaviewer-embed-byline": "توسط $1",
+ "multimediaviewer-embed-license": "تحت پروانهٔ $1.",
+ "multimediaviewer-embed-via": "به وسیلهٔ $1.",
+ "multimediaviewer-default-embed-dimensions": "اندازهٔ تصویر بندانگشتی پیش‌فرض",
+ "multimediaviewer-original-embed-dimensions": "پروندهٔ اصلی $1",
+ "multimediaviewer-large-embed-dimensions": "بزرگ $1",
+ "multimediaviewer-medium-embed-dimensions": "متوسط $1",
+ "multimediaviewer-small-embed-dimensions": "کوچک $1",
+ "multimediaviewer-description-page-button-text": "اطلاعات بیشتر دربارهٔ این پرونده",
+ "multimediaviewer-description-page-popup-text": "اطلاعات بیشتر دربارهٔ این پرونده در $1",
+ "multimediaviewer-commons-subtitle": "مخزن آزاد رسانه",
+ "multimediaviewer-view-expanded": "باز کردن در نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-view-config": "پیکربندی",
+ "multimediaviewer-close-popup-text": "این ابزار را ببند (Ecs)",
+ "multimediaviewer-fullscreen-popup-text": "نمایش در تمام‌صفحه",
+ "multimediaviewer-defullscreen-popup-text": "خروج از تمام‌صفحه",
+ "multimediaviewer-title-popup-text": "توضیحات",
+ "multimediaviewer-credit-popup-text": "اطلاعات منبع و نویسنده",
+ "multimediaviewer-title-popup-text-more": "مشاهدهٔ کامل توضیحات",
+ "multimediaviewer-credit-popup-text-more": "مشاهدهٔ کامل منبع و نویسنده",
+ "multimediaviewer-download-attribution-cta-header": "شما باید به نویسنده نسبت دهید",
+ "multimediaviewer-download-optional-attribution-cta-header": "شما می‌توانید به نویسنده نسبت دهید",
+ "multimediaviewer-download-attribution-cta": "به‌ من نشان بده چگونه",
+ "multimediaviewer-attr-plain": "ساده",
+ "multimediaviewer-attr-html": "HTML",
+ "multimediaviewer-options-tooltip": "فعال یا غیرفعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-options-dialog-header": "نمایش‌دهندهٔ رسانه را غیرفعال می‌کنید؟",
+ "multimediaviewer-options-text-header": "این قابلیت مشاهدهٔ همهٔ پرونده‌ها را رد کنید.",
+ "multimediaviewer-options-text-body": "شما می‌توانید آن را بعداً از طریق صفحهٔ جزئیات پرونده فعال کنید.",
+ "multimediaviewer-options-learn-more": "بیشتر بدانید",
+ "multimediaviewer-option-submit-button": "غیرفعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-option-cancel-button": "لغو",
+ "multimediaviewer-disable-confirmation-header": "شما نمایش‌دهندهٔ رسانه را غیرفعال کردید",
+ "multimediaviewer-disable-confirmation-text": "دفعهٔ بعد که روی تصویر بندانگشتی در $1 کلیک می‌کنید، به طور مستقیم جزئیات همهٔ پرونده‌ها را می‌بینید.",
+ "multimediaviewer-enable-dialog-header": "نمایش‌دهندهٔ رسانه را فعال می‌کنید؟",
+ "multimediaviewer-enable-text-header": "این قابلیت مشاهدهٔ رسانه را برای همهٔ پرونده‌ها به صورت پیش‌فرض فعال کنید.",
+ "multimediaviewer-enable-submit-button": "فعال‌ساختن نمایش‌دهندهٔ رسانه",
+ "multimediaviewer-enable-confirmation-header": "شما نمایش‌دهندهٔ رسانه را برای همهٔ پرونده‌ها فعال کردید",
+ "multimediaviewer-enable-confirmation-text": "دفعهٔ بعد که روی تصویر بندانگشتی در $1 کلیک می‌کنید، نمایش‌دهندهٔ رسانه استفاده خواهد شد.",
+ "multimediaviewer-enable-alert": "نمایش‌دهندهٔ رسانه اکنون غیرفعال است",
+ "multimediaviewer-disable-info-title": "شما نمایش‌دهندهٔ رسانه را غیرفعال کردید",
+ "multimediaviewer-disable-info": "شما هنوز می‌توانید پرونده‌های منحصربه‌فرد را با نمایش‌دهندهٔ رسانه مشاهده کنید."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/fi.json b/www/wiki/extensions/MultimediaViewer/i18n/fi.json
new file mode 100644
index 00000000..2585a8aa
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/fi.json
@@ -0,0 +1,87 @@
+{
+ "@metadata": {
+ "authors": [
+ "Elseweyr",
+ "Nike",
+ "Stryn",
+ "ElmA",
+ "Pxos",
+ "MrTapsa",
+ "McSalama",
+ "Pyscowicz",
+ "Pahkiqaz"
+ ]
+ },
+ "multimediaviewer-desc": "Näytä pienoiskuvat suuremmassa koossa kokoruututilassa.",
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-pref-desc": "Paranna multimedian katselukokemustasi tällä uudella työkalulla. Se näyttää kuvat suuremmassa koossa sivuilla, joissa on kuvakkeita. Kuvat aukeavat suuremmassa koossa kokoruututilassa, ja ne voidaan näyttää myös täysikokoisina.",
+ "multimediaviewer-optin-pref": "Ota käyttöön <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Siirry tiedoston omalle sivulle",
+ "multimediaviewer-repository-local": "Lisätiedot",
+ "multimediaviewer-datetime-created": "Luotu: $1",
+ "multimediaviewer-datetime-uploaded": "Tallennettu: $1",
+ "multimediaviewer-credit-fallback": "Näytä tekijätiedot",
+ "multimediaviewer-multiple-authors-combine": "$1 ja $2",
+ "multimediaviewer-metadata-error": "Kuvan tietoja ei voitu ladata (virhe: $1)",
+ "multimediaviewer-thumbnail-error": "Pahoittelut, tiedostoa ei voi näyttää",
+ "multimediaviewer-license-cc-pd": "Public Domain",
+ "multimediaviewer-license-pd": "Public Domain",
+ "multimediaviewer-license-default": "Näytä lisenssi",
+ "multimediaviewer-permission-title": "Lisenssitiedot",
+ "multimediaviewer-permission-link": "katso käyttöehdot",
+ "multimediaviewer-permission-link-hide": "piilota termit",
+ "multimediaviewer-permission-viewmore": "Näytä lisää",
+ "multimediaviewer-about-mmv": "Tietoa",
+ "multimediaviewer-discuss-mmv": "Keskustelu",
+ "multimediaviewer-help-mmv": "Ohje",
+ "multimediaviewer-optout-mmv": "Ota Media Viewer pois käytöstä",
+ "multimediaviewer-optin-mmv": "Ota Media Viewer käyttöön",
+ "multimediaviewer-optout-pending-mmv": "Otetaan Media Viewer pois käytöstä",
+ "multimediaviewer-optin-pending-mmv": "Otetaan Media Viewer käyttöön",
+ "multimediaviewer-geolocation": "Sijainti: $1",
+ "multimediaviewer-reuse-link": "Jaa tai upota tämä tiedosto",
+ "multimediaviewer-reuse-loading-placeholder": "Ladataan…",
+ "multimediaviewer-share-tab": "Jaa",
+ "multimediaviewer-embed-tab": "Upota",
+ "multimediaviewer-download-link": "Lataa tämä tiedosto",
+ "multimediaviewer-download-preview-link-title": "Näytä selaimessa",
+ "multimediaviewer-download-original-button-name": "Lataa alkuperäinen tiedosto",
+ "multimediaviewer-download-small-button-name": "Lataa pienikokoisena",
+ "multimediaviewer-download-medium-button-name": "Lataa keskikokoisena",
+ "multimediaviewer-download-large-button-name": "Lataa suurikokoisena",
+ "multimediaviewer-link-to-page": "Linkki tiedoston kuvaussivulle",
+ "multimediaviewer-link-to-file": "Linkki alkuperäiseen tiedostoon",
+ "multimediaviewer-share-explanation": "Kopioi linkki ja levitä sitä vapaasti",
+ "multimediaviewer-embed-wt": "Wikiteksti",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Käytä tätä koodia tiedoston sijoittamiseksi kohteeseen",
+ "multimediaviewer-html-embed-credit-link-text": "Linkki",
+ "multimediaviewer-embed-byline": "Tekijä on $1",
+ "multimediaviewer-embed-license": "Lisensoitu lisenssillä $1.",
+ "multimediaviewer-default-embed-dimensions": "Pienoiskuvien oletuskoko",
+ "multimediaviewer-original-embed-dimensions": "Alkuperäinen tiedosto $1",
+ "multimediaviewer-large-embed-dimensions": "Suuri $1",
+ "multimediaviewer-medium-embed-dimensions": "Keskikokoinen $1",
+ "multimediaviewer-small-embed-dimensions": "Pieni $1",
+ "multimediaviewer-description-page-button-text": "Lisätietoa tästä tiedostosta",
+ "multimediaviewer-description-page-popup-text": "Lisätietoa tästä tiedostosta sivulla $1",
+ "multimediaviewer-commons-subtitle": "Vapaan mediasisällön tietokanta",
+ "multimediaviewer-view-expanded": "Avaa Media Viewerissä",
+ "multimediaviewer-view-config": "Asetukset",
+ "multimediaviewer-close-popup-text": "Sulje tämä työkalu (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Näytä koko näytössä",
+ "multimediaviewer-defullscreen-popup-text": "Poistu koko näytön tilasta",
+ "multimediaviewer-next-image-alt-text": "Näytä seuraava kuva",
+ "multimediaviewer-prev-image-alt-text": "Näytä edellinen kuva",
+ "multimediaviewer-title-popup-text": "Kuvaus",
+ "multimediaviewer-title-popup-text-more": "Näytä koko kuvaus",
+ "multimediaviewer-download-attribution-cta": "Näytä kuinka",
+ "multimediaviewer-reuse-warning-nonfree": "Tiedosto ei ole vapaasti lisensoitu.",
+ "multimediaviewer-options-learn-more": "Lue lisää",
+ "multimediaviewer-option-cancel-button": "Peru",
+ "multimediaviewer-enable-dialog-header": "Ota Media Viewer käyttöön?",
+ "multimediaviewer-enable-submit-button": "Ota Media Viewer käyttöön",
+ "multimediaviewer-enable-alert": "Media Viewer on nyt poistettu käytöstä",
+ "multimediaviewer-disable-info-title": "Olet poistanut Media Viewerin käytöstä",
+ "multimediaviewer-disable-info": "Voit silti tarkastella yksittäisiä tiedostoja Media Viewerillä."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/fr.json b/www/wiki/extensions/MultimediaViewer/i18n/fr.json
new file mode 100644
index 00000000..d593bed6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/fr.json
@@ -0,0 +1,142 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gomoko",
+ "Jean-Frédéric",
+ "Ltrlg",
+ "NemesisIII",
+ "Verdy p",
+ "Sherbrooke",
+ "Seb35",
+ "Macofe",
+ "Windes",
+ "0x010C",
+ "Orikrin1998",
+ "Weft",
+ "Wladek92",
+ "Urhixidur"
+ ]
+ },
+ "multimediaviewer-desc": "Agrandit les vignettes dans une interface en plein écran",
+ "multimediaviewer-pref": "Visionneuse de Médias",
+ "multimediaviewer-pref-desc": "Améliorez votre expérience de visualisation multimédia avec ce nouvel outil. Il affiche les images en grande taille sur les pages qui ont des vignettes. Les images sont affichées dans un joli cadre d’interface en plein écran, et peuvent aussi être affichées en taille maximale.",
+ "multimediaviewer-optin-pref": "Activer <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About la visionneuse de médias]</span>",
+ "multimediaviewer-file-page": "Aller à la page du fichier correspondant",
+ "multimediaviewer-repository-local": "Plus de détails",
+ "multimediaviewer-datetime-created": "Création : $1",
+ "multimediaviewer-datetime-uploaded": "Téléversé : $1",
+ "multimediaviewer-credit": "$1 — $2",
+ "multimediaviewer-credit-fallback": "Voir les informations sur l’auteur",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|un auteur supplémentaire|$1 auteurs supplémentaire}}",
+ "multimediaviewer-multiple-authors-combine": "$1 et $2",
+ "multimediaviewer-metadata-error": "Impossible de charger les données de l’image. (erreur : $1)",
+ "multimediaviewer-thumbnail-error": "Désolé, le fichier ne peut être chargé.",
+ "multimediaviewer-thumbnail-error-description": "Il semble y avoir un problème technique. Vous pouvez $1 ou $3 s'il persiste. Erreur : $2",
+ "multimediaviewer-thumbnail-error-retry": "réessayer",
+ "multimediaviewer-thumbnail-error-report": "signaler le problème",
+ "multimediaviewer-license-cc-pd": "Domaine public",
+ "multimediaviewer-license-pd": "Domaine public",
+ "multimediaviewer-license-default": "Afficher la licence",
+ "multimediaviewer-permission-title": "Détails de la licence",
+ "multimediaviewer-permission-link": "afficher les conditions",
+ "multimediaviewer-permission-link-hide": "masquer les conditions",
+ "multimediaviewer-permission-viewmore": "Voir plus",
+ "multimediaviewer-restriction-2257": "Cette image contient du contenu sexuellement explicite, qui peut être assujettie à la loi de Protection de l'Enfant et la lutte contre l'Obscénité aux États-unis.",
+ "multimediaviewer-restriction-aus-reserve": "Cette image a été prise dans une réserve du Commonwealth australien et ne peut pas être utilisée à des fins commerciales sans autorisation.",
+ "multimediaviewer-restriction-communist": "Cette image contient des insignes communistes qui peuvent être interdits dans certains pays.",
+ "multimediaviewer-restriction-costume": "Cette image dépeint des costumes et peut être soumise à des restrictions légales.",
+ "multimediaviewer-restriction-currency": "Cette image représente la description d'une unité de monnaie et peut être soumise à des restrictions légales.",
+ "multimediaviewer-restriction-design": "La conception du sujet de cette image peut être protégée et soumise à des restrictions légales.",
+ "multimediaviewer-restriction-fan-art": "Cette image est un travail de fan art, et sa réutilisation peut être soumise à des restrictions légales.",
+ "multimediaviewer-restriction-ihl": "Cette image contient des symboles restreints par le Droit International Humanitaire.",
+ "multimediaviewer-restriction-insignia": "Cette image contient des insignes officiels qui peuvent être soumis à des restrictions légales.",
+ "multimediaviewer-restriction-ita-mibac": "Cette image reproduit une propriété appartenant au patrimoine culturel italien et est limitée par la loi italienne.",
+ "multimediaviewer-restriction-nazi": "Cette image contient des insignes nazi ou fascistes qui peuvent être interdits dans certains pays.",
+ "multimediaviewer-restriction-personality": "Cette image contient des personnes qui peuvent avoir des droits qui légalement restreignent certaines réutilisations de l'image sans leur consentement.",
+ "multimediaviewer-restriction-trademarked": "Cette image contient du contenu qui peut être soumis au droit des marques.",
+ "multimediaviewer-restriction-default": "Cette image peut être limitée par des dispositions légales extérieures au droit d'auteur. Voir la page de description du fichier pour les détails.",
+ "multimediaviewer-restriction-default-and-others": "Cette image peut être en outre limitée par d'autres dispositions légales en dehors du droit d'auteur. Voir la page de description du fichier pour les détails.",
+ "multimediaviewer-about-mmv": "À propos",
+ "multimediaviewer-discuss-mmv": "Discussion",
+ "multimediaviewer-help-mmv": "Aide",
+ "multimediaviewer-optout-mmv": "Désactiver la visionneuse de médias",
+ "multimediaviewer-optin-mmv": "Activer la visionneuse de médias",
+ "multimediaviewer-optout-pending-mmv": "Désactiver la visionneuse de médias",
+ "multimediaviewer-optin-pending-mmv": "Activation de la visionneuse de médias",
+ "multimediaviewer-optout-help": "La visionneuse de média ne sera plus utilisée pour afficher les images. Pour l’utiliser de nouveau, cliquez sur le bouton « {{int:multimediaviewer-view-expanded}} » près d’une image. Puis cliquez sur « {{int:multimediaviewer-optin-mmv}} ».",
+ "multimediaviewer-optin-help": "La visionneuse de média sera utilisée pour afficher les images.",
+ "multimediaviewer-geolocation": "Emplacement : $1",
+ "multimediaviewer-reuse-link": "Partager ou inclure ce fichier",
+ "multimediaviewer-reuse-loading-placeholder": "Chargement en cours…",
+ "multimediaviewer-reuse-copy-share": "Sélectionner et copier (si c’est pris en charge) le lien pour partager ce fichier",
+ "multimediaviewer-reuse-copy-embed": "Sélectionner et copier (si c’est pris en charge) le code pour inclure ce fichier",
+ "multimediaviewer-share-tab": "Partager",
+ "multimediaviewer-embed-tab": "Intégrer",
+ "multimediaviewer-download-link": "Télécharger ce fichier",
+ "multimediaviewer-download-preview-link-title": "Afficher dans le navigateur",
+ "multimediaviewer-download-original-button-name": "Télécharger le fichier d’origine",
+ "multimediaviewer-download-small-button-name": "Télécharger en petite taille",
+ "multimediaviewer-download-medium-button-name": "Télécharger en taille moyenne",
+ "multimediaviewer-download-large-button-name": "Télécharger en grande taille",
+ "multimediaviewer-link-to-page": "Lien vers la page de description du fichier",
+ "multimediaviewer-link-to-file": "Lien vers le fichier d’origine",
+ "multimediaviewer-share-explanation": "Copier et partager librement le lien",
+ "multimediaviewer-embed-wt": "Wikitexte",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Utiliser ce code pour intégrer le fichier",
+ "multimediaviewer-text-embed-credit-text-bl": "Par $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Par $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Par $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Par $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Lien",
+ "multimediaviewer-embed-byline": "Par $1",
+ "multimediaviewer-embed-license": "Sous licence $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Taille de vignette par défaut",
+ "multimediaviewer-original-embed-dimensions": "Fichier d’origine $1",
+ "multimediaviewer-large-embed-dimensions": "Grand $1",
+ "multimediaviewer-medium-embed-dimensions": "Moyen $1",
+ "multimediaviewer-small-embed-dimensions": "Petit $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 px",
+ "multimediaviewer-description-page-button-text": "Plus de détails sur ce fichier",
+ "multimediaviewer-description-page-popup-text": "Plus de détails sur ce fichier en $1",
+ "multimediaviewer-commons-subtitle": "La médiathèque libre",
+ "multimediaviewer-view-expanded": "Ouvrir dans le Visualiseur de médias",
+ "multimediaviewer-view-config": "Configuration",
+ "multimediaviewer-close-popup-text": "Fermer cet outil (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Afficher en plein écran",
+ "multimediaviewer-defullscreen-popup-text": "Sortir du plein écran",
+ "multimediaviewer-next-image-alt-text": "Afficher la prochaine image",
+ "multimediaviewer-prev-image-alt-text": "Afficher l'image précédente",
+ "multimediaviewer-title-popup-text": "Description",
+ "multimediaviewer-credit-popup-text": "Auteur et source de l’information",
+ "multimediaviewer-title-popup-text-more": "Afficher la description complète",
+ "multimediaviewer-credit-popup-text-more": "Afficher au complet l’auteur et la source",
+ "multimediaviewer-download-attribution-cta-header": "Vous devez attribuer l’auteur",
+ "multimediaviewer-download-optional-attribution-cta-header": "Vous pouvez attribuer l'auteur",
+ "multimediaviewer-download-attribution-cta": "Me montrer comment",
+ "multimediaviewer-download-attribution-copy": "Sélectionner et copier (si pris en charge) le texte d'attribution pour ce fichier",
+ "multimediaviewer-reuse-warning-deletion": "Ce fichier est considéré comme à détruire.",
+ "multimediaviewer-reuse-warning-nonfree": "Ce fichier ne possède pas la licence libre.",
+ "multimediaviewer-reuse-warning-noattribution": "Ce fichier n'a pas d'information d'attribution.",
+ "multimediaviewer-reuse-warning-generic": "Vérifier [$1 ses détails] avant de l'utiliser.",
+ "multimediaviewer-attr-plain": "Simple",
+ "multimediaviewer-options-tooltip": "Activer ou désactiver la visionneuse de médias",
+ "multimediaviewer-options-dialog-header": "Désactiver la visionneuse de médias",
+ "multimediaviewer-options-text-header": "Ignorer cette fonctionnalité de visualisation pour tous les fichiers.",
+ "multimediaviewer-options-text-body": "Vous pourrez l'activer plus tard à partir de la page de détails des fichiers.",
+ "multimediaviewer-options-learn-more": "En savoir plus",
+ "multimediaviewer-option-submit-button": "Désactiver la visionneuse de médias",
+ "multimediaviewer-option-cancel-button": "Annuler",
+ "multimediaviewer-disable-confirmation-header": "Vous avez désactivé la visionneuse de médias",
+ "multimediaviewer-disable-confirmation-text": "La prochaine fois que vous cliquerez sur une vignette sur $1, vous verrez directement la page complète d'information sur le fichier.",
+ "multimediaviewer-enable-dialog-header": "Activer la visionneuse de médias ?",
+ "multimediaviewer-enable-text-header": "Activer cette fonctionnalité de visualisation pour l'ensemble des fichiers par défaut.",
+ "multimediaviewer-enable-submit-button": "Activer la visionneuse de médias",
+ "multimediaviewer-enable-confirmation-header": "Vous avez activé la visionneuse de médias pour tous les fichiers",
+ "multimediaviewer-enable-confirmation-text": "La prochaine fois que vous cliquerez sur une vignette sur $1, la visionneuse de médias sera utilisée.",
+ "multimediaviewer-enable-alert": "La visionneuse de médias est maintenant désactivée",
+ "multimediaviewer-disable-info-title": "Vous avez désactivé la visionneuse de médias",
+ "multimediaviewer-disable-info": "Vous pouvez toujours consulter des fichiers individuels avec la visionneuse de médias.",
+ "multimediaviewer-errorreport-privacywarning": "Les détails sur l’erreur sont attachés au rapport, qui sera visible publiquement. Si cela ne vous convient pas, vous pouvez modifier le rapport ci-dessous et supprimer toutes les données que vous ne voulez pas partager."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/frr.json b/www/wiki/extensions/MultimediaViewer/i18n/frr.json
new file mode 100644
index 00000000..0446b8c2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/frr.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Murma174"
+ ]
+ },
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-optin-pref": "Di <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About MediaViewer]</span> aktiwiare"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/fy.json b/www/wiki/extensions/MultimediaViewer/i18n/fy.json
new file mode 100644
index 00000000..3a6914d6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/fy.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
+ ]
+ },
+ "multimediaviewer-multiple-authors-combine": "$1 en $2",
+ "multimediaviewer-help-mmv": "Help",
+ "multimediaviewer-geolocation": "Lokaasje: $1",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-large-embed-dimensions": "Grut $1",
+ "multimediaviewer-small-embed-dimensions": "Lyts $1",
+ "multimediaviewer-title-popup-text": "Beskriuwing"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/gd.json b/www/wiki/extensions/MultimediaViewer/i18n/gd.json
new file mode 100644
index 00000000..825a4a1a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/gd.json
@@ -0,0 +1,123 @@
+{
+ "@metadata": {
+ "authors": [
+ "GunChleoc",
+ "Akerbeltz"
+ ]
+ },
+ "multimediaviewer-desc": "Thoir meud nas motha air dealbhagan air eadar-aghaidh làn-sgrìn.",
+ "multimediaviewer-pref": "Sealladair nam meadhanan",
+ "multimediaviewer-pref-desc": "Thoir piseach air sealladh air meadhanan leis an inneal ùr seo. Seallaidh e dealbhan as motha air duilleagan aig a bheil dealbhagan. Thèid dealbhan a shealltainn air tar-chòmhdachadh làn-sgrìn agus gabhaidh an sealltainn le làn-leud cuideachd.",
+ "multimediaviewer-optin-pref": "Cuir <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About sealladair nam headhanan]</span> an comas",
+ "multimediaviewer-file-page": "Rach gu dhuilleag an fhaidhle seo",
+ "multimediaviewer-repository-local": "Barrachd fiosrachaidh",
+ "multimediaviewer-datetime-created": "Air a chruthachadh: $1",
+ "multimediaviewer-datetime-uploaded": "Air a luchdadh suas: $1",
+ "multimediaviewer-credit": "$1 - $2",
+ "multimediaviewer-credit-fallback": "Seall fiosrachadh an ùghdair",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|$1 ùghdar eile|$1 ùghdar eile|$1 ùghdar eilean|$1 ùghdar eile}}",
+ "multimediaviewer-multiple-authors-combine": "$1 agus $2",
+ "multimediaviewer-metadata-error": "Cha deach leinn fiosrachadh an deilbh a luchdadh (mearachd: $1)",
+ "multimediaviewer-thumbnail-error": "Tha sinn duilich ach cha chan urrainn dhuinn am faidhle a shealltainn",
+ "multimediaviewer-thumbnail-error-description": "Tha coltas gu bheil duilgheadas teicnigeach ann. 'S urrainn dhut $1 no $3 ma mhaireas e. Mearachd: $2",
+ "multimediaviewer-thumbnail-error-retry": "feuchainn ris a-rithist",
+ "multimediaviewer-thumbnail-error-report": "aithris a dhèanamh air an duilgheadas",
+ "multimediaviewer-license-cc-by-1.0": "CC BY 1.0",
+ "multimediaviewer-license-cc-sa-1.0": "CC SA 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC BY 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Public Domain",
+ "multimediaviewer-license-cc-zero": "CC 0",
+ "multimediaviewer-license-pd": "Public Domain",
+ "multimediaviewer-license-default": "Seall an ceadachas",
+ "multimediaviewer-permission-title": "Fiosrachadh a' chead",
+ "multimediaviewer-permission-link": "seall na teirmichean",
+ "multimediaviewer-permission-link-hide": "falaich na teirmichean",
+ "multimediaviewer-permission-viewmore": "Seall barrachd",
+ "multimediaviewer-about-mmv": "Mu dhèidhinn",
+ "multimediaviewer-discuss-mmv": "Deasbaireachd",
+ "multimediaviewer-help-mmv": "Cobhair",
+ "multimediaviewer-optout-mmv": "Cuir sealladair nam meadhanan à comas",
+ "multimediaviewer-optin-mmv": "Cuir an Sealladair mheadhanan an comas",
+ "multimediaviewer-optout-pending-mmv": "A' cur sealladair nam meadhanan à comas",
+ "multimediaviewer-optin-pending-mmv": "A' cur an t-Sealladair mheadhanan an comas",
+ "multimediaviewer-optout-help": "Cha dèid sealladair nam meadhannan a chleachdadh tuilleadh gus dealbhan a shealltainn. Gus a chleachdadh a-rithist, briog air a' phutan \"{{int:multimediaviewer-view-expanded}}\" ri taobh dealbh sam bith. Briog air \"{{int:multimediaviewer-optin-mmv}}\" an uairsin.",
+ "multimediaviewer-optin-help": "Thèid an sealladair mheadhanan a chleachdadh gus dealbhan a shealltainn.",
+ "multimediaviewer-geoloc-north": "T",
+ "multimediaviewer-geoloc-east": "E",
+ "multimediaviewer-geoloc-south": "D",
+ "multimediaviewer-geoloc-west": "I",
+ "multimediaviewer-geoloc-coord": "$1° $2′ $3″ $4",
+ "multimediaviewer-geoloc-coords": "$1, $2",
+ "multimediaviewer-geolocation": "Ionad: $1",
+ "multimediaviewer-reuse-link": "Co-roinn no leabaich am faidhle seo",
+ "multimediaviewer-reuse-loading-placeholder": "'Ga luchdadh…",
+ "multimediaviewer-share-tab": "Co-roinn",
+ "multimediaviewer-embed-tab": "Leabaich",
+ "multimediaviewer-download-link": "Luchdaich a-nuas am faidhle seo",
+ "multimediaviewer-download-preview-link-title": "Seall sa bhrabhsair",
+ "multimediaviewer-download-original-button-name": "Luchdaich a-nuas am faidhle tùsail",
+ "multimediaviewer-download-small-button-name": "Luchdaich a-nuas le meud beag",
+ "multimediaviewer-download-medium-button-name": "Luchdaich a-nuas le meud meadhanach",
+ "multimediaviewer-download-large-button-name": "Luchdaich a-nuas le meud mòr",
+ "multimediaviewer-link-to-page": "Dèan ceangal ri duilleag mìneachadh an fhaidhle",
+ "multimediaviewer-link-to-file": "Dèan ceangal ris an fhaidhle tùsail",
+ "multimediaviewer-share-explanation": "Dèan lethbhreac 's co-roinn an ceangal gu saor",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Cleachd an còd seo gus am faidhle a leabachadh",
+ "multimediaviewer-text-embed-credit-text-bl": "Le $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "le $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Le $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Le $1, $2",
+ "multimediaviewer-embed-byline": "Le $1",
+ "multimediaviewer-embed-license": "Fo cheadachas $1.",
+ "multimediaviewer-embed-via": "Slighe $1.",
+ "multimediaviewer-default-embed-dimensions": "Meud bunaiteach na dealbhaige",
+ "multimediaviewer-original-embed-dimensions": "Am faidhle tùsail $1",
+ "multimediaviewer-large-embed-dimensions": "Mòr $1",
+ "multimediaviewer-medium-embed-dimensions": "Meadhanach $1",
+ "multimediaviewer-small-embed-dimensions": "Beag $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 px",
+ "multimediaviewer-embed-dimensions-separated": "- $1",
+ "multimediaviewer-description-page-button-text": "Barrachd fiosrachaidh air an fhaidhle seo",
+ "multimediaviewer-description-page-popup-text": "Barrachd fiosrachaidh air an fhaidhle seo air $1",
+ "multimediaviewer-commons-subtitle": "Ionad-tasgaidh mheadhanan saora",
+ "multimediaviewer-view-expanded": "Fosgail ann an sealladair nam meadhanan",
+ "multimediaviewer-view-config": "Rèiteachadh",
+ "multimediaviewer-close-popup-text": "Dùin an t-inneal seo (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Seall air làn-sgrìn",
+ "multimediaviewer-defullscreen-popup-text": "Fàg an làn-sgrìn",
+ "multimediaviewer-title-popup-text": "Tuairisgeul",
+ "multimediaviewer-credit-popup-text": "Fiosrachadh mun ùghdar 's tùs",
+ "multimediaviewer-title-popup-text-more": "Seall an tuairisgeul slàn",
+ "multimediaviewer-credit-popup-text-more": "Seall ùghdar is tùs slàn",
+ "multimediaviewer-download-attribution-cta-header": "Feumaidh tu urram a thoirt air an ùghdar",
+ "multimediaviewer-download-attribution-cta": "Seall dhomh ciamar",
+ "multimediaviewer-attr-plain": "Lom",
+ "multimediaviewer-attr-html": "HTML",
+ "multimediaviewer-options-tooltip": "Cuir sealladair nam meadhanan an comas no à comas",
+ "multimediaviewer-options-dialog-header": "A bheil thu airson an sealladair mheadhanan a chur à comas?",
+ "multimediaviewer-options-text-header": "Leig seachad am feart seallaidh seo airson a h-uile faidhle.",
+ "multimediaviewer-options-text-body": "'S urrainn dhut a chur an comas uair sam bith air duilleag fiosrachaidh an deilbh.",
+ "multimediaviewer-options-learn-more": "Barrachd fiosrachaidh",
+ "multimediaviewer-option-submit-button": "Cuir sealladair nam meadhanan à comas",
+ "multimediaviewer-option-cancel-button": "Sguir dheth",
+ "multimediaviewer-disable-confirmation-header": "Tha thu air sealladair nam meadhanan a chur à comas",
+ "multimediaviewer-disable-confirmation-text": "An ath-thuras a bhriogas tu air dealbhag air $1, chì thu fiosrachadh slàn air an fhaidhle sa bhad.",
+ "multimediaviewer-enable-dialog-header": "A bheil thu airson sealladair nam meadhanan a chur an comas?",
+ "multimediaviewer-enable-text-header": "Cuir am feart seo airson meadhanan a shealltainn an comas airson a h-uile faidhle a ghnàth.",
+ "multimediaviewer-enable-submit-button": "Cuir sealladair nam meadhanan an comas",
+ "multimediaviewer-enable-confirmation-text": "An ath thuras a bhriogas tu air dealbhag air $1, thèid sealladair nam meadhanan a chleachdadh.",
+ "multimediaviewer-disable-info-title": "Tha thu air sealladair nam meadhanan a chur à comas",
+ "multimediaviewer-disable-info": "'S urrainn dhut faidhlichean fa leth a shealltainn ann an sealladair nam meadhanan fhathast."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/gl.json b/www/wiki/extensions/MultimediaViewer/i18n/gl.json
new file mode 100644
index 00000000..2f339e33
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/gl.json
@@ -0,0 +1,131 @@
+{
+ "@metadata": {
+ "authors": [
+ "Toliño",
+ "Vivaelcelta",
+ "Elisardojm",
+ "Macofe",
+ "Banjo"
+ ]
+ },
+ "multimediaviewer-desc": "Expande as miniaturas ata un tamaño maior dentro dunha interface a pantalla completa.",
+ "multimediaviewer-pref": "Visor de ficheiros multimedia",
+ "multimediaviewer-pref-desc": "Mellore a súa experiencia de visualización de ficheiros multimedia con esta nova ferramenta. Mostra as imaxes nun tamaño maior nas páxinas que teñen miniaturas. As imaxes móstranse nun visor a pantalla completa agradable e as imaxes tamén se poden ver a tamaño completo.",
+ "multimediaviewer-optin-pref": "Activar o <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About visor de ficheiros multimedia]</span>",
+ "multimediaviewer-file-page": "Ir á páxina de ficheiro correspondente",
+ "multimediaviewer-repository-local": "Máis detalles",
+ "multimediaviewer-datetime-created": "Creación: $1",
+ "multimediaviewer-datetime-uploaded": "Subido o $1",
+ "multimediaviewer-credit-fallback": "Ver a información do autor",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|un autor máis|$1 autores máis}}",
+ "multimediaviewer-multiple-authors-combine": "$1 e $2",
+ "multimediaviewer-metadata-error": "Non se puideron cargar os detalles da imaxe (erro: $1)",
+ "multimediaviewer-thumbnail-error": "Sentímolo, non se pode mostrar o ficheiro",
+ "multimediaviewer-thumbnail-error-description": "Semella haber un problema técnico. Pode $1 ou $3 se persiste. Erro: $2",
+ "multimediaviewer-thumbnail-error-retry": "reintentar",
+ "multimediaviewer-thumbnail-error-report": "informar sobre o problema",
+ "multimediaviewer-license-cc-pd": "Dominio público",
+ "multimediaviewer-license-pd": "Dominio público",
+ "multimediaviewer-license-default": "Ver a licenza",
+ "multimediaviewer-permission-title": "Detalles dos permisos",
+ "multimediaviewer-permission-link": "ver os termos",
+ "multimediaviewer-permission-link-hide": "agochar os termos",
+ "multimediaviewer-permission-viewmore": "Ollar máis",
+ "multimediaviewer-restriction-2257": "Esta imaxe contén contido sexual explícito que pode ser obxecto da ''Child Protection and Obscenity Enforcement Act'' nos Estados Unidos de América.",
+ "multimediaviewer-restriction-aus-reserve": "Esta imaxe foi realizada nunha reserva da Commonwealth Australiana e non pode ser usada con fins comerciais sen autorización previa.",
+ "multimediaviewer-restriction-communist": "Esta imaxe contén a insignia Comunista que pode estar prohibida nalgúns países.",
+ "multimediaviewer-restriction-costume": "Esta imaxe mostra disfraces, uniformes ou traxes e pode ser obxecto de restricións legais.",
+ "multimediaviewer-restriction-currency": "Esta imaxe mostra unha unidade de moeda e pode ser obxecto de restricións legais.",
+ "multimediaviewer-restriction-design": "O deseño do obxecto desta imaxe pode ter copyright e estar suxeito a restricións legais.",
+ "multimediaviewer-restriction-fan-art": "Esta imaxe é un traballo artístico dun fan, e o reuso pode estar suxeito a restricións legais.",
+ "multimediaviewer-restriction-ihl": "Esta imaxe contén símbolos restrinxidos pola Lei Internacional Humanitaria.",
+ "multimediaviewer-restriction-insignia": "Esta imaxe contén unha insignia oficial que pode estar suxeita a restricións legais.",
+ "multimediaviewer-restriction-ita-mibac": "Esta imaxe reproduce unha propiedade pertencente ó patrimonio cultural Italiano e está restrinxida pola lei Italiana.",
+ "multimediaviewer-restriction-nazi": "Esta imaxe contén a insignia Nazi ou doutras asociacións fascistas, que poden estar prohibidas nalgúns países.",
+ "multimediaviewer-restriction-personality": "Esta imaxe contén persoas que poden ter dereitos que legalmente restrinxen certas reutilizacións da imaxe sen o seu consentimento.",
+ "multimediaviewer-restriction-trademarked": "Esta imaxe inclúe contido que pode estar suxeito ás leis de marcas.",
+ "multimediaviewer-restriction-default": "Esta imaxe pode estar restrinxida por disposicións legais externas ós dereitos de autor. Consulte a páxina de descrición do ficheiro para obter máis detalles.",
+ "multimediaviewer-restriction-default-and-others": "Esta imaxe pode ter máis restricións por outras disposicións legais externas ós dereitos de autor. Consulte a páxina de descrición do ficheiro para obter máis detalles.",
+ "multimediaviewer-about-mmv": "Acerca de",
+ "multimediaviewer-discuss-mmv": "Conversa",
+ "multimediaviewer-help-mmv": "Axuda",
+ "multimediaviewer-optout-mmv": "Desactivar o visor de ficheiros multimedia",
+ "multimediaviewer-optin-mmv": "Activar o visor de ficheiros multimedia",
+ "multimediaviewer-optout-pending-mmv": "Desactivando o visor de ficheiros multimedia",
+ "multimediaviewer-optin-pending-mmv": "Activando o visor de ficheiros multimedia",
+ "multimediaviewer-optout-help": "O visor de ficheiros multimedia xa non se usará para mostrar as imaxes. Para utilizalo de novo, prema no botón \"{{int:multimediaviewer-view-expanded}}\" que hai en cada imaxe. Logo, prema en \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "O visor de ficheiros multimedia mostrará as imaxes.",
+ "multimediaviewer-geolocation": "Localización: $1",
+ "multimediaviewer-reuse-link": "Compartir ou incluír este ficheiro",
+ "multimediaviewer-reuse-loading-placeholder": "Cargando…",
+ "multimediaviewer-reuse-copy-share": "Seleccionar e copiar (se está soportado) a ligazón para compartir este ficheiro",
+ "multimediaviewer-reuse-copy-embed": "Seleccionar e copiar (se está soportado) o código para incluír este ficheiro",
+ "multimediaviewer-share-tab": "Compartir",
+ "multimediaviewer-embed-tab": "Incorporar",
+ "multimediaviewer-download-link": "Descargar este ficheiro",
+ "multimediaviewer-download-preview-link-title": "Mostrar no navegador",
+ "multimediaviewer-download-original-button-name": "Descargar o ficheiro orixinal",
+ "multimediaviewer-download-small-button-name": "Descargar en tamaño pequeno",
+ "multimediaviewer-download-medium-button-name": "Descargar en tamaño mediano",
+ "multimediaviewer-download-large-button-name": "Descargar en tamaño grande",
+ "multimediaviewer-link-to-page": "Ligazón cara a páxina de descrición do ficheiro",
+ "multimediaviewer-link-to-file": "Ligazón cara ao ficheiro orixinal",
+ "multimediaviewer-share-explanation": "Copie e comparta libremente a ligazón",
+ "multimediaviewer-embed-wt": "Texto wiki",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Use este código para incorporar o ficheiro",
+ "multimediaviewer-text-embed-credit-text-bl": "De $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "De $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "De $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "De $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Ligazón",
+ "multimediaviewer-embed-byline": "Por $1",
+ "multimediaviewer-embed-license": "Baixo a licenza $1.",
+ "multimediaviewer-embed-via": "A través de $1.",
+ "multimediaviewer-default-embed-dimensions": "Tamaño de miniatura predeterminado",
+ "multimediaviewer-original-embed-dimensions": "Ficheiro orixinal $1",
+ "multimediaviewer-large-embed-dimensions": "Grande $1",
+ "multimediaviewer-medium-embed-dimensions": "Mediano $1",
+ "multimediaviewer-small-embed-dimensions": "Pequeno $1",
+ "multimediaviewer-description-page-button-text": "Máis detalles sobre o ficheiro",
+ "multimediaviewer-description-page-popup-text": "Máis detalles sobre o ficheiro en $1",
+ "multimediaviewer-commons-subtitle": "O repositorio multimedia libre",
+ "multimediaviewer-view-expanded": "Abrir no visor de ficheiros multimedia",
+ "multimediaviewer-view-config": "Configuración",
+ "multimediaviewer-close-popup-text": "Pechar a ferramenta (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Mostrar a pantalla completa",
+ "multimediaviewer-defullscreen-popup-text": "Saír da pantalla completa",
+ "multimediaviewer-next-image-alt-text": "Amosar a imaxe seguinte",
+ "multimediaviewer-prev-image-alt-text": "Amosar a imaxe previa",
+ "multimediaviewer-title-popup-text": "Descrición",
+ "multimediaviewer-credit-popup-text": "Autor e información da orixe",
+ "multimediaviewer-title-popup-text-more": "Ver a descrición completa",
+ "multimediaviewer-credit-popup-text-more": "Ver o autor e a orixe completos",
+ "multimediaviewer-download-attribution-cta-header": "Cómpre darlle recoñecemento ao autor",
+ "multimediaviewer-download-optional-attribution-cta-header": "Pode darlle recoñecemento ao autor",
+ "multimediaviewer-download-attribution-cta": "Mostrádeme como",
+ "multimediaviewer-download-attribution-copy": "Seleccionar e copiar (se está soportado) o texto de atribución deste ficheiro",
+ "multimediaviewer-reuse-warning-deletion": "Este ficheiro está a ser considerado para borrado.",
+ "multimediaviewer-reuse-warning-nonfree": "Este ficheiro non ten unha licenza libre.",
+ "multimediaviewer-reuse-warning-noattribution": "Este ficheiro non ten información de atribución.",
+ "multimediaviewer-reuse-warning-generic": "Compruebe [$1 os seus detalles] antes de utilizalo.",
+ "multimediaviewer-attr-plain": "Simple",
+ "multimediaviewer-options-tooltip": "Activar ou desactivar o visor de ficheiros multimedia",
+ "multimediaviewer-options-dialog-header": "Quere desactivar o visor de ficheiros multimedia?",
+ "multimediaviewer-options-text-header": "Omitir esta función de visualización para todos os ficheiros.",
+ "multimediaviewer-options-text-body": "Pode activalo máis adiante a través da páxina de detalles do ficheiro.",
+ "multimediaviewer-options-learn-more": "Máis información",
+ "multimediaviewer-option-submit-button": "Desactivar o visor de ficheiros multimedia",
+ "multimediaviewer-option-cancel-button": "Cancelar",
+ "multimediaviewer-disable-confirmation-header": "Desactivou o visor de ficheiros multimedia",
+ "multimediaviewer-disable-confirmation-text": "A vindeira vez que prema nunha miniatura en $1 verá directamente todos os detalles do ficheiro.",
+ "multimediaviewer-enable-dialog-header": "Quere activar o visor de ficheiros multimedia?",
+ "multimediaviewer-enable-text-header": "Activar esta función de visualización para todos os ficheiros por defecto.",
+ "multimediaviewer-enable-submit-button": "Activar o visor de ficheiros multimedia",
+ "multimediaviewer-enable-confirmation-header": "Activou o visor de ficheiros multimedia para todos os ficheiros",
+ "multimediaviewer-enable-confirmation-text": "A vindeira vez que prema nunha miniatura en $1 usarase o visor de ficheiros multimedia.",
+ "multimediaviewer-enable-alert": "O visor de ficheiros multimedia está agora desactivado",
+ "multimediaviewer-disable-info-title": "Desactivou o visor de ficheiros multimedia",
+ "multimediaviewer-disable-info": "Pode seguir vendo algúns ficheiros co visor de ficheiros multimedia.",
+ "multimediaviewer-errorreport-privacywarning": "Os detalles do erro achegáronse no informe, que será visible publicamente. Se non concorda con isto, pode editar o informe de abaixo e eliminar todos os datos que non queira compartir."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/gu.json b/www/wiki/extensions/MultimediaViewer/i18n/gu.json
new file mode 100644
index 00000000..69e7cef2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/gu.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "KartikMistry"
+ ]
+ },
+ "multimediaviewer-permission-viewmore": "વધુ જુઓ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/he.json b/www/wiki/extensions/MultimediaViewer/i18n/he.json
new file mode 100644
index 00000000..b10e4951
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/he.json
@@ -0,0 +1,138 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Neukoln",
+ "בנימין",
+ "Yona b",
+ "Eladk",
+ "ערן",
+ "Guycn2"
+ ]
+ },
+ "multimediaviewer-desc": "הגדלת תמונות ממוזערות למסך מלא.",
+ "multimediaviewer-pref": "מציג מדיה",
+ "multimediaviewer-pref-desc": "הכלי החדש הזה משפר את חוויית המולטימדיה שלך. הוא מציג תמונות מוגדלות בדפים עם תמונות ממוזערות. התמונות מוצגות בשכבה במסך מלא וניתן להציג אותן גם בגודל מלא.",
+ "multimediaviewer-optin-pref": "הפעלת <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About מציג המדיה]</span>",
+ "multimediaviewer-file-page": "מעבר אל דף הקובץ המתאים",
+ "multimediaviewer-repository-local": "פרטים נוספים",
+ "multimediaviewer-datetime-created": "נוצר: $1",
+ "multimediaviewer-datetime-uploaded": "הועלה: $1",
+ "multimediaviewer-credit-fallback": "הצגת מידע על היוצר",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ועוד יוצר אחד|ועוד $1 יוצרים}}",
+ "multimediaviewer-multiple-authors-combine": "$1 $2",
+ "multimediaviewer-metadata-error": "לא היה ניתן לטעון את פרטי התמונה. (שגיאה: $1)",
+ "multimediaviewer-thumbnail-error": "סליחה, לא ניתן להציג את הקובץ",
+ "multimediaviewer-thumbnail-error-description": "נראה שיש בעיה טכנית. באפשרותך $1 או $3 אם היא ממשיכה. שגיאה: $2",
+ "multimediaviewer-thumbnail-error-retry": "לנסות שוב",
+ "multimediaviewer-thumbnail-error-report": "לדווח את הבעיה",
+ "multimediaviewer-license-cc-pd": "נחלת הכלל",
+ "multimediaviewer-license-pd": "נחלת הכלל",
+ "multimediaviewer-license-default": "הצגת הרישיון",
+ "multimediaviewer-permission-title": "פרטי ההרשאה",
+ "multimediaviewer-permission-link": "הצגת התנאים",
+ "multimediaviewer-permission-link-hide": "הסתרת התנאים",
+ "multimediaviewer-permission-viewmore": "להראות עוד",
+ "multimediaviewer-restriction-2257": "התמונה הזאת מכילה תוכן מיני שעשוי להיות מושא לחוק להגנת הילד ואכיפת המוסר של ארצות הברית.",
+ "multimediaviewer-restriction-aus-reserve": "התמונה הזאת צולמה בשמורה של חבר העמים האוסטרלי ואין יכולה לשמש לרווח מסחרי ללא רשות.",
+ "multimediaviewer-restriction-communist": "התמונה הזאת מכילה סמלים קומוניסטיים שעשויים להיות אסורים במספר מדינות.",
+ "multimediaviewer-restriction-costume": "התמונה הזאת מציגה תחפושות ועשויה להיות מושא למגבלות משפטיות.",
+ "multimediaviewer-restriction-currency": "התמונה הזאת מציגה יחידת מטבע ועשויה להיות מושא למגבלות משפטיות.",
+ "multimediaviewer-restriction-design": "העיצוב של נושא התמונה הזאת יכול להיות מוגבל בזכויות יוצרים ולהיות מושא למגבלות משפטיות.",
+ "multimediaviewer-restriction-fan-art": "התמונה הזאת היא יצירת אמנות מעריצים, ושימוש חוזר בה עשוי להיות מושא למגבלות משפטיות.",
+ "multimediaviewer-restriction-ihl": "התמונה הזאת מכילה סמלים המוגבלים בחוק ההומניטרי הבין־לאומי.",
+ "multimediaviewer-restriction-insignia": "התמונה הזאת מכילה סמלים רשמיים שעשויים להיות מושא למגבלות משפטיות.",
+ "multimediaviewer-restriction-ita-mibac": "התמונה הזאת מציגה עותק של רכוש ששייך למורשת תרבותית איטלקית ומוגבל בחוק האיטלקי.",
+ "multimediaviewer-restriction-nazi": "המונה הזאת מכילה סמלים נאציים או פשיסטיים אחרים, שעשויים להיות אסורים במדינות מסוימות.",
+ "multimediaviewer-restriction-personality": "התמונה הזאת מכילה אנשים שיכולות להיות להם זכויות שמגבילים באופן משפטי שימושים חוזרים מסוימים של התמונה ללא הסכמה.",
+ "multimediaviewer-restriction-trademarked": "התמונה הזאת מכילה תוכן שאולי נתון לחוקי זכויות יוצרים.",
+ "multimediaviewer-restriction-default": "התמונה הזאת יכולה להיות מוגבלת בהוראות משפטיות אחרות מעבר לחוק זכויות היוצרים. ר' את תיאור הקובץ לפרטים.",
+ "multimediaviewer-restriction-default-and-others": "התמונה הזאת יכולה להיות מוגבלת בהוראות משפטיות אחרות מעבר לחוק זכויות היוצרים. ר' את תיאור הקובץ לפרטים.",
+ "multimediaviewer-about-mmv": "אודות",
+ "multimediaviewer-discuss-mmv": "דיון",
+ "multimediaviewer-help-mmv": "עזרה",
+ "multimediaviewer-optout-mmv": "כיבוי מציג המדיה",
+ "multimediaviewer-optin-mmv": "הפעלת מציג המדיה",
+ "multimediaviewer-optout-pending-mmv": "כיבוי מציג מדיה",
+ "multimediaviewer-optin-pending-mmv": "הפעלת מציג מדיה",
+ "multimediaviewer-optout-help": "מציג המדיה לא ישמש עוד להצגת תמונות. כדי להשתמש בו שוב, יש ללחוץ על כפתור \"{{int:multimediaviewer-view-expanded}}\" ליד תמונה. אחרי־כן יש ללחוץ על \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "מציג המדיה ישמש להצגת תמונות.",
+ "multimediaviewer-geoloc-north": "צפ",
+ "multimediaviewer-geoloc-east": "מז",
+ "multimediaviewer-geoloc-south": "דר",
+ "multimediaviewer-geoloc-west": "מע",
+ "multimediaviewer-geolocation": "מיקום: $1",
+ "multimediaviewer-reuse-link": "שיתוף או הטבעה של הקובץ הזה",
+ "multimediaviewer-reuse-loading-placeholder": "טעינה...",
+ "multimediaviewer-reuse-copy-share": "לבחור ולהעתיק (אם זה נתמך) את הקישור לשיתוף הקובץ הזה",
+ "multimediaviewer-reuse-copy-embed": "לבחור ולהעתיק (אם זה נתמך) את הקישור להטבעת הקובץ הזה",
+ "multimediaviewer-share-tab": "שיתוף",
+ "multimediaviewer-embed-tab": "הטבעה",
+ "multimediaviewer-download-link": "הורדת הקובץ הזה",
+ "multimediaviewer-download-preview-link-title": "תצוגה בדפדפן",
+ "multimediaviewer-download-original-button-name": "הורדת הקובץ המקורי",
+ "multimediaviewer-download-small-button-name": "הורדה בגודל קטן",
+ "multimediaviewer-download-medium-button-name": "הורדה בגודל בינוני",
+ "multimediaviewer-download-large-button-name": "הורדה בגודל גדול",
+ "multimediaviewer-link-to-page": "קישור לדף תיאור הקובץ",
+ "multimediaviewer-link-to-file": "קישור לקובץ המקורי",
+ "multimediaviewer-share-explanation": "קישור להעתקה ושיתוף חופשי",
+ "multimediaviewer-embed-wt": "קוד ויקי",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "קוד להטבעת הקובץ",
+ "multimediaviewer-text-embed-credit-text-bl": "מאת $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "מאת $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "מאת $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "מאת $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "קישור",
+ "multimediaviewer-embed-byline": "מאת $1",
+ "multimediaviewer-embed-license": "ברישיון $1.",
+ "multimediaviewer-embed-via": "דרך $1.",
+ "multimediaviewer-default-embed-dimensions": "גודל התחלתי לתמונה ממוזערת",
+ "multimediaviewer-original-embed-dimensions": "הקובץ המקורי $1",
+ "multimediaviewer-large-embed-dimensions": "גדול $1",
+ "multimediaviewer-medium-embed-dimensions": "בינוני $1",
+ "multimediaviewer-small-embed-dimensions": "קטן $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 פיקסלים",
+ "multimediaviewer-description-page-button-text": "פרטים נוספים על הקובץ הזה",
+ "multimediaviewer-description-page-popup-text": "פרטים נוספים על הקובץ הזה ב{{GRAMMAR:תחילית|$1}}",
+ "multimediaviewer-commons-subtitle": "מאגר המדיה החופשי",
+ "multimediaviewer-view-expanded": "פתיחה במציג המדיה",
+ "multimediaviewer-view-config": "הגדרות",
+ "multimediaviewer-close-popup-text": "סגירת הכלי הזה (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "הצגה במסך מלא",
+ "multimediaviewer-defullscreen-popup-text": "יציאה ממסך מלא",
+ "multimediaviewer-next-image-alt-text": "להציג את התמונה הבאה",
+ "multimediaviewer-prev-image-alt-text": "הצגת התמונה הקודמת",
+ "multimediaviewer-title-popup-text": "תיאור",
+ "multimediaviewer-credit-popup-text": "מידע על המחבר והמקור",
+ "multimediaviewer-title-popup-text-more": "הצגת תיאור מלא",
+ "multimediaviewer-credit-popup-text-more": "הצגת יוצר ומקור",
+ "multimediaviewer-download-attribution-cta-header": "חובה לתת ייחוס ליוצר",
+ "multimediaviewer-download-optional-attribution-cta-header": "באפשרותך לתת ייחוס ליוצר",
+ "multimediaviewer-download-attribution-cta": "תראו לי איך",
+ "multimediaviewer-download-attribution-copy": "נא לבחור ולהעתיק (אם אפשר) את טקסט הייחוס עבור הקובץ הזה",
+ "multimediaviewer-reuse-warning-deletion": "נשקלת מחיקה של הקובץ הזה.",
+ "multimediaviewer-reuse-warning-nonfree": "לקובץ הזה אין רישיון חופשי.",
+ "multimediaviewer-reuse-warning-noattribution": "לקובץ הזה אין מידע על ייחוס.",
+ "multimediaviewer-reuse-warning-generic": "נא לבדוק [$1 את הפרטים שלו] לפני השימוש בו.",
+ "multimediaviewer-attr-plain": "טקסט רגיל",
+ "multimediaviewer-options-tooltip": "הפעלה או כיבוי של תצוגה מקדימה",
+ "multimediaviewer-options-dialog-header": "לכבות את מציג המדיה?",
+ "multimediaviewer-options-text-header": "דילוג על הצגת התכונה הזאת לכל הקבצים.",
+ "multimediaviewer-options-text-body": "באפשרותך להפעיל את זה מאוחר יותר דרך דף הגדרות הקובץ.",
+ "multimediaviewer-options-learn-more": "מידע נוסף",
+ "multimediaviewer-option-submit-button": "כיבוי מציג המדיה",
+ "multimediaviewer-option-cancel-button": "ביטול",
+ "multimediaviewer-disable-confirmation-header": "כיבית את מציג המדיה",
+ "multimediaviewer-disable-confirmation-text": "בעת הלחיצה הבאה על תמונה ממוזערת ב{{GRAMMAR:תחילית|$1}}, יוצגו לך כל פרטי הקובץ.",
+ "multimediaviewer-enable-dialog-header": "להפעיל את מציג המדיה?",
+ "multimediaviewer-enable-text-header": "להפעיל את היכולת הזאת להציג מדיה עבור כל הקבצים לפי בררת המחדל.",
+ "multimediaviewer-enable-submit-button": "הפעלת מציג המדיה",
+ "multimediaviewer-enable-confirmation-header": "הפעלת את מציג המדיה עבור כל הקבצים",
+ "multimediaviewer-enable-confirmation-text": "בלחיצה הבאה על תמונה ממוזערת ב{{GRAMMAR:תחילית|$1}} ישמש מציג המדיה.",
+ "multimediaviewer-enable-alert": "מציג המדיה כבוי עכשיו",
+ "multimediaviewer-disable-info-title": "כיבית את מציג המדיה",
+ "multimediaviewer-disable-info": "היכולת עדיין להציג קבצים בודדים עם מציג המדיה.",
+ "multimediaviewer-errorreport-privacywarning": "פרטי השגיאה מצורפים לדו\"ח, שיהיה זמין לצפייה באופן ציבורי. אם זה לא מתאים לך, באפשרותך לערוך את הדו\"ח להלן ולמחוק את כל הנתונים שאין ברצונך לשתף."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/hi.json b/www/wiki/extensions/MultimediaViewer/i18n/hi.json
new file mode 100644
index 00000000..44a8a741
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/hi.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kunalgrover05",
+ "Siddhartha Ghai",
+ "Vivek Rai",
+ "Wikiuser13",
+ "Smtchahal",
+ "Upendradutt93",
+ "Sfic"
+ ]
+ },
+ "multimediaviewer-permission-title": "अनुमति विवरण",
+ "multimediaviewer-permission-link": "शर्तें देखें",
+ "multimediaviewer-about-mmv": "के बारे में",
+ "multimediaviewer-discuss-mmv": "वार्ता",
+ "multimediaviewer-reuse-loading-placeholder": "लोड हो रहा है…",
+ "multimediaviewer-embed-tab": "एम्बेड करें",
+ "multimediaviewer-download-link": "इस फ़ाइल को डाउनलोड करें",
+ "multimediaviewer-download-small-button-name": "छोटा आकार डाउनलोड करें",
+ "multimediaviewer-download-medium-button-name": "मध्यम आकार डाउनलोड करें",
+ "multimediaviewer-link-to-file": "मूल फ़ाइल से लिंक करें",
+ "multimediaviewer-embed-byline": "$1 द्वारा",
+ "multimediaviewer-description-page-button-text": "इस फ़ाइल की अधिक जानकारी"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/hr.json b/www/wiki/extensions/MultimediaViewer/i18n/hr.json
new file mode 100644
index 00000000..7674b9ec
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/hr.json
@@ -0,0 +1,135 @@
+{
+ "@metadata": {
+ "authors": [
+ "MaGa",
+ "Bugoslav"
+ ]
+ },
+ "multimediaviewer-desc": "Sličice u većoj veličini u prikazu preko cijelog zaslona.",
+ "multimediaviewer-pref": "Preglednik medijskih datoteka",
+ "multimediaviewer-pref-desc": "Poboljšajte svoje iskustvo pregledavajući multimedijske sadržaje uz pomoć ovog alata. Alat prikazuje slike u većoj veličini i u ljepšem Lightbox okviru. Slike se mogu vidjeti i u pravoj veličini.",
+ "multimediaviewer-optin-pref": "Omogući <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About preglednik multimedijskih datoteka]</span>",
+ "multimediaviewer-file-page": "Idi na odgovarajuću stranicu datoteke",
+ "multimediaviewer-repository-local": "Više pojedinosti",
+ "multimediaviewer-datetime-created": "Stvoreno: $1",
+ "multimediaviewer-datetime-uploaded": "Postavljeno: $1",
+ "multimediaviewer-credit-fallback": "Vidi informacije o autoru",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|još jedan autor|još $1 autora}}",
+ "multimediaviewer-multiple-authors-combine": "$1 i $2",
+ "multimediaviewer-metadata-error": "Nije bilo moguće učitavanje pojedinosti slike (pogrješka: $1)",
+ "multimediaviewer-thumbnail-error": "Žao nam je, datoteku nije moguće prikazati",
+ "multimediaviewer-thumbnail-error-description": "Čini se da je došlo do tehničke poteškoće. Možete $1 ili $3 ako se opet pojavi. Pogrješka: $2",
+ "multimediaviewer-thumbnail-error-retry": "ponoviti",
+ "multimediaviewer-thumbnail-error-report": "prijaviti poteškoću",
+ "multimediaviewer-license-cc-by-1.0": "CC BY 1.0",
+ "multimediaviewer-license-cc-sa-1.0": "CC SA 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC BY 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Javno vlasništvo",
+ "multimediaviewer-license-cc-zero": "CC 0",
+ "multimediaviewer-license-pd": "Javno vlasništvo",
+ "multimediaviewer-license-default": "Prikaži licenciju",
+ "multimediaviewer-permission-title": "Pojedinosti dopuštenja",
+ "multimediaviewer-permission-link": "vidi uvjete",
+ "multimediaviewer-permission-link-hide": "prikaži uvjete",
+ "multimediaviewer-permission-viewmore": "Pogledaj više",
+ "multimediaviewer-restriction-2257": "Ova slika sadrži eksplicitne seksualne prizore koji mogu biti podložni Zakonu o zaštiti djece te kontroli neprimjerenog materijala (Child Protection and Obscenity Enforcement Act).",
+ "multimediaviewer-about-mmv": "O pregledniku multimedijskih datoteka",
+ "multimediaviewer-discuss-mmv": "Rasprava",
+ "multimediaviewer-help-mmv": "Pomoć",
+ "multimediaviewer-optout-mmv": "Onemogući preglednik multimedijskih datoteka",
+ "multimediaviewer-optin-mmv": "Omogući preglednik multimedijskih datoteka",
+ "multimediaviewer-optout-pending-mmv": "Onemogućavanje preglednika multimedijskih datoteka",
+ "multimediaviewer-optin-pending-mmv": "Omogućavanje preglednika multimedijskih datoteka",
+ "multimediaviewer-optout-help": "Neće se više koristiti preglednik multimedijskih datoteka. Da biste ga opet omogućili, kliknite na \"{{int:multimediaviewer-view-expanded}}\" pored slike, te na \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Za pregledavanje slika će se koristiti preglednik multimedijskih datoteka.",
+ "multimediaviewer-geoloc-north": "S",
+ "multimediaviewer-geoloc-east": "I",
+ "multimediaviewer-geoloc-south": "J",
+ "multimediaviewer-geoloc-west": "Z",
+ "multimediaviewer-geoloc-coord": "$1° $2′ $3″ $4",
+ "multimediaviewer-geoloc-coords": "$1, $2",
+ "multimediaviewer-geolocation": "Lokacija: $1",
+ "multimediaviewer-reuse-link": "Podijeli ili ugradi ovu datoteku",
+ "multimediaviewer-reuse-loading-placeholder": "Učitavanje...",
+ "multimediaviewer-reuse-copy-share": "Označite i kopirajte (ako je podržano) poveznicu za dijeljene ove datoteke",
+ "multimediaviewer-reuse-copy-embed": "Označite i kopirajte (ako je podržano) kôd za ugradnju ove datoteke",
+ "multimediaviewer-share-tab": "Podijeli",
+ "multimediaviewer-embed-tab": "Ugradi",
+ "multimediaviewer-download-link": "Preuzmi ovu datoteku",
+ "multimediaviewer-download-preview-link-title": "Pogledaj u pregledniku",
+ "multimediaviewer-download-original-button-name": "Preuzmi izvornu datoteku",
+ "multimediaviewer-download-small-button-name": "Preuzmi malu sliku",
+ "multimediaviewer-download-medium-button-name": "Preuzmi srednje veliku sliku",
+ "multimediaviewer-download-large-button-name": "Preuzmi veliku sliku",
+ "multimediaviewer-link-to-page": "Poveznica na stranicu s informacijama o datoteki",
+ "multimediaviewer-link-to-file": "Poveznica na izvornu datoteku",
+ "multimediaviewer-share-explanation": "Kopirajte i slobodno dijelite poveznicu",
+ "multimediaviewer-embed-wt": "Wikitekst",
+ "multimediaviewer-embed-explanation": "Koristite ovaj kôd da biste ugradili datoteku",
+ "multimediaviewer-text-embed-credit-text-bl": "Autor $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Autor $1, $2",
+ "multimediaviewer-text-embed-credit-text-l": "$1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Autor $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Autor $1, $2",
+ "multimediaviewer-html-embed-credit-text-l": "$1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Poveznica",
+ "multimediaviewer-embed-byline": "Autor $1",
+ "multimediaviewer-embed-license": "Licencirano pod licencijom $1.",
+ "multimediaviewer-embed-license-nonfree": "$1.",
+ "multimediaviewer-embed-via": "Preko $1.",
+ "multimediaviewer-default-embed-dimensions": "Podrazumijevana veličina minijature",
+ "multimediaviewer-original-embed-dimensions": "Izvorna datoteka $1",
+ "multimediaviewer-large-embed-dimensions": "Velika $1",
+ "multimediaviewer-medium-embed-dimensions": "Srednja $1",
+ "multimediaviewer-small-embed-dimensions": "Mala $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 piksela",
+ "multimediaviewer-embed-dimensions-separated": "- $1",
+ "multimediaviewer-description-page-button-text": "Više pojedinosti o ovoj datoteci",
+ "multimediaviewer-description-page-popup-text": "Više pojedinosti o ovoj datoteci na projektu $1",
+ "multimediaviewer-commons-subtitle": "Spremište slobodnih datoteka",
+ "multimediaviewer-view-expanded": "Otvori u multimedijskom pregledniku",
+ "multimediaviewer-view-config": "Postavke",
+ "multimediaviewer-close-popup-text": "Zatvori alat (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Prikaži preko cijelog zaslona",
+ "multimediaviewer-defullscreen-popup-text": "Izađi iz prikaza preko cijelog ekrana",
+ "multimediaviewer-next-image-alt-text": "Prikaži sljedeću sliku",
+ "multimediaviewer-prev-image-alt-text": "Prikaži prethodnu sliku",
+ "multimediaviewer-title-popup-text": "Opis",
+ "multimediaviewer-credit-popup-text": "Autor i informacije o izvoru",
+ "multimediaviewer-title-popup-text-more": "Vidi cijeli opis",
+ "multimediaviewer-credit-popup-text-more": "Vidi puni prikaz autora i izvora",
+ "multimediaviewer-download-attribution-cta-header": "Trebate navesti autora",
+ "multimediaviewer-download-optional-attribution-cta-header": "Možetet pripisati autora",
+ "multimediaviewer-download-attribution-cta": "Pokaži mi kako",
+ "multimediaviewer-download-attribution-copy": "Označite i kopirajte (ako je podržano) tekst pripisivanja autorstva ove datoteke",
+ "multimediaviewer-attr-plain": "Običan tekst",
+ "multimediaviewer-attr-html": "HTML",
+ "multimediaviewer-options-tooltip": "Omogući ili onemogući preglednik multimedijskih datoteka",
+ "multimediaviewer-options-dialog-header": "Onemogućiti preglednik multimedijskih datoteka?",
+ "multimediaviewer-options-text-header": "Onemogući ovu značajku za sve datoteke.",
+ "multimediaviewer-options-text-body": "Naknadno ju možete omogućiti na stranici s pojedinostima datoteke.",
+ "multimediaviewer-options-learn-more": "Saznajte više",
+ "multimediaviewer-option-submit-button": "Onemogući preglednik",
+ "multimediaviewer-option-cancel-button": "Odustani",
+ "multimediaviewer-disable-confirmation-header": "Onemogućili ste preglednik",
+ "multimediaviewer-disable-confirmation-text": "Sljedeći put kad kliknete na minijaturu slike na projektu $1, bit ćete preusmjereni na pojedinosti datoteke.",
+ "multimediaviewer-enable-dialog-header": "Omogućiti preglednik multimedijskih datoteka?",
+ "multimediaviewer-enable-text-header": "Omogući ovu mogućnost ubuduće kao podrazumijevanu za sve datoteke.",
+ "multimediaviewer-enable-submit-button": "Omogući preglednik",
+ "multimediaviewer-enable-confirmation-header": "Omogućili ste preglednik za sve datoteke",
+ "multimediaviewer-enable-confirmation-text": "Sljedeći put kad kliknete na minijaturu slike na projektu $1, u uporabi će biti preglednik.",
+ "multimediaviewer-enable-alert": "Preglednik multimedijskih datoteka trenutačno je onemogućen.",
+ "multimediaviewer-disable-info-title": "Onemogućili ste preglednik",
+ "multimediaviewer-disable-info": "Još uvijek možete pregledavati pojedinačne datoteke u pregledniku.",
+ "multimediaviewer-errorreport-privacywarning": "Pojedinosti pogrješke su priloženi izvješću koje će biti javno vidljivo. Ako niste suglasni s tim, možete niže urediti izvješće i ukloniti podatke koje ne želite podijeliti."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/hsb.json b/www/wiki/extensions/MultimediaViewer/i18n/hsb.json
new file mode 100644
index 00000000..ccfbc652
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/hsb.json
@@ -0,0 +1,81 @@
+{
+ "@metadata": {
+ "authors": [
+ "J budissin",
+ "Michawiki"
+ ]
+ },
+ "multimediaviewer-desc": "Miniaturki w powjerchu połneje wobrazowki powjetšić.",
+ "multimediaviewer-pref": "Medijowy wobhladowak",
+ "multimediaviewer-pref-desc": "Polěpš swoje dožiwjenje multimedijoweho wobhladowanja z tutym nastrojom. Zwobraznja wobrazy we wjetšej wulkosći na stronach, kotrež maja miniaturki. Wobrazy pokazuja so w rjeńšim powjerchu połneje wobrazowki a hodźa so w połnej wulkosći předstajić.",
+ "multimediaviewer-file-page": "K přisłušnej datajowej stronje",
+ "multimediaviewer-repository-local": "Dalše informacije",
+ "multimediaviewer-datetime-created": "Wutworjeny $1",
+ "multimediaviewer-datetime-uploaded": "Nahraty $1",
+ "multimediaviewer-credit-fallback": "Awtorske informacije pokazać",
+ "multimediaviewer-license-cc-pd": "Powšitkownosći přistupny",
+ "multimediaviewer-license-default": "Licencu sej wobhladać",
+ "multimediaviewer-permission-link": "pokiwy k dalewužiwanju",
+ "multimediaviewer-permission-link-hide": "pokiwy schować",
+ "multimediaviewer-permission-viewmore": "wjace pokazać",
+ "multimediaviewer-about-mmv": "Wo medijowym wobhladowaku",
+ "multimediaviewer-discuss-mmv": "Wo tutej funkciji diskutować",
+ "multimediaviewer-help-mmv": "Pomoc",
+ "multimediaviewer-optout-mmv": "Medijowy wobhladowak začinić",
+ "multimediaviewer-optin-mmv": "Medijowy wobhladowak wočinić",
+ "multimediaviewer-optout-pending-mmv": "Medijowy wobhladowak so začini",
+ "multimediaviewer-optin-pending-mmv": "Medijowy wobhladowak so wočini",
+ "multimediaviewer-geolocation": "Městno: $1",
+ "multimediaviewer-reuse-link": "Tutu dataju wužiwać abo dźělić",
+ "multimediaviewer-reuse-loading-placeholder": "Začituje so...",
+ "multimediaviewer-share-tab": "Dźělić",
+ "multimediaviewer-embed-tab": "Wužiwać",
+ "multimediaviewer-download-link": "Tutu dataju sćahnyć",
+ "multimediaviewer-download-preview-link-title": "We wobhladowaku pokazać",
+ "multimediaviewer-download-original-button-name": "Originalnu dataju sćahnyć",
+ "multimediaviewer-download-small-button-name": "We małej wulkosći sćahnyć",
+ "multimediaviewer-download-medium-button-name": "W srjedźnej wulkosći sćahnyć",
+ "multimediaviewer-download-large-button-name": "We wulkej wulkosći sćahnyć",
+ "multimediaviewer-link-to-page": "Wotkaz k wopisowanskej stronje",
+ "multimediaviewer-link-to-file": "Wotkaz k originalnej dataji",
+ "multimediaviewer-share-explanation": "Wotkaz kopěrować a dźělić",
+ "multimediaviewer-embed-wt": "WikiTekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-byline": "Wot $1",
+ "multimediaviewer-embed-license": "Licencowane pod $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Standardna wulkosć přehladki",
+ "multimediaviewer-original-embed-dimensions": "Originalna dataja $1",
+ "multimediaviewer-large-embed-dimensions": "Wulke $1",
+ "multimediaviewer-medium-embed-dimensions": "Srjedźne $1",
+ "multimediaviewer-small-embed-dimensions": "Małe $1",
+ "multimediaviewer-description-page-button-text": "Wjace detailow wo dataji",
+ "multimediaviewer-description-page-popup-text": "Wjace detailow wo dataji na $1",
+ "multimediaviewer-commons-subtitle": "Swobodny medijowy archiw",
+ "multimediaviewer-view-expanded": "W medijowym wobhladowaku wočinić",
+ "multimediaviewer-view-config": "Konfiguracija",
+ "multimediaviewer-close-popup-text": "Medijowy wobhladowak začinić (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Na połnej wobrazowce pokazać",
+ "multimediaviewer-defullscreen-popup-text": "Połnu wobrazowku wopušćić",
+ "multimediaviewer-title-popup-text": "Wopis",
+ "multimediaviewer-credit-popup-text": "Informacije wo awtorje a žórle",
+ "multimediaviewer-title-popup-text-more": "Dospołny wopis pokazać",
+ "multimediaviewer-credit-popup-text-more": "Dospołne informacije wo awtorje a žórle pokazać",
+ "multimediaviewer-download-attribution-cta-header": "Trěbne je podać mjeno awtora.",
+ "multimediaviewer-download-optional-attribution-cta-header": "Móžne je podać mjeno awtora.",
+ "multimediaviewer-options-tooltip": "Medijowy wobhladowak wočinić abo začinić",
+ "multimediaviewer-options-dialog-header": "Medijowy wobhladowak začinić?",
+ "multimediaviewer-options-text-body": "Móžeš wočinić medijowy wobhladowak pozdźišo přez wopisowansku stronu",
+ "multimediaviewer-options-learn-more": "Dalše informacije",
+ "multimediaviewer-option-submit-button": "Medijowy wobhladowak začinić",
+ "multimediaviewer-option-cancel-button": "Přetorhnyć",
+ "multimediaviewer-disable-confirmation-header": "Sy začinił(a) medijowy wobhladowak",
+ "multimediaviewer-enable-dialog-header": "Medijowy wobhladowak wočinić?",
+ "multimediaviewer-enable-text-header": "Medijowy wobhladowak za wšitke dataje aktiwěrować.",
+ "multimediaviewer-enable-submit-button": "Medijowy wobhladowak wočinić",
+ "multimediaviewer-enable-confirmation-header": "Sy aktiwěrował(a) medijowy wobhladowak za wšitke dataje",
+ "multimediaviewer-enable-confirmation-text": "Hdyž kliknješ přichodny raz na přehladku na $1, wužiwa so medijowy wobhladowak.",
+ "multimediaviewer-enable-alert": "Medijowy wobhladowak je nětko začinjeny",
+ "multimediaviewer-disable-info-title": "Sy začinił(a) medijowy wobhladowak",
+ "multimediaviewer-disable-info": "Móžeš přeco hišće jednotliwe dataje z medijowym wobhladowakom wobhladać"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/hu.json b/www/wiki/extensions/MultimediaViewer/i18n/hu.json
new file mode 100644
index 00000000..b797ba23
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/hu.json
@@ -0,0 +1,114 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tgr",
+ "Misibacsi",
+ "Tacsipacsi",
+ "Csega"
+ ]
+ },
+ "multimediaviewer-desc": "A teljes képernyőre kinagyíthatóvá teszi a beágyazott képeket",
+ "multimediaviewer-pref": "Képnézegető",
+ "multimediaviewer-pref-desc": "A multimédiás tartalmak megnézését könnyebbé tevő eszköz. Az oldalak szövegébe beágyazott bélyegképeket kattintásra nagyobb méretben jeleníti meg, és számos egyéb adatot is mutat róluk.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Képnézegető]</span> engedélyezése",
+ "multimediaviewer-file-page": "Ugrás a fájl saját lapjára",
+ "multimediaviewer-repository-local": "További részletek",
+ "multimediaviewer-datetime-created": "Létrehozva: $1",
+ "multimediaviewer-datetime-uploaded": "Feltöltve: $1",
+ "multimediaviewer-credit-fallback": "Szerzőről szóló információ megtekintése",
+ "multimediaviewer-multiple-authors": "$1 további szerző",
+ "multimediaviewer-multiple-authors-combine": "$1 és $2",
+ "multimediaviewer-metadata-error": "Nem sikerült betölteni a kép adatait (hibaüzenet: $1)",
+ "multimediaviewer-thumbnail-error": "Bocsánat, a fájl nem jeleníthető meg",
+ "multimediaviewer-thumbnail-error-description": "Úgy tűnik, technikai hiba lépett fel. $1 vagy $3, ha nem szűnik meg. Hibaüzenet: $2",
+ "multimediaviewer-thumbnail-error-retry": "Újrapróbálkozhatsz",
+ "multimediaviewer-thumbnail-error-report": "jelentheted a hibát",
+ "multimediaviewer-license-cc-pd": "Közkincs",
+ "multimediaviewer-license-pd": "Közkincs",
+ "multimediaviewer-license-default": "Licenc megtekintése",
+ "multimediaviewer-permission-title": "Részletes engedély",
+ "multimediaviewer-permission-link": "feltételek mutatása",
+ "multimediaviewer-permission-link-hide": "feltételek elrejtése",
+ "multimediaviewer-permission-viewmore": "Bővebben",
+ "multimediaviewer-restriction-communist": "Ez a kép kommunista jelvényeket tartalmaz, amelyeket egyes országokban – így Magyarországon is – csak korlátozásokkal lehet használni.",
+ "multimediaviewer-restriction-costume": "Ez a kép jelmezt ábrázol, és jogi korlátozások alá eshet.",
+ "multimediaviewer-restriction-currency": "Ez a kép egy pénzegységet ábrázol, és jogi korlátozások alá eshet.",
+ "multimediaviewer-restriction-nazi": "Ez a kép náci vagy egyéb fasiszta jelvényt tartalmaz, amelynek felhasználása egyes országokban – így Magyarországon is – korlátozva lehet.",
+ "multimediaviewer-restriction-trademarked": "Ezen a képen olyan tartalom található, ami védjegyoltalom alá eshet.",
+ "multimediaviewer-about-mmv": "Névjegy",
+ "multimediaviewer-discuss-mmv": "Megbeszélés",
+ "multimediaviewer-help-mmv": "Súgó",
+ "multimediaviewer-optout-mmv": "Képnézegető letiltása",
+ "multimediaviewer-optin-mmv": "A Képnézegető engedélyezése",
+ "multimediaviewer-optout-pending-mmv": "Képnézegető letiltása folyamatban",
+ "multimediaviewer-optin-pending-mmv": "Képnézegető engedélyezése folyamatban",
+ "multimediaviewer-optout-help": "Mostantól nem a Képnézegető fogja megjeleníteni a képeket. Az újbóli bekapcsoláshoz kattints a „{{int:multimediaviewer-view-expanded}}”, majd a „{{int:multimediaviewer-optin-mmv}}” gombra.",
+ "multimediaviewer-optin-help": "A Képnézegető fogja megjeleníteni a képeket.",
+ "multimediaviewer-geolocation": "Hely: $1",
+ "multimediaviewer-reuse-link": "A fájl megosztása vagy beágyazása",
+ "multimediaviewer-reuse-loading-placeholder": "Betöltés…",
+ "multimediaviewer-reuse-copy-share": "A fájlra mutató hivatkozás kijelölése és másolása (ha támogatott)",
+ "multimediaviewer-reuse-copy-embed": "A fájl beágyazására szolgáló kód kijelölése és másolása (ha támogatott)",
+ "multimediaviewer-share-tab": "Megosztás",
+ "multimediaviewer-embed-tab": "Beágyazás",
+ "multimediaviewer-download-link": "Fájl letöltése",
+ "multimediaviewer-download-preview-link-title": "Megtekintés a böngészőben",
+ "multimediaviewer-download-original-button-name": "Eredeti fájl letöltése",
+ "multimediaviewer-download-small-button-name": "Letöltés kis méretben",
+ "multimediaviewer-download-medium-button-name": "Letöltés közepes méretben",
+ "multimediaviewer-download-large-button-name": "Letöltés nagy méretben",
+ "multimediaviewer-link-to-page": "Link a leírólapra",
+ "multimediaviewer-link-to-file": "Link az eredeti fájlra",
+ "multimediaviewer-share-explanation": "Oszd meg ezt a linket",
+ "multimediaviewer-embed-wt": "Wikiszöveg",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Ezzel a kóddal tudod beágyazni a fájlt",
+ "multimediaviewer-text-embed-credit-text-bl": "Készítette: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Készítette: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Készítette: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Készítette: $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Hivatkozás",
+ "multimediaviewer-embed-byline": "Szerző: $1",
+ "multimediaviewer-embed-license": "Engedély: $1",
+ "multimediaviewer-embed-via": "Forrás: $1",
+ "multimediaviewer-default-embed-dimensions": "Alapértelmezett bélyegképméret",
+ "multimediaviewer-original-embed-dimensions": "Eredeti fájl $1",
+ "multimediaviewer-large-embed-dimensions": "Nagy méret $1",
+ "multimediaviewer-medium-embed-dimensions": "Közepes méret $1",
+ "multimediaviewer-small-embed-dimensions": "Kis méret $1",
+ "multimediaviewer-description-page-button-text": "Bővebben erről a fájlról",
+ "multimediaviewer-description-page-popup-text": "További részletek erről a fájlról itt: $1",
+ "multimediaviewer-commons-subtitle": "A szabad képgyűjtemény",
+ "multimediaviewer-view-expanded": "Megnyitás a Képnézegetőben",
+ "multimediaviewer-view-config": "Beállítások",
+ "multimediaviewer-close-popup-text": "Eszköz bezárása (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Teljes képernyős megjelenítés",
+ "multimediaviewer-defullscreen-popup-text": "Kilépés a teljes képernyős módból",
+ "multimediaviewer-next-image-alt-text": "Következő kép megjelenítése",
+ "multimediaviewer-prev-image-alt-text": "Előző kép megjelenítése",
+ "multimediaviewer-title-popup-text": "Leírás",
+ "multimediaviewer-credit-popup-text": "Szerző- és forrásinformációk",
+ "multimediaviewer-title-popup-text-more": "Teljes leírás megtekintése",
+ "multimediaviewer-credit-popup-text-more": "Teljes szerző és forrás megtekintése",
+ "multimediaviewer-download-attribution-cta-header": "Meg kell nevezned a szerzőt",
+ "multimediaviewer-download-optional-attribution-cta-header": "Megnevezheted a szerzőt",
+ "multimediaviewer-download-attribution-cta": "Mutasd meg, hogyan",
+ "multimediaviewer-reuse-warning-deletion": "Ezt a fájlt törlésre jelölték.",
+ "multimediaviewer-reuse-warning-nonfree": "Ez a fájl nem rendelkezik szabad licenccel.",
+ "multimediaviewer-reuse-warning-generic": "Ellenőrizd a [$1 részleteket], mielőtt használnád.",
+ "multimediaviewer-attr-plain": "Sima",
+ "multimediaviewer-options-tooltip": "A Képnézegető be- vagy kikapcsolása",
+ "multimediaviewer-options-dialog-header": "Letiltod a Képnézegetőt?",
+ "multimediaviewer-options-text-body": "Később a fájlleírólapon keresztül engedélyezheted.",
+ "multimediaviewer-options-learn-more": "További információk",
+ "multimediaviewer-option-submit-button": "A Képnézegető letiltása",
+ "multimediaviewer-option-cancel-button": "Mégse",
+ "multimediaviewer-disable-confirmation-header": "Letiltottad a Képnézegetőt",
+ "multimediaviewer-disable-confirmation-text": "Amikor legközelebb egy bélyegképre kattintasz a(z) $1 wikin, azonnal látni fogod az összes fájladatot.",
+ "multimediaviewer-enable-dialog-header": "Engedélyezed a Képnézegetőt?",
+ "multimediaviewer-enable-submit-button": "A Képnézegető engedélyezése",
+ "multimediaviewer-enable-confirmation-text": "Amikor legközelebb egy bélyegképre kattintasz a(z) $1 wikin, a Képnézegető fog megjelenni.",
+ "multimediaviewer-enable-alert": "A Képnézegető most le van tiltva",
+ "multimediaviewer-disable-info-title": "Letiltottad a Képnézegetőt",
+ "multimediaviewer-disable-info": "Továbbra is megtekinthetsz egyes fájlokat a Képnézegetővel."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/hy.json b/www/wiki/extensions/MultimediaViewer/i18n/hy.json
new file mode 100644
index 00000000..4b8ddb85
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/hy.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kareyac"
+ ]
+ },
+ "multimediaviewer-next-image-alt-text": "Ցույց տալ հաջորդ պատկերը",
+ "multimediaviewer-prev-image-alt-text": "Ցույց տալ նախորդ պատկերը"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ia.json b/www/wiki/extensions/MultimediaViewer/i18n/ia.json
new file mode 100644
index 00000000..8e63543a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ia.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "McDutchie"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Activar <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About visualisator multimedial]</span>",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|un altere autor|$1 altere autores}}",
+ "multimediaviewer-multiple-authors-combine": "$1 e $2"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/id.json b/www/wiki/extensions/MultimediaViewer/i18n/id.json
new file mode 100644
index 00000000..bf9b3e97
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/id.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "William Surya Permana",
+ "Ahdan"
+ ]
+ },
+ "multimediaviewer-desc": "Membentangkan gambar mini dalam ukuran yang lebih desar di dalam 'kotak tipis'",
+ "multimediaviewer-pref": "Penampil Media",
+ "multimediaviewer-pref-desc": "Tingkatkan pengalaman penampilan multimedia Anda dengan alat baru ini. Penampil Media menampilkan gambar dalam ukuran yang lebih besar pada halaman yang memiliki gambar mini. Gambar ditampilkan dalam 'kotak tipis' melayang yang lebih indah, dan dapat juga ditampilkan dalam ukuran penuh.",
+ "multimediaviewer-file-page": "Pergi ke halaman berkas terkait",
+ "multimediaviewer-repository-local": "Rincian lebih lanjut",
+ "multimediaviewer-datetime-created": "Dibuat pada $1",
+ "multimediaviewer-datetime-uploaded": "Diunggah pada $1",
+ "multimediaviewer-license-cc-pd": "Domain Umum",
+ "multimediaviewer-license-default": "Lihat lisensi",
+ "multimediaviewer-about-mmv": "Tentang Penampil Media",
+ "multimediaviewer-discuss-mmv": "Tinggalkan umpan balik",
+ "multimediaviewer-reuse-link": "Bagikan atau sematkan berkas ini",
+ "multimediaviewer-download-link": "Unduh file ini",
+ "multimediaviewer-view-expanded": "Buka di Media Viewer"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ilo.json b/www/wiki/extensions/MultimediaViewer/i18n/ilo.json
new file mode 100644
index 00000000..d9bba969
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ilo.json
@@ -0,0 +1,71 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lam-ang"
+ ]
+ },
+ "multimediaviewer-desc": "Palawaen dagiti bassit a ladawan iti dakdakkel iti napno a pangbuyaan ti interface.",
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-pref-desc": "Pasayaatem ti panagsanay a panagbuya ti nadumaduma a midia iti daytoy baro a ramit. Daytoy ket agiparang kadagiti dakdakkel a ladawan kadagiti panid nga addaan kadagiti bassit a ladawan. Dagiti ladawan ket maiparang iti nasaysayaat a tuon iti napno a pangbuyaan ti interface, ken mabalin pay a makita iti napno a kadakkel.",
+ "multimediaviewer-optin-pref": "Pakabaelan ti <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Mapan iti maitutop a panid ti papeles",
+ "multimediaviewer-repository-local": "Dagiti adu pay a salaysay a maipanggep iti daytoy a papeles",
+ "multimediaviewer-datetime-created": "Pinartuat: $1",
+ "multimediaviewer-datetime-uploaded": "Inkarga: $1",
+ "multimediaviewer-metadata-error": "Biddut: Saan a maikarga ti datos ti ladawan. $1",
+ "multimediaviewer-thumbnail-error": "Biddut: Saan a maikarga ti datos ti bassit a ladawan. $1",
+ "multimediaviewer-license-cc-pd": "Dominio a Publiko",
+ "multimediaviewer-license-pd": "Dominio a Publiko",
+ "multimediaviewer-license-default": "Kitaen ti lisensia",
+ "multimediaviewer-permission-title": "Dagiti salaysay ti lisensia",
+ "multimediaviewer-permission-link": "kitaen dagiti termino",
+ "multimediaviewer-permission-viewmore": "Agkita pay ti adu",
+ "multimediaviewer-about-mmv": "Maipanggep ti Media Viewer",
+ "multimediaviewer-discuss-mmv": "Pakitungtungan daytoy a langa",
+ "multimediaviewer-help-mmv": "Tulong",
+ "multimediaviewer-optout-mmv": "Ibaldado ti Media Viewer",
+ "multimediaviewer-optin-mmv": "Pakabaelan ti Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Ibaldadon ti Media Viewer",
+ "multimediaviewer-optin-pending-mmv": "Pakabaelanen ti Media Viewer",
+ "multimediaviewer-optout-help": "Ti Media Viewer ket saanton a mausar a mangipakita kadagiti ladawan. Ti mangusar manen, pinduten ti buton ti \"{{int:multimediaviewer-view-expanded}}\" a kadenna ti ania man a ladawan. Kalpasanna pinduten ti \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Ti Media Viewer ket mausarton a mangipakita kadagiti ladawan.",
+ "multimediaviewer-geolocation": "Lokasion: $1",
+ "multimediaviewer-reuse-link": "Usaren daytoy a papeles",
+ "multimediaviewer-reuse-loading-placeholder": "Agkarkarga...",
+ "multimediaviewer-share-tab": "Makibingay",
+ "multimediaviewer-embed-tab": "Isengngat",
+ "multimediaviewer-download-link": "Agikaraga",
+ "multimediaviewer-download-preview-link-title": "Kitaen iti pagbasabasa",
+ "multimediaviewer-download-original-button-name": "Ikarga ti kasisigud a papeles",
+ "multimediaviewer-download-small-button-name": "Ikarga ti bassit a kadakkel",
+ "multimediaviewer-download-medium-button-name": "Ikarga ti kalalainganna a kadakkel",
+ "multimediaviewer-download-large-button-name": "Ikarga ti dakkel a kadakkel",
+ "multimediaviewer-link-to-page": "Isilpo iti panid ti deskripsion ti papeles",
+ "multimediaviewer-link-to-file": "Isilpo iti kasisigud a papeles",
+ "multimediaviewer-share-explanation": "Kopiaen ken nawaya a pakibingayan ti silpo",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Isaren daytoy a kodigo tapno maisengngat ti papeles",
+ "multimediaviewer-embed-byline": "Babaen ni $1",
+ "multimediaviewer-embed-license": "Nalisensiaan babaen ti $1.",
+ "multimediaviewer-embed-via": "Babaen ti $1.",
+ "multimediaviewer-default-embed-dimensions": "Kasisigud a kadakkel ti bassit a ladawan",
+ "multimediaviewer-original-embed-dimensions": "Kasisigud a ladawan $1",
+ "multimediaviewer-large-embed-dimensions": "Dakkel $1",
+ "multimediaviewer-medium-embed-dimensions": "Kalalainganna $1",
+ "multimediaviewer-small-embed-dimensions": "Bassit $1",
+ "multimediaviewer-description-page-button-text": "Dagiti adu pay a salaysay a maipanggep iti daytoy a papeles",
+ "multimediaviewer-description-page-popup-text": "Dagiti adu pay a salaysay a maipanggep iti daytoy a papeles idiay $1",
+ "multimediaviewer-commons-subtitle": "Ti nawaya a repositorio ti midia",
+ "multimediaviewer-view-expanded": "Padakkelen ti panagbuya",
+ "multimediaviewer-close-popup-text": "Irikep daytoy a ramit (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Ipakita ti napno a pagbuyaan",
+ "multimediaviewer-defullscreen-popup-text": "Rummuar iti napno a pagbuyaan",
+ "multimediaviewer-title-popup-text": "Nagan ti papeles",
+ "multimediaviewer-credit-popup-text": "Mannurat ken pakaammo ti taudan",
+ "multimediaviewer-title-popup-text-more": "Pinduten tapno maiparang ti napno a nagan ti papeles",
+ "multimediaviewer-credit-popup-text-more": "Pinduten tapno maipakita ti napno a mannurat ken taudan",
+ "multimediaviewer-download-attribution-cta-header": "Nasken a pammadayawam ti mannurat",
+ "multimediaviewer-download-attribution-cta": "Ipakitam kaniak no kasano",
+ "multimediaviewer-attr-plain": "Naranas"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/inh.json b/www/wiki/extensions/MultimediaViewer/i18n/inh.json
new file mode 100644
index 00000000..b6c35df5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/inh.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Умар",
+ "ElizaMag"
+ ]
+ },
+ "multimediaviewer-help-mmv": "Новкъoстал"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/io.json b/www/wiki/extensions/MultimediaViewer/i18n/io.json
new file mode 100644
index 00000000..d9f0b386
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/io.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joao Xavier"
+ ]
+ },
+ "multimediaviewer-repository-local": "Plura detali",
+ "multimediaviewer-permission-viewmore": "Montrez pluse",
+ "multimediaviewer-description-page-button-text": "Plura detali pri ca arkivo"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/is.json b/www/wiki/extensions/MultimediaViewer/i18n/is.json
new file mode 100644
index 00000000..6005486e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/is.json
@@ -0,0 +1,82 @@
+{
+ "@metadata": {
+ "authors": [
+ "Snævar",
+ "Sveinn í Felli"
+ ]
+ },
+ "multimediaviewer-file-page": "Fara á samsvarandi skráarsíðu",
+ "multimediaviewer-repository-local": "Frekari upplýsingar",
+ "multimediaviewer-datetime-created": "Búið til: $1",
+ "multimediaviewer-datetime-uploaded": "Hlaðið inn: $1",
+ "multimediaviewer-multiple-authors-combine": "$1 og $2",
+ "multimediaviewer-metadata-error": "Gat ekki hlaðið inn myndagögnum. (villa: $1)",
+ "multimediaviewer-thumbnail-error": "Því miður var ekki hægt að sýna skránna.",
+ "multimediaviewer-thumbnail-error-retry": "Reyna aftur",
+ "multimediaviewer-license-cc-by-1.0": "CC BY 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC BY 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Í almenningi",
+ "multimediaviewer-license-cc-zero": "CC 0",
+ "multimediaviewer-license-pd": "Í almenningi",
+ "multimediaviewer-license-default": "Skoða leyfi",
+ "multimediaviewer-permission-link": "skoða skilmála",
+ "multimediaviewer-permission-viewmore": "sýna meira",
+ "multimediaviewer-about-mmv": "Um",
+ "multimediaviewer-discuss-mmv": "Umræða",
+ "multimediaviewer-help-mmv": "Hjálp",
+ "multimediaviewer-geoloc-north": "N",
+ "multimediaviewer-geoloc-east": "A",
+ "multimediaviewer-geoloc-south": "S",
+ "multimediaviewer-geoloc-west": "V",
+ "multimediaviewer-geolocation": "Staðsetning: $1",
+ "multimediaviewer-reuse-link": "Deila eða innifela þessa skrá",
+ "multimediaviewer-reuse-loading-placeholder": "Hleð...",
+ "multimediaviewer-share-tab": "Deila",
+ "multimediaviewer-embed-tab": "Ívefja",
+ "multimediaviewer-download-link": "Hlaða niður þessari skrá",
+ "multimediaviewer-download-preview-link-title": "Skoða í vafra",
+ "multimediaviewer-download-original-button-name": "Hlaða niður upprunalegri skrá",
+ "multimediaviewer-download-small-button-name": "Hlaða niður smámynd",
+ "multimediaviewer-download-medium-button-name": "Hlaða niður miðlungstærð",
+ "multimediaviewer-download-large-button-name": "Hlaða niður stórri stærð",
+ "multimediaviewer-link-to-file": "Tengill á upphaflega skrá",
+ "multimediaviewer-share-explanation": "Afrita og deila tenglinum frjálst",
+ "multimediaviewer-embed-wt": "Wiki-texti",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-text-embed-credit-text-bl": "Með $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Með $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Með $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Með $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Tengill",
+ "multimediaviewer-embed-byline": "Eftir $1",
+ "multimediaviewer-embed-license": "Gefið út undir $1",
+ "multimediaviewer-embed-via": "Margmiðlunarskrá frá $1",
+ "multimediaviewer-default-embed-dimensions": "Sjálfgefin smámynda stærð",
+ "multimediaviewer-original-embed-dimensions": "Upphafleg skrá $1",
+ "multimediaviewer-large-embed-dimensions": "Stór $1",
+ "multimediaviewer-medium-embed-dimensions": "Miðlungs $1",
+ "multimediaviewer-small-embed-dimensions": "Lítil $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 px",
+ "multimediaviewer-description-page-button-text": "Frekari upplýsingar um þessa skrá",
+ "multimediaviewer-description-page-popup-text": "Frekari upplýsingar um þessa skrá á $1",
+ "multimediaviewer-view-config": "Uppsetning",
+ "multimediaviewer-defullscreen-popup-text": "Fara úr skjáfylliham",
+ "multimediaviewer-next-image-alt-text": "Lag",
+ "multimediaviewer-prev-image-alt-text": "Yfirlegg",
+ "multimediaviewer-title-popup-text": "Lýsing",
+ "multimediaviewer-download-attribution-cta": "Sýndu mér hvernig",
+ "multimediaviewer-attr-plain": "Hreintexti",
+ "multimediaviewer-attr-html": "HTML",
+ "multimediaviewer-options-learn-more": "Vita meira",
+ "multimediaviewer-option-cancel-button": "Hætta við"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/it.json b/www/wiki/extensions/MultimediaViewer/i18n/it.json
new file mode 100644
index 00000000..0315299d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/it.json
@@ -0,0 +1,137 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beta16",
+ "CristianCantoro",
+ "Maria victoria",
+ "OrbiliusMagister",
+ "Rosh",
+ "Melos",
+ "PeppeAeco",
+ "Toadino2",
+ "Macofe",
+ "Alexmar983",
+ "Fringio"
+ ]
+ },
+ "multimediaviewer-desc": "Espande le miniature in dimensioni maggiori in un'interfaccia a schermo intero.",
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-pref-desc": "Sperimenta una miglior visualizzazione dei file multimediali con questo nuovo strumento che visualizza le immagini più grandi su pagine che ne riportano le miniature. Le immagini sono mostrate in un'interfaccia a schermo intero più gradevole, ma possono essere visualizzate anche alla dimensione originale.",
+ "multimediaviewer-optin-pref": "Attiva <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Vai alla corrispondente pagina del file",
+ "multimediaviewer-repository-local": "Ulteriori dettagli",
+ "multimediaviewer-datetime-created": "Creato: $1",
+ "multimediaviewer-datetime-uploaded": "Caricato: $1",
+ "multimediaviewer-credit-fallback": "Vedi informazioni sull'autore",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|un altro autore|altri $1 autori}}",
+ "multimediaviewer-multiple-authors-combine": "$1 e $2",
+ "multimediaviewer-metadata-error": "Impossibile caricare i dettagli dell'immagine (errore: $1)",
+ "multimediaviewer-thumbnail-error": "Spiacenti, il file non può essere visualizzato",
+ "multimediaviewer-thumbnail-error-description": "Sembra esserci un problema tecnico. Puoi $1 o $2 se persiste. Errore: $3",
+ "multimediaviewer-thumbnail-error-retry": "riprova",
+ "multimediaviewer-thumbnail-error-report": "segnalare il problema",
+ "multimediaviewer-license-cc-pd": "Pubblico dominio",
+ "multimediaviewer-license-pd": "Pubblico dominio",
+ "multimediaviewer-license-default": "Vedi la licenza",
+ "multimediaviewer-permission-title": "Dettagli dell'autorizzazione",
+ "multimediaviewer-permission-link": "vedi termini",
+ "multimediaviewer-permission-link-hide": "nascondi termini",
+ "multimediaviewer-permission-viewmore": "Mostra altro",
+ "multimediaviewer-restriction-2257": "Questa immagine contiene del contenuto sessualmente esplicito che potrebbe essere soggetto al Child Protection and Obscenity Enforcement Act negli Stati Uniti.",
+ "multimediaviewer-restriction-aus-reserve": "Questa immagine è stata fotografata in una riserva dello Stato dell'Australia e non può essere utilizzata per scopo commerciali senza autorizzazione.",
+ "multimediaviewer-restriction-communist": "Questa immagine contiene simboli comunisti che potrebbero essere vietati in alcuni paesi.",
+ "multimediaviewer-restriction-costume": "Quest'immagine rappresenta dei costumi e potrebbe essere soggetta a limitazioni legali.",
+ "multimediaviewer-restriction-currency": "Questa immagine rappresenta una raffigurazione di una unità di valuta e può essere soggetta a restrizioni legali.",
+ "multimediaviewer-restriction-design": "Il progetto del soggetto di quest'immagine potrebbe essere protetto dal diritto d'autore e potrebbe essere soggetto a limitazioni legali.",
+ "multimediaviewer-restriction-fan-art": "Quest'immagine contiene del fan art e il riutilizzo potrebbe essere soggetto a limitazioni legali.",
+ "multimediaviewer-restriction-ihl": "Questa immagine contiene simboli soggetti a restrizioni dalla International Humanitarian Law.",
+ "multimediaviewer-restriction-insignia": "Questa immagine contiene insegne ufficiali che potrebbero essere soggette a limitazioni legali.",
+ "multimediaviewer-restriction-ita-mibac": "Quest'immagine riproduce una proprietà appartenente all'eredità culturale italiana ed è limitata dalla legge italiana.",
+ "multimediaviewer-restriction-nazi": "Questa immagine contiene simboli nazisti o fascisti che potrebbero essere vietati in alcuni paesi.",
+ "multimediaviewer-restriction-personality": "Questa immagine contiene persone che potrebbero avere diritti che limitano legalmente alcuni utilizzi dell'immagine senza consenso.",
+ "multimediaviewer-restriction-trademarked": "Il contenuto di quest'immagine potrebbe essere limitato da leggi sui marchi registrati.",
+ "multimediaviewer-restriction-default": "Questa immagine potrebbe essere limitata da clausole legali fuori dalla legge sul diritto dl'autore. Maggiori dettagli nella pagina di descrizione del file.",
+ "multimediaviewer-restriction-default-and-others": "Questa immagine potrebbe essere ulteriormente limitata da altre clausole legali fuori dalla legge sul diritto d'autore. Maggiori dettagli nella pagina di descrizione del file.",
+ "multimediaviewer-about-mmv": "Informazioni",
+ "multimediaviewer-discuss-mmv": "Discussione",
+ "multimediaviewer-help-mmv": "Aiuto",
+ "multimediaviewer-optout-mmv": "Disattiva Media Viewer",
+ "multimediaviewer-optin-mmv": "Attiva Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Disattiva Media Viewer",
+ "multimediaviewer-optin-pending-mmv": "Sto attivando Media Viewer",
+ "multimediaviewer-optout-help": "Media Viewer non verrà più utilizzato per mostrare immagini. Per riusarlo, clicca sul pulsante \"{{int:multimediaviewer-view-expanded}}\" accanto ad ogni immagine. Poi clicca su \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Sarà usato Media Viewer per mostrare le immagini.",
+ "multimediaviewer-geolocation": "Posizione: $1",
+ "multimediaviewer-reuse-link": "Condividi o incorpora questo file",
+ "multimediaviewer-reuse-loading-placeholder": "Caricamento in corso…",
+ "multimediaviewer-reuse-copy-share": "Seleziona e copia (se supportato) il collegamento per condividere questo file",
+ "multimediaviewer-reuse-copy-embed": "Seleziona e copia (se supportato) il codice per incorporare questo file",
+ "multimediaviewer-share-tab": "Condividi",
+ "multimediaviewer-embed-tab": "Incorpora",
+ "multimediaviewer-download-link": "Scarica questo file",
+ "multimediaviewer-download-preview-link-title": "Visualizza nel browser",
+ "multimediaviewer-download-original-button-name": "Scarica il file originale",
+ "multimediaviewer-download-small-button-name": "Scarica dimensioni piccole",
+ "multimediaviewer-download-medium-button-name": "Scarica dimensioni medie",
+ "multimediaviewer-download-large-button-name": "Scarica dimensioni grandi",
+ "multimediaviewer-link-to-page": "Collegamento alla pagina di descrizione del file.",
+ "multimediaviewer-link-to-file": "Collegamento al file originale.",
+ "multimediaviewer-share-explanation": "Copia e condividi liberamente il collegamento",
+ "multimediaviewer-embed-wt": "Wikitesto",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Usa questo codice per incorporare il file",
+ "multimediaviewer-text-embed-credit-text-bl": "Di $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Di $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Di $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Di $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Collegamento",
+ "multimediaviewer-embed-byline": "Di $1",
+ "multimediaviewer-embed-license": "Con licenza $1.",
+ "multimediaviewer-embed-via": "Tramite $1.",
+ "multimediaviewer-default-embed-dimensions": "Dimensioni miniatura predefinite",
+ "multimediaviewer-original-embed-dimensions": "File originale $1",
+ "multimediaviewer-large-embed-dimensions": "Grande $1",
+ "multimediaviewer-medium-embed-dimensions": "Media $1",
+ "multimediaviewer-small-embed-dimensions": "Piccola $1",
+ "multimediaviewer-description-page-button-text": "Maggiori dettagli per questo file",
+ "multimediaviewer-description-page-popup-text": "Maggiori dettagli per questo file su $1",
+ "multimediaviewer-commons-subtitle": "L'archivio di file multimediali liberi",
+ "multimediaviewer-view-expanded": "Apri in Media Viewer",
+ "multimediaviewer-view-config": "Configurazione",
+ "multimediaviewer-close-popup-text": "Chiudi questo strumento (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Visualizza a schermo intero",
+ "multimediaviewer-defullscreen-popup-text": "Esci da schermo intero",
+ "multimediaviewer-next-image-alt-text": "Mostra l'immagine successiva",
+ "multimediaviewer-prev-image-alt-text": "Mostra l'immagine precedente",
+ "multimediaviewer-title-popup-text": "Descrizione",
+ "multimediaviewer-credit-popup-text": "Informazioni su autore e fonte",
+ "multimediaviewer-title-popup-text-more": "Vedi la descrizione completa",
+ "multimediaviewer-credit-popup-text-more": "Vedi la fonte e l'autore completo",
+ "multimediaviewer-download-attribution-cta-header": "Devi attribuire l'autore",
+ "multimediaviewer-download-optional-attribution-cta-header": "Puoi attribuire l'autore",
+ "multimediaviewer-download-attribution-cta": "Fammi vedere come",
+ "multimediaviewer-download-attribution-copy": "Selezione e copia (se supportato) il testo di attribuzione di questo file",
+ "multimediaviewer-reuse-warning-deletion": "Questo file è considerato per l'eliminazione.",
+ "multimediaviewer-reuse-warning-nonfree": "Questo file non ha una licenza libera.",
+ "multimediaviewer-reuse-warning-noattribution": "Questo file non ha informazioni sull'attribuzione.",
+ "multimediaviewer-reuse-warning-generic": "Controlla i [$1 suoi dettagli] prima di utilizzarlo.",
+ "multimediaviewer-attr-plain": "Normale",
+ "multimediaviewer-options-tooltip": "Attiva o disattiva Media Viewer",
+ "multimediaviewer-options-dialog-header": "Disabilitare Media Viewer?",
+ "multimediaviewer-options-text-header": "Salta questa modalità di visualizzazione per tutti i file.",
+ "multimediaviewer-options-text-body": "Può essere abilitata più tardi dalla pagina del file.",
+ "multimediaviewer-options-learn-more": "Ulteriori informazioni",
+ "multimediaviewer-option-submit-button": "Disattiva Media Viewer",
+ "multimediaviewer-option-cancel-button": "Annulla",
+ "multimediaviewer-disable-confirmation-header": "Hai disabilitato MediaViewer",
+ "multimediaviewer-disable-confirmation-text": "La prossima volta che clicchi su un'anteprima in $1, vedrai direttamente tutti i dettagli del file.",
+ "multimediaviewer-enable-dialog-header": "Attivare Media Viewer?",
+ "multimediaviewer-enable-text-header": "Abilita questa funzionalità di visualizzazione di file multimediali per tutti i file come predefinita.",
+ "multimediaviewer-enable-submit-button": "Attiva Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "Hai abilitato Media Viewer per tutti i file",
+ "multimediaviewer-enable-confirmation-text": "La prossima volta che clicchi su un'anteprima in $1, verrà usato Media Viewer.",
+ "multimediaviewer-enable-alert": "Media Viewer è ora disabilitato",
+ "multimediaviewer-disable-info-title": "Hai disabilitato Media Viewer",
+ "multimediaviewer-disable-info": "Puoi ancora vedere file individuali con Media Viewer.",
+ "multimediaviewer-errorreport-privacywarning": "I dettagli dell'errore sono allegati al report, che sarà visibile pubblicamente. Se non sei a tuo agio con ciò, puoi modificare il report qui sotto e rimuovere tutti i dati che non vuoi condividere."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ja.json b/www/wiki/extensions/MultimediaViewer/i18n/ja.json
new file mode 100644
index 00000000..9093b1d5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ja.json
@@ -0,0 +1,107 @@
+{
+ "@metadata": {
+ "authors": [
+ "Shirayuki",
+ "Whym",
+ "SkyDaisy9",
+ "Sujiniku",
+ "Otokoume"
+ ]
+ },
+ "multimediaviewer-desc": "縮小画像を全画面表示インターフェイス内に拡大表示する",
+ "multimediaviewer-pref": "メディア ビューアー",
+ "multimediaviewer-pref-desc": "この新しいツールは、マルチメディアの表示体験を改善します。縮小画像があるページで、その画像をより大きなサイズで表示します。画像は全画面表示インターフェイスのオーバーレイ内に表示され、完全なサイズで表示させることもできます。",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About メディアビューアー]</span>を有効にする",
+ "multimediaviewer-file-page": "対応するファイル ページに移動",
+ "multimediaviewer-repository-local": "詳細",
+ "multimediaviewer-datetime-created": "作成: $1",
+ "multimediaviewer-datetime-uploaded": "アップロード: $1",
+ "multimediaviewer-credit-fallback": "著者情報を閲覧",
+ "multimediaviewer-metadata-error": "画像の詳細を読み込めませんでした。(エラー: $1)",
+ "multimediaviewer-thumbnail-error": "すみません、ファイルを表示できません",
+ "multimediaviewer-thumbnail-error-report": "問題を報告",
+ "multimediaviewer-license-cc-by-1.0": "CC 表示 1.0",
+ "multimediaviewer-license-cc-sa-1.0": "CC 継承 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC 表示-継承 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC 表示 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC 表示-継承 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC 表示 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC 表示-継承 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC 表示 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC 表示-継承 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC 表示 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC 表示-継承 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC 表示 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC 表示-継承 4.0",
+ "multimediaviewer-license-cc-pd": "パブリック・ドメイン",
+ "multimediaviewer-license-cc-zero": "CC 0",
+ "multimediaviewer-license-pd": "パブリック・ドメイン",
+ "multimediaviewer-license-default": "ライセンスを閲覧",
+ "multimediaviewer-permission-title": "許可の詳細",
+ "multimediaviewer-permission-link": "規約を閲覧",
+ "multimediaviewer-permission-viewmore": "続きを表示",
+ "multimediaviewer-restriction-personality": "この画像には人物が含まれており、同意なしに行われる一定の再利用を制限する権利がその人物にある可能性があります。",
+ "multimediaviewer-restriction-trademarked": "この画像には商標法の対象になる可能性のあるものが含まれています。",
+ "multimediaviewer-restriction-default": "この画像は著作権法以外の法規定により制限を受ける可能性があります。詳細についてはファイル解説ページをご覧ください。",
+ "multimediaviewer-about-mmv": "メディア ビューアーについて",
+ "multimediaviewer-discuss-mmv": "議論",
+ "multimediaviewer-help-mmv": "ヘルプ",
+ "multimediaviewer-optout-mmv": "メディアビューアーを無効にする",
+ "multimediaviewer-optin-mmv": "メディアビューアーを有効にする",
+ "multimediaviewer-optout-pending-mmv": "メディアプレーヤーを無効にしています",
+ "multimediaviewer-optin-pending-mmv": "メディアプレーヤーを有効にしています",
+ "multimediaviewer-optout-help": "今後は画像の表示にメディアビューアーを使用しません。再び使用するには、画像の隣にある「{{int:multimediaviewer-view-expanded}}」ボタンをクリックしてください。さらに「{{int:multimediaviewer-optin-mmv}}」をクリックします。",
+ "multimediaviewer-optin-help": "今後は画像の表示にメディアビューアーを使用します。",
+ "multimediaviewer-geoloc-north": "北緯",
+ "multimediaviewer-geoloc-east": "東経",
+ "multimediaviewer-geoloc-south": "南緯",
+ "multimediaviewer-geoloc-west": "西経",
+ "multimediaviewer-geoloc-coord": "$4$1度$2分$3秒",
+ "multimediaviewer-geoloc-coords": "$1 $2",
+ "multimediaviewer-geolocation": "場所: $1",
+ "multimediaviewer-reuse-link": "このファイルを共有または埋め込む",
+ "multimediaviewer-reuse-loading-placeholder": "読み込み中…",
+ "multimediaviewer-share-tab": "共有",
+ "multimediaviewer-embed-tab": "埋め込み",
+ "multimediaviewer-download-link": "このファイルをダウンロード",
+ "multimediaviewer-download-preview-link-title": "ブラウザーで閲覧",
+ "multimediaviewer-download-original-button-name": "元のファイルをダウンロード",
+ "multimediaviewer-link-to-page": "ファイル解説ページへのリンク",
+ "multimediaviewer-link-to-file": "元ファイルへのリンク",
+ "multimediaviewer-embed-wt": "ウィキテキスト",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-license": "$1 でライセンスされています。",
+ "multimediaviewer-embed-via": "$1 で発表。",
+ "multimediaviewer-default-embed-dimensions": "標準サイズのサムネール",
+ "multimediaviewer-original-embed-dimensions": "元のファイル $1",
+ "multimediaviewer-large-embed-dimensions": "大 $1",
+ "multimediaviewer-medium-embed-dimensions": "中 $1",
+ "multimediaviewer-small-embed-dimensions": "小 $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 ピクセル",
+ "multimediaviewer-description-page-button-text": "このファイルについての詳細を見る",
+ "multimediaviewer-description-page-popup-text": "このファイルについての詳細を$1で見る",
+ "multimediaviewer-commons-subtitle": "フリーなマルチメディアの保管庫",
+ "multimediaviewer-view-expanded": "メディアビューアーで開く",
+ "multimediaviewer-view-config": "配列図",
+ "multimediaviewer-close-popup-text": "このツールを閉じる (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "全画面で表示",
+ "multimediaviewer-defullscreen-popup-text": "全画面表示を終了",
+ "multimediaviewer-title-popup-text": "説明",
+ "multimediaviewer-options-tooltip": "メディアビューアーの有効/無効を切り替える",
+ "multimediaviewer-options-dialog-header": "メディアビューアーを無効にしますか?",
+ "multimediaviewer-options-text-header": "全てのファイルでこの表示機能をスキップします。",
+ "multimediaviewer-options-text-body": "後にファイルの詳細のページからそれを有効にすることができます。",
+ "multimediaviewer-options-learn-more": "詳細",
+ "multimediaviewer-option-submit-button": "メディアビューアーを無効にする",
+ "multimediaviewer-option-cancel-button": "中止",
+ "multimediaviewer-disable-confirmation-header": "メディアビューアーは無効になりました。",
+ "multimediaviewer-disable-confirmation-text": "次回$1のサムネイルをクリックすると、全てのファイルの詳細を直接閲覧できます。",
+ "multimediaviewer-enable-dialog-header": "メディアビューアーを有効にしますか?",
+ "multimediaviewer-enable-text-header": "初期化によりこのメディアの表示機能を全てのファイルで有効にします。",
+ "multimediaviewer-enable-submit-button": " メディアビューアーを有効にする",
+ "multimediaviewer-enable-confirmation-header": "メディアビューアーはすべてのファイルについて有効になりました。",
+ "multimediaviewer-enable-confirmation-text": "次回サムネイルの$1をクリックし, メディアビューアーを使用します。",
+ "multimediaviewer-enable-alert": "メディアビューアーは現在使用できません。",
+ "multimediaviewer-disable-info-title": "メディアビューアーを無効にしました",
+ "multimediaviewer-disable-info": "各ファイルをメディアビューアーで閲覧することもできます。"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/jv.json b/www/wiki/extensions/MultimediaViewer/i18n/jv.json
new file mode 100644
index 00000000..5b8ccb07
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/jv.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "NoiX180"
+ ]
+ },
+ "multimediaviewer-pref": "Panontonan Médhia",
+ "multimediaviewer-optin-pref": "Urubaké <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Panontonan Médhia]</span>",
+ "multimediaviewer-file-page": "Menyang kaca barkas sing magepokan",
+ "multimediaviewer-repository-local": "Rerincèn liyané",
+ "multimediaviewer-datetime-created": "Digawé: $1",
+ "multimediaviewer-datetime-uploaded": "Diunggah: $1",
+ "multimediaviewer-credit-fallback": "Deleng katerangan pangripta",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|pangripta siji liyané|pangripta $1 liyané}}",
+ "multimediaviewer-multiple-authors-combine": "$1 lan $2",
+ "multimediaviewer-metadata-error": "Ora bisa ngamot rerincèn gambar (masalah: $1)",
+ "multimediaviewer-thumbnail-error": "Nyuwun pangapura, barkasé ora bisa ditonton",
+ "multimediaviewer-thumbnail-error-description": "Kayané ana masalah tèhnis. Panjenengan bisa $1 utawa $3 yèn masalahé isih ana. Masalah: $2",
+ "multimediaviewer-thumbnail-error-retry": "jajal manèh",
+ "multimediaviewer-thumbnail-error-report": "lapuraké masalahé",
+ "multimediaviewer-license-cc-pd": "Kukuban Umum",
+ "multimediaviewer-license-pd": "Kukuban Umum",
+ "multimediaviewer-license-default": "Deleng lisènsi",
+ "multimediaviewer-permission-title": "Rerincèn bab palilah",
+ "multimediaviewer-permission-link": "deleng paugeran",
+ "multimediaviewer-permission-link-hide": "dhelikaké paugeran",
+ "multimediaviewer-permission-viewmore": "Tuduhaké liyané",
+ "multimediaviewer-about-mmv": "Ngenani",
+ "multimediaviewer-discuss-mmv": "Parembugan",
+ "multimediaviewer-help-mmv": "Pitulung",
+ "multimediaviewer-optout-mmv": "Patèni Panontonan Médhia",
+ "multimediaviewer-optin-mmv": "Urubaké Panontonan Médhia",
+ "multimediaviewer-optout-pending-mmv": "Matèni Panontonan Médhia",
+ "multimediaviewer-optin-pending-mmv": "Ngurubaké Panontonan Médhia",
+ "multimediaviewer-view-expanded": "Bukak ing Panontonan Médhia"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ka.json b/www/wiki/extensions/MultimediaViewer/i18n/ka.json
new file mode 100644
index 00000000..15782e83
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ka.json
@@ -0,0 +1,58 @@
+{
+ "@metadata": {
+ "authors": [
+ "Otogi",
+ "David1010",
+ "MIKHEIL",
+ "Chavch"
+ ]
+ },
+ "multimediaviewer-pref": "მედია დამთვალიერებელი",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About მედია-მაყურებლის]</span> ჩართვა",
+ "multimediaviewer-repository-local": "დამატებითი ინფორმაცია",
+ "multimediaviewer-datetime-created": "შეიქმნა: $1",
+ "multimediaviewer-datetime-uploaded": "ატვირთულია: $1",
+ "multimediaviewer-credit-fallback": "ავტორის ინფოს ნახვა",
+ "multimediaviewer-metadata-error": "სურათის ჩატვირთვა ვერ მოხერხდა (შეცდომა: $1)",
+ "multimediaviewer-thumbnail-error": "სამწუხაროდ, ამ ფაილის ჩვენება შეუძლებელია",
+ "multimediaviewer-thumbnail-error-retry": "ხელახლა ცდა",
+ "multimediaviewer-license-cc-pd": "საზოგადოებრივი საკუთრება",
+ "multimediaviewer-license-pd": "საზოგადოებრივი საკუთრება",
+ "multimediaviewer-license-default": "ლიცენზიის ხილვა",
+ "multimediaviewer-permission-title": "ნებართვის დეტალები",
+ "multimediaviewer-permission-link": "პირობების ხილვა",
+ "multimediaviewer-permission-link-hide": "პირობების დამალვა",
+ "multimediaviewer-permission-viewmore": "იხილეთ მეტი",
+ "multimediaviewer-discuss-mmv": "მოცემული გვერდის განხილვა",
+ "multimediaviewer-help-mmv": "დახმარება",
+ "multimediaviewer-geolocation": "მდებარეობა: $1",
+ "multimediaviewer-reuse-loading-placeholder": "იტვირთება...",
+ "multimediaviewer-share-tab": "გაზიარება",
+ "multimediaviewer-embed-tab": "ჩასმა",
+ "multimediaviewer-download-link": "ამ ფაილის ჩამოტვირთვა",
+ "multimediaviewer-download-preview-link-title": "ბრაუზერში გახსნა",
+ "multimediaviewer-download-original-button-name": "თავდაპირველი ფაილის ჩამოტვირთვა",
+ "multimediaviewer-download-small-button-name": "მცირე ზომის ჩამოტვირთვა",
+ "multimediaviewer-download-medium-button-name": "საშუალო ზომის ჩამოტვირთვა",
+ "multimediaviewer-download-large-button-name": "დიდი ზომის ჩამოტვირთვა",
+ "multimediaviewer-link-to-page": "ფაილი აღწერის გვერდის ბმული",
+ "multimediaviewer-link-to-file": "თავდაპირველი ფაილის ბმული",
+ "multimediaviewer-embed-wt": "ვიკიტექსტი",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-large-embed-dimensions": "დიდი $1",
+ "multimediaviewer-medium-embed-dimensions": "საშუალო $1",
+ "multimediaviewer-small-embed-dimensions": "პატარა $1",
+ "multimediaviewer-view-config": "კონფიგურაცია",
+ "multimediaviewer-close-popup-text": "ამ ხელსაწყოს დახურვა (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "მთელ ეკრანზე ჩვენება",
+ "multimediaviewer-defullscreen-popup-text": "მთლიანი ეკრანიდან გამოსვლა",
+ "multimediaviewer-title-popup-text": "აღწერა",
+ "multimediaviewer-credit-popup-text": "ავტორი და წყაროს ინფორმაცია",
+ "multimediaviewer-title-popup-text-more": "სრული აღწერის ხილვა",
+ "multimediaviewer-credit-popup-text-more": "ავტორისა და წყაროს სრულად ხილვა",
+ "multimediaviewer-download-optional-attribution-cta-header": "შეგიძლიათ მიუთითოთ ავტორი",
+ "multimediaviewer-download-attribution-cta": "მაჩვენეთ, როგორ",
+ "multimediaviewer-attr-plain": "მარტივი",
+ "multimediaviewer-options-learn-more": "გაიგეთ მეტი",
+ "multimediaviewer-option-cancel-button": "გაუქმება"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/kk-cyrl.json b/www/wiki/extensions/MultimediaViewer/i18n/kk-cyrl.json
new file mode 100644
index 00000000..a66ec807
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/kk-cyrl.json
@@ -0,0 +1,91 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arystanbek",
+ "Габдулгани НИШ ХБН"
+ ]
+ },
+ "multimediaviewer-desc": "Толық экранды интерфейсте шағын суреттерді өлшемін үлкенірек етіп кеңейту",
+ "multimediaviewer-pref": "Медиа қарап шығу құралы",
+ "multimediaviewer-pref-desc": "Өзіңіздің мультимедиа көру мүмкіндігіңізді мына жаңа құралмен жетілдіріп көріңіз. Ол шағын суреті (thumbnail) бар беттердегі суреттерді үлкенірек өлшемде көрсетеді.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Медиа қараушыны]</span> қосу",
+ "multimediaviewer-file-page": "Тиісті файл бетіне өту",
+ "multimediaviewer-repository-local": "Көбірек егжей-тегжейі",
+ "multimediaviewer-datetime-created": "Құрылған кезі: $1",
+ "multimediaviewer-datetime-uploaded": "Жүктелген кезі: $1",
+ "multimediaviewer-credit-fallback": "Авторы туралы мәліметті қарау",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|бірден көп авторы|$1 автордан көбірек}}",
+ "multimediaviewer-multiple-authors-combine": "$1 және $2",
+ "multimediaviewer-metadata-error": "Сурет деректері жүктелмеді (қате: $1)",
+ "multimediaviewer-thumbnail-error": "Кешіріңіз, файл көрсетілмеді",
+ "multimediaviewer-thumbnail-error-retry": "Қайталау",
+ "multimediaviewer-license-cc-pd": "Қоғамдық қазына",
+ "multimediaviewer-license-pd": "Қоғамдық қазына",
+ "multimediaviewer-license-default": "Лицензиясын қарау",
+ "multimediaviewer-permission-title": "Рұқсат егжей-тегжейі",
+ "multimediaviewer-permission-link": "шарттарын қарау",
+ "multimediaviewer-permission-link-hide": "Шарттарды жасыру",
+ "multimediaviewer-permission-viewmore": "Көбірек қарау",
+ "multimediaviewer-about-mmv": "Медиа қарап шығу құралы туралы",
+ "multimediaviewer-discuss-mmv": "Бұл мүмкіндікті талқылау",
+ "multimediaviewer-help-mmv": "Анықтама",
+ "multimediaviewer-optout-mmv": "Медиа қараушыны сөндіру",
+ "multimediaviewer-optin-mmv": "Медиа қараушыны қосу",
+ "multimediaviewer-optout-pending-mmv": "Медиа қараушы өшірілуде",
+ "multimediaviewer-optin-pending-mmv": "Медиа қараушы қосылуда",
+ "multimediaviewer-optin-help": "Медиа қараушыны суреттерді көрсетуге қолданылады.",
+ "multimediaviewer-geolocation": "Мекені: $1",
+ "multimediaviewer-reuse-link": "Бұл файлды бөлісу және ендіру",
+ "multimediaviewer-reuse-loading-placeholder": "Жүктелуде...",
+ "multimediaviewer-share-tab": "Бөлісу",
+ "multimediaviewer-embed-tab": "Ендіру",
+ "multimediaviewer-download-link": "Бұл файлды түсіріп алу",
+ "multimediaviewer-download-preview-link-title": "Броузермен қарау",
+ "multimediaviewer-download-original-button-name": "Түпнұсқа файлды түсіріп алу",
+ "multimediaviewer-download-small-button-name": "Кішкене өлшемін түсіріп алу",
+ "multimediaviewer-download-medium-button-name": "Орташа өлшемін түсіріп алу",
+ "multimediaviewer-download-large-button-name": "Үлкен өлшемін түсіріп алу",
+ "multimediaviewer-link-to-page": "Файл сипаттама бетіне сілтеу",
+ "multimediaviewer-link-to-file": "Тұпнұсқа файлға сілтеу",
+ "multimediaviewer-share-explanation": "Сілтемені копиялау және бөлісу",
+ "multimediaviewer-embed-wt": "Уикимәтін",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Енгізілген файлға бұл кодты қолдану",
+ "multimediaviewer-embed-byline": "$1 арқылы",
+ "multimediaviewer-embed-license": "$1 лицензиясы аясында",
+ "multimediaviewer-embed-via": "$1 арқылы",
+ "multimediaviewer-default-embed-dimensions": "Әдепкі нобай өлшемі",
+ "multimediaviewer-original-embed-dimensions": "Бастапқы файл $1",
+ "multimediaviewer-large-embed-dimensions": "Үлкен $1",
+ "multimediaviewer-medium-embed-dimensions": "Орташа $1",
+ "multimediaviewer-small-embed-dimensions": "Кіші $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 px",
+ "multimediaviewer-description-page-button-text": "Бұл файл туралы толығырақ",
+ "multimediaviewer-description-page-popup-text": "$1 жобасынан көбірек егжей-тегжейін көру",
+ "multimediaviewer-commons-subtitle": "Ашық медиа қоры",
+ "multimediaviewer-view-expanded": "Кеңейтіп көру",
+ "multimediaviewer-view-config": "Құрылымы",
+ "multimediaviewer-close-popup-text": "Бұл құралды жабу (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Толық экранда көру",
+ "multimediaviewer-defullscreen-popup-text": "Толық экраннан шығу",
+ "multimediaviewer-title-popup-text": "Сипаттамасы",
+ "multimediaviewer-credit-popup-text": "Автор және қайнар мәліметі",
+ "multimediaviewer-title-popup-text-more": "Толық сипаттамасын қарау",
+ "multimediaviewer-credit-popup-text-more": "Авторын және қайнарын толық қарау",
+ "multimediaviewer-download-optional-attribution-cta-header": "Авторын анықтай аласыз",
+ "multimediaviewer-download-attribution-cta": "Қалай екенін маған көрсет",
+ "multimediaviewer-attr-plain": "Жәй мәтін",
+ "multimediaviewer-options-tooltip": "Медиа қараушыны қосу не өшіру",
+ "multimediaviewer-options-dialog-header": "Медиа қараушыны өшіресіз бе?",
+ "multimediaviewer-options-text-header": "Барлық файлдар үшін бұл қарапшығу функциясын өшіру",
+ "multimediaviewer-options-learn-more": "Көбірек білу",
+ "multimediaviewer-option-submit-button": "Медиа қараушыны сөндіру",
+ "multimediaviewer-option-cancel-button": "Қажет емес",
+ "multimediaviewer-disable-confirmation-header": "Медиа қараушыны өшірдіңіз",
+ "multimediaviewer-enable-dialog-header": "Медиа қараушыны іске қосасыз ба?",
+ "multimediaviewer-enable-submit-button": "Медиа қараушыны қосу",
+ "multimediaviewer-enable-confirmation-header": "Барлық файлдар үшін Медиа қараушыны іске қосқансыз",
+ "multimediaviewer-enable-alert": "Медиа қараушы қаізр өшірілген",
+ "multimediaviewer-disable-info-title": "Медиа қараушыны өшіргенсіз",
+ "multimediaviewer-disable-info": "Медиа қарап шығушымен жеке файлдарды қарай аласыз"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/km.json b/www/wiki/extensions/MultimediaViewer/i18n/km.json
new file mode 100644
index 00000000..1c26fd73
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/km.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "វ័ណថារិទ្ធ"
+ ]
+ },
+ "multimediaviewer-repository-local": "ស្វែងយល់បន្ថែម"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/kn.json b/www/wiki/extensions/MultimediaViewer/i18n/kn.json
new file mode 100644
index 00000000..84d4d358
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/kn.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Vikassy",
+ "Pavanaja",
+ "Nayvik"
+ ]
+ },
+ "multimediaviewer-desc": "ಚಿಕ್ಕ ಚಿತ್ರವನ್ನು ಪೂರ್ತಿ ಪರದೆಗೆ ದೊಡ್ಡದು ಮಾಡಿ",
+ "multimediaviewer-pref": "ಮೀಡಿಯಾ ವ್ಯೂವರ್",
+ "multimediaviewer-pref-desc": "ನಿಮ್ಮ ಬಹುಮಾಧ‍್ಯಮ ವೀಕ್ಷಣೆಯ ಅನುಭವವನ್ನು ಈ ಸಾಧನ ಬಳಸಿ ಸುಧಾರಿಸಿಕೊಳ್ಳಿ. ಚಿಕ್ಕ ಚಿತ್ರಗಳಿರುವ ಪುಟಗಳಲ್ಲಿಯ ಚಿತ್ರಗಳನ್ನು ಇದು ದೊಡ್ಡದು ಮಾಡಿ ತೋರಿಸುತ್ತದೆ. ಚಿತ್ರಗಳನ್ನು ಪೂರ್ಣಪರದೆಯಲ್ಲಿ ತೋರಿಸುತ್ತದೆ.",
+ "multimediaviewer-optin-pref": "ಬಹುಮಾಧ್ಯಮ ವೀಕ್ಷಣೆಯ ಹೊಸ ಅನುಭವವನ್ನು ಸಕ್ರಿಯಗೊಳಿಸಿ",
+ "multimediaviewer-file-page": "ಸಂಬಂಧಪಟ್ಟ ಫೈಲ್ ಪುಟಕ್ಕೆ ಹೋಗಿ",
+ "multimediaviewer-repository-local": "ಇನ್ನಷ್ಟು ತಿಳಿಯಿರಿ",
+ "multimediaviewer-datetime-created": "$1 ರಂದು ತಯಾರಿಸಿದ್ದು",
+ "multimediaviewer-datetime-uploaded": "$1 ರಂದು ಸೇರಿಸಿದ್ದು",
+ "multimediaviewer-metadata-error": "$1 ದೋಷ: ಚಿತ್ರದ ಮಾಹಿತಿಯನ್ನು ತೆರೆಯಲು ಆಗಲಿಲ್ಲ",
+ "multimediaviewer-thumbnail-error": "$1 ದೋಷ: ಚಿಕ್ಕಚಿತ್ರ ಸೇರಿಸಲು ಆಗಲಿಲ್ಲ",
+ "multimediaviewer-license-cc-pd": "ಸಾರ್ವಜನಿಕರಿಗೆ ಸೇರಿದ್ದು",
+ "multimediaviewer-license-pd": "ಸಾರ್ವಜನಿಕರಿಗೆ ಸೇರಿದ್ದು",
+ "multimediaviewer-license-default": "ಪರವಾನಗಿ ವೀಕ್ಷಿಸಿ",
+ "multimediaviewer-permission-title": "ಪರವಾನಗಿಯ ವಿವರಗಳು",
+ "multimediaviewer-permission-link": "ಶರತ್ತುಗಳನ್ನು ವೀಕ್ಷಿಸಿ",
+ "multimediaviewer-permission-viewmore": "ಹೆಚ್ಚಿನದ್ದನ್ನು ವೀಕ್ಷಿಸಿ",
+ "multimediaviewer-about-mmv": "ಮೀಡಿಯಾ ವ್ಯೂವರ್ ಬಗ್ಗೆ",
+ "multimediaviewer-discuss-mmv": "ಈ ಗುಣವೈಶಿಷ್ಟ್ಯವನ್ನು ಚರ್ಚಿಸಿ",
+ "multimediaviewer-help-mmv": "ಸಹಾಯ",
+ "multimediaviewer-geolocation": "ಸ್ಥಾನ: $1",
+ "multimediaviewer-reuse-link": "ಈ ಫೈಲನ್ನು ಬಳಸಿ",
+ "multimediaviewer-reuse-loading-placeholder": "ಉತ್ಪೂರಿತವಾಗುತ್ತಿದೆ",
+ "multimediaviewer-share-tab": "ಹಂಚಿ",
+ "multimediaviewer-embed-tab": "ಅಂತರ್ಗತಿಸಿ",
+ "multimediaviewer-download-link": "ಡೌನ್‍ಲೋಡ್",
+ "multimediaviewer-download-preview-link-title": "ಬ್ರೌಸರ್‍ನಲ್ಲಿ ಪೂರ್ವಾವಲೋಕನ",
+ "multimediaviewer-download-original-button-name": "ಮೂಲಗಾತ್ರದಲ್ಲಿ ಡೌನ್‍ಲೋಡ್ ಮಾಡಿ",
+ "multimediaviewer-download-small-button-name": "ಚಿಕ್ಕಗಾತ್ರದಲ್ಲಿ ಡೌನ್‍ಲೋಡ್ ಮಾಡಿ",
+ "multimediaviewer-download-medium-button-name": "ಮಧ್ಯಮ ಗಾತ್ರದಲ್ಲಿ ಡೌನ್‍ಲೋಡ್ ಮಾಡಿ",
+ "multimediaviewer-download-large-button-name": "ದೊಡ್ಡಗಾತ್ರದಲ್ಲಿ ಡೌನ್‍ಲೋಡ್ ಮಾಡಿ",
+ "multimediaviewer-link-to-page": "ಫೈಲ್ ವಿವರಣೆ ಪುಟಕ್ಕೆ ಕೊಂಡಿ",
+ "multimediaviewer-link-to-file": "ಮೂಲಫೈಲ್‍ಗೆ ಕೊಂಡಿ",
+ "multimediaviewer-share-explanation": "ಕೊಂಡಿಯನ್ನು ನಕಲಿಸಿ ಮತ್ತು ಎಲ್ಲರಿಗೂ ಹಂಚಿ",
+ "multimediaviewer-embed-wt": "ವಿಕಿಪಠ್ಯ",
+ "multimediaviewer-embed-html": "ಎಚ್‍ಟಿಎಂಎಲ್",
+ "multimediaviewer-embed-explanation": "ಫೈಲನ್ನು ಅಂತರ್ಗತಿಸಲು ಈ ಕೋಡ್ ಅನ್ನು ಬಳಸಿ",
+ "multimediaviewer-description-page-button-text": "ಹೆಚ್ಚಿನ ವಿವರಗಳು",
+ "multimediaviewer-description-page-popup-text": "ಹೆಚ್ಚಿನ ವಿವರಗಳು $1 ರಲ್ಲಿ",
+ "multimediaviewer-commons-subtitle": "ಉಚಿತ ಮಾಧ್ಯಮ ಕಣಜ",
+ "multimediaviewer-view-expanded": "ಹಿಗ್ಗಿದ ವೀಕ್ಷಣೆ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ko.json b/www/wiki/extensions/MultimediaViewer/i18n/ko.json
new file mode 100644
index 00000000..3303f999
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ko.json
@@ -0,0 +1,77 @@
+{
+ "@metadata": {
+ "authors": [
+ "Freebiekr",
+ "Hym411",
+ "Jskang",
+ "Priviet",
+ "아라",
+ "Keysuck",
+ "Revi",
+ "IRTC1015",
+ "Hwangjy9",
+ "Ykhwong",
+ "Jerrykim306"
+ ]
+ },
+ "multimediaviewer-desc": "섬네일을 전체 화면 인터페이스에서 더 큰 크기로 확장합니다.",
+ "multimediaviewer-pref": "미디어 뷰어",
+ "multimediaviewer-pref-desc": "이 새 도구로 멀티미디어를 보는 경험을 개선하세요. 이 도구는 섬네일이 있는 문서에서 그림을 더 크게 보여줍니다. 그림은 화면 위에 보기 편리한 전체 화면 인터페이스 안에 표시되며 전체 크기로 볼 수도 있습니다.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About 미디어 뷰어]</span> 사용",
+ "multimediaviewer-file-page": "해당 파일 문서로 가기",
+ "multimediaviewer-repository-local": "자세한 내용",
+ "multimediaviewer-datetime-created": "만듦: $1",
+ "multimediaviewer-datetime-uploaded": "올림: $1",
+ "multimediaviewer-metadata-error": "오류: 그림 데이터를 불러오지 못했습니다. $1",
+ "multimediaviewer-thumbnail-error": "죄송합니다. 이 파일을 표시할 수 없습니다.",
+ "multimediaviewer-thumbnail-error-description": "기술적 문제인 것 같습니다. 문제가 지속되는 경우 $1하거나 $3할 수 있습니다. 오류: $2",
+ "multimediaviewer-license-cc-pd": "퍼블릭 도메인",
+ "multimediaviewer-license-pd": "퍼블릭 도메인",
+ "multimediaviewer-license-default": "라이선스 보기",
+ "multimediaviewer-permission-title": "이용허락 세부 사항",
+ "multimediaviewer-permission-link": "이용 약관 보기",
+ "multimediaviewer-permission-viewmore": "더 보기",
+ "multimediaviewer-about-mmv": "정보",
+ "multimediaviewer-discuss-mmv": "토론",
+ "multimediaviewer-help-mmv": "도움말",
+ "multimediaviewer-geoloc-north": "북",
+ "multimediaviewer-geoloc-east": "동",
+ "multimediaviewer-geoloc-south": "남",
+ "multimediaviewer-geoloc-west": "서",
+ "multimediaviewer-geolocation": "위치: $1",
+ "multimediaviewer-reuse-link": "이 파일 공유 또는 삽입",
+ "multimediaviewer-reuse-loading-placeholder": "불러오는 중…",
+ "multimediaviewer-share-tab": "공유",
+ "multimediaviewer-embed-tab": "포함하기",
+ "multimediaviewer-download-link": "이 파일을 다운로드",
+ "multimediaviewer-download-preview-link-title": "브라우저에서 보기",
+ "multimediaviewer-download-original-button-name": "원본 파일 다운로드",
+ "multimediaviewer-download-small-button-name": "작은 크기 다운로드",
+ "multimediaviewer-download-medium-button-name": "중간 크기 다운로드",
+ "multimediaviewer-download-large-button-name": "큰 크기 다운로드",
+ "multimediaviewer-link-to-page": "파일 설명 문서로 연결",
+ "multimediaviewer-link-to-file": "원본 파일로 연결",
+ "multimediaviewer-share-explanation": "링크를 복사하고 자유롭게 공유하기",
+ "multimediaviewer-embed-wt": "위키텍스트",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "파일을 포함하려면 이 코드 사용",
+ "multimediaviewer-html-embed-credit-link-text": "링크",
+ "multimediaviewer-embed-byline": "$1 만듦",
+ "multimediaviewer-embed-license": "$1로 라이선스됨.",
+ "multimediaviewer-embed-via": "$1을(를) 통해.",
+ "multimediaviewer-default-embed-dimensions": "기본 섬네일 크기",
+ "multimediaviewer-original-embed-dimensions": "원본 파일 $1",
+ "multimediaviewer-large-embed-dimensions": "큰 크기 $1",
+ "multimediaviewer-medium-embed-dimensions": "중간 크기 $1",
+ "multimediaviewer-small-embed-dimensions": "작은 크기 $1",
+ "multimediaviewer-description-page-button-text": "이 파일의 자세한 내용",
+ "multimediaviewer-description-page-popup-text": "$1의 자세한 내용",
+ "multimediaviewer-commons-subtitle": "자유 미디어 저장소",
+ "multimediaviewer-view-expanded": "미디어 뷰어에서 열기",
+ "multimediaviewer-next-image-alt-text": "다음 사진 보이기",
+ "multimediaviewer-prev-image-alt-text": "이전 사진 보이기",
+ "multimediaviewer-reuse-warning-deletion": "이 파일은 삭제를 고려하고 있습니다.",
+ "multimediaviewer-reuse-warning-nonfree": "이 파일은 자유 라이선스가 아닙니다.",
+ "multimediaviewer-reuse-warning-noattribution": "이 파일에 속성 정보가 없습니다.",
+ "multimediaviewer-reuse-warning-generic": "사용하기 전에 [$1 상세 내용]을 확인하십시오."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/krc.json b/www/wiki/extensions/MultimediaViewer/i18n/krc.json
new file mode 100644
index 00000000..f10b3f21
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/krc.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Iltever",
+ "Ernác"
+ ]
+ },
+ "multimediaviewer-pref": "Медиа-къаратыучу",
+ "multimediaviewer-pref-desc": "Мультимедиа-файллагъа къарауну джангы адыр бла игилендиреди. Суратны эскизи кёрюннген бетде эскизлени уллу суратлача кёргюзеди. Суратла андан да ариу толуэкранлы интерфейсде кёрюнедиле эмда оригинал разрешениесинде ачылыргъа боллукъдула.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Медиа-къараучуну]</span> джандыр",
+ "multimediaviewer-optout-mmv": "Медиа-къараучуну джукълатыу",
+ "multimediaviewer-optin-mmv": "Медиа-къараучуну джандыр",
+ "multimediaviewer-optout-pending-mmv": "Медиа-къараучуну джукълатыу",
+ "multimediaviewer-optin-pending-mmv": "Медиа-къараучуну джандырыу",
+ "multimediaviewer-enable-dialog-header": "Медиа-къараучу джандырылсынмы?",
+ "multimediaviewer-enable-submit-button": "Медиа-къараучуну джандыр"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ksh.json b/www/wiki/extensions/MultimediaViewer/i18n/ksh.json
new file mode 100644
index 00000000..169a25f1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ksh.json
@@ -0,0 +1,63 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha"
+ ]
+ },
+ "multimediaviewer-repository-local": "Mih Einzelheijte",
+ "multimediaviewer-datetime-created": "Aanjelaat: $1",
+ "multimediaviewer-datetime-uploaded": "Huhjelahde: $1",
+ "multimediaviewer-credit-fallback": "Dahte övver dä Schrihver belohre",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|norr_enne|noch $1 mih Schrihver|un söns keine}} Schrihver",
+ "multimediaviewer-multiple-authors-combine": "$1 un $2",
+ "multimediaviewer-metadata-error": "Mer kunnte kein Eijnzeljeijte övver dat bed lahde, der Jrond: $1",
+ "multimediaviewer-thumbnail-error-retry": "norr_ens versöhke",
+ "multimediaviewer-thumbnail-error-report": "donn dat mällde",
+ "multimediaviewer-license-cc-pd": "Allmende (jemeinfrei, <i lang=\"en\">public domain</i>)",
+ "multimediaviewer-license-pd": "Allmende (jemeinfrei, <i lang=\"en\">public domain</i>)",
+ "multimediaviewer-license-default": "De Lezänz beraache",
+ "multimediaviewer-permission-title": "Einzelheijte övver et Jebruche",
+ "multimediaviewer-permission-viewmore": "Mih aanzeije",
+ "multimediaviewer-about-mmv": "Övver",
+ "multimediaviewer-discuss-mmv": "Klaaf",
+ "multimediaviewer-help-mmv": "Hölp",
+ "multimediaviewer-geolocation": "Posizjuhn: $1",
+ "multimediaviewer-reuse-link": "Donn heh di dattei wigger jävve udder woh ennboue",
+ "multimediaviewer-reuse-loading-placeholder": "Ben am Lahde&nbsp;…",
+ "multimediaviewer-share-tab": "Wigger jävve",
+ "multimediaviewer-embed-tab": "Ennföhje",
+ "multimediaviewer-download-link": "Heh di Dattei eronger lahde",
+ "multimediaviewer-download-preview-link-title": "Em Brauser opmaache",
+ "multimediaviewer-download-original-button-name": "Donn de Ojinahl_Dattei eronger lahde",
+ "multimediaviewer-download-small-button-name": "Donn en verkleijnerte Väsjohn vun dä Dattei eronger lahde",
+ "multimediaviewer-download-medium-button-name": "Donn en meddeljruhße Väsjohn vun dä Dattei eronger lahde",
+ "multimediaviewer-download-large-button-name": "Donn en jruhße Väsjohn vun dä Dattei eronger lahde",
+ "multimediaviewer-link-to-file": "Lengk op di Ojjinahl_Dattei",
+ "multimediaviewer-embed-wt": "Wikkitäx",
+ "multimediaviewer-embed-html": "\n<i lang=\"en\" xml:lang=\"en\" dir=\"ltr\" title=\"HyperText Markup Language\">HTML</i>",
+ "multimediaviewer-embed-explanation": "Nemm heh dä Kohd, öm di Dattei ennzebenge",
+ "multimediaviewer-embed-byline": "Vum $1",
+ "multimediaviewer-embed-license": "Veröffentlesch onger dä Lezänz $1.",
+ "multimediaviewer-embed-via": "Övver $1",
+ "multimediaviewer-default-embed-dimensions": "Schtandatt_Jrühße vum Minnibelldsche",
+ "multimediaviewer-original-embed-dimensions": "Ojinal_Dattei $1",
+ "multimediaviewer-large-embed-dimensions": "Jruhß $1",
+ "multimediaviewer-medium-embed-dimensions": "Meddel $1",
+ "multimediaviewer-small-embed-dimensions": "Klein $1",
+ "multimediaviewer-description-page-button-text": "Mih Einzelheijte övver heh di Dattei",
+ "multimediaviewer-description-page-popup-text": "Mih Einzelheijte övver heh di Dattei op $1",
+ "multimediaviewer-commons-subtitle": "Dat freije Repossetohrejom för Mehdije",
+ "multimediaviewer-view-config": "Enschtällonge",
+ "multimediaviewer-close-popup-text": "Maach heh dat Wärkzüsch zuoh (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Om jannze Beldscherrem zeije",
+ "multimediaviewer-defullscreen-popup-text": "Nimmih om jannze Beldscherrem zeije",
+ "multimediaviewer-title-popup-text": "Aanjahbe övver di Dattei",
+ "multimediaviewer-credit-popup-text": "Övver de Hääkonnef vun dä dattei",
+ "multimediaviewer-title-popup-text-more": "Ale Aanjahbe belohre",
+ "multimediaviewer-credit-popup-text-more": "Alles övver der Könsler un de Quäll",
+ "multimediaviewer-download-attribution-cta-header": "Do moß der Maacher nänne",
+ "multimediaviewer-download-attribution-cta": "Zeijsch mer, wi",
+ "multimediaviewer-attr-plain": "Pladd un eijfach",
+ "multimediaviewer-options-learn-more": "Mih lässe",
+ "multimediaviewer-option-cancel-button": "Ophühre"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ku-latn.json b/www/wiki/extensions/MultimediaViewer/i18n/ku-latn.json
new file mode 100644
index 00000000..43a1409c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ku-latn.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bikarhêner",
+ "Ghybu"
+ ]
+ },
+ "multimediaviewer-about-mmv": "Derbar",
+ "multimediaviewer-option-cancel-button": "Betal bike"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/lb.json b/www/wiki/extensions/MultimediaViewer/i18n/lb.json
new file mode 100644
index 00000000..9f9d185e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/lb.json
@@ -0,0 +1,91 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robby"
+ ]
+ },
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-optin-pref": "De <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span> aktivéieren",
+ "multimediaviewer-repository-local": "Méi Detailer",
+ "multimediaviewer-datetime-uploaded": "Eropgelueden: $1",
+ "multimediaviewer-credit-fallback": "Informatioune vum Auteur weisen",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ee weideren Auteur|$1 weider Auteuren}}",
+ "multimediaviewer-multiple-authors-combine": "$1 a(n) $2",
+ "multimediaviewer-metadata-error": "Detailer vum Bild konten net geluede ginn (Feeler: $1)",
+ "multimediaviewer-thumbnail-error-retry": "Nach eng Kéier probéieren",
+ "multimediaviewer-thumbnail-error-report": "de Problem mellen",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-pd": "Ëffentlechen Domaine",
+ "multimediaviewer-license-default": "Lizenz weisen",
+ "multimediaviewer-permission-title": "Detailer vun der Erlaabnes",
+ "multimediaviewer-permission-link-hide": "Konditioune verstoppen",
+ "multimediaviewer-permission-viewmore": "Méi weisen",
+ "multimediaviewer-restriction-communist": "Op dësem Bild si kommunistesch Symboler déi verschiddene Länner kéinte verbuede sinn.",
+ "multimediaviewer-restriction-currency": "Dës Bild ass eng Duerstellung vun enger Währungseenheet an ënnerläit méiglecherweis legale Limitatiounen.",
+ "multimediaviewer-restriction-ihl": "Op dësem Bild si Symboler déi duerch dat internationaalt humanitärt Recht geschützt sinn.",
+ "multimediaviewer-restriction-insignia": "Op dësem Bild sinn offiziell Logoen déi eventuell den Objet vu rechtleche Limitatiounen si kéinten.",
+ "multimediaviewer-restriction-nazi": "Op dësem Bild si Nazi- oder aner faschistesch Symboler déi an eenzelne Länner kéinte verbuede sinn.",
+ "multimediaviewer-about-mmv": "Iwwer",
+ "multimediaviewer-discuss-mmv": "Diskussioun",
+ "multimediaviewer-help-mmv": "Hëllef",
+ "multimediaviewer-optout-mmv": "Media Viewer ausschalten",
+ "multimediaviewer-optin-mmv": "Media Viewer aktivéieren",
+ "multimediaviewer-optout-pending-mmv": "Media Viewer desaktivéieren",
+ "multimediaviewer-optin-pending-mmv": "Media Viewer aktivéieren",
+ "multimediaviewer-optin-help": "Media Viewer gëtt benotzt fir Biller ze weisen.",
+ "multimediaviewer-geolocation": "Plaz: $1",
+ "multimediaviewer-reuse-link": "Dëse Fichier deelen oder abannen",
+ "multimediaviewer-reuse-loading-placeholder": "Lueden...",
+ "multimediaviewer-share-tab": "Deelen",
+ "multimediaviewer-embed-tab": "Abannen",
+ "multimediaviewer-download-link": "Dëse Fichier eroflueden",
+ "multimediaviewer-download-preview-link-title": "Am Browser weisen",
+ "multimediaviewer-download-original-button-name": "Originalfichier eroflueden",
+ "multimediaviewer-download-small-button-name": "Kleng Gréisst eroflueden",
+ "multimediaviewer-download-medium-button-name": "Mëttel Gréisst eroflueden",
+ "multimediaviewer-download-large-button-name": "Grouss Gréisst eroflueden",
+ "multimediaviewer-link-to-page": "Link op d'Beschreiwungssäit vum Fichier",
+ "multimediaviewer-link-to-file": "Link op den Originalfichier",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-text-embed-credit-text-bl": "Vum $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Vum $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Vum $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Vum $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Link",
+ "multimediaviewer-embed-byline": "Vum $1",
+ "multimediaviewer-embed-license": "Lizenzéiert ënner $1.",
+ "multimediaviewer-embed-via": "Iwwer $1.",
+ "multimediaviewer-original-embed-dimensions": "Originalfichier $1",
+ "multimediaviewer-large-embed-dimensions": "Grouss $1",
+ "multimediaviewer-medium-embed-dimensions": "Mëttel $1",
+ "multimediaviewer-small-embed-dimensions": "Kleng $1",
+ "multimediaviewer-description-page-button-text": "Méi Detailer iwwer dëse Fichier",
+ "multimediaviewer-description-page-popup-text": "Méi Detailer iwwer dëse Fichier op $1",
+ "multimediaviewer-view-expanded": "Mam Media Viewer opmaachen",
+ "multimediaviewer-view-config": "Astellung",
+ "multimediaviewer-close-popup-text": "Dësen Tool zoumaachen (Esc)",
+ "multimediaviewer-defullscreen-popup-text": "Aus dem ganzen Ecran erausgoen",
+ "multimediaviewer-next-image-alt-text": "Nächst Bild weisen",
+ "multimediaviewer-prev-image-alt-text": "Viregt Bild weisen",
+ "multimediaviewer-title-popup-text": "Beschreiwung",
+ "multimediaviewer-credit-popup-text": "Informatioun iwwer den Auteur an d'Quell",
+ "multimediaviewer-title-popup-text-more": "Kompletten Beschreiwung weisen",
+ "multimediaviewer-credit-popup-text-more": "Weist all Informatiounen iwwer den Auteur an d'Quell",
+ "multimediaviewer-download-attribution-cta-header": "Dir musst eng Referenz op den Auteur maachen",
+ "multimediaviewer-download-attribution-cta": "Weist mir wéi",
+ "multimediaviewer-reuse-warning-deletion": "Et gouf virgeschloen dëse Fichier ze läschen.",
+ "multimediaviewer-reuse-warning-nonfree": "Dëse Fichier huet keng fräi Lizenz.",
+ "multimediaviewer-reuse-warning-noattribution": "Dëse Fichier huet keng Informatiounen iwwer den Auteur.",
+ "multimediaviewer-options-dialog-header": "Media Viewer ausschalten?",
+ "multimediaviewer-options-learn-more": "Fir méi ze wëssen",
+ "multimediaviewer-option-submit-button": "Media Viewer ausschalten",
+ "multimediaviewer-option-cancel-button": "Ofbriechen",
+ "multimediaviewer-disable-confirmation-header": "Dir hutt de Media Viewer ausgeschalt",
+ "multimediaviewer-enable-dialog-header": "Media Viewer aschalten?",
+ "multimediaviewer-enable-submit-button": "Media Viewer aktivéieren",
+ "multimediaviewer-enable-confirmation-header": "Dir hutt de Media Viewer fir all Fichieren ageschalt.",
+ "multimediaviewer-enable-alert": "De Media Viewer ass elo ausgeschalt",
+ "multimediaviewer-disable-info-title": "Dir hutt de MediaViewer ausgeschalt"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/lki.json b/www/wiki/extensions/MultimediaViewer/i18n/lki.json
new file mode 100644
index 00000000..2967e887
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/lki.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lakzon"
+ ]
+ },
+ "multimediaviewer-link-to-page": "پیوند به صفحهٔ توضیحات پرونده",
+ "multimediaviewer-title-popup-text": "توضیحۀل",
+ "multimediaviewer-title-popup-text-more": "مشاهدهٔ کامل توضیحات"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/lrc.json b/www/wiki/extensions/MultimediaViewer/i18n/lrc.json
new file mode 100644
index 00000000..c827bf74
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/lrc.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mogoeilor"
+ ]
+ },
+ "multimediaviewer-repository-local": "بيشتر يا بيئريت"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/lt.json b/www/wiki/extensions/MultimediaViewer/i18n/lt.json
new file mode 100644
index 00000000..94638bc1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/lt.json
@@ -0,0 +1,101 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mantak111",
+ "Robotukas11",
+ "Hugo.arg",
+ "Gediminas",
+ "Eitvys200",
+ "Zygimantus",
+ "Manvydasz"
+ ]
+ },
+ "multimediaviewer-desc": "Išplėsti labiau miniatiūras esant pilno dydžio vartotojo aplinkai.",
+ "multimediaviewer-pref": "Nuotraukų peržvalgos įrankis",
+ "multimediaviewer-optin-pref": "Įjungti <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About nuotraukų peržvalgos programą]</span>",
+ "multimediaviewer-file-page": "Eiti į atitinkamą rinkmenos puslapį",
+ "multimediaviewer-repository-local": "Plačiau",
+ "multimediaviewer-datetime-created": "Sukurta: $1",
+ "multimediaviewer-datetime-uploaded": "Įkelta: $1",
+ "multimediaviewer-credit-fallback": "Žiūrėti informaciją apie autorių",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|dar vienas autorius|dar $1 autoriai|dar $1 autorių}}",
+ "multimediaviewer-metadata-error": "Nepavyksta įkelti vaizdo duomenų (klaida: $1)",
+ "multimediaviewer-thumbnail-error": "Klaida: nepavyksta pakrauti miniatiūros duomenų. $1",
+ "multimediaviewer-thumbnail-error-retry": "bandyti dar kartą",
+ "multimediaviewer-license-cc-pd": "Viešo naudojimo",
+ "multimediaviewer-license-pd": "Viešo naudojimo",
+ "multimediaviewer-license-default": "Žiūrėti licenciją",
+ "multimediaviewer-permission-title": "Leidimo informacija",
+ "multimediaviewer-permission-link": "žiūrėti sąlygas",
+ "multimediaviewer-permission-viewmore": "Rodyti daugiau",
+ "multimediaviewer-about-mmv": "Apie",
+ "multimediaviewer-discuss-mmv": "Aptarimas",
+ "multimediaviewer-help-mmv": "Pagalba",
+ "multimediaviewer-optout-mmv": "Išjungti nuotraukų peržiūros įrankį",
+ "multimediaviewer-optin-mmv": "Įjungti nuotraukų peržvalgos programą",
+ "multimediaviewer-optout-pending-mmv": "Nuotraukų peržiūros įrankis išjungiamas",
+ "multimediaviewer-optin-pending-mmv": "Nuotraukų peržiūros įrankis įjungiamas",
+ "multimediaviewer-optout-help": "Nuotraukų peržiūros įrankis daugiau nebenaudojamas paveikslėlių rodymui. Kad vėl būtų naudojimas, paspauskite \"{{int:multimediaviewer-view-expanded}}\" mygtuką, esantį greta bet kurio paveikslėlio. Tada spauskite \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Nuotraukų peržiūros įrankis bus naudojamas paveikslėlių atvaizdavimui.",
+ "multimediaviewer-geolocation": "Padėtis: $1",
+ "multimediaviewer-reuse-link": "Dalintis arba įterpti šią nuotrauką",
+ "multimediaviewer-reuse-loading-placeholder": "Kraunama...",
+ "multimediaviewer-share-tab": "Dalintis",
+ "multimediaviewer-embed-tab": "Įterpti",
+ "multimediaviewer-download-link": "Atsisiųsti šią nuotrauką",
+ "multimediaviewer-download-preview-link-title": "Peržiūra naršyklėje",
+ "multimediaviewer-download-original-button-name": "Atsisiųsti pradinę rinkmeną",
+ "multimediaviewer-download-small-button-name": "Atsisiųsti mažu dydžiu",
+ "multimediaviewer-download-medium-button-name": "Atsisiųsti vidutiniu dydžiu",
+ "multimediaviewer-download-large-button-name": "Atsisiųsti dideliu dydžiu",
+ "multimediaviewer-link-to-page": "Nuoroda į aprašymo puslapį",
+ "multimediaviewer-link-to-file": "Nuoroda į pirminę rinkmeną",
+ "multimediaviewer-share-explanation": "Kopijuoti ir laisvai dalintis šia nuoroda",
+ "multimediaviewer-embed-wt": "Wiki-tekstas",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Naudokite šį kodą rinkmenos įterpimui",
+ "multimediaviewer-html-embed-credit-link-text": "Nuoroda",
+ "multimediaviewer-embed-byline": "Naudotojo $1 kūrinys",
+ "multimediaviewer-embed-license": "Licencijuotas kaip $1.",
+ "multimediaviewer-embed-via": "Iš tinklavietės $1.",
+ "multimediaviewer-default-embed-dimensions": "Miniatiūros dydis pagal nutylėjimą",
+ "multimediaviewer-original-embed-dimensions": "Pradinio dydžio rinkmena $1",
+ "multimediaviewer-large-embed-dimensions": "Didelis $1",
+ "multimediaviewer-medium-embed-dimensions": "Vidutinis $1",
+ "multimediaviewer-small-embed-dimensions": "Mažas $1",
+ "multimediaviewer-description-page-button-text": "Daugiau duomenų apie šią rinkmeną",
+ "multimediaviewer-description-page-popup-text": "Daugiau duomenų apie šią rinkmeną tinklalapyje $1",
+ "multimediaviewer-commons-subtitle": "Laisvųjų rinkmenų saugykla",
+ "multimediaviewer-view-expanded": "Atverti su nuotraukų peržvalgos įrankiu",
+ "multimediaviewer-view-config": "Sąranga",
+ "multimediaviewer-close-popup-text": "Užverti šį įrankį (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Rodyti per visą ekraną",
+ "multimediaviewer-defullscreen-popup-text": "Panaikinti būseną „per visą ekraną“",
+ "multimediaviewer-next-image-alt-text": "Rodyti kitą vaizdą",
+ "multimediaviewer-prev-image-alt-text": "Rodyti ankstesnį vaizdą",
+ "multimediaviewer-title-popup-text": "Aprašymas",
+ "multimediaviewer-credit-popup-text": "Žinios apie kūrėją ir šaltinį",
+ "multimediaviewer-title-popup-text-more": "Žiūrėti visą aprašymą",
+ "multimediaviewer-credit-popup-text-more": "Žiūrėti visas žinias apie kūrėją ir šaltinį",
+ "multimediaviewer-download-attribution-cta-header": "Jums būtina nurodyti autorių",
+ "multimediaviewer-download-optional-attribution-cta-header": "Jūs galite nurodyti autorių",
+ "multimediaviewer-download-attribution-cta": "Parodyti man, kaip",
+ "multimediaviewer-attr-plain": "Paprastas",
+ "multimediaviewer-options-tooltip": "Įjungti arba išjungti nuotraukų peržvalgos įrankį",
+ "multimediaviewer-options-dialog-header": "Išjungti nuotraukų peržvalgos įrankį?",
+ "multimediaviewer-options-text-header": "Panaikinti šį peržiūros įrankį visoms rinkmenoms.",
+ "multimediaviewer-options-text-body": "Jūs galite jį įjungti vėliau rinkmenų aprašymo puslapyje.",
+ "multimediaviewer-options-learn-more": "Sužinokite daugiau",
+ "multimediaviewer-option-submit-button": "Išjungti nuotraukų peržiūros įrankį",
+ "multimediaviewer-option-cancel-button": "Atšaukti",
+ "multimediaviewer-disable-confirmation-header": "Jūs išjungėte nuotraukų peržiūros įrankį",
+ "multimediaviewer-disable-confirmation-text": "Kitąsyk kai paspausite ant miniatiūros $1 svetainėje, jus nukreips tiesiai į vaizdo aprašymo puslapį.",
+ "multimediaviewer-enable-dialog-header": "Įjungti nuotraukų peržvalgos įrankį?",
+ "multimediaviewer-enable-text-header": "Įjungti šį nuotraukų peržiūros įrankį pagal nutylėjimą visoms rinkmenoms.",
+ "multimediaviewer-enable-submit-button": "Įjungti nuotraukų peržiūros įrankį",
+ "multimediaviewer-enable-confirmation-header": "Išjungėte nuotraukų peržvalgos įrankį visų atmainų rinkmenoms",
+ "multimediaviewer-enable-confirmation-text": "Kitąsyk, kai paspausite ant miniatiūros $1 svetainėje, bus naudojamas nuotraukų peržvalgos įrankis.",
+ "multimediaviewer-enable-alert": "Nuotraukų peržvalgos įrankis dabar išjungtas",
+ "multimediaviewer-disable-info-title": "Jūs išjungėte nuotraukų peržiūros įrankį",
+ "multimediaviewer-disable-info": "Jūs vis dar galite peržiūrėti atskirus vaizdus su nuotraukų peržvalgos įrankiu"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/lv.json b/www/wiki/extensions/MultimediaViewer/i18n/lv.json
new file mode 100644
index 00000000..6f7ac6c5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/lv.json
@@ -0,0 +1,69 @@
+{
+ "@metadata": {
+ "authors": [
+ "Papuass",
+ "Edgars2007"
+ ]
+ },
+ "multimediaviewer-pref": "Multimediju skatīklis",
+ "multimediaviewer-file-page": "Doties uz atbilstošo faila lapu",
+ "multimediaviewer-repository-local": "Vairāk informācijas",
+ "multimediaviewer-datetime-created": "Izveidots: $1",
+ "multimediaviewer-datetime-uploaded": "Augšupielādēts: $1",
+ "multimediaviewer-multiple-authors-combine": "$1 un $2",
+ "multimediaviewer-metadata-error": "Kļūda: Nevarēja ielādēt attēla datus. $1",
+ "multimediaviewer-thumbnail-error": "Kļūda: Nevarēja ielādēt sīktēlu datus. $1",
+ "multimediaviewer-thumbnail-error-report": "ziņot par problēmu",
+ "multimediaviewer-license-cc-pd": "Neaizsargāts darbs",
+ "multimediaviewer-license-pd": "Neaizsargāts darbs",
+ "multimediaviewer-license-default": "Skatīt licenci",
+ "multimediaviewer-permission-title": "Atļauju detaļas",
+ "multimediaviewer-permission-link": "skatīt noteikumus",
+ "multimediaviewer-permission-viewmore": "Skatīt vairāk",
+ "multimediaviewer-about-mmv": "Par",
+ "multimediaviewer-discuss-mmv": "Diskusija",
+ "multimediaviewer-help-mmv": "Palīdzība",
+ "multimediaviewer-optout-mmv": "Deaktivizēt Media Viewer",
+ "multimediaviewer-optin-mmv": "Aktivizēt multimediju skatīkli",
+ "multimediaviewer-optout-pending-mmv": "Atspējo multimediju skatīkli",
+ "multimediaviewer-optin-pending-mmv": "Iepsējo multimediju skatīkli",
+ "multimediaviewer-optout-help": "Multimediju skatīklis vairs netiks izmantots attēlu apskatei. Lai atkal to izmantotu, klikšķiniet uz \"Izplest\" pogas blakus jebkuram attēlam. tad klikšķiniet uz \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Multimediju skatīklis tiks izmantots attēlu apskatei.",
+ "multimediaviewer-geolocation": "Atrašanās vieta: $1",
+ "multimediaviewer-reuse-link": "Dalīties vai iegult šo failu",
+ "multimediaviewer-reuse-loading-placeholder": "Ielādē…",
+ "multimediaviewer-share-tab": "Dalīties",
+ "multimediaviewer-embed-tab": "Ievietot",
+ "multimediaviewer-download-link": "Lejupielādēt šo failu",
+ "multimediaviewer-download-preview-link-title": "Skatīt pārlūkprogrammā",
+ "multimediaviewer-download-original-button-name": "Lejupielādēt oriģinālo failu",
+ "multimediaviewer-download-small-button-name": "Lejupielādēt maza izmēra failu",
+ "multimediaviewer-download-medium-button-name": "Lejupielādēt vidēja izmēra failu",
+ "multimediaviewer-download-large-button-name": "Lejupielādēt liela izmēra failu",
+ "multimediaviewer-link-to-page": "Saite uz attēla aprakstu lapu",
+ "multimediaviewer-link-to-file": "Saite uz oriģinālo attēlu",
+ "multimediaviewer-share-explanation": "Nokopējiet un brīvi dalieties ar saiti",
+ "multimediaviewer-embed-wt": "Vikiteksts",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Izmanto šo kodu, lai iegultu failu",
+ "multimediaviewer-html-embed-credit-link-text": "Saite",
+ "multimediaviewer-embed-license": "Licencēts saskaņā ar $1.",
+ "multimediaviewer-default-embed-dimensions": "Noklusējuma sīktēlu izmērs",
+ "multimediaviewer-original-embed-dimensions": "Sākotnējais fails $1",
+ "multimediaviewer-large-embed-dimensions": "Liels $1",
+ "multimediaviewer-medium-embed-dimensions": "Vidējs $1",
+ "multimediaviewer-small-embed-dimensions": "Mazs $1",
+ "multimediaviewer-description-page-button-text": "Vairāk datu par šo failu",
+ "multimediaviewer-commons-subtitle": "Brīvā multimediju krātuve",
+ "multimediaviewer-view-expanded": "Atvērt Media Viewer",
+ "multimediaviewer-view-config": "Konfigurācija",
+ "multimediaviewer-close-popup-text": "Aizvērt šo rīku (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Parādīt pilnekrāna režīmā",
+ "multimediaviewer-defullscreen-popup-text": "Iziet no pilnekrāna režīma",
+ "multimediaviewer-next-image-alt-text": "Rādīt nākamo attēlu",
+ "multimediaviewer-prev-image-alt-text": "Rādīt iepriekšējo attēlu",
+ "multimediaviewer-title-popup-text": "Apraksts",
+ "multimediaviewer-reuse-warning-nonfree": "Šim failam nav brīvas licences",
+ "multimediaviewer-options-learn-more": "Uzzināt vairāk",
+ "multimediaviewer-option-cancel-button": "Atcelt"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/lzh.json b/www/wiki/extensions/MultimediaViewer/i18n/lzh.json
new file mode 100644
index 00000000..2c4bdc37
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/lzh.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "StephDC",
+ "Jason924tw"
+ ]
+ },
+ "multimediaviewer-repository-local": "顯細",
+ "multimediaviewer-help-mmv": "助",
+ "multimediaviewer-reuse-loading-placeholder": "載之…",
+ "multimediaviewer-download-link": "取檔",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-attr-plain": "純字"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/mg.json b/www/wiki/extensions/MultimediaViewer/i18n/mg.json
new file mode 100644
index 00000000..1e305fdb
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/mg.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jagwar"
+ ]
+ },
+ "multimediaviewer-permission-viewmore": "Hijery be kokoa"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/mk.json b/www/wiki/extensions/MultimediaViewer/i18n/mk.json
new file mode 100644
index 00000000..21ea6f9f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/mk.json
@@ -0,0 +1,137 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06"
+ ]
+ },
+ "multimediaviewer-desc": "Зголемување на минијатурите на цел екран.",
+ "multimediaviewer-pref": "Прегледувач",
+ "multimediaviewer-pref-desc": "Дава поубаво прегледување на слики на страници. Ги прикажува поголеми на страниците со минијатури. Можат да се прегледуваат и на цел екран.",
+ "multimediaviewer-optin-pref": "Вклучи го <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Мултимедијалниот изведувач]</span>",
+ "multimediaviewer-file-page": "Оди на соодветната податотечна страница",
+ "multimediaviewer-repository-local": "Поподробно",
+ "multimediaviewer-datetime-created": "Создадено: $1",
+ "multimediaviewer-datetime-uploaded": "Подигнато: $1",
+ "multimediaviewer-credit": "$1 — $2",
+ "multimediaviewer-credit-fallback": "Погледнете авторски информации",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|уште еден автор|уште $1 автори}}",
+ "multimediaviewer-multiple-authors-combine": "$1 и $2",
+ "multimediaviewer-metadata-error": "Не можев да ги вчитам податоците за сликата. (грешка: $1)",
+ "multimediaviewer-thumbnail-error": "За жал, не можев да ја прикажам податотеката",
+ "multimediaviewer-thumbnail-error-description": "Имаме технички проблем. Можете да $1 или $3 ако упрно се јавува. Грешка: $2",
+ "multimediaviewer-thumbnail-error-retry": "пробај пак",
+ "multimediaviewer-thumbnail-error-report": "го пријавите проблемот",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Јавна сопственост",
+ "multimediaviewer-license-pd": "Јавна сопственост",
+ "multimediaviewer-license-default": "Погл. лиценцата",
+ "multimediaviewer-permission-title": "Подробности за дозволата",
+ "multimediaviewer-permission-link": "погл. услови",
+ "multimediaviewer-permission-link-hide": "скриј услови",
+ "multimediaviewer-permission-viewmore": "Погл. уште",
+ "multimediaviewer-restriction-2257": "Оваа слика содржи јасно сексуална содржина, која може да подлежи на Законот за заштита на детето и контрола врз непристојниот материјал на САД (''Child Protection and Obscenity Enforcement Act'').",
+ "multimediaviewer-restriction-aus-reserve": "Сликава е фотографирана во резерват на Државната заедница Австралија и не може да се користи за стекнување на финансиска добивка без да се добие дозвола за тоа.",
+ "multimediaviewer-restriction-communist": "Оваа слика содржи комунистички обележја кои се забранети во некои земји.",
+ "multimediaviewer-restriction-costume": "На сликава е прикажано костимирање кое може да подлежи на правни ограничувања.",
+ "multimediaviewer-restriction-currency": "На сликава е претставена платежна единица која може да подлежи на правни ограничувања.",
+ "multimediaviewer-restriction-design": "Дизајнот на сликава може да е заштитен со авторски права, што би значело дека подложи на правни ограничувања.",
+ "multimediaviewer-restriction-fan-art": "Оваа слика е обожавателско уметничко дело, и нејзината пренамена може да подлежи на правни ограничувања.",
+ "multimediaviewer-restriction-ihl": "Оваа слика содржи симболи ограничени од меѓународното хуманитарно право.",
+ "multimediaviewer-restriction-insignia": "Сликава содржи службени обележја што може да подлежат на правни ограничувања.",
+ "multimediaviewer-restriction-ita-mibac": "Оваа слика прикажува културно наследство на Италија и подлежи на ограничувањата пропишани од италијанското право.",
+ "multimediaviewer-restriction-nazi": "Оваа слика содржи нацистички или други фашистички обележја кои се забранети во некои земји.",
+ "multimediaviewer-restriction-personality": "На сликава се прикажани личности кои може да имаат права што ограничуваат извесни нејзини употреби без претходно добиена согласност.",
+ "multimediaviewer-restriction-trademarked": "Сликава има содржини што може да подлежат на законите за заштитен знак.",
+ "multimediaviewer-restriction-default": "Сликава може да е предмет на ограничувања согласно правни одредби вон авторското право. Погледајте ја описната страница на податотеката за повеќе информации.",
+ "multimediaviewer-restriction-default-and-others": "Сликава може да подлежи на понатамошни ограничувања согласно други правни одредби вон авторското право. Погледајте ја описната страница на податотеката за повеќе информации.",
+ "multimediaviewer-about-mmv": "За прегледувачот",
+ "multimediaviewer-discuss-mmv": "Разговор",
+ "multimediaviewer-help-mmv": "Ппомош",
+ "multimediaviewer-optout-mmv": "Исклучи го Прегледувачот",
+ "multimediaviewer-optin-mmv": "Вклучи го Прегледувачот",
+ "multimediaviewer-optout-pending-mmv": "Исклучување на Прегледувачот",
+ "multimediaviewer-optin-pending-mmv": "Вклучување на Прегледувачот",
+ "multimediaviewer-optout-help": "Прегледувачот повеќе нема да се користи за прикажување на слики. Ако сакате да го користите повторно, стиснете на копчето „{{int:multimediaviewer-view-expanded}}“ веднаш до секоја слика. Потоа стниснете на „{{int:multimediaviewer-optin-mmv}}“.",
+ "multimediaviewer-optin-help": "Прегледувачот ќе се користи за прикажување на слики.",
+ "multimediaviewer-geoloc-north": "СГШ",
+ "multimediaviewer-geoloc-east": "ИГД",
+ "multimediaviewer-geoloc-south": "ЈГШ",
+ "multimediaviewer-geoloc-west": "ЗГД",
+ "multimediaviewer-geoloc-coords": "$1, $2",
+ "multimediaviewer-geolocation": "Местоположба: $1",
+ "multimediaviewer-reuse-link": "Сподели/Вметни ја податотекава",
+ "multimediaviewer-reuse-loading-placeholder": "Вчитувам…",
+ "multimediaviewer-reuse-copy-share": "Изберете и прекопирајте ја врската (ако е поддржано) за споделување на податотекава",
+ "multimediaviewer-reuse-copy-embed": "Изберете и прекопирајте го кодот (ако е поддржано) за вметнување на податотекава",
+ "multimediaviewer-share-tab": "Сподели",
+ "multimediaviewer-embed-tab": "Вметни",
+ "multimediaviewer-download-link": "Преземи ја податотекава",
+ "multimediaviewer-download-preview-link-title": "Погледај во прелистувач",
+ "multimediaviewer-download-original-button-name": "Преземи ја изворната податотека",
+ "multimediaviewer-download-small-button-name": "Преземи мало",
+ "multimediaviewer-download-medium-button-name": "Преземи средно",
+ "multimediaviewer-download-large-button-name": "Преземи големо",
+ "multimediaviewer-link-to-page": "Врска до описната страница на податотеката",
+ "multimediaviewer-link-to-file": "Врска до изворната податотека",
+ "multimediaviewer-share-explanation": "Ископирајте ја врската и слободно споделувајте ја",
+ "multimediaviewer-embed-wt": "Викитекст",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Со овој код можете некаде да ја вметнете податотеката",
+ "multimediaviewer-text-embed-credit-text-bl": "Од $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Од $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Од $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Од $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Врска",
+ "multimediaviewer-embed-byline": "Од $1",
+ "multimediaviewer-embed-license": "Под лиценцата $1.",
+ "multimediaviewer-embed-via": "Преку $1.",
+ "multimediaviewer-default-embed-dimensions": "Стандардна големина на минијатурата",
+ "multimediaviewer-original-embed-dimensions": "Изворна податотека $1",
+ "multimediaviewer-large-embed-dimensions": "Голема $1",
+ "multimediaviewer-medium-embed-dimensions": "Средна $1",
+ "multimediaviewer-small-embed-dimensions": "Мала $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 пиксели",
+ "multimediaviewer-embed-dimensions-separated": "— $1",
+ "multimediaviewer-description-page-button-text": "Поподробно за податотекава",
+ "multimediaviewer-description-page-popup-text": "Поподробно за податотекава на $1",
+ "multimediaviewer-commons-subtitle": "Слободно складиште на медиумски содржини",
+ "multimediaviewer-view-expanded": "Отвори во Прегледувачот",
+ "multimediaviewer-view-config": "Нагодување",
+ "multimediaviewer-close-popup-text": "Затворете ја алаткава (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Прикажи на цел екран",
+ "multimediaviewer-defullscreen-popup-text": "Излези од полн екран",
+ "multimediaviewer-next-image-alt-text": "Следна слика",
+ "multimediaviewer-prev-image-alt-text": "Претходна слика",
+ "multimediaviewer-title-popup-text": "Опис",
+ "multimediaviewer-credit-popup-text": "Информации за авторот и изворот",
+ "multimediaviewer-title-popup-text-more": "Погл. целосниот опис",
+ "multimediaviewer-credit-popup-text-more": "Погл. целосните информации за звтор и извор",
+ "multimediaviewer-download-attribution-cta-header": "Ќе треба да го наведете авторот",
+ "multimediaviewer-download-optional-attribution-cta-header": "Можете да го наведете авторот",
+ "multimediaviewer-download-attribution-cta": "Покажи ми како",
+ "multimediaviewer-download-attribution-copy": "Одберете и копирајте го (ако е поддражно) приписниот текст за податотекава.",
+ "multimediaviewer-reuse-warning-deletion": "Оваа податотека е ставена на разгледување за бришење.",
+ "multimediaviewer-reuse-warning-nonfree": "Оваа податотека нема слободна лиценца.",
+ "multimediaviewer-reuse-warning-noattribution": "Оваа податотека нема приписни податоци.",
+ "multimediaviewer-reuse-warning-generic": "Погледајте ги [$1 поединостите] пред да ја употребите.",
+ "multimediaviewer-attr-plain": "Прост",
+ "multimediaviewer-options-tooltip": "Вклучи или исклучи го Прегледувачот",
+ "multimediaviewer-options-dialog-header": "Да го исклучам Прегледувачот?",
+ "multimediaviewer-options-text-header": "Прескокнувај ја функцијата за преглед кај сите податотеки.",
+ "multimediaviewer-options-text-body": "Можете подоцна да ја вклучите преку делот поподробно за податотеката.",
+ "multimediaviewer-options-learn-more": "Дознајте повеќе",
+ "multimediaviewer-option-submit-button": "Исклучи го Прегледувачот",
+ "multimediaviewer-option-cancel-button": "Откажи",
+ "multimediaviewer-disable-confirmation-header": "Прегледувачот ви е исклучен.",
+ "multimediaviewer-disable-confirmation-text": "Следен пат кога ќе стиснете на минијатура на $1, право ќе ви се прикажат сите подробности за податотеката",
+ "multimediaviewer-enable-dialog-header": "Да го вклучам Прегледувачот?",
+ "multimediaviewer-enable-text-header": "Вклучи ја можноста за преглед на сите податотеки по основно.",
+ "multimediaviewer-enable-submit-button": "Вклучи во Прегледувачот",
+ "multimediaviewer-enable-confirmation-header": "Го вклучивте Прегледувачот за сите податотеки",
+ "multimediaviewer-enable-confirmation-text": "Следен пат кога ќе стиснете на минијатура на $1, податотеката ќе ви се отвори во Прегледувачот.",
+ "multimediaviewer-enable-alert": "Прегледувачот сега ви е исклучен",
+ "multimediaviewer-disable-info-title": "Прегледувачот ви е исклучен",
+ "multimediaviewer-disable-info": "Сè уште можете да прегледувате поединечни податотеки со Прегледувачот.",
+ "multimediaviewer-errorreport-privacywarning": "Во извештајот се приложени подровности за грешката, кои ќе бидат јавно видливи. Доколку тоа ви пречи, можете да го измените извештајот подолу, отстранувајќи ги податоците што не сакате да се знаат."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ml.json b/www/wiki/extensions/MultimediaViewer/i18n/ml.json
new file mode 100644
index 00000000..94caa22e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ml.json
@@ -0,0 +1,144 @@
+{
+ "@metadata": {
+ "authors": [
+ "Clockery",
+ "Praveenp",
+ "Macofe"
+ ]
+ },
+ "multimediaviewer-desc": "ലഘുചിത്രങ്ങൾ ഫുൾസ്ക്രീനായി വികസിപ്പിക്കുക",
+ "multimediaviewer-pref": "മീഡിയ ദർശനോപാധി",
+ "multimediaviewer-pref-desc": "ഈ പുതിയ ഉപകരണമുപയോഗിച്ച് താങ്കളുടെ മീഡിയ ദർശനാനുഭവം മെച്ചപ്പെടുത്തൂ. ലഘുചിത്രങ്ങൾ ഉപയോഗിച്ചിരിക്കുന്ന താളുകളിലെ ചിത്രങ്ങൾ ഇതുപയോഗിച്ച് വലുതായി കാണാം. ചിത്രങ്ങൾ സുന്ദരമായ ഫുൾസ്ക്രീൻ സമ്പർക്കമുഖ രൂപത്തിലോ, പൂർണ്ണവലിപ്പത്തിലോ കാണാനാവുന്നതാണ്.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About മീഡിയ കാണൽ സൗകര്യം]</span> സജ്ജമാക്കുക",
+ "multimediaviewer-file-page": "ബന്ധപ്പെട്ട പ്രമാണത്താളിലേയ്ക്ക് പോവുക",
+ "multimediaviewer-repository-local": "വിശദവിവരങ്ങൾ",
+ "multimediaviewer-datetime-created": "സൃഷ്ടിച്ചത്: $1",
+ "multimediaviewer-datetime-uploaded": "അപ്‌ലോഡ് ചെയ്തത്: $1",
+ "multimediaviewer-credit-fallback": "രചയിതാവിന്റെ വിവരങ്ങൾ കാണുക",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ഒരു സ്രഷ്ടാവ് കൂടി|$1 സ്രഷ്ടാക്കൾ കൂടി}}",
+ "multimediaviewer-multiple-authors-combine": "$1 ഒപ്പം $2",
+ "multimediaviewer-metadata-error": "ചിത്രത്തിന്റെ വിവരങ്ങൾ എടുക്കാൻ കഴിഞ്ഞില്ല (പിഴവ്: $1)",
+ "multimediaviewer-thumbnail-error": "ക്ഷമിക്കണം, പ്രമാണം പ്രദർശിപ്പിക്കാനാവില്ല",
+ "multimediaviewer-thumbnail-error-description": "എന്തോ ഒരു സാങ്കേതിക പ്രശ്നമുണ്ടെന്ന് തോന്നുന്നു. താങ്കൾ ഒന്നെങ്കിൽ $1 അല്ലെങ്കിൽ ഇത് സ്ഥിരമായിട്ട് ഉണ്ടെങ്കിൽ $3.\nപിഴവ്: $2",
+ "multimediaviewer-thumbnail-error-retry": "വീണ്ടും ശ്രമിക്കുക",
+ "multimediaviewer-thumbnail-error-report": "പ്രശ്നമാണെന്ന് അറിയിക്കുക",
+ "multimediaviewer-license-cc-by-1.0": "സി.സി. ബൈ 1.0",
+ "multimediaviewer-license-cc-sa-1.0": "സി.സി. എസ്.എ. 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "സി.സി. ബൈ-എസ്.എ. 1.0",
+ "multimediaviewer-license-cc-by-2.0": "സി.സി. ബൈ 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "സി.സി. ബൈ-എസ്.എ. 2.0",
+ "multimediaviewer-license-cc-by-2.1": "സി.സി. ബൈ 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "സി.സി. ബൈ-എസ്.എ. 2.1",
+ "multimediaviewer-license-cc-by-2.5": "സി.സി. ബൈ 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "സി.സി. ബൈ-എസ്.എ. 2.5",
+ "multimediaviewer-license-cc-by-3.0": "സി.സി. ബൈ 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "സി.സി. ബൈ-എസ്.എ. 3.0",
+ "multimediaviewer-license-cc-by-4.0": "സി.സി. ബൈ 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "സി.സി. ബൈ-എസ്.എ. 4.0",
+ "multimediaviewer-license-cc-pd": "പൊതുസഞ്ചയം",
+ "multimediaviewer-license-cc-zero": "സി.സി.0",
+ "multimediaviewer-license-pd": "പൊതുസഞ്ചയം",
+ "multimediaviewer-license-default": "ഉപയോഗാനുമതി കാണുക",
+ "multimediaviewer-permission-title": "അനുമതി വിവരങ്ങൾ",
+ "multimediaviewer-permission-link": "നിബന്ധനകൾ കാണുക",
+ "multimediaviewer-permission-link-hide": "വ്യവസ്ഥകൾ മറയ്ക്കുക",
+ "multimediaviewer-permission-viewmore": "കൂടുതൽ കാണുക",
+ "multimediaviewer-restriction-2257": "അമേരിക്കൻ ഐക്യനാടുകളിലെ ശിശു സംരക്ഷണ, അശ്ലീലതാ തടയൽ നിയമത്തിനു ബാധകമായേക്കാവുന്ന ലൈംഗിക ചിത്രം ഉൾക്കൊള്ളുന്നുണ്ട്.",
+ "multimediaviewer-restriction-aus-reserve": "ഈ ചിത്രം ഓസ്ട്രേലിയൻ കോമൺവെൽത്ത് റിസർവിൽ നിന്നെടുത്തതും വ്യാപാരോദ്ദേശത്തോടെ ഉപയോഗിക്കൻ അനുമതിയെടുക്കേണ്ടതുമാണ്.",
+ "multimediaviewer-restriction-communist": "ഈ ചിത്രത്തിൽ ചില രാജ്യങ്ങളിൽ നിരോധിച്ചിട്ടുള്ള കമ്മ്യൂണിസ്റ്റ് മുദ്രണം ഉൾപ്പെടുന്നു.",
+ "multimediaviewer-restriction-costume": "ഈ ചിത്രത്തിൽ നിയമപ്രകാരമുള്ള പരിമിതപ്പെടുത്തലുകൾക്ക് ബാധകമായ വസ്ത്രധാരണം ഉണ്ടായേക്കാം.",
+ "multimediaviewer-restriction-currency": "ഈ ചിത്രം നിയമപ്രകാരമുള്ള പരിമിതപ്പെടുത്തലുകൾക്ക് ബാധകമായേക്കാവുന്ന ഒരു നാണയത്തിന്റേതാണ്.",
+ "multimediaviewer-restriction-design": "ഈ ചിത്രത്തിന്റെ വിഷയത്തിന്റെ രൂപകല്പന പകർപ്പവകാശസ്വതന്ത്രമല്ലാത്തതും നിയമപ്രകാരമുള്ള പരിമിതപ്പെടുത്തലുകൾക്ക് ബാധകമായതുമായേക്കാം.",
+ "multimediaviewer-restriction-fan-art": "ഈ ചിത്രം ഒരു ആരാധക-സൃഷ്ടി ആണ്, അതിനാലിതിന്റെ പുനരുപയോഗം നിയമപ്രകാരമുള്ള പരിമിതപ്പെടുത്തലിനു ബാധകമായേക്കാം.",
+ "multimediaviewer-restriction-ihl": "അന്താരാഷ്ട്ര മനുഷ്യാവകാശ നിയമപ്രകാരം പരിമിതപ്പെടുത്തിയിട്ടുള്ള ചിഹ്നങ്ങൾ ചിത്രത്തിൽ ഉണ്ട്.",
+ "multimediaviewer-restriction-insignia": "നിയമപ്രകാരമുള്ള പരിമിതപ്പെടുത്തലുകൾക്ക് ബാധകമായേക്കാവുന്ന ഔദ്യോഗിക മുദ്രണങ്ങൾ ഈ ചിത്രത്തിലുണ്ട്.",
+ "multimediaviewer-restriction-ita-mibac": "ഇറ്റാലിയൻ സാംസ്കാരിക പാരമ്പര്യത്തെ പ്രതിനിധീകരിക്കുന്ന ഒരു വസ്തുവിനെയാണ് ഈ ചിത്രത്തിൽ പുനഃസൃഷ്ടിക്കുന്നത്, അത് ഇറ്റാലിയൻ നിയമപ്രകാരം നിയന്ത്രിച്ചിട്ടുള്ളതാണ്.",
+ "multimediaviewer-restriction-nazi": "ഈ ചിത്രത്തിൽ ചില രാജ്യങ്ങളിൽ നിരോധിച്ചിട്ടുള്ള നാസി അല്ലെങ്കിൽ ഫാസിസ്റ്റ് മുദ്രണം ഉൾപ്പെടുന്നു.",
+ "multimediaviewer-restriction-personality": "ചിത്രത്തിന്റെ അനുവാദമില്ലാതെയുള്ള ചില പുനരുപയോഗങ്ങൾ അവരവരുടെ അവകാശപ്രകാരം നിയമപ്രകാരം നിയന്ത്രിച്ചിട്ടുള്ള വ്യക്തികൾ ഈ ചിത്രത്തിൽ ഉൾപ്പെടുന്നു.",
+ "multimediaviewer-restriction-trademarked": "ഈ ചിത്രത്തിൽ വ്യാപാരമുദ്രാ നിയമങ്ങൾ ബാധകമായ ഉള്ളടക്കം ഉണ്ടായേക്കാം.",
+ "multimediaviewer-restriction-default": "പകർപ്പവകാശനിയമത്തിൽ ഉൾപ്പെടാത്ത നിയമവ്യവസ്ഥകളാൽ ഈ ചിത്രം നിയന്ത്രിക്കപ്പെട്ടിട്ടുണ്ടാകാം. കൂടുതൽ വിവരങ്ങൾക്ക് പ്രമാണത്തിന്റെ വിവരണം കാണുക.",
+ "multimediaviewer-restriction-default-and-others": "പകർപ്പവകാശനിയമത്തിൽ ഉൾപ്പെടാത്ത നിയമവ്യവസ്ഥകളാൽ ഈ ചിത്രം കൂടുതൽ നിയന്ത്രിക്കപ്പെട്ടിട്ടുണ്ടാകാം. കൂടുതൽ വിവരങ്ങൾക്ക് പ്രമാണത്തിന്റെ വിവരണം കാണുക.",
+ "multimediaviewer-about-mmv": "വിവരണം",
+ "multimediaviewer-discuss-mmv": "സംവാദം",
+ "multimediaviewer-help-mmv": "സഹായം",
+ "multimediaviewer-optout-mmv": "മീഡിയ ദർശനോപാധി ഒഴിവാക്കുക",
+ "multimediaviewer-optin-mmv": "മീഡിയ ദർശനോപാധി സജ്ജമാക്കുക",
+ "multimediaviewer-optout-pending-mmv": "മീഡിയ ദർശനോപാധി ഒഴിവാക്കുന്നു",
+ "multimediaviewer-optin-pending-mmv": "മീഡിയ ദർശനോപാധി സജ്ജമാക്കുന്നു",
+ "multimediaviewer-optout-help": "ചിത്രങ്ങൾ പ്രദർശിപ്പിക്കാൻ മീഡിയ ദർശനോപാധി ഉപയോഗിക്കുന്നതല്ല. വീണ്ടും ഉപയോഗിക്കുവാൻ ചിത്രത്തിനരികിലുള്ള \"{{int:multimediaviewer-view-expanded}}\" ഞെക്കുക. എന്നിട്ട് \"{{int:multimediaviewer-optin-mmv}}\" ഞെക്കുക.",
+ "multimediaviewer-optin-help": "ചിത്രങ്ങൾ പ്രദർശിപ്പിക്കാൻ മീഡിയ ദർശനോപാധി ഉപയോഗിക്കുന്നതാണ്.",
+ "multimediaviewer-geoloc-north": "വ",
+ "multimediaviewer-geoloc-east": "കി",
+ "multimediaviewer-geoloc-south": "തെ",
+ "multimediaviewer-geoloc-west": "പ",
+ "multimediaviewer-geolocation": "സ്ഥാനം: $1",
+ "multimediaviewer-reuse-link": "ഈ പ്രമാണം ഉൾപ്പെടുത്തുക അല്ലെങ്കിൽ പങ്ക് വെയ്ക്കുക",
+ "multimediaviewer-reuse-loading-placeholder": "ശേഖരിക്കുന്നു...",
+ "multimediaviewer-reuse-copy-share": "ഈ പ്രമാണം പങ്ക് വെയ്ക്കാനായി കണ്ണി തിരഞ്ഞെടുക്കുക, പകർത്തുക (പിന്തുണയുണ്ടെങ്കിൽ)",
+ "multimediaviewer-reuse-copy-embed": "ഈ പ്രമാണം എംബെഡ് ചെയ്യാനായി കോഡ് തിരഞ്ഞെടുക്കുക, പകർത്തുക (പിന്തുണയുണ്ടെങ്കിൽ)",
+ "multimediaviewer-share-tab": "പങ്ക് വെയ്ക്കുക",
+ "multimediaviewer-embed-tab": "എംബെഡ് ചെയ്യുക",
+ "multimediaviewer-download-link": "ഈ പ്രമാണം ഡൗൺലോഡ് ചെയ്യുക",
+ "multimediaviewer-download-preview-link-title": "ബ്രൗസറിൽ കാണുക",
+ "multimediaviewer-download-original-button-name": "യഥാർത്ഥ പ്രമാണം ഡൗൺലോഡ് ചെയ്യുക",
+ "multimediaviewer-download-small-button-name": "ചെറിയ വലിപ്പത്തിൽ ഡൗൺലോഡ് ചെയ്യുക",
+ "multimediaviewer-download-medium-button-name": "ഇടത്തരം വലിപ്പത്തിൽ ഡൗൺലോഡ് ചെയ്യുക",
+ "multimediaviewer-download-large-button-name": "കൂടിയ വലിപ്പത്തിൽ ഡൗൺലോഡ് ചെയ്യുക",
+ "multimediaviewer-link-to-page": "പ്രമാണത്തിന്റെ വിവരണതാളിലേയ്ക്കുള്ള കണ്ണി",
+ "multimediaviewer-link-to-file": "യഥാർത്ഥ പ്രമാണത്തിലേയ്ക്കുള്ള കണ്ണി",
+ "multimediaviewer-share-explanation": "കണ്ണി പകർത്തുക, സ്വതന്ത്രമായി പങ്ക് വെയ്ക്കുക",
+ "multimediaviewer-embed-wt": "വിക്കിഎഴുത്ത്",
+ "multimediaviewer-embed-html": "എച്ച്.റ്റി.എം.എൽ.",
+ "multimediaviewer-embed-explanation": "പ്രമാണം എംബെഡ് ചെയ്യാനായി ഈ കോഡ് ഉപയോഗിക്കുക",
+ "multimediaviewer-html-embed-credit-link-text": "കണ്ണി",
+ "multimediaviewer-embed-byline": "സൃഷ്ടിച്ചത് $1",
+ "multimediaviewer-embed-license": "അനുമതി നൽകിയിരിക്കുന്നത് $1 പ്രകാരം ആണ്.",
+ "multimediaviewer-embed-via": "$1 വഴി.",
+ "multimediaviewer-default-embed-dimensions": "ലഘുചിത്രത്തിന് സ്വതേയുള്ള വലിപ്പം",
+ "multimediaviewer-original-embed-dimensions": "യഥാർത്ഥ പ്രമാണം $1",
+ "multimediaviewer-large-embed-dimensions": "കൂടിയ വലിപ്പം $1",
+ "multimediaviewer-medium-embed-dimensions": "ഇടത്തരം വലിപ്പം $1",
+ "multimediaviewer-small-embed-dimensions": "ചെറിയ വലിപ്പം $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 ബിന്ദു",
+ "multimediaviewer-description-page-button-text": "ഈ പ്രമാണത്തെക്കുറിച്ചുള്ള കൂടുതൽ വിവരങ്ങൾ",
+ "multimediaviewer-description-page-popup-text": "$1 സംരംഭത്തിൽ ഈ പ്രമാണത്തെക്കുറിച്ചുള്ള കൂടുതൽ വിവരങ്ങൾ",
+ "multimediaviewer-commons-subtitle": "സ്വതന്ത്ര മീഡിയ ശേഖരം",
+ "multimediaviewer-view-expanded": "മീഡിയ ദർശനോപാധിയിൽ കാണുക",
+ "multimediaviewer-view-config": "ക്രമീകരണങ്ങൾ",
+ "multimediaviewer-close-popup-text": "ഈ ഉപകരണം അടയ്ക്കുക (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "മുഴുവൻ സ്ക്രീനിൽ കാണിക്കുക",
+ "multimediaviewer-defullscreen-popup-text": "മുഴുവൻ സ്ക്രീനിൽ നിന്ന് പുറത്തു കടക്കുക",
+ "multimediaviewer-next-image-alt-text": "അടുത്ത ചിത്രം കാണിക്കുക",
+ "multimediaviewer-prev-image-alt-text": "മുമ്പത്തെ ചിത്രം കാണിക്കുക",
+ "multimediaviewer-title-popup-text": "വിവരണം",
+ "multimediaviewer-credit-popup-text": "സ്രഷ്ടാവും സ്രോതസ്സ് വിവരങ്ങളും",
+ "multimediaviewer-title-popup-text-more": "മുഴുവൻ വിവരവും കാണുക",
+ "multimediaviewer-credit-popup-text-more": "സ്രഷ്ടാവിന്റെയും സ്രോതസ്സിന്റെയും മുഴുവൻ വിവരവും കാണുക",
+ "multimediaviewer-download-attribution-cta-header": "താങ്കൾ സ്രഷ്ടാവിന് കടപ്പാട് കൊടുക്കേണ്ടതുണ്ട്",
+ "multimediaviewer-download-optional-attribution-cta-header": "താങ്കൾ സ്രഷ്ടാവിന് കടപ്പാട് കൊടുക്കാവുന്നതാണ്",
+ "multimediaviewer-download-attribution-cta": "എങ്ങനെയാണെന്ന് കാണിച്ചു തരിക",
+ "multimediaviewer-download-attribution-copy": "ഈ പ്രമാണത്തിന്റെ കടപ്പാട് എഴുത്ത് തിരഞ്ഞെടുക്കുക, പകർത്തുക (പിന്തുണയുണ്ടെങ്കിൽ)",
+ "multimediaviewer-reuse-warning-deletion": "ഈ പ്രമാണം മായ്ച്ചാലോ എന്നയാലോചനയിലാണ്.",
+ "multimediaviewer-reuse-warning-nonfree": "ഈ പ്രമാണത്തിന് ഒരു സ്വതന്ത്ര ഉപയോഗാനുമതി ഇല്ല.",
+ "multimediaviewer-reuse-warning-noattribution": "ഈ പ്രമാണത്തിന് യാതൊരു കടപ്പാട് വിവരങ്ങളും ഇല്ല.",
+ "multimediaviewer-reuse-warning-generic": "ഉപയോഗിക്കുന്നതിന്റെ മുമ്പ് [$1 ഇതിന്റെ വിശദാംശങ്ങൾ] പരിശോധിക്കുക.",
+ "multimediaviewer-attr-plain": "വെറും എഴുത്ത്",
+ "multimediaviewer-attr-html": "എച്ച്.റ്റി.എം.എൽ.",
+ "multimediaviewer-options-tooltip": "മീഡിയ ദർശനോപാധി സജ്ജമാക്കുക അല്ലെങ്കിൽ ഒഴിവാക്കുക",
+ "multimediaviewer-options-dialog-header": "മീഡിയ ദർശനോപാധി ഒഴിവാക്കണോ?",
+ "multimediaviewer-options-text-header": "എല്ലാ പ്രമാണങ്ങളിൽ നിന്നും ഈ കാണൽ സൗകര്യം ഒഴിവാക്കുക.",
+ "multimediaviewer-options-text-body": "പ്രമാണത്തിന്റെ വിവരണ താളിൽ നിന്ന് ഇത് പീന്നീട് താങ്കൾക്ക് സജ്ജമാക്കാവുന്നതാണ്.",
+ "multimediaviewer-options-learn-more": "കൂടുതൽ അറിയുക",
+ "multimediaviewer-option-submit-button": "മീഡിയ ദർശനോപാധി ഒഴിവാക്കുക",
+ "multimediaviewer-option-cancel-button": "റദ്ദാക്കുക",
+ "multimediaviewer-disable-confirmation-header": "താങ്കൾ മീഡിയ ദർശനോപാധി ഒഴിവാക്കി",
+ "multimediaviewer-disable-confirmation-text": "അടുത്ത പ്രാവശ്യം $1 സംരംഭത്തിൽ ലഘുചിത്രത്തിൽ താങ്കൾ ഞെക്കുമ്പോൾ, താങ്കൾ നേരിട്ട് പ്രമാണത്തിന്റെ വിവരണതാളിലേക്കാവും ചെല്ലുക.",
+ "multimediaviewer-enable-dialog-header": "മീഡിയ ദർശനോപാധി സജ്ജമാക്കണോ?",
+ "multimediaviewer-enable-text-header": "ഈ മീഡിയ കാണൽ സൗകര്യം എല്ലാ പ്രമാണങ്ങൾക്കുമായി സ്വതേയുള്ളതായി സജ്ജമാക്കുക.",
+ "multimediaviewer-enable-submit-button": "മീഡിയ ദർശനോപാധി സജ്ജമാക്കുക",
+ "multimediaviewer-enable-confirmation-header": "എല്ലാ പ്രമാണങ്ങൾക്കും താങ്കൾ മീഡിയ ദർശനോപാധി സജ്ജമാക്കി",
+ "multimediaviewer-enable-confirmation-text": "അടുത്ത പ്രാവശ്യം $1 സംരംഭത്തിൽ ലഘുചിത്രത്തിൽ താങ്കൾ ഞെക്കുമ്പോൾ, മീഡിയ ദർശനോപാധി ഉപയോഗിക്കപ്പെടുന്നതാണ്.",
+ "multimediaviewer-enable-alert": "മീഡിയ ദർശനോപാധി ഇപ്പോൾ പ്രവർത്തനരഹിതമാണ്",
+ "multimediaviewer-disable-info-title": "താങ്കൾ മീഡിയ ദർശനോപാധി പ്രവർത്തനരഹിതമാക്കി",
+ "multimediaviewer-disable-info": "താങ്കൾക്ക് ഇപ്പോഴും ഒറ്റയൊറ്റ പ്രമാണങ്ങൾ മീഡിയ ദർശനോപാധി ഉപയോഗിച്ച് കാണാവുന്നതാണ്."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/mn.json b/www/wiki/extensions/MultimediaViewer/i18n/mn.json
new file mode 100644
index 00000000..398c3070
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/mn.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Wisdom",
+ "Munkhzaya.E"
+ ]
+ },
+ "multimediaviewer-discuss-mmv": "Хэлэлцэх",
+ "multimediaviewer-optin-help": "Зураг харуулахдаа Media Viewer -ыг ашиглана"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/mr.json b/www/wiki/extensions/MultimediaViewer/i18n/mr.json
new file mode 100644
index 00000000..cd777d75
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/mr.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "V.narsikar"
+ ]
+ },
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About मिडिया व्ह्यूअर]</span> सक्षम करा",
+ "multimediaviewer-thumbnail-error-report": "याबाबतचा अहवाल द्या",
+ "multimediaviewer-license-pd": "सार्वजनिक अधिक्षेत्र",
+ "multimediaviewer-optin-mmv": "माध्यम दर्शक(मिडिया व्ह्यूअर) सक्षम करा",
+ "multimediaviewer-text-embed-credit-text-bl": "$1,$2,$3 द्वारे",
+ "multimediaviewer-text-embed-credit-text-b": "$1,$2 द्वारे",
+ "multimediaviewer-html-embed-credit-text-bl": "$1,$2,$3 द्वारे",
+ "multimediaviewer-html-embed-credit-text-b": "$1,$2 द्वारे",
+ "multimediaviewer-html-embed-credit-link-text": "दुवा"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ms.json b/www/wiki/extensions/MultimediaViewer/i18n/ms.json
new file mode 100644
index 00000000..f965a167
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ms.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Hidupkan <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-repository-local": "Maklumat lanjut",
+ "multimediaviewer-credit-fallback": "Lihat maklumat pengarang",
+ "multimediaviewer-license-pd": "Domain Awam",
+ "multimediaviewer-reuse-link": "Sebarkan atau terapkan fail ini",
+ "multimediaviewer-download-link": "Muat turun fail ini",
+ "multimediaviewer-view-expanded": "Buka dalam Media Viewer",
+ "multimediaviewer-options-tooltip": "Hidupkan atau matikan Media Viewer",
+ "multimediaviewer-options-dialog-header": "Matikan Media Viewer?",
+ "multimediaviewer-option-submit-button": "Matikan Media Viewer",
+ "multimediaviewer-option-cancel-button": "Batalkan",
+ "multimediaviewer-disable-confirmation-header": "Anda telah mamtikan Media Viewer",
+ "multimediaviewer-enable-dialog-header": "Hidupkan Media Viewer?",
+ "multimediaviewer-enable-text-header": "Hidupkan ciri-ciri tayangan media untuk semua fail secara asal.",
+ "multimediaviewer-enable-submit-button": "Hidupkan Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "Anda telah menghidupkan Media Viewer untuk semua fail",
+ "multimediaviewer-disable-info-title": "Anda telah mematikan Media Viewer"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/mwl.json b/www/wiki/extensions/MultimediaViewer/i18n/mwl.json
new file mode 100644
index 00000000..8725a264
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/mwl.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "multimediaviewer-pref": "Bisualizador Multimédia",
+ "multimediaviewer-optin-pref": "Atibar l <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Bisualizador Multimédia]</span>",
+ "multimediaviewer-about-mmv": "Subre",
+ "multimediaviewer-optin-mmv": "Atibar l Bisualizador Multimédia"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/my.json b/www/wiki/extensions/MultimediaViewer/i18n/my.json
new file mode 100644
index 00000000..ed3196fc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/my.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ninjastrikers"
+ ]
+ },
+ "multimediaviewer-repository-local": "နောက်ထပ် အချက်အလက်များ",
+ "multimediaviewer-help-mmv": "အကူအညီ",
+ "multimediaviewer-description-page-popup-text": "$1 ရှိ ဤဖိုင်အကြောင်း နောက်ထပ် အချက်အလက်များ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/nan.json b/www/wiki/extensions/MultimediaViewer/i18n/nan.json
new file mode 100644
index 00000000..bedd3504
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/nan.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "唐吉訶德的侍從"
+ ]
+ },
+ "multimediaviewer-view-expanded": "Īng muî-thé kiám-sī-khì lâi khoàⁿ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/nap.json b/www/wiki/extensions/MultimediaViewer/i18n/nap.json
new file mode 100644
index 00000000..7a80f0d2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/nap.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chelin",
+ "C.R."
+ ]
+ },
+ "multimediaviewer-repository-local": "Cchiù dettaglie",
+ "multimediaviewer-license-pd": "Pubbreco duminio",
+ "multimediaviewer-optin-help": "Media Viewer sarrà 'o visore pe' mmustà l'immaggene"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/nb.json b/www/wiki/extensions/MultimediaViewer/i18n/nb.json
new file mode 100644
index 00000000..90aef10b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/nb.json
@@ -0,0 +1,131 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cocu",
+ "Danmichaelo",
+ "Jon Harald Søby"
+ ]
+ },
+ "multimediaviewer-desc": "Utvider miniatyrbilder til større størrelse i et fullskjermoverlegg.",
+ "multimediaviewer-pref": "Mediefremviser",
+ "multimediaviewer-pref-desc": "Forbedre multimediavisningsopplevelsen med dette nye verktøyet. Det viser bilder i større størrelse på sider som har miniatyrbilder. Bilder vises i et overlegg, som også kan utvides til fullskjerm.",
+ "multimediaviewer-optin-pref": "Aktiver <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About mediefremviseren]</span>",
+ "multimediaviewer-file-page": "Gå til tilsvarende filside",
+ "multimediaviewer-repository-local": "Flere detaljer",
+ "multimediaviewer-datetime-created": "Opprettet: $1",
+ "multimediaviewer-datetime-uploaded": "Lastet opp: $1",
+ "multimediaviewer-credit-fallback": "Vis info om opphavsperson",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|én annen forfatter|$1 andre forfattere}}",
+ "multimediaviewer-multiple-authors-combine": "$1 og $2",
+ "multimediaviewer-metadata-error": "Klarte ikke laste bildedetaljer (feil: $1)",
+ "multimediaviewer-thumbnail-error": "Beklager, filen kunne ikke vises",
+ "multimediaviewer-thumbnail-error-description": "Det ser ut til å være et teknisk problem. Du kan $1 eller $3 om det fortsetter. Feil: $2",
+ "multimediaviewer-thumbnail-error-retry": "prøve igjen",
+ "multimediaviewer-thumbnail-error-report": "rapportere problemet",
+ "multimediaviewer-license-cc-pd": "Offentlig eiendom",
+ "multimediaviewer-license-pd": "Offentlig eiendom",
+ "multimediaviewer-license-default": "Vis lisens",
+ "multimediaviewer-permission-title": "Detaljer om tillatelse for bruk",
+ "multimediaviewer-permission-link": "vis vilkår",
+ "multimediaviewer-permission-link-hide": "skjul vilkår",
+ "multimediaviewer-permission-viewmore": "Vis mer",
+ "multimediaviewer-restriction-2257": "Dette bildet inneholder seksuelt innhold som kan dekkes av Child Protection and Obscenity Enforcement Act i USA.",
+ "multimediaviewer-restriction-aus-reserve": "Dette bildet ble tatt i et Australian Commonwealth-reservat, og kan ikke brukes kommersielt uten tillatelse.",
+ "multimediaviewer-restriction-communist": "Dette bildet inneholder kommunistiske symboler som kan være bannlyste i enkelte land.",
+ "multimediaviewer-restriction-costume": "Dette bildet viser kostymer og kan ha juridiske begrensninger.",
+ "multimediaviewer-restriction-currency": "Dette bildet viser en valutaenhet og kan ha juridiske begrensninger.",
+ "multimediaviewer-restriction-design": "Designet til subjektet av dette bildet kan være under opphavsrett og ha juridiske begrensninger.",
+ "multimediaviewer-restriction-fan-art": "Dette bildet er fan-kunst, og gjenbruk kan være ha juridiske begrensninger.",
+ "multimediaviewer-restriction-ihl": "Dette bildet inneholder symboler som begrenses av internasjonal menneskerett.",
+ "multimediaviewer-restriction-insignia": "Dette bildet inneholder offisielle symboler som kan ha juridiske begrensninger.",
+ "multimediaviewer-restriction-ita-mibac": "Dette bildet viser en eiendom som tilhører italiensk kulturarv, og kan ha juridiske begrensninger i italiensk lov.",
+ "multimediaviewer-restriction-nazi": "Dette bildet inneholder nazistiske eller fascistiske symboler som kan være bannlyste i enkelte land.",
+ "multimediaviewer-restriction-personality": "Dette bildet inneholder personer som kan ha rettigheter som legger juridiske begrensninger på gjenbruk uten deres samtykke.",
+ "multimediaviewer-restriction-trademarked": "Dette bildet inneholder innhold som kan være gjenstand for varemerkelover.",
+ "multimediaviewer-restriction-default": "Dette bildet kan være begrenset av juridiske begrensninger utenom opphavsrett. Se filbeskrivelsessiden for detaljer.",
+ "multimediaviewer-restriction-default-and-others": "Dette bildet kan ha videre begrensninger av juridiske bestemmelser utenom opphavsrett. Se filbeskrivelsessiden for detaljer.",
+ "multimediaviewer-about-mmv": "Om",
+ "multimediaviewer-discuss-mmv": "Diskusjon",
+ "multimediaviewer-help-mmv": "Hjelp",
+ "multimediaviewer-optout-mmv": "Deaktiver mediefremviseren",
+ "multimediaviewer-optin-mmv": "Aktiver mediefremviseren",
+ "multimediaviewer-optout-pending-mmv": "Deaktiverer mediefremviseren",
+ "multimediaviewer-optin-pending-mmv": "Aktiverer mediefremviseren",
+ "multimediaviewer-optout-help": "Mediefremviseren vil ikke lenger brukes for å vise bilder. Hvis du vil skru den på igjen, trykk på «{{int:multimediaviewer-view-expanded}}»-knappen ved siden av et bilde. Trykk deretter på «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Mediefremviseren vil bli brukt til å vise bilder.",
+ "multimediaviewer-geoloc-east": "Ø",
+ "multimediaviewer-geoloc-west": "V",
+ "multimediaviewer-geolocation": "Sted: $1",
+ "multimediaviewer-reuse-link": "Del eller bygg inn denne filen",
+ "multimediaviewer-reuse-loading-placeholder": "Laster…",
+ "multimediaviewer-reuse-copy-share": "Velg og kopier lenka for å dele denne fila (om støttet)",
+ "multimediaviewer-reuse-copy-embed": "Velg og kopier koden for å bygge inn denne fila (om støttet)",
+ "multimediaviewer-share-tab": "Del",
+ "multimediaviewer-embed-tab": "Bygg inn",
+ "multimediaviewer-download-link": "Last ned denne filen",
+ "multimediaviewer-download-preview-link-title": "Vis i nettleser",
+ "multimediaviewer-download-original-button-name": "Last ned originalfil",
+ "multimediaviewer-download-small-button-name": "Last ned liten størrelse",
+ "multimediaviewer-download-medium-button-name": "Last ned medium størrelse",
+ "multimediaviewer-download-large-button-name": "Last ned stor størrelse",
+ "multimediaviewer-link-to-page": "Lenke til filbeskrivelsessiden",
+ "multimediaviewer-link-to-file": "Lenke til originalfilen",
+ "multimediaviewer-share-explanation": "Kopier og del lenken fritt",
+ "multimediaviewer-embed-wt": "Wikitekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Bruk denne koden for å bygge inn filen",
+ "multimediaviewer-text-embed-credit-text-bl": "Av $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Av $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Av $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Av $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Lenke",
+ "multimediaviewer-embed-byline": "Av $1",
+ "multimediaviewer-embed-license": "Lisensiert under $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Standard miniatyrbildestørrelse",
+ "multimediaviewer-original-embed-dimensions": "Originalfil $1",
+ "multimediaviewer-large-embed-dimensions": "Stor $1",
+ "multimediaviewer-medium-embed-dimensions": "Middels $1",
+ "multimediaviewer-small-embed-dimensions": "Liten $1",
+ "multimediaviewer-description-page-button-text": "Mer info om denne filen",
+ "multimediaviewer-description-page-popup-text": "Mer info om denne filen på $1",
+ "multimediaviewer-commons-subtitle": "Det frie mediearkivet",
+ "multimediaviewer-view-expanded": "Åpne i mediefremviseren",
+ "multimediaviewer-view-config": "Innstillinger",
+ "multimediaviewer-close-popup-text": "Lukk dette verktøyet (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Vis i fullskjerm",
+ "multimediaviewer-defullscreen-popup-text": "Lukk fullskjerm",
+ "multimediaviewer-next-image-alt-text": "Vis neste bilde",
+ "multimediaviewer-prev-image-alt-text": "Vis forrige bilde",
+ "multimediaviewer-title-popup-text": "Beskrivelse",
+ "multimediaviewer-credit-popup-text": "Informasjon om kilde og opphavsperson",
+ "multimediaviewer-title-popup-text-more": "Vis fullstendig beskrivelse",
+ "multimediaviewer-credit-popup-text-more": "Vis fullstendig informasjon om kilde og opphavsperson",
+ "multimediaviewer-download-attribution-cta-header": "Du må navngi opphavspersonen(e)",
+ "multimediaviewer-download-optional-attribution-cta-header": "Du kan navngi opphavspersonen",
+ "multimediaviewer-download-attribution-cta": "Vis meg hvordan",
+ "multimediaviewer-download-attribution-copy": "Velg og kopier (om støttet) attribusjonsteksten for denne fila",
+ "multimediaviewer-reuse-warning-deletion": "Denne filen vurderes slettet.",
+ "multimediaviewer-reuse-warning-nonfree": "Denne filen har ikke en fri lisens.",
+ "multimediaviewer-reuse-warning-noattribution": "Denne filen har ingen attribusjonsinformasjon.",
+ "multimediaviewer-reuse-warning-generic": "Sjekk [$1 detaljene dens] før du bruker den.",
+ "multimediaviewer-attr-plain": "Enkel tekst",
+ "multimediaviewer-options-tooltip": "Skru av eller på mediefremviseren",
+ "multimediaviewer-options-dialog-header": "Skru av mediefremviseren?",
+ "multimediaviewer-options-text-header": "Hopp over denne visningen som standard.",
+ "multimediaviewer-options-text-body": "Du kan aktivere den igjen på et senere tidspunkt fra fildetaljsidene.",
+ "multimediaviewer-options-learn-more": "Mer informasjon",
+ "multimediaviewer-option-submit-button": "Skru av mediefremviseren",
+ "multimediaviewer-option-cancel-button": "Avbryt",
+ "multimediaviewer-disable-confirmation-header": "Du har skrudd av mediefremviseren",
+ "multimediaviewer-disable-confirmation-text": "Neste gang du trykker på et miniatyrbilde på $1, vil du du bli sendt direkte til fildetaljene.",
+ "multimediaviewer-enable-dialog-header": "Aktiver mediefremviseren?",
+ "multimediaviewer-enable-text-header": "Aktiver denne funksjonen som standard for alle filer.",
+ "multimediaviewer-enable-submit-button": "Aktiver mediefremviseren",
+ "multimediaviewer-enable-confirmation-header": "Du har aktivert mediefremviseren for alle filer",
+ "multimediaviewer-enable-confirmation-text": "Mediefremviseren bli brukt neste gang du trykker på et miniatyrbilde på $1.",
+ "multimediaviewer-enable-alert": "Mediefremviseren er deaktivert som standard",
+ "multimediaviewer-disable-info-title": "Du har deaktivert mediefremviseren",
+ "multimediaviewer-disable-info": "Du kan fremdeles vise enkeltfiler i mediefremviseren.",
+ "multimediaviewer-errorreport-privacywarning": "Detaljer om feilen legges ved rapporten, og vil være synlige offentlig. Om du ikke er komfortabel med det kan du redigere rapporten nedenfor og fjerne data du ikke ønsker å dele."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/nds-nl.json b/www/wiki/extensions/MultimediaViewer/i18n/nds-nl.json
new file mode 100644
index 00000000..f5c8a309
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/nds-nl.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Servien"
+ ]
+ },
+ "multimediaviewer-help-mmv": "Hulpe",
+ "multimediaviewer-fullscreen-popup-text": "Op volledig scharm laoten zien",
+ "multimediaviewer-defullscreen-popup-text": "Volledig scharm sluten",
+ "multimediaviewer-title-popup-text": "Bestaandsnaam"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ne.json b/www/wiki/extensions/MultimediaViewer/i18n/ne.json
new file mode 100644
index 00000000..e0f7d339
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ne.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "NehalDaveND"
+ ]
+ },
+ "multimediaviewer-help-mmv": "सहायता",
+ "multimediaviewer-reuse-loading-placeholder": "लोड हुदैछ...",
+ "multimediaviewer-share-tab": "बाड्ने",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-title-popup-text": "वर्णन",
+ "multimediaviewer-options-learn-more": "जाने थप",
+ "multimediaviewer-option-cancel-button": "रद्द गर्ने"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/nl.json b/www/wiki/extensions/MultimediaViewer/i18n/nl.json
new file mode 100644
index 00000000..dc6e860d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/nl.json
@@ -0,0 +1,107 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arent",
+ "SPQRobin",
+ "Siebrand",
+ "Sjoerddebruin",
+ "Southparkfan",
+ "Romaine",
+ "Mathonius",
+ "Macofe",
+ "Robin0van0der0vliet",
+ "Robin van der Vliet",
+ "Mainframe98",
+ "Mar(c)"
+ ]
+ },
+ "multimediaviewer-desc": "Miniatuurafbeeldingen schermvullend weergeven.",
+ "multimediaviewer-pref": "MediaViewer",
+ "multimediaviewer-pref-desc": "Verbeter uw kijkervaring met deze nieuwe tool. Afbeeldingen worden groter weergegeven op pagina's met thumbnails. Afbeeldingen worden op een prettigere manier schermvullend weergegeven en kunnen ook op ware grootte worden bekeken.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About MediaViewer]</span> inschakelen",
+ "multimediaviewer-file-page": "Naar de bestandspagina gaan",
+ "multimediaviewer-repository-local": "Meer informatie",
+ "multimediaviewer-datetime-created": "Aangemaakt: $1",
+ "multimediaviewer-datetime-uploaded": "Geüpload: $1",
+ "multimediaviewer-credit-fallback": "Auteursgegevens bekijken",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|nog een auteur|nog $1 meer auteurs}}",
+ "multimediaviewer-multiple-authors-combine": "$1 en $2",
+ "multimediaviewer-metadata-error": "Kan afbeeldingsgegevens niet laden (fout: $1)",
+ "multimediaviewer-thumbnail-error": "Sorry, het bestand kan niet worden weergeven",
+ "multimediaviewer-thumbnail-error-description": "Er is een technisch probleem. U kunt $1 of $3 als dit blijft voorkomen. Fout: $2",
+ "multimediaviewer-thumbnail-error-retry": "opnieuw proberen",
+ "multimediaviewer-thumbnail-error-report": "het probleem melden",
+ "multimediaviewer-license-cc-pd": "Publiek domein",
+ "multimediaviewer-license-pd": "Publiek domein",
+ "multimediaviewer-license-default": "Licentie weergeven",
+ "multimediaviewer-permission-title": "Toesteminggegevens",
+ "multimediaviewer-permission-link": "voorwaarden bekijken",
+ "multimediaviewer-permission-link-hide": "voorwaarden verbergen",
+ "multimediaviewer-permission-viewmore": "Meer weergeven",
+ "multimediaviewer-about-mmv": "Over",
+ "multimediaviewer-discuss-mmv": "Overleg",
+ "multimediaviewer-help-mmv": "Hulp",
+ "multimediaviewer-optout-mmv": "MediaViewer uitschakelen",
+ "multimediaviewer-optin-mmv": "MediaViewer inschakelen",
+ "multimediaviewer-optout-pending-mmv": "MediaViewer uitschakelen",
+ "multimediaviewer-optin-pending-mmv": "MediaViewer inschakelen",
+ "multimediaviewer-optin-help": "De MediaViewer wordt gebruikt voor het weergeven van afbeeldingen.",
+ "multimediaviewer-geolocation": "Locatie: $1",
+ "multimediaviewer-reuse-link": "Dit bestand delen of invoegen",
+ "multimediaviewer-reuse-loading-placeholder": "Bezig met laden...",
+ "multimediaviewer-share-tab": "Delen",
+ "multimediaviewer-embed-tab": "Invoegen",
+ "multimediaviewer-download-link": "Dit bestand downloaden",
+ "multimediaviewer-download-preview-link-title": "Weergeven in browser",
+ "multimediaviewer-download-original-button-name": "Oorspronkelijk bestand downloaden",
+ "multimediaviewer-download-small-button-name": "Klein formaat downloaden",
+ "multimediaviewer-download-medium-button-name": "Middelgroot formaat downloaden",
+ "multimediaviewer-download-large-button-name": "Groot formaat downloaden",
+ "multimediaviewer-link-to-page": "Koppeling naar de pagina met de bestandsbeschrijving",
+ "multimediaviewer-link-to-file": "Koppeling naar het originele bestand",
+ "multimediaviewer-share-explanation": "Kopiëren en delen",
+ "multimediaviewer-embed-wt": "Wikitekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Gebruik deze code om het bestand ergens in te voegen",
+ "multimediaviewer-text-embed-credit-text-bl": "Door $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Door $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Door $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Door $1, $2",
+ "multimediaviewer-embed-byline": "Door $1",
+ "multimediaviewer-embed-license": "Licentie $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Standaard miniatuurgrootte",
+ "multimediaviewer-original-embed-dimensions": "Oorspronkelijk bestand $1",
+ "multimediaviewer-large-embed-dimensions": "Groot $1",
+ "multimediaviewer-medium-embed-dimensions": "Middelgroot $1",
+ "multimediaviewer-small-embed-dimensions": "Klein $1",
+ "multimediaviewer-description-page-button-text": "Meer informatie over dit bestand",
+ "multimediaviewer-description-page-popup-text": "Meer informatie over dit bestand op $1",
+ "multimediaviewer-commons-subtitle": "De vrije mediaverzameling",
+ "multimediaviewer-view-expanded": "In MediaViewer openen",
+ "multimediaviewer-view-config": "Configuratie",
+ "multimediaviewer-close-popup-text": "Hulpmiddel sluiten (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "In volledig scherm bekijken",
+ "multimediaviewer-defullscreen-popup-text": "Volledig schermmodus verlaten",
+ "multimediaviewer-next-image-alt-text": "Toon volgende afbeelding",
+ "multimediaviewer-prev-image-alt-text": "Toon vorige afbeelding",
+ "multimediaviewer-title-popup-text": "Beschrijving",
+ "multimediaviewer-credit-popup-text": "Auteur- en broninformatie",
+ "multimediaviewer-title-popup-text-more": "Volledige beschrijving bekijken",
+ "multimediaviewer-credit-popup-text-more": "Volledige auteur en bron bekijken",
+ "multimediaviewer-download-attribution-cta-header": "U moet aan naamsvermelding doen",
+ "multimediaviewer-download-optional-attribution-cta-header": "U kunt aan naamsvermelding doen",
+ "multimediaviewer-download-attribution-cta": "Laat mij zien hoe",
+ "multimediaviewer-attr-plain": "Zonder opmaak",
+ "multimediaviewer-options-tooltip": "MediaViewer in- of uitschakelen",
+ "multimediaviewer-options-dialog-header": "MediaViewer uitschakelen?",
+ "multimediaviewer-options-learn-more": "Meer lezen",
+ "multimediaviewer-option-submit-button": "MediaViewer uitschakelen",
+ "multimediaviewer-option-cancel-button": "Annuleren",
+ "multimediaviewer-disable-confirmation-header": "U hebt de MediaViewer uitgeschakeld",
+ "multimediaviewer-enable-dialog-header": "MediaViewer inschakelen?",
+ "multimediaviewer-enable-submit-button": "MediaViewer inschakelen",
+ "multimediaviewer-enable-alert": "MediaViewer is nu uitgeschakeld",
+ "multimediaviewer-disable-info-title": "U hebt de MediaViewer uitgeschakeld",
+ "multimediaviewer-disable-info": "U kunt nog steeds losse bestanden bekijken met de MediaViewer."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/nn.json b/www/wiki/extensions/MultimediaViewer/i18n/nn.json
new file mode 100644
index 00000000..116856e6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/nn.json
@@ -0,0 +1,92 @@
+{
+ "@metadata": {
+ "authors": [
+ "Njardarlogar"
+ ]
+ },
+ "multimediaviewer-desc": "Vis større storleikar av miniatyrbilete i eit fullskjermgrensesnitt.",
+ "multimediaviewer-pref": "Medieframsynar",
+ "multimediaviewer-pref-desc": "Betra medievisingsopplevinga di med dette nye verktøyet. Det viser fram bilete i større storleikar på sider som har miniatyrbilete. Bileta vert viste i eit betre overlagt fullskjermsgrensesnitt og kan òg visast som fullskjerm.",
+ "multimediaviewer-optin-pref": "Slå på <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About medieframsynaren]</span>",
+ "multimediaviewer-file-page": "Gå til den tilhøyrande filsida",
+ "multimediaviewer-repository-local": "Fleire detaljar",
+ "multimediaviewer-datetime-created": "Oppretta: $1",
+ "multimediaviewer-datetime-uploaded": "Opplasta: $1",
+ "multimediaviewer-credit-fallback": "Sjå informasjon om opphavsperson",
+ "multimediaviewer-multiple-authors": "og {{PLURAL:$1|éin forfattar til|$1 andre forfattarar}}",
+ "multimediaviewer-metadata-error": "Feil: kunne ikkje lasta biletdata. $1",
+ "multimediaviewer-thumbnail-error": "Feil: kunne ikkje lasta miniatyrbiletdata. $1",
+ "multimediaviewer-license-cc-pd": "Offentleg eigedom",
+ "multimediaviewer-license-pd": "Offentleg eigedom",
+ "multimediaviewer-license-default": "Sjå lisens",
+ "multimediaviewer-permission-title": "Lisensdetaljar",
+ "multimediaviewer-permission-link": "sjå vilkår",
+ "multimediaviewer-permission-viewmore": "Sjå meir",
+ "multimediaviewer-about-mmv": "Om medieframsynaren",
+ "multimediaviewer-discuss-mmv": "Diskuter denne funksjonen",
+ "multimediaviewer-help-mmv": "Hjelp",
+ "multimediaviewer-optout-mmv": "Slå av medieframsynaren",
+ "multimediaviewer-optin-mmv": "Slå på medieframsynaren",
+ "multimediaviewer-optout-pending-mmv": "Slår av medieframsynaren",
+ "multimediaviewer-optin-pending-mmv": "Slår på medieframsynaren",
+ "multimediaviewer-optout-help": "Medieframsynaren vil ikkje brukast lenger for å visa bilete. For å bruka han att, klikk på «{{int:multimediaviewer-view-expanded}}»-knappen ved sida av eit kva som helst bilete. Klikk så på «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Medieframsynaren vil brukast til å visa bilete.",
+ "multimediaviewer-geolocation": "Stad: $1",
+ "multimediaviewer-reuse-link": "Bruk eller del fila",
+ "multimediaviewer-reuse-loading-placeholder": "Lastar…",
+ "multimediaviewer-share-tab": "Del",
+ "multimediaviewer-embed-tab": "Inkluder",
+ "multimediaviewer-download-link": "Last ned fila",
+ "multimediaviewer-download-preview-link-title": "Vis i nettlesar",
+ "multimediaviewer-download-original-button-name": "Last ned opphavleg fil",
+ "multimediaviewer-download-small-button-name": "Last ned i liten storleik",
+ "multimediaviewer-download-medium-button-name": "Last ned i mellomstor storleik",
+ "multimediaviewer-download-large-button-name": "Last ned i stor storleik",
+ "multimediaviewer-link-to-page": "Lenkje til filskildringssida",
+ "multimediaviewer-link-to-file": "Lenkje til opphavleg fil",
+ "multimediaviewer-share-explanation": "Kopier lenkja og del henne fritt",
+ "multimediaviewer-embed-wt": "Wikitekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Bruk denne koden for å inkludera fila",
+ "multimediaviewer-embed-byline": "Av $1",
+ "multimediaviewer-embed-license": "Lisensiert under $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Vanleg storleik på minatyrbilete",
+ "multimediaviewer-original-embed-dimensions": "Opphavleg fil $1",
+ "multimediaviewer-large-embed-dimensions": "Stor $1",
+ "multimediaviewer-medium-embed-dimensions": "Mellomstor $1",
+ "multimediaviewer-small-embed-dimensions": "Liten $1",
+ "multimediaviewer-description-page-button-text": "Fleire detaljar om fila",
+ "multimediaviewer-description-page-popup-text": "Fleire detaljar om fila på $1",
+ "multimediaviewer-commons-subtitle": "Det frie medielageret",
+ "multimediaviewer-view-expanded": "Opna i medieframsynaren",
+ "multimediaviewer-view-config": "Innstillingar",
+ "multimediaviewer-close-popup-text": "Lat att verktøyet (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Vis som fullskjerm",
+ "multimediaviewer-defullscreen-popup-text": "Gå ut av fullskjermsmodus",
+ "multimediaviewer-title-popup-text": "Skildring",
+ "multimediaviewer-credit-popup-text": "Opphavsperson- og kjeldeinformasjon",
+ "multimediaviewer-title-popup-text-more": "Sjå heile skildringa",
+ "multimediaviewer-credit-popup-text-more": "Sjå forfattar og kjelde",
+ "multimediaviewer-download-attribution-cta-header": "Du må godskriva opphavspersonen",
+ "multimediaviewer-download-optional-attribution-cta-header": "Du kan godskriva opphavspersonen",
+ "multimediaviewer-download-attribution-cta": "Vis meg korleis",
+ "multimediaviewer-attr-plain": "Enkel",
+ "multimediaviewer-options-tooltip": "Slå av eller på medieframsynaren",
+ "multimediaviewer-options-dialog-header": "Slå av medieframsynaren?",
+ "multimediaviewer-options-text-header": "Ikkje nytt denne visingsmåten for nokon som helst filer.",
+ "multimediaviewer-options-text-body": "Du kan slå han på att seinare gjennom fildetaljsidene.",
+ "multimediaviewer-options-learn-more": "Les meir",
+ "multimediaviewer-option-submit-button": "Slå av medieframsynaren",
+ "multimediaviewer-option-cancel-button": "Bryt av",
+ "multimediaviewer-disable-confirmation-header": "Du har slege av medieframsynaren",
+ "multimediaviewer-disable-confirmation-text": "Du vert sendt rett til alle fildetaljane neste gongen du klikkar på ei miniatyrbilete på $1.",
+ "multimediaviewer-enable-dialog-header": "Slå på medieframsynaren?",
+ "multimediaviewer-enable-text-header": "Slå på denne medieframsyningsfunksjonen for alle filer som standard.",
+ "multimediaviewer-enable-submit-button": "Slå på medieframsynaren",
+ "multimediaviewer-enable-confirmation-header": "Du har slege på medieframsynaren for alle filer",
+ "multimediaviewer-enable-confirmation-text": "Medieframsynaren vert nytta neste gongen du klikkar på ei miniatyrbilete på $1.",
+ "multimediaviewer-enable-alert": "Medieframsynaren er no slegen av",
+ "multimediaviewer-disable-info-title": "Du har slege av medieframsynaren",
+ "multimediaviewer-disable-info": "Du kan framleis sjå einskildfiler med medieframsynaren."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/oc.json b/www/wiki/extensions/MultimediaViewer/i18n/oc.json
new file mode 100644
index 00000000..043fd1d2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/oc.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31"
+ ]
+ },
+ "multimediaviewer-desc": "Agrandís las vinhetas dins una interfàcia en ecran complet.",
+ "multimediaviewer-pref": "Visionadoira de Mèdias",
+ "multimediaviewer-pref-desc": "Melhoratz vòstra experiéncia de visualizacion multimèdia amb aquesta aisina novèla. Aficha los imatges en granda talha sus las paginas qu'an de vinhetas. Los imatges son afichats dins un polit quadre d’interfàcia en ecran complet, e tanben, se pòdon afichar en talha maximala.",
+ "multimediaviewer-file-page": "Anar a la pagina del fichièr correspondent",
+ "multimediaviewer-repository-local": "Mai de detalhs",
+ "multimediaviewer-datetime-created": "Creacion : $1",
+ "multimediaviewer-datetime-uploaded": "Mandat : $1",
+ "multimediaviewer-license-cc-pd": "Domeni public",
+ "multimediaviewer-license-pd": "Domeni public",
+ "multimediaviewer-license-default": "Afichar la licéncia",
+ "multimediaviewer-permission-title": "Detalhs dels dreits",
+ "multimediaviewer-permission-link": "afichar las condicions",
+ "multimediaviewer-permission-viewmore": "Veire mai",
+ "multimediaviewer-about-mmv": "A prepaus",
+ "multimediaviewer-discuss-mmv": "Discussion",
+ "multimediaviewer-help-mmv": "Ajuda",
+ "multimediaviewer-geolocation": "Emplaçament : $1",
+ "multimediaviewer-reuse-link": "Partejar o inclure aqueste fichièr",
+ "multimediaviewer-reuse-loading-placeholder": "Cargament en cors…",
+ "multimediaviewer-download-link": "Telecargar aqueste fichièr",
+ "multimediaviewer-download-preview-link-title": "Afichar dins lo navigador",
+ "multimediaviewer-download-original-button-name": "Telecargar lo fichièr d’origina",
+ "multimediaviewer-download-small-button-name": "Telecargar en pichona talha",
+ "multimediaviewer-download-medium-button-name": "Telecargar en talha mejana",
+ "multimediaviewer-download-large-button-name": "Telecargar en granda talha",
+ "multimediaviewer-default-embed-dimensions": "Talha de vinheta per defaut",
+ "multimediaviewer-original-embed-dimensions": "Fichièr d’origina $1",
+ "multimediaviewer-large-embed-dimensions": "Grand $1",
+ "multimediaviewer-medium-embed-dimensions": "Mejan $1",
+ "multimediaviewer-small-embed-dimensions": "Pichon $1",
+ "multimediaviewer-description-page-button-text": "Mai de detalhs sus aqueste fichièr",
+ "multimediaviewer-description-page-popup-text": "Mai de detalhs sus aqueste fichièr en $1",
+ "multimediaviewer-commons-subtitle": "L'entrepaus de mèdia liure",
+ "multimediaviewer-view-expanded": "Dobrir dins lo Visualizador de mèdias",
+ "multimediaviewer-close-popup-text": "Tampar aquesta aisina (Esc)"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/om.json b/www/wiki/extensions/MultimediaViewer/i18n/om.json
new file mode 100644
index 00000000..79818d7b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/om.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tumsaa"
+ ]
+ },
+ "multimediaviewer-about-mmv": "Waa'ee",
+ "multimediaviewer-discuss-mmv": "Marii"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/or.json b/www/wiki/extensions/MultimediaViewer/i18n/or.json
new file mode 100644
index 00000000..3b7901bd
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/or.json
@@ -0,0 +1,55 @@
+{
+ "@metadata": {
+ "authors": [
+ "Psubhashish"
+ ]
+ },
+ "multimediaviewer-desc": "ପୂରା ସ୍କ୍ରିନରେ ଥମ୍ବନେଲକୁ ବଡ଼ ଆକାର କରିଦିଅନ୍ତୁ ।",
+ "multimediaviewer-pref": "ମିଡ଼ିଆ ଭିଉଅର",
+ "multimediaviewer-pref-desc": "ଏହି ଟୁଲ ବ୍ୟବହାର କରି ଆପଣ ନିଜର ମଲ୍ଟିମିଡ଼ିଆରେ ଦେଖିବାର ଅନୁଭୂତି ବଢ଼ାଇପାରିବେ । ଥମ୍ବନେଲ ଥିବା ପୃଷ୍ଠାମାନଙ୍କରେ ଏହା ଛବିଗୁଡ଼ିକୁ ବଡ଼ କରି ଦେଖାଇଥାଏ । ଏଥିରେ ଛବିସବୁ ସୁନ୍ଦରଭାବେ ପୂରା ସ୍କ୍ରିନରେ ଦେଖିପାରିବେ, ଏବଂ ପୂରା ସ୍କ୍ରିନରେ ମଧ୍ୟ ଦେଖିପାରିବେ ।",
+ "multimediaviewer-optin-pref": "ନୂଆ ମିଡ଼ିଆ ଦେଖିବା ସକ୍ରିୟ କରନ୍ତୁ",
+ "multimediaviewer-file-page": "ଏଥି ସମ୍ବନ୍ଧିତ ଫାଇଲ ପୃଷ୍ଠାକୁ ଯାଆନ୍ତୁ",
+ "multimediaviewer-repository-local": "ଅଧିକ ଜାଣନ୍ତୁ",
+ "multimediaviewer-datetime-created": "$1ରେ ତିଆରି ହେଲା",
+ "multimediaviewer-datetime-uploaded": "$1ରେ ଅପଲୋଡ଼ ହେଲା",
+ "multimediaviewer-metadata-error": "ଚେତାବନୀ: ଛବିର ତଥ୍ୟ ଲୋଡ଼ ହୋଇପାରିଲା ନାହିଁ । $1",
+ "multimediaviewer-thumbnail-error": "ଚେତାବନୀ: ଥମ୍ବନେଲ ତଥ୍ୟ ଲୋଡ଼ ହୋଇପାରିଲା ନାହିଁ । $1",
+ "multimediaviewer-license-cc-pd": "ପବ୍ଲିକ ଡୋମେନ",
+ "multimediaviewer-license-pd": "ପବ୍ଲିକ ଡୋମେନ",
+ "multimediaviewer-license-default": "ଲାଇସେନ୍ସ ଦେଖନ୍ତୁ",
+ "multimediaviewer-permission-title": "ଲାଇସେନ୍ସ ସବିଶେଷ",
+ "multimediaviewer-permission-link": "ସର୍ତ୍ତାବଳୀ ଦେଖନ୍ତୁ",
+ "multimediaviewer-permission-viewmore": "ଅଧିକ ଦେଖନ୍ତୁ",
+ "multimediaviewer-about-mmv": "ମିଡ଼ିଆ ଭିଉଅର ବାବଦରେ",
+ "multimediaviewer-discuss-mmv": "ଏହି ବୈଶିଷ୍ଠଟି ଆଲୋଚନା କରନ୍ତୁ",
+ "multimediaviewer-help-mmv": "ସହଯୋଗ",
+ "multimediaviewer-geolocation": "ଅବସ୍ଥିତି: $1",
+ "multimediaviewer-reuse-link": "ଏହି ଫାଇଲ ବ୍ୟବହାର କରନ୍ତୁ",
+ "multimediaviewer-reuse-loading-placeholder": "ଖୋଲୁଅଛି...",
+ "multimediaviewer-share-tab": "ବିତରଣ କରନ୍ତୁ",
+ "multimediaviewer-embed-tab": "ଏମବେଡ଼",
+ "multimediaviewer-download-link": "ଡାଉନଲୋଡ଼",
+ "multimediaviewer-download-preview-link-title": "ବ୍ରାଉଜରରେ ଦେଖନ୍ତୁ",
+ "multimediaviewer-download-original-button-name": "ମୂଳ ଆକାର ଡାଉନଲୋଡ଼ କରନ୍ତୁ",
+ "multimediaviewer-download-small-button-name": "ଛୋଟ ଆକାର ଡାଉନଲୋଡ଼ କରନ୍ତୁ",
+ "multimediaviewer-download-medium-button-name": "ମଧ୍ୟମ ଆକାର ଡାଉନଲୋଡ଼ କରନ୍ତୁ",
+ "multimediaviewer-download-large-button-name": "ବଡ଼ ଆକାର ଡାଉନଲୋଡ଼ କରନ୍ତୁ",
+ "multimediaviewer-link-to-page": "ବିବରଣ ପୃଷ୍ଠା ସହିତ ଲିଙ୍କ କରନ୍ତୁ",
+ "multimediaviewer-link-to-file": "ମୂଳ ପୃଷ୍ଠା ସହିତ ଲିଙ୍କ କରନ୍ତୁ",
+ "multimediaviewer-share-explanation": "ନକଲ କରି ଖୋଲାରେ ଏହି ଲିଙ୍କଟି ବିତରଣ କରନ୍ତୁ",
+ "multimediaviewer-embed-wt": "ଉଇକିଟେକ୍ସଟ",
+ "multimediaviewer-embed-html": "ଏଚଟିଏମଏଲ",
+ "multimediaviewer-embed-explanation": "ଫାଇଲଟି ଏମବେଡ଼ କରିବା ପାଇଁ ଏହି କୋଡ଼ ଦିଅନ୍ତୁ",
+ "multimediaviewer-embed-byline": "$1ଙ୍କ ଦ୍ୱାରା",
+ "multimediaviewer-embed-license": "$1 ଲାଇସେନ୍ସରେ ପ୍ରକାଶିତ ।",
+ "multimediaviewer-embed-via": "$1ଙ୍କ ଦ୍ୱାରା",
+ "multimediaviewer-default-embed-dimensions": "ଡିଫଲ୍ଟ ଥମ୍ବନେଲ ଆକାର",
+ "multimediaviewer-original-embed-dimensions": "ମୂଳ ଆକାର $1",
+ "multimediaviewer-large-embed-dimensions": "ଆକାର $1",
+ "multimediaviewer-medium-embed-dimensions": "ମଧ୍ୟମ $1",
+ "multimediaviewer-small-embed-dimensions": "ଛୋଟ $1",
+ "multimediaviewer-description-page-button-text": "ସବିଶେଷ",
+ "multimediaviewer-description-page-popup-text": "$1 ବାବଦରେ ଅଧିକ ସବିଶେଷ",
+ "multimediaviewer-commons-subtitle": "ଖୋଲା ମିଡ଼ିଆ ଭଣ୍ଡାରଟିଏ",
+ "multimediaviewer-view-expanded": "ବଡ଼କରି ଦେଖାଇବେ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/pa.json b/www/wiki/extensions/MultimediaViewer/i18n/pa.json
new file mode 100644
index 00000000..5a9d834f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/pa.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Babanwalia"
+ ]
+ },
+ "multimediaviewer-repository-local": "ਹੋਰ ਵੇਰਵਾ",
+ "multimediaviewer-download-link": "ਇਹ ਫ਼ਾਈਲ ਲਾਹੋ",
+ "multimediaviewer-view-expanded": "ਮੀਡੀਆ ਵਿਖਾਊ 'ਚ ਖੋਲ੍ਹੋ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/pl.json b/www/wiki/extensions/MultimediaViewer/i18n/pl.json
new file mode 100644
index 00000000..ede7c224
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/pl.json
@@ -0,0 +1,110 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chrumps",
+ "Jacenty359",
+ "Matik7",
+ "Nux",
+ "Peter Bowman",
+ "Tar Lócesilion",
+ "WTM",
+ "Blackfish",
+ "Matma Rex",
+ "Darellur",
+ "Macofe"
+ ]
+ },
+ "multimediaviewer-desc": "Powiększ miniatury ilustracji do wielkości ekranu.",
+ "multimediaviewer-pref": "Przeglądarka multimediów",
+ "multimediaviewer-pref-desc": "Popraw sposób oglądania ilustracji używając tego nowego narzędzia. Wyświetla ono ilustracje w większym rozmiarze bezpośrednio na stronach, które mają miniatury. Ilustracje te wyświetlane są w ładniejszym pełnoekranowym interfejsie, a nawet mogą być oglądane w pełnym rozmiarze.",
+ "multimediaviewer-optin-pref": "Aktywuj <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About przeglądarkę multimediów]</span>",
+ "multimediaviewer-file-page": "Przejdź na stronę opisu pliku",
+ "multimediaviewer-repository-local": "Więcej szczegółów",
+ "multimediaviewer-datetime-created": "Utworzony: $1",
+ "multimediaviewer-datetime-uploaded": "Przesłany: $1",
+ "multimediaviewer-credit-fallback": "Pokaż informacje o autorze",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|jeden inny autor|$1 innych autorów}}",
+ "multimediaviewer-multiple-authors-combine": "$1 i $2",
+ "multimediaviewer-metadata-error": "Nie można załadować szczegółów obrazu (błąd: $1)",
+ "multimediaviewer-thumbnail-error": "Niestety, nie można wyświetlić pliku",
+ "multimediaviewer-thumbnail-error-description": "Wygląda na to, że mamy problem techniczny. Możesz $1 lub $3, jeśli będzie nadal występował. Błąd: $2",
+ "multimediaviewer-thumbnail-error-retry": "ponowić próbę",
+ "multimediaviewer-thumbnail-error-report": "zgłosić problem",
+ "multimediaviewer-license-cc-pd": "Domena publiczna",
+ "multimediaviewer-license-pd": "Domena publiczna",
+ "multimediaviewer-license-default": "Zobacz licencję",
+ "multimediaviewer-permission-title": "Szczegóły pozwolenia",
+ "multimediaviewer-permission-link": "zobacz zasady",
+ "multimediaviewer-permission-viewmore": "Zobacz więcej",
+ "multimediaviewer-restriction-ihl": "Ten obrazek zawiera symbole zastrzeżone przez prawo konfliktów zbrojnych.",
+ "multimediaviewer-about-mmv": "O aplikacji",
+ "multimediaviewer-discuss-mmv": "Dyskusja",
+ "multimediaviewer-help-mmv": "Pomoc",
+ "multimediaviewer-optout-mmv": "Dezaktywuj przeglądarkę multimediów",
+ "multimediaviewer-optin-mmv": "Aktywuj przeglądarkę multimediów",
+ "multimediaviewer-optout-pending-mmv": "Dezaktywacja przeglądarki multimediów",
+ "multimediaviewer-optin-pending-mmv": "Aktywacja przeglądarki multimediów",
+ "multimediaviewer-optout-help": "Do przeglądania grafiki nie będzie już dłużej wykorzystywana przeglądarka multimedów. Aby użyć jej ponownie, kliknij na przycisk „{{int:multimediaviewer-view-expanded}}” w dowolnej grafice. Następnie kliknij na „{{int:multimediaviewer-optin-mmv}}”.",
+ "multimediaviewer-optin-help": "Przeglądarka multimediów będzie używana do wyświetlania grafik.",
+ "multimediaviewer-geolocation": "Położenie: $1",
+ "multimediaviewer-reuse-link": "Podziel się tym plikiem lub umieść go",
+ "multimediaviewer-reuse-loading-placeholder": "Wczytywanie…",
+ "multimediaviewer-share-tab": "Udostępnij",
+ "multimediaviewer-embed-tab": "Osadź",
+ "multimediaviewer-download-link": "Pobierz ten plik",
+ "multimediaviewer-download-preview-link-title": "Otwórz w przeglądarce",
+ "multimediaviewer-download-original-button-name": "Pobierz oryginalny plik",
+ "multimediaviewer-download-small-button-name": "Pobierz w małym rozmiarze",
+ "multimediaviewer-download-medium-button-name": "Pobierz w średnim rozmiarze",
+ "multimediaviewer-download-large-button-name": "Pobierz w dużym rozmiarze",
+ "multimediaviewer-link-to-page": "Link do strony opisu pliku",
+ "multimediaviewer-link-to-file": "Link do oryginalnego pliku",
+ "multimediaviewer-share-explanation": "Skopiuj i swobodnie dziel się linkiem",
+ "multimediaviewer-embed-wt": "Wikikod",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Wykorzystaj ten kod do osadzenia pliku",
+ "multimediaviewer-html-embed-credit-link-text": "Link",
+ "multimediaviewer-embed-byline": "Autor: $1",
+ "multimediaviewer-embed-license": "Licencja: $1.",
+ "multimediaviewer-embed-via": "Na podstawie $1",
+ "multimediaviewer-default-embed-dimensions": "Domyślny rozmiar miniatury",
+ "multimediaviewer-original-embed-dimensions": "Oryginalny plik $1",
+ "multimediaviewer-large-embed-dimensions": "Duży rozmiar $1",
+ "multimediaviewer-medium-embed-dimensions": "Średni rozmiar $1",
+ "multimediaviewer-small-embed-dimensions": "Mały rozmiar $1",
+ "multimediaviewer-description-page-button-text": "Więcej szczegółów o pliku",
+ "multimediaviewer-description-page-popup-text": "Więcej szczegółów na temat tego pliku $1",
+ "multimediaviewer-commons-subtitle": "Repozytorium wolnych mediów",
+ "multimediaviewer-view-expanded": "Otwórz w Media Viewer",
+ "multimediaviewer-view-config": "Konfiguracja",
+ "multimediaviewer-close-popup-text": "Zamknij narzędzie (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Pokaż w trybie pełnoekranowym",
+ "multimediaviewer-defullscreen-popup-text": "Wyjdź z trybu pełnoekranowego",
+ "multimediaviewer-next-image-alt-text": "Pokaż następny obraz",
+ "multimediaviewer-prev-image-alt-text": "Pokaż poprzedni obraz",
+ "multimediaviewer-title-popup-text": "Opis",
+ "multimediaviewer-credit-popup-text": "Informacje o autorze i źródle",
+ "multimediaviewer-title-popup-text-more": "Zobacz pełny opis",
+ "multimediaviewer-credit-popup-text-more": "Pokaż pełne informacje o autorze i źródle",
+ "multimediaviewer-download-attribution-cta-header": "Powinieneś oznaczyć autora",
+ "multimediaviewer-download-optional-attribution-cta-header": "Możesz oznaczyć autora",
+ "multimediaviewer-download-attribution-cta": "Pokaż jak",
+ "multimediaviewer-attr-plain": "Zwykły tekst",
+ "multimediaviewer-options-tooltip": "Włącz albo wyłącz Media Viewer",
+ "multimediaviewer-options-dialog-header": "Wyłączyć Media Viewer?",
+ "multimediaviewer-options-text-header": "Pomiń wyświetlanie tej funkcji we wszystkich plikach.",
+ "multimediaviewer-options-text-body": "Możesz ją później wyłączyć na stronie ze szczegółami pliku.",
+ "multimediaviewer-options-learn-more": "Dowiedz się więcej",
+ "multimediaviewer-option-submit-button": "Wyłącz Media Viewer",
+ "multimediaviewer-option-cancel-button": "Anuluj",
+ "multimediaviewer-disable-confirmation-header": "Wyłączyłeś Media Viewer",
+ "multimediaviewer-disable-confirmation-text": "Kiedy następnym razem klikniesz na $1, od razu wyświetlą ci się wszystkie szczegóły pliku.",
+ "multimediaviewer-enable-dialog-header": "Włączyć Media Viewer?",
+ "multimediaviewer-enable-text-header": "Włącz to narzędzie wyświetlania multimediów domyślnie dla wszystkich plików.",
+ "multimediaviewer-enable-submit-button": "Włącz Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "Włączyłeś Media Viewer dla wszystkich plików",
+ "multimediaviewer-enable-confirmation-text": "Kiedy następnym razem klikniesz na miniaturkę na $1, wyświetli się Media Viewer.",
+ "multimediaviewer-enable-alert": "Media Viewer jest wyłączony",
+ "multimediaviewer-disable-info-title": "Wyłączyłeś Media Viewer",
+ "multimediaviewer-disable-info": "Wciąż możesz oglądać pojedyncze pliki za pomocą Media Viewera"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ps.json b/www/wiki/extensions/MultimediaViewer/i18n/ps.json
new file mode 100644
index 00000000..ec1cfee1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ps.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ahmed-Najib-Biabani-Ibrahimkhel"
+ ]
+ },
+ "multimediaviewer-pref": "رسنۍ ښکاره کوونکی",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About رسنۍ کتونکی]</span> چارنول",
+ "multimediaviewer-repository-local": "نور تفصيل",
+ "multimediaviewer-datetime-created": "په $1 جوړ شو",
+ "multimediaviewer-datetime-uploaded": "په $1 پورته شو",
+ "multimediaviewer-credit-fallback": "د ليکوال مالومات کتل",
+ "multimediaviewer-license-cc-pd": "ټولگړی شپول",
+ "multimediaviewer-license-default": "د منښتليک مالومات",
+ "multimediaviewer-permission-title": "د اجازې تفصيل",
+ "multimediaviewer-about-mmv": "په اړه",
+ "multimediaviewer-discuss-mmv": "خبرې اترې",
+ "multimediaviewer-optout-mmv": "رسنۍ کتونکی ناچارنول",
+ "multimediaviewer-optin-mmv": "رسنۍ کتونکی چارنول",
+ "multimediaviewer-optout-pending-mmv": "رسنۍ کتونکی ناچارنول",
+ "multimediaviewer-reuse-link": "دا دوتنه کارول",
+ "multimediaviewer-download-link": "همدا دوتنه ښکته کول",
+ "multimediaviewer-download-preview-link-title": "په کتنمل کې کتل",
+ "multimediaviewer-download-original-button-name": "اصلي دوتنه ښکته کول",
+ "multimediaviewer-link-to-file": "اصلي دوتنې ته تړنه",
+ "multimediaviewer-original-embed-dimensions": "اصلي دوتنه $1",
+ "multimediaviewer-view-expanded": "په رسنۍ کتونکي کې پرانيستل",
+ "multimediaviewer-close-popup-text": "دا اوزار تړل (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "په ډکه پرده کې ښکاره کول",
+ "multimediaviewer-download-optional-attribution-cta-header": "ليکوال ته يې اړونده کولی شی",
+ "multimediaviewer-options-tooltip": "رسنۍ کتونکی چارنول يا ناچارنول",
+ "multimediaviewer-options-dialog-header": "آيا رسنۍ کتونکی ناچارنوې؟",
+ "multimediaviewer-options-text-header": "د ټولو دوتنو لپاره د کتلو همدغو ځانتياوو څخه تېرېدل.",
+ "multimediaviewer-options-text-body": "تاسې يې د مخ تفصيلونو له مخې وروسته چارنولی شئ.",
+ "multimediaviewer-option-submit-button": "رسنۍ کتونکی ناچارنول",
+ "multimediaviewer-disable-confirmation-text": "بل ځل ته چې تاسې د $1 په يو بټنوک ټک ورکوئ، نو سمدلاسه به د دوتنې ټول تفصيل درښکاره شي.",
+ "multimediaviewer-enable-dialog-header": "رسنۍ کتونکی چارنوې؟",
+ "multimediaviewer-enable-text-header": "د همدې رسنۍ د کتلو ځانتياوې په تلواليزه توگه د ټولو دوتنو لپاره چارنول.",
+ "multimediaviewer-enable-submit-button": "رسنۍ کتونکی چارنول",
+ "multimediaviewer-enable-confirmation-header": "تاسې د ټولو دوتنو لپاره رسنۍ کتونکی چارن کړی",
+ "multimediaviewer-enable-confirmation-text": "بل ځل ته چې تاسې د $1 په يو بټنوک ټک ورکوئ، نو رسنۍ کتونکی به وکارېږي.",
+ "multimediaviewer-disable-info-title": "تاسې رسنۍ کتونکی ناچارن کړ",
+ "multimediaviewer-disable-info": "تاسې لا تر اوسه پورې د رسنۍ کتونکي په مرسته ځانگړې دوتنې کتلی شی."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/pt-br.json b/www/wiki/extensions/MultimediaViewer/i18n/pt-br.json
new file mode 100644
index 00000000..3f768ac8
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/pt-br.json
@@ -0,0 +1,161 @@
+{
+ "@metadata": {
+ "authors": [
+ "Oona",
+ "Jefersonmoraes",
+ "Ptrke",
+ "TheEduGobi",
+ "Araceletorres",
+ "Macofe",
+ "Eduardo Addad de Oliveira",
+ "Felipe L. Ewald"
+ ]
+ },
+ "multimediaviewer-desc": "Expandir miniaturas em tamanho maior numa interface em tela cheia.",
+ "multimediaviewer-pref": "Visualizador multimídia",
+ "multimediaviewer-pref-desc": "Melhore a sua experiência de visualização multimídia com esta nova ferramenta. Ela exibe imagens em tamanho maior nas páginas que possuam miniaturas. As imagens são exibidas em uma agradável sobreposição em tela cheia, e também podem ser visualizadas em tamanho real.",
+ "multimediaviewer-optin-pref": "Ativar <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Ir para a página do arquivo correspondente",
+ "multimediaviewer-repository-local": "Mais detalhes",
+ "multimediaviewer-datetime-created": "Criada: $1",
+ "multimediaviewer-datetime-uploaded": "Enviado: $1",
+ "multimediaviewer-credit": "$1 - $2",
+ "multimediaviewer-credit-fallback": "Ver informações de autor",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|mais um autor|mais $1 autores}}",
+ "multimediaviewer-multiple-authors-combine": "$1 e $2",
+ "multimediaviewer-metadata-error": "Não foi possível carregar os detalhes da imagem (error:$1)",
+ "multimediaviewer-thumbnail-error": "Desculpe, o arquivo não pode ser exibido",
+ "multimediaviewer-thumbnail-error-description": "Parece haver um problema técnico. Você pode $1 ou $3, caso o problema continue. Erro: $2",
+ "multimediaviewer-thumbnail-error-retry": "tentar novamente",
+ "multimediaviewer-thumbnail-error-report": "comunicar o erro",
+ "multimediaviewer-license-cc-by-1.0": "CC BY 1.0",
+ "multimediaviewer-license-cc-sa-1.0": "CC SA 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC BY 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Domínio Público",
+ "multimediaviewer-license-cc-zero": "CC 0",
+ "multimediaviewer-license-pd": "Domínio Público",
+ "multimediaviewer-license-default": "Ver licença",
+ "multimediaviewer-permission-title": "Detalhes da permissão",
+ "multimediaviewer-permission-link": "ver termos",
+ "multimediaviewer-permission-link-hide": "ocultar termos",
+ "multimediaviewer-permission-viewmore": "Ver mais",
+ "multimediaviewer-restriction-2257": "Esta imagem contém conteúdo sexualmente explícito que pode estar sujeito à Lei de Proteção à Criança e Proteção de Obscenidade nos Estados Unidos.",
+ "multimediaviewer-restriction-aus-reserve": "Esta imagem foi fotografada em uma reserva da Commonwealth australiana e não pode ser usada para ganhos comerciais sem autorização.",
+ "multimediaviewer-restriction-communist": "Esta imagem contém insígnias comunistas que podem ser banidas em alguns países.",
+ "multimediaviewer-restriction-costume": "Esta imagem representa fantasias e pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-currency": "Esta imagem representa uma representação de uma unidade de moeda e pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-design": "O design do assunto desta imagem pode ser protegido por direitos autorais e sujeito a restrições legais.",
+ "multimediaviewer-restriction-fan-art": "Esta imagem é um trabalho de arte de fãs e a reutilização pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-ihl": "Esta imagem contém símbolos restritos pelo Direito Internacional Humanitário.",
+ "multimediaviewer-restriction-insignia": "Esta imagem contém insígnias oficiais que podem estar sujeitas a restrições legais.",
+ "multimediaviewer-restriction-ita-mibac": "Esta imagem reproduz uma propriedade pertencente ao patrimônio cultural italiano e é restringida pela lei italiana.",
+ "multimediaviewer-restriction-nazi": "Esta imagem contém nazistas ou outras insígnias fascistas que podem ser banidas em alguns países.",
+ "multimediaviewer-restriction-personality": "Esta imagem contém pessoas que podem ter direitos que restringem legalmente certas reutilizações da imagem sem consentimento.",
+ "multimediaviewer-restriction-trademarked": "Esta imagem contém conteúdo que pode estar sujeito a leis de marca registada.",
+ "multimediaviewer-restriction-default": "Esta imagem pode ser restrita por disposições legais fora da lei de direitos autorais. Veja a página de descrição do arquivo para obter detalhes.",
+ "multimediaviewer-restriction-default-and-others": "Esta imagem pode ser restringida por outras disposições legais fora da lei de direitos autorais. Veja a página de descrição do arquivo para obter detalhes.",
+ "multimediaviewer-about-mmv": "Sobre",
+ "multimediaviewer-discuss-mmv": "Discussão",
+ "multimediaviewer-help-mmv": "Ajuda",
+ "multimediaviewer-optout-mmv": "Desativar visualizador multimídia",
+ "multimediaviewer-optin-mmv": "Ativar visualizador multimídia",
+ "multimediaviewer-optout-pending-mmv": "Desativar visualizador multimídia",
+ "multimediaviewer-optin-pending-mmv": "Ativar visualizador multimídia",
+ "multimediaviewer-optout-help": "O visualizador multimídia não será mais utilizado para exibir imagens. Para ativá-lo novamente, clique no botão \"{{int:multimediaviewer-view-expanded}}\" próximo a qualquer imagem. Depois, clique em \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "O visualizador multimídia será utilizado para exibir imagens.",
+ "multimediaviewer-geoloc-north": "N",
+ "multimediaviewer-geoloc-east": "E",
+ "multimediaviewer-geoloc-south": "S",
+ "multimediaviewer-geoloc-west": "W",
+ "multimediaviewer-geoloc-coord": "$1 $2 $3 $4",
+ "multimediaviewer-geoloc-coords": "$1, $2",
+ "multimediaviewer-geolocation": "Localização: $1",
+ "multimediaviewer-reuse-link": "Compartilhar ou anexar este arquivo",
+ "multimediaviewer-reuse-loading-placeholder": "Carregando…",
+ "multimediaviewer-reuse-copy-share": "Seleciona e copia (se suportado) o link para compartilhar este arquivo",
+ "multimediaviewer-reuse-copy-embed": "Seleciona e copia (se suportado) o código para incorporar este arquivo",
+ "multimediaviewer-share-tab": "Compartilhar",
+ "multimediaviewer-embed-tab": "Incorporar",
+ "multimediaviewer-download-link": "Baixar este arquivo",
+ "multimediaviewer-download-preview-link-title": "Ver no navegador",
+ "multimediaviewer-download-original-button-name": "Baixar arquivo original",
+ "multimediaviewer-download-small-button-name": "Baixar em tamanho pequeno",
+ "multimediaviewer-download-medium-button-name": "Baixar em tamanho médio",
+ "multimediaviewer-download-large-button-name": "Baixar em tamanho grande",
+ "multimediaviewer-link-to-page": "Link para a página de descrição do arquivo",
+ "multimediaviewer-link-to-file": "Link para o arquivo original",
+ "multimediaviewer-share-explanation": "Copiar e compartilhar o link",
+ "multimediaviewer-embed-wt": "Wikitexto",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Usar este código para incorporar o arquivo",
+ "multimediaviewer-text-embed-credit-text-bl": "Por $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Por $1, $2",
+ "multimediaviewer-text-embed-credit-text-l": "$1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Por $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Por $1, $2",
+ "multimediaviewer-html-embed-credit-text-l": "$1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Link",
+ "multimediaviewer-embed-byline": "Por $1",
+ "multimediaviewer-embed-license": "Licenciado sob $1.",
+ "multimediaviewer-embed-license-nonfree": "$1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Tamanho de miniatura padrão",
+ "multimediaviewer-original-embed-dimensions": "Arquivo original $1",
+ "multimediaviewer-large-embed-dimensions": "Grande $1",
+ "multimediaviewer-medium-embed-dimensions": "Médio $1",
+ "multimediaviewer-small-embed-dimensions": "Pequeno $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2",
+ "multimediaviewer-embed-dimensions-separated": "- $1",
+ "multimediaviewer-description-page-button-text": "Mais detalhes sobre este arquivo",
+ "multimediaviewer-description-page-popup-text": "Mais detalhes sobre este arquivo em $1",
+ "multimediaviewer-commons-subtitle": "O repositório de mídias livres",
+ "multimediaviewer-view-expanded": "Abrir no Visualizador de Mídia",
+ "multimediaviewer-view-config": "Configuração",
+ "multimediaviewer-close-popup-text": "Fechar esta ferramenta (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Mostrar em tela inteira",
+ "multimediaviewer-defullscreen-popup-text": "Sair do modo tela inteira",
+ "multimediaviewer-next-image-alt-text": "Mostrar próxima imagem",
+ "multimediaviewer-prev-image-alt-text": "Mostrar imagem anterior",
+ "multimediaviewer-title-popup-text": "Descrição",
+ "multimediaviewer-credit-popup-text": "Autor e informação sobre a fonte",
+ "multimediaviewer-title-popup-text-more": "Ver descrição completa",
+ "multimediaviewer-credit-popup-text-more": "Ver nome completo do autor e fonte",
+ "multimediaviewer-download-attribution-cta-header": "Você precisa indicar o autor",
+ "multimediaviewer-download-optional-attribution-cta-header": "Você pode indicar o autor",
+ "multimediaviewer-download-attribution-cta": "Mostre-me como",
+ "multimediaviewer-download-attribution-copy": "Seleciona e copia (se suportado) o texto de atribuição para este arquivo",
+ "multimediaviewer-reuse-warning-deletion": "Este arquivo é considerado para exclusão.",
+ "multimediaviewer-reuse-warning-nonfree": "Este arquivo não possui uma licença gratuita.",
+ "multimediaviewer-reuse-warning-noattribution": "Este arquivo não possui informações de atribuição.",
+ "multimediaviewer-reuse-warning-generic": "Verifique [$1 os detalhes] antes de utilizá-lo.",
+ "multimediaviewer-attr-plain": "Simples",
+ "multimediaviewer-attr-html": "HTML",
+ "multimediaviewer-options-tooltip": "Ativar ou desativar visualizador multimídia",
+ "multimediaviewer-options-dialog-header": "Desativar visualizador multimídia?",
+ "multimediaviewer-options-text-header": "Ignorar este recurso de visualização para todos os arquivos.",
+ "multimediaviewer-options-text-body": "Você pode reativá-lo mais tarde através da página de detalhes dos arquivos.",
+ "multimediaviewer-options-learn-more": "Saiba mais",
+ "multimediaviewer-option-submit-button": "Desativar visualizador multimídia",
+ "multimediaviewer-option-cancel-button": "Cancelar",
+ "multimediaviewer-disable-confirmation-header": "Você desativou o visualizador multimídia",
+ "multimediaviewer-disable-confirmation-text": "Da próxima vez que você clicar numa miniatura em $1, terá acesso direto aos detalhes do arquivo.",
+ "multimediaviewer-enable-dialog-header": "Ativar visualizador multimídia?",
+ "multimediaviewer-enable-text-header": "Ativar este recurso de visualização multimídia para todos os arquivos por padrão.",
+ "multimediaviewer-enable-submit-button": "Ativar visualizador multimídia",
+ "multimediaviewer-enable-confirmation-header": "Você ativou o visualizador multimídia para todos os arquivos",
+ "multimediaviewer-enable-confirmation-text": "Da próxima vez que você clicar numa miniatura em $1, o visualizador multimídia será usado.",
+ "multimediaviewer-enable-alert": "O visualizador multimídia agora está desativado",
+ "multimediaviewer-disable-info-title": "Você desativou o visualizador multimídia",
+ "multimediaviewer-disable-info": "Você pode ainda ver os arquivos individuais com o visualizador multimídia.",
+ "multimediaviewer-errorreport-privacywarning": "Os detalhes do erro são anexados ao relatório, que será visível publicamente. Se você não está confortável com isso, você pode editar o relatório abaixo e remover todos os dados que você não deseja compartilhar."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/pt.json b/www/wiki/extensions/MultimediaViewer/i18n/pt.json
new file mode 100644
index 00000000..0b0d1f40
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/pt.json
@@ -0,0 +1,132 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fúlvio",
+ "Imperadeiro98",
+ "SandroHc",
+ "Vitorvicentevalente",
+ "Macofe",
+ "Hamilton Abreu"
+ ]
+ },
+ "multimediaviewer-desc": "Ampliar miniaturas para tamanho maior em ecrã cheio.",
+ "multimediaviewer-pref": "Visualizador Multimédia",
+ "multimediaviewer-pref-desc": "Melhore a sua experiência de visionamento multimédia com esta ferramenta nova. Ela apresenta imagens em tamanho maior nas páginas que tenham miniaturas. As imagens são mostradas numa agradável sobreposição em ecrã cheio e também podem ser vistas em tamanho real.",
+ "multimediaviewer-optin-pref": "Ativar <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Visualizador Multimédia]</span>",
+ "multimediaviewer-file-page": "Ir para a página de ficheiro correspondente",
+ "multimediaviewer-repository-local": "Mais detalhes",
+ "multimediaviewer-datetime-created": "Criação: $1",
+ "multimediaviewer-datetime-uploaded": "Carregamento: $1",
+ "multimediaviewer-credit-fallback": "Ver informação do autor",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|mais um autor|mais $1 autores}}",
+ "multimediaviewer-multiple-authors-combine": "$1 e $2",
+ "multimediaviewer-metadata-error": "Não foi possível carregar os dados da imagem (erro: $1)",
+ "multimediaviewer-thumbnail-error": "Desculpe, o ficheiro não pode ser apresentado",
+ "multimediaviewer-thumbnail-error-description": "Parece haver um problema técnico. Pode $1 ou $3, caso o problema continue. Erro: $2",
+ "multimediaviewer-thumbnail-error-retry": "tentar novamente",
+ "multimediaviewer-thumbnail-error-report": "comunicar o erro",
+ "multimediaviewer-license-cc-pd": "Domínio Público",
+ "multimediaviewer-license-pd": "Domínio público",
+ "multimediaviewer-license-default": "Ver licença",
+ "multimediaviewer-permission-title": "Detalhes da permissão",
+ "multimediaviewer-permission-link": "ver termos",
+ "multimediaviewer-permission-link-hide": "ocultar termos",
+ "multimediaviewer-permission-viewmore": "Ver mais",
+ "multimediaviewer-restriction-2257": "Esta imagem contém conteúdo sexualmente explícito que pode estar sujeito ao Child Protection and Obscenity Enforcement Act nos Estados Unidos.",
+ "multimediaviewer-restriction-aus-reserve": "Esta imagem foi fotografada numa reserva da Comunidade Australiana e não pode ser usada para fins comerciais sem autorização.",
+ "multimediaviewer-restriction-communist": "Esta imagem contém uma insígnia comunista que pode ser proibida em alguns países.",
+ "multimediaviewer-restriction-costume": "Esta imagem mostra objetos de vestuário e pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-currency": "Esta imagem representa uma unidade monetária e pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-design": "A conceção do motivo desta imagem pode estar protegida por direitos de autor e sujeita a restrições legais.",
+ "multimediaviewer-restriction-fan-art": "Esta imagem é um trabalho de arte de fãs (''fan art''), e pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-ihl": "Esta imagem contém símbolos restringidos pelo Direito Humanitário Internacional",
+ "multimediaviewer-restriction-insignia": "Esta imagem contém uma insígnia oficial que pode estar sujeita a restrições legais.",
+ "multimediaviewer-restriction-ita-mibac": "Esta imagem reproduz uma propriedade que pertence à herança cultural italiana e está restringida pela lei italiana.",
+ "multimediaviewer-restriction-nazi": "Esta imagem contém uma insígnia nazista ou outra considerada fascista que pode ser proibida em alguns países.",
+ "multimediaviewer-restriction-personality": "Esta imagem contém pessoas que podem deter direitos de restrição legal de certas reutilizações da imagem sem autorização.",
+ "multimediaviewer-restriction-trademarked": "Esta imagem contém conteúdos que podem estar sujeitos a legislação sobre marcas registadas.",
+ "multimediaviewer-restriction-default": "O uso desta imagem pode estar restringido por disposições legais fora do âmbito da legislação de direitos de autor. Veja a página de descrição do ficheiro para detalhes.",
+ "multimediaviewer-restriction-default-and-others": "O uso desta imagem pode estar restringido por disposições legais fora do âmbito da legislação de direitos de autor. Veja a página de descrição do ficheiro para detalhes.",
+ "multimediaviewer-about-mmv": "Sobre",
+ "multimediaviewer-discuss-mmv": "Discussão",
+ "multimediaviewer-help-mmv": "Ajuda",
+ "multimediaviewer-optout-mmv": "Desativar Visualizador Multimédia",
+ "multimediaviewer-optin-mmv": "Ativar Visualizador Multimédia",
+ "multimediaviewer-optout-pending-mmv": "A desativar o Visualizador Multimédia",
+ "multimediaviewer-optin-pending-mmv": "A ativar o Visualizador Multimédia",
+ "multimediaviewer-optout-help": "O Visualizador Multimédia deixará de ser utilizado para mostrar imagens. Para o ativar novamente, clique o botão \"{{int:multimediaviewer-view-expanded}}\" ao lado de qualquer imagem. Depois, clique \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "O Visualizador Multimédia será utilizado para mostrar imagens.",
+ "multimediaviewer-geolocation": "Localização: $1",
+ "multimediaviewer-reuse-link": "Partilhar ou incorporar este ficheiro",
+ "multimediaviewer-reuse-loading-placeholder": "A carregar...",
+ "multimediaviewer-reuse-copy-share": "Selecionar e copiar (se suportado) a hiperligação para partilhar este ficheiro",
+ "multimediaviewer-reuse-copy-embed": "Seleciona e copia (se suportado) o código para incorporar este ficheiro",
+ "multimediaviewer-share-tab": "Partilhar",
+ "multimediaviewer-embed-tab": "Incorporar",
+ "multimediaviewer-download-link": "Descarregar este ficheiro",
+ "multimediaviewer-download-preview-link-title": "Visualizar no navegador",
+ "multimediaviewer-download-original-button-name": "Descarregar em tamanho original",
+ "multimediaviewer-download-small-button-name": "Descarregar em tamanho pequeno",
+ "multimediaviewer-download-medium-button-name": "Descarregar em tamanho médio",
+ "multimediaviewer-download-large-button-name": "Descarregar em tamanho grande",
+ "multimediaviewer-link-to-page": "Hiperligação para a página de descrição do ficheiro",
+ "multimediaviewer-link-to-file": "Hiperligação para o ficheiro original",
+ "multimediaviewer-share-explanation": "Copiar e partilhar livremente a hiperligação",
+ "multimediaviewer-embed-wt": "Texto wiki",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Usar este código para incorporar o ficheiro",
+ "multimediaviewer-text-embed-credit-text-bl": "Por $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Por $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Por $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Por $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Hiperligação",
+ "multimediaviewer-embed-byline": "Por $1",
+ "multimediaviewer-embed-license": "Licenciado ao abrigo da licença $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Tamanho de miniatura padrão",
+ "multimediaviewer-original-embed-dimensions": "Tamanho original $1",
+ "multimediaviewer-large-embed-dimensions": "Grande $1",
+ "multimediaviewer-medium-embed-dimensions": "Médio $1",
+ "multimediaviewer-small-embed-dimensions": "Pequeno $1",
+ "multimediaviewer-description-page-button-text": "Mais detalhes sobre este ficheiro",
+ "multimediaviewer-description-page-popup-text": "Mais detalhes sobre este ficheiro em $1",
+ "multimediaviewer-commons-subtitle": "O repositório de multimédia livre",
+ "multimediaviewer-view-expanded": "Abrir no Visualizador Multimédia",
+ "multimediaviewer-view-config": "Configuração",
+ "multimediaviewer-close-popup-text": "Fechar esta ferramenta (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Mostrar em ecrã inteiro",
+ "multimediaviewer-defullscreen-popup-text": "Sair do ecrã inteiro",
+ "multimediaviewer-next-image-alt-text": "Mostrar a próxima imagem",
+ "multimediaviewer-prev-image-alt-text": "Mostrar a imagem anterior",
+ "multimediaviewer-title-popup-text": "Descrição",
+ "multimediaviewer-credit-popup-text": "Autor e informação sobre a fonte",
+ "multimediaviewer-title-popup-text-more": "Ver descrição completa",
+ "multimediaviewer-credit-popup-text-more": "Ver nome completo do autor e fonte",
+ "multimediaviewer-download-attribution-cta-header": "Precisa de indicar o autor",
+ "multimediaviewer-download-optional-attribution-cta-header": "Pode indicar o autor",
+ "multimediaviewer-download-attribution-cta": "Mostre-me como",
+ "multimediaviewer-download-attribution-copy": "Seleciona e copia (se suportado) o texto de atribuição deste ficheiro",
+ "multimediaviewer-reuse-warning-deletion": "Este ficheiro está a ser considerado para eliminação.",
+ "multimediaviewer-reuse-warning-nonfree": "Este ficheiro não tem uma licença livre.",
+ "multimediaviewer-reuse-warning-noattribution": "Este ficheiro não tem informação de atribuição do crédito.",
+ "multimediaviewer-reuse-warning-generic": "Verifique [$1 os detalhes] antes de utilizá-lo.",
+ "multimediaviewer-attr-plain": "Simples",
+ "multimediaviewer-options-tooltip": "Ativar ou desativar Visualizador Multimédia",
+ "multimediaviewer-options-dialog-header": "Desativar o Visualizador Multimédia?",
+ "multimediaviewer-options-text-header": "Ignorar esta funcionalidade para todos os ficheiros.",
+ "multimediaviewer-options-text-body": "Pode reativá-la mais tarde através das páginas dos ficheiros.",
+ "multimediaviewer-options-learn-more": "Saiba mais",
+ "multimediaviewer-option-submit-button": "Desativar Visualizador Multimédia",
+ "multimediaviewer-option-cancel-button": "Cancelar",
+ "multimediaviewer-disable-confirmation-header": "Desativou o Visualizador Multimédia",
+ "multimediaviewer-disable-confirmation-text": "Da próxima vez que clicar numa miniatura em $1, terá acesso direto aos detalhes do ficheiro.",
+ "multimediaviewer-enable-dialog-header": "Ativar o Visualizador Multimédia?",
+ "multimediaviewer-enable-text-header": "Ativar esta funcionalidade de visualização multimédia para todos os ficheiros por padrão.",
+ "multimediaviewer-enable-submit-button": "Ativar o Visualizador Multimédia",
+ "multimediaviewer-enable-confirmation-header": "Ativou o Visualizador Multimédia para todos os ficheiros",
+ "multimediaviewer-enable-confirmation-text": "Da próxima vez que clicar uma miniatura em $1, o Visualizador Multimédia será usado.",
+ "multimediaviewer-enable-alert": "O Visualizador Multimédia está agora desativado",
+ "multimediaviewer-disable-info-title": "Desativou o Visualizador Multimédia",
+ "multimediaviewer-disable-info": "Pode ainda ver ficheiros individuais com o Visualizador Multimédia.",
+ "multimediaviewer-errorreport-privacywarning": "Os detalhes do erro foram anexados ao relatório, que será publicamente visível. Se não concordar, pode editar o relatório abaixo e remover todos os dados que não deseja partilhar."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/qqq.json b/www/wiki/extensions/MultimediaViewer/i18n/qqq.json
new file mode 100644
index 00000000..0071595c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/qqq.json
@@ -0,0 +1,166 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mark Holmquist <mtraceur@member.fsf.org>",
+ "Raymond",
+ "Shirayuki",
+ "Liuxinyu970226",
+ "Robby",
+ "Mormegil",
+ "Amire80",
+ "Tacsipacsi",
+ "Wladek92",
+ "Pikne",
+ "Jon Harald Søby"
+ ]
+ },
+ "multimediaviewer-desc": "{{desc|name=Multimedia Viewer|url=https://www.mediawiki.org/wiki/Extension:MultimediaViewer}}",
+ "multimediaviewer-pref": "Preference title",
+ "multimediaviewer-pref-desc": "Description of preference",
+ "multimediaviewer-optin-pref": "Label for non-beta preference.",
+ "multimediaviewer-file-page": "Text for a link to the file page for an image.",
+ "multimediaviewer-repository-local": "Link to repository where the image is locally hosted.\nSee also:\n* {{msg-mw|multimediaviewer-repository}}",
+ "multimediaviewer-datetime-created": "Used in JavaScript code. Parameters:\n* $1 - time and date\nSee also:\n* {{msg-mw|Multimediaviewer-datetime-uploaded}}\n\nNote that the date comes from the description page and can have various forms (e.g. \"2000-01-01\", \"1st January 2000\", \"1492\", \"16th century\"...)\n\nAlso, this might refer to the date when the picture was taken, or the date when the depcited work was made - the usage is not consistent. You should choose a translation that works in all cases.\n{{Identical|Created}}",
+ "multimediaviewer-datetime-uploaded": "Used in JavaScript code. Parameters:\n* $1 - time and date (formatted)\nSee also:\n* {{msg-mw|Multimediaviewer-datetime-created}}\n{{Identical|Uploaded}}",
+ "multimediaviewer-credit": "Credit line for images. Parameters:\n* $1 - HTML describing the author\n* $2 - HTML describing the source\n\nNeither parameters are usernames, so GENDER is useless. Both come directly from the API, the extended metadata imageinfo prop in particular.\n\nThey will usually be derived from the HTML output from wikitext on a file description page - however, no complicated HTML, only links, will be allowed.\n\nSee also {{msg-mw|multimediaviewer-credit-fallback}}",
+ "multimediaviewer-credit-fallback": "Text shown in place of the credit line ({{msg-mw|multimediaviewer-credit}}) when neither author nor source information is available.",
+ "multimediaviewer-multiple-authors": "Text shown after the author name when there are multiple authors. The text will link to the file description page.\n* $1 - number of additional authors.",
+ "multimediaviewer-multiple-authors-combine": "Combines the author name and the message about other authors.\n* $1 - author name, parsed from the file page\n* $2 - {{msg-mw|multimediaviewer-multiple-authors}} wrapped in a link.\n{{Identical|And}}",
+ "multimediaviewer-metadata-error": "Text shown when the information on the metadata panel could not be loaded. Parameters:\n* $1 - the error message (not localized)\nSee also:\n* {{msg-mw|multimediaviewer-thumbnail-error}}",
+ "multimediaviewer-thumbnail-error": "Text shown when the image could not be loaded. Followed by {{msg-mw|multimediaviewer-thumbnail-error-description}}.\nSee also:\n* {{msg-mw|multimediaviewer-thumbnail-error-description}}\n* {{msg-mw|multimediaviewer-metadata-error}}",
+ "multimediaviewer-thumbnail-error-description": "Text shown when the image could not be loaded. Follows {{msg-mw|multimediaviewer-thumbnail-error}}. Parameters:\n* $1 - \"retry\" link (see {{msg-mw|multimediaviewer-thumbnail-error-retry}})\n* $2 - the error message (not localized)\n* $3 - report link (creates a Phabricator task; see {{msg-mw|multimediaviewer-thumbnail-error-report}})\nSee also:\n* {{msg-mw|multimediaviewer-thumbnail-error}}",
+ "multimediaviewer-thumbnail-error-retry": "Used as a part of {{msg-mw|multimediaviewer-thumbnail-error-description}} (as a link text).\n{{Identical|Retry}}",
+ "multimediaviewer-thumbnail-error-report": "Used as a part of {{msg-mw|multimediaviewer-thumbnail-error-description}} (as a link text).",
+ "multimediaviewer-report-issue-url": "{{ignored}}URL to the report issue website",
+ "multimediaviewer-license-cc-by-1.0": "Very short label for the Creative Commons Attribution license, version 1.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY}}",
+ "multimediaviewer-license-cc-sa-1.0": "Very short label for the Creative Commons ShareAlike license, version 1.0, used in a link to the file information page that has more licensing information.",
+ "multimediaviewer-license-cc-by-sa-1.0": "Very short label for the Creative Commons Attribution ShareAlike license, version 1.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY-SA}}",
+ "multimediaviewer-license-cc-by-2.0": "Very short label for the Creative Commons Attribution license, version 2.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY}}",
+ "multimediaviewer-license-cc-by-sa-2.0": "Very short label for the Creative Commons Attribution ShareAlike license, version 2.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY-SA}}",
+ "multimediaviewer-license-cc-by-2.1": "Very short label for the Creative Commons Attribution license, version 2.1, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY}}",
+ "multimediaviewer-license-cc-by-sa-2.1": "Very short label for the Creative Commons Attribution ShareAlike license, version 2.1, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY-SA}}",
+ "multimediaviewer-license-cc-by-2.5": "Very short label for the Creative Commons Attribution license, version 2.5, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY}}",
+ "multimediaviewer-license-cc-by-sa-2.5": "Very short label for the Creative Commons Attribution ShareAlike license, version 2.5, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY-SA}}",
+ "multimediaviewer-license-cc-by-3.0": "Very short label for the Creative Commons Attribution license, version 3.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY}}",
+ "multimediaviewer-license-cc-by-sa-3.0": "Very short label for the Creative Commons Attribution ShareAlike license, version 3.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY-SA}}",
+ "multimediaviewer-license-cc-by-4.0": "Very short label for the Creative Commons Attribution license, version 4.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY}}",
+ "multimediaviewer-license-cc-by-sa-4.0": "Very short label for the Creative Commons Attribution ShareAlike license, version 4.0, used in a link to the file information page that has more licensing information.\n{{Identical|CC BY-SA}}",
+ "multimediaviewer-license-cc-pd": "Very short label for the Creative Commons Public Domain license, used in a link to the file information page that has more licensing information.\n{{Identical|Public domain}}",
+ "multimediaviewer-license-cc-zero": "Very short label for the Creative Commons Zero license, used in a link to the file information page that has more licensing information.",
+ "multimediaviewer-license-pd": "Very short label for Public Domain images, used in a link to the file information page that has more licensing information.\n{{Identical|Public domain}}",
+ "multimediaviewer-license-default": "Short label for a link to generic license information.",
+ "multimediaviewer-permission-title": "Title of the box containing additional permission (by the copyright owner via OTRS) terms",
+ "multimediaviewer-permission-link": "Text of the link (on top of the metadata box) which shows additional permission (by the copyright owner via OTRS) terms\n\nSee also:\n* {{msg-mw|multimediaviewer-permission-link-hide}}",
+ "multimediaviewer-permission-link-hide": "Text of the link (on top of the metadata box) which hides additional permission terms\n\nSee also:\n* {{msg-mw|multimediaviewer-permission-link}}",
+ "multimediaviewer-permission-viewmore": "Text of the link (at the cutoff of the permission term preview) which shows additional permission (by the copyright owner via OTRS) terms.\n{{Identical|View more}}",
+ "multimediaviewer-restriction-2257": "Text of the tooltip for the Child Protection and Obscenity Enforcement Act restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-aus-reserve": "Text of the tooltip for the Australian reserve restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-communist": "Text of the tooltip for the communist symbol restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-costume": "Text of the tooltip for the costuming restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-currency": "Text of the tooltip for the currency restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-design": "Text of the tooltip for the copyrighted design restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-fan-art": "Text of the tooltip for the fan art restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-ihl": "Text of the tooltip for the IHL restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-insignia": "Text of the tooltip for the insignia restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-ita-mibac": "Text of the tooltip for the Italian MiBAC restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-nazi": "Text of the tooltip for the Nazi symbol restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-personality": "Text of the tooltip for the personality rights restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-trademarked": "Text of the tooltip for the trademarked restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-default": "Text of the tooltip for the default restriction label, that is displayed when hovered over.",
+ "multimediaviewer-restriction-default-and-others": "Text of the tooltip for the default restriction label when other restriction labels are present, that is displayed when hovered over.",
+ "multimediaviewer-about-mmv": "Text for a link to a page with more information about Media Viewer software.\n{{Identical|About}}",
+ "multimediaviewer-discuss-mmv": "Text for a link to a page where the user can discuss the Media Viewer software.\n{{Identical|Discussion}}",
+ "multimediaviewer-help-mmv": "Text for a link to a page with help about Media Viewer software.\n{{Identical|Help}}",
+ "multimediaviewer-optout-mmv": "Text for the opt-out link. Clicking on the link will turn off MediaViewer.\n\nSee also:\n* {{msg-mw|Multimediaviewer-optout-pending-mmv}}\n* {{msg-mw|Multimediaviewer-optin-mmv}}",
+ "multimediaviewer-optin-mmv": "Text for the opt-back link. Clicking it will undo the opt-out.\n\nSee also:\n* {{msg-mw|Multimediaviewer-optin-pending-mmv}}\n* {{msg-mw|Multimediaviewer-optout-mmv}}",
+ "multimediaviewer-optout-pending-mmv": "Text shown for the opt-out link while the optout request is being processed.\n\nSee also:\n* {{msg-mw|Multimediaviewer-optout-mmv}}\n* {{msg-mw|Multimediaviewer-optin-pending-mmv}}",
+ "multimediaviewer-optin-pending-mmv": "Text shown for the opt-in link while the optin request is being processed.\n\nSee also:\n* {{msg-mw|Multimediaviewer-optin-mmv}}\n* {{msg-mw|Multimediaviewer-optout-pending-mmv}}",
+ "multimediaviewer-optout-help": "Tooltip shown over the disabling link labeled {{msg-mw|Multimediaviewer-optout-mmv}}.\n\nRefers to {{msg-mw|Multimediaviewer-view-expanded}} and {{msg-mw|Multimediaviewer-optin-mmv}}.\n\nSee also:\n* {{msg-mw|Multimediaviewer-optin-help}}",
+ "multimediaviewer-optin-help": "Tooltip shown over the enabling link.\n\nThe link text is {{msg-mw|Multimediaviewer-optin-mmv}}.\n\nSee also:\n* {{msg-mw|Multimediaviewer-optout-mmv}}\n* {{msg-mw|Multimediaviewer-optout-help}}",
+ "multimediaviewer-geoloc-north": "Symbol for representing \"north\" in geolocation coordinates.\n\nUsed as <code>$4</code> in {{msg-mw|Multimediaviewer-geoloc-coord}}.",
+ "multimediaviewer-geoloc-east": "Symbol for representing \"east\" in geolocation coordinates.\n\nUsed as <code>$4</code> in {{msg-mw|Multimediaviewer-geoloc-coord}}.",
+ "multimediaviewer-geoloc-south": "Symbol for representing \"south\" in geolocation coordinates.\n\nUsed as <code>$4</code> in {{msg-mw|Multimediaviewer-geoloc-coord}}.",
+ "multimediaviewer-geoloc-west": "Symbol for representing \"west\" in geolocation coordinates.\n\nUsed as <code>$4</code> in {{msg-mw|Multimediaviewer-geoloc-coord}}.",
+ "multimediaviewer-geoloc-coord": "Format for geolocation coordinates. Parameters:\n* $1 - the number of degrees\n* $2 - the number of minutes\n* $3 - the number of seconds (rounded to the nearest hundredths place)\n* $4 - the direction symbol, defined by the following messages:\n** {{msg-mw|Multimediaviewer-geoloc-north}}\n** {{msg-mw|Multimediaviewer-geoloc-east}}\n** {{msg-mw|Multimediaviewer-geoloc-south}}\n** {{msg-mw|Multimediaviewer-geoloc-west}}",
+ "multimediaviewer-geoloc-coords": "Format for sets of geolocation coordinates. Parameters:\n* $1 - the latitude\n* $2 - the longitude\nBoth are formatted according to {{msg-mw|Multimediaviewer-geoloc-coord}}.",
+ "multimediaviewer-geolocation": "Message for displaying a location. Parameters:\n* $1 - a location which is formatted by {{msg-mw|Multimediaviewer-geoloc-coords}}\n{{Identical|Location}}",
+ "multimediaviewer-reuse-link": "Text of the link on the metadata panel which opens the reuse panel",
+ "multimediaviewer-reuse-loading-placeholder": "Text that appears in all reuse text boxes as a placeholder while the data loads.\n{{Identical|Loading}}",
+ "multimediaviewer-reuse-copy-share": "Text of the tooltip for the button to select and copy the sharing link (if supported by the browser) in the reuse panel, that is displayed when hovered over.",
+ "multimediaviewer-reuse-copy-embed": "Text of the tooltip for the button to select and copy the embedding code (if supported by the browser) in the reuse panel, that is displayed when hovered over.",
+ "multimediaviewer-share-tab": "Tab title text for the file reuse panel - used for the section with shareable URLs.\n{{Identical|Share}}",
+ "multimediaviewer-embed-tab": "Tab title text for the file reuse panel - used for the section with embeddable HTML and wikitext.",
+ "multimediaviewer-download-link": "Tooltip text for file download dialog open button.\n{{Identical|Download}}",
+ "multimediaviewer-download-preview-link-title": "Text in the link that allows the user to preview the image of the selected size - used for file download functionality.",
+ "multimediaviewer-download-original-button-name": "Text inside the button that lets the user download the original image - used for file download functionality.",
+ "multimediaviewer-download-small-button-name": "Text inside the button that lets the user download a small version of the original image - used for file download functionality.",
+ "multimediaviewer-download-medium-button-name": "Text inside the button that lets the user download a medium version of the original image - used for file download functionality.",
+ "multimediaviewer-download-large-button-name": "Text inside the button that lets the user download a large version of the original image - used for file download functionality.",
+ "multimediaviewer-link-to-page": "Used as alt-text to describe a URL that goes to a File: page for an image.",
+ "multimediaviewer-link-to-file": "Used as alt-text to describe a URL that goes to an image file.",
+ "multimediaviewer-share-explanation": "Used below the URL share input to explain what we expect the user to do.",
+ "multimediaviewer-embed-wt": "Used to represent a choice for embedding a file in a wiki page, as wikitext.\n{{Identical|Wikitext}}",
+ "multimediaviewer-embed-html": "Used to represent a choice for embedding a file in an HTML document, as HTML.\n{{Identical|HTML}}",
+ "multimediaviewer-embed-explanation": "Used below the embed textarea to explain what we expect the user to do.",
+ "multimediaviewer-text-embed-credit-text-bl": "Credit text, used when generating plain text for attributing an image - used as a caption, not in the middle of a sentence.\n\nWhich one of the multimediaviewer-text-embed-credit-text-* messages is used will depend on what information about the image is available.\n\nParameters:\n* $1 - name of the author\n* $2 - copyright tag (usually a license)\n* $3 - URL to the image source.\n{{Related|Multimediaviewer-embed-credit-text}}",
+ "multimediaviewer-text-embed-credit-text-b": "Credit text, used when generating plain text for attributing an image - used as a caption, not in the middle of a sentence.\n\nWhich one of the multimediaviewer-text-embed-credit-text-* messages is used will depend on what information about the image is available.\n\nParameters:\n* $1 - name of the author\n* $2 - URL to the image source.\n{{Related|Multimediaviewer-embed-credit-text}}",
+ "multimediaviewer-text-embed-credit-text-l": "{{optional}}\nCredit text, used when generating plain text for attributing an image - used as a caption, not in the middle of a sentence.\n\nWhich one of the multimediaviewer-text-embed-credit-text-* messages is used will depend on what information about the image is available.\n\nParameters:\n* $1 - copyright tag (usually a license)\n* $2 - URL to the image source.\n{{Related|Multimediaviewer-embed-credit-text}}",
+ "multimediaviewer-html-embed-credit-text-bl": "Credit text, used when generating HTML to reuse an image - used as a caption, not in the middle of a sentence.\n\nWhich one of the multimediaviewer-html-embed-credit-text-* messages is used will depend on what information about the image is available.\n\nParameters:\n* $1 - name of the author\n* $2 - copyright tag (usually a license)\n* $3 - URL to the image source\nEach of the parameters could be either plain text or a link.\n{{Related|Multimediaviewer-embed-credit-text}}",
+ "multimediaviewer-html-embed-credit-text-b": "Credit text, used when generating HTML to reuse an image - used as a caption, not in the middle of a sentence.\n\nWhich one of the multimediaviewer-html-embed-credit-text-* messages is used will depend on what information about the image is available.\n\nParameters:\n* $1 - name of the author\n* $2 - URL to the image source\nEach of the parameters could be either plain text or a link.\n{{Related|Multimediaviewer-embed-credit-text}}",
+ "multimediaviewer-html-embed-credit-text-l": "{{optional}}\nCredit text, used when generating HTML to reuse an image - used as a caption, not in the middle of a sentence.\n\nWhich one of the multimediaviewer-html-embed-credit-text-* messages is used will depend on what information about the image is available.\n\nParameters:\n* $1 - copyright tag (usually a license)\n* $2 - URL to the image source\nEach of the parameters could be either plain text or a link.\n{{Related|Multimediaviewer-embed-credit-text}}",
+ "multimediaviewer-html-embed-credit-link-text": "The clickable text of a link in a credit line, used when generating HTML to reuse an image.\n{{Related|Multimediaviewer-embed-credit-text}}\n{{Identical|Link}}",
+ "multimediaviewer-embed-byline": "Byline (author credit) text, used when generating wikitext/HTML to reuse the image. $1 is author name.\n{{Identical|By}}",
+ "multimediaviewer-embed-license": "License information, used when generating wikitext/HTML to reuse the image. $1 is the license name.",
+ "multimediaviewer-embed-license-nonfree": "Like {{msg-mw|multimediaviewer-embed-license}}, but for non-free images (where $1 is typically not a license name but something like \"Fair use\").",
+ "multimediaviewer-embed-via": "Source information (e.g. \"via Flickr\"), used when generating wikitext/HTML to reuse the image.\n\nParameters:\n* $1 - source (probably a website or institution name)",
+ "multimediaviewer-default-embed-dimensions": "Text of size selector option which will generate wikitext for a thumbnail without explicit size.",
+ "multimediaviewer-original-embed-dimensions": "Text of size selector option which will generate wikitext for a thumbnail with the original (full) size.\n* $1 - thumbnail dimensions, defined by the following message:\n** {{msg-mw|Multimediaviewer-embed-dimensions}}",
+ "multimediaviewer-large-embed-dimensions": "Text of size selector option which will generate wikitext for a thumbnail with small size.\n* $1 - thumbnail dimensions, defined by the following message:\n** {{msg-mw|Multimediaviewer-embed-dimensions}}\n{{Identical|Large}}",
+ "multimediaviewer-medium-embed-dimensions": "Text of size selector option which will generate wikitext for a thumbnail with medium size.\n* $1 - thumbnail dimensions, defined by the following message:\n** {{msg-mw|Multimediaviewer-embed-dimensions}}\n{{Identical|Medium}}",
+ "multimediaviewer-small-embed-dimensions": "Text of size selector option which will generate wikitext for a thumbnail with large size.\n* $1 - thumbnail dimensions, defined by the following message:\n** {{msg-mw|Multimediaviewer-embed-dimensions}}\n\n{{Identical|Small}}",
+ "multimediaviewer-embed-dimensions": "Dimensions for a given size selector option which will generate wikitext for a thumbnail.\n* $1 - width in pixels\n* $2 - height in pixels",
+ "multimediaviewer-embed-dimensions-separated": "Wraps the dimensions with a separator styled the same way, for the embed tab.\n* $1 - image dimensions\n\nSee also:\n* {{msg-mw|Multimediaviewer-embed-dimensions}}",
+ "multimediaviewer-embed-dimensions-with-file-format": "Collates image dimensions and a file format.\n* $1 - {{msg-mw|Multimediaviewer-embed-dimensions}}\n* $2 - file format extension, lowercased",
+ "multimediaviewer-description-page-button-text": "Text of the tooltip popup for the button on top of the metadata panel which links to the file description page. Used when the file was uploaded to the local wiki.\n\nSee also:\n* {{msg-mw|Multimediaviewer-description-page-popup-text}} (for remote files)",
+ "multimediaviewer-description-page-popup-text": "Text of the tooltip popup for the button on top of the metadata panel, which links to the file description page.Used when the file was uploaded to a different wiki.\n\nParameters:\n* $1 - the name of the site where the file comes from (e.g. \"Wikimedia Commons\")\nSee also:\n* {{msg-mw|Multimediaviewer-description-page-button-text}} (for local files)",
+ "multimediaviewer-commons-subtitle": "Additional text to display under {{msg-mw|multimediaviewer-repository}} when the image is from Commons.",
+ "multimediaviewer-view-expanded": "Label for a link on a file page to view the current image in the media viewer.",
+ "multimediaviewer-view-config": "Label for a link on a file page to open the Media Viewer configuration panel. This is for accessibility, and normally not visible; it is used for the icon next to the {{msg-mw|multimediaviewer-view-expanded}} button.\n{{Identical|Configuration}}",
+ "multimediaviewer-close-popup-text": "Tooltip for the button that closes the media viewer. \"Esc\" is the label of the keyboard key usually called \"[[:w:Esc key|Escape]]\".",
+ "multimediaviewer-fullscreen-popup-text": "Tooltip for a button that puts the viewer into full screen.",
+ "multimediaviewer-defullscreen-popup-text": "Tooltip for a button that exits fullscreen mode.",
+ "multimediaviewer-next-image-alt-text": "Alt text for a button that shows the next image.",
+ "multimediaviewer-prev-image-alt-text": "Alt text for a button that shows the previous image.",
+ "multimediaviewer-title-popup-text": "Tooltip that identifies the description of a file in the media viewer. (This could be the thumbnail caption, the filepage description or the file name, depending on what's available.) For very long titles, {{msg-mw|multimediaviewer-title-popup-text-more}} will be shown instead.\n{{Identical|Description}}",
+ "multimediaviewer-credit-popup-text": "Tooltip that identifies the author and source field of a file in the media viewer. If the author name or the source is very long, {{msg-mw|multimediaviewer-credit-popup-text-more}} will be shown instead.",
+ "multimediaviewer-title-popup-text-more": "Tooltip that identifies the description of a file in the media viewer. Used instead of {{msg-mw|multimediaviewer-title-popup-text}} when the name is too long and has to be truncated (and will be untruncated on click).",
+ "multimediaviewer-credit-popup-text-more": "Tooltip that identifies the author and source of a file in the media viewer. Used instead of {{msg-mw|multimediaviewer-credit-popup-text}} when one or both of the author and source is too long and has to be truncated (and will be untruncated on click).",
+ "multimediaviewer-download-attribution-cta-header": "Header for telling the user that the author of an image must be attributed, during a download action. See also {{msg-mw|multimediaviewer-download-optional-attribution-cta-header}}.",
+ "multimediaviewer-download-optional-attribution-cta-header": "Header for inviting the user to attribute author of the image during a download action. This is used for images where attribution is not a legal requirement. See also {{msg-mw|multimediaviewer-download-attribution-cta-header}}.",
+ "multimediaviewer-download-attribution-cta": "Call to action for a user to find out how to attribute the author of an image.",
+ "multimediaviewer-download-attribution-copy": "Text of the tooltip for the button to select and copy the attribution of a file (if supported by the browser) in the download panel, that is displayed when hovered over.",
+ "multimediaviewer-reuse-warning-deletion": "Warning message shown in the share/embed/download panels for files tagged with a deletion template ('''not just deleted!'''). Followed by {{msg-mw|multimediaviewer-reuse-warning-generic}}.",
+ "multimediaviewer-reuse-warning-nonfree": "Warning message shown in the share/embed/download panels for files under a nonfree license / copyright tag. Followed by {{msg-mw|multimediaviewer-reuse-warning-generic}}.",
+ "multimediaviewer-reuse-warning-noattribution": "Warning message shown in the share/embed/download panels for files which have no machine-readable author or source. Followed by {{msg-mw|multimediaviewer-reuse-warning-generic}}.",
+ "multimediaviewer-reuse-warning-generic": "Generic message at the end of every warning. $1 is the link to the file page.\n\nIt = the file",
+ "multimediaviewer-attr-plain": "Label for a button that lets the user pick plain text as an output format.",
+ "multimediaviewer-attr-html": "{{optional}}\nLabel for a button that lets the user pick HTML as an output format.\n{{Identical|HTML}}",
+ "multimediaviewer-options-tooltip": "Tooltip for a button that opens a panel for enabling or disabling the media viewer.",
+ "multimediaviewer-options-dialog-header": "Header for a dialog that gives the user the option to disable the media viewer.",
+ "multimediaviewer-options-text-header": "Text explaining the changes that happen when a user disables media viewer.",
+ "multimediaviewer-options-text-body": "Text explaining how to re-enable the media viewer after disabling.",
+ "multimediaviewer-options-learn-more": "Text for a link to more information about the media viewer.",
+ "multimediaviewer-option-submit-button": "Button for submitting a preference change that modifies the default behavior for image clicks - disables the viewer.",
+ "multimediaviewer-option-cancel-button": "Button for canceling an action on a preference change that modifies the default behavior for image clicks - closes the dialog with no action.\n{{Identical|Cancel}}",
+ "multimediaviewer-disable-confirmation-header": "Header on a dialog that informs the user they've successfully disabled the media viewer.",
+ "multimediaviewer-disable-confirmation-text": "Text informing the user that they've successfully disabled the media viewer. $1 is the wiki's name.",
+ "multimediaviewer-enable-dialog-header": "Header for a dialog that allows users to re-enable media viewer.",
+ "multimediaviewer-enable-text-header": "Text for a dialog that allows users to re-enable media viewer.",
+ "multimediaviewer-enable-submit-button": "Text for a button that re-enables media viewer.",
+ "multimediaviewer-enable-confirmation-header": "Header for a dialog that confirms that the user successfully re-enabled the media viewer.",
+ "multimediaviewer-enable-confirmation-text": "Text confirming that the user successfully re-enabled the media viewer. $1 is the wiki's name.",
+ "multimediaviewer-enable-alert": "Text shown in the enable panel to alert the user that the media viewer is currently disabled.",
+ "multimediaviewer-disable-info-title": "Used as title for {{msg-mw|Multimediaviewer-disable-info}}.",
+ "multimediaviewer-disable-info": "The title for this message is {{msg-mw|Multimediaviewer-disable-info-title}}.",
+ "multimediaviewer-errorreport-privacywarning": "A warning that is included in the Phabricator error report that's generated when the user clicks on the report link on an error page."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/qu.json b/www/wiki/extensions/MultimediaViewer/i18n/qu.json
new file mode 100644
index 00000000..a7ac4f43
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/qu.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "AlimanRuna"
+ ]
+ },
+ "multimediaviewer-repository-local": "Astawan rikuy",
+ "multimediaviewer-datetime-created": "Kamarisqa: $1",
+ "multimediaviewer-datetime-uploaded": "Churkusqa: $1",
+ "multimediaviewer-credit-fallback": "Ruraqmanta willaykunata qhaway",
+ "multimediaviewer-license-cc-pd": "Sapsi Chaskinancha",
+ "multimediaviewer-license-pd": "Sapsi Chaskinancha",
+ "multimediaviewer-permission-title": "Imaymana saqillaymanta",
+ "multimediaviewer-permission-viewmore": "Astawan qhaway",
+ "multimediaviewer-help-mmv": "Yanapa",
+ "multimediaviewer-optout-mmv": "Multimidya qhawanaman ama niy",
+ "multimediaviewer-optin-mmv": "Multimidya qhawanata atichiy",
+ "multimediaviewer-optout-pending-mmv": "Multimidya qhawanaman ama nispa",
+ "multimediaviewer-optin-pending-mmv": "Multimidya qhawanata atichispa",
+ "multimediaviewer-optout-help": "Multimidya qhawanawanqa rikchakuna manañam rikuchisqa kanqachu. Atichinapaqqa \"{{int:multimediaviewer-view-expanded}}\" butunta ñit'iy ima rikchap kinrayninpipas. Chaymantataq \"{{int:multimediaviewer-optin-mmv}}\" nisqapi ñit'iy.",
+ "multimediaviewer-geolocation": "Kay puystupi: $1",
+ "multimediaviewer-reuse-loading-placeholder": "Chaqnamuspa…",
+ "multimediaviewer-share-tab": "Rakinakuy",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-byline": "$1-pa rurasqan",
+ "multimediaviewer-original-embed-dimensions": "Qallariy willañiqi $1",
+ "multimediaviewer-large-embed-dimensions": "Hatun $1",
+ "multimediaviewer-medium-embed-dimensions": "Chawpi chhika $1",
+ "multimediaviewer-small-embed-dimensions": "Uchuy $1",
+ "multimediaviewer-description-page-popup-text": "Kay willañiqimanta astawan rikuy kaypi: $1",
+ "multimediaviewer-view-expanded": "Multimidya qhawanapi kichariy",
+ "multimediaviewer-title-popup-text": "T'iktuna"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ro.json b/www/wiki/extensions/MultimediaViewer/i18n/ro.json
new file mode 100644
index 00000000..db65b514
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ro.json
@@ -0,0 +1,118 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minisarm",
+ "Macofe"
+ ]
+ },
+ "multimediaviewer-desc": "Extinde miniaturile la o dimensiune mai mare într-o interfață pe tot ecranul.",
+ "multimediaviewer-pref": "Vizualizator multimedia",
+ "multimediaviewer-pref-desc": "Îmbunătățiți-vă experiența de vizualizare a conținutului multimedia cu această nouă unealtă. Afișează imaginile la dimensiune mare în cadrul paginilor care conțin miniaturi. Imaginile sunt afișate într-o interfață pe tot ecranul mai simpatică, acestea putând fi, de asemenea, vizualizate la dimensiunea reală.",
+ "multimediaviewer-optin-pref": "Activează <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Vizualizatorul multimedia]</span>",
+ "multimediaviewer-file-page": "Du-te la pagina asociată fișierului",
+ "multimediaviewer-repository-local": "Mai multe detalii",
+ "multimediaviewer-datetime-created": "Creată: $1",
+ "multimediaviewer-datetime-uploaded": "Încărcată: $1",
+ "multimediaviewer-credit-fallback": "Vezi informații despre autor",
+ "multimediaviewer-multiple-authors": "încă {{PLURAL:$1|un autor|$1 autori|$1 de autori}}",
+ "multimediaviewer-multiple-authors-combine": "$1 și $2",
+ "multimediaviewer-metadata-error": "Nu s-au putut încărca detaliile imaginii (eroare: $1).",
+ "multimediaviewer-thumbnail-error": "Din păcate fișierul nu poate fi afișat",
+ "multimediaviewer-thumbnail-error-description": "Se pare că a apărut o eroare tehnică. Puteți să $1 sau să $3 dacă aceasta persistă. Eroare: $2",
+ "multimediaviewer-thumbnail-error-retry": "reîncercați",
+ "multimediaviewer-thumbnail-error-report": "raportați problema",
+ "multimediaviewer-license-cc-pd": "Domeniu public",
+ "multimediaviewer-license-pd": "Domeniu public",
+ "multimediaviewer-license-default": "Vezi licența",
+ "multimediaviewer-permission-title": "Detalii despre permisiuni",
+ "multimediaviewer-permission-link": "vezi condițiile",
+ "multimediaviewer-permission-link-hide": "ascunde condițiile",
+ "multimediaviewer-permission-viewmore": "Mai mult",
+ "multimediaviewer-restriction-2257": "Această imagine ilustrează conținut sexual explicit, care poate fi subiectul legii de Protecție a copilului și luptei împotriva obscenității din Statele Unite.",
+ "multimediaviewer-restriction-aus-reserve": "Această fotografie a fost surprinsă într-o rezervație a Commonwealth-ului Australiei și nu poate fi utilizată în scopuri comerciale fără permisiune.",
+ "multimediaviewer-restriction-communist": "Această imagine conține însemne ale comunismului, care pot fi ilegale în anumite țări.",
+ "multimediaviewer-restriction-costume": "Această imagine ilustrează costumații și poate face subiectul restricțiilor legale.",
+ "multimediaviewer-restriction-currency": "Această imagine reprezintă ilustrația unei unități monetare și poate face subiectul restricțiilor legale.",
+ "multimediaviewer-restriction-design": "Designul subiectului din această imagine se poate afla sub incidența drepturilor de autor și poate face subiectul restricțiilor legale.",
+ "multimediaviewer-restriction-fan-art": "Această imagine este o operă de fan art, iar reutilizarea sa poate face subiectul restricțiilor legale.",
+ "multimediaviewer-restriction-ihl": "Această imagine conține simboluri restricționate de Dreptul internațional umanitar.",
+ "multimediaviewer-restriction-insignia": "Această imagine conține însemne oficiale, care pot face subiectul restricțiilor legale.",
+ "multimediaviewer-restriction-ita-mibac": "Această imagine reproduce o proprietate aparținând patrimoniului cultural italian și este restricționată de legislația italiană.",
+ "multimediaviewer-restriction-nazi": "Această imagine conține însemne naziste sau fasciste, care pot fi ilegale în anumite țări.",
+ "multimediaviewer-restriction-personality": "Această imagine poate ilustra persoane ale căror drepturi legale restricționează anumite reutilizări ale imaginii fără consimțământul acestora.",
+ "multimediaviewer-restriction-trademarked": "Conținutul acestei imagini poate fi subiectul legilor privitoare la mărcile înregistrate.",
+ "multimediaviewer-restriction-default": "Această imagine poate fi restricționată prin dispoziții legale în afara legii drepturilor de autor. Consultați pagina descriptivă a fișierului pentru detalii.",
+ "multimediaviewer-restriction-default-and-others": "Această imagine poate fi restricționată și prin alte dispoziții legale în afara legii drepturilor de autor. Consultați pagina descriptivă a fișierului pentru detalii.",
+ "multimediaviewer-about-mmv": "Despre",
+ "multimediaviewer-discuss-mmv": "Discuții",
+ "multimediaviewer-help-mmv": "Ajutor",
+ "multimediaviewer-optout-mmv": "Dezactivează Vizualizatorul multimedia",
+ "multimediaviewer-optin-mmv": "Activează Vizualizatorul multimedia",
+ "multimediaviewer-optout-pending-mmv": "Se dezactivează Vizualizatorul multimedia",
+ "multimediaviewer-optin-pending-mmv": "Se activează Vizualizatorul multimedia",
+ "multimediaviewer-optout-help": "Vizualizatorul multimedia nu va mai fi utilizat pentru afișarea imaginilor. Pentru a-l folosi din nou, apăsați butonul „{{int:multimediaviewer-view-expanded}}”, care se găsește în dreptul oricărei imagini. Apoi faceți clic pe „{{int:multimediaviewer-optin-mmv}}”.",
+ "multimediaviewer-optin-help": "Vizualizatorul multimedia va fi folosit pentru afișarea imaginilor.",
+ "multimediaviewer-geolocation": "Poziție: $1",
+ "multimediaviewer-reuse-link": "Distribuie sau încorporează acest fișier",
+ "multimediaviewer-reuse-loading-placeholder": "Se încarcă...",
+ "multimediaviewer-share-tab": "Distribuire",
+ "multimediaviewer-embed-tab": "Încorporare",
+ "multimediaviewer-download-link": "Descarcă acest fișier",
+ "multimediaviewer-download-preview-link-title": "Vizualizează cu navigatorul",
+ "multimediaviewer-download-original-button-name": "Descarcă fișierul original",
+ "multimediaviewer-download-small-button-name": "Descarcă la dimensiune mică",
+ "multimediaviewer-download-medium-button-name": "Descarcă la dimensiune intermediară",
+ "multimediaviewer-download-large-button-name": "Descarcă la dimensiune mare",
+ "multimediaviewer-link-to-page": "Legătură către pagina descriptivă a fișierului",
+ "multimediaviewer-link-to-file": "Legătură către fișierul original",
+ "multimediaviewer-share-explanation": "Copiați legătura și distribuiți-o liber",
+ "multimediaviewer-embed-wt": "Text wiki",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Utilizați acest cod pentru a încorpora fișierul",
+ "multimediaviewer-text-embed-credit-text-bl": "De la $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "De la $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "De la $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "De la $1, $2",
+ "multimediaviewer-embed-byline": "De $1",
+ "multimediaviewer-embed-license": "Sub licență $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Dimensiunea implicită a miniaturii",
+ "multimediaviewer-original-embed-dimensions": "Fișier original $1",
+ "multimediaviewer-large-embed-dimensions": "Mare $1",
+ "multimediaviewer-medium-embed-dimensions": "Intermediară $1",
+ "multimediaviewer-small-embed-dimensions": "Mică $1",
+ "multimediaviewer-description-page-button-text": "Mai multe detalii despre acest fișier",
+ "multimediaviewer-description-page-popup-text": "Mai multe detalii despre acest fișier la $1",
+ "multimediaviewer-commons-subtitle": "Depozitul liber de conținut media",
+ "multimediaviewer-view-expanded": "Deschide cu Vizualizatorul multimedia",
+ "multimediaviewer-view-config": "Configurare",
+ "multimediaviewer-close-popup-text": "Închide această unealtă (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Afișează pe tot ecranul",
+ "multimediaviewer-defullscreen-popup-text": "Ieșire din ecran complet",
+ "multimediaviewer-title-popup-text": "Descriere",
+ "multimediaviewer-credit-popup-text": "Informații despre autor și sursă",
+ "multimediaviewer-title-popup-text-more": "Vezi descrierea completă",
+ "multimediaviewer-credit-popup-text-more": "Vezi informațiile complete despre autor şi sursă",
+ "multimediaviewer-download-attribution-cta-header": "Trebuie să atribuiți autorului opera sa",
+ "multimediaviewer-download-optional-attribution-cta-header": "Puteți atribui autorului opera sa",
+ "multimediaviewer-download-attribution-cta": "Arată-mi cum",
+ "multimediaviewer-attr-plain": "Simplu",
+ "multimediaviewer-options-tooltip": "Activează sau dezactivează Vizualizatorul multimedia",
+ "multimediaviewer-options-dialog-header": "Dezactivați Vizualizatorul multimedia?",
+ "multimediaviewer-options-text-header": "Ignoră această opțiune de vizualizare pentru toate fișierele.",
+ "multimediaviewer-options-text-body": "Îl puteți activa mai târziu din pagina descriptivă a fișierelor.",
+ "multimediaviewer-options-learn-more": "Aflați mai multe",
+ "multimediaviewer-option-submit-button": "Dezactivează Vizualizatorul multimedia",
+ "multimediaviewer-option-cancel-button": "Revocare",
+ "multimediaviewer-disable-confirmation-header": "Ați dezactivat Vizualizatorul multimedia",
+ "multimediaviewer-disable-confirmation-text": "Data viitoare când veți face clic pe o miniatură la $1, veți accesa direct detaliile fișierului.",
+ "multimediaviewer-enable-dialog-header": "Activați Vizualizatorul multimedia?",
+ "multimediaviewer-enable-text-header": "Activează această opțiune de vizualizare multimedia în mod implicit pentru toate fișierele.",
+ "multimediaviewer-enable-submit-button": "Activează Vizualizatorul multimedia",
+ "multimediaviewer-enable-confirmation-header": "Ați activat Vizualizatorul multimedia pentru toate fișierele",
+ "multimediaviewer-enable-confirmation-text": "Data viitoare când veți face clic pe o miniatură la $1, se va lansa Vizualizatorul multimedia.",
+ "multimediaviewer-enable-alert": "Vizualizatorul multimedia este acum dezactivat",
+ "multimediaviewer-disable-info-title": "Ați dezactivat Vizualizatorul multimedia",
+ "multimediaviewer-disable-info": "Puteți vizualiza în continuare fișiere individuale cu Vizualizatorul multimedia.",
+ "multimediaviewer-errorreport-privacywarning": "Detaliile referitoare la eroare sunt atașate raportului care va fi făcut public. Dacă nu vă simțiți confortabil în această postură, puteți modifica raportul și să eliminați informațiile pe care nu le doriți publice."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/roa-tara.json b/www/wiki/extensions/MultimediaViewer/i18n/roa-tara.json
new file mode 100644
index 00000000..9049a635
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/roa-tara.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Abbilite 'u <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-thumbnail-error-retry": "pruève arrete",
+ "multimediaviewer-license-pd": "Dominie pubbleche",
+ "multimediaviewer-geolocation": "Posizione: $1"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ru.json b/www/wiki/extensions/MultimediaViewer/i18n/ru.json
new file mode 100644
index 00000000..7f3645f7
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ru.json
@@ -0,0 +1,122 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kaganer",
+ "Okras",
+ "Tucvbif",
+ "Meshkov.a",
+ "Wizardist",
+ "Striking Blue",
+ "Dağlı95",
+ "Macofe",
+ "Jack who built the house",
+ "Kareyac",
+ "Putnik",
+ "Smigles"
+ ]
+ },
+ "multimediaviewer-desc": "Раскрывает эскизы в большие изображения на весь экран.",
+ "multimediaviewer-pref": "Просмотрщик медиафайлов",
+ "multimediaviewer-pref-desc": "Улучшает просмотр мультимедиа-файлов новым инструментом. На странице с эскизами изображений он раскрывает эскизы в большие изображения. Изображения показываются в более красивом полноэкранном интерфейсе, а также могут быть открыты в оригинальном разрешении.",
+ "multimediaviewer-optin-pref": "Включить <span class=\"plainlinks\">«[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Просмотрщик медиафайлов]</span>»",
+ "multimediaviewer-file-page": "Перейти на страницу соответствующего файла",
+ "multimediaviewer-repository-local": "Подробнее",
+ "multimediaviewer-datetime-created": "Создано: $1",
+ "multimediaviewer-datetime-uploaded": "Загружено: $1",
+ "multimediaviewer-credit-fallback": "Посмотреть информацию об авторе",
+ "multimediaviewer-multiple-authors": "ещё {{PLURAL:$1|один автор|$1 авторов|$1 автора}}",
+ "multimediaviewer-multiple-authors-combine": "$1 и $2",
+ "multimediaviewer-metadata-error": "Не удалось загрузить данные изображения (ошибка: $1)",
+ "multimediaviewer-thumbnail-error": "Извините, файл не может быть отображён",
+ "multimediaviewer-thumbnail-error-description": "Похоже, возникла какая-то техническая проблема. Вы можете $1 или $3, если он будет повторяться. Ошибка: $2",
+ "multimediaviewer-thumbnail-error-retry": "повторить",
+ "multimediaviewer-thumbnail-error-report": "сообщить о проблеме",
+ "multimediaviewer-license-cc-pd": "Общественное достояние",
+ "multimediaviewer-license-pd": "Общественное достояние",
+ "multimediaviewer-license-default": "Просмотр лицензии",
+ "multimediaviewer-permission-title": "Сведения о разрешении",
+ "multimediaviewer-permission-link": "просмотр условий",
+ "multimediaviewer-permission-link-hide": "скрыть условия",
+ "multimediaviewer-permission-viewmore": "Посмотреть подробнее",
+ "multimediaviewer-restriction-2257": "Это изображение содержит откровенное сексуального содержание, которое может регулироваться в США Актом по защите детей и борьбе с непристойностью.",
+ "multimediaviewer-restriction-aus-reserve": "Это изображение было сделано в заповеднике Австралийского содружества и не может быть использовано в коммерческих целях без разрешения.",
+ "multimediaviewer-restriction-communist": "Это изображение содержит коммунистическую символику, которая может быть запрещена в некоторых странах.",
+ "multimediaviewer-restriction-currency": "Это изображение представляет собой изображение денежной единицы и может быть подвержено правовым ограничениям.",
+ "multimediaviewer-restriction-ihl": "Это изображение содержит символы, ограниченные международным гуманитарным правом.",
+ "multimediaviewer-restriction-insignia": "Это изображение содержит официальные знаки отличия, которые могут быть объектом правового ограничения.",
+ "multimediaviewer-restriction-trademarked": "Это изображение содержит материал, который может быть объектом законов о товарном знаке.",
+ "multimediaviewer-about-mmv": "О просмотрщике",
+ "multimediaviewer-discuss-mmv": "Обсуждение",
+ "multimediaviewer-help-mmv": "Справка",
+ "multimediaviewer-optout-mmv": "Отключить «Просмотрщик медиафайлов»",
+ "multimediaviewer-optin-mmv": "Включить «Просмотрщик медиафайлов»",
+ "multimediaviewer-optout-pending-mmv": "Отключение «Просмотрщика медиафайлов»",
+ "multimediaviewer-optin-pending-mmv": "Включение «Просмотрщика медиафайлов»",
+ "multimediaviewer-optout-help": "«Просмотрщик медиафайлов» больше не будет использоваться для показа изображений. Чтобы использовать его снова, нажмите на кнопку «{{int:multimediaviewer-view-expanded}}» рядом с любой образ. Затем нажмите на «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Для показа изображений будет использоваться «Просмотрщик медиафайлов».",
+ "multimediaviewer-geolocation": "Географическое положение: $1",
+ "multimediaviewer-reuse-link": "Поделиться или встроить этот файл",
+ "multimediaviewer-reuse-loading-placeholder": "Загрузка…",
+ "multimediaviewer-share-tab": "Поделиться",
+ "multimediaviewer-embed-tab": "Вставить на страницу",
+ "multimediaviewer-download-link": "Загрузить этот файл",
+ "multimediaviewer-download-preview-link-title": "Просмотр в браузере",
+ "multimediaviewer-download-original-button-name": "Скачать исходный файл",
+ "multimediaviewer-download-small-button-name": "Скачать в маленьком размере",
+ "multimediaviewer-download-medium-button-name": "Скачать в среднем размере",
+ "multimediaviewer-download-large-button-name": "Скачать в большом размере",
+ "multimediaviewer-link-to-page": "Ссылка на страницу описания файла",
+ "multimediaviewer-link-to-file": "Ссылка на исходный файл",
+ "multimediaviewer-share-explanation": "Скопируйте и свободно делитесь ссылкой",
+ "multimediaviewer-embed-wt": "Вики-текст",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Используйте этот код, чтобы вставить файл на страницу",
+ "multimediaviewer-text-embed-credit-text-bl": "Автор: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Автор: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Автор: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Автор: $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Ссылка",
+ "multimediaviewer-embed-byline": "Участника $1",
+ "multimediaviewer-embed-license": "Под лицензией $1.",
+ "multimediaviewer-embed-via": "Через $1.",
+ "multimediaviewer-default-embed-dimensions": "Размер эскиза по умолчанию",
+ "multimediaviewer-original-embed-dimensions": "Исходный файл $1",
+ "multimediaviewer-large-embed-dimensions": "Большой $1",
+ "multimediaviewer-medium-embed-dimensions": "Средний $1",
+ "multimediaviewer-small-embed-dimensions": "Маленький $1",
+ "multimediaviewer-description-page-button-text": "Подробнее об этом файле",
+ "multimediaviewer-description-page-popup-text": "Подробнее об этом файле на сайте $1",
+ "multimediaviewer-commons-subtitle": "Хранилище свободных медиафайлов",
+ "multimediaviewer-view-expanded": "Открыть в «Просмотрщике медиафайлов»",
+ "multimediaviewer-view-config": "Настройка",
+ "multimediaviewer-close-popup-text": "Закрыть этот инструмент (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Показать в полноэкранном режиме",
+ "multimediaviewer-defullscreen-popup-text": "Выход из полноэкранного режима",
+ "multimediaviewer-next-image-alt-text": "Показать следующее изображение",
+ "multimediaviewer-prev-image-alt-text": "Показать предыдущее изображение",
+ "multimediaviewer-title-popup-text": "Описание",
+ "multimediaviewer-credit-popup-text": "Информация об авторе и источнике",
+ "multimediaviewer-title-popup-text-more": "Посмотреть полное описание",
+ "multimediaviewer-credit-popup-text-more": "Посмотреть полную информацию об авторе и источнике",
+ "multimediaviewer-download-attribution-cta-header": "Вам нужно указать автора",
+ "multimediaviewer-download-optional-attribution-cta-header": "Вам нужно указать автора",
+ "multimediaviewer-download-attribution-cta": "Показать мне, как",
+ "multimediaviewer-attr-plain": "Простой",
+ "multimediaviewer-options-tooltip": "Включение или отключение «Просмотрщика медиафайлов»",
+ "multimediaviewer-options-dialog-header": "Отключить «Просмотрщик медиафайлов»?",
+ "multimediaviewer-options-text-header": "Выключить эту функцию просмотра для всех файлов.",
+ "multimediaviewer-options-text-body": "Вы можете включить его позже на странице сведений о файле.",
+ "multimediaviewer-options-learn-more": "Узнать больше",
+ "multimediaviewer-option-submit-button": "Отключить «Просмотрщик медиафайлов»",
+ "multimediaviewer-option-cancel-button": "Отмена",
+ "multimediaviewer-disable-confirmation-header": "Вы отключили «Просмотрщик медиафайлов»",
+ "multimediaviewer-disable-confirmation-text": "Следующий раз, когда вы щёлкните на миниатюре файла на сайте $1, вы напрямую сможете просматривать все сведения о файле.",
+ "multimediaviewer-enable-dialog-header": "Включить «Просмотрщик медиафайлов»?",
+ "multimediaviewer-enable-text-header": "Включить эту функцию медиапросмотра по умолчанию для всех файлов.",
+ "multimediaviewer-enable-submit-button": "Включить «Просмотрщик медиафайлов»",
+ "multimediaviewer-enable-confirmation-header": "Вы включили «Просмотрщик медиафайлов» для всех файлов",
+ "multimediaviewer-enable-confirmation-text": "Следующий раз, когда вы щёлкните на миниатюре файла на сайте $1, будет использован «Просмотрщик медиафайлов».",
+ "multimediaviewer-enable-alert": "«Просмотрщик медиафайлов» теперь отключен",
+ "multimediaviewer-disable-info-title": "Вы отключили «Просмотрщик медиафайлов»",
+ "multimediaviewer-disable-info": "Вы всё ещё можете просматривать отдельные файлы через «Просмотрщик медиафайлов»."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sa.json b/www/wiki/extensions/MultimediaViewer/i18n/sa.json
new file mode 100644
index 00000000..42a264ff
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sa.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "NehalDaveND"
+ ]
+ },
+ "multimediaviewer-repository-local": "अधिकविवरणम्",
+ "multimediaviewer-multiple-authors-combine": "$1, $2 च",
+ "multimediaviewer-thumbnail-error-retry": "पुनःप्रयासः",
+ "multimediaviewer-help-mmv": "साहाय्यम्",
+ "multimediaviewer-reuse-loading-placeholder": "आरोपयति...",
+ "multimediaviewer-share-tab": "वितरतु",
+ "multimediaviewer-embed-html": "एच् टि एम् एल्",
+ "multimediaviewer-embed-byline": "$1 द्वारा",
+ "multimediaviewer-embed-via": "$1 भूत्वा",
+ "multimediaviewer-title-popup-text": "वर्णनम्",
+ "multimediaviewer-option-cancel-button": "निरस्यताम्"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sco.json b/www/wiki/extensions/MultimediaViewer/i18n/sco.json
new file mode 100644
index 00000000..e34e8cf2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sco.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "John Reid",
+ "AmaryllisGardener"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Enable <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-metadata-error": "Mistak: Coudna laid eemage data. $1",
+ "multimediaviewer-thumbnail-error": "Mistak: Coudna laid thummnail data. $1",
+ "multimediaviewer-license-pd": "Public Domain",
+ "multimediaviewer-permission-title": "Permeession details",
+ "multimediaviewer-permission-link": "see the terms",
+ "multimediaviewer-permission-viewmore": "See mair",
+ "multimediaviewer-discuss-mmv": "Tauk ower this featur",
+ "multimediaviewer-help-mmv": "Heelp",
+ "multimediaviewer-optin-mmv": "Enable Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Disablin Media Viewer",
+ "multimediaviewer-optin-pending-mmv": "Enablin Media Viewer",
+ "multimediaviewer-optout-help": "Media Viewer wil no be uised tae shaw eemages onie mair. Tae uise it again, clap oan the \"{{int:mutimediaviewer-view-expanded}}\" button nex tae onie eemage. Than clap oan \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-reuse-loading-placeholder": "Laidin...",
+ "multimediaviewer-share-tab": "Shair",
+ "multimediaviewer-embed-tab": "Embed",
+ "multimediaviewer-download-link": "Dounlaid this file",
+ "multimediaviewer-download-preview-link-title": "See in the brouser",
+ "multimediaviewer-download-original-button-name": "Dounlaid the oreeginal file",
+ "multimediaviewer-download-small-button-name": "Dounlaid wee size",
+ "multimediaviewer-download-medium-button-name": "Dounlaid middlin size",
+ "multimediaviewer-download-large-button-name": "Dounlaid muckle size",
+ "multimediaviewer-link-to-page": "Link til file descreeption page",
+ "multimediaviewer-link-to-file": "Airt til oreeginal file",
+ "multimediaviewer-share-explanation": "Capie n freelie shair the airtin",
+ "multimediaviewer-embed-wt": "Wikitex",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Uise this code tae embed the file",
+ "multimediaviewer-embed-byline": "Bi $1",
+ "multimediaviewer-embed-license": "Licensed unner $1.",
+ "multimediaviewer-embed-via": "Bi waa o $1.",
+ "multimediaviewer-default-embed-dimensions": "Defaut thummnail size",
+ "multimediaviewer-original-embed-dimensions": "Oreeginal file $1",
+ "multimediaviewer-large-embed-dimensions": "Muckle $1",
+ "multimediaviewer-medium-embed-dimensions": "Midlin $1",
+ "multimediaviewer-small-embed-dimensions": "Smaw $1"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sd.json b/www/wiki/extensions/MultimediaViewer/i18n/sd.json
new file mode 100644
index 00000000..3f6f3071
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sd.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mehtab ahmed",
+ "Aursani"
+ ]
+ },
+ "multimediaviewer-thumbnail-error-description": "ڪو ٽيڪنيڪي مسئلو ٿيو آهي. جي حل نہ ٿي تہ توهان $1 يا $3 ڪري سگھو ٿا. چُڪَ: $2",
+ "multimediaviewer-thumbnail-error-report": "مسئلي جي رپورٽ ڪريو",
+ "multimediaviewer-about-mmv": "بابت",
+ "multimediaviewer-discuss-mmv": "بحث"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sdc.json b/www/wiki/extensions/MultimediaViewer/i18n/sdc.json
new file mode 100644
index 00000000..620924ca
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sdc.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jun Misugi"
+ ]
+ },
+ "multimediaviewer-repository-local": "Imparà più"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sgs.json b/www/wiki/extensions/MultimediaViewer/i18n/sgs.json
new file mode 100644
index 00000000..cafc90e9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sgs.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hugo.arg"
+ ]
+ },
+ "multimediaviewer-pref": "Abruozdieliu parveiza",
+ "multimediaviewer-optin-pref": "Ijongtė <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About abruozdieliu parvaizas rakonda]</span>",
+ "multimediaviewer-repository-local": "Tėksliau",
+ "multimediaviewer-datetime-created": "Padėrbts: $1",
+ "multimediaviewer-datetime-uploaded": "Ikelts: $1",
+ "multimediaviewer-credit-fallback": "Veizietė žėnēs aple autorio",
+ "multimediaviewer-multiple-authors-combine": "$1 ė $2",
+ "multimediaviewer-license-cc-pd": "Vėiša nauduojėma",
+ "multimediaviewer-license-pd": "Vėiša nauduojėma",
+ "multimediaviewer-license-default": "Veizietė lėcencėjė",
+ "multimediaviewer-permission-link": "veizietė sālīgas",
+ "multimediaviewer-permission-link-hide": "kavuotė sālīgas",
+ "multimediaviewer-permission-viewmore": "Da veizietė",
+ "multimediaviewer-help-mmv": "Pagelba",
+ "multimediaviewer-geolocation": "Vėita: $1",
+ "multimediaviewer-description-page-button-text": "Daugiau žėniū aple ta abruozdieli",
+ "multimediaviewer-view-expanded": "Atverė so abruozdieliu parveiza",
+ "multimediaviewer-title-popup-text": "Aprašīms"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/si.json b/www/wiki/extensions/MultimediaViewer/i18n/si.json
new file mode 100644
index 00000000..bd57cfef
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/si.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sahan.ssw",
+ "Susith Chandira Gts",
+ "Thirsty",
+ 1100100
+ ]
+ },
+ "multimediaviewer-metadata-error": "පින්තූරයේ විස්තර වලට ප්‍රෙව්ශනය විය නොහැක(දෝෂය:$1)",
+ "multimediaviewer-thumbnail-error": "සමාවන්න, ගොනුව පෙන්විය නොහැක.",
+ "multimediaviewer-thumbnail-error-retry": "නැවත උත්සහ කරන්න",
+ "multimediaviewer-permission-title": "බලපත්‍ර විස්තර",
+ "multimediaviewer-permission-link": "කොන්දේසි පෙන්වන්න",
+ "multimediaviewer-permission-link-hide": "කොන්දේසි සඟවන්න",
+ "multimediaviewer-permission-viewmore": "තවත් බලන්න",
+ "multimediaviewer-embed-html": "HTML"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sk.json b/www/wiki/extensions/MultimediaViewer/i18n/sk.json
new file mode 100644
index 00000000..ed5215ff
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sk.json
@@ -0,0 +1,71 @@
+{
+ "@metadata": {
+ "authors": [
+ "Teslaton",
+ "LacoR"
+ ]
+ },
+ "multimediaviewer-desc": "Zobrazí náhľady obrázkov na celú obrazovku.",
+ "multimediaviewer-pref": "Prehliadač médií",
+ "multimediaviewer-optin-pref": "Zapnúť <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Prehliadač médií]</span>",
+ "multimediaviewer-repository-local": "Viac informácií",
+ "multimediaviewer-datetime-created": "Vytvorené: $1",
+ "multimediaviewer-datetime-uploaded": "Nahrané: $1",
+ "multimediaviewer-credit-fallback": "Zobraziť informácie o autorovi",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ďalší autor|$1 ďalší autori|$1 ďalších autorov}}",
+ "multimediaviewer-multiple-authors-combine": "$1 a $2",
+ "multimediaviewer-metadata-error": "Nedajú sa načítať podrobnosti obrázka (chyba: $1)",
+ "multimediaviewer-thumbnail-error": "Prepáčte, súbor nie je možné zobraziť",
+ "multimediaviewer-thumbnail-error-retry": "znova",
+ "multimediaviewer-thumbnail-error-report": "nahlásiť problém",
+ "multimediaviewer-license-cc-pd": "Voľné dielo",
+ "multimediaviewer-license-pd": "Voľné dielo",
+ "multimediaviewer-license-default": "Zobraziť licenciu",
+ "multimediaviewer-permission-title": "Podrobnosti o povolení",
+ "multimediaviewer-permission-link": "zobraziť podmienky",
+ "multimediaviewer-permission-link-hide": "skryť podmienky",
+ "multimediaviewer-permission-viewmore": "Zobraziť viac",
+ "multimediaviewer-restriction-2257": "Tento obrázok obsahuje sexuálne explicitný obsah, ktorý môže byť predmetom zákona Spojených štátov Child Protection and Obscenity Enforcement Act.",
+ "multimediaviewer-restriction-aus-reserve": "Táto fotka bola vytvorená v austrálskej prírodnej rezervácii a nesmie byť použitá na komerčné účely bez povolenia.",
+ "multimediaviewer-restriction-communist": "Tento obrázok obsahuje komunistické symboly, ktoré môžu byť v niektorých krajinách zakázané.",
+ "multimediaviewer-restriction-costume": "Tento obrázok zobrazuje kostýmy a môže byť predmetom zákonných obmedzení.",
+ "multimediaviewer-restriction-nazi": "Tento obrázok obsahuje nacistické alebo iné fašistické symboly, ktoré môžu byť v niektorých krajinách zakázané.",
+ "multimediaviewer-discuss-mmv": "Diskusia",
+ "multimediaviewer-help-mmv": "Pomoc",
+ "multimediaviewer-optout-mmv": "Vypnúť Prehliadač médií",
+ "multimediaviewer-optin-mmv": "Zapnúť Prehliadač médií",
+ "multimediaviewer-optout-pending-mmv": "Prehliadač médií sa vypína",
+ "multimediaviewer-optin-pending-mmv": "Prehliadač médií sa zapína",
+ "multimediaviewer-geolocation": "Poloha: $1",
+ "multimediaviewer-reuse-link": "Zdielať alebo vložiť tento súbor",
+ "multimediaviewer-reuse-loading-placeholder": "Načítavam…",
+ "multimediaviewer-share-tab": "Zdieľať",
+ "multimediaviewer-embed-tab": "Vložiť",
+ "multimediaviewer-download-link": "Stiahnuť tento súbor",
+ "multimediaviewer-download-preview-link-title": "Otvoriť v prehliadači",
+ "multimediaviewer-download-original-button-name": "Stiahnuť pôvodný súbor",
+ "multimediaviewer-text-embed-credit-text-bl": "Autor: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Autor: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Autor: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Autor: $1, $2",
+ "multimediaviewer-embed-byline": "Autor: $1",
+ "multimediaviewer-embed-license": "Licencovaný pod $1.",
+ "multimediaviewer-embed-via": "Prostredníctvom $1.",
+ "multimediaviewer-default-embed-dimensions": "Predvolená veľkosť náhľadu",
+ "multimediaviewer-original-embed-dimensions": "Pôvodný súbor $1",
+ "multimediaviewer-description-page-button-text": "Viac informácií o tomto súbore",
+ "multimediaviewer-description-page-popup-text": "Viac informácií o tomto súbore na $1",
+ "multimediaviewer-view-expanded": "Zobraziť v prehliadači médií",
+ "multimediaviewer-view-config": "Nastavenie",
+ "multimediaviewer-close-popup-text": "Zatvoriť tento nástroj (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Zobraziť na celej obrazovke",
+ "multimediaviewer-defullscreen-popup-text": "Ukončiť režim zobrazenia na celej obrazovky",
+ "multimediaviewer-title-popup-text": "Popis",
+ "multimediaviewer-credit-popup-text": "Informácie o autorovi a zdroji",
+ "multimediaviewer-title-popup-text-more": "Zobraziť úplný popis",
+ "multimediaviewer-credit-popup-text-more": "Zobraziť úplné informácie o autorovi a zdroji",
+ "multimediaviewer-download-attribution-cta-header": "Musíte uviesť autora",
+ "multimediaviewer-download-optional-attribution-cta-header": "Môžete uviesť autora",
+ "multimediaviewer-download-attribution-cta": "Ukážte mi ako",
+ "multimediaviewer-option-submit-button": "Vypnúť Prehliadač médií"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sl.json b/www/wiki/extensions/MultimediaViewer/i18n/sl.json
new file mode 100644
index 00000000..82f253c2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sl.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dbc334",
+ "Eleassar",
+ "Pickle12"
+ ]
+ },
+ "multimediaviewer-desc": "Razširitev sličic v večji velikosti v celozaslonskem vmesniku.",
+ "multimediaviewer-pref": "Predstavnostni pregledovalnik",
+ "multimediaviewer-pref-desc": "S tem orodjem lahko izboljšate svojo izkušnjo pri ogledovanju večpredstavnostnih vsebin. Orodje prikazuje slike na straneh s sličicami v večji velikosti in v lepšem okvirčku celozaslonskega vmesnika, mogoč pa je tudi celozaslonski prikaz.",
+ "multimediaviewer-file-page": "Pojdi na pripadajočo opisno stran datoteke.",
+ "multimediaviewer-repository-local": "Več podrobnosti",
+ "multimediaviewer-datetime-created": "Ustvarjeno: $1",
+ "multimediaviewer-datetime-uploaded": "Naloženo: $1",
+ "multimediaviewer-license-cc-pd": "javna last",
+ "multimediaviewer-license-pd": "Javna last",
+ "multimediaviewer-license-default": "Prikaz licence",
+ "multimediaviewer-permission-title": "Podatki o dovoljenju",
+ "multimediaviewer-permission-link": "ogled pogojev",
+ "multimediaviewer-permission-viewmore": "Oglej si več",
+ "multimediaviewer-about-mmv": "O pregledovalniku",
+ "multimediaviewer-discuss-mmv": "Razprava",
+ "multimediaviewer-help-mmv": "Pomoč",
+ "multimediaviewer-geolocation": "Lokacija: $1",
+ "multimediaviewer-reuse-link": "Deli ali vdelaj datoteko",
+ "multimediaviewer-reuse-loading-placeholder": "Nalaganje ...",
+ "multimediaviewer-share-tab": "Deli",
+ "multimediaviewer-embed-tab": "Vdelaj",
+ "multimediaviewer-download-link": "Prenesi datoteko",
+ "multimediaviewer-download-preview-link-title": "Ogled v brskalniku",
+ "multimediaviewer-download-original-button-name": "Prenesi izvirno datoteko",
+ "multimediaviewer-download-small-button-name": "Prenesi majhno velikost",
+ "multimediaviewer-download-medium-button-name": "Prenesi srednjo velikost",
+ "multimediaviewer-download-large-button-name": "Prenesi veliko velikost",
+ "multimediaviewer-link-to-page": "Povezava do strani z opisom datoteke",
+ "multimediaviewer-link-to-file": "Povezava do izvirne datoteke",
+ "multimediaviewer-share-explanation": "Povezavo kopirajte in jo prosto delite",
+ "multimediaviewer-embed-wt": "Wikibesedilo",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Uporabite to kodo za vdelavo datoteke",
+ "multimediaviewer-html-embed-credit-link-text": "Povezava",
+ "multimediaviewer-default-embed-dimensions": "Privzeta velikost sličice",
+ "multimediaviewer-original-embed-dimensions": "Izvirna datoteka $1",
+ "multimediaviewer-large-embed-dimensions": "Velika $1",
+ "multimediaviewer-medium-embed-dimensions": "Srednja $1",
+ "multimediaviewer-small-embed-dimensions": "Majhna $1",
+ "multimediaviewer-description-page-button-text": "Več podrobnosti o datoteki",
+ "multimediaviewer-description-page-popup-text": "Več podrobnosti o datoteki na $1"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sq.json b/www/wiki/extensions/MultimediaViewer/i18n/sq.json
new file mode 100644
index 00000000..9d9835ff
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sq.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "GretaDoci"
+ ]
+ },
+ "multimediaviewer-optin-mmv": "Aktivizo Median Pamore"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sr-ec.json b/www/wiki/extensions/MultimediaViewer/i18n/sr-ec.json
new file mode 100644
index 00000000..c1f9b0dc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sr-ec.json
@@ -0,0 +1,111 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01",
+ "Сербијана",
+ "Obsuser",
+ "Acamicamacaraca",
+ "BadDog"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Омогући <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About прегледач датотека]</span>",
+ "multimediaviewer-file-page": "Иди на одговарајућу страницу датотеке",
+ "multimediaviewer-repository-local": "Више детаља",
+ "multimediaviewer-datetime-created": "Направљено: $1",
+ "multimediaviewer-datetime-uploaded": "Послато: $1",
+ "multimediaviewer-credit-fallback": "Погледај информације о аутору",
+ "multimediaviewer-thumbnail-error": "Жао нам је, датотеку није могуће приказати",
+ "multimediaviewer-thumbnail-error-description": "Изгледа да постоји технички проблем. Можете $1 или $3 ако се настави. Грешка: $2",
+ "multimediaviewer-thumbnail-error-retry": "пробати опет",
+ "multimediaviewer-thumbnail-error-report": "пријавити проблем",
+ "multimediaviewer-license-cc-pd": "Јавно власништво",
+ "multimediaviewer-license-pd": "Јавно власништво",
+ "multimediaviewer-license-default": "Види лиценцу",
+ "multimediaviewer-permission-title": "Детаљи дозволе",
+ "multimediaviewer-permission-link": "види услове",
+ "multimediaviewer-permission-link-hide": "сакриј услове",
+ "multimediaviewer-permission-viewmore": "Прикажи још",
+ "multimediaviewer-restriction-communist": "Ова слика садржи комунистичка обележја која су забрањена у неким земљама.",
+ "multimediaviewer-restriction-insignia": "Ова слика садржи званично обележје, њихова употреба подлеже ограничењима.",
+ "multimediaviewer-restriction-nazi": "Ова слика садржи нацистичка обележја која су забрањена у неким земљама.",
+ "multimediaviewer-restriction-trademarked": "Ова слика можда садржи регистровани заштитни знак.",
+ "multimediaviewer-restriction-default": "Ова слика можда подлеже неким другим ограничењима независно од статуса ауторских права. Погледајте страницу датотеке за више информација.",
+ "multimediaviewer-restriction-default-and-others": "Ова слика можда подлеже неким другим ограничењима независно од статуса ауторских права. Погледајте страницу датотеке за више информација.",
+ "multimediaviewer-about-mmv": "О",
+ "multimediaviewer-discuss-mmv": "Расправа",
+ "multimediaviewer-help-mmv": "Помоћ",
+ "multimediaviewer-optout-mmv": "Онемогући Media Viewer",
+ "multimediaviewer-optin-mmv": "Омогући прегледач датотека",
+ "multimediaviewer-optout-pending-mmv": "Онемогућавање Media Viewer-а",
+ "multimediaviewer-optin-pending-mmv": "Омогућавање Media Viewer-а",
+ "multimediaviewer-optout-help": "Media Viewer неће више бити коришћен за приказ слика. Да га користите опет кликните на „{{int:multimediaviewer-view-expanded}}“, па на „{{int:multimediaviewer-optin-mmv}}“.",
+ "multimediaviewer-optin-help": "Media Viewer ће бити коришћен за приказивање слика.",
+ "multimediaviewer-geolocation": "Локација: $1",
+ "multimediaviewer-reuse-link": "Користи ову датотеку",
+ "multimediaviewer-reuse-loading-placeholder": "Учитавам...",
+ "multimediaviewer-share-tab": "Дели",
+ "multimediaviewer-embed-tab": "Угради",
+ "multimediaviewer-download-link": "Преузми",
+ "multimediaviewer-download-preview-link-title": "Види у веб-прегледачу",
+ "multimediaviewer-download-original-button-name": "Преузми оригиналну датотеку",
+ "multimediaviewer-download-small-button-name": "Преузми у малој величини",
+ "multimediaviewer-download-medium-button-name": "Преузми у средњој величини",
+ "multimediaviewer-download-large-button-name": "Преузми велику",
+ "multimediaviewer-link-to-page": "Веза до одговарајуће странице датотеке",
+ "multimediaviewer-link-to-file": "Веза до оригиналне датотеке",
+ "multimediaviewer-share-explanation": "Копирајте и слободно делите ову везу",
+ "multimediaviewer-embed-wt": "Викитекст",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Користите овај код да уградите датотеку",
+ "multimediaviewer-text-embed-credit-text-bl": "Аутор: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Аутор: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Аутор: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Аутор: $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Веза",
+ "multimediaviewer-embed-byline": "Аутор: $1",
+ "multimediaviewer-embed-license": "Под лиценцом $1.",
+ "multimediaviewer-embed-via": "Преко $1.",
+ "multimediaviewer-default-embed-dimensions": "Подразумевана величина",
+ "multimediaviewer-original-embed-dimensions": "Оригинална датотека $1",
+ "multimediaviewer-large-embed-dimensions": "Велика $1",
+ "multimediaviewer-medium-embed-dimensions": "Средња $1",
+ "multimediaviewer-small-embed-dimensions": "Мала $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 п",
+ "multimediaviewer-description-page-button-text": "Прикажи детаље",
+ "multimediaviewer-description-page-popup-text": "Прикажи детаље са пројекта $1",
+ "multimediaviewer-commons-subtitle": "Ризница слободних медијских датотека",
+ "multimediaviewer-view-expanded": "Рашири",
+ "multimediaviewer-view-config": "Подешавања",
+ "multimediaviewer-close-popup-text": "Затвори ову алатку (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Прикажи преко целог екрана",
+ "multimediaviewer-defullscreen-popup-text": "Изађи из целог екрана",
+ "multimediaviewer-next-image-alt-text": "Следећа слика",
+ "multimediaviewer-prev-image-alt-text": "Претходна слика",
+ "multimediaviewer-title-popup-text": "Опис",
+ "multimediaviewer-credit-popup-text": "Аутор и информације о извору",
+ "multimediaviewer-title-popup-text-more": "Види цео опис",
+ "multimediaviewer-download-attribution-cta-header": "Морате навести аутора",
+ "multimediaviewer-download-optional-attribution-cta-header": "Можете навести аутора",
+ "multimediaviewer-download-attribution-cta": "Покажи ми како",
+ "multimediaviewer-reuse-warning-nonfree": "Ова датотека није под слободном лиценцом.",
+ "multimediaviewer-reuse-warning-noattribution": "Ова датотека нема информације о ауторству.",
+ "multimediaviewer-reuse-warning-generic": "Проверите [$1 њене детаље] пре коришћења.",
+ "multimediaviewer-attr-plain": "Текст",
+ "multimediaviewer-options-tooltip": "Омогућите или онемогућите прегледач датотека",
+ "multimediaviewer-options-dialog-header": "Онемогући Media Viewer?",
+ "multimediaviewer-options-text-header": "Онемогући ову могућност за све датотеке.",
+ "multimediaviewer-options-text-body": "Накнадно је можете омогућити на страници саме датотеке.",
+ "multimediaviewer-options-learn-more": "Сазнајте више",
+ "multimediaviewer-option-submit-button": "Онемогући Media Viewer",
+ "multimediaviewer-option-cancel-button": "Откажи",
+ "multimediaviewer-disable-confirmation-header": "Онемогућили сте Media Viewer",
+ "multimediaviewer-disable-confirmation-text": "Следећи пут када кликнете на неку слику на $1, биће вам приказани сви детаљи дотичне датотеке.",
+ "multimediaviewer-enable-dialog-header": "Омогући прегледач датотека?",
+ "multimediaviewer-enable-text-header": "Омогући ову могућност као подразумевану за све датотеке.",
+ "multimediaviewer-enable-submit-button": "Омогући прегледач датотека",
+ "multimediaviewer-enable-confirmation-header": "Омогућили сте Media Viewer за све датотеке",
+ "multimediaviewer-enable-confirmation-text": "Следећи пут када кликнете на неку слику на $1, Media Viewer ће је приказати.",
+ "multimediaviewer-enable-alert": "Media Viewer је тренутно онемогућен",
+ "multimediaviewer-disable-info-title": "Онемогућили сте Media Viewer",
+ "multimediaviewer-disable-info": "И даље можете користити Media Viewer за појединачне датотеке."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sr-el.json b/www/wiki/extensions/MultimediaViewer/i18n/sr-el.json
new file mode 100644
index 00000000..f46f2813
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sr-el.json
@@ -0,0 +1,93 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01",
+ "Obsuser"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Omogući <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Media Viewer]</span>",
+ "multimediaviewer-file-page": "Idi na odgovarajuću stranicu datoteke",
+ "multimediaviewer-repository-local": "Saznajte više",
+ "multimediaviewer-datetime-created": "Napravljeno: $1",
+ "multimediaviewer-datetime-uploaded": "Poslato: $1",
+ "multimediaviewer-credit-fallback": "Vidi informacije o autoru",
+ "multimediaviewer-thumbnail-error": "Žao nam je, datoteku nije moguće prikazati",
+ "multimediaviewer-thumbnail-error-description": "Izgleda da postoji tehnički problem. Možete $1 ili $3 ako se nastavi. Greška: $2",
+ "multimediaviewer-thumbnail-error-retry": "probaj opet",
+ "multimediaviewer-license-cc-pd": "Javno vlasništvo",
+ "multimediaviewer-license-pd": "Javno vlasništvo",
+ "multimediaviewer-license-default": "Vidi licencu",
+ "multimediaviewer-permission-title": "Detalji dozvole",
+ "multimediaviewer-permission-link": "vidi uslove",
+ "multimediaviewer-permission-link-hide": "sakrij uslove",
+ "multimediaviewer-permission-viewmore": "Prikaži još",
+ "multimediaviewer-restriction-communist": "Ova slika sadrži komunistička obeležja koja su zabranjena u nekim zemljama.",
+ "multimediaviewer-restriction-insignia": "Ova slika sadrži zvanično obeležje, njihova upotreba podleže ograničenjima.",
+ "multimediaviewer-restriction-nazi": "Ova slika sadrži nacistička obeležja koja su zabranjena u nekim zemljama.",
+ "multimediaviewer-restriction-trademarked": "Ova slika možda sadrži registrovani zaštitni znak.",
+ "multimediaviewer-restriction-default": "Ova slika možda podleže nekim drugim ograničenjima nezavisno od statusa autorskih prava. Pogledajte stranicu datoteke za više informacija.",
+ "multimediaviewer-restriction-default-and-others": "Ova slika možda podleže nekim drugim ograničenjima nezavisno od statusa autorskih prava. Pogledajte stranicu datoteke za više informacija.",
+ "multimediaviewer-about-mmv": "O Media Viewer-u",
+ "multimediaviewer-discuss-mmv": "Rasprava",
+ "multimediaviewer-help-mmv": "Pomoć",
+ "multimediaviewer-optout-mmv": "Onemogući Media Viewer",
+ "multimediaviewer-optin-mmv": "Omogući Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Onemogućavanje Media Viewer-a",
+ "multimediaviewer-optin-pending-mmv": "Omogućavanje Media Viewer-a",
+ "multimediaviewer-optout-help": "Media Viewer neće više biti korišćen za prikaz slika. Da ga koristite opet kliknite na „{{int:multimediaviewer-view-expanded}}“, pa na „{{int:multimediaviewer-optin-mmv}}“.",
+ "multimediaviewer-optin-help": "Media Viewer će biti korišćen za prikazivanje slika.",
+ "multimediaviewer-geolocation": "Lokacija: $1",
+ "multimediaviewer-reuse-link": "Koristi ovu datoteku",
+ "multimediaviewer-reuse-loading-placeholder": "Učitavanje...",
+ "multimediaviewer-share-tab": "Deli",
+ "multimediaviewer-embed-tab": "Ugradi",
+ "multimediaviewer-download-link": "Preuzmi",
+ "multimediaviewer-download-preview-link-title": "Vidi u veb-pregledaču",
+ "multimediaviewer-download-original-button-name": "Preuzmi originalnu datoteku",
+ "multimediaviewer-download-small-button-name": "Preuzmi u maloj veličini",
+ "multimediaviewer-download-medium-button-name": "Preuzmi u srednjoj veličini",
+ "multimediaviewer-download-large-button-name": "Preuzmi veliku",
+ "multimediaviewer-link-to-page": "Veza do odgovarajuće stranice datoteke",
+ "multimediaviewer-link-to-file": "Veza do originalne datoteke",
+ "multimediaviewer-share-explanation": "Kopirajte i slobodno delite ovu vezu",
+ "multimediaviewer-embed-wt": "Vikitekst",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Koristite ovaj kod da ugradite datoteku",
+ "multimediaviewer-default-embed-dimensions": "Podrazumevana veličina",
+ "multimediaviewer-original-embed-dimensions": "Originalna datoteka $1",
+ "multimediaviewer-large-embed-dimensions": "Velika $1",
+ "multimediaviewer-medium-embed-dimensions": "Srednja $1",
+ "multimediaviewer-small-embed-dimensions": "Mala $1",
+ "multimediaviewer-description-page-button-text": "Prikaži detalje",
+ "multimediaviewer-description-page-popup-text": "Prikaži detalje na $1",
+ "multimediaviewer-commons-subtitle": "Riznica slobodnih medijskih datoteka",
+ "multimediaviewer-view-expanded": "Raširi",
+ "multimediaviewer-view-config": "Podešavanja",
+ "multimediaviewer-close-popup-text": "Zatvori ovu alatku (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Prikaži preko celog ekrana",
+ "multimediaviewer-defullscreen-popup-text": "Izađi iz celog ekrana",
+ "multimediaviewer-title-popup-text": "Naziv datoteke",
+ "multimediaviewer-credit-popup-text": "Autor i informacije o izvoru",
+ "multimediaviewer-title-popup-text-more": "Vidi ceo opis",
+ "multimediaviewer-download-attribution-cta-header": "Morate navesti autora",
+ "multimediaviewer-download-optional-attribution-cta-header": "Možete navesti autora",
+ "multimediaviewer-download-attribution-cta": "Pokaži mi kako",
+ "multimediaviewer-attr-plain": "Tekst",
+ "multimediaviewer-options-tooltip": "Omogući ili onemogući Media Viewer",
+ "multimediaviewer-options-dialog-header": "Onemogući Media Viewer?",
+ "multimediaviewer-options-text-header": "Onemogući ovu mogućnost za sve datoteke.",
+ "multimediaviewer-options-text-body": "Naknadno je možete omogućiti na stranici same datoteke.",
+ "multimediaviewer-options-learn-more": "Saznajte više",
+ "multimediaviewer-option-submit-button": "Onemogući Media Viewer",
+ "multimediaviewer-option-cancel-button": "Otkaži",
+ "multimediaviewer-disable-confirmation-header": "Onemogućili ste Media Viewer",
+ "multimediaviewer-disable-confirmation-text": "Sledeći put kada kliknete na neku sliku na $1, biće vam prikazani svi detalji dotične datoteke.",
+ "multimediaviewer-enable-dialog-header": "Omogući Media Viewer?",
+ "multimediaviewer-enable-text-header": "Omogući ovu mogućnost kao podrazumevanu za sve datoteke.",
+ "multimediaviewer-enable-submit-button": "Omogući Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "Omogućili ste Media Viewer za sve datoteke",
+ "multimediaviewer-enable-confirmation-text": "Sledeći put kada kliknete na neku sliku na $1, Media Viewer će je prikazati.",
+ "multimediaviewer-enable-alert": "Media Viewer je trenutno onemogućen",
+ "multimediaviewer-disable-info-title": "Onemogućili ste Media Viewer",
+ "multimediaviewer-disable-info": "I dalje možete koristiti Media Viewer za pojedinačne datoteke."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/su.json b/www/wiki/extensions/MultimediaViewer/i18n/su.json
new file mode 100644
index 00000000..0aec1152
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/su.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Uchup19"
+ ]
+ },
+ "multimediaviewer-option-cancel-button": "Bolay"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sv.json b/www/wiki/extensions/MultimediaViewer/i18n/sv.json
new file mode 100644
index 00000000..f920f8e3
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sv.json
@@ -0,0 +1,119 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ainali",
+ "Jopparn",
+ "Lokal Profil",
+ "NH",
+ "WikiPhoenix",
+ "Stens51",
+ "Abbedabb",
+ "Warrakkk",
+ "Hangsna",
+ "Bengtsson96"
+ ]
+ },
+ "multimediaviewer-desc": "Expandera miniatyrer i en större storlek i fulkskärmsgränssnitt.",
+ "multimediaviewer-pref": "Mediavisare",
+ "multimediaviewer-pref-desc": "Förbättra din multimediaupplevelse med detta nya verktyg. Det visar bilder i större storlek på sidor som har miniatyrer. Bilder visas i ett trevligare fullskärmsöverlägg, och kan också ses i full storlek.",
+ "multimediaviewer-optin-pref": "Aktivera <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Mediavisaren]</span>",
+ "multimediaviewer-file-page": "Gå till motsvarande filsida",
+ "multimediaviewer-repository-local": "Mer detaljer",
+ "multimediaviewer-datetime-created": "Skapades: $1",
+ "multimediaviewer-datetime-uploaded": "Laddades upp: $1",
+ "multimediaviewer-credit-fallback": "Visa information om skapare",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ytterligare en skapare|ytterligare $1 skapare}}",
+ "multimediaviewer-multiple-authors-combine": "$1 och $2",
+ "multimediaviewer-metadata-error": "Kunde inte läsa in bilddetaljer. (Fel: $1)",
+ "multimediaviewer-thumbnail-error": "Tyvärr, filen kan inte visas",
+ "multimediaviewer-thumbnail-error-description": "Ett tekniskt fel har uppstått. Du kan $1 eller $3 om det kvarstår. Felmeddelande: $2",
+ "multimediaviewer-thumbnail-error-retry": "försöka igen",
+ "multimediaviewer-thumbnail-error-report": "rapportera problemet",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Public Domain",
+ "multimediaviewer-license-pd": "Public Domain",
+ "multimediaviewer-license-default": "Visa licens",
+ "multimediaviewer-permission-title": "Behörighetsdetaljer",
+ "multimediaviewer-permission-link": "visa villkor",
+ "multimediaviewer-permission-link-hide": "dölj villkor",
+ "multimediaviewer-permission-viewmore": "Visa mer",
+ "multimediaviewer-restriction-trademarked": "Denna bild innehåller material som kan vara föremål för varumärkesrättsliga lagar.",
+ "multimediaviewer-about-mmv": "Om",
+ "multimediaviewer-discuss-mmv": "Diskussion",
+ "multimediaviewer-help-mmv": "Hjälp",
+ "multimediaviewer-optout-mmv": "Inaktivera Mediavisaren",
+ "multimediaviewer-optin-mmv": "Aktivera Mediavisaren",
+ "multimediaviewer-optout-pending-mmv": "Inaktivera Mediavisaren",
+ "multimediaviewer-optin-pending-mmv": "Aktivera Mediavisaren",
+ "multimediaviewer-optout-help": "Mediavisaren kommer inte längre att användas för att visa bilder. För att använda den igen, klicka på \"{{int:multimediaviewer-view-expanded}}\"-knappen bredvid valfri bild. Klicka sedan på \"{{int:multimediaviewer-optin-mmv}}\".",
+ "multimediaviewer-optin-help": "Mediavisaren kommer att användas för att visa bilder.",
+ "multimediaviewer-geolocation": "Plats: $1",
+ "multimediaviewer-reuse-link": "Använd eller bädda in denna fil",
+ "multimediaviewer-reuse-loading-placeholder": "Läser in...",
+ "multimediaviewer-share-tab": "Dela",
+ "multimediaviewer-embed-tab": "Bädda in",
+ "multimediaviewer-download-link": "Ladda ner denna fil",
+ "multimediaviewer-download-preview-link-title": "Visa i webbläsare",
+ "multimediaviewer-download-original-button-name": "Ladda ned originalfil",
+ "multimediaviewer-download-small-button-name": "Ladda ner liten storlek",
+ "multimediaviewer-download-medium-button-name": "Ladda ner medium storlek",
+ "multimediaviewer-download-large-button-name": "Ladda ner stor storlek",
+ "multimediaviewer-link-to-page": "Länk till filbeskrivningssidan",
+ "multimediaviewer-link-to-file": "Länk till originalfil",
+ "multimediaviewer-share-explanation": "Kopiera och dela fritt länken",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Använd denna kod för att bädda in filen",
+ "multimediaviewer-text-embed-credit-text-bl": "Av $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Av $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Av $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Av $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Länk",
+ "multimediaviewer-embed-byline": "Av $1",
+ "multimediaviewer-embed-license": "Licenserat under $1.",
+ "multimediaviewer-embed-via": "Via $1.",
+ "multimediaviewer-default-embed-dimensions": "Standardstorlek för miniatyrer",
+ "multimediaviewer-original-embed-dimensions": "Originalfil $1",
+ "multimediaviewer-large-embed-dimensions": "Stor $1",
+ "multimediaviewer-medium-embed-dimensions": "Medium $1",
+ "multimediaviewer-small-embed-dimensions": "Liten $1",
+ "multimediaviewer-description-page-button-text": "Fler detaljer om denna fil",
+ "multimediaviewer-description-page-popup-text": "Mer detaljer om den här filen på $1",
+ "multimediaviewer-commons-subtitle": "Det fria mediearkivet",
+ "multimediaviewer-view-expanded": "Öppna i Mediavisare",
+ "multimediaviewer-view-config": "Konfigurering",
+ "multimediaviewer-close-popup-text": "Stäng detta verktyg (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Visa i helskärmsläge",
+ "multimediaviewer-defullscreen-popup-text": "Lämnar helskärmsläge",
+ "multimediaviewer-next-image-alt-text": "Visa nästa bild",
+ "multimediaviewer-prev-image-alt-text": "Visa föregående bild",
+ "multimediaviewer-title-popup-text": "Beskrivning",
+ "multimediaviewer-credit-popup-text": "Information om skapare och källa",
+ "multimediaviewer-title-popup-text-more": "Visa full beskrivning",
+ "multimediaviewer-credit-popup-text-more": "Visa all information om skapare och källa",
+ "multimediaviewer-download-attribution-cta-header": "Du måste ge skaparen erkännande",
+ "multimediaviewer-download-optional-attribution-cta-header": "Du kan ge skaparen erkännande",
+ "multimediaviewer-download-attribution-cta": "Visa mig hur",
+ "multimediaviewer-reuse-warning-deletion": "Filen är föreslagen för radering.",
+ "multimediaviewer-reuse-warning-nonfree": "Filen har inte en fri licens.",
+ "multimediaviewer-reuse-warning-generic": "Kontrollera [$1 filens detaljer] före användning.",
+ "multimediaviewer-attr-plain": "Klartext",
+ "multimediaviewer-options-tooltip": "Aktivera eller inaktivera Mediavisaren",
+ "multimediaviewer-options-dialog-header": "Inaktivera Mediavisaren?",
+ "multimediaviewer-options-text-header": "Skippa denna visningsfunktion för alla filer.",
+ "multimediaviewer-options-text-body": "Du kan aktivera det senare genom filens beskrivningssida.",
+ "multimediaviewer-options-learn-more": "Läs mer",
+ "multimediaviewer-option-submit-button": "Inaktivera Mediavisaren",
+ "multimediaviewer-option-cancel-button": "Avbryt",
+ "multimediaviewer-disable-confirmation-header": "Du har inaktiverat Media Viewer",
+ "multimediaviewer-disable-confirmation-text": "Nästa gång du klickar på en miniatyrbild på $1 kommer du direkt se all filinformation.",
+ "multimediaviewer-enable-dialog-header": "Aktiverar Media Viewer?",
+ "multimediaviewer-enable-text-header": "Aktivera denna mediavisare för alla filer som standard.",
+ "multimediaviewer-enable-submit-button": "Aktivera Media Viewer",
+ "multimediaviewer-enable-confirmation-header": "Du har aktiverat Media Viewer för alla filer",
+ "multimediaviewer-enable-confirmation-text": "Nästa gång du klickar på en miniatyrbild på $1 kommer Media Viewer att användas.",
+ "multimediaviewer-enable-alert": "Media Viewer är nu inaktiverad",
+ "multimediaviewer-disable-info-title": "Du har inaktiverat Media Viewer",
+ "multimediaviewer-disable-info": "Du kan fortfarande visa enskilda filer med Media Viewer."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/sw.json b/www/wiki/extensions/MultimediaViewer/i18n/sw.json
new file mode 100644
index 00000000..c6b1086f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/sw.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lloffiwr"
+ ]
+ },
+ "multimediaviewer-license-default": "Tazama leseni",
+ "multimediaviewer-permission-title": "Maelezo ya leseni",
+ "multimediaviewer-permission-viewmore": "Tazama zaidi",
+ "multimediaviewer-about-mmv": "Kuhusu Media Viewer",
+ "multimediaviewer-help-mmv": "Msaada",
+ "multimediaviewer-reuse-link": "Tumia faili hili",
+ "multimediaviewer-embed-html": "HTML"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ta.json b/www/wiki/extensions/MultimediaViewer/i18n/ta.json
new file mode 100644
index 00000000..98131e21
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ta.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "ElangoRamanujam",
+ "Kalyanasundar"
+ ]
+ },
+ "multimediaviewer-optin-pref": "இயலச்செய்",
+ "multimediaviewer-repository-local": "மேலதிக விபரங்கள்",
+ "multimediaviewer-download-link": "இக்கோப்பைப் பதிவிறக்குக",
+ "multimediaviewer-description-page-button-text": "மேலதிக விபரங்கள்"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/tcy.json b/www/wiki/extensions/MultimediaViewer/i18n/tcy.json
new file mode 100644
index 00000000..de5705b3
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/tcy.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Soundarya shetty s",
+ "Bharathesha Alasandemajalu"
+ ]
+ },
+ "multimediaviewer-thumbnail-error-report": "ಸಮಸ್ಯೆನ್ ವರದಿ ಮಲ್ಪುಲೆ"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/te.json b/www/wiki/extensions/MultimediaViewer/i18n/te.json
new file mode 100644
index 00000000..219b4b9c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/te.json
@@ -0,0 +1,60 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chaduvari",
+ "Ravichandra",
+ "రహ్మానుద్దీన్",
+ "Veeven"
+ ]
+ },
+ "multimediaviewer-desc": "పూర్తి స్క్రీను అంతరవర్తినిలో గోరంతబొమ్మను పెద్ద పరిణామంలోకి మార్చు.",
+ "multimediaviewer-pref": "మీడియా వ్యూయర్",
+ "multimediaviewer-pref-desc": "ఈ సరికొత్త ఉపకరణంతో బొమ్మలను చూసే అనుభవాన్ని మరింత మెరుగుపరుచుకోండి. ఇది పేజీలో ఉన్న గోరంతబొమ్మ(నఖచిత్రా)లను పెద్దదిగా చూపిస్తుంది. బొమ్మలు మెరుగైన పూర్తి స్క్రీన్ ఓవర్లే లో చూపబడతాయి, పూర్తి స్థాయి బొమ్మ పరిమాణం కూడా చూడవచ్చు.",
+ "multimediaviewer-optin-pref": "సరికొత్త బొమ్మలను చూసే అనుభూతిని సచేతనం చేసుకోండి",
+ "multimediaviewer-file-page": "సంబంధిత దస్త్రపు పేజీకు వెళ్ళండి",
+ "multimediaviewer-repository-local": "మరిన్ని వివరాలు",
+ "multimediaviewer-datetime-created": "$1 న సృష్టించబడింది",
+ "multimediaviewer-datetime-uploaded": "$1 న ఎక్కించబడింది",
+ "multimediaviewer-metadata-error": "దోషం : $1. బొమ్మ సమాచారాన్ని చూపలేకపోతున్నాం.",
+ "multimediaviewer-thumbnail-error": "దోషం : $1. గోరంతబొమ్మ (నఖచిత్రం) సమాచారాన్ని చూపించలేకపోతున్నాం.",
+ "multimediaviewer-license-cc-pd": "సార్వజనీనం",
+ "multimediaviewer-license-pd": "సార్వజనీనం",
+ "multimediaviewer-license-default": "లైసెన్స్ వివరాలు చూడండి",
+ "multimediaviewer-permission-title": "అనుమతి వివరాలు",
+ "multimediaviewer-permission-link": "నిబంధనలు చూడండి",
+ "multimediaviewer-permission-viewmore": "మరింత చూడండి",
+ "multimediaviewer-about-mmv": "గురించి",
+ "multimediaviewer-discuss-mmv": "చర్చ",
+ "multimediaviewer-help-mmv": "సహాయం",
+ "multimediaviewer-geolocation": "స్థానం : $1",
+ "multimediaviewer-reuse-link": "ఈ దస్త్రాన్ని వాడండి",
+ "multimediaviewer-reuse-loading-placeholder": "లోడవుతోంది...",
+ "multimediaviewer-share-tab": "పంచుకోండి",
+ "multimediaviewer-embed-tab": "ఇముడ్చు",
+ "multimediaviewer-download-link": "దింపుకోండి",
+ "multimediaviewer-download-preview-link-title": "విహారిణిలో మునుజూపు చూడండి",
+ "multimediaviewer-download-original-button-name": "అసలు పరిమాణంలో దింపుకోండి",
+ "multimediaviewer-download-small-button-name": "చిన్ని పరిమాణంలో దింపుకోండి",
+ "multimediaviewer-download-medium-button-name": "మధ్యస్థ పరిమాణంలో దింపుకోండి",
+ "multimediaviewer-download-large-button-name": "పెద్ద పరిమాణంలో దింపుకోండి",
+ "multimediaviewer-link-to-page": "దస్త్రపు వివరణ పేజీకి లంకె",
+ "multimediaviewer-link-to-file": "అసలు దస్త్రానికి లంకె",
+ "multimediaviewer-share-explanation": "నకలు తీసుకొని, స్వేచ్ఛగా లంకెను పంచుకోండి",
+ "multimediaviewer-embed-wt": "వికీపాఠ్యం",
+ "multimediaviewer-embed-html": "హెచ్.టి.ఎం.ఎల్",
+ "multimediaviewer-embed-explanation": "దస్త్రాన్ని ఇమిడ్చేందుకు ఈ కోడ్ ను వాడండి",
+ "multimediaviewer-embed-byline": "$1 ద్వారా",
+ "multimediaviewer-embed-license": "$1 లైసెన్సుకు లోబడి",
+ "multimediaviewer-embed-via": "$1 ద్వారా.",
+ "multimediaviewer-default-embed-dimensions": "అప్రమేయ నఖచిత్ర(గోరంతబొమ్మ) పరిమాణం",
+ "multimediaviewer-original-embed-dimensions": "అసలు పరిమాణం $1",
+ "multimediaviewer-large-embed-dimensions": "పెద్ద పరిమాణం $1",
+ "multimediaviewer-medium-embed-dimensions": "మధ్యస్థ పరిమాణం $1",
+ "multimediaviewer-small-embed-dimensions": "చిన్న పరిమాణం $1",
+ "multimediaviewer-description-page-button-text": "ఈ దస్త్రం గురించి మరిన్ని వివరాలు",
+ "multimediaviewer-description-page-popup-text": "$1 పై మరిన్ని వివరాలు",
+ "multimediaviewer-commons-subtitle": "స్వేచ్ఛా దస్త్రాల భాండాగారం",
+ "multimediaviewer-view-expanded": "వీక్షణాన్ని పెద్దది చేయండి",
+ "multimediaviewer-next-image-alt-text": "తర్వాతి బొమ్మను చూపించు",
+ "multimediaviewer-prev-image-alt-text": "మునుపటి బొమ్మను చూపించు"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/tg-cyrl.json b/www/wiki/extensions/MultimediaViewer/i18n/tg-cyrl.json
new file mode 100644
index 00000000..ad5aaeb5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/tg-cyrl.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "ToJack"
+ ]
+ },
+ "multimediaviewer-embed-wt": "Вики-матн"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/th.json b/www/wiki/extensions/MultimediaViewer/i18n/th.json
new file mode 100644
index 00000000..ef85e31f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/th.json
@@ -0,0 +1,27 @@
+{
+ "@metadata": {
+ "authors": [
+ "Horus",
+ "Nullzero",
+ "Taweetham",
+ "Ans"
+ ]
+ },
+ "multimediaviewer-desc": "ขยายรูปขนาดย่อให้มีขนาดใหญ่ขึ้นในอินเตอร์เฟซเต็มหน้าจอ",
+ "multimediaviewer-pref": "Media Viewer",
+ "multimediaviewer-pref-desc": "ด้วยเครื่องมือใหม่นี้ คุณสามารถดูสื่อได้ดีไปกว่าเดิม เครื่องมือจะแสดงภาพขนาดใหญ่ขึ้นบนหน้าที่มีรูปขนาดย่อ คุณยังสามารถดูภาพแบบในอินเตอร์เฟซเต็มหน้าจอและดูภาพในขนาดเต็มได้ด้วย",
+ "multimediaviewer-file-page": "ไปยังหน้าไฟล์ที่ตรงกัน",
+ "multimediaviewer-repository-local": "ดูรายละเอียดเพิ่มเติมเกี่ยวกับไฟล์นี้",
+ "multimediaviewer-datetime-created": "สร้าง: $1",
+ "multimediaviewer-datetime-uploaded": "อัปโหลด: $1",
+ "multimediaviewer-license-cc-pd": "สาธารณสมบัติ",
+ "multimediaviewer-license-pd": "สาธารณสมบัติ",
+ "multimediaviewer-license-default": "ดูสัญญาอนุญาต",
+ "multimediaviewer-permission-title": "รายละเอียดสัญญาอนุญาต",
+ "multimediaviewer-permission-link": "ดูเงื่อนไข",
+ "multimediaviewer-permission-viewmore": "ดูเพิ่มเติม",
+ "multimediaviewer-about-mmv": "เกี่ยวกับ Media Viewer",
+ "multimediaviewer-discuss-mmv": "อธิบายคุณลักษณะนี้",
+ "multimediaviewer-geolocation": "สถานที่: $1",
+ "multimediaviewer-reuse-link": "ใช้ไฟล์นี้"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/tl.json b/www/wiki/extensions/MultimediaViewer/i18n/tl.json
new file mode 100644
index 00000000..459fa3ea
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/tl.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jewel457",
+ "Leeheonjin"
+ ]
+ },
+ "multimediaviewer-repository-local": "Iba pang detalye tungkol sa file",
+ "multimediaviewer-thumbnail-error-report": "iulat ang palahatla (issue) na ito",
+ "multimediaviewer-optin-mmv": "Pinapagana ang Media Viewer",
+ "multimediaviewer-optout-pending-mmv": "Isinasara ang Media Viewer"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/tr.json b/www/wiki/extensions/MultimediaViewer/i18n/tr.json
new file mode 100644
index 00000000..84c8ed66
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/tr.json
@@ -0,0 +1,80 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ceas08",
+ "Incelemeelemani",
+ "Rapsar",
+ "SiLveRLeaD",
+ "Sucsuzz",
+ "Meelo",
+ "Sayginer",
+ "Violetanka",
+ "McAang"
+ ]
+ },
+ "multimediaviewer-desc": "Küçük resimleri daha büyük boyutlara genişleterek, tam ekran arayüzde gösterir.",
+ "multimediaviewer-pref": "Ortam Görüntüleyici",
+ "multimediaviewer-pref-desc": "Bu yeni araçla multimedya görüntüleme deneyiminizi geliştirin. Bu sayede küçük sayfaları daha büyük boyutlarda görüntüleyebilirsiniz. Ayrıca görüntüler tam ekran arayüzle ve tam boyutlu görüntülebeilir.",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Ortam Görüntüleyici]</span>'yi etkinleştir",
+ "multimediaviewer-file-page": "İlgili dosya sayfasına git",
+ "multimediaviewer-repository-local": "Bu dosya hakkında daha fazla bilgi",
+ "multimediaviewer-datetime-created": "Oluşturulma tarihi: $1",
+ "multimediaviewer-datetime-uploaded": "Yüklenme tarihi: $1",
+ "multimediaviewer-metadata-error": "Hata: Resim verisi yüklenemedi. $1",
+ "multimediaviewer-thumbnail-error": "Hata: Küçük resim verisi yüklenemedi. $1",
+ "multimediaviewer-license-cc-pd": "Kamu Malı",
+ "multimediaviewer-license-pd": "Kamu Malı",
+ "multimediaviewer-license-default": "Lisansı göster",
+ "multimediaviewer-permission-title": "Lisans ayrıntıları",
+ "multimediaviewer-permission-link": "şartları görüntüle",
+ "multimediaviewer-permission-viewmore": "Daha fazla",
+ "multimediaviewer-about-mmv": "Ortam Görüntüleyici hakkında",
+ "multimediaviewer-discuss-mmv": "Bu özelliği tartış",
+ "multimediaviewer-help-mmv": "Yardım",
+ "multimediaviewer-optout-mmv": "Ortam Görüntüleyici'yi devre dışı bırak",
+ "multimediaviewer-optin-mmv": "Ortam Görüntüleyici'yi etkinleştir",
+ "multimediaviewer-optout-pending-mmv": "Ortam Görüntüleyici devre dışı bırakılıyor",
+ "multimediaviewer-optin-pending-mmv": "Ortam Görüntüleyici etkinleştiriliyor",
+ "multimediaviewer-optout-help": "Seçerseniz artık görüntüler için Ortam Görüntüleyici kullanılmayacak. Tekrar kullanmak için, herhangi bir görüntünün yanındaki \"{{int:multimediaviewer-view-expanded}}\" butonuna ve sonrasında \"{{int:multimediaviewer-optin-mmv}}\" seçeneğine tıklayın.",
+ "multimediaviewer-optin-help": "Artık görüntüler için Ortam Görüntüleyici kullanılacak.",
+ "multimediaviewer-geolocation": "Konum: $1",
+ "multimediaviewer-reuse-link": "Bu dosyayı paylaş veya bir siteye yerleştir",
+ "multimediaviewer-reuse-loading-placeholder": "Yükleniyor...",
+ "multimediaviewer-share-tab": "Paylaş",
+ "multimediaviewer-embed-tab": "Göm",
+ "multimediaviewer-download-link": "Bu dosyayı indirin",
+ "multimediaviewer-download-preview-link-title": "Tarayıcıda görüntüle",
+ "multimediaviewer-download-original-button-name": "Özgün dosyayı indir",
+ "multimediaviewer-download-small-button-name": "Küçük boyutta indir",
+ "multimediaviewer-download-medium-button-name": "Orta boyutta indir",
+ "multimediaviewer-download-large-button-name": "Büyük boyutta indir",
+ "multimediaviewer-link-to-page": "Dosya açıklama sayfası bağlantısı",
+ "multimediaviewer-link-to-file": "Özgün dosya bağlantısı",
+ "multimediaviewer-share-explanation": "Bağlantıyı kopyala ve özgürce paylaş",
+ "multimediaviewer-embed-wt": "Vikimetin",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Dosyayı gömmek için bu kodu kullanın",
+ "multimediaviewer-embed-byline": "$1 tarafından",
+ "multimediaviewer-embed-license": "$1 ile lisanslanmıştır.",
+ "multimediaviewer-embed-via": "$1 kaynağındandır.",
+ "multimediaviewer-default-embed-dimensions": "Varsayılan küçük resim boyutu",
+ "multimediaviewer-original-embed-dimensions": "Özgün dosya $1",
+ "multimediaviewer-large-embed-dimensions": "Büyük $1",
+ "multimediaviewer-medium-embed-dimensions": "Orta $1",
+ "multimediaviewer-small-embed-dimensions": "Küçük $1",
+ "multimediaviewer-description-page-button-text": "Bu dosya hakkında daha fazla bilgi",
+ "multimediaviewer-description-page-popup-text": "$1 üzerinde bu dosya hakkında daha fazla bilgi",
+ "multimediaviewer-commons-subtitle": "Özgür ortam havuzu",
+ "multimediaviewer-view-expanded": "Medya Görüntüleyici'de açın",
+ "multimediaviewer-close-popup-text": "Aracı kapat (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Tam ekran göster",
+ "multimediaviewer-defullscreen-popup-text": "Tam ekrandan çık",
+ "multimediaviewer-title-popup-text": "Dosya adı",
+ "multimediaviewer-title-popup-text-more": "Tam dosya adını görüntülemek için tıklayın",
+ "multimediaviewer-download-attribution-cta-header": "Oluşturana atıf yapmanız gerekiyor",
+ "multimediaviewer-download-attribution-cta": "Nasıl yapıldığını göster",
+ "multimediaviewer-options-tooltip": "Ortam Görüntüleyici'yi etkinleştir veya devre dışı bırak",
+ "multimediaviewer-options-dialog-header": "Ortam Görüntüleyici devre dışı bırakılsın mı?",
+ "multimediaviewer-options-text-header": "Bu görüntüleme özelliğini tüm dosyalar için devre dışı bırak.",
+ "multimediaviewer-options-text-body": "Daha sonra dosya ayrıntıları sayfasından etkinleştirebilirsiniz."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/tt-cyrl.json b/www/wiki/extensions/MultimediaViewer/i18n/tt-cyrl.json
new file mode 100644
index 00000000..24987aa2
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/tt-cyrl.json
@@ -0,0 +1,77 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ильнар"
+ ]
+ },
+ "multimediaviewer-pref": "Медиа гизгеч",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Медиа гизгечне]</span> куллану",
+ "multimediaviewer-repository-local": "Тулырак",
+ "multimediaviewer-datetime-created": "Ясалу: $1",
+ "multimediaviewer-datetime-uploaded": "Йөкләнү: $1",
+ "multimediaviewer-credit": "$1 - $2",
+ "multimediaviewer-credit-fallback": "Автор турында мәгълүмат",
+ "multimediaviewer-multiple-authors": "тагын {{PLURAL:$1|бер автор|$1 автор}}",
+ "multimediaviewer-multiple-authors-combine": "$1 һәм $2",
+ "multimediaviewer-thumbnail-error": "Гафу итегез, файлны ачу мөмкин түгел",
+ "multimediaviewer-thumbnail-error-retry": "кабатлау",
+ "multimediaviewer-thumbnail-error-report": "хата турында хәбәр итү",
+ "multimediaviewer-license-cc-pd": "Җәмгыять мирасы",
+ "multimediaviewer-license-pd": "Җәмгыять мирасы",
+ "multimediaviewer-license-default": "Лицензияне карау",
+ "multimediaviewer-permission-title": "Шартлар турында мәгълүмат",
+ "multimediaviewer-permission-link": "хокукларны карау",
+ "multimediaviewer-permission-link-hide": "хокукларны яшерү",
+ "multimediaviewer-permission-viewmore": "Тулырак мәгълүмат",
+ "multimediaviewer-about-mmv": "Тасвирлама",
+ "multimediaviewer-discuss-mmv": "Бәхәс",
+ "multimediaviewer-help-mmv": "Ярдәм",
+ "multimediaviewer-optout-mmv": "Медиа гизгечне ябу",
+ "multimediaviewer-optin-mmv": "Медиа гизгечне ачу",
+ "multimediaviewer-optout-pending-mmv": "Медиа гизгечне ябу",
+ "multimediaviewer-optin-pending-mmv": "Медиа гизгечне ачу",
+ "multimediaviewer-optin-help": "Рәсемнәрне курсәтү өчен медиа гизгеч кулланылачак",
+ "multimediaviewer-geolocation": "Географик урыны: $1",
+ "multimediaviewer-reuse-link": "Файлны өлү яисә бүлешү",
+ "multimediaviewer-reuse-loading-placeholder": "Йөкләү...",
+ "multimediaviewer-share-tab": "Бүлешү",
+ "multimediaviewer-embed-tab": "Кую",
+ "multimediaviewer-download-link": "Файлны йөкләү",
+ "multimediaviewer-download-preview-link-title": "Гизгечтә карау",
+ "multimediaviewer-download-original-button-name": "Төп файлны алу",
+ "multimediaviewer-download-small-button-name": "Кече зурлыкта алу",
+ "multimediaviewer-download-medium-button-name": "Уртача зурлыкта алу",
+ "multimediaviewer-download-large-button-name": "Зур зурлыкта алу",
+ "multimediaviewer-embed-wt": "Викитекст",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-text-embed-credit-text-bl": "Автор: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Автор: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Автор: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Автор: $1, $2",
+ "multimediaviewer-embed-byline": "Кулланучы $1",
+ "multimediaviewer-embed-license": "$1 лицензиясе астында.",
+ "multimediaviewer-embed-via": "$1 аркылы.",
+ "multimediaviewer-original-embed-dimensions": "Төп файл $1",
+ "multimediaviewer-large-embed-dimensions": "Зур $1",
+ "multimediaviewer-medium-embed-dimensions": "Уратача $1",
+ "multimediaviewer-small-embed-dimensions": "Кече $1",
+ "multimediaviewer-view-expanded": "Медиа гизгечтә ачу",
+ "multimediaviewer-view-config": "Көйләү",
+ "multimediaviewer-close-popup-text": "Коралны ябу (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Тулы экранда күрсәтү",
+ "multimediaviewer-defullscreen-popup-text": "Тулы экран режимыннан чыгу",
+ "multimediaviewer-title-popup-text": "Тасвирлама",
+ "multimediaviewer-credit-popup-text": "Авторы һәм чыганагы турында мәгълүмат",
+ "multimediaviewer-title-popup-text-more": "Тулы тасвирны карау",
+ "multimediaviewer-credit-popup-text-more": "Автор һәм чыганак турында тулырак мәгълүмат",
+ "multimediaviewer-download-attribution-cta-header": "Сезга авторын күрсәтү кирәк",
+ "multimediaviewer-attr-plain": "Гади",
+ "multimediaviewer-options-dialog-header": "Медиа гизгечне ябаргамы?",
+ "multimediaviewer-options-text-header": "Әлеге мөмкинлекне бөтен файллар өчен дә сүндерергә.",
+ "multimediaviewer-options-text-body": "Кирәк чакта, сез аны файл турындагы мәгълүмат битендә куша аласыз.",
+ "multimediaviewer-options-learn-more": "Күбрәк белү",
+ "multimediaviewer-option-submit-button": "Медиа гизгечне ябу",
+ "multimediaviewer-option-cancel-button": "Баш тарту",
+ "multimediaviewer-enable-dialog-header": "Медиа гизгечне ачу?",
+ "multimediaviewer-enable-submit-button": "Медиа гизгечне ачу"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/uk.json b/www/wiki/extensions/MultimediaViewer/i18n/uk.json
new file mode 100644
index 00000000..78d35595
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/uk.json
@@ -0,0 +1,133 @@
+{
+ "@metadata": {
+ "authors": [
+ "Andriykopanytsia",
+ "Ата",
+ "Sergento",
+ "Olion",
+ "Piramidion",
+ "Macofe",
+ "Base"
+ ]
+ },
+ "multimediaviewer-desc": "Розгорнути мініатюри в більшому розмірі у лайтбоксі.",
+ "multimediaviewer-pref": "Медіа переглядач",
+ "multimediaviewer-pref-desc": "Поліпшити ваші враження від перегляду мультимедіа з цим новим інструментом. Він відображає зображення у більшому розмірі на сторінках, які мають ескізи. Зображення показані у кращому накладенні і також відображаються в натуральну величину.",
+ "multimediaviewer-optin-pref": "Увімкнути <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About Медіапереглядач]</span>",
+ "multimediaviewer-file-page": "Перейти на сторінку відповідного файлу",
+ "multimediaviewer-repository-local": "Докладніше",
+ "multimediaviewer-datetime-created": "Створено $1",
+ "multimediaviewer-datetime-uploaded": "Завантажено $1",
+ "multimediaviewer-credit-fallback": "Переглянути інформацію про автора",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|ще один автор|$1 інші автори|$1 інших авторів}}",
+ "multimediaviewer-multiple-authors-combine": "$1 і $2",
+ "multimediaviewer-metadata-error": "Не вдалося завантажити дані зображення (помилка: $1)",
+ "multimediaviewer-thumbnail-error": "Вибачте, файл не можна відобразити",
+ "multimediaviewer-thumbnail-error-description": "Схоже, виникла технічна проблема. Ви можете $1 або $3, якщо вона збережеться. Помилка: $2",
+ "multimediaviewer-thumbnail-error-retry": "повторити",
+ "multimediaviewer-thumbnail-error-report": "повідомити про проблему",
+ "multimediaviewer-license-cc-pd": "Суспільне надбання",
+ "multimediaviewer-license-pd": "Суспільне надбання (Public Domain)",
+ "multimediaviewer-license-default": "Перегляд ліцензії",
+ "multimediaviewer-permission-title": "Відомості про дозвіл",
+ "multimediaviewer-permission-link": "перегляд умов",
+ "multimediaviewer-permission-link-hide": "приховати умови",
+ "multimediaviewer-permission-viewmore": "Показати докладно",
+ "multimediaviewer-restriction-2257": "Це зображення містить відвертий сексуальний вміст, який може підпадати під дію Закону США про захист дітей і примус до непристойності.",
+ "multimediaviewer-restriction-aus-reserve": "Це зображення є фотографією із заповідника Австралійського Союзу і не може використовуватися у комерційних цілях без дозволу.",
+ "multimediaviewer-restriction-communist": "Це зображення містить комуністичні символи, які можуть бути заборонені в деяких країнах.",
+ "multimediaviewer-restriction-costume": "Цей зображення містить костюми і може бути предметом юридичних обмежень.",
+ "multimediaviewer-restriction-currency": "Це зображення є зображенням грошової одиниці і може бути предметом юридичних обмежень.",
+ "multimediaviewer-restriction-design": "Дизайн предмета цього зображення може бути захищений авторським правом і бути предметом юридичних обмежень.",
+ "multimediaviewer-restriction-fan-art": "Це зображення є фан-артом, його повторне використання може бути предметом юридичних обмежень.",
+ "multimediaviewer-restriction-ihl": "Це зображення містить символи, заборонені міжнародним гуманітарним правом.",
+ "multimediaviewer-restriction-insignia": "Це зображення містить офіційні знаки, які можуть бути предметом юридичних обмежень.",
+ "multimediaviewer-restriction-ita-mibac": "Це зображення відтворює майно, що належить до культурної спадщини Італії, й підпадає під обмеження за італійськими законами.",
+ "multimediaviewer-restriction-nazi": "Це зображення містить нацистську або іншу фашистську символіку, яка може бути заборонена в деяких країнах.",
+ "multimediaviewer-restriction-personality": "Це зображення містить осіб, які можуть мати права, що юридично обмежують певне повторне використання зображення без згоди.",
+ "multimediaviewer-restriction-trademarked": "Це зображення має вміст, що може бути об'єктом законів про товарні знаки.",
+ "multimediaviewer-restriction-default": "Це зображення може бути обмежене правовими нормами за межами авторського права. Див. сторінку опису файлу для детальнішої інформації.",
+ "multimediaviewer-restriction-default-and-others": "Це зображення може бути ще більш обмежене іншими правовими нормами за межами авторського права. Див. сторінку опису файлу для інформації.",
+ "multimediaviewer-about-mmv": "Про програму",
+ "multimediaviewer-discuss-mmv": "Обговорення",
+ "multimediaviewer-help-mmv": "Допомога",
+ "multimediaviewer-optout-mmv": "Вимкнути медіапереглядач",
+ "multimediaviewer-optin-mmv": "Увімкнути медіапереглядач",
+ "multimediaviewer-optout-pending-mmv": "Вимкнення медіапереглядача",
+ "multimediaviewer-optin-pending-mmv": "Увімкнення медіапереглядача",
+ "multimediaviewer-optout-help": "Медіаперелядач більше не використовуватиметься для показу зображень. Щоб використовувати його знову, натисніть кнопку «{{int:multimediaviewer-view-expanded}}» поруч з будь-яким зображенням. Далі натисніть «{{int:multimediaviewer-optin-mmv}}».",
+ "multimediaviewer-optin-help": "Медіапереглядач використовуватиметься для показу зображень.",
+ "multimediaviewer-geolocation": "Розташування:$1",
+ "multimediaviewer-reuse-link": "Поділитися чи вставити цей файл",
+ "multimediaviewer-reuse-loading-placeholder": "Завантаження...",
+ "multimediaviewer-reuse-copy-share": "Виділіть і скопіюйте (якщо підтримується) посилання для поширення цього файлу",
+ "multimediaviewer-reuse-copy-embed": "Виділіть і скопіюйте (якщо підтримується) цей код для вбудовування цього файлу",
+ "multimediaviewer-share-tab": "Поділитись",
+ "multimediaviewer-embed-tab": "Вбудований",
+ "multimediaviewer-download-link": "Завантажити цей файл",
+ "multimediaviewer-download-preview-link-title": "Переглянути в браузері",
+ "multimediaviewer-download-original-button-name": "Завантажити початковий файл",
+ "multimediaviewer-download-small-button-name": "Завантажити в малому розмірі",
+ "multimediaviewer-download-medium-button-name": "Завантажити в середньому розмірі",
+ "multimediaviewer-download-large-button-name": "Завантажити у великому розмірі",
+ "multimediaviewer-link-to-page": "Посилання на сторінку опису файлу",
+ "multimediaviewer-link-to-file": "Посилання на оригінал файлу",
+ "multimediaviewer-share-explanation": "Скопіюйте і вільно діліться посиланням",
+ "multimediaviewer-embed-wt": "Вікітекст",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Використовуйте цей код, щоб додати файл на сторінку",
+ "multimediaviewer-text-embed-credit-text-bl": "Автор: $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Автор: $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Автор: $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Автор: $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Посилання",
+ "multimediaviewer-embed-byline": "Від $1",
+ "multimediaviewer-embed-license": "Під ліцензією $1.",
+ "multimediaviewer-embed-via": "Через $1.",
+ "multimediaviewer-default-embed-dimensions": "Типовий розмір мініатюри",
+ "multimediaviewer-original-embed-dimensions": "Початковий файл $1",
+ "multimediaviewer-large-embed-dimensions": "Великий $1",
+ "multimediaviewer-medium-embed-dimensions": "Середній $1",
+ "multimediaviewer-small-embed-dimensions": "Малий $1",
+ "multimediaviewer-description-page-button-text": "Докладніше про цей файл",
+ "multimediaviewer-description-page-popup-text": "Детальніше про цей файл на $1",
+ "multimediaviewer-commons-subtitle": "Сховище вільних файлів",
+ "multimediaviewer-view-expanded": "Відкрити в Медіапереглядачі.",
+ "multimediaviewer-view-config": "Налаштування",
+ "multimediaviewer-close-popup-text": "Закрити цей інструмент (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Показати на весь екран",
+ "multimediaviewer-defullscreen-popup-text": "Вийти з повноекранного режиму",
+ "multimediaviewer-next-image-alt-text": "Показати наступне зображення",
+ "multimediaviewer-prev-image-alt-text": "Показати попереднє зображення",
+ "multimediaviewer-title-popup-text": "Опис файлу",
+ "multimediaviewer-credit-popup-text": "Інформація про автора і джерело",
+ "multimediaviewer-title-popup-text-more": "Переглянути опис файлу повністю",
+ "multimediaviewer-credit-popup-text-more": "Переглянути інформацію про автора та джерело повністю",
+ "multimediaviewer-download-attribution-cta-header": "Вам потрібно вказати автора",
+ "multimediaviewer-download-optional-attribution-cta-header": "Ви можете вказати ім'я автора",
+ "multimediaviewer-download-attribution-cta": "Показати мені, як",
+ "multimediaviewer-download-attribution-copy": "Виділіть та скопіюйте (якщо підтримується) текст атрибуції цього файлу",
+ "multimediaviewer-reuse-warning-deletion": "Цей файл номіновано на вилучення.",
+ "multimediaviewer-reuse-warning-nonfree": "Цей файл не має вільної ліцензії.",
+ "multimediaviewer-reuse-warning-noattribution": "Цей файл не має інформації про авторство.",
+ "multimediaviewer-reuse-warning-generic": "Перевірте [$1 його подробиці], перед тим як використовувати.",
+ "multimediaviewer-attr-plain": "Простий текст",
+ "multimediaviewer-options-tooltip": "Увімкнути або вимкнути Медіапереглядач",
+ "multimediaviewer-options-dialog-header": "Вимкнути Медіапереглядач?",
+ "multimediaviewer-options-text-header": "Вимкнути цю функцію перегляду для всіх файлів.",
+ "multimediaviewer-options-text-body": "Пізніше Ви зможете увімкнути її на сторінці опису файлу.",
+ "multimediaviewer-options-learn-more": "Дізнатися більше",
+ "multimediaviewer-option-submit-button": "Вимкнути Медіапереглядач",
+ "multimediaviewer-option-cancel-button": "Скасувати",
+ "multimediaviewer-disable-confirmation-header": "Ви вимкнули Медіапереглядач",
+ "multimediaviewer-disable-confirmation-text": "Наступного разу при клацанні на мініатюру файлу на сайті $1, Ви потрапите безпосередньо на сторінку опису файлу.",
+ "multimediaviewer-enable-dialog-header": "Увімкнути Медіапереглядач?",
+ "multimediaviewer-enable-text-header": "Увімкнути цю функцію перегляду для всіх медіа-файлів за замовчуванням.",
+ "multimediaviewer-enable-submit-button": "Увімкнути Медіапереглядач",
+ "multimediaviewer-enable-confirmation-header": "Ви увімкнули Медіапереглядач для всіх файлів",
+ "multimediaviewer-enable-confirmation-text": "Наступного разу при клацанні на мініатюру файлу на сайті $1, буде використано Медіапереглядач.",
+ "multimediaviewer-enable-alert": "Медіапереглядач тепер вимкнено",
+ "multimediaviewer-disable-info-title": "Ви вимкнули Медіапереглядач",
+ "multimediaviewer-disable-info": "Ви все ще можете переглядати окремі файли за допомогою Медіапереглядача.",
+ "multimediaviewer-errorreport-privacywarning": "Відомості про помилку прикріплені до звіту, який буде доступний для публічного перегляду. Якщо для Вас це незручно, Ви можете відредагувати звіт нижче та усунути всі дані, якими Ви не бажаєте ділитися."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/ur.json b/www/wiki/extensions/MultimediaViewer/i18n/ur.json
new file mode 100644
index 00000000..41965fbe
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/ur.json
@@ -0,0 +1,70 @@
+{
+ "@metadata": {
+ "authors": [
+ "عثمان خان شاہ",
+ "Muhammad Shuaib",
+ "BukhariSaeed"
+ ]
+ },
+ "multimediaviewer-pref": "میڈیا نمائش گر",
+ "multimediaviewer-optin-pref": "<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About میڈیا نمائش گر]</span> کو فعال کریں",
+ "multimediaviewer-file-page": "فائل کے متعلقہ صفحہ پر جائیں",
+ "multimediaviewer-repository-local": "مزید تفصیلات",
+ "multimediaviewer-datetime-created": "تخلیق شدہ: $1",
+ "multimediaviewer-datetime-uploaded": "اپلوڈ شدہ: $1",
+ "multimediaviewer-credit-fallback": "مصنف کی معلومات دیکھیں",
+ "multimediaviewer-multiple-authors-combine": "$1 اور $2",
+ "multimediaviewer-metadata-error": "تصویر کی تفصیلات لوڈ نہیں ہو سکیں (نقص: $1)",
+ "multimediaviewer-thumbnail-error": "معذرت، یہ فائل نہیں دکھائی جا سکتی۔",
+ "multimediaviewer-thumbnail-error-retry": "دوبارہ کوشش کریں",
+ "multimediaviewer-license-cc-pd": "دائرہ عام",
+ "multimediaviewer-license-pd": "دائرہ عام",
+ "multimediaviewer-license-default": "اجازت نامہ دیکھیں",
+ "multimediaviewer-permission-title": "اجازت نامے کی تفصیلات",
+ "multimediaviewer-permission-link": "شرائط دیکھیں",
+ "multimediaviewer-permission-link-hide": "شرائط چھپائیں",
+ "multimediaviewer-permission-viewmore": "مزید دیکھیں",
+ "multimediaviewer-about-mmv": "تعارف",
+ "multimediaviewer-discuss-mmv": "تبادلۂ خیال",
+ "multimediaviewer-help-mmv": "معاونت",
+ "multimediaviewer-optout-mmv": "میڈیا نمائش گر کو غیر فعال کريں",
+ "multimediaviewer-optin-mmv": "میڈیا نمائش گر کو فعال کريں",
+ "multimediaviewer-optout-pending-mmv": "میڈیا نمائش گر غیر فعال ہو رہا ہے",
+ "multimediaviewer-optin-pending-mmv": "میڈیا نمائش گر فعال ہو رہا ہے",
+ "multimediaviewer-geolocation": "مقام: $1",
+ "multimediaviewer-reuse-loading-placeholder": "لوڈ ہو رہا ہے۔۔۔",
+ "multimediaviewer-download-link": "اس فائل کو ڈاؤنلوڈ کریں",
+ "multimediaviewer-download-preview-link-title": "براؤزر میں کھولیں",
+ "multimediaviewer-download-original-button-name": "اصل فائل حاصل کریں",
+ "multimediaviewer-download-small-button-name": "چھوٹے حجم میں ڈاؤنلوڈ کریں",
+ "multimediaviewer-download-medium-button-name": "متوسط حجم میں ڈاؤنلوڈ کریں",
+ "multimediaviewer-download-large-button-name": "بڑے حجم میں ڈاؤنلوڈ کریں",
+ "multimediaviewer-link-to-page": "فائل کے صفحہ وضاحت کا ربط",
+ "multimediaviewer-link-to-file": "اصل فائل کا ربط",
+ "multimediaviewer-share-explanation": "ربط کو نقل اور نشر کریں",
+ "multimediaviewer-embed-wt": "ویکی متن",
+ "multimediaviewer-embed-html": "ایچ ٹی ایم ایل",
+ "multimediaviewer-text-embed-credit-text-bl": "از $1، $2، $3",
+ "multimediaviewer-text-embed-credit-text-b": "از $1، $2",
+ "multimediaviewer-html-embed-credit-text-bl": "از $1، $2، $3",
+ "multimediaviewer-html-embed-credit-text-b": "از $1، $2",
+ "multimediaviewer-embed-byline": "از $1",
+ "multimediaviewer-embed-license": "اجازت نامہ: $1",
+ "multimediaviewer-embed-via": "ماخذ: $1",
+ "multimediaviewer-description-page-button-text": "اس فائل کے متعلق مزید تفصیلات",
+ "multimediaviewer-view-expanded": "میڈیا نمائش گر میں کھولیں",
+ "multimediaviewer-title-popup-text": "وضاحت",
+ "multimediaviewer-credit-popup-text": "مصنف و ماخذ کی معلومات",
+ "multimediaviewer-title-popup-text-more": "مکمل وضاحت دیکھیں",
+ "multimediaviewer-options-tooltip": "میڈیا نمائش گر کو فعال یا غیر فعال کریں",
+ "multimediaviewer-options-dialog-header": "میڈیا نمائش گر کو غیر فعال کريں؟",
+ "multimediaviewer-options-learn-more": "مزید معلومات حاصل کریں",
+ "multimediaviewer-option-submit-button": "میڈیا نمائش گر کو غیر فعال کريں",
+ "multimediaviewer-option-cancel-button": "منسوخ",
+ "multimediaviewer-disable-confirmation-header": "آپ نے میڈیا نمائش گر کو غیر فعال کر دیا ہے",
+ "multimediaviewer-enable-dialog-header": "میڈیا نمائش گر کو فعال کريں؟",
+ "multimediaviewer-enable-submit-button": "میڈیا نمائش گر کو فعال کريں",
+ "multimediaviewer-enable-confirmation-header": "آپ نے تمام فائلوں کے لیے میڈیا نمائش گر کو فعال کر دیا ہے",
+ "multimediaviewer-enable-alert": "میڈیا نمائش گر اب غیر فعال ہوگیا ہے",
+ "multimediaviewer-disable-info-title": "آپ نے میڈیا نمائش گر کو غیر فعال کر دیا ہے"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/vi.json b/www/wiki/extensions/MultimediaViewer/i18n/vi.json
new file mode 100644
index 00000000..20ef6e42
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/vi.json
@@ -0,0 +1,138 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minh Nguyen",
+ "Withoutaname",
+ "Max20091",
+ "Macofe",
+ "Envlh"
+ ]
+ },
+ "multimediaviewer-desc": "Mở các hình nhỏ lớn hơn trong giao diện toàn màn hình.",
+ "multimediaviewer-pref": "Cửa sổ phương tiện",
+ "multimediaviewer-pref-desc": "Cải thiện trải nghiệm xem phương tiện của bạn với công cụ mới này. Nó mở rộng các hình nhỏ để phủ lên toàn cửa sổ. Các hình ảnh được hiển thị trong giao diện toàn màn hình đẹp đẽ và cũng có thể xem kích thước gốc.",
+ "multimediaviewer-optin-pref": "Bật <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About cửa sổ phương tiện]</span>",
+ "multimediaviewer-file-page": "Mở trang ứng với tập tin",
+ "multimediaviewer-repository-local": "Thêm chi tiết",
+ "multimediaviewer-datetime-created": "Ngày tạo: $1",
+ "multimediaviewer-datetime-uploaded": "Ngày tải lên: $1",
+ "multimediaviewer-credit": "$1 – $2",
+ "multimediaviewer-credit-fallback": "Xem thông tin tác giả",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|một tác giả|$1 tác giả}} nữa",
+ "multimediaviewer-multiple-authors-combine": "$1 và $2",
+ "multimediaviewer-metadata-error": "Không thể tải chi tiết hình ảnh (lỗi: $1)",
+ "multimediaviewer-thumbnail-error": "Rất tiếc, không thể hiển thị tập tin",
+ "multimediaviewer-thumbnail-error-description": "Hình như đã gặp vấn đề về kỹ thuật. Bạn có thể $1 hoặc $3 nếu tiếp tục xảy ra. Lỗi: $2",
+ "multimediaviewer-thumbnail-error-retry": "thử lại",
+ "multimediaviewer-thumbnail-error-report": "báo cáo về vấn đề",
+ "multimediaviewer-license-cc-by-4.0": "CC-BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "Phạm vi công cộng",
+ "multimediaviewer-license-cc-zero": "CC0",
+ "multimediaviewer-license-pd": "Phạm vi công cộng",
+ "multimediaviewer-license-default": "Xem giấy phép",
+ "multimediaviewer-permission-title": "Chi tiết cho phép",
+ "multimediaviewer-permission-link": "xem điều khoản",
+ "multimediaviewer-permission-link-hide": "ẩn điều khiển",
+ "multimediaviewer-permission-viewmore": "Xem thêm",
+ "multimediaviewer-restriction-2257": "Hình ảnh này có nội dung khiêu dâm có thể được Đạo luật Bảo vệ Trẻ em và Ép buộc Điều lệ Tục tĩu (Child Protection and Obscenity Enforcement Act) kiểm soát tại Hoa Kỳ.",
+ "multimediaviewer-restriction-aus-reserve": "Hình ảnh này được chụp tại một khu bảo tồn của Thịnh vượng chung Úc, nên phải có giấy cấp phép để sử dụng nó với mục đích thương mại.",
+ "multimediaviewer-restriction-communist": "Hình ảnh này có dấu cộng sản có thể bị cấm tại một số quốc gia.",
+ "multimediaviewer-restriction-costume": "Hình ảnh này có người cải trang nên có thể được kiểm soát bằng pháp luật.",
+ "multimediaviewer-restriction-currency": "Hình ảnh này có tiền tệ nên có thể được kiểm soát bằng pháp luật.",
+ "multimediaviewer-restriction-design": "Thiết kế của chủ đề hình ảnh này có thể dưới bản quyền và được kiểm soát bằng pháp luật.",
+ "multimediaviewer-restriction-fan-art": "Hình ảnh này là do người hâm mộ tạo ra, nên sự tái sử dụng có thể được kiểm soát bằng pháp luật.",
+ "multimediaviewer-restriction-ihl": "Hình ảnh này có ký hiệu được kiểm soát bởi Luật Nhân đạo Quốc tế.",
+ "multimediaviewer-restriction-insignia": "Hình ảnh này có huy hiệu chính thức có thể được kiểm soát bằng pháp luật.",
+ "multimediaviewer-restriction-ita-mibac": "Hình ảnh này sao lại di sản văn hóa Ý và được kiểm soát bởi luật Ý.",
+ "multimediaviewer-restriction-nazi": "Hình ảnh này có dấu Quốc xã hoặc phát xít có thể bị cấm tại một số quốc gia.",
+ "multimediaviewer-restriction-personality": "Những người trong hình này có thể có quyền hạn chế việc tái sử dụng hình này mà không được cấp phép.",
+ "multimediaviewer-restriction-trademarked": "Công trình này có chứa tư liệu có thể là đối tượng của luật thương hiệu theo một hoặc một số bộ luật.",
+ "multimediaviewer-restriction-default": "Hình ảnh này có thể được kiểm soát bởi những điều khoản luật pháp ngoài luật quyền tác giả. Xem chi tiết tại trang miêu tả tập tin.",
+ "multimediaviewer-restriction-default-and-others": "Hình ảnh này có thể được kiểm soát thêm bởi những điều khoản luật pháp ngoài luật quyền tác giả. Xem chi tiết tại trang miêu tả tập tin.",
+ "multimediaviewer-about-mmv": "Giới thiệu",
+ "multimediaviewer-discuss-mmv": "Thảo luận",
+ "multimediaviewer-help-mmv": "Trợ giúp",
+ "multimediaviewer-optout-mmv": "Tắt cửa sổ phương tiện",
+ "multimediaviewer-optin-mmv": "Bật cửa sổ phương tiện",
+ "multimediaviewer-optout-pending-mmv": "Tắt cửa sổ phương tiện",
+ "multimediaviewer-optin-pending-mmv": "Bật cửa sổ phương tiện",
+ "multimediaviewer-optout-help": "Các hình ảnh sẽ không còn mở rộng trong cửa sổ phương tiện. Để lại sử dụng cửa sổ này, hãy bấm nút “{{int:multimediaviewer-view-expanded}}” bên cạnh hình ảnh nào đó, rồi bấm “{{int:multimediaviewer-optin-mmv}}”.",
+ "multimediaviewer-optin-help": "Các hình ảnh sẽ mở rộng trong cửa sổ phương tiện.",
+ "multimediaviewer-geoloc-north": "B",
+ "multimediaviewer-geoloc-east": "Đ",
+ "multimediaviewer-geoloc-south": "N",
+ "multimediaviewer-geoloc-west": "T",
+ "multimediaviewer-geoloc-coord": "$1°$2′$3″$4",
+ "multimediaviewer-geolocation": "Vị trí: $1",
+ "multimediaviewer-reuse-link": "Chia sẻ hoặc nhúng tập tin này",
+ "multimediaviewer-reuse-loading-placeholder": "Đang tải…",
+ "multimediaviewer-reuse-copy-share": "Chọn và sao chép (nếu được hỗ trợ) liên kết để chia sẻ tập tin này",
+ "multimediaviewer-reuse-copy-embed": "Chọn và sao chép (nếu được hỗ trợ) đoạn mã để nhúng tập tin này",
+ "multimediaviewer-share-tab": "Chia sẻ",
+ "multimediaviewer-embed-tab": "Nhúng",
+ "multimediaviewer-download-link": "Tải về tập tin này",
+ "multimediaviewer-download-preview-link-title": "Xem trong trình duyệt",
+ "multimediaviewer-download-original-button-name": "Tải về tập tin gốc",
+ "multimediaviewer-download-small-button-name": "Tải về hình nhỏ",
+ "multimediaviewer-download-medium-button-name": "Tải về hình vừa",
+ "multimediaviewer-download-large-button-name": "Tải về hình lớn",
+ "multimediaviewer-link-to-page": "Liên kết đến trang miêu tả",
+ "multimediaviewer-link-to-file": "Liên kết đến tập tin gốc",
+ "multimediaviewer-share-explanation": "Sao chép và thoải mái chia sẻ liên kết này",
+ "multimediaviewer-embed-wt": "Mã wiki",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "Nhúng tập tin bằng đoạn mã này",
+ "multimediaviewer-text-embed-credit-text-bl": "Bởi $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "Bởi $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "Bởi $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "Bởi $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "Liên kết",
+ "multimediaviewer-embed-byline": "Bởi $1",
+ "multimediaviewer-embed-license": "Phát hành theo giấy phép $1.",
+ "multimediaviewer-embed-via": "Do $1 cung cấp.",
+ "multimediaviewer-default-embed-dimensions": "Kích thước hình nhỏ mặc định",
+ "multimediaviewer-original-embed-dimensions": "Tập tin gốc $1",
+ "multimediaviewer-large-embed-dimensions": "Lớn $1",
+ "multimediaviewer-medium-embed-dimensions": "Vừa $1",
+ "multimediaviewer-small-embed-dimensions": "Nhỏ $1",
+ "multimediaviewer-embed-dimensions": "$1×$2 điểm ảnh",
+ "multimediaviewer-embed-dimensions-separated": "– $1",
+ "multimediaviewer-description-page-button-text": "Thêm chi tiết về tập tin này",
+ "multimediaviewer-description-page-popup-text": "Thêm chi tiết về tập tin này tại $1",
+ "multimediaviewer-commons-subtitle": "Kho tư liệu mở",
+ "multimediaviewer-view-expanded": "Mở trong cửa sổ phương tiện",
+ "multimediaviewer-view-config": "Cấu hình",
+ "multimediaviewer-close-popup-text": "Đóng cửa sổ này (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "Xem toàn màn hình",
+ "multimediaviewer-defullscreen-popup-text": "Thoát ra toàn màn hình",
+ "multimediaviewer-next-image-alt-text": "Xem hình sau",
+ "multimediaviewer-prev-image-alt-text": "Xem hình trước",
+ "multimediaviewer-title-popup-text": "Miêu tả",
+ "multimediaviewer-credit-popup-text": "Thông tin tác giả và nguồn gốc",
+ "multimediaviewer-title-popup-text-more": "Xem miêu tả đầy đủ",
+ "multimediaviewer-credit-popup-text-more": "Xem tác giả và nguồn gốc đầy đủ",
+ "multimediaviewer-download-attribution-cta-header": "Bạn cần phải ghi công tác giả",
+ "multimediaviewer-download-optional-attribution-cta-header": "Bạn có thể ghi công tác giả",
+ "multimediaviewer-download-attribution-cta": "Chỉ tôi làm thế nào",
+ "multimediaviewer-download-attribution-copy": "Chọn và sao chép (nếu được hỗ trợ) văn bản ghi công của tập tin này",
+ "multimediaviewer-attr-plain": "Văn bản thuần",
+ "multimediaviewer-options-tooltip": "Bật/tắt cửa sổ phương tiện",
+ "multimediaviewer-options-dialog-header": "Tắt cửa sổ phương tiện?",
+ "multimediaviewer-options-text-header": "Bỏ qua cửa sổ phương tiện cho tất cả các tập tin.",
+ "multimediaviewer-options-text-body": "Bạn có thể bật nó lên về sau trong trang miêu tả tập tin.",
+ "multimediaviewer-options-learn-more": "Tìm hiểu thêm",
+ "multimediaviewer-option-submit-button": "Tắt cửa sổ phương tiện",
+ "multimediaviewer-option-cancel-button": "Hủy bỏ",
+ "multimediaviewer-disable-confirmation-header": "Bạn đã tắt cửa sổ phương tiện",
+ "multimediaviewer-disable-confirmation-text": "Lần sau khi bạn nhấn chuột vào một hình nhỏ trên $1, bạn sẽ được dẫn trực tiếp đến trang có tất cả các chi tiết của tập tin.",
+ "multimediaviewer-enable-dialog-header": "Bật cửa sổ phương tiện?",
+ "multimediaviewer-enable-text-header": "Xem tất cả các tập tin trong cửa sổ phương tiện theo mặc định.",
+ "multimediaviewer-enable-submit-button": "Bật cửa sổ phương tiện",
+ "multimediaviewer-enable-confirmation-header": "Bạn đã bật lên cửa sổ phương tiện cho tất cả các tập tin",
+ "multimediaviewer-enable-confirmation-text": "Lần sau khi bạn nhấn chuột vào một hình nhỏ trên $1, nó sẽ xuất hiện trong cửa sổ phương tiện.",
+ "multimediaviewer-enable-alert": "Cửa sổ phương tiện đã tắt",
+ "multimediaviewer-disable-info-title": "Đã tắt cửa sổ phương tiện",
+ "multimediaviewer-disable-info": "Bạn vẫn có thể xem tập tin riêng trong cửa sổ phương tiện.",
+ "multimediaviewer-errorreport-privacywarning": "Các chi tiết lỗi được đính kèm vào bản báo cáo công khai. Nếu bạn không đồng ý với điều này, bạn có thể sửa đổi bản báo cáo bên dưới và xóa tất cả dữ liệu mà bạn không muốn chia sẻ."
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/vo.json b/www/wiki/extensions/MultimediaViewer/i18n/vo.json
new file mode 100644
index 00000000..2b6f9f91
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/vo.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya"
+ ]
+ },
+ "multimediaviewer-datetime-created": "Pejafon tü $1",
+ "multimediaviewer-datetime-uploaded": "Pelöpükon tü $1"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/wa.json b/www/wiki/extensions/MultimediaViewer/i18n/wa.json
new file mode 100644
index 00000000..fa15af7a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/wa.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Srtxg"
+ ]
+ },
+ "multimediaviewer-optin-pref": "Mete en alaedje li <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About håyneu di medias]</span>"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/yi.json b/www/wiki/extensions/MultimediaViewer/i18n/yi.json
new file mode 100644
index 00000000..439a77ba
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/yi.json
@@ -0,0 +1,55 @@
+{
+ "@metadata": {
+ "authors": [
+ "פוילישער",
+ "Har-wradim"
+ ]
+ },
+ "multimediaviewer-pref": "מעדיע־ווייזער",
+ "multimediaviewer-repository-local": "מער פּרטים",
+ "multimediaviewer-datetime-created": "געשאפן: $1",
+ "multimediaviewer-datetime-uploaded": "ארויפגעלאדן: $1",
+ "multimediaviewer-credit-fallback": "באקוקן שאפֿער אינפארמאציע",
+ "multimediaviewer-multiple-authors": "נאך {{PLURAL:$1|איין|$1}} שאפער",
+ "multimediaviewer-multiple-authors-combine": "$1 און $2",
+ "multimediaviewer-thumbnail-error": "אנטשולדיקט, מען קען נישט ווייזן די טעקע",
+ "multimediaviewer-thumbnail-error-description": "עס זעט אויס אז ס׳איז פֿאראן א טעכנישער פראבלעם. איר קענט $1 אדער $3 טאמער עס האלט זיך אן ווייטער. פֿעלער: $2",
+ "multimediaviewer-thumbnail-error-retry": "פרובירן ווידער",
+ "multimediaviewer-thumbnail-error-report": "מעלדן דעם פראבלעם",
+ "multimediaviewer-license-default": "באקוקן ליצענץ",
+ "multimediaviewer-permission-title": "ערלויבניש פרטים",
+ "multimediaviewer-permission-link": "באקוקן טערמינען",
+ "multimediaviewer-permission-link-hide": "באהאלטן באדינגונגען",
+ "multimediaviewer-permission-viewmore": "ווײזן נאך",
+ "multimediaviewer-about-mmv": "וועגן",
+ "multimediaviewer-discuss-mmv": "שמועס",
+ "multimediaviewer-help-mmv": "הילף",
+ "multimediaviewer-optin-mmv": "אקטיווירן מעדיע־ווייזער",
+ "multimediaviewer-optin-help": "מען וועט ניצן מעדיע־באקוקער צו ווײַזן בילדער.",
+ "multimediaviewer-geolocation": "לאקאציע: $1",
+ "multimediaviewer-reuse-loading-placeholder": "לאָדנדיק…",
+ "multimediaviewer-share-tab": "טיילן",
+ "multimediaviewer-download-link": "אַראָפלאָדן די טעקע",
+ "multimediaviewer-download-preview-link-title": "באקוקן אין בלעטערער",
+ "multimediaviewer-download-original-button-name": "אַראָפלאָדן אריגינעלע טעקע",
+ "multimediaviewer-embed-wt": "וויקיטעקסט",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-text-embed-credit-text-bl": "פון $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "פון $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "פון $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "פון $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "לינק",
+ "multimediaviewer-embed-byline": "פֿון $1",
+ "multimediaviewer-embed-license": "ליצענצירט אונטער $1.",
+ "multimediaviewer-embed-via": "דורך $1.",
+ "multimediaviewer-large-embed-dimensions": "גרויס $1",
+ "multimediaviewer-medium-embed-dimensions": "מיטל $1",
+ "multimediaviewer-small-embed-dimensions": "קליין $1",
+ "multimediaviewer-description-page-button-text": "נאך פרטים וועגן דער טעקטע",
+ "multimediaviewer-view-expanded": "עפֿענען אין מעדיע־ווייזער",
+ "multimediaviewer-view-config": "קאנפֿיגוראציע",
+ "multimediaviewer-title-popup-text": "באַשרײבונג",
+ "multimediaviewer-download-attribution-cta": "ווײַז מיך וויאזוי",
+ "multimediaviewer-attr-plain": "קלארטעקסט",
+ "multimediaviewer-option-cancel-button": "אַנולירן"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/zh-hans.json b/www/wiki/extensions/MultimediaViewer/i18n/zh-hans.json
new file mode 100644
index 00000000..0f7fcf46
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/zh-hans.json
@@ -0,0 +1,159 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liuxinyu970226",
+ "Qiyue2001",
+ "Shizhao",
+ "Stieizc",
+ "Xiaomingyan",
+ "Yfdyh000",
+ "Hudafu",
+ "Cwek",
+ "Duolaimi",
+ "NigelSoft",
+ "Liangent",
+ "Papapasan",
+ "Linforest",
+ "Hydra",
+ "飞舞回堂前"
+ ]
+ },
+ "multimediaviewer-desc": "在全屏界面中以较大尺寸显示缩略图。",
+ "multimediaviewer-pref": "媒体查看器",
+ "multimediaviewer-pref-desc": "使用这个新工具改善您的多媒体浏览体验。它能以更大的尺寸显示页面中的缩略图。图像将显示于一个漂亮的全屏界面浮层中,并能以完整尺寸查看。",
+ "multimediaviewer-optin-pref": "启用<span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About 媒体查看器]</span>",
+ "multimediaviewer-file-page": "前往对应的文件页面",
+ "multimediaviewer-repository-local": "更多详情",
+ "multimediaviewer-datetime-created": "创建于:$1",
+ "multimediaviewer-datetime-uploaded": "上传于:$1",
+ "multimediaviewer-credit-fallback": "查看作者信息",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|$1位更多作者}}",
+ "multimediaviewer-multiple-authors-combine": "$1和$2",
+ "multimediaviewer-metadata-error": "无法加载图片的详细信息(错误:$1)",
+ "multimediaviewer-thumbnail-error": "抱歉,文件无法显示",
+ "multimediaviewer-thumbnail-error-description": "看起来发生了技术问题。您可以$1,或如果仍然发生,可$3。错误:$2",
+ "multimediaviewer-thumbnail-error-retry": "重试",
+ "multimediaviewer-thumbnail-error-report": "报告问题",
+ "multimediaviewer-license-cc-by-1.0": "CC BY 1.0",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-2.0": "CC BY 2.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-2.1": "CC BY 2.1",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-2.5": "CC BY 2.5",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-3.0": "CC BY 3.0",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-4.0": "CC BY 4.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "公有领域",
+ "multimediaviewer-license-pd": "公有领域",
+ "multimediaviewer-license-default": "查看许可协议",
+ "multimediaviewer-permission-title": "许可协议详情",
+ "multimediaviewer-permission-link": "查看条款",
+ "multimediaviewer-permission-link-hide": "隐藏条款",
+ "multimediaviewer-permission-viewmore": "查看更多",
+ "multimediaviewer-restriction-2257": "此图片包含色情内容,它可能受美国Child Protection and Obscenity Enforcement Act法律的管制。",
+ "multimediaviewer-restriction-aus-reserve": "此图片是在澳大利亚联邦储备机构中拍摄的,并因此在未获许可的情况下不能用于商业性使用。",
+ "multimediaviewer-restriction-communist": "此图片包含共产主义标志,它可能被一些国家禁止使用。",
+ "multimediaviewer-restriction-costume": "此图片描述服装,并可能受法律限制。",
+ "multimediaviewer-restriction-currency": "此图片表现了对货币单位的描述,并可能受法律限制。",
+ "multimediaviewer-restriction-design": "此图片主题的设计可能受到版权保护,并受法律限制。",
+ "multimediaviewer-restriction-fan-art": "此图片是一件爱好者作品,并在再利用时可能受到法律限制。",
+ "multimediaviewer-restriction-ihl": "此图片包含受国际人道主义法限制的符号。",
+ "multimediaviewer-restriction-insignia": "此图片包含官方标志,并可能受法律限制。",
+ "multimediaviewer-restriction-ita-mibac": "此图片再现了意大利文化遗产,并受意大利法律限制。",
+ "multimediaviewer-restriction-nazi": "此图片包含纳粹或其他法西斯标志,它可能被一些国家禁止使用。",
+ "multimediaviewer-restriction-personality": "此图片包含人物,可能有合法权利限制未经许可的图片再利用。",
+ "multimediaviewer-restriction-trademarked": "此图片包含受商标法管理的内容。",
+ "multimediaviewer-restriction-default": "此图片可能受版权法以外的法律法规限制。请参见文件说明页面以获取详细信息。",
+ "multimediaviewer-restriction-default-and-others": "此图片可能受版权法以外的其他法律法规的进一步限制。请参见文件说明页面以获取详细信息。",
+ "multimediaviewer-about-mmv": "关于",
+ "multimediaviewer-discuss-mmv": "讨论",
+ "multimediaviewer-help-mmv": "帮助",
+ "multimediaviewer-optout-mmv": "停用媒体查看器",
+ "multimediaviewer-optin-mmv": "启用媒体查看器",
+ "multimediaviewer-optout-pending-mmv": "正在停用媒体查看器",
+ "multimediaviewer-optin-pending-mmv": "正在启用媒体查看器",
+ "multimediaviewer-optout-help": "媒体查看器将不再用于展示图像。要再次使用,请点击任意图像旁的“{{int:multimediaviewer-view-expanded}}”按钮,然后点击“{{int:multimediaviewer-optin-mmv}}”。",
+ "multimediaviewer-optin-help": "媒体查看器将会用于展示图像。",
+ "multimediaviewer-geoloc-north": "N",
+ "multimediaviewer-geoloc-east": "E",
+ "multimediaviewer-geoloc-south": "S",
+ "multimediaviewer-geoloc-west": "W",
+ "multimediaviewer-geolocation": "位置:$1",
+ "multimediaviewer-reuse-link": "分享或嵌入该文件",
+ "multimediaviewer-reuse-loading-placeholder": "正在载入…",
+ "multimediaviewer-reuse-copy-share": "选择并复制(如果支持)链接以分享该文件",
+ "multimediaviewer-reuse-copy-embed": "选择并复制(如果支持)代码以嵌入该文件",
+ "multimediaviewer-share-tab": "分享",
+ "multimediaviewer-embed-tab": "嵌入",
+ "multimediaviewer-download-link": "下载此文件",
+ "multimediaviewer-download-preview-link-title": "在浏览器中预览",
+ "multimediaviewer-download-original-button-name": "下载原始文件",
+ "multimediaviewer-download-small-button-name": "下载小尺寸",
+ "multimediaviewer-download-medium-button-name": "下载中等尺寸",
+ "multimediaviewer-download-large-button-name": "下载大尺寸",
+ "multimediaviewer-link-to-page": "文件说明页面的链接",
+ "multimediaviewer-link-to-file": "原始文件的链接",
+ "multimediaviewer-share-explanation": "复制并自由分享本链接",
+ "multimediaviewer-embed-wt": "Wiki文本",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "使用这些代码嵌入该文件",
+ "multimediaviewer-text-embed-credit-text-bl": "由$1,$2,$3",
+ "multimediaviewer-text-embed-credit-text-b": "由$1,$2",
+ "multimediaviewer-html-embed-credit-text-bl": "由$1,$2,$3",
+ "multimediaviewer-html-embed-credit-text-b": "由$1,$2",
+ "multimediaviewer-html-embed-credit-link-text": "链接",
+ "multimediaviewer-embed-byline": "作者$1",
+ "multimediaviewer-embed-license": "采用$1授权。",
+ "multimediaviewer-embed-via": "来自$1。",
+ "multimediaviewer-default-embed-dimensions": "默认缩略图尺寸",
+ "multimediaviewer-original-embed-dimensions": "原始文件$1",
+ "multimediaviewer-large-embed-dimensions": "大 $1",
+ "multimediaviewer-medium-embed-dimensions": "中 $1",
+ "multimediaviewer-small-embed-dimensions": "小 $1",
+ "multimediaviewer-embed-dimensions": "$1 × $2 像素",
+ "multimediaviewer-embed-dimensions-separated": "- $1",
+ "multimediaviewer-description-page-button-text": "更多关于此文件的详情",
+ "multimediaviewer-description-page-popup-text": "在$1了解该文件详情",
+ "multimediaviewer-commons-subtitle": "自由的媒体存储库",
+ "multimediaviewer-view-expanded": "在媒体查看器中打开",
+ "multimediaviewer-view-config": "配置",
+ "multimediaviewer-close-popup-text": "关闭此工具(或按“Esc”键退出)",
+ "multimediaviewer-fullscreen-popup-text": "全屏显示",
+ "multimediaviewer-defullscreen-popup-text": "退出全屏",
+ "multimediaviewer-next-image-alt-text": "显示下一张图片",
+ "multimediaviewer-prev-image-alt-text": "显示上一张图片",
+ "multimediaviewer-title-popup-text": "说明",
+ "multimediaviewer-credit-popup-text": "作者和来源信息",
+ "multimediaviewer-title-popup-text-more": "显示完整说明",
+ "multimediaviewer-credit-popup-text-more": "显示完整的作者和来源",
+ "multimediaviewer-download-attribution-cta-header": "您需要为作者署名",
+ "multimediaviewer-download-optional-attribution-cta-header": "您可以为作者署名",
+ "multimediaviewer-download-attribution-cta": "告诉我如何",
+ "multimediaviewer-download-attribution-copy": "选择并复制(如果支持)此文件的署名文本",
+ "multimediaviewer-reuse-warning-deletion": "文件被标记提删。",
+ "multimediaviewer-reuse-warning-nonfree": "文件没有自由许可协议。",
+ "multimediaviewer-reuse-warning-noattribution": "文件没有署名信息。",
+ "multimediaviewer-reuse-warning-generic": "在使用前请检查[$1 详情]。",
+ "multimediaviewer-attr-plain": "无格式",
+ "multimediaviewer-options-tooltip": "启用或禁用媒体查看器",
+ "multimediaviewer-options-dialog-header": "禁用媒体查看器?",
+ "multimediaviewer-options-text-header": "对所有文件跳过查看功能",
+ "multimediaviewer-options-text-body": "您可以稍后通过文件详细说明页面启用它。",
+ "multimediaviewer-options-learn-more": "了解更多",
+ "multimediaviewer-option-submit-button": "禁用媒体查看器",
+ "multimediaviewer-option-cancel-button": "取消",
+ "multimediaviewer-disable-confirmation-header": "您已禁用媒体查看器",
+ "multimediaviewer-disable-confirmation-text": "下一次在您点击$1上的缩略图时,您将直接查看文件的详细信息。",
+ "multimediaviewer-enable-dialog-header": "启用媒体查看器?",
+ "multimediaviewer-enable-text-header": "默认对所有文件启用此媒体查看功能。",
+ "multimediaviewer-enable-submit-button": "启用媒体查看器",
+ "multimediaviewer-enable-confirmation-header": "您已对所有文件启用媒体查看器",
+ "multimediaviewer-enable-confirmation-text": "下次当您在$1点击一个缩略图时,媒体查看器将被使用。",
+ "multimediaviewer-enable-alert": "媒体查看器已禁用",
+ "multimediaviewer-disable-info-title": "您已禁用媒体查看器",
+ "multimediaviewer-disable-info": "您仍可通过媒体查看器查看个别文件。",
+ "multimediaviewer-errorreport-privacywarning": "错误的详细信息已附加于报告中,它将公开可见。如果您对此感到不适,您可以编辑下方的报告并移除所有您不希望分享的数据。"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/i18n/zh-hant.json b/www/wiki/extensions/MultimediaViewer/i18n/zh-hant.json
new file mode 100644
index 00000000..8a0a122c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/i18n/zh-hant.json
@@ -0,0 +1,116 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liuxinyu970226",
+ "Simon Shek",
+ "Liangent",
+ "Cwlin0416",
+ "LNDDYL",
+ "Alexsh"
+ ]
+ },
+ "multimediaviewer-desc": "使用全螢幕介面以較大尺寸的方式顯示展開後的縮圖。",
+ "multimediaviewer-pref": "媒體檢視器",
+ "multimediaviewer-pref-desc": "這個新的工具可以改善您的多媒體瀏覽體驗。它會在有縮圖的網頁中以更大的尺寸顯示影像;影像將以浮動視窗呈現,您也可以選擇檢視原始大小的圖片。",
+ "multimediaviewer-optin-pref": "開啟 <span class=\"plainlinks\">[https://www.mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About 媒體檢視器]</span>",
+ "multimediaviewer-file-page": "前往相關的檔案頁面",
+ "multimediaviewer-repository-local": "更多詳細資料",
+ "multimediaviewer-datetime-created": "建立於:$1",
+ "multimediaviewer-datetime-uploaded": "上傳於:$1",
+ "multimediaviewer-credit-fallback": "檢視作者資訊",
+ "multimediaviewer-multiple-authors": "{{PLURAL:$1|還有 1 位作者|還有 $1 位作者}}",
+ "multimediaviewer-multiple-authors-combine": "$1 及 $2",
+ "multimediaviewer-metadata-error": "無法讀取圖片資料 (錯誤:$1)",
+ "multimediaviewer-thumbnail-error": "抱歉,檔案無法正常顯示",
+ "multimediaviewer-thumbnail-error-description": "似乎發生技術性問題,您可以 $1,若問題仍然存在,可 $3。錯誤:$2",
+ "multimediaviewer-thumbnail-error-retry": "重試",
+ "multimediaviewer-thumbnail-error-report": "回報問題",
+ "multimediaviewer-license-cc-by-sa-1.0": "CC BY-SA 1.0",
+ "multimediaviewer-license-cc-by-sa-2.0": "CC BY-SA 2.0",
+ "multimediaviewer-license-cc-by-sa-2.1": "CC BY-SA 2.1",
+ "multimediaviewer-license-cc-by-sa-2.5": "CC BY-SA 2.5",
+ "multimediaviewer-license-cc-by-sa-3.0": "CC BY-SA 3.0",
+ "multimediaviewer-license-cc-by-sa-4.0": "CC BY-SA 4.0",
+ "multimediaviewer-license-cc-pd": "公有領域",
+ "multimediaviewer-license-pd": "公有領域",
+ "multimediaviewer-license-default": "檢視授權條款",
+ "multimediaviewer-permission-title": "權限詳細資料",
+ "multimediaviewer-permission-link": "檢視條款",
+ "multimediaviewer-permission-link-hide": "隱藏條款",
+ "multimediaviewer-permission-viewmore": "檢視更多",
+ "multimediaviewer-about-mmv": "關於",
+ "multimediaviewer-discuss-mmv": "討論",
+ "multimediaviewer-help-mmv": "說明",
+ "multimediaviewer-optout-mmv": "停用媒體檢視器",
+ "multimediaviewer-optin-mmv": "開啟媒體檢視器",
+ "multimediaviewer-optout-pending-mmv": "正在停用媒體檢視器",
+ "multimediaviewer-optin-pending-mmv": "正在開啟媒體檢視器",
+ "multimediaviewer-optout-help": "將不再使用媒體檢視器來顯示圖片。 若要再使用媒體檢視器,請點選圖片旁的 \"{{int:multimediaviewer-view-expanded}}\" 按鈕,然後再點選 \"{{int:multimediaviewer-optin-mmv}}\"。",
+ "multimediaviewer-optin-help": "將使用媒體檢視器來顯示圖片。",
+ "multimediaviewer-geolocation": "位置:$1",
+ "multimediaviewer-reuse-link": "分享或內嵌此檔案",
+ "multimediaviewer-reuse-loading-placeholder": "讀取中…",
+ "multimediaviewer-share-tab": "分享",
+ "multimediaviewer-embed-tab": "內嵌",
+ "multimediaviewer-download-link": "下載此檔案",
+ "multimediaviewer-download-preview-link-title": "在瀏覽器中檢視",
+ "multimediaviewer-download-original-button-name": "下載原始檔案",
+ "multimediaviewer-download-small-button-name": "下載小型尺寸",
+ "multimediaviewer-download-medium-button-name": "下載中型尺寸",
+ "multimediaviewer-download-large-button-name": "下載大型尺寸",
+ "multimediaviewer-link-to-page": "連結至檔案描述頁面",
+ "multimediaviewer-link-to-file": "連結至原始檔案",
+ "multimediaviewer-share-explanation": "複製並自由的分享該連結",
+ "multimediaviewer-embed-wt": "Wikitext",
+ "multimediaviewer-embed-html": "HTML",
+ "multimediaviewer-embed-explanation": "使用此程式碼內嵌該檔案",
+ "multimediaviewer-text-embed-credit-text-bl": "由 $1, $2, $3",
+ "multimediaviewer-text-embed-credit-text-b": "由 $1, $2",
+ "multimediaviewer-html-embed-credit-text-bl": "由 $1, $2, $3",
+ "multimediaviewer-html-embed-credit-text-b": "由 $1, $2",
+ "multimediaviewer-html-embed-credit-link-text": "連結",
+ "multimediaviewer-embed-byline": "由 $1",
+ "multimediaviewer-embed-license": "使用 $1 條款授權。",
+ "multimediaviewer-embed-via": "來自 $1。",
+ "multimediaviewer-default-embed-dimensions": "預設縮圖大小",
+ "multimediaviewer-original-embed-dimensions": "原始檔案 $1",
+ "multimediaviewer-large-embed-dimensions": "大型 $1",
+ "multimediaviewer-medium-embed-dimensions": "中型 $1",
+ "multimediaviewer-small-embed-dimensions": "小型 $1",
+ "multimediaviewer-description-page-button-text": "更多有關此檔案的詳細資料",
+ "multimediaviewer-description-page-popup-text": "更多 $1 上有關此檔案的詳細資料",
+ "multimediaviewer-commons-subtitle": "自由的媒體存儲庫",
+ "multimediaviewer-view-expanded": "使用媒體檢視器開啟",
+ "multimediaviewer-view-config": "設定",
+ "multimediaviewer-close-popup-text": "關閉此工具 (Esc)",
+ "multimediaviewer-fullscreen-popup-text": "全螢幕顯示",
+ "multimediaviewer-defullscreen-popup-text": "退出全螢幕",
+ "multimediaviewer-next-image-alt-text": "顯示下張圖片",
+ "multimediaviewer-prev-image-alt-text": "顯示上張圖片",
+ "multimediaviewer-title-popup-text": "描述說明",
+ "multimediaviewer-credit-popup-text": "作者與來源資訊",
+ "multimediaviewer-title-popup-text-more": "點選以顯示完整描述說明",
+ "multimediaviewer-credit-popup-text-more": "檢視完整作者與來源",
+ "multimediaviewer-download-attribution-cta-header": "您需要註明作者",
+ "multimediaviewer-download-optional-attribution-cta-header": "您可以註明作者",
+ "multimediaviewer-download-attribution-cta": "教我怎麼做",
+ "multimediaviewer-download-attribution-copy": "選擇並複製 (若支援) 此檔案的署名文字",
+ "multimediaviewer-attr-plain": "純文字",
+ "multimediaviewer-options-tooltip": "開啟或關閉媒體檢視器",
+ "multimediaviewer-options-dialog-header": "關閉媒體檢視器?",
+ "multimediaviewer-options-text-header": "對所有檔案略過此檢視功能。",
+ "multimediaviewer-options-text-body": "您可稍後在檔案明細頁面開啟。",
+ "multimediaviewer-options-learn-more": "瞭解更多",
+ "multimediaviewer-option-submit-button": "關閉媒體檢視器",
+ "multimediaviewer-option-cancel-button": "取消",
+ "multimediaviewer-disable-confirmation-header": "您已關閉媒體檢視器",
+ "multimediaviewer-disable-confirmation-text": "下次您點選 $1 上的縮圖時,您會直接檢視所有檔案明細。",
+ "multimediaviewer-enable-dialog-header": "開啟媒體檢視器?",
+ "multimediaviewer-enable-text-header": "預設對所有檔案開啟此媒體檢視功能。",
+ "multimediaviewer-enable-submit-button": "開啟媒體檢視器",
+ "multimediaviewer-enable-confirmation-header": "您已對所有檔案開啟媒體檢視器",
+ "multimediaviewer-enable-confirmation-text": "下次您點選 $1 上的縮圖時,會使用媒體檢視器。",
+ "multimediaviewer-enable-alert": "媒體檢視器現在已關閉",
+ "multimediaviewer-disable-info-title": "您已關閉媒體檢視器",
+ "multimediaviewer-disable-info": "您仍可以使用媒體檢視器來檢視個別檔案。"
+}
diff --git a/www/wiki/extensions/MultimediaViewer/importml.sh b/www/wiki/extensions/MultimediaViewer/importml.sh
new file mode 100755
index 00000000..148b5907
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/importml.sh
@@ -0,0 +1,25 @@
+#!/usr/bin/env bash
+
+if [ $1 = "--reverse" ]; then
+ MLDIR=$2
+else
+ MLDIR=$1
+fi
+
+JSDIR=$MLDIR/lib
+CSSDIR=$MLDIR/css
+IMGDIR=$MLDIR/img
+HOOKSFILE=$MLDIR/hooks.txt
+LOCALMLDIR=resources/multilightbox
+
+if [ $1 = "--reverse" ]; then
+ cp $LOCALMLDIR/*.js $JSDIR
+ cp $LOCALMLDIR/multilightbox.css $CSSDIR
+ cp img/close.svg img/fullscreen.svg img/defullscreen.svg $IMGDIR
+ cp $LOCALMLDIR/hooks.txt $HOOKSFILE
+else
+ cp $JSDIR/* resources/multilightbox/
+ cp $CSSDIR/* resources/multilightbox/
+ cp $IMGDIR/* img/
+ cp $HOOKSFILE resources/multilightbox/
+fi
diff --git a/www/wiki/extensions/MultimediaViewer/includes/MultimediaViewerHooks.php b/www/wiki/extensions/MultimediaViewer/includes/MultimediaViewerHooks.php
new file mode 100644
index 00000000..80a18816
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/includes/MultimediaViewerHooks.php
@@ -0,0 +1,349 @@
+<?php
+/**
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * @file
+ * @ingroup extensions
+ * @author Mark Holmquist <mtraceur@member.fsf.org>
+ * @copyright Copyright © 2013, Mark Holmquist
+ */
+
+class MultimediaViewerHooks {
+ /** Link to more information about this module */
+ protected static $infoLink =
+ 'https://mediawiki.org/wiki/Special:MyLanguage/Extension:Media_Viewer/About';
+
+ /** Link to a page where this module can be discussed */
+ protected static $discussionLink =
+ 'https://mediawiki.org/wiki/Special:MyLanguage/Extension_talk:Media_Viewer/About';
+
+ /** Link to help about this module */
+ protected static $helpLink =
+ 'https://mediawiki.org/wiki/Special:MyLanguage/Help:Extension:Media_Viewer';
+
+ public static function onUserGetDefaultOptions( &$defaultOptions ) {
+ global $wgMediaViewerEnableByDefault;
+
+ if ( $wgMediaViewerEnableByDefault ) {
+ $defaultOptions['multimediaviewer-enable'] = 1;
+ }
+
+ return true;
+ }
+
+ public static function onExtensionFunctions() {
+ global $wgResourceModules;
+
+ if ( isset( $wgResourceModules['ext.eventLogging'] ) ) {
+ $wgResourceModules['mmv.lightboxinterface']['dependencies'][] = 'ext.eventLogging';
+ $wgResourceModules['mmv']['dependencies'][] = 'ext.eventLogging';
+ $wgResourceModules['mmv.bootstrap.autostart']['dependencies'][] = 'ext.eventLogging';
+ }
+ }
+
+ public static function onEventLoggingRegisterSchemas( array &$schemas ) {
+ $schemas += [
+ 'MediaViewer' => 10867062,
+ 'MultimediaViewerNetworkPerformance' => 15573630,
+ 'MultimediaViewerDuration' => 10427980,
+ 'MultimediaViewerAttribution' => 9758179,
+ 'MultimediaViewerDimensions' => 10014238,
+ ];
+ }
+
+ /**
+ * Checks the context for whether to load the viewer.
+ * @param User $user
+ * @return bool
+ */
+ protected static function shouldHandleClicks( $user ) {
+ global $wgMediaViewerIsInBeta, $wgMediaViewerEnableByDefaultForAnonymous,
+ $wgMediaViewerEnableByDefault;
+
+ if ( $wgMediaViewerIsInBeta && class_exists( 'BetaFeatures' ) ) {
+ return BetaFeatures::isFeatureEnabled( $user, 'multimedia-viewer' );
+ }
+
+ if ( $wgMediaViewerEnableByDefaultForAnonymous === null ) {
+ $enableByDefaultForAnons = $wgMediaViewerEnableByDefault;
+ } else {
+ $enableByDefaultForAnons = $wgMediaViewerEnableByDefaultForAnonymous;
+ }
+
+ if ( !$user->isLoggedIn() ) {
+ return (bool)$enableByDefaultForAnons;
+ } else {
+ return (bool)$user->getOption( 'multimediaviewer-enable' );
+ }
+ }
+
+ /**
+ * Handler for all places where we add the modules
+ * Could be on article pages or on Category pages
+ * @param OutputPage &$out
+ * @return bool
+ */
+ protected static function getModules( &$out ) {
+ $out->addModules( [ 'mmv.head', 'mmv.bootstrap.autostart' ] );
+
+ return true;
+ }
+
+ /**
+ * Handler for BeforePageDisplay hook
+ * Add JavaScript to the page when an image is on it
+ * and the user has enabled the feature if BetaFeatures is installed
+ * @param OutputPage &$out
+ * @param Skin &$skin
+ * @return bool
+ */
+ public static function getModulesForArticle( &$out, &$skin ) {
+ $pageHasThumbnails = count( $out->getFileSearchOptions() ) > 0;
+ $pageIsFilePage = $out->getTitle()->inNamespace( NS_FILE );
+ $fileRelatedSpecialPages = [ 'NewFiles', 'ListFiles', 'MostLinkedFiles',
+ 'MostGloballyLinkedFiles', 'UncategorizedFiles', 'UnusedFiles', 'Search' ];
+ $pageIsFileRelatedSpecialPage = $out->getTitle()->inNamespace( NS_SPECIAL )
+ && in_array( $out->getTitle()->getText(), $fileRelatedSpecialPages );
+
+ if ( $pageHasThumbnails || $pageIsFilePage || $pageIsFileRelatedSpecialPage ) {
+ return self::getModules( $out );
+ }
+
+ return true;
+ }
+
+ /**
+ * Handler for CategoryPageView hook
+ * Add JavaScript to the page if there are images in the category
+ * @param CategoryPage &$catPage
+ * @return bool
+ */
+ public static function getModulesForCategory( &$catPage ) {
+ $title = $catPage->getTitle();
+ $cat = Category::newFromTitle( $title );
+ if ( $cat->getFileCount() > 0 ) {
+ $out = $catPage->getContext()->getOutput();
+ return self::getModules( $out );
+ }
+
+ return true;
+ }
+
+ /**
+ * Add a beta preference to gate the feature
+ * @param User $user
+ * @param array &$prefs
+ * @return true
+ */
+ public static function getBetaPreferences( $user, &$prefs ) {
+ global $wgExtensionAssetsPath, $wgMediaViewerIsInBeta;
+
+ if ( !$wgMediaViewerIsInBeta ) {
+ return true;
+ }
+
+ $prefs['multimedia-viewer'] = [
+ 'label-message' => 'multimediaviewer-pref',
+ 'desc-message' => 'multimediaviewer-pref-desc',
+ 'info-link' => self::$infoLink,
+ 'discussion-link' => self::$discussionLink,
+ 'help-link' => self::$helpLink,
+ 'screenshot' => [
+ 'ltr' => "$wgExtensionAssetsPath/MultimediaViewer/viewer-ltr.svg",
+ 'rtl' => "$wgExtensionAssetsPath/MultimediaViewer/viewer-rtl.svg",
+ ],
+ ];
+
+ return true;
+ }
+
+ /**
+ * Adds a default-enabled preference to gate the feature on non-beta sites
+ * @param User $user
+ * @param array &$prefs
+ * @return true
+ */
+ public static function getPreferences( $user, &$prefs ) {
+ global $wgMediaViewerIsInBeta;
+
+ if ( !$wgMediaViewerIsInBeta ) {
+ $prefs['multimediaviewer-enable'] = [
+ 'type' => 'toggle',
+ 'label-message' => 'multimediaviewer-optin-pref',
+ 'section' => 'rendering/files',
+ ];
+ }
+
+ return true;
+ }
+
+ /**
+ * Export variables used in both PHP and JS to keep DRY
+ * @param array &$vars
+ * @return bool
+ */
+ public static function resourceLoaderGetConfigVars( &$vars ) {
+ global $wgMediaViewerActionLoggingSamplingFactorMap,
+ $wgMediaViewerNetworkPerformanceSamplingFactor,
+ $wgMediaViewerDurationLoggingSamplingFactor,
+ $wgMediaViewerDurationLoggingLoggedinSamplingFactor,
+ $wgMediaViewerAttributionLoggingSamplingFactor,
+ $wgMediaViewerDimensionLoggingSamplingFactor,
+ $wgMediaViewerIsInBeta, $wgMediaViewerUseThumbnailGuessing, $wgMediaViewerExtensions,
+ $wgMediaViewerImageQueryParameter, $wgMediaViewerRecordVirtualViewBeaconURI;
+
+ $vars['wgMultimediaViewer'] = [
+ 'infoLink' => self::$infoLink,
+ 'discussionLink' => self::$discussionLink,
+ 'helpLink' => self::$helpLink,
+ 'useThumbnailGuessing' => (bool)$wgMediaViewerUseThumbnailGuessing,
+ 'durationSamplingFactor' => $wgMediaViewerDurationLoggingSamplingFactor,
+ 'durationSamplingFactorLoggedin' => $wgMediaViewerDurationLoggingLoggedinSamplingFactor,
+ 'networkPerformanceSamplingFactor' => $wgMediaViewerNetworkPerformanceSamplingFactor,
+ 'actionLoggingSamplingFactorMap' => $wgMediaViewerActionLoggingSamplingFactorMap,
+ 'attributionSamplingFactor' => $wgMediaViewerAttributionLoggingSamplingFactor,
+ 'dimensionSamplingFactor' => $wgMediaViewerDimensionLoggingSamplingFactor,
+ 'imageQueryParameter' => $wgMediaViewerImageQueryParameter,
+ 'recordVirtualViewBeaconURI' => $wgMediaViewerRecordVirtualViewBeaconURI,
+ 'tooltipDelay' => 1000,
+ 'extensions' => $wgMediaViewerExtensions,
+ ];
+ $vars['wgMediaViewer'] = true;
+ $vars['wgMediaViewerIsInBeta'] = $wgMediaViewerIsInBeta;
+
+ return true;
+ }
+
+ /**
+ * Export variables which depend on the current user
+ * @param array &$vars
+ * @param OutputPage $out
+ */
+ public static function makeGlobalVariablesScript( &$vars, OutputPage $out ) {
+ $defaultUserOptions = User::getDefaultOptions();
+
+ $user = $out->getUser();
+ $vars['wgMediaViewerOnClick'] = self::shouldHandleClicks( $user );
+ // needed because of bug 69942; could be different for anon and logged-in
+ $vars['wgMediaViewerEnabledByDefault'] =
+ !empty( $defaultUserOptions['multimediaviewer-enable'] );
+ }
+
+ /**
+ * Get modules for testing our JavaScript
+ * @param array &$testModules
+ * @param ResourceLoader &$resourceLoader
+ * @return bool
+ */
+ public static function getTestModules( array &$testModules, ResourceLoader &$resourceLoader ) {
+ $testModules['qunit']['mmv.tests'] = [
+ 'scripts' => [
+ 'tests/qunit/mmv/mmv.bootstrap.test.js',
+ 'tests/qunit/mmv/mmv.test.js',
+ 'tests/qunit/mmv/mmv.lightboxinterface.test.js',
+ 'tests/qunit/mmv/mmv.lightboximage.test.js',
+ 'tests/qunit/mmv/mmv.ThumbnailWidthCalculator.test.js',
+ 'tests/qunit/mmv/mmv.EmbedFileFormatter.test.js',
+ 'tests/qunit/mmv/mmv.Config.test.js',
+ 'tests/qunit/mmv/mmv.HtmlUtils.test.js',
+ 'tests/qunit/mmv/logging/mmv.logging.DurationLogger.test.js',
+ 'tests/qunit/mmv/logging/mmv.logging.PerformanceLogger.test.js',
+ 'tests/qunit/mmv/logging/mmv.logging.ActionLogger.test.js',
+ 'tests/qunit/mmv/logging/mmv.logging.AttributionLogger.test.js',
+ 'tests/qunit/mmv/logging/mmv.logging.DimensionLogger.test.js',
+ 'tests/qunit/mmv/logging/mmv.logging.ViewLogger.test.js',
+ 'tests/qunit/mmv/model/mmv.model.test.js',
+ 'tests/qunit/mmv/model/mmv.model.IwTitle.test.js',
+ 'tests/qunit/mmv/model/mmv.model.TaskQueue.test.js',
+ 'tests/qunit/mmv/model/mmv.model.License.test.js',
+ 'tests/qunit/mmv/model/mmv.model.Image.test.js',
+ 'tests/qunit/mmv/model/mmv.model.Repo.test.js',
+ 'tests/qunit/mmv/model/mmv.model.EmbedFileInfo.test.js',
+ 'tests/qunit/mmv/provider/mmv.provider.Api.test.js',
+ 'tests/qunit/mmv/provider/mmv.provider.ImageInfo.test.js',
+ 'tests/qunit/mmv/provider/mmv.provider.FileRepoInfo.test.js',
+ 'tests/qunit/mmv/provider/mmv.provider.ThumbnailInfo.test.js',
+ 'tests/qunit/mmv/provider/mmv.provider.GuessedThumbnailInfo.test.js',
+ 'tests/qunit/mmv/provider/mmv.provider.Image.test.js',
+ 'tests/qunit/mmv/routing/mmv.routing.MainFileRoute.test.js',
+ 'tests/qunit/mmv/routing/mmv.routing.ThumbnailRoute.test.js',
+ 'tests/qunit/mmv/routing/mmv.routing.Router.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.canvas.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.canvasButtons.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.description.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.download.pane.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.metadataPanel.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.metadataPanelScroller.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.progressBar.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.permission.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.reuse.dialog.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.reuse.embed.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.reuse.share.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.reuse.tab.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.reuse.utils.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.tipsyDialog.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.truncatableTextField.test.js',
+ 'tests/qunit/mmv/ui/mmv.ui.viewingOptions.test.js',
+ 'tests/qunit/mmv/mmv.testhelpers.js',
+ ],
+ 'dependencies' => [
+ 'mmv.head',
+ 'mmv.bootstrap',
+ 'mmv',
+ 'mmv.ui.ondemandshareddependencies',
+ 'mmv.ui.reuse.shareembed',
+ 'mmv.ui.download.pane',
+ 'mmv.ui.tipsyDialog',
+ 'moment',
+ ],
+ 'localBasePath' => dirname( __DIR__ ),
+ 'remoteExtPath' => 'MultimediaViewer',
+ ];
+
+ return true;
+ }
+
+ /**
+ * Modify thumbnail DOM
+ * @param ThumbnailImage $thumbnail
+ * @param array &$attribs Attributes of the <img> element
+ * @param array|bool &$linkAttribs Attributes of the wrapping <a> element
+ * @return true
+ */
+ public static function thumbnailBeforeProduceHTML( ThumbnailImage $thumbnail, array &$attribs,
+ &$linkAttribs
+ ) {
+ $file = $thumbnail->getFile();
+
+ if ( $file ) {
+ // At the moment all classes that extend File have getWidth() and getHeight()
+ // but since the File class doesn't have these methods defined, this check
+ // is more future-proof
+
+ if ( method_exists( $file, 'getWidth' ) ) {
+ $attribs['data-file-width'] = $file->getWidth();
+ }
+
+ if ( method_exists( $file, 'getHeight' ) ) {
+ $attribs['data-file-height'] = $file->getHeight();
+ }
+ }
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/jsduck.categories.json b/www/wiki/extensions/MultimediaViewer/jsduck.categories.json
new file mode 100644
index 00000000..b994017e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/jsduck.categories.json
@@ -0,0 +1,104 @@
+[
+ {
+ "name": "Media Viewer classes",
+ "groups": [
+ {
+ "name": "Base",
+ "classes": [
+ "mw.mmv.Config",
+ "mw.mmv.EmbedFileFormatter",
+ "mw.mmv.HtmlUtils",
+ "mw.mmv.LightboxImage",
+ "mw.mmv.LightboxInterface",
+ "mw.mmv.MultimediaViewer",
+ "mw.mmv.MultimediaViewerBootstrap",
+ "mw.mmv.ThumbnailWidthCalculator"
+ ]
+ },
+ {
+ "name": "Loggers",
+ "classes": [
+ "mw.mmv.logging.*"
+ ]
+ },
+ {
+ "name": "Models",
+ "classes": [
+ "mw.mmv.model.*"
+ ]
+ },
+ {
+ "name": "Providers",
+ "classes": [
+ "mw.mmv.provider.*"
+ ]
+ },
+ {
+ "name": "Routers",
+ "classes": [
+ "mw.mmv.routing.*"
+ ]
+ },
+ {
+ "name": "Interface",
+ "classes": [
+ "mw.mmv.ui.*"
+ ]
+ }
+ ]
+ },
+
+ {
+ "name": "External",
+ "groups": [
+ {
+ "name": "jQuery",
+ "classes": [
+ "jQuery",
+ "jQuery.Promise",
+ "jQuery.Deferred",
+ "jQuery.Event",
+ "jqXHR"
+ ]
+ },
+ {
+ "name": "JavaScript natives",
+ "classes": [
+ "Array",
+ "Boolean",
+ "Date",
+ "Function",
+ "Number",
+ "Object",
+ "RegExp",
+ "String"
+ ]
+ },
+ {
+ "name": "OOUI",
+ "classes": [
+ "OO.ui.*"
+ ]
+ },
+ {
+ "name": "MediaWiki",
+ "classes": [
+ "mw",
+ "mw.Api",
+ "mw.Title",
+ "mw.Map",
+ "mw.storage",
+ "mw.eventLog"
+ ]
+ },
+ {
+ "name": "Browser native classes",
+ "classes": [
+ "HTMLElement",
+ "HTMLImageElement",
+ "XMLHttpRequest"
+ ]
+ }
+ ]
+ }
+]
diff --git a/www/wiki/extensions/MultimediaViewer/jsduck.external.js b/www/wiki/extensions/MultimediaViewer/jsduck.external.js
new file mode 100644
index 00000000..45c713db
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/jsduck.external.js
@@ -0,0 +1,87 @@
+/**
+ * @class mw
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/mw>
+ * @singleton
+ */
+
+/**
+ * @class mw.Api
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/mw.Api>
+ */
+
+/**
+ * @class mw.Title
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/mw.Title>
+ */
+
+/**
+ * @class mw.eventLog
+ * <https://www.mediawiki.org/wiki/Extension:EventLogging>
+ */
+
+/**
+ * @class mw.Map
+ * Associative array which is used for various configuration objects, most prominently mw.config:
+ * <https://www.mediawiki.org/wiki/Manual:Interface/JavaScript#mw.config>
+ */
+
+/**
+ * @class mw.storage
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/mw.storage>
+ */
+
+/**
+ * @class HTMLElement
+ * An HTML element.
+ */
+
+/**
+ * @class HTMLImageElement
+ * @extends HTMLElement
+ * An HTML <img> element.
+ */
+
+/**
+ * @class OO.ui.MenuOptionWidget
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/OO.ui.MenuOptionWidget>
+ */
+
+/**
+ * @class OO.ui.MenuSelectWidget
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/OO.ui.MenuSelectWidget>
+ */
+
+/**
+ * @class OO.ui.DropdownWidget
+ * <https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/OO.ui.DropdownWidget>
+ */
+
+/**
+ * @class XMLHttpRequest
+ * An AJAX request
+ */
+
+/**
+ * @class jQuery
+ * A jQuery object.
+ */
+
+/**
+ * @class jQuery.Promise
+ * A jQuery promise object.
+ */
+
+/**
+ * @class jQuery.Deferred
+ * A jQuery deferred object.
+ */
+
+/**
+ * @class jQuery.Event
+ * An event object with extra jQuery data.
+ */
+
+/**
+ * @class jqXHR
+ * An XMLHttpRequest object wrapped by jQuery
+ */
diff --git a/www/wiki/extensions/MultimediaViewer/jsduck.json b/www/wiki/extensions/MultimediaViewer/jsduck.json
new file mode 100644
index 00000000..a9be81f9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/jsduck.json
@@ -0,0 +1,12 @@
+{
+ "--title": "MultimediaViewer - Documentation",
+ "--categories": "jsduck.categories.json",
+ "--builtin-classes": true,
+ "--processes": "0",
+ "--warnings-exit-nonzero": true,
+ "--output": "docs",
+ "--": [
+ "jsduck.external.js",
+ "resources/mmv"
+ ]
+}
diff --git a/www/wiki/extensions/MultimediaViewer/package.json b/www/wiki/extensions/MultimediaViewer/package.json
new file mode 100644
index 00000000..e54ceb9b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/package.json
@@ -0,0 +1,18 @@
+{
+ "private": true,
+ "scripts": {
+ "test": "grunt test",
+ "doc": "jsduck"
+ },
+ "devDependencies": {
+ "eslint-config-wikimedia": "0.5.0",
+ "grunt": "1.0.1",
+ "grunt-banana-checker": "0.6.0",
+ "grunt-eslint": "20.0.0",
+ "grunt-jsonlint": "1.1.0",
+ "grunt-stylelint": "0.9.0",
+ "grunt-svgmin": "5.0.0",
+ "stylelint": "8.2.0",
+ "stylelint-config-wikimedia": "0.4.2"
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/jquery.hashchange/jquery.hashchange.js b/www/wiki/extensions/MultimediaViewer/resources/jquery.hashchange/jquery.hashchange.js
new file mode 100644
index 00000000..b7e7db31
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/jquery.hashchange/jquery.hashchange.js
@@ -0,0 +1,260 @@
+/*!
+ * jQuery hashchange event - v1.3 - 7/21/2010
+ * http://benalman.com/projects/jquery-hashchange-plugin/
+ *
+ * Copyright (c) 2010 "Cowboy" Ben Alman
+ * Dual licensed under the MIT and GPL licenses.
+ * http://benalman.com/about/license/
+ */
+
+// Forked on July 10th 2014 by Gilles Dubuc (WMF) in order to add jQuery 1.9 compatibility
+// The fork was done because upstream is currently unmaintained and not responding to merge requests
+
+// Script: jQuery hashchange event
+//
+// *Version: 1.3, Last updated: 7/21/2010*
+//
+// Project Home - http://benalman.com/projects/jquery-hashchange-plugin/
+// GitHub - http://github.com/cowboy/jquery-hashchange/
+// Source - http://github.com/cowboy/jquery-hashchange/raw/master/jquery.ba-hashchange.js
+// (Minified) - http://github.com/cowboy/jquery-hashchange/raw/master/jquery.ba-hashchange.min.js (0.8kb gzipped)
+//
+// About: License
+//
+// Copyright (c) 2010 "Cowboy" Ben Alman,
+// Dual licensed under the MIT and GPL licenses.
+// http://benalman.com/about/license/
+//
+// About: Examples
+//
+// These working examples, complete with fully commented code, illustrate a few
+// ways in which this plugin can be used.
+//
+// hashchange event - http://benalman.com/code/projects/jquery-hashchange/examples/hashchange/
+// document.domain - http://benalman.com/code/projects/jquery-hashchange/examples/document_domain/
+//
+// About: Support and Testing
+//
+// Information about what version or versions of jQuery this plugin has been
+// tested with, what browsers it has been tested in, and where the unit tests
+// reside (so you can test it yourself).
+//
+// jQuery Versions - 1.2.6, 1.3.2, 1.4.1, 1.4.2
+// Browsers Tested - Internet Explorer 6-8, Firefox 2-4, Chrome 5-6, Safari 3.2-5,
+// Opera 9.6-10.60, iPhone 3.1, Android 1.6-2.2, BlackBerry 4.6-5.
+// Unit Tests - http://benalman.com/code/projects/jquery-hashchange/unit/
+//
+// About: Known issues
+//
+// While this jQuery hashchange event implementation is quite stable and
+// robust, there are a few unfortunate browser bugs surrounding expected
+// hashchange event-based behaviors, independent of any JavaScript
+// window.onhashchange abstraction. See the following examples for more
+// information:
+//
+// Chrome: Back Button - http://benalman.com/code/projects/jquery-hashchange/examples/bug-chrome-back-button/
+// Firefox: Remote XMLHttpRequest - http://benalman.com/code/projects/jquery-hashchange/examples/bug-firefox-remote-xhr/
+// WebKit: Back Button in an Iframe - http://benalman.com/code/projects/jquery-hashchange/examples/bug-webkit-hash-iframe/
+// Safari: Back Button from a different domain - http://benalman.com/code/projects/jquery-hashchange/examples/bug-safari-back-from-diff-domain/
+//
+// Also note that should a browser natively support the window.onhashchange
+// event, but not report that it does, the fallback polling loop will be used.
+//
+// About: Release History
+//
+// 1.3 - (7/21/2010) Reorganized IE6/7 Iframe code to make it more
+// "removable" for mobile-only development. Added IE6/7 document.title
+// support. Attempted to make Iframe as hidden as possible by using
+// techniques from http://www.paciellogroup.com/blog/?p=604. Added
+// support for the "shortcut" format $(window).hashchange( fn ) and
+// $(window).hashchange() like jQuery provides for built-in events.
+// Renamed jQuery.hashchangeDelay to <jQuery.fn.hashchange.delay> and
+// lowered its default value to 50. Added <jQuery.fn.hashchange.domain>
+// and <jQuery.fn.hashchange.src> properties plus document-domain.html
+// file to address access denied issues when setting document.domain in
+// IE6/7.
+// 1.2 - (2/11/2010) Fixed a bug where coming back to a page using this plugin
+// from a page on another domain would cause an error in Safari 4. Also,
+// IE6/7 Iframe is now inserted after the body (this actually works),
+// which prevents the page from scrolling when the event is first bound.
+// Event can also now be bound before DOM ready, but it won't be usable
+// before then in IE6/7.
+// 1.1 - (1/21/2010) Incorporated document.documentMode test to fix IE8 bug
+// where browser version is incorrectly reported as 8.0, despite
+// inclusion of the X-UA-Compatible IE=EmulateIE7 meta tag.
+// 1.0 - (1/9/2010) Initial Release. Broke out the jQuery BBQ event.special
+// window.onhashchange functionality into a separate plugin for users
+// who want just the basic event & back button support, without all the
+// extra awesomeness that BBQ provides. This plugin will be included as
+// part of jQuery BBQ, but also be available separately.
+
+(function($,window,undefined){
+ '$:nomunge'; // Used by YUI compressor.
+
+ // Reused string.
+ var str_hashchange = 'hashchange',
+
+ // Method / object references.
+ doc = document,
+ fake_onhashchange,
+ special = $.event.special,
+
+ // Does the browser support window.onhashchange?
+ supports_onhashchange = 'on' + str_hashchange in window;
+
+ // Get location.hash (or what you'd expect location.hash to be) sans any
+ // leading #. Thanks for making this necessary, Firefox!
+ function get_fragment( url ) {
+ url = url || location.href;
+ return '#' + url.replace( /^[^#]*#?(.*)$/, '$1' );
+ };
+
+ // Method: jQuery.fn.hashchange
+ //
+ // Bind a handler to the window.onhashchange event or trigger all bound
+ // window.onhashchange event handlers. This behavior is consistent with
+ // jQuery's built-in event handlers.
+ //
+ // Usage:
+ //
+ // > jQuery(window).hashchange( [ handler ] );
+ //
+ // Arguments:
+ //
+ // handler - (Function) Optional handler to be bound to the hashchange
+ // event. This is a "shortcut" for the more verbose form:
+ // jQuery(window).bind( 'hashchange', handler ). If handler is omitted,
+ // all bound window.onhashchange event handlers will be triggered. This
+ // is a shortcut for the more verbose
+ // jQuery(window).trigger( 'hashchange' ). These forms are described in
+ // the <hashchange event> section.
+ //
+ // Returns:
+ //
+ // (jQuery) The initial jQuery collection of elements.
+
+ // Allow the "shortcut" format $(elem).hashchange( fn ) for binding and
+ // $(elem).hashchange() for triggering, like jQuery does for built-in events.
+ $.fn[ str_hashchange ] = function( fn ) {
+ return fn ? this.bind( str_hashchange, fn ) : this.trigger( str_hashchange );
+ };
+
+ // Property: jQuery.fn.hashchange.delay
+ //
+ // The numeric interval (in milliseconds) at which the <hashchange event>
+ // polling loop executes. Defaults to 50.
+
+ $.fn[ str_hashchange ].delay = 50;
+
+ // Event: hashchange event
+ //
+ // Fired when location.hash changes. In browsers that support it, the native
+ // HTML5 window.onhashchange event is used, otherwise a polling loop is
+ // initialized, running every <jQuery.fn.hashchange.delay> milliseconds to
+ // see if the hash has changed.
+ //
+ // Usage as described in <jQuery.fn.hashchange>:
+ //
+ // > // Bind an event handler.
+ // > jQuery(window).hashchange( function(e) {
+ // > var hash = location.hash;
+ // > ...
+ // > });
+ // >
+ // > // Manually trigger the event handler.
+ // > jQuery(window).hashchange();
+ //
+ // A more verbose usage that allows for event namespacing:
+ //
+ // > // Bind an event handler.
+ // > jQuery(window).bind( 'hashchange', function(e) {
+ // > var hash = location.hash;
+ // > ...
+ // > });
+ // >
+ // > // Manually trigger the event handler.
+ // > jQuery(window).trigger( 'hashchange' );
+ //
+ // Additional Notes:
+ //
+ // * The polling loop and Iframe are not created until at least one handler
+ // is actually bound to the 'hashchange' event.
+ // * If you need the bound handler(s) to execute immediately, in cases where
+ // a location.hash exists on page load, via bookmark or page refresh for
+ // example, use jQuery(window).hashchange() or the more verbose
+ // jQuery(window).trigger( 'hashchange' ).
+
+ // Override existing $.event.special.hashchange methods (allowing this plugin
+ // to be defined after jQuery BBQ in BBQ's source code).
+ special[ str_hashchange ] = $.extend( special[ str_hashchange ], {
+
+ // Called only when the first 'hashchange' event is bound to window.
+ setup: function() {
+ // If window.onhashchange is supported natively, there's nothing to do..
+ if ( supports_onhashchange ) { return false; }
+
+ // Otherwise, we need to create our own. And we don't want to call this
+ // until the user binds to the event, just in case they never do, since it
+ // will create a polling loop and possibly even a hidden Iframe.
+ $( fake_onhashchange.start );
+ },
+
+ // Called only when the last 'hashchange' event is unbound from window.
+ teardown: function() {
+ // If window.onhashchange is supported natively, there's nothing to do..
+ if ( supports_onhashchange ) { return false; }
+
+ // Otherwise, we need to stop ours (if possible).
+ $( fake_onhashchange.stop );
+ }
+
+ });
+
+ // fake_onhashchange creates a polling loop to watch for hash changes and
+ // triggers the window.onhashchange event for browsers that don't natively
+ // support it.
+ fake_onhashchange = (function(){
+ var self = {},
+ timeout_id,
+
+ // Remember the initial hash so it doesn't get triggered immediately.
+ last_hash = get_fragment(),
+
+ fn_retval = function(val){ return val; },
+ history_set = fn_retval,
+ history_get = fn_retval;
+
+ // Start the polling loop.
+ self.start = function() {
+ timeout_id || poll();
+ };
+
+ // Stop the polling loop.
+ self.stop = function() {
+ timeout_id && clearTimeout( timeout_id );
+ timeout_id = undefined;
+ };
+
+ // This polling loop checks every $.fn.hashchange.delay milliseconds to see
+ // if location.hash has changed, and triggers the 'hashchange' event on
+ // window when necessary.
+ function poll() {
+ var hash = get_fragment(),
+ history_hash = history_get( last_hash );
+
+ if ( hash !== last_hash ) {
+ history_set( last_hash = hash, history_hash );
+
+ $(window).trigger( str_hashchange );
+
+ } else if ( history_hash !== last_hash ) {
+ location.href = location.href.replace( /#.*/, '' ) + history_hash;
+ }
+
+ timeout_id = setTimeout( poll, $.fn[ str_hashchange ].delay );
+ };
+
+ return self;
+ })();
+
+})(jQuery,this);
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/img/down.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/down.svg
new file mode 100644
index 00000000..db304af0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/down.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12">
+ <path fill="#fff" fill-rule="evenodd" d="M2.023 3l3.49 5.953L9 3z" clip-rule="evenodd"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/img/expand.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/expand.svg
new file mode 100644
index 00000000..52be87b9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/expand.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1024 768">
+ <path d="M851.2 71.6L690.7 232.1l-40.1-40.3-9.6 164.8 164.8-9.3-40.3-40.4L926 146.4l58.5 58.5L997.6 0 792.7 13.1"/>
+ <path d="M769.6 89.3H611.9l70.9 70.8 7.9 7.5m-47.1 234.6l-51.2 3 3-51.2 9.4-164.4 5.8-100.3H26.4V768h883.1V387l-100.9 5.8-165 9.4zM813.9 678H113.6l207.2-270.2 31.5-12.9L548 599.8l105.9-63.2 159.8 140.8.2.6zm95.6-291.9V228l-79.1 78.9 7.8 7.9"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/img/gear.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/gear.svg
new file mode 100644
index 00000000..01c7a43c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/gear.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1024 768">
+ <path d="M897 454.6V313.4L810.4 299c-6.4-23.3-16-45.7-27.3-65.8l50.5-71.4-99.4-100.2-71.4 50.5c-20.9-11.2-42.5-20.9-65.8-27.3L582.6-1H441.4L427 85.6c-23.3 6.4-45.7 16-65.8 27.3l-71.4-50.5-100.3 99.5 50.5 71.4c-11.2 20.9-20.9 42.5-27.3 66.6L127 313.4v141.2l85.8 14.4c6.4 23.3 16 45.7 27.3 66.6L189.6 607l99.5 99.5 71.4-50.5c20.9 11.2 42.5 20.9 66.6 27.3l14.4 85.8h141.2l14.4-86.6c23.3-6.4 45.7-16 65.8-27.3l71.4 50.5 99.5-99.5-50.5-71.4c11.2-20.9 20.9-42.5 27.3-66.6l86.4-13.6zm-385 77c-81.8 0-147.6-66.6-147.6-147.6 0-81.8 66.6-147.6 147.6-147.6S659.6 302.2 659.6 384 593.8 531.6 512 531.6z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/img/x_gray.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/x_gray.svg
new file mode 100644
index 00000000..739b911e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/img/x_gray.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 612 792">
+ <path fill="#72777d" d="M612 179.2L522.8 90 306 306.8 89.2 90 0 179.2 216.8 396 0 612.8 89.2 702 306 485.2 522.8 702l89.2-89.2L395.2 396"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ActionLogger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ActionLogger.js
new file mode 100644
index 00000000..9f18f972
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ActionLogger.js
@@ -0,0 +1,192 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var L;
+
+ /**
+ * Writes log entries
+ *
+ * @class mw.mmv.logging.ActionLogger
+ * @extends mw.mmv.logging.Logger
+ * @constructor
+ */
+ function ActionLogger() {}
+
+ oo.inheritClass( ActionLogger, mw.mmv.logging.Logger );
+
+ L = ActionLogger.prototype;
+
+ /**
+ * Sampling factor key-value map.
+ *
+ * The map's keys are the action identifiers and the values are the sampling factor for each action type.
+ * There is a "default" key defined providing a default sampling factor for actions that aren't explicitely
+ * set in the map.
+ * @property {Object.<string, number>}
+ * @static
+ */
+ L.samplingFactorMap = mw.config.get( 'wgMultimediaViewer' ).actionLoggingSamplingFactorMap;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ L.schema = 'MediaViewer';
+
+ /**
+ * Possible log actions, and their associated English developer log strings.
+ *
+ * These events are not de-duped. Eg. if the user opens the same site link
+ * in 10 tabs, there will be 10 file-description-page events. If they view the
+ * same image 10 times by hitting the prev/next buttons, there will be 10
+ * image-view events, etc.
+ * @property
+ * @static
+ */
+ L.logActions = {
+ thumbnail: 'User clicked on a thumbnail to open Media Viewer.',
+ enlarge: 'User clicked on an enlarge link to open Media Viewer.',
+ fullscreen: 'User entered fullscreen mode.',
+ defullscreen: 'User exited fullscreen mode.',
+ close: 'User closed Media Viewer.',
+ 'view-original-file': 'User clicked on the direct link to the original file',
+ 'file-description-page': 'User opened the file description page.',
+ 'file-description-page-abovefold': 'User opened the file description page via the above-the-fold button.',
+ 'use-this-file-open': 'User opened the dialog to use this file.',
+ 'image-view': 'User viewed an image.',
+ 'metadata-open': 'User opened the metadata panel.',
+ 'metadata-close': 'User closed the metadata panel.',
+ 'metadata-scroll-open': 'User opened the metadata panel by scrolling.',
+ 'metadata-scroll-close': 'User closed the metadata panel by scrolling.',
+ 'next-image': 'User viewed the next image.',
+ 'prev-image': 'User viewed the previous image.',
+ 'terms-open': 'User opened the usage terms.',
+ 'license-page': 'User opened the license page.',
+ 'author-page': 'User opened the author page.',
+ 'source-page': 'User opened the source page.',
+ 'hash-load': 'User loaded the image via a hash on pageload.',
+ 'history-navigation': 'User navigated with the browser history.',
+ 'optout-loggedin': 'opt-out (via quick link at bottom of metadata panel) by logged-in user',
+ 'optout-anon': 'opt-out by anonymous user',
+ 'optin-loggedin': 'opt-in (via quick link at bottom of metadata panel) by logged-in user',
+ 'optin-anon': 'opt-in by anonymous user',
+ 'about-page': 'User opened the about page.',
+ 'discuss-page': 'User opened the discuss page.',
+ 'help-page': 'User opened the help page.',
+ 'location-page': 'User opened the location page.',
+ 'download-select-menu-original': 'User selected the original size in the download dropdown menu.',
+ 'download-select-menu-small': 'User selected the small size in the download dropdown menu.',
+ 'download-select-menu-medium': 'User selected the medium size in the download dropdown menu.',
+ 'download-select-menu-large': 'User selected the large size in the download dropdown menu.',
+ download: 'User clicked on the button to download a file.',
+ 'download-view-in-browser': 'User clicked on the link to view the image in the browser in the download tab.',
+ 'right-click-image': 'User right-clicked on the image.',
+ 'share-page': 'User opened the link to the current image.',
+ 'share-link-copied': 'User copied the share link.',
+ 'embed-html-copied': 'User copied the HTML embed code.',
+ 'embed-wikitext-copied': 'User copied the wikitext embed code.',
+ 'embed-switched-to-html': 'User switched to the HTML embed code.',
+ 'embed-switched-to-wikitext': 'User switched to the wikitext embed code.',
+ 'embed-select-menu-wikitext-default': 'User switched to the default thumbnail size on wikitext.',
+ 'embed-select-menu-wikitext-small': 'User switched to the small thumbnail size on wikitext.',
+ 'embed-select-menu-wikitext-medium': 'User switched to the medium thumbnail size on wikitext.',
+ 'embed-select-menu-wikitext-large': 'User switched to the large thumbnail size on wikitext.',
+ 'embed-select-menu-html-original': 'User switched to the original thumbnail size on html.',
+ 'embed-select-menu-html-small': 'User switched to the small thumbnail size on html.',
+ 'embed-select-menu-html-medium': 'User switched to the medium thumbnail size on html.',
+ 'embed-select-menu-html-large': 'User switched to the large thumbnail size on html.',
+ 'use-this-file-close': 'User closed the dialog to use this file.',
+ 'download-open': 'User opened the dialog to download this file.',
+ 'download-close': 'User closed the dialog to download this file.',
+ 'options-open': 'User opened the enable/disable dialog.',
+ 'options-close': 'User either canceled an enable/disable action or closed a confirmation window.',
+ 'disable-about-link': 'User clicked on the "Learn more" link in the disable window.',
+ 'enable-about-link': 'User clicked on the "Learn more" link in the enable window.',
+ 'image-unview': 'User stopped looking at the current image.'
+ };
+
+ /**
+ * Logs an action
+ *
+ * @param {string} action The key representing the action
+ * @param {boolean} forceEventLog True if we want the action to be logged regardless of the sampling factor
+ * @return {jQuery.Promise}
+ */
+ L.log = function ( action, forceEventLog ) {
+ var actionText = this.logActions[ action ] || action,
+ self = this;
+
+ if ( this.isEnabled( action ) ) {
+ mw.log( actionText );
+ }
+
+ if ( forceEventLog || self.isInSample( action ) ) {
+ return this.loadDependencies().then( function () {
+ self.eventLog.logEvent( self.schema, {
+ action: action,
+ samplingFactor: self.getActionFactor( action )
+ } );
+
+ return true;
+ } );
+ } else {
+ return $.Deferred().resolve( false );
+ }
+ };
+
+ /**
+ * Returns the sampling factor for a given action
+ *
+ * @param {string} action The key representing the action
+ * @return {number} Sampling factor
+ */
+ L.getActionFactor = function ( action ) {
+ return this.samplingFactorMap[ action ] || this.samplingFactorMap.default;
+ };
+
+ /**
+ * Returns whether or not we should measure this request for this action
+ *
+ * @param {string} action The key representing the action
+ * @return {boolean} True if this request needs to be sampled
+ */
+ L.isInSample = function ( action ) {
+ var factor = this.getActionFactor( action );
+
+ if ( !$.isNumeric( factor ) || factor < 1 ) {
+ return false;
+ }
+ return Math.floor( Math.random() * factor ) === 0;
+ };
+
+ /**
+ * Returns whether logging this event is enabled. This is intended for console logging, which
+ * (in debug mode) should be done even if the request is not being sampled, as long as logging
+ * is enabled for some sample.
+ *
+ * @param {string} action The key representing the action
+ * @return {boolean} True if this logging is enabled
+ */
+ L.isEnabled = function ( action ) {
+ var factor = this.getActionFactor( action );
+ return $.isNumeric( factor ) && factor >= 1;
+ };
+
+ mw.mmv.logging.ActionLogger = ActionLogger;
+ mw.mmv.actionLogger = new ActionLogger();
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Api.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Api.js
new file mode 100644
index 00000000..a6158d78
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Api.js
@@ -0,0 +1,58 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ /**
+ * Runs performance analysis on requests via mw.mmv.logging.PerformanceLogger
+ *
+ * @class mw.mmv.logging.Api
+ * @extends mw.Api
+ * @constructor
+ * @param {string} type The type of the requests to be made through this API.
+ * @param {Object} options See mw.Api#defaultOptions
+ */
+ function Api( type, options ) {
+ mw.Api.call( this, options );
+
+ /** @property {mw.mmv.logging.PerformanceLogger} performance Used to record performance data. */
+ this.performance = new mw.mmv.logging.PerformanceLogger();
+
+ /** @property {string} type Type of requests being sent via this API. */
+ this.type = type;
+ }
+
+ oo.inheritClass( Api, mw.Api );
+
+ /**
+ * Runs an AJAX call to the server.
+ *
+ * @override
+ * @param {Object} parameters
+ * @param {Object} [ajaxOptions]
+ * @return {jQuery.Promise.<Object, jqXHR>} Done: API response data. Fail: Error code.
+ */
+ Api.prototype.ajax = function ( parameters, ajaxOptions ) {
+ var start = $.now(),
+ api = this;
+
+ return mw.Api.prototype.ajax.call( this, parameters, ajaxOptions ).done( function ( result, jqxhr ) {
+ api.performance.recordJQueryEntryDelayed( api.type, $.now() - start, jqxhr );
+ } );
+ };
+
+ mw.mmv.logging.Api = Api;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.AttributionLogger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.AttributionLogger.js
new file mode 100644
index 00000000..52171977
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.AttributionLogger.js
@@ -0,0 +1,73 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var AL;
+
+ /**
+ * Writes EventLogging entries for duration measurements
+ *
+ * @class mw.mmv.logging.AttributionLogger
+ * @extends mw.mmv.logging.Logger
+ * @constructor
+ */
+ function AttributionLogger() {}
+
+ oo.inheritClass( AttributionLogger, mw.mmv.logging.Logger );
+
+ AL = AttributionLogger.prototype;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ AL.samplingFactor = mw.config.get( 'wgMultimediaViewer' ).attributionSamplingFactor;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ AL.schema = 'MultimediaViewerAttribution';
+
+ /**
+ * Logs attribution data
+ *
+ * @param {mw.mmv.model.Image} image Image data
+ */
+ AL.logAttribution = function ( image ) {
+ var data;
+
+ data = {
+ authorPresent: !!image.author,
+ sourcePresent: !!image.source,
+ licensePresent: !!image.license,
+ loggedIn: !mw.user.isAnon(),
+ samplingFactor: this.samplingFactor
+ };
+
+ if ( this.isEnabled() ) {
+ mw.log( 'author: ' + ( data.authorPresent ? 'present' : 'absent' ) +
+ ', source: ' + ( data.sourcePresent ? 'present' : 'absent' ) +
+ ', license: ' + ( data.licensePresent ? 'present' : 'absent' ) );
+ }
+
+ this.log( data );
+ };
+
+ mw.mmv.logging.AttributionLogger = AttributionLogger;
+ mw.mmv.attributionLogger = new AttributionLogger();
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DimensionLogger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DimensionLogger.js
new file mode 100644
index 00000000..82ead14c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DimensionLogger.js
@@ -0,0 +1,81 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var DL;
+
+ /**
+ * Writes EventLogging entries for size measurements related to thumbnail size selection
+ * (bucket size vs. display size).
+ *
+ * @class mw.mmv.logging.DimensionLogger
+ * @extends mw.mmv.logging.Logger
+ * @constructor
+ */
+ function DimensionLogger() {}
+
+ oo.inheritClass( DimensionLogger, mw.mmv.logging.Logger );
+
+ DL = DimensionLogger.prototype;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ DL.samplingFactor = mw.config.get( 'wgMultimediaViewer' ).dimensionSamplingFactor;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ DL.schema = 'MultimediaViewerDimensions';
+
+ /**
+ * Logs dimension data.
+ *
+ * @param {mw.mmv.model.ThumbnailWidth} imageWidths Widths of the image that will be displayed
+ * @param {Object} canvasDimensions Canvas width and height in CSS pixels
+ * @param {string} context Reason for requesting the image, one of 'show', 'resize', 'preload'
+ */
+ DL.logDimensions = function ( imageWidths, canvasDimensions, context ) {
+ var data;
+
+ data = {
+ screenWidth: screen.width,
+ screenHeight: screen.height,
+ viewportWidth: $( window ).width(),
+ viewportHeight: $( window ).height(),
+ canvasWidth: canvasDimensions.width,
+ canvasHeight: canvasDimensions.height,
+ devicePixelRatio: $.devicePixelRatio(),
+ imgWidth: imageWidths.cssWidth,
+ imageAspectRatio: imageWidths.cssWidth / imageWidths.cssHeight,
+ thumbWidth: imageWidths.real,
+ context: context,
+ samplingFactor: this.samplingFactor
+ };
+
+ if ( this.isEnabled() ) {
+ mw.log( 'mw.mmw.logger.DimensionLogger', data );
+ }
+
+ this.log( data );
+ };
+
+ mw.mmv.logging.DimensionLogger = DimensionLogger;
+ mw.mmv.dimensionLogger = new DimensionLogger();
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DurationLogger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DurationLogger.js
new file mode 100644
index 00000000..d2e0f918
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.DurationLogger.js
@@ -0,0 +1,162 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var L;
+
+ /**
+ * Writes EventLogging entries for duration measurements
+ *
+ * @class mw.mmv.logging.DurationLogger
+ * @extends mw.mmv.logging.Logger
+ * @constructor
+ */
+ function DurationLogger() {
+ this.starts = {};
+ this.stops = {};
+ }
+
+ oo.inheritClass( DurationLogger, mw.mmv.logging.Logger );
+
+ L = DurationLogger.prototype;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ L.samplingFactor = mw.config.get( 'wgMultimediaViewer' ).durationSamplingFactor;
+
+ // If a sampling factor specific to loggedin users is set and we're logged in, apply it
+ if ( mw.config.get( 'wgMultimediaViewer' ).durationSamplingFactorLoggedin && !mw.user.isAnon() ) {
+ L.samplingFactor = mw.config.get( 'wgMultimediaViewer' ).durationSamplingFactorLoggedin;
+ }
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ L.schema = 'MultimediaViewerDuration';
+
+ // eslint-disable-next-line valid-jsdoc
+ /**
+ * Saves the start of a duration
+ *
+ * @param {string|string[]} typeOrTypes Type(s) of duration being measured.
+ * @chainable
+ */
+ L.start = function ( typeOrTypes ) {
+ var i,
+ start = $.now();
+
+ if ( !typeOrTypes ) {
+ throw new Error( 'Must specify type' );
+ }
+
+ if ( !$.isArray( typeOrTypes ) ) {
+ typeOrTypes = [ typeOrTypes ];
+ }
+
+ for ( i = 0; i < typeOrTypes.length; i++ ) {
+ // Don't overwrite an existing value
+ if ( !this.starts.hasOwnProperty( typeOrTypes[ i ] ) ) {
+ this.starts[ typeOrTypes[ i ] ] = start;
+ }
+ }
+
+ return this;
+ };
+
+ // eslint-disable-next-line valid-jsdoc
+ /**
+ * Saves the stop of a duration
+ *
+ * @param {string} type Type of duration being measured.
+ * @param {number} start Start timestamp to substitute the one coming from start()
+ * @chainable
+ */
+ L.stop = function ( type, start ) {
+ var stop = $.now();
+
+ if ( !type ) {
+ throw new Error( 'Must specify type' );
+ }
+
+ // Don't overwrite an existing value
+ if ( !this.stops.hasOwnProperty( type ) ) {
+ this.stops[ type ] = stop;
+ }
+
+ // Don't overwrite an existing value
+ if ( start !== undefined && !this.starts.hasOwnProperty( type ) ) {
+ this.starts[ type ] = start;
+ }
+
+ return this;
+ };
+
+ // eslint-disable-next-line valid-jsdoc
+ /**
+ * Records the duration log event
+ *
+ * @param {string} type Type of duration being measured.
+ * @param {Object} extraData Extra information to add to the log event data
+ * @chainable
+ */
+ L.record = function ( type, extraData ) {
+ var e, duration;
+
+ if ( !type ) {
+ throw new Error( 'Must specify type' );
+ }
+
+ if ( !this.starts.hasOwnProperty( type ) || this.starts[ type ] === undefined ) {
+ return;
+ }
+
+ if ( !this.stops.hasOwnProperty( type ) || this.stops[ type ] === undefined ) {
+ return;
+ }
+
+ duration = this.stops[ type ] - this.starts[ type ];
+
+ e = {
+ type: type,
+ duration: duration,
+ loggedIn: !mw.user.isAnon(),
+ samplingFactor: this.samplingFactor
+ };
+
+ if ( extraData ) {
+ $.each( extraData, function ( key, value ) {
+ e[ key ] = value;
+ } );
+ }
+
+ if ( this.isEnabled() ) {
+ mw.log( 'mw.mmw.logger.DurationLogger', e );
+ }
+
+ this.log( e );
+
+ delete this.starts[ type ];
+ delete this.stops[ type ];
+
+ return this;
+ };
+
+ mw.mmv.durationLogger = new DurationLogger();
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Logger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Logger.js
new file mode 100644
index 00000000..10bad51b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.Logger.js
@@ -0,0 +1,160 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var L;
+
+ /**
+ * Abstract class providing common code for EventLogging loggers
+ *
+ * @class mw.mmv.logging.Logger
+ * @abstract
+ */
+ function Logger() {
+ this.Geo = undefined;
+ this.eventLog = undefined;
+ }
+
+ L = Logger.prototype;
+
+ /**
+ * Sampling factor key-value map.
+ *
+ * Makes the logger sample log events instead of recording each one if > 0. Disables logging if === 0.
+ * @property {number}
+ */
+ L.samplingFactor = 0;
+
+ /**
+ * EventLogging schema
+ * @property {string}
+ */
+ L.schema = '';
+
+ /**
+ * Sets the Geo object providing country information about the visitor
+ *
+ * @param {Object} Geo object containing country GeoIP information about the user
+ */
+ L.setGeo = function ( Geo ) {
+ this.Geo = Geo;
+ };
+
+ /**
+ * Sets the eventLog object providing a facility to record events
+ *
+ * @param {mw.eventLog} eventLog EventLogging instance
+ */
+ L.setEventLog = function ( eventLog ) {
+ this.eventLog = eventLog;
+ };
+
+ /**
+ * Loads the dependencies that allow us to log events
+ *
+ * @return {jQuery.Promise}
+ */
+ L.loadDependencies = function () {
+ var self = this,
+ waitForEventLog = $.Deferred();
+
+ // Waits for dom readiness because we don't want to have these dependencies loaded in the head
+ $( function () {
+ // window.Geo is currently defined in components that are loaded independently, there is no cheap
+ // way to load just that information. Either we piggy-back on something that already loaded it
+ // or we just don't have it
+ if ( window.Geo ) {
+ self.setGeo( window.Geo );
+ }
+
+ try {
+ mw.loader.using( [ 'ext.eventLogging', 'schema.' + self.schema ], function () {
+ self.setEventLog( mw.eventLog );
+ waitForEventLog.resolve();
+ } );
+ } catch ( e ) {
+ waitForEventLog.reject();
+ }
+ } );
+
+ return waitForEventLog;
+ };
+
+ /**
+ * Returns whether or not we should measure this request
+ *
+ * @return {boolean} True if this request needs to be sampled
+ */
+ L.isInSample = function () {
+ if ( !$.isNumeric( this.samplingFactor ) || this.samplingFactor < 1 ) {
+ return false;
+ }
+
+ return Math.floor( Math.random() * this.samplingFactor ) === 0;
+ };
+
+ /**
+ * Returns whether logging this event is enabled. This is intended for console logging, which
+ * (in debug mode) should be done even if the request is not being sampled, as long as logging
+ * is enabled for some sample.
+ *
+ * @return {boolean} True if this logging is enabled
+ */
+ L.isEnabled = function () {
+ return $.isNumeric( this.samplingFactor ) && this.samplingFactor >= 1;
+ };
+
+ /**
+ * True if the schema has a country field. Broken out in a separate function so it's easy to mock.
+ *
+ * @return {boolean}
+ */
+ L.schemaSupportsCountry = function () {
+ return this.eventLog && this.eventLog.schemas && // don't die if eventLog is a mock
+ this.schema in this.eventLog.schemas && // don't die if schema is not loaded
+ 'country' in this.eventLog.schemas[ this.schema ].schema.properties;
+ };
+
+ /**
+ * Logs EventLogging data while including Geo data if any
+ *
+ * @param {Object} data
+ * @return {jQuery.Promise}
+ */
+ L.log = function ( data ) {
+ var self = this;
+
+ if ( self.isInSample() ) {
+ return this.loadDependencies().then( function () {
+ // Add Geo information if there's any
+ if (
+ self.Geo && self.Geo.country !== undefined &&
+ self.schemaSupportsCountry()
+ ) {
+ data.country = self.Geo.country;
+ }
+
+ self.eventLog.logEvent( self.schema, data );
+ } );
+ } else {
+ return $.Deferred().resolve();
+ }
+ };
+
+ mw.mmv.logging = {};
+ mw.mmv.logging.Logger = Logger;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.PerformanceLogger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.PerformanceLogger.js
new file mode 100644
index 00000000..026626ff
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.PerformanceLogger.js
@@ -0,0 +1,455 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var PL;
+
+ /**
+ * Measures the network performance
+ * See <https://meta.wikimedia.org/wiki/Schema:MultimediaViewerNetworkPerformance>
+ *
+ * @class mw.mmv.logging.PerformanceLogger
+ * @extends mw.mmv.logging.Logger
+ * @constructor
+ */
+ function PerformanceLogger() {}
+
+ oo.inheritClass( PerformanceLogger, mw.mmv.logging.Logger );
+
+ PL = PerformanceLogger.prototype;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ PL.samplingFactor = mw.config.get( 'wgMultimediaViewer' ).networkPerformanceSamplingFactor;
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ PL.schema = 'MultimediaViewerNetworkPerformance';
+
+ /**
+ * Global setup that should be done while the page loads
+ */
+ PL.init = function () {
+ var performance = this.getWindowPerformance();
+
+ // by default logging is cut off after 150 resources, which is not enough in debug mode
+ // only supported by IE
+ if ( mw.config.get( 'debug' ) && performance && performance.setResourceTimingBufferSize ) {
+ performance.setResourceTimingBufferSize( 500 );
+ }
+ };
+
+ /**
+ * Gather network performance for a given URL
+ * Will only run on a sample of users/requests. Avoid using this on URLs that aren't
+ * cached by the browser, as it will consume unnecessary bandwidth for the user.
+ *
+ * @param {string} type the type of request to be measured
+ * @param {string} url URL to be measured
+ * @param {jQuery.Deferred.<string>} [extraStatsDeferred] A promise which resolves to the extra stats.
+ * @return {jQuery.Promise} A promise that resolves when the contents of the URL have been fetched
+ */
+ PL.record = function ( type, url, extraStatsDeferred ) {
+ var deferred = $.Deferred(),
+ request,
+ perf = this,
+ start;
+
+ try {
+ request = this.newXHR();
+
+ request.onprogress = function ( e ) {
+ var percent;
+
+ if ( e.lengthComputable ) {
+ percent = ( e.loaded / e.total ) * 100;
+ }
+
+ deferred.notify( request.response, percent );
+ };
+
+ request.onreadystatechange = function () {
+ var total = $.now() - start;
+
+ if ( request.readyState === 4 ) {
+ deferred.notify( request.response, 100 );
+ deferred.resolve( request.response );
+ perf.recordEntryDelayed( type, total, url, request, extraStatsDeferred );
+ }
+ };
+
+ start = $.now();
+ request.open( 'GET', url, true );
+ request.send();
+ } catch ( e ) {
+ // old browser not supporting XMLHttpRequest or CORS, or CORS is not permitted
+ return deferred.reject();
+ }
+
+ return deferred;
+ };
+
+ /**
+ * Records network performance results for a given url
+ * Will record if enough data is present and it's not a local cache hit
+ *
+ * @param {string} type the type of request to be measured
+ * @param {number} total the total load time tracked with a basic technique
+ * @param {string} url URL of that was measured
+ * @param {XMLHttpRequest} request HTTP request that just completed
+ * @param {jQuery.Deferred.<string>} [extraStatsDeferred] A promise which resolves to extra stats to be included.
+ * @return {jQuery.Promise}
+ */
+ PL.recordEntry = function ( type, total, url, request, extraStatsDeferred ) {
+ var matches,
+ logger = this,
+ stats = { type: type,
+ contentHost: window.location.host,
+ isHttps: window.location.protocol === 'https:',
+ total: total },
+ connection = this.getNavigatorConnection();
+
+ if ( !this.performanceChecked ) {
+ this.performanceChecked = {};
+ }
+
+ if ( url && url.length ) {
+ // There is no need to measure the same url more than once
+ if ( url in this.performanceChecked ) {
+ return $.Deferred().reject();
+ }
+
+ this.performanceChecked[ url ] = true;
+
+ matches = url.match( /^https?:\/\/([^/?#]+)(?:[/?#]|$)/i );
+ stats.isHttps = url.indexOf( 'https' ) === 0;
+ }
+
+ if ( !matches || matches.length !== 2 ) {
+ stats.urlHost = stats.contentHost;
+ } else {
+ stats.urlHost = matches[ 1 ];
+ }
+
+ this.populateStatsFromXhr( stats, request );
+ this.populateStatsFromPerformance( stats, url );
+
+ // Add connection information if there's any
+ if ( connection ) {
+ if ( connection.bandwidth ) {
+ if ( connection.bandwidth === Infinity ) {
+ stats.bandwidth = -1;
+ } else {
+ stats.bandwidth = Math.round( connection.bandwidth );
+ }
+ }
+
+ if ( connection.metered ) {
+ stats.metered = connection.metered;
+ }
+ }
+
+ return ( extraStatsDeferred || $.Deferred().reject() ).done( function ( extraStats ) {
+ stats = $.extend( stats, extraStats );
+ } ).always( function () {
+ logger.log( stats );
+ } );
+ };
+
+ /**
+ * Processes an XMLHttpRequest (or jqXHR) object
+ *
+ * @param {Object} stats stats object to extend with additional statistics fields
+ * @param {XMLHttpRequest} request
+ */
+ PL.populateStatsFromXhr = function ( stats, request ) {
+ var age,
+ contentLength,
+ xcache,
+ xvarnish,
+ varnishXCache,
+ lastModified;
+
+ if ( !request ) {
+ return;
+ }
+
+ stats.status = request.status;
+
+ // Chrome disallows header access for CORS image requests, even if the responose has the
+ // proper header :-/
+ contentLength = request.getResponseHeader( 'Content-Length' );
+ if ( contentLength === null ) {
+ return;
+ }
+
+ xcache = request.getResponseHeader( 'X-Cache' );
+ if ( xcache ) {
+ stats.XCache = xcache;
+ varnishXCache = this.parseVarnishXCacheHeader( xcache );
+
+ $.each( varnishXCache, function ( key, value ) {
+ stats[ key ] = value;
+ } );
+ }
+
+ xvarnish = request.getResponseHeader( 'X-Varnish' );
+ if ( xvarnish ) {
+ stats.XVarnish = xvarnish;
+ }
+
+ stats.contentLength = parseInt( contentLength, 10 );
+
+ age = parseInt( request.getResponseHeader( 'Age' ), 10 );
+ if ( !isNaN( age ) ) {
+ stats.age = age;
+ }
+
+ stats.timestamp = new Date( request.getResponseHeader( 'Date' ) ).getTime() / 1000;
+
+ lastModified = request.getResponseHeader( 'Last-Modified' );
+ if ( lastModified ) {
+ stats.lastModified = new Date( lastModified ).getTime() / 1000;
+ }
+ };
+
+ /**
+ * Populates statistics based on the Request Timing API
+ *
+ * @param {Object} stats
+ * @param {string} url
+ */
+ PL.populateStatsFromPerformance = function ( stats, url ) {
+ var performance = this.getWindowPerformance(),
+ timingEntries, timingEntry;
+
+ // If we're given an xhr and we have access to the Navigation Timing API, use it
+ if ( performance && performance.getEntriesByName ) {
+ // This could be tricky as we need to match encoding (the Request Timing API uses
+ // percent-encoded UTF-8). The main use case we are interested in is thumbnails and
+ // jQuery AJAX. jQuery uses encodeURIComponent to construct URL parameters, and
+ // thumbnail URLs come from MediaWiki API which also encodes them, so both should be
+ // all right.
+ timingEntries = performance.getEntriesByName( url );
+
+ if ( timingEntries.length ) {
+ // Let's hope it's the first request for the given URL we are interested in.
+ // This could fail in exotic cases (e.g. we send an AJAX request for a thumbnail,
+ // but it exists on the page as a normal thumbnail with the exact same size),
+ // but it's unlikely.
+ timingEntry = timingEntries[ 0 ];
+
+ stats.total = Math.round( timingEntry.duration );
+ stats.redirect = Math.round( timingEntry.redirectEnd - timingEntry.redirectStart );
+ stats.dns = Math.round( timingEntry.domainLookupEnd - timingEntry.domainLookupStart );
+ stats.tcp = Math.round( timingEntry.connectEnd - timingEntry.connectStart );
+ stats.request = Math.round( timingEntry.responseStart - timingEntry.requestStart );
+ stats.response = Math.round( timingEntry.responseEnd - timingEntry.responseStart );
+ stats.cache = Math.round( timingEntry.domainLookupStart - timingEntry.fetchStart );
+ } else if ( performance.getEntriesByType( 'resource' ).length === 150 && this.isEnabled() ) {
+ // browser stops logging after 150 entries
+ mw.log( 'performance buffer full, results are probably incorrect' );
+ }
+ }
+ };
+
+ /**
+ * Like recordEntry, but takes a jqXHR argument instead of a normal XHR one.
+ * Due to the way some parameters are retrieved, this will work best if the context option
+ * for the ajax request was not used.
+ *
+ * @param {string} type the type of request to be measured
+ * @param {number} total the total load time tracked with a basic technique
+ * @param {jqXHR} jqxhr
+ */
+ PL.recordJQueryEntry = function ( type, total, jqxhr ) {
+ var perf = this;
+
+ // We take advantage of the fact that the context of the jqXHR deferred is the AJAX
+ // settings object. The deferred has already resolved so chaining to it does not influence
+ // the timing.
+ jqxhr.done( function () {
+ var url;
+
+ if ( !this.url ) {
+ mw.log.warn( 'Cannot find URL - did you use context option?' );
+ } else {
+ url = this.url;
+ // The performance API returns absolute URLs, but the one in the settings object is
+ // usually relative.
+ if ( !url.match( /^(\w+:)?\/\// ) ) {
+ url = location.protocol + '//' + location.host + url;
+ }
+ }
+
+ if ( this.crossDomain && this.dataType === 'jsonp' ) {
+ // Cross-domain jQuery requests return a fake jqXHR object which is useless and
+ // would only cause logging errors.
+ jqxhr = undefined;
+ }
+
+ // jQuery does not expose the original XHR object, but the jqXHR wrapper is similar
+ // enogh that we will probably get away by passing it instead.
+ perf.recordEntry( type, total, url, jqxhr );
+ } );
+ };
+
+ /**
+ * Records network performance results for a given url
+ * Will record if enough data is present and it's not a local cache hit
+ * Will run after a delay to make sure the window.performance entry is present
+ *
+ * @param {string} type the type of request to be measured
+ * @param {number} total the total load time tracked with a basic technique
+ * @param {string} url URL of that was measured
+ * @param {XMLHttpRequest} request HTTP request that just completed
+ * @param {jQuery.Promise.<string>} extraStatsDeferred A promise which resolves to extra stats.
+ */
+ PL.recordEntryDelayed = function ( type, total, url, request, extraStatsDeferred ) {
+ var perf = this;
+
+ // The timeout is necessary because if there's an entry in window.performance,
+ // it hasn't been added yet at this point
+ setTimeout( function () {
+ perf.recordEntry( type, total, url, request, extraStatsDeferred );
+ }, 0 );
+ };
+
+ /**
+ * Like recordEntryDelayed, but for jQuery AJAX requests.
+ *
+ * @param {string} type the type of request to be measured
+ * @param {number} total the total load time tracked with a basic technique
+ * @param {jqXHR} jqxhr
+ */
+ PL.recordJQueryEntryDelayed = function ( type, total, jqxhr ) {
+ var perf = this;
+
+ // The timeout is necessary because if there's an entry in window.performance,
+ // it hasn't been added yet at this point
+ setTimeout( function () {
+ perf.recordJQueryEntry( type, total, jqxhr );
+ }, 0 );
+ };
+
+ /**
+ * Parses an X-Cache header from Varnish and extracts varnish information
+ *
+ * @param {string} header The X-Cache header from the request
+ * @return {Object} The parsed X-Cache data
+ */
+ PL.parseVarnishXCacheHeader = function ( header ) {
+ var parts,
+ part,
+ subparts,
+ i,
+ results = {},
+ matches;
+
+ if ( !header || !header.length ) {
+ return results;
+ }
+
+ parts = header.split( ',' );
+
+ for ( i = 0; i < parts.length; i++ ) {
+ part = parts[ i ];
+ subparts = part.trim().split( ' ' );
+
+ // If the subparts aren't space-separated, it's an unknown format, skip
+ if ( subparts.length < 2 ) {
+ continue;
+ }
+
+ matches = part.match( /\(([0-9]+)\)/ );
+
+ // If there is no number between parenthesis for a given server
+ // it's an unknown format, skip
+ if ( !matches || matches.length !== 2 ) {
+ continue;
+ }
+
+ results[ 'varnish' + ( i + 1 ) ] = subparts[ 0 ];
+ results[ 'varnish' + ( i + 1 ) + 'hits' ] = parseInt( matches[ 1 ], 10 );
+ }
+
+ return results;
+ };
+
+ /**
+ * Returns the window's Performance object
+ * Allows us to override for unit tests
+ *
+ * @return {Object} The window's Performance object
+ */
+ PL.getWindowPerformance = function () {
+ return window.performance;
+ };
+
+ /**
+ * Returns the navigator's Connection object
+ * Allows us to override for unit tests
+ *
+ * @return {Object} The navigator's Connection object
+ */
+ PL.getNavigatorConnection = function () {
+ return navigator.connection || navigator.mozConnection || navigator.webkitConnection;
+ };
+
+ /**
+ * Returns a new XMLHttpRequest object
+ * Allows us to override for unit tests
+ *
+ * @return {XMLHttpRequest} New XMLHttpRequest
+ */
+ PL.newXHR = function () {
+ return new XMLHttpRequest();
+ };
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ PL.log = function ( data ) {
+ var trackedWidths = mw.mmv.ThumbnailWidthCalculator.prototype.defaultOptions.widthBuckets.slice( 0 );
+ trackedWidths.push( 600 ); // Most common non-bucket size
+
+ // Track thumbnail load time with statsv, sampled
+ if ( this.isInSample() &&
+ data.type === 'image' &&
+ data.imageWidth > 0 &&
+ data.total > 20 &&
+ $.inArray( data.imageWidth, trackedWidths ) !== -1
+ ) {
+ mw.track( 'timing.media.thumbnail.client.' + data.imageWidth, data.total );
+ }
+
+ if ( this.isEnabled() ) {
+ mw.log( 'mw.mmv.logging.PerformanceLogger', data );
+ }
+ return mw.mmv.logging.Logger.prototype.log.call( this, data );
+ };
+
+ new PerformanceLogger().init();
+
+ mw.mmv.logging.PerformanceLogger = PerformanceLogger;
+
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ViewLogger.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ViewLogger.js
new file mode 100644
index 00000000..34dcc9a0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/logging/mmv.logging.ViewLogger.js
@@ -0,0 +1,178 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var VL;
+
+ /**
+ * Tracks how long users are viewing images for
+ *
+ * @class mw.mmv.logging.ViewLogger
+ * @extends mw.Api
+ * @constructor
+ * @param {mw.mmv.Config} config mw.mmv.Config object
+ * @param {Object} windowObject Browser window object
+ * @param {mw.mmv.logging.ActionLogger} actionLogger ActionLogger object
+ */
+ function ViewLogger( config, windowObject, actionLogger ) {
+ /**
+ * Was the last image view logged or was logging skipped?
+ * @property {boolean}
+ */
+ this.wasLastViewLogged = false;
+
+ /**
+ * Record when the user started looking at the current image
+ * @property {number}
+ */
+ this.viewStartTime = 0;
+
+ /**
+ * How long the user has been looking at the current image
+ * @property {number}
+ */
+ this.viewDuration = 0;
+
+ /**
+ * The image URL to record a virtual view for
+ * @property {string}
+ */
+ this.url = '';
+
+ /**
+ * If set, URI to send the beacon request to in order to record the virtual view
+ * @property {string}
+ */
+ this.recordVirtualViewBeaconURI = config.recordVirtualViewBeaconURI();
+
+ /**
+ * Browser window
+ * @property {Object}
+ */
+ this.window = windowObject;
+
+ /**
+ * Action logger
+ * @property {mw.mmv.logging.ActionLogger}
+ */
+ this.actionLogger = actionLogger;
+ }
+
+ VL = ViewLogger.prototype;
+
+ /**
+ * Tracks the unview event of the current image if appropriate
+ */
+ VL.unview = function () {
+ if ( !this.wasLastViewLogged ) {
+ return;
+ }
+
+ this.wasLastViewLogged = false;
+ this.actionLogger.log( 'image-unview', true );
+ };
+
+ /**
+ * Starts recording a viewing window for the current image
+ */
+ VL.startViewDuration = function () {
+ this.viewStartTime = $.now();
+ };
+
+ /**
+ * Stops recording the viewing window for the current image
+ */
+ VL.stopViewDuration = function () {
+ if ( this.viewStartTime ) {
+ this.viewDuration += $.now() - this.viewStartTime;
+ this.viewStartTime = 0;
+ }
+ };
+
+ /**
+ * Records the amount of time the current image has been viewed
+ */
+ VL.recordViewDuration = function () {
+ var uri;
+
+ this.stopViewDuration();
+
+ if ( this.recordVirtualViewBeaconURI ) {
+ uri = new mw.Uri( this.recordVirtualViewBeaconURI );
+ uri.extend( { duration: this.viewDuration,
+ uri: this.url } );
+
+ try {
+ navigator.sendBeacon( uri.toString() );
+ } catch ( e ) {
+ $.ajax( {
+ type: 'HEAD',
+ url: uri.toString()
+ } );
+ }
+
+ mw.log( 'Image has been viewed for ', this.viewDuration );
+ }
+
+ this.viewDuration = 0;
+
+ this.unview();
+ };
+
+ /**
+ * Sets up the view tracking for the current image
+ *
+ * @param {string} url URL of the image to record a virtual view for
+ */
+ VL.attach = function ( url ) {
+ var view = this;
+
+ this.url = url;
+ this.startViewDuration();
+
+ $( this.window )
+ .off( '.mmv-view-logger' )
+ .on( 'beforeunload.mmv-view-logger', function () {
+ view.recordViewDuration();
+ } )
+ .on( 'focus.mmv-view-logger', function () {
+ view.startViewDuration();
+ } )
+ .on( 'blur.mmv-view-logger', function () {
+ view.stopViewDuration();
+ } );
+ };
+
+ /*
+ * Stops listening to events
+ */
+ VL.unattach = function () {
+ $( this.window ).off( '.mmv-view-logger' );
+ this.stopViewDuration();
+ };
+
+ /**
+ * Tracks whether or not the image view event was logged or not (i.e. was it in the logging sample)
+ *
+ * @param {boolean} wasEventLogged Whether the image view event was logged
+ */
+ VL.setLastViewLogged = function ( wasEventLogged ) {
+ this.wasLastViewLogged = wasEventLogged;
+ };
+
+ mw.mmv.logging.ViewLogger = ViewLogger;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.Config.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.Config.js
new file mode 100644
index 00000000..a2989816
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.Config.js
@@ -0,0 +1,272 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var CP;
+
+ /**
+ * Contains/retrieves configuration/environment information for MediaViewer.
+ * @class mw.mmv.Config
+ * @constructor
+ * @param {Object} viewerConfig
+ * @param {mw.Map} mwConfig
+ * @param {Object} mwUser
+ * @param {mw.Api} api
+ * @param {mw.storage} localStorage
+ */
+ function Config( viewerConfig, mwConfig, mwUser, api, localStorage ) {
+ /**
+ * A plain object storing MediaViewer-specific settings
+ * @type {Object}
+ */
+ this.viewerConfig = viewerConfig;
+
+ /**
+ * The mw.config object, for dependency injection
+ * @type {mw.Map}
+ */
+ this.mwConfig = mwConfig;
+
+ /**
+ * mw.user object, for dependency injection
+ * @type {Object}
+ */
+ this.mwUser = mwUser;
+
+ /**
+ * API object, for dependency injction
+ * @type {mw.Api}
+ */
+ this.api = api;
+
+ /**
+ * The localStorage object, for dependency injection
+ * @type {mw.storage}
+ */
+ this.localStorage = localStorage;
+ }
+ CP = Config.prototype;
+
+ /**
+ * Get value from local storage or fail gracefully.
+ *
+ * @param {string} key
+ * @param {*} [fallback] value to return when key is not set or localStorage is not supported
+ * @return {string|null} stored value or fallback or null if neither exists
+ */
+ CP.getFromLocalStorage = function ( key, fallback ) {
+ var value = this.localStorage.get( key );
+
+ // localStorage will only store strings; if values `null`, `false` or
+ // `0` are set, they'll come out as `"null"`, `"false"` or `"0"`, so we
+ // can be certain that an actual null is a failure to locate the item,
+ // and false is an issue with localStorage itself
+ if ( value !== null && value !== false ) {
+ return value;
+ }
+
+ if ( value === null ) {
+ mw.log( 'Failed to fetch item ' + key + ' from localStorage' );
+ }
+
+ return fallback !== undefined ? fallback : null;
+ };
+
+ /**
+ * Set item in local storage or fail gracefully.
+ *
+ * @param {string} key
+ * @param {*} value
+ * @return {boolean} whether storing the item was successful
+ */
+ CP.setInLocalStorage = function ( key, value ) {
+ return this.localStorage.set( key, value );
+ };
+
+ /**
+ * Remove item from local storage or fail gracefully.
+ *
+ * @param {string} key
+ * @return {boolean} whether storing the item was successful
+ */
+ CP.removeFromLocalStorage = function ( key ) {
+ this.localStorage.remove( key );
+
+ // mw.storage.remove catches all exceptions and returns false if any
+ // occur, so we can't distinguish between actual issues, and
+ // localStorage not being supported - however, localStorage.removeItem
+ // is not documented to throw any errors, so nothing to worry about;
+ // when localStorage is not supported, we'll consider removal successful
+ // (it can't have been there in the first place)
+ return true;
+ };
+
+ /**
+ * Set user preference via AJAX
+ *
+ * @param {string} key
+ * @param {string} value
+ * @return {jQuery.Promise} a deferred which resolves/rejects on success/failure respectively
+ */
+ CP.setUserPreference = function ( key, value ) {
+ return this.api.saveOption( key, value );
+ };
+
+ /**
+ * Returns true if MediaViewer should handle thumbnail clicks.
+ *
+ * @return {boolean}
+ */
+ CP.isMediaViewerEnabledOnClick = function () {
+ // IMPORTANT: mmv.head.js uses the same logic but does not use this class to be lightweight. Make sure to keep it in sync.
+ return this.mwConfig.get( 'wgMediaViewer' ) && // global opt-out switch, can be set in user JS
+ this.mwConfig.get( 'wgMediaViewerOnClick' ) && // thumbnail opt-out, can be set in preferences
+ ( !this.mwUser.isAnon() || this.getFromLocalStorage( 'wgMediaViewerOnClick', '1' ) === '1' ); // thumbnail opt-out for anons
+ };
+
+ /**
+ * (Semi-)permanently stores the setting whether MediaViewer should handle thumbnail clicks.
+ * - for logged-in users, we use preferences
+ * - for anons, we use localStorage
+ * - for anons with old browsers, we don't do anything
+ *
+ * @param {boolean} enabled
+ * @return {jQuery.Promise} a deferred which resolves/rejects on success/failure respectively
+ */
+ CP.setMediaViewerEnabledOnClick = function ( enabled ) {
+ var deferred,
+ newPrefValue,
+ defaultPrefValue = this.mwConfig.get( 'wgMediaViewerEnabledByDefault' ),
+ config = this,
+ success = true;
+
+ if ( this.mwUser.isAnon() ) {
+ if ( !enabled ) {
+ success = this.setInLocalStorage( 'wgMediaViewerOnClick', '0' ); // localStorage stringifies everything, best use strings in the first place
+ } else {
+ success = this.removeFromLocalStorage( 'wgMediaViewerOnClick' );
+ }
+ if ( success ) {
+ deferred = $.Deferred().resolve();
+ } else {
+ deferred = $.Deferred().reject();
+ }
+ } else {
+ // Simulate changing the option in Special:Preferences. Turns out this is quite hard (bug 69942):
+ // we need to delete the user_properties row if the new setting is the same as the default,
+ // otherwise set '1' for enabled, '' for disabled. In theory the pref API will delete the row
+ // if the new value equals the default, but this does not always work.
+ if ( defaultPrefValue === true ) {
+ newPrefValue = enabled ? '1' : '';
+ } else {
+ // undefined will cause the API call to omit the optionvalue parameter
+ // which in turn will cause the options API to delete the row and revert the pref to default
+ newPrefValue = enabled ? '1' : undefined;
+ }
+ deferred = this.setUserPreference( 'multimediaviewer-enable', newPrefValue );
+ }
+
+ return deferred.done( function () {
+ // make the change work without a reload
+ config.mwConfig.set( 'wgMediaViewerOnClick', enabled );
+ if ( !enabled ) {
+ // set flag for showing a popup if this was a first-time disable
+ config.maybeEnableStatusInfo();
+ }
+ } );
+ };
+
+ /**
+ * True if info about enable/disable status should be displayed (mingle #719).
+ *
+ * @return {boolean}
+ */
+ CP.shouldShowStatusInfo = function () {
+ return !this.isMediaViewerEnabledOnClick() && this.getFromLocalStorage( 'mmv-showStatusInfo' ) === '1';
+ };
+
+ /**
+ * Called when MediaViewer is disabled. If status info was never displayed before, future
+ * shouldShowStatusInfo() calls will return true.
+ *
+ * @private
+ */
+ CP.maybeEnableStatusInfo = function () {
+ var currentShowStatusInfo = this.getFromLocalStorage( 'mmv-showStatusInfo' );
+ if ( currentShowStatusInfo === null ) {
+ this.setInLocalStorage( 'mmv-showStatusInfo', '1' );
+ }
+ };
+
+ /**
+ * Called when status info is displayed. Future shouldShowStatusInfo() calls will retrurn false.
+ */
+ CP.disableStatusInfo = function () {
+ this.setInLocalStorage( 'mmv-showStatusInfo', '0' );
+ };
+
+ /**
+ * Returns file extensions handled by Media Viewer.
+ *
+ * The object's keys are the file extensions.
+ * The object's values are either 'default' when Media Viewer handles that file extension
+ * directly or the name of a ResourceLoader module to load when such a file is opened.
+ *
+ * @return {Object}
+ */
+ CP.extensions = function () {
+ return this.viewerConfig.extensions;
+ };
+
+ /**
+ * Returns UI language
+ *
+ * @return {string} Language code
+ */
+ CP.language = function () {
+ return this.mwConfig.get( 'wgUserLanguage', false ) || this.mwConfig.get( 'wgContentLanguage', 'en' );
+ };
+
+ /**
+ * Returns URI of virtual view beacon or false if not set
+ *
+ * @return {string|boolean} URI
+ */
+ CP.recordVirtualViewBeaconURI = function () {
+ return this.viewerConfig.recordVirtualViewBeaconURI;
+ };
+
+ /**
+ * Returns useThumbnailGuessing flag
+ *
+ * @return {boolean}
+ */
+ CP.useThumbnailGuessing = function () {
+ return this.viewerConfig.useThumbnailGuessing;
+ };
+
+ /**
+ * Returns imageQueryParameter, if set
+ *
+ * @return {string|boolean}
+ */
+ CP.imageQueryParameter = function () {
+ return this.viewerConfig.imageQueryParameter;
+ };
+
+ mw.mmv.Config = Config;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.EmbedFileFormatter.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.EmbedFileFormatter.js
new file mode 100644
index 00000000..735173bc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.EmbedFileFormatter.js
@@ -0,0 +1,251 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var EFFP;
+
+ /**
+ * Converts data in various formats needed by the Embed sub-dialog
+ *
+ * @class mw.mmv.EmbedFileFormatter
+ * @constructor
+ */
+ function EmbedFileFormatter() {
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+
+ /**
+ * @property {mw.mmv.routing.Router} router -
+ */
+ this.router = new mw.mmv.routing.Router();
+ }
+ EFFP = EmbedFileFormatter.prototype;
+
+ /**
+ * Returns the caption of the image (possibly a fallback generated from image metadata).
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @return {string}
+ */
+ EFFP.getCaption = function ( info ) {
+ if ( info.caption ) {
+ return this.htmlUtils.htmlToText( info.caption );
+ } else {
+ return info.imageInfo.title.getNameText();
+ }
+ };
+
+ /**
+ * Helper function to generate thumbnail wikicode
+ *
+ * @param {mw.Title} title
+ * @param {number} [width]
+ * @param {string} [caption]
+ * @param {string} [alt]
+ * @return {string}
+ */
+ EFFP.getThumbnailWikitext = function ( title, width, caption, alt ) {
+ var widthSection, captionSection, altSection;
+
+ widthSection = width ? '|' + width + 'px' : '';
+ captionSection = caption ? '|' + caption : '';
+ altSection = alt ? '|alt=' + alt : '';
+
+ return '[[File:' + title.getMainText() + widthSection + '|thumb' + captionSection + altSection + ']]';
+ };
+
+ /**
+ * Helper function to generate thumbnail wikicode
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @param {number} [width]
+ * @return {string}
+ */
+ EFFP.getThumbnailWikitextFromEmbedFileInfo = function ( info, width ) {
+ return this.getThumbnailWikitext( info.imageInfo.title, width, this.getCaption( info ), info.alt );
+ };
+
+ /**
+ * Byline construction
+ *
+ * @param {string} [author] author name (can contain HTML)
+ * @param {string} [source] source name (can contain HTML)
+ * @param {string} [attribution] custom attribution line (can contain HTML)
+ * @param {Function} [formatterFunction] Format function for the text - defaults to whitelisting HTML links, but all else sanitized.
+ * @return {string} Byline (can contain HTML)
+ */
+ EFFP.getByline = function ( author, source, attribution, formatterFunction ) {
+ var formatter = this;
+
+ formatterFunction = formatterFunction || function ( txt ) {
+ return formatter.htmlUtils.htmlToTextWithLinks( txt );
+ };
+
+ if ( attribution ) {
+ attribution = attribution && formatterFunction( attribution );
+ return attribution;
+ } else {
+ author = author && formatterFunction( author );
+ source = source && formatterFunction( source );
+
+ if ( author && source ) {
+ return mw.message(
+ 'multimediaviewer-credit',
+ author,
+ source
+ ).parse();
+ } else {
+ return author || source;
+ }
+ }
+ };
+
+ /**
+ * Generates the plain text embed code for the image credit line.
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @return {string}
+ */
+ EFFP.getCreditText = function ( info ) {
+ var creditText, creditParams,
+ formatter = this,
+ shortURL = info.imageInfo.descriptionShortUrl,
+ license = info.imageInfo.license,
+ byline = this.getByline( info.imageInfo.author, info.imageInfo.source, info.imageInfo.attribution, function ( txt ) {
+ return formatter.htmlUtils.htmlToText( txt );
+ } );
+
+ // If both the byline and licence are missing, the credit text is simply the URL
+ if ( !byline && !license ) {
+ return shortURL;
+ }
+
+ creditParams = [
+ 'multimediaviewer-text-embed-credit-text-'
+ ];
+
+ if ( byline ) {
+ creditParams[ 0 ] += 'b';
+ creditParams.push( byline );
+ }
+
+ if ( license ) {
+ creditParams[ 0 ] += 'l';
+ creditParams.push( this.htmlUtils.htmlToText( license.getShortName() ) );
+ }
+
+ creditParams.push( shortURL );
+ creditText = mw.message.apply( mw, creditParams ).plain();
+
+ return creditText;
+ };
+
+ /**
+ * Generates the HTML embed code for the image credit line.
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @return {string}
+ */
+ EFFP.getCreditHtml = function ( info ) {
+ var creditText, creditParams,
+ shortURL = info.imageInfo.descriptionShortUrl,
+ shortLink = this.htmlUtils.makeLinkText( mw.message( 'multimediaviewer-html-embed-credit-link-text' ), { href: shortURL } ),
+ license = info.imageInfo.license,
+ byline = this.getByline( info.imageInfo.author, info.imageInfo.source, info.imageInfo.attribution );
+
+ if ( !byline && !license ) {
+ return shortLink;
+ }
+
+ creditParams = [
+ 'multimediaviewer-html-embed-credit-text-'
+ ];
+
+ if ( byline ) {
+ creditParams[ 0 ] += 'b';
+ creditParams.push( byline );
+ }
+ if ( license ) {
+ creditParams[ 0 ] += 'l';
+ creditParams.push( license.getShortLink() );
+ }
+
+ creditParams.push( shortLink );
+ creditText = mw.message.apply( mw, creditParams ).plain();
+
+ return creditText;
+ };
+
+ /**
+ * Returns HTML code for a link to the site of the image.
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @return {string}
+ */
+ EFFP.getSiteLink = function ( info ) {
+ var siteName = info.repoInfo.displayName,
+ siteUrl = info.repoInfo.getSiteLink();
+
+ if ( siteUrl ) {
+ return this.htmlUtils.jqueryToHtml(
+ $( '<a>' ).prop( 'href', siteUrl ).text( siteName )
+ );
+ } else {
+ return siteName;
+ }
+ };
+
+ /**
+ * Generates the HTML embed code for the image.
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @param {string} imgUrl URL to the file itself.
+ * @param {number} [width] Width to put into the image element.
+ * @param {number} [height] Height to put into the image element.
+ * @return {string} Embed code.
+ */
+ EFFP.getThumbnailHtml = function ( info, imgUrl, width, height ) {
+ return this.htmlUtils.jqueryToHtml(
+ $( '<p>' ).append(
+ $( '<a>' )
+ .attr( 'href', this.getLinkUrl( info ) )
+ .append(
+ $( '<img>' )
+ .attr( 'src', imgUrl )
+ .attr( 'alt', info.alt || info.imageInfo.title.getMainText() )
+ .attr( 'height', height )
+ .attr( 'width', width )
+ ),
+ $( '<br>' ),
+ this.getCreditHtml( info )
+ )
+ );
+ };
+
+ /**
+ * Generate a link which we will be using for sharing stuff.
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} info
+ * @return {string} URL
+ */
+ EFFP.getLinkUrl = function ( info ) {
+ var route = new mw.mmv.routing.ThumbnailRoute( info.imageInfo.title );
+ return this.router.createHashedUrl( route, info.imageInfo.descriptionUrl );
+ };
+
+ mw.mmv.EmbedFileFormatter = EmbedFileFormatter;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.HtmlUtils.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.HtmlUtils.js
new file mode 100644
index 00000000..25cc65e7
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.HtmlUtils.js
@@ -0,0 +1,269 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var HUP, cache;
+
+ /**
+ * Shared cache between HtmlUtils instances to store the results of expensive text operations.
+ *
+ * @member mw.mmv.HtmlUtils
+ * @private
+ * @static
+ * @type {{text: Object.<string, string>, textWithLinks: Object.<string, string>, textWithTags: Object.<string, string>}}
+ */
+ cache = {
+ text: {},
+ textWithLinks: {},
+ textWithTags: {}
+ };
+
+ /**
+ * Helper class that does various HTML-to-text transformations
+ *
+ * @class mw.mmv.HtmlUtils
+ * @constructor
+ */
+ function HtmlUtils() {}
+ HUP = HtmlUtils.prototype;
+
+ /**
+ * Returns a jQuery node which contains the given HTML (wrapped into a `<div>` - this is
+ * necessary since an arbitrary HTML string might not have a jQuery representation).
+ *
+ * @param {string|HTMLElement|jQuery} html
+ * @return {jQuery}
+ */
+ HUP.wrapAndJquerify = function ( html ) {
+ if ( this.isJQueryOrHTMLElement( html ) ) {
+ return $( '<div>' ).append( $( html ).clone() );
+ } else if ( typeof html === 'string' ) {
+ return $( '<div>' + html + '</div>' );
+ } else {
+ mw.log.warn( 'wrapAndJquerify: unknown type', html );
+ throw new Error( 'wrapAndJquerify: unknown type' );
+ }
+ };
+
+ /**
+ * Returns true of the object is a jQuery object or an HTMLElement, false otherwise
+ *
+ * @param {string|HTMLElement|jQuery} html
+ * @return {boolean}
+ */
+ HUP.isJQueryOrHTMLElement = function ( html ) {
+ if ( html instanceof jQuery ) {
+ return true;
+ }
+
+ if ( window.HTMLElement ) {
+ if ( html instanceof HTMLElement ) {
+ return true;
+ }
+ }
+
+ return false;
+ };
+
+ /**
+ * Filters display:none children of a node.
+ * The root element is never filtered, and generally ignored (i.e. whether the root element is
+ * visible won't affect the filtering).
+ * Works in place.
+ *
+ * @param {jQuery} $jq
+ */
+ HUP.filterInvisible = function ( $jq ) {
+ // We are not using :visible because
+ // 1) it would require appending $jq to the document which makes things complicated;
+ // 2) the main difference is that it looks for CSS rules hiding the element;
+ // since this function is intended to be used on html originating from a different
+ // document, possibly a different site, that would probably have unexpected results.
+ $jq
+ .find( '[style]' )
+ .filter( function () { return this.style.display === 'none'; } )
+ .remove();
+ };
+
+ /**
+ * Discards all nodes which do not match the whitelist,
+ * but keeps the text and whitelisted nodes inside them.
+ * Works in-place.
+ *
+ * @param {jQuery} $el
+ * @param {string} whitelist a jQuery selector string such as 'a, span, br'
+ */
+ HUP.whitelistHtml = function ( $el, whitelist ) {
+ var child, $prev,
+ $child = $el.children().first();
+
+ while ( $child && $child.length ) {
+ child = $child.get( 0 );
+
+ if ( child.nodeType !== child.ELEMENT_NODE ) {
+ return;
+ }
+
+ this.whitelistHtml( $child, whitelist );
+
+ if ( !$child.is( whitelist ) ) {
+ $prev = $child.prev();
+ $child.replaceWith( $child.contents() );
+ } else {
+ $prev = $child;
+ }
+
+ if ( $prev && $prev.length === 1 ) {
+ $child = $prev.next();
+ } else {
+ $child = $el.children().first();
+ }
+ }
+ };
+
+ /**
+ * Adds a whitespace to block elements. This is useful if you want to convert the contents
+ * to text and don't want words that are visually separate (e.g. table cells) to be fused.
+ * Works in-place.
+ *
+ * @param {jQuery} $el
+ */
+ HUP.appendWhitespaceToBlockElements = function ( $el ) {
+ // the list of what elements to add whitespace to is somewhat ad-hoc (not all of these
+ // are technically block-level elements, and a lot of block-level elements are missing)
+ // but will hopefully cover the common cases where text is fused together.
+ $el
+ .find( 'blockquote, dd, dl, dt, li, td' )
+ .before( ' ' )
+ .after( ' ' );
+ $el
+ .find( 'br, tr, p' )
+ .before( '\n' )
+ .after( '\n' );
+ };
+
+ /**
+ * Returns the HTML code for a jQuery element (only the first one if passed a set of elements).
+ * Unlike .html(), this includes HTML code for the outermost element; compare
+ * - `$('<div>').html() // ''`
+ * - `mw.mmv.HtmlUtils.jqueryToHtml( $('<div>') ) // '<div></div>'`
+ *
+ * @param {jQuery} $el
+ * @return {string}
+ */
+ HUP.jqueryToHtml = function ( $el ) {
+ // There are two possible implementations for this:
+ // 1) load innto a wrapper element and get its innerHTML;
+ // 2) use outerHTML.
+ // We go with 1) because it handles the case when a jQuery object contains something
+ // that is not an element (this can happen with e.g. $x.children() which returns text
+ // nodes as well).
+ return $( '<div>' ).append( $el ).html();
+ };
+
+ /**
+ * Cleans up superfluous whitespace.
+ * Given that the results will be displayed in a HTML environment, this doesn't have any real
+ * effect. It is mostly there to make testing easier.
+ *
+ * @protected
+ * @param {string} html a HTML (or plaintext) string
+ * @return {string}
+ */
+ HUP.mergeWhitespace = function ( html ) {
+ html = html.replace( /^\s+|\s+$/g, '' );
+ html = html.replace( /\s*\n\s*/g, '\n' );
+ html = html.replace( / {2,}/g, ' ' );
+ return html;
+ };
+
+ /**
+ * Returns the text content of a html string.
+ * Tries to give an approximation of what would be visible if the HTML would be displayed.
+ *
+ * @param {string} html
+ * @return {string}
+ */
+ HUP.htmlToText = function ( html ) {
+ var $html;
+ if ( !cache.text[ html ] ) {
+ $html = this.wrapAndJquerify( html );
+ this.filterInvisible( $html );
+ this.appendWhitespaceToBlockElements( $html );
+ cache.text[ html ] = this.mergeWhitespace( $html.text() );
+ }
+ return cache.text[ html ];
+ };
+
+ /**
+ * Returns the text content of a html string, with the `<a>`, `<i>`, `<b>` tags left intact.
+ * Tries to give an approximation of what would be visible if the HTML would be displayed.
+ *
+ * @param {string} html
+ * @return {string}
+ */
+ HUP.htmlToTextWithTags = function ( html ) {
+ var $html;
+ if ( !cache.textWithTags[ html ] ) {
+ $html = this.wrapAndJquerify( html );
+ this.filterInvisible( $html );
+ this.appendWhitespaceToBlockElements( $html );
+ this.whitelistHtml( $html, 'a, span, i, b, sup, sub' );
+ cache.textWithTags[ html ] = this.mergeWhitespace( $html.html() );
+ }
+ return cache.textWithTags[ html ];
+ };
+
+ /**
+ * Returns the text content of a html string, with the `<a>` tags left intact.
+ * Tries to give an approximation of what would be visible if the HTML would be displayed.
+ *
+ * @param {string} html
+ * @return {string}
+ */
+ HUP.htmlToTextWithLinks = function ( html ) {
+ var $html;
+ if ( !cache.textWithLinks[ html ] ) {
+ $html = this.wrapAndJquerify( html );
+ this.filterInvisible( $html );
+ this.appendWhitespaceToBlockElements( $html );
+ this.whitelistHtml( $html, 'a, span' );
+ cache.textWithLinks[ html ] = this.mergeWhitespace( $html.html() );
+ }
+ return cache.textWithLinks[ html ];
+ };
+
+ /**
+ * Generates HTML code for a link.
+ *
+ * @param {string} text Link text (plain text; will be sanitized)
+ * @param {Object} props Link attributes (should at a minumum include href; will be sanitized)
+ * @return {string}
+ */
+ HUP.makeLinkText = function ( text, props ) {
+ var key;
+ for ( key in props ) {
+ if ( !props.hasOwnProperty( key ) ) {
+ continue;
+ }
+ props[ key ] = this.htmlToText( props[ key ] );
+ }
+ return this.jqueryToHtml( $( '<a>' ).prop( props ).text( text ) );
+ };
+
+ mw.mmv.HtmlUtils = HtmlUtils;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.ThumbnailWidthCalculator.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.ThumbnailWidthCalculator.js
new file mode 100644
index 00000000..2087aa4c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.ThumbnailWidthCalculator.js
@@ -0,0 +1,172 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var TWCP;
+
+ /**
+ * A helper class for bucketing image sizes.
+ * Bucketing helps to avoid cache fragmentation and thus speed up image loading:
+ * instead of generating potentially hundreds of different thumbnail sizes, we restrict
+ * ourselves to a short list of acceptable thumbnail widths, and only ever load thumbnails
+ * of that size. Final size adjustment is done in a thumbnail.
+ *
+ * See also the [Standardized thumbnail sizes RFC][1].
+ *
+ * [1]: https://www.mediawiki.org/wiki/Talk:Requests_for_comment/Standardized_thumbnails_sizes
+ *
+ * @class mw.mmv.ThumbnailWidthCalculator
+ * @constructor
+ * @param {Object} [options]
+ * @param {number[]} [options.widthBuckets] see {@link mw.mmv.ThumbnailWidthCalculator#widthBuckets}
+ * @param {number} [options.devicePixelRatio] see {@link mw.mmv.ThumbnailWidthCalculator#devicePixelRatio};
+ * will be autodetected if omitted
+ */
+ function ThumbnailWidthCalculator( options ) {
+ options = $.extend( {}, this.defaultOptions, options );
+
+ if ( !options.widthBuckets.length ) {
+ throw new Error( 'No buckets!' );
+ }
+
+ /**
+ * List of thumbnail width bucket sizes, in pixels.
+ * @property {number[]}
+ */
+ this.widthBuckets = options.widthBuckets;
+ this.widthBuckets.sort( function ( a, b ) { return a - b; } );
+
+ /**
+ * Screen pixel count per CSS pixel.
+ * @property {number}
+ */
+ this.devicePixelRatio = options.devicePixelRatio;
+ }
+
+ TWCP = ThumbnailWidthCalculator.prototype;
+
+ /**
+ * The default list of image widths
+ * @static
+ * @property {Object}
+ */
+ TWCP.defaultOptions = {
+ // default image widths
+ widthBuckets: [
+ 320,
+ 800,
+ 1024,
+ 1280,
+ 1920,
+ 2560,
+ 2880
+ ],
+
+ // screen pixel per CSS pixel
+ devicePixelRatio: $.devicePixelRatio()
+ };
+
+ /**
+ * Finds the smallest bucket which is large enough to hold the target size
+ * (i. e. the smallest bucket whose size is equal to or greater than the target).
+ * If none of the buckets are large enough, returns the largest bucket.
+ *
+ * @param {number} target
+ * @return {number}
+ */
+ TWCP.findNextBucket = function ( target ) {
+ var i, bucket,
+ buckets = this.widthBuckets;
+
+ for ( i = 0; i < buckets.length; i++ ) {
+ bucket = buckets[ i ];
+
+ if ( bucket >= target ) {
+ return bucket;
+ }
+ }
+
+ // If we failed to find a high enough size...good luck
+ return bucket;
+ };
+
+ /**
+ * Finds the largest width for an image so that it will still fit into a given bounding box,
+ * based on the size of a sample (some smaller version of the same image, like the thumbnail
+ * shown in the article) which is used to calculate the ratio.
+ *
+ * This is for internal use, you should probably use calculateWidths() instead.
+ *
+ * @protected
+ * @param {number} boundingWidth width of the bounding box
+ * @param {number} boundingHeight height of the bounding box
+ * @param {number} sampleWidth width of the sample image
+ * @param {number} sampleHeight height of the sample image
+ * @return {number} the largest width so that the scaled version of the sample image fits
+ * into the bounding box (either horizontal or vertical edges touch on both sides).
+ */
+ TWCP.calculateFittingWidth = function ( boundingWidth, boundingHeight, sampleWidth, sampleHeight ) {
+ if ( ( boundingWidth / boundingHeight ) > ( sampleWidth / sampleHeight ) ) {
+ // we are limited by height; we need to calculate the max width that fits
+ return Math.round( ( sampleWidth / sampleHeight ) * boundingHeight );
+ } else {
+ // simple case, ratio tells us we're limited by width
+ return boundingWidth;
+ }
+ };
+
+ /**
+ * Finds the largest width for an image so that it will still fit into a given bounding box,
+ * based on the size of a sample (some smaller version of the same image, like the thumbnail
+ * shown in the article) which is used to calculate the ratio.
+ *
+ * Returns two values, a CSS width which is the size in pixels that should be used so the image
+ * fits exactly into the bounding box, and a real width which should be the size of the
+ * downloaded image in pixels. The two will be different for two reasons:
+ * - Images are bucketed for more efficient caching, so the real width will always be one of
+ * the numbers in this.widthBuckets. The resulting thumbnail will be slightly larger than
+ * the bounding box so that it takes roughly the same amount of bandwidth and
+ * looks decent when resized by the browser.
+ * - For devices with high pixel density (multiple actual pixels per CSS pixel) we want to use
+ * a larger image so that there will be roughly one image pixel per physical display pixel.
+ *
+ * @param {number} boundingWidth width of the bounding box, in CSS pixels
+ * @param {number} boundingHeight height of the bounding box, in CSS pixels
+ * @param {number} sampleWidth width of the sample image (in whatever - only used for aspect ratio)
+ * @param {number} sampleHeight height of the sample image (in whatever - only used for aspect ratio)
+ * @return {mw.mmv.model.ThumbnailWidth}
+ */
+
+ TWCP.calculateWidths = function ( boundingWidth, boundingHeight, sampleWidth, sampleHeight ) {
+ var cssWidth,
+ cssHeight,
+ screenPixelWidth,
+ bucketedWidth,
+ ratio = sampleHeight / sampleWidth;
+
+ cssWidth = this.calculateFittingWidth( boundingWidth, boundingHeight, sampleWidth, sampleHeight );
+ cssHeight = Math.round( cssWidth * ratio );
+
+ screenPixelWidth = cssWidth * this.devicePixelRatio;
+
+ bucketedWidth = this.findNextBucket( screenPixelWidth );
+
+ return new mw.mmv.model.ThumbnailWidth( cssWidth, cssHeight, screenPixelWidth, bucketedWidth );
+ };
+
+ mw.mmv.ThumbnailWidthCalculator = ThumbnailWidthCalculator;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.base.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.base.js
new file mode 100644
index 00000000..400438a3
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.base.js
@@ -0,0 +1,34 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+// Included on every page which has images so keep it lightweight.
+( function ( mw ) {
+ mw.mmv = {
+ /**
+ * Feature-detects SVG support. MuyltimediaViewer uses SVG icons extensively and is
+ * unusable without them.
+ *
+ * @member mw.mmv.MultimediaViewer
+ * @return {boolean}
+ */
+ isBrowserSupported: function () {
+ // From modernizr 2.6.1
+ var ns = { svg: 'http://www.w3.org/2000/svg' };
+ return !!document.createElementNS && !!document.createElementNS( ns.svg, 'svg' ).createSVGRect;
+ }
+ };
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.autostart.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.autostart.js
new file mode 100644
index 00000000..7fde43f3
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.autostart.js
@@ -0,0 +1,34 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+// This file is used to do the global initialization that we want on the real pages,
+// but do not want in the tests.
+( function ( mw, $ ) {
+ var bootstrap;
+
+ if ( !mw.mmv.isBrowserSupported() ) {
+ return;
+ }
+
+ bootstrap = new mw.mmv.MultimediaViewerBootstrap();
+
+ $( function () {
+ bootstrap.setupEventHandlers();
+ } );
+
+ mw.mmv.bootstrap = bootstrap;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.js
new file mode 100644
index 00000000..1165ca02
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.js
@@ -0,0 +1,631 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var MMVB;
+
+ /**
+ * Bootstrap code listening to thumb clicks checking the initial location.hash
+ * Loads the mmv and opens it if necessary
+ *
+ * @class mw.mmv.MultimediaViewerBootstrap
+ */
+ function MultimediaViewerBootstrap() {
+ // Exposed for tests
+ this.hoverWaitDuration = 200;
+
+ // TODO lazy-load config and htmlUtils
+
+ /** @property {mw.mmv.Config} config - */
+ this.config = new mw.mmv.Config(
+ mw.config.get( 'wgMultimediaViewer', {} ),
+ mw.config,
+ mw.user,
+ new mw.Api(),
+ mw.storage
+ );
+
+ this.validExtensions = this.config.extensions();
+
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+
+ /**
+ * This flag is set to true when we were unable to load the viewer.
+ * @property {boolean}
+ */
+ this.viewerIsBroken = false;
+
+ this.thumbsReadyDeferred = $.Deferred();
+ this.thumbs = [];
+ this.$thumbs = null; // will be set by processThumbs
+
+ // find and setup all thumbs on this page
+ // this will run initially and then every time the content changes,
+ // e.g. via a VE edit or pagination in a multipage file
+ mw.hook( 'wikipage.content' ).add( $.proxy( this, 'processThumbs' ) );
+
+ this.browserHistory = window.history;
+ }
+
+ MMVB = MultimediaViewerBootstrap.prototype;
+
+ /**
+ * Loads the mmv module asynchronously and passes the thumb data to it
+ *
+ * @param {boolean} [setupOverlay]
+ * @return {jQuery.Promise}
+ */
+ MMVB.loadViewer = function ( setupOverlay ) {
+ var deferred = $.Deferred(),
+ bs = this,
+ viewer,
+ message;
+
+ // Don't load if someone has specifically stopped us from doing so
+ if ( mw.config.get( 'wgMediaViewer' ) !== true ) {
+ return deferred.reject();
+ }
+
+ // FIXME setupOverlay is a quick hack to avoid setting up and immediately
+ // removing the overlay on a not-MMV -> not-MMV hash change.
+ // loadViewer is called on every click and hash change and setting up
+ // the overlay is not needed on all of those; this logic really should
+ // not be here.
+ if ( setupOverlay ) {
+ bs.setupOverlay();
+ }
+
+ mw.loader.using( 'mmv', function () {
+ try {
+ viewer = bs.getViewer();
+ } catch ( e ) {
+ message = e.message;
+ if ( e.stack ) {
+ message += '\n' + e.stack;
+ }
+ deferred.reject( message );
+ return;
+ }
+ deferred.resolve( viewer );
+ }, function ( error ) {
+ deferred.reject( error.message );
+ } );
+
+ return deferred.promise()
+ .then(
+ function ( viewer ) {
+ if ( !bs.viewerInitialized ) {
+ if ( bs.thumbs.length ) {
+ viewer.initWithThumbs( bs.thumbs );
+ }
+
+ bs.viewerInitialized = true;
+ }
+ return viewer;
+ },
+ function ( message ) {
+ mw.log.warn( message );
+ bs.cleanupOverlay();
+ bs.viewerIsBroken = true;
+ mw.notify( 'Error loading MediaViewer: ' + message );
+ return $.Deferred().reject( message );
+ }
+ );
+ };
+
+ /**
+ * Processes all thumbs found on the page
+ *
+ * @param {jQuery} $content Element to search for thumbs
+ */
+ MMVB.processThumbs = function ( $content ) {
+ var bs = this;
+
+ this.$thumbs = $content.find(
+ '.gallery .image img, ' +
+ 'a.image img, ' +
+ '#file a img, ' +
+ 'figure[typeof*="mw:Image"] > *:first-child > img, ' +
+ 'span[typeof*="mw:Image"] img'
+ );
+
+ try {
+ this.$thumbs.each( function ( i, thumb ) {
+ bs.processThumb( thumb );
+ } );
+ } finally {
+ this.thumbsReadyDeferred.resolve();
+ // now that we have set up our real click handler we can we can remove the temporary
+ // handler added in mmv.head.js which just replays clicks to the real handler
+ $( document ).off( 'click.mmv-head' );
+ }
+ };
+
+ /**
+ * Check if this thumbnail should be handled by MediaViewer
+ *
+ * @param {jQuery} $thumb the thumbnail (an `<img>` element) in question
+ * @return {boolean}
+ */
+ MMVB.isAllowedThumb = function ( $thumb ) {
+ var selectors = [
+ '.metadata', // this is inside an informational template like {{refimprove}} on enwiki.
+ '.noviewer', // MediaViewer has been specifically disabled for this image
+ '.noarticletext', // we are on an error page for a non-existing article, the image is part of some template
+ '#siteNotice',
+ 'ul.mw-gallery-slideshow li.gallerybox' // thumbnails of a slideshow gallery
+ ];
+ return $thumb.closest( selectors.join( ', ' ) ).length === 0;
+
+ };
+
+ /**
+ * Processes a thumb
+ *
+ * @param {Object} thumb
+ */
+ MMVB.processThumb = function ( thumb ) {
+ var title,
+ bs = this,
+ $thumb = $( thumb ),
+ $link = $thumb.closest( 'a.image, [typeof*="mw:Image"] > a' ),
+ $thumbContain = $link.closest( '.thumb, [typeof*="mw:Image"]' ),
+ $enlarge = $thumbContain.find( '.magnify a' ),
+ link = $link.prop( 'href' ),
+ alt = $thumb.attr( 'alt' ),
+ isFilePageMainThumb = $thumb.closest( '#file' ).length > 0;
+
+ if ( isFilePageMainThumb ) {
+ // main thumbnail (file preview area) of a file page
+ // if this is a PDF filetype thumbnail, it can trick us,
+ // so we short-circuit that logic and use the file page title
+ // instead of the thumbnail logic.
+ title = mw.Title.newFromText( mw.config.get( 'wgTitle' ), mw.config.get( 'wgNamespaceNumber' ) );
+ } else {
+ title = mw.Title.newFromImg( $thumb );
+ }
+
+ if ( !title || !title.getExtension() || !( title.getExtension().toLowerCase() in bs.validExtensions ) ) {
+ // Short-circuit event handler and interface setup, because
+ // we can't do anything for this filetype
+ return;
+ }
+
+ if ( !bs.isAllowedThumb( $thumb ) ) {
+ return;
+ }
+
+ if ( $thumbContain.length ) {
+ // If this is a thumb, we preload JS/CSS when the mouse cursor hovers the thumb container (thumb image + caption + border)
+ $thumbContain.mouseenter( function () {
+ // There is no point preloading if clicking the thumb won't open Media Viewer
+ if ( !bs.config.isMediaViewerEnabledOnClick() ) {
+ return;
+ }
+ bs.preloadOnHoverTimer = setTimeout( function () {
+ mw.loader.load( 'mmv' );
+ }, bs.hoverWaitDuration );
+ } ).mouseleave( function () {
+ if ( bs.preloadOnHoverTimer ) {
+ clearTimeout( bs.preloadOnHoverTimer );
+ }
+ } );
+ }
+
+ if ( isFilePageMainThumb ) {
+ this.processFilePageThumb( $thumb, title );
+ return;
+ }
+
+ // This is the data that will be passed onto the mmv
+ this.thumbs.push( {
+ thumb: thumb,
+ $thumb: $thumb,
+ title: title,
+ link: link,
+ alt: alt,
+ caption: this.findCaption( $thumbContain, $link ) } );
+
+ $link.add( $enlarge ).click( function ( e ) {
+ return bs.click( this, e, title );
+ } );
+ };
+
+ /**
+ * Processes the main thumbnail of a file page by adding some buttons
+ * below to open MediaViewer.
+ *
+ * @param {jQuery} $thumb
+ * @param {mw.Title} title
+ */
+ MMVB.processFilePageThumb = function ( $thumb, title ) {
+ var $link,
+ $configLink,
+ $filepageButtons,
+ bs = this,
+ link = $thumb.closest( 'a' ).prop( 'href' );
+
+ // remove the buttons (and the clearing element) if they are already there
+ // this should not happen (at least until we support paged media) but just in case
+ $( '.mw-mmv-filepage-buttons' ).next().addBack().remove();
+
+ $link = $( '<a>' )
+ // It won't matter because we catch the click event anyway, but
+ // give the user some URL to see.
+ .prop( 'href', link )
+ .addClass( 'mw-mmv-view-expanded mw-ui-button mw-ui-icon mw-ui-icon-before' )
+ .text( mw.message( 'multimediaviewer-view-expanded' ).text() );
+
+ $configLink = $( '<a>' )
+ .prop( 'href', $thumb.closest( 'a' ).prop( 'href' ) )
+ .addClass( 'mw-mmv-view-config mw-ui-button mw-ui-icon mw-ui-icon-element' )
+ .text( mw.message( 'multimediaviewer-view-config' ).text() );
+
+ $filepageButtons = $( '<div>' )
+ .addClass( 'mw-ui-button-group mw-mmv-filepage-buttons' )
+ .append( $link, $configLink );
+
+ $( '.fullMedia' ).append(
+ $filepageButtons,
+ $( '<div>' )
+ .css( 'clear', 'both' )
+ );
+
+ this.thumbs.push( {
+ thumb: $thumb.get( 0 ),
+ $thumb: $thumb,
+ title: title,
+ link: link
+ } );
+
+ $link.click( function () {
+ if ( bs.statusInfoDialog ) {
+ bs.statusInfoDialog.close();
+ }
+ bs.openImage( this, title );
+ return false;
+ } );
+
+ $configLink.click( function () {
+ if ( bs.statusInfoDialog ) {
+ bs.statusInfoDialog.close();
+ }
+ bs.openImage( this, title ).then( function () {
+ $( document ).trigger( 'mmv-options-open' );
+ } );
+ return false;
+ } );
+
+ if ( this.config.shouldShowStatusInfo() ) {
+ this.config.disableStatusInfo();
+ this.showStatusInfo();
+ }
+ };
+
+ /**
+ * Shows a popup notifying the user
+ */
+ MMVB.showStatusInfo = function () {
+ var bs = this;
+
+ mw.loader.using( 'mmv.ui.tipsyDialog' ).done( function () {
+ /** @property {mw.mmv.ui.TipsyDialog} statusInfoDialog popup on the file page explaining how to re-enable */
+ bs.statusInfoDialog = new mw.mmv.ui.TipsyDialog( $( '.mw-mmv-view-expanded' ), { gravity: 'sw' } );
+ bs.statusInfoDialog.setContent(
+ mw.message( 'multimediaviewer-disable-info-title' ).plain(),
+ mw.message( 'multimediaviewer-disable-info' ).escaped()
+ );
+ // tipsy mispositions the tooltip, probably because it does the positioning before the buttons are
+ // displayed and the page is reflown. Adding some delay seems to help.
+ window.setTimeout( function () {
+ bs.statusInfoDialog.open();
+ }, 1000 );
+ } );
+ };
+
+ /**
+ * Finds the caption for an image.
+ *
+ * @param {jQuery} $thumbContain The container for the thumbnail.
+ * @param {jQuery} $link The link that encompasses the thumbnail.
+ * @return {string|undefined} Unsafe HTML may be present - caution
+ */
+ MMVB.findCaption = function ( $thumbContain, $link ) {
+ var $thumbCaption, $potentialCaptions;
+
+ if ( !$thumbContain.length ) {
+ return $link.prop( 'title' ) || undefined;
+ }
+
+ $potentialCaptions = $thumbContain.find( '.thumbcaption, figcaption' );
+ if ( $potentialCaptions.length < 2 ) {
+ $thumbCaption = $potentialCaptions.eq( 0 );
+ } else {
+ // Template:Multiple_image or some such; try to find closest caption to the image
+ $thumbCaption = $link.closest( ':has(> .thumbcaption)', $thumbContain )
+ .find( '> .thumbcaption' );
+ }
+
+ if ( !$thumbCaption.length ) { // gallery, maybe
+ $thumbCaption = $thumbContain
+ .closest( '.gallerybox' )
+ .not( function () {
+ // do not treat categories as galleries - the autogenerated caption they have is not helpful
+ return $thumbContain.closest( '#mw-category-media' ).length;
+ } )
+ .not( function () {
+ // do not treat special file related pages as galleries
+ var $specialFileRelatedPages = $(
+ '.page-Special_NewFiles, ' +
+ '.page-Special_MostLinkedFiles,' +
+ '.page-Special_MostGloballyLinkedFiles, ' +
+ '.page-Special_UncategorizedFiles, ' +
+ '.page-Special_UnusedFiles'
+ );
+ return $thumbContain.closest( $specialFileRelatedPages ).length;
+ } )
+ .find( '.gallerytext' );
+ }
+
+ if ( $thumbCaption.find( '.magnify' ).length ) {
+ $thumbCaption = $thumbCaption.clone();
+ $thumbCaption.find( '.magnify' ).remove();
+ }
+
+ return this.htmlUtils.htmlToTextWithTags( $thumbCaption.html() || '' );
+ };
+
+ /**
+ * Opens MediaViewer and loads the given thumbnail. Requires processThumb() to be called first.
+ *
+ * @param {HTMLElement} element Clicked element
+ * @param {string} title File title
+ * @return {jQuery.Promise}
+ */
+ MMVB.openImage = function ( element, title ) {
+ var $element = $( element );
+
+ mw.mmv.durationLogger.start( [ 'click-to-first-image', 'click-to-first-metadata' ] );
+
+ if ( $element.is( 'a.image, [typeof*="mw:Image"] > a' ) ) {
+ mw.mmv.actionLogger.log( 'thumbnail' );
+ } else if ( $element.is( '.magnify a' ) ) {
+ mw.mmv.actionLogger.log( 'enlarge' );
+ }
+
+ this.ensureEventHandlersAreSetUp();
+
+ return this.loadViewer( true ).then( function ( viewer ) {
+ viewer.loadImageByTitle( title, true );
+ } );
+ };
+
+ /**
+ * Handles a click event on a link
+ *
+ * @param {HTMLElement} element Clicked element
+ * @param {jQuery.Event} e jQuery event object
+ * @param {string} title File title
+ * @return {boolean} a value suitable for an event handler (ie. true if the click should be handled
+ * by the browser).
+ */
+ MMVB.click = function ( element, e, title ) {
+ // Do not interfere with non-left clicks or if modifier keys are pressed.
+ if ( ( e.button !== 0 && e.which !== 1 ) || e.altKey || e.ctrlKey || e.shiftKey || e.metaKey ) {
+ return true;
+ }
+
+ // Don't load if someone has specifically stopped us from doing so
+ if ( !this.config.isMediaViewerEnabledOnClick() ) {
+ return true;
+ }
+
+ // Don't load if we already tried loading and it failed
+ if ( this.viewerIsBroken ) {
+ return true;
+ }
+
+ this.openImage( element, title );
+
+ // calling this late so that in case of errors users at least get to the file page
+ e.preventDefault();
+
+ return false;
+ };
+
+ /**
+ * Returns true if the hash part of the current URL is one that's owned by MMV.
+ *
+ * @return {boolean}
+ * @private
+ */
+ MMVB.isViewerHash = function () {
+ return window.location.hash.indexOf( '#mediaviewer/' ) === 0 ||
+ window.location.hash.indexOf( '#/media/' ) === 0;
+ };
+
+ /**
+ * Handles the browser location hash on pageload or hash change
+ *
+ * @param {boolean} initialHash Whether this is called for the hash that came with the pageload
+ */
+ MMVB.hash = function ( initialHash ) {
+ var bootstrap = this;
+
+ // There is no point loading the mmv if it isn't loaded yet for hash changes unrelated to the mmv
+ // Such as anchor links on the page
+ if ( !this.viewerInitialized && !this.isViewerHash() ) {
+ return;
+ }
+
+ if ( this.skipNextHashHandling ) {
+ this.skipNextHashHandling = false;
+ return;
+ }
+
+ this.loadViewer( this.isViewerHash() ).then( function ( viewer ) {
+ viewer.hash();
+ // this is an ugly temporary fix to avoid a black screen of death when
+ // the page is loaded with an invalid MMV url
+ if ( !viewer.isOpen ) {
+ bootstrap.cleanupOverlay();
+ } else if ( initialHash ) {
+ mw.mmv.actionLogger.log( 'hash-load' );
+ } else {
+ mw.mmv.actionLogger.log( 'history-navigation' );
+ }
+ } );
+ };
+
+ /**
+ * Handles hash change requests coming from mmv
+ *
+ * @param {jQuery.Event} e Custom mmv-hash event
+ */
+ MMVB.internalHashChange = function ( e ) {
+ var hash = e.hash,
+ title = e.title;
+
+ // The advantage of using pushState when it's available is that it has to ability to truly
+ // clear the hash, not leaving "#" in the history
+ // An entry with "#" in the history has the side-effect of resetting the scroll position when navigating the history
+ if ( this.browserHistory && this.browserHistory.pushState ) {
+ // In order to truly clear the hash, we need to reconstruct the hash-free URL
+ if ( hash === '#' ) {
+ hash = window.location.href.replace( /#.*$/, '' );
+ }
+
+ window.history.pushState( null, title, hash );
+ } else {
+ // Since we voluntarily changed the hash, we don't want MMVB.hash (which will trigger on hashchange event) to treat it
+ this.skipNextHashHandling = true;
+
+ window.location.hash = hash;
+ }
+
+ document.title = title;
+ };
+
+ /**
+ * Instantiates a new viewer if necessary
+ *
+ * @return {mw.mmv.MultimediaViewer}
+ */
+ MMVB.getViewer = function () {
+ if ( this.viewer === undefined ) {
+ this.viewer = new mw.mmv.MultimediaViewer( this.config );
+ this.viewer.setupEventHandlers();
+ mw.mmv.viewer = this.viewer;
+ }
+
+ return this.viewer;
+ };
+
+ /**
+ * Listens to events on the window/document
+ */
+ MMVB.setupEventHandlers = function () {
+ var self = this;
+
+ /** @property {boolean} eventHandlersHaveBeenSetUp tracks domready event handler state */
+ this.eventHandlersHaveBeenSetUp = true;
+
+ $( window ).on( this.browserHistory && this.browserHistory.pushState ? 'popstate.mmvb' : 'hashchange', function () {
+ self.hash();
+ } );
+
+ // Interpret any hash that might already be in the url
+ self.hash( true );
+
+ $( document ).on( 'mmv-hash', function ( e ) {
+ self.internalHashChange( e );
+ } ).on( 'mmv-cleanup-overlay', function () {
+ self.cleanupOverlay();
+ } );
+ };
+
+ /**
+ * Cleans up event handlers, used for tests
+ */
+ MMVB.cleanupEventHandlers = function () {
+ $( window ).off( 'hashchange popstate.mmvb' );
+ $( document ).off( 'mmv-hash' );
+ this.eventHandlersHaveBeenSetUp = false;
+ };
+
+ /**
+ * Makes sure event handlers are set up properly via MultimediaViewerBootstrap.setupEventHandlers().
+ * Called before loading the main mmv module. At this point, event handers for MultimediaViewerBootstrap
+ * should have been set up, but due to bug 70756 it cannot be guaranteed.
+ */
+ MMVB.ensureEventHandlersAreSetUp = function () {
+ if ( !this.eventHandlersHaveBeenSetUp ) {
+ this.setupEventHandlers();
+ }
+ };
+
+ /**
+ * Sets up the overlay while the viewer loads
+ */
+ MMVB.setupOverlay = function () {
+ var $body = $( document.body );
+
+ // There are situations where we can call setupOverlay while the overlay is already there,
+ // such as inside this.hash(). In that case, do nothing
+ if ( $body.hasClass( 'mw-mmv-lightbox-open' ) ) {
+ return;
+ }
+
+ if ( !this.$overlay ) {
+ this.$overlay = $( '<div>' )
+ .addClass( 'mw-mmv-overlay' );
+ }
+
+ this.savedScrollTop = $( window ).scrollTop();
+
+ $body.addClass( 'mw-mmv-lightbox-open' )
+ .append( this.$overlay );
+ };
+
+ /**
+ * Cleans up the overlay
+ */
+ MMVB.cleanupOverlay = function () {
+ var bootstrap = this;
+
+ $( document.body ).removeClass( 'mw-mmv-lightbox-open' );
+
+ if ( this.$overlay ) {
+ this.$overlay.remove();
+ }
+
+ if ( this.savedScrollTop !== undefined ) {
+ // setTimeout because otherwise Chrome will scroll back to top after the popstate event handlers run
+ setTimeout( function () {
+ $( window ).scrollTop( bootstrap.savedScrollTop );
+ bootstrap.savedScrollTop = undefined;
+ } );
+ }
+ };
+
+ MMVB.whenThumbsReady = function () {
+ return this.thumbsReadyDeferred.promise();
+ };
+
+ mw.mmv.MultimediaViewerBootstrap = MultimediaViewerBootstrap;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.less
new file mode 100644
index 00000000..82547243
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.bootstrap.less
@@ -0,0 +1,69 @@
+.mw-mmv-overlay {
+ position: fixed;
+ top: 0;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ z-index: 1000;
+ background-color: #000;
+}
+
+body.mw-mmv-lightbox-open {
+ overflow-y: auto;
+
+ /* stylelint-disable selector-max-id */
+ #mw-page-base,
+ #mw-head-base,
+ #mw-navigation,
+ #content,
+ #footer,
+ #globalWrapper { // monobook
+ /** Stop the article from scrolling in the background - skin-specific but works in any browser */
+ display: none;
+ }
+ /* stylelint-enable selector-max-id */
+
+ > * {
+ /** Stop the article from scrolling in the background - works with any skin but needs modern browser */
+ display: none;
+ }
+ > .mw-mmv-overlay,
+ > .mw-mmv-wrapper {
+ display: block;
+ }
+}
+
+.mw-mmv-filepage-buttons {
+ margin-top: 5px;
+
+ .mw-mmv-view-expanded,
+ .mw-mmv-view-config {
+ display: block;
+ // Work around some weirdness of MW-UI buttons. T127052
+ line-height: inherit;
+ }
+
+ .mw-mmv-view-expanded.mw-ui-icon:before {
+ /* @embed */
+ background-image: url( img/expand.svg );
+ }
+
+ .mw-mmv-view-config.mw-ui-icon:before {
+ /* @embed */
+ background-image: url( img/gear.svg );
+ opacity: 0.75;
+
+ &:hover {
+ opacity: 1;
+ }
+ }
+}
+
+.mw-mmv-button {
+ background-color: transparent;
+ min-width: 0;
+ border: 0;
+ padding: 0;
+ overflow-x: hidden;
+ text-indent: -9999em;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.globals.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.globals.less
new file mode 100644
index 00000000..2a4aec1c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.globals.less
@@ -0,0 +1,31 @@
+// Height of the area of the metadata bar which is visible without scrolling.
+@metadatabar-above-fold-height: 86px;
+
+// adjust for @metadatabar-below-fold-pushup-height wide bottom padding - that area will be overlapped
+// by the revealed part of the below-the-fold content
+@metadatabar-above-fold-inner-height: @metadatabar-above-fold-height - @metadatabar-below-fold-pushup-height;
+
+// Height of the top part of the "below-fold" content which is actually above the fold, as a scrolling affordance
+@metadatabar-below-fold-pushup-height: 30px;
+
+@panel-above-fold-background-color: #fff;
+
+// Height of the progress bar
+@progress-bar-height: 14px;
+
+// Height of dialogs
+@dialog-height: 350px;
+
+// Border radius for dialogs
+@border-radius: 2px;
+
+// Arrow size for dialogs
+@arrow-size: 20px;
+@arrow-border-size: 2px;
+
+@dialog-warning-color: #ffd36e;
+
+// Some button things that get included all over
+@navbutton-width: 18px;
+@buttons-offset-right: 5px;
+@buttons-offset-each-top: 37px;
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.head.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.head.js
new file mode 100644
index 00000000..069309b5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.head.js
@@ -0,0 +1,59 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var $document = $( document ),
+ start;
+
+ if ( !mw.mmv.isBrowserSupported() ) {
+ return;
+ }
+
+ // If the user disabled MediaViewer in his preferences, we do not set up click handling.
+ // This is loaded before user JS so we cannot check wgMediaViewer.
+ if (
+ mw.config.get( 'wgMediaViewerOnClick' ) !== true ||
+ mw.user.isAnon() && mw.storage.get( 'wgMediaViewerOnClick', '1' ) !== '1'
+ ) {
+ return;
+ }
+
+ $document.on( 'click.mmv-head', 'a.image', function ( e ) {
+ // Do not interfere with non-left clicks or if modifier keys are pressed.
+ // Also, make sure we do not get in a loop.
+ if ( ( e.button !== 0 && e.which !== 1 ) || e.altKey || e.ctrlKey || e.shiftKey || e.metaKey || e.replayed ) {
+ return;
+ }
+
+ start = $.now();
+
+ // We wait for document readiness because mw.loader.using writes to the DOM
+ // which can cause a blank page if it happens before DOM readiness
+ $( function () {
+ mw.loader.using( [ 'mmv.bootstrap.autostart' ], function () {
+ mw.mmv.bootstrap.whenThumbsReady().then( function () {
+ mw.mmv.durationLogger.stop( 'early-click-to-replay-click', start ).record( 'early-click-to-replay-click' );
+
+ // We have to copy the properties, passing e doesn't work. Probably because of preventDefault()
+ $( e.target ).trigger( { type: 'click', which: 1, replayed: true } );
+ } );
+ } );
+ } );
+
+ e.preventDefault();
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.js
new file mode 100644
index 00000000..8d164baa
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.js
@@ -0,0 +1,1031 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var MMVP,
+ comingFromHashChange = false;
+
+ /**
+ * Analyses the page, looks for image content and sets up the hooks
+ * to manage the viewing experience of such content.
+ *
+ * @class mw.mmv.MultimediaViewer
+ * @constructor
+ * @param {mw.mmv.Config} config mw.mmv.Config object
+ */
+ function MultimediaViewer( config ) {
+ var apiCacheMaxAge = 86400, // one day (24 hours * 60 min * 60 sec)
+ apiCacheFiveMinutes = 300; // 5 min * 60 sec
+
+ /**
+ * @property {mw.mmv.Config}
+ * @private
+ */
+ this.config = config;
+
+ /**
+ * @property {mw.mmv.provider.Image}
+ * @private
+ */
+ this.imageProvider = new mw.mmv.provider.Image( this.config.imageQueryParameter() );
+
+ /**
+ * @property {mw.mmv.provider.ImageInfo}
+ * @private
+ */
+ this.imageInfoProvider = new mw.mmv.provider.ImageInfo( new mw.mmv.logging.Api( 'imageinfo' ), {
+ language: this.config.language(),
+ maxage: apiCacheFiveMinutes
+ } );
+
+ /**
+ * @property {mw.mmv.provider.FileRepoInfo}
+ * @private
+ */
+ this.fileRepoInfoProvider = new mw.mmv.provider.FileRepoInfo( new mw.mmv.logging.Api( 'filerepoinfo' ),
+ { maxage: apiCacheMaxAge } );
+
+ /**
+ * @property {mw.mmv.provider.ThumbnailInfo}
+ * @private
+ */
+ this.thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( new mw.mmv.logging.Api( 'thumbnailinfo' ),
+ { maxage: apiCacheMaxAge } );
+
+ /**
+ * @property {mw.mmv.provider.ThumbnailInfo}
+ * @private
+ */
+ this.guessedThumbnailInfoProvider = new mw.mmv.provider.GuessedThumbnailInfo();
+
+ /**
+ * Image index on page.
+ * @property {number}
+ */
+ this.currentIndex = 0;
+
+ /**
+ * @property {mw.mmv.routing.Router} router -
+ */
+ this.router = new mw.mmv.routing.Router();
+
+ /**
+ * UI object used to display the pictures in the page.
+ * @property {mw.mmv.LightboxInterface}
+ * @private
+ */
+ this.ui = new mw.mmv.LightboxInterface();
+
+ /**
+ * How many sharp images have been displayed in Media Viewer since the pageload
+ * @property {number}
+ */
+ this.imageDisplayedCount = 0;
+
+ /**
+ * How many data-filled metadata panels have been displayed in Media Viewer since the pageload
+ * @property {number}
+ */
+ this.metadataDisplayedCount = 0;
+
+ /** @property {string} documentTitle base document title, MediaViewer will expand this */
+ this.documentTitle = document.title;
+
+ /**
+ * @property {mw.mmv.logging.ViewLogger} view -
+ */
+ this.viewLogger = new mw.mmv.logging.ViewLogger( this.config, window, mw.mmv.actionLogger );
+ }
+
+ MMVP = MultimediaViewer.prototype;
+
+ /**
+ * Initialize the lightbox interface given an array of thumbnail
+ * objects.
+ *
+ * @param {Object[]} thumbs Complex structure...TODO, document this better.
+ */
+ MMVP.initWithThumbs = function ( thumbs ) {
+ var i, thumb;
+
+ this.thumbs = thumbs;
+
+ for ( i = 0; i < this.thumbs.length; i++ ) {
+ thumb = this.thumbs[ i ];
+ // Create a LightboxImage object for each legit image
+ thumb.image = this.createNewImage(
+ thumb.$thumb.prop( 'src' ),
+ thumb.link,
+ thumb.title,
+ i,
+ thumb.thumb,
+ thumb.caption,
+ thumb.alt
+ );
+
+ thumb.extraStatsDeferred = $.Deferred();
+ }
+ };
+
+ /**
+ * Create an image object for the lightbox to use.
+ *
+ * @protected
+ * @param {string} fileLink Link to the file - generally a thumb URL
+ * @param {string} filePageLink Link to the File: page
+ * @param {mw.Title} fileTitle Represents the File: page
+ * @param {number} index Which number file this is
+ * @param {HTMLImageElement} thumb The thumbnail that represents this image on the page
+ * @param {string} [caption] The caption, if any.
+ * @param {string} [alt] The alt text of the image
+ * @return {mw.mmv.LightboxImage}
+ */
+ MMVP.createNewImage = function ( fileLink, filePageLink, fileTitle, index, thumb, caption, alt ) {
+ var thisImage = new mw.mmv.LightboxImage( fileLink, filePageLink, fileTitle, index, thumb, caption, alt ),
+ $thumb = $( thumb );
+
+ thisImage.filePageLink = filePageLink;
+ thisImage.filePageTitle = fileTitle;
+ thisImage.index = index;
+ thisImage.thumbnail = thumb;
+ thisImage.originalWidth = parseInt( $thumb.data( 'file-width' ), 10 );
+ thisImage.originalHeight = parseInt( $thumb.data( 'file-height' ), 10 );
+
+ return thisImage;
+ };
+
+ /**
+ * Handles resize events in viewer.
+ *
+ * @protected
+ * @param {mw.mmv.LightboxInterface} ui lightbox that got resized
+ */
+ MMVP.resize = function ( ui ) {
+ var imageWidths, canvasDimensions,
+ viewer = this,
+ image = this.thumbs[ this.currentIndex ].image,
+ ext = this.thumbs[ this.currentIndex ].title.ext.toLowerCase();
+
+ this.preloadThumbnails();
+
+ if ( image ) {
+ imageWidths = ui.canvas.getCurrentImageWidths();
+ canvasDimensions = ui.canvas.getDimensions();
+
+ mw.mmv.dimensionLogger.logDimensions( imageWidths, canvasDimensions, 'resize' );
+
+ this.fetchThumbnailForLightboxImage(
+ image, imageWidths.real
+ ).then( function ( thumbnail, image ) {
+ image.className = ext;
+ viewer.setImage( ui, thumbnail, image, imageWidths );
+ }, function ( error ) {
+ viewer.ui.canvas.showError( error );
+ } );
+ }
+
+ this.updateControls();
+ };
+
+ /**
+ * Updates positioning of controls, usually after a resize event.
+ */
+ MMVP.updateControls = function () {
+ var numImages = this.thumbs ? this.thumbs.length : 0,
+ showNextButton = this.currentIndex < ( numImages - 1 ),
+ showPreviousButton = this.currentIndex > 0;
+
+ this.ui.updateControls( showNextButton, showPreviousButton );
+ };
+
+ /**
+ * Loads and sets the specified image. It also updates the controls.
+ *
+ * @param {mw.mmv.LightboxInterface} ui image container
+ * @param {mw.mmv.model.Thumbnail} thumbnail thumbnail information
+ * @param {HTMLImageElement} imageElement
+ * @param {mw.mmv.model.ThumbnailWidth} imageWidths
+ */
+ MMVP.setImage = function ( ui, thumbnail, imageElement, imageWidths ) {
+ ui.canvas.setImageAndMaxDimensions( thumbnail, imageElement, imageWidths );
+ this.updateControls();
+ };
+
+ /**
+ * Loads a specified image.
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @param {HTMLImageElement} initialImage A thumbnail to use as placeholder while the image loads
+ */
+ MMVP.loadImage = function ( image, initialImage ) {
+ var imageWidths,
+ canvasDimensions,
+ imagePromise,
+ metadataPromise,
+ pluginsPromise,
+ start,
+ viewer = this,
+ $initialImage = $( initialImage ),
+ extraStatsDeferred = $.Deferred();
+
+ pluginsPromise = this.loadExtensionPlugins( image.filePageTitle.ext.toLowerCase() );
+
+ this.currentIndex = image.index;
+
+ this.currentImageFileTitle = image.filePageTitle;
+
+ if ( !this.isOpen ) {
+ this.ui.open();
+ this.isOpen = true;
+ } else {
+ this.ui.empty();
+ }
+ this.setHash();
+
+ // At this point we can't show the thumbnail because we don't
+ // know what size it should be. We still assign it to allow for
+ // size calculations in getCurrentImageWidths, which needs to know
+ // the aspect ratio
+ $initialImage.hide();
+ $initialImage.addClass( 'mw-mmv-placeholder-image' );
+ $initialImage.addClass( image.filePageTitle.ext.toLowerCase() );
+
+ this.ui.canvas.set( image, $initialImage );
+
+ this.preloadImagesMetadata();
+ this.preloadThumbnails();
+ // this.preloadFullscreenThumbnail( image ); // disabled - #474
+
+ imageWidths = this.ui.canvas.getCurrentImageWidths();
+ canvasDimensions = this.ui.canvas.getDimensions();
+
+ start = $.now();
+
+ mw.mmv.dimensionLogger.logDimensions( imageWidths, canvasDimensions, 'show' );
+
+ imagePromise = this.fetchThumbnailForLightboxImage( image, imageWidths.real, extraStatsDeferred );
+
+ this.resetBlurredThumbnailStates();
+ if ( imagePromise.state() === 'pending' ) {
+ this.displayPlaceholderThumbnail( image, $initialImage, imageWidths );
+ }
+
+ this.setupProgressBar( image, imagePromise, imageWidths.real );
+
+ metadataPromise = this.fetchSizeIndependentLightboxInfo( image.filePageTitle );
+
+ imagePromise.then(
+ // done
+ function ( thumbnail, imageElement ) {
+ if ( viewer.currentIndex !== image.index ) {
+ return;
+ }
+
+ if ( viewer.imageDisplayedCount++ === 0 ) {
+ mw.mmv.durationLogger.stop( 'click-to-first-image' );
+
+ metadataPromise.then( function ( imageInfo, repoInfo ) {
+ if ( imageInfo && imageInfo.anonymizedUploadDateTime ) {
+ mw.mmv.durationLogger.record( 'click-to-first-image', {
+ uploadTimestamp: imageInfo.anonymizedUploadDateTime
+ } );
+ }
+
+ return $.Deferred().resolve( imageInfo, repoInfo );
+ } );
+ }
+
+ imageElement.className = 'mw-mmv-final-image ' + image.filePageTitle.ext.toLowerCase();
+ imageElement.alt = image.alt;
+
+ $.when( metadataPromise, pluginsPromise ).then( function ( metadata ) {
+ $( document ).trigger( $.Event( 'mmv-metadata', { viewer: viewer, image: image, imageInfo: metadata[ 0 ] } ) );
+ } );
+
+ viewer.displayRealThumbnail( thumbnail, imageElement, imageWidths, $.now() - start );
+
+ return $.Deferred().resolve( thumbnail, imageElement );
+ },
+ // fail
+ function ( error ) {
+ viewer.ui.canvas.showError( error );
+ return $.Deferred().reject( error );
+ }
+ );
+
+ metadataPromise.then(
+ // done
+ function ( imageInfo, repoInfo ) {
+ extraStatsDeferred.resolve( { uploadTimestamp: imageInfo.anonymizedUploadDateTime } );
+
+ if ( viewer.currentIndex !== image.index ) {
+ return;
+ }
+
+ if ( viewer.metadataDisplayedCount++ === 0 ) {
+ mw.mmv.durationLogger.stop( 'click-to-first-metadata' ).record( 'click-to-first-metadata' );
+ }
+
+ viewer.ui.panel.setImageInfo( image, imageInfo, repoInfo );
+
+ // File reuse steals a bunch of information from the DOM, so do it last
+ viewer.ui.setFileReuseData( imageInfo, repoInfo, image.caption, image.alt );
+
+ return $.Deferred().resolve( imageInfo, repoInfo );
+ },
+ // fail
+ function ( error ) {
+ extraStatsDeferred.reject();
+
+ if ( viewer.currentIndex === image.index ) {
+ // Set title to caption or file name if caption is not available;
+ // see setTitle() in mmv.ui.metadataPanel for extended caption fallback
+ viewer.ui.panel.showError( image.caption || image.filePageTitle.getNameText(), error );
+ }
+
+ return $.Deferred().reject( error );
+ }
+ );
+
+ $.when( imagePromise, metadataPromise ).then( function () {
+ if ( viewer.currentIndex !== image.index ) {
+ return;
+ }
+
+ viewer.ui.panel.scroller.animateMetadataOnce();
+ viewer.preloadDependencies();
+ } );
+
+ this.comingFromHashChange = false;
+ };
+
+ /**
+ * Loads an image by its title
+ *
+ * @param {mw.Title} title
+ * @param {boolean} updateHash Viewer should update the location hash when true
+ */
+ MMVP.loadImageByTitle = function ( title, updateHash ) {
+ var viewer = this;
+
+ if ( !this.thumbs || !this.thumbs.length ) {
+ return;
+ }
+
+ this.comingFromHashChange = !updateHash;
+
+ $.each( this.thumbs, function ( idx, thumb ) {
+ if ( thumb.title.getPrefixedText() === title.getPrefixedText() ) {
+ viewer.loadImage( thumb.image, thumb.$thumb.clone()[ 0 ], true );
+ return false;
+ }
+ } );
+ };
+
+ /**
+ * Image loading progress. Keyed by image (database) name + '|' + thumbnail width in pixels,
+ * value is undefined, 'blurred' or 'real' (meaning respectively that no thumbnail is shown
+ * yet / the thumbnail that existed on the page is shown, enlarged and blurred / the real,
+ * correct-size thumbnail is shown).
+ *
+ * @private
+ * @property {Object.<string, string>}
+ */
+ MMVP.thumbnailStateCache = {};
+
+ /**
+ * Resets the cross-request states needed to handle the blurred thumbnail logic.
+ */
+ MMVP.resetBlurredThumbnailStates = function () {
+ /**
+ * Stores whether the real image was loaded and displayed already.
+ * This is reset when paging, so it is not necessarily accurate.
+ * @property {boolean}
+ */
+ this.realThumbnailShown = false;
+
+ /**
+ * Stores whether the a blurred placeholder is being displayed in place of the real image.
+ * When a placeholder is displayed, but it is not blurred, this is false.
+ * This is reset when paging, so it is not necessarily accurate.
+ * @property {boolean}
+ */
+ this.blurredThumbnailShown = false;
+ };
+
+ /**
+ * Display the real, full-resolution, thumbnail that was fetched with fetchThumbnail
+ *
+ * @param {mw.mmv.model.Thumbnail} thumbnail
+ * @param {HTMLImageElement} imageElement
+ * @param {mw.mmv.model.ThumbnailWidth} imageWidths
+ * @param {number} loadTime Time it took to load the thumbnail
+ */
+ MMVP.displayRealThumbnail = function ( thumbnail, imageElement, imageWidths, loadTime ) {
+ var viewer = this;
+
+ this.realThumbnailShown = true;
+
+ this.setImage( this.ui, thumbnail, imageElement, imageWidths );
+
+ // We only animate unblurWithAnimation if the image wasn't loaded from the cache
+ // A load in < 10ms is considered to be a browser cache hit
+ if ( this.blurredThumbnailShown && loadTime > 10 ) {
+ this.ui.canvas.unblurWithAnimation();
+ } else {
+ this.ui.canvas.unblur();
+ }
+
+ this.viewLogger.attach( thumbnail.url );
+
+ mw.mmv.actionLogger.log( 'image-view' ).then( function ( wasEventLogged ) {
+ viewer.viewLogger.setLastViewLogged( wasEventLogged );
+ } );
+ };
+
+ /**
+ * Display the blurred thumbnail from the page
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @param {jQuery} $initialImage The thumbnail from the page
+ * @param {mw.mmv.model.ThumbnailWidth} imageWidths
+ * @param {boolean} [recursion=false] for internal use, never set this when calling from outside
+ */
+ MMVP.displayPlaceholderThumbnail = function ( image, $initialImage, imageWidths, recursion ) {
+ var viewer = this,
+ size = { width: image.originalWidth, height: image.originalHeight };
+
+ // If the actual image has already been displayed, there's no point showing the blurry one.
+ // This can happen if the API request to get the original image size needed to show the
+ // placeholder thumbnail takes longer then loading the actual thumbnail.
+ if ( this.realThumbnailShown ) {
+ return;
+ }
+
+ // Width/height of the original image are added to the HTML by MediaViewer via a PHP hook,
+ // and can be missing in exotic circumstances, e. g. when the extension has only been
+ // enabled recently and the HTML cache has not cleared yet. If that is the case, we need
+ // to fetch the size from the API first.
+ if ( !size.width || !size.height ) {
+ if ( recursion ) {
+ // this should not be possible, but an infinite recursion is nasty
+ // business, so we make a sanity check
+ throw new Error( 'MediaViewer internal error: displayPlaceholderThumbnail recursion' );
+ }
+ this.imageInfoProvider.get( image.filePageTitle ).done( function ( imageInfo ) {
+ // Make sure the user has not navigated away while we were waiting for the size
+ if ( viewer.currentIndex === image.index ) {
+ image.originalWidth = imageInfo.width;
+ image.originalHeight = imageInfo.height;
+ viewer.displayPlaceholderThumbnail( image, $initialImage, imageWidths, true );
+ }
+ } );
+ } else {
+ this.blurredThumbnailShown = this.ui.canvas.maybeDisplayPlaceholder(
+ size, $initialImage, imageWidths );
+ }
+ };
+
+ /**
+ * Image loading progress. Keyed by image (database) name + '|' + thumbnail width in pixels,
+ * value is a number between 0-100.
+ *
+ * @private
+ * @property {Object.<string, number>}
+ */
+ MMVP.progressCache = {};
+
+ /**
+ * Displays a progress bar for the image loading, if necessary, and sets up handling of
+ * all the related callbacks.
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @param {jQuery.Promise.<mw.mmv.model.Thumbnail, HTMLImageElement>} imagePromise
+ * @param {number} imageWidth needed for caching progress (FIXME)
+ */
+ MMVP.setupProgressBar = function ( image, imagePromise, imageWidth ) {
+ var viewer = this,
+ progressBar = viewer.ui.panel.progressBar,
+ key = image.filePageTitle.getPrefixedDb() + '|' + imageWidth;
+
+ if ( !this.progressCache[ key ] ) {
+ // Animate progress bar to 5 to give a sense that something is happening, and make sure
+ // the progress bar is noticeable, even if we're sitting at 0% stuck waiting for
+ // server-side processing, such as thumbnail (re)generation
+ progressBar.jumpTo( 0 );
+ progressBar.animateTo( 5 );
+ viewer.progressCache[ key ] = 5;
+ } else {
+ progressBar.jumpTo( this.progressCache[ key ] );
+ }
+
+ // FIXME would be nice to have a "filtered" promise which does not fire when the image is not visible
+ imagePromise.then(
+ // done
+ function ( thumbnail, imageElement ) {
+ viewer.progressCache[ key ] = 100;
+ if ( viewer.currentIndex === image.index ) {
+ // Fallback in case the browser doesn't have fancy progress updates
+ progressBar.animateTo( 100 );
+
+ // Hide progress bar, we're done
+ progressBar.hide();
+ }
+
+ return $.Deferred().resolve( thumbnail, imageElement );
+ },
+ // fail
+ function ( error ) {
+ viewer.progressCache[ key ] = 100;
+
+ if ( viewer.currentIndex === image.index ) {
+ // Hide progress bar on error
+ progressBar.hide();
+ }
+
+ return $.Deferred().reject( error );
+ },
+ // progress
+ function ( progress ) {
+ // We pretend progress is always at least 5%, so progress events below 5% should be ignored
+ // 100 will be handled by the done handler, do not mix two animations
+ if ( progress >= 5 && progress < 100 ) {
+ viewer.progressCache[ key ] = progress;
+
+ // Touch the UI only if the user is looking at this image
+ if ( viewer.currentIndex === image.index ) {
+ progressBar.animateTo( progress );
+ }
+ }
+
+ return progress;
+ }
+ );
+ };
+
+ /**
+ * Preload this many prev/next images to speed up navigation.
+ * (E.g. preloadDistance = 3 means that the previous 3 and the next 3 images will be loaded.)
+ * Preloading only happens when the viewer is open.
+ * @property {number}
+ */
+ MMVP.preloadDistance = 1;
+
+ /**
+ * Stores image metadata preloads, so they can be cancelled.
+ * @property {mw.mmv.model.TaskQueue}
+ */
+ MMVP.metadataPreloadQueue = null;
+
+ /**
+ * Stores image thumbnail preloads, so they can be cancelled.
+ * @property {mw.mmv.model.TaskQueue}
+ */
+ MMVP.thumbnailPreloadQueue = null;
+
+ /**
+ * Orders lightboximage indexes for preloading. Works similar to $.each, except it only takes
+ * the callback argument. Calls the callback with each lightboximage index in some sequence
+ * that is ideal for preloading.
+ *
+ * @private
+ * @param {function(number, mw.mmv.LightboxImage)} callback
+ */
+ MMVP.eachPrealoadableLightboxIndex = function ( callback ) {
+ var i;
+ for ( i = 0; i <= this.preloadDistance; i++ ) {
+ if ( this.currentIndex + i < this.thumbs.length ) {
+ callback(
+ this.currentIndex + i,
+ this.thumbs[ this.currentIndex + i ].image,
+ this.thumbs[ this.currentIndex + i ].extraStatsDeferred
+ );
+ }
+ if ( i && this.currentIndex - i >= 0 ) { // skip duplicate for i==0
+ callback(
+ this.currentIndex - i,
+ this.thumbs[ this.currentIndex - i ].image,
+ this.thumbs[ this.currentIndex - i ].extraStatsDeferred
+ );
+ }
+ }
+ };
+
+ /**
+ * A helper function to fill up the preload queues.
+ * taskFactory(lightboxImage) should return a preload task for the given lightboximage.
+ *
+ * @private
+ * @param {function(mw.mmv.LightboxImage): function()} taskFactory
+ * @return {mw.mmv.model.TaskQueue}
+ */
+ MMVP.pushLightboxImagesIntoQueue = function ( taskFactory ) {
+ var queue = new mw.mmv.model.TaskQueue();
+
+ this.eachPrealoadableLightboxIndex( function ( i, lightboxImage, extraStatsDeferred ) {
+ queue.push( taskFactory( lightboxImage, extraStatsDeferred ) );
+ } );
+
+ return queue;
+ };
+
+ /**
+ * Cancels in-progress image metadata preloading.
+ */
+ MMVP.cancelImageMetadataPreloading = function () {
+ if ( this.metadataPreloadQueue ) {
+ this.metadataPreloadQueue.cancel();
+ }
+ };
+
+ /**
+ * Cancels in-progress image thumbnail preloading.
+ */
+ MMVP.cancelThumbnailsPreloading = function () {
+ if ( this.thumbnailPreloadQueue ) {
+ this.thumbnailPreloadQueue.cancel();
+ }
+ };
+
+ /**
+ * Preload metadata for next and prev N image (N = MMVP.preloadDistance).
+ * Two images will be loaded at a time (one forward, one backward), with closer images
+ * being loaded sooner.
+ */
+ MMVP.preloadImagesMetadata = function () {
+ var viewer = this;
+
+ this.cancelImageMetadataPreloading();
+
+ this.metadataPreloadQueue = this.pushLightboxImagesIntoQueue( function ( lightboxImage, extraStatsDeferred ) {
+ return function () {
+ var metadatapromise = viewer.fetchSizeIndependentLightboxInfo( lightboxImage.filePageTitle );
+ metadatapromise.done( function ( imageInfo ) {
+ extraStatsDeferred.resolve( { uploadTimestamp: imageInfo.anonymizedUploadDateTime } );
+ } ).fail( function () {
+ extraStatsDeferred.reject();
+ } );
+ return metadatapromise;
+ };
+ } );
+
+ this.metadataPreloadQueue.execute();
+ };
+
+ /**
+ * Preload thumbnails for next and prev N image (N = MMVP.preloadDistance).
+ * Two images will be loaded at a time (one forward, one backward), with closer images
+ * being loaded sooner.
+ */
+ MMVP.preloadThumbnails = function () {
+ var viewer = this;
+
+ this.cancelThumbnailsPreloading();
+
+ this.thumbnailPreloadQueue = this.pushLightboxImagesIntoQueue( function ( lightboxImage, extraStatsDeferred ) {
+ return function () {
+ var imageWidths, canvasDimensions;
+
+ // viewer.ui.canvas.getLightboxImageWidths needs the viewer to be open
+ // because it needs to read the size of visible elements
+ if ( !viewer.isOpen ) {
+ return;
+ }
+
+ imageWidths = viewer.ui.canvas.getLightboxImageWidths( lightboxImage );
+ canvasDimensions = viewer.ui.canvas.getDimensions();
+
+ mw.mmv.dimensionLogger.logDimensions( imageWidths, canvasDimensions, 'preload' );
+
+ return viewer.fetchThumbnailForLightboxImage( lightboxImage, imageWidths.real, extraStatsDeferred );
+ };
+ } );
+
+ this.thumbnailPreloadQueue.execute();
+ };
+
+ /**
+ * Preload the fullscreen size of the current image.
+ *
+ * @param {mw.mmv.LightboxImage} image
+ */
+ MMVP.preloadFullscreenThumbnail = function ( image ) {
+ var imageWidths = this.ui.canvas.getLightboxImageWidthsForFullscreen( image ),
+ canvasDimensions = this.ui.canvas.getDimensions( true );
+
+ mw.mmv.dimensionLogger.logDimensions( imageWidths, canvasDimensions, 'preload' );
+ this.fetchThumbnailForLightboxImage( image, imageWidths.real );
+ };
+
+ /**
+ * Loads all the size-independent information needed by the lightbox (image metadata, repo
+ * information).
+ *
+ * @param {mw.Title} fileTitle Title of the file page for the image.
+ * @return {jQuery.Promise.<mw.mmv.model.Image, mw.mmv.model.Repo>}
+ */
+ MMVP.fetchSizeIndependentLightboxInfo = function ( fileTitle ) {
+ var imageInfoPromise = this.imageInfoProvider.get( fileTitle ),
+ repoInfoPromise = this.fileRepoInfoProvider.get( fileTitle );
+
+ return $.when(
+ imageInfoPromise, repoInfoPromise
+ ).then( function ( imageInfo, repoInfoHash ) {
+ return $.Deferred().resolve( imageInfo, repoInfoHash[ imageInfo.repo ] );
+ } );
+ };
+
+ /**
+ * Loads size-dependent components of a lightbox - the thumbnail model and the image itself.
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @param {number} width the width of the requested thumbnail
+ * @param {jQuery.Deferred.<string>} [extraStatsDeferred] Promise that resolves to the image's upload timestamp when the metadata is loaded
+ * @return {jQuery.Promise.<mw.mmv.model.Thumbnail, HTMLImageElement>}
+ */
+ MMVP.fetchThumbnailForLightboxImage = function ( image, width, extraStatsDeferred ) {
+ return this.fetchThumbnail(
+ image.filePageTitle,
+ width,
+ image.src,
+ image.originalWidth,
+ image.originalHeight,
+ extraStatsDeferred
+ );
+ };
+
+ /**
+ * Loads size-dependent components of a lightbox - the thumbnail model and the image itself.
+ *
+ * @param {mw.Title} fileTitle
+ * @param {number} width the width of the requested thumbnail
+ * @param {string} [sampleUrl] a thumbnail URL for the same file (but with different size) (might be missing)
+ * @param {number} [originalWidth] the width of the original, full-sized file (might be missing)
+ * @param {number} [originalHeight] the height of the original, full-sized file (might be missing)
+ * @param {jQuery.Deferred.<string>} [extraStatsDeferred] Promise that resolves to the image's upload timestamp when the metadata is loaded
+ * @return {jQuery.Promise.<mw.mmv.model.Thumbnail, HTMLImageElement>} A promise resolving to
+ * a thumbnail model and an <img> element. It might or might not have progress events which
+ * return a single number.
+ */
+ MMVP.fetchThumbnail = function ( fileTitle, width, sampleUrl, originalWidth, originalHeight, extraStatsDeferred ) {
+ var viewer = this,
+ guessing = false,
+ combinedDeferred = $.Deferred(),
+ thumbnailPromise,
+ imagePromise;
+
+ if ( originalWidth && width > originalWidth ) {
+ // Do not request images larger than the original image
+ // This would be possible (but still unwanted) for SVG images
+ width = originalWidth;
+ }
+
+ if (
+ sampleUrl && originalWidth && originalHeight &&
+ this.config.useThumbnailGuessing()
+ ) {
+ guessing = true;
+ thumbnailPromise = this.guessedThumbnailInfoProvider.get(
+ fileTitle, sampleUrl, width, originalWidth, originalHeight
+ ).then( null, function () { // catch rejection, use fallback
+ return viewer.thumbnailInfoProvider.get( fileTitle, width );
+ } );
+ } else {
+ thumbnailPromise = this.thumbnailInfoProvider.get( fileTitle, width );
+ }
+
+ // Add thumbnail width to the extra stats passed to the performance log
+ extraStatsDeferred = $.when( extraStatsDeferred || {} ).then( function ( extraStats ) {
+ extraStats.imageWidth = width;
+ return extraStats;
+ } );
+
+ imagePromise = thumbnailPromise.then( function ( thumbnail ) {
+ return viewer.imageProvider.get( thumbnail.url, extraStatsDeferred );
+ } );
+
+ if ( guessing ) {
+ // If we guessed wrong, need to retry with real URL on failure.
+ // As a side effect this introduces an extra (harmless) retry of a failed thumbnailInfoProvider.get call
+ // because thumbnailInfoProvider.get is already called above when guessedThumbnailInfoProvider.get fails.
+ imagePromise = imagePromise.then( null, function () {
+ return viewer.thumbnailInfoProvider.get( fileTitle, width ).then( function ( thumbnail ) {
+ return viewer.imageProvider.get( thumbnail.url, extraStatsDeferred );
+ } );
+ } );
+ }
+
+ // In jQuery<3, $.when used to also relay notify, but that is no longer
+ // the case - but we still want to pass it along...
+ $.when( thumbnailPromise, imagePromise ).then( combinedDeferred.resolve, combinedDeferred.reject );
+ imagePromise.then( null, null, function ( arg, progress ) {
+ combinedDeferred.notify( progress );
+ } );
+ return combinedDeferred;
+ };
+
+ /**
+ * Loads an image at a specified index in the viewer's thumbnail array.
+ *
+ * @param {number} index
+ */
+ MMVP.loadIndex = function ( index ) {
+ var thumb;
+
+ if ( index < this.thumbs.length && index >= 0 ) {
+ this.viewLogger.recordViewDuration();
+
+ thumb = this.thumbs[ index ];
+ this.loadImage( thumb.image, thumb.$thumb.clone()[ 0 ] );
+ }
+ };
+
+ /**
+ * Opens the next image
+ */
+ MMVP.nextImage = function () {
+ mw.mmv.actionLogger.log( 'next-image' );
+ this.loadIndex( this.currentIndex + 1 );
+ };
+
+ /**
+ * Opens the previous image
+ */
+ MMVP.prevImage = function () {
+ mw.mmv.actionLogger.log( 'prev-image' );
+ this.loadIndex( this.currentIndex - 1 );
+ };
+
+ /**
+ * Handles close event coming from the lightbox
+ */
+ MMVP.close = function () {
+ var windowTitle;
+
+ this.viewLogger.recordViewDuration();
+ this.viewLogger.unattach();
+
+ windowTitle = this.createDocumentTitle( null );
+
+ if ( comingFromHashChange === false ) {
+ $( document ).trigger( $.Event( 'mmv-hash', { hash: '#', title: windowTitle } ) );
+ } else {
+ comingFromHashChange = false;
+ }
+
+ // This has to happen after the hash reset, because setting the hash to # will reset the page scroll
+ $( document ).trigger( $.Event( 'mmv-cleanup-overlay' ) );
+
+ this.isOpen = false;
+ };
+
+ /**
+ * Handles a hash change coming from the browser
+ */
+ MMVP.hash = function () {
+ var route = this.router.parseLocation( window.location );
+
+ if ( route instanceof mw.mmv.routing.ThumbnailRoute ) {
+ document.title = this.createDocumentTitle( route.fileTitle );
+ this.loadImageByTitle( route.fileTitle );
+ } else if ( this.isOpen ) {
+ // This allows us to avoid the mmv-hash event that normally happens on close
+ comingFromHashChange = true;
+
+ document.title = this.createDocumentTitle( null );
+ if ( this.ui ) {
+ // FIXME triggers mmv-close event, which calls viewer.close()
+ this.ui.unattach();
+ } else {
+ this.close();
+ }
+ }
+ };
+
+ MMVP.setHash = function () {
+ var route, windowTitle, hashFragment;
+ if ( !this.comingFromHashChange ) {
+ route = new mw.mmv.routing.ThumbnailRoute( this.currentImageFileTitle );
+ hashFragment = '#' + this.router.createHash( route );
+ windowTitle = this.createDocumentTitle( this.currentImageFileTitle );
+ $( document ).trigger( $.Event( 'mmv-hash', { hash: hashFragment, title: windowTitle } ) );
+ }
+ };
+
+ /**
+ * Creates a string which can be shown as document title (the text at the top of the browser window).
+ *
+ * @param {mw.Title|null} imageTitle the title object for the image which is displayed; null when the
+ * viewer is being closed
+ * @return {string}
+ */
+ MMVP.createDocumentTitle = function ( imageTitle ) {
+ if ( imageTitle ) {
+ return imageTitle.getNameText() + ' - ' + this.documentTitle;
+ } else {
+ return this.documentTitle;
+ }
+ };
+
+ /**
+ * @event mmv-close
+ * Fired when the viewer is closed. This is used by the ligthbox to notify the main app.
+ */
+ /**
+ * @event mmv-next
+ * Fired when the user requests the next image.
+ */
+ /**
+ * @event mmv-prev
+ * Fired when the user requests the previous image.
+ */
+ /**
+ * @event mmv-resize-end
+ * Fired when the screen size changes. Debounced to avoid continous triggering while resizing with a mouse.
+ */
+ /**
+ * @event mmv-request-thumbnail
+ * Used by components to request a thumbnail URL for the current thumbnail, with a given size.
+ * @param {number} size
+ */
+ /**
+ * Registers all event handlers
+ */
+ MMVP.setupEventHandlers = function () {
+ var viewer = this;
+
+ this.ui.connect( this, {
+ next: 'nextImage',
+ prev: 'prevImage'
+ } );
+
+ $( document ).on( 'mmv-close.mmvp', function () {
+ viewer.close();
+ } ).on( 'mmv-resize-end.mmvp', function () {
+ viewer.resize( viewer.ui );
+ } ).on( 'mmv-request-thumbnail.mmvp', function ( e, size ) {
+ if ( viewer.currentImageFileTitle ) {
+ return viewer.thumbnailInfoProvider.get( viewer.currentImageFileTitle, size );
+ } else {
+ return $.Deferred().reject();
+ }
+ } ).on( 'mmv-viewfile.mmvp', function () {
+ viewer.imageInfoProvider.get( viewer.currentImageFileTitle ).done( function ( imageInfo ) {
+ document.location = imageInfo.url;
+ } );
+ } );
+ };
+
+ /**
+ * Unregisters all event handlers. Currently only used in tests.
+ */
+ MMVP.cleanupEventHandlers = function () {
+ $( document ).off( 'mmv-close.mmvp mmv-resize-end.mmvp' );
+
+ this.ui.disconnect( this );
+ };
+
+ /**
+ * Preloads JS and CSS dependencies that aren't needed to display the first image, but could be needed later
+ */
+ MMVP.preloadDependencies = function () {
+ mw.loader.load( [ 'mmv.ui.reuse.shareembed', 'moment' ] );
+ };
+
+ /**
+ * Loads the RL module defined for a given file extension, if any
+ *
+ * @param {string} extension File extension
+ * @return {jQuery.Promise}
+ */
+ MMVP.loadExtensionPlugins = function ( extension ) {
+ var deferred = $.Deferred(),
+ config = this.config.extensions();
+
+ if ( !( extension in config ) || config[ extension ] === 'default' ) {
+ return deferred.resolve();
+ }
+
+ mw.loader.using( config[ extension ], function () {
+ deferred.resolve();
+ } );
+
+ return deferred;
+ };
+
+ mw.mmv.MultimediaViewer = MultimediaViewer;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboximage.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboximage.js
new file mode 100644
index 00000000..865666d5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboximage.js
@@ -0,0 +1,63 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+
+ /**
+ * Represents an image on the page.
+ *
+ * @class mw.mmv.LightboxImage
+ * @constructor
+ * @param {string} fileLink Link to the file - generally a thumb URL
+ * @param {string} filePageLink Link to the File: page
+ * @param {mw.Title} fileTitle Represents the File: page
+ * @param {number} index Which number file this is
+ * @param {HTMLImageElement} thumb The thumbnail that represents this image on the page
+ * @param {string} [caption] The caption, if any.
+ * @param {string} [alt] The alt text of the image
+ */
+ function LightboxImage( fileLink, filePageLink, fileTitle, index, thumb, caption, alt ) {
+ /** @property {string} Link to the file - generally a thumb URL */
+ this.src = fileLink;
+
+ /** @property {string} filePageLink URL to the image's file page */
+ this.filePageLink = filePageLink;
+
+ /** @property {mw.Title} filePageTitle Title of the image's file page */
+ this.filePageTitle = fileTitle;
+
+ /** @property {number} index What number this image is in the array of indexed images */
+ this.index = index;
+
+ /** @property {HTMLImageElement} thumbnail The <img> element that holds the already-loaded thumbnail of the image*/
+ this.thumbnail = thumb;
+
+ /** @property {string} caption The caption of the image, if any */
+ this.caption = caption;
+
+ /** @property {string} alt The alt text of the image */
+ this.alt = alt;
+
+ /** @property {number|undefined} originalWidth Width of the full-sized file (read from HTML data attribute, might be missing) */
+ this.originalWidth = undefined;
+
+ /** @property {number|undefined} originalHeight Height of the full-sized file (read from HTML data attribute, might be missing) */
+ this.originalHeight = undefined;
+ }
+
+ mw.mmv.LightboxImage = LightboxImage;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.js
new file mode 100644
index 00000000..21f33a06
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.js
@@ -0,0 +1,509 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var LIP;
+
+ /**
+ * Represents the main interface of the lightbox
+ *
+ * @class mw.mmv.LightboxInterface
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ */
+ function LightboxInterface() {
+ this.localStorage = mw.storage;
+
+ /** @property {mw.mmv.Config} config - */
+ this.config = new mw.mmv.Config(
+ mw.config.get( 'wgMultimediaViewer', {} ),
+ mw.config,
+ mw.user,
+ new mw.Api(),
+ this.localStorage
+ );
+
+ /**
+ * @property {mw.mmv.ThumbnailWidthCalculator}
+ * @private
+ */
+ this.thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator();
+
+ this.init();
+ mw.mmv.ui.Element.call( this, this.$wrapper );
+ }
+ oo.inheritClass( LightboxInterface, mw.mmv.ui.Element );
+ LIP = LightboxInterface.prototype;
+
+ /**
+ * The currently selected LightboxImage.
+ *
+ * @type {mw.mmv.LightboxImage}
+ * @protected
+ */
+ LIP.currentImage = null;
+
+ /**
+ * Initialize the entire interface - helper method.
+ */
+ LIP.init = function () {
+ // SVG filter, needed to achieve blur in Firefox
+ this.$filter = $( '<svg><filter id="gaussian-blur"><fegaussianblur stdDeviation="3"></filter></svg>' );
+
+ this.$wrapper = $( '<div>' )
+ .addClass( 'mw-mmv-wrapper' );
+
+ this.$main = $( '<div>' )
+ .addClass( 'mw-mmv-main' );
+
+ // I blame CSS for this
+ this.$innerWrapper = $( '<div>' )
+ .addClass( 'mw-mmv-image-inner-wrapper' );
+
+ this.$imageWrapper = $( '<div>' )
+ .addClass( 'mw-mmv-image-wrapper' )
+ .append( this.$innerWrapper );
+
+ this.$preDiv = $( '<div>' )
+ .addClass( 'mw-mmv-pre-image' );
+
+ this.$postDiv = $( '<div>' )
+ .addClass( 'mw-mmv-post-image' );
+
+ this.$aboveFold = $( '<div>' )
+ .addClass( 'mw-mmv-above-fold' );
+
+ this.$main.append(
+ this.$preDiv,
+ this.$imageWrapper,
+ this.$postDiv,
+ this.$filter
+ );
+
+ this.$wrapper.append(
+ this.$main
+ );
+
+ this.setupCanvasButtons();
+
+ this.panel = new mw.mmv.ui.MetadataPanel( this.$postDiv, this.$aboveFold, this.localStorage, this.config );
+ this.buttons = new mw.mmv.ui.CanvasButtons( this.$preDiv, this.$closeButton, this.$fullscreenButton );
+ this.canvas = new mw.mmv.ui.Canvas( this.$innerWrapper, this.$imageWrapper, this.$wrapper );
+
+ this.fileReuse = new mw.mmv.ui.reuse.Dialog( this.$innerWrapper, this.buttons.$reuse, this.config );
+ this.downloadDialog = new mw.mmv.ui.download.Dialog( this.$innerWrapper, this.buttons.$download, this.config );
+ this.optionsDialog = new mw.mmv.ui.OptionsDialog( this.$innerWrapper, this.buttons.$options, this.config );
+ };
+
+ /**
+ * Sets up the file reuse data in the DOM
+ *
+ * @param {mw.mmv.model.Image} image
+ * @param {mw.mmv.model.Repo} repo
+ * @param {string} caption
+ * @param {string} alt
+ */
+ LIP.setFileReuseData = function ( image, repo, caption, alt ) {
+ this.fileReuse.set( image, repo, caption, alt );
+ this.downloadDialog.set( image, repo );
+ };
+
+ /**
+ * Empties the interface.
+ */
+ LIP.empty = function () {
+ this.panel.empty();
+
+ this.canvas.empty();
+
+ this.buttons.empty();
+
+ this.$main.addClass( 'metadata-panel-is-closed' )
+ .removeClass( 'metadata-panel-is-open' );
+ };
+
+ /**
+ * Opens the lightbox.
+ */
+ LIP.open = function () {
+ this.empty();
+ this.attach();
+ };
+
+ /**
+ * Attaches the interface to the DOM.
+ *
+ * @param {string} [parentId] parent id where we want to attach the UI. Defaults to document
+ * element, override is mainly used for testing.
+ */
+ LIP.attach = function ( parentId ) {
+ var ui = this,
+ $parent;
+
+ // Advanced description needs to be below the fold when the lightbox opens
+ // regardless of what the scroll value was prior to opening the lightbox
+ // If the lightbox is already attached, it means we're doing prev/next, and
+ // we should avoid scrolling the panel
+ if ( !this.attached ) {
+ $( window ).scrollTop( 0 );
+ }
+
+ // Make sure that the metadata is going to be at the bottom when it appears
+ // 83 is the height of the top metadata area. Which can't be measured by
+ // reading the DOM at this point of the execution, unfortunately
+ this.$postDiv.css( 'top', ( $( window ).height() - 83 ) + 'px' );
+
+ // Re-appending the same content can have nasty side-effects
+ // Such as the browser leaving fullscreen mode if the fullscreened element is part of it
+ if ( this.currentlyAttached ) {
+ return;
+ }
+
+ this.handleEvent( 'keyup', function ( e ) {
+ if ( e.keyCode === 27 && !( e.altKey || e.ctrlKey || e.shiftKey || e.metaKey ) ) {
+ // Escape button pressed
+ ui.unattach();
+ }
+ } );
+
+ this.handleEvent( 'jq-fullscreen-change.lip', function ( e ) {
+ ui.fullscreenChange( e );
+ } );
+
+ this.handleEvent( 'keydown', function ( e ) { ui.keydown( e ); } );
+
+ // mousemove generates a ton of events, which is why we throttle it
+ this.handleEvent( 'mousemove.lip', $.throttle( 250, function ( e ) {
+ ui.mousemove( e );
+ } ) );
+
+ this.handleEvent( 'mmv-faded-out', function ( e ) { ui.fadedOut( e ); } );
+ this.handleEvent( 'mmv-fade-stopped', function ( e ) { ui.fadeStopped( e ); } );
+
+ this.buttons.connect( this, {
+ next: [ 'emit', 'next' ],
+ prev: [ 'emit', 'prev' ]
+ } );
+
+ $parent = $( parentId || document.body );
+
+ // Clean up fullscreen data because hard-existing fullscreen might have left
+ // jquery.fullscreen unable to remove the class and attribute, since $main wasn't
+ // attached to the DOM anymore at the time the jq-fullscreen-change event triggered
+ this.$main.data( 'isFullscreened', false ).removeClass( 'jq-fullscreened' );
+ this.isFullscreen = false;
+
+ $parent
+ .append(
+ this.$wrapper
+ );
+ this.currentlyAttached = true;
+
+ this.panel.attach();
+
+ this.canvas.attach();
+
+ // cross-communication between panel and canvas, sort of
+ this.$postDiv.on( 'mmv-metadata-open.lip', function () {
+ ui.$main.addClass( 'metadata-panel-is-open' )
+ .removeClass( 'metadata-panel-is-closed' );
+ } ).on( 'mmv-metadata-close.lip', function () {
+ ui.$main.removeClass( 'metadata-panel-is-open' )
+ .addClass( 'metadata-panel-is-closed' );
+ } );
+ this.$wrapper.on( 'mmv-panel-close-area-click.lip', function () {
+ ui.panel.scroller.toggle( 'down' );
+ } );
+
+ // Buttons fading might not had been reset properly after a hard fullscreen exit
+ // This needs to happen after the parent attach() because the buttons need to be attached
+ // to the DOM for $.fn.stop() to work
+ this.buttons.stopFade();
+ this.buttons.attach();
+
+ this.fileReuse.attach();
+ this.downloadDialog.attach();
+ this.optionsDialog.attach();
+
+ // Reset the cursor fading
+ this.fadeStopped();
+
+ this.attached = true;
+ };
+
+ /**
+ * Detaches the interface from the DOM.
+ */
+ LIP.unattach = function () {
+ mw.mmv.actionLogger.log( 'close' );
+
+ // Has to happen first so that the scroller can freeze with visible elements
+ this.panel.unattach();
+
+ this.$wrapper.detach();
+
+ this.currentlyAttached = false;
+
+ this.buttons.unattach();
+
+ this.$postDiv.off( '.lip' );
+ this.$wrapper.off( 'mmv-panel-close-area-click.lip' );
+
+ this.fileReuse.unattach();
+ this.fileReuse.closeDialog();
+
+ this.downloadDialog.unattach();
+ this.downloadDialog.closeDialog();
+
+ this.optionsDialog.unattach();
+ this.optionsDialog.closeDialog();
+
+ // Canvas listens for events from dialogs, so should be unattached at the end
+ this.canvas.unattach();
+
+ this.clearEvents();
+
+ this.buttons.disconnect( this, {
+ next: [ 'emit', 'next' ],
+ prev: [ 'emit', 'prev' ]
+ } );
+
+ // We trigger this event on the document because unattach() can run
+ // when the interface is unattached
+ $( document ).trigger( $.Event( 'mmv-close' ) )
+ .off( 'jq-fullscreen-change.lip' );
+
+ this.attached = false;
+ };
+
+ /**
+ * Exits fullscreen mode.
+ */
+ LIP.exitFullscreen = function () {
+ this.fullscreenButtonJustPressed = true;
+ this.$main.exitFullscreen();
+ };
+
+ /**
+ * Enters fullscreen mode.
+ */
+ LIP.enterFullscreen = function () {
+ this.$main.enterFullscreen();
+ };
+
+ /**
+ * Setup for canvas navigation buttons
+ */
+ LIP.setupCanvasButtons = function () {
+ var ui = this,
+ tooltipDelay = mw.config.get( 'wgMultimediaViewer' ).tooltipDelay;
+
+ this.$closeButton = $( '<button>' )
+ .text( ' ' )
+ .addClass( 'mw-mmv-close' )
+ .prop( 'title', mw.message( 'multimediaviewer-close-popup-text' ).text() )
+ .tipsy( {
+ delayIn: tooltipDelay,
+ gravity: this.correctEW( 'ne' )
+ } )
+ .click( function () {
+ if ( ui.isFullscreen ) {
+ ui.$main.trigger( $.Event( 'jq-fullscreen-change.lip' ) );
+ }
+ ui.unattach();
+ } );
+
+ this.$fullscreenButton = $( '<button>' )
+ .text( ' ' )
+ .addClass( 'mw-mmv-fullscreen' )
+ .prop( 'title', mw.message( 'multimediaviewer-fullscreen-popup-text' ).text() )
+ .tipsy( {
+ delayIn: tooltipDelay,
+ gravity: this.correctEW( 'ne' )
+ } )
+ .click( function ( e ) {
+ if ( ui.isFullscreen ) {
+ ui.exitFullscreen();
+
+ // mousemove is throttled and the mouse coordinates only
+ // register every 250ms, so there is a chance that we moved
+ // our mouse over one of the buttons but it didn't register,
+ // and a fadeOut is triggered; when we're coming back from
+ // fullscreen, we'll want to make sure the mouse data is
+ // current so that the fadeOut behavior will not trigger
+ ui.mousePosition = { x: e.pageX, y: e.pageY };
+ ui.buttons.revealAndFade( ui.mousePosition );
+ } else {
+ ui.enterFullscreen();
+ }
+ } );
+
+ // If the browser doesn't support fullscreen mode, hide the fullscreen button
+ if ( $.support.fullscreen ) {
+ this.$fullscreenButton.show();
+ } else {
+ this.$fullscreenButton.hide();
+ }
+ };
+
+ /**
+ * Handle a fullscreen change event.
+ *
+ * @param {jQuery.Event} e The fullscreen change event.
+ */
+ LIP.fullscreenChange = function ( e ) {
+ this.isFullscreen = e.fullscreen;
+
+ if ( this.isFullscreen ) {
+ mw.mmv.actionLogger.log( 'fullscreen' );
+
+ this.$fullscreenButton
+ .prop( 'title', mw.message( 'multimediaviewer-defullscreen-popup-text' ).text() )
+ .attr( 'alt', mw.message( 'multimediaviewer-defullscreen-popup-text' ).text() );
+ } else {
+ mw.mmv.actionLogger.log( 'defullscreen' );
+
+ this.$fullscreenButton
+ .prop( 'title', mw.message( 'multimediaviewer-fullscreen-popup-text' ).text() )
+ .attr( 'alt', mw.message( 'multimediaviewer-fullscreen-popup-text' ).text() );
+ }
+
+ if ( !this.fullscreenButtonJustPressed && !e.fullscreen ) {
+ // Close the interface all the way if the user pressed 'esc'
+ this.unattach();
+ } else if ( this.fullscreenButtonJustPressed ) {
+ this.fullscreenButtonJustPressed = false;
+ }
+
+ // Fullscreen change events can happen after unattach(), in which
+ // case we shouldn't do anything UI-related
+ if ( !this.currentlyAttached ) {
+ return;
+ }
+
+ if ( this.isFullscreen ) {
+ // When entering fullscreen without a mousemove, the browser
+ // still thinks that the cursor is where it was prior to entering
+ // fullscreen. I.e. on top of the fullscreen button
+ // Thus, we purposefully reset the saved position, so that
+ // the fade out really takes place (otherwise it's cancelled
+ // by updateControls which is called a few times when fullscreen opens)
+ this.mousePosition = { x: 0, y: 0 };
+ this.buttons.fadeOut();
+ }
+
+ // Some browsers only send resize events before toggling fullscreen, but not once the toggling is done
+ // This makes sure that the UI is properly resized after a fullscreen change
+ this.$main.trigger( $.Event( 'mmv-resize-end' ) );
+ };
+
+ /**
+ * Handles keydown events on the document
+ *
+ * @param {jQuery.Event} e The jQuery keypress event object
+ */
+ LIP.keydown = function ( e ) {
+ var forward,
+ isRtl = $( document.body ).hasClass( 'rtl' );
+
+ if ( e.altKey || e.shiftKey || e.ctrlKey || e.metaKey ) {
+ return;
+ }
+
+ switch ( e.which ) {
+ case 37: // Left arrow
+ case 39: // Right arrow
+ e.preventDefault();
+ forward = ( e.which === 39 );
+ if ( isRtl ) {
+ forward = !forward;
+ }
+
+ if ( forward ) {
+ this.emit( 'next' );
+ } else {
+ this.emit( 'prev' );
+ }
+
+ e.preventDefault();
+ break;
+ }
+ };
+
+ /**
+ * Handles mousemove events on the document
+ *
+ * @param {jQuery.Event} e The mousemove event object
+ */
+ LIP.mousemove = function ( e ) {
+ // T77869 ignore fake mousemove events triggered by Chrome
+ if (
+ e &&
+ e.originalEvent &&
+ e.originalEvent.movementX === 0 &&
+ e.originalEvent.movementY === 0
+ ) {
+ return;
+ }
+
+ if ( e ) {
+ // Saving the mouse position is useful whenever we need to
+ // run LIP.mousemove manually, such as when going to the next/prev
+ // element
+ this.mousePosition = { x: e.pageX, y: e.pageY };
+ }
+
+ if ( this.isFullscreen ) {
+ this.buttons.revealAndFade( this.mousePosition );
+ }
+ };
+
+ /**
+ * Called when the buttons have completely faded out and disappeared
+ */
+ LIP.fadedOut = function () {
+ this.$main.addClass( 'cursor-hidden' );
+ };
+
+ /**
+ * Called when the buttons have stopped fading and are back into view
+ */
+ LIP.fadeStopped = function () {
+ this.$main.removeClass( 'cursor-hidden' );
+ };
+
+ /**
+ * Updates the next and prev buttons
+ *
+ * @param {boolean} showPrevButton Whether the prev button should be revealed or not
+ * @param {boolean} showNextButton Whether the next button should be revealed or not
+ */
+ LIP.updateControls = function ( showPrevButton, showNextButton ) {
+ var prevNextTop = ( ( this.$imageWrapper.height() / 2 ) - 60 ) + 'px';
+
+ if ( this.$main.data( 'isFullscreened' ) ) {
+ this.$postDiv.css( 'top', '' );
+ } else {
+ this.$postDiv.css( 'top', this.$imageWrapper.height() );
+ }
+
+ this.buttons.setOffset( prevNextTop );
+ this.buttons.toggle( showPrevButton, showNextButton );
+ };
+
+ mw.mmv.LightboxInterface = LightboxInterface;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.less
new file mode 100644
index 00000000..77d93546
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.lightboxinterface.less
@@ -0,0 +1,105 @@
+@import 'mmv.globals';
+@import 'mmv.mixins';
+
+.mw-mmv-wrapper {
+ top: 0;
+ left: 0;
+ right: 0;
+ z-index: 1001;
+ position: absolute;
+ bottom: auto;
+
+ .skin-monobook & {
+ font-size: medium;
+ }
+}
+
+.mw-mmv-main {
+ width: 100%;
+ height: auto;
+ position: relative;
+
+ .jq-fullscreened {
+ background-color: #000;
+ }
+}
+
+.mw-mmv-image-wrapper {
+ position: fixed;
+ top: 0;
+ bottom: @metadatabar-above-fold-height;
+ left: 0;
+ right: 0;
+ overflow-y: hidden;
+}
+
+.mw-mmv-image-inner-wrapper {
+ display: table;
+ width: 100%;
+ height: 100%;
+}
+
+.mw-mmv-pre-image {
+ position: absolute;
+ top: 0;
+ height: 32px;
+ width: 100%;
+ z-index: 1;
+}
+
+.mw-mmv-post-image {
+ position: absolute;
+ width: 100%;
+ bottom: auto;
+ height: auto;
+ color: #222;
+ background-color: @panel-above-fold-background-color;
+ min-height: ( @metadatabar-above-fold-inner-height + 1 );
+ z-index: 1005;
+}
+
+// above-the-fold part of the metadata panel
+.mw-mmv-above-fold {
+ width: 100%;
+ height: @metadatabar-above-fold-inner-height;
+ // min-height is used when the height is changed to auto to display long texts, to make sure the layout
+ // is not messed up wheen the text is short and does not fill the available place. It is also used by
+ // JavaScript to get the "default" height.
+ min-height: @metadatabar-above-fold-inner-height;
+ position: relative;
+ // make sure there is no content in the part which is overlapped by the revealed part of the below-fold content
+ // also used in JavaScript for the height calculations
+ padding-bottom: @metadatabar-below-fold-pushup-height;
+
+ .mw-mmv-untruncated & {
+ height: auto;
+ }
+}
+
+// Fullscreen styles
+
+.cursor-hidden {
+ cursor: none;
+}
+
+.mw-mmv-main.jq-fullscreened {
+ background-color: #000;
+}
+
+.jq-fullscreened {
+ .mw-mmv-image-wrapper, // make the image occupy the whole screen
+ .mw-mmv-post-image { // make sure the panel fits in the screen and does not cause scrollbars to appear
+ bottom: 0;
+ }
+
+ .mw-mmv-post-image {
+ position: fixed;
+ min-height: 0;
+ .opacity( 0 );
+ transition: opacity 0.25s;
+
+ &:hover {
+ .opacity( 1 );
+ }
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.mixins.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.mixins.less
new file mode 100644
index 00000000..262d9fdb
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/mmv.mixins.less
@@ -0,0 +1,60 @@
+/* stylelint-disable function-parentheses-space-inside */
+/* stylelint-disable string-quotes */
+
+.unselectable() {
+ -webkit-user-select: none;
+ -moz-user-select: -moz-none;
+ -ms-user-select: none;
+ user-select: none;
+}
+
+.opacity( @value ) {
+ opacity: @value;
+ filter: e( %( "alpha(opacity=%s )", round( @value * 100 ) ) ); // IE6-8
+ zoom: 1; // IE 6-7 hasLayout hack
+}
+
+// from http://stackoverflow.com/a/12178019/323407
+.fade-out-vertical( @backgroundColor: white ) {
+ @invisible: fadeout( @backgroundColor, 100% );
+ background-image: -moz-linear-gradient( top, @invisible 0%, @backgroundColor 100% ); // FF3.6+
+ background-image: -webkit-gradient( linear, left top, left bottom, color-stop( 0%, @invisible ), color-stop( 100%, @backgroundColor ) ); // Chrome,Safari4+
+ background-image: -webkit-linear-gradient( top, @invisible 0%, @backgroundColor 100% ); // Chrome10+,Safari5.1+
+ background-image: linear-gradient( to bottom, @invisible 0%, @backgroundColor 100% ); // W3C
+ filter: e( %( "progid:DXImageTransform.Microsoft.gradient( startColorstr='#%s', endColorstr='#%s',GradientType=0 )", rgbahex( @invisible ), rgbahex( @backgroundColor) ) ); // IE6-9
+}
+.fade-out-horizontal( @backgroundColor: white ) {
+ @invisible: fadeout( @backgroundColor, 100% );
+ background-image: -moz-linear-gradient( left, @invisible 0%, @backgroundColor 100% ); // FF3.6+
+ background-image: -webkit-gradient( linear, left top, right top, color-stop(0%, @invisible ), color-stop( 100%, @backgroundColor) ); // Chrome,Safari4+
+ background-image: -webkit-linear-gradient( left, @invisible 0%, @backgroundColor 100% ); // Chrome10+,Safari5.1+
+ background-image: linear-gradient( to right, @invisible 0%, @backgroundColor 100% ); // W3C
+ filter: e( %( "progid:DXImageTransform.Microsoft.gradient( startColorstr='#%s', endColorstr='#%s',GradientType=1 )", rgbahex( @invisible ), rgbahex( @backgroundColor) ) ); // IE6-9
+}
+
+.rotate( @degrees: 45deg ) {
+ -webkit-transform: rotate( @degrees );
+ -moz-transform: rotate( @degrees );
+ -ms-transform: rotate( @degrees ); // IE 9 only
+ transform: rotate( @degrees );
+
+ /* stylelint-disable number-no-trailing-zeros */
+ filter: progid:DXImageTransform.Microsoft.BasicImage( rotation=( @degrees / 90.0 ) );
+ -ms-filter: 'progid:DXImageTransform.Microsoft.BasicImage( rotation=( @degrees / 90.0 ) )';
+ /* stylelint-enable number-no-trailing-zeros */
+
+ // The filter rules ( which are for IE < 9 ) cause a bug in IE 9 where the rotated
+ // element will have a black background. So we have to disable them in IE9
+ /* stylelint-disable declaration-block-no-duplicate-properties */
+ filter: none \0;
+ -ms-filter: none \0;
+ /* stylelint-enable declaration-block-no-duplicate-properties */
+}
+
+// from http://pixelhunter.me/post/25782670606/css3-grayscale
+.grayscale() {
+ -webkit-filter: grayscale( 100% );
+ filter: url( "data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\'><filter id=\'grayscale\'><feColorMatrix type=\'matrix\' values=\'0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0\'/></filter></svg>#grayscale" ); /* Firefox 3.5+ */ /* stylelint-disable-line function-url-quotes */
+ filter: grayscale( 100% );
+ filter: #72777d; // IE 6-9
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.EmbedFileInfo.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.EmbedFileInfo.js
new file mode 100644
index 00000000..3e5378dd
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.EmbedFileInfo.js
@@ -0,0 +1,53 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ /**
+ * Contains information needed to embed and share files.
+ *
+ * @class mw.mmv.model.EmbedFileInfo
+ * @constructor
+ * @param {mw.mmv.model.Image} imageInfo
+ * @param {mw.mmv.model.Repo} repoInfo
+ * @param {string} [caption]
+ * @param {string} [alt]
+ */
+ function EmbedFileInfo(
+ imageInfo,
+ repoInfo,
+ caption,
+ alt
+ ) {
+ if ( !imageInfo || !repoInfo ) {
+ throw new Error( 'imageInfo and repoInfo are required and must have a value' );
+ }
+
+ /** @property {mw.mmv.model.Image} imageInfo The title of the file */
+ this.imageInfo = imageInfo;
+
+ /** @property {mw.mmv.model.Repo} repoInfo The URL to the original file */
+ this.repoInfo = repoInfo;
+
+ /** @property {Object} [caption] Image caption, if any */
+ this.caption = caption;
+
+ /** @property {string} [alt] Alt text for image */
+ this.alt = alt;
+ }
+
+ mw.mmv.model.EmbedFileInfo = EmbedFileInfo;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Image.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Image.js
new file mode 100644
index 00000000..26498ccf
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Image.js
@@ -0,0 +1,343 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ var IP;
+
+ /**
+ * Represents information about a single image
+ *
+ * @class mw.mmv.model.Image
+ * @constructor
+ * @param {mw.Title} title
+ * @param {string} name Image name (e.g. title of the artwork) or human-readable file if there is no better title
+ * @param {number} size Filesize in bytes of the original image
+ * @param {number} width Width of the original image
+ * @param {number} height Height of the original image
+ * @param {string} mimeType
+ * @param {string} url URL to the image itself (original version)
+ * @param {string} descriptionUrl URL to the image description page
+ * @param {string} descriptionShortUrl A short URL to the description page for the image, using curid=...
+ * @param {string} pageID pageId of the description page for the image
+ * @param {string} repo The repository this image belongs to
+ * @param {string} uploadDateTime The time and date the last upload occurred
+ * @param {string} anonymizedUploadDateTime Anonymized and EL-friendly version of uploadDateTime
+ * @param {string} creationDateTime The time and date the original upload occurred
+ * @param {string} description
+ * @param {string} source
+ * @param {string} author
+ * @param {number} authorCount
+ * @param {mw.mmv.model.License} license
+ * @param {string} permission
+ * @param {string} attribution Custom attribution string that replaces credit line when set
+ * @param {string} deletionReason
+ * @param {number} latitude
+ * @param {number} longitude
+ * @param {string[]} restrictions
+ */
+ function Image(
+ title,
+ name,
+ size,
+ width,
+ height,
+ mimeType,
+ url,
+ descriptionUrl,
+ descriptionShortUrl,
+ pageID,
+ repo,
+ uploadDateTime,
+ anonymizedUploadDateTime,
+ creationDateTime,
+ description,
+ source,
+ author,
+ authorCount,
+ license,
+ permission,
+ attribution,
+ deletionReason,
+ latitude,
+ longitude,
+ restrictions
+ ) {
+ /** @property {mw.Title} title The title of the image file */
+ this.title = title;
+
+ /** @property {string} name Image name (e.g. title of the artwork) or human-readable file if there is no better title */
+ this.name = name;
+
+ /** @property {number} size The filesize, in bytes, of the original image */
+ this.size = size;
+
+ /** @property {number} width The width, in pixels, of the original image */
+ this.width = width;
+
+ /** @property {number} height The height, in pixels, of the original image */
+ this.height = height;
+
+ /** @property {string} mimeType The MIME type of the original image */
+ this.mimeType = mimeType;
+
+ /** @property {string} url The URL to the original image */
+ this.url = url;
+
+ /** @property {string} descriptionUrl The URL to the description page for the image */
+ this.descriptionUrl = descriptionUrl;
+
+ /** @property {string} descriptionShortUrl A short URL to the description page for the image, using curid=... */
+ this.descriptionShortUrl = descriptionShortUrl;
+
+ /** @property {number} pageId of the description page for the image */
+ this.pageID = pageID;
+
+ /** @property {string} repo The name of the repository where this image is stored */
+ this.repo = repo;
+
+ /** @property {string} uploadDateTime The date and time of the last upload */
+ this.uploadDateTime = uploadDateTime;
+
+ /** @property {string} anonymizedUploadDateTime The anonymized date and time of the last upload */
+ this.anonymizedUploadDateTime = anonymizedUploadDateTime;
+
+ /** @property {string} creationDateTime The date and time that the image was created */
+ this.creationDateTime = creationDateTime;
+
+ /** @property {string} description The description from the file page - unsafe HTML sometimes goes here */
+ this.description = description;
+
+ /** @property {string} source The source for the image (could be an organization, e.g.) - unsafe HTML sometimes goes here */
+ this.source = source;
+
+ /** @property {string} author The author of the image - unsafe HTML sometimes goes here */
+ this.author = author;
+
+ /** @property {number} authorCount The number of different authors of the image. This is guessed by the
+ * number of templates with author fields, so might be less than the number of actual authors. */
+ this.authorCount = authorCount;
+
+ /** @property {mw.mmv.model.License} license The license under which the image is distributed */
+ this.license = license;
+
+ /** @property {string} additional license conditions by the author (note that this is usually a big ugly HTML blob) */
+ this.permission = permission;
+
+ /** @property {string} attribution custom attribution string set by uploader that replaces credit line */
+ this.attribution = attribution;
+
+ /** @property {string|null} reason for pending deletion, null if image is not about to be deleted */
+ this.deletionReason = deletionReason;
+
+ /** @property {number} latitude The latitude of the place where the image was created */
+ this.latitude = latitude;
+
+ /** @property {number} longitude The longitude of the place where the image was created */
+ this.longitude = longitude;
+
+ /** @property {string[]} restrictions Any re-use restrictions for the image, eg trademarked */
+ this.restrictions = restrictions;
+
+ /**
+ * @property {Object} thumbUrls
+ * An object indexed by image widths
+ * with URLs to appropriately sized thumbnails
+ */
+ this.thumbUrls = {};
+ }
+ IP = Image.prototype;
+
+ /**
+ * Constructs a new Image object out of an object containing
+ *
+ * imageinfo data from an API response.
+ *
+ * @static
+ * @param {mw.Title} title
+ * @param {Object} imageInfo
+ * @return {mw.mmv.model.Image}
+ */
+ Image.newFromImageInfo = function ( title, imageInfo ) {
+ var name, uploadDateTime, anonymizedUploadDateTime, creationDateTime, imageData,
+ description, source, author, authorCount, license, permission, attribution,
+ deletionReason, latitude, longitude, restrictions,
+ innerInfo = imageInfo.imageinfo[ 0 ],
+ extmeta = innerInfo.extmetadata;
+
+ if ( extmeta ) {
+ creationDateTime = this.parseExtmeta( extmeta.DateTimeOriginal, 'plaintext' );
+ uploadDateTime = this.parseExtmeta( extmeta.DateTime, 'plaintext' ).toString();
+
+ // Convert to "timestamp" format commonly used in EventLogging
+ anonymizedUploadDateTime = uploadDateTime.replace( /[^\d]/g, '' );
+
+ // Anonymise the timestamp to avoid making the file identifiable
+ // We only need to know the day
+ anonymizedUploadDateTime = anonymizedUploadDateTime.substr( 0, anonymizedUploadDateTime.length - 6 ) + '000000';
+
+ name = this.parseExtmeta( extmeta.ObjectName, 'plaintext' );
+
+ description = this.parseExtmeta( extmeta.ImageDescription, 'string' );
+ source = this.parseExtmeta( extmeta.Credit, 'string' );
+ author = this.parseExtmeta( extmeta.Artist, 'string' );
+ authorCount = this.parseExtmeta( extmeta.AuthorCount, 'integer' );
+
+ license = this.newLicenseFromImageInfo( extmeta );
+ permission = this.parseExtmeta( extmeta.Permission, 'string' );
+ attribution = this.parseExtmeta( extmeta.Attribution, 'string' );
+ deletionReason = this.parseExtmeta( extmeta.DeletionReason, 'string' );
+ restrictions = this.parseExtmeta( extmeta.Restrictions, 'list' );
+
+ latitude = this.parseExtmeta( extmeta.GPSLatitude, 'float' );
+ longitude = this.parseExtmeta( extmeta.GPSLongitude, 'float' );
+ }
+
+ if ( !name ) {
+ name = title.getNameText();
+ }
+
+ imageData = new Image(
+ title,
+ name,
+ innerInfo.size,
+ innerInfo.width,
+ innerInfo.height,
+ innerInfo.mime,
+ innerInfo.url,
+ innerInfo.descriptionurl,
+ innerInfo.descriptionshorturl,
+ imageInfo.pageid,
+ imageInfo.imagerepository,
+ uploadDateTime,
+ anonymizedUploadDateTime,
+ creationDateTime,
+ description,
+ source,
+ author,
+ authorCount,
+ license,
+ permission,
+ attribution,
+ deletionReason,
+ latitude,
+ longitude,
+ restrictions
+ );
+
+ if ( innerInfo.thumburl ) {
+ imageData.addThumbUrl(
+ innerInfo.thumbwidth,
+ innerInfo.thumburl
+ );
+ }
+
+ return imageData;
+ };
+
+ /**
+ * Constructs a new License object out of an object containing
+ * imageinfo data from an API response.
+ *
+ * @static
+ * @param {Object} extmeta the extmeta array of the imageinfo data
+ * @return {mw.mmv.model.License|undefined}
+ */
+ Image.newLicenseFromImageInfo = function ( extmeta ) {
+ var license;
+
+ if ( extmeta.LicenseShortName ) {
+ license = new mw.mmv.model.License(
+ this.parseExtmeta( extmeta.LicenseShortName, 'string' ),
+ this.parseExtmeta( extmeta.License, 'string' ),
+ this.parseExtmeta( extmeta.UsageTerms, 'string' ),
+ this.parseExtmeta( extmeta.LicenseUrl, 'string' ),
+ this.parseExtmeta( extmeta.AttributionRequired, 'boolean' ),
+ this.parseExtmeta( extmeta.NonFree, 'boolean' )
+ );
+ }
+
+ return license;
+ };
+
+ /**
+ * Reads and parses a value from the imageinfo API extmetadata field.
+ *
+ * @param {Array} data
+ * @param {string} type one of 'plaintext', 'string', 'float', 'boolean', 'list'
+ * @return {string|number|boolean|Array} value or undefined if it is missing
+ */
+ Image.parseExtmeta = function ( data, type ) {
+ var value = data && data.value;
+ if ( value === null || value === undefined ) {
+ return undefined;
+ } else if ( type === 'plaintext' ) {
+ return value.toString().replace( /<.*?>/g, '' );
+ } else if ( type === 'string' ) {
+ return value.toString();
+ } else if ( type === 'integer' ) {
+ return parseInt( value, 10 );
+ } else if ( type === 'float' ) {
+ return parseFloat( value );
+ } else if ( type === 'boolean' ) {
+ value = value.toString().toLowerCase().replace( /^\s+|\s+$/g, '' );
+ if ( value in { 1: null, yes: null, 'true': null } ) {
+ return true;
+ } else if ( value in { 0: null, no: null, 'false': null } ) {
+ return false;
+ } else {
+ return undefined;
+ }
+ } else if ( type === 'list' ) {
+ return value === '' ? [] : value.split( '|' );
+ } else {
+ throw new Error( 'mw.mmv.model.Image.parseExtmeta: unknown type' );
+ }
+ };
+
+ /**
+ * Add a thumb URL
+ *
+ * @param {number} width
+ * @param {string} url
+ */
+ IP.addThumbUrl = function ( width, url ) {
+ this.thumbUrls[ width ] = url;
+ };
+
+ /**
+ * Get a thumb URL if we have it.
+ *
+ * @param {number} width
+ * @return {string|undefined}
+ */
+ IP.getThumbUrl = function ( width ) {
+ return this.thumbUrls[ width ];
+ };
+
+ /**
+ * Check whether the image has geolocation data.
+ *
+ * @return {boolean}
+ */
+ IP.hasCoords = function () {
+ return this.hasOwnProperty( 'latitude' ) && this.hasOwnProperty( 'longitude' ) &&
+ this.latitude !== undefined && this.latitude !== null &&
+ this.longitude !== undefined && this.longitude !== null;
+ };
+
+ mw.mmv.model.Image = Image;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.IwTitle.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.IwTitle.js
new file mode 100644
index 00000000..046cbf94
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.IwTitle.js
@@ -0,0 +1,80 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ var ITP;
+
+ /**
+ * IwTitle represents a title in a foreign wiki. The long-term goal is to have an interface
+ * largely compatible with mw.Title, but for now we only implement what we actually need.
+ *
+ * @class mw.mmv.model.IwTitle
+ * @param {string} namespaceId namespace number
+ * @param {string} title full title, including namespace name; with underscores (as in mw.Title#getPrefixedDb())
+ * @param {string} domain domain name of the wiki
+ * @param {string} url full URL to the page
+ * @constructor
+ */
+ function IwTitle(
+ namespaceId,
+ title,
+ domain,
+ url
+ ) {
+ /** @property {number} namespaceId - */
+ this.namespaceId = namespaceId;
+
+ /** @property {string} title - */
+ this.title = title;
+
+ /** @property {string} domain - */
+ this.domain = domain;
+
+ /** @property {string} url - */
+ this.url = url;
+ }
+ ITP = IwTitle.prototype;
+
+ /**
+ * Turn underscores into spaces.
+ * Copy of the private function in mw.Title.
+ *
+ * @param {string} s
+ * @return {string}
+ */
+ function text( s ) {
+ return s ? s.replace( /_/g, ' ' ) : '';
+ }
+
+ ITP.getUrl = function () {
+ return this.url;
+ };
+
+ ITP.getPrefixedDb = function () {
+ return this.title;
+ };
+
+ ITP.getPrefixedText = function () {
+ return text( this.getPrefixedDb() );
+ };
+
+ ITP.getDomain = function () {
+ return this.domain;
+ };
+
+ mw.mmv.model.IwTitle = IwTitle;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.License.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.License.js
new file mode 100644
index 00000000..2e608091
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.License.js
@@ -0,0 +1,144 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ var LP;
+
+ /**
+ * Class for storing license information about an image. For available fields, see
+ * TemplateParser::$licenseFieldClasses in the CommonsMetadata extension.
+ *
+ * @class mw.mmv.model.License
+ * @param {string} shortName see {@link #shortName}
+ * @param {string} [internalName] see {@link #internalName}
+ * @param {string} [longName] see {@link #longName}
+ * @param {string} [deedUrl] see {@link #deedUrl}
+ * @param {boolean} [attributionRequired] see {@link #attributionRequired}
+ * @param {boolean} [nonFree] see {@link #nonFree}
+ * @constructor
+ */
+ function License(
+ shortName,
+ internalName,
+ longName,
+ deedUrl,
+ attributionRequired,
+ nonFree
+ ) {
+ if ( !shortName ) {
+ throw new Error( 'mw.mmv.model.License: shortName is required' );
+ }
+
+ /** @property {string} shortName short (abbreviated) name of the license (e.g. CC-BY-SA-3.0) */
+ this.shortName = shortName;
+
+ /** @property {string} internalName internal name of the license, used for localization (e.g. cc-by-sa ) */
+ this.internalName = internalName;
+
+ /** @property {string} longName full name of the license (e.g. Creative Commons etc. etc.) */
+ this.longName = longName;
+
+ /** @property {string} deedUrl URL to the description of the license (e.g. the CC deed) */
+ this.deedUrl = deedUrl;
+
+ /** @property {boolean} attributionRequired does the author need to be attributed on reuse? */
+ this.attributionRequired = attributionRequired;
+
+ /** @property {boolean} nonFree is this a non-free license? */
+ this.nonFree = nonFree;
+
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+ }
+ LP = License.prototype;
+
+ /**
+ * Check whether this is a Creative Commons license.
+ *
+ * @return {boolean}
+ */
+ LP.isCc = function () {
+ return this.internalName ? this.internalName.substr( 0, 2 ) === 'cc' : false;
+ };
+
+ /**
+ * Check whether this is a public domain "license".
+ *
+ * @return {boolean}
+ */
+ LP.isPd = function () {
+ return this.internalName === 'pd';
+ };
+
+ /**
+ * Check whether this is a free license.
+ *
+ * @return {boolean}
+ */
+ LP.isFree = function () {
+ // licenses with missing nonfree information are assumed free
+ return !this.nonFree;
+ };
+
+ /**
+ * Check whether reusers need to attribute the author
+ *
+ * @return {boolean}
+ */
+ LP.needsAttribution = function () {
+ // to be on the safe side, if the attribution required flag is not set, it is assumed to be true
+ return !this.isPd() && this.attributionRequired !== false;
+ };
+
+ /**
+ * Returns the short name of the license:
+ * - if we have interface messages for this license (basically just CC and PD), use those
+ * - otherwise use the short name from the license template (might or might not be translated
+ * still, depending on how the template is set up)
+ *
+ * @return {string}
+ * FIXME a model should not depend on an i18n class. We should probably use view models.
+ */
+ LP.getShortName = function () {
+ var message = 'multimediaviewer-license-' + ( this.internalName || '' );
+ if ( mw.messages.exists( message ) ) {
+ return mw.message( message ).text();
+ } else {
+ return this.shortName;
+ }
+ };
+
+ /**
+ * Returns a short HTML representation of the license.
+ *
+ * @return {string}
+ */
+ LP.getShortLink = function () {
+ var shortName = this.getShortName();
+
+ if ( this.deedUrl ) {
+ return this.htmlUtils.makeLinkText( shortName, {
+ href: this.deedUrl,
+ title: this.longName || shortName
+ } );
+ } else {
+ return shortName;
+ }
+ };
+
+ mw.mmv.model.License = License;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Repo.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Repo.js
new file mode 100644
index 00000000..d23ac74b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Repo.js
@@ -0,0 +1,209 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+/* eslint-disable no-use-before-define */
+
+( function ( mw, oo ) {
+ /**
+ * Represents information about a single image repository
+ *
+ * @class mw.mmv.model.Repo
+ * @constructor
+ * @param {string} displayName
+ * @param {string} favIcon URL to the repo's favicon
+ * @param {boolean} isLocal
+ */
+ function Repo(
+ displayName,
+ favIcon,
+ isLocal
+ ) {
+ /** @property {string} displayName Human-readable name of the repository */
+ this.displayName = displayName;
+
+ /** @property {string} favIcon An icon that represents the repository */
+ this.favIcon = favIcon;
+
+ /** @property {boolean} isLocal Whether the repository is the local wiki */
+ this.isLocal = isLocal;
+ }
+
+ /**
+ * Creates a new object from repoInfo we found in an API response.
+ *
+ * @static
+ * @param {Object} repoInfo
+ * @return {mw.mmv.model.Repo}
+ */
+ Repo.newFromRepoInfo = function ( repoInfo ) {
+ if ( repoInfo.apiurl ) {
+ return new ForeignApiRepo(
+ repoInfo.displayname,
+ repoInfo.favicon,
+ false,
+ repoInfo.apiurl,
+ repoInfo.server,
+ repoInfo.articlepath
+ );
+ } else if ( repoInfo.descBaseUrl ) {
+ return new ForeignDbRepo(
+ repoInfo.displayname,
+ repoInfo.favicon,
+ false,
+ repoInfo.descBaseUrl
+ );
+ } else {
+ return new Repo( repoInfo.displayname, repoInfo.favicon, repoInfo.local );
+ }
+ };
+
+ /**
+ * Returns true if the repo is Wikimedia Commons.
+ *
+ * @return {boolean}
+ */
+ Repo.prototype.isCommons = function () {
+ // there does not seem to be a sane way to do this
+ return this.displayName === 'Wikimedia Commons';
+ };
+
+ /**
+ * Gets the article path for the repository.
+ *
+ * @param {boolean} absolute if true, the URL will be absolute (if false, it still might be)
+ * @return {string} Replace $1 with the page name you want to link to.
+ */
+ Repo.prototype.getArticlePath = function ( absolute ) {
+ var articlePath = mw.config.get( 'wgArticlePath' );
+ if ( absolute ) {
+ articlePath = mw.config.get( 'wgServer' ) + articlePath;
+ }
+ return articlePath;
+ };
+
+ /**
+ * Gets the a link to the site where the image was uploaded to.
+ * This is a hack and might break for wikis with exotic config; unfortunately no
+ * better data is provided currently.
+ *
+ * @return {string}
+ */
+ Repo.prototype.getSiteLink = function () {
+ return this.getArticlePath( true ).replace( '$1', '' );
+ };
+
+ /**
+ * Represents information about a foreign API repository
+ *
+ * @class mw.mmv.model.ForeignApiRepo
+ * @extends mw.mmv.model.Repo
+ * @constructor
+ * @inheritdoc
+ * @param {string} displayName
+ * @param {string} favIcon
+ * @param {boolean} isLocal
+ * @param {string} apiUrl URL to the wiki's api.php
+ * @param {string} server Hostname for the wiki
+ * @param {string} articlePath Path to articles on the wiki, relative to the hostname.
+ */
+ function ForeignApiRepo(
+ displayName,
+ favIcon,
+ isLocal,
+ apiUrl,
+ server,
+ articlePath
+ ) {
+ Repo.call( this, displayName, favIcon, isLocal );
+
+ /** @property {string} apiUrl URL to the wiki's api.php */
+ this.apiUrl = apiUrl;
+
+ /** @property {string} server Hostname for the wiki */
+ this.server = server;
+
+ /** @property {string} articlePath Path to articles on the wiki, relative to the hostname */
+ this.articlePath = articlePath;
+
+ /** @property {string} absoluteArticlePath Path to articles on the wiki, relative to nothing */
+ this.absoluteArticlePath = server + articlePath;
+ }
+
+ oo.inheritClass( ForeignApiRepo, Repo );
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ ForeignApiRepo.prototype.getArticlePath = function () {
+ return this.absoluteArticlePath;
+ };
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ ForeignApiRepo.prototype.isCommons = function () {
+ return /^(https?:)?\/\/commons.wikimedia.org/.test( this.server );
+ };
+
+ /**
+ * Represents information about a foreign, shared DB repository
+ *
+ * @class mw.mmv.model.ForeignDbRepo
+ * @extends mw.mmv.model.Repo
+ * @constructor
+ * @inheritdoc
+ * @param {string} displayName
+ * @param {string} favIcon
+ * @param {boolean} isLocal
+ * @param {string} descBaseUrl Base URL for description pages - should include the "File:" prefix or similar.
+ */
+ function ForeignDbRepo(
+ displayName,
+ favIcon,
+ isLocal,
+ descBaseUrl
+ ) {
+ Repo.call( this, displayName, favIcon, isLocal );
+
+ /** @property {string} descBaseUrl Base URL for descriptions on the wiki - append a file's title to this to get the description page */
+ this.descBaseUrl = descBaseUrl;
+ }
+
+ oo.inheritClass( ForeignDbRepo, Repo );
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ ForeignDbRepo.prototype.getArticlePath = function () {
+ return this.descBaseUrl.replace( /[^/:]*:$/, '$1' );
+ };
+
+ /**
+ * @override
+ * @inheritdoc
+ */
+ ForeignDbRepo.prototype.isCommons = function () {
+ return /^(https?:)?\/\/commons.wikimedia.org/.test( this.descBaseUrl );
+ };
+
+ mw.mmv.model.Repo = Repo;
+ mw.mmv.model.ForeignApiRepo = ForeignApiRepo;
+ mw.mmv.model.ForeignDbRepo = ForeignDbRepo;
+}( mediaWiki, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.TaskQueue.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.TaskQueue.js
new file mode 100644
index 00000000..bfa908bc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.TaskQueue.js
@@ -0,0 +1,141 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var tqp;
+
+ /**
+ * A queue which holds a list of tasks (functions). The tasks will be executed in order,
+ * each starting when the previous one has finished (or failed).
+ *
+ * @class mw.mmv.model.TaskQueue
+ * @constructor
+ */
+ function TaskQueue() {
+ /**
+ * The list of functions to execute.
+ * @protected
+ * @property {Array.<function()>}
+ */
+ this.queue = [];
+
+ /**
+ * State of the task queue (running, finished etc)
+ * @protected
+ * @property {mw.mmv.model.TaskQueue.State}
+ */
+ this.state = TaskQueue.State.NOT_STARTED;
+
+ /**
+ * A deferred which shows the state of the queue.
+ * @protected
+ * @property {jQuery.Deferred}
+ */
+ this.deferred = $.Deferred();
+ }
+
+ tqp = TaskQueue.prototype;
+
+ /**
+ * Adds a task. The task should be a function which returns a promise. (Other return values are
+ * permitted, and will be taken to mean that the task has finished already.) The next task will
+ * start when the promise resolves (or rejects).
+ *
+ * Tasks can only be added before the queue is first executed.
+ *
+ * @param {function()} task
+ */
+ tqp.push = function ( task ) {
+ if ( this.state !== TaskQueue.State.NOT_STARTED ) {
+ throw new Error( 'Task queue already started!' );
+ }
+ this.queue.push( task );
+ };
+
+ /**
+ * Execute the queue. The tasks will be performed in order. No more tasks can be added to the
+ * queue.
+ *
+ * @return {jQuery.Promise} a promise which will resolve when the queue execution is finished,
+ * or reject when it is cancelled.
+ */
+ tqp.execute = function () {
+ if ( this.state === TaskQueue.State.NOT_STARTED ) {
+ this.state = TaskQueue.State.RUNNING;
+ this.runNextTask( 0, $.Deferred().resolve() );
+ }
+
+ return this.deferred;
+ };
+
+ /**
+ * Runs the next task once the current one has finished.
+ *
+ * @param {number} index
+ * @param {jQuery.Promise} currentTask
+ */
+ tqp.runNextTask = function ( index, currentTask ) {
+ var taskQueue = this;
+
+ function handleThen() {
+ if ( !taskQueue.queue[ index ] ) {
+ taskQueue.state = TaskQueue.State.FINISHED;
+ taskQueue.queue = []; // just to be sure there are no memory leaks
+ taskQueue.deferred.resolve();
+ return;
+ }
+
+ taskQueue.runNextTask( index + 1, $.when( taskQueue.queue[ index ]() ) );
+ }
+
+ if ( this.state !== TaskQueue.State.RUNNING ) {
+ return;
+ }
+
+ currentTask.then( handleThen, handleThen );
+ };
+
+ /**
+ * Cancel the queue. No more tasks will be executed.
+ */
+ tqp.cancel = function () {
+ this.state = TaskQueue.State.CANCELLED;
+ this.queue = []; // just to be sure there are no memory leaks
+ this.deferred.reject();
+ };
+
+ /**
+ * State of the task queue (running, finished etc)
+ *
+ * @enum {string} mw.mmv.model.TaskQueue.State
+ */
+ TaskQueue.State = {
+ /** not executed yet, tasks can still be added */
+ NOT_STARTED: 'not_started',
+
+ /** some task is being executed */
+ RUNNING: 'running',
+
+ /** all tasks finished, queue can be discarded */
+ FINISHED: 'finished',
+
+ /** cancel() function has been called, queue can be discarded */
+ CANCELLED: 'cancelled'
+ };
+
+ mw.mmv.model.TaskQueue = TaskQueue;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Thumbnail.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Thumbnail.js
new file mode 100644
index 00000000..aef05763
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.Thumbnail.js
@@ -0,0 +1,48 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ /**
+ * Represents information about an image thumbnail
+ *
+ * @class mw.mmv.model.Thumbnail
+ * @constructor
+ * @param {string} url URL to the thumbnail
+ * @param {number} width Width in pixels
+ * @param {number} height Height in pixels
+ */
+ function Thumbnail(
+ url,
+ width,
+ height
+ ) {
+ if ( !url || !width || !height ) {
+ throw new Error( 'All parameters are required and cannot be empty or zero' );
+ }
+
+ /** @property {string} url The URL to the thumbnail */
+ this.url = url;
+
+ /** @property {number} width The width of the thumbnail in pixels */
+ this.width = width;
+
+ /** @property {number} height The height of the thumbnail in pixels */
+ this.height = height;
+ }
+
+ mw.mmv.model.Thumbnail = Thumbnail;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.ThumbnailWidth.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.ThumbnailWidth.js
new file mode 100644
index 00000000..77df870f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.ThumbnailWidth.js
@@ -0,0 +1,82 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ /**
+ * Represents image width information.
+ *
+ * To utilize caching as much as possible, we use images which are displayed at a slightly
+ * different size than their screen size. The ThumbnailWidth model stores the various types of
+ * sizes and helps avoiding accidental incompatible assignments. (Think of it as a slightly
+ * overcomplicated Hungarian notation)
+ *
+ * @class mw.mmv.model.ThumbnailWidth
+ * @constructor
+ * @param {number} cssWidth width in CSS pixels
+ * @param {number} cssHeight height in CSS pixels
+ * @param {number} screen width in screen pixels
+ * @param {number} real width in real pixels
+ */
+ function ThumbnailWidth( cssWidth, cssHeight, screen, real ) {
+ if ( !cssWidth || !cssHeight || !screen || !real ) {
+ throw new Error( 'All parameters are required and cannot be empty or zero' );
+ }
+
+ /**
+ * Width of the thumbnail on the screen, in CSS pixels. This is the number which can be plugged
+ * into UI code like $element.width(x).
+ *
+ * @property {number}
+ */
+ this.cssWidth = cssWidth;
+
+ /**
+ * Height of the thumbnail on the screen, in CSS pixels. This is the number which can be plugged
+ * into UI code like $element.height(x).
+ *
+ * @property {number}
+ */
+ this.cssHeight = cssHeight;
+
+ /**
+ * Width of the thumbnail on the screen, in device pixels. On most devices this is the same as
+ * the CSS width, but devices with high pixel density displays have multiple screen pixels
+ * in a CSS pixel.
+ *
+ * This value is mostly used internally; for most purposes you will need one of the others.
+ *
+ * @property {number}
+ */
+ this.screen = screen;
+
+ /**
+ * "Real" width of the thumbnail. This is the number you need to use in API requests when
+ * obtaining the thumbnail URL. This is usually larger than the screen width, since
+ * downscaling images via CSS looks OK but upscaling them looks ugly. However, for images
+ * where the full size itself is very small, this can be smaller than the screen width, since
+ * we cannot create a thumbnail which is larger than the original image. (In such cases the
+ * image is just positioned to the center of the intended area and the space around it is
+ * left empty.)
+ *
+ * @property {number}
+ */
+ this.real = real;
+ }
+
+ mw.mmv.model.ThumbnailWidth = ThumbnailWidth;
+
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.js
new file mode 100644
index 00000000..2c986543
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/model/mmv.model.js
@@ -0,0 +1,20 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ mw.mmv.model = {};
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Api.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Api.js
new file mode 100644
index 00000000..b1b209b8
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Api.js
@@ -0,0 +1,199 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ /**
+ * Base class for API-based data providers.
+ *
+ * @class mw.mmv.provider.Api
+ * @abstract
+ * @constructor
+ * @param {mw.Api} api
+ * @param {Object} [options]
+ * @cfg {number} [maxage] cache expiration time, in seconds
+ * Will be used for both client-side cache (maxage) and reverse proxies (s-maxage)
+ */
+ function Api( api, options ) {
+ /**
+ * API object for dependency injection.
+ * @property {mw.Api}
+ */
+ this.api = api;
+
+ /**
+ * Options object; the exact format and meaning is unspecified and could be different
+ * from subclass to subclass.
+ * @property {Object}
+ */
+ this.options = options || {};
+
+ /**
+ * API call cache.
+ * @property {Object.<string, jQuery.Promise>} cache
+ * @protected
+ */
+ this.cache = {};
+ }
+
+ /**
+ * Wraps a caching layer around a function returning a promise; if getCachedPromise has been
+ * called with the same key already, it will return the previous result.
+ *
+ * Since it is the promise and not the API response that gets cached, this method can ensure
+ * that there are no race conditions and multiple calls to the same resource: even if the
+ * request is still in progress, separate calls (with the same key) to getCachedPromise will
+ * share on the same promise object.
+ * The promise is cached even if it is rejected, so if the API request fails, all later calls
+ * to getCachedPromise will fail immediately without retrying the request.
+ *
+ * @param {string} key cache key
+ * @param {function(): jQuery.Promise} getPromise a function to get the promise on cache miss
+ * @return {jQuery.Promise}
+ */
+ Api.prototype.getCachedPromise = function ( key, getPromise ) {
+ var provider = this;
+
+ if ( !this.cache[ key ] ) {
+ this.cache[ key ] = getPromise();
+ this.cache[ key ].fail( function ( error ) {
+ // constructor.name is usually not reliable in inherited classes, but OOjs fixes that
+ mw.log( provider.constructor.name + ' provider failed to load: ', error );
+ } );
+ }
+ return this.cache[ key ];
+ };
+
+ /**
+ * Calls mw.Api.get, with caching parameters.
+ *
+ * @param {Object} params Parameters to the API query.
+ * @param {Object} [ajaxOptions] ajaxOptions argument for mw.Api.get
+ * @param {number|null} [maxage] Cache the call for this many seconds.
+ * Sets both the maxage (client-side) and smaxage (proxy-side) caching parameters.
+ * Null means no caching. Undefined means the default caching period is used.
+ * @return {jQuery.Promise} the return value from mw.Api.get
+ */
+ Api.prototype.apiGetWithMaxAge = function ( params, ajaxOptions, maxage ) {
+ if ( maxage === undefined ) {
+ maxage = this.options.maxage;
+ }
+ if ( maxage ) {
+ params.maxage = params.smaxage = maxage;
+ }
+
+ return this.api.get( params, ajaxOptions );
+ };
+
+ /**
+ * Pulls an error message out of an API response.
+ *
+ * @param {Object} data
+ * @param {Object} data.error
+ * @param {string} data.error.code
+ * @param {string} data.error.info
+ * @return {string} From data.error.code + ': ' + data.error.info, or 'unknown error'
+ */
+ Api.prototype.getErrorMessage = function ( data ) {
+ var errorCode, errorMessage;
+ errorCode = data.error && data.error.code;
+ errorMessage = data.error && data.error.info || 'unknown error';
+ if ( errorCode ) {
+ errorMessage = errorCode + ': ' + errorMessage;
+ }
+ return errorMessage;
+ };
+
+ /**
+ * Returns a fixed a title based on the API response.
+ * The title of the returned file might be different from the requested title, e.g.
+ * if we used a namespace alias. If that happens the old and new title will be set in
+ * data.query.normalized; this method creates an updated title based on that.
+ *
+ * @param {mw.Title} title
+ * @param {Object} data
+ * @return {mw.Title}
+ */
+ Api.prototype.getNormalizedTitle = function ( title, data ) {
+ var i, normalized, length;
+ if ( data && data.query && data.query.normalized ) {
+ for ( normalized = data.query.normalized, length = normalized.length, i = 0; i < length; i++ ) {
+ if ( normalized[ i ].from === title.getPrefixedText() ) {
+ title = new mw.Title( normalized[ i ].to );
+ break;
+ }
+ }
+ }
+ return title;
+ };
+
+ /**
+ * Returns a promise with the specified field from the API result.
+ * This is intended to be used as a .then() callback for action=query APIs.
+ *
+ * @param {string} field
+ * @param {Object} data
+ * @return {jQuery.Promise} when successful, the first argument will be the field data,
+ * when unsuccessful, it will be an error message. The second argument is always
+ * the full API response.
+ */
+ Api.prototype.getQueryField = function ( field, data ) {
+ if ( data && data.query && data.query[ field ] ) {
+ return $.Deferred().resolve( data.query[ field ], data );
+ } else {
+ return $.Deferred().reject( this.getErrorMessage( data ), data );
+ }
+ };
+
+ /**
+ * Returns a promise with the specified page from the API result.
+ * This is intended to be used as a .then() callback for action=query&prop=(...) APIs.
+ *
+ * @param {mw.Title} title
+ * @param {Object} data
+ * @return {jQuery.Promise} when successful, the first argument will be the page data,
+ * when unsuccessful, it will be an error message. The second argument is always
+ * the full API response.
+ */
+ Api.prototype.getQueryPage = function ( title, data ) {
+ var pageName, pageData = null;
+ if ( data && data.query && data.query.pages ) {
+ title = this.getNormalizedTitle( title, data );
+ pageName = title.getPrefixedText();
+
+ // pages is an associative array indexed by pageid,
+ // we need to iterate through to find the right page
+ $.each( data.query.pages, function ( id, page ) {
+ if ( page.title === pageName ) {
+ pageData = page;
+ return false;
+ }
+ } );
+
+ if ( pageData ) {
+ return $.Deferred().resolve( pageData, data );
+ }
+ }
+
+ // If we got to this point either the pages array is missing completely, or we iterated
+ // through it and the requested page was not found. Neither is supposed to happen
+ // (if the page simply did not exist, there would still be a record for it).
+ return $.Deferred().reject( this.getErrorMessage( data ), data );
+ };
+
+ mw.mmv.provider = {};
+ mw.mmv.provider.Api = Api;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.FileRepoInfo.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.FileRepoInfo.js
new file mode 100644
index 00000000..8a526d62
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.FileRepoInfo.js
@@ -0,0 +1,63 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, oo, $ ) {
+
+ /**
+ * Gets file repo information.
+ *
+ * @class mw.mmv.provider.FileRepoInfo
+ * @extends mw.mmv.provider.Api
+ * @constructor
+ * @param {mw.Api} api
+ * @param {Object} [options]
+ * @cfg {number} [maxage] cache expiration time, in seconds
+ * Will be used for both client-side cache (maxage) and reverse proxies (s-maxage)
+ */
+ function FileRepoInfo( api, options ) {
+ mw.mmv.provider.Api.call( this, api, options );
+ }
+ oo.inheritClass( FileRepoInfo, mw.mmv.provider.Api );
+
+ /**
+ * Runs an API GET request to get the repo info.
+ *
+ * @return {jQuery.Promise.<Object.<string, mw.mmv.model.Repo>>} a promise which resolves to
+ * a hash of mw.mmv.model.Repo objects, indexed by repo names.
+ */
+ FileRepoInfo.prototype.get = function () {
+ var provider = this;
+
+ return this.getCachedPromise( '*', function () {
+ return provider.apiGetWithMaxAge( {
+ action: 'query',
+ meta: 'filerepoinfo',
+ uselang: 'content'
+ } ).then( function ( data ) {
+ return provider.getQueryField( 'repos', data );
+ } ).then( function ( reposArray ) {
+ var reposHash = {};
+ $.each( reposArray, function ( i, repo ) {
+ reposHash[ repo.name ] = mw.mmv.model.Repo.newFromRepoInfo( repo );
+ } );
+ return reposHash;
+ } );
+ } );
+ };
+
+ mw.mmv.provider.FileRepoInfo = FileRepoInfo;
+}( mediaWiki, OO, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.GuessedThumbnailInfo.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.GuessedThumbnailInfo.js
new file mode 100644
index 00000000..5ad76dbd
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.GuessedThumbnailInfo.js
@@ -0,0 +1,307 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ /**
+ * This provider is similar to mw.mmv.provider.ThumbnailInfo, but instead of making an API call
+ * to get the thumbnail URL, it tries to guess it. There are two failure modes:
+ * - known failure: in the given situation it does not seem possible or safe to guess the URL.
+ * It is up to the caller to obtain it by falling back to the normal provider.
+ * - unexpected failure: we guess an URL but it does not work. The current implementation is
+ * conservative so at least on WMF wikis this probably won't happen, but should be reckoned
+ * with anyway. On other wikis (especially ones which do not generate thumbnails on demand
+ * via the 404 handler) this could be more frequent. Again, it is the caller's resonsibility
+ * to handle this by detecting image loading errors and falling back to the normal provider.
+ *
+ * @class mw.mmv.provider.GuessedThumbnailInfo
+ * @constructor
+ */
+ function GuessedThumbnailInfo() {}
+
+ /**
+ * File extensions which are vector types (as opposed to bitmap).
+ * Thumbnails of vector types can be larger than the original file.
+ * @property {Object.<string, number>}
+ */
+ GuessedThumbnailInfo.prototype.vectorExtensions = {
+ svg: 1
+ };
+
+ /**
+ * File extensions which can be displayed in the browser.
+ * Other file types need to be thumbnailed even if the size of the original file would be right.
+ * @property {Object.<string, number>}
+ */
+ GuessedThumbnailInfo.prototype.displayableExtensions = {
+ png: 1,
+ jpg: 1,
+ jpeg: 1,
+ gif: 1
+ };
+
+ /**
+ * Try to guess the thumbnailinfo for a thumbnail without doing an API request.
+ * An existing thumbnail URL is required.
+ *
+ * There is no guarantee this function will be successful - in some cases, it is impossible
+ * to guess how the URL would look. If that's the case, the promise just rejects.
+ *
+ * @param {mw.Title} file
+ * @param {string} sampleUrl a thumbnail URL for the same file (but with different size).
+ * @param {number} width thumbnail width in pixels
+ * @param {number} originalWidth width of original image in pixels
+ * @param {number} originalHeight height of original image in pixels
+ * @return {jQuery.Promise.<mw.mmv.model.Thumbnail>}
+ */
+ GuessedThumbnailInfo.prototype.get = function ( file, sampleUrl, width, originalWidth, originalHeight ) {
+ var url = this.getUrl( file, sampleUrl, width, originalWidth );
+ if ( url ) {
+ return $.Deferred().resolve( new mw.mmv.model.Thumbnail(
+ url,
+ this.guessWidth( file, width, originalWidth ),
+ this.guessHeight( file, width, originalWidth, originalHeight )
+ ) );
+ } else {
+ return $.Deferred().reject( 'Could not guess thumbnail URL' );
+ }
+ };
+
+ /**
+ * Try to guess the URL of a thumbnail without doing an API request.
+ * See #get().
+ *
+ * @param {mw.Title} file
+ * @param {string} sampleUrl a thumbnail URL for the same file (but with different size)
+ * @param {number} width thumbnail width in pixels
+ * @param {number} originalWidth width of original image in pixels
+ * @return {string|undefined} a thumbnail URL or nothing
+ */
+ GuessedThumbnailInfo.prototype.getUrl = function ( file, sampleUrl, width, originalWidth ) {
+ var needsFullSize = this.needsOriginal( file, width, originalWidth ),
+ sampleIsFullSize = this.isFullSizeUrl( sampleUrl, file );
+
+ if ( sampleIsFullSize && needsFullSize ) {
+ // sample thumbnail uses full size, and we need full size as well - the sample URL
+ // happens to be just the right one for us
+ return sampleUrl;
+ } else if ( !sampleIsFullSize && !needsFullSize ) {
+ // need to convert a scaled thumbnail URL to another scaled thumbnail URL
+ return this.replaceSize( file, sampleUrl, width );
+ } else if ( !sampleIsFullSize && needsFullSize ) {
+ if ( this.canBeDisplayedInBrowser( file ) ) {
+ // the size requested is larger than the original - we need to return an URL
+ // to the original file instead
+ return this.guessFullUrl( file, sampleUrl );
+ } else {
+ // the size requested is larger than the original, but this file type cannot
+ // be displayed by all browsers, so needs to be thumbnailed anyway,
+ // but the thumbnail still cannot be larger than the original file
+ return this.replaceSize( file, sampleUrl, originalWidth );
+ }
+ } else { // sampleIsFullSize && !needsOriginal
+ return this.guessThumbUrl( file, sampleUrl, width );
+ }
+ };
+
+ /**
+ * True if the the original image needs to be used as a thumbnail.
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @param {number} width thumbnail width in pixels
+ * @param {number} originalWidth width of original image in pixels
+ * @return {boolean}
+ */
+ GuessedThumbnailInfo.prototype.needsOriginal = function ( file, width, originalWidth ) {
+ return width >= originalWidth && !this.canHaveLargerThumbnailThanOriginal( file );
+ };
+
+ /**
+ * Checks if a given thumbnail URL is full-size (the original image) or scaled
+ *
+ * @protected
+ * @param {string} url a thumbnail URL
+ * @param {mw.Title} file
+ * @return {boolean}
+ */
+ GuessedThumbnailInfo.prototype.isFullSizeUrl = function ( url, file ) {
+ return !this.obscureFilename( url, file ).match( '/thumb/' );
+ };
+
+ /**
+ * Removes the filename in a reversible way. This is useful because the filename can be nearly
+ * anything and could cause false positives when looking for patterns.
+ *
+ * @protected
+ * @param {string} url a thumbnail URL
+ * @param {mw.Title} file
+ * @return {string} thumbnnail URL with occurences of the filename replaced by `<filename>`
+ */
+ GuessedThumbnailInfo.prototype.obscureFilename = function ( url, file ) {
+ // corresponds to File::getUrlRel() which uses rawurlencode()
+ var filenameInUrl = mw.util.rawurlencode( file.getMain() );
+
+ // In the URL to the original file the filename occurs once. In a thumbnail URL it usually
+ // occurs twice, but can occur once if it is too short. We replace twice, can't hurt.
+ return url.replace( filenameInUrl, '<filename>' ).replace( filenameInUrl, '<filename>' );
+ };
+
+ /**
+ * Undoes #obscureFilename().
+ *
+ * @protected
+ * @param {string} url a thumbnail URL (with obscured filename)
+ * @param {mw.Title} file
+ * @return {string} original thumbnnail URL
+ */
+ GuessedThumbnailInfo.prototype.restoreFilename = function ( url, file ) {
+ // corresponds to File::getUrlRel() which uses rawurlencode()
+ var filenameInUrl = mw.util.rawurlencode( file.getMain() );
+
+ // <> cannot be used in titles, so this is safe
+ return url.replace( '<filename>', filenameInUrl ).replace( '<filename>', filenameInUrl );
+ };
+
+ /**
+ * True if the file is of a type for which the thumbnail can be scaled beyond the original size.
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @return {boolean}
+ */
+ GuessedThumbnailInfo.prototype.canHaveLargerThumbnailThanOriginal = function ( file ) {
+ return ( file.getExtension().toLowerCase() in this.vectorExtensions );
+ };
+
+ /**
+ * True if the file type can be displayed in most browsers, false if it needs thumbnailing
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @return {boolean}
+ */
+ GuessedThumbnailInfo.prototype.canBeDisplayedInBrowser = function ( file ) {
+ return ( file.getExtension().toLowerCase() in this.displayableExtensions );
+ };
+
+ /**
+ * Guess what will be the width of the thumbnail. (Thumbnails for most file formats cannot be
+ * larger than the original file so this might be smaller than the requested width.)
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @param {number} width thumbnail width in pixels
+ * @param {number} originalWidth width of original image in pixels
+ * @return {number} guessed width
+ */
+ GuessedThumbnailInfo.prototype.guessWidth = function ( file, width, originalWidth ) {
+ if ( width >= originalWidth && !this.canHaveLargerThumbnailThanOriginal( file ) ) {
+ return originalWidth;
+ } else {
+ return width;
+ }
+ };
+
+ /**
+ * Guess what will be the height of the thumbnail, given its width.
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @param {number} width thumbnail width in pixels
+ * @param {number} originalWidth width of original image in pixels
+ * @param {number} originalHeight height of original image in pixels
+ * @return {number} guessed height
+ */
+ GuessedThumbnailInfo.prototype.guessHeight = function ( file, width, originalWidth, originalHeight ) {
+ if ( width >= originalWidth && !this.canHaveLargerThumbnailThanOriginal( file ) ) {
+ return originalHeight;
+ } else {
+ // might be off 1px due to rounding (we don't know what exact scaling method the
+ // backend uses) but that should not cause any issues
+ return Math.round( width * ( originalHeight / originalWidth ) );
+ }
+ };
+
+ /**
+ * Given a thumbnail URL with a wrong size, returns one with the right size.
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @param {string} sampleUrl a thumbnail URL for the same file (but with different size)
+ * @param {number} width thumbnail width in pixels
+ * @return {string|undefined} thumbnail URL with the correct size
+ */
+ GuessedThumbnailInfo.prototype.replaceSize = function ( file, sampleUrl, width ) {
+ var url = this.obscureFilename( sampleUrl, file ),
+ sizeRegexp = /\b\d{1,5}px\b/;
+
+ // this should never happen, but let's play it safe - returning the sample URL and believing
+ // it is the resized one would be bad. Returning a wrong filename is not catastrophical
+ // as long as we return a non-working wrong filename, which would not be the case here.
+ if ( !url.match( sizeRegexp ) ) {
+ return undefined;
+ }
+
+ // we are assuming here that the other thumbnail parameters do not look like a size
+ url = url.replace( sizeRegexp, width + 'px' );
+
+ return this.restoreFilename( url, file );
+ };
+
+ /**
+ * Try to guess the original URL to the file, from a thumb URL.
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @param {string} thumbnailUrl
+ * @return {string} URL of the original file
+ */
+ GuessedThumbnailInfo.prototype.guessFullUrl = function ( file, thumbnailUrl ) {
+ var url = this.obscureFilename( thumbnailUrl, file );
+
+ if ( url === thumbnailUrl ) {
+ // Did not find the filename, maybe due to URL encoding issues. Bail out.
+ return undefined;
+ }
+
+ // this depends on some config settings, but will work with default or WMF settings.
+ url = url.replace( /<filename>.*/, '<filename>' );
+ url = url.replace( '/thumb', '' );
+
+ return this.restoreFilename( url, file );
+ };
+
+ /**
+ * Hardest version: try to guess thumbnail URL from original
+ *
+ * @protected
+ * @param {mw.Title} file
+ * @param {string} originalUrl URL for the original file
+ * @param {number} width thumbnail width in pixels
+ * @return {string|undefined} thumbnail URL
+ */
+ GuessedThumbnailInfo.prototype.guessThumbUrl = function () {
+ // Not implemented. This can be very complicated (the thumbnail might have other
+ // parameters than the size, which are impossible to guess, might be converted to some
+ // other format, might have a special shortened format depending on the length of the
+ // filename) and it is unlikely to be useful - it would be only called when we need
+ // a thumbnail that is smaller than the sample (the thumbnail which is already on the page).
+ return undefined;
+ };
+
+ mw.mmv.provider.GuessedThumbnailInfo = GuessedThumbnailInfo;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Image.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Image.js
new file mode 100644
index 00000000..9a20edfd
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.Image.js
@@ -0,0 +1,153 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+
+ /**
+ * Loads an image.
+ *
+ * @class mw.mmv.provider.Image
+ * @constructor
+ * @param {string} imageQueryParameter When defined, is a query parameter to add to every image request
+ */
+ function Image( imageQueryParameter ) {
+ /**
+ * @property {mw.mmv.logging.PerformanceLogger}
+ * @private
+ */
+ this.performance = new mw.mmv.logging.PerformanceLogger();
+
+ this.imageQueryParameter = imageQueryParameter;
+
+ /**
+ * AJAX call cache.
+ * @property {Object.<string, jQuery.Promise>} cache
+ * @protected
+ */
+ this.cache = {};
+ }
+
+ /**
+ * Loads an image and returns it. Includes performance metrics via mw.mmv.logging.PerformanceLogger.
+ * When the browser supports it, the image is loaded as an AJAX request.
+ *
+ * @param {string} url
+ * @param {jQuery.Deferred.<string>} extraStatsDeferred A promise which resolves to extra statistics.
+ * @return {jQuery.Promise.<HTMLImageElement>} A promise which resolves to the image object.
+ * When loaded via AJAX, it has progress events, which return an array with the content loaded
+ * so far and with the progress as a floating-point number between 0 and 100.
+ */
+ Image.prototype.get = function ( url, extraStatsDeferred ) {
+ var provider = this,
+ cacheKey = url,
+ extraParam = {},
+ start,
+ rawGet,
+ uri;
+
+ if ( this.imageQueryParameter ) {
+ uri = new mw.Uri( url );
+ extraParam[ this.imageQueryParameter ] = null;
+ url = uri.extend( extraParam ).toString();
+ }
+
+ if ( !this.cache[ cacheKey ] ) {
+ if ( this.imagePreloadingSupported() ) {
+ rawGet = $.proxy( provider.rawGet, provider, url, true );
+ this.cache[ cacheKey ] = this.performance.record( 'image', url, extraStatsDeferred ).then( rawGet, rawGet );
+ } else {
+ start = $.now();
+ this.cache[ cacheKey ] = this.rawGet( url );
+ this.cache[ cacheKey ].always( function () {
+ provider.performance.recordEntry( 'image', $.now() - start, url, undefined, extraStatsDeferred );
+ } );
+ }
+ this.cache[ cacheKey ].fail( function ( error ) {
+ mw.log( provider.constructor.name + ' provider failed to load: ', error );
+ } );
+ }
+
+ return this.cache[ cacheKey ];
+ };
+
+ /**
+ * Internal version of get(): no caching, no performance metrics.
+ *
+ * @param {string} url
+ * @param {boolean} [cors] if true, use CORS for preloading
+ * @return {jQuery.Promise.<HTMLImageElement>} a promise which resolves to the image object
+ */
+ Image.prototype.rawGet = function ( url, cors ) {
+ var img = new window.Image(),
+ deferred = $.Deferred();
+
+ // This attribute is necessary in Firefox, which needs it for the image request after
+ // the XHR to hit the cache by being a proper CORS request. In IE11, however,
+ // the presence of that attribute would cause the second image request to miss the cache,
+ // because IE11 adds a no-cache request header to image CORS requests. As a result,
+ // we call needsCrossOrigin to check if the current browser needs to set the attribute
+ // or not in order to avoid loading the image twice.
+ if ( cors && this.needsCrossOrigin() ) {
+ img.crossOrigin = 'anonymous';
+ }
+
+ img.onload = function () {
+ deferred.resolve( img );
+ };
+ img.onerror = function () {
+ deferred.reject( 'could not load image from ' + url );
+ };
+
+ img.src = url;
+
+ return deferred;
+ };
+
+ /**
+ * Checks whether the current browser supports AJAX preloading of images.
+ * This means that:
+ * - the browser supports CORS requests (large wiki farms usually host images on a
+ * separate domain) and
+ * - either AJAX and normal image loading uses the same cache (when an image is used by a CORS
+ * request, and then normally by setting img.src, it is only loaded once)
+ * - or (as is the case with Firefox) they are cached separately, but that can be changed by
+ * setting the crossOrigin attribute
+ *
+ * @return {boolean}
+ */
+ Image.prototype.imagePreloadingSupported = function () {
+ // This checks if the browser supports CORS requests in XHRs
+ return window.XMLHttpRequest !== undefined && 'withCredentials' in new XMLHttpRequest();
+ };
+
+ /**
+ * Checks whether the current browser needs to set crossOrigin on images to avoid
+ * doing a double load
+ *
+ * @return {boolean} Browser needs to set crossOrigin
+ */
+ Image.prototype.needsCrossOrigin = function () {
+ // Support: IE11
+ // This check is essentially "is this browser anything but IE > 10?".
+ // I couldn't find something more topical because IE11 does support the crossOrigin
+ // attribute, just in a counter-productive way compared to all the other browsers
+ // who also support it.
+ return window.MSInputMethodContext === undefined;
+ };
+
+ mw.mmv.provider.Image = Image;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ImageInfo.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ImageInfo.js
new file mode 100644
index 00000000..9973fe99
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ImageInfo.js
@@ -0,0 +1,117 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, oo, $ ) {
+
+ /**
+ * Gets file information.
+ *
+ * See https://www.mediawiki.org/wiki/API:Properties#imageinfo_.2F_ii
+ *
+ * @class mw.mmv.provider.ImageInfo
+ * @extends mw.mmv.provider.Api
+ * @constructor
+ * @param {mw.Api} api
+ * @param {Object} [options]
+ * @cfg {string} [language=null] image metadata language
+ * @cfg {number} [maxage] cache expiration time, in seconds
+ * Will be used for both client-side cache (maxage) and reverse proxies (s-maxage)
+ */
+ function ImageInfo( api, options ) {
+ options = $.extend( {
+ language: null
+ }, options );
+
+ mw.mmv.provider.Api.call( this, api, options );
+ }
+ oo.inheritClass( ImageInfo, mw.mmv.provider.Api );
+
+ /**
+ * List of imageinfo API properties which are needed to construct an Image model.
+ *
+ * @property {string}
+ */
+ ImageInfo.prototype.iiprop = [
+ 'timestamp',
+ 'url',
+ 'size',
+ 'mime',
+ 'mediatype',
+ 'extmetadata'
+ ].join( '|' );
+
+ /**
+ * List of imageinfo extmetadata fields which are needed to construct an Image model.
+ *
+ * @property {string}
+ */
+ ImageInfo.prototype.iiextmetadatafilter = [
+ 'DateTime',
+ 'DateTimeOriginal',
+ 'ObjectName',
+ 'ImageDescription',
+ 'License',
+ 'LicenseShortName',
+ 'UsageTerms',
+ 'LicenseUrl',
+ 'Credit',
+ 'Artist',
+ 'AuthorCount',
+ 'GPSLatitude',
+ 'GPSLongitude',
+ 'Permission',
+ 'Attribution',
+ 'AttributionRequired',
+ 'NonFree',
+ 'Restrictions',
+ 'DeletionReason'
+ ].join( '|' );
+
+ /**
+ * Runs an API GET request to get the image info.
+ *
+ * @param {mw.Title} file
+ * @return {jQuery.Promise} a promise which resolves to an mw.mmv.model.Image object.
+ */
+ ImageInfo.prototype.get = function ( file ) {
+ var provider = this;
+
+ return this.getCachedPromise( file.getPrefixedDb(), function () {
+ return provider.apiGetWithMaxAge( {
+ action: 'query',
+ prop: 'imageinfo',
+ titles: file.getPrefixedDb(),
+ iiprop: provider.iiprop,
+ iiextmetadatafilter: provider.iiextmetadatafilter,
+ iiextmetadatalanguage: provider.options.language,
+ uselang: 'content'
+ } ).then( function ( data ) {
+ return provider.getQueryPage( file, data );
+ } ).then( function ( page ) {
+ if ( page.imageinfo && page.imageinfo.length ) {
+ return mw.mmv.model.Image.newFromImageInfo( file, page );
+ } else if ( page.missing === '' && page.imagerepository === '' ) {
+ return $.Deferred().reject( 'file does not exist: ' + file.getPrefixedDb() );
+ } else {
+ return $.Deferred().reject( 'unknown error' );
+ }
+ } );
+ } );
+ };
+
+ mw.mmv.provider.ImageInfo = ImageInfo;
+}( mediaWiki, OO, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ThumbnailInfo.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ThumbnailInfo.js
new file mode 100644
index 00000000..45b6cdef
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/provider/mmv.provider.ThumbnailInfo.js
@@ -0,0 +1,89 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, oo, $ ) {
+
+ /**
+ * Gets thumbnail information.
+ *
+ * See https://www.mediawiki.org/wiki/API:Properties#imageinfo_.2F_ii
+ *
+ * @class mw.mmv.provider.ThumbnailInfo
+ * @extends mw.mmv.provider.Api
+ * @constructor
+ * @param {mw.Api} api
+ * @param {Object} [options]
+ * @cfg {number} [maxage] cache expiration time, in seconds
+ * Will be used for both client-side cache (maxage) and reverse proxies (s-maxage)
+ */
+ function ThumbnailInfo( api, options ) {
+ mw.mmv.provider.Api.call( this, api, options );
+ }
+ oo.inheritClass( ThumbnailInfo, mw.mmv.provider.Api );
+
+ /**
+ * Runs an API GET request to get the thumbnail info for the specified size.
+ * The thumbnail always has the same aspect ratio as the full image.
+ * One of width or height can be null; if both are set, the API will return the largest
+ * thumbnail which fits into a width x height bounding box (or the full-sized image - whichever
+ * is smaller).
+ *
+ * @param {mw.Title} file
+ * @param {number} width thumbnail width in pixels
+ * @param {number} height thumbnail height in pixels
+ * @return {jQuery.Promise.<mw.mmv.model.Thumbnail>}
+ */
+ ThumbnailInfo.prototype.get = function ( file, width, height ) {
+ var provider = this,
+ cacheKey = file.getPrefixedDb() + '|' + ( width || '' ) + '|' + ( height || '' );
+
+ return this.getCachedPromise( cacheKey, function () {
+ return provider.apiGetWithMaxAge( {
+ action: 'query',
+ prop: 'imageinfo',
+ titles: file.getPrefixedDb(),
+ iiprop: 'url',
+ iiurlwidth: width, // mw.Api will omit null/undefined parameters
+ iiurlheight: height
+ } ).then( function ( data ) {
+ return provider.getQueryPage( file, data );
+ } ).then( function ( page ) {
+ var imageInfo;
+ if ( page.imageinfo && page.imageinfo[ 0 ] ) {
+ imageInfo = page.imageinfo[ 0 ];
+ if ( imageInfo.thumburl && imageInfo.thumbwidth && imageInfo.thumbheight ) {
+ return $.Deferred().resolve(
+ new mw.mmv.model.Thumbnail(
+ imageInfo.thumburl,
+ imageInfo.thumbwidth,
+ imageInfo.thumbheight
+ )
+ );
+ } else {
+ return $.Deferred().reject( 'error in provider, thumb info not found' );
+ }
+ } else if ( page.missing === '' && page.imagerepository === '' ) {
+ return $.Deferred().reject( 'file does not exist: ' + file.getPrefixedDb() );
+ } else {
+ return $.Deferred().reject( 'unknown error' );
+ }
+ } );
+ } );
+ };
+
+ mw.mmv.provider.ThumbnailInfo = ThumbnailInfo;
+}( mediaWiki, OO, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.MainFileRoute.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.MainFileRoute.js
new file mode 100644
index 00000000..391a7703
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.MainFileRoute.js
@@ -0,0 +1,30 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, oo ) {
+ /**
+ * Route for showing the main image on the page, (whatever that means might depend on the page).
+ * This is typically used on file pages.
+ *
+ * @class mw.mmv.routing.MainFileRoute
+ * @extends mw.mmv.routing.Route
+ * @constructor
+ */
+ function MainFileRoute() {}
+ oo.inheritClass( MainFileRoute, mw.mmv.routing.Route );
+ mw.mmv.routing.MainFileRoute = MainFileRoute;
+}( mediaWiki, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Route.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Route.js
new file mode 100644
index 00000000..4985dd81
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Route.js
@@ -0,0 +1,28 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ /**
+ * The base class for routes. Route classes don't really do anything, they are just simple
+ * containers which specify a certain way of referencing images.
+ *
+ * @class mw.mmv.routing.Route
+ * @constructor
+ */
+ function Route() {}
+ mw.mmv.routing.Route = Route;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Router.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Router.js
new file mode 100644
index 00000000..093bbb6a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.Router.js
@@ -0,0 +1,197 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ var RP;
+
+ /**
+ * Converts between routes and their URL hash representations such as `mediaviewer/File:Foo`.
+ *
+ * @class mw.mmv.routing.Router
+ * @constructor
+ */
+ function Router() {}
+ RP = Router.prototype;
+
+ /**
+ * The prefix originally used to namespace MediaViewer routing hashes. Since there are many links
+ * out there pointing to those URLs, we should keep them working.
+ *
+ * @protected
+ * @property {string}
+ */
+ RP.legacyPrefix = 'mediaviewer';
+
+ /**
+ * The prefix used to namespace MediaViewer routing hashes
+ *
+ * @protected
+ * @property {string}
+ */
+ RP.applicationPrefix = '/media';
+
+ /**
+ * Takes an URL hash and returns a route (or null if it could not be parsed).
+ * Returns null for URL hashes which were not created by MediaViewer; you should use
+ * #isMediaViewerHash() if you want to differentiate such hashes.
+ * The hash can contain the starting `#` but does not have to; it should be in raw (percent-
+ * encoded) form. Note that the percent-encoding behavior of location.hash is not consistent
+ * between browsers; location.href can be used instead.
+ *
+ * @param {string} hash
+ * @return {mw.mmv.routing.Route|null}
+ */
+ RP.parseHash = function ( hash ) {
+ var hashParts, fileName;
+
+ hashParts = this.tokenizeHash( hash );
+
+ if ( hashParts.length === 0 ) {
+ return null;
+ } else if ( hashParts.length === 1 ) {
+ return new mw.mmv.routing.MainFileRoute();
+ } else if ( hashParts.length === 2 ) {
+ fileName = this.decodeRouteComponent( hashParts[ 1 ] );
+ return new mw.mmv.routing.ThumbnailRoute( new mw.Title( fileName ) );
+ }
+
+ return null;
+ };
+
+ /**
+ * Takes a route and returns a string representation which can be used in the URL fragment.
+ * The string does not contain the starting `#`, and it is encoded and guaranteed to be a
+ * valid URL.
+ *
+ * @param {mw.mmv.routing.Route} route
+ * @return {string}
+ */
+ RP.createHash = function ( route ) {
+ if ( route instanceof mw.mmv.routing.ThumbnailRoute ) {
+ return this.applicationPrefix + '/' +
+ this.encodeRouteComponent( 'File:' + route.fileTitle.getMain() );
+ } else if ( route instanceof mw.mmv.routing.MainFileRoute ) {
+ return this.applicationPrefix;
+ } else if ( route instanceof mw.mmv.routing.Route ) {
+ throw new Error( 'mw.mmv.routing.Router.createHash: not implemented for ' + route.constructor.name );
+ } else {
+ throw new Error( 'mw.mmv.routing.Router.createHash: invalid argument' );
+ }
+ };
+
+ /**
+ * Like #parseHash(), but takes a window.location object. This is a helper function to make
+ * sure that hashes are decoded correctly in spite of browser inconsistencies.
+ *
+ * @param {{href: string}} location window.location object
+ * @return {mw.mmv.routing.Route|null}
+ */
+ RP.parseLocation = function ( location ) {
+ // Firefox percent-decodes location.hash: https://bugzilla.mozilla.org/show_bug.cgi?id=483304
+ // which would cause inconsistent cross-browser behavior for files which have % or /
+ // characters in their names. Using location.href is safe.
+ return this.parseHash( location.href.split( '#' )[ 1 ] || '' );
+ };
+
+ /**
+ * Like #createHash(), but appends the hash to a specified URL
+ *
+ * @param {mw.mmv.routing.Route} route
+ * @param {string} baseUrl the URL of the page the image is on (can contain a hash part,
+ * which will be stripped)
+ * @return {string} an URL to the same page as baseUrl, with the hash for the given route
+ */
+ RP.createHashedUrl = function ( route, baseUrl ) {
+ return baseUrl.replace( /#.*/, '' ) + '#' + this.createHash( route );
+ };
+
+ /**
+ * Returns true if this hash looks like it was created by MediaViewer.
+ * The hash can contain the starting `#` but does not have to.
+ *
+ * @param {string} hash
+ * @return {boolean}
+ */
+ RP.isMediaViewerHash = function ( hash ) {
+ return this.tokenizeHash( hash ).length !== 0;
+ };
+
+ /**
+ * Returns "segments" of a hash. The first segment is always the #applicationPrefix.
+ * If the hash is not a MediaViewer routing hash, an empty array is returned.
+ * The input hash can contain the starting `#` but does not have to.
+ *
+ * @protected
+ * @param {string} hash
+ * @return {string[]}
+ */
+ RP.tokenizeHash = function ( hash ) {
+ var prefix,
+ hashParts;
+
+ if ( hash[ 0 ] === '#' ) {
+ hash = hash.slice( 1 );
+ }
+
+ if ( hash.indexOf( this.legacyPrefix ) === 0 ) {
+ prefix = this.legacyPrefix;
+ }
+
+ if ( hash.indexOf( this.applicationPrefix ) === 0 ) {
+ prefix = this.applicationPrefix;
+ }
+
+ if ( prefix === undefined ) {
+ return [];
+ }
+
+ hash = hash.slice( prefix.length );
+
+ hashParts = hash.split( '/' );
+ hashParts[ 0 ] = prefix;
+
+ return hashParts;
+ };
+
+ /**
+ * URL-encodes a route component.
+ * Almost identical to mw.util.wikiUrlencode but makes sure there are no unencoded `/`
+ * characters left since we use those to delimit components.
+ *
+ * @protected
+ * @param {string} component
+ * @return {string}
+ */
+ RP.encodeRouteComponent = function ( component ) {
+ return mw.util.wikiUrlencode( component ).replace( /\//g, '%2F' );
+ };
+
+ /**
+ * URL-decodes a route component.
+ * This is basically just a standard percent-decode, but for backwards compatibility with
+ * older schemes, we also replace spaces which underlines (the current scheme never has spaces).
+ *
+ * @protected
+ * @param {string} component
+ * @return {string}
+ */
+ RP.decodeRouteComponent = function ( component ) {
+ return decodeURIComponent( component ).replace( / /g, '_' );
+ };
+
+ mw.mmv.routing.Router = Router;
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.ThumbnailRoute.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.ThumbnailRoute.js
new file mode 100644
index 00000000..328ad8c9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.ThumbnailRoute.js
@@ -0,0 +1,36 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, oo ) {
+ /**
+ * Route for a specific thumbnail on the current page. The thumbnail must be that of a wiki
+ * file (can't be e.g. an external image); can be a file from a remote repo though.
+ *
+ * @class mw.mmv.routing.ThumbnailRoute
+ * @extends mw.mmv.routing.Route
+ * @constructor
+ * @param {mw.Title} fileTitle the name of the image
+ */
+ function ThumbnailRoute( fileTitle ) {
+ if ( !fileTitle ) {
+ throw new Error( 'mw.mmv.routing.ThumbnailRoute: fileTitle parameter is required' );
+ }
+ this.fileTitle = fileTitle;
+ }
+ oo.inheritClass( ThumbnailRoute, mw.mmv.routing.Route );
+ mw.mmv.routing.ThumbnailRoute = ThumbnailRoute;
+}( mediaWiki, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.js
new file mode 100644
index 00000000..34785f0a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/routing/mmv.routing.js
@@ -0,0 +1,20 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ mw.mmv.routing = {};
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/checker.png b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/checker.png
new file mode 100644
index 00000000..3e9e3d09
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/checker.png
Binary files differ
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/cc.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/cc.svg
new file mode 100644
index 00000000..998f30a0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/cc.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="5.5 -3.5 64 64">
+ <circle cx="37.785" cy="28.501" r="28.836" fill="none" stroke="#72777d"/>
+ <path fill="#72777d" d="M37.441-3.5c8.951 0 16.572 3.125 22.857 9.372 3.008 3.009 5.295 6.448 6.857 10.314 1.561 3.867 2.344 7.971 2.344 12.314 0 4.381-.773 8.486-2.314 12.313-1.543 3.828-3.82 7.21-6.828 10.143-3.123 3.085-6.666 5.448-10.629 7.086-3.961 1.638-8.057 2.457-12.285 2.457s-8.276-.808-12.143-2.429c-3.866-1.618-7.333-3.961-10.4-7.027-3.067-3.066-5.4-6.524-7-10.372S5.5 32.767 5.5 28.5c0-4.229.809-8.295 2.428-12.2 1.619-3.905 3.972-7.4 7.057-10.486C21.08-.394 28.565-3.5 37.441-3.5zm.116 5.772c-7.314 0-13.467 2.553-18.458 7.657-2.515 2.553-4.448 5.419-5.8 8.6a25.204 25.204 0 0 0-2.029 9.972c0 3.429.675 6.734 2.029 9.913 1.353 3.183 3.285 6.021 5.8 8.516 2.514 2.496 5.351 4.399 8.515 5.715a25.652 25.652 0 0 0 9.943 1.971c3.428 0 6.75-.665 9.973-1.999 3.219-1.335 6.121-3.257 8.713-5.771 4.99-4.876 7.484-10.99 7.484-18.344 0-3.543-.648-6.895-1.943-10.057-1.293-3.162-3.18-5.98-5.654-8.458-5.146-5.143-11.335-7.715-18.573-7.715zm-.401 20.915l-4.287 2.229c-.458-.951-1.019-1.619-1.685-2-.667-.38-1.286-.571-1.858-.571-2.856 0-4.286 1.885-4.286 5.657 0 1.714.362 3.084 1.085 4.113.724 1.029 1.791 1.544 3.201 1.544 1.867 0 3.181-.915 3.944-2.743l3.942 2c-.838 1.563-2 2.791-3.486 3.686-1.484.896-3.123 1.343-4.914 1.343-2.857 0-5.163-.875-6.915-2.629-1.752-1.752-2.628-4.19-2.628-7.313 0-3.048.886-5.466 2.657-7.257 1.771-1.79 4.009-2.686 6.715-2.686 3.963-.002 6.8 1.541 8.515 4.627zm18.457 0l-4.229 2.229c-.457-.951-1.02-1.619-1.686-2-.668-.38-1.307-.571-1.914-.571-2.857 0-4.287 1.885-4.287 5.657 0 1.714.363 3.084 1.086 4.113.723 1.029 1.789 1.544 3.201 1.544 1.865 0 3.18-.915 3.941-2.743l4 2c-.875 1.563-2.057 2.791-3.541 3.686a9.233 9.233 0 0 1-4.857 1.343c-2.896 0-5.209-.875-6.941-2.629-1.736-1.752-2.602-4.19-2.602-7.313 0-3.048.885-5.466 2.658-7.257 1.77-1.79 4.008-2.686 6.713-2.686 3.962-.002 6.783 1.541 8.458 4.627z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/commons_white.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/commons_white.svg
new file mode 100644
index 00000000..aa7f0262
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/commons_white.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 80 80">
+ <g fill="#fff">
+ <path d="M39.022 80c-8.302-.252-15.975-4.025-21.384-10.314-4.528-5.283-6.918-11.95-6.918-18.994 0-7.044 2.39-13.71 7.044-19.12.629-.754 2.138-2.264 2.264-2.264l3.9 3.9 3.899 3.899 1.132-1.006c.629-.63 1.132-1.007 1.132-1.007s.754 2.39 2.264 8.05c0 0 0 .126-.126.126 0 0-7.421-2.012-7.924-2.138h-.126s.503-.503 1.006-1.132a11.797 11.797 0 0 0 1.006-1.132c0-.126-1.886-2.013-1.886-2.013s-.504.63-1.007 1.132a20.56 20.56 0 0 0-4.276 10.566c-.126 1.007-.126 1.133 0 1.258h2.767v-1.51c0-1.509 0-1.509.126-1.509.125 0 7.17 4.151 7.17 4.151s0 .126-.126.126c-.126-.126-7.044 3.774-7.044 3.774v-3.02h-2.768v.378c0 .755.252 2.139.503 3.145.63 3.019 2.013 5.786 3.9 8.176.377.377 1.006 1.258 1.006 1.258s2.013-1.887 2.013-2.013c0 0-.503-.503-1.007-1.132-.628-.629-1.006-1.132-1.006-1.132 0-.126 8.05-2.264 8.05-2.138l-2.138 8.05s-.377-.377-1.132-1.006l-1.132-1.132c-.126 0-2.013 1.887-1.887 2.012 0 .126.755.755 1.384 1.132 2.39 1.761 5.157 3.145 8.176 3.774 1.006.252 2.39.377 3.145.503h.377v-2.767H36.38c0-.126 4.151-7.296 4.151-7.296s4.15 7.17 4.15 7.296h-3.018v2.767h.377c.755 0 2.139-.251 3.145-.503 3.019-.629 5.786-2.013 8.176-3.774a23.22 23.22 0 0 0 1.384-1.132c.126-.125-1.887-2.012-1.887-2.012l-1.132 1.132a11.797 11.797 0 0 1-1.132 1.006c0-.126-2.138-8.05-2.138-8.05l8.05 2.138s-.378.378-1.006 1.132c-.63.63-1.007 1.132-1.007 1.132 0 .126 1.887 2.013 2.013 2.013.126 0 .755-.755 1.006-1.258 1.887-2.39 3.145-5.283 3.9-8.176.251-1.006.377-2.39.377-3.145v-.377h-3.522v3.019s-6.918-3.9-7.17-4.151l-.126-.126s7.044-4.15 7.17-4.15c.126 0 .126 0 .126 1.509v1.509s2.641.126 2.767 0v-1.258a20.56 20.56 0 0 0-4.277-10.566c-.503-.629-1.006-1.132-1.006-1.132l-1.887 1.887s.503.503 1.007 1.132a11.826 11.826 0 0 1 1.006 1.132l-.126.126c-.503.126-7.924 2.138-7.924 2.138s-.126 0 0-.126c1.509-5.534 2.138-7.924 2.264-8.05 0 0 .503.377 1.132 1.006l1.132 1.007 1.006-1.007 1.006-1.006s-.628-.503-1.132-.88c-1.132-.755-1.886-1.007-5.534-2.516-2.516-1.007-3.774-1.635-5.283-2.642-3.27-2.264-5.409-5.157-6.793-9.308-.125-.503-.629-2.013-.629-2.013 0-.125-.251 0-2.012.63-2.264 1.131-3.145 1.509-3.396 1.509-.378 0-.504-.126-.252-.378.126-.251.252-.377.629-.88.88-1.132 1.635-2.138 2.516-3.9 1.51-2.767 3.019-6.54 4.276-10.817.378-1.258.88-2.893 1.007-3.27 0-.126 0-.252.125-.252 0 0 3.648 6.164 5.41 9.057 3.396 6.037 4.905 9.182 4.528 9.434-.126.125-.252 0-.88-.63-.881-.88-1.385-1.131-2.265-1.509-.377-.126-1.006-.251-1.384-.251-.377 0-.377 0-.251.503.503 2.012 1.383 3.522 2.515 4.528 1.133 1.132 2.516 1.887 6.038 3.27 2.767 1.133 4.528 2.013 6.038 3.02 1.258.88 2.264 1.635 3.27 2.767 6.29 6.415 9.183 15.094 8.176 24.025-.88 7.799-5.031 14.843-11.195 19.622-3.522 2.642-7.42 4.529-11.698 5.41-2.264.502-4.905.754-7.17.754z"/>
+ <path d="M39.399 60.503c-1.51-.126-2.516-.377-3.648-1.006-1.132-.503-1.887-1.132-2.767-2.013-1.384-1.51-2.39-3.27-2.642-5.409-.125-.754-.125-2.138 0-2.767.126-1.006.378-1.887.755-2.641a9.816 9.816 0 0 1 7.547-5.66c.378 0 .63-.126 1.384-.126.755 0 1.132 0 1.384.125a9.816 9.816 0 0 1 7.547 5.66c.377.881.629 1.636.754 2.642.126.63.126 2.139 0 2.767-.125 1.007-.377 1.887-.88 2.768-.503 1.132-1.006 1.887-1.761 2.641-.88.88-1.635 1.51-2.767 2.013-1.384.629-2.642 1.006-4.151 1.006h-.755z"/>
+ </g>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_darkgray.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_darkgray.svg
new file mode 100644
index 00000000..d8837049
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_darkgray.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 96">
+ <g fill="#54595d" transform="translate(0 20)">
+ <path d="M22 48.3c0 6.1-4.9 11-11 11s-11-4.9-11-11 4.9-11 11-11 11 4.9 11 11zm37 0c0 6.1-4.9 11-11 11s-11-4.9-11-11 4.9-11 11-11 11 4.9 11 11z"/>
+ <circle cx="85" cy="48.3" r="11"/>
+ </g>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_gray.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_gray.svg
new file mode 100644
index 00000000..bccbc71a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_gray.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 96">
+ <g fill="#72777d" transform="translate(0 20)">
+ <path d="M22 48.3c0 6.1-4.9 11-11 11s-11-4.9-11-11 4.9-11 11-11 11 4.9 11 11zm37 0c0 6.1-4.9 11-11 11s-11-4.9-11-11 4.9-11 11-11 11 4.9 11 11z"/>
+ <circle cx="85" cy="48.3" r="11"/>
+ </g>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_lightgray.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_lightgray.svg
new file mode 100644
index 00000000..bccbc71a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/ellipsis_lightgray.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 96">
+ <g fill="#72777d" transform="translate(0 20)">
+ <path d="M22 48.3c0 6.1-4.9 11-11 11s-11-4.9-11-11 4.9-11 11-11 11 4.9 11 11zm37 0c0 6.1-4.9 11-11 11s-11-4.9-11-11 4.9-11 11-11 11 4.9 11 11z"/>
+ <circle cx="85" cy="48.3" r="11"/>
+ </g>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/error-media-icon.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/error-media-icon.svg
new file mode 100644
index 00000000..5e7232ca
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/error-media-icon.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 67.684 79.813">
+ <path fill="#c8ccd1" d="M67.255 0L3.26.816l.535 41.997L19.14 27.07 31.176 38.8l15.306-15.7 16.152 15.745 5.05-5.18z"/>
+ <path fill="#fff" d="M61.357 8.076L8.36 8.752l.37 28.997 10.41-10.68 3.75 3.654 3.015-4.172 8.866 8.56 11.712-12.014L61.738 37.97z"/>
+ <path fill="#c8ccd1" d="M61.638 50.217L47.46 32.673 30.406 46.457l-10.563-13.07-17.1 13.818L0 73.06l63.643 6.753 3.622-34.144z"/>
+ <path fill="#fff" d="M60.852 49.244l-13.39-16.57-13.05 10.545 3.15 3.858 7.21-4.71 8.77 12.238-42.095-4.466L23.13 37.458l-3.288-4.07-11.6 9.373-1.16 10.94 52.704 5.59z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/file.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/file.svg
new file mode 100644
index 00000000..119cceba
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/file.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="19" height="14" viewBox="0 0 19 14">
+ <path fill="#72777d" d="M13 0H0v14h19V6h-6V0zm4.5 12.3V12H2.4l4.5-5.5.7-.1 4.2 4.5 2.3-1.5 3.4 2.9z"/>
+ <path fill="#72777d" d="M18.8 4.5h-4.5V0"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/gear.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/gear.svg
new file mode 100644
index 00000000..09e2d9e1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/gear.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 96 96">
+ <path fill-opacity=".51" d="M39.063.038c-.014.004.013.136 0 .14-.014.005-.128-.005-.141 0-.014.005-.128-.005-.14 0-.014.006.012.135 0 .14-.014.007-.128-.005-.141 0-.013.007-.128-.006-.141 0-.013.008.013.134 0 .141-.013.008-.128-.007-.14 0-.013.008-.13-.008-.141 0-.012.009.011.133 0 .141-.012.009-.13-.009-.14 0-.012.009.01.131 0 .14-.012.01-.13-.009-.142 0-.01.01.01.131 0 .141-.01.01-.13-.01-.14 0l-.14.14c-.01.012.008.13 0 .142-.01.01-.133-.012-.141 0-.009.011.008.128 0 .14-.008.012-.133-.012-.141 0-.008.012.008.129 0 .14-.007.013.007.129 0 .141-.007.013-.134-.012-.14 0-.007.013.006.128 0 .141-.006.013-.136.127-.141.14-.006.014.005.128 0 .141-.005.014.004.127 0 .14-.004.015.004.128 0 .142-.004.013-.137-.014-.14 0-.004.013.002.126 0 .14-.004.014.002.127 0 .14-.003.015.001.127 0 .141l-1.407 8.438c-1.472.498-2.851 1.025-4.219 1.687l-7.172-4.921c-.013-.01-.127.008-.14 0-.014-.009-.127-.133-.141-.141-.014-.008-.126.007-.14 0-.015-.007-.127.007-.141 0-.015-.007.015-.134 0-.14-.015-.007-.126.005-.14 0-.016-.006-.126.004-.142 0-.015-.006-.125-.137-.14-.141-.015-.005-.125.003-.14 0-.017-.004-.126.002-.141 0-.016-.003-.125.002-.141 0-.016-.002-.125.001-.14 0h-.141c-.016 0-.125-.14-.14-.141-.017 0-.126.14-.142.14-.015.002-.124 0-.14 0-.016.002-.125-.001-.14 0-.017.003-.126-.002-.141 0-.016.004-.125-.003-.141 0-.015.005-.125-.004-.14 0-.016.005-.126.136-.141.141-.015.006-.126-.005-.14 0-.016.006-.127-.006-.142 0-.014.007.015.134 0 .14-.014.008-.126-.006-.14 0-.014.008-.127-.007-.14 0-.015.009.013.133 0 .142-.014.008-.128-.01-.141 0-.013.009-.128.13-.141.14-.013.01-.128.13-.14.14-.012.011-.13-.01-.141 0-.012.012.011.13 0 .141L8.547 20.006c-.011.012-.13-.011-.14 0-.012.012.01.129 0 .14-.011.013-.131.129-.141.142-.01.013-.132.127-.141.14-.009.014.009.127 0 .14-.008.014-.133-.013-.14 0-.009.015.007.127 0 .141-.008.015.007.127 0 .141-.008.014-.135-.014-.141 0-.007.015.006.126 0 .14-.006.015.005.126 0 .141-.005.016-.136.126-.14.14-.005.016.003.126 0 .142-.005.015.003.125 0 .14-.004.016.001.125 0 .14-.003.017 0 .125 0 .141-.002.016 0 .125 0 .141-.002.016-.141.125-.141.14 0 .017.14.125.14.141v.14c.002.017-.002.126 0 .142.002.015-.002.124 0 .14.003.016-.003.125 0 .14.004.016-.004.126 0 .141.005.016.136.126.14.141.006.015-.005.126 0 .14.007.015-.006.126 0 .141.007.015.135-.014.141 0 .007.015-.007.127 0 .14.008.015-.007.128 0 .142.008.013.133.126.141.14.009.014-.009.128 0 .14l4.922 6.891c-.724 1.484-1.275 3.006-1.828 4.641l-8.297 1.266c-.016.002-.124-.003-.14 0-.017.003-.125-.004-.141 0-.017.004-.125-.005-.141 0-.016.004.016.136 0 .14-.016.005-.125-.005-.14 0-.016.006-.126-.006-.141 0-.016.007-.126-.006-.14 0-.016.007.014.134 0 .14-.016.008-.127-.006-.142 0-.014.009-.126-.007-.14 0-.015.009.014.133 0 .142-.015.008-.127-.009-.14 0-.015.009-.128.13-.141.14-.013.01-.128-.01-.141 0-.013.01.013.13 0 .14-.013.011-.128-.01-.14 0-.013.012.012.13 0 .141-.013.012-.13-.011-.141 0-.012.013.011.129 0 .141-.012.012-.13-.013-.14 0-.012.013.01.128 0 .14-.011.014-.131-.012-.141 0-.01.014.01.128 0 .141-.01.014-.132.127-.141.14-.009.015.008.127 0 .142-.008.014-.133.125-.14.14-.008.015.006.125 0 .14-.008.016-.135-.015-.141 0-.007.016.005.126 0 .141-.006.016.005.125 0 .141-.005.016.004.125 0 .14-.004.017-.137.125-.141.141-.003.016.003.125 0 .14-.003.017.002.125 0 .142-.002.016.002.124 0 .14v17.015c.002.017-.002.125 0 .141.002.017-.003.125 0 .141.003.016-.003.124 0 .14.004.017.137.125.14.141.005.016-.004.125 0 .14.006.017-.005.126 0 .142.006.015-.006.125 0 .14.007.015.135-.015.141 0 .007.015-.007.126 0 .14.008.016.133.127.14.141.009.015-.008.127 0 .141.01.014.132.127.141.14.01.014-.01.128 0 .141.01.013.13-.013.141 0 .01.013-.01.128 0 .14.01.013.13-.011.14 0 .012.013-.01.13 0 .142.012.011.13-.012.141 0 .013.01-.012.129 0 .14.013.01.128-.01.141 0 .013.01-.013.13 0 .14.013.011.127-.01.14 0 .014.01.127.132.141.141.014.009.127-.008.14 0 .015.009-.014.133 0 .141.015.008.127-.008.141 0 .015.007.126-.007.141 0 .015.007-.015.134 0 .14.015.007.125-.006.14 0 .017.006.126-.005.141 0 .016.006.125-.004.141 0 .016.005-.016.137 0 .141.016.005.125-.004.14 0 .017.004.125-.003.141 0 .016.003.124-.002.14 0l8.298 1.407c.55 1.61 1.102 3.14 1.828 4.64l-4.922 6.89c-.009.014.009.128 0 .141-.008.014-.133.127-.14.141-.008.014.007.126 0 .14-.008.015.006.127 0 .141-.007.015-.135-.015-.141 0-.007.015.006.126 0 .14-.006.016.005.126 0 .141-.005.016-.136.126-.14.141-.005.015.003.125 0 .14-.004.016.002.126 0 .141-.003.016.001.125 0 .141-.003.016 0 .125 0 .14-.002.016 0 .125 0 .141-.001.016-.141.125-.141.14 0 .017.14.126.14.141v.141c.002.016-.002.125 0 .14.002.016-.003.126 0 .141.004.016-.004.125 0 .141.004.015-.004.125 0 .14.005.016.136.126.14.141.006.015-.005.126 0 .14.007.016-.006.127 0 .141.008.015.134-.014.141 0 .008.015-.007.127 0 .141.008.014-.008.127 0 .14.008.015.133-.013.141 0 .009.014-.009.128 0 .141.009.013.131.128.14.141.01.013.131.128.141.14.011.012-.01.13 0 .141.011.012.13-.011.14 0L20.22 87.928c.011.011-.012.13 0 .14.011.012.128-.01.14 0 .013.011.128.131.141.141.013.01.127.132.14.141.014.009.128-.009.141 0 .014.008-.014.133 0 .14.014.009.127-.007.14 0 .015.008.127-.007.142 0 .014.008-.015.135 0 .141.014.007.125-.006.14 0 .015.006.126-.005.14 0 .016.005.126.136.141.14.016.005.126-.003.141 0 .016.005.125-.003.14 0 .016.004.125-.001.141 0 .016.003.125 0 .14 0 .017.002.126 0 .142 0 .015.002.124.141.14.141.016 0 .125-.14.14-.14h.141c.016-.002.125.002.141 0 .016-.002.125.002.14 0 .016-.003.126.003.141 0 .016-.004.125.004.14 0 .016-.005.126-.136.142-.14.015-.006.125.005.14 0 .015-.007.126.006.14 0 .016-.007-.014-.135 0-.141.015-.007.127.007.141 0 .014-.008.127.007.141 0 .014-.008.127-.133.14-.141.014-.009.128.009.141 0l6.89-4.922c1.456.69 2.936 1.177 4.5 1.688l1.407 8.437c.003.016-.003.124 0 .14.003.017-.003.125 0 .141.004.017-.004.125 0 .141.004.016.136-.016.14 0 .005.016-.004.125 0 .14.006.016-.005.126 0 .141.007.016-.006.126 0 .14.007.016.135-.014.141 0 .007.016-.007.127 0 .141.008.015-.008.127 0 .141.008.015.133-.014.141 0 .009.015-.009.127 0 .14.009.015.131.128.14.141.01.013-.01.128 0 .141.011.013.13-.013.141 0 .01.013-.01.128 0 .14.012.013.13-.012.14 0 .012.013-.01.13 0 .141.013.012.13-.011.142 0 .012.011-.013.13 0 .14.012.012.127-.01.14 0 .013.011-.013.131 0 .141.013.01.127-.01.14 0 .015.01.127.132.141.141.015.009.127-.008.141 0 .014.008.126.133.14.14.016.007.126-.006.141 0 .016.007-.015.135 0 .141.016.007.125-.005.14 0 .017.006.126-.005.142 0 .015.005.124-.004.14 0 .016.004.125.137.14.141.017.003.125-.003.141 0 .017.003.125-.002.141 0 .017.002.124-.002.14 0h17.156c.018-.002.125.002.142 0 .016-.002.124.003.14 0 .016-.003.125.003.14 0 .017-.004.125-.137.141-.14.017-.005.125.004.141 0 .016-.006.125.005.14 0 .016-.006.126.006.141 0 .016-.007-.015-.135 0-.141.016-.007.126.006.14 0 .016-.008.127-.133.142-.14.014-.009.126.008.14 0 .014-.01.127-.132.14-.142.014-.01.128.01.141 0 .013-.01-.013-.13 0-.14.013-.01.128.01.141 0 .013-.01-.012-.13 0-.14.012-.012.129.01.14 0 .012-.012-.01-.13 0-.141.012-.013.13.012.141 0 .011-.013-.01-.128 0-.141.01-.013.13.013.14 0 .011-.013-.009-.127 0-.14.01-.014.132-.127.142-.141.008-.014-.01-.127 0-.14.008-.015.132.014.14 0 .008-.015-.008-.127 0-.142.007-.014-.007-.125 0-.14.007-.015.134.015.14 0 .007-.015-.006-.125 0-.14.007-.017-.005-.126 0-.141.006-.016-.004-.125 0-.141.005-.016.137.016.141 0 .005-.016-.004-.125 0-.14.004-.017-.003-.125 0-.141.003-.016-.002-.124 0-.14l1.407-8.438c1.542-.547 2.968-1.124 4.359-1.829l7.031 4.922c.013.01.128-.009.14 0 .014.008.128.133.141.141.014.008.127-.007.141 0 .015.007.126-.007.14 0 .015.007-.014.134 0 .14.016.007.126-.005.141 0 .015.006.126-.004.141 0 .015.006.125.137.14.141.016.004.126-.004.141 0 .016.003.125-.003.14 0 .017.003.126-.002.141 0 .016.002.125-.001.141 0h.14c.017 0 .125.14.141.14.017 0 .125-.14.141-.14.016 0 .125.002.14 0 .016-.001.125.002.141 0 .016-.002.125.003.14 0 .017-.003.126.004.141 0 .016-.004.126.005.141 0 .015-.004.126-.135.14-.14.016-.006.126.005.141 0 .015-.006.126.006.141 0 .014-.007-.014-.134 0-.141.014-.007.126.007.14 0 .015-.008.127.008.141 0 .014-.008-.014-.132 0-.14.014-.01.128.008.14 0 .014-.01.129-.132.141-.141.013-.01.129-.13.141-.14.012-.012.13.01.14 0 .012-.012-.01-.13 0-.142L88 76.117c.011-.012.13.011.14 0 .011-.012-.01-.13 0-.141.011-.012.131-.128.141-.14.01-.014.132-.128.14-.141.01-.014-.008-.127 0-.14.009-.015.134.013.141 0 .009-.015-.007-.127 0-.142.008-.014-.007-.126 0-.14.008-.015.134.014.141 0 .006-.015-.006-.126 0-.14.006-.016-.005-.126 0-.141.005-.016.136-.126.14-.141.005-.015-.003-.125 0-.14.004-.016-.003-.126 0-.141.003-.016-.002-.125 0-.14.003-.017 0-.126 0-.142.002-.015 0-.124 0-.14.001-.016.141-.125.141-.14 0-.017-.14-.125-.14-.141v-.141c-.002-.016.002-.125 0-.14-.002-.016.002-.125 0-.141-.003-.016.003-.125 0-.14-.004-.016.004-.126 0-.142-.005-.015-.136-.125-.14-.14-.006-.015.005-.126 0-.14-.007-.016.005-.127 0-.141-.007-.015-.135.014-.141 0-.007-.015.007-.127 0-.141-.008-.014.007-.127 0-.14-.009-.015-.133-.128-.141-.141-.01-.014.009-.128 0-.14L83.5 65.286c.71-1.43 1.274-2.901 1.828-4.5l8.438-1.406c.016-.002.124.003.14 0 .016-.003.125.004.14 0 .017-.004.125.005.141 0 .017-.004-.015-.136 0-.14.016-.005.125.005.141 0 .016-.006.125.005.14 0 .016-.007.126.006.141 0 .016-.007-.015-.134 0-.141.016-.007.126.007.141 0 .015-.008.126.008.14 0 .015-.008-.014-.132 0-.14.015-.01.127.008.141 0 .014-.01.127-.132.14-.141.014-.01.128.01.141 0 .014-.01-.012-.13 0-.14.013-.011.129.01.141 0 .012-.012-.012-.13 0-.142.012-.01.129.012.14 0 .012-.012-.01-.128 0-.14.012-.012.13.012.141 0 .011-.013-.01-.128 0-.14.01-.014.13.012.141 0 .01-.014-.01-.128 0-.141.009-.014.132-.127.14-.141.01-.014-.007-.126 0-.14.009-.015.134-.126.141-.141.007-.016-.007-.126 0-.14.007-.016.135.014.14 0 .007-.016-.005-.126 0-.142.006-.015-.005-.124 0-.14.006-.016-.004-.125 0-.14.005-.017.138-.125.141-.141.004-.017-.003-.125 0-.141.003-.016-.002-.124 0-.14.002-.017-.001-.125 0-.141.002-.017 0-.124 0-.14V39.693c0-.017.002-.124 0-.14-.001-.018.002-.125 0-.142-.002-.016.003-.124 0-.14-.003-.016.004-.125 0-.14-.003-.017-.136-.125-.14-.141-.005-.017.005-.125 0-.141-.006-.016.005-.125 0-.14-.006-.016.006-.126 0-.141-.006-.016-.134.015-.14 0-.007-.016.006-.126 0-.14-.008-.016-.133-.127-.141-.142-.008-.014.008-.126 0-.14-.01-.014-.132-.127-.141-.14-.01-.014.01-.128 0-.141-.01-.013-.13.013-.14 0-.011-.013.01-.128 0-.141-.011-.013-.13.012-.141 0-.011-.012.011-.129 0-.14-.012-.012-.129.01-.14 0-.013-.012.011-.13 0-.141-.013-.011-.129.01-.141 0-.013-.01.013-.13 0-.14-.014-.011-.128.009-.141 0-.014-.01-.127-.132-.14-.142-.015-.008-.127.009-.141 0-.015-.008.014-.132 0-.14-.015-.008-.126.008-.141 0-.015-.007-.125.007-.14 0-.016-.007.015-.134 0-.14-.016-.007-.126.006-.141 0-.016-.007-.125.005-.14 0-.017-.006-.126.004-.141 0-.016-.005.016-.137 0-.141-.017-.005-.125.004-.141 0-.016-.004-.124.003-.14 0-.017-.003-.125.002-.141 0l-8.438-1.407a37.056 37.056 0 0 0-1.828-4.359l4.922-7.031c.009-.013-.01-.128 0-.14.008-.014.132-.128.14-.142.008-.013-.007-.126 0-.14.008-.015-.006-.126 0-.14.007-.015.135.014.141 0 .006-.016-.006-.126 0-.141.006-.015-.005-.126 0-.141.005-.015.136-.125.14-.14.005-.016-.003-.126 0-.141.004-.016-.002-.125 0-.14.003-.017-.001-.126 0-.142.003-.015 0-.124 0-.14.002-.016 0-.125 0-.14.001-.017.141-.125.141-.141 0-.017-.14-.125-.14-.141v-.14c-.002-.016.002-.125 0-.141-.003-.016.002-.125 0-.14-.004-.017.003-.126 0-.142-.004-.015.004-.125 0-.14-.005-.015-.136-.126-.14-.14-.006-.016.005-.126 0-.141-.007-.015.005-.126 0-.141-.008-.014-.135.014-.141 0-.008-.014.007-.126 0-.14-.008-.015.008-.127 0-.141-.009-.014-.133.013-.141 0-.009-.014.009-.128 0-.14-.01-.014-.131-.129-.14-.142-.01-.012-.131-.128-.141-.14-.011-.012.01-.13 0-.14-.011-.012-.13.01-.141 0L76.469 8.333c-.011-.01.011-.13 0-.14-.012-.011-.129.01-.14 0-.013-.01-.129-.131-.141-.14-.014-.01-.128-.132-.141-.142-.014-.008-.127.009-.14 0-.015-.008.013-.132 0-.14-.015-.008-.127.007-.141 0-.015-.007-.127.007-.141 0-.014-.007.014-.134 0-.14-.015-.007-.126.005-.14 0-.015-.006-.126.005-.141 0-.016-.006-.126-.137-.14-.141-.016-.005-.126.004-.141 0-.016-.004-.126.003-.141 0-.016-.003-.125.002-.14 0-.016-.002-.125.001-.141 0-.016-.002-.125 0-.141 0-.016-.001-.125-.14-.14-.141-.017 0-.125.14-.141.14h-.14c-.017.002-.126-.001-.141 0-.016.003-.125-.002-.141 0-.016.003-.125-.003-.14 0-.016.004-.126-.004-.141 0-.016.005-.126.136-.141.141-.015.005-.126-.005-.14 0-.015.006-.126-.006-.141 0-.015.007.014.134 0 .14-.015.008-.127-.006-.14 0-.015.008-.128-.007-.141 0-.014.009-.127.133-.141.141-.014.01-.128-.009-.14 0L65.5 12.834c-1.394-.7-2.82-1.276-4.36-1.828L59.735 2.71v-.14c-.003-.017.004-.125 0-.14-.004-.017.005-.125 0-.142-.004-.016-.136.016-.14 0-.005-.015.005-.124 0-.14-.006-.016.006-.125 0-.14-.007-.016.006-.126 0-.141-.007-.016-.134.015-.14 0-.008-.016.006-.126 0-.141-.009-.015.007-.126 0-.14-.009-.015-.133.014-.142 0-.008-.015.01-.127 0-.141-.008-.014-.13-.127-.14-.14-.01-.014.01-.128 0-.142-.01-.013-.13.013-.14 0-.011-.012.01-.128 0-.14-.012-.012-.13.012-.141 0-.012-.012.011-.129 0-.14-.013-.012-.129.01-.141 0-.012-.012.013-.13 0-.141-.013-.011-.128.01-.14 0-.014-.01.012-.13 0-.141-.014-.01-.128.01-.141 0-.014-.01-.127-.132-.14-.14-.015-.01-.127.008-.142 0-.014-.009-.125-.134-.14-.141-.015-.007-.125.006-.14 0-.016-.007.015-.135 0-.14-.016-.007-.126.005-.141 0-.016-.006-.125.004-.141 0-.016-.006-.125.004-.14 0-.017-.005-.125-.138-.141-.142-.016-.003-.125.004-.14 0-.017-.002-.125.003-.142 0-.016-.001-.124.002-.14 0H39.485a.436.436 0 0 0-.141 0c-.014.004-.127-.003-.14 0-.015.004-.128-.004-.142 0zm9.28 33.89c7.791 0 14.204 6.323 14.204 14.203 0 7.903-6.27 14.063-14.203 14.063-7.912 0-14.203-6.271-14.203-14.063 0-7.88 6.412-14.203 14.203-14.203z"/>
+ <path fill="#fff" d="M92.345 55.587v-16.5L82.22 37.4c-.75-2.719-1.875-5.344-3.188-7.688l5.907-8.343-11.625-11.72-8.344 5.907c-2.438-1.312-4.97-2.436-7.688-3.186L55.595 2.337h-16.5l-1.688 10.125c-2.718.75-5.343 1.875-7.687 3.188l-8.344-5.906L9.657 21.369l5.907 8.343c-1.313 2.438-2.438 4.97-3.188 7.782L2.345 39.087v16.5l10.031 1.688c.75 2.719 1.875 5.344 3.188 7.781L9.657 73.4l11.625 11.625 8.344-5.906c2.438 1.312 4.969 2.437 7.781 3.187l1.688 10.031h16.5l1.687-10.125c2.72-.75 5.344-1.875 7.688-3.187l8.344 5.906 11.625-11.625-5.907-8.344c1.313-2.437 2.438-4.968 3.188-7.78l10.125-1.595zm-45 9c-9.563 0-17.25-7.78-17.25-17.25 0-9.562 7.781-17.25 17.25-17.25 9.469 0 17.25 7.688 17.25 17.25 0 9.563-7.688 17.25-17.25 17.25z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/grayscale.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/grayscale.svg
new file mode 100644
index 00000000..72bec238
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/grayscale.svg
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg">
+ <filter id="grayscale">
+ <feColorMatrix values="0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0"/>
+ </filter>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_mmv.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_mmv.svg
new file mode 100644
index 00000000..067eaf14
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_mmv.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="58.4" height="52.3" viewBox="0 0 58.4 52.3">
+ <path fill="#36c" d="M0 0v44.7h58.4V0H0zm51.9 35.4H6l13.7-17.7 2-.8 12.9 13.7 6.8-4 10.5 8.8z"/>
+ <path fill="#fff" d="M48 4.2l1.9 1.9-5.1 5.1-1.3-1.3-.3 5.3 5.2-.3-1.3-1.3 5.2-5.1 1.8 1.9.4-6.6"/>
+ <path fill="#eaecf0" d="M0 44.7h58.4v7.7H0z"/>
+ <path fill="#36c" d="M1.9 46.2h13.8v1.6H1.9zm0 3.1h54.7v1.6H1.9z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_page.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_page.svg
new file mode 100644
index 00000000..cdc570cc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/icon_page.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="58.4" height="52.3" viewBox="0 0 58.4 52.3">
+ <path fill="#eaecf0" d="M0 0h58.4v52.3H0z"/>
+ <path fill="#36c" d="M14.9 28.2h13.8v1.6H14.9zm0 3.1h38.8v1.6H14.9zm0 3h38.8v1.6H14.9zm0 5.2h13.8v1.6H14.9zm0 3h38.8v1.6H14.9zm0 3.1h38.8v1.6H14.9zm-.5-37.8v17.4h22.7V7.8H14.4zm20.2 13.8H16.7l5.3-6.9.8-.3 5 5.3 2.7-1.6 4.1 3.5z"/>
+ <path fill="#c8ccd1" d="M0 10.8h9.8v41.6H0z"/>
+ <circle cx="5.4" cy="4.8" r="3.7" fill="#c8ccd1"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/license.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/license.svg
new file mode 100644
index 00000000..97bfd989
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/license.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="5.5 -3.5 64 64">
+ <path fill="#72777d" d="M13 .5v56h38.5C57.45 56.5 62 51.95 62 46V.5H13zM51.5 53H20V4h14v28l7-7 7 7V4h10.5v42c0 3.85-3.15 7-7 7z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link-hover.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link-hover.svg
new file mode 100644
index 00000000..60ae8395
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link-hover.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="16.831" height="22.457" viewBox="0 0 16.831 22.457">
+ <path fill="#36c" d="M13.39.56a5.956 5.956 0 0 1 2.881 7.915l-1.521 3.262a6.024 6.024 0 0 1-.798 1.269c-.044.054-.089.104-.134.154l-.052.059a5.98 5.98 0 0 1-3.692 1.912l-.065.008a6.206 6.206 0 0 1-.821.035 5.94 5.94 0 0 1-4.291-2.002l.507-1.086a2.354 2.354 0 0 1 1.156-1.148l.025.045a3.14 3.14 0 0 0 1.37 1.233 3.136 3.136 0 0 0 1.876.248c.001.001.149-.012.384-.086.107-.034.23-.08.369-.146a3.136 3.136 0 0 0 1.561-1.541l.319-.683.192-.412.197-.422.956-2.051a3.153 3.153 0 0 0-5.715-2.665l-.839 1.798-.124.267a6.78 6.78 0 0 0-3.549 1.228c.016-.063.031-.127.049-.19.084-.29.192-.576.323-.858L5.476 3.44A5.954 5.954 0 0 1 13.39.56zM4.686 11.767l-.319.683-.192.412-.197.422-.956 2.051A3.153 3.153 0 0 0 8.737 18l.839-1.799.124-.267a6.79 6.79 0 0 0 3.549-1.228c-.016.063-.031.127-.049.19a5.95 5.95 0 0 1-.323.858l-1.521 3.262A5.956 5.956 0 0 1 .56 13.982l1.521-3.262c.217-.466.486-.89.798-1.269.044-.054.089-.104.133-.154l.051-.06a5.98 5.98 0 0 1 3.692-1.912c.022-.001.044-.005.065-.007a5.46 5.46 0 0 1 .387-.029 5.94 5.94 0 0 1 4.726 1.997l-.507 1.087a2.356 2.356 0 0 1-1.157 1.148 3.134 3.134 0 0 0-1.395-1.278 3.117 3.117 0 0 0-1.875-.248c-.001 0-.149.012-.384.087-.107.034-.23.079-.369.145a3.136 3.136 0 0 0-1.56 1.54z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link.svg
new file mode 100644
index 00000000..757b5983
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/link.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="16.831" height="22.457" viewBox="0 0 16.831 22.457">
+ <path fill="#72777d" d="M13.39.56a5.956 5.956 0 0 1 2.881 7.915l-1.521 3.262a6.024 6.024 0 0 1-.798 1.269c-.044.054-.089.104-.134.154l-.052.059a5.98 5.98 0 0 1-3.692 1.912l-.065.008a6.206 6.206 0 0 1-.821.035 5.94 5.94 0 0 1-4.291-2.002l.507-1.086a2.354 2.354 0 0 1 1.156-1.148l.025.045a3.14 3.14 0 0 0 1.37 1.233 3.136 3.136 0 0 0 1.876.248c.001.001.149-.012.384-.086.107-.034.23-.08.369-.146a3.136 3.136 0 0 0 1.561-1.541l.319-.683.192-.412.197-.422.956-2.051a3.153 3.153 0 0 0-5.715-2.665l-.839 1.798-.124.267a6.78 6.78 0 0 0-3.549 1.228c.016-.063.031-.127.049-.19.084-.29.192-.576.323-.858L5.476 3.44A5.954 5.954 0 0 1 13.39.56zM4.686 11.767l-.319.683-.192.412-.197.422-.956 2.051A3.153 3.153 0 0 0 8.737 18l.839-1.799.124-.267a6.79 6.79 0 0 0 3.549-1.228c-.016.063-.031.127-.049.19a5.95 5.95 0 0 1-.323.858l-1.521 3.262A5.956 5.956 0 0 1 .56 13.982l1.521-3.262c.217-.466.486-.89.798-1.269.044-.054.089-.104.133-.154l.051-.06a5.98 5.98 0 0 1 3.692-1.912c.022-.001.044-.005.065-.007a5.46 5.46 0 0 1 .387-.029 5.94 5.94 0 0 1 4.726 1.997l-.507 1.087a2.356 2.356 0 0 1-1.157 1.148 3.134 3.134 0 0 0-1.395-1.278 3.117 3.117 0 0 0-1.875-.248c-.001 0-.149.012-.384.087-.107.034-.23.079-.369.145a3.136 3.136 0 0 0-1.56 1.54z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/location.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/location.svg
new file mode 100644
index 00000000..92d1a83e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/location.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80">
+ <path fill="#72777d" d="M61.615 10.966A30.392 30.392 0 0 0 51.506 4.25a30.615 30.615 0 0 0-33.178 6.728c-5.783 5.792-8.975 13.166-8.975 20.791 0 7.613 3.19 14.995 8.975 20.781l3.182 3.153c6.386 6.31 11.893 11.758 16.618 19.331L39.966 78l1.85-2.966c4.725-7.573 10.232-13.021 16.607-19.324l3.191-3.17c12.044-12.044 12.044-29.529.001-41.574zM49.477 42.641c-5.25 5.258-13.76 5.258-19.011 0-5.249-5.24-5.249-13.75 0-19 5.251-5.24 13.761-5.24 19.011 0 5.238 5.25 5.238 13.758 0 19z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-close.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-close.svg
new file mode 100644
index 00000000..6e02593f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-close.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="23" height="23" viewBox="0 0 23 23">
+ <path fill-opacity=".51" d="M19.65 0a.436.436 0 0 0-.282.125l-8.031 8L3.493.282C3.336.125 3.103.109 2.962.25L.274 2.938c-.14.141-.125.375.032.531l7.843 7.844-8.021 8.021c-.157.157-.172.422-.031.563l2.687 2.656c.141.141.375.126.532-.031l8.02-8.021 8.21 8.208c.156.157.39.173.531.032l2.688-2.688c.14-.14.125-.374-.032-.531l-8.209-8.209 8.032-8.031c.156-.157.172-.39.03-.531L19.9.094a.311.311 0 0 0-.25-.093z"/>
+ <path fill="#fff" d="M19.65.657a.32.32 0 0 0-.22.093l-8.093 8.094L3.43.938a.316.316 0 0 0-.438 0L1.306 2.625a.316.316 0 0 0 0 .438l7.906 7.906-8.094 8.094a.316.316 0 0 0 0 .437l1.719 1.688a.278.278 0 0 0 .406 0l8.094-8.094 8.281 8.281c.118.118.32.118.438 0l1.687-1.718a.278.278 0 0 0 0-.407l-8.281-8.28 8.094-8.095a.316.316 0 0 0 0-.437L19.868.75a.32.32 0 0 0-.219-.093z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-ltr.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-ltr.svg
new file mode 100644
index 00000000..6d0936af
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-ltr.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="28.391" height="29.067">
+ <path fill-opacity=".51" d="M15.224 0c-.178 0-.313.083-.313.188v13.437c0 .2.086.375.188.375h12.625c.1 0 .187-.176.187-.375V9.844c0-.2-.086-.344-.187-.344h-5.22l5.845-5.844c.08-.08.047-.265-.094-.406L25.567.562c-.14-.14-.326-.173-.406-.093l-6.25 6.25V.187c0-.104-.135-.187-.312-.187h-3.375z"/>
+ <path fill="#fff" d="M15.724.5c-.167 0-.313.047-.313.125v12.219c0 .01.026.02.031.031a.257.257 0 0 0 .031.062c.012.01.017.025.032.032.005.004.025-.003.03 0 .01.005.022.03.032.03h11.719c.075 0 .125-.145.125-.312v-2.375c0-.166-.05-.312-.125-.312h-6.688l6.719-6.75c.06-.06.024-.195-.094-.313L25.536 1.25c-.118-.118-.284-.185-.344-.125l-6.781 6.812V.625c0-.079-.115-.125-.281-.125h-2.407z"/>
+ <path fill-opacity=".51" d="M.974 15c-.102 0-.188.144-.188.344v3.781c0 .2.086.375.188.375H6.38L.036 25.844c-.082.082-.016.265.125.406l2.656 2.656c.141.141.324.208.407.125l6.562-6.562v6.312c0 .11.135.219.313.219h3.343c.178 0 .344-.11.344-.219V15.188c0-.034-.038-.067-.062-.094a.229.229 0 0 0-.094-.063c-.013-.006-.017-.031-.031-.031H.974z"/>
+ <path fill="#fff" d="M1.411 15.5c-.075 0-.125.115-.125.281v2.406c0 .167.05.313.125.313h6.656l-7 7.031c-.06.06-.024.195.094.313L2.88 27.53c.117.118.252.185.312.125l7.094-7.125v7.313c0 .078.115.156.281.156h2.406c.167 0 .313-.078.313-.156V15.625c0-.026-.037-.042-.063-.063-.009-.02-.019-.017-.03-.03-.009-.005-.024.002-.032 0-.013-.01-.017-.032-.031-.032H1.41z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-rtl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-rtl.svg
new file mode 100644
index 00000000..16266e47
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-defullscreen-rtl.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="28.391" height="29.067">
+ <path fill-opacity=".51" d="M13.168 0c.177 0 .312.083.312.188v13.437c0 .2-.086.375-.187.375H.668c-.101 0-.188-.176-.188-.375V9.844c0-.2.087-.344.188-.344h5.218L.043 3.656c-.08-.08-.048-.265.093-.406L2.824.562c.14-.14.326-.173.406-.093l6.25 6.25V.188c0-.105.135-.188.313-.188h3.375z"/>
+ <path fill="#fff" d="M12.668.5c.166 0 .312.047.312.125v12.219c0 .01-.026.02-.031.031a.257.257 0 0 1-.031.062c-.012.01-.016.025-.031.032-.005.004-.026-.003-.032 0-.01.005-.02.03-.03.03H1.104c-.075 0-.125-.145-.125-.312v-2.375c0-.166.05-.312.125-.312h6.688L1.074 3.25c-.06-.06-.024-.195.094-.313L2.855 1.25c.118-.118.284-.185.344-.125L9.98 7.937V.625c0-.079.115-.125.282-.125h2.406z"/>
+ <path fill-opacity=".51" d="M27.418 15c.1 0 .187.144.187.344v3.781c0 .2-.086.375-.187.375H22.01l6.344 6.344c.083.082.016.265-.125.406l-2.656 2.656c-.141.141-.324.208-.406.125l-6.563-6.562v6.312c0 .11-.135.219-.312.219h-3.344c-.177 0-.344-.11-.344-.219V15.188c0-.034.039-.067.063-.094a.23.23 0 0 1 .093-.063c.014-.006.017-.03.032-.03h12.625z"/>
+ <path fill="#fff" d="M26.98 15.5c.075 0 .125.115.125.281v2.406c0 .167-.05.313-.125.313h-6.656l7 7.031c.06.06.024.195-.094.313l-1.719 1.687c-.117.118-.252.185-.312.125l-7.094-7.125v7.313c0 .078-.115.156-.281.156h-2.406c-.166 0-.313-.078-.313-.156V15.625c0-.026.037-.042.063-.063.009-.02.02-.017.03-.03.009-.005.024.002.032 0 .013-.01.017-.032.031-.032h11.72z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-download.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-download.svg
new file mode 100644
index 00000000..5603c753
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-download.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
+ <path fill-opacity=".51" d="M9.944.006a1.62 1.62 0 0 0-1.157.469 1.62 1.62 0 0 0-.468 1.156v7.875h-4s.006.025 0 .031c-.006.007-.031 0-.032 0 0 0 .005.029 0 .032-.004.003-.03 0-.03 0-.004.003-.028-.004-.032 0h-.031V9.6c-.004.003-.028-.004-.032 0 0 0 .008.028 0 .031-.007.004-.03 0-.03 0s-.005.025 0 .031c-.012-.005-.032 0-.032 0h-.031s-.004.025 0 .032h-.032s-.004.024 0 .031c0 0 .005.029 0 .031l-.03.031s-.028-.003-.032 0v.032s.027.003.031 0l-.031.031c-.006-.004.004-.028 0-.031-.007-.005-.031 0-.031 0a.097.097 0 0 0 0 .031v.031c-.004.004.004.028 0 .031.004.003-.006.028 0 .032-.011-.005-.032 0-.032 0v.125a2.53 2.53 0 0 0 0 .062v.188s.02.005.032 0c-.006.004.004.028 0 .031v.094s.024.004.031 0c.004-.003-.006-.028 0-.032.009-.005.022.006.031 0-.006.005.005.029 0 .032-.006.004-.031 0-.031 0v.031h.031c.004.003-.004.028 0 .031.004.008.032 0 .031 0l.032-.031c.006-.006.031 0 .031 0s.011.037 0 .063c-.002.004-.03-.004-.031 0-.005.006 0 .03 0 .03H4.1l6.031 7.438H3.069a.097.097 0 0 0-.032 0h-.062v.032c-.004.003-.028-.004-.031 0 0 0 .006.026 0 .03-.006.005-.031 0-.032 0H2.85v.032s.002.027 0 .031-.031 0-.031 0h-.032v.032s.006.023 0 .03c-.005.009-.03 0-.03 0s.003.03 0 .032c-.004.002-.032 0-.032 0h-.031v.031h-.032v.062s.005.025 0 .032c-.004.007-.03 0-.03 0v.063s.003.023 0 .03c-.005.009-.032 0-.032 0v2.97a.705.705 0 0 0 0 .062v.125h.031v.063s.024-.01.031 0c.008.01 0 .03 0 .03v.063s.024-.008.032 0c.007.008 0 .031 0 .032h.031c.003.003-.004.027 0 .03.004.004.029-.002.031 0 .001.002-.007.025 0 .032.008.007.04.009.031 0-.008-.008-.007.024 0 .031.008.008.03 0 .032 0 .002.003-.004.028 0 .032.003.003.028-.004.031 0a.097.097 0 0 0 0 .03c.008.008.031 0 .031 0 .008.008 0 .032 0 .032h.031c.004.006.032 0 .032 0h.031c.01.008 0 .031 0 .031h.062v.032h.125a1.698 1.698 0 0 0 .063 0h15.594a.704.704 0 0 0 .062 0h.032a.097.097 0 0 0 .03 0h.063v-.032h.062s-.009-.023 0-.031c0 0 .025.006.032 0 0 0 .028.006.031 0h.032s-.008-.024 0-.031c.008-.008.03 0 .03 0 .008-.008 0-.032 0-.031.004-.004.028.003.032 0 .004-.004-.003-.03 0-.032.001 0 .024.008.031 0 .008-.007.009-.04 0-.031-.008.009.024.007.032 0 .007-.007-.001-.03 0-.031.002-.003.027.003.03 0 .004-.004-.003-.028 0-.031l.032-.032c.008-.008.031 0 .031 0v-.031a.097.097 0 0 0 0-.031c.006-.007 0-.032 0-.031.008-.01.031 0 .032 0V21.6h.03v-.062a.097.097 0 0 0 0-.032v-.031a1.698 1.698 0 0 0 0-.063v-2.78a.704.704 0 0 0 0-.063v-.125h-.03c-.005-.004.003-.028 0-.031v-.032s-.024.01-.032 0c0 0 .006-.024 0-.031v-.062s-.023.008-.031 0l-.031-.032c-.004-.003.003-.027 0-.031-.004-.004-.029.003-.031 0-.001-.001.007-.024 0-.031-.008-.008-.04-.009-.032 0 .009.008.008-.024 0-.031-.007-.008-.03 0-.031 0-.003-.003.004-.028 0-.032-.004-.003-.028.004-.031 0V18.1c-.008-.008-.032 0-.031 0-.008-.008 0-.031 0-.031h-.032c-.003-.006-.031 0-.031 0-.007-.006-.031 0-.031 0-.01-.008 0-.031 0-.031h-.063v-.032h-.125a1.698 1.698 0 0 0-.062 0H11.1v-.031l6.625-7.406h.063s.004-.025 0-.031c-.005-.003.005-.028 0-.032l-.032.032s-.012-.043-.031-.063c.005.002.019-.006.031 0 .013.006.02-.005.032 0 .004.001-.004.03 0 .031.011.004.03 0 .03 0 .005-.003-.003-.028 0-.031 0 0 .027.003.032 0v-.031s-.025.004-.031 0l.031-.031v.03c.006.005.031 0 .031 0a.097.097 0 0 0 0-.03v-.094c.011.005.032 0 .032 0v-.188a2.81 2.81 0 0 0 0-.062v-.125s-.02-.005-.032 0v-.031c-.003-.004.004-.028 0-.032v-.062s-.024-.005-.031 0c-.004.003.006.027 0 .031-.023.016-.063.031-.063.031.006-.007-.007-.022 0-.031.008-.014.024-.017.032-.031.006-.005.031 0 .031 0v-.031h-.031c-.004-.004.004-.028 0-.032 0 0-.02-.005-.031 0v-.031s-.021-.006-.032 0c.005-.007 0-.031 0-.031v-.031s-.024-.005-.031 0V9.63s-.025-.004-.031 0c0 0-.025-.006-.031 0-.003-.002.003-.027 0-.031h-.032v-.031a.097.097 0 0 0-.031 0 .12.12 0 0 0-.031 0s-.027.003-.031 0v-.031c-.006-.007-.032 0-.032 0v-.032h-.093a.097.097 0 0 0-.032 0H13.57L13.757.63a.704.704 0 0 0 0-.062V.444h-.031c-.004-.004.004-.028 0-.031V.38s-.024.01-.031 0V.288s-.024.007-.031 0c0 0 .007-.024 0-.032a.097.097 0 0 0-.032 0c-.003-.003.004-.027 0-.031-.003-.004-.028.003-.031 0 0-.001.007-.024 0-.031-.007-.008-.04-.009-.031 0 .008.008.007-.024 0-.031-.008-.008-.03 0-.031 0-.003-.003.003-.028 0-.032-.004-.003-.028.004-.032 0a.097.097 0 0 0 0-.031s-.023.008-.031 0 0-.031 0-.031h-.031c-.003-.006-.031 0-.031 0s-.022.007-.032 0c-.01-.008 0-.031 0-.031h-.062V.006h-.125a1.693 1.693 0 0 0-.063 0H9.944zM4.069 10.537l-.032-.03c.005.007 0 .03 0 .03s.025.007.032 0zm.093-.875c.004.012-.004.019 0 .032-.008-.009-.024.006-.03 0l.03-.032zm13.594.094c.009-.004.023.035.032.031-.01.006-.023-.005-.032 0 .005-.002-.006-.027 0-.03zm-13.75.094c.009.006.023-.006.032 0 .006.007 0 .031 0 .031s-.017-.021-.032-.031z"/>
+ <path fill="#fff" d="M9.71.435c-.6 0-1 .4-1 1v8.5H4.305l6.094 7.5 6.688-7.5H12.71l.187-9.5H9.711zm-6.718 18v2.78h15.594v-2.78H2.992z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-ltr.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-ltr.svg
new file mode 100644
index 00000000..64850f61
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-ltr.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="21.125" height="21.781">
+ <path fill-opacity=".51" d="M8.313 0c-.102 0-.188.144-.188.344v3.781c0 .2.086.375.188.375h5.124L4 13.938v-5.97c0-.104-.135-.187-.313-.187H.313c-.178 0-.313.083-.313.188v13.437c0 .2.086.375.188.375h12.624c.102 0 .188-.175.188-.375v-3.781c0-.2-.086-.344-.188-.344H7L17.125 7.188v6.593c0 .11.166.219.344.219h3.343c.178 0 .313-.11.313-.219V.187c0-.012-.027-.019-.031-.03-.005-.016.01-.05 0-.063-.019-.037-.038-.045-.063-.063-.008-.005-.022.005-.031 0C20.987.025 20.983 0 20.969 0H8.312z"/>
+ <path fill="#fff" d="M8.781.5c-.075 0-.156.115-.156.281v2.406c0 .167.081.313.156.313h6.375L3.5 15.156v-6.75c0-.078-.146-.125-.313-.125H.781c-.166 0-.281.047-.281.125v12.219c0 .013.024.02.031.031.003.008-.003.024 0 .031.015.017.036.019.063.032.016.015.012.062.03.062h11.75c.076 0 .126-.146.126-.312v-2.407c0-.166-.05-.28-.125-.28H5.094L17.624 5.25v7.594c0 .078.147.156.313.156h2.407c.166 0 .28-.078.28-.156V.624c0-.014-.021-.017-.03-.03-.005-.008.008-.024 0-.032-.01-.02-.02-.017-.031-.03-.008-.005-.023.002-.032 0-.013-.01-.016-.032-.03-.032H8.78z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-rtl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-rtl.svg
new file mode 100644
index 00000000..13c751d0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/mw-fullscreen-rtl.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="21.125" height="21.781">
+ <path fill-opacity=".51" d="M12.813 0c.1 0 .187.144.187.344v3.781c0 .2-.086.375-.188.375H7.689l9.437 9.438v-5.97c0-.104.135-.187.313-.187h3.375c.177 0 .312.083.312.188v13.437c0 .2-.086.375-.188.375H8.313c-.1 0-.187-.175-.187-.375v-3.781c0-.2.086-.344.188-.344h5.812L4 7.188v6.593c0 .11-.166.219-.344.219H.312C.136 14 0 13.89 0 13.781V.187C0 .175.028.169.031.158.036.14.021.106.031.093.05.057.07.049.094.03c.008-.005.022.004.03 0C.139.025.143.001.157.001h12.656z"/>
+ <path fill="#fff" d="M12.344.5c.075 0 .156.115.156.281v2.406c0 .167-.081.313-.156.313H5.969l11.656 11.656v-6.75c0-.078.146-.125.313-.125h2.406c.166 0 .281.047.281.125v12.219c0 .013-.024.02-.031.031-.003.008.003.024 0 .031-.015.017-.036.019-.063.032-.016.015-.012.062-.03.062H8.75c-.076 0-.126-.146-.126-.312v-2.407c0-.166.05-.28.125-.28h7.281L3.501 5.25v7.594c0 .078-.147.156-.313.156H.78c-.166 0-.28-.078-.28-.156V.624C.5.61.521.608.53.595.536.586.523.57.531.562c.01-.02.02-.017.031-.03.008-.005.023.002.032 0C.607.521.61.5.624.5h11.72z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-ltr.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-ltr.svg
new file mode 100644
index 00000000..c8ab0d1c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-ltr.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="26" height="40" viewBox="0 0 26 40">
+ <path fill-opacity=".51" d="M6 .007a.403.403 0 0 0-.281.125L.656 5.226a.395.395 0 0 0 0 .563l14.188 14.218L.656 34.227a.395.395 0 0 0 0 .562l5.063 5.093a.434.434 0 0 0 .593 0l14.47-14.5 5.093-5.093a.403.403 0 0 0 .125-.282.433.433 0 0 0-.031-.156.392.392 0 0 0-.094-.125l-5.094-5.094L6.313.132A.478.478 0 0 0 6 .007z"/>
+ <path fill="#fff" d="M6 .695c-.077 0-.129.004-.188.062L1.97 4.601a.278.278 0 0 0 0 .406L16.28 19.29 1.344 34.226a.395.395 0 0 0 0 .563l3.687 3.656a.395.395 0 0 0 .563 0L20.719 23.32l3.75-3.75c.022-.022.046-.037.062-.063.017-.017.02-.042.031-.062.004-.009-.003-.022 0-.031.039-.08.036-.139 0-.219-.008-.02.013-.045 0-.062-.005-.014-.024-.019-.03-.032l-.063-.093-3.688-3.657L6.22.758C6.159.698 6.077.695 6 .695z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-rtl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-rtl.svg
new file mode 100644
index 00000000..e27085ec
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/next-rtl.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="26" height="40" viewBox="0 0 26 40">
+ <path fill-opacity=".51" d="M20 .007c.102 0 .203.047.281.125l5.063 5.094a.395.395 0 0 1 0 .563L11.156 20.007l14.188 14.22a.395.395 0 0 1 0 .562l-5.063 5.093a.434.434 0 0 1-.593 0l-14.47-14.5L.126 20.29A.403.403 0 0 1 0 20.007c0-.05.012-.108.031-.156a.392.392 0 0 1 .094-.125l5.094-5.094L19.687.132A.478.478 0 0 1 20 .007z"/>
+ <path fill="#fff" d="M20 .695c.077 0 .129.004.188.062l3.843 3.844a.278.278 0 0 1 0 .406L9.72 19.29l14.937 14.937a.395.395 0 0 1 0 .563l-3.687 3.656a.395.395 0 0 1-.563 0L5.281 23.32l-3.75-3.75c-.022-.022-.046-.037-.062-.063-.017-.017-.02-.042-.031-.062-.004-.009.003-.022 0-.031-.039-.08-.036-.139 0-.219.008-.02-.013-.045 0-.062.005-.014.024-.019.03-.032l.063-.093L5.22 15.35 19.78.758c.06-.06.142-.063.219-.063z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/open.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/open.svg
new file mode 100644
index 00000000..559f8faf
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/open.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="1024" height="768">
+ <path fill="#72777d" d="M304 179.2v355.2h464V179.2H304zm412.8 281.6H352L460.8 320l16-6.4 102.4 108.8 54.4-32 83.2 70.4z"/>
+ <path fill="#72777d" d="M256 230.4v358.4h499.2v-25.6H281.6V230.4"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/page.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/page.svg
new file mode 100644
index 00000000..97b10d33
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/page.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" viewBox="212 84 600 600.8">
+ <path fill="#fff" d="M422.4 233.6h180v60h-180v-60zm299.2 120v60H422.4v-60h299.2zM422.4 534.4v-60h300v60h-300zM332 233.6h-84l-5.6-8v-67.2c0-24 21.6-44 45.6-44s44 20 44 44v75.2zM812 148c0-35.2-60-64-60-64H276c-35.2 0-64 28.8-64 64v100l16 16h104v420.8h480V148z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting-hover.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting-hover.svg
new file mode 100644
index 00000000..6e9c277d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting-hover.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="18.244" height="22.457" viewBox="0 0 18.244 22.457">
+ <g fill="#36c" fill-rule="evenodd">
+ <path d="M2.773 1.936C1.21 2.237 0 3.612 0 5.256v13.799c0 1.86 1.54 3.402 3.4 3.402h11.444c1.86 0 3.4-1.542 3.4-3.402v-13.8c0-1.643-1.21-3.018-2.773-3.32.129.332.207.687.207 1.06v.175c0 .591-.184 1.145-.49 1.613a.555.555 0 0 1 .253.473v13.799c0 .355-.241.597-.597.597H3.4c-.355 0-.597-.242-.597-.597v-13.8c0-.214.105-.369.254-.472a2.938 2.938 0 0 1-.49-1.613v-.176c0-.372.078-.728.206-1.058z"/>
+ <path d="M8.096 0c-.831 0-1.5.669-1.5 1.5v.004h-1.04c-.824 0-1.49.665-1.49 1.49v.176c0 .825.666 1.488 1.49 1.488h7.133c.825 0 1.489-.663 1.489-1.488v-.176c0-.825-.664-1.49-1.489-1.49H11.65V1.5c0-.831-.669-1.5-1.5-1.5z"/>
+ </g>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting.svg
new file mode 100644
index 00000000..70ef8de0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pasting.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="18.244" height="22.457" viewBox="0 0 18.244 22.457">
+ <g fill="#72777d" fill-rule="evenodd">
+ <path d="M2.773 1.936C1.21 2.237 0 3.612 0 5.256v13.799c0 1.86 1.54 3.402 3.4 3.402h11.444c1.86 0 3.4-1.542 3.4-3.402v-13.8c0-1.643-1.21-3.018-2.773-3.32.129.332.207.687.207 1.06v.175c0 .591-.184 1.145-.49 1.613a.555.555 0 0 1 .253.473v13.799c0 .355-.241.597-.597.597H3.4c-.355 0-.597-.242-.597-.597v-13.8c0-.214.105-.369.254-.472a2.938 2.938 0 0 1-.49-1.613v-.176c0-.372.078-.728.206-1.058z"/>
+ <path d="M8.096 0c-.831 0-1.5.669-1.5 1.5v.004h-1.04c-.824 0-1.49.665-1.49 1.49v.176c0 .825.666 1.488 1.49 1.488h7.133c.825 0 1.489-.663 1.489-1.488v-.176c0-.825-.664-1.49-1.489-1.49H11.65V1.5c0-.831-.669-1.5-1.5-1.5z"/>
+ </g>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pd.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pd.svg
new file mode 100644
index 00000000..c98d1b6c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/pd.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="5.5 -3.5 64 64">
+ <path fill="#72777d" d="M54.414 39.014c.915-1.828 1.372-4.114 1.372-5.943h-7.772l6.4 5.943zM53.5 17.071C48.471 7.93 35.671 5.186 26.986 11.586l5.485 5.485c5.943-4.571 14.172 0 14.629 6.858h8.229c0-2.743-.915-5.943-1.829-6.858-.914-1.828.914 1.829 0 0z"/>
+ <path fill="#72777d" d="M37.5-3.5c-17.829 0-32 14.171-32 32s14.171 32 32 32 32-14.171 32-32-14.171-32-32-32zm-27.429 32c0-5.486 1.829-10.514 4.572-14.629l6.4 6.4c-2.743 7.772-1.829 17.372 4.114 23.772 5.486 5.486 15.086 6.857 22.4 3.2l4.572 5.028c-4.115 2.743-9.143 4.115-14.172 4.115-15.543-.457-27.886-12.8-27.886-27.886zm17.829-.914l13.714 14.171c-4.114 1.372-8.685 0-11.428-3.657-1.829-3.2-2.286-7.314-2.286-10.514zM57.157 47.7l-38.4-38.857C23.33 3.814 30.186 1.07 37.5 1.07c15.086 0 27.429 12.343 27.429 27.429 0 7.314-3.2 14.171-7.772 19.2z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-ltr.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-ltr.svg
new file mode 100644
index 00000000..e27085ec
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-ltr.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="26" height="40" viewBox="0 0 26 40">
+ <path fill-opacity=".51" d="M20 .007c.102 0 .203.047.281.125l5.063 5.094a.395.395 0 0 1 0 .563L11.156 20.007l14.188 14.22a.395.395 0 0 1 0 .562l-5.063 5.093a.434.434 0 0 1-.593 0l-14.47-14.5L.126 20.29A.403.403 0 0 1 0 20.007c0-.05.012-.108.031-.156a.392.392 0 0 1 .094-.125l5.094-5.094L19.687.132A.478.478 0 0 1 20 .007z"/>
+ <path fill="#fff" d="M20 .695c.077 0 .129.004.188.062l3.843 3.844a.278.278 0 0 1 0 .406L9.72 19.29l14.937 14.937a.395.395 0 0 1 0 .563l-3.687 3.656a.395.395 0 0 1-.563 0L5.281 23.32l-3.75-3.75c-.022-.022-.046-.037-.062-.063-.017-.017-.02-.042-.031-.062-.004-.009.003-.022 0-.031-.039-.08-.036-.139 0-.219.008-.02-.013-.045 0-.062.005-.014.024-.019.03-.032l.063-.093L5.22 15.35 19.78.758c.06-.06.142-.063.219-.063z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-rtl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-rtl.svg
new file mode 100644
index 00000000..c8ab0d1c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/prev-rtl.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="26" height="40" viewBox="0 0 26 40">
+ <path fill-opacity=".51" d="M6 .007a.403.403 0 0 0-.281.125L.656 5.226a.395.395 0 0 0 0 .563l14.188 14.218L.656 34.227a.395.395 0 0 0 0 .562l5.063 5.093a.434.434 0 0 0 .593 0l14.47-14.5 5.093-5.093a.403.403 0 0 0 .125-.282.433.433 0 0 0-.031-.156.392.392 0 0 0-.094-.125l-5.094-5.094L6.313.132A.478.478 0 0 0 6 .007z"/>
+ <path fill="#fff" d="M6 .695c-.077 0-.129.004-.188.062L1.97 4.601a.278.278 0 0 0 0 .406L16.28 19.29 1.344 34.226a.395.395 0 0 0 0 .563l3.687 3.656a.395.395 0 0 0 .563 0L20.719 23.32l3.75-3.75c.022-.022.046-.037.062-.063.017-.017.02-.042.031-.062.004-.009-.003-.022 0-.031.039-.08.036-.139 0-.219-.008-.02.013-.045 0-.062-.005-.014-.024-.019-.03-.032l-.063-.093-3.688-3.657L6.22.758C6.159.698 6.077.695 6 .695z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-2257.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-2257.svg
new file mode 100644
index 00000000..920f2f54
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-2257.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M64 63.43H45.256L31.704 42.744 17.9 63.43H-8l30.29-31.662L.464.57h18.702l13.087 19.588L45.72.57h17.942L41.71 31.135 64 63.43z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-aus-reserve.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-aus-reserve.svg
new file mode 100644
index 00000000..bb5c53f8
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-aus-reserve.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M49.024 2.346c-2.179 2.268-2.006 5.62-2.19 8.515-.247 3.166-3.671 4.733-5.458 1.819-2.273-1.17-7.088-3.087-3.768-6.01 1.239-1.461 1.625-2.656-.662-2.304-2.317.615-5.01-2.55-6.605-1.01.67 1.932-3.56.545-3.975 3.091-.499 2.203-1.535 4.134-3.75 2.016-2.504-2.237-4.987 1.97-5.734 2.799.853 1.324-2.909 1.143-.965 2.49-.833 2.001-1.932-3.072-2.565-.021.343 3.524-2.84 6.01-6.048 6.818-2.81.252-4.573 3.223-6.714 3.87-.87-1.04-.65 4.011-.156 5.458C2.787 31.029.2 34.153 2.64 35.504c1.184 2.587 3.321 5.234 3.168 8.13-2.186 3.172 3.68 4.56 5.343 2.11 1.913-2.355 5.297-.565 7.32-2.559 2.039-2.874 6.43-2.899 9.66-3.857 3.368-.274 5.443 1.8 7.18 4.096-.43 2.596 1.588 1.655 2.096-.137.903-1.066 2.574-1.662 1.27.226-.998.99-.486 3.618.272 1.107 2.06-.86-.1 2.63 2.359 2.515-.024 2.905 2.293 4.83 5.199 5.168 2.456-.574 4.634 1.692 6.822-.36 4.33.004 3.583-5.22 6.362-7.349 3.678-3.691 4.851-9.228 4.09-14.26-1.857-1.748-2.183-5.43-4.382-6.134-.06-2.62-2.088-4.984-4.671-6.257-.734-2.389-1.338-5.474-1.686-8.096-4.132-.394-1.933-4.892-4.017-7.5zm-.4 54.03c-.893 2.043.675 7.189 3.696 4.534 1.1-1.99 1.28-5.248-1.923-3.8-.63-.162-1.114-.655-1.773-.734z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-communist.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-communist.svg
new file mode 100644
index 00000000..65950c16
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-communist.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" fill-rule="evenodd" d="M31.934 0C55.19 15.901 56.025 29.211 53.04 40.015c-.646 2.34-1.731 4.446-3.252 6.19-1.29 1.479-2.938 2.724-4.996 3.683-6.357 2.963-16.17 1.966-29.08-5.537l-2.441 3.147c-.516-.385-1.798-.86-2.783.345-.953 1.166.395 2.498-.1 3.362-.44.767-.583.747-3.388 2.48-5.579 3.445-6.784 8.087-5.137 9.709 1.607 1.582 6.333-.348 9.027-6.834 1.14-2.744.882-2.379 1.752-3.31.734-.787 2.084.31 2.951-.67.92-1.039.372-2.533-.004-3.043l.793-.91c13.014 11.687 26.154 13.391 35.115 8.478l6.147 6.623c.64.664 2.239.07 3.584-1.326 1.344-1.397 1.91-3.057 1.271-3.721l-5.793-5.687c3.32-3.655 5.47-8.657 5.975-14.64C64.472 17.128 48.11 4.708 31.934 0zM22.95 11.512L9.497 25.488l5.82 6.043 6.326-6.57 3.164-3.29 7.996-8.306-9.853-1.853zM38.99 19.5c-.872 0-1.578.276-2.12.83-.543.554-.813 1.286-.813 2.193 0 1.002.276 2.659.83 4.969l.92 3.853c.46 1.91.73 3.537.812 4.881h.78c.153-1.886.394-3.513.724-4.88l.938-3.854c.59-2.452.883-4.126.883-5.022 0-.86-.282-1.567-.848-2.12-.554-.566-1.257-.85-2.105-.85zm.038 19.253c-.802 0-1.48.284-2.034.85a2.804 2.804 0 0 0-.832 2.033c0 .79.278 1.468.832 2.033.566.554 1.244.83 2.034.83.79 0 1.461-.276 2.015-.83a2.773 2.773 0 0 0 .848-2.033c0-.801-.282-1.479-.848-2.033a2.717 2.717 0 0 0-2.015-.85z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-costume.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-costume.svg
new file mode 100644
index 00000000..b8f3447a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-costume.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" fill-rule="evenodd" d="M50.477 0c-6.606 4.229-11.73 10.863-19.481 13.187-6.862 2.179-14.184 1.266-21.231.839-3.598-1.417-6.256 1.87-4.78 5.25 1.647 9.517 6.173 18.306 11.46 26.296 4.395 6.31 9.82 12.151 16.6 15.906 5.76 2.912 13.311 3.862 18.784-.206 4.091-2.592 5.26-7.596 6.422-11.969 2.205-9.96.865-20.24-.353-30.234-.829-5.258-2.991-10.171-4.861-15.118-.728-1.345-1.2-3.102-2.56-3.951zm-6.295 13.741c3.165.799 11.212 2.413 6.02 5.54l-13.199 4.313c1.264-5.245.32-11.22 7.18-9.853zm-22.347 8.716c3.165.799 11.212 2.413 6.02 5.54l-13.2 4.312c1.264-5.245.321-11.22 7.18-9.852zM51.762 33.39c5.181 3.66 1.884 9.062.853 12.706-1.71 4.281-11.064 9.595-15.575 7.469-4.524-1.543-7.244-2.464-11.86-6.9-.629-6.497 3.78-3.115 7.055-2.573 5.357 1.752 12.296.678 14.994-4.814 1.566-2.515 1.583-4.709 4.533-5.888z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-currency.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-currency.svg
new file mode 100644
index 00000000..82aa8e44
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-currency.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M30.69.318c-6.128-.134-11.905 3.47-14.575 8.834l-3.205-.646-1.656 2.336 3.918.789c-.157.413-.244.84-.33 1.267-.086.428-.173.855-.188 1.297l-2.777-.56-1.656 2.336 4.345.875c.461 6.913 5.547 13.127 12.565 14.54 3.883.783 7.825-.017 11.07-1.958l.748-3.705c-2.982 2.66-7.135 3.939-11.303 3.1-5.699-1.149-9.817-5.91-10.408-11.44l17.346 3.496 1.658-2.336-19.023-3.832c.015-.442.101-.868.187-1.295.072-.356.173-.856.33-1.27l20.162 4.063 1.657-2.336-20.768-4.184c2.636-4.806 8.255-7.677 14.025-6.515 4.489.904 7.5 3.624 9.227 7.197l1.65-2.3C41.48 4.325 37.82 1.512 33.33.608a15.04 15.04 0 0 0-2.64-.29zM48.142 27.07c-.916.016-1.871.15-2.866.405-2.578.658-4.6 1.9-6.068 3.726-1.818 2.29-2.34 4.959-1.563 8.006.184.718.438 1.437.762 2.158.325.721.938 1.838 1.84 3.356l-3.383.863.83 3.254 4.307-1.1c.485.86.84 1.736 1.068 2.63.532 2.08.492 3.968-.12 5.661-.614 1.694-1.523 3.107-2.731 4.242l2.486 3.415c.82-.881 1.78-1.656 2.88-2.327 1.101-.67 2.179-1.14 3.233-1.41a12.695 12.695 0 0 1 2.112-.351c.462-.025 1.501.002 3.12.08 1.62.077 2.637.102 3.052.074a10.53 10.53 0 0 0 1.914-.3 9.814 9.814 0 0 0 2.138-.829c.695-.365 1.644-1.004 2.846-1.92l-2.201-3.3c-1.52 1.261-2.82 2.031-3.904 2.308-.894.228-2.677.363-5.35.406-1.617.023-3.032.192-4.248.502-.952.243-1.968.671-3.043 1.29 1.014-1.836 1.643-3.54 1.889-5.116.245-1.576.206-3.003-.12-4.277a4.998 4.998 0 0 0-.912-1.827l6.24-1.593-.83-3.252-6.921 1.765c-1.505-2.409-2.464-4.426-2.88-6.052-.377-1.48-.162-2.88.647-4.202.81-1.322 2.026-2.19 3.653-2.605 1.523-.389 2.959-.218 4.308.514 1.35.732 2.36 1.948 3.03 3.65l3.78-1.598c-1.068-2.535-2.65-4.312-4.743-5.33-1.309-.636-2.726-.942-4.252-.916zm-34.989 1.004l-.74 3.627c-1.527-.311-8.78.156-10.004 6.154-1.088 5.336 3.572 7.804 6.91 8.98l-1.222 6.032c-2.369-1.2-2.45-3.15-2.485-4.756L.105 46.988c-.882 6.07 4.032 9.978 6.946 11.014l-.752 3.69 5.234 1.066.74-3.631c4.189.633 9.8-1.81 10.762-6.527 1.102-5.403-3.474-7.934-7.555-9.196l1.127-5.527c1.616.446 2.575 2.271 2.39 3.89l5.454 1.112c1.093-5.36-3.404-9.213-6.857-10.121l.74-3.63-5.18-1.054zm-1.767 8.793l-.934 4.58c-3.68-.808-2.96-4.711.934-4.58zm3.058 11.908c4.546 1.044 4.162 5.533-1.062 5.198l1.062-5.198z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-default.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-default.svg
new file mode 100644
index 00000000..1573b23d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-default.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" fill-rule="evenodd" d="M32.166 3.814A3.556 3.556 0 0 0 28.92 5.59L.477 54.855a3.556 3.556 0 0 0 3.08 5.334h56.886a3.556 3.556 0 0 0 3.08-5.334L35.08 5.59a3.556 3.556 0 0 0-2.914-1.776zm-.176 18.377c.938 0 1.712.313 2.324.938.625.612.938 1.393.938 2.344 0 .99-.326 2.838-.977 5.547l-1.035 4.257c-.364 1.51-.631 3.308-.8 5.391h-.86c-.091-1.484-.39-3.281-.898-5.39l-1.016-4.258c-.612-2.553-.918-4.382-.918-5.489 0-1.002.3-1.81.898-2.422.6-.612 1.38-.918 2.344-.918zm.04 21.27a3 3 0 0 1 2.226.937c.625.612.937 1.361.937 2.247 0 .872-.312 1.62-.937 2.246a3.032 3.032 0 0 1-2.227.918 3.097 3.097 0 0 1-2.246-.918 3.097 3.097 0 0 1-.918-2.246c0-.873.306-1.622.918-2.247.612-.625 1.36-.937 2.246-.937z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-design.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-design.svg
new file mode 100644
index 00000000..f3166617
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-design.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M15.375 0v15.375H0v1h15.375V31.5H0v1h15.375v15.125H0v1h15.375L0 64h64V0L52.87 11.133l-4.243 4.242h-.002V0h-1v15.375H32.5V0h-1v15.375H16.375V0h-1zm1 16.375H31.5V31.5H16.375V16.375zm16.125 0h15.125v.002L32.502 31.5H32.5V16.375zm18.457 15.111v.014h-.014l.014-.014zM16.375 32.5H31.5v.002L16.375 47.625V32.5zm33.568 0h1.014v15.125h-2.332V33.818l1.318-1.318zm-2.318 2.318v12.807H34.818l12.807-12.807zM33.818 48.625h13.807v2.332H32.5v-1.014l1.318-1.318zm14.807 0h2.332v2.332h-2.332v-2.332zM31.5 50.943v.014h-.014l.014-.014z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-fan-art.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-fan-art.svg
new file mode 100644
index 00000000..fbb5a0d0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-fan-art.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" fill-rule="evenodd" d="M21.145 2.008c-.77.02-1.43.58-1.586 1.373L8.879 41.908c-.352 1.777.872 3.473 2.656 3.785 1.784.313 3.511-.865 3.785-2.656l7.508-39.084c.14-.916-.443-1.76-1.35-1.92a1.665 1.665 0 0 0-.333-.025zm18.43 7.65c-1.161.024-2.37.165-3.634.446-5.145 1.14-10.539 3.35-14.744 7.72l-4.873 25.37c-.17 1.1-.782 2.002-1.6 2.634.45.816.658 1.855.55 3.23 3.81 9.697 13.185 12.934 18.292 12.934 6.76 0 22.29-3.106 21.377-11.328-.913-8.222-8.952-10.05-8.039-14.252.914-4.202 9.502 3.29 12.608 4.022 3.106.73 8.037-11.144.547-18.635-6.555-6.555-12.363-12.307-20.485-12.14zm.347 3.285c1.29-.021 2.636.63 3.6 1.739 1.612 1.854 1.694 4.422.183 5.736-1.512 1.314-4.046.875-5.658-.98s-1.695-4.425-.184-5.739c.552-.48 1.271-.742 2.059-.756zm-10.969 5.094c1.369.05 2.77.621 3.91 1.592 2.42 2.062 3.02 5.331 1.34 7.303-1.68 1.97-5.005 1.897-7.424-.164-2.418-2.062-3.017-5.33-1.338-7.301.822-.965 2.09-1.481 3.512-1.43zm-6.47 12.053a4.953 4.953 0 0 1 2.288.525c2.093 1.034 3.107 3.254 2.264 4.96-.843 1.705-3.223 2.25-5.316 1.216-2.093-1.035-3.106-3.257-2.262-4.963.52-1.051 1.66-1.707 3.025-1.738zm1.146 13.113c.087.003.173.01.26.018 2.03.188 3.552 1.683 3.398 3.338-.154 1.654-1.925 2.84-3.955 2.652-2.03-.189-3.55-1.682-3.396-3.336.145-1.572 1.759-2.74 3.693-2.672zM8.906 44.955c-1.095.544-2.222 1.507-3.177 2.906-1.998 2.928 1.04 5.007-.672 8.418C3.345 59.691 0 61.83 0 61.83s11.1-2.634 13.307-8.866c1.343-3.795 1.187-5.702.504-6.815a4.078 4.078 0 0 1-2.41.315 4.073 4.073 0 0 1-2.495-1.508z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ihl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ihl.svg
new file mode 100644
index 00000000..026c80a0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ihl.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M34.923.061c-.539-.071-1.103.157-1.744.8-1.297 1.301-1.765 3.165-1.483 5.123L5.672 32.068c-1.864-.2-3.625.276-4.865 1.52-2.565 2.573 1.509 3.917 4.875 7.273l5.224 5.207c3.366 3.356 4.711 7.417 7.276 4.845 1.244-1.248 1.717-3.019 1.506-4.889l10.794-10.82c13.061 14.525 16.6 17.131 25.408 26.958.055.062.116.125.176.184 1.85 1.82 5.628 2.136 7.038.723 1.455-1.46 1.133-5.375-.926-7.211-9.848-8.783-12.547-12.23-27.106-25.255l10.86-10.887c1.773.132 3.436-.341 4.622-1.53 2.564-2.573-1.51-3.917-4.876-7.273l-5.223-5.207C37.93 3.19 36.542.275 34.923.061z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-insignia.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-insignia.svg
new file mode 100644
index 00000000..6f8cecec
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-insignia.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M30.297 0a.736.736 0 0 0-.125.016c-.315-.028-1.217.426-.729.648.623-.087 1.127.204 1.266.82.427.425.432 1.249-.283 1.362-.615.126-1.18-.27-1.774-.368-.363-.59.887-.638.678-1.166-.283-.54-1.28-.793-1.441-.027-.236.572-.218 1.27-.703 1.717-.408.514-.335 1.22-.838 1.602-.055.71.859.67 1.187 1.128.347.4.814 1.002 1.412.702.697-.322.39-1.245.903-1.68.748-.556.288.791.511.955.372-.027.965-.115.774.467.26.452.103.558-.819 1.16-.498-.582-1.488-.1-1.336.144.508.164 2.103-.303 2.102.473-.209.715-1.088.808-1.69.57-.62-.11-1.236-.27-1.87-.265-.654-.045-1.28.33-1.66.844-.157.589-.738 1.308-.266 1.878.705.313 1.012-.675 1.572-.898.612-.337 1.361-.244 2.037-.285.674-.01 1.344-.015 2.008.103.262.016.524.026.787.034.263-.008.525-.018.787-.034.664-.118 1.334-.112 2.008-.103.676.041 1.425-.052 2.037.285.56.223.867 1.21 1.572.898.472-.57-.11-1.29-.265-1.878-.38-.515-1.007-.89-1.66-.844-.635-.004-1.25.156-1.872.265-.601.238-1.48.145-1.689-.57 0-.776 1.594-.31 2.102-.473.152-.243-.838-.726-1.336-.144-.923-.602-1.08-.708-.819-1.16-.19-.582.402-.493.774-.467.223-.164-.237-1.511.511-.955.513.435.206 1.358.903 1.68.598.3 1.065-.303 1.412-.702.328-.458 1.242-.418 1.187-1.128-.503-.382-.43-1.088-.838-1.602-.485-.448-.467-1.145-.703-1.717-.16-.766-1.158-.513-1.441.027-.21.528 1.041.576.678 1.166-.594.098-1.16.494-1.774.368-.715-.113-.71-.937-.283-1.362.139-.616.643-.907 1.266-.82.488-.222-.414-.676-.729-.648A.717.717 0 0 0 33.703 0c-.61-.017-.922.763-1.328 1.135-.084.098-.17.197-.232.31-.04.13-.088.255-.143.377a3.023 3.023 0 0 1-.143-.377c-.063-.113-.148-.212-.232-.31C31.219.763 30.907-.018 30.297 0zm2.213 11.518c-1.72.03-3.463.782-4.815 2.502-2.402 3.057-.436 2.768.729 4.296 1.165 1.53 1.238 4.732-.072 5.97 0 0 3.785-3.713 5.095-3.786 1.31-.073 3.057 1.53 3.057 1.53s-.8-2.113-.436-3.278c.364-1.165 2.767-4.44.22-6.115-1.116-.733-2.44-1.144-3.778-1.12zm-9.405.101c-.187-.013-.391.125-.63.512-.975-.062-1.694-.392-2.707-.025-1.617-.271-2.538 1.2-3.315 2.351-.258.99.71 1.623 1.582 1.536a.959.959 0 0 1 .625-.215c.013-.01.026-.014.04-.023 1.092-.543-.19-2.968 1.603-2.276.53.747.16 3.313-1.221 2.385a1.295 1.295 0 0 0-.422-.084c-.188.122-.403.19-.625.213-.585.452-.889 1.483-1.586 1.766-1.152.977.179 2.211.182 3.345.026 1.421 1.537 2.645 2.922 2.106 1.545-.068 2.055-1.638.61-2.366-.686-.95-1.826-1.375-2.606-2.216 1.697-.434 3.125.857 4.662 1.275 1.916.203 4.129-1.555 3.636-3.61.12-1.225-1.446-1.99-.992-3.314-.124-.082-.277.023-.379.084-.535-.384-.9-1.409-1.379-1.443zm17.79 0c-.479.035-.844 1.06-1.38 1.444-.101-.061-.252-.167-.376-.084.454 1.324-1.115 2.086-.994 3.312-.493 2.054 1.72 3.812 3.636 3.61 1.537-.418 2.965-1.71 4.662-1.276-.78.842-1.92 1.268-2.605 2.219-1.446.728-.936 2.297.61 2.365 1.384.54 2.895-.685 2.921-2.105.003-1.135 1.334-2.369.182-3.346-.697-.283-1.001-1.314-1.586-1.766a1.398 1.398 0 0 1-.625-.213c-.129 0-.267.028-.422.084-1.38.928-1.751-1.64-1.22-2.386 1.791-.692.51 1.733 1.603 2.275.013.01.026.017.039.025.246 0 .448.078.625.215.872.088 1.84-.546 1.582-1.535-.777-1.15-1.698-2.623-3.315-2.352-1.013-.367-1.732-.038-2.707.025-.239-.387-.443-.525-.63-.512zM9.742 19.611c-.056 0-.113 0-.17.012-.767.488-1.877.17-2.779.155-.527.56.018 1.03.103 1.543.477.908.072 2.124-.103 3.09-.507.93.744 1.186.412 2.162-.424.407-.6.975-.516 1.67.068.616-.162 1.112-.103 1.726.19.781.263 1.82.83 2.572.356.595.146 1.41.201 2.125.014 1.15.231 2.21-.27 3.328-.368 1.138-.931 2.282-1.171 3.3-.35.8-.865 1.92-1.237 2.882-.304.707-.355 2.178-1.441 1.545-.355-.637.207-1.514.104-2.266.22-.814.082-1.782.412-2.572.156-.946.088-1.983.101-2.988.078-.821-.115-1.186-.72-1.543-.286-.85-.582-1.65-.514-2.594-.181-.707-.078-1.518-.104-2.287-.07-.445.27-1.596-.513-1.09-.728.472-1.533 1.126-1.34 2.08-.21 1.42.961 2.484 1.236 3.79v4.96c.052.606-.113 1.297.104 1.834v2.37c-.233 1.1.555 1.649 1.142 2.411.031 1.832 1.417.066 1.43-.767-.086-.56.734-2.392.62-2.059.032 1.066-.441 2.047-.517 3.088v2.102c-.047.977.558 1.68.774 2.443.653.911.799 2.206 1.598 3.125-.118 1.579 2.086 1.245 2.261.236-.12-.735.232-1.279.207-1.976.085-.849-1.17-.88-1.644-1.42-.222-.794-.499-1.733-.21-2.553.386-.874.431-1.821 1.13-2.37.76-.379.778-1.342.724-2.161-.137-.837.18-1.02.823-.719-.058 1.058-.137 2.123-.102 3.192.191.713-1.859 1.376-1.256 1.855.93.165 1.8 1.307 2.902 1.129 1.207.071 2.59-.383 3.5-.926-.035-1.149.169-2.347-.412-3.398-.518-1.427-.734 1-1.853.31-.687-.386-1.105-.672-.926-1.547-.044-.992.102-2.03-.103-2.984-.153-1.02-1.793-.995-2.676-1.133-.998.443-.484-1.077-.53-.98.7-1.214 1.344-2.584 2.176-3.653.46.344 1.18 1.196 1.903 1.532.689.835 2.046 1.048 2.763.187.693-.538 1.118-1.904 1.432-2.111 1.016-.33.603-1.846-.332-1.975.837-1.114-.746-1.372-1.338-1.646-.448.07-2.044-.785-1.75-.824.6-.402-.108-.84.102-1.647.205-1.115 1.591-1.002 2.472-1.545 1.475-.868-1.064-2.426.617-3.09.102-.811-.57-.842-.72-1.338.086-.593-.113-1.066-.309-1.543-.88-1.325-1.257.172-1.558 1.012-.363 1.159-.854 2.522-1.737 3.31-.198.917-1.203 2.057-1.75.928.226-1.05.127-1.7-.926-1.914-.281-.412-.286-1.306-.103-1.69.55-.672 1.475-.561 1.955-1.235.705-.305.746-1.822 0-1.852-.656-.463-1.455-1.582-2.3-1.607zm44.516 0c-.846.026-1.645 1.143-2.301 1.606-.746.03-.705 1.549 0 1.853.48.675 1.406.564 1.955 1.237.183.382.178 1.277-.103 1.69-1.053.213-1.152.863-.926 1.913-.547 1.129-1.552-.012-1.75-.928-.883-.788-1.374-2.152-1.737-3.31-.3-.84-.678-2.34-1.558-1.014-.196.477-.395.952-.309 1.545-.15.495-.822.526-.72 1.338 1.68.664-.858 2.222.617 3.09.88.542 2.267.427 2.472 1.543.21.808-.497 1.246.102 1.648.294.04-1.302.895-1.75.824-.592.275-2.175.532-1.338 1.647-.935.128-1.348 1.644-.332 1.975.314.207.739 1.573 1.432 2.11.717.862 2.074.647 2.763-.189.722-.335 1.443-1.185 1.903-1.529.831 1.067 1.476 2.434 2.174 3.647-.013 0 .44 1.415-.528.986-.883.138-2.523.112-2.676 1.133-.205.954-.059 1.992-.103 2.984.179.874-.24 1.158-.926 1.545-1.119.69-1.335-1.735-1.853-.309-.58 1.052-.377 2.25-.412 3.399.91.543 2.293.997 3.5.926 1.103.178 1.973-.965 2.902-1.13.603-.479-1.447-1.141-1.256-1.855.035-1.068-.044-2.134-.102-3.191.643-.302.96-.118.823.719-.054.819-.037 1.782.724 2.16.699.55.744 1.496 1.13 2.37.289.82.012 1.76-.21 2.554-.473.54-1.729.57-1.644 1.42-.025.697.327 1.24.207 1.976.175 1.009 2.379 1.343 2.261-.236.8-.919.945-2.214 1.598-3.125.216-.763.82-1.466.774-2.444v-2.101c-.076-1.04-.55-2.022-.516-3.088-.115-.334.705 1.498.62 2.059.012.834 1.398 2.598 1.429.767.587-.763 1.375-1.312 1.142-2.412v-2.371c.217-.537.052-1.227.104-1.832v-4.963c.275-1.305 1.445-2.366 1.236-3.787.193-.955-.612-1.608-1.34-2.08-.784-.507-.443.644-.513 1.09-.026.768.077 1.58-.104 2.287.068.944-.228 1.743-.514 2.594-.605.357-.798.721-.72 1.543.013 1.005-.055 2.042.101 2.988.33.79.191 1.757.412 2.572-.103.752.46 1.629.104 2.266-1.086.632-1.137-.838-1.441-1.545-.372-.962-.887-2.082-1.237-2.883-.24-1.018-.803-2.161-1.172-3.299-.5-1.12-.283-2.18-.27-3.328.056-.714-.154-1.53.202-2.125.567-.753.64-1.791.83-2.572.059-.615-.17-1.112-.103-1.729.083-.694-.092-1.26-.516-1.668-.332-.975.919-1.232.412-2.162-.175-.965-.58-2.181-.103-3.09.085-.512.63-.983.103-1.543-.902.015-2.012.332-2.78-.156-.056-.01-.113-.012-.17-.01zm-34.79 5.39v17.991c0 6.958 5.61 12.6 12.532 12.6 6.921 0 12.532-5.642 12.531-12.6v-17.99zm.452 29.317a1.4 1.4 0 0 0-.574.133c-1.156.11-1.582 1.782-2.797 1.488-.987-.59-1.445 1.211-.502 1.397.424.535.836 1.127 1.422 1.486-6.91-.338-10.592-1.611-10.592-1.611.423 2.006.636 3.861 0 5.098 0 0 4.892 1.691 13.992 1.691 9.1 0 19.219-1.455 26.717-1.455 7.498 0 9.537 1.455 9.537 1.455-.396-1.401-.685-2.883 0-5.096 0 0-1.983-1.41-9.209-1.453.08-.12.157-.243.229-.369.708-.055.078-1.042-.147-1.379-1.236 1.111-1.955-.82-3.004-1.133-.973-.56-3.512.084-2.474 1.434.51.592.149 1.294-.606.787-1.157-.316-2.51.044-3.197.887-.17-.548-.707-1.28-.947-.307-.332.76-.998.585-.727-.205-.373-1.506-3.195-.419-1.676.746-.47.556-2.604.1-1.392-.863.525-.674-.072-1.72-.659-.656-.553.468-1.04 2.959-1.78 1.464-.308-.645-1.035-2.176-1.723-1.75.148.825 1.202 2.34-.442 1.987-.738.215-1.06-.308-.357-.682.224-1.51-2.644-1.163-2.092.418-.573.485-.69-1.624-1.51-.596-.327 1.097-.903-.834-1.808-.535-.686-.292-2.731.87-2.3-.465 1.2-.914-.255-1.946-1.382-1.916zm9.271 2.805l-.003.021zm5.616 0l.002.021z"/>
+ <path fill="none" d="M616.063-229.45s-19.799-14.141-92.63-14.141c-72.833 0-171.12 14.142-259.509 14.142-88.388 0-135.893-16.438-135.893-16.438 6.175-12.009 4.107-30.012 0-49.498 0 0 47.505 16.438 135.893 16.438s186.676-14.142 259.508-14.142 92.631 14.142 92.631 14.142c-6.654 21.49-3.849 35.885 0 49.498z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ita-mibac.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ita-mibac.svg
new file mode 100644
index 00000000..492220ca
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-ita-mibac.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M30.333 0c-2.038.777-5.011.9-6.296 1.932C21.898.845 22.13 3.129 21.941 3.44c-2.834-1.096.312 3.695-2.301 1.53-1.463 1.483-2.776-2.772-2.958.5-.336 1.576-1.55 2.906-2.411 1.237-1.258-.47-1.294-3.868-2.414-1.078-.23 3.548-6.552.574-5.698 4.106 2.332 1.41-.494 3.275-1.086 3.73 2.747 1.525-.643 5.362 3.002 5.757 2.684-.276.144 1.433 1.237 2.36 2.98-.145 4.12-5.818 7.549-3.489 2.196 1.381 5.189 2.538 5.098 5.507.896 1.315.17 3.456 1.843 3.937 1.111.681 1.67 2.425 1.941 2.707 3.367.791 4.577 4.81 7.552 6.402 2.06.69 5.108.291 5.566 3.31 1.845-.877.92 2.146 2.694.887 1.865.923 1.107 4.238 4.088 3.788 1.297 1.363 3.28 5.757 2.276 7.507-1.345.623-.872 2.94-2.03 3.698 1.408 2.932 4.08-1.39 4.459-3.12.56-2.335 4.26-1.664 1.986-4.607-1.224-1.336-3.36-1.734-1.794-3.904.453-2.184 2.617-2.798 3.993-1.455 2.022-.471 3.391 5.54 4.394 1.738-.419-3.44-4.418-4.727-6.968-6.335-1.781-.735-6.323-2.15-3.646-4.197-.839-2.147-4.687.465-6.298-1.895-2.546-1.748-4.23-4.364-4.698-7.426-1.01-3.574-6.77-3.743-6.716-7.992-1.055-1.63 2.211-1.957.34-3.497-.954-1.05.72-3.765.655-2.356 2.433-.589 3.195-2.72 5.615-1.48 1.4 1.723-.621-1.31-.45-1.264-1.293-1.154.955-1.941-.826-2.237-.032-1.179 2.253-2.251-.193-2.234-1.877.062-6.639-.972-5.353-3.36L30.333 0zM16.641 37.157c-.972 1.768-3.476 2.719-4.84 2.582.016 1.888 2.138 3.61 1.249 5.37.696 1.788-1.47 6.907 2.068 5.866.59-2.577 3.66-.06 3.51-2.975-.596-2.899 1.494-6.423-.452-8.816.512-1.086-1.026-1.395-1.535-2.027zm2.325 2.013c-1.444-.19-.416.642 0 0zm26.568 15.48c-2.47 1.015-5.208 1.696-7.86 1.785-1.738-.474-2.625-1.488-4.233-.351-2.767-1.675-2.33 3.99.588 3.14 2.893 1.72 6.007 3.487 8.96 4.776 2.757-1.698-1.014-5.466 1.987-7.524.253-.43 1.383-1.423.558-1.826z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-nazi.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-nazi.svg
new file mode 100644
index 00000000..a784da88
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-nazi.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" fill-rule="evenodd" d="M32.008 0L12.805 19.195l6.398 6.399L38.406 6.398 32.008 0zm12.797 12.797l-6.399 6.398 19.196 19.203L64 32 44.805 12.797zM31.992 19.5c-.893 0-1.616.278-2.172.832-.555.554-.836 1.288-.836 2.195 0 1.002.284 2.655.852 4.965l.945 3.86c.471 1.91.744 3.529.828 4.873h.797c.157-1.886.404-3.506.742-4.873l.961-3.86c.604-2.451.907-4.122.907-5.017 0-.86-.288-1.568-.868-2.121-.567-.566-1.286-.854-2.156-.854zM6.398 25.602L0 32l19.203 19.203 6.39-6.398L6.399 25.602zm38.407 12.796L25.602 57.602 31.992 64l19.211-19.203-6.398-6.399zm-12.774.36c-.82 0-1.518.28-2.086.846-.567.565-.851 1.247-.851 2.037s.284 1.461.851 2.027c.58.554 1.277.832 2.086.832.81 0 1.495-.278 2.063-.832.58-.566.867-1.238.867-2.027a2.71 2.71 0 0 0-.867-2.037 2.81 2.81 0 0 0-2.063-.846z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-personality.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-personality.svg
new file mode 100644
index 00000000..625ee415
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/restrict-personality.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64">
+ <path fill="#222" d="M0 0v64h64V0H0zm6 6h52v52h-6.06a25.206 60.413 0 0 0-10.19-18.945c-2.754 1.99-6.12 3.181-9.758 3.181-3.624 0-6.978-1.18-9.726-3.158A25.206 60.413 0 0 0 12.06 58H6V6zm25.992 6C24.541 12 18.5 18.04 18.5 25.492c0 7.452 6.04 13.492 13.492 13.492s13.492-6.04 13.492-13.492c0-7.451-6.04-13.492-13.492-13.492z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/time.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/time.svg
new file mode 100644
index 00000000..3c635e77
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/time.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80">
+ <path fill="#72777d" d="M64.742 15.246C58.14 8.638 49.35 5 39.996 5c-9.348 0-18.137 3.638-24.754 10.246C8.633 21.856 5 30.65 5 40s3.633 18.144 10.242 24.742C21.859 71.352 30.648 75 39.996 75c9.354 0 18.144-3.649 24.746-10.258C71.353 58.144 75 49.35 75 40s-3.647-18.144-10.258-24.754zm-13.283 41.29L36.504 41.604V16.01h5.628v23.234l13.3 13.309-3.973 3.982z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-ltr.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-ltr.svg
new file mode 100644
index 00000000..20f540ec
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-ltr.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
+ <path fill-opacity=".51" d="M16.051 1.55a.52.52 0 0 0-.092.062.52.52 0 0 0-.245.153c.004-.004-.034.004-.03 0 .004-.004-.004.034 0 .03l-.03.031a.52.52 0 0 0 0 .03.52.52 0 0 0-.031 0c.002-.003-.003.035 0 .031l-.03.03c.001-.003-.033.035-.031.031.001-.003-.002.035 0 .031.001-.004-.033.035-.031.03v.061a.52.52 0 0 0-.03.123v.061a.582.582 0 0 0 0 .062v2.233c-4.157.277-6.5 2.397-7.589 4.59-1.141 2.299-1.103 4.542-1.101 4.59v.03a2.328 2.328 0 0 0 0 .092.52.52 0 0 0 .06.184.52.52 0 0 0 0 .03c0-.004.033.035.031.03-.001-.003.002.035 0 .031a.52.52 0 0 0 .03.031c-.002-.004.035.034.032.03-.003-.003.002.035 0 .031a.52.52 0 0 0 .03.03c-.002-.001.024-.007.03 0 .008.009.002.033 0 .031-.003-.004.004.035 0 .031-.003-.004.035.004.031 0l.03.03a.52.52 0 0 0 .032.031c-.004-.002.034.002.03 0l.03.03c-.003-.001.035.033.031.031-.003-.001.035.002.03 0-.003-.001.035.033.031.031-.003-.002.035.001.031 0h.03a.52.52 0 0 0 .123.03h.061a.452.452 0 0 0 .061 0h.061a.52.52 0 0 0 .123-.03h.03c-.003.001.035-.002.031 0-.004.002.035-.032.03-.03-.003.001.035-.002.031 0-.003.001.035-.033.031-.031-.004.002.034-.033.03-.03-.003.001.035-.003.031 0a.52.52 0 0 0 .03-.031l.031-.031c-.003.004.035-.004.031 0 .008-.007.002-.032 0-.03l.03-.031.031-.03a.52.52 0 0 0 .03-.031S10.79 10.6 15.5 10.975v2.845a.52.52 0 0 0 .03.123.15.15 0 0 0 0 .03.16.16 0 0 0 0 .031c0-.004.033.034.032.03-.002-.003.001.035 0 .031-.002-.004.032.034.03.03-.002-.003.002.035 0 .031.005.008.032.002.03 0-.001-.003.003.034 0 .031l.031.03c-.002-.003.003.034 0 .031-.002-.003.033.003.03 0l.031.03c-.002-.002.003.034 0 .031-.002-.002.034.003.031 0l.03.031c-.002-.003.004.033 0 .03-.002-.002.035.003.031 0-.003-.002.034.033.03.031-.002-.002.035.002.031 0-.003-.002.004.033 0 .03.01.007.034.002.031 0l.061.031c-.005-.002.036.003.03 0-.005-.002.037.033.031.031-.005-.002.037.002.031 0l.061.03h.061a.52.52 0 0 0 .031 0h.122a.52.52 0 0 0 .184-.06c-.004 0 .035-.002.03 0-.003.001.035-.033.031-.031a.52.52 0 0 0 .061-.03l.031-.031c-.004.003.034-.004.03 0-.003.003.004-.035 0-.031l.031-.03a.52.52 0 0 0 .03 0l5.814-5.722a.52.52 0 0 0 .062-.062c-.003.004.002-.034 0-.03-.003.003.032-.034.03-.03-.002.003.002-.035 0-.031l.03-.031c0 .004.033-.034.031-.03-.001.003.002-.035 0-.031a.071.071 0 0 1 0-.03c.004-.009.032-.003.031 0-.002.003.001-.035 0-.031V8.22a.52.52 0 0 0 .03-.122v-.122a.52.52 0 0 0-.03-.123v-.03c.001.003-.002-.035 0-.031 0 .002-.027.007-.03 0 0 .004-.002-.035 0-.03 0 .003-.002-.035 0-.032.001.004-.033-.034-.031-.03 0 .002.004-.024 0-.03 0 .001-.027.007-.03 0 .001.003-.003-.035 0-.031.001.003-.034-.034-.031-.03.002.003-.003-.035 0-.032a.52.52 0 0 0-.062-.06l-5.813-5.753a.52.52 0 0 0-.061-.061c.003.002-.034-.003-.031 0l-.03-.03a.06.06 0 0 1-.031 0c.003.001-.034-.034-.03-.032a.439.439 0 0 1-.031-.03c.003.002-.035-.002-.031 0a.071.071 0 0 1-.03 0c-.008-.003-.003-.031 0-.03.003 0-.035-.002-.031 0 .004 0-.035-.002-.03 0a.52.52 0 0 0-.123-.031h-.183a.52.52 0 0 0-.062 0zM.63 3.08a.52.52 0 0 0-.153.092.52.52 0 0 0-.184.123c.003-.003-.003.033 0 .03a.52.52 0 0 0-.03.031c.002-.003-.033.003-.031 0a.52.52 0 0 0 0 .03l-.03.031c.002-.003-.003.034 0 .03.001-.003-.033.004-.031 0-.006.011-.002.034 0 .031a4.58 4.58 0 0 1-.03.062c.002-.006-.003.036 0 .03.001-.005-.033.036-.031.03.001-.005-.002.037 0 .031.001-.005-.032.067-.031.062v.06a.52.52 0 0 0 0 .062v16.798a.52.52 0 0 0 .03.123.15.15 0 0 0 0 .03.15.15 0 0 0 0 .03c0-.003.033.035.031.031-.002-.003.002.035 0 .03l.03.032c-.001-.004.003.034 0 .03.005.007.033.002.031 0-.002-.003.003.034 0 .03-.002-.003.033.035.031.031-.002-.003.002.034 0 .03-.002-.002.033.004.03 0l.031.032c-.003-.003.003.033 0 .03-.003-.003.034.003.03 0l.031.03c-.003-.002.004.034 0 .031-.003-.002.034.003.031 0l.03.03c-.003-.001.035.003.031 0-.003-.001.004.033 0 .032.01.005.033 0 .03 0l.062.03c-.005-.002.036.002.03 0-.005-.002.037.033.031.03-.005-.001.036.002.03 0-.005 0 .068.033.062.031h.061a.52.52 0 0 0 .061 0h18.175a.52.52 0 0 0 .123-.03c-.004.001.034-.002.03 0-.003.001.035-.002.031 0-.004.001.034-.033.03-.03-.003 0 .035-.003.031 0-.003.001.034-.034.03-.031-.003.002.035-.033.031-.031-.003.002.034-.003.031 0l.03-.03c-.003.002.034-.003.031 0-.003.002.003-.034 0-.031l.03-.03c-.002.002.034-.004.031 0-.002.002.003-.034 0-.031l.031-.031c-.003.003.033-.003.03 0-.002.003.003-.034 0-.03-.002.003.033-.035.031-.031-.002.003.002-.034 0-.03-.003.004.034-.037.03-.031l.031-.062c-.002.006.003-.036 0-.03-.002.005.033-.036.031-.03-.002.005.002-.037 0-.031l.03-.062v-.06a.52.52 0 0 0 0-.062v-7.283a.52.52 0 0 0-.03-.123v-.03c.001.004-.002-.035 0-.03l-.03-.032c.001.004-.002-.034 0-.03.001.004-.033-.034-.031-.03 0 .001.004-.024 0-.031.002.003-.033-.004-.03 0 .001.003-.003-.034 0-.03l-.031-.032c.002.004-.003-.033 0-.03.002.003-.034-.003-.031 0l-.03-.03c.002.002-.003-.034 0-.031.002.003-.034-.003-.031 0l-.03-.03c.002.002-.004-.034 0-.031.002.002-.035-.003-.031 0l-.031-.031c.003.002-.034-.002-.03 0 .003.002-.004-.033 0-.03-.011-.007-.034-.002-.031 0a4.144 4.144 0 0 1-.061-.031c.005.002-.036-.002-.031 0 .006.002-.036-.033-.03-.03.005.001-.037-.002-.031 0 .006 0-.067-.033-.061-.031h-.062a.52.52 0 0 0-.03 0h-.123a.52.52 0 0 0-.153.06.52.52 0 0 0-.091.031c.004-.001-.035.002-.03 0l-.032.03c.004-.001-.034.034-.03.032.003-.003-.034.002-.03 0a.52.52 0 0 0-.031.06.52.52 0 0 0-.03 0l-2.663 2.602a.52.52 0 0 0-.061.06c.002-.003-.002.035 0 .031l-.03.03c.001-.003-.033.035-.031.032.002-.004-.002.034 0 .03.001-.004-.032.035-.03.03 0-.003-.002.035 0 .031 0-.002.002.023 0 .03-.004.009-.032.003-.031 0 .001-.003-.002.035 0 .031 0-.003-.002.035 0 .031a.52.52 0 0 0-.031.122v1.286H4.24V7.15h4.069a.52.52 0 0 0 .092-.03.52.52 0 0 0 .153-.031c-.004.002.034-.033.03-.03-.003.001.034-.034.03-.031-.003.002.035-.003.031 0l3.948-2.601a.52.52 0 0 0 .06-.03l.031-.031.03-.03c-.004.004.036-.067.032-.062-.005.005.034-.036.03-.03-.004.005.034-.037.03-.031 0 .002-.004-.022 0-.03-.002.003.033-.035.031-.031-.003.006.033-.037.03-.031 0 .003-.004-.018 0-.03a.071.071 0 0 1 0-.031c.004-.008.032-.002.031 0-.001.004.002-.035 0-.03 0 .003.002-.035 0-.031a.52.52 0 0 0 .031-.123v-.122a.52.52 0 0 0-.03-.123c0 .004-.002-.034 0-.03 0 .004-.002-.035 0-.03 0 .001-.028.007-.031 0V3.54c.001.003-.002-.035 0-.031.001.004-.032-.034-.03-.03.001.003-.003-.035 0-.031 0 .002-.027.007-.031 0 .002.003-.003-.034 0-.03l-.03-.031c.001.003-.003-.034 0-.031a.52.52 0 0 0-.062-.061 3.266 3.266 0 0 1-.03-.03l-.031-.031c.003.002-.034-.003-.03 0 .003.002-.035-.033-.031-.031l-.031-.03c.004.001-.034-.033-.03-.031.003.002-.035-.002-.031 0 .004.002-.035-.002-.03 0 .003.001-.035-.032-.031-.03.004 0-.035-.002-.031 0 .004 0-.035-.002-.03 0 .003 0-.035-.032-.031-.031h-.061a.52.52 0 0 0-.031 0H.69a.52.52 0 0 0-.061 0z"/>
+ <path fill="#fff" d="M16.064 2.188v2.873c-8.872.057-8.7 8.606-8.7 8.606s3.163-4.297 8.7-3.442v3.442l5.797-5.734-5.797-5.745zM.624 3.723V20.46H18.75v-7.227l-2.655 2.602v1.97H3.331V6.336H8.08l3.94-2.613H.625z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-rtl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-rtl.svg
new file mode 100644
index 00000000..b16507cf
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/use-rtl.svg
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
+ <path fill-opacity=".51" d="M6.81 1.55a.52.52 0 0 0 .092.062.52.52 0 0 0 .244.153c-.003-.003.035.004.031 0-.004-.004.004.035 0 .03l.03.031a.52.52 0 0 0 0 .03.52.52 0 0 0 .031 0c-.002-.003.003.035 0 .031l.03.031c-.001-.004.033.034.031.03-.001-.003.002.035 0 .031-.001-.004.033.035.031.03-.002-.003.001.035 0 .031v.031a.52.52 0 0 0 .03.122V4.55c4.157.278 6.5 2.398 7.589 4.59 1.141 2.299 1.103 4.542 1.101 4.59v.122a.52.52 0 0 0-.06.184.52.52 0 0 0 0 .03c0-.003-.033.035-.031.031.001-.004-.002.034 0 .03a.52.52 0 0 0-.03.031c.002-.004-.035.035-.032.03.003-.003-.002.035 0 .031a.52.52 0 0 0-.03.031c.002-.002-.024-.008-.03 0-.008.008-.002.033 0 .03.003-.003-.004.035 0 .031.003-.003-.035.004-.031 0l-.03.03a.52.52 0 0 0-.032.031c.004-.002-.034.003-.03 0 .003-.002-.034.033-.03.031.003-.002-.035.032-.031.03.003-.001-.035.002-.03 0 .003-.001-.035.033-.032.031.004-.001-.034.002-.03 0h-.03a.52.52 0 0 0-.123.03h-.091a.2.2 0 0 0-.031 0h-.061a.52.52 0 0 0-.123-.03h-.03c.003.002-.035-.001-.031 0 .004.002-.035-.032-.03-.03.003.001-.035-.002-.031 0 .003.001-.035-.033-.031-.031l-.03-.03c.003.002-.035-.003-.031 0a.52.52 0 0 0-.03-.031l-.031-.03c.003.003-.035-.004-.031 0-.008-.008-.002-.033 0-.031l-.03-.031-.031-.03a.52.52 0 0 0-.03-.031S12.071 10.6 7.36 10.975v2.846a.52.52 0 0 0-.031.122v.03c.001-.003-.002.035 0 .031.002-.004-.032.035-.03.03.001-.003-.002.035 0 .031.001-.003-.033.035-.031.031.002-.003-.002.034 0 .03-.005.008-.032.002-.03 0 .001-.003-.003.035 0 .031l-.031.03c.002-.002-.003.035 0 .031.002-.003-.034.003-.03 0l-.032.031c.003-.003-.002.033 0 .03.003-.002-.033.003-.03 0l-.03.031c.002-.002-.004.033 0 .03.002-.002-.035.003-.031 0l-.03.031c.002-.002-.035.002-.032 0 .004-.002-.003.033 0 .031-.01.006-.033.001-.03 0a4.144 4.144 0 0 0-.061.03c.005-.002-.036.003-.03 0 .005-.002-.037.033-.032.031.006-.002-.036.002-.03 0 .006-.001-.067.032-.061.03.005 0-.037.002-.03 0h-.032a.52.52 0 0 0-.03 0h-.123a.52.52 0 0 0-.183-.06c.004.001-.035-.002-.03 0 .003.001-.035-.033-.031-.031a.52.52 0 0 0-.061-.03l-.031-.031c.004.003-.034-.004-.03 0 .003.004-.004-.035 0-.03l-.031-.031a.52.52 0 0 0-.03 0L.292 8.558a.52.52 0 0 0-.062-.061c.003.003-.002-.034 0-.031.003.003-.032-.034-.03-.03.002.003-.003-.035 0-.031l-.03-.03c0 .003-.033-.035-.031-.031.001.003-.002-.035 0-.031a.071.071 0 0 0 0-.03c-.004-.008-.032-.002-.031 0v-.061a.52.52 0 0 0-.03-.123v-.122a.52.52 0 0 0 .03-.123v-.061c0 .002.027.008.03 0 0 .004.002-.035 0-.03 0 .003.002-.035 0-.031-.001.004.033-.035.031-.03a.067.067 0 0 1 0-.032c0 .002.027.008.03 0-.002.004.003-.033 0-.03-.001.003.034-.034.031-.03-.002.003.003-.035 0-.031a.52.52 0 0 0 .062-.062l5.813-5.752a.52.52 0 0 0 .061-.061c-.003.002.034-.002.03 0l.032-.03a.06.06 0 0 0 .03 0c-.003.002.034-.033.03-.031l.031-.03c-.003 0 .035-.003.03 0a.071.071 0 0 0 .032 0c.007-.004.001-.032 0-.032-.004.002.034 0 .03 0-.004.002.035 0 .03 0a.52.52 0 0 0 .123-.03h.03a2.328 2.328 0 0 0 .123 0h.03a.52.52 0 0 0 .062 0zm15.42 1.53a.52.52 0 0 0 .153.093.52.52 0 0 0 .184.122c-.003-.003.003.034 0 .03a.52.52 0 0 0 .03.031c-.002-.003.033.003.031 0a.52.52 0 0 0 0 .03l.03.031c-.002-.003.003.034 0 .031-.001-.003.033.003.031 0 .006.01.002.033 0 .03l.03.062c-.002-.006.003.036 0 .03-.001-.005.033.037.031.03-.001-.005.002.037 0 .032-.001-.006.032.067.031.06v.061a.52.52 0 0 0 0 .062v16.798a.52.52 0 0 0-.03.123c0-.004-.002.034 0 .03 0-.004-.002.035 0 .031.001-.004-.033.034-.031.03.002-.003-.002.035 0 .031.002-.004-.033.034-.03.03.001-.003-.003.035 0 .031-.005.008-.033.002-.031 0 .002-.003-.003.034 0 .031.002-.003-.033.034-.031.03.002-.003-.002.034 0 .031.002-.003-.033.003-.03 0l-.031.03c.003-.002-.003.034 0 .031.003-.002-.034.003-.03 0l-.031.031c.003-.003-.004.033 0 .03.003-.002-.034.003-.031 0 .003-.002-.034.033-.03.031.003-.002-.035.002-.031 0 .003-.002-.004.033 0 .03-.01.007-.033.002-.03 0a4.263 4.263 0 0 0-.062.031c.005-.002-.036.003-.03 0 .005-.002-.037.033-.031.031.005-.002-.036.002-.03 0l-.062.03h-.061a.52.52 0 0 0-.061 0H3.872a.52.52 0 0 0-.122-.03h-.03c.003.001-.035-.002-.031 0 .004.002-.035-.032-.03-.03.003.001-.035-.002-.031 0 .003.001-.035-.033-.03-.031l-.032-.03c.004.001-.033-.003-.03 0 .003.001-.034-.034-.03-.031.003.002-.034-.003-.031 0 .003.002-.003-.034 0-.031l-.03-.03c.002.002-.034-.003-.031 0 .002.002-.003-.034 0-.031l-.031-.03c.003.002-.033-.004-.03 0 .002.002-.003-.035 0-.031l-.031-.031c.002.003-.002-.034 0-.03l-.03-.031a4.143 4.143 0 0 0-.031-.061c.002.005-.003-.036 0-.031.002.005-.033-.036-.031-.03.002.005-.002-.037 0-.031.001.005-.032-.067-.03-.061 0 .005-.002-.037 0-.031v-.03a.52.52 0 0 0 0-.062V13.27a.52.52 0 0 0 .03-.122v-.061c-.002.003.032-.035.03-.031-.001.004.002-.035 0-.03-.001.003.033-.035.031-.031-.001.001-.004-.024 0-.031-.002.003.033-.004.03 0-.001.003.003-.034 0-.03l.031-.031c-.002.003.003-.034 0-.03-.002.002.034-.004.03 0l.032-.031c-.003.002.002-.034 0-.031-.003.003.033-.003.03 0l.03-.03c-.002.002.004-.034 0-.031-.002.002.035-.003.031 0l.03-.03c-.002.001.035-.003.031 0-.003.001.004-.033 0-.031.01-.006.034-.002.031 0l.061-.031c-.005.002.036-.002.03 0-.005.002.037-.033.031-.03-.005.001.037-.002.031 0-.006 0 .067-.032.061-.031h.061a.52.52 0 0 0 .031 0h.122a.52.52 0 0 0 .153.06.52.52 0 0 0 .092.032c-.004-.002.035.001.03 0-.003-.002.035.032.031.03l.031.03c-.003-.002.034.003.03 0a.52.52 0 0 0 .031.062.52.52 0 0 0 .03 0l2.663 2.6a.52.52 0 0 0 .061.062c-.002-.003.002.034 0 .03l.03.031c-.001-.003.033.034.031.03-.002-.003.002.035 0 .031-.001-.003.032.035.03.03 0-.003.002.035 0 .032a.071.071 0 0 0 0 .03c.004.008.032.002.031 0-.001-.004.002.035 0 .03a.16.16 0 0 0 0 .031.52.52 0 0 0 .031.123v.03a.452.452 0 0 0 0 .062v1.193h11.29V7.15h-4.068a.52.52 0 0 0-.093-.03.52.52 0 0 0-.153-.03c.004.001-.034-.033-.03-.031.003.002-.034-.033-.03-.031.003.002-.035-.003-.031 0l-3.948-2.6a.52.52 0 0 0-.06-.032l-.031-.03a1.374 1.374 0 0 0-.03-.03c.004.004-.036-.067-.032-.062.005.005-.034-.036-.03-.03.004.005-.034-.037-.03-.031 0 .002.004-.021 0-.03.002.003-.033-.035-.031-.031.003.006-.034-.037-.03-.03 0 .002.004-.019 0-.031a.071.071 0 0 0 0-.031c-.004-.008-.032-.002-.032 0 .002.004 0-.035 0-.03.002.003 0-.035 0-.031a.52.52 0 0 0-.03-.123v-.122a.52.52 0 0 0 .03-.122c0 .004.002-.035 0-.031 0 .004.002-.035 0-.03 0 .001.028.007.031 0V3.54c-.001.004.002-.035 0-.03-.001.003.032-.035.03-.031-.001.003.003-.035 0-.031 0 .002.027.007.031 0-.002.003.003-.034 0-.03l.03-.031c-.001.003.003-.034 0-.03a.52.52 0 0 0 .062-.062l.03-.03.031-.031c-.003.002.034-.003.03 0l.031-.03.031-.031c-.004.002.034-.033.03-.031-.003.002.035-.002.031 0-.004.002.035-.002.03 0-.003.002.035-.032.031-.03-.004 0 .035-.002.031 0-.004 0 .035-.002.03 0-.003 0 .035-.032.031-.031h.061a.52.52 0 0 0 .031 0h11.505a.452.452 0 0 1 .062 0 .52.52 0 0 0 .061 0z"/>
+ <path fill="#fff" d="M6.798 2.189V5.06c8.873.057 8.7 8.606 8.7 8.606s-3.162-4.296-8.7-3.442v3.442L1.002 7.933 6.798 2.19zm15.44 1.534V20.46H4.113v-7.227l2.654 2.603v1.97h12.765V6.336h-4.75l-3.94-2.613h11.396z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-ltr.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-ltr.svg
new file mode 100644
index 00000000..a631d5a0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-ltr.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80">
+ <path fill="#72777d" d="M16.436 8C8.396 8 8.014 15.667 8 16.049V72h55.562c8.039 0 8.422-7.667 8.438-8.049V8H16.436z"/>
+ <path fill="#fff" d="M31.202 26.303a4.655 4.655 0 1 1-.012 9.31 4.655 4.655 0 0 1 .012-9.31z"/>
+ <circle cx="50.476" cy="30.957" r="4.654" fill="#fff"/>
+ <path fill="#fff" d="M40.835 57.729c-7.189 0-13.987-2.433-18.186-6.508a2.666 2.666 0 1 1 3.715-3.827c3.226 3.131 8.636 5 14.471 5 5.749 0 11.117-1.83 14.359-4.896a2.667 2.667 0 0 1 3.665 3.875c-4.271 4.04-10.84 6.356-18.024 6.356z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-rtl.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-rtl.svg
new file mode 100644
index 00000000..dcfeecfa
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/user-rtl.svg
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80">
+ <path fill="#72777d" d="M63.564 8c8.04 0 8.422 7.667 8.436 8.049V72H16.438C8.399 72 8.016 64.333 8 63.951V8h55.564z"/>
+ <path fill="#fff" d="M48.798 26.303a4.655 4.655 0 1 0 .012 9.31 4.655 4.655 0 0 0-.012-9.31z"/>
+ <circle cx="50.476" cy="30.957" r="4.654" fill="#fff" transform="matrix(-1 0 0 1 80 0)"/>
+ <path fill="#fff" d="M39.165 57.729c7.189 0 13.987-2.433 18.186-6.508a2.666 2.666 0 1 0-3.715-3.827c-3.226 3.131-8.636 5-14.471 5-5.749 0-11.117-1.83-14.359-4.896a2.667 2.667 0 0 0-3.665 3.875c4.271 4.04 10.84 6.356 18.024 6.356z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_gray.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_gray.svg
new file mode 100644
index 00000000..2f0e4440
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_gray.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="96" height="96" viewBox="0 0 96 96">
+ <path fill="#a2a9b1" d="M96 14L82 0 48 34 14 0 0 14l34 34L0 82l14 14 34-34 34 34 14-14-34-34z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_white.svg b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_white.svg
new file mode 100644
index 00000000..75521e7e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/img/x_white.svg
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="96" height="96" viewBox="0 0 96 96">
+ <polygon fill="#fff" points="96,14 82,0 48,34 14,0 0,14 34,48 0,82 14,96 48,62 82,96 96,82 62,48 "/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.js
new file mode 100644
index 00000000..61d33624
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.js
@@ -0,0 +1,467 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var C;
+
+ /**
+ * UI component that contains the multimedia element to be displayed.
+ * This first version assumes an image but it can be extended to other
+ * media types (video, sound, presentation, etc.).
+ *
+ * @class mw.mmv.ui.Canvas
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container Canvas' container
+ * @param {jQuery} $imageWrapper
+ * @param {jQuery} $mainWrapper
+ */
+ function Canvas( $container, $imageWrapper, $mainWrapper ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ /**
+ * @property {boolean}
+ * @private
+ */
+ this.dialogOpen = false;
+
+ /**
+ * @property {mw.mmv.ThumbnailWidthCalculator}
+ * @private
+ */
+ this.thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator();
+
+ /**
+ * Contains image.
+ * @property {jQuery}
+ */
+ this.$imageDiv = $( '<div>' )
+ .addClass( 'mw-mmv-image' );
+
+ this.$imageDiv.appendTo( this.$container );
+
+ /**
+ * Container of canvas and controls, needed for canvas size calculations.
+ * @property {jQuery}
+ * @private
+ */
+ this.$imageWrapper = $imageWrapper;
+
+ /**
+ * Main container of image and metadata, needed to propagate events.
+ * @property {jQuery}
+ * @private
+ */
+ this.$mainWrapper = $mainWrapper;
+
+ /**
+ * Raw metadata of current image, needed for canvas size calculations.
+ * @property {mw.mmv.LightboxImage}
+ * @private
+ */
+ this.imageRawMetadata = null;
+ }
+ oo.inheritClass( Canvas, mw.mmv.ui.Element );
+ C = Canvas.prototype;
+
+ /**
+ * Maximum blownup factor tolerated
+ * @property MAX_BLOWUP_FACTOR
+ * @static
+ */
+ Canvas.MAX_BLOWUP_FACTOR = 11;
+
+ /**
+ * Blowup factor threshold at which blurring kicks in
+ * @property BLUR_BLOWUP_FACTOR_THRESHOLD
+ * @static
+ */
+ Canvas.BLUR_BLOWUP_FACTOR_THRESHOLD = 2;
+
+ /**
+ * Clears everything.
+ */
+ C.empty = function () {
+ this.$imageDiv.addClass( 'empty' ).removeClass( 'error' );
+
+ this.$imageDiv.empty();
+ };
+
+ /**
+ * Sets image on the canvas; does not resize it to fit. This is used to make the placeholder
+ * image available; it will be resized and displayed by #maybeDisplayPlaceholder().
+ * FIXME maybeDisplayPlaceholder() receives the placeholder so it is very unclear why this
+ * is necessary at all (apart from setting the LightboxImage, which is used in size calculations).
+ *
+ * @param {mw.mmv.LightboxImage} imageRawMetadata
+ * @param {jQuery} $imageElement
+ */
+ C.set = function ( imageRawMetadata, $imageElement ) {
+ this.$imageDiv.removeClass( 'empty' );
+
+ this.imageRawMetadata = imageRawMetadata;
+ this.$image = $imageElement;
+ this.setUpImageClick();
+
+ this.$imageDiv.html( this.$image );
+ };
+
+ /**
+ * Resizes image to the given dimensions and displays it on the canvas.
+ * This is used to display the actual image; it assumes set function was already called before.
+ *
+ * @param {mw.mmv.model.Thumbnail} thumbnail thumbnail information
+ * @param {HTMLImageElement} imageElement
+ * @param {mw.mmv.model.ThumbnailWidth} imageWidths
+ */
+ C.setImageAndMaxDimensions = function ( thumbnail, imageElement, imageWidths ) {
+ var $image = $( imageElement );
+
+ // we downscale larger images but do not scale up smaller ones, that would look ugly
+ if ( thumbnail.width > imageWidths.cssWidth ) {
+ imageElement.width = imageWidths.cssWidth;
+ imageElement.height = imageWidths.cssHeight;
+ }
+
+ if ( !this.$image.is( imageElement ) ) { // http://bugs.jquery.com/ticket/4087
+ this.$image.replaceWith( $image );
+ this.$image = $image;
+
+ // Since the image element got replaced, we need to rescue the dialog-open class.
+ this.$image.toggleClass( 'mw-mmv-dialog-is-open', this.dialogOpen );
+
+ this.setUpImageClick();
+ }
+ };
+
+ /**
+ * Handles a "dialog open/close" event from dialogs on the page.
+ *
+ * @param {jQuery.Event} e
+ */
+ C.handleDialogEvent = function ( e ) {
+ switch ( e.type ) {
+ case 'mmv-download-opened':
+ this.downloadOpen = true;
+ break;
+ case 'mmv-download-closed':
+ this.downloadOpen = false;
+ break;
+ case 'mmv-reuse-opened':
+ this.reuseOpen = true;
+ break;
+ case 'mmv-reuse-closed':
+ this.reuseOpen = false;
+ break;
+ case 'mmv-options-opened':
+ this.optionsOpen = true;
+ break;
+ case 'mmv-options-closed':
+ this.optionsOpen = false;
+ break;
+ }
+
+ this.dialogOpen = this.reuseOpen || this.downloadOpen || this.optionsOpen;
+ this.$image.toggleClass( 'mw-mmv-dialog-is-open', this.dialogOpen );
+ };
+
+ /**
+ * Registers click listener on the image.
+ */
+ C.setUpImageClick = function () {
+ var canvas = this;
+
+ this.handleEvent( 'mmv-reuse-opened', $.proxy( this.handleDialogEvent, this ) );
+ this.handleEvent( 'mmv-reuse-closed', $.proxy( this.handleDialogEvent, this ) );
+ this.handleEvent( 'mmv-download-opened', $.proxy( this.handleDialogEvent, this ) );
+ this.handleEvent( 'mmv-download-closed', $.proxy( this.handleDialogEvent, this ) );
+ this.handleEvent( 'mmv-options-opened', $.proxy( this.handleDialogEvent, this ) );
+ this.handleEvent( 'mmv-options-closed', $.proxy( this.handleDialogEvent, this ) );
+
+ this.$image.on( 'click.mmv-canvas', function ( e ) {
+ // ignore clicks if the metadata panel or one of the dialogs is open - assume the intent is to
+ // close it in this case; that will be handled elsewhere
+ if (
+ !canvas.dialogOpen &&
+ // FIXME a UI component should not know about its parents
+ canvas.$container.closest( '.metadata-panel-is-open' ).length === 0
+ ) {
+ e.stopPropagation(); // don't let $imageWrapper handle this
+ mw.mmv.actionLogger.log( 'view-original-file' ).always( function () {
+ $( document ).trigger( 'mmv-viewfile' );
+ } );
+ }
+ } );
+
+ // open the download panel on right clicking the image
+ this.$image.on( 'mousedown.mmv-canvas', function ( e ) {
+ if ( e.which === 3 ) {
+ mw.mmv.actionLogger.log( 'right-click-image' );
+ if ( !canvas.downloadOpen ) {
+ $( document ).trigger( 'mmv-download-open', e );
+ e.stopPropagation();
+ }
+ }
+ } );
+ };
+
+ /**
+ * Registers listeners.
+ */
+ C.attach = function () {
+ var canvas = this;
+
+ $( window ).on( 'resize.mmv-canvas', $.debounce( 100, function () {
+ canvas.$mainWrapper.trigger( $.Event( 'mmv-resize-end' ) );
+ } ) );
+
+ this.$imageWrapper.on( 'click.mmv-canvas', function () {
+ if ( canvas.$container.closest( '.metadata-panel-is-open' ).length > 0 ) {
+ canvas.$mainWrapper.trigger( 'mmv-panel-close-area-click' );
+ }
+ } );
+ };
+
+ /**
+ * Clears listeners.
+ */
+ C.unattach = function () {
+ this.clearEvents();
+
+ $( window ).off( 'resize.mmv-canvas' );
+
+ this.$imageWrapper.off( 'click.mmv-canvas' );
+ };
+
+ /**
+ * Sets page thumbnail for display if blowupFactor <= MAX_BLOWUP_FACTOR. Otherwise thumb is not set.
+ * The image gets also blured to avoid pixelation if blowupFactor > BLUR_BLOWUP_FACTOR_THRESHOLD.
+ * We set SVG files to the maximum screen size available.
+ * Assumes set function called before.
+ *
+ * @param {{width: number, height: number}} size
+ * @param {jQuery} $imagePlaceholder Image placeholder to be displayed while the real image loads.
+ * @param {mw.mmv.model.ThumbnailWidth} imageWidths
+ * @return {boolean} Whether the image was blured or not
+ */
+ C.maybeDisplayPlaceholder = function ( size, $imagePlaceholder, imageWidths ) {
+ var targetWidth,
+ targetHeight,
+ blowupFactor,
+ blurredThumbnailShown = false;
+
+ // Assume natural thumbnail size¸
+ targetWidth = size.width;
+ targetHeight = size.height;
+
+ // If the image is bigger than the screen we need to resize it
+ if ( size.width > imageWidths.cssWidth ) { // This assumes imageInfo.width in CSS units
+ targetWidth = imageWidths.cssWidth;
+ targetHeight = imageWidths.cssHeight;
+ }
+
+ blowupFactor = targetWidth / $imagePlaceholder.width();
+
+ // If the placeholder is too blown up, it's not worth showing it
+ if ( blowupFactor > Canvas.MAX_BLOWUP_FACTOR ) {
+ return blurredThumbnailShown;
+ }
+
+ $imagePlaceholder.width( targetWidth );
+ $imagePlaceholder.height( targetHeight );
+
+ // Only blur the placeholder if it's blown up significantly
+ if ( blowupFactor > Canvas.BLUR_BLOWUP_FACTOR_THRESHOLD ) {
+ this.blur( $imagePlaceholder );
+ blurredThumbnailShown = true;
+ }
+
+ this.set( this.imageRawMetadata, $imagePlaceholder.show() );
+
+ return blurredThumbnailShown;
+ };
+
+ /**
+ * Blur image
+ *
+ * @param {jQuery} $image Image to be blurred.
+ */
+ C.blur = function ( $image ) {
+ // We have to apply the SVG filter here, it doesn't work when defined in the .less file
+ // We can't use an external SVG file because filters can't be accessed cross-domain
+ // We can't embed the SVG file because accessing the filter inside of it doesn't work
+ $image.addClass( 'blurred' ).css( 'filter', 'url("#gaussian-blur")' );
+ };
+
+ /**
+ * Animates the image into focus
+ */
+ C.unblurWithAnimation = function () {
+ var self = this,
+ animationLength = 300;
+
+ // The blurred class has an opacity < 1. This animated the image to become fully opaque
+ this.$image
+ .addClass( 'blurred' )
+ .animate( { opacity: 1.0 }, animationLength );
+
+ // During the same amount of time (animationLength) we animate a blur value from 3.0 to 0.0
+ // We pass that value to an inline CSS Gaussian blur effect
+ $( { blur: 3.0 } ).animate( { blur: 0.0 }, {
+ duration: animationLength,
+ step: function ( step ) {
+ self.$image.css( { '-webkit-filter': 'blur(' + step + 'px)',
+ filter: 'blur(' + step + 'px)' } );
+ },
+ complete: function () {
+ // When the animation is complete, the blur value is 0, clean things up
+ self.unblur();
+ }
+ } );
+ };
+
+ C.unblur = function () {
+ // We apply empty CSS values to remove the inline styles applied by jQuery
+ // so that they don't get in the way of styles defined in CSS
+ this.$image.css( { '-webkit-filter': '', opacity: '', filter: '' } )
+ .removeClass( 'blurred' );
+ };
+
+ /**
+ * Displays a message and error icon when loading the image fails.
+ *
+ * @param {string} error error message
+ */
+ C.showError = function ( error ) {
+ var errorDetails, description, errorUri, retryLink, reportLink,
+ canvasDimensions = this.getDimensions(),
+ thumbnailDimensions = this.getCurrentImageWidths(),
+ htmlUtils = new mw.mmv.HtmlUtils();
+
+ errorDetails = [
+ 'error: ' + error,
+ 'URL: ' + location.href,
+ 'user agent: ' + navigator.userAgent,
+ 'screen size: ' + screen.width + 'x' + screen.height,
+ 'canvas size: ' + canvasDimensions.width + 'x' + canvasDimensions.height,
+ 'image size: ' + this.imageRawMetadata.originalWidth + 'x' + this.imageRawMetadata.originalHeight,
+ 'thumbnail size: CSS: ' + thumbnailDimensions.cssWidth + 'x' + thumbnailDimensions.cssHeight +
+ ', screen width: ' + thumbnailDimensions.screen + ', real width: ' + thumbnailDimensions.real
+ ];
+ // ** is bolding in Phabricator
+ description = '**' + mw.message( 'multimediaviewer-errorreport-privacywarning' ).text() + '**\n\n\n' +
+ 'Error details:\n\n' + errorDetails.join( '\n' );
+ errorUri = mw.msg( 'multimediaviewer-report-issue-url', encodeURIComponent( description ) );
+
+ retryLink = $( '<a>' ).addClass( 'mw-mmv-retry-link' ).text(
+ mw.msg( 'multimediaviewer-thumbnail-error-retry' ) );
+ reportLink = $( '<a>' ).attr( 'href', errorUri ).text(
+ mw.msg( 'multimediaviewer-thumbnail-error-report' ) );
+
+ this.$imageDiv.empty()
+ .addClass( 'error' )
+ .append(
+ $( '<div>' ).addClass( 'error-box' ).append(
+ $( '<div>' ).addClass( 'mw-mmv-error-text' ).text(
+ mw.msg( 'multimediaviewer-thumbnail-error' )
+ )
+ ).append(
+ $( '<div>' ).addClass( 'mw-mmv-error-description' ).append(
+ mw.msg( 'multimediaviewer-thumbnail-error-description',
+ htmlUtils.jqueryToHtml( retryLink ),
+ error,
+ htmlUtils.jqueryToHtml( reportLink )
+ )
+ )
+ )
+ );
+ this.$imageDiv.find( '.mw-mmv-retry-link' ).click( function () {
+ location.reload();
+ } );
+ };
+
+ /**
+ * Returns width and height of the canvas area (i.e. the space available for the image).
+ *
+ * @param {boolean} forFullscreen if true, return size in fullscreen mode; otherwise, return current size
+ * (which might still be fullscreen mode).
+ * @return {Object} Width and height in CSS pixels
+ */
+ C.getDimensions = function ( forFullscreen ) {
+ var $window = $( window ),
+ $aboveFold = $( '.mw-mmv-above-fold' ),
+ isFullscreened = !!$aboveFold.closest( '.jq-fullscreened' ).length,
+ // Don't rely on this.$imageWrapper's sizing because it's fragile.
+ // Depending on what the wrapper contains, its size can be 0 on some browsers.
+ // Therefore, we calculate the available space manually
+ availableWidth = $window.width(),
+ availableHeight = $window.height() - ( isFullscreened ? 0 : $aboveFold.outerHeight() );
+
+ if ( forFullscreen ) {
+ return {
+ width: screen.width,
+ height: screen.height
+ };
+ } else {
+ return {
+ width: availableWidth,
+ height: availableHeight
+ };
+ }
+ };
+
+ /**
+ * Gets the widths for a given lightbox image.
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @return {mw.mmv.model.ThumbnailWidth}
+ */
+ C.getLightboxImageWidths = function ( image ) {
+ var thumb = image.thumbnail,
+ canvasDimensions = this.getDimensions();
+
+ return this.thumbnailWidthCalculator.calculateWidths(
+ canvasDimensions.width, canvasDimensions.height, thumb.width, thumb.height );
+ };
+
+ /**
+ * Gets the fullscreen widths for a given lightbox image.
+ * Intended for use before the viewer is in fullscreen mode
+ * (in fullscreen mode getLightboxImageWidths() works fine).
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @return {mw.mmv.model.ThumbnailWidth}
+ */
+ C.getLightboxImageWidthsForFullscreen = function ( image ) {
+ var thumb = image.thumbnail,
+ canvasDimensions = this.getDimensions( true );
+
+ return this.thumbnailWidthCalculator.calculateWidths(
+ canvasDimensions.width, canvasDimensions.height, thumb.width, thumb.height );
+ };
+
+ /**
+ * Gets the widths for the current lightbox image.
+ *
+ * @return {mw.mmv.model.ThumbnailWidth}
+ */
+ C.getCurrentImageWidths = function () {
+ return this.getLightboxImageWidths( this.imageRawMetadata );
+ };
+
+ mw.mmv.ui.Canvas = Canvas;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.less
new file mode 100644
index 00000000..63ff35f1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvas.less
@@ -0,0 +1,89 @@
+@import '../mmv.mixins';
+
+.mw-mmv-image {
+ display: table-cell;
+ width: 100%;
+ height: 100%;
+ vertical-align: middle;
+ .unselectable;
+
+ &.empty {
+ display: none;
+ }
+ &.error {
+ background-color: #222;
+
+ a,
+ a:visited {
+ cursor: pointer;
+ color: #3472e5;
+ }
+ }
+
+ .error-box {
+ /* @embed */
+ background: url( img/error-media-icon.svg ) no-repeat 0 0;
+ background-size: 110px 110px;
+
+ position: absolute;
+ left: 50%;
+ margin-left: -350px;
+ top: 50%;
+ margin-top: -100px;
+
+ padding: 0 20px 0 160px;
+ color: #fff;
+
+ max-width: 520px;
+
+ .mw-mmv-error-text {
+ font-size: 48px;
+ }
+
+ .mw-mmv-error-description {
+ margin-top: 30px;
+ font-size: 22px;
+ }
+ }
+}
+
+.mw-mmv-image img {
+ display: block;
+ margin-right: auto;
+ margin-left: auto;
+ cursor: pointer;
+ cursor: zoom-in;
+
+ &.blurred {
+ filter: blur( 3px );
+ -webkit-filter: blur( 3px );
+ .opacity( 0.8 );
+ }
+
+ /* Whitelist file types that are potentially transparent.
+ We don't set it for other file types because Media Viewer plugins
+ can find that undesirable (eg. 3d) */
+ &.gif,
+ &.png,
+ &.svg,
+ &.tiff,
+ &.tif {
+ background: url( checker.png ) repeat;
+ }
+
+ &.mw-mmv-dialog-is-open {
+ cursor: default;
+ }
+
+ .metadata-panel-is-open & {
+ cursor: pointer;
+ }
+}
+
+.mw-mmv-image.empty img {
+ display: none;
+}
+
+.metadata-panel-is-open .mw-mmv-image-wrapper {
+ cursor: pointer;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.js
new file mode 100644
index 00000000..0bf6c2c6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.js
@@ -0,0 +1,285 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var CBP;
+
+ /**
+ * Represents the buttons which are displayed over the image - next, previous, close
+ * and fullscreen.
+ *
+ * @class mw.mmv.ui.CanvasButtons
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container The parent element we should put the buttons into.
+ * @param {jQuery} $closeButton The close button element from the parent class.
+ * @param {jQuery} $fullscreenButton The fullscreen button from the parent class.
+ */
+ function CanvasButtons( $container, $closeButton, $fullscreenButton ) {
+ var buttons = this,
+ tooltipDelay = mw.config.get( 'wgMultimediaViewer' ).tooltipDelay;
+
+ mw.mmv.ui.Element.call( this, $container );
+
+ this.$close = $closeButton;
+ this.$fullscreen = $fullscreenButton;
+
+ this.$reuse = $( '<button>' )
+ .addClass( 'mw-mmv-reuse-button' )
+ .html( '&nbsp;' )
+ .prop( 'title', mw.message( 'multimediaviewer-reuse-link' ).text() )
+ .tipsy( {
+ delayIn: tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } );
+
+ this.$options = $( '<button>' )
+ .text( ' ' )
+ .prop( 'title', mw.message( 'multimediaviewer-options-tooltip' ).text() )
+ .addClass( 'mw-mmv-options-button' )
+ .tipsy( {
+ delayIn: tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } );
+
+ this.$download = $( '<button>' )
+ .addClass( 'mw-mmv-download-button' )
+ .html( '&nbsp;' )
+ .prop( 'title', mw.message( 'multimediaviewer-download-link' ).text() )
+ .tipsy( {
+ delayIn: tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } );
+
+ this.$next = $( '<button>' )
+ .prop( 'title', mw.message( 'multimediaviewer-next-image-alt-text' ).text() )
+ .addClass( 'mw-mmv-next-image disabled' )
+ .html( '&nbsp;' );
+
+ this.$prev = $( '<button>' )
+ .prop( 'title', mw.message( 'multimediaviewer-prev-image-alt-text' ).text() )
+ .addClass( 'mw-mmv-prev-image disabled' )
+ .html( '&nbsp;' );
+
+ this.$nav = this.$next
+ .add( this.$prev );
+
+ this.$buttons = this.$close
+ .add( this.$download )
+ .add( this.$reuse )
+ .add( this.$fullscreen )
+ .add( this.$options )
+ .add( this.$next )
+ .add( this.$prev );
+
+ this.$buttons.appendTo( this.$container );
+
+ $( document ).on( 'mmv-close', function () {
+ buttons.$nav.addClass( 'disabled' );
+ } );
+
+ this.$close.click( function () {
+ $container.trigger( $.Event( 'mmv-close' ) );
+ } );
+
+ this.$next.click( function () {
+ buttons.emit( 'next' );
+ } );
+
+ this.$prev.click( function () {
+ buttons.emit( 'prev' );
+ } );
+ }
+ oo.inheritClass( CanvasButtons, mw.mmv.ui.Element );
+ CBP = CanvasButtons.prototype;
+
+ /**
+ * Sets the top offset for the navigation buttons.
+ *
+ * @param {number} offset
+ */
+ CBP.setOffset = function ( offset ) {
+ this.$nav.css( {
+ top: offset
+ } );
+ };
+
+ /**
+ * Stops the fading animation of the buttons and cancel any opacity value
+ */
+ CBP.stopFade = function () {
+ this.$buttons
+ .stop( true )
+ .removeClass( 'hidden' )
+ .css( 'opacity', '' );
+
+ this.$container.trigger( $.Event( 'mmv-fade-stopped' ) );
+ };
+
+ /**
+ * Toggles buttons being disabled or not
+ *
+ * @param {boolean} showPrevButton
+ * @param {boolean} showNextButton
+ */
+ CBP.toggle = function ( showPrevButton, showNextButton ) {
+ this.$next.toggleClass( 'disabled', !showPrevButton );
+ this.$prev.toggleClass( 'disabled', !showNextButton );
+ };
+
+ /**
+ * Fades out the active buttons
+ */
+ CBP.fadeOut = function () {
+ var buttons = this;
+
+ // We don't use animation chaining because delay() can't be stop()ed
+ this.buttonsFadeTimeout = setTimeout( function () {
+ buttons.$buttons.not( '.disabled' ).animate( { opacity: 0 }, 1000, 'swing',
+ function () {
+ buttons.$buttons.addClass( 'hidden' );
+ buttons.$container.trigger( $.Event( 'mmv-faded-out' ) );
+ } );
+ }, 1500 );
+ };
+
+ /**
+ * Checks if any active buttons are currently hovered, given a position
+ *
+ * @param {number} x The horizontal coordinate of the position
+ * @param {number} y The vertical coordinate of the position
+ * @return {boolean}
+ */
+ CBP.isAnyActiveButtonHovered = function ( x, y ) {
+ // We don't use mouseenter/mouseleave events because content is subject
+ // to change underneath the cursor, eg. when entering fullscreen or
+ // when going prev/next (the button can disappear when reaching ends)
+ var hovered = false;
+
+ this.$buttons.not( '.disabled' ).each( function ( idx, e ) {
+ var $e = $( e ),
+ offset = $e.offset();
+
+ if ( y >= offset.top &&
+ // using css( 'height' ) & css( 'width' ) instead of .height()
+ // and .width() since those don't include padding, and as a
+ // result can return a smaller size than is actually the button
+ y <= offset.top + parseInt( $e.css( 'height' ) ) &&
+ x >= offset.left &&
+ x <= offset.left + parseInt( $e.css( 'width' ) ) ) {
+ hovered = true;
+ }
+ } );
+
+ return hovered;
+ };
+
+ /**
+ * Reveals all active buttons and schedule a fade out if needed
+ *
+ * @param {Object} [mousePosition] Mouse position containing 'x' and 'y' properties
+ */
+ CBP.revealAndFade = function ( mousePosition ) {
+ if ( this.buttonsFadeTimeout ) {
+ clearTimeout( this.buttonsFadeTimeout );
+ }
+
+ // Stop ongoing animations and make sure the buttons that need to be displayed are displayed
+ this.stopFade();
+
+ // mousePosition can be empty, for instance when we enter fullscreen and haven't
+ // recorded a real mousemove event yet
+ if ( !mousePosition ||
+ !this.isAnyActiveButtonHovered( mousePosition.x, mousePosition.y ) ) {
+ this.fadeOut();
+ }
+ };
+
+ /**
+ * @event mmv-reuse-open
+ * Fired when the button to open the reuse dialog is clicked.
+ */
+ /**
+ * Registers listeners.
+ */
+ CBP.attach = function () {
+ var buttons = this;
+
+ this.$reuse.on( 'click.mmv-canvasButtons', function ( e ) {
+ $( document ).trigger( 'mmv-reuse-open', e );
+ e.stopPropagation(); // the dialog would take it as an outside click and close
+ } );
+ this.handleEvent( 'mmv-reuse-opened', function () {
+ buttons.$reuse.addClass( 'open' );
+ } );
+ this.handleEvent( 'mmv-reuse-closed', function () {
+ buttons.$reuse.removeClass( 'open' );
+ } );
+
+ this.$download.on( 'click.mmv-canvasButtons', function ( e ) {
+ $( document ).trigger( 'mmv-download-open', e );
+ e.stopPropagation();
+ } );
+ this.handleEvent( 'mmv-download-opened', function () {
+ buttons.$download.addClass( 'open' );
+ } );
+ this.handleEvent( 'mmv-download-closed', function () {
+ buttons.$download.removeClass( 'open' );
+ } );
+
+ this.$options.on( 'click.mmv-canvasButtons', function ( e ) {
+ $( document ).trigger( 'mmv-options-open', e );
+ e.stopPropagation();
+ } );
+ this.handleEvent( 'mmv-options-opened', function () {
+ buttons.$options.addClass( 'open' );
+ } );
+ this.handleEvent( 'mmv-options-closed', function () {
+ buttons.$options.removeClass( 'open' );
+ } );
+
+ this.$download
+ .add( this.$reuse )
+ .add( this.$options )
+ .add( this.$close )
+ .add( this.$fullscreen )
+ .each( function () {
+ $( this ).tipsy( 'enable' );
+ } );
+ };
+
+ /**
+ * Removes all UI things from the DOM, or hides them
+ */
+ CBP.unattach = function () {
+ this.$download
+ .add( this.$reuse )
+ .add( this.$options )
+ .add( this.$close )
+ .add( this.$fullscreen )
+ .off( 'click.mmv-canvasButtons' )
+ .each( function () {
+ $( this ).tipsy( 'hide' ).tipsy( 'disable' );
+ } );
+ };
+
+ CBP.empty = function () {
+ this.$reuse.removeClass( 'open' );
+ };
+
+ mw.mmv.ui.CanvasButtons = CanvasButtons;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.less
new file mode 100644
index 00000000..bd73beb4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.canvasButtons.less
@@ -0,0 +1,142 @@
+@import '../mmv.globals';
+@import '../mmv.mixins';
+
+.mw-mmv-download-button,
+.mw-mmv-reuse-button,
+.mw-mmv-options-button,
+.mw-mmv-close,
+.mw-mmv-fullscreen,
+.mw-mmv-next-image,
+.mw-mmv-prev-image {
+ cursor: pointer;
+ position: fixed;
+ background-color: transparent;
+ background-repeat: no-repeat;
+ .opacity( 0.8 );
+ border: 0;
+ z-index: 1003;
+
+ &.mw-mmv-dialog-open,
+ &:hover {
+ .opacity( 1 );
+ }
+
+ .unselectable;
+}
+
+.mw-mmv-download-button.hidden,
+.mw-mmv-reuse-button.hidden,
+.mw-mmv-options-button.hidden,
+.mw-mmv-close.hidden,
+.mw-mmv-fullscreen.hidden,
+.mw-mmv-next-image.hidden,
+.mw-mmv-prev-image.hidden {
+ display: none;
+}
+
+.cursor-hidden {
+ .mw-mmv-download-button,
+ .mw-mmv-reuse-button,
+ .mw-mmv-close,
+ .mw-mmv-fullscreen,
+ .mw-mmv-next-image,
+ .mw-mmv-prev-image {
+ cursor: none;
+ }
+}
+
+.mw-mmv-download-button,
+.mw-mmv-reuse-button,
+.mw-mmv-options-button,
+.mw-mmv-close,
+.mw-mmv-fullscreen {
+ right: @buttons-offset-right;
+ left: auto;
+ transition: opacity 0.25s;
+ background-position: center;
+ margin-top: 14px;
+ margin-right: 14px;
+}
+
+.mw-mmv-next-image,
+.mw-mmv-prev-image {
+ top: -999px;
+ width: 80px;
+ height: 120px;
+ transition: opacity 0.25s, margin 0.25s;
+
+ &.disabled {
+ display: none;
+ cursor: none;
+ }
+}
+
+.mw-mmv-close {
+ top: @buttons-offset-right;
+ /* @embed */
+ background-image: url( img/mw-close.svg );
+ height: 23px;
+ width: 23px;
+}
+
+.mw-mmv-fullscreen {
+ top: ( @buttons-offset-right + ( @buttons-offset-each-top ) );
+ /* @embed */
+ background-image: url( img/mw-fullscreen-ltr.svg );
+ width: 21px;
+ height: 22px;
+}
+
+.mw-mmv-options-button {
+ top: ( @buttons-offset-right + ( 2 * @buttons-offset-each-top ) );
+ /* @embed */
+ background-image: url( img/gear.svg );
+ height: 23px;
+ width: 23px;
+}
+
+.jq-fullscreened {
+ .mw-mmv-fullscreen {
+ /* @embed */
+ background-image: url( img/mw-defullscreen-ltr.svg );
+ }
+}
+
+.mw-mmv-next-image {
+ /* @embed */
+ background-image: url( img/next-ltr.svg );
+ background-position: right;
+ right: @navbutton-width;
+
+ &:hover {
+ margin-right: -4px;
+ }
+}
+
+.mw-mmv-prev-image {
+ /* @embed */
+ background-image: url( img/prev-ltr.svg );
+ background-position: left;
+ left: @navbutton-width;
+
+ &:hover {
+ margin-left: -4px;
+ }
+}
+
+.mw-mmv-reuse-button {
+ right: @buttons-offset-right - 2px;
+ bottom: @buttons-offset-right + @metadatabar-above-fold-height + @progress-bar-height;
+ /* @embed */
+ background-image: url( img/use-ltr.svg );
+ height: 24px;
+ width: 24px;
+}
+
+.mw-mmv-download-button {
+ bottom: @buttons-offset-right + @metadatabar-above-fold-height + @progress-bar-height + 37px;
+ /* @embed */
+ background-image: url( img/mw-download.svg );
+ height: 24px;
+ width: 24px;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.description.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.description.js
new file mode 100644
index 00000000..558877c8
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.description.js
@@ -0,0 +1,69 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ /**
+ * Description element in the UI.
+ *
+ * @class mw.mmv.ui.Description
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @inheritdoc
+ */
+ function Description( $container ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+
+ this.$imageDescDiv = $( '<div>' )
+ .addClass( 'mw-mmv-image-desc-div empty' )
+ .appendTo( this.$container );
+
+ this.$imageDesc = $( '<p>' )
+ .addClass( 'mw-mmv-image-desc' )
+ .appendTo( this.$imageDescDiv );
+ }
+
+ oo.inheritClass( Description, mw.mmv.ui.Element );
+
+ /**
+ * Sets data on the element.
+ * This complements MetadataPanel.setTitle() - information shown there will not be shown here.
+ *
+ * @param {string|null} description The text of the description
+ * @param {string|null} caption The text of the caption
+ */
+ Description.prototype.set = function ( description, caption ) {
+ if ( caption && description ) { // panel header shows the caption - show description here
+ this.$imageDesc.html( this.htmlUtils.htmlToTextWithTags( description ) );
+ this.$imageDescDiv.removeClass( 'empty' );
+ } else { // either there is no description or the paner header already shows it - nothing to do here
+ this.empty();
+ }
+ };
+
+ /**
+ * @inheritdoc
+ */
+ Description.prototype.empty = function () {
+ this.$imageDesc.empty();
+ this.$imageDescDiv.addClass( 'empty' );
+ };
+
+ mw.mmv.ui.Description = Description;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.js
new file mode 100644
index 00000000..6738b50b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.js
@@ -0,0 +1,258 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var DP;
+
+ /**
+ * Represents a dialog and the link to open it.
+ *
+ * @class mw.mmv.ui.Dialog
+ * @extends mw.mmv.ui.Element
+ * @param {jQuery} $container the element to which the dialog will be appended
+ * @param {jQuery} $openButton the button which opens the dialog. Only used for positioning.
+ * @param {mw.mmv.Config} config
+ */
+ function Dialog( $container, $openButton, config ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ /** @property {boolean} isOpen Whether or not the dialog is open. */
+ this.isOpen = false;
+
+ /**
+ * @property {string[]} loadDependencies Dependencies to load before showing the dialog.
+ */
+ this.loadDependencies = [];
+
+ /**
+ * @property {string} eventPrefix Prefix specific to the class to be applied to events.
+ */
+ this.eventPrefix = '';
+ /** @property {mw.mmv.Config} config - */
+ this.config = config;
+
+ /** @property {jQuery} $openButton The click target which opens the dialog. */
+ this.$openButton = $openButton;
+
+ /** @type {jQuery} $dialog The main dialog container */
+ this.$dialog = $( '<div>' )
+ .addClass( 'mw-mmv-dialog' );
+
+ /**
+ * @property {jQuery} $downArrow Tip of the dialog pointing to $openButton. Called
+ * downArrow for historical reasons although it does not point down anymore.
+ */
+ this.$downArrow = $( '<div>' )
+ .addClass( 'mw-mmv-dialog-down-arrow' )
+ .appendTo( this.$dialog );
+
+ this.initWarning();
+
+ this.$dialog.appendTo( this.$container );
+ }
+
+ oo.inheritClass( Dialog, mw.mmv.ui.Element );
+ DP = Dialog.prototype;
+
+ /**
+ * Creates the DOM element that setWarning()/clearWarning() will operate on.
+ * @private
+ */
+ DP.initWarning = function () {
+ this.$warning = $( '<div>' )
+ .addClass( 'mw-mmv-dialog-warning' )
+ .hide()
+ .click( function ( e ) {
+ // prevent other click handlers such as the download CTA from intercepting clicks at the warning
+ e.stopPropagation();
+ } )
+ .appendTo( this.$dialog );
+ };
+
+ /**
+ * Handles click on link that opens/closes the dialog.
+ *
+ * @param {jQuery.Event} openEvent Event object for the mmv-$dialog-open event.
+ * @param {jQuery.Event} e Event object for the click event.
+ * @return {boolean} False to cancel the default event
+ */
+ DP.handleOpenCloseClick = function ( openEvent, e ) {
+ var dialog = this;
+
+ mw.loader.using( this.loadDependencies, function () {
+ dialog.dependenciesLoaded = true;
+ dialog.toggleDialog( e );
+ }, function ( error ) {
+ if ( window.console && window.console.error ) {
+ window.console.error( 'mw.loader.using error when trying to load dialog dependencies', error );
+ }
+ } );
+
+ return false;
+ };
+
+ /**
+ * Toggles the open state on the dialog.
+ *
+ * @param {jQuery.Event} [e] Event object when the close action is caused by a user
+ * action, as opposed to closing the window or something.
+ */
+ DP.toggleDialog = function ( e ) {
+ if ( this.isOpen ) {
+ this.closeDialog( e );
+ } else {
+ this.openDialog();
+ }
+ };
+
+ /**
+ * Opens a dialog.
+ */
+ DP.openDialog = function () {
+ mw.mmv.actionLogger.log( this.eventPrefix + '-open' );
+
+ this.startListeningToOutsideClick();
+ this.$dialog.show();
+ this.isOpen = true;
+ this.$openButton.addClass( 'mw-mmv-dialog-open' );
+ };
+
+ /**
+ * Closes a dialog.
+ */
+ DP.closeDialog = function () {
+ if ( this.isOpen ) {
+ mw.mmv.actionLogger.log( this.eventPrefix + '-close' );
+ }
+
+ this.stopListeningToOutsideClick();
+ this.$dialog.hide();
+ this.isOpen = false;
+ this.$openButton.removeClass( 'mw-mmv-dialog-open' );
+ };
+
+ /**
+ * Sets up the event handler which closes the dialog when the user clicks outside.
+ */
+ DP.startListeningToOutsideClick = function () {
+ var dialog = this;
+
+ this.outsideClickHandler = this.outsideClickHandler || function ( e ) {
+ var $clickTarget = $( e.target );
+
+ // Don't close the dialog if the click inside a dialog or on an navigation arrow
+ if (
+ $clickTarget.closest( dialog.$dialog ).length ||
+ $clickTarget.closest( '.mw-mmv-next-image' ).length ||
+ $clickTarget.closest( '.mw-mmv-prev-image' ).length ||
+ e.which === 3
+ ) {
+ return;
+ }
+
+ dialog.closeDialog();
+ return false;
+ };
+ $( document ).on( 'click.mmv.' + this.eventPrefix, this.outsideClickHandler );
+ };
+
+ /**
+ * Removes the event handler set up by startListeningToOutsideClick().
+ */
+ DP.stopListeningToOutsideClick = function () {
+ $( document ).off( 'click.mmv.' + this.eventPrefix, this.outsideClickHandler );
+ };
+
+ /**
+ * Clears listeners.
+ */
+ DP.unattach = function () {
+ mw.mmv.ui.Element.prototype.unattach.call( this );
+
+ this.stopListeningToOutsideClick();
+ };
+
+ /**
+ * @inheritdoc
+ */
+ DP.empty = function () {
+ this.closeDialog();
+ this.clearWarning();
+ };
+
+ /**
+ * Displays a warning ribbon.
+ * @param {string} content Content of the warning (can be HTML,
+ * setWarning does no escaping).
+ */
+ DP.setWarning = function ( content ) {
+ this.$warning
+ .empty()
+ .append( content )
+ .show();
+ this.$dialog.addClass( 'mw-mmv-warning-visible' );
+ };
+
+ /**
+ * Removes the warning ribbon.
+ */
+ DP.clearWarning = function () {
+ this.$warning.hide();
+ this.$dialog.removeClass( 'mw-mmv-warning-visible' );
+ };
+
+ /**
+ * @param {mw.mmv.model.Image} image
+ * @return {string[]}
+ */
+ DP.getImageWarnings = function ( image ) {
+ var warnings = [];
+
+ if ( image.deletionReason ) {
+ warnings.push( mw.message( 'multimediaviewer-reuse-warning-deletion' ).plain() );
+ // Don't inform about other warnings (they may be the cause of the deletion)
+ return warnings;
+ }
+
+ if ( !image.license || image.license.needsAttribution() && !image.author && !image.attribution ) {
+ warnings.push( mw.message( 'multimediaviewer-reuse-warning-noattribution' ).plain() );
+ }
+
+ if ( image.license && !image.license.isFree() ) {
+ warnings.push( mw.message( 'multimediaviewer-reuse-warning-nonfree' ).plain() );
+ }
+
+ return warnings;
+ };
+
+ /**
+ * @param {mw.mmv.model.Image} image
+ */
+ DP.showImageWarnings = function ( image ) {
+ var warnings = this.getImageWarnings( image );
+
+ if ( warnings.length > 0 ) {
+ warnings.push( mw.message( 'multimediaviewer-reuse-warning-generic', image.descriptionUrl ).parse() );
+ this.setWarning( warnings.join( '<br />' ) );
+ } else {
+ this.clearWarning();
+ }
+ };
+
+ mw.mmv.ui.Dialog = Dialog;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.less
new file mode 100644
index 00000000..cccbfac3
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.dialog.less
@@ -0,0 +1,45 @@
+@import '../mmv.mixins';
+@import '../mmv.globals';
+
+@background-color: #fff;
+@dialog-width: 450px;
+@box-shadow-dialog: 0 2px 2px 0 darken( @background-color, 33.3% );
+
+.mw-mmv-dialog {
+ position: fixed;
+ right: 58px;
+ display: none;
+ width: @dialog-width;
+ height: @dialog-height;
+ background-color: @background-color;
+ box-shadow: @box-shadow-dialog;
+ border-radius: @border-radius;
+ z-index: 1004;
+
+ .mw-mmv-dialog-down-arrow {
+ right: 48px;
+ background-color: @background-color;
+ width: @arrow-size;
+ height: @arrow-size;
+ .rotate( -45deg );
+ position: fixed;
+ }
+
+ .mw-mmv-dialog-copy {
+ /* @embed */
+ background-image: url( img/pasting.svg );
+ background-size: contain;
+ background-position: right center;
+ background-repeat: no-repeat;
+
+ &:hover {
+ /* @embed */
+ background-image: url( img/pasting-hover.svg );
+ text-decoration: none;
+ }
+ }
+
+ .mw-mmv-dialog-warning {
+ background-color: @dialog-warning-color;
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.js
new file mode 100644
index 00000000..d0c1847d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.js
@@ -0,0 +1,128 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var DP;
+
+ /**
+ * Represents the file download dialog and the link to open it.
+ *
+ * @class mw.mmv.ui.download.Dialog
+ * @extends mw.mmv.ui.Dialog
+ * @param {jQuery} $container the element to which the dialog will be appended
+ * @param {jQuery} $openButton the button which opens the dialog. Only used for positioning.
+ * @param {mw.mmv.Config} config
+ */
+ function Dialog( $container, $openButton, config ) {
+ mw.mmv.ui.Dialog.call( this, $container, $openButton, config );
+
+ this.loadDependencies.push( 'mmv.ui.download.pane' );
+
+ this.$dialog.addClass( 'mw-mmv-download-dialog' );
+
+ this.eventPrefix = 'download';
+ }
+
+ oo.inheritClass( Dialog, mw.mmv.ui.Dialog );
+ DP = Dialog.prototype;
+
+ /**
+ * Registers listeners.
+ */
+ DP.attach = function () {
+ var dialog = this;
+
+ this.handleEvent( 'mmv-download-open', $.proxy( this.handleOpenCloseClick, this ) );
+
+ this.handleEvent( 'mmv-reuse-open', $.proxy( this.closeDialog, this ) );
+ this.handleEvent( 'mmv-options-open', $.proxy( this.closeDialog, this ) );
+
+ this.$container.on( 'mmv-download-cta-open', function () {
+ dialog.$warning.hide();
+ } );
+ this.$container.on( 'mmv-download-cta-close', function () {
+ if ( dialog.$dialog.hasClass( 'mw-mmv-warning-visible' ) ) {
+ dialog.$warning.show();
+ }
+ } );
+ };
+
+ /**
+ * Clears listeners.
+ */
+ DP.unattach = function () {
+ this.$container.off( 'mmv-download-cta-open mmv-download-cta-close' );
+ };
+
+ /**
+ * Sets data needed by contaned tabs and makes dialog launch link visible.
+ *
+ * @param {mw.mmv.model.Image} image
+ * @param {mw.mmv.model.Repo} repo
+ */
+ DP.set = function ( image, repo ) {
+ if ( this.download ) {
+ this.download.set( image, repo );
+ this.showImageWarnings( image );
+ } else {
+ this.setValues = {
+ image: image,
+ repo: repo
+ };
+ }
+ };
+
+ /**
+ * @event mmv-download-opened
+ * Fired when the dialog is opened.
+ */
+ /**
+ * Opens a dialog with information about file download.
+ */
+ DP.openDialog = function () {
+ if ( !this.download ) {
+ this.download = new mw.mmv.ui.download.Pane( this.$dialog );
+ this.download.attach();
+ }
+
+ if ( this.setValues ) {
+ this.download.set( this.setValues.image, this.setValues.repo );
+ this.showImageWarnings( this.setValues.image );
+ this.setValues = undefined;
+ }
+
+ mw.mmv.ui.Dialog.prototype.openDialog.call( this );
+
+ $( document ).trigger( 'mmv-download-opened' );
+ };
+
+ /**
+ * @event mmv-download-closed
+ * Fired when the dialog is closed.
+ */
+ /**
+ * Closes the download dialog.
+ */
+ DP.closeDialog = function () {
+ mw.mmv.ui.Dialog.prototype.closeDialog.call( this );
+
+ $( document ).trigger( 'mmv-download-closed' );
+ };
+
+ mw.mmv.ui.download.Dialog = Dialog;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.less
new file mode 100644
index 00000000..d4615a17
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.dialog.less
@@ -0,0 +1,34 @@
+@import '../mmv.mixins';
+@import '../mmv.globals';
+
+.mw-mmv-download-dialog {
+ // resetting height (to overwrite .mw-mmv-dialog's bigger height), since the
+ // height may have to change for warnings being added
+ height: initial;
+ // positioned relative to the download button
+ position: fixed;
+ bottom: @metadatabar-above-fold-height + @progress-bar-height + 35px;
+
+ .mw-mmv-download-size .oo-ui-optionWidget {
+ display: inline-block;
+ padding: 10px 25px;
+ font-size: 16px;
+
+ &.oo-ui-optionWidget-selected {
+ border: 0;
+ }
+
+ &:first-child {
+ border-radius: @border-radius 0 0 0;
+ }
+ }
+
+ .mw-mmv-dialog-down-arrow {
+ bottom: @metadatabar-above-fold-height + @progress-bar-height + 45px;
+ background-color: #f8f9fa;
+ }
+
+ .mw-mmv-dialog-warning {
+ padding: 10px 30px;
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.js
new file mode 100644
index 00000000..58c5d269
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.js
@@ -0,0 +1,20 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ mw.mmv.ui.download = {};
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.js
new file mode 100644
index 00000000..560695bc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.js
@@ -0,0 +1,429 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var DP;
+
+ /**
+ * UI component that provides functionality to download the media asset displayed.
+ *
+ * @class mw.mmv.ui.download.Pane
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container
+ */
+ function Pane( $container ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ /** @property {mw.mmv.ui.Utils} utils - */
+ this.utils = new mw.mmv.ui.Utils();
+
+ this.$pane = $( '<div>' )
+ .addClass( 'mw-mmv-download-pane' )
+ .appendTo( this.$container );
+
+ this.$downloadArea = $( '<div>' )
+ .addClass( 'mw-mmv-download-area' )
+ .appendTo( this.$pane );
+
+ this.createDownloadButton( this.$downloadArea );
+ this.createSizePulldownMenu( this.$downloadArea );
+ this.createPreviewLink( this.$downloadArea );
+
+ this.formatter = new mw.mmv.EmbedFileFormatter();
+ this.currentAttrView = 'plain';
+ this.createAttributionButton( this.$pane );
+
+ /**
+ * Default item for the size menu.
+ * @property {OO.ui.MenuOptionWidget}
+ */
+ this.defaultItem = this.downloadSizeMenu.getMenu().findSelectedItem();
+
+ /** @property {mw.mmv.model.Image|null} Image the download button currently points to. */
+ this.image = null;
+ }
+ oo.inheritClass( Pane, mw.mmv.ui.Element );
+ DP = Pane.prototype;
+
+ /**
+ * @event mmv-download-cta-open
+ * Fired when the attribution call to action panel is clicked.
+ */
+ /**
+ * @event mmv-download-cta-close
+ * Fired when the attribution area is closed.
+ */
+
+ /**
+ * Creates download split button. It is a link with the "download" property set plus an
+ * arrow that allows the user to select the image size desired. The "download" property
+ * triggers native browser downloading in browsers that support it. The fallback is the
+ * 'download' parameter which instructs the server to send the right headers so the browser
+ * downloads the file instead of just displaying it. If all this fails, the image will appear
+ * in another window/tab.
+ *
+ * @param {jQuery} $container
+ */
+ DP.createDownloadButton = function ( $container ) {
+ // TODO: Use OOUI progressive button widget instead
+ this.$downloadButton = $( '<a>' )
+ .attr( 'target', '_blank' )
+ .attr( 'download', '' )
+ .addClass( 'mw-ui-button mw-ui-progressive mw-mmv-download-go-button' )
+ .click( function () {
+ mw.mmv.actionLogger.log( 'download' );
+ } );
+
+ this.$selectionArrow = $( '<span>' )
+ .addClass( 'mw-ui-button mw-ui-progressive mw-mmv-download-select-menu' )
+ .append(
+ $( '<span>' )
+ .addClass( 'mw-mmv-download-image-size-name' )
+ .html( '&nbsp;' )
+ )
+ .append(
+ $( '<span>' )
+ .addClass( 'mw-mmv-download-image-size' )
+ .html( '&nbsp;' )
+ );
+
+ $container
+ .append( this.$downloadButton )
+ .append( this.$selectionArrow );
+ };
+
+ /**
+ * Creates pulldown menu to select image sizes.
+ *
+ * @param {jQuery} $container
+ */
+ DP.createSizePulldownMenu = function ( $container ) {
+ this.downloadSizeMenu = this.utils.createPulldownMenu(
+ [ 'original', 'small', 'medium', 'large' ],
+ [ 'mw-mmv-download-size' ],
+ 'original'
+ );
+
+ this.downloadSizeMenu.getMenu().on( 'select', function ( item ) {
+ mw.mmv.actionLogger.log( 'download-select-menu-' + item.data.name );
+ } );
+
+ $container.append( this.downloadSizeMenu.$element );
+ };
+
+ /**
+ * Creates preview link.
+ *
+ * @param {jQuery} $container
+ */
+ DP.createPreviewLink = function ( $container ) {
+ this.$previewLink = $( '<a>' )
+ .attr( 'target', '_blank' )
+ .addClass( 'mw-mmv-download-preview-link' )
+ .text( mw.message( 'multimediaviewer-download-preview-link-title' ).text() )
+ .appendTo( $container )
+ .click( function () {
+ mw.mmv.actionLogger.log( 'download-view-in-browser' );
+ } );
+ };
+
+ DP.createAttributionButton = function ( $container ) {
+ var dl = this,
+ attributionInput = new oo.ui.TextInputWidget( {
+ classes: [ 'mw-mmv-download-attr-input' ],
+ readOnly: true
+ } ),
+ attributionSwitch = new oo.ui.ButtonSelectWidget( {
+ classes: [ 'mw-mmv-download-attr-select' ]
+ } ),
+ plainOption = new oo.ui.ButtonOptionWidget( {
+ data: 'plain',
+ label: mw.message( 'multimediaviewer-attr-plain' ).text()
+ } ),
+ htmlOption = new oo.ui.ButtonOptionWidget( {
+ data: 'html',
+ label: mw.message( 'multimediaviewer-attr-html' ).text()
+ } );
+
+ attributionSwitch.addItems( [
+ plainOption,
+ htmlOption
+ ] );
+
+ attributionSwitch.selectItem( plainOption );
+
+ attributionSwitch.on( 'select', function ( selection ) {
+ dl.selectAttribution( selection.getData() );
+
+ dl.attributionInput.$element.find( 'input' ).focus();
+ } );
+
+ this.$attributionSection = $( '<div>' )
+ .addClass( 'mw-mmv-download-attribution mw-mmv-download-attribution-collapsed' )
+ .appendTo( $container )
+ .click( function () {
+ if ( dl.$attributionSection.hasClass( 'mw-mmv-download-attribution-collapsed' ) ) {
+ dl.$container.trigger( 'mmv-download-cta-open' );
+ dl.$attributionSection.removeClass( 'mw-mmv-download-attribution-collapsed' );
+ dl.attributionInput.$element.find( 'input' ).focus();
+ }
+ } );
+
+ this.$attributionCtaHeader = $( '<p>' )
+ .addClass( 'mw-mmv-download-attribution-cta-header' )
+ .text( mw.message( 'multimediaviewer-download-attribution-cta-header' ).text() );
+ this.$attributionCta = $( '<div>' )
+ .addClass( 'mw-mmv-download-attribution-cta' )
+ .append(
+ this.$attributionCtaHeader,
+ $( '<p>' )
+ .addClass( 'mw-mmv-download-attribution-cta-invite' )
+ .text( mw.message( 'multimediaviewer-download-attribution-cta' ).text() )
+ )
+ .appendTo( this.$attributionSection );
+ this.attributionInput = attributionInput;
+ this.$attributionCopy = this.$copyButton = $( '<button>' )
+ .addClass( 'mw-ui-button mw-mmv-button mw-mmv-dialog-copy' )
+ .click( function () {
+ // Select the text, and then try to copy the text.
+ // If the copy fails or is not supported, continue as if nothing had happened.
+ dl.attributionInput.select();
+ try {
+ if ( document.queryCommandSupported &&
+ document.queryCommandSupported( 'copy' ) ) {
+ document.execCommand( 'copy' );
+ }
+ } catch ( e ) {
+ // queryCommandSupported in Firefox pre-41 can throw errors when used with
+ // clipboard commands. We catch and ignore these and other copy-command-related
+ // errors here.
+ }
+ } )
+ .prop( 'title', mw.msg( 'multimediaviewer-download-attribution-copy' ) )
+ .text( mw.msg( 'multimediaviewer-download-attribution-copy' ) )
+ .tipsy( {
+ delayIn: mw.config.get( 'wgMultimediaViewer' ).tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } );
+
+ this.$attributionHowHeader = $( '<p>' )
+ .addClass( 'mw-mmv-download-attribution-how-header' )
+ .text( mw.message( 'multimediaviewer-download-attribution-cta-header' ).text() );
+ this.$attributionHow = $( '<div>' )
+ .addClass( 'mw-mmv-download-attribution-how' )
+ .append(
+ this.$attributionHowHeader,
+ this.attributionInput.$element,
+ this.$attributionCopy,
+ attributionSwitch.$element,
+ $( '<p>' )
+ .addClass( 'mw-mmv-download-attribution-close-button' )
+ .click( function ( e ) {
+ dl.$container.trigger( 'mmv-download-cta-close' );
+ dl.$attributionSection.addClass( 'mw-mmv-download-attribution-collapsed' );
+ e.stopPropagation();
+ } )
+ .text( ' ' )
+ )
+ .appendTo( this.$attributionSection );
+ };
+
+ /**
+ * Selects the specified attribution type.
+ *
+ * @param {string} [name='plain'] The attribution type to use ('plain' or 'html')
+ */
+ DP.selectAttribution = function ( name ) {
+ this.currentAttrView = name;
+
+ if ( this.currentAttrView === 'html' ) {
+ this.attributionInput.setValue( this.htmlCredit );
+ } else {
+ this.attributionInput.setValue( this.textCredit );
+ }
+ };
+
+ /**
+ * Registers listeners.
+ */
+ DP.attach = function () {
+ var download = this;
+
+ // Register handlers for switching between file sizes
+ this.downloadSizeMenu.getMenu().on( 'choose', function ( item ) {
+ download.handleSizeSwitch( item );
+ } );
+ this.$selectionArrow.on( 'click', function () {
+ download.downloadSizeMenu.getMenu().toggle();
+ } );
+
+ this.attributionInput.$element.find( 'input' )
+ .on( 'focus', this.selectAllOnEvent )
+ .on( 'mousedown click', this.onlyFocus );
+ };
+
+ /**
+ * Clears listeners.
+ */
+ DP.unattach = function () {
+ mw.mmv.ui.Element.prototype.unattach.call( this );
+
+ this.downloadSizeMenu.getMenu().off( 'choose' );
+ this.$selectionArrow.off( 'click' );
+
+ this.attributionInput.$element.find( 'input' )
+ .off( 'focus mousedown click' );
+ };
+
+ /**
+ * Handles size menu change events.
+ *
+ * @param {OO.ui.MenuOptionWidget} item
+ */
+ DP.handleSizeSwitch = function ( item ) {
+ var download = this,
+ value = item.getData();
+
+ if ( value.name === 'original' && this.image !== null ) {
+ this.setDownloadUrl( this.image.url );
+ this.setButtonText( value.name, this.getExtensionFromUrl( this.image.url ),
+ value.width, value.height );
+ } else {
+ // Disable download while we get the image
+ this.$downloadButton.addClass( 'disabledLink' );
+ // Set a temporary message. It will be updated once we have the file type.
+ this.setButtonText( value.name, this.imageExtension, value.width, value.height );
+
+ this.utils.getThumbnailUrlPromise( value.width ).done( function ( thumbnail ) {
+ download.setDownloadUrl( thumbnail.url );
+ download.setButtonText( value.name, download.getExtensionFromUrl( thumbnail.url ),
+ value.width, value.height );
+ } );
+ }
+ };
+
+ /**
+ * Sets the URL on the download button.
+ *
+ * @param {string} url
+ */
+ DP.setDownloadUrl = function ( url ) {
+ this.$downloadButton.attr( 'href', url + '?download' );
+ this.$previewLink.attr( 'href', url );
+
+ // Re-enable download
+ this.$downloadButton.removeClass( 'disabledLink' );
+ };
+
+ /**
+ * Sets the text of the download button.
+ *
+ * @param {string} sizeClass A size class such as 'small'
+ * @param {string} extension file extension
+ * @param {number} width
+ * @param {number} height
+ */
+ DP.setButtonText = function ( sizeClass, extension, width, height ) {
+ var sizeClasMessage, sizeMessage, dimensionMessage;
+
+ sizeClasMessage = mw.message( 'multimediaviewer-download-' + sizeClass + '-button-name' ).text();
+ dimensionMessage = mw.message( 'multimediaviewer-embed-dimensions', width, height ).text();
+ sizeMessage = mw.message( 'multimediaviewer-embed-dimensions-with-file-format',
+ dimensionMessage, extension ).text();
+
+ // Update button label and size strings to reflect new selected size
+ this.$downloadButton.html(
+ '<span class="mw-mmv-download-image-size-name">' + sizeClasMessage + '</span>' +
+ '<span class="mw-mmv-download-image-size">' + sizeMessage + '</span>'
+ );
+ };
+
+ /**
+ * Sets the text in the attribution input element.
+ *
+ * @param {mw.mmv.model.EmbedFileInfo} embed
+ */
+ DP.setAttributionText = function ( embed ) {
+ this.htmlCredit = this.formatter.getCreditHtml( embed );
+ this.textCredit = this.formatter.getCreditText( embed );
+ this.selectAttribution( this.currentAttrView );
+ };
+
+ /**
+ * Chops off the extension part of an URL.
+ *
+ * @param {string} url URL
+ * @return {string} Extension
+ */
+ DP.getExtensionFromUrl = function ( url ) {
+ var urlParts = url.split( '.' );
+ return urlParts[ urlParts.length - 1 ];
+ };
+
+ /**
+ * Sets the data on the element.
+ *
+ * @param {mw.mmv.model.Image} image
+ * @param {mw.mmv.model.Repo} repo
+ */
+ DP.set = function ( image, repo ) {
+ var attributionCtaMessage,
+ license = image && image.license,
+ sizeOptions = this.downloadSizeMenu.getMenu().getItems(),
+ sizes = this.utils.getPossibleImageSizesForHtml( image.width, image.height );
+
+ this.image = image;
+
+ this.utils.updateMenuOptions( sizes, sizeOptions );
+
+ this.downloadSizeMenu.$element.addClass( 'active' );
+
+ // Note: This extension will not be the real one for file types other than: png/gif/jpg/jpeg
+ this.imageExtension = image.title.getExtension().toLowerCase();
+
+ // Reset size menu to default item and update download button label now that we have the info
+ this.downloadSizeMenu.getMenu().chooseItem( this.defaultItem );
+
+ if ( image && repo ) {
+ this.setAttributionText( new mw.mmv.model.EmbedFileInfo( image, repo ) );
+ }
+
+ attributionCtaMessage = ( license && license.needsAttribution() ) ?
+ 'multimediaviewer-download-attribution-cta-header' :
+ 'multimediaviewer-download-optional-attribution-cta-header';
+ this.$attributionCtaHeader.text( mw.message( attributionCtaMessage ).text() );
+ this.$attributionHowHeader.text( mw.message( attributionCtaMessage ).text() );
+ };
+
+ /**
+ * @inheritdoc
+ */
+ DP.empty = function () {
+ this.downloadSizeMenu.getMenu().toggle( false );
+ this.downloadSizeMenu.$element.removeClass( 'active' );
+
+ this.$downloadButton.attr( 'href', '' );
+ this.$previewLink.attr( 'href', '' );
+ this.imageExtension = undefined;
+
+ this.image = null;
+ };
+
+ mw.mmv.ui.download.Pane = Pane;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.less
new file mode 100644
index 00000000..85874556
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.download.pane.less
@@ -0,0 +1,206 @@
+@import 'mediawiki.ui/variables';
+@import '../mmv.mixins';
+
+@pane-padding: 10px;
+@attribution-color: #f8f9fa;
+@attribution-color-highlighted: #fff;
+@attribution-logo-size: 40px;
+@input-text-color: #222;
+
+.mw-mmv-download-pane {
+ padding: 0 @pane-padding;
+ position: relative;
+ height: 100%;
+
+ /* Disable link clicks */
+ a.disabledLink {
+ pointer-events: none;
+ cursor: default;
+ }
+
+ .mw-mmv-download-area {
+ padding-top: 20px;
+ padding-left: 10px;
+ padding-bottom: 60px;
+ width: 100%;
+
+ .mw-mmv-download-go-button {
+ border-top-right-radius: 0;
+ border-bottom-right-radius: 0;
+ }
+
+ /* Selection size arrow element */
+ .mw-mmv-download-select-menu {
+ .unselectable();
+ background-image: /* @embed */ url( ../img/down.svg );
+ background-position: center center;
+ background-repeat: no-repeat;
+ min-width: 10px;
+ border-top-left-radius: 0;
+ border-bottom-left-radius: 0;
+ border-left: 1px solid mix( #000, @colorProgressive, 20% );
+
+ &:hover {
+ border-bottom: 1px solid mix( #000, @colorProgressive, 20% );
+ }
+ }
+
+ .mw-mmv-download-image-size-name {
+ display: block;
+ }
+
+ .mw-mmv-download-image-size {
+ display: block;
+ font-size: small;
+ font-weight: normal;
+ }
+
+ .mw-mmv-download-preview-link {
+ display: inline-block;
+ margin-top: 12px;
+ margin-left: -6px;
+ font-size: 16px;
+ color: #54595d;
+
+ &:before {
+ display: inline-block;
+ vertical-align: middle;
+ content: ' ';
+ width: 44px;
+ height: 30px;
+ /* @embed */
+ background-image: url( img/open.svg );
+ background-size: contain;
+ background-position: right center;
+ background-repeat: no-repeat;
+ }
+ }
+
+ /* Pulldown size menu */
+ .mw-mmv-download-size {
+ text-align: start;
+ display: none;
+ margin-top: 0;
+ margin-right: 20px;
+ width: auto;
+
+ &.active {
+ display: block;
+ }
+
+ /* Changes to pulldown menu */
+ .oo-ui-dropdownWidget-handle {
+ display: none;
+ }
+
+ .oo-ui-menuOptionWidget {
+ display: block;
+ }
+
+ .oo-ui-widget-disabled {
+ display: none;
+ }
+
+ .oo-ui-labelElement-label {
+ margin-left: 20px;
+ }
+ }
+ }
+
+ .mw-mmv-download-attribution {
+ margin: 0 -@pane-padding;
+ padding: 0 @pane-padding @pane-padding;
+ background-color: @attribution-color;
+ color: #54595d;
+
+ &:hover {
+ background-color: @attribution-color-highlighted;
+ color: #222;
+ }
+
+ &-how {
+ position: relative;
+ display: block;
+ padding: 5px;
+ margin-bottom: 0;
+
+ .mw-mmv-download-attribution-close-button {
+ cursor: pointer;
+ position: absolute;
+ top: 5px;
+ right: 0;
+ width: 12px;
+ height: 12px;
+ /* @embed */
+ background-image: url( img/x_gray.svg );
+ }
+ }
+
+ &-how-header,
+ &-cta-header {
+ font-size: large;
+ font-weight: bold;
+ }
+
+ &-cta-header {
+ margin-bottom: 0;
+ }
+
+ &-cta-invite {
+ font-size: small;
+ margin: 0;
+ color: #72777d;
+ }
+
+ &-cta {
+ cursor: pointer;
+ display: none;
+ padding-left: @attribution-logo-size + 10px;
+
+ /* @embed */
+ background-image: url( img/user-ltr.svg );
+ background-repeat: no-repeat;
+ background-size: @attribution-logo-size;
+ background-position: left center;
+ }
+
+ &.mw-mmv-download-attribution-collapsed {
+ .mw-mmv-download-attribution-cta {
+ display: block;
+ }
+
+ .mw-mmv-download-attribution-how {
+ display: none;
+ }
+ }
+
+ .mw-mmv-download-attr-input {
+ // override OOUI fixed width
+ width: auto;
+
+ // margin between text widget and option switch widget
+ margin-bottom: 10px;
+
+ input[ readonly ] {
+ color: @input-text-color;
+ text-shadow: none;
+ }
+ }
+
+ .mw-mmv-dialog-copy {
+ // style rules based on .mw-mmv-share-page-link
+ float: right;
+ width: 1.5em;
+ height: 1.5em;
+
+ // position approximately to the middle - probably fragile but couldn't find a better way as
+ // the height of OOUI input widget has both em and px parts and not possible to calculate
+ // exactly
+ margin: 8px 0.5em 8px 0;
+ }
+ }
+}
+
+.mw-mmv-reuse-dialog.mw-mmv-reuse-download-active .mw-mmv-reuse-down-arrow {
+ background-color: @attribution-color;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.js
new file mode 100644
index 00000000..e498e803
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.js
@@ -0,0 +1,268 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var EP,
+ cachedRTL;
+
+ /**
+ * Represents a UI element.
+ *
+ * @class mw.mmv.ui.Element
+ * @abstract
+ * @constructor
+ * @param {jQuery} $container
+ */
+ function Element( $container ) {
+ oo.EventEmitter.call( this );
+
+ /** @property {jQuery} $container The element that contains the UI element. */
+ this.$container = $container;
+
+ /** @property {Object.<string, string[]>} eventsRegistered Events that this element has registered with the DOM. */
+ this.eventsRegistered = {};
+
+ /**
+ * @property {Object.<string, jQuery>} $inlineStyles a list of `<style>` elements in the head
+ * which we use to manipulate pseudo-classes and pseudo-elements.
+ */
+ this.$inlineStyles = [];
+
+ /**
+ * Stores named timeouts. See setTimer().
+ *
+ * @private
+ * @property {Object.<string, {timeout: Object, handler: function(), delay: number}>}
+ */
+ this.timers = {};
+ }
+
+ oo.mixinClass( Element, oo.EventEmitter );
+
+ EP = Element.prototype;
+
+ /**
+ * Checks whether the document is RTL. Assumes it doesn't change.
+ *
+ * @return {boolean}
+ */
+ EP.isRTL = function () {
+ if ( cachedRTL === undefined ) {
+ cachedRTL = $( document.body ).hasClass( 'rtl' );
+ }
+
+ return cachedRTL;
+ };
+
+ /**
+ * Sets the data for the element.
+ *
+ * @abstract
+ */
+ EP.set = function () {};
+
+ /**
+ * Empties the element.
+ *
+ * @abstract
+ */
+ EP.empty = function () {};
+
+ /**
+ * Registers listeners.
+ *
+ * @abstract
+ */
+ EP.attach = function () {};
+
+ /**
+ * Clears listeners.
+ *
+ * @abstract
+ */
+ EP.unattach = function () {
+ this.clearEvents();
+ };
+
+ /**
+ * Add event handler in a way that will be auto-cleared on lightbox close
+ *
+ * TODO: Unit tests
+ *
+ * @param {string} name Name of event, like 'keydown'
+ * @param {Function} handler Callback for the event
+ */
+ EP.handleEvent = function ( name, handler ) {
+ if ( this.eventsRegistered[ name ] === undefined ) {
+ this.eventsRegistered[ name ] = [];
+ }
+ this.eventsRegistered[ name ].push( handler );
+ $( document ).on( name, handler );
+ };
+
+ /**
+ * Remove all events that have been registered on this element.
+ *
+ * TODO: Unit tests
+ */
+ EP.clearEvents = function () {
+ var i, handlers, thisevent,
+ events = Object.keys( this.eventsRegistered );
+
+ for ( i = 0; i < events.length; i++ ) {
+ thisevent = events[ i ];
+ handlers = this.eventsRegistered[ thisevent ];
+ while ( handlers.length > 0 ) {
+ $( document ).off( thisevent, handlers.pop() );
+ }
+ }
+ };
+
+ /**
+ * Manipulate CSS directly. This is needed to set styles for pseudo-classes and pseudo-elements.
+ *
+ * @param {string} key some name to identify the style
+ * @param {string|null} style a CSS snippet (set to null to delete the given style)
+ */
+ EP.setInlineStyle = function ( key, style ) {
+
+ if ( !this.$inlineStyles ) {
+ this.$inlineStyles = [];
+ }
+
+ if ( !this.$inlineStyles[ key ] ) {
+ if ( !style ) {
+ return;
+ }
+
+ this.$inlineStyles[ key ] = $( '<style type="text/css" />' ).appendTo( 'head' );
+ }
+
+ this.$inlineStyles[ key ].html( style || '' );
+ };
+
+ /**
+ * Sets a timer. This is a shortcut to using the native setTimout and then storing
+ * the reference, with some small differences for convenience:
+ * - setting the same timer again clears the old one
+ * - callbacks have the element as their context
+ * Timers are local to the element.
+ * See also clearTimer() and resetTimer().
+ *
+ * @param {string} name
+ * @param {function()} callback
+ * @param {number} delay delay in milliseconds
+ */
+ EP.setTimer = function ( name, callback, delay ) {
+ var element = this;
+
+ this.clearTimer( name );
+ this.timers[ name ] = {
+ timeout: null,
+ handler: callback,
+ delay: delay
+ };
+ this.timers[ name ].timeout = setTimeout( function () {
+ delete element.timers[ name ];
+ callback.call( element );
+ }, delay );
+ };
+
+ /**
+ * Clears a timer. See setTimer().
+ *
+ * @param {string} name
+ */
+ EP.clearTimer = function ( name ) {
+ if ( name in this.timers ) {
+ clearTimeout( this.timers[ name ].timeout );
+ delete this.timers[ name ];
+ }
+ };
+
+ /**
+ * Resets a timer, so that its delay will be relative to when resetTimer() was called, not when
+ * the timer was created. Optionally changes the delay as well.
+ * Resetting a timer that does not exist or has already fired has no effect.
+ * See setTimer().
+ *
+ * @param {string} name
+ * @param {number} [delay] delay in milliseconds
+ */
+ EP.resetTimer = function ( name, delay ) {
+ if ( name in this.timers ) {
+ if ( delay === undefined ) {
+ delay = this.timers[ name ].delay;
+ }
+ this.setTimer( name, this.timers[ name ].handler, delay );
+ }
+ };
+
+ /**
+ * Makes the entire input/textarea selected when focused.
+ * Invoked with that input/textarea as context.
+ */
+ EP.selectAllOnEvent = function () {
+ try {
+ this.select();
+ } catch ( e ) {
+ // IE doesn't like when select() is called during the onfocus handler
+ }
+ };
+
+ /**
+ * Reduces the action of clicks to solely focusing the input/textarea.
+ * Essentialy disables clicking inside the text to select a portion of it.
+ * Invoked with that input/textarea as context.
+ *
+ * @param {jQuery.Event} e
+ * @return {boolean} False to prevent default event
+ */
+ EP.onlyFocus = function ( e ) {
+ this.focus();
+ e.preventDefault();
+ return false;
+ };
+
+ /**
+ * Flips E (east) and W (west) directions in RTL documents.
+ *
+ * @param {string} keyword a keyword where the first 'e' or 'w' character means a direction (such as a
+ * tipsy gravity parameter)
+ * @return {string}
+ */
+ EP.correctEW = function ( keyword ) {
+ if ( this.isRTL() ) {
+ keyword = keyword.replace( /[ew]/i, function ( dir ) {
+ if ( dir === 'e' ) {
+ return 'w';
+ } else if ( dir === 'E' ) {
+ return 'W';
+ } else if ( dir === 'w' ) {
+ return 'e';
+ } else if ( dir === 'W' ) {
+ return 'E';
+ }
+ } );
+ }
+ return keyword;
+ };
+
+ mw.mmv.ui = {};
+ mw.mmv.ui.reuse = {};
+ mw.mmv.ui.Element = Element;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.js
new file mode 100644
index 00000000..182173fa
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.js
@@ -0,0 +1,886 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var MPP;
+
+ /**
+ * Represents the metadata panel in the viewer
+ *
+ * @class mw.mmv.ui.MetadataPanel
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container The container for the panel (.mw-mmv-post-image).
+ * @param {jQuery} $aboveFold The brighter headline of the metadata panel (.mw-mmv-above-fold).
+ * Called "aboveFold" for historical reasons, but actually a part of the next sibling of the element
+ * is also above the fold (bottom of the screen).
+ * @param {mw.storage} localStorage the localStorage object, for dependency injection
+ * @param {mw.mmv.Config} config A configuration object.
+ */
+ function MetadataPanel( $container, $aboveFold, localStorage, config ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ this.$aboveFold = $aboveFold;
+
+ /** @property {mw.mmv.Config} config - */
+ this.config = config;
+
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+
+ this.initializeHeader( localStorage );
+ this.initializeImageMetadata();
+ this.initializeAboutLinks();
+ }
+ oo.inheritClass( MetadataPanel, mw.mmv.ui.Element );
+ MPP = MetadataPanel.prototype;
+
+ /**
+ * Maximum number of restriction icons before default icon is used
+ *
+ * @property MAX_RESTRICT
+ * @static
+ */
+ MetadataPanel.MAX_RESTRICT = 4;
+
+ /**
+ * FIXME this should be in the jquery.fullscreen plugin.
+ *
+ * @return {boolean}
+ */
+ MPP.isFullscreened = function () {
+ return $( this.$container ).closest( '.jq-fullscreened' ).length > 0;
+ };
+
+ MPP.attach = function () {
+ var panel = this;
+
+ this.scroller.attach();
+ this.buttons.attach();
+ this.title.attach();
+ this.creditField.attach();
+
+ this.$title
+ .add( this.$authorAndSource )
+ .add( this.title.$ellipsis )
+ .add( this.creditField.$ellipsis )
+ .each( function () {
+ $( this ).tipsy( 'enable' );
+ } )
+ .on( 'click.mmv-mp', function ( e ) {
+ var clickTargetIsLink = $( e.target ).is( 'a' ),
+ clickTargetIsTruncated = !!$( e.target ).closest( '.mw-mmv-ttf-truncated' ).length,
+ someTextIsExpanded = !!$( e.target ).closest( '.mw-mmv-untruncated' ).length;
+
+ if (
+ !clickTargetIsLink && // don't interfere with clicks on links in the text
+ clickTargetIsTruncated && // don't expand when non-truncated text is clicked
+ !someTextIsExpanded // ignore clicks if text is already expanded
+ ) {
+ if ( panel.isFullscreened() ) {
+ panel.revealTruncatedText();
+ } else {
+ panel.scroller.toggle( 'up' );
+ }
+ }
+ } );
+
+ $( this.$container ).on( 'mmv-metadata-open.mmv-mp mmv-metadata-reveal-truncated-text.mmv-mp', function () {
+ panel.revealTruncatedText();
+ } ).on( 'mmv-metadata-close.mmv-mp', function () {
+ panel.hideTruncatedText();
+ } ).on( 'mouseleave.mmv-mp', function () {
+ var duration;
+
+ if ( panel.isFullscreened() ) {
+ duration = parseFloat( panel.$container.css( 'transition-duration' ) ) * 1000 || 0;
+ panel.panelShrinkTimeout = setTimeout( function () {
+ panel.hideTruncatedText();
+ }, duration );
+ }
+ } ).on( 'mouseenter.mmv-mp', function () {
+ clearTimeout( panel.panelShrinkTimeout );
+ } ).on( 'mmv-permission-grow.mmv-mp', function () {
+ panel.$permissionLink
+ .text( mw.message( 'multimediaviewer-permission-link-hide' ).text() );
+ } ).on( 'mmv-permission-shrink.mmv-mp', function () {
+ panel.$permissionLink
+ .text( mw.message( 'multimediaviewer-permission-link' ).text() );
+ } );
+
+ this.handleEvent( 'jq-fullscreen-change.lip', function () {
+ panel.hideTruncatedText();
+ } );
+ };
+
+ MPP.unattach = function () {
+ this.scroller.freezeHeight();
+
+ this.$title
+ .add( this.title.$ellipsis )
+ .add( this.$authorAndSource )
+ .add( this.creditField.$ellipsis )
+ .each( function () {
+ $( this ).tipsy( 'hide' ).tipsy( 'disable' );
+ } )
+ .off( 'click.mmv-mp' );
+
+ $( this.$container ).off( '.mmv-mp' );
+
+ this.scroller.unattach();
+ this.buttons.unattach();
+ this.clearEvents();
+ };
+
+ MPP.empty = function () {
+ this.scroller.freezeHeight();
+ this.scroller.empty();
+
+ this.buttons.empty();
+
+ this.description.empty();
+ this.permission.empty();
+
+ this.$title.removeClass( 'error' );
+ this.title.empty();
+ this.creditField.empty();
+
+ this.$license.empty().prop( 'href', '#' );
+ this.$licenseLi.addClass( 'empty' );
+ this.$permissionLink.hide();
+ this.$restrictions.children().hide();
+
+ this.$filename.empty();
+ this.$filenamePrefix.empty();
+ this.$filenameLi.addClass( 'empty' );
+
+ this.$datetime.empty();
+ this.$datetimeLi.addClass( 'empty' );
+
+ this.$location.empty();
+ this.$locationLi.addClass( 'empty' );
+
+ this.progressBar.empty();
+
+ this.$container.removeClass( 'mw-mmv-untruncated' );
+ };
+
+ /* Initialization methods */
+
+ /**
+ * Initializes the header, which contains the title, credit, and license elements.
+ *
+ * @param {mw.storage} localStorage the localStorage object, for dependency injection
+ */
+ MPP.initializeHeader = function ( localStorage ) {
+ this.progressBar = new mw.mmv.ui.ProgressBar( this.$aboveFold );
+
+ this.scroller = new mw.mmv.ui.MetadataPanelScroller( this.$container, this.$aboveFold,
+ localStorage );
+
+ this.$titleDiv = $( '<div>' )
+ .addClass( 'mw-mmv-title-contain' )
+ .appendTo( this.$aboveFold );
+
+ this.$container.append( this.$aboveFold );
+
+ this.initializeButtons(); // float, needs to be on top
+ this.initializeTitle();
+ };
+
+ /**
+ * Initializes the title elements.
+ */
+ MPP.initializeTitle = function () {
+ this.$titlePara = $( '<p>' )
+ .addClass( 'mw-mmv-title-para' )
+ .appendTo( this.$aboveFold );
+
+ this.$title = $( '<span>' )
+ .addClass( 'mw-mmv-title' );
+
+ this.title = new mw.mmv.ui.TruncatableTextField( this.$titlePara, this.$title, {
+ styles: [ 'mw-mmv-title-small', 'mw-mmv-title-smaller' ]
+ } );
+ this.title.setTitle(
+ mw.message( 'multimediaviewer-title-popup-text' ),
+ mw.message( 'multimediaviewer-title-popup-text-more' )
+ );
+
+ this.$title.add( this.title.$ellipsis ).tipsy( {
+ delayIn: mw.config.get( 'wgMultimediaViewer' ).tooltipDelay,
+ gravity: this.correctEW( 'sw' )
+ } );
+ };
+
+ MPP.initializeButtons = function () {
+ this.buttons = new mw.mmv.ui.StripeButtons( this.$titleDiv );
+ };
+
+ /**
+ * Initializes the main body of metadata elements.
+ */
+ MPP.initializeImageMetadata = function () {
+ this.$container.addClass( 'mw-mmv-ttf-ellipsis-container' );
+
+ this.$imageMetadata = $( '<div>' )
+ .addClass( 'mw-mmv-image-metadata' )
+ .appendTo( this.$container );
+
+ this.$imageMetadataLeft = $( '<div>' )
+ .addClass( 'mw-mmv-image-metadata-column mw-mmv-image-metadata-desc-column' )
+ .appendTo( this.$imageMetadata );
+
+ this.$imageMetadataRight = $( '<div>' )
+ .addClass( 'mw-mmv-image-metadata-column mw-mmv-image-metadata-links-column' )
+ .appendTo( this.$imageMetadata );
+
+ this.initializeCredit();
+ this.description = new mw.mmv.ui.Description( this.$imageMetadataLeft );
+ this.permission = new mw.mmv.ui.Permission( this.$imageMetadataLeft, this.scroller );
+ this.initializeImageLinks();
+ };
+
+ /**
+ * Initializes the credit elements.
+ */
+ MPP.initializeCredit = function () {
+ this.$credit = $( '<p>' )
+ .addClass( 'mw-mmv-credit empty' )
+ .appendTo( this.$imageMetadataLeft )
+ .on( 'click.mmv-mp', '.mw-mmv-credit-fallback', function () {
+ mw.mmv.actionLogger.log( 'author-page' );
+ } );
+
+ // we need an inline container for tipsy, otherwise it would be centered weirdly
+ this.$authorAndSource = $( '<span>' )
+ .addClass( 'mw-mmv-source-author' )
+ .on( 'click', '.mw-mmv-author a', function () {
+ mw.mmv.actionLogger.log( 'author-page' );
+ } )
+ .on( 'click', '.mw-mmv-source a', function () {
+ mw.mmv.actionLogger.log( 'source-page' );
+ } );
+
+ this.creditField = new mw.mmv.ui.TruncatableTextField(
+ this.$credit,
+ this.$authorAndSource,
+ { styles: [] }
+ );
+
+ this.creditField.setTitle(
+ mw.message( 'multimediaviewer-credit-popup-text' ),
+ mw.message( 'multimediaviewer-credit-popup-text-more' )
+ );
+
+ this.$authorAndSource.add( this.creditField.$ellipsis ).tipsy( {
+ delayIn: mw.config.get( 'wgMultimediaViewer' ).tooltipDelay,
+ gravity: this.correctEW( 'sw' )
+ } );
+ };
+
+ /**
+ * Initializes the list of image metadata on the right side of the panel.
+ */
+ MPP.initializeImageLinks = function () {
+ this.$imageLinkDiv = $( '<div>' )
+ .addClass( 'mw-mmv-image-links-div' )
+ .appendTo( this.$imageMetadataRight );
+
+ this.$imageLinks = $( '<ul>' )
+ .addClass( 'mw-mmv-image-links' )
+ .appendTo( this.$imageLinkDiv );
+
+ this.initializeLicense();
+ this.initializeFilename();
+ this.initializeDatetime();
+ this.initializeLocation();
+ };
+
+ /**
+ * Initializes the license elements.
+ */
+ MPP.initializeLicense = function () {
+ var panel = this;
+
+ this.$licenseLi = $( '<li>' )
+ .addClass( 'mw-mmv-license-li empty' )
+ .appendTo( this.$imageLinks );
+
+ this.$license = $( '<a>' )
+ .addClass( 'mw-mmv-license' )
+ .prop( 'href', '#' )
+ .appendTo( this.$licenseLi )
+ .on( 'click', function () {
+ mw.mmv.actionLogger.log( 'license-page' );
+ } );
+
+ this.$restrictions = $( '<span>' )
+ .addClass( 'mw-mmv-restrictions' )
+ .appendTo( this.$licenseLi );
+
+ this.$permissionLink = $( '<span>' )
+ .addClass( 'mw-mmv-permission-link mw-mmv-label' )
+ .text( mw.message( 'multimediaviewer-permission-link' ).text() )
+ .appendTo( this.$licenseLi )
+ .hide()
+ .on( 'click', function () {
+ if ( panel.permission.isFullSize() ) {
+ panel.permission.shrink();
+ } else {
+ panel.permission.grow();
+ panel.scroller.toggle( 'up' );
+ }
+ return false;
+ } );
+ };
+
+ /**
+ * Initializes the filename element.
+ */
+ MPP.initializeFilename = function () {
+ this.$filenameLi = $( '<li>' )
+ .addClass( 'mw-mmv-filename-li empty' )
+ .appendTo( this.$imageLinks );
+
+ this.$filenamePrefix = $( '<span>' )
+ .addClass( 'mw-mmv-filename-prefix' )
+ .appendTo( this.$filenameLi );
+
+ this.$filename = $( '<span>' )
+ .addClass( 'mw-mmv-filename' )
+ .appendTo( this.$filenameLi );
+ };
+
+ /**
+ * Initializes the upload date/time element.
+ */
+ MPP.initializeDatetime = function () {
+ this.$datetimeLi = $( '<li>' )
+ .addClass( 'mw-mmv-datetime-li empty' )
+ .appendTo( this.$imageLinks );
+
+ this.$datetime = $( '<span>' )
+ .addClass( 'mw-mmv-datetime' )
+ .appendTo( this.$datetimeLi );
+ };
+
+ /**
+ * Initializes the geolocation element.
+ */
+ MPP.initializeLocation = function () {
+ this.$locationLi = $( '<li>' )
+ .addClass( 'mw-mmv-location-li empty' )
+ .appendTo( this.$imageLinks );
+
+ this.$location = $( '<a>' )
+ .addClass( 'mw-mmv-location' )
+ .appendTo( this.$locationLi )
+ .click( function () { mw.mmv.actionLogger.log( 'location-page' ); } );
+ };
+
+ /**
+ * Initializes two about links at the bottom of the panel.
+ */
+ MPP.initializeAboutLinks = function () {
+ var separator = ' | ';
+
+ this.$mmvAboutLink = $( '<a>' )
+ .prop( 'href', mw.config.get( 'wgMultimediaViewer' ).infoLink )
+ .text( mw.message( 'multimediaviewer-about-mmv' ).text() )
+ .addClass( 'mw-mmv-about-link' )
+ .click( function () { mw.mmv.actionLogger.log( 'about-page' ); } );
+
+ this.$mmvDiscussLink = $( '<a>' )
+ .prop( 'href', mw.config.get( 'wgMultimediaViewer' ).discussionLink )
+ .text( mw.message( 'multimediaviewer-discuss-mmv' ).text() )
+ .addClass( 'mw-mmv-discuss-link' )
+ .click( function () { mw.mmv.actionLogger.log( 'discuss-page' ); } );
+
+ this.$mmvHelpLink = $( '<a>' )
+ .prop( 'href', mw.config.get( 'wgMultimediaViewer' ).helpLink )
+ .text( mw.message( 'multimediaviewer-help-mmv' ).text() )
+ .addClass( 'mw-mmv-help-link' )
+ .click( function () { mw.mmv.actionLogger.log( 'help-page' ); } );
+
+ this.$mmvAboutLinks = $( '<div>' )
+ .addClass( 'mw-mmv-about-links' )
+ .append(
+ this.$mmvAboutLink,
+ separator,
+ this.$mmvDiscussLink,
+ separator,
+ this.$mmvHelpLink
+ )
+ .appendTo( this.$imageMetadata );
+ };
+
+ /* Setters */
+
+ /**
+ * Sets the image title at the top of the metadata panel.
+ * The title will be the first one available form the options below:
+ * - the image caption
+ * - the description from the filepage
+ * - the filename (without extension)
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @param {mw.mmv.model.Image} imageData
+ */
+ MPP.setTitle = function ( image, imageData ) {
+ var title;
+
+ if ( image.caption ) {
+ title = image.caption;
+ } else if ( imageData.description ) {
+ title = imageData.description;
+ } else {
+ title = image.filePageTitle.getNameText();
+ }
+
+ this.title.set( title );
+ };
+
+ /**
+ * Sets the upload or creation date and time in the panel
+ *f
+ * @param {string} date The formatted date to set.
+ * @param {boolean} created Whether this is the creation date
+ */
+ MPP.setDateTime = function ( date, created ) {
+ this.$datetime.text(
+ mw.message(
+ 'multimediaviewer-datetime-' + ( created ? 'created' : 'uploaded' ),
+ date
+ ).text()
+ );
+
+ this.$datetimeLi.removeClass( 'empty' );
+ };
+
+ /**
+ * Sets the file name in the panel.
+ *
+ * @param {string} filename The file name to set, without prefix
+ */
+ MPP.setFileName = function ( filename ) {
+ this.$filenamePrefix.text( 'File:' );
+ this.$filename.text( filename );
+
+ this.$filenameLi.removeClass( 'empty' );
+ };
+
+ /**
+ * Set source and author.
+ *
+ * @param {string} attribution Custom attribution string
+ * @param {string} source With unsafe HTML
+ * @param {string} author With unsafe HTML
+ * @param {number} authorCount
+ * @param {string} filepageUrl URL of the file page (used when other data is not available)
+ */
+ MPP.setCredit = function ( attribution, source, author, authorCount, filepageUrl ) {
+ // sanitization will be done by TruncatableTextField.set()
+ if ( attribution && ( authorCount <= 1 || !authorCount ) ) {
+ this.creditField.set( this.wrapAttribution( attribution ) );
+ } else if ( author && source ) {
+ this.creditField.set(
+ mw.message(
+ 'multimediaviewer-credit',
+ this.wrapAuthor( author, authorCount, filepageUrl ),
+ this.wrapSource( source )
+ ).plain()
+ );
+ } else if ( author ) {
+ this.creditField.set( this.wrapAuthor( author, authorCount, filepageUrl ) );
+ } else if ( source ) {
+ this.creditField.set( this.wrapSource( source ) );
+ } else {
+ this.creditField.set(
+ $( '<a>' )
+ .addClass( 'mw-mmv-credit-fallback' )
+ .prop( 'href', filepageUrl )
+ .text( mw.message( 'multimediaviewer-credit-fallback' ).plain() )
+ );
+ }
+
+ this.$credit.removeClass( 'empty' );
+ };
+
+ /**
+ * Wraps a source string it with MediaViewer styles
+ *
+ * @param {string} source Warning - unsafe HTML sometimes goes here
+ * @return {string} unsafe HTML
+ */
+ MPP.wrapSource = function ( source ) {
+ return $( '<span>' )
+ .addClass( 'mw-mmv-source' )
+ .append( $.parseHTML( source ) )
+ .get( 0 ).outerHTML;
+ };
+
+ /**
+ * Wraps an author string with MediaViewer styles
+ *
+ * @param {string} author Warning - unsafe HTML sometimes goes here
+ * @param {number} authorCount
+ * @param {string} filepageUrl URL of the file page (used when some author data is not available)
+ * @return {string} unsafe HTML
+ */
+ MPP.wrapAuthor = function ( author, authorCount, filepageUrl ) {
+ var moreText,
+ $wrapper = $( '<span>' );
+
+ $wrapper.addClass( 'mw-mmv-author' );
+
+ if ( authorCount > 1 ) {
+ moreText = this.htmlUtils.jqueryToHtml(
+ $( '<a>' )
+ .addClass( 'mw-mmv-more-authors' )
+ .text( mw.message( 'multimediaviewer-multiple-authors', authorCount - 1 ).text() )
+ .attr( 'href', filepageUrl )
+ );
+ $wrapper.append( mw.message( 'multimediaviewer-multiple-authors-combine', author, moreText ).text() );
+ } else {
+ $wrapper.append( author );
+ }
+
+ return $wrapper.get( 0 ).outerHTML;
+ };
+
+ /**
+ * Wraps an attribution string with MediaViewer styles
+ *
+ * @param {string} attribution Warning - unsafe HTML sometimes goes here
+ * @return {string} unsafe HTML
+ */
+ MPP.wrapAttribution = function ( attribution ) {
+ return $( '<span>' )
+ .addClass( 'mw-mmv-author' )
+ .addClass( 'mw-mmv-source' )
+ .append( $.parseHTML( attribution ) )
+ .get( 0 ).outerHTML;
+ };
+
+ /**
+ * Sets the license display in the panel
+ *
+ * @param {mw.mmv.model.License|null} license license data (could be missing)
+ * @param {string} filePageUrl URL of the file description page
+ */
+ MPP.setLicense = function ( license, filePageUrl ) {
+ var shortName, url, isCc, isPd;
+
+ if ( license ) {
+ shortName = license.getShortName();
+ url = license.deedUrl || filePageUrl;
+ isCc = license.isCc();
+ isPd = license.isPd();
+ } else {
+ shortName = mw.message( 'multimediaviewer-license-default' ).text();
+ url = filePageUrl;
+ isCc = isPd = false;
+ }
+
+ this.$license
+ .text( shortName )
+ .prop( 'href', url )
+ .prop( 'target', license && license.deedUrl ? '_blank' : '' );
+
+ this.$licenseLi
+ .toggleClass( 'cc-license', isCc )
+ .toggleClass( 'pd-license', isPd )
+ .removeClass( 'empty' );
+ };
+
+ /**
+ * Set an extra permission text which should be displayed.
+ *
+ * @param {string} permission
+ */
+ MPP.setPermission = function ( permission ) {
+ this.$permissionLink.show();
+ this.permission.set( permission );
+ };
+
+ /**
+ * Sets any special restrictions that should be displayed.
+ *
+ * @param {string[]} restrictions Array of restrictions
+ */
+ MPP.setRestrictions = function ( restrictions ) {
+ var panel = this,
+ restrictionsSet = {},
+ showDefault = false,
+ validRestrictions = 0;
+
+ $.each( restrictions, function ( index, value ) {
+ if ( !mw.message( 'multimediaviewer-restriction-' + value ).exists() || value === 'default' || index + 1 > MetadataPanel.MAX_RESTRICT ) {
+ showDefault = true; // If the restriction isn't defined or there are more than MAX_RESTRICT of them, show a generic symbol at the end
+ return;
+ }
+ if ( restrictionsSet[ value ] ) {
+ return; // Only show one of each symbol
+ } else {
+ restrictionsSet[ value ] = true;
+ }
+
+ panel.$restrictions.append( panel.createRestriction( value ) );
+ validRestrictions++; // See how many defined restrictions are added so we know which default i18n msg to use
+ } );
+
+ if ( showDefault ) {
+ if ( validRestrictions ) {
+ panel.$restrictions.append( panel.createRestriction( 'default-and-others' ) );
+ } else {
+ panel.$restrictions.append( panel.createRestriction( 'default' ) );
+ }
+ }
+ };
+
+ /**
+ * Helper function that generates restriction labels
+ *
+ * @param {string} type Restriction type
+ * @return {jQuery} jQuery object of label
+ */
+ MPP.createRestriction = function ( type ) {
+ var $label = $( '<span>' )
+ .addClass( 'mw-mmv-label mw-mmv-restriction-label' )
+ .prop( 'title', mw.message( 'multimediaviewer-restriction-' + type ).text() )
+ .tipsy( {
+ delay: mw.config.get( 'wgMultimediaViewer' ).tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } );
+
+ $( '<span>' )
+ .addClass( 'mw-mmv-restriction-label-inner mw-mmv-restriction-' +
+ ( type === 'default-and-others' ? 'default' : type ) )
+ .text( mw.message( 'multimediaviewer-restriction-' + type ).text() )
+ .appendTo( $label );
+
+ return $label;
+ };
+
+ /**
+ * Sets location data in the interface.
+ *
+ * @param {mw.mmv.model.Image} imageData
+ */
+ MPP.setLocationData = function ( imageData ) {
+ var latsec, latitude, latmsg, latdeg, latremain, latmin,
+ longsec, longitude, longmsg, longdeg, longremain, longmin,
+ language;
+
+ if ( !imageData.hasCoords() ) {
+ return;
+ }
+
+ latitude = imageData.latitude >= 0 ? imageData.latitude : imageData.latitude * -1;
+ latmsg = 'multimediaviewer-geoloc-' + ( imageData.latitude >= 0 ? 'north' : 'south' );
+ latdeg = Math.floor( latitude );
+ latremain = latitude - latdeg;
+ latmin = Math.floor( ( latremain ) * 60 );
+
+ longitude = imageData.longitude >= 0 ? imageData.longitude : imageData.longitude * -1;
+ longmsg = 'multimediaviewer-geoloc-' + ( imageData.longitude >= 0 ? 'east' : 'west' );
+ longdeg = Math.floor( longitude );
+ longremain = longitude - longdeg;
+ longmin = Math.floor( ( longremain ) * 60 );
+
+ longremain -= longmin / 60;
+ latremain -= latmin / 60;
+ latsec = Math.round( latremain * 100 * 60 * 60 ) / 100;
+ longsec = Math.round( longremain * 100 * 60 * 60 ) / 100;
+
+ this.$location.text(
+ mw.message( 'multimediaviewer-geolocation',
+ mw.message(
+ 'multimediaviewer-geoloc-coords',
+
+ mw.message(
+ 'multimediaviewer-geoloc-coord',
+ mw.language.convertNumber( latdeg ),
+ mw.language.convertNumber( latmin ),
+ mw.language.convertNumber( latsec ),
+ mw.message( latmsg ).text()
+ ).text(),
+
+ mw.message(
+ 'multimediaviewer-geoloc-coord',
+ mw.language.convertNumber( longdeg ),
+ mw.language.convertNumber( longmin ),
+ mw.language.convertNumber( longsec ),
+ mw.message( longmsg ).text()
+ ).text()
+ ).text()
+ ).text()
+ );
+
+ $.each( mw.language.data, function ( key ) {
+ language = key;
+ return false;
+ } );
+
+ this.$location.prop( 'href', (
+ '//tools.wmflabs.org/geohack/geohack.php?pagename=' +
+ 'File:' + imageData.title.getMain() +
+ '&params=' +
+ Math.abs( imageData.latitude ) + ( imageData.latitude >= 0 ? '_N_' : '_S_' ) +
+ Math.abs( imageData.longitude ) + ( imageData.longitude >= 0 ? '_E_' : '_W_' ) +
+ '&language=' + language
+ ) );
+
+ this.$locationLi.removeClass( 'empty' );
+ };
+
+ /**
+ * Set all the image information in the panel
+ *
+ * @param {mw.mmv.LightboxImage} image
+ * @param {mw.mmv.model.Image} imageData
+ * @param {mw.mmv.model.Repo} repoData
+ */
+ MPP.setImageInfo = function ( image, imageData, repoData ) {
+ var panel = this;
+
+ mw.mmv.attributionLogger.logAttribution( imageData );
+
+ if ( imageData.creationDateTime ) {
+ // Use the raw date until moment can try to interpret it
+ panel.setDateTime( imageData.creationDateTime );
+
+ this.formatDate( imageData.creationDateTime ).then( function ( formattedDate ) {
+ panel.setDateTime( formattedDate, true );
+ } );
+ } else if ( imageData.uploadDateTime ) {
+ // Use the raw date until moment can try to interpret it
+ panel.setDateTime( imageData.uploadDateTime );
+
+ this.formatDate( imageData.uploadDateTime ).then( function ( formattedDate ) {
+ panel.setDateTime( formattedDate );
+ } );
+ }
+
+ this.buttons.set( imageData, repoData );
+ this.description.set( imageData.description, image.caption );
+
+ this.setLicense( imageData.license, imageData.descriptionUrl );
+
+ this.setFileName( imageData.title.getMainText() );
+
+ // these handle text truncation and should be called when everything that can push text down
+ // (e.g. floated buttons) has already been laid out
+ this.setTitle( image, imageData );
+ this.setCredit( imageData.attribution, imageData.source, imageData.author, imageData.authorCount, imageData.descriptionUrl );
+
+ if ( imageData.permission ) {
+ this.setPermission( imageData.permission );
+ }
+
+ if ( imageData.restrictions ) {
+ this.setRestrictions( imageData.restrictions );
+ }
+
+ this.setLocationData( imageData );
+
+ this.resetTruncatedText();
+ this.scroller.unfreezeHeight();
+ };
+
+ /**
+ * Show an error message, in case the data could not be loaded
+ *
+ * @param {string} title image title
+ * @param {string} error error message
+ */
+ MPP.showError = function ( title, error ) {
+ this.$credit.text( mw.message( 'multimediaviewer-metadata-error', error ).text() );
+ this.$title.html( title );
+ };
+
+ /**
+ * Transforms a date string into localized, human-readable format.
+ * Unrecognized strings are returned unchanged.
+ *
+ * @param {string} dateString
+ * @return {jQuery.Deferred}
+ */
+ MPP.formatDate = function ( dateString ) {
+ var deferred = $.Deferred(),
+ date;
+
+ mw.loader.using( 'moment', function () {
+ /* global moment */
+ date = moment( dateString );
+
+ if ( date.isValid() ) {
+ deferred.resolve( date.format( 'LL' ) );
+ } else {
+ deferred.resolve( dateString );
+ }
+ }, function ( error ) {
+ deferred.reject( error );
+ if ( window.console && window.console.error ) {
+ window.console.error( 'mw.loader.using error when trying to load moment', error );
+ }
+ } );
+
+ return deferred.promise();
+ };
+
+ /**
+ * Shows truncated text in the title and credit (this also rearranges the layout a bit).
+ */
+ MPP.revealTruncatedText = function () {
+ if ( this.$container.hasClass( 'mw-mmv-untruncated' ) ) {
+ return;
+ }
+ this.$container.addClass( 'mw-mmv-untruncated' );
+ this.title.grow();
+ this.creditField.grow();
+ };
+
+ /**
+ * Undoes changes made by revealTruncatedText().
+ */
+ MPP.hideTruncatedText = function () {
+ if ( !this.$container.hasClass( 'mw-mmv-untruncated' ) ) {
+ return;
+ }
+ this.title.shrink();
+ this.creditField.shrink();
+ this.$container.removeClass( 'mw-mmv-untruncated' );
+ };
+
+ /**
+ * Hide or reveal truncated text based on whether the panel is open. This is normally handled by
+ * MetadataPanelScroller, but when the panel is reset (e.g. on a prev/next event) sometimes the panel position can change without a panel , such as on a
+ * prev/next event; in such cases this function has to be called.
+ */
+ MPP.resetTruncatedText = function () {
+ if ( this.scroller.panelIsOpen() ) {
+ this.revealTruncatedText();
+ } else {
+ this.hideTruncatedText();
+ }
+ };
+
+ mw.mmv.ui.MetadataPanel = MetadataPanel;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.less
new file mode 100644
index 00000000..9d3e3911
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanel.less
@@ -0,0 +1,392 @@
+@import '../mmv.globals';
+@import '../mmv.mixins';
+
+@panel-below-fold-background-color: #f8f9fa;
+
+@fold-separator-border-width: 1px;
+@vertical-padding: 10px;
+@horizontal-padding: 20px;
+@space-above-credit: 2px;
+
+.mw-mmv-info-box {
+ display: inline-block;
+ overflow: hidden;
+ border: 1px solid #c8ccd1;
+ border-radius: @border-radius;
+ background-color: #fff;
+}
+
+.mw-mmv-title-contain {
+ position: relative;
+}
+
+.mw-mmv-title-para {
+ @height: @metadatabar-above-fold-inner-height - 2 * @vertical-padding; // needs explicit height for text truncation logic
+ margin: 0 0 @vertical-padding; // use margin instead of padding for bottom so text is not visible
+ padding: @vertical-padding @horizontal-padding 0 @horizontal-padding;
+ height: @height;
+ line-height: @height;
+
+ &.mw-mmv-ttf-normal {
+ font-size: 20px;
+ }
+ &.mw-mmv-title-small {
+ font-size: 18px;
+ }
+ &.mw-mmv-title-smaller {
+ @vertical-padding: 6px;
+ @height: @metadatabar-above-fold-inner-height - 2 * @vertical-padding;
+ height: @height;
+ margin: 0 0 @horizontal-padding;
+ padding: @vertical-padding @horizontal-padding 0 @horizontal-padding;
+ line-height: floor( @height / 2 ); // two lines
+ font-size: 16px;
+ }
+
+ // this should be after the size-specific styles so it can override any height set there
+ &.mw-mmv-ttf-untruncated {
+ height: auto;
+ }
+
+ .mw-mmv-ttf-ellipsis {
+ right: @horizontal-padding;
+ bottom: 3px;
+ background-color: @panel-above-fold-background-color; // clip text
+
+ &:before {
+ .fade-out-horizontal( @panel-above-fold-background-color );
+ }
+ }
+}
+
+.mw-mmv-credit {
+ @padding-right: 5px;
+ margin: 0;
+ color: #54595d;
+ padding: 0 0 @padding-right;
+ font-size: 0.85em;
+
+ .metadata-panel-is-closed {
+ height: @metadatabar-below-fold-pushup-height - @space-above-credit - @fold-separator-border-width; // needs explicit height for text truncation logic
+ line-height: @metadatabar-below-fold-pushup-height - @space-above-credit - @fold-separator-border-width;
+ }
+
+ &.empty {
+ height: 0.85em;
+ }
+
+ .mw-mmv-ttf-ellipsis {
+ right: @padding-right;
+ bottom: 13px;
+ background-color: @panel-below-fold-background-color; // clip text
+
+ &:before {
+ .fade-out-horizontal( @panel-below-fold-background-color );
+ }
+ }
+}
+
+.mw-mmv-source-author {
+ line-height: 1.8em;
+}
+
+.mw-mmv-title {
+ // this element is the click target for text untruncation; with the default display:inline it would be an
+ // inline box which can have "gaps" between the lines, making clicks seem to have no effect
+ display: inline-block;
+}
+
+.mw-mmv-image-metadata {
+ width: 100%;
+ position: relative;
+ margin-top: -@metadatabar-below-fold-pushup-height;
+ border-top: @fold-separator-border-width solid #c8ccd1;
+ background-color: @panel-below-fold-background-color;
+ padding-top: @space-above-credit;
+
+ .jq-fullscreened & {
+ // Make sure content fits into the screen. This assumes no paddings.
+ height: @metadatabar-below-fold-pushup-height - @fold-separator-border-width - @space-above-credit;
+ overflow: hidden;
+ }
+ .jq-fullscreened .mw-mmv-untruncated & {
+ height: auto;
+ }
+}
+
+.mw-mmv-author:before {
+ display: inline-block;
+ vertical-align: middle;
+ height: 16px;
+ width: 16px;
+ content: ' ';
+ margin-right: 7px;
+ margin-bottom: 2px;
+ background-size: contain;
+ background-position: center center;
+ background-repeat: no-repeat;
+ /* @embed */
+ background-image: url( img/user-ltr.svg );
+}
+
+.mw-mmv-image-desc-div {
+ overflow-y: auto;
+ max-height: 150px;
+ margin-bottom: 15px;
+
+ &.empty {
+ display: none;
+ }
+}
+
+.mw-mmv-image-desc-div,
+.mw-mmv-image-links-div {
+ display: inline-block;
+ vertical-align: top;
+}
+
+@littlefont: 0.85em;
+@mediumfont: 0.95em;
+
+.mw-mmv-image-desc {
+ font-size: @mediumfont;
+ color: #54595d;
+}
+
+.mw-mmv-image-links {
+ margin: 0 20px;
+
+ li {
+ list-style: none;
+ font-size: @littlefont;
+ color: #3f4040;
+
+ &.empty {
+ display: none;
+ }
+
+ // Make sure the next list item is not visible when the
+ // metadata panel is closed
+ .metadata-panel-is-closed &.mw-mmv-license-li {
+ height: @metadatabar-below-fold-pushup-height - @space-above-credit;
+ line-height: @metadatabar-below-fold-pushup-height - @space-above-credit;
+ }
+
+ &:before {
+ display: inline-block;
+ vertical-align: middle;
+ height: 16px;
+ width: 16px;
+ content: ' ';
+ margin-right: 7px;
+ margin-bottom: 2px;
+ background-size: contain;
+ background-position: right center;
+ background-repeat: no-repeat;
+ }
+
+ &.mw-mmv-license-li:before {
+ /* @embed */
+ background-image: url( img/license.svg );
+ }
+
+ &.mw-mmv-license-li.cc-license:before {
+ /* @embed */
+ background-image: url( img/cc.svg );
+ }
+
+ &.mw-mmv-license-li.pd-license:before {
+ /* @embed */
+ background-image: url( img/pd.svg );
+ }
+
+ &.mw-mmv-filename-li:before {
+ /* @embed */
+ background-image: url( img/file.svg );
+ }
+
+ &.mw-mmv-datetime-li:before {
+ /* @embed */
+ background-image: url( img/time.svg );
+ }
+
+ &.mw-mmv-location-li:before {
+ /* @embed */
+ background-image: url( img/location.svg );
+ }
+
+ &.empty:before {
+ background-image: none !important; /* stylelint-disable-line declaration-no-important */
+ }
+ }
+}
+
+.mw-mmv-license-contain,
+.mw-mmv-license {
+ text-align: right;
+}
+
+.mw-mmv-filename-prefix {
+ padding-right: 4px;
+ cursor: text;
+}
+
+.mw-mmv-title-para,
+.mw-mmv-credit,
+.mw-mmv-image-desc {
+ padding-left: @horizontal-padding;
+}
+
+.mw-mmv-about-links {
+ font-size: @littlefont;
+ padding: @horizontal-padding;
+ width: 50%;
+ clear: both;
+}
+
+.mw-mmv-label {
+ background-color: #eaecf0;
+ color: #222;
+ margin-left: 6px;
+ margin-top: 1px;
+ border-radius: @border-radius;
+ padding: 2px 5px;
+ font-size: 0.9em;
+
+ &:hover {
+ background-color: #c8ccd1;
+ }
+}
+
+.mw-mmv-image-metadata-column {
+ float: left;
+}
+
+.mw-mmv-image-metadata-desc-column {
+ width: 66.5%;
+}
+
+.mw-mmv-image-metadata-links-column {
+ max-width: 33.5%;
+ width: 25%;
+ text-align: right;
+ float: right;
+ transition: width 0.2s ease-out;
+
+ .mw-mmv-untruncated & {
+ width: 33.5%;
+ text-align: left;
+ }
+
+}
+
+.mw-mmv-restrictions {
+ display: inline-block;
+ line-height: 14px;
+}
+
+.mw-mmv-restriction-label {
+ &,
+ &:hover {
+ background-color: #fc6;
+ }
+
+ cursor: default;
+ display: inline-block;
+ height: 16px;
+}
+
+.mw-mmv-restriction-label-inner {
+ display: inline-block;
+ width: 14px;
+ height: 14px;
+ text-indent: -9999px;
+ text-align: left;
+ background-size: contain;
+ &:after {
+ float: right;
+ text-indent: 0;
+ }
+}
+
+.mw-mmv-restriction-2257 {
+ /* @embed */
+ background-image: url( img/restrict-2257.svg );
+}
+
+.mw-mmv-restriction-aus-reserve {
+ /* @embed */
+ background-image: url( img/restrict-aus-reserve.svg );
+}
+
+.mw-mmv-restriction-communist {
+ /* @embed */
+ background-image: url( img/restrict-communist.svg );
+}
+
+.mw-mmv-restriction-costume {
+ /* @embed */
+ background-image: url( img/restrict-costume.svg );
+}
+
+.mw-mmv-restriction-currency {
+ /* @embed */
+ background-image: url( img/restrict-currency.svg );
+}
+
+.mw-mmv-restriction-design {
+ /* @embed */
+ background-image: url( img/restrict-design.svg );
+}
+
+.mw-mmv-restriction-fan-art {
+ /* @embed */
+ background-image: url( img/restrict-fan-art.svg );
+}
+
+.mw-mmv-restriction-ihl {
+ /* @embed */
+ background-image: url( img/restrict-ihl.svg );
+}
+
+.mw-mmv-restriction-insignia {
+ /* @embed */
+ background-image: url( img/restrict-insignia.svg );
+}
+
+.mw-mmv-restriction-ita-mibac {
+ /* @embed */
+ background-image: url( img/restrict-ita-mibac.svg );
+}
+
+.mw-mmv-restriction-nazi {
+ /* @embed */
+ background-image: url( img/restrict-nazi.svg );
+}
+
+.mw-mmv-restriction-personality {
+ /* @embed */
+ background-image: url( img/restrict-personality.svg );
+}
+
+.mw-mmv-restriction-trademarked:after {
+ content: '\002122';
+}
+
+.mw-mmv-restriction-default {
+ /* @embed */
+ background-image: url( img/restrict-default.svg );
+}
+
+.mw-mmv-permission-link {
+ cursor: pointer;
+
+ .jq-fullscreened & {
+ display: none;
+ }
+}
+
+.mw-mmv-optout-link.pending {
+ cursor: wait;
+ color: #54595d;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.js
new file mode 100644
index 00000000..d7095322
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.js
@@ -0,0 +1,247 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var MPSP;
+
+ /**
+ * Handles scrolling behavior of the metadata panel.
+ *
+ * @class mw.mmv.ui.MetadataPanelScroller
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container The container for the panel (.mw-mmv-post-image).
+ * @param {jQuery} $aboveFold The control bar element (.mw-mmv-above-fold).
+ * @param {mw.storage} localStorage the localStorage object, for dependency injection
+ */
+ function MetadataPanelScroller( $container, $aboveFold, localStorage ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ this.$aboveFold = $aboveFold;
+
+ /** @property {mw.storage} localStorage */
+ this.localStorage = localStorage;
+
+ /** @property {boolean} panelWasOpen state flag which will be used to detect open <-> closed transitions */
+ this.panelWasOpen = null;
+
+ /**
+ * Whether this user has ever opened the metadata panel.
+ * Based on a localstorage flag; will be set to true if the client does not support localstorage.
+ * @type {boolean}
+ */
+ this.hasOpenedMetadata = undefined;
+
+ /**
+ * Whether we've already fired an animation for the metadata div in this lightbox session.
+ * @property {boolean}
+ * @private
+ */
+ this.hasAnimatedMetadata = false;
+
+ this.initialize();
+ }
+ oo.inheritClass( MetadataPanelScroller, mw.mmv.ui.Element );
+ MPSP = MetadataPanelScroller.prototype;
+
+ MPSP.attach = function () {
+ var panel = this;
+
+ this.handleEvent( 'keydown', function ( e ) {
+ panel.keydown( e );
+ } );
+
+ $( window ).on( 'scroll.mmvp', $.throttle( 250, function () {
+ panel.scroll();
+ } ) );
+
+ this.$container.on( 'mmv-metadata-open', function () {
+ if ( !panel.hasOpenedMetadata && panel.localStorage.store ) {
+ panel.hasOpenedMetadata = true;
+ panel.localStorage.set( 'mmv.hasOpenedMetadata', '1' );
+ }
+ } );
+
+ // reset animation flag when the viewer is reopened
+ this.hasAnimatedMetadata = false;
+ };
+
+ MPSP.unattach = function () {
+ this.clearEvents();
+ $( window ).off( 'scroll.mmvp' );
+ this.$container.off( 'mmv-metadata-open' );
+ };
+
+ MPSP.empty = function () {
+ // need to remove this to avoid animating again when reopening lightbox on same page
+ this.$container.removeClass( 'invite' );
+
+ this.panelWasOpen = this.panelIsOpen();
+ };
+
+ /**
+ * Returns scroll top position when the panel is fully open.
+ * (In other words, the height of the area that is outside the screen, in pixels.)
+ *
+ * @return {number}
+ */
+ MPSP.getScrollTopWhenOpen = function () {
+ return this.$container.outerHeight() - parseInt( this.$aboveFold.css( 'min-height' ), 10 ) -
+ parseInt( this.$aboveFold.css( 'padding-bottom' ), 10 );
+ };
+
+ /**
+ * Makes sure the panel does not contract when it is emptied and thus keeps its position as much as possible.
+ * This should be called when switching images, before the panel is emptied, and should be undone with
+ * unfreezeHeight after the panel has been populeted with the new metadata.
+ */
+ MPSP.freezeHeight = function () {
+ var scrollTop, scrollTopWhenOpen;
+
+ if ( !this.$container.is( ':visible' ) ) {
+ return;
+ }
+
+ scrollTop = $( window ).scrollTop();
+ scrollTopWhenOpen = this.getScrollTopWhenOpen();
+
+ this.panelWasFullyOpen = ( scrollTop === scrollTopWhenOpen );
+ this.$container.css( 'min-height', this.$container.height() );
+ };
+
+ MPSP.unfreezeHeight = function () {
+ if ( !this.$container.is( ':visible' ) ) {
+ return;
+ }
+
+ this.$container.css( 'min-height', '' );
+ if ( this.panelWasFullyOpen ) {
+ $( window ).scrollTop( this.getScrollTopWhenOpen() );
+ }
+ };
+
+ MPSP.initialize = function () {
+ var value = this.localStorage.get( 'mmv.hasOpenedMetadata' );
+
+ // localStorage will only store strings; if values `null`, `false` or
+ // `0` are set, they'll come out as `"null"`, `"false"` or `"0"`, so we
+ // can be certain that an actual null is a failure to locate the item,
+ // and false is an issue with localStorage itself
+ if ( value !== false ) {
+ this.hasOpenedMetadata = value !== null;
+ } else {
+ // if there was an issue with localStorage, treat it as opened
+ this.hasOpenedMetadata = true;
+ }
+ };
+
+ /**
+ * Animates the metadata area when the viewer is first opened.
+ */
+ MPSP.animateMetadataOnce = function () {
+ if ( !this.hasOpenedMetadata && !this.hasAnimatedMetadata ) {
+ this.hasAnimatedMetadata = true;
+ this.$container.addClass( 'invite' );
+ }
+ };
+
+ /**
+ * Toggles the metadata div being totally visible.
+ *
+ * @param {string} [forceDirection] 'up' or 'down' makes the panel move on that direction (and is a noop
+ * if the panel is already at the upmost/bottommost position); without the parameter, the panel position
+ * is toggled. (Partially open counts as open.)
+ * @return {jQuery.Promise} A promise which resolves after the animation has finished.
+ */
+ MPSP.toggle = function ( forceDirection ) {
+ var scrollTopWhenOpen = this.getScrollTopWhenOpen(),
+ scrollTopWhenClosed = 0,
+ scrollTop = $( window ).scrollTop(),
+ panelIsOpen = scrollTop > scrollTopWhenClosed,
+ direction = forceDirection || ( panelIsOpen ? 'down' : 'up' ),
+ scrollTopTarget = ( direction === 'up' ) ? scrollTopWhenOpen : scrollTopWhenClosed;
+
+ // don't log / animate if the panel is already in the end position
+ if ( scrollTopTarget === scrollTop ) {
+ return $.Deferred().resolve().promise();
+ } else {
+ mw.mmv.actionLogger.log( direction === 'up' ? 'metadata-open' : 'metadata-close' );
+ if ( direction === 'up' && !panelIsOpen ) {
+ // FIXME nasty. This is not really an event but a command sent to the metadata panel;
+ // child UI elements should not send commands to their parents. However, there is no way
+ // to calculate the target scrollTop accurately without revealing the text, and the event
+ // which does that (metadata-open) is only triggered later in the process, when the panel
+ // actually scrolled, so we cannot use it here without risking triggering it multiple times.
+ this.$container.trigger( 'mmv-metadata-reveal-truncated-text' );
+ scrollTopTarget = this.getScrollTopWhenOpen();
+ }
+ return $( 'html, body' ).animate( { scrollTop: scrollTopTarget }, 'fast' ).promise();
+ }
+ };
+
+ /**
+ * Handles keydown events for this element.
+ *
+ * @param {jQuery.Event} e Key down event
+ */
+ MPSP.keydown = function ( e ) {
+ if ( e.altKey || e.shiftKey || e.ctrlKey || e.metaKey ) {
+ return;
+ }
+ switch ( e.which ) {
+ case 40: // Down arrow
+ // fall through
+ case 38: // Up arrow
+ this.toggle();
+ e.preventDefault();
+ break;
+ }
+ };
+
+ /**
+ * Returns whether the metadata panel is open. (Partially open is considered to be open.)
+ *
+ * @return {boolean}
+ */
+ MPSP.panelIsOpen = function () {
+ return $( window ).scrollTop() > 0;
+ };
+
+ /**
+ * Receives the window's scroll events and and turns them into business logic events
+ *
+ * @fires mmv-metadata-open
+ * @fires mmv-metadata-close
+ */
+ MPSP.scroll = function () {
+ var panelIsOpen = this.panelIsOpen();
+
+ if ( panelIsOpen && !this.panelWasOpen ) { // just opened
+ this.$container.trigger( 'mmv-metadata-open' );
+ // This will include keyboard- and mouseclick-initiated open events as well,
+ // since the panel is anomated, which counts as scrolling.
+ // Filtering these seems too much trouble to be worth it.
+ mw.mmv.actionLogger.log( 'metadata-scroll-open' );
+ } else if ( !panelIsOpen && this.panelWasOpen ) { // just closed
+ this.$container.trigger( 'mmv-metadata-close' );
+ mw.mmv.actionLogger.log( 'metadata-scroll-close' );
+ }
+ this.panelWasOpen = panelIsOpen;
+ };
+
+ mw.mmv.ui.MetadataPanelScroller = MetadataPanelScroller;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.less
new file mode 100644
index 00000000..4edf59f6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.metadataPanelScroller.less
@@ -0,0 +1,69 @@
+@import '../mmv.globals';
+@import '../mmv.mixins';
+@import 'mediawiki.mixins.animation';
+
+.mw-mmv-post-image {
+ .animation( mw-mmv-appear-animation 0.5s ease 0s 1 normal forwards );
+ transition: box-shadow 0.25s;
+
+ &.invite {
+ .animation( mw-mmv-invite-animation 0.9s ease 0.2s 1 normal forwards );
+ }
+
+ .jq-fullscreened & {
+ .animation( none );
+ }
+
+ &.mw-mmv-untruncated,
+ .jq-fullscreened & {
+ box-shadow: 0 -4px 0 rgba( 0, 0, 0, 0.2 );
+ }
+}
+
+.mw-mmv-appear-animation() {
+ 0% {
+ opacity: 0.6;
+ }
+ 50% {
+ opacity: 0.9;
+ }
+ 100% {
+ opacity: 1;
+ }
+}
+
+@-webkit-keyframes mw-mmv-appear-animation {
+ .mw-mmv-appear-animation;
+}
+
+@-moz-keyframes mw-mmv-appear-animation {
+ .mw-mmv-appear-animation;
+}
+
+@keyframes mw-mmv-appear-animation {
+ .mw-mmv-appear-animation;
+}
+
+.mw-mmv-invite-animation() {
+ 0% {
+ margin-top: 0;
+ }
+ 30% {
+ margin-top: -15px;
+ }
+ 85% {
+ margin-top: 0;
+ }
+}
+
+@-webkit-keyframes mw-mmv-invite-animation {
+ .mw-mmv-invite-animation;
+}
+
+@-moz-keyframes mw-mmv-invite-animation {
+ .mw-mmv-invite-animation;
+}
+
+@keyframes mw-mmv-invite-animation {
+ .mw-mmv-invite-animation;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.js
new file mode 100644
index 00000000..74ce639a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.js
@@ -0,0 +1,173 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var P;
+
+ /**
+ * A box to display additional terms or remarks from the image author.
+ * (Typically comes from the Permission field of the {{Information}} template.)
+ * It has two states: when closed, it just shows some text, when open, it shows the HTML
+ * block supplied by the author in its full beauty.
+ *
+ * @class mw.mmv.ui.Permission
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container
+ * @param {mw.mmv.ui.MetadataPanelScroller} scroller
+ */
+ function Permission( $container, scroller ) {
+ var permission = this;
+
+ mw.mmv.ui.Element.call( this, $container );
+
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+
+ /**
+ * Contains everything else.
+ * @property {jQuery}
+ */
+ this.$box = $( '<div>' )
+ .addClass( 'mw-mmv-permission-box mw-mmv-info-box empty' )
+ .appendTo( this.$container );
+
+ /**
+ * Box title
+ * @property {jQuery}
+ */
+ this.$title = $( '<h3>' )
+ .text( mw.message( 'multimediaviewer-permission-title' ).text() )
+ .appendTo( this.$box );
+
+ /**
+ * Plain-text version of the author's message
+ * This is just the text parsed out from the original markup, it might not make much sense
+ * (e.g. if the original is a HTML table)
+ * @property {jQuery}
+ */
+ this.$text = $( '<div>' )
+ .addClass( 'mw-mmv-permission-text' )
+ .appendTo( this.$box )
+ .on( 'click', '.mw-mmv-permission-text-viewmore', function ( e ) {
+ e.preventDefault();
+ permission.grow();
+ permission.scroller.toggle( 'up' );
+ } )
+ ;
+
+ /**
+ * A helper element to fade off text
+ * @property {jQuery}
+ */
+ this.$fader = $( '<div>' )
+ .addClass( 'mw-mmv-permission-text-fader' )
+ .append(
+ $( '<a>' )
+ .addClass( 'mw-mmv-permission-text-viewmore' )
+ .prop( 'href', '#' )
+ .text( mw.message( 'multimediaviewer-permission-viewmore' ).text() )
+ );
+
+ /**
+ * Original (HTML) version of the author's message
+ * This can be scary sometimes (huge tables, black text on dark purple background etc).
+ * @property {jQuery}
+ */
+ this.$html = $( '<div>' )
+ .addClass( 'mw-mmv-permission-html' )
+ .appendTo( this.$box );
+
+ /**
+ * "Close" button (does not actually close the box, just makes it smaller).
+ * @property {jQuery}
+ */
+ this.$close = $( '<button>' )
+ .addClass( 'mw-mmv-permission-close' )
+ .on( 'click', function () {
+ permission.shrink();
+ } )
+ .appendTo( this.$box );
+
+ /**
+ * Panel scroller from the metadata panel object.
+ * @property {mw.mmv.ui.MetadataPanelScroller}
+ */
+ this.scroller = scroller;
+ }
+ oo.inheritClass( Permission, mw.mmv.ui.Element );
+ P = Permission.prototype;
+
+ /**
+ * Clear everything
+ */
+ P.empty = function () {
+ this.$box.addClass( 'empty' );
+ this.$text.empty();
+ this.$html.empty();
+ };
+
+ /**
+ * Set permission text/html
+ *
+ * @param {string} permission the text or HTML code written by the image author
+ */
+ P.set = function ( permission ) {
+ this.$box.removeClass( 'empty' );
+
+ this.$text.html( this.htmlUtils.htmlToTextWithLinks( permission ) );
+ this.$text.append( this.$fader );
+
+ this.$html.html( permission );
+ };
+
+ /**
+ * Enlarge the box, show HTML instead of text.
+ *
+ * @fires mmv-permission-grow
+ */
+ P.grow = function () {
+ mw.mmv.actionLogger.log( 'terms-open' );
+
+ this.$box.addClass( 'full-size' )
+ .stop( true )
+ .animate( { backgroundColor: '#FFFFA0' }, 500 )
+ .animate( { backgroundColor: '#FFFFFF' }, 500 );
+ this.$container.trigger( 'mmv-permission-grow' );
+ };
+
+ /**
+ * Limit the size of the box, show text only.
+ *
+ * @fires mmv-permission-shrink
+ */
+ P.shrink = function () {
+ this.$box.removeClass( 'full-size' );
+ this.$container.trigger( 'mmv-permission-shrink' );
+ };
+
+ /**
+ * Returns whether the box is full-size.
+ *
+ * @return {boolean}
+ */
+ P.isFullSize = function () {
+ return this.$box.hasClass( 'full-size' );
+ };
+
+ mw.mmv.ui.Permission = Permission;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.less
new file mode 100644
index 00000000..52051594
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.permission.less
@@ -0,0 +1,81 @@
+@import 'mediawiki.mixins';
+@import '../mmv.mixins';
+
+.mw-mmv-permission-box {
+ position: relative;
+ width: 90%;
+ margin: 10px 20px 0;
+
+ &.empty {
+ display: none;
+ }
+
+ h3 {
+ margin: 10px;
+ padding: 0;
+ color: #54595d;
+ font-size: 0.95em;
+ }
+
+ .mw-mmv-permission-close {
+ display: none;
+ position: absolute;
+ top: 12px;
+ right: 8px;
+ width: 16px;
+ height: 16px;
+ .background-image( 'img/x_gray.svg' );
+ cursor: pointer;
+ }
+
+ .mw-mmv-permission-text {
+ @text-font-size: 0.9em;
+ @text-line-height: 1.4;
+ @lines-shown: 3;
+
+ position: relative;
+ max-height: @lines-shown * @text-line-height * @text-font-size;
+ overflow: hidden;
+ margin: 0 10px 10px;
+ font-size: @text-font-size;
+ line-height: @text-line-height;
+ color: #54595d;
+
+ .mw-mmv-permission-text-fader {
+ position: absolute;
+ top: ( @lines-shown - 1 ) * @text-line-height * @text-font-size;
+ width: 100%;
+ height: @text-line-height * @text-font-size;
+ .fade-out-vertical();
+ text-align: right;
+
+ a {
+ padding: 3px 0 0 1em;
+ background-color: #fff;
+ font-size: 1em;
+ }
+ }
+ }
+
+ .mw-mmv-permission-html {
+ padding: 0 15px 15px;
+ display: none;
+ max-height: 400px;
+ overflow: auto;
+ }
+
+ &.full-size {
+ .mw-mmv-permission-close {
+ display: block;
+ }
+
+ .mw-mmv-permission-text {
+ display: none;
+ }
+
+ .mw-mmv-permission-html {
+ display: block;
+ border-top: 1px solid #f8f9fa;
+ }
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.js
new file mode 100644
index 00000000..c34a27d4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.js
@@ -0,0 +1,93 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var PBP;
+
+ /**
+ * A progress bar for the loading of the image.
+ *
+ * @class mw.mmv.ui.ProgressBar
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container
+ */
+ function ProgressBar( $container ) {
+ mw.mmv.ui.Element.call( this, $container );
+ this.init();
+ }
+ oo.inheritClass( ProgressBar, mw.mmv.ui.Element );
+ PBP = ProgressBar.prototype;
+
+ /**
+ * Initializes the progress display at the top of the panel.
+ */
+ PBP.init = function () {
+ this.$progress = $( '<div>' )
+ .addClass( 'mw-mmv-progress empty' )
+ .appendTo( this.$container );
+ this.$percent = $( '<div>' )
+ .addClass( 'mw-mmv-progress-percent' )
+ .appendTo( this.$progress );
+ };
+
+ PBP.empty = function () {
+ this.hide();
+ };
+
+ /**
+ * Hides the bar, resets it to 0 and stops any animation in progress.
+ */
+ PBP.hide = function () {
+ this.$progress.addClass( 'empty' );
+ this.$percent.stop().css( { width: 0 } );
+ };
+
+ /**
+ * Handles the progress display when a percentage of progress is received
+ *
+ * @param {number} percent a number between 0 and 100
+ */
+ PBP.animateTo = function ( percent ) {
+ var panel = this;
+
+ this.$progress.removeClass( 'empty' );
+ this.$percent.stop();
+
+ if ( percent === 100 ) {
+ // When a 100% update comes in, we make sure that the bar is visible, we animate
+ // fast to 100 and we hide the bar when the animation is done
+ this.$percent.animate( { width: percent + '%' }, 50, 'swing', $.proxy( panel.hide, panel ) );
+ } else {
+ // When any other % update comes in, we make sure the bar is visible
+ // and we animate to the right position
+ this.$percent.animate( { width: percent + '%' } );
+ }
+ };
+
+ /**
+ * Goes to the given percent without animation
+ *
+ * @param {number} percent a number between 0 and 100
+ */
+ PBP.jumpTo = function ( percent ) {
+ this.$progress.removeClass( 'empty' );
+ this.$percent.stop().css( { width: percent + '%' } );
+ };
+
+ mw.mmv.ui.ProgressBar = ProgressBar;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.less
new file mode 100644
index 00000000..9f4c2a67
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.progressBar.less
@@ -0,0 +1,46 @@
+@import '../mmv.globals';
+@import 'mediawiki.mixins.animation';
+
+@progress-height: @progress-bar-height;
+
+.mw-mmv-progress {
+ background-color: #c8ccd1;
+ background-color: rgba( 221, 221, 221, 0.5 );
+ width: 100%;
+ height: @progress-height;
+ position: absolute;
+ top: -@progress-height;
+}
+
+.mw-mmv-progress.empty {
+ display: none;
+}
+
+.mw-mmv-progress-percent {
+ width: 0;
+ height: @progress-height;
+ background: linear-gradient( -45deg, transparent 33%, rgba( 0, 0, 0, 0.1 ) 33%, rgba( 0, 0, 0, 0.1 ) 66%, transparent 66% ), #36c;
+ background-size: 35px 20px, 100% 100%, 100% 100%;
+ .animation( mw-mmv-progress-percent-animation 1.5s linear infinite );
+}
+
+.mw-mmv-progress-percent-animation() {
+ 0% {
+ background-position: 0 0;
+ }
+ 100% {
+ background-position: -70px 0;
+ }
+}
+
+@-webkit-keyframes mw-mmv-progress-percent-animation {
+ .mw-mmv-progress-percent-animation;
+}
+
+@-moz-keyframes mw-mmv-progress-percent-animation {
+ .mw-mmv-progress-percent-animation;
+}
+
+@keyframes mw-mmv-progress-percent-animation {
+ .mw-mmv-progress-percent-animation;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.js
new file mode 100644
index 00000000..11eb46f4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.js
@@ -0,0 +1,264 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var DP;
+
+ /**
+ * Represents the file reuse dialog and the link to open it.
+ *
+ * @class mw.mmv.ui.reuse.Dialog
+ * @extends mw.mmv.ui.Element
+ * @param {jQuery} $container the element to which the dialog will be appended
+ * @param {jQuery} $openButton the button which opens the dialog. Only used for positioning.
+ * @param {mw.mmv.Config} config
+ */
+ function Dialog( $container, $openButton, config ) {
+ mw.mmv.ui.Dialog.call( this, $container, $openButton, config );
+
+ /**
+ * @property {Object.<string, mw.mmv.ui.Element>} tabs List of tab ui objects.
+ */
+ this.tabs = null;
+
+ /**
+ * @property {Object.<string, OO.ui.MenuOptionWidget>} ooTabs List of tab OOUI objects.
+ */
+ this.ooTabs = null;
+
+ this.loadDependencies.push( 'mmv.ui.reuse.shareembed' );
+
+ this.$dialog.addClass( 'mw-mmv-reuse-dialog' );
+
+ this.eventPrefix = 'use-this-file';
+ }
+
+ oo.inheritClass( Dialog, mw.mmv.ui.Dialog );
+ DP = Dialog.prototype;
+
+ // FIXME this should happen outside the dialog and the tabs, but we need to improve
+ DP.initTabs = function () {
+ function makeTab( type ) {
+ return new oo.ui.MenuOptionWidget( {
+ data: type,
+ label: mw.message( 'multimediaviewer-' + type + '-tab' ).text()
+ } );
+ }
+
+ this.reuseTabs = new oo.ui.MenuSelectWidget( {
+ autoHide: false,
+ classes: [ 'mw-mmv-reuse-tabs' ]
+ } );
+ this.reuseTabs.$element.appendTo( this.$dialog );
+
+ this.tabs = {
+ share: new mw.mmv.ui.reuse.Share( this.$dialog ),
+ embed: new mw.mmv.ui.reuse.Embed( this.$dialog )
+ };
+
+ this.ooTabs = {
+ share: makeTab( 'share' ),
+ embed: makeTab( 'embed' )
+ };
+
+ this.reuseTabs.addItems( [
+ this.ooTabs.share,
+ this.ooTabs.embed
+ ] );
+
+ // MenuSelectWidget has a nasty tendency to hide itself, maybe we're not using it right?
+ this.reuseTabs.toggle( true );
+ this.reuseTabs.toggle = $.noop;
+
+ this.selectedTab = this.getLastUsedTab();
+
+ // In case nothing is saved in localStorage or it contains junk
+ if ( !this.tabs.hasOwnProperty( this.selectedTab ) ) {
+ this.selectedTab = 'share';
+ }
+
+ this.reuseTabs.selectItem( this.ooTabs[ this.selectedTab ] );
+
+ if ( this.dependenciesNeedToBeAttached ) {
+ this.attachDependencies();
+ }
+
+ if ( this.tabsSetValues ) {
+ // This is a delayed set() for the elements we've just created on demand
+ this.tabs.share.set.apply( this.tabs.share, this.tabsSetValues.share );
+ this.tabs.embed.set.apply( this.tabs.embed, this.tabsSetValues.embed );
+ this.showImageWarnings( this.tabsSetValues.share[ 0 ] );
+ this.tabsSetValues = undefined;
+ }
+ };
+
+ DP.toggleDialog = function () {
+ if ( this.tabs === null ) {
+ this.initTabs();
+ }
+
+ mw.mmv.ui.Dialog.prototype.toggleDialog.call( this );
+ };
+
+ /**
+ * Handles tab selection.
+ *
+ * @param {OO.ui.MenuOptionWidget} option
+ */
+ DP.handleTabSelection = function ( option ) {
+ var tab;
+
+ this.selectedTab = option.getData();
+
+ for ( tab in this.tabs ) {
+ if ( tab === this.selectedTab ) {
+ this.tabs[ tab ].show();
+ } else {
+ this.tabs[ tab ].hide();
+ }
+ }
+
+ this.config.setInLocalStorage( 'mmv-lastUsedTab', this.selectedTab );
+ };
+
+ /**
+ * @return {string} Last used tab
+ */
+ DP.getLastUsedTab = function () {
+ return this.config.getFromLocalStorage( 'mmv-lastUsedTab' );
+ };
+
+ /**
+ * Registers listeners.
+ */
+ DP.attach = function () {
+ this.handleEvent( 'mmv-reuse-open', $.proxy( this.handleOpenCloseClick, this ) );
+
+ this.handleEvent( 'mmv-download-open', $.proxy( this.closeDialog, this ) );
+ this.handleEvent( 'mmv-options-open', $.proxy( this.closeDialog, this ) );
+
+ this.attachDependencies();
+ };
+
+ /**
+ * Registrers listeners for dependencies loaded on demand
+ */
+ DP.attachDependencies = function () {
+ var tab, dialog = this;
+
+ if ( this.reuseTabs && this.tabs ) {
+ // This is a delayed attach() for the elements we've just created on demand
+ this.reuseTabs.on( 'select', $.proxy( dialog.handleTabSelection, dialog ) );
+
+ for ( tab in this.tabs ) {
+ this.tabs[ tab ].attach();
+ }
+
+ this.dependenciesNeedToBeAttached = false;
+ } else {
+ this.dependenciesNeedToBeAttached = true;
+ }
+ };
+
+ /**
+ * Clears listeners.
+ */
+ DP.unattach = function () {
+ var tab;
+
+ mw.mmv.ui.Dialog.prototype.unattach.call( this );
+
+ if ( this.reuseTabs ) {
+ this.reuseTabs.off( 'select' );
+ }
+
+ if ( this.tabs ) {
+ for ( tab in this.tabs ) {
+ this.tabs[ tab ].unattach();
+ }
+ }
+ };
+
+ /**
+ * Sets data needed by contaned tabs and makes dialog launch link visible.
+ *
+ * @param {mw.mmv.model.Image} image
+ * @param {mw.mmv.model.Repo} repo
+ * @param {string} caption
+ * @param {string} alt
+ */
+ DP.set = function ( image, repo, caption, alt ) {
+ if ( this.tabs !== null ) {
+ this.tabs.share.set( image );
+ this.tabs.embed.set( image, repo, caption, alt );
+ this.tabs.embed.set( image, repo, caption );
+ this.showImageWarnings( image );
+ } else {
+ this.tabsSetValues = {
+ share: [ image ],
+ embed: [ image, repo, caption, alt ]
+ };
+ }
+ };
+
+ /**
+ * @inheritdoc
+ */
+ DP.empty = function () {
+ var tab;
+
+ mw.mmv.ui.Dialog.prototype.empty.call( this );
+
+ for ( tab in this.tabs ) {
+ this.tabs[ tab ].empty();
+ }
+ };
+
+ /**
+ * @event mmv-reuse-opened
+ * Fired when the dialog is opened.
+ */
+ /**
+ * Opens a dialog with information about file reuse.
+ */
+ DP.openDialog = function () {
+ mw.mmv.ui.Dialog.prototype.openDialog.call( this );
+
+ // move warnings after the tabs
+ this.$warning.insertAfter( this.reuseTabs.$element );
+
+ this.tabs[ this.selectedTab ].show();
+
+ $( document ).trigger( 'mmv-reuse-opened' );
+ };
+
+ /**
+ * @event mmv-reuse-closed
+ * Fired when the dialog is closed.
+ */
+ /**
+ * Closes the reuse dialog.
+ */
+ DP.closeDialog = function () {
+ mw.mmv.ui.Dialog.prototype.closeDialog.call( this );
+
+ $( document ).trigger( 'mmv-reuse-closed' );
+ };
+
+ mw.mmv.ui.reuse.Dialog = Dialog;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.less
new file mode 100644
index 00000000..976a2903
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.dialog.less
@@ -0,0 +1,72 @@
+@import '../mmv.mixins';
+@import '../mmv.globals';
+
+.mw-mmv-reuse-dialog {
+ @divider-border-height: 1px;
+
+ // resetting height (to overwrite .mw-mmv-dialog's bigger height), since the
+ // height may have to change for warnings being added
+ height: initial;
+ // set a standard min-height that should be larger than both panels in
+ // normal circumstances (without warnings) so that the height of the dialog
+ // doesn't change when switching tabs
+ min-height: 300px;
+ // positioned relative to the reuse button
+ bottom: @metadatabar-above-fold-height + @progress-bar-height - 5px;
+
+ .mw-mmv-reuse-tabs {
+ @divider-color: #c8ccd1;
+
+ position: static;
+ box-shadow: none;
+ padding-bottom: 0; // OOUI override
+ border: 0; // OOUI override
+ border-bottom: @divider-border-height solid @divider-color;
+ border-radius: @border-radius @border-radius 0 0;
+
+ .oo-ui-iconedElement-icon.oo-ui-icon-check,
+ .oo-ui-iconElement-icon.oo-ui-icon-check {
+ display: none;
+ }
+
+ .oo-ui-optionWidget {
+ @tab-border-height: 3px;
+ @highlighted-tab-color: #e1f3ff;
+ @selected-tab-color: #2a4b8d;
+
+ display: inline-block;
+ padding: 10px 25px;
+ font-size: 1.2em;
+
+ &.oo-ui-optionWidget-highlighted {
+ border-bottom: ( @tab-border-height - @divider-border-height ) solid @highlighted-tab-color;
+ }
+
+ &.oo-ui-optionWidget-selected,
+ &.oo-ui-optionWidget-highlighted.oo-ui-optionWidget-selected {
+ border-bottom: @tab-border-height solid @selected-tab-color;
+ }
+
+ &:first-child {
+ border-radius: @border-radius 0 0 0;
+ }
+ }
+ }
+
+ .mw-mmv-reuse-pane {
+ display: none;
+ padding: 20px;
+
+ &.active {
+ display: block;
+ }
+ }
+
+ .mw-mmv-dialog-down-arrow {
+ bottom: @metadatabar-above-fold-height + @progress-bar-height + 5px;
+ }
+
+ .mw-mmv-dialog-warning {
+ padding: 15px 30px;
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.js
new file mode 100644
index 00000000..bdf03aff
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.js
@@ -0,0 +1,542 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var EP;
+
+ /**
+ * UI component that provides the user html/wikitext snippets needed to share
+ * and/or embed a media asset.
+ *
+ * @class mw.mmv.ui.reuse.Embed
+ * @extends mw.mmv.ui.reuse.Tab
+ * @constructor
+ * @param {jQuery} $container
+ */
+ function Embed( $container ) {
+ mw.mmv.ui.reuse.Tab.call( this, $container );
+
+ /**
+ * Formatter converting image data into formats needed for output
+ *
+ * @property {mw.mmv.EmbedFileFormatter}
+ */
+ this.formatter = new mw.mmv.EmbedFileFormatter();
+
+ /** @property {mw.mmv.ui.Utils} utils - */
+ this.utils = new mw.mmv.ui.Utils();
+
+ /**
+ * Indicates whether or not the default option has been reset for both size menus.
+ *
+ * @property {boolean}
+ */
+ this.isSizeMenuDefaultReset = false;
+
+ this.$pane.addClass( 'mw-mmv-embed-pane' );
+
+ this.$pane.appendTo( this.$container );
+
+ this.createSnippetTextAreas( this.$pane );
+
+ this.$explanation = $( '<div>' )
+ .addClass( 'mw-mmv-shareembed-explanation mw-mmv-embed-explanation' )
+ .text( mw.message( 'multimediaviewer-embed-explanation' ).text() )
+ .appendTo( this.$pane );
+
+ this.createSnippetSelectionButtons( this.$pane );
+ this.createSizePulldownMenus( this.$pane );
+
+ /**
+ * Currently selected embed snippet.
+ *
+ * @property {jQuery}
+ */
+ this.$currentMainEmbedText = mw.user.isAnon() ? this.embedTextHtml.$element : this.embedTextWikitext.$element;
+
+ /**
+ * Default item for the html size menu.
+ *
+ * @property {OO.ui.MenuOptionWidget}
+ */
+ this.defaultHtmlItem = this.embedSizeSwitchHtml.getMenu().findSelectedItem();
+
+ /**
+ * Default item for the wikitext size menu.
+ *
+ * @property {OO.ui.MenuOptionWidget}
+ */
+ this.defaultWikitextItem = this.embedSizeSwitchWikitext.getMenu().findSelectedItem();
+
+ /**
+ * Currently selected size menu.
+ *
+ * @property {OO.ui.MenuSelectWidget}
+ */
+ this.currentSizeMenu = mw.user.isAnon() ? this.embedSizeSwitchHtml.getMenu() : this.embedSizeSwitchWikitext.getMenu();
+
+ /**
+ * Current default item.
+ *
+ * @property {OO.ui.MenuOptionWidget}
+ */
+ this.currentDefaultItem = mw.user.isAnon() ? this.defaultHtmlItem : this.defaultWikitextItem;
+ }
+ oo.inheritClass( Embed, mw.mmv.ui.reuse.Tab );
+ EP = Embed.prototype;
+
+ /** @property {number} Width threshold at which an image is to be considered "large" */
+ EP.LARGE_IMAGE_WIDTH_THRESHOLD = 1200;
+
+ /** @property {number} Height threshold at which an image is to be considered "large" */
+ EP.LARGE_IMAGE_HEIGHT_THRESHOLD = 900;
+
+ /**
+ * Creates text areas for html and wikitext snippets.
+ *
+ * @param {jQuery} $container
+ */
+ EP.createSnippetTextAreas = function ( $container ) {
+ var wikitextClasses = [ 'mw-mmv-embed-text-wikitext' ],
+ htmlClasses = [ 'mw-mmv-embed-text-html' ];
+
+ ( mw.user.isAnon() ? htmlClasses : wikitextClasses ).push( 'active' );
+
+ this.embedTextHtml = new oo.ui.MultilineTextInputWidget( {
+ classes: htmlClasses,
+ readOnly: true
+ } );
+
+ this.embedTextHtml.$element.find( 'textarea' )
+ .prop( 'placeholder', mw.message( 'multimediaviewer-reuse-loading-placeholder' ).text() );
+
+ this.embedTextHtml.$input.on( 'copy', function () {
+ mw.mmv.actionLogger.log( 'embed-html-copied' );
+ } );
+
+ this.embedTextWikitext = new oo.ui.MultilineTextInputWidget( {
+ classes: wikitextClasses,
+ readOnly: true
+ } );
+
+ this.embedTextWikitext.$element.find( 'textarea' )
+ .prop( 'placeholder', mw.message( 'multimediaviewer-reuse-loading-placeholder' ).text() );
+
+ this.embedTextWikitext.$input.on( 'copy', function () {
+ mw.mmv.actionLogger.log( 'embed-wikitext-copied' );
+ } );
+
+ this.$copyButton = $( '<button>' )
+ .addClass( 'mw-mmv-button mw-mmv-dialog-copy' )
+ .click( function () {
+ // Select the text, and then try to copy the text.
+ // If the copy fails or is not supported, continue as if nothing had happened.
+ $( this ).parent().find( '.active > textarea' ).select();
+ try {
+ if ( document.queryCommandSupported &&
+ document.queryCommandSupported( 'copy' ) ) {
+ document.execCommand( 'copy' );
+ }
+ } catch ( e ) {
+ // queryCommandSupported in Firefox pre-41 can throw errors when used with
+ // clipboard commands. We catch and ignore these and other copy-command-related
+ // errors here.
+ }
+ } )
+ .prop( 'title', mw.msg( 'multimediaviewer-reuse-copy-embed' ) )
+ .text( mw.msg( 'multimediaviewer-reuse-copy-embed' ) )
+ .tipsy( {
+ delayIn: mw.config.get( 'wgMultimediaViewer' ).tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } );
+
+ $( '<p>' )
+ .append(
+ this.embedTextHtml.$element,
+ this.embedTextWikitext.$element,
+ this.$copyButton
+ )
+ .appendTo( $container );
+ };
+
+ /**
+ * Creates snippet selection buttons.
+ *
+ * @param {jQuery} $container
+ */
+ EP.createSnippetSelectionButtons = function ( $container ) {
+ var wikitextButtonOption,
+ htmlButtonOption;
+
+ this.embedSwitch = new oo.ui.ButtonSelectWidget( {
+ classes: [ 'mw-mmv-embed-select' ]
+ } );
+
+ wikitextButtonOption = new oo.ui.ButtonOptionWidget( {
+ data: 'wikitext',
+ label: mw.message( 'multimediaviewer-embed-wt' ).text()
+ } );
+ htmlButtonOption = new oo.ui.ButtonOptionWidget( {
+ data: 'html',
+ label: mw.message( 'multimediaviewer-embed-html' ).text()
+ } );
+
+ this.embedSwitch.addItems( [
+ wikitextButtonOption,
+ htmlButtonOption
+ ] );
+
+ $( '<p>' )
+ .append( this.embedSwitch.$element )
+ .appendTo( $container );
+
+ // Logged-out defaults to 'html', logged-in to 'wikitext'
+ this.embedSwitch.selectItem( mw.user.isAnon() ? htmlButtonOption : wikitextButtonOption );
+ };
+
+ /**
+ * Creates pulldown menus to select file sizes.
+ *
+ * @param {jQuery} $container
+ */
+ EP.createSizePulldownMenus = function ( $container ) {
+ var wikitextClasses = [ 'mw-mmv-embed-size' ],
+ htmlClasses = [ 'mw-mmv-embed-size' ];
+
+ ( mw.user.isAnon() ? htmlClasses : wikitextClasses ).push( 'active' );
+
+ // Wikitext sizes pulldown menu
+ this.embedSizeSwitchWikitext = this.utils.createPulldownMenu(
+ [ 'default', 'small', 'medium', 'large' ],
+ wikitextClasses,
+ 'default'
+ );
+
+ this.embedSizeSwitchWikitext.getMenu().on( 'select', function ( item ) {
+ mw.mmv.actionLogger.log( 'embed-select-menu-wikitext-' + item.data.name );
+ } );
+
+ // Html sizes pulldown menu
+ this.embedSizeSwitchHtml = this.utils.createPulldownMenu(
+ [ 'small', 'medium', 'large', 'original' ],
+ htmlClasses,
+ 'original'
+ );
+
+ this.embedSizeSwitchHtml.getMenu().on( 'select', function ( item ) {
+ mw.mmv.actionLogger.log( 'embed-select-menu-html-' + item.data.name );
+ } );
+
+ $( '<p>' )
+ .append(
+ this.embedSizeSwitchHtml.$element,
+ this.embedSizeSwitchWikitext.$element
+ )
+ .appendTo( $container );
+ };
+
+ /**
+ * Registers listeners.
+ */
+ EP.attach = function () {
+ var embed = this,
+ $htmlTextarea = this.embedTextHtml.$element.find( 'textarea' ),
+ $wikitextTextarea = this.embedTextWikitext.$element.find( 'textarea' );
+
+ // Select all text once element gets focus
+ $htmlTextarea.on( 'focus', this.selectAllOnEvent );
+ $wikitextTextarea.on( 'focus', this.selectAllOnEvent );
+ // Disable partial text selection inside the textboxes
+ $htmlTextarea.on( 'mousedown click', this.onlyFocus );
+ $wikitextTextarea.on( 'mousedown click', this.onlyFocus );
+
+ // Register handler for switching between wikitext/html snippets
+ this.embedSwitch.on( 'select', $.proxy( embed.handleTypeSwitch, embed ) );
+
+ // Register handlers for switching between file sizes
+ this.embedSizeSwitchHtml.getMenu().on( 'choose', $.proxy( this.handleSizeSwitch, this ) );
+ this.embedSizeSwitchWikitext.getMenu().on( 'choose', $.proxy( this.handleSizeSwitch, this ) );
+ };
+
+ /**
+ * Clears listeners.
+ */
+ EP.unattach = function () {
+ var $htmlTextarea = this.embedTextHtml.$element.find( 'textarea' ),
+ $wikitextTextarea = this.embedTextWikitext.$element.find( 'textarea' );
+
+ mw.mmv.ui.reuse.Tab.prototype.unattach.call( this );
+
+ $htmlTextarea.off( 'focus mousedown click' );
+ $wikitextTextarea.off( 'focus mousedown click' );
+ this.embedSwitch.off( 'select' );
+ this.embedSizeSwitchHtml.getMenu().off( 'choose' );
+ this.embedSizeSwitchWikitext.getMenu().off( 'choose' );
+ };
+
+ /**
+ * Handles size menu change events.
+ *
+ * @param {OO.ui.MenuOptionWidget} item
+ */
+ EP.handleSizeSwitch = function ( item ) {
+ var value = item.getData();
+
+ this.changeSize( value.width, value.height );
+ };
+
+ /**
+ * Handles snippet type switch.
+ *
+ * @param {OO.ui.MenuOptionWidget} item
+ */
+ EP.handleTypeSwitch = function ( item ) {
+ var value = item.getData();
+
+ mw.mmv.actionLogger.log( 'embed-switched-to-' + value );
+
+ if ( value === 'html' ) {
+ this.$currentMainEmbedText = this.embedTextHtml.$element;
+ this.embedSizeSwitchWikitext.getMenu().toggle( false );
+
+ this.currentSizeMenu = this.embedSizeSwitchHtml.getMenu();
+ this.currentDefaultItem = this.defaultHtmlItem;
+ } else if ( value === 'wikitext' ) {
+ this.$currentMainEmbedText = this.embedTextWikitext.$element;
+ this.embedSizeSwitchHtml.getMenu().toggle( false );
+
+ this.currentSizeMenu = this.embedSizeSwitchWikitext.getMenu();
+ this.currentDefaultItem = this.defaultWikitextItem;
+ }
+
+ this.embedTextHtml.$element
+ .add( this.embedSizeSwitchHtml.$element )
+ .toggleClass( 'active', value === 'html' );
+
+ this.embedTextWikitext.$element
+ .add( this.embedSizeSwitchWikitext.$element )
+ .toggleClass( 'active', value === 'wikitext' );
+
+ // Reset current selection to default when switching the first time
+ if ( !this.isSizeMenuDefaultReset ) {
+ this.resetCurrentSizeMenuToDefault();
+ this.isSizeMenuDefaultReset = true;
+ }
+
+ this.select();
+ };
+
+ /**
+ * Reset current menu selection to default item.
+ */
+ EP.resetCurrentSizeMenuToDefault = function () {
+ this.currentSizeMenu.chooseItem( this.currentDefaultItem );
+ // Force select logic to update the selected item bar, otherwise we end up
+ // with the wrong label. This is implementation dependent and maybe it should
+ // be done via a to flag to OO.ui.SelectWidget.prototype.chooseItem()?
+ this.currentSizeMenu.emit( 'select', this.currentDefaultItem );
+ };
+
+ /**
+ * Changes the size, takes different actions based on which sort of
+ * embed is currently chosen.
+ *
+ * @param {number} width New width to set
+ * @param {number} height New height to set
+ */
+ EP.changeSize = function ( width, height ) {
+ var currentItem = this.embedSwitch.findSelectedItem();
+
+ if ( currentItem === null ) {
+ return;
+ }
+
+ switch ( currentItem.getData() ) {
+ case 'html':
+ this.updateEmbedHtml( {}, width, height );
+ break;
+ case 'wikitext':
+ this.updateEmbedWikitext( width );
+ break;
+ }
+
+ this.select();
+ };
+
+ /**
+ * Sets the HTML embed text.
+ *
+ * Assumes that the set() method has already been called to update this.embedFileInfo
+ *
+ * @param {mw.mmv.model.Thumbnail} thumbnail (can be just an empty object)
+ * @param {number} width New width to set
+ * @param {number} height New height to set
+ */
+ EP.updateEmbedHtml = function ( thumbnail, width, height ) {
+ var src;
+
+ if ( !this.embedFileInfo ) {
+ return;
+ }
+
+ src = thumbnail.url || this.embedFileInfo.imageInfo.url;
+
+ // If the image dimension requested are "large", use the current image url
+ if ( width > EP.LARGE_IMAGE_WIDTH_THRESHOLD || height > EP.LARGE_IMAGE_HEIGHT_THRESHOLD ) {
+ src = this.embedFileInfo.imageInfo.url;
+ }
+
+ this.embedTextHtml.setValue(
+ this.formatter.getThumbnailHtml( this.embedFileInfo, src, width, height ) );
+ };
+
+ /**
+ * Updates the wikitext embed text with a new value for width.
+ *
+ * Assumes that the set method has already been called.
+ *
+ * @param {number} width
+ */
+ EP.updateEmbedWikitext = function ( width ) {
+ if ( !this.embedFileInfo ) {
+ return;
+ }
+
+ this.embedTextWikitext.setValue(
+ this.formatter.getThumbnailWikitextFromEmbedFileInfo( this.embedFileInfo, width )
+ );
+ };
+
+ /**
+ * Shows the pane.
+ */
+ EP.show = function () {
+ mw.mmv.ui.reuse.Tab.prototype.show.call( this );
+ this.select();
+ };
+
+ /**
+ * Gets size options for html and wikitext snippets.
+ *
+ * @param {number} width
+ * @param {number} height
+ * @return {Object}
+ * @return {Object} return.html Collection of possible image sizes for html snippets
+ * @return {Object} return.wikitext Collection of possible image sizes for wikitext snippets
+ */
+ EP.getSizeOptions = function ( width, height ) {
+ var sizes = {};
+
+ sizes.html = this.utils.getPossibleImageSizesForHtml( width, height );
+ sizes.wikitext = this.getPossibleImageSizesForWikitext( width, height );
+
+ return sizes;
+ };
+
+ /**
+ * Sets the data on the element.
+ *
+ * @param {mw.mmv.model.Image} image
+ * @param {mw.mmv.model.Repo} repo
+ * @param {string} caption
+ * @param {string} alt
+ */
+ EP.set = function ( image, repo, caption, alt ) {
+ var embed = this,
+ htmlSizeSwitch = this.embedSizeSwitchHtml.getMenu(),
+ htmlSizeOptions = htmlSizeSwitch.getItems(),
+ wikitextSizeSwitch = this.embedSizeSwitchWikitext.getMenu(),
+ wikitextSizeOptions = wikitextSizeSwitch.getItems(),
+ sizes = this.getSizeOptions( image.width, image.height );
+
+ this.embedFileInfo = new mw.mmv.model.EmbedFileInfo( image, repo, caption, alt );
+
+ this.utils.updateMenuOptions( sizes.html, htmlSizeOptions );
+ this.utils.updateMenuOptions( sizes.wikitext, wikitextSizeOptions );
+
+ // Reset defaults
+ this.isSizeMenuDefaultReset = false;
+ this.resetCurrentSizeMenuToDefault();
+
+ this.utils.getThumbnailUrlPromise( this.LARGE_IMAGE_WIDTH_THRESHOLD )
+ .done( function ( thumbnail ) {
+ embed.updateEmbedHtml( thumbnail );
+ embed.select();
+ } );
+ };
+
+ /**
+ * @inheritdoc
+ */
+ EP.empty = function () {
+ this.embedTextHtml.setValue( '' );
+ this.embedTextWikitext.setValue( '' );
+
+ this.embedSizeSwitchHtml.getMenu().toggle( false );
+ this.embedSizeSwitchWikitext.getMenu().toggle( false );
+ };
+
+ /**
+ * Selects the text in the current textbox by triggering a focus event.
+ */
+ EP.select = function () {
+ this.$currentMainEmbedText.focus();
+ };
+
+ /**
+ * Calculates possible image sizes for wikitext snippets. It returns up to
+ * three possible snippet frame sizes (small, medium, large).
+ *
+ * @param {number} width
+ * @param {number} height
+ * @return {Object}
+ * @return {Object} return.small
+ * @return {Object} return.medium
+ * @return {Object} return.large
+ */
+ EP.getPossibleImageSizesForWikitext = function ( width, height ) {
+ var i, bucketName,
+ bucketWidth,
+ buckets = {
+ small: 300,
+ medium: 400,
+ large: 500
+ },
+ sizes = {},
+ bucketNames = Object.keys( buckets ),
+ widthToHeight = height / width;
+
+ for ( i = 0; i < bucketNames.length; i++ ) {
+ bucketName = bucketNames[ i ];
+ bucketWidth = buckets[ bucketName ];
+
+ if ( width > bucketWidth ) {
+ sizes[ bucketName ] = {
+ width: bucketWidth,
+ height: Math.round( bucketWidth * widthToHeight )
+ };
+ }
+ }
+
+ sizes.default = { width: null, height: null };
+
+ return sizes;
+ };
+
+ mw.mmv.ui.reuse.Embed = Embed;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.less
new file mode 100644
index 00000000..52333e87
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.embed.less
@@ -0,0 +1,77 @@
+@switch-color: #f8f9fa;
+@active-switch-color: #54595d;
+@embed-dimensions-color: #72777d;
+@textarea-text-color: #222;
+
+.mw-mmv-reuse-pane {
+ .mw-mmv-embed-text-html,
+ .mw-mmv-embed-text-wikitext {
+ display: none;
+ width: auto;
+
+ &.active {
+ display: block;
+ }
+
+ // The selector has to be that deep and include [readonly] to override OOUI's definition
+ textarea[ readonly ] {
+ color: @textarea-text-color;
+ text-shadow: none;
+ word-wrap: break-word;
+ }
+ }
+}
+
+.mw-mmv-reuse-dialog .mw-mmv-embed-pane {
+ padding: 20px 27px;
+
+ .mw-mmv-embed-explanation {
+ margin: 10px 0 20px 0;
+ padding: 0;
+ }
+
+ p,
+ textarea {
+ margin: 0;
+ }
+
+ .mw-mmv-dialog-copy {
+ float: right;
+ width: 1.5em;
+ height: 1.5em;
+ margin: 10px 0.75em 20px 0.75em;
+ }
+}
+
+.mw-mmv-embed-switch {
+ div {
+ padding: 1px 3px;
+ background-color: @switch-color;
+
+ &.active {
+ background-color: @active-switch-color;
+ }
+ }
+}
+
+.mw-mmv-embed-size {
+ display: none;
+ margin: 10px 0 0 0;
+
+ &.active {
+ display: block;
+ }
+
+ .oo-ui-widget-disabled {
+ display: none;
+ }
+}
+
+.mw-mmv-embed-dimensions {
+ color: @embed-dimensions-color;
+ font-size: small;
+
+ .oo-ui-optionWidget-selected & {
+ color: lighten( @embed-dimensions-color, 20% ); // selected option has dark background
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.js
new file mode 100644
index 00000000..98b8722a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.js
@@ -0,0 +1,166 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var SP;
+
+ /**
+ * Represents the file reuse dialog and link to open it.
+ *
+ * @class mw.mmv.ui.reuse.Share
+ * @extends mw.mmv.ui.reuse.Tab
+ * @param {jQuery} $container
+ */
+ function Share( $container ) {
+ mw.mmv.ui.reuse.Tab.call( this, $container );
+
+ /**
+ * @property {mw.mmv.routing.Router} router -
+ */
+ this.router = new mw.mmv.routing.Router();
+
+ this.init();
+ }
+ oo.inheritClass( Share, mw.mmv.ui.reuse.Tab );
+ SP = Share.prototype;
+
+ SP.init = function () {
+ var pane = this;
+
+ this.$pane.addClass( 'mw-mmv-share-pane' )
+ .appendTo( this.$container );
+
+ this.pageInput = new oo.ui.TextInputWidget( {
+ classes: [ 'mw-mmv-share-page' ],
+ readOnly: true
+ } );
+
+ this.pageInput.$element.find( 'input' )
+ .prop( 'placeholder', mw.message( 'multimediaviewer-reuse-loading-placeholder' ).text() );
+
+ this.pageInput.$input.on( 'copy', function () {
+ mw.mmv.actionLogger.log( 'share-link-copied' );
+ } );
+
+ this.$pageLink = $( '<a>' )
+ .addClass( 'mw-mmv-share-page-link' )
+ .prop( 'alt', mw.message( 'multimediaviewer-link-to-page' ).text() )
+ .prop( 'target', '_blank' )
+ .html( '&nbsp;' )
+ .appendTo( this.$pane )
+ .click( function () {
+ mw.mmv.actionLogger.log( 'share-page' );
+ } );
+
+ this.$copyButton = $( '<button>' )
+ .addClass( 'mw-mmv-button mw-mmv-dialog-copy' )
+ .click( function () {
+ // Select the text, and then try to copy the text.
+ // If the copy fails or is not supported, continue as if nothing had happened.
+ pane.pageInput.$input.select();
+ try {
+ if ( document.queryCommandSupported &&
+ document.queryCommandSupported( 'copy' ) ) {
+ document.execCommand( 'copy' );
+ }
+ } catch ( e ) {
+ // queryCommandSupported in Firefox pre-41 can throw errors when used with
+ // clipboard commands. We catch and ignore these and other copy-command-related
+ // errors here.
+ }
+ } )
+ .prop( 'title', mw.msg( 'multimediaviewer-reuse-copy-share' ) )
+ .text( mw.msg( 'multimediaviewer-reuse-copy-share' ) )
+ .tipsy( {
+ delayIn: mw.config.get( 'wgMultimediaViewer' ).tooltipDelay,
+ gravity: this.correctEW( 'se' )
+ } )
+ .appendTo( this.$pane );
+
+ this.pageInput.$element.appendTo( this.$pane );
+
+ this.$explanation = $( '<div>' )
+ .addClass( 'mw-mmv-shareembed-explanation' )
+ .text( mw.message( 'multimediaviewer-share-explanation' ).text() )
+ .appendTo( this.$pane );
+
+ this.$pane.appendTo( this.$container );
+ };
+
+ /**
+ * Shows the pane.
+ */
+ SP.show = function () {
+ mw.mmv.ui.reuse.Tab.prototype.show.call( this );
+ this.select();
+ };
+
+ /**
+ * @inheritdoc
+ * @param {mw.mmv.model.Image} image
+ */
+ SP.set = function ( image ) {
+ var route = new mw.mmv.routing.ThumbnailRoute( image.title ),
+ url = this.router.createHashedUrl( route, image.descriptionUrl );
+
+ this.pageInput.setValue( url );
+
+ this.select();
+
+ this.$pageLink.prop( 'href', url );
+ };
+
+ /**
+ * @inheritdoc
+ */
+ SP.empty = function () {
+ this.pageInput.setValue( '' );
+ this.$pageLink.prop( 'href', null );
+ };
+
+ /**
+ * @inheritdoc
+ */
+ SP.attach = function () {
+ var $input = this.pageInput.$element.find( 'input' );
+
+ $input.on( 'focus', this.selectAllOnEvent );
+ // Disable partial text selection inside the textbox
+ $input.on( 'mousedown click', this.onlyFocus );
+ };
+
+ /**
+ * @inheritdoc
+ */
+ SP.unattach = function () {
+ var $input = this.pageInput.$element.find( 'input' );
+
+ mw.mmv.ui.reuse.Tab.prototype.unattach.call( this );
+
+ $input.off( 'focus mousedown click' );
+ };
+
+ /**
+ * Selects the text in the readonly textbox by triggering a focus event.
+ */
+ SP.select = function () {
+ this.pageInput.$element.focus();
+ };
+
+ mw.mmv.ui.reuse.Share = Share;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.less
new file mode 100644
index 00000000..fac60a81
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.share.less
@@ -0,0 +1,49 @@
+@input-text-color: #222;
+
+.mw-mmv-share-pane {
+ .mw-mmv-share-page {
+ // override OOUI fixed width
+ width: auto;
+ // make sure this is a new block formatting context so that the float shrinks it instead of
+ // running into it and pushing the input down (there is probably a better way of doing this)
+ overflow: hidden;
+
+ // The selector has to be that deep and include [readonly] to override OOUI's definition
+ input[ readonly ] {
+ color: @input-text-color;
+ text-shadow: none;
+ }
+ }
+
+ .mw-mmv-dialog-copy {
+ // style rules based on .mw-mmv-share-page-link
+ float: right;
+ width: 2em;
+ height: 2em;
+ // position approximately to the middle - probably fragile but couldn't find a better way as
+ // the height of OOUI input widget has both em and px parts and not possible to calculate
+ // exactly
+ margin: 8px 0.5em;
+ }
+}
+
+.mw-mmv-share-page-link {
+ float: left;
+ width: 1.5em;
+ height: 1.5em;
+ // position approximately to the middle - probably fragile but couldn't find a better way as the
+ // height of OOUI input widget has both em and px parts and not possible to calculate exactly
+ margin: 8px 0;
+ padding: 0 5px 0 0;
+ /* @embed */
+ background-image: url( img/link.svg );
+ background-size: contain;
+ background-position: left center;
+ background-repeat: no-repeat;
+
+ &:hover {
+ /* @embed */
+ background-image: url( img/link-hover.svg );
+ text-decoration: none;
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.shareembed.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.shareembed.less
new file mode 100644
index 00000000..d5c68919
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.shareembed.less
@@ -0,0 +1,8 @@
+@explanation-color: #72777d;
+
+.mw-mmv-shareembed-explanation {
+ color: @explanation-color;
+ font-size: 0.9em;
+ margin-left: 1.5em;
+ padding: 5px 8px;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.tab.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.tab.js
new file mode 100644
index 00000000..74735c04
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.reuse.tab.js
@@ -0,0 +1,57 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var TP;
+
+ /**
+ * A tab in a mw.mmv.ui.Pane component
+ *
+ * @class mw.mmv.ui.reuse.Tab
+ * @extends mw.mmv.ui.Element
+ * @param {jQuery} $container
+ * @constructor
+ */
+ function Tab( $container ) {
+ Tab.super.call( this, $container );
+
+ /**
+ * Container for the tab.
+ * @property {jQuery}
+ */
+ this.$pane = $( '<div>' ).addClass( 'mw-mmv-reuse-pane' );
+
+ }
+ oo.inheritClass( Tab, mw.mmv.ui.Element );
+ TP = Tab.prototype;
+
+ /**
+ * Shows the pane.
+ */
+ TP.show = function () {
+ this.$pane.addClass( 'active' );
+ };
+
+ /**
+ * Hides the pane.
+ */
+ TP.hide = function () {
+ this.$pane.removeClass( 'active' );
+ };
+
+ mw.mmv.ui.reuse.Tab = Tab;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.js
new file mode 100644
index 00000000..75497df9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.js
@@ -0,0 +1,136 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var SBP;
+
+ /**
+ * Class for buttons which are placed on the metadata stripe (the always visible part of the
+ * metadata panel).
+ *
+ * @class mw.mmv.ui.StripeButtons
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container the title block (.mw-mmv-title-contain) which wraps the buttons and all
+ * other title elements
+ */
+ function StripeButtons( $container ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ this.$buttonContainer = $( '<div>' )
+ .addClass( 'mw-mmv-stripe-button-container' )
+ .appendTo( $container );
+
+ /**
+ * This holds the actual buttons.
+ * @property {Object.<string, jQuery>}
+ */
+ this.buttons = {};
+
+ this.initDescriptionPageButton();
+ }
+ oo.inheritClass( StripeButtons, mw.mmv.ui.Element );
+ SBP = StripeButtons.prototype;
+
+ /**
+ * Creates a new button on the metadata stripe.
+ *
+ * @protected
+ * @param {string} cssClass CSS class name for the button
+ * @return {jQuery} Button
+ */
+ SBP.createButton = function ( cssClass ) {
+ var $button;
+
+ $button = $( '<a>' )
+ .addClass( 'mw-mmv-stripe-button empty ' + cssClass )
+ // elements are right-floated so we use prepend instead of append to keep the order
+ .prependTo( this.$buttonContainer )
+ .attr( 'tabindex', '0' );
+
+ return $button;
+ };
+
+ /**
+ * Creates a button linking to the file description page.
+ *
+ * @protected
+ */
+ SBP.initDescriptionPageButton = function () {
+ this.buttons.$descriptionPage = this.createButton(
+ 'empty mw-mmv-description-page-button mw-ui-big mw-ui-button mw-ui-progressive'
+ ).click( function () {
+ mw.mmv.actionLogger.log( 'file-description-page-abovefold' );
+ } );
+ };
+
+ /**
+ * Runs code for each button, similarly to $.each.
+ *
+ * @protected
+ * @param {function(jQuery, string)} callback a function that will be called with each button
+ */
+ SBP.eachButton = function ( callback ) {
+ var buttonName;
+ for ( buttonName in this.buttons ) {
+ callback( this.buttons[ buttonName ], buttonName );
+ }
+ };
+
+ /**
+ * @inheritdoc
+ * @param {mw.mmv.model.Image} imageInfo
+ * @param {mw.mmv.model.Repo} repoInfo
+ */
+ SBP.set = function ( imageInfo, repoInfo ) {
+ this.eachButton( function ( $button ) {
+ $button.removeClass( 'empty' );
+ } );
+
+ this.setDescriptionPageButton( imageInfo, repoInfo );
+ };
+
+ /**
+ * Updates the button linking to the file page.
+ *
+ * @protected
+ * @param {mw.mmv.model.Image} imageInfo
+ * @param {mw.mmv.model.Repo} repoInfo
+ */
+ SBP.setDescriptionPageButton = function ( imageInfo, repoInfo ) {
+ var $button = this.buttons.$descriptionPage;
+
+ $button.text( mw.message( 'multimediaviewer-repository-local' ).text() )
+ .attr( 'href', imageInfo.descriptionUrl );
+
+ $button.toggleClass( 'mw-mmv-repo-button-commons', repoInfo.isCommons() );
+ };
+
+ /**
+ * @inheritdoc
+ */
+ SBP.empty = function () {
+ this.eachButton( function ( $button ) {
+ $button.addClass( 'empty' );
+ } );
+
+ this.buttons.$descriptionPage.attr( { href: null, title: null, 'original-title': null } )
+ .removeClass( 'mw-mmv-repo-button-commons' );
+ };
+
+ mw.mmv.ui.StripeButtons = StripeButtons;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.less
new file mode 100644
index 00000000..e9d4f66c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.stripeButtons.less
@@ -0,0 +1,68 @@
+@import '../mmv.globals';
+@import '../mmv.mixins';
+
+@button-vertical-padding: 20px;
+@button-height: 25px;
+@repo-button-width: 50px;
+
+// The buttons need to be positioned to the bottom right corner of .mw-mmv-title-contain, and
+// other text in that element must not overlap them. Their width is not known (depends on the
+// translation) so we float them to the right and calculate the top margin required to make them
+// full height.
+.mw-mmv-stripe-button {
+ @button-text-color: #888;
+
+ float: right;
+ margin-top: @metadatabar-above-fold-inner-height - ( @button-height + 2 * @button-vertical-padding );
+
+ .unselectable;
+ font-size: 1.25em;
+ color: @button-text-color;
+ cursor: pointer;
+ transition: opacity 0.25s;
+
+ &.empty {
+ display: none;
+ }
+
+ &:before {
+ display: inline-block;
+ width: 1em;
+ height: 1em;
+
+ // fix odd position caused by bottom of icon and bottom of SVG not being aligned
+ position: relative;
+ top: 0.1em;
+
+ background-size: 100% 100%;
+ content: ' ';
+ vertical-align: baseline;
+
+ /* @embed */
+ background-image: url( img/page.svg );
+
+ margin-right: 0.7em;
+ }
+ &.has-label:before {
+ margin-right: 0.25em;
+ }
+
+ &.mw-mmv-description-page-button,
+ &.mw-mmv-description-page-button:active,
+ &.mw-mmv-description-page-button:visited {
+ border-radius: @border-radius;
+ color: #fff;
+ padding: 7px 16px;
+ margin: 7px 10px;
+ }
+
+ &.mw-mmv-description-page-button.mw-mmv-repo-button-commons:before {
+ /* @embed */
+ background-image: url( img/commons_white.svg );
+ width: 1.3em;
+ height: 1.3em;
+ position: relative;
+ top: 0.15em;
+ margin: -0.3em 0.4em 0 0;
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.js
new file mode 100644
index 00000000..8202d5e7
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.js
@@ -0,0 +1,202 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+( function ( mw, $, oo ) {
+ var TDP;
+
+ /**
+ * A simple popup dialog that can be opened and closed and can contain some HTML.
+ * Due to the way tipsy works, there can be only one TipsyDialog and/or tipsy tooltip on the same element.
+ *
+ * @class mw.mmv.ui.TipsyDialog
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $anchor the element to which the popup is anchored.
+ * @param {Object} options takes any tipsy option - see
+ * https://github.com/jaz303/tipsy/blob/master/docs/src/index.html.erb#L298
+ */
+ function TipsyDialog( $anchor, options ) {
+ mw.mmv.ui.Element.call( this, null ); // tipsy does the element construction so we don't need a container
+
+ /** @property {jQuery} $anchor - */
+ this.$anchor = $anchor;
+
+ /** @property {Object} options - */
+ this.options = $.extend( {}, this.defaultOptions, options );
+
+ /** @property {boolean} dirty Track whether tipsy settings changed and need to be reinitialized. */
+ this.dirty = false;
+
+ /** @property {string|null} contentTitle Title of the dialog (optional) */
+ this.contentTitle = null;
+
+ /** @property {string|null} contentBody Contents of the dialog */
+ this.contentBody = null;
+
+ /** @property {Function} closeProxy Proxied close function to be used as an event handler, so it can be
+ * identified for removal. */
+ this.closeProxy = $.proxy( this.maybeCloseOnClick, this );
+ }
+
+ oo.inheritClass( TipsyDialog, mw.mmv.ui.Element );
+ TDP = TipsyDialog.prototype;
+
+ /**
+ * @property {Object} defaultOptions Tipsy defaults - see
+ * https://github.com/jaz303/tipsy/blob/master/docs/src/index.html.erb#L298
+ */
+ TDP.defaultOptions = {
+ // tipsy options
+ trigger: 'manual',
+ html: true,
+ fade: false,
+ offset: 0,
+ gravity: 'sw'
+ };
+
+ /**
+ * @property {number} extraOffset offset adjustment to correct for the larger margins and tip size
+ * compared to the standard tipsy style
+ */
+ TDP.extraOffset = 10;
+
+ /**
+ * @private
+ * @return {boolean}
+ */
+ TDP.isInitialized = function () {
+ return !!this.$anchor.tipsy( true );
+ };
+
+ /**
+ * Returns the preprocessed version of an options object:
+ * - directions are flipped on RTL documents
+ * - standard classnames are applied
+ * - HTML content is generated
+ * The original object is not changed.
+ *
+ * @private
+ * @param {Object} originalOptions
+ * @return {Object} Preprocessed options
+ */
+ TDP.getPreprocessedOptions = function ( originalOptions ) {
+ var options = $.extend( {}, originalOptions );
+
+ if ( options.className ) {
+ options.className += ' mw-mmv-tipsy-dialog';
+ } else {
+ options.className = ' mw-mmv-tipsy-dialog';
+ }
+ options.gravity = this.correctEW( options.gravity );
+ options.offset += this.extraOffset;
+ options.fallback = this.generateContent( this.contentTitle, this.contentBody );
+
+ return options;
+ };
+
+ /**
+ * @private
+ */
+ TDP.init = function () {
+ var options;
+
+ if ( !this.isInitialized() || this.dirty ) {
+ options = this.getPreprocessedOptions( this.options );
+ this.$anchor.tipsy( options );
+
+ // add click handler to close the popup when clicking on X or outside
+ // off is to make sure we won't end up with more then one - init() can be called multiple times
+ this.$anchor.find( '.mw-mmv-tipsy-dialog-disable' ).add( document )
+ .off( 'click.mmv-tipsy-dialog', this.closeProxy )
+ .on( 'click.mmv-tipsy-dialog', this.closeProxy );
+
+ this.dirty = false;
+ }
+ };
+
+ /**
+ * Open the dialog
+ */
+ TDP.open = function () {
+ this.init();
+ this.$anchor.tipsy( 'enable' ).tipsy( 'show' );
+ };
+
+ /**
+ * Close the dialog
+ */
+ TDP.close = function () {
+ if ( this.isInitialized() ) {
+ this.$anchor.tipsy( 'hide' ).tipsy( 'disable' );
+ }
+ };
+
+ /**
+ * Return the main popup element.
+ *
+ * @return {jQuery|null}
+ */
+ TDP.getPopup = function () {
+ var tipsyData = this.$anchor.tipsy( true );
+
+ return tipsyData ? tipsyData.$tip : null;
+ };
+
+ /**
+ * Set dialog contents
+ *
+ * @param {string|null} title title of the dialog (plain text; escaping will be handled by TipsyDialog)
+ * @param {string|null} body content of the dialog (HTML; no escaping)
+ */
+ TDP.setContent = function ( title, body ) {
+ this.contentTitle = title;
+ this.contentBody = body;
+ this.dirty = true;
+ };
+
+ /**
+ * @private
+ * @param {string} [title]
+ * @param {string} [body]
+ * @return {string}
+ */
+ TDP.generateContent = function ( title, body ) {
+ body = body || '';
+ if ( title ) {
+ body = '<div class="mw-mmv-tipsy-dialog-title">' + mw.html.escape( title ) + '</div>' + body;
+ }
+ return '<div class="mw-mmv-tipsy-dialog-disable"></div>' + body;
+ };
+
+ /**
+ * Click handler to be set on the document.
+ *
+ * @private
+ * @param {jQuery.Event} event
+ */
+ TDP.maybeCloseOnClick = function ( event ) {
+ var $clickTarget = $( event.target );
+
+ if (
+ $clickTarget.closest( this.getPopup() ).length === 0 || // click was outside the dialog
+ $clickTarget.closest( '.mw-mmv-tipsy-dialog-disable' ).length > 0 // click was on the close icon
+ ) {
+ this.close();
+ }
+ };
+
+ mw.mmv.ui.TipsyDialog = TipsyDialog;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.less
new file mode 100644
index 00000000..bd21a13b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.tipsyDialog.less
@@ -0,0 +1,56 @@
+@import '../mmv.globals';
+@import '../mmv.mixins';
+
+.mw-mmv-tipsy-dialog {
+ @arrow-height: 8px;
+ @background-color: #eaecf0;
+ @border-color: #a2a9b1;
+ @padding: 20px; // must be larger than @arrow-height / sqrt(2), otherwise the arrow overlaps the text
+
+ padding-bottom: @arrow-height; // the actual arrow height is @arrow-height / sqrt(2)
+
+ .tipsy-inner {
+ max-width: 400px;
+ background-color: @background-color;
+ border: 1px solid @border-color;
+ border-radius: @border-radius;
+ padding: @padding;
+ color: #54595d;
+
+ .mw-mmv-tipsy-dialog-title {
+ margin-bottom: 1em;
+ color: #222;
+ font-size: 130%;
+ }
+ }
+
+ .tipsy-arrow {
+ width: 2 * @arrow-height;
+ height: 2 * @arrow-height;
+ position: absolute;
+ bottom: 0;
+ left: 10px + @arrow-height;
+ background: @background-color;
+ border: 1px solid @border-color;
+ border-width: 0 0 1px 1px;
+ .rotate( -45deg );
+ }
+
+ .mw-mmv-tipsy-dialog-disable {
+ @distanceFromBorder: 8px;
+ @topRightMargin: @distanceFromBorder - @padding;
+ width: 15px;
+ height: 15px;
+ float: right;
+ margin: @topRightMargin @topRightMargin @padding @padding;
+ cursor: pointer;
+ /* @embed */
+ background-image: url( img/x_gray.svg );
+ background-repeat: no-repeat;
+ opacity: 0.75;
+
+ &:hover {
+ opacity: 1;
+ }
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.js
new file mode 100644
index 00000000..c14b4a98
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.js
@@ -0,0 +1,240 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var TTFP;
+
+ /**
+ * Represents any text field that might need to be truncated to be readable. Text will be adjusted to
+ * fit into its container.
+ *
+ * More specifically, TruncatableTextField should be invoked with a fixed-height container as the first
+ * parameter and a flexible-width content (which gets its size from the text inside it) as the second
+ * one. The container gets overflow: hidden, and the content is placed inside it; if the content
+ * overflows the container, TruncatableTextField will cycle through a set of styles and apply to the
+ * container the first one that makes the content not overflow anymore. If none of the styles do that,
+ * the last one is applied anyway.
+ *
+ * The list of styles can be customized; by default, they set progressively smaller font size, and the
+ * last one adds an ellipsis to the end. (An ellipsis element is automatically appended to the end of
+ * the container to help with this, but it is hidden unless made visible by one of the styles.)
+ *
+ * grow() and shrink() can be used to show full text (by making the container flexible-height) and hiding
+ * them again; TruncatableTextField will not call them automatically (the caller class should e.g. set up
+ * a click handler on the ellipsis).
+ *
+ * repaint() should be called after layout changes to keep the truncation accurate.
+ *
+ * @class mw.mmv.ui.TruncatableTextField
+ * @extends mw.mmv.ui.Element
+ * @constructor
+ * @param {jQuery} $container The container for the element.
+ * @param {jQuery} $element The element where we should put the text.
+ * @param {Object} [options]
+ * @param {string[]} [options.styles] a list of styles to try if the text does not fit into the container.
+ * Will stop at the first which makes the text fit; the last one will be used even if it does not make
+ * the text fit.
+ */
+ function TruncatableTextField( $container, $element, options ) {
+ mw.mmv.ui.Element.call( this, $container );
+
+ /** @property {jQuery} $element The DOM element that holds text for this element. */
+ this.$element = $element;
+
+ /** @property {Object} options - */
+ this.options = $.extend( {}, this.defaultOptions, options );
+
+ /** @property {boolean} expanded true if the text is long enough to be truncated but the full text is shown */
+ this.expanded = false;
+
+ /** @property {jQuery} ellipsis the element which marks that the text was truncated */
+ this.$ellipsis = null;
+
+ /** @property {string} normalTitle title attribute to show when the text is not truncated */
+ this.normalTitle = null;
+
+ /** @property {string} truncatedTitle title attribute to show when the text is not truncated */
+ this.truncatedTitle = null;
+
+ /** @property {mw.mmv.HtmlUtils} htmlUtils Our HTML utility instance. */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+
+ this.init();
+ }
+
+ oo.inheritClass( TruncatableTextField, mw.mmv.ui.Element );
+
+ TTFP = TruncatableTextField.prototype;
+
+ /**
+ * Default options
+ * @property {Object} defaultOptions
+ */
+ TTFP.defaultOptions = {
+ styles: [ 'mw-mmv-ttf-small', 'mw-mmv-ttf-smaller', 'mw-mmv-ttf-smallest' ]
+ };
+
+ /**
+ * Initializes the DOM.
+ *
+ * @private
+ */
+ TTFP.init = function () {
+ this.$ellipsis = $( '<span>' )
+ .text( '…' )
+ .hide()
+ .addClass( 'mw-mmv-ttf-ellipsis' );
+
+ this.$container
+ .addClass( 'mw-mmv-ttf-container empty' )
+ .append( this.$element, this.$ellipsis );
+ };
+
+ TTFP.attach = function () {
+ $( window ).on( 'resize.mmv-ttf', $.debounce( 100, $.proxy( this.repaint, this ) ) );
+ };
+
+ TTFP.unattach = function () {
+ $( window ).off( 'resize.mmv-ttf' );
+ };
+
+ /**
+ * Sets the string for the element.
+ *
+ * @param {string} value Warning - unsafe HTML is allowed here.
+ */
+ TTFP.set = function ( value ) {
+ this.$element.empty().append( this.htmlUtils.htmlToTextWithTags( value ) );
+ this.changeStyle();
+ this.$container.toggleClass( 'empty', !value );
+ this.$ellipsis.hide();
+ this.shrink();
+ };
+
+ TTFP.empty = function () {
+ this.$element.empty();
+ this.$container
+ .removeClass( this.options.styles.join( ' ' ) )
+ .removeClass( 'mw-mmv-ttf-untruncated mw-mmv-ttf-truncated' )
+ .addClass( 'empty' );
+ this.$ellipsis.hide();
+ this.setTitle( '', '' );
+ this.expanded = false;
+ };
+
+ /**
+ * Recalculate truncation after layout changes (such as resize)
+ */
+ TTFP.repaint = function () {
+ this.changeStyle();
+ this.$ellipsis.hide();
+ this.shrink();
+ };
+
+ /**
+ * Allows setting different titles for fully visible and for truncated text.
+ *
+ * @param {string} normal
+ * @param {string} truncated
+ */
+ TTFP.setTitle = function ( normal, truncated ) {
+ this.normalTitle = normal;
+ this.truncatedTitle = truncated;
+ this.updateTitle();
+ };
+
+ /**
+ * Selects the right title to use (for full or for truncated version). The title can be set with setTitle().
+ */
+ TTFP.updateTitle = function () {
+ var $elementsWithTitle = this.$element.add( this.$ellipsis );
+ $elementsWithTitle.attr( 'original-title', this.isTruncated() ? this.truncatedTitle : this.normalTitle );
+ };
+
+ /**
+ * Returns true if the text is long enough that it needs to be truncated.
+ *
+ * @return {boolean}
+ */
+ TTFP.isTruncatable = function () {
+ // height calculation logic does not work for expanded state since the container expands
+ // to envelop the element, but we never go into expanded state for non-truncatable elements anyway
+ return this.$container.height() < this.$element.height() || this.expanded;
+ };
+
+ /**
+ * Returns true if the text is truncated at the moment.
+ *
+ * @return {boolean}
+ */
+ TTFP.isTruncated = function () {
+ return this.isTruncatable() && !this.expanded;
+ };
+
+ /**
+ * Makes the container fixed-width, clipping the text.
+ * This will only add a .mw-mmv-ttf-truncated class; it's the caller's responsibility to define the fixed
+ * height for that class.
+ */
+ TTFP.shrink = function () {
+ if ( this.isTruncatable() ) {
+ this.expanded = false;
+ this.$container.addClass( 'mw-mmv-ttf-truncated' ).removeClass( 'mw-mmv-ttf-untruncated' );
+ this.$ellipsis.show();
+ this.updateTitle();
+ }
+ };
+
+ /**
+ * Makes the container flexible-width, thereby restoring the full text.
+ */
+ TTFP.grow = function () {
+ if ( this.isTruncatable() ) {
+ this.expanded = true;
+ this.$container.removeClass( 'mw-mmv-ttf-truncated' ).addClass( 'mw-mmv-ttf-untruncated' );
+ this.$ellipsis.hide();
+ this.updateTitle();
+ }
+ };
+
+ /**
+ * Changes the element style if a certain length is reached.
+ */
+ TTFP.changeStyle = function () {
+ var oldClass,
+ newClass = 'mw-mmv-ttf-normal',
+ field = this;
+
+ this.$container
+ .removeClass( this.options.styles.join( ' ' ) )
+ .removeClass( 'mw-mmv-ttf-untruncated mw-mmv-ttf-truncated' )
+ .addClass( newClass );
+ this.expanded = false;
+
+ $.each( this.options.styles, function ( k, v ) {
+ if ( !field.isTruncatable() ) {
+ return false;
+ }
+
+ oldClass = newClass;
+ newClass = v;
+ field.$container.removeClass( oldClass ).addClass( newClass );
+ } );
+ };
+
+ mw.mmv.ui.TruncatableTextField = TruncatableTextField;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.less
new file mode 100644
index 00000000..f3a5f77e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.truncatableTextField.less
@@ -0,0 +1,74 @@
+@import 'mediawiki.mixins';
+@import '../mmv.globals';
+@import '../mmv.mixins';
+
+.mw-mmv-ttf-container {
+ position: relative;
+ overflow: hidden; // need to create a block formatting context, otherwise adjacent floats would be problematic
+
+ &.mw-mmv-ttf-small {
+ font-size: 90%;
+ }
+
+ &.mw-mmv-ttf-smaller {
+ font-size: 80%;
+ }
+
+ &.mw-mmv-ttf-smallest {
+ font-size: 65%;
+ }
+
+ // used on containers which have been shortened and can be expanded
+ &.mw-mmv-ttf-truncated {
+ cursor: pointer;
+ }
+
+ // used on containers which have been expanded
+ &.mw-mmv-ttf-untruncated {
+ height: auto;
+ }
+
+ .mw-mmv-ttf-ellipsis {
+ display: block;
+ position: absolute;
+ right: 0;
+ bottom: 0;
+ height: 1em; // make it scale with the font
+ width: 1.5em; // SVG image has ~1.5 aspect ratio
+ text-indent: -9999px;
+ border-radius: @border-radius;
+ background-size: contain;
+ background-position: center center;
+ background-repeat: no-repeat;
+ /* @embed */
+ background-image: url( img/ellipsis_lightgray.svg );
+ .box-shadow( -4px 6px 0 0 #fff );
+
+ // Hovering over .mw-mmv-ttf-ellipsis-container will make the ellipsis more visible to attract
+ // attention to it. Since it has to be set on a parent element which is not under control of
+ // TruncatableTextField, setting it is the caller's responsibility.
+ .mw-mmv-ttf-ellipsis-container:hover & {
+ background-color: #eaecf0;
+ /* @embed */
+ background-image: url( img/ellipsis_gray.svg );
+ }
+ // second rule + ordering needed for specificity
+ &:hover,
+ .mw-mmv-ttf-ellipsis-container &:hover {
+ background-color: #c8ccd1;
+ /* @embed */
+ background-image: url( img/ellipsis_darkgray.svg );
+ }
+
+ &:before {
+ @fade-length: 2em;
+
+ display: block;
+ content: '';
+ height: 1.6em; // 1em would not cover high glyphs
+ width: @fade-length;
+ margin-left: -@fade-length;
+ .fade-out-horizontal();
+ }
+ }
+}
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.utils.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.utils.js
new file mode 100644
index 00000000..31af3872
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.utils.js
@@ -0,0 +1,210 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ var RUP;
+
+ /**
+ * A helper class for reuse logic.
+ *
+ * @class mw.mmv.ui.Utils
+ * @constructor
+ */
+ function Utils() {
+ /** @property {mw.mmv.HtmlUtils} htmlUtils - */
+ this.htmlUtils = new mw.mmv.HtmlUtils();
+ }
+
+ RUP = Utils.prototype;
+
+ /**
+ * Creates pulldown menu from given options.
+ *
+ * @param {string[]} options
+ * @param {string[]} classes
+ * @param {string} def
+ * @return {OO.ui.DropdownWidget}
+ */
+ RUP.createPulldownMenu = function ( options, classes, def ) {
+ var dropdown, i, option,
+ items = [],
+ choices = {};
+
+ dropdown = new oo.ui.DropdownWidget( {
+ classes: classes
+ } );
+
+ for ( i = 0; i < options.length; i++ ) {
+ option = options[ i ];
+
+ choices[ option ] = new oo.ui.MenuOptionWidget( {
+ data: {
+ name: option,
+ height: null,
+ width: null
+ },
+ label: this.getDimensionsMessageHtml( option, 0, 0 ),
+ autoFitLabel: false
+ } );
+
+ items.push( choices[ option ] );
+ }
+
+ dropdown.getMenu()
+ .addItems( items )
+ .chooseItem( choices[ def ] );
+
+ return dropdown;
+ };
+
+ /**
+ * Gets a promise for the large thumbnail URL. This is needed because thumbnail URLs cannot
+ * be reliably guessed, even if we know the full size of the image - most of the time replacing
+ * the size in another thumbnail URL works (as long as the new size is not larger than the full
+ * size), but if the file name is very long and with the larger size the URL length would
+ * exceed a certain threshold, a different schema is used instead.
+ *
+ * @param {number} width
+ *
+ * @return {jQuery.Promise.<string>}
+ */
+ RUP.getThumbnailUrlPromise = function ( width ) {
+ return $( document ).triggerHandler( 'mmv-request-thumbnail', width ) ||
+ $.Deferred().reject();
+ };
+
+ /**
+ * Updates the menu options based on calculated sizes.
+ *
+ * @private
+ * @param {Object} sizes
+ * @param {OO.ui.MenuOptionWidget[]} options
+ */
+ RUP.updateMenuOptions = function ( sizes, options ) {
+ var i, option, data, $label;
+
+ for ( i = 0; i < options.length; i++ ) {
+ option = options[ i ];
+ data = option.getData();
+
+ if ( sizes[ data.name ] ) {
+ option.setDisabled( false );
+
+ // These values are later used when the item is selected
+ data.width = sizes[ data.name ].width;
+ data.height = sizes[ data.name ].height;
+
+ $label = $( '<span>' ).html( this.getDimensionsMessageHtml( data.name, data.width, data.height ) );
+
+ option.setLabel( $label );
+ } else {
+ option.setDisabled( true );
+ }
+ }
+ };
+
+ /**
+ * Calculates possible image sizes for html snippets. It returns up to
+ * three possible snippet frame sizes (small, medium, large) plus the
+ * original image size.
+ *
+ * @param {number} width
+ * @param {number} height
+ * @return {Object}
+ * @return {Object} return.small
+ * @return {Object} return.medium
+ * @return {Object} return.large
+ * @return {Object} return.original
+ */
+ RUP.getPossibleImageSizesForHtml = function ( width, height ) {
+ var i, bucketName,
+ currentGuess, dimensions,
+ bucketWidth, bucketHeight,
+ buckets = {
+ small: { width: 220, height: 145 },
+ medium: { width: 640, height: 480 },
+ large: { width: 1200, height: 900 }
+ },
+ sizes = {},
+ bucketNames = Object.keys( buckets ),
+ widthToHeight = height / width,
+ heightToWidth = width / height;
+
+ for ( i = 0; i < bucketNames.length; i++ ) {
+ bucketName = bucketNames[ i ];
+ dimensions = buckets[ bucketName ];
+ bucketWidth = dimensions.width;
+ bucketHeight = dimensions.height;
+
+ if ( width > bucketWidth ) {
+ // Width fits in the current bucket
+ currentGuess = bucketWidth;
+
+ if ( currentGuess * widthToHeight > bucketHeight ) {
+ // Constrain in height, resize width accordingly
+ sizes[ bucketName ] = {
+ width: Math.round( bucketHeight * heightToWidth ),
+ height: bucketHeight
+ };
+ } else {
+ sizes[ bucketName ] = {
+ width: currentGuess,
+ height: Math.round( currentGuess * widthToHeight )
+ };
+ }
+ } else if ( height > bucketHeight ) {
+ // Height fits in the current bucket, resize width accordingly
+ sizes[ bucketName ] = {
+ width: Math.round( bucketHeight * heightToWidth ),
+ height: bucketHeight
+ };
+ }
+ }
+
+ sizes.original = { width: width, height: height };
+
+ return sizes;
+ };
+
+ /**
+ * Generates an i18n message for a label, given a size label and image dimensions
+ *
+ * @param {string} sizeLabel
+ * @param {number} width
+ * @param {number} height
+ * @return {string} i18n label html
+ */
+ RUP.getDimensionsMessageHtml = function ( sizeLabel, width, height ) {
+ var dimensions = this.htmlUtils.jqueryToHtml( $( '<span>' )
+ .addClass( 'mw-mmv-embed-dimensions' )
+ .text(
+ mw.message(
+ 'multimediaviewer-embed-dimensions-separated',
+ mw.message(
+ 'multimediaviewer-embed-dimensions',
+ width, height ).text()
+ ).text()
+ ) );
+
+ return mw.message(
+ 'multimediaviewer-' + sizeLabel + '-embed-dimensions',
+ dimensions
+ ).text();
+ };
+
+ mw.mmv.ui.Utils = Utils;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.js b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.js
new file mode 100644
index 00000000..61d89722
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.js
@@ -0,0 +1,397 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $, oo ) {
+ // Shortcut for prototype later
+ var ODP;
+
+ /**
+ * Represents the viewing options dialog and the link to open it.
+ *
+ * @class mw.mmv.ui.OptionsDialog
+ * @extends mw.mmv.ui.Dialog
+ * @param {jQuery} $container the element to which the dialog will be appended
+ * @param {jQuery} $openButton the button which opens the dialog. Only used for positioning.
+ * @param {mw.mmv.Config} config
+ */
+ function OptionsDialog( $container, $openButton, config ) {
+ mw.mmv.ui.Dialog.call( this, $container, $openButton, config );
+
+ this.$dialog.addClass( 'mw-mmv-options-dialog' );
+ this.eventPrefix = 'options';
+
+ this.initPanel();
+ }
+
+ oo.inheritClass( OptionsDialog, mw.mmv.ui.Dialog );
+ ODP = OptionsDialog.prototype;
+
+ ODP.attach = function () {
+ this.handleEvent( 'mmv-options-open', $.proxy( this.handleOpenCloseClick, this ) );
+
+ this.handleEvent( 'mmv-reuse-open', $.proxy( this.closeDialog, this ) );
+ this.handleEvent( 'mmv-download-open', $.proxy( this.closeDialog, this ) );
+ };
+
+ /**
+ * Initialises UI elements.
+ */
+ ODP.initPanel = function () {
+ this.initEnableConfirmation();
+ this.initDisableConfirmation();
+ this.initEnableDiv();
+ this.initDisableDiv();
+ };
+
+ /**
+ * Initialises the enable confirmation pane.
+ */
+ ODP.initEnableConfirmation = function () {
+ this.createConfirmationPane(
+ 'mw-mmv-enable-confirmation',
+ '$enableConfirmation',
+ [
+ mw.message( 'multimediaviewer-enable-confirmation-header' ).text(),
+ mw.message( 'multimediaviewer-enable-confirmation-text', mw.config.get( 'wgSiteName' ) ).text()
+ ] );
+ };
+
+ /**
+ * Initialises the disable confirmation pane.
+ */
+ ODP.initDisableConfirmation = function () {
+ this.createConfirmationPane(
+ 'mw-mmv-disable-confirmation',
+ '$disableConfirmation',
+ [
+ mw.message( 'multimediaviewer-disable-confirmation-header' ).text(),
+ mw.message( 'multimediaviewer-disable-confirmation-text', mw.config.get( 'wgSiteName' ) ).text()
+ ] );
+ };
+
+ /**
+ * Initialises the enable action pane.
+ */
+ ODP.initEnableDiv = function () {
+ this.createActionPane(
+ 'mw-mmv-options-enable',
+ '$enableDiv',
+ mw.message( 'multimediaviewer-enable-submit-button' ).text(),
+ [
+ mw.message( 'multimediaviewer-enable-dialog-header' ).text(),
+ mw.message( 'multimediaviewer-enable-text-header' ).text()
+ ], true );
+ };
+
+ /**
+ * Initialises the disable action pane.
+ */
+ ODP.initDisableDiv = function () {
+ this.createActionPane(
+ 'mw-mmv-options-disable',
+ '$disableDiv',
+ mw.message( 'multimediaviewer-option-submit-button' ).text(),
+ [
+ mw.message( 'multimediaviewer-options-dialog-header' ).text(),
+ mw.message( 'multimediaviewer-options-text-header' ).text(),
+ mw.message( 'multimediaviewer-options-text-body' ).text()
+ ], false );
+ };
+
+ /**
+ * Hides all of the divs.
+ */
+ ODP.hideDivs = function () {
+ this.$dialog.removeClass( 'mw-mmv-disable-confirmation-shown mw-mmv-enable-confirmation-shown mw-mmv-enable-div-shown' );
+
+ this.$disableDiv
+ .add( this.$disableConfirmation )
+ .add( this.$enableDiv )
+ .add( this.$enableConfirmation )
+ .removeClass( 'mw-mmv-shown' );
+ };
+
+ /**
+ * Shows the confirmation div for the disable action.
+ */
+ ODP.showDisableConfirmation = function () {
+ this.hideDivs();
+ this.$disableConfirmation.addClass( 'mw-mmv-shown' );
+ this.$dialog.addClass( 'mw-mmv-disable-confirmation-shown' );
+ };
+
+ /**
+ * Shows the confirmation div for the enable action.
+ */
+ ODP.showEnableConfirmation = function () {
+ this.hideDivs();
+ this.$enableConfirmation.addClass( 'mw-mmv-shown' );
+ this.$dialog.addClass( 'mw-mmv-enable-confirmation-shown' );
+ };
+
+ /**
+ * @event mmv-options-opened
+ * Fired when the dialog is opened.
+ */
+
+ /**
+ * Opens a dialog with information about file reuse.
+ */
+ ODP.openDialog = function () {
+ if ( this.isEnabled() ) {
+ this.$disableDiv.addClass( 'mw-mmv-shown' );
+ } else {
+ this.$enableDiv.addClass( 'mw-mmv-shown' );
+ this.$dialog.addClass( 'mw-mmv-enable-div-shown' );
+ }
+
+ mw.mmv.ui.Dialog.prototype.openDialog.call( this );
+ $( document ).trigger( 'mmv-options-opened' );
+ };
+
+ /**
+ * @event mmv-options-closed
+ * Fired when the dialog is closed.
+ */
+
+ /**
+ * Closes the options dialog.
+ *
+ * @param {Event} [e] Event object when the close action is caused by a user
+ * action, as opposed to closing the window or something.
+ */
+ ODP.closeDialog = function ( e ) {
+ var wasConfirmation = this.$dialog.is( '.mw-mmv-disable-confirmation-shown' ) || this.$dialog.is( '.mw-mmv-enable-confirmation-shown' );
+
+ mw.mmv.ui.Dialog.prototype.closeDialog.call( this );
+ $( document ).trigger( 'mmv-options-closed' );
+ this.hideDivs();
+
+ if ( e && $( e.target ).is( '.mw-mmv-options-button' ) && wasConfirmation ) {
+ this.openDialog();
+ }
+ };
+
+ /**
+ * Creates a confirmation pane.
+ *
+ * @param {string} divClass Class applied to main div.
+ * @param {string} propName Name of the property on this object to which we'll assign the div.
+ * @param {string} msgs See #addText
+ */
+ ODP.createConfirmationPane = function ( divClass, propName, msgs ) {
+ var dialog = this,
+ $div = $( '<div>' )
+ .addClass( divClass )
+ .appendTo( this.$dialog );
+
+ $( '<div>' )
+ .html( '&nbsp;' )
+ .addClass( 'mw-mmv-confirmation-close' )
+ .click( function () {
+ dialog.closeDialog();
+ } )
+ .appendTo( $div );
+
+ this.addText( $div, msgs );
+
+ this[ propName ] = $div;
+ };
+
+ /**
+ * Creates an action pane.
+ *
+ * @param {string} divClass Class applied to main div.
+ * @param {string} propName Name of the property on this object to which we'll assign the div.
+ * @param {string} smsg Message for the submit button.
+ * @param {string} msgs See #addText
+ * @param {boolean} enabled Whether this dialog is an enable one.
+ */
+ ODP.createActionPane = function ( divClass, propName, smsg, msgs, enabled ) {
+ var $div = $( '<div>' )
+ .addClass( divClass )
+ .appendTo( this.$dialog );
+
+ if ( enabled ) {
+ $( '<div>' )
+ .addClass( 'mw-mmv-options-enable-alert' )
+ .text( mw.message( 'multimediaviewer-enable-alert' ).text() )
+ .appendTo( $div );
+ }
+
+ this.addText( $div, msgs, true );
+ this.addInfoLink( $div, ( enabled ? 'enable' : 'disable' ) + '-about-link' );
+ this.makeButtons( $div, smsg, enabled );
+
+ this[ propName ] = $div;
+ };
+
+ /**
+ * Creates buttons for the dialog.
+ *
+ * @param {jQuery} $container
+ * @param {string} smsg Message for the submit button.
+ * @param {boolean} enabled Whether the viewer is enabled after this dialog is submitted.
+ */
+ ODP.makeButtons = function ( $container, smsg, enabled ) {
+ var $submitDiv = $( '<div>' )
+ .addClass( 'mw-mmv-options-submit' )
+ .appendTo( $container );
+
+ this.makeSubmitButton(
+ $submitDiv,
+ smsg,
+ enabled
+ );
+
+ this.makeCancelButton( $submitDiv );
+ };
+
+ /**
+ * Makes a submit button for one of the panels.
+ *
+ * @param {jQuery} $submitDiv The div for the buttons in the dialog.
+ * @param {string} msg The string to put in the button.
+ * @param {boolean} enabled Whether to turn the viewer on or off when this button is pressed.
+ * @return {jQuery} Submit button
+ */
+ ODP.makeSubmitButton = function ( $submitDiv, msg, enabled ) {
+ var dialog = this;
+
+ return $( '<button>' )
+ .addClass( 'mw-mmv-options-submit-button mw-ui-button mw-ui-progressive' )
+ .text( msg )
+ .appendTo( $submitDiv )
+ .click( function () {
+ var $buttons = $( this ).closest( '.mw-mmv-options-submit' ).find( '.mw-mmv-options-submit-button, .mw-mmv-options-cancel-button' );
+ $buttons.prop( 'disabled', true );
+
+ dialog.config.setMediaViewerEnabledOnClick( enabled ).done( function () {
+ mw.mmv.actionLogger.log( 'opt' + ( enabled ? 'in' : 'out' ) + '-' + ( mw.user.isAnon() ? 'anon' : 'loggedin' ) );
+
+ if ( enabled ) {
+ dialog.showEnableConfirmation();
+ } else {
+ dialog.showDisableConfirmation();
+ }
+ } ).always( function () {
+ $buttons.prop( 'disabled', false );
+ } );
+
+ return false;
+ } );
+ };
+
+ /**
+ * Makes a cancel button for one of the panels.
+ *
+ * @param {jQuery} $submitDiv The div for the buttons in the dialog.
+ * @return {jQuery} Cancel button
+ */
+ ODP.makeCancelButton = function ( $submitDiv ) {
+ var dialog = this;
+
+ return $( '<button>' )
+ .addClass( 'mw-mmv-options-cancel-button mw-ui-button mw-ui-quiet' )
+ .text( mw.message( 'multimediaviewer-option-cancel-button' ).text() )
+ .appendTo( $submitDiv )
+ .click( function () {
+ dialog.closeDialog();
+ return false;
+ } );
+ };
+
+ /**
+ * Adds text to a dialog.
+ *
+ * @param {jQuery} $container
+ * @param {string[]} msgs The messages to be added.
+ * @param {boolean} icon Whether to display an icon next to the text or not
+ */
+ ODP.addText = function ( $container, msgs, icon ) {
+ var i, $text, $subContainer,
+ adders = [
+ function ( msg ) {
+ $( '<h3>' )
+ .text( msg )
+ .addClass( 'mw-mmv-options-dialog-header' )
+ .appendTo( $container );
+ },
+
+ function ( msg ) {
+ $( '<p>' )
+ .text( msg )
+ .addClass( 'mw-mmv-options-text-header' )
+ .appendTo( $text );
+ },
+
+ function ( msg ) {
+ $( '<p>' )
+ .text( msg )
+ .addClass( 'mw-mmv-options-text-body' )
+ .appendTo( $text );
+ }
+ ];
+
+ $text = $( '<div>' )
+ .addClass( 'mw-mmv-options-text' );
+
+ for ( i = 0; i < msgs.length && i < adders.length; i++ ) {
+ adders[ i ]( msgs[ i ] );
+ }
+
+ if ( icon ) {
+ $subContainer = $( '<div>' ).addClass( 'mw-mmv-options-subcontainer' );
+
+ $( '<div>' )
+ .html( '&nbsp;' )
+ .addClass( 'mw-mmv-options-icon' )
+ .appendTo( $subContainer );
+
+ $text.appendTo( $subContainer );
+ $subContainer.appendTo( $container );
+ } else {
+ $text.appendTo( $container );
+ }
+ };
+
+ /**
+ * Adds the info link to the panel.
+ *
+ * @param {jQuery} $div The panel to which we're adding the link.
+ * @param {string} eventName
+ */
+ ODP.addInfoLink = function ( $div, eventName ) {
+ $( '<a>' )
+ .addClass( 'mw-mmv-project-info-link' )
+ .prop( 'href', mw.config.get( 'wgMultimediaViewer' ).helpLink )
+ .text( mw.message( 'multimediaviewer-options-learn-more' ) )
+ .click( function () { mw.mmv.actionLogger.log( eventName ); } )
+ .appendTo( $div.find( '.mw-mmv-options-text' ) );
+ };
+
+ /**
+ * Checks the preference.
+ *
+ * @return {boolean} MV is enabled
+ */
+ ODP.isEnabled = function () {
+ return this.config.isMediaViewerEnabledOnClick();
+ };
+
+ mw.mmv.ui.OptionsDialog = OptionsDialog;
+}( mediaWiki, jQuery, OO ) );
diff --git a/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.less b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.less
new file mode 100644
index 00000000..7112172c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/resources/mmv/ui/mmv.ui.viewingOptions.less
@@ -0,0 +1,160 @@
+@import '../mmv.globals';
+@import '../mmv.mixins';
+
+.mw-mmv-options-dialog {
+ @offset-top: ( @buttons-offset-right + ( 2 * @buttons-offset-each-top ) + 6px );
+
+ top: @offset-top;
+ height: auto;
+ z-index: 1004;
+ padding: 15px;
+
+ &.mw-mmv-enable-confirmation-shown {
+ background-color: #00af89;
+ box-shadow: 0 2px 0 #00634e;
+
+ .mw-mmv-dialog-down-arrow {
+ background-color: #00af89;
+ }
+ }
+
+ &.mw-mmv-disable-confirmation-shown,
+ &.mw-mmv-disable-confirmation-shown .mw-mmv-dialog-down-arrow,
+ &.mw-mmv-enable-div-shown .mw-mmv-dialog-down-arrow {
+ background-color: #eaecf0;
+ }
+
+ .mw-mmv-dialog-down-arrow {
+ @arrow-size: 20px;
+ top: ( @offset-top + ( @arrow-size / 2 ) );
+ }
+
+ .mw-mmv-enable-confirmation,
+ .mw-mmv-disable-confirmation,
+ .mw-mmv-options-enable,
+ .mw-mmv-options-disable {
+ position: relative;
+ display: none;
+
+ &.mw-mmv-shown {
+ display: block;
+ }
+ }
+
+ .mw-mmv-confirmation-close {
+ display: inline-block;
+ position: absolute;
+ right: 0;
+ top: 0;
+ width: 15px;
+ height: 15px;
+ cursor: pointer;
+ opacity: 0.75;
+ /* @embed */
+ background-image: url( img/x_white.svg );
+ background-size: 15px 15px;
+
+ &:hover {
+ opacity: 1;
+ }
+ }
+
+ .mw-mmv-disable-confirmation {
+ .mw-mmv-options-dialog-header {
+ color: #222;
+ padding: 0;
+ }
+
+ .mw-mmv-options-text-header {
+ color: #222;
+ }
+ }
+
+ .mw-mmv-enable-confirmation {
+ .mw-mmv-options-dialog-header {
+ color: #fff;
+ padding: 0;
+ }
+
+ .mw-mmv-options-text-header {
+ color: #fff;
+ }
+ }
+
+ .mw-mmv-disable-confirmation,
+ .mw-mmv-enable-confirmation {
+ padding: 0;
+
+ .mw-mmv-options-text {
+ left: 0;
+ }
+ }
+}
+
+.mw-mmv-options-text,
+.mw-mmv-options-icon {
+ .mw-mmv-options-enable & {
+ top: 70px;
+ }
+}
+
+.mw-mmv-options-submit {
+ margin-top: 10px;
+}
+
+.mw-mmv-options-text {
+ left: 68px;
+ right: 0;
+}
+
+.mw-mmv-options-subcontainer .mw-mmv-options-text {
+ margin-left: 68px;
+}
+
+.mw-mmv-options-icon {
+ /* @embed */
+ background-image: url( img/icon_mmv.svg );
+ float: left;
+ width: 58px;
+ height: 52px;
+}
+
+.mw-mmv-options-cancel-button,
+.mw-mmv-options-submit-button {
+ float: right;
+}
+
+.mw-mmv-options-dialog-header {
+ padding-top: 0;
+ font-weight: normal;
+ font-size: 1.25em;
+ color: #222;
+
+ .mw-mmv-options-enable & {
+ top: 35px;
+ }
+}
+
+.mw-mmv-options-text-header {
+ margin: 0;
+ font-size: 1em;
+ color: #54595d;
+}
+
+.mw-mmv-options-text-body {
+ font-size: 0.9em;
+ color: #72777d;
+}
+
+.mw-mmv-options-enable-alert {
+ background-color: #eaecf0;
+ color: #222;
+ position: absolute;
+ left: -15px;
+ right: -15px;
+ top: -15px;
+ border-top-right-radius: @border-radius;
+ border-top-left-radius: @border-radius;
+ padding: 10px 15px;
+ font-weight: 500;
+}
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/LocalSettings.php b/www/wiki/extensions/MultimediaViewer/tests/browser/LocalSettings.php
new file mode 100644
index 00000000..acd153c6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/LocalSettings.php
@@ -0,0 +1,2 @@
+<?php
+ $wgUseInstantCommons = true;
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/README.md b/www/wiki/extensions/MultimediaViewer/tests/browser/README.md
new file mode 100644
index 00000000..36319498
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/README.md
@@ -0,0 +1 @@
+Please see https://github.com/wikimedia/mediawiki-selenium for instructions on how to run tests.
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/ci.yml b/www/wiki/extensions/MultimediaViewer/tests/browser/ci.yml
new file mode 100644
index 00000000..b95ed6f9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/ci.yml
@@ -0,0 +1,28 @@
+BROWSER:
+ - chrome
+ - firefox
+ - safari
+
+MEDIAWIKI_ENVIRONMENT:
+ - beta
+ - mediawiki
+
+PLATFORM:
+ - Linux
+ - OS X 10.9
+
+exclude:
+ - BROWSER: chrome
+ MEDIAWIKI_ENVIRONMENT: mediawiki
+
+ - BROWSER: chrome
+ PLATFORM: Linux
+
+ - BROWSER: firefox
+ PLATFORM: OS X 10.9
+
+ - BROWSER: safari
+ MEDIAWIKI_ENVIRONMENT: mediawiki
+
+ - BROWSER: safari
+ PLATFORM: Linux
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/environments.yml b/www/wiki/extensions/MultimediaViewer/tests/browser/environments.yml
new file mode 100644
index 00000000..caa5168e
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/environments.yml
@@ -0,0 +1,42 @@
+# Customize this configuration as necessary to provide defaults for various
+# test environments.
+#
+# The set of defaults to use is determined by the MEDIAWIKI_ENVIRONMENT
+# environment variable.
+#
+# export MEDIAWIKI_ENVIRONMENT=mw-vagrant-host
+# bundle exec cucumber
+#
+# Additional variables set by the environment will override the corresponding
+# defaults defined here.
+#
+# export MEDIAWIKI_ENVIRONMENT=mw-vagrant-host
+# export MEDIAWIKI_USER=Selenium_user2
+# bundle exec cucumber
+#
+mw-vagrant-host: &default
+ browser_useragent: test-user-agent
+ user_factory: true
+ mediawiki_url: http://127.0.0.1:8080/wiki/
+
+mw-vagrant-guest:
+ user_factory: true
+ mediawiki_url: http://127.0.0.1/wiki/
+
+beta:
+ browser_useragent: test-user-agent
+ mediawiki_url: https://en.wikipedia.beta.wmflabs.org/wiki/
+ mediawiki_user: Selenium_user
+ # mediawiki_password: SET THIS IN THE ENVIRONMENT!
+
+mediawiki:
+ browser_useragent: test-user-agent
+ mediawiki_url: https://www.mediawiki.org/wiki/
+ mediawiki_user: Selenium_user
+ # mediawiki_password: SET THIS IN THE ENVIRONMENT!
+
+integration:
+ user_factory: true
+ # mediawiki_url: THIS WILL BE SET BY JENKINS
+
+default: *default
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.download.feature b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.download.feature
new file mode 100644
index 00000000..fac69f34
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.download.feature
@@ -0,0 +1,59 @@
+@chrome @en.wikipedia.beta.wmflabs.org @firefox @integration @safari @test2.wikipedia.org
+Feature: Download menu
+
+ Background:
+ Given I am viewing an image using MMV
+
+ Scenario: Download menu can be opened
+ When I click the download icon
+ Then the download menu should appear
+
+ Scenario: Clicking the image closes the download menu
+ When I click the download icon
+ And the download menu appears
+ And I click the image
+ Then the download menu should disappear
+
+ Scenario: Image size defaults to original
+ When I click the download icon
+ Then the original beginning download image size label should be "4000 × 3000 px jpg"
+ And the download links should be the original image
+
+ Scenario: Attribution area is collapsed by default
+ When I click the download icon
+ Then the attribution area should be collapsed
+
+ Scenario: Attribution area can be opened
+ When I click the download icon
+ And I click on the attribution area
+ Then the attribution area should be open
+
+ Scenario: Attribution area can be closed
+ When I click the download icon
+ And I click on the attribution area
+ And I click on the attribution area close icon
+ Then the attribution area should be collapsed
+
+ Scenario: The small download option has the correct information
+ When I open the download dropdown
+ And the download size options appear
+ And I click the small download size
+ And the download size options disappears
+ Then the download image size label should be "193 × 145 px jpg"
+ And the download links should be the 193 thumbnail
+
+ Scenario: The medium download option has the correct information
+ When I open the download dropdown
+ And the download size options appear
+ And I click the medium download size
+ And the download size options disappears
+ Then the download image size label should be "640 × 480 px jpg"
+ And the download links should be the 640 thumbnail
+
+ Scenario: The large download option has the correct information
+ When I open the download dropdown
+ And the download size options appear
+ And I click the large download size
+ And the download size options disappears
+ Then the download image size label should be "1200 × 900 px jpg"
+ And the download links should be the 1200 thumbnail
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.navigation.feature b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.navigation.feature
new file mode 100644
index 00000000..39fae447
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.navigation.feature
@@ -0,0 +1,23 @@
+@chrome @en.wikipedia.beta.wmflabs.org @firefox @integration @test2.wikipedia.org
+Feature: Navigation
+
+ Background:
+ Given I am viewing an image using MMV
+
+ Scenario: Clicking the next arrow takes me to the next image
+ When I click the next arrow
+ Then the image and metadata of the next image should appear
+
+ Scenario: Clicking the previous arrow takes me to the previous image
+ When I click the previous arrow
+ Then the image and metadata of the previous image should appear
+
+ Scenario: Closing MMV restores the scroll position
+ When I close MMV
+ Then I should be navigated back to the original wiki article
+ And the wiki article should be scrolled to the same position as before opening MMV
+
+ Scenario: Browsing back to close MMV restores the scroll position
+ When I press the browser back button
+ Then I should be navigated back to the original wiki article
+ And the wiki article should be scrolled to the same position as before opening MMV
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.options.feature b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.options.feature
new file mode 100644
index 00000000..85c6826d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.options.feature
@@ -0,0 +1,44 @@
+@chrome @en.wikipedia.beta.wmflabs.org @firefox @integration @test2.wikipedia.org
+Feature: Options
+
+ Background:
+ Given I am viewing an image using MMV
+
+ Scenario: Clicking the X icon on the enable confirmation closes the options menu
+ Given I reenable MMV
+ When I click the enable X icon
+ Then the options menu should disappear
+
+ Scenario: Clicking the X icon on the disable confirmation closes the options menu
+ Given I disable MMV
+ When I click the disable X icon
+ Then the options menu should disappear
+
+ Scenario: Clicking the image closes the options menu
+ Given I click the options icon
+ When I click the image
+ Then the options menu should disappear
+
+ Scenario: Clicking cancel closes the options menu
+ Given I click the options icon
+ When I click the disable cancel button
+ Then the options menu should disappear
+
+ Scenario: Clicking the options icon brings up the options menu
+ When I click the options icon
+ Then the options menu should appear with the prompt to disable
+
+ Scenario: Clicking enable shows the confirmation
+ Given I click the options icon with MMV disabled
+ When I click the enable button
+ Then the enable confirmation should appear
+
+ Scenario: Clicking disable shows the confirmation
+ Given I click the options icon
+ When I click the disable button
+ Then the disable confirmation should appear
+
+ Scenario: Disabling media viewer makes the next thumbnail click go to the file page
+ Given I disable and close MMV
+ When I click on the first image in the article
+ Then I am taken to the file page
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.performance.feature b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.performance.feature
new file mode 100644
index 00000000..37e0c658
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/mmv.performance.feature
@@ -0,0 +1,42 @@
+@en.wikipedia.beta.wmflabs.org @firefox @www.mediawiki.org @test2.wikipedia.org
+Feature: Multimedia Viewer performance
+
+ Background:
+ Given I am using a custom user agent
+ And I am at a wiki article with at least two embedded pictures
+
+ Scenario: Commons with warm cache
+ Given I visit an unrelated Commons page to warm up the browser cache
+ And I visit the Commons page
+ Then the File: page image is loaded
+
+ Scenario: MMV with warm cache and small browser window
+ Given I have a small browser window
+ When I click on an unrelated image in the article to warm up the browser cache
+ And I close MMV
+ And I click on the first image in the article
+ Then the MMV image is loaded in 125 percent of the time with a warm cache and an average browser window
+
+ Scenario: MMV with cold cache and average browser window
+ Given I have an average browser window
+ When I click on the first image in the article
+ Then the MMV image is loaded in 210 percent of the time with a cold cache and an average browser window
+
+ Scenario: MMV with warm cache and average browser window
+ Given I have an average browser window
+ When I click on an unrelated image in the article to warm up the browser cache
+ And I close MMV
+ And I click on the first image in the article
+ Then the MMV image is loaded in 125 percent of the time with a warm cache and an average browser window
+
+ Scenario: MMV with cold cache and large browser window
+ Given I have a large browser window
+ When I click on the first image in the article
+ Then the MMV image is loaded in 240 percent of the time with a cold cache and a large browser window
+
+ Scenario: MMV with warm cache and large browser window
+ Given I have a large browser window
+ When I click on an unrelated image in the article to warm up the browser cache
+ And I close MMV
+ And I click on the first image in the article
+ Then the MMV image is loaded in 125 percent of the time with a warm cache and a large browser window
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_download_steps.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_download_steps.rb
new file mode 100644
index 00000000..1d94a804
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_download_steps.rb
@@ -0,0 +1,101 @@
+# encoding: utf-8
+
+When /^I open the download dropdown$/ do
+ step 'I click the download icon'
+ step 'I click the download down arrow icon'
+end
+
+When /^I click the download icon$/ do
+ on(E2ETestPage).mmv_download_icon_element.when_present.click
+end
+
+When /^I click the download down arrow icon$/ do
+ sleep 1
+ on(E2ETestPage).mmv_download_down_arrow_icon_element.when_present(10).click
+end
+
+When /^I click on the attribution area$/ do
+ on(E2ETestPage).mmv_download_attribution_area_element.when_present(10).click
+end
+
+When /^I click on the attribution area close icon$/ do
+ on(E2ETestPage).mmv_download_attribution_area_close_icon_element.click
+end
+
+When /^I click the (.*) download size$/ do |size_option|
+ on(E2ETestPage) do |page|
+ case size_option
+ when 'small'
+ @index = 1
+ when 'medium'
+ @index = 2
+ when 'large'
+ @index = 3
+ else
+ @index = 0
+ end
+
+ page.mmv_download_size_options_elements[@index].click
+ end
+end
+
+When /^the download size options appear$/ do
+ on(E2ETestPage).mmv_download_size_menu_element.when_present
+end
+
+When /^the download size options disappears$/ do
+ on(E2ETestPage).mmv_download_size_menu_element.when_not_present
+end
+
+When /^the download menu appears$/ do
+ on(E2ETestPage).mmv_download_menu_element.when_present(10)
+end
+
+Then /^the download menu should appear$/ do
+ expect(on(E2ETestPage).mmv_download_menu_element.when_present(10)).to be_visible
+end
+
+Then /^the download menu should disappear$/ do
+ expect(on(E2ETestPage).mmv_download_menu_element).not_to be_visible
+end
+
+Then /^the original beginning download image size label should be "(.*)"$/ do |size_in_pixels|
+ expect(on(E2ETestPage).mmv_download_size_label_element.when_present(10).text).to eq size_in_pixels
+end
+
+Then /^the download image size label should be "(.*)"$/ do |size_in_pixels|
+ on(E2ETestPage) do |page|
+ page.mmv_download_size_options_elements[0].when_not_present
+ expect(page.mmv_download_size_label_element.when_present.text).to eq size_in_pixels
+ end
+end
+
+Then /^the download size options should appear$/ do
+ expect(on(E2ETestPage).mmv_download_size_menu_element.when_present).to be_visible
+end
+
+Then /^the download links should be the original image$/ do
+ on(E2ETestPage) do |page|
+ expect(page.mmv_download_link_element.attribute('href')).to match /^?download$/
+ expect(page.mmv_download_preview_link_element.attribute('href')).not_to match /^?download$/
+ expect(page.mmv_download_link_element.attribute('href')).not_to match %r{/thumb/}
+ expect(page.mmv_download_preview_link_element.attribute('href')).not_to match %r{/thumb/}
+ end
+end
+
+Then /^the download links should be the (\d+) thumbnail$/ do |thumb_size|
+ on(E2ETestPage) do |page|
+ page.wait_until { page.mmv_download_link_element.attribute('href').match thumb_size }
+ expect(page.mmv_download_link_element.attribute('href')).to match /^?download$/
+ expect(page.mmv_download_preview_link_element.attribute('href')).not_to match /^?download$/
+ expect(page.mmv_download_preview_link_element.attribute('href')).to match thumb_size
+ end
+end
+
+Then /^the attribution area should be collapsed$/ do
+ expect(on(E2ETestPage).mmv_download_attribution_area_element.when_present(10).attribute('class')).to match 'mw-mmv-download-attribution-collapsed'
+end
+
+Then /^the attribution area should be open$/ do
+ expect(on(E2ETestPage).mmv_download_attribution_area_element.when_present.attribute('class')).not_to match 'mw-mmv-download-attribution-collapsed'
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_navigation_steps.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_navigation_steps.rb
new file mode 100644
index 00000000..bd73d899
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_navigation_steps.rb
@@ -0,0 +1,44 @@
+# encoding: utf-8
+
+When /^I click the next arrow$/ do
+ on(E2ETestPage).mmv_next_button_element.when_present.click
+end
+
+When /^I click the previous arrow$/ do
+ on(E2ETestPage).mmv_previous_button_element.when_present.click
+end
+
+When /^I press the browser back button$/ do
+ # $browser.back doesn't work for Safari. This is a workaround for https://code.google.com/p/selenium/issues/detail?id=3771
+ on(E2ETestPage).execute_script('window.history.back();')
+end
+
+Then /^the image and metadata of the next image should appear$/ do
+ on(E2ETestPage) do |page|
+ # MMV was launched, article is not visible yet
+ expect(page.image1_in_article_element).not_to be_visible
+ check_elements_in_viewer_for_image3 page
+ end
+end
+
+Then /^the image and metadata of the previous image should appear$/ do
+ on(E2ETestPage) do |page|
+ # MMV was launched, article is not visible yet
+ expect(page.image1_in_article_element).not_to be_visible
+ check_elements_in_viewer_for_image1 page
+ end
+end
+
+Then /^the wiki article should be scrolled to the same position as before opening MMV$/ do
+ on(E2ETestPage) do |page|
+ scroll_difference = page.execute_script('return $(window).scrollTop();') - @article_scroll_top
+ expect(scroll_difference.abs).to be < 2
+ end
+end
+
+Then /^I should be navigated back to the original wiki article$/ do
+ on(E2ETestPage) do |page|
+ expect(page.image1_in_article_element).to be_visible
+ expect(page.mmv_wrapper_element).not_to be_visible
+ end
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_options_steps.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_options_steps.rb
new file mode 100644
index 00000000..db5c380c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_options_steps.rb
@@ -0,0 +1,69 @@
+# encoding: utf-8
+
+When /^I click the options icon$/ do
+ on(E2ETestPage).mmv_options_icon_element.click
+end
+
+Then /^the options menu should appear with the prompt to disable$/ do
+ on(E2ETestPage).mmv_options_menu_disable_element.should be_visible
+end
+
+Then /^the options menu should disappear$/ do
+ on(E2ETestPage).mmv_options_menu_disable_element.should_not be_visible
+end
+
+When /^I click the enable button$/ do
+ on(E2ETestPage).mmv_options_enable_button_element.click
+end
+
+When /^I click the disable button$/ do
+ on(E2ETestPage).mmv_options_disable_button_element.click
+end
+
+When /^I click the disable cancel button$/ do
+ on(E2ETestPage).mmv_options_disable_cancel_button_element.click
+end
+
+When /^I click the enable X icon$/ do
+ on(E2ETestPage).mmv_options_enable_x_icon_element.click
+end
+
+When /^I click the disable X icon$/ do
+ on(E2ETestPage).mmv_options_disable_x_icon_element.click
+end
+
+When /^I disable MMV$/ do
+ step 'I click the options icon'
+ step 'I click the disable button'
+end
+
+When /^I reenable MMV$/ do
+ step 'I disable MMV'
+ step 'I click the options icon'
+ step 'I click the enable button'
+end
+
+When /^I click the options icon with MMV disabled$/ do
+ step 'I disable MMV'
+ step 'I click the options icon'
+end
+
+When /^I disable and close MMV$/ do
+ step 'I disable MMV'
+ step 'I close MMV'
+end
+
+Then /^the disable confirmation should appear$/ do
+ on(E2ETestPage).mmv_options_disable_confirmation_element.should be_visible
+end
+
+Then /^the enable confirmation should appear$/ do
+ on(E2ETestPage).mmv_options_enable_confirmation_element.should be_visible
+end
+
+Then /^I am taken to the file page$/ do
+ on(E2ETestPage) do |page|
+ page.current_url.should match %r{/File:}
+ page.current_url.should_not match %r{#/media}
+ end
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_performance_steps.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_performance_steps.rb
new file mode 100644
index 00000000..c81ee4e1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_performance_steps.rb
@@ -0,0 +1,48 @@
+When /^I click on an unrelated image in the article to warm up the browser cache$/ do
+ on(E2ETestPage).other_image_in_article
+end
+
+Given /^I visit the Commons page$/ do
+ @commons_open_time = Time.now.getutc
+ browser.goto 'https://commons.wikimedia.org/wiki/File:Sunrise_over_fishing_boats_in_Kerala.jpg'
+end
+
+Given /^I visit an unrelated Commons page to warm up the browser cache$/ do
+ browser.goto 'https://commons.wikimedia.org/wiki/File:Wikimedia_Foundation_2013_All_Hands_Offsite_-_Day_2_-_Photo_16.jpg'
+end
+
+Given /^I have a small browser window$/ do
+ browser.window.resize_to 900, 700
+end
+
+Given /^I have an average browser window$/ do
+ browser.window.resize_to 1366, 768
+end
+
+Given /^I have a large browser window$/ do
+ browser.window.resize_to 1920, 1080
+end
+
+Given /^I am using a custom user agent$/ do
+ browser_factory.override(browser_user_agent: env[:browser_useragent])
+end
+
+Then /^the File: page image is loaded$/ do
+ on(CommonsPage) do |page|
+ page.wait_for_image_load '.fullImageLink img'
+ # Has to be a global variable, otherwise it doesn't survive between scenarios
+ $commons_time = Time.now.getutc - @commons_open_time
+ page.log_performance type: 'file-page', duration: $commons_time * 1000
+ end
+end
+
+Then /^the MMV image is loaded in (\d+) percent of the time with a (.*) cache and an? (.*) browser window$/ do |percentage, cache, window_size|
+ on(E2ETestPage) do |page|
+ page.wait_for_image_load '.mw-mmv-image img'
+ mmv_time = Time.now.getutc - @image_click_time
+ page.log_performance type: 'mmv', duration: mmv_time * 1000, cache: cache, windowSize: window_size
+
+ expected_time = $commons_time * (percentage.to_f / 100.0)
+ expect(mmv_time).to be < expected_time
+ end
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_steps.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_steps.rb
new file mode 100644
index 00000000..3e4590bc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/step_definitions/mmv_steps.rb
@@ -0,0 +1,174 @@
+# encoding: utf-8
+
+Given /^I am at a wiki article with at least two embedded pictures$/ do
+ api.create_page 'MediaViewerE2ETest', File.read(File.join(__dir__, '../../samples/MediaViewerE2ETest.wikitext'))
+ visit(E2ETestPage)
+ on(E2ETestPage).image1_in_article_element.when_present.should be_visible
+end
+
+Given /^the MMV has loaded$/ do
+ on(E2ETestPage) do |page|
+ page.wait_until do
+ # Wait for JS to hijack standard link
+ # TODO: If this approach works well, we should implement general
+ # `wait_for_resource` and `resource_ready?` helper methods in
+ # mw-selenium, and document this pattern on mw.org
+ browser.execute_script("return mw.loader.getState('mmv.bootstrap') === 'ready'")
+ end
+ end
+end
+
+Given /^I am viewing an image using MMV$/ do
+ step 'I am at a wiki article with at least two embedded pictures'
+ step 'the MMV has loaded'
+ step 'I click on the second image in the article'
+ step 'the image metadata and the image itself should be there'
+end
+
+When /^I click on the first image in the article$/ do
+ on(E2ETestPage) do |page|
+ # We store the offset of the image as the scroll position and scroll to it, because cucumber/selenium
+ # sometimes automatically scrolls to it when we ask it to click on it (seems to depend on timing)
+ @article_scroll_top = page.execute_script("var scrollTop = Math.round($('a[href$=\"File:Sunrise_over_fishing_boats_in_Kerala.jpg\"]').first().find('img').offset().top); window.scrollTo(0, scrollTop); return scrollTop;")
+ # Scrolls to the image and clicks on it
+ page.image1_in_article
+ # This is a global variable that can be used to measure performance
+ @image_click_time = Time.now.getutc
+ end
+end
+
+When /^I click on the second image in the article$/ do
+ on(E2ETestPage) do |page|
+ # We store the offset of the image as the scroll position and scroll to it, because cucumber/selenium
+ # sometimes automatically scrolls to it when we ask it to click on it (seems to depend on timing)
+ @article_scroll_top = page.execute_script("var scrollTop = Math.round($('a[href$=\"File:Wikimedia_Foundation_2013_All_Hands_Offsite_-_Day_2_-_Photo_24.jpg\"]').first().find('img').offset().top); window.scrollTo(0, scrollTop); return scrollTop;")
+ # Scrolls to the image and clicks on it
+ page.image2_in_article
+ # This is a global variable that can be used to measure performance
+ @image_click_time = Time.now.getutc
+ end
+end
+
+When /^I close MMV$/ do
+ on(E2ETestPage).mmv_close_button_element.when_present(30).click
+end
+
+When /^I click the image$/ do
+ on(E2ETestPage) do
+ # Clicking the top-left corner of the image is necessary for the test to work on IE
+ # A plain click on the image element ends up hitting the dialog, which means it won't close
+ begin
+ browser.driver.action.move_to(browser.driver.find_element(:class, 'mw-mmv-image'), 10, 10).click.perform
+ rescue
+ # Plain click for web drivers that don't support mouse moves (Safari, currently)
+ on(E2ETestPage).mmv_image_div_element.when_present.click
+ end
+ end
+end
+
+Then /^the image metadata and the image itself should be there$/ do
+ on(E2ETestPage) do |page|
+ # MMV was launched, article is not visible now
+ page.image1_in_article_element.should_not be_visible
+ check_elements_in_viewer_for_image2 page
+ end
+end
+
+# Helper function that verifies the presence of various elements in viewer
+# while looking at image1 (Kerala)
+def check_elements_in_viewer_for_image1(page)
+ # Check basic MMV elements are present
+ expect(page.mmv_overlay_element.when_present).to be_visible
+ expect(page.mmv_wrapper_element.when_present).to be_visible
+ expect(page.mmv_image_div_element).to be_visible
+
+ # Check image content
+ expect(page.mmv_final_image_element.when_present.attribute('src')).to match /Kerala/
+
+ # Check basic metadata is present
+
+ # Title
+ expect(page.mmv_metadata_title_element.when_present.text).to match /^Sunrise over fishing boats$/
+ # License
+ expect(page.mmv_metadata_license_element.when_present.attribute('href')).to match %r{^https?://creativecommons.org/licenses/by-sa/3.0$}
+ expect(page.mmv_metadata_license_element.when_present.text).to match 'CC BY-SA 3.0'
+ # Credit
+ expect(page.mmv_metadata_credit_element.when_present).to be_visible
+ expect(page.mmv_metadata_source_element.when_present.text).to match 'Own work'
+
+ # Image metadata
+ expect(page.mmv_image_metadata_wrapper_element.when_present).to be_visible
+ # Description
+ expect(page.mmv_image_metadata_desc_element.when_present.text).to match 'Sunrise over fishing boats on the beach south of Kovalam'
+ # Image metadata links
+ expect(page.mmv_image_metadata_links_wrapper_element.when_present).to be_visible
+ # Details link
+ expect(page.mmv_details_page_link_element.when_present.text).to match 'More details'
+ expect(page.mmv_details_page_link_element.when_present.attribute('href')).to match /boats_in_Kerala.jpg$/
+end
+
+# Helper function that verifies the presence of various elements in viewer
+# while looking at image2 (Aquarium)
+def check_elements_in_viewer_for_image2(page)
+ # Check basic MMV elements are present
+ expect(page.mmv_overlay_element.when_present).to be_visible
+ expect(page.mmv_wrapper_element.when_present).to be_visible
+ expect(page.mmv_image_div_element).to be_visible
+
+ # Check image content
+ expect(page.mmv_final_image_element.when_present(30).attribute('src')).to match 'Offsite'
+
+ # Check basic metadata is present
+
+ # Title
+ expect(page.mmv_metadata_title_element.when_present.text).to match /^Tropical Fish Aquarium$/
+ # License
+ expect(page.mmv_metadata_license_element.when_present(10).attribute('href')).to match %r{^https?://creativecommons.org/licenses/by-sa/3.0$}
+ expect(page.mmv_metadata_license_element.when_present.text).to match 'CC BY-SA 3.0'
+ # Credit
+ expect(page.mmv_metadata_credit_element.when_present).to be_visible
+ expect(page.mmv_metadata_source_element.when_present.text).to match 'Wikimedia Foundation'
+
+ # Image metadata
+ expect(page.mmv_image_metadata_wrapper_element.when_present).to be_visible
+ # Description
+ expect(page.mmv_image_metadata_desc_element.when_present.text).to match 'Photo from Wikimedia Foundation'
+ # Image metadata links
+ expect(page.mmv_image_metadata_links_wrapper_element.when_present).to be_visible
+ # Details link
+ expect(page.mmv_details_page_link_element.when_present.text).to match 'More details'
+ expect(page.mmv_details_page_link_element.when_present.attribute('href')).to match /All_Hands_Offsite.*\.jpg$/
+end
+
+# Helper function that verifies the presence of various elements in viewer
+# while looking at image3 (Hong Kong)
+def check_elements_in_viewer_for_image3(page)
+ # Check basic MMV elements are present
+ expect(page.mmv_overlay_element.when_present).to be_visible
+ expect(page.mmv_wrapper_element.when_present).to be_visible
+ expect(page.mmv_image_div_element).to be_visible
+
+ # Check image content
+ expect(page.mmv_image_div_element.image_element.attribute('src')).to match 'Hong_Kong'
+
+ # Check basic metadata is present
+
+ # Title
+ expect(page.mmv_metadata_title_element.when_present.text).to match /^Hong Kong Harbor at night$/
+ # License
+ expect(page.mmv_metadata_license_element.when_present.attribute('href')).to match %r{^https?://creativecommons.org/licenses/by-sa/3.0$}
+ expect(page.mmv_metadata_license_element.when_present.text).to match 'CC BY-SA 3.0'
+ # Credit
+ expect(page.mmv_metadata_credit_element.when_present).to be_visible
+ expect(page.mmv_metadata_source_element.when_present.text).to match 'Wikimedia Foundation'
+
+ # Image metadata
+ expect(page.mmv_image_metadata_wrapper_element.when_present).to be_visible
+ # Description
+ expect(page.mmv_image_metadata_desc_element.when_present.text).to match /Photos from our product team's talks at Wikimania 2013 in Hong Kong./
+ # Image metadata links
+ expect(page.mmv_image_metadata_links_wrapper_element.when_present).to be_visible
+ # Details link
+ expect(page.mmv_details_page_link_element.when_present.text).to match 'More details'
+ expect(page.mmv_details_page_link_element.when_present.attribute('href')).to match /Wikimania_2013_-_Hong_Kong_-_Photo_090\.jpg$/
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/env.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/env.rb
new file mode 100644
index 00000000..c1072b26
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/env.rb
@@ -0,0 +1,3 @@
+require 'mediawiki_selenium/cucumber'
+require 'mediawiki_selenium/pages'
+require 'mediawiki_selenium/step_definitions'
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/commons_page.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/commons_page.rb
new file mode 100644
index 00000000..0923e354
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/commons_page.rb
@@ -0,0 +1,51 @@
+require 'json'
+
+class CommonsPage
+ include PageObject
+
+ page_url 'File:Sunrise_over_fishing_boats_in_Kerala.jpg'
+
+ img(:commons_image, src: /Kerala\.jpg$/)
+ div(:mmv_image_loaded_cucumber, class: 'mw-mmv-image-loaded-cucumber')
+
+ def wait_for_image_load(selector)
+ browser.execute_script <<-end_script
+ function wait_for_image() {
+ var $img = $( #{selector.to_json} );
+ if ( $img.length
+ && $img.attr( 'src' ).match(/Kerala/)
+ && !$img.attr( 'src' ).match(/\\/220px-/) // Blurry placeholder
+ && $img.prop( 'complete' ) ) {
+ $( 'body' ).append( '<div class=\"mw-mmv-image-loaded-cucumber\"/>' );
+ } else {
+ setTimeout( wait_for_image, 10 );
+ }
+ }
+ wait_for_image();
+ end_script
+
+ wait_until { mmv_image_loaded_cucumber_element.exists? }
+ end
+
+ def log_performance(stats)
+ stats = stats.reject { |_name, value| value.nil? || value.to_s.empty? }
+ stats[:duration] = stats[:duration].floor
+
+ browser.execute_script <<-end_script
+ mediaWiki.eventLog.declareSchema( 'MultimediaViewerVersusPageFilePerformance',
+ { schema:
+ { title: 'MultimediaViewerVersusPageFilePerformance',
+ properties: {
+ type: { type: 'string', required: true, enum: [ 'mmv', 'file-page' ] },
+ duration: { type: 'integer', required: true },
+ cache: { type: 'string', required: false, enum: [ 'cold', 'warm' ] },
+ windowSize: { type: 'string', required: false, enum: [ 'average', 'large'] }
+ }
+ },
+ revision: 7907636
+ });
+
+ mw.eventLog.logEvent( 'MultimediaViewerVersusPageFilePerformance', #{stats.to_json} );
+ end_script
+ end
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/e2e_test_page.rb b/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/e2e_test_page.rb
new file mode 100644
index 00000000..c0f04077
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/features/support/pages/e2e_test_page.rb
@@ -0,0 +1,87 @@
+class E2ETestPage < CommonsPage
+ include PageObject
+
+ page_url 'MediaViewerE2ETest'
+
+ # Tag page elements that we will need.
+
+ # First image in lightbox demo page
+ a(:image1_in_article, class: 'image', href: /Kerala\.jpg$/)
+ a(:image2_in_article, class: 'image', href: /Wikimedia_Foundation_2013_All_Hands_Offsite_-_Day_2_-_Photo_24\.jpg$/)
+
+ a(:other_image_in_article, href: /Academy_of_Sciences\.jpg$/)
+
+ # Black overlay
+ div(:mmv_overlay, class: 'mw-mmv-overlay')
+
+ # Wrapper div for all mmv elements
+ div(:mmv_wrapper, class: 'mw-mmv-wrapper')
+
+ # Wrapper div for image
+ div(:mmv_image_div, class: 'mw-mmv-image')
+
+ # Actual image
+ image(:mmv_final_image, class: 'mw-mmv-final-image')
+
+ # Metadata elements
+ span(:mmv_metadata_title, class: 'mw-mmv-title')
+ a(:mmv_metadata_license, class: 'mw-mmv-license')
+ p(:mmv_metadata_credit, class: 'mw-mmv-credit')
+ span(:mmv_metadata_source, class: 'mw-mmv-source')
+
+ div(:mmv_image_metadata_wrapper, class: 'mw-mmv-image-metadata')
+ p(:mmv_image_metadata_desc, class: 'mw-mmv-image-desc')
+
+ ul(:mmv_image_metadata_links_wrapper, class: 'mw-mmv-image-links')
+ a(:mmv_details_page_link, class: 'mw-mmv-description-page-button')
+
+ # Controls
+ button(:mmv_next_button, class: 'mw-mmv-next-image')
+ button(:mmv_previous_button, class: 'mw-mmv-prev-image')
+ button(:mmv_close_button, class: 'mw-mmv-close')
+ div(:mmv_image_loaded_cucumber, class: 'mw-mmv-image-loaded-cucumber')
+
+ # Download
+ button(:mmv_download_icon, class: 'mw-mmv-download-button')
+ div(:mmv_download_menu, class: 'mw-mmv-download-dialog')
+ span(:mmv_download_size_label, class: 'mw-mmv-download-image-size')
+ span(:mmv_download_down_arrow_icon, class: 'mw-mmv-download-select-menu')
+ div(:mmv_download_size_menu_container, class: 'mw-mmv-download-size')
+ div(:mmv_download_size_menu) do |page|
+ page.mmv_download_size_menu_container_element.div_element(class: 'oo-ui-selectWidget')
+ end
+ divs(:mmv_download_size_options, class: 'oo-ui-menuOptionWidget')
+ a(:mmv_download_link, class: 'mw-mmv-download-go-button')
+ a(:mmv_download_preview_link, class: 'mw-mmv-download-preview-link')
+ div(:mmv_download_attribution_area, class: 'mw-mmv-download-attribution')
+ p(:mmv_download_attribution_area_close_icon, class: 'mw-mmv-download-attribution-close-button')
+ div(:mmv_download_attribution_area_input_container, class: 'mw-mmv-download-attr-input')
+ text_field(:mmv_download_attribution_area_input) do |page|
+ page.mmv_download_attribution_area_input_container_element.text_field_element
+ end
+
+ # Options
+ button(:mmv_options_icon, class: 'mw-mmv-options-button')
+ div(:mmv_options_menu_disable, class: 'mw-mmv-options-disable')
+ div(:mmv_options_menu_enable, class: 'mw-mmv-options-enable')
+ button(:mmv_options_enable_button) do |page|
+ page.mmv_options_menu_enable_element.div_element(class: 'mw-mmv-options-submit').button_element(class: 'mw-mmv-options-submit-button')
+ end
+ button(:mmv_options_disable_button) do |page|
+ page.mmv_options_menu_disable_element.div_element(class: 'mw-mmv-options-submit').button_element(class: 'mw-mmv-options-submit-button')
+ end
+ button(:mmv_options_enable_cancel_button) do |page|
+ page.mmv_options_menu_enable_element.div_element(class: 'mw-mmv-options-submit').button_element(class: 'mw-mmv-options-cancel-button')
+ end
+ button(:mmv_options_disable_cancel_button) do |page|
+ page.mmv_options_menu_disable_element.div_element(class: 'mw-mmv-options-submit').button_element(class: 'mw-mmv-options-cancel-button')
+ end
+ div(:mmv_options_disable_confirmation, class: 'mw-mmv-disable-confirmation')
+ div(:mmv_options_disable_x_icon) do |page|
+ page.mmv_options_disable_confirmation_element.div_element(class: 'mw-mmv-confirmation-close')
+ end
+ div(:mmv_options_enable_confirmation, class: 'mw-mmv-enable-confirmation')
+ div(:mmv_options_enable_x_icon) do |page|
+ page.mmv_options_enable_confirmation_element.div_element(class: 'mw-mmv-confirmation-close')
+ end
+end
diff --git a/www/wiki/extensions/MultimediaViewer/tests/browser/samples/MediaViewerE2ETest.wikitext b/www/wiki/extensions/MultimediaViewer/tests/browser/samples/MediaViewerE2ETest.wikitext
new file mode 100644
index 00000000..a920e77f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/browser/samples/MediaViewerE2ETest.wikitext
@@ -0,0 +1,14 @@
+<big>PLEASE DO NOT EDIT THIS PAGE! IT NEEDS TO STAY THE SAME FOR THE PURPOSE OF AUTOMATED TESTING</big>
+
+==Test Images==
+Here are some sample images for testing different features of Media Viewer.
+
+[[File:Sunrise over fishing boats in Kerala.jpg|thumb|left|Sunrise over fishing boats]] [[File:Wikimedia_Foundation_2013_All_Hands_Offsite_-_Day_2_-_Photo_24.jpg|thumb|Tropical Fish Aquarium]] [[File:Wikimania 2013 - Hong Kong - Photo 090.jpg|thumb|center|Hong Kong Harbor at night]]
+<br clear="all"/>
+
+[[File:Wikimedia_Foundation_2013_All_Hands_Offsite_-_Day_2_-_Photo_16.jpg|thumb|left|Nautilus Shell at California Academy of Sciences]] [[File:Multimedia_Team_-_Wikimedia_Foundation.jpg|thumb|center|Multimedia Team]] [[File:Zonotrichia atricapilla -British Columbia, Canada-8.jpg|thumb|Golden-crowned Sparrow]]
+<br clear="all"/>
+
+[[File:Multimedia Roundtable 5 Photo 2.jpg|thumb|left|Multimedia Roundtable]] [[File:Wikimedia Foundation - Team 1 - California Academy of Sciences.jpg|thumb|Wikimedia Team]]
+
+<br clear="all"/>
diff --git a/www/wiki/extensions/MultimediaViewer/tests/phan/config.php b/www/wiki/extensions/MultimediaViewer/tests/phan/config.php
new file mode 100644
index 00000000..0cfe0c1a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/phan/config.php
@@ -0,0 +1,19 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+
+$cfg['directory_list'] = array_merge(
+ $cfg['directory_list'],
+ [
+ './../../extensions/BetaFeatures',
+ ]
+);
+
+$cfg['exclude_analysis_directory_list'] = array_merge(
+ $cfg['exclude_analysis_directory_list'],
+ [
+ './../../extensions/BetaFeatures',
+ ]
+);
+
+return $cfg;
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ActionLogger.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ActionLogger.test.js
new file mode 100644
index 00000000..9a1808c4
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ActionLogger.test.js
@@ -0,0 +1,48 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.logging.ActionLogger', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'log()', function ( assert ) {
+ var fakeEventLog = { logEvent: this.sandbox.stub() },
+ logger = new mw.mmv.logging.ActionLogger(),
+ action1key = 'test-1',
+ action1value = 'Test',
+ action2key = 'test-2',
+ action2value = 'Foo $1 $2 bar',
+ unknownAction = 'test-3',
+ clock = this.sandbox.useFakeTimers();
+
+ this.sandbox.stub( logger, 'loadDependencies' ).returns( $.Deferred().resolve() );
+ this.sandbox.stub( mw, 'log' );
+
+ logger.samplingFactorMap = { 'default': 1 };
+ logger.setEventLog( fakeEventLog );
+ logger.logActions = {};
+ logger.logActions[ action1key ] = action1value;
+ logger.logActions[ action2key ] = action2value;
+
+ logger.log( unknownAction );
+ clock.tick( 10 );
+
+ assert.strictEqual( mw.log.lastCall.args[ 0 ], unknownAction, 'Log message defaults to unknown key' );
+ assert.ok( fakeEventLog.logEvent.called, 'event log has been recorded' );
+
+ mw.log.reset();
+ fakeEventLog.logEvent.reset();
+ logger.log( action1key );
+ clock.tick( 10 );
+
+ assert.strictEqual( mw.log.lastCall.args[ 0 ], action1value, 'Log message is translated to its text' );
+ assert.ok( fakeEventLog.logEvent.called, 'event log has been recorded' );
+
+ mw.log.reset();
+ fakeEventLog.logEvent.reset();
+ logger.samplingFactorMap = { 'default': 0 };
+ logger.log( action1key, true );
+ clock.tick( 10 );
+
+ assert.ok( !mw.log.called, 'No logging when disabled' );
+ assert.ok( fakeEventLog.logEvent.called, 'event log has been recorded' );
+
+ clock.restore();
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.AttributionLogger.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.AttributionLogger.test.js
new file mode 100644
index 00000000..e62d8109
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.AttributionLogger.test.js
@@ -0,0 +1,22 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.logging.AttributionLogger', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'log()', function ( assert ) {
+ var fakeEventLog = { logEvent: this.sandbox.stub() },
+ logger = new mw.mmv.logging.AttributionLogger(),
+ image = { author: 'foo', source: 'bar', license: {} },
+ emptyImage = {};
+
+ this.sandbox.stub( logger, 'loadDependencies' ).returns( $.Deferred().resolve() );
+ this.sandbox.stub( mw, 'log' );
+
+ logger.samplingFactor = 1;
+ logger.setEventLog( fakeEventLog );
+
+ logger.logAttribution( image );
+ assert.ok( true, 'logDimensions() did not throw errors' );
+
+ logger.logAttribution( emptyImage );
+ assert.ok( true, 'logDimensions() did not throw errors for empty image' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DimensionLogger.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DimensionLogger.test.js
new file mode 100644
index 00000000..0df8c02f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DimensionLogger.test.js
@@ -0,0 +1,17 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.logging.DimensionLogger', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'log()', function ( assert ) {
+ var fakeEventLog = { logEvent: this.sandbox.stub() },
+ logger = new mw.mmv.logging.DimensionLogger();
+
+ this.sandbox.stub( logger, 'loadDependencies' ).returns( $.Deferred().resolve() );
+ this.sandbox.stub( mw, 'log' );
+
+ logger.samplingFactor = 1;
+ logger.setEventLog( fakeEventLog );
+
+ logger.logDimensions( 640, 480, 200, 'resize' );
+ assert.ok( true, 'logDimensions() did not throw errors' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DurationLogger.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DurationLogger.test.js
new file mode 100644
index 00000000..474fc08c
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.DurationLogger.test.js
@@ -0,0 +1,218 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.logging.DurationLogger', QUnit.newMwEnvironment( {
+ setup: function () {
+ this.clock = this.sandbox.useFakeTimers();
+
+ // since jQuery 2/3, $.now will capture a reference to Date.now
+ // before above fake timer gets a chance to override it, so I'll
+ // override that new behavior in order to run these tests...
+ // @see https://github.com/sinonjs/lolex/issues/76
+ this.oldNow = $.now;
+ $.now = function () { return +( new Date() ); };
+ },
+
+ teardown: function () {
+ $.now = this.oldNow;
+ this.clock.restore();
+ }
+ } ) );
+
+ QUnit.test( 'start()', function ( assert ) {
+ var durationLogger = new mw.mmv.durationLogger.constructor();
+ durationLogger.samplingFactor = 1;
+
+ try {
+ durationLogger.start();
+ } catch ( e ) {
+ assert.ok( true, 'Exception raised when calling start() without parameters' );
+ }
+ assert.ok( $.isEmptyObject( durationLogger.starts ), 'No events saved by DurationLogger' );
+
+ durationLogger.start( 'foo' );
+ assert.strictEqual( durationLogger.starts.foo, 0, 'Event start saved' );
+
+ this.clock.tick( 1000 );
+ durationLogger.start( 'bar' );
+ assert.strictEqual( durationLogger.starts.bar, 1000, 'Later event start saved' );
+
+ durationLogger.start( 'foo' );
+ assert.strictEqual( durationLogger.starts.foo, 0, 'Event start not overritten' );
+
+ this.clock.tick( 666 );
+ durationLogger.start( [ 'baz', 'bob', 'bar' ] );
+ assert.strictEqual( durationLogger.starts.baz, 1666, 'First simultaneous event start saved' );
+ assert.strictEqual( durationLogger.starts.bob, 1666, 'Second simultaneous event start saved' );
+ assert.strictEqual( durationLogger.starts.bar, 1000, 'Third simultaneous event start not overwritten' );
+ } );
+
+ QUnit.test( 'stop()', function ( assert ) {
+ var durationLogger = new mw.mmv.durationLogger.constructor();
+
+ try {
+ durationLogger.stop();
+ } catch ( e ) {
+ assert.ok( true, 'Exception raised when calling stop() without parameters' );
+ }
+
+ durationLogger.stop( 'foo' );
+
+ assert.strictEqual( durationLogger.stops.foo, 0, 'Event stop saved' );
+
+ this.clock.tick( 1000 );
+ durationLogger.stop( 'foo' );
+
+ assert.strictEqual( durationLogger.stops.foo, 0, 'Event stop not overwritten' );
+
+ durationLogger.stop( 'foo', 1 );
+
+ assert.strictEqual( durationLogger.starts.foo, 1, 'Event start saved' );
+
+ durationLogger.stop( 'foo', 2 );
+
+ assert.strictEqual( durationLogger.starts.foo, 1, 'Event start not overwritten' );
+ } );
+
+ QUnit.test( 'record()', function ( assert ) {
+ var dependenciesDeferred = $.Deferred(),
+ fakeEventLog = { logEvent: this.sandbox.stub() },
+ durationLogger = new mw.mmv.durationLogger.constructor();
+
+ durationLogger.samplingFactor = 1;
+ durationLogger.schemaSupportsCountry = this.sandbox.stub().returns( true );
+
+ this.sandbox.stub( mw.user, 'isAnon' ).returns( false );
+ this.sandbox.stub( durationLogger, 'loadDependencies' ).returns( dependenciesDeferred.promise() );
+
+ try {
+ durationLogger.record();
+ } catch ( e ) {
+ assert.ok( true, 'Exception raised when calling record() without parameters' );
+ }
+
+ durationLogger.setEventLog( fakeEventLog );
+
+ durationLogger.start( 'bar' );
+ this.clock.tick( 1000 );
+ durationLogger.stop( 'bar' );
+ durationLogger.record( 'bar' );
+
+ assert.ok( !fakeEventLog.logEvent.called, 'Event queued if dependencies not loaded' );
+
+ // Queue a second item
+
+ durationLogger.start( 'bob' );
+ this.clock.tick( 4000 );
+ durationLogger.stop( 'bob' );
+ durationLogger.record( 'bob' );
+
+ assert.ok( !fakeEventLog.logEvent.called, 'Event queued if dependencies not loaded' );
+
+ dependenciesDeferred.resolve();
+ this.clock.tick( 10 );
+
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 0 ], 'MultimediaViewerDuration', 'EventLogging schema is correct' );
+ assert.deepEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ], { type: 'bar', duration: 1000, loggedIn: true, samplingFactor: 1 },
+ 'EventLogging data is correct' );
+
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 1 ).args[ 0 ], 'MultimediaViewerDuration', 'EventLogging schema is correct' );
+ assert.deepEqual( fakeEventLog.logEvent.getCall( 1 ).args[ 1 ], { type: 'bob', duration: 4000, loggedIn: true, samplingFactor: 1 },
+ 'EventLogging data is correct' );
+
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 2, 'logEvent called when processing the queue' );
+
+ durationLogger.start( 'foo' );
+ this.clock.tick( 3000 );
+ durationLogger.stop( 'foo' );
+ durationLogger.record( 'foo' );
+ this.clock.tick( 10 );
+
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 2 ).args[ 0 ], 'MultimediaViewerDuration', 'EventLogging schema is correct' );
+ assert.deepEqual( fakeEventLog.logEvent.getCall( 2 ).args[ 1 ], { type: 'foo', duration: 3000, loggedIn: true, samplingFactor: 1 },
+ 'EventLogging data is correct' );
+
+ assert.strictEqual( durationLogger.starts.bar, undefined, 'Start value deleted after record' );
+ assert.strictEqual( durationLogger.stops.bar, undefined, 'Stop value deleted after record' );
+
+ durationLogger.setGeo( { country: 'FR' } );
+ mw.user.isAnon.returns( true );
+
+ durationLogger.start( 'baz' );
+ this.clock.tick( 2000 );
+ durationLogger.stop( 'baz' );
+ durationLogger.record( 'baz' );
+ this.clock.tick( 10 );
+
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 3 ).args[ 0 ], 'MultimediaViewerDuration', 'EventLogging schema is correct' );
+ assert.deepEqual( fakeEventLog.logEvent.getCall( 3 ).args[ 1 ], { type: 'baz', duration: 2000, loggedIn: false, country: 'FR', samplingFactor: 1 },
+ 'EventLogging data is correct' );
+
+ assert.strictEqual( durationLogger.starts.bar, undefined, 'Start value deleted after record' );
+ assert.strictEqual( durationLogger.stops.bar, undefined, 'Stop value deleted after record' );
+
+ durationLogger.stop( 'fooz', $.now() - 9000 );
+ durationLogger.record( 'fooz' );
+ this.clock.tick( 10 );
+
+ assert.deepEqual( fakeEventLog.logEvent.getCall( 4 ).args[ 1 ], { type: 'fooz', duration: 9000, loggedIn: false, country: 'FR', samplingFactor: 1 },
+ 'EventLogging data is correct' );
+
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 5, 'logEvent has been called fives times at this point in the test' );
+
+ durationLogger.stop( 'foo' );
+ durationLogger.record( 'foo' );
+ this.clock.tick( 10 );
+
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 5, 'Record without a start doesn\'t get logged' );
+
+ durationLogger.start( 'foofoo' );
+ durationLogger.record( 'foofoo' );
+ this.clock.tick( 10 );
+
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 5, 'Record without a stop doesn\'t get logged' );
+
+ durationLogger.start( 'extra' );
+ this.clock.tick( 5000 );
+ durationLogger.stop( 'extra' );
+ durationLogger.record( 'extra', { bim: 'bam' } );
+ this.clock.tick( 10 );
+
+ assert.deepEqual( fakeEventLog.logEvent.getCall( 5 ).args[ 1 ], { type: 'extra', duration: 5000, loggedIn: false, country: 'FR', samplingFactor: 1, bim: 'bam' },
+ 'EventLogging data is correct' );
+ } );
+
+ QUnit.test( 'loadDependencies()', function ( assert ) {
+ var promise,
+ durationLogger = new mw.mmv.durationLogger.constructor();
+
+ this.sandbox.stub( mw.loader, 'using' );
+
+ mw.loader.using.withArgs( [ 'ext.eventLogging', 'schema.MultimediaViewerDuration' ] ).throwsException( 'EventLogging is missing' );
+
+ promise = durationLogger.loadDependencies();
+ this.clock.tick( 10 );
+
+ assert.strictEqual( promise.state(), 'rejected', 'Promise is rejected' );
+
+ // It's necessary to reset the stub, otherwise the original withArgs keeps running alongside the new one
+ mw.loader.using.restore();
+ this.sandbox.stub( mw.loader, 'using' );
+
+ mw.loader.using.withArgs( [ 'ext.eventLogging', 'schema.MultimediaViewerDuration' ] ).throwsException( 'EventLogging is missing' );
+
+ promise = durationLogger.loadDependencies();
+ this.clock.tick( 10 );
+
+ assert.strictEqual( promise.state(), 'rejected', 'Promise is rejected' );
+
+ // It's necessary to reset the stub, otherwise the original withArgs keeps running alongside the new one
+ mw.loader.using.restore();
+ this.sandbox.stub( mw.loader, 'using' );
+
+ mw.loader.using.withArgs( [ 'ext.eventLogging', 'schema.MultimediaViewerDuration' ] ).callsArg( 1 );
+
+ promise = durationLogger.loadDependencies();
+ this.clock.tick( 10 );
+
+ assert.strictEqual( promise.state(), 'resolved', 'Promise is resolved' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.PerformanceLogger.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.PerformanceLogger.test.js
new file mode 100644
index 00000000..81a621f7
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.PerformanceLogger.test.js
@@ -0,0 +1,341 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.logging.PerformanceLogger', QUnit.newMwEnvironment() );
+
+ function createFakeXHR( response ) {
+ return {
+ readyState: 0,
+ open: $.noop,
+ send: function () {
+ var xhr = this;
+
+ setTimeout( function () {
+ xhr.readyState = 4;
+ xhr.response = response;
+ if ( $.isFunction( xhr.onreadystatechange ) ) {
+ xhr.onreadystatechange();
+ }
+ }, 0 );
+ }
+ };
+ }
+
+ QUnit.test( 'recordEntry: basic', function ( assert ) {
+ var performance = new mw.mmv.logging.PerformanceLogger(),
+ fakeEventLog = { logEvent: this.sandbox.stub() },
+ type = 'gender',
+ total = 100,
+ // we'll be waiting for 4 promises to complete
+ asyncs = [ assert.async(), assert.async(), assert.async(), assert.async() ];
+
+ this.sandbox.stub( performance, 'loadDependencies' ).returns( $.Deferred().resolve() );
+ this.sandbox.stub( performance, 'isInSample' );
+ performance.setEventLog( fakeEventLog );
+
+ performance.isInSample.returns( false );
+
+ performance.recordEntry( type, total ).then( null, function () {
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 0, 'No stats should be logged if not in sample' );
+ asyncs.pop()();
+ } );
+
+ performance.isInSample.returns( true );
+
+ performance.recordEntry( type, total ).then( null, function () {
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 0 ], 'MultimediaViewerNetworkPerformance', 'EventLogging schema is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].type, type, 'type is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].total, total, 'total is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 1, 'Stats should be logged' );
+ asyncs.pop()();
+ } );
+
+ performance.recordEntry( type, total, 'URL' ).then( null, function () {
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 2, 'Stats should be logged' );
+ asyncs.pop()();
+ } );
+
+ performance.recordEntry( type, total, 'URL' ).then( null, function () {
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 2, 'Stats should not be logged a second time for the same URL' );
+ asyncs.pop()();
+ } );
+ } );
+
+ QUnit.test( 'recordEntry: with Navigation Timing data', function ( assert ) {
+ var fakeRequest,
+ varnish1 = 'cp1061',
+ varnish2 = 'cp3006',
+ varnish3 = 'cp3005',
+ varnish1hits = 0,
+ varnish2hits = 2,
+ varnish3hits = 1,
+ xvarnish = '1754811951 1283049064, 1511828531, 1511828573 1511828528',
+ xcache = varnish1 + ' miss (0), ' + varnish2 + ' miss (2), ' + varnish3 + ' frontend hit (1), malformed(5)',
+ age = '12345',
+ contentLength = '23456',
+ urlHost = 'fail',
+ date = 'Tue, 04 Feb 2014 11:11:50 GMT',
+ timestamp = 1391512310,
+ url = 'https://' + urlHost + '/balls.jpg',
+ redirect = 500,
+ dns = 2,
+ tcp = 10,
+ request = 25,
+ response = 50,
+ cache = 1,
+ perfData = {
+ initiatorType: 'xmlhttprequest',
+ name: url,
+ duration: 12345,
+ redirectStart: 1000,
+ redirectEnd: 1500,
+ domainLookupStart: 2,
+ domainLookupEnd: 4,
+ connectStart: 50,
+ connectEnd: 60,
+ requestStart: 125,
+ responseStart: 150,
+ responseEnd: 200,
+ fetchStart: 1
+ },
+ country = 'FR',
+ type = 'image',
+ performance = new mw.mmv.logging.PerformanceLogger(),
+ status = 200,
+ metered = true,
+ bandwidth = 45.67,
+ fakeEventLog = { logEvent: this.sandbox.stub() },
+ done = assert.async();
+
+ this.sandbox.stub( performance, 'loadDependencies' ).returns( $.Deferred().resolve() );
+ performance.setEventLog( fakeEventLog );
+ performance.schemaSupportsCountry = this.sandbox.stub().returns( true );
+
+ this.sandbox.stub( performance, 'getWindowPerformance' ).returns( {
+ getEntriesByName: function () {
+ return [ perfData, {
+ initiatorType: 'bogus',
+ duration: 1234,
+ name: url
+ } ];
+ }
+ } );
+
+ this.sandbox.stub( performance, 'getNavigatorConnection' ).returns( { metered: metered, bandwidth: bandwidth } );
+ this.sandbox.stub( performance, 'isInSample' ).returns( true );
+
+ fakeRequest = {
+ getResponseHeader: function ( header ) {
+ switch ( header ) {
+ case 'X-Cache':
+ return xcache;
+ case 'X-Varnish':
+ return xvarnish;
+ case 'Age':
+ return age;
+ case 'Content-Length':
+ return contentLength;
+ case 'Date':
+ return date;
+ }
+ },
+ status: status
+ };
+
+ performance.setGeo( { country: country } );
+
+ performance.recordEntry( type, 100, url, fakeRequest ).then( null, function () {
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 0 ], 'MultimediaViewerNetworkPerformance', 'EventLogging schema is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].type, type, 'type is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish1, varnish1, 'varnish1 is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish2, varnish2, 'varnish2 is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish3, varnish3, 'varnish3 is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish4, undefined, 'varnish4 is undefined' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish1hits, varnish1hits, 'varnish1hits is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish2hits, varnish2hits, 'varnish2hits is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish3hits, varnish3hits, 'varnish3hits is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].varnish4hits, undefined, 'varnish4hits is undefined' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].XVarnish, xvarnish, 'XVarnish is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].XCache, xcache, 'XCache is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].age, parseInt( age, 10 ), 'age is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].contentLength, parseInt( contentLength, 10 ), 'contentLength is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].contentHost, window.location.host, 'contentHost is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].urlHost, urlHost, 'urlHost is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].timestamp, timestamp, 'timestamp is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].total, perfData.duration, 'total is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].redirect, redirect, 'redirect is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].dns, dns, 'dns is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].tcp, tcp, 'tcp is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].request, request, 'request is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].response, response, 'response is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].cache, cache, 'cache is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].country, country, 'country is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].isHttps, true, 'isHttps is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].status, status, 'status is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].metered, metered, 'metered is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].bandwidth, Math.round( bandwidth ), 'bandwidth is correct' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'recordEntry: with async extra stats', function ( assert ) {
+ var performance = new mw.mmv.logging.PerformanceLogger(),
+ fakeEventLog = { logEvent: this.sandbox.stub() },
+ type = 'gender',
+ total = 100,
+ overriddenType = 'image',
+ foo = 'bar',
+ extraStatsPromise = $.Deferred(),
+ clock = this.sandbox.useFakeTimers();
+
+ this.sandbox.stub( performance, 'loadDependencies' ).returns( $.Deferred().resolve() );
+ this.sandbox.stub( performance, 'isInSample' );
+ performance.setEventLog( fakeEventLog );
+
+ performance.isInSample.returns( true );
+
+ performance.recordEntry( type, total, 'URL1', undefined, extraStatsPromise );
+
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 0, 'Stats should not be logged if the promise hasn\'t completed yet' );
+
+ extraStatsPromise.reject();
+
+ extraStatsPromise.then( null, function () {
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 1, 'Stats should be logged' );
+
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 0 ], 'MultimediaViewerNetworkPerformance', 'EventLogging schema is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].type, type, 'type is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 0 ).args[ 1 ].total, total, 'total is correct' );
+ } );
+
+ // make sure first promise is completed before recording another entry,
+ // to make sure data in fakeEventLog doesn't suffer race conditions
+ clock.tick( 10 );
+ clock.restore();
+
+ extraStatsPromise = $.Deferred();
+
+ performance.recordEntry( type, total, 'URL2', undefined, extraStatsPromise );
+
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 1, 'Stats should not be logged if the promise hasn\'t been resolved yet' );
+
+ extraStatsPromise.resolve( { type: overriddenType, foo: foo } );
+
+ return extraStatsPromise.then( function () {
+ assert.strictEqual( fakeEventLog.logEvent.callCount, 2, 'Stats should be logged' );
+
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 1 ).args[ 0 ], 'MultimediaViewerNetworkPerformance', 'EventLogging schema is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 1 ).args[ 1 ].type, overriddenType, 'type is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 1 ).args[ 1 ].total, total, 'total is correct' );
+ assert.strictEqual( fakeEventLog.logEvent.getCall( 1 ).args[ 1 ].foo, foo, 'extra stat is correct' );
+ } );
+ } );
+
+ QUnit.test( 'parseVarnishXCacheHeader', function ( assert ) {
+ var varnish1 = 'cp1061',
+ varnish2 = 'cp3006',
+ varnish3 = 'cp3005',
+ testString = varnish1 + ' miss (0), ' + varnish2 + ' miss (0), ' + varnish3 + ' frontend hit (1)',
+ performance = new mw.mmv.logging.PerformanceLogger(),
+ varnishXCache = performance.parseVarnishXCacheHeader( testString );
+
+ assert.strictEqual( varnishXCache.varnish1, varnish1, 'First varnish server name extracted' );
+ assert.strictEqual( varnishXCache.varnish2, varnish2, 'Second varnish server name extracted' );
+ assert.strictEqual( varnishXCache.varnish3, varnish3, 'Third varnish server name extracted' );
+ assert.strictEqual( varnishXCache.varnish4, undefined, 'Fourth varnish server is undefined' );
+ assert.strictEqual( varnishXCache.varnish1hits, 0, 'First varnish hit count extracted' );
+ assert.strictEqual( varnishXCache.varnish2hits, 0, 'Second varnish hit count extracted' );
+ assert.strictEqual( varnishXCache.varnish3hits, 1, 'Third varnish hit count extracted' );
+ assert.strictEqual( varnishXCache.varnish4hits, undefined, 'Fourth varnish hit count is undefined' );
+
+ testString = varnish1 + ' miss (36), ' + varnish2 + ' miss (2)';
+ varnishXCache = performance.parseVarnishXCacheHeader( testString );
+
+ assert.strictEqual( varnishXCache.varnish1, varnish1, 'First varnish server name extracted' );
+ assert.strictEqual( varnishXCache.varnish2, varnish2, 'Second varnish server name extracted' );
+ assert.strictEqual( varnishXCache.varnish3, undefined, 'Third varnish server is undefined' );
+ assert.strictEqual( varnishXCache.varnish1hits, 36, 'First varnish hit count extracted' );
+ assert.strictEqual( varnishXCache.varnish2hits, 2, 'Second varnish hit count extracted' );
+ assert.strictEqual( varnishXCache.varnish3hits, undefined, 'Third varnish hit count is undefined' );
+
+ varnishXCache = performance.parseVarnishXCacheHeader( 'garbage' );
+ assert.ok( $.isEmptyObject( varnishXCache ), 'Varnish cache results are empty' );
+ } );
+
+ QUnit.test( 'record()', function ( assert ) {
+ var type = 'foo',
+ url = 'http://example.com/',
+ response = {},
+ done = assert.async(),
+ performance = new mw.mmv.logging.PerformanceLogger();
+
+ performance.newXHR = function () { return createFakeXHR( response ); };
+
+ performance.recordEntryDelayed = function ( recordType, _, recordUrl, recordRequest ) {
+ assert.strictEqual( recordType, type, 'type is recorded correctly' );
+ assert.strictEqual( recordUrl, url, 'url is recorded correctly' );
+ assert.strictEqual( recordRequest.response, response, 'response is recorded correctly' );
+ done();
+ };
+
+ return performance.record( type, url ).done( function ( recordResponse ) {
+ assert.strictEqual( recordResponse, response, 'response is passed to callback' );
+ } );
+ } );
+
+ QUnit.test( 'record() with old browser', function ( assert ) {
+ var type = 'foo',
+ url = 'http://example.com/',
+ done = assert.async(),
+ performance = new mw.mmv.logging.PerformanceLogger();
+
+ performance.newXHR = function () { throw new Error( 'XMLHttpRequest? What\'s that?' ); };
+
+ performance.record( type, url ).fail( function () {
+ assert.ok( true, 'the promise is rejected when XMLHttpRequest is not supported' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'mw.mmv.logging.Api', function ( assert ) {
+ var api,
+ oldRecord = mw.mmv.logging.PerformanceLogger.prototype.recordJQueryEntryDelayed,
+ oldAjax = mw.Api.prototype.ajax,
+ ajaxCalled = false,
+ fakeJqxhr = {};
+
+ mw.Api.prototype.ajax = function () {
+ ajaxCalled = true;
+ return $.Deferred().resolve( {}, fakeJqxhr );
+ };
+
+ mw.mmv.logging.PerformanceLogger.prototype.recordJQueryEntryDelayed = function ( type, total, jqxhr ) {
+ assert.strictEqual( type, 'foo', 'type was passed correctly' );
+ assert.strictEqual( jqxhr, fakeJqxhr, 'jqXHR was passed correctly' );
+ };
+
+ api = new mw.mmv.logging.Api( 'foo' );
+
+ api.ajax();
+
+ assert.ok( ajaxCalled, 'parent ajax() function was called' );
+
+ mw.mmv.logging.PerformanceLogger.prototype.recordJQueryEntryDelayed = oldRecord;
+ mw.Api.prototype.ajax = oldAjax;
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ViewLogger.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ViewLogger.test.js
new file mode 100644
index 00000000..5da3633f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/logging/mmv.logging.ViewLogger.test.js
@@ -0,0 +1,87 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.logging.ViewLogger', QUnit.newMwEnvironment( {
+ setup: function () {
+ this.clock = this.sandbox.useFakeTimers();
+
+ // since jQuery 2/3, $.now will capture a reference to Date.now
+ // before above fake timer gets a chance to override it, so I'll
+ // override that new behavior in order to run these tests...
+ // @see https://github.com/sinonjs/lolex/issues/76
+ this.oldNow = $.now;
+ $.now = function () { return +( new Date() ); };
+ },
+
+ teardown: function () {
+ $.now = this.oldNow;
+ this.clock.restore();
+ }
+ } ) );
+
+ QUnit.test( 'unview()', function ( assert ) {
+ var logger = { log: $.noop },
+ viewLogger = new mw.mmv.logging.ViewLogger( { recordVirtualViewBeaconURI: $.noop }, {}, logger );
+
+ this.sandbox.stub( logger, 'log' );
+
+ viewLogger.unview();
+
+ assert.ok( !logger.log.called, 'action logger not called' );
+
+ viewLogger.setLastViewLogged( false );
+ viewLogger.unview();
+
+ assert.ok( !logger.log.called, 'action logger not called' );
+
+ viewLogger.setLastViewLogged( true );
+ viewLogger.unview();
+
+ assert.ok( logger.log.calledOnce, 'action logger called' );
+
+ viewLogger.unview();
+
+ assert.ok( logger.log.calledOnce, 'action logger not called again' );
+ } );
+
+ QUnit.test( 'focus and blur', function ( assert ) {
+ var fakeWindow = $( '<div>' ),
+ viewLogger = new mw.mmv.logging.ViewLogger( { recordVirtualViewBeaconURI: $.noop }, fakeWindow, { log: $.noop } );
+
+ this.clock.tick( 1 ); // This is just so that $.now() > 0 in the fake timer environment
+
+ viewLogger.attach();
+
+ this.clock.tick( 5 );
+
+ fakeWindow.triggerHandler( 'blur' );
+
+ this.clock.tick( 2 );
+
+ fakeWindow.triggerHandler( 'focus' );
+
+ this.clock.tick( 3 );
+
+ fakeWindow.triggerHandler( 'blur' );
+
+ this.clock.tick( 4 );
+
+ assert.strictEqual( viewLogger.viewDuration, 8, 'Only focus duration was logged' );
+ } );
+
+ QUnit.test( 'stopViewDuration before startViewDuration', function ( assert ) {
+ var viewLogger = new mw.mmv.logging.ViewLogger( { recordVirtualViewBeaconURI: $.noop }, {}, { log: $.noop } );
+
+ this.clock.tick( 1 ); // This is just so that $.now() > 0 in the fake timer environment
+
+ viewLogger.stopViewDuration();
+
+ this.clock.tick( 2 );
+
+ viewLogger.startViewDuration();
+
+ this.clock.tick( 3 );
+
+ viewLogger.stopViewDuration();
+
+ assert.strictEqual( viewLogger.viewDuration, 3, 'Only last timeframe was logged' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.Config.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.Config.test.js
new file mode 100644
index 00000000..0a1b6a61
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.Config.test.js
@@ -0,0 +1,203 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.Config', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity test', function ( assert ) {
+ var config = new mw.mmv.Config( {}, {}, {}, {}, null );
+ assert.ok( config );
+ } );
+
+ QUnit.test( 'Localstorage get', function ( assert ) {
+ var localStorage, config;
+
+ localStorage = mw.mmv.testHelpers.getUnsupportedLocalStorage(); // no browser support
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.getFromLocalStorage( 'foo' ), null, 'Returns null when not supported' );
+ assert.strictEqual( config.getFromLocalStorage( 'foo', 'bar' ), 'bar', 'Returns fallback when not supported' );
+
+ localStorage = mw.mmv.testHelpers.getDisabledLocalStorage(); // browser supports it but disabled
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.getFromLocalStorage( 'foo' ), null, 'Returns null when disabled' );
+ assert.strictEqual( config.getFromLocalStorage( 'foo', 'bar' ), 'bar', 'Returns fallback when disabled' );
+
+ localStorage = mw.mmv.testHelpers.createLocalStorage( { getItem: this.sandbox.stub() } );
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+
+ localStorage.store.getItem.withArgs( 'foo' ).returns( null );
+ assert.strictEqual( config.getFromLocalStorage( 'foo' ), null, 'Returns null when key not set' );
+ assert.strictEqual( config.getFromLocalStorage( 'foo', 'bar' ), 'bar', 'Returns fallback when key not set' );
+
+ localStorage.store.getItem.reset();
+ localStorage.store.getItem.withArgs( 'foo' ).returns( 'boom' );
+ assert.strictEqual( config.getFromLocalStorage( 'foo' ), 'boom', 'Returns correct value' );
+ assert.strictEqual( config.getFromLocalStorage( 'foo', 'bar' ), 'boom', 'Returns correct value ignoring fallback' );
+ } );
+
+ QUnit.test( 'Localstorage set', function ( assert ) {
+ var localStorage, config;
+
+ localStorage = mw.mmv.testHelpers.getUnsupportedLocalStorage(); // no browser support
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.setInLocalStorage( 'foo', 'bar' ), false, 'Returns false when not supported' );
+
+ localStorage = mw.mmv.testHelpers.getDisabledLocalStorage(); // browser supports it but disabled
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.setInLocalStorage( 'foo', 'bar' ), false, 'Returns false when disabled' );
+
+ localStorage = mw.mmv.testHelpers.createLocalStorage( { setItem: this.sandbox.stub() } );
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+
+ assert.strictEqual( config.setInLocalStorage( 'foo', 'bar' ), true, 'Returns true when works' );
+
+ localStorage.store.setItem.throwsException( 'localStorage full!' );
+ assert.strictEqual( config.setInLocalStorage( 'foo', 'bar' ), false, 'Returns false on error' );
+ } );
+
+ QUnit.test( 'Localstorage remove', function ( assert ) {
+ var localStorage, config;
+
+ localStorage = mw.mmv.testHelpers.getUnsupportedLocalStorage(); // no browser support
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.removeFromLocalStorage( 'foo' ), true, 'Returns true when not supported' );
+
+ localStorage = mw.mmv.testHelpers.getDisabledLocalStorage(); // browser supports it but disabled
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.removeFromLocalStorage( 'foo' ), true, 'Returns true when disabled' );
+
+ localStorage = mw.mmv.testHelpers.createLocalStorage( { removeItem: this.sandbox.stub() } );
+ config = new mw.mmv.Config( {}, {}, {}, {}, localStorage );
+ assert.strictEqual( config.removeFromLocalStorage( 'foo' ), true, 'Returns true when works' );
+ } );
+
+ QUnit.test( 'isMediaViewerEnabledOnClick', function ( assert ) {
+ var localStorage = mw.mmv.testHelpers.createLocalStorage( { getItem: this.sandbox.stub() } ),
+ mwConfig = { get: this.sandbox.stub() },
+ mwUser = { isAnon: this.sandbox.stub() },
+ config = new mw.mmv.Config( {}, mwConfig, mwUser, {}, localStorage );
+
+ mwUser.isAnon.returns( false );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( true );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), true, 'Returns true for logged-in with standard settings' );
+
+ mwUser.isAnon.returns( false );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( false );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( true );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), false, 'Returns false if opted out via user JS flag' );
+
+ mwUser.isAnon.returns( false );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( false );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), false, 'Returns false if opted out via preferences' );
+
+ mwUser.isAnon.returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( false );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( true );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), false, 'Returns false if anon user opted out via user JS flag' );
+
+ mwUser.isAnon.returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( false );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), false, 'Returns false if anon user opted out in some weird way' ); // apparently someone created a browser extension to do this
+
+ mwUser.isAnon.returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( true );
+ localStorage.store.getItem.withArgs( 'wgMediaViewerOnClick' ).returns( null );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), true, 'Returns true for anon with standard settings' );
+
+ mwUser.isAnon.returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewer' ).returns( true );
+ mwConfig.get.withArgs( 'wgMediaViewerOnClick' ).returns( true );
+ localStorage.store.getItem.withArgs( 'wgMediaViewerOnClick' ).returns( '0' );
+ assert.strictEqual( config.isMediaViewerEnabledOnClick(), false, 'Returns true for anon opted out via localSettings' );
+ } );
+
+ QUnit.test( 'setMediaViewerEnabledOnClick sanity check', function ( assert ) {
+ var localStorage = mw.mmv.testHelpers.createLocalStorage( {
+ getItem: this.sandbox.stub(),
+ setItem: this.sandbox.stub(),
+ removeItem: this.sandbox.stub()
+ } ),
+ mwUser = { isAnon: this.sandbox.stub() },
+ mwConfig = new mw.Map(),
+ api = { saveOption: this.sandbox.stub().returns( $.Deferred().resolve() ) },
+ config = new mw.mmv.Config( {}, mwConfig, mwUser, api, localStorage );
+ mwConfig.set( 'wgMediaViewerEnabledByDefault', false );
+
+ mwUser.isAnon.returns( false );
+ api.saveOption.returns( $.Deferred().resolve() );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.ok( api.saveOption.called, 'For logged-in users, pref change is via API' );
+
+ mwUser.isAnon.returns( true );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.ok( localStorage.store.setItem.called, 'For anons, opt-out is set in localStorage' );
+
+ mwUser.isAnon.returns( true );
+ config.setMediaViewerEnabledOnClick( true );
+ assert.ok( localStorage.store.removeItem.called, 'For anons, opt-in means clearing localStorage' );
+ } );
+
+ QUnit.test( 'shouldShowStatusInfo', function ( assert ) {
+ var config,
+ mwConfig = new mw.Map(),
+ fakeLocalStorage = mw.mmv.testHelpers.getFakeLocalStorage(),
+ mwUser = { isAnon: this.sandbox.stub() },
+ api = { saveOption: this.sandbox.stub().returns( $.Deferred().resolve() ) };
+
+ mwConfig.set( {
+ wgMediaViewer: true,
+ wgMediaViewerOnClick: true,
+ wgMediaViewerEnabledByDefault: true
+ } );
+ config = new mw.mmv.Config( {}, mwConfig, mwUser, api, fakeLocalStorage );
+ mwUser.isAnon.returns( false );
+
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Status info is not shown by default' );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.strictEqual( config.shouldShowStatusInfo(), true, 'Status info is shown after MMV is disabled the first time' );
+ config.setMediaViewerEnabledOnClick( true );
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Status info is not shown when MMV is enabled' );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.strictEqual( config.shouldShowStatusInfo(), true, 'Status info is shown after MMV is disabled the first time #2' );
+ config.disableStatusInfo();
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Status info is not shown when already displayed once' );
+ config.setMediaViewerEnabledOnClick( true );
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Further status changes have no effect' );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Further status changes have no effect #2' );
+
+ // make sure disabling calls maybeEnableStatusInfo() for logged-in as well
+ config.localStorage = mw.mmv.testHelpers.getFakeLocalStorage();
+ mwUser.isAnon.returns( true );
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Status info is not shown by default for logged-in users' );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.strictEqual( config.shouldShowStatusInfo(), true, 'Status info is shown after MMV is disabled the first time for logged-in users' );
+
+ // make sure popup is not shown immediately on disabled-by-default sites, but still works otherwise
+ config.localStorage = mw.mmv.testHelpers.getFakeLocalStorage();
+ mwConfig.set( 'wgMediaViewerEnabledByDefault', false );
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Status info is not shown by default #2' );
+ config.setMediaViewerEnabledOnClick( true );
+ assert.strictEqual( config.shouldShowStatusInfo(), false, 'Status info is not shown when MMV is enabled #2' );
+ config.setMediaViewerEnabledOnClick( false );
+ assert.strictEqual( config.shouldShowStatusInfo(), true, 'Status info is shown after MMV is disabled the first time #2' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.EmbedFileFormatter.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.EmbedFileFormatter.test.js
new file mode 100644
index 00000000..d215eaf5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.EmbedFileFormatter.test.js
@@ -0,0 +1,293 @@
+( function ( mw ) {
+ QUnit.module( 'mmv.EmbedFileFormatter', QUnit.newMwEnvironment() );
+
+ function createEmbedFileInfo( options ) {
+ var license = options.licenseShortName ? new mw.mmv.model.License( options.licenseShortName,
+ options.licenseInternalName, options.licenseLongName, options.licenseUrl ) : undefined,
+ imageInfo = new mw.mmv.model.Image(
+
+ options.title,
+ options.title.getNameText(),
+ undefined,
+ undefined,
+ undefined,
+ undefined,
+ options.imgUrl,
+ options.filePageUrl,
+ options.shortFilePageUrl,
+ 42,
+ 'repo',
+ undefined,
+ undefined,
+ undefined,
+ undefined,
+ options.source,
+ options.author,
+ options.authorCount,
+ license ),
+ repoInfo = { displayName: options.siteName, getSiteLink:
+ function () { return options.siteUrl; } };
+
+ return new mw.mmv.model.EmbedFileInfo( imageInfo, repoInfo, options.caption );
+ }
+
+ QUnit.test( 'EmbedFileFormatter constructor sanity check', function ( assert ) {
+ var formatter = new mw.mmv.EmbedFileFormatter();
+ assert.ok( formatter, 'constructor with no argument works' );
+ } );
+
+ QUnit.test( 'getByline():', function ( assert ) {
+ var formatter = new mw.mmv.EmbedFileFormatter(),
+ author = '<span class="mw-mmv-author">Homer</span>',
+ source = '<span class="mw-mmv-source">Iliad</span>',
+ attribution = '<span class="mw-mmv-attr">Cat</span>',
+ byline;
+
+ // Works with no arguments
+ byline = formatter.getByline();
+ assert.strictEqual( byline, undefined, 'No argument case handled correctly.' );
+
+ // Attribution present
+ byline = formatter.getByline( author, source, attribution );
+ assert.ok( byline.match( /Cat/ ), 'Attribution found in bylines' );
+
+ // Author and source present
+ byline = formatter.getByline( author, source );
+ assert.ok( byline.match( /Homer|Iliad/ ), 'Author and source found in bylines' );
+
+ // Only author present
+ byline = formatter.getByline( author );
+ assert.ok( byline.match( /Homer/ ), 'Author found in bylines.' );
+
+ // Only source present
+ byline = formatter.getByline( undefined, source );
+ assert.ok( byline.match( /Iliad/ ), 'Source found in bylines.' );
+ } );
+
+ QUnit.test( 'getSiteLink():', function ( assert ) {
+ var repoInfo = new mw.mmv.model.Repo( 'Wikipedia', '//wikipedia.org/favicon.ico', true ),
+ info = new mw.mmv.model.EmbedFileInfo( {}, repoInfo ),
+ formatter = new mw.mmv.EmbedFileFormatter(),
+ siteUrl = repoInfo.getSiteLink(),
+ siteLink = formatter.getSiteLink( info );
+
+ assert.ok( siteLink.match( 'Wikipedia' ), 'Site name is present in site link' );
+ assert.ok( siteLink.indexOf( siteUrl ) !== -1, 'Site URL is present in site link' );
+ } );
+
+ QUnit.test( 'getThumbnailHtml():', function ( assert ) {
+ var formatter = new mw.mmv.EmbedFileFormatter(),
+ titleText = 'Music Room',
+ title = mw.Title.newFromText( titleText ),
+ imgUrl = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ filePageUrl = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ filePageShortUrl = 'https://commons.wikimedia.org/wiki/index.php?curid=42',
+ siteName = 'Site Name',
+ siteUrl = '//site.url/',
+ licenseShortName = 'Public License',
+ licenseInternalName = '-',
+ licenseLongName = 'Public Domain, copyrights have lapsed',
+ licenseUrl = '//example.com/pd',
+ author = '<span class="mw-mmv-author">Homer</span>',
+ source = '<span class="mw-mmv-source">Iliad</span>',
+ thumbUrl = 'https://upload.wikimedia.org/wikipedia/thumb/Foobar.jpg',
+ width = 700,
+ height = 500,
+ info,
+ generatedHtml;
+
+ // Bylines, license and site
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl,
+ shortFilePageUrl: filePageShortUrl, siteName: siteName, siteUrl: siteUrl,
+ licenseShortName: licenseShortName, licenseInternalName: licenseInternalName,
+ licenseLongName: licenseLongName, licenseUrl: licenseUrl, author: author, source: source } );
+
+ generatedHtml = formatter.getThumbnailHtml( info, thumbUrl, width, height );
+ assert.ok( generatedHtml.match( titleText ), 'Title appears in generated HTML.' );
+ assert.ok( generatedHtml.match( filePageUrl ), 'Page url appears in generated HTML.' );
+ assert.ok( generatedHtml.match( thumbUrl ), 'Thumbnail url appears in generated HTML' );
+ assert.ok( generatedHtml.match( 'Public License' ), 'License appears in generated HTML' );
+ assert.ok( generatedHtml.match( 'Homer' ), 'Author appears in generated HTML' );
+ assert.ok( generatedHtml.match( 'Iliad' ), 'Source appears in generated HTML' );
+ assert.ok( generatedHtml.match( width ), 'Width appears in generated HTML' );
+ assert.ok( generatedHtml.match( height ), 'Height appears in generated HTML' );
+ // .includes() for checking the short url since it contains a ? (bad for regex). Could escape instead.
+ assert.ok( generatedHtml.includes( filePageShortUrl ), 'Short URL appears in generated HTML' );
+
+ // Bylines, no license and site
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl,
+ shortFilePageUrl: filePageShortUrl, siteName: siteName, siteUrl: siteUrl,
+ author: author, source: source } );
+ generatedHtml = formatter.getThumbnailHtml( info, thumbUrl, width, height );
+
+ assert.ok( generatedHtml.match( titleText ), 'Title appears in generated HTML.' );
+ assert.ok( generatedHtml.match( filePageUrl ), 'Page url appears in generated HTML.' );
+ assert.ok( generatedHtml.match( thumbUrl ), 'Thumbnail url appears in generated HTML' );
+ assert.ok( !generatedHtml.match( 'Public License' ), 'License should not appear in generated HTML' );
+ assert.ok( generatedHtml.match( 'Homer' ), 'Author appears in generated HTML' );
+ assert.ok( generatedHtml.match( 'Iliad' ), 'Source appears in generated HTML' );
+ assert.ok( generatedHtml.match( width ), 'Width appears in generated HTML' );
+ assert.ok( generatedHtml.match( height ), 'Height appears in generated HTML' );
+ assert.ok( generatedHtml.includes( filePageShortUrl ), 'Short URL appears in generated HTML' );
+
+ // No bylines, license and site
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl,
+ siteName: siteName, siteUrl: siteUrl, licenseShortName: licenseShortName,
+ licenseInternalName: licenseInternalName, licenseLongName: licenseLongName,
+ licenseUrl: licenseUrl, shortFilePageUrl: filePageShortUrl } );
+ generatedHtml = formatter.getThumbnailHtml( info, thumbUrl, width, height );
+
+ assert.ok( generatedHtml.match( titleText ), 'Title appears in generated HTML.' );
+ assert.ok( generatedHtml.match( filePageUrl ), 'Page url appears in generated HTML.' );
+ assert.ok( generatedHtml.match( thumbUrl ), 'Thumbnail url appears in generated HTML' );
+ assert.ok( generatedHtml.match( 'Public License' ), 'License appears in generated HTML' );
+ assert.ok( !generatedHtml.match( 'Homer' ), 'Author should not appear in generated HTML' );
+ assert.ok( !generatedHtml.match( 'Iliad' ), 'Source should not appear in generated HTML' );
+ assert.ok( generatedHtml.match( width ), 'Width appears in generated HTML' );
+ assert.ok( generatedHtml.match( height ), 'Height appears in generated HTML' );
+ assert.ok( generatedHtml.includes( filePageShortUrl ), 'Short URL appears in generated HTML' );
+
+ // No bylines, no license and site
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl,
+ siteName: siteName, siteUrl: siteUrl, shortFilePageUrl: filePageShortUrl } );
+ generatedHtml = formatter.getThumbnailHtml( info, thumbUrl, width, height );
+
+ assert.ok( generatedHtml.match( titleText ), 'Title appears in generated HTML.' );
+ assert.ok( generatedHtml.match( filePageUrl ), 'Page url appears in generated HTML.' );
+ assert.ok( generatedHtml.match( thumbUrl ), 'Thumbnail url appears in generated HTML' );
+ assert.ok( !generatedHtml.match( 'Public License' ), 'License should not appear in generated HTML' );
+ assert.ok( !generatedHtml.match( 'Homer' ), 'Author should not appear in generated HTML' );
+ assert.ok( !generatedHtml.match( 'Iliad' ), 'Source should not appear in generated HTML' );
+ assert.ok( generatedHtml.match( width ), 'Width appears in generated HTML' );
+ assert.ok( generatedHtml.match( height ), 'Height appears in generated HTML' );
+ assert.ok( generatedHtml.includes( filePageShortUrl ), 'Short URL appears in generated HTML' );
+
+ } );
+
+ QUnit.test( 'getThumbnailWikitext():', function ( assert ) {
+ var formatter = new mw.mmv.EmbedFileFormatter(),
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ imgUrl = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ filePageUrl = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ caption = 'Foobar caption.',
+ width = 700,
+ info,
+ wikitext;
+
+ // Title, width and caption
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl,
+ caption: caption } );
+ wikitext = formatter.getThumbnailWikitextFromEmbedFileInfo( info, width );
+
+ assert.strictEqual(
+ wikitext,
+ '[[File:Foobar.jpg|700px|thumb|Foobar caption.]]',
+ 'Wikitext generated correctly.' );
+
+ // Title, width and no caption
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl } );
+ wikitext = formatter.getThumbnailWikitextFromEmbedFileInfo( info, width );
+
+ assert.strictEqual(
+ wikitext,
+ '[[File:Foobar.jpg|700px|thumb|Foobar]]',
+ 'Wikitext generated correctly.' );
+
+ // Title, no width and no caption
+ info = createEmbedFileInfo( { title: title, imgUrl: imgUrl, filePageUrl: filePageUrl } );
+ wikitext = formatter.getThumbnailWikitextFromEmbedFileInfo( info );
+
+ assert.strictEqual(
+ wikitext,
+ '[[File:Foobar.jpg|thumb|Foobar]]',
+ 'Wikitext generated correctly.' );
+ } );
+
+ QUnit.test( 'getCreditText():', function ( assert ) {
+ var txt, formatter = new mw.mmv.EmbedFileFormatter();
+
+ txt = formatter.getCreditText( {
+ repoInfo: {
+ displayName: 'Localcommons'
+ },
+
+ imageInfo: {
+ author: 'Author',
+ source: 'Source',
+ descriptionShortUrl: 'link',
+ title: {
+ getNameText: function () { return 'Image Title'; }
+ }
+ }
+ } );
+
+ assert.strictEqual( txt, 'By Author - Source, link', 'Sanity check' );
+
+ txt = formatter.getCreditText( {
+ repoInfo: {
+ displayName: 'Localcommons'
+ },
+
+ imageInfo: {
+ author: 'Author',
+ source: 'Source',
+ descriptionShortUrl: 'link',
+ title: {
+ getNameText: function () { return 'Image Title'; }
+ },
+ license: {
+ getShortName: function () { return 'WTFPL v2'; },
+ longName: 'Do What the Fuck You Want Public License Version 2',
+ isFree: this.sandbox.stub().returns( true )
+ }
+ }
+ } );
+
+ assert.strictEqual( txt, 'By Author - Source, WTFPL v2, link', 'License message works' );
+ } );
+
+ QUnit.test( 'getCreditHtml():', function ( assert ) {
+ var html, formatter = new mw.mmv.EmbedFileFormatter();
+
+ html = formatter.getCreditHtml( {
+ repoInfo: {
+ displayName: 'Localcommons',
+ getSiteLink: function () { return 'quux'; }
+ },
+
+ imageInfo: {
+ author: 'Author',
+ source: 'Source',
+ descriptionShortUrl: 'some link',
+ title: {
+ getNameText: function () { return 'Image Title'; }
+ }
+ }
+ } );
+
+ assert.strictEqual( html, 'By Author - Source, <a href="some link">Link</a>', 'Sanity check' );
+
+ html = formatter.getCreditHtml( {
+ repoInfo: {
+ displayName: 'Localcommons',
+ getSiteLink: function () { return 'quux'; }
+ },
+
+ imageInfo: {
+ author: 'Author',
+ source: 'Source',
+ descriptionShortUrl: 'some link',
+ title: {
+ getNameText: function () { return 'Image Title'; }
+ },
+ license: {
+ getShortLink: function () { return '<a href="http://www.wtfpl.net/">WTFPL v2</a>'; },
+ longName: 'Do What the Fuck You Want Public License Version 2',
+ isFree: this.sandbox.stub().returns( true )
+ }
+ }
+ } );
+
+ assert.strictEqual( html, 'By Author - Source, <a href="http://www.wtfpl.net/">WTFPL v2</a>, <a href="some link">Link</a>', 'Sanity check' );
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.HtmlUtils.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.HtmlUtils.test.js
new file mode 100644
index 00000000..48c0076f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.HtmlUtils.test.js
@@ -0,0 +1,192 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.HtmlUtils', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'wrapAndJquerify() for single node', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $el = $( '<span>' ),
+ el = $( '<span>' ).get( 0 ),
+ html = '<span></span>',
+ invalid = {};
+
+ assert.strictEqual( utils.wrapAndJquerify( $el ).html(), '<span></span>', 'jQuery' );
+ assert.strictEqual( utils.wrapAndJquerify( el ).html(), '<span></span>', 'HTMLElement' );
+ assert.strictEqual( utils.wrapAndJquerify( html ).html(), '<span></span>', 'HTML string' );
+
+ try {
+ utils.wrapAndJquerify( invalid );
+ } catch ( e ) {
+ assert.ok( e, 'throws exception for invalid type' );
+ }
+ } );
+
+ QUnit.test( 'wrapAndJquerify() for multiple nodes', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $el = $( '<span></span><span></span>' ),
+ html = '<span></span><span></span>';
+
+ assert.strictEqual( utils.wrapAndJquerify( $el ).html(), '<span></span><span></span>', 'jQuery' );
+ assert.strictEqual( utils.wrapAndJquerify( html ).html(), '<span></span><span></span>', 'HTML string' );
+ } );
+
+ QUnit.test( 'wrapAndJquerify() for text', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $el = $( document.createTextNode( 'foo' ) ),
+ html = 'foo';
+
+ assert.strictEqual( utils.wrapAndJquerify( $el ).html(), 'foo', 'jQuery' );
+ assert.strictEqual( utils.wrapAndJquerify( html ).html(), 'foo', 'HTML string' );
+ } );
+
+ QUnit.test( 'wrapAndJquerify() does not change original', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $el = $( '<span>' ),
+ el = $( '<span>' ).get( 0 );
+
+ utils.wrapAndJquerify( $el ).find( 'span' ).prop( 'data-x', 1 );
+ utils.wrapAndJquerify( el ).find( 'span' ).prop( 'data-x', 1 );
+ assert.strictEqual( $el.prop( 'data-x' ), undefined, 'wrapped jQuery element is not the same as original' );
+ assert.strictEqual( $( el ).prop( 'data-x' ), undefined, 'wrapped HTMLElement is not the same as original' );
+ } );
+
+ QUnit.test( 'filterInvisible()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $visibleChild = $( '<div><span></span></div>' ),
+ $invisibleChild = $( '<div><span style="display: none"></span></div>' ),
+ $invisibleChildInVisibleChild = $( '<div><span><abbr style="display: none"></abbr></span></div>' ),
+ $visibleChildInInvisibleChild = $( '<div><span style="display: none"><abbr></abbr></span></div>' ),
+ $invisibleChildWithVisibleSiblings = $( '<div><span></span><abbr style="display: none"></abbr><b></b></div>' );
+
+ utils.filterInvisible( $visibleChild );
+ utils.filterInvisible( $invisibleChild );
+ utils.filterInvisible( $invisibleChildInVisibleChild );
+ utils.filterInvisible( $visibleChildInInvisibleChild );
+ utils.filterInvisible( $invisibleChildWithVisibleSiblings );
+
+ assert.ok( $visibleChild.has( 'span' ).length, 'visible child is not filtered' );
+ assert.ok( !$invisibleChild.has( 'span' ).length, 'invisible child is filtered' );
+ assert.ok( $invisibleChildInVisibleChild.has( 'span' ).length, 'visible child is not filtered...' );
+ assert.ok( !$invisibleChildInVisibleChild.has( 'abbr' ).length, '... but its invisible child is' );
+ assert.ok( !$visibleChildInInvisibleChild.has( 'span' ).length, 'invisible child is filtered...' );
+ assert.ok( !$visibleChildInInvisibleChild.has( 'abbr' ).length, '...and its children too' );
+ assert.ok( $visibleChild.has( 'span' ).length, 'visible child is not filtered' );
+ assert.ok( !$invisibleChildWithVisibleSiblings.has( 'abbr' ).length, 'invisible sibling is filtered...' );
+ assert.ok( $invisibleChildWithVisibleSiblings.has( 'span' ).length, '...but its visible siblings are not' );
+ assert.ok( $invisibleChildWithVisibleSiblings.has( 'b' ).length, '...but its visible siblings are not' );
+ } );
+
+ QUnit.test( 'whitelistHtml()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $whitelisted = $( '<div>abc<a>def</a>ghi</div>' ),
+ $nonWhitelisted = $( '<div>abc<span>def</span>ghi</div>' ),
+ $nonWhitelistedInWhitelisted = $( '<div>abc<a>d<span>e</span>f</a>ghi</div>' ),
+ $whitelistedInNonWhitelisted = $( '<div>abc<span>d<a>e</a>f</span>ghi</div>' ),
+ $siblings = $( '<div>ab<span>c</span>d<a>e</a>f<span>g</span>hi</div>' );
+
+ utils.whitelistHtml( $whitelisted, 'a' );
+ utils.whitelistHtml( $nonWhitelisted, 'a' );
+ utils.whitelistHtml( $nonWhitelistedInWhitelisted, 'a' );
+ utils.whitelistHtml( $whitelistedInNonWhitelisted, 'a' );
+ utils.whitelistHtml( $siblings, 'a' );
+
+ assert.ok( $whitelisted.has( 'a' ).length, 'Whitelisted elements are kept.' );
+ assert.ok( !$nonWhitelisted.has( 'span' ).length, 'Non-whitelisted elements are removed.' );
+ assert.ok( $nonWhitelistedInWhitelisted.has( 'a' ).length, 'Whitelisted parents are kept.' );
+ assert.ok( !$nonWhitelistedInWhitelisted.has( 'span' ).length, 'Non-whitelisted children are removed.' );
+ assert.ok( !$whitelistedInNonWhitelisted.has( 'span' ).length, 'Non-whitelisted parents are removed.' );
+ assert.ok( $whitelistedInNonWhitelisted.has( 'a' ).length, 'Whitelisted children are kept.' );
+ assert.ok( !$siblings.has( 'span' ).length, 'Non-whitelisted siblings are removed.' );
+ assert.ok( $siblings.has( 'a' ).length, 'Whitelisted siblings are kept.' );
+ } );
+
+ QUnit.test( 'appendWhitespaceToBlockElements()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ $noBlockElement = $( '<div>abc<i>def</i>ghi</div>' ),
+ $blockElement = $( '<div>abc<p>def</p>ghi</div>' ),
+ $linebreak = $( '<div>abc<br>def</div>' );
+
+ utils.appendWhitespaceToBlockElements( $noBlockElement );
+ utils.appendWhitespaceToBlockElements( $blockElement );
+ utils.appendWhitespaceToBlockElements( $linebreak );
+
+ assert.ok( $noBlockElement.text().match( /abcdefghi/ ), 'Non-block elemens are not whitespaced.' );
+ assert.ok( $blockElement.text().match( /abc\s+def\s+ghi/ ), 'Block elemens are whitespaced.' );
+ assert.ok( $linebreak.text().match( /abc\s+def/ ), 'Linebreaks are whitespaced.' );
+ } );
+
+ QUnit.test( 'jqueryToHtml()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils();
+
+ assert.strictEqual( utils.jqueryToHtml( $( '<a>' ) ), '<a></a>',
+ 'works for single element' );
+ assert.strictEqual( utils.jqueryToHtml( $( '<b><a>foo</a></b>' ) ), '<b><a>foo</a></b>',
+ 'works for complex element' );
+ assert.strictEqual( utils.jqueryToHtml( $( '<a>foo</a>' ).contents() ), 'foo',
+ 'works for text nodes' );
+ } );
+
+ QUnit.test( 'mergeWhitespace()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils();
+
+ assert.strictEqual( utils.mergeWhitespace( ' x \n' ), 'x',
+ 'leading/trainling whitespace is trimmed' );
+ assert.strictEqual( utils.mergeWhitespace( 'x \n\n \n y' ), 'x\ny',
+ 'whitespace containing a newline is collapsed into a single newline' );
+ assert.strictEqual( utils.mergeWhitespace( 'x y' ), 'x y',
+ 'multiple spaces are collapsed into a single one' );
+ } );
+
+ QUnit.test( 'htmlToText()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ html = '<table><tr><td>Foo</td><td><a>bar</a></td><td style="display: none">baz</td></tr></table>';
+
+ assert.strictEqual( utils.htmlToText( html ), 'Foo bar', 'works' );
+ } );
+
+ QUnit.test( 'htmlToTextWithLinks()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ html = '<table><tr><td><b>F</b>o<i>o</i></td><td><a>bar</a></td><td style="display: none">baz</td></tr></table>';
+
+ assert.strictEqual( utils.htmlToTextWithLinks( html ), 'Foo <a>bar</a>', 'works' );
+ } );
+
+ QUnit.test( 'htmlToTextWithTags()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils(),
+ html = '<table><tr><td><b>F</b>o<i>o</i><sub>o</sub><sup>o</sup></td><td><a>bar</a></td><td style="display: none">baz</td></tr></table>';
+
+ assert.strictEqual( utils.htmlToTextWithTags( html ), '<b>F</b>o<i>o</i><sub>o</sub><sup>o</sup> <a>bar</a>', 'works' );
+ } );
+
+ QUnit.test( 'isJQueryOrHTMLElement()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils();
+
+ assert.ok( utils.isJQueryOrHTMLElement( $( '<span>' ) ), 'Recognizes jQuery objects correctly' );
+ assert.ok( utils.isJQueryOrHTMLElement( $( '<span>' ).get( 0 ) ), 'Recognizes HTMLElements correctly' );
+ assert.ok( !utils.isJQueryOrHTMLElement( '<span></span>' ), 'Recognizes jQuery objects correctly' );
+ } );
+
+ QUnit.test( 'makeLinkText()', function ( assert ) {
+ var utils = new mw.mmv.HtmlUtils();
+
+ assert.strictEqual( utils.makeLinkText( 'foo', {
+ href: 'http://example.com',
+ title: 'h<b>t</b><i>m</i>l'
+ } ), '<a href="http://example.com" title="html">foo</a>', 'works' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.ThumbnailWidthCalculator.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.ThumbnailWidthCalculator.test.js
new file mode 100644
index 00000000..33484e42
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.ThumbnailWidthCalculator.test.js
@@ -0,0 +1,149 @@
+( function ( mw ) {
+ QUnit.module( 'mmv.ThumbnailWidthCalculator', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'ThumbnailWidthCalculator constructor sanity check', function ( assert ) {
+ var badWidthBuckets = [],
+ goodWidthBuckets = [ 1 ],
+ thumbnailWidthCalculator;
+
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator();
+ assert.ok( thumbnailWidthCalculator, 'constructor with no argument works' );
+
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {} );
+ assert.ok( thumbnailWidthCalculator, 'constructor with empty option argument works' );
+
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {
+ widthBuckets: goodWidthBuckets
+ } );
+ assert.ok( thumbnailWidthCalculator, 'constructor with non-default buckets works' );
+
+ try {
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {
+ widthBuckets: badWidthBuckets
+ } );
+ } catch ( e ) {
+ assert.ok( e, 'constructor with empty bucket list throws exception' );
+ }
+ } );
+
+ QUnit.test( 'findNextBucket() test', function ( assert ) {
+ var thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {
+ widthBuckets: [ 100, 200 ]
+ } );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 50 ), 100,
+ 'return first bucket for value smaller than all buckets' );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 300 ), 200,
+ 'return last bucket for value larger than all buckets' );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 150 ), 200,
+ 'return next bucket for value between two buckets' );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 100 ), 100,
+ 'return bucket for value equal to that bucket' );
+ } );
+
+ // Old tests for the default bucket sizes. Preserved because why not.
+ QUnit.test( 'We get sane image sizes when we ask for them', function ( assert ) {
+ var twc = new mw.mmv.ThumbnailWidthCalculator();
+
+ assert.strictEqual( twc.findNextBucket( 200 ), 320, 'Low target size gives us lowest possible size bucket' );
+ assert.strictEqual( twc.findNextBucket( 320 ), 320, 'Asking for a bucket size gives us exactly that bucket size' );
+ assert.strictEqual( twc.findNextBucket( 320.00001 ), 800, 'Asking for greater than an image bucket definitely gives us the next size up' );
+ assert.strictEqual( twc.findNextBucket( 2000 ), 2560, 'The image bucketing also works on big screens' );
+ assert.strictEqual( twc.findNextBucket( 3000 ), 2880, 'The image bucketing also works on REALLY big screens' );
+ } );
+
+ QUnit.test( 'findNextBucket() test with unordered bucket list', function ( assert ) {
+ var thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {
+ widthBuckets: [ 200, 100 ]
+ } );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 50 ), 100,
+ 'return first bucket for value smaller than all buckets' );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 300 ), 200,
+ 'return last bucket for value larger than all buckets' );
+
+ assert.strictEqual( thumbnailWidthCalculator.findNextBucket( 150 ), 200,
+ 'return next bucket for value between two buckets' );
+ } );
+
+ QUnit.test( 'calculateFittingWidth() test', function ( assert ) {
+ var boundingWidth = 100,
+ boundingHeight = 200,
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( { widthBuckets: [ 1 ] } );
+
+ // 50x10 image in 100x200 box - need to scale up 2x
+ assert.strictEqual(
+ thumbnailWidthCalculator.calculateFittingWidth( boundingWidth, boundingHeight, 50, 10 ),
+ 100, 'fit calculation correct when limited by width' );
+
+ // 10x100 image in 100x200 box - need to scale up 2x
+ assert.strictEqual(
+ thumbnailWidthCalculator.calculateFittingWidth( boundingWidth, boundingHeight, 10, 100 ),
+ 20, 'fit calculation correct when limited by height' );
+
+ // 10x20 image in 100x200 box - need to scale up 10x
+ assert.strictEqual(
+ thumbnailWidthCalculator.calculateFittingWidth( boundingWidth, boundingHeight, 10, 20 ),
+ 100, 'fit calculation correct when same aspect ratio' );
+ } );
+
+ QUnit.test( 'calculateWidths() test', function ( assert ) {
+ var boundingWidth = 100,
+ boundingHeight = 200,
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {
+ widthBuckets: [ 8, 16, 32, 64, 128, 256, 512 ],
+ devicePixelRatio: 1
+ } ),
+ widths;
+
+ // 50x10 image in 100x200 box - image size should be 100x20, thumbnail should be 128x25.6
+ widths = thumbnailWidthCalculator.calculateWidths( boundingWidth, boundingHeight, 50, 10 );
+ assert.strictEqual( widths.cssWidth, 100, 'css width is correct when limited by width' );
+ assert.strictEqual( widths.cssHeight, 20, 'css height is correct when limited by width' );
+ assert.strictEqual( widths.real, 128, 'real width is correct when limited by width' );
+
+ // 10x100 image in 100x200 box - image size should be 20x200, thumbnail should be 32x320
+ widths = thumbnailWidthCalculator.calculateWidths( boundingWidth, boundingHeight, 10, 100 );
+ assert.strictEqual( widths.cssWidth, 20, 'css width is correct when limited by height' );
+ assert.strictEqual( widths.cssHeight, 200, 'css height is correct when limited by width' );
+ assert.strictEqual( widths.real, 32, 'real width is correct when limited by height' );
+
+ // 10x20 image in 100x200 box - image size should be 100x200, thumbnail should be 128x256
+ widths = thumbnailWidthCalculator.calculateWidths( boundingWidth, boundingHeight, 10, 20 );
+ assert.strictEqual( widths.cssWidth, 100, 'css width is correct when same aspect ratio' );
+ assert.strictEqual( widths.cssHeight, 200, 'css height is correct when limited by width' );
+ assert.strictEqual( widths.real, 128, 'real width is correct when same aspect ratio' );
+ } );
+
+ QUnit.test( 'calculateWidths() test with non-standard device pixel ratio', function ( assert ) {
+ var boundingWidth = 100,
+ boundingHeight = 200,
+ thumbnailWidthCalculator = new mw.mmv.ThumbnailWidthCalculator( {
+ widthBuckets: [ 8, 16, 32, 64, 128, 256, 512 ],
+ devicePixelRatio: 2
+ } ),
+ widths;
+
+ // 50x10 image in 100x200 box - image size should be 100x20, thumbnail should be 256x51.2
+ widths = thumbnailWidthCalculator.calculateWidths( boundingWidth, boundingHeight, 50, 10 );
+ assert.strictEqual( widths.cssWidth, 100, 'css width is correct when limited by width' );
+ assert.strictEqual( widths.cssHeight, 20, 'css height is correct when limited by width' );
+ assert.strictEqual( widths.real, 256, 'real width is correct when limited by width' );
+
+ // 10x100 image in 100x200 box - image size should be 20x200, thumbnail should be 64x640
+ widths = thumbnailWidthCalculator.calculateWidths( boundingWidth, boundingHeight, 10, 100 );
+ assert.strictEqual( widths.cssWidth, 20, 'css width is correct when limited by height' );
+ assert.strictEqual( widths.cssHeight, 200, 'css height is correct when limited by width' );
+ assert.strictEqual( widths.real, 64, 'real width is correct when limited by height' );
+
+ // 10x20 image in 100x200 box - image size should be 100x200, thumbnail should be 256x512
+ widths = thumbnailWidthCalculator.calculateWidths( boundingWidth, boundingHeight, 10, 20 );
+ assert.strictEqual( widths.cssWidth, 100, 'css width is correct when same aspect ratio' );
+ assert.strictEqual( widths.cssHeight, 200, 'css height is correct when limited by width' );
+ assert.strictEqual( widths.real, 256, 'real width is correct when same aspect ratio' );
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.bootstrap.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.bootstrap.test.js
new file mode 100644
index 00000000..793f2b52
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.bootstrap.test.js
@@ -0,0 +1,582 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.bootstrap', QUnit.newMwEnvironment( {
+ setup: function () {
+ mw.config.set( 'wgMediaViewer', true );
+ mw.config.set( 'wgMediaViewerOnClick', true );
+ this.sandbox.stub( mw.user, 'isAnon' ).returns( false );
+ }
+ } ) );
+
+ function createGallery( imageSrc, caption ) {
+ var $div = $( '<div>' ).addClass( 'gallery' ).appendTo( '#qunit-fixture' ),
+ $galleryBox = $( '<div>' ).addClass( 'gallerybox' ).appendTo( $div ),
+ $thumbwrap = $( '<div>' ).addClass( 'thumb' ).appendTo( $galleryBox ),
+ $link = $( '<a>' ).addClass( 'image' ).appendTo( $thumbwrap );
+
+ $( '<img>' ).attr( 'src', ( imageSrc || 'thumb.jpg' ) ).appendTo( $link );
+ $( '<div>' ).addClass( 'gallerytext' ).text( caption || 'Foobar' ).appendTo( $galleryBox );
+
+ return $div;
+ }
+
+ function createThumb( imageSrc, caption, alt ) {
+ var $div = $( '<div>' ).addClass( 'thumb' ).appendTo( '#qunit-fixture' ),
+ $link = $( '<a>' ).addClass( 'image' ).appendTo( $div );
+
+ $( '<div>' ).addClass( 'thumbcaption' ).appendTo( $div ).text( caption );
+ $( '<img>' ).attr( 'src', ( imageSrc || 'thumb.jpg' ) ).attr( 'alt', alt ).appendTo( $link );
+
+ return $div;
+ }
+
+ function createNormal( imageSrc, caption ) {
+ var $link = $( '<a>' ).prop( 'title', caption ).addClass( 'image' ).appendTo( '#qunit-fixture' );
+ $( '<img>' ).prop( 'src', ( imageSrc || 'thumb.jpg' ) ).appendTo( $link );
+ return $link;
+ }
+
+ function createMultipleImage( images ) {
+ var i, $div, $thumbimage, $link,
+ $contain = $( '<div>' ).addClass( 'thumb' ),
+ $thumbinner = $( '<div>' ).addClass( 'thumbinner' ).appendTo( $contain );
+ for ( i = 0; i < images.length; ++i ) {
+ $div = $( '<div>' ).appendTo( $thumbinner );
+ $thumbimage = $( '<div>' ).addClass( 'thumbimage' ).appendTo( $div );
+ $link = $( '<a>' ).addClass( 'image' ).appendTo( $thumbimage );
+ $( '<img>' ).prop( 'src', images[ i ][ 0 ] ).appendTo( $link );
+ $( '<div>' ).addClass( 'thumbcaption' ).text( images[ i ][ 1 ] ).appendTo( $div );
+ }
+ return $contain;
+ }
+
+ function createBootstrap( viewer ) {
+ var bootstrap = new mw.mmv.MultimediaViewerBootstrap();
+
+ bootstrap.processThumbs( $( '#qunit-fixture' ) );
+
+ // MultimediaViewerBootstrap.ensureEventHandlersAreSetUp() is a weird workaround for gadget bugs.
+ // MediaViewer should work without it, and so should the tests.
+ bootstrap.ensureEventHandlersAreSetUp = $.noop;
+
+ bootstrap.getViewer = function () {
+ return viewer || { initWithThumbs: $.noop, hash: $.noop };
+ };
+
+ return bootstrap;
+ }
+
+ function hashTest( prefix, bootstrap, assert ) {
+ var hash = prefix + '/foo',
+ callCount = 0;
+
+ bootstrap.loadViewer = function () {
+ callCount++;
+ return $.Deferred().reject();
+ };
+
+ // Hijack loadViewer, which will return a promise that we'll have to
+ // wait for if we want to see these tests through
+ mw.mmv.testHelpers.asyncMethod( bootstrap, 'loadViewer' );
+
+ bootstrap.setupEventHandlers();
+
+ // invalid hash, should not trigger MMV load
+ window.location.hash = 'Foo';
+
+ // actual hash we want to test for, should trigger MMV load
+ // use setTimeout to add new hash change to end of the call stack,
+ // ensuring that event handlers for our previous change can execute
+ // without us interfering with another immediate change
+ setTimeout( function () {
+ window.location.hash = hash;
+ } );
+
+ return mw.mmv.testHelpers.waitForAsync().then( function () {
+ assert.ok( callCount === 1, 'Viewer should be loaded once' );
+ bootstrap.cleanupEventHandlers();
+ window.location.hash = '';
+ } );
+ }
+
+ QUnit.test( 'Promise does not hang on ResourceLoader errors', function ( assert ) {
+ var bootstrap,
+ errorMessage = 'loading failed',
+ done = assert.async();
+
+ this.sandbox.stub( mw.loader, 'using' )
+ .callsArgWith( 2, new Error( errorMessage, [ 'mmv' ] ) )
+ .withArgs( 'mediawiki.notification' ).returns( $.Deferred().reject() ); // needed for mw.notify
+
+ bootstrap = createBootstrap();
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+ this.sandbox.stub( bootstrap, 'cleanupOverlay' );
+
+ bootstrap.loadViewer( true ).fail( function ( message ) {
+ assert.ok( bootstrap.setupOverlay.called, 'Overlay was set up' );
+ assert.ok( bootstrap.cleanupOverlay.called, 'Overlay was cleaned up' );
+ assert.strictEqual( message, errorMessage, 'promise is rejected with the error message when loading fails' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'Clicks are not captured once the loading fails', function ( assert ) {
+ var event, returnValue,
+ bootstrap = new mw.mmv.MultimediaViewerBootstrap(),
+ clock = this.sandbox.useFakeTimers();
+
+ this.sandbox.stub( mw.loader, 'using' )
+ .callsArgWith( 2, new Error( 'loading failed', [ 'mmv' ] ) )
+ .withArgs( 'mediawiki.notification' ).returns( $.Deferred().reject() ); // needed for mw.notify
+ bootstrap.ensureEventHandlersAreSetUp = $.noop;
+
+ // trigger first click, which will cause MMV to be loaded (which we've
+ // set up to fail)
+ event = new $.Event( 'click', { button: 0, which: 1 } );
+ returnValue = bootstrap.click( {}, event, 'foo' );
+ clock.tick( 10 );
+ assert.ok( event.isDefaultPrevented(), 'First click is caught' );
+ assert.strictEqual( returnValue, false, 'First click is caught' );
+
+ // wait until MMW is loaded (or failed to load, in this case) before we
+ // trigger another click - which should then not be caught
+ event = new $.Event( 'click', { button: 0, which: 1 } );
+ returnValue = bootstrap.click( {}, event, 'foo' );
+ clock.tick( 10 );
+ assert.ok( !event.isDefaultPrevented(), 'Click after loading failure is not caught' );
+ assert.notStrictEqual( returnValue, false, 'Click after loading failure is not caught' );
+
+ clock.restore();
+ } );
+
+ /* FIXME: Tests suspended as they do not pass in QUnit 2.x+ – T192932
+ QUnit.test( 'Check viewer invoked when clicking on valid image links', function ( assert ) {
+ // TODO: Is <div class="gallery"><span class="image"><img/></span></div> valid ???
+ var div, link, link2, link3, link4, link5, bootstrap,
+ viewer = { initWithThumbs: $.noop, loadImageByTitle: this.sandbox.stub() },
+ clock = this.sandbox.useFakeTimers();
+
+ // Create gallery with valid link image
+ div = createGallery();
+ link = div.find( 'a.image' );
+
+ // Valid isolated thumbnail
+ link2 = $( '<a>' ).addClass( 'image' ).appendTo( '#qunit-fixture' );
+ $( '<img>' ).attr( 'src', 'thumb2.jpg' ).appendTo( link2 );
+
+ // Non-valid fragment
+ link3 = $( '<a>' ).addClass( 'noImage' ).appendTo( div );
+ $( '<img>' ).attr( 'src', 'thumb3.jpg' ).appendTo( link3 );
+
+ mw.config.set( 'wgTitle', 'Thumb4.jpg' );
+ mw.config.set( 'wgNamespaceNumber', 6 );
+ $( '<div>' ).addClass( 'fullMedia' ).appendTo( div );
+ $( '<img>' ).attr( 'src', 'thumb4.jpg' ).appendTo(
+ $( '<a>' )
+ .appendTo(
+ $( '<div>' )
+ .attr( 'id', 'file' )
+ .appendTo( '#qunit-fixture' )
+ )
+ );
+
+ // Create a new bootstrap object to trigger the DOM scan, etc.
+ bootstrap = createBootstrap( viewer );
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+
+ link4 = $( '.fullMedia .mw-mmv-view-expanded' );
+ assert.ok( link4.length, 'Link for viewing expanded file was set up.' );
+
+ link5 = $( '.fullMedia .mw-mmv-view-config' );
+ assert.ok( link5.length, 'Link for opening enable/disable configuration was set up.' );
+
+ // Click on valid link
+ link.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ // FIXME: Actual bootstrap.setupOverlay.callCount: 2
+ assert.equal( bootstrap.setupOverlay.callCount, 1, 'setupOverlay called (1st click)' );
+ assert.equal( viewer.loadImageByTitle.callCount, 1, 'loadImageByTitle called (1st click)' );
+ this.sandbox.reset();
+
+ // Click on valid link
+ link2.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 1, 'setupOverlay called (2nd click)' );
+ assert.equal( viewer.loadImageByTitle.callCount, 1, 'loadImageByTitle called (2nd click)' );
+ this.sandbox.reset();
+
+ // Click on valid link
+ link4.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 1, 'setupOverlay called (3rd click)' );
+ assert.equal( viewer.loadImageByTitle.callCount, 1, 'loadImageByTitle called (3rd click)' );
+ this.sandbox.reset();
+
+ // Click on valid link even when preference says not to
+ mw.config.set( 'wgMediaViewerOnClick', false );
+ link4.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ mw.config.set( 'wgMediaViewerOnClick', true );
+ assert.equal( bootstrap.setupOverlay.callCount, 1, 'setupOverlay called on-click with pref off' );
+ assert.equal( viewer.loadImageByTitle.callCount, 1, 'loadImageByTitle called on-click with pref off' );
+ this.sandbox.reset();
+
+ // @todo comment that above clicks should result in call, below clicks should not
+
+ // Click on non-valid link
+ link3.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 0, 'setupOverlay not called on non-valid link click' );
+ assert.equal( viewer.loadImageByTitle.callCount, 0, 'loadImageByTitle not called on non-valid link click' );
+ this.sandbox.reset();
+
+ // Click on valid links with preference off
+ mw.config.set( 'wgMediaViewerOnClick', false );
+ link.trigger( { type: 'click', which: 1 } );
+ link2.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 0, 'setupOverlay not called on non-valid link click with pref off' );
+ assert.equal( viewer.loadImageByTitle.callCount, 0, 'loadImageByTitle not called on non-valid link click with pref off' );
+
+ clock.restore();
+ } );
+ */
+
+ QUnit.test( 'Skip images with invalid extensions', function ( assert ) {
+ var div, link,
+ viewer = { initWithThumbs: $.noop, loadImageByTitle: this.sandbox.stub() },
+ clock = this.sandbox.useFakeTimers();
+
+ // Create gallery with image that has invalid name extension
+ div = createGallery( 'thumb.badext' );
+ link = div.find( 'a.image' );
+
+ // Create a new bootstrap object to trigger the DOM scan, etc.
+ createBootstrap( viewer );
+
+ // Click on valid link with wrong image extension
+ link.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+
+ assert.ok( !viewer.loadImageByTitle.called, 'Image should not be loaded' );
+
+ clock.restore();
+ } );
+
+ /* FIXME: Tests suspended as they do not pass in QUnit 2.x+ – T192932
+ QUnit.test( 'Accept only left clicks without modifier keys, skip the rest', function ( assert ) {
+ var $div, $link, bootstrap,
+ viewer = { initWithThumbs: $.noop, loadImageByTitle: this.sandbox.stub() },
+ clock = this.sandbox.useFakeTimers();
+
+ // Create gallery with image that has valid name extension
+ $div = createGallery();
+
+ // Create a new bootstrap object to trigger the DOM scan, etc.
+ bootstrap = createBootstrap( viewer );
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+
+ $link = $div.find( 'a.image' );
+
+ // Handle valid left click, it should try to load the image
+ $link.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+
+ // FIXME: Actual bootstrap.setupOverlay.callCount: 2
+ assert.equal( bootstrap.setupOverlay.callCount, 1, 'Left-click: Set up overlay' );
+ assert.equal( viewer.loadImageByTitle.callCount, 1, 'Left-click: Load image' );
+ this.sandbox.reset();
+
+ // Skip Ctrl-left-click, no image is loaded
+ $link.trigger( { type: 'click', which: 1, ctrlKey: true } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 0, 'Ctrl-left-click: No overlay' );
+ assert.equal( viewer.loadImageByTitle.callCount, 0, 'Ctrl-left-click: No image load' );
+ this.sandbox.reset();
+
+ // Skip invalid right click, no image is loaded
+ $link.trigger( { type: 'click', which: 2 } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 0, 'Right-click: No overlay' );
+ assert.equal( viewer.loadImageByTitle.callCount, 0, 'Right-click: Image was not loaded' );
+
+ clock.restore();
+ } );
+ */
+
+ QUnit.test( 'Ensure that the correct title is loaded when clicking', function ( assert ) {
+ var bootstrap,
+ viewer = { initWithThumbs: $.noop, loadImageByTitle: this.sandbox.stub() },
+ $div = createGallery( 'foo.jpg' ),
+ $link = $div.find( 'a.image' ),
+ clock = this.sandbox.useFakeTimers();
+
+ // Create a new bootstrap object to trigger the DOM scan, etc.
+ bootstrap = createBootstrap( viewer );
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+
+ $link.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ assert.ok( bootstrap.setupOverlay.called, 'Overlay was set up' );
+ assert.strictEqual( viewer.loadImageByTitle.firstCall.args[ 0 ].getPrefixedDb(), 'File:Foo.jpg', 'Titles are identical' );
+
+ clock.restore();
+ } );
+
+ /* FIXME: Tests suspended as they do not pass in QUnit 2.x+ – T192932
+ QUnit.test( 'Validate new LightboxImage object has sane constructor parameters', function ( assert ) {
+ var bootstrap,
+ $div,
+ $link,
+ viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ fname = 'valid',
+ imgSrc = '/' + fname + '.jpg/300px-' + fname + '.jpg',
+ imgRegex = new RegExp( imgSrc + '$' ),
+ clock = this.sandbox.useFakeTimers();
+
+ $div = createThumb( imgSrc, 'Blah blah', 'meow' );
+ $link = $div.find( 'a.image' );
+
+ // Create a new bootstrap object to trigger the DOM scan, etc.
+ bootstrap = createBootstrap( viewer );
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+ this.sandbox.stub( viewer, 'createNewImage' );
+ viewer.loadImage = $.noop;
+ viewer.createNewImage = function ( fileLink, filePageLink, fileTitle, index, thumb, caption, alt ) {
+ var html = thumb.outerHTML;
+
+ // FIXME: fileLink doesn't match imgRegex (null)
+ assert.ok( fileLink.match( imgRegex ), 'Thumbnail URL used in creating new image object' );
+ assert.strictEqual( filePageLink, '', 'File page link is sane when creating new image object' );
+ assert.strictEqual( fileTitle.title, fname, 'Filename is correct when passed into new image constructor' );
+ assert.strictEqual( index, 0, 'The only image we created in the gallery is set at index 0 in the images array' );
+ assert.ok( html.indexOf( ' src="' + imgSrc + '"' ) > 0, 'The image element passed in contains the src=... we want.' );
+ assert.ok( html.indexOf( ' alt="meow"' ) > 0, 'The image element passed in contains the alt=... we want.' );
+ assert.strictEqual( caption, 'Blah blah', 'The caption passed in is correct' );
+ assert.strictEqual( alt, 'meow', 'The alt text passed in is correct' );
+ };
+
+ $link.trigger( { type: 'click', which: 1 } );
+ clock.tick( 10 );
+ assert.equal( bootstrap.setupOverlay.callCount, 1, 'Overlay was set up' );
+
+ clock.reset();
+ } );
+ */
+
+ QUnit.test( 'Only load the viewer on a valid hash (modern browsers)', function ( assert ) {
+ var bootstrap;
+
+ window.location.hash = '';
+
+ bootstrap = createBootstrap();
+
+ return hashTest( '/media', bootstrap, assert );
+ } );
+
+ QUnit.test( 'Only load the viewer on a valid hash (old browsers)', function ( assert ) {
+ var bootstrap;
+
+ window.location.hash = '';
+
+ bootstrap = createBootstrap();
+ bootstrap.browserHistory = undefined;
+
+ return hashTest( '/media', bootstrap, assert );
+ } );
+
+ QUnit.test( 'Load the viewer on a legacy hash (modern browsers)', function ( assert ) {
+ var bootstrap;
+
+ window.location.hash = '';
+
+ bootstrap = createBootstrap();
+
+ return hashTest( 'mediaviewer', bootstrap, assert );
+ } );
+
+ QUnit.test( 'Load the viewer on a legacy hash (old browsers)', function ( assert ) {
+ var bootstrap;
+
+ window.location.hash = '';
+
+ bootstrap = createBootstrap();
+ bootstrap.browserHistory = undefined;
+
+ return hashTest( 'mediaviewer', bootstrap, assert );
+ } );
+
+ QUnit.test( 'Overlay is set up on hash change', function ( assert ) {
+ var bootstrap;
+
+ window.location.hash = '#/media/foo';
+
+ bootstrap = createBootstrap();
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+
+ bootstrap.hash();
+
+ assert.ok( bootstrap.setupOverlay.called, 'Overlay is set up' );
+ } );
+
+ QUnit.test( 'Overlay is not set up on an irrelevant hash change', function ( assert ) {
+ var bootstrap;
+
+ window.location.hash = '#foo';
+
+ bootstrap = createBootstrap();
+ this.sandbox.stub( bootstrap, 'setupOverlay' );
+ bootstrap.loadViewer();
+ bootstrap.setupOverlay.reset();
+
+ bootstrap.hash();
+
+ assert.ok( !bootstrap.setupOverlay.called, 'Overlay is not set up' );
+ } );
+
+ QUnit.test( 'internalHashChange', function ( assert ) {
+ var bootstrap = createBootstrap(),
+ hash = '#/media/foo',
+ callCount = 0,
+ clock = this.sandbox.useFakeTimers();
+
+ window.location.hash = '';
+
+ bootstrap.loadViewer = function () {
+ callCount++;
+ return $.Deferred().reject();
+ };
+
+ bootstrap.setupEventHandlers();
+
+ bootstrap.internalHashChange( { hash: hash } );
+ clock.tick( 10 );
+
+ assert.ok( callCount === 0, 'Viewer should not be loaded' );
+ assert.strictEqual( window.location.hash, hash, 'Window\'s hash has been updated correctly' );
+
+ bootstrap.cleanupEventHandlers();
+ window.location.hash = '';
+ clock.restore();
+ } );
+
+ QUnit.test( 'internalHashChange (legacy)', function ( assert ) {
+ var bootstrap = createBootstrap(),
+ hash = '#mediaviewer/foo',
+ callCount = 0,
+ clock = this.sandbox.useFakeTimers();
+
+ window.location.hash = '';
+
+ bootstrap.loadViewer = function () {
+ callCount++;
+ return $.Deferred().reject();
+ };
+
+ bootstrap.setupEventHandlers();
+
+ bootstrap.internalHashChange( { hash: hash } );
+ clock.tick( 10 );
+
+ assert.ok( callCount === 0, 'Viewer should not be loaded' );
+ assert.strictEqual( window.location.hash, hash, 'Window\'s hash has been updated correctly' );
+
+ bootstrap.cleanupEventHandlers();
+ window.location.hash = '';
+ clock.restore();
+ } );
+
+ QUnit.test( 'Restoring article scroll position', function ( assert ) {
+ var stubbedScrollTop,
+ bootstrap = createBootstrap(),
+ $window = $( window ),
+ done = assert.async();
+
+ this.sandbox.stub( $.fn, 'scrollTop', function ( scrollTop ) {
+ if ( scrollTop !== undefined ) {
+ stubbedScrollTop = scrollTop;
+ return this;
+ } else {
+ return stubbedScrollTop;
+ }
+ } );
+
+ $window.scrollTop( 50 );
+ bootstrap.setupOverlay();
+ // Calling this a second time because it can happen in history navigation context
+ bootstrap.setupOverlay();
+ // Clear scrollTop to check it is restored
+ $window.scrollTop( 0 );
+ bootstrap.cleanupOverlay();
+
+ // Scroll restoration is on a setTimeout
+ setTimeout( function () {
+ assert.strictEqual( $( window ).scrollTop(), 50, 'Scroll is correctly reset to original top position' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'Preload JS/CSS dependencies on thumb hover', function ( assert ) {
+ var $div, bootstrap,
+ clock = this.sandbox.useFakeTimers(),
+ viewer = { initWithThumbs: $.noop };
+
+ // Create gallery with image that has valid name extension
+ $div = createThumb();
+
+ // Create a new bootstrap object to trigger the DOM scan, etc.
+ bootstrap = createBootstrap( viewer );
+
+ this.sandbox.stub( mw.loader, 'load' );
+
+ $div.mouseenter();
+ clock.tick( bootstrap.hoverWaitDuration - 50 );
+ $div.mouseleave();
+
+ assert.ok( !mw.loader.load.called, 'Dependencies should not be preloaded if the thumb is not hovered long enough' );
+
+ $div.mouseenter();
+ clock.tick( bootstrap.hoverWaitDuration + 50 );
+ $div.mouseleave();
+
+ assert.ok( mw.loader.load.called, 'Dependencies should be preloaded if the thumb is hovered long enough' );
+
+ clock.restore();
+ } );
+
+ QUnit.test( 'isAllowedThumb', function ( assert ) {
+ var $container = $( '<div>' ),
+ $thumb = $( '<img>' ).appendTo( $container ),
+ bootstrap = createBootstrap();
+
+ assert.ok( bootstrap.isAllowedThumb( $thumb ), 'Normal image in a div is allowed.' );
+
+ $container.addClass( 'metadata' );
+ assert.strictEqual( bootstrap.isAllowedThumb( $thumb ), false, 'Image in a metadata container is disallowed.' );
+
+ $container.prop( 'class', '' );
+ $container.addClass( 'noviewer' );
+ assert.strictEqual( bootstrap.isAllowedThumb( $thumb ), false, 'Image in a noviewer container is disallowed.' );
+
+ $container.prop( 'class', '' );
+ $container.addClass( 'noarticletext' );
+ assert.strictEqual( bootstrap.isAllowedThumb( $thumb ), false, 'Image in an empty article is disallowed.' );
+
+ $container.prop( 'class', '' );
+ $thumb.addClass( 'noviewer' );
+ assert.strictEqual( bootstrap.isAllowedThumb( $thumb ), false, 'Image with a noviewer class is disallowed.' );
+ } );
+
+ QUnit.test( 'findCaption', function ( assert ) {
+ var gallery = createGallery( 'foo.jpg', 'Baz' ),
+ thumb = createThumb( 'foo.jpg', 'Quuuuux' ),
+ link = createNormal( 'foo.jpg', 'Foobar' ),
+ multiple = createMultipleImage( [ [ 'foo.jpg', 'Image #1' ], [ 'bar.jpg', 'Image #2' ],
+ [ 'foobar.jpg', 'Image #3' ] ] ),
+ bootstrap = createBootstrap();
+
+ assert.strictEqual( bootstrap.findCaption( gallery.find( '.thumb' ), gallery.find( 'a.image' ) ), 'Baz', 'A gallery caption is found.' );
+ assert.strictEqual( bootstrap.findCaption( thumb, thumb.find( 'a.image' ) ), 'Quuuuux', 'A thumbnail caption is found.' );
+ assert.strictEqual( bootstrap.findCaption( $(), link ), 'Foobar', 'The caption is found even if the image is not a thumbnail.' );
+ assert.strictEqual( bootstrap.findCaption( multiple, multiple.find( 'img[src="bar.jpg"]' ).closest( 'a' ) ), 'Image #2', 'The caption is found in {{Multiple image}}.' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboximage.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboximage.test.js
new file mode 100644
index 00000000..ce824707
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboximage.test.js
@@ -0,0 +1,10 @@
+( function ( mw ) {
+ QUnit.module( 'mmv.lightboximage', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation', function ( assert ) {
+ var lightboxImage = new mw.mmv.LightboxImage( 'foo.png' );
+
+ assert.ok( lightboxImage, 'Object created !' );
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboxinterface.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboxinterface.test.js
new file mode 100644
index 00000000..1f85eeca
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.lightboxinterface.test.js
@@ -0,0 +1,306 @@
+( function ( mw, $ ) {
+ var oldScrollTo;
+
+ function stubScrollTo() {
+ oldScrollTo = $.scrollTo;
+ $.scrollTo = function () { return { scrollTop: $.noop, on: $.noop, off: $.noop }; };
+ }
+
+ function restoreScrollTo() {
+ $.scrollTo = oldScrollTo;
+ }
+
+ QUnit.module( 'mmv.lightboxInterface', QUnit.newMwEnvironment( {
+ setup: function () {
+ // animation would keep running, conflict with other tests
+ this.sandbox.stub( $.fn, 'animate' ).returnsThis();
+ }
+ } ) );
+
+ QUnit.test( 'Sanity test, object creation and ui construction', function ( assert ) {
+ var lightbox = new mw.mmv.LightboxInterface();
+
+ stubScrollTo();
+
+ function checkIfUIAreasAttachedToDocument( inDocument ) {
+ var msg = ( inDocument === 1 ? ' ' : ' not ' ) + 'attached.';
+ assert.strictEqual( $( '.mw-mmv-wrapper' ).length, inDocument, 'Wrapper area' + msg );
+ assert.strictEqual( $( '.mw-mmv-main' ).length, inDocument, 'Main area' + msg );
+ assert.strictEqual( $( '.mw-mmv-title' ).length, inDocument, 'Title area' + msg );
+ assert.strictEqual( $( '.mw-mmv-credit' ).length, inDocument, 'Author/source area' + msg );
+ assert.strictEqual( $( '.mw-mmv-image-desc' ).length, inDocument, 'Description area' + msg );
+ assert.strictEqual( $( '.mw-mmv-image-links' ).length, inDocument, 'Links area' + msg );
+ }
+
+ // UI areas not attached to the document yet.
+ checkIfUIAreasAttachedToDocument( 0 );
+
+ // Attach lightbox to testing fixture to avoid interference with other tests.
+ lightbox.attach( '#qunit-fixture' );
+
+ // UI areas should now be attached to the document.
+ checkIfUIAreasAttachedToDocument( 1 );
+
+ // Check that the close button on the lightbox still follow the spec (being visible right away)
+ assert.strictEqual( $( '#qunit-fixture .mw-mmv-close' ).length, 1, 'There should be a close button' );
+ assert.ok( $( '#qunit-fixture .mw-mmv-close' ).is( ':visible' ), 'The close button should be visible' );
+
+ // Unattach lightbox from document
+ lightbox.unattach();
+
+ // UI areas not attached to the document anymore.
+ checkIfUIAreasAttachedToDocument( 0 );
+
+ restoreScrollTo();
+ } );
+
+ QUnit.test( 'Handler registration and clearance work OK', function ( assert ) {
+ var lightbox = new mw.mmv.LightboxInterface(),
+ handlerCalls = 0,
+ clock = this.sandbox.useFakeTimers();
+
+ function handleEvent() {
+ handlerCalls++;
+ }
+
+ lightbox.handleEvent( 'test', handleEvent );
+ $( document ).trigger( 'test' );
+ clock.tick( 10 );
+ assert.strictEqual( handlerCalls, 1, 'The handler was called when we triggered the event.' );
+
+ lightbox.clearEvents();
+
+ $( document ).trigger( 'test' );
+ clock.tick( 10 );
+ assert.strictEqual( handlerCalls, 1, 'The handler was not called after calling lightbox.clearEvents().' );
+
+ clock.restore();
+ } );
+
+ QUnit.test( 'Fullscreen mode', function ( assert ) {
+ var lightbox = new mw.mmv.LightboxInterface(),
+ oldFnEnterFullscreen = $.fn.enterFullscreen,
+ oldFnExitFullscreen = $.fn.exitFullscreen,
+ oldSupportFullscreen = $.support.fullscreen;
+
+ // Since we don't want these tests to really open fullscreen
+ // which is subject to user security confirmation,
+ // we use a mock that pretends regular jquery.fullscreen behavior happened
+ $.fn.enterFullscreen = mw.mmv.testHelpers.enterFullscreenMock;
+ $.fn.exitFullscreen = mw.mmv.testHelpers.exitFullscreenMock;
+
+ stubScrollTo();
+
+ lightbox.buttons.fadeOut = $.noop;
+
+ // Attach lightbox to testing fixture to avoid interference with other tests.
+ lightbox.attach( '#qunit-fixture' );
+
+ $.support.fullscreen = false;
+ lightbox.setupCanvasButtons();
+
+ assert.strictEqual( lightbox.$fullscreenButton.css( 'display' ), 'none',
+ 'Fullscreen button is hidden when fullscreen mode is unavailable' );
+
+ $.support.fullscreen = true;
+ lightbox.setupCanvasButtons();
+
+ assert.strictEqual( lightbox.$fullscreenButton.css( 'display' ), '',
+ 'Fullscreen button is visible when fullscreen mode is available' );
+
+ // Entering fullscreen
+ lightbox.$fullscreenButton.click();
+
+ assert.strictEqual( lightbox.$main.hasClass( 'jq-fullscreened' ), true,
+ 'Fullscreened area has the fullscreen class' );
+ assert.strictEqual( lightbox.isFullscreen, true, 'Lightbox knows it\'s in fullscreen mode' );
+
+ // Exiting fullscreen
+ lightbox.$fullscreenButton.click();
+
+ assert.strictEqual( lightbox.$main.hasClass( 'jq-fullscreened' ), false,
+ 'Fullscreened area doesn\'t have the fullscreen class anymore' );
+ assert.strictEqual( lightbox.isFullscreen, false, 'Lightbox knows it\'s not in fullscreen mode' );
+
+ // Entering fullscreen
+ lightbox.$fullscreenButton.click();
+
+ // Hard-exiting fullscreen
+ lightbox.$closeButton.click();
+
+ // Re-attach after hard-exit
+ lightbox.attach( '#qunit-fixture' );
+
+ assert.strictEqual( lightbox.$main.hasClass( 'jq-fullscreened' ), false,
+ 'Fullscreened area doesn\'t have the fullscreen class anymore' );
+ assert.strictEqual( lightbox.isFullscreen, false, 'Lightbox knows it\'s not in fullscreen mode' );
+
+ // Unattach lightbox from document
+ lightbox.unattach();
+
+ $.fn.enterFullscreen = oldFnEnterFullscreen;
+ $.fn.exitFullscreen = oldFnExitFullscreen;
+ $.support.fullscreen = oldSupportFullscreen;
+ restoreScrollTo();
+ } );
+
+ QUnit.test( 'Fullscreen mode', function ( assert ) {
+ var buttonOffset, panelBottom,
+ oldRevealButtonsAndFadeIfNeeded,
+ lightbox = new mw.mmv.LightboxInterface(),
+ viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ oldFnEnterFullscreen = $.fn.enterFullscreen,
+ oldFnExitFullscreen = $.fn.exitFullscreen;
+
+ stubScrollTo();
+
+ // ugly hack to avoid preloading which would require lightbox list being set up
+ viewer.preloadDistance = -1;
+
+ // Since we don't want these tests to really open fullscreen
+ // which is subject to user security confirmation,
+ // we use a mock that pretends regular jquery.fullscreen behavior happened
+ $.fn.enterFullscreen = mw.mmv.testHelpers.enterFullscreenMock;
+ $.fn.exitFullscreen = mw.mmv.testHelpers.exitFullscreenMock;
+
+ // Attach lightbox to testing fixture to avoid interference with other tests.
+ lightbox.attach( '#qunit-fixture' );
+ viewer.ui = lightbox;
+ viewer.ui = lightbox;
+
+ assert.ok( !lightbox.isFullscreen, 'Lightbox knows that it\'s not in fullscreen mode' );
+ assert.ok( lightbox.panel.$imageMetadata.is( ':visible' ), 'Image metadata is visible' );
+
+ lightbox.buttons.fadeOut = function () {
+ assert.ok( true, 'Opening fullscreen triggers a fadeout' );
+ };
+
+ // Pretend that the mouse cursor is on top of the button
+ buttonOffset = lightbox.buttons.$fullscreen.offset();
+ lightbox.mousePosition = { x: buttonOffset.left, y: buttonOffset.top };
+
+ // Enter fullscreen
+ lightbox.buttons.$fullscreen.click();
+
+ lightbox.buttons.fadeOut = $.noop;
+ assert.ok( lightbox.isFullscreen, 'Lightbox knows that it\'s in fullscreen mode' );
+
+ oldRevealButtonsAndFadeIfNeeded = lightbox.buttons.revealAndFade;
+
+ lightbox.buttons.revealAndFade = function ( position ) {
+ assert.ok( true, 'Moving the cursor triggers a reveal + fade' );
+
+ oldRevealButtonsAndFadeIfNeeded.call( this, position );
+ };
+
+ // Pretend that the mouse cursor moved to the top-left corner
+ lightbox.mousemove( { pageX: 0, pageY: 0 } );
+
+ lightbox.buttons.revealAndFadeIfNeeded = $.noop;
+
+ panelBottom = $( '.mw-mmv-post-image' ).position().top + $( '.mw-mmv-post-image' ).height();
+
+ assert.ok( panelBottom === $( window ).height(), 'Image metadata does not extend beyond the viewport' );
+
+ lightbox.buttons.revealAndFade = function ( position ) {
+ assert.ok( true, 'Closing fullscreen triggers a reveal + fade' );
+
+ oldRevealButtonsAndFadeIfNeeded.call( this, position );
+ };
+
+ // Exiting fullscreen
+ lightbox.buttons.$fullscreen.click();
+
+ panelBottom = $( '.mw-mmv-post-image' ).position().top + $( '.mw-mmv-post-image' ).height();
+
+ assert.ok( panelBottom > $( window ).height(), 'Image metadata extends beyond the viewport' );
+ assert.ok( !lightbox.isFullscreen, 'Lightbox knows that it\'s not in fullscreen mode' );
+
+ // Unattach lightbox from document
+ lightbox.unattach();
+
+ $.fn.enterFullscreen = oldFnEnterFullscreen;
+ $.fn.exitFullscreen = oldFnExitFullscreen;
+ restoreScrollTo();
+ } );
+
+ QUnit.test( 'isAnyActiveButtonHovered', function ( assert ) {
+ var lightbox = new mw.mmv.LightboxInterface();
+
+ stubScrollTo();
+
+ // Attach lightbox to testing fixture to avoid interference with other tests.
+ lightbox.attach( '#qunit-fixture' );
+
+ $.each( lightbox.buttons.$buttons, function ( idx, e ) {
+ var $e = $( e ),
+ offset = $e.show().offset(),
+ width = $e.width(),
+ height = $e.height(),
+ disabled = $e.hasClass( 'disabled' );
+
+ assert.strictEqual( lightbox.buttons.isAnyActiveButtonHovered( offset.left, offset.top ),
+ !disabled,
+ 'Hover detection works for top-left corner of element' );
+ assert.strictEqual( lightbox.buttons.isAnyActiveButtonHovered( offset.left + width, offset.top ),
+ !disabled,
+ 'Hover detection works for top-right corner of element' );
+ assert.strictEqual( lightbox.buttons.isAnyActiveButtonHovered( offset.left, offset.top + height ),
+ !disabled,
+ 'Hover detection works for bottom-left corner of element' );
+ assert.strictEqual( lightbox.buttons.isAnyActiveButtonHovered( offset.left + width, offset.top + height ),
+ !disabled,
+ 'Hover detection works for bottom-right corner of element' );
+ assert.strictEqual(
+ lightbox.buttons.isAnyActiveButtonHovered(
+ offset.left + ( width / 2 ), offset.top + ( height / 2 )
+ ),
+ !disabled,
+ 'Hover detection works for center of element'
+ );
+ } );
+
+ // Unattach lightbox from document
+ lightbox.unattach();
+ restoreScrollTo();
+ } );
+
+ QUnit.test( 'Keyboard prev/next', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ lightbox = new mw.mmv.LightboxInterface();
+
+ viewer.setupEventHandlers();
+
+ // Since we define both, the test works regardless of RTL settings
+ lightbox.on( 'next', function () {
+ assert.ok( true, 'Next image was open' );
+ } );
+
+ lightbox.on( 'prev', function () {
+ assert.ok( true, 'Prev image was open' );
+ } );
+
+ // 37 is left arrow, 39 is right arrow
+ lightbox.keydown( $.Event( 'keydown', { which: 37 } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 39 } ) );
+
+ lightbox.off( 'next' ).on( 'next', function () {
+ assert.ok( false, 'Next image should not have been open' );
+ } );
+
+ lightbox.off( 'prev' ).on( 'prev', function () {
+ assert.ok( false, 'Prev image should not have been open' );
+ } );
+
+ lightbox.keydown( $.Event( 'keydown', { which: 37, altKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 39, altKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 37, ctrlKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 39, ctrlKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 37, shiftKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 39, shiftKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 37, metaKey: true } ) );
+ lightbox.keydown( $.Event( 'keydown', { which: 39, metaKey: true } ) );
+
+ viewer.cleanupEventHandlers();
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.test.js
new file mode 100644
index 00000000..95a01c36
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.test.js
@@ -0,0 +1,706 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'eachPrealoadableLightboxIndex()', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ expectedIndices,
+ i;
+
+ viewer.preloadDistance = 3;
+ viewer.thumbs = [];
+
+ // 0..10
+ for ( i = 0; i < 11; i++ ) {
+ viewer.thumbs.push( { image: false } );
+ }
+
+ viewer.currentIndex = 2;
+ i = 0;
+ expectedIndices = [ 2, 3, 1, 4, 0, 5 ];
+ viewer.eachPrealoadableLightboxIndex( function ( index ) {
+ assert.strictEqual( index, expectedIndices[ i++ ], 'preload on left edge' );
+ } );
+
+ viewer.currentIndex = 9;
+ i = 0;
+ expectedIndices = [ 9, 10, 8, 7, 6 ];
+ viewer.eachPrealoadableLightboxIndex( function ( index ) {
+ assert.strictEqual( index, expectedIndices[ i++ ], 'preload on right edge' );
+ } );
+ } );
+
+ QUnit.test( 'Hash handling', function ( assert ) {
+ var oldUnattach,
+ viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ ui = new mw.mmv.LightboxInterface(),
+ imageSrc = 'Foo bar.jpg',
+ image = { filePageTitle: new mw.Title( 'File:' + imageSrc ) };
+
+ // animation would keep running, conflict with other tests
+ this.sandbox.stub( $.fn, 'animate' ).returnsThis();
+
+ window.location.hash = '';
+
+ viewer.setupEventHandlers();
+ oldUnattach = ui.unattach;
+
+ ui.unattach = function () {
+ assert.ok( true, 'Lightbox was unattached' );
+ oldUnattach.call( this );
+ };
+
+ viewer.ui = ui;
+ viewer.close();
+
+ assert.ok( !viewer.isOpen, 'Viewer is closed' );
+
+ viewer.isOpen = true;
+
+ // Verify that passing an invalid mmv hash when the mmv is open triggers unattach()
+ window.location.hash = 'Foo';
+ viewer.hash();
+
+ // Verify that mmv doesn't reset a foreign hash
+ assert.strictEqual( window.location.hash, '#Foo', 'Foreign hash remains intact' );
+ assert.ok( !viewer.isOpen, 'Viewer is closed' );
+
+ ui.unattach = function () {
+ assert.ok( false, 'Lightbox was not unattached' );
+ oldUnattach.call( this );
+ };
+
+ // Verify that passing an invalid mmv hash when the mmv is closed doesn't trigger unattach()
+ window.location.hash = 'Bar';
+ viewer.hash();
+
+ // Verify that mmv doesn't reset a foreign hash
+ assert.strictEqual( window.location.hash, '#Bar', 'Foreign hash remains intact' );
+
+ viewer.ui = { images: [ image ], disconnect: $.noop };
+
+ $( '#qunit-fixture' ).append( '<a class="image"><img src="' + imageSrc + '"></a>' );
+
+ viewer.loadImageByTitle = function ( title ) {
+ assert.strictEqual( title.getPrefixedText(), 'File:' + imageSrc, 'The title matches' );
+ };
+
+ // Open a valid mmv hash link and check that the right image is requested.
+ // imageSrc contains a space without any encoding on purpose
+ window.location.hash = '/media/File:' + imageSrc;
+ viewer.hash();
+
+ // Reset the hash, because for some browsers switching from the non-URI-encoded to
+ // the non-URI-encoded version of the same text with a space will not trigger a hash change
+ window.location.hash = '';
+ viewer.hash();
+
+ // Try again with an URI-encoded imageSrc containing a space
+ window.location.hash = '/media/File:' + encodeURIComponent( imageSrc );
+ viewer.hash();
+
+ // Reset the hash
+ window.location.hash = '';
+ viewer.hash();
+
+ // Try again with a legacy hash
+ window.location.hash = 'mediaviewer/File:' + imageSrc;
+ viewer.hash();
+
+ viewer.cleanupEventHandlers();
+
+ window.location.hash = '';
+ } );
+
+ QUnit.test( 'Progress', function ( assert ) {
+ var imageDeferred = $.Deferred(),
+ viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ fakeImage = {
+ filePageTitle: new mw.Title( 'File:Stuff.jpg' ),
+ extraStatsDeferred: $.Deferred().reject()
+ },
+ // custom clock ensures progress handlers execute in correct sequence
+ clock = this.sandbox.useFakeTimers();
+
+ viewer.thumbs = [];
+ viewer.displayPlaceholderThumbnail = $.noop;
+ viewer.setImage = $.noop;
+ viewer.scroll = $.noop;
+ viewer.preloadFullscreenThumbnail = $.noop;
+ viewer.fetchSizeIndependentLightboxInfo = function () { return $.Deferred().resolve( {} ); };
+ viewer.ui = {
+ setFileReuseData: $.noop,
+ setupForLoad: $.noop,
+ canvas: { set: $.noop,
+ unblurWithAnimation: $.noop,
+ unblur: $.noop,
+ getCurrentImageWidths: function () { return { real: 0 }; },
+ getDimensions: function () { return {}; }
+ },
+ panel: {
+ setImageInfo: $.noop,
+ scroller: {
+ animateMetadataOnce: $.noop
+ },
+ progressBar: {
+ animateTo: this.sandbox.stub(),
+ jumpTo: this.sandbox.stub()
+ }
+ },
+ open: $.noop };
+
+ viewer.imageProvider.get = function () { return imageDeferred.promise(); };
+ viewer.imageInfoProvider.get = function () { return $.Deferred().resolve( {} ); };
+ viewer.thumbnailInfoProvider.get = function () { return $.Deferred().resolve( {} ); };
+
+ // loadImage will call setupProgressBar, which will attach done, fail &
+ // progress handlers
+ viewer.loadImage( fakeImage, new Image() );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.jumpTo.lastCall.calledWith( 0 ),
+ 'Percentage correctly reset by loadImage' );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.firstCall.calledWith( 5 ),
+ 'Percentage correctly animated to 5 by loadImage' );
+
+ imageDeferred.notify( 'response', 45 );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.secondCall.calledWith( 45 ),
+ 'Percentage correctly funneled to panel UI' );
+
+ imageDeferred.resolve( {}, {} );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.thirdCall.calledWith( 100 ),
+ 'Percentage correctly funneled to panel UI' );
+
+ clock.restore();
+
+ viewer.close();
+ } );
+
+ QUnit.test( 'Progress when switching images', function ( assert ) {
+ var firstImageDeferred = $.Deferred(),
+ secondImageDeferred = $.Deferred(),
+ firstImage = {
+ index: 1,
+ filePageTitle: new mw.Title( 'File:First.jpg' ),
+ extraStatsDeferred: $.Deferred().reject()
+ },
+ secondImage = {
+ index: 2,
+ filePageTitle: new mw.Title( 'File:Second.jpg' ),
+ extraStatsDeferred: $.Deferred().reject()
+ },
+ viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ // custom clock ensures progress handlers execute in correct sequence
+ clock = this.sandbox.useFakeTimers();
+
+ // animation would keep running, conflict with other tests
+ this.sandbox.stub( $.fn, 'animate' ).returnsThis();
+
+ viewer.thumbs = [];
+ viewer.displayPlaceholderThumbnail = $.noop;
+ viewer.setImage = $.noop;
+ viewer.scroll = $.noop;
+ viewer.preloadFullscreenThumbnail = $.noop;
+ viewer.preloadImagesMetadata = $.noop;
+ viewer.preloadThumbnails = $.noop;
+ viewer.fetchSizeIndependentLightboxInfo = function () { return $.Deferred().resolve( {} ); };
+ viewer.ui = {
+ setFileReuseData: $.noop,
+ setupForLoad: $.noop,
+ canvas: { set: $.noop,
+ unblurWithAnimation: $.noop,
+ unblur: $.noop,
+ getCurrentImageWidths: function () { return { real: 0 }; },
+ getDimensions: function () { return {}; }
+ },
+ panel: {
+ setImageInfo: $.noop,
+ scroller: {
+ animateMetadataOnce: $.noop
+ },
+ progressBar: {
+ hide: this.sandbox.stub(),
+ animateTo: this.sandbox.stub(),
+ jumpTo: this.sandbox.stub()
+ }
+ },
+ open: $.noop,
+ empty: $.noop };
+
+ viewer.imageInfoProvider.get = function () { return $.Deferred().resolve( {} ); };
+ viewer.thumbnailInfoProvider.get = function () { return $.Deferred().resolve( {} ); };
+
+ // load some image
+ viewer.imageProvider.get = this.sandbox.stub().returns( firstImageDeferred );
+ viewer.loadImage( firstImage, new Image() );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.jumpTo.getCall( 0 ).calledWith( 0 ),
+ 'Percentage correctly reset for new first image' );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.getCall( 0 ).calledWith( 5 ),
+ 'Percentage correctly animated to 5 for first new image' );
+
+ // progress on active image
+ firstImageDeferred.notify( 'response', 20 );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.getCall( 1 ).calledWith( 20 ),
+ 'Percentage correctly animated when active image is loading' );
+
+ // change to another image
+ viewer.imageProvider.get = this.sandbox.stub().returns( secondImageDeferred );
+ viewer.loadImage( secondImage, new Image() );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.jumpTo.getCall( 1 ).calledWith( 0 ),
+ 'Percentage correctly reset for second new image' );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.getCall( 2 ).calledWith( 5 ),
+ 'Percentage correctly animated to 5 for second new image' );
+
+ // progress on active image
+ secondImageDeferred.notify( 'response', 30 );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.getCall( 3 ).calledWith( 30 ),
+ 'Percentage correctly animated when active image is loading' );
+
+ // progress on inactive image
+ firstImageDeferred.notify( 'response', 40 );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.callCount === 4,
+ 'Percentage not animated when inactive image is loading' );
+
+ // progress on active image
+ secondImageDeferred.notify( 'response', 50 );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.animateTo.getCall( 4 ).calledWith( 50 ),
+ 'Percentage correctly ignored inactive image & only animated when active image is loading' );
+
+ // change back to first image
+ viewer.imageProvider.get = this.sandbox.stub().returns( firstImageDeferred );
+ viewer.loadImage( firstImage, new Image() );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.jumpTo.getCall( 2 ).calledWith( 40 ),
+ 'Percentage jumps to right value when changing images' );
+
+ secondImageDeferred.resolve( {}, {} );
+ clock.tick( 10 );
+ assert.ok( !viewer.ui.panel.progressBar.hide.called,
+ 'Progress bar not hidden when something finishes in the background' );
+
+ // change back to second image, which has finished loading
+ viewer.imageProvider.get = this.sandbox.stub().returns( secondImageDeferred );
+ viewer.loadImage( secondImage, new Image() );
+ clock.tick( 10 );
+ assert.ok( viewer.ui.panel.progressBar.hide.called,
+ 'Progress bar hidden when switching to finished image' );
+
+ clock.restore();
+
+ viewer.close();
+ } );
+
+ QUnit.test( 'resetBlurredThumbnailStates', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer();
+
+ // animation would keep running, conflict with other tests
+ this.sandbox.stub( $.fn, 'animate' ).returnsThis();
+
+ assert.ok( !viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+ assert.ok( !viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+
+ viewer.realThumbnailShown = true;
+ viewer.blurredThumbnailShown = true;
+
+ viewer.resetBlurredThumbnailStates();
+
+ assert.ok( !viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+ assert.ok( !viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'Placeholder first, then real thumbnail', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer();
+
+ viewer.setImage = $.noop;
+ viewer.ui = { canvas: {
+ unblurWithAnimation: $.noop,
+ unblur: $.noop,
+ maybeDisplayPlaceholder: function () { return true; }
+ } };
+ viewer.imageInfoProvider.get = this.sandbox.stub();
+
+ viewer.displayPlaceholderThumbnail( { originalWidth: 100, originalHeight: 100 }, undefined, undefined );
+
+ assert.ok( viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+ assert.ok( !viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+
+ viewer.displayRealThumbnail( { url: undefined } );
+
+ assert.ok( viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+ assert.ok( viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'Placeholder first, then real thumbnail - missing size', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer();
+
+ viewer.currentIndex = 1;
+ viewer.setImage = $.noop;
+ viewer.ui = { canvas: {
+ unblurWithAnimation: $.noop,
+ unblur: $.noop,
+ maybeDisplayPlaceholder: function () { return true; }
+ } };
+ viewer.imageInfoProvider.get = this.sandbox.stub().returns( $.Deferred().resolve( { width: 100, height: 100 } ) );
+
+ viewer.displayPlaceholderThumbnail( { index: 1 }, undefined, undefined );
+
+ assert.ok( viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+ assert.ok( !viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+
+ viewer.displayRealThumbnail( { url: undefined } );
+
+ assert.ok( viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+ assert.ok( viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'Real thumbnail first, then placeholder', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer();
+
+ viewer.setImage = $.noop;
+ viewer.ui = {
+ showImage: $.noop,
+ canvas: {
+ unblurWithAnimation: $.noop,
+ unblur: $.noop
+ } };
+
+ viewer.displayRealThumbnail( { url: undefined } );
+
+ assert.ok( viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+ assert.ok( !viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+
+ viewer.displayPlaceholderThumbnail( {}, undefined, undefined );
+
+ assert.ok( viewer.realThumbnailShown, 'Real thumbnail state is correct' );
+ assert.ok( !viewer.blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'displayRealThumbnail', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer();
+
+ viewer.setImage = $.noop;
+ viewer.ui = { canvas: {
+ unblurWithAnimation: this.sandbox.stub(),
+ unblur: $.noop
+ } };
+ viewer.blurredThumbnailShown = true;
+
+ // Should not result in an unblurWithAnimation animation (image cache from cache)
+ viewer.displayRealThumbnail( { url: undefined }, undefined, undefined, 5 );
+ assert.ok( !viewer.ui.canvas.unblurWithAnimation.called, 'There should not be an unblurWithAnimation animation' );
+
+ // Should result in an unblurWithAnimation (image didn't come from cache)
+ viewer.displayRealThumbnail( { url: undefined }, undefined, undefined, 1000 );
+ assert.ok( viewer.ui.canvas.unblurWithAnimation.called, 'There should be an unblurWithAnimation animation' );
+ } );
+
+ QUnit.test( 'New image loaded while another one is loading', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ firstImageDeferred = $.Deferred(),
+ secondImageDeferred = $.Deferred(),
+ firstLigthboxInfoDeferred = $.Deferred(),
+ secondLigthboxInfoDeferred = $.Deferred(),
+ firstImage = {
+ filePageTitle: new mw.Title( 'File:Foo.jpg' ),
+ index: 0,
+ extraStatsDeferred: $.Deferred().reject()
+ },
+ secondImage = {
+ filePageTitle: new mw.Title( 'File:Bar.jpg' ),
+ index: 1,
+ extraStatsDeferred: $.Deferred().reject()
+ },
+ // custom clock ensures progress handlers execute in correct sequence
+ clock = this.sandbox.useFakeTimers();
+
+ viewer.preloadFullscreenThumbnail = $.noop;
+ viewer.fetchSizeIndependentLightboxInfo = this.sandbox.stub();
+ viewer.ui = {
+ setFileReuseData: $.noop,
+ setupForLoad: $.noop,
+ canvas: {
+ set: $.noop,
+ getCurrentImageWidths: function () { return { real: 0 }; },
+ getDimensions: function () { return {}; }
+ },
+ panel: {
+ setImageInfo: this.sandbox.stub(),
+ scroller: {
+ animateMetadataOnce: $.noop
+ },
+ progressBar: {
+ animateTo: this.sandbox.stub(),
+ jumpTo: this.sandbox.stub()
+ },
+ empty: $.noop
+ },
+ open: $.noop,
+ empty: $.noop };
+ viewer.displayRealThumbnail = this.sandbox.stub();
+ viewer.eachPrealoadableLightboxIndex = $.noop;
+ viewer.animateMetadataDivOnce = this.sandbox.stub().returns( $.Deferred().reject() );
+ viewer.imageProvider.get = this.sandbox.stub();
+ viewer.imageInfoProvider.get = function () { return $.Deferred().reject(); };
+ viewer.thumbnailInfoProvider.get = function () { return $.Deferred().resolve( {} ); };
+
+ viewer.imageProvider.get.returns( firstImageDeferred.promise() );
+ viewer.fetchSizeIndependentLightboxInfo.returns( firstLigthboxInfoDeferred.promise() );
+ viewer.loadImage( firstImage, new Image() );
+ clock.tick( 10 );
+ assert.ok( !viewer.animateMetadataDivOnce.called, 'Metadata of the first image should not be animated' );
+ assert.ok( !viewer.ui.panel.setImageInfo.called, 'Metadata of the first image should not be shown' );
+
+ viewer.imageProvider.get.returns( secondImageDeferred.promise() );
+ viewer.fetchSizeIndependentLightboxInfo.returns( secondLigthboxInfoDeferred.promise() );
+ viewer.loadImage( secondImage, new Image() );
+ clock.tick( 10 );
+
+ viewer.ui.panel.progressBar.animateTo.reset();
+ firstImageDeferred.notify( undefined, 45 );
+ clock.tick( 10 );
+ assert.ok( !viewer.ui.panel.progressBar.animateTo.reset.called, 'Progress of the first image should not be shown' );
+
+ firstImageDeferred.resolve( {}, {} );
+ firstLigthboxInfoDeferred.resolve( {} );
+ clock.tick( 10 );
+ assert.ok( !viewer.displayRealThumbnail.called, 'The first image being done loading should have no effect' );
+
+ viewer.displayRealThumbnail = this.sandbox.spy( function () { viewer.close(); } );
+ secondImageDeferred.resolve( {}, {} );
+ secondLigthboxInfoDeferred.resolve( {} );
+ clock.tick( 10 );
+ assert.ok( viewer.displayRealThumbnail.called, 'The second image being done loading should result in the image being shown' );
+
+ clock.restore();
+ } );
+
+ QUnit.test( 'Events are not trapped after the viewer is closed', function ( assert ) {
+ var i, j, k, eventParameters,
+ viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ $document = $( document ),
+ $qf = $( '#qunit-fixture' ),
+ eventTypes = [ 'keydown', 'keyup', 'keypress', 'click', 'mousedown', 'mouseup' ],
+ modifiers = [ undefined, 'altKey', 'ctrlKey', 'shiftKey', 'metaKey' ],
+ // Events are async, we need to wait for the last event to be caught before ending the test
+ done = assert.async(),
+ oldScrollTo = $.scrollTo;
+
+ assert.expect( 0 );
+
+ // animation would keep running, conflict with other tests
+ this.sandbox.stub( $.fn, 'animate' ).returnsThis();
+
+ $.scrollTo = function () { return { scrollTop: $.noop, on: $.noop, off: $.noop }; };
+
+ viewer.setupEventHandlers();
+
+ viewer.imageProvider.get = function () { return $.Deferred().reject(); };
+ viewer.imageInfoProvider.get = function () { return $.Deferred().reject(); };
+ viewer.thumbnailInfoProvider.get = function () { return $.Deferred().reject(); };
+ viewer.fileRepoInfoProvider.get = function () { return $.Deferred().reject(); };
+
+ viewer.preloadFullscreenThumbnail = $.noop;
+ viewer.initWithThumbs( [] );
+
+ viewer.loadImage(
+ {
+ filePageTitle: new mw.Title( 'File:Stuff.jpg' ),
+ thumbnail: new mw.mmv.model.Thumbnail( 'foo', 10, 10 ),
+ extraStatsDeferred: $.Deferred().reject()
+ },
+ new Image()
+ );
+
+ viewer.ui.$closeButton.click();
+
+ function eventHandler( e ) {
+ if ( e.isDefaultPrevented() ) {
+ assert.ok( false, 'Event was incorrectly trapped: ' + e.which );
+ }
+
+ e.preventDefault();
+
+ // Wait for the last event
+ if ( e.which === 32 && e.type === 'mouseup' ) {
+ $document.off( '.mmvtest' );
+ viewer.cleanupEventHandlers();
+ $.scrollTo = oldScrollTo;
+ done();
+ }
+ }
+
+ for ( j = 0; j < eventTypes.length; j++ ) {
+ $document.on( eventTypes[ j ] + '.mmvtest', eventHandler );
+
+ eventloop:
+ for ( i = 0; i < 256; i++ ) {
+ // Save some time by not testing unlikely values for mouse events
+ if ( i > 32 ) {
+ switch ( eventTypes[ j ] ) {
+ case 'click':
+ case 'mousedown':
+ case 'mouseup':
+ break eventloop;
+ }
+ }
+
+ for ( k = 0; k < modifiers.length; k++ ) {
+ eventParameters = { which: i };
+ if ( modifiers[ k ] !== undefined ) {
+ eventParameters[ modifiers[ k ] ] = true;
+ }
+ $qf.trigger( $.Event( eventTypes[ j ], eventParameters ) );
+ }
+ }
+ }
+ } );
+
+ QUnit.test( 'Refuse to load too-big thumbnails', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ intendedWidth = 50,
+ title = mw.Title.newFromText( 'File:Foobar.svg' );
+
+ viewer.thumbnailInfoProvider.get = function ( fileTitle, width ) {
+ assert.strictEqual( width, intendedWidth );
+ return $.Deferred().reject();
+ };
+
+ viewer.fetchThumbnail( title, 1000, null, intendedWidth, 60 );
+ } );
+
+ QUnit.test( 'fetchThumbnail()', function ( assert ) {
+ var guessedThumbnailInfoStub,
+ thumbnailInfoStub,
+ imageStub,
+ promise,
+ useThumbnailGuessing,
+ viewer = new mw.mmv.MultimediaViewer( { imageQueryParameter: $.noop, language: $.noop, recordVirtualViewBeaconURI: $.noop, extensions: function () { return { jpg: 'default' }; }, useThumbnailGuessing: function () { return useThumbnailGuessing; } } ),
+ sandbox = this.sandbox,
+ file = new mw.Title( 'File:Copyleft.svg' ),
+ sampleURL = 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png',
+ width = 100,
+ originalWidth = 1000,
+ originalHeight = 1000,
+ image = {},
+ // custom clock ensures progress handlers execute in correct sequence
+ clock = this.sandbox.useFakeTimers();
+
+ function setupStubs() {
+ guessedThumbnailInfoStub = viewer.guessedThumbnailInfoProvider.get = sandbox.stub();
+ thumbnailInfoStub = viewer.thumbnailInfoProvider.get = sandbox.stub();
+ imageStub = viewer.imageProvider.get = sandbox.stub();
+ }
+
+ useThumbnailGuessing = true;
+
+ // When we lack sample URL and original dimensions, the classic provider should be used
+ setupStubs();
+ guessedThumbnailInfoStub.returns( $.Deferred().resolve( { url: 'guessedURL' } ) );
+ thumbnailInfoStub.returns( $.Deferred().resolve( { url: 'apiURL' } ) );
+ imageStub.returns( $.Deferred().resolve( image ) );
+ promise = viewer.fetchThumbnail( file, width );
+ clock.tick( 10 );
+ assert.ok( !guessedThumbnailInfoStub.called, 'When we lack sample URL and original dimensions, GuessedThumbnailInfoProvider is not called' );
+ assert.ok( thumbnailInfoStub.calledOnce, 'When we lack sample URL and original dimensions, ThumbnailInfoProvider is called once' );
+ assert.ok( imageStub.calledOnce, 'When we lack sample URL and original dimensions, ImageProvider is called once' );
+ assert.ok( imageStub.calledWith( 'apiURL' ), 'When we lack sample URL and original dimensions, ImageProvider is called with the API url' );
+ assert.strictEqual( promise.state(), 'resolved', 'When we lack sample URL and original dimensions, fetchThumbnail resolves' );
+
+ // When the guesser bails out, the classic provider should be used
+ setupStubs();
+ guessedThumbnailInfoStub.returns( $.Deferred().reject() );
+ thumbnailInfoStub.returns( $.Deferred().resolve( { url: 'apiURL' } ) );
+ imageStub.returns( $.Deferred().resolve( image ) );
+ promise = viewer.fetchThumbnail( file, width, sampleURL, originalWidth, originalHeight );
+ clock.tick( 10 );
+ assert.ok( guessedThumbnailInfoStub.calledOnce, 'When the guesser bails out, GuessedThumbnailInfoProvider is called once' );
+ assert.ok( thumbnailInfoStub.calledOnce, 'When the guesser bails out, ThumbnailInfoProvider is called once' );
+ assert.ok( imageStub.calledOnce, 'When the guesser bails out, ImageProvider is called once' );
+ assert.ok( imageStub.calledWith( 'apiURL' ), 'When the guesser bails out, ImageProvider is called with the API url' );
+ assert.strictEqual( promise.state(), 'resolved', 'When the guesser bails out, fetchThumbnail resolves' );
+
+ // When the guesser returns an URL, that should be used
+ setupStubs();
+ guessedThumbnailInfoStub.returns( $.Deferred().resolve( { url: 'guessedURL' } ) );
+ thumbnailInfoStub.returns( $.Deferred().resolve( { url: 'apiURL' } ) );
+ imageStub.returns( $.Deferred().resolve( image ) );
+ promise = viewer.fetchThumbnail( file, width, sampleURL, originalWidth, originalHeight );
+ clock.tick( 10 );
+ assert.ok( guessedThumbnailInfoStub.calledOnce, 'When the guesser returns an URL, GuessedThumbnailInfoProvider is called once' );
+ assert.ok( !thumbnailInfoStub.called, 'When the guesser returns an URL, ThumbnailInfoProvider is not called' );
+ assert.ok( imageStub.calledOnce, 'When the guesser returns an URL, ImageProvider is called once' );
+ assert.ok( imageStub.calledWith( 'guessedURL' ), 'When the guesser returns an URL, ImageProvider is called with the guessed url' );
+ assert.strictEqual( promise.state(), 'resolved', 'When the guesser returns an URL, fetchThumbnail resolves' );
+
+ // When the guesser returns an URL, but that returns 404, image loading should be retried with the classic provider
+ setupStubs();
+ guessedThumbnailInfoStub.returns( $.Deferred().resolve( { url: 'guessedURL' } ) );
+ thumbnailInfoStub.returns( $.Deferred().resolve( { url: 'apiURL' } ) );
+ imageStub.withArgs( 'guessedURL' ).returns( $.Deferred().reject() );
+ imageStub.withArgs( 'apiURL' ).returns( $.Deferred().resolve( image ) );
+ promise = viewer.fetchThumbnail( file, width, sampleURL, originalWidth, originalHeight );
+ clock.tick( 10 );
+ assert.ok( guessedThumbnailInfoStub.calledOnce, 'When the guesser returns an URL, but that returns 404, GuessedThumbnailInfoProvider is called once' );
+ assert.ok( thumbnailInfoStub.calledOnce, 'When the guesser returns an URL, but that returns 404, ThumbnailInfoProvider is called once' );
+ assert.ok( imageStub.calledTwice, 'When the guesser returns an URL, but that returns 404, ImageProvider is called twice' );
+ assert.ok( imageStub.getCall( 0 ).calledWith( 'guessedURL' ), 'When the guesser returns an URL, but that returns 404, ImageProvider is called first with the guessed url' );
+ assert.ok( imageStub.getCall( 1 ).calledWith( 'apiURL' ), 'When the guesser returns an URL, but that returns 404, ImageProvider is called second with the guessed url' );
+ assert.strictEqual( promise.state(), 'resolved', 'When the guesser returns an URL, but that returns 404, fetchThumbnail resolves' );
+
+ // When even the retry fails, fetchThumbnail() should reject
+ setupStubs();
+ guessedThumbnailInfoStub.returns( $.Deferred().resolve( { url: 'guessedURL' } ) );
+ thumbnailInfoStub.returns( $.Deferred().resolve( { url: 'apiURL' } ) );
+ imageStub.withArgs( 'guessedURL' ).returns( $.Deferred().reject() );
+ imageStub.withArgs( 'apiURL' ).returns( $.Deferred().reject() );
+ promise = viewer.fetchThumbnail( file, width, sampleURL, originalWidth, originalHeight );
+ clock.tick( 10 );
+ assert.ok( guessedThumbnailInfoStub.calledOnce, 'When even the retry fails, GuessedThumbnailInfoProvider is called once' );
+ assert.ok( thumbnailInfoStub.calledOnce, 'When even the retry fails, ThumbnailInfoProvider is called once' );
+ assert.ok( imageStub.calledTwice, 'When even the retry fails, ImageProvider is called twice' );
+ assert.ok( imageStub.getCall( 0 ).calledWith( 'guessedURL' ), 'When even the retry fails, ImageProvider is called first with the guessed url' );
+ assert.ok( imageStub.getCall( 1 ).calledWith( 'apiURL' ), 'When even the retry fails, ImageProvider is called second with the guessed url' );
+ assert.strictEqual( promise.state(), 'rejected', 'When even the retry fails, fetchThumbnail rejects' );
+
+ useThumbnailGuessing = false;
+
+ // When guessing is disabled, the classic provider is used
+ setupStubs();
+ guessedThumbnailInfoStub.returns( $.Deferred().resolve( { url: 'guessedURL' } ) );
+ thumbnailInfoStub.returns( $.Deferred().resolve( { url: 'apiURL' } ) );
+ imageStub.returns( $.Deferred().resolve( image ) );
+ promise = viewer.fetchThumbnail( file, width );
+ clock.tick( 10 );
+ assert.ok( !guessedThumbnailInfoStub.called, 'When guessing is disabled, GuessedThumbnailInfoProvider is not called' );
+ assert.ok( thumbnailInfoStub.calledOnce, 'When guessing is disabled, ThumbnailInfoProvider is called once' );
+ assert.ok( imageStub.calledOnce, 'When guessing is disabled, ImageProvider is called once' );
+ assert.ok( imageStub.calledWith( 'apiURL' ), 'When guessing is disabled, ImageProvider is called with the API url' );
+ assert.strictEqual( promise.state(), 'resolved', 'When guessing is disabled, fetchThumbnail resolves' );
+
+ clock.restore();
+ } );
+
+ QUnit.test( 'document.title', function ( assert ) {
+ var viewer = mw.mmv.testHelpers.getMultimediaViewer(),
+ bootstrap = new mw.mmv.MultimediaViewerBootstrap(),
+ title = new mw.Title( 'File:This_should_show_up_in_document_title.png' ),
+ oldDocumentTitle = document.title;
+
+ viewer.currentImageFileTitle = title;
+ bootstrap.setupEventHandlers();
+ viewer.setHash();
+
+ assert.ok( document.title.match( title.getNameText() ), 'File name is visible in title' );
+
+ viewer.close();
+ bootstrap.cleanupEventHandlers();
+
+ assert.strictEqual( document.title, oldDocumentTitle, 'Original title restored after viewer is closed' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.testhelpers.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.testhelpers.js
new file mode 100644
index 00000000..4010883a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/mmv.testhelpers.js
@@ -0,0 +1,174 @@
+( function ( mw, $ ) {
+ var MTH = {};
+
+ MTH.enterFullscreenMock = function () {
+ this.first().addClass( 'jq-fullscreened' ).data( 'isFullscreened', true );
+
+ $( document ).trigger( $.Event( 'jq-fullscreen-change', { element: this, fullscreen: true } ) );
+ };
+
+ MTH.exitFullscreenMock = function () {
+ this.first().removeClass( 'jq-fullscreened' ).data( 'isFullscreened', false );
+
+ $( document ).trigger( $.Event( 'jq-fullscreen-change', { element: this, fullscreen: false } ) );
+ };
+
+ /**
+ * Returns the exception thrown by callback, or undefined if no exception was thrown.
+ *
+ * @param {Function} callback
+ * @return {Error}
+ */
+ MTH.getException = function ( callback ) {
+ var ex;
+ try {
+ callback();
+ } catch ( e ) {
+ ex = e;
+ }
+ return ex;
+ };
+
+ /**
+ * Creates an mw.storage-like object.
+ *
+ * @param {Object} storage localStorage stub with getItem, setItem, removeItem methods
+ * @return {mw.storage} Local storage-like object
+ */
+ MTH.createLocalStorage = function ( storage ) {
+ return new ( Object.getPrototypeOf( mw.storage ) ).constructor( storage );
+ };
+
+ /**
+ * Returns an mw.storage that mimicks lack of localStorage support.
+ *
+ * @return {mw.storage} Local storage-like object
+ */
+ MTH.getUnsupportedLocalStorage = function () {
+ return this.createLocalStorage( undefined );
+ };
+
+ /**
+ * Returns an mw.storage that mimicks localStorage being disabled in browser.
+ *
+ * @return {mw.storage} Local storage-like object
+ */
+ MTH.getDisabledLocalStorage = function () {
+ var e = function () {
+ throw new Error( 'Error' );
+ };
+
+ return this.createLocalStorage( {
+ getItem: e,
+ setItem: e,
+ removeItem: e
+ } );
+ };
+
+ /**
+ * Returns a fake local storage which is not saved between reloads.
+ *
+ * @param {Object} [initialData]
+ * @return {mw.storage} Local storage-like object
+ */
+ MTH.getFakeLocalStorage = function ( initialData ) {
+ var bag = new mw.Map();
+ bag.set( initialData );
+
+ return this.createLocalStorage( {
+ getItem: function ( key ) { return bag.get( key ); },
+ setItem: function ( key, value ) { bag.set( key, value ); },
+ removeItem: function ( key ) { bag.set( key, null ); }
+ } );
+ };
+
+ /**
+ * Returns a viewer object with all the appropriate placeholder functions.
+ *
+ * @return {mv.mmv.MultiMediaViewer} [description]
+ */
+ MTH.getMultimediaViewer = function () {
+ return new mw.mmv.MultimediaViewer( {
+ imageQueryParameter: $.noop,
+ language: $.noop,
+ recordVirtualViewBeaconURI: $.noop,
+ extensions: function () {
+ return { jpg: 'default' };
+ }
+ } );
+ };
+
+ MTH.asyncPromises = [];
+
+ /**
+ * Given a method/function that returns a promise, this'll return a function
+ * that just wraps the original & returns the original result, but also
+ * executes an assert.async() right before it's called, and resolves that
+ * async after that promise has completed.
+ *
+ * Example usage: given a method `bootstrap.openImage` that returns a
+ * promise, just call it like this to wrap this functionality around it:
+ * `bootstrap.openImage = asyncMethod( bootstrap.openImage, bootstrap );`
+ *
+ * Now, every time some part of the code calls this function, it'll just
+ * execute as it normally would, but your tests won't finish until these
+ * functions (and any .then tacked on to them) have completed.
+ *
+ * This method will make sure your tests don't end prematurely (before the
+ * promises have been resolved), but that's it. If you need to run
+ * additional code after all promises have resolved, you can call the
+ * complementary `waitForAsync`, which will return a promise that doesn't
+ * resolve until all of these promises have.
+ *
+ * @param {Object} object
+ * @param {string} method
+ * @param {QUnit.assert} [assert]
+ * @return {Function}
+ */
+ MTH.asyncMethod = function ( object, method, assert ) {
+ return function () {
+ // apply arguments to original promise
+ var promise = object[ method ].apply( object, arguments ),
+ done;
+
+ this.asyncPromises.push( promise );
+
+ if ( assert ) {
+ done = assert.async();
+ // use setTimeout to ensure `done` is not the first callback handler
+ // to execute (possibly ending the test's wait right before
+ // the result of the promise is executed)
+ setTimeout( promise.then.bind( null, done, done ) );
+ }
+
+ return promise;
+ }.bind( this );
+ };
+
+ /**
+ * Returns a promise that will not resolve until all of the promises that
+ * were created in functions upon which `asyncMethod` was called have
+ * resolved.
+ *
+ * @return {$.Promise}
+ */
+ MTH.waitForAsync = function () {
+ var deferred = $.Deferred();
+
+ // it's possible that, before this function call, some code was executed
+ // that triggers async code that will eventually end up `asyncPromises`
+ // in order to give that code a chance to run, we'll add another promise
+ // to the array, that will only resolve at the end of the current call
+ // stack (using setTimeout)
+ this.asyncPromises.push( deferred.promise() );
+ setTimeout( deferred.resolve );
+
+ return QUnit.whenPromisesComplete.apply( null, this.asyncPromises ).then(
+ function () {
+ this.asyncPromises = [];
+ }.bind( this )
+ );
+ };
+
+ mw.mmv.testHelpers = MTH;
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.EmbedFileInfo.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.EmbedFileInfo.test.js
new file mode 100644
index 00000000..be606300
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.EmbedFileInfo.test.js
@@ -0,0 +1,40 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.model.EmbedFileInfo', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'EmbedFileInfo constructor sanity check', function ( assert ) {
+ var imageInfo = {},
+ repoInfo = {},
+ caption = 'Foo',
+ alt = 'Bar',
+ embedFileInfo = new mw.mmv.model.EmbedFileInfo( imageInfo, repoInfo, caption, alt );
+
+ assert.strictEqual( embedFileInfo.imageInfo, imageInfo, 'ImageInfo is set correctly' );
+ assert.strictEqual( embedFileInfo.repoInfo, repoInfo, 'ImageInfo is set correctly' );
+ assert.strictEqual( embedFileInfo.caption, caption, 'Caption is set correctly' );
+ assert.strictEqual( embedFileInfo.alt, alt, 'Alt text is set correctly' );
+
+ try {
+ embedFileInfo = new mw.mmv.model.EmbedFileInfo( {} );
+ } catch ( e ) {
+ assert.ok( e, 'Exception is thrown when parameters are missing' );
+ }
+ } );
+
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Image.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Image.test.js
new file mode 100644
index 00000000..f02c55db
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Image.test.js
@@ -0,0 +1,151 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.model.Image', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Image model constructor sanity check', function ( assert ) {
+ var
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ name = 'Foo bar',
+ size = 100,
+ width = 10,
+ height = 15,
+ mime = 'image/jpeg',
+ url = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ pageID = 42,
+ descurl = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ descShortUrl = '',
+ repo = 'wikimediacommons',
+ datetime = '2011-07-04T23:31:14Z',
+ anondatetime = '20110704000000',
+ origdatetime = '2010-07-04T23:31:14Z',
+ description = 'This is a test file.',
+ source = 'WMF',
+ author = 'Ryan Kaldari',
+ authorCount = 1,
+ permission = 'only use for good, not evil',
+ deletionReason = 'poor quality',
+ license = new mw.mmv.model.License( 'cc0' ),
+ attribution = 'Created by my cats on a winter morning',
+ latitude = 39.12381283,
+ longitude = 100.983829,
+ restrictions = [ 'trademarked' ],
+ imageData = new mw.mmv.model.Image(
+ title, name, size, width, height, mime, url,
+ descurl, descShortUrl, pageID, repo, datetime, anondatetime, origdatetime,
+ description, source, author, authorCount, license, permission, attribution,
+ deletionReason, latitude, longitude, restrictions );
+
+ assert.strictEqual( imageData.title, title, 'Title is set correctly' );
+ assert.strictEqual( imageData.name, name, 'Name is set correctly' );
+ assert.strictEqual( imageData.size, size, 'Size is set correctly' );
+ assert.strictEqual( imageData.width, width, 'Width is set correctly' );
+ assert.strictEqual( imageData.height, height, 'Height is set correctly' );
+ assert.strictEqual( imageData.mimeType, mime, 'MIME type is set correctly' );
+ assert.strictEqual( imageData.url, url, 'URL for original image is set correctly' );
+ assert.strictEqual( imageData.descriptionUrl, descurl, 'URL for image description page is set correctly' );
+ assert.strictEqual( imageData.pageID, pageID, 'Page ID of image description is set correctly' );
+ assert.strictEqual( imageData.repo, repo, 'Repository name is set correctly' );
+ assert.strictEqual( imageData.uploadDateTime, datetime, 'Date and time of last upload is set correctly' );
+ assert.strictEqual( imageData.anonymizedUploadDateTime, anondatetime, 'Anonymized date and time of last upload is set correctly' );
+ assert.strictEqual( imageData.creationDateTime, origdatetime, 'Date and time of original upload is set correctly' );
+ assert.strictEqual( imageData.description, description, 'Description is set correctly' );
+ assert.strictEqual( imageData.source, source, 'Source is set correctly' );
+ assert.strictEqual( imageData.author, author, 'Author is set correctly' );
+ assert.strictEqual( imageData.authorCount, authorCount, 'Author is set correctly' );
+ assert.strictEqual( imageData.license, license, 'License is set correctly' );
+ assert.strictEqual( imageData.permission, permission, 'Permission is set correctly' );
+ assert.strictEqual( imageData.attribution, attribution, 'Attribution is set correctly' );
+ assert.strictEqual( imageData.deletionReason, deletionReason, 'Deletion reason is set correctly' );
+ assert.strictEqual( imageData.latitude, latitude, 'Latitude is set correctly' );
+ assert.strictEqual( imageData.longitude, longitude, 'Longitude is set correctly' );
+ assert.deepEqual( imageData.restrictions, restrictions, 'Restrictions is set correctly' );
+ assert.ok( imageData.thumbUrls, 'Thumb URL cache is set up properly' );
+ } );
+
+ QUnit.test( 'hasCoords()', function ( assert ) {
+ var
+ firstImageData = new mw.mmv.model.Image(
+ mw.Title.newFromText( 'File:Foobar.pdf.jpg' ), 'Foo bar',
+ 10, 10, 10, 'image/jpeg', 'http://example.org', 'http://example.com', 42,
+ 'example', 'tester', '2013-11-10', '20131110', '2013-11-09', 'Blah blah blah',
+ 'A person', 'Another person', 1, 'CC-BY-SA-3.0', 'Permitted', 'My cat'
+ ),
+ secondImageData = new mw.mmv.model.Image(
+ mw.Title.newFromText( 'File:Foobar.pdf.jpg' ), 'Foo bar',
+ 10, 10, 10, 'image/jpeg', 'http://example.org', 'http://example.com', 42,
+ 'example', 'tester', '2013-11-10', '20131110', '2013-11-09', 'Blah blah blah',
+ 'A person', 'Another person', 1, 'CC-BY-SA-3.0', 'Permitted', 'My cat',
+ undefined, '39.91820938', '78.09812938'
+ );
+
+ assert.strictEqual( firstImageData.hasCoords(), false, 'No coordinates present means hasCoords returns false.' );
+ assert.strictEqual( secondImageData.hasCoords(), true, 'Coordinates present means hasCoords returns true.' );
+ } );
+
+ QUnit.test( 'parseExtmeta()', function ( assert ) {
+ var Image = mw.mmv.model.Image,
+ stringData = { value: 'foo' },
+ plaintextData = { value: 'fo<b>o</b>' },
+ integerData = { value: 3 },
+ integerStringData = { value: '3' },
+ zeroPrefixedIntegerStringData = { value: '03' },
+ floatData = { value: 1.23 },
+ floatStringData = { value: '1.23' },
+ booleanData = { value: 'yes' },
+ wrongBooleanData = { value: 'blah' },
+ listDataEmpty = { value: '' },
+ listDataSingle = { value: 'foo' },
+ listDataMultiple = { value: 'foo|bar|baz' },
+ missingData;
+
+ assert.strictEqual( Image.parseExtmeta( stringData, 'string' ), 'foo',
+ 'Extmeta string parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( plaintextData, 'plaintext' ), 'foo',
+ 'Extmeta plaintext parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( floatData, 'float' ), 1.23,
+ 'Extmeta float parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( floatStringData, 'float' ), 1.23,
+ 'Extmeta float string parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( booleanData, 'boolean' ), true,
+ 'Extmeta boolean string parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( wrongBooleanData, 'boolean' ), undefined,
+ 'Extmeta boolean string with error ignored.' );
+ assert.strictEqual( Image.parseExtmeta( integerData, 'integer' ), 3,
+ 'Extmeta integer parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( integerStringData, 'integer' ), 3,
+ 'Extmeta integer string parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( zeroPrefixedIntegerStringData, 'integer' ), 3,
+ 'Extmeta zero-prefixed integer string parsed correctly.' );
+ assert.deepEqual( Image.parseExtmeta( listDataEmpty, 'list' ), [],
+ 'Extmeta empty list parsed correctly.' );
+ assert.deepEqual( Image.parseExtmeta( listDataSingle, 'list' ), [ 'foo' ],
+ 'Extmeta list with single element parsed correctly.' );
+ assert.deepEqual( Image.parseExtmeta( listDataMultiple, 'list' ), [ 'foo', 'bar', 'baz' ],
+ 'Extmeta list with multipleelements parsed correctly.' );
+ assert.strictEqual( Image.parseExtmeta( missingData, 'string' ), undefined,
+ 'Extmeta missing data parsed correctly.' );
+
+ try {
+ Image.parseExtmeta( stringData, 'strong' );
+ } catch ( e ) {
+ assert.ok( e, 'Exception is thrown on invalid argument' );
+ }
+ } );
+
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.IwTitle.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.IwTitle.test.js
new file mode 100644
index 00000000..27cf119d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.IwTitle.test.js
@@ -0,0 +1,43 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.model.IwTitle', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'constructor sanity test', function ( assert ) {
+ var namespace = 4,
+ fullPageName = 'User_talk:John_Doe',
+ domain = 'en.wikipedia.org',
+ url = 'https://en.wikipedia.org/wiki/User_talk:John_Doe',
+ title = new mw.mmv.model.IwTitle( namespace, fullPageName, domain, url );
+
+ assert.ok( title );
+ } );
+
+ QUnit.test( 'getters', function ( assert ) {
+ var namespace = 4,
+ fullPageName = 'User_talk:John_Doe',
+ domain = 'en.wikipedia.org',
+ url = 'https://en.wikipedia.org/wiki/User_talk:John_Doe',
+ title = new mw.mmv.model.IwTitle( namespace, fullPageName, domain, url );
+
+ assert.strictEqual( title.getUrl(), url, 'getUrl()' );
+ assert.strictEqual( title.getDomain(), domain, 'getDomain()' );
+ assert.strictEqual( title.getPrefixedDb(), fullPageName, 'getPrefixedDb()' );
+ assert.strictEqual( title.getPrefixedText(), 'User talk:John Doe', 'getPrefixedText()' );
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.License.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.License.test.js
new file mode 100644
index 00000000..7d758f09
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.License.test.js
@@ -0,0 +1,161 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+
+ QUnit.module( 'mmv.model.License', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'License constructor sanity check', function ( assert ) {
+ var license,
+ shortName = 'CC-BY-SA-3.0',
+ internalName = 'cc-by-sa-3.0',
+ longName = 'Creative Commons Attribution--Share-Alike 3.0',
+ url = 'http://creativecommons.org/licenses/by-sa/3.0/';
+
+ license = new mw.mmv.model.License( shortName );
+ assert.ok( license, 'License created successfully' );
+ assert.strictEqual( license.shortName, shortName, 'License has correct short name' );
+ assert.ok( !license.internalName, 'License has no internal name' );
+ assert.ok( !license.longName, 'License has no long name' );
+ assert.ok( !license.deedUrl, 'License has no deed URL' );
+
+ license = new mw.mmv.model.License( shortName, internalName, longName, url );
+ assert.ok( license, 'License created successfully' );
+ assert.strictEqual( license.shortName, shortName, 'License has correct short name' );
+ assert.strictEqual( license.internalName, internalName, 'License has correct internal name' );
+ assert.strictEqual( license.longName, longName, 'License has correct long name' );
+ assert.strictEqual( license.deedUrl, url, 'License has correct deed URL' );
+
+ try {
+ license = new mw.mmv.model.License();
+ } catch ( e ) {
+ assert.ok( e, 'License cannot be created without a short name' );
+ }
+ } );
+
+ QUnit.test( 'getShortName()', function ( assert ) {
+ var existingMessageKey = 'Internal name that does exist',
+ nonExistingMessageKey = 'Internal name that does not exist',
+ license1 = new mw.mmv.model.License( 'Shortname' ),
+ license2 = new mw.mmv.model.License( 'Shortname', nonExistingMessageKey ),
+ license3 = new mw.mmv.model.License( 'Shortname', existingMessageKey ),
+ oldMwMessage = mw.message,
+ oldMwMessagesExists = mw.messages.exists;
+
+ mw.message = function ( name ) {
+ return name === 'multimediaviewer-license-' + existingMessageKey ?
+ { text: function () { return 'Translated name'; } } :
+ oldMwMessage.apply( mw, arguments );
+ };
+ mw.messages.exists = function ( name ) {
+ return name === 'multimediaviewer-license-' + existingMessageKey ?
+ true : oldMwMessagesExists.apply( mw.messages, arguments );
+ };
+
+ assert.strictEqual( license1.getShortName(), 'Shortname',
+ 'Short name is returned when there is no translated name' );
+ assert.strictEqual( license2.getShortName(), 'Shortname',
+ 'Short name is returned when translated name is missing' );
+ assert.strictEqual( license3.getShortName(), 'Translated name',
+ 'Translated name is returned when it exists' );
+
+ mw.message = oldMwMessage;
+ mw.messages.exists = oldMwMessagesExists;
+ } );
+
+ QUnit.test( 'getShortLink()', function ( assert ) {
+ var $html,
+ license1 = new mw.mmv.model.License( 'lorem ipsum' ),
+ license2 = new mw.mmv.model.License( 'lorem ipsum', 'lipsum' ),
+ license3 = new mw.mmv.model.License( 'lorem ipsum', 'lipsum', 'Lorem ipsum dolor sit amet' ),
+ license4 = new mw.mmv.model.License( 'lorem ipsum', 'lipsum', 'Lorem ipsum dolor sit amet',
+ 'http://www.lipsum.com/' );
+
+ assert.strictEqual( license1.getShortLink(), 'lorem ipsum',
+ 'Code for license without link is formatted correctly' );
+ assert.strictEqual( license2.getShortLink(), 'lorem ipsum',
+ 'Code for license without link is formatted correctly' );
+ assert.strictEqual( license3.getShortLink(), 'lorem ipsum',
+ 'Code for license without link is formatted correctly' );
+
+ $html = $( license4.getShortLink() );
+ assert.strictEqual( $html.text(), 'lorem ipsum',
+ 'Text for license with link is formatted correctly' );
+ assert.strictEqual( $html.prop( 'href' ), 'http://www.lipsum.com/',
+ 'URL for license with link is formatted correctly' );
+ assert.strictEqual( $html.prop( 'title' ), 'Lorem ipsum dolor sit amet',
+ 'Title for license with link is formatted correctly' );
+ } );
+
+ QUnit.test( 'isCc()', function ( assert ) {
+ var license;
+
+ license = new mw.mmv.model.License( 'CC-BY-SA-2.0', 'cc-by-sa-2.0',
+ 'Creative Commons Attribution - ShareAlike 2.0',
+ 'http://creativecommons.org/licenses/by-sa/2.0/' );
+ assert.strictEqual( license.isCc(), true, 'CC license recognized' );
+
+ license = new mw.mmv.model.License( 'Public Domain', 'pd',
+ 'Public Domain for lack of originality' );
+ assert.strictEqual( license.isCc(), false, 'Non-CC license not recognized' );
+
+ license = new mw.mmv.model.License( 'MIT' );
+ assert.strictEqual( license.isCc(), false, 'Non-CC license with no internal name not recognized' );
+ } );
+
+ QUnit.test( 'isPd()', function ( assert ) {
+ var license;
+
+ license = new mw.mmv.model.License( 'Public Domain', 'pd',
+ 'Public Domain for lack of originality' );
+ assert.strictEqual( license.isPd(), true, 'PD license recognized' );
+
+ license = new mw.mmv.model.License( 'CC-BY-SA-2.0', 'cc-by-sa-2.0',
+ 'Creative Commons Attribution - ShareAlike 2.0',
+ 'http://creativecommons.org/licenses/by-sa/2.0/' );
+ assert.strictEqual( license.isPd(), false, 'Non-PD license not recognized' );
+
+ license = new mw.mmv.model.License( 'MIT' );
+ assert.strictEqual( license.isPd(), false, 'Non-PD license with no internal name not recognized' );
+ } );
+
+ QUnit.test( 'isFree()', function ( assert ) {
+ var license;
+
+ license = new mw.mmv.model.License( 'CC-BY-SA-2.0', 'cc-by-sa-2.0',
+ 'Creative Commons Attribution - ShareAlike 2.0',
+ 'http://creativecommons.org/licenses/by-sa/2.0/' );
+ assert.strictEqual( license.isFree(), true, 'Licenses default to free' );
+
+ license = new mw.mmv.model.License( 'Fair use', 'fairuse',
+ 'Fair use', undefined, undefined, true );
+ assert.strictEqual( license.isFree(), false, 'Non-free flag handled correctly' );
+ } );
+
+ QUnit.test( 'needsAttribution()', function ( assert ) {
+ var license;
+
+ license = new mw.mmv.model.License( 'CC-BY-SA-2.0', 'cc-by-sa-2.0',
+ 'Creative Commons Attribution - ShareAlike 2.0',
+ 'http://creativecommons.org/licenses/by-sa/2.0/' );
+ assert.strictEqual( license.needsAttribution(), true, 'Licenses assumed to need attribution by default' );
+
+ license = new mw.mmv.model.License( 'Public Domain', 'pd',
+ 'Public Domain for lack of originality', false );
+ assert.strictEqual( license.needsAttribution(), false, 'Attribution required flag handled correctly' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Repo.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Repo.test.js
new file mode 100644
index 00000000..a9bc7a2d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.Repo.test.js
@@ -0,0 +1,100 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.model.Repo', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Repo constructor sanity check', function ( assert ) {
+ var displayName = 'Wikimedia Commons',
+ favicon = '//commons.wikimedia.org/favicon.ico',
+ apiUrl = '//commons.wikimedia.org/w/api.php',
+ server = '//commons.wikimedia.org',
+ articlePath = '//commons.wikimedia.org/wiki/$1',
+ descBaseUrl = '//commons.wikimedia.org/wiki/File:',
+ localRepo = new mw.mmv.model.Repo( displayName, favicon, true ),
+ foreignApiRepo = new mw.mmv.model.ForeignApiRepo( displayName, favicon,
+ false, apiUrl, server, articlePath ),
+ foreignDbRepo = new mw.mmv.model.ForeignDbRepo( displayName, favicon, false, descBaseUrl );
+
+ assert.ok( localRepo, 'Local repo creation works' );
+ assert.ok( foreignApiRepo,
+ 'Foreign API repo creation works' );
+ assert.ok( foreignDbRepo, 'Foreign DB repo creation works' );
+ } );
+
+ QUnit.test( 'getArticlePath()', function ( assert ) {
+ var displayName = 'Wikimedia Commons',
+ favicon = '//commons.wikimedia.org/favicon.ico',
+ apiUrl = '//commons.wikimedia.org/w/api.php',
+ server = '//commons.wikimedia.org',
+ articlePath = '/wiki/$1',
+ descBaseUrl = '//commons.wikimedia.org/wiki/File:',
+ localRepo = new mw.mmv.model.Repo( displayName, favicon, true ),
+ foreignApiRepo = new mw.mmv.model.ForeignApiRepo( displayName, favicon,
+ false, apiUrl, server, articlePath ),
+ foreignDbRepo = new mw.mmv.model.ForeignDbRepo( displayName, favicon, false, descBaseUrl ),
+ expectedLocalArticlePath = '/wiki/$1',
+ expectedFullArticlePath = '//commons.wikimedia.org/wiki/$1',
+ oldWgArticlePath = mw.config.get( 'wgArticlePath' ),
+ oldWgServer = mw.config.get( 'wgServer' );
+
+ mw.config.set( 'wgArticlePath', '/wiki/$1' );
+ mw.config.set( 'wgServer', server );
+
+ assert.strictEqual( localRepo.getArticlePath(), expectedLocalArticlePath,
+ 'Local repo article path is correct' );
+ assert.strictEqual( localRepo.getArticlePath( true ), expectedFullArticlePath,
+ 'Local repo absolute article path is correct' );
+ assert.strictEqual( foreignApiRepo.getArticlePath(), expectedFullArticlePath,
+ 'Foreign API article path is correct' );
+ assert.strictEqual( foreignDbRepo.getArticlePath(), expectedFullArticlePath,
+ 'Foreign DB article path is correct' );
+
+ mw.config.set( 'wgArticlePath', oldWgArticlePath );
+ mw.config.set( 'wgServer', oldWgServer );
+ } );
+
+ QUnit.test( 'getSiteLink()', function ( assert ) {
+ var displayName = 'Wikimedia Commons',
+ favicon = '//commons.wikimedia.org/favicon.ico',
+ apiUrl = '//commons.wikimedia.org/w/api.php',
+ server = '//commons.wikimedia.org',
+ articlePath = '/wiki/$1',
+ descBaseUrl = '//commons.wikimedia.org/wiki/File:',
+ localRepo = new mw.mmv.model.Repo( displayName, favicon, true ),
+ foreignApiRepo = new mw.mmv.model.ForeignApiRepo( displayName, favicon,
+ false, apiUrl, server, articlePath ),
+ foreignDbRepo = new mw.mmv.model.ForeignDbRepo( displayName, favicon, false, descBaseUrl ),
+ expectedSiteLink = '//commons.wikimedia.org/wiki/',
+ oldWgArticlePath = mw.config.get( 'wgArticlePath' ),
+ oldWgServer = mw.config.get( 'wgServer' );
+
+ mw.config.set( 'wgArticlePath', '/wiki/$1' );
+ mw.config.set( 'wgServer', server );
+
+ assert.strictEqual( localRepo.getSiteLink(), expectedSiteLink,
+ 'Local repo site link is correct' );
+ assert.strictEqual( foreignApiRepo.getSiteLink(), expectedSiteLink,
+ 'Foreign API repo site link is correct' );
+ assert.strictEqual( foreignDbRepo.getSiteLink(), expectedSiteLink,
+ 'Foreign DB repo site link is correct' );
+
+ mw.config.set( 'wgArticlePath', oldWgArticlePath );
+ mw.config.set( 'wgServer', oldWgServer );
+ } );
+
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.TaskQueue.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.TaskQueue.test.js
new file mode 100644
index 00000000..f3958a24
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.TaskQueue.test.js
@@ -0,0 +1,276 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.model.TaskQueue', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'TaskQueue constructor sanity check', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue();
+
+ assert.ok( taskQueue, 'TaskQueue created successfully' );
+ } );
+
+ QUnit.test( 'Queue length check', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue();
+
+ assert.strictEqual( taskQueue.queue.length, 0, 'queue is initially empty' );
+
+ taskQueue.push( function () {} );
+
+ assert.strictEqual( taskQueue.queue.length, 1, 'queue length is incremented on push' );
+ } );
+
+ QUnit.test( 'State check', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ task = $.Deferred(),
+ promise;
+
+ taskQueue.push( function () { return task; } );
+
+ assert.strictEqual( taskQueue.state, mw.mmv.model.TaskQueue.State.NOT_STARTED,
+ 'state is initially NOT_STARTED' );
+
+ promise = taskQueue.execute().then( function () {
+ assert.strictEqual( taskQueue.state, mw.mmv.model.TaskQueue.State.FINISHED,
+ 'state is FINISHED after execution finished' );
+ } );
+
+ assert.strictEqual( taskQueue.state, mw.mmv.model.TaskQueue.State.RUNNING,
+ 'state is RUNNING after execution started' );
+
+ task.resolve();
+
+ return promise;
+ } );
+
+ QUnit.test( 'State check for cancellation', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ task = $.Deferred();
+
+ taskQueue.push( function () { return task; } );
+ taskQueue.execute();
+ taskQueue.cancel();
+
+ assert.strictEqual( taskQueue.state, mw.mmv.model.TaskQueue.State.CANCELLED,
+ 'state is CANCELLED after cancellation' );
+ } );
+
+ QUnit.test( 'Test executing empty queue', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue();
+
+ return taskQueue.execute().done( function () {
+ assert.ok( true, 'Queue promise resolved' );
+ } );
+ } );
+
+ QUnit.test( 'Simple execution test', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ called = false;
+
+ taskQueue.push( function () {
+ called = true;
+ } );
+
+ return taskQueue.execute().then( function () {
+ assert.strictEqual( called, true, 'Task executed successfully' );
+ } );
+ } );
+
+ QUnit.test( 'Task execution order test', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ order = [];
+
+ taskQueue.push( function () {
+ order.push( 1 );
+ } );
+
+ taskQueue.push( function () {
+ var deferred = $.Deferred();
+
+ order.push( 2 );
+
+ setTimeout( function () {
+ deferred.resolve();
+ }, 0 );
+
+ return deferred;
+ } );
+
+ taskQueue.push( function () {
+ order.push( 3 );
+ } );
+
+ return taskQueue.execute().then( function () {
+ assert.deepEqual( order, [ 1, 2, 3 ], 'Tasks executed in order' );
+ } );
+ } );
+
+ QUnit.test( 'Double execution test', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ called = 0;
+
+ taskQueue.push( function () {
+ called++;
+ } );
+
+ return taskQueue.execute().then( function () {
+ return taskQueue.execute();
+ } ).then( function () {
+ assert.strictEqual( called, 1, 'Task executed only once' );
+ } );
+ } );
+
+ QUnit.test( 'Parallel execution test', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ called = 0;
+
+ taskQueue.push( function () {
+ called++;
+ } );
+
+ return $.when(
+ taskQueue.execute(),
+ taskQueue.execute()
+ ).then( function () {
+ assert.strictEqual( called, 1, 'Task executed only once' );
+ } );
+ } );
+
+ QUnit.test( 'Test push after execute', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue();
+
+ taskQueue.execute();
+
+ try {
+ taskQueue.push( function () {} );
+ } catch ( e ) {
+ assert.ok( e, 'Exception thrown when trying to push to an already running queue' );
+ }
+ } );
+
+ QUnit.test( 'Test failed task', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue();
+
+ taskQueue.push( function () {
+ return $.Deferred().reject();
+ } );
+
+ return taskQueue.execute().done( function () {
+ assert.ok( true, 'Queue promise resolved' );
+ } );
+ } );
+
+ QUnit.test( 'Test that tasks wait for each other', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ longRunningTaskFinished = false,
+ seenFinished = false;
+
+ taskQueue.push( function () {
+ var deferred = $.Deferred();
+
+ setTimeout( function () {
+ longRunningTaskFinished = true;
+ deferred.resolve();
+ }, 0 );
+
+ return deferred;
+ } );
+
+ taskQueue.push( function () {
+ seenFinished = longRunningTaskFinished;
+ } );
+
+ return taskQueue.execute().then( function () {
+ assert.ok( seenFinished, 'Task waits for previous task to finish' );
+ } );
+ } );
+
+ QUnit.test( 'Test cancellation before start', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ triggered = false,
+ verificationTask = function () {
+ triggered = true;
+ };
+
+ taskQueue.push( verificationTask );
+
+ taskQueue.cancel();
+
+ taskQueue.execute()
+ .done( function () {
+ assert.ok( false, 'Queue promise rejected' );
+ } )
+ .fail( function () {
+ assert.ok( true, 'Queue promise rejected' );
+ assert.strictEqual( triggered, false, 'Task was not triggered' );
+ } )
+ .always( assert.async() );
+ } );
+
+ QUnit.test( 'Test cancellation within callback', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ triggered = false,
+ verificationTask = function () {
+ triggered = true;
+ };
+
+ taskQueue.push( function () {
+ taskQueue.cancel();
+ } );
+ taskQueue.push( verificationTask );
+
+ taskQueue.execute()
+ .done( function () {
+ assert.ok( false, 'Queue promise rejected' );
+ } )
+ .fail( function () {
+ assert.ok( true, 'Queue promise rejected' );
+ assert.strictEqual( triggered, false, 'Task was not triggered' );
+ } )
+ .always( assert.async() );
+ } );
+
+ QUnit.test( 'Test cancellation from task', function ( assert ) {
+ var taskQueue = new mw.mmv.model.TaskQueue(),
+ triggered = false,
+ task1 = $.Deferred(),
+ verificationTask = function () {
+ triggered = true;
+ };
+
+ taskQueue.push( function () {
+ return task1;
+ } );
+ taskQueue.push( verificationTask );
+
+ setTimeout( function () {
+ taskQueue.cancel();
+ task1.resolve();
+ }, 0 );
+
+ taskQueue.execute()
+ .done( function () {
+ assert.ok( false, 'Queue promise rejected' );
+ } )
+ .fail( function () {
+ assert.ok( true, 'Queue promise rejected' );
+ assert.strictEqual( triggered, false, 'Task was not triggered' );
+ } )
+ .always( assert.async() );
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.test.js
new file mode 100644
index 00000000..a24241dc
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/model/mmv.model.test.js
@@ -0,0 +1,58 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.model', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Thumbnail constructor sanity check', function ( assert ) {
+ var width = 23,
+ height = 42,
+ url = 'http://example.com/foo.jpg',
+ thumbnail = new mw.mmv.model.Thumbnail( url, width, height );
+
+ assert.strictEqual( thumbnail.url, url, 'Url is set correctly' );
+ assert.strictEqual( thumbnail.width, width, 'Width is set correctly' );
+ assert.strictEqual( thumbnail.height, height, 'Height is set correctly' );
+
+ try {
+ thumbnail = new mw.mmv.model.Thumbnail( url, width );
+ } catch ( e ) {
+ assert.ok( e, 'Exception is thrown when parameters are missing' );
+ }
+ } );
+
+ QUnit.test( 'ThumbnailWidth constructor sanity check', function ( assert ) {
+ var cssWidth = 23,
+ cssHeight = 29,
+ screenWidth = 42,
+ realWidth = 123,
+ thumbnailWidth = new mw.mmv.model.ThumbnailWidth(
+ cssWidth, cssHeight, screenWidth, realWidth );
+
+ assert.strictEqual( thumbnailWidth.cssWidth, cssWidth, 'Width is set correctly' );
+ assert.strictEqual( thumbnailWidth.cssHeight, cssHeight, 'Height is set correctly' );
+ assert.strictEqual( thumbnailWidth.screen, screenWidth, 'Screen width is set correctly' );
+ assert.strictEqual( thumbnailWidth.real, realWidth, 'Real width is set correctly' );
+
+ try {
+ thumbnailWidth = new mw.mmv.model.ThumbnailWidth( cssWidth, screenWidth );
+ } catch ( e ) {
+ assert.ok( e, 'Exception is thrown when parameters are missing' );
+ }
+ } );
+
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Api.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Api.test.js
new file mode 100644
index 00000000..371a22a5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Api.test.js
@@ -0,0 +1,270 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.provider.Api', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Api constructor sanity check', function ( assert ) {
+ var api = { get: function () {} },
+ options = {},
+ apiProvider = new mw.mmv.provider.Api( api, options ),
+ ApiProviderWithNoOptions = new mw.mmv.provider.Api( api );
+
+ assert.ok( apiProvider );
+ assert.ok( ApiProviderWithNoOptions );
+ } );
+
+ QUnit.test( 'apiGetWithMaxAge()', function ( assert ) {
+ var api = {},
+ options = {},
+ apiProvider = new mw.mmv.provider.Api( api, options );
+
+ api.get = this.sandbox.stub();
+ apiProvider.apiGetWithMaxAge( {} );
+ assert.ok( !( 'maxage' in api.get.getCall( 0 ).args[ 0 ] ), 'maxage is not set by default' );
+ assert.ok( !( 'smaxage' in api.get.getCall( 0 ).args[ 0 ] ), 'smaxage is not set by default' );
+
+ options = { maxage: 123 };
+ apiProvider = new mw.mmv.provider.Api( api, options );
+
+ api.get = this.sandbox.stub();
+ apiProvider.apiGetWithMaxAge( {} );
+ assert.strictEqual( api.get.getCall( 0 ).args[ 0 ].maxage, 123, 'maxage falls back to provider default' );
+ assert.strictEqual( api.get.getCall( 0 ).args[ 0 ].smaxage, 123, 'smaxage falls back to provider default' );
+
+ api.get = this.sandbox.stub();
+ apiProvider.apiGetWithMaxAge( {}, null, 456 );
+ assert.strictEqual( api.get.getCall( 0 ).args[ 0 ].maxage, 456, 'maxage can be overridden' );
+ assert.strictEqual( api.get.getCall( 0 ).args[ 0 ].smaxage, 456, 'smaxage can be overridden' );
+
+ api.get = this.sandbox.stub();
+ apiProvider.apiGetWithMaxAge( {}, null, null );
+ assert.ok( !( 'maxage' in api.get.getCall( 0 ).args[ 0 ] ), 'maxage can be overridden to unset' );
+ assert.ok( !( 'smaxage' in api.get.getCall( 0 ).args[ 0 ] ), 'smaxage can be overridden to unset' );
+ } );
+
+ QUnit.test( 'getCachedPromise success', function ( assert ) {
+ var api = { get: function () {} },
+ apiProvider = new mw.mmv.provider.Api( api ),
+ oldMwLog = mw.log,
+ promiseSource,
+ promiseShouldBeCached = false;
+
+ mw.log = function () {
+ assert.ok( false, 'mw.log should not have been called' );
+ };
+
+ promiseSource = function ( result ) {
+ return function () {
+ assert.ok( !promiseShouldBeCached, 'promise was not cached' );
+ return $.Deferred().resolve( result );
+ };
+ };
+
+ apiProvider.getCachedPromise( 'foo', promiseSource( 1 ) ).done( function ( result ) {
+ assert.strictEqual( result, 1, 'result comes from the promise source' );
+ } );
+
+ apiProvider.getCachedPromise( 'bar', promiseSource( 2 ) ).done( function ( result ) {
+ assert.strictEqual( result, 2, 'result comes from the promise source' );
+ } );
+
+ promiseShouldBeCached = true;
+ apiProvider.getCachedPromise( 'foo', promiseSource( 3 ) ).done( function ( result ) {
+ assert.strictEqual( result, 1, 'result comes from cache' );
+ } );
+
+ mw.log = oldMwLog;
+ } );
+
+ QUnit.test( 'getCachedPromise failure', function ( assert ) {
+ var api = { get: function () {} },
+ apiProvider = new mw.mmv.provider.Api( api ),
+ oldMwLog = mw.log,
+ promiseSource,
+ promiseShouldBeCached = false;
+
+ mw.log = function () {
+ assert.ok( true, 'mw.log was called' );
+ };
+
+ promiseSource = function ( result ) {
+ return function () {
+ assert.ok( !promiseShouldBeCached, 'promise was not cached' );
+ return $.Deferred().reject( result );
+ };
+ };
+
+ apiProvider.getCachedPromise( 'foo', promiseSource( 1 ) ).fail( function ( result ) {
+ assert.strictEqual( result, 1, 'result comes from the promise source' );
+ } );
+
+ apiProvider.getCachedPromise( 'bar', promiseSource( 2 ) ).fail( function ( result ) {
+ assert.strictEqual( result, 2, 'result comes from the promise source' );
+ } );
+
+ promiseShouldBeCached = true;
+ apiProvider.getCachedPromise( 'foo', promiseSource( 3 ) ).fail( function ( result ) {
+ assert.strictEqual( result, 1, 'result comes from cache' );
+ } );
+
+ mw.log = oldMwLog;
+ } );
+
+ QUnit.test( 'getErrorMessage', function ( assert ) {
+ var api = { get: function () {} },
+ apiProvider = new mw.mmv.provider.Api( api ),
+ errorMessage;
+
+ errorMessage = apiProvider.getErrorMessage( {
+ servedby: 'mw1194',
+ error: {
+ code: 'unknown_action',
+ info: 'Unrecognized value for parameter \'action\': FOO'
+ }
+ } );
+ assert.strictEqual( errorMessage,
+ 'unknown_action: Unrecognized value for parameter \'action\': FOO',
+ 'error message is parsed correctly' );
+
+ assert.strictEqual( apiProvider.getErrorMessage( {} ), 'unknown error', 'missing error message is handled' );
+ } );
+
+ QUnit.test( 'getNormalizedTitle', function ( assert ) {
+ var api = { get: function () {} },
+ apiProvider = new mw.mmv.provider.Api( api ),
+ title = new mw.Title( 'Image:Stuff.jpg' ),
+ normalizedTitle;
+
+ normalizedTitle = apiProvider.getNormalizedTitle( title, {} );
+ assert.strictEqual( normalizedTitle, title, 'missing normalization block is handled' );
+
+ normalizedTitle = apiProvider.getNormalizedTitle( title, {
+ query: {
+ normalized: [
+ {
+ from: 'Image:Foo.jpg',
+ to: 'File:Foo.jpg'
+ }
+ ]
+ }
+ } );
+ assert.strictEqual( normalizedTitle, title, 'irrelevant normalization info is skipped' );
+
+ normalizedTitle = apiProvider.getNormalizedTitle( title, {
+ query: {
+ normalized: [
+ {
+ from: 'Image:Stuff.jpg',
+ to: 'File:Stuff.jpg'
+ }
+ ]
+ }
+ } );
+ assert.strictEqual( normalizedTitle.getPrefixedDb(), 'File:Stuff.jpg', 'normalization happens' );
+ } );
+
+ QUnit.test( 'getQueryField', function ( assert ) {
+ var api = { get: function () {} },
+ apiProvider = new mw.mmv.provider.Api( api ),
+ done = assert.async( 3 ),
+ data;
+
+ data = {
+ query: {
+ imageusage: [
+ {
+ pageid: 736,
+ ns: 0,
+ title: 'Albert Einstein'
+ }
+ ]
+ }
+ };
+
+ apiProvider.getQueryField( 'imageusage', data ).then( function ( field ) {
+ assert.strictEqual( field, data.query.imageusage, 'specified field is found' );
+ done();
+ } );
+ apiProvider.getQueryField( 'imageusage', {} ).fail( function () {
+ assert.ok( true, 'promise rejected when data is missing' );
+ done();
+ } );
+
+ apiProvider.getQueryField( 'imageusage', { data: { query: {} } } ).fail( function () {
+ assert.ok( true, 'promise rejected when field is missing' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'getQueryPage', function ( assert ) {
+ var api = { get: function () {} },
+ apiProvider = new mw.mmv.provider.Api( api ),
+ title = new mw.Title( 'File:Stuff.jpg' ),
+ titleWithNamespaceAlias = new mw.Title( 'Image:Stuff.jpg' ),
+ otherTitle = new mw.Title( 'File:Foo.jpg' ),
+ done = assert.async( 6 ),
+ data;
+
+ data = {
+ normalized: [
+ {
+ from: 'Image:Stuff.jpg',
+ to: 'File:Stuff.jpg'
+ }
+ ],
+ query: {
+ pages: {
+ '-1': {
+ title: 'File:Stuff.jpg'
+ }
+ }
+ }
+ };
+
+ apiProvider.getQueryPage( title, data ).then( function ( field ) {
+ assert.strictEqual( field, data.query.pages[ '-1' ], 'specified page is found' );
+ done();
+ } );
+
+ apiProvider.getQueryPage( titleWithNamespaceAlias, data ).then( function ( field ) {
+ assert.strictEqual( field, data.query.pages[ '-1' ],
+ 'specified page is found even if its title was normalized' );
+ done();
+ } );
+
+ apiProvider.getQueryPage( otherTitle, {} ).fail( function () {
+ assert.ok( true, 'promise rejected when page has different title' );
+ done();
+ } );
+
+ apiProvider.getQueryPage( title, {} ).fail( function () {
+ assert.ok( true, 'promise rejected when data is missing' );
+ done();
+ } );
+
+ apiProvider.getQueryPage( title, { data: { query: {} } } ).fail( function () {
+ assert.ok( true, 'promise rejected when pages are missing' );
+ done();
+ } );
+
+ apiProvider.getQueryPage( title, { data: { query: { pages: {} } } } ).fail( function () {
+ assert.ok( true, 'promise rejected when pages are empty' );
+ done();
+ } );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.FileRepoInfo.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.FileRepoInfo.test.js
new file mode 100644
index 00000000..80771784
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.FileRepoInfo.test.js
@@ -0,0 +1,126 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.provider.FileRepoInfo', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'FileRepoInfo constructor sanity check', function ( assert ) {
+ var api = { get: function () {} },
+ fileRepoInfoProvider = new mw.mmv.provider.FileRepoInfo( api );
+
+ assert.ok( fileRepoInfoProvider );
+ } );
+
+ QUnit.test( 'FileRepoInfo get test', function ( assert ) {
+ var apiCallCount = 0,
+ api = { get: function () {
+ apiCallCount++;
+ return $.Deferred().resolve( {
+ query: {
+ repos: [
+ {
+ name: 'shared',
+ displayname: 'Wikimedia Commons',
+ rootUrl: '//upload.beta.wmflabs.org/wikipedia/commons',
+ local: false,
+ url: '//upload.beta.wmflabs.org/wikipedia/commons',
+ thumbUrl: '//upload.beta.wmflabs.org/wikipedia/commons/thumb',
+ initialCapital: true,
+ descBaseUrl: '//commons.wikimedia.beta.wmflabs.org/wiki/File:',
+ scriptDirUrl: '//commons.wikimedia.beta.wmflabs.org/w',
+ fetchDescription: true,
+ favicon: 'http://en.wikipedia.org/favicon.ico'
+ },
+ {
+ name: 'wikimediacommons',
+ displayname: 'Wikimedia Commons',
+ rootUrl: '//upload.beta.wmflabs.org/wikipedia/en',
+ local: false,
+ url: '//upload.beta.wmflabs.org/wikipedia/en',
+ thumbUrl: '//upload.beta.wmflabs.org/wikipedia/en/thumb',
+ initialCapital: true,
+ scriptDirUrl: 'http://commons.wikimedia.org/w',
+ fetchDescription: true,
+ descriptionCacheExpiry: 43200,
+ apiurl: 'http://commons.wikimedia.org/w/api.php',
+ articlepath: '/wiki/$1',
+ server: '//commons.wikimedia.org',
+ favicon: '//commons.wikimedia.org/favicon.ico'
+ },
+ {
+ name: 'local',
+ displayname: null,
+ rootUrl: '//upload.beta.wmflabs.org/wikipedia/en',
+ local: true,
+ url: '//upload.beta.wmflabs.org/wikipedia/en',
+ thumbUrl: '//upload.beta.wmflabs.org/wikipedia/en/thumb',
+ initialCapital: true,
+ scriptDirUrl: '/w',
+ favicon: 'http://en.wikipedia.org/favicon.ico'
+ }
+ ]
+ }
+ } );
+ } },
+ fileRepoInfoProvider = new mw.mmv.provider.FileRepoInfo( api );
+
+ return fileRepoInfoProvider.get().then( function ( repos ) {
+ assert.strictEqual( repos.shared.displayName,
+ 'Wikimedia Commons', 'displayName is set correctly' );
+ assert.strictEqual( repos.shared.favIcon,
+ 'http://en.wikipedia.org/favicon.ico', 'favIcon is set correctly' );
+ assert.strictEqual( repos.shared.isLocal, false, 'isLocal is set correctly' );
+ assert.strictEqual( repos.shared.descBaseUrl,
+ '//commons.wikimedia.beta.wmflabs.org/wiki/File:', 'descBaseUrl is set correctly' );
+
+ assert.strictEqual( repos.wikimediacommons.displayName,
+ 'Wikimedia Commons', 'displayName is set correctly' );
+ assert.strictEqual( repos.wikimediacommons.favIcon,
+ '//commons.wikimedia.org/favicon.ico', 'favIcon is set correctly' );
+ assert.strictEqual( repos.wikimediacommons.isLocal, false, 'isLocal is set correctly' );
+ assert.strictEqual( repos.wikimediacommons.apiUrl,
+ 'http://commons.wikimedia.org/w/api.php', 'apiUrl is set correctly' );
+ assert.strictEqual( repos.wikimediacommons.server,
+ '//commons.wikimedia.org', 'server is set correctly' );
+ assert.strictEqual( repos.wikimediacommons.articlePath,
+ '/wiki/$1', 'articlePath is set correctly' );
+
+ assert.strictEqual( repos.local.displayName, null, 'displayName is set correctly' );
+ assert.strictEqual( repos.local.favIcon,
+ 'http://en.wikipedia.org/favicon.ico', 'favIcon is set correctly' );
+ assert.strictEqual( repos.local.isLocal, true, 'isLocal is set correctly' );
+ } ).then( function () {
+ // call the data provider a second time to check caching
+ return fileRepoInfoProvider.get();
+ } ).then( function () {
+ assert.strictEqual( apiCallCount, 1 );
+ } );
+ } );
+
+ QUnit.test( 'FileRepoInfo fail test', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {} );
+ } },
+ done = assert.async(),
+ fileRepoInfoProvider = new mw.mmv.provider.FileRepoInfo( api );
+
+ fileRepoInfoProvider.get().fail( function () {
+ assert.ok( true, 'promise rejected when no data is returned' );
+ done();
+ } );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.GuessedThumbnailInfo.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.GuessedThumbnailInfo.test.js
new file mode 100644
index 00000000..93cd51fa
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.GuessedThumbnailInfo.test.js
@@ -0,0 +1,280 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.provider.GuessedThumbnailInfo', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity check', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo();
+ assert.ok( provider, 'Constructor call successful' );
+ } );
+
+ QUnit.test( 'get()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' ),
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/180px-Copyleft.svg.png',
+ width = 300,
+ originalWidth = 512,
+ originalHeight = 512,
+ resultUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png',
+ done = assert.async(),
+ result;
+
+ provider.getUrl = function () { return resultUrl; };
+ result = provider.get( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.ok( result.then, 'Result is a promise' );
+ assert.strictEqual( result.state(), 'resolved', 'Result is resolved' );
+ result.then( function ( thumbnailInfo ) {
+ assert.ok( thumbnailInfo.width, 'Width is set' );
+ assert.ok( thumbnailInfo.height, 'Height is set' );
+ assert.strictEqual( thumbnailInfo.url, resultUrl, 'URL is set' );
+ done();
+ } );
+
+ provider.getUrl = function () { return undefined; };
+ result = provider.get( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.ok( result.then, 'Result is a promise' );
+ assert.strictEqual( result.state(), 'rejected', 'Result is rejected' );
+ } );
+
+ QUnit.test( 'getUrl()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Elizabeth_I_George_Gower.jpg' ),
+ originalWidth = 922,
+ originalHeight = 968,
+ width,
+ sampleUrl,
+ expectedUrl,
+ resultUrl;
+
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/7/78/Elizabeth_I_George_Gower.jpg';
+ width = 1000;
+ expectedUrl = 'http://upload.wikimedia.org/wikipedia/commons/7/78/Elizabeth_I_George_Gower.jpg';
+ resultUrl = provider.getUrl( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.strictEqual( resultUrl, expectedUrl, 'Simple case - full image, needs no resize' );
+
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/7/78/Elizabeth_I_George_Gower.jpg/180px-Elizabeth_I_George_Gower.jpg';
+ width = 400;
+ expectedUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/7/78/Elizabeth_I_George_Gower.jpg/400px-Elizabeth_I_George_Gower.jpg';
+ resultUrl = provider.getUrl( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.strictEqual( resultUrl, expectedUrl, 'Mostly simple case - just need to replace size' );
+
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/7/78/Elizabeth_I_George_Gower.jpg';
+ width = 400;
+ expectedUrl = undefined;
+ resultUrl = provider.getUrl( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.strictEqual( resultUrl, expectedUrl, 'We bail on hard case - full to thumbnail' );
+
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/7/78/Elizabeth_I_George_Gower.jpg/180px-Elizabeth_I_George_Gower.jpg';
+ width = 1000;
+ expectedUrl = 'http://upload.wikimedia.org/wikipedia/commons/7/78/Elizabeth_I_George_Gower.jpg';
+ resultUrl = provider.getUrl( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.strictEqual( resultUrl, expectedUrl, 'Thumbnail to full-size, image with limited size' );
+
+ file = new mw.Title( 'File:Ranunculus_gmelinii_NRCS-2.tiff' );
+ sampleUrl = 'https://upload.wikimedia.org/wikipedia/commons/thumb/2/27/Ranunculus_gmelinii_NRCS-2.tiff/lossy-page1-428px-Ranunculus_gmelinii_NRCS-2.tiff.jpg';
+ width = 2000;
+ originalWidth = 1500;
+ originalHeight = 2100;
+ expectedUrl = 'https://upload.wikimedia.org/wikipedia/commons/thumb/2/27/Ranunculus_gmelinii_NRCS-2.tiff/lossy-page1-1500px-Ranunculus_gmelinii_NRCS-2.tiff.jpg';
+ resultUrl = provider.getUrl( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.strictEqual( resultUrl, expectedUrl, 'Thumbnail to full-size, image which cannot be displayed directly' );
+
+ file = new mw.Title( 'File:Copyleft.svg' );
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/180px-Copyleft.svg.png';
+ width = 1000;
+ originalWidth = 512;
+ originalHeight = 512;
+ expectedUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/1000px-Copyleft.svg.png';
+ resultUrl = provider.getUrl( file, sampleUrl, width, originalWidth, originalHeight );
+ assert.strictEqual( resultUrl, expectedUrl, 'Thumbnail to "full-size", image with unlimited size' );
+ } );
+
+ QUnit.test( 'needsOriginal()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.ok( !provider.needsOriginal( file, 100, 1000 ), 'Thumbnail of an SVG smaller than the original size doesn\'t need original' );
+ assert.ok( !provider.needsOriginal( file, 1000, 1000 ), 'Thumbnail of an SVG equal to the original size doesn\'t need original' );
+ assert.ok( !provider.needsOriginal( file, 2000, 1000 ), 'Thumbnail of an SVG bigger than the original size doesn\'t need original' );
+
+ file = new mw.Title( 'File:Foo.png' );
+
+ assert.ok( !provider.needsOriginal( file, 100, 1000 ), 'Thumbnail of a PNG smaller than the original size doesn\'t need original' );
+ assert.ok( provider.needsOriginal( file, 1000, 1000 ), 'Thumbnail of a PNG equal to the original size needs original' );
+ assert.ok( provider.needsOriginal( file, 2000, 1000 ), 'Thumbnail of a PNG bigger than the original size needs original' );
+ } );
+
+ QUnit.test( 'isFullSizeUrl()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.ok( !provider.isFullSizeUrl( 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png', file ),
+ 'Thumbnail url recognized as not being full size' );
+ assert.ok( provider.isFullSizeUrl( 'http://upload.wikimedia.org/wikipedia/commons/8/8b/Copyleft.svg', file ),
+ 'Original url recognized as being full size' );
+ } );
+
+ QUnit.test( 'obscureFilename()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.strictEqual( provider.obscureFilename( 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png', file ),
+ 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/<filename>/300px-<filename>.png', 'Filename correctly obscured' );
+
+ file = new mw.Title( 'File:Hoag\'s_object.jpg' );
+
+ assert.strictEqual( provider.obscureFilename( 'http://upload.wikimedia.org/wikipedia/commons/thumb/d/da/Hoag%27s_object.jpg/180px-Hoag%27s_object.jpg', file ),
+ 'http://upload.wikimedia.org/wikipedia/commons/thumb/d/da/<filename>/180px-<filename>', 'Filename with urlencoded character correctly obscured' );
+ } );
+
+ QUnit.test( 'restoreFilename()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.strictEqual( provider.restoreFilename( 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/<filename>/300px-<filename>.png', file ),
+ 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png', 'Filename correctly restored' );
+
+ } );
+
+ QUnit.test( 'canHaveLargerThumbnailThanOriginal()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.ok( provider.canHaveLargerThumbnailThanOriginal( file ), 'SVG can have a larger thumbnail than the original' );
+
+ file = new mw.Title( 'File:Foo.jpg' );
+
+ assert.ok( !provider.canHaveLargerThumbnailThanOriginal( file ), 'JPG can\'t have a larger thumbnail than the original' );
+
+ file = new mw.Title( 'File:Foo.png' );
+
+ assert.ok( !provider.canHaveLargerThumbnailThanOriginal( file ), 'PNG can\'t have a larger thumbnail than the original' );
+
+ file = new mw.Title( 'File:Foo.jpeg' );
+
+ assert.ok( !provider.canHaveLargerThumbnailThanOriginal( file ), 'JPEG can\'t have a larger thumbnail than the original' );
+
+ file = new mw.Title( 'File:Foo.tiff' );
+
+ assert.ok( !provider.canHaveLargerThumbnailThanOriginal( file ), 'TIFF can\'t have a larger thumbnail than the original' );
+
+ file = new mw.Title( 'File:Foo.gif' );
+
+ assert.ok( !provider.canHaveLargerThumbnailThanOriginal( file ), 'GIF can\'t have a larger thumbnail than the original' );
+ } );
+
+ QUnit.test( 'canBeDisplayedInBrowser()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.ok( !provider.canBeDisplayedInBrowser( file ), 'SVG can\'t be displayed as-is in the browser' );
+
+ file = new mw.Title( 'File:Foo.jpg' );
+
+ assert.ok( provider.canBeDisplayedInBrowser( file ), 'JPG can be displayed as-is in the browser' );
+
+ file = new mw.Title( 'File:Foo.png' );
+
+ assert.ok( provider.canBeDisplayedInBrowser( file ), 'PNG can be displayed as-is in the browser' );
+
+ file = new mw.Title( 'File:Foo.jpeg' );
+
+ assert.ok( provider.canBeDisplayedInBrowser( file ), 'JPEG can be displayed as-is in the browser' );
+
+ file = new mw.Title( 'File:Foo.tiff' );
+
+ assert.ok( !provider.canBeDisplayedInBrowser( file ), 'TIFF can\'t be displayed as-is in the browser' );
+
+ file = new mw.Title( 'File:Foo.gif' );
+
+ assert.ok( provider.canBeDisplayedInBrowser( file ), 'GIF can be displayed as-is in the browser' );
+ } );
+
+ QUnit.test( 'guessWidth()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.strictEqual( provider.guessWidth( file, 100, 1000 ), 100, 'Width correctly guessed for SVG thumbnail smaller than the original' );
+ assert.strictEqual( provider.guessWidth( file, 2000, 1000 ), 2000, 'Width correctly guessed for SVG thumbnail bigger than the original' );
+
+ file = new mw.Title( 'File:Copyleft.jpg' );
+
+ assert.strictEqual( provider.guessWidth( file, 100, 1000 ), 100, 'Width correctly guessed for JPG thumbnail smaller than the original' );
+ assert.strictEqual( provider.guessWidth( file, 2000, 1000 ), 1000, 'Width correctly guessed for JPG thumbnail bigger than the original' );
+ } );
+
+ QUnit.test( 'guessHeight()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.strictEqual( provider.guessHeight( file, 100, 1000, 500 ), 50, 'Height correctly guessed for SVG thumbnail smaller than the original' );
+ assert.strictEqual( provider.guessHeight( file, 2000, 1000, 500 ), 1000, 'Height correctly guessed for SVG thumbnail bigger than the original' );
+
+ file = new mw.Title( 'File:Copyleft.jpg' );
+
+ assert.strictEqual( provider.guessHeight( file, 100, 1000, 500 ), 50, 'Height correctly guessed for JPG thumbnail smaller than the original' );
+ assert.strictEqual( provider.guessHeight( file, 2000, 1000, 500 ), 500, 'Height correctly guessed for JPG thumbnail bigger than the original' );
+ } );
+
+ QUnit.test( 'replaceSize()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' );
+
+ assert.strictEqual( provider.replaceSize( file, 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png', 220 ),
+ 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/220px-Copyleft.svg.png', 'Incorrect size correctly replaced' );
+ assert.strictEqual( provider.replaceSize( file, 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png', 300 ),
+ 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png', 'Identical size correctly left the same' );
+ assert.strictEqual( provider.replaceSize( file, 'http://upload.wikimedia.org/wikipedia/commons/8/8b/Copyleft.svg', 220 ),
+ undefined, 'Returns undefined when it cannot handle the URL' );
+
+ file = new mw.Title( 'File:Copyleft-300px.svg' );
+ assert.strictEqual( provider.replaceSize( file, 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft-300px.svg/300px-Copyleft-300px.svg.png', 220 ),
+ 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft-300px.svg/220px-Copyleft-300px.svg.png', 'Works with strange filename' );
+
+ file = new mw.Title( 'File:Ranunculus_gmelinii_NRCS-2.tiff' );
+ assert.strictEqual( provider.replaceSize( file, 'https://upload.wikimedia.org/wikipedia/commons/thumb/2/27/Ranunculus_gmelinii_NRCS-2.tiff/lossy-page1-428px-Ranunculus_gmelinii_NRCS-2.tiff.jpg', 220 ),
+ 'https://upload.wikimedia.org/wikipedia/commons/thumb/2/27/Ranunculus_gmelinii_NRCS-2.tiff/lossy-page1-220px-Ranunculus_gmelinii_NRCS-2.tiff.jpg', 'Works with extra parameters' );
+ } );
+
+ QUnit.test( 'guessFullUrl()', function ( assert ) {
+ var provider = new mw.mmv.provider.GuessedThumbnailInfo(),
+ file = new mw.Title( 'File:Copyleft.svg' ),
+ fullUrl = 'http://upload.wikimedia.org/wikipedia/commons/8/8b/Copyleft.svg',
+ sampleUrl = 'http://upload.wikimedia.org/wikipedia/commons/thumb/8/8b/Copyleft.svg/300px-Copyleft.svg.png',
+ result;
+
+ result = provider.guessFullUrl( file, sampleUrl );
+
+ assert.strictEqual( result, fullUrl, 'guessFullUrl returns correct full URL for SVG' );
+
+ file = new mw.Title( 'File:அணில்-3-தென்னையின்_வளர்நிலை.jpg' );
+ fullUrl = 'https://upload.wikimedia.org/wikipedia/commons/1/15/%E0%AE%85%E0%AE%A3%E0%AE%BF%E0%AE%B2%E0%AF%8D-3-%E0%AE%A4%E0%AF%86%E0%AE%A9%E0%AF%8D%E0%AE%A9%E0%AF%88%E0%AE%AF%E0%AE%BF%E0%AE%A9%E0%AF%8D_%E0%AE%B5%E0%AE%B3%E0%AE%B0%E0%AF%8D%E0%AE%A8%E0%AE%BF%E0%AE%B2%E0%AF%88.jpg';
+ sampleUrl = 'https://upload.wikimedia.org/wikipedia/commons/thumb/1/15/%E0%AE%85%E0%AE%A3%E0%AE%BF%E0%AE%B2%E0%AF%8D-3-%E0%AE%A4%E0%AF%86%E0%AE%A9%E0%AF%8D%E0%AE%A9%E0%AF%88%E0%AE%AF%E0%AE%BF%E0%AE%A9%E0%AF%8D_%E0%AE%B5%E0%AE%B3%E0%AE%B0%E0%AF%8D%E0%AE%A8%E0%AE%BF%E0%AE%B2%E0%AF%88.jpg/800px-%E0%AE%85%E0%AE%A3%E0%AE%BF%E0%AE%B2%E0%AF%8D-3-%E0%AE%A4%E0%AF%86%E0%AE%A9%E0%AF%8D%E0%AE%A9%E0%AF%88%E0%AE%AF%E0%AE%BF%E0%AE%A9%E0%AF%8D_%E0%AE%B5%E0%AE%B3%E0%AE%B0%E0%AF%8D%E0%AE%A8%E0%AE%BF%E0%AE%B2%E0%AF%88.jpg';
+
+ result = provider.guessFullUrl( file, sampleUrl );
+
+ assert.strictEqual( result, fullUrl, 'guessFullUrl returns correct full URL for JPG with unicode name' );
+
+ file = new mw.Title( 'File:அணில்-3-தென்னையின்_வளர்நிலை.jpg' );
+ sampleUrl = 'https://upload.wikimedia.org/wikipedia/commons/thumb/1/15/அணில்-3-தென்னையின்_வளர்நிலை.jpg/800px-அணில்-3-தென்னையின்_வளர்நிலை.jpg';
+
+ result = provider.guessFullUrl( file, sampleUrl );
+
+ assert.strictEqual( result, undefined, 'guessFullUrl bails out when URL encoding is not as expected' );
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Image.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Image.test.js
new file mode 100644
index 00000000..76b84afe
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.Image.test.js
@@ -0,0 +1,200 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.provider.Image', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Image constructor sanity check', function ( assert ) {
+ var imageProvider = new mw.mmv.provider.Image();
+
+ assert.ok( imageProvider );
+ } );
+
+ QUnit.test( 'Image load success', function ( assert ) {
+ var url = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0' +
+ 'iAAAABlBMVEUAAAD///+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH' +
+ '8yw83NDDeNGe4Ug9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC',
+ imageProvider = new mw.mmv.provider.Image();
+
+ imageProvider.imagePreloadingSupported = function () { return false; };
+ imageProvider.performance.recordEntry = $.noop;
+
+ return imageProvider.get( url ).then( function ( image ) {
+ assert.ok( image instanceof HTMLImageElement,
+ 'success handler was called with the image element' );
+ assert.strictEqual( image.src, url, 'image src is correct' );
+ } );
+ } );
+
+ QUnit.test( 'Image caching', function ( assert ) {
+ var url = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0' +
+ 'iAAAABlBMVEUAAAD///+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH' +
+ '8yw83NDDeNGe4Ug9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC',
+ url2 = 'data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==',
+ result,
+ imageProvider = new mw.mmv.provider.Image();
+
+ imageProvider.imagePreloadingSupported = function () { return false; };
+ imageProvider.performance.recordEntry = $.noop;
+
+ return QUnit.whenPromisesComplete(
+ imageProvider.get( url ).then( function ( image ) {
+ result = image;
+ assert.ok( image instanceof HTMLImageElement,
+ 'success handler was called with the image element' );
+ assert.strictEqual( image.src, url, 'image src is correct' );
+ } ),
+
+ imageProvider.get( url ).then( function ( image ) {
+ assert.strictEqual( image, result, 'image element is cached and not regenerated' );
+ assert.strictEqual( image.src, url, 'image src is correct' );
+ } ),
+
+ imageProvider.get( url2 ).then( function ( image ) {
+ assert.notStrictEqual( image, result, 'image element for different url is not cached' );
+ assert.strictEqual( image.src, url2, 'image src is correct' );
+ } )
+ );
+ } );
+
+ QUnit.test( 'Image load XHR progress funneling', function ( assert ) {
+ var i = 0,
+ imageProvider = new mw.mmv.provider.Image(),
+ oldPerformance = imageProvider.performance,
+ fakeURL = 'fakeURL',
+ response = 'response',
+ done1 = assert.async(),
+ done2 = assert.async();
+
+ imageProvider.performance.delay = 0;
+ imageProvider.imagePreloadingSupported = function () { return true; };
+ imageProvider.rawGet = function () { return $.Deferred().resolve(); };
+
+ imageProvider.performance.newXHR = function () {
+ return { readyState: 4,
+ response: response,
+ send: function () {
+ var self = this;
+
+ // The timeout is necessary because without it notify() happens before
+ // the imageProvider has time to chain its progress() to the returned deferred
+ setTimeout( function () {
+ self.onprogress( { lengthComputable: true, loaded: 10, total: 20 } );
+ self.onreadystatechange();
+ } );
+ },
+
+ open: $.noop };
+ };
+
+ imageProvider.performance.recordEntry = function ( type, total, url ) {
+ assert.strictEqual( type, 'image', 'Type matches' );
+ assert.strictEqual( url, fakeURL, 'URL matches' );
+ done1();
+
+ imageProvider.performance = oldPerformance;
+
+ return $.Deferred().resolve();
+ };
+
+ imageProvider.get( fakeURL )
+ .fail( function () {
+ assert.ok( false, 'Image failed to (pretend to) load' );
+ done2();
+ } )
+ .then( function () {
+ assert.ok( true, 'Image was pretend-loaded' );
+ done2();
+ } )
+ .progress( function ( response, percent ) {
+ if ( i === 0 ) {
+ assert.strictEqual( percent, 50, 'Correctly propagated a 50% progress event' );
+ assert.strictEqual( response, response, 'Partial response propagated' );
+ } else if ( i === 1 ) {
+ assert.strictEqual( percent, 100, 'Correctly propagated a 100% progress event' );
+ assert.strictEqual( response, response, 'Partial response propagated' );
+ } else {
+ assert.ok( false, 'Only 2 progress events should propagate' );
+ }
+
+ i++;
+ } );
+ } );
+
+ QUnit.test( 'Image load fail', function ( assert ) {
+ var imageProvider = new mw.mmv.provider.Image(),
+ oldMwLog = mw.log,
+ done = assert.async(),
+ mwLogCalled = false;
+
+ imageProvider.imagePreloadingSupported = function () { return false; };
+ imageProvider.performance.recordEntry = $.noop;
+ mw.log = function () { mwLogCalled = true; };
+
+ imageProvider.get( 'doesntexist.png' ).fail( function () {
+ assert.ok( true, 'fail handler was called' );
+ assert.ok( mwLogCalled, 'mw.log was called' );
+ mw.log = oldMwLog;
+ done();
+ } );
+ } );
+
+ QUnit.test( 'Image load with preloading supported', function ( assert ) {
+ var url = mw.config.get( 'wgExtensionAssetsPath' ) + '/MultimediaViewer/resources/mmv/img/expand.svg',
+ imageProvider = new mw.mmv.provider.Image(),
+ endsWith = function ( a, b ) { return a.indexOf( b ) === a.length - b.length; };
+
+ imageProvider.imagePreloadingSupported = function () { return true; };
+ imageProvider.performance = {
+ record: function () { return $.Deferred().resolve(); }
+ };
+
+ return imageProvider.get( url ).then( function ( image ) {
+ // can't test equality as browsers transform this to a full URL
+ assert.ok( endsWith( image.src, url ), 'local image loaded with correct source' );
+ } );
+ } );
+
+ QUnit.test( 'Failed image load with preloading supported', function ( assert ) {
+ var url = 'nosuchimage.png',
+ imageProvider = new mw.mmv.provider.Image(),
+ done = assert.async();
+
+ imageProvider.imagePreloadingSupported = function () { return true; };
+ imageProvider.performance = {
+ record: function () { return $.Deferred().resolve(); }
+ };
+
+ imageProvider.get( url ).fail( function () {
+ assert.ok( true, 'Fail callback called for non-existing image' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'imageQueryParameter', function ( assert ) {
+ var imageProvider = new mw.mmv.provider.Image( 'foo' );
+
+ imageProvider.imagePreloadingSupported = function () { return false; };
+ imageProvider.rawGet = function () { return $.Deferred().resolve(); };
+
+ imageProvider.performance.recordEntry = function ( type, total, url ) {
+ assert.strictEqual( url, 'http://www.wikipedia.org/?foo', 'Extra parameter added' );
+ };
+
+ imageProvider.get( 'http://www.wikipedia.org/' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ImageInfo.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ImageInfo.test.js
new file mode 100644
index 00000000..3daaac12
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ImageInfo.test.js
@@ -0,0 +1,241 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.provider.ImageInfo', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'ImageInfo constructor sanity check', function ( assert ) {
+ var api = { get: function () {} },
+ imageInfoProvider = new mw.mmv.provider.ImageInfo( api );
+
+ assert.ok( imageInfoProvider );
+ } );
+
+ QUnit.test( 'ImageInfo get test', function ( assert ) {
+ var apiCallCount = 0,
+ api = { get: function () {
+ apiCallCount++;
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ ns: 6,
+ title: 'File:Stuff.jpg',
+ missing: '',
+ imagerepository: 'shared',
+ imageinfo: [
+ {
+ timestamp: '2013-08-25T14:41:02Z',
+ userid: '3053121',
+ size: 346684,
+ width: 720,
+ height: 1412,
+ comment: 'User created page with UploadWizard',
+ url: 'https://upload.wikimedia.org/wikipedia/commons/1/19/Stuff.jpg',
+ descriptionurl: 'https://commons.wikimedia.org/wiki/File:Stuff.jpg',
+ sha1: 'a1ba23d471f4dad208b71c143e2e105a0e3032db',
+ metadata: [],
+ extmetadata: {
+ ObjectName: {
+ value: 'Some stuff',
+ source: 'commons-templates'
+ },
+ License: {
+ value: 'cc0',
+ source: 'commons-templates',
+ hidden: ''
+ },
+ LicenseShortName: {
+ value: 'CC0',
+ source: 'commons-templates'
+ },
+ UsageTerms: {
+ value: 'Creative Commons Public Domain Dedication',
+ source: 'commons-templates'
+ },
+ LicenseUrl: {
+ value: 'http://creativecommons.org/publicdomain/zero/1.0/',
+ source: 'commons-templates'
+ },
+ GPSLatitude: {
+ value: '90.000000',
+ source: 'commons-desc-page'
+ },
+ GPSLongitude: {
+ value: ' 180.000000',
+ source: 'commons-desc-page'
+ },
+ ImageDescription: {
+ value: 'Wikis stuff',
+ source: 'commons-desc-page'
+ },
+ DateTimeOriginal: {
+ value: '<time class="dtstart" datetime="2009-02-18">18 February 2009</time>\u00a0(according to <a href="//en.wikipedia.org/wiki/Exchangeable_image_file_format" class="extiw" title="en:Exchangeable image file format">EXIF</a> data)',
+ source: 'commons-desc-page'
+ },
+ DateTime: {
+ value: '2013-08-25T14:41:02Z',
+ source: 'commons-desc-page'
+ },
+ Credit: {
+ value: 'Wikipedia',
+ source: 'commons-desc-page',
+ hidden: ''
+ },
+ Artist: {
+ value: 'John Smith',
+ source: 'commons-desc-page'
+ },
+ AuthorCount: {
+ value: '2',
+ source: 'commons-desc-page'
+ },
+ Attribution: {
+ value: 'By John Smith',
+ source: 'commons-desc-page'
+ },
+ Permission: {
+ value: 'Do not use. Ever.',
+ source: 'commons-desc-page'
+ },
+ AttributionRequired: {
+ value: 'no',
+ source: 'commons-desc-page'
+ },
+ NonFree: {
+ value: 'yes',
+ source: 'commons-desc-page'
+ },
+ Restrictions: {
+ value: 'trademarked|insignia',
+ source: 'commons-desc-page'
+ },
+ DeletionReason: {
+ value: 'copyvio',
+ source: 'commons-desc-page'
+ }
+ },
+ mime: 'image/jpeg',
+ mediatype: 'BITMAP'
+ }
+ ]
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ imageInfoProvider = new mw.mmv.provider.ImageInfo( api );
+
+ return imageInfoProvider.get( file ).then( function ( image ) {
+ assert.strictEqual( image.title.getPrefixedDb(), 'File:Stuff.jpg', 'title is set correctly' );
+ assert.strictEqual( image.name, 'Some stuff', 'name is set correctly' );
+ assert.strictEqual( image.size, 346684, 'size is set correctly' );
+ assert.strictEqual( image.width, 720, 'width is set correctly' );
+ assert.strictEqual( image.height, 1412, 'height is set correctly' );
+ assert.strictEqual( image.mimeType, 'image/jpeg', 'mimeType is set correctly' );
+ assert.strictEqual( image.url, 'https://upload.wikimedia.org/wikipedia/commons/1/19/Stuff.jpg', 'url is set correctly' );
+ assert.strictEqual( image.descriptionUrl, 'https://commons.wikimedia.org/wiki/File:Stuff.jpg', 'descriptionUrl is set correctly' );
+ assert.strictEqual( image.repo, 'shared', 'repo is set correctly' );
+ assert.strictEqual( image.uploadDateTime, '2013-08-25T14:41:02Z', 'uploadDateTime is set correctly' );
+ assert.strictEqual( image.anonymizedUploadDateTime, '20130825000000', 'anonymizedUploadDateTime is set correctly' );
+ assert.strictEqual( image.creationDateTime, '18 February 2009\u00a0(according to EXIF data)', 'creationDateTime is set correctly' );
+ assert.strictEqual( image.description, 'Wikis stuff', 'description is set correctly' );
+ assert.strictEqual( image.source, 'Wikipedia', 'source is set correctly' );
+ assert.strictEqual( image.author, 'John Smith', 'author is set correctly' );
+ assert.strictEqual( image.authorCount, 2, 'author count is set correctly' );
+ assert.strictEqual( image.attribution, 'By John Smith', 'attribution is set correctly' );
+ assert.strictEqual( image.license.shortName, 'CC0', 'license short name is set correctly' );
+ assert.strictEqual( image.license.internalName, 'cc0', 'license internal name is set correctly' );
+ assert.strictEqual( image.license.longName, 'Creative Commons Public Domain Dedication', 'license long name is set correctly' );
+ assert.strictEqual( image.license.deedUrl, 'http://creativecommons.org/publicdomain/zero/1.0/', 'license URL is set correctly' );
+ assert.strictEqual( image.license.attributionRequired, false, 'Attribution required flag is honored' );
+ assert.strictEqual( image.license.nonFree, true, 'Non-free flag is honored' );
+ assert.strictEqual( image.permission, 'Do not use. Ever.', 'permission is set correctly' );
+ assert.strictEqual( image.deletionReason, 'copyvio', 'permission is set correctly' );
+ assert.strictEqual( image.latitude, 90, 'latitude is set correctly' );
+ assert.strictEqual( image.longitude, 180, 'longitude is set correctly' );
+ assert.deepEqual( image.restrictions, [ 'trademarked', 'insignia' ], 'restrictions is set correctly' );
+ } ).then( function () {
+ // call the data provider a second time to check caching
+ return imageInfoProvider.get( file );
+ } ).then( function () {
+ assert.strictEqual( apiCallCount, 1 );
+ } );
+ } );
+
+ QUnit.test( 'ImageInfo fail test', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {} );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ imageInfoProvider = new mw.mmv.provider.ImageInfo( api );
+
+ imageInfoProvider.get( file ).fail( function () {
+ assert.ok( true, 'promise rejected when no data is returned' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'ImageInfo fail test 2', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ title: 'File:Stuff.jpg'
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ imageInfoProvider = new mw.mmv.provider.ImageInfo( api );
+
+ imageInfoProvider.get( file ).fail( function () {
+ assert.ok( true, 'promise rejected when imageinfo is missing' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'ImageInfo missing page test', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ title: 'File:Stuff.jpg',
+ missing: '',
+ imagerepository: ''
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ imageInfoProvider = new mw.mmv.provider.ImageInfo( api );
+
+ imageInfoProvider.get( file ).fail( function ( errorMessage ) {
+ assert.strictEqual( errorMessage, 'file does not exist: File:Stuff.jpg',
+ 'error message is set correctly for missing file' );
+ done();
+ } );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ThumbnailInfo.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ThumbnailInfo.test.js
new file mode 100644
index 00000000..19a18e6a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/provider/mmv.provider.ThumbnailInfo.test.js
@@ -0,0 +1,165 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.provider.ThumbnailInfo', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'ThumbnailInfo constructor sanity check', function ( assert ) {
+ var api = { get: function () {} },
+ thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( api );
+
+ assert.ok( thumbnailInfoProvider );
+ } );
+
+ QUnit.test( 'ThumbnailInfo get test', function ( assert ) {
+ var apiCallCount = 0,
+ api = { get: function () {
+ apiCallCount++;
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ ns: 6,
+ title: 'File:Stuff.jpg',
+ missing: '',
+ imagerepository: 'shared',
+ imageinfo: [
+ {
+ thumburl: 'https://upload.wikimedia.org/wikipedia/commons/thumb/1/19/Stuff.jpg/51px-Stuff.jpg',
+ thumbwidth: 95,
+ thumbheight: 200,
+ url: 'https://upload.wikimedia.org/wikipedia/commons/1/19/Stuff.jpg',
+ descriptionurl: 'https://commons.wikimedia.org/wiki/File:Stuff.jpg'
+ }
+ ]
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( api );
+
+ return thumbnailInfoProvider.get( file, 100 ).then( function ( thumbnail ) {
+ assert.strictEqual( thumbnail.url,
+ 'https://upload.wikimedia.org/wikipedia/commons/thumb/1/19/Stuff.jpg/51px-Stuff.jpg',
+ 'URL is set correctly' );
+ assert.strictEqual( thumbnail.width, 95, 'actual width is set correctly' );
+ assert.strictEqual( thumbnail.height, 200, 'actual height is set correctly' );
+ } ).then( function () {
+ assert.strictEqual( apiCallCount, 1 );
+ // call the data provider a second time to check caching
+ return thumbnailInfoProvider.get( file, 100 );
+ } ).then( function () {
+ assert.strictEqual( apiCallCount, 1 );
+ // call a third time with different size to check caching
+ return thumbnailInfoProvider.get( file, 110 );
+ } ).then( function () {
+ assert.strictEqual( apiCallCount, 2 );
+ // call it again, with a height specified, to check caching
+ return thumbnailInfoProvider.get( file, 110, 100 );
+ } ).then( function () {
+ assert.strictEqual( apiCallCount, 3 );
+ } );
+ } );
+
+ QUnit.test( 'ThumbnailInfo fail test', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {} );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( api );
+
+ thumbnailInfoProvider.get( file, 100 ).fail( function () {
+ assert.ok( true, 'promise rejected when no data is returned' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'ThumbnailInfo fail test 2', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ title: 'File:Stuff.jpg'
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( api );
+
+ thumbnailInfoProvider.get( file, 100 ).fail( function () {
+ assert.ok( true, 'promise rejected when imageinfo is missing' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'ThumbnailInfo missing page test', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ title: 'File:Stuff.jpg',
+ missing: '',
+ imagerepository: ''
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( api );
+
+ thumbnailInfoProvider.get( file ).fail( function ( errorMessage ) {
+ assert.strictEqual( errorMessage, 'file does not exist: File:Stuff.jpg',
+ 'error message is set correctly for missing file' );
+ done();
+ } );
+ } );
+
+ QUnit.test( 'ThumbnailInfo fail test 3', function ( assert ) {
+ var api = { get: function () {
+ return $.Deferred().resolve( {
+ query: {
+ pages: {
+ '-1': {
+ title: 'File:Stuff.jpg',
+ imageinfo: [
+ {}
+ ]
+ }
+ }
+ }
+ } );
+ } },
+ file = new mw.Title( 'File:Stuff.jpg' ),
+ done = assert.async(),
+ thumbnailInfoProvider = new mw.mmv.provider.ThumbnailInfo( api );
+
+ thumbnailInfoProvider.get( file, 100 ).fail( function () {
+ assert.ok( true, 'promise rejected when thumbnail info is missing' );
+ done();
+ } );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.MainFileRoute.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.MainFileRoute.test.js
new file mode 100644
index 00000000..49fcff6a
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.MainFileRoute.test.js
@@ -0,0 +1,24 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.routing.MainFileRoute', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity checks', function ( assert ) {
+ assert.ok( new mw.mmv.routing.MainFileRoute(), 'MainFileRoute created successfully' );
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.Router.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.Router.test.js
new file mode 100644
index 00000000..3da76de5
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.Router.test.js
@@ -0,0 +1,232 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.routing.Router', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity checks', function ( assert ) {
+ var router;
+
+ router = new mw.mmv.routing.Router();
+ assert.ok( router, 'Router created successfully' );
+ } );
+
+ QUnit.test( 'isMediaViewerHash()', function ( assert ) {
+ var router = new mw.mmv.routing.Router();
+
+ assert.ok( router.isMediaViewerHash( 'mediaviewer/foo' ), 'Legacy hash' );
+ assert.ok( router.isMediaViewerHash( '#mediaviewer/foo' ), 'Legacy hash with #' );
+ assert.ok( router.isMediaViewerHash( 'mediaviewer' ), 'Bare legacy hash' );
+ assert.ok( router.isMediaViewerHash( '#mediaviewer' ), 'Bare legacy hash with #' );
+ assert.ok( router.isMediaViewerHash( '/media/foo' ), 'Normal hash' );
+ assert.ok( router.isMediaViewerHash( '#/media/foo' ), 'Normal hash with #' );
+ assert.ok( router.isMediaViewerHash( '/media' ), 'Bare hash' );
+ assert.ok( router.isMediaViewerHash( '#/media' ), 'Bare hash with #' );
+ assert.ok( !router.isMediaViewerHash( 'foo/media' ), 'Foreign hash' );
+ assert.ok( !router.isMediaViewerHash( '' ), 'Empty hash' );
+ } );
+
+ QUnit.test( 'createHash()/parseHash()', function ( assert ) {
+ var route, parsedRoute, hash, title,
+ router = new mw.mmv.routing.Router();
+
+ route = new mw.mmv.routing.MainFileRoute();
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.deepEqual( parsedRoute, route, 'Bare hash' );
+
+ title = new mw.Title( 'File:Foo.png' );
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Normal hash' );
+ assert.ok( hash.match( /File:Foo.png/ ), 'Simple filenames remain readable' );
+
+ title = new mw.Title( 'File:Foo.png' );
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ assert.notEqual( hash[ 0 ], '#', 'Leading # is not included in the returned hash' );
+ parsedRoute = router.parseHash( '#' + hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Leading # is accepted when parsing a hash' );
+
+ title = new mw.Title( 'File:Foo.png' );
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Normal hash' );
+ assert.ok( hash.match( /File:Foo.png/ ), 'Simple filenames remain readable' );
+
+ title = new mw.Title( 'File:Foo/bar.png' );
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Filename with /' );
+ assert.ok( !hash.match( 'Foo/bar' ), '/ is encoded' );
+
+ title = new mw.Title( 'File:Foo bar.png' );
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Filename with space' );
+ assert.ok( !hash.match( 'Foo bar' ), 'space is replaced...' );
+ assert.ok( hash.match( 'Foo_bar' ), '...with underscore' );
+
+ title = new mw.Title( 'File:看門狗 (遊戲).jpg' );
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Unicode filename' );
+
+ title = new mw.Title( 'File:%!"$&\'()*,-./:;=?@\\^_`~+.jpg' );
+ if ( title ) {
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ hash = router.createHash( route );
+ parsedRoute = router.parseHash( hash );
+ assert.strictEqual( parsedRoute.fileTitle.getPrefixedDb(),
+ title.getPrefixedDb(), 'Special characters' );
+ } else {
+ // mw.Title depends on $wgLegalTitleChars - do not fail test if it is non-standard
+ assert.ok( true, 'Skipped' );
+ }
+ } );
+
+ QUnit.test( 'createHash() error handling', function ( assert ) {
+ var router = new mw.mmv.routing.Router();
+
+ assert.ok( mw.mmv.testHelpers.getException( function () { return new mw.mmv.routing.ThumbnailRoute(); } ),
+ 'Exception thrown then ThumbnailRoute has no title' );
+ assert.ok( mw.mmv.testHelpers.getException( function () {
+ router.createHash( this.sandbox.createStubInstance( mw.mmv.routing.Route ) );
+ } ), 'Exception thrown for unknown Route subclass' );
+ assert.ok( mw.mmv.testHelpers.getException( function () {
+ router.createHash( {} );
+ } ), 'Exception thrown for non-Route class' );
+ } );
+
+ QUnit.test( 'parseHash() with invalid hashes', function ( assert ) {
+ var router = new mw.mmv.routing.Router();
+
+ assert.ok( !router.parseHash( 'foo' ), 'Non-MMV hash is rejected.' );
+ assert.ok( !router.parseHash( '#foo' ), 'Non-MMV hash is rejected (with #).' );
+ assert.ok( !router.parseHash( '/media/foo/bar' ), 'Invalid MMV hash is rejected.' );
+ assert.ok( !router.parseHash( '#/media/foo/bar' ), 'Invalid MMV hash is rejected (with #).' );
+ } );
+
+ QUnit.test( 'parseHash() backwards compatibility', function ( assert ) {
+ var route,
+ router = new mw.mmv.routing.Router();
+
+ route = router.parseHash( '#mediaviewer/File:Foo bar.png' );
+ assert.strictEqual( route.fileTitle.getPrefixedDb(), 'File:Foo_bar.png',
+ 'Old urls (with space) are handled' );
+
+ route = router.parseHash( '#mediaviewer/File:Mexican \'Alien\' Piñata.jpg' );
+ assert.strictEqual( route.fileTitle.getPrefixedDb(), 'File:Mexican_\'Alien\'_Piñata.jpg',
+ 'Old urls (without percent-encoding) are handled' );
+ } );
+
+ QUnit.test( 'createHashedUrl()', function ( assert ) {
+ var url,
+ route = new mw.mmv.routing.MainFileRoute(),
+ router = new mw.mmv.routing.Router();
+
+ url = router.createHashedUrl( route, 'http://example.com/' );
+ assert.strictEqual( url, 'http://example.com/#/media', 'Url generation works' );
+
+ url = router.createHashedUrl( route, 'http://example.com/#foo' );
+ assert.strictEqual( url, 'http://example.com/#/media', 'Urls with fragments are handled' );
+ } );
+
+ QUnit.test( 'parseLocation()', function ( assert ) {
+ var location, route,
+ router = new mw.mmv.routing.Router();
+
+ location = { href: 'http://example.com/foo#mediaviewer/File:Foo.png' };
+ route = router.parseLocation( location );
+ assert.strictEqual( route.fileTitle.getPrefixedDb(), 'File:Foo.png', 'Reading location works' );
+
+ location = { href: 'http://example.com/foo#/media/File:Foo.png' };
+ route = router.parseLocation( location );
+ assert.strictEqual( route.fileTitle.getPrefixedDb(), 'File:Foo.png', 'Reading location works' );
+
+ location = { href: 'http://example.com/foo' };
+ route = router.parseLocation( location );
+ assert.ok( !route, 'Reading location without fragment part works' );
+ } );
+
+ QUnit.test( 'parseLocation() with real location', function ( assert ) {
+ var route, title, hash,
+ router = new mw.mmv.routing.Router();
+
+ // mw.Title does not accept % in page names
+ this.sandbox.stub( mw, 'Title', function ( name ) {
+ return {
+ name: name,
+ getMain: function () { return name.replace( /^File:/, '' ); }
+ };
+ } );
+ title = new mw.Title( 'File:%40.png' );
+ hash = router.createHash( new mw.mmv.routing.ThumbnailRoute( title ) );
+
+ window.location.hash = hash;
+ route = router.parseLocation( window.location );
+ assert.strictEqual( route.fileTitle.getMain(), '%40.png',
+ 'Reading location set via location.hash works' );
+
+ if ( window.history ) {
+ window.history.pushState( null, null, '#' + hash );
+ route = router.parseLocation( window.location );
+ assert.strictEqual( route.fileTitle.getMain(), '%40.png',
+ 'Reading location set via pushState() works' );
+ } else {
+ assert.ok( true, 'Skipped pushState() test, not supported on this browser' );
+ }
+
+ // reset location, might interfere with other tests
+ window.location.hash = '#';
+ } );
+
+ QUnit.test( 'tokenizeHash()', function ( assert ) {
+ var router = new mw.mmv.routing.Router();
+
+ router.legacyPrefix = 'legacy';
+ router.applicationPrefix = 'prefix';
+
+ assert.deepEqual( router.tokenizeHash( '#foo/bar' ), [], 'No known prefix' );
+
+ assert.deepEqual( router.tokenizeHash( '#prefix' ), [ 'prefix' ], 'Current prefix, with #' );
+ assert.deepEqual( router.tokenizeHash( 'prefix' ), [ 'prefix' ], 'Current prefix, without #' );
+ assert.deepEqual( router.tokenizeHash( '#prefix/bar' ), [ 'prefix', 'bar' ], 'Current prefix, with # and element' );
+ assert.deepEqual( router.tokenizeHash( 'prefix/bar' ), [ 'prefix', 'bar' ], 'Current prefix, with element without #' );
+ assert.deepEqual( router.tokenizeHash( '#prefix/bar/baz' ), [ 'prefix', 'bar', 'baz' ], 'Current prefix, with # and 2 elements' );
+ assert.deepEqual( router.tokenizeHash( 'prefix/bar/baz' ), [ 'prefix', 'bar', 'baz' ], 'Current prefix, with 2 elements without #' );
+
+ assert.deepEqual( router.tokenizeHash( '#legacy' ), [ 'legacy' ], 'Legacy prefix, with #' );
+ assert.deepEqual( router.tokenizeHash( 'legacy' ), [ 'legacy' ], 'Legacy prefix, without #' );
+ assert.deepEqual( router.tokenizeHash( '#legacy/bar' ), [ 'legacy', 'bar' ], 'Legacy prefix, with # and element' );
+ assert.deepEqual( router.tokenizeHash( 'legacy/bar' ), [ 'legacy', 'bar' ], 'Legacy prefix, with element without #' );
+ assert.deepEqual( router.tokenizeHash( '#legacy/bar/baz' ), [ 'legacy', 'bar', 'baz' ], 'Legacy prefix, with # and 2 elements' );
+ assert.deepEqual( router.tokenizeHash( 'legacy/bar/baz' ), [ 'legacy', 'bar', 'baz' ], 'Legacy prefix, with 2 elements without #' );
+
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.ThumbnailRoute.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.ThumbnailRoute.test.js
new file mode 100644
index 00000000..0336a628
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/routing/mmv.routing.ThumbnailRoute.test.js
@@ -0,0 +1,32 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw ) {
+ QUnit.module( 'mmv.routing.ThumbnailRoute', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity checks', function ( assert ) {
+ var route,
+ title = new mw.Title( 'File:Foo.png' );
+
+ route = new mw.mmv.routing.ThumbnailRoute( title );
+ assert.ok( route, 'ThumbnailRoute created successfully' );
+
+ assert.ok( mw.mmv.testHelpers.getException( function () {
+ return new mw.mmv.routing.ThumbnailRoute();
+ } ), 'Exception is thrown when ThumbnailRoute is created without arguments' );
+ } );
+}( mediaWiki ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvas.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvas.test.js
new file mode 100644
index 00000000..88c74bdb
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvas.test.js
@@ -0,0 +1,287 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.Canvas', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity check', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ canvas = new mw.mmv.ui.Canvas( $qf, $qf, $qf );
+
+ assert.ok( canvas.$imageDiv, 'Image container is created.' );
+ assert.strictEqual( canvas.$imageWrapper, $qf, '$imageWrapper is set correctly.' );
+ assert.strictEqual( canvas.$mainWrapper, $qf, '$mainWrapper is set correctly.' );
+ } );
+
+ QUnit.test( 'empty() and set()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ canvas = new mw.mmv.ui.Canvas( $qf ),
+ image = new Image(),
+ $imageElem = $( image ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.png' );
+
+ canvas.empty();
+
+ assert.strictEqual( canvas.$imageDiv.html(), '', 'Canvas is empty.' );
+ assert.ok( canvas.$imageDiv.hasClass( 'empty' ), 'Canvas is not visible.' );
+
+ canvas.set( imageRawMetadata, $imageElem );
+
+ assert.strictEqual( canvas.$image, $imageElem, 'Image element set correctly.' );
+ assert.strictEqual( canvas.imageRawMetadata, imageRawMetadata, 'Raw metadata set correctly.' );
+ assert.strictEqual( canvas.$imageDiv.html(), '<img>', 'Image added to container.' );
+ assert.ok( !canvas.$imageDiv.hasClass( 'empty' ), 'Canvas is visible.' );
+
+ canvas.empty();
+
+ assert.strictEqual( canvas.$imageDiv.html(), '', 'Canvas is empty.' );
+ assert.ok( canvas.$imageDiv.hasClass( 'empty' ), 'Canvas is not visible.' );
+ } );
+
+ QUnit.test( 'setImageAndMaxDimensions()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $mainWrapper = $( '<div>' ).appendTo( $qf ),
+ $innerWrapper = $( '<div>' ).appendTo( $mainWrapper ),
+ $imageWrapper = $( '<div>' ).appendTo( $innerWrapper ),
+ canvas = new mw.mmv.ui.Canvas( $innerWrapper, $imageWrapper, $mainWrapper ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.png' ),
+ image = new Image(),
+ $imageElem = $( image ),
+ image2 = new Image(),
+ thumbnailWidth = 10,
+ screenWidth = 100,
+ $currentImage,
+ originalWidth;
+
+ // Need to call set() before using setImageAndMaxDimensions()
+ canvas.set( imageRawMetadata, $imageElem );
+ originalWidth = image.width;
+
+ // Call with the same image
+ canvas.setImageAndMaxDimensions(
+ { width: thumbnailWidth },
+ image,
+ { cssWidth: screenWidth }
+ );
+
+ assert.strictEqual( image.width, originalWidth, 'Image width was not modified.' );
+ assert.strictEqual( canvas.$image, $imageElem, 'Image element still set correctly.' );
+
+ $currentImage = canvas.$image;
+
+ // Call with a new image bigger than screen size
+ thumbnailWidth = 150;
+ canvas.setImageAndMaxDimensions(
+ { width: thumbnailWidth },
+ image2,
+ { cssWidth: screenWidth }
+ );
+
+ assert.strictEqual( image2.width, screenWidth, 'Image width was trimmed correctly.' );
+ assert.notStrictEqual( canvas.$image, $currentImage, 'Image element switched correctly.' );
+ } );
+
+ QUnit.test( 'maybeDisplayPlaceholder: Constrained area for SVG files', function ( assert ) {
+ var $image,
+ blurredThumbnailShown,
+ $qf = $( '#qunit-fixture' ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.svg' ),
+ canvas = new mw.mmv.ui.Canvas( $qf );
+
+ imageRawMetadata.filePageTitle = {
+ getExtension: function () { return 'svg'; }
+ };
+ canvas.imageRawMetadata = imageRawMetadata;
+
+ canvas.set = function () {
+ assert.ok( false, 'Placeholder is not shown' );
+ };
+
+ $image = $( '<img>' ).width( 10 ).height( 5 );
+
+ blurredThumbnailShown = canvas.maybeDisplayPlaceholder(
+ { width: 200, height: 100 },
+ $image,
+ { cssWidth: 300, cssHeight: 150 }
+ );
+
+ assert.strictEqual( $image.width(), 10, 'Placeholder width was not set to max' );
+ assert.strictEqual( $image.height(), 5, 'Placeholder height was not set to max' );
+ assert.ok( !$image.hasClass( 'blurred' ), 'Placeholder is not blurred' );
+ assert.ok( !blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'maybeDisplayPlaceholder: placeholder big enough that it doesn\'t need blurring, actual image bigger than the lightbox', function ( assert ) {
+ var $image,
+ blurredThumbnailShown,
+ $qf = $( '#qunit-fixture' ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.png' ),
+ canvas = new mw.mmv.ui.Canvas( $qf );
+
+ imageRawMetadata.filePageTitle = {
+ getExtension: function () { return 'png'; }
+ };
+ canvas.imageRawMetadata = imageRawMetadata;
+
+ canvas.set = function () {
+ assert.ok( true, 'Placeholder shown' );
+ };
+
+ $image = $( '<img>' ).width( 200 ).height( 100 );
+
+ blurredThumbnailShown = canvas.maybeDisplayPlaceholder(
+ { width: 1000, height: 500 },
+ $image,
+ { cssWidth: 300, cssHeight: 150 }
+ );
+
+ assert.strictEqual( $image.width(), 300, 'Placeholder has the right width' );
+ assert.strictEqual( $image.height(), 150, 'Placeholder has the right height' );
+ assert.ok( !$image.hasClass( 'blurred' ), 'Placeholder is not blurred' );
+ assert.ok( !blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'maybeDisplayPlaceholder: big-enough placeholder that needs blurring, actual image bigger than the lightbox', function ( assert ) {
+ var $image,
+ blurredThumbnailShown,
+ $qf = $( '#qunit-fixture' ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.png' ),
+ canvas = new mw.mmv.ui.Canvas( $qf );
+
+ imageRawMetadata.filePageTitle = {
+ getExtension: function () { return 'png'; }
+ };
+ canvas.imageRawMetadata = imageRawMetadata;
+
+ canvas.set = function () {
+ assert.ok( true, 'Placeholder shown' );
+ };
+
+ $image = $( '<img>' ).width( 100 ).height( 50 );
+
+ blurredThumbnailShown = canvas.maybeDisplayPlaceholder(
+ { width: 1000, height: 500 },
+ $image,
+ { cssWidth: 300, cssHeight: 150 }
+ );
+
+ assert.strictEqual( $image.width(), 300, 'Placeholder has the right width' );
+ assert.strictEqual( $image.height(), 150, 'Placeholder has the right height' );
+ assert.ok( $image.hasClass( 'blurred' ), 'Placeholder is blurred' );
+ assert.ok( blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'maybeDisplayPlaceholder: big-enough placeholder that needs blurring, actual image smaller than the lightbox', function ( assert ) {
+ var $image,
+ blurredThumbnailShown,
+ $qf = $( '#qunit-fixture' ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.png' ),
+ canvas = new mw.mmv.ui.Canvas( $qf );
+
+ imageRawMetadata.filePageTitle = {
+ getExtension: function () { return 'png'; }
+ };
+ canvas.imageRawMetadata = imageRawMetadata;
+
+ canvas.set = function () {
+ assert.ok( true, 'Placeholder shown' );
+ };
+
+ $image = $( '<img>' ).width( 100 ).height( 50 );
+
+ blurredThumbnailShown = canvas.maybeDisplayPlaceholder(
+ { width: 1000, height: 500 },
+ $image,
+ { cssWidth: 1200, cssHeight: 600 }
+ );
+
+ assert.strictEqual( $image.width(), 1000, 'Placeholder has the right width' );
+ assert.strictEqual( $image.height(), 500, 'Placeholder has the right height' );
+ assert.ok( $image.hasClass( 'blurred' ), 'Placeholder is blurred' );
+ assert.ok( blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'maybeDisplayPlaceholder: placeholder too small to be displayed, actual image bigger than the lightbox', function ( assert ) {
+ var $image,
+ blurredThumbnailShown,
+ $qf = $( '#qunit-fixture' ),
+ imageRawMetadata = new mw.mmv.LightboxImage( 'foo.png' ),
+ canvas = new mw.mmv.ui.Canvas( $qf );
+
+ imageRawMetadata.filePageTitle = {
+ getExtension: function () { return 'png'; }
+ };
+ canvas.imageRawMetadata = imageRawMetadata;
+
+ canvas.set = function () {
+ assert.ok( false, 'Placeholder shown when it should not' );
+ };
+
+ $image = $( '<img>' ).width( 10 ).height( 5 );
+
+ blurredThumbnailShown = canvas.maybeDisplayPlaceholder(
+ { width: 1000, height: 500 },
+ $image,
+ { cssWidth: 300, cssHeight: 150 }
+ );
+
+ assert.strictEqual( $image.width(), 10, 'Placeholder has the right width' );
+ assert.strictEqual( $image.height(), 5, 'Placeholder has the right height' );
+ assert.ok( !$image.hasClass( 'blurred' ), 'Placeholder is not blurred' );
+ assert.ok( !blurredThumbnailShown, 'Placeholder state is correct' );
+ } );
+
+ QUnit.test( 'Unblur', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ canvas = new mw.mmv.ui.Canvas( $qf ),
+ oldAnimate = $.fn.animate;
+
+ $.fn.animate = function ( target, options ) {
+ var self = this,
+ lastValue;
+
+ $.each( target, function ( key, value ) {
+ lastValue = self.key = value;
+ } );
+
+ if ( options ) {
+ if ( options.step ) {
+ options.step.call( this, lastValue );
+ }
+
+ if ( options.complete ) {
+ options.complete.call( this );
+ }
+ }
+ };
+
+ canvas.$image = $( '<img>' );
+
+ canvas.unblurWithAnimation();
+
+ assert.ok( !canvas.$image.css( '-webkit-filter' ) || !canvas.$image.css( '-webkit-filter' ).length,
+ 'Image has no -webkit-filter left' );
+ assert.ok( !canvas.$image.css( 'filter' ) || !canvas.$image.css( 'filter' ).length || canvas.$image.css( 'filter' ) === 'none',
+ 'Image has no filter left' );
+ assert.strictEqual( parseInt( canvas.$image.css( 'opacity' ), 10 ), 1,
+ 'Image is fully opaque' );
+ assert.ok( !canvas.$image.hasClass( 'blurred' ), 'Image has no "blurred" class' );
+
+ $.fn.animate = oldAnimate;
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvasButtons.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvasButtons.test.js
new file mode 100644
index 00000000..09e5ab9d
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.canvasButtons.test.js
@@ -0,0 +1,36 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.CanvasButtons', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Prev/Next', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ buttons = new mw.mmv.ui.CanvasButtons( $qf, $( '<div>' ), $( '<div>' ) );
+
+ buttons.on( 'next', function () {
+ assert.ok( true, 'Switched to next image' );
+ } );
+
+ buttons.on( 'prev', function () {
+ assert.ok( true, 'Switched to prev image' );
+ } );
+
+ buttons.$next.click();
+ buttons.$prev.click();
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.description.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.description.test.js
new file mode 100644
index 00000000..bcb2b322
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.description.test.js
@@ -0,0 +1,42 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.description', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var description = new mw.mmv.ui.Description( $( '#qunit-fixture' ) );
+
+ assert.ok( description, 'Image description UI element is created' );
+ assert.strictEqual( description.$imageDescDiv.length, 1, 'Image description div is created' );
+ assert.strictEqual( description.$imageDesc.length, 1, 'Image description element is created' );
+ } );
+
+ QUnit.test( 'Setting data in different combinations works well', function ( assert ) {
+ var description = new mw.mmv.ui.Description( $( '#qunit-fixture' ) );
+
+ description.set( null, null );
+ assert.ok( description.$imageDescDiv.hasClass( 'empty' ),
+ 'Image description div is marked empty when neither description nor caption is available' );
+
+ description.set( null, 'foo' );
+ assert.ok( description.$imageDescDiv.hasClass( 'empty' ),
+ 'Image description div is marked empty when there is no description' );
+
+ description.set( 'blah', null );
+ assert.ok( description.$imageDescDiv.hasClass( 'empty' ),
+ 'Image description div is marked empty when there is no caption (description will be shown in title)' );
+
+ description.set( 'foo', 'bar' );
+ assert.ok( !description.$imageDescDiv.hasClass( 'empty' ),
+ 'Image description div is not marked empty when both description and caption are available' );
+ assert.strictEqual( description.$imageDesc.text(), 'foo',
+ 'Image description text is set correctly, caption is ignored' );
+ } );
+
+ QUnit.test( 'Emptying data works as expected', function ( assert ) {
+ var description = new mw.mmv.ui.Description( $( '#qunit-fixture' ) );
+
+ description.set( 'foo', 'bar' );
+ description.empty();
+ assert.strictEqual( description.$imageDescDiv.hasClass( 'empty' ), true, 'Image description div is marked empty when emptied' );
+ assert.strictEqual( description.$imageDesc.text(), '', 'Image description text is emptied correctly' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.download.pane.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.download.pane.test.js
new file mode 100644
index 00000000..8cc6008f
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.download.pane.test.js
@@ -0,0 +1,164 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.download.pane', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) );
+
+ assert.ok( download, 'download UI element is created.' );
+ assert.strictEqual( download.$pane.length, 1, 'Pane div created.' );
+ assert.ok( download.$downloadButton && download.$selectionArrow, 'Download button created.' );
+ assert.ok( download.downloadSizeMenu, 'Image size pulldown menu created.' );
+ assert.ok( download.$previewLink, 'Preview link created.' );
+ assert.ok( download.defaultItem, 'Default item set.' );
+
+ assert.strictEqual( download.$downloadButton.html(), '', 'Button has empty content.' );
+ assert.strictEqual( download.$downloadButton.attr( 'href' ), undefined, 'Button href is empty.' );
+ assert.strictEqual( download.$previewLink.attr( 'href' ), undefined, 'Preview link href is empty.' );
+ } );
+
+ QUnit.test( 'set()/empty():', function ( assert ) {
+ var download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) ),
+ src = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ image = { // fake mw.mmv.model.Image
+ title: new mw.Title( 'File:Foobar.jpg' ),
+ url: src
+ };
+
+ assert.strictEqual( download.imageExtension, undefined, 'Image extension is not set.' );
+
+ download.utils.updateMenuOptions = function () {
+ assert.ok( true, 'Menu options updated.' );
+ };
+ download.downloadSizeMenu.getMenu().selectItem = function () {
+ assert.ok( true, 'Default item selected to update the labels.' );
+ };
+
+ download.set( image );
+
+ assert.strictEqual( download.imageExtension, 'jpg', 'Image extension is set correctly.' );
+
+ download.empty();
+
+ assert.strictEqual( download.imageExtension, undefined, 'Image extension is not set.' );
+ } );
+
+ QUnit.test( 'attach()/unattach():', function ( assert ) {
+ var hsstub, tstub,
+ download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) ),
+ image = {
+ title: new mw.Title( 'File:Foobar.jpg' ),
+ url: 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg'
+ };
+
+ download.set( image );
+
+ hsstub = this.sandbox.stub( download, 'handleSizeSwitch' );
+ tstub = this.sandbox.stub( download.downloadSizeMenu.getMenu(), 'toggle' );
+
+ // Triggering action events before attaching should do nothing
+ download.downloadSizeMenu.getMenu().emit(
+ 'choose', download.downloadSizeMenu.getMenu().findSelectedItem() );
+ download.$selectionArrow.click();
+
+ assert.ok( !hsstub.called, 'handleSizeSwitch not called' );
+ assert.ok( !tstub.called, 'Menu selection did not happen' );
+
+ hsstub.reset();
+ tstub.reset();
+
+ download.attach();
+
+ // Action events should be handled now
+ download.downloadSizeMenu.getMenu().emit(
+ 'choose', download.downloadSizeMenu.getMenu().findSelectedItem() );
+ download.$selectionArrow.click();
+
+ assert.ok( hsstub.called, 'handleSizeSwitch was called' );
+ assert.ok( tstub.called, 'Menu selection happened' );
+
+ hsstub.reset();
+ tstub.reset();
+
+ download.unattach();
+
+ // Triggering action events now that we are unattached should do nothing
+ download.downloadSizeMenu.getMenu().emit(
+ 'choose', download.downloadSizeMenu.getMenu().findSelectedItem() );
+ download.$selectionArrow.click();
+
+ assert.ok( !hsstub.called, 'handleSizeSwitch not called' );
+ assert.ok( !tstub.called, 'Menu selection did not happen' );
+ } );
+
+ QUnit.test( 'handleSizeSwitch():', function ( assert ) {
+ var download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) ),
+ newImageUrl = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/NewFoobar.jpg';
+
+ download.utils.getThumbnailUrlPromise = function () {
+ return $.Deferred().resolve( { url: newImageUrl } ).promise();
+ };
+
+ download.setDownloadUrl = function ( url ) {
+ assert.strictEqual( url, newImageUrl, 'URL passed to setDownloadUrl is correct' );
+ };
+
+ download.handleSizeSwitch( download.downloadSizeMenu.getMenu().findSelectedItem() );
+
+ assert.ok( download.$downloadButton.html().match( /original.*/ ), 'Button message updated.' );
+
+ download.image = { url: newImageUrl };
+
+ download.utils.getThumbnailUrlPromise = function () {
+ assert.ok( false, 'Should not fetch the thumbnail if the image is original size.' );
+ };
+
+ download.handleSizeSwitch( download.downloadSizeMenu.getMenu().findSelectedItem() );
+ } );
+
+ QUnit.test( 'setButtonText() sanity check:', function ( assert ) {
+ var download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) ),
+ message;
+
+ download.setButtonText( 'large', 'jpg', 100, 200 );
+ assert.ok( true, 'Setting the text did not cause any errors' );
+
+ message = download.$downloadButton.html();
+ download.setButtonText( 'small', 'png', 1000, 2000 );
+ assert.notStrictEqual( download.$downloadButton.html(), message, 'Button text was updated' );
+ } );
+
+ QUnit.test( 'getExtensionFromUrl():', function ( assert ) {
+ var download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) );
+
+ assert.strictEqual( download.getExtensionFromUrl( 'http://example.com/bing/foo.bar.png' ),
+ 'png', 'Extension is parsed correctly' );
+ } );
+
+ QUnit.test( 'setDownloadUrl', function ( assert ) {
+ var download = new mw.mmv.ui.download.Pane( $( '#qunit-fixture' ) ),
+ imageUrl = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/NewFoobar.jpg';
+
+ download.setDownloadUrl( imageUrl );
+
+ assert.strictEqual( download.$downloadButton.attr( 'href' ), imageUrl + '?download', 'Download link is set correctly.' );
+ assert.strictEqual( download.$previewLink.attr( 'href' ), imageUrl, 'Preview link is set correctly.' );
+ assert.ok( !download.$downloadButton.hasClass( 'disabledLink' ), 'Download link is enabled.' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanel.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanel.test.js
new file mode 100644
index 00000000..c10c6dc9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanel.test.js
@@ -0,0 +1,207 @@
+( function ( mw, $ ) {
+ var thingsShouldBeEmptied = [
+ '$license',
+ '$title',
+ '$location',
+ '$datetime'
+ ],
+
+ thingsShouldHaveEmptyClass = [
+ '$licenseLi',
+ '$credit',
+ '$locationLi',
+ '$datetimeLi'
+ ];
+
+ QUnit.module( 'mmv.ui.metadataPanel', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'The panel is emptied properly when necessary', function ( assert ) {
+ var i,
+ $qf = $( '#qunit-fixture' ),
+ panel = new mw.mmv.ui.MetadataPanel( $qf, $( '<div>' ).appendTo( $qf ), mw.storage, new mw.mmv.Config( {}, mw.config, mw.user, new mw.Api(), mw.storage ) );
+
+ panel.empty();
+
+ assert.expect( thingsShouldBeEmptied.length + thingsShouldHaveEmptyClass.length );
+
+ for ( i = 0; i < thingsShouldBeEmptied.length; i++ ) {
+ assert.strictEqual( panel[ thingsShouldBeEmptied[ i ] ].text(), '', 'We successfully emptied the ' + thingsShouldBeEmptied[ i ] + ' element' );
+ }
+
+ for ( i = 0; i < thingsShouldHaveEmptyClass.length; i++ ) {
+ assert.strictEqual( panel[ thingsShouldHaveEmptyClass[ i ] ].hasClass( 'empty' ), true, 'We successfully applied the empty class to the ' + thingsShouldHaveEmptyClass[ i ] + ' element' );
+ }
+ } );
+
+ QUnit.test( 'Setting location information works as expected', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ panel = new mw.mmv.ui.MetadataPanel( $qf, $( '<div>' ).appendTo( $qf ), mw.storage, new mw.mmv.Config( {}, mw.config, mw.user, new mw.Api(), mw.storage ) ),
+ fileName = 'Foobar.jpg',
+ latitude = 12.3456789,
+ longitude = 98.7654321,
+ imageData = {
+ latitude: latitude,
+ longitude: longitude,
+ hasCoords: function () { return true; },
+ title: mw.Title.newFromText( 'File:Foobar.jpg' )
+ };
+
+ panel.setLocationData( imageData );
+
+ assert.strictEqual(
+ panel.$location.text(),
+ 'Location: 12° 20′ 44.44″ N, 98° 45′ 55.56″ E',
+ 'Location text is set as expected - if this fails it may be due to i18n issues.'
+ );
+
+ assert.strictEqual(
+ panel.$location.prop( 'href' ),
+ 'http://tools.wmflabs.org/geohack/geohack.php?pagename=File:' + fileName + '&params=' + latitude + '_N_' + longitude + '_E_&language=en',
+ 'Location URL is set as expected'
+ );
+
+ latitude = -latitude;
+ longitude = -longitude;
+ imageData.latitude = latitude;
+ imageData.longitude = longitude;
+ panel.setLocationData( imageData );
+
+ assert.strictEqual(
+ panel.$location.text(),
+ 'Location: 12° 20′ 44.44″ S, 98° 45′ 55.56″ W',
+ 'Location text is set as expected - if this fails it may be due to i18n issues.'
+ );
+
+ assert.strictEqual(
+ panel.$location.prop( 'href' ),
+ 'http://tools.wmflabs.org/geohack/geohack.php?pagename=File:' + fileName + '&params=' + ( -latitude ) + '_S_' + ( -longitude ) + '_W_&language=en',
+ 'Location URL is set as expected'
+ );
+
+ latitude = 0;
+ longitude = 0;
+ imageData.latitude = latitude;
+ imageData.longitude = longitude;
+ panel.setLocationData( imageData );
+
+ assert.strictEqual(
+ panel.$location.text(),
+ 'Location: 0° 0′ 0″ N, 0° 0′ 0″ E',
+ 'Location text is set as expected - if this fails it may be due to i18n issues.'
+ );
+
+ assert.strictEqual(
+ panel.$location.prop( 'href' ),
+ 'http://tools.wmflabs.org/geohack/geohack.php?pagename=File:' + fileName + '&params=' + latitude + '_N_' + longitude + '_E_&language=en',
+ 'Location URL is set as expected'
+ );
+ } );
+
+ QUnit.test( 'Setting image information works as expected', function ( assert ) {
+ var creditPopupText,
+ $qf = $( '#qunit-fixture' ),
+ panel = new mw.mmv.ui.MetadataPanel( $qf, $( '<div>' ).appendTo( $qf ), mw.storage, new mw.mmv.Config( {}, mw.config, mw.user, new mw.Api(), mw.storage ) ),
+ title = 'Foo bar',
+ image = {
+ filePageTitle: mw.Title.newFromText( 'File:' + title + '.jpg' )
+ },
+ imageData = {
+ title: image.filePageTitle,
+ url: 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ descriptionUrl: 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ hasCoords: function () { return false; }
+ },
+ repoData = {
+ getArticlePath: function () { return 'Foo'; },
+ isCommons: function () { return false; }
+ },
+ oldMoment = window.moment,
+ // custom clock will give MPP.formatDate some time to load moment.js
+ clock = this.sandbox.useFakeTimers();
+
+ /* window.moment = function ( date ) {
+ // This has no effect for now, since writing this test revealed that our moment.js
+ // doesn't have any language configuration
+ return oldMoment( date ).lang( 'fr' );
+ };*/
+
+ panel.setImageInfo( image, imageData, repoData );
+
+ assert.strictEqual( panel.$title.text(), title, 'Title is correctly set' );
+ assert.ok( panel.$credit.text(), 'Default credit is shown' );
+ assert.strictEqual( panel.$license.prop( 'href' ), imageData.descriptionUrl,
+ 'User is directed to file page for license information' );
+ assert.ok( !panel.$license.prop( 'target' ), 'License information opens in same window' );
+ assert.ok( panel.$datetimeLi.hasClass( 'empty' ), 'Date/Time is empty' );
+ assert.ok( panel.$locationLi.hasClass( 'empty' ), 'Location is empty' );
+
+ imageData.creationDateTime = '2013-08-26T14:41:02Z';
+ imageData.uploadDateTime = '2013-08-25T14:41:02Z';
+ imageData.source = '<b>Lost</b><a href="foo">Bar</a>';
+ imageData.author = 'Bob';
+ imageData.license = new mw.mmv.model.License( 'CC-BY-2.0', 'cc-by-2.0',
+ 'Creative Commons Attribution - Share Alike 2.0',
+ 'http://creativecommons.org/licenses/by-sa/2.0/' );
+ imageData.restrictions = [ 'trademarked', 'default', 'insignia' ];
+
+ panel.setImageInfo( image, imageData, repoData );
+ creditPopupText = panel.creditField.$element.attr( 'original-title' );
+ clock.tick( 10 );
+
+ assert.strictEqual( panel.$title.text(), title, 'Title is correctly set' );
+ assert.ok( !panel.$credit.hasClass( 'empty' ), 'Credit is not empty' );
+ assert.ok( !panel.$datetimeLi.hasClass( 'empty' ), 'Date/Time is not empty' );
+ assert.strictEqual( panel.creditField.$element.find( '.mw-mmv-author' ).text(), imageData.author, 'Author text is correctly set' );
+ assert.strictEqual( panel.creditField.$element.find( '.mw-mmv-source' ).html(), '<b>Lost</b><a href="foo">Bar</a>', 'Source text is correctly set' );
+ // Either multimediaviewer-credit-popup-text or multimediaviewer-credit-popup-text-more.
+ assert.ok( creditPopupText === 'Author and source information' || creditPopupText === 'View full author and source', 'Source tooltip is correctly set' );
+ assert.ok( panel.$datetime.text().indexOf( '26 August 2013' ) > 0, 'Correct date is displayed' );
+ assert.strictEqual( panel.$license.text(), 'CC BY 2.0', 'License is correctly set' );
+ assert.ok( panel.$license.prop( 'target' ), 'License information opens in new window' );
+ assert.ok( panel.$restrictions.children().last().children().hasClass( 'mw-mmv-restriction-default' ), 'Default restriction is correctly displayed last' );
+
+ imageData.creationDateTime = undefined;
+ panel.setImageInfo( image, imageData, repoData );
+ clock.tick( 10 );
+
+ assert.ok( panel.$datetime.text().indexOf( '25 August 2013' ) > 0, 'Correct date is displayed' );
+
+ window.moment = oldMoment;
+ clock.restore();
+ } );
+
+ QUnit.test( 'Setting permission information works as expected', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ panel = new mw.mmv.ui.MetadataPanel( $qf, $( '<div>' ).appendTo( $qf ), mw.storage, new mw.mmv.Config( {}, mw.config, mw.user, new mw.Api(), mw.storage ) );
+
+ panel.setLicense( null, 'http://example.com' ); // make sure license is visible as it contains the permission
+ panel.setPermission( 'Look at me, I am a permission!' );
+ assert.ok( panel.$permissionLink.is( ':visible' ) );
+ } );
+
+ QUnit.test( 'Date formatting', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ panel = new mw.mmv.ui.MetadataPanel( $qf, $( '<div>' ).appendTo( $qf ), mw.storage, new mw.mmv.Config( {}, mw.config, mw.user, new mw.Api(), mw.storage ) ),
+ date1 = 'Garbage',
+ promise = panel.formatDate( date1 );
+
+ return promise.then( function ( result ) {
+ assert.strictEqual( result, date1, 'Invalid date is correctly ignored' );
+ } );
+ } );
+
+ QUnit.test( 'About links', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ oldWgMediaViewerIsInBeta = mw.config.get( 'wgMediaViewerIsInBeta' );
+
+ this.sandbox.stub( mw.user, 'isAnon' );
+ mw.config.set( 'wgMediaViewerIsInBeta', false );
+ // eslint-disable-next-line no-new
+ new mw.mmv.ui.MetadataPanel( $qf.empty(), $( '<div>' ).appendTo( $qf ), mw.storage, new mw.mmv.Config( {}, mw.config, mw.user, new mw.Api(), mw.storage ) );
+
+ assert.strictEqual( $qf.find( '.mw-mmv-about-link' ).length, 1, 'About link is created.' );
+ assert.strictEqual( $qf.find( '.mw-mmv-discuss-link' ).length, 1, 'Discuss link is created.' );
+ assert.strictEqual( $qf.find( '.mw-mmv-help-link' ).length, 1, 'Help link is created.' );
+ mw.config.set( 'wgMediaViewerIsInBeta', oldWgMediaViewerIsInBeta );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanelScroller.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanelScroller.test.js
new file mode 100644
index 00000000..7de5aef0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.metadataPanelScroller.test.js
@@ -0,0 +1,232 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.metadataPanelScroller', QUnit.newMwEnvironment( {
+ setup: function () {
+ this.clock = this.sandbox.useFakeTimers();
+ }
+ } ) );
+
+ QUnit.test( 'empty()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ localStorage = mw.mmv.testHelpers.getFakeLocalStorage(),
+ scroller = new mw.mmv.ui.MetadataPanelScroller( $qf, $( '<div>' ).appendTo( $qf ), localStorage );
+
+ scroller.empty();
+ assert.ok( !scroller.$container.hasClass( 'invite' ), 'We successfully reset the invite' );
+ } );
+
+ QUnit.test( 'Metadata div is only animated once', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ displayCount = null, // pretend it doesn't exist at first
+ localStorage = mw.mmv.testHelpers.createLocalStorage( {
+ // We simulate localStorage to avoid test side-effects
+ getItem: function () { return displayCount; },
+ setItem: function ( _, val ) { displayCount = val; }
+ } ),
+ scroller = new mw.mmv.ui.MetadataPanelScroller( $qf, $( '<div>' ).appendTo( $qf ), localStorage );
+
+ scroller.attach();
+
+ scroller.animateMetadataOnce();
+
+ assert.ok( scroller.hasAnimatedMetadata,
+ 'The first call to animateMetadataOnce set hasAnimatedMetadata to true' );
+ assert.ok( $qf.hasClass( 'invite' ),
+ 'The first call to animateMetadataOnce led to an animation' );
+
+ $qf.removeClass( 'invite' );
+
+ scroller.animateMetadataOnce();
+
+ assert.strictEqual( scroller.hasAnimatedMetadata, true, 'The second call to animateMetadataOnce did not change the value of hasAnimatedMetadata' );
+ assert.ok( !$qf.hasClass( 'invite' ),
+ 'The second call to animateMetadataOnce did not lead to an animation' );
+
+ scroller.unattach();
+
+ scroller.attach();
+
+ scroller.animateMetadataOnce();
+ assert.ok( $qf.hasClass( 'invite' ),
+ 'After closing and opening the viewer, the panel is animated again' );
+
+ scroller.unattach();
+ } );
+
+ QUnit.test( 'No localStorage', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ localStorage = mw.mmv.testHelpers.getUnsupportedLocalStorage(),
+ scroller = new mw.mmv.ui.MetadataPanelScroller( $qf, $( '<div>' ).appendTo( $qf ), localStorage );
+
+ this.sandbox.stub( $.fn, 'scrollTop', function () { return 10; } );
+
+ scroller.scroll();
+
+ assert.strictEqual( scroller.hasOpenedMetadata, true, 'We store hasOpenedMetadata flag for the session' );
+ } );
+
+ QUnit.test( 'localStorage is full', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ localStorage = mw.mmv.testHelpers.createLocalStorage( {
+ getItem: this.sandbox.stub().returns( null ),
+ setItem: this.sandbox.stub().throwsException( 'I am full' )
+ } ),
+ scroller = new mw.mmv.ui.MetadataPanelScroller( $qf, $( '<div>' ).appendTo( $qf ), localStorage );
+
+ this.sandbox.stub( $.fn, 'scrollTop', function () { return 10; } );
+
+ scroller.attach();
+
+ scroller.scroll();
+
+ assert.strictEqual( scroller.hasOpenedMetadata, true, 'We store hasOpenedMetadata flag for the session' );
+
+ scroller.scroll();
+
+ assert.ok( localStorage.store.setItem.calledOnce, 'localStorage only written once' );
+
+ scroller.unattach();
+ } );
+
+ /**
+ * We need to set up a proxy on the jQuery scrollTop function and the jQuery.scrollTo plugin,
+ * that will let us pretend that the document really scrolled and that will return values
+ * as if the scroll happened.
+ *
+ * @param {sinon.sandbox} sandbox
+ * @param {mw.mmv.ui.MetadataPanelScroller} scroller
+ */
+ function stubScrollFunctions( sandbox, scroller ) {
+ var memorizedScrollTop = 0;
+
+ sandbox.stub( $.fn, 'scrollTop', function ( scrollTop ) {
+ if ( scrollTop !== undefined ) {
+ memorizedScrollTop = scrollTop;
+ scroller.scroll();
+ return this;
+ } else {
+ return memorizedScrollTop;
+ }
+ } );
+ sandbox.stub( $.fn, 'animate', function ( props ) {
+ if ( 'scrollTop' in props ) {
+ memorizedScrollTop = props.scrollTop;
+ scroller.scroll();
+ }
+ return this;
+ } );
+ }
+
+ QUnit.test( 'Metadata scrolling', function ( assert ) {
+ var $window = $( window ),
+ $qf = $( '#qunit-fixture' ),
+ $container = $( '<div>' ).css( 'height', 100 ).appendTo( $qf ),
+ $aboveFold = $( '<div>' ).css( 'height', 50 ).appendTo( $container ),
+ fakeLocalStorage = mw.mmv.testHelpers.createLocalStorage( {
+ getItem: this.sandbox.stub().returns( null ),
+ setItem: $.noop
+ } ),
+ scroller = new mw.mmv.ui.MetadataPanelScroller( $container, $aboveFold, fakeLocalStorage ),
+ keydown = $.Event( 'keydown' );
+
+ stubScrollFunctions( this.sandbox, scroller );
+
+ this.sandbox.stub( fakeLocalStorage.store, 'setItem' );
+
+ // First phase of the test: up and down arrows
+
+ scroller.hasAnimatedMetadata = false;
+
+ scroller.attach();
+
+ assert.strictEqual( $window.scrollTop(), 0, 'scrollTop should be set to 0' );
+
+ assert.ok( !fakeLocalStorage.store.setItem.called, 'The metadata hasn\'t been open yet, no entry in localStorage' );
+
+ keydown.which = 38; // Up arrow
+ scroller.keydown( keydown );
+
+ assert.ok( fakeLocalStorage.store.setItem.calledWithExactly( 'mmv.hasOpenedMetadata', '1' ), 'localStorage knows that the metadata has been open' );
+
+ keydown.which = 40; // Down arrow
+ scroller.keydown( keydown );
+
+ assert.strictEqual( $window.scrollTop(), 0,
+ 'scrollTop should be set to 0 after pressing down arrow' );
+
+ // Unattach lightbox from document
+ scroller.unattach();
+
+ // Second phase of the test: scroll memory
+
+ scroller.attach();
+
+ // To make sure that the details are out of view, the lightbox is supposed to scroll to the top when open
+ assert.strictEqual( $window.scrollTop(), 0, 'Page scrollTop should be set to 0' );
+
+ // Scroll down to check that the scrollTop memory doesn't affect prev/next (bug 59861)
+ $window.scrollTop( 20 );
+ this.clock.tick( 100 );
+
+ // This extra attach() call simulates the effect of prev/next seen in bug 59861
+ scroller.attach();
+
+ // The lightbox was already open at this point, the scrollTop should be left untouched
+ assert.strictEqual( $window.scrollTop(), 20, 'Page scrollTop should be set to 20' );
+
+ scroller.unattach();
+ } );
+
+ QUnit.test( 'Metadata scroll logging', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $container = $( '<div>' ).css( 'height', 100 ).appendTo( $qf ),
+ $aboveFold = $( '<div>' ).css( 'height', 50 ).appendTo( $container ),
+ localStorage = mw.mmv.testHelpers.getFakeLocalStorage(),
+ scroller = new mw.mmv.ui.MetadataPanelScroller( $container, $aboveFold, localStorage ),
+ keydown = $.Event( 'keydown' );
+
+ stubScrollFunctions( this.sandbox, scroller );
+
+ this.sandbox.stub( mw.mmv.actionLogger, 'log' );
+
+ keydown.which = 38; // Up arrow
+ scroller.keydown( keydown );
+
+ assert.ok( mw.mmv.actionLogger.log.calledWithExactly( 'metadata-open' ), 'Opening keypress logged' );
+ mw.mmv.actionLogger.log.reset();
+
+ keydown.which = 38; // Up arrow
+ scroller.keydown( keydown );
+
+ assert.ok( mw.mmv.actionLogger.log.calledWithExactly( 'metadata-close' ), 'Closing keypress logged' );
+ mw.mmv.actionLogger.log.reset();
+
+ keydown.which = 40; // Down arrow
+ scroller.keydown( keydown );
+
+ assert.ok( mw.mmv.actionLogger.log.calledWithExactly( 'metadata-open' ), 'Opening keypress logged' );
+ mw.mmv.actionLogger.log.reset();
+
+ keydown.which = 40; // Down arrow
+ scroller.keydown( keydown );
+
+ assert.ok( mw.mmv.actionLogger.log.calledWithExactly( 'metadata-close' ), 'Closing keypress logged' );
+ mw.mmv.actionLogger.log.reset();
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.permission.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.permission.test.js
new file mode 100644
index 00000000..319642e3
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.permission.test.js
@@ -0,0 +1,112 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mw.mmv.ui.Permission', QUnit.newMwEnvironment( {
+ setup: function () {
+ // animation would keep running, conflict with other tests
+ this.sandbox.stub( $.fn, 'animate' ).returnsThis();
+ }
+ } ) );
+
+ QUnit.test( 'Constructor sanity check', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf );
+
+ assert.ok( permission, 'constructor does not throw error' );
+ } );
+
+ QUnit.test( 'set()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf ),
+ text = 'Nothing to see here.';
+
+ permission.set( text );
+
+ // FIXME get rid of "view more" - this is temporary
+ assert.strictEqual( permission.$text.children().remove().end().text(),
+ text, 'permission text is set' );
+ assert.strictEqual( permission.$html.text(), text, 'permission html is set' );
+ assert.ok( permission.$text.is( ':visible' ), 'permission text is visible' );
+ assert.ok( !permission.$html.is( ':visible' ), 'permission html is not visible' );
+ assert.ok( !permission.$close.is( ':visible' ), 'close button is not visible' );
+ } );
+
+ QUnit.test( 'set() with html', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf ),
+ text = '<b>Nothing</b> to see here.';
+
+ permission.set( text );
+
+ assert.ok( !permission.$text.find( 'b' ).length, 'permission text has no html' );
+ assert.ok( permission.$html.find( 'b' ), 'permission html has html' );
+ } );
+
+ QUnit.test( 'empty()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf ),
+ text = 'Nothing to see here.';
+
+ permission.set( text );
+ permission.empty();
+
+ assert.ok( !permission.$text.is( ':visible' ), 'permission text is not visible' );
+ assert.ok( !permission.$html.is( ':visible' ), 'permission html is not visible' );
+ assert.ok( !permission.$close.is( ':visible' ), 'close button is not visible' );
+ } );
+
+ QUnit.test( 'grow()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf ),
+ text = 'Nothing to see here.';
+
+ permission.set( text );
+ permission.grow();
+
+ assert.ok( !permission.$text.is( ':visible' ), 'permission text is not visible' );
+ assert.ok( permission.$html.is( ':visible' ), 'permission html is visible' );
+ assert.ok( permission.$close.is( ':visible' ), 'close button is visible' );
+ } );
+
+ QUnit.test( 'shrink()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf ),
+ text = 'Nothing to see here.';
+
+ permission.set( text );
+ permission.grow();
+ permission.shrink();
+
+ assert.ok( permission.$text.is( ':visible' ), 'permission text is visible' );
+ assert.ok( !permission.$html.is( ':visible' ), 'permission html is not visible' );
+ assert.ok( !permission.$close.is( ':visible' ), 'close button is not visible' );
+ } );
+
+ QUnit.test( 'isFullSize()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ permission = new mw.mmv.ui.Permission( $qf ),
+ text = 'Nothing to see here.';
+
+ permission.set( text );
+ assert.ok( !permission.isFullSize(), 'permission is not full-size' );
+ permission.grow();
+ assert.ok( permission.isFullSize(), 'permission is full-size' );
+ permission.shrink();
+ assert.ok( !permission.isFullSize(), 'permission is not full-size again' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.progressBar.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.progressBar.test.js
new file mode 100644
index 00000000..5b3bd3d0
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.progressBar.test.js
@@ -0,0 +1,77 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.ProgressBar', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity check', function ( assert ) {
+ var progressBar = new mw.mmv.ui.ProgressBar( $( '<div>' ) );
+ assert.ok( progressBar, 'ProgressBar created sccessfully' );
+ assert.ok( progressBar.$progress.hasClass( 'empty' ), 'ProgressBar starts empty' );
+ } );
+
+ QUnit.test( 'animateTo()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $div = $( '<div>' ).css( { width: 250, position: 'relative' } ).appendTo( $qf ),
+ progress = new mw.mmv.ui.ProgressBar( $div );
+
+ assert.ok( progress.$progress.hasClass( 'empty' ), 'Progress bar is hidden' );
+ assert.strictEqual( progress.$percent.width(), 0, 'Progress bar\'s indicator is at 0' );
+
+ this.sandbox.stub( $.fn, 'animate', function ( target ) {
+ $( this ).css( target );
+ assert.strictEqual( target.width, '50%', 'Animation should go to 50%' );
+ } );
+ progress.animateTo( 50 );
+ assert.ok( !progress.$progress.hasClass( 'empty' ), 'Progress bar is visible' );
+
+ assert.strictEqual( progress.$percent.width(), 125, 'Progress bar\'s indicator is at half' );
+
+ $.fn.animate.restore();
+ this.sandbox.stub( $.fn, 'animate', function ( target, duration, transition, callback ) {
+ $( this ).css( target );
+
+ assert.strictEqual( target.width, '100%', 'Animation should go to 100%' );
+
+ if ( callback !== undefined ) {
+ callback();
+ }
+ } );
+ progress.animateTo( 100 );
+ assert.ok( progress.$progress.hasClass( 'empty' ), 'Progress bar is hidden' );
+ assert.strictEqual( progress.$percent.width(), 0, 'Progress bar\'s indicator is at 0' );
+ } );
+
+ QUnit.test( 'jumpTo()/hide()', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $div = $( '<div>' ).css( { width: 250, position: 'relative' } ).appendTo( $qf ),
+ progress = new mw.mmv.ui.ProgressBar( $div );
+
+ assert.ok( progress.$progress.hasClass( 'empty' ), 'Progress bar is hidden' );
+ assert.strictEqual( progress.$percent.width(), 0, 'Progress bar\'s indicator is at 0' );
+
+ progress.jumpTo( 50 );
+
+ assert.ok( !progress.$progress.hasClass( 'empty' ), 'Progress bar is visible' );
+ assert.strictEqual( progress.$percent.width(), 125, 'Progress bar\'s indicator is at half' );
+
+ progress.hide();
+
+ assert.ok( progress.$progress.hasClass( 'empty' ), 'Progress bar is hidden' );
+ assert.strictEqual( progress.$percent.width(), 0, 'Progress bar\'s indicator is at 0' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.dialog.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.dialog.test.js
new file mode 100644
index 00000000..01322125
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.dialog.test.js
@@ -0,0 +1,250 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ function makeReuseDialog( sandbox ) {
+ var $fixture = $( '#qunit-fixture' ),
+ config = { getFromLocalStorage: sandbox.stub(), setInLocalStorage: sandbox.stub() };
+ return new mw.mmv.ui.reuse.Dialog( $fixture, $( '<div>' ).appendTo( $fixture ), config );
+ }
+
+ QUnit.module( 'mmv.ui.reuse.Dialog', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox );
+
+ assert.ok( reuseDialog, 'Reuse UI element is created.' );
+ assert.strictEqual( reuseDialog.$dialog.length, 1, 'Reuse dialog div created.' );
+ } );
+
+ QUnit.test( 'handleOpenCloseClick():', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox );
+
+ reuseDialog.openDialog = function () {
+ assert.ok( true, 'openDialog called.' );
+ };
+ reuseDialog.closeDialog = function () {
+ assert.ok( false, 'closeDialog should not have been called.' );
+ };
+
+ // Dialog is closed by default, we should open it
+ reuseDialog.handleOpenCloseClick();
+
+ reuseDialog.openDialog = function () {
+ assert.ok( false, 'openDialog should not have been called.' );
+ };
+ reuseDialog.closeDialog = function () {
+ assert.ok( true, 'closeDialog called.' );
+ };
+ reuseDialog.isOpen = true;
+
+ // Dialog open now, we should close it.
+ reuseDialog.handleOpenCloseClick();
+ } );
+
+ QUnit.test( 'handleTabSelection():', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox );
+
+ reuseDialog.initTabs();
+
+ // Share pane is selected
+ reuseDialog.handleTabSelection( { getData: function () { return 'share'; } } );
+ assert.ok( reuseDialog.tabs.share.$pane.hasClass( 'active' ), 'Share tab shown.' );
+ assert.ok( !reuseDialog.tabs.embed.$pane.hasClass( 'active' ), 'Embed tab hidden.' );
+ assert.ok( reuseDialog.config.setInLocalStorage.calledWith( 'mmv-lastUsedTab', 'share' ),
+ 'Tab state saved in local storage.' );
+
+ // Embed pane is selected
+ reuseDialog.handleTabSelection( { getData: function () { return 'embed'; } } );
+ assert.ok( !reuseDialog.tabs.share.$pane.hasClass( 'active' ), 'Share tab hidden.' );
+ assert.ok( reuseDialog.tabs.embed.$pane.hasClass( 'active' ), 'Embed tab shown.' );
+ } );
+
+ QUnit.test( 'default tab:', function ( assert ) {
+ var reuseDialog;
+
+ reuseDialog = makeReuseDialog( this.sandbox );
+ reuseDialog.initTabs();
+ assert.strictEqual( reuseDialog.selectedTab, 'share', 'Share tab is default' );
+
+ reuseDialog = makeReuseDialog( this.sandbox );
+ reuseDialog.config.getFromLocalStorage.withArgs( 'mmv-lastUsedTab' ).returns( 'share' );
+ reuseDialog.initTabs();
+ assert.strictEqual( reuseDialog.selectedTab, 'share', 'Default can be overridden' );
+ } );
+
+ QUnit.test( 'attach()/unattach():', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox );
+
+ reuseDialog.initTabs();
+
+ reuseDialog.handleOpenCloseClick = function () {
+ assert.ok( false, 'handleOpenCloseClick should not have been called.' );
+ };
+ reuseDialog.handleTabSelection = function () {
+ assert.ok( false, 'handleTabSelection should not have been called.' );
+ };
+
+ // Triggering action events before attaching should do nothing
+ $( document ).trigger( 'mmv-reuse-open' );
+ reuseDialog.reuseTabs.emit( 'select' );
+
+ reuseDialog.handleOpenCloseClick = function () {
+ assert.ok( true, 'handleOpenCloseClick called.' );
+ };
+ reuseDialog.handleTabSelection = function () {
+ assert.ok( true, 'handleTabSelection called.' );
+ };
+
+ reuseDialog.attach();
+
+ // Action events should be handled now
+ $( document ).trigger( 'mmv-reuse-open' );
+ reuseDialog.reuseTabs.emit( 'select' );
+
+ // Test the unattach part
+ reuseDialog.handleOpenCloseClick = function () {
+ assert.ok( false, 'handleOpenCloseClick should not have been called.' );
+ };
+ reuseDialog.handleTabSelection = function () {
+ assert.ok( false, 'handleTabSelection should not have been called.' );
+ };
+
+ reuseDialog.unattach();
+
+ // Triggering action events now that we are unattached should do nothing
+ $( document ).trigger( 'mmv-reuse-open' );
+ reuseDialog.reuseTabs.emit( 'select' );
+ } );
+
+ QUnit.test( 'start/stopListeningToOutsideClick():', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox ),
+ realCloseDialog = reuseDialog.closeDialog;
+
+ reuseDialog.initTabs();
+
+ function clickOutsideDialog() {
+ var event = new $.Event( 'click', { target: reuseDialog.$container[ 0 ] } );
+ reuseDialog.$container.trigger( event );
+ return event;
+ }
+ function clickInsideDialog() {
+ var event = new $.Event( 'click', { target: reuseDialog.$dialog[ 0 ] } );
+ reuseDialog.$dialog.trigger( event );
+ return event;
+ }
+
+ function assertDialogDoesNotCatchClicks() {
+ var event;
+ reuseDialog.closeDialog = function () { assert.ok( false, 'Dialog is not affected by click' ); };
+ event = clickOutsideDialog();
+ assert.ok( !event.isDefaultPrevented(), 'Dialog does not affect click' );
+ assert.ok( !event.isPropagationStopped(), 'Dialog does not affect click propagation' );
+ }
+ function assertDialogCatchesOutsideClicksOnly() {
+ var event;
+ reuseDialog.closeDialog = function () { assert.ok( false, 'Dialog is not affected by inside click' ); };
+ event = clickInsideDialog();
+ assert.ok( !event.isDefaultPrevented(), 'Dialog does not affect inside click' );
+ assert.ok( !event.isPropagationStopped(), 'Dialog does not affect inside click propagation' );
+ reuseDialog.closeDialog = function () { assert.ok( true, 'Dialog is closed by outside click' ); };
+ event = clickOutsideDialog();
+ assert.ok( event.isDefaultPrevented(), 'Dialog catches outside click' );
+ assert.ok( event.isPropagationStopped(), 'Dialog stops outside click propagation' );
+ }
+
+ assertDialogDoesNotCatchClicks();
+ reuseDialog.openDialog();
+ assertDialogCatchesOutsideClicksOnly();
+ realCloseDialog.call( reuseDialog );
+ assertDialogDoesNotCatchClicks();
+ reuseDialog.openDialog();
+ reuseDialog.unattach();
+ assertDialogDoesNotCatchClicks();
+ } );
+
+ QUnit.test( 'set()/empty() sanity check:', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox ),
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ src = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ url = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ image = { // fake mw.mmv.model.Image
+ title: title,
+ url: src,
+ descriptionUrl: url,
+ width: 100,
+ height: 80
+ },
+ embedFileInfo = new mw.mmv.model.EmbedFileInfo( title, src, url );
+
+ reuseDialog.set( image, embedFileInfo );
+ reuseDialog.empty();
+
+ assert.ok( true, 'Set/empty did not cause an error.' );
+ } );
+
+ QUnit.test( 'openDialog()/closeDialog():', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox ),
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ src = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ url = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ image = { // fake mw.mmv.model.Image
+ title: title,
+ url: src,
+ descriptionUrl: url,
+ width: 100,
+ height: 80
+ },
+ repoInfo = new mw.mmv.model.Repo( 'Wikipedia', '//wikipedia.org/favicon.ico', true );
+
+ reuseDialog.initTabs();
+
+ reuseDialog.set( image, repoInfo );
+
+ assert.ok( !reuseDialog.isOpen, 'Dialog closed by default.' );
+
+ reuseDialog.openDialog();
+
+ assert.ok( reuseDialog.isOpen, 'Dialog open now.' );
+
+ reuseDialog.closeDialog();
+
+ assert.ok( !reuseDialog.isOpen, 'Dialog closed now.' );
+ } );
+
+ QUnit.test( 'getImageWarnings():', function ( assert ) {
+ var reuseDialog = makeReuseDialog( this.sandbox ),
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ src = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ url = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ image = { // fake mw.mmv.model.Image
+ title: title,
+ url: src,
+ descriptionUrl: url,
+ width: 100,
+ height: 80
+ },
+ imageDeleted = $.extend( { deletionReason: 'deleted file test' }, image );
+
+ // Test that the lack of license is picked up
+ assert.equal( 1, reuseDialog.getImageWarnings( image ).length, 'Lack of license detected' );
+
+ // Test that deletion supersedes other warnings and only that one is reported
+ assert.equal( 1, reuseDialog.getImageWarnings( imageDeleted ).length, 'Deletion detected' );
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.embed.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.embed.test.js
new file mode 100644
index 00000000..69ca2466
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.embed.test.js
@@ -0,0 +1,398 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var $qf = $( '#qunit-fixture' );
+
+ QUnit.module( 'mmv.ui.reuse.Embed', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf );
+
+ assert.ok( embed, 'Embed UI element is created.' );
+ assert.strictEqual( embed.$pane.length, 1, 'Pane div is created.' );
+ assert.ok( embed.embedTextHtml, 'Html snipped text area created.' );
+ assert.ok( embed.embedTextWikitext, 'Wikitext snipped text area created.' );
+ assert.ok( embed.embedSwitch, 'Snipped selection buttons created.' );
+ assert.ok( embed.embedSizeSwitchWikitext, 'Size selection menu for wikitext created.' );
+ assert.ok( embed.embedSizeSwitchHtml, 'Size selection menu for html created.' );
+ assert.strictEqual( embed.$currentMainEmbedText.length, 1, 'Size selection menu for html created.' );
+ assert.strictEqual( embed.isSizeMenuDefaultReset, false, 'Reset flag intialized correctly.' );
+ assert.ok( embed.defaultHtmlItem, 'Default item for html size selection intialized.' );
+ assert.ok( embed.defaultWikitextItem, 'Default item for wikitext size selection intialized.' );
+ assert.ok( embed.currentSizeMenu, 'Current size menu intialized.' );
+ assert.ok( embed.currentDefaultItem, 'Current default item intialized.' );
+ } );
+
+ QUnit.test( 'changeSize(): Skip if no item selected.', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ width = 10,
+ height = 20;
+
+ assert.expect( 0 );
+
+ // deselect items
+ embed.embedSwitch.selectItem();
+
+ embed.updateEmbedHtml = function () {
+ assert.ok( false, 'No item selected, this should not have been called.' );
+ };
+ embed.updateEmbedWikitext = function () {
+ assert.ok( false, 'No item selected, this should not have been called.' );
+ };
+
+ embed.changeSize( width, height );
+ } );
+
+ QUnit.test( 'changeSize(): HTML size menu item selected.', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ width = 10,
+ height = 20;
+
+ embed.embedSwitch.findSelectedItem = function () {
+ return { getData: function () { return 'html'; } };
+ };
+ embed.updateEmbedHtml = function ( thumb, w, h ) {
+ assert.strictEqual( thumb.url, undefined, 'Empty thumbnail passed.' );
+ assert.strictEqual( w, width, 'Correct width passed.' );
+ assert.strictEqual( h, height, 'Correct height passed.' );
+ };
+ embed.updateEmbedWikitext = function () {
+ assert.ok( false, 'Dealing with HTML menu, this should not have been called.' );
+ };
+ embed.select = function () {
+ assert.ok( true, 'Item selected after update.' );
+ };
+
+ embed.changeSize( width, height );
+ } );
+
+ QUnit.test( 'changeSize(): Wikitext size menu item selected.', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ width = 10,
+ height = 20;
+
+ embed.embedSwitch.findSelectedItem = function () {
+ return { getData: function () { return 'wikitext'; } };
+ };
+ embed.updateEmbedHtml = function () {
+ assert.ok( false, 'Dealing with wikitext menu, this should not have been called.' );
+ };
+ embed.updateEmbedWikitext = function ( w ) {
+ assert.strictEqual( w, width, 'Correct width passed.' );
+ };
+ embed.select = function () {
+ assert.ok( true, 'Item selected after update.' );
+ };
+
+ embed.changeSize( width, height );
+ } );
+
+ QUnit.test( 'updateEmbedHtml(): Do nothing if set() not called before.', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ width = 10,
+ height = 20;
+
+ assert.expect( 0 );
+
+ embed.formatter.getThumbnailHtml = function () {
+ assert.ok( false, 'formatter.getThumbnailHtml() should not have been called.' );
+ };
+ embed.updateEmbedHtml( {}, width, height );
+ } );
+
+ QUnit.test( 'updateEmbedHtml():', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ url = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ thumbUrl = 'https://upload.wikimedia.org/wikipedia/thumb/Foobar.jpg',
+ imageInfo = { url: url },
+ repoInfo = {},
+ caption = '-',
+ info = new mw.mmv.model.EmbedFileInfo( imageInfo, repoInfo, caption ),
+ width = 10,
+ height = 20;
+
+ embed.set( imageInfo, repoInfo, caption );
+
+ // Small image, no thumbnail info is passed
+ embed.formatter.getThumbnailHtml = function ( i, u, w, h ) {
+ assert.deepEqual( i, info, 'Info passed correctly.' );
+ assert.strictEqual( u, url, 'Image URL passed correctly.' );
+ assert.strictEqual( w, width, 'Correct width passed.' );
+ assert.strictEqual( h, height, 'Correct height passed.' );
+ };
+ embed.updateEmbedHtml( {}, width, height );
+
+ // Small image, thumbnail info present
+ embed.formatter.getThumbnailHtml = function ( i, u ) {
+ assert.strictEqual( u, thumbUrl, 'Image src passed correctly.' );
+ };
+ embed.updateEmbedHtml( { url: thumbUrl }, width, height );
+
+ // Big image, thumbnail info present
+ embed.formatter.getThumbnailHtml = function ( i, u ) {
+ assert.strictEqual( u, url, 'Image src passed correctly.' );
+ };
+ width = 1300;
+ embed.updateEmbedHtml( { url: thumbUrl }, width, height );
+ } );
+
+ QUnit.test( 'updateEmbedWikitext(): Do nothing if set() not called before.', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ width = 10;
+
+ assert.expect( 0 );
+
+ embed.formatter.getThumbnailWikitext = function () {
+ assert.ok( false, 'formatter.getThumbnailWikitext() should not have been called.' );
+ };
+ embed.updateEmbedWikitext( width );
+ } );
+
+ QUnit.test( 'updateEmbedWikitext():', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ imageInfo = {},
+ repoInfo = {},
+ caption = '-',
+ info = new mw.mmv.model.EmbedFileInfo( imageInfo, repoInfo, caption ),
+ width = 10;
+
+ embed.set( imageInfo, repoInfo, caption );
+
+ embed.formatter.getThumbnailWikitextFromEmbedFileInfo = function ( i, w ) {
+ assert.deepEqual( i, info, 'EmbedFileInfo passed correctly.' );
+ assert.strictEqual( w, width, 'Width passed correctly.' );
+ };
+ embed.updateEmbedWikitext( width );
+ } );
+
+ QUnit.test( 'getPossibleImageSizesForWikitext()', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ exampleSizes = [
+ // Big wide image
+ {
+ width: 2048, height: 1536,
+ expected: {
+ small: { width: 300, height: 225 },
+ medium: { width: 400, height: 300 },
+ large: { width: 500, height: 375 },
+ 'default': { width: null, height: null }
+ }
+ },
+
+ // Big tall image
+ {
+ width: 201, height: 1536,
+ expected: {
+ 'default': { width: null, height: null }
+ }
+ },
+
+ // Very small image
+ {
+ width: 15, height: 20,
+ expected: {
+ 'default': { width: null, height: null }
+ }
+ }
+ ],
+ i, cursize, opts;
+ for ( i = 0; i < exampleSizes.length; i++ ) {
+ cursize = exampleSizes[ i ];
+ opts = embed.getPossibleImageSizesForWikitext( cursize.width, cursize.height );
+ assert.deepEqual( opts, cursize.expected, 'We got the expected results out of the size calculation function.' );
+ }
+ } );
+
+ QUnit.test( 'set():', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ src = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ url = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ embedFileInfo = new mw.mmv.model.EmbedFileInfo( title, src, url ),
+ calledSelect = false,
+ width = 15,
+ height = 20;
+
+ embed.utils.updateMenuOptions = function ( sizes, options ) {
+ assert.strictEqual( options.length, 4, 'Options passed correctly.' );
+ };
+ embed.resetCurrentSizeMenuToDefault = function () {
+ assert.ok( true, 'resetCurrentSizeMenuToDefault() is called.' );
+ };
+ embed.utils.getThumbnailUrlPromise = function () {
+ return $.Deferred().resolve().promise();
+ };
+ embed.updateEmbedHtml = function () {
+ assert.ok( true, 'updateEmbedHtml() is called after data is collected.' );
+ };
+ embed.select = function () {
+ calledSelect = true;
+ };
+
+ assert.ok( !embed.embedFileInfo, 'embedFileInfo not set yet.' );
+
+ embed.set( { width: width, height: height }, embedFileInfo );
+
+ assert.ok( embed.embedFileInfo, 'embedFileInfo correctly set.' );
+ assert.strictEqual( embed.isSizeMenuDefaultReset, false, 'Reset flag cleared.' );
+ assert.strictEqual( calledSelect, true, 'select() is called' );
+ } );
+
+ QUnit.test( 'empty():', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ width = 15,
+ height = 20;
+
+ embed.formatter = {
+ getThumbnailWikitextFromEmbedFileInfo: function () { return 'wikitext'; },
+ getThumbnailHtml: function () { return 'html'; }
+ };
+
+ embed.set( {}, {} );
+ embed.updateEmbedHtml( { url: 'x' }, width, height );
+ embed.updateEmbedWikitext( width );
+
+ assert.notStrictEqual( embed.embedTextHtml.getValue(), '', 'embedTextHtml is not empty.' );
+ assert.notStrictEqual( embed.embedTextWikitext.getValue(), '', 'embedTextWikitext is not empty.' );
+
+ embed.empty();
+
+ assert.strictEqual( embed.embedTextHtml.getValue(), '', 'embedTextHtml is empty.' );
+ assert.strictEqual( embed.embedTextWikitext.getValue(), '', 'embedTextWikitext is empty.' );
+ assert.ok( !embed.embedSizeSwitchHtml.getMenu().isVisible(), 'Html size menu should be hidden.' );
+ assert.ok( !embed.embedSizeSwitchWikitext.getMenu().isVisible(), 'Wikitext size menu should be hidden.' );
+ } );
+
+ QUnit.test( 'attach()/unattach():', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf ),
+ title = mw.Title.newFromText( 'File:Foobar.jpg' ),
+ src = 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ url = 'https://commons.wikimedia.org/wiki/File:Foobar.jpg',
+ embedFileInfo = new mw.mmv.model.EmbedFileInfo( title, src, url ),
+ width = 15,
+ height = 20;
+
+ embed.set( { width: width, height: height }, embedFileInfo );
+
+ embed.selectAllOnEvent = function () {
+ assert.ok( false, 'selectAllOnEvent should not have been called.' );
+ };
+ embed.handleTypeSwitch = function () {
+ assert.ok( false, 'handleTypeSwitch should not have been called.' );
+ };
+ embed.handleSizeSwitch = function () {
+ assert.ok( false, 'handleTypeSwitch should not have been called.' );
+ };
+
+ // Triggering action events before attaching should do nothing
+ // use of focus() would run into jQuery bug #14740 and similar issues
+ embed.embedTextHtml.$element.find( 'textarea' ).triggerHandler( 'focus' );
+ embed.embedTextWikitext.$element.find( 'textarea' ).triggerHandler( 'focus' );
+ embed.embedSwitch.emit( 'select' );
+ embed.embedSizeSwitchHtml.getMenu().emit(
+ 'choose', embed.embedSizeSwitchHtml.getMenu().findSelectedItem() );
+ embed.embedSizeSwitchWikitext.getMenu().emit(
+ 'choose', embed.embedSizeSwitchWikitext.getMenu().findSelectedItem() );
+
+ embed.selectAllOnEvent = function () {
+ assert.ok( true, 'selectAllOnEvent was called.' );
+ };
+ embed.handleTypeSwitch = function () {
+ assert.ok( true, 'handleTypeSwitch was called.' );
+ };
+ embed.handleSizeSwitch = function () {
+ assert.ok( true, 'handleTypeSwitch was called.' );
+ };
+
+ embed.attach();
+
+ // Action events should be handled now
+ embed.embedTextHtml.$element.find( 'textarea' ).triggerHandler( 'focus' );
+ embed.embedTextWikitext.$element.find( 'textarea' ).triggerHandler( 'focus' );
+ embed.embedSwitch.emit( 'select' );
+ embed.embedSizeSwitchHtml.getMenu().emit(
+ 'choose', embed.embedSizeSwitchHtml.getMenu().findSelectedItem() );
+ embed.embedSizeSwitchWikitext.getMenu().emit(
+ 'choose', embed.embedSizeSwitchWikitext.getMenu().findSelectedItem() );
+
+ // Test the unattach part
+ embed.selectAllOnEvent = function () {
+ assert.ok( false, 'selectAllOnEvent should not have been called.' );
+ };
+ embed.handleTypeSwitch = function () {
+ assert.ok( false, 'handleTypeSwitch should not have been called.' );
+ };
+ embed.handleSizeSwitch = function () {
+ assert.ok( false, 'handleTypeSwitch should not have been called.' );
+ };
+
+ embed.unattach();
+
+ // Triggering action events now that we are unattached should do nothing
+ embed.embedTextHtml.$element.find( 'textarea' ).triggerHandler( 'focus' );
+ embed.embedTextWikitext.$element.find( 'textarea' ).triggerHandler( 'focus' );
+ embed.embedSwitch.emit( 'select' );
+ embed.embedSizeSwitchHtml.getMenu().emit(
+ 'choose', embed.embedSizeSwitchHtml.getMenu().findSelectedItem() );
+ embed.embedSizeSwitchWikitext.getMenu().emit(
+ 'choose', embed.embedSizeSwitchWikitext.getMenu().findSelectedItem() );
+ } );
+
+ QUnit.test( 'handleTypeSwitch():', function ( assert ) {
+ var embed = new mw.mmv.ui.reuse.Embed( $qf );
+
+ assert.strictEqual( embed.isSizeMenuDefaultReset, false, 'Reset flag intialized correctly.' );
+
+ embed.resetCurrentSizeMenuToDefault = function () {
+ assert.ok( true, 'resetCurrentSizeMenuToDefault() called.' );
+ };
+
+ // HTML selected
+ embed.handleTypeSwitch( { getData: function () { return 'html'; } } );
+
+ assert.strictEqual( embed.isSizeMenuDefaultReset, true, 'Reset flag updated correctly.' );
+ assert.ok( !embed.embedSizeSwitchWikitext.getMenu().isVisible(), 'Wikitext size menu should be hidden.' );
+
+ embed.resetCurrentSizeMenuToDefault = function () {
+ assert.ok( false, 'resetCurrentSizeMenuToDefault() should not have been called.' );
+ };
+
+ // Wikitext selected, we are done resetting defaults
+ embed.handleTypeSwitch( { getData: function () { return 'wikitext'; } } );
+
+ assert.strictEqual( embed.isSizeMenuDefaultReset, true, 'Reset flag updated correctly.' );
+ assert.ok( !embed.embedSizeSwitchHtml.getMenu().isVisible(), 'HTML size menu should be hidden.' );
+ } );
+
+ QUnit.test( 'Logged out', function ( assert ) {
+ var embed,
+ oldUserIsAnon = mw.user.isAnon;
+
+ mw.user.isAnon = function () { return true; };
+
+ embed = new mw.mmv.ui.reuse.Embed( $qf );
+
+ assert.ok( !embed.embedSizeSwitchWikitext.$element.hasClass( 'active' ), 'Wikitext widget should be hidden.' );
+ assert.ok( embed.embedSizeSwitchHtml.$element.hasClass( 'active' ), 'HTML widget should be visible.' );
+ assert.ok( !embed.embedTextWikitext.$element.hasClass( 'active' ), 'Wikitext input should be hidden.' );
+ assert.ok( embed.embedTextHtml.$element.hasClass( 'active' ), 'HTML input should be visible.' );
+
+ mw.user.isAnon = oldUserIsAnon;
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.share.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.share.test.js
new file mode 100644
index 00000000..5757d35b
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.share.test.js
@@ -0,0 +1,95 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ function makeShare() {
+ return new mw.mmv.ui.reuse.Share( $( '#qunit-fixture' ) );
+ }
+
+ QUnit.module( 'mmv.ui.reuse.share', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var share = makeShare();
+
+ assert.ok( share, 'Share UI element is created.' );
+ assert.strictEqual( share.$pane.length, 1, 'Pane div created.' );
+ assert.ok( share.pageInput, 'Text field created.' );
+ assert.ok( share.$pageLink, 'Link created.' );
+ } );
+
+ QUnit.test( 'set()/empty():', function ( assert ) {
+ var share = makeShare(),
+ image = { // fake mw.mmv.model.Image
+ title: new mw.Title( 'File:Foobar.jpg' ),
+ url: 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ descriptionUrl: '//commons.wikimedia.org/wiki/File:Foobar.jpg'
+ };
+
+ assert.notStrictEqual( !share.pageInput.getValue(), '', 'pageInput is empty.' );
+
+ share.select = function () {
+ assert.ok( true, 'Text has been selected after data is set.' );
+ };
+
+ share.set( image );
+
+ assert.notStrictEqual( share.pageInput.getValue(), '', 'pageInput is not empty.' );
+
+ share.empty();
+
+ assert.notStrictEqual( !share.pageInput.getValue(), '', 'pageInput is empty.' );
+ } );
+
+ QUnit.test( 'attach()/unattach():', function ( assert ) {
+ var share = makeShare(),
+ image = {
+ title: new mw.Title( 'File:Foobar.jpg' ),
+ url: 'https://upload.wikimedia.org/wikipedia/commons/3/3a/Foobar.jpg',
+ descriptionUrl: '//commons.wikimedia.org/wiki/File:Foobar.jpg'
+ };
+
+ share.set( image );
+
+ share.selectAllOnEvent = function () {
+ assert.ok( false, 'selectAllOnEvent should not have been called.' );
+ };
+
+ // Triggering action events before attaching should do nothing
+ // use of focus() would run into jQuery bug #14740 and similar issues
+ share.pageInput.$element.find( 'input' ).triggerHandler( 'focus' );
+
+ share.selectAllOnEvent = function () {
+ assert.ok( true, 'selectAllOnEvent was called.' );
+ };
+
+ share.attach();
+
+ // Action events should be handled now
+ share.pageInput.$element.find( 'input' ).triggerHandler( 'focus' );
+
+ // Test the unattach part
+ share.selectAllOnEvent = function () {
+ assert.ok( false, 'selectAllOnEvent should not have been called.' );
+ };
+
+ share.unattach();
+
+ // Triggering action events now that we are unattached should do nothing
+ share.pageInput.$element.find( 'input' ).triggerHandler( 'focus' );
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.tab.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.tab.test.js
new file mode 100644
index 00000000..9bc7c4fa
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.tab.test.js
@@ -0,0 +1,43 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ var $fixture = $( '#qunit-fixture' );
+
+ function makeReuseTab() {
+ return new mw.mmv.ui.reuse.Tab( $( '<div>' ).appendTo( $fixture ), $fixture );
+ }
+
+ QUnit.module( 'mmv.ui.reuse.Tab', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Object creation, UI construction and basic funtionality', function ( assert ) {
+ var reuseTab = makeReuseTab();
+
+ assert.ok( reuseTab, 'Reuse UI element is created.' );
+ assert.strictEqual( reuseTab.$pane.length, 1, 'Pane created.' );
+
+ assert.ok( !reuseTab.$pane.hasClass( 'active' ), 'Tab is not active.' );
+
+ reuseTab.show();
+
+ assert.ok( reuseTab.$pane.hasClass( 'active' ), 'Tab is active.' );
+
+ reuseTab.hide();
+
+ assert.ok( !reuseTab.$pane.hasClass( 'active' ), 'Tab is not active.' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.utils.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.utils.test.js
new file mode 100644
index 00000000..07967dd9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.reuse.utils.test.js
@@ -0,0 +1,117 @@
+/*
+ * This file is part of the MediaWiki extension MultimediaViewer.
+ *
+ * MultimediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MultimediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MultimediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mw.mmv.ui.reuse.utils', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var utils = new mw.mmv.ui.Utils();
+
+ assert.ok( utils, 'ReuseUtils object is created.' );
+ } );
+
+ QUnit.test( 'createPulldownMenu():', function ( assert ) {
+ var utils = new mw.mmv.ui.Utils(),
+ menuItems = [ 'original', 'small', 'medium', 'large' ],
+ def = 'large',
+ menu = utils.createPulldownMenu(
+ menuItems,
+ [ 'mw-mmv-download-size' ],
+ def
+ ),
+ options = menu.getMenu().getItems(),
+ i, data;
+
+ assert.strictEqual( options.length, 4, 'Menu has correct number of items.' );
+
+ for ( i = 0; i < menuItems.length; i++ ) {
+ data = options[ i ].getData();
+
+ assert.strictEqual( data.name, menuItems[ i ], 'Correct item name on the list.' );
+ assert.strictEqual( data.height, null, 'Correct item height on the list.' );
+ assert.strictEqual( data.width, null, 'Correct item width on the list.' );
+ }
+
+ assert.strictEqual( menu.getMenu().findSelectedItem(), options[ 3 ], 'Default set correctly.' );
+ } );
+
+ QUnit.test( 'updateMenuOptions():', function ( assert ) {
+ var utils = new mw.mmv.ui.Utils(),
+ menu = utils.createPulldownMenu(
+ [ 'original', 'small', 'medium', 'large' ],
+ [ 'mw-mmv-download-size' ],
+ 'original'
+ ),
+ options = menu.getMenu().getItems(),
+ width = 700,
+ height = 500,
+ sizes = utils.getPossibleImageSizesForHtml( width, height ),
+ oldMessage = mw.message;
+
+ mw.message = function ( messageKey ) {
+ assert.ok( messageKey.match( /^multimediaviewer-(small|medium|original|embed-dimensions)/ ), 'messageKey passed correctly.' );
+
+ return { text: $.noop };
+ };
+
+ utils.updateMenuOptions( sizes, options );
+
+ mw.message = oldMessage;
+ } );
+
+ QUnit.test( 'getPossibleImageSizesForHtml()', function ( assert ) {
+ var utils = new mw.mmv.ui.Utils(),
+ exampleSizes = [
+ // Big wide image
+ {
+ width: 2048, height: 1536,
+ expected: {
+ small: { width: 193, height: 145 },
+ medium: { width: 640, height: 480 },
+ large: { width: 1200, height: 900 },
+ original: { width: 2048, height: 1536 }
+ }
+ },
+
+ // Big tall image
+ {
+ width: 201, height: 1536,
+ expected: {
+ small: { width: 19, height: 145 },
+ medium: { width: 63, height: 480 },
+ large: { width: 118, height: 900 },
+ original: { width: 201, height: 1536 }
+ }
+ },
+
+ // Very small image
+ {
+ width: 15, height: 20,
+ expected: {
+ original: { width: 15, height: 20 }
+ }
+ }
+ ],
+ i, cursize, opts;
+ for ( i = 0; i < exampleSizes.length; i++ ) {
+ cursize = exampleSizes[ i ];
+ opts = utils.getPossibleImageSizesForHtml( cursize.width, cursize.height );
+ assert.deepEqual( opts, cursize.expected, 'We got the expected results out of the size calculation function.' );
+ }
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
new file mode 100644
index 00000000..7ebe04e9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.stripeButtons.test.js
@@ -0,0 +1,76 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.StripeButtons', QUnit.newMwEnvironment() );
+
+ function createStripeButtons() {
+ var fixture = $( '#qunit-fixture' );
+ return new mw.mmv.ui.StripeButtons( fixture );
+ }
+
+ QUnit.test( 'Sanity test, object creation and UI construction', function ( assert ) {
+ var buttons,
+ oldMwUserIsAnon = mw.user.isAnon;
+
+ // first pretend we are anonymous
+ mw.user.isAnon = function () { return true; };
+ buttons = createStripeButtons();
+
+ assert.ok( buttons, 'UI element is created.' );
+ assert.ok( buttons.buttons.$descriptionPage, 'File page button created for anon.' );
+
+ // now pretend we are logged in
+ mw.user.isAnon = function () { return false; };
+ buttons = createStripeButtons();
+
+ assert.strictEqual( buttons.buttons.$descriptionPage.length, 1, 'File page button created for logged in.' );
+
+ mw.user.isAnon = oldMwUserIsAnon;
+ } );
+
+ QUnit.test( 'set()/empty() sanity test:', function ( assert ) {
+ var buttons = createStripeButtons(),
+ fakeImageInfo = { descriptionUrl: '//commons.wikimedia.org/wiki/File:Foo.jpg' },
+ fakeRepoInfo = { displayName: 'Wikimedia Commons', isCommons: function () { return true; } };
+
+ buttons.set( fakeImageInfo, fakeRepoInfo );
+ buttons.empty();
+
+ assert.ok( true, 'No error on set()/empty().' );
+ } );
+
+ QUnit.test( 'Description page button', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ buttons = new mw.mmv.ui.StripeButtons( $qf ),
+ button = buttons.buttons.$descriptionPage,
+ descriptionUrl = 'http://example.com/desc',
+ imageInfo = { descriptionUrl: descriptionUrl },
+ repoInfo = { isCommons: function () { return false; } };
+
+ buttons.setDescriptionPageButton( imageInfo, repoInfo );
+
+ assert.ok( !button.hasClass( 'mw-mmv-repo-button-commons' ), 'Button does not have commons class non-Commons files' );
+ assert.strictEqual( button.find( 'a' ).addBack().filter( 'a' ).attr( 'href' ), descriptionUrl, 'Description page link is correct' );
+
+ repoInfo.isCommons = function () { return true; };
+ buttons.setDescriptionPageButton( imageInfo, repoInfo );
+
+ assert.ok( button.hasClass( 'mw-mmv-repo-button-commons' ), 'Button commons class for Commons files' );
+ } );
+
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.test.js
new file mode 100644
index 00000000..7f78a060
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.test.js
@@ -0,0 +1,109 @@
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui', QUnit.newMwEnvironment( {
+ setup: function () {
+ this.clock = this.sandbox.useFakeTimers();
+ }
+ } ) );
+
+ QUnit.test( 'handleEvent()', function ( assert ) {
+ var element = new mw.mmv.ui.Element( $( '<div>' ) );
+
+ element.handleEvent( 'mmv-foo', function () {
+ assert.ok( true, 'Event is handled' );
+ } );
+
+ $( document ).trigger( new $.Event( 'mmv-foo' ) );
+
+ element.clearEvents();
+
+ $( document ).trigger( new $.Event( 'mmv-foo' ) );
+ } );
+
+ QUnit.test( 'setInlineStyle()', function ( assert ) {
+ var element = new mw.mmv.ui.Element( $( '<div>' ) ),
+ $testDiv = $( '<div id="mmv-testdiv">!!!</div>' ).appendTo( '#qunit-fixture' );
+
+ assert.ok( $testDiv.is( ':visible' ), 'Test div is visible' );
+
+ element.setInlineStyle( 'test', '#mmv-testdiv { display: none; }' );
+
+ assert.ok( !$testDiv.is( ':visible' ), 'Test div is hidden by inline style' );
+
+ element.setInlineStyle( 'test', null );
+
+ assert.ok( $testDiv.is( ':visible' ), 'Test div is visible again' );
+ } );
+
+ QUnit.test( 'setTimer()/clearTimer()/resetTimer()', function ( assert ) {
+ var element = new mw.mmv.ui.Element( $( '<div>' ) ),
+ element2 = new mw.mmv.ui.Element( $( '<div>' ) ),
+ spy = this.sandbox.spy(),
+ spy2 = this.sandbox.spy();
+
+ element.setTimer( 'foo', spy, 10 );
+ this.clock.tick( 100 );
+ assert.ok( spy.called, 'Timeout callback was called' );
+ assert.ok( spy.calledOnce, 'Timeout callback was called once' );
+ assert.ok( spy.calledOn( element ), 'Timeout callback was called on the element' );
+
+ spy = this.sandbox.spy();
+ element.setTimer( 'foo', spy, 10 );
+ element.setTimer( 'foo', spy2, 20 );
+ this.clock.tick( 100 );
+ assert.ok( !spy.called, 'Old timeout callback was not called after update' );
+ assert.ok( spy2.called, 'New timeout callback was called after update' );
+
+ spy = this.sandbox.spy();
+ spy2 = this.sandbox.spy();
+ element.setTimer( 'foo', spy, 10 );
+ element.setTimer( 'bar', spy2, 20 );
+ this.clock.tick( 100 );
+ assert.ok( spy.called && spy2.called, 'Timeouts with different names do not conflict' );
+
+ spy = this.sandbox.spy();
+ spy2 = this.sandbox.spy();
+ element.setTimer( 'foo', spy, 10 );
+ element2.setTimer( 'foo', spy2, 20 );
+ this.clock.tick( 100 );
+ assert.ok( spy.called && spy2.called, 'Timeouts in different elements do not conflict' );
+
+ spy = this.sandbox.spy();
+ element.setTimer( 'foo', spy, 10 );
+ element.clearTimer( 'foo' );
+ this.clock.tick( 100 );
+ assert.ok( !spy.called, 'Timeout is invalidated by clearing' );
+
+ spy = this.sandbox.spy();
+ element.setTimer( 'foo', spy, 100 );
+ this.clock.tick( 80 );
+ element.resetTimer( 'foo' );
+ this.clock.tick( 80 );
+ assert.ok( !spy.called, 'Timeout is reset' );
+ this.clock.tick( 80 );
+ assert.ok( spy.called, 'Timeout works after reset' );
+
+ spy = this.sandbox.spy();
+ element.setTimer( 'foo', spy, 100 );
+ this.clock.tick( 80 );
+ element.resetTimer( 'foo', 200 );
+ this.clock.tick( 180 );
+ assert.ok( !spy.called, 'Timeout is reset to the designated delay' );
+ this.clock.tick( 80 );
+ assert.ok( spy.called, 'Timeout works after changing the delay' );
+ } );
+
+ QUnit.test( 'correctEW()', function ( assert ) {
+ var element = new mw.mmv.ui.Element( $( '<div>' ) );
+
+ element.isRTL = this.sandbox.stub().returns( true );
+
+ assert.strictEqual( element.correctEW( 'e' ), 'w', 'e (east) is flipped' );
+ assert.strictEqual( element.correctEW( 'ne' ), 'nw', 'ne (northeast) is flipped' );
+ assert.strictEqual( element.correctEW( 'W' ), 'E', 'uppercase is flipped' );
+ assert.strictEqual( element.correctEW( 's' ), 's', 'non-horizontal directions are ignored' );
+
+ element.isRTL.returns( false );
+
+ assert.strictEqual( element.correctEW( 'e' ), 'e', 'no flipping in LTR documents' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.tipsyDialog.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.tipsyDialog.test.js
new file mode 100644
index 00000000..3d4044ec
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.tipsyDialog.test.js
@@ -0,0 +1,68 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.tipsyDialog', QUnit.newMwEnvironment( {
+ setup: function () {
+ // remove tipsy elements left behind by other tests so these tests don't find them by accident
+ // tipsy puts its elements to the end of the body so clearing the fixture doesn't get rid of them
+ $( '.mw-mmv-tipsy-dialog' ).remove();
+ }
+ } ) );
+
+ QUnit.test( 'Open/close', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $anchor = $( '<div>' ).appendTo( $qf ),
+ dialog = new mw.mmv.ui.TipsyDialog( $anchor );
+
+ assert.ok( !$( '.mw-mmv-tipsy-dialog' ).length, 'dialog is not shown' );
+ dialog.open();
+ assert.ok( $( '.mw-mmv-tipsy-dialog' ).length, 'dialog is shown' );
+ dialog.close();
+ assert.ok( !$( '.mw-mmv-tipsy-dialog' ).length, 'dialog is not shown' );
+ } );
+
+ QUnit.test( 'setContent', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $anchor = $( '<div>' ).appendTo( $qf ),
+ titleText = 'This is a title',
+ bodyText = 'This is the <b class="typsyDialogTest-123">body</b>',
+ dialog = new mw.mmv.ui.TipsyDialog( $anchor );
+
+ dialog.setContent( titleText, bodyText );
+ dialog.open();
+ assert.ok( $( '.mw-mmv-tipsy-dialog' ).text().match( titleText ), 'Title is included' );
+ assert.ok( $( '.mw-mmv-tipsy-dialog' ).html().match( bodyText ), 'Body is included' );
+ assert.ok( $( '.mw-mmv-tipsy-dialog' ).find( '.typsyDialogTest-123' ).length, 'Body is HTML' );
+ } );
+
+ QUnit.test( 'Close on click', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ $anchor = $( '<div>' ).appendTo( $qf ),
+ dialog = new mw.mmv.ui.TipsyDialog( $anchor );
+
+ dialog.open();
+ assert.ok( $( '.mw-mmv-tipsy-dialog' ).length, 'dialog is shown initially' );
+ dialog.getPopup().click();
+ assert.ok( $( '.mw-mmv-tipsy-dialog' ).length, 'dialog is not hidden when clicked' );
+ dialog.getPopup().find( '.mw-mmv-tipsy-dialog-disable' ).click();
+ assert.ok( !$( '.mw-mmv-tipsy-dialog' ).length, 'dialog is hidden when close icon is clicked' );
+ dialog.open();
+ $qf.click();
+ assert.ok( !$( '.mw-mmv-tipsy-dialog' ).length, 'dialog is hidden when clicked outside' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.truncatableTextField.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.truncatableTextField.test.js
new file mode 100644
index 00000000..6516b2b6
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.truncatableTextField.test.js
@@ -0,0 +1,64 @@
+/*
+ * This file is part of the MediaWiki extension MediaViewer.
+ *
+ * MediaViewer is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * MediaViewer is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with MediaViewer. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+( function ( mw, $ ) {
+ QUnit.module( 'mmv.ui.TruncatableTextField', QUnit.newMwEnvironment() );
+
+ /**
+ * Create a textfield that can contain exactly width x height characters
+ *
+ * @param {number} width
+ * @param {number} height
+ * @param {jQuery} $qf fixture element
+ * @param {Object} sandbox sinon instance
+ * @return {TruncatableTextField}
+ */
+ function getField( width, height, $qf, sandbox ) {
+ var $container = $( '<div>' ).appendTo( $qf ),
+ $element = $( '<span>' ),
+ ttf = new mw.mmv.ui.TruncatableTextField( $container, $element, {} );
+
+ ttf.htmlUtils.htmlToTextWithLinks = sandbox.stub().returnsArg( 0 );
+
+ $container.css( {
+ fontFamily: 'monospace',
+ lineHeight: 1,
+ width: width + 'ch',
+ height: height + 'em'
+ } );
+
+ return ttf;
+ }
+
+ QUnit.test( 'Normal constructor', function ( assert ) {
+ var $container = $( '#qunit-fixture' ),
+ $element = $( '<div>' ).appendTo( $container ).text( 'This is a unique string.' ),
+ ttf = new mw.mmv.ui.TruncatableTextField( $container, $element );
+
+ assert.strictEqual( ttf.$element.text(), 'This is a unique string.', 'The constructor set the element to the right thing.' );
+ assert.strictEqual( ttf.$element.closest( '#qunit-fixture' ).length, 1, 'The constructor put the element into the container.' );
+ } );
+
+ QUnit.test( 'Set method', function ( assert ) {
+ var $qf = $( '#qunit-fixture' ),
+ ttf = getField( 3, 2, $qf, this.sandbox );
+
+ ttf.shrink = this.sandbox.stub();
+ ttf.set( 'abc' );
+ assert.strictEqual( ttf.$element.text(), 'abc', 'Text is set accurately.' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.viewingOptions.test.js b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.viewingOptions.test.js
new file mode 100644
index 00000000..ee1a9e29
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/tests/qunit/mmv/ui/mmv.ui.viewingOptions.test.js
@@ -0,0 +1,139 @@
+( function ( mw, $ ) {
+ function makeDialog( initialise ) {
+ var $qf = $( '#qunit-fixture' ),
+ $button = $( '<div>' ).appendTo( $qf ),
+ dialog = new mw.mmv.ui.OptionsDialog( $qf, $button, { setMediaViewerEnabledOnClick: $.noop } );
+
+ if ( initialise ) {
+ dialog.initPanel();
+ }
+
+ return dialog;
+ }
+
+ QUnit.module( 'mmv.ui.viewingOptions', QUnit.newMwEnvironment() );
+
+ QUnit.test( 'Constructor sanity test', function ( assert ) {
+ var dialog = makeDialog();
+ assert.ok( dialog, 'Dialog is created successfully' );
+ } );
+
+ QUnit.test( 'Initialisation functions', function ( assert ) {
+ var dialog = makeDialog( true );
+
+ assert.ok( dialog.$disableDiv, 'Disable div is created.' );
+ assert.ok( dialog.$enableDiv, 'Enable div is created.' );
+ assert.ok( dialog.$disableConfirmation, 'Disable confirmation is created.' );
+ assert.ok( dialog.$enableConfirmation, 'Enable confirmation is created.' );
+ } );
+
+ QUnit.test( 'Disable', function ( assert ) {
+ var $header, $icon, $text, $textHeader, $textBody,
+ $submitButton, $cancelButton, $aboutLink,
+ dialog = makeDialog(),
+ deferred = $.Deferred();
+
+ this.sandbox.stub( dialog.config, 'setMediaViewerEnabledOnClick', function () {
+ return deferred;
+ } );
+
+ dialog.initDisableDiv();
+
+ $header = dialog.$disableDiv.find( 'h3.mw-mmv-options-dialog-header' );
+ $icon = dialog.$disableDiv.find( 'div.mw-mmv-options-icon' );
+
+ $text = dialog.$disableDiv.find( 'div.mw-mmv-options-text' );
+ $textHeader = $text.find( 'p.mw-mmv-options-text-header' );
+ $textBody = $text.find( 'p.mw-mmv-options-text-body' );
+ $aboutLink = $text.find( 'a.mw-mmv-project-info-link' );
+ $submitButton = dialog.$disableDiv.find( 'button.mw-mmv-options-submit-button' );
+ $cancelButton = dialog.$disableDiv.find( 'button.mw-mmv-options-cancel-button' );
+
+ assert.strictEqual( $header.length, 1, 'Disable header created successfully.' );
+ assert.strictEqual( $header.text(), 'Disable Media Viewer?', 'Disable header has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $icon.length, 1, 'Icon created successfully.' );
+ assert.strictEqual( $icon.html(), '&nbsp;', 'Icon has a blank space in it.' );
+
+ assert.ok( $text, 'Text div created successfully.' );
+ assert.strictEqual( $textHeader.length, 1, 'Text header created successfully.' );
+ assert.strictEqual( $textHeader.text(), 'Skip this viewing feature for all files.', 'Text header has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $textBody.length, 1, 'Text body created successfully.' );
+ assert.strictEqual( $textBody.text(), 'You can enable it later through the file details page.', 'Text body has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $aboutLink.length, 1, 'About link created successfully.' );
+ assert.strictEqual( $aboutLink.text(), 'Learn more', 'About link has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $submitButton.length, 1, 'Disable button created successfully.' );
+ assert.strictEqual( $submitButton.text(), 'Disable Media Viewer', 'Disable button has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $cancelButton.length, 1, 'Cancel button created successfully.' );
+ assert.strictEqual( $cancelButton.text(), 'Cancel', 'Cancel button has correct text (if this fails, it may be due to i18n differences)' );
+
+ $submitButton.click();
+
+ assert.ok( !dialog.$disableConfirmation.hasClass( 'mw-mmv-shown' ), 'Disable confirmation not shown yet' );
+ assert.ok( !dialog.$dialog.hasClass( 'mw-mmv-disable-confirmation-shown' ), 'Disable confirmation not shown yet' );
+
+ // Pretend that the async call in mmv.js succeeded
+ deferred.resolve();
+
+ // The confirmation should appear
+ assert.ok( dialog.$disableConfirmation.hasClass( 'mw-mmv-shown' ), 'Disable confirmation shown' );
+ assert.ok( dialog.$dialog.hasClass( 'mw-mmv-disable-confirmation-shown' ), 'Disable confirmation shown' );
+ } );
+
+ QUnit.test( 'Enable', function ( assert ) {
+ var $header, $icon, $text, $textHeader, $aboutLink,
+ $submitButton, $cancelButton,
+ dialog = makeDialog(),
+ deferred = $.Deferred();
+
+ this.sandbox.stub( dialog.config, 'setMediaViewerEnabledOnClick', function () {
+ return deferred;
+ } );
+
+ dialog.initEnableDiv();
+
+ $header = dialog.$enableDiv.find( 'h3.mw-mmv-options-dialog-header' );
+ $icon = dialog.$enableDiv.find( 'div.mw-mmv-options-icon' );
+
+ $text = dialog.$enableDiv.find( 'div.mw-mmv-options-text' );
+ $textHeader = $text.find( 'p.mw-mmv-options-text-header' );
+ $aboutLink = $text.find( 'a.mw-mmv-project-info-link' );
+ $submitButton = dialog.$enableDiv.find( 'button.mw-mmv-options-submit-button' );
+ $cancelButton = dialog.$enableDiv.find( 'button.mw-mmv-options-cancel-button' );
+
+ assert.strictEqual( $header.length, 1, 'Enable header created successfully.' );
+ assert.strictEqual( $header.text(), 'Enable Media Viewer?', 'Enable header has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $icon.length, 1, 'Icon created successfully.' );
+ assert.strictEqual( $icon.html(), '&nbsp;', 'Icon has a blank space in it.' );
+
+ assert.ok( $text, 'Text div created successfully.' );
+ assert.strictEqual( $textHeader.length, 1, 'Text header created successfully.' );
+ assert.strictEqual( $textHeader.text(), 'Enable this media viewing feature for all files by default.', 'Text header has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $aboutLink.length, 1, 'About link created successfully.' );
+ assert.strictEqual( $aboutLink.text(), 'Learn more', 'About link has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $submitButton.length, 1, 'Enable button created successfully.' );
+ assert.strictEqual( $submitButton.text(), 'Enable Media Viewer', 'Enable button has correct text (if this fails, it may be due to i18n differences)' );
+
+ assert.strictEqual( $cancelButton.length, 1, 'Cancel button created successfully.' );
+ assert.strictEqual( $cancelButton.text(), 'Cancel', 'Cancel button has correct text (if this fails, it may be due to i18n differences)' );
+
+ $submitButton.click();
+
+ assert.ok( !dialog.$enableConfirmation.hasClass( 'mw-mmv-shown' ), 'Enable confirmation not shown yet' );
+ assert.ok( !dialog.$dialog.hasClass( 'mw-mmv-enable-confirmation-shown' ), 'Enable confirmation not shown yet' );
+
+ // Pretend that the async call in mmv.js succeeded
+ deferred.resolve();
+
+ // The confirmation should appear
+ assert.ok( dialog.$enableConfirmation.hasClass( 'mw-mmv-shown' ), 'Enable confirmation shown' );
+ assert.ok( dialog.$dialog.hasClass( 'mw-mmv-enable-confirmation-shown' ), 'Enable confirmation shown' );
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/MultimediaViewer/version b/www/wiki/extensions/MultimediaViewer/version
new file mode 100644
index 00000000..0ba061c1
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/version
@@ -0,0 +1,4 @@
+MultimediaViewer: REL1_31
+2018-05-11T20:11:31
+
+1273d3e
diff --git a/www/wiki/extensions/MultimediaViewer/viewer-ltr.svg b/www/wiki/extensions/MultimediaViewer/viewer-ltr.svg
new file mode 100644
index 00000000..b42b96c9
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/viewer-ltr.svg
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="264" height="162" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 264 162">
+ <defs>
+ <path id="a" fill="#eaecf0" d="M0 5h22v6H0z"/>
+ </defs>
+ <path fill="#fff" d="M24.833 151.362l-11.467 9.995L.5 151.749V.5h263v151.749l-9 6.705V42.5h-39v112.6l-4.393-3.731-7.607 5.33V42.5h-155v110.849l-9.751 8.031"/>
+ <path fill="#eaecf0" d="M263 1v150.998l-8 5.96V42h-40v112.019l-3.274-2.779-.589-.499-.633.44-6.504 4.557V42H48v111.099l-9.257 7.661-13.295-9.569-.644-.465-.598.521-10.864 9.47L1 151.499V1h262m1-1H0v152l13.391 10 11.473-10 13.891 10L49 153.6V43h154v114.66l8.078-5.66 4.922 4.18V43h38v116.95l10-7.45V0z"/>
+ <path fill="#eaecf0" d="M203 157.66V43H49v110.6l2.145-1.6L63.7 162l13.809-10 14.229 10 12.972-10 12.973 10 13.811-10 12.136 10 13.391-10 14.229 10 12.972-10 12.974 10 5.804-4.34zM11 36c0-7.732 6.268-14 14-14s14 6.268 14 14-6.268 14-14 14-14-6.268-14-14zm243 123.95V43h-38v113.18l7.551 5.82 13.811-10 13.891 10 2.747-2.05zM38 107V72H13v35h25zM232.51 5h26v6h-26V5z"/>
+ <use x="208.51" xlink:href="#a"/>
+ <path fill="#eaecf0" d="M142 6v4H50V6h92m1-1H49v6h94V5z"/>
+ <use x="184.51" xlink:href="#a"/>
+ <use width="13" x="161.51" xlink:href="#a"/>
+ <use width="6" x="176.51" xlink:href="#a"/>
+ <use width="6" x="153.51" xlink:href="#a"/>
+ <use width="32" x="9" xlink:href="#a"/>
+ <path fill="#eaecf0" stroke="#eaecf0" d="M2 14.5h260"/>
+ <path fill="#a2a9b1" d="M221 73h24v1h-24v-1z"/>
+ <use width="2" height="2" x="52" y="2"/>
+ <path fill="#eaecf0" d="M38 59v-5H13v5h25z"/>
+ <path fill="#8acdff" d="M250 47h-30v24h30V47zm-20.268 11h1.08l6.69 6.596 3.634-2.172 5.477 4.557V67h-23.959l7.078-9z"/>
+ <path fill="#fff" d="M54 15h155v128H54V15z"/>
+ <path fill="#36c" d="M204 24H60v112h144V24zm-97.679 50h5.184l32.129 34.005 17.446-10.42 26.28 21.317V119H72.343l33.978-45z"/>
+ <path fill="#fff" d="M191.795 34.937L187.955 31H198v10.067l-3.948-4.221-6.478 6.494L191.21 47H182V36.933l3.637 4.046 6.158-6.042z"/>
+</svg>
diff --git a/www/wiki/extensions/MultimediaViewer/viewer-rtl.svg b/www/wiki/extensions/MultimediaViewer/viewer-rtl.svg
new file mode 100644
index 00000000..e403ab73
--- /dev/null
+++ b/www/wiki/extensions/MultimediaViewer/viewer-rtl.svg
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg xmlns="http://www.w3.org/2000/svg" width="264" height="162" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 264 162">
+ <defs>
+ <path id="a" fill="#eaecf0" d="M0 5h22v6H0z"/>
+ </defs>
+ <path fill="#fff" d="M250.634 161.357l12.866-9.608V.5H.5v151.749l9 6.705V42.5h39v112.6l4.393-3.731 7.607 5.33V42.5h155v110.849l9.751 8.031 13.916-10.018"/>
+ <path fill="#eaecf0" d="M1 1v150.998l8 5.96V42h40v112.019l3.274-2.779.589-.499.633.44L60 155.738V42h156v111.099l9.257 7.661 13.295-9.569.644-.465.598.521 10.864 9.47L263 151.499V1H1M0 0h264v152l-13.391 10-11.473-10-13.891 10L215 153.6V43H61v114.66L52.922 152 48 156.18V43H10v116.95L0 152.5V0z"/>
+ <path fill="#eaecf0" d="M61 157.66V43h154v110.6l-2.145-1.6-12.555 10-13.809-10-14.229 10-12.972-10-12.973 10-13.811-10-12.136 10-13.391-10-14.229 10-12.972-10-12.974 10L61 157.66zM253 36c0-7.732-6.268-14-14-14s-14 6.268-14 14 6.268 14 14 14 14-6.268 14-14zM10 159.95V43h38v113.18L40.449 162l-13.811-10-13.891 10L10 159.95zM226 107V72h25v35h-25zM31.49 5h-26v6h26V5z"/>
+ <use width="264" height="162" x="208.50999" xlink:href="#a" transform="matrix(-1 0 0 1 264 0)"/>
+ <path fill="#eaecf0" d="M122 6v4h92V6h-92m-1-1h94v6h-94V5z"/>
+ <use width="264" height="162" x="184.50999" xlink:href="#a" transform="matrix(-1 0 0 1 264 0)"/>
+ <use width="13" height="162" x="161.50999" xlink:href="#a" transform="matrix(-1 0 0 1 264 0)"/>
+ <use width="6" height="162" x="176.50999" xlink:href="#a" transform="matrix(-1 0 0 1 264 0)"/>
+ <use width="6" height="162" x="153.50999" xlink:href="#a" transform="matrix(-1 0 0 1 264 0)"/>
+ <use width="32" height="162" x="9" xlink:href="#a" transform="matrix(-1 0 0 1 264 0)"/>
+ <path fill="#eaecf0" stroke="#eaecf0" d="M262 14.5H2"/>
+ <path fill="#a2a9b1" d="M43 73H19v1h24v-1z"/>
+ <use width="2" height="2" x="52" y="2" transform="matrix(-1 0 0 1 264 0)"/>
+ <path fill="#eaecf0" d="M226 59v-5h25v5h-25z"/>
+ <path fill="#8acdff" d="M14 47h30v24H14V47zm20.268 11h-1.08l-6.69 6.596-3.634-2.172-5.477 4.557V67h23.959l-7.078-9z"/>
+ <path fill="#fff" d="M210 15H55v128h155V15z"/>
+ <path fill="#36c" d="M60 24h144v112H60V24zm97.679 50h-5.184l-32.129 34.005-17.446-10.42-26.28 21.317V119h115.017l-33.978-45z"/>
+ <path fill="#fff" d="M72.205 34.937L76.045 31H66v10.067l3.948-4.221 6.478 6.494L72.79 47H82V36.933l-3.637 4.046-6.158-6.042z"/>
+</svg>
diff --git a/www/wiki/extensions/NoTitle/NoTitle.body.php b/www/wiki/extensions/NoTitle/NoTitle.body.php
index 30a6f046..79376bb0 100644
--- a/www/wiki/extensions/NoTitle/NoTitle.body.php
+++ b/www/wiki/extensions/NoTitle/NoTitle.body.php
@@ -16,7 +16,7 @@ class NoTitle {
global $wgOut;
$mw = MagicWord::get( 'MAG_NOTITLE' );
if ( $mw->matchAndRemove( $text ) ) {
- $wgOut->addInlineStyle( '.firstHeading, .subtitle, #siteSub, #contentSub, .pagetitle { display: none; }' );
+ $wgOut->addInlineStyle( '.contentHeader, .firstHeading, .subtitle, #siteSub, #contentSub, .pagetitle { display: none; }' );
}
return true;
}
diff --git a/www/wiki/extensions/Nuke/Gruntfile.js b/www/wiki/extensions/Nuke/Gruntfile.js
index acb20a8a..be5d2541 100644
--- a/www/wiki/extensions/Nuke/Gruntfile.js
+++ b/www/wiki/extensions/Nuke/Gruntfile.js
@@ -18,7 +18,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/Nuke/Nuke.alias.php b/www/wiki/extensions/Nuke/Nuke.alias.php
index b9474065..528db578 100644
--- a/www/wiki/extensions/Nuke/Nuke.alias.php
+++ b/www/wiki/extensions/Nuke/Nuke.alias.php
@@ -283,6 +283,11 @@ $specialPageAliases['uk'] = [
'Nuke' => [ 'Масове_вилучення', 'Множественное_удаление' ],
];
+/** Urdu (اردو) */
+$specialPageAliases['ur'] = [
+ 'Nuke' => [ 'اجتماعی_حذف_شدگی' ],
+];
+
/** Vietnamese (Tiếng Việt) */
$specialPageAliases['vi'] = [
'Nuke' => [ 'Xóa_hàng_loạt', 'Xoá_hàng_loạt' ],
diff --git a/www/wiki/extensions/Nuke/composer.json b/www/wiki/extensions/Nuke/composer.json
index 6d8c82ed..afa0dc78 100644
--- a/www/wiki/extensions/Nuke/composer.json
+++ b/www/wiki/extensions/Nuke/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude vendor --exclude node_modules",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/Nuke/ext.nuke.confirm.js b/www/wiki/extensions/Nuke/ext.nuke.confirm.js
new file mode 100644
index 00000000..928e671b
--- /dev/null
+++ b/www/wiki/extensions/Nuke/ext.nuke.confirm.js
@@ -0,0 +1,14 @@
+( function ( mw, $ ) {
+ $( function () {
+ /*global confirm */
+
+ // Confirm nuke
+ $( 'form[name="nukelist"]' ).on( 'submit', function () {
+ var pages = $( this ).find( 'input[name="pages[]"][type="checkbox"]:checked' );
+ if ( pages.length ) {
+ return confirm( mw.msg( 'nuke-confirm', pages.length ) );
+ }
+ } );
+
+ } );
+}( mediaWiki, jQuery ) );
diff --git a/www/wiki/extensions/Nuke/extension.json b/www/wiki/extensions/Nuke/extension.json
index 329d7df8..4d5f9d68 100644
--- a/www/wiki/extensions/Nuke/extension.json
+++ b/www/wiki/extensions/Nuke/extension.json
@@ -7,7 +7,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:Nuke",
"descriptionmsg": "nuke-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"requires": {
"MediaWiki": ">= 1.28.1"
},
@@ -30,6 +30,14 @@
"scripts": [
"ext.nuke.js"
]
+ },
+ "ext.nuke.confirm": {
+ "scripts": [
+ "ext.nuke.confirm.js"
+ ],
+ "messages": [
+ "nuke-confirm"
+ ]
}
},
"ResourceFileModulePaths": {
@@ -48,8 +56,8 @@
"Nuke": "SpecialNuke"
},
"AutoloadClasses": {
- "SpecialNuke": "Nuke_body.php",
- "NukeHooks": "Nuke.hooks.php"
+ "SpecialNuke": "includes/SpecialNuke.php",
+ "NukeHooks": "includes/NukeHooks.php"
},
"manifest_version": 1
}
diff --git a/www/wiki/extensions/Nuke/i18n/ar.json b/www/wiki/extensions/Nuke/i18n/ar.json
index 825138cf..f43657e5 100644
--- a/www/wiki/extensions/Nuke/i18n/ar.json
+++ b/www/wiki/extensions/Nuke/i18n/ar.json
@@ -26,7 +26,12 @@
"nuke-editby": "من إنشاء [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-deleted": "صفحة '''$1''' حذفت.",
"nuke-not-deleted": "صفحة [[:$1]] '''لا''' تحذف.",
+ "nuke-delete-more": "[[Special:Nuke|حذف المزيد من الصفحات]]",
+ "nuke-pattern": "نمط لاسم الصفحة:",
+ "nuke-nopages-global": "لا توجد عناوين صفحات تطابق بحثك.",
"nuke-viewchanges": "عرض التغييرات",
+ "nuke-namespace": "حد للنطاق:",
"nuke-linkoncontribs": "حذف كمي",
- "nuke-linkoncontribs-text": "حذف كمي للصفحات التي يكون هذا المستخدم مؤلفها الوحيد"
+ "nuke-linkoncontribs-text": "حذف كمي للصفحات التي {{GENDER:$1|يكون هذا المستخدم مؤلفها الوحيد|تكون هذه المستخدمة مؤلفتها الوحيدة}}",
+ "nuke-confirm": "أنت على وشك حذف {{PLURAL:$1|صفحة واحدة|$1 صفحة}}، هل أنت متأكد من أنك تريد الحذف؟"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ast.json b/www/wiki/extensions/Nuke/i18n/ast.json
index fbf70dd5..8a8fe604 100644
--- a/www/wiki/extensions/Nuke/i18n/ast.json
+++ b/www/wiki/extensions/Nuke/i18n/ast.json
@@ -26,9 +26,10 @@
"nuke-not-deleted": "La páxina [[:$1]] '''nun se pudo''' desaniciar.",
"nuke-delete-more": "[[Special:Nuke|Desaniciar más páxines]]",
"nuke-pattern": "Patrón pal nome de páxina:",
- "nuke-nopages-global": "Nun hai páxines nueves nos [[Special:RecentChanges|cambios recientes]].",
+ "nuke-nopages-global": "Nun hai títulos de páxina que casen cola gueta.",
"nuke-viewchanges": "ver los cambios",
"nuke-namespace": "Llendar al espaciu de nomes:",
"nuke-linkoncontribs": "desaniciar en masa",
- "nuke-linkoncontribs-text": "Desaniciar en masa les páxines nes qu'esti usuariu ye l'únicu autor"
+ "nuke-linkoncontribs-text": "Desaniciar en masa les páxines nes qu'{{GENDER:$1|esti usuariu ye l'únicu autor|esta usuaria ye la única autora}}",
+ "nuke-confirm": "Tas a piques de desaniciar {{PLURAL:$1|una páxina|$1 páxines}}. ¿Seguro que quies desaniciar?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/be-tarask.json b/www/wiki/extensions/Nuke/i18n/be-tarask.json
index 6436182a..bc6da8ed 100644
--- a/www/wiki/extensions/Nuke/i18n/be-tarask.json
+++ b/www/wiki/extensions/Nuke/i18n/be-tarask.json
@@ -32,5 +32,6 @@
"nuke-viewchanges": "праглядзець зьмены",
"nuke-namespace": "Абмежаваць прасторай назваў:",
"nuke-linkoncontribs": "масавае выдаленьне",
- "nuke-linkoncontribs-text": "Масавае выдаленьне старонак, дзе {{GENDER:$1|гэты ўдзельнік|гэтая ўдзельніца}} зьяўляецца адзіным аўтарам"
+ "nuke-linkoncontribs-text": "Масавае выдаленьне старонак, дзе {{GENDER:$1|гэты ўдзельнік|гэтая ўдзельніца}} зьяўляецца адзіным аўтарам",
+ "nuke-confirm": "Вы зьбіраецеся выдаліць $1 {{PLURAL:$1|старонку|старонкі|старонак}}. Вы ўпэўненыя, што хачаце гэта зрабіць?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/bg.json b/www/wiki/extensions/Nuke/i18n/bg.json
index f53b9fcd..f43c8087 100644
--- a/www/wiki/extensions/Nuke/i18n/bg.json
+++ b/www/wiki/extensions/Nuke/i18n/bg.json
@@ -4,7 +4,8 @@
"Borislav",
"DCLXVI",
"Spiritia",
- "Termininja"
+ "Termininja",
+ "ShockD"
]
},
"nuke": "Масово изтриване",
@@ -16,8 +17,11 @@
"nuke-submit-user": "Отваряне",
"nuke-submit-delete": "Изтриване на избраните",
"right-nuke": "Масово изтриване на страници",
+ "nuke-select": "Избиране: $1",
"nuke-userorip": "Потребителско име, IP адрес или празно:",
"nuke-maxpages": "Максимален брой страници:",
+ "nuke-deleted": "Страницата '''$1''' е изтрита.",
+ "nuke-delete-more": "[[Special:Nuke|Изтриване на още страници]]",
"nuke-pattern": "Обща част (pattern) в заглавията:",
"nuke-namespace": "Ограничение по именно пространство:",
"nuke-linkoncontribs": "масово изтриване",
diff --git a/www/wiki/extensions/Nuke/i18n/bn.json b/www/wiki/extensions/Nuke/i18n/bn.json
index 886f558d..cc021689 100644
--- a/www/wiki/extensions/Nuke/i18n/bn.json
+++ b/www/wiki/extensions/Nuke/i18n/bn.json
@@ -6,7 +6,8 @@
"Wikitanvir",
"Zaheen",
"Aftabuzzaman",
- "Elias Ahmmad"
+ "Elias Ahmmad",
+ "Bodhisattwa"
]
},
"nuke": "গণ অপসারণ",
@@ -15,13 +16,13 @@
"nuke-nopages": "সাম্প্রতিক পরিবর্তনসমূহে [[Special:Contributions/$1|{{GENDER:$1|$1}}]] কর্তৃক তৈরি কোন নতুন পাতা নেই।",
"nuke-list": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]] সাম্প্রতিক কালে নিচের পাতাগুলি সৃষ্টি করেছেন; একটি মন্তব্য দিন এবং বোতাম চেপে এগুলি মুছে ফেলুন।",
"nuke-list-multiple": "নিচের পাতাসমূহ সম্প্রতি তৈরি করা হয়েছে; একটি মন্তব্য লিখুন এবং বোতাম চেপে তাদের অপসারণ করুন।",
- "nuke-defaultreason": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]] কর্তৃক যোগকৃত পাতাগুলির গণ অপসারণ",
+ "nuke-defaultreason": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]] কর্তৃক যোগ করা পাতাগুলির গণ অপসারণ",
"nuke-multiplepeople": "সম্প্রতি যোগ করা পাতার গণ অপসারণ",
"nuke-tools": "এই সরঞ্জামটি প্রদত্ত ব্যবহারকারী বা আইপি ঠিকানা দ্বারা সম্প্রতি যোগকৃত পাতাগুলি গণ আকারে অপসারণ করার অনুমতি দেয়। অপসারণ করতে পাতাগুলির তালিকা পেতে ব্যবহারকারী নাম বা আইপি ঠিকানাটি ইনপুট করুন বা সমস্ত ব্যবহারকারীদের জন্য ফাঁকা রেখে দিন।",
"nuke-submit-user": "পাতাসমূহের তালিকা",
"nuke-toggleinvert": "ব্যুত্ক্রমে",
- "nuke-submit-delete": "নির্বাচিত অপসারণ করো",
- "right-nuke": "গণ অপসারণ পাতা",
+ "nuke-submit-delete": "নির্বাচিত অপসারণ করুন",
+ "right-nuke": "পাতা গণ অপসারণ",
"nuke-select": "নির্বাচন: $1",
"nuke-userorip": "ব্যবহারকারী নাম, আইপি ঠিকানা বা খালি:",
"nuke-maxpages": "সর্বোচ্চ সংখ্যক পাতাসমূহ:",
@@ -34,5 +35,6 @@
"nuke-viewchanges": "পরিবর্তনসমূহ দেখুন",
"nuke-namespace": "নামস্থানে সীমা:",
"nuke-linkoncontribs": "গণ অপসারণ",
- "nuke-linkoncontribs-text": "পাতা গণ অপসারণ করুন যেখানে {{GENDER:$1|এই ব্যবহারকারী}} একমাত্র লেখক"
+ "nuke-linkoncontribs-text": "পাতা গণ অপসারণ করুন যেখানে {{GENDER:$1|এই ব্যবহারকারী}} একমাত্র লেখক",
+ "nuke-confirm": "আপনি {{PLURAL:$1|একটি পাতা|$1টি পাতা}} অপসারণ করতে চলছেন। আপনি কি নিশ্চিত যে আপনি অপসারণ করতে চান?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ckb.json b/www/wiki/extensions/Nuke/i18n/ckb.json
index 1df383e9..e5ba7016 100644
--- a/www/wiki/extensions/Nuke/i18n/ckb.json
+++ b/www/wiki/extensions/Nuke/i18n/ckb.json
@@ -3,7 +3,8 @@
"authors": [
"Calak",
"Asoxor",
- "Lost Whispers"
+ "Lost Whispers",
+ "Épine"
]
},
"nuke": "سڕینەوەی بەکۆمەڵ",
diff --git a/www/wiki/extensions/Nuke/i18n/cs.json b/www/wiki/extensions/Nuke/i18n/cs.json
index a8f4834c..558ad262 100644
--- a/www/wiki/extensions/Nuke/i18n/cs.json
+++ b/www/wiki/extensions/Nuke/i18n/cs.json
@@ -36,5 +36,6 @@
"nuke-viewchanges": "ukázat změny",
"nuke-namespace": "Omezit na jmenný prostor:",
"nuke-linkoncontribs": "hromadné mazání",
- "nuke-linkoncontribs-text": "Hromadně smazat stránky, jichž je {{GENDER:$1|tento uživatel jediným autorem|tato uživatelka jedinou autorkou}}"
+ "nuke-linkoncontribs-text": "Hromadně smazat stránky, jichž je {{GENDER:$1|tento uživatel jediným autorem|tato uživatelka jedinou autorkou}}",
+ "nuke-confirm": "Chystáte se smazat $1 {{PLURAL:$1|stránku|stránky|stránek}}. Jste si jisti, že {{PLURAL:$1|ji|je}} chcete smazat?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/de.json b/www/wiki/extensions/Nuke/i18n/de.json
index 5eb91dc5..da53365c 100644
--- a/www/wiki/extensions/Nuke/i18n/de.json
+++ b/www/wiki/extensions/Nuke/i18n/de.json
@@ -34,5 +34,6 @@
"nuke-viewchanges": "Änderungen ansehen",
"nuke-namespace": "Auf den folgenden Namensraum begrenzen:",
"nuke-linkoncontribs": "Massenlöschungen",
- "nuke-linkoncontribs-text": "Massengelöschte Seiten, bei denen {{GENDER:$1|dieser Benutzer der einzige Autor|diese Benutzerin die einzige Autorin}} ist."
+ "nuke-linkoncontribs-text": "Massengelöschte Seiten, bei denen {{GENDER:$1|dieser Benutzer der einzige Autor|diese Benutzerin die einzige Autorin}} ist.",
+ "nuke-confirm": "Du bist gerade dabei, {{PLURAL:$1|eine Seite|$1 Seiten}} zu löschen. Möchtest du wirklich fortfahren?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/en.json b/www/wiki/extensions/Nuke/i18n/en.json
index 71cda055..dc22fe81 100644
--- a/www/wiki/extensions/Nuke/i18n/en.json
+++ b/www/wiki/extensions/Nuke/i18n/en.json
@@ -30,5 +30,6 @@
"nuke-viewchanges": "view changes",
"nuke-namespace": "Limit to namespace:",
"nuke-linkoncontribs": "mass delete",
- "nuke-linkoncontribs-text": "Mass delete pages where {{GENDER:$1|this user}} is the only author"
+ "nuke-linkoncontribs-text": "Mass delete pages where {{GENDER:$1|this user}} is the only author",
+ "nuke-confirm": "You are about to delete {{PLURAL:$1|one page|$1 pages}}. Are you sure that you want to delete?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/es.json b/www/wiki/extensions/Nuke/i18n/es.json
index 09b5266d..74876d7c 100644
--- a/www/wiki/extensions/Nuke/i18n/es.json
+++ b/www/wiki/extensions/Nuke/i18n/es.json
@@ -15,7 +15,8 @@
"Remember the dot",
"Sanbec",
"Macofe",
- "Dgstranz"
+ "Dgstranz",
+ "RicardoSGZ"
]
},
"nuke": "Borrado en masa",
@@ -43,5 +44,6 @@
"nuke-viewchanges": "Mostrar cambios",
"nuke-namespace": "Límite al espacio de nombres:",
"nuke-linkoncontribs": "borrado masivo",
- "nuke-linkoncontribs-text": "Eliminar masivamente las páginas donde {{GENDER:$1|este usuario sea el único autor|esta usuaria sea la única autora}}"
+ "nuke-linkoncontribs-text": "Eliminar masivamente las páginas donde {{GENDER:$1|este usuario sea el único autor|esta usuaria sea la única autora}}",
+ "nuke-confirm": "Estás a punto de eliminar {{PLURAL:$1|una página|$1 páginas}}. ¿Estás seguro de que quieres eliminarlo?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/eu.json b/www/wiki/extensions/Nuke/i18n/eu.json
index 7cdad005..3461f0a7 100644
--- a/www/wiki/extensions/Nuke/i18n/eu.json
+++ b/www/wiki/extensions/Nuke/i18n/eu.json
@@ -12,7 +12,7 @@
"nuke": "Ezabaketa masiboa",
"nuke-nopages": "Azken aldaketetan ez dago [[Special:Contributions/$1|$1]]-(r)en orri berririk.",
"nuke-list": "Ondorengo orri hauek sortu berri ditu [[Special:Contributions/$1|{{GENDER:$1|$1}}]] wikilariak;\nidatz ezazu ohar bat, eta sakatu botoia orri horiek ezabatzeko.",
- "nuke-defaultreason": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]]-(e)k sortutako orrien ezabaketa masiboa",
+ "nuke-defaultreason": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]] wikilariak sortutako orrien ezabaketa masiboa",
"nuke-submit-user": "Orri zerrenda",
"nuke-toggleinvert": "Alderantzikatu",
"nuke-submit-delete": "Aukeratutakoa ezabatu",
diff --git a/www/wiki/extensions/Nuke/i18n/fa.json b/www/wiki/extensions/Nuke/i18n/fa.json
index 5cd473f9..67cd13e6 100644
--- a/www/wiki/extensions/Nuke/i18n/fa.json
+++ b/www/wiki/extensions/Nuke/i18n/fa.json
@@ -7,7 +7,8 @@
"Mjbmr",
"Reza1615",
"ZxxZxxZ",
- "Alirezaaa"
+ "Alirezaaa",
+ "Ladsgroup"
]
},
"nuke": "حذف دسته‌جمعی",
@@ -19,7 +20,8 @@
"nuke-defaultreason": "حذف دسته‌جمعی صفحه‌هایی که توسط [[Special:Contributions/$1|{{GENDER:$1|$1}}]] ایجاد شده‌اند",
"nuke-multiplepeople": "حذف توده‌ای صفحه‌های به‌تازگی افزوده‌شده",
"nuke-tools": "این ابزار امکان حذف دسته‌جمعی صفحه‌هایی که به تازگی توسط یک کاربر یا نشانی آی‌پی اضافه شده‌اند را فراهم می‌کند.\nنام کاربری یا نشانی آی‌پی موردنظر را وارد کنید، یا جعبه را خالی بگذارید تا تمام کاربرها در نظر گرفته شوند.",
- "nuke-submit-user": "برو",
+ "nuke-submit-user": "فهرست صفحات",
+ "nuke-toggleinvert": "معکوس",
"nuke-submit-delete": "حذف موارد انتخاب شده",
"right-nuke": "حذف دسته‌جمعی صفحات",
"nuke-select": "انتخاب: $1",
@@ -30,9 +32,10 @@
"nuke-not-deleted": "صفحهٔ [[:$1]] را '''نمی‌توان''' حذف کرد.",
"nuke-delete-more": "[[Special:Nuke|حذف صفحه‌های بیشتر]]",
"nuke-pattern": "الگو برای نام صفحه:",
- "nuke-nopages-global": "هیچ صفحهٔ جدیدی در [[Special:RecentChanges|فهرست تغییرات اخیر]] نیست.",
+ "nuke-nopages-global": "هیچ صفحهٔ جدیدی در جستجوی شما نیست.",
"nuke-viewchanges": "نمایش تغییرات",
"nuke-namespace": "محدودیت به فضای نام:",
"nuke-linkoncontribs": "حذف گروهی",
- "nuke-linkoncontribs-text": "حذف دستهٔ صفحات جایی که این کاربر تنها نویسنده است"
+ "nuke-linkoncontribs-text": "حذف دستهٔ صفحات جایی که {{GENDER:$1|این کاربر}} تنها نویسنده است",
+ "nuke-confirm": "شما در حال حذف کردن {{PLURAL:$1|یک صفحه|$1 صفحه}} هستید. آیا مطمئنید؟"
}
diff --git a/www/wiki/extensions/Nuke/i18n/fr.json b/www/wiki/extensions/Nuke/i18n/fr.json
index dc2dc86f..bdd39db5 100644
--- a/www/wiki/extensions/Nuke/i18n/fr.json
+++ b/www/wiki/extensions/Nuke/i18n/fr.json
@@ -40,5 +40,6 @@
"nuke-viewchanges": "voir les modifications",
"nuke-namespace": "Se limiter à l'espace de nommage:",
"nuke-linkoncontribs": "suppression de masse",
- "nuke-linkoncontribs-text": "Suppression de pages en masse pour lesquelles {{GENDER:$1|cet utilisateur|cette utilisatrice}} est l’unique auteur"
+ "nuke-linkoncontribs-text": "Suppression de pages en masse pour lesquelles {{GENDER:$1|cet utilisateur|cette utilisatrice}} est l’unique auteur",
+ "nuke-confirm": "Vous allez supprimer {{PLURAL:$1|une page|$1 pages}}. Êtes-vous sûr de vouloir supprimer ?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/gl.json b/www/wiki/extensions/Nuke/i18n/gl.json
index 3d491b72..15da3ef0 100644
--- a/www/wiki/extensions/Nuke/i18n/gl.json
+++ b/www/wiki/extensions/Nuke/i18n/gl.json
@@ -33,5 +33,6 @@
"nuke-viewchanges": "ollar os cambios",
"nuke-namespace": "Limitar ao espazo de nomes:",
"nuke-linkoncontribs": "eliminar en masa",
- "nuke-linkoncontribs-text": "Eliminar en masa as páxinas das que este usuario é o único autor"
+ "nuke-linkoncontribs-text": "Eliminar en masa as páxinas das que {{GENDER:$1|este usuario é o único autor|esta usuaria é a única autora}}",
+ "nuke-confirm": "Está a piques de eliminar {{PLURAL:$1|unha páxina|$1 páxinas}}. Está seguro de que quere facer o borrado?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/he.json b/www/wiki/extensions/Nuke/i18n/he.json
index f8956bc6..b5a34efc 100644
--- a/www/wiki/extensions/Nuke/i18n/he.json
+++ b/www/wiki/extensions/Nuke/i18n/he.json
@@ -13,7 +13,7 @@
"action-nuke": "למחוק דפים מרובים",
"nuke-desc": "אפשרות למפעילי המערכת לבצע [[Special:Nuke|מחיקה מרובה]] של דפים",
"nuke-nopages": "אין דפים חדשים שנוצרו על־ידי [[Special:Contributions/$1|$1]] בשינויים האחרונים.",
- "nuke-list": "הדפים הבאים נוצרו לאחרונה על־ידי [[Special:Contributions/$1|$1]];\nאנא כתבו הסבר למחיקה ולחצו על הכפתור כדי למחוק אותם.",
+ "nuke-list": "הדפים הבאים נוצרו לאחרונה על־ידי [[Special:Contributions/$1|$1]];\nיש לכתוב הסבר למחיקה ולאחר מכן ללחוץ על הכפתור כדי למחוק אותם.",
"nuke-list-multiple": "הדפים הבאים נוצרו לאחרונה;\nאנא כתבו נימוק למחיקה ולחצו על הכפתור כדי למחוק אותם.",
"nuke-defaultreason": "מחיקה מרובה של דפים שנוצרו על־ידי [[Special:Contributions/$1|$1]]",
"nuke-multiplepeople": "מחיקה מרובה של דפים שנוספו לאחרונה",
@@ -34,5 +34,6 @@
"nuke-viewchanges": "הצגת שינויים",
"nuke-namespace": "להגביל למרחב השמות הבא:",
"nuke-linkoncontribs": "מחיקה מרובה",
- "nuke-linkoncontribs-text": "מחיקת דפים רבים {{GENDER:$1|שהמשתמש הזה הוא הכותב היחיד|שהמשתמשת הזאת היא הכותבת היחידה}} שלהם"
+ "nuke-linkoncontribs-text": "מחיקת דפים רבים {{GENDER:$1|שהמשתמש הזה הוא הכותב היחיד|שהמשתמשת הזאת היא הכותבת היחידה}} שלהם",
+ "nuke-confirm": "{{GENDER:|אתה עומד|את עומדת}} למחוק {{PLURAL:$1|דף אחד|$1 דפים}}. האם {{GENDER:|אתה|את}} רוצה להמשיך?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/hu.json b/www/wiki/extensions/Nuke/i18n/hu.json
index b73948ab..6f459303 100644
--- a/www/wiki/extensions/Nuke/i18n/hu.json
+++ b/www/wiki/extensions/Nuke/i18n/hu.json
@@ -10,27 +10,31 @@
"Urbalazs"
]
},
- "nuke": "Halmozott törlés",
+ "nuke": "Tömeges törlés",
"action-nuke": "oldalak tömeges törlése",
"nuke-desc": "Lehetővé teszi az adminisztrátorok számára a lapok [[Special:Nuke|tömeges törlését]].",
- "nuke-nopages": "Nincsenek új oldalak [[Special:Contributions/$1|$1]] az aktuális események között.",
+ "nuke-nopages": "Nincsenek új oldalak [[Special:Contributions/$1|$1]] felhasználótól a friss változtatások között.",
"nuke-list": "Az alábbi lapokat nem rég készítette [[Special:Contributions/$1|{{GENDER:$1|$1}}]]; adj meg egy indoklást, és kattints a gombra a törlésükhöz.",
"nuke-list-multiple": "Az alábbi lapok találhatók a friss változtatásokban;\nadjál hozzá megjegyzést, és a törléshez nyomd meg a gombot.",
- "nuke-defaultreason": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]] által készített lapok tömeges eltávolítása",
+ "nuke-defaultreason": "[[Special:Contributions/$1|$1]] által készített lapok tömeges törlése",
"nuke-multiplepeople": "Frissen hozzáadott oldalak tömeges törlése",
- "nuke-tools": "Ez az eszköz lehetővé teszi egy adott felhasználó vagy IP által nemrég készített lapok tömeges törlését. Add meg a felhasználónevet vagy az IP-címet, ezzel megkapod a törölhető lapok listáját. Ha nem adsz meg nevet, az összes felhasználót listázza.",
- "nuke-submit-user": "Menj",
+ "nuke-tools": "Ez az eszköz lehetővé teszi egy adott felhasználó vagy IP-cím által nemrég készített lapok tömeges törlését.\nAdd meg a felhasználónevet vagy az IP-címet a törölhető lapok listájának lekéréséhez, vagy hagyd üresen a mezőt az összes felhasználó listázásához.",
+ "nuke-submit-user": "Lapok listázása",
+ "nuke-toggleinvert": "Megfordítás",
"nuke-submit-delete": "Kijelöltek törlése",
"right-nuke": "oldalak tömeges törlése",
"nuke-select": "Kiválasztás: $1",
"nuke-userorip": "Felhasználónév, IP-cím vagy üres:",
"nuke-maxpages": "Lapok maximális száma:",
- "nuke-editby": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]] által létrehozott",
- "nuke-deleted": "'''$1''' oldal törölve lett.",
- "nuke-not-deleted": "[[:$1]] oldalt ''nem sikerült''' törölni.",
+ "nuke-editby": "Készítette [[Special:Contributions/$1|$1]]",
+ "nuke-deleted": "A(z) '''$1''' oldal törölve.",
+ "nuke-not-deleted": "A(z) [[:$1]] oldalt '''nem sikerült''' törölni.",
"nuke-delete-more": "[[Special:Nuke|További oldalak törlése]]",
"nuke-pattern": "Lapnév minta:",
"nuke-nopages-global": "Nincsenek a keresésre illeszkedő oldalcímek.",
"nuke-viewchanges": "változtatások megtekintése",
- "nuke-namespace": "Csak az alábbi névtérben:"
+ "nuke-namespace": "Csak az alábbi névtérben:",
+ "nuke-linkoncontribs": "tömeges törlés",
+ "nuke-linkoncontribs-text": "Olyan lapok tömeges törlése, amiknek {{GENDER:$1|ez a felhasználó}} az egyetlen szerzője",
+ "nuke-confirm": "$1 lap törlésére készülsz. Biztos, hogy ezt akarod tenni?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/hy.json b/www/wiki/extensions/Nuke/i18n/hy.json
new file mode 100644
index 00000000..c12c7de3
--- /dev/null
+++ b/www/wiki/extensions/Nuke/i18n/hy.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Դավիթ Սարոյան"
+ ]
+ },
+ "nuke": "Զանգվածային ջնջում",
+ "action-nuke": "էջերի զանգվածային ջնջում",
+ "nuke-linkoncontribs": "զանգվածային ջնջում"
+}
diff --git a/www/wiki/extensions/Nuke/i18n/io.json b/www/wiki/extensions/Nuke/i18n/io.json
index e9ed4b8f..9485ca70 100644
--- a/www/wiki/extensions/Nuke/i18n/io.json
+++ b/www/wiki/extensions/Nuke/i18n/io.json
@@ -2,9 +2,11 @@
"@metadata": {
"authors": [
"Malafaya",
- "Lakaoso"
+ "Lakaoso",
+ "Joao Xavier"
]
},
"nuke-submit-user": "Montrar listo di pagini",
- "nuke-submit-delete": "Efacez selektiti"
+ "nuke-submit-delete": "Efacez selektiti",
+ "nuke-select": "Selektez: $1"
}
diff --git a/www/wiki/extensions/Nuke/i18n/is.json b/www/wiki/extensions/Nuke/i18n/is.json
index 35f97b83..98d1b68b 100644
--- a/www/wiki/extensions/Nuke/i18n/is.json
+++ b/www/wiki/extensions/Nuke/i18n/is.json
@@ -2,7 +2,9 @@
"@metadata": {
"authors": [
"S.Örvarr.S",
- "Snævar"
+ "Snævar",
+ "Maxí",
+ "Sveinn í Felli"
]
},
"nuke": "Fjöldaeyða",
@@ -15,6 +17,7 @@
"nuke-multiplepeople": "Fjöldaeyðing nýjustu greina",
"nuke-tools": "Hér er hægt að fjöldaeyða síðum sem voru nýlega búnar til af notanda eða vistfangi.\nTilgreindu notendanafn eða vistfang til að fá lista yfir síður til að eyða, eða skildu reitinn eftir tóman til að fá lista yfir síður frá öllum notendum.",
"nuke-submit-user": "Lista síður",
+ "nuke-toggleinvert": "Umhverfa",
"nuke-submit-delete": "Eyða völdum síðum",
"right-nuke": "Fjöldaeyða síðum",
"nuke-select": "Velja: $1",
@@ -25,6 +28,7 @@
"nuke-not-deleted": "Mistök við eyðingu síðunnar [[:$1]].",
"nuke-delete-more": "[[Special:Nuke|Fjöldaeyða fleiri skrám]]",
"nuke-pattern": "Nafna mynstur:",
- "nuke-nopages-global": "Það eru engar nýjar síður í [[Special:RecentChanges|nýjustu breytingum]].",
- "nuke-viewchanges": "skoða breytingar"
+ "nuke-nopages-global": "Það eru engir síðutitlar sem samsvara leitinni þinni.",
+ "nuke-viewchanges": "skoða breytingar",
+ "nuke-linkoncontribs": "fjöldaeyða"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ja.json b/www/wiki/extensions/Nuke/i18n/ja.json
index 58e82f71..313b8c78 100644
--- a/www/wiki/extensions/Nuke/i18n/ja.json
+++ b/www/wiki/extensions/Nuke/i18n/ja.json
@@ -11,7 +11,8 @@
"Penn Station",
"Schu",
"Shirayuki",
- "青子守歌"
+ "青子守歌",
+ "Otokoume"
]
},
"nuke": "一括削除",
@@ -35,8 +36,10 @@
"nuke-not-deleted": "ページ [[:$1]] を削除'''できませんでした'''。",
"nuke-delete-more": "[[Special:Nuke|他のページも削除]]",
"nuke-pattern": "ページ名のパターン:",
- "nuke-nopages-global": "[[Special:RecentChanges|最近の更新]]には新しいページはありません。",
+ "nuke-nopages-global": "指定したページ名に一致する検索結果はありません。",
"nuke-viewchanges": "履歴を表示",
"nuke-namespace": "名前空間:",
- "nuke-linkoncontribs": "一括削除"
+ "nuke-linkoncontribs": "一括削除",
+ "nuke-linkoncontribs-text": "{{GENDER:$1|この利用者}}が作成したページを一括削除します",
+ "nuke-confirm": "{{PLURAL:$1|1|$1}}件のページを削除しようとしています。削除してもよろしいですか?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/jv.json b/www/wiki/extensions/Nuke/i18n/jv.json
index c1752a44..b6759cb9 100644
--- a/www/wiki/extensions/Nuke/i18n/jv.json
+++ b/www/wiki/extensions/Nuke/i18n/jv.json
@@ -6,24 +6,31 @@
"Bennylin"
]
},
- "nuke": "Busak massal",
- "nuke-desc": "Mènèhi opsis fungsionalitas kanggo [[Special:Nuke|mbusak massal]] kaca-kaca",
- "nuke-nopages": "Ora ditemokaké kaca anyar saka [[Special:Contributions/$1|$1]] ing owah-owahan pungkasan.",
- "nuke-list": "Kaca-kaca ing ngisor iki lagi baé digawé déning [[Special:Contributions/$1|$1]];\nlebokna komentar lan pencèten tombol kanggo mbusak kabèh.",
- "nuke-defaultreason": "Pambusakan massal kaca-kaca sing digawé déning $1",
- "nuke-tools": "Piranti iki bisa ngakibataké pambusakan massal kaca-kaca sing lagi waé ditambahaké déning sawijining panganggo utawa alamat IP.\nLebokna jeneng panganggo utawa alamat IP kanggo olèh daftar kaca-kaca sing bisa dibusak:",
- "nuke-submit-user": "Lakokna",
- "nuke-submit-delete": "Busaken sing kapilih",
- "right-nuke": "Pambusakan masal",
+ "nuke": "Busak gedhèn-gedhèn",
+ "action-nuke": "busak gedhèn-gedhèn",
+ "nuke-desc": "Awèh pangurus kabisan [[Special:Nuke|mbusak kaca gedhèn-gedhèn]]",
+ "nuke-nopages": "Ora ana kaca anyar garapané [[Special:Contributions/$1|$1]] ing owah-owahan.",
+ "nuke-list": "Kaca-kaca ing ngisor iki mentas digawé [[Special:Contributions/$1|$1]]; awèh tanggepan lan pencèt tombol saperlu mbusak.",
+ "nuke-list-multiple": "Kaca-kaca ing ngisor iki mentas kagawé;\nawèh tanggepan lan pencèn tombol saperlu mbusak.",
+ "nuke-defaultreason": "Busak gedhèn-gedhèn kaca garapané [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
+ "nuke-multiplepeople": "Busakan gedhèn-gedhèn kaca sing mentas kagawé",
+ "nuke-tools": "Piranti iki ngidinaké pambusak gedhèn-gedhèn kaca sing tembé digawé sawijining panganggo utawa digawé sawijining alamat IP.\nLebokaké jeneng panganggo utawa alamat IP saperlu ngéntukaké pratélan kaca sing arep kabusak gawéané panganggo utawa alamat IP mau, utawa kosongi waé kanggo ngéntukaké pratélan kaca gawéané kabèh panganggo.",
+ "nuke-submit-user": "Pratélan kaca",
+ "nuke-toggleinvert": "Balèkaké",
+ "nuke-submit-delete": "Busak sing kapilih",
+ "right-nuke": "Busak kaca gedhèn-gedhèn",
"nuke-select": "Pilih: $1",
"nuke-userorip": "Jeneng panganggo, alamat IP utawa kosong:",
"nuke-maxpages": "Cacahé kaca maksimal:",
- "nuke-editby": "Digawé déning [[Special:Contributions/$1|$1]]",
+ "nuke-editby": "Garapané [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-deleted": "Kaca '''$1''' wis dibusak.",
"nuke-not-deleted": "Kaca [[:$1]] '''ora bisa''' dibusak.",
"nuke-delete-more": "[[Special:Nuke|Busak kaca luwih akèh]]",
"nuke-pattern": "Pola kanggo jeneng kaca:",
- "nuke-nopages-global": "Ora ana kaca anyar nèng [[Special:RecentChanges|owah-owahan paling anyar]].",
+ "nuke-nopages-global": "Ora ana sesirah kaca sing mathuk karo panggolèké panjenengan.",
"nuke-viewchanges": "deleng owah-owahan",
- "nuke-linkoncontribs": "busak massal"
+ "nuke-namespace": "Watesan ing mandala-aran:",
+ "nuke-linkoncontribs": "busak gedhèn-gedhèn",
+ "nuke-linkoncontribs-text": "Busak gedhèn-gedhèn kaca sing digawé {{GENDER:$1|panganggo iki}}",
+ "nuke-confirm": "Panjenengan arep mbusak {{PLURAL:$1|kaca siji|kaca $1}}. Apa panjenengan yakin arep mbusak?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ko.json b/www/wiki/extensions/Nuke/i18n/ko.json
index 56929844..73e889b1 100644
--- a/www/wiki/extensions/Nuke/i18n/ko.json
+++ b/www/wiki/extensions/Nuke/i18n/ko.json
@@ -38,5 +38,6 @@
"nuke-viewchanges": "차이 보기",
"nuke-namespace": "이름공간 제한:",
"nuke-linkoncontribs": "문서 대량 삭제",
- "nuke-linkoncontribs-text": "{{GENDER:$1|이 사용자}}가 유일한 기여자인 문서를 대량 삭제"
+ "nuke-linkoncontribs-text": "{{GENDER:$1|이 사용자}}가 유일한 기여자인 문서를 대량 삭제",
+ "nuke-confirm": "{{PLURAL:$1|문서 한 개|문서 $1개}}를 삭제하려고 합니다. 정말 삭제하시겠습니까?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ku-latn.json b/www/wiki/extensions/Nuke/i18n/ku-latn.json
index 97742ba7..11fec5ea 100644
--- a/www/wiki/extensions/Nuke/i18n/ku-latn.json
+++ b/www/wiki/extensions/Nuke/i18n/ku-latn.json
@@ -1,9 +1,10 @@
{
"@metadata": {
"authors": [
- "George Animal"
+ "George Animal",
+ "Bikarhêner"
]
},
- "nuke-submit-user": "Biçe",
+ "nuke-submit-user": "Rûpelan lîste bike",
"nuke-select": "Hilbijêre: $1"
}
diff --git a/www/wiki/extensions/Nuke/i18n/lb.json b/www/wiki/extensions/Nuke/i18n/lb.json
index e9867caf..860d260e 100644
--- a/www/wiki/extensions/Nuke/i18n/lb.json
+++ b/www/wiki/extensions/Nuke/i18n/lb.json
@@ -11,9 +11,9 @@
"nuke-desc": "Gëtt Administrateuren d'Méiglechkeet fir [[Special:Nuke|vill Säite mateneen ze läschen]]",
"nuke-nopages": "Et gëtt bei de rezenten Ännerunge keng nei Säite vum [[Special:Contributions/$1|{{GENDER:$1|$1}}]].",
"nuke-list": "Dës Säite goufe viru kuerzem vum [[Special:Contributions/$1|{{GENDER:$1|$1}}]] nei ugeluecht; gitt w.e.g. eng Bemierkung an, an dréckt op de Knäppche Läschen.",
- "nuke-list-multiple": "Dës Säite goufe rezent gemaach;\nsetzt eng Bemierkung derbäi a klickt op de Knäppche fir se ze läschen.",
+ "nuke-list-multiple": "Dës Säite goufe rezent gemaach;\nsetzt eng Bemierkung dobäi a klickt op de Knäppche fir se ze läschen.",
"nuke-defaultreason": "Masseläschung vu Säiten, déi vum [[Special:Contributions/$1|{{GENDER:$1|$1}}]] ugefaang goufen",
- "nuke-multiplepeople": "Masse-Läschung vu Säiten déi rezent derbäigesat goufen",
+ "nuke-multiplepeople": "Masse-Läschung vu Säiten déi rezent dobäigesat goufen",
"nuke-tools": "Dësen Tool erlaabt vill Säite mateneen ze läschen, déi vun engem Benotzer oder vun enger IP-Adress ugeluecht goufen.\nGitt w.e.g. d'IP-Adress respektiv de Benotzer u fir eng Lëscht vun de Säiten ze kréien déi geläscht solle ginn, oder loosst et eidel fir all Benotzer.",
"nuke-submit-user": "Säiten oplëschten",
"nuke-toggleinvert": "Ëmdréinen",
diff --git a/www/wiki/extensions/Nuke/i18n/lt.json b/www/wiki/extensions/Nuke/i18n/lt.json
index 45c662c1..db8ad42b 100644
--- a/www/wiki/extensions/Nuke/i18n/lt.json
+++ b/www/wiki/extensions/Nuke/i18n/lt.json
@@ -4,7 +4,8 @@
"Eitvys200",
"Homo",
"Matasg",
- "Pofka"
+ "Pofka",
+ "Manvydasz"
]
},
"nuke": "Masinis trynimas",
@@ -14,7 +15,7 @@
"nuke-defaultreason": "Masinis pašalinimas puslapių, kuriuos sukūrė $1",
"nuke-multiplepeople": "Masinis neseniai sukurtų puslapių trynimas",
"nuke-tools": "Šis įrankis leidžia masiškai ištrinti puslapius, neseniai sukurtus nurodyto naudotojo ar IP.\nĮrašykite naudotojo vardą ar IP adresą, kad gautumėte trintinų puslapių sąrašą.",
- "nuke-submit-user": "Išsiųsti",
+ "nuke-submit-user": "Puslapių sąrašas",
"nuke-toggleinvert": "Invertuoti",
"nuke-submit-delete": "Ištrinti pasirinktus(ą)",
"right-nuke": "Masinis puslapių trynėjas",
diff --git a/www/wiki/extensions/Nuke/i18n/lzh.json b/www/wiki/extensions/Nuke/i18n/lzh.json
index fd576e07..8b281ee2 100644
--- a/www/wiki/extensions/Nuke/i18n/lzh.json
+++ b/www/wiki/extensions/Nuke/i18n/lzh.json
@@ -1,7 +1,11 @@
{
- "@metadata": [],
+ "@metadata": {
+ "authors": [
+ "Itsmine"
+ ]
+ },
"nuke": "量刪",
- "nuke-nopages": "近易無示[[Special:Contributions/$1|$1]]之新頁。",
+ "nuke-nopages": "[[Special:Contributions/$1|{{GENDER:$1|$1}}]]並無新纂。",
"nuke-list": "[[Special:Contributions/$1|$1]]之作所示;剔註再點刪之。",
"nuke-defaultreason": "量刪由$1所建之頁",
"nuke-tools": "此意供簿或IP建之頁。入簿名加號取表作刪也:",
diff --git a/www/wiki/extensions/Nuke/i18n/mk.json b/www/wiki/extensions/Nuke/i18n/mk.json
index 1de93769..206d8117 100644
--- a/www/wiki/extensions/Nuke/i18n/mk.json
+++ b/www/wiki/extensions/Nuke/i18n/mk.json
@@ -13,7 +13,7 @@
"nuke-defaultreason": "Масовно бришење на страници од [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-multiplepeople": "Масовно бришење на неодамна додадени страници",
"nuke-tools": "Оваа алатка овозможува збирни бришења на страници неодамна додадени од извесен корисник или IP-адреса.\nВнесете го корисничкото име или IP-адреса за да го добиете списокот на страници за бришење, или пак оставете го празно ако сакате да се наведат сите корисници.",
- "nuke-submit-user": "Изврши",
+ "nuke-submit-user": "Испиши страници",
"nuke-toggleinvert": "Избери обратно",
"nuke-submit-delete": "Избриши ги избраните",
"right-nuke": "Групно бришење на страници",
@@ -25,9 +25,10 @@
"nuke-not-deleted": "Страницата [[:$1]] '''не можеше''' да се избрише.",
"nuke-delete-more": "[[Special:Nuke|Избриши уште страници]]",
"nuke-pattern": "Мостра за име на страница:",
- "nuke-nopages-global": "Нема нови страници во [[Special:RecentChanges|скорешните промени]].",
+ "nuke-nopages-global": "Нема нови наслови што одговараат на бараното.",
"nuke-viewchanges": "прикажи промени",
"nuke-namespace": "Само во имен. простор:",
"nuke-linkoncontribs": "масовно бришење",
- "nuke-linkoncontribs-text": "Масовното бришење на страници чиј единствен автор е овој корисник"
+ "nuke-linkoncontribs-text": "Масовното бришење на страници чиј единствен автор е {{GENDER:$1|овој корисник}}",
+ "nuke-confirm": "На пат сте да избришете {{PLURAL:$1|една страница|$1 страници}}. Дали сте сигурни?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/mwl.json b/www/wiki/extensions/Nuke/i18n/mwl.json
index 93b58a0d..dee465bd 100644
--- a/www/wiki/extensions/Nuke/i18n/mwl.json
+++ b/www/wiki/extensions/Nuke/i18n/mwl.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
"nuke": "Botar fuora an massa",
diff --git a/www/wiki/extensions/Nuke/i18n/mzn.json b/www/wiki/extensions/Nuke/i18n/mzn.json
new file mode 100644
index 00000000..acd047fe
--- /dev/null
+++ b/www/wiki/extensions/Nuke/i18n/mzn.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "محک"
+ ]
+ },
+ "nuke": "یک‌شِب حذف هاکردن"
+}
diff --git a/www/wiki/extensions/Nuke/i18n/nb.json b/www/wiki/extensions/Nuke/i18n/nb.json
index 74d64a00..07fd5e8b 100644
--- a/www/wiki/extensions/Nuke/i18n/nb.json
+++ b/www/wiki/extensions/Nuke/i18n/nb.json
@@ -17,7 +17,7 @@
"nuke-defaultreason": "Massesletting av sider lagt inn av [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-multiplepeople": "Massesletting av nylig opprettede sider",
"nuke-tools": "Dette verktøyet muliggjør massesletting av sider som nylig er opprettet av gitt bruker eller IP-adresse.\nSkriv et brukernavn eller en IP-adresse for å få en liste over sider som kan slettes, eller angi tomt for alle brukere.",
- "nuke-submit-user": "Vis",
+ "nuke-submit-user": "List opp sider",
"nuke-toggleinvert": "Inverter",
"nuke-submit-delete": "Slett valgte",
"right-nuke": "Masseslette sider",
@@ -29,9 +29,10 @@
"nuke-not-deleted": "Siden [[:$1]] '''kunne ikke''' slettes.",
"nuke-delete-more": "[[Special:Nuke|Slett flere sider]]",
"nuke-pattern": "Mønster for sidenavnet:",
- "nuke-nopages-global": "Det er ingen sider i [[Special:RecentChanges|siste endringer]].",
+ "nuke-nopages-global": "Det er ingen sidetitler som matcher søket ditt.",
"nuke-viewchanges": "vis endringer",
"nuke-namespace": "Begrens til navnerom:",
"nuke-linkoncontribs": "masseslett",
- "nuke-linkoncontribs-text": "Masseslett sider der denne brukeren er den eneste oppretteren"
+ "nuke-linkoncontribs-text": "Masseslett sider der denne {{GENDER:$1|brukeren}} er den eneste forfatteren",
+ "nuke-confirm": "Du er i ferd med å slette {{PLURAL:$1|éi side|$1 sider}}. Er du sikker på at du vil gjøre dette?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/nl.json b/www/wiki/extensions/Nuke/i18n/nl.json
index bb526063..be95077f 100644
--- a/www/wiki/extensions/Nuke/i18n/nl.json
+++ b/www/wiki/extensions/Nuke/i18n/nl.json
@@ -34,5 +34,6 @@
"nuke-viewchanges": "wijzigingen bekijken",
"nuke-namespace": "Beperk tot naamruimte:",
"nuke-linkoncontribs": "massaal verwijderen",
- "nuke-linkoncontribs-text": "Pagina's waar {{GENDER:$1|deze gebruiker}} de enige auteur is massaal verwijderen"
+ "nuke-linkoncontribs-text": "Pagina's waar {{GENDER:$1|deze gebruiker}} de enige auteur is massaal verwijderen",
+ "nuke-confirm": "U staat op het punt om {{PLURAL:$1|een pagina| $1 pagina's}} te verwijderen. Weet u zeker dat u deze pagina's wilt verwijderen?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/nn.json b/www/wiki/extensions/Nuke/i18n/nn.json
index 1218adc7..8d461ea2 100644
--- a/www/wiki/extensions/Nuke/i18n/nn.json
+++ b/www/wiki/extensions/Nuke/i18n/nn.json
@@ -29,5 +29,6 @@
"nuke-viewchanges": "vis endringar",
"nuke-namespace": "Avgrens til namnerom:",
"nuke-linkoncontribs": "masseslett",
- "nuke-linkoncontribs-text": "Masseslett sider der denne brukaren er den einaste bidragsytaren"
+ "nuke-linkoncontribs-text": "Masseslett sider der denne brukaren er den einaste bidragsytaren",
+ "nuke-confirm": "Du er i ferd med å sletta {{PLURAL:$1|éi side|$1 sider}}. Er du viss på at du vil gjera dette?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/pl.json b/www/wiki/extensions/Nuke/i18n/pl.json
index 1fbb2a21..2955e509 100644
--- a/www/wiki/extensions/Nuke/i18n/pl.json
+++ b/www/wiki/extensions/Nuke/i18n/pl.json
@@ -13,7 +13,8 @@
"Sp5uhe",
"WTM",
"Woytecr",
- "Peter Bowman"
+ "Peter Bowman",
+ "Railfail536"
]
},
"nuke": "Masowe usuwanie",
@@ -25,7 +26,7 @@
"nuke-defaultreason": "Masowe usunięcie stron stworzonych przez [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-multiplepeople": "Masowe usuwanie ostatnio utworzonych stron",
"nuke-tools": "Narzędzie pozwala na masowe usuwanie stron ostatnio dodanych przez zarejestrowanego lub anonimowego użytkownika.<br />\nWpisz nazwę użytkownika lub adres IP, by otrzymać listę stron do usunięcia. Możesz także nic nie wpisywać, wtedy będzie można masowo usunąć wkład wszystkich użytkowników.",
- "nuke-submit-user": "Dalej",
+ "nuke-submit-user": "Lista stron",
"nuke-toggleinvert": "Odwróć",
"nuke-submit-delete": "Usuń zaznaczone",
"right-nuke": "Masowe usuwanie stron",
@@ -37,9 +38,10 @@
"nuke-not-deleted": "Strony [[:$1]] '''nie można''' usunąć.",
"nuke-delete-more": "[[Special:Nuke|Usuń więcej stron]]",
"nuke-pattern": "Wzór nazwy strony:",
- "nuke-nopages-global": "Brak nowych stron w [[Special:RecentChanges|ostatnich zmianach]].",
+ "nuke-nopages-global": "Nie odnaleziono stron pasujących do Twojego wyszukiwania.",
"nuke-viewchanges": "widok zmian",
"nuke-namespace": "Tylko w przestrzeni nazw:",
"nuke-linkoncontribs": "masowe usuwanie",
- "nuke-linkoncontribs-text": "Masowe usuwanie stron, których {{GENDER:$1|jedynym autorem jest ten użytkownik|jedyną autorką jest ta użytkowniczka}}"
+ "nuke-linkoncontribs-text": "Masowe usuwanie stron, których {{GENDER:$1|jedynym autorem jest ten użytkownik|jedyną autorką jest ta użytkowniczka}}",
+ "nuke-confirm": "Zamierzasz usunąć {{PLURAL:$1|jedną stronę|$1 strony|$1 stron}}. Czy na pewno chcesz to zrobić?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ps.json b/www/wiki/extensions/Nuke/i18n/ps.json
index eac3e8b3..effc8af4 100644
--- a/www/wiki/extensions/Nuke/i18n/ps.json
+++ b/www/wiki/extensions/Nuke/i18n/ps.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Ahmed-Najib-Biabani-Ibrahimkhel"
+ "Ahmed-Najib-Biabani-Ibrahimkhel",
+ "Baloch Khan"
]
},
"nuke": "ټول ړنگېدنه",
@@ -16,5 +17,6 @@
"nuke-deleted": "د '''$1''' مخ ړنگ شو.",
"nuke-not-deleted": "د [[:$1]] مخ '''نشي''' ړنګېدلی.",
"nuke-delete-more": "[[Special:Nuke|لا نور مخونه ړنگول]]",
- "nuke-viewchanges": "بدلونونه کتل"
+ "nuke-viewchanges": "بدلونونه کتل",
+ "nuke-linkoncontribs": "ټول ړنگېدنه"
}
diff --git a/www/wiki/extensions/Nuke/i18n/pt-br.json b/www/wiki/extensions/Nuke/i18n/pt-br.json
index f5d0fe07..be0769ed 100644
--- a/www/wiki/extensions/Nuke/i18n/pt-br.json
+++ b/www/wiki/extensions/Nuke/i18n/pt-br.json
@@ -8,7 +8,8 @@
"MetalBrasil",
"555",
"Araceletorres",
- "Felipe L. Ewald"
+ "Felipe L. Ewald",
+ "Eduardo Addad de Oliveira"
]
},
"nuke": "Eliminar de forma massiva",
@@ -36,5 +37,6 @@
"nuke-viewchanges": "ver alterações",
"nuke-namespace": "Limitar ao espaço nominal:",
"nuke-linkoncontribs": "excluir em massa",
- "nuke-linkoncontribs-text": "Excluir em massa páginas em que este usuário é o único autor"
+ "nuke-linkoncontribs-text": "Eliminar em massa páginas em que {{GENDER:$1|este usuário é o único autor|esta usuária é a única autora}}",
+ "nuke-confirm": "Está prestes a eliminar {{PLURAL:$1|uma página|$1 páginas}}. Tem a certeza de que pretende {{PLURAL:$1|eliminá-la|eliminá-las}}?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/pt.json b/www/wiki/extensions/Nuke/i18n/pt.json
index 956ac11c..d558120a 100644
--- a/www/wiki/extensions/Nuke/i18n/pt.json
+++ b/www/wiki/extensions/Nuke/i18n/pt.json
@@ -11,9 +11,9 @@
},
"nuke": "Eliminação em massa",
"action-nuke": "eliminar páginas em massa",
- "nuke-desc": "[[Special:Nuke|Página especial]] que permite que os administradores apaguem páginas de forma massiva",
+ "nuke-desc": "[[Special:Nuke|Página especial]] que permite que os administradores apaguem páginas de forma maciça",
"nuke-nopages": "Não há novas páginas de [[Special:Contributions/$1|{{GENDER:$1|$1}}]] nas mudanças recentes.",
- "nuke-list": "As páginas a seguir foram criadas recentemente por [[Special:Contributions/$1|{{GENDER:$1|$1}}]]; \nintroduza um comentário e pressione o botão a seguir para eliminá-las.",
+ "nuke-list": "As páginas a seguir foram criadas recentemente por [[Special:Contributions/$1|{{GENDER:$1|$1}}]]; \nintroduza um comentário e pressione o botão para eliminá-las.",
"nuke-list-multiple": "As seguintes páginas foram criadas recentemente;\nintroduza um comentário e clique o botão para eliminá-las.",
"nuke-defaultreason": "Eliminação em massa de páginas criadas por [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-multiplepeople": "Eliminação em massa de páginas recentemente adicionadas",
@@ -34,5 +34,6 @@
"nuke-viewchanges": "ver alterações",
"nuke-namespace": "Limitar ao espaço nominal:",
"nuke-linkoncontribs": "eliminação em massa",
- "nuke-linkoncontribs-text": "Eliminar em massa páginas em que este utilizador é o único autor"
+ "nuke-linkoncontribs-text": "Eliminar em massa páginas em que {{GENDER:$1|este utilizador é o único autor|esta utilizadora é a única autora}}",
+ "nuke-confirm": "Está prestes a eliminar {{PLURAL:$1|uma página|$1 páginas}}. Tem a certeza de que pretende {{PLURAL:$1|eliminá-la|eliminá-las}}?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/qqq.json b/www/wiki/extensions/Nuke/i18n/qqq.json
index 0aeae899..4604066f 100644
--- a/www/wiki/extensions/Nuke/i18n/qqq.json
+++ b/www/wiki/extensions/Nuke/i18n/qqq.json
@@ -41,5 +41,6 @@
"nuke-viewchanges": "Used as link text.\n\nThe link points to History page of the page.\n\nThis message follows:\n* {{msg-mw|nuke-editby}} and {{msg-mw|comma-separator}}\n* or empty string (if username is empty).\n{{Identical|View changes}}",
"nuke-namespace": "Label shown on [[Special:Nuke]] in front of the namespace input that allows choosing a namespace to filter the search by",
"nuke-linkoncontribs": "Used as link text which is used on [[Special:Contributions]] and [[Special:DeletedContributions]].\n\nOnly added if a user has rights to nuke pages.\n\nThe link has the tooltip {{msg-mw|Nuke-linkoncontribs-text}}.\n{{Identical|Mass delete}}",
- "nuke-linkoncontribs-text": "Tooltip for the link which is labeled {{msg-mw|Nuke-linkoncontribs}} Parameters:\n* $1 is the target user name used for GENDER."
+ "nuke-linkoncontribs-text": "Tooltip for the link which is labeled {{msg-mw|Nuke-linkoncontribs}} Parameters:\n* $1 is the target user name used for GENDER.",
+ "nuke-confirm": "Message when the user is trying to delete pages."
}
diff --git a/www/wiki/extensions/Nuke/i18n/roa-tara.json b/www/wiki/extensions/Nuke/i18n/roa-tara.json
index 0f9389d6..eb160591 100644
--- a/www/wiki/extensions/Nuke/i18n/roa-tara.json
+++ b/www/wiki/extensions/Nuke/i18n/roa-tara.json
@@ -13,7 +13,7 @@
"nuke-defaultreason": "Scangellazzione de masse de le pàggene aggiunde da [[Special:Contributions/$1|{{GENDER:$1|$1}}]]",
"nuke-multiplepeople": "Scangellazione massive de le pàggene aggiunde de recende",
"nuke-tools": "Stu strumende permette le scangellazziune de masse de le pàggene aggiunde de recende da 'nu certe utende o IP.<br />\nMitte 'u nome de l'utende o l'indirizze IP pe avè 'n'elenghe de le pàggene de scangellà, o lasse vianghe pe tutte l'utinde.",
- "nuke-submit-user": "Veje",
+ "nuke-submit-user": "Elenghe de le pàggene",
"nuke-toggleinvert": "'Nverte",
"nuke-submit-delete": "Scangelle 'a selezione",
"right-nuke": "Scangellazione de masse de le pàggene",
@@ -25,9 +25,10 @@
"nuke-not-deleted": "Pàgene [[:$1]] '''non ge pò''' essere scangellate.",
"nuke-delete-more": "[[Special:Nuke|Scangille cchiù pàggene]]",
"nuke-pattern": "Segnaposte pu nomed'a pàgene:",
- "nuke-nopages-global": "Non ge stonne pàggene nove jndr'à le [[Special:RecentChanges|cangiaminde recende]].",
+ "nuke-nopages-global": "Non ge stonne titole de pàggene ca s'accocchiane cu 'a recerca toje.",
"nuke-viewchanges": "vide le cangiaminde",
"nuke-namespace": "Limite a namespace:",
"nuke-linkoncontribs": "scangellazione de masse",
- "nuke-linkoncontribs-text": "Pàggene da scangellà massive addò stu utende jè 'u sole autore"
+ "nuke-linkoncontribs-text": "Pàggene da scangellazzione massive addò {{GENDER:$1|stu utende}} jè 'u sole autore",
+ "nuke-confirm": "Ste pe scangellà {{PLURAL:$1|'na pàgene|$1 pàggene}}. Sì secure ca vue ccu scangille?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/ru.json b/www/wiki/extensions/Nuke/i18n/ru.json
index 167cb136..1a0912da 100644
--- a/www/wiki/extensions/Nuke/i18n/ru.json
+++ b/www/wiki/extensions/Nuke/i18n/ru.json
@@ -11,7 +11,8 @@
"VasilievVV",
"Александр Сигачёв",
"Ping08",
- "Mailman"
+ "Mailman",
+ "Facenapalm"
]
},
"nuke": "Множественное удаление",
@@ -39,5 +40,6 @@
"nuke-viewchanges": "история правок",
"nuke-namespace": "Ограничить пространством имён:",
"nuke-linkoncontribs": "множественное удаление",
- "nuke-linkoncontribs-text": "Массово удалить страницы, единственным автором которых является этот участник."
+ "nuke-linkoncontribs-text": "Массово удалить страницы, единственным автором которых является {{GENDER:$1|этот участник|эта участница}}.",
+ "nuke-confirm": "Вы собираетесь удалить {{PLURAL:$1|одну страницу|$1 страниц}}. Вы уверены, что хотите это сделать?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/sd.json b/www/wiki/extensions/Nuke/i18n/sd.json
index 20078e10..fe30ebdc 100644
--- a/www/wiki/extensions/Nuke/i18n/sd.json
+++ b/www/wiki/extensions/Nuke/i18n/sd.json
@@ -1,8 +1,15 @@
{
"@metadata": {
"authors": [
- "Mehtab ahmed"
+ "Mehtab ahmed",
+ "Indus Asia"
]
},
- "nuke-viewchanges": "تبديليون ڏيکاريو"
+ "nuke": "جھجھي ڊاھ",
+ "nuke-desc": "انتظام-ڪارن کي صفحن [[Special:Nuke|ججھي ڊاھ]] جي قابليت ڏئي ٿو",
+ "nuke-submit-delete": "چونڊيل ڊاھيو",
+ "right-nuke": "جھجھي ڊاھ وارا صفحا",
+ "nuke-viewchanges": "تبديليون ڏيکاريو",
+ "nuke-linkoncontribs": "جھجھي ڊاھ",
+ "nuke-linkoncontribs-text": "صفحن جي ججھي ڊاھ ڪريو جتي {{GENDER:$1|ھي واپرائيندڙ}} اڪيلو ليکڪ آھي"
}
diff --git a/www/wiki/extensions/Nuke/i18n/uk.json b/www/wiki/extensions/Nuke/i18n/uk.json
index 13f05b4e..ff1ae790 100644
--- a/www/wiki/extensions/Nuke/i18n/uk.json
+++ b/www/wiki/extensions/Nuke/i18n/uk.json
@@ -34,9 +34,10 @@
"nuke-not-deleted": "Сторінка [[:$1]] '''не може''' бути вилучена.",
"nuke-delete-more": "[[Special:Nuke|Масове вилучення сторінок]]",
"nuke-pattern": "Шаблон назви сторінки:",
- "nuke-nopages-global": "У [[Special:RecentChanges|нових редагуваннях]] немає нових сторінок.",
+ "nuke-nopages-global": "Немає назв сторінок, які б відповідали Вашому пошуковому запиту.",
"nuke-viewchanges": "переглянути зміни",
"nuke-namespace": "Обмежити за простором назв:",
"nuke-linkoncontribs": "масове вилучення",
- "nuke-linkoncontribs-text": "Масове вилучення сторінок, де цей користувач є єдиним автором"
+ "nuke-linkoncontribs-text": "Масове вилучення сторінок, де {{GENDER:$1|цей користувач є єдиним автором|ця користувачка є єдиною авторкою}}",
+ "nuke-confirm": "Ви збираєтесь вилучити {{PLURAL:$1|$1 сторінку|$1 сторінки|$1 сторінок}}. Ви впевнені, що хочете продовжити?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/zh-hans.json b/www/wiki/extensions/Nuke/i18n/zh-hans.json
index 36e94e91..2e4de671 100644
--- a/www/wiki/extensions/Nuke/i18n/zh-hans.json
+++ b/www/wiki/extensions/Nuke/i18n/zh-hans.json
@@ -40,5 +40,6 @@
"nuke-viewchanges": "查看变更",
"nuke-namespace": "限制名字空间为:",
"nuke-linkoncontribs": "大量删除",
- "nuke-linkoncontribs-text": "大量删除仅{{GENDER:$1|此用户}}为作者的页面"
+ "nuke-linkoncontribs-text": "大量删除仅{{GENDER:$1|此用户}}为作者的页面",
+ "nuke-confirm": "您将要删除{{PLURAL:$1|$1个页面}}。您确定要删除么?"
}
diff --git a/www/wiki/extensions/Nuke/i18n/zh-hant.json b/www/wiki/extensions/Nuke/i18n/zh-hant.json
index 7642e812..5f99195f 100644
--- a/www/wiki/extensions/Nuke/i18n/zh-hant.json
+++ b/www/wiki/extensions/Nuke/i18n/zh-hant.json
@@ -9,7 +9,8 @@
"Mark85296341",
"Shinjiman",
"LNDDYL",
- "EagerLin"
+ "EagerLin",
+ "Hello903hello"
]
},
"nuke": "大量刪除",
@@ -33,9 +34,9 @@
"nuke-not-deleted": "'''無法'''刪除頁面 [[:$1]]。",
"nuke-delete-more": "[[Special:Nuke|刪除更多頁面]]",
"nuke-pattern": "頁面名稱模式:",
- "nuke-nopages-global": "[[Special:RecentChanges|最近更改]] 中沒有新的頁面。",
+ "nuke-nopages-global": "沒有頁面標題符合您的搜尋。",
"nuke-viewchanges": "檢視變更",
"nuke-namespace": "限制命名空間為:",
"nuke-linkoncontribs": "大量刪除",
- "nuke-linkoncontribs-text": "大量刪除此使用者是唯一作者的頁面"
+ "nuke-linkoncontribs-text": "大量刪除{{GENDER:$1|此使用者}}是唯一作者的頁面"
}
diff --git a/www/wiki/extensions/Nuke/includes/NukeHooks.php b/www/wiki/extensions/Nuke/includes/NukeHooks.php
new file mode 100644
index 00000000..fcf2264f
--- /dev/null
+++ b/www/wiki/extensions/Nuke/includes/NukeHooks.php
@@ -0,0 +1,26 @@
+<?php
+
+class NukeHooks {
+
+ /**
+ * Shows link to Special:Nuke on Special:Contributions/username if applicable
+ *
+ * @param int $userId
+ * @param Title $userPageTitle
+ * @param string[] &$toolLinks
+ * @param SpecialPage $sp
+ */
+ public static function nukeContributionsLinks( $userId, $userPageTitle, &$toolLinks,
+ SpecialPage $sp
+ ) {
+ $username = $userPageTitle->getText();
+ if ( $sp->getUser()->isAllowed( 'nuke' ) && !IP::isValidRange( $username ) ) {
+ $toolLinks['nuke'] = $sp->getLinkRenderer()->makeKnownLink(
+ SpecialPage::getTitleFor( 'Nuke' ),
+ $sp->msg( 'nuke-linkoncontribs' )->text(),
+ [ 'title' => $sp->msg( 'nuke-linkoncontribs-text', $username )->text() ],
+ [ 'target' => $username ]
+ );
+ }
+ }
+}
diff --git a/www/wiki/extensions/Nuke/includes/SpecialNuke.php b/www/wiki/extensions/Nuke/includes/SpecialNuke.php
new file mode 100644
index 00000000..17f8a4e1
--- /dev/null
+++ b/www/wiki/extensions/Nuke/includes/SpecialNuke.php
@@ -0,0 +1,407 @@
+<?php
+
+class SpecialNuke extends SpecialPage {
+
+ public function __construct() {
+ parent::__construct( 'Nuke', 'nuke' );
+ }
+
+ public function doesWrites() {
+ return true;
+ }
+
+ /**
+ * @param null|string $par
+ */
+ public function execute( $par ) {
+ $this->setHeaders();
+ $this->checkPermissions();
+ $this->checkReadOnly();
+ $this->outputHeader();
+
+ $currentUser = $this->getUser();
+ if ( $currentUser->isBlocked() ) {
+ $block = $currentUser->getBlock();
+ throw new UserBlockedError( $block );
+ }
+
+ $req = $this->getRequest();
+ $target = trim( $req->getText( 'target', $par ) );
+
+ // Normalise name
+ if ( $target !== '' ) {
+ $user = User::newFromName( $target );
+ if ( $user ) {
+ $target = $user->getName();
+ }
+ }
+
+ $msg = $target === '' ?
+ $this->msg( 'nuke-multiplepeople' )->inContentLanguage()->text() :
+ $this->msg( 'nuke-defaultreason', $target )->
+ inContentLanguage()->text();
+ $reason = $req->getText( 'wpReason', $msg );
+
+ $limit = $req->getInt( 'limit', 500 );
+ $namespace = $req->getVal( 'namespace' );
+ $namespace = ctype_digit( $namespace ) ? (int)$namespace : null;
+
+ if ( $req->wasPosted()
+ && $currentUser->matchEditToken( $req->getVal( 'wpEditToken' ) )
+ ) {
+ if ( $req->getVal( 'action' ) === 'delete' ) {
+ $pages = $req->getArray( 'pages' );
+
+ if ( $pages ) {
+ $this->doDelete( $pages, $reason );
+
+ return;
+ }
+ } elseif ( $req->getVal( 'action' ) === 'submit' ) {
+ $this->listForm( $target, $reason, $limit, $namespace );
+ } else {
+ $this->promptForm();
+ }
+ } elseif ( $target === '' ) {
+ $this->promptForm();
+ } else {
+ $this->listForm( $target, $reason, $limit, $namespace );
+ }
+ }
+
+ /**
+ * Prompt for a username or IP address.
+ *
+ * @param string $userName
+ */
+ protected function promptForm( $userName = '' ) {
+ $out = $this->getOutput();
+
+ $out->addWikiMsg( 'nuke-tools' );
+
+ $formDescriptor = [
+ 'nuke-target' => [
+ 'id' => 'nuke-target',
+ 'default' => $userName,
+ 'label' => $this->msg( 'nuke-userorip' )->text(),
+ 'type' => 'user',
+ 'name' => 'target'
+ ],
+ 'nuke-pattern' => [
+ 'id' => 'nuke-pattern',
+ 'label' => $this->msg( 'nuke-pattern' )->text(),
+ 'maxLength' => 40,
+ 'type' => 'text',
+ 'name' => 'pattern'
+ ],
+ 'namespace' => [
+ 'id' => 'nuke-namespace',
+ 'type' => 'namespaceselect',
+ 'label' => $this->msg( 'nuke-namespace' )->text(),
+ 'all' => 'all',
+ 'name' => 'namespace'
+ ],
+ 'limit' => [
+ 'id' => 'nuke-limit',
+ 'maxLength' => 7,
+ 'default' => 500,
+ 'label' => $this->msg( 'nuke-maxpages' )->text(),
+ 'type' => 'int',
+ 'name' => 'limit'
+ ]
+ ];
+
+ HTMLForm::factory( 'ooui', $formDescriptor, $this->getContext() )
+ ->setName( 'massdelete' )
+ ->setFormIdentifier( 'massdelete' )
+ ->setWrapperLegendMsg( 'nuke' )
+ ->setSubmitTextMsg( 'nuke-submit-user' )
+ ->setSubmitName( 'nuke-submit-user' )
+ ->setAction( $this->getPageTitle()->getLocalURL( 'action=submit' ) )
+ ->setMethod( 'post' )
+ ->addHiddenField( 'wpEditToken', $this->getUser()->getEditToken() )
+ ->prepareForm()
+ ->displayForm( false );
+ }
+
+ /**
+ * Display list of pages to delete.
+ *
+ * @param string $username
+ * @param string $reason
+ * @param int $limit
+ * @param int|null $namespace
+ */
+ protected function listForm( $username, $reason, $limit, $namespace = null ) {
+ $out = $this->getOutput();
+
+ $pages = $this->getNewPages( $username, $limit, $namespace );
+
+ if ( count( $pages ) === 0 ) {
+ if ( $username === '' ) {
+ $out->addWikiMsg( 'nuke-nopages-global' );
+ } else {
+ $out->addWikiMsg( 'nuke-nopages', $username );
+ }
+
+ $this->promptForm( $username );
+
+ return;
+ }
+
+ $out->addModules( 'ext.nuke.confirm' );
+
+ if ( $username === '' ) {
+ $out->addWikiMsg( 'nuke-list-multiple' );
+ } else {
+ $out->addWikiMsg( 'nuke-list', $username );
+ }
+
+ $nuke = $this->getPageTitle();
+
+ $out->addHTML(
+ Xml::openElement( 'form', [
+ 'action' => $nuke->getLocalURL( 'action=delete' ),
+ 'method' => 'post',
+ 'name' => 'nukelist' ]
+ ) .
+ Html::hidden( 'wpEditToken', $this->getUser()->getEditToken() ) .
+ Xml::tags( 'p',
+ null,
+ Xml::inputLabel(
+ $this->msg( 'deletecomment' )->text(), 'wpReason', 'wpReason', 70, $reason
+ )
+ )
+ );
+
+ // Select: All, None, Invert
+ // ListToggle was introduced in 1.27, old code kept for B/C
+ if ( class_exists( 'ListToggle' ) ) {
+ $listToggle = new ListToggle( $this->getOutput() );
+ $selectLinks = $listToggle->getHTML();
+ } else {
+ $out->addModules( 'ext.nuke' );
+
+ $links = [];
+ $links[] = '<a href="#" id="toggleall">' .
+ $this->msg( 'powersearch-toggleall' )->escaped() . '</a>';
+ $links[] = '<a href="#" id="togglenone">' .
+ $this->msg( 'powersearch-togglenone' )->escaped() . '</a>';
+ $links[] = '<a href="#" id="toggleinvert">' .
+ $this->msg( 'nuke-toggleinvert' )->escaped() . '</a>';
+
+ $selectLinks = Xml::tags( 'p',
+ null,
+ $this->msg( 'nuke-select' )
+ ->rawParams( $this->getLanguage()->commaList( $links ) )->escaped()
+ );
+ }
+
+ $out->addHTML(
+ $selectLinks .
+ '<ul>'
+ );
+
+ $wordSeparator = $this->msg( 'word-separator' )->escaped();
+ $commaSeparator = $this->msg( 'comma-separator' )->escaped();
+
+ $linkRenderer = $this->getLinkRenderer();
+ foreach ( $pages as $info ) {
+ /**
+ * @var $title Title
+ */
+ list( $title, $userName ) = $info;
+
+ $image = $title->inNamespace( NS_FILE ) ? wfLocalFile( $title ) : false;
+ $thumb = $image && $image->exists() ?
+ $image->transform( [ 'width' => 120, 'height' => 120 ], 0 ) :
+ false;
+
+ $userNameText = $userName ?
+ $this->msg( 'nuke-editby', $userName )->parse() . $commaSeparator :
+ '';
+ $changesLink = $linkRenderer->makeKnownLink(
+ $title,
+ $this->msg( 'nuke-viewchanges' )->text(),
+ [],
+ [ 'action' => 'history' ]
+ );
+ $out->addHTML( '<li>' .
+ Xml::check(
+ 'pages[]',
+ true,
+ [ 'value' => $title->getPrefixedDBkey() ]
+ ) . '&#160;' .
+ ( $thumb ? $thumb->toHtml( [ 'desc-link' => true ] ) : '' ) .
+ $linkRenderer->makeKnownLink( $title ) . $wordSeparator .
+ $this->msg( 'parentheses' )->rawParams( $userNameText . $changesLink )->escaped() .
+ "</li>\n" );
+ }
+
+ $out->addHTML(
+ "</ul>\n" .
+ Xml::submitButton( $this->msg( 'nuke-submit-delete' )->text() ) .
+ '</form>'
+ );
+ }
+
+ /**
+ * Gets a list of new pages by the specified user or everyone when none is specified.
+ *
+ * @param string $username
+ * @param int $limit
+ * @param int|null $namespace
+ *
+ * @return array
+ */
+ protected function getNewPages( $username, $limit, $namespace = null ) {
+ $dbr = wfGetDB( DB_REPLICA );
+
+ $what = [
+ 'rc_namespace',
+ 'rc_title',
+ 'rc_timestamp',
+ ];
+
+ $where = [ "(rc_new = 1) OR (rc_log_type = 'upload' AND rc_log_action = 'upload')" ];
+
+ if ( class_exists( 'ActorMigration' ) ) {
+ if ( $username === '' ) {
+ $actorQuery = ActorMigration::newMigration()->getJoin( 'rc_user' );
+ $what['rc_user_text'] = $actorQuery['fields']['rc_user_text'];
+ } else {
+ $actorQuery = ActorMigration::newMigration()
+ ->getWhere( $dbr, 'rc_user', User::newFromName( $username, false ) );
+ $where[] = $actorQuery['conds'];
+ }
+ } else {
+ $actorQuery = [ 'tables' => [], 'joins' => [] ];
+ if ( $username === '' ) {
+ $what[] = 'rc_user_text';
+ } else {
+ $where['rc_user_text'] = $username;
+ }
+ }
+
+ if ( $namespace !== null ) {
+ $where['rc_namespace'] = $namespace;
+ }
+
+ $pattern = $this->getRequest()->getText( 'pattern' );
+ if ( !is_null( $pattern ) && trim( $pattern ) !== '' ) {
+ // $pattern is a SQL pattern supporting wildcards, so buildLike
+ // will not work.
+ $where[] = 'rc_title LIKE ' . $dbr->addQuotes( $pattern );
+ }
+ $group = implode( ', ', $what );
+
+ $result = $dbr->select(
+ [ 'recentchanges' ] + $actorQuery['tables'],
+ $what,
+ $where,
+ __METHOD__,
+ [
+ 'ORDER BY' => 'rc_timestamp DESC',
+ 'GROUP BY' => $group,
+ 'LIMIT' => $limit
+ ],
+ $actorQuery['joins']
+ );
+
+ $pages = [];
+
+ foreach ( $result as $row ) {
+ $pages[] = [
+ Title::makeTitle( $row->rc_namespace, $row->rc_title ),
+ $username === '' ? $row->rc_user_text : false
+ ];
+ }
+
+ // Allows other extensions to provide pages to be nuked that don't use
+ // the recentchanges table the way mediawiki-core does
+ Hooks::run( 'NukeGetNewPages', [ $username, $pattern, $namespace, $limit, &$pages ] );
+
+ // Re-enforcing the limit *after* the hook because other extensions
+ // may add and/or remove pages. We need to make sure we don't end up
+ // with more pages than $limit.
+ if ( count( $pages ) > $limit ) {
+ $pages = array_slice( $pages, 0, $limit );
+ }
+
+ return $pages;
+ }
+
+ /**
+ * Does the actual deletion of the pages.
+ *
+ * @param array $pages The pages to delete
+ * @param string $reason
+ * @throws PermissionsError
+ */
+ protected function doDelete( array $pages, $reason ) {
+ $res = [];
+
+ foreach ( $pages as $page ) {
+ $title = Title::newFromText( $page );
+
+ $deletionResult = false;
+ if ( !Hooks::run( 'NukeDeletePage', [ $title, $reason, &$deletionResult ] ) ) {
+ if ( $deletionResult ) {
+ $res[] = $this->msg( 'nuke-deleted', $title->getPrefixedText() )->parse();
+ } else {
+ $res[] = $this->msg( 'nuke-not-deleted', $title->getPrefixedText() )->parse();
+ }
+ continue;
+ }
+
+ $file = $title->getNamespace() === NS_FILE ? wfLocalFile( $title ) : false;
+ $permission_errors = $title->getUserPermissionsErrors( 'delete', $this->getUser() );
+
+ if ( $permission_errors !== [] ) {
+ throw new PermissionsError( 'delete', $permission_errors );
+ }
+
+ if ( $file ) {
+ $oldimage = null; // Must be passed by reference
+ $ok = FileDeleteForm::doDelete( $title, $file, $oldimage, $reason, false )->isOK();
+ } else {
+ $article = new Article( $title, 0 );
+ $ok = $article->doDeleteArticle( $reason );
+ }
+
+ if ( $ok ) {
+ $res[] = $this->msg( 'nuke-deleted', $title->getPrefixedText() )->parse();
+ } else {
+ $res[] = $this->msg( 'nuke-not-deleted', $title->getPrefixedText() )->parse();
+ }
+ }
+
+ $this->getOutput()->addHTML( "<ul>\n<li>" . implode( "</li>\n<li>", $res ) . "</li>\n</ul>\n" );
+ $this->getOutput()->addWikiMsg( 'nuke-delete-more' );
+ }
+
+ /**
+ * Return an array of subpages beginning with $search that this special page will accept.
+ *
+ * @param string $search Prefix to search for
+ * @param int $limit Maximum number of results to return (usually 10)
+ * @param int $offset Number of results to skip (usually 0)
+ * @return string[] Matching subpages
+ */
+ public function prefixSearchSubpages( $search, $limit, $offset ) {
+ if ( !class_exists( 'UserNamePrefixSearch' ) ) { // check for version 1.27
+ return [];
+ }
+ $user = User::newFromName( $search );
+ if ( !$user ) {
+ // No prefix suggestion for invalid user
+ return [];
+ }
+ // Autocomplete subpage as user list - public to allow caching
+ return UserNamePrefixSearch::search( 'public', $search, $limit, $offset );
+ }
+
+ protected function getGroupName() {
+ return 'pagetools';
+ }
+}
diff --git a/www/wiki/extensions/Nuke/tests/phan/config.php b/www/wiki/extensions/Nuke/tests/phan/config.php
new file mode 100644
index 00000000..f40ada12
--- /dev/null
+++ b/www/wiki/extensions/Nuke/tests/phan/config.php
@@ -0,0 +1,19 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ */
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/OATHAuth/CODE_OF_CONDUCT.md b/www/wiki/extensions/OATHAuth/CODE_OF_CONDUCT.md
new file mode 100644
index 00000000..d8e5d087
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/CODE_OF_CONDUCT.md
@@ -0,0 +1 @@
+The development of this software is covered by a [Code of Conduct](https://www.mediawiki.org/wiki/Code_of_Conduct).
diff --git a/www/wiki/extensions/OATHAuth/COPYING b/www/wiki/extensions/OATHAuth/COPYING
new file mode 100644
index 00000000..d159169d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/COPYING
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/www/wiki/extensions/OATHAuth/Gruntfile.js b/www/wiki/extensions/OATHAuth/Gruntfile.js
new file mode 100644
index 00000000..4ce8b94a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/Gruntfile.js
@@ -0,0 +1,41 @@
+/*jshint node:true */
+module.exports = function ( grunt ) {
+ grunt.loadNpmTasks( 'grunt-contrib-jshint' );
+ grunt.loadNpmTasks( 'grunt-banana-checker' );
+ grunt.loadNpmTasks( 'grunt-jsonlint' );
+ grunt.loadNpmTasks( 'grunt-stylelint' );
+
+ grunt.initConfig( {
+ jshint: {
+ options: {
+ jshintrc: true
+ },
+ all: [
+ '**/*.js',
+ '!modules/qrcode.js',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ },
+ banana: {
+ all: 'i18n/'
+ },
+ jsonlint: {
+ all: [
+ '**/*.json',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ },
+ stylelint: {
+ all: [
+ '**/*.css',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ }
+ } );
+
+ grunt.registerTask( 'test', [ 'jshint', 'jsonlint', 'banana', 'stylelint' ] );
+ grunt.registerTask( 'default', 'test' );
+};
diff --git a/www/wiki/extensions/OATHAuth/OATHAuth.alias.php b/www/wiki/extensions/OATHAuth/OATHAuth.alias.php
new file mode 100644
index 00000000..6d59f9a6
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/OATHAuth.alias.php
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Aliases for OATHAuth's special pages
+ *
+ * @file
+ * @ingroup Extensions
+ */
+
+$specialPageAliases = [];
+
+/** English (English) */
+$specialPageAliases['en'] = [
+ 'OATH' => [ 'Two-factor authentication', 'OATH', 'OATHAuth' ],
+];
+
+/** Arabic (العربية) */
+$specialPageAliases['ar'] = [
+ 'OATH' => [ 'أواث', 'أواث_أوث' ],
+];
+
+/** Egyptian Arabic (مصرى) */
+$specialPageAliases['arz'] = [
+ 'OATH' => [ 'اواث', 'اواث_اوث' ],
+];
+
+/** Czech (čeština) */
+$specialPageAliases['cs'] = [
+ 'OATH' => [ 'Dvoufaktorové_ověření' ],
+];
+
+/** Northern Luri (لۊری شومالی) */
+$specialPageAliases['lrc'] = [
+ 'OATH' => [ 'قأسأم' ],
+];
+
+/** Urdu (اردو) */
+$specialPageAliases['ur'] = [
+ 'OATH' => [ 'حلف_نامہ' ],
+];
+
+/** Simplified Chinese (中文(简体)‎) */
+$specialPageAliases['zh-hans'] = [
+ 'OATH' => [ 'OATH验证' ],
+];
+
+/** Traditional Chinese (中文(繁體)‎) */
+$specialPageAliases['zh-hant'] = [
+ 'OATH' => [ 'OATH_認證' ],
+];
diff --git a/www/wiki/extensions/OATHAuth/OATHAuth.php b/www/wiki/extensions/OATHAuth/OATHAuth.php
new file mode 100644
index 00000000..6cf00b0a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/OATHAuth.php
@@ -0,0 +1,29 @@
+<?php
+/**
+ * OATHAuth extension - Support for HMAC based one time passwords
+ *
+ *
+ * For more info see http://mediawiki.org/wiki/Extension:OATHAuth
+ *
+ * @file
+ * @ingroup Extensions
+ * @author Ryan Lane <rlane@wikimedia.org>
+ * @copyright © 2012 Ryan Lane
+ * @license GPL-2.0-or-later
+ */
+
+if ( function_exists( 'wfLoadExtension' ) ) {
+ wfLoadExtension( 'OATHAuth' );
+
+ $wgMessagesDirs['OATHAuth'] = __DIR__ . '/i18n';
+ $wgExtensionMessagesFiles['OATHAuthAlias'] = __DIR__ . '/OATHAuth.alias.php';
+
+ /* wfWarn(
+ 'Deprecated PHP entry point used for OATHAuth extension. Please use wfLoadExtension instead, ' .
+ 'see https://www.mediawiki.org/wiki/Extension_registration for more details.'
+ ); */
+
+ return true;
+} else {
+ die( 'This version of the OATHAuth extension requires MediaWiki 1.25+' );
+}
diff --git a/www/wiki/extensions/OATHAuth/composer.json b/www/wiki/extensions/OATHAuth/composer.json
new file mode 100644
index 00000000..c48241db
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/composer.json
@@ -0,0 +1,25 @@
+{
+ "require-dev": {
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
+ },
+ "scripts": {
+ "lint": "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs": "phpcs -p -s",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
+ "test": [
+ "composer lint",
+ "composer phpcs",
+ "minus-x check ."
+ ]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/extension.json b/www/wiki/extensions/OATHAuth/extension.json
new file mode 100644
index 00000000..c6b58388
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/extension.json
@@ -0,0 +1,120 @@
+{
+ "name": "OATHAuth",
+ "version": "0.2.2",
+ "author": "Ryan Lane",
+ "url": "https://www.mediawiki.org/wiki/Extension:OATHAuth",
+ "descriptionmsg": "oathauth-desc",
+ "type": "other",
+ "requires": {
+ "MediaWiki": ">= 1.31.0"
+ },
+ "license-name": "GPL-2.0-or-later AND GPL-3.0-or-later",
+ "AutoloadClasses": {
+ "ApiOATHValidate": "includes/api/ApiOATHValidate.php",
+ "ApiQueryOATH": "includes/api/ApiQueryOATH.php",
+ "OATHAuthHooks": "includes/OATHAuthHooks.php",
+ "OATHAuthKey": "includes/OATHAuthKey.php",
+ "OATHAuthUtils": "includes/OATHAuthUtils.php",
+ "OATHUserRepository": "includes/OATHUserRepository.php",
+ "HOTP": "includes/lib/hotp.php",
+ "HOTPResult": "includes/lib/hotp.php",
+ "Base32": "includes/lib/base32.php",
+ "OATHUser": "includes/OATHUser.php",
+ "SpecialOATH": "includes/special/SpecialOATH.php",
+ "SpecialOATHEnable": "includes/special/SpecialOATHEnable.php",
+ "SpecialOATHDisable": "includes/special/SpecialOATHDisable.php",
+ "ProxySpecialPage": "includes/special/ProxySpecialPage.php",
+ "TOTPAuthenticationRequest": "includes/auth/TOTPAuthenticationRequest.php",
+ "TOTPSecondaryAuthenticationProvider": "includes/auth/TOTPSecondaryAuthenticationProvider.php"
+ },
+ "AuthManagerAutoConfig": {
+ "secondaryauth": {
+ "TOTPSecondaryAuthenticationProvider":{
+ "class": "TOTPSecondaryAuthenticationProvider",
+ "sort": 50
+ }
+ }
+ },
+ "ExtensionMessagesFiles": {
+ "OATHAuthAlias": "OATHAuth.alias.php"
+ },
+ "Hooks": {
+ "AuthChangeFormFields": [
+ "OATHAuthHooks::onAuthChangeFormFields"
+ ],
+ "TwoFactorIsEnabled": [
+ "OATHAuthHooks::onTwoFactorIsEnabled"
+ ],
+ "LoadExtensionSchemaUpdates": [
+ "OATHAuthHooks::onLoadExtensionSchemaUpdates"
+ ],
+ "GetPreferences": [
+ "OATHAuthHooks::onGetPreferences"
+ ]
+ },
+ "MessagesDirs": {
+ "OATHAuth": [
+ "i18n"
+ ]
+ },
+ "config": {
+ "OATHAuthWindowRadius": 4,
+ "OATHAuthDatabase": false,
+ "OATHAuthSecret": false,
+ "OATHAuthAccountPrefix": false
+ },
+ "ResourceModules": {
+ "ext.oath.showqrcode": {
+ "scripts": [
+ "jquery.qrcode.js",
+ "qrcode.js",
+ "ext.oath.showqrcode.js"
+ ]
+ },
+ "ext.oath.showqrcode.styles": {
+ "styles": [
+ "ext.oath.showqrcode.styles.css"
+ ]
+ }
+ },
+ "ResourceFileModulePaths": {
+ "localBasePath": "modules",
+ "remoteExtPath": "OATHAuth"
+ },
+ "SpecialPages": {
+ "OATH": "SpecialOATH"
+ },
+ "AvailableRights": [
+ "oathauth-enable",
+ "oathauth-api-all"
+ ],
+ "GroupPermissions": {
+ "*": {
+ "oathauth-enable": true
+ }
+ },
+ "GrantPermissions": {
+ "oath": {
+ "oathauth-api-all": true
+ }
+ },
+ "GrantPermissionGroups": {
+ "oath": "authentication"
+ },
+ "APIModules": {
+ "oathvalidate": "ApiOATHValidate"
+ },
+ "APIMetaModules": {
+ "oath": "ApiQueryOATH"
+ },
+ "RateLimits": {
+ "badoath": {
+ "&can-bypass": false,
+ "user": [
+ 10,
+ 60
+ ]
+ }
+ },
+ "manifest_version": 1
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/af.json b/www/wiki/extensions/OATHAuth/i18n/af.json
new file mode 100644
index 00000000..3b7c2234
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/af.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Naudefj"
+ ]
+ },
+ "oathauth-notloggedin": "Aanmelding is verpligtend"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ar.json b/www/wiki/extensions/OATHAuth/i18n/ar.json
new file mode 100644
index 00000000..5c2022c9
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ar.json
@@ -0,0 +1,53 @@
+{
+ "@metadata": {
+ "authors": [
+ "محمد أحمد عبد الفتاح",
+ "علاء",
+ "Meno25",
+ "ديفيد"
+ ]
+ },
+ "oathauth-desc": "يوفر دعم المصادقة باستخدام كلمات مرور لمرة واحدة تستند إلى HMAC",
+ "specialpages-group-oath": "توثيق ذو عاملين",
+ "oathauth-account": "اسم المستخدم:",
+ "oathauth-secret": "رمز أمان التوثيق ذي العاملين:",
+ "oathauth-enable": "تفعيل التوثيق ذي العاملين",
+ "oathauth-scratchtokens": "القائمة التالية عبارة عن قائمة برموز سكراتش للاستخدام لمرة واحدة، يمكن استخدام هذه الرموز المميزة مرة واحدة فقط، وهي للاستخدام في حالات الطوارئ، يُرجَى كتابتها والاحتفاظ بها في مكان آمن، إذا فقدت هاتفك، فهذه الرموز المميزة هي الطريقة الوحيدة لإنقاذ حسابك، '''لن يتم عرض هذه الرموز مرة أخرى أبدا'''.",
+ "oathauth-token": "الرمز",
+ "oathauth-disable": "تعطيل التوثيق ذي العاملين",
+ "oathauth-validatedoath": "شهادات التوثيق ذو العاملين مُعتمدة. سينفذ التوثيق ذو العاملين منذ الآن.",
+ "oathauth-noscratchforvalidation": "لا يمكنك استخدام رمز سكراتش لتأكيد المصادقة الثنائية; تكون رموز الخدوش للنسخ الاحتياطي والاستخدام العرضي فقط، يُرجَى استخدام رمز التحقق من مولد الكود الخاص بك.",
+ "oathauth-failedtovalidateoath": "فشل التحقق من صحة بيانات الاعتماد الثنائية",
+ "oathauth-disabledoath": "تم تعطيل التوثيق ذو العاملين.",
+ "oathauth-prefs-label": "توثيق ذو عاملين:",
+ "oathauth-step1": "الخطوة 1: نزل برنامج عاملي التوثيق",
+ "oathauth-step1-test": "حمل تطبيقًا يساعد في التوثيق ذي العاملين. من الممكن أن يكون تطبيق هاتف (مثل Google Authenticator) أو تطبيقًا لسطح المكتب.",
+ "oathauth-step2": "الخطوة 2: امسح الرمز المربع",
+ "oathauth-step2alt": "أو أدخل رمز الأمان بشكل يدوي:",
+ "oathauth-step3": "الخطوة 3: اكتب الرُموز الواردة في الأسفل",
+ "oathauth-step4": "الخطوة 4: التحقق",
+ "oathauth-entertoken": "أدخل رمز التحقق من جهازك للتأكيد:",
+ "right-oathauth-enable": "تفعيل ميزة التحقق بخطوتين",
+ "action-oathauth-enable": "تفعيل ميزة التحقق بخطوتين",
+ "oathauth-auth-token-label": "الرمز",
+ "oathauth-auth-token-help": "تُستخدَم كلمة المرور لمرة واحدة كعامل ثاني للمصادقة الثنائية.",
+ "oathauth-auth-ui": "رجاءً أدخل رمز التحقق من جهاز المصادقة الخاص بك.",
+ "oathauth-throttled": "هناك الكثير من محاولات التحقق! الرجاء انتظار $1.",
+ "oathauth-login-failed": "فشل التحقق.",
+ "oathauth-describe-provider": "توثيق ذو عاملين (OATH)",
+ "grant-group-authentication": "أداء إجراءات التوثيق لنفسك والآخرين",
+ "grant-oath": "الوصول إلى معلومات المصادقة الثنائية (OATH) للذات وغيرها",
+ "right-oathauth-api-all": "الاستعلام والتحقق من صحة معلومات OATH للنفس والآخرين",
+ "action-oathauth-api-all": "تحقق من حالة OATH",
+ "apihelp-query+oath-description": "تحقق لمعرفة ما إذا تم تمكين المصادقة الثنائية (OATH) للمستخدم.",
+ "apihelp-query+oath-summary": "تحقق لمعرفة ما إذا تم تمكين المصادقة الثنائية (OATH) للمستخدم.",
+ "apihelp-query+oath-param-user": "المستخدم للحصول على معلومات عنه، افتراضي للمستخدم الحالي.",
+ "apihelp-query+oath-example-1": "الحصول على معلومات حول المستخدم الحالي",
+ "apihelp-query+oath-example-2": "الحصول على معلومات حول المستخدم <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "تحقق من صحة رمز المصادقة الثنائية (OATH).",
+ "apihelp-oathvalidate-summary": "تحقق من صحة رمز المصادقة الثنائية (OATH).",
+ "apihelp-oathvalidate-param-user": "مستخدم للتحقق من صحة الرمز المميز له، افتراضي للمستخدم الحالي.",
+ "apihelp-oathvalidate-param-totp": "رمز المصادقة الثنائية (OATH).",
+ "apihelp-oathvalidate-example-1": "تحقق من رمز مميز للمستخدم الحالي",
+ "apihelp-oathvalidate-example-2": "قق من رمز مستخدم <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ast.json b/www/wiki/extensions/OATHAuth/i18n/ast.json
new file mode 100644
index 00000000..ff6b7cd8
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ast.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xuacu"
+ ]
+ },
+ "oathauth-desc": "Ufre soporte d'identificación utilizando contraseñes pa una sola vez basaes en HMAC",
+ "specialpages-group-oath": "Identificación de dos factores",
+ "oathauth-account": "Nome de la cuenta:",
+ "oathauth-secret": "Clave secreta d'identificación en dos pasos:",
+ "oathauth-enable": "Activar la identificación de dos factores",
+ "oathauth-scratchtokens": "La siguiente ye una llista de pases d'un solu usu. Estos pases sólo pueen utilizase una vez, y son pa usu d'emerxencia. Por favor, apúntales y guárdales nun llugar seguru. Si pierdes el teléfonu, estos pases son la única manera de rescatar la cuenta. '''Estos pases nunca volverán a apaecer'''.",
+ "oathauth-token": "Pase",
+ "oathauth-disable": "Desactivar la identificación de dos factores",
+ "oathauth-validatedoath": "Validáronse les credenciales de dos factores. Agora sedrá obligatoria la identificación de dos factores.",
+ "oathauth-noscratchforvalidation": "Nun puedes utilizar un códigu predefiníu pa confirmar la identificación en dos pasos. Esos códigos solo sirven como respaldu y pa usu ocasional. Utiliza un códigu de comprobación del to xenerador de códigos.",
+ "oathauth-failedtovalidateoath": "Nun pudieron validase les credenciales de dos factores",
+ "oathauth-disabledoath": "Desactivada la identificación de dos factores.",
+ "oathauth-prefs-label": "Identificación de dos factores:",
+ "oathauth-step1": "Pasu 1: Descargar un programa d'identificación en dos pasos",
+ "oathauth-step1-test": "Descarga un programa pa identificación en dos pasos. Pué ser una aplicación pa móvil (como Google Authenticator) o d'escritoriu.",
+ "oathauth-step2": "Pasu 2: escanea'l códigu QR",
+ "oathauth-step2alt": "O escribe'l códigu secretu manualmente:",
+ "oathauth-step3": "Pasu 3: Apunta los códigos",
+ "oathauth-step4": "Pasu 4: Comprobación",
+ "oathauth-entertoken": "Escribe'l códigu dende'l preséu d'identificación a comprobar:",
+ "right-oathauth-enable": "Activar la identificación de dos factores",
+ "action-oathauth-enable": "activar la identificación de dos factores",
+ "oathauth-auth-token-label": "Pase",
+ "oathauth-auth-token-help": "La contraseña d'un usu emplegada como segundu factor na autenticación de dos pasos.",
+ "oathauth-auth-ui": "Escribe un códigu de comprobación dende'l preséu d'identificación",
+ "oathauth-throttled": "Demasiaos intentos de comprobación. Espera $1.",
+ "oathauth-login-failed": "Falló la comprobación.",
+ "oathauth-describe-provider": "Identificación de dos factores (OATH).",
+ "grant-group-authentication": "Facer les aiciones d'autenticación propies y pa otros",
+ "grant-oath": "Acceder a la información d'autenticación en dos factores (OAuth) propies y pa otros",
+ "right-oathauth-api-all": "Consultar y validar la información OATH propia y d'otros",
+ "action-oathauth-api-all": "comprobar l'estatus OATH",
+ "apihelp-query+oath-description": "Comprobar si la identificación de dos factores (OATH) ta activada pa un usuariu.",
+ "apihelp-query+oath-summary": "Comprobar si la identificación de dos factores (OATH) tá activada pa un usuariu.",
+ "apihelp-query+oath-param-user": "Usuariu del qu'algamar la información. De mou predetermináu, ye l'usuariu actual.",
+ "apihelp-query+oath-example-1": "Recibir información sobro l'usuariu actual.",
+ "apihelp-query+oath-example-2": "Recibir información sobro l'usuariu <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Validar un pase d'identificación de dos factores (OATH)",
+ "apihelp-oathvalidate-summary": "Validar un pase d'identificación de dos factores (OATH)",
+ "apihelp-oathvalidate-param-user": "Usuariu pal que validar el pase. De mou predetermináu, l'usuariu actual.",
+ "apihelp-oathvalidate-param-totp": "Pase d'identificación de dos factores (OATH).",
+ "apihelp-oathvalidate-example-1": "Validar un pase pal usuariu actual",
+ "apihelp-oathvalidate-example-2": "Validar un pase pal usuariu <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/az.json b/www/wiki/extensions/OATHAuth/i18n/az.json
new file mode 100644
index 00000000..03e76ef2
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/az.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Zpizza",
+ "Wertuose"
+ ]
+ },
+ "oathauth-account": "Hesab adı:",
+ "right-oathauth-enable": "ikifaktorlu autentifikasiyanı tətbiq et"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ba.json b/www/wiki/extensions/OATHAuth/i18n/ba.json
new file mode 100644
index 00000000..f26d589b
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ba.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Айсар",
+ "Вильданова Гюзель",
+ "Ләйсән"
+ ]
+ },
+ "oathauth-step1": "1-се аҙым: ҡушымтаны ҡуйығыҙ",
+ "oathauth-step2alt": "Йә серһүҙҙе ҡулдан яҙығыҙ:",
+ "oathauth-step3": "3-сө аҙым: Кодтарҙы яҙығыҙ",
+ "oathauth-step4": "4-се аҙым: Тикшереү",
+ "oathauth-entertoken": "Тикшереү өсөн кодты мобиль ҡушымта ярҙамында яҙығыҙ:",
+ "oathauth-auth-token-label": "Тамға"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/be-tarask.json b/www/wiki/extensions/OATHAuth/i18n/be-tarask.json
new file mode 100644
index 00000000..88ca9f0e
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/be-tarask.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Red Winged Duck"
+ ]
+ },
+ "specialpages-group-oath": "Двухфактарная аўтэнтыфікацыя"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/be.json b/www/wiki/extensions/OATHAuth/i18n/be.json
new file mode 100644
index 00000000..1b7a519b
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/be.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Artsiom91"
+ ]
+ },
+ "oathauth-account": "Імя ўліковага запісу:",
+ "oathauth-secret": "Двухфактарны сакрэтны ключ аўтэнтыфікацыі:",
+ "oathauth-scratchtokens": "Гэта — спіс аднаразовых токенаў. Гэтыя токены могуць быць выкарыстаны толькі адзін раз і прызначаны для выкарыстання ў надзвычайных сітуацыях. Калі ласка, запішыце іх і захоўвайце ў бяспечным месцы. Калі Вы страціце свой тэлефон, яны будуць адзіным спосабам выратаваць Ваш акаўнт. '''Гэтыя токены болей ніколі не будуць паказаныя'''.",
+ "oathauth-step1": "Этап 1: Спампуйце праграму двухфактарнай аўтэнтыфікацыі",
+ "oathauth-step2": "Этап 2: Адсканіруйце QR-код",
+ "oathauth-step2alt": "Або ўвядзіце сакрэтны код уручную:",
+ "oathauth-step3": "Этап 3: Запішыце скрэтч-коды",
+ "oathauth-step4": "Этап 4: Праверка",
+ "oathauth-entertoken": "Увядзіце код з Вашай прылады праверкі сапраўднасці, каб праверыць:",
+ "right-oathauth-enable": "уключэнне двухфактарнай аўтэнтыфікацыі",
+ "action-oathauth-enable": "уключыць двухфактарную аўтэнтыфікацыю",
+ "oathauth-auth-ui": "Калі ласка, увядзіце код пацвярджэння з прылады праверкі сапраўднасці"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/bg.json b/www/wiki/extensions/OATHAuth/i18n/bg.json
new file mode 100644
index 00000000..917052e1
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/bg.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "StanProg",
+ "ShockD"
+ ]
+ },
+ "specialpages-group-oath": "Двукомпонентно удостоверяване",
+ "oathauth-account": "Име на сметка:",
+ "oathauth-secret": "Таен ключ на двукомпонентното удостоверяване:",
+ "oathauth-enable": "Включване на двукомпонентно удостоверяване",
+ "oathauth-scratchtokens": "Следният списък съдържа еднократни маркери. Тези маркери могат да бъдат използвани само веднъж и са за спешни случаи. Моля, запишете ги и ги пазете на сигурно място. Ако загубите телефона си, тези маркери са единственият начин да спасите сметката си. Тези маркери никога повече няма да бъдат показани.",
+ "oathauth-disable": "Изключване на двукомпонентно удостоверяване",
+ "oathauth-disabledoath": "Двукомпонентното удостоверяване е изключено.",
+ "oathauth-prefs-label": "Двукомпонентно удостоверяване:",
+ "oathauth-step1": "Стъпка 1: Изтегляне на софтуера за двукомпонентно удостоверяване",
+ "oathauth-step1-test": "Изтеглете програма за двукомпонентно удостоверяване. Това може да е мобилно приложение (като Google Authenticator) или настолно приложение",
+ "oathauth-step2": "Стъпка 2: Сканиране на QR кода",
+ "oathauth-step2alt": "Или напишете тайната ръчно:",
+ "oathauth-step3": "Стъпка 3: Запишете кодовете",
+ "oathauth-step4": "Стъпка 4: Потвърждение",
+ "oathauth-entertoken": "Въведете код от устройството Ви за удостоверяване, за проверка:",
+ "right-oathauth-enable": "Включване на двукомпонентно удостоверяване",
+ "action-oathauth-enable": "включване на двукомпонентно удостоверяване",
+ "oathauth-describe-provider": "Двукомпонентно удостоверяване (OATH)."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/bn.json b/www/wiki/extensions/OATHAuth/i18n/bn.json
new file mode 100644
index 00000000..61edf119
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/bn.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aftabuzzaman",
+ "Elias Ahmmad"
+ ]
+ },
+ "oathauth-desc": "HMAC ভিত্তিক এক-কালীন পাসওয়ার্ড ব্যবহার করে প্রমাণীকরণ প্রদান করে",
+ "specialpages-group-oath": "দুই-গুণনীয়ক প্রমাণীকরণ",
+ "oathauth-account": "অ্যাকাউন্টের নাম:",
+ "oathauth-secret": "দুই-গুণনীয়ক প্রমাণীকরণের গোপন চাবি:",
+ "oathauth-enable": "দুই-গুণনীয়ক প্রমাণীকরণ সক্রিয় করুন",
+ "oathauth-scratchtokens": "নিম্নলিখিত তালিকাটি হচ্ছে এককালীন ব্যবহারের স্ক্র্যাচ টোকেনের একটি তালিকা। এই টোকেন শুধুমাত্র একবার ব্যবহার করা যাবে, এবং এগুলি জরুরি ব্যবহারের জন্য। দয়া করে এইগুলি লিখে রাখুন এবং তাদের একটি নিরাপদ স্থানে রাখুন। আপনি যদি আপনার ফোন হারিয়ে ফেলেন, তাহলে এই টোকেনগুলি হচ্ছে আপনার অ্যাকাউন্ট উদ্ধার করার একমাত্র উপায়। '''এই টোকেনগুলি আর কখনো দেখানো হবে না'''।",
+ "oathauth-token": "টোকেন",
+ "oathauth-disable": "দুই-গুণনীয়ক প্রমাণীকরণ নিষ্ক্রিয় করুন",
+ "oathauth-validatedoath": "দুই-গুণনীয়ক পরিচয়পত্র যাচাই করা হয়েছে। এখন থেকে দুই-গুণনীয়ক প্রমাণীকরণ প্রয়োগ করা হবে।",
+ "oathauth-failedtovalidateoath": "দুই-গুণনীয়ক পরিচয়পত্র বৈধকরণ ব্যর্থ হয়েছে",
+ "oathauth-disabledoath": "দুই-গুণনীয়ক প্রমাণীকরণ নিষ্ক্রিয় করুন।",
+ "oathauth-prefs-label": "দুই-গুণনীয়ক প্রমাণীকরণ:",
+ "oathauth-step1": "ধাপ ১: অ্যাপটি ডাউনলোড করুন",
+ "oathauth-step1-test": "আপনার ফোনে দুই-গুণনীয়ক প্রমাণীকরণের জন্য একটি মোবাইল অ্যাপ্লিকেশন (যেমন Google Authenticator) ডাউনলোড করুন।",
+ "oathauth-step2": "ধাপ ২: কিউআর কোডটি স্ক্যান করুন",
+ "oathauth-step2alt": "বা গোপন কোড নিজ হাতে লিখুন:",
+ "oathauth-step3": "ধাপ ৩: স্ক্র্যাচ কোড লিখুন",
+ "oathauth-step4": "ধাপ ৪: নিশ্চিতকরণ",
+ "oathauth-entertoken": "যাচাই করতে আপনার মোবাইল অ্যাপ থেকে একটি কোড লিখুন:",
+ "right-oathauth-enable": "দুই-গুণনীয়ক প্রমাণীকরণ সক্রিয় করে",
+ "action-oathauth-enable": "দুই-গুণনীয়ক প্রমাণীকরণ সক্রিয় করার",
+ "oathauth-auth-token-label": "টোকেন",
+ "oathauth-auth-token-help": "এককালীন পাসওয়ার্ড দুই-গুণনীয়ক প্রমাণীকরণের দ্বিতীয় গুণক হিসেবে ব্যবহৃত হয়।",
+ "oathauth-auth-ui": "আপনার প্রমাণীকরণ ডিভাইস থেকে যাচাইকরণ কোড প্রবেশ করান",
+ "oathauth-throttled": "অনেকগুলি যাচাইয়ের প্রচেষ্টা! অনুগ্রহ করে $1 অপেক্ষা করুন।",
+ "oathauth-login-failed": "যাচাইকরণ ব্যর্থ হয়েছে।",
+ "oathauth-describe-provider": "দুই-গুণনীয়ক প্রমাণীকরণ (OATH)।",
+ "action-oathauth-api-all": "OATH অবস্থা পরীক্ষা করার",
+ "apihelp-oathvalidate-example-1": "বর্তমান ব্যবহারকারীর জন্য একটি টোকেন যাচাই করুন"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/br.json b/www/wiki/extensions/OATHAuth/i18n/br.json
new file mode 100644
index 00000000..d2ed48ce
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/br.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fohanno"
+ ]
+ },
+ "oathauth-token": "Jedouer"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/bs.json b/www/wiki/extensions/OATHAuth/i18n/bs.json
new file mode 100644
index 00000000..028ecf95
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/bs.json
@@ -0,0 +1,32 @@
+{
+ "@metadata": {
+ "authors": [
+ "Srdjan m"
+ ]
+ },
+ "specialpages-group-oath": "Potvrda u 2 koraka",
+ "oathauth-account": "Ime računa:",
+ "oathauth-secret": "Tajni ključ za potvrdu u 2 koraka:",
+ "oathauth-enable": "Uključi potvrdu u 2 koraka",
+ "oathauth-scratchtokens": "Sljedeći spisak sadrži žetone za jednokratnu upotrebu. Mogu se koristiti samo jednom i to u hitnim slučajevima. Zapišite i čuvajte ih na sigurnom mjestu. Ako izgubite telefon, jedino će oni moći spasiti Vaš račun. Ovi žetoni više se nikad neće prikazati.",
+ "oathauth-token": "Žeton",
+ "oathauth-disable": "Isključi potvrdu u 2 koraka",
+ "oathauth-validatedoath": "Podaci potvrđeni. Odsad će se provoditi potvrda u 2 koraka.",
+ "oathauth-failedtovalidateoath": "Ne mogu potvrditi dvofaktorske podatke",
+ "oathauth-disabledoath": "Potvrda u 2 koraka isključena.",
+ "oathauth-prefs-label": "Potvrda u 2 koraka:",
+ "oathauth-step1": "1. korak: Preuzmite program za potvrdu u 2 koraka",
+ "oathauth-step1-test": "Preuzmite program za potvrdu u 2 koraka. Može biti mobilna (naprimjer, Google Authenticator) ili računarska aplikacija",
+ "oathauth-step2": "2. korak: Skenirajte QR kôd",
+ "oathauth-step2alt": "Ili ručno upišite tajnu:",
+ "oathauth-step3": "3. korak: Zapišite kodove",
+ "oathauth-step4": "4. korak: Potvrda",
+ "oathauth-entertoken": "Upišite kôd za potvrdu s Vašeg uređaja:",
+ "right-oathauth-enable": "Uključivanje potvrde u 2 koraka",
+ "action-oathauth-enable": "uključite potvrdu u 2 koraka",
+ "oathauth-auth-token-label": "Žeton",
+ "oathauth-auth-ui": "Upišite kôd za potvrdu s Vašeg uređaja",
+ "oathauth-throttled": "Previše pokušaja potvrde! Sačekajte $1.",
+ "oathauth-login-failed": "Potvrda nije uspjela.",
+ "oathauth-describe-provider": "Potvrda u 2 koraka (OATH)."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ce.json b/www/wiki/extensions/OATHAuth/i18n/ce.json
new file mode 100644
index 00000000..d67b8af4
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ce.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Умар"
+ ]
+ },
+ "oathauth-desc": "НМАСан гӀоьнца бакъхиларна таллам барехь гӀо латтадо, цкъа лелочу паролашца",
+ "specialpages-group-oath": "шина-факторан аутентификаци",
+ "oathauth-account": "Декъашхочун цӀе:",
+ "oathauth-secret": "Шина-факторан аутентификацин къайла догӀа:",
+ "oathauth-enable": "Шина-факторан аутентификаци латае",
+ "oathauth-scratchtokens": "ХӀара бу — цхьауз лелош йоцу токенийн могӀам. ХӀара токенаш цхьауз бен лелош яц, уьш леррина ю чӀогӀа ситуацеш хилча лело. Дехар до, уьш дӀаязъяр а. Ӏалашъяр а. Ахьа хьайн телефон яйахь, цера гӀоьнца хьан аккаунт меттахӀотто йиш хир ю. И токенаш кхий цкъа а гойтур яц.",
+ "oathauth-token": "Токен",
+ "oathauth-disable": "шина-факторан аутентификаци дӀаяйа",
+ "oathauth-failedtovalidateoath": "Шина-факторан аутентификацин хаамаш хьажа цаделий",
+ "oathauth-disabledoath": "шина-факторан аутентификаци дӀаяйина",
+ "oathauth-prefs-label": "Шина-факторан аутентификаци:",
+ "oathauth-step1": "Ког 1: Шина-факторан аутентификацин программа чуяккха",
+ "oathauth-step1-test": "Шина-факторан аутентификацин программа чуяккха, иза хила мега телефонан программа (масала, Google Authenticator) я кхиин",
+ "oathauth-step2": "Ког 2: QR-кодан сканер яккха",
+ "oathauth-step2alt": "Я куьга дӀаязъе къайла код:",
+ "oathauth-step3": "Ког 3: ДӀаязъе скретч кодаш",
+ "oathauth-step4": "Ког 4: Таллар",
+ "oathauth-entertoken": "Хьайн телефон тӀера код дӀаязъе, хьажархьама:",
+ "right-oathauth-enable": "шина-факторан аутентификаци латор",
+ "action-oathauth-enable": "шина-факторан аутентификаци латае",
+ "oathauth-auth-token-label": "Токен",
+ "oathauth-auth-ui": "Дехар до, хьайн телефон тӀера код дӀаязъе, хьажархьама:",
+ "oathauth-login-failed": "Хьажа цаделий",
+ "oathauth-describe-provider": "Шина-факторан аутентификаци (OATH).",
+ "grant-oath": "Шина-факторан аутентификаци (OAUTH) тӀекхачар",
+ "action-oathauth-api-all": "Хьажа OATH статус"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/cs.json b/www/wiki/extensions/OATHAuth/i18n/cs.json
new file mode 100644
index 00000000..1783d100
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/cs.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mormegil",
+ "Urbanecm",
+ "Dvorapa",
+ "Martin Urbanec",
+ "Matěj Suchánek"
+ ]
+ },
+ "oathauth-desc": "Poskytuje podporu pro autentizaci pomocí jednorázových hesel založených na HMAC",
+ "specialpages-group-oath": "Dvoufaktorová autentizace",
+ "oathauth-account": "Název účtu:",
+ "oathauth-secret": "Tajný klíč pro dvoufaktorovou autentizaci:",
+ "oathauth-enable": "Zapnutí dvoufaktorové autentizace",
+ "oathauth-scratchtokens": "Následující seznam obsahuje jednorázové provizorní kódy. Tyto kódy lze použít pouze jednou a slouží pro případ nouze. Opište si je a uchovávejte je na bezpečném místě. Pokud ztratíte svůj telefon, budou tyto kódy jediným způsobem, jak zachránit váš účet. '''Tyto kódy se již nikdy znovu nezobrazí'''.",
+ "oathauth-token": "Kód",
+ "oathauth-disable": "Vypnutí dvoufaktorové autentizace",
+ "oathauth-validatedoath": "Dvoufaktorové přihlášení ověřeno. Odteď bude vynucována dvoufaktorová autentizace.",
+ "oathauth-failedtovalidateoath": "Nepodařilo se ověřit dvoufaktorové přihlášení.",
+ "oathauth-disabledoath": "Dvoufaktorová autentizace vypnuta.",
+ "oathauth-prefs-label": "Dvoufaktorová autentizace:",
+ "oathauth-step1": "Krok 1: Stáhněte si program pro dvoufaktorovou autentizaci",
+ "oathauth-step1-test": "Stáhněte si program nebo mobilní aplikaci (jako je třeba Google Authenticator) pro dvoufaktorovou autentizaci",
+ "oathauth-step2": "Krok 2: Naskenujte QR kód",
+ "oathauth-step2alt": "Nebo tajemství zadejte ručně:",
+ "oathauth-step3": "Krok 3: Zapište si jednorázové kódy",
+ "oathauth-step4": "Krok 4: Ověření",
+ "oathauth-entertoken": "Pro ověření zadejte kód z vašeho autentizačního zařízení:",
+ "right-oathauth-enable": "Zapnutí dvoufaktorové autentizace",
+ "action-oathauth-enable": "zapnout dvoufaktorovou autentizaci",
+ "oathauth-auth-token-label": "Kód",
+ "oathauth-auth-token-help": "Jednorázové heslo používané jako druhý faktor dvoufaktorové autentizace.",
+ "oathauth-auth-ui": "Zadejte prosím ověřovací kód ze svého autentizačního zařízení",
+ "oathauth-throttled": "Příliš mnoho pokusů o ověření! Počkejte prosím $1.",
+ "oathauth-login-failed": "Ověření se nezdařilo.",
+ "oathauth-describe-provider": "Dvoufaktorová autentizace (OATH).",
+ "grant-group-authentication": "Provádění autentizačních akcí pro sebe či ostatní",
+ "grant-oath": "Přístup k informacím o dvoufaktorové autentizaci (OATH) u sebe a ostatních",
+ "right-oathauth-api-all": "Zjišťování a ověřování informací týkajících se OATH u sebe a ostatních"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/de-formal.json b/www/wiki/extensions/OATHAuth/i18n/de-formal.json
new file mode 100644
index 00000000..a42ea9eb
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/de-formal.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kghbln"
+ ]
+ },
+ "oathauth-scratchtokens": "Die folgende Liste ist eine Liste einmalig verwendbarer Sondertoken. Diese Token können jeweils nur einmal verwendet werden und sind für Notfälle vorgesehen. Bitte schreiben Sie sie auf und verwahren Sie sie an einem sicheren Ort. Sofern Ihnen Ihr Mobiltelefon abhanden kommt, werden diese Token die einzige Möglichkeit sein, Ihr Konto zu retten. Diese Token werden Ihnen niemals wieder angezeigt werden."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/de.json b/www/wiki/extensions/OATHAuth/i18n/de.json
new file mode 100644
index 00000000..0b37d951
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/de.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kghbln",
+ "Metalhead64"
+ ]
+ },
+ "oathauth-desc": "Ermöglicht die Authentifizierung mit HMAC-gestützten Einmalpasswörtern",
+ "specialpages-group-oath": "Zwei-Faktor-Authentifizierung",
+ "oathauth-account": "Benutzerkonto:",
+ "oathauth-secret": "Geheimer Schlüssel für die Zwei-Faktor-Authentifizierung:",
+ "oathauth-enable": "Die Zwei-Faktor-Authentifizierung aktivieren",
+ "oathauth-scratchtokens": "Die folgende Liste ist eine Liste einmalig verwendbarer Sondertoken. Diese Token können jeweils nur einmal verwendet werden und sind für Notfälle vorgesehen. Bitte schreibe sie auf und verwahre sie an einem sicheren Ort. Sofern dir dein Mobiltelefon abhanden kommt, werden diese Token die einzige Möglichkeit sein, dein Konto zu retten. '''Diese Token werden dir niemals wieder angezeigt werden'''.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Die Zwei-Faktor-Authentifizierung deaktivieren",
+ "oathauth-validatedoath": "Die Zwei-Faktor-Anmeldeinformationen wurden bestätigt. Die Zwei-Faktor-Authentifizierung wird jetzt durchgesetzt.",
+ "oathauth-noscratchforvalidation": "Du kannst keinen Scratchcode verwenden, um die Zwei-Faktor-Authentifikation zu bestätigen. Scratchcodes sind für Sicherungszwecke und die gelegentliche Nutzung vorgesehen. Bitte verwende einen Verifizierungscode von deinem Codegenerator.",
+ "oathauth-failedtovalidateoath": "Die Zwei-Faktor-Anmeldeinformationen konnten nicht bestätigt werden.",
+ "oathauth-disabledoath": "Die Zwei-Faktor-Authentifizierung wurde deaktiviert.",
+ "oathauth-prefs-label": "Zwei-Faktor-Authentifizierung:",
+ "oathauth-step1": "Schritt 1: Lade ein Zwei-Faktor-Authentifizierungsprogramm herunter",
+ "oathauth-step1-test": "Lade ein Programm zur Zwei-Faktor-Authentifizierung herunter. Das kann eine mobile Anwendung (wie Google Authenticator) oder eine Desktop-Anwendung sein.",
+ "oathauth-step2": "Schritt 2: Scanne den QR-Code",
+ "oathauth-step2alt": "Oder gib das Geheimnis manuell ein:",
+ "oathauth-step3": "Schritt 3: Schreibe die Sondercodes auf",
+ "oathauth-step4": "Schritt 4: Verifizierung",
+ "oathauth-entertoken": "Gib zur Verifizierung einen Code von deinem Authentifizierungsgerät ein:",
+ "right-oathauth-enable": "Die Zwei-Faktor-Authentifizierung aktivieren",
+ "action-oathauth-enable": "die Zwei-Faktor-Authentifizierung zu aktivieren",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "Das Einmalpasswort, verwendet als zweiter Faktor der Zwei-Faktor-Authentifizierung.",
+ "oathauth-auth-ui": "Bitte einen Verifizierungscode vom Authentifizierungsgerät eingeben",
+ "oathauth-throttled": "Zu viele Verifizierungsversuche! Bitte warte $1.",
+ "oathauth-login-failed": "Verifizierung fehlgeschlagen.",
+ "oathauth-describe-provider": "Zwei-Faktor-Authentifizierung (OATH).",
+ "grant-group-authentication": "Authentifizierungs-Aktionen für sich selbst und andere ausführen",
+ "grant-oath": "Auf Zwei-Faktor-Authentifizierungs-Informationen für sich selbst und andere zugreifen",
+ "right-oathauth-api-all": "OATH-Informationen für sich selbst und andere abfragen und validieren",
+ "action-oathauth-api-all": "den OATH-Status zu überprüfen",
+ "apihelp-query+oath-example-1": "Ruft Informationen über den aktuellen Benutzer ab",
+ "apihelp-oathvalidate-description": "Validiert einen Token der Zwei-Faktor-Authentifizierung (OATH).",
+ "apihelp-oathvalidate-param-user": "Benutzer, für den der Token validiert werden soll. Standard ist der aktuelle Benutzer.",
+ "apihelp-oathvalidate-param-totp": "Token der Zwei-Faktor-Authentifizierung (OATH).",
+ "apihelp-oathvalidate-example-1": "Validiert einen Token für den aktuellen Benutzer",
+ "apihelp-oathvalidate-example-2": "Validiert einen Token für den Benutzer <kbd>Beispiel</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/diq.json b/www/wiki/extensions/OATHAuth/i18n/diq.json
new file mode 100644
index 00000000..11543606
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/diq.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Marmase",
+ "Mirzali",
+ "Kumkumuk"
+ ]
+ },
+ "oathauth-token": "Mare"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/dsb.json b/www/wiki/extensions/OATHAuth/i18n/dsb.json
new file mode 100644
index 00000000..fdd6f11d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/dsb.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Derbeth",
+ "Michawiki"
+ ]
+ },
+ "oathauth-desc": "Zmóžnja awtentifkaciju z pomocu raz wužytych gronidłow na zakłaźe HMAC",
+ "specialpages-group-oath": "Dwójofaktorowa awtentifikacija",
+ "oathauth-account": "Kontowe mě dwójofaktoroweje awtentifikacije:",
+ "oathauth-secret": "Dwójofaktorowy pótajmny kluc:",
+ "oathauth-enable": "Dwójofaktorowu awtentifikaciju zmóžniś",
+ "oathauth-scratchtokens": "Slědujuca lisćina jo lisćina raz wužywajobnych specialnych tokenow. Toś te tokeny daju se jano jaden raz wužywaś a su za nuzne pady. Pšosym napiš je a zachowaj je na wěstem městnje. Jolic zgubijoš swój mobilny telefon, budu toś te tokeny jadnučka móžnosć, aby swójo konto wuchował. Toś te tokeny njepokažu śi žednje zas.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Dwójofaktorowu awtentifikaciju znjemóžniś",
+ "oathauth-validatedoath": "Dwójofaktorowe pśizjawjeńske informacije su se wobkšuśili. Dwójofaktorowa awtentifikacija buźo se něnto pśesajźiś.",
+ "oathauth-failedtovalidateoath": "Dwójofaktorowe pśizjawjeńske informacije njejsu dali se wobkšuśiś",
+ "oathauth-disabledoath": "Dwójofaktorowa awtentifikacija jo se znjemóžniła.",
+ "oathauth-prefs-label": "Dwójofaktorowa awtentifikacija:"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/el.json b/www/wiki/extensions/OATHAuth/i18n/el.json
new file mode 100644
index 00000000..a48af8a0
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/el.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Geraki",
+ "Protnet",
+ "Nikosgranturismogt"
+ ]
+ },
+ "oathauth-account": "Όνομα λογαριασμού:",
+ "oathauth-secret": "Μυστικό κλειδί ταυτοποίησης δύο παραγόντων:",
+ "oathauth-disable": "Απενεργοποίηση ελέγχου ταυτότητας δύο παραγόντων",
+ "grant-oath": "Πρόσβαση σε πληροφορίες ταυτοποίησης δύο παραγόντων (OATH) για εαυτόν και άλλους"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/en.json b/www/wiki/extensions/OATHAuth/i18n/en.json
new file mode 100644
index 00000000..09a1e701
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/en.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ryan Lane <rlane@wikimedia.org>",
+ "Tyler Romeo <tylerromeo@gmail.com>"
+ ]
+ },
+ "oathauth-desc": "Provides authentication support using HMAC based one-time passwords",
+ "oath": "OATHAuth",
+ "specialpages-group-oath": "Two-factor authentication",
+ "oathauth-account": "Account name:",
+ "oathauth-secret": "Two-factor authentication secret key:",
+ "oathauth-enable": "Enable two-factor authentication",
+ "oathauth-scratchtokens": "The following list is a list of one-time use scratch tokens. These tokens can only be used once, and are for emergency use. Please write these down and keep them in a secure location. If you lose your phone, these tokens are the only way to rescue your account. '''These tokens will never be shown again'''.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Disable two-factor authentication",
+ "oathauth-validatedoath": "Validated two-factor credentials. Two-factor authentication will now be enforced.",
+ "oathauth-noscratchforvalidation": "You cannot use a scratch code to confirm two-factor authentication. Scratch codes are for backup and incidental use only. Please use a verification code from your code generator.",
+ "oathauth-failedtovalidateoath": "Failed to validate two-factor credentials",
+ "oathauth-disabledoath": "Disabled two-factor authentication.",
+ "oathauth-prefs-label": "Two-factor authentication:",
+ "oathauth-step1": "Step 1: Download a two-factor authentication program",
+ "oathauth-step1-test": "Download a program for two-factor authentication. That can be a mobile application (such as Google Authenticator) or a desktop application",
+ "oathauth-step2": "Step 2: Scan the QR code",
+ "oathauth-step2alt": "Or enter the secret manually:",
+ "oathauth-step3": "Step 3: Write down the scratch codes",
+ "oathauth-step4": "Step 4: Verification",
+ "oathauth-entertoken": "Enter a code from your authentication device to verify:",
+ "right-oathauth-enable": "Enable two-factor authentication",
+ "action-oathauth-enable": "enable two-factor authentication",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "The one-time password used as the second factor of two-factor authentication.",
+ "oathauth-auth-ui": "Please enter a verification code from your authentication device",
+ "oathauth-throttled": "Too many verification attempts! Please wait $1.",
+ "oathauth-login-failed": "Verification failed.",
+ "oathauth-describe-provider": "Two-factor authentication (OATH).",
+ "grant-group-authentication": "Perform authentication actions for self and others",
+ "grant-oath": "Access two-factor authentication (OATH) information for self and others",
+ "right-oathauth-api-all": "Query and validate OATH information for self and others",
+ "action-oathauth-api-all": "check OATH status",
+ "apihelp-query+oath-description": "Check to see if two-factor authentication (OATH) is enabled for a user.",
+ "apihelp-query+oath-summary": "Check to see if two-factor authentication (OATH) is enabled for a user.",
+ "apihelp-query+oath-param-user": "User to get information about. Defaults to the current user.",
+ "apihelp-query+oath-example-1": "Get information about the current user",
+ "apihelp-query+oath-example-2": "Get information about user <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Validate a two-factor authentication (OATH) token.",
+ "apihelp-oathvalidate-summary": "Validate a two-factor authentication (OATH) token.",
+ "apihelp-oathvalidate-param-user": "User to validate token for. Defaults to the current user.",
+ "apihelp-oathvalidate-param-totp": "Two-factor authentication (OATH) token.",
+ "apihelp-oathvalidate-example-1": "Validate a token for the current user",
+ "apihelp-oathvalidate-example-2": "Validate a token for the user <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/es.json b/www/wiki/extensions/OATHAuth/i18n/es.json
new file mode 100644
index 00000000..073c5356
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/es.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armando-Martin",
+ "Fitoschido",
+ "McDutchie",
+ "Matiia",
+ "Macofe",
+ "Dgstranz"
+ ]
+ },
+ "oathauth-desc": "Proporciona compatibilidad con la autenticación mediante contraseñas en HMAC de un solo uso",
+ "specialpages-group-oath": "Autenticación de dos factores",
+ "oathauth-account": "Nombre de la cuenta:",
+ "oathauth-secret": "Clave secreta de autenticación en dos pasos:",
+ "oathauth-enable": "Activar la autenticación en dos pasos",
+ "oathauth-scratchtokens": "La lista siguiente es una lista de claves de un solo uso. Estas claves solo pueden utilizarse una vez y son para uso de emergencia. Por favor, anótalas y mantenlas en un lugar seguro. Si pierdes el teléfono, estas claves son la única manera de recuperar tu cuenta. Estas claves nunca se mostrarán una segunda vez.",
+ "oathauth-token": "Clave",
+ "oathauth-disable": "Deshabilitar la autenticación de dos factores",
+ "oathauth-validatedoath": "Se han validado las credenciales de dos factores. Ahora se aplicará la autenticación de dos factores.",
+ "oathauth-noscratchforvalidation": "No puedes utilizar códigos predefinidos para confirmar la autenticación de dos pasos. Tales códigos solo sirven como respaldo y para uso ocasional accesorio. Utiliza un código de verificación proveniente de un generador de códigos.",
+ "oathauth-failedtovalidateoath": "Error al validar las credenciales de dos factores",
+ "oathauth-disabledoath": "Se ha deshabilitado la autenticación de dos factores.",
+ "oathauth-prefs-label": "Autenticación en dos etapas:",
+ "oathauth-step1": "Paso 1: descarga un programa de autenticación en dos pasos",
+ "oathauth-step1-test": "Descarga un programa para la autentificación de dos pasos. Puede tratarse de una aplicación móvil (como Google Authenticator) o bien de una aplicación de escritorio",
+ "oathauth-step2": "Paso 2: escanea el código QR",
+ "oathauth-step2alt": "O escribe el secreto manualmente:",
+ "oathauth-step3": "Paso 3: escribe los códigos",
+ "oathauth-step4": "Paso 4: verificación",
+ "oathauth-entertoken": "Escribe un código de tu dispositivo de autentificación para verificar:",
+ "right-oathauth-enable": "Activar la autenticación en dos pasos",
+ "action-oathauth-enable": "activar la autenticación de dos pasos",
+ "oathauth-auth-ui": "Escribe el código de verificación de tu dispositivo de autenticación",
+ "oathauth-login-failed": "Falló la verificación.",
+ "oathauth-describe-provider": "Autenticación de dos factores (OATH).",
+ "grant-group-authentication": "Realizar acciones de autentificación para uno mismo y para otros",
+ "grant-oath": "Acceder a la autentificación de dos factores (OATH) para uno mismo y para otros",
+ "right-oathauth-api-all": "Consultar y validar la inofrmación OATH para uno mismo y para otros",
+ "action-oathauth-api-all": "verificar el estado de OATH",
+ "apihelp-query+oath-description": "Comprobar si la autentificación de dos factores (OATH) está habilitada para un usuario.",
+ "apihelp-query+oath-param-user": "Usuario del que obtener información. Por defecto, se trata del usuario actual.",
+ "apihelp-query+oath-example-1": "Obtener información sobre el usuario actual",
+ "apihelp-query+oath-example-2": "Obtener información sobre el usuario <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/et.json b/www/wiki/extensions/OATHAuth/i18n/et.json
new file mode 100644
index 00000000..cacea021
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/et.json
@@ -0,0 +1,25 @@
+{
+ "@metadata": {
+ "authors": [
+ "Avjoska",
+ "Cumbril",
+ "Pikne"
+ ]
+ },
+ "oathauth-account": "Konto nimi:",
+ "oathauth-secret": "Kaheastmelise autentimise salavõti:",
+ "oathauth-enable": "Luba kaheastmeline autentimine",
+ "oathauth-scratchtokens": "All on ühekordsete koodide nimekiri. Igat koodi saab kasutada vaid ühel korral, koodid on mõeldud hädaolukorra jaoks. Kirjuta koodid üles ja pane turvalisse kohta hoiule. Kui peaksid telefoni kaotama, on need koodid ainus võimalus oma kontot päästa. '''Allolevaid koode rohkem ei kuvata'''.",
+ "oathauth-prefs-label": "Kaheastmeline autentimine:",
+ "oathauth-step1": "Samm 1: laadi alla kaheastmelise autentimise rakendus",
+ "oathauth-step1-test": "Laadi alla kaheastmelise autentimise programm. See võib olla mobiilirakendus (näiteks Google Authenticator) või lauaarvuti rakendus.",
+ "oathauth-step2": "Samm 2: skaneeri QR-kood",
+ "oathauth-step2alt": "Või sisesta salavõti käsitsi.",
+ "oathauth-step3": "Samm 3: kirjuta üles ühekordsed koodid",
+ "oathauth-step4": "Samm 4: kinnitamine",
+ "oathauth-entertoken": "Kinnitamiseks sisesta autentimisseadmest pärit kood:",
+ "right-oathauth-enable": "Lubada kaheastmelist autentimist",
+ "action-oathauth-enable": "kaheastmelist autentimist lubada",
+ "grant-oath": "Juurdepääs enda ja teiste kaheastmelise autentimise (OATH) andmetele",
+ "right-oathauth-api-all": "Pärida ja valideerida enda ja teiste OATH-i teavet"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/fa.json b/www/wiki/extensions/OATHAuth/i18n/fa.json
new file mode 100644
index 00000000..e52d8986
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/fa.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armin1392",
+ "Ebraminio",
+ "Alirezaaa",
+ "Huji",
+ "Reza1615",
+ "Ladsgroup"
+ ]
+ },
+ "oathauth-desc": "پشتیبانی از اعتبارسنجی با استفاده از گذرواژه‌های یکبار مصرف مبتنی بر اچ‌ام‌ای‌سی",
+ "specialpages-group-oath": "اعتبارسنجی دومرحله‌ای",
+ "oathauth-account": "نام حساب:",
+ "oathauth-secret": "کلید مخفی ورود دومرحله‌ای:",
+ "oathauth-enable": "فعال کردن اعتبارسنجی دومرحله‌ای",
+ "oathauth-scratchtokens": "فهرست زیر، فهرست یک‌بار مصرف نشانه‌های مخفی است. این نشانه‌ها می‌تواند فقط یک بار مورد استفاده قرار گیرند، و برای ضرورت استفاده می‌شوند. لطفاً این‌ها را برروی کاغذ یا جایی بنویسید و آن‌ها را در محل امنی نگهدارید. اگر گوشی خود رو گم کردید، این نشانه‌ها تنها راه نجات حساب شما هستند. این نشانه‌ها هرگز دوباره نشان داده نخواهند شد.",
+ "oathauth-token": "بلیط",
+ "oathauth-disable": "غیرفعال کردن اعتبارسنجی دومرحله‌ای",
+ "oathauth-validatedoath": "اعتبارنامه‌های دو مرحله‌ای تأیید شدند. اعتبارسنجی دو مرحله‌ای از این پس اعمال خواهد شد.",
+ "oathauth-failedtovalidateoath": "تأیید اعتبارنامه‌های ورود دومرحله‌ای شکست خورد",
+ "oathauth-disabledoath": "غیرفعال کردن اعتبارسنجی دومرحله‌ای.",
+ "oathauth-prefs-label": "اعتبارسنجی دومرحله‌ای:",
+ "oathauth-step1": "قدم ۱: یک برنامه ورود دومرحله‌ای را بارگیری کنید",
+ "oathauth-step1-test": "برنامه‌ای (نظیر Google Authenticator) برای اعتبارسنجی دومرحله‌ای روی دستگاه تلفن همراه خود بارگیری کنید",
+ "oathauth-step2": "قدم ۲: رمزینهٔ پاسخ سریع را پویش کنید",
+ "oathauth-step2alt": "یا رمز را دستی وارد کنید:",
+ "oathauth-step3": "قدم ۳: کدهای دورانداختنی را یادداشت کنید",
+ "oathauth-step4": "قدم ۴: تأیید",
+ "oathauth-entertoken": "کدی که در برنامهٔ روی دستگاه‌تان نمایش داده شده وارد کنید تا تأیید شوید:",
+ "right-oathauth-enable": "فعال‌سازی اعتبارسنجی دومرحله‌ای",
+ "action-oathauth-enable": "فعال‌سازی اعتبارسنجی دومرحله‌ای",
+ "oathauth-auth-token-label": "بلیط",
+ "oathauth-auth-token-help": "گذرواژهٔ یکبار مصرف قابل استفاده به عنوان عامل دوم در اعتبارسنجی دومرحله‌ای",
+ "oathauth-auth-ui": "لطفاً کد تأیید را از برنامهٔ روی دستگاه همراه خود وارد کنید",
+ "oathauth-throttled": "تعداد تلاش‌ها برای تأیید بیش از حد مجاز بود! لطفاً $1 صبر کنید.",
+ "oathauth-login-failed": "تأیید شکست خورد.",
+ "oathauth-describe-provider": "اعتبارسنجی دومرحله‌ای (OATH).",
+ "grant-group-authentication": "انجام اعمال اعتبارسنجی برای خودتان و دیگران",
+ "grant-oath": "دسترسی به اطلاعات اعتبارسنجی دومرحله‌ای (OATH) برای خودتان و دیگران",
+ "right-oathauth-api-all": "پرسمان و تأیید اطلاعات OATH برای خودتان و دیگران",
+ "apihelp-query+oath-description": "بررسی این که آیا اعتبارسنجی دومرحله‌ای (OATH) برای یک کاربر فعال شده‌است.",
+ "apihelp-query+oath-param-user": "کاربری که در موردش اطلاعات می‌گیرید. پیش‌فرض، حساب کاربری جاری است.",
+ "apihelp-query+oath-example-1": "گرفتن اطلاعات در مورد کاربر جاری",
+ "apihelp-query+oath-example-2": "گرفتن اطلاعات در مورد کاربر <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "تأیید یک بلیط اعتبارسنجی دومرحله‌ای (OATH)",
+ "apihelp-oathvalidate-param-user": "کاربری که بلیط برایش تأیید می‌شود. پیش‌فرض، حساب کاربری جاری است.",
+ "apihelp-oathvalidate-param-totp": "بلیط اعتبارسنجی دومرحله‌ای (OATH).",
+ "apihelp-oathvalidate-example-1": "تأیید یک بلیط برای کاربر جاری",
+ "apihelp-oathvalidate-example-2": "تأیید یک بلیط برای کاربر <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/fi.json b/www/wiki/extensions/OATHAuth/i18n/fi.json
new file mode 100644
index 00000000..925e5d18
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/fi.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mikahama",
+ "Stryn",
+ "Pxos",
+ "Nike"
+ ]
+ },
+ "specialpages-group-oath": "Kaksivaiheinen tunnistautuminen",
+ "oathauth-account": "Tilin nimi:",
+ "oathauth-secret": "Kaksivaiheisen tunnistautumisen salausavain:",
+ "oathauth-enable": "Ota käyttöön kaksivaiheinen tunnistautuminen",
+ "oathauth-token": "Avain",
+ "oathauth-disable": "Poista käytöstä kaksivaiheinen tunnistautuminen",
+ "oathauth-prefs-label": "Kaksivaiheinen tunnistautuminen:",
+ "oathauth-step1": "Vaihe 1: Lataa kaksivaiheisen tunnistautumisen sovellus",
+ "oathauth-step2": "Vaihe 2: Skannaa QR-koodi",
+ "oathauth-step2alt": "Tai syötä salainen tunnus käsin:",
+ "oathauth-step4": "Vaihe 4: Vahvistus",
+ "right-oathauth-enable": "Ottaa käyttöön kaksivaiheinen tunnistautuminen",
+ "action-oathauth-enable": "ottaa käyttöön kaksivaiheista tunnistautumista",
+ "oathauth-auth-token-label": "Avain",
+ "oathauth-auth-ui": "Syötä vahvistuskoodi tunnistautumislaitteestasi",
+ "action-oathauth-api-all": "tarkistaa OATH-tilaa"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/fr.json b/www/wiki/extensions/OATHAuth/i18n/fr.json
new file mode 100644
index 00000000..90c8ceb4
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/fr.json
@@ -0,0 +1,62 @@
+{
+ "@metadata": {
+ "authors": [
+ "Crochet.david",
+ "Gomoko",
+ "Peter17",
+ "Sherbrooke",
+ "Manaviko",
+ "Orlodrim",
+ "Verdy p",
+ "Wladek92",
+ "Yasten",
+ "McDutchie",
+ "Trial",
+ "Urhixidur",
+ "Thibaut120094"
+ ]
+ },
+ "oathauth-desc": "Prend en charge l’authentification utilisant des mots de passe HMAC à utilisation unique.",
+ "specialpages-group-oath": "Authentification à deux facteurs",
+ "oathauth-account": "Nom du compte :",
+ "oathauth-secret": "Clé secrète d’authentification à deux facteurs :",
+ "oathauth-enable": "Activer l'authentification à deux facteurs",
+ "oathauth-scratchtokens": "La liste suivante est une liste de jetons à gratter à utilisation unique. Ces jetons ne peuvent être utilisés qu'une seule fois, et servent en cas d'urgence. Veuillez les écrire et les conserver dans un endroit sûr. Si vous perdez votre téléphone, ces jetons sont le seul moyen de récupérer votre compte. '''Ces jetons ne seront jamais affichés de nouveau'''.",
+ "oathauth-token": "Jeton",
+ "oathauth-disable": "Désactiver l'authentification à deux facteurs",
+ "oathauth-validatedoath": "Identifications à deux facteurs validées. L'authentification à deux facteurs sera désormais appliquée.",
+ "oathauth-noscratchforvalidation": "Vous ne pouvez pas utiliser un code prédéfini pour confirmer une authentification à deux facteurs. Les codes prédéfinis sont utilisés uniquement pour la sauvegarde et les incidents. Veuillez utiliser un code de vérification de votre générateur de code.",
+ "oathauth-failedtovalidateoath": "Échec de validation des identifications à deux facteurs",
+ "oathauth-disabledoath": "Authentification à deux facteurs désactivée.",
+ "oathauth-prefs-label": "Authentification à deux facteurs :",
+ "oathauth-step1": "Étape 1 : téléchargez un programme d'authentification à deux facteurs",
+ "oathauth-step1-test": "Télécharger un programme pour l’authentification à deux facteurs. Il peut s'agir d'une application mobile (comme Google Authenticator) ou une application de bureau",
+ "oathauth-step2": "Étape 2 : scannez le code QR",
+ "oathauth-step2alt": "Ou entrez le code secret manuellement",
+ "oathauth-step3": "Étape 3 : inscrivez les codes à gratter",
+ "oathauth-step4": "Étape 4 : vérification",
+ "oathauth-entertoken": "Entrez un code à partir de votre équipement d'identification pour vérifier:",
+ "right-oathauth-enable": "Activer l’authentification à deux facteurs",
+ "action-oathauth-enable": "activer l’authentification à deux facteurs",
+ "oathauth-auth-token-label": "Jeton",
+ "oathauth-auth-token-help": "Le mot de passe à usage unique utilisé comme le deuxième facteur d'authentification à deux facteurs.",
+ "oathauth-auth-ui": "Veuillez entrer le code de vérification à partir de votre appareil d’authentification",
+ "oathauth-throttled": "Trop de tentatives de vérification ! Veuillez attendre $1.",
+ "oathauth-login-failed": "Échec de la vérification",
+ "oathauth-describe-provider": "Authentification à deux facteurs (OATH)",
+ "grant-group-authentication": "Effectuer les actions d’authentification pour soi-même et les autres",
+ "grant-oath": "Accéder aux informations (OAuth) d’authentification à deux facteurs pour soi-même et les autres",
+ "right-oathauth-api-all": "Demander et valider les informations OATH pour soi-même et les autres",
+ "action-oathauth-api-all": "vérifier l'état OATH",
+ "apihelp-query+oath-description": "Vérifier si l’authentification à deux facteurs (OATH) est activée pour un utilisateur.",
+ "apihelp-query+oath-summary": "Vérifie si l'authentification à deux facteurs (OATH) est activée chez un utilisateur",
+ "apihelp-query+oath-param-user": "Utilisateur au sujet duquel obtenir des informations. Par défaut, l’utilisateur actuel.",
+ "apihelp-query+oath-example-1": "Obtenir des informations sur l’utilisateur actuel",
+ "apihelp-query+oath-example-2": "Obtenir des informations sur l’utilisateur <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Valider un jeton d’authentification à deux facteurs (OATH).",
+ "apihelp-oathvalidate-summary": "Valider un jeton d’authentification à deux facteurs (OATH).",
+ "apihelp-oathvalidate-param-user": "Utilisateur pour lequel valider le jeton. Par défaut, l’utilisateur actuel.",
+ "apihelp-oathvalidate-param-totp": "Jeton d’authentification à deux facteurs (OATH).",
+ "apihelp-oathvalidate-example-1": "Valider un jeton pour l’utilisateur actuel",
+ "apihelp-oathvalidate-example-2": "Valider un jeton pour l’utilisateur <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/frp.json b/www/wiki/extensions/OATHAuth/i18n/frp.json
new file mode 100644
index 00000000..9ee826f2
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/frp.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "ChrisPtDe"
+ ]
+ },
+ "oathauth-desc": "Balye n’assistance d’ôtentificacion empleyent HMAC basâ sur des contresegnos a usâjo solèt",
+ "specialpages-group-oath": "Ôtentificacion a doux factors",
+ "oathauth-account": "Nom du compto a doux factors :",
+ "oathauth-secret": "Cllâf secrèta a doux factors :",
+ "oathauth-enable": "Activar l’ôtentificacion a doux factors",
+ "oathauth-token": "Jeton",
+ "oathauth-disable": "Dèsactivar l’ôtentificacion a doux factors",
+ "oathauth-failedtovalidateoath": "Falyita de la validacion de les refèrences a doux factors",
+ "oathauth-disabledoath": "Ôtentificacion a doux factors dèsactivâye."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/gl.json b/www/wiki/extensions/OATHAuth/i18n/gl.json
new file mode 100644
index 00000000..8c5d11cc
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/gl.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Toliño",
+ "Elisardojm",
+ "Banjo"
+ ]
+ },
+ "oathauth-desc": "Proporciona un soporte de autenticación mediante HMAC baseado en contrasinais dunha soa vez",
+ "specialpages-group-oath": "Autenticación de dous factores",
+ "oathauth-account": "Nome da conta:",
+ "oathauth-secret": "Clave secreta de autenticación de dous factoresː",
+ "oathauth-enable": "Activar a autenticación de dous factores",
+ "oathauth-scratchtokens": "A seguinte é unha lista de pases dun só uso. Estes pases unicamente se poden empregar unha vez, e son para casos de emerxencia. Escríbaos nun papel e gárdeos nun lugar seguro. Se perde o seu teléfono, estes pases son o único xeito de recuperar a súa conta. Esta é a única vez que poderá ver os pases.",
+ "oathauth-token": "Pase",
+ "oathauth-disable": "Desactivar a autenticación de dous factores",
+ "oathauth-validatedoath": "Validáronse as credenciais de dous factores. Agora hase aplicar a autenticación de dous factores.",
+ "oathauth-noscratchforvalidation": "Non pode utilizar códigos predefinidos para confirmar a autenticación de dous pasos. Tales códigos só sirven como respaldo e para uso ocasional accesorio. Utilice un código de verificación provinte do seu xerador de códigos.",
+ "oathauth-failedtovalidateoath": "Erro ao validar as credenciais de dous factores",
+ "oathauth-disabledoath": "Desactivouse a autenticación de dous factores.",
+ "oathauth-prefs-label": "Autenticación de dous factores:",
+ "oathauth-step1": "Paso 1: descargue a un programa de autenticación en dous pasos",
+ "oathauth-step1-test": "Descargue un programa para a autentificación en dous pasos. Pode tratarse dunha aplicación móbil (como Google Authenticator) ou ben dunha aplicación de escritorio",
+ "oathauth-step2": "Paso 2: escanee o código QR",
+ "oathauth-step2alt": "Ou escriba o código secreto manualmente:",
+ "oathauth-step3": "Paso 3: escriba os códigos",
+ "oathauth-step4": "Paso 4: verificación",
+ "oathauth-entertoken": "Escriba un código a partir do seu dispositivo de autenticación para verificar:",
+ "right-oathauth-enable": "Activar a autenticación en dous pasos",
+ "action-oathauth-enable": "activar a autenticación de dous pasos",
+ "oathauth-auth-token-label": "Identificador",
+ "oathauth-auth-token-help": "O contrasinal único empregado como segundo factor da autenticación de dous pasos.",
+ "oathauth-auth-ui": "Por favor, introduzca o código de verificación do seu dispositivo de autenticación",
+ "oathauth-throttled": "Demasiados intentos de verificaciónǃ Por favor, espere $1.",
+ "oathauth-login-failed": "Fallou a verificación",
+ "oathauth-describe-provider": "Autenticación de dous factores (OATH).",
+ "grant-group-authentication": "Relizar as accións de autenticación para vostede e para outros",
+ "grant-oath": "Acceder á información (OAuth) de autenticación en dous factores para vostede e para outros",
+ "right-oathauth-api-all": "Consultar e validar a información OATH para vostede e para outros",
+ "action-oathauth-api-all": "verificar o estado de OATH",
+ "apihelp-query+oath-description": "Comprobar se a autenticación en dous factores (OAuth) está activa para un usuario.",
+ "apihelp-query+oath-summary": "Verificar se a autenticación en dous factores (OATH) está activa para un usuario.",
+ "apihelp-query+oath-param-user": "Usuario do que obter a información. Por defecto é o usuario actual.",
+ "apihelp-query+oath-example-1": "Obter información sobre o usuario actual",
+ "apihelp-query+oath-example-2": "Obter información sobre o usuario <kbd>Exemplo</kbd>",
+ "apihelp-oathvalidate-description": "Validar un pase de autenticación en dous factores (OATH)",
+ "apihelp-oathvalidate-summary": "Validar un pase de autenticación en dous factores (OATH)",
+ "apihelp-oathvalidate-param-user": "Usuario ó que validar o pase. Por defecto, o usuario actual.",
+ "apihelp-oathvalidate-param-totp": "Pase de autenticación en dos factores (OATH)",
+ "apihelp-oathvalidate-example-1": "Validar un pase para o usuario actual",
+ "apihelp-oathvalidate-example-2": "Validar un pase para o usuario <kbd>Exemplo</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/he.json b/www/wiki/extensions/OATHAuth/i18n/he.json
new file mode 100644
index 00000000..7892362d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/he.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Guycn2",
+ "Matanya"
+ ]
+ },
+ "oathauth-desc": "תמיכה באימות באמצעות סיסמאות חד־פעמיות מבוססות HMAC",
+ "specialpages-group-oath": "אימות דו־שלבי",
+ "oathauth-account": "שם החשבון:",
+ "oathauth-secret": "המפתח הסודי של האימות הדו־שלבי:",
+ "oathauth-enable": "הפעלת אימות דו־שלבי",
+ "oathauth-scratchtokens": "להלן רשימה של אסימוני גירוד זמניים. אפשר להשתמש באסימונים האלה רק פעם אחת במצב חירום. נא לרשום אותם ולשמור אותם במקום בטוח. אם הטלפון שלך יאבד, האסימונים האלה יהיו דרכך היחידה להציל את החשבון שלך. '''האסימונים האלה לא יוצגו שוב לעולם.'''",
+ "oathauth-token": "אסימון",
+ "oathauth-disable": "כיבוי אימות דו־שלבי",
+ "oathauth-validatedoath": "תקינותם של נתוני האימות הדו־שלבי נבדקה. מעכשיו ייכפה אימות דו־שלבי.",
+ "oathauth-noscratchforvalidation": "לא ניתן להשתמש בקוד גירוד כדי לאשר אימות דו־שלבי. קודי גירוד מיועדים רק לגיבוי ולשימוש אקראי. נא להשתמש בקוד אימות ממחולל הקודים שלך.",
+ "oathauth-failedtovalidateoath": "בדיקת התקינות של נתוני האימות הדו־שלבי נכשלה.",
+ "oathauth-disabledoath": "האימות הדו־שלבי כובה.",
+ "oathauth-prefs-label": "אימות דו־שלבי:",
+ "oathauth-step1": "צעד 1: הורדת תכנית לאימות דו־שלבי",
+ "oathauth-step1-test": "יש להוריד תכנית לאימות דו־שלבי. זה יכול להיות יישום נייד (כגון המאמת של גוגל) או יישום שולחני",
+ "oathauth-step2": "צעד 2: סריקת קוד ה־QR",
+ "oathauth-step2alt": "אפשר גם להזין את המפתח הסודי באופן ידני:",
+ "oathauth-step3": "צעד 3: רישום קודי גירוד",
+ "oathauth-step4": "צעד 4: אישור",
+ "oathauth-entertoken": "נא להזין את הקוד מהמכשיר המאמת שלך לאישור:",
+ "right-oathauth-enable": "הפעלת אימות דו־שלבי",
+ "action-oathauth-enable": "להפעיל אימות דו־שלבי",
+ "oathauth-auth-token-label": "אסימון",
+ "oathauth-auth-token-help": "הסיסמה החד־פעמית שמשמשת בתור הגורם השני של האימות הדו־שלבי.",
+ "oathauth-auth-ui": "נא להזין את קוד האישור ממכשיר האימות שלך",
+ "oathauth-throttled": "יותר מדי ניסיונות אימות! נא לנסות $1.",
+ "oathauth-login-failed": "האימות נכשל.",
+ "oathauth-describe-provider": "אימות דו־שלבי (OATH).",
+ "grant-group-authentication": "ביצוע פעולות זיהוי עבור עצמך ועבור אחרים",
+ "grant-oath": "גישה למידע של אימות דו־שלבי (OATH) על עצמך ועל אחרים",
+ "right-oathauth-api-all": "שליחת שאילתה לקבלת מידע על OATH ובדיקת תקינותו עבור עצמך ועבור אחרים",
+ "action-oathauth-api-all": "בדיקת מצב OATH",
+ "apihelp-query+oath-description": "בדיקה האם האימות הדו־שלבי (OATH) מופעל עבור המשתמש הזה.",
+ "apihelp-query+oath-summary": "בדיקה האם אימות דו־שלבי (OATH) מופעל עבור משתמש.",
+ "apihelp-query+oath-param-user": "על איזה משתמש לקבל מידע. בררת המחדל היא המשתמש הנוכחי.",
+ "apihelp-query+oath-example-1": "קבלת מידע על המשתמש הנוכחי",
+ "apihelp-query+oath-example-2": "קבלת מידע על משתמש <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "בדיקת תקינות של אסימון אימות דו־שלבי (OATH).",
+ "apihelp-oathvalidate-summary": "בדיקת תקינות של אסימון אימות דו־שלבי (OATH).",
+ "apihelp-oathvalidate-param-user": "לאיזה משתמש לאמת את האסימון. בררת המחדל היא המשתמש הנוכחי.",
+ "apihelp-oathvalidate-param-totp": "אסימון אימות דו־שלבי (OATH).",
+ "apihelp-oathvalidate-example-1": "בדיקת תקינות של אסימון עבור המשתמש הנוכחי.",
+ "apihelp-oathvalidate-example-2": "בדיקת אסימון עבור המשתמש <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/hi.json b/www/wiki/extensions/OATHAuth/i18n/hi.json
new file mode 100644
index 00000000..d63c9c7f
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/hi.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ziyaurr",
+ "Smtchahal"
+ ]
+ },
+ "oathauth-scratchtokens": "निम्नलिखित एक-बार उपयोग किये जाने वाले स्क्रैच टोकनो की सूची है। ये टोकन केवल एक बार उपयोग किये जा सकते हैं, तथा ये आपातकालीन उपयोग के लिये हैं। कृपया इन्हें लिखकर किसी सुरक्षित जगह रखें। अपना फ़ोन खो देने पर ये टोकन आपके खाते को बचाने का एकमात्र ज़रिया हैं। '''ये टोकन दोबारा कभी नहीं दिखाए जाएंगें।'''",
+ "apihelp-oathvalidate-description": "दो कारक प्रमाणीकरण (शपथ) की निशानी पोषण करें।",
+ "apihelp-oathvalidate-param-totp": "दो कारक प्रमाणीकरण (शपथ) की निशानी।",
+ "apihelp-oathvalidate-example-1": "वर्तमान उपयोगकर्ता के लिए एक टोकन पोषण करें।",
+ "apihelp-oathvalidate-example-2": "उपयोगकर्ता के लिए एक टोकन मंजूर करें<kbd>उदाहरण</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/hr.json b/www/wiki/extensions/OATHAuth/i18n/hr.json
new file mode 100644
index 00000000..21eacf16
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/hr.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "MaGa"
+ ]
+ },
+ "oathauth-account": "Suradnički račun:",
+ "oathauth-secret": "Tajni ključ za dvostruku provjeru autentičnosti:",
+ "oathauth-enable": "Omogući dvostruku provjeru autentičnosti",
+ "oathauth-scratchtokens": "Sljedeći popis je popis jednokratnih tokena. Mogu se uporabiti jednom, i to u hitnim slučajevima. Zapišite ih i čuvajte ih na sigurnom mjestu. Ako izgubite telefon, ovi tokeni su jedini način da spasite suradnički račun. Ovi tokeni više nikada neće biti prikazani.",
+ "oathauth-prefs-label": "Dvostruka provjera autentičnosti:",
+ "oathauth-step1": "Prvi korak: preuzmite program za dvostruku provjeru autentičnosti",
+ "oathauth-step1-test": "Preuzmite program za dvostruku provjeru autentičnosti. Može biti aplikacija za mobilni uređaj (kao Google Authenticator) ili aplikacija za stolno računalo",
+ "oathauth-step2": "Drugi korak: skenirajte QR kôd",
+ "oathauth-step2alt": "Možete unijeti i ručno:",
+ "oathauth-step3": "Treći korak: zapišite kôdove",
+ "oathauth-step4": "Četvrti korak: provjera",
+ "oathauth-entertoken": "Za provjeru unesite kôd s Vašeg uređaja:",
+ "right-oathauth-enable": "Omogući dvostruku provjeru autentičnosti",
+ "action-oathauth-enable": "omogući dvostruku provjeru autentičnosti"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/hsb.json b/www/wiki/extensions/OATHAuth/i18n/hsb.json
new file mode 100644
index 00000000..bbeb1822
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/hsb.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "oathauth-desc": "Zmóžnja awtentifkaciju z pomocu jónkróć wužiwanych hesłow na zakładźe HMAC",
+ "specialpages-group-oath": "Dwufaktorowa awtentifikacija",
+ "oathauth-account": "Kontowe mjeno dwufaktoroweje awtentifikacije:",
+ "oathauth-secret": "Tajny kluč dwufaktoroweje awtentfikacije:",
+ "oathauth-enable": "Dwufaktorowu awtentifikaciju zmóžnić",
+ "oathauth-scratchtokens": "Slědowaca lisćina je lisćina jónkróć wužiwajomnych specialnych tokenow. Tute tokeny dadźa so jenož jadyn raz wužiwać a su za nuzowe pady. Prošu napisaj je a wobchowaj je na wěstym městnje. Jeli zhubiš swój mobilny telefon, budu tute tokeny jenička móžnosć, zo by swoje konto zachował. Tute tokeny so ći ženje znowa njepokazaja.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Dwufaktorowu awtentifikaciju znjemóžnić",
+ "oathauth-validatedoath": "Dwufaktorowe přizjewjenske informacije su so wobkrućili. Dwufaktorowa awtentifikacija budźe so nětko wukonjeć.",
+ "oathauth-failedtovalidateoath": "Dwufaktorowe přizjewjenske informacije njedachu so wobkrućić",
+ "oathauth-disabledoath": "Dwufaktorowu awtentifikaciju znjemóžnjena.",
+ "oathauth-prefs-label": "Dwufaktorowa awtentifikacija:"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/hu.json b/www/wiki/extensions/OATHAuth/i18n/hu.json
new file mode 100644
index 00000000..d489134e
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/hu.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bencoke",
+ "Tacsipacsi"
+ ]
+ },
+ "specialpages-group-oath": "Kétlépcsős azonosítás",
+ "oathauth-account": "Fióknév:",
+ "oathauth-secret": "Kétlépcsős azonosítás titkos kulcsa:",
+ "oathauth-enable": "Kétlépcsős azonosítás engedélyezése",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Kétlépcsős azonosítás letiltása",
+ "oathauth-validatedoath": "Kétlépcsős azonosítás engedélyezve. Mostantól csak két lépésben tudod azonosítani magad.",
+ "oathauth-failedtovalidateoath": "A kétlépcsős azonosítási adatok ellenőrzése sikertelen",
+ "oathauth-disabledoath": "Kétlépcsős azonosítás letiltva.",
+ "oathauth-prefs-label": "Kétlépcsős azonosítás:",
+ "oathauth-step1": "1. lépés: Alkalmazás letöltése",
+ "oathauth-step1-test": "Tölts le egy kétlépcsős azonosításra szolgáló alkalmazást (pl. Google Hitelesítő) a telefonodra.",
+ "oathauth-step2": "2. lépés: QR-kód beolvasása",
+ "oathauth-step2alt": "Vagy írd be a titkos kódot kézzel:",
+ "oathauth-step4": "4. lépés: Ellenőrzés",
+ "oathauth-entertoken": "Írj be egy kódot a mobilalkalmazásodból az ellenőrzéshez:",
+ "right-oathauth-enable": "kétlépcsős azonosítás engedélyezése",
+ "action-oathauth-enable": "kétlépcsős azonosítás engedélyezése",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "A kétlépcsős bejelentkezés második lépcsőjeként használt egyszeri jelszó.",
+ "oathauth-auth-ui": "Írd be a megerősítő kódot a hitelesítési eszközödről",
+ "oathauth-throttled": "Túl sok hitelesítési kísérlet! Várj $1 ideig.",
+ "oathauth-login-failed": "Ellenőrzés sikertelen",
+ "oathauth-describe-provider": "Kétlépcsős azonosítás (OATH).",
+ "grant-group-authentication": "hitelesítési műveletek végrehajtása magadnak és másoknak",
+ "grant-oath": "kétlépcsős hitelesítés (OATH) információinak elérése magadról és másokról",
+ "right-oathauth-api-all": "OATH-információk lekérdezése és érvényesítése magadról és másokról",
+ "apihelp-query+oath-description": "Annak ellenőrzése, hogy a kétlépcsős azonosítás (OATH) engedélyezve van-e egy felhasználónak.",
+ "apihelp-query+oath-param-user": "A lekérdezendő felhasználó, alapértelmezetten az aktuális.",
+ "apihelp-query+oath-example-1": "Információk az aktuális felhasználóról",
+ "apihelp-query+oath-example-2": "Információk az <kbd>Example</kbd> felhasználóról.",
+ "apihelp-oathvalidate-description": "Kétlépcsős hitelesítés (OATH) tokenjének érvényesítése.",
+ "apihelp-oathvalidate-param-user": "A felhasználó, akinek a tokenjét érvényesíteni szeretnéd, alapértelmezetten az aktuális felhasználó.",
+ "apihelp-oathvalidate-param-totp": "Kétlépcsős azonosítás (OATH) tokenje.",
+ "apihelp-oathvalidate-example-1": "Egy token érvényesítése az aktuális felhasználónak",
+ "apihelp-oathvalidate-example-2": "Egy token érvényesítése az <kbd>Example</kbd> felhasználónak"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/hy.json b/www/wiki/extensions/OATHAuth/i18n/hy.json
new file mode 100644
index 00000000..ec98e86a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/hy.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kareyac",
+ "Xelgen"
+ ]
+ },
+ "oathauth-account": "Հաշվի անունը",
+ "oathauth-auth-ui": "Խնդրում ենք մուտքագրել հաստատման կոդը ձեր նույնականացման սարքից"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ia.json b/www/wiki/extensions/OATHAuth/i18n/ia.json
new file mode 100644
index 00000000..2b5a460e
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ia.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "McDutchie"
+ ]
+ },
+ "oathauth-desc": "Forni supporto de authentication usante contrasignos a uso unic a base de HMAC",
+ "specialpages-group-oath": "Authentication bifactorial",
+ "oathauth-account": "Nomine de conto:",
+ "oathauth-secret": "Clave secrete de authentication bifactorial:",
+ "oathauth-enable": "Activar authentication bifactorial",
+ "oathauth-scratchtokens": "Le sequente lista contine indicios a uso unic. Iste indicios pote esser usate un sol vice e es pro casos de emergentia. Per favor nota los e guarda los in un loco secur. Si tu perde tu telephono, iste indicios es le sol maniera de salvar tu conto. Iste indicios nunquam essera monstrate un altere vice.",
+ "oathauth-token": "Indicio",
+ "oathauth-disable": "Disactivar authentication bifactorial",
+ "oathauth-validatedoath": "Le credentiales bifactorial ha essite validate. Le authentication bifactorial essera applicate desde ora.",
+ "oathauth-failedtovalidateoath": "Impossibile validar credentiales bifactorial",
+ "oathauth-disabledoath": "Le authentication bifactorial ha essite disactivate.",
+ "right-oathauth-enable": "Activar le authentication bifactorial",
+ "action-oathauth-enable": "activar le authentication bifactorial",
+ "oathauth-auth-token-label": "Indicio",
+ "oathauth-auth-token-help": "Le contrasigno a uso singule usate como secunde factor pro le authentication bifactorial.",
+ "oathauth-auth-ui": "Scribe le codice de verification ab tu dispositivo de authentication",
+ "oathauth-throttled": "Troppo de tentativas de verification! Per favor attende $1.",
+ "oathauth-login-failed": "Verification fallite.",
+ "oathauth-describe-provider": "Authentication bifactorial (OATH)."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/id.json b/www/wiki/extensions/OATHAuth/i18n/id.json
new file mode 100644
index 00000000..b697a071
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/id.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Rachmat.Wahidi",
+ "Rachmat04"
+ ]
+ },
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "Kata sandi satu kali digunakan sebagai faktor kedua dari otentikasi dua-faktor.",
+ "oathauth-auth-ui": "Silakan masukkan kode verifikasi dari aplikasi telepon genggam Anda",
+ "oathauth-throttled": "Terlalu banyak percobaan verifikasi dilakukan! Mohon menunggu $1.",
+ "oathauth-login-failed": "Verifikasi gagal.",
+ "oathauth-describe-provider": "Otentikasi dua-faktor (OATH)."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/is.json b/www/wiki/extensions/OATHAuth/i18n/is.json
new file mode 100644
index 00000000..8efd686b
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/is.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sveinn í Felli"
+ ]
+ },
+ "oathauth-account": "Heiti aðgangs:",
+ "oathauth-token": "Teikn",
+ "oathauth-auth-token-label": "Teikn",
+ "oathauth-login-failed": "Staðfesting mistókst."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/it.json b/www/wiki/extensions/OATHAuth/i18n/it.json
new file mode 100644
index 00000000..add891de
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/it.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beta16",
+ "Darth Kule",
+ "Gianfranco",
+ "McDutchie"
+ ]
+ },
+ "oathauth-desc": "Fornisce supporto per l'autenticazione utilizzando password a uso singolo basate su HMAC",
+ "specialpages-group-oath": "Autenticazione a due fattori",
+ "oathauth-account": "Nome utenza:",
+ "oathauth-secret": "Chiave segreta per l'autenticazione a due fattori:",
+ "oathauth-enable": "Abilita autenticazione a due fattori",
+ "oathauth-scratchtokens": "Il seguente è un elenco di token monouso. Questi token possono essere utilizzati solo una volta e sono per casi di emergenza. Sei pregato di annotarteli e tenerli in un luogo sicuro. Se perdi il telefono, questi token sono l'unico modo per recuperare l'accesso al tuo account. '''Questi token non saranno mostrati mai più.'''",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Disabilita autenticazione a due fattori",
+ "oathauth-validatedoath": "Convalidate le credenziali a due fattori. D'ora in poi sarà applicata l'autenticazione a due fattori.",
+ "oathauth-failedtovalidateoath": "Impossibile convalidare le credenziali a due fattori",
+ "oathauth-disabledoath": "Disabilita autenticazione a due fattori.",
+ "oathauth-prefs-label": "Autenticazione a due fattori:",
+ "oathauth-step1": "Passo 1: scarica un programma per l'autenticazione a due fattori",
+ "oathauth-step1-test": "Scarica un programma per l'autenticazione a due fattori. Può essere un'applicazione mobile (come Google Authenticator) o per desktop.",
+ "oathauth-step2": "Passo 2: scansiona il codice QR",
+ "oathauth-step2alt": "O inserisci il codice segreto manualmente:",
+ "oathauth-step3": "Passo 3: scrivi il codice 'graffiato'",
+ "oathauth-step4": "Passo 4: verifica",
+ "oathauth-entertoken": "Inserisci un codice dal tuo dispositivo di autenticazione per verificare:",
+ "right-oathauth-enable": "Abilita autenticazione a due fattori",
+ "action-oathauth-enable": "abilitare l'autenticazione a due fattori",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "La password a uso singolo utilizzata come secondo fattore per l'autenticazione a due fattori.",
+ "oathauth-auth-ui": "Inserisci il codice di verifica dal tuo dispositivo di autenticazione",
+ "oathauth-throttled": "Troppi tentativi di verifica! Attendi $1.",
+ "oathauth-login-failed": "Verifica non riuscita.",
+ "oathauth-describe-provider": "Autenticazione a due fattori (OATH).",
+ "apihelp-query+oath-example-1": "Ottieni informazioni sull'utente attuale",
+ "apihelp-query+oath-example-2": "Ottieni informazioni sull'utente <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Convalida un token di autenticazione a due fattori (OATH).",
+ "apihelp-oathvalidate-param-user": "Utente per cui convalidare il token. Valore predefinito è l'utente attuale.",
+ "apihelp-oathvalidate-param-totp": "Token di autenticazione a due fattori (OATH).",
+ "apihelp-oathvalidate-example-1": "Convalida un token per l'utente attuale",
+ "apihelp-oathvalidate-example-2": "Convalida un token per l'utente <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ja.json b/www/wiki/extensions/OATHAuth/i18n/ja.json
new file mode 100644
index 00000000..cc675bcd
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ja.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Shirayuki",
+ "ネイ",
+ "Yusuke1109"
+ ]
+ },
+ "oathauth-desc": "ワンタイムパスワードに基づいた HMAC を使用する認証機能を提供する",
+ "specialpages-group-oath": "二要素認証",
+ "oathauth-account": "アカウント名:",
+ "oathauth-secret": "二要素認証の秘密鍵:",
+ "oathauth-enable": "二要素認証の有効化",
+ "oathauth-scratchtokens": "以下は、一度しか使用できないトークンの一覧です。これらのトークンは一度しか使用できず、緊急用です。これらを書き留めて、安全な場所に保管してください。携帯電話を紛失した際に、これらのトークンがあなたのアカウントを救済する唯一の手段になります。'''これらのトークンは二度と表示されません'''。",
+ "oathauth-token": "トークン",
+ "oathauth-disable": "二要素認証の無効化",
+ "oathauth-validatedoath": "二要素信用情報を検証しました。二要素認証を実行します。",
+ "oathauth-failedtovalidateoath": "二要素信用情報の検証に失敗しました。",
+ "oathauth-disabledoath": "二要素認証を無効にしました。",
+ "oathauth-prefs-label": "二要素認証:",
+ "right-oathauth-enable": "二要素認証を有効にする",
+ "action-oathauth-enable": "二要素認証の有効化"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/jv.json b/www/wiki/extensions/OATHAuth/i18n/jv.json
new file mode 100644
index 00000000..bc9b27b8
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/jv.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "NoiX180"
+ ]
+ },
+ "specialpages-group-oath": "Otèntifikasi rong faktor",
+ "oathauth-account": "Jeneng akun:",
+ "oathauth-secret": "Kunci wani otèntifikasi rong faktor:",
+ "oathauth-enable": "Urubaké otèntifikasi rong faktor",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Patèni otèntifikasi rong faktor",
+ "oathauth-failedtovalidateoath": "Wurung validhasi krédhènsial rong faktor",
+ "oathauth-disabledoath": "Patèni otèntifikasi rong faktor.",
+ "oathauth-prefs-label": "Otèntifikasi rong faktor:",
+ "oathauth-step1": "Lampah 1: Undhuh program otèntifikasi rong faktor",
+ "oathauth-step2alt": "Utawa isinen wadiné kanthi manual:",
+ "oathauth-step3": "Lampah 3: Tulisen kodhe rèngrèngan",
+ "oathauth-step4": "Lampah 5: Vèrifikasi",
+ "oathauth-entertoken": "Isinen kodhe saka piranti otèntifikasi kanggo vèrifikasi:",
+ "right-oathauth-enable": "Urubaké otèntifikasi rong faktor",
+ "action-oathauth-enable": "urubaké otèntifikasi rong faktor",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-ui": "Mangga isinen kodhe vèrifikasi saka piranti otèntifikasiné panjenengan",
+ "oathauth-throttled": "Kakèhan tumindak vèrifikasi! Mangga entènana $1.",
+ "oathauth-login-failed": "Wurung vèrifikasi.",
+ "oathauth-describe-provider": "Otèntifikasi rong faktor (OATH).",
+ "grant-group-authentication": "Ayahi tumindak otèntifikasi kanggo panjenengan dhéwé lan liyan",
+ "grant-oath": "Aksès informasi otèntifikasi rong faktor (OATH) kanggo panjenengan dhéwé lan liyan",
+ "action-oathauth-api-all": "priksa status OATH",
+ "apihelp-query+oath-description": "Priksa yèn otèntifikasi rong faktor (OATH) wis murub tumrap panganggo.",
+ "apihelp-query+oath-param-user": "Panganggo sing informasiné arep digolèki. Modhe gawan ya iku marang panganggo saiki.",
+ "apihelp-query+oath-example-1": "Golèk informasi ngenani panganggo saiki",
+ "apihelp-query+oath-example-2": "Golèk informasi ngenani panganggo <kbd>Conto</kbd>",
+ "apihelp-oathvalidate-description": "Validhasi token otèntifikasi rong faktor (OATH).",
+ "apihelp-oathvalidate-param-user": "Panganggo sing tokené arep divalidhasi. Modhe gawan ya iku marang panganggo saiki.",
+ "apihelp-oathvalidate-param-totp": "Token otèntifikasi rong faktor (OATH).",
+ "apihelp-oathvalidate-example-1": "Validhasi token kanggo panganggo saiki",
+ "apihelp-oathvalidate-example-2": "Validhasi token kanggo panganggo <kbd>Conto</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ka.json b/www/wiki/extensions/OATHAuth/i18n/ka.json
new file mode 100644
index 00000000..a5f3504f
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ka.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "David1010",
+ "Otogi"
+ ]
+ },
+ "specialpages-group-oath": "ორფაქტორიანი იდენტიფიკაცია",
+ "oathauth-account": "ორფაქტორიანი ანგარიშის სახელი:",
+ "oathauth-secret": "ორფაქტორიანი საიდუმლო გასაღები:",
+ "oathauth-enable": "ორფაქტორიანი იდენტიფიკაციის ჩართვა",
+ "oathauth-scratchtokens": "შემდეგი სია წარმოადგენს დაკაწრული ტოკენების გამოყენების ერთჯერად სიას. ეს ტოკენები მხოლოდ ერთხელ შეიძლება იყოს გამოყენებული და განკუთვნილია საგანგებო სიტუაციების სამართავად. გთხოვთ, ჩაიწერეთ ისინი და შეინახეთ უსაფრთხო ადგილას. ტელეფონის დაკარგვის შემთხევაში თქვენი ანგარიშის გადარჩენის ერთადერთი საშუალება ტოკენები იქნება. ეს ტოკენები აღარასოდეს იქნება ნაჩვენები.",
+ "oathauth-token": "ჟეტონი",
+ "oathauth-disable": "ორფაქტორიანი იდენტიფიკაციის გამორთვა",
+ "oathauth-disabledoath": "ორფაქტორიანი იდენტიფიკაცია გამორთულია.",
+ "oathauth-prefs-label": "ორფაქტორიანი ავთენტიკაცია",
+ "oathauth-step1": "ნაბიჯი 1: გადმოწერეთ აპლიკაცია",
+ "oathauth-step1-test": "გადმოწერეთ მიბილური აპლიკაცია ორფაქტორიანი ავთენტიკაციისთვის (მსგავსად Google ავთენტიკატორისა) თქვენ ტელეფონზე",
+ "oathauth-step2": "ნაბიჯი 2: დაასკანირეთ QR კოდი",
+ "oathauth-step2alt": "ან ხელით შეიყვანეთ გასაღები",
+ "oathauth-step3": "ნაბიჯი 3: ჩაიწერეთ დაკაწრული კოდები",
+ "oathauth-step4": "ნაბიჯი 4: ვერიფიკაცია",
+ "oathauth-entertoken": "დასადასტურებლად შეიყვანეთ კოდი თქვენი მობილური აპლიკაციიდან"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ko.json b/www/wiki/extensions/OATHAuth/i18n/ko.json
new file mode 100644
index 00000000..0c5ccfea
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ko.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Priviet",
+ "아라",
+ "Ykhwong",
+ "Jonghaya",
+ "Revi",
+ "Tursetic",
+ "IRTC1015"
+ ]
+ },
+ "oathauth-desc": "일회용 비밀번호에 기초한 HMAC를 사용하여 인증 기능을 제공",
+ "specialpages-group-oath": "2요소 인증",
+ "oathauth-account": "계정 이름:",
+ "oathauth-secret": "2요소 인증 비밀 키:",
+ "oathauth-enable": "2요소 인증 활성화하기",
+ "oathauth-scratchtokens": "다음 목록은 일회용 스크래치 토큰 목록입니다. 이 토큰들은 한 번만 사용할 수 있으며 비상용입니다. 이것들을 적어놓고 안전한 위치에 보관하세요. 전화를 분실할 경우 이 토큰들이 당신의 계정을 찾을 유일한 수단입니다. '''이 토큰들은 다시 볼 수 없습니다'''.",
+ "oathauth-token": "토큰",
+ "oathauth-disable": "2요소 인증 비활성화하기",
+ "oathauth-validatedoath": "2요소 자격 정보를 검증했습니다. 2요소 인증을 실행합니다.",
+ "oathauth-noscratchforvalidation": "2요소 인증을 확인하기 위해 스크래치 코드를 사용할 수 없습니다. 스크래치 코드는 백업용 및 부수적인 용도 전용입니다. 코드 생성기의 인증 코드를 사용해 주십시오.",
+ "oathauth-failedtovalidateoath": "2요소 자격정보를 검증하는 데 실패했습니다",
+ "oathauth-disabledoath": "2요소 인증이 비활성화되었습니다.",
+ "oathauth-prefs-label": "2요소 인증:",
+ "oathauth-step1": "1단계: 2요소 인증 프로그램을 다운로드하세요",
+ "oathauth-step1-test": "2요소 인증을 위한 프로그램을 다운로드하세요. 모바일 애플리케이션(Google Authenticator 등)이나 데스크톱 애플리케이션일 수 있습니다.",
+ "oathauth-step2": "2단계: QR 코드를 스캔하세요",
+ "oathauth-step2alt": "아니면 수동으로 비밀 키를 입력하세요:",
+ "oathauth-step3": "3단계: 스크래치 코드를 기록하세요",
+ "oathauth-step4": "4단계: 확인",
+ "oathauth-entertoken": "확인을 위해 인증 장치로부터 받은 코드를 입력하세요:",
+ "right-oathauth-enable": "2요소 인증 활성화",
+ "action-oathauth-enable": "2요소 인증 활성화",
+ "oathauth-auth-token-label": "토큰",
+ "oathauth-auth-token-help": "2단계 인증의 두 번째 단계로 사용되는 일회용 암호입니다.",
+ "oathauth-auth-ui": "인증 장치의 인증 코드를 넣어주세요",
+ "oathauth-throttled": "너무 많은 인증을 요청했습니다! $1 기다리세요.",
+ "oathauth-login-failed": "인증 검토 실패.",
+ "oathauth-describe-provider": "2단계 인증(OATH)",
+ "grant-group-authentication": "인증을 위해 OAuth 사용",
+ "grant-oath": "자기 자신과 다른 사람에 대한 2요소 인증(OATH) 정보에 접근합니다",
+ "action-oathauth-api-all": "OATH 상태 학인",
+ "apihelp-oathvalidate-description": "2요소 인증 (OATH) 토큰을 검사합니다.",
+ "apihelp-oathvalidate-summary": "2요소 인증 (OATH) 토큰을 검사합니다.",
+ "apihelp-oathvalidate-param-user": "토큰을 확인할 사용자입니다. 기본값은 현재 사용자입니다.",
+ "apihelp-oathvalidate-param-totp": "2요소 인증(OATH) 토큰입니다.",
+ "apihelp-oathvalidate-example-1": "현재 사용자의 토큰 인증",
+ "apihelp-oathvalidate-example-2": "사용자 <kbd>Example</kbd>의 토큰을 검사합니다"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ksh.json b/www/wiki/extensions/OATHAuth/i18n/ksh.json
new file mode 100644
index 00000000..3f3a4663
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ksh.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha"
+ ]
+ },
+ "oathauth-desc": "Määd et Enlogge met enem <code lang=\"en\">HMAC</code>-eijmohl-Paßwoot müjjelesch.",
+ "oath": "OATHAuth — de Login-Pröhvong övver zwai Wähje",
+ "specialpages-group-oath": "Two-factor authentication !FUZZY!! <!--\n\thttps://translatewiki.net/wiki/Thread:Support/About_MediaWiki:Specialpages-group-oath/en\n-->",
+ "oathauth-account": "Der Nahme zom Enlogge för de Login-Pröhvong övver zwai Wähje:",
+ "oathauth-secret": "Der jeheime Schößel för de Login-Pröhvong övver zwai Wähje:",
+ "oathauth-enable": "Donn de Login-Pröhvong övver zwai Wähje enschallde",
+ "oathauth-disable": "Donn de Login-Pröhvong övver zwai Wähje ußschallde",
+ "oathauth-validatedoath": "De Aanjahbe för de Login-Pröhvong övver zwai Wähje sin joht, de Login-Pröhvong övver zwai Wähje wehd jäz ",
+ "oathauth-failedtovalidateoath": "De Aanjahbe för de Login-Pröhvong övver zwai Wähje wohre nit joht.",
+ "oathauth-disabledoath": "Mer han de Login-Pröhvong övver zwai Wähje ußjeschalldt.",
+ "oathauth-prefs-label": "Login-Pröhvong övver zwai Wähje:"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/lb.json b/www/wiki/extensions/OATHAuth/i18n/lb.json
new file mode 100644
index 00000000..1dadae17
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/lb.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robby"
+ ]
+ },
+ "oathauth-account": "Numm vum Kont:",
+ "oathauth-enable": "Authentifikatioun mat zwee Elementer aschalten",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Authentifikatioun mat zwee Elementer ausschalten",
+ "oathauth-disabledoath": "Authentifikatioun mat zwee Elementer ausgeschalt",
+ "oathauth-prefs-label": "Authentifikatioun mat zwee Elementer:",
+ "oathauth-step1": "Schrëtt 1: Den Zwee-Facteur-Authentifikatiounsprogramm eroflueden",
+ "oathauth-step2": "Schrëtt 2: De QR-Code scannen",
+ "oathauth-step4": "Schrëtt 4: Verificatioun",
+ "grant-group-authentication": "Authentifikatiouns-Aktioune fir sech selwer a fir Anerer maachen",
+ "action-oathauth-api-all": "OATH-Status nokucken",
+ "apihelp-query+oath-param-user": "Benotzer vun deem d'Informatioun gefrot gëtt. Standard ass et den aktuelle Benotzer.",
+ "apihelp-query+oath-example-1": "Informatiounen iwwer den aktuelle Benotzer kréien",
+ "apihelp-query+oath-example-2": "Informatiounen iwwer de Benotzer <kbd>Beispill</kbd> kréien",
+ "apihelp-oathvalidate-example-1": "En Token fir den aktuelle Benotzer validéieren"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/lki.json b/www/wiki/extensions/OATHAuth/i18n/lki.json
new file mode 100644
index 00000000..2a2e08d2
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/lki.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hosseinblue"
+ ]
+ },
+ "oathauth-backtopreferences": "بازگشت به اولویت‌ها"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/lt.json b/www/wiki/extensions/OATHAuth/i18n/lt.json
new file mode 100644
index 00000000..968eb05d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/lt.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eitvys200"
+ ]
+ },
+ "oathauth-account": "Paskyros vardas:",
+ "action-oathauth-api-all": "patikrinti OATH būseną"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/lv.json b/www/wiki/extensions/OATHAuth/i18n/lv.json
new file mode 100644
index 00000000..776bd676
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/lv.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Papuass",
+ "Silraks"
+ ]
+ },
+ "oathauth-account": "Konta nosaukums:",
+ "oathauth-enable": "Iespējot divpakāpju autentifikāciju",
+ "oathauth-token": "Marķieris",
+ "right-oathauth-enable": "Iespējot divpakāpju autentifikāciju",
+ "action-oathauth-enable": "iespējot divpakāpju autentifikāciju",
+ "oathauth-auth-token-label": "Marķieris"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/mk.json b/www/wiki/extensions/OATHAuth/i18n/mk.json
new file mode 100644
index 00000000..4610562a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/mk.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06"
+ ]
+ },
+ "oathauth-desc": "Овозможува заверка на корисничката веродостојност со HMAC врз основа на еднократни лозинки",
+ "specialpages-group-oath": "Двочинителска заверка",
+ "oathauth-account": "Име на сметката:",
+ "oathauth-secret": "Таен клуч за двочинителска заверка:",
+ "oathauth-enable": "Овозможување на двочинителска заверка на веродостојноста",
+ "oathauth-scratchtokens": "Ова е список на еднократни шифри. Можат да се користат само еднаш и служат за непредвидени случаи. Запишете ги и чувајте ги на безбедно место. Ако го загубите телефонот, шифрите се единствен начин да си ја повратите сметката. Овие шифри никогаш повеќе нема да се прикажат.",
+ "oathauth-token": "Шифра",
+ "oathauth-disable": "Оневозможување на двочинителска заверка на веродостојноста",
+ "oathauth-validatedoath": "Двочинителското полномоштво е заверено. Сега стапува на сила.",
+ "oathauth-noscratchforvalidation": "Не можете да користите код од грепка за да ја потврдите двочинителската заверка. Овие кодови се резервни, и имаат исклучиво наменска употреба. Послужете се со код од вашиот создавач на кодови.",
+ "oathauth-failedtovalidateoath": "Не успеав да го заверам двочинителското полномоштво",
+ "oathauth-disabledoath": "Двочинителската заверка е оневозможена.",
+ "oathauth-prefs-label": "Двочинителска заверка:",
+ "oathauth-step1": "Чекор 1: Преземете го програмот за двочинителска заверка",
+ "oathauth-step1-test": "Преземете го програмот за двочинителска заверка. Ова може да биде мобилен прилог (како Google Authenticator) или прилог за столен сметач",
+ "oathauth-step2": "Чекор 2: Отчитајте го QR-кодот",
+ "oathauth-step2alt": "Или пак внесете ја тајната рачно:",
+ "oathauth-step3": "Чекор 3: Запишете го кодовите",
+ "oathauth-step4": "Чекор 4: Заверка",
+ "oathauth-entertoken": "Внесете код од вашиот уред на заверка за да потврдите:",
+ "right-oathauth-enable": "Овозможување на двочинителска заверка",
+ "action-oathauth-enable": "овозможување на двочинителска заверката",
+ "oathauth-auth-token-label": "Жетон",
+ "oathauth-auth-token-help": "Еднократната лозинка што служи како втор чинител во двочинителската заверка.",
+ "oathauth-auth-ui": "Внесете потврден код од вашиот уред на заверка",
+ "oathauth-throttled": "Направивте премногу обиди за заверка! Почекајте $1.",
+ "oathauth-login-failed": "Заверката не успеа.",
+ "oathauth-describe-provider": "Двочинителска заверка (OATH).",
+ "grant-group-authentication": "Вршење заверка за себе и други",
+ "grant-oath": "Пристап до податоците за двочинителска заверка (OATH) за себе и други",
+ "right-oathauth-api-all": "Барање и проверка на податоци за OATH за себе и други",
+ "action-oathauth-api-all": "проверување на OATH-статус",
+ "apihelp-query+oath-description": "Проверка дали двочинителската заверка (OATH) е овозможена за даден корисник.",
+ "apihelp-query+oath-summary": "Провери дали е овозможена двочинителската заверка (OATH) за даден корисник.",
+ "apihelp-query+oath-param-user": "За кој корисник да се дадат информации. По основно: тековниот корисник.",
+ "apihelp-query+oath-example-1": "Дај информации за тековниот корисник.",
+ "apihelp-query+oath-example-2": "Дај информации за корисникот <kbd>Пример</kbd>",
+ "apihelp-oathvalidate-description": "Провери шифра за двочинителска заверка (OATH).",
+ "apihelp-oathvalidate-summary": "Провери шифра за двочинителска заверка (OATH).",
+ "apihelp-oathvalidate-param-user": "Корисник чија шифра треба да се завери. По основно: тековниот корисник.",
+ "apihelp-oathvalidate-param-totp": "Шифра за двочинителска заверка (OATH).",
+ "apihelp-oathvalidate-example-1": "Провери шифра за тековниот корисник",
+ "apihelp-oathvalidate-example-2": "Провери шифра за корисникот <kbd>Пример</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ml.json b/www/wiki/extensions/OATHAuth/i18n/ml.json
new file mode 100644
index 00000000..28767c06
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ml.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Praveenp"
+ ]
+ },
+ "oathauth-desc": "എച്ച്.എം.എ.സി. അധിഷ്ഠിത ഒറ്റത്തവണ രഹസ്യവാക്കുക്കൾ വഴി സാധൂകരണം ചെയ്യുന്നു",
+ "specialpages-group-oath": "ദ്വി-ഘടക സാധൂകരണം",
+ "oathauth-account": "അംഗത്വ നാമം:",
+ "oathauth-secret": "ദ്വി-ഘടക സാധൂകരണത്തിനുള്ള രഹസ്യചാവി:",
+ "oathauth-enable": "ദ്വി-ഘടക സാധൂകരണം സജ്ജമാക്കുക",
+ "oathauth-token": "ചീട്ട്",
+ "oathauth-disable": "ദ്വി-ഘടക സാധൂകരണം ഒഴിവാക്കുക",
+ "oathauth-disabledoath": "ദ്വി-ഘടക സാധൂകരണം പ്രവർത്തനരഹിതമാക്കിയിരിക്കുന്നു.",
+ "oathauth-prefs-label": "ദ്വി-ഘടക സാധൂകരണം:",
+ "oathauth-step1": "ഘട്ടം 1: ദ്വി-ഘടക സാധൂകരണ പ്രോഗ്രാം ഡൗൺലോഡ് ചെയ്യുക",
+ "oathauth-step2": "ഘട്ടം 2: ക്യൂ.ആർ. കോഡ് സ്കാൻ ചെയുക",
+ "oathauth-step3": "ഘട്ടം 3: സ്ക്രാച്ച് കോഡുകൾ എഴുതിവെക്കുക",
+ "oathauth-step4": "ഘട്ടം 4: പരിശോധിക്കൽ",
+ "oathauth-auth-token-label": "ചീട്ട്"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/mr.json b/www/wiki/extensions/OATHAuth/i18n/mr.json
new file mode 100644
index 00000000..6135375c
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/mr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "V.narsikar"
+ ]
+ },
+ "oathauth-auth-token-label": "बिल्ला"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ms.json b/www/wiki/extensions/OATHAuth/i18n/ms.json
new file mode 100644
index 00000000..c5f19c7a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ms.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia"
+ ]
+ },
+ "oathauth-desc": "Menyediakan sokongan penentusahan dengan menggunakan kata laluan kegunaan sekali berasaskan HMAC",
+ "specialpages-group-oath": "Penentusahan Dwifaktor",
+ "oathauth-account": "Nama Akaun Dwifaktor:",
+ "oathauth-secret": "Kunci Rahsia Dwifaktor:",
+ "oathauth-enable": "Hidupkan Penentusahan Dwifaktor",
+ "oathauth-scratchtokens": "Yang berikut ialah senarai token kegunaan sekali. Token-token ini hanya boleh digunakan sekali, malah adalah untuk kegunaan kecemasan. Sila catatkan dalam kertas dan simpan dalam tempat yang selamat. Sekiranya anda kehilangan telefon anda, token-token ini sahajalah caranya untuk menyelamatkan akaun anda. Token-token ini tidak akan dipaparkan lagi.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Matikan Penentusahan Dwifaktor",
+ "oathauth-validatedoath": "Watikah dwifaktor disahkan. Penentusahan dwifaktor kini akan berkuatkuasa.",
+ "oathauth-failedtovalidateoath": "Watikah dwifaktor gagal disahkan",
+ "oathauth-disabledoath": "Penentusahan dwifaktor dimatikan.",
+ "oathauth-prefs-label": "Penentusahan dwifaktor:"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/mwl.json b/www/wiki/extensions/OATHAuth/i18n/mwl.json
new file mode 100644
index 00000000..4c44fefc
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/mwl.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "specialpages-group-oath": "Outenticaçon de dous fatores",
+ "oathauth-prefs-label": "Outenticaçon de dous fatores:",
+ "right-oathauth-enable": "Atibar outenticaçon de dous fatores",
+ "action-oathauth-enable": "atibar outenticaçon de dous fatores"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/nb.json b/www/wiki/extensions/OATHAuth/i18n/nb.json
new file mode 100644
index 00000000..457eaca1
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/nb.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jon Harald Søby",
+ "Jeblad"
+ ]
+ },
+ "oathauth-desc": "Muliggjør autentiseringsstøtte med bruk av HMAC-baserte engangspassord",
+ "specialpages-group-oath": "Tofaktor-autentisering",
+ "oathauth-account": "Kontonavn:",
+ "oathauth-secret": "Hemmelig nøkkel for tofaktor-autentisering:",
+ "oathauth-enable": "Slå på tofaktor-autentisering",
+ "oathauth-scratchtokens": "Følgende liste er en liste over engangspassord. Disse kan kun brukes én gang, og bør kun brukes i nødstilfelle. Skriv dem ned og legg dem på et lurt sted. Om du mister telefonen din vil disse passordene være eneste måte å få tilbake kontoen din. Disse passordene vil aldri vises igjen.",
+ "oathauth-token": "Tegn",
+ "oathauth-disable": "Slå av tofaktor-autentisering",
+ "oathauth-validatedoath": "Validerte tofaktor-attestering. Tofaktorautentisering vil nå bli iverksatt.",
+ "oathauth-noscratchforvalidation": "Du kan ikke bruke en engangskode for å bekrefte tofaktorautentisering. Engangskoder er kun til backup og nødsbruk. Bruk en bekreftelseskode fra kodegeneratoren din.",
+ "oathauth-failedtovalidateoath": "Kunne ikke validere tofaktorattestering",
+ "oathauth-disabledoath": "Tofaktorautentisering er nå slått av.",
+ "oathauth-prefs-label": "Tofaktorautentisering:",
+ "oathauth-step1": "Steg 1: Last ned et program for tofaktor-autentisering",
+ "oathauth-step1-test": "Last ned et program for tofaktor-autentisering. Det kan være en mobilapp (som Google Authenticator) eller et dataprogram.",
+ "oathauth-step2": "Steg 2: Skann QR-koden",
+ "oathauth-step2alt": "Eller skriv inn hemmeligheten manuelt:",
+ "oathauth-step3": "Steg 3: Skriv ned engangskodene",
+ "oathauth-step4": "Steg 4: Verifisering",
+ "oathauth-entertoken": "Skriv inn en kode fra autentiseringsprogrammet ditt for å verifisere:",
+ "right-oathauth-enable": "Slå på tofaktor-autentisering",
+ "action-oathauth-enable": "slå på tofaktor-autentisering",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "Engangspassordet som brukes som den andre faktoren av tofaktor-autentiseringen.",
+ "oathauth-auth-ui": "Skriv inn verifiseringskoden fra autentiseringsenheten din",
+ "oathauth-throttled": "For mange verifiseringsforsøk! Vent i $1.",
+ "oathauth-login-failed": "Verifikasjonen feilet.",
+ "oathauth-describe-provider": "Tofaktor-autentisering (OATH).",
+ "grant-group-authentication": "Utføre autentiseringshandlinger for seg selv og andre",
+ "grant-oath": "Få tilgang til tofaktorautentiseringsinformasjon (OATH) for seg selv og andre",
+ "right-oathauth-api-all": "Spørre mot og validere OATH-informasjon for seg selv og andre",
+ "action-oathauth-api-all": "sjekk OATH-status",
+ "apihelp-query+oath-description": "Sjekk om tofaktorautentisering (OATH) er slått på for en bruker.",
+ "apihelp-query+oath-summary": "Sjekk om tofaktorautentisering (OATH) er slått på for en bruker.",
+ "apihelp-query+oath-param-user": "Brukeren det skal hentes informasjon om. Standard er den gjeldende brukeren.",
+ "apihelp-query+oath-example-1": "Få informasjon om den aktuelle brukeren",
+ "apihelp-query+oath-example-2": "Få informasjon om brukeren <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Valider et tofaktor-autentiseringstegn (OATH).",
+ "apihelp-oathvalidate-summary": "Valider et tofaktorautentiseringstegn (OATH).",
+ "apihelp-oathvalidate-param-user": "Brukeren tegnet skal valideres for. Standard er den aktuelle brukeren.",
+ "apihelp-oathvalidate-param-totp": "Tofaktor-autentiseringstegn (OATH).",
+ "apihelp-oathvalidate-example-1": "Valider et tegn for den aktuelle brukeren",
+ "apihelp-oathvalidate-example-2": "Valider et tegn for brukeren <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ne.json b/www/wiki/extensions/OATHAuth/i18n/ne.json
new file mode 100644
index 00000000..06bca26a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ne.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "NehalDaveND"
+ ]
+ },
+ "oathauth-token": "टोकन"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/nl.json b/www/wiki/extensions/OATHAuth/i18n/nl.json
new file mode 100644
index 00000000..c552980d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/nl.json
@@ -0,0 +1,27 @@
+{
+ "@metadata": {
+ "authors": [
+ "SPQRobin",
+ "Siebrand",
+ "Romaine",
+ "Sjoerddebruin",
+ "Southparkfan"
+ ]
+ },
+ "oathauth-desc": "Biedt ondersteuning voor authenticatie via op HMAC-gebaseerde eenmalige wachtwoorden",
+ "specialpages-group-oath": "Tweetrapsauthenticatie",
+ "oathauth-account": "Accountnaam:",
+ "oathauth-secret": "Geheime sleutel voor tweetrapsauthenticatie:",
+ "oathauth-enable": "Tweetrapsauthenticatie inschakelen",
+ "oathauth-scratchtokens": "De onderstaande lijst bevat tokens voor eenmalig gebruik. Deze tokens kunnen slechts één keer gebruikt worden en zijn bedoeld voor noodgevallen. Noteer deze tokens en bewaar ze op een veilige plaats. Als u uw telefoon bent verloren, zijn deze tokens de enige manier om uw gebruikersaccount te redden. '''Deze tokens worden nooit meer weergegeven'''.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Tweetrapsauthenticatie uitschakelen",
+ "oathauth-validatedoath": "De gebruikersgegevens voor tweetrapsauthenticatie zijn gevalideerd. Tweetrapsauthenticatie is nu verplicht.",
+ "oathauth-failedtovalidateoath": "Het valideren van de gebruikersgegevens voor tweetrapsauthenticatie is mislukt.",
+ "oathauth-disabledoath": "Tweetrapsauthenticatie is uitgeschakeld.",
+ "oathauth-prefs-label": "Tweetrapsauthenticatie:",
+ "oathauth-entertoken": "Vul een code van uw authenticatie-apparaat in om te bevestigen:",
+ "oathauth-auth-token-label": "Verificatiecode",
+ "oathauth-auth-ui": "Gelieve een verificatiecode van uw authenticatie-apparaat invullen",
+ "grant-group-authentication": "OAuth gebruiken voor authenticatie"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/oc.json b/www/wiki/extensions/OATHAuth/i18n/oc.json
new file mode 100644
index 00000000..eca8a90f
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/oc.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31"
+ ]
+ },
+ "specialpages-group-oath": "Autentificacion de dos factors",
+ "oathauth-enable": "Activar l'autentificacion de dos factors",
+ "oathauth-disable": "Desactivar l'autentificacion de dos factors",
+ "oathauth-disabledoath": "Autentificacion de dos factors desactivada.",
+ "oathauth-prefs-label": "Autentificacion de dos factors :",
+ "right-oathauth-enable": "Activar l’autentificacion de dos factors",
+ "action-oathauth-enable": "activar l’autentificacion de dos factors",
+ "oathauth-describe-provider": "Autentificacion de dos factors (OATH)"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/pl.json b/www/wiki/extensions/OATHAuth/i18n/pl.json
new file mode 100644
index 00000000..415dcf62
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/pl.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chrumps",
+ "Alan ffm"
+ ]
+ },
+ "specialpages-group-oath": "Uwierzytelnianie dwuskładnikowe",
+ "oathauth-account": "Nazwa konta:",
+ "oathauth-secret": "Tajny klucz uwierzytelniania dwuskładnikowego:",
+ "oathauth-enable": "Włączenie uwierzytelniania dwuskładnikowego",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Wyłączenie uwierzytelniania dwuskładnikowego",
+ "oathauth-prefs-label": "Uwierzytelnianie dwuskładnikowe:",
+ "oathauth-step1": "Krok 1: Pobierz program do uwierzytelniania dwuskładnikowego",
+ "oathauth-step1-test": "Pobierz program do uwierzytelniania dwuskładnikowego. Może to być aplikacja mobilna (np. Google Authenticator) lub aplikacja komputerowa",
+ "oathauth-step2": "Krok 2: Zeskanuj kod QR",
+ "oathauth-step2alt": "Lub ręcznie wprowadź tajny klucz:",
+ "oathauth-step4": "Krok 4: Weryfikacja",
+ "oathauth-entertoken": "Wpisz kod z urządzenia uwierzytelniającego w celu weryfikacji:",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-ui": "Wpisz kod weryfikacyjny z urządzenia uwierzytelniającego",
+ "oathauth-throttled": "Zbyt wiele prób weryfikacji! Poczekaj $1.",
+ "oathauth-login-failed": "Weryfikacja nie powiodła się.",
+ "oathauth-describe-provider": "Uwierzytelnianie dwuetapowe (OATH).",
+ "action-oathauth-api-all": "sprawdzania statusu OATH",
+ "apihelp-query+oath-example-1": "Pobierz informacje o aktualnym użytkowniku",
+ "apihelp-query+oath-example-2": "Pobierz informacje na temat użytkownika <kbd>Example</kbd>",
+ "apihelp-oathvalidate-param-totp": "Token uwierzytelniania dwuetapowego (OATH)."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/pms.json b/www/wiki/extensions/OATHAuth/i18n/pms.json
new file mode 100644
index 00000000..dd2bfc36
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/pms.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Borichèt",
+ "Dragonòt"
+ ]
+ },
+ "oathauth-desc": "A dà un supòrt d'autenticassion dovrand HMAC basà su dle ciav a usagi ùnich",
+ "specialpages-group-oath": "Autenticassion a Doi Fator",
+ "oathauth-account": "Nòm dël Cont dij Doi Fator:",
+ "oathauth-secret": "Ciav Segreta dij Doi Fator:",
+ "oathauth-enable": "Abilité l'Autenticassion a Doi Fator",
+ "oathauth-scratchtokens": "La lista sì-dapress a l'é na lista ëd geton da dovré mach na vira. Sti geton a peulo mach esse dovrà na vira, e a son da dovré an cas d'emergensa. Për piasì, ch'a jë scriva e ch'a-j goerna ant un pòst sigur. S'a perd sò teléfon, costi geton a son l'ùnica manera ëd salvé sò cont. Costi geton a saran mai pi mostrà torna.",
+ "oathauth-token": "Marca-pòst",
+ "oathauth-disable": "Disabilité l'Autenticassion a Doi Fator",
+ "oathauth-validatedoath": "Credensiaj a doi fator validà. L'autenticassion a doi fator a sarà dorenavan aplicà.",
+ "oathauth-failedtovalidateoath": "Falì a validé le credensiaj a doi fator",
+ "oathauth-disabledoath": "Autenticassion a doi fator disabilità."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ps.json b/www/wiki/extensions/OATHAuth/i18n/ps.json
new file mode 100644
index 00000000..74b31ae3
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ps.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Baloch Khan"
+ ]
+ },
+ "grant-oath": "دوه فکتور تصدیق ('''واته''') د ځان او نورو لپاره معلومات"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/pt-br.json b/www/wiki/extensions/OATHAuth/i18n/pt-br.json
new file mode 100644
index 00000000..e43736a4
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/pt-br.json
@@ -0,0 +1,55 @@
+{
+ "@metadata": {
+ "authors": [
+ "Araceletorres",
+ "Luk3",
+ "Tark",
+ "Felipe L. Ewald",
+ "Eduardo Addad de Oliveira"
+ ]
+ },
+ "oathauth-desc": "Fornece suporte a autenticação usando HMAC com base em senhas de uso único",
+ "oath": "OATHAuth",
+ "specialpages-group-oath": "Autenticação de dois fatores",
+ "oathauth-account": "Nome da conta:",
+ "oathauth-secret": "Chave secreta de autenticação de dois fatores:",
+ "oathauth-enable": "Ativar autenticação de dois fatores",
+ "oathauth-scratchtokens": "A lista a seguir é uma lista de chaves de uso único. Essas chaves só podem ser usadas uma vez, e são para uso de emergência. Por favor, anote-as e mantenha-as em um local seguro. Se você perder seu telefone, '''essas chaves são a única maneira de recuperar sua conta. Essas chaves nunca serão mostradas novamente'''.",
+ "oathauth-token": "Token",
+ "oathauth-disable": "Desativar autenticação de dois fatores",
+ "oathauth-validatedoath": "Credenciais de dois fatores validadas. A autenticação de dois fatores agora será aplicada.",
+ "oathauth-noscratchforvalidation": "Você não pode usar um código de rascunho para confirmar a autenticação de dois fatores. Os códigos Scratch são para backup e uso incidental apenas. Use um código de verificação do seu gerador de código.",
+ "oathauth-failedtovalidateoath": "Falha ao validar credenciais de dois fatores",
+ "oathauth-disabledoath": "Desativar autenticação de dois fatores.",
+ "oathauth-prefs-label": "Autenticação de dois fatores:",
+ "oathauth-step1": "Passo 1: Baixe um programa de autenticação de dois fatores",
+ "oathauth-step1-test": "Baixe um programa para a autenticação de dois fatores. Pode ser um aplicativo para celular (como o Google Authenticator) ou para desktop",
+ "oathauth-step2": "Passo 2: Escaneie o código QR",
+ "oathauth-step2alt": "Ou introduza o segredo manualmente:",
+ "oathauth-step3": "Passo 3: Anote os códigos scratch",
+ "oathauth-step4": "Passo 4: Verificação",
+ "oathauth-entertoken": "Digite um código do seu dispositivo de autenticação para verificação:",
+ "right-oathauth-enable": "Ativar autenticação de dois fatores",
+ "action-oathauth-enable": "ativar autenticação em duas etapas",
+ "oathauth-auth-token-label": "Token",
+ "oathauth-auth-token-help": "A senha única utilizada como o segundo fator de autenticação de dois fatores.",
+ "oathauth-auth-ui": "Por favor, digite um código de verificação do seu dispositivo de autenticação",
+ "oathauth-throttled": "Muitas tentativas de verificação! Por favor, aguarde $1.",
+ "oathauth-login-failed": "Verificação falhou.",
+ "oathauth-describe-provider": "Autenticação de dois fatores (OATH).",
+ "grant-group-authentication": "Execute ações de autenticação para si e para os outros",
+ "grant-oath": "Acesse informações de autenticação de dois fatos (OATH) para si e para os outros",
+ "right-oathauth-api-all": "Consultar e validar a informação OATH para si e para os outros",
+ "action-oathauth-api-all": "verificar estado do OATH",
+ "apihelp-query+oath-description": "Verifique se a autenticação de dois fatores (OATH) está habilitada para um usuário.",
+ "apihelp-query+oath-summary": "Verifique se a autenticação de dois fatores (OATH) está habilitada para um usuário.",
+ "apihelp-query+oath-param-user": "Usuário para o qual obter informações. Padrão para o usuário atual.",
+ "apihelp-query+oath-example-1": "Obtenha informações sobre o usuário atual",
+ "apihelp-query+oath-example-2": "Obter informações sobre o usuário <kbd>Exemplo</kbd>",
+ "apihelp-oathvalidate-description": "Valide um token de autenticação de dois fatos (OAUTH).",
+ "apihelp-oathvalidate-summary": "Valide um token de autenticação de dois fatos (OAUTH).",
+ "apihelp-oathvalidate-param-user": "Usuário para o qual validar token. Padrão para o usuário atual.",
+ "apihelp-oathvalidate-param-totp": "Token de autenticação de dois fatos (OATH).",
+ "apihelp-oathvalidate-example-1": "Validar um token para o usuário atual",
+ "apihelp-oathvalidate-example-2": "Valide um token para o usuário <kbd>Exemplo</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/pt.json b/www/wiki/extensions/OATHAuth/i18n/pt.json
new file mode 100644
index 00000000..ef8a37d5
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/pt.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Vitorvicentevalente",
+ "Hamilton Abreu",
+ "Athena in Wonderland"
+ ]
+ },
+ "oathauth-desc": "Fornece suporte à autenticação usando palavras-passe de uso único baseadas em códigos HMAC",
+ "specialpages-group-oath": "Autenticação de dois fatores",
+ "oathauth-account": "Nome da conta:",
+ "oathauth-secret": "Chave secreta da autenticação de dois fatores:",
+ "oathauth-enable": "Ativar a autenticação de dois fatores",
+ "oathauth-scratchtokens": "A seguinte é uma lista de chaves de uso único. Estas chaves só podem ser usadas uma vez, e são para casos de emergência. Anote-as, por favor, e guarde-as num local seguro. Se perder o seu telefone, estas chaves são a única forma de recuperar a sua conta. '''Esta é a única vez em que estas chaves serão mostradas'''.",
+ "oathauth-token": "Chave",
+ "oathauth-disable": "Desativar a autenticação de dois fatores",
+ "oathauth-validatedoath": "As credenciais de dois fatores foram validadas. A autenticação de dois fatores será agora aplicada.",
+ "oathauth-noscratchforvalidation": "Não pode usar um código de uso único para confirmar a autenticação de dois fatores. Os códigos de uso único só servem como reserva para uso ocasional. Use um código de verificação do seu gerador de códigos.",
+ "oathauth-failedtovalidateoath": "A validação das credenciais de dois fatores falhou",
+ "oathauth-disabledoath": "A autenticação de dois fatores foi desativada.",
+ "oathauth-prefs-label": "Autenticação de dois fatores:",
+ "oathauth-step1": "Passo 1: Descarregue um programa de autenticação de dois fatores",
+ "oathauth-step1-test": "Descarregue um programa para autenticação de dois fatores. Tanto pode ser uma aplicação de dispositivo móvel (como o Autenticador da Google, Google Authenticator) como de ambiente de trabalho.",
+ "oathauth-step2": "Passo 2: Faça o ''scan'' do código QR",
+ "oathauth-step2alt": "Ou, introduza o segredo manualmente:",
+ "oathauth-step3": "Passo 3: Anote os códigos de uso único",
+ "oathauth-step4": "Passo 4: Verificação",
+ "oathauth-entertoken": "Introduza um código do seu dispositivo de autenticação para verificação:",
+ "right-oathauth-enable": "Ativar autenticação de dois fatores",
+ "action-oathauth-enable": "ativar autenticação de dois fatores",
+ "oathauth-auth-token-label": "Chave",
+ "oathauth-auth-token-help": "A palavra-passe de uso único usada como segundo fator da autenticação de dois fatores.",
+ "oathauth-auth-ui": "Insira o código de verificação do seu dispositivo de autenticação",
+ "oathauth-throttled": "Ocorreram demasiadas tentativas de verificação! Por favor, aguarde $1.",
+ "oathauth-login-failed": "A verificação falhou.",
+ "oathauth-describe-provider": "Autenticação de dois fatores (OATH).",
+ "grant-group-authentication": "Executar as ações de autenticação para si e para outros",
+ "grant-oath": "Aceder a informação da autenticação de dois fatores (OATH) do próprio e de outros",
+ "right-oathauth-api-all": "Consultar e validar informação OATH do próprio e de outros",
+ "action-oathauth-api-all": "verificar o estado OATH",
+ "apihelp-query+oath-description": "Verificar se a autenticação de dois fatores (OATH) está ativa para um utilizador.",
+ "apihelp-query+oath-summary": "Verificar se a autenticação de dois fatores (OATH) está ativa para um utilizador.",
+ "apihelp-query+oath-param-user": "Utilizador acerca do qual será obtida informação. Por omissão, o utilizador atual.",
+ "apihelp-query+oath-example-1": "Obter informações sobre o utilizador atual",
+ "apihelp-query+oath-example-2": "Obter informação sobre o utilizador <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Validar uma chave de autenticação de dois fatores (OATH).",
+ "apihelp-oathvalidate-summary": "Validar uma chave de autenticação de dois fatores (OATH).",
+ "apihelp-oathvalidate-param-user": "O utilizador para o qual a chave será validada. Por omissão, o utilizador atual.",
+ "apihelp-oathvalidate-param-totp": "Chave para autenticação de dois fatores (OATH).",
+ "apihelp-oathvalidate-example-1": "Validar uma chave para o utilizador atual",
+ "apihelp-oathvalidate-example-2": "Validar uma chave para o utilizador <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/qqq.json b/www/wiki/extensions/OATHAuth/i18n/qqq.json
new file mode 100644
index 00000000..445ea228
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/qqq.json
@@ -0,0 +1,59 @@
+{
+ "@metadata": {
+ "authors": [
+ "Raymond",
+ "Ryan Lane <rlane@wikimedia.org>",
+ "Shirayuki",
+ "Purodha",
+ "Umherirrender",
+ "Tyler Romeo <tylerromeo@gmail.com>",
+ "Liuxinyu970226",
+ "Amire80",
+ "Siebrand"
+ ]
+ },
+ "oathauth-desc": "{{desc|name=OATH Auth|url=https://www.mediawiki.org/wiki/Extension:OATHAuth}}",
+ "oath": "{{optional}}\n{{doc-special|OATH}}",
+ "specialpages-group-oath": "{{doc-special-group|like=[[Special:OATH]]}}\n\nSee [[w:en:Two_factor_authentication|Wikipedia article on two factor authentication]].\n\n{{Identical|Two factor authentication}}",
+ "oathauth-account": "Plain text associated with [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication] on this wiki (username@<wiki name>) found on Special:OATH.\n{{Identical|Account name}}",
+ "oathauth-secret": "Plain text found on Special:OATH while enabling OATH\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-enable": "Page title on Special:OATH, when enabling OATH.\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-scratchtokens": "Plain text, found on Special:OATH while enabling OATH.",
+ "oathauth-token": "HTMLForm label, found on [[Special:OATH]], when verifying OATH.\n{{Identical|Token}}",
+ "oathauth-disable": "Page title on Special:OATH while disabling OATH.\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-validatedoath": "Plain text found on Special:OATH after a token has been validated.\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-noscratchforvalidation": "Plain text found on Special:OATH if the user used the incorrect type of token while enabling OATH.\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-failedtovalidateoath": "Plain text found on Special:OATH when validation of a token has failed.\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-disabledoath": "Plain text found on Special:OATH when disabling OATH has been successful.\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]",
+ "oathauth-prefs-label": "Plain text label seen on Special:Preferences\n\nSee [https://en.wikipedia.org/wiki/Two_factor_authentication two factor authentication]\n{{Identical|Two factor authentication}}",
+ "oathauth-step1": "Label for step 1 on Special:OATH form",
+ "oathauth-step1-test": "Text for step 1 on Special:OATH for. Check the name of \"Google Authenticator\" in your language in the Play Market—it's quite likely that it's translated.",
+ "oathauth-step2": "Label for step 2, the QR code, on Special:OATH",
+ "oathauth-step2alt": "Label for information on how to manually do step 2 on Special:OATH",
+ "oathauth-step3": "Label for step 3 information on Special:OATH",
+ "oathauth-step4": "Label for step 4 information on Special:OATH",
+ "oathauth-entertoken": "Label on input field on Special:OATH asking user to enter token",
+ "right-oathauth-enable": "{{doc-right|oathauth-enable}}",
+ "action-oathauth-enable": "{{doc-action|oathauth-enable}}",
+ "oathauth-auth-token-label": "Label of the second-factor field on special pages and in the API\n{{Identical|Token}}",
+ "oathauth-auth-token-help": "Extended help message for the second factor field in the API.",
+ "oathauth-auth-ui": "Shown on top of the login form when second factor is required",
+ "oathauth-throttled": "Error message when throttling limit is hit.\n\nParameters:\n* $1 - throttle block duration",
+ "oathauth-login-failed": "Error message when verifying the second factor failed.",
+ "oathauth-describe-provider": "Description of the extension as an authentication provider.",
+ "grant-group-authentication": "{{Related|Grant-group}}",
+ "grant-oath": "Name for grant \"oath\".\n{{Related|Grant}}",
+ "right-oathauth-api-all": "{{doc-right|oathauth-api-all}}",
+ "action-oathauth-api-all": "{{doc-action|oathauth-api-all}}",
+ "apihelp-query+oath-description": "{{doc-apihelp-description|query+oath}}",
+ "apihelp-query+oath-summary": "{{doc-apihelp-summary|query+oath}}",
+ "apihelp-query+oath-param-user": "{{doc-apihelp-param|query+oath|user}}",
+ "apihelp-query+oath-example-1": "{{doc-apihelp-example|query+oath}}",
+ "apihelp-query+oath-example-2": "{{doc-apihelp-example|query+oath}}",
+ "apihelp-oathvalidate-description": "{{doc-apihelp-description|oathvalidate}}",
+ "apihelp-oathvalidate-summary": "{{doc-apihelp-summary|oathvalidate}}",
+ "apihelp-oathvalidate-param-user": "{{doc-apihelp-param|oathvalidate|user}}",
+ "apihelp-oathvalidate-param-totp": "{{doc-apihelp-param|oathvalidate|totp}}",
+ "apihelp-oathvalidate-example-1": "{{doc-apihelp-example|oathvalidate}}",
+ "apihelp-oathvalidate-example-2": "{{doc-apihelp-example|oathvalidate}}"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ro.json b/www/wiki/extensions/OATHAuth/i18n/ro.json
new file mode 100644
index 00000000..c368abda
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ro.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "Firilacroco",
+ "Stelistcristi",
+ "Narlotep1",
+ "Strainu"
+ ]
+ },
+ "specialpages-group-oath": "Autentificare pe două niveluri",
+ "oathauth-account": "Numele contului:",
+ "oathauth-token": "Jeton",
+ "oathauth-prefs-label": "Autentificare pe două niveluri:",
+ "oathauth-step4": "Pasul 4: Verificare",
+ "oathauth-auth-ui": "Va rugam introduceti codul de autentificare de pe dispozitivul dumneavoastra"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/roa-tara.json b/www/wiki/extensions/OATHAuth/i18n/roa-tara.json
new file mode 100644
index 00000000..12edc7bb
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/roa-tara.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras"
+ ]
+ },
+ "specialpages-group-oath": "Autendicazione a Doje Fattore",
+ "oathauth-account": "Nome d'u cunde:",
+ "oathauth-secret": "Chiave segrete de autendicazione a Doje Fattore:",
+ "oathauth-enable": "Abbilite l'Autendicazione a Doje Fattore",
+ "oathauth-token": "Gettone",
+ "oathauth-disable": "Disabbilite l'Autendicazione a Doje Fattore",
+ "oathauth-auth-token-label": "Gettone",
+ "apihelp-oathvalidate-example-1": "Valide 'nu gettone pe l'utende de mò",
+ "apihelp-oathvalidate-example-2": "Valide 'nu gettone pe l'utende <kbd>Esembie</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ru.json b/www/wiki/extensions/OATHAuth/i18n/ru.json
new file mode 100644
index 00000000..df663213
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ru.json
@@ -0,0 +1,57 @@
+{
+ "@metadata": {
+ "authors": [
+ "Okras",
+ "Kareyac",
+ "Iniquity",
+ "Ping08",
+ "Alexandr Efremov",
+ "NBS",
+ "Mouse21",
+ "Patrick Star"
+ ]
+ },
+ "oathauth-desc": "Обеспечивает поддержку проверки подлинности с помощью HMAC на основе одноразовых паролей",
+ "specialpages-group-oath": "Двухфакторная аутентификация",
+ "oathauth-account": "Имя учётной записи:",
+ "oathauth-secret": "Двухфакторный секретный ключ аутентификации:",
+ "oathauth-enable": "Включить двухфакторную аутентификацию",
+ "oathauth-scratchtokens": "Это — список одноразовых токенов. Эти токены могут быть использованы только один раз и предназначены для использования в чрезвычайных ситуациях. Пожалуйста, запишите их и хранить в безопасном месте. Если вы потеряете свой телефон, они будут единственным способом спасти ваш аккаунт. '''Эти токены больше никогда не будут показаны'''.",
+ "oathauth-token": "Токен",
+ "oathauth-disable": "Отключить двухфакторную аутентификацию",
+ "oathauth-validatedoath": "Двухфакторные учётные данные проверены. Теперь будет использоваться двухфакторная аутентификация.",
+ "oathauth-noscratchforvalidation": "Вы не можете использовать код scratch для подтверждения двухфакторной аутентификации. Коды scratch предназначены только для резервного копирования и случайного использования. Пожалуйста, используйте код подтверждения от вашего генератора кода.",
+ "oathauth-failedtovalidateoath": "Не удалось проверить двухфакторные учётные данные",
+ "oathauth-disabledoath": "Двухфакторная аутентификация отключена.",
+ "oathauth-prefs-label": "Двухфакторная аутентификация:",
+ "oathauth-step1": "Шаг 1: Загрузите программу двухфакторной аутентификации",
+ "oathauth-step1-test": "Загрузите программу для двухфакторной аутентификации. Это может быть мобильное приложение (например, Google Authenticator) или настольное приложение",
+ "oathauth-step2": "Шаг 2: Отсканируйте QR-код",
+ "oathauth-step2alt": "Или введите секретный код вручную:",
+ "oathauth-step3": "Шаг 3: Запишите скретч коды",
+ "oathauth-step4": "Шаг 4: Проверка",
+ "oathauth-entertoken": "Введите код с вашего устройства проверки подлинности, чтобы проверить:",
+ "right-oathauth-enable": "включение двухфакторной аутентификации",
+ "action-oathauth-enable": "включить двухфакторную аутентификацию",
+ "oathauth-auth-token-label": "Токен",
+ "oathauth-auth-token-help": "Одноразовый пароль используется как второй фактор двухфакторной аутентификации.",
+ "oathauth-auth-ui": "Пожалуйста, введите код подтверждения из устройства проверки подлинности",
+ "oathauth-throttled": "Слишком много попыток проверки! пожалуйста, подождите $1.",
+ "oathauth-login-failed": "Не удалось выполнить проверку.",
+ "oathauth-describe-provider": "Двухфакторная аутентификация (OATH).",
+ "grant-group-authentication": "Выполнять действия, связанные с проверкой подлинности для себя и других",
+ "grant-oath": "Доступ к двухфакторной аутентификации (OAUTH) для себя и других",
+ "right-oathauth-api-all": "Запрос и проверка информации OAUTH для себя и других",
+ "action-oathauth-api-all": "Проверить статус OATH",
+ "apihelp-query+oath-description": "Проверьте, включена ли двухфакторная аутентификация (OATH) для пользователя.",
+ "apihelp-query+oath-summary": "Проверьте, включена ли двухфакторная аутентификация (OATH) для пользователя.",
+ "apihelp-query+oath-param-user": "Пользователь для получения информации о. По умолчанию для текущего пользователя.",
+ "apihelp-query+oath-example-1": "Получить информацию о текущем пользователе",
+ "apihelp-query+oath-example-2": "Получать информацию о пользователе <kbd>Пример</kbd>",
+ "apihelp-oathvalidate-description": "Подтвердите двухфакторный токен аутентификации (OAUTH).",
+ "apihelp-oathvalidate-summary": "Подтвердите двухфакторный токен аутентификации (OAUTH).",
+ "apihelp-oathvalidate-param-user": "Пользователь для проверки токена для. По умолчанию для текущего пользователя.",
+ "apihelp-oathvalidate-param-totp": "Токен двухфакторной аутентификации (OAUTH).",
+ "apihelp-oathvalidate-example-1": "Проверка токена для текущего пользователя",
+ "apihelp-oathvalidate-example-2": "Проверить токен для пользователя <kbd>пример</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sa.json b/www/wiki/extensions/OATHAuth/i18n/sa.json
new file mode 100644
index 00000000..175b9d05
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sa.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "NehalDaveND"
+ ]
+ },
+ "oathauth-token": "स्तोकम् (token)"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sah.json b/www/wiki/extensions/OATHAuth/i18n/sah.json
new file mode 100644
index 00000000..f0bebe83
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sah.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Марианна"
+ ]
+ },
+ "oathauth-auth-token-label": "Токен"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sd.json b/www/wiki/extensions/OATHAuth/i18n/sd.json
new file mode 100644
index 00000000..a5c4599f
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sd.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mehtab ahmed"
+ ]
+ },
+ "action-oathauth-api-all": "OATH جو مرتبو چڪاسيو"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/si.json b/www/wiki/extensions/OATHAuth/i18n/si.json
new file mode 100644
index 00000000..e6ed694a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/si.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "specialpages-group-oath": "ද්විසාධක සහතික කිරීම",
+ "oathauth-account": "ද්විසාධක ගිණුමේ නාමය:",
+ "oathauth-secret": "ද්විසාධක රහස් යතුර:",
+ "oathauth-enable": "ද්විසාධක සහතික කිරීම සක්‍රිය කරන්න",
+ "oathauth-token": "ටෝකනය",
+ "oathauth-disable": "ද්විසාධක සහතික කිරීම අක්‍රිය කරන්න",
+ "oathauth-disabledoath": "ද්විසාධක සහතික කිරීම අක්‍රිය කර ඇත."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sk.json b/www/wiki/extensions/OATHAuth/i18n/sk.json
new file mode 100644
index 00000000..6187b90d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sk.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Teslaton"
+ ]
+ },
+ "oathauth-desc": "Poskytuje podporu pre autentifikáciu pomocou jednorázových hesiel, založených na HMAC",
+ "specialpages-group-oath": "Dvojfaktorová autentifikácia",
+ "oathauth-account": "Názov účtu:",
+ "oathauth-secret": "Tajný kľúč pre dvojfaktorovú autentifikáciu:",
+ "oathauth-enable": "Zapnutie dvojfaktorovej autentifikácie",
+ "oathauth-scratchtokens": "Nasledovný zoznam obsahuje jednorazové kódy. Tieto kódy možno použiť iba raz a slúžia pre prípad núdze. Opíšte si ich a uchovávajte ich na bezpečnom mieste. Ak stratíte svoj telefón, budú tieto kódy jediným spôsobom, ako zachrániť svoj účet. Tieto kódy sa už nikdy opätovne nezobrazia.",
+ "oathauth-token": "Kód",
+ "oathauth-disable": "Vypnutie dvojfaktorovej autentifikácie",
+ "oathauth-validatedoath": "Dvojfaktorové prihlásenie overené. Odteraz bude vynucovaná dvojfaktorová autentifikácia.",
+ "oathauth-failedtovalidateoath": "Nepodarilo se overiť dvojfaktorové prihlásenie.",
+ "oathauth-disabledoath": "Dvojfaktorová autentifikácia vypnutá.",
+ "oathauth-prefs-label": "Dvojfaktorová autentifikácia:",
+ "oathauth-step1": "Krok 1: Stiahnite si program pre dvojfaktorovú autentifikáciu",
+ "oathauth-step1-test": "Stiahnite si program alebo mobilnú aplikáciu (ako napr. Google Authenticator) pre dvojfaktorovú autentifikáciu",
+ "oathauth-step2": "Krok 2: Naskenujte QR kód",
+ "oathauth-step2alt": "Alebo zadajte tajomstvo manuálne:",
+ "oathauth-step3": "Krok 3: Zapíšte si jednorazové kódy",
+ "oathauth-step4": "Krok 4: Overenie",
+ "oathauth-entertoken": "Pre overenie zadajte kód z vášho autentifikačného zariadenia:",
+ "right-oathauth-enable": "Zapnutie dvojfaktorovej autentifikácie",
+ "action-oathauth-enable": "zapnúť dvojfaktorovú autentifikáciu",
+ "oathauth-auth-token-label": "Kód",
+ "oathauth-auth-token-help": "Jednorazové heslo používané ako druhý faktor dvojfaktorovej autentifikácie.",
+ "oathauth-auth-ui": "Zadajte prosím overovací kód zo svojho autentifikačného zariadenia",
+ "oathauth-throttled": "Príliš veľa pokusov o overenie! Počkajte prosím $1.",
+ "oathauth-login-failed": "Overenie sa nepodarilo.",
+ "oathauth-describe-provider": "Dvojfaktorová autentifikácia (OATH).",
+ "grant-group-authentication": "Vykonávanie autentifikačných akcií pre seba alebo pre ostatných",
+ "grant-oath": "Prístup k informáciám o dvojfaktorovej autentifikácii (OATH) k sebe a ostatným",
+ "right-oathauth-api-all": "Zisťovanie a overovanie informácií týkajúcich sa OATH k sebe a ostatným",
+ "action-oathauth-api-all": "kontrolovať stav OATH"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sq.json b/www/wiki/extensions/OATHAuth/i18n/sq.json
new file mode 100644
index 00000000..883ade89
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sq.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liridon"
+ ]
+ },
+ "oathauth-account": "Emri i llogarisë",
+ "oathauth-auth-ui": "Ju lutemi shkruani kodin e verifikimit tuaj nga pajisje të legalizuara"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sr-ec.json b/www/wiki/extensions/OATHAuth/i18n/sr-ec.json
new file mode 100644
index 00000000..5c193780
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sr-ec.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01",
+ "Obsuser"
+ ]
+ },
+ "oathauth-token": "Жетон",
+ "oathauth-noscratchforvalidation": "Не можете да користите скреч код за потврђивање двофакторске аутентификације. Скреч кодови су за подршку и случајну употребу само. Користите верификациони код из свог генератора кода."
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sr-el.json b/www/wiki/extensions/OATHAuth/i18n/sr-el.json
new file mode 100644
index 00000000..65bea883
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sr-el.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01"
+ ]
+ },
+ "oathauth-token": "Žeton"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/sv.json b/www/wiki/extensions/OATHAuth/i18n/sv.json
new file mode 100644
index 00000000..1406e71a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/sv.json
@@ -0,0 +1,32 @@
+{
+ "@metadata": {
+ "authors": [
+ "WikiPhoenix",
+ "Lokal Profil"
+ ]
+ },
+ "oathauth-desc": "Ger autentiseringsstöd med HMAC-baserade engångslösenord",
+ "specialpages-group-oath": "Tvåstegsverifiering",
+ "oathauth-account": "Kontonamn:",
+ "oathauth-secret": "Tvåstegs-hemlig nyckel:",
+ "oathauth-enable": "Aktivera tvåstegsverifiering",
+ "oathauth-scratchtokens": "Följande lista är en förteckning över engångsnycklar. Dessa nycklar kan enbart användas en gång och är avsedda för användning i nödfall. Vänligen skriv ner dessa och förvara dem på en säker plats. Om du förlorar din telefon, är dessa nycklar det enda sättet att rädda ditt konto. Dessa nycklar kommer aldrig att visas igen.",
+ "oathauth-token": "Nyckel",
+ "oathauth-disable": "Inaktivera tvåstegsverifiering",
+ "oathauth-validatedoath": "Validerade tvåstegs-autentiseringsuppgifter. Tvåstegsverifiering kommer nu att verkställas.",
+ "oathauth-failedtovalidateoath": "Misslyckades med att validera tvåstegs-autentiseringsuppgifter",
+ "oathauth-disabledoath": "Inaktivera tvåstegsverifiering.",
+ "oathauth-prefs-label": "Tvåstegsverifiering:",
+ "oathauth-step1": "Steg 1: Ladda ned appen",
+ "oathauth-step2": "Steg 2: Skanna QR-koden",
+ "oathauth-step4": "Steg 4: Verifiering",
+ "oathauth-auth-token-label": "Nyckel",
+ "oathauth-auth-ui": "Ange verifieringskoden från din autentiseringsenhet",
+ "oathauth-login-failed": "Verifiering misslyckades.",
+ "grant-group-authentication": "Använd OAuth för autentisering",
+ "action-oathauth-api-all": "kolla OATH-status",
+ "apihelp-query+oath-example-1": "Skaffa information om den aktuella användaren.",
+ "apihelp-query+oath-example-2": "Hämta information om användaren <kbd>Example</kbd>",
+ "apihelp-oathvalidate-example-1": "Bekräfta en nyckel för aktuell användare",
+ "apihelp-oathvalidate-example-2": "Bekräfta en nyckel för användaren <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ta.json b/www/wiki/extensions/OATHAuth/i18n/ta.json
new file mode 100644
index 00000000..a4885d2e
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ta.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Karthi.dr"
+ ]
+ },
+ "oathauth-notloggedin": "புகுபதிகை செய்யப்பட வேண்டும்"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/te.json b/www/wiki/extensions/OATHAuth/i18n/te.json
new file mode 100644
index 00000000..5bbfee86
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/te.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jedimaster26"
+ ]
+ },
+ "action-oathauth-api-all": "OATH స్థితి గమనించండి"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/th.json b/www/wiki/extensions/OATHAuth/i18n/th.json
new file mode 100644
index 00000000..70e32bc6
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/th.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aefgh39622"
+ ]
+ },
+ "oathauth-desc": "จัดหาการรองรับการยืนยันตัวตนโดยใช้รหัสผ่านแบบครั้งเดียวบนพื้นฐานของ HMAC",
+ "specialpages-group-oath": "การยืนยันตัวตนสองขั้นตอน",
+ "oathauth-account": "ชื่อบัญชี:",
+ "oathauth-secret": "คีย์ลับการยืนยันตัวตันสองขั้นตอน:",
+ "oathauth-enable": "เปิดใช้งานการยืนยันตัวตนสองขั้นตอน",
+ "oathauth-scratchtokens": "รายการต่อไปนี้เป็นรายการโทเค็นชั่วคราวสำหรับใช้ครั้งเดียว โทเค็นเหล่านี้สามารถใช้ได้เพียงครั้งเดียวเท่านั้น และใช้ในยามฉุกเฉิน กรุณาจดโทเค็นเหล่านี้ไว้และเก็บไว้ในที่ที่ปลอดภัย ถ้าโทรศัพท์ของคุณสูญหาย โทเค็นเหล่านี้จะเป็นเพียงวิธีเดียวในการช่วยเหลือบัญชีของคุณ '''โทเค็นเหล่านี้จะไม่ถูกแสดงอีก'''",
+ "oathauth-token": "โทเค็น",
+ "oathauth-disable": "ปิดใช้งานการยืนยันตัวตนสองขั้นตอน",
+ "oathauth-validatedoath": "ตรวจสอบข้อมูลประจำตัวแบบสองขั้นตอนแล้ว คุณจะถูกบังคับให้ทำการยืนยันตัวตนสองขั้นตอน",
+ "oathauth-failedtovalidateoath": "ไม่สามารถตรวจสอบข้อมูลประจำตัวแบบสองขั้นตอนได้",
+ "oathauth-disabledoath": "ปิดใช้งานการยืนยันตัวตนสองขั้นตอนแล้ว",
+ "oathauth-prefs-label": "การยืนยันตัวตนสองขั้นตอน:",
+ "right-oathauth-enable": "เปิดใช้งานการยืนยันตัวตนสองขั้นตอน",
+ "action-oathauth-enable": "เปิดใช้งานการยืนยันตัวตนสองขั้นตอน"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/tl.json b/www/wiki/extensions/OATHAuth/i18n/tl.json
new file mode 100644
index 00000000..fc64aeec
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/tl.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "AnakngAraw",
+ "Emem.calist"
+ ]
+ },
+ "oathauth-desc": "Nagbibigay ng suporta ng pagpapatunay sa pamamagitan ng pang-isang ulit na mga hudyat na nakabatay sa HMAC",
+ "specialpages-group-oath": "Dalawang Salik na Pagpapatunay",
+ "oathauth-account": "Dalawang Salik na Pangalan ng Akawnt:",
+ "oathauth-secret": "Dalawang Salik na Susi ng Lihim:",
+ "oathauth-enable": "Paganahin ang Dalawang Salik na Pagpapatunay",
+ "oathauth-scratchtokens": "Ang sumusunod na lista ay isang listahan ng mga pang-isahang ulit na paggamit na mga panghalip na nagagasgas. Ang mga panghalip na ito ay magagamit lamang nang isang beses, at mga para sa paggamit na pangkagipitan. Pakisulat ang mga ito at itabi sa isang ligtas na lugar. Kapag naiwala mo ang telepono mo, ang mga panghalip na ito lang ang makasasaklolo sa akawnt mo. Hindi na muling ipapakita pa ang mga panghalip na ito.",
+ "oathauth-token": "Kahalip",
+ "oathauth-disable": "Huwag Paganahin ang Dalawang Salik na Pagpapatunay",
+ "oathauth-validatedoath": "Nakapagpatunay ng dalawang salik na mga katibayan. Isasakatuparan na ngayon ang dalawang salik na pagpapatunay.",
+ "oathauth-failedtovalidateoath": "Nabigo sa pagpapatunay ng dalawang salik na mga kredensiyal",
+ "oathauth-disabledoath": "Hindi na pinaaandar ang dalawang salik na pagpapatunay.",
+ "apihelp-query+oath-example-1": "Maghanap ng kaukulang impormasyon tungkol sa 'current user'"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/tr.json b/www/wiki/extensions/OATHAuth/i18n/tr.json
new file mode 100644
index 00000000..7c2c555c
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/tr.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "Incelemeelemani",
+ "Hbseren",
+ "Sayginer",
+ "HakanIST"
+ ]
+ },
+ "oathauth-desc": "HMAC tabanlı tek kullanımlık şifreler kullanan bir kimlik doğrulama desteği sağlar",
+ "specialpages-group-oath": "İki faktörlü kimlik doğrulama",
+ "oathauth-account": "İki Faktörlü Hesap Adı:",
+ "oathauth-secret": "İki Faktörlü Gizli Anahtar:",
+ "oathauth-enable": "İki Faktörlü Doğrulamayı Etkinleştirin",
+ "oathauth-scratchtokens": "Aşağıdaki listede, yalnızca bir defa kullanımlık anahtar bulunmaktadır. Bu semboller yalnızca bir defalık kullanım içindir ve acil durum kullanımlarına özel olabilir. Lütfen aşağıda yazılı anahtarı bir yere yazın ve bunu güvenli bir yerde saklayın. Eğer telefonunuzu kaybederseniz, bu simgeler hesabınızı kurtarmanın tek yolu olacaktır. Bu simgeler asla tekrar gösterilmeyecektir.",
+ "oathauth-token": "Anahtar",
+ "oathauth-disable": "İki Faktörlü Kimlik Doğrulama Devre Dışı",
+ "oathauth-validatedoath": "İki Faktörlü kimlik onaylandı. İki faktörlü kimlik doğrulama artık etkinleştirilecektir.",
+ "oathauth-failedtovalidateoath": "İki faktörlü kimlik doğrulama başarısız oldu",
+ "oathauth-disabledoath": "İki faktörlü kimlik doğrulama devre dışı.",
+ "oathauth-prefs-label": "İki faktörlü kimlik doğrulama:",
+ "oathauth-step1": "1. Adım: Uygulamayı indirin",
+ "oathauth-step2": "2. Adım: QR kodunu tarayın",
+ "oathauth-step4": "4. Adım: Doğrulama",
+ "grant-group-authentication": "Kimlik doğrulama işlemlerini kendin ve diğerleri için uygula"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/uk.json b/www/wiki/extensions/OATHAuth/i18n/uk.json
new file mode 100644
index 00000000..fd84b820
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/uk.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Andriykopanytsia",
+ "Piramidion",
+ "Ата"
+ ]
+ },
+ "oathauth-desc": "Забезпечує підтримку автентифікації за допомогою HMAC на основі одноразових паролів",
+ "specialpages-group-oath": "Двофакторна авторизація",
+ "oathauth-account": "Назва облікового запису:",
+ "oathauth-secret": "Секретний ключ двофакторної автентифікації:",
+ "oathauth-enable": "Увімкнути двофакторну авторизацію",
+ "oathauth-scratchtokens": "У цій таблиці наведено список одноразових кодів. Ці коди можна використовувати лише один раз. Вони призначені для використання в надзвичайних ситуаціях. Будь ласка, запишіть їх і зберігайте у безпечному місці. Якщо ваш телефон загубиться, ці коди єдиний спосіб врятувати ваш обліковий запис. Ці коди ніколи не з'являться знову.",
+ "oathauth-token": "Код",
+ "oathauth-disable": "Вимкнути двофакторну авторизацію",
+ "oathauth-validatedoath": "Перевірено двофакторні облікові дані. Двофакторна авторизація тепер буде застосована.",
+ "oathauth-noscratchforvalidation": "Ви не можете скористатись скретч-кодом для підтвердження двофакторної автентифікації. Скретч-коди призначені лише для використання як резервної копії або при виникненні незвичних інцидентів. Будь ласка, використовуйте код верифікації з Вашого генератора коду.",
+ "oathauth-failedtovalidateoath": "Не вдалося перевірити двофакторні повноваження",
+ "oathauth-disabledoath": "Вимкнено двофакторну авторизацію.",
+ "oathauth-prefs-label": "Двофакторна авторизація:",
+ "oathauth-step1": "Крок 1: Завантажте програму з двофакторної автентифікації",
+ "oathauth-step1-test": "Завантажте програму для двофакторної автентифікації. Це може бути мобільний застосунок (напр., Google Authenticator), або програма для комп'ютера.",
+ "oathauth-step2": "Крок 2: Зіскануйте QR-код",
+ "oathauth-step2alt": "Або введіть ключ вручну:",
+ "oathauth-step3": "Крок 3: Запишіть скретч-коди",
+ "oathauth-step4": "Крок 4: Перевірка",
+ "oathauth-entertoken": "Введіть код зі свого пристрою автентифікації для перевірки:",
+ "right-oathauth-enable": "вмикання двофакторної авторизації",
+ "action-oathauth-enable": "вмикання двофакторної авторизації",
+ "oathauth-auth-token-label": "Токен",
+ "oathauth-auth-token-help": "Одноразовий пароль використовується як другий фактор двофакторної автентифікації.",
+ "oathauth-auth-ui": "Будь ласка, введіть код верифікації з Вашого пристрою автентифікації",
+ "oathauth-throttled": "Забагато спроб верифікації! Будь ласка, зачекайте $1.",
+ "oathauth-login-failed": "Верифікація не вдалася.",
+ "oathauth-describe-provider": "Двофакторна автентифікація (OATH).",
+ "grant-group-authentication": "Виконати дії з автентифікації для себе й інших",
+ "grant-oath": "Отримати доступ до інформації про двофакторну автентифікацію (OATH) для себе й інших",
+ "right-oathauth-api-all": "Запитати та перевірити інформацію щодо OATH для себе та інших",
+ "action-oathauth-api-all": "перевірку статусу OATH",
+ "apihelp-query+oath-description": "Поставити позначку, щоб побачити, чи двофакторна автентифікація (OATH) увімкнена для користувача.",
+ "apihelp-query+oath-summary": "Проведіть перевірку, щоб побачити, чи двофакторна автентифікація (OATH) увімкнена для користувача.",
+ "apihelp-query+oath-param-user": "Користувач, про якого треба отримати інформацію. За замовчуванням ним є поточний користувач.",
+ "apihelp-query+oath-example-1": "Отримати інформацію про поточного користувача",
+ "apihelp-query+oath-example-2": "Отримати інформацію про користувача <kbd>Example</kbd>",
+ "apihelp-oathvalidate-description": "Перевірити токен двофакторної автентифікації (OATH).",
+ "apihelp-oathvalidate-summary": "Перевірити токен двофакторної автентифікації (OATH).",
+ "apihelp-oathvalidate-param-user": "Користувач, для якого треба перевірити токен. За замовчуванням ним є поточний користувач.",
+ "apihelp-oathvalidate-param-totp": "Токен двофакторної автентифікації (OATH).",
+ "apihelp-oathvalidate-example-1": "Перевірити токен для поточного користувача",
+ "apihelp-oathvalidate-example-2": "Перевірити токен для користувача <kbd>Example</kbd>"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/ur.json b/www/wiki/extensions/OATHAuth/i18n/ur.json
new file mode 100644
index 00000000..d60ea8dc
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/ur.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද",
+ "Muhammad Shuaib"
+ ]
+ },
+ "oathauth-enable": "دو مرحلہ تصدیق فعال کریں",
+ "oathauth-disable": "دو مرحلہ تصدیق غیر فعال کریں",
+ "oathauth-disabledoath": "معذور تصدیق دو عنصر.",
+ "oathauth-prefs-label": "دو مرحلہ تصدیق:",
+ "right-oathauth-enable": "دو مرحلہ تصدیق کا نفاذ",
+ "action-oathauth-enable": "دو مرحلہ تصدیق فعال کرنے"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/vi.json b/www/wiki/extensions/OATHAuth/i18n/vi.json
new file mode 100644
index 00000000..8af48836
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/vi.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minh Nguyen"
+ ]
+ },
+ "oathauth-desc": "Cho phép xác nhận dùng các mật khẩu một lần dựa trên mã xác thực thông điệp được băm (HMAC)",
+ "oath": "Xác thực OATH",
+ "specialpages-group-oath": "Xác thực dùng hai nhân tố",
+ "oathauth-account": "Tên tài khoản:",
+ "oathauth-secret": "Chìa khóa bí mật để xác thực dùng hai nhân tố:",
+ "oathauth-enable": "Xác thực dùng hai nhân tố",
+ "oathauth-scratchtokens": "Danh sách sau có các mã dùng một lần. Các mã này chỉ có thể dùng một lần cho mục đích khẩn cấp. Xin hãy ghi xuống các mã này và lưu giữ chúng tại một nơi an toàn. Nếu bạn mất điện thoại của bạn, các mã này là phương sách duy nhất để cứu tài khoản của bạn. Từ nay các mã này sẽ không bao giờ được hiển thị.",
+ "oathauth-token": "Mã",
+ "oathauth-disable": "Tắt xác thực dùng hai nhân tố",
+ "oathauth-validatedoath": "Đã xác nhận thông tin xác thực dùng hai nhân tố. Từ nay sẽ áp dụng việc xác thực dùng hai nhân tố.",
+ "oathauth-noscratchforvalidation": "Bạn không thể sử dụng mã thẻ để xác thực dùng hai nhân tố. Các mã thẻ chỉ để sao lưu hoặc sử dụng tình cờ. Xin hãy nhập mã xác nhận từ trình xác thực của bạn.",
+ "oathauth-failedtovalidateoath": "Thất bại khi xác nhận thông tin xác thực dùng hai nhân tố",
+ "oathauth-disabledoath": "Đã tắt xác thực dùng hai nhân tố.",
+ "oathauth-prefs-label": "Xác thực dùng hai nhân tố:",
+ "oathauth-step1": "Bước 1: Tải về ứng dụng xác thực dùng hai nhân tố",
+ "oathauth-step1-test": "Tải một chương trình có chức năng xác thực dùng hai nhân tố, có thể là ứng dụng di động như trình xác thực Google Authenticator hoặc một ứng dụng dành cho máy tính để bàn.",
+ "oathauth-step2": "Bước 2: Quét mã QR",
+ "oathauth-step2alt": "Hoặc nhập mật mã thủ công:",
+ "oathauth-step3": "Bước 3: Ghi xuống các mã thẻ",
+ "oathauth-step4": "Bước 4: Xác nhận",
+ "oathauth-entertoken": "Nhập một mã từ thiết bị xác thực của bạn để xác nhận:",
+ "right-oathauth-enable": "Xác thực dùng hai nhân tố",
+ "action-oathauth-enable": "xác thực dùng hai nhân tố",
+ "oathauth-auth-token-label": "Mã",
+ "oathauth-auth-token-help": "Mật khẩu dùng một lần được sử dụng làm nhân tố thứ hai trong quá trình xác thực dùng hai nhân tố.",
+ "oathauth-auth-ui": "Xin hãy nhập mã xác nhận từ máy xác thực của bạn",
+ "oathauth-throttled": "Đã cố xác nhận danh tính nhiều lần quá! Xin hãy chờ $1.",
+ "oathauth-login-failed": "Xác nhận thất bại.",
+ "oathauth-describe-provider": "Xác thực dùng hai nhân tố (OATH).",
+ "grant-group-authentication": "Thực hiện các tác vụ xác thực cho chính mình và những người khác",
+ "grant-oath": "Truy cập thông tin xác thực dùng hai nhân tố (OATH) về chính mình và những người khác",
+ "right-oathauth-api-all": "Truy vấn và xác nhận thông tin OATH về chính mình và những người khác",
+ "action-oathauth-api-all": "kiểm tra trạng thái OATH"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/yi.json b/www/wiki/extensions/OATHAuth/i18n/yi.json
new file mode 100644
index 00000000..e4f926bd
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/yi.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "פוילישער"
+ ]
+ },
+ "oathauth-account": "קאנטע נאמען:"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/zh-hans.json b/www/wiki/extensions/OATHAuth/i18n/zh-hans.json
new file mode 100644
index 00000000..6c2a94bc
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/zh-hans.json
@@ -0,0 +1,53 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hzy980512",
+ "Liuxinyu970226",
+ "Xiaomingyan",
+ "Yfdyh000"
+ ]
+ },
+ "oathauth-desc": "提供使用基于HMAC的一次性密码的身份验证支持",
+ "specialpages-group-oath": "双因素验证",
+ "oathauth-account": "账户名称:",
+ "oathauth-secret": "双因素验证密钥:",
+ "oathauth-enable": "启用双因素验证",
+ "oathauth-scratchtokens": "下面的列表是一次性使用的即时令牌列表。这些令牌只能使用一次,并应用于紧急用途。请将它们记下来,并保存在一个安全的位置。如果您遗失了手机,唯一能够找回您账户的方法就是这些令牌。'''这些令牌不会再显示'''。",
+ "oathauth-token": "令牌",
+ "oathauth-disable": "禁用双因素验证",
+ "oathauth-validatedoath": "已验证双因素证书。双因素验证现将实施生效。",
+ "oathauth-noscratchforvalidation": "您不能使用乱码确认双因素验证。乱码只用于备份及附带使用。请使用来自您的代码生成器的确认代码。",
+ "oathauth-failedtovalidateoath": "验证双因素凭据失败",
+ "oathauth-disabledoath": "已禁用双因素验证。",
+ "oathauth-prefs-label": "双因素验证:",
+ "oathauth-step1": "第1步:下载双因素验证程序",
+ "oathauth-step1-test": "下载用于双因素验证的程序。这可以是移动应用(例如Google Authenticator)或桌面端应用",
+ "oathauth-step2": "第2步:扫描二维码",
+ "oathauth-step2alt": "或手动输入密钥:",
+ "oathauth-step3": "第3步:记下即时性代码",
+ "oathauth-step4": "第4步:验证",
+ "oathauth-entertoken": "输入来自您的验证设备的代码进行验证:",
+ "right-oathauth-enable": "启用双因素验证",
+ "action-oathauth-enable": "启用双因素验证",
+ "oathauth-auth-token-label": "令牌",
+ "oathauth-auth-token-help": "用作双因素验证中第二因素的一次性密码。",
+ "oathauth-auth-ui": "请输入来自您的验证设备的验证码",
+ "oathauth-throttled": "尝试了太多次验证!请等待$1。",
+ "oathauth-login-failed": "验证失败。",
+ "oathauth-describe-provider": "双因素验证(OATH)。",
+ "grant-group-authentication": "为自己和他人执行身份验证操作",
+ "grant-oath": "访问自己和他人的双因素验证(OATH)信息",
+ "right-oathauth-api-all": "查询并验证自己和他人的OATH信息",
+ "action-oathauth-api-all": "检查OATH状态",
+ "apihelp-query+oath-description": "检查是否为某一用户启用双因素验证(OATH)。",
+ "apihelp-query+oath-summary": "检查双因素验证(OATH)是否为某一用户启用。",
+ "apihelp-query+oath-param-user": "获取相关信息的用户。默认为当前用户。",
+ "apihelp-query+oath-example-1": "获取有关当前用户的信息",
+ "apihelp-query+oath-example-2": "获取有关用户<kbd>Example</kbd>的信息",
+ "apihelp-oathvalidate-description": "验证一个双因素验证(OATH)令牌。",
+ "apihelp-oathvalidate-summary": "验证一个双因素验证(OATH)令牌。",
+ "apihelp-oathvalidate-param-user": "要验证令牌的用户。默认为当前用户。",
+ "apihelp-oathvalidate-param-totp": "双因素验证(OATH)令牌。",
+ "apihelp-oathvalidate-example-1": "验证当前用户的令牌",
+ "apihelp-oathvalidate-example-2": "验证用户<kbd>Example</kbd>的令牌"
+}
diff --git a/www/wiki/extensions/OATHAuth/i18n/zh-hant.json b/www/wiki/extensions/OATHAuth/i18n/zh-hant.json
new file mode 100644
index 00000000..667d1ba7
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/i18n/zh-hant.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Simon Shek",
+ "Cwlin0416",
+ "LNDDYL",
+ "Alexsh",
+ "Waihorace",
+ "A2093064",
+ "Hello903hello"
+ ]
+ },
+ "oathauth-desc": "提供支援 HMAC 為基礎的一次性密碼認證",
+ "specialpages-group-oath": "雙重認證",
+ "oathauth-account": "帳號名稱:",
+ "oathauth-secret": "雙重認證秘密金鑰:",
+ "oathauth-enable": "開啟雙重認證",
+ "oathauth-scratchtokens": "以下是一次性使用的備用密碼,這些密碼於緊急情況使用,且只能使用一次。請寫下這些密碼,並存放在安全的地方。如果您遺失了您的行動電話,這些密碼可以回復您的帳號。\n這些密碼只會於現在顯示一次,之後將不會再次顯示。",
+ "oathauth-token": "金鑰",
+ "oathauth-disable": "停用雙重認證",
+ "oathauth-validatedoath": "已驗證您的代碼並啟動雙重認證。",
+ "oathauth-failedtovalidateoath": "驗證雙重認證失敗。",
+ "oathauth-disabledoath": "已停用雙重認證。",
+ "oathauth-prefs-label": "雙重認證:",
+ "oathauth-step1": "第1步:下載雙重認證應用程式",
+ "oathauth-step1-test": "下載雙重認證的應用程式。這可以是一個流動應用程式(例如Google Authenticator)或一個桌面應用程式",
+ "oathauth-step2": "掃描QR碼",
+ "oathauth-step2alt": "或手動輸入密鑰:",
+ "oathauth-step3": "記下備用碼",
+ "oathauth-step4": "驗證",
+ "oathauth-entertoken": "輸入顯示於您認證設備上應用程式的代碼:",
+ "right-oathauth-enable": "啟用雙重認證",
+ "action-oathauth-enable": "啟用雙重認證",
+ "oathauth-auth-token-label": "金鑰",
+ "oathauth-auth-token-help": "用作雙重認證的一次性密碼",
+ "oathauth-auth-ui": "請輸入您行動裝置上顯示的驗證碼",
+ "oathauth-throttled": "驗證次數過多,請稍等 $1。",
+ "oathauth-login-failed": "驗證失敗",
+ "oathauth-describe-provider": "雙重認證(OATH)",
+ "grant-group-authentication": "為自己及其他人進行身份認證動作",
+ "apihelp-oathvalidate-description": "驗證雙重認證金鑰",
+ "apihelp-oathvalidate-param-totp": "雙重認證金鑰"
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/OATHAuthHooks.php b/www/wiki/extensions/OATHAuth/includes/OATHAuthHooks.php
new file mode 100644
index 00000000..8842b16a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/OATHAuthHooks.php
@@ -0,0 +1,221 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+use MediaWiki\Auth\AuthenticationRequest;
+use MediaWiki\MediaWikiServices;
+use Wikimedia\Rdbms\IDatabase;
+
+/**
+ * Hooks for Extension:OATHAuth
+ *
+ * @ingroup Extensions
+ */
+class OATHAuthHooks {
+ /**
+ * Get the singleton OATH user repository
+ *
+ * @return OATHUserRepository
+ */
+ public static function getOATHUserRepository() {
+ global $wgOATHAuthDatabase;
+
+ static $service = null;
+
+ if ( $service == null ) {
+ $factory = MediaWikiServices::getInstance()->getDBLoadBalancerFactory();
+ $service = new OATHUserRepository(
+ $factory->getMainLB( $wgOATHAuthDatabase ),
+ new HashBagOStuff(
+ [
+ 'maxKeys' => 5,
+ ]
+ )
+ );
+ }
+
+ return $service;
+ }
+
+ /**
+ * @param AuthenticationRequest[] $requests
+ * @param array $fieldInfo Field information array (union of the
+ * AuthenticationRequest::getFieldInfo() responses).
+ * @param array &$formDescriptor HTMLForm descriptor. The special key 'weight' can be set
+ * to change the order of the fields.
+ * @param string $action One of the AuthManager::ACTION_* constants.
+ * @return bool
+ */
+ public static function onAuthChangeFormFields(
+ array $requests, array $fieldInfo, array &$formDescriptor, $action
+ ) {
+ if ( isset( $fieldInfo['OATHToken'] ) ) {
+ $formDescriptor['OATHToken'] += [
+ 'cssClass' => 'loginText',
+ 'id' => 'wpOATHToken',
+ 'size' => 20,
+ 'autofocus' => true,
+ 'persistent' => false,
+ 'autocomplete' => false,
+ 'spellcheck' => false,
+ ];
+ }
+ return true;
+ }
+
+ /**
+ * Determine if two-factor authentication is enabled for $wgUser
+ *
+ * This isn't the preferred mechanism for controlling access to sensitive features
+ * (see AuthManager::securitySensitiveOperationStatus() for that) but there is no harm in
+ * keeping it.
+ *
+ * @param bool &$isEnabled Will be set to true if enabled, false otherwise
+ * @return bool False if enabled, true otherwise
+ */
+ public static function onTwoFactorIsEnabled( &$isEnabled ) {
+ global $wgUser;
+
+ $user = self::getOATHUserRepository()->findByUser( $wgUser );
+ if ( $user && $user->getKey() !== null ) {
+ $isEnabled = true;
+ # This two-factor extension is enabled by the user,
+ # we don't need to check others.
+ return false;
+ } else {
+ $isEnabled = false;
+ # This two-factor extension isn't enabled by the user,
+ # but others may be.
+ return true;
+ }
+ }
+
+ /**
+ * Add the necessary user preferences for OATHAuth
+ *
+ * @param User $user
+ * @param array &$preferences
+ * @return bool
+ */
+ public static function onGetPreferences( User $user, array &$preferences ) {
+ $oathUser = self::getOATHUserRepository()->findByUser( $user );
+
+ // If there is no existing key, and the user is not allowed to enable it,
+ // we have nothing to show. (
+ if ( $oathUser->getKey() === null && !$user->isAllowed( 'oathauth-enable' ) ) {
+ return true;
+ }
+
+ $title = SpecialPage::getTitleFor( 'OATH' );
+ $msg = $oathUser->getKey() !== null ? 'oathauth-disable' : 'oathauth-enable';
+
+ $preferences[$msg] = [
+ 'type' => 'info',
+ 'raw' => 'true',
+ 'default' => Linker::link(
+ $title,
+ wfMessage( $msg )->escaped(),
+ [],
+ [ 'returnto' => SpecialPage::getTitleFor( 'Preferences' )->getPrefixedText() ]
+ ),
+ 'label-message' => 'oathauth-prefs-label',
+ 'section' => 'personal/info', ];
+
+ return true;
+ }
+
+ /**
+ * @param DatabaseUpdater $updater
+ * @return bool
+ */
+ public static function onLoadExtensionSchemaUpdates( $updater ) {
+ $base = dirname( __DIR__ );
+ switch ( $updater->getDB()->getType() ) {
+ case 'mysql':
+ case 'sqlite':
+ $updater->addExtensionTable( 'oathauth_users', "$base/sql/mysql/tables.sql" );
+ $updater->addExtensionUpdate( [ [ __CLASS__, 'schemaUpdateOldUsersFromInstaller' ] ] );
+ $updater->dropExtensionField(
+ 'oathauth_users',
+ 'secret_reset',
+ "$base/sql/mysql/patch-remove_reset.sql"
+ );
+ break;
+
+ case 'oracle':
+ $updater->addExtensionTable( 'oathauth_users', "$base/sql/oracle/tables.sql" );
+ break;
+
+ case 'postgres':
+ $updater->addExtensionTable( 'oathauth_users', "$base/sql/postgres/tables.sql" );
+ break;
+ }
+
+ return true;
+ }
+
+ /**
+ * Helper function for converting old users to the new schema
+ * @see OATHAuthHooks::OATHAuthSchemaUpdates
+ *
+ * @param DatabaseUpdater $updater
+ *
+ * @return bool
+ */
+ public static function schemaUpdateOldUsersFromInstaller( DatabaseUpdater $updater ) {
+ return self::schemaUpdateOldUsers( $updater->getDB() );
+ }
+
+ /**
+ * Helper function for converting old users to the new schema
+ * @see OATHAuthHooks::OATHAuthSchemaUpdates
+ *
+ * @param IDatabase $db
+ * @return bool
+ */
+ public static function schemaUpdateOldUsers( IDatabase $db ) {
+ if ( !$db->fieldExists( 'oathauth_users', 'secret_reset' ) ) {
+ return true;
+ }
+
+ $res = $db->select(
+ 'oathauth_users',
+ [ 'id', 'scratch_tokens' ],
+ [ 'is_validated != 0' ],
+ __METHOD__
+ );
+
+ foreach ( $res as $row ) {
+ Wikimedia\suppressWarnings();
+ $scratchTokens = unserialize( base64_decode( $row->scratch_tokens ) );
+ Wikimedia\restoreWarnings();
+ if ( $scratchTokens ) {
+ $db->update(
+ 'oathauth_users',
+ [ 'scratch_tokens' => implode( ',', $scratchTokens ) ],
+ [ 'id' => $row->id ],
+ __METHOD__
+ );
+ }
+ }
+
+ // Remove rows from the table where user never completed the setup process
+ $db->delete( 'oathauth_users', [ 'is_validated' => 0 ], __METHOD__ );
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/OATHAuthKey.php b/www/wiki/extensions/OATHAuth/includes/OATHAuthKey.php
new file mode 100644
index 00000000..2e178803
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/OATHAuthKey.php
@@ -0,0 +1,187 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Class representing a two-factor key
+ *
+ * Keys can be tied to OATHUsers
+ *
+ * @ingroup Extensions
+ */
+class OATHAuthKey {
+ /**
+ * Represents that a token corresponds to the main secret
+ * @see verifyToken
+ */
+ const MAIN_TOKEN = 1;
+
+ /**
+ * Represents that a token corresponds to a scratch token
+ * @see verifyToken
+ */
+ const SCRATCH_TOKEN = -1;
+
+ /** @var array Two factor binary secret */
+ private $secret;
+
+ /** @var string[] List of scratch tokens */
+ private $scratchTokens;
+
+ /**
+ * Make a new key from random values
+ *
+ * @return OATHAuthKey
+ */
+ public static function newFromRandom() {
+ $object = new self(
+ Base32::encode( MWCryptRand::generate( 10, true ) ),
+ []
+ );
+
+ $object->regenerateScratchTokens();
+
+ return $object;
+ }
+
+ /**
+ * @param string $secret
+ * @param array $scratchTokens
+ */
+ public function __construct( $secret, array $scratchTokens ) {
+ // Currently harcoded values; might be used in future
+ $this->secret = [
+ 'mode' => 'hotp',
+ 'secret' => $secret,
+ 'period' => 30,
+ 'algorithm' => 'SHA1',
+ ];
+ $this->scratchTokens = $scratchTokens;
+ }
+
+ /**
+ * @return string
+ */
+ public function getSecret() {
+ return $this->secret['secret'];
+ }
+
+ /**
+ * @return array
+ */
+ public function getScratchTokens() {
+ return $this->scratchTokens;
+ }
+
+ /**
+ * Verify a token against the secret or scratch tokens
+ *
+ * @param string $token Token to verify
+ * @param OATHUser $user
+ *
+ * @return int|false Returns a constant represent what type of token was matched,
+ * or false for no match
+ */
+ public function verifyToken( $token, OATHUser $user ) {
+ global $wgOATHAuthWindowRadius;
+
+ if ( $this->secret['mode'] !== 'hotp' ) {
+ throw new \DomainException( 'OATHAuth extension does not support non-HOTP tokens' );
+ }
+
+ // Prevent replay attacks
+ $memc = ObjectCache::newAnything( [] );
+ $uid = CentralIdLookup::factory()->centralIdFromLocalUser( $user->getUser() );
+ $memcKey = wfMemcKey( 'oathauth', 'usedtokens', $uid );
+ $lastWindow = (int)$memc->get( $memcKey );
+
+ $retval = false;
+ $results = HOTP::generateByTimeWindow(
+ Base32::decode( $this->secret['secret'] ),
+ $this->secret['period'], -$wgOATHAuthWindowRadius, $wgOATHAuthWindowRadius
+ );
+
+ // Remove any whitespace from the received token, which can be an intended group seperator
+ // or trimmeable whitespace
+ $token = preg_replace( '/\s+/', '', $token );
+
+ // Check to see if the user's given token is in the list of tokens generated
+ // for the time window.
+ foreach ( $results as $window => $result ) {
+ if ( $window > $lastWindow && $result->toHOTP( 6 ) === $token ) {
+ $lastWindow = $window;
+ $retval = self::MAIN_TOKEN;
+ break;
+ }
+ }
+
+ // See if the user is using a scratch token
+ if ( !$retval ) {
+ $length = count( $this->scratchTokens );
+ // Detect condition where all scratch tokens have been used
+ if ( $length == 1 && "" === $this->scratchTokens[0] ) {
+ $retval = false;
+ } else {
+ for ( $i = 0; $i < $length; $i++ ) {
+ if ( $token === $this->scratchTokens[$i] ) {
+ // If there is a scratch token, remove it from the scratch token list
+ unset( $this->scratchTokens[$i] );
+ $oathrepo = OATHAuthHooks::getOATHUserRepository();
+ $user->setKey( $this );
+ $oathrepo->persist( $user );
+ // Only return true if we removed it from the database
+ $retval = self::SCRATCH_TOKEN;
+ break;
+ }
+ }
+ }
+ }
+
+ if ( $retval ) {
+ $memc->set(
+ $memcKey,
+ $lastWindow,
+ $this->secret['period'] * ( 1 + 2 * $wgOATHAuthWindowRadius )
+ );
+ } else {
+ // Increase rate limit counter for failed request
+ $user->getUser()->pingLimiter( 'badoath' );
+ }
+
+ return $retval;
+ }
+
+ public function regenerateScratchTokens() {
+ $scratchTokens = [];
+ for ( $i = 0; $i < 5; $i++ ) {
+ array_push( $scratchTokens, Base32::encode( MWCryptRand::generate( 10, true ) ) );
+ }
+ $this->scratchTokens = $scratchTokens;
+ }
+
+ /**
+ * Check if a token is one of the scratch tokens for this two factor key.
+ *
+ * @param string $token Token to verify
+ *
+ * @return bool true if this is a scratch token.
+ */
+ public function isScratchToken( $token ) {
+ $token = preg_replace( '/\s+/', '', $token );
+ return in_array( $token, $this->scratchTokens, true );
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/OATHAuthUtils.php b/www/wiki/extensions/OATHAuth/includes/OATHAuthUtils.php
new file mode 100644
index 00000000..2afd3bf8
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/OATHAuthUtils.php
@@ -0,0 +1,141 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Utility class for various OATH functions
+ *
+ * @ingroup Extensions
+ */
+class OATHAuthUtils {
+ /**
+ * Check whether OATH two-factor authentication is enabled for a given user.
+ * This is a stable method that does not change and can be used in other extensions.
+ * @param User $user
+ * @return bool
+ */
+ public static function isEnabledFor( User $user ) {
+ $oathUser = OATHAuthHooks::getOATHUserRepository()->findByUser( $user );
+ return $oathUser && $oathUser->getKey();
+ }
+
+ /**
+ * Encrypt an aray of variables to put into the user's session. We use this
+ * when storing the user's password in their session. We can use json as the
+ * serialization format because $plaintextVars is an array of strings.
+ * @param array $plaintextVars array of user input strings
+ * @param int $userId passed to key derivation functions so each user uses
+ * distinct encryption and hmac keys
+ * @return string encrypted data packet
+ */
+ public static function encryptSessionData( array $plaintextVars, $userId ) {
+ $keyMaterial = self::getKeyMaterials();
+ $keys = self::getUserKeys( $keyMaterial, $userId );
+ return self::seal( json_encode( $plaintextVars ), $keys['encrypt'], $keys['hmac'] );
+ }
+
+ /**
+ * Decrypt an encrypted packet, generated with encryptSessionData
+ * @param string $ciphertext Encrypted data packet
+ * @param string|int $userId
+ * @return array of strings
+ */
+ public static function decryptSessionData( $ciphertext, $userId ) {
+ $keyMaterial = self::getKeyMaterials();
+ $keys = self::getUserKeys( $keyMaterial, $userId );
+ return json_decode( self::unseal( $ciphertext, $keys['encrypt'], $keys['hmac'] ), true );
+ }
+
+ /**
+ * Get the base secret for this wiki, used to derive all of the encryption
+ * keys. When $wgOATHAuthSecret is rotated, users who are part way through the
+ * two-step login will get an exception, and have to re-start the login.
+ * @return string
+ */
+ private static function getKeyMaterials() {
+ global $wgOATHAuthSecret, $wgSecretKey;
+ return $wgOATHAuthSecret ?: $wgSecretKey;
+ }
+
+ /**
+ * Generate encryption and hmac keys, unique to this user, based on a single
+ * wiki secret. Use a moderate pbkdf2 work factor in case we ever leak keys.
+ * @param string $secret
+ * @param string|int $userid
+ * @return array including key for encryption and integrity checking
+ */
+ private static function getUserKeys( $secret, $userid ) {
+ $keymats = hash_pbkdf2( 'sha256', $secret, "oath-$userid", 10001, 64, true );
+ return [
+ 'encrypt' => substr( $keymats, 0, 32 ),
+ 'hmac' => substr( $keymats, 32, 32 ),
+ ];
+ }
+
+ /**
+ * Actually encrypt the data, using a new random IV, and prepend the hmac
+ * of the encrypted data + IV, using a separate hmac key.
+ * @param string $data
+ * @param string $encKey
+ * @param string $hmacKey
+ * @return string $hmac.$iv.$ciphertext, each component b64 encoded
+ */
+ private static function seal( $data, $encKey, $hmacKey ) {
+ $iv = MWCryptRand::generate( 16, true );
+ $ciphertext = openssl_encrypt(
+ $data,
+ 'aes-256-ctr',
+ $encKey,
+ OPENSSL_RAW_DATA,
+ $iv
+ );
+ $sealed = base64_encode( $iv ) . '.' . base64_encode( $ciphertext );
+ $hmac = hash_hmac( 'sha256', $sealed, $hmacKey, true );
+ return base64_encode( $hmac ) . '.' . $sealed;
+ }
+
+ /**
+ * Decrypt data sealed using seal(). First checks the hmac to prevent various
+ * attacks.
+ * @param string $encrypted
+ * @param string $encKey
+ * @param string $hmacKey
+ * @return string plaintext
+ * @throws Exception
+ */
+ private static function unseal( $encrypted, $encKey, $hmacKey ) {
+ $pieces = explode( '.', $encrypted );
+ if ( count( $pieces ) !== 3 ) {
+ throw new InvalidArgumentException( 'Invalid sealed-secret format' );
+ }
+
+ list( $hmac, $iv, $ciphertext ) = $pieces;
+ $integCalc = hash_hmac( 'sha256', $iv . '.' . $ciphertext, $hmacKey, true );
+ if ( !hash_equals( $integCalc, base64_decode( $hmac ) ) ) {
+ throw new Exception( 'Sealed secret has been tampered with, aborting.' );
+ }
+
+ return openssl_decrypt(
+ base64_decode( $ciphertext ),
+ 'aes-256-ctr',
+ $encKey,
+ OPENSSL_RAW_DATA,
+ base64_decode( $iv )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/OATHUser.php b/www/wiki/extensions/OATHAuth/includes/OATHUser.php
new file mode 100644
index 00000000..ed1b4a16
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/OATHUser.php
@@ -0,0 +1,83 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Class representing a user from OATH's perspective
+ *
+ * @ingroup Extensions
+ */
+class OATHUser {
+ /** @var User */
+ private $user;
+
+ /** @var OATHAuthKey|null */
+ private $key;
+
+ /**
+ * Constructor. Can't be called directly. Use OATHUserRepository::findByUser instead.
+ * @param User $user
+ * @param OATHAuthKey|null $key
+ */
+ public function __construct( User $user, OATHAuthKey $key = null ) {
+ $this->user = $user;
+ $this->key = $key;
+ }
+
+ /**
+ * @return User
+ */
+ public function getUser() {
+ return $this->user;
+ }
+
+ /**
+ * @return String
+ */
+ public function getIssuer() {
+ global $wgSitename, $wgOATHAuthAccountPrefix;
+ if ( $wgOATHAuthAccountPrefix !== false ) {
+ return $wgOATHAuthAccountPrefix;
+ }
+ return $wgSitename;
+ }
+
+ /**
+ * @return String
+ */
+ public function getAccount() {
+ return $this->user->getName();
+ }
+
+ /**
+ * Get the key associated with this user.
+ *
+ * @return null|OATHAuthKey
+ */
+ public function getKey() {
+ return $this->key;
+ }
+
+ /**
+ * Set the key associated with this user.
+ *
+ * @param OATHAuthKey|null $key
+ */
+ public function setKey( OATHAuthKey $key = null ) {
+ $this->key = $key;
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/OATHUserRepository.php b/www/wiki/extensions/OATHAuth/includes/OATHUserRepository.php
new file mode 100644
index 00000000..698ca49b
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/OATHUserRepository.php
@@ -0,0 +1,103 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+use Wikimedia\Rdbms\LoadBalancer;
+use Wikimedia\Rdbms\DBConnRef;
+
+class OATHUserRepository {
+ /** @var LoadBalancer */
+ protected $lb;
+
+ /** @var BagOStuff */
+ protected $cache;
+
+ /**
+ * OATHUserRepository constructor.
+ * @param LoadBalancer $lb
+ * @param BagOStuff $cache
+ */
+ public function __construct( LoadBalancer $lb, BagOStuff $cache ) {
+ $this->lb = $lb;
+ $this->cache = $cache;
+ }
+
+ /**
+ * @param User $user
+ * @return OATHUser
+ */
+ public function findByUser( User $user ) {
+ $oathUser = $this->cache->get( $user->getName() );
+ if ( !$oathUser ) {
+ $oathUser = new OATHUser( $user, null );
+
+ $uid = CentralIdLookup::factory()->centralIdFromLocalUser( $user );
+ $res = $this->getDB( DB_REPLICA )->selectRow(
+ 'oathauth_users',
+ '*',
+ [ 'id' => $uid ],
+ __METHOD__
+ );
+ if ( $res ) {
+ $key = new OATHAuthKey( $res->secret, explode( ',', $res->scratch_tokens ) );
+ $oathUser->setKey( $key );
+ }
+
+ $this->cache->set( $user->getName(), $oathUser );
+ }
+ return $oathUser;
+ }
+
+ /**
+ * @param OATHUser $user
+ */
+ public function persist( OATHUser $user ) {
+ $this->getDB( DB_MASTER )->replace(
+ 'oathauth_users',
+ [ 'id' ],
+ [
+ 'id' => CentralIdLookup::factory()->centralIdFromLocalUser( $user->getUser() ),
+ 'secret' => $user->getKey()->getSecret(),
+ 'scratch_tokens' => implode( ',', $user->getKey()->getScratchTokens() ),
+ ],
+ __METHOD__
+ );
+ $this->cache->set( $user->getUser()->getName(), $user );
+ }
+
+ /**
+ * @param OATHUser $user
+ */
+ public function remove( OATHUser $user ) {
+ $this->getDB( DB_MASTER )->delete(
+ 'oathauth_users',
+ [ 'id' => CentralIdLookup::factory()->centralIdFromLocalUser( $user->getUser() ) ],
+ __METHOD__
+ );
+ $this->cache->delete( $user->getUser()->getName() );
+ }
+
+ /**
+ * @param integer $index DB_MASTER/DB_REPLICA
+ * @return DBConnRef
+ */
+ private function getDB( $index ) {
+ global $wgOATHAuthDatabase;
+
+ return $this->lb->getConnectionRef( $index, [], $wgOATHAuthDatabase );
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/api/ApiOATHValidate.php b/www/wiki/extensions/OATHAuth/includes/api/ApiOATHValidate.php
new file mode 100644
index 00000000..14f46414
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/api/ApiOATHValidate.php
@@ -0,0 +1,101 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Validate an OATH token.
+ *
+ * @ingroup API
+ * @ingroup Extensions
+ */
+class ApiOATHValidate extends ApiBase {
+ public function execute() {
+ // Be extra paranoid about the data that is sent
+ $this->requirePostedParameters( [ 'totp', 'token' ] );
+
+ $params = $this->extractRequestParams();
+ if ( $params['user'] === null ) {
+ $params['user'] = $this->getUser()->getName();
+ }
+
+ $this->checkUserRightsAny( 'oathauth-api-all' );
+
+ $user = User::newFromName( $params['user'] );
+ if ( $user === false ) {
+ $this->dieWithError( 'noname' );
+ }
+
+ // Don't increase pingLimiter, just check for limit exceeded.
+ if ( $user->pingLimiter( 'badoath', 0 ) ) {
+ $this->dieWithError( 'apierror-ratelimited' );
+ }
+
+ $result = [
+ ApiResult::META_BC_BOOLS => [ 'enabled', 'valid' ],
+ 'enabled' => false,
+ 'valid' => false,
+ ];
+
+ if ( !$user->isAnon() ) {
+ $oathUser = OATHAuthHooks::getOATHUserRepository()
+ ->findByUser( $user );
+ if ( $oathUser ) {
+ $key = $oathUser->getKey();
+ if ( $key !== null ) {
+ $result['enabled'] = true;
+ $result['valid'] = $key->verifyToken(
+ $params['totp'], $oathUser ) !== false;
+ }
+ }
+ }
+
+ $this->getResult()->addValue( null, $this->getModuleName(), $result );
+ }
+
+ public function getCacheMode( $params ) {
+ return 'private';
+ }
+
+ public function isInternal() {
+ return true;
+ }
+
+ public function needsToken() {
+ return 'csrf';
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'user' => [
+ ApiBase::PARAM_TYPE => 'user',
+ ],
+ 'totp' => [
+ ApiBase::PARAM_TYPE => 'string',
+ ApiBase::PARAM_REQUIRED => true,
+ ],
+ ];
+ }
+
+ protected function getExamplesMessages() {
+ return [
+ 'action=oathvalidate&totp=123456&token=123ABC'
+ => 'apihelp-oathvalidate-example-1',
+ 'action=oathvalidate&user=Example&totp=123456&token=123ABC'
+ => 'apihelp-oathvalidate-example-2',
+ ];
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/api/ApiQueryOATH.php b/www/wiki/extensions/OATHAuth/includes/api/ApiQueryOATH.php
new file mode 100644
index 00000000..e131f193
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/api/ApiQueryOATH.php
@@ -0,0 +1,90 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Query module to check if a user has OATH authentication enabled.
+ *
+ * Usage requires the 'oathauth-api-all' grant which is not given to any group
+ * by default. Use of this API is security sensitive and should not be granted
+ * lightly. Configuring a special 'oathauth' user group is recommended.
+ *
+ * @ingroup API
+ * @ingroup Extensions
+ */
+class ApiQueryOATH extends ApiQueryBase {
+ public function __construct( $query, $moduleName ) {
+ parent::__construct( $query, $moduleName, 'oath' );
+ }
+
+ public function execute() {
+ $params = $this->extractRequestParams();
+ if ( $params['user'] === null ) {
+ $params['user'] = $this->getUser()->getName();
+ }
+
+ $this->checkUserRightsAny( 'oathauth-api-all' );
+
+ $user = User::newFromName( $params['user'] );
+ if ( $user === false ) {
+ $this->dieWithError( 'noname' );
+ }
+
+ $result = $this->getResult();
+ $data = [
+ ApiResult::META_BC_BOOLS => [ 'enabled' ],
+ 'enabled' => false,
+ ];
+
+ if ( !$user->isAnon() ) {
+ $oathUser = OATHAuthHooks::getOATHUserRepository()
+ ->findByUser( $user );
+ $data['enabled'] = $oathUser && $oathUser->getKey() !== null;
+ }
+ $result->addValue( 'query', $this->getModuleName(), $data );
+ }
+
+ /**
+ * @param array $params
+ *
+ * @return string
+ */
+ public function getCacheMode( $params ) {
+ return 'private';
+ }
+
+ public function isInternal() {
+ return true;
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'user' => [
+ ApiBase::PARAM_TYPE => 'user',
+ ],
+ ];
+ }
+
+ protected function getExamplesMessages() {
+ return [
+ 'action=query&meta=oath'
+ => 'apihelp-query+oath-example-1',
+ 'action=query&meta=oath&oathuser=Example'
+ => 'apihelp-query+oath-example-2',
+ ];
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/auth/TOTPAuthenticationRequest.php b/www/wiki/extensions/OATHAuth/includes/auth/TOTPAuthenticationRequest.php
new file mode 100644
index 00000000..c10f5e2f
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/auth/TOTPAuthenticationRequest.php
@@ -0,0 +1,43 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+use MediaWiki\Auth\AuthenticationRequest;
+
+/**
+ * AuthManager value object for the TOTP second factor of an authentication:
+ * a pseudorandom token that is generated from the current time independently
+ * by the server and the client.
+ */
+class TOTPAuthenticationRequest extends AuthenticationRequest {
+ public $OATHToken;
+
+ public function describeCredentials() {
+ return [
+ 'provider' => wfMessage( 'oathauth-describe-provider' ),
+ 'account' => new \RawMessage( '$1', [ $this->username ] ),
+ ] + parent::describeCredentials();
+ }
+
+ public function getFieldInfo() {
+ return [
+ 'OATHToken' => [
+ 'type' => 'string',
+ 'label' => wfMessage( 'oathauth-auth-token-label' ),
+ 'help' => wfMessage( 'oathauth-auth-token-help' ), ], ];
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/auth/TOTPSecondaryAuthenticationProvider.php b/www/wiki/extensions/OATHAuth/includes/auth/TOTPSecondaryAuthenticationProvider.php
new file mode 100644
index 00000000..90d69cc3
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/auth/TOTPSecondaryAuthenticationProvider.php
@@ -0,0 +1,121 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+use MediaWiki\Auth\AbstractSecondaryAuthenticationProvider;
+use MediaWiki\Auth\AuthenticationRequest;
+use MediaWiki\Auth\AuthenticationResponse;
+use MediaWiki\Auth\AuthManager;
+
+/**
+ * AuthManager secondary authentication provider for TOTP second-factor authentication.
+ *
+ * After a successful primary authentication, requests a time-based one-time password
+ * (typically generated by a mobile app such as Google Authenticator) from the user.
+ *
+ * @see AuthManager
+ * @see https://en.wikipedia.org/wiki/Time-based_One-time_Password_Algorithm
+ */
+class TOTPSecondaryAuthenticationProvider extends AbstractSecondaryAuthenticationProvider {
+
+ /**
+ * @param string $action
+ * @param array $options
+ *
+ * @return array
+ */
+ public function getAuthenticationRequests( $action, array $options ) {
+ switch ( $action ) {
+ case AuthManager::ACTION_LOGIN:
+ // don't ask for anything initially so the second factor is on a separate screen
+ return [];
+ default:
+ return [];
+ }
+ }
+
+ /**
+ * If the user has enabled two-factor authentication, request a second factor.
+ *
+ * @param User $user
+ * @param array $reqs
+ *
+ * @return AuthenticationResponse
+ */
+ public function beginSecondaryAuthentication( $user, array $reqs ) {
+ $oathuser = OATHAuthHooks::getOATHUserRepository()->findByUser( $user );
+
+ if ( $oathuser->getKey() === null ) {
+ return AuthenticationResponse::newAbstain();
+ } else {
+ return AuthenticationResponse::newUI( [ new TOTPAuthenticationRequest() ],
+ wfMessage( 'oathauth-auth-ui' ), 'warning' );
+ }
+ }
+
+ /**
+ * Verify the second factor.
+ * @inheritDoc
+ */
+ public function continueSecondaryAuthentication( $user, array $reqs ) {
+ /** @var TOTPAuthenticationRequest $request */
+ $request = AuthenticationRequest::getRequestByClass( $reqs, TOTPAuthenticationRequest::class );
+ if ( !$request ) {
+ return AuthenticationResponse::newUI( [ new TOTPAuthenticationRequest() ],
+ wfMessage( 'oathauth-login-failed' ), 'error' );
+ }
+
+ $oathuser = OATHAuthHooks::getOATHUserRepository()->findByUser( $user );
+ /** @suppress PhanUndeclaredProperty */
+ $token = $request->OATHToken;
+
+ if ( $oathuser->getKey() === null ) {
+ $this->logger->warning( 'Two-factor authentication was disabled mid-authentication for '
+ . $user->getName() );
+ return AuthenticationResponse::newAbstain();
+ }
+
+ // Don't increase pingLimiter, just check for limit exceeded.
+ if ( $user->pingLimiter( 'badoath', 0 ) ) {
+ return AuthenticationResponse::newUI(
+ [ new TOTPAuthenticationRequest() ],
+ new Message(
+ 'oathauth-throttled',
+ // Arbitrary duration given here
+ [ Message::durationParam( 60 ) ]
+ ), 'error' );
+ }
+
+ if ( $oathuser->getKey()->verifyToken( $token, $oathuser ) ) {
+ return AuthenticationResponse::newPass();
+ } else {
+ return AuthenticationResponse::newUI( [ new TOTPAuthenticationRequest() ],
+ wfMessage( 'oathauth-login-failed' ), 'error' );
+ }
+ }
+
+ /**
+ * @param User $user
+ * @param User $creator
+ * @param array $reqs
+ *
+ * @return AuthenticationResponse
+ */
+ public function beginSecondaryAccountCreation( $user, $creator, array $reqs ) {
+ return AuthenticationResponse::newAbstain();
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/lib/base32.php b/www/wiki/extensions/OATHAuth/includes/lib/base32.php
new file mode 100644
index 00000000..d4ca1dff
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/lib/base32.php
@@ -0,0 +1,105 @@
+<?php
+/**
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * PHP Google two-factor authentication module.
+ *
+ * See http://www.idontplaydarts.com/2011/07/google-totp-two-factor-authentication-for-php/
+ * for more details
+ *
+ * @author Phil
+ **/
+
+class Base32 {
+
+ private static $lut = array(
+ "A" => 0, "B" => 1,
+ "C" => 2, "D" => 3,
+ "E" => 4, "F" => 5,
+ "G" => 6, "H" => 7,
+ "I" => 8, "J" => 9,
+ "K" => 10, "L" => 11,
+ "M" => 12, "N" => 13,
+ "O" => 14, "P" => 15,
+ "Q" => 16, "R" => 17,
+ "S" => 18, "T" => 19,
+ "U" => 20, "V" => 21,
+ "W" => 22, "X" => 23,
+ "Y" => 24, "Z" => 25,
+ "2" => 26, "3" => 27,
+ "4" => 28, "5" => 29,
+ "6" => 30, "7" => 31
+ );
+
+ /**
+ * Decodes a base32 string into a binary string according to RFC 4648.
+ **/
+ public static function decode($b32) {
+
+ $b32 = strtoupper($b32);
+
+ if (!preg_match('/^[ABCDEFGHIJKLMNOPQRSTUVWXYZ234567]+$/', $b32, $match))
+ throw new Exception('Invalid characters in the base32 string.');
+
+ $l = strlen($b32);
+ $n = 0;
+ $j = 0;
+ $binary = "";
+
+ for ($i = 0; $i < $l; $i++) {
+ // Move buffer left by 5 to make room
+ $n = $n << 5;
+ // Add value into buffer
+ $n = $n + self::$lut[$b32[$i]];
+ // Keep track of number of bits in buffer
+ $j = $j + 5;
+
+ if ($j >= 8) {
+ $j = $j - 8;
+ $binary .= chr(($n & (0xFF << $j)) >> $j);
+ }
+ }
+
+ return $binary;
+ }
+
+ /**
+ * Encodes a binary string into a base32 string according to RFC 4648 (no padding).
+ **/
+ public static function encode($string) {
+
+ if (empty($string))
+ throw new Exception('Empty string.');
+
+ $b32 = "";
+ $binary = "";
+
+ $bytes = str_split($string);
+ $length = count( $bytes );
+ for ($i = 0; $i < $length; $i++) {
+ $bits = base_convert(ord($bytes[$i]), 10, 2);
+ $binary .= str_pad($bits, 8, '0', STR_PAD_LEFT);
+ }
+
+ $map = array_keys(self::$lut);
+ $fivebits = str_split($binary, 5);
+ $length = count( $fivebits );
+ for ($i = 0; $i < $length; $i++) {
+ $dec = base_convert(str_pad($fivebits[$i], 5, '0'), 2, 10);
+ $b32 .= $map[$dec];
+ }
+
+ return $b32;
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/lib/hotp.php b/www/wiki/extensions/OATHAuth/includes/lib/hotp.php
new file mode 100644
index 00000000..8fd3d94b
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/lib/hotp.php
@@ -0,0 +1,179 @@
+<?php
+/**
+ * HOTP Class
+ * Based on the work of OAuth, and the sample implementation of HMAC OTP
+ * http://tools.ietf.org/html/draft-mraihi-oath-hmac-otp-04#appendix-D
+ * @author Jakob Heuser (firstname)@felocity.com
+ * @copyright 2011
+ * @license BSD-3-Clause
+ * @version 1.0
+ */
+class HOTP {
+ /**
+ * Generate a HOTP key based on a counter value (event based HOTP)
+ * @param string $key the key to use for hashing
+ * @param int $counter the number of attempts represented in this hashing
+ * @return HOTPResult a HOTP Result which can be truncated or output
+ */
+ public static function generateByCounter( $key, $counter ) {
+ // the counter value can be more than one byte long,
+ // so we need to pack it down properly.
+ $cur_counter = array( 0, 0, 0, 0, 0, 0, 0, 0 );
+ for ( $i = 7; $i >= 0; $i-- ) {
+ $cur_counter[$i] = pack( 'C*', $counter );
+ $counter = $counter >> 8;
+ }
+
+ $bin_counter = implode( $cur_counter );
+
+ // Pad to 8 chars
+ if ( strlen( $bin_counter ) < 8 ) {
+ $bin_counter = str_repeat( "\0", 8 - strlen( $bin_counter ) ) . $bin_counter;
+ }
+
+ // HMAC
+ $hash = hash_hmac( 'sha1', $bin_counter, $key );
+
+ return new HOTPResult( $hash );
+ }
+
+ /**
+ * Generate a HOTP key based on a timestamp and window size
+ *
+ * @param string $key the key to use for hashing
+ * @param int $window the size of the window a key is valid for in seconds
+ * @param int|bool $timestamp a timestamp to calculate for, defaults to time()
+ *
+ * @return HOTPResult a HOTP Result which can be truncated or output
+ */
+ public static function generateByTime( $key, $window, $timestamp = false ) {
+ if ( !$timestamp && $timestamp !== 0 ) {
+ $timestamp = HOTP::getTime();
+ }
+
+ $counter = (int)( $timestamp / $window );
+
+ return HOTP::generateByCounter( $key, $counter );
+ }
+
+ /**
+ * Generate a HOTP key collection based on a timestamp and window size
+ * all keys that could exist between a start and end time will be included
+ * in the returned array
+ *
+ * @param string $key the key to use for hashing
+ * @param int $window the size of the window a key is valid for in seconds
+ * @param int $min the minimum window to accept before $timestamp
+ * @param int $max the maximum window to accept after $timestamp
+ * @param int|bool $timestamp a timestamp to calculate for, defaults to time()
+ *
+ * @return HOTPResult[]
+ */
+ public static function generateByTimeWindow( $key, $window, $min = -1,
+ $max = 1, $timestamp = false
+ ) {
+ if ( !$timestamp && $timestamp !== 0 ) {
+ $timestamp = HOTP::getTime();
+ }
+
+ $counter = (int)( $timestamp / $window );
+ $window = range( $min, $max );
+
+ $out = array();
+ $length = count( $window );
+ for ( $i = 0; $i < $length; $i++ ) {
+ $shift_counter = $counter + $window[$i];
+ $out[$shift_counter] = HOTP::generateByCounter($key, $shift_counter);
+ }
+
+ return $out;
+ }
+
+ /**
+ * Gets the current time
+ * Ensures we are operating in UTC for the entire framework
+ * Restores the timezone on exit.
+ * @return int the current time
+ */
+ public static function getTime() {
+ return time(); // PHP's time is always UTC
+ }
+}
+
+/**
+ * The HOTPResult Class converts an HOTP item to various forms
+ * Supported formats include hex, decimal, string, and HOTP
+ * @author Jakob Heuser (firstname)@felocity.com
+ */
+class HOTPResult {
+ protected $hash;
+ protected $binary;
+ protected $decimal;
+ protected $hex;
+
+ /**
+ * Build an HOTP Result
+ * @param string $value the value to construct with
+ */
+ public function __construct( $value ) {
+ // store raw
+ $this->hash = $value;
+
+ // store calculate decimal
+ $hmac_result = array();
+
+ // Convert to decimal
+ foreach ( str_split( $this->hash, 2 ) as $hex ) {
+ $hmac_result[] = hexdec($hex);
+ }
+
+ $offset = $hmac_result[19] & 0xf;
+
+ $this->decimal = (
+ ( ( $hmac_result[$offset+0] & 0x7f ) << 24 ) |
+ ( ( $hmac_result[$offset+1] & 0xff ) << 16 ) |
+ ( ( $hmac_result[$offset+2] & 0xff ) << 8 ) |
+ ( $hmac_result[$offset+3] & 0xff )
+ );
+
+ // calculate hex
+ $this->hex = dechex( $this->decimal );
+ }
+
+ /**
+ * Returns the string version of the HOTP
+ * @return string
+ */
+ public function toString() {
+ return $this->hash;
+ }
+
+ /**
+ * Returns the hex version of the HOTP
+ * @return string
+ */
+ public function toHex() {
+ return $this->hex;
+ }
+
+ /**
+ * Returns the decimal version of the HOTP
+ * @return int
+ */
+ public function toDec() {
+ return $this->decimal;
+ }
+
+ /**
+ * Returns the truncated decimal form of the HOTP
+ * @param int $length the length of the HOTP to return
+ * @return string
+ */
+ public function toHOTP( $length ) {
+ $str = str_pad( $this->toDec(), $length, "0", STR_PAD_LEFT );
+ $str = substr( $str, ( -1 * $length ) );
+
+ return $str;
+ }
+
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/special/ProxySpecialPage.php b/www/wiki/extensions/OATHAuth/includes/special/ProxySpecialPage.php
new file mode 100644
index 00000000..bdb808f0
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/special/ProxySpecialPage.php
@@ -0,0 +1,227 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * A proxy class that routes a special page to other special pages based on
+ * request parameters
+ */
+abstract class ProxySpecialPage extends SpecialPage {
+ /**
+ * @var SpecialPage|null Target page to execute
+ */
+ private $target = null;
+
+ /**
+ * Instantiate a SpecialPage based on request parameters
+ *
+ * The page returned by this function will be cached and used as
+ * the target page for this proxy object.
+ *
+ * @return SpecialPage
+ */
+ abstract protected function getTargetPage();
+
+ /**
+ * Helper function that initializes the target SpecialPage object
+ */
+ private function init() {
+ if ( $this->target === null ) {
+ $this->target = $this->getTargetPage();
+ }
+ }
+
+ /**
+ * Magic function that proxies function calls to the target object
+ *
+ * @param string $method Method name being called
+ * @param array $args Array of arguments
+ *
+ * @return mixed
+ */
+ public function __call( $method, $args ) {
+ $this->init();
+ return call_user_func_array( [ $this->target, $method ], $args );
+ }
+
+ /**
+ * @return string
+ */
+ function getName() {
+ $this->init();
+ return $this->target->getName();
+ }
+
+ /**
+ * @param string|bool $subpage
+ * @return Title
+ */
+ function getPageTitle( $subpage = false ) {
+ $this->init();
+ return $this->target->getPageTitle( $subpage );
+ }
+
+ /**
+ * @return string
+ */
+ function getLocalName() {
+ $this->init();
+ return $this->target->getLocalName();
+ }
+
+ /**
+ * @return string
+ */
+ function getRestriction() {
+ $this->init();
+ return $this->target->getRestriction();
+ }
+
+ /**
+ * @return bool
+ */
+ function isListed() {
+ $this->init();
+ return $this->target->isListed();
+ }
+
+ /**
+ * @param bool $listed
+ * @return bool
+ */
+ function setListed( $listed ) {
+ $this->init();
+ return $this->target->setListed( $listed );
+ }
+
+ /**
+ * @param bool $x
+ * @return bool
+ */
+ function listed( $x = null ) {
+ $this->init();
+ return $this->target->listed( $x );
+ }
+
+ /**
+ * @return bool
+ */
+ public function isIncludable() {
+ $this->init();
+ return $this->target->isIncludable();
+ }
+
+ /**
+ * @param bool $x
+ * @return bool
+ */
+ function including( $x = null ) {
+ $this->init();
+ return $this->target->including( $x );
+ }
+
+ /**
+ * @return bool
+ */
+ public function isRestricted() {
+ $this->init();
+ return $this->target->isRestricted();
+ }
+
+ /**
+ * @param User $user
+ * @return bool
+ */
+ public function userCanExecute( User $user ) {
+ $this->init();
+ return $this->target->userCanExecute( $user );
+ }
+
+ /**
+ * @throws PermissionsError
+ */
+ function displayRestrictionError() {
+ $this->init();
+ $this->target->displayRestrictionError();
+ }
+
+ /**
+ * @return void
+ * @throws PermissionsError
+ */
+ public function checkPermissions() {
+ $this->init();
+ $this->target->checkPermissions();
+ }
+
+ /**
+ * @param string|null $subPage
+ */
+ protected function beforeExecute( $subPage ) {
+ $this->init();
+ $this->target->beforeExecute( $subPage );
+ }
+
+ /**
+ * @param string|null $subPage
+ */
+ protected function afterExecute( $subPage ) {
+ $this->init();
+ $this->target->afterExecute( $subPage );
+ }
+
+ /**
+ * @param string|null $subPage
+ */
+ public function execute( $subPage ) {
+ $this->init();
+ $this->target->execute( $subPage );
+ }
+
+ /**
+ * @return string
+ */
+ function getDescription() {
+ $this->init();
+ return $this->target->getDescription();
+ }
+
+ /**
+ * @param IContextSource $context
+ */
+ public function setContext( $context ) {
+ $this->init();
+ $this->target->setContext( $context );
+ parent::setContext( $context );
+ }
+
+ /**
+ * @return string
+ */
+ protected function getRobotPolicy() {
+ $this->init();
+ return $this->target->getRobotPolicy();
+ }
+
+ /**
+ * @return string
+ */
+ protected function getGroupName() {
+ $this->init();
+ return $this->target->getGroupName();
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/special/SpecialOATH.php b/www/wiki/extensions/OATHAuth/includes/special/SpecialOATH.php
new file mode 100644
index 00000000..21a854c2
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/special/SpecialOATH.php
@@ -0,0 +1,44 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Proxy page that redirects to the proper OATH special page
+ */
+class SpecialOATH extends ProxySpecialPage {
+ /**
+ * If the user already has OATH enabled, show them a page to disable
+ * If the user has OATH disabled, show them a page to enable
+ *
+ * @return SpecialOATHDisable|SpecialOATHEnable
+ */
+ protected function getTargetPage() {
+ $repo = OATHAuthHooks::getOATHUserRepository();
+
+ $user = $repo->findByUser( $this->getUser() );
+
+ if ( $user->getKey() === null ) {
+ return new SpecialOATHEnable( $repo, $user );
+ } else {
+ return new SpecialOATHDisable( $repo, $user );
+ }
+ }
+
+ protected function getGroupName() {
+ return 'oath';
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/special/SpecialOATHDisable.php b/www/wiki/extensions/OATHAuth/includes/special/SpecialOATHDisable.php
new file mode 100644
index 00000000..7e5758b9
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/special/SpecialOATHDisable.php
@@ -0,0 +1,136 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Special page to display key information to the user
+ *
+ * @ingroup Extensions
+ */
+class SpecialOATHDisable extends FormSpecialPage {
+ /** @var OATHUserRepository */
+ private $OATHRepository;
+
+ /** @var OATHUser */
+ private $OATHUser;
+
+ /**
+ * Initialize the OATH user based on the current local User object in the context
+ *
+ * @param OATHUserRepository $repository
+ * @param OATHUser $user
+ */
+ public function __construct( OATHUserRepository $repository, OATHUser $user ) {
+ parent::__construct( 'OATH', '', false );
+ $this->OATHRepository = $repository;
+ $this->OATHUser = $user;
+ }
+
+ public function doesWrites() {
+ return true;
+ }
+
+ /**
+ * Set the page title and add JavaScript RL modules
+ *
+ * @param HTMLForm $form
+ */
+ public function alterForm( HTMLForm $form ) {
+ $form->setMessagePrefix( 'oathauth' );
+ $form->setWrapperLegend( false );
+ $form->getOutput()->setPageTitle( $this->msg( 'oathauth-disable' ) );
+ }
+
+ /**
+ * @return string
+ */
+ protected function getDisplayFormat() {
+ return 'ooui';
+ }
+
+ /**
+ * @return bool
+ */
+ public function requiresUnblock() {
+ return false;
+ }
+
+ /**
+ * Require users to be logged in
+ *
+ * @param User $user
+ *
+ * @return bool|void
+ */
+ protected function checkExecutePermissions( User $user ) {
+ parent::checkExecutePermissions( $user );
+
+ $this->requireLogin();
+ }
+
+ /**
+ * @return array[]
+ */
+ protected function getFormFields() {
+ return [
+ 'token' => [
+ 'type' => 'text',
+ 'label-message' => 'oathauth-entertoken',
+ 'name' => 'token',
+ 'required' => true,
+ 'autofocus' => true,
+ ],
+ 'returnto' => [
+ 'type' => 'hidden',
+ 'default' => $this->getRequest()->getVal( 'returnto' ),
+ 'name' => 'returnto',
+ ],
+ 'returntoquery' => [
+ 'type' => 'hidden',
+ 'default' => $this->getRequest()->getVal( 'returntoquery' ),
+ 'name' => 'returntoquery',
+ ]
+ ];
+ }
+
+ /**
+ * @param array $formData
+ *
+ * @return array|bool
+ */
+ public function onSubmit( array $formData ) {
+ // Don't increase pingLimiter, just check for limit exceeded.
+ if ( $this->OATHUser->getUser()->pingLimiter( 'badoath', 0 ) ) {
+ // Arbitrary duration given here
+ return [ 'oathauth-throttled', Message::durationParam( 60 ) ];
+ }
+
+ if ( !$this->OATHUser->getKey()->verifyToken( $formData['token'], $this->OATHUser ) ) {
+ return [ 'oathauth-failedtovalidateoath' ];
+ }
+
+ $this->OATHUser->setKey( null );
+ $this->OATHRepository->remove( $this->OATHUser );
+
+ return true;
+ }
+
+ public function onSuccess() {
+ $this->getOutput()->addWikiMsg( 'oathauth-disabledoath' );
+ $this->getOutput()->returnToMain();
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/includes/special/SpecialOATHEnable.php b/www/wiki/extensions/OATHAuth/includes/special/SpecialOATHEnable.php
new file mode 100644
index 00000000..bf4b62e5
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/includes/special/SpecialOATHEnable.php
@@ -0,0 +1,241 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Special page to display key information to the user
+ *
+ * @ingroup Extensions
+ */
+class SpecialOATHEnable extends FormSpecialPage {
+ /** @var OATHUserRepository */
+ private $OATHRepository;
+
+ /** @var OATHUser */
+ private $OATHUser;
+
+ /**
+ * Initialize the OATH user based on the current local User object in the context
+ *
+ * @param OATHUserRepository $repository
+ * @param OATHUser $user
+ */
+ public function __construct( OATHUserRepository $repository, OATHUser $user ) {
+ parent::__construct( 'OATH', 'oathauth-enable', false );
+
+ $this->OATHRepository = $repository;
+ $this->OATHUser = $user;
+ }
+
+ public function doesWrites() {
+ return true;
+ }
+
+ /**
+ * Set the page title and add JavaScript RL modules
+ *
+ * @param HTMLForm $form
+ */
+ public function alterForm( HTMLForm $form ) {
+ $form->setMessagePrefix( 'oathauth' );
+ $form->setWrapperLegend( false );
+ $form->getOutput()->setPageTitle( $this->msg( 'oathauth-enable' ) );
+ $form->getOutput()->addModules( 'ext.oath.showqrcode' );
+ $form->getOutput()->addModuleStyles( 'ext.oath.showqrcode.styles' );
+ }
+
+ /**
+ * @return string
+ */
+ protected function getDisplayFormat() {
+ return 'ooui';
+ }
+
+ /**
+ * @return bool
+ */
+ public function requiresUnblock() {
+ return false;
+ }
+
+ /**
+ * Require users to be logged in
+ *
+ * @param User $user
+ *
+ * @return bool|void
+ */
+ protected function checkExecutePermissions( User $user ) {
+ parent::checkExecutePermissions( $user );
+
+ $this->requireLogin();
+ }
+
+ /**
+ * @return array[]
+ */
+ protected function getFormFields() {
+ $key = $this->getRequest()->getSessionData( 'oathauth_key' );
+
+ if ( $key === null ) {
+ $key = OATHAuthKey::newFromRandom();
+ $this->getRequest()->setSessionData( 'oathauth_key', $key );
+ }
+
+ $secret = $key->getSecret();
+ $label = "{$this->OATHUser->getIssuer()}:{$this->OATHUser->getAccount()}";
+ $qrcodeUrl = "otpauth://totp/"
+ . rawurlencode( $label )
+ . "?secret="
+ . rawurlencode( $secret )
+ . "&issuer="
+ . rawurlencode( $this->OATHUser->getIssuer() );
+
+ $qrcodeElement = Html::element( 'div', [
+ 'data-mw-qrcode-url' => $qrcodeUrl,
+ 'class' => 'mw-display-qrcode',
+ // Include width/height, so js won't re-arrange layout
+ // And non-js users will have this hidden with CSS
+ 'style' => 'width: 256px; height: 256px;'
+ ] );
+
+ return [
+ 'app' => [
+ 'type' => 'info',
+ 'default' => $this->msg( 'oathauth-step1-test' )->escaped(),
+ 'raw' => true,
+ 'section' => 'step1',
+ ],
+ 'qrcode' => [
+ 'type' => 'info',
+ 'default' => $qrcodeElement,
+ 'raw' => true,
+ 'section' => 'step2',
+ ],
+ 'manual' => [
+ 'type' => 'info',
+ 'label-message' => 'oathauth-step2alt',
+ 'default' =>
+ '<strong>' . $this->msg( 'oathauth-account' )->escaped() . '</strong><br/>'
+ . $this->OATHUser->getAccount() . '<br/><br/>'
+ . '<strong>' . $this->msg( 'oathauth-secret' )->escaped() . '</strong><br/>'
+ . '<kbd>' . $this->getSecretForDisplay( $key ) . '</kbd><br/>',
+ 'raw' => true,
+ 'section' => 'step2',
+ ],
+ 'scratchtokens' => [
+ 'type' => 'info',
+ 'default' =>
+ $this->msg( 'oathauth-scratchtokens' )
+ . $this->createResourceList( $this->getScratchTokensForDisplay( $key ) ),
+ 'raw' => true,
+ 'section' => 'step3',
+ ],
+ 'token' => [
+ 'type' => 'text',
+ 'default' => '',
+ 'label-message' => 'oathauth-entertoken',
+ 'name' => 'token',
+ 'section' => 'step4',
+ ],
+ 'returnto' => [
+ 'type' => 'hidden',
+ 'default' => $this->getRequest()->getVal( 'returnto' ),
+ 'name' => 'returnto',
+ ],
+ 'returntoquery' => [
+ 'type' => 'hidden',
+ 'default' => $this->getRequest()->getVal( 'returntoquery' ),
+ 'name' => 'returntoquery', ]
+ ];
+ }
+
+ /**
+ * @param array $formData
+ *
+ * @return array|bool
+ */
+ public function onSubmit( array $formData ) {
+ /** @var OATHAuthKey $key */
+ $key = $this->getRequest()->getSessionData( 'oathauth_key' );
+
+ if ( $key->isScratchToken( $formData['token'] ) ) {
+ // A scratch token is not allowed for enrollement
+ return [ 'oathauth-noscratchforvalidation' ];
+ }
+ if ( !$key->verifyToken( $formData['token'], $this->OATHUser ) ) {
+ return [ 'oathauth-failedtovalidateoath' ];
+ }
+
+ $this->getRequest()->setSessionData( 'oathauth_key', null );
+ $this->OATHUser->setKey( $key );
+ $this->OATHRepository->persist( $this->OATHUser );
+
+ return true;
+ }
+
+ public function onSuccess() {
+ $this->getOutput()->addWikiMsg( 'oathauth-validatedoath' );
+ $this->getOutput()->returnToMain();
+ }
+
+ /**
+ * @param $resources array
+ * @return string
+ */
+ private function createResourceList( $resources ) {
+ $resourceList = '';
+ foreach ( $resources as $resource ) {
+ $resourceList .= Html::rawElement( 'li', [], Html::rawElement( 'kbd', [], $resource ) );
+ }
+ return Html::rawElement( 'ul', [], $resourceList );
+ }
+
+ /**
+ * Retrieve the current secret for display purposes
+ *
+ * The characters of the token are split in groups of 4
+ *
+ * @param OATHAuthKey $key
+ * @return String
+ */
+ protected function getSecretForDisplay( OATHAuthKey $key ) {
+ return $this->tokenFormatterFunction( $key->getSecret() );
+ }
+
+ /**
+ * Retrieve current scratch tokens for display purposes
+ *
+ * The characters of the token are split in groups of 4
+ *
+ * @param OATHAuthKey $key
+ * @return string[]
+ */
+ protected function getScratchTokensForDisplay( OATHAuthKey $key ) {
+ return array_map( [ $this, 'tokenFormatterFunction' ], $key->getScratchTokens() );
+ }
+
+ /**
+ * Formats a key or scratch token by creating groups of 4 seperated by space characters
+ *
+ * @param string $token Token to format
+ * @return string The token formatted for display
+ */
+ private function tokenFormatterFunction( $token ) {
+ return implode( ' ', str_split( $token, 4 ) );
+ }
+}
diff --git a/www/wiki/extensions/OATHAuth/maintenance/disableOATHAuthForUser.php b/www/wiki/extensions/OATHAuth/maintenance/disableOATHAuthForUser.php
new file mode 100644
index 00000000..612f07d7
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/maintenance/disableOATHAuthForUser.php
@@ -0,0 +1,40 @@
+<?php
+
+if ( getenv( 'MW_INSTALL_PATH' ) ) {
+ $IP = getenv( 'MW_INSTALL_PATH' );
+} else {
+ $IP = __DIR__ . '/../../..';
+}
+require_once "$IP/maintenance/Maintenance.php";
+
+class DisableOATHAuthForUser extends Maintenance {
+ function __construct() {
+ parent::__construct();
+ $this->mDescription = 'Remove OATHAuth from a specific user';
+ $this->addArg( 'user', 'The username to remove OATHAuth from.' );
+ $this->requireExtension( 'OATHAuth' );
+ }
+
+ public function execute() {
+ $username = $this->getArg( 0 );
+
+ $user = User::newFromName( $username );
+ if ( $user && $user->getId() === 0 ) {
+ $this->error( "User $username doesn't exist!", 1 );
+ }
+
+ $repo = OATHAuthHooks::getOATHUserRepository();
+
+ $oathUser = $repo->findByUser( $user );
+
+ if ( $oathUser->getKey() === null ) {
+ $this->error( "User $username doesn't have OATHAuth enabled!", 1 );
+ }
+
+ $repo->remove( $oathUser );
+ $this->output( "OATHAuth disabled for $username.\n" );
+ }
+}
+
+$maintClass = "DisableOATHAuthForUser";
+require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/www/wiki/extensions/OATHAuth/maintenance/updateScratchTokenFormat.php b/www/wiki/extensions/OATHAuth/maintenance/updateScratchTokenFormat.php
new file mode 100644
index 00000000..81b4ea2d
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/maintenance/updateScratchTokenFormat.php
@@ -0,0 +1,51 @@
+<?php
+/**
+ * Update scratch_token column format
+ *
+ * Usage: php updateScratchTokenFormat.php
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @author Darian Anthony Patrick
+ * @ingroup Maintenance
+ */
+
+if ( getenv( 'MW_INSTALL_PATH' ) ) {
+ $IP = getenv( 'MW_INSTALL_PATH' );
+} else {
+ $IP = __DIR__ . '/../../..';
+}
+require_once "$IP/maintenance/Maintenance.php";
+
+class UpdateScratchTokenFormat extends Maintenance {
+ function __construct() {
+ parent::__construct();
+ $this->mDescription = 'Script to update scratch_token column format';
+ $this->requireExtension( 'OATHAuth' );
+ }
+
+ public function execute() {
+ $dbw = $this->getDB( DB_MASTER );
+ if ( !OATHAuthHooks::schemaUpdateOldUsers( $dbw ) ) {
+ $this->error( "Failed to update scratch_token rows.\n", 1 );
+ }
+ $this->output( "Done.\n" );
+ }
+}
+
+$maintClass = "UpdateScratchTokenFormat";
+require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.js b/www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.js
new file mode 100644
index 00000000..9c7d2b52
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.js
@@ -0,0 +1,6 @@
+(function ( $ ) {
+ $( function () {
+ var $elm = $( '.mw-display-qrcode' );
+ $elm.qrcode( $elm.data( 'mw-qrcode-url' ) );
+ } );
+} )( jQuery );
diff --git a/www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.styles.css b/www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.styles.css
new file mode 100644
index 00000000..0e2f48c4
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/modules/ext.oath.showqrcode.styles.css
@@ -0,0 +1,13 @@
+.client-nojs .mw-display-qrcode {
+ display: none;
+}
+
+kbd {
+ font-family: monospace, monospace;
+ white-space: nowrap;
+ font-size: larger;
+}
+
+fieldset {
+ page-break-inside: avoid;
+}
diff --git a/www/wiki/extensions/OATHAuth/modules/jquery.qrcode.js b/www/wiki/extensions/OATHAuth/modules/jquery.qrcode.js
new file mode 100644
index 00000000..15a1c663
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/modules/jquery.qrcode.js
@@ -0,0 +1,88 @@
+( function ( $ ) {
+ $.fn.qrcode = function ( options ) {
+ // if options is string,
+ if ( typeof options === 'string' ){
+ options = { text: options };
+ }
+
+ // set default values
+ // typeNumber < 1 for automatic calculation
+ options = $.extend( {}, {
+ render : "canvas",
+ width : 256,
+ height : 256,
+ typeNumber : -1,
+ correctLevel : QRErrorCorrectLevel.H,
+ background : "#ffffff",
+ foreground : "#000000"
+ }, options);
+
+ var createCanvas = function(){
+ // create the qrcode itself
+ var qrcode = new QRCode(options.typeNumber, options.correctLevel);
+ qrcode.addData(options.text);
+ qrcode.make();
+
+ // create canvas element
+ var canvas = document.createElement('canvas');
+ canvas.width = options.width;
+ canvas.height = options.height;
+ var ctx = canvas.getContext('2d');
+
+ // compute tileW/tileH based on options.width/options.height
+ var tileW = options.width / qrcode.getModuleCount();
+ var tileH = options.height / qrcode.getModuleCount();
+
+ // draw in the canvas
+ for( var row = 0; row < qrcode.getModuleCount(); row++ ){
+ for( var col = 0; col < qrcode.getModuleCount(); col++ ){
+ ctx.fillStyle = qrcode.isDark(row, col) ? options.foreground : options.background;
+ var w = (Math.ceil((col+1)*tileW) - Math.floor(col*tileW));
+ var h = (Math.ceil((row+1)*tileW) - Math.floor(row*tileW));
+ ctx.fillRect(Math.round(col*tileW),Math.round(row*tileH), w, h);
+ }
+ }
+ // return just built canvas
+ return canvas;
+ };
+
+ // from Jon-Carlos Rivera (https://github.com/imbcmdth)
+ var createTable = function(){
+ // create the qrcode itself
+ var qrcode = new QRCode(options.typeNumber, options.correctLevel);
+ qrcode.addData(options.text);
+ qrcode.make();
+
+ // create table element
+ var $table = $('<table></table>')
+ .css("width", options.width+"px")
+ .css("height", options.height+"px")
+ .css("border", "0px")
+ .css("border-collapse", "collapse")
+ .css('background-color', options.background);
+
+ // compute tileS percentage
+ var tileW = options.width / qrcode.getModuleCount();
+ var tileH = options.height / qrcode.getModuleCount();
+
+ // draw in the table
+ for(var row = 0; row < qrcode.getModuleCount(); row++ ){
+ var $row = $('<tr></tr>').css('height', tileH+"px").appendTo($table);
+
+ for(var col = 0; col < qrcode.getModuleCount(); col++ ){
+ $('<td></td>')
+ .css('width', tileW+"px")
+ .css('background-color', qrcode.isDark(row, col) ? options.foreground : options.background)
+ .appendTo($row);
+ }
+ }
+ // return just built canvas
+ return $table;
+ };
+
+ return this.each(function(){
+ var element = options.render === "canvas" ? createCanvas() : createTable();
+ $(element).appendTo(this);
+ } );
+ };
+}( jQuery ) );
diff --git a/www/wiki/extensions/OATHAuth/modules/qrcode.js b/www/wiki/extensions/OATHAuth/modules/qrcode.js
new file mode 100644
index 00000000..7775c90e
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/modules/qrcode.js
@@ -0,0 +1,1237 @@
+//---------------------------------------------------------------------
+// QRCode for JavaScript
+//
+// Copyright (c) 2009 Kazuhiko Arase
+//
+// URL: http://www.d-project.com/
+//
+// Licensed under the MIT license:
+// http://www.opensource.org/licenses/mit-license.php
+//
+// The word "QR Code" is registered trademark of
+// DENSO WAVE INCORPORATED
+// http://www.denso-wave.com/qrcode/faqpatent-e.html
+//
+//---------------------------------------------------------------------
+
+//---------------------------------------------------------------------
+// QR8bitByte
+//---------------------------------------------------------------------
+
+function QR8bitByte(data) {
+ this.mode = QRMode.MODE_8BIT_BYTE;
+ this.data = data;
+}
+
+QR8bitByte.prototype = {
+
+ getLength : function(buffer) {
+ return this.data.length;
+ },
+
+ write : function(buffer) {
+ for (var i = 0; i < this.data.length; i++) {
+ // not JIS ...
+ buffer.put(this.data.charCodeAt(i), 8);
+ }
+ }
+};
+
+//---------------------------------------------------------------------
+// QRCode
+//---------------------------------------------------------------------
+
+function QRCode(typeNumber, errorCorrectLevel) {
+ this.typeNumber = typeNumber;
+ this.errorCorrectLevel = errorCorrectLevel;
+ this.modules = null;
+ this.moduleCount = 0;
+ this.dataCache = null;
+ this.dataList = new Array();
+}
+
+QRCode.prototype = {
+
+ addData : function(data) {
+ var newData = new QR8bitByte(data);
+ this.dataList.push(newData);
+ this.dataCache = null;
+ },
+
+ isDark : function(row, col) {
+ if (row < 0 || this.moduleCount <= row || col < 0 || this.moduleCount <= col) {
+ throw new Error(row + "," + col);
+ }
+ return this.modules[row][col];
+ },
+
+ getModuleCount : function() {
+ return this.moduleCount;
+ },
+
+ make : function() {
+ // Calculate automatically typeNumber if provided is < 1
+ if (this.typeNumber < 1 ){
+ var typeNumber = 1;
+ for (typeNumber = 1; typeNumber < 40; typeNumber++) {
+ var rsBlocks = QRRSBlock.getRSBlocks(typeNumber, this.errorCorrectLevel);
+
+ var buffer = new QRBitBuffer();
+ var totalDataCount = 0;
+ for (var i = 0; i < rsBlocks.length; i++) {
+ totalDataCount += rsBlocks[i].dataCount;
+ }
+
+ for (var i = 0; i < this.dataList.length; i++) {
+ var data = this.dataList[i];
+ buffer.put(data.mode, 4);
+ buffer.put(data.getLength(), QRUtil.getLengthInBits(data.mode, typeNumber) );
+ data.write(buffer);
+ }
+ if (buffer.getLengthInBits() <= totalDataCount * 8)
+ break;
+ }
+ this.typeNumber = typeNumber;
+ }
+ this.makeImpl(false, this.getBestMaskPattern() );
+ },
+
+ makeImpl : function(test, maskPattern) {
+
+ this.moduleCount = this.typeNumber * 4 + 17;
+ this.modules = new Array(this.moduleCount);
+
+ for (var row = 0; row < this.moduleCount; row++) {
+
+ this.modules[row] = new Array(this.moduleCount);
+
+ for (var col = 0; col < this.moduleCount; col++) {
+ this.modules[row][col] = null;//(col + row) % 3;
+ }
+ }
+
+ this.setupPositionProbePattern(0, 0);
+ this.setupPositionProbePattern(this.moduleCount - 7, 0);
+ this.setupPositionProbePattern(0, this.moduleCount - 7);
+ this.setupPositionAdjustPattern();
+ this.setupTimingPattern();
+ this.setupTypeInfo(test, maskPattern);
+
+ if (this.typeNumber >= 7) {
+ this.setupTypeNumber(test);
+ }
+
+ if (this.dataCache == null) {
+ this.dataCache = QRCode.createData(this.typeNumber, this.errorCorrectLevel, this.dataList);
+ }
+
+ this.mapData(this.dataCache, maskPattern);
+ },
+
+ setupPositionProbePattern : function(row, col) {
+
+ for (var r = -1; r <= 7; r++) {
+
+ if (row + r <= -1 || this.moduleCount <= row + r) continue;
+
+ for (var c = -1; c <= 7; c++) {
+
+ if (col + c <= -1 || this.moduleCount <= col + c) continue;
+
+ if ( (0 <= r && r <= 6 && (c == 0 || c == 6) )
+ || (0 <= c && c <= 6 && (r == 0 || r == 6) )
+ || (2 <= r && r <= 4 && 2 <= c && c <= 4) ) {
+ this.modules[row + r][col + c] = true;
+ } else {
+ this.modules[row + r][col + c] = false;
+ }
+ }
+ }
+ },
+
+ getBestMaskPattern : function() {
+
+ var minLostPoint = 0;
+ var pattern = 0;
+
+ for (var i = 0; i < 8; i++) {
+
+ this.makeImpl(true, i);
+
+ var lostPoint = QRUtil.getLostPoint(this);
+
+ if (i == 0 || minLostPoint > lostPoint) {
+ minLostPoint = lostPoint;
+ pattern = i;
+ }
+ }
+
+ return pattern;
+ },
+
+ createMovieClip : function(target_mc, instance_name, depth) {
+
+ var qr_mc = target_mc.createEmptyMovieClip(instance_name, depth);
+ var cs = 1;
+
+ this.make();
+
+ for (var row = 0; row < this.modules.length; row++) {
+
+ var y = row * cs;
+
+ for (var col = 0; col < this.modules[row].length; col++) {
+
+ var x = col * cs;
+ var dark = this.modules[row][col];
+
+ if (dark) {
+ qr_mc.beginFill(0, 100);
+ qr_mc.moveTo(x, y);
+ qr_mc.lineTo(x + cs, y);
+ qr_mc.lineTo(x + cs, y + cs);
+ qr_mc.lineTo(x, y + cs);
+ qr_mc.endFill();
+ }
+ }
+ }
+
+ return qr_mc;
+ },
+
+ setupTimingPattern : function() {
+
+ for (var r = 8; r < this.moduleCount - 8; r++) {
+ if (this.modules[r][6] != null) {
+ continue;
+ }
+ this.modules[r][6] = (r % 2 == 0);
+ }
+
+ for (var c = 8; c < this.moduleCount - 8; c++) {
+ if (this.modules[6][c] != null) {
+ continue;
+ }
+ this.modules[6][c] = (c % 2 == 0);
+ }
+ },
+
+ setupPositionAdjustPattern : function() {
+
+ var pos = QRUtil.getPatternPosition(this.typeNumber);
+
+ for (var i = 0; i < pos.length; i++) {
+
+ for (var j = 0; j < pos.length; j++) {
+
+ var row = pos[i];
+ var col = pos[j];
+
+ if (this.modules[row][col] != null) {
+ continue;
+ }
+
+ for (var r = -2; r <= 2; r++) {
+
+ for (var c = -2; c <= 2; c++) {
+
+ if (r == -2 || r == 2 || c == -2 || c == 2
+ || (r == 0 && c == 0) ) {
+ this.modules[row + r][col + c] = true;
+ } else {
+ this.modules[row + r][col + c] = false;
+ }
+ }
+ }
+ }
+ }
+ },
+
+ setupTypeNumber : function(test) {
+
+ var bits = QRUtil.getBCHTypeNumber(this.typeNumber);
+
+ for (var i = 0; i < 18; i++) {
+ var mod = (!test && ( (bits >> i) & 1) == 1);
+ this.modules[Math.floor(i / 3)][i % 3 + this.moduleCount - 8 - 3] = mod;
+ }
+
+ for (var i = 0; i < 18; i++) {
+ var mod = (!test && ( (bits >> i) & 1) == 1);
+ this.modules[i % 3 + this.moduleCount - 8 - 3][Math.floor(i / 3)] = mod;
+ }
+ },
+
+ setupTypeInfo : function(test, maskPattern) {
+
+ var data = (this.errorCorrectLevel << 3) | maskPattern;
+ var bits = QRUtil.getBCHTypeInfo(data);
+
+ // vertical
+ for (var i = 0; i < 15; i++) {
+
+ var mod = (!test && ( (bits >> i) & 1) == 1);
+
+ if (i < 6) {
+ this.modules[i][8] = mod;
+ } else if (i < 8) {
+ this.modules[i + 1][8] = mod;
+ } else {
+ this.modules[this.moduleCount - 15 + i][8] = mod;
+ }
+ }
+
+ // horizontal
+ for (var i = 0; i < 15; i++) {
+
+ var mod = (!test && ( (bits >> i) & 1) == 1);
+
+ if (i < 8) {
+ this.modules[8][this.moduleCount - i - 1] = mod;
+ } else if (i < 9) {
+ this.modules[8][15 - i - 1 + 1] = mod;
+ } else {
+ this.modules[8][15 - i - 1] = mod;
+ }
+ }
+
+ // fixed module
+ this.modules[this.moduleCount - 8][8] = (!test);
+
+ },
+
+ mapData : function(data, maskPattern) {
+
+ var inc = -1;
+ var row = this.moduleCount - 1;
+ var bitIndex = 7;
+ var byteIndex = 0;
+
+ for (var col = this.moduleCount - 1; col > 0; col -= 2) {
+
+ if (col == 6) col--;
+
+ while (true) {
+
+ for (var c = 0; c < 2; c++) {
+
+ if (this.modules[row][col - c] == null) {
+
+ var dark = false;
+
+ if (byteIndex < data.length) {
+ dark = ( ( (data[byteIndex] >>> bitIndex) & 1) == 1);
+ }
+
+ var mask = QRUtil.getMask(maskPattern, row, col - c);
+
+ if (mask) {
+ dark = !dark;
+ }
+
+ this.modules[row][col - c] = dark;
+ bitIndex--;
+
+ if (bitIndex == -1) {
+ byteIndex++;
+ bitIndex = 7;
+ }
+ }
+ }
+
+ row += inc;
+
+ if (row < 0 || this.moduleCount <= row) {
+ row -= inc;
+ inc = -inc;
+ break;
+ }
+ }
+ }
+
+ }
+
+};
+
+QRCode.PAD0 = 0xEC;
+QRCode.PAD1 = 0x11;
+
+QRCode.createData = function(typeNumber, errorCorrectLevel, dataList) {
+
+ var rsBlocks = QRRSBlock.getRSBlocks(typeNumber, errorCorrectLevel);
+
+ var buffer = new QRBitBuffer();
+
+ for (var i = 0; i < dataList.length; i++) {
+ var data = dataList[i];
+ buffer.put(data.mode, 4);
+ buffer.put(data.getLength(), QRUtil.getLengthInBits(data.mode, typeNumber) );
+ data.write(buffer);
+ }
+
+ // calc num max data.
+ var totalDataCount = 0;
+ for (var i = 0; i < rsBlocks.length; i++) {
+ totalDataCount += rsBlocks[i].dataCount;
+ }
+
+ if (buffer.getLengthInBits() > totalDataCount * 8) {
+ throw new Error("code length overflow. ("
+ + buffer.getLengthInBits()
+ + ">"
+ + totalDataCount * 8
+ + ")");
+ }
+
+ // end code
+ if (buffer.getLengthInBits() + 4 <= totalDataCount * 8) {
+ buffer.put(0, 4);
+ }
+
+ // padding
+ while (buffer.getLengthInBits() % 8 != 0) {
+ buffer.putBit(false);
+ }
+
+ // padding
+ while (true) {
+
+ if (buffer.getLengthInBits() >= totalDataCount * 8) {
+ break;
+ }
+ buffer.put(QRCode.PAD0, 8);
+
+ if (buffer.getLengthInBits() >= totalDataCount * 8) {
+ break;
+ }
+ buffer.put(QRCode.PAD1, 8);
+ }
+
+ return QRCode.createBytes(buffer, rsBlocks);
+}
+
+QRCode.createBytes = function(buffer, rsBlocks) {
+
+ var offset = 0;
+
+ var maxDcCount = 0;
+ var maxEcCount = 0;
+
+ var dcdata = new Array(rsBlocks.length);
+ var ecdata = new Array(rsBlocks.length);
+
+ for (var r = 0; r < rsBlocks.length; r++) {
+
+ var dcCount = rsBlocks[r].dataCount;
+ var ecCount = rsBlocks[r].totalCount - dcCount;
+
+ maxDcCount = Math.max(maxDcCount, dcCount);
+ maxEcCount = Math.max(maxEcCount, ecCount);
+
+ dcdata[r] = new Array(dcCount);
+
+ for (var i = 0; i < dcdata[r].length; i++) {
+ dcdata[r][i] = 0xff & buffer.buffer[i + offset];
+ }
+ offset += dcCount;
+
+ var rsPoly = QRUtil.getErrorCorrectPolynomial(ecCount);
+ var rawPoly = new QRPolynomial(dcdata[r], rsPoly.getLength() - 1);
+
+ var modPoly = rawPoly.mod(rsPoly);
+ ecdata[r] = new Array(rsPoly.getLength() - 1);
+ for (var i = 0; i < ecdata[r].length; i++) {
+ var modIndex = i + modPoly.getLength() - ecdata[r].length;
+ ecdata[r][i] = (modIndex >= 0)? modPoly.get(modIndex) : 0;
+ }
+
+ }
+
+ var totalCodeCount = 0;
+ for (var i = 0; i < rsBlocks.length; i++) {
+ totalCodeCount += rsBlocks[i].totalCount;
+ }
+
+ var data = new Array(totalCodeCount);
+ var index = 0;
+
+ for (var i = 0; i < maxDcCount; i++) {
+ for (var r = 0; r < rsBlocks.length; r++) {
+ if (i < dcdata[r].length) {
+ data[index++] = dcdata[r][i];
+ }
+ }
+ }
+
+ for (var i = 0; i < maxEcCount; i++) {
+ for (var r = 0; r < rsBlocks.length; r++) {
+ if (i < ecdata[r].length) {
+ data[index++] = ecdata[r][i];
+ }
+ }
+ }
+
+ return data;
+
+}
+
+//---------------------------------------------------------------------
+// QRMode
+//---------------------------------------------------------------------
+
+var QRMode = {
+ MODE_NUMBER : 1 << 0,
+ MODE_ALPHA_NUM : 1 << 1,
+ MODE_8BIT_BYTE : 1 << 2,
+ MODE_KANJI : 1 << 3
+};
+
+//---------------------------------------------------------------------
+// QRErrorCorrectLevel
+//---------------------------------------------------------------------
+
+var QRErrorCorrectLevel = {
+ L : 1,
+ M : 0,
+ Q : 3,
+ H : 2
+};
+
+//---------------------------------------------------------------------
+// QRMaskPattern
+//---------------------------------------------------------------------
+
+var QRMaskPattern = {
+ PATTERN000 : 0,
+ PATTERN001 : 1,
+ PATTERN010 : 2,
+ PATTERN011 : 3,
+ PATTERN100 : 4,
+ PATTERN101 : 5,
+ PATTERN110 : 6,
+ PATTERN111 : 7
+};
+
+//---------------------------------------------------------------------
+// QRUtil
+//---------------------------------------------------------------------
+
+var QRUtil = {
+
+ PATTERN_POSITION_TABLE : [
+ [],
+ [6, 18],
+ [6, 22],
+ [6, 26],
+ [6, 30],
+ [6, 34],
+ [6, 22, 38],
+ [6, 24, 42],
+ [6, 26, 46],
+ [6, 28, 50],
+ [6, 30, 54],
+ [6, 32, 58],
+ [6, 34, 62],
+ [6, 26, 46, 66],
+ [6, 26, 48, 70],
+ [6, 26, 50, 74],
+ [6, 30, 54, 78],
+ [6, 30, 56, 82],
+ [6, 30, 58, 86],
+ [6, 34, 62, 90],
+ [6, 28, 50, 72, 94],
+ [6, 26, 50, 74, 98],
+ [6, 30, 54, 78, 102],
+ [6, 28, 54, 80, 106],
+ [6, 32, 58, 84, 110],
+ [6, 30, 58, 86, 114],
+ [6, 34, 62, 90, 118],
+ [6, 26, 50, 74, 98, 122],
+ [6, 30, 54, 78, 102, 126],
+ [6, 26, 52, 78, 104, 130],
+ [6, 30, 56, 82, 108, 134],
+ [6, 34, 60, 86, 112, 138],
+ [6, 30, 58, 86, 114, 142],
+ [6, 34, 62, 90, 118, 146],
+ [6, 30, 54, 78, 102, 126, 150],
+ [6, 24, 50, 76, 102, 128, 154],
+ [6, 28, 54, 80, 106, 132, 158],
+ [6, 32, 58, 84, 110, 136, 162],
+ [6, 26, 54, 82, 110, 138, 166],
+ [6, 30, 58, 86, 114, 142, 170]
+ ],
+
+ G15 : (1 << 10) | (1 << 8) | (1 << 5) | (1 << 4) | (1 << 2) | (1 << 1) | (1 << 0),
+ G18 : (1 << 12) | (1 << 11) | (1 << 10) | (1 << 9) | (1 << 8) | (1 << 5) | (1 << 2) | (1 << 0),
+ G15_MASK : (1 << 14) | (1 << 12) | (1 << 10) | (1 << 4) | (1 << 1),
+
+ getBCHTypeInfo : function(data) {
+ var d = data << 10;
+ while (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G15) >= 0) {
+ d ^= (QRUtil.G15 << (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G15) ) );
+ }
+ return ( (data << 10) | d) ^ QRUtil.G15_MASK;
+ },
+
+ getBCHTypeNumber : function(data) {
+ var d = data << 12;
+ while (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G18) >= 0) {
+ d ^= (QRUtil.G18 << (QRUtil.getBCHDigit(d) - QRUtil.getBCHDigit(QRUtil.G18) ) );
+ }
+ return (data << 12) | d;
+ },
+
+ getBCHDigit : function(data) {
+
+ var digit = 0;
+
+ while (data != 0) {
+ digit++;
+ data >>>= 1;
+ }
+
+ return digit;
+ },
+
+ getPatternPosition : function(typeNumber) {
+ return QRUtil.PATTERN_POSITION_TABLE[typeNumber - 1];
+ },
+
+ getMask : function(maskPattern, i, j) {
+
+ switch (maskPattern) {
+
+ case QRMaskPattern.PATTERN000 : return (i + j) % 2 == 0;
+ case QRMaskPattern.PATTERN001 : return i % 2 == 0;
+ case QRMaskPattern.PATTERN010 : return j % 3 == 0;
+ case QRMaskPattern.PATTERN011 : return (i + j) % 3 == 0;
+ case QRMaskPattern.PATTERN100 : return (Math.floor(i / 2) + Math.floor(j / 3) ) % 2 == 0;
+ case QRMaskPattern.PATTERN101 : return (i * j) % 2 + (i * j) % 3 == 0;
+ case QRMaskPattern.PATTERN110 : return ( (i * j) % 2 + (i * j) % 3) % 2 == 0;
+ case QRMaskPattern.PATTERN111 : return ( (i * j) % 3 + (i + j) % 2) % 2 == 0;
+
+ default :
+ throw new Error("bad maskPattern:" + maskPattern);
+ }
+ },
+
+ getErrorCorrectPolynomial : function(errorCorrectLength) {
+
+ var a = new QRPolynomial([1], 0);
+
+ for (var i = 0; i < errorCorrectLength; i++) {
+ a = a.multiply(new QRPolynomial([1, QRMath.gexp(i)], 0) );
+ }
+
+ return a;
+ },
+
+ getLengthInBits : function(mode, type) {
+
+ if (1 <= type && type < 10) {
+
+ // 1 - 9
+
+ switch(mode) {
+ case QRMode.MODE_NUMBER : return 10;
+ case QRMode.MODE_ALPHA_NUM : return 9;
+ case QRMode.MODE_8BIT_BYTE : return 8;
+ case QRMode.MODE_KANJI : return 8;
+ default :
+ throw new Error("mode:" + mode);
+ }
+
+ } else if (type < 27) {
+
+ // 10 - 26
+
+ switch(mode) {
+ case QRMode.MODE_NUMBER : return 12;
+ case QRMode.MODE_ALPHA_NUM : return 11;
+ case QRMode.MODE_8BIT_BYTE : return 16;
+ case QRMode.MODE_KANJI : return 10;
+ default :
+ throw new Error("mode:" + mode);
+ }
+
+ } else if (type < 41) {
+
+ // 27 - 40
+
+ switch(mode) {
+ case QRMode.MODE_NUMBER : return 14;
+ case QRMode.MODE_ALPHA_NUM : return 13;
+ case QRMode.MODE_8BIT_BYTE : return 16;
+ case QRMode.MODE_KANJI : return 12;
+ default :
+ throw new Error("mode:" + mode);
+ }
+
+ } else {
+ throw new Error("type:" + type);
+ }
+ },
+
+ getLostPoint : function(qrCode) {
+
+ var moduleCount = qrCode.getModuleCount();
+
+ var lostPoint = 0;
+
+ // LEVEL1
+
+ for (var row = 0; row < moduleCount; row++) {
+
+ for (var col = 0; col < moduleCount; col++) {
+
+ var sameCount = 0;
+ var dark = qrCode.isDark(row, col);
+
+ for (var r = -1; r <= 1; r++) {
+
+ if (row + r < 0 || moduleCount <= row + r) {
+ continue;
+ }
+
+ for (var c = -1; c <= 1; c++) {
+
+ if (col + c < 0 || moduleCount <= col + c) {
+ continue;
+ }
+
+ if (r == 0 && c == 0) {
+ continue;
+ }
+
+ if (dark == qrCode.isDark(row + r, col + c) ) {
+ sameCount++;
+ }
+ }
+ }
+
+ if (sameCount > 5) {
+ lostPoint += (3 + sameCount - 5);
+ }
+ }
+ }
+
+ // LEVEL2
+
+ for (var row = 0; row < moduleCount - 1; row++) {
+ for (var col = 0; col < moduleCount - 1; col++) {
+ var count = 0;
+ if (qrCode.isDark(row, col ) ) count++;
+ if (qrCode.isDark(row + 1, col ) ) count++;
+ if (qrCode.isDark(row, col + 1) ) count++;
+ if (qrCode.isDark(row + 1, col + 1) ) count++;
+ if (count == 0 || count == 4) {
+ lostPoint += 3;
+ }
+ }
+ }
+
+ // LEVEL3
+
+ for (var row = 0; row < moduleCount; row++) {
+ for (var col = 0; col < moduleCount - 6; col++) {
+ if (qrCode.isDark(row, col)
+ && !qrCode.isDark(row, col + 1)
+ && qrCode.isDark(row, col + 2)
+ && qrCode.isDark(row, col + 3)
+ && qrCode.isDark(row, col + 4)
+ && !qrCode.isDark(row, col + 5)
+ && qrCode.isDark(row, col + 6) ) {
+ lostPoint += 40;
+ }
+ }
+ }
+
+ for (var col = 0; col < moduleCount; col++) {
+ for (var row = 0; row < moduleCount - 6; row++) {
+ if (qrCode.isDark(row, col)
+ && !qrCode.isDark(row + 1, col)
+ && qrCode.isDark(row + 2, col)
+ && qrCode.isDark(row + 3, col)
+ && qrCode.isDark(row + 4, col)
+ && !qrCode.isDark(row + 5, col)
+ && qrCode.isDark(row + 6, col) ) {
+ lostPoint += 40;
+ }
+ }
+ }
+
+ // LEVEL4
+
+ var darkCount = 0;
+
+ for (var col = 0; col < moduleCount; col++) {
+ for (var row = 0; row < moduleCount; row++) {
+ if (qrCode.isDark(row, col) ) {
+ darkCount++;
+ }
+ }
+ }
+
+ var ratio = Math.abs(100 * darkCount / moduleCount / moduleCount - 50) / 5;
+ lostPoint += ratio * 10;
+
+ return lostPoint;
+ }
+
+};
+
+
+//---------------------------------------------------------------------
+// QRMath
+//---------------------------------------------------------------------
+
+var QRMath = {
+
+ glog : function(n) {
+
+ if (n < 1) {
+ throw new Error("glog(" + n + ")");
+ }
+
+ return QRMath.LOG_TABLE[n];
+ },
+
+ gexp : function(n) {
+
+ while (n < 0) {
+ n += 255;
+ }
+
+ while (n >= 256) {
+ n -= 255;
+ }
+
+ return QRMath.EXP_TABLE[n];
+ },
+
+ EXP_TABLE : new Array(256),
+
+ LOG_TABLE : new Array(256)
+
+};
+
+for (var i = 0; i < 8; i++) {
+ QRMath.EXP_TABLE[i] = 1 << i;
+}
+for (var i = 8; i < 256; i++) {
+ QRMath.EXP_TABLE[i] = QRMath.EXP_TABLE[i - 4]
+ ^ QRMath.EXP_TABLE[i - 5]
+ ^ QRMath.EXP_TABLE[i - 6]
+ ^ QRMath.EXP_TABLE[i - 8];
+}
+for (var i = 0; i < 255; i++) {
+ QRMath.LOG_TABLE[QRMath.EXP_TABLE[i] ] = i;
+}
+
+//---------------------------------------------------------------------
+// QRPolynomial
+//---------------------------------------------------------------------
+
+function QRPolynomial(num, shift) {
+
+ if (num.length == undefined) {
+ throw new Error(num.length + "/" + shift);
+ }
+
+ var offset = 0;
+
+ while (offset < num.length && num[offset] == 0) {
+ offset++;
+ }
+
+ this.num = new Array(num.length - offset + shift);
+ for (var i = 0; i < num.length - offset; i++) {
+ this.num[i] = num[i + offset];
+ }
+}
+
+QRPolynomial.prototype = {
+
+ get : function(index) {
+ return this.num[index];
+ },
+
+ getLength : function() {
+ return this.num.length;
+ },
+
+ multiply : function(e) {
+
+ var num = new Array(this.getLength() + e.getLength() - 1);
+
+ for (var i = 0; i < this.getLength(); i++) {
+ for (var j = 0; j < e.getLength(); j++) {
+ num[i + j] ^= QRMath.gexp(QRMath.glog(this.get(i) ) + QRMath.glog(e.get(j) ) );
+ }
+ }
+
+ return new QRPolynomial(num, 0);
+ },
+
+ mod : function(e) {
+
+ if (this.getLength() - e.getLength() < 0) {
+ return this;
+ }
+
+ var ratio = QRMath.glog(this.get(0) ) - QRMath.glog(e.get(0) );
+
+ var num = new Array(this.getLength() );
+
+ for (var i = 0; i < this.getLength(); i++) {
+ num[i] = this.get(i);
+ }
+
+ for (var i = 0; i < e.getLength(); i++) {
+ num[i] ^= QRMath.gexp(QRMath.glog(e.get(i) ) + ratio);
+ }
+
+ // recursive call
+ return new QRPolynomial(num, 0).mod(e);
+ }
+};
+
+//---------------------------------------------------------------------
+// QRRSBlock
+//---------------------------------------------------------------------
+
+function QRRSBlock(totalCount, dataCount) {
+ this.totalCount = totalCount;
+ this.dataCount = dataCount;
+}
+
+QRRSBlock.RS_BLOCK_TABLE = [
+
+ // L
+ // M
+ // Q
+ // H
+
+ // 1
+ [1, 26, 19],
+ [1, 26, 16],
+ [1, 26, 13],
+ [1, 26, 9],
+
+ // 2
+ [1, 44, 34],
+ [1, 44, 28],
+ [1, 44, 22],
+ [1, 44, 16],
+
+ // 3
+ [1, 70, 55],
+ [1, 70, 44],
+ [2, 35, 17],
+ [2, 35, 13],
+
+ // 4
+ [1, 100, 80],
+ [2, 50, 32],
+ [2, 50, 24],
+ [4, 25, 9],
+
+ // 5
+ [1, 134, 108],
+ [2, 67, 43],
+ [2, 33, 15, 2, 34, 16],
+ [2, 33, 11, 2, 34, 12],
+
+ // 6
+ [2, 86, 68],
+ [4, 43, 27],
+ [4, 43, 19],
+ [4, 43, 15],
+
+ // 7
+ [2, 98, 78],
+ [4, 49, 31],
+ [2, 32, 14, 4, 33, 15],
+ [4, 39, 13, 1, 40, 14],
+
+ // 8
+ [2, 121, 97],
+ [2, 60, 38, 2, 61, 39],
+ [4, 40, 18, 2, 41, 19],
+ [4, 40, 14, 2, 41, 15],
+
+ // 9
+ [2, 146, 116],
+ [3, 58, 36, 2, 59, 37],
+ [4, 36, 16, 4, 37, 17],
+ [4, 36, 12, 4, 37, 13],
+
+ // 10
+ [2, 86, 68, 2, 87, 69],
+ [4, 69, 43, 1, 70, 44],
+ [6, 43, 19, 2, 44, 20],
+ [6, 43, 15, 2, 44, 16],
+
+ // 11
+ [4, 101, 81],
+ [1, 80, 50, 4, 81, 51],
+ [4, 50, 22, 4, 51, 23],
+ [3, 36, 12, 8, 37, 13],
+
+ // 12
+ [2, 116, 92, 2, 117, 93],
+ [6, 58, 36, 2, 59, 37],
+ [4, 46, 20, 6, 47, 21],
+ [7, 42, 14, 4, 43, 15],
+
+ // 13
+ [4, 133, 107],
+ [8, 59, 37, 1, 60, 38],
+ [8, 44, 20, 4, 45, 21],
+ [12, 33, 11, 4, 34, 12],
+
+ // 14
+ [3, 145, 115, 1, 146, 116],
+ [4, 64, 40, 5, 65, 41],
+ [11, 36, 16, 5, 37, 17],
+ [11, 36, 12, 5, 37, 13],
+
+ // 15
+ [5, 109, 87, 1, 110, 88],
+ [5, 65, 41, 5, 66, 42],
+ [5, 54, 24, 7, 55, 25],
+ [11, 36, 12],
+
+ // 16
+ [5, 122, 98, 1, 123, 99],
+ [7, 73, 45, 3, 74, 46],
+ [15, 43, 19, 2, 44, 20],
+ [3, 45, 15, 13, 46, 16],
+
+ // 17
+ [1, 135, 107, 5, 136, 108],
+ [10, 74, 46, 1, 75, 47],
+ [1, 50, 22, 15, 51, 23],
+ [2, 42, 14, 17, 43, 15],
+
+ // 18
+ [5, 150, 120, 1, 151, 121],
+ [9, 69, 43, 4, 70, 44],
+ [17, 50, 22, 1, 51, 23],
+ [2, 42, 14, 19, 43, 15],
+
+ // 19
+ [3, 141, 113, 4, 142, 114],
+ [3, 70, 44, 11, 71, 45],
+ [17, 47, 21, 4, 48, 22],
+ [9, 39, 13, 16, 40, 14],
+
+ // 20
+ [3, 135, 107, 5, 136, 108],
+ [3, 67, 41, 13, 68, 42],
+ [15, 54, 24, 5, 55, 25],
+ [15, 43, 15, 10, 44, 16],
+
+ // 21
+ [4, 144, 116, 4, 145, 117],
+ [17, 68, 42],
+ [17, 50, 22, 6, 51, 23],
+ [19, 46, 16, 6, 47, 17],
+
+ // 22
+ [2, 139, 111, 7, 140, 112],
+ [17, 74, 46],
+ [7, 54, 24, 16, 55, 25],
+ [34, 37, 13],
+
+ // 23
+ [4, 151, 121, 5, 152, 122],
+ [4, 75, 47, 14, 76, 48],
+ [11, 54, 24, 14, 55, 25],
+ [16, 45, 15, 14, 46, 16],
+
+ // 24
+ [6, 147, 117, 4, 148, 118],
+ [6, 73, 45, 14, 74, 46],
+ [11, 54, 24, 16, 55, 25],
+ [30, 46, 16, 2, 47, 17],
+
+ // 25
+ [8, 132, 106, 4, 133, 107],
+ [8, 75, 47, 13, 76, 48],
+ [7, 54, 24, 22, 55, 25],
+ [22, 45, 15, 13, 46, 16],
+
+ // 26
+ [10, 142, 114, 2, 143, 115],
+ [19, 74, 46, 4, 75, 47],
+ [28, 50, 22, 6, 51, 23],
+ [33, 46, 16, 4, 47, 17],
+
+ // 27
+ [8, 152, 122, 4, 153, 123],
+ [22, 73, 45, 3, 74, 46],
+ [8, 53, 23, 26, 54, 24],
+ [12, 45, 15, 28, 46, 16],
+
+ // 28
+ [3, 147, 117, 10, 148, 118],
+ [3, 73, 45, 23, 74, 46],
+ [4, 54, 24, 31, 55, 25],
+ [11, 45, 15, 31, 46, 16],
+
+ // 29
+ [7, 146, 116, 7, 147, 117],
+ [21, 73, 45, 7, 74, 46],
+ [1, 53, 23, 37, 54, 24],
+ [19, 45, 15, 26, 46, 16],
+
+ // 30
+ [5, 145, 115, 10, 146, 116],
+ [19, 75, 47, 10, 76, 48],
+ [15, 54, 24, 25, 55, 25],
+ [23, 45, 15, 25, 46, 16],
+
+ // 31
+ [13, 145, 115, 3, 146, 116],
+ [2, 74, 46, 29, 75, 47],
+ [42, 54, 24, 1, 55, 25],
+ [23, 45, 15, 28, 46, 16],
+
+ // 32
+ [17, 145, 115],
+ [10, 74, 46, 23, 75, 47],
+ [10, 54, 24, 35, 55, 25],
+ [19, 45, 15, 35, 46, 16],
+
+ // 33
+ [17, 145, 115, 1, 146, 116],
+ [14, 74, 46, 21, 75, 47],
+ [29, 54, 24, 19, 55, 25],
+ [11, 45, 15, 46, 46, 16],
+
+ // 34
+ [13, 145, 115, 6, 146, 116],
+ [14, 74, 46, 23, 75, 47],
+ [44, 54, 24, 7, 55, 25],
+ [59, 46, 16, 1, 47, 17],
+
+ // 35
+ [12, 151, 121, 7, 152, 122],
+ [12, 75, 47, 26, 76, 48],
+ [39, 54, 24, 14, 55, 25],
+ [22, 45, 15, 41, 46, 16],
+
+ // 36
+ [6, 151, 121, 14, 152, 122],
+ [6, 75, 47, 34, 76, 48],
+ [46, 54, 24, 10, 55, 25],
+ [2, 45, 15, 64, 46, 16],
+
+ // 37
+ [17, 152, 122, 4, 153, 123],
+ [29, 74, 46, 14, 75, 47],
+ [49, 54, 24, 10, 55, 25],
+ [24, 45, 15, 46, 46, 16],
+
+ // 38
+ [4, 152, 122, 18, 153, 123],
+ [13, 74, 46, 32, 75, 47],
+ [48, 54, 24, 14, 55, 25],
+ [42, 45, 15, 32, 46, 16],
+
+ // 39
+ [20, 147, 117, 4, 148, 118],
+ [40, 75, 47, 7, 76, 48],
+ [43, 54, 24, 22, 55, 25],
+ [10, 45, 15, 67, 46, 16],
+
+ // 40
+ [19, 148, 118, 6, 149, 119],
+ [18, 75, 47, 31, 76, 48],
+ [34, 54, 24, 34, 55, 25],
+ [20, 45, 15, 61, 46, 16]
+];
+
+QRRSBlock.getRSBlocks = function(typeNumber, errorCorrectLevel) {
+
+ var rsBlock = QRRSBlock.getRsBlockTable(typeNumber, errorCorrectLevel);
+
+ if (rsBlock == undefined) {
+ throw new Error("bad rs block @ typeNumber:" + typeNumber + "/errorCorrectLevel:" + errorCorrectLevel);
+ }
+
+ var length = rsBlock.length / 3;
+
+ var list = new Array();
+
+ for (var i = 0; i < length; i++) {
+
+ var count = rsBlock[i * 3 + 0];
+ var totalCount = rsBlock[i * 3 + 1];
+ var dataCount = rsBlock[i * 3 + 2];
+
+ for (var j = 0; j < count; j++) {
+ list.push(new QRRSBlock(totalCount, dataCount) );
+ }
+ }
+
+ return list;
+}
+
+QRRSBlock.getRsBlockTable = function(typeNumber, errorCorrectLevel) {
+
+ switch(errorCorrectLevel) {
+ case QRErrorCorrectLevel.L :
+ return QRRSBlock.RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 0];
+ case QRErrorCorrectLevel.M :
+ return QRRSBlock.RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 1];
+ case QRErrorCorrectLevel.Q :
+ return QRRSBlock.RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 2];
+ case QRErrorCorrectLevel.H :
+ return QRRSBlock.RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 3];
+ default :
+ return undefined;
+ }
+}
+
+//---------------------------------------------------------------------
+// QRBitBuffer
+//---------------------------------------------------------------------
+
+function QRBitBuffer() {
+ this.buffer = new Array();
+ this.length = 0;
+}
+
+QRBitBuffer.prototype = {
+
+ get : function(index) {
+ var bufIndex = Math.floor(index / 8);
+ return ( (this.buffer[bufIndex] >>> (7 - index % 8) ) & 1) == 1;
+ },
+
+ put : function(num, length) {
+ for (var i = 0; i < length; i++) {
+ this.putBit( ( (num >>> (length - i - 1) ) & 1) == 1);
+ }
+ },
+
+ getLengthInBits : function() {
+ return this.length;
+ },
+
+ putBit : function(bit) {
+
+ var bufIndex = Math.floor(this.length / 8);
+ if (this.buffer.length <= bufIndex) {
+ this.buffer.push(0);
+ }
+
+ if (bit) {
+ this.buffer[bufIndex] |= (0x80 >>> (this.length % 8) );
+ }
+
+ this.length++;
+ }
+};
diff --git a/www/wiki/extensions/OATHAuth/sql/mssql/tables.sql b/www/wiki/extensions/OATHAuth/sql/mssql/tables.sql
new file mode 100644
index 00000000..f4db281c
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/sql/mssql/tables.sql
@@ -0,0 +1,10 @@
+CREATE TABLE /*_*/oathauth_users (
+ -- User ID
+ id INT NOT NULL PRIMARY KEY IDENTITY(0,1),
+
+ -- Secret key
+ secret NVARCHAR(255) NULL DEFAULT NULL,
+
+ -- Scratch tokens
+ scratch_tokens varbinary(511) NULL DEFAULT NULL
+);
diff --git a/www/wiki/extensions/OATHAuth/sql/mysql/patch-remove_reset.sql b/www/wiki/extensions/OATHAuth/sql/mysql/patch-remove_reset.sql
new file mode 100644
index 00000000..6b37a344
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/sql/mysql/patch-remove_reset.sql
@@ -0,0 +1,8 @@
+ALTER TABLE /*_*/oathauth_users
+ DROP COLUMN secret_reset;
+
+ALTER TABLE /*_*/oathauth_users
+ DROP COLUMN scratch_tokens_reset;
+
+ALTER TABLE /*_*/oathauth_users
+ DROP COLUMN is_validated;
diff --git a/www/wiki/extensions/OATHAuth/sql/mysql/tables.sql b/www/wiki/extensions/OATHAuth/sql/mysql/tables.sql
new file mode 100644
index 00000000..1d531f04
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/sql/mysql/tables.sql
@@ -0,0 +1,11 @@
+CREATE TABLE /*_*/oathauth_users (
+ -- User ID
+ id int not null primary key,
+
+ -- Secret key
+ secret varbinary(255) null,
+
+ -- Scratch tokens
+ scratch_tokens varbinary(511) null
+
+) /*$wgDBTableOptions*/;
diff --git a/www/wiki/extensions/OATHAuth/sql/oracle/tables.sql b/www/wiki/extensions/OATHAuth/sql/oracle/tables.sql
new file mode 100644
index 00000000..51bf328a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/sql/oracle/tables.sql
@@ -0,0 +1,15 @@
+define mw_prefix='{$wgDBprefix}';
+
+CREATE SEQUENCE oathauth_users_id_seq;
+CREATE TABLE &mw_prefix.oathauth_users (
+ -- User ID
+ id NUMBER NOT NULL,
+
+ -- Secret key
+ secret VARCHAR2(255) NULL,
+
+ -- Scratch tokens
+ scratch_tokens varbinary(511) NULL
+
+);
+ALTER TABLE &mw_prefix.oathauth_users ADD CONSTRAINT &mw_prefix.oathauth_users_pk PRIMARY KEY (id); \ No newline at end of file
diff --git a/www/wiki/extensions/OATHAuth/sql/postgres/tables.sql b/www/wiki/extensions/OATHAuth/sql/postgres/tables.sql
new file mode 100644
index 00000000..35dabedb
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/sql/postgres/tables.sql
@@ -0,0 +1,19 @@
+BEGIN;
+SET client_min_messages = 'ERROR';
+
+DROP SEQUENCE IF EXISTS oathauth_users_id_seq CASCADE;
+
+CREATE SEQUENCE oathauth_users_id_seq MINVALUE 0 START WITH 0;
+CREATE TABLE oathauth_users (
+ -- User ID
+ id INTEGER NOT NULL PRIMARY KEY DEFAULT nextval('oathauth_users_id_seq'),
+
+ -- Secret key
+ secret TEXT NULL,
+
+ -- Scratch tokens
+ scratch_tokens TEXT NULL
+
+);
+
+COMMIT; \ No newline at end of file
diff --git a/www/wiki/extensions/OATHAuth/tests/phan/config.php b/www/wiki/extensions/OATHAuth/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/OATHAuth/tests/phpunit/TOTPAuthenticationRequestTest.php b/www/wiki/extensions/OATHAuth/tests/phpunit/TOTPAuthenticationRequestTest.php
new file mode 100644
index 00000000..56403848
--- /dev/null
+++ b/www/wiki/extensions/OATHAuth/tests/phpunit/TOTPAuthenticationRequestTest.php
@@ -0,0 +1,17 @@
+<?php
+
+use MediaWiki\Auth\AuthenticationRequestTestCase;
+
+class TOTPAuthenticationRequestTest extends AuthenticationRequestTestCase {
+
+ protected function getInstance( array $args = [] ) {
+ return new TOTPAuthenticationRequest();
+ }
+
+ public function provideLoadFromSubmission() {
+ return [
+ [ [], [], false ],
+ [ [], [ 'OATHToken' => '123456' ], [ 'OATHToken' => '123456' ] ],
+ ];
+ }
+}
diff --git a/www/wiki/extensions/OpenGraphMeta/OpenGraphMeta.class.php b/www/wiki/extensions/OpenGraphMeta/OpenGraphMeta.class.php
index d6f96dc4..d015718f 100644
--- a/www/wiki/extensions/OpenGraphMeta/OpenGraphMeta.class.php
+++ b/www/wiki/extensions/OpenGraphMeta/OpenGraphMeta.class.php
@@ -66,7 +66,11 @@ class OpenGraphMeta {
if ( $setMainImage !== null ) {
// $mainImage = wfFindFile( Title::newFromDBkey( $setMainImage ) );
- $mainImage = wfFindFile(Title::newFromText( $setMainImage , NS_FILE ));
+ if (filter_var($setMainImage, FILTER_VALIDATE_URL) === FALSE) {
+ $mainImage = wfFindFile(Title::newFromText( $setMainImage , NS_FILE ));
+ } else {
+ $mainImage = $setMainImage;
+ }
} else {
$mainImage = false;
}
@@ -100,7 +104,7 @@ class OpenGraphMeta {
}
if ( ( $mainImage !== false ) ) {
- if ( is_object( $mainImage ) ) {
+ if (filter_var($mainImage, FILTER_VALIDATE_URL) === FALSE) {
// The official OpenGraph documentation says:
// - thumbnail previews can't be smaller than 200px x 200px
// - thumbnail previews look best at 1200px x 630px
@@ -112,6 +116,7 @@ class OpenGraphMeta {
} else {
// In some edge-cases we won't have defined an object but rather a full URL.
$meta['og:image'] = $mainImage;
+ $bannerImage = $mainImage;
}
} elseif ( $isMainpage ) {
$meta['og:image'] = wfExpandUrl( $wgLogo );
diff --git a/www/wiki/extensions/PageForms/.jshintrc b/www/wiki/extensions/PageForms/.jshintrc
index 22a065c1..30b20079 100644
--- a/www/wiki/extensions/PageForms/.jshintrc
+++ b/www/wiki/extensions/PageForms/.jshintrc
@@ -32,10 +32,15 @@
"globals": {
"mediaWiki": false,
+ "mw": false,
"pageforms": false,
"pf": false,
"ext": false,
"google": true,
"OpenLayers": true
- }
+ },
+
+ "predef": [
+ "OO"
+ ]
}
diff --git a/www/wiki/extensions/PageForms/Gruntfile.js b/www/wiki/extensions/PageForms/Gruntfile.js
index 1b1db4e7..6bedd9ee 100644
--- a/www/wiki/extensions/PageForms/Gruntfile.js
+++ b/www/wiki/extensions/PageForms/Gruntfile.js
@@ -15,7 +15,8 @@ module.exports = function ( grunt ) {
'!vendor/**',
'!libs/jquery.browser.js',
'!libs/jquery.dynatree.js',
- '!libs/jquery.fancybox.js',
+ '!libs/FancyBox/jquery.fancybox.1.3.4.js',
+ '!libs/FancyBox/jquery.fancybox.3.2.10.js',
'!libs/jsgrid.js',
'!libs/select2.js',
'!libs/PF_maps.js'
diff --git a/www/wiki/extensions/PageForms/INSTALL b/www/wiki/extensions/PageForms/INSTALL
index ce29dc1e..53a9ca41 100644
--- a/www/wiki/extensions/PageForms/INSTALL
+++ b/www/wiki/extensions/PageForms/INSTALL
@@ -1,4 +1,4 @@
-[[Page Forms 4.3]]
+[[Page Forms 4.4.1]]
Contents:
* Disclaimer
diff --git a/www/wiki/extensions/PageForms/PageForms.php b/www/wiki/extensions/PageForms/PageForms.php
index e9971973..3ef0d14a 100644
--- a/www/wiki/extensions/PageForms/PageForms.php
+++ b/www/wiki/extensions/PageForms/PageForms.php
@@ -69,7 +69,7 @@ if ( defined( 'PF_VERSION' ) ) {
return 1;
}
-define( 'PF_VERSION', '4.3' );
+define( 'PF_VERSION', '4.4.1' );
$GLOBALS['wgExtensionCredits']['specialpage'][] = array(
'path' => __FILE__,
@@ -113,14 +113,21 @@ if ( defined( 'SMW_VERSION' ) ) {
}
-$GLOBALS['wgHooks']['LinkEnd'][] = 'PFFormLinker::setBrokenLink';
+if ( class_exists( 'MediaWiki\Linker\LinkRenderer' ) ) {
+ // MW 1.28+
+ $GLOBALS['wgHooks']['HtmlPageLinkRendererEnd'][] = 'PFFormLinker::setBrokenLink';
+} else {
+ $GLOBALS['wgHooks']['LinkEnd'][] = 'PFFormLinker::setBrokenLinkOld';
+}
$GLOBALS['wgHooks']['SkinTemplateNavigation'][] = 'PFFormEditAction::displayTab';
$GLOBALS['wgHooks']['SkinTemplateNavigation'][] = 'PFHelperFormAction::displayTab';
$GLOBALS['wgHooks']['ArticlePurge'][] = 'PFFormUtils::purgeCache';
+$GLOBALS['wgHooks']['PageContentSaveComplete'][] = 'PFHooks::setPostEditCookie';
$GLOBALS['wgHooks']['ParserFirstCallInit'][] = 'PFHooks::registerFunctions';
$GLOBALS['wgHooks']['MakeGlobalVariablesScript'][] = 'PFHooks::setGlobalJSVariables';
$GLOBALS['wgHooks']['PageSchemasRegisterHandlers'][] = 'PFPageSchemas::registerClass';
$GLOBALS['wgHooks']['EditPage::importFormData'][] = 'PFHooks::showFormPreview';
+$GLOBALS['wgHooks']['CargoTablesActionLinks'][] = 'PFHooks::addToCargoTablesLinks';
$GLOBALS['wgHooks']['TinyMCEDisable'][] = 'PFHooks::disableTinyMCE';
$GLOBALS['wgHooks']['CanonicalNamespaces'][] = 'PFHooks::registerNamespaces';
$GLOBALS['wgHooks']['UnitTestsList'][] = 'PFHooks::onUnitTestsList';
@@ -152,6 +159,8 @@ $GLOBALS['wgSpecialPages']['CreateForm'] = 'PFCreateForm';
$GLOBALS['wgAutoloadClasses']['PFCreateForm'] = __DIR__ . '/specials/PF_CreateForm.php';
$GLOBALS['wgSpecialPages']['Templates'] = 'PFTemplates';
$GLOBALS['wgAutoloadClasses']['PFTemplates'] = __DIR__ . '/specials/PF_Templates.php';
+$GLOBALS['wgSpecialPages']['MultiPageEdit'] = 'PFMultiPageEdit';
+$GLOBALS['wgAutoloadClasses']['PFMultiPageEdit'] = __DIR__ . '/specials/PF_MultiPageEdit.php';
$GLOBALS['wgSpecialPages']['CreateTemplate'] = 'PFCreateTemplate';
$GLOBALS['wgAutoloadClasses']['PFCreateTemplate'] = __DIR__ . '/specials/PF_CreateTemplate.php';
if ( defined( 'SMW_VERSION' ) ) {
@@ -174,6 +183,7 @@ $GLOBALS['wgAutoloadClasses']['PFUploadSourceField'] = __DIR__ . '/specials/PF_U
$GLOBALS['wgAutoloadClasses']['PFUploadWindow'] = __DIR__ . '/specials/PF_UploadWindow.php';
$GLOBALS['wgAutoloadClasses']['PFTemplateField'] = __DIR__ . '/includes/PF_TemplateField.php';
$GLOBALS['wgAutoloadClasses']['TemplatesPage'] = __DIR__ . '/specials/PF_Templates.php';
+$GLOBALS['wgAutoloadClasses']['SpreadsheetTemplatesPage'] = __DIR__ . '/specials/PF_MultiPageEdit.php';
$GLOBALS['wgAutoloadClasses']['FormsPage'] = __DIR__ . '/specials/PF_Forms.php';
$GLOBALS['wgAutoloadClasses']['PFForm'] = __DIR__ . '/includes/PF_Form.php';
$GLOBALS['wgAutoloadClasses']['PFTemplate'] = __DIR__ . '/includes/PF_Template.php';
@@ -258,9 +268,9 @@ $GLOBALS['wgResourceModules'] += array(
'jquery.ui.core',
'jquery.ui.autocomplete',
'jquery.ui.sortable',
- 'ext.pageforms.fancybox',
'ext.pageforms.autogrow',
'mediawiki.util',
+ "mediawiki.api",
'ext.pageforms.select2',
'ext.pageforms.wikieditor'
),
@@ -281,9 +291,14 @@ $GLOBALS['wgResourceModules'] += array(
'ext.pageforms.browser' => $wgPageFormsResourceTemplate + array(
'scripts' => 'libs/jquery.browser.js',
),
- 'ext.pageforms.fancybox' => $wgPageFormsResourceTemplate + array(
- 'scripts' => 'libs/jquery.fancybox.js',
- 'styles' => 'skins/jquery.fancybox.css',
+ 'ext.pageforms.fancybox.jquery1' => $wgPageFormsResourceTemplate + array(
+ 'scripts' => 'libs/FancyBox/jquery.fancybox.1.3.4.js',
+ 'styles' => 'skins/FancyBox/jquery.fancybox.1.3.4.css',
+ 'dependencies' => array( 'ext.pageforms.browser' ),
+ ),
+ 'ext.pageforms.fancybox.jquery3' => $wgPageFormsResourceTemplate + array(
+ 'scripts' => 'libs/FancyBox/jquery.fancybox.3.2.10.js',
+ 'styles' => 'skins/FancyBox/jquery.fancybox.3.2.10.css',
'dependencies' => array( 'ext.pageforms.browser' ),
),
'ext.pageforms.dynatree' => $wgPageFormsResourceTemplate + array(
@@ -410,6 +425,7 @@ $GLOBALS['wgResourceModules'] += array(
'skins/jsgrid/theme.css',
),
'dependencies' => array(
+ 'ext.pageforms.select2',
'jquery.ui.sortable',
),
'messages' => array(
@@ -466,6 +482,14 @@ $GLOBALS['wgResourceModules'] += array(
'pf_blank_error',
),
),
+ 'ext.pageforms.PF_MultiPageEdit' => $wgPageFormsResourceTemplate + array(
+ 'scripts' => array(
+ 'libs/PF_MultiPageEdit.js',
+ ),
+ 'dependencies' => array(
+ 'ext.pageforms.jsgrid'
+ ),
+ ),
);
// PHP fails to find relative includes at some level of inclusion:
@@ -527,6 +551,12 @@ $GLOBALS['wgGroupPermissions']['user']['createclass'] = true;
$GLOBALS['wgAvailableRights'][] = 'createclass';
# ##
+# Permission to access Special:MultiPageEdit
+# ##
+$GLOBALS['wgGroupPermissions']['user']['multipageedit'] = true;
+$GLOBALS['wgAvailableRights'][] = 'multipageedit';
+
+# ##
# List separator character
# ##
$GLOBALS['wgPageFormsListSeparator'] = ",";
@@ -594,6 +624,9 @@ $GLOBALS['wgPageFormsShowOnSelect'] = array();
$GLOBALS['wgPageFormsAutocompleteValues'] = array();
$GLOBALS['wgPageFormsGridValues'] = array();
$GLOBALS['wgPageFormsGridParams'] = array();
+$GLOBALS['wgPageFormsContLangYes'] = null;
+$GLOBALS['wgPageFormsContLangNo'] = null;
+$GLOBALS['wgPageFormsContLangMonths'] = array();
// SMW
$GLOBALS['wgPageFormsFieldProperties'] = array();
// Cargo
diff --git a/www/wiki/extensions/PageForms/README b/www/wiki/extensions/PageForms/README
index 104aa052..55b28ac0 100644
--- a/www/wiki/extensions/PageForms/README
+++ b/www/wiki/extensions/PageForms/README
@@ -1,9 +1,9 @@
== About ==
Page Forms is an extension to MediaWiki that allows for the
-creation and usage of forms to add and edit semantic data. It can
-work in conjuction with two other extensions that both handle the
-storage of data: Semantic MediaWiki and Cargo.
+creation of forms that can be used to create and edit pages. It can
+work by itself, or in conjuction with two other extensions that
+both handle the storage of data: Cargo and Semantic MediaWiki.
For much more information on Page Forms, see the extension
homepage at https://www.mediawiki.org/wiki/Extension:Page_Forms
@@ -16,11 +16,11 @@ Page Forms was created, and mostly written by, Yaron Koren.
Significant parts of the code were contributed by Stephan Gambke.
-Much of the jQuery and related Javascript functionality was initially
+Much of the jQuery and related JavaScript functionality was initially
created by Sanyam Goyal as part of the 2010 Google Summer of Code
program.
-Integration into the Page Schemas extension was initially created by
+Integration with the Page Schemas extension was initially created by
Ankit Garg as part of the 2011 Google Summer of Code.
Support for section handling, and PHPUnit tests, were added by Himeshi
@@ -32,6 +32,9 @@ Jatin Mehta as part of the 2014 Google Summer of Code.
Support for hierarchies in the Cargo extension was added by Feroz
Ahmed as part of the 2017 Google Summer of Code.
+The page Special:MultiPageEdit was added by Yashdeep Thorat as part
+of the 2018 Google Summer of Code.
+
Important code contributions were also made by Christoph Burgmer,
Cindy Cicalese, Daniel Friesen, Daniel Hansch, Eugene Mednikov,
Harold Solbrig, Ilmārs Poikāns, Jayson Harshbarger, Jeffrey Stuckman,
@@ -39,19 +42,17 @@ Joel Natividad, Jeroen De Dauw, Joel Natividad, Louis Gerbarg, LY Meng,
Mathias Lidal, Matt Williamson, MWJames, Niklas Laxstrom, Nils
Opperman, Paladox, Patrick Nagel, Peter Grassberger, Remco de Boer,
Sebastian Richter, Sergey Chernyshev, Siebrand Mazeland, Simon Heimler,
-Solitarius, Tom Fellows, Vedmaka, wheresmytab, Yashdeep Thorat and
-others.
+Solitarius, Tom Fellows, Vedmaka, wheresmytab and others.
Language translations were provided by many people; see the files in
the /i18n and /languages directories for the full listings.
== Contact ==
-Comments, questions and suggestions can be sent to either the MediaWiki
-or the Semantic MediaWiki mailing lists:
+Comments, questions and suggestions should be sent to the MediaWiki
+or mailing list:
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
- https://lists.sourceforge.net/lists/listinfo/semediawiki-user
If possible, please add "[Page Forms]" at the beginning of the subject
line, to clarify the subject matter.
@@ -84,4 +85,5 @@ It also includes the Balloon.css CSS library
distributed under the MIT license.
Page Forms also makes extensive use of the jQuery and jQuery UI
-JavaScript libraries, included within MediaWiki.
+JavaScript libraries, as well as some use of the OOUI library, all
+included within MediaWiki.
diff --git a/www/wiki/extensions/PageForms/composer.json b/www/wiki/extensions/PageForms/composer.json
index 8f32fb12..50b951e2 100644
--- a/www/wiki/extensions/PageForms/composer.json
+++ b/www/wiki/extensions/PageForms/composer.json
@@ -39,7 +39,7 @@
"require-dev": {
"jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "16.0.0",
+ "mediawiki/mediawiki-codesniffer": "19.0.0",
"mediawiki/minus-x": "0.3.1"
},
"scripts": {
diff --git a/www/wiki/extensions/PageForms/extension.json b/www/wiki/extensions/PageForms/extension.json
index b301b1cd..1802c449 100644
--- a/www/wiki/extensions/PageForms/extension.json
+++ b/www/wiki/extensions/PageForms/extension.json
@@ -1,7 +1,7 @@
{
"@Note": "When updating this file please also update PageForms.php with the same changes.",
"name": "Page Forms",
- "version": "4.3",
+ "version": "4.4.1",
"author": [
"Yaron Koren",
"Stephan Gambke",
@@ -40,13 +40,15 @@
"editrestrictedfields": true
},
"user": {
- "createclass": true
+ "createclass": true,
+ "multipageedit": true
}
},
"AvailableRights": [
"viewedittab",
"editrestrictedfields",
- "createclass"
+ "createclass",
+ "multipageedit"
],
"Actions": {
"formedit": "PFFormEditAction",
@@ -56,6 +58,7 @@
"Forms": "PFForms",
"CreateForm": "PFCreateForm",
"Templates": "PFTemplates",
+ "MultiPageEdit": "PFMultiPageEdit",
"CreateTemplate": "PFCreateTemplate",
"CreateClass": "PFCreateClass",
"CreateCategory": "PFCreateCategory",
@@ -85,6 +88,7 @@
"PFForms": "specials/PF_Forms.php",
"PFCreateForm": "specials/PF_CreateForm.php",
"PFTemplates": "specials/PF_Templates.php",
+ "PFMultiPageEdit": "specials/PF_MultiPageEdit.php",
"PFCreateTemplate": "specials/PF_CreateTemplate.php",
"PFCreateClass": "specials/PF_CreateClass.php",
"PFCreateCategory": "specials/PF_CreateCategory.php",
@@ -96,6 +100,7 @@
"PFUploadWindow": "specials/PF_UploadWindow.php",
"PFTemplateField": "includes/PF_TemplateField.php",
"TemplatesPage": "specials/PF_Templates.php",
+ "SpreadsheetTemplatesPage": "specials/PF_MultiPageEdit.php",
"FormsPage": "specials/PF_Forms.php",
"PFForm": "includes/PF_Form.php",
"PFTemplate": "includes/PF_Template.php",
@@ -162,9 +167,9 @@
"jquery.ui.core",
"jquery.ui.autocomplete",
"jquery.ui.sortable",
- "ext.pageforms.fancybox",
"ext.pageforms.autogrow",
"mediawiki.util",
+ "mediawiki.api",
"ext.pageforms.select2",
"ext.pageforms.wikieditor"
],
@@ -187,9 +192,16 @@
"libs/jquery.browser.js"
]
},
- "ext.pageforms.fancybox": {
- "scripts": "libs/jquery.fancybox.js",
- "styles": "skins/jquery.fancybox.css",
+ "ext.pageforms.fancybox.jquery1": {
+ "scripts": "libs/FancyBox/jquery.fancybox.1.3.4.js",
+ "styles": "skins/FancyBox/jquery.fancybox.1.3.4.css",
+ "dependencies": [
+ "ext.pageforms.browser"
+ ]
+ },
+ "ext.pageforms.fancybox.jquery3": {
+ "scripts": "libs/FancyBox/jquery.fancybox.3.2.10.js",
+ "styles": "skins/FancyBox/jquery.fancybox.3.2.10.css",
"dependencies": [
"ext.pageforms.browser"
]
@@ -336,6 +348,7 @@
"skins/jsgrid/theme.css"
],
"dependencies": [
+ "ext.pageforms.select2",
"jquery.ui.sortable"
],
"messages": [
@@ -384,6 +397,11 @@
"pf_createtemplate_hierarchystructureplaceholder"
]
},
+ "ext.pageforms.PF_UploadWindow": {
+ "styles": [
+ "skins/PF_UploadWindow.css"
+ ]
+ },
"ext.pageforms.PF_CreateForm": {
"scripts": [
"libs/PF_CreateForm.js"
@@ -424,6 +442,14 @@
"ext.visualEditor.mwtransclusion",
"oojs-ui.styles.icons-editing-advanced"
]
+ },
+ "ext.pageforms.PF_MultiPageEdit": {
+ "scripts": [
+ "libs/PF_MultiPageEdit.js"
+ ],
+ "dependencies": [
+ "ext.pageforms.jsgrid"
+ ]
}
},
"ResourceFileModulePaths": {
@@ -431,9 +457,6 @@
"remoteExtPath": "PageForms"
},
"Hooks": {
- "LinkEnd": [
- "PFFormLinker::setBrokenLink"
- ],
"SkinTemplateNavigation": [
"PFFormEditAction::displayTab",
"PFHelperFormAction::displayTab"
@@ -444,6 +467,7 @@
"PageContentSave": [
"PFFormUtils::purgeCache"
],
+ "PageContentSaveComplete": "PFHooks::setPostEditCookie",
"ParserFirstCallInit": [
"PFHooks::registerFunctions"
],
@@ -456,6 +480,7 @@
"EditPage::importFormData": [
"PFHooks::showFormPreview"
],
+ "CargoTablesActionLinks": "PFHooks::addToCargoTablesLinks",
"TinyMCEDisable": "PFHooks::disableTinyMCE",
"CanonicalNamespaces": [
"PFHooks::registerNamespaces"
@@ -490,6 +515,9 @@
"PageFormsAutocompleteValues": [],
"PageFormsGridValues": [],
"PageFormsGridParams": [],
+ "PageFormsContLangYes": null,
+ "PageFormsContLangNo": null,
+ "PageFormsContLangMonths": [],
"PageFormsFieldProperties": [],
"PageFormsCargoFields": [],
"PageFormsDependentFields": [],
diff --git a/www/wiki/extensions/PageForms/i18n/ar.json b/www/wiki/extensions/PageForms/i18n/ar.json
index 9d855b85..7d2f7a0f 100644
--- a/www/wiki/extensions/PageForms/i18n/ar.json
+++ b/www/wiki/extensions/PageForms/i18n/ar.json
@@ -71,6 +71,9 @@
"pf_createtemplate_sectionsformat": "الأقسام",
"pf_createtemplate_addfield": "أضف حقلًا",
"pf_createtemplate_deletefield": "حذف",
+ "multipageedit": "تحرير صفحات متعددة",
+ "pf_multipageedit_docu": "حدد أحد القوالب التالية لتحرير كل الصفحات التي تحتوي عليه، يمكن أيضا إنشاء صفحات جديدة باستخدام القالب المحدد.",
+ "pf_multipageedit_with-name": "تحرير صفحات متعددة للقالب: $1",
"forms": "نماذج",
"pf_forms_docu": "النماذج التالية موجودة في الويكي.",
"pf_forminputs_mandatory": "إلزامي",
@@ -218,7 +221,7 @@
"pf_bad_number_error": "يجب أن يكون عددا سليما",
"pf_bad_date_error": "يجب أن يكون تاريخا سليما",
"pf_modified_input_error": "يجب الموافقة على هذا التعديل أو رفضه",
- "pf_pipe_error": "\"|\" غير مسموح به ، باستثناء داخل {{...}} أو [[...]]",
+ "pf_pipe_error": "\"|\" غير مسموح به ، باستثناء داخل {{...}} أو [[...]]، أو وسوم خاصة",
"uploadwindow": "نافذة الرفع",
"pf-simpleupload": "رفع",
"pf_deletionlog": "سجل الحذف",
@@ -242,9 +245,11 @@
"right-viewedittab": "أظهر لسان \"{{int:edit}}\" للصفحات التي يمكن تعديلها باستخدام نموذج.",
"right-editrestrictedfields": "حرّر حقول النموذج المقيّدة",
"right-createclass": "إنشاء طبقات دلالية جديدة",
+ "right-multipageedit": "تحرير صفحات متعددة باستخدام جدول بيانات",
"action-createclass": "إنشاء طبقات دلالية جديدة",
"action-editrestrictedfields": "تحرير حقول النموذج المقيدة",
"action-viewedittab": "عرض علامة التبويب \"{{int:edit}}\" للصفحات القابلة للتعديل بواسطة النموذج",
+ "action-multipageedit": "تحرير صفحات متعددة باستخدام جدول بيانات",
"tooltip-ca-formedit": "عدل هذه الصفحة بنموذج",
"pf-select2-no-matches": "لا توجد مطابقات",
"pf-select2-searching": "جارٍ البحث...",
diff --git a/www/wiki/extensions/PageForms/i18n/ast.json b/www/wiki/extensions/PageForms/i18n/ast.json
index 96831f0a..bebe552c 100644
--- a/www/wiki/extensions/PageForms/i18n/ast.json
+++ b/www/wiki/extensions/PageForms/i18n/ast.json
@@ -65,6 +65,9 @@
"pf_createtemplate_sectionsformat": "Seiciones",
"pf_createtemplate_addfield": "Agregar campu",
"pf_createtemplate_deletefield": "Desaniciar",
+ "multipageedit": "Editar múltiples páxines",
+ "pf_multipageedit_docu": "Seleiciona una de les siguientes plantíes pa editar toles páxines que la contengan. Tamién pueden crease páxines nueves usando la plantía seleicionada.",
+ "pf_multipageedit_with-name": "Editar múltiples páxines pa la plantía: $1",
"forms": "Formularios",
"pf_forms_docu": "Los siguientes formularios yá existen na wiki.",
"pf_forminputs_mandatory": "Tien d'escribir un valor pa esta entrada",
@@ -236,9 +239,11 @@
"right-viewedittab": "Ver la llingüeta \"{{int:edit}}\" nes páxines editables con un formulariu",
"right-editrestrictedfields": "Editar los campos restrinxíos de los formularios",
"right-createclass": "Crear nueves clases semántiques",
+ "right-multipageedit": "Editar delles páxines usando una fueya de cálculu",
"action-createclass": "crear nueves clases semántiques",
"action-editrestrictedfields": "editar los campos restrinxíos de los formularios",
"action-viewedittab": "ver la llingüeta \"{{int:edit}}\" nes páxines editables con un formulariu",
+ "action-multipageedit": "editar delles páxines usando una fueya de cálculu",
"tooltip-ca-formedit": "Editar esta páxina con un formulariu",
"pf-select2-no-matches": "Nun hai coincidencies",
"pf-select2-searching": "Buscando...",
diff --git a/www/wiki/extensions/PageForms/i18n/be.json b/www/wiki/extensions/PageForms/i18n/be.json
index d28ff63f..5d87025f 100644
--- a/www/wiki/extensions/PageForms/i18n/be.json
+++ b/www/wiki/extensions/PageForms/i18n/be.json
@@ -3,7 +3,8 @@
"authors": [
"Тест",
"Irus",
- "Mechanizatar"
+ "Mechanizatar",
+ "Artsiom91"
]
},
"pf_createproperty_proptype": "Тып:",
@@ -14,5 +15,6 @@
"formedit": "Рэдагаваць з дапамогай формы",
"pf_viewform": "Глядзець форму",
"pf_formedit_formwarning": "Папярэджаньне. Гэтая старонка [[$1|ужо існуе]], але не выкарыстоўвае гэтую форму.",
- "pf_autoedit_redlinkexists": "$1 ужо існуе."
+ "pf_autoedit_redlinkexists": "$1 ужо існуе.",
+ "pf-datepicker-close": "Закрыць"
}
diff --git a/www/wiki/extensions/PageForms/i18n/bn.json b/www/wiki/extensions/PageForms/i18n/bn.json
index 24505149..ad695e8b 100644
--- a/www/wiki/extensions/PageForms/i18n/bn.json
+++ b/www/wiki/extensions/PageForms/i18n/bn.json
@@ -5,7 +5,8 @@
"Bellayet",
"Wikitanvir",
"Zaheen",
- "Aftabuzzaman"
+ "Aftabuzzaman",
+ "আফতাবুজ্জামান"
]
},
"pf_createproperty_proptype": "ধরন:",
diff --git a/www/wiki/extensions/PageForms/i18n/cs.json b/www/wiki/extensions/PageForms/i18n/cs.json
index 2d2e7b48..31bbc750 100644
--- a/www/wiki/extensions/PageForms/i18n/cs.json
+++ b/www/wiki/extensions/PageForms/i18n/cs.json
@@ -11,7 +11,8 @@
"Aktron",
"Cvanca",
"Ilimanaq29",
- "Matěj Suchánek"
+ "Matěj Suchánek",
+ "Clon"
]
},
"createproperty": "Vytvořit vlastnost",
@@ -30,6 +31,7 @@
"pf_createtemplate_plainformat": "Prostý text",
"pf_createtemplate_addfield": "Přidat pole",
"pf_createtemplate_deletefield": "Smazat",
+ "multipageedit": "Editovat několik stránek",
"forms": "Formuláře",
"pf_createform_nameinput": "Název formuláře",
"pf_createform_template": "Šablona:",
diff --git a/www/wiki/extensions/PageForms/i18n/de.json b/www/wiki/extensions/PageForms/i18n/de.json
index f97278cc..8642874a 100644
--- a/www/wiki/extensions/PageForms/i18n/de.json
+++ b/www/wiki/extensions/PageForms/i18n/de.json
@@ -78,6 +78,9 @@
"pf_createtemplate_sectionsformat": "Abschnitte",
"pf_createtemplate_addfield": "Feld hinzufügen",
"pf_createtemplate_deletefield": "Löschen",
+ "multipageedit": "Mehrere Seiten bearbeiten",
+ "pf_multipageedit_docu": "Wähle eine der folgenden Vorlagen aus, um alle enthaltenen Seiten zu bearbeiten. Mit der ausgewählten Vorlage können auch neue Seiten erstellt werden.",
+ "pf_multipageedit_with-name": "Mehrere Seiten für die Vorlage „$1“ bearbeiten",
"forms": "Formulare",
"pf_forms_docu": "Die folgenden Formulare sind in diesem Wiki vorhanden:",
"pf_forminputs_mandatory": "In dieses Eingabefeld muss ein Datenwert eingegeben werden",
@@ -225,7 +228,7 @@
"pf_bad_number_error": "muss eine gültige Zahl sein",
"pf_bad_date_error": "muss ein gültiges Datum sein",
"pf_modified_input_error": "Diese Veränderung sollte bestätigt oder abgelehnt werden",
- "pf_pipe_error": "„|“ ist nicht erlaubt, mit Ausnahme innerhalb von {{...}} oder [[...]]",
+ "pf_pipe_error": "„|“ ist nicht erlaubt, mit Ausnahme innerhalb von {{...}}, [[...]] oder speziellen Tags",
"uploadwindow": "Formular zum Hochladen",
"pf-simpleupload": "Hochladen",
"pf_deletionlog": "Lösch-Logbuch",
@@ -249,9 +252,11 @@
"right-viewedittab": "Den Reiter „{{int:edit}}“ auf Seiten sehen, die bearbeitet werden können",
"right-editrestrictedfields": "Für die Bearbeitung beschränkte Formularfelder bearbeiten",
"right-createclass": "Erstellen neuer semantischer Klassen",
+ "right-multipageedit": "Mehrere Seiten mithilfe einer Tabelle bearbeiten",
"action-createclass": "neue semantische Klassen zu erstellen",
"action-editrestrictedfields": "für die Bearbeitung beschränkte Formularfelder zu bearbeiten",
"action-viewedittab": "den Reiter „{{int:edit}}“ auf Seiten zu sehen, die bearbeitet werden können",
+ "action-multipageedit": "mehrere Seiten mithilfe einer Tabelle zu bearbeiten",
"tooltip-ca-formedit": "Diese Seite mit einem Formular bearbeiten",
"pf-select2-no-matches": "Keine Treffer",
"pf-select2-searching": "Suche …",
diff --git a/www/wiki/extensions/PageForms/i18n/el.json b/www/wiki/extensions/PageForms/i18n/el.json
index fb21cc5f..1613bd95 100644
--- a/www/wiki/extensions/PageForms/i18n/el.json
+++ b/www/wiki/extensions/PageForms/i18n/el.json
@@ -14,7 +14,9 @@
"pageforms-desc": "Φόρμες για τη δημιουργία και επεξεργασία σελίδων wiki",
"specialpages-group-pf_group": "Φόρμες σελίδων",
"apihelp-pfautocomplete-description": "Αυτόματη συμπλήρωση που χρησιμοποιείται από την επέκταση Φόρμες σελίδων.",
+ "apihelp-pfautocomplete-summary": "Αυτόματη συμπλήρωση που χρησιμοποιείται από την επέκταση Φόρμες σελίδων.",
"apihelp-pfautocomplete-param-limit": "Όριο για τον αριθμό των αποτελεσμάτων που επιστρέφονται",
+ "apihelp-pfautocomplete-param-substr": "Η υποσυμβολοσειρά για αυτοολοκλήρωση σε",
"apihelp-pfautocomplete-param-property": "Ιδιότητα του Σημασιολογικού MediaWiki από τις τιμές της οποίας θα γίνεται η αυτόματη συμπλήρωση",
"apihelp-pfautocomplete-param-category": "Κατηγορία από τις σελίδες της οποίας θα γίνεται η αυτόματη συμπλήρωση",
"apihelp-pfautocomplete-param-concept": "«Έννοια» του Σημασιολογικού MediaWiki από τις σελίδες της οποίας θα γίνεται η αυτόματη συμπλήρωση",
@@ -23,7 +25,12 @@
"apihelp-pfautocomplete-param-field_is_array": "Αν το καθορισμένο πεδίο Cargo περιέχει σειρά τιμών",
"apihelp-pfautocomplete-param-namespace": "Ονοματοχώρος από τις σελίδες του οποίου θα γίνεται η αυτόματη συμπλήρωση",
"apihelp-pfautocomplete-param-external_url": "Ψευδώνυμο για μια εξωτερική διεύθυνση URL από την οποία να ληφθούν τιμές",
+ "apihelp-pfautocomplete-param-baseprop": "Μια προηγούμενη ιδιότητα Σημασιολογικού MediaWiki στη φόρμα για έλεγχο κατά",
+ "apihelp-pfautocomplete-param-base_cargo_table": "Ο πίνακας Cargo για ένα προηγούμενο πεδίο στην φόρμα για να ελεχθεί κατά",
+ "apihelp-pfautocomplete-param-base_cargo_field": "Το πεδίο Cargo για ένα προηγούμενο πεδίο στην φόρμα για να ελεχθεί κατά",
+ "apihelp-pfautocomplete-param-basevalue": "Η τιμή για έλεγχο της προηγούμενης ιδιότητας ή πεδίου",
"apihelp-pfautoedit-description": "Δημιουργία ή επεξεργασία σελίδας χρησιμοποιώντας φόρμα που ορίζεται από την επέκταση Φόρμες σελίδων.",
+ "apihelp-pfautoedit-summary": "Δημιουργία ή επεξεργασία σελίδας χρησιμοποιώντας φόρμα που ορίζεται από την επέκταση Φόρμες σελίδων.",
"apihelp-pfautoedit-param-form": "Η φόρμα των Φορμών σελίδων που να χρησιμοποιηθεί",
"apihelp-pfautoedit-param-target": "Το όνομα της σελίδας προς δημιουργία ή επεξεργασία",
"apihelp-pfautoedit-param-query": "Η συμβολοσειρά του ερωτήματος",
@@ -43,13 +50,17 @@
"pf_createtemplate_multipleinstance": "Αυτό το πρότυπο μπορεί να συμπεριληφθεί πολλές φορές στη σελίδα.",
"pf_createtemplate_connectingproperty": "Όνομα ιδιότητας που να συνδέει τα πεδία αυτού του προτύπου με το υπόλοιπο της σελίδας:",
"pf_createtemplate_categorylabel": "Κατηγορία οριζόμενη από πρότυπο (προαιρετικό):",
- "pf_createtemplate_cargotablelabel": "Πίνακας Cargo οριζόμενος από πρότυπο (προαιρετικό):",
+ "pf_createtemplate_usecargo": "Χρησιμοποιήστε την επέκταση Cargo για να αποθηκεύσετε τα δεδομένα αυτού του προτύπου",
+ "pf_createtemplate_cargotablelabel": "Όνομα πίνακα του Cargo οριζόμενου από πρότυπο:",
"pf_createtemplate_templatefields": "Πεδία προτύπου",
"pf_createtemplate_fieldsdesc": "Για να μην χρειάζονται ονόματα τα πεδία αυτού του προτύπου, απλά εισαγάγετε τον αύξοντα αριθμό κάθε πεδίου (π.χ. 1, 2, 3, κλπ.) σαν όνομα, αντί για κανονικό όνομα.",
"pf_createtemplate_fieldname": "Όνομα πεδίου:",
"pf_createtemplate_displaylabel": "Εμφανιζόμενη ετικέτα:",
"pf_createtemplate_semanticproperty": "Σημασιολογική ιδιότητα:",
"pf_createtemplate_fieldislist": "Το πεδίο δέχεται λίστα τιμών",
+ "pf_createtemplate_fieldishierarchy": "Το πεδίο κατέχει μια ιεραρχία",
+ "pf_createtemplate_hierarchystructureplaceholder": "*Εισαγωγή\n**τιμών\n***ιεραρχίας\n***σε\n**μια\n***μορφοποίηση\n*όπως\n**αυτή",
+ "pf_createproperty_allowedvalsforhierarchy": "Επιτρεπόμενες τιμές για ιεραρχία:",
"pf_createtemplate_delimiter": "Διαχωριστικό:",
"pf_createtemplate_aggregation": "Συνάθροιση",
"pf_createtemplate_aggregationdesc": "Για να εμφανίσετε, σε οποιαδήποτε σελίδα χρησιμοποιεί αυτό το πρότυπο, μια λίστα όλων των σελίδων που έχουν μια ορισμένη ιδιότητα που οδηγεί σε αυτήν τη σελίδα, καθορίστε την κατάλληλη ιδιότητα παρακάτω:",
@@ -61,6 +72,7 @@
"pf_createtemplate_sectionsformat": "Ενότητες",
"pf_createtemplate_addfield": "Προσθήκη πεδίου",
"pf_createtemplate_deletefield": "Διαγραφή",
+ "multipageedit": "Επεξεργασία πολλαπλών σελίδων",
"forms": "Φόρμες",
"pf_forms_docu": "Στο wiki υπάρχουν οι παρακάτω φόρμες.",
"pf_forminputs_mandatory": "Υποχρεωτικό",
@@ -207,6 +219,7 @@
"pf_bad_email_error": "απαιτείται μια έγκυρη μορφή διεύθυνσης email",
"pf_bad_number_error": "πρέπει να είναι ένας έγκυρος αριθμός",
"pf_bad_date_error": "πρέπει να είναι μια έγκυρη ημερομηνία",
+ "pf_modified_input_error": "Αυτή η τροποποίηση πρέπει να εγκριθεί ή να απορριφθεί",
"pf_pipe_error": "Το «|» δεν επιτρέπεται, εκτός αν είναι μέσα σε {{...}} ή [[...]]",
"uploadwindow": "Παράθυρο ανεβάσματος",
"pf-simpleupload": "Ανέβασμα αρχείου",
diff --git a/www/wiki/extensions/PageForms/i18n/en.json b/www/wiki/extensions/PageForms/i18n/en.json
index 4a6196cc..dc7aceb9 100644
--- a/www/wiki/extensions/PageForms/i18n/en.json
+++ b/www/wiki/extensions/PageForms/i18n/en.json
@@ -65,6 +65,9 @@
"pf_createtemplate_sectionsformat": "Sections",
"pf_createtemplate_addfield": "Add field",
"pf_createtemplate_deletefield": "Delete",
+ "multipageedit": "Edit multiple pages",
+ "pf_multipageedit_docu": "Select one of the following templates to edit all the pages containing it. New pages can also be created using the selected template.",
+ "pf_multipageedit_with-name": "Edit multiple pages for template: $1",
"forms": "Forms",
"pf_forms_docu": "The following forms exist in the wiki.",
"pf_forminputs_mandatory": "A value must be entered for this input",
@@ -213,7 +216,7 @@
"pf_bad_number_error": "must be a valid number",
"pf_bad_date_error": "must be a valid date",
"pf_modified_input_error": "This modification should be approved or rejected",
- "pf_pipe_error": "\"|\" is not allowed, except within {{...}} or [[...]]",
+ "pf_pipe_error": "\"|\" is not allowed, except within {{...}}, [[...]], or special tags",
"uploadwindow": "Upload window",
"pf-simpleupload": "Upload",
"pf_deletionlog": "Deletion log",
@@ -237,9 +240,11 @@
"right-viewedittab": "View \"{{int:edit}}\" tab for pages editable by form",
"right-editrestrictedfields": "Edit restricted form fields",
"right-createclass": "Create new semantic classes",
+ "right-multipageedit": "Edit multiple pages using a spreadsheet",
"action-createclass": "create new semantic classes",
"action-editrestrictedfields": "edit restricted form fields",
"action-viewedittab": "view the \"{{int:edit}}\" tab for pages editable by form",
+ "action-multipageedit": "edit multiple pages using a spreadsheet",
"tooltip-ca-formedit": "Edit this page with a form",
"accesskey-ca-formedit": "&",
"pf-select2-no-matches": "No matches",
@@ -277,5 +282,7 @@
"pf-invalidexturl": "Invalid external URL value.",
"pf-blankexturl": "Blank external URL value.",
"pf-externalpageempty": "External page contains no contents.",
- "pf-externalpagebadjson": "Could not parse JSON in external page."
+ "pf-externalpagebadjson": "Could not parse JSON in external page.",
+ "pf_formstart_pagelanguage": "Page language:",
+ "pf_formstart_pagenamespace": "Page namespace:"
}
diff --git a/www/wiki/extensions/PageForms/i18n/es.json b/www/wiki/extensions/PageForms/i18n/es.json
index 0a49a951..43487ab5 100644
--- a/www/wiki/extensions/PageForms/i18n/es.json
+++ b/www/wiki/extensions/PageForms/i18n/es.json
@@ -18,7 +18,8 @@
"Ryo567",
"Sethladan",
"Matiia",
- "Dgstranz"
+ "Dgstranz",
+ "Adjen"
]
},
"pageforms-desc": "Formularios para crear y editar páginas wiki",
diff --git a/www/wiki/extensions/PageForms/i18n/fr.json b/www/wiki/extensions/PageForms/i18n/fr.json
index b57a5f73..b09bb6b0 100644
--- a/www/wiki/extensions/PageForms/i18n/fr.json
+++ b/www/wiki/extensions/PageForms/i18n/fr.json
@@ -95,6 +95,9 @@
"pf_createtemplate_sectionsformat": "Sections",
"pf_createtemplate_addfield": "Ajouter un champ",
"pf_createtemplate_deletefield": "Supprimer",
+ "multipageedit": "Modifier des pages multiples",
+ "pf_multipageedit_docu": "Choisir un des modèles suivants pour modifier toutes les pages qui l'importent. De nouvelles pages peuvent également être créées en utilisant le modèle sélectionné.",
+ "pf_multipageedit_with-name": "Modifier des pages multiples pour le modèle : $1",
"forms": "Formulaires",
"pf_forms_docu": "Les formulaires suivants existent dans le wiki.",
"pf_forminputs_mandatory": "Obligatoire",
@@ -186,6 +189,8 @@
"pf_formstart_docu": "Entrez ici un nom de page, destinée à être modifiée avec le formulaire « $1 ». \nSi cette page existe déjà, vous serez dirigé vers son formulaire de modification. \nDans le cas contraire, vous serez redirigé vers le formulaire de création de page.",
"pf_formstart_noform_docu": "Entrez ici un nom de page, puis sélectionnez le formulaire qui servira à la modifier. \nSi cette page existe déjà, vous serez dirigé vers son formulaire de modification. \nDans le cas contraire, vous serez redirigé vers le formulaire de création de page.",
"pf_formstart_createoredit": "Créer ou modifier",
+ "pf_formstart_pagelanguage": "Langue de la page :",
+ "pf_formstart_pagenamespace": "Namespace de la page :",
"formedit": "Modifier avec formulaire",
"pf-formedit-selectform": "Sélectionnez un formulaire pour créer cette page:",
"pf-formedit-mainforms": "Formulaires principaux :",
@@ -242,7 +247,7 @@
"pf_bad_number_error": "doit être un nombre valide",
"pf_bad_date_error": "doit être une date valide",
"pf_modified_input_error": "Cette modification doit être approuvée ou rejetée",
- "pf_pipe_error": "« | » n’est pas autorisé, sauf à l’intérieur de {{...}} ou de [[...]].",
+ "pf_pipe_error": "« | » n’est pas autorisé, sauf à l’intérieur de {{...}}, de [[...]], ou de balises spéciales",
"uploadwindow": "Fenêtre de téléversement",
"pf-simpleupload": "Téléverser",
"pf_deletionlog": "Historique des suppressions",
@@ -266,9 +271,11 @@
"right-viewedittab": "Voir l’onglet « {{int:edit}} » pour les pages modifiables via un formulaire",
"right-editrestrictedfields": "Modifier les champs restreints des formulaires",
"right-createclass": "Créer de nouvelles classes sémantiques",
+ "right-multipageedit": "Modifier plusieurs pages à l'aide d'un tableur",
"action-createclass": "créer de nouvelles classes sémantiques",
"action-editrestrictedfields": "Modifier les champs de formulaire protégés",
"action-viewedittab": "voir l’onglet \"{{int:edit}}\" pour les pages modifiables via un formulaire",
+ "action-multipageedit": "modifier plusieurs pages à l'aide d'un tableur",
"tooltip-ca-formedit": "Modifier cette page avec un formulaire",
"pf-select2-no-matches": "Aucune correspondance",
"pf-select2-searching": "Recherche en cours…",
diff --git a/www/wiki/extensions/PageForms/i18n/fy.json b/www/wiki/extensions/PageForms/i18n/fy.json
index 8794fbdb..b580d6a1 100644
--- a/www/wiki/extensions/PageForms/i18n/fy.json
+++ b/www/wiki/extensions/PageForms/i18n/fy.json
@@ -3,7 +3,8 @@
"authors": [
"Kening Aldgilles",
"Snakesteuben",
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "PiefPafPier"
]
},
"pf_createtemplate_standardformat": "Tabel",
@@ -14,7 +15,7 @@
"pf_formedit_createtitle": "$1 oanmeitsje: $2",
"pf_formedit_createtitlenotarget": "$1 oanmeitsje",
"pf_editsource": "Bewurkje boarne",
- "pf_formedit_none": "Gjin",
+ "pf_formedit_none": "Gjint",
"pf-datepicker-close": "Slute",
"pf-datepicker-prev": "Foarige",
"pf-datepicker-next": "Folgjende",
diff --git a/www/wiki/extensions/PageForms/i18n/gl.json b/www/wiki/extensions/PageForms/i18n/gl.json
index 02fe30d6..e156e8f2 100644
--- a/www/wiki/extensions/PageForms/i18n/gl.json
+++ b/www/wiki/extensions/PageForms/i18n/gl.json
@@ -52,7 +52,7 @@
"pf_createtemplate_templatefields": "Modelo dos campos",
"pf_createtemplate_fieldsdesc": "Para facer que os campos deste modelo non requiran xa nomes de campo, simplemente introduza o índice de cada campo (p. ex. 1, 2, 3, etc.) como nome, no canto dun nome real.",
"pf_createtemplate_fieldname": "Nome do campo:",
- "pf_createtemplate_displaylabel": "Mostrar a etiqueta:",
+ "pf_createtemplate_displaylabel": "Amosar a etiqueta:",
"pf_createtemplate_semanticproperty": "Propiedade semántica:",
"pf_createtemplate_fieldislist": "Este campo contén unha lista de valores",
"pf_createtemplate_delimiter": "Delimitador:",
@@ -92,13 +92,13 @@
"pf_forminputs_list": "Marcar esta entrada como que ten unha lista de valores",
"pf_forminputs_delimiter": "O delimitador entre os valores do campo, se esta entrada ten unha lista de valores",
"pf_forminputs_existingvaluesonly": "Permitir soamente os valores que xa estean na lista",
- "pf_forminputs_showonselect": "Elementos da páxina que mostrar se só se seleccionan algúns valores determinados (por exemplo: \"valor1=>div1;valor2=>div2\")",
+ "pf_forminputs_showonselect": "Elementos da páxina que amosar se só se seleccionan algúns valores determinados (por exemplo: \"valor1=>div1;valor2=>div2\")",
"pf_forminputs_listboxsize": "A altura desta caixa de listas, en liñas",
"pf_forminputs_includetimezone": "Incluír unha entrada para a zona horaria",
"pf_forminputs_topcategory": "A categoría nai dun conxunto de categorías",
"pf_forminputs_structure": "Unha lista manual de valores, feita como unha lista non ordenada de valores en texto wiki",
"pf_forminputs_hideroot": "Agochar a categoría raíz",
- "pf_forminputs_depth": "O número de niveis de categorías que mostrar inicialmente",
+ "pf_forminputs_depth": "O número de niveis de categorías que amosar inicialmente",
"pf_forminputs_height": "A altura desta entrada, en píxeles",
"pf_forminputs_width": "O largo desta entrada, en píxeles",
"pf_forminputs_checkboxes_select_all": "Seleccionar todos",
@@ -266,7 +266,7 @@
"pf-regexp-baseprefix": "Prefixo para os parámetros do tipo de base.",
"pf-regexp-orchar": "O carácter OU a usar na expresión regular no canto de \"|\". Por defecto é \"!\".",
"pf-regexp-inverse": "En caso de estar definida, a entrada NON debe coincidir coa expresión regular para ser válida. Por exemplo, se a expresión regular está invertida.",
- "pf-regexp-message": "A mensaxe de erro a mostrar se falla a coincidencia. Por defecto é \"Formato incorrecto!\" (ou a forma equivalente na lingua local)",
+ "pf-regexp-message": "A mensaxe de erro a amosar se falla a coincidencia. Por defecto é \"Formato incorrecto!\" (ou a forma equivalente na lingua local)",
"pf-missingconcept": "Non se puido atopar o concepto: $1",
"pf-missingnamespace": "Non se puido atopar o espazo de nomes: $1",
"pf-nocompletionurls": "Non se especificou ningunha URL externa para a función de autocompletado neste wiki.",
diff --git a/www/wiki/extensions/PageForms/i18n/hr.json b/www/wiki/extensions/PageForms/i18n/hr.json
index 1b359020..f0d7935b 100644
--- a/www/wiki/extensions/PageForms/i18n/hr.json
+++ b/www/wiki/extensions/PageForms/i18n/hr.json
@@ -26,5 +26,7 @@
"pf_formedit_remove": "Ukloni",
"runquery": "Pokreni upit",
"pf_form_docu": "Ovo je obrazac \"$1\".\nZa kreiranje stranica uporabom ovog obrasca, unesite ime stranice u polje ispod;\nako takva stranica već postoji, otvorit će Vam se obrazac za uređivanje te stranice.",
- "pf_form_freetextlabel": "Slobodni unos"
+ "pf_form_freetextlabel": "Slobodni unos",
+ "pf-maps-enteraddress": "Ovdje upišite adresu",
+ "pf-maps-lookupcoordinates": "Izračunaj koordinate rabeći adresu"
}
diff --git a/www/wiki/extensions/PageForms/i18n/ia.json b/www/wiki/extensions/PageForms/i18n/ia.json
index 0132355f..252d0f87 100644
--- a/www/wiki/extensions/PageForms/i18n/ia.json
+++ b/www/wiki/extensions/PageForms/i18n/ia.json
@@ -166,9 +166,11 @@
"right-viewedittab": "Vider le scheda \"{{int:edit}}\" pro paginas modificabile per formulario",
"right-editrestrictedfields": "Modificar le campos restringite de formularios",
"right-createclass": "Crear nove classes semantic",
+ "right-multipageedit": "Modificar plure paginas usante un folio de calculo",
"action-createclass": "crear nove classes semantic",
"action-editrestrictedfields": "modificar le campos restringite de formularios",
"action-viewedittab": "vider le scheda \"{{int:edit}}\" pro paginas modificabile per formulario",
+ "action-multipageedit": "modificar plure paginas usante un folio de calculo",
"pf-datepicker-close": "Clauder",
"pf-datepicker-prev": "Precedente",
"pf-datepicker-next": "Sequente",
diff --git a/www/wiki/extensions/PageForms/i18n/inh.json b/www/wiki/extensions/PageForms/i18n/inh.json
index 28744670..cc04b49f 100644
--- a/www/wiki/extensions/PageForms/i18n/inh.json
+++ b/www/wiki/extensions/PageForms/i18n/inh.json
@@ -6,6 +6,7 @@
},
"templates": "Лераш",
"pf_createform_template": "Ло:",
+ "pf_createform_inputtypedefault": "(юххьанцара хиннача тайпара)",
"pf_createclass_create": "Хьакхолла",
"pf_formedit_createtitle": "Хьакхоллар $1: $2",
"pf_formedit_createtitlenotarget": "Хьакхолла $1"
diff --git a/www/wiki/extensions/PageForms/i18n/it.json b/www/wiki/extensions/PageForms/i18n/it.json
index 97351dfe..365e48a8 100644
--- a/www/wiki/extensions/PageForms/i18n/it.json
+++ b/www/wiki/extensions/PageForms/i18n/it.json
@@ -184,7 +184,7 @@
"pf_bad_number_error": "Dev'\\esser un numero valido",
"pf_bad_date_error": "Dev'\\esser una data valida",
"pf_modified_input_error": "Questa modifica deve essere approvata o rifiutata",
- "pf_pipe_error": "\"|\" non è consentito, eccetto all'interno di {{...}} o [[...]]",
+ "pf_pipe_error": "\"|\" non è consentito, eccetto all'interno di {{...}}, [[...]] o etichette speciali",
"uploadwindow": "Finestra di upload",
"pf-simpleupload": "Carica",
"pf_deletionlog": "Log cancellazioni",
diff --git a/www/wiki/extensions/PageForms/i18n/kjp.json b/www/wiki/extensions/PageForms/i18n/kjp.json
new file mode 100644
index 00000000..5d58ae47
--- /dev/null
+++ b/www/wiki/extensions/PageForms/i18n/kjp.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Rul1902"
+ ]
+ },
+ "formedit": "လ်ုဖေါင်ႋအ်ုၯင် မ်ုအင်းတာင်"
+}
diff --git a/www/wiki/extensions/PageForms/i18n/ko.json b/www/wiki/extensions/PageForms/i18n/ko.json
index 46706171..a69be4c5 100644
--- a/www/wiki/extensions/PageForms/i18n/ko.json
+++ b/www/wiki/extensions/PageForms/i18n/ko.json
@@ -52,6 +52,8 @@
"pf_createtemplate_sectionsformat": "부분",
"pf_createtemplate_addfield": "필드 추가",
"pf_createtemplate_deletefield": "삭제",
+ "multipageedit": "여러 문서 편집",
+ "pf_multipageedit_docu": "틀을 포함하는 모든 문서를 편집하려면 다음의 틀 중 하나를 선택하십시오. 선택된 틀을 사용하여 새 문서를 만들 수도 있습니다.",
"forms": "양식 목록",
"pf_forms_docu": "다음 양식은 위키에 존재합니다.",
"pf_forminputs_mandatory": "이 입력에 대한 값을 입력해야 합니다",
@@ -193,7 +195,7 @@
"pf_bad_number_error": "올바른 숫자여야 합니다",
"pf_bad_date_error": "올바른 날짜여야 합니다",
"pf_modified_input_error": "이 수정은 승인되거나 거부되어야 합니다",
- "pf_pipe_error": "{{...}} 또는 [[...]] 안에 쓰지 않는 한 \"|\"는 허용되지 않습니다.",
+ "pf_pipe_error": "{{...}}, [[...]] 또는 특수 문서 안에 쓰지 않는 한 \"|\"는 허용되지 않습니다",
"uploadwindow": "올리기 창",
"pf-simpleupload": "업로드",
"pf_deletionlog": "삭제 기록",
@@ -217,9 +219,11 @@
"right-viewedittab": "양식에서 편집할 문서에 \"{{int:edit}}\" 탭을 보여줍니다",
"right-editrestrictedfields": "제한된 양식 입력란 편집",
"right-createclass": "새 시맨틱 클래스 만들기",
+ "right-multipageedit": "스프레드시트를 사용하여 여러 문서 편집",
"action-createclass": "새 시맨틱 클래스 만들기",
"action-editrestrictedfields": "제한된 양식 입력란 편집",
"action-viewedittab": "양식에서 편집할 문서에 \"{{int:edit}}\" 탭을 보이기",
+ "action-multipageedit": "스프레드시트를 사용하여 여러 문서 편집",
"tooltip-ca-formedit": "형식에 따라 이 페이지를 수정하십시오.",
"pf-select2-no-matches": "일치하는 항목 없음",
"pf-select2-searching": "검색 중...",
diff --git a/www/wiki/extensions/PageForms/i18n/lb.json b/www/wiki/extensions/PageForms/i18n/lb.json
index 91dfeffd..2c0f6d01 100644
--- a/www/wiki/extensions/PageForms/i18n/lb.json
+++ b/www/wiki/extensions/PageForms/i18n/lb.json
@@ -130,7 +130,7 @@
"pf_bad_number_error": "muss eng valabel Zuel sinn",
"pf_bad_date_error": "muss e gëltegen Datum sinn",
"pf_modified_input_error": "Dës Ännerung soll nogekuckt oder refuséiert ginn.",
- "pf_pipe_error": "\"|\" ass net erlaabt, ausser an {{...}} oder [[...]]",
+ "pf_pipe_error": "\"|\" ass net erlaabt, ausser an {{...}}, [[...]] oder speziellen Tags",
"uploadwindow": "Fënster fir eropzelueden",
"pf-simpleupload": "Eroplueden",
"pf_deletionlog": "Logbuch vum Läschen",
diff --git a/www/wiki/extensions/PageForms/i18n/lt.json b/www/wiki/extensions/PageForms/i18n/lt.json
index 983a7374..d0267b00 100644
--- a/www/wiki/extensions/PageForms/i18n/lt.json
+++ b/www/wiki/extensions/PageForms/i18n/lt.json
@@ -148,10 +148,10 @@
"pf-pageschemas-edittitle": "Formos pavadinimas egzistuojantiems puslapiams:",
"pf-pageschemas-inputtype": "Įvesties tipas (palikite tuščią, kad būtų numatytasis):",
"pf_property_isproperty": "Tai yra „$1“ tipo savybė.",
- "pf_property_allowedvals": "Šios savybės leidžiamos reikšmės yra:",
+ "pf_property_allowedvals": "{{PLURAL:$1|Šios savybės leidžiama reikšmė|Šios savybės leidžiamos reikšmės}} yra:",
"pf_template_docu": "Tai yra „$1“ šablonas.\nJis turėtų būti kviečiamas šiuo formatu formatu:",
"pf_template_docufooter": "Norėdami matyti šablono tekstą, turite redaguoti puslapį.",
- "pf_form_docu": "Tai yra „$1“ forma.\nNorėdami sukurti puslapį naudojantis šia forma, įveskite to pulslapio vardą žemiau.\nJeigu puslapis tokiu vardu jau egzistuoja, šia forma galėsite jį redaguoti.",
+ "pf_form_docu": "Tai yra „$1“ forma.\nNorėdami sukurti puslapį su šia forma, įveskite to puslapio pavadinimą žemiau.\nJeigu puslapis tokiu vardu jau egzistuoja, jūs būsite nukreipti į puslapio redagavimo formą.",
"pf_form_freetextlabel": "Laisvas tekstas",
"pf_category_hasdefaultform": "Ši kategorija naudoja „$1“ formą.",
"pf_category_desc": "Tai yra „$1“ kategorija.",
diff --git a/www/wiki/extensions/PageForms/i18n/lv.json b/www/wiki/extensions/PageForms/i18n/lv.json
index 476b0e1f..ecb3d20c 100644
--- a/www/wiki/extensions/PageForms/i18n/lv.json
+++ b/www/wiki/extensions/PageForms/i18n/lv.json
@@ -33,6 +33,7 @@
"pf_createtemplate_sectionsformat": "Sadaļas",
"pf_createtemplate_addfield": "Pievienot lauku",
"pf_createtemplate_deletefield": "Izdzēst",
+ "multipageedit": "Labot vairākas lapas",
"forms": "Formas",
"pf_forms_docu": "Wiki ir sekojošas formas.",
"pf_forminputs_mandatory": "Šim laukam obligāti jāievada vērtība",
diff --git a/www/wiki/extensions/PageForms/i18n/mk.json b/www/wiki/extensions/PageForms/i18n/mk.json
index 5c14753f..ec2981df 100644
--- a/www/wiki/extensions/PageForms/i18n/mk.json
+++ b/www/wiki/extensions/PageForms/i18n/mk.json
@@ -66,6 +66,9 @@
"pf_createtemplate_sectionsformat": "Поднаслови",
"pf_createtemplate_addfield": "Додај поле",
"pf_createtemplate_deletefield": "Избриши",
+ "multipageedit": "Уредување на повеќе страници",
+ "pf_multipageedit_docu": "Изберете еден од следниве шаблони за да ги уредите сите страници што го содржат. Со избраниот шаблон можат да се создаваат и нови страници.",
+ "pf_multipageedit_with-name": "Уредување на повеќе страници за шаблонот „$1“",
"forms": "Обрасци",
"pf_forms_docu": "Во викито постојат следниве обрасци.",
"pf_forminputs_mandatory": "Мора да внесете вредност за овој внос",
@@ -81,7 +84,7 @@
"pf_forminputs_change_file": "Смени податотека",
"pf_forminputs_defaultfilename": "Основно-зададено име на подигнатите податотеки",
"pf_forminputs_rows": "Број на редови за овој внос",
- "pf_forminputs_cols": "Број на колони за овој внос",
+ "pf_forminputs_cols": "Број на столбови за овој внос",
"pf_forminputs_autogrow": "Поставете го овој внос да расте во големина ако текстот ги надминува неговите граници",
"pf_forminputs_valuesfromproperty": "Својство чиишто вредности во викито треба да се збирот вредности на овој внос",
"pf_forminputs_valuesfromcategory": "Категорија чиишто страници треба да се збирот вредности на овој внос",
@@ -237,9 +240,11 @@
"right-viewedittab": "Приказ на јазиче „{{int:edit}}“ за страниците уредливи со образец",
"right-editrestrictedfields": "Уредување на заштитени полиња на обрасци",
"right-createclass": "Создавање на нови семантички класи",
+ "right-multipageedit": "Уредување на повеќе страници наеднаш со помош на таблица",
"action-createclass": "создавање на нови семантички класи",
"action-editrestrictedfields": "уредување на заштитени полиња на обрасци",
"action-viewedittab": "приказ на јазичето „{{int:edit}}“ кај страниците уредливи со образец",
+ "action-multipageedit": "уредување на повеќе страници наеднаш со помош на таблица",
"tooltip-ca-formedit": "Уреди ја страницава со образец",
"pf-select2-no-matches": "Нема совпаѓања",
"pf-select2-searching": "Пребарувам...",
diff --git a/www/wiki/extensions/PageForms/i18n/my.json b/www/wiki/extensions/PageForms/i18n/my.json
index f658362e..dc01e1ac 100644
--- a/www/wiki/extensions/PageForms/i18n/my.json
+++ b/www/wiki/extensions/PageForms/i18n/my.json
@@ -1,9 +1,40 @@
{
"@metadata": {
"authors": [
- "Ninjastrikers"
+ "Ninjastrikers",
+ "Dr Lotus Black",
+ "Jc phone"
]
},
+ "specialpages-group-pf_group": "စာမျက်နှာ ပုံစံများ",
+ "pf_createproperty_proptype": "အမျိုးအစား:",
"templates": "တမ်းပလိတ်များ",
- "pf_createform_template": "တမ်းပလိတ်:"
+ "createtemplate": "တမ်းပလိတ်တစ်ခု ဖန်တီးရန်",
+ "pf-createtemplate-with-name": "တမ်းပလိတ် ဖန်တီးရန်: $1",
+ "pf_createtemplate_namelabel": "တမ်းပလိတ်အမည်",
+ "pf_createtemplate_deletefield": "ဖျက်ပါ",
+ "pf_createform_template": "တမ်းပလိတ်:",
+ "pf_createform_inputtypedefault": "(နဂိုအတိုင်း)",
+ "createcategory": "ကဏ္ဍတစ်ခု ဖန်တီးရန်",
+ "pf-createcategory-with-name": "ကဏ္ဍတစ်ခု ဖန်တီးရန်: $1",
+ "pf_createcategory_name": "ကဏ္ဍအမည်:",
+ "pf_createcategory_defaultform": "နဂိုပုံစံ:",
+ "pf_createcategory_makesubcategory": "ဤကို အခြားကဏ္ဍ၏ ကဏ္ဍခွဲတစ်ခုအဖြစ် ပြုလုပ်ရန် (ထည့်လိုက):",
+ "pf_createclass_create": "ဖန်တီးရန်",
+ "formedit": "ဖောင်ပုံစံဖြင့် တည်းဖြတ်ရန်",
+ "pf_editsource": "ရင်းမြစ်ကို တည်းဖြတ်ရန်",
+ "pf-autoedit-wait": "စောင့်ဆိုင်းပါ...",
+ "pf_pipe_error": "{{...}}၊ [[...]]၊ (သို့) အထူးစာတွဲများအတွင်းကလွဲ၍ \"|\" ကို ခွင့်မပြုပါ",
+ "pf_deletionlog": "ဖျက်ထားသည်များ မှတ်တမ်း",
+ "pf_blank_namespace": "ပင်မ",
+ "pf-select2-no-matches": "ကိုက်ညီမှုများ မရှိပါ",
+ "pf-select2-searching": "ရှာဖွေနေသည်...",
+ "pf-select2-input-too-short": "$1 သို့မဟုတ် အက္ခရာ ပိုမိုရိုက်ထည့်ပါ။",
+ "pf-maps-enteraddress": "ဤနေရာတွင် လိပ်စာထည့်ပါ",
+ "pf-maps-lookupcoordinates": "လိပ်စာသုံးပြီး ကိုဩဒိနိတ်များ တွက်ချက်ရန်",
+ "pf-adminlinks-datastructure": "ဒေတာဖွဲ့စည်းပုံ",
+ "pf-datepicker-close": "ပိတ်ရန်",
+ "pf-datepicker-prev": "ယခင်",
+ "pf-datepicker-next": "ရှေ့",
+ "pf-datepicker-today": "ယနေ့"
}
diff --git a/www/wiki/extensions/PageForms/i18n/nb.json b/www/wiki/extensions/PageForms/i18n/nb.json
index d7867a88..392cd8d9 100644
--- a/www/wiki/extensions/PageForms/i18n/nb.json
+++ b/www/wiki/extensions/PageForms/i18n/nb.json
@@ -8,7 +8,8 @@
"Nghtwlkr",
"Emilbk",
"Cocu",
- "Jon Harald Søby"
+ "Jon Harald Søby",
+ "Kingu"
]
},
"pageforms-desc": "Skjemaer for å legge til og endre semantiske data",
@@ -53,6 +54,7 @@
"pf_createtemplate_sectionsformat": "Avsnitt",
"pf_createtemplate_addfield": "Legg til felt",
"pf_createtemplate_deletefield": "Slett",
+ "multipageedit": "Rediger flere sider",
"forms": "Skjemaer",
"pf_forms_docu": "Følgende skjemaer finnes på wikien.",
"pf_forminputs_mandatory": "Obligatorisk",
diff --git a/www/wiki/extensions/PageForms/i18n/pl.json b/www/wiki/extensions/PageForms/i18n/pl.json
index c3f7bf05..a7311708 100644
--- a/www/wiki/extensions/PageForms/i18n/pl.json
+++ b/www/wiki/extensions/PageForms/i18n/pl.json
@@ -163,7 +163,7 @@
"pf_bad_email_error": "musi mieć poprawny format adresu e‐mail",
"pf_bad_number_error": "musi być poprawną liczbą",
"pf_bad_date_error": "musi być poprawną datą",
- "pf_pipe_error": "„|” nie jest dozwolone, z wyjątkiem ciągu {{...}} lub [[...]]",
+ "pf_pipe_error": "„|” nie jest dozwolone, z wyjątkiem ciągu {{...}}, [[...]] lub specjalnych znaczników",
"uploadwindow": "Okno przesyłania plików",
"pf_deletionlog": "Rejestr usunięć",
"pf-preview-header": "Podgląd formularza",
@@ -188,7 +188,7 @@
"pf-select2-input-too-short": "Podaj $1 lub więcej znaków",
"pf-select2-selection-too-big": "To pole nie może mieć więcej niż {{PLURAL:$1| $1 wartość|$1 wartości}}.",
"pf-maps-enteraddress": "Wprowadź adres",
- "pf-maps-lookupcoordinates": "Znajdź współrzędne",
+ "pf-maps-lookupcoordinates": "Oblicz współrzędne za pomocą adresu",
"pf-adminlinks-datastructure": "Struktura danych",
"pf-datepicker-close": "Zamknij",
"pf-datepicker-prev": "Poprzednie",
diff --git a/www/wiki/extensions/PageForms/i18n/pt-br.json b/www/wiki/extensions/PageForms/i18n/pt-br.json
index 281ec38c..f7efa0a2 100644
--- a/www/wiki/extensions/PageForms/i18n/pt-br.json
+++ b/www/wiki/extensions/PageForms/i18n/pt-br.json
@@ -77,6 +77,9 @@
"pf_createtemplate_sectionsformat": "Seções",
"pf_createtemplate_addfield": "Adicionar campo",
"pf_createtemplate_deletefield": "Deletar",
+ "multipageedit": "Editar várias páginas",
+ "pf_multipageedit_docu": "Selecione um dos seguintes modelos para editar todas as páginas que o contêm. Novas páginas também podem ser criadas usando o modelo selecionado.",
+ "pf_multipageedit_with-name": "Editar várias páginas para predefinição: $1",
"forms": "Formulários",
"pf_forms_docu": "Existem os seguintes formulários neste wiki.",
"pf_forminputs_mandatory": "Um valor é obrigatório para este campo",
@@ -224,7 +227,7 @@
"pf_bad_number_error": "precisa ser um número válido",
"pf_bad_date_error": "precisa ser uma data válida",
"pf_modified_input_error": "Esta alteração devia ser aprovada ou rejeitada",
- "pf_pipe_error": "\"|\" não é permitido, exceto dentro de {{...}} ou [[...]]",
+ "pf_pipe_error": "\"|\" não é permitido, exceto dentro de {{...}} ou [[...]], ou etiquetas especiais",
"uploadwindow": "Janela de upload",
"pf-simpleupload": "Enviar",
"pf_deletionlog": "Registro de eliminações",
@@ -248,9 +251,11 @@
"right-viewedittab": "Veja a aba \"{{int:edit}}\" para páginas editáveis pelo formulário",
"right-editrestrictedfields": "Editar campos restritos de formulários",
"right-createclass": "Criar novas classes semânticas",
+ "right-multipageedit": "Editar várias páginas usando uma planilha",
"action-createclass": "criar novas classes semânticas",
"action-editrestrictedfields": "editar campos restritos dos formulários",
"action-viewedittab": "veja a aba \"{{int:edit}}\" para páginas editáveis pelo formulário",
+ "action-multipageedit": "editar várias páginas usando uma planilha",
"tooltip-ca-formedit": "Edite esta página com um formulário",
"pf-select2-no-matches": "Sem correspondências",
"pf-select2-searching": "Pesquisando...",
diff --git a/www/wiki/extensions/PageForms/i18n/pt.json b/www/wiki/extensions/PageForms/i18n/pt.json
index 619af7af..041bc916 100644
--- a/www/wiki/extensions/PageForms/i18n/pt.json
+++ b/www/wiki/extensions/PageForms/i18n/pt.json
@@ -76,9 +76,12 @@
"pf_createtemplate_sectionsformat": "Secções",
"pf_createtemplate_addfield": "Adicionar campo",
"pf_createtemplate_deletefield": "Apagar",
+ "multipageedit": "Editar várias páginas",
+ "pf_multipageedit_docu": "Selecione uma das seguintes predefinições, para editar todas as páginas que a contêm. Também podem ser criadas páginas novas usando a predefinição selecionada.",
+ "pf_multipageedit_with-name": "Editar várias páginas para a predefinição: $1",
"forms": "Formulários",
"pf_forms_docu": "Os seguintes formulários existem na wiki.",
- "pf_forminputs_mandatory": "Obrigatório",
+ "pf_forminputs_mandatory": "É obrigatório introduzir um valor nesta entrada",
"pf_forminputs_restricted": "Esta entrada só pode ser editada por administradores",
"pf_forminputs_class": "O atributo HTML \"class\" para esta entrada",
"pf_forminputs_default": "O valor por omissão desta entrada",
@@ -87,7 +90,7 @@
"pf_forminputs_size": "O tamanho deste campo de texto, em caracteres",
"pf_forminputs_maxlength": "O comprimento máximo permitido para o texto deste campo",
"pf_forminputs_placeholder": "Texto de ajuda que aparece na caixa de entrada até que o utilizador clique a caixa",
- "pf_forminputs_uploadable": "Colocar uma ligação \"{{int:upload}}\" ao lado desta entrada",
+ "pf_forminputs_uploadable": "Colocar uma hiperligação \"{{int:upload}}\" ao lado desta entrada",
"pf_forminputs_change_file": "Alterar ficheiro",
"pf_forminputs_defaultfilename": "O nome de ficheiro por omissão, dos ficheiros enviados",
"pf_forminputs_rows": "O número de linhas desta entrada",
@@ -223,7 +226,7 @@
"pf_bad_number_error": "tem de ser um número válido",
"pf_bad_date_error": "tem de ser uma data válida",
"pf_modified_input_error": "Esta alteração devia ser aprovada ou rejeitada",
- "pf_pipe_error": "\"|\" não é permitido, exceto entre {{...}} ou [[...]]",
+ "pf_pipe_error": "\"|\" não é permitido, exceto entre {{...}}, [[...]] ou elementos especiais",
"uploadwindow": "Janela de carregamento",
"pf-simpleupload": "Carregar",
"pf_deletionlog": "Registo de eliminações",
@@ -247,9 +250,11 @@
"right-viewedittab": "Ver o separador \"{{int:edit}}\" nas páginas editáveis por formulário",
"right-editrestrictedfields": "Editar os campos restritos dos formulários",
"right-createclass": "Criar novas classes semânticas",
+ "right-multipageedit": "Editar várias páginas usando uma folha de cálculo",
"action-createclass": "criar novas classes semânticas",
"action-editrestrictedfields": "editar os campos restritos dos formulários",
"action-viewedittab": "ver o separador \"{{int:edit}}\" nas páginas editáveis por formulário",
+ "action-multipageedit": "editar várias páginas usando uma folha de cálculo",
"tooltip-ca-formedit": "Editar esta página com um formulário",
"pf-select2-no-matches": "Sem correspondências",
"pf-select2-searching": "A pesquisar...",
diff --git a/www/wiki/extensions/PageForms/i18n/qqq.json b/www/wiki/extensions/PageForms/i18n/qqq.json
index b0b91ca2..7efe6486 100644
--- a/www/wiki/extensions/PageForms/i18n/qqq.json
+++ b/www/wiki/extensions/PageForms/i18n/qqq.json
@@ -82,6 +82,9 @@
"pf_createtemplate_sectionsformat": "{{Identical|Section}}",
"pf_createtemplate_addfield": "Button",
"pf_createtemplate_deletefield": "{{Identical|Delete}}",
+ "multipageedit": "{{doc-special|MultiPageEdit}}",
+ "pf_multipageedit_docu": "Header describing the special page",
+ "pf_multipageedit_with-name": "Used as page title. Parameters:\n* $1 - template name",
"forms": "{{doc-special|Forms}}\n{{Identical|Form}}",
"pf_forms_docu": "Header describing the special page.",
"pf_forminputs_mandatory": "Longer explanation of an option when creating a form\n\nSee also:\n* {{msg-mw|pf forminputs restricted}}\n* {{msg-mw|pf createform hiddensection}}",
@@ -254,9 +257,11 @@
"right-viewedittab": "{{doc-right|viewedittab}}\nRefers to {{msg-mw|Edit}}.",
"right-editrestrictedfields": "{{doc-right|editrestrictedfields}}",
"right-createclass": "{{doc-right|createclass}}",
+ "right-multipageedit": "{{doc-right|multipageedit}}",
"action-createclass": "{{doc-action|createclass}}",
"action-editrestrictedfields": "{{doc-action|editrestrictedfields}}",
"action-viewedittab": "{{doc-action|viewedittab}}\nRefers to {{msg-mw|Edit}}.",
+ "action-multipageedit": "{{doc-action|multipageedit}}",
"tooltip-ca-formedit": "Tooltip shown when the cursor hovers over the \"Edit with form\" tab",
"accesskey-ca-formedit": "{{doc-accesskey}}",
"pf-select2-no-matches": "A message that is displayed when nothing is matched in Select2 autocompletion.",
diff --git a/www/wiki/extensions/PageForms/i18n/roa-tara.json b/www/wiki/extensions/PageForms/i18n/roa-tara.json
index 6e2e96c3..02be653f 100644
--- a/www/wiki/extensions/PageForms/i18n/roa-tara.json
+++ b/www/wiki/extensions/PageForms/i18n/roa-tara.json
@@ -16,6 +16,7 @@
"pf_createtemplate_plainformat": "Teste semblice",
"pf_createtemplate_addfield": "Aggiunge 'u cambe",
"pf_createtemplate_deletefield": "Scangìlle",
+ "multipageedit": "Cange cchiù pàggene",
"forms": "Module",
"createform": "Ccreje 'nu module",
"pf-createform-with-name": "Ccreje 'u module: $1",
diff --git a/www/wiki/extensions/PageForms/i18n/ru.json b/www/wiki/extensions/PageForms/i18n/ru.json
index d6d256ec..5806847e 100644
--- a/www/wiki/extensions/PageForms/i18n/ru.json
+++ b/www/wiki/extensions/PageForms/i18n/ru.json
@@ -19,7 +19,9 @@
"INS Pirat",
"Kareyac",
"Alexey zakharenkov",
- "Redredsonia"
+ "Redredsonia",
+ "Vlad5250",
+ "Shaleych"
]
},
"pageforms-desc": "Формы для создания и правки вики-страниц",
@@ -48,6 +50,8 @@
"pf_createtemplate_displaylabel": "Отображаемая надпись:",
"pf_createtemplate_semanticproperty": "Семантическое свойство:",
"pf_createtemplate_fieldislist": "Поле содержит список значений",
+ "pf_createtemplate_fieldishierarchy": "Поле содержит иерархию",
+ "pf_createtemplate_hierarchystructureplaceholder": "*Введите\n**значения\n***иерархии\n***в\n**таком\n***формате,\n*как\n**этот",
"pf_createtemplate_delimiter": "Разделитель:",
"pf_createtemplate_aggregation": "Соединение",
"pf_createtemplate_aggregationdesc": "Чтобы вывести на любую страницу, использующую этот шаблон, все страницы, у которых заданное свойство указывает на эту страницу, укажите соответствующее свойство ниже:",
@@ -59,6 +63,9 @@
"pf_createtemplate_sectionsformat": "Разделы",
"pf_createtemplate_addfield": "Добавить поле",
"pf_createtemplate_deletefield": "Удалить",
+ "multipageedit": "Редактировать несколько страниц",
+ "pf_multipageedit_docu": "Выберите один из следующих шаблонов, чтобы редактировать все страницы, содержащие этот шаблон. Вы также можете создавать новые страницы, используя выбранный шаблон.",
+ "pf_multipageedit_with-name": "Редактировать несколько страниц с шаблоном: $1",
"forms": "Формы",
"pf_forms_docu": "В вики существуют следующие формы.",
"pf_forminputs_mandatory": "Обязательное",
@@ -71,6 +78,7 @@
"pf_forminputs_maxlength": "Максимально допустимая длина текста в этом поле",
"pf_forminputs_placeholder": "Справочный текст, который появляется в поле ввода до тех пор, пока пользователь не перейдет на него",
"pf_forminputs_uploadable": "Добавить ссылку «{{int:upload}}» рядом с этим полем",
+ "pf_forminputs_change_file": "Изменить файл",
"pf_forminputs_defaultfilename": "Имя файла по умолчанию для загруженных файлов",
"pf_forminputs_rows": "Размер поля в строках",
"pf_forminputs_cols": "Размер поля в столбцах",
@@ -139,6 +147,7 @@
"pf_createclass_missingvalues": "Не все требуемые поля были заполнены.",
"pf_createclass_success": "Указанные страницы будут созданы.",
"pf_createclass_create": "Создать",
+ "pf_createclass_ishierarchy": "Иерархия?",
"formstart": "Добавить страницу с формой",
"pf_formstart_badform": "Ошибка. Форма не найдена на $1",
"pf_formstart_badtitle": "Ошибка. «$1» — недопустимое название страницы.",
@@ -147,6 +156,8 @@
"pf_formstart_createoredit": "Создать или править",
"formedit": "Редактировать с помощью формы",
"pf-formedit-selectform": "Выберите форму для создания этой страницы:",
+ "pf-formedit-mainforms": "Основные формы:",
+ "pf-formedit-otherforms": "Другие формы:",
"pf-formedit-donotuseform": "Создать страницу без формы.",
"pf_formedit_createtitle": "Создание $1: $2",
"pf_formedit_createtitlenotarget": "Создать $1",
@@ -198,6 +209,7 @@
"pf_bad_email_error": "должно содержать адрес почты соответствующего формата",
"pf_bad_number_error": "должно быть числом",
"pf_bad_date_error": "должно быть датой",
+ "pf_pipe_error": "Знак «|» не разрешён, кроме в рамках {{...}} или [[...]]",
"uploadwindow": "Окно загрузки",
"pf-simpleupload": "Загрузить",
"pf_deletionlog": "Журнал удалений",
@@ -218,12 +230,15 @@
"pf_category_hasdefaultform": "Эта категория использует форму $1.",
"pf_category_desc": "Это категория $1.",
"pf_blank_namespace": "Основное",
- "right-viewedittab": "доступ к вкладке «{{int:edit}}» для страниц, редактируемых при помощи формы",
+ "right-viewedittab": "отображение вкладки «{{int:edit}}» для страниц, редактируемых при помощи формы",
"right-editrestrictedfields": "правка защищённых полей формы",
"right-createclass": "создание новых семантических классов",
+ "right-multipageedit": "редактирование нескольких страниц с использованием электронной таблицы",
"action-createclass": "создать новый семантический класс",
"action-editrestrictedfields": "правка защищённых полей формы",
"action-viewedittab": "доступ к вкладке «{{int:edit}}» для страниц, редактируемых при помощи формы",
+ "action-multipageedit": "редактирование нескольких страниц с использованием электронной таблицы",
+ "tooltip-ca-formedit": "Редактировать эту страницу формой",
"pf-select2-no-matches": "Cовпадений не найдено",
"pf-select2-searching": "Поиск…",
"pf-select2-input-too-short": "Пожалуйста, введите $1 или более символов",
@@ -250,5 +265,7 @@
"pf-regexp-baseprefix": "Префикс для параметров базового типа.",
"pf-regexp-orchar": "ИЛИ-символ, который используется в регулярном выражении вместо |. По умолчанию «!»",
"pf-regexp-inverse": "Если задано, входные данные не должны соответствовать регулярному выражению. Т.е. регулярное выражение инвертируется.",
- "pf-regexp-message": "Отображаемое сообщение об ошибке, если сопоставление потерпит неудачу. По умолчанию \"Wrong format!\" (или эквивалент для текущей локали)"
+ "pf-regexp-message": "Отображаемое сообщение об ошибке, если сопоставление потерпит неудачу. По умолчанию \"Wrong format!\" (или эквивалент для текущей локали)",
+ "pf-missingconcept": "Не удалось найти концепцию: $1",
+ "pf-invalidexturl": "Недопустимое значение внешнего URL-адреса."
}
diff --git a/www/wiki/extensions/PageForms/i18n/sd.json b/www/wiki/extensions/PageForms/i18n/sd.json
index 39a37139..cf8c55ad 100644
--- a/www/wiki/extensions/PageForms/i18n/sd.json
+++ b/www/wiki/extensions/PageForms/i18n/sd.json
@@ -1,9 +1,11 @@
{
"@metadata": {
"authors": [
- "Mehtab ahmed"
+ "Mehtab ahmed",
+ "Tweety"
]
},
+ "pf_createtemplate_plainformat": "سدا اکر",
"pf-datepicker-close": "بند ڪريو",
"pf-datepicker-prev": "پويون"
}
diff --git a/www/wiki/extensions/PageForms/i18n/skr.json b/www/wiki/extensions/PageForms/i18n/skr-arab.json
index be53a3d2..d006704d 100644
--- a/www/wiki/extensions/PageForms/i18n/skr.json
+++ b/www/wiki/extensions/PageForms/i18n/skr-arab.json
@@ -1,9 +1,5 @@
{
- "@metadata": {
- "authors": [
- "Saraiki"
- ]
- },
+ "@metadata": [],
"pf-autoedit-wait": "رک ونڄو",
"pf-datepicker-close": "بند کرو"
}
diff --git a/www/wiki/extensions/PageForms/i18n/sr-ec.json b/www/wiki/extensions/PageForms/i18n/sr-ec.json
index 3be9f8de..92cfd477 100644
--- a/www/wiki/extensions/PageForms/i18n/sr-ec.json
+++ b/www/wiki/extensions/PageForms/i18n/sr-ec.json
@@ -10,72 +10,82 @@
"Obsuser",
"Prevodim",
"Acamicamacaraca",
- "BadDog"
+ "BadDog",
+ "Zoranzoki21"
]
},
- "specialpages-group-pf_group": "Семантички обрасци",
- "createproperty": "Прављење особине",
+ "specialpages-group-pf_group": "Обрасци странице",
+ "createproperty": "Прављење својства",
"pf_createproperty_allowedvalsinput": "Ако желите да овој особини буде дозвољено да има само одређене вредности, унесите списак дозвољених вредност, одвојених зарезима (ако вредност садржи зарез, пишите га као „\\,“):",
- "pf_createproperty_propname": "Име особине:",
- "pf_createproperty_proptype": "Врста:",
+ "pf_createproperty_propname": "Име својства:",
+ "pf_createproperty_proptype": "Тип:",
"templates": "Шаблони",
- "pf_templates_docu": "Следећи шаблони постоје у Викију.",
+ "pf_templates_docu": "Следећи шаблони постоје на викију.",
"pf_templates_definescat": "дефинише категорију: $1",
"createtemplate": "Прављење шаблона",
"pf_createtemplate_namelabel": "Име шаблона:",
- "pf_createtemplate_categorylabel": "Категорија дефинисана шаблоном (необавезно):",
+ "pf_createtemplate_categorylabel": "Категорија дефинисана шаблоном (опционално):",
"pf_createtemplate_templatefields": "Поља шаблона",
"pf_createtemplate_fieldname": "Име поља:",
- "pf_createtemplate_displaylabel": "Натпис за приказ:",
+ "pf_createtemplate_displaylabel": "Прикажи ознаку:",
"pf_createtemplate_semanticproperty": "Семантичко својство:",
"pf_createtemplate_fieldislist": "Ово поље може да садржи списак вредности, одвојених зарезима",
"pf_createtemplate_hierarchystructureplaceholder": "*Унеси\n**вредности\n***за\n***хијерархију\n**у\n***формату\n*попут\n**овог",
"pf_createtemplate_aggregation": "Агрегација",
- "pf_createtemplate_aggregationlabel": "Наслов листе:",
+ "pf_createtemplate_aggregationlabel": "Наслов списка:",
"pf_createtemplate_outputformat": "Излазни формат:",
"pf_createtemplate_standardformat": "Табела",
"pf_createtemplate_addfield": "Додај поље",
- "pf_createtemplate_deletefield": "Обриши",
+ "pf_createtemplate_deletefield": "Избриши",
+ "multipageedit": "Уређивање више страница",
+ "pf_multipageedit_docu": "Изаберите један од следећих шаблона да бисте уређивали све странице које га садрже. Нове странице такође могу да се направе његовим коришћењем.",
+ "pf_multipageedit_with-name": "Уређивање више страница за шаблон: $1",
"forms": "Образци",
- "pf_forms_docu": "Следеће форме постоје на Викију.",
+ "pf_forms_docu": "Следећи обрсци постоје на викију.",
"createform": "Прављење образца",
- "pf_createform_nameinput": "Име форме",
+ "pf_createform_nameinput": "Име обрасца",
"pf_createform_template": "Шаблон:",
"pf_createform_field": "Поље:",
"pf_createform_fieldprop": "Ово поље дефинише особину $1, типа $2.",
- "pf_createform_inputtype": "Врста уноса:",
+ "pf_createform_inputtype": "Тип уноса:",
"pf_createform_inputtypedefault": "(подразумевано)",
- "pf_createform_formlabel": "Из лабеле:",
+ "pf_createform_formlabel": "Из ознаке:",
"pf_createform_hidden": "Сакривено",
- "pf_createform_removetemplate": "Обриши шаблон",
+ "pf_createform_removetemplate": "Уклони шаблон",
"pf_createform_addtemplate": "Додај шаблон:",
"pf_createform_atend": "На крају",
"pf_createform_add": "Додај",
- "pf_createform_choosefield": "Изабери поље за додавање",
+ "pf_createform_choosefield": "Одабери поље за додавање",
"pf_createform_before": "Пре шаблона:",
"createcategory": "Прављење категорије",
"pf_createcategory_name": "Име категорије:",
- "pf_createcategory_defaultform": "Подразумевана форма:",
+ "pf_createcategory_defaultform": "Подразумевани образац:",
"createclass": "Прављење класе",
"pf_createclass_allowedvalues": "Дозвољене вредности:",
"pf_createclass_listofvalues": "Списак вредности?",
"pf_createclass_ishierarchy": "Хијерархија?",
"formstart": "Почетак образца",
- "pf_formstart_createoredit": "Направи или измени",
- "formedit": "Измени формом",
- "pf_formedit_createtitle": "Направи $1: $2",
+ "pf_formstart_createoredit": "Направи или уреди",
+ "formedit": "Уреди обрасцем",
+ "pf_formedit_createtitle": "Прављење $1: $2",
+ "pf_formedit_createtitlenotarget": "Прављење $1",
+ "pf_viewform": "Образац",
"pf_editsource": "Уреди извор",
- "pf_formedit_edittitle": "Измени $1: $2",
+ "pf_formedit_edittitle": "Уређивање $1: $2",
"pf_formedit_remove": "Уклони",
"pf_formedit_none": "Нема",
"pf_autoedit_anoneditwarning": "Упозорење: Нисте пријављени. Ако објавите страницу, Ваша IP адреса ће бити јавно видљива у њеној историји измена и другде.",
"runquery": "Покретање упита",
- "pf_bad_number_error": "мора бити исправан број",
- "pf_bad_date_error": "мора бити исправан датум",
+ "pf_bad_number_error": "мора да буде важећи број",
+ "pf_bad_date_error": "мора да буде важећи датум",
+ "pf_pipe_error": "Знак „|” није дозвољен, осим унутар {{...}}, [[...]] или посебних тагова",
"uploadwindow": "Прозор за отпремање",
- "pf_deletionlog": "Историја брисања",
+ "pf_deletionlog": "Дневник брисања",
"pf_form_freetextlabel": "Слободан текст",
- "action-viewedittab": "преглед картице „{{int:edit}}” за странице које су уредиве",
+ "right-multipageedit": "уређивање више страница користећи унакрсну табелу",
+ "action-editrestrictedfields": "уређујете ограничења из поља",
+ "action-viewedittab": "прегледате картицу „{{int:edit}}” за странице које су уредиве путем обрасца",
+ "action-multipageedit": "уређујете више страница користећи унакрсну табелу",
"pf-select2-selection-too-big": "Ово поље не може да садржи више од {{PLURAL:$1|$1 вредности}}.",
"pf-datepicker-dateformatlong": "d MM yy",
"pf-datepicker-dateformatshort": "dd.mm.yy",
diff --git a/www/wiki/extensions/PageForms/i18n/sr-el.json b/www/wiki/extensions/PageForms/i18n/sr-el.json
index d58fde45..0e74b190 100644
--- a/www/wiki/extensions/PageForms/i18n/sr-el.json
+++ b/www/wiki/extensions/PageForms/i18n/sr-el.json
@@ -58,7 +58,7 @@
"pf_formstart_createoredit": "Napravi ili izmeni",
"formedit": "Izmeni formom",
"pf_formedit_createtitle": "Napravi $1: $2",
- "pf_editsource": "Uredi izvor",
+ "pf_editsource": "Uredi izvorni kod",
"pf_formedit_edittitle": "Izmeni $1: $2",
"pf_formedit_remove": "Ukloni",
"pf_formedit_none": "Nema",
diff --git a/www/wiki/extensions/PageForms/i18n/sv.json b/www/wiki/extensions/PageForms/i18n/sv.json
index a6f733f1..cf4bed9f 100644
--- a/www/wiki/extensions/PageForms/i18n/sv.json
+++ b/www/wiki/extensions/PageForms/i18n/sv.json
@@ -49,6 +49,7 @@
"pf_createtemplate_sectionsformat": "Avsnitt",
"pf_createtemplate_addfield": "Lägg till fält",
"pf_createtemplate_deletefield": "Radera",
+ "multipageedit": "Redigera flera sidor",
"forms": "Formulär",
"pf_forms_docu": "Följande formulär finns på wikin.",
"pf_forminputs_mandatory": "Obligatorisk",
diff --git a/www/wiki/extensions/PageForms/i18n/tr.json b/www/wiki/extensions/PageForms/i18n/tr.json
index cfe1facd..cdc1c922 100644
--- a/www/wiki/extensions/PageForms/i18n/tr.json
+++ b/www/wiki/extensions/PageForms/i18n/tr.json
@@ -8,7 +8,8 @@
"Vito Genovese",
"Sucsuzz",
"Rapsar",
- "Alikaan"
+ "Alikaan",
+ "Hedda"
]
},
"pageforms-desc": "Semantik veri ekleme ve düzenleme için formlar",
@@ -39,6 +40,7 @@
"pf_createtemplate_deletefield": "Sil",
"forms": "Formlar",
"pf_forminputs_mandatory": "Zorunlu",
+ "pf_forminputs_hideroot": "Ana kategoriyi gizle",
"pf_forminputs_checkboxes_select_all": "Tümünü seç",
"pf_forminputs_checkboxes_select_none": "Hiçbirini seçme",
"createform": "Form oluştur",
diff --git a/www/wiki/extensions/PageForms/i18n/tt-cyrl.json b/www/wiki/extensions/PageForms/i18n/tt-cyrl.json
index 48359501..2f12a1d4 100644
--- a/www/wiki/extensions/PageForms/i18n/tt-cyrl.json
+++ b/www/wiki/extensions/PageForms/i18n/tt-cyrl.json
@@ -1,8 +1,10 @@
{
"@metadata": {
"authors": [
- "Ерней"
+ "Ерней",
+ "Ильнар"
]
},
- "pf_createform_inputtypedefault": "(килешү буенча)"
+ "pf_createform_inputtypedefault": "(килешү буенча)",
+ "formedit": "Форма ярдәмендә үзгәртү"
}
diff --git a/www/wiki/extensions/PageForms/i18n/zh-hans.json b/www/wiki/extensions/PageForms/i18n/zh-hans.json
index d637f234..4efe6e00 100644
--- a/www/wiki/extensions/PageForms/i18n/zh-hans.json
+++ b/www/wiki/extensions/PageForms/i18n/zh-hans.json
@@ -14,7 +14,8 @@
"Hudafu",
"NigelSoft",
"Apflu",
- "아라"
+ "아라",
+ "夢蝶葬花"
]
},
"pageforms-desc": "用于创建和编辑wiki页面的表单",
@@ -78,6 +79,8 @@
"pf_createtemplate_sectionsformat": "小节",
"pf_createtemplate_addfield": "添加字段",
"pf_createtemplate_deletefield": "删除",
+ "multipageedit": "编辑多个页面:",
+ "pf_multipageedit_docu": "选择以下模板之一以编辑包含它的所有页面。也可以使用所选模板创建新页面。",
"forms": "表单",
"pf_forms_docu": "当前wiki之中存在下列表单。",
"pf_forminputs_mandatory": "必须为该输入项录入取值",
diff --git a/www/wiki/extensions/PageForms/i18n/zh-hant.json b/www/wiki/extensions/PageForms/i18n/zh-hant.json
index 78f24d05..889550fa 100644
--- a/www/wiki/extensions/PageForms/i18n/zh-hant.json
+++ b/www/wiki/extensions/PageForms/i18n/zh-hant.json
@@ -10,11 +10,34 @@
"Wrightbus",
"Cwlin0416",
"LNDDYL",
- "아라"
+ "아라",
+ "Kly"
]
},
- "pageforms-desc": "可用來增加與編輯語意資料的表單",
- "specialpages-group-pf_group": "語意表單",
+ "pageforms-desc": "可用來建立與編輯 wiki 頁面的表單",
+ "specialpages-group-pf_group": "Page Forms",
+ "apihelp-pfautocomplete-description": "透過 Page Forms 擴充所使用的自動化功能。",
+ "apihelp-pfautocomplete-summary": "透過 Page Forms 擴充所使用的自動化功能。",
+ "apihelp-pfautocomplete-param-limit": "回傳結果的限制數目",
+ "apihelp-pfautocomplete-param-substr": "要自動完成的子字串",
+ "apihelp-pfautocomplete-param-property": "內容值會自動完成的語意 MediaWiki 屬性",
+ "apihelp-pfautocomplete-param-category": "頁面會自動完成的分類",
+ "apihelp-pfautocomplete-param-concept": "頁面會自動完成的語意 MediaWiki \"概念\"內容",
+ "apihelp-pfautocomplete-param-cargo_table": "由 Cargo 擴充所定義,內容值會自動完成的資料庫表格",
+ "apihelp-pfautocomplete-param-cargo_field": "內容值會自動完成的 Cargo 表格欄位",
+ "apihelp-pfautocomplete-param-field_is_array": "所指定 Cargo 是否能包含陣列值",
+ "apihelp-pfautocomplete-param-namespace": "頁面會自動完成的命名空間",
+ "apihelp-pfautocomplete-param-external_url": "來自所要獲取值的外部 URL 別名",
+ "apihelp-pfautocomplete-param-baseprop": "所要檢查的在表格裡先前語意 MediaWiki 之屬性",
+ "apihelp-pfautocomplete-param-base_cargo_table": "所要檢查的在表格裡用於先前欄位之 Cargo 表格",
+ "apihelp-pfautocomplete-param-base_cargo_field": "所要檢查的在表格裡用於先前欄位之 Cargo 表格",
+ "apihelp-pfautocomplete-param-basevalue": "用於檢查先前屬性或欄位的值",
+ "apihelp-pfautoedit-description": "使用透過 Page Forms 擴充所定義的表單來建立或編輯頁面。",
+ "apihelp-pfautoedit-summary": "使用透過 Page Forms 擴充所定義的表單來建立或編輯頁面。",
+ "apihelp-pfautoedit-param-form": "要使用的 Page Forms 表單",
+ "apihelp-pfautoedit-param-target": "要建立或編輯的頁面名稱",
+ "apihelp-pfautoedit-param-query": "查詢字串",
+ "apihelp-pfautoedit-param-preload": "要在表單裡重新載入的頁面名稱",
"createproperty": "建立屬性",
"pf-createproperty-with-name": "建立屬性:$1",
"pf_createproperty_allowedvalsinput": "只允許使用特定的數值,請輸入數值清單,以逗號分隔 (若數值中含有逗號,請取代該逗號為 \"\\,\"):",
@@ -30,13 +53,17 @@
"pf_createtemplate_multipleinstance": "此模板可被其他頁面引用多次。",
"pf_createtemplate_connectingproperty": "頁面其餘部份連結到此模板欄位的屬性名稱:",
"pf_createtemplate_categorylabel": "使用模板定義的分類 (選填) :",
- "pf_createtemplate_cargotablelabel": "由模板定義的 Cargo 表格 (選填):",
+ "pf_createtemplate_usecargo": "使用 Cargo 擴充功能來儲存此模板的資料",
+ "pf_createtemplate_cargotablelabel": "由模板定義的 Cargo 表格名稱:",
"pf_createtemplate_templatefields": "模板欄位",
"pf_createtemplate_fieldsdesc": "要讓模板中的欄位可不必使用欄位名稱,只需輸入欄位的索引 (如:1、2、3,等) 做為名稱,替代實際的名稱。",
"pf_createtemplate_fieldname": "欄位名稱:",
"pf_createtemplate_displaylabel": "顯示標籤:",
"pf_createtemplate_semanticproperty": "語意屬性:",
"pf_createtemplate_fieldislist": "欄位可使用多個數值",
+ "pf_createtemplate_fieldishierarchy": "含有等級的欄位",
+ "pf_createtemplate_hierarchystructureplaceholder": "* 輸入\n** 等級\n*** 的值\n*** 以\n** 某個\n*** 格式\n* 像是\n** 這樣",
+ "pf_createproperty_allowedvalsforhierarchy": "允許用於等級的值:",
"pf_createtemplate_delimiter": "分隔附號:",
"pf_createtemplate_aggregation": "彙整",
"pf_createtemplate_aggregationdesc": "為了要可以列出所有使用此模板的頁面,所有的頁面均含有特定的屬性指向該頁面,請在下方指定適合的屬性:",
@@ -48,6 +75,9 @@
"pf_createtemplate_sectionsformat": "章節",
"pf_createtemplate_addfield": "增加欄位",
"pf_createtemplate_deletefield": "刪除",
+ "multipageedit": "編輯多個頁面",
+ "pf_multipageedit_docu": "選擇以下模板其一,來編輯所有包含該模板的頁面。新頁面可透過使用所選的模板來創建。",
+ "pf_multipageedit_with-name": "替模板:$1編輯多個頁面",
"forms": "表單",
"pf_forms_docu": "下列為 Wiki 已有的表單。",
"pf_forminputs_mandatory": "此輸入欄位必須填寫數值",
@@ -60,6 +90,7 @@
"pf_forminputs_maxlength": "此欄位允許填寫的文字長度上限",
"pf_forminputs_placeholder": "使用者尚未點選輸入欄位前持續顯示說明文字",
"pf_forminputs_uploadable": "此輸入欄位旁放置 \"{{int:upload}}\" 連結",
+ "pf_forminputs_change_file": "變更檔案",
"pf_forminputs_defaultfilename": "上傳檔案預設的檔案名稱",
"pf_forminputs_rows": "此欄位的列數",
"pf_forminputs_cols": "此欄位的欄數",
@@ -85,6 +116,9 @@
"pf_forminputs_checkboxes_select_all": "全部選擇",
"pf_forminputs_checkboxes_select_none": "全部取消",
"pf_forminputs_maxvalues": "欄位值允許填寫的數量限制",
+ "pf_forminputs_starwidth": "每顆星的寬度(與高度)",
+ "pf_forminputs_numstars": "要顯示的星級數目",
+ "pf_forminputs_allowhalfstars": "是否允許半顆星,例如像是評比為 3.5 顆星",
"createform": "建立表單",
"pf-createform-with-name": "建立表單:$1",
"pf_createform_nameinput": "表單名稱",
@@ -128,6 +162,7 @@
"pf_createclass_missingvalues": "尚未填寫所有必填欄位。",
"pf_createclass_success": "將會建立指定的頁面。",
"pf_createclass_create": "建立",
+ "pf_createclass_ishierarchy": "等級?",
"formstart": "使用表單",
"pf_formstart_badform": "錯誤:在頁面 \"$1\" 上沒有找到表單。",
"pf_formstart_badtitle": "錯誤:\"$1\" 不是有效的頁面標題。",
@@ -136,6 +171,8 @@
"pf_formstart_createoredit": "建立或編輯",
"formedit": "使用表單編輯",
"pf-formedit-selectform": "選擇要用來建立此頁面的表單:",
+ "pf-formedit-mainforms": "主表單:",
+ "pf-formedit-otherforms": "其它表單:",
"pf-formedit-donotuseform": "不使用表單建立頁面。",
"pf_formedit_createtitle": "建立 $1:$2",
"pf_formedit_createtitlenotarget": "建立 $1",
@@ -187,7 +224,10 @@
"pf_bad_email_error": "必須使用有效的電子郵件地址格式",
"pf_bad_number_error": "必須為有效的數字",
"pf_bad_date_error": "必須為有效的日期",
+ "pf_modified_input_error": "此變動應被允許或拒絕",
+ "pf_pipe_error": "除了在 {{...}} 或 [[...]] 以內外,不允許使用 \"|\"",
"uploadwindow": "上傳視窗",
+ "pf-simpleupload": "上傳",
"pf_deletionlog": "刪除日誌",
"pf-preview-header": "表單預覽",
"pf-preview-note": "這是該表單使用時的樣子:",
@@ -209,15 +249,18 @@
"right-viewedittab": "檢視 \"{{int:edit}}\" 頁籤來查看可使用表單編輯的頁面",
"right-editrestrictedfields": "編輯受限制的表單欄位",
"right-createclass": "建立新的語義類別",
+ "right-multipageedit": "使用電子試算表來編輯多個頁面",
"action-createclass": "建立新的語義類別",
"action-editrestrictedfields": "編輯受限制的表單欄位",
"action-viewedittab": "檢視 \"{{int:edit}}\" 頁籤來查看可使用表單編輯的頁面",
+ "action-multipageedit": "使用電子試算表來編輯多個頁面",
+ "tooltip-ca-formedit": "以表單編輯此頁面",
"pf-select2-no-matches": "無符何條件的結果",
"pf-select2-searching": "搜尋中...",
"pf-select2-input-too-short": "請輸入 $1 個或更多的字元。",
"pf-select2-selection-too-big": "此欄位不可使用超過 {{PLURAL:$1|$1 個值|$1 個值}}。",
"pf-maps-enteraddress": "在此處輸入地址",
- "pf-maps-lookupcoordinates": "尋找座標",
+ "pf-maps-lookupcoordinates": "使用地址計算座標",
"pf-adminlinks-datastructure": "資料結構",
"pf-datepicker-close": "關閉",
"pf-datepicker-prev": "上一個",
@@ -238,5 +281,12 @@
"pf-regexp-baseprefix": "基本類型參數的字首。",
"pf-regexp-orchar": "正則表達式當中所要使用的邏輯或字符,而不是“|”。默認值為\"!\"。",
"pf-regexp-inverse": "如果加以設置,輸入要有效的話,不得與正則表達式相匹配。也就是說,正則表達式是倒轉的。",
- "pf-regexp-message": "匹配失敗時所要顯示的錯誤信息。默認值為\"格式錯誤!\"(或者是當前區域的等效取值)。"
+ "pf-regexp-message": "匹配失敗時所要顯示的錯誤信息。默認值為\"格式錯誤!\"(或者是當前區域的等效取值)。",
+ "pf-missingconcept": "找不到概念內容:$1",
+ "pf-missingnamespace": "找不到命名空間:$1",
+ "pf-nocompletionurls": "此 wiki 上沒有指定用於自動完成的外部 URL。",
+ "pf-invalidexturl": "無效的外部 URL 值。",
+ "pf-blankexturl": "空白的外部 URL 值。",
+ "pf-externalpageempty": "外部頁面未包含內容。",
+ "pf-externalpagebadjson": "不可在外部頁面解析 JSON。"
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_AutocompleteAPI.php b/www/wiki/extensions/PageForms/includes/PF_AutocompleteAPI.php
index 7beac298..d822619a 100644
--- a/www/wiki/extensions/PageForms/includes/PF_AutocompleteAPI.php
+++ b/www/wiki/extensions/PageForms/includes/PF_AutocompleteAPI.php
@@ -191,7 +191,12 @@ class PFAutocompleteAPI extends ApiBase {
$sqlOptions = array();
$sqlOptions['LIMIT'] = $wgPageFormsMaxAutocompleteValues;
- $property = SMWPropertyValue::makeUserProperty( $property_name );
+ if ( method_exists( 'SMW\DataValueFactory', 'newPropertyValueByLabel' ) ) {
+ // SMW 3.0+
+ $property = SMW\DataValueFactory::getInstance()->newPropertyValueByLabel( $property_name );
+ } else {
+ $property = SMWPropertyValue::makeUserProperty( $property_name );
+ }
$propertyHasTypePage = ( $property->getPropertyTypeID() == '_wpg' );
$property_name = str_replace( ' ', '_', $property_name );
$conditions = array( 'p_ids.smw_title' => $property_name );
@@ -237,7 +242,12 @@ class PFAutocompleteAPI extends ApiBase {
}
if ( !is_null( $basePropertyName ) ) {
- $baseProperty = SMWPropertyValue::makeUserProperty( $basePropertyName );
+ if ( method_exists( 'SMW\DataValueFactory', 'newPropertyValueByLabel' ) ) {
+ $baseProperty = SMW\DataValueFactory::getInstance()->newPropertyValueByLabel( $basePropertyName );
+ } else {
+ // SMW 3.0+
+ $baseProperty = SMWPropertyValue::makeUserProperty( $basePropertyName );
+ }
$basePropertyHasTypePage = ( $baseProperty->getPropertyTypeID() == '_wpg' );
$basePropertyName = str_replace( ' ', '_', $basePropertyName );
@@ -348,7 +358,8 @@ class PFAutocompleteAPI extends ApiBase {
$cargoField,
$havingStr = null,
$cargoField,
- $wgPageFormsMaxAutocompleteValues
+ $wgPageFormsMaxAutocompleteValues,
+ $offsetStr = 0
);
$cargoFieldAlias = str_replace( '_', ' ', $cargoField );
$queryResults = $sqlQuery->run();
diff --git a/www/wiki/extensions/PageForms/includes/PF_AutoeditAPI.php b/www/wiki/extensions/PageForms/includes/PF_AutoeditAPI.php
index 5d7026e7..b4c0767f 100644
--- a/www/wiki/extensions/PageForms/includes/PF_AutoeditAPI.php
+++ b/www/wiki/extensions/PageForms/includes/PF_AutoeditAPI.php
@@ -38,6 +38,7 @@ class PFAutoeditAPI extends ApiBase {
private $mOptions = array();
private $mAction;
private $mStatus;
+ private $mIsAutoEdit = false;
/**
* Converts an options string into an options array and stores it
@@ -165,6 +166,7 @@ class PFAutoeditAPI extends ApiBase {
} elseif ( array_key_exists( 'action', $this->mOptions ) ) {
switch ( $this->mOptions['action'] ) {
case 'pfautoedit' :
+ $this->mIsAutoEdit = true;
$this->mAction = self::ACTION_SAVE;
break;
case 'preview' :
@@ -371,7 +373,6 @@ class PFAutoeditAPI extends ApiBase {
Hooks::run( 'EditPage::showEditForm:initial', array( &$editor, &$wgOut ) );
- $this->getOutput()->addStyle( 'common/IE80Fixes.css', 'screen', 'IE 8' );
$this->getOutput()->setRobotPolicy( 'noindex,nofollow' );
// This hook seems slightly odd here, but makes things more
@@ -871,7 +872,12 @@ class PFAutoeditAPI extends ApiBase {
// HTML of the existing page.
list( $formHTML, $targetContent, $form_page_title, $generatedTargetNameFormula ) =
$wgPageFormsFormPrinter->formHTML(
- $formContent, $isFormSubmitted, $pageExists, $formArticleId, $preloadContent, $targetName, $targetNameFormula
+ // Special handling for autoedit edits -
+ // otherwise, multi-instance templates
+ // don't get saved, for some convoluted
+ // reason.
+ $formContent, ( $isFormSubmitted && !$this->mIsAutoEdit ), $pageExists,
+ $formArticleId, $preloadContent, $targetName, $targetNameFormula
);
$formHtmlHasRun = true;
@@ -1160,7 +1166,7 @@ class PFAutoeditAPI extends ApiBase {
/**
* Returns an array of parameter descriptions.
- * Don't call this functon directly: use getFinalParamDescription() to
+ * Don't call this function directly: use getFinalParamDescription() to
* allow hooks to modify descriptions as needed.
*
* @return array or false
diff --git a/www/wiki/extensions/PageForms/includes/PF_Form.php b/www/wiki/extensions/PageForms/includes/PF_Form.php
index b2b1e8a6..7f0ae447 100644
--- a/www/wiki/extensions/PageForms/includes/PF_Form.php
+++ b/www/wiki/extensions/PageForms/includes/PF_Form.php
@@ -52,7 +52,7 @@ class PFForm {
$fs = SpecialPageFactory::getPage( 'FormStart' );
$form_start_url = PFUtils::titleURLString( $fs->getTitle() ) . "/" . $title->getPartialURL();
$form_description = wfMessage( 'pf_form_docu', $this->mFormName, $form_start_url )->inContentLanguage()->text();
- $form_input = "{{#forminput:form=" . $this->mFormName;
+ $form_input = "{{#forminput:form=" . str_replace( ',', '\,', $this->mFormName );
if ( !is_null( $this->mAssociatedCategory ) ) {
$form_input .= "|autocomplete on category=" . $this->mAssociatedCategory;
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_FormField.php b/www/wiki/extensions/PageForms/includes/PF_FormField.php
index 00b0df32..99c736bb 100644
--- a/www/wiki/extensions/PageForms/includes/PF_FormField.php
+++ b/www/wiki/extensions/PageForms/includes/PF_FormField.php
@@ -327,6 +327,7 @@ class PFFormField {
$f->mFieldArgs['delimiter'] = ',';
} else {
$f->mFieldArgs['delimiter'] = $delimiterFromTemplate;
+ $f->mIsList = true;
}
}
$delimiter = $f->mFieldArgs['delimiter'];
diff --git a/www/wiki/extensions/PageForms/includes/PF_FormLinker.php b/www/wiki/extensions/PageForms/includes/PF_FormLinker.php
index 4f098094..a9de68de 100644
--- a/www/wiki/extensions/PageForms/includes/PF_FormLinker.php
+++ b/www/wiki/extensions/PageForms/includes/PF_FormLinker.php
@@ -10,6 +10,8 @@
class PFFormLinker {
+ private static $formPerNamespace = array();
+
static function getDefaultForm( $title ) {
// The title passed in can be null in at least one
// situation: if the "namespace page" is being checked, and
@@ -74,7 +76,8 @@ class PFFormLinker {
/**
* Sets the URL for form-based creation of a nonexistent (broken-linked,
- * AKA red-linked) page
+ * AKA red-linked) page, for MW < 1.28 only.
+ *
* @param Linker $linker
* @param Title $target
* @param array $options
@@ -83,24 +86,72 @@ class PFFormLinker {
* @param bool &$ret
* @return true
*/
- static function setBrokenLink( $linker, $target, $options, $text, &$attribs, &$ret ) {
+ static function setBrokenLinkOld( $linker, $target, $options, $text, &$attribs, &$ret ) {
// If it's not a broken (red) link, exit.
if ( !in_array( 'broken', $options, true ) ) {
return true;
}
// If the link is to a special page, exit.
- if ( $target->getNamespace() == NS_SPECIAL ) {
+ $namespace = $target->getNamespace();
+ if ( $namespace == NS_SPECIAL ) {
+ return true;
+ }
+
+ global $wgPageFormsLinkAllRedLinksToForms;
+ // Don't do this if it's a category page - it probably
+ // won't have an associated form.
+ if ( $wgPageFormsLinkAllRedLinksToForms && $target->getNamespace() != NS_CATEGORY ) {
+ $attribs['href'] = $target->getLinkURL( array( 'action' => 'formedit', 'redlink' => '1' ) );
+ return true;
+ }
+
+ if ( self::getDefaultFormForNamespace( $namespace ) !== null ) {
+ $attribs['href'] = $target->getLinkURL( array( 'action' => 'formedit', 'redlink' => '1' ) );
+ return true;
+ }
+
+ return true;
+ }
+
+ /**
+ * Called by the HtmlPageLinkRendererEnd hook.
+ * The $target argument is listed in the documentation as being of type
+ * LinkTarget, but in practice it seems to sometimes be of type Title
+ * and sometimes of type TitleValue. So we just leave out a type
+ * declaration for that argument in the header.
+ *
+ * @param LinkRenderer $linkRenderer
+ * @param Title $target
+ * @param bool $isKnown
+ * @param string &$text
+ * @param array &$attribs
+ * @param bool &$ret
+ * @return true
+ */
+ static function setBrokenLink( MediaWiki\Linker\LinkRenderer $linkRenderer, $target, $isKnown, &$text, &$attribs, &$ret ) {
+ // If it's not a broken (red) link, exit.
+ if ( $isKnown ) {
+ return true;
+ }
+ // If the link is to a special page, exit.
+ $namespace = $target->getNamespace();
+ if ( $namespace == NS_SPECIAL ) {
return true;
}
global $wgPageFormsLinkAllRedLinksToForms;
- // Don't do this is it it's a category page - it probably
+ // Don't do this if it's a category page - it probably
// won't have an associated form.
if ( $wgPageFormsLinkAllRedLinksToForms && $target->getNamespace() != NS_CATEGORY ) {
$attribs['href'] = $target->getLinkURL( array( 'action' => 'formedit', 'redlink' => '1' ) );
return true;
}
+ if ( self::getDefaultFormForNamespace( $namespace ) !== null ) {
+ $attribs['href'] = $target->getLinkURL( array( 'action' => 'formedit', 'redlink' => '1' ) );
+ return true;
+ }
+
return true;
}
@@ -165,8 +216,19 @@ class PFFormLinker {
return array();
}
- // If we're still here, just return the default form for the
- // namespace, which may well be null.
+ $default_form = self::getDefaultFormForNamespace( $namespace );
+ if ( $default_form != '' ) {
+ return array( $default_form );
+ }
+
+ return array();
+ }
+
+ public static function getDefaultFormForNamespace( $namespace ) {
+ if ( array_key_exists( $namespace, self::$formPerNamespace ) ) {
+ return self::$formPerNamespace[$namespace];
+ }
+
if ( NS_MAIN === $namespace ) {
// If it's in the main (blank) namespace, check for the
// file named with the word for "Main" in this language.
@@ -178,11 +240,8 @@ class PFFormLinker {
}
$namespacePage = Title::makeTitleSafe( NS_PROJECT, $namespace_label );
- $default_form = self::getDefaultForm( $namespacePage );
- if ( $default_form != '' ) {
- return array( $default_form );
- }
-
- return array();
+ $defaultForm = self::getDefaultForm( $namespacePage );
+ self::$formPerNamespace[$namespace] = $defaultForm;
+ return $defaultForm;
}
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_FormPrinter.php b/www/wiki/extensions/PageForms/includes/PF_FormPrinter.php
index 360383f4..fb249245 100644
--- a/www/wiki/extensions/PageForms/includes/PF_FormPrinter.php
+++ b/www/wiki/extensions/PageForms/includes/PF_FormPrinter.php
@@ -921,7 +921,7 @@ END;
} else {
$previous_template_name = '';
}
- $template_name = str_replace( '_', ' ', $tag_components[1] );
+ $template_name = str_replace( '_', ' ', $wgParser->recursiveTagParse( $tag_components[1] ) );
$is_new_template = ( $template_name != $previous_template_name );
if ( $is_new_template ) {
$template = PFTemplate::newFromName( $template_name );
@@ -964,10 +964,10 @@ END;
}
// We get values from the request,
- // regardless of whether the the source
- // is the page or a form submit, because
- // even if the source is a page, values
- // can still come from a query string.
+ // regardless of whether the source is the
+ // page or a form submit, because even if
+ // the source is a page, values can still
+ // come from a query string.
$tif->setFieldValuesFromSubmit();
$tif->checkIfAllInstancesPrinted( $form_submitted, $source_is_page );
@@ -1022,7 +1022,7 @@ END;
// If the user is editing a page, and that page contains a call to
// the template being processed, get the current field's value
// from the template call
- if ( $source_is_page && ( $tif->getFullTextInPage() != '' && !$form_submitted ) ) {
+ if ( $source_is_page && ( $tif->getFullTextInPage() != '' ) && ( !$form_is_partial || !$form_submitted ) ) {
if ( $tif->hasValueFromPageForField( $field_name ) ) {
// Get value, and remove it,
// so that at the end we
@@ -1079,7 +1079,8 @@ END;
}
}
$free_text_was_included = true;
- $wiki_page->addFreeTextSection();
+ $options = $form_field->getFieldArgs();
+ $wiki_page->addFreeTextSection($options);
}
if ( $tif->getTemplateName() === '' || $field_name == '#freetext#' ) {
@@ -1136,12 +1137,12 @@ END;
( $form_field->hasFieldArg( 'mapping template' ) ||
$form_field->hasFieldArg( 'mapping property' ) ||
( $form_field->hasFieldArg( 'mapping cargo table' ) &&
- $form_field->hasFieldArg( 'mapping cargo field' ) ) ) ||
- $form_field->getUseDisplayTitle() ) {
+ $form_field->hasFieldArg( 'mapping cargo field' ) ) ||
+ $form_field->getUseDisplayTitle() ) ) {
// If the input type is "tokens', the value is not
// an array, but the delimiter still needs to be set.
if ( !is_array( $cur_value ) ) {
- if ( $form_field->hasFieldArg( 'delimiter' ) ) {
+ if ( $form_field->isList() ) {
$delimiter = $form_field->getFieldArg( 'delimiter' );
} else {
$delimiter = null;
@@ -1217,6 +1218,7 @@ END;
$options = $form_field->getFieldArgs();
$wiki_page->addTemplateParam( $template_name, $tif->getInstanceNum(), $field_name, $cur_value_in_template, $options);
$section = substr_replace( $section, $new_text, $brackets_loc, $brackets_end_loc + 3 - $brackets_loc );
+ $start_position = $brackets_loc + strlen( $new_text );
} else {
$start_position = $brackets_end_loc;
}
@@ -1604,7 +1606,7 @@ END;
// text.
// The page text needs to be created whether or not the form
// was submitted, in case this is called from #formredlink.
- $wiki_page->setFreeText( $free_text );
+ $wiki_page->setFreeText( $free_text, $wgRequest->getCheck( 'pf_free_text' ) );
$page_text = $wiki_page->createPageText();
// Also substitute the free text into the form.
diff --git a/www/wiki/extensions/PageForms/includes/PF_FormUtils.php b/www/wiki/extensions/PageForms/includes/PF_FormUtils.php
index 7c3636ee..39068e83 100644
--- a/www/wiki/extensions/PageForms/includes/PF_FormUtils.php
+++ b/www/wiki/extensions/PageForms/includes/PF_FormUtils.php
@@ -569,7 +569,7 @@ END;
* Get a cache key.
*
* @param string $formId
- * @param Parser $parser Provide parser to get unique cache key
+ * @param Parser|null $parser Provide parser to get unique cache key
* @return string
*/
public static function getCacheKey( $formId, $parser = null ) {
diff --git a/www/wiki/extensions/PageForms/includes/PF_Hooks.php b/www/wiki/extensions/PageForms/includes/PF_Hooks.php
index 704142e1..32ad53f3 100644
--- a/www/wiki/extensions/PageForms/includes/PF_Hooks.php
+++ b/www/wiki/extensions/PageForms/includes/PF_Hooks.php
@@ -10,13 +10,16 @@
class PFHooks {
+ // Used for caching by addToCargoTablesLinks().
+ private static $mMultiPageEditPage = null;
+
public static function registerExtension() {
if ( defined( 'PF_VERSION' ) ) {
// Do not load Page Forms more than once.
return 1;
}
- define( 'PF_VERSION', '4.3' );
+ define( 'PF_VERSION', '4.4.1' );
$GLOBALS['wgPageFormsIP'] = dirname( __DIR__ ) . '/../';
@@ -25,11 +28,7 @@ class PFHooks {
* up properly before we add our stuff.
*/
- // This global variable is needed so that other
- // extensions can hook into it to add their own
- // input types.
-
- if ( defined( 'SMW_VERSION' ) ) {
+ if ( defined( 'SMW_VERSION' ) || ExtensionRegistry::getInstance()->isLoaded( 'SemanticMediaWiki' ) ) {
$GLOBALS['wgSpecialPages']['CreateProperty'] = 'PFCreateProperty';
$GLOBALS['wgAutoloadClasses']['PFCreateProperty'] = __DIR__ . '/../specials/PF_CreateProperty.php';
}
@@ -45,6 +44,15 @@ class PFHooks {
$GLOBALS['wgPageFormsPartialPath'] = '/extensions/PageForms';
$GLOBALS['wgPageFormsScriptPath'] = $GLOBALS['wgScriptPath'] . $GLOBALS['wgPageFormsPartialPath'];
+ // We have to have this hook called here, instead of in
+ // extension.json, because it's conditional.
+ if ( class_exists( 'MediaWiki\Linker\LinkRenderer' ) ) {
+ // MW 1.28+
+ $GLOBALS['wgHooks']['HtmlPageLinkRendererEnd'][] = 'PFFormLinker::setBrokenLink';
+ } else {
+ $GLOBALS['wgHooks']['LinkEnd'][] = 'PFFormLinker::setBrokenLinkOld';
+ }
+
// Admin Links hook needs to be called in a delayed way so that it
// will always be called after SMW's Admin Links addition; as of
// SMW 1.9, SMW delays calling all its hook functions.
@@ -140,6 +148,7 @@ class PFHooks {
global $wgPageFormsAutocompleteValues, $wgPageFormsAutocompleteOnAllChars;
global $wgPageFormsFieldProperties, $wgPageFormsCargoFields, $wgPageFormsDependentFields;
global $wgPageFormsGridValues, $wgPageFormsGridParams;
+ global $wgPageFormsContLangYes, $wgPageFormsContLangNo, $wgPageFormsContLangMonths;
global $wgPageFormsShowOnSelect, $wgPageFormsScriptPath;
global $edgValues, $wgPageFormsEDSettings, $wgAllowPipesInForms;
//global $wgPageFormsInitJSFunctions, $wgPageFormsValidationJSFunctions;
@@ -152,6 +161,9 @@ class PFHooks {
$vars['wgPageFormsDependentFields'] = $wgPageFormsDependentFields;
$vars['wgPageFormsGridValues'] = $wgPageFormsGridValues;
$vars['wgPageFormsGridParams'] = $wgPageFormsGridParams;
+ $vars['wgPageFormsContLangYes'] = $wgPageFormsContLangYes;
+ $vars['wgPageFormsContLangNo'] = $wgPageFormsContLangNo;
+ $vars['wgPageFormsContLangMonths'] = $wgPageFormsContLangMonths;
$vars['wgPageFormsShowOnSelect'] = $wgPageFormsShowOnSelect;
$vars['wgPageFormsScriptPath'] = $wgPageFormsScriptPath;
$vars['edgValues'] = $edgValues;
@@ -217,6 +229,69 @@ class PFHooks {
}
/**
+ * Called by the CargoTablesActionLinks hook.
+ *
+ * Adds an "Edit" link to Special:CargoTables, pointing to Special:MultiPageEdit.
+ *
+ * @param array &$actionLinks Action links
+ * @param string $tableName Cargo table name
+ * @param bool $isReplacementTable Whether this table iss a replacement table
+ * @param bool $hasReplacementTable Whether this table has a replacement table
+ * @param string[] $templatesThatDeclareTables An array
+ * @param string[] $templatesThatAttachToTables An array
+ *
+ * @return bool
+ *
+ * @since 4.4
+ */
+ public static function addToCargoTablesLinks( &$actionLinks, $tableName, $isReplacementTable, $hasReplacementTable, $templatesThatDeclareTables, $templatesThatAttachToTables ) {
+ global $wgUser;
+
+ // If it has a "replacement table", it's read-only and can't
+ // be edited (though the replacement table can).
+ if ( $hasReplacementTable ) {
+ return true;
+ }
+
+ // Check permissions.
+ if ( !$wgUser->isAllowed( 'multipageedit' ) ) {
+ return true;
+ }
+ // Only put in an "Edit" link if there's exactly one template
+ // for this Cargo table, and one form for that template.
+ if ( !array_key_exists( $tableName, $templatesThatDeclareTables ) ) {
+ return true;
+ }
+ if ( array_key_exists( $tableName, $templatesThatAttachToTables ) ) {
+ return true;
+ }
+ $templateIDs = $templatesThatDeclareTables[$tableName];
+ if ( count( $templateIDs ) > 1 ) {
+ return true;
+ }
+
+ $templateTitle = Title::newFromID( $templateIDs[0] );
+ $templateName = $templateTitle->getText();
+ if ( self::$mMultiPageEditPage == null ) {
+ self::$mMultiPageEditPage = new SpreadsheetTemplatesPage();
+ }
+ $formName = self::$mMultiPageEditPage->getFormForTemplate( $templateName );
+ if ( $formName == null ) {
+ return true;
+ }
+
+ $sp = SpecialPageFactory::getPage( 'MultiPageEdit' );
+ $editMsg = wfMessage( 'edit' )->text();
+ $text = PFUtils::makeLink( $linkRenderer = null, $sp->getTitle(), $editMsg, array(),
+ array( "template" => $templateName, "form" => $formName ) );
+
+ $indexOfDrilldown = array_search( 'drilldown', array_keys( $actionLinks ) );
+ $pos = false === $indexOfDrilldown ? count( $array ) : $indexOfDrilldown + 1;
+ $actionLinks = array_merge( array_slice( $actionLinks, 0, $pos ), array( 'edit' => $text ), array_slice( $actionLinks, $pos ) );
+ return true;
+ }
+
+ /**
* Disable TinyMCE if this is a form definition page, or a form-editable page.
*
* @param Title $title The page Title object
@@ -271,6 +346,42 @@ class PFHooks {
}
/**
+ * Called by the PageContentSaveComplete hook.
+ *
+ * Set a cookie after the page save so that a "Your edit was saved"
+ * popup will appear after form-based saves, just as it does after
+ * standard saves. This code will be called after all saves, which
+ * means that it will lead to redundant cookie-setting after normal
+ * saves. However, there doesn't appear to be a way to to set the
+ * cookie correctly only after form-based saves, unfortunately.
+ *
+ * @param WikiPage &$wikiPage The page modified
+ * @param User &$user User performing the modification
+ * @param Content $content New content
+ * @param string $summary Edit summary/comment
+ * @param bool $isMinor Whether or not the edit was marked as minor
+ * @param bool $isWatch No longer used
+ * @param bool $section No longer used
+ * @param int[] &$flags Flags passed to WikiPage::doEditContent()
+ * @param Revision $revision Revision object of the saved content (or null)
+ * @param Status &$status Status object about to be returned by doEditContent()
+ * @param int $baseRevId The rev ID (or false) this edit was based on
+ * @param int $undidRevId The rev ID this edit undid (default 0)
+ *
+ * @return bool
+ */
+ public static function setPostEditCookie( &$wikiPage, &$user, $content, $summary, $isMinor, $isWatch, $section, &$flags, $revision, &$status, $baseRevId, $undidRevId = 0 ) {
+ if ( $revision == null ) {
+ return true;
+ }
+ // Code based on EditPage::setPostEditCookie().
+ $postEditKey = EditPage::POST_EDIT_COOKIE_KEY_PREFIX . $revision->getID();
+ $response = RequestContext::getMain()->getRequest()->response();
+ $response->setCookie( $postEditKey, 'saved', time() + EditPage::POST_EDIT_COOKIE_DURATION );
+ return true;
+ }
+
+ /**
* Hook to add PHPUnit test cases.
* From https://www.mediawiki.org/wiki/Manual:PHP_unit_testing/Writing_unit_tests_for_extensions
*
diff --git a/www/wiki/extensions/PageForms/includes/PF_PageSchemas.php b/www/wiki/extensions/PageForms/includes/PF_PageSchemas.php
index d581d1d5..84d19caa 100644
--- a/www/wiki/extensions/PageForms/includes/PF_PageSchemas.php
+++ b/www/wiki/extensions/PageForms/includes/PF_PageSchemas.php
@@ -602,17 +602,18 @@ class PFPageSchemas extends PSExtensionHandler {
* @return Title[]
*/
public static function getPagesToGenerate( $pageSchemaObj ) {
+ $genPageList = array();
$psTemplates = $pageSchemaObj->getTemplates();
foreach ( $psTemplates as $psTemplate ) {
$title = Title::makeTitleSafe( NS_TEMPLATE, $psTemplate->getName() );
$genPageList[] = $title;
}
$form_name = self::getFormName( $pageSchemaObj );
- if ( $form_name == null ) {
- return array();
+ if ( $form_name != null ) {
+ $title = Title::makeTitleSafe( PF_NS_FORM, $form_name );
+ $genPageList[] = $title;
}
- $title = Title::makeTitleSafe( PF_NS_FORM, $form_name );
- $genPageList[] = $title;
+
return $genPageList;
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_ParserFunctions.php b/www/wiki/extensions/PageForms/includes/PF_ParserFunctions.php
index f0708956..c72495e7 100644
--- a/www/wiki/extensions/PageForms/includes/PF_ParserFunctions.php
+++ b/www/wiki/extensions/PageForms/includes/PF_ParserFunctions.php
@@ -23,7 +23,7 @@ use MediaWiki\MediaWikiServices;
*
* {{#forminput:form=|size=|default value=|button text=|query string=
* |autocomplete on category=|autocomplete on namespace=
- * |...additional query string values...}}
+ * |popup|reload|...additional query string values...}}
*
* This function returns HTML representing a form to let the user enter the
* name of a page to be added or edited using a Page Forms form. All
@@ -39,6 +39,8 @@ use MediaWiki\MediaWikiServices;
* choice, using 'autocomplete on category' or 'autocomplete on namespace'
* (you can only use one). To autcomplete on all pages in the main (blank)
* namespace, specify "autocomplete on namespace=main".
+ * 'reload' is an optional value to be used along with 'popup', causes the page
+ * to reload with 'action=purge' after the form is submitted successfully.
*
* Example: to create an input to add or edit a page with a form called
* 'User' within a namespace also called 'User', and to have the form
@@ -51,10 +53,10 @@ use MediaWiki\MediaWikiServices;
* '#formlink' is called as:
*
* {{#formlink:form=|link text=|link type=|tooltip=|query string=|target=
- * |popup|...additional query string values...}}
+ * |popup|reload|...additional query string values...}}
*
* This function returns HTML representing a link to a form; given that
- * no page name is entered by the the user, the form must be one that
+ * no page name is entered by the user, the form must be one that
* creates an automatic page name, or else it will display an error
* message when the user clicks on the link.
*
@@ -69,6 +71,8 @@ use MediaWiki\MediaWikiServices;
* (or, in the case of 'post button', to be sent as hidden inputs).
* 'target' is an optional value, setting the name of the page to be
* edited by the form.
+ * 'reload' is an optional value to be used along with 'popup', causes the page
+ * to reload with 'action=purge' after the form is submitted successfully.
*
* Example: to create a link to add data with a form called
* 'User' within a namespace also called 'User', and to have the form
@@ -221,6 +225,7 @@ class PFParserFunctions {
}
public static function renderFormInput( &$parser ) {
+
$params = func_get_args();
array_shift( $params ); // don't need the parser
@@ -232,6 +237,8 @@ class PFParserFunctions {
$classStr = "pfFormInput";
$inPlaceholder = null;
$inAutofocus = true;
+ $languageSelector = false;
+ $namespaceSelector = false;
// Assign params.
foreach ( $params as $i => $param ) {
@@ -271,8 +278,14 @@ class PFParserFunctions {
} elseif ( $paramName == 'popup' ) {
self::loadScriptsForPopupForm( $parser );
$classStr .= ' popupforminput';
+ } elseif ( $paramName == 'reload' ) {
+ $classStr .= ' reload';
} elseif ( $paramName == 'no autofocus' ) {
$inAutofocus = false;
+ } elseif ( $paramName == 'language selector' && defined('TRANSLATE_VERSION') ) {
+ $languageSelector = true;
+ } elseif ($paramName == 'namespace selector'){
+ $namespaceSelector = true;
} else {
$value = urlencode( $value );
parse_str( "$paramName=$value", $arr );
@@ -317,6 +330,8 @@ class PFParserFunctions {
// double-encoding.
$inValue = html_entity_decode( $inValue );
$formContents = Html::input( 'page_name', $inValue, 'text', $formInputAttrs );
+ $languageSelectorContent = '';
+ $namespaceSelectorContent = '';
// If the form start URL looks like "index.php?title=Special:FormStart"
// (i.e., it's in the default URL style), add in the title as a
@@ -334,6 +349,7 @@ class PFParserFunctions {
if ( $inFormName == '' ) {
$formContents .= PFUtils::formDropdownHTML();
} elseif ( count( $listOfForms ) == 1 ) {
+ $inFormName = str_replace( '\,', ',', $inFormName );
$formContents .= Html::hidden( "form", $inFormName );
} else {
$formContents .= PFUtils::formDropdownHTML( $listOfForms );
@@ -353,6 +369,82 @@ class PFParserFunctions {
}
}
+ if ($languageSelector) {
+
+ global $wgLang, $wgSimpleLangageSelectionLangList;
+
+ if (isset($wgSimpleLangageSelectionLangList) && $wgSimpleLangageSelectionLangList) {
+
+ $languages = [];
+
+ foreach ($wgSimpleLangageSelectionLangList as $langcode) {
+ $languages[$langcode] = Language::fetchLanguageName( $langcode, $wgLang->getCode(), 'mw' );
+ }
+ } else {
+ $languages = Language::fetchLanguageNames( $wgLang->getCode(), 'mw' );
+ }
+
+ ksort( $languages );
+
+ foreach ( $languages as $code => $name ) {
+
+ if ( $wgLang->getCode() == $code ) {
+
+ $optionsHtml[] = Html::element(
+ 'option', [
+ 'value' => $code,
+ 'selected' => 'selected'
+ ], "$code - $name"
+ );
+ } else {
+
+ $optionsHtml[] = Html::element(
+ 'option', [
+ 'value' => $code
+ ], "$code - $name"
+ );
+ }
+ }
+
+ $languageSelectorSelect = '<label>' . wfMessage( 'pf_formstart_pagelanguage' ) . '</label>'
+ . Html::openElement( 'select', ['name' => "PageLang[Language]"] )
+ . "\n"
+ . implode( "\n", $optionsHtml )
+ . "\n"
+ . Html::closeElement( 'select' );
+
+ $languageSelectorContent .= Html::openElement( 'div', ['class' => "form-inline"] )
+ . $languageSelectorSelect
+ . Html::closeElement( 'div' );
+ }
+
+ if($namespaceSelector) {
+
+ global $wgPageFormsAvailableNamespaces;
+
+ if(isset($wgPageFormsAvailableNamespaces)){
+ foreach ($wgPageFormsAvailableNamespaces as $availableNamespace){
+
+ $optionsHtmlNamespace[] = Html::element(
+ 'option', [
+ 'value' => $availableNamespace,
+ ], $availableNamespace
+ );
+ }
+
+ $namespaceSelectorSelect = Html::label(wfMessage('pf_formstart_pagenamespace'), '')
+ . Html::openElement('select', ['name' => "namespace"])
+ . "\n"
+ .implode( "\n", $optionsHtmlNamespace)
+ . "\n"
+ . Html::closeElement('select');
+
+ $namespaceSelectorContent .= Html::openElement('div', ['class' => "form-inline"] )
+ .$namespaceSelectorSelect
+ .Html::closeElement('div');
+ }
+ }
+
$buttonStr = ( $inButtonStr != '' ) ? $inButtonStr : wfMessage( 'pf_formstart_createoredit' )->escaped();
$formContents .= "&nbsp;" . Html::input( null, $buttonStr, 'submit',
array(
@@ -366,7 +458,7 @@ class PFParserFunctions {
'action' => $fsURL,
'method' => 'get',
'class' => $classStr
- ), '<p>' . $formContents . '</p>'
+ ), '<p>' . $formContents . '</p>' . $languageSelectorContent . $namespaceSelectorContent
) . "\n";
if ( ! empty( $inAutocompletionSource ) ) {
@@ -402,9 +494,9 @@ class PFParserFunctions {
$new_delimiter = isset( $args[4] ) ? trim( $frame->expand( $args[4] ) ) : ', ';
# Unstrip some
$delimiter = $parser->mStripState->unstripNoWiki( $delimiter );
- # let '\n' represent newlines
- $delimiter = str_replace( '\n', "\n", $delimiter );
- $new_delimiter = str_replace( '\n', "\n", $new_delimiter );
+ # Let '\n' represent newlines, and '\s' represent spaces.
+ $delimiter = str_replace( array( '\n', '\s' ), array( "\n", ' ' ), $delimiter );
+ $new_delimiter = str_replace( array( '\n', '\s' ), array( "\n", ' ' ), $new_delimiter );
if ( $delimiter == '' ) {
$values_array = preg_split( '/(.)/u', $value, -1, PREG_SPLIT_NO_EMPTY | PREG_SPLIT_DELIM_CAPTURE );
@@ -667,6 +759,8 @@ class PFParserFunctions {
} elseif ( $param_name == null && $value == 'popup' ) {
self::loadScriptsForPopupForm( $parser );
$classStr = 'popupformlink';
+ } elseif ( $param_name == null && $value == 'reload' ) {
+ $classStr .= ' reload';
} elseif ( $param_name == null && $value == 'new window' ) {
$targetWindow = '_blank';
} elseif ( $param_name == null && $value == 'create page' ) {
diff --git a/www/wiki/extensions/PageForms/includes/PF_Template.php b/www/wiki/extensions/PageForms/includes/PF_Template.php
index 3483ee2a..71c9419a 100644
--- a/www/wiki/extensions/PageForms/includes/PF_Template.php
+++ b/www/wiki/extensions/PageForms/includes/PF_Template.php
@@ -461,11 +461,6 @@ END;
}
$separator = '';
- $fieldStart = $this->mFieldStart;
- Hooks::run( 'PageForms::TemplateFieldStart', array( $field, &$fieldStart ) );
- $fieldEnd = $this->mFieldEnd;
- Hooks::run( 'PageForms::TemplateFieldEnd', array( $field, &$fieldEnd ) );
-
$fieldLabel = $field->getLabel();
if ( $fieldLabel == '' ) {
$fieldLabel = $field->getFieldName();
@@ -524,29 +519,16 @@ END;
if ( $separator != '' ) {
$tableText .= "$separator ";
}
- if ( $fieldStart != '' ) {
- $tableText .= "$fieldStart ";
- }
- if ( $cargoInUse && ( $field->getFieldType() == 'Page' || $field->getFieldType() == 'File' ) ) {
- $tableText .= "[[$fieldString]]";
- } else {
- $tableText .= $fieldString;
- }
- if ( $fieldEnd != '' ) {
- $tableText .= " $fieldEnd";
- }
- $tableText .= "\n";
+ $tableText .= $this->createTextForField( $field );
if ( $fieldDisplay == 'nonempty' ) {
$tableText .= " }}";
}
+ $tableText .= "\n";
} elseif ( !is_null( $internalObjText ) ) {
if ( $separator != '' ) {
$tableText .= "$separator ";
}
- if ( $fieldStart != '' ) {
- $tableText .= "$fieldStart ";
- }
- $tableText .= "$fieldString $fieldEnd";
+ $tableText .= $this->createTextForField( $field );
if ( $fieldDisplay == 'nonempty' ) {
$tableText .= " }}";
}
@@ -570,55 +552,9 @@ END;
if ( $this->mTemplateFormat == 'standard' || $this->mTemplateFormat == 'infobox' ) {
$tableText .= '{{!}} ';
}
- if ( $fieldStart != '' ) {
- $tableText .= $fieldStart . ' ';
- }
- if ( !is_null( $field->getNamespace() ) ) {
- // Special handling is needed, for at
- // least the File and Category namespaces.
- $tableText .= "[[$fieldString]] {{#set:$fieldProperty=$fieldString}}";
- } else {
- $tableText .= "[[$fieldProperty::$fieldString]]";
- }
- $tableText .= "}} $fieldEnd\n";
- } elseif ( $fieldIsList ) {
- // If this field is meant to contain a list,
- // add on an 'arraymap' function, that will
- // call this semantic markup tag on every
- // element in the list.
- // Find a string that's not in the semantic
- // field call, to be used as the variable.
- $var = "x"; // default - use this if all the attempts fail
- if ( strstr( $fieldProperty, $var ) ) {
- $var_options = array( 'y', 'z', 'xx', 'yy', 'zz', 'aa', 'bb', 'cc' );
- foreach ( $var_options as $option ) {
- if ( ! strstr( $fieldProperty, $option ) ) {
- $var = $option;
- break;
- }
- }
- }
- $tableText .= "{{#arraymap:{{{" . $field->getFieldName() . '|}}}|' . $field->getDelimiter() . "|$var|[[";
- if ( $cargoInUse ) {
- $tableText .= "$var]]";
- } elseif ( is_null( $field->getNamespace() ) ) {
- $tableText .= "$fieldProperty::$var]]";
- } else {
- $tableText .= $field->getNamespace() . ":$var]] {{#set:" . $fieldProperty . "=$var}} ";
- }
- $tableText .= "}}\n";
+ $tableText .= $this->createTextForField( $field ) . "\n";
} else {
- if ( $fieldStart != '' ) {
- $tableText .= $fieldStart . ' ';
- }
- if ( !is_null( $field->getNamespace() ) ) {
- // Special handling is needed, for at
- // least the File and Category namespaces.
- $tableText .= "[[$fieldString]] {{#set:$fieldProperty=$fieldString}}";
- } else {
- $tableText .= "[[$fieldProperty::$fieldString]]";
- }
- $tableText .= " $fieldEnd\n";
+ $tableText .= $this->createTextForField( $field ) . "\n";
}
}
@@ -676,4 +612,25 @@ END;
return $text;
}
+
+ function createTextForField( $field ) {
+ $text = '';
+ $fieldStart = $this->mFieldStart;
+ Hooks::run( 'PageForms::TemplateFieldStart', array( $field, &$fieldStart ) );
+ if ( $fieldStart != '' ) {
+ $text .= "$fieldStart ";
+ }
+
+ $cargoInUse = defined( 'CARGO_VERSION' ) && !defined( 'SMW_VERSION' ) && $this->mCargoTable != '';
+ $text .= $field->createText( $cargoInUse );
+
+ $fieldEnd = $this->mFieldEnd;
+ Hooks::run( 'PageForms::TemplateFieldEnd', array( $field, &$fieldEnd ) );
+ if ( $fieldEnd != '' ) {
+ $text .= " $fieldEnd";
+ }
+
+ return $text;
+ }
+
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_TemplateField.php b/www/wiki/extensions/PageForms/includes/PF_TemplateField.php
index 1ee5d85f..740e54b5 100644
--- a/www/wiki/extensions/PageForms/includes/PF_TemplateField.php
+++ b/www/wiki/extensions/PageForms/includes/PF_TemplateField.php
@@ -243,6 +243,10 @@ class PFTemplateField {
function setFieldType( $fieldType ) {
$this->mFieldType = $fieldType;
+
+ if ( $fieldType == 'File' ) {
+ $this->mNamespace = MWNamespace::getCanonicalName( NS_FILE );
+ }
}
function setPossibleValues( $possibleValues ) {
@@ -252,4 +256,66 @@ class PFTemplateField {
function setHierarchyStructure( $hierarchyStructure ) {
$this->mHierarchyStructure = $hierarchyStructure;
}
+
+ function createText( $cargoInUse ) {
+ $fieldProperty = $this->mSemanticProperty;
+ if ( $this->mIsList ) {
+ // If this field is meant to contain a list,
+ // add on an 'arraymap' function, that will
+ // call this semantic markup tag on every
+ // element in the list.
+ // Find a string that's not in the semantic
+ // field call, to be used as the variable.
+ $var = "x"; // default - use this if all the attempts fail
+ if ( strstr( $fieldProperty, $var ) ) {
+ $var_options = array( 'y', 'z', 'xx', 'yy', 'zz', 'aa', 'bb', 'cc' );
+ foreach ( $var_options as $option ) {
+ if ( ! strstr( $fieldProperty, $option ) ) {
+ $var = $option;
+ break;
+ }
+ }
+ }
+ $text = "{{#arraymap:{{{" . $this->mFieldName . '|}}}|' . $this->mDelimiter . "|$var|[[";
+ if ( $fieldProperty == '' ) {
+ $text .= "$var]]";
+ } elseif ( $this->mNamespace == '' ) {
+ $text .= "$fieldProperty::$var]]";
+ } else {
+ $text .= $this->mNamespace . ":$var]] {{#set:" . $fieldProperty . "=$var}} ";
+ }
+ $text .= "}}\n"; // close #arraymap call.
+ return $text;
+ }
+
+ // Not a list.
+ $fieldParam = '{{{' . $this->mFieldName . '|}}}';
+ if ( is_null( $this->mNamespace ) ) {
+ $fieldString = $fieldParam;
+ } else {
+ $fieldString = $this->mNamespace . ':' . $fieldParam;
+ }
+
+ if ( $fieldProperty == '' ) {
+ if ( $cargoInUse && ( $this->mFieldType == 'Page' || $this->mFieldType == 'File' ) ) {
+ $fieldString = "[[$fieldString]]";
+ // Add an #if around the link, to prevent
+ // anything from getting displayed on the
+ // screen for blank values, if the
+ // ParserFunctions extension is installed.
+ if ( ExtensionRegistry::getInstance()->isLoaded( 'ParserFunctions' ) ) {
+ $fieldString = "{{#if:$fieldParam|$fieldString}}";
+ }
+ return $fieldString;
+ }
+ return $fieldString;
+ } elseif ( is_null( $this->mNamespace ) ) {
+ return "[[$fieldProperty::$fieldString]]";
+ } else {
+ // Special handling is needed, for at
+ // least the File and Category namespaces.
+ return "[[$fieldString]] {{#set:$fieldProperty=$fieldString}}";
+ }
+ }
+
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_TemplateInForm.php b/www/wiki/extensions/PageForms/includes/PF_TemplateInForm.php
index bec5d66e..317c731b 100644
--- a/www/wiki/extensions/PageForms/includes/PF_TemplateInForm.php
+++ b/www/wiki/extensions/PageForms/includes/PF_TemplateInForm.php
@@ -56,7 +56,7 @@ class PFTemplateInForm {
public static function newFromFormTag( $tag_components ) {
global $wgParser;
- $template_name = str_replace( '_', ' ', trim( $tag_components[1] ) );
+ $template_name = str_replace( '_', ' ', trim( $wgParser->recursiveTagParse( $tag_components[1] ) ) );
$tif = new PFTemplateInForm();
$tif->mTemplateName = str_replace( '_', ' ', $template_name );
@@ -72,7 +72,7 @@ class PFTemplateInForm {
$sub_components = array_map( 'trim', explode( '=', $component, 2 ) );
if ( count( $sub_components ) == 2 ) {
if ( $sub_components[0] == 'label' ) {
- $tif->mLabel = $sub_components[1];
+ $tif->mLabel = $wgParser->recursiveTagParse( $sub_components[1] );
} elseif ( $sub_components[0] == 'minimum instances' ) {
$tif->mMinAllowed = $sub_components[1];
} elseif ( $sub_components[0] == 'maximum instances' ) {
@@ -272,8 +272,56 @@ class PFTemplateInForm {
return $this->mValuesFromSubmit;
}
+ /**
+ * Change "non-template pipes", i.e. pipes that do not separate
+ * between template params but rather are contained within tag
+ * functions, into another character, so that they don't get
+ * handled and can be changed back into pipes later.
+ * (This doesn't include pipes contained within curly bracket
+ * parser functions - those are handled separately.)
+ *
+ * @param string $str
+ * @return string
+ */
+ static function escapeNonTemplatePipes( $str ) {
+ $startAndEndTags = array(
+ array( '<pre', 'pre>' ),
+ array( '<syntaxhighlight', 'syntaxhighlight>' ),
+ array( '<source', 'source>' ),
+ array( '<ref', 'ref>' )
+ );
+
+ foreach ( $startAndEndTags as $tags ) {
+ list( $startTag, $endTag ) = $tags;
+ $pattern = "/($startTag.*)\|(.*$endTag)/mis";
+ while ( preg_match( $pattern, $str, $matches ) ) {
+ // Special handling, to avoid escaping pipes
+ // within a string that looks like:
+ // startTag ... endTag | startTag ... endTag
+ if ( strpos( $matches[1], $endTag ) &&
+ strpos( $matches[2], $startTag ) ) {
+ $str = preg_replace( $pattern, "$1" . "\2" . "$2", $str );
+ } else {
+ $str = preg_replace( $pattern, "$1" . "\1" . "$2", $str );
+ }
+ }
+ }
+ // Change the "true" pipes back into pipes.
+ $str = str_replace( "\2", '|', $str );
+ return $str;
+ }
+
+ /**
+ * @param string $str
+ * @return string
+ */
+ static function unescapeNonTemplatePipes( $str ) {
+ return str_replace( "\1", '|', $str );
+ }
+
function setFieldValuesFromPage( $existing_page_content ) {
global $wgPageFormsUseTranslatableTemplates;
+ $existing_page_content = self::escapeNonTemplatePipes( $existing_page_content );
$matches = array();
$search_pattern = '/{{' . $this->mPregMatchTemplateStr . '\s*[\|}]/i';
$content_str = str_replace( '_', ' ', $existing_page_content );
@@ -319,14 +367,15 @@ class PFTemplateInForm {
$template_ended = ( $uncompleted_curly_brackets == 0 && $uncompleted_square_brackets == 0 );
$field_ended = ( $c == '|' && $uncompleted_square_brackets == 0 && $uncompleted_curly_brackets <= 2 );
if ( $template_ended || $field_ended ) {
- // if this was the last character in the template, remove
- // the closing curly brackets
+ // If this was the last character in the template, remove
+ // the closing curly brackets.
if ( $template_ended ) {
$field = substr( $field, 0, - 1 );
}
- // either there's an equals sign near the beginning or not -
+ $field = self::unescapeNonTemplatePipes( $field );
+ // Either there's an equals sign near the beginning or not -
// handling is similar in either way; if there's no equals
- // sign, the index of this field becomes the key
+ // sign, the index of this field becomes the key.
$sub_fields = explode( '=', $field, 2 );
if ( count( $sub_fields ) > 1 ) {
$this->mValuesFromPage[trim( $sub_fields[0] )] = trim( $sub_fields[1] );
@@ -347,6 +396,7 @@ class PFTemplateInForm {
if ( $uncompleted_curly_brackets > 0 || $uncompleted_square_brackets > 0 ) {
throw new MWException( "PageFormsMismatchedBrackets" );
}
+ $existing_page_content = self::unescapeNonTemplatePipes( $existing_page_content );
$this->mFullTextInPage = substr( $existing_page_content, $start_char, $i - $start_char );
}
}
diff --git a/www/wiki/extensions/PageForms/includes/PF_Utils.php b/www/wiki/extensions/PageForms/includes/PF_Utils.php
index 1003a284..794bd1f4 100644
--- a/www/wiki/extensions/PageForms/includes/PF_Utils.php
+++ b/www/wiki/extensions/PageForms/includes/PF_Utils.php
@@ -223,10 +223,11 @@ END;
* to display and work correctly.
*
* Accepts an optional Parser instance, or uses $wgOut if omitted.
- * @param Parser $parser
+ * @param Parser|null $parser
*/
public static function addFormRLModules( $parser = null ) {
- global $wgOut, $wgPageFormsSimpleUpload;
+ global $wgOut, $wgPageFormsSimpleUpload, $wgVersion,
+ $wgUsejQueryThree;
// Handling depends on whether or not this form is embedded
// in another page.
@@ -249,7 +250,6 @@ END;
// templates makes that tricky (every form input needs
// to re-apply the JS on a new instance) - it can be
// done via JS hooks, but it hasn't been done yet.
- 'ext.pageforms.fancybox',
'ext.pageforms.dynatree',
'ext.pageforms.imagepreview',
'ext.pageforms.autogrow',
@@ -258,6 +258,12 @@ END;
'ext.pageforms.rating'
);
+ if ( version_compare( $wgVersion, '1.30', '<' ) || $wgUsejQueryThree === false ) {
+ $mainModules[] = 'ext.pageforms.fancybox.jquery1';
+ } else {
+ $mainModules[] = 'ext.pageforms.fancybox.jquery3';
+ }
+
if ( $wgPageFormsSimpleUpload ) {
$mainModules[] = 'ext.pageforms.simpleupload';
}
@@ -293,7 +299,7 @@ END;
/**
* Creates a dropdown of possible form names.
- * @param array $form_names
+ * @param array|null $form_names
* @return string
*/
public static function formDropdownHTML( $form_names = null ) {
diff --git a/www/wiki/extensions/PageForms/includes/PF_ValuesUtils.php b/www/wiki/extensions/PageForms/includes/PF_ValuesUtils.php
index adb58416..87bdd0c1 100644
--- a/www/wiki/extensions/PageForms/includes/PF_ValuesUtils.php
+++ b/www/wiki/extensions/PageForms/includes/PF_ValuesUtils.php
@@ -14,7 +14,7 @@ class PFValuesUtils {
* @param Store $store
* @param Title $subject
* @param string $propID
- * @param array $requestOptions
+ * @param array|null $requestOptions
* @return array
*/
public static function getSMWPropertyValues( $store, $subject, $propID, $requestOptions = null ) {
@@ -313,7 +313,7 @@ class PFValuesUtils {
// Escape if there's no such concept.
if ( $conceptTitle == null || !$conceptTitle->exists() ) {
- return wfMessage( 'pf-missingconcept', wfEscapeWikiText( $conceptName ) );
+ throw new MWException( wfMessage( 'pf-missingconcept', wfEscapeWikiText( $conceptName ) ) );
}
global $wgPageFormsUseDisplayTitle;
@@ -429,7 +429,7 @@ class PFValuesUtils {
}
if ( is_null( $matchingNamespaceCode ) ) {
- return wfMessage( 'pf-missingnamespace', wfEscapeWikiText( $namespace_name ) );
+ throw new MWException( wfMessage( 'pf-missingnamespace', wfEscapeWikiText( $namespace_name ) ) );
}
$db = wfGetDB( DB_SLAVE );
@@ -469,13 +469,7 @@ class PFValuesUtils {
$conditions[] = self::getSQLConditionForAutocompleteInColumn( 'page_title', $substring );
}
}
- $res = $db->select(
- $tables,
- $columns,
- $conditions,
- __METHOD__,
- $options = array(),
- $join );
+ $res = $db->select( $tables, $columns, $conditions, __METHOD__, $options = array(), $join );
$pages = array();
$sortkeys = array();
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_CheckboxesInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_CheckboxesInput.php
index af5333c0..03a93ca8 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_CheckboxesInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_CheckboxesInput.php
@@ -41,7 +41,7 @@ class PFCheckboxesInput extends PFMultiEnumInput {
if ( array_key_exists( 'class', $other_args ) ) {
$labelClass .= ' ' . $other_args['class'];
}
- $input_id = "input_$wgPageFormsFieldNum";
+ $input_prefix_id = "input_$wgPageFormsFieldNum";
// get list delimiter - default is comma
if ( array_key_exists( 'delimiter', $other_args ) ) {
$delimiter = $other_args['delimiter'];
@@ -54,7 +54,10 @@ class PFCheckboxesInput extends PFMultiEnumInput {
$possible_values = array();
}
$text = '';
+ $valIndex = 0;
foreach ( $possible_values as $key => $possible_value ) {
+ $valIndex ++;
+ $input_id = $input_prefix_id . '_' . $valIndex;
$cur_input_name = $input_name . '[' . $key . ']';
if (
@@ -83,7 +86,7 @@ class PFCheckboxesInput extends PFMultiEnumInput {
// Put a <label> tag around each checkbox, for CSS
// purposes as well as to clarify this element.
$text .= "\t" . Html::rawElement( 'label',
- array( 'class' => $labelClass ),
+ array( 'class' => $labelClass, 'for' => $input_id ),
$checkbox_input . '&nbsp;' . $label
) . " ";
$wgPageFormsTabIndex++;
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_DateInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_DateInput.php
index 55decc7f..7bec5c16 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_DateInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_DateInput.php
@@ -53,6 +53,8 @@ class PFDateInput extends PFFormInput {
}
static function parseDate( $date ) {
+ global $wgLanguageCode;
+
// Special handling for 'default=now'.
if ( $date == 'now' ) {
global $wgLocaltimezone;
@@ -75,6 +77,36 @@ class PFDateInput extends PFFormInput {
}
$seconds = strtotime( $date );
+
+ // If strtotime() parsing didn't work, it may be because the
+ // date contains a month name in a language other than English.
+ // (Page Forms only puts in a month name if there's no day
+ // value, but the date text could also be coming from an
+ // outside source.)
+ if ( $seconds == null && $wgLanguageCode != 'en' ) {
+ $date = strtolower( $date );
+ $monthNames = PFFormUtils::getMonthNames();
+ $englishMonthNames = array( 'January', 'February',
+ 'March', 'April', 'May', 'June', 'July',
+ 'August', 'September', 'October', 'November',
+ 'December' );
+ foreach ( $monthNames as $i => $monthName ) {
+ $monthName = strtolower( $monthName );
+ if ( strpos( $date, $monthName ) !== false ) {
+ $englishMonthName = $englishMonthNames[$i];
+ $date = str_replace( $monthName,
+ $englishMonthName, $date );
+ break;
+ }
+ }
+ $seconds = strtotime( $date );
+ }
+
+ // If we still don't have a date value, exit.
+ if ( $seconds == null ) {
+ return array( null, null, null );
+ }
+
$year = date( 'Y', $seconds );
$month = date( 'm', $seconds );
// Determine if there's a month but no day. There's no ideal
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_DatePickerInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_DatePickerInput.php
index a4b6a505..ebbcbdf0 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_DatePickerInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_DatePickerInput.php
@@ -388,27 +388,31 @@ class PFDatePickerInput extends PFFormInput {
}
// register highlighted dates with datepicker
- if ( count( $highlightedDates ) > 0 ) {
- // Convert the PHP array of date ranges into an // array of numbers.
- $jsattribs["highlightedDates"] = array_map(
- function ( $range ) {
- $y0 = $range[0]->format( "Y" );
- $m0 = $range[0]->format( "m" ) - 1;
- $d0 = $range[0]->format( "d" );
-
- $y1 = $range[1]->format( "Y" );
- $m1 = $range[1]->format( "m" ) - 1;
- $d1 = $range[1]->format( "d" );
-
- return array( $y0, $m0, $d0, $y1, $m1, $d1 );
- },
- $highlightedDates
- );
+ if (is_array($highlightedDates)) {
+ if ( count( $highlightedDates ) > 0 ) {
+ // Convert the PHP array of date ranges into an // array of numbers.
+ $jsattribs["highlightedDates"] = array_map(
+ function ( $range ) {
+ $y0 = $range[0]->format( "Y" );
+ $m0 = $range[0]->format( "m" ) - 1;
+ $d0 = $range[0]->format( "d" );
+
+ $y1 = $range[1]->format( "Y" );
+ $m1 = $range[1]->format( "m" ) - 1;
+ $d1 = $range[1]->format( "d" );
+
+ return array( $y0, $m0, $d0, $y1, $m1, $d1 );
+ },
+ $highlightedDates
+ );
+ }
}
// register disabled days of week with datepicker
- if ( count( $disabledDays ) > 0 ) {
- $jsattribs["disabledDays"] = $disabledDays;
+ if (is_array($disabledDays)) {
+ if ( count( $disabledDays ) > 0 ) {
+ $jsattribs["disabledDays"] = $disabledDays;
+ }
}
// register highlighted days of week with datepicker
@@ -637,8 +641,8 @@ class PFDatePickerInput extends PFFormInput {
* @param string $inputName
* @param bool $isDisabled
* @param array $otherArgs
- * @param string $inputId (optional)
- * @param int $tabIndex (optional)
+ * @param string|null $inputId (optional)
+ * @param int|null $tabIndex (optional)
* @param string $class
* @return string the html text of an input element
*/
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimeInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimeInput.php
index 2cbfdd8b..16e14c21 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimeInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimeInput.php
@@ -60,31 +60,25 @@ class PFDateTimeInput extends PFDateInput {
// Handle 'default=now'.
if ( $datetime == 'now' ) {
global $wgLocaltimezone;
- if ( isset( $wgLocaltimezone ) ) {
- $serverTimezone = date_default_timezone_get();
- date_default_timezone_set( $wgLocaltimezone );
+ if ( $wgLocaltimezone == null ) {
+ $dateTimeObject = new DateTime( 'now' );
+ } else {
+ $dateTimeObject = new DateTime( 'now', new DateTimeZone( $wgLocaltimezone ) );
}
- $actual_date = time();
} else {
- $actual_date = strtotime( $datetime );
+ $dateTimeObject = new DateTime( $datetime );
}
if ( $wgPageForms24HourTime ) {
- $hour = date( 'G', $actual_date );
+ $hour = $dateTimeObject->format( 'G' );
} else {
- $hour = date( 'g', $actual_date );
+ $hour = $dateTimeObject->format( 'g' );
}
- $minute = date( 'i', $actual_date );
- $second = date( 's', $actual_date );
+ $minute = $dateTimeObject->format( 'i' );
+ $second = $dateTimeObject->format( 's' );
if ( !$wgPageForms24HourTime ) {
- $ampm24h = date( 'A', $actual_date );
- }
- $timezone = date( 'T', $actual_date );
- // Restore back to the server's timezone.
- if ( $datetime == 'now' ) {
- if ( isset( $wgLocaltimezone ) ) {
- date_default_timezone_set( $serverTimezone );
- }
+ $ampm24h = $dateTimeObject->format( 'A' );
}
+ $timezone = $dateTimeObject->format( 'T' );
}
} else {
$hour = null;
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimePicker.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimePicker.php
index 43c962a2..e5bde117 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimePicker.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_DateTimePicker.php
@@ -23,6 +23,9 @@ class PFDateTimePicker extends PFFormInput {
* input definition.
*/
public function __construct( $input_number, $cur_value, $input_name, $disabled, $other_args ) {
+ if ( $cur_value == 'now' ) {
+ $cur_value = date( 'Y/m/d H:i' ); // include hours and minutes
+ }
parent::__construct( $input_number, $cur_value, $input_name, $disabled, $other_args );
// prepare sub-inputs
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_FormInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_FormInput.php
index 8875cd9e..d88323f4 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_FormInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_FormInput.php
@@ -214,7 +214,7 @@ abstract class PFFormInput {
*
*
* @param string $name The name of the initialization function.
- * @param string $param The parameter passed to the initialization function.
+ * @param string|null $param The parameter passed to the initialization function.
*/
public function addJsInitFunctionData( $name, $param = null ) {
if ( is_string( $param ) ) {
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_ListBoxInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_ListBoxInput.php
index b6047fdd..40b05462 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_ListBoxInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_ListBoxInput.php
@@ -42,7 +42,7 @@ class PFListBoxInput extends PFMultiEnumInput {
$delimiter = ',';
}
$cur_values = PFValuesUtils::getValuesArray( $this->mCurrentValue, $delimiter );
- $className .= ' PfShowIfSelected';
+ $className .= ' pfShowIfSelected';
if ( ( $possible_values = $this->mOtherArgs['possible_values'] ) == null ) {
$possible_values = array();
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_TextAreaInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_TextAreaInput.php
index 06589bfc..3c74713c 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_TextAreaInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_TextAreaInput.php
@@ -13,12 +13,16 @@ class PFTextAreaInput extends PFFormInput {
protected $mEditor = null;
public static function getDefaultCargoTypes() {
- return array( 'Text' => array() );
+ return array(
+ 'Text' => array(),
+ 'Searchtext' => array()
+ );
}
public static function getDefaultCargoTypeLists() {
return array(
- 'Text' => array( 'field_type' => 'text', 'is_list' => 'true' )
+ 'Text' => array( 'field_type' => 'text', 'is_list' => 'true' ),
+ 'Searchtext' => array( 'field_type' => 'text', 'is_list' => 'true' )
);
}
@@ -49,6 +53,15 @@ class PFTextAreaInput extends PFFormInput {
$this->addJsInitFunctionData( 'window.ext.wikieditor.init' );
}
+ // VisualEditor (plus VEForAll)
+ if (
+ array_key_exists( 'editor', $this->mOtherArgs ) &&
+ $this->mOtherArgs['editor'] == 'visualeditor' &&
+ ExtensionRegistry::getInstance()->isLoaded( 'VisualEditor' )
+ ) {
+ $this->mEditor = 'visualeditor';
+ }
+
// TinyMCE
if (
array_key_exists( 'editor', $this->mOtherArgs ) &&
@@ -152,6 +165,8 @@ class PFTextAreaInput extends PFFormInput {
public function getResourceModuleNames() {
if ( $this->mEditor == 'wikieditor' ) {
return 'ext.pageforms.wikieditor';
+ } elseif ( $this->mEditor == 'visualeditor' ) {
+ return 'ext.veforall.main';
} elseif ( $this->mEditor == 'tinymce' ) {
return 'ext.tinymce';
} else {
@@ -178,6 +193,8 @@ class PFTextAreaInput extends PFFormInput {
$editPage = new EditPage( $article );
WikiEditorHooks::editPageShowEditFormInitial( $editPage, $wgOut );
$className = 'wikieditor ';
+ } elseif ( $this->mEditor == 'visualeditor' ) {
+ $className = 'visualeditor ';
} elseif ( $this->mEditor == 'tinymce' ) {
$className = 'tinymce ';
} else {
@@ -288,6 +305,9 @@ class PFTextAreaInput extends PFFormInput {
if ( array_key_exists( 'unique', $this->mOtherArgs ) ) {
$spanClass .= ' uniqueFieldSpan';
}
+ if ( $this->mEditor == 'visualeditor' ) {
+ $spanClass .= ' ve-area-wrapper';
+ }
$text = Html::rawElement( 'span', array( 'class' => $spanClass ), $text );
return $text;
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_TextInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_TextInput.php
index 9fc229d8..33aa95f9 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_TextInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_TextInput.php
@@ -150,7 +150,8 @@ class PFTextInput extends PFFormInput {
}
public static function uploadableHTML( $input_id, $delimiter = null, $default_filename = null, $cur_value = '', $other_args = array() ) {
- global $wgPageFormsSimpleUpload, $wgPageFormsScriptPath;
+ global $wgPageFormsSimpleUpload, $wgPageFormsScriptPath,
+ $wgVersion;
if ( $wgPageFormsSimpleUpload ) {
$text = "\n" . '<img class="loading" style="display:none;" src="' . $wgPageFormsScriptPath . '/skins/loading.gif"/>' . "\n";
$text .= Html::input( '',
@@ -211,9 +212,12 @@ class PFTextInput extends PFFormInput {
// 'title' => $upload_label,
'rev' => $style,
'data-input-id' => $input_id,
- 'data-type' => 'iframe'
);
+ if ( version_compare( $wgVersion, '1.30', '>=' ) ) {
+ $linkAttrs['data-type'] = 'iframe';
+ }
+
$text = "\t" . Html::element( 'a', $linkAttrs, $upload_label ) . "\n";
if ( $showPreview ) {
diff --git a/www/wiki/extensions/PageForms/includes/forminputs/PF_TreeInput.php b/www/wiki/extensions/PageForms/includes/forminputs/PF_TreeInput.php
index 48db84c4..c4aa0a53 100644
--- a/www/wiki/extensions/PageForms/includes/forminputs/PF_TreeInput.php
+++ b/www/wiki/extensions/PageForms/includes/forminputs/PF_TreeInput.php
@@ -68,7 +68,7 @@ class PFTreeInput extends PFFormInput {
} else {
$is_list = ( array_key_exists( 'is_list', $other_args ) && $other_args['is_list'] == true );
if ( $is_list ) {
- $inputType = "checkbox";
+ $inputType = "checkbox";
self::$multipleSelect = true;
} else {
$inputType = "radio";
@@ -119,8 +119,8 @@ class PFTreeInput extends PFFormInput {
// Escape - we can't do anything.
return null;
}
-
- $inputText = self::treeToHTML( $tree, $input_name, $cur_values, $hideroot, $depth, $inputType );
+
+ $inputText = self::treeToHTML( $tree, $input_name, $cur_values, $hideroot, $depth, $inputType );
// Replace values one at a time, by an incrementing index -
// inspired by http://bugs.php.net/bug.php?id=11457
@@ -171,8 +171,14 @@ class PFTreeInput extends PFFormInput {
$text = '';
- // HTML IDs can't contain spaces.
- $key_id = str_replace( ' ', '-', "$key_prefix-$index" );
+ $key_id = "$key_prefix-$index";
+ // Replace characters not allowed in HTML IDs.
+ $key_id = preg_replace( '/[^a-zA-Z0-9-_:\.]/', '-', $key_id );
+ // Make sure it starts with a letter.
+ preg_match( '/$[^a-zA-Z]/', $key_id, $matches );
+ if ( count( $matches ) > 0 ) {
+ $key_id = 'a' . $key_id;
+ }
if ( !$hidenode ) {
$liAttribs = array( 'id' => $key_id );
@@ -202,8 +208,13 @@ class PFTreeInput extends PFFormInput {
}
$text .= Html::input( $cur_input_name, $node->title, $inputType, $nodeAttribs );
-
- $text .= $node->title . "\n";
+
+ $categoryTitle = $node->title;
+ if(class_exists('CategoryManagerCore')){
+ $title = Title::makeTitleSafe(NS_CATEGORY, $node->title);
+ $categoryTitle = CategoryManagerCore::getTranslatedCategoryTitle($title);
+ }
+ $text .= $categoryTitle . "\n";
}
if ( array_key_exists( 'children', $node ) ) {
@@ -290,5 +301,4 @@ class PFTreeInput extends PFFormInput {
}
return $t;
}
-
}
diff --git a/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPage.php b/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPage.php
index b7c4efc0..6d7f8797 100644
--- a/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPage.php
+++ b/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPage.php
@@ -51,14 +51,17 @@ class PFWikiPage {
$this->mComponents[] = new PFWikiPageSection( $sectionName, $headerLevel, $sectionText, $sectionOptions );
}
- function addFreeTextSection() {
- $this->mComponents[] = new PFWikiPageFreeText();
+ function addFreeTextSection($options = []) {
+ $this->mComponents[] = new PFWikiPageFreeText($options);
}
- function setFreeText( $text ) {
+ function setFreeText( &$text, $form_submitted = FALSE ) {
foreach ( $this->mComponents as $i => $component ) {
if ( get_class( $component ) == 'PFWikiPageFreeText' ) {
- $this->mComponents[$i]->setText( $text );
+ // call to PFWikiPageFreeText->setText()
+ // we pass $text by reference, so that translate tags get removed for displaying and put back
+ // when submitting the form
+ $this->mComponents[$i]->setText( $text, $form_submitted );
return;
}
}
diff --git a/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageFreeText.php b/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageFreeText.php
index ecb9c390..1e46427d 100644
--- a/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageFreeText.php
+++ b/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageFreeText.php
@@ -11,12 +11,51 @@
*/
class PFWikiPageFreeText {
private $mText;
+ private $mOptions;
+
+ function __construct( $options = [] ) {
+ $this->mOptions = $options;
+ }
+
+ function setText( &$text, $form_submitted = FALSE ) {
+
+ if ( $this->isTranslateEnabled() && isset($this->mOptions['translatable']) && $this->mOptions['translatable']) {
+
+ if (!$form_submitted) {
+ // remove translate tags when displaying the form as it messes up with VE
+ if(preg_match('#^<translate>([\S\s]*)<\/translate>$#m', $text, $matches)) {
+ $text = $matches[1];
+ }
+ } else {
+ // fix : rearrange <!--T:<number>--> tags to avoid errors
+ // 4 cases :
+ // 1 : text<tag> => text\n\n<tag>
+ // 2 : <tag>text => <tag>\ntext
+ // 3 : <tag>\n* => <tag>\n\n
+ // 4 : \n*<tag> => \n\n<tag>
+ $text = preg_replace(['#([^\s])(<!--T:\d+-->)#m', '#(<!--T:\d+-->)([^\s])#m', '#(<!--T:\d+-->)([\s]+)#m', '#([\s]+)(<!--T:\d+-->)#m'], ["$1\n\n$2", "$1\n$2", "$1\n", "\n\n$2"], $text);
+
+ // put translate tags back
+ $text = '<translate>' . $text .'</translate>';
+ }
+ }
- function setText( $text ) {
$this->mText = $text;
}
+ function isTranslateEnabled() {
+ return class_exists('SpecialTranslate');
+ }
+
function getText() {
return $this->mText;
}
-}
+
+ function getOptions() {
+ return $this->mOptions;
+ }
+
+ function setOptions( $options ) {
+ $this->mOptions = $options;
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageTemplateParam.php b/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageTemplateParam.php
index bb1d8fd2..599dfc09 100644
--- a/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageTemplateParam.php
+++ b/www/wiki/extensions/PageForms/includes/wikipage/PF_WikiPageTemplateParam.php
@@ -32,6 +32,13 @@ class PFWikiPageTemplateParam {
$value = $this->mValue;
if ( $this->isTranslateEnabled() && isset($this->mOptions['translatable']) && $this->mOptions['translatable']) {
if( strpos($value, '<translate>') === false) {
+ // fix : rearrange <!--T:<number>--> tags to avoid errors
+ // 4 cases :
+ // 1 : text<tag> => text\n\n<tag>
+ // 2 : <tag>text => <tag>\ntext
+ // 3 : <tag>\n* => <tag>\n\n
+ // 4 : \n*<tag> => \n\n<tag>
+ $value = preg_replace(['#([^\s])(<!--T:\d+-->)#m', '#(<!--T:\d+-->)([^\s])#m', '#(<!--T:\d+-->)([\s]+)#m', '#([\s]+)(<!--T:\d+-->)#m'], ["$1\n\n$2", "$1\n$2", "$1\n", "\n\n$2"], $value);
$value = '<translate>' . $value .'</translate>';
}
}
diff --git a/www/wiki/extensions/PageForms/languages/PF_Aliases.php b/www/wiki/extensions/PageForms/languages/PF_Aliases.php
index 455e4463..f4557d0a 100644
--- a/www/wiki/extensions/PageForms/languages/PF_Aliases.php
+++ b/www/wiki/extensions/PageForms/languages/PF_Aliases.php
@@ -6,7 +6,6 @@
* @ingroup Extensions
* @ingroup PF
*/
-// @codingStandardsIgnoreFile
$specialPageAliases = array();
@@ -17,6 +16,7 @@ $specialPageAliases['en'] = array(
'CreateForm' => array( 'CreateForm' ),
'CreateProperty' => array( 'CreateProperty' ),
'CreateTemplate' => array( 'CreateTemplate' ),
+ 'MultiPageEdit' => array( 'MultiPageEdit' ),
'FormEdit' => array( 'FormEdit', 'AddData', 'EditData' ),
'FormStart' => array( 'FormStart', 'AddPage' ),
'Forms' => array( 'Forms' ),
diff --git a/www/wiki/extensions/PageForms/languages/PF_Namespaces.php b/www/wiki/extensions/PageForms/languages/PF_Namespaces.php
index 68228542..fedee106 100644
--- a/www/wiki/extensions/PageForms/languages/PF_Namespaces.php
+++ b/www/wiki/extensions/PageForms/languages/PF_Namespaces.php
@@ -8,7 +8,7 @@
* @file PF_Namespaces.php
* @ingroup PageForms
*
- * @licence GNU GPL v2+
+ * @license GPL-2.0-or-later
* @author Jeroen De Dauw < jeroendedauw@gmail.com >
* @author Yaron Koren
*/
diff --git a/www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.1.3.4.js b/www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.1.3.4.js
new file mode 100644
index 00000000..a974b992
--- /dev/null
+++ b/www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.1.3.4.js
@@ -0,0 +1,1152 @@
+/*
+ * FancyBox - jQuery Plugin
+ * Simple and fancy lightbox alternative
+ *
+ * Examples and documentation at: http://fancybox.net
+ *
+ * Copyright (c) 2008 - 2010 Janis Skarnelis
+ * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
+ *
+ * Version: 1.3.4 (11/11/2010)
+ * Requires: jQuery v1.3+
+ *
+ * Dual licensed under the MIT and GPL licenses:
+ * http://www.opensource.org/licenses/mit-license.php
+ * http://www.gnu.org/licenses/gpl.html
+ */
+
+;(function($) {
+ var tmp, loading, overlay, wrap, outer, content, close, title, nav_left, nav_right,
+
+ selectedIndex = 0, selectedOpts = {}, selectedArray = [], currentIndex = 0, currentOpts = {}, currentArray = [],
+
+ ajaxLoader = null, imgPreloader = new Image(), imgRegExp = /\.(jpg|gif|png|bmp|jpeg)(.*)?$/i, swfRegExp = /[^\.]\.(swf)\s*$/i,
+
+ loadingTimer, loadingFrame = 1,
+
+ titleHeight = 0, titleStr = '', start_pos, final_pos, busy = false, fx = $.extend($('<div/>')[0], { prop: 0 }),
+
+ isIE6 = $.browser.msie && $.browser.version < 7 && !window.XMLHttpRequest,
+
+ /*
+ * Private methods
+ */
+
+ _abort = function() {
+ loading.hide();
+
+ imgPreloader.onerror = imgPreloader.onload = null;
+
+ if (ajaxLoader) {
+ ajaxLoader.abort();
+ }
+
+ tmp.empty();
+ },
+
+ _error = function() {
+ if (false === selectedOpts.onError(selectedArray, selectedIndex, selectedOpts)) {
+ loading.hide();
+ busy = false;
+ return;
+ }
+
+ selectedOpts.titleShow = false;
+
+ selectedOpts.width = 'auto';
+ selectedOpts.height = 'auto';
+
+ tmp.html( '<p id="fancybox-error">The requested content cannot be loaded.<br />Please try again later.</p>' );
+
+ _process_inline();
+ },
+
+ _start = function() {
+ var obj = selectedArray[ selectedIndex ],
+ href,
+ type,
+ title,
+ str,
+ emb,
+ ret;
+
+ _abort();
+
+ selectedOpts = $.extend({}, $.fn.fancybox.defaults, (typeof $(obj).data('fancybox') == 'undefined' ? selectedOpts : $(obj).data('fancybox')));
+
+ ret = selectedOpts.onStart(selectedArray, selectedIndex, selectedOpts);
+
+ if (ret === false) {
+ busy = false;
+ return;
+ } else if (typeof ret == 'object') {
+ selectedOpts = $.extend(selectedOpts, ret);
+ }
+
+ title = selectedOpts.title || (obj.nodeName ? $(obj).attr('title') : obj.title) || '';
+
+ if (obj.nodeName && !selectedOpts.orig) {
+ selectedOpts.orig = $(obj).children("img:first").length ? $(obj).children("img:first") : $(obj);
+ }
+
+ if (title === '' && selectedOpts.orig && selectedOpts.titleFromAlt) {
+ title = selectedOpts.orig.attr('alt');
+ }
+
+ href = selectedOpts.href || (obj.nodeName ? $(obj).attr('href') : obj.href) || null;
+
+ if ((/^(?:javascript)/i).test(href) || href == '#') {
+ href = null;
+ }
+
+ if (selectedOpts.type) {
+ type = selectedOpts.type;
+
+ if (!href) {
+ href = selectedOpts.content;
+ }
+
+ } else if (selectedOpts.content) {
+ type = 'html';
+
+ } else if (href) {
+ if (href.match(imgRegExp)) {
+ type = 'image';
+
+ } else if (href.match(swfRegExp)) {
+ type = 'swf';
+
+ } else if ($(obj).hasClass("iframe")) {
+ type = 'iframe';
+
+ } else if (href.indexOf("#") === 0) {
+ type = 'inline';
+
+ } else {
+ type = 'ajax';
+ }
+ }
+
+ if (!type) {
+ _error();
+ return;
+ }
+
+ if (type == 'inline') {
+ obj = href.substr(href.indexOf("#"));
+ type = $(obj).length > 0 ? 'inline' : 'ajax';
+ }
+
+ selectedOpts.type = type;
+ selectedOpts.href = href;
+ selectedOpts.title = title;
+
+ if (selectedOpts.autoDimensions) {
+ if (selectedOpts.type == 'html' || selectedOpts.type == 'inline' || selectedOpts.type == 'ajax') {
+ selectedOpts.width = 'auto';
+ selectedOpts.height = 'auto';
+ } else {
+ selectedOpts.autoDimensions = false;
+ }
+ }
+
+ if (selectedOpts.modal) {
+ selectedOpts.overlayShow = true;
+ selectedOpts.hideOnOverlayClick = false;
+ selectedOpts.hideOnContentClick = false;
+ selectedOpts.enableEscapeButton = false;
+ selectedOpts.showCloseButton = false;
+ }
+
+ selectedOpts.padding = parseInt(selectedOpts.padding, 10);
+ selectedOpts.margin = parseInt(selectedOpts.margin, 10);
+
+ tmp.css('padding', (selectedOpts.padding + selectedOpts.margin));
+
+ $('.fancybox-inline-tmp').unbind('fancybox-cancel').bind('fancybox-change', function() {
+ $(this).replaceWith(content.children());
+ });
+
+ switch (type) {
+ case 'html' :
+ tmp.html( selectedOpts.content );
+ _process_inline();
+ break;
+
+ case 'inline' :
+ if ( $(obj).parent().is('#fancybox-content') === true) {
+ busy = false;
+ return;
+ }
+
+ $('<div class="fancybox-inline-tmp" />')
+ .hide()
+ .insertBefore( $(obj) )
+ .bind('fancybox-cleanup', function() {
+ $(this).replaceWith(content.children());
+ }).bind('fancybox-cancel', function() {
+ $(this).replaceWith(tmp.children());
+ });
+
+ $(obj).appendTo(tmp);
+
+ _process_inline();
+ break;
+
+ case 'image':
+ busy = false;
+
+ $.fancybox.showActivity();
+
+ imgPreloader = new Image();
+
+ imgPreloader.onerror = function() {
+ _error();
+ };
+
+ imgPreloader.onload = function() {
+ busy = true;
+
+ imgPreloader.onerror = imgPreloader.onload = null;
+
+ _process_image();
+ };
+
+ imgPreloader.src = href;
+ break;
+
+ case 'swf':
+ selectedOpts.scrolling = 'no';
+
+ str = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="' + selectedOpts.width + '" height="' + selectedOpts.height + '"><param name="movie" value="' + href + '"></param>';
+ emb = '';
+
+ $.each(selectedOpts.swf, function(name, val) {
+ str += '<param name="' + name + '" value="' + val + '"></param>';
+ emb += ' ' + name + '="' + val + '"';
+ });
+
+ str += '<embed src="' + href + '" type="application/x-shockwave-flash" width="' + selectedOpts.width + '" height="' + selectedOpts.height + '"' + emb + '></embed></object>';
+
+ tmp.html(str);
+
+ _process_inline();
+ break;
+
+ case 'ajax':
+ busy = false;
+
+ $.fancybox.showActivity();
+
+ selectedOpts.ajax.win = selectedOpts.ajax.success;
+
+ ajaxLoader = $.ajax($.extend({}, selectedOpts.ajax, {
+ url : href,
+ data : selectedOpts.ajax.data || {},
+ error : function(XMLHttpRequest, textStatus, errorThrown) {
+ if ( XMLHttpRequest.status > 0 ) {
+ _error();
+ }
+ },
+ success : function(data, textStatus, XMLHttpRequest) {
+ var o = typeof XMLHttpRequest == 'object' ? XMLHttpRequest : ajaxLoader;
+ if (o.status == 200) {
+ if ( typeof selectedOpts.ajax.win == 'function' ) {
+ ret = selectedOpts.ajax.win(href, data, textStatus, XMLHttpRequest);
+
+ if (ret === false) {
+ loading.hide();
+ return;
+ } else if (typeof ret == 'string' || typeof ret == 'object') {
+ data = ret;
+ }
+ }
+
+ tmp.html( data );
+ _process_inline();
+ }
+ }
+ }));
+
+ break;
+
+ case 'iframe':
+ _show();
+ break;
+ }
+ },
+
+ _process_inline = function() {
+ var
+ w = selectedOpts.width,
+ h = selectedOpts.height;
+
+ if (w.toString().indexOf('%') > -1) {
+ w = parseInt( ($(window).width() - (selectedOpts.margin * 2)) * parseFloat(w) / 100, 10) + 'px';
+
+ } else {
+ w = w == 'auto' ? 'auto' : w + 'px';
+ }
+
+ if (h.toString().indexOf('%') > -1) {
+ h = parseInt( ($(window).height() - (selectedOpts.margin * 2)) * parseFloat(h) / 100, 10) + 'px';
+
+ } else {
+ h = h == 'auto' ? 'auto' : h + 'px';
+ }
+
+ tmp.wrapInner('<div style="width:' + w + ';height:' + h + ';overflow: ' + (selectedOpts.scrolling == 'auto' ? 'auto' : (selectedOpts.scrolling == 'yes' ? 'scroll' : 'hidden')) + ';position:relative;"></div>');
+
+ selectedOpts.width = tmp.width();
+ selectedOpts.height = tmp.height();
+
+ _show();
+ },
+
+ _process_image = function() {
+ selectedOpts.width = imgPreloader.width;
+ selectedOpts.height = imgPreloader.height;
+
+ $("<img />").attr({
+ 'id' : 'fancybox-img',
+ 'src' : imgPreloader.src,
+ 'alt' : selectedOpts.title
+ }).appendTo( tmp );
+
+ _show();
+ },
+
+ _show = function() {
+ var pos, equal;
+
+ loading.hide();
+
+ if (wrap.is(":visible") && false === currentOpts.onCleanup(currentArray, currentIndex, currentOpts)) {
+ $.event.trigger('fancybox-cancel');
+
+ busy = false;
+ return;
+ }
+
+ busy = true;
+
+ $(content.add( overlay )).unbind();
+
+ $(window).unbind("resize.fb scroll.fb");
+ $(document).unbind('keydown.fb');
+
+ if (wrap.is(":visible") && currentOpts.titlePosition !== 'outside') {
+ wrap.css('height', wrap.height());
+ }
+
+ currentArray = selectedArray;
+ currentIndex = selectedIndex;
+ currentOpts = selectedOpts;
+
+ if (currentOpts.overlayShow) {
+ overlay.css({
+ 'background-color' : currentOpts.overlayColor,
+ 'opacity' : currentOpts.overlayOpacity,
+ 'cursor' : currentOpts.hideOnOverlayClick ? 'pointer' : 'auto',
+ 'height' : $(document).height()
+ });
+
+ if (!overlay.is(':visible')) {
+ if (isIE6) {
+ $('select:not(#fancybox-tmp select)').filter(function() {
+ return this.style.visibility !== 'hidden';
+ }).css({'visibility' : 'hidden'}).one('fancybox-cleanup', function() {
+ this.style.visibility = 'inherit';
+ });
+ }
+
+ overlay.show();
+ }
+ } else {
+ overlay.hide();
+ }
+
+ final_pos = _get_zoom_to();
+
+ _process_title();
+
+ if (wrap.is(":visible")) {
+ $( close.add( nav_left ).add( nav_right ) ).hide();
+
+ pos = wrap.position();
+
+ start_pos = {
+ top : pos.top,
+ left : pos.left,
+ width : wrap.width(),
+ height : wrap.height()
+ };
+
+ equal = (start_pos.width == final_pos.width && start_pos.height == final_pos.height);
+
+ content.fadeTo(currentOpts.changeFade, 0.3, function() {
+ var finish_resizing = function() {
+ content.html( tmp.contents() ).fadeTo(currentOpts.changeFade, 1, _finish);
+ };
+
+ $.event.trigger('fancybox-change');
+
+ content
+ .empty()
+ .removeAttr('filter')
+ .css({
+ 'border-width' : currentOpts.padding,
+ 'width' : final_pos.width - currentOpts.padding * 2,
+ 'height' : selectedOpts.autoDimensions ? 'auto' : final_pos.height - titleHeight - currentOpts.padding * 2
+ });
+
+ if (equal) {
+ finish_resizing();
+
+ } else {
+ fx.prop = 0;
+
+ $(fx).animate({prop: 1}, {
+ duration : currentOpts.changeSpeed,
+ easing : currentOpts.easingChange,
+ step : _draw,
+ complete : finish_resizing
+ });
+ }
+ });
+
+ return;
+ }
+
+ wrap.removeAttr("style");
+
+ content.css('border-width', currentOpts.padding);
+
+ if (currentOpts.transitionIn == 'elastic') {
+ start_pos = _get_zoom_from();
+
+ content.html( tmp.contents() );
+
+ wrap.show();
+
+ if (currentOpts.opacity) {
+ final_pos.opacity = 0;
+ }
+
+ fx.prop = 0;
+
+ $(fx).animate({prop: 1}, {
+ duration : currentOpts.speedIn,
+ easing : currentOpts.easingIn,
+ step : _draw,
+ complete : _finish
+ });
+
+ return;
+ }
+
+ if (currentOpts.titlePosition == 'inside' && titleHeight > 0) {
+ title.show();
+ }
+
+ content
+ .css({
+ 'width' : final_pos.width - currentOpts.padding * 2,
+ 'height' : selectedOpts.autoDimensions ? 'auto' : final_pos.height - titleHeight - currentOpts.padding * 2
+ })
+ .html( tmp.contents() );
+
+ wrap
+ .css(final_pos)
+ .fadeIn( currentOpts.transitionIn == 'none' ? 0 : currentOpts.speedIn, _finish );
+ },
+
+ _format_title = function(title) {
+ if (title && title.length) {
+ if (currentOpts.titlePosition == 'float') {
+ return '<table id="fancybox-title-float-wrap" cellpadding="0" cellspacing="0"><tr><td id="fancybox-title-float-left"></td><td id="fancybox-title-float-main">' + title + '</td><td id="fancybox-title-float-right"></td></tr></table>';
+ }
+
+ return '<div id="fancybox-title-' + currentOpts.titlePosition + '">' + title + '</div>';
+ }
+
+ return false;
+ },
+
+ _process_title = function() {
+ titleStr = currentOpts.title || '';
+ titleHeight = 0;
+
+ title
+ .empty()
+ .removeAttr('style')
+ .removeClass();
+
+ if (currentOpts.titleShow === false) {
+ title.hide();
+ return;
+ }
+
+ titleStr = $.isFunction(currentOpts.titleFormat) ? currentOpts.titleFormat(titleStr, currentArray, currentIndex, currentOpts) : _format_title(titleStr);
+
+ if (!titleStr || titleStr === '') {
+ title.hide();
+ return;
+ }
+
+ title
+ .addClass('fancybox-title-' + currentOpts.titlePosition)
+ .html( titleStr )
+ .appendTo( 'body' )
+ .show();
+
+ switch (currentOpts.titlePosition) {
+ case 'inside':
+ title
+ .css({
+ 'width' : final_pos.width - (currentOpts.padding * 2),
+ 'marginLeft' : currentOpts.padding,
+ 'marginRight' : currentOpts.padding
+ });
+
+ titleHeight = title.outerHeight(true);
+
+ title.appendTo( outer );
+
+ final_pos.height += titleHeight;
+ break;
+
+ case 'over':
+ title
+ .css({
+ 'marginLeft' : currentOpts.padding,
+ 'width' : final_pos.width - (currentOpts.padding * 2),
+ 'bottom' : currentOpts.padding
+ })
+ .appendTo( outer );
+ break;
+
+ case 'float':
+ title
+ .css('left', parseInt((title.width() - final_pos.width - 40)/ 2, 10) * -1)
+ .appendTo( wrap );
+ break;
+
+ default:
+ title
+ .css({
+ 'width' : final_pos.width - (currentOpts.padding * 2),
+ 'paddingLeft' : currentOpts.padding,
+ 'paddingRight' : currentOpts.padding
+ })
+ .appendTo( wrap );
+ break;
+ }
+
+ title.hide();
+ },
+
+ _set_navigation = function() {
+ if (currentOpts.enableEscapeButton || currentOpts.enableKeyboardNav) {
+ $(document).bind('keydown.fb', function(e) {
+ if (e.keyCode == 27 && currentOpts.enableEscapeButton) {
+ e.preventDefault();
+ $.fancybox.close();
+
+ } else if ((e.keyCode == 37 || e.keyCode == 39) && currentOpts.enableKeyboardNav && e.target.tagName !== 'INPUT' && e.target.tagName !== 'TEXTAREA' && e.target.tagName !== 'SELECT') {
+ e.preventDefault();
+ $.fancybox[ e.keyCode == 37 ? 'prev' : 'next']();
+ }
+ });
+ }
+
+ if (!currentOpts.showNavArrows) {
+ nav_left.hide();
+ nav_right.hide();
+ return;
+ }
+
+ if ((currentOpts.cyclic && currentArray.length > 1) || currentIndex !== 0) {
+ nav_left.show();
+ }
+
+ if ((currentOpts.cyclic && currentArray.length > 1) || currentIndex != (currentArray.length -1)) {
+ nav_right.show();
+ }
+ },
+
+ _finish = function () {
+ if (!$.support.opacity) {
+ content.get(0).style.removeAttribute('filter');
+ wrap.get(0).style.removeAttribute('filter');
+ }
+
+ if (selectedOpts.autoDimensions) {
+ content.css('height', 'auto');
+ }
+
+ wrap.css('height', 'auto');
+
+ if (titleStr && titleStr.length) {
+ title.show();
+ }
+
+ if (currentOpts.showCloseButton) {
+ close.show();
+ }
+
+ _set_navigation();
+
+ if (currentOpts.hideOnContentClick) {
+ content.bind('click', $.fancybox.close);
+ }
+
+ if (currentOpts.hideOnOverlayClick) {
+ overlay.bind('click', $.fancybox.close);
+ }
+
+ $(window).bind("resize.fb", $.fancybox.resize);
+
+ if (currentOpts.centerOnScroll) {
+ $(window).bind("scroll.fb", $.fancybox.center);
+ }
+
+ if (currentOpts.type == 'iframe') {
+ $('<iframe id="fancybox-frame" name="fancybox-frame' + new Date().getTime() + '" frameborder="0" hspace="0" ' + ($.browser.msie ? 'allowtransparency="true""' : '') + ' scrolling="' + selectedOpts.scrolling + '" src="' + currentOpts.href + '"></iframe>').appendTo(content);
+ }
+
+ wrap.show();
+
+ busy = false;
+
+ $.fancybox.center();
+
+ currentOpts.onComplete(currentArray, currentIndex, currentOpts);
+
+ _preload_images();
+ },
+
+ _preload_images = function() {
+ var href,
+ objNext;
+
+ if ((currentArray.length -1) > currentIndex) {
+ href = currentArray[ currentIndex + 1 ].href;
+
+ if (typeof href !== 'undefined' && href.match(imgRegExp)) {
+ objNext = new Image();
+ objNext.src = href;
+ }
+ }
+
+ if (currentIndex > 0) {
+ href = currentArray[ currentIndex - 1 ].href;
+
+ if (typeof href !== 'undefined' && href.match(imgRegExp)) {
+ objNext = new Image();
+ objNext.src = href;
+ }
+ }
+ },
+
+ _draw = function(pos) {
+ var dim = {
+ width : parseInt(start_pos.width + (final_pos.width - start_pos.width) * pos, 10),
+ height : parseInt(start_pos.height + (final_pos.height - start_pos.height) * pos, 10),
+
+ top : parseInt(start_pos.top + (final_pos.top - start_pos.top) * pos, 10),
+ left : parseInt(start_pos.left + (final_pos.left - start_pos.left) * pos, 10)
+ };
+
+ if (typeof final_pos.opacity !== 'undefined') {
+ dim.opacity = pos < 0.5 ? 0.5 : pos;
+ }
+
+ wrap.css(dim);
+
+ content.css({
+ 'width' : dim.width - currentOpts.padding * 2,
+ 'height' : dim.height - (titleHeight * pos) - currentOpts.padding * 2
+ });
+ },
+
+ _get_viewport = function() {
+ return [
+ $(window).width() - (currentOpts.margin * 2),
+ $(window).height() - (currentOpts.margin * 2),
+ $(document).scrollLeft() + currentOpts.margin,
+ $(document).scrollTop() + currentOpts.margin
+ ];
+ },
+
+ _get_zoom_to = function () {
+ var view = _get_viewport(),
+ to = {},
+ resize = currentOpts.autoScale,
+ double_padding = currentOpts.padding * 2,
+ ratio;
+
+ if (currentOpts.width.toString().indexOf('%') > -1) {
+ to.width = parseInt((view[0] * parseFloat(currentOpts.width)) / 100, 10);
+ } else {
+ to.width = currentOpts.width + double_padding;
+ }
+
+ if (currentOpts.height.toString().indexOf('%') > -1) {
+ to.height = parseInt((view[1] * parseFloat(currentOpts.height)) / 100, 10);
+ } else {
+ to.height = currentOpts.height + double_padding;
+ }
+
+ if (resize && (to.width > view[0] || to.height > view[1])) {
+ if (selectedOpts.type == 'image' || selectedOpts.type == 'swf') {
+ ratio = (currentOpts.width ) / (currentOpts.height );
+
+ if ((to.width ) > view[0]) {
+ to.width = view[0];
+ to.height = parseInt(((to.width - double_padding) / ratio) + double_padding, 10);
+ }
+
+ if ((to.height) > view[1]) {
+ to.height = view[1];
+ to.width = parseInt(((to.height - double_padding) * ratio) + double_padding, 10);
+ }
+
+ } else {
+ to.width = Math.min(to.width, view[0]);
+ to.height = Math.min(to.height, view[1]);
+ }
+ }
+
+ to.top = parseInt(Math.max(view[3] - 20, view[3] + ((view[1] - to.height - 40) * 0.5)), 10);
+ to.left = parseInt(Math.max(view[2] - 20, view[2] + ((view[0] - to.width - 40) * 0.5)), 10);
+
+ return to;
+ },
+
+ _get_obj_pos = function(obj) {
+ var pos = obj.offset();
+
+ pos.top += parseInt( obj.css('paddingTop'), 10 ) || 0;
+ pos.left += parseInt( obj.css('paddingLeft'), 10 ) || 0;
+
+ pos.top += parseInt( obj.css('border-top-width'), 10 ) || 0;
+ pos.left += parseInt( obj.css('border-left-width'), 10 ) || 0;
+
+ pos.width = obj.width();
+ pos.height = obj.height();
+
+ return pos;
+ },
+
+ _get_zoom_from = function() {
+ var orig = selectedOpts.orig ? $(selectedOpts.orig) : false,
+ from = {},
+ pos,
+ view;
+
+ if (orig && orig.length) {
+ pos = _get_obj_pos(orig);
+
+ from = {
+ width : pos.width + (currentOpts.padding * 2),
+ height : pos.height + (currentOpts.padding * 2),
+ top : pos.top - currentOpts.padding - 20,
+ left : pos.left - currentOpts.padding - 20
+ };
+
+ } else {
+ view = _get_viewport();
+
+ from = {
+ width : currentOpts.padding * 2,
+ height : currentOpts.padding * 2,
+ top : parseInt(view[3] + view[1] * 0.5, 10),
+ left : parseInt(view[2] + view[0] * 0.5, 10)
+ };
+ }
+
+ return from;
+ },
+
+ _animate_loading = function() {
+ if (!loading.is(':visible')){
+ clearInterval(loadingTimer);
+ return;
+ }
+
+ $('div', loading).css('top', (loadingFrame * -40) + 'px');
+
+ loadingFrame = (loadingFrame + 1) % 12;
+ };
+
+ /**
+ * Public methods
+ */
+
+ $.fn.fancybox = function(options) {
+ if (!$(this).length) {
+ return this;
+ }
+
+ $(this)
+ .data('fancybox', $.extend({}, options, ($.metadata ? $(this).metadata() : {})))
+ .unbind('click.fb')
+ .bind('click.fb', function(e) {
+ e.preventDefault();
+
+ if (busy) {
+ return;
+ }
+
+ busy = true;
+
+ $(this).blur();
+
+ selectedArray = [];
+ selectedIndex = 0;
+
+ var rel = $(this).attr('rel') || '';
+
+ if (!rel || rel === '' || rel === 'nofollow') {
+ selectedArray.push(this);
+
+ } else {
+ selectedArray = $("a[rel=" + rel + "], area[rel=" + rel + "]");
+ selectedIndex = selectedArray.index( this );
+ }
+
+ _start();
+ });
+
+ return this;
+ };
+
+ $.fancybox = function(obj) {
+ var opts;
+
+ if (busy) {
+ return;
+ }
+
+ busy = true;
+ opts = typeof arguments[1] !== 'undefined' ? arguments[1] : {};
+
+ selectedArray = [];
+ selectedIndex = parseInt(opts.index, 10) || 0;
+
+ if ($.isArray(obj)) {
+ for (var i = 0, j = obj.length; i < j; i++) {
+ if (typeof obj[i] == 'object') {
+ $(obj[i]).data('fancybox', $.extend({}, opts, obj[i]));
+ } else {
+ obj[i] = $({}).data('fancybox', $.extend({content : obj[i]}, opts));
+ }
+ }
+
+ selectedArray = jQuery.merge(selectedArray, obj);
+
+ } else {
+ if (typeof obj == 'object') {
+ $(obj).data('fancybox', $.extend({}, opts, obj));
+ } else {
+ obj = $({}).data('fancybox', $.extend({content : obj}, opts));
+ }
+
+ selectedArray.push(obj);
+ }
+
+ if (selectedIndex > selectedArray.length || selectedIndex < 0) {
+ selectedIndex = 0;
+ }
+
+ _start();
+ };
+
+ $.fancybox.showActivity = function() {
+ clearInterval(loadingTimer);
+
+ loading.show();
+ loadingTimer = setInterval(_animate_loading, 66);
+ };
+
+ $.fancybox.hideActivity = function() {
+ loading.hide();
+ };
+
+ $.fancybox.next = function() {
+ return $.fancybox.pos( currentIndex + 1);
+ };
+
+ $.fancybox.prev = function() {
+ return $.fancybox.pos( currentIndex - 1);
+ };
+
+ $.fancybox.pos = function(pos) {
+ if (busy) {
+ return;
+ }
+
+ pos = parseInt(pos);
+
+ selectedArray = currentArray;
+
+ if (pos > -1 && pos < currentArray.length) {
+ selectedIndex = pos;
+ _start();
+
+ } else if (currentOpts.cyclic && currentArray.length > 1) {
+ selectedIndex = pos >= currentArray.length ? 0 : currentArray.length - 1;
+ _start();
+ }
+ };
+
+ $.fancybox.cancel = function() {
+ if (busy) {
+ return;
+ }
+
+ busy = true;
+
+ $.event.trigger('fancybox-cancel');
+
+ _abort();
+
+ selectedOpts.onCancel(selectedArray, selectedIndex, selectedOpts);
+
+ busy = false;
+ };
+
+ // Note: within an iframe use - parent.$.fancybox.close();
+ $.fancybox.close = function() {
+ if (busy || wrap.is(':hidden')) {
+ return;
+ }
+
+ busy = true;
+
+ if (currentOpts && false === currentOpts.onCleanup(currentArray, currentIndex, currentOpts)) {
+ busy = false;
+ return;
+ }
+
+ _abort();
+
+ $(close.add( nav_left ).add( nav_right )).hide();
+
+ $(content.add( overlay )).unbind();
+
+ $(window).unbind("resize.fb scroll.fb");
+ $(document).unbind('keydown.fb');
+
+ content.find('iframe').attr('src', isIE6 && /^https/i.test(window.location.href || '') ? 'javascript:void(false)' : 'about:blank');
+
+ if (currentOpts.titlePosition !== 'inside') {
+ title.empty();
+ }
+
+ wrap.stop();
+
+ function _cleanup() {
+ overlay.fadeOut('fast');
+
+ title.empty().hide();
+ wrap.hide();
+
+ $.event.trigger('fancybox-cleanup');
+
+ content.empty();
+
+ currentOpts.onClosed(currentArray, currentIndex, currentOpts);
+
+ currentArray = selectedOpts = [];
+ currentIndex = selectedIndex = 0;
+ currentOpts = selectedOpts = {};
+
+ busy = false;
+ }
+
+ if (currentOpts.transitionOut == 'elastic') {
+ start_pos = _get_zoom_from();
+
+ var pos = wrap.position();
+
+ final_pos = {
+ top : pos.top ,
+ left : pos.left,
+ width : wrap.width(),
+ height : wrap.height()
+ };
+
+ if (currentOpts.opacity) {
+ final_pos.opacity = 1;
+ }
+
+ title.empty().hide();
+
+ fx.prop = 1;
+
+ $(fx).animate({ prop: 0 }, {
+ duration : currentOpts.speedOut,
+ easing : currentOpts.easingOut,
+ step : _draw,
+ complete : _cleanup
+ });
+
+ } else {
+ wrap.fadeOut( currentOpts.transitionOut == 'none' ? 0 : currentOpts.speedOut, _cleanup);
+ }
+ };
+
+ $.fancybox.resize = function() {
+ if (overlay.is(':visible')) {
+ overlay.css('height', $(document).height());
+ }
+
+ $.fancybox.center(true);
+ };
+
+ $.fancybox.center = function() {
+ var view, align;
+
+ if (busy) {
+ return;
+ }
+
+ align = arguments[0] === true ? 1 : 0;
+ view = _get_viewport();
+
+ if (!align && (wrap.width() > view[0] || wrap.height() > view[1])) {
+ return;
+ }
+
+ wrap
+ .stop()
+ .animate({
+ 'top' : parseInt(Math.max(view[3] - 20, view[3] + ((view[1] - content.height() - 40) * 0.5) - currentOpts.padding)),
+ 'left' : parseInt(Math.max(view[2] - 20, view[2] + ((view[0] - content.width() - 40) * 0.5) - currentOpts.padding))
+ }, typeof arguments[0] == 'number' ? arguments[0] : 200);
+ };
+
+ $.fancybox.init = function() {
+ if ($("#fancybox-wrap").length) {
+ return;
+ }
+
+ $('body').append(
+ tmp = $('<div id="fancybox-tmp"></div>'),
+ loading = $('<div id="fancybox-loading"><div></div></div>'),
+ overlay = $('<div id="fancybox-overlay"></div>'),
+ wrap = $('<div id="fancybox-wrap"></div>')
+ );
+
+ outer = $('<div id="fancybox-outer"></div>')
+ .append('<div class="fancybox-bg" id="fancybox-bg-n"></div><div class="fancybox-bg" id="fancybox-bg-ne"></div><div class="fancybox-bg" id="fancybox-bg-e"></div><div class="fancybox-bg" id="fancybox-bg-se"></div><div class="fancybox-bg" id="fancybox-bg-s"></div><div class="fancybox-bg" id="fancybox-bg-sw"></div><div class="fancybox-bg" id="fancybox-bg-w"></div><div class="fancybox-bg" id="fancybox-bg-nw"></div>')
+ .appendTo( wrap );
+
+ outer.append(
+ content = $('<div id="fancybox-content"></div>'),
+ close = $('<a id="fancybox-close"></a>'),
+ title = $('<div id="fancybox-title"></div>'),
+
+ nav_left = $('<a href="javascript:;" id="fancybox-left"><span class="fancy-ico" id="fancybox-left-ico"></span></a>'),
+ nav_right = $('<a href="javascript:;" id="fancybox-right"><span class="fancy-ico" id="fancybox-right-ico"></span></a>')
+ );
+
+ close.click($.fancybox.close);
+ loading.click($.fancybox.cancel);
+
+ nav_left.click(function(e) {
+ e.preventDefault();
+ $.fancybox.prev();
+ });
+
+ nav_right.click(function(e) {
+ e.preventDefault();
+ $.fancybox.next();
+ });
+
+ if ($.fn.mousewheel) {
+ wrap.bind('mousewheel.fb', function(e, delta) {
+ if (busy) {
+ e.preventDefault();
+
+ } else if ($(e.target).get(0).clientHeight === 0 || $(e.target).get(0).scrollHeight === $(e.target).get(0).clientHeight) {
+ e.preventDefault();
+ $.fancybox[ delta > 0 ? 'prev' : 'next']();
+ }
+ });
+ }
+
+ if (!$.support.opacity) {
+ wrap.addClass('fancybox-ie');
+ }
+
+ if (isIE6) {
+ loading.addClass('fancybox-ie6');
+ wrap.addClass('fancybox-ie6');
+
+ $('<iframe id="fancybox-hide-sel-frame" src="' + (/^https/i.test(window.location.href || '') ? 'javascript:void(false)' : 'about:blank' ) + '" scrolling="no" border="0" frameborder="0" tabindex="-1"></iframe>').prependTo(outer);
+ }
+ };
+
+ $.fn.fancybox.defaults = {
+ padding : 10,
+ margin : 40,
+ opacity : false,
+ modal : false,
+ cyclic : false,
+ scrolling : 'auto', // 'auto', 'yes' or 'no'
+
+ width : 560,
+ height : 340,
+
+ autoScale : true,
+ autoDimensions : true,
+ centerOnScroll : false,
+
+ ajax : {},
+ swf : { wmode: 'transparent' },
+
+ hideOnOverlayClick : true,
+ hideOnContentClick : false,
+
+ overlayShow : true,
+ overlayOpacity : 0.7,
+ overlayColor : '#777',
+
+ titleShow : true,
+ titlePosition : 'float', // 'float', 'outside', 'inside' or 'over'
+ titleFormat : null,
+ titleFromAlt : false,
+
+ transitionIn : 'fade', // 'elastic', 'fade' or 'none'
+ transitionOut : 'fade', // 'elastic', 'fade' or 'none'
+
+ speedIn : 300,
+ speedOut : 300,
+
+ changeSpeed : 300,
+ changeFade : 'fast',
+
+ easingIn : 'swing',
+ easingOut : 'swing',
+
+ showCloseButton : true,
+ showNavArrows : true,
+ enableEscapeButton : true,
+ enableKeyboardNav : true,
+
+ onStart : function(){},
+ onCancel : function(){},
+ onComplete : function(){},
+ onCleanup : function(){},
+ onClosed : function(){},
+ onError : function(){}
+ };
+
+ $(document).ready(function() {
+ $.fancybox.init();
+ });
+
+})(jQuery); \ No newline at end of file
diff --git a/www/wiki/extensions/PageForms/libs/jquery.fancybox.js b/www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.3.2.10.js
index e84bc448..e84bc448 100644
--- a/www/wiki/extensions/PageForms/libs/jquery.fancybox.js
+++ b/www/wiki/extensions/PageForms/libs/FancyBox/jquery.fancybox.3.2.10.js
diff --git a/www/wiki/extensions/PageForms/libs/PF_MultiPageEdit.js b/www/wiki/extensions/PageForms/libs/PF_MultiPageEdit.js
new file mode 100644
index 00000000..745f6f1f
--- /dev/null
+++ b/www/wiki/extensions/PageForms/libs/PF_MultiPageEdit.js
@@ -0,0 +1,337 @@
+/**
+ * Overrides of PF_jsGrid.js for use in Special:MultiPageEdit.
+ *
+ * @author Yashdeep Thorat
+ * @author Yaron Koren
+ */
+/* global jsGrid, mw */
+/*jshint esversion: 6 */
+(function(jsGrid, $, undefined) {
+
+ // Create month selector dropdown.
+ function multiPageEditBuildSelect( currentMonth ) {
+ var monthNames = mw.config.get('wgMonthNamesShort');
+ var str = '<select class="pf_jsGrid_month" style=" width: 100% !important; font-size:14px;">';
+ for (var val=0; val<=12; val++) {
+ var val2;
+ if (val < 10) { //Adds a leading 0 to single digit months, ex 01 instead of 1.
+ val2 = "0" + val;
+ } else {
+ val2 = val;
+ }
+ var option = '<option ';
+ if (val === currentMonth) {
+ option += 'selected="selected" ';
+ }
+ option += 'value="' + val2 + '">' + monthNames[val] + '</option>';
+ str += option;
+ }
+ str += '</select>';
+ return str;
+ }
+
+ var PFDateField = function(config) {
+ jsGrid.Field.call(this, config);
+ };
+
+ PFDateField.prototype = new jsGrid.Field({
+ sorter: function(date1, date2) {
+ return new Date(date1) - new Date(date2);
+ },
+
+ itemTemplate: function(value) {
+ return value;
+ },
+
+ insertTemplate: function(value) {
+ var html_day = '<div style="float:left; width:19%;"><label style="display:block; text-align:center; font- size:14px;">DD:</label><input class="pf_jsGrid_day" style=" font-size:14px; " type="text" value="" placeholder="DD"></input></div>';
+ var html_year = '<div style="float:left; width:29%;"><label style="display:block; text-align:center; width:29%; font-size:14px;">YYYY:</label><input class="pf_jsGrid_year" style=" font-size:14px; " type="text" value="" placeholder="YYYY"></input></div>';
+ var html_month = '<div style="float:left; width:48%; margin-left:2%; margin-right:2%;"><label style="display:block; text-align:center; font-size:14px;">MM:</label>' + multiPageEditBuildSelect(0) + '</div>';
+ var fullDateInputHTML = '<div class="pf_jsGrid_ymd_form">';
+ if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
+ fullDateInputHTML += html_month + html_day + html_year;
+ } else {
+ fullDateInputHTML += html_day + html_month + html_year;
+ }
+ fullDateInputHTML += '</div>';
+ this.fullDateInputInsertHTML = $( fullDateInputHTML );
+ return this.fullDateInputInsertHTML;
+ },
+
+ editTemplate: function(value) {
+ var display_day_of_month = '';
+ var display_year = '';
+ var display_month = 0;
+ var dateValue, dateFormat;
+
+ // These both sometimes happen.
+ if ( value === undefined || value === '' ) {
+ value = null;
+ }
+
+ if ( value === null ) {
+ dateValue = null;
+ } else if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
+ dateValue = value;
+ if ( /^\d+$/.test( dateValue ) && dateValue.length < 8 ){
+ dateFormat = 1; //Year only
+ // Add a fake day and month that will be ignored later
+ // so that it's a valid date format in javascript
+ dateValue = "January 01," + dateValue;
+ } else {
+ var spaceCount = ( dateValue.match(/ /g) || [] ).length;
+ if ( spaceCount === 1 ) {
+ dateFormat = 2; //Month and Year only
+ // Add a fake day that will be ignored later
+ // so that it's a valid date format in javascript
+ var temp = dateValue.split(' ');
+ dateValue = temp.join(' 01,');
+ } else {
+ dateFormat = 3; //Complete date
+ }
+ }
+ } else {
+ dateValue = value.replace( /\//g, '-' );
+ if ( /^\d+$/.test( dateValue ) && dateValue.length < 8 ){
+ dateFormat = 1; //Year only
+ // Add a fake day and month that will be ignored later
+ // so that it's a valid date format in javascript
+ dateValue = dateValue + "-01-01";
+ } else {
+ var hyphenCount = ( dateValue.match(/-/g) || [] ).length;
+ if ( hyphenCount === 1 ) {
+ dateFormat = 2; //Month and Year only
+ // Add a fake day that will be ignored later
+ // so that it's a valid date format in javascript
+ dateValue = dateValue + "-01";
+ } else {
+ dateFormat = 3; //Complete date
+ }
+ }
+ }
+ if ( value !== null ) {
+ var dateObject = new Date( dateValue );
+ display_day_of_month = dateObject.getDate();
+ display_year = dateObject.getFullYear();
+ display_month = dateObject.getMonth();
+ }
+ var fullDateInputHTML = '<div class="pf_jsGrid_ymd_form">';
+ var monthElement;
+ var dayElement;
+ if ( value === null ) {
+ dayElement = '';
+ monthElement = multiPageEditBuildSelect(0);
+ } else if ( dateFormat === 1 ) {
+ dayElement = '';
+ monthElement = multiPageEditBuildSelect(0);
+ } else if ( dateFormat === 2 ) {
+ dayElement = '';
+ monthElement = multiPageEditBuildSelect(display_month + 1);
+ } else {
+ dayElement = display_day_of_month;
+ monthElement = multiPageEditBuildSelect(display_month + 1);
+ }
+ var html_day = '<div style="float:left; width:19%;"><label style="display:block; text-align:center; font-size:14px;">DD:</label><input class="pf_jsGrid_day" style=" font-size:14px; " type="text" value="' + dayElement + '" placeholder="DD"></input></div>';
+ var html_month = '<div style="float:left; width:48%; margin-left:2%; margin-right:2%;"><label style="display:block; text-align:center; font-size:14px;">MM:</label>' + monthElement + '</div>';
+ var html_year = '<div style="float:left; width:29%;"><label style="display:block; text-align:center; width:29%; font-size:14px;">YYYY:</label><input class="pf_jsGrid_year" style=" font-size:14px; " type="text" value=' + display_year + '></input></div>';
+
+ if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
+ fullDateInputHTML += html_month + html_day + html_year;
+ } else {
+ fullDateInputHTML += html_day + html_month + html_year;
+ }
+ fullDateInputHTML += '</div>';
+ this.fullDateInputEditHTML = $( fullDateInputHTML );
+ return this.fullDateInputEditHTML;
+ },
+
+ insertValue: function() {
+ var Insert_year = this.fullDateInputInsertHTML.find(".pf_jsGrid_year").val();
+ var Insert_month = this.fullDateInputInsertHTML.find(".pf_jsGrid_month").val();
+ var Insert_day_of_month = this.fullDateInputInsertHTML.find(".pf_jsGrid_day").val();
+ if ( Insert_year === undefined || Insert_year === "" ) {
+ return null;
+ }
+ if ( Insert_month === '00' && Insert_day_of_month !== '' ) {
+ return null;
+ }
+ var ret, day, month;
+ if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
+ var monthNames = mw.config.get('wgPageFormsContLangMonths');
+ day = ( Insert_day_of_month === '' ) ? '' : Insert_day_of_month + ", ";
+ month = ( Insert_month === '00' ) ? '' : monthNames[parseInt( Insert_month )] + " ";
+ ret = month + day + Insert_year;
+ } else {
+ day = ( Insert_day_of_month === '' ) ? '' : "/" + Insert_day_of_month;
+ month = ( Insert_month === '00' ) ? '' : "/" + Insert_month;
+ ret = Insert_year + month + day;
+ }
+ return ret;
+ },
+
+ editValue: function(value) {
+ var Edit_year = this.fullDateInputEditHTML.find(".pf_jsGrid_year").val();
+ var Edit_month = this.fullDateInputEditHTML.find(".pf_jsGrid_month").val();
+ var Edit_day_of_month = this.fullDateInputEditHTML.find(".pf_jsGrid_day").val();
+ if ( Edit_year === undefined || Edit_year === "" ) {
+ return null;
+ }
+ if ( Edit_month === '00' && Edit_day_of_month !== '' ) {
+ return null;
+ }
+ var ret, day, month;
+ if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
+ var monthNames = mw.config.get('wgPageFormsContLangMonths');
+ day = ( Edit_day_of_month === '' ) ? '' : Edit_day_of_month + ", ";
+ month = ( Edit_month === '00' ) ? '' : monthNames[parseInt( Edit_month )] + " ";
+ ret = month + day + Edit_year;
+ } else {
+ day = ( Edit_day_of_month === '' ) ? '' : "/" + Edit_day_of_month;
+ month = ( Edit_month === '00' ) ? '' : "/" + Edit_month;
+ ret = Edit_year + month + day;
+ }
+ return ret;
+ }
+ });
+
+ jsGrid.fields.date = PFDateField;
+
+ /**
+ * The following code handles the 'combobox' input type within the grid.
+ * insertTemplate preprocesses the value and returns it to the grid cell to display;
+ * editTemplate/insertTemplate generate the edition/insertion forms;
+ * editValue/insertValue is in charge of putting the final values into the grid.
+ */
+
+ var PFComboBoxField = function(config) {
+ jsGrid.Field.call(this, config);
+ };
+
+ PFComboBoxField.prototype = new jsGrid.Field({
+
+ itemTemplate: function(value) {
+ return value;
+ },
+
+ insertTemplate: function(value) {
+ var autocompletedatatype = "";
+ if ( this.autocompletedatatype !== undefined ) {
+ autocompletedatatype = 'autocompletedatatype="' + this.autocompletedatatype + '"';
+ }
+ var inputHTML = '<input id="insertjsGridComboBox" class="pfCombobox" autocompletesettings="' + this.autocompletesettings + '" size="35" ' + autocompletedatatype + '>';
+ return inputHTML;
+ },
+
+ editTemplate: function(value) {
+ var autocompletedatatype = "";
+ if ( this.autocompletedatatype !== undefined ) {
+ autocompletedatatype = 'autocompletedatatype="' + this.autocompletedatatype + '"';
+ }
+ var inputHTML = '<input id="jsGridComboBox" class="pfCombobox" value="' + value + '" autocompletesettings="' + this.autocompletesettings + '" size="35" ' + autocompletedatatype + '>';
+ return inputHTML;
+ },
+
+ insertValue: function() {
+ return $('#insertjsGridComboBox').val();
+ },
+
+ editValue: function(value) {
+ return $('#jsGridComboBox').val();
+ }
+ });
+
+ jsGrid.fields.combobox = PFComboBoxField;
+
+ /**
+ * The following code handles the 'tokens' input type within the grid.
+ * insertTemplate preprocesses the value and returns it to the grid cell to display;
+ * editTemplate/insertTemplate generate the edition/insertion forms;
+ * editValue/insertValue is in charge of putting the final values into the grid.
+ */
+
+ var PFTokensField = function(config) {
+ jsGrid.Field.call(this, config);
+ };
+
+ PFTokensField.prototype = new jsGrid.Field({
+
+ itemTemplate: function(value) {
+ return value;
+ },
+
+ insertTemplate: function(value) {
+ var autocompletedatatype = "";
+ if ( this.autocompletedatatype !== undefined ) {
+ autocompletedatatype = 'autocompletedatatype="' + this.autocompletedatatype + '"';
+ }
+ var inputHTML = '<input id="insertjsGridTokens" class="pfTokens createboxInput" autocompletesettings="' + this.autocompletesettings + '" size="50" ' + autocompletedatatype + '>';
+ return inputHTML;
+ },
+
+ editTemplate: function(value) {
+ var autocompletedatatype = "";
+ if ( this.autocompletedatatype !== undefined ) {
+ autocompletedatatype = 'autocompletedatatype="' + this.autocompletedatatype + '"';
+ }
+ var inputHTML = '<input id="jsGridTokens" class="pfTokens createboxInput" value="' + value + '" autocompletesettings="' + this.autocompletesettings + '" size="50" ' + autocompletedatatype + '>';
+ return inputHTML;
+ },
+
+ insertValue: function() {
+ return $('#insertjsGridTokens').val();
+ },
+
+ editValue: function(value) {
+ return $('#jsGridTokens').val();
+ }
+ });
+
+ jsGrid.fields.tokens = PFTokensField;
+
+ // Override checkbox functions (and add valueIsYes()) to get correct
+ // handling of Yes/No/etc. values.
+ jsGrid.fields.checkbox.prototype.valueIsYes = function(value) {
+ // This is sometimes called with an "undefined" value.
+ if ( value === undefined || value === null ) {
+ return false;
+ }
+
+ value = value.toLowerCase();
+ var possibleYesMessages = [
+ mw.config.get( 'wgPageFormsContLangYes' ).toLowerCase(),
+ // Add in '1', and some hardcoded English.
+ '1', 'yes', 'true'
+ ];
+ return ( possibleYesMessages.indexOf( value ) >= 0 );
+ };
+
+ jsGrid.fields.checkbox.prototype.itemTemplate = function(value) {
+ return this._createCheckbox().prop({
+ checked: this.valueIsYes( value ),
+ disabled: true
+ });
+ };
+
+ jsGrid.fields.checkbox.prototype.editTemplate = function(value) {
+ if(!this.editing) {
+ return this.itemTemplate(value);
+ }
+
+ var $result = this.editControl = this._createCheckbox();
+ $result.prop("checked", this.valueIsYes( value ));
+ return $result;
+ };
+
+ jsGrid.fields.checkbox.prototype.insertValue = function() {
+ return this.insertControl.is(":checked") ?
+ mw.config.get( 'wgPageFormsContLangYes' ) :
+ mw.config.get( 'wgPageFormsContLangNo' );
+ };
+
+ jsGrid.fields.checkbox.prototype.editValue = function() {
+ return this.editControl.is(":checked") ?
+ mw.config.get( 'wgPageFormsContLangYes' ) :
+ mw.config.get( 'wgPageFormsContLangNo' );
+ };
+
+}(jsGrid, jQuery)); \ No newline at end of file
diff --git a/www/wiki/extensions/PageForms/libs/PF_jsGrid.js b/www/wiki/extensions/PageForms/libs/PF_jsGrid.js
index 8a8d8c99..184fd58e 100644
--- a/www/wiki/extensions/PageForms/libs/PF_jsGrid.js
+++ b/www/wiki/extensions/PageForms/libs/PF_jsGrid.js
@@ -5,6 +5,7 @@
* @author Balabky9
*/
/* global jsGrid, mw */
+/*jshint esversion: 6 */
(function(jsGrid, $, undefined) {
/**
* The following code handles the 'date' input type within the grid.
@@ -27,7 +28,7 @@
function buildSelect( currentMonth ) {
var monthNames = mw.config.get('wgMonthNamesShort');
var str = '<select class="pf_jsGrid_month" style=" width: 100% !important; font-size:14px;">';
- for (var val=1; val<=12; val++) {
+ for (var val=0; val<=12; val++) {
var val2;
if (val < 10) { //Adds a leading 0 to single digit months, ex 01 instead of 1.
val2 = "0" + val;
@@ -59,14 +60,14 @@
},
insertTemplate: function(value) {
- var html_date = '<div style="float:left; width:19%;"><label style="display:block; text-align:center; font- size:14px;">DD:</label><input class="pf_jsGrid_day" style=" font-size:14px; " type="text" value="" placeholder="DD"></input></div>';
+ var html_day = '<div style="float:left; width:19%;"><label style="display:block; text-align:center; font- size:14px;">DD:</label><input class="pf_jsGrid_day" style=" font-size:14px; " type="text" value="" placeholder="DD"></input></div>';
var html_year = '<div style="float:left; width:29%;"><label style="display:block; text-align:center; width:29%; font-size:14px;">YYYY:</label><input class="pf_jsGrid_year" style=" font-size:14px; " type="text" value="" placeholder="YYYY"></input></div>';
- var html_month = '<div style="float:left; width:48%; margin-left:2%; margin-right:2%;"><label style="display:block; text-align:center; font-size:14px;">MM:</label>' + buildSelect(1) + '</div>';
+ var html_month = '<div style="float:left; width:48%; margin-left:2%; margin-right:2%;"><label style="display:block; text-align:center; font-size:14px;">MM:</label>' + buildSelect(0) + '</div>';
var fullDateInputHTML = '<div class="pf_jsGrid_ymd_form">';
if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
- fullDateInputHTML += html_month + html_date + html_year;
+ fullDateInputHTML += html_month + html_day + html_year;
} else {
- fullDateInputHTML += html_date + html_month + html_year;
+ fullDateInputHTML += html_day + html_month + html_year;
}
fullDateInputHTML += '</div>';
@@ -90,13 +91,13 @@
display_month = dateObject.getMonth();
}
var fullDateInputHTML = '<div class="pf_jsGrid_ymd_form">';
- var html_date = '<div style="float:left; width:19%;"><label style="display:block; text-align:center; font-size:14px;">DD:</label><input class="pf_jsGrid_day" style=" font-size:14px; " type="text" value=' + display_day_of_month + '></input></div>';
+ var html_day = '<div style="float:left; width:19%;"><label style="display:block; text-align:center; font-size:14px;">DD:</label><input class="pf_jsGrid_day" style=" font-size:14px; " type="text" value=' + display_day_of_month + '></input></div>';
var html_year = '<div style="float:left; width:29%;"><label style="display:block; text-align:center; width:29%; font-size:14px;">YYYY:</label><input class="pf_jsGrid_year" style=" font-size:14px; " type="text" value=' + display_year + '></input></div>';
var html_month = '<div style="float:left; width:48%; margin-left:2%; margin-right:2%;"><label style="display:block; text-align:center; font-size:14px;">MM:</label>' + buildSelect(display_month + 1) + '</div>';
if ( mw.config.get('wgAmericanDates') ) { //check for date-style format.
- fullDateInputHTML += html_month + html_date + html_year;
+ fullDateInputHTML += html_month + html_day + html_year;
} else {
- fullDateInputHTML += html_date + html_month + html_year;
+ fullDateInputHTML += html_day + html_month + html_year;
}
fullDateInputHTML += '</div>';
@@ -132,21 +133,234 @@
});
jsGrid.fields.date = PFDateField;
+
}(jsGrid, jQuery));
-( function ( $, mw ) {
+( function ( $, mw, pf ) {
$( '.pfJSGrid' ).each( function() {
var gridParams = mw.config.get( 'wgPageFormsGridParams' ),
gridValues = mw.config.get( 'wgPageFormsGridValues' );
var $gridDiv = $( this );
var templateName = $gridDiv.attr( 'data-template-name' );
+ var formName = $gridDiv.attr( 'data-form-name' );
var gridHeight = $gridDiv.attr( 'height' );
+ var editMultiplePages = $gridDiv.attr( 'editMultiplePages' );
+ var baseUrl = mw.config.get( 'wgScriptPath' );
if ( gridHeight === undefined ) { gridHeight = '400px'; }
// The slice() is necessary to do a clone, so that
- //gridParams does not get modified.
+ // gridParams does not get modified.
var templateParams = gridParams[templateName].slice(0);
- templateParams.push( { type: 'control' } );
+ // Different controls depending on whether it's
+ // Special:MultiPageEdit or "display=spreadsheet".
+ if ( editMultiplePages !== undefined ) {
+ templateParams.push( { type: 'control', deleteButton: false } );
+ } else {
+ templateParams.push( { type: 'control' } );
+ }
+ var dataValues = [];
+ var pages = [];
+ var cancelUpdate = 0;
+ if ( editMultiplePages !== undefined ) {
+ $.ajax({
+ url: baseUrl + '/api.php?action=query&format=json&list=embeddedin&eilimit=500&eititle=Template:' + templateName,
+ dataType: 'json',
+ type: 'POST',
+ async: false,
+ headers: { 'Api-User-Agent': 'Example/1.0' },
+ success: function(data) {
+ var pageObjects = data.query.embeddedin;
+ for ( var i = 0; i < pageObjects.length; i++ ) {
+ pages.push( encodeURIComponent( pageObjects[i].title ) );
+ }
+ pages.sort(function( a, b ){ return a.toUpperCase().localeCompare( b.toUpperCase() ); });
+
+ },
+ error: function(xhr, status, error){
+ mw.notify( "ERROR: Unable to retrieve pages for the selected template", { type: 'error' } );
+ }
+ });
+ }
+
+ function getGridValues( pageNames ) {
+ return $.ajax({
+ url: baseUrl + '/api.php?action=query&format=json&prop=revisions&rvprop=content&formatversion=2&titles=' + pageNames,
+ dataType: 'json',
+ type: 'POST',
+ headers: { 'Api-User-Agent': 'Example/1.0' }
+ });
+ }
+
+ function getTemplateCalls( pageContent, pageName ) {
+ var startDelimiter = '{{' + templateName.toLowerCase();
+ var endDelimiter = '}}';
+ var contents = [];
+ var startFrom, contentStart, contentEnd;
+ startFrom = contentStart = contentEnd = 0;
+ while ( -1 !== ( contentStart = pageContent.toLowerCase().indexOf( startDelimiter, startFrom ) ) ) {
+ contentEnd = pageContent.indexOf( endDelimiter, contentStart );
+ if ( contentEnd === -1 ) {
+ break;
+ }
+ var content = pageContent.substring( contentStart + startDelimiter.length, contentEnd );
+ contents.push( 'page=' + pageName + content );
+ startFrom = contentEnd + 1;
+ }
+ return contents;
+ }
+
+ function getQueryString( preEdit, postEdit ){
+ var queryString = "";
+ $.each( postEdit, function( key, value ) {
+ if ( value !== preEdit[key] && key !== 'page' ) {
+ queryString += '&' + templateName + '[' + key + ']' + '=' + value;
+ }
+ });
+ return queryString;
+ }
+
+ function getToken() {
+ var url = baseUrl + '/api.php?action=query&format=json&meta=tokens&type=csrf';
+ return $.post( url );
+ }
+
+ function movePage( fromPage, toPage ) {
+ return $.when( getToken() ).then( function successHandler( postResult ){
+ var data = {};
+ var token = postResult.query.tokens.csrftoken;
+ data.token = token;
+ var query = 'from=' + encodeURIComponent( fromPage ) + "&to=" + encodeURIComponent( toPage ) + "&movetalk&noredirect";
+ return $.ajax( {
+ type: 'POST',
+ url: baseUrl + '/api.php?action=move&format=json&' + query,
+ dataType: 'json',
+ data: data
+ } );
+ });
+ }
+
+ function updatePage( args, queryString ) {
+ if ( queryString !== "") {
+ var data = {
+ action: 'pfautoedit',
+ format: 'json'
+ };
+ data.query = 'form=' + formName + '&target=' + encodeURIComponent( args.previousItem.page ) + encodeURI( queryString );
+ return $.ajax( {
+ type: 'POST',
+ url: baseUrl + '/api.php',
+ data: data,
+ dataType: 'json'
+ } );
+ } else {
+ var result = { status: 200 };
+ return result;
+ }
+ }
+
+ function addPage( args ){
+ var queryString = "";
+ $.each( args.item, function( key, value ) {
+ if ( key !== "page" ) {
+ if ( value === "" ) {
+ value = " ";
+ }
+ queryString += '&' + templateName + '[' + key + ']' + '=' + value;
+ }
+ });
+ var data = {
+ action: 'pfautoedit',
+ format: 'json'
+ };
+ data.query = 'form=' + formName + '&target=' + encodeURIComponent( args.item.page ) + encodeURI( queryString );
+ return $.ajax( {
+ type: 'POST',
+ url: baseUrl + '/api.php',
+ data: data,
+ dataType: 'json'
+ } );
+ }
+
+ var ooJSUIModule = 'oojs-ui-widgets';
+ if ( mw.loader.getVersion( 'oojs-ui-widgets' ) === null ) {
+ // MW < 1.29 (?)
+ ooJSUIModule = 'oojs-ui';
+ }
+
+ mw.loader.using( ooJSUIModule ).done( function () {
+ $( function () {
+
+ var option1 = new OO.ui.ButtonOptionWidget( {
+ data: 1,
+ label: '25',
+ title: 'Button option 1'
+ } );
+ var option2 = new OO.ui.ButtonOptionWidget( {
+ data: 2,
+ label: '50',
+ title: 'Button option 2'
+ } );
+ var option3 = new OO.ui.ButtonOptionWidget( {
+ data: 3,
+ label: '100',
+ title: 'Button option 3'
+ } );
+ var option4 = new OO.ui.ButtonOptionWidget( {
+ data: 4,
+ label: '250',
+ title: 'Button option 4'
+ } );
+
+ var buttonSelect = new OO.ui.ButtonSelectWidget( {
+ items: [ option1, option2, option3, option4 ]
+ } );
+
+ var popupButton = new OO.ui.PopupButtonWidget( {
+ label: 'Results to show',
+ popup: {
+ $content: buttonSelect.$element,
+ padded: true,
+ width: 'auto',
+ align: 'forwards'
+ }
+ } );
+
+ buttonSelect.selectItem( option1 );
+ option1.on( 'click', function () {
+ $gridDiv.jsGrid("option", "pageSize", 25);
+ } );
+ option2.on( 'click', function () {
+ $gridDiv.jsGrid("option", "pageSize", 50);
+ } );
+ option3.on( 'click', function () {
+ $gridDiv.jsGrid("option", "pageSize", 100);
+ } );
+ option4.on( 'click', function () {
+ $gridDiv.jsGrid("option", "pageSize", 250);
+ } );
+
+ $( '#selectLimit' ).append( popupButton.$element );
+
+ } );
+ } );
+
+ var PFPageLoadingStrategy = function(grid) {
+ jsGrid.loadStrategies.PageLoadingStrategy.call(this, grid);
+ };
+
+ PFPageLoadingStrategy.prototype = new jsGrid.loadStrategies.PageLoadingStrategy();
+
+ PFPageLoadingStrategy.prototype.finishInsert = function(insertedItem) {
+ var grid = this._grid;
+ grid.option("data").unshift(insertedItem);
+ grid.refresh();
+ };
+
+ PFPageLoadingStrategy.prototype.finishDelete = function(deletedItem, deletedItemIndex) {
+ var grid = this._grid;
+ grid.option("data").splice(deletedItemIndex, 1);
+ grid.refresh();
+ };
$gridDiv.jsGrid({
width: "100%",
@@ -156,10 +370,94 @@
inserting: true,
confirmDeleting: false,
+ autoload: ( editMultiplePages === undefined ) ? false : true,
+ paging: ( editMultiplePages === undefined ) ? false : true,
+ pageSize: 25,
+ pageIndex: 1,
+
+ loadStrategy: function() {
+ return new PFPageLoadingStrategy(this);
+ },
+
data: gridValues[templateName],
fields: templateParams,
+ controller: {
+ loadData: function ( filter ) {
+ $gridDiv.css( "visibility", "hidden" );
+ $("#selectLimit").css( "visibility", "hidden" );
+ $("#loadingImage").css( "display", "block" );
+ var start = filter.pageSize * ( filter.pageIndex - 1 );
+ var end = start + filter.pageSize;
+ dataValues = [];
+ var pageNames = "";
+
+ if ( pages.length > 0 ) {
+ for (var i = start; ( i < end - 1 ) && ( i < pages.length - 1 ); i++) {
+ pageNames += pages[i] + "|";
+ }
+ pageNames += pages[i];
+ return $.when( getGridValues( pageNames ) ).then( function successHandler( data ) {
+ var templateCalls = [];
+ data.query.pages.sort(function( a, b ){ return a.title.toUpperCase().localeCompare( b.title.toUpperCase() ); });
+ for (var i = 0; i < data.query.pages.length; i++) {
+ var pageContent = data.query.pages[i].revisions[0].content;
+ templateCalls = getTemplateCalls( pageContent, data.query.pages[i].title );
+ for ( const templateCall of templateCalls ) {
+ var fieldArray = templateCall.split( '|' );
+ var fieldValueObject = {};
+ for ( const field of fieldArray ) {
+ var equalPos = field.indexOf( '=' );
+ var fieldLabel = field.substring( 0, equalPos );
+ var fieldValue = field.substring( equalPos + 1 );
+ fieldLabel = fieldLabel.replace(/(\r\n\t|\n|\r\t)/gm,"");
+ fieldValueObject[fieldLabel] = fieldValue.replace(/(\r\n\t|\n|\r\t)/gm,"");
+ }
+ dataValues.push( fieldValueObject );
+ }
+ }
+ var dataResult = {
+ data: dataValues,
+ itemsCount: dataValues.length
+ };
+ $("#loadingImage").css( "display", "none" );
+ $gridDiv.css( "visibility", "visible" );
+ $("#selectLimit").css( "visibility", "visible" );
+ return dataResult;
+ }, function errorHandler( jqXHR, textStatus, errorThrown ){
+ mw.notify( "ERROR: Unable to retrieve pages", { type: 'error' } );
+ return false;
+ });
+ }
+ }
+ },
+
+ _pagesCount: function() {
+ var pageSize = this.pageSize;
+ return Math.ceil( pages.length / pageSize );
+ },
+
+ onOptionChanging: function( args ){
+ if ( $('#insertjsGridComboBox').length ) {
+ var insertcombobox = new pf.select2.combobox();
+ insertcombobox.apply( $('#insertjsGridComboBox') );
+ }
+ if ( $('#insertjsGridTokens').length ) {
+ var inserttokens = new pf.select2.tokens();
+ inserttokens.apply( $('#insertjsGridTokens') );
+ }
+ },
+
onEditRowCreated: function( args ) {
+ if ( $('#jsGridComboBox').length ) {
+ var combobox = new pf.select2.combobox();
+ combobox.apply( $('#jsGridComboBox') );
+ }
+ if ( $('#jsGridTokens').length ) {
+ var tokens = new pf.select2.tokens();
+ tokens.apply( $('#jsGridTokens') );
+ }
+
args.editRow.keypress( function( e ) {
// Make the "Enter" key approve an update.
if ( e.which === 13 ) {
@@ -189,27 +487,138 @@
}
});
- }
- });
+ },
- var $gridData = $gridDiv.find( ".jsgrid-grid-body tbody" );
+ onItemUpdating: function( args ){
+ if ( editMultiplePages === undefined || cancelUpdate === 1 ) {
+ cancelUpdate = 0;
+ return;
+ }
+ var queryString = getQueryString( args.previousItem, args.item );
+ if ( queryString !== "" || args.previousItem.page !== args.item.page ) {
+ $.when( updatePage( args, queryString ) ).then( function successHandler( result ) {
+ if ( result.status === 200 ) {
+ if ( queryString !== "" ) {
+ mw.notify( 'Update Successful' );
+ }
+
+ if ( args.previousItem.page !== args.item.page ) {
+ $.when( movePage( args.previousItem.page, args.item.page ) ).then( function successHandler( result ) {
+ if ( "error" in result ) {
+ // args.cancel = true;
+ mw.notify( "Error in renaming page: " + result.error.info, { type: 'error' } );
+ cancelUpdate = 1;
+ $gridDiv.jsGrid("updateItem", args.item, args.previousItem );
+ } else {
+ mw.notify( 'Update Successful: moved page "' + args.previousItem.page + '" to "' + args.item.page + '"' );
+ }
+ }, function errorHandler( jqXHR, textStatus, errorThrown ){
+ var result = jQuery.parseJSON(jqXHR.responseText);
+ var text = result.responseText;
+
+ for ( var i = 0; i < result.errors.length; i++ ) {
+ text += ' ' + result.errors[i].message;
+ }
+ // args.cancel = true;
+ mw.notify( "ERROR: " + text, { type: 'error' } );
+ cancelUpdate = 1;
+ $gridDiv.jsGrid("updateItem", args.item, args.previousItem );
+ });
+ }
+
+ } else {
+ mw.notify( "ERROR: " + result.status, { type: 'error' } );
+ // args.cancel = true;
+ cancelUpdate = 1;
+ $gridDiv.jsGrid("updateItem", args.item, args.previousItem );
+ }
+ }, function errorHandler( jqXHR, textStatus, errorThrown ){
+ // args.cancel = true;
+ var result = jQuery.parseJSON(jqXHR.responseText);
+ var text = result.responseText;
+
+ for ( var i = 0; i < result.errors.length; i++ ) {
+ text += ' ' + result.errors[i].message;
+ }
+ mw.notify( "ERROR: " + text, { type: 'error' } );
+ cancelUpdate = 1;
+ $gridDiv.jsGrid("updateItem", args.item, args.previousItem );
+ } );
+ }
+ },
- // Copied from http://js-grid.com/demos/rows-reordering.html
- $gridData.sortable({
- update: function( e, ui ) {
- // array of indexes
- var clientIndexRegExp = /\s+client-(\d+)\s+/;
- var indexes = $.map( $gridData.sortable( "toArray", { attribute: "class" } ), function(classes) {
- return clientIndexRegExp.exec(classes)[1];
- });
+ onItemInserting: function( args ){
+ if ( editMultiplePages === undefined ) {
+ return;
+ }
+
+ if ( args.item.page === "" ) {
+ mw.notify( "ERROR: " + "Page name not specified", { type: 'error' } );
+ args.cancel = true;
+ return;
+ }
+
+ new mw.Api().get( {
+ action: "query",
+ titles: [ args.item.page ],
+ } ).then( function( ret ) {
+ $.each( ret.query.pages, function() {
+ if ( this.missing === "" ) {
+ $.when( addPage( args ) ).then( function successHandler( result ){
+ if ( result.status === 200 ) {
+ mw.notify( 'New page: ' + args.item.page + ' created successfully' );
+ } else {
+ mw.notify( "ERROR: " + result.status, { type: 'error' } );
+ // args.cancel = true;
+ $gridDiv.jsGrid("deleteItem", args.item );
+ }
+ }, function errorHandler( jqXHR, textStatus, errorThrown ){
+ // args.cancel = true;
+ var result = jQuery.parseJSON(jqXHR.responseText);
+ var text = result.responseText;
+
+ for ( var i = 0; i < result.errors.length; i++ ) {
+ text += ' ' + result.errors[i].message;
+ }
+ mw.notify( "ERROR: " + text, { type: 'error' } );
+ $gridDiv.jsGrid("deleteItem", args.item );
+ } );
+ } else {
+ mw.notify( "ERROR: " + "Page already exists", { type: 'error' } );
+ // args.cancel = true;
+ $gridDiv.jsGrid("deleteItem", args.item );
+ }
+ } );
+ }, function( error ) {
+ mw.notify( "ERROR: " + error, { type: 'error' } );
+ // args.cancel = true;
+ $gridDiv.jsGrid("deleteItem", args.item );
+ } );
- // arrays of items
- var items = $.map( $gridData.find("tr"), function(row) {
- return $(row).data("JSGridItem");
- });
}
});
+
+
+ var $gridData = $gridDiv.find( ".jsgrid-grid-body tbody" );
+
+ // Copied from http://js-grid.com/demos/rows-reordering.html
+ if ( editMultiplePages === undefined ) {
+ $gridData.sortable({
+ update: function( e, ui ) {
+ // array of indexes
+ var clientIndexRegExp = /\s+client-(\d+)\s+/;
+ var indexes = $.map( $gridData.sortable( "toArray", { attribute: "class" } ), function(classes) {
+ return clientIndexRegExp.exec(classes)[1];
+ });
+
+ // arrays of items
+ var items = $.map( $gridData.find("tr"), function(row) {
+ return $(row).data("JSGridItem");
+ });
+ }
+ });
+ }
});
$( "#pfForm" ).submit(function( event ) {
@@ -237,9 +646,9 @@
// will be undefined.
var isChecked = $( this ).find( ':checkbox' ).prop( 'checked' );
if ( isChecked === true ) {
- value = mw.msg( 'htmlform-yes' );
+ value = mw.config.get( 'wgPageFormsContLangYes' );
} else if ( isChecked === false ) {
- value = mw.msg( 'htmlform-no' );
+ value = mw.config.get( 'wgPageFormsContLangNo' );
}
var inputName = templateName + '[' + rowNum + '][' + paramName + ']';
$('<input>').attr( 'type', 'hidden' ).attr( 'name', inputName ).attr( 'value', value ).appendTo( '#pfForm' );
@@ -293,4 +702,4 @@
return this;
};
-}( jQuery, mediaWiki ) ); \ No newline at end of file
+}( jQuery, mediaWiki, pf ) ); \ No newline at end of file
diff --git a/www/wiki/extensions/PageForms/libs/PF_popupform.js b/www/wiki/extensions/PageForms/libs/PF_popupform.js
index d8f35e36..304513b3 100644
--- a/www/wiki/extensions/PageForms/libs/PF_popupform.js
+++ b/www/wiki/extensions/PageForms/libs/PF_popupform.js
@@ -51,7 +51,7 @@ window.ext.popupform = ( function () {
var brokenBrowser, brokenChrome;
var padding = 20;
-
+ var reload;
function fadeOut(elem, callback ) {
// no fading for broken browsers
if ( brokenBrowser ){
@@ -341,7 +341,7 @@ window.ext.popupform = ( function () {
elem.fadeTo(time, target, callback);
}
}
-
+
function showForm() {
instance++;
@@ -415,6 +415,13 @@ window.ext.popupform = ( function () {
closeBtn.click( handleCloseFrame );
}
+ function purgePage() {
+ var path = location.pathname;
+ // get name of the current page from the url
+ var pageName = path.split("/").pop();
+ return ( new mw.Api() ).post( { action: 'purge', titles: pageName } );
+ }
+
function handleSubmitData( event, returnedData, textStatus, XMLHttpRequest ){
fadeOut( container, function() {
fadeIn( waitIndicator );
@@ -443,7 +450,11 @@ window.ext.popupform = ( function () {
doc.close();
handleCloseFrame();
-
+ if ( reload ) {
+ purgePage().then( function( data ) {
+ location.reload();
+ } );
+ }
return false;
}
@@ -672,7 +683,7 @@ window.ext.popupform = ( function () {
if ( innerJ ) {
innerwdw.jQuery(form[0])
.bind( "submit", function( event ) {
- submitok = event.result;
+ submitok = ( event.result === undefined ) ? true : event.result;
innersubmitprocessed = true;
return false;
});
@@ -747,6 +758,7 @@ window.ext.popupform = ( function () {
function handlePopupFormInput( ptarget, elem ) {
showForm();
+ reload = $(elem).hasClass('reload');
iframe.on( 'load', function(){
// attach event handler to iframe
@@ -760,7 +772,7 @@ window.ext.popupform = ( function () {
function handlePopupFormLink( ptarget, elem ) {
showForm();
-
+ reload = $(elem).hasClass('reload');
// store initial readystate
var readystate = iframe.contents()[0].readyState;
@@ -818,7 +830,6 @@ window.ext.popupform = ( function () {
document.getElementsByTagName('body')[0].appendChild(form);
form.submit();
document.getElementsByTagName('body')[0].removeChild(form);
-
return false;
}
}
diff --git a/www/wiki/extensions/PageForms/libs/PageForms.js b/www/wiki/extensions/PageForms/libs/PageForms.js
index 29b68980..aaf3ee2f 100644
--- a/www/wiki/extensions/PageForms/libs/PageForms.js
+++ b/www/wiki/extensions/PageForms/libs/PageForms.js
@@ -504,17 +504,18 @@ function showDivIfSelected(options, div_id, inputVal, instanceWrapperDiv, initPa
}
// Used for handling 'show on select' for the 'dropdown' and 'listbox' inputs.
-$.fn.showIfSelected = function(initPage) {
+$.fn.showIfSelected = function(partOfMultiple, initPage) {
var inputVal = this.val(),
wgPageFormsShowOnSelect = mw.config.get( 'wgPageFormsShowOnSelect' ),
showOnSelectVals,
- instanceWrapperDiv = this.closest('.multipleTemplateInstance');
+ instanceWrapperDiv;
- if ( instanceWrapperDiv.length === 0 ) {
- instanceWrapperDiv = null;
- showOnSelectVals = wgPageFormsShowOnSelect[this.attr("id")];
- } else {
+ if ( partOfMultiple ) {
showOnSelectVals = wgPageFormsShowOnSelect[this.attr("data-origID")];
+ instanceWrapperDiv = this.closest('.multipleTemplateInstance');
+ } else {
+ showOnSelectVals = wgPageFormsShowOnSelect[this.attr("id")];
+ instanceWrapperDiv = null;
}
if ( showOnSelectVals !== undefined ) {
@@ -544,17 +545,18 @@ $.fn.showDivIfChecked = function(options, div_id, instanceWrapperDiv, initPage )
// Used for handling 'show on select' for the 'checkboxes' and 'radiobutton'
// inputs.
-$.fn.showIfChecked = function(initPage) {
+$.fn.showIfChecked = function(partOfMultiple, initPage) {
var wgPageFormsShowOnSelect = mw.config.get( 'wgPageFormsShowOnSelect' ),
showOnSelectVals,
+ instanceWrapperDiv,
i;
- var instanceWrapperDiv = this.closest('.multipleTemplateInstance');
- if ( instanceWrapperDiv.length === 0 ) {
- instanceWrapperDiv = null;
- showOnSelectVals = wgPageFormsShowOnSelect[this.attr("id")];
- } else {
+ if ( partOfMultiple ) {
showOnSelectVals = wgPageFormsShowOnSelect[this.attr("data-origID")];
+ instanceWrapperDiv = this.closest('.multipleTemplateInstance');
+ } else {
+ showOnSelectVals = wgPageFormsShowOnSelect[this.attr("id")];
+ instanceWrapperDiv = null;
}
if ( showOnSelectVals !== undefined ) {
@@ -915,11 +917,40 @@ $.fn.checkForPipes = function() {
if ( fieldVal.indexOf( '|' ) < 0 ) {
return true;
}
-
+
if (mw.config.get( 'wgAllowPipesInForms' )) {
return true;
}
+ // Also allow pipes within special tags, like <pre> or <syntaxhighlight>.
+ // Code copied, more or less, from PFTemplateInForm::escapeNonTemplatePipes().
+ var startAndEndTags = [
+ [ '<pre', 'pre>' ],
+ [ '<syntaxhighlight', 'syntaxhighlight>' ],
+ [ '<source', 'source>' ],
+ [ '<ref', 'ref>' ]
+ ];
+
+ for ( var i in startAndEndTags ) {
+ var startTag = startAndEndTags[i][0];
+ var endTag = startAndEndTags[i][1];
+ var pattern = RegExp( "(" + startTag + "[^]*?)\\|([^]*?" + endTag + ")", 'i' );
+ var matches;
+ while ( ( matches = fieldVal.match( pattern ) ) !== null ) {
+ // Special handling, to avoid escaping pipes
+ // within a string that looks like:
+ // startTag ... endTag | startTag ... endTag
+ if ( matches[1].includes( endTag ) &&
+ matches[2].includes( startTag ) ) {
+ fieldVal = fieldVal.replace( pattern, "$1" + "\2" + "$2");
+ } else {
+ fieldVal = fieldVal.replace( pattern, "$1" + "\1" + "$2" );
+ }
+ }
+ }
+ fieldVal = fieldVal.replace( "\2", '|' );
+
+ // Now check for pipes outside of brackets.
var nextPipe,
nextDoubleBracketsStart,
nextDoubleBracketsEnd;
@@ -1166,9 +1197,18 @@ $.fn.addInstance = function( addAboveCurInstance ) {
// Add in a 'b' at the end of the name to reduce the
// chance of name collision with another field
if (this.name) {
+ var real_old_name = this.name;
var old_name = this.name.replace(/\[num\]/g, '');
$(this).attr('origName', old_name);
this.name = this.name.replace(/\[num\]/g, '[' + num_elements + 'b]');
+ var new_name = this.name;
+
+ // replace name in imput that reference it :
+ new_div.find("input[data-targetname='"+real_old_name + "']").each(
+ function () {
+ $(this).attr('data-targetname',new_name);
+ }
+ );
}
if (this.id) {
@@ -1262,10 +1302,21 @@ $.fn.addInstance = function( addAboveCurInstance ) {
// Call every initialization method
// for this input
for ( var i = 0; i < thatData.length; i++ ) {
- thatData[i].initFunction(
+ var initFunction = thatData[i].initFunction;
+ // If the code attempted to store
+ // this function before it was
+ // defined, only its name was stored.
+ // In that case, get the function now.
+ // @TODO - move getFunctionFromName()
+ // so that it can be called from here,
+ // which would be better than window[].
+ if ( typeof initFunction === 'string' ) {
+ initFunction = window[initFunction];
+ }
+ initFunction(
this.id,
thatData[i].parameters
- );
+ );
}
}
}
@@ -1386,23 +1437,37 @@ $.fn.setAutocompleteForDependentField = function( partOfMultiple ) {
* instance of a multiple-instance template.
*/
$.fn.initializeJSElements = function( partOfMultiple ) {
+ var fancyBoxSettings;
+
this.find(".pfShowIfSelected").each( function() {
+ // Avoid duplicate calls on any one element.
+ if ( !partOfMultiple && $(this).parents('.multipleTemplateWrapper').length > 0 ) {
+ return;
+ }
$(this)
- .showIfSelected(true)
+ .showIfSelected(partOfMultiple, true)
.change( function() {
- $(this).showIfSelected(false);
+ $(this).showIfSelected(partOfMultiple, false);
});
});
this.find(".pfShowIfChecked").each( function() {
+ // Avoid duplicate calls on any one element.
+ if ( !partOfMultiple && $(this).parents('.multipleTemplateWrapper').length > 0 ) {
+ return;
+ }
$(this)
- .showIfChecked(true)
+ .showIfChecked(partOfMultiple, true)
.click( function() {
- $(this).showIfChecked(false);
+ $(this).showIfChecked(partOfMultiple, false);
});
});
this.find(".pfShowIfCheckedCheckbox").each( function() {
+ // Avoid duplicate calls on any one element.
+ if ( !partOfMultiple && $(this).parents('.multipleTemplateWrapper').length > 0 ) {
+ return;
+ }
$(this)
.showIfCheckedCheckbox(partOfMultiple, true)
.click( function() {
@@ -1410,37 +1475,35 @@ $.fn.initializeJSElements = function( partOfMultiple ) {
});
});
- // Enable the new remove button
- this.find(".removeButton").click( function() {
+ if ( partOfMultiple ) {
+ // Enable the new remove button
+ this.find(".removeButton").click( function() {
- // Unregister initialization and validation for deleted inputs
- $(this).parentsUntil( '.multipleTemplateInstance' ).last().parent().find("input, select, textarea").each(
+ // Unregister initialization and validation for deleted inputs
+ $(this).parentsUntil( '.multipleTemplateInstance' ).last().parent().find("input, select, textarea").each(
function() {
$(this).PageForms_unregisterInputInit();
$(this).PageForms_unregisterInputValidation();
}
);
- // Remove the encompassing div for this instance.
- $(this).closest(".multipleTemplateInstance")
- .fadeTo('fast', 0, function() {
- $(this).slideUp('fast', function() {
- $(this).remove();
+ // Remove the encompassing div for this instance.
+ $(this).closest(".multipleTemplateInstance")
+ .fadeTo('fast', 0, function() {
+ $(this).slideUp('fast', function() {
+ $(this).remove();
+ });
});
+ return false;
});
- return false;
- });
- // ...and the new adder
- if ( partOfMultiple ) {
+ // ...and the new adder
this.find('.addAboveButton').click( function() {
$(this).addInstance( true );
return false; // needed to disable <a> behavior
});
}
- this.find('.autocompleteInput').attachAutocomplete();
-
var combobox = new pf.select2.combobox();
this.find('.pfComboBox').not('#semantic_property_starter, .multipleTemplateStarter .pfComboBox, .select2-container').each( function() {
combobox.apply($(this));
@@ -1451,19 +1514,52 @@ $.fn.initializeJSElements = function( partOfMultiple ) {
tokens.apply($(this));
});
- this.find('.autoGrow').autoGrow();
- this.find('.pfFancyBox').fancybox({
- toolbar : false,
- smallBtn : true,
- iframe : {
- preload : false,
- css : {
- width : '75%',
- height : '75%'
- }
- },
- animationEffect : false
- });
+ // We use a different version of FancyBox depending on the version
+ // of jQuery (1 vs. 3) (which in turn depends on the version of
+ // MediaWiki (<= 1.29 vs. >= 1.30)).
+ if ( parseInt($().jquery) >= 3 ) {
+ fancyBoxSettings = {
+ toolbar : false,
+ smallBtn : true,
+ iframe : {
+ preload : false,
+ css : {
+ width : '75%',
+ height : '75%'
+ }
+ },
+ animationEffect : false
+ };
+ } else {
+ fancyBoxSettings = {
+ 'width' : '75%',
+ 'height' : '75%',
+ 'autoScale' : false,
+ 'transitionIn' : 'none',
+ 'transitionOut' : 'none',
+ 'type' : 'iframe',
+ 'overlayColor' : '#222',
+ 'overlayOpacity' : '0.8'
+ };
+ }
+
+ if ( partOfMultiple ) {
+ this.find('.pfFancyBox').fancybox(fancyBoxSettings);
+ this.find('.autocompleteInput').attachAutocomplete();
+ this.find('.autoGrow').autoGrow();
+ this.find(".pfRating").applyRatingInput();
+ this.find(".pfTreeInput").each( function() {
+ $(this).applyDynatree();
+ });
+ } else {
+ this.find('.pfFancyBox').not('multipleTemplateWrapper .pfFancyBox').fancybox(fancyBoxSettings);
+ this.find('.autocompleteInput').not('.multipleTemplateWrapper .autocompleteInput').attachAutocomplete();
+ this.find('.autoGrow').not('.multipleTemplateWrapper .autoGrow').autoGrow();
+ this.find(".pfRating").not(".multipleTemplateWrapper .pfRating").applyRatingInput();
+ this.find(".pfTreeInput").not(".multipleTemplateWrapper .pfTreeInput").each( function() {
+ $(this).applyDynatree();
+ });
+ }
// @TODO - this should ideally be called only for inputs that have
// a dependent field - which might involve changing the storage of
@@ -1485,18 +1581,33 @@ $.fn.initializeJSElements = function( partOfMultiple ) {
$(this).setAutocompleteForDependentField( partOfMultiple );
});
- this.find(".pfTreeInput").not(".multipleTemplateStarter .pfTreeInput").each( function() {
- $(this).applyDynatree();
- });
-
- this.find(".pfRating").each( function() {
- $(this).applyRatingInput();
- });
+ var myThis = this;
+ if ( $.fn.applyVisualEditor ) {
+ if ( partOfMultiple ) {
+ myThis.find(".visualeditor").applyVisualEditor();
+ } else {
+ myThis.find(".visualeditor").not(".multipleTemplateWrapper .visualeditor").applyVisualEditor();
+ }
+ } else {
+ $(document).bind('VEForAllLoaded', function(e) {
+ if ( partOfMultiple ) {
+ myThis.find(".visualeditor").applyVisualEditor();
+ } else {
+ myThis.find(".visualeditor").not(".multipleTemplateWrapper .visualeditor").applyVisualEditor();
+ }
+ });
+ }
// @TODO - this should be in the TinyMCE extension, and use a hook.
- this.find(".tinymce").not(".multipleTemplateStarter .tinymce").each( function() {
- mwTinyMCEInit( '#' + $(this).attr('id') );
- });
+ if ( partOfMultiple ) {
+ this.find(".tinymce").each( function() {
+ mwTinyMCEInit( '#' + $(this).attr('id') );
+ });
+ } else {
+ this.find(".tinymce").not(".multipleTemplateWrapper .tinymce").each( function() {
+ mwTinyMCEInit( '#' + $(this).attr('id') );
+ });
+ }
};
@@ -1512,6 +1623,11 @@ $(document).ready( function() {
for ( var i = 0; i < namespaces.length; i++ ) {
func = func[ namespaces[ i ] ];
}
+ // If this gets called before the function is defined, just
+ // store the function name instead, for later lookup.
+ if ( func === null ) {
+ return functionName;
+ }
return func;
}
@@ -1560,5 +1676,7 @@ $(document).ready( function() {
$('#pfForm').submit( function() {
return validateAll();
} );
+
+ mw.hook('pf.formInitializationEnd').fire();
});
}( jQuery, mediaWiki ) );
diff --git a/www/wiki/extensions/PageForms/libs/ext.pf.select2.base.js b/www/wiki/extensions/PageForms/libs/ext.pf.select2.base.js
index ac1bbc39..4cda14cc 100644
--- a/www/wiki/extensions/PageForms/libs/ext.pf.select2.base.js
+++ b/www/wiki/extensions/PageForms/libs/ext.pf.select2.base.js
@@ -42,10 +42,13 @@
*/
apply: function( element ) {
this.id = element.attr( "id" );
- var opts = this.setOptions();
-
- element.select2(opts);
- element.on( "change", this.onChange );
+ try {
+ var opts = this.setOptions();
+ element.select2(opts);
+ element.on( "change", this.onChange );
+ } catch (e) {
+ window.console.log(e);
+ }
},
/*
* Used to remove the select2 applied to the HTML element,
@@ -167,7 +170,7 @@
*
*/
nameAttr: function( element ) {
- return this.partOfMultiple( element ) ? "origname" : "name";
+ return this.partOfMultiple( element ) ? "origname" : "name";
},
/*
* Checks whether the field is part of multiple instance template or not
@@ -192,10 +195,11 @@
getDependentFieldOpts: function( dep_on ) {
var input_id = "#" + this.id;
var dep_field_opts = {};
- var base_element;
+ var base_element;
+
if ( this.partOfMultiple($(input_id)) ) {
base_element = $(input_id).closest( ".multipleTemplateInstance" )
- .find( '[origname ="' + dep_on + '" ]' );
+ .find( '[origname ="' + dep_on + '" ]' );
} else {
base_element = $('[name ="' + dep_on + '" ]');
}
@@ -216,9 +220,13 @@
getAutocompleteOpts: function() {
var input_id = "#" + this.id;
var autocomplete_opts = {};
+
+ if ( $(input_id).attr( "autocompletesettings" ) === undefined ) {
+ throw "Error: No autocomplete settings set for input " + input_id;
+ }
+
autocomplete_opts.autocompletedatatype = $(input_id).attr( "autocompletedatatype" );
autocomplete_opts.autocompletesettings = $(input_id).attr( "autocompletesettings" );
-
return autocomplete_opts;
},
/*
diff --git a/www/wiki/extensions/PageForms/libs/ext.pf.select2.tokens.js b/www/wiki/extensions/PageForms/libs/ext.pf.select2.tokens.js
index e670f7af..d33f3e8b 100644
--- a/www/wiki/extensions/PageForms/libs/ext.pf.select2.tokens.js
+++ b/www/wiki/extensions/PageForms/libs/ext.pf.select2.tokens.js
@@ -42,11 +42,15 @@
*
*/
tokens_proto.apply = function( element ) {
- this.id = element.attr( "id" );
- var opts = this.setOptions();
var cur_val = element.val();
+ this.id = element.attr( "id" );
- element.select2(opts);
+ try {
+ var opts = this.setOptions();
+ element.select2(opts);
+ } catch (e) {
+ window.console.log(e);
+ }
this.sortable(element);
element.on( "change", this.onChange );
element.val(cur_val);
diff --git a/www/wiki/extensions/PageForms/libs/select2.js b/www/wiki/extensions/PageForms/libs/select2.js
index aec61bf4..3b4f504e 100644
--- a/www/wiki/extensions/PageForms/libs/select2.js
+++ b/www/wiki/extensions/PageForms/libs/select2.js
@@ -1695,7 +1695,7 @@ the specific language governing permissions and limitations under the Apache Lic
opts.query({
element: opts.element,
- term: search.val(),
+ term: stripDiacritics(search.val()),
page: this.resultsPage,
context: null,
matcher: opts.matcher,
@@ -1734,7 +1734,7 @@ the specific language governing permissions and limitations under the Apache Lic
}
results.empty();
- self.opts.populateResults.call(this, results, data.results, {term: search.val(), page: this.resultsPage, context:null});
+ self.opts.populateResults.call(this, results, data.results, {term: stripDiacritics(search.val()), page: this.resultsPage, context:null});
if (data.more === true && checkFormatter(opts.formatLoadMore, "formatLoadMore")) {
results.append("<li class='select2-more-results'>" + self.opts.escapeMarkup(evaluate(opts.formatLoadMore, this.resultsPage)) + "</li>");
diff --git a/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.target.js b/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.target.js
index 20a7a7ea..60734b4a 100644
--- a/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.target.js
+++ b/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.target.js
@@ -12,7 +12,7 @@
* @extends ve.init.sa.Target
*/
mw.pageForms.ve.Target = function PageFormsVeTarget(node, content) {
-
+
this.$node = node;
var config = {};
config.toolbarConfig = {};
@@ -34,16 +34,19 @@
// HACK: stop VE's education popups from appearing (T116643)
this.dummyToolbar = true;
-
+
this.init(content);
+
};
OO.inheritClass( mw.pageForms.ve.Target, ve.init.sa.Target );
-
-
+
+
mw.pageForms.ve.Target.prototype.init = function ( content ) {
this.convertToHtml(content);
+
+ this.autoUpdate();
}
// Static
@@ -87,12 +90,12 @@
type: 'list',
icon: 'add',
label: '',
- include: [ 'insertTable', 'specialCharacter', 'warningblock','preformatted','infoblock', 'ideablock', 'dontblock', 'pinblock']
+ include: [ 'mediapmg', 'insertTable', 'specialCharacter', 'warningblock','preformatted','infoblock', 'ideablock', 'dontblock', 'pinblock', 'iatemplateblock']
},
// Special character toolbar
//{ include: [ 'specialCharacter' ] }
];
-
+
mw.pageForms.ve.Target.static.actionGroups = [
{ include: [ 'vefpgSwitchEditor' ] }
/*{
@@ -105,7 +108,7 @@
},*/
//{ include: [ 'link' ] }
];
-
+
// Allow pasting links
mw.pageForms.ve.Target.static.importRules = ve.copy( mw.pageForms.ve.Target.static.importRules );
@@ -130,7 +133,7 @@
mw.pageForms.ve.Target.static.actionGroups = [];
}
};
-
+
/**
* add listener to show or hide toolbar if the area get focus or loose it
*/
@@ -141,6 +144,8 @@
} );
this.getSurface().getView().on( 'focus', function (data) {
target.updateToolbarVisibility();
+
+ target.autoUpdate();
} );
this.updateToolbarVisibility();
}
@@ -156,13 +161,34 @@
} else {
this.getToolbar().$element.hide(500);
}
+
+ }
+
+ mw.pageForms.ve.Target.prototype.autoUpdate = function () {
+
+ var target = this;
+ if (target.autoUpdateWaiting) {
+ return;
+ }
+ target.autoUpdateWaiting = true;
+ setTimeout(function(){
+ target.autoUpdateWaiting = false;
+ var isActive = target.getSurface().getView().focused;
+ if (isActive) {
+ console.log("auto-update");
+ target.updateContent();
+ } else {
+
+ console.log("no auto-update");
+ }
+ target.autoUpdate();
+ }, 60000 * 4);
}
-
-
+
/**
* create a new surface with VisualEditor, and add it to the target
- *
+ *
* @param String content text to initiate content, in html format
*/
mw.pageForms.ve.Target.prototype.createWithHtmlContent = function(content) {
@@ -177,7 +203,7 @@
// Append the target to the document
$( this.$node ).before( this.$element );
-
+
$ (this.$node)
.hide()
.removeClass( 'oo-ui-texture-pending' )
@@ -191,7 +217,7 @@
console.log('switchEditor event');
target.switchEditor();
} );
-
+
// show or hide toolbar when loose focus
this.getSurface().getView().on( 'blur', function (data) {
target.updateToolbarVisibility();
@@ -206,24 +232,24 @@
if ( $focusedElement.length && this.$node.is( $focusedElement ) ) {
this.getSurface().getView().focus();
}
-
+
// fix BUG on initialisation of toolbar position :
target.getToolbar().onWindowResize();
target.onToolbarResize();
target.onContainerScroll();
}
-
+
/**
- * update the original textarea value with the content of VisualEditor surface
+ * update the original textarea value with the content of VisualEditor surface
* (converte the content into wikitext)
*/
mw.pageForms.ve.Target.prototype.updateContent = function () {
this.convertToWikiText(this.getSurface().getHtml());
}
-
+
mw.pageForms.ve.Target.prototype.getPageName = function () {
return mw.config.get( 'wgPageName' ).split(/(\\|\/)/g).pop();
}
@@ -233,10 +259,26 @@
var oldFormat = 'html';
var newFormat = 'wikitext';
+ var paragraphRegex = new RegExp("<\/?(p|span)( [^><]*)?\/?>", "gm");
+ var paragraphTypeOfRegex = new RegExp("typeof=", "gm");
+ if (content.replace(paragraphRegex, '').trim() === '' && ! content.match(paragraphTypeOfRegex)) {
+ // if content empty, no need to do a conversion call
+ $( target.$node ).val('');
+ $( target.$node ).change();
+ return;
+ }
+
+ //console.log("convert to wikitext : ");
+ //console.log(content);
+
$(this.$node)
- .prop( 'disabled', true )
+ //.prop( 'disabled', true )
.addClass( 'oo-ui-texture-pending' );
-
+
+ function onError() {
+
+ };
+
var apiCall = new mw.Api().post( {
action: 'flow-parsoid-utils',
from: oldFormat,
@@ -244,25 +286,39 @@
content: content,
title: this.getPageName()
} ).then( function (data) {
- $( target.$node ).val(data[ 'flow-parsoid-utils' ].content);
- $( target.$node ).change();
-
+ if (data[ 'flow-parsoid-utils' ].content) {
+ $( target.$node ).val(data[ 'flow-parsoid-utils' ].content);
+ $( target.$node ).change();
+ } else {
+ console.log('Error converting to wikitext : empty content');
+ }
+
$ (target.$node)
.removeClass( 'oo-ui-texture-pending' )
.prop( 'disabled', false );
})
.fail( function (data) {
- console.log('Error converting to wikitext');
+ $ (target.$node)
+ .removeClass( 'oo-ui-texture-pending' )
+ .prop( 'disabled', false );
+ console.log('Error converting to wikitext : call fails');
});
-
+
}
-
+
mw.pageForms.ve.Target.prototype.convertToHtml = function ( content ) {
var target = this;
var oldFormat = 'wikitext';
var newFormat = 'html';
-
-
+
+
+ if (content == '') {
+ // if content empty, no need to do a conversion call
+ target.createWithHtmlContent('');
+ return;
+ }
+
+
var apiCall = new mw.Api().post( {
action: 'flow-parsoid-utils',
from: oldFormat,
@@ -275,13 +331,13 @@
.fail( function (data) {
console.log('Error converting to html');
});
-
+
}
-
+
mw.pageForms.ve.Target.prototype.switchEditor = function ( content ) {
var textarea = this.$node;
-
+
if ( $(textarea).is(":visible") ) {
// switch back to VE
this.clearSurfaces();
@@ -297,7 +353,7 @@
}
}
-
+
/**
* Attach the toolbar to the DOM
* redifine attach Toolbar function to place on the bottom
diff --git a/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.targetwide.js b/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.targetwide.js
index 68ba6ff0..4778145b 100644
--- a/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.targetwide.js
+++ b/www/wiki/extensions/PageForms/libs/ve/ext.pageforms.ve.targetwide.js
@@ -12,7 +12,7 @@
* @extends ve.init.sa.Target
*/
mw.pageForms.ve.Targetwide = function PageFormsVeTargetwide(node, content) {
-
+
mw.pageForms.ve.Targetwide.parent.call( this, node, content );
};
@@ -57,12 +57,12 @@
type: 'list',
icon: 'add',
label: '',
- include: [ 'media', 'insertTable', 'specialCharacter', 'warningblock','preformatted','infoblock', 'ideablock', 'dontblock', 'pinblock']
+ include: [ 'mediapmg', 'insertTable', 'specialCharacter', 'warningblock','preformatted','infoblock', 'ideablock', 'dontblock', 'pinblock', 'iatemplateblock']
},
// Special character toolbar
//{ include: [ 'specialCharacter' ] }
];
-
+
ve.init.mw.targetFactory.register( mw.pageForms.ve.Targetwide );
}( mediaWiki, OO, ve ) );
diff --git a/www/wiki/extensions/PageForms/libs/ve/veforpageform.js b/www/wiki/extensions/PageForms/libs/ve/veforpageform.js
index 6f339f09..1a901510 100644
--- a/www/wiki/extensions/PageForms/libs/ve/veforpageform.js
+++ b/www/wiki/extensions/PageForms/libs/ve/veforpageform.js
@@ -1,22 +1,22 @@
/*!
- * VisualEditor for PageForm Initialization
+ * VisualEditor for PageForm Initialization
*
* @author Pierre Boutet, Clement Flipo
* @copyright Copyright © 2016-2017, Wikifab
* @license https://mit-license.org/ MIT
*/
( function ( $ , mw) {
-
+
/**
* what does this file do :
* - Load VisualEditor librairy
* - look for every textearea where we must activate visual editor, and activate it
* - watch click on save button, to defer the save request after all visualEditor requests are done.
- *
+ *
*/
-
+
var veInstances = [];
-
+
function initVisualEditor() {
// init VisualEditor Platform
new ve.init.mw.Platform( ).initialize()
@@ -28,33 +28,38 @@
// add i18n messages to VE
ve.init.platform.addMessages( mw.messages.get() );
-
+
// init all VisualEditor areas
addVisualEditorOnTextareas();
-
+
// add event on new step button, to appli VE on new steps
mw.hook( 'pf.addTemplateInstance' ).add( function(div) {
- $(div).find('.createboxInput.form-textarea').each(function() {
- activeVisualEditorOnTextArea(this);
- });
+ // set time out enable to run it in a new 'thread',
+ // and to continue hook execution without wait for VE to be loaded
+ setTimeout(function(){
+ $(div).find('.createboxInput.form-textarea').each(function() {
+ activeVisualEditorOnTextArea(this);
+ });
+ }, 20);
+
} );
} );
-
+
// we catch event on save button, to wait that every VE content is up to date
// (ie api calls triggered and received)
catchAndDelayClickEvent('wpSave');
catchAndDelayClickEvent('wpSaveAndContinue');
-
+
}
-
+
var clickCount = [];
-
+
function catchAndDelayClickEvent(buttonId) {
if( ! clickCount[buttonId]) {
clickCount[buttonId] = 0;
}
-
+
$('#'+buttonId).click( function(event) {
clickCount[buttonId] ++;
// the click count var is a security to avoid infinite loop if api calls do not end
@@ -69,7 +74,7 @@
if ((updateNeeded || jQuery.active > 0) && clickCount[buttonId] < 2) {
// if update needed, stop event propagation, and delay before relaunch
event.preventDefault();
- setTimeout( function () {
+ setTimeout( function () {
clickWhenApiCallDone('#'+buttonId, 5);
}, 100);
} else {
@@ -78,35 +83,42 @@
}
});
}
-
+
function clickWhenApiCallDone(button, maxCount) {
if (jQuery.active > 0 && maxCount > 0) {
- setTimeout( function () {
+ setTimeout( function () {
clickWhenApiCallDone(button, maxCount -1);
}, 500);
} else {
$(button).click();
}
}
-
+
function addVisualEditorOnTextareas() {
$('.createboxInput.form-textarea').not( ".multipleTemplateStarter .form-textarea" ).each(function() {
activeVisualEditorOnTextArea(this);
});
}
-
+
function activeVisualEditorOnTextArea(textarea) {
var logo = $('<div class="ve-demo-logo"></div>');
var toolbar = $('<div class="ve-demo-toolbar ve-demo-targetToolbar"></div>');
var editor = $('<div class="ve-demo-editor"></div>');
-
+
$(textarea).before(logo, editor, toolbar);
var veEditor = new mw.pageForms.ve.Editor(textarea, $(textarea).val());
veInstances.push( veEditor);
}
-
- mw.loader.using( 'ext.pageforms.visualeditor.visualEditor', $.proxy( initVisualEditor ) );
-
+
+ // init VE when VisualEditor OK :
+ //mw.loader.using( 'ext.pageforms.visualeditor.visualEditor', $.proxy( initVisualEditor ) );
+
+
+ // init VE When PF is init :
+ mw.hook( 'pf.formInitializationEnd' ).add( function(div) {
+ mw.loader.using( 'ext.pageforms.visualeditor.visualEditor', $.proxy( initVisualEditor ) );
+ });
+
}( jQuery , mw) );
$ = jQuery;
diff --git a/www/wiki/extensions/PageForms/package.json b/www/wiki/extensions/PageForms/package.json
index 414bb95c..0a2f648c 100644
--- a/www/wiki/extensions/PageForms/package.json
+++ b/www/wiki/extensions/PageForms/package.json
@@ -1,11 +1,11 @@
{
- "scripts": {
- "test": "grunt test"
- },
- "devDependencies": {
- "grunt": "1.0.1",
- "grunt-banana-checker": "0.5.0",
- "grunt-contrib-jshint": "1.0.0",
- "grunt-jsonlint": "1.1.0"
- }
+ "scripts": {
+ "test": "grunt test"
+ },
+ "devDependencies": {
+ "grunt": "1.0.3",
+ "grunt-banana-checker": "0.5.0",
+ "grunt-contrib-jshint": "1.0.0",
+ "grunt-jsonlint": "1.1.0"
+ }
}
diff --git a/www/wiki/extensions/PageForms/skins/blank.gif b/www/wiki/extensions/PageForms/skins/FancyBox/blank.gif
index 35d42e80..35d42e80 100644
--- a/www/wiki/extensions/PageForms/skins/blank.gif
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/blank.gif
Binary files differ
diff --git a/www/wiki/extensions/PageForms/skins/fancy_close.png b/www/wiki/extensions/PageForms/skins/FancyBox/fancy_close.png
index a80440ff..a80440ff 100644
--- a/www/wiki/extensions/PageForms/skins/fancy_close.png
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/fancy_close.png
Binary files differ
diff --git a/www/wiki/extensions/PageForms/skins/fancy_title_over.png b/www/wiki/extensions/PageForms/skins/FancyBox/fancy_title_over.png
index d9f458f4..d9f458f4 100644
--- a/www/wiki/extensions/PageForms/skins/fancy_title_over.png
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/fancy_title_over.png
Binary files differ
diff --git a/www/wiki/extensions/PageForms/skins/fancybox-x.png b/www/wiki/extensions/PageForms/skins/FancyBox/fancybox-x.png
index 718efb41..718efb41 100644
--- a/www/wiki/extensions/PageForms/skins/fancybox-x.png
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/fancybox-x.png
Binary files differ
diff --git a/www/wiki/extensions/PageForms/skins/fancybox-y.png b/www/wiki/extensions/PageForms/skins/FancyBox/fancybox-y.png
index 23ec8700..23ec8700 100644
--- a/www/wiki/extensions/PageForms/skins/fancybox-y.png
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/fancybox-y.png
Binary files differ
diff --git a/www/wiki/extensions/PageForms/skins/fancybox.png b/www/wiki/extensions/PageForms/skins/FancyBox/fancybox.png
index 99971629..99971629 100644
--- a/www/wiki/extensions/PageForms/skins/fancybox.png
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/fancybox.png
Binary files differ
diff --git a/www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.1.3.4.css b/www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.1.3.4.css
new file mode 100644
index 00000000..212330d2
--- /dev/null
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.1.3.4.css
@@ -0,0 +1,359 @@
+/*
+ * FancyBox - jQuery Plugin
+ * Simple and fancy lightbox alternative
+ *
+ * Examples and documentation at: http://fancybox.net
+ *
+ * Copyright (c) 2008 - 2010 Janis Skarnelis
+ * That said, it is hardly a one-person project. Many people have submitted bugs, code, and offered their advice freely. Their support is greatly appreciated.
+ *
+ * Version: 1.3.4 (11/11/2010)
+ * Requires: jQuery v1.3+
+ *
+ * Dual licensed under the MIT and GPL licenses:
+ * http://www.opensource.org/licenses/mit-license.php
+ * http://www.gnu.org/licenses/gpl.html
+ */
+
+#fancybox-loading {
+ position: fixed;
+ top: 50%;
+ left: 50%;
+ width: 40px;
+ height: 40px;
+ margin-top: -20px;
+ margin-left: -20px;
+ cursor: pointer;
+ overflow: hidden;
+ z-index: 1104;
+ display: none;
+}
+
+#fancybox-loading div {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 40px;
+ height: 480px;
+ background-image: url('fancybox.png');
+}
+
+#fancybox-overlay {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 100%;
+ z-index: 1100;
+ display: none;
+}
+
+#fancybox-tmp {
+ padding: 0;
+ margin: 0;
+ border: 0;
+ overflow: auto;
+ display: none;
+}
+
+#fancybox-wrap {
+ position: absolute;
+ top: 0;
+ left: 0;
+ padding: 20px;
+ z-index: 1101;
+ outline: none;
+ display: none;
+}
+
+#fancybox-outer {
+ position: relative;
+ width: 100%;
+ height: 100%;
+ background: #fff;
+}
+
+#fancybox-content {
+ width: 0;
+ height: 0;
+ padding: 0;
+ outline: none;
+ position: relative;
+ overflow: hidden;
+ z-index: 1102;
+ border: 0 solid #fff;
+}
+
+#fancybox-hide-sel-frame {
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ background: transparent;
+ z-index: 1101;
+}
+
+#fancybox-close {
+ position: absolute;
+ top: -15px;
+ right: -15px;
+ width: 30px;
+ height: 30px;
+ background: transparent url('fancybox.png') -40px 0;
+ cursor: pointer;
+ z-index: 1103;
+ display: none;
+}
+
+#fancybox-error {
+ color: #444;
+ font: normal 12px/20px Arial;
+ padding: 14px;
+ margin: 0;
+}
+
+#fancybox-img {
+ width: 100%;
+ height: 100%;
+ padding: 0;
+ margin: 0;
+ border: none;
+ outline: none;
+ line-height: 0;
+ vertical-align: top;
+}
+
+#fancybox-frame {
+ width: 100%;
+ height: 100%;
+ border: none;
+ display: block;
+}
+
+#fancybox-left, #fancybox-right {
+ position: absolute;
+ bottom: 0;
+ height: 100%;
+ width: 35%;
+ cursor: pointer;
+ outline: none;
+ background: transparent url('blank.gif');
+ z-index: 1102;
+ display: none;
+}
+
+#fancybox-left {
+ left: 0;
+}
+
+#fancybox-right {
+ right: 0;
+}
+
+#fancybox-left-ico, #fancybox-right-ico {
+ position: absolute;
+ top: 50%;
+ left: -9999px;
+ width: 30px;
+ height: 30px;
+ margin-top: -15px;
+ cursor: pointer;
+ z-index: 1102;
+ display: block;
+}
+
+#fancybox-left-ico {
+ background-image: url('fancybox.png');
+ background-position: -40px -30px;
+}
+
+#fancybox-right-ico {
+ background-image: url('fancybox.png');
+ background-position: -40px -60px;
+}
+
+#fancybox-left:hover, #fancybox-right:hover {
+ visibility: visible; /* IE6 */
+}
+
+#fancybox-left:hover span {
+ left: 20px;
+}
+
+#fancybox-right:hover span {
+ left: auto;
+ right: 20px;
+}
+
+.fancybox-bg {
+ position: absolute;
+ padding: 0;
+ margin: 0;
+ border: 0;
+ width: 20px;
+ height: 20px;
+ z-index: 1001;
+}
+
+#fancybox-bg-n {
+ top: -20px;
+ left: 0;
+ width: 100%;
+ background-image: url('fancybox-x.png');
+}
+
+#fancybox-bg-ne {
+ top: -20px;
+ right: -20px;
+ background-image: url('fancybox.png');
+ background-position: -40px -162px;
+}
+
+#fancybox-bg-e {
+ top: 0;
+ right: -20px;
+ height: 100%;
+ background-image: url('fancybox-y.png');
+ background-position: -20px 0;
+}
+
+#fancybox-bg-se {
+ bottom: -20px;
+ right: -20px;
+ background-image: url('fancybox.png');
+ background-position: -40px -182px;
+}
+
+#fancybox-bg-s {
+ bottom: -20px;
+ left: 0;
+ width: 100%;
+ background-image: url('fancybox-x.png');
+ background-position: 0 -20px;
+}
+
+#fancybox-bg-sw {
+ bottom: -20px;
+ left: -20px;
+ background-image: url('fancybox.png');
+ background-position: -40px -142px;
+}
+
+#fancybox-bg-w {
+ top: 0;
+ left: -20px;
+ height: 100%;
+ background-image: url('fancybox-y.png');
+}
+
+#fancybox-bg-nw {
+ top: -20px;
+ left: -20px;
+ background-image: url('fancybox.png');
+ background-position: -40px -122px;
+}
+
+#fancybox-title {
+ font-family: Helvetica;
+ font-size: 12px;
+ z-index: 1102;
+}
+
+.fancybox-title-inside {
+ padding-bottom: 10px;
+ text-align: center;
+ color: #333;
+ background: #fff;
+ position: relative;
+}
+
+.fancybox-title-outside {
+ padding-top: 10px;
+ color: #fff;
+}
+
+.fancybox-title-over {
+ position: absolute;
+ bottom: 0;
+ left: 0;
+ color: #FFF;
+ text-align: left;
+}
+
+#fancybox-title-over {
+ padding: 10px;
+ background-image: url('fancy_title_over.png');
+ display: block;
+}
+
+.fancybox-title-float {
+ position: absolute;
+ left: 0;
+ bottom: -20px;
+ height: 32px;
+}
+
+#fancybox-title-float-wrap {
+ border: none;
+ border-collapse: collapse;
+ width: auto;
+}
+
+#fancybox-title-float-wrap td {
+ border: none;
+ white-space: nowrap;
+}
+
+#fancybox-title-float-left {
+ padding: 0 0 0 15px;
+ background: url('fancybox.png') -40px -90px no-repeat;
+}
+
+#fancybox-title-float-main {
+ color: #FFF;
+ line-height: 29px;
+ font-weight: bold;
+ padding: 0 0 3px 0;
+ background: url('fancybox-x.png') 0 -40px;
+}
+
+#fancybox-title-float-right {
+ padding: 0 0 0 15px;
+ background: url('fancybox.png') -55px -90px no-repeat;
+}
+
+/* IE6 */
+
+.fancybox-ie6 #fancybox-close { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_close.png', sizingMethod='scale'); }
+
+.fancybox-ie6 #fancybox-left-ico { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_nav_left.png', sizingMethod='scale'); }
+.fancybox-ie6 #fancybox-right-ico { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_nav_right.png', sizingMethod='scale'); }
+
+.fancybox-ie6 #fancybox-title-over { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_over.png', sizingMethod='scale'); zoom: 1; }
+.fancybox-ie6 #fancybox-title-float-left { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_left.png', sizingMethod='scale'); }
+.fancybox-ie6 #fancybox-title-float-main { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_main.png', sizingMethod='scale'); }
+.fancybox-ie6 #fancybox-title-float-right { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_title_right.png', sizingMethod='scale'); }
+
+.fancybox-ie6 #fancybox-bg-w, .fancybox-ie6 #fancybox-bg-e, .fancybox-ie6 #fancybox-left, .fancybox-ie6 #fancybox-right, #fancybox-hide-sel-frame {
+ height: expression(this.parentNode.clientHeight + "px");
+}
+
+#fancybox-loading.fancybox-ie6 {
+ position: absolute; margin-top: 0;
+ top: expression( (-20 + (document.documentElement.clientHeight ? document.documentElement.clientHeight/2 : document.body.clientHeight/2 ) + ( ignoreMe = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop )) + 'px');
+}
+
+#fancybox-loading.fancybox-ie6 div { background: transparent; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_loading.png', sizingMethod='scale'); }
+
+/* IE6, IE7, IE8 */
+
+.fancybox-ie .fancybox-bg { background: transparent !important; }
+
+.fancybox-ie #fancybox-bg-n { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_n.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-ne { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_ne.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-e { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_e.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-se { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_se.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-s { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_s.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-sw { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_sw.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-w { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_w.png', sizingMethod='scale'); }
+.fancybox-ie #fancybox-bg-nw { filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(src='fancybox/fancy_shadow_nw.png', sizingMethod='scale'); } \ No newline at end of file
diff --git a/www/wiki/extensions/PageForms/skins/jquery.fancybox.css b/www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.3.2.10.css
index 6ed61314..6ed61314 100644
--- a/www/wiki/extensions/PageForms/skins/jquery.fancybox.css
+++ b/www/wiki/extensions/PageForms/skins/FancyBox/jquery.fancybox.3.2.10.css
diff --git a/www/wiki/extensions/PageForms/skins/PF_UploadWindow.css b/www/wiki/extensions/PageForms/skins/PF_UploadWindow.css
new file mode 100644
index 00000000..2cb7d3db
--- /dev/null
+++ b/www/wiki/extensions/PageForms/skins/PF_UploadWindow.css
@@ -0,0 +1,81 @@
+@import url('https://fonts.googleapis.com/css?family=Lato:400,900');
+
+body {
+ font-family: "Lato","Helvetica Neue",Helvetica,Arial,sans-serif;
+ -webkit-font-smoothing: subpixel-antialiased;
+ text-rendering: optimizeLegibility;
+ color: #30373b;
+ font-size: 14.5px;
+ padding: 10px;
+}
+
+fieldset legend {
+ float: left;
+ width: 100%;
+ font-weight: 900;
+ margin-bottom: 10px;
+ border-bottom: 1px solid #ccc;
+ padding: 10px 0 5px;
+ text-transform: uppercase;
+ font-size: 16px;
+}
+
+fieldset {
+ background: #fafbfc;
+ border-radius: 3px;
+ border: 0;
+ margin-bottom: 15px;
+}
+
+.mw-htmlform-field-HTMLInfoField .mw-label,
+.mw-htmlform-field-HTMLTextAreaField {
+ display:none;
+}
+
+.mw-htmlform-field-HTMLInfoField {
+ font-size: 0.89em;
+}
+
+.mw-htmlform-field-PFUploadSourceField {
+ display: flex;
+}
+.mw-htmlform-field-Licenses {
+ display: none;
+}
+input#wpDestFile {
+ height: 30px;
+ border-radius: 3px;
+ border: 2px solid #ddd;
+ padding: 0 7px;
+}
+
+input#wpDestFile:hover {
+ border: 2px solid #ccc;
+}
+
+input#wpDestFile:active {
+ border: 2px solid #52bad5;
+}
+
+input#wpDestFile:focus {
+ outline: none;
+ box-shadow: none;
+ outline-offset: 0;
+}
+
+.mw-htmlform-submit-buttons input {
+ background-color: #52bad5;
+ color: #fff;
+ padding: 7px 12px;
+ border: none;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ transition: all ease .25s;
+ font-size: 1em;
+ cursor:pointer;
+}
+
+.mw-htmlform-submit-buttons input:hover {
+ background-color: #2c9ab7;
+}
diff --git a/www/wiki/extensions/PageForms/skins/PF_popupform.css b/www/wiki/extensions/PageForms/skins/PF_popupform.css
index bd98b43d..bf16ed5f 100644
--- a/www/wiki/extensions/PageForms/skins/PF_popupform.css
+++ b/www/wiki/extensions/PageForms/skins/PF_popupform.css
@@ -59,7 +59,7 @@ div.popupform-close {
width: 30px;
height: 30px;
cursor: pointer;
- background-image: url('fancy_close.png');
+ background-image: url('FancyBox/fancy_close.png');
}
div.popupform-loading {
diff --git a/www/wiki/extensions/PageForms/specials/PF_CreateForm.php b/www/wiki/extensions/PageForms/specials/PF_CreateForm.php
index 8122e0e8..7366bab7 100644
--- a/www/wiki/extensions/PageForms/specials/PF_CreateForm.php
+++ b/www/wiki/extensions/PageForms/specials/PF_CreateForm.php
@@ -33,7 +33,7 @@ class PFCreateForm extends SpecialPage {
$fieldFormText = $req->getVal( 'formfield' );
$paramValues = array();
- // @TODO - is any of this "params" stuff necesary?
+ // @TODO - is any of this "params" stuff necessary?
// For now, it's removed - if the setting of params is
// going to be re-added, that has to be done in the JS.
/*
diff --git a/www/wiki/extensions/PageForms/specials/PF_FormEdit.php b/www/wiki/extensions/PageForms/specials/PF_FormEdit.php
index 0939ede3..25552ad8 100644
--- a/www/wiki/extensions/PageForms/specials/PF_FormEdit.php
+++ b/www/wiki/extensions/PageForms/specials/PF_FormEdit.php
@@ -52,7 +52,7 @@ class PFFormEdit extends UnlistedSpecialPage {
if ( $i++ > 0 ) {
$text .= ', ';
}
- $altFormURL = $fe_url . '/' . rawurlencode( $alt_form ) . '/' . rawurlencode( $target_name );
+ $altFormURL = $fe_url . '/' . $alt_form . '/' . $target_name;
$text .= Html::element( 'a',
array( 'href' => $altFormURL ),
str_replace( '_', ' ', $alt_form )
diff --git a/www/wiki/extensions/PageForms/specials/PF_MultiPageEdit.php b/www/wiki/extensions/PageForms/specials/PF_MultiPageEdit.php
new file mode 100644
index 00000000..a2e14bf8
--- /dev/null
+++ b/www/wiki/extensions/PageForms/specials/PF_MultiPageEdit.php
@@ -0,0 +1,284 @@
+<?php
+/**
+ * Displays a spreadsheet interface for editing and adding pages for a particular
+ * template. If no template is specified, displays a list of all available templates.
+ *
+ *
+ * @file
+ * @ingroup PF
+ * @author Yashdeep Thorat
+ */
+
+/**
+ * @ingroup PFSpecialPages
+ */
+class PFMultiPageEdit extends SpecialPage {
+
+ public $mTemplate;
+ public $mForm;
+
+ /**
+ * Constructor
+ */
+ function __construct() {
+ parent::__construct( 'MultiPageEdit', 'multipageedit' );
+ }
+
+ function execute( $query ) {
+ $this->setHeaders();
+
+ // Check permissions.
+ if ( !$this->getUser()->isAllowed( 'multipageedit' ) ) {
+ $this->displayRestrictionError();
+ return;
+ }
+
+ $this->mTemplate = $this->getRequest()->getText( 'template' );
+ $this->mForm = $this->getRequest()->getText( 'form' );
+ // If a template is not specified, list all the available templates.
+ if ( empty( $this->mTemplate ) ) {
+ list( $limit, $offset ) = $this->getRequest()->getLimitOffset();
+ $rep = new SpreadsheetTemplatesPage();
+ $rep->execute( $query );
+ } else {
+ if ( empty( $this->mForm ) ) {
+ list( $limit, $offset ) = $this->getRequest()->getLimitOffset();
+ $rep = new SpreadsheetTemplatesPage();
+ $rep->execute( $query );
+ } else {
+ $this->createSpreadsheet( $this->mTemplate, $this->mForm );
+ }
+ }
+ }
+
+ /**
+ * Creates the spreadsheet Interface for a template and dislpays all the
+ * template calls( instances ) as rows.
+ * @param string $template_name
+ */
+ private function createSpreadsheet( $template_name, $form_name ) {
+ global $wgPageFormsGridParams, $wgPageFormsScriptPath;
+ global $wgPageFormsAutocompleteValues, $wgPageFormsMaxLocalAutocompleteValues;
+ global $wgPageFormsContLangYes, $wgPageFormsContLangNo, $wgPageFormsContLangMonths;
+
+ $out = $this->getOutput();
+ $req = $this->getRequest();
+
+ $out->addModules( 'ext.pageforms.PF_MultiPageEdit' );
+ $text = '';
+ $out->setPageTitle( wfMessage( 'pf_multipageedit_with-name', $this->mTemplate )->text() );
+
+ $template = PFTemplate::newFromName( $template_name );
+ $templateCalls = array();
+
+ $templateFields = $template->getTemplateFields();
+
+ $gridParams = array();
+ $gridParamValues = array( 'name' => 'page', 'title' => 'Page', 'type' => 'text' );
+ $gridParams[] = $gridParamValues;
+
+ foreach ( $templateFields as $templateField ) {
+ $gridParamValues = array( 'name' => $templateField->getFieldName() );
+ $gridParamValues['title'] = $templateField->getLabel();
+ $gridParamValues['type'] = 'text';
+ if ( !empty( $fieldType = $templateField->getFieldType() ) ) {
+ if ( $fieldType == 'Date' ) {
+ $gridParamValues['type'] = 'date';
+ } elseif ( $fieldType == 'Boolean' ) {
+ $gridParamValues['type'] = 'checkbox';
+ } elseif ( $fieldType == 'Text' ) {
+ $gridParamValues['type'] = 'textarea';
+ } elseif ( $fieldType == 'Page' ) {
+ $gridParamValues['type'] = 'select';
+ if ( $templateField->isList() ) {
+ $gridParamValues['type'] = 'tokens';
+ $gridParamValues['delimiter'] = $templateField->getDelimiter();
+ } else {
+ $gridParamValues['type'] = 'combobox';
+ }
+ $fullCargoField = $templateField->getFullCargoField();
+ $autocompleteValues = PFValuesUtils::getAutocompleteValues( $fullCargoField, 'cargo field' );
+ $gridParamValues['autocompletesettings'] = $fullCargoField;
+ if ( count( $autocompleteValues ) > $wgPageFormsMaxLocalAutocompleteValues ) {
+ $gridParamValues['autocompletedatatype'] = 'cargo field';
+ } else {
+ $wgPageFormsAutocompleteValues[$fullCargoField] = $autocompleteValues;
+ }
+ }
+ } elseif ( !empty( $propertyType = $templateField->getPropertyType() ) ) {
+ if ( $propertyType == '_dat' ) {
+ $gridParamValues['type'] = 'date';
+ } elseif ( $propertyType == '_boo' ) {
+ $gridParamValues['type'] = 'checkbox';
+ } elseif ( $propertyType == '_txt' || $propertyType == '_cod' ) {
+ $gridParamValues['type'] = 'textarea';
+ } elseif ( $propertyType == '_wpg' ) {
+ if ( $templateField->isList() ) {
+ $gridParamValues['type'] = 'tokens';
+ $gridParamValues['delimiter'] = $templateField->getDelimiter();
+ } else {
+ $gridParamValues['type'] = 'combobox';
+ }
+ $property = $templateField->getSemanticProperty();
+ $autocompleteValues = PFValuesUtils::getAutocompleteValues( $property, 'property' );
+ $gridParamValues['autocompletesettings'] = $property;
+ if ( count( $autocompleteValues ) > $wgPageFormsMaxLocalAutocompleteValues ) {
+ $gridParamValues['autocompletedatatype'] = 'property';
+ } else {
+ $wgPageFormsAutocompleteValues[$property] = $autocompleteValues;
+ }
+
+ }
+ }
+ $gridParams[] = $gridParamValues;
+ }
+ $templateDivID = str_replace( ' ', '', $template_name ) . "Grid";
+ $templateDivAttrs = array(
+ 'class' => 'pfJSGrid',
+ 'id' => $templateDivID,
+ 'data-template-name' => $template_name,
+ 'data-form-name' => $form_name,
+ 'height' => '500px',
+ 'editMultiplePages' => true
+ );
+ $loadingImage = Html::element( 'img', array( 'src' => "$wgPageFormsScriptPath/skins/loading.gif" ) );
+
+ $text .= "<div id='loadingImage' style='display: none;'>" . $loadingImage . "</div>";
+
+ $text .= Html::rawElement( 'div', $templateDivAttrs, $loadingImage );
+ $wgPageFormsGridParams[$template_name] = $gridParams;
+
+ // JS variables that hol boolean and date values in wiki's (as
+ // opposed to user's) language.
+ $wgPageFormsContLangYes = wfMessage( 'htmlform-yes' )->inContentLanguage()->text();
+ $wgPageFormsContLangNo = wfMessage( 'htmlform-no' )->inContentLanguage()->text();
+ $monthMessages = array(
+ "january", "february", "march", "april", "may_long", "june",
+ "july", "august", "september", "october", "november", "december"
+ );
+ $wgPageFormsContLangMonths = array( '' );
+ foreach ( $monthMessages as $monthMsg ) {
+ $wgPageFormsContLangMonths[] = wfMessage( $monthMsg )->inContentLanguage()->text();
+ }
+
+ $text .= "<p><div id='selectLimit'></div></p>";
+
+ $out->addHTML( $text );
+ }
+
+ protected function getGroupName() {
+ return 'pf_group';
+ }
+}
+
+/**
+ * @ingroup PFSpecialPages
+ */
+class SpreadsheetTemplatesPage extends QueryPage {
+
+ private $templateInForm = array();
+ private $templatesUsed = array();
+
+ /**
+ * This function is used to find all the non-repeating templates in all the
+ * forms available in the wiki and store them along with the form names
+ * in an array using helper functions.
+ * @param string $name
+ */
+ public function __construct( $name = 'MultiPageEdit' ) {
+ $dbr = wfGetDB( DB_SLAVE );
+ $res = $dbr->select(
+ array( 'page' ),
+ array( 'page_title' ),
+ array( 'page_namespace' => PF_NS_FORM, 'page_is_redirect' => 0 ),
+ __METHOD__,
+ array(),
+ array()
+ );
+ while ( $row = $dbr->fetchRow( $res ) ) {
+ $formTitle = Title::makeTitle( PF_NS_FORM, $row['page_title'] );
+ $this->findTemplates( $formTitle );
+ }
+ parent::__construct( $name );
+ }
+
+ function getName() {
+ return "MultiPageEdit";
+ }
+
+ function isExpensive() {
+ return false;
+ }
+
+ function isSyndicated() {
+ return false;
+ }
+
+ function getPageHeader() {
+ $header = Html::element( 'p', null, wfMessage( 'pf_multipageedit_docu' )->text() );
+ return $header;
+ }
+
+ function getPageFooter() {
+ }
+
+ function getQueryInfo() {
+ return array(
+ 'tables' => array( 'page' ),
+ 'fields' => array( 'page_title AS title', 'page_title AS value' ),
+ 'conds' => array( 'page_namespace' => NS_TEMPLATE )
+ );
+ }
+
+ function sortDescending() {
+ return false;
+ }
+
+ function findTemplates( $formTitle ) {
+ $formWikiPage = WikiPage::factory( $formTitle );
+ $formContent = $formWikiPage->getContent( Revision::RAW )->getNativeData();
+ $start_position = 0;
+ while ( $brackets_loc = strpos( $formContent, '{{{', $start_position ) ) {
+ $brackets_end_loc = strpos( $formContent, "}}}", $brackets_loc );
+ $bracketed_string = substr( $formContent, $brackets_loc + 3, $brackets_end_loc - ( $brackets_loc + 3 ) );
+ $tag_components = PFUtils::getFormTagComponents( $bracketed_string );
+ $tag_title = trim( $tag_components[0] );
+ if ( $tag_title == 'for template' ) {
+ if ( count( $tag_components ) > 1 ) {
+ $templateName = $tag_components[1];
+ if ( array_key_exists( $templateName, $this->templatesUsed ) ) {
+ unset( $this->templateInForm[$templateName] );
+ } else {
+ $this->templateInForm[$templateName] = $formTitle->getText();
+ $this->templatesUsed[$templateName] = $formTitle->getText();
+ }
+ }
+ }
+ $start_position = $brackets_loc + 1;
+ }
+ }
+
+ function getFormForTemplate( $templateName ) {
+ if ( !array_key_exists( $templateName, $this->templateInForm ) ) {
+ return null;
+ }
+ return $this->templateInForm[$templateName];
+ }
+
+ function formatResult( $skin, $result ) {
+ $templateName = $result->value;
+ $formName = $this->getFormForTemplate( $templateName );
+ if ( $formName == null ) {
+ return false;
+ }
+ $templateTitle = Title::makeTitle( NS_TEMPLATE, $templateName );
+ if ( method_exists( $this, 'getLinkRenderer' ) ) {
+ $linkRenderer = $this->getLinkRenderer();
+ } else {
+ $linkRenderer = null;
+ }
+ $sp = SpecialPageFactory::getPage( 'MultiPageEdit' );
+ $text = PFUtils::makeLink( $linkRenderer, $sp->getTitle(), $templateTitle->getText(), array(), array( "template" => $templateTitle->getText(), "form" => $formName ) );
+ return $text;
+ }
+}
diff --git a/www/wiki/extensions/PageForms/specials/PF_UploadForm.php b/www/wiki/extensions/PageForms/specials/PF_UploadForm.php
index a90ef975..989fc2ca 100644
--- a/www/wiki/extensions/PageForms/specials/PF_UploadForm.php
+++ b/www/wiki/extensions/PageForms/specials/PF_UploadForm.php
@@ -100,16 +100,16 @@ class PFUploadForm extends HTMLForm {
);
}
- $maxUploadSizeFile = ini_get( 'upload_max_filesize' );
- $maxUploadSizeURL = ini_get( 'upload_max_filesize' );
+ $maxUploadSizeFile = wfShorthandToInteger(ini_get( 'upload_max_filesize' ));
+ $maxUploadSizeURL = wfShorthandToInteger(ini_get( 'upload_max_filesize' ));
global $wgMaxUploadSize;
if ( isset( $wgMaxUploadSize ) ) {
if ( gettype( $wgMaxUploadSize ) == "array" ) {
- $maxUploadSizeFile = $wgMaxUploadSize['*'];
- $maxUploadSizeURL = $wgMaxUploadSize['url'];
+ $maxUploadSizeFile = min($wgMaxUploadSize['*'], $maxUploadSizeFile);
+ $maxUploadSizeURL = min($wgMaxUploadSize['url'], $maxUploadSizeURL);
} else {
- $maxUploadSizeFile = $wgMaxUploadSize;
- $maxUploadSizeURL = $wgMaxUploadSize;
+ $maxUploadSizeFile = min($wgMaxUploadSize, $maxUploadSizeFile);
+ $maxUploadSizeURL = min($wgMaxUploadSize, $maxUploadSizeURL);
}
}
@@ -122,9 +122,7 @@ class PFUploadForm extends HTMLForm {
'upload-type' => 'File',
'radio' => &$radio,
'help' => wfMessage( 'upload-maxfilesize',
- $this->getLanguage()->formatSize(
- wfShorthandToInteger( $maxUploadSizeFile )
- )
+ $this->getLanguage()->formatSize($maxUploadSizeFile)
)->parse() . ' ' . wfMessage( 'upload_source_file' )->escaped(),
'checked' => $selectedSourceType == 'file',
);
diff --git a/www/wiki/extensions/PageForms/specials/PF_UploadWindow.php b/www/wiki/extensions/PageForms/specials/PF_UploadWindow.php
index c7f6cc05..254fbcdb 100644
--- a/www/wiki/extensions/PageForms/specials/PF_UploadWindow.php
+++ b/www/wiki/extensions/PageForms/specials/PF_UploadWindow.php
@@ -17,7 +17,7 @@ class PFUploadWindow extends UnlistedSpecialPage {
/**
* Constructor : initialise object
* Get data POSTed through the form and assign them to the object
- * @param WebRequest $request Data posted.
+ * @param WebRequest|null $request Data posted.
*/
public function __construct( $request = null ) {
parent::__construct( 'UploadWindow', 'upload' );
@@ -116,6 +116,9 @@ class PFUploadWindow extends UnlistedSpecialPage {
$this->setHeaders();
$this->outputHeader();
+ # style
+ $this->getOutput()->addHTML('<link rel="stylesheet" href="' . $this->getOutput()->getResourceLoader()->getModule('ext.pageforms.PF_UploadWindow')->getStyleURLsForDebug(ResourceLoaderContext::newDummyContext())['all'][0] . '" >');
+
# Check uploading enabled
if ( !UploadBase::isEnabled() ) {
throw new ErrorPageError( 'uploaddisabled', 'uploaddisabledtext' );
@@ -578,7 +581,11 @@ END;
}
$success = $this->mUpload->unsaveUploadedFile();
if ( ! $success ) {
- $this->getOutput()->showFileDeleteError( $this->mUpload->getTempPath() );
+ $this->getOutput()->showFatalError(
+ $this->msg( 'filedeleteerror' )
+ ->params( $this->mUpload->getTempPath() )
+ ->escaped()
+ );
return false;
} else {
return true;
diff --git a/www/wiki/extensions/ParserFunctions/Gruntfile.js b/www/wiki/extensions/ParserFunctions/Gruntfile.js
index 528caa1a..af2402e4 100644
--- a/www/wiki/extensions/ParserFunctions/Gruntfile.js
+++ b/www/wiki/extensions/ParserFunctions/Gruntfile.js
@@ -23,7 +23,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/ParserFunctions/ParserFunctions.i18n.magic.php b/www/wiki/extensions/ParserFunctions/ParserFunctions.i18n.magic.php
index 1a234116..36892cef 100644
--- a/www/wiki/extensions/ParserFunctions/ParserFunctions.i18n.magic.php
+++ b/www/wiki/extensions/ParserFunctions/ParserFunctions.i18n.magic.php
@@ -655,7 +655,26 @@ $magicWords['uk'] = [
/** Urdu (اردو) */
$magicWords['ur'] = [
+ 'expr' => [ 0, 'اظہار' ],
'if' => [ 0, 'اگر' ],
+ 'ifeq' => [ 0, 'اگربرابر' ],
+ 'ifexpr' => [ 0, 'اگراظہار' ],
+ 'iferror' => [ 0, 'اگرنقص' ],
+ 'switch' => [ 0, 'منتقل' ],
+ 'default' => [ 0, '#ابتدائی' ],
+ 'ifexist' => [ 0, 'اگرموجود' ],
+ 'time' => [ 0, 'وقت' ],
+ 'timel' => [ 0, 'وقت_لمبائی' ],
+ 'rel2abs' => [ 0, 'اضافی_تا_مطلق' ],
+ 'titleparts' => [ 0, 'اجزاء_عنوان' ],
+ 'len' => [ 0, 'لمبائی' ],
+ 'pos' => [ 0, 'جگہ' ],
+ 'rpos' => [ 0, 'جگہ_واپس' ],
+ 'sub' => [ 0, 'ذیلی' ],
+ 'count' => [ 0, 'شمار' ],
+ 'replace' => [ 0, 'تبدیلی' ],
+ 'explode' => [ 0, 'انتشار' ],
+ 'urldecode' => [ 0, 'بلاکوڈیوآرایل' ],
];
/** Uzbek (oʻzbekcha/ўзбекча) */
diff --git a/www/wiki/extensions/ParserFunctions/composer.json b/www/wiki/extensions/ParserFunctions/composer.json
index 021a14cb..b822010c 100644
--- a/www/wiki/extensions/ParserFunctions/composer.json
+++ b/www/wiki/extensions/ParserFunctions/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/ParserFunctions/extension.json b/www/wiki/extensions/ParserFunctions/extension.json
index 9b38c5a8..9f9f165e 100644
--- a/www/wiki/extensions/ParserFunctions/extension.json
+++ b/www/wiki/extensions/ParserFunctions/extension.json
@@ -9,7 +9,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:ParserFunctions",
"descriptionmsg": "pfunc_desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "parserhook",
"requires": {
"MediaWiki": ">= 1.25.0"
@@ -36,15 +36,11 @@
]
},
"AutoloadClasses": {
- "ExtParserFunctions": "ParserFunctions_body.php",
- "ExprParser": "Expr.php",
- "ExprError": "Expr.php",
- "Scribunto_LuaParserFunctionsLibrary": "ParserFunctions.library.php",
- "ParserFunctionsHooks": "ParserFunctions.hooks.php"
+ "ExtParserFunctions": "includes/ExtParserFunctions.php",
+ "ExprParser": "includes/ExprParser.php",
+ "ExprError": "includes/ExprError.php",
+ "Scribunto_LuaParserFunctionsLibrary": "includes/Scribunto_LuaParserFunctionsLibrary.php",
+ "ParserFunctionsHooks": "includes/ParserFunctionsHooks.php"
},
- "ParserTestFiles": [
- "funcsParserTests.txt",
- "stringFunctionTests.txt"
- ],
"manifest_version": 1
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/ais.json b/www/wiki/extensions/ParserFunctions/i18n/ais.json
index 3e0f4757..c31f0989 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/ais.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/ais.json
@@ -5,10 +5,25 @@
"Bunukwiki"
]
},
+ "pfunc_desc": "sangaleb papulita-sakaluk, nipabeli loci sapisausi sasahicaan",
"pfunc_time_error": "mungangaw: la’cusay a tuki",
+ "pfunc_time_too_long": "mungangaw: mangsiw #time miawaw.",
+ "pfunc_time_too_big": "mungangaw:#time midama pabaw-sahezek ku 9999 a mihca.",
+ "pfunc_time_too_small": "mungangaw: #time midama sainayi'ay ku 0 a mihca.",
+ "pfunc_rel2abs_invalid_depth": "mungangaw: la’cusay a zazan salabuay:\"$1\" (mitanam misuped-miala pabaw nu lamit ciyityin)",
+ "pfunc_expr_stack_exhausted": "sakamu tu nizateng sasakawawen mungangaw: kalud kihkih tuway.",
+ "pfunc_expr_unexpected_number": "sakamu tu nizateng sasakawawen mungangaw: talibahalay asip-bacu.",
+ "pfunc_expr_preg_match_failure": "sakamu tu nizateng sasakawawen mungangaw: talibahalay preg_match mungangaw.",
"pfunc_expr_unrecognised_word": "sakamu tu nizateng sasakawawen mungangaw: la’cusay sapulitaan a sulit \"$1\".",
"pfunc_expr_unexpected_operator": "Expression error: Unexpected $1 operator.",
"pfunc_expr_missing_operand": "sakamu tu nizateng sasakawawen mungangaw:caay kataneng $1 a yunswaniyin.",
+ "pfunc_expr_unexpected_closing_bracket": "sakamu tu nizateng sasakawawen mungangaw: talibahalay a belih kwahaw",
"pfunc_expr_unrecognised_punctuation": "sakamu tu nizateng sasakawawen mungangaw: la’cusay sapulitaan a sulit nu hahanhanan nu kamu \"$1\".",
- "pfunc_expr_division_by_zero": "sapiwada’ nu piasip u inayi’."
+ "pfunc_expr_unclosed_bracket": "sakamu tu nizateng sasakawawen mungangaw: caay pahezek a kwahaw.",
+ "pfunc_expr_division_by_zero": "sapiwada’ nu piasip u inayi’.",
+ "pfunc_expr_invalid_argument": "$1 a aazihen-sulyang la’cus: < -1 saca > 1.",
+ "pfunc_expr_invalid_argument_ln": "ln a aazihan a sulyang la’cus: <= 0.",
+ "pfunc_expr_unknown_error": "sakamu tu nizateng sasakawawen mungangaw:caay katinengay a mungangaw ($1)",
+ "pfunc_expr_not_a_number": "ilabu $1: kya heci caay ku asip-bacu.",
+ "pfunc_string_too_long": "mungangaw: sulisulitan mangasiw $1 tatebanan-nisulitan kelec."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/anp.json b/www/wiki/extensions/ParserFunctions/i18n/anp.json
index d726fc22..abf4157a 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/anp.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/anp.json
@@ -4,8 +4,10 @@
"Angpradesh"
]
},
+ "pfunc_time_error": "त्रुटि: अमान्य समय।",
"pfunc_expr_unrecognised_word": "एक्स्प्रेशन त्रुटि: अज्ञात शब्द \"$1\"।",
"pfunc_expr_unexpected_operator": "एक्स्प्रेशन त्रुटि: अनपेक्षित $1 ऑपरेटर",
"pfunc_expr_missing_operand": "एक्स्प्रेशन त्रुटि: $1 केरऽ घटक नै मिललै",
- "pfunc_expr_unrecognised_punctuation": "एक्स्प्रेशन त्रुटि: अनपेक्षित उद्गार चिन्ह \"$1\""
+ "pfunc_expr_unrecognised_punctuation": "एक्स्प्रेशन त्रुटि: अनपेक्षित उद्गार चिन्ह \"$1\"",
+ "pfunc_expr_division_by_zero": "शून्य स॑ भाग।"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/ar.json b/www/wiki/extensions/ParserFunctions/i18n/ar.json
index 307bc7db..15ea9638 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/ar.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/ar.json
@@ -3,7 +3,8 @@
"authors": [
"Aiman titi",
"Asaifm",
- "Meno25"
+ "Meno25",
+ "أحمد"
]
},
"pfunc_desc": "محلل ممدد بدوال منطقية",
@@ -17,7 +18,7 @@
"pfunc_expr_preg_match_failure": "خطأ في التعبير: فشل preg_match غير متوقع",
"pfunc_expr_unrecognised_word": "خطأ في التعبير: كلمة غير متعرف عليها \"$1\"",
"pfunc_expr_unexpected_operator": "خطأ في التعبير: عامل $1 غير متوقع",
- "pfunc_expr_missing_operand": "خطأ في التعبير: operand مفقود ل$1",
+ "pfunc_expr_missing_operand": "خطأ في التعبير: معامل مفقود للعامل $1",
"pfunc_expr_unexpected_closing_bracket": "خطأ في التعبير: قوس إغلاق غير متوقع",
"pfunc_expr_unrecognised_punctuation": "خطأ في التعبير: علامة ترقيم غير متعرف عليها \"$1\"",
"pfunc_expr_unclosed_bracket": "خطأ في التعبير: قوس غير مغلق",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/bg.json b/www/wiki/extensions/ParserFunctions/i18n/bg.json
index bbe543dd..4c24ee99 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/bg.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/bg.json
@@ -9,11 +9,11 @@
"pfunc_desc": "Подобряване на парсера с логически функции",
"pfunc_time_error": "Грешка: невалидно време",
"pfunc_time_too_long": "Грешка: Твърде много извиквания на #time",
- "pfunc_rel2abs_invalid_depth": "Грешка: Невалидна дълбочина в път: \"$1\" (опит за достъп на възел над корена)",
+ "pfunc_rel2abs_invalid_depth": "Грешка: Невалидна дълбочина в път: „$1“ (опит за достъп на възел над корена)",
"pfunc_expr_stack_exhausted": "Грешка в израза: Стекът е изчерпан.",
"pfunc_expr_unexpected_number": "Грешка в записа: Неочаквано число",
"pfunc_expr_preg_match_failure": "Грешка в израза: Неочакван проблем с preg_match.",
- "pfunc_expr_unrecognised_word": "Грешка в записа: Неразпозната дума \"$1\"",
+ "pfunc_expr_unrecognised_word": "Грешка в записа: Неразпозната дума „$1“.",
"pfunc_expr_unexpected_operator": "Грешка в израза: Неочакван оператор $1.",
"pfunc_expr_missing_operand": "Грешка в записа: Липсващ операнд в $1",
"pfunc_expr_unexpected_closing_bracket": "Грешка в израза: Една затваряща скоба в повече.",
@@ -24,5 +24,5 @@
"pfunc_expr_invalid_argument_ln": "Невалиден аргумент за ln: <= 0",
"pfunc_expr_unknown_error": "Грешка в израза: Неразпозната грешка ($1).",
"pfunc_expr_not_a_number": "В $1: резултатът не е число",
- "pfunc_string_too_long": "Грешка: Низът превишава лимита от $1 знака"
+ "pfunc_string_too_long": "Грешка: Низът превишава ограничението от $1 знака"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/bho.json b/www/wiki/extensions/ParserFunctions/i18n/bho.json
index 6eef5deb..408d03f7 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/bho.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/bho.json
@@ -8,5 +8,6 @@
"pfunc_expr_unrecognised_word": "एक्सप्रेशन खराबी: नामालूम शब्द \"$1\"।",
"pfunc_expr_unexpected_operator": "एक्सप्रेशन खराबी: $1 आपरेटर जेकर उमेद ना रहल।",
"pfunc_expr_missing_operand": "एक्सप्रेशन खराबी: $1 खातिर गायब क्रिया-चीन्हा (Operand)!",
- "pfunc_expr_unrecognised_punctuation": "एक्सप्रेशन खराबी: नामालूम चीन्हा \"$1\"।"
+ "pfunc_expr_unrecognised_punctuation": "एक्सप्रेशन खराबी: नामालूम चीन्हा \"$1\"।",
+ "pfunc_expr_division_by_zero": "जीरो से भाग."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/ckb.json b/www/wiki/extensions/ParserFunctions/i18n/ckb.json
index d60b19bd..2f5a4006 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/ckb.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/ckb.json
@@ -3,7 +3,8 @@
"authors": [
"Asoxor",
"Lost Whispers",
- "Muhammed taha"
+ "Muhammed taha",
+ "Épine"
]
},
"pfunc_time_error": "ھەڵە: کات نادروستە.",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/cv.json b/www/wiki/extensions/ParserFunctions/i18n/cv.json
new file mode 100644
index 00000000..ed5e4147
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/cv.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chavash"
+ ]
+ },
+ "pfunc_expr_unrecognised_word": "Ҫырнинчи йӑнӑш: Палласа илеймен сӑмах: \"$1\"",
+ "pfunc_expr_unrecognised_punctuation": "Ҫырнинчи йӑнӑш: Палласа илеймен паллӑ: $1"
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/dty.json b/www/wiki/extensions/ParserFunctions/i18n/dty.json
index 60e17777..f782aab7 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/dty.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/dty.json
@@ -2,11 +2,14 @@
"@metadata": {
"authors": [
"रमेश सिंह बोहरा",
- "जनक राज भट्ट"
+ "जनक राज भट्ट",
+ "Nirajan pant"
]
},
+ "pfunc_time_error": "त्रुटी: अमान्य समय।",
"pfunc_expr_unrecognised_word": "अभिव्यक्ति त्रुटि: अज्ञात शब्द \"$1\"।",
"pfunc_expr_unexpected_operator": "अभिव्यक्ति त्रुटि र आकस्मिक संचालन $1",
"pfunc_expr_missing_operand": "अभिव्यक्ति त्रुटि:संचालन भुलका लागि $1",
- "pfunc_expr_unrecognised_punctuation": "अभिव्यक्ति त्रुटि: नपछड्याको विराम चिन्ह चरित्र \"$1\"।"
+ "pfunc_expr_unrecognised_punctuation": "अभिव्यक्ति त्रुटि: नपछड्याको विराम चिन्ह चरित्र \"$1\"।",
+ "pfunc_expr_division_by_zero": "सुन्ना ले भाग।"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/frp.json b/www/wiki/extensions/ParserFunctions/i18n/frp.json
index b10f73d9..77f08cdc 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/frp.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/frp.json
@@ -5,7 +5,7 @@
]
},
"pfunc_desc": "Mèlyore lo parsor avouéc des fonccions logiques.",
- "pfunc_time_error": "Èrror : temps envalido",
+ "pfunc_time_error": "Fôta : temps pas justo",
"pfunc_time_too_long": "Èrror : trop grant nombro d’apèls a #time",
"pfunc_rel2abs_invalid_depth": "Èrror : provondior envalida dens lo chemin « $1 » (at tâchiê d’arrevar a un nivél en-dessus du nuod racena)",
"pfunc_expr_stack_exhausted": "Èrror d’èxprèssion : pila èpouesiê",
@@ -17,7 +17,7 @@
"pfunc_expr_unexpected_closing_bracket": "Èrror d’èxprèssion : parentèsa cllosenta emprèvua",
"pfunc_expr_unrecognised_punctuation": "Fôta d’èxprèssion : caractèro de ponctuacion « $1 » pas recognu.",
"pfunc_expr_unclosed_bracket": "Èrror d’èxprèssion : parentèsa pas cllôsa",
- "pfunc_expr_division_by_zero": "Division per zérô",
+ "pfunc_expr_division_by_zero": "Division per zérô.",
"pfunc_expr_invalid_argument": "Argument fôx por « $1 » : < -1 ou ben > 1",
"pfunc_expr_invalid_argument_ln": "Argument fôx por « ln » : ≤ 0",
"pfunc_expr_unknown_error": "Èrror d’èxprèssion : èrror encognua ($1)",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/gcr.json b/www/wiki/extensions/ParserFunctions/i18n/gcr.json
new file mode 100644
index 00000000..e8c845a0
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/gcr.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "LeGuyanaisPure"
+ ]
+ },
+ "pfunc_time_error": "Éròr : douré envalid.",
+ "pfunc_expr_unrecognised_word": "Éròr d’èksprésyon : mo « $1 » pa roukonèt.",
+ "pfunc_expr_unexpected_operator": "Éròr d’èksprésyon : opératò '''$1''' inatandou.",
+ "pfunc_expr_missing_operand": "Éròr d’èksprésyon : opérand mankan pou '''$1'''.",
+ "pfunc_expr_unrecognised_punctuation": "Éròr d’èksprésyon : karaktèr di ponktchwasyon « $1 » pa roukonèt.",
+ "pfunc_expr_division_by_zero": "Divizyon pa zéro."
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/hy.json b/www/wiki/extensions/ParserFunctions/i18n/hy.json
index 8b95ed60..5c0a2406 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/hy.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/hy.json
@@ -4,8 +4,10 @@
"Դավիթ Սարոյան"
]
},
+ "pfunc_time_error": "Սխալ՝ անվավեր ժամանակ",
"pfunc_expr_unrecognised_word": "Արտահայտության սխալ․ չճանաչված բառ՝ «$1»։",
"pfunc_expr_unexpected_operator": "Արտահայտության սխալ․ $1 անսպասելի օպերատոր։",
"pfunc_expr_missing_operand": "Արտահայտության սխալ․ $1-ը չունի օպերանդ։",
- "pfunc_expr_unrecognised_punctuation": "Արտահայտության սխալ․ չճանաչված կետադրական նշան՝ «$1»։"
+ "pfunc_expr_unrecognised_punctuation": "Արտահայտության սխալ․ չճանաչված կետադրական նշան՝ «$1»։",
+ "pfunc_expr_division_by_zero": "Զրոյի վրա բաժանում"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/hyw.json b/www/wiki/extensions/ParserFunctions/i18n/hyw.json
new file mode 100644
index 00000000..b8812ab2
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/hyw.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "ArmenBakkalian"
+ ]
+ },
+ "pfunc_expr_unrecognised_word": "Արտայայտութեան սխալ․ չճանչցուած բառ՝ «$1»։",
+ "pfunc_expr_unrecognised_punctuation": "Արտայայտութեան սխալ․ չճանչցուած կէտադրական նշան՝ «$1»։"
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/inh.json b/www/wiki/extensions/ParserFunctions/i18n/inh.json
index 5bb151d1..982c851a 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/inh.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/inh.json
@@ -8,5 +8,6 @@
"pfunc_expr_unrecognised_word": "Дешáш белгалдаккхара гӀалат: довзанза дола дош «$1»",
"pfunc_expr_unexpected_operator": "Дешаш белгалдаккхара гIалат: цIаьхха хинна оператор $1",
"pfunc_expr_missing_operand": "Дешáш белгалдаккхара гӀалат: «$1» операнд тоъаш яц",
- "pfunc_expr_unrecognised_punctuation": "Дешáш белгалдаккхара гӀалат: йовзанза йола пунктуацен хьарак «$1»"
+ "pfunc_expr_unrecognised_punctuation": "Дешáш белгалдаккхара гӀалат: йовзанза йола пунктуацен хьарак «$1»",
+ "pfunc_expr_division_by_zero": "КIолханна декъар"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/io.json b/www/wiki/extensions/ParserFunctions/i18n/io.json
index bf669613..ca163ea2 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/io.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/io.json
@@ -7,5 +7,8 @@
},
"pfunc_time_error": "Eroro: ne-valida tempo",
"pfunc_expr_unrecognised_word": "Skriptal eroro: vorto \"$1\" nekonocita.",
+ "pfunc_expr_unexpected_operator": "Eroro en la frazo: Neexpektata $1 operacero.",
+ "pfunc_expr_missing_operand": "Eroro en la frazo: Mankas operando por $1.",
+ "pfunc_expr_unrecognised_punctuation": "Frazala eroro: Nekonocita puntizosigno “$1”.",
"pfunc_expr_division_by_zero": "Divido per zero"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/jv.json b/www/wiki/extensions/ParserFunctions/i18n/jv.json
index cd8b04bd..e3079030 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/jv.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/jv.json
@@ -6,7 +6,7 @@
]
},
"pfunc_desc": "Kembangna parser mawa fungsi logis",
- "pfunc_time_error": "Kaluputan: wektu ora absah",
+ "pfunc_time_error": "Masalah: wektu ora absah",
"pfunc_time_too_long": "Kaluputan: Olèhé nyeluk #time kakèhan",
"pfunc_rel2abs_invalid_depth": "Kaluputan: Kajeroané path ora absah: \"$1\" (nyoba ngakses simpul sadhuwuring simpul oyot)",
"pfunc_expr_stack_exhausted": "Kaluputan èksprèsi: Stack entèk",
@@ -18,7 +18,7 @@
"pfunc_expr_unexpected_closing_bracket": "Kaluputan èksprèsi: Kurung tutup ora kaduga",
"pfunc_expr_unrecognised_punctuation": "Masalah pitembungan: Karakter tandha waca \"$1\" ora dingertèni.",
"pfunc_expr_unclosed_bracket": "Kaluputan èksprèsi: Kurung tanpa tutup",
- "pfunc_expr_division_by_zero": "Dipara karo das (nol)",
+ "pfunc_expr_division_by_zero": "Dipara nul.",
"pfunc_expr_invalid_argument": "Argumèn ora absah kanggo $1: < -1 utawa > 1",
"pfunc_expr_invalid_argument_ln": "Argumèn ora absah kanggo ln: <= 0",
"pfunc_expr_unknown_error": "Kaluputan èksprèsi: Kaluputan ora ditepungi ($1)",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/km.json b/www/wiki/extensions/ParserFunctions/i18n/km.json
index ac23744c..789be6c9 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/km.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/km.json
@@ -7,6 +7,6 @@
]
},
"pfunc_time_error": "កំហុស៖ ពេលវេលាមិនត្រឹមត្រូវ",
- "pfunc_expr_division_by_zero": "ចែកនឹងសូន្យ",
+ "pfunc_expr_division_by_zero": "ចែកនឹងសូន្យ។",
"pfunc_expr_not_a_number": "ក្នុង $1: លទ្ធផល​មិន​មែន​ជា​លេខ​ទេ"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/krl.json b/www/wiki/extensions/ParserFunctions/i18n/krl.json
index 56ff05f2..8f1679f5 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/krl.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/krl.json
@@ -1,11 +1,14 @@
{
"@metadata": {
"authors": [
- "Varvana"
+ "Varvana",
+ "Ilja.mos"
]
},
+ "pfunc_time_error": "Hirhe: viärä aika.",
"pfunc_expr_unrecognised_word": "Hairahuš: tuntomatoin šana \"$1\"",
"pfunc_expr_unexpected_operator": "Hairahuš: Vuottamatoin operattori $1.",
"pfunc_expr_missing_operand": "Hairahuš: operattorilla $1 ei ole operandie.",
- "pfunc_expr_unrecognised_punctuation": "Hairahuš: tuntomatoin välimerkki \"$1\"."
+ "pfunc_expr_unrecognised_punctuation": "Hairahuš: tuntomatoin välimerkki \"$1\".",
+ "pfunc_expr_division_by_zero": "Virhe: jako nollalla"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/kum.json b/www/wiki/extensions/ParserFunctions/i18n/kum.json
new file mode 100644
index 00000000..ba884d0a
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/kum.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Arsenekoumyk",
+ "ArslanX"
+ ]
+ },
+ "pfunc_time_error": "Хата: терс заман",
+ "pfunc_expr_unrecognised_word": "Жумла хата: белгисиз сёз \"$1\".‎",
+ "pfunc_expr_unexpected_operator": "Жумла янгылыш:гёзленмейген оператор $1.",
+ "pfunc_expr_missing_operand": "Жумла янгылышы: $1 операнд етишмей",
+ "pfunc_expr_unrecognised_punctuation": "Жумла хата: белгисиз бюртюклев ишара \"$1\".‎",
+ "pfunc_expr_division_by_zero": "Сыфыргъа бёлюв"
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/lb.json b/www/wiki/extensions/ParserFunctions/i18n/lb.json
index db945116..4b6f2824 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/lb.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/lb.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Robby",
- "Soued031"
+ "Soued031",
+ "Les Meloures"
]
},
"pfunc_desc": "Erweidert Parser mat logesche Funktiounen",
@@ -13,8 +14,8 @@
"pfunc_expr_stack_exhausted": "Expressiouns-Feeler: Stack iwwergelaf",
"pfunc_expr_unexpected_number": "Expressiouns-Feeler: Onerwarten Zuel",
"pfunc_expr_unrecognised_word": "Expressiouns-Feeler: Onerkantent Wuert \"$1\"",
- "pfunc_expr_unexpected_operator": "Expression-Feeler: Onerwarten Operateur: $1",
- "pfunc_expr_missing_operand": "Expression-Feeler: Et feelt en Operand fir $1",
+ "pfunc_expr_unexpected_operator": "Expressiounsfeeler: Onerwarten Operateur: $1",
+ "pfunc_expr_missing_operand": "Expressiounsfeeler: Et feelt en Operand fir $1",
"pfunc_expr_unexpected_closing_bracket": "Expressiouns-Feeler: Onerwarte Klammer déi zougemaach gëtt",
"pfunc_expr_unrecognised_punctuation": "Expressiouns-Feeler: D'Sazzeechen \"$1\" gouf net erkannt",
"pfunc_expr_unclosed_bracket": "Expressiouns-Feeler: Eckeg Klammer net zougemaach",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/lv.json b/www/wiki/extensions/ParserFunctions/i18n/lv.json
index 1f84dff5..0fa2240a 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/lv.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/lv.json
@@ -6,6 +6,9 @@
},
"pfunc_time_error": "Kļūda: nederīgs laiks",
"pfunc_time_too_long": "Kļūda: pārāk daudz #time izsaukumu",
+ "pfunc_expr_unrecognised_word": "Izteiksmes kļūda: Neatpazīts vārds \"$1\".",
+ "pfunc_expr_unexpected_operator": "Izteiksmes kļūda: Negaidīts $1 operators.",
"pfunc_expr_missing_operand": "Izteiksmes kļūda: trūkst $1 operands.",
+ "pfunc_expr_unrecognised_punctuation": "Izteiksmes kļūda: Neatpazīta pieturzīme \"$1\".",
"pfunc_expr_division_by_zero": "Dalīšana ar nulli"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/mui.json b/www/wiki/extensions/ParserFunctions/i18n/mui.json
new file mode 100644
index 00000000..0503a3ff
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/mui.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jawadywn"
+ ]
+ },
+ "pfunc_expr_unrecognised_word": "Salah jingok: Kato \"$1\" dak ketemu.",
+ "pfunc_expr_unrecognised_punctuation": "Salah jingok: Karakter tando baco \"$1\" dak ketemu."
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/mwl.json b/www/wiki/extensions/ParserFunctions/i18n/mwl.json
index 584ccf80..ddb6acb4 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/mwl.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/mwl.json
@@ -1,9 +1,14 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
+ "pfunc_time_error": "Erro: Tiempo ambálido.",
"pfunc_expr_unrecognised_word": "Erro de spresson: Palabra \"$1\" nun recoincida.",
- "pfunc_expr_unrecognised_punctuation": "Erro de spresson: Carátele de pontuaçon \"$1\" nun recoincido."
+ "pfunc_expr_unexpected_operator": "Erro de spresson: Ouparador $1 inasperado",
+ "pfunc_expr_missing_operand": "Erro de spresson: Falta un ouparador pa $1.",
+ "pfunc_expr_unrecognised_punctuation": "Erro de spresson: Carátele de pontuaçon \"$1\" nun recoincido.",
+ "pfunc_expr_division_by_zero": "Debison por zero."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/myv.json b/www/wiki/extensions/ParserFunctions/i18n/myv.json
index ecfe4cfe..f1bc77c2 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/myv.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/myv.json
@@ -1,10 +1,12 @@
{
"@metadata": {
"authors": [
- "Botuzhaleny-sodamo"
+ "Botuzhaleny-sodamo",
+ "Rueter"
]
},
"pfunc_time_error": "Ильведевксэсь: амаштовикс шкась",
"pfunc_expr_stack_exhausted": "Ёвтавкссонть ильведевкс: стекесь тыц пешксе",
+ "pfunc_expr_unrecognised_word": "Ёвтамонь ильведевкс:«$1» — асодавикс вал.",
"pfunc_expr_division_by_zero": "Нольсэ йавома"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/nan.json b/www/wiki/extensions/ParserFunctions/i18n/nan.json
index 79d7c6c8..a661a8ec 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/nan.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/nan.json
@@ -2,10 +2,11 @@
"@metadata": {
"authors": [
"Ianbu",
- "Luuva"
+ "Luuva",
+ "Yoxem"
]
},
- "pfunc_expr_unrecognised_word": "表達錯誤:認無\"$1\"這个字。",
+ "pfunc_expr_unrecognised_word": "Piáu-ta̍t chhò-ngō͘: Jīn-bô \"$1\" chit ê jī.",
"pfunc_expr_missing_operand": "Piáu-tat chha-chhok: Phàng-kiàn $1 ê pī-sǹg-sò͘.",
- "pfunc_expr_unrecognised_punctuation": "表達錯誤:認無標點符號 \"$1\"。"
+ "pfunc_expr_unrecognised_punctuation": "Piáu-ta̍t chhò-ngō͘: jīn-bô piau-tiám hû-hō \"$1\"."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/nys.json b/www/wiki/extensions/ParserFunctions/i18n/nys.json
new file mode 100644
index 00000000..06b61bb2
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/nys.json
@@ -0,0 +1,13 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gnangarra"
+ ]
+ },
+ "pfunc_time_error": "Error: Yuwart time.",
+ "pfunc_expr_unrecognised_word": "Expression error: Unrecognized word \"$1\".",
+ "pfunc_expr_unexpected_operator": "Expression error: Unexpected $1 operator.",
+ "pfunc_expr_missing_operand": "Expression error: Missing operand for $1.",
+ "pfunc_expr_unrecognised_punctuation": "Expression error: Baliak natj punctuation character \"$1\".",
+ "pfunc_expr_division_by_zero": "Division by zero."
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/pa.json b/www/wiki/extensions/ParserFunctions/i18n/pa.json
index 7fffd08b..ce8f1805 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/pa.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/pa.json
@@ -1,11 +1,14 @@
{
"@metadata": {
"authors": [
- "Satdeep gill"
+ "Satdeep gill",
+ "Tow"
]
},
+ "pfunc_time_error": "ਗਲਤੀ: ਗਲਤ ਸਮਾਂ",
"pfunc_expr_unrecognised_word": "ਗ਼ਲਤੀ:ਅਣਪਛਾਤਾ ਸ਼ਬਦ \"$1\"।",
"pfunc_expr_unexpected_operator": "ਗ਼ਲਤੀ: ਅਕਲਪਿਤ $1 ਚਾਲਕ।",
"pfunc_expr_missing_operand": "ਗ਼ਲਤੀ: $1 ਲਈ ਕਾਰਜ ਸੰਖਿਆ ਮੌਜੂਦ ਨਹੀਂ।",
- "pfunc_expr_unrecognised_punctuation": "ਗ਼ਲਤੀ:ਅਣਪਛਾਤਾ ਚਿੰਨ੍ਹ \"$1\"।"
+ "pfunc_expr_unrecognised_punctuation": "ਗ਼ਲਤੀ:ਅਣਪਛਾਤਾ ਚਿੰਨ੍ਹ \"$1\"।",
+ "pfunc_expr_division_by_zero": "ਸਿਫਰ ਨਾਲ ਵਿਭਾਜਨ।"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/ps.json b/www/wiki/extensions/ParserFunctions/i18n/ps.json
index 8a79666a..c0323cac 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/ps.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/ps.json
@@ -2,11 +2,12 @@
"@metadata": {
"authors": [
"Ahmed-Najib-Biabani-Ibrahimkhel",
- "عثمان خان شاہ"
+ "عثمان خان شاہ",
+ "Baloch Khan"
]
},
"pfunc_time_error": "ستونزه: ناسم وخت",
- "pfunc_expr_unrecognised_word": "اصطلاحي تېروتنه: ناپېژندل شوې وييکه \"$1\".",
+ "pfunc_expr_unrecognised_word": "اصطلاحي تېروتنه: ناپېژندل شوې ټکي \"$1\".",
"pfunc_expr_unexpected_operator": "اصطلاحي تېروتنه: نااټکله $1 چارنگر.",
"pfunc_expr_missing_operand": "اصطلاحي تېروتنه: د $1 ورک شوی چارنگر.",
"pfunc_expr_unrecognised_punctuation": "اصطلاحي تېروتنه: د ناپېژندلې ليکنښې لوښه \"$1\".",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/ro.json b/www/wiki/extensions/ParserFunctions/i18n/ro.json
index 8ee0271d..9b1670ed 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/ro.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/ro.json
@@ -4,13 +4,15 @@
"KlaudiuMihaila",
"Minisarm",
"Stelistcristi",
- "ImGelu"
+ "ImGelu",
+ "Strainu"
]
},
"pfunc_desc": "Îmbunătățește parserul cu funcții logice",
"pfunc_time_error": "Eroare: timp incorect",
"pfunc_time_too_long": "Eroare: prea multe apeluri #time",
"pfunc_time_too_big": "Eroare: #time acceptă doar ani până la 9999",
+ "pfunc_time_too_small": "Eroare: #time acceptă doar ani de la 0.",
"pfunc_rel2abs_invalid_depth": "Eroare: adâncime incorectă în cale: „$1” (încercat accesarea unui nod deasupra nodului rădăcină)",
"pfunc_expr_stack_exhausted": "Eroare de expresie: stivă epuizată",
"pfunc_expr_unexpected_number": "Eroare de expresie: număr neașteptat",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/sat.json b/www/wiki/extensions/ParserFunctions/i18n/sat.json
new file mode 100644
index 00000000..9c3f1646
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/sat.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Manik Soren",
+ "Ramjit Tudu"
+ ]
+ },
+ "pfunc_time_error": "ᱦᱩᱲᱟᱹᱜ : ᱚᱢᱟᱱᱚᱛ ᱚᱠᱛᱚ ᱾",
+ "pfunc_expr_unrecognised_word": "Expression error: ᱵᱟᱝ ᱧᱮᱞ ᱴᱷᱤᱠᱚᱜᱠᱟᱱ ᱟᱹᱲᱟᱹ \"$1\".",
+ "pfunc_expr_unexpected_operator": "ᱞᱟᱹᱭᱟᱜ ᱦᱩᱲᱟᱹᱜ : ᱵᱟᱝᱩᱭᱦᱟᱹᱨ $1 ᱠᱟᱹᱢᱤᱭᱟᱹ ᱾",
+ "pfunc_expr_missing_operand": "ᱞᱟᱹᱭᱟᱜ ᱦᱩᱲᱟᱹᱜ: $1 ᱞᱟᱹᱜᱤᱫ ᱠᱟᱹᱢᱤ ᱦᱚᱨᱟ ᱯᱩᱪᱩᱡ ᱟᱠᱟᱱᱟ ᱾",
+ "pfunc_expr_unrecognised_punctuation": "Expression error: ᱵᱟᱝ ᱧᱮᱞ ᱴᱷᱤᱠᱚᱜᱠᱟᱱ ᱪᱤᱱᱦᱟᱹ ᱠᱚ \"$1\".",
+ "pfunc_expr_division_by_zero": "ᱥᱩᱱ ᱛᱮ ᱵᱷᱮᱜᱮᱫ"
+}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/sco.json b/www/wiki/extensions/ParserFunctions/i18n/sco.json
index f619b55b..6d6c203e 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/sco.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/sco.json
@@ -4,8 +4,10 @@
"AmaryllisGardener"
]
},
+ "pfunc_time_error": "Error: Invalid time.",
"pfunc_expr_unrecognised_word": "Expression error: Unrecognised wird \"$1\".",
"pfunc_expr_unexpected_operator": "Expression error: Unexpectit $1 operator.",
"pfunc_expr_missing_operand": "Expression error: Missin operand for $1.",
- "pfunc_expr_unrecognised_punctuation": "Expression error: Unrecognised punctuation character \"$1\"."
+ "pfunc_expr_unrecognised_punctuation": "Expression error: Unrecognised punctuation character \"$1\".",
+ "pfunc_expr_division_by_zero": "Diveesion bi zero."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/sd.json b/www/wiki/extensions/ParserFunctions/i18n/sd.json
index bb0c9f15..0c0ce227 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/sd.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/sd.json
@@ -5,8 +5,10 @@
"Mehtab ahmed"
]
},
+ "pfunc_time_error": "چُڪَ:ناقابلِڪار وقت.",
"pfunc_expr_unrecognised_word": "اظھاري چُڪَ: اڻڄاتل لفظ $1.",
"pfunc_expr_unexpected_operator": "اظھاري چُڪَ: غير متوقع $1 عامل.",
"pfunc_expr_missing_operand": "اظھاري چُڪَ: $1 لاءِ معامل انگ کٽل.",
- "pfunc_expr_unrecognised_punctuation": "اظھاري چُڪَ: اڻڄاتل وقفي نشاني \"$1\"."
+ "pfunc_expr_unrecognised_punctuation": "اظھاري چُڪَ: اڻڄاتل وقفي نشاني \"$1\".",
+ "pfunc_expr_division_by_zero": "ٻريءَ سان ونڊ."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/sty.json b/www/wiki/extensions/ParserFunctions/i18n/sty.json
index f2c0abb7..264cc3f8 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/sty.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/sty.json
@@ -4,8 +4,10 @@
"Khanmarat"
]
},
+ "pfunc_time_error": "Ҡата: уаҡыт төрөс түгел.",
"pfunc_expr_unrecognised_word": "Аңнатма ҡата: танылмаған \"$1\" сүс",
"pfunc_expr_unexpected_operator": "Аңнатма ҡата: Көтөлмәгән $1 операторы",
"pfunc_expr_missing_operand": "Аңнатма ҡата: $1 операнд йетмәйте.",
- "pfunc_expr_unrecognised_punctuation": "Аңнатма ҡата: танылмаған \"$1\" пунктуация тамғасы"
+ "pfunc_expr_unrecognised_punctuation": "Аңнатма ҡата: танылмаған \"$1\" пунктуация тамғасы",
+ "pfunc_expr_division_by_zero": "Нольға пүлеү"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/sv.json b/www/wiki/extensions/ParserFunctions/i18n/sv.json
index 46d445ef..b9d32d55 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/sv.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/sv.json
@@ -6,7 +6,8 @@
"Lokal Profil",
"M.M.S.",
"Najami",
- "WikiPhoenix"
+ "WikiPhoenix",
+ "Skalman"
]
},
"pfunc_desc": "Lägger till logiska funktioner i parsern",
@@ -18,11 +19,11 @@
"pfunc_expr_stack_exhausted": "Fel i uttryck: Stackutrymmet tog slut",
"pfunc_expr_unexpected_number": "Fel i uttryck: Oväntat tal",
"pfunc_expr_preg_match_failure": "Fel i uttryck: Oväntad fel i preg_match",
- "pfunc_expr_unrecognised_word": "Fel i uttryck: Okänt ord \"$1\"",
- "pfunc_expr_unexpected_operator": "Fel i uttryck: Oväntad operator $1",
- "pfunc_expr_missing_operand": "Fel i uttryck: Operand saknas för $1",
+ "pfunc_expr_unrecognised_word": "Fel i uttryck: Okänt ord \"$1\".",
+ "pfunc_expr_unexpected_operator": "Fel i uttryck: Oväntad operator $1.",
+ "pfunc_expr_missing_operand": "Fel i uttryck: Operand saknas för $1.",
"pfunc_expr_unexpected_closing_bracket": "Fel i uttryck: Oväntad avslutande parentes",
- "pfunc_expr_unrecognised_punctuation": "Fel i uttryck: Okänt interpunktionstecken \"$1\"",
+ "pfunc_expr_unrecognised_punctuation": "Fel i uttryck: Okänt skiljetecken \"$1\"",
"pfunc_expr_unclosed_bracket": "Fel i uttryck: Oavslutad parentes",
"pfunc_expr_division_by_zero": "Division med noll",
"pfunc_expr_invalid_argument": "Ogiltigt argument för $1: < -1 eller > 1",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/tay.json b/www/wiki/extensions/ParserFunctions/i18n/tay.json
index dec265de..21dab9e0 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/tay.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/tay.json
@@ -6,8 +6,10 @@
"Translatealcd"
]
},
+ "pfunc_time_error": "Min’uqu’: ungat zyuwaw zikang.",
"pfunc_expr_unrecognised_word": "min’uqu’ bniru’ su’: ungat qqbaq mita’ biru’ tay \"$1\"",
"pfunc_expr_unexpected_operator": "Min’uqu’ pinkaykita’ su’:Iyat sinpngan sa sawn naha Yuswanc’ $1",
"pfunc_expr_missing_operand": "Min’uqu’ quw sinbbaq kay’ su’:wal su’ zhuqan biru’ sa bbiru’ na pplpgan tay $1",
- "pfunc_expr_unrecognised_punctuation": "Min’uqu’ quw bniru’ su’: ini’ baqiy mita’ quw bniru’ na sinbbaq su’ \"$1\"."
+ "pfunc_expr_unrecognised_punctuation": "Min’uqu’ quw bniru’ su’: ini’ baqiy mita’ quw bniru’ na sinbbaq su’ \"$1\".",
+ "pfunc_expr_division_by_zero": "Ungat quw pinqsugan na pinqsugan."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/udm.json b/www/wiki/extensions/ParserFunctions/i18n/udm.json
index b4b1308c..fb0ecc28 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/udm.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/udm.json
@@ -1,9 +1,11 @@
{
"@metadata": {
"authors": [
- "Wadorgurt"
+ "Wadorgurt",
+ "Patrick Star"
]
},
+ "pfunc_time_error": "Янгышъёс: недопустимый дыр.",
"pfunc_expr_unrecognised_word": "Выражениын янгыш: тодмамтэ кыл «$1».",
"pfunc_expr_unexpected_operator": "Выражениын янгыш: возьмамтэ $1 оператор.",
"pfunc_expr_missing_operand": "Выражениын янгыш: $1 операнд уг тырмы.",
diff --git a/www/wiki/extensions/ParserFunctions/i18n/war.json b/www/wiki/extensions/ParserFunctions/i18n/war.json
index d3ed0416..ae8c36b9 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/war.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/war.json
@@ -1,12 +1,14 @@
{
"@metadata": {
"authors": [
- "JinJian"
+ "JinJian",
+ "Harvzsf"
]
},
"pfunc_time_error": "Sayop: Diri puydi an oras.",
"pfunc_expr_unrecognised_word": "Sayop nga expression:Diri nakikilal-an an pulong nga \"$1\".",
"pfunc_expr_unexpected_operator": "Sayop nga expression: Unexpected $1 operator.",
"pfunc_expr_missing_operand": "Expression error: Nawawara nga operand para han $1.",
- "pfunc_expr_unrecognised_punctuation": "Sayop nga expression\": Waray nakilal-an nga punctuation character \"$1\"."
+ "pfunc_expr_unrecognised_punctuation": "Sayop nga expression\": Waray nakilal-an nga punctuation character \"$1\".",
+ "pfunc_expr_division_by_zero": "Pagbahinbahin hin zero."
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/wuu.json b/www/wiki/extensions/ParserFunctions/i18n/wuu.json
index f15196e0..d9a1bb50 100644
--- a/www/wiki/extensions/ParserFunctions/i18n/wuu.json
+++ b/www/wiki/extensions/ParserFunctions/i18n/wuu.json
@@ -1,11 +1,14 @@
{
"@metadata": {
"authors": [
- "Poiuyt"
+ "Poiuyt",
+ "飞舞回堂前"
]
},
+ "pfunc_time_error": "出错:无效个辰光。",
"pfunc_expr_unrecognised_word": "表达式出错:弗能识别个词“$1”",
"pfunc_expr_unexpected_operator": "表达式出错:朆预料着个$1操作符",
"pfunc_expr_missing_operand": "表达式出错:缺少$1个操作数",
- "pfunc_expr_unrecognised_punctuation": "表达式出错:弗能识别个标点“$1”"
+ "pfunc_expr_unrecognised_punctuation": "表达式出错:弗能识别个标点“$1”",
+ "pfunc_expr_division_by_zero": "畀零除。"
}
diff --git a/www/wiki/extensions/ParserFunctions/i18n/zgh.json b/www/wiki/extensions/ParserFunctions/i18n/zgh.json
new file mode 100644
index 00000000..1f53e789
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/i18n/zgh.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mdb897"
+ ]
+ },
+ "pfunc_expr_unrecognised_word": "ⵜⴰⵣⴳⵍⵜ ⴳ ⵜⴰⵡⵏⵏⵉⵜ: ⵜⴰⴳⵓⵔⵢ \"$1\" ⵓⵔ ⵜⵢⴰⴽⴰⵣ.",
+ "pfunc_expr_unrecognised_punctuation": "ⵜⴰⵣⴳⵍⵜ ⴳ ⵜⴰⵡⵏⵏⵉⵜ: ⵜⴰⵎⴰⵜⴰⵔⵜ ⵏ ⵓⵙⵏⵇⴹ \"$1\" ⵓⵔ ⵜⵢⴰⴽⴰⵣ."
+}
diff --git a/www/wiki/extensions/ParserFunctions/includes/ExprError.php b/www/wiki/extensions/ParserFunctions/includes/ExprError.php
new file mode 100644
index 00000000..bb2032a9
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/includes/ExprError.php
@@ -0,0 +1,33 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ */
+
+class ExprError extends Exception {
+ /**
+ * @param string $msg
+ * @param string $parameter
+ */
+ public function __construct( $msg, $parameter = '' ) {
+ // Give grep a chance to find the usages:
+ // pfunc_expr_stack_exhausted, pfunc_expr_unexpected_number, pfunc_expr_preg_match_failure,
+ // pfunc_expr_unrecognised_word, pfunc_expr_unexpected_operator, pfunc_expr_missing_operand,
+ // pfunc_expr_unexpected_closing_bracket, pfunc_expr_unrecognised_punctuation,
+ // pfunc_expr_unclosed_bracket, pfunc_expr_division_by_zero, pfunc_expr_invalid_argument,
+ // pfunc_expr_invalid_argument_ln, pfunc_expr_unknown_error, pfunc_expr_not_a_number
+ $this->message = wfMessage( "pfunc_expr_$msg", $parameter )->inContentLanguage()->text();
+ }
+}
diff --git a/www/wiki/extensions/ParserFunctions/includes/ExprParser.php b/www/wiki/extensions/ParserFunctions/includes/ExprParser.php
new file mode 100644
index 00000000..f6a80432
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/includes/ExprParser.php
@@ -0,0 +1,673 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ */
+
+use UtfNormal\Validator;
+
+// Character classes
+define( 'EXPR_WHITE_CLASS', " \t\r\n" );
+define( 'EXPR_NUMBER_CLASS', '0123456789.' );
+
+// Token types
+define( 'EXPR_WHITE', 1 );
+define( 'EXPR_NUMBER', 2 );
+define( 'EXPR_NEGATIVE', 3 );
+define( 'EXPR_POSITIVE', 4 );
+define( 'EXPR_PLUS', 5 );
+define( 'EXPR_MINUS', 6 );
+define( 'EXPR_TIMES', 7 );
+define( 'EXPR_DIVIDE', 8 );
+define( 'EXPR_MOD', 9 );
+define( 'EXPR_OPEN', 10 );
+define( 'EXPR_CLOSE', 11 );
+define( 'EXPR_AND', 12 );
+define( 'EXPR_OR', 13 );
+define( 'EXPR_NOT', 14 );
+define( 'EXPR_EQUALITY', 15 );
+define( 'EXPR_LESS', 16 );
+define( 'EXPR_GREATER', 17 );
+define( 'EXPR_LESSEQ', 18 );
+define( 'EXPR_GREATEREQ', 19 );
+define( 'EXPR_NOTEQ', 20 );
+define( 'EXPR_ROUND', 21 );
+define( 'EXPR_EXPONENT', 22 );
+define( 'EXPR_SINE', 23 );
+define( 'EXPR_COSINE', 24 );
+define( 'EXPR_TANGENS', 25 );
+define( 'EXPR_ARCSINE', 26 );
+define( 'EXPR_ARCCOS', 27 );
+define( 'EXPR_ARCTAN', 28 );
+define( 'EXPR_EXP', 29 );
+define( 'EXPR_LN', 30 );
+define( 'EXPR_ABS', 31 );
+define( 'EXPR_FLOOR', 32 );
+define( 'EXPR_TRUNC', 33 );
+define( 'EXPR_CEIL', 34 );
+define( 'EXPR_POW', 35 );
+define( 'EXPR_PI', 36 );
+define( 'EXPR_FMOD', 37 );
+define( 'EXPR_SQRT', 38 );
+
+class ExprParser {
+ public $maxStackSize = 100;
+
+ public $precedence = [
+ EXPR_NEGATIVE => 10,
+ EXPR_POSITIVE => 10,
+ EXPR_EXPONENT => 10,
+ EXPR_SINE => 9,
+ EXPR_COSINE => 9,
+ EXPR_TANGENS => 9,
+ EXPR_ARCSINE => 9,
+ EXPR_ARCCOS => 9,
+ EXPR_ARCTAN => 9,
+ EXPR_EXP => 9,
+ EXPR_LN => 9,
+ EXPR_ABS => 9,
+ EXPR_FLOOR => 9,
+ EXPR_TRUNC => 9,
+ EXPR_CEIL => 9,
+ EXPR_NOT => 9,
+ EXPR_SQRT => 9,
+ EXPR_POW => 8,
+ EXPR_TIMES => 7,
+ EXPR_DIVIDE => 7,
+ EXPR_MOD => 7,
+ EXPR_FMOD => 7,
+ EXPR_PLUS => 6,
+ EXPR_MINUS => 6,
+ EXPR_ROUND => 5,
+ EXPR_EQUALITY => 4,
+ EXPR_LESS => 4,
+ EXPR_GREATER => 4,
+ EXPR_LESSEQ => 4,
+ EXPR_GREATEREQ => 4,
+ EXPR_NOTEQ => 4,
+ EXPR_AND => 3,
+ EXPR_OR => 2,
+ EXPR_PI => 0,
+ EXPR_OPEN => -1,
+ EXPR_CLOSE => -1,
+ ];
+
+ public $names = [
+ EXPR_NEGATIVE => '-',
+ EXPR_POSITIVE => '+',
+ EXPR_NOT => 'not',
+ EXPR_TIMES => '*',
+ EXPR_DIVIDE => '/',
+ EXPR_MOD => 'mod',
+ EXPR_FMOD => 'fmod',
+ EXPR_PLUS => '+',
+ EXPR_MINUS => '-',
+ EXPR_ROUND => 'round',
+ EXPR_EQUALITY => '=',
+ EXPR_LESS => '<',
+ EXPR_GREATER => '>',
+ EXPR_LESSEQ => '<=',
+ EXPR_GREATEREQ => '>=',
+ EXPR_NOTEQ => '<>',
+ EXPR_AND => 'and',
+ EXPR_OR => 'or',
+ EXPR_EXPONENT => 'e',
+ EXPR_SINE => 'sin',
+ EXPR_COSINE => 'cos',
+ EXPR_TANGENS => 'tan',
+ EXPR_ARCSINE => 'asin',
+ EXPR_ARCCOS => 'acos',
+ EXPR_ARCTAN => 'atan',
+ EXPR_LN => 'ln',
+ EXPR_EXP => 'exp',
+ EXPR_ABS => 'abs',
+ EXPR_FLOOR => 'floor',
+ EXPR_TRUNC => 'trunc',
+ EXPR_CEIL => 'ceil',
+ EXPR_POW => '^',
+ EXPR_PI => 'pi',
+ EXPR_SQRT => 'sqrt',
+ ];
+
+ public $words = [
+ 'mod' => EXPR_MOD,
+ 'fmod' => EXPR_FMOD,
+ 'and' => EXPR_AND,
+ 'or' => EXPR_OR,
+ 'not' => EXPR_NOT,
+ 'round' => EXPR_ROUND,
+ 'div' => EXPR_DIVIDE,
+ 'e' => EXPR_EXPONENT,
+ 'sin' => EXPR_SINE,
+ 'cos' => EXPR_COSINE,
+ 'tan' => EXPR_TANGENS,
+ 'asin' => EXPR_ARCSINE,
+ 'acos' => EXPR_ARCCOS,
+ 'atan' => EXPR_ARCTAN,
+ 'exp' => EXPR_EXP,
+ 'ln' => EXPR_LN,
+ 'abs' => EXPR_ABS,
+ 'trunc' => EXPR_TRUNC,
+ 'floor' => EXPR_FLOOR,
+ 'ceil' => EXPR_CEIL,
+ 'pi' => EXPR_PI,
+ 'sqrt' => EXPR_SQRT,
+ ];
+
+ /**
+ * Evaluate a mathematical expression
+ *
+ * The algorithm here is based on the infix to RPN algorithm given in
+ * http://montcs.bloomu.edu/~bobmon/Information/RPN/infix2rpn.shtml
+ * It's essentially the same as Dijkstra's shunting yard algorithm.
+ * @param string $expr
+ * @throws ExprError
+ * @return string
+ */
+ public function doExpression( $expr ) {
+ $operands = [];
+ $operators = [];
+
+ # Unescape inequality operators
+ $expr = strtr( $expr, [ '&lt;' => '<', '&gt;' => '>',
+ '&minus;' => '-', '−' => '-' ] );
+
+ $p = 0;
+ $end = strlen( $expr );
+ $expecting = 'expression';
+ $name = '';
+
+ while ( $p < $end ) {
+ if ( count( $operands ) > $this->maxStackSize || count( $operators ) > $this->maxStackSize ) {
+ throw new ExprError( 'stack_exhausted' );
+ }
+ $char = $expr[$p];
+ $char2 = substr( $expr, $p, 2 );
+
+ // Mega if-elseif-else construct
+ // Only binary operators fall through for processing at the bottom, the rest
+ // finish their processing and continue
+
+ // First the unlimited length classes
+
+ if ( false !== strpos( EXPR_WHITE_CLASS, $char ) ) {
+ // Whitespace
+ $p += strspn( $expr, EXPR_WHITE_CLASS, $p );
+ continue;
+ } elseif ( false !== strpos( EXPR_NUMBER_CLASS, $char ) ) {
+ // Number
+ if ( $expecting !== 'expression' ) {
+ throw new ExprError( 'unexpected_number' );
+ }
+
+ // Find the rest of it
+ $length = strspn( $expr, EXPR_NUMBER_CLASS, $p );
+ // Convert it to float, silently removing double decimal points
+ $operands[] = (float)substr( $expr, $p, $length );
+ $p += $length;
+ $expecting = 'operator';
+ continue;
+ } elseif ( ctype_alpha( $char ) ) {
+ // Word
+ // Find the rest of it
+ $remaining = substr( $expr, $p );
+ if ( !preg_match( '/^[A-Za-z]*/', $remaining, $matches ) ) {
+ // This should be unreachable
+ throw new ExprError( 'preg_match_failure' );
+ }
+ $word = strtolower( $matches[0] );
+ $p += strlen( $word );
+
+ // Interpret the word
+ if ( !isset( $this->words[$word] ) ) {
+ throw new ExprError( 'unrecognised_word', $word );
+ }
+ $op = $this->words[$word];
+ switch ( $op ) {
+ // constant
+ case EXPR_EXPONENT:
+ if ( $expecting !== 'expression' ) {
+ break;
+ }
+ $operands[] = exp( 1 );
+ $expecting = 'operator';
+ continue 2;
+ case EXPR_PI:
+ if ( $expecting !== 'expression' ) {
+ throw new ExprError( 'unexpected_number' );
+ }
+ $operands[] = pi();
+ $expecting = 'operator';
+ continue 2;
+ // Unary operator
+ case EXPR_NOT:
+ case EXPR_SINE:
+ case EXPR_COSINE:
+ case EXPR_TANGENS:
+ case EXPR_ARCSINE:
+ case EXPR_ARCCOS:
+ case EXPR_ARCTAN:
+ case EXPR_EXP:
+ case EXPR_LN:
+ case EXPR_ABS:
+ case EXPR_FLOOR:
+ case EXPR_TRUNC:
+ case EXPR_CEIL:
+ case EXPR_SQRT:
+ if ( $expecting !== 'expression' ) {
+ throw new ExprError( 'unexpected_operator', $word );
+ }
+ $operators[] = $op;
+ continue 2;
+ }
+ // Binary operator, fall through
+ $name = $word;
+ } elseif ( $char2 === '<=' ) {
+ $name = $char2;
+ $op = EXPR_LESSEQ;
+ $p += 2;
+ } elseif ( $char2 === '>=' ) {
+ $name = $char2;
+ $op = EXPR_GREATEREQ;
+ $p += 2;
+ } elseif ( $char2 === '<>' || $char2 === '!=' ) {
+ $name = $char2;
+ $op = EXPR_NOTEQ;
+ $p += 2;
+ } elseif ( $char === '+' ) {
+ ++$p;
+ if ( $expecting === 'expression' ) {
+ // Unary plus
+ $operators[] = EXPR_POSITIVE;
+ continue;
+ } else {
+ // Binary plus
+ $op = EXPR_PLUS;
+ }
+ } elseif ( $char === '-' ) {
+ ++$p;
+ if ( $expecting === 'expression' ) {
+ // Unary minus
+ $operators[] = EXPR_NEGATIVE;
+ continue;
+ } else {
+ // Binary minus
+ $op = EXPR_MINUS;
+ }
+ } elseif ( $char === '*' ) {
+ $name = $char;
+ $op = EXPR_TIMES;
+ ++$p;
+ } elseif ( $char === '/' ) {
+ $name = $char;
+ $op = EXPR_DIVIDE;
+ ++$p;
+ } elseif ( $char === '^' ) {
+ $name = $char;
+ $op = EXPR_POW;
+ ++$p;
+ } elseif ( $char === '(' ) {
+ if ( $expecting === 'operator' ) {
+ throw new ExprError( 'unexpected_operator', '(' );
+ }
+ $operators[] = EXPR_OPEN;
+ ++$p;
+ continue;
+ } elseif ( $char === ')' ) {
+ $lastOp = end( $operators );
+ while ( $lastOp && $lastOp != EXPR_OPEN ) {
+ $this->doOperation( $lastOp, $operands );
+ array_pop( $operators );
+ $lastOp = end( $operators );
+ }
+ if ( $lastOp ) {
+ array_pop( $operators );
+ } else {
+ throw new ExprError( 'unexpected_closing_bracket' );
+ }
+ $expecting = 'operator';
+ ++$p;
+ continue;
+ } elseif ( $char === '=' ) {
+ $name = $char;
+ $op = EXPR_EQUALITY;
+ ++$p;
+ } elseif ( $char === '<' ) {
+ $name = $char;
+ $op = EXPR_LESS;
+ ++$p;
+ } elseif ( $char === '>' ) {
+ $name = $char;
+ $op = EXPR_GREATER;
+ ++$p;
+ } else {
+ $utfExpr = Validator::cleanUp( substr( $expr, $p ) );
+ throw new ExprError( 'unrecognised_punctuation', mb_substr( $utfExpr, 0, 1 ) );
+ }
+
+ // Binary operator processing
+ if ( $expecting === 'expression' ) {
+ throw new ExprError( 'unexpected_operator', $name );
+ }
+
+ // Shunting yard magic
+ $lastOp = end( $operators );
+ while ( $lastOp && $this->precedence[$op] <= $this->precedence[$lastOp] ) {
+ $this->doOperation( $lastOp, $operands );
+ array_pop( $operators );
+ $lastOp = end( $operators );
+ }
+ $operators[] = $op;
+ $expecting = 'expression';
+ }
+
+ // Finish off the operator array
+ // @codingStandardsIgnoreStart
+ while ( $op = array_pop( $operators ) ) {
+ // @codingStandardsIgnoreEnd
+ if ( $op == EXPR_OPEN ) {
+ throw new ExprError( 'unclosed_bracket' );
+ }
+ $this->doOperation( $op, $operands );
+ }
+
+ return implode( "<br />\n", $operands );
+ }
+
+ /**
+ * @param int $op
+ * @param array &$stack
+ * @throws ExprError
+ */
+ public function doOperation( $op, &$stack ) {
+ switch ( $op ) {
+ case EXPR_NEGATIVE:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = -$arg;
+ break;
+ case EXPR_POSITIVE:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ break;
+ case EXPR_TIMES:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = $left * $right;
+ break;
+ case EXPR_DIVIDE:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ if ( !$right ) {
+ throw new ExprError( 'division_by_zero', $this->names[$op] );
+ }
+ $stack[] = $left / $right;
+ break;
+ case EXPR_MOD:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = (int)array_pop( $stack );
+ $left = (int)array_pop( $stack );
+ if ( !$right ) {
+ throw new ExprError( 'division_by_zero', $this->names[$op] );
+ }
+ $stack[] = $left % $right;
+ break;
+ case EXPR_FMOD:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = (double)array_pop( $stack );
+ $left = (double)array_pop( $stack );
+ if ( !$right ) {
+ throw new ExprError( 'division_by_zero', $this->names[$op] );
+ }
+ $stack[] = fmod( $left, $right );
+ break;
+ case EXPR_PLUS:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = $left + $right;
+ break;
+ case EXPR_MINUS:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = $left - $right;
+ break;
+ case EXPR_AND:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left && $right ) ? 1 : 0;
+ break;
+ case EXPR_OR:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left || $right ) ? 1 : 0;
+ break;
+ case EXPR_EQUALITY:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left == $right ) ? 1 : 0;
+ break;
+ case EXPR_NOT:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = ( !$arg ) ? 1 : 0;
+ break;
+ case EXPR_ROUND:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $digits = (int)array_pop( $stack );
+ $value = array_pop( $stack );
+ $stack[] = round( $value, $digits );
+ break;
+ case EXPR_LESS:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left < $right ) ? 1 : 0;
+ break;
+ case EXPR_GREATER:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left > $right ) ? 1 : 0;
+ break;
+ case EXPR_LESSEQ:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left <= $right ) ? 1 : 0;
+ break;
+ case EXPR_GREATEREQ:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left >= $right ) ? 1 : 0;
+ break;
+ case EXPR_NOTEQ:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = ( $left != $right ) ? 1 : 0;
+ break;
+ case EXPR_EXPONENT:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $stack[] = $left * pow( 10, $right );
+ break;
+ case EXPR_SINE:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = sin( $arg );
+ break;
+ case EXPR_COSINE:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = cos( $arg );
+ break;
+ case EXPR_TANGENS:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = tan( $arg );
+ break;
+ case EXPR_ARCSINE:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ if ( $arg < -1 || $arg > 1 ) {
+ throw new ExprError( 'invalid_argument', $this->names[$op] );
+ }
+ $stack[] = asin( $arg );
+ break;
+ case EXPR_ARCCOS:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ if ( $arg < -1 || $arg > 1 ) {
+ throw new ExprError( 'invalid_argument', $this->names[$op] );
+ }
+ $stack[] = acos( $arg );
+ break;
+ case EXPR_ARCTAN:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = atan( $arg );
+ break;
+ case EXPR_EXP:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = exp( $arg );
+ break;
+ case EXPR_LN:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ if ( $arg <= 0 ) {
+ throw new ExprError( 'invalid_argument_ln', $this->names[$op] );
+ }
+ $stack[] = log( $arg );
+ break;
+ case EXPR_ABS:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = abs( $arg );
+ break;
+ case EXPR_FLOOR:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = floor( $arg );
+ break;
+ case EXPR_TRUNC:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = (int)$arg;
+ break;
+ case EXPR_CEIL:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $stack[] = ceil( $arg );
+ break;
+ case EXPR_POW:
+ if ( count( $stack ) < 2 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $right = array_pop( $stack );
+ $left = array_pop( $stack );
+ $result = pow( $left, $right );
+ if ( $result === false ) {
+ throw new ExprError( 'division_by_zero', $this->names[$op] );
+ }
+ $stack[] = $result;
+ break;
+ case EXPR_SQRT:
+ if ( count( $stack ) < 1 ) {
+ throw new ExprError( 'missing_operand', $this->names[$op] );
+ }
+ $arg = array_pop( $stack );
+ $result = sqrt( $arg );
+ if ( is_nan( $result ) ) {
+ throw new ExprError( 'not_a_number', $this->names[$op] );
+ }
+ $stack[] = $result;
+ break;
+ default:
+ // Should be impossible to reach here.
+ throw new ExprError( 'unknown_error' );
+ }
+ }
+}
diff --git a/www/wiki/extensions/ParserFunctions/includes/ExtParserFunctions.php b/www/wiki/extensions/ParserFunctions/includes/ExtParserFunctions.php
new file mode 100644
index 00000000..aae37bb1
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/includes/ExtParserFunctions.php
@@ -0,0 +1,891 @@
+<?php
+
+class ExtParserFunctions {
+ public static $mExprParser;
+ public static $mTimeCache = [];
+ public static $mTimeChars = 0;
+ public static $mMaxTimeChars = 6000; # ~10 seconds
+
+ /**
+ * @param Parser $parser
+ * @return bool
+ */
+ public static function clearState( $parser ) {
+ self::$mTimeChars = 0;
+ return true;
+ }
+
+ /**
+ * Register ParserClearState hook.
+ * We defer this until needed to avoid the loading of the code of this file
+ * when no parser function is actually called.
+ */
+ public static function registerClearHook() {
+ static $done = false;
+ if ( !$done ) {
+ global $wgHooks;
+ $wgHooks['ParserClearState'][] = __CLASS__ . '::clearState';
+ $done = true;
+ }
+ }
+
+ /**
+ * @return ExprParser
+ */
+ public static function &getExprParser() {
+ if ( !isset( self::$mExprParser ) ) {
+ self::$mExprParser = new ExprParser;
+ }
+ return self::$mExprParser;
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string $expr
+ * @return string
+ */
+ public static function expr( $parser, $expr = '' ) {
+ try {
+ return self::getExprParser()->doExpression( $expr );
+ } catch ( ExprError $e ) {
+ return '<strong class="error">' . htmlspecialchars( $e->getMessage() ) . '</strong>';
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string $expr
+ * @param string $then
+ * @param string $else
+ * @return string
+ */
+ public static function ifexpr( $parser, $expr = '', $then = '', $else = '' ) {
+ try {
+ $ret = self::getExprParser()->doExpression( $expr );
+ if ( is_numeric( $ret ) ) {
+ $ret = (float)$ret;
+ }
+ if ( $ret ) {
+ return $then;
+ } else {
+ return $else;
+ }
+ } catch ( ExprError $e ) {
+ return '<strong class="error">' . htmlspecialchars( $e->getMessage() ) . '</strong>';
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function ifexprObj( $parser, $frame, $args ) {
+ $expr = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
+ $then = isset( $args[1] ) ? $args[1] : '';
+ $else = isset( $args[2] ) ? $args[2] : '';
+ $result = self::ifexpr( $parser, $expr, $then, $else );
+ if ( is_object( $result ) ) {
+ $result = trim( $frame->expand( $result ) );
+ }
+ return $result;
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function ifObj( $parser, $frame, $args ) {
+ $test = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
+ if ( $test !== '' ) {
+ return isset( $args[1] ) ? trim( $frame->expand( $args[1] ) ) : '';
+ } else {
+ return isset( $args[2] ) ? trim( $frame->expand( $args[2] ) ) : '';
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function ifeqObj( $parser, $frame, $args ) {
+ $left = isset( $args[0] ) ? self::decodeTrimExpand( $args[0], $frame ) : '';
+ $right = isset( $args[1] ) ? self::decodeTrimExpand( $args[1], $frame ) : '';
+
+ // Strict compare is not possible here. 01 should equal 1 for example.
+ /** @noinspection TypeUnsafeComparisonInspection */
+ if ( $left == $right ) {
+ return isset( $args[2] ) ? trim( $frame->expand( $args[2] ) ) : '';
+ } else {
+ return isset( $args[3] ) ? trim( $frame->expand( $args[3] ) ) : '';
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string $test
+ * @param string $then
+ * @param bool $else
+ * @return bool|string
+ */
+ public static function iferror( $parser, $test = '', $then = '', $else = false ) {
+ if ( preg_match(
+ '/<(?:strong|span|p|div)\s(?:[^\s>]*\s+)*?class="(?:[^"\s>]*\s+)*?error(?:\s[^">]*)?"/',
+ $test )
+ ) {
+ return $then;
+ } elseif ( $else === false ) {
+ return $test;
+ } else {
+ return $else;
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function iferrorObj( $parser, $frame, $args ) {
+ $test = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
+ $then = isset( $args[1] ) ? $args[1] : false;
+ $else = isset( $args[2] ) ? $args[2] : false;
+ $result = self::iferror( $parser, $test, $then, $else );
+ if ( $result === false ) {
+ return '';
+ } else {
+ return trim( $frame->expand( $result ) );
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function switchObj( $parser, $frame, $args ) {
+ if ( count( $args ) === 0 ) {
+ return '';
+ }
+ $primary = self::decodeTrimExpand( array_shift( $args ), $frame );
+ $found = $defaultFound = false;
+ $default = null;
+ $lastItemHadNoEquals = false;
+ $lastItem = '';
+ $mwDefault =& MagicWord::get( 'default' );
+ foreach ( $args as $arg ) {
+ $bits = $arg->splitArg();
+ $nameNode = $bits['name'];
+ $index = $bits['index'];
+ $valueNode = $bits['value'];
+
+ if ( $index === '' ) {
+ # Found "="
+ $lastItemHadNoEquals = false;
+ if ( $found ) {
+ # Multiple input match
+ return trim( $frame->expand( $valueNode ) );
+ } else {
+ $test = self::decodeTrimExpand( $nameNode, $frame );
+ /** @noinspection TypeUnsafeComparisonInspection */
+ if ( $test == $primary ) {
+ # Found a match, return now
+ return trim( $frame->expand( $valueNode ) );
+ } elseif ( $defaultFound || $mwDefault->matchStartToEnd( $test ) ) {
+ $default = $valueNode;
+ $defaultFound = false;
+ } # else wrong case, continue
+ }
+ } else {
+ # Multiple input, single output
+ # If the value matches, set a flag and continue
+ $lastItemHadNoEquals = true;
+ // $lastItem is an "out" variable
+ $decodedTest = self::decodeTrimExpand( $valueNode, $frame, $lastItem );
+ /** @noinspection TypeUnsafeComparisonInspection */
+ if ( $decodedTest == $primary ) {
+ $found = true;
+ } elseif ( $mwDefault->matchStartToEnd( $decodedTest ) ) {
+ $defaultFound = true;
+ }
+ }
+ }
+ # Default case
+ # Check if the last item had no = sign, thus specifying the default case
+ if ( $lastItemHadNoEquals ) {
+ return $lastItem;
+ } elseif ( !is_null( $default ) ) {
+ return trim( $frame->expand( $default ) );
+ } else {
+ return '';
+ }
+ }
+
+ /**
+ * Returns the absolute path to a subpage, relative to the current article
+ * title. Treats titles as slash-separated paths.
+ *
+ * Following subpage link syntax instead of standard path syntax, an
+ * initial slash is treated as a relative path, and vice versa.
+ *
+ * @param Parser $parser
+ * @param string $to
+ * @param string $from
+ *
+ * @return string
+ */
+ public static function rel2abs( $parser , $to = '' , $from = '' ) {
+ $from = trim( $from );
+ if ( $from === '' ) {
+ $from = $parser->getTitle()->getPrefixedText();
+ }
+
+ $to = rtrim( $to, ' /' );
+
+ // if we have an empty path, or just one containing a dot
+ if ( $to === '' || $to === '.' ) {
+ return $from;
+ }
+
+ // if the path isn't relative
+ if ( substr( $to, 0, 1 ) !== '/' &&
+ substr( $to, 0, 2 ) !== './' &&
+ substr( $to, 0, 3 ) !== '../' &&
+ $to !== '..'
+ ) {
+ $from = '';
+ }
+ // Make a long path, containing both, enclose it in /.../
+ $fullPath = '/' . $from . '/' . $to . '/';
+
+ // remove redundant current path dots
+ $fullPath = preg_replace( '!/(\./)+!', '/', $fullPath );
+
+ // remove double slashes
+ $fullPath = preg_replace( '!/{2,}!', '/', $fullPath );
+
+ // remove the enclosing slashes now
+ $fullPath = trim( $fullPath, '/' );
+ $exploded = explode( '/', $fullPath );
+ $newExploded = [];
+
+ foreach ( $exploded as $current ) {
+ if ( $current === '..' ) { // removing one level
+ if ( !count( $newExploded ) ) {
+ // attempted to access a node above root node
+ $msg = wfMessage( 'pfunc_rel2abs_invalid_depth', $fullPath )
+ ->inContentLanguage()->escaped();
+ return '<strong class="error">' . $msg . '</strong>';
+ }
+ // remove last level from the stack
+ array_pop( $newExploded );
+ } else {
+ // add the current level to the stack
+ $newExploded[] = $current;
+ }
+ }
+
+ // we can now join it again
+ return implode( '/', $newExploded );
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param string $titletext
+ * @param string $then
+ * @param string $else
+ *
+ * @return string
+ */
+ public static function ifexistCommon(
+ $parser, $frame, $titletext = '', $then = '', $else = ''
+ ) {
+ global $wgContLang;
+ $title = Title::newFromText( $titletext );
+ $wgContLang->findVariantLink( $titletext, $title, true );
+ if ( $title ) {
+ if ( $title->getNamespace() === NS_MEDIA ) {
+ /* If namespace is specified as NS_MEDIA, then we want to
+ * check the physical file, not the "description" page.
+ */
+ if ( !$parser->incrementExpensiveFunctionCount() ) {
+ return $else;
+ }
+ $file = wfFindFile( $title );
+ if ( !$file ) {
+ return $else;
+ }
+ $parser->mOutput->addImage(
+ $file->getName(), $file->getTimestamp(), $file->getSha1() );
+ return $file->exists() ? $then : $else;
+ } elseif ( $title->getNamespace() === NS_SPECIAL ) {
+ /* Don't bother with the count for special pages,
+ * since their existence can be checked without
+ * accessing the database.
+ */
+ return SpecialPageFactory::exists( $title->getDBkey() ) ? $then : $else;
+ } elseif ( $title->isExternal() ) {
+ /* Can't check the existence of pages on other sites,
+ * so just return $else. Makes a sort of sense, since
+ * they don't exist _locally_.
+ */
+ return $else;
+ } else {
+ $pdbk = $title->getPrefixedDBkey();
+ $lc = LinkCache::singleton();
+ $id = $lc->getGoodLinkID( $pdbk );
+ if ( $id !== 0 ) {
+ $parser->mOutput->addLink( $title, $id );
+ return $then;
+ } elseif ( $lc->isBadLink( $pdbk ) ) {
+ $parser->mOutput->addLink( $title, 0 );
+ return $else;
+ }
+ if ( !$parser->incrementExpensiveFunctionCount() ) {
+ return $else;
+ }
+ $id = $title->getArticleID();
+ $parser->mOutput->addLink( $title, $id );
+
+ // bug 70495: don't just check whether the ID != 0
+ if ( $title->exists() ) {
+ return $then;
+ }
+ }
+ }
+ return $else;
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function ifexistObj( $parser, $frame, $args ) {
+ $title = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
+ $then = isset( $args[1] ) ? $args[1] : null;
+ $else = isset( $args[2] ) ? $args[2] : null;
+
+ $result = self::ifexistCommon( $parser, $frame, $title, $then, $else );
+ if ( $result === null ) {
+ return '';
+ } else {
+ return trim( $frame->expand( $result ) );
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param string $format
+ * @param string $date
+ * @param string $language
+ * @param string|bool $local
+ * @return string
+ */
+ public static function timeCommon(
+ $parser, $frame = null, $format = '', $date = '', $language = '', $local = false
+ ) {
+ global $wgLocaltimezone;
+ self::registerClearHook();
+ if ( $date === '' ) {
+ $cacheKey = $parser->getOptions()->getTimestamp();
+ $timestamp = new MWTimestamp( $cacheKey );
+ $date = $timestamp->getTimestamp( TS_ISO_8601 );
+ $useTTL = true;
+ } else {
+ $cacheKey = $date;
+ $useTTL = false;
+ }
+ if ( isset( self::$mTimeCache[$format][$cacheKey][$language][$local] ) ) {
+ $cachedVal = self::$mTimeCache[$format][$cacheKey][$language][$local];
+ if ( $useTTL
+ && $cachedVal[1] !== null && $frame && is_callable( [ $frame, 'setTTL' ] )
+ ) {
+ $frame->setTTL( $cachedVal[1] );
+ }
+ return $cachedVal[0];
+ }
+
+ # compute the timestamp string $ts
+ # PHP >= 5.2 can handle dates before 1970 or after 2038 using the DateTime object
+
+ $invalidTime = false;
+
+ # the DateTime constructor must be used because it throws exceptions
+ # when errors occur, whereas date_create appears to just output a warning
+ # that can't really be detected from within the code
+ try {
+
+ # Default input timezone is UTC.
+ $utc = new DateTimeZone( 'UTC' );
+
+ # Correct for DateTime interpreting 'XXXX' as XX:XX o'clock
+ if ( preg_match( '/^[0-9]{4}$/', $date ) ) {
+ $date = '00:00 '.$date;
+ }
+
+ # Parse date
+ # UTC is a default input timezone.
+ $dateObject = new DateTime( $date, $utc );
+
+ # Set output timezone.
+ if ( $local ) {
+ if ( isset( $wgLocaltimezone ) ) {
+ $tz = new DateTimeZone( $wgLocaltimezone );
+ } else {
+ $tz = new DateTimeZone( date_default_timezone_get() );
+ }
+ } else {
+ $tz = $utc;
+ }
+ $dateObject->setTimezone( $tz );
+ # Generate timestamp
+ $ts = $dateObject->format( 'YmdHis' );
+
+ } catch ( Exception $ex ) {
+ $invalidTime = true;
+ }
+
+ $ttl = null;
+ # format the timestamp and return the result
+ if ( $invalidTime ) {
+ $result = '<strong class="error">' .
+ wfMessage( 'pfunc_time_error' )->inContentLanguage()->escaped() .
+ '</strong>';
+ } else {
+ self::$mTimeChars += strlen( $format );
+ if ( self::$mTimeChars > self::$mMaxTimeChars ) {
+ return '<strong class="error">' .
+ wfMessage( 'pfunc_time_too_long' )->inContentLanguage()->escaped() .
+ '</strong>';
+ } else {
+ if ( $ts < 0 ) { // Language can't deal with BC years
+ return '<strong class="error">' .
+ wfMessage( 'pfunc_time_too_small' )->inContentLanguage()->escaped() .
+ '</strong>';
+ } elseif ( $ts < 100000000000000 ) { // Language can't deal with years after 9999
+ if ( $language !== '' && Language::isValidBuiltInCode( $language ) ) {
+ // use whatever language is passed as a parameter
+ $langObject = Language::factory( $language );
+ } else {
+ // use wiki's content language
+ $langObject = $parser->getFunctionLang();
+ // $ttl is passed by reference, which doesn't work right on stub objects
+ StubObject::unstub( $langObject );
+ }
+ $result = $langObject->sprintfDate( $format, $ts, $tz, $ttl );
+ } else {
+ return '<strong class="error">' .
+ wfMessage( 'pfunc_time_too_big' )->inContentLanguage()->escaped() .
+ '</strong>';
+ }
+ }
+ }
+ self::$mTimeCache[$format][$cacheKey][$language][$local] = [ $result, $ttl ];
+ if ( $useTTL && $ttl !== null && $frame && is_callable( [ $frame, 'setTTL' ] ) ) {
+ $frame->setTTL( $ttl );
+ }
+ return $result;
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string $format
+ * @param string $date
+ * @param string $language
+ * @param string|bool $local
+ * @return string
+ */
+ public static function time(
+ $parser, $format = '', $date = '', $language = '', $local = false
+ ) {
+ return self::timeCommon( $parser, null, $format, $date, $language, $local );
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function timeObj( $parser, $frame, $args ) {
+ $format = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
+ $date = isset( $args[1] ) ? trim( $frame->expand( $args[1] ) ) : '';
+ $language = isset( $args[2] ) ? trim( $frame->expand( $args[2] ) ) : '';
+ $local = isset( $args[3] ) && trim( $frame->expand( $args[3] ) );
+ return self::timeCommon( $parser, $frame, $format, $date, $language, $local );
+ }
+
+ /**
+ * @param Parser $parser
+ * @param string $format
+ * @param string $date
+ * @param string $language
+ * @return string
+ */
+ public static function localTime( $parser, $format = '', $date = '', $language = '' ) {
+ return self::timeCommon( $parser, null, $format, $date, $language, true );
+ }
+
+ /**
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @param array $args
+ * @return string
+ */
+ public static function localTimeObj( $parser, $frame, $args ) {
+ $format = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
+ $date = isset( $args[1] ) ? trim( $frame->expand( $args[1] ) ) : '';
+ $language = isset( $args[2] ) ? trim( $frame->expand( $args[2] ) ) : '';
+ return self::timeCommon( $parser, $frame, $format, $date, $language, true );
+ }
+
+ /**
+ * Obtain a specified number of slash-separated parts of a title,
+ * e.g. {{#titleparts:Hello/World|1}} => "Hello"
+ *
+ * @param Parser $parser Parent parser
+ * @param string $title Title to split
+ * @param int $parts Number of parts to keep
+ * @param int $offset Offset starting at 1
+ * @return string
+ */
+ public static function titleparts( $parser, $title = '', $parts = 0, $offset = 0 ) {
+ $parts = (int)$parts;
+ $offset = (int)$offset;
+ $ntitle = Title::newFromText( $title );
+ if ( $ntitle instanceof Title ) {
+ $bits = explode( '/', $ntitle->getPrefixedText(), 25 );
+ if ( count( $bits ) <= 0 ) {
+ return $ntitle->getPrefixedText();
+ } else {
+ if ( $offset > 0 ) {
+ --$offset;
+ }
+ if ( $parts === 0 ) {
+ return implode( '/', array_slice( $bits, $offset ) );
+ } else {
+ return implode( '/', array_slice( $bits, $offset, $parts ) );
+ }
+ }
+ } else {
+ return $title;
+ }
+ }
+
+ /**
+ * Verifies parameter is less than max string length.
+ * @param string $text
+ * @return bool
+ */
+ private static function checkLength( $text ) {
+ global $wgPFStringLengthLimit;
+ return ( mb_strlen( $text ) < $wgPFStringLengthLimit );
+ }
+
+ /**
+ * Generates error message. Called when string is too long.
+ * @return string
+ */
+ private static function tooLongError() {
+ global $wgPFStringLengthLimit;
+ $msg = wfMessage( 'pfunc_string_too_long' )->numParams( $wgPFStringLengthLimit );
+ return '<strong class="error">' . $msg->inContentLanguage()->escaped() . '</strong>';
+ }
+
+ /**
+ * {{#len:string}}
+ *
+ * Reports number of characters in string.
+ * @param Parser $parser
+ * @param string $inStr
+ * @return int
+ */
+ public static function runLen( $parser, $inStr = '' ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+ return mb_strlen( $inStr );
+ }
+
+ /**
+ * {{#pos: string | needle | offset}}
+ *
+ * Finds first occurrence of "needle" in "string" starting at "offset".
+ *
+ * Note: If the needle is an empty string, single space is used instead.
+ * Note: If the needle is not found, empty string is returned.
+ * @param Parser $parser
+ * @param string $inStr
+ * @param int|string $inNeedle
+ * @param int $inOffset
+ * @return int|string
+ */
+ public static function runPos( $parser, $inStr = '', $inNeedle = '', $inOffset = 0 ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+ $inNeedle = $parser->killMarkers( (string)$inNeedle );
+
+ if ( !self::checkLength( $inStr ) ||
+ !self::checkLength( $inNeedle ) ) {
+ return self::tooLongError();
+ }
+
+ if ( $inNeedle === '' ) {
+ $inNeedle = ' ';
+ }
+
+ $pos = mb_strpos( $inStr, $inNeedle, min( (int)$inOffset, mb_strlen( $inStr ) ) );
+ if ( $pos === false ) {
+ $pos = '';
+ }
+
+ return $pos;
+ }
+
+ /**
+ * {{#rpos: string | needle}}
+ *
+ * Finds last occurrence of "needle" in "string".
+ *
+ * Note: If the needle is an empty string, single space is used instead.
+ * Note: If the needle is not found, -1 is returned.
+ * @param Parser $parser
+ * @param string $inStr
+ * @param int|string $inNeedle
+ * @return int|string
+ */
+ public static function runRPos( $parser, $inStr = '', $inNeedle = '' ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+ $inNeedle = $parser->killMarkers( (string)$inNeedle );
+
+ if ( !self::checkLength( $inStr ) ||
+ !self::checkLength( $inNeedle ) ) {
+ return self::tooLongError();
+ }
+
+ if ( $inNeedle === '' ) {
+ $inNeedle = ' ';
+ }
+
+ $pos = mb_strrpos( $inStr, $inNeedle );
+ if ( $pos === false ) {
+ $pos = -1;
+ }
+
+ return $pos;
+ }
+
+ /**
+ * {{#sub: string | start | length }}
+ *
+ * Returns substring of "string" starting at "start" and having
+ * "length" characters.
+ *
+ * Note: If length is zero, the rest of the input is returned.
+ * Note: A negative value for "start" operates from the end of the
+ * "string".
+ * Note: A negative value for "length" returns a string reduced in
+ * length by that amount.
+ *
+ * @param Parser $parser
+ * @param string $inStr
+ * @param int $inStart
+ * @param int $inLength
+ * @return string
+ */
+ public static function runSub( $parser, $inStr = '', $inStart = 0, $inLength = 0 ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+
+ if ( !self::checkLength( $inStr ) ) {
+ return self::tooLongError();
+ }
+
+ if ( (int)$inLength === 0 ) {
+ $result = mb_substr( $inStr, (int)$inStart );
+ } else {
+ $result = mb_substr( $inStr, (int)$inStart, (int)$inLength );
+ }
+
+ return $result;
+ }
+
+ /**
+ * {{#count: string | substr }}
+ *
+ * Returns number of occurrences of "substr" in "string".
+ *
+ * Note: If "substr" is empty, a single space is used.
+ * @param Parser $parser
+ * @param string $inStr
+ * @param string $inSubStr
+ * @return int|string
+ */
+ public static function runCount( $parser, $inStr = '', $inSubStr = '' ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+ $inSubStr = $parser->killMarkers( (string)$inSubStr );
+
+ if ( !self::checkLength( $inStr ) ||
+ !self::checkLength( $inSubStr ) ) {
+ return self::tooLongError();
+ }
+
+ if ( $inSubStr === '' ) {
+ $inSubStr = ' ';
+ }
+
+ $result = mb_substr_count( $inStr, $inSubStr );
+
+ return $result;
+ }
+
+ /**
+ * {{#replace:string | from | to | limit }}
+ *
+ * Replaces each occurrence of "from" in "string" with "to".
+ * At most "limit" replacements are performed.
+ *
+ * Note: Armored against replacements that would generate huge strings.
+ * Note: If "from" is an empty string, single space is used instead.
+ * @param Parser $parser
+ * @param string $inStr
+ * @param string $inReplaceFrom
+ * @param string $inReplaceTo
+ * @param int $inLimit
+ * @return mixed|string
+ */
+ public static function runReplace( $parser, $inStr = '',
+ $inReplaceFrom = '', $inReplaceTo = '', $inLimit = -1 ) {
+ global $wgPFStringLengthLimit;
+
+ $inStr = $parser->killMarkers( (string)$inStr );
+ $inReplaceFrom = $parser->killMarkers( (string)$inReplaceFrom );
+ $inReplaceTo = $parser->killMarkers( (string)$inReplaceTo );
+
+ if ( !self::checkLength( $inStr ) ||
+ !self::checkLength( $inReplaceFrom ) ||
+ !self::checkLength( $inReplaceTo ) ) {
+ return self::tooLongError();
+ }
+
+ if ( $inReplaceFrom === '' ) {
+ $inReplaceFrom = ' ';
+ }
+
+ // Precompute limit to avoid generating enormous string:
+ $diff = mb_strlen( $inReplaceTo ) - mb_strlen( $inReplaceFrom );
+ if ( $diff > 0 ) {
+ $limit = ( ( $wgPFStringLengthLimit - mb_strlen( $inStr ) ) / $diff ) + 1;
+ } else {
+ $limit = -1;
+ }
+
+ $inLimit = (int)$inLimit;
+ if ( $inLimit >= 0 ) {
+ if ( $limit > $inLimit || $limit == -1 ) {
+ $limit = $inLimit;
+ }
+ }
+
+ // Use regex to allow limit and handle UTF-8 correctly.
+ $inReplaceFrom = preg_quote( $inReplaceFrom, '/' );
+ $inReplaceTo = StringUtils::escapeRegexReplacement( $inReplaceTo );
+
+ $result = preg_replace( '/' . $inReplaceFrom . '/u',
+ $inReplaceTo, $inStr, $limit );
+
+ if ( !self::checkLength( $result ) ) {
+ return self::tooLongError();
+ }
+
+ return $result;
+ }
+
+ /**
+ * {{#explode:string | delimiter | position | limit}}
+ *
+ * Breaks "string" into chunks separated by "delimiter" and returns the
+ * chunk identified by "position".
+ *
+ * Note: Negative position can be used to specify tokens from the end.
+ * Note: If the divider is an empty string, single space is used instead.
+ * Note: Empty string is returned if there are not enough exploded chunks.
+ * @param Parser $parser
+ * @param string $inStr
+ * @param string $inDiv
+ * @param int $inPos
+ * @param int|null $inLim
+ * @return string
+ */
+ public static function runExplode(
+ $parser, $inStr = '', $inDiv = '', $inPos = 0, $inLim = null
+ ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+ $inDiv = $parser->killMarkers( (string)$inDiv );
+
+ if ( $inDiv === '' ) {
+ $inDiv = ' ';
+ }
+
+ if ( !self::checkLength( $inStr ) ||
+ !self::checkLength( $inDiv ) ) {
+ return self::tooLongError();
+ }
+
+ $inDiv = preg_quote( $inDiv, '/' );
+
+ $matches = preg_split( '/' . $inDiv . '/u', $inStr, $inLim );
+
+ if ( $inPos >= 0 && isset( $matches[$inPos] ) ) {
+ $result = $matches[$inPos];
+ } elseif ( $inPos < 0 && isset( $matches[count( $matches ) + $inPos] ) ) {
+ $result = $matches[count( $matches ) + $inPos];
+ } else {
+ $result = '';
+ }
+
+ return $result;
+ }
+
+ /**
+ * {{#urldecode:string}}
+ *
+ * Decodes URL-encoded (like%20that) strings.
+ * @param Parser $parser
+ * @param string $inStr
+ * @return string
+ */
+ public static function runUrlDecode( $parser, $inStr = '' ) {
+ $inStr = $parser->killMarkers( (string)$inStr );
+ if ( !self::checkLength( $inStr ) ) {
+ return self::tooLongError();
+ }
+
+ return urldecode( $inStr );
+ }
+
+ /**
+ * Take a PPNode (-ish thing), expand it, remove entities, and trim.
+ *
+ * For use when doing string comparisions, where user expects entities
+ * to be equal for what they stand for (e.g. comparisions with {{PAGENAME}})
+ *
+ * @param PPNode|string $obj Thing to expand
+ * @param PPFrame $frame
+ * @param string &$trimExpanded Expanded and trimmed version of PPNode,
+ * but with char refs intact
+ * @return string The trimmed, expanded and entity reference decoded version of the PPNode
+ */
+ private static function decodeTrimExpand( $obj, $frame, &$trimExpanded = null ) {
+ $expanded = $frame->expand( $obj );
+ $trimExpanded = trim( $expanded );
+ return trim( Sanitizer::decodeCharReferences( $expanded ) );
+ }
+}
diff --git a/www/wiki/extensions/ParserFunctions/includes/ParserFunctionsHooks.php b/www/wiki/extensions/ParserFunctions/includes/ParserFunctionsHooks.php
new file mode 100644
index 00000000..af1c7522
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/includes/ParserFunctionsHooks.php
@@ -0,0 +1,59 @@
+<?php
+
+class ParserFunctionsHooks {
+
+ /**
+ * Enable string functions, when running Wikimedia Jenkins unit tests.
+ *
+ * Running Jenkins unit tests without setting $wgPFEnableStringFunctions = true;
+ * will cause all the parser tests for string functions to be skipped.
+ */
+ public static function onRegistration() {
+ if ( isset( $GLOBALS['wgWikimediaJenkinsCI'] ) && $GLOBALS['wgWikimediaJenkinsCI'] === true ) {
+ $GLOBALS['wgPFEnableStringFunctions'] = true;
+ }
+ }
+
+ /**
+ * @param Parser $parser
+ * @return bool
+ */
+ public static function onParserFirstCallInit( $parser ) {
+ global $wgPFEnableStringFunctions;
+
+ // These functions accept DOM-style arguments
+ $parser->setFunctionHook( 'if', 'ExtParserFunctions::ifObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'ifeq', 'ExtParserFunctions::ifeqObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'switch', 'ExtParserFunctions::switchObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'ifexist', 'ExtParserFunctions::ifexistObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'ifexpr', 'ExtParserFunctions::ifexprObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'iferror', 'ExtParserFunctions::iferrorObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'time', 'ExtParserFunctions::timeObj', Parser::SFH_OBJECT_ARGS );
+ $parser->setFunctionHook( 'timel', 'ExtParserFunctions::localTimeObj', Parser::SFH_OBJECT_ARGS );
+
+ $parser->setFunctionHook( 'expr', 'ExtParserFunctions::expr' );
+ $parser->setFunctionHook( 'rel2abs', 'ExtParserFunctions::rel2abs' );
+ $parser->setFunctionHook( 'titleparts', 'ExtParserFunctions::titleparts' );
+
+ // String Functions
+ if ( $wgPFEnableStringFunctions ) {
+ $parser->setFunctionHook( 'len', 'ExtParserFunctions::runLen' );
+ $parser->setFunctionHook( 'pos', 'ExtParserFunctions::runPos' );
+ $parser->setFunctionHook( 'rpos', 'ExtParserFunctions::runRPos' );
+ $parser->setFunctionHook( 'sub', 'ExtParserFunctions::runSub' );
+ $parser->setFunctionHook( 'count', 'ExtParserFunctions::runCount' );
+ $parser->setFunctionHook( 'replace', 'ExtParserFunctions::runReplace' );
+ $parser->setFunctionHook( 'explode', 'ExtParserFunctions::runExplode' );
+ $parser->setFunctionHook( 'urldecode', 'ExtParserFunctions::runUrlDecode' );
+ }
+
+ return true;
+ }
+
+ public static function onScribuntoExternalLibraries( $engine, array &$extraLibraries ) {
+ if ( $engine === 'lua' ) {
+ $extraLibraries['mw.ext.ParserFunctions'] = 'Scribunto_LuaParserFunctionsLibrary';
+ }
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/ParserFunctions/includes/Scribunto_LuaParserFunctionsLibrary.php b/www/wiki/extensions/ParserFunctions/includes/Scribunto_LuaParserFunctionsLibrary.php
new file mode 100644
index 00000000..7dc7c598
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/includes/Scribunto_LuaParserFunctionsLibrary.php
@@ -0,0 +1,23 @@
+<?php
+
+class Scribunto_LuaParserFunctionsLibrary extends Scribunto_LuaLibraryBase {
+ public function register() {
+ $lib = [
+ 'expr' => [ $this, 'expr' ],
+ ];
+
+ return $this->getEngine()->registerInterface(
+ __DIR__ . '/mw.ext.ParserFunctions.lua', $lib, []
+ );
+ }
+
+ public function expr( $expression = null ) {
+ $this->checkType( 'mw.ext.ParserFunctions.expr', 1, $expression, 'string' );
+ try {
+ return [ ExtParserFunctions::getExprParser()->doExpression( $expression ) ];
+ } catch ( ExprError $e ) {
+ throw new Scribunto_LuaError( $e->getMessage() );
+ }
+ }
+
+}
diff --git a/www/wiki/extensions/ParserFunctions/includes/mw.ext.ParserFunctions.lua b/www/wiki/extensions/ParserFunctions/includes/mw.ext.ParserFunctions.lua
new file mode 100644
index 00000000..ccec046d
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/includes/mw.ext.ParserFunctions.lua
@@ -0,0 +1,22 @@
+local ParserFunctions = {}
+local php
+
+function ParserFunctions.expr( expression )
+ return php.expr( expression )
+end
+
+function ParserFunctions.setupInterface( options )
+ -- Boilerplate
+ ParserFunctions.setupInterface = nil
+ php = mw_interface
+ mw_interface = nil
+
+ -- Register this library in the "mw" global
+ mw = mw or {}
+ mw.ext = mw.ext or {}
+ mw.ext.ParserFunctions = ParserFunctions
+
+ package.loaded['mw.ext.ParserFunctions'] = ParserFunctions
+end
+
+return ParserFunctions
diff --git a/www/wiki/extensions/ParserFunctions/tests/parser/funcsParserTests.txt b/www/wiki/extensions/ParserFunctions/tests/parser/funcsParserTests.txt
new file mode 100644
index 00000000..b66b6b4a
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/tests/parser/funcsParserTests.txt
@@ -0,0 +1,343 @@
+# Force the test runner to ensure the extension is loaded
+# fixme... this doesn't seem to work :D
+#!! functionhooks
+#time
+#!! endfunctionhooks
+
+# fixme: #time seems to be accepting input as local time, which strikes me as wrong
+
+!! article
+ParserFunctions page
+!! text
+A sample page so we can test ifexist.
+
+This used to be a Main Page, but that caused duplicate article
+warnings when running the normal tests at the same time.
+!! endarticle
+
+!! article
+File:Dionysos-Brunnen am Kölner Dom.jpg
+!! text
+blah blah
+!! endarticle
+
+!! article
+File:Redirect_to_Foobar.jpg
+!! text
+#REDIRECT[[File:Foobar.jpg]]
+!! endarticle
+
+!! article
+File:Redirect_to_nowhere.jpg
+!! text
+#REDIRECT[[File:Missing target file.jpg]]
+!! endarticle
+
+!! test
+Input times are UTC, not local time
+!! input
+{{#time:c|15 January 2001}}
+!!result
+<p>2001-01-15T00:00:00+00:00
+</p>
+!! end
+
+!! test
+Time test in traditional range...
+!! input
+{{#time:Y|15 January 2001}}
+!! result
+<p>2001
+</p>
+!! end
+
+!! test
+Time test prior to 1970 Unix creation myth
+!! input
+{{#time:Y|5 April 1967}}
+!! result
+<p>1967
+</p>
+!! end
+
+!! test
+Time test after the 2038 32-bit Apocalype
+!! input
+{{#time:Y|28 July 2061}}
+!! result
+<p>2061
+</p>
+!! end
+
+!! test
+Explicitly specified timezone: UTC
+!! input
+{{#time:Y-m-d H:i| 2011-11-12 23:00 UTC }}
+!! result
+<p>2011-11-12 23:00
+</p>
+!! end
+
+!! test
+Explicitly specified timezone: Europe/Paris (UTC+1)
+!! input
+{{#time:Y-m-d H:i| 2011-11-12 23:00 Europe/Paris }}
+!! result
+<p>2011-11-12 22:00
+</p>
+!! end
+
+!! test
+Explicitly specified timezone: America/New_York (UTC-5)
+!! input
+{{#time:Y-m-d H:i| 2011-11-12 23:00 America/New_York }}
+!! result
+<p>2011-11-13 04:00
+</p>
+!! end
+
+!! test
+Explicitely specified output language (Dutch)
+!! input
+{{#time:d F Y|1988-02-28|nl}}
+!! result
+<p>28 februari 1988
+</p>
+!! end
+
+!! test
+Preserve tags in #switch default value
+!! input
+{{#switch:a|b|<div>c</div>}}
+!! result
+<div>c</div>
+
+!! end
+
+!! test
+Bug 19093: Default values don't fall through in switch
+!! input
+<{{#switch: foo | bar | #default = DEF }}>
+<{{#switch: foo | #default | bar = DEF }}>
+!! result
+<p>&lt;DEF&gt;
+&lt;DEF&gt;
+</p>
+!! end
+
+!! test
+{{#ifexist}}
+!! input
+{{#ifexist:Media:Foobar.jpg|Found|Not found}}
+{{#ifexist:ParserFunctions page|Found|Not found}}
+{{#ifexist:Missing|Found|Not found}}
+!! result
+<p>Found
+Found
+Not found
+</p>
+!! end
+
+!! test
+{{#ifexist:}} media redirect (bug 32031)
+!! input
+{{#ifexist:Media:Redirect_to_Foobar.jpg|Found|Not found}}
+{{#ifexist:Media:Redirect_to_nowhere.jpg|Found|Not found}}
+{{#ifexist:Media:Missing file.jpg|Found|Not found}}
+{{#ifexist:Media:Dionysos-Brunnen am Kölner Dom.jpg|Found|Not found}}
+!!result
+<p>Found
+Not found
+Not found
+Not found
+</p>
+!!end
+
+!! test
+#if
+!! input
+{{#if: | yes | no}}
+{{#if: string | yes | no}}
+{{#if: | yes | no}}
+{{#if:
+
+
+| yes | no}}
+{{#if: 1==2 | yes | no}}
+{{#if: foo | yes }}
+{{#if: | yes }}(empty)
+{{#if: foo | | no}}(empty)
+{{#if: {{{1}}} | yes | no}}
+{{#if: {{{1|}}} | yes | no}}
+!! result
+<p>no
+yes
+no
+no
+yes
+yes
+(empty)
+(empty)
+yes
+no
+</p>
+!! end
+
+!! test
+#ifeq
+!!input
+{{#ifeq: 01 | 1 | yes | no}}
+{{#ifeq: 0 | -0 | yes | no}}
+{{#ifeq: foo | bar | yes | no}}
+{{#ifeq: foo | Foo | yes | no}}
+{{#ifeq: "01" | "1" | yes | no}}
+!! result
+<p>yes
+yes
+no
+no
+no
+</p>
+!! end
+
+!! test
+#ifeq entities
+!!input
+{{#ifeq: {{PAGENAME:*foo&bar}} | *foo&bar | yes | no}}
+{{#ifeq: a'b | a&#39;b | yes | no}}
+{{#ifeq: a'b | a&amp;#39;b | yes | no}}
+{{#ifeq: foo | Foo | *yes | *no}}
+!! result
+<p>yes
+yes
+no
+</p>
+<ul><li>no</li></ul>
+
+!! end
+
+
+!! test
+#iferror
+!!input
+{{#iferror: {{#expr: 1 + 2 }} | error | correct }}
+{{#iferror: {{#expr: 1 + X }} | error | correct }}
+{{#iferror: {{#expr: 1 + 2 }} | error }}
+{{#iferror: {{#expr: 1 + X }} | error }}
+{{#iferror: {{#expr: 1 + 2 }} }}
+{{#iferror: {{#expr: 1 + X }} }}empty
+!! result
+<p>correct
+error
+3
+error
+3
+empty
+</p>
+!! end
+
+
+!! test
+#ifexpr
+!! input
+{{#ifexpr: | yes | no}}
+{{#ifexpr: 1 > 0 | yes }}
+{{#ifexpr: 1 < 0 | yes }}empty
+{{#ifexpr: 1 > 0 | | no}}empty
+{{#ifexpr: 1 < 0 | | no}}
+{{#ifexpr: 1 > 0 }}empty
+!! result
+<p>no
+yes
+empty
+empty
+no
+empty
+</p>
+!! end
+
+!! test
+Bug 22866: #ifexpr should evaluate "-0" as false
+!! input
+{{#ifexpr: (-1)*0 | true | false }}
+!! result
+<p>false
+</p>
+!! end
+
+!! test
+Templates: Parser functions don't strip whitespace from positional parameters
+!! input
+{{#if: {{foo}}
+| no-pre-then
+| no-pre-else
+}}
+!! result
+<p>no-pre-then
+</p>
+!! end
+
+!! test
+#switch
+!! input
+{{#switch:foo&bar|foo&amp;bar=yes|no}}
+{{#switch:foo&bar|fred=1|foo&amp;bar|g=yes|no}}
+{{#switch:foo&bar|fred=1|foo&amp;&#39;bar|g=yes|no}}
+{{#switch:foo|bar|baz=no|*default}}
+{{#switch:none|foo=1|bar=2|#default=no match|baz=3}}
+{{#switch:none|foo=1|bar=2|#default=ignored|baz=3|Second default}}
+{{#switch:|a&amp;#39;b}}
+!! result
+<p>yes
+yes
+no
+</p>
+<ul><li>default</li></ul>
+<p>no match
+Second default
+a&amp;#39;b
+</p>
+!!end
+
+!! test
+#switch #default should match next and not last named parameter
+!! input
+<{{#switch: foo | #default | bar = DEF }}>
+<{{#switch: foo | #default | bar = DEF | baz = GHI }}>
+!! result
+<p>&lt;DEF&gt;
+&lt;DEF&gt;
+</p>
+!! end
+
+!! test
+#switch should not match #default as a prefix
+!! input
+<{{#switch: foo | #defaultWTF? = This is crazy }}>
+<{{#switch: foo | #defaultWTF? | bar = This is crazy }}>
+!! result
+<p>&lt;&gt;
+&lt;&gt;
+</p>
+!! end
+
+!! test
+#switch Test php truthy
+!!input
+{{#switch: 01 | 1 = yes | no}}
+{{#switch: 0 | -0 = yes | no}}
+{{#switch: foo | bar = yes | no}}
+{{#switch: foo | Foo = yes | no}}
+{{#switch: "01" | "1" = yes | no}}
+{{#switch: 1 | 02 | 01 = yes | no}}
+{{#switch: 1 | "01" | "1" = yes | no}}
+!! result
+<p>yes
+yes
+no
+no
+no
+yes
+no
+</p>
+!! end
diff --git a/www/wiki/extensions/ParserFunctions/tests/parser/stringFunctionTests.txt b/www/wiki/extensions/ParserFunctions/tests/parser/stringFunctionTests.txt
new file mode 100644
index 00000000..b1fb9651
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/tests/parser/stringFunctionTests.txt
@@ -0,0 +1,50 @@
+# @todo expand
+!! functionhooks
+len
+!! endfunctionhooks
+
+!! test
+#len
+!! input
+{{#len:}}
+{{#len:0}}
+{{#len:test}}
+!!result
+<p>0
+1
+4
+</p>
+!! end
+
+!! test
+#urldecode
+!! input
+{{#urldecode:}}
+{{#urldecode:foo%20bar}}
+{{#urldecode:%D0%9C%D0%B5%D0%B4%D0%B8%D0%B0%D0%92%D0%B8%D0%BA%D0%B8}}
+{{#urldecode: some unescaped string}}
+!! result
+<p>foo bar
+МедиаВики
+some unescaped string
+</p>
+!! end
+
+!! test
+#pos
+!! input
+{{#pos:Žmržlina|žlina}}
+{{#pos:stringstring|str|4}}
+!! result
+<p>3
+6
+</p>
+!! end
+
+!! test
+#pos with too large offset (T209600)
+!! input
+{{#pos:FooBar|Foo|32}}
+!! result
+
+!! end
diff --git a/www/wiki/extensions/ParserFunctions/tests/phan/config.php b/www/wiki/extensions/ParserFunctions/tests/phan/config.php
new file mode 100644
index 00000000..83214eee
--- /dev/null
+++ b/www/wiki/extensions/ParserFunctions/tests/phan/config.php
@@ -0,0 +1,19 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+
+$cfg['directory_list'] = array_merge(
+ $cfg['directory_list'],
+ [
+ './../../extensions/Scribunto',
+ ]
+);
+
+$cfg['exclude_analysis_directory_list'] = array_merge(
+ $cfg['exclude_analysis_directory_list'],
+ [
+ './../../extensions/Scribunto',
+ ]
+);
+
+return $cfg;
diff --git a/www/wiki/extensions/ParserFunctions/tests/phpunit/ExpressionTest.php b/www/wiki/extensions/ParserFunctions/tests/phpunit/ExpressionTest.php
index 690457a2..06d571e3 100644
--- a/www/wiki/extensions/ParserFunctions/tests/phpunit/ExpressionTest.php
+++ b/www/wiki/extensions/ParserFunctions/tests/phpunit/ExpressionTest.php
@@ -1,4 +1,8 @@
<?php
+
+/**
+ * @covers ExprParser
+ */
class ExpressionTest extends MediaWikiTestCase {
/**
diff --git a/www/wiki/extensions/PdfHandler/Gruntfile.js b/www/wiki/extensions/PdfHandler/Gruntfile.js
index e4033e51..26ca0c16 100644
--- a/www/wiki/extensions/PdfHandler/Gruntfile.js
+++ b/www/wiki/extensions/PdfHandler/Gruntfile.js
@@ -17,7 +17,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/PdfHandler/composer.json b/www/wiki/extensions/PdfHandler/composer.json
index 021a14cb..b822010c 100644
--- a/www/wiki/extensions/PdfHandler/composer.json
+++ b/www/wiki/extensions/PdfHandler/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/PdfHandler/extension.json b/www/wiki/extensions/PdfHandler/extension.json
index 73aa6f68..d046d0e0 100644
--- a/www/wiki/extensions/PdfHandler/extension.json
+++ b/www/wiki/extensions/PdfHandler/extension.json
@@ -6,7 +6,7 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:PdfHandler",
"descriptionmsg": "pdf-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "media",
"requires": {
"MediaWiki": ">= 1.25.0"
@@ -41,9 +41,9 @@
"application/pdf": "PdfHandler"
},
"AutoloadClasses": {
- "PdfImage": "PdfHandler.image.php",
- "PdfHandler": "PdfHandler_body.php",
- "CreatePdfThumbnailsJob": "CreatePdfThumbnailsJob.class.php"
+ "PdfImage": "includes/PdfImage.php",
+ "PdfHandler": "includes/PdfHandler.php",
+ "CreatePdfThumbnailsJob": "includes/CreatePdfThumbnailsJob.php"
},
"manifest_version": 1
}
diff --git a/www/wiki/extensions/PdfHandler/i18n/ais.json b/www/wiki/extensions/PdfHandler/i18n/ais.json
index f224ee74..510ec64b 100644
--- a/www/wiki/extensions/PdfHandler/i18n/ais.json
+++ b/www/wiki/extensions/PdfHandler/i18n/ais.json
@@ -6,7 +6,13 @@
"Benel"
]
},
+ "pdf-desc": "pisaungay zunga muse ciwsace PDF tangan a lisimet cengse",
+ "pdf-file-page-warning": "PDF u macibulay a kese, i hatizaay a pulita hakay apuelac liyad dimuday a cesyun. pilucek PDF ciwsace-sakaluk nu misu masaungay kazahkezay a sasakawawen setin.",
"pdf-file-page-warning-header": "mizateng tu midimut kasikazan",
+ "pdf-file-page-warning-footer": "tina munday caay patuzu’ tu zumaay tangan, ku PDF kese a habutud munday.",
+ "pdf-file-page-warning-info": "amitineng yadah mahizaay tina munday.",
+ "pdf_no_metadata": "la’cus ilabu nu PDF miala misaheci nu kalunasulitan.",
+ "pdf_page_error": "kasabilih mataelib ku tatungus.",
"exif-pdf-producer": "miliyaw cengse",
"exif-pdf-version": "PDF kese baziyong",
"exif-pdf-encrypted": "pamimatu",
diff --git a/www/wiki/extensions/PdfHandler/i18n/bg.json b/www/wiki/extensions/PdfHandler/i18n/bg.json
index e04fd36b..eb7322a1 100644
--- a/www/wiki/extensions/PdfHandler/i18n/bg.json
+++ b/www/wiki/extensions/PdfHandler/i18n/bg.json
@@ -3,10 +3,11 @@
"authors": [
"DCLXVI",
"Stanqo",
- "Turin"
+ "Turin",
+ "StanProg"
]
},
- "pdf_no_metadata": "невъзможно е да бъдат извлечени метаданни от PDF",
+ "pdf_no_metadata": "Извличането метаданни от PDF е невъзможно.",
"pdf_page_error": "Номерът на страница е извън обхвата",
"exif-pdf-encrypted": "Криптиране",
"exif-pdf-pagesize": "Размер на страницата"
diff --git a/www/wiki/extensions/PdfHandler/i18n/ca.json b/www/wiki/extensions/PdfHandler/i18n/ca.json
index c31ceae9..499e9199 100644
--- a/www/wiki/extensions/PdfHandler/i18n/ca.json
+++ b/www/wiki/extensions/PdfHandler/i18n/ca.json
@@ -2,12 +2,13 @@
"@metadata": {
"authors": [
"Aleator",
- "Ssola"
+ "Ssola",
+ "Fitoschido"
]
},
"pdf-desc": "Gestor per a visualitzar arxius PDF en mode imatge",
"pdf-file-page-warning": "PDF és un format complex que en alguns casos podria exposar la vostra informació privada. Assegureu-vos de configurar el lector de PDF d'una forma segura.",
- "pdf-file-page-warning-header": "Consideracions de privacitat",
+ "pdf-file-page-warning-header": "Consideracions de privadesa",
"pdf-file-page-warning-footer": "Aquest problema no es específic d'aquest fitxer en particular, sinó un problema general amb el format PDF.",
"pdf-file-page-warning-info": "Més informació sobre aquest problema.",
"pdf_no_metadata": "No s'han pogut obtenir metadades del PDF",
diff --git a/www/wiki/extensions/PdfHandler/i18n/de.json b/www/wiki/extensions/PdfHandler/i18n/de.json
index 144ec9fb..162605d2 100644
--- a/www/wiki/extensions/PdfHandler/i18n/de.json
+++ b/www/wiki/extensions/PdfHandler/i18n/de.json
@@ -7,15 +7,15 @@
"ThePiscin"
]
},
- "pdf-desc": "Stellt eine Schnittstelle zur Ansicht von PDF-Dateien im Bildermodus bereit",
- "pdf-file-page-warning": "PDF ist ein komplexes Dateiformat, das in bestimmten Fällen einige deiner privaten Informationen preisgeben kann. Achte darauf, dass dein PDF-Betrachter entsprechend sicher konfiguriert ist.",
+ "pdf-desc": "Ermöglicht die Anzeige von PDF-Dateien im Bildermodus",
+ "pdf-file-page-warning": "PDF ist ein komplexes Dateiformat, das in bestimmten Fällen private Informationen preisgeben kann. Es muss darauf geachtet werden, dass der PDF-Betrachter entsprechend sicher konfiguriert ist.",
"pdf-file-page-warning-header": "Hinweise zum Datenschutz",
"pdf-file-page-warning-footer": "Dieses Problem ist nicht auf diese Datei beschränkt, sondern ist ein generelles Problem mit dem PDF-Dateiformat.",
"pdf-file-page-warning-info": "Erfahre mehr über dieses Problem.",
- "pdf_no_metadata": "Keine Metadaten im PDF vorhanden.",
- "pdf_page_error": "Seitenzahl außerhalb des Dokumentes.",
+ "pdf_no_metadata": "Es können keine Metadaten aus der PDF-Datei abgerufen werden.",
+ "pdf_page_error": "Die Seitenzahl ist höher als die Anzahl der Seiten der PDF-Datei.",
"exif-pdf-producer": "Umwandlungsprogramm",
"exif-pdf-version": "Version des PDF-Formats",
"exif-pdf-encrypted": "Verschlüsselt",
- "exif-pdf-pagesize": "Seitengröße"
+ "exif-pdf-pagesize": "Papierformat"
}
diff --git a/www/wiki/extensions/PdfHandler/i18n/is.json b/www/wiki/extensions/PdfHandler/i18n/is.json
new file mode 100644
index 00000000..92cccd8b
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/i18n/is.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sveinn í Felli"
+ ]
+ },
+ "exif-pdf-encrypted": "Dulritað",
+ "exif-pdf-pagesize": "Blaðsíðustærð"
+}
diff --git a/www/wiki/extensions/PdfHandler/i18n/ko.json b/www/wiki/extensions/PdfHandler/i18n/ko.json
index 4c55b457..902bbed0 100644
--- a/www/wiki/extensions/PdfHandler/i18n/ko.json
+++ b/www/wiki/extensions/PdfHandler/i18n/ko.json
@@ -3,10 +3,11 @@
"authors": [
"Kwj2772",
"아라",
- "Ykhwong"
+ "Ykhwong",
+ "Garam"
]
},
- "pdf-desc": "PDF 파일을 이미지 방식으로 볼 수 있게 하는 핸들러",
+ "pdf-desc": "PDF 파일을 영상 방식으로 볼 수 있게 하는 조정기",
"pdf-file-page-warning-info": "이 문제에 대해 더 알아보세요.",
"pdf_no_metadata": "PDF 파일에서 메타데이터를 추출할 수 없습니다.",
"pdf_page_error": "쪽수가 범위 안에 있지 않습니다.",
diff --git a/www/wiki/extensions/PdfHandler/i18n/la.json b/www/wiki/extensions/PdfHandler/i18n/la.json
new file mode 100644
index 00000000..de5e7f12
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/i18n/la.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lesgles"
+ ]
+ },
+ "exif-pdf-pagesize": "Magnitudo paginae"
+}
diff --git a/www/wiki/extensions/PdfHandler/i18n/mwl.json b/www/wiki/extensions/PdfHandler/i18n/mwl.json
new file mode 100644
index 00000000..bd07bc12
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/i18n/mwl.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "pdf-desc": "Cuntrolador pa ber fexeiros PDF an modo de eimaige",
+ "pdf-file-page-warning": "L PDF ye un formato cumplexo que puode sponer alguas de las sues anformaçones pribadas, an alguns causos. Certefique-se de cunfigurar l sou lheitor de PDF dua forma sigura.",
+ "pdf-file-page-warning-header": "Cunsidraçones de pribacidade",
+ "pdf-file-page-warning-footer": "Este porblema nó ye specífeco pa este tipo de fexeiro, mas un porblema giral cul formato PDF.",
+ "pdf-file-page-warning-info": "Coincer más subre este porblema.",
+ "pdf_no_metadata": "Nó fui possible outener ls metadados de l PDF.",
+ "pdf_page_error": "Númaro de páigina fuora de l anterbalo.",
+ "exif-pdf-producer": "Porgrama de cumberson",
+ "exif-pdf-version": "Berson de l formato PDF",
+ "exif-pdf-encrypted": "Criptografado",
+ "exif-pdf-pagesize": "Tamanho de la páigina"
+}
diff --git a/www/wiki/extensions/PdfHandler/i18n/nb.json b/www/wiki/extensions/PdfHandler/i18n/nb.json
index 1dcd13ac..c9eacfda 100644
--- a/www/wiki/extensions/PdfHandler/i18n/nb.json
+++ b/www/wiki/extensions/PdfHandler/i18n/nb.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Jsoby",
- "Danmichaelo"
+ "Danmichaelo",
+ "Jon Harald Søby"
]
},
"pdf-desc": "Håndtering av PDF-visning i bildemodus",
diff --git a/www/wiki/extensions/PdfHandler/i18n/pt.json b/www/wiki/extensions/PdfHandler/i18n/pt.json
index 6cc627ad..aa770c83 100644
--- a/www/wiki/extensions/PdfHandler/i18n/pt.json
+++ b/www/wiki/extensions/PdfHandler/i18n/pt.json
@@ -8,7 +8,7 @@
]
},
"pdf-desc": "Controlador do visionamento de ficheiros PDF em modo de imagem",
- "pdf-file-page-warning": "O PDF é um formato complexo que pode expor algumas das suas informações privadas, em alguns casos. Certifique-se de configurar o seu visualizador de PDF de uma forma segura.",
+ "pdf-file-page-warning": "O PDF é um formato complexo que pode expor algumas informações privadas em certos casos. Certifique-se de que configura o seu leitor de PDF de forma a ficar seguro.",
"pdf-file-page-warning-header": "Considerações de privacidade",
"pdf-file-page-warning-footer": "Este problema não é específico para este tipo de ficheiro, mas uma questão geral com o formato PDF.",
"pdf-file-page-warning-info": "Saiba mais sobre este problema.",
diff --git a/www/wiki/extensions/PdfHandler/i18n/tay.json b/www/wiki/extensions/PdfHandler/i18n/tay.json
index 75d23f8f..f45c3df6 100644
--- a/www/wiki/extensions/PdfHandler/i18n/tay.json
+++ b/www/wiki/extensions/PdfHandler/i18n/tay.json
@@ -4,5 +4,8 @@
"Hitaypayan"
]
},
- "exif-pdf-encrypted": "Wal twangan psawsu’"
+ "pdf-file-page-warning-header": "Pspngun sa zyuwaw na lnqing",
+ "exif-pdf-producer": "Iyugiy cngs’",
+ "exif-pdf-encrypted": "Wal twangan psawsu’",
+ "exif-pdf-pagesize": "Sspngan kinkrahu’ na zzngayan"
}
diff --git a/www/wiki/extensions/PdfHandler/i18n/zh-hant.json b/www/wiki/extensions/PdfHandler/i18n/zh-hant.json
index c875032d..b4942c89 100644
--- a/www/wiki/extensions/PdfHandler/i18n/zh-hant.json
+++ b/www/wiki/extensions/PdfHandler/i18n/zh-hant.json
@@ -4,7 +4,8 @@
"Justincheng12345",
"Mark85296341",
"Simon Shek",
- "Cwlin0416"
+ "Cwlin0416",
+ "Kly"
]
},
"pdf-desc": "使用圖片模式檢視 PDF 檔案的處理程式。",
@@ -12,7 +13,7 @@
"pdf-file-page-warning-header": "隱私考量",
"pdf-file-page-warning-footer": "此問題未針對特定檔檔案,是 PDF 格式的一般問題。",
"pdf-file-page-warning-info": "了解更多有關此問題。",
- "pdf_no_metadata": "無法在 PDF 中取得資料定義。",
+ "pdf_no_metadata": "無法在 PDF 中取得詮釋資料。",
"pdf_page_error": "頁數超出範圍。",
"exif-pdf-producer": "轉換程式",
"exif-pdf-version": "PDF 格式版本",
diff --git a/www/wiki/extensions/PdfHandler/includes/CreatePdfThumbnailsJob.php b/www/wiki/extensions/PdfHandler/includes/CreatePdfThumbnailsJob.php
new file mode 100644
index 00000000..65edb8ee
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/includes/CreatePdfThumbnailsJob.php
@@ -0,0 +1,130 @@
+<?php
+
+class CreatePdfThumbnailsJob extends Job {
+ /**
+ * Flags for thumbnail jobs
+ */
+ const BIG_THUMB = 1;
+ const SMALL_THUMB = 2;
+
+ /**
+ * Construct a thumbnail job
+ *
+ * @param Title $title Title object
+ * @param array $params Associative array of options:
+ * page: page number for which the thumbnail will be created
+ * jobtype: CreatePDFThumbnailsJob::BIG_THUMB or CreatePDFThumbnailsJob::SMALL_THUMB
+ * BIG_THUMB will create a thumbnail visible for full thumbnail view,
+ * SMALL_THUMB will create a thumbnail shown in "previous page"/"next page" boxes
+ */
+ public function __construct( $title, $params ) {
+ parent::__construct( 'createPdfThumbnailsJob', $title, $params );
+ }
+
+ /**
+ * Run a thumbnail job on a given PDF file.
+ * @return bool true
+ */
+ public function run() {
+ if ( !isset( $this->params['page'] ) ) {
+ wfDebugLog( 'thumbnails', 'A page for thumbnails job of ' . $this->title->getText() .
+ ' was not specified! That should never happen!' );
+ return true; // no page set? that should never happen
+ }
+
+ $file = wfLocalFile( $this->title ); // we just want a local file
+ if ( !$file ) {
+ return true; // Just silently fail, perhaps the file was already deleted, don't bother
+ }
+
+ switch ( $this->params['jobtype'] ) {
+ case self::BIG_THUMB:
+ global $wgImageLimits;
+ // Ignore user preferences, do default thumbnails
+ // everything here shamelessy copied and reused from includes/ImagePage.php
+ $sizeSel = User::getDefaultOption( 'imagesize' );
+
+ // The user offset might still be incorrect, specially if
+ // $wgImageLimits got changed (see bug #8858).
+ if ( !isset( $wgImageLimits[$sizeSel] ) ) {
+ // Default to the first offset in $wgImageLimits
+ $sizeSel = 0;
+ }
+ $max = $wgImageLimits[$sizeSel];
+ $maxWidth = $max[0];
+ $maxHeight = $max[1];
+
+ $width_orig = $file->getWidth( $this->params['page'] );
+ $width = $width_orig;
+ $height_orig = $file->getHeight( $this->params['page'] );
+ $height = $height_orig;
+ if ( $width > $maxWidth || $height > $maxHeight ) {
+ // Calculate the thumbnail size.
+ // First case, the limiting factor is the width, not the height.
+ if ( $width / $height >= $maxWidth / $maxHeight ) {
+ // $height = round( $height * $maxWidth / $width );
+ $width = $maxWidth;
+ // Note that $height <= $maxHeight now.
+ } else {
+ $newwidth = floor( $width * $maxHeight / $height );
+ // $height = round( $height * $newwidth / $width );
+ $width = $newwidth;
+ // Note that $height <= $maxHeight now, but might not be identical
+ // because of rounding.
+ }
+ $transformParams = [ 'page' => $this->params['page'], 'width' => $width ];
+ $file->transform( $transformParams );
+ }
+ break;
+
+ case self::SMALL_THUMB:
+ Linker::makeThumbLinkObj( $this->title, $file, '', '', 'none',
+ [ 'page' => $this->params['page'] ] );
+ break;
+ }
+
+ return true;
+ }
+
+ /**
+ * @param UploadBase $upload
+ * @param string $mime
+ * @param string &$error
+ * @return bool
+ */
+ public static function insertJobs( $upload, $mime, &$error ) {
+ global $wgPdfCreateThumbnailsInJobQueue;
+ if ( !$wgPdfCreateThumbnailsInJobQueue ) {
+ return true;
+ }
+ $magic = MediaWiki\MediaWikiServices::getInstance()->getMimeAnalyzer();
+ if ( !$magic->isMatchingExtension( 'pdf', $mime ) ) {
+ return true; // not a PDF, abort
+ }
+
+ $title = $upload->getTitle();
+ $uploadFile = $upload->getLocalFile();
+ if ( is_null( $uploadFile ) ) {
+ wfDebugLog( 'thumbnails', '$uploadFile seems to be null, should never happen...' );
+ return true; // should never happen, but it's better to be secure
+ }
+
+ $metadata = $uploadFile->getMetadata();
+ $unserialized = unserialize( $metadata );
+ $pages = intval( $unserialized['Pages'] );
+
+ $jobs = [];
+ for ( $i = 1; $i <= $pages; $i++ ) {
+ $jobs[] = new CreatePdfThumbnailsJob(
+ $title,
+ [ 'page' => $i, 'jobtype' => self::BIG_THUMB ]
+ );
+ $jobs[] = new CreatePdfThumbnailsJob(
+ $title,
+ [ 'page' => $i, 'jobtype' => self::SMALL_THUMB ]
+ );
+ }
+ JobQueueGroup::singleton()->push( $jobs );
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/PdfHandler/includes/PdfHandler.php b/www/wiki/extensions/PdfHandler/includes/PdfHandler.php
new file mode 100644
index 00000000..fd40e4ad
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/includes/PdfHandler.php
@@ -0,0 +1,453 @@
+<?php
+/**
+ * Copyright © 2007 Martin Seidel (Xarax) <jodeldi@gmx.de>
+ *
+ * Inspired by djvuhandler from Tim Starling
+ * Modified and written by Xarax
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+class PdfHandler extends ImageHandler {
+ public static $messages = [
+ 'main' => 'pdf-file-page-warning',
+ 'header' => 'pdf-file-page-warning-header',
+ 'info' => 'pdf-file-page-warning-info',
+ 'footer' => 'pdf-file-page-warning-footer',
+ ];
+
+ /**
+ * @return bool
+ */
+ function isEnabled() {
+ global $wgPdfProcessor, $wgPdfPostProcessor, $wgPdfInfo;
+
+ if ( !isset( $wgPdfProcessor ) || !isset( $wgPdfPostProcessor ) || !isset( $wgPdfInfo ) ) {
+ wfDebug( "PdfHandler is disabled, please set the following\n" );
+ wfDebug( "variables in LocalSettings.php:\n" );
+ wfDebug( "\$wgPdfProcessor, \$wgPdfPostProcessor, \$wgPdfInfo\n" );
+ return false;
+ }
+ return true;
+ }
+
+ /**
+ * @param File $file
+ * @return bool
+ */
+ function mustRender( $file ) {
+ return true;
+ }
+
+ /**
+ * @param File $file
+ * @return bool
+ */
+ function isMultiPage( $file ) {
+ return true;
+ }
+
+ /**
+ * @param string $name
+ * @param string $value
+ * @return bool
+ */
+ function validateParam( $name, $value ) {
+ if ( $name === 'page' && trim( $value ) !== (string)intval( $value ) ) {
+ // Extra junk on the end of page, probably actually a caption
+ // e.g. [[File:Foo.pdf|thumb|Page 3 of the document shows foo]]
+ return false;
+ }
+ if ( in_array( $name, [ 'width', 'height', 'page' ] ) ) {
+ return ( $value > 0 );
+ }
+ return false;
+ }
+
+ /**
+ * @param array $params
+ * @return bool|string
+ */
+ function makeParamString( $params ) {
+ $page = isset( $params['page'] ) ? $params['page'] : 1;
+ if ( !isset( $params['width'] ) ) {
+ return false;
+ }
+ return "page{$page}-{$params['width']}px";
+ }
+
+ /**
+ * @param string $str
+ * @return array|bool
+ */
+ function parseParamString( $str ) {
+ $m = [];
+
+ if ( preg_match( '/^page(\d+)-(\d+)px$/', $str, $m ) ) {
+ return [ 'width' => $m[2], 'page' => $m[1] ];
+ }
+
+ return false;
+ }
+
+ /**
+ * @param array $params
+ * @return array
+ */
+ function getScriptParams( $params ) {
+ return [
+ 'width' => $params['width'],
+ 'page' => $params['page'],
+ ];
+ }
+
+ /**
+ * @return array
+ */
+ function getParamMap() {
+ return [
+ 'img_width' => 'width',
+ 'img_page' => 'page',
+ ];
+ }
+
+ /**
+ * @param int $width
+ * @param int $height
+ * @param string $msg
+ * @return MediaTransformError
+ */
+ protected function doThumbError( $width, $height, $msg ) {
+ return new MediaTransformError( 'thumbnail_error',
+ $width, $height, wfMessage( $msg )->inContentLanguage()->text() );
+ }
+
+ /**
+ * @param File $image
+ * @param string $dstPath
+ * @param string $dstUrl
+ * @param array $params
+ * @param int $flags
+ * @return MediaTransformError|MediaTransformOutput|ThumbnailImage|TransformParameterError
+ */
+ function doTransform( $image, $dstPath, $dstUrl, $params, $flags = 0 ) {
+ global $wgPdfProcessor, $wgPdfPostProcessor, $wgPdfHandlerDpi, $wgPdfHandlerJpegQuality;
+
+ if ( !$this->normaliseParams( $image, $params ) ) {
+ return new TransformParameterError( $params );
+ }
+
+ $width = (int)$params['width'];
+ $height = (int)$params['height'];
+ $page = (int)$params['page'];
+
+ if ( $page > $this->pageCount( $image ) ) {
+ return $this->doThumbError( $width, $height, 'pdf_page_error' );
+ }
+
+ if ( $flags & self::TRANSFORM_LATER ) {
+ return new ThumbnailImage( $image, $dstUrl, false, [
+ 'width' => $width,
+ 'height' => $height,
+ 'page' => $page,
+ ] );
+ }
+
+ if ( !wfMkdirParents( dirname( $dstPath ), null, __METHOD__ ) ) {
+ return $this->doThumbError( $width, $height, 'thumbnail_dest_directory' );
+ }
+
+ // Thumbnail extraction is very inefficient for large files.
+ // Provide a way to pool count limit the number of downloaders.
+ if ( $image->getSize() >= 1e7 ) { // 10MB
+ $work = new PoolCounterWorkViaCallback( 'GetLocalFileCopy', sha1( $image->getName() ),
+ [
+ 'doWork' => function () use ( $image ) {
+ return $image->getLocalRefPath();
+ }
+ ]
+ );
+ $srcPath = $work->execute();
+ } else {
+ $srcPath = $image->getLocalRefPath();
+ }
+
+ if ( $srcPath === false ) { // could not download original
+ return $this->doThumbError( $width, $height, 'filemissing' );
+ }
+
+ $cmd = '(' . wfEscapeShellArg(
+ $wgPdfProcessor,
+ "-sDEVICE=jpeg",
+ "-sOutputFile=-",
+ "-dFirstPage={$page}",
+ "-dLastPage={$page}",
+ "-dSAFER",
+ "-r{$wgPdfHandlerDpi}",
+ "-dBATCH",
+ "-dNOPAUSE",
+ "-q",
+ $srcPath
+ );
+ $cmd .= " | " . wfEscapeShellArg(
+ $wgPdfPostProcessor,
+ "-depth",
+ "8",
+ "-quality",
+ $wgPdfHandlerJpegQuality,
+ "-resize",
+ $width,
+ "-",
+ $dstPath
+ );
+ $cmd .= ")";
+
+ wfDebug( __METHOD__ . ": $cmd\n" );
+ $retval = '';
+ $err = wfShellExecWithStderr( $cmd, $retval );
+
+ $removed = $this->removeBadFile( $dstPath, $retval );
+
+ if ( $retval != 0 || $removed ) {
+ wfDebugLog( 'thumbnail',
+ sprintf( 'thumbnail failed on %s: error %d "%s" from "%s"',
+ wfHostname(), $retval, trim( $err ), $cmd ) );
+ return new MediaTransformError( 'thumbnail_error', $width, $height, $err );
+ } else {
+ return new ThumbnailImage( $image, $dstUrl, $dstPath, [
+ 'width' => $width,
+ 'height' => $height,
+ 'page' => $page,
+ ] );
+ }
+ }
+
+ /**
+ * @param File $image
+ * @param string $path
+ * @return PdfImage
+ * @suppress PhanUndeclaredProperty
+ */
+ function getPdfImage( $image, $path ) {
+ if ( !$image ) {
+ $pdfimg = new PdfImage( $path );
+ } elseif ( !isset( $image->pdfImage ) ) {
+ $pdfimg = $image->pdfImage = new PdfImage( $path );
+ } else {
+ $pdfimg = $image->pdfImage;
+ }
+
+ return $pdfimg;
+ }
+
+ /**
+ * @param File $image
+ * @return bool|array
+ * @suppress PhanUndeclaredProperty
+ */
+ function getMetaArray( $image ) {
+ if ( isset( $image->pdfMetaArray ) ) {
+ return $image->pdfMetaArray;
+ }
+
+ $metadata = $image->getMetadata();
+
+ if ( !$this->isMetadataValid( $image, $metadata ) ) {
+ wfDebug( "Pdf metadata is invalid or missing, should have been fixed in upgradeRow\n" );
+ return false;
+ }
+
+ $work = new PoolCounterWorkViaCallback(
+ 'PdfHandler-unserialize-metadata',
+ $image->getName(),
+ [
+ /**
+ * @suppress PhanUndeclaredProperty
+ */
+ 'doWork' => function () use ( $image, $metadata ) {
+ wfSuppressWarnings();
+ $image->pdfMetaArray = unserialize( $metadata );
+ wfRestoreWarnings();
+ },
+ ]
+ );
+ $work->execute();
+
+ return $image->pdfMetaArray;
+ }
+
+ /**
+ * @param File $image
+ * @param string $path
+ * @return array|bool
+ */
+ function getImageSize( $image, $path ) {
+ return $this->getPdfImage( $image, $path )->getImageSize();
+ }
+
+ /**
+ * @param string $ext
+ * @param string $mime
+ * @param null $params
+ * @return array
+ */
+ function getThumbType( $ext, $mime, $params = null ) {
+ global $wgPdfOutputExtension;
+ static $mime;
+
+ if ( !isset( $mime ) ) {
+ $magic = MediaWiki\MediaWikiServices::getInstance()->getMimeAnalyzer();
+ $mime = $magic->guessTypesForExtension( $wgPdfOutputExtension );
+ }
+ return [ $wgPdfOutputExtension, $mime ];
+ }
+
+ /**
+ * @param File $image
+ * @param string $path
+ * @return string
+ */
+ function getMetadata( $image, $path ) {
+ return serialize( $this->getPdfImage( $image, $path )->retrieveMetaData() );
+ }
+
+ /**
+ * @param File $image
+ * @param string $metadata
+ * @return bool
+ */
+ function isMetadataValid( $image, $metadata ) {
+ if ( !$metadata || $metadata === serialize( [] ) ) {
+ return self::METADATA_BAD;
+ } elseif ( strpos( $metadata, 'mergedMetadata' ) === false ) {
+ return self::METADATA_COMPATIBLE;
+ }
+ return self::METADATA_GOOD;
+ }
+
+ /**
+ * @param File $image
+ * @param bool|IContextSource $context Context to use (optional)
+ * @return bool|array
+ */
+ function formatMetadata( $image, $context = false ) {
+ $meta = $image->getMetadata();
+
+ if ( !$meta ) {
+ return false;
+ }
+ wfSuppressWarnings();
+ $meta = unserialize( $meta );
+ wfRestoreWarnings();
+
+ if ( !isset( $meta['mergedMetadata'] )
+ || !is_array( $meta['mergedMetadata'] )
+ || count( $meta['mergedMetadata'] ) < 1
+ ) {
+ return false;
+ }
+
+ // Inherited from MediaHandler.
+ return $this->formatMetadataHelper( $meta['mergedMetadata'], $context );
+ }
+
+ /**
+ * @param File $image
+ * @return bool|int
+ */
+ function pageCount( File $image ) {
+ $info = $this->getDimensionInfo( $image );
+
+ return $info ? $info['pageCount'] : false;
+ }
+
+ /**
+ * @param File $image
+ * @param int $page
+ * @return array|bool
+ */
+ function getPageDimensions( File $image, $page ) {
+ $index = $page; // MW starts pages at 1, as they are stored here
+
+ $info = $this->getDimensionInfo( $image );
+ if ( $info && isset( $info['dimensionsByPage'][$index] ) ) {
+ return $info['dimensionsByPage'][$index];
+ }
+
+ return false;
+ }
+
+ protected function getDimensionInfo( File $file ) {
+ $cache = ObjectCache::getMainWANInstance();
+ return $cache->getWithSetCallback(
+ $cache->makeKey( 'file-pdf', 'dimensions', $file->getSha1() ),
+ $cache::TTL_INDEFINITE,
+ function () use ( $file ) {
+ $data = $this->getMetaArray( $file );
+ if ( !$data || !isset( $data['Pages'] ) ) {
+ return false;
+ }
+ unset( $data['text'] ); // lower peak RAM
+
+ $dimsByPage = [];
+ $count = intval( $data['Pages'] );
+ for ( $i = 1; $i <= $count; $i++ ) {
+ $dimsByPage[$i] = PdfImage::getPageSize( $data, $i );
+ }
+
+ return [ 'pageCount' => $count, 'dimensionsByPage' => $dimsByPage ];
+ },
+ [ 'pcTTL' => $cache::TTL_INDEFINITE ]
+ );
+ }
+
+ /**
+ * @param File $image
+ * @param int $page
+ * @return bool
+ */
+ function getPageText( File $image, $page ) {
+ $data = $this->getMetaArray( $image );
+ if ( !$data || !isset( $data['text'] ) || !isset( $data['text'][$page - 1] ) ) {
+ return false;
+ }
+ return $data['text'][$page - 1];
+ }
+
+ /**
+ * Adds a warning about PDFs being potentially dangerous to the file
+ * page. Multiple messages with this base will be used.
+ * @param File $file
+ * @return array
+ */
+ function getWarningConfig( $file ) {
+ return [
+ 'messages' => self::$messages,
+ 'link' => '//www.mediawiki.org/wiki/Special:MyLanguage/Help:Security/PDF_files',
+ 'module' => 'pdfhandler.messages',
+ ];
+ }
+
+ /**
+ * Register a module with the warning messages in it.
+ * @param ResourceLoader &$resourceLoader
+ */
+ static function registerWarningModule( &$resourceLoader ) {
+ $resourceLoader->register( 'pdfhandler.messages', [
+ 'messages' => array_values( self::$messages ),
+ ] );
+ }
+}
diff --git a/www/wiki/extensions/PdfHandler/includes/PdfImage.php b/www/wiki/extensions/PdfHandler/includes/PdfImage.php
new file mode 100644
index 00000000..0fdefc96
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/includes/PdfImage.php
@@ -0,0 +1,329 @@
+<?php
+/**
+ *
+ * Copyright © 2007 Xarax <jodeldi@gmx.de>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+use MediaWiki\Logger\LoggerFactory;
+use MediaWiki\Shell\Shell;
+use UtfNormal\Validator;
+
+/**
+ * inspired by djvuimage from Brion Vibber
+ * modified and written by xarax
+ */
+
+class PdfImage {
+
+ /**
+ * @var string
+ */
+ private $mFilename;
+
+ /**
+ * @param string $filename
+ */
+ function __construct( $filename ) {
+ $this->mFilename = $filename;
+ }
+
+ /**
+ * @return bool
+ */
+ public function isValid() {
+ return true;
+ }
+
+ /**
+ * @return array|bool
+ */
+ public function getImageSize() {
+ $data = $this->retrieveMetadata();
+ $size = self::getPageSize( $data, 1 );
+
+ if ( $size ) {
+ $width = $size['width'];
+ $height = $size['height'];
+ return [ $width, $height, 'Pdf',
+ "width=\"$width\" height=\"$height\"" ];
+ }
+ return false;
+ }
+
+ /**
+ * @param array $data
+ * @param int $page
+ * @return array|bool
+ */
+ public static function getPageSize( $data, $page ) {
+ global $wgPdfHandlerDpi;
+
+ if ( isset( $data['pages'][$page]['Page size'] ) ) {
+ $o = $data['pages'][$page]['Page size'];
+ } elseif ( isset( $data['Page size'] ) ) {
+ $o = $data['Page size'];
+ } else {
+ $o = false;
+ }
+
+ if ( $o ) {
+ if ( isset( $data['pages'][$page]['Page rot'] ) ) {
+ $r = $data['pages'][$page]['Page rot'];
+ } elseif ( isset( $data['Page rot'] ) ) {
+ $r = $data['Page rot'];
+ } else {
+ $r = 0;
+ }
+ $size = explode( 'x', $o, 2 );
+
+ if ( $size ) {
+ $width = intval( trim( $size[0] ) / 72 * $wgPdfHandlerDpi );
+ $height = explode( ' ', trim( $size[1] ), 2 );
+ $height = intval( trim( $height[0] ) / 72 * $wgPdfHandlerDpi );
+ if ( ( $r / 90 ) & 1 ) {
+ // Swap width and height for landscape pages
+ $t = $width;
+ $width = $height;
+ $height = $t;
+ }
+
+ return [
+ 'width' => $width,
+ 'height' => $height
+ ];
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * @return array|bool|null
+ */
+ public function retrieveMetaData() {
+ global $wgPdfInfo, $wgPdftoText;
+
+ if ( $wgPdfInfo ) {
+ // Note in poppler 0.26 the -meta and page data options worked together,
+ // but as of poppler 0.48 they must be queried separately.
+ // https://bugs.freedesktop.org/show_bug.cgi?id=96801
+ $cmdMeta = [
+ $wgPdfInfo,
+ '-enc', 'UTF-8', # Report metadata as UTF-8 text...
+ '-meta', # Report XMP metadata
+ $this->mFilename,
+ ];
+ $resultMeta = Shell::command( $cmdMeta )
+ ->execute();
+
+ $cmdPages = [
+ $wgPdfInfo,
+ '-enc', 'UTF-8', # Report metadata as UTF-8 text...
+ '-l', '9999999', # Report page sizes for all pages
+ $this->mFilename,
+ ];
+ $resultPages = Shell::command( $cmdPages )
+ ->execute();
+
+ $dump = $resultMeta->getStdout() . $resultPages->getStdout();
+ $data = $this->convertDumpToArray( $dump );
+ } else {
+ $data = null;
+ }
+
+ // Read text layer
+ if ( isset( $wgPdftoText ) ) {
+ $cmd = [ $wgPdftoText, $this->mFilename, '-' ];
+ $result = Shell::command( $cmd )
+ ->execute();
+ $retval = $result->getExitCode();
+ $txt = $result->getStdout();
+ if ( $retval == 0 ) {
+ $txt = str_replace( "\r\n", "\n", $txt );
+ $pages = explode( "\f", $txt );
+ foreach ( $pages as $page => $pageText ) {
+ // Get rid of invalid UTF-8, strip control characters
+ // Note we need to do this per page, as \f page feed would be stripped.
+ $pages[$page] = Validator::cleanUp( $pageText );
+ }
+ $data['text'] = $pages;
+ }
+ }
+ return $data;
+ }
+
+ /**
+ * @param string $dump
+ * @return array|bool
+ */
+ protected function convertDumpToArray( $dump ) {
+ if ( strval( $dump ) == '' ) {
+ return false;
+ }
+
+ $lines = explode( "\n", $dump );
+ $data = [];
+
+ // Metadata is always the last item, and spans multiple lines.
+ $inMetadata = false;
+
+ // Basically this loop will go through each line, splitting key value
+ // pairs on the colon, until it gets to a "Metadata:\n" at which point
+ // it will gather all remaining lines into the xmp key.
+ foreach ( $lines as $line ) {
+ if ( $inMetadata ) {
+ // Handle XMP differently due to diffence in line break
+ $data['xmp'] .= "\n$line";
+ continue;
+ }
+ $bits = explode( ':', $line, 2 );
+ if ( count( $bits ) > 1 ) {
+ $key = trim( $bits[0] );
+ if ( $key === 'Metadata' ) {
+ $inMetadata = true;
+ $data['xmp'] = '';
+ continue;
+ }
+ $value = trim( $bits[1] );
+ $matches = [];
+ // "Page xx rot" will be in poppler 0.20's pdfinfo output
+ // See https://bugs.freedesktop.org/show_bug.cgi?id=41867
+ if ( preg_match( '/^Page +(\d+) (size|rot)$/', $key, $matches ) ) {
+ $data['pages'][$matches[1]][$matches[2] == 'size' ? 'Page size' : 'Page rot'] = $value;
+ } else {
+ $data[$key] = $value;
+ }
+ }
+ }
+ $data = $this->postProcessDump( $data );
+ return $data;
+ }
+
+ /**
+ * Postprocess the metadata (convert xmp into useful form, etc)
+ *
+ * This is used to generate the metadata table at the bottom
+ * of the image description page.
+ *
+ * @param array $data metadata
+ * @return array post-processed metadata
+ */
+ protected function postProcessDump( array $data ) {
+ $meta = new BitmapMetadataHandler();
+ $items = [];
+ foreach ( $data as $key => $val ) {
+ switch ( $key ) {
+ case 'Title':
+ $items['ObjectName'] = $val;
+ break;
+ case 'Subject':
+ $items['ImageDescription'] = $val;
+ break;
+ case 'Keywords':
+ // Sometimes we have empty keywords. This seems
+ // to be a product of how pdfinfo deals with keywords
+ // with spaces in them. Filter such empty keywords
+ $keyList = array_filter( explode( ' ', $val ) );
+ if ( count( $keyList ) > 0 ) {
+ $items['Keywords'] = $keyList;
+ }
+ break;
+ case 'Author':
+ $items['Artist'] = $val;
+ break;
+ case 'Creator':
+ // Program used to create file.
+ // Different from program used to convert to pdf.
+ $items['Software'] = $val;
+ break;
+ case 'Producer':
+ // Conversion program
+ $items['pdf-Producer'] = $val;
+ break;
+ case 'ModTime':
+ $timestamp = wfTimestamp( TS_EXIF, $val );
+ if ( $timestamp ) {
+ // 'if' is just paranoia
+ $items['DateTime'] = $timestamp;
+ }
+ break;
+ case 'CreationTime':
+ $timestamp = wfTimestamp( TS_EXIF, $val );
+ if ( $timestamp ) {
+ $items['DateTimeDigitized'] = $timestamp;
+ }
+ break;
+ // These last two (version and encryption) I was unsure
+ // if we should include in the table, since they aren't
+ // all that useful to editors. I leaned on the side
+ // of including. However not including if file
+ // is optimized/linearized since that is really useless
+ // to an editor.
+ case 'PDF version':
+ $items['pdf-Version'] = $val;
+ break;
+ case 'Encrypted':
+ // @todo: The value isn't i18n-ised. The appropriate
+ // place to do that is in FormatMetadata.php
+ // should add a hook a there.
+ // For reference, if encrypted this fields value looks like:
+ // "yes (print:yes copy:no change:no addNotes:no)"
+ $items['pdf-Encrypted'] = $val;
+ break;
+ // Note 'pages' and 'Pages' are different keys (!)
+ case 'pages':
+ // A pdf document can have multiple sized pages in it.
+ // (However 95% of the time, all pages are the same size)
+ // get a list of all the unique page sizes in document.
+ // This doesn't do anything with rotation as of yet,
+ // mostly because I am unsure of what a good way to
+ // present that information to the user would be.
+ $pageSizes = [];
+ foreach ( $val as $page ) {
+ if ( isset( $page['Page size'] ) ) {
+ $pageSizes[$page['Page size']] = true;
+ }
+ }
+
+ $pageSizeArray = array_keys( $pageSizes );
+ if ( count( $pageSizeArray ) > 0 ) {
+ $items['pdf-PageSize'] = $pageSizeArray;
+ }
+ break;
+ }
+
+ }
+ $meta->addMetadata( $items, 'native' );
+
+ if ( isset( $data['xmp'] ) && function_exists( 'xml_parser_create_ns' ) ) {
+ // func exists verifies that the xml extension required for XMPReader
+ // is present (Almost always is present)
+ // @todo: This only handles generic xmp properties. Would be improved
+ // by handling pdf xmp properties (pdf and pdfx) via XMPInfo hook.
+ $xmp = new XMPReader( LoggerFactory::getInstance( 'XMP' ) );
+ $xmp->parse( $data['xmp'] );
+ $xmpRes = $xmp->getResults();
+ foreach ( $xmpRes as $type => $xmpSection ) {
+ $meta->addMetadata( $xmpSection, $type );
+ }
+ }
+ unset( $data['xmp'] );
+ $data['mergedMetadata'] = $meta->getMetadataArray();
+ return $data;
+ }
+}
diff --git a/www/wiki/extensions/PdfHandler/tests/phan/config.php b/www/wiki/extensions/PdfHandler/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/PdfHandler/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/Poem/Gruntfile.js b/www/wiki/extensions/Poem/Gruntfile.js
index e4033e51..26ca0c16 100644
--- a/www/wiki/extensions/Poem/Gruntfile.js
+++ b/www/wiki/extensions/Poem/Gruntfile.js
@@ -17,7 +17,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/Poem/composer.json b/www/wiki/extensions/Poem/composer.json
index 021a14cb..85b14ed3 100644
--- a/www/wiki/extensions/Poem/composer.json
+++ b/www/wiki/extensions/Poem/composer.json
@@ -1,14 +1,26 @@
{
+ "require": {
+ "php": ">=5.5.9"
+ },
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/Poem/extension.json b/www/wiki/extensions/Poem/extension.json
index 3f175974..130de1a0 100644
--- a/www/wiki/extensions/Poem/extension.json
+++ b/www/wiki/extensions/Poem/extension.json
@@ -20,10 +20,7 @@
]
},
"AutoloadClasses": {
- "Poem": "Poem.class.php"
+ "Poem": "includes/Poem.php"
},
- "ParserTestFiles": [
- "poemParserTests.txt"
- ],
"manifest_version": 1
}
diff --git a/www/wiki/extensions/Poem/i18n/km.json b/www/wiki/extensions/Poem/i18n/km.json
index a0afde06..e4531936 100644
--- a/www/wiki/extensions/Poem/i18n/km.json
+++ b/www/wiki/extensions/Poem/i18n/km.json
@@ -2,8 +2,9 @@
"@metadata": {
"authors": [
"Lovekhmer",
- "Thearith"
+ "Thearith",
+ "គីមស៊្រុន"
]
},
- "poem-desc": "ដាក់ប្លាក <code>&lt;poem&gt;</code> សម្រាប់ទ្រង់ទ្រាយកំណាព្យ"
+ "poem-desc": "ដាក់ស្លាក <code>&lt;poem&gt;</code> សម្រាប់ទ្រង់ទ្រាយកំណាព្យ"
}
diff --git a/www/wiki/extensions/Poem/i18n/lb.json b/www/wiki/extensions/Poem/i18n/lb.json
index b9a89f2c..38348270 100644
--- a/www/wiki/extensions/Poem/i18n/lb.json
+++ b/www/wiki/extensions/Poem/i18n/lb.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "Robby"
+ "Robby",
+ "Les Meloures"
]
},
"poem-desc": "Setzt de <code>&lt;poem&gt;</code>-Tag fir d'Formatéierung vu Gedichter derbäi"
diff --git a/www/wiki/extensions/Poem/i18n/sr-ec.json b/www/wiki/extensions/Poem/i18n/sr-ec.json
index fab98cf7..8b80fc33 100644
--- a/www/wiki/extensions/Poem/i18n/sr-ec.json
+++ b/www/wiki/extensions/Poem/i18n/sr-ec.json
@@ -2,8 +2,9 @@
"@metadata": {
"authors": [
"Millosh",
- "Nikola Smolenski"
+ "Nikola Smolenski",
+ "Acamicamacaraca"
]
},
- "poem-desc": "Додаје <code>&lt;poem&gt;</code> ознаку за форматирање песама."
+ "poem-desc": "Додаје <code>&lt;poem&gt;</code> ознаку за обликовање песама."
}
diff --git a/www/wiki/extensions/Poem/includes/Poem.php b/www/wiki/extensions/Poem/includes/Poem.php
new file mode 100644
index 00000000..ac139f40
--- /dev/null
+++ b/www/wiki/extensions/Poem/includes/Poem.php
@@ -0,0 +1,87 @@
+<?php
+
+/**
+ * This class handles formatting poems in WikiText, specifically anything within
+ * <poem></poem> tags.
+ *
+ * @license CC0-1.0
+ * @author Nikola Smolenski <smolensk@eunet.yu>
+ */
+class Poem {
+ /**
+ * Bind the renderPoem function to the <poem> tag
+ * @param Parser $parser
+ */
+ public static function init( Parser $parser ) {
+ $parser->setHook( 'poem', [ self::class, 'renderPoem' ] );
+ }
+
+ /**
+ * Parse the text into proper poem format
+ * @param string|null $in The text inside the poem tag
+ * @param string[] $param
+ * @param Parser $parser
+ * @param PPFrame $frame
+ * @return string
+ */
+ public static function renderPoem( $in, array $param = [], Parser $parser, PPFrame $frame ) {
+ // using newlines in the text will cause the parser to add <p> tags,
+ // which may not be desired in some cases
+ $newline = isset( $param['compact'] ) ? '' : "\n";
+
+ $tag = $parser->insertStripItem( "<br />" );
+
+ // replace colons with indented spans
+ $text = preg_replace_callback( '/^(:+)(.+)$/m', [ self::class, 'indentVerse' ], $in );
+
+ // replace newlines with <br /> tags unless they are at the beginning or end
+ // of the poem
+ $text = preg_replace(
+ [ "/^\n/", "/\n$/D", "/\n/" ],
+ [ "", "", "$tag\n" ],
+ $text
+ );
+
+ // replace spaces at the beginning of a line with non-breaking spaces
+ $text = preg_replace_callback( '/^( +)/m', [ self::class, 'replaceSpaces' ], $text );
+
+ $text = $parser->recursiveTagParse( $text, $frame );
+
+ $attribs = Sanitizer::validateTagAttributes( $param, 'div' );
+
+ // Wrap output in a <div> with "poem" class.
+ if ( isset( $attribs['class'] ) ) {
+ $attribs['class'] = 'poem ' . $attribs['class'];
+ } else {
+ $attribs['class'] = 'poem';
+ }
+
+ return Html::rawElement( 'div', $attribs, $newline . trim( $text ) . $newline );
+ }
+
+ /**
+ * Callback for preg_replace_callback() that replaces spaces with non-breaking spaces
+ * @param string[] $m Matches from the regular expression
+ * - $m[1] consists of 1 or more spaces
+ * @return string
+ */
+ protected static function replaceSpaces( array $m ) {
+ return str_replace( ' ', '&#160;', $m[1] );
+ }
+
+ /**
+ * Callback for preg_replace_callback() that wraps content in an indented span
+ * @param string[] $m Matches from the regular expression
+ * - $m[1] consists of 1 or more colons
+ * - $m[2] consists of the text after the colons
+ * @return string
+ */
+ protected static function indentVerse( array $m ) {
+ $attribs = [
+ 'class' => 'mw-poem-indented',
+ 'style' => 'display: inline-block; margin-left: ' . strlen( $m[1] ) . 'em;'
+ ];
+ // @todo Should this really be raw?
+ return Html::rawElement( 'span', $attribs, $m[2] );
+ }
+}
diff --git a/www/wiki/extensions/Poem/tests/parser/parserTests.txt b/www/wiki/extensions/Poem/tests/parser/parserTests.txt
new file mode 100644
index 00000000..3bc95e44
--- /dev/null
+++ b/www/wiki/extensions/Poem/tests/parser/parserTests.txt
@@ -0,0 +1,162 @@
+# Force the test runner to ensure the extension is loaded
+!! hooks
+poem
+!! endhooks
+
+#Regression tests for existing functionality, to ensure nothing was broken.
+!! test
+<poem>
+!! input
+<poem>
+this
+is
+a
+test
+</poem>
+!! result
+<div class="poem">
+<p>this<br />
+is<br />
+a<br />
+test
+</p>
+</div>
+
+!! end
+
+!!test
+ <poem> with recursive parsing
+!!input
+<poem>
+this ''is'' a '''test'''
+</poem>
+!! result
+<div class="poem">
+<p>this <i>is</i> a <b>test</b>
+</p>
+</div>
+
+!!end
+
+
+!!test
+ <poem> with leading whitespace
+!!input
+<poem>
+
+ test
+
+</poem>
+!! result
+<div class="poem">
+<p><br />
+&#160;&#160;&#160;test<br />
+</p>
+</div>
+
+!!end
+
+!!test
+Horizontal rule
+!!input
+<poem>
+some
+-----
+text
+</poem>
+!!result
+<div class="poem">
+<p>some<br />
+</p>
+<hr /><br />
+<p>text
+</p>
+</div>
+
+!!end
+
+#test for new poem/nowiki feature; should fail without new enhancement.
+!! test 2
+example of <nowiki> without <poem>
+!!options
+disabled
+!! input
+<nowiki>
+this
+is
+a
+test
+</nowiki>
+!! result
+<p>
+this
+is
+a
+test
+
+</p>
+!! end
+
+!! test
+ nested <poem><nowiki>
+!! input
+<poem><nowiki>
+this
+is
+a
+test
+</nowiki></poem>
+!! result
+<div class="poem">
+<p><br />
+this<br />
+is<br />
+a<br />
+test<br />
+
+</p>
+</div>
+
+!!end
+
+!! test 5
+ nested <poem><nowiki> with formatting
+!! input
+<poem><nowiki>
+this
+'''is'''
+a
+test
+</nowiki></poem>
+!! result
+<div class="poem">
+<p><br />
+this<br />
+'''is'''<br />
+a<br />
+test<br />
+
+</p>
+</div>
+
+!! end
+
+!! test
+Basic <poem> usage with style
+!! input
+<poem style="border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;">
+A stately pleasure-dome decree:
+Where Alph, the sacred river, ran
+Through caverns measureless to man
+Down to a sunless sea.
+</poem>
+!! result
+<div style="border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;" class="poem">
+<p>A stately pleasure-dome decree:<br />
+Where Alph, the sacred river, ran<br />
+Through caverns measureless to man<br />
+Down to a sunless sea.
+</p>
+</div>
+
+!! end
diff --git a/www/wiki/extensions/Poem/tests/phan/config.php b/www/wiki/extensions/Poem/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/Poem/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/Renameuser/Gruntfile.js b/www/wiki/extensions/Renameuser/Gruntfile.js
index 116f5823..13202269 100644
--- a/www/wiki/extensions/Renameuser/Gruntfile.js
+++ b/www/wiki/extensions/Renameuser/Gruntfile.js
@@ -15,7 +15,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/Renameuser/Renameuser.alias.php b/www/wiki/extensions/Renameuser/Renameuser.alias.php
index a37c70e7..eb1755e2 100644
--- a/www/wiki/extensions/Renameuser/Renameuser.alias.php
+++ b/www/wiki/extensions/Renameuser/Renameuser.alias.php
@@ -363,6 +363,11 @@ $specialPageAliases['uk'] = [
'Renameuser' => [ 'Перейменувати_користувача', 'Переименовать_участника' ],
];
+/** Urdu (اردو) */
+$specialPageAliases['ur'] = [
+ 'Renameuser' => [ 'تبدیلی_نام' ],
+];
+
/** Vietnamese (Tiếng Việt) */
$specialPageAliases['vi'] = [
'Renameuser' => [ 'Đổi_tên_thành_viên', 'Đổi_tên_người_dùng' ],
diff --git a/www/wiki/extensions/Renameuser/Renameuser.php b/www/wiki/extensions/Renameuser/Renameuser.php
index 738ca0db..64a7e034 100644
--- a/www/wiki/extensions/Renameuser/Renameuser.php
+++ b/www/wiki/extensions/Renameuser/Renameuser.php
@@ -13,5 +13,5 @@ if ( function_exists( 'wfLoadExtension' ) ) {
return true;
} else {
- die( 'This version of the Renameuser extension requires MediaWiki 1.25+' );
+ die( 'This version of the Renameuser extension requires MediaWiki 1.30+' );
}
diff --git a/www/wiki/extensions/Renameuser/composer.json b/www/wiki/extensions/Renameuser/composer.json
index 7c63cad5..afa0dc78 100644
--- a/www/wiki/extensions/Renameuser/composer.json
+++ b/www/wiki/extensions/Renameuser/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
- "parallel-lint . --exclude vendor",
- "phpcs -p -s"
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/Renameuser/extension.json b/www/wiki/extensions/Renameuser/extension.json
index 226cca39..99dfe6f4 100644
--- a/www/wiki/extensions/Renameuser/extension.json
+++ b/www/wiki/extensions/Renameuser/extension.json
@@ -6,10 +6,10 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:Renameuser",
"descriptionmsg": "renameuser-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "specialpage",
"requires": {
- "MediaWiki": ">= 1.25.0"
+ "MediaWiki": ">= 1.30.0"
},
"ExtensionMessagesFiles": {
"RenameuserAliases": "Renameuser.alias.php"
@@ -51,11 +51,11 @@
"Renameuser": "SpecialRenameuser"
},
"AutoloadClasses": {
- "RenameuserHooks": "Renameuser.hooks.php",
- "RenameUserJob": "RenameUserJob.php",
- "RenameuserLogFormatter": "RenameuserLogFormatter.php",
- "RenameuserSQL": "RenameuserSQL.php",
- "SpecialRenameuser": "specials/SpecialRenameuser.php"
+ "RenameuserHooks": "includes/RenameuserHooks.php",
+ "RenameUserJob": "includes/RenameUserJob.php",
+ "RenameuserLogFormatter": "includes/RenameuserLogFormatter.php",
+ "RenameuserSQL": "includes/RenameuserSQL.php",
+ "SpecialRenameuser": "includes/SpecialRenameuser.php"
},
"manifest_version": 1
}
diff --git a/www/wiki/extensions/Renameuser/i18n/bg.json b/www/wiki/extensions/Renameuser/i18n/bg.json
index 31c60033..b45eab0f 100644
--- a/www/wiki/extensions/Renameuser/i18n/bg.json
+++ b/www/wiki/extensions/Renameuser/i18n/bg.json
@@ -7,7 +7,8 @@
"Stanqo",
"Turin",
"Vodnokon4e",
- "Termininja"
+ "Termininja",
+ "ShockD"
]
},
"renameuser": "Преименуване на потребител",
@@ -35,6 +36,8 @@
"renameuser-page-unmoved": "Страницата $1 не можа да бъде преместена като $2.",
"log-name-renameuser": "Дневник на преименуванията",
"log-description-renameuser": "Това е дневник на промените в потребителските имена.",
+ "logentry-renameuser-renameuser": "$1 {{GENDER:$2|преименува}} потребител $4 ({{PLURAL:$6|$6 редакция|$6 редакции}}) на {{GENDER:$7|$5}}",
+ "logentry-renameuser-renameuser-legacier": "$1 преименува потребител $4 на {{GENDER:$7|$5}}",
"renameuser-move-log": "Автоматично преместена страница при преименуването на потребител \"[[User:$1|$1]]\" като \"[[User:$2|$2]]\"",
"action-renameuser": "преименуване на потребител",
"right-renameuser": "преименуване на потребители",
diff --git a/www/wiki/extensions/Renameuser/i18n/bn.json b/www/wiki/extensions/Renameuser/i18n/bn.json
index 5e6cb94a..e73c92a8 100644
--- a/www/wiki/extensions/Renameuser/i18n/bn.json
+++ b/www/wiki/extensions/Renameuser/i18n/bn.json
@@ -18,8 +18,8 @@
"renameuserreserve": "ভবিষ্যতে উদ্দেশ্যে পুরাতন ব্যবহারকারী নাম ব্লক করা হল",
"renameuserwarnings": "সতর্কীকরণ:",
"renameuserconfirm": "হ্যাঁ, ব্যবহারকারীর নাম পরিবর্তন করো",
- "renameusersubmit": "জমা দাও",
- "renameuser-submit-blocklog": "ব্যবহারকারীর ব্লক লগ দেখুন",
+ "renameusersubmit": "জমা দিন",
+ "renameuser-submit-blocklog": "ব্যবহারকারীর বাধা লগ দেখুন",
"renameusererrordoesnotexist": "\"<nowiki>$1</nowiki>\" নামের কোন ব্যবহারকারী নাই।",
"renameusererrorexists": "\"<nowiki>$1</nowiki>\" {{GENDER:$1|ব্যবহারকারী}} ইতিমধ্যে বিদ্যমান আছে।",
"renameusererrorinvalid": "\"<nowiki>$1</nowiki>\" ব্যবহারকারী নামটি ঠিক নয়।",
diff --git a/www/wiki/extensions/Renameuser/i18n/ckb.json b/www/wiki/extensions/Renameuser/i18n/ckb.json
index beffb842..6609dc2f 100644
--- a/www/wiki/extensions/Renameuser/i18n/ckb.json
+++ b/www/wiki/extensions/Renameuser/i18n/ckb.json
@@ -2,7 +2,8 @@
"@metadata": {
"authors": [
"Calak",
- "Lost Whispers"
+ "Lost Whispers",
+ "Épine"
]
},
"renameuserold": "ناوی بەکارھێنەری ئێستا:",
diff --git a/www/wiki/extensions/Renameuser/i18n/el.json b/www/wiki/extensions/Renameuser/i18n/el.json
index ac036635..83c07e22 100644
--- a/www/wiki/extensions/Renameuser/i18n/el.json
+++ b/www/wiki/extensions/Renameuser/i18n/el.json
@@ -10,7 +10,8 @@
"Kiriakos",
"MF-Warburg",
"Omnipaedista",
- "ZaDiak"
+ "ZaDiak",
+ "Nikosgranturismogt"
]
},
"renameuser": "Μετονομασία χρήστη",
@@ -28,7 +29,7 @@
"renameusersubmit": "Καταχώριση",
"renameuser-submit-blocklog": "Εμφάνιση μητρώου φραγών του χρήστη",
"renameusererrordoesnotexist": "Ο χρήστης \"<nowiki>$1</nowiki>\" δεν υπάρχει",
- "renameusererrorexists": "Ο χρήστης \"<nowiki>$1</nowiki>\" υπάρχει ήδη.",
+ "renameusererrorexists": "Ο {{GENDER:$1|χρήστης}} \"<nowiki>$1</nowiki>\" υπάρχει ήδη.",
"renameusererrorinvalid": "Το όνομα χρήστη \"<nowiki>$1</nowiki>\" είναι άκυρο.",
"renameuser-error-request": "Υπήρξε ένα πρόβλημα στην παραλαβή της αίτησης. Παρακαλούμε επιστρέψτε και ξαναδοκιμάστε.",
"renameuser-error-same-user": "Δεν μπορείτε να μετονομάσετε έναν χρήστη σε όνομα ίδιο με το προηγούμενο.",
@@ -39,7 +40,7 @@
"log-name-renameuser": "Αρχείο μετονομασίας χρηστών",
"log-description-renameuser": "Αυτό είναι ένα αρχείο καταγραφής αλλαγών σε ονόματα χρηστών",
"logentry-renameuser-renameuser": "{{GENDER:$2|Ο|Η}} $1 μετονόμασε {{GENDER:$4|το χρήστη|τη χρήστρια}} $4 ({{PLURAL:$6|$6 επεξεργασία|$6 επεξεργασίες}}) σε $5",
- "logentry-renameuser-renameuser-legacier": "{{GENDER:$2|Ο|Η}} $1 μετονόμασε {{GENDER:$4|το χρήστη|τη χρήστρια}} $4 σε $5",
+ "logentry-renameuser-renameuser-legacier": "Ο $1 μετονόμασε τον χρήστη $4 σε {{GENDER:$7|$5}}",
"renameuser-move-log": "Η σελίδα μετακινήθηκε αυτόματα κατά τη μετονομασία του χρήστη \"[[User:$1|$1]]\" σε \"[[User:$2|$2]]\"",
"action-renameuser": "μετονομασία χρηστών",
"right-renameuser": "Μετονομασία χρηστών",
diff --git a/www/wiki/extensions/Renameuser/i18n/es.json b/www/wiki/extensions/Renameuser/i18n/es.json
index 885abb40..b50dad1d 100644
--- a/www/wiki/extensions/Renameuser/i18n/es.json
+++ b/www/wiki/extensions/Renameuser/i18n/es.json
@@ -21,25 +21,25 @@
"Fitoschido"
]
},
- "renameuser": "Renombrar usuario",
- "renameuser-linkoncontribs": "renombrar usuario",
- "renameuser-linkoncontribs-text": "Renombrar a este usuario",
- "renameuser-desc": "Añade una [[Special:RenameUser|página especial]] para renombrar a un usuario (necesita el permiso ''renameuser'')",
+ "renameuser": "Cambiar nombre de usuario",
+ "renameuser-linkoncontribs": "cambiar nombre de usuario",
+ "renameuser-linkoncontribs-text": "Cambiar nombre de este usuario",
+ "renameuser-desc": "Añade una [[Special:RenameUser|página especial]] para cambiar el nombre de un usuario (necesita el permiso ''renameuser'')",
"renameuserold": "Nombre de usuario actual:",
"renameusernew": "Nombre de usuario nuevo:",
"renameuserreason": "Motivo:",
"renameusermove": "Trasladar las páginas de usuario y de discusión (y sus subpáginas) al nuevo nombre",
- "renameusersuppress": "No crear redirecciones al nuevo nombre",
+ "renameusersuppress": "No crear redirecciones al nombre nuevo",
"renameuserreserve": "Bloquear el antiguo nombre de usuario para evitar que sea usado en el futuro",
- "renameuserwarnings": "Avisos:",
- "renameuserconfirm": "Sí, renombrar al usuario",
+ "renameuserwarnings": "Alertas:",
+ "renameuserconfirm": "Sí, cambiar nombre de usuario",
"renameusersubmit": "Enviar",
"renameuser-submit-blocklog": "Mostrar el registro de bloqueo para el usuario",
"renameusererrordoesnotexist": "El usuario «<nowiki>$1</nowiki>» no existe.",
"renameusererrorexists": "{{GENDER:$1|El usuario|La usuaria}} «<nowiki>$1</nowiki>» ya existe.",
"renameusererrorinvalid": "El nombre de usuario «<nowiki>$1</nowiki>» no es válido.",
"renameuser-error-request": "Hubo un problema al recibir la solicitud.\nRegresa e inténtalo de nuevo.",
- "renameuser-error-same-user": "No puedes renombrar a un usuario con el nombre que ya tenía.",
+ "renameuser-error-same-user": "No puedes otorgar a un usuario un nombre que ya tenía.",
"renameusersuccess": "{{GENDER:$2|El usuario|La usuaria}} «<nowiki>$1</nowiki>» se renombró a «<nowiki>$2</nowiki>».",
"renameuser-page-exists": "La página $1 ya existe y no puede ser reemplazada automáticamente.",
"renameuser-page-moved": "La página $1 ha sido trasladada a $2.",
@@ -49,7 +49,7 @@
"logentry-renameuser-renameuser": "$1 {{GENDER:$2|renombró}} {{GENDER:$7|al usuario|a la usuaria}} $4 ({{PLURAL:$6|$6 edición|$6 ediciones}}) como $5",
"logentry-renameuser-renameuser-legacier": "$1 renombró {{GENDER:$7|al usuario|a la usuaria}} $4 como $5",
"renameuser-move-log": "Página trasladada automáticamente al cambiar el nombre {{GENDER:$2|del usuario|de la usuaria}} de «[[User:$1|$1]]» a «[[User:$2|$2]]»",
- "action-renameuser": "renombrar usuarios",
- "right-renameuser": "Renombrar usuarios",
- "renameuser-renamed-notice": "{{GENDER:$1|Este usuario|Esta usuaria}} se ha renombrado.\nEl registro de cambios de nombre de usuario se provee debajo para mayor referencia."
+ "action-renameuser": "cambiar nombres de usuarios",
+ "right-renameuser": "Cambiar nombres de usuarios",
+ "renameuser-renamed-notice": "Se cambió el nombre de {{GENDER:$1|este usuario|esta usuaria}}.\nEl registro de cambios de nombre de usuario se provee debajo para mayor referencia."
}
diff --git a/www/wiki/extensions/Renameuser/i18n/fa.json b/www/wiki/extensions/Renameuser/i18n/fa.json
index 4f87db34..b758c80f 100644
--- a/www/wiki/extensions/Renameuser/i18n/fa.json
+++ b/www/wiki/extensions/Renameuser/i18n/fa.json
@@ -14,9 +14,9 @@
"renameuser-linkoncontribs-text": "تغییر نام کاربر",
"renameuser-desc": "نام یک کاربر را تغییر می‌دهد (نیازمند برخورداری از اختیارات ''تغییرنام'' است)",
"renameuserold": "نام کاربری کنونی:",
- "renameusernew": "نام کاربری نو:",
+ "renameusernew": "نام کاربری تازه:",
"renameuserreason": "دلیل:",
- "renameusermove": "صفحه‌های کاربری و بحث (به همراه زیر صفحه‌هایشان) به نام تازه منتقل کن",
+ "renameusermove": "صفحه‌های کاربری و بحث را (به همراه زیر صفحه‌هایشان) به نام تازه منتقل کن",
"renameusersuppress": "تغییرمسیر به نام جدید ایجاد نکن",
"renameuserreserve": "نام کاربری قبلی را در مقابل استفادهٔ مجدد حفظ کن",
"renameuserwarnings": "هشدار:",
@@ -24,20 +24,20 @@
"renameusersubmit": "ارسال",
"renameuser-submit-blocklog": "نمایش سیاههٔ بستن کاربر",
"renameusererrordoesnotexist": "نام کاربری «<nowiki>$1</nowiki>» وجود ندارد",
- "renameusererrorexists": "نام کاربری «<nowiki>$1</nowiki>» استفاده شده‌است",
+ "renameusererrorexists": "{{GENDER:$1|نام کاربری}} «<nowiki>$1</nowiki>» استفاده شده‌است.",
"renameusererrorinvalid": "نام کاربری «<nowiki>$1</nowiki>» نامجاز است.",
- "renameuser-error-request": "در دریافت درخواست مشکلی پیش آمد. لطفاً به صفحهٔ قبل بازگردید و دوباره تلاش کنید.",
+ "renameuser-error-request": "در دریافت درخواست مشکلی پیش آمد.\nلطفاً به صفحهٔ قبل بازگردید و دوباره تلاش کنید.",
"renameuser-error-same-user": "شما نمی‌توانید نام یک کاربر را به همان نام قبلی‌اش تغییر دهید.",
- "renameusersuccess": "نام کاربر «<nowiki>$1</nowiki>» به «<nowiki>$2</nowiki>» تغییر یافت.",
+ "renameusersuccess": "نام {{GENDER:$2|کاربر}} «<nowiki>$1</nowiki>» به «<nowiki>$2</nowiki>» تغییر یافت.",
"renameuser-page-exists": "صفحهٔ $1 از قبل وجود داشته و به طور خودکار قابل بازنویسی نیست.",
"renameuser-page-moved": "صفحهٔ $1 به $2 انتقال داده شد.",
"renameuser-page-unmoved": "امکان انتقال صفحهٔ $1 به $2 وجود ندارد.",
"log-name-renameuser": "سیاهه تغییر نام کاربر",
"log-description-renameuser": "این سیاههٔ تغییر نام کاربران است.",
- "logentry-renameuser-renameuser": "$1 نام $4 ({{PLURAL:$6|$6 ویرایش|}}) را به $5 {{GENDER:$2|تغییر داد}}",
- "logentry-renameuser-renameuser-legacier": "$1 نام کاربری $4 را به $5 تغییر داد",
- "renameuser-move-log": "صفحه در ضمن تغییر نام کاربر «[[User:$1|$1]]» به «[[User:$2|$2]]» به طور خودکار منتقل شد",
+ "logentry-renameuser-renameuser": "$1 نام $4 ({{PLURAL:$6|$6 ویرایش}}) را به {{GENDER:$7|$5}} {{GENDER:$2|تغییر داد}}",
+ "logentry-renameuser-renameuser-legacier": "$1 نام کاربری $4 را به {{GENDER:$7|$5}} تغییر داد",
+ "renameuser-move-log": "صفحه را در ضمن تغییر نام {{GENDER:$2|کاربر}} از «[[User:$1|$1]]» به «[[User:$2|$2]]» به طور خودکار منتقل کرد",
"action-renameuser": "تغییر نام کاربران",
"right-renameuser": "تغییر نام کاربران",
- "renameuser-renamed-notice": "این کاربر تغییر نام داده است.\nسیاهه تغییر نام در ادامه آمده است."
+ "renameuser-renamed-notice": "این کاربر تغییر نام داده‌است.\nسیاههٔ تغییر نام در ادامه آمده‌است."
}
diff --git a/www/wiki/extensions/Renameuser/i18n/fy.json b/www/wiki/extensions/Renameuser/i18n/fy.json
index 01f2f9b5..f1ebec61 100644
--- a/www/wiki/extensions/Renameuser/i18n/fy.json
+++ b/www/wiki/extensions/Renameuser/i18n/fy.json
@@ -3,7 +3,8 @@
"authors": [
"SK-luuut",
"Snakesteuben",
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
"renameuser": "Feroarje in meidochnamme",
diff --git a/www/wiki/extensions/Renameuser/i18n/he.json b/www/wiki/extensions/Renameuser/i18n/he.json
index cecb453a..3ae76621 100644
--- a/www/wiki/extensions/Renameuser/i18n/he.json
+++ b/www/wiki/extensions/Renameuser/i18n/he.json
@@ -29,7 +29,7 @@
"renameusererrorinvalid": "שם המשתמש \"<nowiki>$1</nowiki>\" אינו תקין.",
"renameuser-error-request": "הייתה בעיה בקבלת הבקשה. אנא חזרו לדף הקודם ונסו שנית.",
"renameuser-error-same-user": "לא ניתן לשנות את שם המשתמש לשם זהה לשמו הישן.",
- "renameusersuccess": "שם המשתמש של \"<nowiki>$1</nowiki>\" שונה ל\"<nowiki>$2</nowiki>\".",
+ "renameusersuccess": "שם המשתמש \"<nowiki>$1</nowiki>\" שוּנה לשם \"<nowiki>$2</nowiki>\".",
"renameuser-page-exists": "הדף $1 כבר קיים ולא ניתן לדרוס אותו אוטומטית.",
"renameuser-page-moved": "הדף $1 הועבר לשם $2.",
"renameuser-page-unmoved": "לא ניתן היה להעביר את הדף $1 ל$2.",
diff --git a/www/wiki/extensions/Renameuser/i18n/hr.json b/www/wiki/extensions/Renameuser/i18n/hr.json
index 8c2b7806..039c3380 100644
--- a/www/wiki/extensions/Renameuser/i18n/hr.json
+++ b/www/wiki/extensions/Renameuser/i18n/hr.json
@@ -17,7 +17,7 @@
"renameuser-desc": "Dodaje [[Special:RenameUser|posebnu stranicu]] za preimenovanje suradnika (potrebno je ''renameuser'' pravo)",
"renameuserold": "Trenutačno suradničko ime:",
"renameusernew": "Novo suradničko ime:",
- "renameuserreason": "Razlog za preimenovanje:",
+ "renameuserreason": "Razlog:",
"renameusermove": "Premjesti suradnikove stranice (glavnu, stranicu za razgovor i podstranice, ako postoje) na novo ime",
"renameusersuppress": "Ne kreiraj preusmjeravanja na novo ime",
"renameuserreserve": "Zadrži staro suradničko ime od daljnje upotrebe",
diff --git a/www/wiki/extensions/Renameuser/i18n/io.json b/www/wiki/extensions/Renameuser/i18n/io.json
index f3355b6f..a42eccb7 100644
--- a/www/wiki/extensions/Renameuser/i18n/io.json
+++ b/www/wiki/extensions/Renameuser/i18n/io.json
@@ -4,7 +4,8 @@
"Malafaya",
"Wyvernoid",
"Robin van der Vliet",
- "Lakaoso"
+ "Lakaoso",
+ "Joao Xavier"
]
},
"renameuser": "Rinomar uzero",
@@ -20,5 +21,6 @@
"renameuser-page-moved": "La pagino $1 movesis a $2.",
"renameuser-page-unmoved": "On ne povis movar la pagino $1 a $2.",
"log-name-renameuser": "Registro di uzero-rinomizuri",
+ "logentry-renameuser-renameuser": "$1 {{GENDER:$2|rinomizis}} uzero $4 ({{PLURAL:$6|$6 redakto|$6 redakti}}) kom {{GENDER:$7|$5}}",
"right-renameuser": "Rinomar uzanti"
}
diff --git a/www/wiki/extensions/Renameuser/i18n/lt.json b/www/wiki/extensions/Renameuser/i18n/lt.json
index bceb9f27..3dab826d 100644
--- a/www/wiki/extensions/Renameuser/i18n/lt.json
+++ b/www/wiki/extensions/Renameuser/i18n/lt.json
@@ -4,34 +4,35 @@
"Eitvys200",
"Homo",
"Hugo.arg",
- "Matasg"
+ "Matasg",
+ "Manvydasz"
]
},
"renameuser": "Pervadinti naudotoją",
- "renameuser-linkoncontribs": "Pervadinti naudotoją",
+ "renameuser-linkoncontribs": "pervadinti naudotoją",
"renameuser-linkoncontribs-text": "Pervardyti šį vartotoją",
- "renameuser-desc": "Pervadinti naudotoją (reikia ''pervadintojo'' teisių)",
+ "renameuser-desc": "Prideda [[Special:RenameUser|specialų puslapį]] naudotojo pervadinimui (reikia ''pervadintojo'' teisių)",
"renameuserold": "Esamas naudotojo vardas:",
"renameusernew": "Naujas naudotojo vardas:",
- "renameuserreason": "Pervadinimo priežastis:",
- "renameusermove": "Perkelti naudotojo ir aptarimo puslapius (bei jo subpuslapius) prie naujo vardo",
+ "renameuserreason": "Priežastis:",
+ "renameusermove": "Perkelti naudotojo ir aptarimo puslapius (bei jo antrinius puslapius) prie naujo vardo",
"renameuserreserve": "Užblokuoti senąjį naudotojo vardą nuo galimybių naudoti ateityje",
"renameuserwarnings": "Įspėjimai:",
"renameuserconfirm": "Taip, pervadinti naudotoją",
"renameusersubmit": "Patvirtinti",
"renameusererrordoesnotexist": "Naudotojas \"<nowiki>$1</nowiki>\" neegzistuoja.",
- "renameusererrorexists": "Naudotojas \"<nowiki>$1</nowiki>\" jau egzistuoja.",
+ "renameusererrorexists": "{{GENDER:$1|Naudotojas|Naudotoja}} \"<nowiki>$1</nowiki>\" jau egzistuoja.",
"renameusererrorinvalid": "Naudotojo vardas \"<nowiki>$1</nowiki>\" netinkamas.",
"renameuser-error-request": "Iškilo prašymo gavimo problema.\nPrašome eiti atgal ir bandyti iš naujo.",
"renameuser-error-same-user": "Jūs negalite pervadinti naudotojo į tokį pat vardą, kaip pirmiau.",
- "renameusersuccess": "Naudotojas \"<nowiki>$1</nowiki>\" buvo pervadintas į \"<nowiki>$2</nowiki>\".",
+ "renameusersuccess": "{{GENDER:$2|Naudotojas|Naudotoja}} \"<nowiki>$1</nowiki>\" buvo pervadintas(-a) į \"<nowiki>$2</nowiki>\".",
"renameuser-page-exists": "Puslapis $1 jau egzistuoja ir negali būti automatiškai perrašytas.",
"renameuser-page-moved": "Puslapis $1 buvo perkeltas į $2.",
"renameuser-page-unmoved": "Puslapis $1 negali būti perkeltas į $2.",
"log-name-renameuser": "Naudotojų pervadinimo sąrašas",
"log-description-renameuser": "Šiame sąraše pateikiami naudotojų vardų pakeitimai.",
- "logentry-renameuser-renameuser": "$1 {{GENDER:$2|pervadino}} naudotoją $4 ({{PLURAL:$6|keitimų|keitimų}}: $6) į {{GENDER:$7|$5}}",
- "renameuser-move-log": "Puslapis automatiškai perkeltas, kai buvo pervadinamas naudotojas \"[[User:$1|$1]]\" į \"[[User:$2|$2]]\"",
+ "logentry-renameuser-renameuser": "$1 {{GENDER:$2|pervadino}} naudotoją $4 ({{PLURAL:$6|$6 keitimas|$6 keitimai|$6 keitimų}}) į {{GENDER:$7|$5}}",
+ "renameuser-move-log": "Puslapis automatiškai perkeltas, kai buvo {{GENDER:$2|pervadinamas naudotojas|pervadinama naudotoja}} \"[[User:$1|$1]]\" į \"[[User:$2|$2]]\"",
"action-renameuser": "pervadinti naudotojus",
"right-renameuser": "Pervadinti naudotojus"
}
diff --git a/www/wiki/extensions/Renameuser/i18n/mk.json b/www/wiki/extensions/Renameuser/i18n/mk.json
index 3175c709..1c91d925 100644
--- a/www/wiki/extensions/Renameuser/i18n/mk.json
+++ b/www/wiki/extensions/Renameuser/i18n/mk.json
@@ -13,7 +13,7 @@
"renameuserold": "Сегашно корисничко име:",
"renameusernew": "Ново корисничко име:",
"renameuserreason": "Причина:",
- "renameusermove": "Премести корисничка страница и страници за разговор (и нивните потстраници) под новото име",
+ "renameusermove": "Премести кориснички и разговорни страници (и нивните потстраници) под новото име",
"renameusersuppress": "Не создавај пренасочувања кон новото име",
"renameuserreserve": "Блокирање на старото корисничко име, да не може да се користи во иднина",
"renameuserwarnings": "Предупредувања:",
@@ -21,19 +21,19 @@
"renameusersubmit": "Внеси",
"renameuser-submit-blocklog": "Дневник на блокирања за корисникот",
"renameusererrordoesnotexist": "Корисникот „<nowiki>$1</nowiki>“ не постои",
- "renameusererrorexists": "Корисникот „<nowiki>$1</nowiki>“ веќе постои",
+ "renameusererrorexists": "{{GENDER:$1|Корисникот}} „<nowiki>$1</nowiki>“ веќе постои.",
"renameusererrorinvalid": "Корисничкото име „<nowiki>$1</nowiki>“ не е важечко.",
"renameuser-error-request": "Се јави проблем при примањето на барањето.\nВратете се и обидете се повторно.",
"renameuser-error-same-user": "Не можете да го преименувате корисникот во име кое е исто како претходното.",
- "renameusersuccess": "Корисникот „<nowiki>$1</nowiki>“ е преименуван во „<nowiki>$2</nowiki>“",
+ "renameusersuccess": "{{GENDER:$2|Корисникот}} „<nowiki>$1</nowiki>“ е преименуван во „<nowiki>$2</nowiki>“",
"renameuser-page-exists": "Страницата $1 веќе постои и не може автоматски да се замени со друга содржина.",
"renameuser-page-moved": "Страницата $1 е преместена на $2.",
"renameuser-page-unmoved": "Страницата $1 неможеше да се премести на $2.",
"log-name-renameuser": "Дневник на преименувања на корисници",
"log-description-renameuser": "Ово е дневник на преименувања на корисници",
- "logentry-renameuser-renameuser": "$1 го {{GENDER:$2|преименуваше}} корисникот $4 ({{PLURAL:$6|$6 уредување|$6 уредувања}}) во $5",
- "logentry-renameuser-renameuser-legacier": "$1 го преименуваше корисникот $4 во $5",
- "renameuser-move-log": "Автоматски преместена страница при преименување на корисникот „[[User:$1|$1]]“ во „[[User:$2|$2]]“",
+ "logentry-renameuser-renameuser": "$1 го {{GENDER:$2|преименуваше}} корисникот $4 ({{PLURAL:$6|$6 уредување|$6 уредувања}}) во {{GENDER:$7|$5}}",
+ "logentry-renameuser-renameuser-legacier": "$1 го преименуваше корисникот $4 во {{GENDER:$7|$5}}",
+ "renameuser-move-log": "Автоматски преместена страница при преименување на {{GENDER:$2|корисникот}} „[[User:$1|$1]]“ во „[[User:$2|$2]]“",
"action-renameuser": "преименување на корисници",
"right-renameuser": "Преименување корисници",
"renameuser-renamed-notice": "Овој корисник е преименуван.\nПодолу е приложен дневникот на преименување за споредба."
diff --git a/www/wiki/extensions/Renameuser/i18n/ml.json b/www/wiki/extensions/Renameuser/i18n/ml.json
index 7c4b54d2..ce76c647 100644
--- a/www/wiki/extensions/Renameuser/i18n/ml.json
+++ b/www/wiki/extensions/Renameuser/i18n/ml.json
@@ -5,7 +5,7 @@
"Shijualex"
]
},
- "renameuser": "ഉപയോക്താവിനെ പുനർനാമകരണം ചെയ്യുക",
+ "renameuser": "ഉപയോക്തൃ പുനർനാമകരണം",
"renameuser-linkoncontribs": "ഉപയോക്തൃ പുനർനാമകരണം",
"renameuser-linkoncontribs-text": "ഈ ഉപയോക്താവിന്റെ പേരു മാറ്റുക",
"renameuser-desc": "ഉപയോക്താവിനെ പുനർനാമകരണം ചെയ്യുവാനുള്ള (''പുനർനാമകരണ'' അവകാശം വേണം) ഒരു [[Special:RenameUser|പ്രത്യേക താൾ]] ചേർക്കുന്നു",
@@ -20,19 +20,19 @@
"renameusersubmit": "സമർപ്പിക്കുക",
"renameuser-submit-blocklog": "ഉപയോക്താവിനെക്കുറിച്ചുള്ള തടയൽ രേഖ പ്രദർശിപ്പിക്കുക",
"renameusererrordoesnotexist": "\"<nowiki>$1</nowiki>\" എന്ന ഉപയോക്താവ് നിലവിലില്ല.",
- "renameusererrorexists": "\"<nowiki>$1</nowiki>\" എന്ന ഉപയോക്താവ് നിലവിലുണ്ട്.",
+ "renameusererrorexists": "\"<nowiki>$1</nowiki>\" എന്ന {{GENDER:$1|ഉപയോക്താവ്}} നിലവിലുണ്ട്.",
"renameusererrorinvalid": "\"<nowiki>$1</nowiki>\" എന്ന ഉപയോക്തൃനാമം അസാധുവാണ്‌.",
"renameuser-error-request": "അപേക്ഷ സ്വീകരിക്കുമ്പോൾ പിഴവ് സം‌ഭവിച്ചു. ദയവായി തിരിച്ചു പോയി വീണ്ടും പരിശ്രമിക്കുക.",
"renameuser-error-same-user": "നിലവിലുള്ള ഒരു ഉപയോക്തൃനാമത്തിലേക്കു വേറൊരു ഉപയോക്തൃനാമം പുനർനാമകരണം നടത്തുവാൻ സാധിക്കില്ല.",
- "renameusersuccess": "\"<nowiki>$1</nowiki>\" എന്ന ഉപയോക്താവിനെ \"<nowiki>$2</nowiki>\" എന്ന നാമത്തിലേക്കു പുനർനാമകരണം ചെയ്തിരിക്കുന്നു.",
+ "renameusersuccess": "\"<nowiki>$1</nowiki>\" എന്ന {{GENDER:$2|ഉപയോക്താവിനെ}} \"<nowiki>$2</nowiki>\" എന്ന നാമത്തിലേക്കു പുനർനാമകരണം ചെയ്തിരിക്കുന്നു.",
"renameuser-page-exists": "$1 എന്ന താൾ നിലവിലുള്ളതിനാൽ അതിനെ യാന്ത്രികമായി മാറ്റാൻ കഴിയില്ല.",
"renameuser-page-moved": "$1 എന്ന താൾ $2 എന്നാക്കിയിരിക്കുന്നു.",
"renameuser-page-unmoved": "$1 എന്ന താൾ $2 എന്നാക്കാൻ സാദ്ധ്യമല്ല.",
"log-name-renameuser": "ഉപയോക്തൃ പുനർനാമകരണ രേഖ",
"log-description-renameuser": "ഈ പ്രവർത്തനരേഖ ഉപയോക്തൃനാമം പുനർനാമകരണം നടത്തിയതിന്റേതാണ്‌.",
- "logentry-renameuser-renameuser": "$4 ({{PLURAL:$6|$6 തിരുത്ത്|$6 തിരുത്തുകൾ}}) എന്ന ഉപയോക്താവിനെ $1, $5 എന്ന് {{GENDER:$2|പുനർനാമകരണം ചെയ്തിരിക്കുന്നു}}",
- "logentry-renameuser-renameuser-legacier": "$4 എന്ന ഉപയോക്താവിനെ $5 എന്ന് $1 പുനർനാമകരണം ചെയ്തു",
- "renameuser-move-log": "\"[[User:$1|$1]]\" എന്ന ഉപയോക്താവിനെ \"[[User:$2|$2]]\" എന്നു പുനർനാമകരണം ചെയ്തപ്പോൾ താൾ യാന്ത്രികമായി മാറ്റി.",
+ "logentry-renameuser-renameuser": "$4 ({{PLURAL:$6|$6 തിരുത്ത്|$6 തിരുത്തുകൾ}}) എന്ന ഉപയോക്താവിനെ $1, {{GENDER:$7|$5}} എന്ന് {{GENDER:$2|പുനർനാമകരണം ചെയ്തിരിക്കുന്നു}}",
+ "logentry-renameuser-renameuser-legacier": "$4 എന്ന ഉപയോക്താവിനെ {{GENDER:$7|$5}} എന്ന് $1 പുനർനാമകരണം ചെയ്തു",
+ "renameuser-move-log": "\"[[User:$1|$1]]\" എന്ന {{GENDER:$2|ഉപയോക്താവിനെ}} \"[[User:$2|$2]]\" എന്നു പുനർനാമകരണം ചെയ്തപ്പോൾ താൾ യാന്ത്രികമായി മാറ്റി.",
"action-renameuser": "ഉപയോക്താക്കളുടെ പുനർനാമകരണം",
"right-renameuser": "ഉപയോക്തൃ പുനർനാമകരണം",
"renameuser-renamed-notice": "ഈ ഉപയോക്താവിനെ പുനർനാമകരണം ചെയ്തിരിക്കുന്നു.\nപുനർനാമകരണ രേഖ അവലംബമായി പരിശോധിക്കാനായി താഴെ കൊടുത്തിരിക്കുന്നു."
diff --git a/www/wiki/extensions/Renameuser/i18n/mwl.json b/www/wiki/extensions/Renameuser/i18n/mwl.json
index acb8f6d9..6057c499 100644
--- a/www/wiki/extensions/Renameuser/i18n/mwl.json
+++ b/www/wiki/extensions/Renameuser/i18n/mwl.json
@@ -1,7 +1,8 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
"renameuser-page-moved": "La páigina $1 fui arrastrada pa $2."
diff --git a/www/wiki/extensions/Renameuser/i18n/my.json b/www/wiki/extensions/Renameuser/i18n/my.json
index 743f006d..ac98114b 100644
--- a/www/wiki/extensions/Renameuser/i18n/my.json
+++ b/www/wiki/extensions/Renameuser/i18n/my.json
@@ -5,5 +5,7 @@
]
},
"log-name-renameuser": "အသုံးပြုသူ အမည်ပြောင်းလဲခြင်း မှတ်တမ်း",
- "logentry-renameuser-renameuser-legacier": "$1 က အသုံးပြုသူ $4 ကို {{GENDER:$7|$5}} သို့ အမည်ပြောင်းလဲခဲ့သည်"
+ "logentry-renameuser-renameuser": "အသုံးပြုသူ $4 ({{PLURAL:$6|တည်းဖြတ်မှု $6 ခု|တည်းဖြတ်မှုများ $6 ခု}}) ကို {{GENDER:$7|$5}} သို့ $1 က {{GENDER:$2|အမည်ပြောင်းလဲခဲ့သည်}}",
+ "logentry-renameuser-renameuser-legacier": "$1 က အသုံးပြုသူ $4 ကို {{GENDER:$7|$5}} သို့ အမည်ပြောင်းလဲခဲ့သည်",
+ "renameuser-move-log": "{{GENDER:$2|အသုံးပြုသူ}} \"[[User:$1|$1]]\" ကို \"[[User:$2|$2]]\" သို့ အမည်ပြောင်းလဲစဉ် စာမျက်နှာအား အလိုအလျောက် ရွှေ့ပြောင်းခြင်း"
}
diff --git a/www/wiki/extensions/Renameuser/i18n/pt-br.json b/www/wiki/extensions/Renameuser/i18n/pt-br.json
index 256169a1..d781bb34 100644
--- a/www/wiki/extensions/Renameuser/i18n/pt-br.json
+++ b/www/wiki/extensions/Renameuser/i18n/pt-br.json
@@ -15,7 +15,7 @@
"renameuserold": "Nome de usuário atual:",
"renameusernew": "Novo nome de usuário:",
"renameuserreason": "Motivo:",
- "renameusermove": "Mover as páginas de usuário, páginas de discussão de usuário (e suas sub-páginas) para o novo nome",
+ "renameusermove": "Mover as páginas de usuário, páginas de discussão de usuário (e suas subpáginas) para o novo nome",
"renameusersuppress": "Não criar redirecionamentos para o novo nome",
"renameuserreserve": "Impedir novos usos do antigo nome de usuário",
"renameuserwarnings": "Alertas:",
diff --git a/www/wiki/extensions/Renameuser/i18n/skr-arab.json b/www/wiki/extensions/Renameuser/i18n/skr-arab.json
new file mode 100644
index 00000000..ef7f21aa
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/i18n/skr-arab.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Saraiki"
+ ]
+ },
+ "log-name-renameuser": "ورتݨ آلیاں دے ناں وٹاوݨ دا لاگ"
+}
diff --git a/www/wiki/extensions/Renameuser/i18n/th.json b/www/wiki/extensions/Renameuser/i18n/th.json
index 0f6719a6..d299b5ba 100644
--- a/www/wiki/extensions/Renameuser/i18n/th.json
+++ b/www/wiki/extensions/Renameuser/i18n/th.json
@@ -3,7 +3,8 @@
"authors": [
"Harley Hartwell",
"Mopza",
- "Passawuth"
+ "Passawuth",
+ "Horus"
]
},
"renameuser": "เปลี่ยนชื่อผู้ใช้",
@@ -11,7 +12,7 @@
"renameuserold": "ชื่อผู้ใช้ปัจจุบัน:",
"renameusernew": "ชื่อผู้ใช้ใหม่:",
"renameuserreason": "เหตุผลในการเปลี่ยนชื่อ:",
- "renameusermove": "ย้ายหน้าผู้ใช้และหน้าพูดคุย (รวมถึงหน้าย่อยด้วย) ไปยังชื่อใหม่",
+ "renameusermove": "ย้ายหน้าผู้ใช้และหน้าคุย (รวมถึงหน้าย่อยด้วย) ไปชื่อใหม่",
"renameuserreserve": "บล็อกชื่อผู้ใช้เดิมจากการใช้งานในอนาคต",
"renameuserwarnings": "คำเตือน:",
"renameuserconfirm": "ใช่, เปลี่ยนชื่อผู้ใช้นี้",
diff --git a/www/wiki/extensions/Renameuser/i18n/zh-hant.json b/www/wiki/extensions/Renameuser/i18n/zh-hant.json
index 66fe88aa..5fc644c3 100644
--- a/www/wiki/extensions/Renameuser/i18n/zh-hant.json
+++ b/www/wiki/extensions/Renameuser/i18n/zh-hant.json
@@ -13,7 +13,8 @@
"LNDDYL",
"Liuxinyu970226",
"EagerLin",
- "Alexsh"
+ "Alexsh",
+ "Hello903hello"
]
},
"renameuser": "重新命名使用者",
@@ -43,7 +44,7 @@
"log-description-renameuser": "此頁面為使用者名稱修改日誌。",
"logentry-renameuser-renameuser": "$1 {{GENDER:$2|重新命名}}使用者 $4 (已編輯 {{PLURAL:$6|$6 次}}) 為 {{GENDER:$7|$5}}",
"logentry-renameuser-renameuser-legacier": "$1 重新命名使用者 $4 為 {{GENDER:$7|$5}}",
- "renameuser-move-log": "重新命名使用者 \"[[User:$1|$1]]\" 為 \"[[User:$2|$2]]\" 時已自動移動使用者相關頁面",
+ "renameuser-move-log": "重新命名{{GENDER:$2|使用者}} \"[[User:$1|$1]]\" 為 \"[[User:$2|$2]]\" 時已自動移動使用者相關頁面",
"action-renameuser": "重新命名使用者",
"right-renameuser": "重新命名使用者",
"renameuser-renamed-notice": "本使用者已重新命名。\n下列為重新命名日誌以提供參考。"
diff --git a/www/wiki/extensions/Renameuser/includes/RenameUserJob.php b/www/wiki/extensions/Renameuser/includes/RenameUserJob.php
new file mode 100644
index 00000000..2127e26a
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/includes/RenameUserJob.php
@@ -0,0 +1,229 @@
+<?php
+
+/**
+ * Custom job to perform updates on tables in busier environments
+ *
+ * Job parameters include:
+ * - table : DB table to update
+ * - column : The *_user_text column to update
+ * - oldname : The old user name
+ * - newname : The new user name
+ * - count : The expected number of rows to update in this batch
+ * - logId : The ID of the logging table row expected to exist if the rename was committed
+ *
+ * Additionally, one of the following groups of parameters must be set:
+ * a) The timestamp based rename paramaters:
+ * - timestampColumn : The *_timestamp column
+ * - minTimestamp : The minimum bound of the timestamp column range for this batch
+ * - maxTimestamp : The maximum bound of the timestamp column range for this batch
+ * - uniqueKey : A column that is unique (preferrably the PRIMARY KEY) [optional]
+ * b) The unique key based rename paramaters:
+ * - uniqueKey : A column that is unique (preferrably the PRIMARY KEY)
+ * - keyId : A list of values for this column to determine rows to update for this batch
+ *
+ * To avoid some race conditions, the following parameters should be set:
+ * - userID : The ID of the user to update
+ * - uidColumn : The *_user_id column
+ */
+class RenameUserJob extends Job {
+ /** @var array Core tables+columns that are being migrated to the `actor` table */
+ private static $actorMigratedColumns = [
+ 'revision.rev_user_text',
+ 'archive.ar_user_text',
+ 'ipblocks.ipb_by_text',
+ 'image.img_user_text',
+ 'oldimage.oi_user_text',
+ 'filearchive.fa_user_text',
+ 'recentchanges.rc_user_text',
+ 'logging.log_user_text',
+ ];
+
+ public function __construct( Title $title, $params = [] ) {
+ parent::__construct( 'renameUser', $title, $params );
+ }
+
+ public function run() {
+ global $wgUpdateRowsPerQuery;
+
+ $dbw = wfGetDB( DB_MASTER );
+ $table = $this->params['table'];
+ $column = $this->params['column'];
+
+ // Skip core tables that were migrated to the actor table, even if the
+ // field still exists in the database.
+ if ( in_array( "$table.$column", self::$actorMigratedColumns, true ) ) {
+ // We still run the job for MIGRATION_WRITE_NEW because reads might
+ // still be falling back.
+ $stage = RenameuserSQL::getActorMigrationStage();
+ if ( $stage >= MIGRATION_NEW ) {
+ wfDebugLog( 'Renameuser',
+ "Ignoring job {$this->toString()}, column $table.$column actor migration stage = $stage\n"
+ );
+ return true;
+ }
+ }
+
+ // It's not worth a hook to let extensions add themselves to that list.
+ // Just check whether the table and column still exist instead.
+ if ( !$dbw->tableExists( $table, __METHOD__ ) ) {
+ wfDebugLog( 'Renameuser',
+ "Ignoring job {$this->toString()}, table $table does not exist\n"
+ );
+ return true;
+ } elseif ( !$dbw->fieldExists( $table, $column, __METHOD__ ) ) {
+ wfDebugLog( 'Renameuser',
+ "Ignoring job {$this->toString()}, column $table.$column does not exist\n"
+ );
+ return true;
+ }
+
+ $oldname = $this->params['oldname'];
+ $newname = $this->params['newname'];
+ $count = $this->params['count'];
+ if ( isset( $this->params['userID'] ) ) {
+ $userID = $this->params['userID'];
+ $uidColumn = $this->params['uidColumn'];
+ } else {
+ $userID = null;
+ $uidColumn = null;
+ }
+ if ( isset( $this->params['timestampColumn'] ) ) {
+ $timestampColumn = $this->params['timestampColumn'];
+ $minTimestamp = $this->params['minTimestamp'];
+ $maxTimestamp = $this->params['maxTimestamp'];
+ } else {
+ $timestampColumn = null;
+ $minTimestamp = null;
+ $maxTimestamp = null;
+ }
+ $uniqueKey = isset( $this->params['uniqueKey'] ) ? $this->params['uniqueKey'] : null;
+ $keyId = isset( $this->params['keyId'] ) ? $this->params['keyId'] : null;
+ $logId = isset( $this->params['logId'] ) ? $this->params['logId'] : null;
+
+ if ( $logId ) {
+ # Block until the transaction that inserted this job commits.
+ # The atomic section is for sanity as FOR UPDATE does not lock in auto-commit mode
+ # per http://dev.mysql.com/doc/refman/5.7/en/innodb-locking-reads.html.
+ $dbw->startAtomic( __METHOD__ );
+ $committed = $dbw->selectField( 'logging',
+ '1',
+ [ 'log_id' => $logId ],
+ __METHOD__,
+ [ 'FOR UPDATE' ]
+ );
+ $dbw->endAtomic( __METHOD__ );
+ # If the transaction inserting this job was rolled back, detect that
+ if ( $committed === false ) { // rollback happened?
+ throw new LogicException( 'Cannot run job if the account rename failed.' );
+ }
+ }
+
+ # Flush any state snapshot data (and release the lock above)
+ $dbw->commit( __METHOD__, 'flush' );
+
+ # Conditions like "*_user_text = 'x'
+ $conds = [ $column => $oldname ];
+ # If user ID given, add that to condition to avoid rename collisions
+ if ( $userID !== null ) {
+ $conds[$uidColumn] = $userID;
+ }
+ # Bound by timestamp if given
+ if ( $timestampColumn !== null ) {
+ $conds[] = "$timestampColumn >= " . $dbw->addQuotes( $minTimestamp );
+ $conds[] = "$timestampColumn <= " . $dbw->addQuotes( $maxTimestamp );
+ # Bound by unique key if given (B/C)
+ } elseif ( $uniqueKey !== null && $keyId !== null ) {
+ $conds[$uniqueKey] = $keyId;
+ } else {
+ throw new InvalidArgumentException( 'Expected ID batch or time range' );
+ }
+
+ $affectedCount = 0;
+ # Actually update the rows for this job...
+ if ( $uniqueKey !== null ) {
+ # Select the rows to update by PRIMARY KEY
+ $ids = $dbw->selectFieldValues( $table, $uniqueKey, $conds, __METHOD__ );
+ # Update these rows by PRIMARY KEY to avoid slave lag
+ foreach ( array_chunk( $ids, $wgUpdateRowsPerQuery ) as $batch ) {
+ $dbw->commit( __METHOD__, 'flush' );
+ wfWaitForSlaves();
+
+ $dbw->update( $table,
+ [ $column => $newname ],
+ [ $column => $oldname, $uniqueKey => $batch ],
+ __METHOD__
+ );
+ $affectedCount += $dbw->affectedRows();
+ }
+ } else {
+ # Update the chunk of rows directly
+ $dbw->update( $table,
+ [ $column => $newname ],
+ $conds,
+ __METHOD__
+ );
+ $affectedCount += $dbw->affectedRows();
+ }
+
+ # Special case: revisions may be deleted while renaming...
+ if ( $affectedCount < $count && $table === 'revision' && $timestampColumn !== null ) {
+ # If some revisions were not renamed, they may have been deleted.
+ # Do a pass on the archive table to get these straglers...
+ $ids = $dbw->selectFieldValues(
+ 'archive',
+ 'ar_id',
+ [
+ 'ar_user_text' => $oldname,
+ 'ar_user' => $userID,
+ // No user,rev_id index, so use timestamp to bound
+ // the rows. This can use the user,timestamp index.
+ "ar_timestamp >= '$minTimestamp'",
+ "ar_timestamp <= '$maxTimestamp'"
+ ],
+ __METHOD__
+ );
+ foreach ( array_chunk( $ids, $wgUpdateRowsPerQuery ) as $batch ) {
+ $dbw->commit( __METHOD__, 'flush' );
+ wfWaitForSlaves();
+
+ $dbw->update(
+ 'archive',
+ [ 'ar_user_text' => $newname ],
+ [ 'ar_user_text' => $oldname, 'ar_id' => $batch ],
+ __METHOD__
+ );
+ }
+ }
+ # Special case: revisions may be restored while renaming...
+ if ( $affectedCount < $count && $table === 'archive' && $timestampColumn !== null ) {
+ # If some revisions were not renamed, they may have been restored.
+ # Do a pass on the revision table to get these straglers...
+ $ids = $dbw->selectFieldValues(
+ 'revision',
+ 'rev_id',
+ [
+ 'rev_user_text' => $oldname,
+ 'rev_user' => $userID,
+ // No user,rev_id index, so use timestamp to bound
+ // the rows. This can use the user,timestamp index.
+ "rev_timestamp >= '$minTimestamp'",
+ "rev_timestamp <= '$maxTimestamp'"
+ ],
+ __METHOD__
+ );
+ foreach ( array_chunk( $ids, $wgUpdateRowsPerQuery ) as $batch ) {
+ $dbw->commit( __METHOD__, 'flush' );
+ wfWaitForSlaves();
+
+ $dbw->update(
+ 'revision',
+ [ 'rev_user_text' => $newname ],
+ [ 'rev_user_text' => $oldname, 'rev_id' => $batch ],
+ __METHOD__
+ );
+ }
+ }
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/Renameuser/includes/RenameuserHooks.php b/www/wiki/extensions/Renameuser/includes/RenameuserHooks.php
new file mode 100644
index 00000000..9fdc29ed
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/includes/RenameuserHooks.php
@@ -0,0 +1,66 @@
+<?php
+
+class RenameuserHooks {
+ /**
+ * Show a log if the user has been renamed and point to the new username.
+ * Don't show the log if the $oldUserName exists as a user.
+ *
+ * @param Article $article
+ * @return bool
+ */
+ public static function onShowMissingArticle( $article ) {
+ $title = $article->getTitle();
+ $oldUser = User::newFromName( $title->getBaseText() );
+ if ( ( $title->getNamespace() === NS_USER || $title->getNamespace() === NS_USER_TALK ) &&
+ ( $oldUser && $oldUser->isAnon() )
+ ) {
+ // Get the title for the base userpage
+ $page = Title::makeTitle( NS_USER, str_replace( ' ', '_', $title->getBaseText() ) )
+ ->getPrefixedDBkey();
+ $out = $article->getContext()->getOutput();
+ LogEventsList::showLogExtract(
+ $out,
+ 'renameuser',
+ $page,
+ '',
+ [
+ 'lim' => 10,
+ 'showIfEmpty' => false,
+ 'msgKey' => [ 'renameuser-renamed-notice', $title->getBaseText() ]
+ ]
+ );
+ }
+
+ return true;
+ }
+
+ /**
+ * Shows link to Special:Renameuser on Special:Contributions/foo
+ *
+ * @param int $id
+ * @param Title $nt
+ * @param array &$tools
+ * @param SpecialPage $sp
+ */
+ public static function onContributionsToolLinks( $id, $nt, array &$tools, SpecialPage $sp ) {
+ if ( $id && $sp->getUser()->isAllowed( 'renameuser' ) ) {
+ $tools['renameuser'] = $sp->getLinkRenderer()->makeKnownLink(
+ SpecialPage::getTitleFor( 'Renameuser' ),
+ $sp->msg( 'renameuser-linkoncontribs' )->text(),
+ [ 'title' => $sp->msg( 'renameuser-linkoncontribs-text' )->parse() ],
+ [ 'oldusername' => $nt->getText() ]
+ );
+ }
+ }
+
+ /**
+ * So users can just type in a username for target and it'll work
+ * @param array &$types
+ * @return bool
+ */
+ public static function onGetLogTypesOnUser( array &$types ) {
+ $types[] = 'renameuser';
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/Renameuser/includes/RenameuserLogFormatter.php b/www/wiki/extensions/Renameuser/includes/RenameuserLogFormatter.php
new file mode 100644
index 00000000..d775a8a0
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/includes/RenameuserLogFormatter.php
@@ -0,0 +1,99 @@
+<?php
+
+/**
+ * LogFormatter for renameuser/renameuser logs
+ */
+class RenameuserLogFormatter extends LogFormatter {
+
+ protected function getMessageParameters() {
+ $params = parent::getMessageParameters();
+ /* Current format:
+ * 1,2,3: normal logformatter params
+ * 4: old username (linked)
+ * (legaciest doesn't have this at all, all in comment)
+ * (legacier uses this as new name and stores old name in target)
+ * 5: new username (linked)
+ * 6: number of edits the user had at the time
+ * (not available except in newest log entries)
+ * 7: new username (raw format for GENDER)
+ * Note that the arrays are zero-indexed, while message parameters
+ * start from 1, so substract one to get array entries below.
+ */
+
+ if ( !isset( $params[3] ) ) {
+ // The oldest format
+ return $params;
+ } elseif ( !isset( $params[4] ) ) {
+ // See comments above
+ $params[4] = $params[3];
+ $params[3] = $this->entry->getTarget()->getText();
+ }
+
+ // Nice link to old user page
+ $title = Title::makeTitleSafe( NS_USER, $params[3] );
+ $link = $this->myPageLink( $title, $params[3] );
+ $params[3] = Message::rawParam( $link );
+
+ // Nice link to new user page
+ $title = Title::makeTitleSafe( NS_USER, $params[4] );
+ $link = $this->myPageLink( $title, $params[4] );
+ $params[4] = Message::rawParam( $link );
+ // GENDER support (using new user page)
+ $params[6] = $title->getText();
+
+ return $params;
+ }
+
+ protected function myPageLink( Title $title = null, $text ) {
+ if ( !$this->plaintext ) {
+ if ( !$title instanceof Title ) {
+ $link = htmlspecialchars( $text );
+ } else {
+ $link = $this->getLinkRenderer()->makeLink( $title, $text );
+ }
+ } else {
+ if ( !$title instanceof Title ) {
+ $link = "[[User:$text]]";
+ } else {
+ $link = '[[' . $title->getPrefixedText() . ']]';
+ }
+ }
+
+ return $link;
+ }
+
+ public function getMessageKey() {
+ $key = parent::getMessageKey();
+ $params = $this->extractParameters();
+
+ // Very old log format, everything in comment
+ if ( !isset( $params[3] ) ) {
+ return "$key-legaciest";
+ } elseif ( !isset( $params[5] ) ) {
+ return "$key-legacier";
+ }
+
+ return $key;
+ }
+
+ public function getPreloadTitles() {
+ $params = $this->extractParameters();
+ if ( !isset( $params[3] ) ) {
+ // Very old log format, everything in comment - legaciest
+ return [];
+ }
+ if ( !isset( $params[4] ) ) {
+ // Old log format - legacier
+ $newUserName = $params[3];
+ } else {
+ $newUserName = $params[4];
+ }
+
+ $title = Title::makeTitleSafe( NS_USER, $newUserName );
+ if ( $title ) {
+ return [ $title ];
+ }
+
+ return [];
+ }
+}
diff --git a/www/wiki/extensions/Renameuser/includes/RenameuserSQL.php b/www/wiki/extensions/Renameuser/includes/RenameuserSQL.php
new file mode 100644
index 00000000..f8808e2e
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/includes/RenameuserSQL.php
@@ -0,0 +1,411 @@
+<?php
+
+use MediaWiki\Auth\AuthManager;
+use MediaWiki\Session\SessionManager;
+
+/**
+ * Class which performs the actual renaming of users
+ */
+class RenameuserSQL {
+ /**
+ * The old username
+ *
+ * @var string
+ * @access private
+ */
+ public $old;
+
+ /**
+ * The new username
+ *
+ * @var string
+ * @access private
+ */
+ public $new;
+
+ /**
+ * The user ID
+ *
+ * @var integer
+ * @access private
+ */
+ public $uid;
+
+ /**
+ * The the tables => fields to be updated
+ *
+ * @var array
+ * @access private
+ */
+ public $tables;
+
+ /**
+ * tables => fields to be updated in a deferred job
+ *
+ * @var array
+ */
+ public $tablesJob;
+
+ /**
+ * Flag that can be set to false, in case another process has already started
+ * the updates and the old username may have already been renamed in the user table.
+ *
+ * @var bool
+ * @access private
+ */
+ public $checkIfUserExists;
+
+ /**
+ * User object of the user performing the rename, for logging purposes
+ *
+ * @var User
+ */
+ private $renamer;
+
+ /**
+ * Reason to be used in the log entry
+ *
+ * @var string
+ */
+ private $reason = '';
+
+ /**
+ * A prefix to use in all debug log messages
+ *
+ * @var string
+ */
+ private $debugPrefix = '';
+
+ /**
+ * Users with more than this number of edits will have their rename operation
+ * deferred via the job queue.
+ */
+ const CONTRIB_JOB = 500;
+
+ // B/C constants for tablesJob field
+ const NAME_COL = 0;
+ const UID_COL = 1;
+ const TIME_COL = 2;
+
+ /**
+ * Constructor
+ *
+ * @param string $old The old username
+ * @param string $new The new username
+ * @param int $uid
+ * @param User $renamer
+ * @param array $options Optional extra options.
+ * 'reason' - string, reason for the rename
+ * 'debugPrefix' - string, prefixed to debug messages
+ * 'checkIfUserExists' - bool, whether to update the user table
+ */
+ public function __construct( $old, $new, $uid, User $renamer, $options = [] ) {
+ $this->old = $old;
+ $this->new = $new;
+ $this->uid = $uid;
+ $this->renamer = $renamer;
+ $this->checkIfUserExists = true;
+
+ if ( isset( $options['checkIfUserExists'] ) ) {
+ $this->checkIfUserExists = $options['checkIfUserExists'];
+ }
+
+ if ( isset( $options['debugPrefix'] ) ) {
+ $this->debugPrefix = $options['debugPrefix'];
+ }
+
+ if ( isset( $options['reason'] ) ) {
+ $this->reason = $options['reason'];
+ }
+
+ $this->tables = []; // Immediate updates
+ $this->tablesJob = []; // Slow updates
+
+ // We still do the table updates here for MIGRATION_WRITE_NEW because reads might
+ // still be falling back.
+ if ( self::getActorMigrationStage() < MIGRATION_NEW ) {
+ $this->tables['image'] = [ 'img_user_text', 'img_user' ];
+ $this->tables['oldimage'] = [ 'oi_user_text', 'oi_user' ];
+ $this->tables['filearchive'] = [ 'fa_user_text', 'fa_user' ];
+
+ // If this user has a large number of edits, use the jobqueue
+ // T134136: if this is for user_id=0, then use the queue as the edit count is unknown.
+ if ( !$uid || User::newFromId( $uid )->getEditCount() > self::CONTRIB_JOB ) {
+ $this->tablesJob['revision'] = [
+ self::NAME_COL => 'rev_user_text',
+ self::UID_COL => 'rev_user',
+ self::TIME_COL => 'rev_timestamp',
+ 'uniqueKey' => 'rev_id'
+ ];
+ $this->tablesJob['archive'] = [
+ self::NAME_COL => 'ar_user_text',
+ self::UID_COL => 'ar_user',
+ self::TIME_COL => 'ar_timestamp',
+ 'uniqueKey' => 'ar_id'
+ ];
+ $this->tablesJob['logging'] = [
+ self::NAME_COL => 'log_user_text',
+ self::UID_COL => 'log_user',
+ self::TIME_COL => 'log_timestamp',
+ 'uniqueKey' => 'log_id'
+ ];
+ } else {
+ $this->tables['revision'] = [ 'rev_user_text', 'rev_user' ];
+ $this->tables['archive'] = [ 'ar_user_text', 'ar_user' ];
+ $this->tables['logging'] = [ 'log_user_text', 'log_user' ];
+ }
+ // Recent changes is pretty hot, deadlocks occur if done all at once
+ if ( wfQueriesMustScale() ) {
+ $this->tablesJob['recentchanges'] = [ 'rc_user_text', 'rc_user', 'rc_timestamp' ];
+ } else {
+ $this->tables['recentchanges'] = [ 'rc_user_text', 'rc_user' ];
+ }
+ }
+
+ Hooks::run( 'RenameUserSQL', [ $this ] );
+ }
+
+ protected function debug( $msg ) {
+ if ( $this->debugPrefix ) {
+ $msg = "{$this->debugPrefix}: $msg";
+ }
+ wfDebugLog( 'Renameuser', $msg );
+ }
+
+ /**
+ * Do the rename operation
+ * @return true
+ */
+ public function rename() {
+ global $wgAuth, $wgUpdateRowsPerJob;
+
+ // Grab the user's edit count first, used in log entry
+ $contribs = User::newFromId( $this->uid )->getEditCount();
+
+ $dbw = wfGetDB( DB_MASTER );
+ $dbw->startAtomic( __METHOD__ );
+
+ Hooks::run( 'RenameUserPreRename', [ $this->uid, $this->old, $this->new ] );
+
+ // Make sure the user exists if needed
+ if ( $this->checkIfUserExists && !self::lockUserAndGetId( $this->old ) ) {
+ $this->debug( "User {$this->old} does not exist, bailing out" );
+
+ return false;
+ }
+
+ // Rename and touch the user before re-attributing edits to avoid users still being
+ // logged in and making new edits (under the old name) while being renamed.
+ $this->debug( "Starting rename of {$this->old} to {$this->new}" );
+ $dbw->update( 'user',
+ [ 'user_name' => $this->new, 'user_touched' => $dbw->timestamp() ],
+ [ 'user_name' => $this->old, 'user_id' => $this->uid ],
+ __METHOD__
+ );
+ if ( self::getActorMigrationStage() >= MIGRATION_WRITE_BOTH ) {
+ $dbw->update( 'actor',
+ [ 'actor_name' => $this->new ],
+ [ 'actor_name' => $this->old, 'actor_user' => $this->uid ],
+ __METHOD__
+ );
+ }
+
+ // Reset token to break login with central auth systems.
+ // Again, avoids user being logged in with old name.
+ $user = User::newFromId( $this->uid );
+
+ if ( class_exists( SessionManager::class ) &&
+ is_callable( [ SessionManager::singleton(), 'invalidateSessionsForUser' ] )
+ ) {
+ $user->load( User::READ_LATEST );
+ SessionManager::singleton()->invalidateSessionsForUser( $user );
+ } else {
+ $authUser = $wgAuth->getUserInstance( $user );
+ $authUser->resetAuthToken();
+ }
+
+ // Purge user cache
+ $user->invalidateCache();
+
+ // Update ipblock list if this user has a block in there.
+ $dbw->update( 'ipblocks',
+ [ 'ipb_address' => $this->new ],
+ [ 'ipb_user' => $this->uid, 'ipb_address' => $this->old ],
+ __METHOD__
+ );
+ // Update this users block/rights log. Ideally, the logs would be historical,
+ // but it is really annoying when users have "clean" block logs by virtue of
+ // being renamed, which makes admin tasks more of a pain...
+ $oldTitle = Title::makeTitle( NS_USER, $this->old );
+ $newTitle = Title::makeTitle( NS_USER, $this->new );
+ $this->debug( "Updating logging table for {$this->old} to {$this->new}" );
+
+ $logTypesOnUser = SpecialLog::getLogTypesOnUser();
+
+ $dbw->update( 'logging',
+ [ 'log_title' => $newTitle->getDBkey() ],
+ [ 'log_type' => $logTypesOnUser,
+ 'log_namespace' => NS_USER,
+ 'log_title' => $oldTitle->getDBkey() ],
+ __METHOD__
+ );
+
+ // Do immediate re-attribution table updates...
+ foreach ( $this->tables as $table => $fieldSet ) {
+ list( $nameCol, $userCol ) = $fieldSet;
+ $dbw->update( $table,
+ [ $nameCol => $this->new ],
+ [ $nameCol => $this->old, $userCol => $this->uid ],
+ __METHOD__
+ );
+ }
+
+ /** @var RenameUserJob[] $jobs */
+ $jobs = []; // jobs for all tables
+ // Construct jobqueue updates...
+ // FIXME: if a bureaucrat renames a user in error, he/she
+ // must be careful to wait until the rename finishes before
+ // renaming back. This is due to the fact the the job "queue"
+ // is not really FIFO, so we might end up with a bunch of edits
+ // randomly mixed between the two new names. Some sort of rename
+ // lock might be in order...
+ foreach ( $this->tablesJob as $table => $params ) {
+ $userTextC = $params[self::NAME_COL]; // some *_user_text column
+ $userIDC = $params[self::UID_COL]; // some *_user column
+ $timestampC = $params[self::TIME_COL]; // some *_timestamp column
+
+ $res = $dbw->select( $table,
+ [ $timestampC ],
+ [ $userTextC => $this->old, $userIDC => $this->uid ],
+ __METHOD__,
+ [ 'ORDER BY' => "$timestampC ASC" ]
+ );
+
+ $jobParams = [];
+ $jobParams['table'] = $table;
+ $jobParams['column'] = $userTextC;
+ $jobParams['uidColumn'] = $userIDC;
+ $jobParams['timestampColumn'] = $timestampC;
+ $jobParams['oldname'] = $this->old;
+ $jobParams['newname'] = $this->new;
+ $jobParams['userID'] = $this->uid;
+ // Timestamp column data for index optimizations
+ $jobParams['minTimestamp'] = '0';
+ $jobParams['maxTimestamp'] = '0';
+ $jobParams['count'] = 0;
+ // Unique column for slave lag avoidance
+ if ( isset( $params['uniqueKey'] ) ) {
+ $jobParams['uniqueKey'] = $params['uniqueKey'];
+ }
+
+ // Insert jobs into queue!
+ while ( true ) {
+ $row = $dbw->fetchObject( $res );
+ if ( !$row ) {
+ # If there are any job rows left, add it to the queue as one job
+ if ( $jobParams['count'] > 0 ) {
+ $jobs[] = Job::factory( 'renameUser', $oldTitle, $jobParams );
+ }
+ break;
+ }
+ # Since the ORDER BY is ASC, set the min timestamp with first row
+ if ( $jobParams['count'] === 0 ) {
+ $jobParams['minTimestamp'] = $row->$timestampC;
+ }
+ # Keep updating the last timestamp, so it should be correct
+ # when the last item is added.
+ $jobParams['maxTimestamp'] = $row->$timestampC;
+ # Update row counter
+ $jobParams['count']++;
+ # Once a job has $wgUpdateRowsPerJob rows, add it to the queue
+ if ( $jobParams['count'] >= $wgUpdateRowsPerJob ) {
+ $jobs[] = Job::factory( 'renameUser', $oldTitle, $jobParams );
+ $jobParams['minTimestamp'] = '0';
+ $jobParams['maxTimestamp'] = '0';
+ $jobParams['count'] = 0;
+ }
+ }
+ $dbw->freeResult( $res );
+ }
+
+ // Log it!
+ $logEntry = new ManualLogEntry( 'renameuser', 'renameuser' );
+ $logEntry->setPerformer( $this->renamer );
+ $logEntry->setTarget( $oldTitle );
+ $logEntry->setComment( $this->reason );
+ $logEntry->setParameters( [
+ '4::olduser' => $this->old,
+ '5::newuser' => $this->new,
+ '6::edits' => $contribs
+ ] );
+ $logid = $logEntry->insert();
+ // Include the log_id in the jobs as a DB commit marker
+ foreach ( $jobs as $job ) {
+ $job->params['logId'] = $logid;
+ }
+
+ // Insert any jobs as needed. If this fails, then an exception will be thrown and the
+ // DB transaction will be rolled back. If it succeeds but the DB commit fails, then the
+ // jobs will see that the transaction was not committed and will cancel themselves.
+ $count = count( $jobs );
+ if ( $count > 0 ) {
+ JobQueueGroup::singleton()->push( $jobs );
+ $this->debug( "Queued $count jobs for {$this->old} to {$this->new}" );
+ }
+
+ // Commit the transaction
+ $dbw->endAtomic( __METHOD__ );
+
+ $that = $this;
+ $dbw->onTransactionIdle( function () use ( $that, $dbw, $logEntry, $logid ) {
+ $dbw->startAtomic( __METHOD__ );
+ // Clear caches and inform authentication plugins
+ $user = User::newFromId( $that->uid );
+ $user->load( User::READ_LATEST );
+ // Call $wgAuth for backwards compatibility
+ if ( class_exists( AuthManager::class ) ) {
+ AuthManager::callLegacyAuthPlugin( 'updateExternalDB', [ $user ] );
+ } else {
+ global $wgAuth;
+ $wgAuth->updateExternalDB( $user );
+ }
+ // Trigger the UserSaveSettings hook, which is the replacement for
+ // $wgAuth->updateExternalDB()
+ $user->saveSettings();
+ Hooks::run( 'RenameUserComplete', [ $that->uid, $that->old, $that->new ] );
+ // Publish to RC
+ $logEntry->publish( $logid );
+ $dbw->endAtomic( __METHOD__ );
+ } );
+
+ $this->debug( "Finished rename for {$this->old} to {$this->new}" );
+
+ return true;
+ }
+
+ /**
+ * @param string $name Current wiki local user name
+ * @return integer Returns 0 if no row was found
+ */
+ private static function lockUserAndGetId( $name ) {
+ return (int)wfGetDB( DB_MASTER )->selectField(
+ 'user',
+ 'user_id',
+ [ 'user_name' => $name ],
+ __METHOD__,
+ [ 'FOR UPDATE' ]
+ );
+ }
+
+ /**
+ * Fetch the core actor table schema migration stage
+ * @return int MIGRATION_* constant
+ */
+ public static function getActorMigrationStage() {
+ global $wgActorTableSchemaMigrationStage;
+
+ return isset( $wgActorTableSchemaMigrationStage )
+ ? $wgActorTableSchemaMigrationStage
+ : ( is_callable( User::class, 'getActorId' ) ? MIGRATION_NEW : MIGRATION_OLD );
+ }
+}
diff --git a/www/wiki/extensions/Renameuser/includes/SpecialRenameuser.php b/www/wiki/extensions/Renameuser/includes/SpecialRenameuser.php
new file mode 100644
index 00000000..090adeef
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/includes/SpecialRenameuser.php
@@ -0,0 +1,432 @@
+<?php
+
+/**
+ * Special page that allows authorised users to rename
+ * user accounts
+ */
+class SpecialRenameuser extends SpecialPage {
+ public function __construct() {
+ parent::__construct( 'Renameuser', 'renameuser' );
+ }
+
+ public function doesWrites() {
+ return true;
+ }
+
+ /**
+ * Show the special page
+ *
+ * @param mixed $par Parameter passed to the page
+ * @throws PermissionsError
+ * @throws ReadOnlyError
+ * @throws UserBlockedError
+ */
+ public function execute( $par ) {
+ global $wgContLang, $wgCapitalLinks;
+
+ $this->setHeaders();
+ $this->addHelpLink( 'Help:Renameuser' );
+
+ $out = $this->getOutput();
+ $out->addWikiMsg( 'renameuser-summary' );
+
+ $user = $this->getUser();
+ if ( !$user->isAllowed( 'renameuser' ) ) {
+ throw new PermissionsError( 'renameuser' );
+ }
+
+ if ( wfReadOnly() ) {
+ throw new ReadOnlyError;
+ }
+
+ if ( $user->isBlocked() ) {
+ throw new UserBlockedError( $this->getUser()->mBlock );
+ }
+
+ $this->useTransactionalTimeLimit();
+
+ $request = $this->getRequest();
+ $showBlockLog = $request->getBool( 'submit-showBlockLog' );
+ $usernames = explode( '/', $par, 2 ); // this works as "/" is not valid in usernames
+ $oldnamePar = trim( str_replace( '_', ' ', $request->getText( 'oldusername', $usernames[0] ) ) );
+ $oldusername = Title::makeTitle( NS_USER, $oldnamePar );
+ $newnamePar = isset( $usernames[1] ) ? $usernames[1] : null;
+ $newnamePar = trim( str_replace( '_', ' ', $request->getText( 'newusername', $newnamePar ) ) );
+ // Force uppercase of newusername, otherwise wikis
+ // with wgCapitalLinks=false can create lc usernames
+ $newusername = Title::makeTitleSafe( NS_USER, $wgContLang->ucfirst( $newnamePar ) );
+ $oun = is_object( $oldusername ) ? $oldusername->getText() : '';
+ $nun = is_object( $newusername ) ? $newusername->getText() : '';
+ $token = $user->getEditToken();
+ $reason = $request->getText( 'reason' );
+
+ $move_checked = $request->getBool( 'movepages', !$request->wasPosted() );
+ $suppress_checked = $request->getCheck( 'suppressredirect' );
+
+ $warnings = [];
+ if ( $oun && $nun && !$request->getCheck( 'confirmaction' ) ) {
+ Hooks::run( 'RenameUserWarning', [ $oun, $nun, &$warnings ] );
+ }
+
+ $out->addHTML(
+ Xml::openElement( 'form', [
+ 'method' => 'post',
+ 'action' => $this->getPageTitle()->getLocalURL(),
+ 'id' => 'renameuser'
+ ] ) .
+ Xml::openElement( 'fieldset' ) .
+ Xml::element( 'legend', null, $this->msg( 'renameuser' )->text() ) .
+ Xml::openElement( 'table', [ 'id' => 'mw-renameuser-table' ] ) .
+ "<tr>
+ <td class='mw-label'>" .
+ Xml::label( $this->msg( 'renameuserold' )->text(), 'oldusername' ) .
+ "</td>
+ <td class='mw-input'>" .
+ Xml::input( 'oldusername', 20, $oun, [ 'type' => 'text', 'tabindex' => '1' ] ) . ' ' .
+ "</td>
+ </tr>
+ <tr>
+ <td class='mw-label'>" .
+ Xml::label( $this->msg( 'renameusernew' )->text(), 'newusername' ) .
+ "</td>
+ <td class='mw-input'>" .
+ Xml::input( 'newusername', 20, $nun, [ 'type' => 'text', 'tabindex' => '2' ] ) .
+ "</td>
+ </tr>
+ <tr>
+ <td class='mw-label'>" .
+ Xml::label( $this->msg( 'renameuserreason' )->text(), 'reason' ) .
+ "</td>
+ <td class='mw-input'>" .
+ Xml::input(
+ 'reason',
+ 40,
+ $reason,
+ [ 'type' => 'text', 'tabindex' => '3', 'maxlength' => 255 ]
+ ) .
+ '</td>
+ </tr>'
+ );
+ if ( $user->isAllowed( 'move' ) ) {
+ $out->addHTML( "
+ <tr>
+ <td>&#160;
+ </td>
+ <td class='mw-input'>" .
+ Xml::checkLabel( $this->msg( 'renameusermove' )->text(), 'movepages', 'movepages',
+ $move_checked, [ 'tabindex' => '4' ] ) .
+ '</td>
+ </tr>'
+ );
+
+ if ( $user->isAllowed( 'suppressredirect' ) ) {
+ $out->addHTML( "
+ <tr>
+ <td>&#160;
+ </td>
+ <td class='mw-input'>" .
+ Xml::checkLabel(
+ $this->msg( 'renameusersuppress' )->text(),
+ 'suppressredirect',
+ 'suppressredirect',
+ $suppress_checked,
+ [ 'tabindex' => '5' ]
+ ) .
+ '</td>
+ </tr>'
+ );
+ }
+ }
+ if ( $warnings ) {
+ $warningsHtml = [];
+ foreach ( $warnings as $warning ) {
+ $warningsHtml[] = is_array( $warning ) ?
+ $this->msg( $warning[0] )->rawParams( array_slice( $warning, 1 ) )->escaped() :
+ $this->msg( $warning )->escaped();
+ }
+
+ $out->addHTML( "
+ <tr>
+ <td class='mw-label'>" . $this->msg( 'renameuserwarnings' )->escaped() . "
+ </td>
+ <td class='mw-input'>" .
+ '<ul class="error"><li>' .
+ implode( '</li><li>', $warningsHtml ) . '</li></ul>' .
+ '</td>
+ </tr>'
+ );
+ $out->addHTML( "
+ <tr>
+ <td>&#160;
+ </td>
+ <td class='mw-input'>" .
+ Xml::checkLabel(
+ $this->msg( 'renameuserconfirm' )->text(),
+ 'confirmaction',
+ 'confirmaction',
+ false,
+ [ 'tabindex' => '6' ]
+ ) .
+ '</td>
+ </tr>'
+ );
+ }
+ $out->addHTML( "
+ <tr>
+ <td>&#160;
+ </td>
+ <td class='mw-submit'>" .
+ Xml::submitButton(
+ $this->msg( 'renameusersubmit' )->text(),
+ [
+ 'name' => 'submit',
+ 'tabindex' => '7',
+ 'id' => 'submit'
+ ]
+ ) .
+ ' ' .
+ Xml::submitButton(
+ $this->msg( 'renameuser-submit-blocklog' )->text(),
+ [
+ 'name' => 'submit-showBlockLog',
+ 'id' => 'submit-showBlockLog',
+ 'tabindex' => '8'
+ ]
+ ) .
+ '</td>
+ </tr>' .
+ Xml::closeElement( 'table' ) .
+ Xml::closeElement( 'fieldset' ) .
+ Html::hidden( 'token', $token ) .
+ Xml::closeElement( 'form' ) . "\n"
+ );
+
+ // Show block log if requested
+ if ( $showBlockLog && is_object( $oldusername ) ) {
+ $this->showLogExtract( $oldusername, 'block', $out );
+
+ return;
+ }
+
+ if ( $request->getText( 'token' ) === '' ) {
+ # They probably haven't even submitted the form, so don't go further.
+ return;
+ } elseif ( $warnings ) {
+ # Let user read warnings
+ return;
+ } elseif ( !$request->wasPosted() || !$user->matchEditToken( $request->getVal( 'token' ) ) ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>", 'renameuser-error-request' );
+
+ return;
+ } elseif ( !is_object( $oldusername ) ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>",
+ [ 'renameusererrorinvalid', $request->getText( 'oldusername' ) ] );
+
+ return;
+ } elseif ( !is_object( $newusername ) ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>",
+ [ 'renameusererrorinvalid', $request->getText( 'newusername' ) ] );
+
+ return;
+ } elseif ( $oldusername->getText() === $newusername->getText() ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>", 'renameuser-error-same-user' );
+
+ return;
+ }
+
+ // Suppress username validation of old username
+ $olduser = User::newFromName( $oldusername->getText(), false );
+ $newuser = User::newFromName( $newusername->getText(), 'creatable' );
+
+ // It won't be an object if for instance "|" is supplied as a value
+ if ( !is_object( $olduser ) ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>",
+ [ 'renameusererrorinvalid', $oldusername->getText() ] );
+
+ return;
+ }
+ if ( !is_object( $newuser ) || !User::isCreatableName( $newuser->getName() ) ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>",
+ [ 'renameusererrorinvalid', $newusername->getText() ] );
+
+ return;
+ }
+
+ // Check for the existence of lowercase oldusername in database.
+ // Until r19631 it was possible to rename a user to a name with first character as lowercase
+ if ( $oldusername->getText() !== $wgContLang->ucfirst( $oldusername->getText() ) ) {
+ // oldusername was entered as lowercase -> check for existence in table 'user'
+ $dbr = wfGetDB( DB_REPLICA );
+ $uid = $dbr->selectField( 'user', 'user_id',
+ [ 'user_name' => $oldusername->getText() ],
+ __METHOD__ );
+ if ( $uid === false ) {
+ if ( !$wgCapitalLinks ) {
+ $uid = 0; // We are on a lowercase wiki but lowercase username does not exists
+ } else {
+ // We are on a standard uppercase wiki, use normal
+ $uid = $olduser->idForName();
+ $oldusername = Title::makeTitleSafe( NS_USER, $olduser->getName() );
+ }
+ }
+ } else {
+ // oldusername was entered as upperase -> standard procedure
+ $uid = $olduser->idForName();
+ }
+
+ if ( $uid === 0 ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>",
+ [ 'renameusererrordoesnotexist', $oldusername->getText() ] );
+
+ return;
+ }
+
+ if ( $newuser->idForName() !== 0 ) {
+ $out->wrapWikiMsg( "<div class=\"errorbox\">$1</div>",
+ [ 'renameusererrorexists', $newusername->getText() ] );
+
+ return;
+ }
+
+ // Give other affected extensions a chance to validate or abort
+ if ( !Hooks::run(
+ 'RenameUserAbort',
+ [ $uid, $oldusername->getText(), $newusername->getText() ]
+ ) ) {
+ return;
+ }
+
+ // Do the heavy lifting...
+ $rename = new RenameuserSQL(
+ $oldusername->getText(),
+ $newusername->getText(),
+ $uid,
+ $this->getUser(),
+ [ 'reason' => $reason ]
+ );
+ if ( !$rename->rename() ) {
+ return;
+ }
+
+ // If this user is renaming his/herself, make sure that Title::moveTo()
+ // doesn't make a bunch of null move edits under the old name!
+ if ( $user->getId() === $uid ) {
+ $user->setName( $newusername->getText() );
+ }
+
+ // Move any user pages
+ if ( $request->getCheck( 'movepages' ) && $user->isAllowed( 'move' ) ) {
+ $dbr = wfGetDB( DB_REPLICA );
+
+ $pages = $dbr->select(
+ 'page',
+ [ 'page_namespace', 'page_title' ],
+ [
+ 'page_namespace' => [ NS_USER, NS_USER_TALK ],
+ $dbr->makeList( [
+ 'page_title ' . $dbr->buildLike( $oldusername->getDBkey() . '/', $dbr->anyString() ),
+ 'page_title = ' . $dbr->addQuotes( $oldusername->getDBkey() ),
+ ], LIST_OR ),
+ ],
+ __METHOD__
+ );
+
+ $suppressRedirect = false;
+
+ if ( $request->getCheck( 'suppressredirect' ) && $user->isAllowed( 'suppressredirect' ) ) {
+ $suppressRedirect = true;
+ }
+
+ $output = '';
+ $linkRenderer = $this->getLinkRenderer();
+ foreach ( $pages as $row ) {
+ $oldPage = Title::makeTitleSafe( $row->page_namespace, $row->page_title );
+ $newPage = Title::makeTitleSafe( $row->page_namespace,
+ preg_replace( '!^[^/]+!', $newusername->getDBkey(), $row->page_title ) );
+ # Do not autodelete or anything, title must not exist
+ if ( $newPage->exists() && !$oldPage->isValidMoveTarget( $newPage ) ) {
+ $link = $linkRenderer->makeKnownLink( $newPage );
+ $output .= Html::rawElement(
+ 'li',
+ [ 'class' => 'mw-renameuser-pe' ],
+ $this->msg( 'renameuser-page-exists' )->rawParams( $link )->escaped()
+ );
+ } else {
+ $success = $oldPage->moveTo(
+ $newPage,
+ false,
+ $this->msg(
+ 'renameuser-move-log',
+ $oldusername->getText(),
+ $newusername->getText() )->inContentLanguage()->text(),
+ !$suppressRedirect
+ );
+ if ( $success === true ) {
+ # oldPage is not known in case of redirect suppression
+ $oldLink = $linkRenderer->makeLink( $oldPage, null, [], [ 'redirect' => 'no' ] );
+
+ # newPage is always known because the move was successful
+ $newLink = $linkRenderer->makeKnownLink( $newPage );
+
+ $output .= Html::rawElement(
+ 'li',
+ [ 'class' => 'mw-renameuser-pm' ],
+ $this->msg( 'renameuser-page-moved' )->rawParams( $oldLink, $newLink )->escaped()
+ );
+ } else {
+ $oldLink = $linkRenderer->makeKnownLink( $oldPage );
+ $newLink = $linkRenderer->makeLink( $newPage );
+ $output .= Html::rawElement(
+ 'li', [ 'class' => 'mw-renameuser-pu' ],
+ $this->msg( 'renameuser-page-unmoved' )->rawParams( $oldLink, $newLink )->escaped()
+ );
+ }
+ }
+ }
+ if ( $output ) {
+ $out->addHTML( Html::rawElement( 'ul', [], $output ) );
+ }
+ }
+
+ // Output success message stuff :)
+ $out->wrapWikiMsg( "<div class=\"successbox\">$1</div><br style=\"clear:both\" />",
+ [ 'renameusersuccess', $oldusername->getText(), $newusername->getText() ] );
+ }
+
+ /**
+ * @param Title $username
+ * @param string $type
+ * @param OutputPage &$out
+ */
+ protected function showLogExtract( $username, $type, &$out ) {
+ # Show relevant lines from the logs:
+ $logPage = new LogPage( $type );
+ $out->addHTML( Xml::element( 'h2', null, $logPage->getName()->text() ) . "\n" );
+ LogEventsList::showLogExtract( $out, $type, $username->getPrefixedText() );
+ }
+
+ /**
+ * Return an array of subpages beginning with $search that this special page will accept.
+ *
+ * @param string $search Prefix to search for
+ * @param int $limit Maximum number of results to return (usually 10)
+ * @param int $offset Number of results to skip (usually 0)
+ * @return string[] Matching subpages
+ */
+ public function prefixSearchSubpages( $search, $limit, $offset ) {
+ if ( !class_exists( 'UserNamePrefixSearch' ) ) { // check for version 1.27
+ return [];
+ }
+ $user = User::newFromName( $search );
+ if ( !$user ) {
+ // No prefix suggestion for invalid user
+ return [];
+ }
+ // Autocomplete subpage as user list - public to allow caching
+ return UserNamePrefixSearch::search( 'public', $search, $limit, $offset );
+ }
+
+ protected function getGroupName() {
+ return 'users';
+ }
+}
diff --git a/www/wiki/extensions/Renameuser/maintenance/cleanupArchiveUserText.php b/www/wiki/extensions/Renameuser/maintenance/cleanupArchiveUserText.php
index 25f7344f..40ccaae7 100644
--- a/www/wiki/extensions/Renameuser/maintenance/cleanupArchiveUserText.php
+++ b/www/wiki/extensions/Renameuser/maintenance/cleanupArchiveUserText.php
@@ -15,9 +15,16 @@ class CleanupArchiveUserText extends Maintenance {
parent::__construct();
$this->mDescription = 'Update the archive table where users were ' .
'previously renamed, but their archive contributions were not';
+
+ $this->requireExtension( 'Renameuser' );
}
public function execute() {
+ if ( RenameuserSQL::getActorMigrationStage() >= MIGRATION_NEW ) {
+ $this->output( "archive.ar_user_text is no longer used.\n" );
+ return;
+ }
+
$dbw = wfGetDB( DB_MASTER );
do {
$res = $dbw->select(
diff --git a/www/wiki/extensions/Renameuser/maintenance/renameUserCleanup.php b/www/wiki/extensions/Renameuser/maintenance/renameUserCleanup.php
index 136a6630..4adffe7e 100644
--- a/www/wiki/extensions/Renameuser/maintenance/renameUserCleanup.php
+++ b/www/wiki/extensions/Renameuser/maintenance/renameUserCleanup.php
@@ -32,15 +32,22 @@ require_once "$IP/maintenance/Maintenance.php";
class RenameUserCleanup extends Maintenance {
public function __construct() {
parent::__construct();
- $this->mDescription = 'Maintenance script to finish incomplete rename user,'
- . ' in particular to reassign edits that were missed';
+ $this->addDescription( 'Maintenance script to finish incomplete rename user,'
+ . ' in particular to reassign edits that were missed' );
$this->addOption( 'olduser', 'Old user name', true, true );
$this->addOption( 'newuser', 'New user name', true, true );
$this->addOption( 'olduid', 'Old user id in revision records (DANGEROUS)', false, true );
- $this->mBatchSize = 1000;
+ $this->setBatchSize( 1000 );
+
+ $this->requireExtension( 'Renameuser' );
}
public function execute() {
+ if ( RenameuserSQL::getActorMigrationStage() >= MIGRATION_NEW ) {
+ $this->output( "Core xx_user_text fields are no longer used, no updates should be needed.\n" );
+ return;
+ }
+
$this->output( "Rename User Cleanup starting...\n\n" );
$olduser = User::newFromName( $this->getOption( 'olduser' ) );
$newuser = User::newFromName( $this->getOption( 'newuser' ) );
@@ -87,7 +94,7 @@ class RenameUserCleanup extends Maintenance {
* @param User $newuser
*/
public function checkRenameLog( $olduser, $newuser ) {
- $dbr = wfGetDB( DB_SLAVE );
+ $dbr = wfGetDB( DB_REPLICA );
$oldTitle = Title::makeTitle( NS_USER, $olduser->getName() );
@@ -103,8 +110,8 @@ class RenameUserCleanup extends Maintenance {
if ( !$result || !$result->numRows() ) {
// try the old format
if ( class_exists( CommentStore::class ) ) {
- $commentStore = CommentStore::newKey( 'log_comment' );
- $commentQuery = $commentStore->getJoin();
+ $commentStore = CommentStore::getStore();
+ $commentQuery = $commentStore->getJoin( 'log_comment' );
} else {
$commentStore = null;
$commentQuery = [
@@ -140,7 +147,9 @@ class RenameUserCleanup extends Maintenance {
}
} else {
foreach ( $result as $row ) {
- $comment = $commentStore ? $commentStore->getComment( $row )->text : $row->log_comment;
+ $comment = $commentStore
+ ? $commentStore->getComment( 'log_comment', $row )->text
+ : $row->log_comment;
$this->output( 'Found possible log entry of the rename, please check: ' .
$row->log_title . ' with comment ' . $comment .
" on $row->log_timestamp\n" );
@@ -170,7 +179,7 @@ class RenameUserCleanup extends Maintenance {
/**
* @param User $olduser
* @param User $newuser
- * @param $uid
+ * @param int $uid
*/
public function doUpdates( $olduser, $newuser, $uid ) {
$this->updateTable(
@@ -231,12 +240,12 @@ class RenameUserCleanup extends Maintenance {
/**
* @param string $table
- * @param $usernamefield
- * @param $useridfield
- * @param $timestampfield
+ * @param string $usernamefield
+ * @param string $useridfield
+ * @param string $timestampfield
* @param User $olduser
* @param User $newuser
- * @param $uid
+ * @param int $uid
*/
public function updateTable( $table, $usernamefield, $useridfield,
$timestampfield, $olduser, $newuser, $uid
@@ -313,7 +322,7 @@ class RenameUserCleanup extends Maintenance {
$result->seek( $result->numRows() - 1 );
$row = $result->fetchObject();
- $timestamp = $row->$timestampfield;
+ $timestamp = $dbw->addQuotes( $row->$timestampfield );
$updateCondsWithTime = array_merge( $selectConds, [ "$timestampfield >= $timestamp" ] );
$success = $dbw->update(
$table,
diff --git a/www/wiki/extensions/Renameuser/tests/phan/config.php b/www/wiki/extensions/Renameuser/tests/phan/config.php
new file mode 100644
index 00000000..f2660b8a
--- /dev/null
+++ b/www/wiki/extensions/Renameuser/tests/phan/config.php
@@ -0,0 +1,3 @@
+<?php
+
+return require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
diff --git a/www/wiki/extensions/ReplaceText/COPYING b/www/wiki/extensions/ReplaceText/COPYING
new file mode 100644
index 00000000..d159169d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/COPYING
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/www/wiki/extensions/ReplaceText/Gruntfile.js b/www/wiki/extensions/ReplaceText/Gruntfile.js
new file mode 100644
index 00000000..9d52c843
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/Gruntfile.js
@@ -0,0 +1,35 @@
+/* eslint-env node */
+module.exports = function ( grunt ) {
+ var conf = grunt.file.readJSON( 'extension.json' );
+
+ grunt.loadNpmTasks( 'grunt-banana-checker' );
+ grunt.loadNpmTasks( 'grunt-eslint' );
+ grunt.loadNpmTasks( 'grunt-jsonlint' );
+ grunt.loadNpmTasks( 'grunt-stylelint' );
+
+ grunt.initConfig( {
+ eslint: {
+ all: '.'
+ },
+ stylelint: {
+ options: {
+ syntax: 'less'
+ },
+ all: [
+ '**/*.{css,less}',
+ '!vendor/**'
+ ]
+ },
+ banana: conf.MessagesDirs,
+ jsonlint: {
+ all: [
+ '**/*.json',
+ '!node_modules/**',
+ '!vendor/**'
+ ]
+ }
+ } );
+
+ grunt.registerTask( 'test', [ 'eslint', 'stylelint', 'jsonlint', 'banana' ] );
+ grunt.registerTask( 'default', 'test' );
+};
diff --git a/www/wiki/extensions/ReplaceText/README b/www/wiki/extensions/ReplaceText/README
new file mode 100644
index 00000000..f609e250
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/README
@@ -0,0 +1,52 @@
+Replace Text Extension
+
+ Version 1.4.1
+ Yaron Koren, Niklas Laxström and others
+
+This is free software licenced under the GNU General Public Licence. Please
+see http://www.gnu.org/copyleft/gpl.html for further details, including the
+full text and terms of the licence.
+
+== Overview ==
+
+Replace Text is an extension to MediaWiki that creates a new special page,
+Special:ReplaceText, available to anyone who has the 'replacetext'
+privilege, that does a text find-and-replace on all pages in the wiki,
+selectable by namespace. Both the contents of pages and their titles can be
+modified. The search is case-sensitive.
+
+Since the replacement is not undoable, if the replacement string is
+blank or a string that is already contained in the wiki, the 'ReplaceText'
+page prompts the user to confirm the replacement before it is performed.
+
+Each replacement shows up as a wiki edit, with the administrator who
+performed the replacement appearing as the user and an edit summary that
+looks like "Text replacement: 'search string' to 'replacement string'".
+
+For more information, see the extension homepage at:
+http://www.mediawiki.org/wiki/Extension:Replace_Text
+
+== Requirements ==
+
+This version of the Replace Text extension requires MediaWiki 1.23 or higher.
+
+== Installation ==
+
+To install the extension, place the entire 'ReplaceText' directory
+within your MediaWiki 'extensions' directory, then add either of the
+following lines to your 'LocalSettings.php' file:
+
+ wfLoadExtension( 'ReplaceText' );
+ require_once( "$IP/extensions/ReplaceText/ReplaceText.php" );
+
+In order to perform replacements, you must have the 'replacetext' permssion;
+if you are an administrator on your wiki, the easiest way to do this is to
+also add the following line:
+
+ $wgGroupPermissions['sysop']['replacetext'] = true;
+
+== Contact ==
+
+Comments, questions, suggestions and bug reports are welcome, and can
+be placed on the Talk page for the extension, or sent to Yaron at
+yaron57@gmail.com.
diff --git a/www/wiki/extensions/ReplaceText/ReplaceText.i18n.alias.php b/www/wiki/extensions/ReplaceText/ReplaceText.i18n.alias.php
new file mode 100644
index 00000000..48d085f0
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/ReplaceText.i18n.alias.php
@@ -0,0 +1,289 @@
+<?php
+/**
+ * Aliases for special pages
+ *
+ * @file
+ * @ingroup Extensions
+ */
+
+$specialPageAliases = [];
+
+/** English (English) */
+$specialPageAliases['en'] = [
+ 'ReplaceText' => [ 'ReplaceText' ],
+];
+
+/** Arabic (العربية) */
+$specialPageAliases['ar'] = [
+ 'ReplaceText' => [ 'استبدال_نص' ],
+];
+
+/** Egyptian Arabic (مصرى) */
+$specialPageAliases['arz'] = [
+ 'ReplaceText' => [ 'تبديل_نص' ],
+];
+
+/** Western Balochi (بلوچی رخشانی) */
+$specialPageAliases['bgn'] = [
+ 'ReplaceText' => [ 'متنی_جاگیرکورتین' ],
+];
+
+/** Breton (brezhoneg) */
+$specialPageAliases['br'] = [
+ 'ReplaceText' => [ 'Erlc\'hiañTestenn' ],
+];
+
+/** Bosnian (bosanski) */
+$specialPageAliases['bs'] = [
+ 'ReplaceText' => [ 'ZamjenaTeksta' ],
+];
+
+/** Czech (čeština) */
+$specialPageAliases['cs'] = [
+ 'ReplaceText' => [ 'Nahradit_text' ],
+];
+
+/** German (Deutsch) */
+$specialPageAliases['de'] = [
+ 'ReplaceText' => [ 'Text_ersetzen' ],
+];
+
+/** Zazaki (Zazaki) */
+$specialPageAliases['diq'] = [
+ 'ReplaceText' => [ 'MetinVırnayış' ],
+];
+
+/** Lower Sorbian (dolnoserbski) */
+$specialPageAliases['dsb'] = [
+ 'ReplaceText' => [ 'Tekst wuměniś' ],
+];
+
+/** Divehi (ދިވެހިބަސް) */
+$specialPageAliases['dv'] = [
+ 'ReplaceText' => [ 'ލިޔުން_ބަދަލުކުރައްވާ' ],
+];
+
+/** Greek (Ελληνικά) */
+$specialPageAliases['el'] = [
+ 'ReplaceText' => [ 'ΑντικατάστασηΚειμένου' ],
+];
+
+/** Esperanto (Esperanto) */
+$specialPageAliases['eo'] = [
+ 'ReplaceText' => [ 'Anstataŭigi_tekston' ],
+];
+
+/** Persian (فارسی) */
+$specialPageAliases['fa'] = [
+ 'ReplaceText' => [ 'جایگزینی_متن' ],
+];
+
+/** Finnish (suomi) */
+$specialPageAliases['fi'] = [
+ 'ReplaceText' => [ 'Korvaa_teksti' ],
+];
+
+/** French (français) */
+$specialPageAliases['fr'] = [
+ 'ReplaceText' => [ 'Remplacer_texte', 'RemplacerTexte' ],
+];
+
+/** Arpitan (arpetan) */
+$specialPageAliases['frp'] = [
+ 'ReplaceText' => [ 'Remplaciér_lo_tèxto', 'RemplaciérLoTèxto' ],
+];
+
+/** Galician (galego) */
+$specialPageAliases['gl'] = [
+ 'ReplaceText' => [ 'Substituír_o_texto', 'Substituír_texto' ],
+];
+
+/** Swiss German (Alemannisch) */
+$specialPageAliases['gsw'] = [
+ 'ReplaceText' => [ 'Täxt_ersetze' ],
+];
+
+/** Hebrew (עברית) */
+$specialPageAliases['he'] = [
+ 'ReplaceText' => [ 'החלפת_טקסט' ],
+];
+
+/** Croatian (hrvatski) */
+$specialPageAliases['hr'] = [
+ 'ReplaceText' => [ 'Zamjeni_tekst' ],
+];
+
+/** Upper Sorbian (hornjoserbsce) */
+$specialPageAliases['hsb'] = [
+ 'ReplaceText' => [ 'Tekst_narunać' ],
+];
+
+/** Haitian (Kreyòl ayisyen) */
+$specialPageAliases['ht'] = [
+ 'ReplaceText' => [ 'RanplaseTeks' ],
+];
+
+/** Hungarian (magyar) */
+$specialPageAliases['hu'] = [
+ 'ReplaceText' => [ 'Szöveg_csere' ],
+];
+
+/** Interlingua (interlingua) */
+$specialPageAliases['ia'] = [
+ 'ReplaceText' => [ 'Reimplaciar_texto' ],
+];
+
+/** Indonesian (Bahasa Indonesia) */
+$specialPageAliases['id'] = [
+ 'ReplaceText' => [ 'Ganti_teks', 'GantiTeks' ],
+];
+
+/** Italian (italiano) */
+$specialPageAliases['it'] = [
+ 'ReplaceText' => [ 'SostituisciTesto' ],
+];
+
+/** Japanese (日本語) */
+$specialPageAliases['ja'] = [
+ 'ReplaceText' => [ '文字列置換', '文字列の置換' ],
+];
+
+/** Khmer (ភាសាខ្មែរ) */
+$specialPageAliases['km'] = [
+ 'ReplaceText' => [ 'ជំនួសអត្ថបទ' ],
+];
+
+/** Korean (한국어) */
+$specialPageAliases['ko'] = [
+ 'ReplaceText' => [ '찾아바꾸기' ],
+];
+
+/** Colognian (Ripoarisch) */
+$specialPageAliases['ksh'] = [
+ 'ReplaceText' => [ 'Tex tuusche' ],
+];
+
+/** Luxembourgish (Lëtzebuergesch) */
+$specialPageAliases['lb'] = [
+ 'ReplaceText' => [ 'Text_ersetzen' ],
+];
+
+/** Macedonian (македонски) */
+$specialPageAliases['mk'] = [
+ 'ReplaceText' => [ 'ЗамениТекст' ],
+];
+
+/** Malayalam (മലയാളം) */
+$specialPageAliases['ml'] = [
+ 'ReplaceText' => [ 'എഴുത്ത്മാറ്റിച്ചേർക്കുക' ],
+];
+
+/** Marathi (मराठी) */
+$specialPageAliases['mr'] = [
+ 'ReplaceText' => [ 'मजकुरबदला' ],
+];
+
+/** Malay (Bahasa Melayu) */
+$specialPageAliases['ms'] = [
+ 'ReplaceText' => [ 'Ganti_teks' ],
+];
+
+/** Maltese (Malti) */
+$specialPageAliases['mt'] = [
+ 'ReplaceText' => [ 'BiddelTest' ],
+];
+
+/** Norwegian Bokmål (norsk bokmål) */
+$specialPageAliases['nb'] = [
+ 'ReplaceText' => [ 'Teksterstatning' ],
+];
+
+/** Low Saxon (Netherlands) (Nedersaksies) */
+$specialPageAliases['nds-nl'] = [
+ 'ReplaceText' => [ 'Tekste_vervangen' ],
+];
+
+/** Dutch (Nederlands) */
+$specialPageAliases['nl'] = [
+ 'ReplaceText' => [ 'TekstVervangen' ],
+];
+
+/** Occitan (occitan) */
+$specialPageAliases['oc'] = [
+ 'ReplaceText' => [ 'Remplaçar tèxte', 'RemplaçarTèxte' ],
+];
+
+/** Portuguese (português) */
+$specialPageAliases['pt'] = [
+ 'ReplaceText' => [ 'Substituir_texto' ],
+];
+
+/** Sicilian (sicilianu) */
+$specialPageAliases['scn'] = [
+ 'ReplaceText' => [ 'SostituisciTesto' ],
+];
+
+/** Slovak (slovenčina) */
+$specialPageAliases['sk'] = [
+ 'ReplaceText' => [ 'NahradiťText' ],
+];
+
+/** Albanian (shqip) */
+$specialPageAliases['sq'] = [
+ 'ReplaceText' => [ 'ZëvendësoTekstin' ],
+];
+
+/** Serbian (Cyrillic script) (српски (ћирилица)‎) */
+$specialPageAliases['sr-ec'] = [
+ 'ReplaceText' => [ 'ЗамениТекст', 'Замени_текст' ],
+];
+
+/** Swedish (svenska) */
+$specialPageAliases['sv'] = [
+ 'ReplaceText' => [ 'Ersätt_text' ],
+];
+
+/** Swahili (Kiswahili) */
+$specialPageAliases['sw'] = [
+ 'ReplaceText' => [ 'PandikiziaMatini' ],
+];
+
+/** Tagalog (Tagalog) */
+$specialPageAliases['tl'] = [
+ 'ReplaceText' => [ 'Palitan_ang_teksto' ],
+];
+
+/** Turkish (Türkçe) */
+$specialPageAliases['tr'] = [
+ 'ReplaceText' => [ 'MetniDeğiştir' ],
+];
+
+/** Ukrainian (українська) */
+$specialPageAliases['uk'] = [
+ 'ReplaceText' => [ 'Замінити_текст' ],
+];
+
+/** Venetian (vèneto) */
+$specialPageAliases['vec'] = [
+ 'ReplaceText' => [ 'SostuituissiTesto' ],
+];
+
+/** Vietnamese (Tiếng Việt) */
+$specialPageAliases['vi'] = [
+ 'ReplaceText' => [ 'Thay_văn_bản' ],
+];
+
+/** Chinese (中文) */
+$specialPageAliases['zh'] = [
+ 'ReplaceText' => [ '替换文本', '替換文本', '取代文字' ],
+];
+
+/** Simplified Chinese (中文(简体)‎) */
+$specialPageAliases['zh-hans'] = [
+ 'ReplaceText' => [ '替换文本' ],
+];
+
+/** Traditional Chinese (中文(繁體)‎) */
+$specialPageAliases['zh-hant'] = [
+ 'ReplaceText' => [ '替換文字' ],
+];
diff --git a/www/wiki/extensions/ReplaceText/ReplaceText.php b/www/wiki/extensions/ReplaceText/ReplaceText.php
new file mode 100644
index 00000000..dac34b48
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/ReplaceText.php
@@ -0,0 +1,73 @@
+<?php
+/**
+ * Replace Text - a MediaWiki extension that provides a special page to
+ * allow administrators to do a global string find-and-replace on all the
+ * content pages of a wiki.
+ *
+ * https://www.mediawiki.org/wiki/Extension:Replace_Text
+ *
+ * The special page created is 'Special:ReplaceText', and it provides
+ * a form to do a global search-and-replace, with the changes to every
+ * page showing up as a wiki edit, with the administrator who performed
+ * the replacement as the user, and an edit summary that looks like
+ * "Text replace: 'search string' * to 'replacement string'".
+ *
+ * If the replacement string is blank, or is already found in the wiki,
+ * the page provides a warning prompt to the user before doing the
+ * replacement, since it is not easily reversible.
+ */
+
+if ( function_exists( 'wfLoadExtension' ) ) {
+ wfLoadExtension( 'ReplaceText' );
+ // Keep i18n globals so mergeMessageFileList.php doesn't break
+ $wgMessagesDirs['ReplaceText'] = __DIR__ . '/i18n';
+ $wgExtensionMessagesFiles['ReplaceTextAlias'] = __DIR__ . '/ReplaceText.i18n.alias.php';
+ /* wfWarn(
+ 'Deprecated PHP entry point used for Replace Text extension. ' .
+ 'Please use wfLoadExtension instead, ' .
+ 'see https://www.mediawiki.org/wiki/Extension_registration for more details.'
+ ); */
+ return;
+}
+
+if ( !defined( 'MEDIAWIKI' ) ) {
+ die();
+}
+
+define( 'REPLACE_TEXT_VERSION', '1.4.1' );
+
+// credits
+$wgExtensionCredits['specialpage'][] = [
+ 'path' => __FILE__,
+ 'name' => 'Replace Text',
+ 'version' => REPLACE_TEXT_VERSION,
+ 'author' => [ 'Yaron Koren', 'Niklas Laxström', '...' ],
+ 'url' => 'https://www.mediawiki.org/wiki/Extension:Replace_Text',
+ 'descriptionmsg' => 'replacetext-desc',
+ 'license-name' => 'GPL-2.0-or-later'
+];
+
+$wgMessagesDirs['ReplaceText'] = __DIR__ . '/i18n';
+$wgExtensionMessagesFiles['ReplaceTextAlias'] = __DIR__ . '/ReplaceText.i18n.alias.php';
+$wgJobClasses['replaceText'] = 'ReplaceTextJob';
+
+// This extension uses its own permission type, 'replacetext'
+$wgAvailableRights[] = 'replacetext';
+$wgGroupPermissions['sysop']['replacetext'] = true;
+
+$wgHooks['AdminLinks'][] = 'ReplaceTextHooks::addToAdminLinks';
+
+$wgSpecialPages['ReplaceText'] = 'SpecialReplaceText';
+$wgAutoloadClasses['ReplaceTextHooks'] = __DIR__ . '/src/ReplaceTextHooks.php';
+$wgAutoloadClasses['SpecialReplaceText'] = __DIR__ . '/src/SpecialReplaceText.php';
+$wgAutoloadClasses['ReplaceTextJob'] = __DIR__ . '/src/ReplaceTextJob.php';
+$wgAutoloadClasses['ReplaceTextSearch'] = __DIR__ . '/src/ReplaceTextSearch.php';
+
+$wgResourceModules['ext.ReplaceText'] = [
+ 'scripts' => 'ext.ReplaceText.js',
+ 'localBasePath' => 'resources',
+ 'remoteExtPath' => 'ReplaceText/resources',
+];
+
+// Global variables
+$wgReplaceTextUser = null;
diff --git a/www/wiki/extensions/ReplaceText/composer.json b/www/wiki/extensions/ReplaceText/composer.json
new file mode 100644
index 00000000..17019b96
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/composer.json
@@ -0,0 +1,20 @@
+{
+ "require-dev": {
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
+ },
+ "scripts": {
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
+ "test": [
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
+ ]
+ }
+}
diff --git a/www/wiki/extensions/ReplaceText/extension.json b/www/wiki/extensions/ReplaceText/extension.json
new file mode 100644
index 00000000..e9f54da5
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/extension.json
@@ -0,0 +1,73 @@
+{
+ "name": "Replace Text",
+ "version": "1.4.1",
+ "author": [
+ "Yaron Koren",
+ "Niklas Laxström",
+ "..."
+ ],
+ "url": "https://www.mediawiki.org/wiki/Extension:Replace_Text",
+ "descriptionmsg": "replacetext-desc",
+ "license-name": "GPL-2.0-or-later",
+ "type": "specialpage",
+ "GroupPermissions": {
+ "sysop": {
+ "replacetext": true
+ }
+ },
+ "AvailableRights": [
+ "replacetext"
+ ],
+ "SpecialPages": {
+ "ReplaceText": "SpecialReplaceText"
+ },
+ "JobClasses": {
+ "replaceText": "ReplaceTextJob"
+ },
+ "MessagesDirs": {
+ "ReplaceText": [
+ "i18n"
+ ]
+ },
+ "ResourceModules": {
+ "ext.ReplaceText": {
+ "scripts": [
+ "ext.ReplaceText.js"
+ ]
+ },
+ "ext.ReplaceTextStyles": {
+ "styles": [
+ "ext.ReplaceText.css"
+ ]
+ }
+ },
+ "ResourceFileModulePaths": {
+ "localBasePath": "resources",
+ "remoteExtPath": "ReplaceText/resources"
+ },
+ "ExtensionMessagesFiles": {
+ "ReplaceTextAlias": "ReplaceText.i18n.alias.php"
+ },
+ "AutoloadClasses": {
+ "ReplaceTextHooks": "src/ReplaceTextHooks.php",
+ "SpecialReplaceText": "src/SpecialReplaceText.php",
+ "ReplaceTextJob": "src/ReplaceTextJob.php",
+ "ReplaceTextSearch": "src/ReplaceTextSearch.php",
+ "ReplaceTextUtils": "src/ReplaceTextUtils.php"
+ },
+ "Hooks": {
+ "AdminLinks": [
+ "ReplaceTextHooks::addToAdminLinks"
+ ],
+ "SpecialMovepageAfterMove": [
+ "ReplaceTextHooks::replaceTextReminder"
+ ],
+ "UserGetReservedNames": [
+ "ReplaceTextHooks::getReservedNames"
+ ]
+ },
+ "config": {
+ "ReplaceTextUser": null
+ },
+ "manifest_version": 1
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/af.json b/www/wiki/extensions/ReplaceText/i18n/af.json
new file mode 100644
index 00000000..15d141ed
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/af.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Naudefj"
+ ]
+ },
+ "replacetext": "Vervang teks",
+ "replacetext-desc": "Administrateurs kan via 'n [[Special:ReplaceText|spesiale bladsy]] teks in alle bladsye soek en vervang",
+ "replacetext_originaltext": "Oorspronklike teks:",
+ "replacetext_replacementtext": "Vervangende teks:",
+ "replacetext_optionalfilters": "Opsionele filters:",
+ "replacetext_categorysearch": "Vervang slegs in kategorie:",
+ "replacetext_prefixsearch": "Vervang slegs in bladsye met voorvoegsel:",
+ "replacetext_editpages": "Vervang teks in die bladsy-inhoud",
+ "replacetext_movepages": "Vervang teks in bladsyname (waar moontlik)",
+ "replacetext_givetarget": "U moet die string wat vervang moet word verskaf",
+ "replacetext_nonamespace": "U moet ten minste een naamruimte kies.",
+ "replacetext_editormove": "U moet ten minste een van die vervangingsopsies kies.",
+ "replacetext_choosepagesforedit": "Kies die {{PLURAL:$3|bladsy|blaaie}} waar u '$1' met '$2' wil vervang:",
+ "replacetext_choosepagesformove": "Vervang \"$1\" met \"$2\" in die volgende {{PLURAL:$3|bladsynaam|bladsyname}}:",
+ "replacetext_cannotmove": "Die volgende {{PLURAL:$1|bladsy|blaaie}} kan nie geskuif word nie:",
+ "replacetext_formovedpages": "Vir geskuifde bladsye:",
+ "replacetext_savemovedpages": "Stoor die ou bladsyname as aansture na die nuwe name",
+ "replacetext_watchmovedpages": "Hou hierdie bladsy dop",
+ "replacetext_invertselections": "Omgekeerde seleksie",
+ "replacetext_replace": "Vervang",
+ "replacetext_success": "\"$1\" word in $3 {{PLURAL:$3|bladsy|blaaie}} met \"$2\" vervang.",
+ "replacetext_noreplacement": "Daar was geen bladsye wat die teks '$1' bevat gevind nie.",
+ "replacetext_nomove": "Daar is geen bladsye met \"$1\" in die naam gevind nie.",
+ "replacetext_nosuchcategory": "Die kategorie \"$1\" bestaan nie.",
+ "replacetext_return": "Terug na die vorm.",
+ "replacetext_blankwarning": "Omdat u teks met niks vervang kan hierdie aksie nie ongedaan gemaak word nie.\nWil u voortgaan?",
+ "replacetext_continue": "Gaan voort",
+ "replacetext_editsummary": "Teks vervang - '$1' na '$2'",
+ "right-replacetext": "Doen vervangings oor die hele wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ais.json b/www/wiki/extensions/ReplaceText/i18n/ais.json
new file mode 100644
index 00000000..db6ce6e6
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ais.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Tokoabibi"
+ ]
+ },
+ "replacetext_invertselections": "kabelihan mipili’"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ar.json b/www/wiki/extensions/ReplaceText/i18n/ar.json
new file mode 100644
index 00000000..3152ccf5
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ar.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Alnokta",
+ "Meno25",
+ "OsamaK",
+ "Ouda",
+ "ديفيد",
+ "أحمد"
+ ]
+ },
+ "replacetext": "استبدال النصوص",
+ "replacetext-desc": "تتيح [[Special:ReplaceText|صفحة خاصة]] لتمكين الإداريين من إجراء عمليات الإيجاد و&nbsp;الاستبدال للنصوص في كل صفحات المحتوى في الويكي",
+ "replacetext_docu": "لاستبدال نص بغيره في كل الصفحات العادية في هذه الويكي {{gender:|أدخل|أدخلي}} مقطعي النص هنا ثم {{gender:|اضغط|اضغطي}} \"{{int:replacetext_continue}}\"، ستُعرض عليك عندها قائمة الصفحات التي تحوي نص البحث، ويمكنك اختيار الصفحات التي {{gender:|تريد|تريدين}} استبدالها.\nاسمك سيظهر في تأريخات الصفحات بوصفك من {{gender:|أجرى|أجرت}} التعديلات.",
+ "replacetext_originaltext": "النص الأصلي:",
+ "replacetext_replacementtext": "نص الاستبدال:",
+ "replacetext_useregex": "استعمل العبارات الاعتيادية",
+ "replacetext_regexdocu": "(مثال: وضع القيمة \"أ(.*)ج\" في \"{{int:replacetext_originaltext}}\" و \"أج$1\" في \"{{int:replacetext_replacementtext}}\" ستستبدل النصّ \"أبج\" بالنص \"أجب\".)",
+ "replacetext_optionalfilters": "مرشحات اختيارية:",
+ "replacetext_categorysearch": "استبدل فقط في التصنيف:",
+ "replacetext_prefixsearch": "استبدل فقط في الصفحات ذات البادئة:",
+ "replacetext_editpages": "استبدل النص في محتويات الصفحة",
+ "replacetext_movepages": "استبدل النص في عناوين الصفحات إن أمكن",
+ "replacetext_givetarget": "لابد من تحديد النصّ الذي تريد استبداله",
+ "replacetext_nonamespace": "يجب اختيار نطاق واحد على الأقل.",
+ "replacetext_editormove": "لابد أن تختار خيار واحد على الأقل من خيارات الاستبدال.",
+ "replacetext_choosepagesforedit": "استبدال النصّ '$1' بالنصّ '$2' في محتوى {{PLURAL:$3||الصفحة التالية|الصفحتين التاليتين|الصفحات التالية}}:",
+ "replacetext_choosepagesformove": "استبدل النصّ \"$1\" بالنصّ \"$2\" في {{PLURAL:$3||عنوان الصفحة التالية|عنواني الصفحتين التاليتين|عناوين الصفحات التالية}}:",
+ "replacetext_cannotmove": "لا يمكن نقل {{PLURAL:$1||الصفحة التالية|الصفحتين التاليتين|الصفحات التالية}}:",
+ "replacetext_formovedpages": "للصفحات المنقولة:",
+ "replacetext_savemovedpages": "احفظ العناوين القديمة كتحويلات إلى العناوين الجديدة",
+ "replacetext_watchmovedpages": "راقب هذه الصفحات",
+ "replacetext_invertselections": "اعكس الاختيارات",
+ "replacetext_replace": "استبدل",
+ "replacetext_success": "سوف تستبدل النصّ '$1' بالنصّ '$2' في {{PLURAL:$3||صفحة واحدة|صفحتين|$3 صفحات|$3 صفحة}}.",
+ "replacetext_noreplacement": "لا توجد صفحات تحوي النصّ '$1'.",
+ "replacetext_nomove": "لا توجد صفحات تحوي عناوينها '$1'.",
+ "replacetext_nosuchcategory": "لا يوجد تصنيف بالاسم \"$1\".",
+ "replacetext_return": "ارجع إلى الاستمارة",
+ "replacetext_warning": "'''تحذير''': توجد {{PLURAL:$1||صفحة واحدة تحتوي|صفحتان تحتويان|$1 صفحات تحتوي|$1 صفحة تحتوي}} بالفعل على نصّ الاستبدال '$2'. إذا أجريت هذا الاستبدال فلن تصبح قادرًا على تمييز استبدالاتك من تلك النصوص.",
+ "replacetext_blankwarning": "سلسلة الاستبدال فارغة لذا فلن تكون هذه العملية عكسية.",
+ "replacetext_continue": "استمرار",
+ "replacetext_editsummary": "استبدال النص - '$1' ب'$2'",
+ "right-replacetext": "أجرِ استبدال النصّ في الويكي بأكملها",
+ "action-replacetext": "أجرِ استبدال النصّ في الويكي بأكملها"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/arc.json b/www/wiki/extensions/ReplaceText/i18n/arc.json
new file mode 100644
index 00000000..bd905ad9
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/arc.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Basharh"
+ ]
+ },
+ "replacetext_originaltext": "ܟܬܒܬܐ ܫܪܫܝܬܐ:",
+ "replacetext_watchmovedpages": "ܪܗܝ ܦܐܬܬ̈ܐ ܗܠܝܢ",
+ "replacetext_invertselections": "ܐܗܦܟ ܠܓܘܒܝ̈ܐ"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/arz.json b/www/wiki/extensions/ReplaceText/i18n/arz.json
new file mode 100644
index 00000000..222efa67
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/arz.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ghaly",
+ "Meno25",
+ "Ramsis II"
+ ]
+ },
+ "replacetext": "استبدل النص",
+ "replacetext-desc": "يوفر [[Special:ReplaceText|صفحة خاصة]] للسماح للإداريين للقيام بعملية أوجد واستبدل على نص فى كل صفحات المحتوى لويكي",
+ "replacetext_docu": "لاستبدال سلسلة نص بأخرى عبر كل الصفحات العادية فى هذا الويكى، أدخل قطعتى النص هنا ثم اضغط 'استمرار'. سيعرض عليك بعد ذلك قائمة بالصفحات التى تحتوى على نص البحث، ويمكنك اختيار اللواتى تريد الاستبدال فيها. اسمك سيظهر فى تواريخ الصفحات كالمستخدم المسؤول عن أية تغييرات.",
+ "replacetext_originaltext": "النص الأصلي:",
+ "replacetext_replacementtext": "نص الاستبدال:",
+ "replacetext_movepages": "استبدل النص فى عناوين الصفحات، عندما يكون ممكنا",
+ "replacetext_choosepagesforedit": "من فضلك اختار {{PLURAL:$3|الصفحه|الصفحات}} اللى فيها عايز تستبدل ب'$1' '$2':",
+ "replacetext_choosepagesformove": "استبدل \"$1\" ب\"$2\" فى {{PLURAL:$3||اسم الصفحة التالية|اسمى الصفحتين التاليتين|أسماء الصفحات التالية}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|الصفحة|الصفحات}} التالية لا يمكن نقلها:",
+ "replacetext_savemovedpages": "احفظ العناوين القديمة كتحويلات للعناوين الجديدة",
+ "replacetext_invertselections": "عكس الاختيارات",
+ "replacetext_replace": "استبدل",
+ "replacetext_success": "'$1' ح تتبدل بـ '$2' فى $3 {{PLURAL:$3|صفحه|صفحات}}.",
+ "replacetext_noreplacement": "لا صفحات تم العثور عليها تحتوى على السلسلة '$1'.",
+ "replacetext_return": "رجوع إلى الإستمارة",
+ "replacetext_warning": "فيه $1 {{PLURAL:$1|$1 صفحه|$1 صفحات}} فيها سلسلة الاستبدال، '$2'.\nلو أنك قمت بالاستبدال ده مش هاتقدر تفصل استبدالاتك من السلاسل دى.\nاستمرار مع الاستبدال؟",
+ "replacetext_blankwarning": "لأن سلسلة الاستبدال فارغة، هذه العملية لن تكون عكسية؛ استمر؟",
+ "replacetext_continue": "استمر",
+ "replacetext_editsummary": "استبدال النص - '$1' ب'$2'",
+ "right-replacetext": "القيام باستبدال للسلاسل فى الويكى بأكمله"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ast.json b/www/wiki/extensions/ReplaceText/i18n/ast.json
new file mode 100644
index 00000000..476f4429
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ast.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xuacu"
+ ]
+ },
+ "replacetext": "Reemplazar testu",
+ "replacetext-desc": "Ufre una [[Special:ReplaceText|páxina especial]] que permite a los alministradores facer una gueta y sustitución global d'una cadena de testu en toles páxines de conteníu d'una wiki",
+ "replacetext_docu": "Pa sustituir una cadena de testu por otra en toles páxines regulares d'esta wiki, escribi equí les dos pieces de testu y llueu calca \"{{int:replacetext_continue}}\".\nDempués s'amosará una llista de les páxines que contienen el testu buscáu, y podrás esbillar aquelles nes que quieras sustituilu.\nEl to nome apaecerá nos historiales de les páxines como l'usuariu responsable de cualesquier cambiu.",
+ "replacetext_originaltext": "Testu orixinal:",
+ "replacetext_replacementtext": "Testu de sustitución:",
+ "replacetext_useregex": "Usar espresiones regulares",
+ "replacetext_regexdocu": "(Exemplu: los valores \"a(.*)c\" pa \"{{int:replacetext_originaltext}}\" y \"ac$1\" pa \"{{int:replacetext_replacementtext}}\" camudarán \"abc\" por \"acb\".)",
+ "replacetext_optionalfilters": "Peñeres opcionales:",
+ "replacetext_categorysearch": "Sustituir sólo na categoría:",
+ "replacetext_prefixsearch": "Sustituir sólo nes páxines col prefixu:",
+ "replacetext_editpages": "Sustituir el testu nel conteníu de la páxina",
+ "replacetext_movepages": "Sustituir el testu nos títulos de les páxines, si ye posible",
+ "replacetext_givetarget": "Debes conseñar la cadena que se va a sustituir.",
+ "replacetext_nonamespace": "Debes escoyer, polo menos, un espaciu de nomes.",
+ "replacetext_editormove": "Debes escoyer polo menos una de les opciones de sustitución.",
+ "replacetext_choosepagesforedit": "Sustituír \"$1\" por \"$2\" nel testu de {{PLURAL:$3|la páxina siguiente|les páxines siguientes}}:",
+ "replacetext_choosepagesformove": "Sustituír \"$1\" por \"$2\" {{PLURAL:$3|nel títulu de la páxina siguiente|nos títulos de les páxines siguientes}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|La siguiente páxina|Les siguientes páxines}} nun se {{PLURAL:$1|pue|puen}} mover:",
+ "replacetext_formovedpages": "Pa páxines movies:",
+ "replacetext_savemovedpages": "Guardar los títulos antiguos como redireiciones a los títulos nuevos",
+ "replacetext_watchmovedpages": "Vixilar eses páxines",
+ "replacetext_invertselections": "Invertir seleiciones",
+ "replacetext_replace": "Sustituir",
+ "replacetext_success": "\"$1\" se sustituirá por \"$2\" en {{PLURAL:$3|una páxina|$3 páxines}}.",
+ "replacetext_noreplacement": "Nun s'alcontraron páxines que contengan la cadena de caráuteres «$1».",
+ "replacetext_nomove": "Nun s'alcontraron páxines que contengan «$1» nel títulu.",
+ "replacetext_nosuchcategory": "Nun esiste denguna categoría col nome «$1».",
+ "replacetext_return": "Volver al formulariu.",
+ "replacetext_warning": "'''Avisu:''' Hai {{PLURAL:$1|una páxina|$1 páxines}} que yá {{PLURAL:$1|contién|contienen}} la cadena de sustitución «$2». Si faes esta sustitución nun podrás distinguir los tos cambios d'estes cadenes.",
+ "replacetext_blankwarning": "'''Avisu:''' Como la cadena de sustitución ta balera, esta operación nun sedrá reversible.",
+ "replacetext_continue": "Siguir",
+ "replacetext_announce": "Anunciar eses ediciones per $1 y llistes de siguimientu",
+ "replacetext_editsummary": "Sustitución de testu - de «$1» a «$2»",
+ "right-replacetext": "Facer les sustituciones de la cadena na wiki ensembre",
+ "action-replacetext": "facer sustituciones de cadena na wiki ensembre",
+ "replacetext_reminder": "Pa cambiar tamién los enllaces a esta páxina n'otres páxines, por favor, visita $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/az.json b/www/wiki/extensions/ReplaceText/i18n/az.json
new file mode 100644
index 00000000..9029801a
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/az.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cekli829"
+ ]
+ },
+ "replacetext_originaltext": "Orijinal mətn:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/azb.json b/www/wiki/extensions/ReplaceText/i18n/azb.json
new file mode 100644
index 00000000..e1b1857a
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/azb.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mousa"
+ ]
+ },
+ "replacetext": "یازینی دَییشدیر",
+ "replacetext-desc": "ایداره‌چیلره ویکی‌نین بوتون مقاله‌لرینده سراسری بیر یازی آختاریب و دَییشدیرمگی ایجازه وئرن بیر [[Special:ReplaceText|اؤزل صحیفه]] تعمین ائدیر.",
+ "replacetext_docu": "بوتون بو ویکی‌ده معمولی صحیفه‌لر اوستونده بیر یازینی آیری بیر یازی ایله دَییشدیرمک اوچون، او ایکی یازی پارچالارینی بوردا یازین و «{{int:replacetext_continue}}»-ی وورون.\nسونرا سیزه آختاریش یازیسی اولان صحیفه‌لرین لیستی گؤستریله‌جک و سیزه دَییشدیرمک ایسته‌دیگینیزلری سئچه بیلرسینیز.\nصحیفه‌لرین گئچمیشلرینده سیزین آدینیز دَییشدیرمگه مسئول اولان ایستیفاده‌چی عونوانیندا گؤرونه‌جکدیر.",
+ "replacetext_originaltext": "ایلکین یازی:",
+ "replacetext_replacementtext": "یئرینه قویما یازیسی:",
+ "replacetext_useregex": "دوزنلی ایفاده‌لر (رِگولار اِکسپرِشن) ایشلدین",
+ "replacetext_regexdocu": "(میثال: «{{int:replacetext_originaltext}}» اوچون «a(.*)c» دَیَری و «{{int:replacetext_replacementtext}}» اوچون «ac$1» دَیَری، «abc»-ی «acb» ایله دَییشدیره‌جکدیر.)",
+ "replacetext_optionalfilters": "ایستگه باغلی سۆزگَجلر:",
+ "replacetext_categorysearch": "یالنیز بؤلمه‌ده یئرینه قوی:",
+ "replacetext_prefixsearch": "یالنیز بو اؤن‌اکلری اولان صحیفه‌لرده یئرینه قوی:",
+ "replacetext_editpages": "یازینی مقاله ایچینده‌کیلرده یئرینه قوی",
+ "replacetext_movepages": "اولسا، یازینی صحیفه باشلیقلاریندا یئرینه قوی",
+ "replacetext_givetarget": "یئرینه قویولان یازینی گرک بیلیندیره‌سینیز.",
+ "replacetext_nonamespace": "گرک آزی بیر آدفضاسی بیلیندیره‌سینیز.",
+ "replacetext_editormove": "گرک یئرینه قویماق سئچمه‌لریندن آزی بیرینی سئچه‌سینیز.",
+ "replacetext_choosepagesforedit": "بو {{PLURAL:$3|صحیفه‌نین یازیسیندا|صحیفه‌لرین یازیلاریندا}} «$1»-ین یئرینه «$2»-ی قوی:",
+ "replacetext_choosepagesformove": "بو {{PLURAL:$3|صحیفه‌نین باشلیغیندا|صحیفه‌لرین باشلیقلاریندا}} «$1»-ین یئرینه «$2»-ی قوی:",
+ "replacetext_cannotmove": "بو {{PLURAL:$1|صحیفه‌نی|صحیفه‌لری}} آپارماق اولماز:",
+ "replacetext_formovedpages": "آپاریلان صحیفه‌لر اوچون:",
+ "replacetext_savemovedpages": "اسکی باشلیقلاردا یئنی باشلیقلارا یول‌لاندیرما قئید ائت",
+ "replacetext_watchmovedpages": "بو صحیفه‌لری ایزله",
+ "replacetext_invertselections": "سئچیلمیشلری دؤندر",
+ "replacetext_replace": "یئرینه قوی",
+ "replacetext_success": "{{PLURAL:$3|بیر|$3}} صحیفه‌ده «$1»-ین یئرینه «$2» قویولاجاقدیر.",
+ "replacetext_noreplacement": "«$1» یازیسی اولان هئچ بیر صحیفه تاپیلمادی.",
+ "replacetext_nomove": "«$1» باشلیغی اولان هئچ بیر صحیفه تاپیلمادی.",
+ "replacetext_nosuchcategory": "«$1» آدی ایله بیر بؤلمه یوخدور.",
+ "replacetext_return": "قورما قاییت.",
+ "replacetext_warning": "'''دیقت:''' ایندی {{PLURAL:$1|بیر|$1}} دنه «$2» یئرینه قویولان یازیسی اولان صحیفه واردیر. اگر بو یئرینه قویماغی ائتسز، اؤز یئرینه قویدوقلارینیزی بو یازیلاردان آییرا بیلنمه‌یه‌جکسینیز.",
+ "replacetext_blankwarning": "'''دیقت:''' یئرینه قویولان یازینین بوش اولدوغونا گؤره، بو ایشی دؤندره بیلنمه‌یه‌جکسینیز.",
+ "replacetext_continue": "داوام ائت",
+ "replacetext_editsummary": "یازی یئرینه قویما - «$1»-ی «$2»-یه",
+ "right-replacetext": "یازی یئرینه قویمانی بوتون ویکی‌ده ائت",
+ "action-replacetext": "یازی یئرینه قویمانی بوتون ویکی‌ده ائت"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ba.json b/www/wiki/extensions/ReplaceText/i18n/ba.json
new file mode 100644
index 00000000..7e63e9cf
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ba.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Assele",
+ "Рустам Нурыев"
+ ]
+ },
+ "replacetext": "Тексты алмаштырырға",
+ "replacetext-desc": "Хакимдәргә бөтә эстәлек биттәрендә тексты табып алмаштырырға мөмкинлек биреүсе [[Special:ReplaceText|махсус бит]] менән тәьмин итә",
+ "replacetext_docu": "Был викиның бөтә биттәрендә бер текст юлын икенсе менән алмаштырыр өсөн, ике текст керетегеҙ һәм \"Дауам итергә\" төймәһенә баҫығыҙ.\nАртабан һеҙгә эҙләнгән тексты үҙ эсенә алған биттәр исемлеге күрһәтеләсәк, һеҙ улар араһында алмаштырырға теләгәндәрен һайлай алаһығыҙ.\nҺеҙҙең исемегеҙ биттәрҙең үҙгәртеү тарихтарында үҙгәртеүҙәргә яуаплы ҡатнашыусы булараҡ күрһәтеләсәк.",
+ "replacetext_originaltext": "Сығанаҡ текст:",
+ "replacetext_replacementtext": "Алмаш текст:",
+ "replacetext_useregex": "Регуляр аңлатмаларҙы ҡулланырға",
+ "replacetext_regexdocu": "(Миҫал: \"Сығанаҡ текст\" өсөн \"a(.*)c\" аңлатмаһы һәм \"Алмаш текст\" өсөн \"ac$1\" \"abc\" тексын \"acb\" тип алмаштырасаҡ.)",
+ "replacetext_optionalfilters": "Мөһим булмаған һөҙгөстәр:",
+ "replacetext_categorysearch": "Был категорияла ғына алмаштырырға:",
+ "replacetext_prefixsearch": "Ошо хәрефтәр менән башланған биттәрҙә генә алмаштырырға:",
+ "replacetext_editpages": "Тексты бит эстәлектәрендә алмаштырырға",
+ "replacetext_movepages": "Тексты бит исемдәрендә, мөмкин булһа, алмаштырырға",
+ "replacetext_givetarget": "Һеҙ алмаштырыла торған юлды күрһәтергә тейешһегеҙ.",
+ "replacetext_nonamespace": "Һеҙ кәмендә бер исемдәр арауығын һайларға тейешһегеҙ.",
+ "replacetext_editormove": "Һеҙ кәмендә бер алмаштырыу төрөн һайларға тейешһегеҙ.",
+ "replacetext_choosepagesforedit": "\"$1\" тексын \"$2\" менән түбәндәге {{PLURAL:$3|1=биттә|биттәрҙә}} алмаштырырға:",
+ "replacetext_choosepagesformove": "\"$1\" тексын \"$2\" менән түбәндәге бит {{PLURAL:$3|1=исемендә|исемдәрендә}} алмаштырырға:",
+ "replacetext_cannotmove": "Түбәндәге {{PLURAL:$1|1=биттең|биттәрҙең}} исемен үҙгәртеп булмай:",
+ "replacetext_formovedpages": "Исемдәре үҙгәртелгән биттәр өсөн:",
+ "replacetext_savemovedpages": "Иҫке исемдәрен яңы исемдәргә йүнәлтеүҙәр рәүешендә һаҡларға",
+ "replacetext_watchmovedpages": "Был биттәрҙе күҙәтеүҙәр исемлегенә индерергә",
+ "replacetext_invertselections": "Һайланғандарҙы әйләндерергә",
+ "replacetext_replace": "Алмаштырырға",
+ "replacetext_success": "\"$1\" \"$2\" менән $3 {{PLURAL:$3|биттә}} алмаштырыласаҡ.",
+ "replacetext_noreplacement": "\"$1\" юлын үҙ эсенә алған бер бит тә табылманы.",
+ "replacetext_nomove": "Исемендә \"$1\" булған бер бит тә табылманы.",
+ "replacetext_nosuchcategory": "\"$1\" исемле бер категория ла юҡ.",
+ "replacetext_return": "Формаға кире ҡайтырға.",
+ "replacetext_warning": "'''Иғтибар:''' Алмаш \"$2\" тексын үҙ эсенә алған {{PLURAL:$1|$1 бит}} бар инде. Әгәр һеҙ алмаштырыуҙы башҡарһағыҙ, алмаштырылған текстарҙы булғандарынан айыра алмаясаҡһығыҙ.",
+ "replacetext_blankwarning": "'''Иғтибар:'''Алмаш текст буш булғанға күрә, был ғәмәлде кире алыу мөмкин түгел.",
+ "replacetext_continue": "Дауам итергә",
+ "replacetext_editsummary": "\"$1\" тексын \"$2\" менән алмаштырыу",
+ "right-replacetext": "Бөтә викила тексты алмаштырыу"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/bcc.json b/www/wiki/extensions/ReplaceText/i18n/bcc.json
new file mode 100644
index 00000000..24003043
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/bcc.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Baloch Afghanistan"
+ ]
+ },
+ "replacetext_categorysearch": "جایگرین کورتین پکت بی تهرِ تا:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/be-tarask.json b/www/wiki/extensions/ReplaceText/i18n/be-tarask.json
new file mode 100644
index 00000000..1a53f763
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/be-tarask.json
@@ -0,0 +1,47 @@
+{
+ "@metadata": {
+ "authors": [
+ "EugeneZelenko",
+ "Jim-by",
+ "Wizardist",
+ "Zedlik",
+ "Red Winged Duck"
+ ]
+ },
+ "replacetext": "Замяніць тэкст",
+ "replacetext-desc": "Дадае [[Special:ReplaceText|спэцыяльную старонку]], якая дазваляе адміністратарам глябальны пошук і замену тэксту ва усіх старонках вікі",
+ "replacetext_docu": "Каб замяніць адзін радок на іншы ва ўсіх звычайных старонках гэтай вікі, увядзіце два радкі тут, а потым націсьніце «{{int:replacetext_continue}}».\nБудзе паказаны сьпіс старонак, якія ўтрымліваюць тэкст, які Вы шукалі, і Вы зможаце выбраць старонкі, дзе Вы жадаеце зрабіць замену.\nВаша імя будзе запісанае ў гісторыю старонкі, таму што ўдзельнікі адказныя за ўсе зробленыя зьмены.",
+ "replacetext_originaltext": "Арыгінальны тэкст:",
+ "replacetext_replacementtext": "Тэкст на замену:",
+ "replacetext_useregex": "Выкарыстоўваць рэгулярныя выразы",
+ "replacetext_regexdocu": "(Напрыклад, выразы «a(.*)c» ў полі «{{int:replacetext_originaltext}}» і «ac$1» у полі «{{int:replacetext_replacementtext}}» прывядуць да замены «abc» на «acb».)",
+ "replacetext_optionalfilters": "Неабавязковыя фільтры:",
+ "replacetext_categorysearch": "Замяніць толькі ў катэгорыі:",
+ "replacetext_prefixsearch": "Замяніць толькі ў старонках, назвы якіх пачынаюцца з:",
+ "replacetext_editpages": "Замяніць тэкст ў зьмесьце старонак",
+ "replacetext_movepages": "Замяніць тэкст у назвах старонак, калі гэта магчыма",
+ "replacetext_givetarget": "Вам неабходна пазначыць радок для замены.",
+ "replacetext_nonamespace": "Вам неабходна выбраць хаця б адну прастору назваў.",
+ "replacetext_editormove": "Вам неабходна выбраць хаця б адну з наладаў пераносу.",
+ "replacetext_choosepagesforedit": "Калі ласка, абярыце {{PLURAL:$3|1=старонку, на якой|старонкі, на якіх}} Вы жадаеце замяніць «$1» на «$2»:",
+ "replacetext_choosepagesformove": "Замяніць «$1» на «$2» у {{PLURAL:$3|1=назьве наступнай старонкі|назвах наступных старонак}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|1=Наступная старонка ня можа быць перанесена|Наступныя старонкі ня могуць быць перанесеныя}}:",
+ "replacetext_formovedpages": "Для перанесеных старонак:",
+ "replacetext_savemovedpages": "Захаваць старыя назвы як перанакіраваньні на новыя",
+ "replacetext_watchmovedpages": "Назіраць за гэтымі старонкамі",
+ "replacetext_invertselections": "Адваротны выбар",
+ "replacetext_replace": "Замяніць",
+ "replacetext_success": "«$1» будзе заменены на «$2» ў $3 {{PLURAL:$3|старонцы|старонках|старонках}}.",
+ "replacetext_noreplacement": "Старонак, якія ўтрымліваюць тэкст «$1» ня знойдзена.",
+ "replacetext_nomove": "Ня знойдзена старонак, у назвах якіх утрымліваецца «$1».",
+ "replacetext_nosuchcategory": "Не існуе катэгорыі з назвай «$1».",
+ "replacetext_return": "Вярнуцца да формы.",
+ "replacetext_warning": "'''Папярэджаньне:''' Існуе $1 {{PLURAL:$1|старонка, якая ўтрымлівае|старонкі, якія ўтрымліваюць|старонак, якія ўтрымліваюць}} тэкст на замену «$2».\nКалі Вы зробіце гэту замену, Вы ня зможаце аддзяліць Вашыя замены ад гэтых тэкстаў.",
+ "replacetext_blankwarning": "У выніку таго, што радок, на які павінна адбыцца замена, пусты, апэрацыя ня будзе выкананая.\nВы жадаеце працягваць?",
+ "replacetext_continue": "Працягваць",
+ "replacetext_announce": "Анансаваць гэтыя праўкі праз $1 і сьпісы назіраньня",
+ "replacetext_editsummary": "Замена тэксту — «$1» на «$2»",
+ "right-replacetext": "замена тэксту ва ўсёй вікі",
+ "action-replacetext": "замяняць радкі ва ўсёй вікі",
+ "replacetext_reminder": "Каб таксама зьмяніць спасылкі на гэтую старонку зь іншых старонак, перайдзіце на $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/bg.json b/www/wiki/extensions/ReplaceText/i18n/bg.json
new file mode 100644
index 00000000..e3dd378a
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/bg.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "DCLXVI",
+ "StanProg"
+ ]
+ },
+ "replacetext": "Заместване на текст",
+ "replacetext-desc": "Предоставя [[Special:ReplaceText|специална страница]], чрез която администраторите могат да извършват глобално откриване-и-заместване на низове в страниците на уикито",
+ "replacetext_originaltext": "Оригинален текст:",
+ "replacetext_replacementtext": "Текст за заместване:",
+ "replacetext_choosepagesforedit": "Замяна на „$1“ с „$2“ в текста на {{PLURAL:$3|следната страница|следните $3 страници}}:\nИзберете страници, в които желаете да замените :",
+ "replacetext_replace": "Заместване",
+ "replacetext_success": "Заместване на „$1“ с „$2“ в {{PLURAL:$3|една страница|$3 страници}} .",
+ "replacetext_noreplacement": "Не бяха открити страници, съдържащи низа „$1“.",
+ "replacetext_blankwarning": "'''Предупреждение:''' Тъй като низът за заместване е празен, процесът на заместване ще бъде необратим.",
+ "replacetext_continue": "Продължаване",
+ "replacetext_editsummary": "Замяна на текст – „$1“ с „$2“"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/bn.json b/www/wiki/extensions/ReplaceText/i18n/bn.json
new file mode 100644
index 00000000..5fc45c00
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/bn.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bellayet",
+ "Wikitanvir",
+ "Aftabuzzaman",
+ "Bodhisattwa"
+ ]
+ },
+ "replacetext": "লেখা প্রতিস্থাপন",
+ "replacetext_originaltext": "মূল লেখা:",
+ "replacetext_replacementtext": "প্রতিস্থাপিত লেখা:",
+ "replacetext_useregex": "রেগুলার এক্সপ্রেশন ব্যবহার করো",
+ "replacetext_optionalfilters": "ঐচ্ছিক ফিল্টার:",
+ "replacetext_categorysearch": "শুধুমাত্র বিষয়শ্রেণীতেই প্রতিস্থাপন করো:",
+ "replacetext_formovedpages": "স্থানান্তরিত পাতাগুলির জন্য:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/br.json b/www/wiki/extensions/ReplaceText/i18n/br.json
new file mode 100644
index 00000000..0f9a0fc0
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/br.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fohanno",
+ "Fulup",
+ "Y-M D"
+ ]
+ },
+ "replacetext": "Erlec'hiañ an destenn",
+ "replacetext-desc": "Pourchas a ra ur [[Special:ReplaceText|bajenn dibar]] a aotre ar verourien da erlec'hiañ steudadoù arouezennoù dre arouezennoù all er wiki a-bezh",
+ "replacetext_docu": "Evit erlec'hiañ ur steudad arouezennoù gant unan all e holl bajennoù boutin ar wiki-mañ e c'hallit merkañ an div destenn amañ ha klikañ war 'kenderc'hel'.\nDiskouezet e vo deoc'h ur roll pajennoù m'emañ an destenn klasket enno ha gallout a reot dibab ar re a fell deoc'h cheñch.\nWar wel e teuio hoc'h anv war roll istor pep pajenn evit ma vo gouezet gant piv eo bet graet ar cheñchamant.",
+ "replacetext_originaltext": "Testenn orin :",
+ "replacetext_replacementtext": "Testenn erlec'hiañ :",
+ "replacetext_useregex": "Ober gant jedadennoù reoliek",
+ "replacetext_regexdocu": "(Da skouer : Talvoudenn \"a(.*)c\" evit \"Testenn orin\" ha \"ac$1\" evit \"Testenn erlec'hiañ\" a vo erlec'ho \"abc\" gant \"acb\".)",
+ "replacetext_optionalfilters": "Siloù diret :",
+ "replacetext_categorysearch": "Erlec'hiañ er rummad hepken :",
+ "replacetext_prefixsearch": "Erlec'hiañ hepken er bajennoù gant ar rakger :",
+ "replacetext_editpages": "Erlec'hiañ an destenn e-mesk danvez ar bajenn",
+ "replacetext_movepages": "Erlec'hiañ an destenn e titl ar pajennoù, pa vez posupl",
+ "replacetext_givetarget": "Rankout a rit reiñ ar chadenn a rank bezañ erlec'hiet.",
+ "replacetext_nonamespace": "Rankout a rit dibab un esaouenn anv d'an nebeutañ.",
+ "replacetext_editormove": "Rankout a rit dibab d'an nebeutañ un dibarzh erlec'hiañ.",
+ "replacetext_choosepagesforedit": "Erlec'hiañ \"$1\" gant \"$2\" e testenn ar bajenn{{PLURAL:$3||où}} da heul :",
+ "replacetext_choosepagesformove": "Erlec'hiañ \"$1\" gant \"$2\" e titl{{PLURAL:$3| ar bajenn da heul|où ar bajennoù da heul}} :",
+ "replacetext_cannotmove": "Ne c'hell ket bezañ fiñvet ar bajenn{{PLURAL:$1||où}} da heul :",
+ "replacetext_formovedpages": "Evit ar pajennoù dilec'hiet :",
+ "replacetext_savemovedpages": "Enrollañ an titloù kozh evel adkasoù davet an titloù nevez",
+ "replacetext_watchmovedpages": "Evezhiañ ar pajennoù-mañ",
+ "replacetext_invertselections": "Eilpennañ an diuzadennoù",
+ "replacetext_replace": "Erlec'hiañ",
+ "replacetext_success": "\"$1\" a vo erlec'hiet gant \"$2\" e $3 pajenn{{PLURAL:$3||}}.",
+ "replacetext_noreplacement": "N'eus bet kavet pajenn ebet gant an neudennad « $1 ».",
+ "replacetext_nomove": "N'eo bet kavet pennad ebet gant \"$1\" en ul lodenn eus an titl.",
+ "replacetext_nosuchcategory": "N'eus rummad ebet en anv « $1 ».",
+ "replacetext_return": "Distreiñ d'ar furmskrid.",
+ "replacetext_warning": "'''Diwallit :''' {{PLURAL:$1| $1 bajenn enni| $1 pajenn enno}} ar steudad arouezennoù erlec'hiañ zo dija, \"$2\". Ma kasit ar cheñchamant da benn ne vo ket posupl diforc'hañ ar cheñchamantoù degaset ganeoc'h diouzh an neudennadoù-se ken.",
+ "replacetext_blankwarning": "'''Diwallit : ''' Dre m'eo goullo ar steudad erlec'hiañ, ne vo ket tu da zizober an urzh-mañ.",
+ "replacetext_continue": "Kenderc'hel",
+ "replacetext_editsummary": "Erlec'hiañ an destenn - \"$1\" dre \"$2\"",
+ "right-replacetext": "Krouiñ erlec'hiadurioù testenn er wiki a-bezh"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/bs.json b/www/wiki/extensions/ReplaceText/i18n/bs.json
new file mode 100644
index 00000000..ea3e428e
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/bs.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "CERminator",
+ "Srdjan m"
+ ]
+ },
+ "replacetext": "Zamijeni tekst",
+ "replacetext-desc": "Dodaje [[Special:ReplaceText|posebnu stranicu]] koja omogućava administratorima da izvrše globalnu pretragu nađi-i-zamijeni na svim stranicama sadržaja na wikiju.",
+ "replacetext_docu": "Da biste zamijenili jedan tekst s drugim po svim regularnim stranicama na ovom wikiju, unesite dva dijela teksta ovdje i kliknite \"{{int:replacetext_continue}}\".\nPrikazat će Vam se spisak stranica koje sadrže traženi tekst, i možete odabrati one kod kojih želite taj tekst zamijeniti.\nVaše ime će se prikazati na historiji izmjena stranice kao korisnika koji je odgovoran za sve promjene.",
+ "replacetext_originaltext": "Prvobitni tekst:",
+ "replacetext_replacementtext": "Tekst za zamjenu:",
+ "replacetext_useregex": "Koristi regularne izraze",
+ "replacetext_regexdocu": "(Primjer: vrijednosti od \"a(.*)c\" za \"{{int:replacetext_originaltext}}\" i \"ac$1\" za \"{{int:replacetext_replacementtext}}\" će zamijeniti \"abc\" sa \"acb\".)",
+ "replacetext_optionalfilters": "Opcionalni filteri:",
+ "replacetext_categorysearch": "Zamijeni samo u kategoriji:",
+ "replacetext_prefixsearch": "Zamijeni samo na stranicama sa prefiksom:",
+ "replacetext_editpages": "Zamijeni tekst u sadržaju stranice",
+ "replacetext_movepages": "Zamijeni tekst u naslovima stranica, ako je moguće",
+ "replacetext_givetarget": "Morate navesti znakove koji se zamjenjuju.",
+ "replacetext_nonamespace": "Morate odabrati najmanje jedan imenski prostor.",
+ "replacetext_editormove": "Morate odabrati najmanje jednu od opcija za zamjenu.",
+ "replacetext_choosepagesforedit": "Molimo odaberite {{PLURAL:$3|stranicu|stranice}} za {{PLURAL:$3|koju|koje}} želite zamijeniti '$1' sa '$2':",
+ "replacetext_choosepagesformove": "Zamjena \"$1\" sa \"$2\" u nazivu {{PLURAL:$3|slijedeće stranice|slijedećih stranica}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Slijedeća stranica|Slijedeće stranice}} se ne mogu premjestiti:",
+ "replacetext_formovedpages": "Za premještene stranice:",
+ "replacetext_savemovedpages": "Spremi stare naslove kao preusmjerenja na nove naslove",
+ "replacetext_watchmovedpages": "Prati ove stranice",
+ "replacetext_invertselections": "Preokreni odabir",
+ "replacetext_replace": "Zamijeni",
+ "replacetext_success": "'$1' će biti zamijenjeno sa '$2' na $3 {{PLURAL:$3|stranici|stranice|stranica}}.",
+ "replacetext_noreplacement": "Nije pronađena nijedna stranica koja sadrži '$1'.",
+ "replacetext_nomove": "Nijedna stranica nije pronađena čiji naslov sadrži '$1'.",
+ "replacetext_nosuchcategory": "Ne postoji nijedna kategorija pod nazivom \"$1\".",
+ "replacetext_return": "Nazad na obrazac.",
+ "replacetext_warning": "'''Upozorenje:''' {{PLURAL:$1|Postoji $1 stranica koja već sadrži|Postoje $1 stranice koje već sadrže|Postoji $1 stranica koje već sadrže}} zamjenski tekst ''$2''.\nAko želite napraviti ovu zamjenu nećete biti u mogućnosti da razdvojite Vaše zamjene od ovih tekstova.",
+ "replacetext_blankwarning": "Pošto je zamjenski tekst prazan, ovu operaciju neće biti moguće vratiti.\nDa li želite nastaviti?",
+ "replacetext_continue": "Nastavi",
+ "replacetext_editsummary": "Zamjena teksta – \"$1\" u \"$2\"",
+ "right-replacetext": "Pravljenje zamjene teksta na cijelom wikiju"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ca.json b/www/wiki/extensions/ReplaceText/i18n/ca.json
new file mode 100644
index 00000000..66174adc
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ca.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "SMP",
+ "Solde",
+ "Jmarchn",
+ "Toniher",
+ "Fitoschido"
+ ]
+ },
+ "replacetext": "Substitució de text",
+ "replacetext-desc": "Proporciona una [[Special:ReplaceText|pàgina especial]] per permetre que els administradors a trobar-i-substituir una cadena global per a tots els continguts de les pàgines d'un wiki",
+ "replacetext_docu": "Per reemplaçar una cadena de text amb una altre a través de totes les pàgines regulars d'aquest wiki, introduïu les dues peces de text aquí i llavors polseu \"{{int:replacetext_continue}}\".\nA continuació es mostra una llista de les pàgines que contenen el text de cerca, i podreu triar les pàgines on voleu que es substitueixi.\nEl vostre nom apareixerà en la pàgina de l'historial com a usuari responsable d'aquests canvis.",
+ "replacetext_originaltext": "Text original:",
+ "replacetext_replacementtext": "Text de substitució:",
+ "replacetext_useregex": "Utilitzar expressions regulars",
+ "replacetext_regexdocu": "(Exemple: valors de \"a\"(.*)c\" per \"{{int:replacetext_originaltext}}\" i \"ac$1\" per \"{{int:replacetext_replacementtext}}\" hauria de substituir \"abc\" amb \"acb\")",
+ "replacetext_optionalfilters": "Filtres opcionals:",
+ "replacetext_categorysearch": "Substitueix només en la categoria:",
+ "replacetext_prefixsearch": "Substitueix només en les pàgines amb el prefix:",
+ "replacetext_editpages": "Substitueix el text en els continguts de les pàgines",
+ "replacetext_movepages": "Substitueix el text dels títols de les pàgines, quan sigui possible",
+ "replacetext_givetarget": "S'ha d'especificar la cadena a substituir.",
+ "replacetext_nonamespace": "Heu de seleccionar com a mínim, un espai de noms.",
+ "replacetext_editormove": "Heu de seleccionar com a mínim una de les opcions de substitució.",
+ "replacetext_choosepagesforedit": "Substitueix «$1» amb «$2» en el text de {{PLURAL:$3|la següent pàgina|les següents $3 pàgines}}:",
+ "replacetext_choosepagesformove": "Substituir \"$1\" amb \"$2\" en {{PLURAL:$3|el títol de la pàgina següent|els títols de les següents $3 pàgines}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|La següent pàgina no es pot|Les següents $1 pàgines no es poden}} moure:",
+ "replacetext_formovedpages": "Per a pàgines mogudes:",
+ "replacetext_savemovedpages": "Desa els títols vells com a redireccions a títols nous",
+ "replacetext_watchmovedpages": "Vigila aquestes pàgines",
+ "replacetext_invertselections": "Inverteix les seleccions",
+ "replacetext_replace": "Substitueix",
+ "replacetext_success": "\"$1\" serà substituït per \"$2\" en {{PLURAL:$3|una pàgina|$3 pàgines}}.",
+ "replacetext_noreplacement": "No s'ha trobat cap pàgina que contingui la cadena «$1».",
+ "replacetext_nomove": "No s'ha trobat cap pàgina que contingui el títol \"$1\".",
+ "replacetext_nosuchcategory": "No hi ha cap categoria de nom \"$1\".",
+ "replacetext_return": "Torna al formulari.",
+ "replacetext_warning": "'''Compte!:''' Hi ha {{PLURAL:$1|una pàgina que ja conté|$1 pàgines que ja contenen}} la cadena de reemplaçament, «$2». Si realitzeu aquesta substitució no podreu distingir els vostres reemplaçaments d'aquestes cadenes ja existents.",
+ "replacetext_blankwarning": "\"'Compte!:\"' Perquè la cadena de substitució és buida, aquesta operació no serà reversible.",
+ "replacetext_continue": "Continua",
+ "replacetext_editsummary": "Text de reemplaçament - \"$1\" a \"$2\"",
+ "right-replacetext": "Fer substitucions de cadena a tot el wiki",
+ "action-replacetext": "fer les substitucions de la cadena en tot el wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ce.json b/www/wiki/extensions/ReplaceText/i18n/ce.json
new file mode 100644
index 00000000..993b1648
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ce.json
@@ -0,0 +1,15 @@
+{
+ "@metadata": {
+ "authors": [
+ "Sasan700",
+ "Умар"
+ ]
+ },
+ "replacetext": "Хийца йоза",
+ "replacetext_originaltext": "ДӀадолалун йоза:",
+ "replacetext_optionalfilters": "Тlедожийна доцу литтарш:",
+ "replacetext_cannotmove": "{{PLURAL:$1|1=ТӀехьа йогӀу агӀона цӀе хуьйцийла дац|ТӀехьа йогӀу агӀонийн цӀерш хуьйцийла дац}}:",
+ "replacetext_invertselections": "Харжаран инверт йе",
+ "replacetext_replace": "Хийца",
+ "replacetext_continue": "Кхин дӀа"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/crh-cyrl.json b/www/wiki/extensions/ReplaceText/i18n/crh-cyrl.json
new file mode 100644
index 00000000..203aa181
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/crh-cyrl.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Don Alessandro"
+ ]
+ },
+ "replacetext_cannotmove": "Ашагъыдаки {{PLURAL:$1|саифенинъ ады|саифелернинъ адлары}} денъиштирилип оламай:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/crh-latn.json b/www/wiki/extensions/ReplaceText/i18n/crh-latn.json
new file mode 100644
index 00000000..09b2c0de
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/crh-latn.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Don Alessandro"
+ ]
+ },
+ "replacetext_cannotmove": "Aşağıdaki {{PLURAL:$1|saifeniñ adı|saifelerniñ adları}} deñiştirilip olamay:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/cs.json b/www/wiki/extensions/ReplaceText/i18n/cs.json
new file mode 100644
index 00000000..2ed6c086
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/cs.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chmee2",
+ "Hypothalamus",
+ "Matěj Grabovský",
+ "Mormegil",
+ "Paxt",
+ "Vks",
+ "Ilimanaq29",
+ "Matěj Suchánek"
+ ]
+ },
+ "replacetext": "Nahradit text",
+ "replacetext-desc": "Poskytuje [[Special:ReplaceText|speciální stránku]], která správcům umožňuje globálně najít a nahradit nějaký text na všech obsahových stránkách wiki",
+ "replacetext_docu": "Chcete-li nahradit jeden textový řetězec jiným na všech standardních stránkách této wiki, zadejte sem oba řetězce a poté stiskněte „{{int:replacetext_continue}}“.\nBude vám zobrazen seznam stránek obsahujících hledaný text, kde si pak můžete vybrat ty, ve kterém chcete řetězce nahradit.\nVaše jméno se objeví v historii stránek jako {{GENDER:|uživatel, který změny provedl|uživatelka, která změny provedla}}.",
+ "replacetext_originaltext": "Původní text:",
+ "replacetext_replacementtext": "Nahradit textem:",
+ "replacetext_useregex": "Použít regulární výrazy",
+ "replacetext_regexdocu": "(Příklad: hodnoty „a(.*)c“ v „{{int:replacetext_originaltext}}“ a „ac$1“ v „{{int:replacetext_replacementtext}}“ by nahradily „abc“ za „acb“.)",
+ "replacetext_optionalfilters": "Volitelné filtry:",
+ "replacetext_categorysearch": "Nahradit pouze v kategorii:",
+ "replacetext_prefixsearch": "Nahradit pouze ve stránkách s předponou:",
+ "replacetext_editpages": "Nahradit text v obsahu stránky",
+ "replacetext_movepages": "Nahradit text v názvu stránky, pokud je to možné",
+ "replacetext_givetarget": "Musíte zadat řetězec, který má být nahrazen.",
+ "replacetext_nonamespace": "Musíte vybrat alespoň jeden jmenný prostor.",
+ "replacetext_editormove": "Musíte vybrat alespoň jednu z možností nahrazení.",
+ "replacetext_choosepagesforedit": "Nahradit „$1“ řetězcem „$2“ v textu {{PLURAL:$3|této stránky|těchto $3 stránek}}:",
+ "replacetext_choosepagesformove": "Nahradit „$1“ řetězcem „$2“ v {{PLURAL:$3|názvu následující stránky|názvech následujících $3 stránek}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Následující stránku|Následující $1 stránky|Následujících $1 stránek}} nelze přesunout:",
+ "replacetext_formovedpages": "Pro přesunuté stránky:",
+ "replacetext_savemovedpages": "Zachovat staré názvy stránek jako přesměrování na nové názvy stránek",
+ "replacetext_watchmovedpages": "Sledovat tyto stránky",
+ "replacetext_invertselections": "Invertovat výběr",
+ "replacetext_replace": "Nahradit",
+ "replacetext_success": "Na {{PLURAL:$3|jedné stránce|$3 stránkách}} bude text „$1“ nahrazen textem „$2“.",
+ "replacetext_noreplacement": "Nebyly nalezeny žádné stránky, které by obsahovaly řetězec „$1“.",
+ "replacetext_nomove": "Nebyly nalezeny žádné stránky, jejichž název by obsahoval „$1“.",
+ "replacetext_nosuchcategory": "Neexistuje žádná kategorie s názvem „$1“.",
+ "replacetext_return": "Vrátit se na formulář.",
+ "replacetext_warning": "'''Upozornění:''' {{PLURAL:$1|Existuje jedna strana již obsahující|Existují $1 stránky již obsahující|Existuje $1 stránek již obsahujících}} náhradní řetězec „$2“. Pokud provedete toto nahrazení, nebudete moci rozlišit své náhradní řetězce od původních řetězců.",
+ "replacetext_blankwarning": "'''Upozornění:''' Protože náhradní řetězec je prázdný, tato operace nebude vratná.",
+ "replacetext_continue": "Pokračovat",
+ "replacetext_editsummary": "Nahrazení textu „$1“ textem „$2“",
+ "right-replacetext": "Hledání a nahrazování textu na celé wiki",
+ "action-replacetext": "nahrazovat text na celé wiki",
+ "replacetext_reminder": "Pokud také chcete na jiných stránkách upravit odkazy na tuto stránku, jděte na $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/cy.json b/www/wiki/extensions/ReplaceText/i18n/cy.json
new file mode 100644
index 00000000..e755c28c
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/cy.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lloffiwr"
+ ]
+ },
+ "replacetext": "Disodli testun",
+ "replacetext_originaltext": "Y testun gwreiddiol:",
+ "replacetext_replacementtext": "Y testun newydd:",
+ "replacetext_optionalfilters": "Hidlau dewisol:",
+ "replacetext_watchmovedpages": "Dilyn hynt y tudalennau hyn",
+ "replacetext_invertselections": "Gwrthdroi'r dewis",
+ "replacetext_replace": "Disodler",
+ "replacetext_success": "Caiff \"$1\" ei ddisodli gan \"$2\" mewn $3 {{PLURAL:$3||dudalen|dudalen|tudalen|thudalen|tudalen}}.",
+ "replacetext_noreplacement": "Ni chafwyd hyd i unrhyw dudalennau yn cynnwys y llinyn \"$1\".",
+ "replacetext_continue": "Parhau",
+ "replacetext_editsummary": "Disodli'r testun - \"$1\" i \"$2\""
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/de-formal.json b/www/wiki/extensions/ReplaceText/i18n/de-formal.json
new file mode 100644
index 00000000..f483e20e
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/de-formal.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Imre",
+ "Kghbln",
+ "Umherirrender"
+ ]
+ },
+ "replacetext_docu": "Um einen Text durch einen anderen Text auf allen Inhaltsseiten zu ersetzen, geben Sie hier die beiden Textteile ein und klicken danach auf die „Fortfahren“-Schaltfläche. Auf der dann folgenden Seite erhält man eine Aufzählung der Seiten, die den zu ersetzenden Text enthalten. Dort kann man auch auswählen, auf welchen Seiten die Ersetzungen durchgeführt werden sollen. Ihr Benutzername wird während der Ersetzungen in der Versionsgeschichte aufgenommen.",
+ "replacetext_givetarget": "Sie müssen eine Zeichenkette angeben, die ersetzt werden soll.",
+ "replacetext_editormove": "Sie müssen mindestens eine Ersetzungsoption wählen.",
+ "replacetext_warning": "'''Warnung:''' $1 {{PLURAL:$1|Seite enthält|Seiten enthalten}} bereits den zu ersetzenden Textteil „$2“.\nSofern Sie nun die {{PLURAL:$1|Ersetzung|Ersetzungen}} durchführen, ist eine spätere Unterscheidung zwischen den nunmehr zu ersetzenden und den bereits vorhandenen Textteilen nicht mehr möglich.",
+ "replacetext_blankwarning": "'''Warnung:''' Da der zu ersetzende Textteil leer ist, kann die Operation nicht rückgängig gemacht werden. Möchten Sie dennoch fortfahren?"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/de.json b/www/wiki/extensions/ReplaceText/i18n/de.json
new file mode 100644
index 00000000..fa965654
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/de.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kghbln",
+ "Leithian",
+ "Melancholie",
+ "Merlissimo",
+ "Metalhead64",
+ "Purodha",
+ "Raimond Spekking",
+ "Umherirrender"
+ ]
+ },
+ "replacetext": "Text ersetzen",
+ "replacetext-desc": "Ergänzt eine [[Special:ReplaceText|Spezialseite]], die das Suchen und Ersetzen von Zeichenketten ermöglicht",
+ "replacetext_docu": "Um einen Text durch einen anderen Text auf allen Inhaltsseiten zu ersetzen, gib hier die beiden Textteile ein und klicke danach auf die Schaltfläche „{{int:replacetext_continue}}“. Auf der dann folgenden Seite erhält man eine Aufzählung der Seiten, die den zu ersetzenden Text enthalten. Dort kann man auch auswählen, auf welchen Seiten die Ersetzungen durchgeführt werden sollen. Dein Benutzername wird während der Ersetzungen in der Versionsgeschichte aufgenommen.",
+ "replacetext_originaltext": "Vorhandener Text:",
+ "replacetext_replacementtext": "Neuer Text:",
+ "replacetext_useregex": "Platzhalter und reguläre Ausdrücke verwenden",
+ "replacetext_regexdocu": "(Beispiel: Die Werte für „a(.*)c“ für „{{int:replacetext_originaltext}}“ und „ac$1“ für „{{int:replacetext_replacementtext}}“ würden zur Ersetzung „abc“ durch „acb“ führen.)",
+ "replacetext_optionalfilters": "Optionale Filter:",
+ "replacetext_categorysearch": "Ersetze nur in der Kategorie:",
+ "replacetext_prefixsearch": "Ersetze nur in Seiten mit dem Präfix:",
+ "replacetext_editpages": "Ersetze Text im Seiteninhalt",
+ "replacetext_movepages": "Ersetze Text auch in Seitentiteln (sofern möglich)",
+ "replacetext_givetarget": "Du musst eine Zeichenkette angeben, die ersetzt werden soll.",
+ "replacetext_nonamespace": "Mindestens ein Namensraum muss ausgewählt werden.",
+ "replacetext_editormove": "Du musst mindestens eine Ersetzungsoption wählen.",
+ "replacetext_choosepagesforedit": "Ersetzen von „$1“ durch „$2“ im Text der {{PLURAL:$3|Seite|Seiten}}:",
+ "replacetext_choosepagesformove": "Ersetze „$1“ durch „$2“ im Titel der folgenden {{PLURAL:$3|Seite|Seiten}}:",
+ "replacetext_cannotmove": "Die {{PLURAL:$1|folgende Seite kann|folgenden Seiten können}} nicht verschoben werden:",
+ "replacetext_formovedpages": "Für verschobene Seiten:",
+ "replacetext_savemovedpages": "Eine Weiterleitung für die verschobene Seite anlegen",
+ "replacetext_watchmovedpages": "Diese Seiten beobachten",
+ "replacetext_invertselections": "Auswahl umkehren",
+ "replacetext_replace": "Ersetzen",
+ "replacetext_success": "„$1“ wird durch „$2“ in $3 {{PLURAL:$3|Seite|Seiten}} ersetzt.",
+ "replacetext_noreplacement": "Es wurde keine Seite gefunden, die den Text „$1“ enthält.",
+ "replacetext_nomove": "Es wurde keine Seite gefunden, deren Titel den Text „$1“ enthält.",
+ "replacetext_nosuchcategory": "Es ist keine Kategorie namens „$1“ vorhanden.",
+ "replacetext_return": "Zurück zum Formular.",
+ "replacetext_warning": "'''Warnung:''' $1 {{PLURAL:$1|Seite enthält|Seiten enthalten}} bereits den zu ersetzenden Textteil „$2“.\nSofern du nun die {{PLURAL:$1|Ersetzung|Ersetzungen}} durchführst, ist eine spätere Unterscheidung zwischen den nunmehr zu ersetzenden und den bereits vorhandenen Textteilen nicht mehr möglich.",
+ "replacetext_blankwarning": "'''Warnung:''' Da der zu ersetzende Textteil leer ist, kann die Operation nicht rückgängig gemacht werden. Möchtest du dennoch fortfahren?",
+ "replacetext_continue": "Fortfahren",
+ "replacetext_announce": "Diese Bearbeitungen über $1 und Beobachtungslisten ankündigen",
+ "replacetext_editsummary": "Textersetzung - „$1“ durch „$2“",
+ "right-replacetext": "Textersetzung für das gesamte Wiki durchführen",
+ "action-replacetext": "im gesamten Wiki Zeichenfolgeersetzungen durchzuführen",
+ "replacetext_reminder": "Um auch Links auf diese Seite in anderen Seiten zu verändern, gehe zu $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/diq.json b/www/wiki/extensions/ReplaceText/i18n/diq.json
new file mode 100644
index 00000000..8ee451f6
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/diq.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mirzali",
+ "Marmase"
+ ]
+ },
+ "replacetext_watchmovedpages": "Enê pelan seyr ke",
+ "replacetext_continue": "Dewam ke"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/dsb.json b/www/wiki/extensions/ReplaceText/i18n/dsb.json
new file mode 100644
index 00000000..cb0be336
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/dsb.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "replacetext": "Tekst wuměniś",
+ "replacetext-desc": "Staja [[Special:ReplaceText|specialny bok]] k dispoziciji, aby zmóžnił administratoram operaciju globalnego namakanja-wuměnjenja na wšych wopśimjeśowych bokach wikija pśewjasć",
+ "replacetext_docu": "Aby wuměnił tekst pśez drugi tekst na wšych regularnych bokach w toś tom wikiju, zapódaj wobej tekstowej źěla a klikni na \"{{int:replacetext_continue}}\". Buźoš pótom lisćinu bokow wiźeś, kótarež wopśimuju pytański tekst a móžoš wubraś te, w kótarychž coš jen wuměniś. Twójo mě zjawijo se w stawiznach boka ako wužywaŕ, kótaryž jo zagronity za te změny.",
+ "replacetext_originaltext": "Originalny tekst:",
+ "replacetext_replacementtext": "Tekst pó wuměnjenju:",
+ "replacetext_useregex": "Regularne wuraze wužywaś",
+ "replacetext_regexdocu": "(Pśikład: gódnoty za \"a(.*)c\" za \"{{int:replacetext_originaltext}}\" a \"ac$1\" za \"{{int:replacetext_replacementtext}}\" by \"abc\" pśez \"acb\" wuměnili.)",
+ "replacetext_optionalfilters": "Opcionalne filtry:",
+ "replacetext_categorysearch": "Jano w kategoriji wuměniś:",
+ "replacetext_prefixsearch": "Jano w bokach wuměniś z prefiksom:",
+ "replacetext_editpages": "Tekst w datajowem wopśimjeśu wuměniś",
+ "replacetext_movepages": "Tekst w bokowych titelach wuměniś, jolic móžno",
+ "replacetext_givetarget": "Musyš tekst pódaś, kótaryž ma se wuměniś.",
+ "replacetext_nonamespace": "Musyš nanejmjenjej jaden mjenjowy rum wubraś.",
+ "replacetext_editormove": "Musyš nanejmjenjej jadnu z wuměnjeńskich opcijow wubraś.",
+ "replacetext_choosepagesforedit": "Pšosym wubjeŕ {{PLURAL:$3|bok|boka|boki|boki}}, na {{PLURAL:$3|kótaremž|kótarymaž|kótarychž|kótarychž}} coš '$1' pśez '$2' wuměniś:",
+ "replacetext_choosepagesformove": "\"$1\" pśez \"$2\" w titelu {{PLURAL:$3|slědujucego boka|slědujuceju bokowu|slědujucych bokow|slědujucych bokow}} wuměniś:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Slědujucy bok njedajo|Slědujucej boka njedajotej|Slědujuce boki njedaju|Slědujuce boki njedaju}} se pśesunuś:",
+ "replacetext_formovedpages": "Za pśesunjone boki:",
+ "replacetext_savemovedpages": "Stare titele ako dalejpósrědnjenja do nowych titelow składowaś",
+ "replacetext_watchmovedpages": "Toś te boki wobglědowaś",
+ "replacetext_invertselections": "Wuběrk pśewobrośiś",
+ "replacetext_replace": "Wuměniś",
+ "replacetext_success": "'$1' wuměnja se pśez '$2' na $3 {{PLURAL:$3|boku|bokoma|bokach|bokach}}.",
+ "replacetext_noreplacement": "Njejsu se namakali žedne boki, kótarež wopśimuju tekst '$1'.",
+ "replacetext_nomove": "Boki, kótarychž titel wopśimujo '$1', njejsu se namakali.",
+ "replacetext_nosuchcategory": "Kategorija z mjenim \"$1\" njeeksistěrujo.",
+ "replacetext_return": "Slědk k formularoju.",
+ "replacetext_warning": "'''Warnowanje:''' {{PLURAL:$1|Jo $1 bok, kótaryž južo wopśimujo|stej $1 boka, kótarejž južo wopśimujotej|su $1 boki, kótarež južo wopśimuju|jo $1 bokow, kótarež južo wopśimujo}} tekst, kótaryž ma se wuměniś, \"$2\".\nJolic wuwjedujoš toś tu wuměnu, njamóžoš rozeznaś swóje wuměny wót toś togo teksta.",
+ "replacetext_blankwarning": "Dokulaž njejo tekst za wuměnjenje, toś ta operacija njedajo se anulěrowaś. Coš weto pókšacowaś?",
+ "replacetext_continue": "Dalej",
+ "replacetext_editsummary": "Wuměna teksta - \"$1\" do \"$2\"",
+ "right-replacetext": "Tekst na cełem wikiju wuměniś",
+ "action-replacetext": "Tekst na cełem wikiju wuměniś"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/el.json b/www/wiki/extensions/ReplaceText/i18n/el.json
new file mode 100644
index 00000000..00d1ce1f
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/el.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Consta",
+ "Dada",
+ "Glavkos",
+ "Protnet",
+ "ZaDiak",
+ "Απεργός"
+ ]
+ },
+ "replacetext": "Αντικατάσταση κειμένου",
+ "replacetext-desc": "Παρέχει μια [[Special:ReplaceText|ειδική σελίδα]] που επιτρέπει σε διαχειριστές να κάνουν μια καθολική εύρεση και αντικατάσταση συμβολοσειράς σε όλες τις σελίδες περιεχομένου ενός wiki",
+ "replacetext_docu": "Για να αντικαταστήσετε μια συμβολοσειρά κειμένου με μια άλλη σε όλες τις κανονικές σελίδες αυτού του wiki, εισαγάγετε εδώ τα δύο κείμενα και μετά πατήστε «{{int:replacetext_continue}}».\nΘα εμφανιστεί τότε μια λίστα με σελίδες που περιέχουν το αναζητούμενο κείμενο και μπορείτε να επιλέξετε εκείνες στις οποίες θέλετε να το αντικαταστήσετε.\nΤο όνομά σας θα εμφανιστεί στο ιστορικό των σελίδων ως ο χρήστης που ευθύνεται για τις όποιες αλλαγές.",
+ "replacetext_originaltext": "Αρχικό κείμενο:",
+ "replacetext_replacementtext": "Κείμενο αντικατάστασης:",
+ "replacetext_useregex": "Χρήση κανονικών εκφράσεων",
+ "replacetext_regexdocu": "(Παράδειγμα: με τιμές «α(.*)γ» ως «{{int:replacetext_originaltext}}» και «αγ$1» ως «{{int:replacetext_replacementtext}}» θα αντικατασταθεί το «αβγ» με «αγβ»).",
+ "replacetext_optionalfilters": "Προαιρετικά φίλτρα:",
+ "replacetext_categorysearch": "Αντικατάσταση μόνο στην κατηγορία:",
+ "replacetext_prefixsearch": "Αντικατάσταση μόνο σε σελίδες με πρόθεμα:",
+ "replacetext_editpages": "Αντικατάσταση κειμένου στα περιεχόμενα σελίδας",
+ "replacetext_movepages": "Αντικατάσταση κειμένου σε τίτλους σελίδας, όταν είναι δυνατόν",
+ "replacetext_givetarget": "Πρέπει να καθορίσετε τη συμβολοσειρά προς αντικατάσταση.",
+ "replacetext_nonamespace": "Πρέπει να επιλέξετε τουλάχιστον έναν ονοματοχώρο.",
+ "replacetext_editormove": "Πρέπει να επιλέξετε τουλάχιστον μία από τις επιλογές αντικατάστασης.",
+ "replacetext_choosepagesforedit": "Αντικατάσταση «$1» με «$2» στο κείμενο {{PLURAL:$3|της ακόλουθης σελίδας|των ακόλουθων $3 σελίδων}}:",
+ "replacetext_choosepagesformove": "Αντικατάσταση «$1» με «$2» στον τίτλο {{PLURAL:$3|της ακόλουθης σελίδας|των ακόλουθων $3 σελίδων}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Η ακόλουθη σελίδα|Οι ακόλουθες $1 σελίδες}} δεν είναι δυνατό να μετακινηθούν:",
+ "replacetext_formovedpages": "Για τις σελίδες που θα μετακινηθούν:",
+ "replacetext_savemovedpages": "Αποθήκευση των παλιών τίτλων ως ανακατευθύνσεις προς τους νέους τίτλους",
+ "replacetext_watchmovedpages": "Παρακολούθηση αυτών των σελίδων",
+ "replacetext_invertselections": "Αναστροφή επιλογών",
+ "replacetext_replace": "Αντικατάσταση",
+ "replacetext_success": "Το «$1» θα αντικατασταθεί από το «$2» σε {{PLURAL:$3|μία σελίδα|$3 σελίδες}}.",
+ "replacetext_noreplacement": "Δε βρέθηκαν σελίδες που να περιέχουν τη συμβολοσειρά «$1».",
+ "replacetext_nomove": "Δε βρέθηκαν σελίδες των οποίων ο τίτλος να περιέχει «$1».",
+ "replacetext_nosuchcategory": "Δεν υπάρχει κατηγορία με όνομα «$1».",
+ "replacetext_return": "Επιστροφή στη φόρμα.",
+ "replacetext_warning": "'''Προειδοποίηση:''' {{PLURAL:$1|Υπάρχει μια σελίδα που περιέχει|Υπάρχουν $1 σελίδες που περιέχουν}} ήδη την προς αντικατάσταση συμβολοσειρά, «$2». Αν κάνετε αυτήν την αντικατάσταση δεν θα είστε μετά σε θέση να ξεχωρίσετε το κείμενο που αντικαταστήσατε από αυτό που ήδη υπήρχε.",
+ "replacetext_blankwarning": "'''Προειδοποίηση:''' Επειδή η προς αντικατάσταση συμβολοσειρά είναι κενή, αυτή η εργασία δεν θα είναι αναστρέψιμη.",
+ "replacetext_continue": "Συνέχεια",
+ "replacetext_editsummary": "Αντικατάσταση κειμένου - «$1» σε «$2»",
+ "right-replacetext": "Να γίνουν αντικαταστάσεις συμβολοσειρών σε ολόκληρο το wiki",
+ "action-replacetext": "κάνετε αντικαταστάσεις συμβολοσειρών σε ολόκληρο το wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/en.json b/www/wiki/extensions/ReplaceText/i18n/en.json
new file mode 100644
index 00000000..deda578b
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/en.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Yaron Koren"
+ ]
+ },
+ "replacetext": "Replace text",
+ "replacetext-desc": "Provides a [[Special:ReplaceText|special page]] to allow administrators to do a global string find-and-replace on all the content pages of a wiki",
+ "replacetext_docu": "To replace one text string with another across all regular pages on this wiki, enter the two pieces of text here and then hit \"{{int:replacetext_continue}}\".\nYou will then be shown a list of pages that contain the search text, and you can choose the ones in which you want to replace it.\nYour name will appear in page histories as the user responsible for any changes.",
+ "replacetext_originaltext": "Original text:",
+ "replacetext_replacementtext": "Replacement text:",
+ "replacetext_useregex": "Use regular expressions",
+ "replacetext_regexdocu": "(Example: values of \"a(.*)c\" for \"{{int:replacetext_originaltext}}\" and \"ac$1\" for \"{{int:replacetext_replacementtext}}\" would replace \"abc\" with \"acb\".)",
+ "replacetext_optionalfilters": "Optional filters:",
+ "replacetext_categorysearch": "Replace only in category:",
+ "replacetext_prefixsearch": "Replace only in pages with the prefix:",
+ "replacetext_editpages": "Replace text in page contents",
+ "replacetext_movepages": "Replace text in page titles, when possible",
+ "replacetext_givetarget": "You must specify the string to be replaced.",
+ "replacetext_nonamespace": "You must select at least one namespace.",
+ "replacetext_editormove": "You must select at least one of the replacement options.",
+ "replacetext_choosepagesforedit": "Replace \"$1\" with \"$2\" in the text of the following {{PLURAL:$3|page|$3 pages}}:",
+ "replacetext_choosepagesformove": "Replace \"$1\" with \"$2\" in the {{PLURAL:$3|title of the following page|titles of the following $3 pages}}:",
+ "replacetext_cannotmove": "The following {{PLURAL:$1|page|$1 pages}} cannot be moved:",
+ "replacetext_formovedpages": "For moved pages:",
+ "replacetext_savemovedpages": "Save the old titles as redirects to the new titles",
+ "replacetext_watchmovedpages": "Watch these pages",
+ "replacetext_invertselections": "Invert selections",
+ "replacetext_replace": "Replace",
+ "replacetext_success": "\"$1\" will be replaced with \"$2\" in {{PLURAL:$3|one page|$3 pages}}.",
+ "replacetext_noreplacement": "No pages were found containing the string \"$1\".",
+ "replacetext_nomove": "No pages were found whose title contains \"$1\".",
+ "replacetext_nosuchcategory": "No category exists with the name \"$1\".",
+ "replacetext_return": "Return to form.",
+ "replacetext_warning": "'''Warning:''' There {{PLURAL:$1|is one page that already contains|are $1 pages that already contain}} the replacement string, \"$2\". If you make this replacement you will not be able to separate your replacements from these strings.",
+ "replacetext_blankwarning": "'''Warning:''' Because the replacement string is blank, this operation will not be reversible.",
+ "replacetext_continue": "Continue",
+ "replacetext_announce": "Announce these edits via $1 and watchlists",
+ "replacetext_editsummary": "Text replacement - \"$1\" to \"$2\"",
+ "right-replacetext": "Make string replacements on the entire wiki",
+ "action-replacetext": "make string replacements on the entire wiki",
+ "replacetext_reminder": "To also modify links to this page in other pages, go to $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/eo.json b/www/wiki/extensions/ReplaceText/i18n/eo.json
new file mode 100644
index 00000000..e2ecb1c7
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/eo.json
@@ -0,0 +1,23 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki",
+ "Yekrats"
+ ]
+ },
+ "replacetext": "Anstataŭigi tekston",
+ "replacetext_originaltext": "Originala teksto:",
+ "replacetext_replacementtext": "Anstataŭigita teksto:",
+ "replacetext_optionalfilters": "Nedevigaj filtriloj:",
+ "replacetext_categorysearch": "Anstataŭigi nur en kategorio:",
+ "replacetext_movepages": "Anstataŭigi tekston en paĝaj titoloj, kiam eble",
+ "replacetext_nonamespace": "Vi devas elekti almenaŭ unu nomspacon.",
+ "replacetext_watchmovedpages": "Atenti ĉi tiujn paĝojn",
+ "replacetext_invertselections": "Inversigi selektojn",
+ "replacetext_replace": "Anstataŭigi",
+ "replacetext_success": "\"$1\" estos anstataŭigita de \"$2\" en $3 {{PLURAL:$3|paĝo|paĝoj}}.",
+ "replacetext_noreplacement": "Neniuj paĝoj estis trovitaj enhavantaj la ĉenon '$1'.",
+ "replacetext_return": "Reiri al formularo.",
+ "replacetext_continue": "Reaktivigi",
+ "replacetext_editsummary": "Teksta anstataŭigo - '$1' al '$2'"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/es.json b/www/wiki/extensions/ReplaceText/i18n/es.json
new file mode 100644
index 00000000..a6ced236
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/es.json
@@ -0,0 +1,54 @@
+{
+ "@metadata": {
+ "authors": [
+ "Antur",
+ "Armando-Martin",
+ "Ciencia Al Poder",
+ "Crazymadlover",
+ "Dferg",
+ "Fitoschido",
+ "Imre",
+ "Locos epraix",
+ "MarcoAurelio",
+ "Pertile",
+ "Translationista",
+ "Macofe"
+ ]
+ },
+ "replacetext": "Reemplazar texto",
+ "replacetext-desc": "Provee a los administradores de una [[Special:ReplaceText|página especial]] para realizar una búsqueda y reemplazo global de una expresión en todas las páginas de una wiki.",
+ "replacetext_docu": "Para sustituir una cadena de texto con otra en todas las páginas de este wiki, escribe ambos textos aquí y haz clic en \"{{int:replacetext_continue}}\".\nA continuación verás un listado de páginas que contienen el texto de búsqueda, de los cuales podrás elegir aquellos en los que quieras cambiar el texto.\nTu nombre aparecerá como usuario responsable de los cambios en el historial de cada una de esas páginas.",
+ "replacetext_originaltext": "Texto original:",
+ "replacetext_replacementtext": "Texto de reemplazo:",
+ "replacetext_useregex": "Utilizar expresiones regulares",
+ "replacetext_regexdocu": "(Ejemplo: los valores \"a(.*)c\" para \"{{int:replacetext_originaltext}}\" y \"ac$1\" para \"{{int:replacetext_replacementtext}}\" cambiarán \"abc\" por \"acb\".)",
+ "replacetext_optionalfilters": "Filtros opcionales:",
+ "replacetext_categorysearch": "Reemplazar solo en la categoría:",
+ "replacetext_prefixsearch": "Reemplazar solo en las páginas con el prefijo:",
+ "replacetext_editpages": "Reemplazar texto en los contenidos de las páginas",
+ "replacetext_movepages": "Reemplazar texto en títulos de páginas, cuando sea posible",
+ "replacetext_givetarget": "Debes especificar la cadena de caracteres que reemplazar.",
+ "replacetext_nonamespace": "Debes seleccionar al menos un espacio de nombres.",
+ "replacetext_editormove": "Debes seleccionar al menos una de las opciones de reemplazo.",
+ "replacetext_choosepagesforedit": "Reemplazar «$1» por «$2» en {{PLURAL:$3|la página siguiente|las $3 páginas siguientes}}:",
+ "replacetext_choosepagesformove": "Reemplazar «$1» por «$2» en {{PLURAL:$3|el título de la página siguiente|los títulos de las $3 páginas siguientes}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|La siguiente página no puede|Las siguientes páginas no pueden}} trasladarse:",
+ "replacetext_formovedpages": "Para páginas trasladadas:",
+ "replacetext_savemovedpages": "Guardar los títulos antiguos como redirecciones a los títulos nuevos",
+ "replacetext_watchmovedpages": "Vigilar estas páginas",
+ "replacetext_invertselections": "Invertir selecciones",
+ "replacetext_replace": "Reemplazar",
+ "replacetext_success": "«$1» se reemplazará por «$2» en {{PLURAL:$3|una página|$3 páginas}}.",
+ "replacetext_noreplacement": "No se hallaron páginas que contengan la cadena de caracteres «$1».",
+ "replacetext_nomove": "No se hallaron páginas cuyos títulos contengan «$1».",
+ "replacetext_nosuchcategory": "No existen categorías con el nombre «$1».",
+ "replacetext_return": "Retornar al formulario.",
+ "replacetext_warning": "'''Advertencia:''' hay {{PLURAL:$1|una página que ya contiene|$1 páginas que ya contienen}} la cadena de sustitución, \"$2\". Si realizas esta sustitución, no podrás separar tus sustituciones de estas cadenas.",
+ "replacetext_blankwarning": "'''Advertencia:''' como la cadena de reemplazo está vacía, esta operación no podrá revertirse.",
+ "replacetext_continue": "Continuar",
+ "replacetext_announce": "Anunciar estas ediciones mediante $1 y las listas de seguimiento",
+ "replacetext_editsummary": "Texto reemplazado: «$1» por «$2»",
+ "right-replacetext": "Reemplazar cadenas de texto en todo el wiki",
+ "action-replacetext": "reemplazar cadenas de texto en todo el wiki",
+ "replacetext_reminder": "Para modificar también los enlaces a esta página en otras páginas por favor ve a $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/et.json b/www/wiki/extensions/ReplaceText/i18n/et.json
new file mode 100644
index 00000000..c62591c4
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/et.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Avjoska",
+ "Pikne"
+ ]
+ },
+ "replacetext": "Teksti asendamine",
+ "replacetext_originaltext": "Originaaltekst:",
+ "replacetext_replacementtext": "Asendustekst:",
+ "replacetext_replace": "Asenda"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/eu.json b/www/wiki/extensions/ReplaceText/i18n/eu.json
new file mode 100644
index 00000000..e65df8df
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/eu.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "An13sa",
+ "Kobazulo",
+ "Xabier Armendaritz",
+ "Sator"
+ ]
+ },
+ "replacetext": "Testua ordeztu",
+ "replacetext_originaltext": "Jatorrizko testua:",
+ "replacetext_movepages": "Posiblea denean, orrialdeen izenburuetan ere testua ordezkatu",
+ "replacetext_cannotmove": "Ondorengo {{PLURAL:$1|orri hau ezin da mugitu:|orri hauek ezin dira mugitu:}}",
+ "replacetext_watchmovedpages": "Orrialde hauek jarraitu",
+ "replacetext_invertselections": "Hautaketak alderantzikatu",
+ "replacetext_replace": "Ordeztu",
+ "replacetext_noreplacement": "Ez da aurkitu '$1' karaktere-katea duen orrialderik.",
+ "replacetext_continue": "Jarraitu",
+ "replacetext_editsummary": "Testu ordezkapena - '$1'(e)tik '$2'(e)ra."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/fa.json b/www/wiki/extensions/ReplaceText/i18n/fa.json
new file mode 100644
index 00000000..ff394191
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/fa.json
@@ -0,0 +1,47 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armin1392",
+ "Ebraminio",
+ "Huji",
+ "Omidh",
+ "Reza1615",
+ "Wayiran",
+ "Alirezaaa"
+ ]
+ },
+ "replacetext": "جایگزینی متن",
+ "replacetext-desc": "یک [[Special:ReplaceText|صفحهٔ ویژه]] اضافه می‌کند که به مدیران اجازه می‌دهد یک جستجو و جایگزینی سراسری در تمام محتوای ویکی انجام دهند",
+ "replacetext_docu": "برای جایگزین کردن یک رشتهٔ متنی با رشته دیگر در کل داده‌های این ویکی، شما می‌توانید دو قسمت از متن را در زیر وارد کرده و دکمهٔ «ادامه» را بزنید. \nبه شما فهرستی از صفحاتی که دارای متن موردنظر هستند نشان داده می‌شود، و شما می‌توانید انتخاب کنید که می‌خواهید کدام صفحات جایگزین شوند.\nاسم شما در تاریخچهٔ صفحات به عنوان کاربری که مسئول این تغییرها است ثبت می‌شود.",
+ "replacetext_originaltext": "متن اصلی:",
+ "replacetext_replacementtext": "متن جایگزین:",
+ "replacetext_useregex": "استفاده از عبارت باقاعده",
+ "replacetext_regexdocu": "(مثال: مقادیر «a(.*)c» برای «{{int:replacetext_originaltext}}» و «ac$1» برای «{{int:replacetext_replacementtext}}»، «abc» را با «acb» جایگزین خواهد کرد.)",
+ "replacetext_optionalfilters": "پالایه‌های اختیاری:",
+ "replacetext_categorysearch": "جایگزینی فقط در ردهٔ:",
+ "replacetext_prefixsearch": "جایگزینی فقط در صفحه‌هایی با پیشوند:",
+ "replacetext_editpages": "جایگزینی متن در محتویات صفحه",
+ "replacetext_movepages": "جایگزینی متن و در عنوان صفحه‌ها، وقتی که امکان‌پذیر است",
+ "replacetext_givetarget": "شما می‌بایست متنی را که باید جایگزین شود مشخص نمایید.",
+ "replacetext_nonamespace": "شما می‌بایست حداقل یک فضای نام را انتخاب کنید.",
+ "replacetext_editormove": "شما می‌بایست حداقل یکی از گزینه‌های جایگزین کردن را انتخاب کنید.",
+ "replacetext_choosepagesforedit": "جایگزینی «$1» با «$2» در متن این {{PLURAL:$3|صفحه|صفحه‌ها}}:",
+ "replacetext_choosepagesformove": "جایگزینی «$1» با «$2» در {{PLURAL:$3|عنوان این صفحه|عنوان این صفحات}}",
+ "replacetext_cannotmove": "این {{PLURAL:$1|صفحه|صفحه‌ها}} نمی‌توانند منتقل شوند:",
+ "replacetext_formovedpages": "برای صفحه‌های منتقل‌شده:",
+ "replacetext_savemovedpages": "ذخیره‌سازی عنوان‌های قدیم به عنوان تغییر مسیرهایی به عنوان‌های تازه",
+ "replacetext_watchmovedpages": "‌پی‌گیری این صفحات",
+ "replacetext_invertselections": "وارانه کردن انتخاب‌ها",
+ "replacetext_replace": "جایگزین کن",
+ "replacetext_success": "در $3 {{PLURAL:$3|صفحه|صفحه}} «$1» با «$2» جایگزین می‌شود.",
+ "replacetext_noreplacement": "جایگزینی انجام نشد؛ صفحه‌ای که حاوی '$1' باشد پیدا نشد.",
+ "replacetext_nomove": "صفحه‌ای پیدا نشد که عنوان آن «$1» را داشته باشد.",
+ "replacetext_nosuchcategory": "رده‌ای با نام «$1» وجود ندارد.",
+ "replacetext_return": "بازگشت به فرم.",
+ "replacetext_warning": "'''هشدار:''' در حال حاضر $1 صفحه وجود دارد که حاوی رشتهٔ جایگزینی «$2» {{PLURAL:$1|است|هستند}}. اگر شما این جایگزینی را انجام دهید، قادر نخواهید بود تا جایگزینی‌هایتان را از این رشته‌ها جدا کنید.",
+ "replacetext_blankwarning": "چون متن جایگزین خالی است، این عمل قابل بازگشت نخواهد بود؛ ادامه می‌دهید؟",
+ "replacetext_continue": "ادامه",
+ "replacetext_editsummary": "جایگزینی متن - '$1' به '$2'",
+ "right-replacetext": "انجام جایگزین کردن رشته در تمام ویکی",
+ "action-replacetext": "ساختن جایگزین کردن رشته در تمام ویکی"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/fi.json b/www/wiki/extensions/ReplaceText/i18n/fi.json
new file mode 100644
index 00000000..26e9af91
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/fi.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cimon Avaro",
+ "Crt",
+ "Nike",
+ "Silvonen",
+ "Str4nd",
+ "Usp"
+ ]
+ },
+ "replacetext": "Korvaa teksti",
+ "replacetext-desc": "Lisää [[Special:ReplaceText|toimintosivun]], jonka kautta ylläpitäjät voivat etsiä ja korvata wikin sisältämää tekstiä",
+ "replacetext_docu": "Korvataksesi yhden merkkijonon toisella kaikissa tämän wikin tavallisissa sivuissa, syötä molemmat kaksi tekstinpätkää tänne ja sitten napsauta kohtaa 'Jatka'. Tämän jälkeen sinulle näytetään luettelo sivuista, jotka sisältävät haetun tekstin, ja voit valita ne, joihin haluat korvata sen. Oma nimesi näkyy sivun historiassa käyttäjänä joka on vastuussa kaikista tehdyistä muutoksista.",
+ "replacetext_originaltext": "Alkuperäinen teksti",
+ "replacetext_replacementtext": "Korvaava teksti",
+ "replacetext_useregex": "Käytä säännöllisiä lausekkeita",
+ "replacetext_optionalfilters": "Lisäehtoja:",
+ "replacetext_categorysearch": "Muokkaa ainoastaan sivuja, jotka ovat luokassa:",
+ "replacetext_prefixsearch": "Korvaa ainoastaan sivuilla, joissa on etuliite:",
+ "replacetext_editpages": "Korvaa teksti sivujen sisällöstä",
+ "replacetext_movepages": "Korvaa teksti otsikoista, jos mahdollista",
+ "replacetext_givetarget": "Sinun tulee määrittää korvattava merkkijono.",
+ "replacetext_nonamespace": "Sinun täytyy valita vähintään yksi nimiavaruus.",
+ "replacetext_editormove": "Sinun on valittava vähintään yksi kohde, mistä etsitään.",
+ "replacetext_choosepagesforedit": "Korvaa teksti \"$1\" tekstillä \"$2\" {{PLURAL:$3|seuraavalta sivulta|seuraavilta sivuilta}}:",
+ "replacetext_choosepagesformove": "Korvaa teksti \"$1\" tekstillä \"$2\" {{PLURAL:$3|seuraavan sivun otsikossa|seuraavien sivujen otsikoissa}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Seuraavaa sivua|Seuraavia sivuja}} ei voi siirtää:",
+ "replacetext_formovedpages": "Tee siirretyille sivuille:",
+ "replacetext_savemovedpages": "Tallenna vanhat sivujen otsikot ohjauksina uusiin sivuihin.",
+ "replacetext_watchmovedpages": "Tarkkaile näitä sivuja",
+ "replacetext_invertselections": "Käänteinen valinta",
+ "replacetext_replace": "Korvaa",
+ "replacetext_success": "\"$1\" korvataan tekstillä \"$2\" $3 {{PLURAL:$3|sivulla|sivulla}}.",
+ "replacetext_noreplacement": "Tekstin \"$1\" leipätekstissään sisältäviä sivuja ei löytynyt.",
+ "replacetext_nomove": "No pages were found whose title contains \"$1\".",
+ "replacetext_nosuchcategory": "Luokkaa \"$1\" ei ole.",
+ "replacetext_return": "Palaa lomakkeeseen.",
+ "replacetext_warning": "'''Varoitus:''' {{PLURAL:$1|$1 sivu| $1 sivua}} sisältää jo korvaavan tekstin, ”$2”.\nKorvauksen jälkeen korvatut ja jo tekstin sisältäneet kohdat eivät erotu toisistaan.",
+ "replacetext_blankwarning": "'''Varoitus:''' Koska korvaava teksti on tyhjä, operaatiota ei voi palauttaa käänteisellä korvauksella.",
+ "replacetext_continue": "Jatka",
+ "replacetext_editsummary": "Tekstin korvaus – ”$1” muotoon ”$2”",
+ "right-replacetext": "Tehdä merkkijonojen korvauksia koko wikin laajuudella"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/fr.json b/www/wiki/extensions/ReplaceText/i18n/fr.json
new file mode 100644
index 00000000..c915c8db
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/fr.json
@@ -0,0 +1,53 @@
+{
+ "@metadata": {
+ "authors": [
+ "Crochet.david",
+ "Gomoko",
+ "Grondin",
+ "IAlex",
+ "McDutchie",
+ "Nicolas NALLET",
+ "Peter17",
+ "PieRRoMaN",
+ "Urhixidur",
+ "Verdy p",
+ "Zetud"
+ ]
+ },
+ "replacetext": "Remplacer le texte",
+ "replacetext-desc": "Fournit une page spéciale permettant aux administrateurs de remplacer des chaînes de caractères par d’autres sur l’ensemble du wiki",
+ "replacetext_docu": "Pour remplacer une chaîne de caractères par une autre sur l’ensemble des données des pages de ce wiki, vous pouvez entrez les deux textes ici et cliquer sur « {{int:replacetext_replace}} ».\nUne liste des pages contenant le texte recherché apparaîtra et vous pourrez choisir celles que vous voulez modifier.\nVotre nom apparaîtra dans l’historique des pages tel un utilisateur auteur des changements.",
+ "replacetext_originaltext": "Texte original :",
+ "replacetext_replacementtext": "Texte de remplacement :",
+ "replacetext_useregex": "Utiliser des expressions rationnelles",
+ "replacetext_regexdocu": "(Exemple : la valeur « a(.*)c » pour « {{int:replacetext_originaltext}} » et « ac$1 » pour « {{int:replacetext_replacementtext}} » remplace « abc » avec « acb ».)",
+ "replacetext_optionalfilters": "Filtres optionnels :",
+ "replacetext_categorysearch": "Remplacer seulement dans la catégorie :",
+ "replacetext_prefixsearch": "Remplacer seulement dans les pages ayant le préfixe :",
+ "replacetext_editpages": "Remplacer le texte dans le contenu dans la page",
+ "replacetext_movepages": "Remplacer le texte dans le titre des pages, si possible",
+ "replacetext_givetarget": "Vous devez spécifier la chaîne à remplacer.",
+ "replacetext_nonamespace": "Vous devez sélectionner au moins un espace de noms.",
+ "replacetext_editormove": "Vous devez choisir au moins une option de remplacement.",
+ "replacetext_choosepagesforedit": "Veuillez sélectionner {{PLURAL:$3|la pages|les pages}} dans {{PLURAL:$3|laquelle|lesquelles}} vous voulez remplacer « $1 » par « $2 » :",
+ "replacetext_choosepagesformove": "Remplacer « $1 » par « $2 » dans {{PLURAL:$3|le nom de la page suivante|les noms des pages suivantes}} :",
+ "replacetext_cannotmove": "{{PLURAL:$1|La page suivante n’a pas pu être renommée|Les pages suivantes n’ont pas pu être renommées}} :",
+ "replacetext_formovedpages": "Pour les pages renommées :",
+ "replacetext_savemovedpages": "Enregistrer les anciens titres comme redirections vers les nouveaux titres",
+ "replacetext_watchmovedpages": "Suivre ces pages",
+ "replacetext_invertselections": "Inverser les sélections",
+ "replacetext_replace": "Remplacer",
+ "replacetext_success": "« $1 » sera remplacé par « $2 » dans $3 fichier{{PLURAL:$3||s}}.",
+ "replacetext_noreplacement": "Aucun fichier contenant la chaîne « $1 » n’a été trouvé.",
+ "replacetext_nomove": "Aucune page n’a été trouvée dont le titre contient « $1 ».",
+ "replacetext_nosuchcategory": "Il n’existe pas de catégorie nommée « $1 ».",
+ "replacetext_return": "Revenir au formulaire.",
+ "replacetext_warning": "Il y a $1 fichier {{PLURAL:$1| qui contient|s qui contiennent}} déjà la chaîne de remplacement « $2 ».\nSi vous effectuez cette substitution, vous ne pourrez pas distinguer vos modifications de ces chaînes.",
+ "replacetext_blankwarning": "Parce que la chaîne de remplacement est vide, cette opération sera irréversible ; voulez-vous continuer ?",
+ "replacetext_continue": "Continuer",
+ "replacetext_announce": "Annoncer ces modifications via $1 et les listes de suivi",
+ "replacetext_editsummary": "Remplacement de texte — « $1 » par « $2 »",
+ "right-replacetext": "Faire des remplacements de texte dans tout le wiki",
+ "action-replacetext": "faire les remplacements de la chaîne dans tout le wiki",
+ "replacetext_reminder": "Pour modifier aussi les liens vers cette page dans d’autres pages, allez en $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/frp.json b/www/wiki/extensions/ReplaceText/i18n/frp.json
new file mode 100644
index 00000000..9d154e07
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/frp.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "ChrisPtDe"
+ ]
+ },
+ "replacetext": "Remplaciér lo tèxto",
+ "replacetext_originaltext": "Tèxto d’origina :",
+ "replacetext_replacementtext": "Tèxto de remplacement :",
+ "replacetext_useregex": "Utilisar des èxprèssions racionèles",
+ "replacetext_optionalfilters": "Filtros u chouèx :",
+ "replacetext_categorysearch": "Remplaciér solament dedens la catègorie :",
+ "replacetext_prefixsearch": "Remplaciér solament dedens les pâges qu’ont lo prèfixo :",
+ "replacetext_editpages": "Remplaciér lo tèxto dedens lo contegnu de la pâge",
+ "replacetext_movepages": "Remplaciér lo tèxto dedens lo titre de les pâges, se possiblo",
+ "replacetext_givetarget": "Vos dête spècifiar la chêna a remplaciér.",
+ "replacetext_nonamespace": "Vos dête chouèsir u muens yon èspâço de noms.",
+ "replacetext_editormove": "Vos dête chouèsir u muens yon chouèx de remplacement.",
+ "replacetext_formovedpages": "Por les pâges renomâs :",
+ "replacetext_watchmovedpages": "Siuvre cetes pâges",
+ "replacetext_invertselections": "Envèrsar los chouèx",
+ "replacetext_replace": "Remplaciér",
+ "replacetext_return": "Tornar u formulèro.",
+ "replacetext_continue": "Continuar",
+ "replacetext_editsummary": "Remplacement du tèxto — « $1 » per « $2 »"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/gl.json b/www/wiki/extensions/ReplaceText/i18n/gl.json
new file mode 100644
index 00000000..f7644750
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/gl.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hamilton Abreu",
+ "Toliño"
+ ]
+ },
+ "replacetext": "Substituír un texto",
+ "replacetext-desc": "Proporciona unha [[Special:ReplaceText|páxina especial]] para que os administradores poidan facer unha cadea global para atopar e substituír un texto no contido de todas as páxinas dun wiki",
+ "replacetext_docu": "Para substituír unha cadea de texto por outra en todas as páxinas regulares deste wiki, insira aquí as dúas pezas de texto e logo prema en \"{{int:replacetext_continue}}\".\nDespois mostraráselle unha lista das páxinas que conteñen o texto buscado e poderá elixir en cales quere substituílo.\nO seu nome aparecerá nos histotiais das páxinas como o usuario responsable de calquera cambio.",
+ "replacetext_originaltext": "Texto orixinal:",
+ "replacetext_replacementtext": "Texto de substitución:",
+ "replacetext_useregex": "Usar expresións regulares",
+ "replacetext_regexdocu": "(Exemplo: Os valores \"a(.*)c\" en \"{{int:replacetext_originaltext}}\" e \"ac$1\" en \"{{int:replacetext_replacementtext}}\" han substituír \"abc\" por \"acb\".)",
+ "replacetext_optionalfilters": "Filtros opcionais:",
+ "replacetext_categorysearch": "Substituír só na categoría:",
+ "replacetext_prefixsearch": "Substituír só nas páxinas co prefixo:",
+ "replacetext_editpages": "Substituír o texto nos contidos da páxina",
+ "replacetext_movepages": "Substituír o texto nos títulos das páxinas, cando sexa posible",
+ "replacetext_givetarget": "Debe especificar a cadea que vai ser substituída.",
+ "replacetext_nonamespace": "Debe escoller, polo menos, un espazo de nomes.",
+ "replacetext_editormove": "Debe seleccionar, polo menos, unha das opcións de substitución.",
+ "replacetext_choosepagesforedit": "Substituír \"$1\" por \"$2\" no texto {{PLURAL:$3|da seguinte páxina|das seguintes páxinas}}:",
+ "replacetext_choosepagesformove": "Substituír \"$1\" por \"$2\" {{PLURAL:$3|no título da seguinte páxina|nos títulos das seguintes páxinas}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|A seguinte páxina|As seguintes páxinas}} non {{PLURAL:$1|pode|poden}} ser {{PLURAL:$1|movida|movidas}}:",
+ "replacetext_formovedpages": "Para as páxinas movidas:",
+ "replacetext_savemovedpages": "Gardar os títulos vellos como redireccións cara aos títulos novos",
+ "replacetext_watchmovedpages": "Vixíe estas páxinas",
+ "replacetext_invertselections": "Inverter as seleccións",
+ "replacetext_replace": "Substituír",
+ "replacetext_success": "\"$1\" será substituído por \"$2\" {{PLURAL:$3|nunha páxina|en $3 páxinas}}.",
+ "replacetext_noreplacement": "Non foi atopada ningunha páxina que contivese a cadea '$1'.",
+ "replacetext_nomove": "Non se atopou ningún artigo cuxo título conteña \"$1\".",
+ "replacetext_nosuchcategory": "Non existe ningunha categoría co nome \"$1\".",
+ "replacetext_return": "Volver ao formulario.",
+ "replacetext_warning": "'''Aviso:''' Hai {{PLURAL:$1|unha páxina|$1 páxinas}} que xa {{PLURAL:$1|contén|conteñen}} a cadea de substitución \"$2\". Se fai esta substitución non poderá distinguir as súas modificacións destas cadeas.",
+ "replacetext_blankwarning": "'''Atención:''' Debido a que a cadea de substitución está baleira, esta operación non será reversible.",
+ "replacetext_continue": "Continuar",
+ "replacetext_editsummary": "Substitución de texto: \"$1\" por \"$2\"",
+ "right-replacetext": "Facer substitucións de texto en todo o wiki",
+ "action-replacetext": "facer substitucións de texto en todo o wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/grc.json b/www/wiki/extensions/ReplaceText/i18n/grc.json
new file mode 100644
index 00000000..eebc8012
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/grc.json
@@ -0,0 +1,16 @@
+{
+ "@metadata": {
+ "authors": [
+ "Crazymadlover",
+ "Omnipaedista"
+ ]
+ },
+ "replacetext": "Ἀντικαθιστάναι κείμενον",
+ "replacetext_originaltext": "Πρωτότυπον κείμενον:",
+ "replacetext_replacementtext": "Κείμενον ἀντικαταστάσεως:",
+ "replacetext_formovedpages": "Περὶ μετακεκινημένων δέλτων:",
+ "replacetext_watchmovedpages": "Ἐφορᾶν τάσδε τὰς δέλτους",
+ "replacetext_replace": "Ἀντικαθιστάναι",
+ "replacetext_return": "Ἐπανιέναι εἰς τὸν τύπον.",
+ "replacetext_continue": "Συνεχίζειν"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/gsw.json b/www/wiki/extensions/ReplaceText/i18n/gsw.json
new file mode 100644
index 00000000..26a89e8d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/gsw.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Als-Holder"
+ ]
+ },
+ "replacetext": "Täxt ersetze",
+ "replacetext-desc": "Ergänzt e [[Special:ReplaceText|Spezialsyte]], wu s Ammanne megli macht, e wältwyti Täxt-suechen-un-ersetze-Operation in allene Inhaltsyte vum Wiki durzfiere",
+ "replacetext_docu": "Go ne Täxt dur e andere Täxt uf allene Inhaltssyte z ersetze, gib di bede Täxtteil doo yy un druck uf Ersetze-Schaltflächi. Dir wird derno ne Lischt vu dr Syte zeigt, wu s dr gsuecht Täxt din het, un Du chasch die uuswehle, wu Du dr Täxt witt din ersetze. Dyy Benutzername wird in d Versionsgschicht ufgnuh",
+ "replacetext_originaltext": "Originaltäxt:",
+ "replacetext_replacementtext": "Neje Täxt:",
+ "replacetext_useregex": "Platzhalter un reguläri Uusdruck verwände",
+ "replacetext_regexdocu": "(Byschpel: D Wärt fir „a(.*)c“ fir „Originaltext“ un „ac$1“ fir „Neje Text“ deete zue dr Ersetzig „abc“ dur „acb“ fiere.)",
+ "replacetext_optionalfilters": "Optionali Filter:",
+ "replacetext_categorysearch": "Nume in däre Kategorie ersetze:",
+ "replacetext_prefixsearch": "Nume in Syte ersetze mit däm Präfix:",
+ "replacetext_editpages": "Täxt im Syteinhalt ersetze",
+ "replacetext_movepages": "Ersetz Täxt au in Sytetitel, wänn s goht",
+ "replacetext_givetarget": "Du muesch d Zeichechette spezifiziere, wu soll ersetzt wäre.",
+ "replacetext_nonamespace": "Zmindescht ei Namensruum muess uusgwehlt wäre.",
+ "replacetext_editormove": "Du muesch zmindescht eini vu dr Ersetzigsoptione uuswehle.",
+ "replacetext_choosepagesforedit": "Bitte d {{PLURAL:$3|Syten|Syten}} uuswehle, wu Du „$1“ dur „$2“ wetsch ersetzen:",
+ "replacetext_choosepagesformove": "Ersetz „$1“ dur „$2“ {{PLURAL:$3|im Name vu däre Syte|in dr Näme vu däne Syte}}:",
+ "replacetext_cannotmove": "Die {{PLURAL:$1|Syte cha|Syte chenne}} nit verschobe wäre:",
+ "replacetext_formovedpages": "Fir verschobeni Syte:",
+ "replacetext_savemovedpages": "Di alte Sytenäme as Wyterleitig zue dr neje Sytenäme spychere",
+ "replacetext_watchmovedpages": "Die Syte beobachte",
+ "replacetext_invertselections": "Uuswahl umchehre",
+ "replacetext_replace": "Ersetze",
+ "replacetext_success": "„$1“ wird dur „$2“ in $3 {{PLURAL:$3|Syten|Syten}} ersetzt.",
+ "replacetext_noreplacement": "S isch kei Syte gfunde wore, wu s dr Täxt „$1“ din het.",
+ "replacetext_nomove": "S sin kei Syte gfunde wore, wu '$1' im Titel hän",
+ "replacetext_nosuchcategory": "S git kei Kategorii mit em Name „$1“.",
+ "replacetext_return": "Zrugg zum Formular.",
+ "replacetext_warning": "'''Warnig:''' In $1 {{PLURAL:$1|Syte het s|Seite het s}} dr Täxtteil „$2“, wu ersetzt soll wäre, scho.\nE Trännig vu dr Ersetzige mit dr Täxtteil, wu s scho het, sich nit megli. Mechtsch einewäg wytermache?",
+ "replacetext_blankwarning": "Dr Täxtteil, wu soll ersetzt wären, isch läär. D Operation cha nit ruckgängig gmacht wäre, einewäg wytermache?",
+ "replacetext_continue": "Wytermache",
+ "replacetext_editsummary": "Täxtersetzig - „$1“ dur „$2“",
+ "right-replacetext": "Mach e Täxtersetzig fir s gsamt Wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/he.json b/www/wiki/extensions/ReplaceText/i18n/he.json
new file mode 100644
index 00000000..7be6926d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/he.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Rotemliss",
+ "YaronSh",
+ "Guycn2"
+ ]
+ },
+ "replacetext": "החלפת טקסט",
+ "replacetext-desc": "אספקת [[Special:ReplaceText|דף מיוחד]] כדי לאפשר למפעילים לבצע חיפוש והחלפה של מחרוזות בכל דפי התוכן בוויקי",
+ "replacetext_docu": "כדי להחליף מחרוזת טקסט אחת באחרת בכל הדפים הרגילים בוויקי זה, הזינו את הטקסט בשני חלקים ולחצו על \"{{int:replacetext_continue}}\". אז תוצג בפניכם רשימת דפים המכילים את הטקסט שחיפשתם, ותוכלו לבחור את הדפים שבהם תרצו להחליף את הטקסט האמור. שמכם יופיע בהיסטוריית הגרסאות של כל דף בתור המשתמש האחראי לשינויים שנעשו.",
+ "replacetext_originaltext": "הטקסט המקורי:",
+ "replacetext_replacementtext": "טקסט ההחלפה:",
+ "replacetext_useregex": "להשתמש בביטויים רגולריים",
+ "replacetext_regexdocu": "(דוגמה: ערכים של \"a(.*)c\" עבור \"{{int:replacetext_originaltext}}\" ושל \"ac$1\" עבור \"{{int:replacetext_replacementtext}}\" יחליפו \"abc\" ב־\"acb\".)",
+ "replacetext_optionalfilters": "מסננים אופציונליים:",
+ "replacetext_categorysearch": "החלפה רק בקטגוריה:",
+ "replacetext_prefixsearch": "החלפה רק בדפים בעלי הקידומת:",
+ "replacetext_editpages": "החלפת טקסט בתוכן הדפים",
+ "replacetext_movepages": "החלפת טקסט בכותרות הדפים, כשניתן",
+ "replacetext_givetarget": "יש לציין את המחרוזת שתוחלף.",
+ "replacetext_nonamespace": "יש לבחור מרחב שם אחד לפחות.",
+ "replacetext_editormove": "יש לבחור לפחות באחת מאפשרויות ההחלפה.",
+ "replacetext_choosepagesforedit": "אנא בחרו את {{PLURAL:$3|הדף בו|הדפים בהם}} ברצונכם להחליף את '$1' ב־'$2':",
+ "replacetext_choosepagesformove": "החלפת \"$1\" ב־\"$2\" ב{{PLURAL:$3|שם הדף הבא|שמות הדפים הבאים}}:",
+ "replacetext_cannotmove": "לא ניתן להעביר את {{PLURAL:$1|הדף הבא|הדפים הבאים}}:",
+ "replacetext_formovedpages": "עבור דפים שיועברו:",
+ "replacetext_savemovedpages": "שמירת שמות הדפים הישנים כהפניות לשמות הדפים החדשים",
+ "replacetext_watchmovedpages": "מעקב אחר דפים אלה",
+ "replacetext_invertselections": "הפיכת הבחירות",
+ "replacetext_replace": "החלפה",
+ "replacetext_success": "'$1' יוחלף ב־'$2' ב־{{PLURAL:$3|דף אחד|$3 דפים}}.",
+ "replacetext_noreplacement": "לא נמצאו דפים המכילים את המחרוזת '$1'.",
+ "replacetext_nomove": "לא נמצאו דפים ששמם מכיל '$1'.",
+ "replacetext_nosuchcategory": "לא קיימת קטגוריה בשם \"$1\".",
+ "replacetext_return": "חזרה לטופס.",
+ "replacetext_warning": "'''אזהרה''': {{PLURAL:$1|ישנו עמוד אחד שכבר מכיל|ישנם $1 עמודים שכבר מכילים}} את מחרוזת ההחלפה, \"$2\". אם החלפה זו תבוצע לא תהיה באפשרותך להפריד את החלפותיך מ{{PLURAL:$1|מחרוזת זו|מחרוזות אלו}}.",
+ "replacetext_blankwarning": "כיוון שמחרוזת ההחלפה ריקה, לא ניתן יהיה לבטל פעולה זו; להמשיך?",
+ "replacetext_continue": "המשך",
+ "replacetext_editsummary": "החלפת טקסט – \"$1\" ב־\"$2\"",
+ "right-replacetext": "ביצוע החלפת מחרוזות באתר הוויקי כולו",
+ "action-replacetext": "לבצע החלפת מחרוזות באתר הוויקי כולו"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/hr.json b/www/wiki/extensions/ReplaceText/i18n/hr.json
new file mode 100644
index 00000000..072ca9c5
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/hr.json
@@ -0,0 +1,29 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bugoslav",
+ "Dalibor Bosits",
+ "Ex13",
+ "Herr Mlinka",
+ "MaGa"
+ ]
+ },
+ "replacetext": "Zamijeni tekst",
+ "replacetext-desc": "Dodaje [[Special:ReplaceText|posebnu stranicu]] koja omogućava administratorima globalnu zamjenu teksta na principu nađi-zamjeni na svim stranicama wikija.",
+ "replacetext_docu": "Za zamjenu jednog teksta s drugim na svim stranicama wikija, upišite ciljani i zamjenski tekst ovdje i pritisnite 'Dalje'. Pokazati će vam se popis stranica koje sadrže ciljani tekst, i moći ćete odabrati u kojima od njih želite izvršiti zamjenu. Vaše ime će se pojaviti u povijesti stranice kao suradnik odgovoran za promjenu.",
+ "replacetext_originaltext": "Izvorni tekst:",
+ "replacetext_replacementtext": "Zamjenski tekst:",
+ "replacetext_movepages": "Zamijeni tekst u naslovima stranica, ako je moguće",
+ "replacetext_choosepagesforedit": "Molimo odaberite {{PLURAL:$3|stranicu|stranice}} na kojima želite zamijeniti '$1' za '$2':",
+ "replacetext_choosepagesformove": "Zamijeni \"$1\" s \"$2\" u {{PLURAL:$1|naslovu sljedeće stranice|naslovima sljedećih stranica}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Sljedeća stranica|Sljedeće stranice}} ne mogu biti premještene:",
+ "replacetext_watchmovedpages": "Prati ove stranice",
+ "replacetext_invertselections": "Obrni odabir",
+ "replacetext_replace": "Zamijeni",
+ "replacetext_success": "'$1' će biti zamijenjen za '$2' na $3 {{PLURAL:$3|stranici|stranice|stranica}}.",
+ "replacetext_noreplacement": "Nije pronađena ni jedna stranica koja sadrži '$1'.",
+ "replacetext_warning": "Postoji {{PLURAL:$1|$1 stranica koja već sadrži|$1 stranica koje već sadrže}} zamjenski tekst, '$2'. \nAko napravite ovu zamjenu nećete moći odvojiti svoju zamjenu od ovog teksta. Nastaviti sa zamjenom?",
+ "replacetext_blankwarning": "Zato što je zamjenski tekst prazan, ovaj postupak se neće moći vratiti; nastaviti?",
+ "replacetext_continue": "Dalje",
+ "replacetext_editsummary": "Zamjena teksta - '$1' u '$2'"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/hsb.json b/www/wiki/extensions/ReplaceText/i18n/hsb.json
new file mode 100644
index 00000000..425d930f
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/hsb.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "replacetext": "Tekst narunać",
+ "replacetext-desc": "Staji [[Special:ReplaceText|specialnu stronu]] k dispoziciji, kotraž administratoram zmóžnja, globalne pytanje a narunanje teksta na wšěch wobsahowych stronach wikija přewjesć",
+ "replacetext_docu": "Zo by tekst přez druhi tekst na wšěch regularnych stronach tutoho wikija narunał, zapodaj wobaj tekstowej dźělej a klikń potom na \"{{int:replacetext_continue}}\". Budźeš potom lisćinu stronow widźeć, kotrež pytany tekst wobsahuja a móžeš te z nich wubrać, w kotrejž chceš tekst narunać. Twoje mjeno zjewi so w stawiznach strony jako wužiwar, kotryž je zamołwity za změny.",
+ "replacetext_originaltext": "Originalny tekst:",
+ "replacetext_replacementtext": "Narunanski tekst:",
+ "replacetext_useregex": "regularne wuraz wužiwać",
+ "replacetext_regexdocu": "(Přikład: hódnoty za \"a(.*)c\" za \"{{int:replacetext_originaltext}}\"a \"ac$1\" za \"{{int:replacetext_replacementtext}}\" bychu \"abc\" přez \"acb\" wuměnili.)",
+ "replacetext_optionalfilters": "Opcionalne filtry:",
+ "replacetext_categorysearch": "Jenož w kategoriji narunać:",
+ "replacetext_prefixsearch": "Jenož w stronach narunać z prefiksom:",
+ "replacetext_editpages": "Tekst we wobsahu strony narunać",
+ "replacetext_movepages": "Tekst w titulach stronow narunać, jeli móžno",
+ "replacetext_givetarget": "Dyrbiš tekst podać, kotryž ma so narunać.",
+ "replacetext_nonamespace": "Dyrbiš znajmjeńša jedyn mjenowy rum wubrać.",
+ "replacetext_editormove": "Dyrbiš znajmjeńša jednu z narunanskich opcijow wubrać.",
+ "replacetext_choosepagesforedit": "\"$1\" w {{PLURAL:$3|slědowacej stronje|slědowacymaj stronomaj|slědowacych stronach|slědowacych stronach}} přez \"$2\" wuměnić:",
+ "replacetext_choosepagesformove": "\"$1\" přez \"$2\" w titulu {{PLURAL:$3|slědowaceje strony|slědowaceju stronow|slědowacych stronow|slědowacych stronow}} narunać:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Slědowaca strona njehodźi|Slědowacej stronje njehodźitej|Slědowace strony njehodźa|Slědowace strony njehodźa}} so přesunyć:",
+ "replacetext_formovedpages": "Za přesunjene strony:",
+ "replacetext_savemovedpages": "Stare titule jako daleposrědkowanja do nowych titulow składować",
+ "replacetext_watchmovedpages": "Tute strony wobkedźbować",
+ "replacetext_invertselections": "Wuběry wobroćić",
+ "replacetext_replace": "Narunać",
+ "replacetext_success": "'$1' so w $3 {{PLURAL:$3|stronje|stronomaj|stronach|stronach}} přez '$2' naruna.",
+ "replacetext_noreplacement": "Njejsu so žane strony namakali, kotrež wuraz '$1' wobsahuja.",
+ "replacetext_nomove": "Strony, kotrychž titul '$1' wobsahuje, njebuchu namakane.",
+ "replacetext_nosuchcategory": "Kategorija z mjenom \"$1\" njeeksistuje.",
+ "replacetext_return": "Wróćo k formularej",
+ "replacetext_warning": "'''Warnowanje:''' {{PLURAL:$1|Je hižo $1 strona, kotraž wobsahuje|Stej hižo $1 stronje, kotejž wobsahujetej|Su hižo $1 strony, kotrež wobsahuja|Je hižo $1 stronow, kotrež wobsahuje}} narunanski tekst, '$2'. Jeli tute narunanje činiš, njemóžeš swoje narunanja wot tutoho teksta rozdźělić.",
+ "replacetext_blankwarning": "Narunanski dźěl je prózdny, tohodla operacija njeda so cofnyć; njedźiwajo na to pokročować?",
+ "replacetext_continue": "Dale",
+ "replacetext_editsummary": "Tekstowe narunanje - \"$1\" do \"$2\"",
+ "right-replacetext": "Tekstowe narunanja na cyłym wikiju činić",
+ "action-replacetext": "Tekstowe narunanja na cyłym wikiju činić"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/hu.json b/www/wiki/extensions/ReplaceText/i18n/hu.json
new file mode 100644
index 00000000..6cab29d4
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/hu.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Glanthor Reviol",
+ "Tacsipacsi"
+ ]
+ },
+ "replacetext": "Szöveg cseréje",
+ "replacetext-desc": "[[Special:ReplaceText|Speciális lap]] adminisztrátorok részére szövegek globális keresés-és-cseréjére a wiki összes tartalom oldalán",
+ "replacetext_docu": "Hogy lecserélj egy szöveget egy másikra az összes rendes lapon a wikin, add meg a keresendő és a cél szöveget, majd kattints a „{{int:replacetext_continue}}” gombra.\nEzután kapsz egy listát azokról a lapokról, amelyek tartalmazzák a cserélendő szöveget, és kiválaszthatod azokat, amelyekben végre szeretnéd hajtani a cserét.\nA neved szerepelni fog a laptörténetekben a változtatásokért felelős felhasználóként.",
+ "replacetext_originaltext": "Eredeti szöveg:",
+ "replacetext_replacementtext": "Új szöveg:",
+ "replacetext_useregex": "Reguláris kifejezések használata",
+ "replacetext_regexdocu": "(Például: ha az „{{int:replacetext_originaltext}}” mezőbe „a(.*)c”-t írsz, az „{{int:replacetext_replacementtext}}” mezőbe pedig „ac$1”-t, az „abc” szöveget „acb”-re cseréli.)",
+ "replacetext_optionalfilters": "Választható szűrők:",
+ "replacetext_categorysearch": "Csere csak ebben a kategóriában:",
+ "replacetext_prefixsearch": "Csere csak a következő előtaggal rendelkező lapokon:",
+ "replacetext_editpages": "Szöveg cseréje a lap tartalmában",
+ "replacetext_movepages": "Szöveg cseréje a lapok címeiben, ha lehetséges",
+ "replacetext_givetarget": "Meg kell adnod a cserélendő szöveget.",
+ "replacetext_nonamespace": "Ki kell választanod legalább egy névteret.",
+ "replacetext_editormove": "Ki kell választanod legalább egyet a csere lehetőségek közül.",
+ "replacetext_choosepagesforedit": "„$1” cseréje „$2” kifejezésre a következő {{PLURAL:$3|lap|lapok}} szövegében:",
+ "replacetext_choosepagesformove": "„$1” cseréje „$2” kifejezésre a következő {{PLURAL:$3|lap címében|lapok címeiben}}:",
+ "replacetext_cannotmove": "A következő {{PLURAL:$1|lap|lapok}} nem nevezhetőek át:",
+ "replacetext_formovedpages": "Az átnevezett lapokhoz:",
+ "replacetext_savemovedpages": "A régi címek megtartása átirányításként az új címekre",
+ "replacetext_watchmovedpages": "Figyeld ezeket a lapokat",
+ "replacetext_invertselections": "Kijelölések megfordítása",
+ "replacetext_replace": "Csere",
+ "replacetext_success": "„$1” cseréje $3 lapon erre: „$2”.",
+ "replacetext_noreplacement": "Egy lap sem tartalmazza a(z) „$1” szöveget.",
+ "replacetext_nomove": "Nem található olyan lap, melynek címe tartalmazza a(z) „$1” keresőkifejezést.",
+ "replacetext_nosuchcategory": "Nincs „$1” nevű kategória.",
+ "replacetext_return": "Visszatérés az űrlapra.",
+ "replacetext_warning": "'''Figyelem:''' {{PLURAL:$1|egy|$1}} lap már tartalmazza a szöveget, amire cserélni szeretnél („$2”). Ha végrehajtod a cserét, utólag nem fogod tudni megkülönböztetni az újonnan bekerült szövegeket a már előtte is meglevő előfordulásoktól.",
+ "replacetext_blankwarning": "Mivel az új szöveg üres, ez a művelet nem lesz visszavonható.\nBiztosan folytatni szeretnéd?",
+ "replacetext_continue": "Folytatás",
+ "replacetext_editsummary": "Szövegcsere – „$1” → „$2”",
+ "right-replacetext": "szövegcserék végrehajtása az egész wikin",
+ "action-replacetext": "szövegcsere az egész wikiben"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ia.json b/www/wiki/extensions/ReplaceText/i18n/ia.json
new file mode 100644
index 00000000..cadcf128
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ia.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "McDutchie"
+ ]
+ },
+ "replacetext": "Reimplaciar texto",
+ "replacetext-desc": "Forni un [[Special:ReplaceText|pagina special]] que permitte al administratores cercar e reimplaciar globalmente un catena de characteres in tote le paginas de contento de un wiki",
+ "replacetext_docu": "Pro reimplaciar un catena de characteres per un altere in tote le paginas regular in iste wiki, entra le duo pecias de texto hic e clicca super \"{{int:replacetext_continue}}\".\nPostea apparera un lista de paginas que contine le texto cercate, e tu potera seliger le paginas in le quales tu vole reimplaciar lo.\nTu nomine figurara in le historias del paginas como le usator responsabile de eventual modificationes.",
+ "replacetext_originaltext": "Texto original:",
+ "replacetext_replacementtext": "Texto de substitution:",
+ "replacetext_useregex": "Usar expressiones regular",
+ "replacetext_regexdocu": "(Exemplo: valores de \"a(.*)c\" pro \"{{int:replacetext_originaltext}}\" e \"ac$1\" pro \"{{int:replacetext_replacementtext}}\" reimplaciarea \"abc\" per \"acb\".)",
+ "replacetext_optionalfilters": "Filtros optional:",
+ "replacetext_categorysearch": "Reimplaciar solmente in le categoria:",
+ "replacetext_prefixsearch": "Reimplaciar solmente in paginas con le prefixo:",
+ "replacetext_editpages": "Reimplaciar texto in contento de pagina",
+ "replacetext_movepages": "Reimplaciar texto in titulos de paginas, quando possibile",
+ "replacetext_givetarget": "Tu debe specificar le texto a esser reimplaciate.",
+ "replacetext_nonamespace": "Tu debe seliger al minus un spatio de nomines.",
+ "replacetext_editormove": "Tu debe seliger al minus un del optiones de reimplaciamento.",
+ "replacetext_choosepagesforedit": "Per favor selige le {{PLURAL:$3|pagina in le qual|paginas in le quales}} tu vole reimplaciar '$1' per '$2':",
+ "replacetext_choosepagesformove": "Reimplaciar \"$1\" per \"$2\" in le {{PLURAL:$3|titulo del sequente pagina|titulos del sequente paginas}}:",
+ "replacetext_cannotmove": "Le sequente {{PLURAL:$1|pagina|paginas}} non pote esser renominate:",
+ "replacetext_formovedpages": "Pro pagina renominate:",
+ "replacetext_savemovedpages": "Preservar le ancian titulos como redirectiones verso le nove titulos",
+ "replacetext_watchmovedpages": "Observar iste paginas",
+ "replacetext_invertselections": "Inverter selectiones",
+ "replacetext_replace": "Reimplaciar",
+ "replacetext_success": "'$1' essera reimplaciate per '$2' in $3 {{PLURAL:$3|pagina|paginas}}.",
+ "replacetext_noreplacement": "Nulle pagina esseva trovate que contine le catena de characteres '$1'.",
+ "replacetext_nomove": "Nulle pagina esseva trovate con un titulo que contine '$1'.",
+ "replacetext_nosuchcategory": "Nulle categoria existe con le nomine '$1'.",
+ "replacetext_return": "Retornar al formulario.",
+ "replacetext_warning": "'''Attention:''' Il ha $1 {{PLURAL:$1|pagina|paginas}} que contine ja le nove texto, \"$2\".\nSi tu face iste reimplaciamento, tu non potera distinguer inter tu reimplaciamentos e iste texto ja existente.",
+ "replacetext_blankwarning": "Post que le nove texto es vacue, iste operation non essera reversibile; continuar?",
+ "replacetext_continue": "Continuar",
+ "replacetext_editsummary": "Substitution de texto – \"$1\" per \"$2\"",
+ "right-replacetext": "Reimplaciar catenas de texto in tote le wiki",
+ "action-replacetext": "reimplaciar catenas de texto in tote le wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/id.json b/www/wiki/extensions/ReplaceText/i18n/id.json
new file mode 100644
index 00000000..d3effe62
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/id.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bennylin",
+ "Farras",
+ "IvanLanin",
+ "Rex"
+ ]
+ },
+ "replacetext": "Mengganti teks",
+ "replacetext-desc": "Menyediakan [[Special:ReplaceText|halaman istimewa]] untuk memungkinkan pengurus untuk melakukan pencarian-dan-penggantian untaian secara global pada semua halaman isi dari suatu wiki",
+ "replacetext_docu": "Untuk mengganti suatu teks kalimat dengan kalimat lain di antara semua halaman-halaman regular wiki ini, masukkan kedua teks di sini dan klik 'Lanjutkan'. Anda akan mendapatkan tampilan daftar halaman yang berisikan teks yang dicari, dan Anda dapat memilih yang mana saja yang ingin digantikan. Nama Anda akan tampil di versi terdahulu halaman sebagai pengguna yang melakukan perubahan.",
+ "replacetext_originaltext": "Teks asli:",
+ "replacetext_replacementtext": "Teks pengganti:",
+ "replacetext_useregex": "Gunakan persamaan reguler",
+ "replacetext_regexdocu": "(Congoh: nilai dari \"a(.*)c\" untuk \"Teks asal\" dan \"ac$1\" untuk \"Teks pengganti\" akan mengganti \"abc\" dengan \"acb\".)",
+ "replacetext_optionalfilters": "Filter opsional:",
+ "replacetext_categorysearch": "Hanya ganti pada kategori:",
+ "replacetext_prefixsearch": "Hanya ganti pada halaman dengan awalan:",
+ "replacetext_editpages": "Ganti teks pada isi halaman",
+ "replacetext_movepages": "Ganti teks pada judul halaman, jika mungkin",
+ "replacetext_givetarget": "Anda harus menyebutkan untaian yang akan diganti.",
+ "replacetext_nonamespace": "Anda harus memilih paling tidak satu ruang nama.",
+ "replacetext_editormove": "Anda harus memilih paling tidak salah satu opsi penggantian.",
+ "replacetext_choosepagesforedit": "Ganti \"$1\" dengan \"$2\" pada teks dari {{PLURAL:$3|halaman|halaman}} berikut:",
+ "replacetext_choosepagesformove": "Ganti \"$1\" dengan \"$2\" pada {{PLURAL:$3|judul halaman berikut|judul halaman berikut}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Halaman|Halaman}} berikut tidak dapat dipindahkan:",
+ "replacetext_formovedpages": "Untuk halaman yang dipindahkan:",
+ "replacetext_savemovedpages": "Simpan judul lama sebagai pengalihan ke judul baru",
+ "replacetext_watchmovedpages": "Pantau halaman-halaman ini",
+ "replacetext_invertselections": "Balikkan pilihan",
+ "replacetext_replace": "Gantikan",
+ "replacetext_success": "\"$1\" akan diganti dengan \"$2\" pada $3 {{PLURAL:$3|halaman|halaman}}.",
+ "replacetext_noreplacement": "Tidak ada halaman yang ditemukan yang mengandung untaian \"$1\".",
+ "replacetext_nomove": "Tidak ada halaman yang ditemukan yang judulnya mengandung \"$1\".",
+ "replacetext_nosuchcategory": "Tidak ditemukan kategori bernama \"$1\".",
+ "replacetext_return": "Kembali ke isian.",
+ "replacetext_warning": "Ada {{PLURAL:$1|$1 halaman|$1 halaman}} yang telah berisi untaian pengganti, \"$2\". Jika Anda melakukan penggantian ini Anda tidak akan dapat memisahkan pengganti Anda dari untaian ini.",
+ "replacetext_blankwarning": "Karena untaian pengganti kosong, operasi ini tidak dapat dikembalikan.\nApakah ingin dilanjutkan?",
+ "replacetext_continue": "Lanjutkan",
+ "replacetext_editsummary": "Penggantian teks - \"$1\" menjadi \"$2\"",
+ "right-replacetext": "Melakukan penggantian seluruh teks kalimat di wiki ini"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ig.json b/www/wiki/extensions/ReplaceText/i18n/ig.json
new file mode 100644
index 00000000..7c1bab2d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ig.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ukabia"
+ ]
+ },
+ "replacetext_originaltext": "Mkpụrụ nke mbu:",
+ "replacetext_replace": "Kwụchí na élú"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/it.json b/www/wiki/extensions/ReplaceText/i18n/it.json
new file mode 100644
index 00000000..5bab2181
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/it.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beta16",
+ "Civvì",
+ "Darth Kule",
+ "Marco 27",
+ "Malore",
+ "Nemo bis"
+ ]
+ },
+ "replacetext": "Sostituzione testo",
+ "replacetext-desc": "Fornisce una [[Special:ReplaceText|pagina speciale]] per permettere agli amministratori di effettuare una ricerca e sostituzione globale di testo su tutte le pagine di contenuto di un sito",
+ "replacetext_docu": "Per sostituire una stringa di testo con un'altra su tutte le pagine del sito, inserire qui due pezzi di testo e poi premere \"{{int:replacetext_continue}}\". Verrà quindi mostrato un elenco delle pagine che contengono il testo cercato e sarà possibile scegliere quelle in cui si desidera sostituirlo. Il proprio nome verrà visualizzato nella pagina della cronologia come l'utente responsabile delle eventuali modifiche.",
+ "replacetext_originaltext": "Testo originale:",
+ "replacetext_replacementtext": "Testo sostituito:",
+ "replacetext_useregex": "Utilizza le espressioni regolari",
+ "replacetext_regexdocu": "(Esempio: con valori di \"a(.*)c\" per \"{{int:replacetext_originaltext}}\" e \"ac$1\" per \"{{int:replacetext_replacementtext}}\" trasformerebbe \"abc\" in \"acb\".)",
+ "replacetext_optionalfilters": "Filtri opzionali:",
+ "replacetext_categorysearch": "Sostituire solo nella categoria:",
+ "replacetext_prefixsearch": "Sostituire solo nelle pagine con il prefisso:",
+ "replacetext_editpages": "Sostituire il testo nel contenuto delle pagine",
+ "replacetext_movepages": "Sostituisci il testo nei titoli delle pagine, quando possibile",
+ "replacetext_givetarget": "È necessario specificare il testo da sostituire.",
+ "replacetext_nonamespace": "È necessario selezionare almeno un namespace",
+ "replacetext_editormove": "È necessario selezionare almeno una delle opzioni di sostituzione.",
+ "replacetext_choosepagesforedit": "Selezionare {{PLURAL:$3|la pagina per la quale|le pagine per le quali}} si desidera sostituire '$1' con '$2':",
+ "replacetext_choosepagesformove": "Sostituire \"$1\" con \"$2\" {{PLURAL:$3|nel titolo della pagina seguente|nei titoli delle pagine seguenti}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|La pagina seguente non può essere spostata|Le pagine seguenti non possono essere spostate}}:",
+ "replacetext_formovedpages": "Per le pagine spostate:",
+ "replacetext_savemovedpages": "Conservare i vecchi titoli come redirect al nuovo titolo:",
+ "replacetext_watchmovedpages": "Aggiungi agli osservati speciali",
+ "replacetext_invertselections": "Inverti selezione",
+ "replacetext_replace": "Sostituisci",
+ "replacetext_success": "'$1' sarà sostituito con '$2' in $3 {{PLURAL:$3|pagina|pagine}}.",
+ "replacetext_noreplacement": "Non sono state trovate pagine contenenti il testo '$1'.",
+ "replacetext_nomove": "Non sono state trovate pagine il cui titolo contiene '$1'.",
+ "replacetext_nosuchcategory": "Non esiste categoria con il nome \"$1\".",
+ "replacetext_return": "Torna al modulo.",
+ "replacetext_warning": "{{PLURAL:$1|C'è già $1 pagina che contiene|Ci sono già $1 pagine che contengono}} il testo di sostituzione, \"$2\". Se si effettua questa sostituzione non si sarà in grado di separare le sostituzioni da questi testi. Continuare con la sostituzione?",
+ "replacetext_blankwarning": "Poiché il testo di sostituzione è vuoto, l'operazione non sarà reversibile. Si desidera continuare?",
+ "replacetext_continue": "Continua",
+ "replacetext_editsummary": "Sostituzione testo - \"$1\" con \"$2\"",
+ "right-replacetext": "Esegue sostituzioni di testo in tutto il sito",
+ "action-replacetext": "eseguire sostituzioni di testo in tutto il sito"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ja.json b/www/wiki/extensions/ReplaceText/i18n/ja.json
new file mode 100644
index 00000000..293e1b6d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ja.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aotake",
+ "Fryed-peach",
+ "Schu",
+ "Shirayuki",
+ "青子守歌"
+ ]
+ },
+ "replacetext": "文字列の置換",
+ "replacetext-desc": "管理者がウィキ内の全記事で、ある文字列に一致する部分すべてを置換できるようにする[[Special:ReplaceText|特別ページ]]を提供する",
+ "replacetext_docu": "このウィキ上のすべての標準ページについて、ある文字列を別の文字列に置換するには、2 つの文字列をここに入力して「{{int:replacetext_continue}}」を押します。\n検索した文字列を含むページが列挙されますので、置換したいページを選択してください。\n置換すると、その編集を担当した利用者としてあなたの名前が、ページ履歴に表示されます。",
+ "replacetext_originaltext": "置換前の文字列:",
+ "replacetext_replacementtext": "置換後の文字列:",
+ "replacetext_useregex": "正規表現を使用",
+ "replacetext_regexdocu": "(例: 「{{int:replacetext_originaltext}}」の値が「a(.*)c」、「{{int:replacetext_replacementtext}}」の値が「ac$1」の場合、「abc」を「acb」に置換します。)",
+ "replacetext_optionalfilters": "追加のフィルター (任意):",
+ "replacetext_categorysearch": "以下のカテゴリにあるもののみを置換:",
+ "replacetext_prefixsearch": "以下の文字列から始まるページ内のもののみを置換:",
+ "replacetext_editpages": "ページ本文中の文字列を置換",
+ "replacetext_movepages": "可能ならば、ページ名中の文字列を置換する",
+ "replacetext_givetarget": "置換される対象となる文字列を指定する必要があります。",
+ "replacetext_nonamespace": "名前空間を少なくとも1つ選択する必要があります。",
+ "replacetext_editormove": "置換オプションから少なくとも1つ選択する必要があります。",
+ "replacetext_choosepagesforedit": "以下の{{PLURAL:$3|ページ}}の本文中の「$1」を「$2」に置換する:",
+ "replacetext_choosepagesformove": "以下の名前の{{PLURAL:$3|ページ}}中の文字列「$1」を「$2」に置換する:",
+ "replacetext_cannotmove": "以下の{{PLURAL:$1|ページ}}は移動できません:",
+ "replacetext_formovedpages": "移動したページについて:",
+ "replacetext_savemovedpages": "古いページ名を新しいページへのリダイレクトとして残す",
+ "replacetext_watchmovedpages": "これらのページをウォッチ",
+ "replacetext_invertselections": "選択を反転",
+ "replacetext_replace": "置換",
+ "replacetext_success": "$3{{PLURAL:$3|ページ}}で「$1」が「$2」に置換されます。",
+ "replacetext_noreplacement": "文字列「$1」を含むページは見つかりませんでした。",
+ "replacetext_nomove": "「$1」を名前に含むページは見つかりませんでした。",
+ "replacetext_nosuchcategory": "「$1」という名前のカテゴリは存在しません。",
+ "replacetext_return": "フォームに戻る",
+ "replacetext_warning": "'''警告:''' 置換後の文字列「$2」を含むページが既に {{PLURAL:$1|$1 件あります。}}この置換を実行すると、これらの文字列と実際に置換された箇所を区別できなくなります。",
+ "replacetext_blankwarning": "'''警告:''' 置換後文字列が空であるため、この操作は取り消せません。",
+ "replacetext_continue": "続行",
+ "replacetext_editsummary": "文字列「$1」を「$2」に置換",
+ "right-replacetext": "ウィキ全体で文字列の置換を実行",
+ "action-replacetext": "ウィキ全体での文字列の置換の実行"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/jv.json b/www/wiki/extensions/ReplaceText/i18n/jv.json
new file mode 100644
index 00000000..da221641
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/jv.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Meursault2004",
+ "Pras"
+ ]
+ },
+ "replacetext": "Ganti tèks",
+ "replacetext_originaltext": "Tèks asli:",
+ "replacetext_continue": "Banjurna"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ka.json b/www/wiki/extensions/ReplaceText/i18n/ka.json
new file mode 100644
index 00000000..fd8475e3
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ka.json
@@ -0,0 +1,26 @@
+{
+ "@metadata": {
+ "authors": [
+ "BRUTE",
+ "David1010",
+ "Otogi"
+ ]
+ },
+ "replacetext": "ტექსტის შეცვლა",
+ "replacetext_originaltext": "პირველადი ტექსტი:",
+ "replacetext_replacementtext": "შესაცვლელი ტექსტი:",
+ "replacetext_optionalfilters": "არასავალდებულო ფილტრები:",
+ "replacetext_categorysearch": "მხოლოდ კატეგორიაში შეცვლა:",
+ "replacetext_prefixsearch": "მხოლოდ თავსართიან გვერდებში შეცვლა:",
+ "replacetext_editpages": "ტექსტის შეცვლა გვერდების შინაარსში",
+ "replacetext_movepages": "ტექსტის შეცვლა გვერდების სათაურში, თუ ეს შესაძლებელია",
+ "replacetext_cannotmove": "შემდეგი {{PLURAL:$1|გვერდის|$1 გვერდის}} გადატანა შეუძლებელია:",
+ "replacetext_formovedpages": "გადატანილი გვერდებისათვის:",
+ "replacetext_savemovedpages": "ძველი სათაურის შენახვა როგორც ახალზე გადამისამართება",
+ "replacetext_watchmovedpages": "ამ გვერდების კონტროლი",
+ "replacetext_invertselections": "შერჩევის ინვერტირება",
+ "replacetext_replace": "ჩანაცვლება",
+ "replacetext_return": "ფორმასთან დაბრუნება.",
+ "replacetext_continue": "გაგრძელება",
+ "replacetext_editsummary": "ტექსტის შეცვლა - „$1“ „$2“-ზე"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/km.json b/www/wiki/extensions/ReplaceText/i18n/km.json
new file mode 100644
index 00000000..9ec0c7f7
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/km.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lovekhmer",
+ "Thearith",
+ "គីមស៊្រុន"
+ ]
+ },
+ "replacetext": "ជំនួសអត្ថបទ",
+ "replacetext_originaltext": "អត្ថបទដើម៖",
+ "replacetext_replacementtext": "អត្ថបទជំនួស៖",
+ "replacetext_movepages": "ជំនួស​អត្ថបទ​នៅក្នុង​ចំណងជើង​ទំព័រ​បើអាច",
+ "replacetext_choosepagesforedit": "សូម​ជ្រើសរើស {{PLURAL:$3|ទំព័រ|ទំព័រ}} សម្រាប់​អ្វី​ដែល​អ្នក​ចង់​ជំនួស '$1' ដោយ '$2':",
+ "replacetext_choosepagesformove": "ជំនួស​ \"$1\" ដោយ \"$2\" ក្នុង {{PLURAL:$1|ចំណងជើងទំព័រ​ដូចតទៅ|ចំណងជើងទំព័រ​ដូចតទៅ}}៖",
+ "replacetext_invertselections": "ដាក់បញ្ច្រាស​ជម្រើស",
+ "replacetext_replace": "ជំនួស",
+ "replacetext_success": "'$1' នឹងត្រូវបានជំនួសដោយ '$2' ក្នុង $3 {{PLURAL:$3|ទំព័រ|ទំព័រ}}​។",
+ "replacetext_noreplacement": "រក​មិន​ឃើញ​ទំព័រ​ដែល​មាន​ខ្សែអក្សរ (string) '$1' ។",
+ "replacetext_continue": "បន្ត",
+ "replacetext_editsummary": "អត្ថបទជំនួស - '$1' ទៅ '$2'"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ko.json b/www/wiki/extensions/ReplaceText/i18n/ko.json
new file mode 100644
index 00000000..6798e94f
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ko.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Devunt",
+ "Kwj2772",
+ "아라",
+ "Hwangjy9",
+ "Yearning",
+ "Ykhwong",
+ "Nuevo Paso"
+ ]
+ },
+ "replacetext": "문자열 찾아 바꾸기",
+ "replacetext-desc": "관리자가 위키 전체의 본문에 있는 문자열을 찾아 바꿀 수 있도록 [[Special:ReplaceText|특수 문서]]를 제공합니다",
+ "replacetext_docu": "이 위키에서 어떤 문자열을 다른 문자열로 바꾸기 위해서는 찾을 문자열과 바꿀 문자열을 입력한 뒤 \"{{int:replacetext_continue}}\"을 누르세요.\n그러면 해당 문자열을 포함하고 있는 문서 목록이 나오며, 그 중에서 바꿀 문서들을 선택할 수 있습니다.\n모든 바뀜에 당신의 사용자 이름이 문서 역사에 나올 것입니다.",
+ "replacetext_originaltext": "찾을 문자열:",
+ "replacetext_replacementtext": "바꿀 문자열:",
+ "replacetext_useregex": "정규 표현식 사용",
+ "replacetext_regexdocu": "(예: \"{{int:replacetext_originaltext}}\"에 \"a(.*)c\"값을 입력하고 \"{{int:replacetext_replacementtext}}\"에 \"ac$1\"값을 입력하면 \"abc\"가 \"acb\"로 바뀝니다.)",
+ "replacetext_optionalfilters": "선택적 필터:",
+ "replacetext_categorysearch": "다음 분류에서만 바꾸기:",
+ "replacetext_prefixsearch": "다음 접두어로 시작하는 문서만 바꾸기:",
+ "replacetext_editpages": "문서 내용의 문자열을 바꾸기",
+ "replacetext_movepages": "가능하다면 문서 제목에 있는 문자열도 바꾸기",
+ "replacetext_givetarget": "찾을 문자열을 반드시 지정해야 합니다.",
+ "replacetext_nonamespace": "이름공간을 적어도 하나는 선택해야 합니다.",
+ "replacetext_editormove": "찾아 바꾸기 옵션을 적어도 하나는 선택해야 합니다.",
+ "replacetext_choosepagesforedit": "{{PLURAL:$3|문서|문서 $3개}}에 있는 \"$1\" 문자열을 \"$2\" 문자열로 바꿉니다:",
+ "replacetext_choosepagesformove": "가리키는 문서 제목 $3개에 있는 \"$1\" 문자열을 \"$2\" 문자열로 바꿉니다:",
+ "replacetext_cannotmove": "다음 {{PLURAL:$1|문서는}} 이동할 수 없습니다:",
+ "replacetext_formovedpages": "이동한 문서에 대해:",
+ "replacetext_savemovedpages": "오래된 제목을 새 제목으로 넘겨주는 문서 만들기",
+ "replacetext_watchmovedpages": "이 문서 주시하기",
+ "replacetext_invertselections": "선택 반전",
+ "replacetext_replace": "찾아 바꾸기",
+ "replacetext_success": "\"$1\" 문자열은 문서 $3개에서 \"$2\" 문자열로 바뀔 것입니다.",
+ "replacetext_noreplacement": "\"$1\" 문자열을 포함하고 있는 문서가 없습니다.",
+ "replacetext_nomove": "\"$1\" 문자열을 포함하고 있는 문서 제목이 없습니다.",
+ "replacetext_nosuchcategory": "\"$1\" 문자열을 포함하고 있는 분류가 없습니다.",
+ "replacetext_return": "양식으로 돌아갑니다.",
+ "replacetext_warning": "\"$2\" 문자열을 포함하고 있는 문서 $1개가 이미 있습니다. 이 찾아 바꾸기를 실행하면, 이미 존재하는 \"$2\" 문자열과 더 이상 구분되지 않을 것입니다.\n찾아 바꾸기를 계속하겠습니까?",
+ "replacetext_blankwarning": "바꿀 문자열이 비어 있으므로 이 동작은 되돌릴 수 없습니다.\n계속하시겠습니까?",
+ "replacetext_continue": "계속",
+ "replacetext_announce": "$1과 주시문서 목록을 통해 이 편집을 알립니다.",
+ "replacetext_editsummary": "문자열 찾아 바꾸기 - \"$1\" 문자열을 \"$2\" 문자열로",
+ "right-replacetext": "위키 전체에서 찾아 바꾸기",
+ "action-replacetext": "찾아 바꾸기를 위키 전체에 수행",
+ "replacetext_reminder": "또, 다른 문서에서 이 문서를 가리키는 링크를 수정하려면 $1(으)로 이동하십시오."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ksh.json b/www/wiki/extensions/ReplaceText/i18n/ksh.json
new file mode 100644
index 00000000..0bad63df
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ksh.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha"
+ ]
+ },
+ "replacetext": "Täx-Shtöcksher ußtuusche",
+ "replacetext-desc": "Deit en [[Special:ReplaceText|{{int:specialpage}}]] en et Wiki, womet {{int:group-sysop}} aanjefbaa Täx-Schtöckscher en alle Atikelle em Wikki söhke un ußtuusche künne.",
+ "replacetext_docu": "Öm ene Täx en alle nomaale Sigge em Wiki ze söke un ußzetuusche, jif hee\nzwei Täx-Schtöcksher en, un donn dann op „{{int:replacetext continue}}“ klecke.\nDann süühß De en Leß met Sigge, wo dö dä jesoohte Täx dren änthallde es,\nun De kanns Der erußsöke, en wat för enne dovun dat De dä och jetuusch\nhan wells. Dinge Name als Metmaacher weed met dä neu veränderte Versione\nfun dä Sigge faßjehallde als dä Schriiver, dä et jemaat hät.",
+ "replacetext_originaltext": "Dä ojinaal Täx för Ußzetuusche:",
+ "replacetext_replacementtext": "Dä neue Täx för anshtatt dämm Ojinaal erin ze donn",
+ "replacetext_useregex": "Met rejolähre Ußdrök",
+ "replacetext_regexdocu": "(För e Beispel: Nämm „a(.*)c“ för „{{int:replacetext_originaltext}}“ un „ac$1“ för „{{int:replacetext_replacementtext}}“, un De kriß „abc“ dorsh „acb“ ußjetuusch.)",
+ "replacetext_optionalfilters": "Müjjelesche Beschrängkunge:",
+ "replacetext_categorysearch": "Bloß en dä Saachjropp ußtuusche:",
+ "replacetext_prefixsearch": "Bloß en Sigge ußtuusche, dänne ier Övverschreff aanfängk met:",
+ "replacetext_editpages": "Donn dä Täx em Sigge_Enhaldt ußtuusche",
+ "replacetext_movepages": "Donn dä Täx en de Sigge ier Tittele ußtuusche, wan et jeiht",
+ "replacetext_givetarget": "Do moß aanjävve, wat ußjetuusch wäde sull. „Nix“ ußtuusche künne mer nit.",
+ "replacetext_nonamespace": "Do moß winnischßdens ei Appachtemang ußwähle.",
+ "replacetext_editormove": "Do moß winnischßdenß ei Höksche maache, sönß brengk dat hee nix.",
+ "replacetext_choosepagesforedit": "Don {{PLURAL:$3|en Sigg|di Sigge|nix aan Sigge}} ußsöke, en dänne De „$1“ jääje „$2“ jetuusch han wells:",
+ "replacetext_choosepagesformove": "Donn dä Täx „$1“ en hee dä {{PLURAL:$3|Sigg|Sigge|nix}} ierem Name jäje der Täx „$2“ ußtuusche:",
+ "replacetext_cannotmove": "Heh di {{PLURAL:$1|Sigg kann|Sigge künne|nix kann}} nit ömjenannt wäde:",
+ "replacetext_formovedpages": "För ömjenannte Sigge:",
+ "replacetext_savemovedpages": "Donn der ahle Tittel faßallde un en Ömleidong op der Neue druß maache,\nwann en Sigg ömjenannt woode es.",
+ "replacetext_watchmovedpages": "Op di Sigge oppaßße",
+ "replacetext_invertselections": "De Ußwahl ömdrieje",
+ "replacetext_replace": "Tuusche",
+ "replacetext_success": "„$1“ soll en {{PLURAL:$3|eine Sigg|$3 Sigge|nix}} dorsch „$2“ ußjetuusch wääde.",
+ "replacetext_noreplacement": "Kein Sigge jefonge met däm Täxstöck „$1“ dren.",
+ "replacetext_nomove": "Mer han kei Sigge jefonge, woh „$1“ en de Övverschreff dren förkütt.",
+ "replacetext_nosuchcategory": "Mer han kein Saachjropp met dämm Name „$1“.",
+ "replacetext_return": "Jangk retuhr op dat Fommolaa.",
+ "replacetext_warning": "<strong>Opjepaß:<strong>\n{{PLURAL:$1|Ein Sigg enthält|$1 Sigge enthallde}} ald dat Täxstöck „$2“, wat bemm Tuusche ennjeföhsch wähde sull.\nWenn De dat jemaat häs, kam_mer di Ännderong nit esu leijsch automattesch retuhr maache, weil mer di ald do wohre, un de ennjetuuschte Täxschtöker nit ongerscheide kann.\nWells De verhafftesch trozdämm wigger maache?",
+ "replacetext_blankwarning": "Dat Täxstöck, wat beim Tuusche ennjföhsch weed, es läddesch, dröm kam_mer di Ännderong nidd esu leijsch automattesch retuhr maache.\nWells De trozdämm wigger maache?",
+ "replacetext_continue": "Wiggermaache",
+ "replacetext_editsummary": "Täx-Schtöker tuusche — vun „$1“ noh „$2“",
+ "right-replacetext": "Täx-Schtöckscher em janze Wiki ußtuusche",
+ "action-replacetext": "Täx-Schtöckscher em janze Wiki ußzetuusche"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/lb.json b/www/wiki/extensions/ReplaceText/i18n/lb.json
new file mode 100644
index 00000000..c66ebb3c
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/lb.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Les Meloures",
+ "Robby"
+ ]
+ },
+ "replacetext": "Text ersetzen",
+ "replacetext-desc": "Weist eng [[Special:ReplaceText|Spezialsäit]] déi Administrateuren et erlaabt eng Rei vun Textzeechen op alle Contenu-säite vun enger Wiki ze gesinn an z'ersetzen",
+ "replacetext_docu": "Fir en Text duerch en aneren Text op allen Inhaltssäite vun dëser Wiki z'ersetzen, gitt w.e.g. déi zwéin Texter hei an klickt op \"{{int:replacetext_continue}}\". Dir gesitt dann eng Lëscht vu Säiten op deenen de gesichten Text dran ass, an Dir kënnt déi eraussichen op deenen Dir den Text ersetze wëllt. Ären Numm steet an der Lëscht vun de Versiounen als Auteur vun all deenen Ännerungen.",
+ "replacetext_originaltext": "Originaltext:",
+ "replacetext_replacementtext": "Neien Text:",
+ "replacetext_useregex": "Regulär Ausdréck benotzen",
+ "replacetext_regexdocu": "(Beispill: De Wäert „a(.*)c“ fir \"{{int:replacetext_originaltext}}“ an \"ac$1\" fir „Neien Text\"{{int:replacetext_replacementtext}}\" géif „abc“ duerch „acb“ ersetzen.)",
+ "replacetext_optionalfilters": "Optional Filteren:",
+ "replacetext_categorysearch": "Ersetz nëmmen an der Kategorie:",
+ "replacetext_prefixsearch": "Ersetz nëmmen a Säite mam Prefix:",
+ "replacetext_editpages": "Den Text a Säiteninhalter ersetzen",
+ "replacetext_movepages": "Text an den Titele vun de Säiten ersetzen, wa méiglech",
+ "replacetext_givetarget": "Dir musst déi Zeechen uginn déi ersat solle ginn.",
+ "replacetext_nonamespace": "Dir musst mindestens een Nummraum eraussichen.",
+ "replacetext_editormove": "Dir musst mindestens eng vun den Optioune vum Ersetzen eraussichen.",
+ "replacetext_choosepagesforedit": "Wielt w.e.g. d'{{PLURAL:$3|Säit op där|Säiten op deenen}} Dir \"$1\" duerch \"$2\" ersetze wëllt:",
+ "replacetext_choosepagesformove": "'$1' duerch '$2' am Titel vun {{PLURAL:$3|dëser Säit|dëse Säiten}} ersetzen:",
+ "replacetext_cannotmove": "Dës {{PLURAL:$1|Säit kann|Säite kënne}} net geréckelt ginn:",
+ "replacetext_formovedpages": "Fir geréckelt Säiten:",
+ "replacetext_savemovedpages": "Déi al Titelen als Viruleedung op déi nei Titele späicheren",
+ "replacetext_watchmovedpages": "Dës Säiten iwwerwaachen",
+ "replacetext_invertselections": "Auswiel ëmdréinen",
+ "replacetext_replace": "Ersetzen",
+ "replacetext_success": "'$1' gëtt duerch '$2' op $3 {{PLURAL:$3|Säit|Säiten}} ersat.",
+ "replacetext_noreplacement": "Et goufe keng Säite mam Text '$1' fonnt.",
+ "replacetext_nomove": "Keng Säite fonnt wou '$1' am Titel drasteet.",
+ "replacetext_nosuchcategory": "Et gëtt keng Kategorie mam Numm \"$1\".",
+ "replacetext_return": "Zréck op de Formulaire",
+ "replacetext_warning": "'''Opgepasst:''' Et gëtt schonn {{PLURAL:$1|eng Säit op där|$1 Säiten op deenen}} d'Zeecherei '$2' schonn dran ass.\nWann Dir dës Ännerunge maacht wäert et Iech net méi méiglech sinn déi Säiten op deenen Dir Ännerunge gemaach hutt vun de Säiten z'ënnerscheeden wou elo d'Zeecherei '$2' schonn dran ass.",
+ "replacetext_blankwarning": "Well den Textdeel mat dem de gesichten Text ersat gi soll eidel ass, kann dës Aktioun net réckgängeg gemaach ginn; wëllt Dir awer virufueren?",
+ "replacetext_continue": "Virufueren",
+ "replacetext_editsummary": "Text ersat - \"$1\" duerch \"$2\"",
+ "right-replacetext": "Ersetze vun enger Rei vun Textzeechen op der ganzer Wiki",
+ "action-replacetext": "ersetze vun enger Rei vun Textzeechen op der ganzer Wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/lki.json b/www/wiki/extensions/ReplaceText/i18n/lki.json
new file mode 100644
index 00000000..043b22d0
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/lki.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lakzon"
+ ]
+ },
+ "replacetext_categorysearch": "جایگزینی فقط در ڕِزگ:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/lt.json b/www/wiki/extensions/ReplaceText/i18n/lt.json
new file mode 100644
index 00000000..271879c8
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/lt.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Homo",
+ "Manvydasz"
+ ]
+ },
+ "replacetext": "Keisti tekstą",
+ "replacetext_cannotmove": "{{PLURAL:$1|Šis puslapis|Šie $1 puslapiai|Šie $1 puslapių}} negali būti pervadinti:",
+ "replacetext_continue": "Tęsti",
+ "replacetext_editsummary": "Teksto pakeitimas - \"$1\" į \"$2\""
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/mg.json b/www/wiki/extensions/ReplaceText/i18n/mg.json
new file mode 100644
index 00000000..95bba3e7
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/mg.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jagwar"
+ ]
+ },
+ "right-replacetext": "Manolo lahatsoratra misy manerana ilay wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/mk.json b/www/wiki/extensions/ReplaceText/i18n/mk.json
new file mode 100644
index 00000000..fc2080e3
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/mk.json
@@ -0,0 +1,43 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06"
+ ]
+ },
+ "replacetext": "Замени текст",
+ "replacetext-desc": "Додава [[Special:ReplaceText|службена страница]] која им овозможува на администраторите да вршат пронаоѓање и замена на глобални низи во страниците на викито",
+ "replacetext_docu": "За да замените една низа со друга, ширум сите регуларни страници на ова вики, внесете ги тука двете парчиња текст и потоа притиснете на „{{int:replacetext_continue}}“.\nПотоа ќе ви се прикаже список на страници кои го содржат бараниот текст, и ќе можете да изберете во кои од нив сакате да ја извршите змената.\nВашето име ќе се појави во историјата на страниците како корисник одговорен за промените.",
+ "replacetext_originaltext": "Изворен текст:",
+ "replacetext_replacementtext": "Нов текст:",
+ "replacetext_useregex": "Користи регуларни изрази",
+ "replacetext_regexdocu": "(Пример: вредностите на „a(.*)c“ за „{{int:replacetext_originaltext}}“ и „ac$1“ за „{{int:replacetext_replacementtext}}“ ќе го заменат „abc“ со „acb“.)",
+ "replacetext_optionalfilters": "Незадолжителни филтри:",
+ "replacetext_categorysearch": "Замени само во категорија:",
+ "replacetext_prefixsearch": "Замени само во страници со претставката:",
+ "replacetext_editpages": "Замени текст во содржина на страница",
+ "replacetext_movepages": "Замени текст во насловите на страниците, кога е можно",
+ "replacetext_givetarget": "Мора да ја наведете низата што треба да се замени.",
+ "replacetext_nonamespace": "Мора да изберете барем еден именски простор.",
+ "replacetext_editormove": "Мора да одберете барем една од можностите за замена.",
+ "replacetext_choosepagesforedit": "Замени „$1“ со „$2“ во текстот на {{PLURAL:$3|следнава страница|следниве страници}}:",
+ "replacetext_choosepagesformove": "Замени „$1“ со „$2“ во {{PLURAL:$3|насловот на следната страница|насловите на следните страници}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Следнава страница не може да се премести|Следниве страници не можат да се преместат}}:",
+ "replacetext_formovedpages": "За преместени страници:",
+ "replacetext_savemovedpages": "Зачувај ги старите наслови како пренасочувања кон новите наслови",
+ "replacetext_watchmovedpages": "Набљудувај ги овие страници",
+ "replacetext_invertselections": "Обратен избор",
+ "replacetext_replace": "Замени",
+ "replacetext_success": "„$1“ ќе биде заменето со „$2“ во $3 {{PLURAL:$3|страница|страници}}.",
+ "replacetext_noreplacement": "Нема пронајдено страници кои ја содржат низата „$1“.",
+ "replacetext_nomove": "Нема пронајдено страници чиј наслов содржи „$1“.",
+ "replacetext_nosuchcategory": "Не постои категорија по име „$1“",
+ "replacetext_return": "Назад кон образецот",
+ "replacetext_warning": "'''Предупредување:''' Има {{PLURAL:$1|$1 страница што веќе ја содржи|$1 страници што веќе ја содржат}} новата низа „$2“. Ако ја извршите оваа замена, тогаш нема да можете да ги раздвоите вашите замени од тие низи.",
+ "replacetext_blankwarning": "Бидејќи новата низа е празна, оваа постапка е не повратна.",
+ "replacetext_continue": "Продолжи",
+ "replacetext_announce": "Соопштувај ги овие уредувања преку $1 и набљудуваните",
+ "replacetext_editsummary": "Замена на текст — „$1“ со „$2“",
+ "right-replacetext": "Вршење замена на низи во целото вики",
+ "action-replacetext": "вршење замена на низи во целото вики",
+ "replacetext_reminder": "За воедно да ги измените до оваа страница на други страници, појдете на $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ml.json b/www/wiki/extensions/ReplaceText/i18n/ml.json
new file mode 100644
index 00000000..15c23565
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ml.json
@@ -0,0 +1,35 @@
+{
+ "@metadata": {
+ "authors": [
+ "Praveenp",
+ "Shijualex"
+ ]
+ },
+ "replacetext": "എഴുത്ത് മാറ്റിച്ചേർക്കുക",
+ "replacetext-desc": "വിക്കിയിലെ എല്ലാ ഉള്ളടക്ക താളിൽ നിന്നും കാര്യനിർവാഹകർക്ക് ഒരു പ്രത്യേക പദത്തെ കണ്ടെത്തി-മാറ്റിച്ചേർക്കാനുള്ള [[Special:ReplaceText|പ്രത്യേക താൾ]] നൽകുന്നു",
+ "replacetext_originaltext": "യഥാർത്ഥ എഴുത്ത്:",
+ "replacetext_replacementtext": "മാറ്റിച്ചേർക്കേണ്ട എഴുത്ത്:",
+ "replacetext_optionalfilters": "ഐച്ഛിക അരിപ്പകൾ:",
+ "replacetext_categorysearch": "ഈ വർഗ്ഗത്തിൽ നിന്നു മാത്രം മാറ്റിച്ചേർക്കുക:",
+ "replacetext_prefixsearch": "ഈ പൂർവ്വപദമുള്ള താളുകളിൽ മാത്രം മാറ്റിച്ചേർക്കുക:",
+ "replacetext_editpages": "താളിന്റെ ഉള്ളടക്കത്തിലെ എഴുത്ത് മാറ്റിച്ചേർക്കുക",
+ "replacetext_movepages": "സാദ്ധ്യമെങ്കിൽ, താളിന്റെ ഉള്ളടക്കത്തിലെ എഴുത്തുകൾ മാറ്റിച്ചേർക്കുക",
+ "replacetext_givetarget": "മാറ്റിച്ചേർക്കാനുള്ള പദം താങ്കൾ വ്യക്തമാക്കണം.",
+ "replacetext_nonamespace": "ഒരു നാമമേഖലയെങ്കിലും തിരഞ്ഞെടുത്തിരിക്കണം.",
+ "replacetext_editormove": "ഒരു മാറ്റിച്ചേർക്കൽ ഐച്ഛികമെങ്കിലും തിരഞ്ഞെടുത്തിരിക്കണം.",
+ "replacetext_choosepagesforedit": "താഴെയുള്ള {{PLURAL:$3|താളിൽ|താളുകളിൽ}} നിന്നും \"$1\" എന്നത് \"$2\" എന്നതുകൊണ്ട് മാറ്റിച്ചേർക്കുക:",
+ "replacetext_choosepagesformove": "താഴെയുള്ള {{PLURAL:$3|താളിന്റെ തലക്കെട്ടിൽ|താളുകളുടെ തലക്കെട്ടുകളിൽ}} നിന്നും \"$1\" എന്നത് \"$2\" എന്നതുകൊണ്ട് മാറ്റിച്ചേർക്കുക:",
+ "replacetext_cannotmove": "താഴെയുള്ള {{PLURAL:$1|താൾ|താളുകൾ}} മാറ്റാനാവില്ല:",
+ "replacetext_formovedpages": "മാറ്റിയ താളുകൾക്ക് വേണ്ടി:",
+ "replacetext_savemovedpages": "പഴയ തലക്കെട്ടുകൾ പുതിയ തലക്കെട്ടുകളിലോട്ടുള്ള തിരിച്ചുവിടലായി നിലനിർത്തുക",
+ "replacetext_watchmovedpages": "ഈ താളുകൾ ശ്രദ്ധിക്കുക",
+ "replacetext_invertselections": "വിപരീതം തിരഞ്ഞെടുക്കുക",
+ "replacetext_replace": "മാറ്റിച്ചേർക്കുക",
+ "replacetext_success": "{{PLURAL:$3|ഒരു താളിൽ|$3 താളുകളിൽ}} \"$1\" എന്നത് \"$2\" എന്നതുകൊണ്ട് മാറ്റിച്ചേർക്കപ്പെടും.",
+ "replacetext_noreplacement": "\"$1\" എന്ന പദമുള്ള താളുകളൊന്നും കണ്ടെത്താനായില്ല.",
+ "replacetext_nomove": "ഒരു താളിന്റെയും തലക്കെട്ടിൽ \"$1\" എന്നു കണ്ടെത്താനായില്ല.",
+ "replacetext_return": "ഫോമിലേക്ക് തിരിച്ചു പോവുക",
+ "replacetext_continue": "തുടരുക",
+ "replacetext_editsummary": "എഴുത്ത് മാറ്റിച്ചേർക്കൽ - \"$1\" എന്നത് \"$2\" എന്നതുകൊണ്ട്",
+ "right-replacetext": "വിക്കിയിൽ മുഴുവനും പദം മാറ്റിച്ചേർക്കുക"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/mr.json b/www/wiki/extensions/ReplaceText/i18n/mr.json
new file mode 100644
index 00000000..3b8b4dc6
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/mr.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Kaustubh",
+ "V.narsikar"
+ ]
+ },
+ "replacetext": "मजकूरावर पुनर्लेखन करा",
+ "replacetext-desc": "एक [[Special:ReplaceText|विशेष पान]] देते ज्याच्यामुळे प्रबंधकांना एखाद्या विकिवरील सर्व पानांमध्ये शोधा व बदला सुविधा वापरता येते",
+ "replacetext_docu": "एखाद्या विकितील सर्व डाटा पानांवरील एखादा मजकूर बदलायचा झाल्यास, मजकूराचे दोन्ही तुकडे खाली लिहून 'पुनर्लेखन करा' कळीवर टिचकी द्या. तुम्हाला एक यादी दाखविली जाईल व त्यामधील कुठली पाने बदलायची हे तुम्ही ठरवू शकता. तुमचे नाव त्या पानांच्या इतिहास यादीत दिसेल.",
+ "replacetext_originaltext": "मूळ मजकूर",
+ "replacetext_replacementtext": "बदलण्यासाठीचा मजकूर",
+ "replacetext_choosepagesforedit": "ज्या पानांवर तुम्ही '$1' ला '$2' ने बदलू इच्छिता ती पाने निवडा:",
+ "replacetext_replace": "पुनर्लेखन करा",
+ "replacetext_success": "'$1' ला '$2' ने $3 पानांवर बदलले जाईल.",
+ "replacetext_noreplacement": "'$1' मजकूर असणारे एकही पान सापडले नाही.",
+ "replacetext_warning": "अगोदरच $1 पानांवर '$2' हा बदलण्यासाठीचा मजकूर आहे; जर तुम्ही पुनर्लेखन केले तर तुम्ही केलेले बदल तुम्ही या पानांपासून वेगळे करू शकणार नाही. पुनर्लेखन करायचे का?",
+ "replacetext_blankwarning": "बदलण्यासाठीचा मजकूर रिकामा असल्यामुळे ही क्रिया उलटविता येणार नाही; पुढे जायचे का?",
+ "replacetext_continue": "चालू ठेवा",
+ "replacetext_editsummary": "मजकूर पुनर्लेखन - '$1' ते '$2'"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ms.json b/www/wiki/extensions/ReplaceText/i18n/ms.json
new file mode 100644
index 00000000..345a90fc
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ms.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia",
+ "Pizza1016"
+ ]
+ },
+ "replacetext": "Ganti teks",
+ "replacetext-desc": "Menyediakan sebuah [[Special:ReplaceText|laman khas]] untuk membolehkan para penyelia untuk melakukan pencarian dan penggantian rentetan sejagat pada semua laman-laman kandungan sebuah wiki",
+ "replacetext_docu": "Untuk mengganti satu rentetan teks dengan satu lagi merentasi semua laman biasa di wiki ini, isikan kedua-dua teks yang terlibat di sini, kemudian tekan '{{int:replacetext_continue}}'.\nKemudian, anda akan ditunjukkan satu senarai laman yang mengandungi teks carian, dan anda boleh memilih laman-laman yang mana anda ingin melakukan penggantian itu.\nNama anda akan terpapar dalam sejarah laman sebagai pengguna yang bertanggungjawab atas sebarang perubahan.",
+ "replacetext_originaltext": "Teks asal:",
+ "replacetext_replacementtext": "Teks ganti:",
+ "replacetext_useregex": "Gunakan ungkapan nalar",
+ "replacetext_regexdocu": "(Contoh: nilai \"a(.*)c\" untuk \"{{int:replacetext_originaltext}}\" dan \"ac$1\" untuk \"{{int:replacetext_replacementtext}}\" akan mengganti \"abc\" dengan \"acb\".)",
+ "replacetext_optionalfilters": "Penapis pilihan:",
+ "replacetext_categorysearch": "Ganti dalam kategori sahaja:",
+ "replacetext_prefixsearch": "Ganti dalam laman yang berawalan ini sahaja:",
+ "replacetext_editpages": "Ganti teks dalam kandungan laman",
+ "replacetext_movepages": "Ganti teks dalam tajuk laman, jika boleh",
+ "replacetext_givetarget": "Anda mesti menyatakan rentetan untuk diganti.",
+ "replacetext_nonamespace": "Anda mesti memilih sekurang-kurangnya satu ruang nama.",
+ "replacetext_editormove": "Anda mesti memilih sekurang-kurangnya satu pilihan penggantian.",
+ "replacetext_choosepagesforedit": "Ganti \"$1\" dengan \"$2\" dalam teks {{PLURAL:$3|laman|laman-laman}} berikut:",
+ "replacetext_choosepagesformove": "Ganti \"$1\" dengan \"$2\" dalam {{PLURAL:$3|judul|judul-judul}} laman yang berikut:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Laman|Laman-laman}} yang berikut tidak boleh dipindahkan:",
+ "replacetext_formovedpages": "Untuk laman yang dipindahkan:",
+ "replacetext_savemovedpages": "Simpan tajuk lama sebagai lencongan kepada tajuk baru",
+ "replacetext_watchmovedpages": "Pantau laman-laman ini",
+ "replacetext_invertselections": "Songsangkan pilihan",
+ "replacetext_replace": "Ganti",
+ "replacetext_success": "\"$1\" akan digantikan oleh \"$2\" di $3 laman.",
+ "replacetext_noreplacement": "Tiada laman yang mengandungi rentetan \"$1\".",
+ "replacetext_nomove": "Tiada laman yang mengandungi \"$1\" dalam tajuknya.",
+ "replacetext_nosuchcategory": "Tiada kategori dengan nama \"$1\".",
+ "replacetext_return": "Kembali ke borang.",
+ "replacetext_warning": "'''Amaran:''' Terdapat $1 laman yang sudah mengandungi rentetan ganti \"$2\". Jika anda melakukan penggantian ini, anda tidak akan dapat mengasingkan gantian anda daripada rentetan-rentetan ini.",
+ "replacetext_blankwarning": "'''Amaran:''' Oleh sebab rentetan ganti adalah kosong, operasi ini tidak boleh dimansuhkan.",
+ "replacetext_continue": "Sambung",
+ "replacetext_editsummary": "Ganti teks - \"$1\" kepada \"$2\"",
+ "right-replacetext": "Membuat penggantian rentetan di seluruh wiki",
+ "action-replacetext": "melakukan penggantian rentetan di seluruh wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/nb.json b/www/wiki/extensions/ReplaceText/i18n/nb.json
new file mode 100644
index 00000000..c96ea0eb
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/nb.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Event",
+ "Laaknor",
+ "Nghtwlkr",
+ "Simny",
+ "Jon Harald Søby"
+ ]
+ },
+ "replacetext": "Erstatt tekst",
+ "replacetext-desc": "Lar administratorer kunne [[Special:ReplaceText|erstatte tekst]] på alle innholdssider på en wiki.",
+ "replacetext_docu": "For å erstatte én tekststreng med en annen på alle datasider på denne wikien kan du skrive inn de to tekstene her og trykke «{{int:replacetext_continue}}».\nDu vil da bli ført til en liste over sider som inneholder søketeksten, og du kan velge hvilke sider du ønsker å erstatte den i.\nNavnet ditt vil stå i sidehistorikkene som den som er ansvarlig for endringene.",
+ "replacetext_originaltext": "Originaltekst:",
+ "replacetext_replacementtext": "Erstatningstekst:",
+ "replacetext_useregex": "Bruk regulæruttrykk",
+ "replacetext_regexdocu": "(Eksempel: Verdier for \"a(.*)c\" i \"{{int:replacetext_originaltext}}\" og \"ac$1\" i \"{{int:replacetext_replacementtext}}\" erstatter \"abc\" med \"acb\".)",
+ "replacetext_optionalfilters": "Valgfrie filter:",
+ "replacetext_categorysearch": "Erstatt kun i kategori:",
+ "replacetext_prefixsearch": "Erstatt kun i sider med prefikset:",
+ "replacetext_editpages": "Erstatt tekst i sideinnholdet",
+ "replacetext_movepages": "Erstatt tekst i sidetitler, der dette er mulig",
+ "replacetext_givetarget": "Du må spesifisere en streng som skal erstattes.",
+ "replacetext_nonamespace": "Du må velge minst ett navnerom.",
+ "replacetext_editormove": "Du må velge minst ett av alternativene for erstatning.",
+ "replacetext_choosepagesforedit": "Velg {{PLURAL:$3|siden|sidene}} der du ønsker å bytte ut «$1» med «$2»:",
+ "replacetext_choosepagesformove": "Erstatt «$1» med «$2» i {{PLURAL:$3|tittelen på den følgende siden|titlene på de følgende sidene}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Den følgende siden|De følgende sidene}} kan ikke flyttes:",
+ "replacetext_formovedpages": "For flyttede sider:",
+ "replacetext_savemovedpages": "Lagre de gamle titlene som omdirigeringer til de nye",
+ "replacetext_watchmovedpages": "Overvåk disse sidene",
+ "replacetext_invertselections": "Inverter valg",
+ "replacetext_replace": "Erstatt",
+ "replacetext_success": "«$1» blir erstattet med «$2» på {{PLURAL:$3|én side|$3 sider}}.",
+ "replacetext_noreplacement": "Ingen sider ble funnet med strengen «$1».",
+ "replacetext_nomove": "Ingen sider ble funnet der tittelen inneholder «$1».",
+ "replacetext_nosuchcategory": "Det eksisterer ingen kategori med navnet «$1».",
+ "replacetext_return": "Tilbake til skjemaet.",
+ "replacetext_warning": "'''Advarsel:''' Det er {{PLURAL:$1|én side|$1 sider}} som allerede har erstatningsteksten «$2». Om du gjør denne erstatningen vil du ikke kunne skille ut dine erstatninger fra denne teksten.",
+ "replacetext_blankwarning": "Fordi erstatningsteksten er tom vil denne handlingen ikke kunne angres automatisk; fortsette?",
+ "replacetext_continue": "Fortsett",
+ "replacetext_editsummary": "Teksterstatting – «$1» til «$2»",
+ "right-replacetext": "Gjennomfør teksterstatninger på hele wikien",
+ "action-replacetext": "gjennomføre strengerstatninger på hele wikien"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/nl.json b/www/wiki/extensions/ReplaceText/i18n/nl.json
new file mode 100644
index 00000000..3a0a7c2f
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/nl.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "HanV",
+ "SPQRobin",
+ "Siebrand",
+ "Patio",
+ "Fitoschido"
+ ]
+ },
+ "replacetext": "Tekst vervangen",
+ "replacetext-desc": "Beheerders kunnen via een [[Special:ReplaceText|speciale pagina]] tekst zoeken en vervangen in alle pagina's",
+ "replacetext_docu": "Om een stuk tekst te vervangen door een ander stuk tekst in alle pagina's van de wiki, kunt u hier deze twee tekstdelen opgeven en daarna op \"{{int:replacetext_continue}}\" klikken.\nU krijgt dan een lijst met pagina's te zien waar uw te vervangen tekstdeel in voorkomt, en u kunt kiezen in welke pagina's u de tekst ook echt wilt vervangen.\nUw naam wordt opgenomen in de geschiedenis van de pagina als verantwoordelijke voor de wijzigingen.",
+ "replacetext_originaltext": "Oorspronkelijke tekst:",
+ "replacetext_replacementtext": "Vervangende tekst:",
+ "replacetext_useregex": "Reguliere expressies en wildcards gebruiken",
+ "replacetext_regexdocu": "Voorbeeld: waarden van \"a(.*)c\" voor \"{{int:replacetext_originaltext}}\" en \"ac$1\" voor \"{{int:replacetext_replacementtext}}\", vervangt \"abc\" door \"acb\".",
+ "replacetext_optionalfilters": "Optionele filters:",
+ "replacetext_categorysearch": "Alleen in de volgende categorie vervangen:",
+ "replacetext_prefixsearch": "Alleen in pagina's met het volgende voorvoegsel vervangen:",
+ "replacetext_editpages": "Tekst vervangen in de pagina-inhoud",
+ "replacetext_movepages": "Tekst vervangen in paginanamen als mogelijk",
+ "replacetext_givetarget": "U moet de te vervangen tekst opgeven.",
+ "replacetext_nonamespace": "U moet ten minste één naamruimte selecteren.",
+ "replacetext_editormove": "U moet ten minste één van de vervangingsopties kiezen.",
+ "replacetext_choosepagesforedit": "Selecteer de {{PLURAL:$3|pagina|pagina's}} waar u \"$1\" door \"$2\" wilt vervangen:",
+ "replacetext_choosepagesformove": "\"$1\" door \"$2\" vervangen in de volgende {{PLURAL:$3|paginanaam|paginanamen}}:",
+ "replacetext_cannotmove": "De volgende {{PLURAL:$1|pagina kan|pagina's kunnen}} niet hernoemd worden:",
+ "replacetext_formovedpages": "Voor hernoemde pagina's:",
+ "replacetext_savemovedpages": "Een doorverwijzing aanmaken voor hernoemde pagina's",
+ "replacetext_watchmovedpages": "Deze pagina's volgen",
+ "replacetext_invertselections": "Selecties omkeren",
+ "replacetext_replace": "Vervangen",
+ "replacetext_success": "\"$1\" wordt in $3 {{PLURAL:$3|pagina|pagina's}} vervangen door \"$2\".",
+ "replacetext_noreplacement": "Er waren geen pagina's die de tekst '$1' bevatten.",
+ "replacetext_nomove": "Er zijn geen pagina's gevonden met \"$1\" in de naam.",
+ "replacetext_nosuchcategory": "De categorie \"$1\" bestaat niet.",
+ "replacetext_return": "Terugkeren naar het formulier.",
+ "replacetext_warning": "'''Waarschuwing:''' Er {{PLURAL:$1|is één pagina|zijn $1 pagina's}} die het te vervangen tekstdeel al \"$2\" al {{PLURAL:$1|bevat|bevatten}}.\nAls u nu doorgaat met vervangen, kunt u geen onderscheid meer maken.",
+ "replacetext_blankwarning": "Omdat u tekst vervangt door niets, kan deze handeling niet ongedaan gemaakt worden. Wilt u doorgaan?",
+ "replacetext_continue": "Doorgaan",
+ "replacetext_announce": "Meld deze bewerkingen op $1 en volglijsten.",
+ "replacetext_editsummary": "Tekst vervangen - \"$1\" door \"$2\"",
+ "right-replacetext": "Tekst vervangen in de hele wiki",
+ "action-replacetext": "tekst te vervangen in de hele wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/nn.json b/www/wiki/extensions/ReplaceText/i18n/nn.json
new file mode 100644
index 00000000..eb625375
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/nn.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gunnernett",
+ "Harald Khan",
+ "Njardarlogar"
+ ]
+ },
+ "replacetext": "Byt ut tekst",
+ "replacetext-desc": "Gjev ei [[Special:ReplaceText|spesialsida]] som lèt administratorar søkja etter og byta ut tekst på alle innhaldssidene på ein wiki.",
+ "replacetext_docu": "For å byta ein tekststreng med ein annan på alle vanlege sider på denne wikien kan du skriva inn dei to tekstbitane her og klikka «{{int:replacetext_continue}}». Du vil då verta ført til ei liste over sidene som inneheld søkjestrengen, og du kan velja kva sider du ønskjer å byta han ut i. Namnet ditt vil stå i sidehistorikkane som den som er ansvarleg for endringane.",
+ "replacetext_originaltext": "Originaltekst:",
+ "replacetext_replacementtext": "Ny tekst til erstatning:",
+ "replacetext_optionalfilters": "Valfrie filter:",
+ "replacetext_categorysearch": "Byt berre ut i kategorien:",
+ "replacetext_prefixsearch": "Byt berre ut på sider med førestavinga:",
+ "replacetext_editpages": "Byt ut tekst i sideinnhaldet",
+ "replacetext_movepages": "Byt ut tekst i sidetitlar der dette er mogleg",
+ "replacetext_givetarget": "Du må spesifisera strengen som skal verta bytt ut.",
+ "replacetext_nonamespace": "Du må velja minst eitt namnerom.",
+ "replacetext_editormove": "Du må velja minst eitt av vala for tekstbyte.",
+ "replacetext_choosepagesforedit": "Vel {{PLURAL:$3|sida|sidene}} der du ønskjer å byta ut «$1» med «$2»:",
+ "replacetext_choosepagesformove": "Byt ut «$1» med «$2» i {{PLURAL:$3|namnet på den følgjande sida|namna på dei følgjande sidene}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Den følgjande sida|Dei følgjande sidene}} kan ikkje bli flytta:",
+ "replacetext_formovedpages": "For flytta sider:",
+ "replacetext_savemovedpages": "Lagra dei gamle titlane som omdirigeringar til dei nye",
+ "replacetext_watchmovedpages": "Hald oppsyn med desse sidene",
+ "replacetext_invertselections": "Inverter val",
+ "replacetext_replace": "Byt ut",
+ "replacetext_success": "$1» blir byta ut med «$2» på {{PLURAL:$3|éi sida|$3 sider}}.",
+ "replacetext_noreplacement": "Fann ingen sider som inneheldt søkjestrengen «$1».",
+ "replacetext_nomove": "Ingen sider vart funne der tittelen inneheld «$1».",
+ "replacetext_nosuchcategory": "Det finst ingen kategoriar med namnet «$1».",
+ "replacetext_return": "Attende til skjemaet.",
+ "replacetext_warning": "Det finst {{PLURAL:$1|éi sida|$1 sider}} som allereie inneheld strengen som skal bli sett inn, «$2».\nOm du utfører denne utbytinga vil du ikkje vera i stand til å skilja utbytingane dine frå desse strengane.\nHalda fram med utbytinga?",
+ "replacetext_blankwarning": "Av di teksten som skal bli sett inn er tom, vil ikkje denne handlinga kunna bli køyrt omvendt.\nVil du halda fram?",
+ "replacetext_continue": "Hald fram",
+ "replacetext_editsummary": "Utbyting av tekst - «$1» til «$2»",
+ "right-replacetext": "Gjennomfør utbyting av tekst på heile wikien"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/oc.json b/www/wiki/extensions/ReplaceText/i18n/oc.json
new file mode 100644
index 00000000..d376a452
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/oc.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31",
+ "Unuaiga",
+ "Fitoschido"
+ ]
+ },
+ "replacetext": "Remplaçar lo tèxte",
+ "replacetext-desc": "Provesís una [[Special:ReplaceText|pagina especiala]] que permet als administrators de remplaçar de cadenas de caractèrs per d’autras sus l’ensemble del wiki",
+ "replacetext_docu": "Per remplaçar una cadena de caractèrs per una autra sus l'ensemble de las donadas de las paginas d'aqueste wiki, podètz picar los dos tèxtes aicí e clicar sus « {{int:replacetext_replace}} ».\nUna lista de las paginas que contenon lo tèxte recercat apareisserà e poiretz causir las que volètz modificar.\nVòstre nom apareiserà dins l'istoric de las paginas tal coma un utilizaire autor dels cambiaments.",
+ "replacetext_originaltext": "Tèxte original :",
+ "replacetext_replacementtext": "Tèxte novèl :",
+ "replacetext_optionalfilters": "Filtres opcionals :",
+ "replacetext_categorysearch": "Remplaçar solament dins la categoria :",
+ "replacetext_prefixsearch": "Remplaçar solament dins las paginas qu'an lo prefix :",
+ "replacetext_editpages": "Remplaçar lo tèxte dins lo contengut dins la pagina",
+ "replacetext_movepages": "Remplaçar lo tèxte dins lo títol de las paginas, se possible",
+ "replacetext_givetarget": "Vos cal especificar la cadena de remplaçar.",
+ "replacetext_nonamespace": "Vos cal seleccionar al mens un espaci de noms.",
+ "replacetext_editormove": "Vos cal causir al mens una opcion de remplaçament.",
+ "replacetext_choosepagesforedit": "Seleccionatz {{PLURAL:$3|la pagina|las paginas}} dins {{PLURAL:$3|la quala|las qualas}} volètz remplaçar « $1 » per « $2 » :",
+ "replacetext_choosepagesformove": "Remplaçar « $1 » per « $2 » dins {{PLURAL:$3|lo nom de la pagina seguenta|los noms de las paginas seguentas}} :",
+ "replacetext_cannotmove": "{{PLURAL:$1|La pagina seguenta a pas pogut èsser renomenada|Las paginas seguentas an pas pogut èsser renomenadas}} :",
+ "replacetext_formovedpages": "Per las paginas renomenadas :",
+ "replacetext_savemovedpages": "Enregistratz los títols ancians coma redireccions cap als títols novèls",
+ "replacetext_watchmovedpages": "Seguir aquestas paginas",
+ "replacetext_invertselections": "Inversar las seleccions",
+ "replacetext_replace": "Remplaçar",
+ "replacetext_success": "« $1 » es estat remplaçat per « $2 » dins $3 fichièr{{PLURAL:$3||s}}.",
+ "replacetext_noreplacement": "Cap de fichièr que conten la cadena « $1 » es pas estat trobat.",
+ "replacetext_nomove": "Cap de pagina es pas estada trobada amb lo títol que conten « $1 ».",
+ "replacetext_nosuchcategory": "Existís pas de categoria nomenada « $1 ».",
+ "replacetext_return": "Tornar al formulari.",
+ "replacetext_warning": "I a $1 fichièr{{PLURAL:$1| que conten|s que contenon}} ja la cadena de remplaçament « $2 ».\nS'efectuatz aquesta substitucion, poiretz pas separar vòstres cambiaments a partir d'aquestas cadenas.",
+ "replacetext_blankwarning": "Perque la cadena de remplaçament es voida, aquesta operacion serà irreversibla ; volètz contunhar ?",
+ "replacetext_continue": "Contunhar",
+ "replacetext_announce": "Anonciar aquelas modificacions via $1 e via las listas de seguit.",
+ "replacetext_editsummary": "Remplaçament de tèxte — « $1 » per « $2 »",
+ "right-replacetext": "Far de remplaçaments de tèxte dins tot lo wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/pdc.json b/www/wiki/extensions/ReplaceText/i18n/pdc.json
new file mode 100644
index 00000000..0d37968a
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/pdc.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Xqt"
+ ]
+ },
+ "replacetext_noreplacement": "Ken Blatt gfunne mit „$1“.",
+ "replacetext_continue": "Weider"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/pl.json b/www/wiki/extensions/ReplaceText/i18n/pl.json
new file mode 100644
index 00000000..4e7571fe
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/pl.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ankry",
+ "Chrumps",
+ "Derbeth",
+ "Leinad",
+ "Maikking",
+ "Matma Rex",
+ "Odder",
+ "Reedy",
+ "Sp5uhe",
+ "ToSter",
+ "WTM"
+ ]
+ },
+ "replacetext": "Zastąp tekst",
+ "replacetext-desc": "Dodaje [[Special:ReplaceText|stronę specjalną]], pozwalającą administratorom na wyszukanie i zamianę zadanego tekstu w treści wszystkich stron wiki",
+ "replacetext_docu": "Możesz zastąpić jeden ciąg znaków innym, w treści wszystkich normalnych stron tej wiki. W tym celu wprowadź tutaj dwa fragmenty tekstu i naciśnij „{{int:replacetext_continue}}”. Zostanie pokazana lista stron, które zawierają wyszukiwany tekst. Będziesz {{GENDER:|mógł|mogła}} wybrać te strony, na których chcesz ten tekst zamienić na nowy. W historii zmian pojawi się Twoja nazwa użytkownika.",
+ "replacetext_originaltext": "Wyszukiwany tekst",
+ "replacetext_replacementtext": "Zamień na",
+ "replacetext_useregex": "Użyj wyrażeń regularnych",
+ "replacetext_regexdocu": "(Przykładowo: wstawiając „a(.*)c” w polu „{{int:replacetext_originaltext}}” oraz „ac$1” w polu „{{int:replacetext_replacementtext}}” spowodujesz zastąpienie „abc” przez „acb”.)",
+ "replacetext_optionalfilters": "Dodatkowe filtry:",
+ "replacetext_categorysearch": "Zamień tylko w kategorii",
+ "replacetext_prefixsearch": "Zamień tylko na stronach z prefiksem",
+ "replacetext_editpages": "Zastąp tekst w treści stron",
+ "replacetext_movepages": "Jeśli to możliwe wykonaj zastępowanie również w tytułach stron",
+ "replacetext_givetarget": "Musisz podać łańcuch znaków, który ma zostać zastąpiony.",
+ "replacetext_nonamespace": "Musisz wybrać co najmniej jedną przestrzeń nazw.",
+ "replacetext_editormove": "Musisz wybrać co najmniej jedną opcję zastępowania.",
+ "replacetext_choosepagesforedit": "Wybierz {{PLURAL:$3|stronę|strony}}, na których chcesz „$1” zastąpić „$2”",
+ "replacetext_choosepagesformove": "Zastąp „$1” tekstem „$2” w {{PLURAL:$3|tytule strony|tytułach następujących stron:}}",
+ "replacetext_cannotmove": "{{PLURAL:$1|Poniższa strona nie może zostać przeniesiona|Poniższe strony nie mogą zostać przeniesione}}:",
+ "replacetext_formovedpages": "Dla przeniesionych stron:",
+ "replacetext_savemovedpages": "Zapisz stare tytuły jako przekierowania do nowych",
+ "replacetext_watchmovedpages": "Obserwuj te strony",
+ "replacetext_invertselections": "Odwróć zaznaczenie",
+ "replacetext_replace": "Zastąp",
+ "replacetext_success": "„$1” zostanie zastąpiony przez „$2” na $3 {{PLURAL:$3|stronie|stronach}}.",
+ "replacetext_noreplacement": "Nie znaleziono stron zawierających tekst „$1”.",
+ "replacetext_nomove": "Nie znaleziono żadnych stron o tytule zawierającym „$1”.",
+ "replacetext_nosuchcategory": "Kategoria „$1” nie istnieje.",
+ "replacetext_return": "Powrót do formularza.",
+ "replacetext_warning": "'''Uwaga''' {{PLURAL:$1|Jest $1 strona zawierająca|Są $1 strony zawierające|Jest $1 stron zawierających}} tekst „$2”, którym chcesz zastępować. Jeśli wykonasz zastępowanie nie będzie możliwe odseparowanie Twoich zastąpień od tych tekstów.",
+ "replacetext_blankwarning": "Ponieważ ciąg znaków, którym ma być wykonane zastępowanie jest pusty, operacja będzie nieodwracalna. Czy kontynuować?",
+ "replacetext_continue": "Kontynuuj",
+ "replacetext_editsummary": "Zastępowanie tekstu - \"$1\" na \"$2\"",
+ "right-replacetext": "Wykonywanie zastępowania tekstu w całej wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/pms.json b/www/wiki/extensions/ReplaceText/i18n/pms.json
new file mode 100644
index 00000000..4d9de496
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/pms.json
@@ -0,0 +1,42 @@
+{
+ "@metadata": {
+ "authors": [
+ "Borichèt",
+ "Dragonòt"
+ ]
+ },
+ "replacetext": "Rimpiassa test",
+ "replacetext-desc": "A dà na [[Special:ReplaceText|pàgina special]] për përmëtte a j'aministrator ëd fé un sërca-e-rampiassa dë stringhe global su tute le pàgine ëd contnù ëd na wiki",
+ "replacetext_docu": "Për rampiassé na stringa ëd test con n'àutra dzora a tute le pàgine regolar dë sta wiki-sì, ch'a buta ij doi tòch ëd test ambelessì e peui ch'a sgnaca \"{{int:replacetext_continue}}\".\nA-j sarà alora mostrà na lista ëd pàgine ch'a conten-o ël test d'arserca, e a podrà serne cole andoa a veul rampiasselo.\nSò nòm a comparirà ant le stòrie dle pàgine com l'utent responsàbil ëd tute modìfiche.",
+ "replacetext_originaltext": "Test original:",
+ "replacetext_replacementtext": "Test ëd rimpiassadura:",
+ "replacetext_useregex": "Dovré dj'espression regolar",
+ "replacetext_regexdocu": "(Esempi: ij valor «a(.*)c» për «{{int:replacetext_originaltext}}» e «ac$1» për «{{int:replacetext_replacementtext}}» a rampiasso «abc» with «acb».)",
+ "replacetext_optionalfilters": "Filtr opsionaj:",
+ "replacetext_categorysearch": "Rimpiassa mach an categorìa:",
+ "replacetext_prefixsearch": "Rimpiassa mach an pàgine con ël prefiss:",
+ "replacetext_editpages": "Rimpiassa test ant ij contnù dla pàgina",
+ "replacetext_movepages": "Rimpiassa test ant ij tìtoj dla pàgina, quand possìbil",
+ "replacetext_givetarget": "It deve spessifiché la stringa da esse rimpiassà.",
+ "replacetext_nonamespace": "It deve spessifiché almanch në spassi nominal.",
+ "replacetext_editormove": "It deve selessioné almanch un-a dj'opsion ëd rampiass.",
+ "replacetext_choosepagesforedit": "Rimpiassa \"$1\" con \"$2\" ant ël test ëd {{PLURAL:$3|la pàgina|le pàgine}} sota:",
+ "replacetext_choosepagesformove": "Rimpiassa \"$1\" con \"$2\" ant {{PLURAL:$3|ël tìtol dla pàgina|ij tìtoj dle pàgine}} sota:",
+ "replacetext_cannotmove": "{{PLURAL:$1|La pàgina|Le pàgine}} sota a peulo pa esse tramudà:",
+ "replacetext_formovedpages": "Për le pàgine tramudà:",
+ "replacetext_savemovedpages": "Salva ël tìtol vej com ridiression al tìtol neuv",
+ "replacetext_watchmovedpages": "Ten d'euj ste pàgine-sì",
+ "replacetext_invertselections": "Anvert selession",
+ "replacetext_replace": "Rimpiassa",
+ "replacetext_success": "\"$1\" a sarà rimpiassà con \"$2\" an $3 {{PLURAL:$3|pàgina|pàgine}}.",
+ "replacetext_noreplacement": "Pa gnun-e pàgine trovà contenente la stringa \"$1\".",
+ "replacetext_nomove": "Pa gnun-e pàgine trovà con ij tìtoj contenent \"$1\".",
+ "replacetext_nosuchcategory": "A esisto gnun-e categorìe con ël nòm \"$1\".",
+ "replacetext_return": "Artorna al formolari.",
+ "replacetext_warning": "'''Atension:''' A-i {{PLURAL:$1|é $1 pàgina ch'a conten|son $1 pàgine ch'a conten-o}} già la stringa ëd rimpiassadura, \"$2\".\nS'it fas sta rimpiassadura-sì it saras pa bon a separé toe rimpiassadure da ste stringhe-sì.",
+ "replacetext_blankwarning": "Da già che la stringa ëd rimpiass a l'é veuida, st'operassion-sì a sarà pa reversìbil.\nVeul-lo continué?",
+ "replacetext_continue": "Continua",
+ "replacetext_editsummary": "Rimpiassadura test - \"$1\" a \"$2\"",
+ "right-replacetext": "Fà rimpiassadura dë stringhe an sl'antrega wiki",
+ "action-replacetext": "fé ij rampiass dë stringhe an sla wiki antrega"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/pnt.json b/www/wiki/extensions/ReplaceText/i18n/pnt.json
new file mode 100644
index 00000000..13aa094d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/pnt.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Omnipaedista"
+ ]
+ },
+ "replacetext_originaltext": "Πρωτότυπον κείμενον:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ps.json b/www/wiki/extensions/ReplaceText/i18n/ps.json
new file mode 100644
index 00000000..83ed3e17
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ps.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ahmed-Najib-Biabani-Ibrahimkhel"
+ ]
+ },
+ "replacetext": "متن ځايناستول",
+ "replacetext_originaltext": "آرنی متن:",
+ "replacetext_replacementtext": "د متن ځايناستوب:",
+ "replacetext_categorysearch": "يوازې په وېشنيزه کې ځايناستول:",
+ "replacetext_prefixsearch": "يوازې په مختاړي لرونکيو مخونو کې ځايناستول:",
+ "replacetext_editpages": "د مخ په مېنځپانگه کې متن ځايناستول",
+ "replacetext_movepages": "د شونتيا په وخت کې، د مخ د سرليک متن ځايناستول",
+ "replacetext_nonamespace": "تاسې بايد لږ تر لږه يو نوم-تشيال وټاکۍ.",
+ "replacetext_cannotmove": "دا {{PLURAL:$1|لاندې مخ|لانديني مخونه}} د لېږدولو وړ نه دي:",
+ "replacetext_formovedpages": "د لېږدل شويو مخونو لپاره:",
+ "replacetext_watchmovedpages": "همدا مخونه کتل",
+ "replacetext_invertselections": "ټاکنې سرچپه کول",
+ "replacetext_replace": "ځايناستول",
+ "replacetext_editsummary": "متن ځايناستول - له \"$1\" نه \"$2\" ته"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/pt-br.json b/www/wiki/extensions/ReplaceText/i18n/pt-br.json
new file mode 100644
index 00000000..d9fbc1ff
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/pt-br.json
@@ -0,0 +1,54 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cainamarques",
+ "Capmo",
+ "Crazymadlover",
+ "Eduardo.mps",
+ "Enqd",
+ "Giro720",
+ "Hamilton Abreu",
+ "Jaideraf",
+ "Luckas",
+ "Luckas Blade",
+ "555",
+ "Eduardo Addad de Oliveira"
+ ]
+ },
+ "replacetext": "Substituir texto",
+ "replacetext-desc": "Apresenta uma [[Special:ReplaceText|página especial]] que permite aos administradores fazer substituições globais de texto em todas as páginas de conteúdo de uma wiki",
+ "replacetext_docu": "Para substituir uma \"string\" de texto por outra em todas as páginas deste wiki, forneça o texto a ser substituído e o novo texto e clique no botão \"{{int:replacetext_continue}}\".\nSerá exibida uma lista de páginas que possuem o termo pesquisado. A partir dela, selecione em quais você deseja realizar substituições.\nSeu nome de usuário aparecerá nos históricos das páginas como o responsável por ter feito as alterações.",
+ "replacetext_originaltext": "Texto original:",
+ "replacetext_replacementtext": "Novo texto:",
+ "replacetext_useregex": "Usar expressões regulares",
+ "replacetext_regexdocu": "(Exemplo: os valores \"a(.*)c\" no \"{{int:replacetext_originaltext}}\" e \"ac$1\" em \"{{int:replacetext_replacementtext}}\" substituiriam \"abc\" por \"acb\")",
+ "replacetext_optionalfilters": "Filtros opcionais:",
+ "replacetext_categorysearch": "Substituir apenas na categoria:",
+ "replacetext_prefixsearch": "Substituir apenas em páginas com o prefixo:",
+ "replacetext_editpages": "Substituir texto no conteúdo da página",
+ "replacetext_movepages": "Substituir texto nos títulos das páginas, quando possível",
+ "replacetext_givetarget": "Você precisa especificar um texto para ser substituído.",
+ "replacetext_nonamespace": "Você precisa selecionar no mínimo um espaço nominal.",
+ "replacetext_editormove": "Você precisa selecionar no mínimo uma das opções de substituição.",
+ "replacetext_choosepagesforedit": "Substituir \"$1\" por \"$2\" no texto {{PLURAL:$3|da página|das páginas}} a seguir:",
+ "replacetext_choosepagesformove": "Substituir \"$1\" por \"$2\" {{PLURAL:$3|no nome da seguinte página|nos nomes das seguintes páginas}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|A seguinte página não pode ser movida|As seguintes páginas não podem ser movidas}}:",
+ "replacetext_formovedpages": "Para páginas movidas:",
+ "replacetext_savemovedpages": "Manter os títulos antigos como redirecionamentos para os novos títulos",
+ "replacetext_watchmovedpages": "Vigiar estas páginas",
+ "replacetext_invertselections": "Inverter seleções",
+ "replacetext_replace": "Substituir",
+ "replacetext_success": "\"$1\" será substituído por \"$2\" em $3 {{PLURAL:$3|página|páginas}}.",
+ "replacetext_noreplacement": "Não foram encontradas páginas que contenham a expressão \"$1\".",
+ "replacetext_nomove": "Não foram encontradas páginas cujo título contenha \"$1\".",
+ "replacetext_nosuchcategory": "Não existe nenhuma categoria com o nome \"$1\".",
+ "replacetext_return": "Voltar ao formulário.",
+ "replacetext_warning": "'''Aviso:''' Há {{PLURAL:$1|uma página que já contém|$1 páginas que já contêm}} a expressão de substituição, \"$2\". Se você prosseguir, não será possível distinguí-las das suas substituições, nem desfazer a operação com uma simples substituição em ordem inversa.",
+ "replacetext_blankwarning": "'''Aviso:''' Como o texto de substituição foi deixado em branco, esta operação não será reversível.",
+ "replacetext_continue": "Continuar",
+ "replacetext_announce": "Anunciar estas edições através da página $1 e das páginas vigiadas.",
+ "replacetext_editsummary": "Substituição de texto - \"$1\" por \"$2\"",
+ "right-replacetext": "Fazer substituições de texto em toda a wiki",
+ "action-replacetext": "executar substituições de cadeias de caracteres em toda a wiki",
+ "replacetext_reminder": "Para alterar também as páginas afluentes a esta, vá para $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/pt.json b/www/wiki/extensions/ReplaceText/i18n/pt.json
new file mode 100644
index 00000000..8ef32a16
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/pt.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Capmo",
+ "Crazymadlover",
+ "Hamilton Abreu",
+ "Lijealso",
+ "Luckas",
+ "Malafaya",
+ "Waldir",
+ "555",
+ "Macofe",
+ "Athena in Wonderland"
+ ]
+ },
+ "replacetext": "Substituir texto",
+ "replacetext-desc": "[[Special:ReplaceText|Página especial]] que permite que os administradores façam substituições globais de texto ''(string find-and-replace)'' em todas as páginas de conteúdo de uma wiki",
+ "replacetext_docu": "Para substituir um texto por outro texto em todas as páginas desta wiki, introduza os dois textos e clique o botão \"Prosseguir\".\nSerão listadas as páginas que contêm o texto a substituir e poderá selecionar em quais deseja proceder à substituição.\nO seu nome aparecerá no histórico dessas páginas como o utilizador responsável pelas alterações.",
+ "replacetext_originaltext": "Texto original:",
+ "replacetext_replacementtext": "Texto de substituição:",
+ "replacetext_useregex": "Usar expressões regulares",
+ "replacetext_regexdocu": "(Exemplo: os valores \"a(.*)c\" no \"Texto original\" e \"ac$1\" no \"Texto de substituição\" substituiriam \"abc\" por \"acb\")",
+ "replacetext_optionalfilters": "Filtros opcionais:",
+ "replacetext_categorysearch": "Substituir só na categoria:",
+ "replacetext_prefixsearch": "Substituir só em páginas com o prefixo:",
+ "replacetext_editpages": "Substituir texto no conteúdo da página",
+ "replacetext_movepages": "Substituir texto nos títulos de páginas, quando possível",
+ "replacetext_givetarget": "Deve especificar o texto que será substituído.",
+ "replacetext_nonamespace": "Deverá selecionar pelo menos um espaço nominal.",
+ "replacetext_editormove": "Deve selecionar pelo menos uma das opções de substituição.",
+ "replacetext_choosepagesforedit": "Substituir \"$1\" por \"$2\" no texto {{PLURAL:$3|da seguinte página|das seguintes páginas}}:",
+ "replacetext_choosepagesformove": "Substituir \"$1\" por \"$2\" {{PLURAL:$3|no título da seguinte página|nos títulos das seguintes páginas}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|A seguinte página não pode ser movida|As seguintes páginas não podem ser movidas}}:",
+ "replacetext_formovedpages": "Para páginas movidas:",
+ "replacetext_savemovedpages": "Gravar os títulos anteriores como redirecionamentos para os novos títulos",
+ "replacetext_watchmovedpages": "Vigiar estas páginas",
+ "replacetext_invertselections": "Inverter seleções",
+ "replacetext_replace": "Substituir",
+ "replacetext_success": "'$1' será substituído por '$2' em $3 {{PLURAL:$3|página|páginas}}.",
+ "replacetext_noreplacement": "Não foram encontradas páginas que contenham o texto \"$1\".",
+ "replacetext_nomove": "Não foram encontradas páginas cujo título contenha \"$1\".",
+ "replacetext_nosuchcategory": "Não existe nenhuma categoria com o nome \"$1\".",
+ "replacetext_return": "Voltar ao formulário.",
+ "replacetext_warning": "'''Aviso:''' Há {{PLURAL:$1|uma página que já contém|$1 páginas que já contêm}} o texto de substituição, \"$2\". Se fizer esta substituição não poderá distingui-las das suas substituições, nem desfazer a operação com uma simples substituição em ordem inversa.",
+ "replacetext_blankwarning": "'''Aviso:''' Como o texto de substituição foi deixado em branco, esta operação não será reversível.",
+ "replacetext_continue": "Prosseguir",
+ "replacetext_announce": "Anunciar estas edições através da página $1 e das páginas vigiadas.",
+ "replacetext_editsummary": "Substituição de texto - \"$1\" por \"$2\"",
+ "right-replacetext": "Fazer substituições de texto em toda a wiki",
+ "action-replacetext": "fazer substituições de texto em toda a wiki",
+ "replacetext_reminder": "Para alterar também as ligações para esta página nas páginas afluentes, vá a $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/qqq.json b/www/wiki/extensions/ReplaceText/i18n/qqq.json
new file mode 100644
index 00000000..d9d62450
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/qqq.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Darth Kule",
+ "EugeneZelenko",
+ "Fryed-peach",
+ "Kghbln",
+ "Kwj2772",
+ "McMonster",
+ "Nike",
+ "Purodha",
+ "Shirayuki",
+ "Umherirrender"
+ ]
+ },
+ "replacetext": "{{doc-special|ReplaceText}}",
+ "replacetext-desc": "{{desc|name=Replace Text|url=https://www.mediawiki.org/wiki/Extension:Replace_Text}}\n{{Identical|Content page}}",
+ "replacetext_docu": "Description of how to use this extension, displayed on the extension's special page ([[Special:ReplaceText]]).\n\nRefers to {{msg-mw|Replacetext continue}}.",
+ "replacetext_originaltext": "Label of the text field, where user enters original piece of text, which would be replaced.",
+ "replacetext_replacementtext": "Used as table header on [[Special:ReplaceText]]",
+ "replacetext_useregex": "Used as label message of a checkbox on [[Special:ReplaceText]]",
+ "replacetext_regexdocu": "<code>$1</code> is not a parameter.\n\nRefers to the following messages:\n* {{msg-mw|Replacetext originaltext}}\n* {{msg-mw|Replacetext replacementtext}}",
+ "replacetext_optionalfilters": "Used as header on [[Special:ReplaceText]]",
+ "replacetext_categorysearch": "Used as label on [[Special:ReplaceText]]",
+ "replacetext_prefixsearch": "Used as label on [[Special:ReplaceText]]",
+ "replacetext_editpages": "Used as label message of a checkbox on [[Special:ReplaceText]]",
+ "replacetext_movepages": "Used as label message of a checkbox on [[Special:ReplaceText]]",
+ "replacetext_givetarget": "Used as error message on [[Special:ReplaceText]]",
+ "replacetext_nonamespace": "Used as error message on [[Special:ReplaceText]]",
+ "replacetext_editormove": "Used as error message on [[Special:ReplaceText]]",
+ "replacetext_choosepagesforedit": "Displayed over the list of pages where the given text was found. Parameters:\n* $1 - target code\n* $2 - replacement code\n* $3 - number of pages for edit",
+ "replacetext_choosepagesformove": "Used in [[Special:ReplaceText]].\n\nThis message is followed by list of the pages.\n\nParameters:\n* $1 - target string\n* $2 - replacement string\n* $3 - number of pages",
+ "replacetext_cannotmove": "Used in [[Special:ReplaceText]].\n\nThis message is followed by list of the pages.\n\nParameters:\n* $1 - number of pages which cannot be moved",
+ "replacetext_formovedpages": "Used as label on [[Special:ReplaceText]]",
+ "replacetext_savemovedpages": "Used as label of a checkbox on [[Special:ReplaceText]]",
+ "replacetext_watchmovedpages": "Used as label message of a checkbox on [[Special:ReplaceText]]",
+ "replacetext_invertselections": "{{Identical|Invert selection}}",
+ "replacetext_replace": "Label of the button, which triggers the begin of replacment.\n\n{{Identical|Replace}}",
+ "replacetext_success": "Used as success message in [[Special:ReplaceText]]. Parameters:\n* $1 - target string\n* $2 - replacement string\n* $3 - number of affected pages",
+ "replacetext_noreplacement": "Used in [[Special:ReplaceText]]. Parameters:\n* $1 - target string\nSee also:\n* {{msg-mw|Replacetext nomove}}",
+ "replacetext_nomove": "Used in [[Special:ReplaceText]]. Parameters:\n* $1 - target string\nSee also:\n* {{msg-mw|Replacetext noreplacement}}",
+ "replacetext_nosuchcategory": "Used in [[Special:ReplaceText]]. Parameters:\n* $1 - category name (with link)",
+ "replacetext_return": "Used as text of a link on [[Special:ReplaceText]]",
+ "replacetext_warning": "Used in [[Special:ReplaceText]]. Parameters:\n* $1 - number of pages\n* $2 - replacement string",
+ "replacetext_blankwarning": "Used as warning message on [[Special:ReplaceText]]",
+ "replacetext_continue": "{{Identical|Continue}}",
+ "replacetext_announce": "Used as a label for a checkbox on [[Special:ReplaceText]]",
+ "replacetext_editsummary": "Used as Edit Summary in [[Special:ReplaceText]]. Parameters:\n* $1 - target string\n* $2 - replacement string",
+ "right-replacetext": "{{doc-right|replacetext}}",
+ "action-replacetext": "{{doc-action|replacetext}}",
+ "replacetext_reminder": "Used at the end of success message in [[Special:MovePage]]. Parameters:\n* $1 - link to ReplaceText page"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ro.json b/www/wiki/extensions/ReplaceText/i18n/ro.json
new file mode 100644
index 00000000..15183e14
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ro.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Firilacroco",
+ "KlaudiuMihaila",
+ "Stelistcristi"
+ ]
+ },
+ "replacetext": "Înlocuiește text",
+ "replacetext_originaltext": "Text original:",
+ "replacetext_optionalfilters": "Filtre opționale:",
+ "replacetext_watchmovedpages": "Urmărește aceste pagini",
+ "replacetext_invertselections": "Inversează selecțiile",
+ "replacetext_replace": "Înlocuire",
+ "replacetext_nomove": "Nu a fost găsită nici o pagină al cărei titlu să conțină '$1'.",
+ "replacetext_return": "Revenire la formular.",
+ "replacetext_continue": "Continuare",
+ "replacetext_editsummary": "Înlocuire de text - '$1' în '$2'"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/roa-tara.json b/www/wiki/extensions/ReplaceText/i18n/roa-tara.json
new file mode 100644
index 00000000..dbf4d396
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/roa-tara.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras"
+ ]
+ },
+ "replacetext": "Sostituisce 'u teste",
+ "replacetext_originaltext": "Teste origgenale:",
+ "replacetext_replacementtext": "Teste da sostituì:",
+ "replacetext_useregex": "Ause le espressiune regolare",
+ "replacetext_watchmovedpages": "Vide ste pàggene",
+ "replacetext_invertselections": "Selezione a smerse",
+ "replacetext_replace": "Sostituisce",
+ "replacetext_success": "\"$1\" avène sostituite cu \"$2\" jndr'à {{PLURAL:$3|'na pàgene|$3 pàggene}}.",
+ "replacetext_return": "Tuèrne a 'u module.",
+ "replacetext_continue": "Condinue",
+ "replacetext_editsummary": "Sostituzione d'u teste - \"$1\" cu \"$2\"",
+ "right-replacetext": "Fà 'a sostituzione de le stringhe sus a totte a uicchi"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ru.json b/www/wiki/extensions/ReplaceText/i18n/ru.json
new file mode 100644
index 00000000..3859932c
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ru.json
@@ -0,0 +1,53 @@
+{
+ "@metadata": {
+ "authors": [
+ "AlexSm",
+ "Ferrer",
+ "Kaganer",
+ "Kv75",
+ "Normalex",
+ "Okras",
+ "Rubin",
+ "Rubin16",
+ "Александр Сигачёв",
+ "Mouse21",
+ "Happy13241"
+ ]
+ },
+ "replacetext": "Заменить текст",
+ "replacetext-desc": "Добавляет [[Special:ReplaceText|служебную страницу]], позволяющую администраторам осуществлять повсеместную замену указанного текста на всех обычных страницах вики",
+ "replacetext_docu": "Для того, чтобы заменить одну строку на другую на всех страницах вики, вам необходимо ввести здесь желаемый текст и нажать на кнопку «{{int:replacetext_continue}}». После этого вам будет предложен список всех страниц, содержащих заменяемый текст, и вы сможете выбрать из них те, в которых нужно произвести замены. В качестве лица, отвечающего за внесённые изменения, в истории правок страниц, в которых произойдёт замена текста, будете указаны вы.",
+ "replacetext_originaltext": "Исходный текст:",
+ "replacetext_replacementtext": "Текст для замены:",
+ "replacetext_useregex": "Использовать регулярные выражения",
+ "replacetext_regexdocu": "(Например, выражения «a(.*)c» в поле «{{int:replacetext_originaltext}}» и «ac$1» в поле «{{int:replacetext_replacementtext}}» приведут к замене «abc» на «acb».)",
+ "replacetext_optionalfilters": "Необязательные фильтры:",
+ "replacetext_categorysearch": "Заменить только в категории:",
+ "replacetext_prefixsearch": "Заменить только в страницах с приставкой:",
+ "replacetext_editpages": "Замена текста в содержимом страниц",
+ "replacetext_movepages": "Заменить текст в названиях страниц, если это возможно",
+ "replacetext_givetarget": "Вы должны указать строку, которую нужно заменить.",
+ "replacetext_nonamespace": "Вы должны выбрать по крайней мере одно пространство имён.",
+ "replacetext_editormove": "Вы должны выбрать по крайней мере, один из вариантов замены.",
+ "replacetext_choosepagesforedit": "Пожалуйста, выберите {{PLURAL:$3|1=страницу, в которой|страницы, в которых}} вы хотите осуществить замену «$1» на «$2»:",
+ "replacetext_choosepagesformove": "Заменить «$1» на «$2» в {{PLURAL:$3|1=названии следующей страницы|названиях следующих страниц}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|1=Следующая страница не может быть переименована|Следующие страницы не могут быть переименованы}}:",
+ "replacetext_formovedpages": "Для переименованных страниц:",
+ "replacetext_savemovedpages": "Сохранить старые названия как перенаправления на новые",
+ "replacetext_watchmovedpages": "Включить эти страницы в список наблюдения",
+ "replacetext_invertselections": "Инвертировать выбор",
+ "replacetext_replace": "Заменить",
+ "replacetext_success": "«$1» будет заменён на «$2» на $3 {{PLURAL:$3|странице|страницах}}.",
+ "replacetext_noreplacement": "Не найдено ни одной страницы, содержащей «$1».",
+ "replacetext_nomove": "Не удалось найти страницы, заголовок которых содержит «$1».",
+ "replacetext_nosuchcategory": "Не существует категории с именем «$1».",
+ "replacetext_return": "Вернуться к форме.",
+ "replacetext_warning": "'''Внимание.''' Найдена {{PLURAL:$1|$1 страница, содержащая|$1 страницы, содержащие|$1 страниц, содержащих}} текст для замены, «$2». Если вы продолжите операцию замены, то не сможете отделить уже существующие записи от тех, которые появятся после замены.",
+ "replacetext_blankwarning": "Из-за того, что текст для замены пуст, операция по замене не сможет быть отменена.\nВы хотите продолжить?",
+ "replacetext_continue": "Продолжить",
+ "replacetext_announce": "Объявите об этих изменениях через $1 и контрольные списки",
+ "replacetext_editsummary": "Замена текста — «$1» на «$2»",
+ "right-replacetext": "выполнение замен текста во всей вики",
+ "action-replacetext": "замену строк по всему проекту",
+ "replacetext_reminder": "Чтобы изменить ссылки на эту страницу на других страницах, перейдите к $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/si.json b/www/wiki/extensions/ReplaceText/i18n/si.json
new file mode 100644
index 00000000..a5c879d1
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/si.json
@@ -0,0 +1,18 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "replacetext": "පෙළ ප්‍රතිස්ථාපනය කරන්න",
+ "replacetext_originaltext": "මුල් පෙළ:",
+ "replacetext_replacementtext": "ප්‍රතිස්ථාපන පෙළ:",
+ "replacetext_optionalfilters": "අමතර පෙරහන්:",
+ "replacetext_formovedpages": "ගෙනගිය පිටු සඳහා:",
+ "replacetext_watchmovedpages": "මෙම පිටු මුර කරන්න",
+ "replacetext_invertselections": "තෝරාගැනුම් යටිකුරු කරන්න",
+ "replacetext_replace": "ප්‍රතිස්ථාපනය",
+ "replacetext_return": "නැවතත් ආකෘතිපත්‍රයට.",
+ "replacetext_continue": "ඉදිරියට යන්න",
+ "replacetext_editsummary": "පෙළ ප්‍රතිස්ථාපනය - \"$1\" වෙත \"$2\""
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/sk.json b/www/wiki/extensions/ReplaceText/i18n/sk.json
new file mode 100644
index 00000000..42d3b0f4
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/sk.json
@@ -0,0 +1,41 @@
+{
+ "@metadata": {
+ "authors": [
+ "Helix84",
+ "Teslaton"
+ ]
+ },
+ "replacetext": "Nahradiť text",
+ "replacetext-desc": "Poskytuje [[Special:ReplaceText|špeciálnu stránku]], ktorá správcom umožňuje globálne nájsť a nahradiť text na všetkých stránkach celej wiki.",
+ "replacetext_docu": "Nájsť text na všetkých stránkach tejto wiki a nahradiť ho iným textom môžete tak, že sem napíšete texty a stlačíte „Pokračovať”. Potom sa vám zobrazí zoznam stránok obsahujúcich hľadaný text a môžete si zvoliť tie, na ktorých ho chcete nahradiť. V histórii úprav sa zaznamená vaše meno.",
+ "replacetext_originaltext": "Pôvodný text:",
+ "replacetext_replacementtext": "Nahradiť textom:",
+ "replacetext_useregex": "Použiť regulárne výrazy",
+ "replacetext_regexdocu": "(Príklad: výraz „a(.*)c“ pre „Pôvodný text“ a „ac$1“ pre „Nahradiť textom“ nahradí „abc“ textom „acb“.)",
+ "replacetext_optionalfilters": "Nepovinné filtre:",
+ "replacetext_categorysearch": "Nahradiť iba v kategórii:",
+ "replacetext_prefixsearch": "Nahradiť iba v stránkach s predponou:",
+ "replacetext_editpages": "Nahradiť text v obsahu stránok",
+ "replacetext_movepages": "Nahradiť text v názvoch stránok, keď je to možné",
+ "replacetext_givetarget": "Musíte zadať reťazec, ktorý sa má nahradiť.",
+ "replacetext_nonamespace": "Musíte vybrať aspoň jeden menný priestor.",
+ "replacetext_editormove": "Musíte vybrať aspoň jednu z volieb nahrádzania.",
+ "replacetext_choosepagesforedit": "Prosím, vyberte {{PLURAL:$3|stránku, na ktorej|stránky, na ktorých}} chcete nahradiť „$1“ za „$2“:",
+ "replacetext_choosepagesformove": "Nahradiť text „$1“ textom „$2“ v {{PLURAL:$3|názve nasledovnej stránky|názvoch nasledovných stránok}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Nasledovnú stránku|Nasledovné stránky}} nemožno presunúť:",
+ "replacetext_formovedpages": "Pri presunutých stránkach:",
+ "replacetext_savemovedpages": "Ukladať staré názvy ako presmerovania na nové názvy",
+ "replacetext_watchmovedpages": "Sledovať tieto stránky",
+ "replacetext_invertselections": "Invertovať výber",
+ "replacetext_replace": "Nahradiť",
+ "replacetext_success": "Text „$1” bude nahradený textom „$2” na $3 {{PLURAL:$3|stránke|stránkach}}.",
+ "replacetext_noreplacement": "Nenašli sa žiadne stránky obsahujúce text „$1”.",
+ "replacetext_nomove": "Neboli nájdené žiadne stránky, ktorých názov obsahuje „$1“.",
+ "replacetext_nosuchcategory": "Žiadna kategória s názvom „$1“ neexistuje.",
+ "replacetext_return": "Späť na formulár.",
+ "replacetext_warning": "'''Upozornenie:''' $1 {{PLURAL:$1|stránka|stránky|stránok}} už obsahuje text „$2”, ktorým chcete pôvodný text nahradiť. Ak budete pokračovať a text nahradíte, nebudete môcť odlíšiť vaše nahradenia od existujúceho textu, ktorý tento reťazec už obsahuje.",
+ "replacetext_blankwarning": "Pretože text, ktorým text chcete nahradiť je prázdny, operácia bude nevratná. Pokračovať?",
+ "replacetext_continue": "Pokračovať",
+ "replacetext_editsummary": "Nahradenie textu „$1” textom „$2”",
+ "right-replacetext": "Vykonať náhradu reťazcov na celej wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/sr-ec.json b/www/wiki/extensions/ReplaceText/i18n/sr-ec.json
new file mode 100644
index 00000000..df6dabbb
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/sr-ec.json
@@ -0,0 +1,36 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01",
+ "Rancher",
+ "Sasa Stefanovic",
+ "Жељко Тодоровић",
+ "Михајло Анђелковић",
+ "Сербијана"
+ ]
+ },
+ "replacetext": "Замена текста",
+ "replacetext_originaltext": "Изворни текст:",
+ "replacetext_replacementtext": "Нови текст:",
+ "replacetext_optionalfilters": "Необавезни филтери:",
+ "replacetext_categorysearch": "Замени само у категорији:",
+ "replacetext_editpages": "Замени текст у садржају странице",
+ "replacetext_movepages": "Замени текст у насловима страница, када је могуће",
+ "replacetext_givetarget": "Морате навести ниску коју желите да замените.",
+ "replacetext_nonamespace": "Морате изабрати барем један именски простор.",
+ "replacetext_editormove": "Морате изабрати барем једну од могућности за замену.",
+ "replacetext_choosepagesforedit": "Замени „$1“ са „$2“ у тексту {{PLURAL:$3|следеће странице|следећих $3 страница}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Следећа страница не може бити премештена|Следеће странице не могу бити премештене}}:",
+ "replacetext_formovedpages": "За премештене странице:",
+ "replacetext_savemovedpages": "Сачувај старе наслове као преусмерења ка новим насловима",
+ "replacetext_watchmovedpages": "Надгледај ове стране",
+ "replacetext_invertselections": "Обрни избор",
+ "replacetext_replace": "Замени",
+ "replacetext_success": "„$1“ ће бити замењено са „$2“ у $3 {{PLURAL:$3|страни|страна}}.",
+ "replacetext_noreplacement": "Није нађена ниједна страница која садржи стринг '$1'.",
+ "replacetext_nomove": "Није нађена ниједна страница чији наслов садржи „$1“.",
+ "replacetext_return": "Назад на образац.",
+ "replacetext_continue": "Настави",
+ "replacetext_editsummary": "Замена текста — „$1” у „$2”",
+ "right-replacetext": "замењивање ниски на целом викију"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/sr-el.json b/www/wiki/extensions/ReplaceText/i18n/sr-el.json
new file mode 100644
index 00000000..33b5fa0e
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/sr-el.json
@@ -0,0 +1,34 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michaello",
+ "Milicevic01",
+ "Rancher",
+ "Жељко Тодоровић"
+ ]
+ },
+ "replacetext": "Zamena teksta",
+ "replacetext_originaltext": "Izvorni tekst:",
+ "replacetext_replacementtext": "Novi tekst:",
+ "replacetext_optionalfilters": "Neobavezni filteri:",
+ "replacetext_categorysearch": "Zameni samo u kategoriji:",
+ "replacetext_editpages": "Zameni tekst u sadržaju stranice",
+ "replacetext_movepages": "Zameni tekst u naslovima stranica, kada je moguće",
+ "replacetext_givetarget": "Morate navesti nisku koju želite da zamenite.",
+ "replacetext_nonamespace": "Morate izabrati barem jedan imenski prostor.",
+ "replacetext_editormove": "Morate izabrati barem jednu od mogućnosti za zamenu.",
+ "replacetext_choosepagesforedit": "Zameni „$1“ sa „$2“ u tekstu {{PLURAL:$3|sledeće stranice|sledećih $3 stranica}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Sledeća stranica ne može biti premeštena|Sledeće stranice ne mogu biti premeštene}}:",
+ "replacetext_formovedpages": "Za premeštene stranice:",
+ "replacetext_savemovedpages": "Sačuvaj stare naslove kao preusmerenja ka novim naslovima",
+ "replacetext_watchmovedpages": "Nadgledaj ove strane",
+ "replacetext_invertselections": "Obrni izbor",
+ "replacetext_replace": "Zameni",
+ "replacetext_success": "„$1“ će biti zamenjeno sa „$2“ u $3 {{PLURAL:$3|strani|strana}}.",
+ "replacetext_noreplacement": "Nije nađena nijedna stranica koja sadrži string '$1'.",
+ "replacetext_nomove": "Nije nađena nijedna stranica čiji naslov sadrži „$1“.",
+ "replacetext_return": "Nazad na obrazac.",
+ "replacetext_continue": "Nastavi",
+ "replacetext_editsummary": "Zamena teksta - '$1' u '$2'",
+ "right-replacetext": "zamenjivanje niski na celom vikiju"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/sv.json b/www/wiki/extensions/ReplaceText/i18n/sv.json
new file mode 100644
index 00000000..bd2780bc
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/sv.json
@@ -0,0 +1,50 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cybjit",
+ "Fluff",
+ "M.M.S.",
+ "Martinwiss",
+ "Najami",
+ "Per",
+ "Rotsee",
+ "WikiPhoenix"
+ ]
+ },
+ "replacetext": "Ersätt text",
+ "replacetext-desc": "Låter administratörer [[Special:ReplaceText|ersätta text]] på alla innehållssidor på en wiki",
+ "replacetext_docu": "För att ersätta en textsträng med en annan på alla vanliga sidor i den här wikin, skriv in de två texterna här och klicka på \"{{int:replacetext_continue}}\".\nDu kommer sedan att visas på en lista över sidor som innehåller söktexten, där du kan välja de som du vill ersätta i.\nDitt namn kommer visas i sidhistoriken som den som är ansvarig för ändringarna.",
+ "replacetext_originaltext": "Originaltext:",
+ "replacetext_replacementtext": "Ersättningstext:",
+ "replacetext_useregex": "Använd reguljära uttryck",
+ "replacetext_regexdocu": "(T.ex: värden på \"a(.*)c\" för \"{{int:replacetext_originaltext}}\" och \"ac$1\" för \"{{int:replacetext_replacementtext}}\" skulle ersätta \"abc\" med \"acb\".)",
+ "replacetext_optionalfilters": "Valbara filter:",
+ "replacetext_categorysearch": "Ersätt endast i kategori:",
+ "replacetext_prefixsearch": "Ersätt endast sidor med prefixet:",
+ "replacetext_editpages": "Ersätt text i sidinnehåll",
+ "replacetext_movepages": "Ersätt text i sidtitlar när det är möjligt",
+ "replacetext_givetarget": "Du måste ange en textsträng som ska ersättas.",
+ "replacetext_nonamespace": "Du måste ange minst en namnrymd.",
+ "replacetext_editormove": "Du måste ange minst ett alternativ för ersättning.",
+ "replacetext_choosepagesforedit": "Var god ange för {{PLURAL:$3|vilken sida|vilka sidor}} du vill ersätta '$1' med '$2':",
+ "replacetext_choosepagesformove": "Ersätt '$1' med '$2' i {{PLURAL:$3|namnet på den följande sidan|namnen på de följande sidorna}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Den följande sidan|De följande sidorna}} kan inte flyttas:",
+ "replacetext_formovedpages": "För flyttade sidor:",
+ "replacetext_savemovedpages": "Spara de gamla artikeltitlarna som omdirigeringar till de nya",
+ "replacetext_watchmovedpages": "Bevaka de här sidorna",
+ "replacetext_invertselections": "Invertera val",
+ "replacetext_replace": "Ersätt",
+ "replacetext_success": "'$1' kommer att ersättas med '$2' på $3 {{PLURAL:$3|sida|sidor}}.",
+ "replacetext_noreplacement": "Inga sidor hittades med strängen \"$1\".",
+ "replacetext_nomove": "Inga sidor hittades som innehåller \"$1\" i titeln.",
+ "replacetext_nosuchcategory": "Det finns inte någon kategori med namnet \"$1\".",
+ "replacetext_return": "Tillbaka till formuläret.",
+ "replacetext_warning": "'''Varning:''' Det finns {{PLURAL:$1|$1 sida|$1 sidor}} som redan har ersättningssträngen \"$2\". Om du gör den här ersättningen kommer du inte kunna separera dina ersättningar från den här texten.",
+ "replacetext_blankwarning": "Eftersom ersättningstexten är tom kommer den här handlingen inte kunna upphävas; vill du fortsätta?",
+ "replacetext_continue": "Fortsätt",
+ "replacetext_announce": "Meddela dessa redigeringar via $1 och bevakningslistor",
+ "replacetext_editsummary": "Textersättning - \"$1\" till \"$2\"",
+ "right-replacetext": "Genomför textersättningar på hela wikin",
+ "action-replacetext": "genomför textersättningar på hela wikin",
+ "replacetext_reminder": "För att även ändra länkar till denna sida på andra sidor, gå till $1."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/sw.json b/www/wiki/extensions/ReplaceText/i18n/sw.json
new file mode 100644
index 00000000..c821aff4
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/sw.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Stephenwanjau"
+ ]
+ },
+ "replacetext_continue": "Endelea"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ta.json b/www/wiki/extensions/ReplaceText/i18n/ta.json
new file mode 100644
index 00000000..30c4c5b0
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ta.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Shanmugamp7"
+ ]
+ },
+ "replacetext_originaltext": "மூலவுரை:",
+ "replacetext_replacementtext": "மாற்றப்பட வேண்டிய உரை:",
+ "replacetext_watchmovedpages": "இந்தப் பக்கங்களை கவனிக்கவும்",
+ "replacetext_replace": "மாற்றுக",
+ "replacetext_continue": "தொடரவும்"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/te.json b/www/wiki/extensions/ReplaceText/i18n/te.json
new file mode 100644
index 00000000..c4c1b737
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/te.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "Veeven"
+ ]
+ },
+ "replacetext_originaltext": "అసలు పాఠ్యం:",
+ "replacetext_replacementtext": "మార్పిడి పాఠ్యం:",
+ "replacetext_optionalfilters": "ఐచ్చిక వడపోతలు:",
+ "replacetext_cannotmove": "ఈ {{PLURAL:$1|పేజీని|$1 పేజీలను}} తరలించలేరు:",
+ "replacetext_continue": "కొనసాగించు"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/th.json b/www/wiki/extensions/ReplaceText/i18n/th.json
new file mode 100644
index 00000000..00a1afeb
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/th.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ans",
+ "Passawuth"
+ ]
+ },
+ "replacetext_originaltext": "ข้อความดั้งเดิม:"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/tl.json b/www/wiki/extensions/ReplaceText/i18n/tl.json
new file mode 100644
index 00000000..fae00350
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/tl.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "AnakngAraw"
+ ]
+ },
+ "replacetext": "Palitan ang teksto",
+ "replacetext-desc": "Nagbibigay ng isang [[Special:ReplaceText|natatanging pahina]] upang mapahintulutan ang mga tagapangasiwa na makagawa ng isang baging na pandaidigang hanapin-at-palitan sa ibabaw ng lahat ng mga pahina ng nilalaman ng isang wiki",
+ "replacetext_docu": "Upang mapalitan ang isang bagting ng teksto ng iba pang nasa kahabaan ng lahat ng pangkaraniwang mga pahinang nasa ibabaw ng wiking ito, ipasok ang dalawang piraso ng teksto dito at pindutin pagkatapos ang \"{{int:replacetext_continue}}\". Susunod na ipapakita naman sa iyo ang isang talaan ng mga pahinang naglalaman ng teksto ng paghanap, at mapipili mo ang mga maaari mong ipamalit dito. Lilitaw ang pangalan mo sa mga kasaysayan ng pahina bilang tagagamit na umaako sa anumang mga pagbabago.",
+ "replacetext_originaltext": "Orihinal na teksto:",
+ "replacetext_replacementtext": "Pamalit na teksto:",
+ "replacetext_useregex": "Gumamit ng pangkaraniwang mga paglalahad",
+ "replacetext_regexdocu": "(Halimbawa: mga halaga ng isang \"a(.*) c\" para sa \"{{int:replacetext_originaltext}}\" at \"ac$1\" para sa \"{{int:replacetext_replacementtext}}\" na papalitan ang \"abc\" ng \"acb\".)",
+ "replacetext_optionalfilters": "Mga pansalang maaaring wala:",
+ "replacetext_categorysearch": "Palitan lamang sa loob ng kategorya:",
+ "replacetext_prefixsearch": "Palitan lamang sa loob ng mga pahina may unlapi:",
+ "replacetext_editpages": "Palitan ang teksto sa loob ng mga nilalaman ng pahina",
+ "replacetext_movepages": "Palitan ang tekstong nasa loob ng mga pamagat na pampahina, kapag maaari",
+ "replacetext_givetarget": "Dapat mong tukuyin ang bagting na papalitan.",
+ "replacetext_nonamespace": "Dapat kang pumili ng kahit na isang puwang na pampangalan.",
+ "replacetext_editormove": "Dapat kang pumili ng kahit na isa sa mga mapipiling pagpapalit.",
+ "replacetext_choosepagesforedit": "Pakipili ang {{PLURAL:$3|pahina|mga pahina}} kung saan mo naisa na palitan ang '$1' ng '$2':",
+ "replacetext_choosepagesformove": "Palitan ang \"$1\" ng \"$2\" sa loob ng {{PLURAL:$3|pangalan ng sumusunod na pahina|mga pangalan ng sumusunod na mga pahina}}:",
+ "replacetext_cannotmove": "Hindi maililipat ang sumusunod na {{PLURAL:$1|pahina|mga pahina}}:",
+ "replacetext_formovedpages": "Para sa mga pahinang inilipat:",
+ "replacetext_savemovedpages": "Sagipin ang lumang mga pamagat bilang mga pampunta patungo sa bagong mga pamagat",
+ "replacetext_watchmovedpages": "Bantayan ang mga pahinang ito",
+ "replacetext_invertselections": "Baligtarin ang mga pagpipilian",
+ "replacetext_replace": "Palitan",
+ "replacetext_success": "Ang '$1' ay mapapalitan ng '$2' sa loob ng $3 {{PLURAL:$3|pahina|mga pahina}}.",
+ "replacetext_noreplacement": "Walang natagpuang mga pahinang naglalaman ng bagting na '$1'.",
+ "replacetext_nomove": "Walang natagpuang mga pahina na naglalaman ang pamagat ng \"$1\".",
+ "replacetext_nosuchcategory": "Walang kategoryang umiiral na may pangalang \"$1\".",
+ "replacetext_return": "Bumalik sa pormularyo.",
+ "replacetext_warning": "'''Babala:''' Mayroong {{PLURAL:$1|$1 pahinang naglalaman na|$1 mga pahinang naglalaman na}} ng pamalit na bagting, '$2'.\nKapag ginawa mo ang pagpapalit na ito hindi mo na maihihiwalay ang mga pamalit mo mula sa mga bagting na ito.",
+ "replacetext_blankwarning": "Dahil sa walang laman ang bagting ng pamalit, hindi na maibabalik pa sa dati ang gawaing ito/\nNaisa mo bang magpatuloy pa?",
+ "replacetext_continue": "Magpatuloy",
+ "replacetext_editsummary": "Palitan ang tekso - '$1' papunta sa '$2'",
+ "right-replacetext": "Gumawa ng pagpapalit ng bagting sa buong wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/tr.json b/www/wiki/extensions/ReplaceText/i18n/tr.json
new file mode 100644
index 00000000..e02dd2bc
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/tr.json
@@ -0,0 +1,39 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joseph",
+ "Vito Genovese"
+ ]
+ },
+ "replacetext": "Metni değiştir",
+ "replacetext-desc": "Yöneticilere, bir vikideki tüm içerik sayfalarında bir küresel dizi bul-ve-değiştir yapmalarına izin veren bir [[Special:ReplaceText|özel sayfa]] sağlar",
+ "replacetext_docu": "Bu viki üzerindeki tüm sayfalarda bir metin dizgisini diğer bir dizgi ile değiştirmek için, iki metin parçasını girin ve 'Devam' seçeneğini seçin.\nSonrasında size arama metnini gösteren sayfaların bir listesi gösterilecek ve değiştirmek istediklerinizi seçebileceksiniz.\nAdınız, değişiklikleri gerçekleştiren kullanıcı olarak sayfa geçmişlerinde görülecek.",
+ "replacetext_originaltext": "Orijinal metin:",
+ "replacetext_replacementtext": "Yerine konulacak metin:",
+ "replacetext_optionalfilters": "Opsiyonel filtreler",
+ "replacetext_categorysearch": "Sadece kategoride değiştir:",
+ "replacetext_prefixsearch": "Sadece şu öneke sahip sayfalarda değiştir:",
+ "replacetext_editpages": "Sayfa içeriklerindeki metinleri değiştir",
+ "replacetext_movepages": "Sayfa başlıklarında metni değiştir, mümkün olduğunda",
+ "replacetext_givetarget": "Değiştirilecek dizgiyi belirtmelisiniz.",
+ "replacetext_nonamespace": "En az bir ad alanı seçmelisiniz.",
+ "replacetext_editormove": "Değiştirme seçeneklerinden en az birini seçmelisiniz.",
+ "replacetext_choosepagesforedit": "Lütfen, '$1' yerine '$2' koymak istediğiniz {{PLURAL:$3|sayfayı|sayfaları}} seçin:",
+ "replacetext_choosepagesformove": "Aşağıdaki {{PLURAL:$3|sayfanın adındaki|sayfaların adlarındaki}} \"$1\" bölümünü \"$2\" ile değiştir:",
+ "replacetext_cannotmove": "Aşağıdaki {{PLURAL:$1|sayfa|sayfalar}} taşınamaz:",
+ "replacetext_formovedpages": "Taşınan sayfalar için:",
+ "replacetext_savemovedpages": "Eski başlıkları yeni başlıklara yönlendirmeler olarak sakla",
+ "replacetext_watchmovedpages": "Bu sayfaları izle",
+ "replacetext_invertselections": "Seçimleri ters çevir",
+ "replacetext_replace": "Değiştir",
+ "replacetext_success": "$3 {{PLURAL:$3|sayfada|sayfada}} \"$1\" ile \"$2\" değiştirildi.",
+ "replacetext_noreplacement": "\"$1\" dizgisini içeren herhangi bir sayfa bulunamadı.",
+ "replacetext_nomove": "\"$1\" ibaresini içeren isimli sayfa bulunamadı.",
+ "replacetext_nosuchcategory": "\"$1\" adında bir kategori mevcut değil.",
+ "replacetext_return": "Forma dön.",
+ "replacetext_warning": "\"$2\" değiştirme dizgisini halihazırda içeren {{PLURAL:$1|$1 sayfa|$1 sayfa}} mevcut.\nBu değişikliği yaparsanız değişikliklerinizi bu dizgilerden ayırma imkanınız olmayacak.\nDeğiştirme işlemine devam etmek ister misiniz?",
+ "replacetext_blankwarning": "Değiştirme dizgisi boş olduğu için bu işlem geri alınamayacak.\nDevam etmek istiyor musunuz?",
+ "replacetext_continue": "Devam",
+ "replacetext_editsummary": "Metin değiştir - \"$1\" yerine \"$2\"",
+ "right-replacetext": "Vikinin tamamında dizgileri değiştirir"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/tt-cyrl.json b/www/wiki/extensions/ReplaceText/i18n/tt-cyrl.json
new file mode 100644
index 00000000..0e197b80
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/tt-cyrl.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ильнар"
+ ]
+ },
+ "replacetext_continue": "Дәвам итү"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/uk.json b/www/wiki/extensions/ReplaceText/i18n/uk.json
new file mode 100644
index 00000000..6b11ad89
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/uk.json
@@ -0,0 +1,46 @@
+{
+ "@metadata": {
+ "authors": [
+ "AS",
+ "Andriykopanytsia",
+ "Base",
+ "Prima klasy4na",
+ "Ата",
+ "Ahonc"
+ ]
+ },
+ "replacetext": "Заміна тексту",
+ "replacetext-desc": "Додає [[Special:ReplaceText|спеціальну сторінку]], що дозволяє адміністраторам робити глобальну заміну зазначеного тексту на всіх звичайних сторінках вікі",
+ "replacetext_docu": "Щоб замінити один текст на інший на всіх сторінках вікі, введіть тут два фрагменти тексту і натисніть \"{{int:replacetext_continue}}\".\nПісля цього Вам буде запропоновано список всіх сторінок, що містять замінюваний текст, і Ви зможете вибрати ті, в яких потрібно виконати заміни. \nВаше ім'я буде вказано біля змін в історії редагувань сторінок.",
+ "replacetext_originaltext": "Оригінальний текст:",
+ "replacetext_replacementtext": "Замінити на:",
+ "replacetext_useregex": "Використовувати регулярні вирази",
+ "replacetext_regexdocu": "(Наприклад: вирази «a(.*)c» у полі «{{int:replacetext_originaltext}}» і «ac$1» у полі «{{int:replacetext_replacementtext}}» призведе до заміни «abc» на «acb».)",
+ "replacetext_optionalfilters": "Додаткові фільтри:",
+ "replacetext_categorysearch": "Замінити тільки в категорії:",
+ "replacetext_prefixsearch": "Замінити тільки на сторінках, чиї назви починаються на:",
+ "replacetext_editpages": "Заміна тексту у вмісті сторінки",
+ "replacetext_movepages": "Замінити текст у назвах сторінок, якщо можливо",
+ "replacetext_givetarget": "Ви повинні вказати рядок, який потрібно замінити.",
+ "replacetext_nonamespace": "Ви повинні вибрати принаймні один простір назв.",
+ "replacetext_editormove": "Ви повинні вибрати принаймні один варіант заміни.",
+ "replacetext_choosepagesforedit": "Будь ласка, виберіть {{PLURAL:$3|1=сторінку, в якій|сторінки, в яких}} ви хочете здійснити заміну «$1» на «$2»:",
+ "replacetext_choosepagesformove": "Замінити «$1» на «$2» в {{PLURAL:$3|1=назві наступної сторінки|назвах наступних сторінок}}:",
+ "replacetext_cannotmove": "{{PLURAL:$1|1=Наступна сторінка не може бути перейменована|Наступні сторінки не можуть бути перейменовані}}:",
+ "replacetext_formovedpages": "Для перейменованих сторінок:",
+ "replacetext_savemovedpages": "Зберегти старі назви як перенаправлення на нові",
+ "replacetext_watchmovedpages": "Спостерігати за цими сторінками",
+ "replacetext_invertselections": "Інвертувати виділення",
+ "replacetext_replace": "Замінити",
+ "replacetext_success": "«$1» буде замінений на «$2» на $3 {{PLURAL:$3|сторінці|сторінках|сторінках}}.",
+ "replacetext_noreplacement": "Не знайдено сторінок, що містять рядок «$1».",
+ "replacetext_nomove": "Не знайдено сторінок, назва яких містить «$1».",
+ "replacetext_nosuchcategory": "Не існує категорії з назвою «$1».",
+ "replacetext_return": "Повернутися до форми.",
+ "replacetext_warning": "'''Увага:''' Знайдено {{PLURAL:$1|$1 сторінку, що містить|$1 сторінки, що містять|$1 сторінок, що містять}} текст на який заміняти, «$2». Якщо Ви проведете цю заміну, то не зможете відділити Ваші заміни від тих рядків, що є вже.",
+ "replacetext_blankwarning": "'''Увага:''' Так, як текст для заміни порожній, операцію не можна буде скасувати.",
+ "replacetext_continue": "Продовжити",
+ "replacetext_editsummary": "Заміна тексту — „$1“ на „$2“",
+ "right-replacetext": "виконання заміни тексту по всій вікі",
+ "action-replacetext": "виконання замін тексту по всій вікі"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/ur.json b/www/wiki/extensions/ReplaceText/i18n/ur.json
new file mode 100644
index 00000000..71606ceb
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/ur.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද",
+ "Muhammad Shuaib"
+ ]
+ },
+ "replacetext_originaltext": "اصل متن:",
+ "replacetext_replacementtext": "متبادل متن:",
+ "replacetext_useregex": "ریگیولر ایکسپریشنز استعمال کریں",
+ "replacetext_optionalfilters": "اختیاری فلٹر:",
+ "replacetext_categorysearch": "محض اس زمرہ میں تبدیلی کریں:",
+ "replacetext_prefixsearch": "محض اس سابقہ والے صفحات میں تبدیلی کریں:",
+ "replacetext_editpages": "صفحہ کے مواد میں تبدیلی کریں",
+ "replacetext_movepages": "عناوین میں تبدیلی کریں اگر ممکن ہو",
+ "replacetext_watchmovedpages": "ان صفحات کو زیر نظر کریں",
+ "replacetext_invertselections": "انتخاب معکوس",
+ "replacetext_replace": "کو تبدیل",
+ "replacetext_continue": "جاری رکھیں"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/vep.json b/www/wiki/extensions/ReplaceText/i18n/vep.json
new file mode 100644
index 00000000..01fdf4b9
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/vep.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Игорь Бродский"
+ ]
+ },
+ "replacetext_originaltext": "Originaline tekst",
+ "replacetext_watchmovedpages": "Kacelta nened lehtpoled",
+ "replacetext_return": "Pörtas formannoks."
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/vi.json b/www/wiki/extensions/ReplaceText/i18n/vi.json
new file mode 100644
index 00000000..68228d78
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/vi.json
@@ -0,0 +1,44 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minh Nguyen",
+ "Tuankiet65",
+ "Vinhtantran",
+ "Trần Nguyễn Minh Huy"
+ ]
+ },
+ "replacetext": "Thay thế văn bản",
+ "replacetext-desc": "Cung cấp một [[Special:ReplaceText|trang đặc biệt]] để cho phép bảo quản viên thực hiện tìm-kiếm-và-thay-thế thống nhất trên tất cả các trang có nội dung tại một wiki",
+ "replacetext_docu": "Để thay thế một chuỗi ký tự bằng một chuỗi khác trên toàn bộ các trang thông thường tại wiki này, hãy gõ vào hai đoạn văn bản ở đây và sau đó nhấn “{{int:replacetext_continue}}”. Khi đó bạn thấy một danh sách các trang có chứa đoạn ký tự được tìm, và bạn có thể chọn những trang mà bạn muốn thay thế. Tên của bạn sẽ xuất hiện trong lịch sử trang như một thành viên chịu trách nhiệm về bất kỳ thay đổi nào.",
+ "replacetext_originaltext": "Văn bản gốc:",
+ "replacetext_replacementtext": "Văn bản thay thế:",
+ "replacetext_useregex": "Sử dụng biểu thức chính quy",
+ "replacetext_regexdocu": "(Ví dụ: Văn bản gốc “a(.*)c” và văn bản thay thế “ac$1” sẽ thay thế “abc” bằng “acb”.)",
+ "replacetext_optionalfilters": "Bộ lọc tùy ý:",
+ "replacetext_categorysearch": "Chỉ thay trong thể loại:",
+ "replacetext_prefixsearch": "Chỉ thay trong những trang với tiền tố:",
+ "replacetext_editpages": "Thay thế văn bản trong nội dung trang",
+ "replacetext_movepages": "Thay văn bản trong tên trang nếu có thể",
+ "replacetext_givetarget": "Bạn cần phải định rõ văn bản để thay thế.",
+ "replacetext_nonamespace": "Cần phải chọn ít nhất một không gian tên.",
+ "replacetext_editormove": "Bạn cần phải chọn ít nhất một trong những tùy chọn thay thế.",
+ "replacetext_choosepagesforedit": "Thay “$1” bằng “$2” trong nội dung của {{PLURAL:$3|trang|những trang}} sau:",
+ "replacetext_choosepagesformove": "Thay “$1” bằng “$2” trong tên của {{PLURAL:$3|trang|các trang}} sau:",
+ "replacetext_cannotmove": "Không thể di chuyển {{PLURAL:$1|trang|$1 trang}} sau:",
+ "replacetext_formovedpages": "Đối với trang đã di chuyển:",
+ "replacetext_savemovedpages": "Lưu các tên cũ để đổi hướng đến tên mới",
+ "replacetext_watchmovedpages": "Theo dõi các trang này",
+ "replacetext_invertselections": "Đảo ngược các lựa chọn",
+ "replacetext_replace": "Thay thế",
+ "replacetext_success": "“$1” sẽ được thay bằng “$2” trong $3 trang.",
+ "replacetext_noreplacement": "Không tìm thấy trang nào có chứa chuỗi ‘$1’.",
+ "replacetext_nomove": "Không tìm thấy trang nào với “$1” trong tên.",
+ "replacetext_nosuchcategory": "Không có thể loại với tên “$1”.",
+ "replacetext_return": "Trở lại biểu mẫu.",
+ "replacetext_warning": "'''Cảnh báo:''' {{PLURAL:$1|Một trang|$1 trang}} trong lựa chọn đã có chứa chuỗi thay thế, “$2”. Nếu bạn thực hiện thay thế này bạn sẽ không thể phân biệt sự thay thế của bạn với những chuỗi này.",
+ "replacetext_blankwarning": "Vì chuỗi thay thế là khoảng trắng, tác vụ này sẽ không thể hồi lại được; tiếp tục?",
+ "replacetext_continue": "Tiếp tục",
+ "replacetext_editsummary": "Thay thế văn bản – “$1” thành “$2”",
+ "right-replacetext": "Thay thế văn bản trên toàn wiki",
+ "action-replacetext": "thay thế văn bản trên toàn wiki"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/vo.json b/www/wiki/extensions/ReplaceText/i18n/vo.json
new file mode 100644
index 00000000..310b48f6
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/vo.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Malafaya",
+ "Smeira"
+ ]
+ },
+ "replacetext": "Plaädön vödemi",
+ "replacetext-desc": "Jafön [[Special:ReplaceText|padi patik]] ad mögükön guvanes sukami e plaädami valöpikis, ninädapadis valik vüka seimik tefölis.",
+ "replacetext_originaltext": "Rigavödem:",
+ "replacetext_replacementtext": "Plaädamavödem:",
+ "replacetext_movepages": "Plaädön vödemi i pö padatiäds, ven mögos",
+ "replacetext_choosepagesforedit": "Välolös {{PLURAL:$3|padi, su kel|padis, su kels}} vilol plaädön vödemi: „$1“ me vödem: „$2“:",
+ "replacetext_cannotmove": "{{PLURAL:$1|Pad|Pads}} fovik no kanons patopätükön:",
+ "replacetext_replace": "Plaädön",
+ "replacetext_success": "Vödem: „$1“ poplaädon dub vödem: „$2“ su {{PLURAL:$3|pad bal|pads $3}}.",
+ "replacetext_noreplacement": "Pads nonik labü vödem: „$1“ petuvons.",
+ "replacetext_blankwarning": "Bi plaädamavödem binon vägik, dun at no kanon pasädunön. Vilol-li fümiko ledunön plaädami?",
+ "replacetext_continue": "Ledunön",
+ "replacetext_editsummary": "Vödemiplaädam - „$1“ ad „$2“",
+ "right-replacetext": "Ledunön vödemiplaädami in vük lölik"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/zh-hans.json b/www/wiki/extensions/ReplaceText/i18n/zh-hans.json
new file mode 100644
index 00000000..f784386e
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/zh-hans.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Liangent",
+ "Onecountry",
+ "PhiLiP",
+ "Yfdyh000",
+ "Mywood",
+ "Impersonator 1",
+ "Liuxinyu970226"
+ ]
+ },
+ "replacetext": "替换文字",
+ "replacetext-desc": "提供[[Special:ReplaceText|特殊页面]]让管理员可以对wiki的所有页面内容执行查找和替换。",
+ "replacetext_docu": "要替换此wiki内所有页面文字的字串,请将“原文字”及“替换文字”分别填入以下两个栏位之中,然后按“{{int:replacetext_continue}}”。接下来会列出所有含原文字的页面供您选择在哪些页面进行替换。页面改动历史会显示您是进行此次改动的用户。",
+ "replacetext_originaltext": "原文字:",
+ "replacetext_replacementtext": "替换文字:",
+ "replacetext_useregex": "使用正则表达式",
+ "replacetext_regexdocu": "(例如:在“{{int:replacetext_originaltext}}”填入“a(.*)c”并在“{{int:replacetext_replacementtext}}”填入“ac$1”可以将“abc”替换为“acb”。)",
+ "replacetext_optionalfilters": "可选过滤器:",
+ "replacetext_categorysearch": "仅替换该分类中的页面:",
+ "replacetext_prefixsearch": "仅替换带该前缀页面:",
+ "replacetext_editpages": "仅在页面内容中替换",
+ "replacetext_movepages": "可能的话,在页面名称中替换",
+ "replacetext_givetarget": "必须指定查找的字符串。",
+ "replacetext_nonamespace": "您必须选择至少一个名字空间。",
+ "replacetext_editormove": "必须选择至少一个替换选项。",
+ "replacetext_choosepagesforedit": "在以下{{PLURAL:$3|页面}}的文本中,将“$1”替换成“$2”。",
+ "replacetext_choosepagesformove": "将{{PLURAL:$3|以下页面中标题|以下$3个页面中标题}}的“$1”替换为“$2”:",
+ "replacetext_cannotmove": "无法移动以下{{PLURAL:$1|页面|$1个页面}}:",
+ "replacetext_formovedpages": "对于移动的页面:",
+ "replacetext_savemovedpages": "保存旧标题,作为重定向至新标题",
+ "replacetext_watchmovedpages": "监视这些页面",
+ "replacetext_invertselections": "反选",
+ "replacetext_replace": "替换",
+ "replacetext_success": "在{{PLURAL:$3|$3个页面}}中,“$1”将被替换为“$2”。",
+ "replacetext_noreplacement": "找不到包含字符串“$1”的页面。",
+ "replacetext_nomove": "找不到标题包含“$1”的页面。",
+ "replacetext_nosuchcategory": "找不到名为“$1”的分类。",
+ "replacetext_return": "返回表格。",
+ "replacetext_warning": "'''警告:'''有{{PLURAL:$1|$1个页面已经包含}}替换字符串“$2”。如果您进行此次替换,您将无法从这些字符串中分离您的替换文字。",
+ "replacetext_blankwarning": "'''警告:'''因为替换字串为空,此次操作将不可逆。",
+ "replacetext_continue": "继续",
+ "replacetext_announce": "通过$1和监视列表通知这些编辑",
+ "replacetext_editsummary": "文本替换 - 替换“$1”为“$2”",
+ "right-replacetext": "在整个wiki进行字符串替换",
+ "action-replacetext": "在整个wiki进行字符串替换",
+ "replacetext_reminder": "要同时修改其他页面中链入此页面的链接,请前往$1。"
+}
diff --git a/www/wiki/extensions/ReplaceText/i18n/zh-hant.json b/www/wiki/extensions/ReplaceText/i18n/zh-hant.json
new file mode 100644
index 00000000..504c4408
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/i18n/zh-hant.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ch.Andrew",
+ "Cwlin0416",
+ "Justincheng12345",
+ "Mark85296341",
+ "Roc michael",
+ "Sheepy",
+ "Wrightbus",
+ "LNDDYL",
+ "Kly"
+ ]
+ },
+ "replacetext": "取代文字",
+ "replacetext-desc": "提供管理員可以對全站頁面內容進行搜尋及取代的 [[Special:ReplaceText|特殊頁面]]。",
+ "replacetext_docu": "要取代此 Wiki 內所有頁面的文字,請分別填入以下「原始文字」及「取代文字」兩個欄位,然後點選 \"{{int:replacetext_continue}}\"。\n接著會顯示所有包含搜尋文字的頁面,您可以選擇您要取代的頁面。\n您所做的任何變更會顯示在頁面的歷史記錄中以示負責。",
+ "replacetext_originaltext": "原始文字:",
+ "replacetext_replacementtext": "取代文字:",
+ "replacetext_useregex": "使用正則表示法",
+ "replacetext_regexdocu": "(例:在 \"{{int:replacetext_originaltext}}\" 中填入 \"a(.*)c\" 並在 \"{{int:replacetext_replacementtext}}\" 填入 \"ac$1\" 可將 \"abc\" 替換為 \"acb\"。)",
+ "replacetext_optionalfilters": "過濾條件選項:",
+ "replacetext_categorysearch": "僅取代頁面於分類:",
+ "replacetext_prefixsearch": "僅取代頁面含字首:",
+ "replacetext_editpages": "取代頁面內容中的文字",
+ "replacetext_movepages": "取代頁面標題的文字 (當可以時)",
+ "replacetext_givetarget": "您必須指定要被取代的字串。",
+ "replacetext_nonamespace": "您至少要選擇一個命名空間。",
+ "replacetext_editormove": "您至少要勾選一個取代選項。",
+ "replacetext_choosepagesforedit": "將下列{{PLURAL:$3|頁面|$3 個頁面}}內容中的 \"$1\" 取代為 \"$2\":",
+ "replacetext_choosepagesformove": "將下列{{PLURAL:$3|頁面|$3 個頁面}}標題中的 \"$1\" 取代為 \"$2\":",
+ "replacetext_cannotmove": "無法移動以下{{PLURAL:$1|頁面|$1 個頁面}}:",
+ "replacetext_formovedpages": "已移動頁面:",
+ "replacetext_savemovedpages": "建立舊標題重新導向頁面至新標題",
+ "replacetext_watchmovedpages": "監視這些頁面",
+ "replacetext_invertselections": "反向選擇",
+ "replacetext_replace": "取代",
+ "replacetext_success": "{{PLURAL:$3|1 個頁面|$3 個頁面}}中的 \"$1\" 將會被取代為 \"$2\"。",
+ "replacetext_noreplacement": "沒有任何頁面內容包含字串 \"$1\"。",
+ "replacetext_nomove": "沒有任何頁面標題包含字串 \"$1\"。",
+ "replacetext_nosuchcategory": "沒有任何分類名稱為 \"$1\"。",
+ "replacetext_return": "返回表單。",
+ "replacetext_warning": "'''警告:'''目前已有 $1 個頁面包含取代的字串 \"$2\",若您進行取代將無法區別原本存在的字串以及取代的字串。",
+ "replacetext_blankwarning": "'''警告:'''因取代的字串為空白,此操作將無法還原。",
+ "replacetext_continue": "繼續",
+ "replacetext_announce": "透過 Special:RecentChanges 與監視清單來通知這些編輯。",
+ "replacetext_editsummary": "文字取代 - \"$1\" 取代為 \"$2\"",
+ "right-replacetext": "對整個 Wiki 進行字串取代。",
+ "action-replacetext": "對整個 Wiki 進行字串取代。",
+ "replacetext_reminder": "要同時變動在其它頁面上連至此頁面的連結,請前往 $1。"
+}
diff --git a/www/wiki/extensions/ReplaceText/maintenance/replaceAll.php b/www/wiki/extensions/ReplaceText/maintenance/replaceAll.php
new file mode 100755
index 00000000..f1078bdc
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/maintenance/replaceAll.php
@@ -0,0 +1,408 @@
+#!/usr/bin/php
+<?php
+/**
+ * Insert jobs into the job queue to replace text bits.
+ * Or execute immediately... your choice.
+ *
+ * Copyright © 2014 NicheWork, LLC
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @category Maintenance
+ * @package ReplaceText
+ * @author Mark A. Hershberger <mah@nichework.com>
+ * @license http://www.gnu.org/copyleft/gpl.html GPL-2.0-or-later
+ * @link https://www.mediawiki.org/wiki/Extension:Replace_Text
+ *
+ */
+// @codingStandardsIgnoreStart
+$IP = getenv( "MW_INSTALL_PATH" ) ? getenv( "MW_INSTALL_PATH" ) : __DIR__ . "/../../..";
+if ( !is_readable( "$IP/maintenance/Maintenance.php" ) ) {
+ die( "MW_INSTALL_PATH needs to be set to your MediaWiki installation.\n" );
+}
+require_once ( "$IP/maintenance/Maintenance.php" );
+// @codingStandardsIgnoreEnd
+
+/**
+ * Maintenance script that replaces text in pages
+ *
+ * @ingroup Maintenance
+ * @SuppressWarnings(StaticAccess)
+ * @SuppressWarnings(LongVariable)
+ */
+class ReplaceAll extends Maintenance {
+ private $user;
+ private $target;
+ private $replacement;
+ private $namespaces;
+ private $category;
+ private $prefix;
+ private $useRegex;
+ private $titles;
+ private $defaultContinue;
+ private $doAnnounce;
+
+ public function __construct() {
+ parent::__construct();
+ $this->mDescription = "CLI utility to replace text wherever it is ".
+ "found in the wiki.";
+
+ $this->addArg( "target", "Target text to find.", false );
+ $this->addArg( "replace", "Text to replace.", false );
+
+ $this->addOption( "dry-run", "Only find the texts, don't replace.",
+ false, false, 'n' );
+ $this->addOption( "regex", "This is a regex (false).",
+ false, false, 'r' );
+ $this->addOption( "user", "The user to attribute this to (uid 1).",
+ false, true, 'u' );
+ $this->addOption( "yes", "Skip all prompts with an assumed 'yes'.",
+ false, false, 'y' );
+ $this->addOption( "summary", "Alternate edit summary. (%r is where to ".
+ " place the replacement text, %f the text to look for.)",
+ false, true, 's' );
+ $this->addOption( "nsall", "Search all canonical namespaces (false). " .
+ "If true, this option overrides the ns option.", false, false, 'a' );
+ $this->addOption( "ns", "Comma separated namespaces to search in " .
+ "(Main) .", false, true );
+ $this->addOption( "replacements", "File containing the list of " .
+ "replacements to be made. Fields in the file are tab-separated. " .
+ "See --show-file-format for more information.", false, true, "f" );
+ $this->addOption( "show-file-format", "Show a description of the " .
+ "file format to use with --replacements.", false, false );
+ $this->addOption( "no-announce", "Do not announce edits on Special:RecentChanges or " .
+ "watchlists.", false, false, "m" );
+ $this->addOption( "debug", "Display replacements being made.", false, false );
+ $this->addOption( "listns", "List out the namespaces on this wiki.",
+ false, false );
+
+ // MW 1.28
+ if ( method_exists( $this, 'requireExtension' ) ) {
+ $this->requireExtension( 'Replace Text' );
+ }
+ }
+
+ private function getUser() {
+ $userReplacing = $this->getOption( "user", 1 );
+
+ $user = is_numeric( $userReplacing ) ?
+ User::newFromId( $userReplacing ) :
+ User::newFromName( $userReplacing );
+
+ if ( get_class( $user ) !== 'User' ) {
+ $this->error(
+ "Couldn't translate '$userReplacing' to a user.", true
+ );
+ }
+
+ return $user;
+ }
+
+ private function getTarget() {
+ $ret = $this->getArg( 0 );
+ if ( !$ret ) {
+ $this->error( "You have to specify a target.", true );
+ }
+ return [ $ret ];
+ }
+
+ private function getReplacement() {
+ $ret = $this->getArg( 1 );
+ if ( !$ret ) {
+ $this->error( "You have to specify replacement text.", true );
+ }
+ return [ $ret ];
+ }
+
+ private function getReplacements() {
+ $file = $this->getOption( "replacements" );
+ if ( !$file ) {
+ return false;
+ }
+
+ if ( !is_readable( $file ) ) {
+ throw new MWException( "File does not exist or is not readable: "
+ . "$file\n" );
+ }
+
+ $handle = fopen( $file, "r" );
+ if ( $handle === false ) {
+ throw new MWException( "Trouble opening file: $file\n" );
+ return false;
+ }
+
+ $this->defaultContinue = true;
+ // @codingStandardsIgnoreStart
+ while ( ( $line = fgets( $handle ) ) !== false ) {
+ // @codingStandardsIgnoreEnd
+ $field = explode( "\t", substr( $line, 0, -1 ) );
+ if ( !isset( $field[1] ) ) {
+ continue;
+ }
+
+ $this->target[] = $field[0];
+ $this->replacement[] = $field[1];
+ $this->useRegex[] = isset( $field[2] ) ? true : false;
+ }
+ return true;
+ }
+
+ private function shouldContinueByDefault() {
+ if ( !is_bool( $this->defaultContinue ) ) {
+ $this->defaultContinue =
+ $this->getOption( "yes" ) ?
+ true :
+ false;
+ }
+ return $this->defaultContinue;
+ }
+
+ private function getSummary( $target, $replacement ) {
+ $msg = wfMessage( 'replacetext_editsummary', $target, $replacement )->
+ plain();
+ if ( $this->getOption( "summary" ) !== null ) {
+ $msg = str_replace( [ '%f', '%r' ],
+ [ $this->target, $this->replacement ],
+ $this->getOption( "summary" ) );
+ }
+ return $msg;
+ }
+
+ private function listNamespaces() {
+ echo "Index\tNamespace\n";
+ $nsList = MWNamespace::getCanonicalNamespaces();
+ ksort( $nsList );
+ foreach ( $nsList as $int => $val ) {
+ if ( $val == "" ) {
+ $val = "(main)";
+ }
+ echo " $int\t$val\n";
+ }
+ }
+
+ private function showFileFormat() {
+echo <<<EOF
+
+The format of the replacements file is tab separated with three fields.
+Any line that does not have a tab is ignored and can be considered a comment.
+
+Fields are:
+
+ 1. String to search for.
+ 2. String to replace found text with.
+ 3. (optional) The presence of this field indicates that the previous two
+ are considered a regular expression.
+
+Example:
+
+This is a comment
+TARGET REPLACE
+regex(p*) Count the Ps; \\1 true
+
+
+EOF;
+ }
+
+ private function getNamespaces() {
+ $nsall = $this->getOption( "nsall" );
+ $ns = $this->getOption( "ns" );
+ if ( !$nsall && !$ns ) {
+ $namespaces = [ NS_MAIN ];
+ } else {
+ $canonical = MWNamespace::getCanonicalNamespaces();
+ $canonical[NS_MAIN] = "_";
+ $namespaces = array_flip( $canonical );
+ if ( !$nsall ) {
+ $namespaces = array_map(
+ function ( $n ) use ( $canonical, $namespaces ) {
+ if ( is_numeric( $n ) ) {
+ if ( isset( $canonical[ $n ] ) ) {
+ return intval( $n );
+ }
+ } else {
+ if ( isset( $namespaces[ $n ] ) ) {
+ return $namespaces[ $n ];
+ }
+ }
+ return null;
+ }, explode( ",", $ns ) );
+ $namespaces = array_filter(
+ $namespaces,
+ function ( $val ) {
+ return $val !== null;
+ } );
+ }
+ }
+ return $namespaces;
+ }
+
+ private function getCategory() {
+ $cat = null;
+ return $cat;
+ }
+
+ private function getPrefix() {
+ $prefix = null;
+ return $prefix;
+ }
+
+ private function useRegex() {
+ return [ $this->getOption( "regex" ) ];
+ }
+
+ private function getTitles( $res ) {
+ if ( !$this->titles || count( $this->titles ) == 0 ) {
+ $this->titles = [];
+ foreach ( $res as $row ) {
+ $this->titles[] = Title::makeTitleSafe(
+ $row->page_namespace,
+ $row->page_title
+ );
+ }
+ }
+ return $this->titles;
+ }
+
+ private function listTitles( $res ) {
+ $ret = false;
+ foreach ( $this->getTitles( $res ) as $title ) {
+ $ret = true;
+ echo "$title\n";
+ }
+ return $ret;
+ }
+
+ private function replaceTitles( $res, $target, $replacement, $useRegex ) {
+ foreach ( $this->getTitles( $res ) as $title ) {
+ $param = [
+ 'target_str' => $target,
+ 'replacement_str' => $replacement,
+ 'use_regex' => $useRegex,
+ 'user_id' => $this->user->getId(),
+ 'edit_summary' => $this->getSummary( $target, $replacement ),
+ 'doAnnounce' => $this->doAnnounce
+ ];
+ echo "Replacing on $title... ";
+ $job = new ReplaceTextJob( $title, $param );
+ if ( $job->run() !== true ) {
+ $this->error( "Trouble on the page '$title'." );
+ }
+ echo "done.\n";
+ }
+ }
+
+ private function getReply( $question ) {
+ $reply = "";
+ if ( $this->shouldContinueByDefault() ) {
+ return true;
+ }
+ while ( $reply !== "y" && $reply !== "n" ) {
+ $reply = $this->readconsole( "$question (Y/N) " );
+ $reply = substr( strtolower( $reply ), 0, 1 );
+ }
+ return $reply === "y";
+ }
+
+ private function localSetup() {
+ if ( $this->getOption( "listns" ) ) {
+ $this->listNamespaces();
+ return false;
+ }
+ if ( $this->getOption( "show-file-format" ) ) {
+ $this->showFileFormat();
+ return false;
+ }
+ $this->user = $this->getUser();
+ if ( ! $this->getReplacements() ) {
+ $this->target = $this->getTarget();
+ $this->replacement = $this->getReplacement();
+ $this->useRegex = $this->useRegex();
+ }
+ $this->namespaces = $this->getNamespaces();
+ $this->category = $this->getCategory();
+ $this->prefix = $this->getPrefix();
+ return true;
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function execute() {
+ global $wgShowExceptionDetails;
+ $wgShowExceptionDetails = true;
+
+ $this->doAnnounce = true;
+ if ( $this->localSetup() ) {
+ if ( $this->namespaces === [] ) {
+ $this->error( "No matching namespaces.", true );
+ }
+
+ foreach ( array_keys( $this->target ) as $index ) {
+ $target = $this->target[$index];
+ $replacement = $this->replacement[$index];
+ $useRegex = $this->useRegex[$index];
+
+ if ( $this->getOption( "debug" ) ) {
+ echo "Replacing '$target' with '$replacement'";
+ if ( $useRegex ) {
+ echo " as regular expression.";
+ }
+ echo "\n";
+ }
+ $res = ReplaceTextSearch::doSearchQuery( $target,
+ $this->namespaces, $this->category, $this->prefix,
+ $useRegex );
+
+ if ( $res->numRows() === 0 ) {
+ $this->error( "No targets found to replace.", true );
+ }
+ if ( $this->getOption( "dry-run" ) ) {
+ $this->listTitles( $res );
+ return;
+ }
+ if ( !$this->shouldContinueByDefault() &&
+ $this->listTitles( $res ) ) {
+ if ( !$this->getReply(
+ "Replace instances on these pages?"
+ ) ) {
+ return;
+ }
+ }
+ $comment = "";
+ if ( $this->getOption( "user", null ) === null ) {
+ $comment = " (Use --user to override)";
+ }
+ if ( $this->getOption( "no-announce", false ) ) {
+ $this->doAnnounce = false;
+ }
+ if ( !$this->getReply(
+ "Attribute changes to the user '{$this->user}'?$comment"
+ ) ) {
+ return;
+ }
+ if ( $res->numRows() > 0 ) {
+ $this->replaceTitles(
+ $res, $target, $replacement, $useRegex
+ );
+ }
+ }
+ }
+ }
+}
+
+$maintClass = "ReplaceAll";
+require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/www/wiki/extensions/ReplaceText/replaceAll.php b/www/wiki/extensions/ReplaceText/replaceAll.php
new file mode 100755
index 00000000..1f08a032
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/replaceAll.php
@@ -0,0 +1,32 @@
+#!/usr/bin/php
+<?php
+/**
+ * Backwards-compatibility before the file was renamed
+ *
+ * Copyright © 2014 NicheWork, LLC
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @category Maintenance
+ * @package ReplaceText
+ * @author Mark A. Hershberger <mah@nichework.com>
+ * @license http://www.gnu.org/copyleft/gpl.html GPL-2.0-or-later
+ * @link https://www.mediawiki.org/wiki/Extension:Replace_Text
+ *
+ */
+
+require_once __DIR__ . '/maintenance/replaceAll.php';
diff --git a/www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.css b/www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.css
new file mode 100644
index 00000000..085f5e71
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.css
@@ -0,0 +1,3 @@
+.client-nojs .mw-replacetext-invert {
+ display: none;
+}
diff --git a/www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.js b/www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.js
new file mode 100644
index 00000000..a73a7b49
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/resources/ext.ReplaceText.js
@@ -0,0 +1,27 @@
+window.invertSelections = function () {
+ 'use strict';
+
+ var form = document.getElementById( 'choose_pages' ),
+ numElements = form.elements.length,
+ i,
+ curElement;
+
+ for ( i = 0; i < numElements; i++ ) {
+ curElement = form.elements[ i ];
+
+ if ( curElement.type === 'checkbox' && curElement.id !== 'create-redirect' &&
+ curElement.id !== 'watch-pages' && curElement.id !== 'doAnnounce' ) {
+ form.elements[ i ].checked = form.elements[ i ].checked !== true;
+ }
+ }
+};
+
+( function ( $ ) {
+ $( function () {
+ $( '#replacetext-invert' )
+ .on( 'click', function () {
+ window.invertSelections();
+ } )
+ .prop( 'disabled', false );
+ } );
+}( jQuery ) );
diff --git a/www/wiki/extensions/ReplaceText/src/ReplaceTextHooks.php b/www/wiki/extensions/ReplaceText/src/ReplaceTextHooks.php
new file mode 100644
index 00000000..84452dc1
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/src/ReplaceTextHooks.php
@@ -0,0 +1,73 @@
+<?php
+/**
+ * Hook functions for the Replace Text extension.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+class ReplaceTextHooks {
+
+ /**
+ * Implements AdminLinks hook from Extension:Admin_Links.
+ *
+ * @param ALTree &$adminLinksTree
+ * @return bool
+ */
+ public static function addToAdminLinks( ALTree &$adminLinksTree ) {
+ $generalSection = $adminLinksTree->getSection( wfMessage( 'adminlinks_general' )->text() );
+ $extensionsRow = $generalSection->getRow( 'extensions' );
+
+ if ( is_null( $extensionsRow ) ) {
+ $extensionsRow = new ALRow( 'extensions' );
+ $generalSection->addRow( $extensionsRow );
+ }
+
+ $extensionsRow->addItem( ALItem::newFromSpecialPage( 'ReplaceText' ) );
+
+ return true;
+ }
+
+ /**
+ * Implements SpecialMovepageAfterMove hook.
+ *
+ * Adds a link to the Special:ReplaceText page at the end of a successful
+ * regular page move message.
+ *
+ * @param MovePageForm &$form
+ * @param Title &$ot Title object of the old article (moved from)
+ * @param Title &$nt Title object of the new article (moved to)
+ */
+ public static function replaceTextReminder( &$form, &$ot, &$nt ) {
+ $out = $form->getOutput();
+ $page = SpecialPageFactory::getPage( 'ReplaceText' );
+ $pageLink = ReplaceTextUtils::link( $page->getPageTitle() );
+ $out->addHTML( $form->msg( 'replacetext_reminder' )
+ ->rawParams( $pageLink )->inContentLanguage()->parseAsBlock() );
+ }
+
+ /**
+ * Implements UserGetReservedNames hook.
+ * @param array &$names
+ */
+ public static function getReservedNames( &$names ) {
+ global $wgReplaceTextUser;
+ if ( !is_null( $wgReplaceTextUser ) ) {
+ $names[] = $wgReplaceTextUser;
+ }
+ }
+}
diff --git a/www/wiki/extensions/ReplaceText/src/ReplaceTextJob.php b/www/wiki/extensions/ReplaceText/src/ReplaceTextJob.php
new file mode 100644
index 00000000..281fdb04
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/src/ReplaceTextJob.php
@@ -0,0 +1,136 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ * @author Yaron Koren
+ * @author Ankit Garg
+ */
+
+use Wikimedia\ScopedCallback;
+
+/**
+ * Background job to replace text in a given page
+ * - based on /includes/RefreshLinksJob.php
+ */
+class ReplaceTextJob extends Job {
+ /**
+ * Constructor.
+ * @param Title $title
+ * @param array|bool $params Cannot be === true
+ */
+ function __construct( $title, $params = '' ) {
+ parent::__construct( 'replaceText', $title, $params );
+ }
+
+ /**
+ * Run a replaceText job
+ * @return bool success
+ */
+ function run() {
+ if ( isset( $this->params['session'] ) ) {
+ $callback = RequestContext::importScopedSession( $this->params['session'] );
+ $this->addTeardownCallback( function () use ( &$callback ) {
+ ScopedCallback::consume( $callback );
+ } );
+ }
+
+ if ( is_null( $this->title ) ) {
+ $this->error = "replaceText: Invalid title";
+ return false;
+ }
+
+ if ( array_key_exists( 'move_page', $this->params ) ) {
+ global $wgUser;
+ $actual_user = $wgUser;
+ $wgUser = User::newFromId( $this->params['user_id'] );
+ $cur_page_name = $this->title->getText();
+ if ( $this->params['use_regex'] ) {
+ $new_page_name = preg_replace(
+ "/" . $this->params['target_str'] . "/Uu", $this->params['replacement_str'], $cur_page_name
+ );
+ } else {
+ $new_page_name =
+ str_replace( $this->params['target_str'], $this->params['replacement_str'], $cur_page_name );
+ }
+
+ $new_title = Title::newFromText( $new_page_name, $this->title->getNamespace() );
+ $reason = $this->params['edit_summary'];
+ $create_redirect = $this->params['create_redirect'];
+ $this->title->moveTo( $new_title, true, $reason, $create_redirect );
+ if ( $this->params['watch_page'] ) {
+ WatchAction::doWatch( $new_title, $wgUser );
+ }
+ $wgUser = $actual_user;
+ } else {
+ if ( $this->title->getContentModel() !== CONTENT_MODEL_WIKITEXT ) {
+ $this->error = 'replaceText: Wiki page "' .
+ $this->title->getPrefixedDBkey() . '" does not hold regular wikitext.';
+ return false;
+ }
+ $wikiPage = new WikiPage( $this->title );
+ // Is this check necessary?
+ if ( !$wikiPage ) {
+ $this->error =
+ 'replaceText: Wiki page not found for "' . $this->title->getPrefixedDBkey() . '."';
+ return false;
+ }
+ $wikiPageContent = $wikiPage->getContent();
+ if ( is_null( $wikiPageContent ) ) {
+ $this->error =
+ 'replaceText: No contents found for wiki page at "' . $this->title->getPrefixedDBkey() . '."';
+ return false;
+ }
+ $article_text = $wikiPageContent->getNativeData();
+
+ $target_str = $this->params['target_str'];
+ $replacement_str = $this->params['replacement_str'];
+ $num_matches = 0;
+
+ if ( $this->params['use_regex'] ) {
+ $new_text =
+ preg_replace( '/' . $target_str . '/Uu', $replacement_str, $article_text, -1, $num_matches );
+ } else {
+ $new_text = str_replace( $target_str, $replacement_str, $article_text, $num_matches );
+ }
+
+ // If there's at least one replacement, modify the page,
+ // using the passed-in edit summary.
+ if ( $num_matches > 0 ) {
+ // Change global $wgUser variable to the one
+ // specified by the job only for the extent of
+ // this replacement.
+ global $wgUser;
+ $actual_user = $wgUser;
+ $wgUser = User::newFromId( $this->params['user_id'] );
+ $edit_summary = $this->params['edit_summary'];
+ $flags = EDIT_MINOR;
+ if ( $wgUser->isAllowed( 'bot' ) ) {
+ $flags |= EDIT_FORCE_BOT;
+ }
+ if ( isset( $this->params['doAnnounce'] ) &&
+ !$this->params['doAnnounce'] ) {
+ $flags |= EDIT_SUPPRESS_RC;
+ # fixme log this action
+ }
+ $new_content = new WikitextContent( $new_text );
+ $wikiPage->doEditContent( $new_content, $edit_summary, $flags );
+ $wgUser = $actual_user;
+ }
+ }
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/ReplaceText/src/ReplaceTextSearch.php b/www/wiki/extensions/ReplaceText/src/ReplaceTextSearch.php
new file mode 100644
index 00000000..712210f6
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/src/ReplaceTextSearch.php
@@ -0,0 +1,111 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+use Wikimedia\Rdbms\Database;
+use Wikimedia\Rdbms\IResultWrapper;
+
+class ReplaceTextSearch {
+
+ /**
+ * @param string $search
+ * @param array $namespaces
+ * @param string $category
+ * @param string $prefix
+ * @param bool $use_regex
+ * @return IResultWrapper Resulting rows
+ */
+ public static function doSearchQuery(
+ $search, $namespaces, $category, $prefix, $use_regex = false
+ ) {
+ $dbr = wfGetDB( DB_REPLICA );
+ $tables = [ 'page', 'revision', 'text' ];
+ $vars = [ 'page_id', 'page_namespace', 'page_title', 'old_text' ];
+ if ( $use_regex ) {
+ $comparisonCond = self::regexCond( $dbr, 'old_text', $search );
+ } else {
+ $any = $dbr->anyString();
+ $comparisonCond = 'old_text ' . $dbr->buildLike( $any, $search, $any );
+ }
+ $conds = [
+ $comparisonCond,
+ 'page_namespace' => $namespaces,
+ 'rev_id = page_latest',
+ 'rev_text_id = old_id'
+ ];
+
+ self::categoryCondition( $category, $tables, $conds );
+ self::prefixCondition( $prefix, $conds );
+ $options = [
+ 'ORDER BY' => 'page_namespace, page_title',
+ // 250 seems like a reasonable limit for one screen.
+ // @TODO - should probably be a setting.
+ 'LIMIT' => 250
+ ];
+
+ return $dbr->select( $tables, $vars, $conds, __METHOD__, $options );
+ }
+
+ /**
+ * @param string $category
+ * @param array &$tables
+ * @param array &$conds
+ */
+ public static function categoryCondition( $category, &$tables, &$conds ) {
+ if ( strval( $category ) !== '' ) {
+ $category = Title::newFromText( $category )->getDbKey();
+ $tables[] = 'categorylinks';
+ $conds[] = 'page_id = cl_from';
+ $conds['cl_to'] = $category;
+ }
+ }
+
+ /**
+ * @param string $prefix
+ * @param array &$conds
+ */
+ public static function prefixCondition( $prefix, &$conds ) {
+ if ( strval( $prefix ) === '' ) {
+ return;
+ }
+
+ $dbr = wfGetDB( DB_REPLICA );
+ $title = Title::newFromText( $prefix );
+ if ( !is_null( $title ) ) {
+ $prefix = $title->getDbKey();
+ }
+ $any = $dbr->anyString();
+ $conds[] = 'page_title ' . $dbr->buildLike( $prefix, $any );
+ }
+
+ /**
+ * @param Database $dbr
+ * @param string $column
+ * @param string $regex
+ * @return string query condition for regex
+ */
+ public static function regexCond( $dbr, $column, $regex ) {
+ if ( $dbr->getType() == 'postgres' ) {
+ $op = '~';
+ } else {
+ $op = 'REGEXP';
+ }
+ return "$column $op " . $dbr->addQuotes( $regex );
+ }
+}
diff --git a/www/wiki/extensions/ReplaceText/src/ReplaceTextUtils.php b/www/wiki/extensions/ReplaceText/src/ReplaceTextUtils.php
new file mode 100644
index 00000000..796e366e
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/src/ReplaceTextUtils.php
@@ -0,0 +1,41 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+use \MediaWiki\MediaWikiServices;
+
+class ReplaceTextUtils {
+
+ /**
+ * Shim for compatibility
+ * @param Title $title to link to
+ * @param string $text to show
+ * @return string HTML for link
+ */
+ public static function link( Title $title, $text = null ) {
+ if ( method_exists( '\MediaWiki\MediaWikiServices', 'getLinkRenderer' ) ) {
+ $linkRenderer = MediaWikiServices::getInstance()->getLinkRenderer();
+ if ( class_exists( 'HtmlArmor' ) && !is_null( $text ) ) {
+ $text = new HtmlArmor( $text );
+ }
+ return $linkRenderer->makeLink( $title, $text );
+ };
+ return Linker::link( $title, $text );
+ }
+}
diff --git a/www/wiki/extensions/ReplaceText/src/SpecialReplaceText.php b/www/wiki/extensions/ReplaceText/src/SpecialReplaceText.php
new file mode 100644
index 00000000..74536679
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/src/SpecialReplaceText.php
@@ -0,0 +1,792 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * @file
+ */
+
+class SpecialReplaceText extends SpecialPage {
+ private $target;
+ private $replacement;
+ private $use_regex;
+ private $category;
+ private $prefix;
+ private $edit_pages;
+ private $move_pages;
+ private $selected_namespaces;
+ private $doAnnounce;
+
+ public function __construct() {
+ parent::__construct( 'ReplaceText', 'replacetext' );
+ }
+
+ /**
+ * @inheritDoc
+ */
+ public function doesWrites() {
+ return true;
+ }
+
+ /**
+ * @param null|string $query
+ */
+ function execute( $query ) {
+ global $wgCompressRevisions, $wgExternalStores;
+
+ if ( !$this->getUser()->isAllowed( 'replacetext' ) ) {
+ throw new PermissionsError( 'replacetext' );
+ }
+
+ // Replace Text can't be run with certain settings, due to the
+ // changes they make to the DB storage setup.
+ if ( $wgCompressRevisions ) {
+ $errorMsg = "Error: text replacements cannot be run if \$wgCompressRevisions is set to true.";
+ $this->getOutput()->addWikiText( "<div class=\"errorbox\">$errorMsg</div>" );
+ return;
+ }
+ if ( !empty( $wgExternalStores ) ) {
+ $errorMsg = "Error: text replacements cannot be run if \$wgExternalStores is non-empty.";
+ $this->getOutput()->addWikiText( "<div class=\"errorbox\">$errorMsg</div>" );
+ return;
+ }
+
+ $this->setHeaders();
+ $out = $this->getOutput();
+ if ( !is_null( $out->getResourceLoader()->getModule( 'mediawiki.special' ) ) ) {
+ $out->addModuleStyles( 'mediawiki.special' );
+ }
+ $this->doSpecialReplaceText();
+ }
+
+ /**
+ * @return array namespaces selected for search
+ */
+ function getSelectedNamespaces() {
+ $all_namespaces = SearchEngine::searchableNamespaces();
+ $selected_namespaces = [];
+ foreach ( $all_namespaces as $ns => $name ) {
+ if ( $this->getRequest()->getCheck( 'ns' . $ns ) ) {
+ $selected_namespaces[] = $ns;
+ }
+ }
+ return $selected_namespaces;
+ }
+
+ /**
+ * Do the actual display and logic of Special:ReplaceText.
+ */
+ function doSpecialReplaceText() {
+ $out = $this->getOutput();
+ $request = $this->getRequest();
+
+ $this->target = $request->getText( 'target' );
+ $this->replacement = $request->getText( 'replacement' );
+ $this->use_regex = $request->getBool( 'use_regex' );
+ $this->category = $request->getText( 'category' );
+ $this->prefix = $request->getText( 'prefix' );
+ $this->edit_pages = $request->getBool( 'edit_pages' );
+ $this->move_pages = $request->getBool( 'move_pages' );
+ $this->doAnnounce = $request->getBool( 'doAnnounce' );
+ $this->selected_namespaces = $this->getSelectedNamespaces();
+
+ if ( $request->getCheck( 'continue' ) && $this->target === '' ) {
+ $this->showForm( 'replacetext_givetarget' );
+ return;
+ }
+
+ if ( $request->getCheck( 'replace' ) ) {
+
+ // check for CSRF
+ $user = $this->getUser();
+ if ( !$user->matchEditToken( $request->getVal( 'token' ) ) ) {
+ $out->addWikiMsg( 'sessionfailure' );
+ return;
+ }
+
+ $jobs = $this->createJobsForTextReplacements();
+ JobQueueGroup::singleton()->push( $jobs );
+
+ $count = $this->getLanguage()->formatNum( count( $jobs ) );
+ $out->addWikiMsg(
+ 'replacetext_success',
+ "<code><nowiki>{$this->target}</nowiki></code>",
+ "<code><nowiki>{$this->replacement}</nowiki></code>",
+ $count
+ );
+
+ // Link back
+ $out->addHTML(
+ ReplaceTextUtils::link(
+ $this->getPageTitle(),
+ $this->msg( 'replacetext_return' )->escaped()
+ )
+ );
+ return;
+ }
+
+ if ( $request->getCheck( 'target' ) ) {
+ // check for CSRF
+ $user = $this->getUser();
+ if ( !$user->matchEditToken( $request->getVal( 'token' ) ) ) {
+ $out->addWikiMsg( 'sessionfailure' );
+ return;
+ }
+
+ // first, check that at least one namespace has been
+ // picked, and that either editing or moving pages
+ // has been selected
+ if ( count( $this->selected_namespaces ) == 0 ) {
+ $this->showForm( 'replacetext_nonamespace' );
+ return;
+ }
+ if ( ! $this->edit_pages && ! $this->move_pages ) {
+ $this->showForm( 'replacetext_editormove' );
+ return;
+ }
+
+ // If user is replacing text within pages...
+ $titles_for_edit = $titles_for_move = $unmoveable_titles = [];
+ if ( $this->edit_pages ) {
+ $titles_for_edit = $this->getTitlesForEditingWithContext();
+ }
+ if ( $this->move_pages ) {
+ list( $titles_for_move, $unmoveable_titles ) = $this->getTitlesForMoveAndUnmoveableTitles();
+ }
+
+ // If no results were found, check to see if a bad
+ // category name was entered.
+ if ( count( $titles_for_edit ) == 0 && count( $titles_for_move ) == 0 ) {
+ $bad_cat_name = false;
+
+ if ( !empty( $this->category ) ) {
+ $category_title = Title::makeTitleSafe( NS_CATEGORY, $this->category );
+ if ( !$category_title->exists() ) {
+ $bad_cat_name = true;
+ }
+ }
+
+ if ( $bad_cat_name ) {
+ $link = ReplaceTextUtils::link( $category_title,
+ htmlspecialchars( ucfirst( $this->category ) ) );
+ $out->addHTML(
+ $this->msg( 'replacetext_nosuchcategory' )->rawParams( $link )->escaped()
+ );
+ } else {
+ if ( $this->edit_pages ) {
+ $out->addWikiMsg(
+ 'replacetext_noreplacement', "<code><nowiki>{$this->target}</nowiki></code>"
+ );
+ }
+
+ if ( $this->move_pages ) {
+ $out->addWikiMsg( 'replacetext_nomove', "<code><nowiki>{$this->target}</nowiki></code>" );
+ }
+ }
+ // link back to starting form
+ $out->addHTML(
+ '<p>' .
+ ReplaceTextUtils::link(
+ $this->getPageTitle(),
+ $this->msg( 'replacetext_return' )->escaped() )
+ . '</p>'
+ );
+ } else {
+ $warning_msg = $this->getAnyWarningMessageBeforeReplace( $titles_for_edit, $titles_for_move );
+ if ( ! is_null( $warning_msg ) ) {
+ $out->addWikiText( "<div class=\"errorbox\">$warning_msg</div><br clear=\"both\" />" );
+ }
+
+ $this->pageListForm( $titles_for_edit, $titles_for_move, $unmoveable_titles );
+ }
+ return;
+ }
+
+ // If we're still here, show the starting form.
+ $this->showForm();
+ }
+
+ /**
+ * Returns the set of MediaWiki jobs that will do all the actual replacements.
+ *
+ * @return array jobs
+ */
+ function createJobsForTextReplacements() {
+ global $wgReplaceTextUser;
+
+ $replacement_params = [];
+ if ( $wgReplaceTextUser != null ) {
+ $user = User::newFromName( $wgReplaceTextUser );
+ } else {
+ $user = $this->getUser();
+ }
+
+ $replacement_params['user_id'] = $user->getId();
+ $replacement_params['target_str'] = $this->target;
+ $replacement_params['replacement_str'] = $this->replacement;
+ $replacement_params['use_regex'] = $this->use_regex;
+ $replacement_params['edit_summary'] = $this->msg(
+ 'replacetext_editsummary',
+ $this->target, $this->replacement
+ )->inContentLanguage()->plain();
+ $replacement_params['create_redirect'] = false;
+ $replacement_params['watch_page'] = false;
+ $replacement_params['doAnnounce'] = $this->doAnnounce;
+
+ $request = $this->getRequest();
+ foreach ( $request->getValues() as $key => $value ) {
+ if ( $key == 'create-redirect' && $value == '1' ) {
+ $replacement_params['create_redirect'] = true;
+ } elseif ( $key == 'watch-pages' && $value == '1' ) {
+ $replacement_params['watch_page'] = true;
+ }
+ }
+
+ $jobs = [];
+ foreach ( $request->getValues() as $key => $value ) {
+ if ( $value == '1' && $key !== 'replace' && $key !== 'use_regex' ) {
+ if ( strpos( $key, 'move-' ) !== false ) {
+ $title = Title::newFromID( substr( $key, 5 ) );
+ $replacement_params['move_page'] = true;
+ } else {
+ $title = Title::newFromID( $key );
+ }
+ if ( $title !== null ) {
+ $jobs[] = new ReplaceTextJob( $title, $replacement_params );
+ }
+ }
+ }
+
+ return $jobs;
+ }
+
+ /**
+ * Returns the set of Titles whose contents would be modified by this
+ * replacement, along with the "search context" string for each one.
+ *
+ * @return array The set of Titles and their search context strings
+ */
+ function getTitlesForEditingWithContext() {
+ $titles_for_edit = [];
+
+ $res = ReplaceTextSearch::doSearchQuery(
+ $this->target,
+ $this->selected_namespaces,
+ $this->category,
+ $this->prefix,
+ $this->use_regex
+ );
+
+ foreach ( $res as $row ) {
+ $title = Title::makeTitleSafe( $row->page_namespace, $row->page_title );
+ if ( $title == null ) {
+ continue;
+ }
+ $context = $this->extractContext( $row->old_text, $this->target, $this->use_regex );
+ $titles_for_edit[] = [ $title, $context ];
+ }
+
+ return $titles_for_edit;
+ }
+
+ /**
+ * Returns two lists: the set of titles that would be moved/renamed by
+ * the current text replacement, and the set of titles that would
+ * ordinarily be moved but are not moveable, due to permissions or any
+ * other reason.
+ *
+ * @return array
+ */
+ function getTitlesForMoveAndUnmoveableTitles() {
+ $titles_for_move = [];
+ $unmoveable_titles = [];
+
+ $res = $this->getMatchingTitles(
+ $this->target,
+ $this->selected_namespaces,
+ $this->category,
+ $this->prefix,
+ $this->use_regex
+ );
+
+ foreach ( $res as $row ) {
+ $title = Title::makeTitleSafe( $row->page_namespace, $row->page_title );
+ if ( $title == null ) {
+ continue;
+ }
+ // See if this move can happen.
+ $cur_page_name = str_replace( '_', ' ', $row->page_title );
+
+ if ( $this->use_regex ) {
+ $new_page_name =
+ preg_replace( "/" . $this->target . "/Uu", $this->replacement, $cur_page_name );
+ } else {
+ $new_page_name =
+ str_replace( $this->target, $this->replacement, $cur_page_name );
+ }
+
+ $new_title = Title::makeTitleSafe( $row->page_namespace, $new_page_name );
+ $err = $title->isValidMoveOperation( $new_title );
+
+ if ( $title->userCan( 'move' ) && !is_array( $err ) ) {
+ $titles_for_move[] = $title;
+ } else {
+ $unmoveable_titles[] = $title;
+ }
+ }
+
+ return [ $titles_for_move, $unmoveable_titles ];
+ }
+
+ /**
+ * Get the warning message if the replacement string is either blank
+ * or found elsewhere on the wiki (since undoing the replacement
+ * would be difficult in either case).
+ *
+ * @param array $titles_for_edit
+ * @param array $titles_for_move
+ * @return string|null Warning message, if any
+ */
+ function getAnyWarningMessageBeforeReplace( $titles_for_edit, $titles_for_move ) {
+ if ( $this->replacement === '' ) {
+ return $this->msg( 'replacetext_blankwarning' )->text();
+ } elseif ( $this->use_regex ) {
+ // If it's a regex, don't bother checking for existing
+ // pages - if the replacement string includes wildcards,
+ // it's a meaningless check.
+ return null;
+ } elseif ( count( $titles_for_edit ) > 0 ) {
+ $res = ReplaceTextSearch::doSearchQuery(
+ $this->replacement,
+ $this->selected_namespaces,
+ $this->category,
+ $this->prefix,
+ $this->use_regex
+ );
+ $count = $res->numRows();
+ if ( $count > 0 ) {
+ return $this->msg( 'replacetext_warning' )->numParams( $count )
+ ->params( "<code><nowiki>{$this->replacement}</nowiki></code>" )->text();
+ }
+ } elseif ( count( $titles_for_move ) > 0 ) {
+ $res = $this->getMatchingTitles(
+ $this->replacement,
+ $this->selected_namespaces,
+ $this->category,
+ $this->prefix, $this->use_regex
+ );
+ $count = $res->numRows();
+ if ( $count > 0 ) {
+ return $this->msg( 'replacetext_warning' )->numParams( $count )
+ ->params( $this->replacement )->text();
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * @param string|null $warning_msg Message to be shown at top of form
+ */
+ function showForm( $warning_msg = null ) {
+ $out = $this->getOutput();
+
+ $out->addHTML(
+ Xml::openElement(
+ 'form',
+ [
+ 'id' => 'powersearch',
+ 'action' => $this->getPageTitle()->getFullURL(),
+ 'method' => 'post'
+ ]
+ ) . "\n" .
+ Html::hidden( 'title', $this->getPageTitle()->getPrefixedText() ) .
+ Html::hidden( 'continue', 1 ) .
+ Html::hidden( 'token', $out->getUser()->getEditToken() )
+ );
+ if ( is_null( $warning_msg ) ) {
+ $out->addWikiMsg( 'replacetext_docu' );
+ } else {
+ $out->wrapWikiMsg(
+ "<div class=\"errorbox\">\n$1\n</div><br clear=\"both\" />",
+ $warning_msg
+ );
+ }
+
+ $out->addHTML( '<table><tr><td style="vertical-align: top;">' );
+ $out->addWikiMsg( 'replacetext_originaltext' );
+ $out->addHTML( '</td><td>' );
+ // 'width: auto' style is needed to override MediaWiki's
+ // normal 'width: 100%', which causes the textarea to get
+ // zero width in IE
+ $out->addHTML(
+ Xml::textarea( 'target', $this->target, 100, 5, [ 'style' => 'width: auto;' ] )
+ );
+ $out->addHTML( '</td></tr><tr><td style="vertical-align: top;">' );
+ $out->addWikiMsg( 'replacetext_replacementtext' );
+ $out->addHTML( '</td><td>' );
+ $out->addHTML(
+ Xml::textarea( 'replacement', $this->replacement, 100, 5, [ 'style' => 'width: auto;' ] )
+ );
+ $out->addHTML( '</td></tr></table>' );
+
+ // SQLite unfortunately lacks a REGEXP function or operator by
+ // default, so disable regex(p) searches for SQLite.
+ $dbr = wfGetDB( DB_REPLICA );
+ if ( $dbr->getType() != 'sqlite' ) {
+ $out->addHTML( Xml::tags( 'p', null,
+ Xml::checkLabel(
+ $this->msg( 'replacetext_useregex' )->text(),
+ 'use_regex', 'use_regex'
+ )
+ ) . "\n" .
+ Xml::element( 'p',
+ [ 'style' => 'font-style: italic' ],
+ $this->msg( 'replacetext_regexdocu' )->text()
+ )
+ );
+ }
+
+ // The interface is heavily based on the one in Special:Search.
+ $namespaces = SearchEngine::searchableNamespaces();
+ $tables = $this->namespaceTables( $namespaces );
+ $out->addHTML(
+ "<div class=\"mw-search-formheader\"></div>\n" .
+ "<fieldset id=\"mw-searchoptions\">\n" .
+ Xml::tags( 'h4', null, $this->msg( 'powersearch-ns' )->parse() )
+ );
+ // The ability to select/unselect groups of namespaces in the
+ // search interface exists only in some skins, like Vector -
+ // check for the presence of the 'powersearch-togglelabel'
+ // message to see if we can use this functionality here.
+ if ( $this->msg( 'powersearch-togglelabel' )->isDisabled() ) {
+ // do nothing
+ } else {
+ $out->addHTML(
+ Html::element(
+ 'div',
+ [ 'id' => 'mw-search-togglebox' ]
+ )
+ );
+ }
+ $out->addHTML(
+ Xml::element( 'div', [ 'class' => 'divider' ], '', false ) .
+ "$tables\n</fieldset>"
+ );
+ // @todo FIXME: raw html messages
+ $category_search_label = $this->msg( 'replacetext_categorysearch' )->escaped();
+ $prefix_search_label = $this->msg( 'replacetext_prefixsearch' )->escaped();
+ $rcPage = SpecialPage::getTitleFor( 'Recentchanges' );
+ $rcPageName = $rcPage->getPrefixedText();
+ $out->addHTML(
+ "<fieldset id=\"mw-searchoptions\">\n" .
+ Xml::tags( 'h4', null, $this->msg( 'replacetext_optionalfilters' )->parse() ) .
+ Xml::element( 'div', [ 'class' => 'divider' ], '', false ) .
+ "<p>$category_search_label\n" .
+ Xml::input( 'category', 20, $this->category, [ 'type' => 'text' ] ) . '</p>' .
+ "<p>$prefix_search_label\n" .
+ Xml::input( 'prefix', 20, $this->prefix, [ 'type' => 'text' ] ) . '</p>' .
+ "</fieldset>\n" .
+ "<p>\n" .
+ Xml::checkLabel(
+ $this->msg( 'replacetext_editpages' )->text(), 'edit_pages', 'edit_pages', true
+ ) . '<br />' .
+ Xml::checkLabel(
+ $this->msg( 'replacetext_movepages' )->text(), 'move_pages', 'move_pages'
+ ) . '<br />' .
+ Xml::checkLabel(
+ $this->msg( 'replacetext_announce', $rcPageName )->text(), 'doAnnounce', 'doAnnounce', true
+ ) .
+ "</p>\n" .
+ Xml::submitButton( $this->msg( 'replacetext_continue' )->text() ) .
+ Xml::closeElement( 'form' )
+ );
+ // Add Javascript specific to Special:Search
+ $out->addModules( 'mediawiki.special.search' );
+ }
+
+ /**
+ * Copied almost exactly from MediaWiki's SpecialSearch class, i.e.
+ * the search page
+ * @param string[] $namespaces
+ * @param int $rowsPerTable
+ * @return string HTML
+ */
+ function namespaceTables( $namespaces, $rowsPerTable = 3 ) {
+ global $wgContLang;
+ // Group namespaces into rows according to subject.
+ // Try not to make too many assumptions about namespace numbering.
+ $rows = [];
+ $tables = "";
+ foreach ( $namespaces as $ns => $name ) {
+ $subj = MWNamespace::getSubject( $ns );
+ if ( !array_key_exists( $subj, $rows ) ) {
+ $rows[$subj] = "";
+ }
+ $name = str_replace( '_', ' ', $name );
+ if ( '' == $name ) {
+ $name = $this->msg( 'blanknamespace' )->text();
+ }
+ $rows[$subj] .= Xml::openElement( 'td', [ 'style' => 'white-space: nowrap' ] ) .
+ Xml::checkLabel( $name, "ns{$ns}", "mw-search-ns{$ns}", in_array( $ns, $namespaces ) ) .
+ Xml::closeElement( 'td' ) . "\n";
+ }
+ $rows = array_values( $rows );
+ $numRows = count( $rows );
+ // Lay out namespaces in multiple floating two-column tables so they'll
+ // be arranged nicely while still accommodating different screen widths
+ // Float to the right on RTL wikis
+ $tableStyle = $wgContLang->isRTL() ?
+ 'float: right; margin: 0 0 0em 1em' : 'float: left; margin: 0 1em 0em 0';
+ // Build the final HTML table...
+ for ( $i = 0; $i < $numRows; $i += $rowsPerTable ) {
+ $tables .= Xml::openElement( 'table', [ 'style' => $tableStyle ] );
+ for ( $j = $i; $j < $i + $rowsPerTable && $j < $numRows; $j++ ) {
+ $tables .= "<tr>\n" . $rows[$j] . "</tr>";
+ }
+ $tables .= Xml::closeElement( 'table' ) . "\n";
+ }
+ return $tables;
+ }
+
+ /**
+ * @param array $titles_for_edit
+ * @param array $titles_for_move
+ * @param array $unmoveable_titles
+ */
+ function pageListForm( $titles_for_edit, $titles_for_move, $unmoveable_titles ) {
+ global $wgLang;
+
+ $out = $this->getOutput();
+
+ $formOpts = [
+ 'id' => 'choose_pages',
+ 'method' => 'post',
+ 'action' => $this->getPageTitle()->getFullUrl()
+ ];
+ $out->addHTML(
+ Xml::openElement( 'form', $formOpts ) . "\n" .
+ Html::hidden( 'title', $this->getPageTitle()->getPrefixedText() ) .
+ Html::hidden( 'target', $this->target ) .
+ Html::hidden( 'replacement', $this->replacement ) .
+ Html::hidden( 'use_regex', $this->use_regex ) .
+ Html::hidden( 'move_pages', $this->move_pages ) .
+ Html::hidden( 'edit_pages', $this->edit_pages ) .
+ Html::hidden( 'doAnnounce', $this->doAnnounce ) .
+ Html::hidden( 'replace', 1 ) .
+ Html::hidden( 'token', $out->getUser()->getEditToken() )
+ );
+
+ foreach ( $this->selected_namespaces as $ns ) {
+ $out->addHTML( Html::hidden( 'ns' . $ns, 1 ) );
+ }
+
+ $out->addModules( "ext.ReplaceText" );
+ $out->addModuleStyles( "ext.ReplaceTextStyles" );
+ // Needed for bolding of search term.
+ $out->addModuleStyles( "mediawiki.special.search.styles" );
+
+ if ( count( $titles_for_edit ) > 0 ) {
+ $out->addWikiMsg(
+ 'replacetext_choosepagesforedit',
+ "<code><nowiki>{$this->target}</nowiki></code>",
+ "<code><nowiki>{$this->replacement}</nowiki></code>",
+ $wgLang->formatNum( count( $titles_for_edit ) )
+ );
+
+ foreach ( $titles_for_edit as $title_and_context ) {
+ /**
+ * @var $title Title
+ */
+ list( $title, $context ) = $title_and_context;
+ $out->addHTML(
+ Xml::check( $title->getArticleID(), true ) .
+ ReplaceTextUtils::link( $title ) .
+ " - <small>$context</small><br />\n"
+ );
+ }
+ $out->addHTML( '<br />' );
+ }
+
+ if ( count( $titles_for_move ) > 0 ) {
+ $out->addWikiMsg(
+ 'replacetext_choosepagesformove',
+ $this->target, $this->replacement, $wgLang->formatNum( count( $titles_for_move ) )
+ );
+ foreach ( $titles_for_move as $title ) {
+ $out->addHTML(
+ Xml::check( 'move-' . $title->getArticleID(), true ) .
+ ReplaceTextUtils::link( $title ) . "<br />\n"
+ );
+ }
+ $out->addHTML( '<br />' );
+ $out->addWikiMsg( 'replacetext_formovedpages' );
+ $rcPage = SpecialPage::getTitleFor( 'Recentchanges' );
+ $rcPageName = $rcPage->getPrefixedText();
+ $out->addHTML(
+ Xml::checkLabel(
+ $this->msg( 'replacetext_savemovedpages' )->text(),
+ 'create-redirect', 'create-redirect', true ) . "<br />\n" .
+ Xml::checkLabel(
+ $this->msg( 'replacetext_watchmovedpages' )->text(),
+ 'watch-pages', 'watch-pages', false ) . '<br />'
+ );
+ $out->addHTML( '<br />' );
+ }
+
+ $out->addHTML(
+ "<br />\n" .
+ Xml::submitButton( $this->msg( 'replacetext_replace' )->text() ) . "\n"
+ );
+
+ // Only show "invert selections" link if there are more than
+ // five pages.
+ if ( count( $titles_for_edit ) + count( $titles_for_move ) > 5 ) {
+ $buttonOpts = [
+ 'type' => 'button',
+ 'value' => $this->msg( 'replacetext_invertselections' )->text(),
+ 'disabled' => true,
+ 'id' => 'replacetext-invert',
+ 'class' => 'mw-replacetext-invert'
+ ];
+
+ $out->addHTML(
+ Xml::element( 'input', $buttonOpts )
+ );
+ }
+
+ $out->addHTML( '</form>' );
+
+ if ( count( $unmoveable_titles ) > 0 ) {
+ $out->addWikiMsg( 'replacetext_cannotmove', $wgLang->formatNum( count( $unmoveable_titles ) ) );
+ $text = "<ul>\n";
+ foreach ( $unmoveable_titles as $title ) {
+ $text .= "<li>" . ReplaceTextUtils::link( $title ) . "<br />\n";
+ }
+ $text .= "</ul>\n";
+ $out->addHTML( $text );
+ }
+ }
+
+ /**
+ * Extract context and highlights search text
+ *
+ * @todo The bolding needs to be fixed for regular expressions.
+ * @param string $text
+ * @param string $target
+ * @param bool $use_regex
+ * @return string
+ */
+ function extractContext( $text, $target, $use_regex = false ) {
+ global $wgLang;
+
+ $cw = $this->getUser()->getOption( 'contextchars', 40 );
+
+ // Get all indexes
+ if ( $use_regex ) {
+ preg_match_all( "/$target/Uu", $text, $matches, PREG_OFFSET_CAPTURE );
+ } else {
+ $targetq = preg_quote( $target, '/' );
+ preg_match_all( "/$targetq/", $text, $matches, PREG_OFFSET_CAPTURE );
+ }
+
+ $poss = [];
+ foreach ( $matches[0] as $_ ) {
+ $poss[] = $_[1];
+ }
+
+ $cuts = [];
+ // @codingStandardsIgnoreStart
+ for ( $i = 0; $i < count( $poss ); $i++ ) {
+ // @codingStandardsIgnoreEnd
+ $index = $poss[$i];
+ $len = strlen( $target );
+
+ // Merge to the next if possible
+ while ( isset( $poss[$i + 1] ) ) {
+ if ( $poss[$i + 1] < $index + $len + $cw * 2 ) {
+ $len += $poss[$i + 1] - $poss[$i];
+ $i++;
+ } else {
+ // Can't merge, exit the inner loop
+ break;
+ }
+ }
+ $cuts[] = [ $index, $len ];
+ }
+
+ $context = '';
+ foreach ( $cuts as $_ ) {
+ list( $index, $len, ) = $_;
+ $context .= $this->convertWhiteSpaceToHTML(
+ $wgLang->truncate( substr( $text, 0, $index ), - $cw, '...', false )
+ );
+ $snippet = $this->convertWhiteSpaceToHTML( substr( $text, $index, $len ) );
+ if ( $use_regex ) {
+ $targetStr = "/$target/Uu";
+ } else {
+ $targetq = preg_quote( $this->convertWhiteSpaceToHTML( $target ), '/' );
+ $targetStr = "/$targetq/i";
+ }
+ $context .= preg_replace( $targetStr, '<span class="searchmatch">\0</span>', $snippet );
+
+ $context .= $this->convertWhiteSpaceToHTML(
+ $wgLang->truncate( substr( $text, $index + $len ), $cw, '...', false )
+ );
+ }
+ return $context;
+ }
+
+ private function convertWhiteSpaceToHTML( $msg ) {
+ $msg = htmlspecialchars( $msg );
+ $msg = preg_replace( '/^ /m', '&#160; ', $msg );
+ $msg = preg_replace( '/ $/m', ' &#160;', $msg );
+ $msg = preg_replace( '/ /', '&#160; ', $msg );
+ # $msg = str_replace( "\n", '<br />', $msg );
+ return $msg;
+ }
+
+ private function getMatchingTitles( $str, $namespaces, $category, $prefix, $use_regex = false ) {
+ $dbr = wfGetDB( DB_REPLICA );
+
+ $tables = [ 'page' ];
+ $vars = [ 'page_title', 'page_namespace' ];
+
+ $str = str_replace( ' ', '_', $str );
+ if ( $use_regex ) {
+ $comparisonCond = ReplaceTextSearch::regexCond( $dbr, 'page_title', $str );
+ } else {
+ $any = $dbr->anyString();
+ $comparisonCond = 'page_title ' . $dbr->buildLike( $any, $str, $any );
+ }
+ $conds = [
+ $comparisonCond,
+ 'page_namespace' => $namespaces,
+ ];
+
+ ReplaceTextSearch::categoryCondition( $category, $tables, $conds );
+ ReplaceTextSearch::prefixCondition( $prefix, $conds );
+ $sort = [ 'ORDER BY' => 'page_namespace, page_title' ];
+
+ return $dbr->select( $tables, $vars, $conds, __METHOD__, $sort );
+ }
+
+ /**
+ * @inheritDoc
+ */
+ protected function getGroupName() {
+ return 'wiki';
+ }
+}
diff --git a/www/wiki/extensions/ReplaceText/tests/phan/config.php b/www/wiki/extensions/ReplaceText/tests/phan/config.php
new file mode 100644
index 00000000..2895780d
--- /dev/null
+++ b/www/wiki/extensions/ReplaceText/tests/phan/config.php
@@ -0,0 +1,19 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+
+$cfg['directory_list'] = array_merge(
+ $cfg['directory_list'],
+ [
+ './../../extensions/AdminLinks',
+ ]
+);
+
+$cfg['exclude_analysis_directory_list'] = array_merge(
+ $cfg['exclude_analysis_directory_list'],
+ [
+ './../../extensions/AdminLinks',
+ ]
+);
+
+return $cfg;
diff --git a/www/wiki/extensions/SemanticFormsSelect/res/select2.css b/www/wiki/extensions/SemanticFormsSelect/res/select2.css
index efe1174f..3b70fb56 100644
--- a/www/wiki/extensions/SemanticFormsSelect/res/select2.css
+++ b/www/wiki/extensions/SemanticFormsSelect/res/select2.css
@@ -3,9 +3,9 @@
position: relative;
display: inline-block;
min-width: 210px;
-} */
+}
-/* span.select-sfs-single:after {
+span.select-sfs-single:after {
background-image: url(select2.png);
background-image: url(select2.png), linear-gradient(to top,#ccc 0%,#eee 60%);
background-image: url(select2.png), -webkit-linear-gradient(center bottom,#ccc 0%,#eee 60%);
@@ -13,18 +13,18 @@
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr = '#eeeeee',endColorstr = '#cccccc',GradientType = 0);
height: 100%;
width: 19px;
-} */
+}
-/* span.select-sfs:after{
+span.select-sfs:after{
content: '';
right: 0;
position: absolute;
pointer-events: none;
border-radius: 0 4px 4px 0;
border: 1px solid #aaa;
-} */
+}
-/* span.select-sfs select {
+span.select-sfs select {
padding-top: 2px;
font-size: 95%;
cursor: pointer;
@@ -34,9 +34,9 @@
appearance: none;
display: inline-block;
min-width: 450px !important;
-} */
+}
-/* span.select-sfs select:not([multiple]) {
+span.select-sfs select:not([multiple]) {
height: 26px;
background-image: linear-gradient(to top,#eee 0%,#fff 50%)
} */
diff --git a/www/wiki/extensions/SemanticMediaWiki/DefaultSettings.php b/www/wiki/extensions/SemanticMediaWiki/DefaultSettings.php
index ed60728c..8229b848 100644
--- a/www/wiki/extensions/SemanticMediaWiki/DefaultSettings.php
+++ b/www/wiki/extensions/SemanticMediaWiki/DefaultSettings.php
@@ -31,6 +31,42 @@ return [
'smwgExtraneousLanguageFileDir' => __DIR__ . '/i18n/extra',
'smwgServicesFileDir' => __DIR__ . '/src/Services',
'smwgResourceLoaderDefFiles' => [ 'smw' => __DIR__ . '/res/Resources.php' ],
+ 'smwgMaintenanceDir' => __DIR__ . '/maintenance',
+ ##
+
+ ###
+ # Configuration directory
+ # @see #3506
+ #
+ # The maintained directory needs to be writable in order for configuration
+ # information to be stored persistently and be accessible for Semantic
+ # MediaWiki throughout its operation.
+ #
+ # You may assign the same directory as in `wgUploadDirectory` (e.g
+ # $smwgConfigFileDir = $wgUploadDirectory;) or select an entire different
+ # location. The default location is the Semantic MediaWiki extension root.
+ #
+ # @since 3.0
+ ##
+ 'smwgConfigFileDir' => __DIR__,
+ ##
+
+ ###
+ # Upgrade key
+ #
+ # This key verifies that a correct upgrade (update.php/setupStore.php) path
+ # was selected and hereby ensures a consistent DB setup.
+ #
+ # Whenever a DB table change occurs, modify the key value (e.g. `smw:20...`)
+ # to reflect the requirement for the client to follow the processes as
+ # outlined in the installation manual.
+ #
+ # Once the installer is run, the `.smw.json` will be updated and no longer
+ # cause any exception.
+ #
+ # @since 3.0
+ ##
+ 'smwgUpgradeKey' => 'smw:2018-09-01',
##
###
@@ -63,24 +99,6 @@ return [
##
###
- # Upgrade key
- #
- # This key verifies that a correct upgrade (update.php/setupStore.php) path
- # was selected and hereby ensures a consistent DB setup.
- #
- # Whenever a DB table change occurs, modify the key value (e.g. `DB-Foo...`)
- # to reflect the requirement for the client to follow the processes as
- # outlined in the installation manual.
- #
- # Once the installer is run, the `.smw.json` will be updated and no longer
- # causes an exception.
- #
- # @since 3.0
- ##
- 'smwgUpgradeKey' => 'DB-2018-09-01',
- ##
-
- ###
# CompatibilityMode is to force SMW to work with other extensions that may impact
# performance in an unanticipated way or may contain potential incompatibilities.
#
@@ -379,8 +397,9 @@ return [
# arbitrary text elements and therefore become difficult to transfer when its
# length exceeds a certain character length.
#
- # A compact link will be encoded and compressed to ensure that it can be handled
- # more easily when referring to it as an URL representation.
+ # The experimental feature of a compact link will be encoded and compressed to
+ # ensure that it can be handled more easily when referring to it as an URL
+ # representation.
#
# It is not expected to be used as a short-url service, yet in some instances
# the generate URL can be comparatively shorter than the plain URL.
@@ -392,7 +411,7 @@ return [
# @since 3.0
# @default true
##
- 'smwgCompactLinkSupport' => true,
+ 'smwgCompactLinkSupport' => false,
##
###
@@ -1977,8 +1996,8 @@ return [
# @since 3.0
##
'smwgURITypeSchemeList' => [
- 'http', 'https', 'mailto', 'tel', 'ftp', 'news', 'file', 'urn', 'telnet',
- 'ldap', 'gopher'
+ 'http', 'https', 'mailto', 'tel', 'ftp', 'sftp', 'news', 'file', 'urn',
+ 'telnet', 'ldap', 'gopher', 'ssh', 'git', 'irc', 'ircs'
],
##
diff --git a/www/wiki/extensions/SemanticMediaWiki/SemanticMediaWiki.php b/www/wiki/extensions/SemanticMediaWiki/SemanticMediaWiki.php
index 9b9c1a4f..f74224b5 100644
--- a/www/wiki/extensions/SemanticMediaWiki/SemanticMediaWiki.php
+++ b/www/wiki/extensions/SemanticMediaWiki/SemanticMediaWiki.php
@@ -54,13 +54,6 @@ class SemanticMediaWiki {
$GLOBALS[$key] = $value;
}
}
-
- if ( is_readable( __DIR__ . '/.smw.json' ) ) {
- $GLOBALS['smw.json'] = json_decode(
- file_get_contents( __DIR__ . '/.smw.json' ),
- true
- );
- }
}
/**
@@ -93,6 +86,8 @@ class SemanticMediaWiki {
$namespace->init( $GLOBALS );
$setup = new Setup( $applicationFactory );
+
+ $setup->loadSchema( $GLOBALS );
$setup->init( $GLOBALS, __DIR__ );
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/INSTALL.md b/www/wiki/extensions/SemanticMediaWiki/docs/INSTALL.md
index 282e80a2..aeb04a88 100644
--- a/www/wiki/extensions/SemanticMediaWiki/docs/INSTALL.md
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/INSTALL.md
@@ -127,7 +127,7 @@ If you would like to install a development version or release candidate then rep
"Installation with Composer" section with the following line
* master: `"mediawiki/semantic-media-wiki": "@dev"`
-* legacy branch: `"mediawiki/semantic-media-wiki": "2.5.x@dev"`
+* legacy branch: `"mediawiki/semantic-media-wiki": "3.0.x@dev"`
* release candidate: `"mediawiki/semantic-media-wiki": "~3.0@rc"`
## More instructions
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/README.md b/www/wiki/extensions/SemanticMediaWiki/docs/README.md
index 78125110..963fdfeb 100644
--- a/www/wiki/extensions/SemanticMediaWiki/docs/README.md
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/README.md
@@ -1,5 +1,5 @@
-The documentation for Semantic MediaWiki (SMW) can primarily be found on the [SMW wiki](https://www.semantic-mediawiki.org).
+The documentation for Semantic MediaWiki (SMW) can primarily be found on the [SMW homepage](https://www.semantic-mediawiki.org).
Some core documentation is included together with the source code, and can mostly be found in the
`docs/` directory. This documentation includes basic installation instructions, release notes and
technical documentation.
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/RELEASE-NOTES.md b/www/wiki/extensions/SemanticMediaWiki/docs/RELEASE-NOTES.md
index 5e0c0107..36557b5c 100644
--- a/www/wiki/extensions/SemanticMediaWiki/docs/RELEASE-NOTES.md
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/RELEASE-NOTES.md
@@ -1,373 +1,24 @@
-# Semantic MediaWiki 3.0
+# Semantic MediaWiki 3.0.2
-Released on October 11, 2018.
+Released on April 11, 2019.
-## Highlights
+## Enhancements
-This release brings many highlights:
+* [#3682](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3682) as `f5d0cab`: Removed `IsFileCacheable` hook and improves file caching
+* [#3856](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3854) as `767c981`: Switched setting of configuration parameter "$smwgCompactLinkSupport" to "false"
-### User interface changes
+## Bug fixes and internal code changes
-Several user interface changes are deployed to make user facing front-end components more intutive and mobile-friendly by improving the responsiveness on small screens including:
+* [#3742](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3742): Fixed raw output of templated message particles
+* [#3771](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3771) as `b7a78e0`: Removed `doPostOutputShutdown`
+* [#3772](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3772) as `79e4adb`: Fixed "... expects parameter 1 to be a valid callback ..."
+* [#3775](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3775) as `3b0d83c`: Made data type "Equivalent URI" non declarative
+* [#3847](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3847) as `d088204`: Fixed warning "a non-numeric value" was encountered
+* [#3854](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3854) as `d05671e`: Provided a new test case for "display title"
+* [#3859](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3859): Updated "InfolinkTest"
+* [#3863](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3863): Fixed resource loading by replacing `localpath` with `localBasePath`
+* [0ed4bbf7](https://github.com/SemanticMediaWiki/SemanticMediaWiki/commit/0ed4bbf75e7ee9989d2ac84437d3733b52885eb8): Updated "EventHandlerTest"
-* Special page "Ask" ([#2893](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2893), [#2898](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2898), [#3415](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3415)) – including further enhancements, most notably input assistance on input fields ([#2699](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2699)), comprehensive input help ([#2967](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2967)) and compact links ([#3017](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3017))
-* Special page "Browse" ([#2891](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2891), [#2875](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2875)) – including further enhancements, grouping of properties ([#2874](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2874)) and compact links ([#3017](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3017))
-* Special page "SemanticMediaWiki" ([#3218](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3218))
-* Property pages – boxed pagination ([#3236](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3236)), tabbed navigation ([#3308](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3308)) including usage count information ([#3440](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3440)) and custom tabs ([#3346](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3346))
-* Concept pages – boxed pagination ([#3236](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3236)), tabbed navigation ([#3308](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3308)) and custom tabs ([#3346](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3346))
-* Factbox ([#2906](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2906))
-* Special page "Concepts" ([#3500](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3500))
-
-### List formats and template format rework
-
-The "list" formats (`list`, `ol` and `ul`) and the `template` format were completely reworked with the latter being renamed to `plainlist` [(#3130)](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3130) now being the default result format if no result format was explicitly specifed for the query. Most notably dedicated separators for values, properties and result "rows" (`sep`, `propsep`, `valuesep`) were introduced as well as class attributes to HTML elements of "list", "ol" and "ul" formats were added to facilitate easy indidual styling. Note that the `plainlist` format does not apply these additional class attributes.
-
-**See the [migration guide](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/technical/migration-guide-3.0.md#list-formats-incl-list-ol-ul-template) for a comprehensive overview of the changes done.**
-
-### Search and query
-
-Local-specific (ICU) sorting and collation is now possible for pages as well as values of datatype "Page" [(#2065)](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2065) facilitated via configuration parameter [`$smwgEntityCollation`](https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation) [(#2429).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2429)
-
-Special page "Search" now provides and additional search form accessible via the "Extended" selector in case the ["SMWSearch" feature](https://www.semantic-mediawiki.org/wiki/Help:SMWSearch) was enabled [(#3126).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3126) with custom search forms definable in the new "smw/schema" namespace [(#3431).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3431)
-
-### Performance
-
-Various effort have been put into improving the performance of the software, most notably with these three code changes:
-[#3142](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3142), [#3261](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3261) and [#3286](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3286) with the latter facilitating less expensive paging limits on various user facing special pages via configuration parameter [`$smwgPagingLimit`](https://www.semantic-mediawiki.org/wiki/Help:$smwgPagingLimit).
-
-## Upgrading
-
-Even though Semantic MediaWiki now supports the extension registration approach with "extension.json" (#1732), `enableSemantics` remains the sole point of activiation for SMW itself to ensure that data and objects are prepared in advanced and users do not have to modify any existing settings in their "LocalSettings.php" file.
-
-This release requires (#2065, #2461, #2499) to run the "setupStore.php" or "update.php" script and a missing upgrade process will redirect users to an [error message](https://www.semantic-mediawiki.org/wiki/Help:Upgrade) to remind him or her of a required action. Note that running the schema update may take quite long (minutes on a medium sized site, many hours on a large site).
-
-**Note that SMW requires write access to the code directory meaning that you currently cannot update. This will be fixed in the following relase allowing to configure an alternative directory for this purpose.**
-
-After the upgrade, please check the "Deprecation notices" section on special page "SemanticMediaWiki" to adapt and modify listed deprecated settings.
-
-If you are still using maintenance scripts identifiable by the "SMW_" prefix you must now migrate to the new maintenance script names. See the help pages on [maintenance scrips](https://www.semantic-mediawiki.org/wiki/Help:Maintenance_scripts) for further information.
-
-[#3198](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3198) switched to PHP 5.6 as minimum requirement as well as to MediaWiki 1.27 as minimum requirement.
-
-**Please also carefully read the section on breaking changes and deprecations further down in these release notes. We have also prepared a [migration guide](https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_3.0.0/Migration_guide) for you.**
-
-## Miscellaneous
-
-Semantic MediaWiki no longer provides file releases [(See #3347).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1732) If command line access to the webspace is not available or if the hoster imposes restrictions on required functionality an [individual file release](https://github.com/SemanticMediaWiki/IndividualFileRelease) will have to be created.
-
-## New features and enhancements
-
-### Setup
-
-* [#1732](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1732) Added support for "extension.json"
-* [#2916](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2916) Added supplements jobs during the installation process
-* [#3095](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3095) Added database upgrade check with ".smw.json"
-
-### Store
-
-* [#2461](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2461) Improved performance on fetching incoming properties
-* [#2882](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2882) Added detection of duplicate entities upon storage
-* [#2516](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2516) Added an optimization run during the installation process (`setupStore.php`) for SQL tables managed by Semantic MediaWiki
-* [#2065](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2065) Added entity specific collation support with help of the [`$smwgEntityCollation`](https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation) setting
-* [#2499](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2499) Added [`$smwgFieldTypeFeatures`](https://www.semantic-mediawiki.org/wiki/Help:$smwgFieldTypeFeatures) with `SMW_FIELDT_CHAR_NOCASE` to enable case insensitive search queries
-* [#2536](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2536) Added `SMW_FIELDT_CHAR_LONG` as flag for `$smwgFieldTypeFeatures` to extend the indexable length of blob and uri fields to max of 300 chars
-* [#2823](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2823) Added `SMW_QSORT_UNCONDITIONAL`
-* [#3080](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3080) Added warm up caching for the ID lookup
-* [#3142](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3142) Replaced `DISTINCT` with `GROUP BY` in `SQLStore::getPropertySubjects`
-* [#3261](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3261) Added support for index hint in `DataItemHandler` to enforce specific index selection
-* [#3314](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3314) Moved the `FIXED_PROPERTY_ID_UPPERBOUND` from 50 to 500 to increase the range for fixed property IDs
-* [#3353](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3353) Added support in SQLite to drop fields without the need to delete and restore the entire store
-* [#3360](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3360) In MySQL/MariaDB increase ID field size from "int(8)" to "int(11)". Postgres and SQLite have no size restriction.
-* [#3390](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3390) Adds the `smw_rev` field to the `smw_object_ids` table to track an entity instance and its associated revision ID (represents the raw content)
-* [#3397](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3397) MediaWiki removed `Database::nextSequenceValue` in commit wikimedia/mediawiki@0a9c55b#diff-278465351b7c14bbcadac82036080e9f. SMW added this functionality back for the sake of Postgres.
-
-#### ElasticStore
-
-* [#3054](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3054) Added `ElasticStore` to use Elasticsearch as query backend
- - #3237, #3241, #3245, #3247, #3249, #3250, #3253
-* [#3152](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3152) Added extra debug query parameter (score_set, q_engine) to special page "Ask"
-
-### Search
-
-* [#2738](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2738) Added information whether `SMWSearch` search mode is enabled or not for special page "Search"
-* [#3006](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3006) Disabled default autocompletion for terms starting with `[[` in special page "Search" for the `SMWSearch` type
-* [#3096](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3096) Added section title display support to indicate subobjects
-* [#3126](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3126) Added extended power profile form
-* [#3143](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3143) Hides namespace section and add auto-discovery
-* [#3145](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3145) Added simplified term parser to `SMWSearch` (see #3157, #3281)
-* [#3234](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3234) Added support for displaytitle in `SearchResult`
-* [#3237](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3237) Added support for highlights from external search engine, if available
-* [#3419](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3419) Add search autocompletion options when `$wgSearchType = 'SMWSearch';`:
- * `in:Foo bar` equivalent to `[[~~*Foo bar*]]`
- * `phrase:Foo bar` equivalent to `[[~~"Foo bar"]]`
- * `has:Foo bar` equivalent to `[[Foo bar::+]]`
-
-### Query
-
-* [#2398](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2398) Added `#ask` and `#show` parser function support for `@deferred` output mode (see also #3257)
-* [#2476](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2476) Added [`$smwgQExpensiveThreshold`](https://www.semantic-mediawiki.org/wiki/Help:$smwgQExpensiveThreshold) and [`$smwgQExpensiveExecutionLimit`](https://www.semantic-mediawiki.org/wiki/Help:$smwgQExpensiveExecutionLimit) to count and restrict expensive `#ask` and `#show` functions on a per page basis
-* [#2953](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2953) Added support for natural sort (`n-asc`, `n-desc`) of printout column values
-* [#2662](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2662) Added `+depth` as syntax component for a condition to restrict the depth of class and property hierarchy queries
-* [#2558](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2558) Added `like:` and `nlike:` comparator operator for approximate queries
-* [#2572](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2572) Added `@annotation` as special processing mode to embedded `#ask` queries
-* [#2673](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2673) Added the `Query state` special property to be able to track an internal state when a `#ask` uses `@annotation` or `@deferred` as special execution mode. In addition to internal usage, one can also now find all deferred queries with `{{#ask: [[Query state::200]] |format=ul }}`
-* [#2873](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2873) Added support for `in:` as expression to the #ask syntax
-* [#3125](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3125) Added support for `phrase:` as expression
-
-#### Result formats
-
-* [#2420](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2420) Added support for a datatable output in the `format=table` (and `broadtable`) result printer
-* [#2515](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2515) Added support for `#LOCL#TO` date formatting to display a [local time](https://www.semantic-mediawiki.org/wiki/Local_time) offset according to a user preferrence
-* [#2677](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2677) Added `+width` as parameter to the `format=table` (and `broadtable`) result printer
-* [#2690](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2690) Added the `type` parameter to `format=json` in support for a simple list export
-* [#2718](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2718) Added ad-hoc export for the `format=table` datatable
-* [#2824](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2824) Added `bom` as parameter to `format=csv`
-* [#2826](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2826) Added `valuesep` as parameter to `format=csv` to define a value separator
-* [#2822](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2822) Added add `merge` parameter to `format=csv`
-* [#2844](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2844) Renamed output formatter `#-ia` to `#-raw`
-* [#3024](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3024) Added `format=templatefile` to support individual export formats defined using MediaWiki templates
-* [#3009](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3009) Added `#tick` and `#num` output formatter to boolean value type
-* [#3011](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3011) Added the [`$smwgDefaultOutputFormatters`](https://www.semantic-mediawiki.org/wiki/Help:$smwgDefaultOutputFormatters) setting to declare default output formatter for a type or property
-* [#1315](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1315) Added support for media files to the `feed` printer
-* [#3130](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3130) Reworked `list` format
-* [#3162](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3162) Added support for `{{DISPLAYTITLE}}` to the `feed` printer
-* [#3136](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3136) Added `class` parameter to `list` format
-
-### API
-
-* [#2696](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2696) Added a new `smwbrowse` API module ([#2717](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2717), [#2719](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2719), [#2721](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2721))
-* [#3052](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3052) Added `api_version` to ask, askargs API
-* [#3129](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3129) Added API `pvalue` browse module
-* [#3381](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3381) Added API `psubject` browse module
-
-### Misc
-
-* [#794](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/794) Added `SMW_PARSER_UNSTRIP` to [`$smwgParserFeatures`](https://www.semantic-mediawiki.org/wiki/Help:$smwgParserFeatures) enabling to use unstripped content on a text annotation
-* [#2348](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2348) Allow showing annotations even if they are improper for datatype "Text"
-* [#2435](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2435) Added filtering of invisible characters (non-printable, shyness etc.) to armor against incorrect annotations
-* [#2453](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2453) Changed the approach on how referenced properties during an article delete are generated to optimize the update dispatcher
-* [#2471](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2471) Added [`SMW_CAT_REDIRECT`](https://www.semantic-mediawiki.org/wiki/Help:$smwgCategoryFeatures) option to allow finding redirects on categories
-* [#2494](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2494) Added [`$smwgChangePropagationProtection`](https://www.semantic-mediawiki.org/wiki/Help:$smwgChangePropagationProtection) and changed the approach on how property modifications are propagated
-* [#2543](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2543) Extended [`EditPageHelp`](https://www.semantic-mediawiki.org/wiki/Help:$smwgEnabledEditPageHelp) to be disabled using a user preference
-* [#2561](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2561) Added listing of improper assignments to the property page for an easier visual control
-* [#2595](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2595) Improved the content navigation in special page "SemanticMediaWiki"
-* [#2600](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2600) Added [`$smwgCreateProtectionRight`](https://www.semantic-mediawiki.org/wiki/Help:$smwgCreateProtectionRight) setting to control the creation of new properties and hereby annotations as part of the [authority mode](https://www.semantic-mediawiki.org/wiki/Help:Authority_mode)
-* [#2615](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2615) Added `filter=unapprove` to special page "WantedProperties"
-* [#2632](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2632) Added [uniqueness violation](https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness) check on the property page for the property label used
-* [#2699](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2699) Added an [input assistance](https://www.semantic-mediawiki.org/wiki/Help:Input_assistance) for the condition textbox on special page "Ask"
-* [#2726](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2726) Added entity [input assistance](https://www.semantic-mediawiki.org/wiki/Help:Input_assistance) for editors and the input field on special page "Search" ([#2756](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2756))
-* [#2776](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2776) Added tracking of changes to categories (see 2495)
-* [#2785](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2785) Added new styling to property page value list
-* [#2796](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2796) Allows "rendering of HTML" on special page "Ask" when using `|headers=plain` in queries
-* [#2801](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2801) Added `--skip-optimize` and `--skip-import` to `setupStore.php` (see 2516)
-* [#2803](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2803) Filter categories from transcluded content in `format=embedded`
-* [#2815](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2815) Added `#nowiki` support for external identifier type
-* [#2820](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2820) Added check on declarative property usage
-* [#2840](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2840) Added [`$smwgPropertyReservedNameList`](https://www.semantic-mediawiki.org/wiki/Help:$smwgPropertyReservedNameList) to define reserved property names
-* [#2842](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2842) Added [`$smwgURITypeSchemeList`](https://www.semantic-mediawiki.org/wiki/Help:$smwgURITypeSchemeList) to restrict valid URI scheme
-* [#2861](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2861) Added restriction for a property name that contains a CR, LF
-* [#2867](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2867) Added singular, plural category canonical check
-* [#2874](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2874) Added grouping support for properties to special page "Browse"
-* [#2875](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2875) Changed the theme on special page "Browse" to `smwb-theme-light`
-* [#2878](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2878) Added value filter to the property page
-* [#2883](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2883) Added function to special page "SemanticMediaWiki" to find duplicate entities
-* [#2889](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2889) Added method to make subobject sortkeys distinguishable
-* [#2891](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2891) Added flex (responsive) mode to special page "Ask" and special page "Browse" div table
-* [#2893](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2893) Changed special page "Ask" appearance ([#2898](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2898))
-* [#2895](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2895) Changed display of named subobject caption to appear without an underscore
-* [#2906](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2906) Added flex (responsive) mode to the factbox
-* [#2907](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2907) Added modal help to special page "Ask"
-* [#2913](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2913) Added a job queue watchlist feature and the [`$smwgJobQueueWatchlist`](https://www.semantic-mediawiki.org/wiki/Help:$smwgJobQueueWatchlist) setting
-* [#2922](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2922) Added `SMW_BROWSE_SHOW_SORTKEY` flag to the [`$smwgBrowseFeatures`](https://www.semantic-mediawiki.org/wiki/Help:$smwgBrowseFeatures) setting
-* [#2930](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2930) Added limit to value selection on the property page
-* [#2932](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2932) Added ["removeDuplicateEntities.php"](https://www.semantic-mediawiki.org/wiki/Help:Maintenance_script_removeDuplicateEntities.php) script to remove duplicate entities
-* [#2933](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2933) Added [`$smwgDefaultLoggerRole`](https://www.semantic-mediawiki.org/wiki/Help:$smwgDefaultLoggerRole) setting to define logging granularity for Semantic MediaWiki
-* [#2973](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2973) Set initial stats entry for non-fixed predefined properties
-* [#3017](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3017) Added the [`$smwgCompactLinkSupport`](https://www.semantic-mediawiki.org/wiki/Help:$smwgCompactLinkSupport) setting to compact links produced by special page "Ask" and special page "Browse"
-* [#3019](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3019) Added experimental support for the `SMW_NS_RULE` namespace
-* [#3020](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3020) Added the [keyword](https://www.semantic-mediawiki.org/wiki/Help:Type_Keyword) (`_keyw`) type
-* [#3029](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3029) Added function to keep updated entities in-memory to improve rebuild performance
-* [#3088](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3088) Modernized special page "Page property"
-* [#3167](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3167) Added support for `RemoteRequest` to share and consolidate query results from remote sources
-* [#3284](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3284) Added the `--dispose-outdated` flag to the "rebuildData.php" maintenance script
-* [#3289](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3289) Added support for the JSON format in the `Allows value list` definition
-* [#3292](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3292) Added support for bounded intervals, ranges in `Allows value` for number and quantity types
-* [#3293](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3293) Added tanslation page annotation (`_TRANS`) support
-* [#3308](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3308) Extended content representation on property and concept pages using tabs
-* [#3318](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3318) Added `smwgPostEditUpdate` to manage post edit event handling for seconday updates via the API interface
-* [#3319](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3319) Sets an extra parser key for queries that contain a self-reference to improve the result display after an edit event
-* [#3339](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3339) Added support for uniqueness validation in records/references
-* [#3416](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3416) Added support for `<section>` on property pages to put user-defined content into SMW-defined tabs
-* [#3415](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3415) Added "compact view" to hide query on special page "Ask"
-* [#3429](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3429) Changed default submit method of special page "Ask" to POST. Submit method can be modified by setting `$smwgSpecialAskFormSubmitMethod` to `SMW_SASK_SUBMIT_GET`, `SMW_SASK_SUBMIT_REDIRECT`, or explicitly setting the default `SMW_SASK_SUBMIT_POST`.
-* [#3431](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3431) Moved namespace "Rule" to namespace "smw/schema"
-* [#3436](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3436) When an entity is deleted, check for possible open references and keep the ID in case it has a residual reference by turning it into a simple object instance (setting `smw_rev` and `smw_proptable_hash` to null)
-* [#3440](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3440) Changed property pages to show the property usage count in the tab
-* [#3441](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3441) Added flags to maintenance script "rebuildData.php":
- * `--revision-mode`: Skip entities where its associated revision matches the latests referenced revision of an associated page
- * `--force-update`: Force an update even when an associated revision is known
-* [#3443](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3443) Changed job queue job names from `SMW\` prefix to `smw.` prefix. Example: `SMW\UpdateJob` -> `smw.update`
-
-## Bug fixes
-
-* [#481](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/481) Fixed "further results" link with special page "Ask" and templates
-* [#502](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/502) Fixed template with named arguments use in #show
-* [#839](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/839) Fixed and extended special page "Ask" to be more maintainable
-* [#2001](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2001) Fixed issue with `smw_subobject` and the generation of duplicate entities
-* [#2505](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2505) Fixed hard-coded default value for `format=csv`
-* [#2586](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2586) Fixed class assignments for empty cells in `format=table`
-* [#2621](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2621) Fixed sort/order field behaviour in special page "Ask"
-* [#2652](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2652) Fixed handling of multiple checkbox parameter in special page "Ask"
-* [#2817](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2817) Fixed Fix preg_replace ... unmatched parentheses
-* [#2871](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2871) Fixed PHP 7.2 `each` use in `SearchResultSet`
-* [#2881](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2881) Fixed display of display dispatched ID in `DataRebuilder`
-* [#2884](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2884) Fixed "Cannot use object of type MappingIterator as array"
-* [#2896](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2896) Fixed display of inverse indicator for translated predefined properties
-* [#2902](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2902) Fixed "LBFactory::getEmptyTransactionTicket ... does not have outer scope"
-* [#2909](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2909) Fixed use of `LBFactory::getEmptyTransactionTicket`
-* [#2915](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2915) Fixed connection instantiation
-* [#2917](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2917) Fixed "DataItemException ... Unserialization failed: the string ..."
-* [#2919](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2919) Fixed fetching all entities during a delete
-* [#2958](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2958) Fixed to mark subobject entities as done in `ExportController`
-* [#2963](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2963) Fixed recognition of `$wgDBadminuser` in maintenance script "setupStore.php"
-* [#2969](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2969) Fixed PHP 7.2 "Warning: count(): Parameter must be an array or an object that implements Countable" issue
-* [#3000](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3000) Fixed fetching namespace aliases
-* [#3010](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3010) Fixed breaking links in an abbreviated text by the `StringValueFormatter`
-* [#3025](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3025) Fixed storage of query information during a `preview` activity
-* [#3026](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3026) Fixed replacement of `smw_proptable_hash` during setup
-* [#3031](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3031) Fixed duplicate entry `smw_prop_stats` exception
-* [#3033](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3033) Fixed "The supplied ParserOptions are not safe ... set $forceParse = true" during the upload of files
-* [#3049](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3049) Fixed concept selection
-* [#3067](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3067) Fixed processing of simple links containing `|` during the in-text annotation parsing
-* [#3076](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3076) Fixed factbox magic works
-* [#3082](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3082) Fixed use of `ParserOptions::setEditSection` for MW 1.31
-* [#3107](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3107) Fixed recognition of `::=` in `LinksProcessor `
-* [#3134](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3134) Escape `/` in property names
-* [#3144](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3144) Return IDs as integer when matching all entities
-* [#3336](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3336) Fixed issue in special page "Ask" with sort parameter where the first parameter is left empty
-* [#3322](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3322) Fixed issue in `UpdateDispatcherJob` with selecting unrelated entities
-* [#3336](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3336) Fixed special page "Ask" to recognize first empty sort parameter as page title, e.g. `|sort=,Has foo`
-* [#3375](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3375) Fixed error "Invalid sort: title. Must be one of: relevance". MediaWiki default sort type is only `relevance`. SMW added `title`, `recent`, and `best`.
-* [#3389](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3389) Fixed "Error: 23505 ERROR: duplicate key value violates unique constraint "smw_new_pkey"" by setting SQL temporary table `id` field to type `SERIAL` instead of `INTEGERY PRIMARY KEY`
-* [#3393](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3393) Fixed MW 1.31+ highlighter issue causing extra inline `<p>` which added newlines to display
-* [#3413](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3413) Fixed a performance issue for maintenance script "rebuildData.php" by doing `SELECT` on pages+namespaces rather than just pages.
-
-## Breaking changes and deprecations
-
-* [#1345](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1345) Setting multiple values to the `#set` and `#subobject` paser functions using pipe `|` is deprecated. Use the `+sep` parameter instead.
-* [#2495](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2495) `Store::getPropertySubjects` and `Store::getAllPropertySubjects` will return an `Iterator` instead of just an array
-* [#2588](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2588) Removed special page "SemanticStatistics"
-* [#2611](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2611) Removed the user preference `smw-ask-otheroptions-collapsed-info`
-* [#2640](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2640) Removed `$smwgAutocompleteInSpecialAsk`
-* [#2659](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2659) Removed deprecated constant `SMWDataItem::TYPE_STRING` (replaced by `SMWDataItem::TYPE_BLOB`)
-* [#2696](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2696) Soft deprecate the `browsebyproperty` API module, the new `smwbrowse` should be used instead
-* [#2705](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2705) Removed usages of deprecated `ResultPrinter::getParameters`
-* [#2724](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2724) Added `$smwgUseComparableContentHash` and will be removed with 3.1 to help migrating subobject hash generation
-* [#2730](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2730) Replaced `$smwgCacheUsage` settings
-* [#2732](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2732) Replaced `$smwgQueryProfiler` settings
-* [#2748](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2748) Removed `ContextSource` from `ResultPrinter` instances
-* [#2750](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2750) Removed `$smwgSparqlDatabaseMaster` and `$smwfGetSparqlDatabase`
-* [#2752](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2752) Renamed `$smwgSparqlDatabaseConnector` to `$smwgSparqlRepositoryConnector`
-* [#2761](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2761) Renamed `$smwgDeclarationProperties`
-* [#2768](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2768) Changed default setting for `$smwgSparqlRepositoryConnector`
-* [#2788](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2788) Resources are now being exported as Internationalized Resource Identifiers (IRI) by default.
-* [#2790](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2790) Removed deprecated entry points for maintenance scripts
-* [#2802](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2802) Consolidated `$smwgParserFeatures` setting
-* [#2806](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2806) Consolidated `$smwgCategoryFeatures` setting
-* [#2821](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2821) Consolidated `smwgQSortFeatures` setting
-* [#2841](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2841) Replaced `$smwgLinksInValues` with the `SMW_PARSER_LINV` flag now maintained in `$smwgParserFeatures`, PCRE option has been removed
-* [#2880](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2880) Migrated special property message keys to new naming schema
-* [#2899](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2899) Removed `$smwgScriptPath`
-* [#2927](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2927) Removed `SEMANTIC_EXTENSION_TYPE` flag
-* [#2944](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2944) Removed deprecated methods in `SMW\DIProperty`
-* [#2961](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2961) Renamed `smwAddToRDFExport` hook
-* [#2995](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2995) Updated old namespace in Spanish
-* [#3164](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3164) Removed `SMW_NS_TYPE` ns and `$smwgHistoricTypeNamespace`
-* [#3231](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3231) Consolidated `$smwgPagingLimit` setting
-* [#3267](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3267) Removed `SMWQueryProcessor::getSortKeys`
-* [#3285](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3285) Deprecated API module `BrowseBySubject`, use `smwbrowse` instead
-* [#3307](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3307) Replaced `smwgCacheType` with `smwgMainCacheType`
-* [#3315](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3315) Consolidated `smwgSparqlEndpoint` sparql endpoint setting
-* [#3366](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3366) Replaced deprecated alias `SMWDIProperty` with `DIProperty` in `SMWDataValue`
-* [#3364](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3364) Removed long-deprecated static functions `SMWWikiPageValue::makePage` and `SMWWikiPageValue::makePageFromTitle`
-* [#3363](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3363) Removed deprecated `ResultPrinter::$m_params`. Use `ResultPrinter::$params` instead.
-* [#3399](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3399) Removed several functions deprecated since SMW 1.9 from `SMW\DataValueFactory`
-* [#3401](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3401) Removed long-deprecated functions `ResultPrinter::textDisplayParameters` and `ResultPrinter::exportFormatParameters`
-* [#3403](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3403) Removed long-deprecated function `SMWResultArray::getNextObject`
-* [#3405](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3405) Removed long-deprecated SMWDIString
-* [#3406](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3406) Removed long-deprecated function `SMWRecordValue::getDV`
-* [#3407](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3407) Removed deprecated global function `smwfIsSemanticsProcessed`
-
-## Other changes
-
-* [#2342](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2342) Added the display of invalid data value annotations for datatype "Text"
-* [#2485](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2485) Disabled updates by the `QueryDependencyLinksStore` on a 'stashedit' activity
-* [#2491](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2491) Added `ChunkedIterator` to `DataRebuilder` to avoid OOM situations in case of a large update queue
-* [#2535](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2535) Fixed property namespace (`_wpp`) display in `WikiPageValue`
-* [#2540](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2540) Added type `parser-html` to [`JSONScript`](https://www.semantic-mediawiki.org/wiki/Help:Integration_tests) testing to allow assertions on HTML structure
-* [#2591](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2591) Discontinued reading MediaWiki `job` table, use the `JobQueue::getQueueSizes` instead
-* [#2609](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2609) Added check to special page "Ask" to require JavaScript
-* [#2631](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2631) Disabled purge button while JS resources are still loaded
-* [#2650](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2650) Replaced some styles in special page "Ask"
-* [#2653](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2653) Fixed `broadtable` width with the "MobileFrontend" extension
-* [#2676](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2676) Added support for column default values in the `TableBuilder`
-* [#2680](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2680) Added `null_count` column to `PropertyStatisticsTable`
-* [#2691](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2691) Replaced `#info` icon set
-* [#2698](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2698) Added persistent caching to the `HierarchyLookup`
-* [#2714](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2714) Added `SMW::GetPreferences` hook
-* [#2727](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2727) Moved parameter processing from `QueryProcessor` to `ParamListProcessor`
-* [#2745](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2745) Moved `ResultPrinter` base class
-* [#2747](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2747) Moved `TableResultPrinter`
-* [#2751](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2751) Added `RecursiveTextProcessor` to isolate `$wgParser` access in `ResultPrinter`
-* [#2765](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2765) Added `SMW::Setup::AfterInitializationComplete` hook
-* [#2774](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2774) Moved `SMWQueryParser` to `SMW\Query\Parser`
-* [#2783](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2783) Added `JsonSchemaValidator`
-* [#2785](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2785) Moved `PropertyPage` and `ConceptPage`
-* [#2845](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2845) Extended use of cached hierarchy instance
-* [#2847](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2847) Introduced different approach to update query dependencies
-* [#2888](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2888) Introduced `Setup::initExtension` to allow an early registration of `SpecialPage_initList` and `ApiMain::moduleManager` hooks
-* [#2908](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2908) Refactored the `ConnectionProvider`
-* [#2928](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2928) Moved `SQLStore::fetchSemanticData` to `SemanticDataLookup`
-* [#2972](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2972) Added `SMW::SQLStore::EntityReferenceCleanUpComplete` hook
-* [#3032](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3032) Added the `SMW::LinksUpdate::ApprovedUpdate` and `SMW::Parser::ChangeRevision` hook
-* [#3061](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3061) Added detection of changes emitted by the `BlockIpComplete`, `UnblockUserComplete`, and `UserGroupsChanged` hook
-* [#3063](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3063) Moved import files to data folder
-* [#3070](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3070) Added `SMW::Admin::TaskHandlerFactory` hook
-* [#3131](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3131) Added `CONTENT_MODEL_RULE` to be able to do schema validation before a save sometime in the future. Switching to an alternate model at a later stage would only create headaches.
-* [#3138](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3138) Fixed use of `$wgExtensionDirectory` to find SMW's "extension.json"
-* [#3146](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3147) Moved table hash cache handling
-* [#3160](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3160) Moved `FeedExportPrinter` and added integration test
-* [#3260](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3260) Moved `SMWSQLStore3::changeSMWPageID`
-* [#3275](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3275) Moved `SMWSQLStore3Readers::getPropertySubjects`
-* [#3282](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3282) Moved `SMWSQLStore3Readers::getProperties`
-* [#3384](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3384) Isolated the handling of "ALTER SEQUENCE ..." for Postgres
-* [#3432](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3432) Moved `SMW\CategoryResultPrinter` to `SMW\Query\ResultPrinters\CategoryResultPrinter`
-
-## Contributors
-
-- 1036 - James Hong Kong
-- 147 - translatewiki.net for the translator community
-- 120 - Karsten Hoffmeyer
-- 50 - Jeroen De Dauw
-- 13 - Stephan Gambke
-- 7 - Kumioko
-- 6 - Iván
-- 6 - Zoran Dori
-- 4 - James Montalvo
-- 4 - Máté Szabó
-- 2 - Jaider Andrade Ferreira
-- 2 - Josef Konrad
-- 2 - TK-999
-- 1 - Amir E. Aharoni
-- 1 - C. Scott Ananian
-- 1 - Kunal Mehta
-- 1 - Peter Grassberger
-- 1 - Prateek Saxena
-- 1 - Stephan
-- 1 - Thiemo Kreuz
-- 1 - Timo Tijhof
-- 1 - Toni Hermoso Pulido
-- 1 - ka7
-- 1 - matthew-a-thompson
-- 1 - salle
-- 1 - غلامحسین حق دوست
+## See also
+* [RELEASE NOTES](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/3.0.x/docs/releasenotes/RELEASE-NOTES-3.0.0.md) for Semantic MediaWiki 3.0.0
+* [RELEASE NOTES](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/3.0.x/docs/releasenotes/RELEASE-NOTES-3.0.1.md) for Semantic MediaWiki 3.0.1
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/README.md b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/README.md
index 2a064010..8f1df375 100644
--- a/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/README.md
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/README.md
@@ -1,5 +1,8 @@
## Release notes
+* [SMW 3.0.2 release notes](RELEASE-NOTES-3.0.2.md)
+* [SMW 3.0.1 release notes](RELEASE-NOTES-3.0.1.md)
+* [SMW 3.0.0 release notes](RELEASE-NOTES-3.0.0.md)
* [SMW 2.5.8 release notes](RELEASE-NOTES-2.5.8.md)
* [SMW 2.5.7 release notes](RELEASE-NOTES-2.5.7.md)
* [SMW 2.5.6 release notes](RELEASE-NOTES-2.5.6.md)
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.0.md b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.0.md
new file mode 100644
index 00000000..3a4a3bb9
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.0.md
@@ -0,0 +1,375 @@
+# Semantic MediaWiki 3.0
+
+Released on October 11, 2018.
+
+## Highlights
+
+This release brings many highlights:
+
+### User interface changes
+
+Several user interface changes are deployed to make user facing front-end components more intutive and mobile-friendly by improving the responsiveness on small screens including:
+
+* Special page "Ask" ([#2891](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2891), [#2893](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2893), [#2898](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2898), [#3415](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3415)) – including further enhancements, most notably input assistance on input fields ([#2699](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2699)), comprehensive input help ([#2907](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2907)) and compact links ([#3017](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3017))
+* Special page "Browse" ([#2891](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2891), [#2875](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2875)) – including further enhancements, grouping of properties ([#2874](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2874)) and compact links ([#3017](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3017))
+* Special page "SemanticMediaWiki" ([#3218](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3218))
+* Property pages – boxed pagination ([#3236](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3236)), tabbed navigation ([#3308](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3308)) including usage count information ([#3440](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3440)) and custom tabs ([#3416](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3416))
+* Concept pages – boxed pagination ([#3236](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3236)), tabbed navigation ([#3308](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3308)) and custom tabs ([#3416](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3416))
+* Factbox ([#2906](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2906))
+* Special page "Concepts" ([#3333](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3333))
+
+### List formats and template format rework
+
+The "list" formats (`list`, `ol` and `ul`) and the `template` format were completely reworked with the latter being renamed to `plainlist` [(#3130)](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3130) now being the default result format if no result format was explicitly specifed for the query. Most notably dedicated separators for values, properties and result "rows" (`sep`, `propsep`, `valuesep`) were introduced as well as class attributes to HTML elements of "list", "ol" and "ul" formats were added to facilitate easy indidual styling. Note that the `plainlist` format does not apply these additional class attributes.
+
+**See the [migration guide](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/technical/migration-guide-3.0.md#list-formats-incl-list-ol-ul-template) for a comprehensive overview of the changes done.**
+
+### Search and query
+
+Local-specific (ICU) sorting and collation is now possible for pages as well as values of datatype "Page" [(#2065)](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2065) facilitated via configuration parameter [`$smwgEntityCollation`](https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation) [(#2429).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2429)
+
+Special page "Search" now provides and additional search form accessible via the "Extended" selector in case the ["SMWSearch" feature](https://www.semantic-mediawiki.org/wiki/Help:SMWSearch) was enabled [(#3126).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3126) with custom search forms definable in the new "smw/schema" namespace [(#3431).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3431)
+
+It is now possible to define [remote sources which can be queried](https://www.semantic-mediawiki.org/wiki/Help:Remote_request) using special page "Ask" or doing inline queries [(#3167).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3167)
+
+### Performance
+
+Various effort have been put into improving the performance of the software, most notably with these three code changes:
+[#3142](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3142), [#3261](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3261) and [#3286](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3286) with the latter facilitating less expensive paging limits on various user facing special pages via configuration parameter [`$smwgPagingLimit`](https://www.semantic-mediawiki.org/wiki/Help:$smwgPagingLimit).
+
+## Upgrading
+
+Even though Semantic MediaWiki now supports the extension registration approach with "extension.json" (#1732), `enableSemantics` remains the sole point of activiation for SMW itself to ensure that data and objects are prepared in advanced and users do not have to modify any existing settings in their "LocalSettings.php" file.
+
+This release requires (#2065, #2461, #2499) to run the "setupStore.php" or "update.php" script and a missing upgrade process will redirect users to an [error message](https://www.semantic-mediawiki.org/wiki/Help:Upgrade) to remind him or her of a required action. Note that running the schema update may take quite long (minutes on a medium sized site, many hours on a large site).
+
+**Note that SMW requires write access to the code directory meaning that you currently cannot update. This will be fixed in the following relase allowing to configure an alternative directory for this purpose.**
+
+After the upgrade, please check the "Deprecation notices" section on special page "SemanticMediaWiki" to adapt and modify listed deprecated settings.
+
+If you are still using maintenance scripts identifiable by the "SMW_" prefix you must now migrate to the new maintenance script names. See the help pages on [maintenance scrips](https://www.semantic-mediawiki.org/wiki/Help:Maintenance_scripts) for further information.
+
+[#3198](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3198) switched to PHP 5.6 as minimum requirement as well as to MediaWiki 1.27 as minimum requirement.
+
+**Please also carefully read the section on breaking changes and deprecations further down in these release notes. We have also prepared a [migration guide](https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_3.0.0/Migration_guide) for you.**
+
+## Miscellaneous
+
+Semantic MediaWiki no longer provides file releases [(See #3347).](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3347) If command line access to the webspace is not available or if the hoster imposes restrictions on required functionality an [individual file release](https://github.com/SemanticMediaWiki/IndividualFileRelease) will have to be created.
+
+## New features and enhancements
+
+### Setup
+
+* [#1732](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1732) Added support for "extension.json"
+* [#2916](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2916) Added supplements jobs during the installation process
+* [#3095](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3095) Added database upgrade check with ".smw.json"
+
+### Store
+
+* [#2461](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2461) Improved performance on fetching incoming properties
+* [#2882](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2882) Added detection of duplicate entities upon storage
+* [#2516](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2516) Added an optimization run during the installation process (`setupStore.php`) for SQL tables managed by Semantic MediaWiki
+* [#2065](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2065) Added entity specific collation support with help of the [`$smwgEntityCollation`](https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation) setting
+* [#2499](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2499) Added [`$smwgFieldTypeFeatures`](https://www.semantic-mediawiki.org/wiki/Help:$smwgFieldTypeFeatures) with `SMW_FIELDT_CHAR_NOCASE` to enable case insensitive search queries
+* [#2536](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2536) Added `SMW_FIELDT_CHAR_LONG` as flag for `$smwgFieldTypeFeatures` to extend the indexable length of blob and uri fields to max of 300 chars
+* [#2823](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2823) Added `SMW_QSORT_UNCONDITIONAL`
+* [#3080](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3080) Added warm up caching for the ID lookup
+* [#3142](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3142) Replaced `DISTINCT` with `GROUP BY` in `SQLStore::getPropertySubjects`
+* [#3261](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3261) Added support for index hint in `DataItemHandler` to enforce specific index selection
+* [#3314](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3314) Moved the `FIXED_PROPERTY_ID_UPPERBOUND` from 50 to 500 to increase the range for fixed property IDs
+* [#3353](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3353) Added support in SQLite to drop fields without the need to delete and restore the entire store
+* [#3360](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3360) In MySQL/MariaDB increase ID field size from "int(8)" to "int(11)". Postgres and SQLite have no size restriction.
+* [#3390](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3390) Adds the `smw_rev` field to the `smw_object_ids` table to track an entity instance and its associated revision ID (represents the raw content)
+* [#3397](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3397) MediaWiki removed `Database::nextSequenceValue` in commit wikimedia/mediawiki@0a9c55b#diff-278465351b7c14bbcadac82036080e9f. SMW added this functionality back for the sake of Postgres.
+
+#### ElasticStore
+
+* [#3054](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3054) Added `ElasticStore` to use Elasticsearch as query backend
+ - #3237, #3241, #3245, #3247, #3249, #3250, #3253
+* [#3152](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3152) Added extra debug query parameter (score_set, q_engine) to special page "Ask"
+
+### Search
+
+* [#2738](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2738) Added information whether `SMWSearch` search mode is enabled or not for special page "Search"
+* [#3006](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3006) Disabled default autocompletion for terms starting with `[[` in special page "Search" for the `SMWSearch` type
+* [#3096](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3096) Added section title display support to indicate subobjects
+* [#3126](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3126) Added extended power profile form
+* [#3143](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3143) Hides namespace section and add auto-discovery
+* [#3145](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3145) Added simplified term parser to `SMWSearch` (see #3157, #3281)
+* [#3234](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3234) Added support for displaytitle in `SearchResult`
+* [#3237](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3237) Added support for highlights from external search engine, if available
+* [#3419](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3419) Add search autocompletion options when `$wgSearchType = 'SMWSearch';`:
+ * `in:Foo bar` equivalent to `[[~~*Foo bar*]]`
+ * `phrase:Foo bar` equivalent to `[[~~"Foo bar"]]`
+ * `has:Foo bar` equivalent to `[[Foo bar::+]]`
+
+### Query
+
+* [#2398](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2398) Added `#ask` and `#show` parser function support for `@deferred` output mode (see also #3257)
+* [#2476](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2476) Added [`$smwgQExpensiveThreshold`](https://www.semantic-mediawiki.org/wiki/Help:$smwgQExpensiveThreshold) and [`$smwgQExpensiveExecutionLimit`](https://www.semantic-mediawiki.org/wiki/Help:$smwgQExpensiveExecutionLimit) to count and restrict expensive `#ask` and `#show` functions on a per page basis
+* [#2953](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2953) Added support for natural sort (`n-asc`, `n-desc`) of printout column values
+* [#2662](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2662) Added `+depth` as syntax component for a condition to restrict the depth of class and property hierarchy queries
+* [#2558](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2558) Added `like:` and `nlike:` comparator operator for approximate queries
+* [#2572](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2572) Added `@annotation` as special processing mode to embedded `#ask` queries
+* [#2673](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2673) Added the `Query state` special property to be able to track an internal state when a `#ask` uses `@annotation` or `@deferred` as special execution mode. In addition to internal usage, one can also now find all deferred queries with `{{#ask: [[Query state::200]] |format=ul }}`
+* [#2873](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2873) Added support for `in:` as expression to the #ask syntax
+* [#3125](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3125) Added support for `phrase:` as expression
+
+#### Result formats
+
+* [#2420](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2420) Added support for a datatable output in the `format=table` (and `broadtable`) result printer
+* [#2515](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2515) Added support for `#LOCL#TO` date formatting to display a [local time](https://www.semantic-mediawiki.org/wiki/Local_time) offset according to a user preferrence
+* [#2677](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2677) Added `+width` as parameter to the `format=table` (and `broadtable`) result printer
+* [#2690](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2690) Added the `type` parameter to `format=json` in support for a simple list export
+* [#2718](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2718) Added ad-hoc export for the `format=table` datatable
+* [#2824](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2824) Added `bom` as parameter to `format=csv`
+* [#2826](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2826) Added `valuesep` as parameter to `format=csv` to define a value separator
+* [#2822](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2822) Added add `merge` parameter to `format=csv`
+* [#2844](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2844) Renamed output formatter `#-ia` to `#-raw`
+* [#3024](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3024) Added `format=templatefile` to support individual export formats defined using MediaWiki templates
+* [#3009](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3009) Added `#tick` and `#num` output formatter to boolean value type
+* [#3011](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3011) Added the [`$smwgDefaultOutputFormatters`](https://www.semantic-mediawiki.org/wiki/Help:$smwgDefaultOutputFormatters) setting to declare default output formatter for a type or property
+* [#1315](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1315) Added support for media files to the `feed` printer
+* [#3130](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3130) Reworked `list` format
+* [#3162](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3162) Added support for `{{DISPLAYTITLE}}` to the `feed` printer
+* [#3136](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3136) Added `class` parameter to `list` format
+
+### API
+
+* [#2696](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2696) Added a new `smwbrowse` API module ([#2717](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2717), [#2719](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2719), [#2721](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2721))
+* [#3052](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3052) Added `api_version` to ask, askargs API
+* [#3129](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3129) Added API `pvalue` browse module
+* [#3381](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3381) Added API `psubject` browse module
+
+### Misc
+
+* [#794](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/794) Added `SMW_PARSER_UNSTRIP` to [`$smwgParserFeatures`](https://www.semantic-mediawiki.org/wiki/Help:$smwgParserFeatures) enabling to use unstripped content on a text annotation
+* [#2348](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2348) Allow showing annotations even if they are improper for datatype "Text"
+* [#2435](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2435) Added filtering of invisible characters (non-printable, shyness etc.) to armor against incorrect annotations
+* [#2453](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2453) Changed the approach on how referenced properties during an article delete are generated to optimize the update dispatcher
+* [#2471](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2471) Added [`SMW_CAT_REDIRECT`](https://www.semantic-mediawiki.org/wiki/Help:$smwgCategoryFeatures) option to allow finding redirects on categories
+* [#2494](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2494) Added [`$smwgChangePropagationProtection`](https://www.semantic-mediawiki.org/wiki/Help:$smwgChangePropagationProtection) and changed the approach on how property modifications are propagated
+* [#2543](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2543) Extended [`EditPageHelp`](https://www.semantic-mediawiki.org/wiki/Help:$smwgEnabledEditPageHelp) to be disabled using a user preference
+* [#2561](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2561) Added listing of improper assignments to the property page for an easier visual control
+* [#2595](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2595) Improved the content navigation in special page "SemanticMediaWiki"
+* [#2600](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2600) Added [`$smwgCreateProtectionRight`](https://www.semantic-mediawiki.org/wiki/Help:$smwgCreateProtectionRight) setting to control the creation of new properties and hereby annotations as part of the [authority mode](https://www.semantic-mediawiki.org/wiki/Help:Authority_mode)
+* [#2615](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2615) Added `filter=unapprove` to special page "WantedProperties"
+* [#2632](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2632) Added [uniqueness violation](https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness) check on the property page for the property label used
+* [#2699](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2699) Added an [input assistance](https://www.semantic-mediawiki.org/wiki/Help:Input_assistance) for the condition textbox on special page "Ask"
+* [#2726](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2726) Added entity [input assistance](https://www.semantic-mediawiki.org/wiki/Help:Input_assistance) for editors and the input field on special page "Search" ([#2756](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2756))
+* [#2776](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2776) Added tracking of changes to categories (see 2495)
+* [#2785](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2785) Added new styling to property page value list
+* [#2796](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2796) Allows "rendering of HTML" on special page "Ask" when using `|headers=plain` in queries
+* [#2801](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2801) Added `--skip-optimize` and `--skip-import` to `setupStore.php` (see 2516)
+* [#2803](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2803) Filter categories from transcluded content in `format=embedded`
+* [#2815](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2815) Added `#nowiki` support for external identifier type
+* [#2820](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2820) Added check on declarative property usage
+* [#2840](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2840) Added [`$smwgPropertyReservedNameList`](https://www.semantic-mediawiki.org/wiki/Help:$smwgPropertyReservedNameList) to define reserved property names
+* [#2842](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2842) Added [`$smwgURITypeSchemeList`](https://www.semantic-mediawiki.org/wiki/Help:$smwgURITypeSchemeList) to restrict valid URI scheme
+* [#2861](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2861) Added restriction for a property name that contains a CR, LF
+* [#2867](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2867) Added singular, plural category canonical check
+* [#2874](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2874) Added grouping support for properties to special page "Browse"
+* [#2875](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2875) Changed the theme on special page "Browse" to `smwb-theme-light`
+* [#2878](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2878) Added value filter to the property page
+* [#2883](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2883) Added function to special page "SemanticMediaWiki" to find duplicate entities
+* [#2889](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2889) Added method to make subobject sortkeys distinguishable
+* [#2891](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2891) Added flex (responsive) mode to special page "Ask" and special page "Browse" div table
+* [#2893](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2893) Changed special page "Ask" appearance ([#2898](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2898))
+* [#2895](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2895) Changed display of named subobject caption to appear without an underscore
+* [#2906](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2906) Added flex (responsive) mode to the factbox
+* [#2907](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2907) Added modal help to special page "Ask"
+* [#2913](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2913) Added a job queue watchlist feature and the [`$smwgJobQueueWatchlist`](https://www.semantic-mediawiki.org/wiki/Help:$smwgJobQueueWatchlist) setting
+* [#2922](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2922) Added `SMW_BROWSE_SHOW_SORTKEY` flag to the [`$smwgBrowseFeatures`](https://www.semantic-mediawiki.org/wiki/Help:$smwgBrowseFeatures) setting
+* [#2930](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2930) Added limit to value selection on the property page
+* [#2932](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2932) Added ["removeDuplicateEntities.php"](https://www.semantic-mediawiki.org/wiki/Help:Maintenance_script_removeDuplicateEntities.php) script to remove duplicate entities
+* [#2933](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2933) Added [`$smwgDefaultLoggerRole`](https://www.semantic-mediawiki.org/wiki/Help:$smwgDefaultLoggerRole) setting to define logging granularity for Semantic MediaWiki
+* [#2973](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2973) Set initial stats entry for non-fixed predefined properties
+* [#3017](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3017) Added the [`$smwgCompactLinkSupport`](https://www.semantic-mediawiki.org/wiki/Help:$smwgCompactLinkSupport) setting to compact links produced by special page "Ask" and special page "Browse"
+* [#3019](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3019) Added experimental support for the `SMW_NS_RULE` namespace
+* [#3020](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3020) Added the [keyword](https://www.semantic-mediawiki.org/wiki/Help:Type_Keyword) (`_keyw`) type
+* [#3029](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3029) Added function to keep updated entities in-memory to improve rebuild performance
+* [#3088](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3088) Modernized special page "Page property"
+* [#3167](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3167) Added support for `RemoteRequest` to share and consolidate query results from remote sources
+* [#3284](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3284) Added the `--dispose-outdated` flag to the "rebuildData.php" maintenance script
+* [#3289](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3289) Added support for the JSON format in the `Allows value list` definition
+* [#3292](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3292) Added support for bounded intervals, ranges in `Allows value` for number and quantity types
+* [#3293](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3293) Added tanslation page annotation (`_TRANS`) support
+* [#3308](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3308) Extended content representation on property and concept pages using tabs
+* [#3318](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3318) Added `smwgPostEditUpdate` to manage post edit event handling for seconday updates via the API interface
+* [#3319](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3319) Sets an extra parser key for queries that contain a self-reference to improve the result display after an edit event
+* [#3339](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3339) Added support for uniqueness validation in records/references
+* [#3416](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3416) Added support for `<section>` on property pages to put user-defined content into SMW-defined tabs
+* [#3415](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3415) Added "compact view" to hide query on special page "Ask"
+* [#3429](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3429) Changed default submit method of special page "Ask" to POST. Submit method can be modified by setting `$smwgSpecialAskFormSubmitMethod` to `SMW_SASK_SUBMIT_GET`, `SMW_SASK_SUBMIT_REDIRECT`, or explicitly setting the default `SMW_SASK_SUBMIT_POST`.
+* [#3431](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3431) Moved namespace "Rule" to namespace "smw/schema"
+* [#3436](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3436) When an entity is deleted, check for possible open references and keep the ID in case it has a residual reference by turning it into a simple object instance (setting `smw_rev` and `smw_proptable_hash` to null)
+* [#3440](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3440) Changed property pages to show the property usage count in the tab
+* [#3441](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3441) Added flags to maintenance script "rebuildData.php":
+ * `--revision-mode`: Skip entities where its associated revision matches the latests referenced revision of an associated page
+ * `--force-update`: Force an update even when an associated revision is known
+* [#3443](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3443) Changed job queue job names from `SMW\` prefix to `smw.` prefix. Example: `SMW\UpdateJob` -> `smw.update`
+
+## Bug fixes
+
+* [#481](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/481) Fixed "further results" link with special page "Ask" and templates
+* [#502](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/502) Fixed template with named arguments use in #show
+* [#839](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/839) Fixed and extended special page "Ask" to be more maintainable
+* [#2001](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2001) Fixed issue with `smw_subobject` and the generation of duplicate entities
+* [#2505](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2505) Fixed hard-coded default value for `format=csv`
+* [#2586](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2586) Fixed class assignments for empty cells in `format=table`
+* [#2621](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2621) Fixed sort/order field behaviour in special page "Ask"
+* [#2652](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2652) Fixed handling of multiple checkbox parameter in special page "Ask"
+* [#2817](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2817) Fixed Fix preg_replace ... unmatched parentheses
+* [#2871](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2871) Fixed PHP 7.2 `each` use in `SearchResultSet`
+* [#2881](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2881) Fixed display of display dispatched ID in `DataRebuilder`
+* [#2884](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2884) Fixed "Cannot use object of type MappingIterator as array"
+* [#2896](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2896) Fixed display of inverse indicator for translated predefined properties
+* [#2902](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2902) Fixed "LBFactory::getEmptyTransactionTicket ... does not have outer scope"
+* [#2909](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2909) Fixed use of `LBFactory::getEmptyTransactionTicket`
+* [#2915](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2915) Fixed connection instantiation
+* [#2917](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2917) Fixed "DataItemException ... Unserialization failed: the string ..."
+* [#2919](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2919) Fixed fetching all entities during a delete
+* [#2958](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2958) Fixed to mark subobject entities as done in `ExportController`
+* [#2963](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/2963) Fixed recognition of `$wgDBadminuser` in maintenance script "setupStore.php"
+* [#2969](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2969) Fixed PHP 7.2 "Warning: count(): Parameter must be an array or an object that implements Countable" issue
+* [#3000](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3000) Fixed fetching namespace aliases
+* [#3010](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3010) Fixed breaking links in an abbreviated text by the `StringValueFormatter`
+* [#3025](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3025) Fixed storage of query information during a `preview` activity
+* [#3026](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3026) Fixed replacement of `smw_proptable_hash` during setup
+* [#3031](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3031) Fixed duplicate entry `smw_prop_stats` exception
+* [#3033](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3033) Fixed "The supplied ParserOptions are not safe ... set $forceParse = true" during the upload of files
+* [#3049](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3049) Fixed concept selection
+* [#3067](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3067) Fixed processing of simple links containing `|` during the in-text annotation parsing
+* [#3076](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3076) Fixed factbox magic works
+* [#3082](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3082) Fixed use of `ParserOptions::setEditSection` for MW 1.31
+* [#3107](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3107) Fixed recognition of `::=` in `LinksProcessor `
+* [#3134](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3134) Escape `/` in property names
+* [#3144](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3144) Return IDs as integer when matching all entities
+* [#3336](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3336) Fixed issue in special page "Ask" with sort parameter where the first parameter is left empty
+* [#3322](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3322) Fixed issue in `UpdateDispatcherJob` with selecting unrelated entities
+* [#3336](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3336) Fixed special page "Ask" to recognize first empty sort parameter as page title, e.g. `|sort=,Has foo`
+* [#3375](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3375) Fixed error "Invalid sort: title. Must be one of: relevance". MediaWiki default sort type is only `relevance`. SMW added `title`, `recent`, and `best`.
+* [#3389](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3389) Fixed "Error: 23505 ERROR: duplicate key value violates unique constraint "smw_new_pkey"" by setting SQL temporary table `id` field to type `SERIAL` instead of `INTEGERY PRIMARY KEY`
+* [#3393](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3393) Fixed MW 1.31+ highlighter issue causing extra inline `<p>` which added newlines to display
+* [#3413](https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues/3413) Fixed a performance issue for maintenance script "rebuildData.php" by doing `SELECT` on pages+namespaces rather than just pages.
+
+## Breaking changes and deprecations
+
+* [#1345](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/1345) Setting multiple values to the `#set` and `#subobject` paser functions using pipe `|` is deprecated. Use the `+sep` parameter instead.
+* [#2495](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2495) `Store::getPropertySubjects` and `Store::getAllPropertySubjects` will return an `Iterator` instead of just an array
+* [#2588](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2588) Removed special page "SemanticStatistics"
+* [#2611](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2611) Removed the user preference `smw-ask-otheroptions-collapsed-info`
+* [#2640](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2640) Removed `$smwgAutocompleteInSpecialAsk`
+* [#2659](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2659) Removed deprecated constant `SMWDataItem::TYPE_STRING` (replaced by `SMWDataItem::TYPE_BLOB`)
+* [#2696](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2696) Soft deprecate the `browsebyproperty` API module, the new `smwbrowse` should be used instead
+* [#2705](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2705) Removed usages of deprecated `ResultPrinter::getParameters`
+* [#2724](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2724) Added `$smwgUseComparableContentHash` and will be removed with 3.1 to help migrating subobject hash generation
+* [#2730](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2730) Replaced `$smwgCacheUsage` settings
+* [#2732](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2732) Replaced `$smwgQueryProfiler` settings
+* [#2748](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2748) Removed `ContextSource` from `ResultPrinter` instances
+* [#2750](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2750) Removed `$smwgSparqlDatabaseMaster` and `$smwfGetSparqlDatabase`
+* [#2752](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2752) Renamed `$smwgSparqlDatabaseConnector` to `$smwgSparqlRepositoryConnector`
+* [#2761](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2761) Renamed `$smwgDeclarationProperties`
+* [#2768](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2768) Changed default setting for `$smwgSparqlRepositoryConnector`
+* [#2788](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2788) Resources are now being exported as Internationalized Resource Identifiers (IRI) by default.
+* [#2790](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2790) Removed deprecated entry points for maintenance scripts
+* [#2802](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2802) Consolidated `$smwgParserFeatures` setting
+* [#2806](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2806) Consolidated `$smwgCategoryFeatures` setting
+* [#2821](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2821) Consolidated `smwgQSortFeatures` setting
+* [#2841](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2841) Replaced `$smwgLinksInValues` with the `SMW_PARSER_LINV` flag now maintained in `$smwgParserFeatures`, PCRE option has been removed
+* [#2880](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2880) Migrated special property message keys to new naming schema
+* [#2899](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2899) Removed `$smwgScriptPath`
+* [#2927](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2927) Removed `SEMANTIC_EXTENSION_TYPE` flag
+* [#2944](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2944) Removed deprecated methods in `SMW\DIProperty`
+* [#2961](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2961) Renamed `smwAddToRDFExport` hook
+* [#2995](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2995) Updated old namespace in Spanish
+* [#3164](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3164) Removed `SMW_NS_TYPE` ns and `$smwgHistoricTypeNamespace`
+* [#3231](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3231) Consolidated `$smwgPagingLimit` setting
+* [#3267](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3267) Removed `SMWQueryProcessor::getSortKeys`
+* [#3285](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3285) Deprecated API module `BrowseBySubject`, use `smwbrowse` instead
+* [#3307](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3307) Replaced `smwgCacheType` with `smwgMainCacheType`
+* [#3315](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3315) Consolidated `smwgSparqlEndpoint` sparql endpoint setting
+* [#3366](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3366) Replaced deprecated alias `SMWDIProperty` with `DIProperty` in `SMWDataValue`
+* [#3364](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3364) Removed long-deprecated static functions `SMWWikiPageValue::makePage` and `SMWWikiPageValue::makePageFromTitle`
+* [#3363](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3363) Removed deprecated `ResultPrinter::$m_params`. Use `ResultPrinter::$params` instead.
+* [#3399](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3399) Removed several functions deprecated since SMW 1.9 from `SMW\DataValueFactory`
+* [#3401](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3401) Removed long-deprecated functions `ResultPrinter::textDisplayParameters` and `ResultPrinter::exportFormatParameters`
+* [#3403](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3403) Removed long-deprecated function `SMWResultArray::getNextObject`
+* [#3405](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3405) Removed long-deprecated SMWDIString
+* [#3406](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3406) Removed long-deprecated function `SMWRecordValue::getDV`
+* [#3407](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3407) Removed deprecated global function `smwfIsSemanticsProcessed`
+
+## Other changes
+
+* [#2342](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2342) Added the display of invalid data value annotations for datatype "Text"
+* [#2485](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2485) Disabled updates by the `QueryDependencyLinksStore` on a 'stashedit' activity
+* [#2491](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2491) Added `ChunkedIterator` to `DataRebuilder` to avoid OOM situations in case of a large update queue
+* [#2535](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2535) Fixed property namespace (`_wpp`) display in `WikiPageValue`
+* [#2540](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2540) Added type `parser-html` to [`JSONScript`](https://www.semantic-mediawiki.org/wiki/Help:Integration_tests) testing to allow assertions on HTML structure
+* [#2591](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2591) Discontinued reading MediaWiki `job` table, use the `JobQueue::getQueueSizes` instead
+* [#2609](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2609) Added check to special page "Ask" to require JavaScript
+* [#2631](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2631) Disabled purge button while JS resources are still loaded
+* [#2650](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2650) Replaced some styles in special page "Ask"
+* [#2653](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2653) Fixed `broadtable` width with the "MobileFrontend" extension
+* [#2676](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2676) Added support for column default values in the `TableBuilder`
+* [#2680](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2680) Added `null_count` column to `PropertyStatisticsTable`
+* [#2691](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2691) Replaced `#info` icon set
+* [#2698](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2698) Added persistent caching to the `HierarchyLookup`
+* [#2714](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2714) Added `SMW::GetPreferences` hook
+* [#2727](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2727) Moved parameter processing from `QueryProcessor` to `ParamListProcessor`
+* [#2745](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2745) Moved `ResultPrinter` base class
+* [#2747](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2747) Moved `TableResultPrinter`
+* [#2751](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2751) Added `RecursiveTextProcessor` to isolate `$wgParser` access in `ResultPrinter`
+* [#2765](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2765) Added `SMW::Setup::AfterInitializationComplete` hook
+* [#2774](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2774) Moved `SMWQueryParser` to `SMW\Query\Parser`
+* [#2783](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2783) Added `JsonSchemaValidator`
+* [#2785](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2785) Moved `PropertyPage` and `ConceptPage`
+* [#2845](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2845) Extended use of cached hierarchy instance
+* [#2847](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2847) Introduced different approach to update query dependencies
+* [#2888](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2888) Introduced `Setup::initExtension` to allow an early registration of `SpecialPage_initList` and `ApiMain::moduleManager` hooks
+* [#2908](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2908) Refactored the `ConnectionProvider`
+* [#2928](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2928) Moved `SQLStore::fetchSemanticData` to `SemanticDataLookup`
+* [#2972](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/2972) Added `SMW::SQLStore::EntityReferenceCleanUpComplete` hook
+* [#3032](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3032) Added the `SMW::LinksUpdate::ApprovedUpdate` and `SMW::Parser::ChangeRevision` hook
+* [#3061](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3061) Added detection of changes emitted by the `BlockIpComplete`, `UnblockUserComplete`, and `UserGroupsChanged` hook
+* [#3063](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3063) Moved import files to data folder
+* [#3070](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3070) Added `SMW::Admin::TaskHandlerFactory` hook
+* [#3131](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3131) Added `CONTENT_MODEL_RULE` to be able to do schema validation before a save sometime in the future. Switching to an alternate model at a later stage would only create headaches.
+* [#3138](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3138) Fixed use of `$wgExtensionDirectory` to find SMW's "extension.json"
+* [#3146](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3147) Moved table hash cache handling
+* [#3160](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3160) Moved `FeedExportPrinter` and added integration test
+* [#3260](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3260) Moved `SMWSQLStore3::changeSMWPageID`
+* [#3275](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3275) Moved `SMWSQLStore3Readers::getPropertySubjects`
+* [#3282](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3282) Moved `SMWSQLStore3Readers::getProperties`
+* [#3384](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3384) Isolated the handling of "ALTER SEQUENCE ..." for Postgres
+* [#3432](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3432) Moved `SMW\CategoryResultPrinter` to `SMW\Query\ResultPrinters\CategoryResultPrinter`
+
+## Contributors
+
+- 1036 - James Hong Kong
+- 147 - translatewiki.net for the translator community
+- 120 - Karsten Hoffmeyer
+- 50 - Jeroen De Dauw
+- 13 - Stephan Gambke
+- 7 - Kumioko
+- 6 - Iván
+- 6 - Zoran Dori
+- 4 - James Montalvo
+- 4 - Máté Szabó
+- 2 - Jaider Andrade Ferreira
+- 2 - Josef Konrad
+- 2 - TK-999
+- 1 - Amir E. Aharoni
+- 1 - C. Scott Ananian
+- 1 - Kunal Mehta
+- 1 - Peter Grassberger
+- 1 - Prateek Saxena
+- 1 - Stephan
+- 1 - Thiemo Kreuz
+- 1 - Timo Tijhof
+- 1 - Toni Hermoso Pulido
+- 1 - ka7
+- 1 - matthew-a-thompson
+- 1 - salle
+- 1 - غلامحسین حق دوست
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.1.md b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.1.md
new file mode 100644
index 00000000..7cdbfea1
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.1.md
@@ -0,0 +1,39 @@
+# Semantic MediaWiki 3.0.1
+
+Released on January 25, 2019.
+
+## Enhancements
+* [#3566](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3566) as `af04255`: Extended the array of permissive URI schemes of [configuration parameter `$smwgURITypeSchemeList`](https://www.semantic-mediawiki.org/wiki/Help:$smwgURITypeSchemeList)
+* [#3596](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3596) as `a6ccc2a`: Added [`$smwgConfigFileDir` configuration parameter](https://www.semantic-mediawiki.org/wiki/Help:$smwgConfigFileDir) allowing to specify the location for the [setup information file](https://www.semantic-mediawiki.org/wiki/Help:Setup_information_file)
+* [#3597](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3597) as `c92b2ca`: Extended and improved information on the ["Upgrade Error Screen"](https://www.semantic-mediawiki.org/wiki/Help:Upgrade/Upgrade_and_setup_consistency) and made it localizable
+* [#3611](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3611) as `8f1177a`: Added ["populateHashField.php" maintenance script](https://www.semantic-mediawiki.org/wiki/Help:Maintenance_script_populateHashField.php) to decouple mass conversions of database field "smw_hash" in the "smw_objects_ids" database table when upgrading the database for large wikis
+* Many new translations for numerous languages by the communtity of [translatewiki.net](https://translatewiki.net/w/i.php?title=Special%3AMessageGroupStats&x=D&group=mwgithub-semanticmediawiki&suppressempty=1)
+
+## Bug fixes and internal code changes
+* [#3565](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3565) as `6f24bf6`: Added missing system message for the "templatefile" format
+* [#3572](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3572) as `70f629e`: Fixed `HtmlForm::getForm` to support a string as result on special page "Ask"
+* [#3573](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3573) as `a59c76c`: Modified tests to avoid "Call to a member function getSchema() on null" for MediaWiki 1.32 and later
+* [#3578](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3578) as `484a4b5`: Made indexer apply `pg_unescape_bytea` for bytea/blob values on postgres
+* [#3584](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3584) as `1205b87`: Added pipe detection in printrequest labels (`[[ ... | ... ]]`)
+* [#3585](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3585) as `5d6d6ff`: Fixed "`strpos()`: Non-string needles ..." for PHP 7.3 and later
+* [#3586](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3586) as `53655ed`: Fixed `#set_recurring_event` parser function to respect related configuration parameters and their settings
+* [#3595](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3595) as `e9ed65e`: Fixed invalid user names using the mandatory interwiki prefix for MediaWiki 1.31 and later by unlinking them
+* [#3599](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3599) as `732ef23`: Fixed "`fputcsv` ... delimiter must be a single character" for the "csv" format
+* [#3607](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3607) as `4d9e5a7`: Fixed `#set_recurring_event` parser function to cause "Call to undefined method `SMWDIError::getJD()`"
+* [#3608](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3608) as `b17526d`: Fixed "QueryResultSerializer" to handle `_qty` on chained properties
+* [#3609](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3609) as `c005c6f`: Restored use of `$wgDBTableOptions` configuration parameter
+* [#3616](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3616) as `4b0cfb7`: Made `isCapitalLinks` be set in `_wpg` description context
+* [#3617](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3617) as `9152f94`: Made "SemanticDataLookup", use `DISTINCT` for non subject items
+* [#3622](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3622) as `cfbd338`: Fixed `#set_recurring_event` parser function to allow monthly events start on a 30th and 31st of a month
+* [#3628](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3628) as `e587291`: Improved commandline prompts for maintenance script "populateHashField.php"
+* [#3630](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3630) as `79aee30`: Added extra _uri validation for `http:///`
+* [#3631](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3631) as `0903c1b`: Fixed `ResultFormatNotFoundException` on untrimmed format strings
+* [#3632](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3632) as `24d8bae`: Changed to using `0x003D` instead of `-3D` to encode `=`
+* [#3633](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3633) as `f70339a`: Made the container subject be used as context to check uniqueness constaints
+* [#3634](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3634) as `711e365`: Made "WikiPageValue" use the provided fixed namespace
+* [a5a4a0d](https://github.com/SemanticMediaWiki/SemanticMediaWiki/commit/a5a4a0d1b05eb622749fe59a1d2be4be699aaed4) as `bea16a5`: Fixed "PHP Notice: Uncommitted DB writes (transaction from ...)"
+* [8bc4443](https://github.com/SemanticMediaWiki/SemanticMediaWiki/commit/8bc4443a6a48682e74e94a014adfcd91cb6104a5) as `5a729d4`: Fixed `get_headers` can return `false`
+* [8ca1ec0](https://github.com/SemanticMediaWiki/SemanticMediaWiki/commit/8ca1ec05ef56144b1991c0381696a52687e39ed4) as `93cf100`: Made "PHP Warning: Class '`SMW\CategoryResultPrinter`' not found in ... Aliases.php" be avoided
+
+## See also
+* [RELEASE NOTES](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/3.0.x/docs/releasenotes/RELEASE-NOTES-3.0.0.md) for Semantic MediaWiki 3.0.0
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.2.md b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.2.md
new file mode 100644
index 00000000..36557b5c
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/releasenotes/RELEASE-NOTES-3.0.2.md
@@ -0,0 +1,24 @@
+# Semantic MediaWiki 3.0.2
+
+Released on April 11, 2019.
+
+## Enhancements
+
+* [#3682](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3682) as `f5d0cab`: Removed `IsFileCacheable` hook and improves file caching
+* [#3856](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3854) as `767c981`: Switched setting of configuration parameter "$smwgCompactLinkSupport" to "false"
+
+## Bug fixes and internal code changes
+
+* [#3742](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3742): Fixed raw output of templated message particles
+* [#3771](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3771) as `b7a78e0`: Removed `doPostOutputShutdown`
+* [#3772](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3772) as `79e4adb`: Fixed "... expects parameter 1 to be a valid callback ..."
+* [#3775](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3775) as `3b0d83c`: Made data type "Equivalent URI" non declarative
+* [#3847](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3847) as `d088204`: Fixed warning "a non-numeric value" was encountered
+* [#3854](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3854) as `d05671e`: Provided a new test case for "display title"
+* [#3859](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3859): Updated "InfolinkTest"
+* [#3863](https://github.com/SemanticMediaWiki/SemanticMediaWiki/pull/3863): Fixed resource loading by replacing `localpath` with `localBasePath`
+* [0ed4bbf7](https://github.com/SemanticMediaWiki/SemanticMediaWiki/commit/0ed4bbf75e7ee9989d2ac84437d3733b52885eb8): Updated "EventHandlerTest"
+
+## See also
+* [RELEASE NOTES](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/3.0.x/docs/releasenotes/RELEASE-NOTES-3.0.0.md) for Semantic MediaWiki 3.0.0
+* [RELEASE NOTES](https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/3.0.x/docs/releasenotes/RELEASE-NOTES-3.0.1.md) for Semantic MediaWiki 3.0.1
diff --git a/www/wiki/extensions/SemanticMediaWiki/docs/technical/code-snippets/approve.update.md b/www/wiki/extensions/SemanticMediaWiki/docs/technical/code-snippets/approve.update.md
index 7e774672..1be387b5 100644
--- a/www/wiki/extensions/SemanticMediaWiki/docs/technical/code-snippets/approve.update.md
+++ b/www/wiki/extensions/SemanticMediaWiki/docs/technical/code-snippets/approve.update.md
@@ -1,4 +1,3 @@
-
For certain user scenarios it may be necessary to refuse or alter an update by changing the revision used as basis for what the semantic data should represent.
Please ensure that when changes are applied to [log][log] those to make them recoverable. See [`$wgLogTypes`][wgLogTypes] on how to add and use an appropriate type and action description.
@@ -69,7 +68,7 @@ Hooks::register( 'SMW::Parser::ChangeRevision', function( $title, &$revision ) {
}
// Forcibly change the revision to match the approved version
- $currentRevison = $revision;
+ $currentRevision = $revision;
$revision = Revision::newFromId( $approvedRevID );
$log = new LogPage( 'myType' );
diff --git a/www/wiki/extensions/SemanticMediaWiki/extension.json b/www/wiki/extensions/SemanticMediaWiki/extension.json
index e313c5b6..6224eaa3 100644
--- a/www/wiki/extensions/SemanticMediaWiki/extension.json
+++ b/www/wiki/extensions/SemanticMediaWiki/extension.json
@@ -1,6 +1,6 @@
{
"name": "SemanticMediaWiki",
- "version": "3.0.0",
+ "version": "3.0.2",
"author": [
"[http://korrekt.org Markus Krötzsch]",
"[https://www.mediawiki.org/wiki/User:Jeroen_De_Dauw Jeroen De Dauw]",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ar.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ar.json
index ffcb0d1d..793e0974 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ar.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ar.json
@@ -21,12 +21,19 @@
},
"smw-desc": "تقرّب الويكي إلى كلٍّ من النّظم الحاسوبية ''و'' البشر ([https://www.semantic-mediawiki.org/wiki/Help:User_manual دليل المستخدم])",
"smw-title": "ميدياويكي الدلالية",
+ "smw-upgrade-error": "تم تثبيت وتمكين ميدياويكي الدلالي لكنه يفتقد إلى [https://www.semantic-mediawiki.org/wiki/Help:Upgrade مفتاح ترقية] مناسب يتطابق مع: <code>$1</code>.",
+ "smw-upgrade-error-why-title": "لماذا أرى هذا الخطأ؟",
+ "smw-upgrade-error-why-explain": "لقد تغير هيكل قاعدة البيانات الداخلية في ميدياويكي ويتطلب بعض التعديلات لكي تعمل بكامل طاقتها، يمكن أن يكون هناك العديد من الأسباب بما فيها: \n* تمت إضافة خصائص مرممة إضافية (يتطلب إعداد جدول إضافي) \n* تحتوي الترقية على بعض التغييرات على الجداول أو الفهارس التي تقوم بإجراء اعتراض إلزامي قبل الوصول إلى البيانات",
+ "smw-upgrade-error-how-title": "كيف أقوم بإصلاح هذا الخطأ؟",
+ "smw-upgrade-error-how-explain": "يجب على الإداري (أو أي شخص لديه صلاحيات الإداري) أن يدير سكريبت الصيانة [https://www.mediawiki.org/wiki/Manual:Update.php update.php] بميدياويكي أو [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] بميدياويكي الدلالي، يمكنك أيضا الرجوع إلى الصفحات التالية للمزيد من المساعدة:\n* تعليمات [https://www.semantic-mediawiki.org/wiki/Help:Installation التثبيت]\n* صفحة المساعدة [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting استكشاف الأخطاء وإصلاحها]",
"smw-semantics-not-enabled": "لم يتم تمكين وظائف ميدياويكي الدلالي لهذا الويكي.",
"smw_viewasrdf": "تلقيمة RDF",
"smw_finallistconjunct": " و",
"smw-factbox-head": "...المزيد عن \"$1\"",
"smw-factbox-facts": "حقائق",
"smw-factbox-facts-help": "يعرض البيانات والحقائق التي تم إنشاؤها بواسطة مستخدم",
+ "smw-factbox-attachments": "المرفقات",
+ "smw-factbox-attachments-help": "يعرض المرفقات المتاحة",
"smw-factbox-facts-derived": "حقائق مشتقة",
"smw-factbox-facts-derived-help": "يعرض الحقائق التي تم استخلاصها من القواعد أو بمساعدة تقنيات التفكير الأخرى",
"smw_isspecprop": "هذه خصيصة مميَّزة في هذه الويكي.",
@@ -116,6 +123,7 @@
"smw-paramdesc-feeddescription": "نصُّ وصف التلقيمة",
"smw-paramdesc-feedpagecontent": "محتوى الصفحة المعروض مع التلقيمة",
"smw-label-feed-description": "تلقيمة $2 $1",
+ "smw-paramdesc-mimetype": "نوع الوسائط (نوع MIME) لملف الإخراج",
"smw_iq_disabled": "الاستعلامات الدلالية مُعطّلة في هذه الويكي.",
"smw_iq_moreresults": "…مزيد من النتائج",
"smw_parseerror": "القيمة المعطاة لم يتم فهمها.",
@@ -327,9 +335,9 @@
"smw_smwadmin_updatenotstopped": "لوقف عملية التحديث الجارية يجب عليك التأشير في الصندوق للتوكيد.",
"smw-admin-docu": "هذه الصفحة الخاصة تساعدك خلال تنصيب وترقية وصيانة واستخدام < href=\"https://www.semantic-mediawiki.org\">ميدياويكي الدلالية</a>\nوتوفر أيضًا المزيد من الوظائف والمهام الإدارية وكذلك إحصاءات.\nتذكر أن تحفظ احتياطيا البيانات القيمة قبل إجراء وظائف إدارية",
"smw-admin-environment": "بيئة البرمجيات",
- "smw-admin-db": "صيانة قاعدة البيانات",
+ "smw-admin-db": "إعداد قاعدة البيانات",
"smw-admin-db-preparation": "تهيئة الجدول مستمرة وربما تستغرق ثانية قبل عرض نتائج بانتظار الحجم والتحسينات الممكنة للجدول.",
- "smw-admin-dbdocu": "ميدياويكي الدلالية تتطلب تمديد قاعدة بيانات ميدياويكي لأجل تخزين البيانات الدلالية.\nالوظيفة التالية تتحقق من أن قاعدة البيانات منصبة على نحو صحيح.\nالتغييرات المجراة في هذه الخطوة لا تؤثر على بقية قاعدة بيانات ميدياويكي، ويمكن عكسها بسهولة في حالة الرغبة في ذلك.\nوظيفة التنصيب هذه يمكن إجراؤها عدة مرات بلا ضرر، لكنها ليست مطلوبة سوى لمرة واحدة عند التنصيب أو الترقية.",
+ "smw-admin-dbdocu": "يتطلب ميدياويكي الدلالي بنية قاعدة البيانات الخاصة به (وهي مستقلة عن ميدياويكي وبالتالي لا تؤثر على بقية تثبيت ميدياويكي) من أجل تخزين البيانات الدلالية. \nيمكن تنفيذ وظيفة الإعداد هذه عدة مرات دون إلحاق أي ضرر، ولكنها مطلوبة مرة واحدة فقط عند التثبيت أو الترقية.",
"smw-admin-permissionswarn": "إذا فشلت العملية بأخطاء SQL، مستخدم قاعدة البيانات المستخدمة من قبل الويكي الخاص بك (تحقق من ملف \"LocalSettings.php\" الخاص بك) ربما ليست لديه صلاحيات كافية;\nامنح هذا المستخدم صلاحيات إضافية لإنشاء الجداول وحذفها أو إدخال تسجيل الدخول لجذر قاعدة البيانات مؤقتا في ملف \"LocalSettings.php\"، أو استخدام كود الصيانة <code>setupStore.php</code>، والذي يمكنه استخدام بيانات الاعتماد من إداري.",
"smw-admin-dbbutton": "تهيئة أو ترقية الجداول",
"smw-admin-announce": "أعلن عن هذه الويكي",
@@ -356,7 +364,7 @@
"smw_smwadmin_datarefreshbutton": "إعادة بناء بيانات الجدول الزمني",
"smw_smwadmin_datarefreshstop": "أوقف هذا التحديث",
"smw_smwadmin_datarefreshstopconfirm": "نعم، أنا {{GENDER:$1|متأكد|متأكدة}}.",
- "smw-admin-job-scheduler-note": "يتم تنفيذ معظم الأنشطة في هذا القسم كوظائف لتجنب حالات توقف تام أثناء التنفيذ، تعد [https://www.mediawiki.org/wiki/Manual:Job_queue جدولة المهام] مسؤولة عن المعالجة، ومن الأهمية بمكان أن يكون سكريبت الصيانة <code>runJobs.php</code> (انظر أيضا وسيط التكوين <code>$wgRunJobsAsync</code>) لديه قدرة مناسبة.",
+ "smw-admin-job-scheduler-note": "يتم تنفيذ المهام (التي تم تمكينها) في هذا القسم من خلال قائمة انتظار المهام لتجنب حالات توقف تام أثناء تنفيذها، [https://www.mediawiki.org/wiki/Manual:Job_queue قائمة انتظار المهام] هي المسئولة عن المعالجة ومن الأهمية بمكان أن سكريبت الصيانة <code>runJobs.php</code> لديه سعة مناسبة (راجع أيضا وسيط التكوين <code>$wgRunJobsAsync</code>).",
"smw-admin-outdateddisposal-title": "التخلص من الكيانات التي عفا عليها الزمن",
"smw-admin-outdateddisposal-intro": "بعض الأنشطة (تغيير نوع الخاصية، أو إزالة صفحات الويكي، أو تصحيح قيم خاطئة) ينتج في [https://www.semantic-mediawiki.org/wiki/Outdated_entities الكيانات التي عفا عليها الزمن] وتُقترَح إزالتها بشكل دوري لتحرير مساحة الجدول المرتبط.",
"smw-admin-outdateddisposal-active": "لقد تمت جدولة مهمة التخلص من الكيانات القديمة.",
@@ -378,7 +386,7 @@
"smw-admin-questions": "إذا كانت لديك أسئلة أو اقتراحات أخرى، فيمكنك الانضمام إلى مناقشة <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">القائمة البريدية للمستخدم</a> أو <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">غرف الدردشة</a> في ميدياويكي الدلالي.",
"smw-admin-other-functions": "وظائف أخرى",
"smw-admin-supplementary-section-title": "وظائف إضافية",
- "smw-admin-supplementary-section-subtitle": "الوظائف المتاحة",
+ "smw-admin-supplementary-section-subtitle": "الوظائف الأساسية",
"smw-admin-supplementary-section-intro": "يوفر هذا القسم وظائف إضافية خارج نطاق الصيانة ومن الممكن أن تكون بعض الوظائف المدرجة في [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions التوثيق] مقيدة أو غير متاحة وبالتالي لا يمكن الوصول إليها في هذا الويكي.",
"smw-admin-supplementary-settings-title": "إعدادات التكوين",
"smw-admin-supplementary-settings-intro": "<u>$1</u> مخرجات القائمة الجماعية بالإعدادات المتاحة المستخدمة في ميدياويكي الدلالي",
@@ -393,9 +401,10 @@
"smw-admin-supplementary-operational-statistics-cache-title": "إحصائيات ذاكرة التخزين المؤقت",
"smw-admin-supplementary-operational-statistics-cache-intro": "يعرض <u>$1</u> إحصائيات متعلقة بذاكرة التخزين المؤقت",
"smw-admin-supplementary-elastic-title": "بحث مرن",
- "smw-admin-supplementary-elastic-intro": "<u>$1</u> يُعلم عن إعدادات وإحصائيات الفهرس",
+ "smw-admin-supplementary-elastic-section-subtitle": "وظائف إلاستيك سيرش",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> يظهر عن إعدادات وإحصائيات الفهرس",
"smw-admin-supplementary-elastic-docu": "تحتوي هذه الصفحة على معلومات حول الإعدادات والتعيينات والصحة وإحصائيات الفهرس المتعلقة بمجموعة البحث المرن المرتبطة بميدياويكي الدلالي و[https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
- "smw-admin-supplementary-elastic-functions": "الوظائف المتاحة",
+ "smw-admin-supplementary-elastic-functions": "الوظائف المدعومة",
"smw-admin-supplementary-elastic-settings-title": "إعدادات",
"smw-admin-supplementary-elastic-settings-intro": "تُستخدَم <u>$1</u> بواسطة البحث المرن لإدارة فهارس ميدياكيكي الدلالي",
"smw-admin-supplementary-elastic-mappings-title": "التعيينات",
@@ -510,9 +519,22 @@
"smw-admin-objectid": "معرف:",
"smw-admin-tab-general": "نظرة عامة",
"smw-admin-tab-notices": "إشعارات انتقاص",
- "smw-admin-tab-rebuild": "صيانة",
+ "smw-admin-tab-maintenance": "الصيانة",
"smw-admin-tab-supplement": "وظائف إضافية",
"smw-admin-tab-registry": "سجل",
+ "smw-admin-maintenance-no-description": "بدون وصف.",
+ "smw-admin-maintenance-script-section-title": "قائمة سكريبتات الصيانة المتاحة",
+ "smw-admin-maintenance-script-section-intro": "تتطلب سكريبتات الصيانة التالية إداريا والوصول إلى سطر الأوامر لتتمكن من تنفيذ السكريبتات المدرجة.",
+ "smw-admin-maintenance-script-description-dumprdf": "تصدير RDF الثلاثي الحالي.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "يتم استخدام هذا السكريبت في إدارة مخابئ المفاهيم لميدياويكي الدلالي حيث يمكن إنشاء، وإزالة ، وتحديث ذاكرات مختارة.",
+ "smw-admin-maintenance-script-description-rebuilddata": "يعيد إنشاء جميع البيانات الدلالية في قاعدة البيانات، عن طريق ركوب الدراجات من خلال جميع الصفحات التي قد تحتوي على بيانات دلالية.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "يعيد إنشاء فهرس إلاستيك سيرش (للمنشآت التي تستخدم <code>ElasticStore</code>)، عن طريق ركوب الدراجات من خلال جميع الكيانات التي لديها بيانات دلالية.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "يعيد بناء فهرس البحث في النص الكامل <code>SQLStore</code> (لعمليات التثبيت حيث تم تمكين الإعداد.",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "يعيد بناء إحصائيات الاستخدام لجميع كيانات الخواص.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "يزيل الكيانات المكررة الموجودة في الجداول المحددة التي لا تحتوي على مراجع نشطة.",
+ "smw-admin-maintenance-script-description-setupstore": "يقوم بإعداد خلفية التخزين المحددة في <code>LocalSettings.php</code>.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "يحدث الحقل <code>smw_sort</code> في <code>SQLStore</code> (وفقا لإعداد [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation $smwgEntityCollation]).",
+ "smw-admin-maintenance-script-description-populatehashfield": "يعبئ حقل <code>smw_hash</code> للصفوف التي تفتقد إلى القيمة.",
"smw-livepreview-loading": "جارٍ التحميل...",
"smw-sp-searchbyproperty-description": "توفر هذه الصفحة [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces واجهة تصفح] بسيطة للعثور على كيانات تم وصفها بواسطة خاصية وقيمة مسماة، تتضمن واجهات البحث الأخرى المتاحة [[Special:PageProperty|صفحة بحث الخصائص]]، و[[Special:Ask|اطلب منشئ استعلام]].",
"smw-sp-searchbyproperty-resultlist-header": "قائمة النتائج",
@@ -636,6 +658,7 @@
"smw-property-predefined-askco": "\"$1\" خاصية محددة مسبقا يقدمها [https://www.semantic-mediawiki.org/wiki/Help:Special_properties ميدياويكي الدلالي] لوصف حالة الاستعلام أو مكوناته.",
"smw-property-predefined-long-askco": "يمثل الرقم أو الأرقام المعينة حالة مقننة داخلية يتم شرحها في [https://www.semantic-mediawiki.org/wiki/Help:Query_profiler صفحة المساعدة].",
"smw-property-predefined-prec": "\"$1\" خاصية محددة مسبقا تصف [https://www.semantic-mediawiki.org/wiki/Help:Display_precision دقة العرض] (بالأرقام العشرية) لأنواع البيانات الرقمية.",
+ "smw-property-predefined-attch-link": "\"$1\" هي خاصية محددة مسبقا تجمع روابط الملفات والملفات المضمنة الموجودة في الصفحة ويتم توفيرها من خلال [https://www.semantic-mediawiki.org/wiki/Help:Special_properties ميدياويكي الدلالي].",
"smw-types-extra-geo-not-available": " لم يتم الكشف عن [https://www.semantic-mediawiki.org/wiki/Extension:Maps تمديد \"الخرائط\"] وبالتالي يقتصر \"$1\" على قدرته على العمل.",
"smw-datavalue-monolingual-dataitem-missing": "عنصر متوقع لبناء قيمة مجمع أحادي اللغة مفقود.",
"smw-datavalue-languagecode-missing": "بالنسبة للتعليق التوضيحي \"$1\"، لم يتمكن المحلل من تحديد رمز اللغة (أي \"foo@en\").",
@@ -773,6 +796,7 @@
"smw-property-reserved-category": "تصنيف",
"smw-category": "التصنيف",
"smw-datavalue-uri-invalid-scheme": "لم يتم إدراج \"$1\" كمخطط URI صالح.",
+ "smw-datavalue-uri-invalid-authority-path-component": "\"$1\" تم التعرف عليه كمحتوي على مكون سلطة أو مسار غير صحيح \"$2\".",
"smw-browse-property-group-title": "مجموعة الخصائص",
"smw-browse-property-group-label": "تسمية مجموعة الخصائص",
"smw-browse-property-group-description": "وصف مجموعة الخصائص",
@@ -825,5 +849,8 @@
"smw-ask-tab-result": "النتيجة",
"smw-ask-tab-extra": "إضافات",
"smw-ask-tab-debug": "تصحيح",
- "smw-ask-tab-code": "كود"
+ "smw-ask-tab-code": "كود",
+ "smw-install-incomplete-intro": "تنصيب (أو ترقية) <b>Semantic MediaWiki</b> لم ينتهي وينبغي على أحد الإداريين تنفيذ المهام التالية لمنع عدم تناسق البيانات قبل أن يواصل المستخدمون إنشاء أو تعديل المحتوى.",
+ "smw-install-incomplete-populate-hash-field": "ملء حقل <code>smw_hash</code> تم تجاهله أثناء التنصيب، سكريبت [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php] مطلوب للتنفيذ.",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ast.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ast.json
index 525412eb..0f234264 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ast.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ast.json
@@ -487,7 +487,6 @@
"smw-admin-objectid": "Identificador:",
"smw-admin-tab-general": "Supervisión",
"smw-admin-tab-notices": "Avisos de desusu",
- "smw-admin-tab-rebuild": "Caltenimientu",
"smw-admin-tab-supplement": "Funciones suplementaries",
"smw-admin-tab-registry": "Rexistru",
"smw-livepreview-loading": "Cargando...",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/be-tarask.json b/www/wiki/extensions/SemanticMediaWiki/i18n/be-tarask.json
index 5da04217..8a13b673 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/be-tarask.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/be-tarask.json
@@ -17,6 +17,7 @@
"smw_finallistconjunct": " і",
"smw-factbox-head": "… болей пра «$1»",
"smw-factbox-facts": "Факты",
+ "smw-factbox-facts-derived": "Атрыманыя факты",
"smw_isspecprop": "Гэтая ўласьцівасьць зьяўляецца спэцыяльнай у {{GRAMMAR:месны|{{SITENAME}}}}.",
"smw-concept-cache-header": "Выкарыстаньне кэшу",
"smw-concept-no-cache": "Кэш адсутнічае.",
@@ -60,6 +61,7 @@
"smw-paramdesc-template": "Назва шаблёну, які будзе выкарыстоўвацца для вываду вынікаў",
"smw-paramdesc-columns": "Колькасьць слупкоў, у якіх будуць паказвацца вынікі",
"smw-paramdesc-userparam": "Значэньне, якое перадаецца ў кожны выклік шаблёну, калі ён выкарыстоўваецца",
+ "smw-paramdesc-class": "Дадатковая кляса CSS, каб задаць сьпіс табліцы",
"smw-paramdesc-introtemplate": "Назва шаблёну для паказу перад вынікамі запыту, калі яны ёсьць",
"smw-paramdesc-outrotemplate": "Назва шаблёну для паказу пасьля вынікаў запыту, калі яны ёсьць",
"smw-paramdesc-embedformat": "Тэг HTML, які выкарыстоўваецца для вызначэньня загалоўкаў",
@@ -72,17 +74,23 @@
"smw-paramdesc-dsv-filename": "Назва DSV-файла",
"smw-paramdesc-filename": "Назва зыходнага файлу",
"smw-smwdoc-description": "Паказвае табліцу з усімі парамэтрамі, якія могуць ужывацца для выбранага фармату вынікаў разам з значэньнямі па змоўчваньні і апісаньнямі.",
+ "smw-smwdoc-default-no-parameter-list": "Гэты фармат выніку не забясьпечвае спэцыфічныя парамэтры.",
"smw-smwdoc-par-format": "Фармат вынікаў для паказу дакумэнтацыі пра парамэтры.",
"smw-paramdesc-sort": "Уласьцівасьць, паводле якой сартаваць запыт",
"smw-paramdesc-order": "Парадак сартаваньня запыту",
"smw-paramdesc-searchlabel": "Тэкст для працягу пошуку",
+ "smw-paramdesc-named_args": "Назвы аргумэнтаў, перададзеных у шаблён",
"smw-paramdesc-export": "Налады імпарту",
"smw-paramdesc-json-type": "Тып сэрыялізацыі",
"smw-paramdesc-source": "Альтэрнатыўная крыніца запыту",
"smw-paramdesc-jsonsyntax": "Сынтаксыс JSON для выкарыстаньня",
"smw-printername-feed": "Канал RSS і Atom",
"smw-paramdesc-feedtype": "Тып каналу",
+ "smw-paramdesc-feedtitle": "Тэкст, які будзе скарыстаны ў якасьці назвы каналу",
+ "smw-paramdesc-feeddescription": "Тэкст, які будзе скарыстаны ў якасьці апісаньня каналу",
+ "smw-paramdesc-feedpagecontent": "Зьмест старонкі, які будзе адлюстроўвацца на канале",
"smw-label-feed-description": "Канал $1 $2",
+ "smw-paramdesc-mimetype": "Тып мэдыя (MIME-тып) для зыходнага файлу",
"smw_iq_disabled": "Сэмантычныя запыты былі выключаны ў {{GRAMMAR:месны|{{SITENAME}}}}.",
"smw_iq_moreresults": "… наступныя вынікі",
"smw_parseerror": "Пададзенае значэньне не было распазнанае.",
@@ -150,9 +158,19 @@
"wantedproperties": "Запатрабаваныя ўласьцівасьці",
"smw-wantedproperties-docu": "Гэтая старонка ўтрымлівае [https://www.semantic-mediawiki.org/wiki/Wanted_properties запатрабаваныя ўласьцівасьці], якія ўжываюцца ў вікі, але ня маюць старонкі з апісаньнем. Для дыфэрэнцаванага выгляду, глядзіце [[Special:Properties|агульную спэцыяльную старонку]] або [[Special:UnusedProperties|старонку неўжываных уласьцівасьцяў]].",
"smw-wantedproperty-template": "$1 ($2 {{PLURAL:$2|выкарыстаньне|выкарыстаньні|выкарыстаньняў}})",
+ "smw-special-wantedproperties-template": "$1 ($2 {{PLURAL:$2|выкарыстаньне|выкарыстаньні|выкарыстаньняў}})",
"smw_purge": "Абнавіць",
"types": "Тыпы",
"smw_types_docu": "Сьпіс [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes даступных тыпаў зьвестак], у якім кожны [https://www.semantic-mediawiki.org/wiki/Help:Datatype тып] зьяўляецца наборам атрыбутаў для апісаньня значэньняў з пункту гледжаньня захоўваньня і адлюстраваньня характарыстык, якія паходзяць ад прызначанай уласьцівасьці.",
+ "smw-statistics-property-instance": "{{PLURAL:$1|1=Значэньне|Значэньні|Значэньняў}} уласьцівасьці (агулам)",
+ "smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|1=Значэньне|Значэньні|Значэньняў}}]] (агулам)",
+ "smw-statistics-property-total-legacy": "{{PLURAL:$1|1=Уласьцівасьць|Уласьцівасьці|Уласьцівасьцяў}} (агулам)",
+ "smw-statistics-property-used": "[[Special:Properties|{{PLURAL:$1|1=Уласьцівасьць|Уласьцівасьці|Уласьцівасьцяў}} (агулам)]] (ужытая з прынамсі адным значэньнем)",
+ "smw-statistics-property-page": "{{PLURAL:$1|1=Уласьцівасьць|Уласьцівасьці|Уласьцівасьцяў}} ({{PLURAL:$1|1=зарэгістраваная|зарэгістраваныя|зарэгістраваных}} са старонкай)",
+ "smw-statistics-property-type": "{{PLURAL:$1|1=Уласьцівасьць|Уласьцівасьці|Уласьцівасьцяў}} ({{PLURAL:$1|1=прысвоеная|прысвоеныя|прысвоеных}} тыпу зьвестак)",
+ "smw-statistics-query-inline-legacy": "{{PLURAL:$1|Запыт|Запыты|Запытаў}}",
+ "smw-statistics-query-inline": "[[Property:Has query|{{PLURAL:$1|Запыт|Запыты|Запытаў}}]]",
+ "smw-statistics-query-size": "Памер запыту",
"smw_uri_doc": "Пераўтваральнік URI ажыцьцяўляе [$1 пошук W3C TAG у httpRange-14].\nГэта забясьпечвае ўпэўненасьць, што людзі не заходзяць на сайты.",
"ask": "Сэмантычны пошук",
"smw_ask_sortby": "Сартаваць па слупку (неабавязкова)",
@@ -190,6 +208,8 @@
"smw-ask-input-assistance": "Дапамога пры ўводзе",
"searchbyproperty": "Шукаць па ўласьцівасьці",
"processingerrorlist": "Сьпіс памылак апрацоўкі",
+ "propertylabelsimilarity": "Паведамленьне аб падобнасьці назваў уласьцівасьцяў",
+ "smw-processingerrorlist-intro": "Наступны сьпіс забясьпечвае агульны выгляд памылак апрацоўваньня, якія ўзьніклі ў сувязі з [https://www.semantic-mediawiki.org/ Сэмантычнае MediaWiki]. Раіцца рэгулярна назіраць за гэтым сьпісам на звыклай аснове й выпраўляць нядзейсныя анатацыі значэньняў.",
"smw_sbv_docu": "Шукаць усе старонкі, якія ўтрымліваюць пададзеную ўласьцівасьць і значэньне.",
"smw_sbv_novalue": "Увядзіце значэньне для ўласьцівасьці, ці паглядзіце ўсе значэньні ўласьцівасьцяў для «$1».",
"smw_sbv_displayresult": "Сьпіс усіх старонак, якія ўтрымліваюць уласьцівасьць «$1» са значэньнем «$2»",
@@ -205,6 +225,10 @@
"smw_browse_hide_incoming": "Схаваць уласьцівасьці, якія спасылаюцца сюды",
"smw_browse_no_outgoing": "Гэта старонка ня мае ўласьцівасьцяў.",
"smw_browse_no_incoming": "На гэту старонку не спасылаюцца ніякія ўласьцівасьці.",
+ "smw-browse-from-backend": "У сапраўдны час ідзе атрыманьне інфармацыі з сэрвэрнай прылады.",
+ "smw-browse-intro": "Дадзеная старонка прадастаўляе падрабязнасьці аб тэме або экзэмпляры сутнасьці, калі ласка, увядзіце назву аб'екту, які патрабуе праверкі.",
+ "smw-browse-invalid-subject": "Праверка суб'екта зьвярнулася з памылкай «$1».",
+ "smw-browse-api-subject-serialization-invalid": "Суб’ект мае некарэктны фармат сэрыялізацыі.",
"smw-browse-show-group": "Адлюстраваць групы",
"smw-browse-hide-group": "Схаваць групы",
"smw_inverse_label_default": "$1 з",
@@ -219,6 +243,7 @@
"smw_result_results": "Вынікі",
"smw_result_noresults": "Вынікаў няма.",
"smwadmin": "Функцыі адміністраваньня і абслугоўваньня",
+ "smw-admin-statistics-job-title": "Статыстыка заданьняў",
"smw-admin-statistics-querycache-title": "Статыстыка кэшу запытаў",
"smw-admin-setupsuccess": "Рухавік сховішча наладжаны.",
"smw_smwadmin_return": "Вярнуцца да $1",
@@ -228,8 +253,8 @@
"smw_smwadmin_updatenotstopped": "Каб спыніць працэс абнаўленьня, пастаўце ў полі адзнаку дзеля пацьверджаньня вашых намераў.",
"smw-admin-docu": "Гэтая спэцыяльная старонка дапамагае вам падчас усталяваньня, абнаўленьня, абслугоўваньня і выкарыстаньня <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWiki</a>, а таксама забясьпечвае далейшыя адміністрацыйныя функцыі і задачы разам з статыстыкай.\nНе забывайце захоўваць каштоўныя зьвесткі перад выкананьнем адміністратарскіх функцыяў.",
"smw-admin-environment": "Абалонка праграмнага забесьпячэньня",
- "smw-admin-db": "Абслугоўваньне базы зьвестак",
- "smw-admin-dbdocu": "Semantic MediaWiki патрабуе некаторыя пашырэньні, каб база зьвестак MediaWiki змагла захоўваць сэмантычныя зьвесткі.\nНаступная функцыя гарантуе, што Вашая база зьвестак усталяваная правільна.\nЗьмены, зробленыя на гэтым этапе, не паўплываюць на астатнія базы зьвестак MediaWiki, і могуць быць лёгка адмененыя па жаданьні.\nГэта ўсталёвачная функцыя можа быць выкананая некалькі разоў без аніякай шкоды, але для ўсталяваньня ці абнаўленьня дастаткова будзе аднаго разу.",
+ "smw-admin-db": "Наладка базы зьвестак",
+ "smw-admin-dbdocu": "Semantic MediaWiki патрабуе ўласную структуру базы зьвестак (яна залежыць ад MediaWiki і не ўплывае на астатнюю частку ўсталяваньня installation) для захоўваньня сэмантычных зьвестак.\nГэта ўсталёвачная функцыя можа быць выкананая некалькі разоў без аніякай шкоды, але для ўсталяваньня ці абнаўленьня дастаткова будзе аднаго разу.",
"smw-admin-permissionswarn": "Калі адбываюцца SQL-памылкі падчас выкананьня апэрацыі, гэта значыць, што рахунак базы зьвестак, які выкарыстоўвае вікі (праверце ваш файл «LocalSettings.php»), магчыма, ня мае адпаведных правоў.\nНадайце рахунку дадатковыя правы на стварэньне і выдаленьне табліцаў, часова ўвядзіце рахунак адміністратара базы зьвестак у файл «LocalSettings.php», ці карыстайцеся скрыптом падтрымкі <code>setupStore.php</code>, які можа выкарыстоўваць рахунак адміністратара.",
"smw-admin-dbbutton": "Усталяваць ці абнавіць табліцы",
"smw-admin-announce": "Анансуйце вашую вікі",
@@ -244,9 +269,13 @@
"smw_smwadmin_datarefreshbutton": "Заплянаваць перабудову зьвестак",
"smw_smwadmin_datarefreshstop": "Спыніць гэта абнаўленьне",
"smw_smwadmin_datarefreshstopconfirm": "Так, я {{GENDER:$1|ўпэўнены|ўпэўненая}}.",
+ "smw-admin-outdateddisposal-title": "Ліквідацыя састарэлых сутнасьцяў",
+ "smw-admin-outdateddisposal-active": "Прызначана праца па ліквідацыі састарэлых аб'ектаў.",
"smw-admin-outdateddisposal-button": "Заплянаваць ліквідацыю",
"smw-admin-propertystatistics-title": "Перабудова статыстыкі ўласьцівасьці",
"smw-admin-propertystatistics-button": "Заплянаваць перабудову статыстыкі",
+ "smw-admin-fulltext-title": "Перабудова паўнатэкставага пошуку",
+ "smw-admin-fulltext-button": "Запланаваць паўнатэкставую перабудову",
"smw-admin-support": "Падтрымка",
"smw-admin-supportdocu": "Ёсьць розныя крыніцы, каб дапамагчы вам у выпадку праблемаў:",
"smw-admin-installfile": "Калі ўзьнікнуць праблемы з вашым усталяваньнем, пачніце з рэкамэндацыяў у <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md\">файле INSTALL</a> і <a href=\"https://www.semantic-mediawiki.org/wiki/Help:Installation\">на старонцы ўсталёўкі</a>.",
@@ -255,30 +284,68 @@
"smw-admin-questions": "Калі вы маеце пытаньні ці прапановы, далучайцеся да дыскусіі ў <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">паштовай рассылцы</a> Semantic MediaWiki ці ў <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">чаце</a>.",
"smw-admin-other-functions": "Іншыя функцыі",
"smw-admin-supplementary-section-title": "Дапаможныя функцыі",
- "smw-admin-supplementary-section-subtitle": "Даступныя функцыі",
+ "smw-admin-supplementary-section-subtitle": "Функцыі ядра",
"smw-admin-supplementary-settings-title": "Парамэтры канфігурацыі",
+ "smw-admin-supplementary-settings-intro": "<u>$1</u> выводзіць супольны сьпіс даступных наладак, якія выкарыстоўваюцца ў Сэмантычнай МэдыяВікі",
"smw-admin-supplementary-operational-statistics-title": "Апэрацыйная статыстыка",
+ "smw-admin-supplementary-operational-statistics-intro": "<u>$1</u> адлюстроўвае пашыраны набор статыстыкі",
+ "smw-admin-supplementary-idlookup-title": "Пошук і вылучэньне сутнасьці",
+ "smw-admin-supplementary-idlookup-intro": "<u>$1</u> зьмяшчае функцыі для пошуку й месцазнаходжаньня асобных сутнасьцяў",
+ "smw-admin-supplementary-duplookup-title": "Дубляваныя сутнасьці",
+ "smw-admin-supplementary-duplookup-intro": "<u>$1</span> каб пералічыць запісы, якія класыфікуюцца як утрымліваючыя дублікаты ў табліцы сутнасьцяў",
+ "smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
"smw-admin-supplementary-operational-statistics-cache-title": "Статыстыка кэшу",
+ "smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> паказвае статыстыку дакранальна кішэні",
+ "smw-admin-supplementary-elastic-title": "Elasticsearch",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> паказвае налады й індэксную статыстыку",
+ "smw-admin-supplementary-elastic-functions": "Падтрымваныя функцыі",
"smw-admin-supplementary-elastic-settings-title": "Налады",
+ "smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> выкарыстоўваецца ''Elasticsearch'' для кіраваньня індэксамі ''Сэмантычнай МэдыяВікі''",
"smw-admin-supplementary-elastic-mappings-title": "Мапаваньні",
+ "smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u>, каб адлюстраваць індэксы і месцазнаходжаньні палёў",
"smw-admin-supplementary-elastic-mappings-summary": "Зьмест",
+ "smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u> паказвае статыстыку вузла",
+ "smw-admin-supplementary-elastic-indices-title": "Індэксы",
+ "smw-admin-supplementary-elastic-indices-intro": "<u>$1</u> забясьпечвае агляд даступных індэксаў і іх статыстыку",
"smw-admin-supplementary-elastic-statistics-title": "Статыстыка",
+ "smw-admin-supplementary-elastic-statistics-intro": "<u>$1</u> паказвае статыстыку ўзроўню індэксу",
"smw-admin-supplementary-elastic-status-replication": "Стан рэплікацыі",
+ "smw-admin-supplementary-elastic-status-last-active-replication": "Апошняя актыўная рэплікацыя: $1",
"smw-admin-supplementary-elastic-status-refresh-interval": "Прамежак абнаўленьня: $1",
+ "smw-admin-supplementary-elastic-status-recovery-job-count": "Затрымка ўзнаўленьня працы: $1 (ацэнка)",
+ "smw-admin-supplementary-elastic-status-file-ingest-job-count": "Часопіс (файл) нявыкананай працы: $1 (ацэнка)",
+ "smw-admin-supplementary-elastic-status-rebuild-lock": "Рэплікацыя заблякавана: $1 (перабудова ў працэсе)",
+ "smw-list-count": "Сьпіс утрымлівае $1 {{PLURAL:$1|уваход|уваходы}}.",
+ "smw-list-count-from-cache": "Ліст утрымлівае $1 {{PLURAL:$1|уваход|уваходы}} і быў атрыманы з кішэню (UTC: $2).",
+ "smw-property-label-similarity-title": "Справаздача аб падобнасьці назваў уласьцівасьцяў",
+ "smw-property-label-similarity-intro": "<u>$1</u> вылічвае падобнасьці для існых назваў уласьцівасьцяў",
"smw-property-label-similarity-threshold": "Парог:",
"smw-property-label-similarity-type": "Адлюстраваць тып ідэнтыфікатару",
+ "smw-property-label-similarity-noresult": "Для абраных парамэтраў ня знойдзена вынікаў.",
"smw_adminlinks_datastructure": "Структура зьвестак",
"smw_adminlinks_displayingdata": "Паказ зьвестак",
"smw_adminlinks_inlinequerieshelp": "Дапамога па ўбудаваных запытах",
+ "smw-property-indicator-type-info": "Уласьцівасьць, вызначаная {{PLURAL:$1|ўдзельнікам|сыстэмай}}",
+ "smw-property-indicator-last-count-update": "Прыкладная колькасьць выкарыстоўваньняў\nАпошні раз абноўлена: $1",
+ "smw-concept-indicator-cache-update": "Лічыльнік кішэню\nАпошні раз абноўлены: $1",
"smw-createproperty-isproperty": "Гэта ўласьцівасьць тыпу $1.",
"smw-createproperty-allowedvals": "{{PLURAL:$1|1=Дазволенае значэньне|Дазволеныя значэньні}} для гэтай уласьцівасьці:",
"smw-paramdesc-category-delim": "Межнік",
+ "smw-paramdesc-category-template": "Шаблён, з дапамогай якога фарматуюцца элэмэнты",
+ "smw-paramdesc-category-userparam": "Парамэтар для перадачы шаблёну",
"smw-info-par-message": "Паведамленьне для адлюстраваньня.",
+ "smw-info-par-icon": "Значак для адлюстраваньня «info» або «warning».",
"prefs-smw": "Сэмантычная MediaWiki",
"prefs-general-options": "Агульныя налады",
+ "prefs-ask-options": "Спэцыяльныя:Парамэтры запыту",
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/ Semantic MediaWiki] (і зьвязаныя пашырэньні) дазваляе пэрсанальную наладку для некаторых функцыяў. Калі ласка, глядзіце [https://www.semantic-mediawiki.org/wiki/Help:User_preferences старонку дапамогі] для падрабязнага апісаньня.",
"smw-prefs-ask-options-tooltip-display": "Адлюстроўваць парамэтар у выглядзе інфармацыйнай падказкі",
"smw-prefs-ask-options-compact-view-basic": "Дазволіць асноўны кампактны выгляд",
+ "smw-prefs-help-ask-options-compact-view-basic": "Калі ўключана, адлюстроўвае скарочаны набор спасылак на Special:Ask у сьціснутым фармаце",
+ "smw-prefs-general-options-jobqueue-watchlist": "Адлюстраваць сьпіс назіраньняў за чэргай задачаў на асабістым панэлю",
+ "smw-prefs-general-options-disable-editpage-info": "Адлучыць уступны тэкст на старонцы рэдагаваньня",
+ "smw-prefs-general-options-disable-search-info": "Адлучыць інфармацыю аб падтрымцы сынтаксысу на змоўчнай старонцы пошуку",
+ "smw-prefs-general-options-suggester-textinput": "Улучыць дапамогу для ўводу сэмантычных аб’ектаў",
"smw-ui-tooltip-title-property": "Уласьцівасьць",
"smw-ui-tooltip-title-quantity": "Канвэрсія адзінкі",
"smw-ui-tooltip-title-info": "Інфармацыя",
@@ -294,7 +361,11 @@
"smw-concept-cache-text": "Задумка мае $1 {{PLURAL:$1|старонку|старонкі|старонак}}, і была апошні раз абноўлена $3, $2.",
"smw_concept_header": "Старонкі канцэпцыі «$1»",
"smw_conceptarticlecount": "Ніжэй {{PLURAL:$1|паказаная $1 старонка|паказаныя $1 старонкі|паказаныя $1 старонак}}.",
+ "smw-qp-empty-data": "Запытаныя зьвесткі ня могуць быць адлюстраваныя ў сувязі зь недастатковасьцю крытэраў адбору.",
"right-smw-admin": "Доступ да адміністрацыйных задачаў (Сэмантычная MediaWiki)",
+ "right-smw-ruleedit": "Рэдагаваць старонкі правілаў (Сэмантычная МэдыяВікі)",
+ "restriction-level-smw-pageedit": "абаронена (толькі адпаведныя ўдзельнікі)",
+ "action-smw-patternedit": "рэдагаваць звычайныя выразы, якія выкарыстоўваюцца Сэмантычнай МэдыяВікі",
"smw-sp-properties-header-label": "Сьпіс уласьцівасьцяў",
"smw-admin-idlookup-title": "Шукаць паводле",
"smw-admin-iddispose-title": "Пазбаўленьне",
@@ -302,7 +373,6 @@
"smw-admin-objectid": "Ідэнтыфікатар:",
"smw-admin-tab-general": "Агляд",
"smw-admin-tab-notices": "Заўвагі аб састарэньні",
- "smw-admin-tab-rebuild": "Тэхнічнае абслугоўваньне",
"smw-admin-tab-supplement": "Дадатковыя функцыі",
"smw-admin-tab-registry": "Рэестар",
"smw-livepreview-loading": "Загрузка…",
@@ -314,10 +384,37 @@
"smw-search-profile-extended-help-find-forms": "даступныя формы",
"smw-search-profile-extended-section-sort": "Сартаваць па",
"smw-search-profile-extended-section-form": "Формы",
+ "smw-search-profile-extended-section-search-syntax": "Пошук увахода",
"smw-search-profile-extended-section-namespace": "Прастора назваў",
"smw-search-profile-extended-section-query": "Запыт",
"smw-search-profile-link-caption-query": "убачыць",
"smw-search-show": "Паказаць",
"smw-search-hide": "Схаваць",
- "log-name-smw": "Журнал Сэмантычнай MediaWiki"
+ "log-name-smw": "Журнал Сэмантычнай MediaWiki",
+ "log-show-hide-smw": "$1 летапіс Сэмантычнай МэдыяВікі",
+ "logeventslist-smw-log": "Летапіс Сэмантычнай Мэдыя Вікі",
+ "logentry-smw-maintenance": "Падзеі, зьвязаныя з падтрымкай, якія адбыліся ў Сэмантычнай МэдыяВікі",
+ "smw-datavalue-import-link": "[[MediaWiki:Smw import $1|імпарт $1]]",
+ "smw-datavalue-restricted-use": "Значэньне зьвестак «$1» было пазначана для абмежаванага карыстаньня.",
+ "smw-datavalue-invalid-number": "«$1» ня можа быць інтэрпрэтавана як лічба.",
+ "smw-query-condition-circular": "Магчымая цыклічная ўмова была знойдзена ў «$1».",
+ "smw-query-condition-empty": "У апісаньні запыту існуе пустая ўмова.",
+ "smw-types-list": "Сьпіс тыпаў зьвестак",
+ "smw-types-default": "«$1» зьяўляецца ўбудаваным тыпам зьвестак.",
+ "smw-type-boo": "«$1» зьяўляецца звычайным тыпам зьвестак для апісаньня значэньня праўда/хлусьня.",
+ "smw-type-ema": "«$1» зьяўляецца тыпам зьвестак для прадастаўленьня адрасу элэктроннай пошты.",
+ "smw-type-tab-properties": "Уласьцівасьці",
+ "smw-type-tab-types": "Тыпы",
+ "smw-type-tab-errors": "Памылкі",
+ "smw-type-primitive": "Асноўная",
+ "smw-type-contextual": "Залежныя",
+ "smw-limitreport-intext-parsertime": "[SMW] Час разбору ўнутрытэкставай анатацыі",
+ "smw-limitreport-intext-postproctime": "[SMW] час пост-апрацоўкі",
+ "smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|сэкунда|сэкундаў}}",
+ "smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|сэкунда|сэкундаў}}",
+ "smw-limitreport-pagepurge-storeupdatetime-value": "$1 {{PLURAL:$1|сэкунда|сэкунды|сэкундаў}}",
+ "smw-datavalue-time-invalid-date-components-empty": "«$1» зьмяшчае некаторыя пустыя кампанэнты.",
+ "smw-datavalue-external-formatter-invalid-uri": "«$1» зьяўляецца няправільным URL-адрасам.",
+ "smw-datavalue-parse-error": "Дадзенае значэньне «$1» не было распазнанае.",
+ "smw-no-data-available": "Няма даступных зьвестак."
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ca.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ca.json
index c49571bc..bf719b24 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ca.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ca.json
@@ -30,6 +30,7 @@
"smw-factbox-facts-derived-help": "Mostra fets que s'han derivat de regles amb l'ajuda d'altres tècniques de raonament",
"smw_isspecprop": "Aquesta és una propietat especial en aquest wiki.",
"smw-concept-cache-header": "Ús de la memòria cau",
+ "smw-concept-cache-count": "La [https://www.semantic-mediawiki.org/wiki/Help:Concept_cache_count memòria cau de conceptes] conté {{PLURAL:$1|'''una''' entitat|'''$1''' entitats}} ($2).",
"smw-concept-no-cache": "No hi ha memòria cau disponible.",
"smw_concept_description": "Descripció del concepte «$1».",
"smw_no_concept_namespace": "Els conceptes només poden ser definits en pàgines dins l'espai de noms (namespace) Concept:",
@@ -112,6 +113,7 @@
"smw-paramdesc-feeddescription": "El text que s'utilitzarà com a descripció del canal",
"smw-paramdesc-feedpagecontent": "Contingut de la pàgina que es mostrarà amb el canal",
"smw-label-feed-description": "Canal $2 $1",
+ "smw-paramdesc-mimetype": "El tipus mèdia (tipus MIME) per al fitxer de sortida",
"smw_iq_disabled": "Les consultes semàntiques estan inhabilitades en aquest wiki.",
"smw_iq_moreresults": "... més resultats",
"smw_parseerror": "El valor donat no s'ha entès.",
@@ -124,6 +126,7 @@
"smw_emptystring": "No s'accepten cadenes buides.",
"smw_notinenum": "«$1» no és a la llista ($2) de [[Property:Allows value|valors permesos]] de la propietat «$3».",
"smw-datavalue-constraint-error-allows-value-list": "«$1» no es troba a la llista ($2) de [[Property:Allows value|valors permesos]] de la propietat «$3».",
+ "smw-datavalue-constraint-error-allows-value-range": "«$1» no es troba en el rang «$2» especificat per la restricció «[[Property:Allows value|permet valor]]» de la propietat «$3».",
"smw_noboolean": "«$1» no es pot reconèixer com un valor booleà (cert/fals).",
"smw_true_words": "verdader,vertader,veritat,cert,true,t,sí,s,yes,y",
"smw_false_words": "fals,f,no,n,false",
@@ -190,16 +193,17 @@
"smw-special-concept-count": "Es {{PLURAL:$1|llista|llisten}} {{PLURAL:$1|el concepte|els $1 conceptes}} següents.",
"smw-special-concept-empty": "No s'ha trobat cap concepte.",
"unusedproperties": "Propietats no utilitzades",
- "smw-unusedproperties-docu": "Les propietats següents existeixen, tot i que cap altra pàgina les fa servir.",
+ "smw-unusedproperties-docu": "Aquesta pàgina llista les [https://www.semantic-mediawiki.org/wiki/Unused_properties propietats no utilitzades], que són declarades però que cap pàgina les fa servir. Per a una vista diferenciada, visiteu les pàgines especials de [[Special:Properties|totes les propietats]] o de les [[Special:WantedProperties|propietats per definir]].",
"smw-unusedproperty-template": "$1 del tipus $2",
"wantedproperties": "Propietats per definir",
- "smw-wantedproperties-docu": "Les propietats següents s'utilitzen en el wiki però encara no tenen cap pàgina per a descriure-les.",
+ "smw-wantedproperties-docu": "Aquesta pàgina llista les [https://www.semantic-mediawiki.org/wiki/Wanted_properties propietats per definir] que s'utilitzen en aquest wiki però que no tenen cap pàgina que les descrigui. Per a una vista diferenciada, visiteu les pàgines especials de [[Special:Properties|totes les propietats]] o de les [[Special:UnusedProperties|propietats no utilitzades]].",
"smw-wantedproperty-template": "$1 ($2 {{PLURAL:$2|ús|usos}})",
+ "smw-special-wantedproperties-docu": "Aquesta pàgina llista les [https://www.semantic-mediawiki.org/wiki/Wanted_properties propietats demanades] que s'utilitzen en el wiki però que no tenen una pàgina que les descriu. Per a una vista diferenciada, vegeu les pàgines especials de [[Special:Properties|totes les propietats]] o de les [[Special:UnusedProperties|no utilitzades]].",
"smw-special-wantedproperties-template": "$1 ($2 {{PLURAL:$2|utilització|utilitzacions}})",
"smw_purge": "Refresca",
"smw-purge-failed": "El refrescament ha fallat",
"types": "Tipus",
- "smw_types_docu": "La següent és una [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes llista] de tots els tipus de dades que poden assignar-se a les propietats.",
+ "smw_types_docu": "Llista de [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes tipus de dades disponibles], on cada [https://www.semantic-mediawiki.org/wiki/Help:Datatype tipus] representa un conjunt únic d'atributs per descriure un valor en termes d'emmagatzematge i característiques de visualització que són hereditaris per a una propietat assignada.",
"smw-special-types-no-such-type": "El tipus de dades «$1» és desconegut o no s'ha especificat.",
"smw-statistics": "Estadístiques semàntiques",
"smw-statistics-property-instance": "Propietat {{PLURAL:$1|valor|valors}} (total)",
@@ -221,6 +225,7 @@
"smw-statistics-delete-count": "{{PLURAL:$1|Entitat desactualitzada|Entitats desactualitzades}} (marcades per suprimir)",
"smw_uri_doc": "El resolutor d'URI implementa la [$1 cerca de W3C TAG en httpRange-14].\nTé cura que els humans no es tornin en llocs web.",
"ask": "Cerca semàntica",
+ "smw-ask-help": "Aquesta secció conté alguns enllaços per ajudar a explicar com utilitzar la sintaxi <code>#ask</code>.\n\n* [https://www.semantic-mediawiki.org/wiki/Help:Selecting_pages Selecció de pàgines]: descriu com seleccionar les pàgines i construir condicions\n\n*[https://www.semantic-mediawiki.org/wiki/Help:Search_operators Operadors de cerca]: llista els operadors de cerca disponibles, incloent-hi els de les consultes d'intèrval i de caràcters comodí\n\n*[https://www.semantic-mediawiki.org/wiki/Help:Displaying_information Impressió d'informació]: resumeix l'ús de les opcions de declaració i formatatge",
"smw_ask_sortby": "Ordena per columna (opcional)",
"smw_ask_ascorder": "Ascendent",
"smw_ask_descorder": "Descendent",
@@ -260,6 +265,7 @@
"smw-ask-format-selection-help": "Ajuda amb el format seleccionat: $1",
"smw-ask-condition-change-info": "S'ha alterat la condició i el motor de cerca necessita que es torni a executar la consulta per a produir resultats que coincideixin amb els nous requisits.",
"smw-ask-input-assistance": "Assistència d'entrada",
+ "smw-ask-condition-input-assistance": "Es proporciona [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance assistència d'entrada] per als camps d'impressió, d'ordenació i de condició. El camp de condició requereix un dels prefixos següents:",
"smw-ask-condition-input-assistance-property": "<code>p:</code> per a recollir suggeriments de propietats (p. ex., <code>[[p:Has …</code>)",
"smw-ask-condition-input-assistance-category": "<code>c:</code> per a recollir suggeriments de categories",
"smw-ask-condition-input-assistance-concept": "<code>con:</code> per a recollir suggeriments de conceptes",
@@ -289,8 +295,10 @@
"smw-browse-intro": "Aquesta pàgina proporciona informació sobre un tema o instància d'entitat. Introduïu el nom d'un objecte per ser inspeccionat.",
"smw-browse-invalid-subject": "La validació del subjecte ha retornat amb un error «$1».",
"smw-browse-api-subject-serialization-invalid": "El subjecte té un format de serialització no vàlid.",
+ "smw-browse-js-disabled": "Se sospita que el Javascript està inhabilitat o no està disponible. Recomanem que feu servir un navegador que el pugui fer servir. Es discuteixen altres opcions a la pàgina del paràmetre de configuració [https://www.semantic-mediawiki.org/wiki/Help:$smwgBrowseByApi <code>$smwgBrowseByApi</code>].",
"smw-browse-show-group": "Mostra els grups",
"smw-browse-hide-group": "Amaga els grups",
+ "smw-noscript": "Aquesta pàgina o acció necessita Javascript per funcionar. Habiliteu el Javascript al navegador o utilitzeu-ne un que el permeti per tal que la funcionalitat funcioni com es demana. Per a més ajuda, consulteu la pàgina d'ajuda [https://www.semantic-mediawiki.org/wiki/Help:Noscript noscript].",
"smw_inverse_label_default": "$1 de",
"smw_inverse_label_property": "Etiqueta de propietat inversa",
"pageproperty": "Cerca de les propietats de la pàgina",
@@ -304,7 +312,9 @@
"smw_result_noresults": "No hi ha resultats.",
"smwadmin": "Funcions administratives i de manteniment",
"smw-admin-statistics-job-title": "Estadístiques de tasques",
+ "smw-admin-statistics-job-docu": "Les estadístiques de tasques mostren informació de les tasques programades al Semantic MediaWiki que encara no s'han executat. El nombre de tasques podria ser lleugerament no acurat o contenir intents fallits. Consulteu el [https://www.mediawiki.org/wiki/Manual:Job_queue manual] per a més informació.",
"smw-admin-statistics-querycache-title": "Estadístiques de la cau de consulta",
+ "smw-admin-statistics-querycache-disabled": "No s'ha habilitat el [https://www.semantic-mediawiki.org/wiki/QueryCache QueryCache] en aquest wiki i, per tant, les estadístiques no són disponibles.",
"smw-admin-permission-missing": "L'accés a la pàgina ha estat blocat perquè manquen permisos. Consulteu la pàgina d'ajuda sobre [https://www.semantic-mediawiki.org/wiki/Help:Permissions permisos] per a més detalls dels paràmetres necessaris.",
"smw-admin-setupsuccess": "S'ha configurat el motor d'emmagatzematge.",
"smw_smwadmin_return": "Torna a $1",
@@ -315,6 +325,7 @@
"smw-admin-docu": "Aquesta pàgina especial us ajuda durant la instal·lació i l'actualització del <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWiki</a> i també proporciona altres funcions i tasques administratives juntament amb estadístiques.\nRecordeu fer una còpia de seguretat de les dades importants abans d'executar cap funció administrativa.",
"smw-admin-environment": "Entorn de programari",
"smw-admin-db": "Manteniment de la base de dades",
+ "smw-admin-db-preparation": "La inicialització de la taula és en procés i pot trigar una estona fins que els resultats es mostrin segons la mida de la taula i les optimitzacions que s'hi facin.",
"smw-admin-dbdocu": "El Semantic MediaWiki necessita algunes extensions a la base de dades del MediaWiki per a poder emmagatzemar les dades semàntiques.\nLa funció a continuació garanteix que la vostra base de dades està configurada correctament.\nEls canvis fets en aquest pas no afecten la resta de la base de dades del MediaWiki, i poden desfer-se fàcilment si així es vol.\nLa funció de configuració pot executar-se moltes vegades sense que es faci cap mal, però només cal una vegada per a la instal·lació o l'actualització.",
"smw-admin-permissionswarn": "Si l'operació falla amb errors SQL, l'usuari de la base de dades que utilitza el vostre wiki (comproveu el LocalSettings.php) probablement no té suficients permisos.\nPodeu atorgar l'usuari permisos addicionals per a crear o suprimir taules, introduïu temporalment les dades d'inici de l'administrador (root) de la base de dades al LocalSettings.php, o bé feu servir l'script de manteniment <code>setupStore.php</code>, que pot utilitzar les credencials d'un administrador.",
"smw-admin-dbbutton": "Inicialitza o actualitza les taules",
@@ -322,12 +333,16 @@
"smw-admin-announce-text": "Si el vostre wiki és públic, el podeu registrar a <a href=\"https://wikiapiary.com\">WikiApiary</a>, el catàleg wiki de wikis.",
"smw-admin-deprecation-notice-title": "Avisos d'obsolescència",
"smw-admin-deprecation-notice-docu": "La secció següent conté paràmetres que són obsolets o en desús però que s'han detectat com a actius en aquest wiki. S'espera que en versions futures se suprimirà el suport per a aquestes configuracions.",
+ "smw-admin-deprecation-notice-config-notice": "<code>[https://www.semantic-mediawiki.org/wiki/Help:$1 $1]</code> és obsolet i se suprimirà en $2",
+ "smw-admin-deprecation-notice-config-notice-option-list": "<code>$1</code> és obsolet i se suprimirà en $2",
"smw-admin-deprecation-notice-config-replacement-option-list": "<code>$1</code> està essent reemplaçat per <code>$2</code>",
"smw-admin-deprecation-notice-config-removal": "<code>[https://www.semantic-mediawiki.org/wiki/Help:$1 $1]</code> va ser suprimit a $2",
"smw-admin-deprecation-notice-title-notice": "Canvis propers",
"smw-admin-deprecation-notice-title-notice-explanation": "S'han detectat els paràmetres següents en aquest wiki, els quals s'ha planejat que se suprimiran o canviaran en una versió futura.",
"smw-admin-deprecation-notice-title-replacement": "Paràmetres substituïts o canviats de nom",
+ "smw-admin-deprecation-notice-title-replacement-explanation": "La secció següent conté paràmetres que van ser reanomenats o bé que s'han modificat. Es recomana que se n'actualitzi el seu nom o format immediatament.",
"smw-admin-deprecation-notice-title-removal": "Paràmetres suprimits",
+ "smw-admin-deprecation-notice-title-removal-explanation": "Els paràmetres llistats van ser suprimits en una versió anterior, però s'ha detectat que encara s'utilitzen en aquest wiki.",
"smw-smwadmin-refresh-title": "Reparació de les dades i actualització",
"smw_smwadmin_datarefresh": "Reconstrucció de les dades",
"smw_smwadmin_datarefreshdocu": "És possible restaurar totes les dades del Semantic MediaWiki a partir dels continguts actuals del wiki.\nAixò pot ser útil per a reparar dades inconsistents o refrescar les dades si el format intern ha canviat per alguna actualització de programari.\nL'actualització s'executa pàgina per pàgina i no es completarà immediatament.\nA continuació és mostra si l'actualització és en curs i us permet iniciar o aturar les actualitzacions (a menys que aquesta característica estigui inhabilitada per l'administrador del lloc).",
@@ -335,26 +350,29 @@
"smw_smwadmin_datarefreshbutton": "Programa la reconstrucció de les dades",
"smw_smwadmin_datarefreshstop": "Atura l'actualització",
"smw_smwadmin_datarefreshstopconfirm": "Sí, estic {{GENDER:$1|segur|segura}}.",
+ "smw-admin-job-scheduler-note": "La majoria d'activitats d'aquesta secció es realitzen com a tasques per tal d'evitar situacions de bloqueig durant l'execució. El [https://www.mediawiki.org/wiki/Manual:Job_queue planificador de tasques] és responsable de processar-les i és crític que l'script de manteniment <code>runJobs.php</code> (vegeu també el paràmetre de configuració <code>$wgRunJobsAsync</code>) tingui una capacitat adequada.",
"smw-admin-outdateddisposal-title": "Eliminació d'entitats obsoletes",
"smw-admin-outdateddisposal-intro": "Algunes activitats (un canvi de tipus de propietat, l'eliminació de pàgines wiki o la correcció de valors erronis) resultarà en [https://www.semantic-mediawiki.org/wiki/Outdated_entities entitats obsoletes] i se suggereix suprimir-les periòdicament per tal d'alliberar l'espai de taula associat.",
"smw-admin-outdateddisposal-active": "S'ha posat en cua una tasca d'eliminació d'entitats obsoletes.",
"smw-admin-outdateddisposal-button": "Programa una eliminació",
+ "smw-admin-feature-disabled": "S'ha inhabilitat aquesta funcionalitat en el wiki, consulteu la pàgina d'ajuda dels <a href=\"https://www.semantic-mediawiki.org/wiki/Help:$smwgAdminFeatures\">paràmetres de configuració</a> o contacteu amb l'administrador del sistema.",
"smw-admin-propertystatistics-title": "Reconstrucció de les estadístiques de les propietats",
"smw-admin-propertystatistics-active": "S'ha programat una tasca de reconstrucció de les estadístiques.",
"smw-admin-propertystatistics-button": "Programa la reconstrucció de les estadístiques",
"smw-admin-fulltext-title": "Reconstrucció de la cerca en text complet",
+ "smw-admin-fulltext-intro": "Reconstrueix l'índex de cerca de les taules de propietats amb un tipus de dades [https://www.semantic-mediawiki.org/wiki/Full-text cerca de text complet] habilitat. Els canvis a les regles d'indexació (separadors modificats, noves arrels, etc.) i/o taules noves o afegides necessiten que es torni a executar la tasca de nou.",
"smw-admin-fulltext-active": "S'ha programat una tasca de reconstrucció de cerca de text complet.",
"smw-admin-fulltext-button": "Programa una reconstrucció de text sencer",
"smw-admin-support": "Com obtenir assistència",
"smw-admin-supportdocu": "Es proporcionen diferents recursos per ajudar-vos en cas de problemes:",
- "smw-admin-installfile": "Si us trobeu amb problemes amb la vostra instal·lació, comenceu comprovant les instruccions del <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md\">fitxer INSTALL</a>.",
+ "smw-admin-installfile": "Si us trobeu amb problemes amb la vostra instal·lació, comenceu comprovant les instruccions del <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md\">fitxer INSTALL</a> i la <a href=\"https://www.semantic-mediawiki.org/wiki/Help:Installation\">pàgina d'instal·lació</a>.",
"smw-admin-smwhomepage": "Podeu trobar la documentació d'usuari completa del Semantic MediaWiki a <b><a href=\"https://www.semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
- "smw-admin-bugsreport": "Es poden enviar informes d'error al <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">GitHub</a>.",
+ "smw-admin-bugsreport": "Es poden enviar informes d'error al <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">gestor d'incidències del Github</a>. La pàgina d'<a href=\"https://www.semantic-mediawiki.org/wiki/Help:Reporting_bugs\">informe d'errors</a> proporciona una guia de com escriure un informe d'error d'una forma eficient.",
"smw-admin-questions": "Si teniu més preguntes o suggeriments, uniu-vos a la discussió a la <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">llista de correu d'usuaris del Semantic MediaWiki</a> o a la <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">sala de xat</a>.",
"smw-admin-other-functions": "Altres funcions",
"smw-admin-supplementary-section-title": "Funcions suplementàries",
"smw-admin-supplementary-section-subtitle": "Funcions disponibles",
- "smw-admin-supplementary-section-intro": "Algunes de les funcions llistades en aquesta secció poden restringir-se i per tant ser inaccessibles en aquest wiki.",
+ "smw-admin-supplementary-section-intro": "Aquesta secció proporciona funcions addicionals més enllà de l'abast de les tasques de manteniment i és possible que algunes de les funcions llistades en la [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions documentació] estiguin restringides o no disponibles i, per tant, siguin inaccessibles en aquest wiki.",
"smw-admin-supplementary-settings-title": "Paràmetres de configuració",
"smw-admin-supplementary-settings-intro": "<u>$1</u> retorna una llista col·lectiva de paràmetres disponibles utilitzats a Semantic MediaWiki",
"smw-admin-supplementary-operational-statistics-title": "Estadístiques operacionals",
@@ -362,21 +380,28 @@
"smw-admin-supplementary-idlookup-title": "Cerca i eliminació d'entitats",
"smw-admin-supplementary-idlookup-intro": "<u>$1</u> conté funcions per a cercar i eliminar entitats individuals",
"smw-admin-supplementary-duplookup-title": "Entitats duplicades",
+ "smw-admin-supplementary-duplookup-intro": "<u>$1</u> per a llistar les entrades que estan categoritzades per contenir duplicats en la taula d'entitats",
"smw-admin-supplementary-duplookup-docu": "Aquesta pàgina llista entrades de [https://www.semantic-mediawiki.org/wiki/Help:Entity_table taules d'entitats] que s'han categoritzat com a duplicades. Les entrades duplicades, si mai n'hi ha, haurien de tenir lloc només en rares ocasions a causa d'un procés terminat durant una actualització de base dades o d'una transacció de reversió que ha fallat.",
+ "smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
"smw-admin-supplementary-operational-statistics-cache-title": "Estadístiques de la memòria cau",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> mostra estadístiques relacionades amb la memòria cau",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
"smw-admin-supplementary-elastic-intro": "<u>$1</u> informa de paràmetres i estadístiques d'indexació",
+ "smw-admin-supplementary-elastic-docu": "Aquesta pàgina conté informació de configuració, correspondència, salut i estadístiques d'indexació relacionades amb un clúster d'Elasticsearch que està connectat a Semantic MediaWiki i el seu [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
"smw-admin-supplementary-elastic-functions": "Funcions disponibles",
"smw-admin-supplementary-elastic-settings-title": "Paràmetres",
+ "smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> utilitzat per Elasticsearch per gestionar els índexs de Semantic MediaWiki",
"smw-admin-supplementary-elastic-mappings-title": "Correspondències",
"smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u> per llistar índex i correspondències de camps",
+ "smw-admin-supplementary-elastic-mappings-docu": "Aquesta pàgina conté detalls de la correspondència de camps que s'utilitzen amb els índexs actuals. Caldria monitoritzar el resum de la correspondència en connexió amb <code>index.mapping.total_fields.limit</code>, que especifica el nombre màxim de camps en un índex.",
"smw-admin-supplementary-elastic-mappings-summary": "Resum",
"smw-admin-supplementary-elastic-mappings-fields": "Correspondències de camp",
"smw-admin-supplementary-elastic-nodes-title": "Nodes",
"smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u> mostra les estadístiques de node",
"smw-admin-supplementary-elastic-indices-title": "Índexs",
+ "smw-admin-supplementary-elastic-indices-intro": "<u>$1</u> proporciona un resum dels índexs disponibles i llurs estadístiques",
"smw-admin-supplementary-elastic-statistics-title": "Estadístiques",
+ "smw-admin-supplementary-elastic-statistics-intro": "<u>$1</u> mostra estadístiques de nivell d'índex",
"smw-admin-supplementary-elastic-status-replication": "Estat de replicació",
"smw-admin-supplementary-elastic-status-last-active-replication": "Darrera replicació activa: $1",
"smw-admin-supplementary-elastic-status-refresh-interval": "Interval de refrescament: $1",
@@ -384,7 +409,7 @@
"smw-list-count": "La llista conté $1 {{PLURAL:$1|entrada|entrades}}.",
"smw-list-count-from-cache": "La llista conté $1 {{PLURAL:$1|entrada|entrades}} i s'ha recuperat de la memòria cau (UTC: $2).",
"smw-property-label-similarity-title": "Informe de similitud d'etiquetes de propietat",
- "smw-property-label-similarity-intro": "<u>$1</u> calcula la similitud de les etiquetes de propietats existents",
+ "smw-property-label-similarity-intro": "<u>$1</u> calcula les similituds de les etiquetes de propietats existents",
"smw-property-label-similarity-threshold": "Llindar:",
"smw-property-label-similarity-type": "Mostra l'ID de tipus",
"smw-property-label-similarity-noresult": "No s'han trobat resultats per a les opcions seleccionades.",
@@ -408,9 +433,12 @@
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/ Semantic MediaWiki] (i extensions relacionades) proporcionen personalització individual per a algunes functions seleccionades. Per obtenir més informació, feu una ullada a aquesta [https://www.semantic-mediawiki.org/wiki/Help:User_preferences secció d'ajuda].",
"smw-prefs-ask-options-tooltip-display": "Mostra el text del paràmetre en un rètol flotant informatiu",
"smw-prefs-ask-options-compact-view-basic": "Habilita la vista compacta bàsica",
+ "smw-prefs-help-ask-options-compact-view-basic": "Si s'habilita, mostra un conjunt reduït d'enllaços en la vista compacta d'Special:Ask.",
+ "smw-prefs-general-options-time-correction": "Habilita la correcció horària per a les pàgines especials que utilitzin la preferència de [[Special:Preferences#mw-prefsection-rendering|decalatge horari]] local",
"smw-prefs-general-options-jobqueue-watchlist": "Mostra la llista de seguiment de la cua de tasques a la meva barra personal",
"smw-prefs-general-options-disable-editpage-info": "Inhabilita el text introductori en la pàgina d'edició",
"smw-prefs-general-options-disable-search-info": "Inhabilita la informació d'ajuda a la sintaxi en la pàgina estàndard de cerca",
+ "smw-prefs-general-options-suggester-textinput": "Habilita l'assistència d'entrada per a les entitats semàntiques",
"smw-ui-tooltip-title-property": "Propietat",
"smw-ui-tooltip-title-quantity": "Conversió d'unitat",
"smw-ui-tooltip-title-info": "Informació",
@@ -429,9 +457,11 @@
"smw-qp-empty-data": "No s'han pogut mostrar les dades sol·licitades per manca de criteris de selecció suficients.",
"right-smw-admin": "Accedeix a les tasques d'administració (Semantic MediaWiki)",
"right-smw-patternedit": "Modifica l'accés per a mantenir les expressions regulars i patrons permesos (Semantic MediaWiki)",
+ "right-smw-pageedit": "Accés d'edició per a pàgines anotades amb <code>Is edit protected</code> (Semantic MediaWiki)",
"right-smw-ruleedit": "Edita les pàgines de regles (Semantic MediaWiki)",
"restriction-level-smw-pageedit": "protegit (només usuaris elegibles)",
"action-smw-patternedit": "edita les expressions regulars que utilitza Semantic MediaWiki",
+ "action-smw-pageedit": "modifica pàgines anotades amb <code>Is edit protected</code> (Semantic MediaWiki)",
"group-smwadministrator": "Administradors (Semantic MediaWiki)",
"group-smwadministrator-member": "{{GENDER:$1|administrador|administratora}} (Semantic MediaWiki)",
"grouppage-smwadministrator": "{{ns:project}}:Administrators (Semantic MediaWiki)",
@@ -441,11 +471,11 @@
"action-smw-admin": "accedeix a les tasques d'administració de Semantic MediaWiki",
"action-smw-ruleedit": "edita les pàgines de regla (Semantic MediaWiki)",
"smw-property-predefined-default": "«$1» és una propietat predefinida.",
- "smw-property-predefined-common": "Aquesta propietat està predesplegada (també coneguda com a [https://www.semantic-mediawiki.org/wiki/Help:Special_properties propietat especial]) i ve amb privilegis administratius addicionals però pot utilitzar-se com qualsevol altra [https://www.semantic-mediawiki.org/wiki/Property propietat definida per l'usuari].",
+ "smw-property-predefined-common": "Aquesta propietat està predesplegada (també coneguda com a [https://www.semantic-mediawiki.org/wiki/Help:Special_properties propietat especial]) i ve amb privilegis administratius addicionals, però pot utilitzar-se com qualsevol altra [https://www.semantic-mediawiki.org/wiki/Property propietat definida per l'usuari].",
"smw-property-predefined-ask": "«$1» és una propietat predefinida que representa metainformació (en la forma de [https://www.semantic-mediawiki.org/wiki/Subobject subobjectes]) sobre consultes individuals i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-asksi": "«$1» és una propietat predefinida que recull el nombre de condicions que s'utilitzen en una consulta i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-askde": "«$1» és una propietat predefinida que informa de la profunditat d'una consulta i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
- "smw-property-predefined-long-askde": "És un valor numèric computat en la base de la subconsulta niuada, cadenes de propietat, i elements de descripció disponibles amb l'execució d'una consulta que és restringida pel paràmetre <code>[https://www.semantic-mediawiki.org/wiki/help:$smwgQMaxDepth $smwgQMaxDepth]</code>.",
+ "smw-property-predefined-long-askde": "És un valor numèric computat en la base de la subconsulta niuada, cadenes de propietat, i elements de descripció disponibles amb l'execució d'una consulta que és restringida pel paràmetre de configuració <code>[https://www.semantic-mediawiki.org/wiki/Help:$smwgQMaxDepth $smwgQMaxDepth]</code>.",
"smw-property-predefined-long-askpa": "És part d'una col·lecció de propietats que especifiquen un [https://www.semantic-mediawiki.org/wiki/Help:Query_profiler perfil de consulta].",
"smw-sp-properties-docu": "Aquesta pàgina llista les [https://www.semantic-mediawiki.org/wiki/Property propietats] i el seu recompte d'ús en el wiki. Per a una estadística al dia, és recomanable córrer l'script de manteniment [https://www.semantic-mediawiki.org/wiki/rebuildPropertyStatistics rebuildPropertyStatistics] de forma regular. Per a una visió diferenciada, vegeu les pàgines especials de les [[Special:UnusedProperties|propietats no utilitzades]] o les [[Special:WantedProperties|propietats per definir]].",
"smw-sp-properties-cache-info": "Les dades llistades s'han recuperat de la [https://www.semantic-mediawiki.org/wiki/Caching memòria cau], i s'han actualitzat el $1.",
@@ -453,7 +483,7 @@
"smw-admin-settings-docu": "Mostra una llista de tots els paràmetres per defecte i localitzats que són rellevants per a un entorn de Semantic MediaWiki. Per a més detalls sobre cada paràmetre en particular, consulteu la pàgina d'ajuda de la [https://www.semantic-mediawiki.org/wiki/Help:Configuration configuració].",
"smw-sp-admin-settings-button": "Genera la llista de paràmetres",
"smw-admin-idlookup-title": "Consulta",
- "smw-admin-idlookup-docu": "Mostra els detalls d'un ID d'objecte intern que representa una entitat individual (pàgina wiki, subobjecte, propietat, etc.) a Semantic MediaWiki. L'ID cal no confondre'l que sigui el mateix que una pàgina de MediaWiki o un ID de revisió.",
+ "smw-admin-idlookup-docu": "Aquesta secció mostra els detalls tècnics d'una entitat individual (pàgina wiki, subobjecte, propietat, etc.) a Semantic MediaWiki. L'entrada pot ser un ID numèric o un valor de cadena per coincidir amb el camp de cerca rellevant, tot i que qualsevol referència ID està relacionada amb Semantic MediaWiki i no la pàgina de MediaWiki o l'ID de la revisió.",
"smw-admin-iddispose-title": "Alliberament",
"smw-admin-iddispose-done": "L'ID «$1» s'ha suprimit del servidor d'emmagatzematge.",
"smw-admin-iddispose-references": "L'ID «$1» {{PLURAL:$2|no té cap|té com a mínim una}} referència activa:",
@@ -463,7 +493,6 @@
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Resum",
"smw-admin-tab-notices": "Avisos d’obsolescència",
- "smw-admin-tab-rebuild": "Manteniment",
"smw-admin-tab-supplement": "Funcions suplementàries",
"smw-admin-tab-registry": "Registre",
"smw-livepreview-loading": "S'està carregant…",
@@ -473,11 +502,13 @@
"smw-sp-searchbyproperty-valuequery": "Una llista de pàgines que tenen la propietat «$1» amb el valor «$2» anotat.",
"smw-datavalue-number-textnotallowed": "«$1» no pot assignar-se a un tipus de nombre declarat amb el valor $2.",
"smw-datavalue-number-nullnotallowed": "«$1» ha tornat «NULL», que no és un nombre vàlid.",
- "smw-editpage-annotation-enabled": "Aquesta pàgina permet anotacions semàntiques en el text (p. ex., <nowiki>«[[Considerat com::Patrimoni de la Humanitat]]»</nowiki>) per a crear contingut estructurat i consultable proporcionat per Semantic MediaWiki. Per a una descripció detallada de com utilitzar les anotacions o la funció d'anàlisi #ask consulteu les pàgines d'ajuda [https://www.semantic-mediawiki.org/wiki/Help:Getting_started Primers passos], [https://www.semantic-mediawiki.org/wiki/Help:In-text_annotation Anotació en el text] o [https://www.semantic-mediawiki.org/wiki/Help:Inline_queries Consultes en el text].",
+ "smw-editpage-annotation-enabled": "Aquesta pàgina permet anotacions semàntiques en el text (p. ex., <nowiki>«[[Is specified as::World Heritage Site]]» (es considera com patrimoni de la Humanitat)</nowiki>) per a crear contingut estructurat i consultable proporcionat per Semantic MediaWiki. Per a una descripció detallada de com utilitzar les anotacions o la funció d'anàlisi #ask consulteu les pàgines d'ajuda [https://www.semantic-mediawiki.org/wiki/Help:Getting_started Primers passos], [https://www.semantic-mediawiki.org/wiki/Help:In-text_annotation Anotació en el text] o [https://www.semantic-mediawiki.org/wiki/Help:Inline_queries Consultes en el text].",
"smw-editpage-annotation-disabled": "Aquesta pàgina no permet incloure anotacions semàntiques en el text per restriccions de l'espai de noms. Teniu més detalls de com habilitar l'espai de noms a la pàgina d'ajuda de la [https://www.semantic-mediawiki.org/wiki/Help:Configuration configuració].",
"smw-editpage-property-annotation-enabled": "Aquesta propietat pot ampliar-se mitjançant anotacions semàntiques per a especificar un tipus de dades (p. ex.,<nowiki>«[[</nowiki>Té tipus::Pàgina]]») o d'altres declaracions d'aquesta mena (p. ex.,<nowiki>«[[</nowiki>Subpropietat de::dc:date]]»). Per a una descripció sobre com augmentar aquesta pàgina, consulteu les pàgines d'ajuda de [https://www.semantic-mediawiki.org/wiki/Help:Property_declaration Declaració d'una propietat] o [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes Llista de tipus de dades].<!--[[Has type::Page]], [[Subproperty of::dc:date]]-->",
"smw-editpage-property-annotation-disabled": "Aquesta propietat no pot ampliar-se amb una anotació de tipus de dades (p. ex., <nowiki>«[[</nowiki>Té tipus::Pàgina]]») perquè ja està predefinida (consulteu la pàgina d'ajuda de les [https://www.semantic-mediawiki.org/wiki/Help:Special_properties propietats especials] per a més informació).<!-- [[Has type::Page]]-->",
"smw-editpage-concept-annotation-enabled": "Aquest concepte pot ser ampliat fent servir la funció d'anàlisi #concept. Per a una descripció de com utilitzar-la, consulteu la pàgina d'ajuda sobre els [https://www.semantic-mediawiki.org/wiki/Help:Concepts conceptes].",
+ "smw-search-help-structured": "Cerques estructurades:\n\n*<code><nowiki>[[Category:Lorem ipsum]]</nowiki></code>, <code><nowiki>[[Has number::123]]</nowiki></code> (comme [https://www.semantic-mediawiki.org/wiki/Help:Search#Filter_context context filtrat])\n\n*<code><nowiki>[[Has text::~*lorem*]]</nowiki></code> (avec un [https://www.semantic-mediawiki.org/wiki/Help:Search#Query_context context de cerca])",
+ "smw-search-help-proximity": "Cerques de proximitat (una propietat que sigui desconeguda, '''només''' disponible per a aquells sistemes que proporcionen integració de cerca de text complet):\n\n* <code><nowiki>[[in:lorem ipsum]]</nowiki></code> (cerca a tots els documents «lorem» i «ipsum» que han estat indexats)\n\n* <code><nowiki>[[phrase:lorem ipsum]]</nowiki></code> (troba la coincidència «lorem ipsum» com a frase)",
"smw-search-input": "Entrada i cerca",
"smw-search-syntax": "Sintaxi",
"smw-search-profile": "Estès",
@@ -485,8 +516,17 @@
"smw-search-profile-sort-best": "Millor coincidència",
"smw-search-profile-sort-recent": "Més recent",
"smw-search-profile-sort-title": "Títol",
+ "smw-search-profile-extended-help-intro": "El [https://www.semantic-mediawiki.org/wiki/Help:SMWSearch/Extended_profile perfil estès] Special:Search proporciona accés a les funcions de cerca específiques de Semantic MediaWiki i del seu motor de consulta.",
"smw-search-profile-extended-help-sort": "Especifica una preferència d'ordenació per a la mostra de resultats amb:",
+ "smw-search-profile-extended-help-sort-title": "* «Títol» fent servir el títol de la pàgina (o el títol mostrat) com a criteri d'ordenació",
+ "smw-search-profile-extended-help-sort-recent": "* «Més recent» mostrà les entrades modificades més recentment abans (les entitats que són subobjectes se suprimiran perquè no estan anotades amb una[[Property:Modification date|data de modificació]])",
+ "smw-search-profile-extended-help-form": "Els formularis es proporcionen (sempre que es mantinguin al dia) per contenir correspondències de casos d'ús específics tot exposant diferents propietats i camps de valor per ajustar els processos d'entrada i facilitar als usuaris procedir amb la sol·licitud de cerca (vegeu $1).",
+ "smw-search-profile-extended-help-namespace": "El quadre de selecció d'espai de noms s'amagarà tan aviat com se seleccioni el formulari, però es pot fer visible amb l'ajuda del botó «mostra/amaga».",
+ "smw-search-profile-extended-help-search-syntax": "El camp d'entrada de cerca permet l'ús de sintaxi <code>#ask</code> per definir un context de cerca específic de Semantic MediaWiki. Les expressions útils inclouen:",
+ "smw-search-profile-extended-help-search-syntax-simplified-not": "* <code>not:</code> per no fer correspondència amb cap entitat que inclou \"...\"",
+ "smw-search-profile-extended-help-search-syntax-prefix": "* Prefixos personalitzats addicionals són disponibles i definits com: $1",
"smw-search-profile-extended-help-search-syntax-reserved": "* Algunes expressions són reservades, com ara: <nowiki>$1</nowiki>",
+ "smw-search-profile-extended-help-search-syntax-note": "«Algunes de les operacions llistades només són útils en connexió amb un índex de text complet habilitat o bé amb l'ElasticStore.»",
"smw-search-profile-extended-help-query": "S'ha utilitzat <code><nowiki>$1</nowiki></code> com a consulta.",
"smw-search-profile-extended-help-query-link": "(Per a més detalls $1).",
"smw-search-profile-extended-help-find-forms": "formularis disponibles",
@@ -515,8 +555,10 @@
"smw-property-predefined-long-sobj": "El contenidor permet acumular assignacions de propietat-valor similars al d'una pàgina wiki normal però en un espai d'entitat diferent mentre que està enllaçat al subjecte que l'inclou.",
"smw-property-predefined-errp": "«$1» és una propietat predefinida per a resseguir errors d'entrada de valors d'anotacions irregulars i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-long-errp": "En la major part dels casos es deu a un error de correspondència de tipus o una restricció de [[Property:Allows value|valor]].",
- "smw-property-predefined-pval": "[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Allows_value «$1»] és una propietat predefinida que defineix una llista de valors permesos per tal de restringir les assignacions de valor d'una propietat.",
+ "smw-property-predefined-pval": "[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Allows_value «$1»] és una propietat predefinida que defineix una llista de valors permesos per tal de restringir les assignacions de valor d'una propietat i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-datavalue-property-restricted-annotation-use": "La propietat «$1» té una àrea d'aplicació restringida i els usuaris no poden utilitzar-la com a propietat d'anotació.",
"smw-datavalue-property-restricted-declarative-use": "La propietat «$1» és una propietat declarativa i només pot utilitzar-se en una pàgina de propietat o categoria.",
+ "smw-datavalue-property-create-restriction": "La propietat «$1» no existeix i l'usuari no té el permís «$2» (consulteu [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode el mode d'autoritat]) per crear o anotar valors amb una propietat no aprovada.",
"smw-datavalue-property-invalid-character": "«$1» conté un caràcter «$2» llistat com a part d'una etiqueta de propietat i que s'ha classificat llavors com a no vàlid.",
"smw-datavalue-property-invalid-chain": "L'ús de «$1» com a cadena de propietat no està permès durant el procés d'anotació.",
"smw-datavalue-restricted-use": "El valor de dades s'ha marcat per a ús restringit «$1».",
@@ -533,15 +575,24 @@
"smw-type-tel": "«$1» és un tipus de dades especial per a descriure números de telèfon internacionals d'acord amb el RFC 3966.",
"smw-type-txt": "«$1» és un tipus de dades bàsic per descriure cadenes de longitud arbitrària.",
"smw-type-dat": "«$1» és un tipus de dades bàsic per representar punts en el temps en un format unificat.",
+ "smw-type-ema": "«$1» és un tipus de dades especial que representa una adreça electrònica.",
+ "smw-type-tem": "«$1» és un tipus de dades numèric especial que representa una temperatura.",
+ "smw-type-qty": "«$1» és un tipus de dades per descriure quantitats amb una representació numèrica i una unitat de mesura.",
+ "smw-type-rec": "«$1» és un tipus de dades de contenidor que especifica una llista de propietats amb tipus en un ordre fix.",
+ "smw-type-extra-tem": "L'esquema de conversió inclou unitats permeses, com ara Kelvin, Celsius, Fahrenheit i Rankine.",
"smw-type-tab-properties": "Propietats",
"smw-type-tab-types": "Tipus",
"smw-type-tab-errors": "Errors",
"smw-type-primitive": "Bàsic",
"smw-type-contextual": "Contextual",
"smw-type-compound": "Compost",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
+ "smw-special-pageproperty-description": "Aquesta pàgina proporciona una interfície de navegació por trobar tots els valors d'una propietat i una pàgina donada. Altres interfícies de cerca disponibles inclouen la [[Special:SearchByProperty|cerca de propietat]] i el [[Special:Ask|constructor de consultes]].",
"smw-property-predefined-errc": "«$1» és una propietat predefinida proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] i que representa errors que van aparèixer en connexió amb anotacions de valors o processament d'entrades no adequats.",
"smw-property-predefined-long-errc": "Els errors es recullen en un [https://www.semantic-mediawiki.org/wiki/Help:Container contenidor] que pot incloure una referència a la propietat que ha causat la discrepància.",
"smw-property-predefined-errt": "«$1» és una propietat predefinida que conté una descripció textual d'un error i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-subobject-parser-invalid-naming-scheme": "Un subobjecte definit per l'usuari que conté un esquema de noms no vàlid. La notació de punt ($1) utilitzada en els primers cinc caràcters està reservada per a extensions. Podeu definir un [https://www.semantic-mediawiki.org/wiki/Help:Adding_subobjects#Named_identifier identificador amb nom].",
"smw-datavalue-record-invalid-property-declaration": "La definició del registre conté la propietat «$1» que és declarada ella mateixa com a de tipus registre, i això no és permès.",
"smw-property-predefined-mime": "«$1» és una propietat predefinida que descriu el tipus MIME d'un fitxer carregat i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-datavalue-monolingual-dataitem-missing": "Manca un element esperat per a construir un valor compost monolingüe.",
@@ -549,15 +600,21 @@
"smw-datavalue-languagecode-invalid": "No s'ha reconegut «$1» com a codi de llengua permès.",
"smw-property-predefined-lcode": "«$1» una propietat predefinida que representa un codi de llengua formatat d'acord amb BCP47 i està proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-limitreport-intext-parsertime": "[SMW] Temps d'anàlisi de l'anotació en línia",
+ "smw-limitreport-intext-postproctime": "[SMW] durada de postprocessament",
"smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|segon|segons}}",
"smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|segon|segons}}",
"smw-limitreport-pagepurge-storeupdatetime": "[SMW] Temps d'actualització de l'emmagatzematge (en la purga de la pàgina)",
"smw-limitreport-pagepurge-storeupdatetime-value": "$1 {{PLURAL:$1|segon|segons}}",
+ "smw_allows_pattern": "S'espera que aquesta pàgina contingui una llista de referències (seguit per unes [https://ca.wikipedia.org/wiki/Expressi%C3%B3_regular expressions regulars]) que seran disponibles per a la propietat [[Property:Allows pattern|Permet patró]]. Per editar la pàgina cal el permís <code>smw-patternedit</code>.",
"smw-datavalue-allows-pattern-mismatch": "S'ha classificat «$1» com a no vàlid per l'expressió regular «$2».",
"smw-datavalue-allows-pattern-reference-unknown": "La referència de patró «$1» no ha pogut coincidir amb una entrada en [[MediaWiki:Smw allows pattern]].",
+ "smw-datavalue-allows-value-list-unknown": "La referència de llista «$1» no correspon a una pàgina de [[MediaWiki:Smw allows list $1]].",
+ "smw-datavalue-allows-value-list-missing-marker": "Al contingut de la llista «$1» hi manquen elements amb un marcador de llista *.",
"smw-datavalue-feature-not-supported": "La característica «$1» no és compatible amb el wiki o bé se n'ha inhabilitat.",
+ "smw-property-predefined-long-pvuc": "La unicitat s'estableix quan dos valors no són iguals en llur representació literal. Llavors qualsevol violació d'aquesta restricció es categoritzarà com error.",
"smw-datavalue-uniqueness-constraint-error": "La propietat «$1» només permet assignacions de valor únic i «$2» ja estava anotada en el subjecte «$3».",
"smw-datavalue-uniqueness-constraint-isknown": "La propietat «$1» només permet anotacions de valor úniques. «$2» ja conté un valor assignat. «$3» viola la restricció d'unicitat.",
+ "smw-datavalue-time-invalid-offset-zone-usage": "«$1» conté un decalatge i un fus horari no permesos.",
"smw-datavalue-time-invalid-values": "El valor «$1» conté informació no interpretable en la forma de «$2».",
"smw-datavalue-time-invalid-date-components-common": "«$1» conté informació que no és interpretable.",
"smw-datavalue-time-invalid-date-components-dash": "«$1» conté un guió extrínsec o altres caràcters que no són vàlids per a interpretar una data.",
@@ -566,10 +623,16 @@
"smw-datavalue-time-invalid-date-components-sequence": "«$1» conté una seqüència que no s'ha pogut interpretar amb una matriu de coincidències de components de dates.",
"smw-datavalue-time-invalid-ampm": "«$1» conté «$2» com element d'hora, que no és vàlid per a la convenció de 12 hores.",
"smw-datavalue-external-formatter-invalid-uri": "«$1» és un URL no vàlid.",
+ "smw-datavalue-external-identifier-formatter-missing": "A la propietat li manca una assignació d'[[Property:External formatter uri|«URI de formatador extern»]]",
+ "smw-datavalue-keyword-maximum-length": "La paraula clau ha excedit la longitud màxima de $1 {{PLURAL:$1|caràcter|caràcters}}.",
"smw-datavalue-parse-error": "El valor donat «$1» no s'ha entès.",
"smw-datavalue-propertylist-invalid-property-key": "La llista de propietats «$1» contenia una clau de propietat «$2» no vàlida.",
"smw-datavalue-type-invalid-typeuri": "El tipus «$1» no s'ha pogut transformar en una representació URI vàlida.",
"smw-datavalue-wikipage-missing-fragment-context": "No es pot utilitzar el valor d'entrada wikipage «$1» sense una pàgina de context.",
+ "smw-datavalue-wikipage-invalid-title": "El valor d'entrada de tipus pàgina «$1» conté caràcters no vàlids o és incomplet. Això pot causar resultats no esperats en una consulta o en el procés d'anotació.",
+ "smw-datavalue-wikipage-property-invalid-title": "La propietat «$1» (com a tipus de pàgina) amb un valor d'entrada «$2» conté caràcters no vàlids o és incomplet. Això pot causar resultats inesperats durant un procés de consulta o d'anotació.",
+ "smw-datavalue-wikipage-empty": "El valor d'entrada de pàgina wiki és buit (p. ex., <code>[[SomeProperty::]], [[]]</code>) i llavors no es pot utilitzar com a nom o part d'una condició de consulta.",
+ "smw-type-ref-rec": "«$1» és un tipus de [https://www.semantic-mediawiki.org/wiki/Container contenidor] que permet enregistrar informació addicional (p. ex., provinència de les dades) de l'assignació d'un valor.",
"smw-datavalue-reference-outputformat": "$1: $2",
"smw-parser-invalid-json-format": "L'analitzador de JSON ha retornat amb «$1».",
"smw-property-preferred-title-format": "$1 ($2)",
@@ -580,12 +643,15 @@
"smw-data-lookup-with-wait": "S'està processant la sol·licitud i pot trigar una estona.",
"smw-no-data-available": "No hi ha cap dada disponible.",
"smw-property-req-violation-type": "La propietat conté tipus d'especificacions que entren en conflicte entre elles, que pot resultar en anotacions de valors no vàlids. S'espera que un usuari hi assigni un tipus apropiat.",
+ "smw-change-propagation-protection": "Es bloqueja la pàgina per tal de prevenir modificacions de dades accidentals mentre s'executa una actualització de la [https://www.semantic-mediawiki.org/wiki/Change_propagation propagació de canvis]. Aquest procés pot trigar una estona abans que es torni a desbloquejar la pàgina i depèn de la mida i de la freqüència del programador de la [https://www.mediawiki.org/wiki/Manual:Job_queue cua de tasques].",
"smw-category-invalid-value-assignment": "«$1» no és reconeguda com a categoria o anotació de valor vàlida.",
"protect-level-smw-pageedit": "Permet només usuaris amb permisos d'edició de pàgines (Semantic MediaWiki)",
+ "smw-edit-protection-disabled": "S'ha inhabilitat la protecció de modificació; per tant, «$1» no pot utilitzar-se per protegir pàgines d'entitat de modificacions no autoritzades.",
"smw-edit-protection-auto-update": "Semantic MediaWiki ha actualitzat l'estat de protecció d'acord amb la propietat «Té protecció de modificació».",
"smw-edit-protection-enabled": "Modifica protegit (Semantic MediaWiki)",
"smw-patternedit-protection": "Aquesta pàgina està protegida i només pot ser modificada per usuaris amb els [https://www.semantic-mediawiki.org/wiki/Help:Permissions permisos] <code>smw-patternedit</code> adequats.",
"smw-property-predefined-edip": "«$1» és una propietat predeterminada proporcionada per [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] per a indicar si la modificació està protegida o no.",
+ "smw-property-predefined-long-edip": "Tot i que qualsevol usuaris pot afegir aquesta propietat al subjecte, només un usuari amb un permís dedicat pot modificar o revocar la protecció a una entitat després que s'hagi afegit.",
"smw-query-reference-link-label": "Referència de consulta",
"smw-format-datatable-emptytable": "No hi ha cap disponible a la taula",
"smw-format-datatable-info": "Es mostren les entrades_START_ a _END_ de _TOTAL_",
@@ -610,12 +676,15 @@
"smw-postproc-queryref": "Semantic MediaWiki està refrescant la pàgina actual d'acord amb la condició d'unes consultes de postprocessament obligatòries.",
"apihelp-smwinfo-summary": "Mòdul API per recuperar informació d'estadístiques de Semantic MediaWiki i d'altres metadades.",
"apihelp-ask-summary": "Mòdul API per consultar Semantic MediaWiki fent servir el llenguatge Ask.",
+ "apihelp-askargs-summary": "Mòdul API per fer consultes a Semantic MediaWiki utilitzant el llenguatge Ask com una llista de condicions, impressions i paràmetres.",
"apihelp-browsebyproperty-summary": "Mòdul API per recuperar informació d'una propietat o d'una llista de propietats.",
"apihelp-browsebysubject-summary": "Mòdul API per recuperar informació d'un tema.",
"apihelp-smwtask-summary": "Mòdul API per executar tasques relacionades amb Semantic MediaWiki.",
"apihelp-smwbrowse-summary": "Mòdul API per permetre les activitats de navegació de diferents tipus d'entitat a Semantic MediaWiki.",
"smw-api-invalid-parameters": "Paràmetres no vàlids, «$1»",
+ "smw-parser-recursion-level-exceeded": "S'ha excedit el nivell de $1 recurrències durant el procés d'anàlisi. Se suggereix que es valida l'estructura de la plantilla o, si s'escau, que s'ajusti el paràmetre de configuració <code>$maxRecursionDepth</code>.",
"smw-property-page-list-count": "Es mostren $1 {{PLURAL:$1|pàgina que utilitza|pàgines que utilitzen}} aquesta propietat.",
+ "smw-property-page-list-search-count": "Es {{PLURAL:$1|mostra $1 pàgina que fa servir|mostren $1 pàgines que fan servir}} aquesta propietat amb una correspondència de valor «$2».",
"smw-property-reserved-category": "Categoria",
"smw-category": "Categoria",
"smw-datavalue-uri-invalid-scheme": "No s'ha llistat «$1» com un esquema URI vàlid.",
@@ -633,10 +702,15 @@
"smw-processing": "S’està processant…",
"smw-redirect-target-unresolvable": "La destinació no es pot resoldre pel motiu «$1».",
"smw-types-title": "Tipus: $1",
+ "smw-schema-namespace-editcontentmodel-disallowed": "No es permet canviar el model de contingut d'una [https://www.semantic-mediawiki.org/wiki/Help:Schema pàgina d'esquema].",
+ "smw-schema-namespace-edit-protection": "Aquesta pàgina està protegida i només pot ser modificada per usuaris amb els [https://www.semantic-mediawiki.org/wiki/Help:Permissions permisos] <code>smw-schemaedit</code> adequats.",
"smw-schema-error": "Error de validació",
+ "smw-schema-error-schema": "L'especificació «$1» i la seva validació per l'esquema actual han trobat les incompatibilitats o violacions següents:",
"smw-schema-error-violation": "Violació (\"$1\", \"$2\")",
"smw-schema-error-type-missing": "Al contingut li manca un tipus per tal que sigui reconegut i usable a l'[https://www.semantic-mediawiki.org/wiki/Help:Schema espai de noms de l'esquema].",
+ "smw-schema-error-type-unknown": "El tipus «$1» no està registrat i llavors not pot utilitzar-se com a contingut a l'[https://www.semantic-mediawiki.org/wiki/Help:Schema espai de noms de l'esquema].",
"smw-schema-title": "Esquema",
+ "smw-schema-type-help-link": "https://www.semantic-mediawiki.org/wiki/Help:Schema/Type/$1",
"smw-schema-type": "Tipus",
"smw-schema-tag": "{{PLURAL:$1|Etiqueta|Etiquetes}}",
"smw-property-predefined-long-schema-tag": "Una etiqueta que identifica l'esquema de continguts o de característiques similars.",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/cs.json b/www/wiki/extensions/SemanticMediaWiki/i18n/cs.json
index c4715e3f..459bf2b4 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/cs.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/cs.json
@@ -17,7 +17,8 @@
"Martin Urbanec",
"Ilimanaq29",
"Patriccck",
- "Korytaacheck"
+ "Korytaacheck",
+ "Danny B."
]
},
"smw-desc": "Činíme vaší wiki přístupnější – pro stroje ''i'' lidi ([https://www.semantic-mediawiki.org/wiki/Help:User_manual online documentation])",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/de.json b/www/wiki/extensions/SemanticMediaWiki/i18n/de.json
index c093c7e1..051c46cb 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/de.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/de.json
@@ -25,8 +25,13 @@
"Nemo bis"
]
},
- "smw-desc": "Ermöglicht es, das Wiki zugänglicher zu machen – für Menschen ''und'' Maschinen ([https://www.semantic-mediawiki.org/wiki/Help:Nutzeranleitung Dokumentation])",
+ "smw-desc": "Ermöglicht es, das Wiki zugänglicher zu machen – für Menschen ''und'' Maschinen ([https://www.semantic-mediawiki.org/wiki/Help:User_manual/de Dokumentation])",
"smw-title": "Semantic MediaWiki",
+ "smw-upgrade-error": "Semantic MediaWiki wurde installiert und aktiviert, es fehlt jedoch der zugehörige [https://www.semantic-mediawiki.org/wiki/Help:Upgrade Aktualisierungsschlüssel]: <code>$1</code>.",
+ "smw-upgrade-error-why-title": "Warum wird diese Fehlermeldung angezeigt?",
+ "smw-upgrade-error-why-explain": "Die interne Struktur der von Semantic MediaWiki genutzten Datenbank hat sich verändert und erfordert Anpassungen, um störungsfrei funktionieren zu können. Für die Änderung kann es unter anderem mehrere Gründe geben:\n* ein feststehendes Attribut wurde hinzugefügt, das die Erstellung einer neuen Datenbanktabelle erfordert, bevor wieder auf die Datenbank zugegriffen werden kann\n* eine Softwareanpassung bedingt Änderungen an Tabellen oder Indizes der Datenbank, die eine Schemaaktualisierung bedingen, bevor wieder auf die Datenbank zugegriffen werden kann",
+ "smw-upgrade-error-how-title": "Wie kann dieser Fehler behoben werden?",
+ "smw-upgrade-error-how-explain": "Ein Administrator oder eine andere Person mit Administratorberechtigung muss entweder das Wartungsskript [https://www.mediawiki.org/wiki/Manual:Update.php „update.php“] von MediaWiki oder [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php „setupStore.php“] von Semantic MediaWiki ausführen. Weitergehende Informationen sind auf den folgenden Seiten verfügbar:\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation Installationsanweisungen]\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting Hilfeseite zu häufigen Problemen]",
"smw-semantics-not-enabled": "Momentan kann Semantic MediaWiki nicht auf diesem Wiki genutzt werden.",
"smw_viewasrdf": "RDF-Feed",
"smw_finallistconjunct": " und",
@@ -121,6 +126,7 @@
"smw-paramdesc-feeddescription": "Legt fest, welcher Text als Beschreibung des Feeds bei der Ausgabe der Abfrageergebnisse verwendet werden soll",
"smw-paramdesc-feedpagecontent": "Legt fest, ob der Seiteninhalt zusammen mit dem Feed bei der Ausgabe der Abfrageergebnisse angezeigt werden soll",
"smw-label-feed-description": "$2-Feed: $1",
+ "smw-paramdesc-mimetype": "Legt fest, welcher Medientyp (MIME-Typ) für die Ausgabedatei verwendet werden soll",
"smw_iq_disabled": "Semantische Abfragen wurden in diesem Wiki deaktiviert.",
"smw_iq_moreresults": "… weitere Ergebnisse",
"smw_parseerror": "Der eingegebene Wert wurde nicht verstanden.",
@@ -332,7 +338,7 @@
"smw_smwadmin_updatenotstopped": "Um den laufenden Aktualisierungsprozess vorzeitig zu beenden, muss das Kontrollkästchen markiert werden, um dadurch anzuzeigen, dass man sich diesbezüglich tatsächlich sicher ist.",
"smw-admin-docu": "Diese Spezialseite bietet während Installation, Aktualisierung, Wartung und Nutzung sowie bei weiteren administrativen Funktionen und Aufgaben von <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_–_Startseite\">Semantic MediaWiki</a> Unterstützung. Ebenso werden Statistiken bereitgestellt. Wichtige Daten sollten vor der Ausführung administrativer Funktionen gesichert werden.",
"smw-admin-environment": "Softwareumgebung",
- "smw-admin-db": "Datenbankwartung",
+ "smw-admin-db": "Datenbankeinrichtung",
"smw-admin-db-preparation": "Die Initialisierung der Datenbanktabellen wird gerade durchgeführt. Es kann etwas dauern, bis die Ergebnisse angezeigt werden. Der Zeitbedarf ist abhängig von der Größe und ggf. dem Optimierungsbedarf der Datenbanktabellen.",
"smw-admin-dbdocu": "Semantic MediaWiki benötigt weitere Datentabellen in der von MediaWiki genutzten Datenbank, um die semantischen Daten speichern zu können. Die folgende Sonderaufgabe gewährleistet, dass die Datenbank richtig eingerichtet wird. Die Datenbankänderungen, die in diesem Schritt durchgeführt werden, beeinträchtigen den übrigen Teil der von MediaWiki genutzten Datenbank nicht. Sie können, sofern dies gewünscht ist, leicht rückgängig gemacht werden.\nDiese Sonderaufgabe zur Einrichtung der Datentabellen kann mehrere Male ausgeführt werden, ohne Schaden zu verursachen. Indes ist es lediglich notwendig, sie einmal während der Installation oder der Aktualisierung von Semantic MediaWiki durchzuführen.",
"smw-admin-permissionswarn": "Sofern diese Aktion mit einem SQL-Fehler abbricht, könnte es sein, dass der Datenbankbenutzer, mit dem das Wiki auf die Datenbank zugreift (siehe die Datei „LocalSettings.php“), über keine ausreichenden Rechte verfügt.\nUm das Problem zu beheben, ist es notwendig, entweder dem Datenbankbenutzer zusätzliche Rechte zur Erstellung und Löschung von Datenbanktabellen einzuräumen, den Datenbankadministrator zeitweilig in die Datei „LocalSettings.php“ einzutragen, oder aber das Wartungsskript „setupStore.php“ zu nutzen, das von einem Serveradministrator mit Administrationsberechtigung ausgeführt werden kann.",
@@ -383,7 +389,7 @@
"smw-admin-questions": "Im Fall von Fragen oder Anregungen kann man sich an den Diskussionen auf der <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">Mailingliste für Nutzer</a> oder im <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">Chatroom</a> beteiligen.",
"smw-admin-other-functions": "Weitere Statistiken",
"smw-admin-supplementary-section-title": "Zusätzliche Funktionen",
- "smw-admin-supplementary-section-subtitle": "Verfügbare Funktionen",
+ "smw-admin-supplementary-section-subtitle": "Allgemeine Funktionen",
"smw-admin-supplementary-section-intro": "In diesem Abschnitt werden weitere Funktionen zusätzlich zu denen der Wartung bereitgestellt. Es ist möglich, dass einige in der [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions Dokumentation] gelisteten Funktionen entweder zugriffsbeschränkt oder nicht verfügbar sind und deshalb nicht auf diesem Wiki genutzt werden können.",
"smw-admin-supplementary-settings-title": "Konfigurationseinstellungen",
"smw-admin-supplementary-settings-intro": "$1 – Zeigt eine Liste der verfügbaren von Semantic MediaWiki verwendeten Konfigurationseinstellungen",
@@ -398,9 +404,10 @@
"smw-admin-supplementary-operational-statistics-cache-title": "Statistiken zum Cache",
"smw-admin-supplementary-operational-statistics-cache-intro": "$1 – Zeigt Statistiken zur Nutzung des Caches an",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
+ "smw-admin-supplementary-elastic-section-subtitle": "Funktionen zu Elasticsearch",
"smw-admin-supplementary-elastic-intro": "$1 – informiert über Einstellungen und Indexstatistiken",
"smw-admin-supplementary-elastic-docu": "Diese Seite bietet Informationen zu Einstellungen, Mappings, Betriebsstatus sowie Indexstatistiken des Elasticsearch-Clusters, der von Semantic MediaWiki über dessen [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore „ElasticStore“] genutzt wird.",
- "smw-admin-supplementary-elastic-functions": "Verfügbare Funktionen",
+ "smw-admin-supplementary-elastic-functions": "Unterstützte Funktionen",
"smw-admin-supplementary-elastic-settings-title": "Einstellungen",
"smw-admin-supplementary-elastic-settings-intro": "$1 – Zeigt eine Übersicht der Einstellungen, die von Elasticsearch verwendet werden, um die von Semantic MediaWiki genutzten Indizes zu verwalten",
"smw-admin-supplementary-elastic-mappings-title": "Mappings",
@@ -515,9 +522,22 @@
"smw-admin-objectid": "Kennung:",
"smw-admin-tab-general": "Übersicht",
"smw-admin-tab-notices": "Hinweise zur Konfiguration",
- "smw-admin-tab-rebuild": "Wartung",
+ "smw-admin-tab-maintenance": "Wartung",
"smw-admin-tab-supplement": "Zusätzliche Funktionen",
"smw-admin-tab-registry": "Wikiregistrierung",
+ "smw-admin-maintenance-no-description": "Es ist keine Beschreibung vorhanden.",
+ "smw-admin-maintenance-script-section-title": "Liste verfügbarer Wartungsskripte",
+ "smw-admin-maintenance-script-section-intro": "Die folgenden Wartungsskripte können nur von einem Systemadministrator über die Kommandozeile des Servers ausgeführt werden:",
+ "smw-admin-maintenance-script-description-dumprdf": "Ermöglicht den RDF-Export der vorhandenen semantische Tripel.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "Ermöglicht die Verwaltung (Erstellung, Löschung und Aktualisierung) semantischer Konzepte.",
+ "smw-admin-maintenance-script-description-rebuilddata": "Ermöglicht das Erstellen oder Aktualisieren aller in der Datenbank gespeicherten semantischen Daten.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "Ermöglicht das Erstellen oder Aktualisieren aller im Elasticsearch-Index gespeicherten semantischen Daten, sofern Elasticsearch genutzt wird.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "Ermöglicht das Erstellen oder Aktualisieren aller im Suchindex der Volltextsuche gespeicherten Daten, sofern die Volltextsuche genutzt wird.",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "Ermöglicht das Aktualisieren der Statistik zur Attributnutzung.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "Ermöglicht das Entfernen von Datenobjektduplikaten, die in der Datenbank über keine aktiven Verknüpfungen mehr verfügen.",
+ "smw-admin-maintenance-script-description-setupstore": "Ermöglicht das Erstellen oder Aktualisieren der für die Speicherung semantischer Daten konfigurierten Datenbank.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "Ermöglicht das Aktualisieren des Datenbankfelds <code>smw_sort</code> in der relationalen Datenbank (in Übereinstimmung mit der [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation Konfiguration des Parameters <code>$smwgEntityCollation</code>]).",
+ "smw-admin-maintenance-script-description-populatehashfield": "Ermöglicht das Befüllen des Datenbankfelds <code>smw_hash</code> in der relationalen Datenbank.",
"smw-livepreview-loading": "Lade …",
"smw-sp-searchbyproperty-description": "Diese Seite stellt eine einfache [https://www.semantic-mediawiki.org/wiki/Help:Semantisches_Browsen Suchoberfläche] zum Finden von Objekten bereit, die ein Attribut mit einem bestimmten Datenwert enthalten. Andere verfügbare Suchoberflächen sind die [[Special:PageProperty|Attributsuche]] sowie der [[Special:Ask|Abfragengenerator]].",
"smw-sp-searchbyproperty-resultlist-header": "Liste der Ergebnisse",
@@ -641,6 +661,7 @@
"smw-property-predefined-askco": "„$1“ ist ein softwareseitig fest definiertes Attribut, das den [https://www.semantic-mediawiki.org/wiki/Help:Special_property_Query_status_code Statuscode von Abragen] speichert. Es wird von [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] zur Verfügung gestellt.",
"smw-property-predefined-long-askco": "Die gespeicherte Zahl oder gespeicherten Zahlen stehen für den softwareintern genutzten Code des Status, in dem sich die jeweilige Abfrage befindet. Weitere Informationen sind auf der entsprechenden [https://www.semantic-mediawiki.org/wiki/Help:Query_profiler Hilfeseite] vorhanden.",
"smw-property-predefined-prec": "„$1“ ist ein softwareseitig fest definiertes Attribut, das die [https://www.semantic-mediawiki.org/wiki/Help:Display_precision Anzeigegenauigkeit] für numerische Datentypen dezimal speichert. Es wird von [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] zur Verfügung gestellt.",
+ "smw-property-predefined-attch-link": "„$1“ ist ein softwareseitig fest definiertes Attribut, das die Links zu den auf einer Seite eingebetteten Dateien speichert. Es wird von [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] zur Verfügung gestellt.",
"smw-types-extra-geo-not-available": "Die Softwareerweiterung [https://www.semantic-mediawiki.org/wiki/Extension:Maps „Maps“] ist nicht installiert. Daher ist das Attribut „$1“ in seiner Nutzbarkeit eingeschränkt.",
"smw-datavalue-monolingual-dataitem-missing": "Ein erwartetes Element zum Erstellen eines einsprachigen zusammengesetzten Wertes fehlt.",
"smw-datavalue-languagecode-missing": "Zur Annotation „$1“ konnte kein Sprachcode festgestellt werden (z.&nbsp;B. „xyz@de“).",
@@ -778,6 +799,7 @@
"smw-property-reserved-category": "Kategorie",
"smw-category": "Kategorie",
"smw-datavalue-uri-invalid-scheme": "„$1“ ist nicht als zulässiges URI-Schema gelistet.",
+ "smw-datavalue-uri-invalid-authority-path-component": "„$1“ enthält mit „$2“ eine ungültige Zuständigkeits- oder Pfadkomponente.",
"smw-browse-property-group-title": "Attributgruppe",
"smw-browse-property-group-label": "Attributgruppenbezeichnung",
"smw-browse-property-group-description": "Attributgruppenbeschreibung",
@@ -830,5 +852,8 @@
"smw-ask-tab-result": "Ergebnis",
"smw-ask-tab-extra": "Extra",
"smw-ask-tab-debug": "Fehleranalyse",
- "smw-ask-tab-code": "Code"
+ "smw-ask-tab-code": "Code",
+ "smw-install-incomplete-intro": "Die Installation oder Aktualisierung von <b>Semantic MediaWiki</b> wurde noch nicht vollständig abgeschlossen. Ein Administrator oder eine andere Person mit Administratorberechtigung muss daher die folgenden Aufgaben ausführen, um Dateninkonsistenzen zu vermeiden, bevor die Nutzer des Wikis bestehende Inhalte ändern oder weitere Inhalte erstellen:",
+ "smw-install-incomplete-populate-hash-field": "Die Befüllung des Datenbankfeldes <code>smw_hash</code> wurde während des Setups aufgrund des Umfangs der Datenbank abgebrochen. Das Wartungsskript [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php „populateHashField.php“] muss ausgeführt werden, um diese Aufgabe zu beenden.",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/el.json b/www/wiki/extensions/SemanticMediaWiki/i18n/el.json
index 13c16588..0dad029d 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/el.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/el.json
@@ -404,7 +404,6 @@
"smw-admin-idlookup-input": "Αναζήτηση:",
"smw-admin-objectid": "Αναγνωριστικό:",
"smw-admin-tab-general": "Επισκόπηση",
- "smw-admin-tab-rebuild": "Συντήρηση",
"smw-admin-tab-supplement": "Συμπληρωματικές λειτουργίες",
"smw-admin-tab-registry": "Μητρώο",
"smw-livepreview-loading": "Φόρτωση σε εξέλιξη...",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/en.json b/www/wiki/extensions/SemanticMediaWiki/i18n/en.json
index cded18fd..a1375e24 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/en.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/en.json
@@ -9,6 +9,11 @@
},
"smw-desc": "Making your wiki more accessible - for machines ''and'' humans ([https://www.semantic-mediawiki.org/wiki/Help:User_manual online documentation])",
"smw-title": "Semantic MediaWiki",
+ "smw-upgrade-error": "Semantic MediaWiki was installed and enabled but is missing an appropriate [https://www.semantic-mediawiki.org/wiki/Help:Upgrade upgrade key] that matches: <code>$1</code>.",
+ "smw-upgrade-error-why-title": "Why Do I see this error?",
+ "smw-upgrade-error-why-explain": "Semantic MediaWiki's internal database structure has changed and requires some adjustments to be fully functional. There can be several reasons including:\n* Additional fixed properties (requires additional table setup) were added \n* An upgrade contains some changes to tables or indices making an interception obligatory before accessing the data",
+ "smw-upgrade-error-how-title": "How Do I fix this error?",
+ "smw-upgrade-error-how-explain": "An administrator (or any person with administrator rights) has to run either MediaWiki's [https://www.mediawiki.org/wiki/Manual:Update.php update.php] or Semantic MediaWiki's [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] maintenance script. You may also consult the following pages for further assistance:\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation Installation] instructions\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting Troubleshooting] help page",
"smw-semantics-not-enabled": "Semantic MediaWiki functionality was not enabled for this wiki.",
"smw_viewasrdf": "RDF feed",
"smw_finallistconjunct": ", and",
@@ -107,6 +112,7 @@
"smw-paramdesc-feedpagecontent": "Page content to be displayed with the feed",
"smw-label-feed-link": "RSS",
"smw-label-feed-description": "$1 $2 feed",
+ "smw-paramdesc-mimetype": "The media type (MIME type) for the output file",
"smw_iq_disabled": "Semantic queries have been disabled for this wiki.",
"smw_iq_moreresults": "... further results",
"smw_parseerror": "The given value was not understood.",
@@ -410,8 +416,8 @@
"smw-admin-supplementary-elastic-status-recovery-job-count": "Recovery job backlog: $1 (estimation)",
"smw-admin-supplementary-elastic-status-file-ingest-job-count": "Injest (file) job backlog: $1 (estimation)",
"smw-admin-supplementary-elastic-status-rebuild-lock": "Replication locked: $1 (rebuild in-progress)",
- "smw-list-count": "The list contains $1 {{PLURAL:$1|entry|entries}}.",
- "smw-list-count-from-cache": "The list contains $1 {{PLURAL:$1|entry|entries}} and was retrieved from cache (UTC: $2).",
+ "smw-list-count": "The list contains $1 entry (or entries).",
+ "smw-list-count-from-cache": "The list contains $1 entry (or entries) and was retrieved from cache (UTC: $2).",
"smw-property-label-uniqueness" : "The \"$1\" label was matched to at least one other property representation. Please consult the [https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness help page] on how to resolve this issue.",
"smw-property-label-similarity-title": "Property label similarity report",
"smw-property-label-similarity-intro": "<u>$1</u> calculates similarities for existing property labels",
@@ -774,6 +780,7 @@
"smw-property-reserved-category": "Category",
"smw-category": "Category",
"smw-datavalue-uri-invalid-scheme": " \"$1\" has not been listed as valid URI scheme.",
+ "smw-datavalue-uri-invalid-authority-path-component": "\"$1\" has been idendified to contain an invalid \"$2\" authority or path component.",
"smw-browse-property-group-title": "Property group",
"smw-browse-property-group-label": "Property group label",
"smw-browse-property-group-description": "Property group description",
@@ -827,5 +834,7 @@
"smw-ask-tab-extra": "Extra",
"smw-ask-tab-debug": "Debug",
"smw-ask-tab-code": "Code",
- "smw-helplink-concepts": "https://www.semantic-mediawiki.org/wiki/Help:Concepts"
+ "smw-helplink-concepts": "https://www.semantic-mediawiki.org/wiki/Help:Concepts",
+ "smw-install-incomplete-intro": "The installation (or upgrade) of <b>Semantic MediaWiki</b> has not been finalized and an administrator should run the following tasks to prevent data inconsistencies before users continue to create or alter content.",
+ "smw-install-incomplete-populate-hash-field": "The <code>smw_hash</code> field population was skipped during the setup, the [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php] script is required to be executed."
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/es.json b/www/wiki/extensions/SemanticMediaWiki/i18n/es.json
index 17d285cb..cbcc424c 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/es.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/es.json
@@ -146,6 +146,7 @@
"smw-paramdesc-feedpagecontent": "Contenido de página que se mostrará con el suministro",
"smw-label-feed-link": "RSS",
"smw-label-feed-description": "Fuente de noticias $1 $2",
+ "smw-paramdesc-mimetype": "El tipo de medio (MIME) del archivo de salida",
"smw_iq_disabled": "Se han desactivado las consultas semánticas en este wiki.",
"smw_iq_moreresults": "... más resultados",
"smw_parseerror": "No se comprendió el valor provisto.",
@@ -537,7 +538,6 @@
"smw-admin-objectid": "Identificador:",
"smw-admin-tab-general": "Visión general",
"smw-admin-tab-notices": "Avisos de obsolescencia",
- "smw-admin-tab-rebuild": "Mantenimiento",
"smw-admin-tab-supplement": "Funciones suplementarias",
"smw-admin-tab-registry": "Registro",
"smw-livepreview-loading": "Cargando…",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/eu.json b/www/wiki/extensions/SemanticMediaWiki/i18n/eu.json
index 84ee22ba..f5c1f4eb 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/eu.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/eu.json
@@ -277,7 +277,6 @@
"smw-admin-idlookup-input": "Bilatu:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Ikuspegi orokorra",
- "smw-admin-tab-rebuild": "Mantenimendua",
"smw-admin-tab-supplement": "Funtzio osagarriak",
"smw-admin-tab-registry": "Erregistroa",
"smw-livepreview-loading": "Kargatzen…",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/fa.json b/www/wiki/extensions/SemanticMediaWiki/i18n/fa.json
index c1c08a73..ecf72ec0 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/fa.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/fa.json
@@ -14,7 +14,8 @@
"DEXi",
"Ommmmid",
"Obzord",
- "Alifakoor"
+ "Alifakoor",
+ "Physicsch"
]
},
"smw-desc": "ویکی خود را بیشترقابل دسترس کنید- برای ماشین‌ها ''و'' انسان‌ها ([https://www.semantic-mediawiki.org/wiki/Help:User_manual online documentation])",
@@ -54,13 +55,13 @@
"smw-paramdesc-intro": "متن برای نمایش قبل از نتایج پرس‌و‌جو، اگر وجود داشته باشند",
"smw-paramdesc-outro": "متن برای نمایش پس از نتایج پرس‌و‌جو، اگر وجود داشته باشد",
"smw-paramdesc-default": "متن برای نمایش اگر هیچ نتایج پرس‌وجویی وجود نداشته باشد",
- "smw-paramdesc-sep": "جدا کننده برای مقادیر",
+ "smw-paramdesc-sep": "جدا کننده میان نتایج",
"smw-paramdesc-showsep": "نمایش جدا کننده در بالای پوشه سی‌اس‌وی (\"sep=<value>\")",
"smw-paramdesc-distribution": "به جای نمایش همه مقادیر، میزان وقوع آنها را حساب کنید،این‌ها را نشان دهید.",
"smw-paramdesc-distributionsort": "نوع توزیع مقدار توسط حساب میزان وقوع.",
"smw-paramdesc-distributionlimit": "محدود کردن توزیع مقدار به حساب فقط برخی از مقادیر.",
"smw-paramdesc-template": "نام یک الگو با آنی که چاپ‌ها را نمایش می‌دهد",
- "smw-paramdesc-columns": "تعداد ستون ها در آنی که نتایج را نمایش می‌دهد (پیش‌فرض $1 است)",
+ "smw-paramdesc-columns": "تعداد ستون‌هایی که نتایج در آن‌ها نمایش می‌یابند",
"smw-paramdesc-userparam": "اگر یک الگو استفاده شده‌است، یک مقدار در هر تماس الگو عبور کرده",
"smw-paramdesc-introtemplate": "نام الگو برای نمایش قبل از نتایج پرس‌و‌جو، اگر وجود داشته باشد",
"smw-paramdesc-outrotemplate": "نام الگو برای نمایش پس از نتایج پرس‌و‌جو، اگر وجود داشته باشد",
@@ -262,14 +263,14 @@
"smw_inverse_label_property": "برچسب خصوصیت برعکس",
"pageproperty": "جستجوی خصوصیت صفحه",
"smw_pp_docu": "جستجو برای همه مقادیر خاصیت در صفحه داده شده.\nصفحه و خاصیت، هر دو را وارد کنید.",
- "smw_pp_from": "از صفحه",
- "smw_pp_type": "ویژگی",
+ "smw_pp_from": "از صفحه:",
+ "smw_pp_type": "ویژگی:",
"smw_pp_submit": "ویژگی",
"smw_result_prev": "قبلی",
"smw_result_next": "بعدی",
"smw_result_results": "نتایج",
"smw_result_noresults": "بدون نتیجه",
- "smwadmin": "عملکردهای مدیریتی",
+ "smwadmin": "توابع مدیریتی و نگهداری",
"smw-admin-statistics-job-title": "آمار کار",
"smw-admin-statistics-querycache-title": "آمار میان‌گیر پرسمان",
"smw-admin-statistics-querycache-disabled": " [https://www.semantic-mediawiki.org/wiki/QueryCache میان‌گیر پرسمان] در این ویکی فعال نشده است، بنابراین هیچ آماری موجود نیست.",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/fi.json b/www/wiki/extensions/SemanticMediaWiki/i18n/fi.json
index 3fc0e2bc..6bb7413e 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/fi.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/fi.json
@@ -12,11 +12,14 @@
"Pyscowicz",
"01miki10",
"Pahkiqaz",
- "Surjection"
+ "Surjection",
+ "Valtlait"
]
},
- "smw-desc": "Lisää wikisi helppokäyttöisyyttä - niin koneille \"kuin\" ihmisillekin ([https://www.semantic-mediawiki.org/wiki/Help:User_manual käyttäjän opas])",
+ "smw-desc": "Lisää wikisi saavutettavuutta – niin koneille kuin ihmisille ([https://www.semantic-mediawiki.org/wiki/Help:User_manual verkko-opas])",
"smw-title": "Semanttinen MediaWiki",
+ "smw-upgrade-error-why-title": "Miksi näen tämän virheen?",
+ "smw-upgrade-error-how-title": "Miten korjaan tämän virheen?",
"smw-semantics-not-enabled": "Semanttisen MediaWikin toiminnallisuutta ei ole otettu käyttöön tässä wikissä.",
"smw_viewasrdf": "RDF-syöte",
"smw_finallistconjunct": " ja",
@@ -29,7 +32,7 @@
"smw_multiple_concepts": "Kullakin käsitesivulla voi olla vain yksi käsitteen määritelmä.",
"smw_noinvannot": "Arvoja ei voi kohdistaa käänteisiin ominaisuuksiin.",
"version-semantic": "Semanttiset laajennukset",
- "smw_baduri": "$1 ei ole sallittu URI:n muoto.",
+ "smw_baduri": "$1 ei ole sallittu URIn muoto.",
"smw_printername_count": "Laskennan tulokset",
"smw_printername_csv": "CSV-vienti",
"smw_printername_dsv": "DSV-vienti",
@@ -41,6 +44,7 @@
"smw_printername_table": "Taulukko",
"smw_printername_broadtable": "Leveä taulukko",
"smw_printername_template": "Malline",
+ "smw_printername_templatefile": "Mallinetiedosto",
"smw_printername_rdf": "RDF-vienti",
"smw_printername_category": "Luokka",
"validator-type-class-SMWParamSource": "teksti",
@@ -81,33 +85,33 @@
"smw_kiloseparator": "&nbsp;",
"smw_notitle": "Nimeä ”$1” ei voi käyttää sivun nimenä tässä wikissä.",
"smw_noproperty": "Nimeä ”$1” ei voi käyttää ominaisuuden nimenä tässä wikissä.",
- "smw_wrong_namespace": "Vain nimiavaruuden \"$1\" sivut sallitaan tässä.",
+ "smw_wrong_namespace": "Vain nimiavaruuden ”$1” sivut sallitaan tässä.",
"smw_manytypes": "Ominaisuudelle on määritelty useampi kuin yksi tyyppi.",
"smw_emptystring": "Tyhjiä merkkijonoja ei hyväksytä.",
- "smw_notinenum": "\"$1\" ei ole ominaisuuden \"$3\" [[Property:Allows value|sallittujen arvojen]] luettelossa ($2).",
+ "smw_notinenum": "”$1” ei ole ominaisuuden ”$3” [[Property:Allows value|sallittujen arvojen]] luettelossa ($2).",
"smw_noboolean": "”$1” ei ole tunnistettavissa totuusarvoksi.",
"smw_true_words": "kyllä,k,y",
"smw_false_words": "ei,e,n",
"smw_nofloat": "”$1” ei ole luku.",
- "smw_infinite": "Numeron \"$1\" kokoisia arvoja ei tueta.",
- "smw_unitnotallowed": "\"$1\" ei ole sallittu mittayksikkö tälle ominaisuudelle.",
+ "smw_infinite": "Arvon ”$1” kokoisia lukuja ei tueta.",
+ "smw_unitnotallowed": "”$1” ei ole sallittu mittayksikkö tälle ominaisuudelle.",
"smw_nounitsdeclared": "Tälle ominaisuudelle ei ole määritetty mittayksikköä.",
"smw_novalues": "Arvoja ei ole määritetty.",
"smw_nodatetime": "Päiväystä ”$1” ei tunnistettu.",
- "smw_toomanyclosing": "Hakukyselyssä tuntuisi olevan liian monta esiintymää \"$1\" termistä.",
- "smw_noclosingbrackets": "Joiltain kyselyn hakasuluilta \"<nowiki>[[</nowiki>\" puuttuu sulkevat hakasulut \"]]\".",
- "smw_misplacedsymbol": "Symbolia \"$1\" käytettiin yhteydessä johon se ei soveltunut.",
- "smw_unexpectedpart": "Kyselyn osaa \"$1\" ei voitu tulkita.\nTulokset eivät ehkä vastaa odotuksia.",
+ "smw_toomanyclosing": "Hakukyselyssä tuntuisi olevan liian monta termin ”$1” esiintymää.",
+ "smw_noclosingbrackets": "Joiltain kyselyn hakasuluilta ”<nowiki>[[</nowiki>” puuttuu sulkevat hakasulut ”]]”.",
+ "smw_misplacedsymbol": "Symbolia ”$1” käytettiin yhteydessä, johon se ei soveltunut.",
+ "smw_unexpectedpart": "Kyselyn osaa ”$1” ei voitu tulkita.\nTulokset eivät ehkä vastaa odotuksia.",
"smw_emptysubquery": "Jollakin alikyselyllä ei ole kelvollista ehtoa.",
"smw_misplacedsubquery": "Jotain alikyselyä käytettiin kohdassa, jossa alikysely ei ole sallittu.",
"smw_valuesubquery": "Alikyselyjä ei tueta ominaisuuden ”$1” arvoille.",
- "smw_badqueryatom": "Kyselyn osaa \"<nowiki>[[…]]</nowiki>\" ei voitu tulkita.",
- "smw_propvalueproblem": "Ominaisuuden \"$1\" arvoa ei voitu tulkita.",
+ "smw_badqueryatom": "Kyselyn osaa \"<nowiki>[[...]]</nowiki>\" ei voitu tulkita.",
+ "smw_propvalueproblem": "Ominaisuuden ”$1” arvoa ei voitu tulkita.",
"smw_noqueryfeature": "Joitain kyselyn ehtoja ei tueta tässä wikissä ja siksi osa kyselystä jäi tekemättä ($1).",
"smw_noconjunctions": "Kyselyjen JA-toimituksia ei tueta tässä wikissä ja siksi osa kyselystä jäi tekemättä ($1).",
"smw_nodisjunctions": "Kyselyjen TAI-toimituksia ei tueta tässä wikissä ja siksi osa kyselystä jäi tekemättä ($1).",
"smw_querytoolarge": "{{PLURAL:$2|Seuraavaa kyselyehtoa|Seuraavia kyselyehtoja}} ei voitu huomioida tämän wikin kyselyjen koko- tai syvyysrajoituksen vuoksi: <code>$1</code>.",
- "smw_notemplategiven": "Parametri \"template\" on pakollinen, jotta tämä kyselymuoto toimisi.",
+ "smw_notemplategiven": "Parametri ”template” on pakollinen, jotta tämä kyselymuoto toimisi.",
"smw_db_sparqlqueryproblem": "Kyselyn tulosta ei voitu noutaa SPARQL-tietokannasta. Virhe voi olla väliaikainen tai osoitus tietokannan ohjelmistovirheestä.",
"smw_db_sparqlqueryincomplete": "Kyselyyn vastaaminen osoittautui liian vaikeaksi ja kysely keskeytettiin. Jotkut tulokset voivat puuttua. Voit yrittää uudelleen yksinkertaisemmalla kyselyllä mikäli vain mahdollista.",
"smw_type_header": "Ominaisuudet jotka ovat tyypiltään $1",
@@ -117,6 +121,8 @@
"smw-propertylist-subproperty-header": "Alaominaisuudet",
"smw-propertylist-redirect-header": "Synonyymit",
"smw-propertylist-count": "Näytetään $1 liittyvä(ä) {{PLURAL:$1|kokonaisuus|kokonaisuutta}}.",
+ "smw-propertylist-count-more-available": "Näytetään $1 liittyvää {{PLURAL:$1|aihe|aihetta}} (lisää on saatavilla).",
+ "specialpages-group-smw_group": "Semanttinen MediaWiki",
"exportrdf": "Vie sivut RDF:nä",
"smw_exportrdf_docu": "Tämän sivun avulla voit noutaa sivun tiedot RDF-muodossa.\nSyötä vietävien sivujen otsikot alla olevaan tekstiruutuun, yksi otsikko yhdellä rivillä.",
"smw_exportrdf_recursive": "Tee vienti rekursiivisesti kaikista liittyvistä sivuista.\nHuomioi, että tulos saattaa olla suuri.",
@@ -148,6 +154,7 @@
"smw_purge": "Päivitä",
"smw-purge-failed": "Päivitys epäonnistui",
"types": "Tyypit",
+ "smw-special-types-no-such-type": "\"$1\" on tuntematon tai sitä ei ole määritetty kelvolliseksi tietotyypiksi.",
"smw-statistics": "Semanttiset tilastot",
"smw-statistics-query-size": "Kyselyn koko",
"smw-statistics-concept-count-legacy": "{{PLURAL:$1|Käsite|Käsitteet}}",
@@ -160,7 +167,8 @@
"smw_ask_submit": "Hae tuloksia",
"smw_ask_editquery": "Muokkaa kyselyä",
"smw_add_sortcondition": "[Lisää lajitteluehto]",
- "smw_ask_hidequery": "Piilota kysely",
+ "smw-ask-sort-add-action": "Lisää lajitteluehto",
+ "smw_ask_hidequery": "Piilota kysely (tiivis näkymä)",
"smw_ask_help": "Hakukyselyn ohjeet",
"smw_ask_queryhead": "Edellytys",
"smw_ask_printhead": "Valinnaiset näytettävät tiedot",
@@ -176,17 +184,20 @@
"smw-ask-delete": "Poista",
"smw-ask-sorting": "Lajittelu",
"smw-ask-options": "Asetukset",
+ "smw-ask-options-sort": "Järjestä valinnat",
"smw-ask-format-options": "Rakenne ja asetukset",
"smw-ask-parameters": "Parametrit",
"smw-ask-search": "Hae",
"smw-ask-debug": "Vianetsintä",
- "smw-ask-no-cache": "Ei välimuistia",
+ "smw-ask-no-cache": "Poista kyselyn välimuisti käytöstä",
+ "smw-ask-no-cache-desc": "Tulokset ilman kyselyn välimuistia",
"smw-ask-result": "Tulos",
"smw-ask-empty": "Tyhjennä kaikki merkinnät",
"smw-ask-download-link-desc": "Lataa kysytyt tulokset $1-muodossa",
"smw-ask-format": "Muoto",
"smw-ask-format-selection-help": "Yksityiskohtaiset tiedot löytyvät sivulta $1.",
"searchbyproperty": "Selaaminen ominaisuuksittain",
+ "processingerrorlist": "Käsittelyvirheluettelo",
"smw_sbv_docu": "Voit selata sivuja, joilla on tietty arvo tietylle ominaisuudelle.",
"smw_sbv_novalue": "Syötä ominaisuuden arvo alle. Lista mahdollisista arvoista löytyy sivulta $1.",
"smw_sbv_displayresult": "Lista kaikista sivuista, joilla ominaisuuden $1 arvona on $2.",
@@ -224,7 +235,7 @@
"smw_smwadmin_updatenotstopped": "Jos haluat pysäyttää käynnissä olevan päivitysprosessin, varmista päätöksesi aktivoimalla valintaruutu.",
"smw-admin-docu": "Tämä toimintosivu auttaa <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWikin</a> asennuksessa, päivityksessä, ylläpidossa ja käytössä sekä tarjoaa myös enemmän hallinnollisia funktioita ja tehtäviä, kuten myös tilastoja.\n\n\nMuista tehdä varmuuskopiot tärkeistä tiedoista ennen kuin aloitat ylläpitotoiminnot.",
"smw-admin-environment": "Ohjelmistoympäristö",
- "smw-admin-db": "Tietokannan huolto",
+ "smw-admin-db": "Tietokannan asennus",
"smw-admin-dbdocu": "Semantic MediaWiki tarvitsee joitain MediaWiki-tietokannan laajennuksia, jotta semanttista tietoa voidaan tallentaa.\nAlla oleva toiminto varmistaa, että tietokanta on asennettu oikein.\nTässä vaiheessa tehdyt muutokset eivät vaikuta muuhun MediaWiki-tietokantaan ja muutokset on helppo tarvittaessa kumota.\nAsennus voidaan suorittaa monta kertaa ilman että siitä ei aiheutuisi vahinkoa, mutta se on tehtävä vain kerran asennuksen tai päivityksen yhteydessä.",
"smw-admin-dbbutton": "Alusta tai päivitä taulukot",
"smw-admin-announce": "Julkista wikisi",
@@ -242,11 +253,14 @@
"smw-admin-installfile": "Jos asennuksen kanssa on ongelmia, lue ensin <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md\">INSTALL-tiedoston</a> ohjeet ja <a href=\"https://www.semantic-mediawiki.org/wiki/Help:Installation\">asennussivu</a>.",
"smw-admin-smwhomepage": "Semantic MediaWikin täydellinen käyttäjän opas löytyy osoitteesta <b><a href=\"https://www.semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
"smw-admin-bugsreport": "Ohjelmistovirheet voi raportoida <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">GitHubiin</a>.",
- "smw-admin-questions": "Jos sinulla on kysymyksiä tai ehdotuksia, liity keskusteluun <a href=\"http://sourceforge.net/mailarchive/forum.php?forum_name=semediawiki-user\">Semanttisen MediaWikin käyttäjäfoorumilla</a>.",
+ "smw-admin-questions": "Jos sinulla on kysymyksiä tai ehdotuksia, liity keskusteluun <a href=\"http://sourceforge.net/mailarchive/forum.php?forum_name=semediawiki-user\">Semanttisen MediaWikin käyttäjäfoorumilla</a> tai <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">keskusteluhuoneessa</a>.",
"smw-admin-supplementary-settings-title": "Määritysasetukset",
+ "smw-admin-supplementary-operational-statistics-cache-title": "Välimuistitilastot",
"smw-admin-supplementary-elastic-settings-title": "Asetukset",
+ "smw-admin-supplementary-elastic-mappings-summary": "Yhteenveto",
"smw-admin-supplementary-elastic-statistics-title": "Tilastot",
"smw-property-label-similarity-threshold": "Kynnys:",
+ "smw-property-label-similarity-noresult": "Valituilla asetuksilla ei löytynyt yhtään tulosta.",
"smw_adminlinks_datastructure": "Tietorakenne",
"smw_adminlinks_displayingdata": "Tietojen näyttö",
"smw_adminlinks_inlinequerieshelp": "Upotettujen kyselyjen ohje",
@@ -258,7 +272,7 @@
"smw-info-par-message": "Näytettävä sanoma.",
"prefs-smw": "Semanttinen MediaWiki",
"prefs-general-options": "Yleiset asetukset",
- "prefs-ask-options": "Semanttiset hakuvalinnat",
+ "prefs-ask-options": "Special:Hakuvalinnat",
"smw-prefs-ask-options-tooltip-display": "Näytä parametri työkaluvihjeenä",
"smw-prefs-general-options-disable-editpage-info": "Poista johdantoteksti käytöstä muokkaussivulla",
"smw-ui-tooltip-title-property": "Ominaisuus",
@@ -272,8 +286,8 @@
"smw-ui-tooltip-title-note": "Huomautus",
"smw-ui-tooltip-title-legend": "Selite",
"smw-ui-tooltip-title-reference": "Viite",
- "smw_unknowntype": "Tämän ominaisuuden tyyppi on virheellinen",
- "smw_concept_header": "Konseptin \"$1\" sivut",
+ "smw_unknowntype": "Tämän ominaisuuden tyyppi \"$1\" on virheellinen",
+ "smw_concept_header": "Käsitteen ”$1” sivut",
"smw_conceptarticlecount": "Näytetään alla $1 {{PLURAL:$1|sivu|sivua}}",
"group-smwadministrator": "Ylläpitäjät (Semantic MediaWiki)",
"group-smwadministrator-member": "{{GENDER:$1|ylläpitäjä (Semantic MediaWiki)}}",
@@ -286,26 +300,34 @@
"smw-admin-idlookup-input": "Hae:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Yleiskatsaus",
+ "smw-admin-maintenance-no-description": "Ei kuvausta.",
"smw-livepreview-loading": "Ladataan…",
"smw-sp-searchbyproperty-resultlist-header": "Luettelo tuloksista",
- "smw-search-profile-extended-section-namespace": "Valitse nimiavaruus",
+ "smw-search-syntax": "Syntaksi",
+ "smw-search-profile-extended-section-namespace": "Nimiavaruus",
+ "smw-search-profile-extended-section-query": "Kysely",
+ "smw-search-show": "Näytä",
+ "smw-search-hide": "Piilota",
"log-name-smw": "Semantic MediaWiki -loki",
"log-show-hide-smw": "$1 Semantic MediaWiki -loki",
"logeventslist-smw-log": "Semantic MediaWiki -loki",
+ "smw-datavalue-invalid-number": "Arvoa ”$1” ei voi tulkita luvuksi.",
"smw-query-condition-empty": "Kyselyn kuvaus sisältää tyhjän ehdon.",
"smw-types-list": "Luettelo tietotyypeistä",
- "smw-types-default": "\"$1\" on sisäänrakennettu tietotyyppi.",
+ "smw-types-default": "”$1” on sisäänrakennettu tietotyyppi.",
"smw-type-boo": "”$1” perustietotyyppi, joka kuvaa totuusarvoa.",
"smw-type-txt": "”$1” on perustietotyyppi, joka kuvaa mielivaltaisen pitkiä merkkijonoja.",
"smw-type-dat": "”$1” on perustietotyyppi, joka kuvaa ajanhetkiä yhtenäisessä muodossa.",
"smw-type-extra-tem": "Muunnosskeema sisältää tuetut yksiköt kuten Kelvin, Celcious, Fahrenheit ja Rankine.",
"smw-type-tab-properties": "Ominaisuudet",
"smw-type-tab-types": "Tyypit",
+ "smw-type-tab-errors": "Virheet",
"smw-type-primitive": "Perustyypit",
"smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|sekunti|sekuntia}}",
"smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|sekunti|sekuntia}}",
"smw-limitreport-pagepurge-storeupdatetime-value": "$1 {{PLURAL:$1|sekunti|sekuntia}}",
- "smw-datavalue-external-formatter-invalid-uri": "\"$1\" on virheellinen URL-osoite.",
+ "smw-datavalue-allows-pattern-mismatch": "Arvo ”$1” luokiteltiin virheelliseksi säännöllisen lausekkeen ”$2” perusteella.",
+ "smw-datavalue-external-formatter-invalid-uri": "”$1” on virheellinen URL-osoite.",
"smw-clipboard-copy-link": "Kopioi linkki leikepöydälle",
"smw-no-data-available": "Tietoja ei ole saatavissa.",
"smw-edit-protection-enabled": "Muokkaaminen suojattu (Semantic MediaWiki)",
@@ -317,13 +339,24 @@
"smw-format-datatable-next": "Seuraava",
"smw-format-datatable-previous": "Edellinen",
"smw-format-datatable-toolbar-export": "Vie",
+ "smw-property-page-list-count": "Näytetään $1 tätä ominaisuutta {{PLURAL:$1|käyttävä sivu|käyttävää sivua}}.",
"smw-property-reserved-category": "Luokka",
"smw-category": "Luokka",
+ "smw-browse-property-group-title": "Ominaisuusryhmä",
+ "smw-filter": "Suodata",
"smw-section-expand": "Laajenna osio",
"smw-section-collapse": "Tiivistä osio",
"smw-help": "Ohje",
"smw-property-predefined-label-skey": "Pikanäppäin",
"smw-processing": "Käsitellään...",
"smw-types-title": "Tyyppi: $1",
- "smw-ask-title-keyword-type": "Avainsanahaku"
+ "smw-schema-error": "Vahvistusvirhe",
+ "smw-schema-type": "Tyyppi",
+ "smw-ask-title-keyword-type": "Avainsanahaku",
+ "smw-property-tab-usage": "Käyttö",
+ "smw-property-tab-redirects": "Synonyymit",
+ "smw-concept-tab-errors": "Virheet",
+ "smw-ask-tab-result": "Tulos",
+ "smw-ask-tab-extra": "Ekstra",
+ "smw-ask-tab-code": "Koodi"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/fr.json b/www/wiki/extensions/SemanticMediaWiki/i18n/fr.json
index 7c4c6e96..e04e4773 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/fr.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/fr.json
@@ -49,6 +49,11 @@
},
"smw-desc": "Rendre votre wiki plus accessible - pour les machines ''et'' les humains ([https://www.semantic-mediawiki.org/wiki/Help:User_manual documentation en ligne])",
"smw-title": "MédiaWiki Sémantique",
+ "smw-upgrade-error": "MédiaWikin Sémantique a été installé et activé, mais il manque une [https://www.semantic-mediawiki.org/wiki/Help:Upgrade clé de mise à jour] appropriée qui corresponde : <code>$1</code>.",
+ "smw-upgrade-error-why-title": "Pourquoi vois-je cette erreur ?",
+ "smw-upgrade-error-why-explain": "La structure de la base de données interne de MédiaWiki Sémantique a été modifiée et nécessite des ajustements pour être pleinement fonctionnelle. Il peut y voir plusieurs raisons à cela, dont :\n* des propriétés corrigées supplémentaires (nécessitant une installation de table supplémentaire) ont été ajoutées \n* Une mise à jour contient certaines modifications de tables ou d’index rendant une interception obligatoire avant d’accéder aux données",
+ "smw-upgrade-error-how-title": "Comment dois-je corriger cette erreur ?",
+ "smw-upgrade-error-how-explain": "Un administrateur (ou toute personne avec des droits administrateur) doit lancer le script de maintenance, soit [https://www.mediawiki.org/wiki/Manual:Update.php update.php] de MédiaWiki, ou [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] de MédiaWiki Sémantique. Vous pouvez aussi consulter les pages suivantes pour plus d’aide :\n* Instructions d’[https://www.semantic-mediawiki.org/wiki/Help:Installation installation]\n* Page d’aide des [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting problèmes]",
"smw-semantics-not-enabled": "La fonctionnalité MédiaWiki Sémantique n’est pas activée sur ce wiki.",
"smw_viewasrdf": "Voir au format RDF",
"smw_finallistconjunct": " et",
@@ -143,6 +148,7 @@
"smw-paramdesc-feeddescription": "Le texte à utiliser comme description du flux",
"smw-paramdesc-feedpagecontent": "Contenu de la page à afficher avec le flux",
"smw-label-feed-description": "Flux $1 $2",
+ "smw-paramdesc-mimetype": "Le type de média (type MIME) du fichier de sortie",
"smw_iq_disabled": "Les recherches sémantiques sur ce wiki sont désactivées.",
"smw_iq_moreresults": "&hellip; autres résultats",
"smw_parseerror": "La donnée indiquée n’a pas été comprise.",
@@ -354,9 +360,9 @@
"smw_smwadmin_updatenotstopped": "Pour arrêter le processus de mise-à-jour en cours, vous devez activer la case à cocher pour indiquer que vous êtes vraiment sûr.",
"smw-admin-docu": "Cette page spéciale vous aide pendant l’installation, la mise à jour, la maintenance et l'utilisation de <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWiki</a> et comporte d'autres fonctions et tâches administratives ainsi que des statistiques.\nN’oubliez pas de sauvegarder vos données importantes avant d’exécuter des fonctions d’administration.",
"smw-admin-environment": "Environnement logiciel",
- "smw-admin-db": "Maintenance de la base de données",
+ "smw-admin-db": "Installation de la base de données",
"smw-admin-db-preparation": "L'initialisation de la table est en cours et peut prendre un moment avant que les résultats ne soient affichés (dépend de la taille et des possibles optimisations).",
- "smw-admin-dbdocu": "Semantic MediaWiki nécessite certaines extensions à la base de données de MediaWiki afin de stocker les données sémantiques.\nLa fonction ci-dessous s’assure que votre base de données a été correctement installée.\nLes modifications faites lors de cette étape n’affecteront pas le reste de la base de données de Mediawiki, et peuvent être facilement annulées si nécessaire.\nCette fonction d’installation peut être lancée plusieurs fois sans causer de dégâts, mais cela n’est nécessaire qu’une seule fois par installation ou mise à niveau.",
+ "smw-admin-dbdocu": "MédiaWiki Sémantique a besoin de sa propre structure de base de données (indépendante de MédiaWiki de manière à ne pas affecter le reste de l’installation de MédiaWiki) afin de stocker les données sémantiques.\nCette fonction d’installation peut être lancée plusieurs fois sans causer de dégâts, mais cela n’est nécessaire qu’une seule fois par installation ou mise à niveau.",
"smw-admin-permissionswarn": "Si l’opération échoue dûe à des erreurs SQL, l’utilisateur de la base de données utilisée par votre wiki (regardez votre fichier « LocalSettings.php ») n’a probablement pas les droits suffisants.\nIl faut soit permettre à cet utilisateur de créer ou de supprimer les tables, soit de saisir temporairement les identifiants du compte root de votre base de données dans le fichier « LocalSettings.php », soit d'utiliser le script de maintenance <code>setupStore.php</code>, qui peut utiliser les informations de connexion d’un administrateur.",
"smw-admin-dbbutton": "Initialiser ou mettre à niveau les tables",
"smw-admin-announce": "Annoncer votre wiki",
@@ -383,7 +389,7 @@
"smw_smwadmin_datarefreshbutton": "Planifier la reconstruction des données",
"smw_smwadmin_datarefreshstop": "Arrêter cette mise à jour",
"smw_smwadmin_datarefreshstopconfirm": "Oui, j’en suis {{GENDER:$1|sûr|sûre}}.",
- "smw-admin-job-scheduler-note": "La plupart des activités dans cette section sont effectuées comme des tâches pour éviter des situations de verrou mortel pendant leur exécution. L’[https://www.mediawiki.org/wiki/Manual:Job_queue ordonnanceur de tâches] est responsable de l’exécution et il est critique que le script de maintenance <code>runJobs.php</code> (voir aussi le paramètre de configuration <code>$wgRunJobsAsync</code>) ait une capacité adaptée.",
+ "smw-admin-job-scheduler-note": "Les tâches (celles activées) dans cette section sont effectuées via la file de travaux pour éviter des situations de verrou mortel pendant leur exécution. La [https://www.mediawiki.org/wiki/Manual:Job_queue file des travaux] est responsable de l’exécution et il est critique que le script de maintenance <code>runJobs.php</code> ait une capacité appropriée (voir aussi le paramètre de configuration <code>$wgRunJobsAsync</code>).",
"smw-admin-outdateddisposal-title": "Élimination des entités désuètes",
"smw-admin-outdateddisposal-intro": "Certaines activités (une modification d’un type de propriété, la suppression de pages wiki, ou la correction de valeurs erronées) créeront [https://www.semantic-mediawiki.org/wiki/Outdated_entities des entités désuètes] et il est conseillé de les supprimer périodiquement pour libérer l’espace occupé par leur tables.",
"smw-admin-outdateddisposal-active": "Une tâche d’élimination des entités désuètes a été planifiée.",
@@ -405,7 +411,7 @@
"smw-admin-questions": "Si vous avez d’autres questions ou des suggestions, joignez-vous à la discussion sur <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">la liste de discussion des utilisateurs</a> de MediaWiki Sémantique ou la <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">zone de discussion</a>.",
"smw-admin-other-functions": "Autres fonctions",
"smw-admin-supplementary-section-title": "Fonctions supplémentaires",
- "smw-admin-supplementary-section-subtitle": "Fonctions disponibles",
+ "smw-admin-supplementary-section-subtitle": "Fonctions système",
"smw-admin-supplementary-section-intro": "Cette section fournit des fonctions supplémentaires au-delà du domaine de maintenance, et il est possible que certaines fonctions qui sont listées dans la [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions documentation] soient restreintes ou indisponibles, et donc inaccessibles sur ce wiki.",
"smw-admin-supplementary-settings-title": "Options de configuration",
"smw-admin-supplementary-settings-intro": "<u>$1</u> renvoie une liste collective de paramètres disponibles utilisés dans Semantic MediaWiki",
@@ -420,9 +426,10 @@
"smw-admin-supplementary-operational-statistics-cache-title": "Statistiques du cache",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> affiche les statistiques relatives au cache",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
- "smw-admin-supplementary-elastic-intro": "<u>$1</u> informe sur les paramètres et les statistiques d’index",
+ "smw-admin-supplementary-elastic-section-subtitle": "Fonctions de Elasticsearch",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> afiche les paramètres et les statistiques d’index",
"smw-admin-supplementary-elastic-docu": "Cette page contient des informations sur les paramètres, les correspondances, la santé et les statistiques d’index liées à une grappe Elasticsearch qui est connectée à MédiaWiki Sémantique et son [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
- "smw-admin-supplementary-elastic-functions": "Fonctions disponibles",
+ "smw-admin-supplementary-elastic-functions": "Fonctions supportées",
"smw-admin-supplementary-elastic-settings-title": "Paramètres",
"smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> utilisé par Elasticsearch pour gérer les index de MédiaWiki Sémantique",
"smw-admin-supplementary-elastic-mappings-title": "Correspondances",
@@ -537,9 +544,22 @@
"smw-admin-objectid": "ID :",
"smw-admin-tab-general": "Résumé",
"smw-admin-tab-notices": "Informations d'obsolescence",
- "smw-admin-tab-rebuild": "Maintenance",
+ "smw-admin-tab-maintenance": "Maintenance",
"smw-admin-tab-supplement": "Fonctions supplémentaires",
"smw-admin-tab-registry": "Registre",
+ "smw-admin-maintenance-no-description": "Aucune description.",
+ "smw-admin-maintenance-script-section-title": "Liste des scripts de maintenance disponibles",
+ "smw-admin-maintenance-script-section-intro": "Les scripts de maintenance suivants nécessitent un administrateur et l’accès à la ligne de commande pour pouvoir exécuter les scripts listés.",
+ "smw-admin-maintenance-script-description-dumprdf": "Export en RDF des triplets existants.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "Ce script est utilisé pour gérer les caches de concept pour MédiaWiki Sémantique, où il peut créer, supprimer et mettre à jour les caches sélectionnés.",
+ "smw-admin-maintenance-script-description-rebuilddata": "Recrée toutes les données sémantiques dans la base de données, en bouclant à travers toutes les pages qui ont des données sémantiques.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "Reconstruit l’index de Elasticsearch(pour les installations qui utilisent <code>ElasticStore</code>), en bouclant à travers toutes les entités qui ont des données sémantiques.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "Reconstruit l’index de recherche en texte brut <code>SQLStore</code> (pour les installations où le paramètre a été activé).",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "Reconstruit les statistiques d’utilisation pour toutes les entités de propriété.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "Supprime les entités en doublon trouvées dans les tables sélectionnées qui n’ont pas de références actives.",
+ "smw-admin-maintenance-script-description-setupstore": "Définit le serveur de stockage sélectionné dans <code>LocalSettings.php</code>.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "Met à jour le champ <code>smw_sort</code> dans <code>SQLStore</code> (en accord avec le paramètre [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation $smwgEntityCollation]).",
+ "smw-admin-maintenance-script-description-populatehashfield": "Remplit le champ <code>smw_hash</code> pour les lignes sans valeur.",
"smw-livepreview-loading": "Chargement en cours…",
"smw-sp-searchbyproperty-description": "Cette page fournit une simple [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces interface de navigation] pour trouver des entités décrites par une propriété et une valeur nommée. D’autres interfaces de recherche disponibles comprennent la [[Special:PageProperty|page recherche de propriété]], et le [[Special:Ask|constructeur de requêtes ask]].",
"smw-sp-searchbyproperty-resultlist-header": "Liste de résultats",
@@ -644,7 +664,7 @@
"smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
"smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
- "smw-special-pageproperty-description": "Cette page fournit une interface de navigation pour trouver toutes les valeurs d’une propriété et d’une page donnée. D’autres interfaces de recherche disponible incluent la [[Special:SearchByProperty|recherche de propriété]], et le [[Special:Ask|constructeur de requête ask]].",
+ "smw-special-pageproperty-description": "Cette page fournit une interface de navigation pour trouver toutes les valeurs d’une propriété et une page donnée. D’autres interfaces de recherche disponibles incluent la [[Special:SearchByProperty|recherche de propriété]], et le [[Special:Ask|constructeur de requête ask]].",
"smw-property-predefined-errc": "« $1 » est une propriété prédéfinie fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique] et représentant les erreurs qui sont apparues lors de la connexion du fait de mauvaises annotations de valeurs ou de traitements de l’entrée.",
"smw-property-predefined-long-errc": "Les erreurs sont enregistrées dans un [https://www.semantic-mediawiki.org/wiki/Help:Container conteneur] qui peut inclure une référence vers la propriété qui a causé le problème.",
"smw-property-predefined-errt": "« $1 » est une propriété prédéfinie contenant une description textuelle d’une erreur et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
@@ -663,13 +683,14 @@
"smw-property-predefined-askco": "« $1 » est une propriété prédéfinie fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique] pour décrire l'état d'une requête ou de ses composants.",
"smw-property-predefined-long-askco": "Le nombre ou les chiffres attribués représentent un état interne codifié expliqué sur la [https://www.semantic-mediawiki.org/wiki/Help:Query_profiler page d’aide].",
"smw-property-predefined-prec": "« $1 » est une propriété prédéfinie qui décrit une [https://www.semantic-mediawiki.org/wiki/Help:Display_precision précision d’affichage] (chiffres décimaux) pour les types de données numériques.",
- "smw-types-extra-geo-not-available": "[https://www.semantic-mediawiki.org/wiki/Extension:Maps L’extension « Maps »] n’a pas été détecté, donc « $1 » est restreint dans ses capacités de traitement.",
+ "smw-property-predefined-attch-link": "« $1 » est une propriété prédéfinie qui recueille les liens des images et des fichiers inclus dans une page et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
+ "smw-types-extra-geo-not-available": "[https://www.semantic-mediawiki.org/wiki/Extension:Maps L’extension « Maps »] n’a pas été détectée, donc « $1 » est restreint dans ses capacités de traitement.",
"smw-datavalue-monolingual-dataitem-missing": "Un élément attendu pour construire une valeur composée monolingue manque.",
"smw-datavalue-languagecode-missing": "Pour l’annotation « $1 », l’analyseur n’a pas pu déterminer un code de langue (par ex. « foo@en »).",
"smw-datavalue-languagecode-invalid": "« $1 » n’a pas été reconnu comme un code de langue pris en charge.",
"smw-property-predefined-lcode": "« $1 » est une propriété prédéfinie qui représente un code de langue au format BCP47 et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
"smw-type-mlt-rec": "« $1 » est un type de données [https://www.semantic-mediawiki.org/wiki/Help:Container conteneur] qui associe une valeur texte avec un [[Property:Language code|code de langue]] spécifique.",
- "smw-types-extra-mlt-lcode": "Le type de données ne {{PLURAL:$2|nécessite|nécessite pas}} un code de langue (par ex. {{PLURAL:$2|une annotation de valeur sans code de langue n’est pas acceptée|une annotation de valeur sans code de langue est acceptée}}).",
+ "smw-types-extra-mlt-lcode": "Le type de données ne {{PLURAL:$2|nécessite un|nécessite pas de}} code de langue (par ex. {{PLURAL:$2|une annotation de valeur sans code de langue n’est pas acceptée|une annotation de valeur sans code de langue est acceptée}}).",
"smw-property-predefined-text": "« $1 » est une propriété prédéfinie qui représente un texte de longueur quelconque et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
"smw-property-predefined-pdesc": "« $1 » est une propriété prédéfinie qui permet de décrire une propriété dans le contexte d’une langue et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
"smw-property-predefined-list": "« $1 » est une propriété prédéfinie pour définir une liste de propriétés utilisée avec une propriété typée [[Special:Types/Record|enregistrement]], et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
@@ -800,6 +821,7 @@
"smw-property-reserved-category": "Catégorie",
"smw-category": "Catégorie",
"smw-datavalue-uri-invalid-scheme": "« $1 » n'a pas été répertorié comme schéma d'URI valide.",
+ "smw-datavalue-uri-invalid-authority-path-component": "« $1 » a été identifié comme contenant une autorité « $2 » ou un chemin de composant non valides.",
"smw-browse-property-group-title": "Groupe de propriétés",
"smw-browse-property-group-label": "Etiquette du groupe de propriétés",
"smw-browse-property-group-description": "Description du groupe de propriétés",
@@ -826,7 +848,7 @@
"smw-schema-type-help-link": "https://www.semantic-mediawiki.org/wiki/Help:Schema/Type/$1",
"smw-schema-type": "Type",
"smw-schema-description-link-format-schema": "Ce type de schéma est censé définir des caractétistiques pour créer des liens dépendants du contexte, en rapport avec une propriété affectée du [[Property:Formatter schema|schéma de mise en forme]].",
- "smw-schema-description-search-form-schema": "Ce type de schéma est censé être utilisé pour définir des formulaires de saisie et des caractéristiques pour le profil de [https://www.semantic-mediawiki.org/wiki/Help:SMWSearch recherche étendue], où il contient des instruction sur la manière de générer les champs de saisie, définit les espaces de nom par défaut, ou déclare les expressions de préfixe pour une requête de recherche.",
+ "smw-schema-description-search-form-schema": "Ce type de schéma est sensé être utilisé pour définir des formulaires de saisie et des caractéristiques pour le profil de [https://www.semantic-mediawiki.org/wiki/Help:SMWSearch recherche étendue], où il contient des instructions sur la manière de générer les champs de saisie, définir les espaces de noms par défaut, ou déclarer les expressions de préfixe pour une requête de recherche.",
"smw-schema-tag": "{{PLURAL:$1|balise|balises}}",
"smw-property-predefined-schema-desc": "« $1 » est une propriété prédéfinie qui stocke une description de schéma et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
"smw-property-predefined-schema-def": "« $1 » est une propriété prédéfinie qui stocke le contenu du schéma et est fournie par [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MédiaWiki Sémantique].",
@@ -852,5 +874,8 @@
"smw-ask-tab-result": "Résultat",
"smw-ask-tab-extra": "Suppléments",
"smw-ask-tab-debug": "Déboguage",
- "smw-ask-tab-code": "Code"
+ "smw-ask-tab-code": "Code",
+ "smw-install-incomplete-intro": "L’installation (ou la mise à jour) de <b>MédiaWiki Sémantique</b> n’a pas été achevée et un administrateur doit lancer les tâches suivantes pour éviter les incohérences de données avant que les utilisateurs ne continuent à créer ou modifier du contenu.",
+ "smw-install-incomplete-populate-hash-field": "Le remplissage du champ <code>smw_hash</code> a été sauté lors de l’installation, le script [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php] doit être exécuté.",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/gl.json b/www/wiki/extensions/SemanticMediaWiki/i18n/gl.json
index eb845679..a6c84e97 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/gl.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/gl.json
@@ -118,6 +118,8 @@
"smw_manytypes": "Máis dun tipo definido para a propiedade.",
"smw_emptystring": "As cordas baleiras non están aceptadas.",
"smw_notinenum": "\"$1\" non está na lista de [[Property:Allows value|valores permitidos]] ($2) para a propiedade \"$3\".",
+ "smw-datavalue-constraint-error-allows-value-list": "\"$1\" non está na lista de [[Property:Allows value|valores permitidos]] ($2) para a propiedade \"$3\".",
+ "smw-datavalue-constraint-error-allows-value-range": "\"$1\" non está no intervalo de \"$2\" especificado pola restrición [[Property:Allows value|permite valor]] para a propiedade \"$3\".",
"smw_noboolean": "\"$1\" non é recoñecido como un valor booleano (verdadeiro/falso).",
"smw_true_words": "verdadeiro,v,si,s",
"smw_false_words": "falso,f,non,n",
@@ -195,7 +197,7 @@
"smw-purge-failed": "Fallou o refresco",
"types": "Tipos",
"smw_types_docu": "Lista dos [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes tipos de datos dispoñibles] con cada [https://www.semantic-mediawiki.org/wiki/Help:Datatype tipo] representando un conxunto único de atributos para describir un valor en termos características de almacenamento e visualización que son heredadas nunha propiedade asignada.",
- "smw-special-types-no-such-type": "O tipo de datos especificado non existe",
+ "smw-special-types-no-such-type": "\"$1\" é descoñecido ou non foi especificado como tipo de datos válido.",
"smw-statistics": "Estatísticas semánticas",
"smw-statistics-property-instance": "{{PLURAL:$1|Valor|Valores}} de propiedade (total)",
"smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|Propiedade|Propiedades}}]] (total)",
@@ -225,7 +227,7 @@
"smw_ask_editquery": "Editar a pregunta",
"smw_add_sortcondition": "[Engadir unha condición de ordenación]",
"smw-ask-sort-add-action": "Engadir condición de ordenación",
- "smw_ask_hidequery": "Agochar a pescuda",
+ "smw_ask_hidequery": "Agochar a pescuda (vista compacta)",
"smw_ask_help": "Axuda sobre as pescudas",
"smw_ask_queryhead": "Condición",
"smw_ask_printhead": "Selección dos datos a imprimir",
@@ -247,7 +249,7 @@
"smw-ask-search": "Procurar",
"smw-ask-debug": "Depurar",
"smw-ask-debug-desc": "Xera información para a revisión de erros das consultas",
- "smw-ask-no-cache": "Sen caché",
+ "smw-ask-no-cache": "Desactivar a caché de consultas",
"smw-ask-no-cache-desc": "Resultados sen caché de consulta",
"smw-ask-result": "Resultado",
"smw-ask-empty": "Borrar todas as entradas",
@@ -257,9 +259,9 @@
"smw-ask-condition-change-info": "A condición foi modificada e o motor de procuras precisa que a consulta volva ser executada para producir resultados que correspondan ós novos requisitos.",
"smw-ask-input-assistance": "Asistencia de entrada",
"smw-ask-condition-input-assistance": "Proporciónase [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance asistencia de entrada] para os campos de saída, de ordenación e de condición. O campo de condición precisa o uso dalgún dos seguintes prefixos:",
- "smw-ask-condition-input-assistance-property": "<code>p:</code> para habilitar a suxestión de propiedades (exemplo: <code>[[p:Has ...</code>)",
- "smw-ask-condition-input-assistance-category": "<code>c:</code> para habilitar as suxestións de categorías",
- "smw-ask-condition-input-assistance-concept": "<code>con:</code> para activar as suxestións de conceptos",
+ "smw-ask-condition-input-assistance-property": "<code>p:</code> para obter as suxestións de propiedades (exemplo: <code>[[p:Has ...</code>)",
+ "smw-ask-condition-input-assistance-category": "<code>c:</code> para obter as suxestións de categorías",
+ "smw-ask-condition-input-assistance-concept": "<code>con:</code> para obter as suxestións de conceptos",
"smw-ask-format-change-info": "O formato foi modificado e é preciso para reexecutar a consulta para corresponderse ós novos parámetros e opcións de visualización.",
"smw-ask-format-export-info": "O formato seleccionado é un formato de exportación que non ten representación visual, polo tanto os resultados só se proporcionan como descarga.",
"smw-ask-query-search-info": "A consulta <code><nowiki>$1</nowiki></code> foi respondida polo {{PLURAL:$3|1=<code>$2</code> (desde a caché)|<code>$2</code> (desde a caché)|<code>$2</code>}} en $4 {{PLURAL:$4|segundo|segundos}}.",
@@ -293,7 +295,7 @@
"smw_inverse_label_default": "$1 de",
"smw_inverse_label_property": "Etiqueta da propiedade inversa",
"pageproperty": "Procura de propiedades de páxinas",
- "smw_pp_docu": "Procurar por todos os valores dunha propiedade nunha páxina dada.\nInsira tanto a páxina como a propiedade.",
+ "smw_pp_docu": "Introduza unha páxina e propiedade, ou só unha propiedade, para obter tódolos valores asignados.",
"smw_pp_from": "Da páxinaː",
"smw_pp_type": "Propiedadeː",
"smw_pp_submit": "Atopar os resultados",
@@ -316,7 +318,7 @@
"smw_smwadmin_updatenotstopped": "Para deter os procesos de actualización actuais, debe activar a caixa de verificación para indicar que está seguro de facelo.",
"smw-admin-docu": "Esta páxina especial serve de axuda durante a instalación, actualización, mantemento e uso do <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWiki</a> e ademais de proporcionar funcións administrativas e tarefas, así como estatísticas.\nLembre facer unha copia de seguridade dos datos antes de executar calquera función administrativa.",
"smw-admin-environment": "Contorno de programación",
- "smw-admin-db": "Instalación e actualización da base de datos",
+ "smw-admin-db": "Mantemento da base de datos",
"smw-admin-db-preparation": "A inicialización da táboa está en curso e pode tardar algún tempo ata que se amosen os resultados, dependendo do tamaño da táboa e de posibles optimizacións da mesma.",
"smw-admin-dbdocu": "Semantic MediaWiki require algunhas extensións da base de datos MediaWiki para almacenar os datos semánticos.\nA función de embaixo asegúrase de que a súa base de datos está configurada apropiadamente.\nOs cambios feitos neste paso non afectarán ao resto da base de datos MediaWiki, e poden ser desfeitos de xeito sinxelo se se desexa.\nEsta función de configuración pode ser executada múltiples veces sen facer ningún dano, pero só é necesaria unha vez na instalación ou actualización.",
"smw-admin-permissionswarn": "Se a operación falla con erros SQL, probablemente o usuario da base de datos empregada polo seu wiki (comprobe o seu ficheiro \"LocalSettings.php\") non teña os permisos suficientes.\nFai falla conceder a este usuario os permisos para crear e eliminar táboas; temporalmente insira o rexistro da súa base de datos no ficheiro \"LocalSettings.php\", ou use o script de mantemento <code>setupStore.php</code>, que pode usar as credenciais dun administrador.",
@@ -385,6 +387,7 @@
"smw-admin-supplementary-elastic-intro": "<u>$1</u> informa sobre configuración e estatísticas de indexación",
"smw-admin-supplementary-elastic-functions": "Funcións dispoñibles",
"smw-admin-supplementary-elastic-settings-title": "Configuración",
+ "smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> usado por Elasticsearch para administrar índices de MediaWiki Semántica",
"smw-admin-supplementary-elastic-mappings-title": "Correspondencias",
"smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u> para listar os índices e as correspondencias de campo",
"smw-admin-supplementary-elastic-mappings-summary": "Resumo",
@@ -398,6 +401,7 @@
"smw-admin-supplementary-elastic-status-replication": "Estado de replicación",
"smw-admin-supplementary-elastic-status-last-active-replication": "Última replicación activa: $1",
"smw-admin-supplementary-elastic-status-refresh-interval": "Intervalo de actualización: $1",
+ "smw-admin-supplementary-elastic-status-rebuild-lock": "Replicación bloqueada: $1 (reconstrución en proceso)",
"smw-list-count": "A lista contén $1 {{PLURAL:$1|entrada|entradas}}.",
"smw-list-count-from-cache": "A lista contén $1 {{PLURAL:$1|entrada|entradas}} e recuperouse da caché (UTC: $2).",
"smw-property-label-uniqueness": "Atopouse unha correspondencia entre a etiqueta \"$1\" e polo menos outra representación de propiedade. Consulte a [https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness páxina de axuda] sobre a resolución deste problema, por favor.",
@@ -427,8 +431,10 @@
"prefs-ask-options": "Especial:Opcións de preguntas",
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/?uselang=gl Semantic MediaWiki] (e as extensións relacionadas) permiten adaptar individualmente algunhas funcións seleccionadas. Por favor, consulte a [https://www.semantic-mediawiki.org/wiki/Help:User_preferences?uselang=gl páxina de axuda] para unha descrición detallada.",
"smw-prefs-ask-options-tooltip-display": "Amosar o texto do parámetro como unha axuda informativa",
+ "smw-prefs-ask-options-compact-view-basic": "Habilita a vista compacta básica",
+ "smw-prefs-help-ask-options-compact-view-basic": "Se se activa, amosa un conxunto reducido de ligazóns na vista compacta Special:Ask.",
"smw-prefs-general-options-time-correction": "Activar a corrección da hora para as páxinas especiais usando a preferencia do [[Special:Preferences#mw-prefsection-rendering|fuso horario]] local.",
- "smw-prefs-general-options-jobqueue-watchlist": "Amosar a [https://www.semantic-mediawiki.org/wiki/Help:Job_queue_watchlist lista de vixilancia da cola de tarefas] na miña barra persoal",
+ "smw-prefs-general-options-jobqueue-watchlist": "Amosar a lista de vixilancia da cola de tarefas na miña barra persoal",
"smw-prefs-general-options-disable-editpage-info": "Desactivar o texto introdutorio da páxina de edición",
"smw-prefs-general-options-suggester-textinput": "Activar a [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance asistencia de entrada] para as suxestións das entidades semánticas",
"smw-ui-tooltip-title-property": "Propiedade",
@@ -487,7 +493,6 @@
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Resumo",
"smw-admin-tab-notices": "Avisos de obsolescencia",
- "smw-admin-tab-rebuild": "Mantemento",
"smw-admin-tab-supplement": "Funcións suplementarias",
"smw-admin-tab-registry": "Rexistro",
"smw-livepreview-loading": "Cargando...",
@@ -507,6 +512,7 @@
"smw-search-input": "Entrada e procura",
"smw-search-syntax": "Sintaxe",
"smw-search-profile": "Extendida",
+ "smw-search-profile-tooltip": "Busca funcións en conexión con MediaWiki Semántica",
"smw-search-profile-sort-best": "Mellor correspondencia",
"smw-search-profile-sort-recent": "Máis recente",
"smw-search-profile-sort-title": "Título",
@@ -514,11 +520,14 @@
"smw-search-profile-extended-help-sort-title": "* \"Título\" usando o título da páxina (ou o título en pantalla) como criterio de ordenación",
"smw-search-profile-extended-help-sort-best": "* \"Mellor correspondencia\" ordenará os resultados por [https://www.semantic-mediawiki.org/wiki/help:ElasticStore/Relevancy relevancia] baseándose nas puntuacións provistas por Elasticsearch",
"smw-search-profile-extended-help-namespace": "A caixa de selección do espazo de nomes estará oculta en canto se seleccione un formulario, pero pode facerse visible de novo coa axuda do botón \"amosar/ocultar\".",
- "smw-search-profile-extended-help-query": "Ligazón aː $1",
- "smw-search-profile-extended-help-find-forms": "Atopar formularios",
+ "smw-search-profile-extended-help-search-syntax-simplified-not": "* <code>not:</code> para non coincidir con ningunha entidade que inclúa \"...\"",
+ "smw-search-profile-extended-help-query": "<code><nowiki>$1</nowiki></code> usado como consulta.",
+ "smw-search-profile-extended-help-query-link": "(Para máis detalles $1).",
+ "smw-search-profile-extended-help-find-forms": "formularios dispoñibles",
"smw-search-profile-extended-section-sort": "Ordenar por",
- "smw-search-profile-extended-section-form": "Seleccionar un formulario",
- "smw-search-profile-extended-section-namespace": "Seleccionar un espazo de nomes",
+ "smw-search-profile-extended-section-form": "Formularios",
+ "smw-search-profile-extended-section-search-syntax": "Entrada de procura",
+ "smw-search-profile-extended-section-namespace": "Espazo de nomes",
"smw-search-profile-extended-section-query": "Consulta",
"smw-search-profile-link-caption-query": "ver",
"smw-search-show": "Amosar",
@@ -550,16 +559,30 @@
"smw-datavalue-restricted-use": "O valor de datos \"$1\" foi marcado para uso restrinxido.",
"smw-datavalue-invalid-number": "Non se pode interpretar \"$1\" coma un número.",
"smw-query-condition-circular": "Detectouse unha posible condición circular en \"$1\".",
+ "smw-query-condition-empty": "A descrición da consulta ten unha condición baleira.",
"smw-types-list": "Lista de tipos de datos",
"smw-types-default": "\"$1\" é un tipo de datos predefinido.",
- "smw-types-help": "Máis información e exemplos poden atoparse na [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 páxina de axuda].",
+ "smw-types-help": "Máis información e exemplos poden atoparse nesta [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 páxina de axuda].",
"smw-type-anu": "\"$1\" é unha variante do tipo de datos [[Special:Types/URL|URL]] que se usa principalmente para declaración de exportación de ''owl:AnnotationProperty''.",
- "smw-type-boo": "\"$1\" é un tipo de dato antigo para describir un valor certo/falso.",
+ "smw-type-boo": "\"$1\" é un tipo de dato básico para describir un valor certo/falso.",
"smw-type-cod": "\"$1\" é unha variante do tipo de dato [[Special:Types/Text|Texto]] que é usada para textos técnicos de lonxitude variable, como listados de código fonte.",
"smw-type-geo": "\"$1\" é un tipo de dato que describe localizacións xeográficas e require a [https://www.semantic-mediawiki.org/wiki/Extension:Maps extensión \"Maps\"].",
"smw-type-tel": "\"$1\" é un tipo de datos especial para describir números de teléfono internacionais segundo o RFC 3966.",
"smw-type-txt": "\"$1\" é un antigo tipo de datos para describir cadeas de texto de lonxitude variable.",
"smw-type-dat": "\"$1\" é un tipo de dato para representar puntos no tempo nun formato unificado.",
+ "smw-type-ema": "\"$1\" é un tipo de datos especial para representar un correo electrónico.",
+ "smw-type-tem": "\"$1\" é un tipo de datos numérico especial para representar unha temperatura.",
+ "smw-type-qty": "\"$1\" é un tipo de datos para describir cantidades con unha representación numérica e unha unidade de medida.",
+ "smw-type-rec": "\"$1\" é un tipo de datos contedor que especifica unha lista de propiedades con tipos, nunha orde fixa.",
+ "smw-type-extra-tem": "O esquema de conversión inclúe as unidades soportadas, como Kelvin, Celsius, Fahrenheit e Rankine.",
+ "smw-type-tab-properties": "Propiedades",
+ "smw-type-tab-types": "Tipos",
+ "smw-type-tab-errors": "Erros",
+ "smw-type-primitive": "Básico",
+ "smw-type-contextual": "Contextual",
+ "smw-type-compound": "Composto",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
"smw-special-pageproperty-description": "Esta páxina proporciona unha interface de navegación para atopar tódolos valores dunha propiedade nunha páxina dada. Outras interfaces de procura dispoñibles inclúen a [[Special:SearchByProperty|procura de propiedades]] e o [[Special:Ask|construtor de preguntas]].",
"smw-property-predefined-errc": "\"$1\" é unha propiedade predefinida proporcionada por [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semántica] e representa erros que aparecen en conexión con anotacións de valores impropios ou do procesamento da entrada.",
@@ -602,7 +625,7 @@
"smw-datavalue-allows-value-list-unknown": "A referencia de lista \"$1\" non se corresponde cunha páxina de [[MediaWiki:Smw allows list $1]].",
"smw-datavalue-allows-value-list-missing-marker": "O contido da lista \"$1\" non contén elementos co marcador de lista *.",
"smw-datavalue-feature-not-supported": "A funcionalidade \"$1\" non é compatible ou foi desactivada neste wiki.",
- "smw-property-predefined-pvap": "\"$1\" é unha propiedade predefinida que pode especificar unha [[MediaWiki:Smw allows pattern|referenza de patrón]] para facer coincidir [https://es.wikipedia.org/wiki/Expresi%C3%B3n_regular expresións regulares]. É proporcionada pola [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semántica].",
+ "smw-property-predefined-pvap": "\"$1\" é unha propiedade predefinida que pode especificar unha [[MediaWiki:Smw allows pattern|referencia de patrón]] para facer coincidir [https://gl.wikipedia.org/wiki/Expresi%C3%B3n_regular expresións regulares]. É proporcionada pola [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semántica].",
"smw-property-predefined-dtitle": "\"$1\" é unha propiedade predefinida que pode asignar un título de visualización diferente a unha entidade. É proporcionada pola [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semántica].",
"smw-property-predefined-pvuc": "\"$1\" é unha propiedade predefinida, proporcionada por [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semántica], que restrinxe as asignacións de valores para cada instancia a valores únicos (ou un polo menos).",
"smw-property-predefined-long-pvuc": "A unicidade está establecida cando dous valores non son iguais na súa representación literal, e toda violación desta constante será considerada coma un erro.",
@@ -659,6 +682,8 @@
"smw-property-req-violation-missing-formatter-uri": "Á propiedade «$1» fáltanlle detalles de declaración para o tipo anotado porque non foi defina a propiedade <code>URI do formatador externo</code>.",
"smw-property-req-violation-predefined-type": "A propiedade \"$1\" é unha propiedade predefinida que contén unha declaración de tipo \"$2\" que é incompatible co tipo por defecto desta propiedade.",
"smw-property-req-violation-import-type": "Detectouse unha declaración de tipo que non é compatible co tipo predefinido do vocabulario importado \"$1\". En xeral, non é necesario declarar un tipo porque a información obtense da definición da importación.",
+ "smw-property-req-violation-change-propagation-locked-error": "A propiedade «$1» foi alterada e precisa que as entidades asignadas sexan reavaliadas usando un proceso de [https://www.semantic-mediawiki.org/wiki/Change_propagation propagación de cambios]. A páxina da propiedade foi protexida ata que a actualización de especificación primaria estea completada para previr interrupcións intermedias ou especificacións contraditorias. O proceso pode levar un momento antes de que a páxina poida ser desprotexida, isto dependerá do tamaño e a frecuencia do planificador da [https://www.mediawiki.org/wiki/Manual:Job_queue cola de traballo] do planificador.",
+ "smw-category-invalid-value-assignment": "\"$1\" non é recoñecido como unha categoría válida ou unha anotación válida.",
"protect-level-smw-pageedit": "Permitir unicamente usuarios co permiso de edición de páxinas (Semantic MediaWiki)",
"smw-create-protection": "A creación da propiedade «$1» está restrinxida ós usuarios que conten co dereito «$2» axeitado (ou pertenzan ó [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups grupo de usuarios]), mentres estea activado o [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode modo de autoridade].",
"smw-create-protection-exists": "As modificacións á propiedade «$1» están restrinxidas ós usuarios que conten co dereito «$2» axeitado (ou pertenzan ó [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups grupo de usuarios]), mentres estea activado o [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode modo de autoridade].",
@@ -715,11 +740,17 @@
"smw-ask-format-help-link": "Formato [https://www.semantic-mediawiki.org/wiki/Help:$1_format $1]",
"smw-help": "Axuda",
"smw-cheat-sheet": "Folla de referencia",
- "smw-personal-jobqueue-watchlist": "Lista de vixilancia da fila de tarefas",
+ "smw-personal-jobqueue-watchlist": "Lista de vixilancia (cola de tarefas)",
"smw-property-predefined-label-skey": "Chave de ordenación",
"smw-processing": "Procesando...",
"smw-redirect-target-unresolvable": "O destino é irresoluble polo motivo «$1»",
"smw-types-title": "Tipo: $1",
+ "smw-schema-error": "Erro de validación.",
+ "smw-schema-error-violation": "Violación (\"$1\", \"$2\")",
+ "smw-schema-title": "Esquema",
+ "smw-schema-type-help-link": "https://www.semantic-mediawiki.org/wiki/Help:Schema/Type/$1",
+ "smw-schema-type": "Tipo",
+ "smw-schema-tag": "{{PLURAL:$1|Etiqueta|Etiquetas}}",
"smw-ask-title-keyword-type": "Procura de palabras clave",
"smw-ask-message-keyword-type": "Esta procura coincide coa condición <code><nowiki>$1</nowiki></code>.",
"smw-remote-source-unavailable": "Non foi posible establecer conexión co destino remoto \"$1\".",
@@ -731,6 +762,11 @@
"smw-property-tab-redirects": "Sinónimos",
"smw-property-tab-subproperties": "Subpropiedades",
"smw-property-tab-errors": "Asignacións incorrectas",
+ "smw-property-tab-specification": "... mais",
"smw-concept-tab-list": "Lista",
- "smw-concept-tab-errors": "Erros"
+ "smw-concept-tab-errors": "Erros",
+ "smw-ask-tab-result": "Resultado",
+ "smw-ask-tab-extra": "Extras",
+ "smw-ask-tab-debug": "Depuración",
+ "smw-ask-tab-code": "Código"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/he.json b/www/wiki/extensions/SemanticMediaWiki/i18n/he.json
index dbc845e7..113f7117 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/he.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/he.json
@@ -14,7 +14,9 @@
"Or",
"Nemo bis",
"Drorsnir",
- "שניאור זלמן"
+ "שניאור זלמן",
+ "המקיסט",
+ "Strayblues"
]
},
"smw-desc": "הופכת את הוויקי שלכם לנגיש יותר – עבור מכונות וגם עבור בני אדם ([https://www.semantic-mediawiki.org/wiki/Help:User_manual תיעוד מקוון])",
@@ -82,7 +84,7 @@
"smw-paramdesc-table-class": "מחלקת CSS נוספת שתוחל על הטבלה",
"smw-paramdesc-table-transpose": "הצגת כותרות טבלה אנכית ותוצאות אופקית",
"smw-paramdesc-rdfsyntax": "באיזה תחביר RDF להשתמש",
- "smw-paramdesc-csv-sep": "תו הפרדה",
+ "smw-paramdesc-csv-sep": "מגדיר מפריד טורים",
"smw-paramdesc-dsv-separator": "באיזה תו הפרדה להשתמש",
"smw-paramdesc-dsv-filename": "שם קובץ DSV",
"smw-paramdesc-filename": "שם קובץ הפלט",
@@ -185,9 +187,10 @@
"smw-wantedproperties-docu": "דף זה מציג [https://www.semantic-mediawiki.org/wiki/Unused_properties מאפיינים מבוקשים] שמשמשים באתר הוויקי, אבל אין שום דף שמתאר אותם. לתצוגה מובדלת, ר' את הדפים המיוחדים של [[Special:Properties|כל המאפיינים]] או של [[Special:UnusedProperties|המאפיינים שאינם בשימוש]].",
"smw-wantedproperty-template": "$1 (בשימוש {{PLURAL:$2|פעם אחת|$2 פעמים}})",
"smw_purge": "רענון תבניות ושאילתות",
+ "smw-purge-failed": "רענון נכשל",
"types": "סוגים",
"smw_types_docu": "רשימה של [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes סוגי נתונים זמינים] שבה כל [https://www.semantic-mediawiki.org/wiki/Help:Datatype סוג] מייצג ערכה ייחודית של מאפיינים שמתארים ערך במונחים של מאבחני אחסון ותצוגה שיורשים ממאפיין מוחל.",
- "smw-special-types-no-such-type": "סוג הנתונים שצוין אינו קיים",
+ "smw-special-types-no-such-type": "$1 אינו ידוע או שלא הוגדר כנתון תקין",
"smw-statistics": "סטטיסטיקה סמנטית",
"smw-statistics-property-instance": "{{PLURAL:$1|ערך של מאפיין|ערכים של מאפיינים}} (סה\"כ)",
"smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|מאפיין|מאפיינים}}]] (סה\"כ)",
@@ -212,6 +215,7 @@
"smw_ask_submit": "חפש תוצאות",
"smw_ask_editquery": "עריכת השאילתה",
"smw_add_sortcondition": "[הוספת הגדרת מיון]",
+ "smw-ask-sort-add-action": "הוסף תנאי מיון",
"smw_ask_hidequery": "הסתרת השאילתה",
"smw_ask_help": "עזרה בכתיבת שאילתות",
"smw_ask_queryhead": "תנאי",
@@ -228,11 +232,16 @@
"smw-ask-delete": "מחיקה",
"smw-ask-sorting": "מיון",
"smw-ask-options": "אפשרויות",
+ "smw-ask-options-sort": "מיין אפשרויות",
+ "smw-ask-format-options": "סוג ואפשרויות",
"smw-ask-parameters": "פרמטרים",
"smw-ask-search": "חיפוש",
+ "smw-ask-debug": "נתח",
"smw-ask-no-cache": "אין מטמון",
"smw-ask-result": "תוצאה",
- "smw-ask-format-selection-help": "למידע נוסף, יש לבקר בדף העזרה $1.",
+ "smw-ask-format": "סוג",
+ "smw-ask-format-selection-help": "עזרה עם הסוגים הנבחרים:$1",
+ "smw-ask-input-assistance": "סיוע קלט",
"smw-ask-query-search-info": "השאילתה <code><nowiki>$1</nowiki></code> נענתה על־ידי {{PLURAL:$3|1=<code>$2</code> (ממטמון)|<code>$2</code> (ממטמון)|<code>$2</code>}} {{PLURAL:$4|בשנייה אחת|ב־$4 שניות}}.",
"searchbyproperty": "חיפוש לפי מאפיין",
"processingerrorlist": "רשימת שגיאות עיבוד",
@@ -284,10 +293,12 @@
"smw-admin-dbbutton": "אתחול או שדרוג של טבלאות",
"smw-admin-announce": "פרסום הוויקי שלך",
"smw-admin-announce-text": "אם הוויקי שלך ציבורי, אפשר לרשום אותו ב־<a href=\"https://wikiapiary.com\">WikiApiary</a>, אתר ויקי שעוקב אחרי אתרי ויקי.",
- "smw_smwadmin_datarefresh": "תיקון ושדרוג של נתונים",
+ "smw-admin-deprecation-notice-title-notice": "שינויים נכנסים",
+ "smw-admin-deprecation-notice-title-removal": "הגדרות מחוקות",
+ "smw_smwadmin_datarefresh": "בנייה מחדש של נתונים",
"smw_smwadmin_datarefreshdocu": "ניתן לשחזר את כל הנתונים של מדיה־ויקי הסמנטי לפי התוכן הנוכחי של אתר הוויקי.\nפעולה זו עשויה להיות שימושית לתיקון נתונים שגויים או לעדכון הנתונים אם המבנה הפנימי שונה לאור שדרוג התוכנה.\nהעדכון מופעל דף־דף והוא לא יושלם מיד.\nהמידע להלן מראה האם העדכון מתבצע כעת ומאפשר לכם להתחיל או להפסיק את העדכונים (אלא אם כן תכונה זו בוטלה על ידי מנהל האתר).",
"smw_smwadmin_datarefreshprogress": "<strong>כבר מתבצע תהליך עדכון.</strong>\nמצב בו העדכון מתקדם לאט הוא מצב נורמלי, מאחר שהנתונים מתעדכנים בחלקים קטנים בכל פעם שמשתמש ניגש לוויקי.\nכדי לסיים את העדכון מהר יותר, תוכלו להפעיל את סקריפט התחזוקה <code>runJobs.php</code> (השתמשו באפשרות <code>--maxjobs 1000</code> כדי להגביל את מספר העדכונים שמתבצעים בבת אחת).\nהתקדמות משוערת של העדכון הנוכחי:",
- "smw_smwadmin_datarefreshbutton": "התחלת עדכון הנתונים",
+ "smw_smwadmin_datarefreshbutton": "קבע בנייה מחדש של נתונים",
"smw_smwadmin_datarefreshstop": "עצירת עדכון זה",
"smw_smwadmin_datarefreshstopconfirm": "כן, אני {{GENDER:$1|בטוח|בטוחה}}.",
"smw-admin-support": "קבלת תמיכה",
@@ -296,9 +307,11 @@
"smw-admin-smwhomepage": "התיעוד המלא למשתמשי המדיה־ויקי הסמנטי נמצא בכתובת <b><a href=\"http://semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
"smw-admin-bugsreport": "ניתן לדווח על באגים ב־<a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">GitHub</a>.",
"smw-admin-questions": "אם יש לכם הצעות או שאלות נוספות, הצטרפו לדיון שנערך ב<a href=\"http://sourceforge.net/mailarchive/forum.php?forum_name=semediawiki-user\">פורום המשתמשים של Semantic MediaWiki</a>.",
+ "smw-admin-other-functions": "אופציות נוספות",
"smw-admin-supplementary-section-subtitle": "תכונות זמינות",
"smw-admin-supplementary-section-intro": "פסקה זו מספקת תכונות נוספות מעבר לתחום התחזוקה, וייתכן שחלק מהתכונות הרשומות ב[https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions תיעוד] מוגבלות או לא זמינות, ולכן אינן נגישות באתר הוויקי הזה.",
"smw-admin-supplementary-settings-title": "הגדרות תצורה",
+ "smw-admin-supplementary-duplookup-title": "ישויות כפולות",
"smw-admin-supplementary-elastic-title": "חיפוש גמיש (Elasticsearch)",
"smw-admin-supplementary-elastic-intro": "<u>$1</u> – מידע על סטטיסטיקות של הגדרות ושל מפתוח",
"smw-admin-supplementary-elastic-docu": "דף זה מכיל מידע על סטטיסטיקות של הגדרות, של מיפויים, של בריאות ושל מפתוח, הקשורות לאשכול החיפוש הגמיש (Elasticsearch) שמחובר להרחבה \"מדיה־ויקי סמנטית\" ול־[https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
@@ -307,6 +320,7 @@
"smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> – הגדרות שנמצאות בשימוש על־ידי החיפוש הגמיש (Elasticsearch) לניהול מדדים של ההרחבה \"מדיה־ויקי סמנטית\"",
"smw-admin-supplementary-elastic-mappings-title": "מיפויים",
"smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u> – רשימה של מיפויי המדדים והשדות",
+ "smw-admin-supplementary-elastic-mappings-summary": "סיכום",
"smw-admin-supplementary-elastic-nodes-title": "צמתים",
"smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u> – הצגת סטטיסטיקות של צמתים",
"smw-admin-supplementary-elastic-indices-title": "מדדים",
@@ -315,6 +329,7 @@
"smw-admin-supplementary-elastic-statistics-intro": "<u>$1</u> – הצגת סטטיסטיקות ברמת מפתוח",
"smw-admin-supplementary-elastic-statistics-docu": "דף זה מספק תובנות לגבי הנתונים הסטטיסטיים של פעולות שונות שמתרחשות ברמת מפתוח. הסטטיסטיקות המוחזרות הן קיבוץ של הבחירה המוקדמת ושל ההצטברות הכוללת. [https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-stats.html דף העזרה] מכיל תיאור מפורט של הנתונים הסטטיסטיים הזמינים.",
"smw-property-label-similarity-threshold": "סף:",
+ "smw-property-label-similarity-noresult": "לא נמצאו תוצאות",
"smw_adminlinks_datastructure": "מבנה הנתונים",
"smw_adminlinks_displayingdata": "הצגת נתונים",
"smw_adminlinks_inlinequerieshelp": "עזרה על שאילתות משובצות",
@@ -351,6 +366,7 @@
"smw-qp-empty-data": "לא ניתן להציג את הנתונים המבוקשים בגלל אמות מידה בלתי־מספיקות לבחירה.",
"right-smw-admin": "גישה למשימות ניהול (מדיה־ויקי סמנטית)",
"right-smw-patternedit": "עריכת גישה כדי לתחזק ביטויים רגולריים ותבניות (מדיה־ויקי סמנטית)",
+ "restriction-level-smw-pageedit": "מוגן (רק למשתמשים מורשים)",
"action-smw-patternedit": "לערוך ביטויים רגולריים שבשימוש של מדיה־ויקי סמנטית",
"group-smwadministrator": "מנהלים (מדיה־ויקי סמנטית)",
"group-smwadministrator-member": "{{GENDER:$1|מנהל|מנהלת}} (מדיה־ויקי סמנטית)",
@@ -379,7 +395,6 @@
"smw-admin-idlookup-input": "חיפוש:",
"smw-admin-objectid": "מזהה:",
"smw-admin-tab-general": "סקירה כללית",
- "smw-admin-tab-rebuild": "תחזוקה",
"smw-admin-tab-registry": "רישום",
"smw-livepreview-loading": "בטעינה…",
"smw-sp-searchbyproperty-description": "הדף הזה מספק [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces ממשק עיון] פשוט למציאת ישויות שמתוארות על־ידי מאפיין וערך בעל־שם. ממשקי חיפוש זמינים אחרים הם [[Special:PageProperty|חיפוש מאפיין דף]] ו[[Special:Ask|בונה שאילתות]].",
@@ -393,8 +408,21 @@
"smw-editpage-property-annotation-enabled": "אפשר להחיב את המאפיין הזה באמצעות הערות סמנטיות כדי להגדיר סוג נתונים (למשל <nowiki>\"[[Has type::Page]]\"</nowiki>) או הצהרות תומכות אחרות (למשל <nowiki>\"[[Subproperty of::dc:date]]\"</nowiki>). לתיאור של איך להרחיב את הדף הזה, ר' את דפי העזרה [https://www.semantic-mediawiki.org/wiki/Help:Property_declaration declaration of a property] או [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes list of available data types].",
"smw-editpage-property-annotation-disabled": "לא ניתן להרחיב את המאפיין הזה עם הערת סוג נתונים (למשל <nowiki>\"[[Has type::Page]]\"</nowiki>) משום שהוא כבר מוגדר מראש (ר' את הדף העזרה [https://www.semantic-mediawiki.org/wiki/Help:Special_properties special properties] למידע נוסף).",
"smw-editpage-concept-annotation-enabled": "אפשר להרחיב את הרעיון הזה באמצעות פונקציית המפענח #concept. לתיאור של השימוש ב־#concept, ר' את דף העזרה [https://www.semantic-mediawiki.org/wiki/Help:Concepts concept].",
+ "smw-search-syntax": "תחביר",
"smw-search-profile": "מורחב",
"smw-search-profile-tooltip": "אפשרויות חיפוש שמחוברות עם ההרחבה \"מדיה־ויקי סמנטית\"",
+ "smw-search-profile-sort-best": "ההתאמה הטובה ביותר",
+ "smw-search-profile-sort-recent": "אחרון ביותר",
+ "smw-search-profile-sort-title": "כותרת",
+ "smw-search-profile-extended-help-find-forms": "מסמכים זמינים",
+ "smw-search-profile-extended-section-sort": "מיין על פי",
+ "smw-search-profile-extended-section-form": "טפסים",
+ "smw-search-profile-extended-section-search-syntax": "קלט לחיפוש",
+ "smw-search-profile-extended-section-namespace": "מרחב שם",
+ "smw-search-profile-extended-section-query": "שאילתה",
+ "smw-search-profile-link-caption-query": "צפייה",
+ "smw-search-show": "הצגה",
+ "smw-search-hide": "להסתיר",
"log-name-smw": "יומן מדיה־ויקי סמנטית",
"log-show-hide-smw": "$1 יומן מדיה־ויקי סמנטית",
"logeventslist-smw-log": "יומן מדיה־ויקי סמנטית",
@@ -421,6 +449,7 @@
"smw-type-tel": "\"$1\" הוא סוג נתונים מיוחד לתיאור מספר טלפון בין־לאומי בהתאם ל־RFC 3966.",
"smw-type-txt": "\"$1\" הוא סוג נתונים פרימיטיבי לתיאור מחרוזות באורך כלשהו.",
"smw-type-dat": "\"$1\" הוא סוג נתונים לייצוג נקודות בזמן בתסדיר מאוחד.",
+ "smw-type-tab-errors": "שגיאות",
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
"smw-property-predefined-errc": "\"$1\" הוא מאפיין מוגדר מראש שסופק ע\"י [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] ומייצג שגיאות שמופיעות בחיבור עם ערך לא מתאים או עיבוד קלט.",
"smw-property-predefined-long-errc": "שגיאות נאספות ב[https://www.semantic-mediawiki.org/wiki/Help:Container מכל] שיכול לכלול הפניה למאפיין שגרם לחוסר העקביות.",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ia.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ia.json
index c05dd258..ee212624 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ia.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ia.json
@@ -97,6 +97,7 @@
"smw-paramdesc-feeddescription": "Le texto a usar como description del syndication",
"smw-paramdesc-feedpagecontent": "Le contento del pagina a monstrar con le syndication",
"smw-label-feed-description": "Syndication $2 $1",
+ "smw-paramdesc-mimetype": "Le typo de multimedia (typo MIME) pro le file resultante",
"smw_iq_disabled": "Le consultas semantic ha essite disactivate pro iste wiki.",
"smw_iq_moreresults": "… ulterior resultatos",
"smw_parseerror": "Le valor date non esseva comprendite.",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/it.json b/www/wiki/extensions/SemanticMediaWiki/i18n/it.json
index 859c9467..1fc4bfcf 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/it.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/it.json
@@ -217,8 +217,8 @@
"smw_browselink": "Sfoglia le proprietà",
"smw_browse_article": "Inserire il nome della pagina da cui iniziare l'esplorazione",
"smw_browse_go": "Vai",
- "smw_browse_show_incoming": "mostra le proprietà che linkano qui",
- "smw_browse_hide_incoming": "nascondi le proprietà che linkano qui",
+ "smw_browse_show_incoming": "Mostra proprietà in entrata",
+ "smw_browse_hide_incoming": "Nascondi proprietà in entrata",
"smw_browse_no_outgoing": "Questa pagina non ha proprietà.",
"smw_browse_no_incoming": "Nessuna proprietà ha collegamenti verso questa pagina.",
"smw-browse-show-group": "Mostra gruppi",
@@ -245,8 +245,8 @@
"smw_smwadmin_updatenotstopped": "Per arrestare il processo di aggiornamento in corso, devi cliccare nel riquadro per confermare che sei davvero sicuro di volerlo fare.",
"smw-admin-docu": "Questa pagina speciale serve ad aiutarti durante l'installazione, aggiornamento, manutenzione e l'utilizzo di <a href=\"http://semantic-mediawiki.org\">Semantic MediaWiki</a> e fornirti anche ulteriori funzioni ed attività amministrative, nonché statistiche.\nRicordati di fare un backup dei dati importanti prima di eseguire funzioni amministrative.",
"smw-admin-environment": "Ambiente software",
- "smw-admin-db": "Manutenzione database",
- "smw-admin-dbdocu": "Semantic MediaWiki richiede alcune estensioni del database MediaWiki per poter registrare i dati semantici.\nLa funzione qui sotto verifica che il tuo database sia installato correttamente.\nLe modifiche effettuate in questo passaggio non hanno effetto sul resto del database MediaWiki, e possono essere facilmente annullate se necessario.\nQuesta funzione di impostazione può essere rieseguita più volte senza conseguenze indesiderate, ma è richiesta solo una volta all'atto dell'installazione o dell'aggiornamento.",
+ "smw-admin-db": "Configurazione database",
+ "smw-admin-dbdocu": "Semantic MediaWiki richiede la propria struttura di database (ed è indipendente da MediaWiki, quindi non influisce sul resto dell'installazione di MediaWiki) per archiviare i dati semantici.\nQuesta funzione di impostazione può essere rieseguita più volte senza conseguenze indesiderate, ma è richiesta solo una volta all'atto dell'installazione o dell'aggiornamento.",
"smw-admin-permissionswarn": "Se l'operazione avrà esito negativo con errori SQL, l'utente del database usato dal tuo wiki (controlla il tuo file \"LocalSettings.php\") probabilmente non ha permessi sufficienti.\nPuoi assegnare a questo utente permessi aggiuntivi per creare e cancellare tabelle, oppure inserire temporaneamente nel file \"LocalSettings.php\" i dati di accesso root al database, oppure usare lo script di manutenzione <code>setupStore.php</code>, che può utilizzare le credenziali di un utente amministratore.",
"smw-admin-dbbutton": "Inizializza o aggiorna tabelle",
"smw-admin-announce": "Annuncia il tuo wiki",
@@ -268,7 +268,7 @@
"smw-admin-supplementary-section-title": "Funzioni supplementari",
"smw-admin-supplementary-settings-title": "Impostazioni di configurazione",
"smw-admin-supplementary-settings-intro": "<u>$1</u> restituisce un elenco collettivo delle impostazioni disponibili utilizzate in Semantic MediaWiki",
- "smw-admin-supplementary-elastic-functions": "Funzioni disponibili",
+ "smw-admin-supplementary-elastic-functions": "Funzioni supportate",
"smw-admin-supplementary-elastic-settings-title": "Impostazioni",
"smw-admin-supplementary-elastic-nodes-title": "Nodi",
"smw-admin-supplementary-elastic-statistics-title": "Statistiche",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ja.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ja.json
index be4f2941..128986a2 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ja.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ja.json
@@ -312,6 +312,7 @@
"smw-info-par-message": "表示するメッセージです。",
"smw-info-par-icon": "表示するアイコン (「info」と「warning」のいずれか) です。",
"prefs-smw": "Semantic MediaWiki",
+ "prefs-general-options": "全般オプション",
"prefs-ask-options": "意味的検索オプション",
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/ Semantic MediaWiki](および関連する拡張機能)は、一部の選択された機能の個別のカスタマイズを提供します。 詳細な説明については、[https://www.semantic-mediawiki.org/wiki/Help:User_preferences ヘルプ]を参照してください。",
"smw-prefs-ask-options-tooltip-display": "パラメーター文字列を情報ツールチップとして表示",
@@ -352,7 +353,6 @@
"smw-admin-iddispose-done": "ID「$1」はストレージバックエンドから除去されました。",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "概要",
- "smw-admin-tab-rebuild": "メンテナンス",
"smw-livepreview-loading": "読み込み中...",
"smw-sp-searchbyproperty-description": "このページは、プロパティと名前を付けられた値によって記述されたエントリを見つけるための簡素な[https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces 閲覧インターフェース]を提供します。[[Special:PageProperty|ページのプロパティの検索]]や[[Special:Ask|問い合わせクエリビルダー]]といった他の検索インターフェースも利用可能です。",
"smw-sp-searchbyproperty-resultlist-header": "結果の一覧",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ko.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ko.json
index 5ba5af91..acad1184 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ko.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ko.json
@@ -21,6 +21,8 @@
},
"smw-desc": "위키를 기계와 사람이 더 접근하기 쉽게 합니다 ([https://www.semantic-mediawiki.org/wiki/Help:User_manual 온라인 설명서])",
"smw-title": "시맨틱 미디어위키",
+ "smw-upgrade-error-why-title": "이 오류를 보게 된 이유는 무엇입니까?",
+ "smw-upgrade-error-how-title": "이 오류를 어떻게 수정합니까?",
"smw-semantics-not-enabled": "시맨틱 미디어위키 기능은 이 위키에서 사용할 수 없습니다.",
"smw_viewasrdf": "RDF 피드",
"smw_finallistconjunct": ", 그리고",
@@ -70,7 +72,7 @@
"smw-paramdesc-distributionlimit": "일부 값만의 횟수로 값 분포를 제한합니다.",
"smw-paramdesc-template": "인쇄 출력과 함께 표시할 틀의 이름",
"smw-paramdesc-columns": "결과를 표시할 열의 수",
- "smw-paramdesc-userparam": "틀이 사용하고 있다면 각 틀 호출에 전달한 값",
+ "smw-paramdesc-userparam": "틀이 사용되는 경우 각 틀 호출에 전달되는 값입니다",
"smw-paramdesc-class": "리스트에 설정할 추가적인 CSS 클래스",
"smw-paramdesc-introtemplate": "질문에 답이 있으면 쿼리 결과 앞에 표시할 틀의 이름",
"smw-paramdesc-outrotemplate": "질문에 답이 있으면 쿼리 결과 뒤에 표시할 틀의 이름",
@@ -215,7 +217,7 @@
"smw_ask_editquery": "쿼리 편집",
"smw_add_sortcondition": "[정렬 조건 추가]",
"smw-ask-sort-add-action": "정렬 조건 추가",
- "smw_ask_hidequery": "쿼리 숨기기",
+ "smw_ask_hidequery": "쿼리 숨기기 (간략히 보기)",
"smw_ask_help": "쿼리 도움말",
"smw_ask_queryhead": "조건",
"smw_ask_printhead": "출력 선택",
@@ -247,7 +249,7 @@
"smw-ask-condition-change-info": "조건이 변경되었으므로 검색 엔진은 새로운 요구사항을 충족하는 결과를 출력하기 위해 쿼리를 다시 실행해야 합니다.",
"smw-ask-input-assistance": "입력 보조",
"smw-ask-condition-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance 입력 지원]은 출력, 정렬, 조건 필드를 위해 제공됩니다. 이 조건 필드는 다음의 접두사 중 하나를 사용해야 합니다:",
- "smw-ask-condition-input-assistance-property": "속성 제안을 사용하려면 <code>p:</code> (예: <code>[[p:Has ...</code>)",
+ "smw-ask-condition-input-assistance-property": "속성 제안을 가져오려면 <code>p:</code> (예: <code>[[p:Has ...</code>)",
"smw-ask-condition-input-assistance-category": "분류 제안을 가져오려면 <code>c:</code>",
"smw-ask-condition-input-assistance-concept": "개념 제안을 가져오려면 <code>con:</code>",
"smw-ask-format-change-info": "포맷이 수정되었으므로 새로운 변수와 시각화 옵션을 일치시키려면 쿼리를 다시 실행해야 합니다.",
@@ -297,7 +299,7 @@
"smw_smwadmin_updatenotstopped": "실행하고 있는 업데이트 과정을 중지하려면 정말 확실한지 나타내는 확인란을 활성화해야 합니다.",
"smw-admin-docu": "이 특수 문서는 <a href=\"https://www.semantic-mediawiki.org\">시맨틱 미디어위키</a>의 설치, 업그레이드, 정비, 사용 중에 도움을 주며 추가적인 관리 기능과 작업, 통계 또한 제공합니다. 관리 기능을 실행하기 전에 중요한 데이터는 백업해 주십시오.",
"smw-admin-environment": "소프트웨어 환경",
- "smw-admin-db": "데이터베이스 유지보수",
+ "smw-admin-db": "데이터베이스 설정",
"smw-admin-db-preparation": "테이블 초기화가 진행 중이며 크기 및 잠재적인 테이블 최적화가 대기 중이므로 결과가 표시되는데 시간이 걸릴 수 있습니다.",
"smw-admin-dbdocu": "시맨틱 미디어위키는 시멘틱 데이터를 저장하기 위해 미디어위키 데이터베이스에 몇 가지 확장 기능이 필요합니다.\n아래의 기능은 데이터베이스가 제대로 설정되어 있는지 확인합니다.\n이 단계에서 바뀐 내용은 미디어위키 데이터베이스의 나머지에 영향을 주지 않고, 원한다면 쉽게 되돌릴 수 있습니다.\n이 설정 기능은 어떠한 피해 없이 여러 번 실행될 수 있지만, 설치나 업그레이드에는 한 번만 필요합니다.",
"smw-admin-permissionswarn": "SQL 오류로 작업이 실패하면, 위키가 고용한 데이터베이스 사용자(LocalSettings.php를 확인하세요)는 아마도 충분한 권한이 없을 것입니다.\n테이블을 만들고 삭제할 추가 권한을 이 사용자에게 부여하거나, 일시적으로 LocalSettings.php에 데이터베이스 루트의 로그인을 입력하거나, 관리자의 자격 증명을 사용할 수 있는 <code>setupStore.php</code> 유지 관리 스크립트를 사용하세요.",
@@ -341,6 +343,9 @@
"smw-admin-supplementary-settings-title": "구성 설정",
"smw-admin-supplementary-settings-intro": "<u>$1</u>은 시맨틱 미디어위키에 쓰이는 사용 가능한 설정의 공통 목록을 출력합니다",
"smw-admin-supplementary-operational-statistics-title": "조작 통계",
+ "smw-admin-supplementary-operational-statistics-intro": "<u>$1</u>는 확장된 통계 집합을 표시합니다",
+ "smw-admin-supplementary-idlookup-title": "엔티티 검색 및 처리",
+ "smw-admin-supplementary-idlookup-intro": "<u>$1</u>는 개개의 엔티티를 검색하고 처리하기 위한 기능을 포함합니다",
"smw-admin-supplementary-duplookup-title": "중복 개체",
"smw-admin-supplementary-duplookup-docu": "이 문서는 [https://www.semantic-mediawiki.org/wiki/Help:Entity_table 개체 표]에서 중복된 것으로 분류된 개체들의 목록입니다. 중복 개체들은 (존재한다면) 데이터베이스 업데이트 중에 프로세스가 종료되거나 롤백 행동이 성공스럽지 못했을 때와 같이 매우 드문 경우에만 발생할 수 있습니다.",
"smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
@@ -348,6 +353,7 @@
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u>은(는) 캐시 관련 통계를 표시합니다",
"smw-admin-supplementary-elastic-title": "일래스틱서치",
"smw-admin-supplementary-elastic-docu": "이 문서는 시맨틱 미디어위키와 [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>일래스틱스토어</code>]에 연결된 일래스틱서치 클러스터 관련 설정, 매핑, 상태, 색인 통계에 관한 정보를 포함합니다.",
+ "smw-admin-supplementary-elastic-functions": "사용 가능한 기능",
"smw-admin-supplementary-elastic-settings-title": "설정",
"smw-admin-supplementary-elastic-mappings-title": "매핑",
"smw-admin-supplementary-elastic-mappings-summary": "요약",
@@ -356,6 +362,7 @@
"smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u>은(는) 노드 통계를 표시합니다",
"smw-admin-supplementary-elastic-indices-title": "색인",
"smw-admin-supplementary-elastic-statistics-title": "통계",
+ "smw-admin-supplementary-elastic-status-replication": "레플리케이션 상태",
"smw-admin-supplementary-elastic-status-refresh-interval": "새로 고침 주기: $1",
"smw-list-count": "이 목록은 {{PLURAL:$1|항목}} $1개를 갖고 있습니다.",
"smw-list-count-from-cache": "이 목록은 {{PLURAL:$1|항목}} $1개를 갖고 있으며 $2(UTC)에 캐시에서 검색됐습니다.",
@@ -381,8 +388,13 @@
"prefs-ask-options": "특수:Ask 옵션",
"smw-prefs-intro-text": "아래의 옵션은 [https://www.semantic-mediawiki.org/ 시맨틱 미디어위키](또는 관련된 확장 기능)가 선택된 기능에 대한 개별 사용자 지정을 활성화하기 위해 제공됩니다. 자세한 정보에 대해서는 이 [http://semantic-mediawiki.org/wiki/Help:User_preferences 도움말 문단]에서 보시기 바랍니다.",
"smw-prefs-ask-options-tooltip-display": "정보 말풍선으로 변수 텍스트 표시",
+ "smw-prefs-general-options-time-correction": "선호하는 지역 [[Special:Preferences#mw-prefsection-rendering|시간 오프셋]]을 사용하여 특수 문서의 시간 조정을 사용합니다",
+ "smw-prefs-general-options-jobqueue-watchlist": "작업 대기열 주시문서 목록을 내 개인 표시줄에 표시합나다",
+ "smw-prefs-help-general-options-jobqueue-watchlist": "활성화하면 보류 중인 선택된 작업의 [https://www.semantic-mediawiki.org/wiki/Help:Job_queue_watchlist 목록]을 쿼리 크기 추정치와 함께 표시합니다.",
"smw-prefs-general-options-disable-editpage-info": "편집 문서의 도입문을 사용하지 않음",
"smw-prefs-general-options-disable-search-info": "표준 검색 문서에서 문법 지원 정보를 비활성화합니다",
+ "smw-prefs-general-options-suggester-textinput": "시맨틱 엔티티를 위한 입력 지원을 사용합니다",
+ "smw-prefs-help-general-options-suggester-textinput": "활성화하면 입력 문맥에서 속성, 개념, 분류를 찾기 위해 [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance 입력 지원]을 사용할 수 있게 합니다.",
"smw-ui-tooltip-title-property": "속성",
"smw-ui-tooltip-title-quantity": "단위 변환",
"smw-ui-tooltip-title-info": "정보",
@@ -400,6 +412,7 @@
"smw_conceptarticlecount": "아래에 {{PLURAL:$1|문서}} $1개를 보여줍니다.",
"smw-qp-empty-data": "일부 선택 기준이 충분하지 않아 요청된 데이터를 표시할 수 없습니다.",
"right-smw-admin": "관리 작업에 접근 (시맨틱 미디어위키)",
+ "right-smw-patternedit": "허용된 정규 표현식과 패턴을 정비할 편집 권한 (시맨틱 미디어위키)",
"right-smw-ruleedit": "규칙 문서 편집 (시맨틱 미디어위키)",
"action-smw-patternedit": "시맨틱 미디어위키에 쓰이는 정규 표현식 편집",
"group-smwadministrator": "관리자(시맨틱 미디어위키)",
@@ -425,8 +438,10 @@
"smw-admin-idlookup-input": "검색:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "개요",
- "smw-admin-tab-rebuild": "유지보수",
+ "smw-admin-tab-notices": "구식 알림",
+ "smw-admin-tab-maintenance": "유지보수",
"smw-admin-tab-supplement": "추가 기능",
+ "smw-admin-maintenance-no-description": "설명이 없습니다.",
"smw-livepreview-loading": "불러오는 중...",
"smw-sp-searchbyproperty-resultlist-header": "결과 목록",
"smw-sp-searchbyproperty-nonvaluequery": "\"$1\" 속성이 할당된 값의 목록입니다.",
@@ -449,8 +464,10 @@
"smw-search-profile-extended-help-find-forms": "사용 가능한 폼",
"smw-search-profile-extended-section-sort": "정렬 기준",
"smw-search-profile-extended-section-form": "폼",
+ "smw-search-profile-extended-section-search-syntax": "검색 입력",
"smw-search-profile-extended-section-namespace": "이름공간",
"smw-search-profile-extended-section-query": "쿼리",
+ "smw-search-profile-link-caption-query": "보기",
"smw-search-show": "보기",
"smw-search-hide": "숨기기",
"log-name-smw": "시맨틱 미디어위키 로그",
@@ -505,6 +522,7 @@
"smw-datavalue-time-invalid-date-components-empty": "\"$1\"에는 일부 비어있는 구성 요소가 포함되어 있습니다.",
"smw-datavalue-time-invalid-date-components-three": "\"$1\"에는 데이터 해석에 필요한 세 개 이상의 구성 요소가 포함되어 있습니다.",
"smw-datavalue-time-invalid-ampm": "\"$1\"에는 12시간 변환에 유효하지 않은 시간 요소로서 \"$2\"이(가) 포함되어 있습니다.",
+ "smw-datavalue-time-invalid-jd": "보고된 \"$2\" 값을 가지고 \"$1\" 입력값을 유효한 JD(율리우스일) 숫자로 해석할 수 없습니다.",
"smw-datavalue-external-formatter-invalid-uri": "\"$1\"은(는) 유효하지 않은 URL입니다.",
"smw-datavalue-keyword-maximum-length": "키워드가 $1의 최대 길이를 초과했습니다.",
"smw-datavalue-parse-error": "지정한 \"$1\" 값을 인식하지 못했습니다.",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/lb.json b/www/wiki/extensions/SemanticMediaWiki/i18n/lb.json
index 98395265..2d0302e7 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/lb.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/lb.json
@@ -8,6 +8,8 @@
},
"smw-desc": "Är Wiki méi accessibel machen - fir Maschinnen ''a'' Menschen ([https://www.semantic-mediawiki.org/wiki/Help:User_manual online documentation])",
"smw-title": "Semantic MediaWiki",
+ "smw-upgrade-error-why-title": "Firwat gesinn ech dëse Feeler?",
+ "smw-upgrade-error-how-title": "Wéi kann ech dëse Feeler flécken?",
"smw-semantics-not-enabled": "D'Semantic MediaWiki Funktioun gouf op dëser Wiki net ageschalt.",
"smw_viewasrdf": "RDF-Feed",
"smw_finallistconjunct": ", an",
@@ -248,7 +250,7 @@
"smw-admin-idlookup-input": "Sichen:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Iwwersiicht",
- "smw-admin-tab-rebuild": "Maintenance",
+ "smw-admin-maintenance-no-description": "Keng Beschreiwung.",
"smw-livepreview-loading": "Lueden...",
"smw-sp-searchbyproperty-resultlist-header": "Lëscht vun de Resultater",
"smw-editpage-annotation-disabled": "Dës Säit ass net fir semantesch Notifikatiounen am Text konfiguréiert duerch d'Limitatiounen an dësem Nummraum. Detailer wéi dat fir den Nummraum ageschalt ka gi fannt Dir op der Hëllefssäit fir d'[https://www.semantic-mediawiki.org/wiki/Help:Configuration Astellungen].",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/mk.json b/www/wiki/extensions/SemanticMediaWiki/i18n/mk.json
index 3f0b4c56..741a82bc 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/mk.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/mk.json
@@ -101,7 +101,7 @@
"smw_kiloseparator": ".",
"smw_notitle": "„$1“ не може да се користи како име на страница во ова вики.",
"smw_noproperty": "„$1“ не може да се користи како име на својство во ова вики.",
- "smw_wrong_namespace": "Тука се дозвоени само страници во именскиот простор „$1“.",
+ "smw_wrong_namespace": "Тука се дозволени само страници во именскиот простор „$1“.",
"smw_manytypes": "За својството е определен повеќе од еден тип.",
"smw_emptystring": "Не се прифаќаат празни низи.",
"smw_notinenum": "„$1“ не е на списокот ($2) на [[Property:Allows value|допуштени вредности]] за својството „$3“.",
@@ -134,6 +134,7 @@
"smw_typearticlecount": "{{PLURAL:$1|Прикажано е $1 својство кое го користи|Прикажани се $1 својства кои го користат}} овој тип.",
"smw_attribute_header": "Страници кои го користат својството „$1“",
"smw_attributearticlecount": "{{PLURAL:$1|Прикажана е $1 страница која го користи ова својство|Прикажани се $1 страници кои го користат}} ова својство.",
+ "smw-propertylist-subproperty-header": "Потсвојства",
"smw-propertylist-redirect-header": "Истозначници",
"smw-propertylist-count": "{{PLURAL:$1|Прикажана е $1 единица|Прикажани се $1 единици}}.",
"smw-propertylist-count-with-restricted-note": "{{PLURAL:$1|Прикажана е $1 поврзана единица|Прикажани се $1 поврзани единици}}. (достапни се повеќе, но ограничувањето е „$2“).",
@@ -201,7 +202,7 @@
"smw_ask_descorder": "Надолен",
"smw-ask-order-rand": "Случајна",
"smw_ask_submit": "Пронајди",
- "smw_ask_editquery": "(Уреди барање)",
+ "smw_ask_editquery": "Уреди барање",
"smw_add_sortcondition": "(Додај услов за подредување)",
"smw-ask-sort-add-action": "Додај услов за подредување",
"smw_ask_hidequery": "Скриј барање (компактен изглед)",
@@ -273,6 +274,7 @@
"smw-admin-dbbutton": "Започни или поднови табели",
"smw-admin-announce": "Објавете го вашето вики",
"smw-admin-announce-text": "Ако вашето вики е јавно, можете да го регистрирате на <a href=\"https://wikiapiary.com\">WikiApiary</a> — викито за следење на викија.",
+ "smw-admin-deprecation-notice-title-notice": "Претстојни промени",
"smw_smwadmin_datarefresh": "Поправка и поднова на податоци",
"smw_smwadmin_datarefreshdocu": "Постои можност за враќање на сите податоци на Семантички МедијаВики врз основа на тековните содржини на викито.\nОва е корисно за поправка на оштетени податоци или за обнова на податоците ако внатрешниот формат се има променето како последица на некаква надградба на програмската опрема.\nПодновувањето се врши страница по страница, и ќе треба да помине некое време за да профункционира.\nПодолу е прикажано дали има поднова во тек, и тоа ви овозможува да започнувате или запирате подновувања (освен ако таа можност не е исклучена од администраторот на мрежното место).",
"smw_smwadmin_datarefreshprogress": "<strong>Веќе е во тек една поднова.</strong>\nНормално е подновата да биде бавна, бидејќи податоците се обновуваат во мали делчиња секојпат кога корисникот ќе отиде на викито.\nЗа да ја убрзате подновата, можете да ја повикате скриптата за одржување на MediaWiki <code>runJobs.php</code> (користете ја можноста <code>--maxjobs 1000</code> за да го ограничите бројот на поднови во една партија).\nПроценет напредок на тековната поднова:",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/nb.json b/www/wiki/extensions/SemanticMediaWiki/i18n/nb.json
index dc9c2813..f2478870 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/nb.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/nb.json
@@ -336,14 +336,20 @@
"smw-admin-smwhomepage": "Den komplette brukerdokumentasjonen til Semantic MediaWiki finnes på <b><a href=\"https://semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
"smw-admin-bugsreport": "Feil kan rapporteres til <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">saksflytverktøyet</a>. <a href=\"https://www.semantic-mediawiki.org/wiki/Help:Reporting_bugs\">Feilrapportsiden</a> gir retningslinjer om hvordan en skriver en effektiv feilrapport.",
"smw-admin-questions": "Hvis du har ytterligere spørsmål eller forslag, bli med i diskusjonen på <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">Semantic MediaWiki brukerforum</a> eller <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">chatroom</a>.",
+ "smw-admin-other-functions": "Andre funksjoner",
"smw-admin-supplementary-section-title": "Ekstra funksjoner",
- "smw-admin-supplementary-section-intro": "Noen av funksjonene i dette avsnittet kan ha begrensninger og derfor være utilgjengelige på denne wikien.",
+ "smw-admin-supplementary-section-subtitle": "Tilgjengelige funksjoner",
+ "smw-admin-supplementary-section-intro": "Dette avsnittet har tilleggsfunksjoner utover det som behøves for vedlikehold, og det er mulig at noen funksjoner som angis i https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions documentation] er begrenset eller utilgjengelig og derfor ikke kan brukes på denne wikien.",
"smw-admin-supplementary-settings-title": "Konfigurasjonsinnstillinger",
"smw-admin-supplementary-settings-intro": "<u>$1</u> inneholder ei liste over tilgjengelige innstillinger som brukes i Semantic MediaWiki",
"smw-admin-supplementary-operational-statistics-title": "Driftsstatistikk",
"smw-admin-supplementary-operational-statistics-intro": "<u>$1</u> viser en utvidet samling statistikker",
"smw-admin-supplementary-idlookup-title": "Elementoppslag og forkasting",
"smw-admin-supplementary-idlookup-intro": "<u>$1</u> inneholder funksjoner for oppslag og forkasting av enkeltelementer",
+ "smw-admin-supplementary-duplookup-title": "Dupliser elementer",
+ "smw-admin-supplementary-duplookup-intro": "<u>$1</u> for å angi elementer som er kategorisert å inneholde duplikater i elementtabellen",
+ "smw-admin-supplementary-duplookup-docu": "Denne siden angir elementer fra [https://www.semantic-mediawiki.org/wiki/Help:Entity_table entity table] som er kategorisert som duplikater. Duplikate elementer bør, om noensinne, bare opptre i sjeldne tilfeller, ev. forårsaket av en avsluttet prosess under en databaseoppdatering eller en mislykket tilbakerulling fra sikkerhetskopi.",
+ "smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
"smw-property-label-uniqueness": "\"$1\"-etiketten hadde treff på minst en egenskap til. Vær vennlig å studere [https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness hjelpesiden] om hvordan du kan løse saken.",
"smw-property-label-similarity-title": "Likhetsrapport for egenskapsetikett",
"smw-property-label-similarity-intro": "<u>$1</u> påviser likheter innenfor eksisterende egenskapsetiketter",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/nl.json b/www/wiki/extensions/SemanticMediaWiki/i18n/nl.json
index 5c41cb0b..938b14e5 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/nl.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/nl.json
@@ -24,7 +24,9 @@
"Mar(c)",
"Patio",
"KlaasZ4usV",
- "Goefie"
+ "Goefie",
+ "Robin van der Linde",
+ "Elroy"
]
},
"smw-desc": "Uw wiki toegankelijker maken – voor machines ''en'' mensen ([https://www.semantic-mediawiki.org/wiki/Help:User_manual online documentatie])",
@@ -257,7 +259,7 @@
"smw-ask-no-cache": "Geen cache",
"smw-ask-no-cache-desc": "Resultaten zonder querycache",
"smw-ask-result": "Resultaat",
- "smw-ask-empty": "Leeg",
+ "smw-ask-empty": "Alle vermeldingen wissen",
"smw-ask-download-link-desc": "Download opgevraagde resultaten in $1-formaat",
"smw-ask-format": "Indeling",
"smw-ask-format-selection-help": "Hulp voor het geselecteerde formaat: $1.",
@@ -302,7 +304,7 @@
"smw_result_next": "Volgende",
"smw_result_results": "Resultaten",
"smw_result_noresults": "Geen resultaten.",
- "smwadmin": "Administratieve functies",
+ "smwadmin": "Beheer- en onderhoudsonderdelen",
"smw-admin-statistics-job-title": "Taakstatistieken",
"smw-admin-statistics-job-docu": "De taakstatistieken tonen informatie over geplande Semantic MediaWiki-taken die nog niet zijn uitgevoerd. Het aantal taken kan enigszins afwijken of mislukte pogingen bevatten. Raadpleeg de [https://www.mediawiki.org/wiki/Manual:Job_queue handleiding] voor meer informatie.",
"smw-admin-statistics-querycache-title": "Querycachestatistieken",
@@ -353,12 +355,16 @@
"smw-admin-supplementary-section-subtitle": "Beschikbare functies",
"smw-admin-supplementary-settings-title": "Configuratie-instellingen",
"smw-admin-supplementary-operational-statistics-title": "Operationele statistieken",
+ "smw-admin-supplementary-operational-statistics-cache-title": "Cachestatistieken",
+ "smw-admin-supplementary-elastic-functions": "Beschikbare functies",
"smw-admin-supplementary-elastic-settings-title": "Instellingen",
"smw-admin-supplementary-elastic-mappings-summary": "Samenvatting",
"smw-admin-supplementary-elastic-indices-title": "Indices",
"smw-admin-supplementary-elastic-statistics-title": "Statistieken",
+ "smw-admin-supplementary-elastic-status-refresh-interval": "Verversinterval: $1",
"smw-property-label-similarity-threshold": "Drempelwaarde:",
"smw-property-label-similarity-type": "Typenummer weergeven",
+ "smw-property-label-similarity-noresult": "Er zijn geen resultaten gevonden voor de geselecteerde opties.",
"smw_adminlinks_datastructure": "Gegevensstructuur",
"smw_adminlinks_displayingdata": "Gegevens weergeven",
"smw_adminlinks_inlinequerieshelp": "Hulp bij inline zoekopdrachten",
@@ -418,7 +424,6 @@
"smw-admin-idlookup-input": "Zoeken:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Overzicht",
- "smw-admin-tab-rebuild": "Onderhoud",
"smw-admin-tab-registry": "Register",
"smw-livepreview-loading": "Bezig met laden…",
"smw-sp-searchbyproperty-description": "Deze pagina biedt een eenvoudige [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces bladerinteractie] voor het vinden van entiteiten met een eigenschap met een bepaalde waarde. Andere beschikbare zoekinteracties zijn de [[Special:PageProperty|zoekpagina voor pagina-eigenschappen]] en de [[Special:Ask|querybouwer]].",
@@ -427,6 +432,7 @@
"smw-sp-searchbyproperty-valuequery": "Een lijst van pagina's waarop de eigenschap ''$1'' de waarde ''$2'' heeft.",
"smw-datavalue-number-textnotallowed": "\"$1\" kan niet worden toegewezen aan een getaltype met waarde $2.",
"smw-search-profile": "Uitgebreid",
+ "smw-search-profile-sort-recent": "Meest recent",
"smw-search-profile-sort-title": "Titel",
"smw-search-profile-extended-help-query-link": "(Voor meer details $1).",
"smw-search-profile-extended-help-find-forms": "beschikbare formulieren",
@@ -450,6 +456,9 @@
"smw-type-tel": "\"$1\" is een speciaal gegevenstype om internationale telefoonnummers te beschrijven conform RFC 3966.",
"smw-type-txt": "\"$1\" is een primitief gegevenstype om tekenreeksen van willekeurige lengte te beschrijven.",
"smw-type-dat": "\"$1\" is een gegevenstype om punten in de tijd te representeren in een uniform formaat.",
+ "smw-type-tab-properties": "Eigenschappen",
+ "smw-type-tab-types": "Typen",
+ "smw-type-tab-errors": "Fouten",
"smw-datavalue-languagecode-invalid": "\"$1\" wordt niet herkend als een ondersteunde taalcode.",
"smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|seconde|seconden}}",
"smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|seconde|seconden}}",
@@ -484,5 +493,14 @@
"smw-help": "Hulp",
"smw-processing": "Verwerken...",
"smw-types-title": "Type: $1",
- "smw-ask-tab-result": "Resultaat"
+ "smw-parameter-missing": "Parameter \"$1\" ontbreekt.",
+ "smw-property-tab-usage": "Gebruik",
+ "smw-property-tab-redirects": "Synoniemen",
+ "smw-property-tab-subproperties": "Subeigenschappen",
+ "smw-property-tab-errors": "Onjuiste toewijzingen",
+ "smw-property-tab-specification": "... meer",
+ "smw-concept-tab-list": "Lijst",
+ "smw-concept-tab-errors": "Fouten",
+ "smw-ask-tab-result": "Resultaat",
+ "smw-ask-tab-extra": "Extra"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/pl.json b/www/wiki/extensions/SemanticMediaWiki/i18n/pl.json
index 5bb8d315..f28a53c4 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/pl.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/pl.json
@@ -22,7 +22,8 @@
"InternerowyGołąb",
"Wojtas",
"Krottyianock",
- "Railfail536"
+ "Railfail536",
+ "CiaPan"
]
},
"smw-desc": "Poprawia dostępność wiki zarówno dla automatów jak i ludzi ([https://www.semantic-mediawiki.org/wiki/Help:User_manual dokumentacja online])",
@@ -90,6 +91,7 @@
"smw-paramdesc-rdfsyntax": "Wykorzystywana składnia RDF",
"smw-paramdesc-csv-sep": "Określa separator kolumn",
"smw-paramdesc-csv-valuesep": "Określa separator wartości",
+ "smw-paramdesc-csv-bom": "Dodaj BOM (znacznik kolejności bajtów) na początku pliku wynikowego",
"smw-paramdesc-dsv-separator": "Użyty separator",
"smw-paramdesc-dsv-filename": "Nazwa pliku DSV",
"smw-paramdesc-filename": "Nazwa pliku wyjściowego",
@@ -175,17 +177,18 @@
"smw-special-concept-count": "Znaleziono {{PLURAL:$1|1 koncept|$1 koncepty|$1 konceptów}}.",
"smw-special-concept-empty": "Nie znaleziono konceptów.",
"unusedproperties": "Niewykorzystywane właściwości",
- "smw-unusedproperties-docu": "Następujące właściwości istnieją, mimo że żadne inne strony ich nie wykorzystują.",
+ "smw-unusedproperties-docu": "Ta strona wymienia [https://www.semantic-mediawiki.org/wiki/Unused_properties niewykorzystywane właściwości], które są zadeklarowane, choć żadna inna strona z nich nie korzysta. Odmiennego spojrzenia dostarczają wykazy na stronach specjalnych [[Special:Properties|wszystkich]] oraz [[Special:WantedProperties|pożądanych właściwości]].",
"smw-unusedproperty-template": "$1 typu $2",
"wantedproperties": "Pożądane właściwości",
- "smw-wantedproperties-docu": "Następujące właściwości są wykorzystywane na wiki, ale nie mają jeszcze opisującej ich strony.",
+ "smw-wantedproperties-docu": "Ta strona wymienia [https://www.semantic-mediawiki.org/wiki/Wanted_properties pożądane właściwości], które są używane w wiki, ale nie mają strony opisującej je. Odmiennego spojrzenia dostarczają wykazy na stronach specjalnych [[Special:Properties|wszystkich]] oraz [[Special:UnusedProperties|niewykorzystywanych właściwości]].",
"smw-wantedproperty-template": "$1 (wykorzystane {{PLURAL:$2|raz|$2 razy}})",
+ "smw-special-wantedproperties-docu": "Ta strona wymienia [https://www.semantic-mediawiki.org/wiki/Wanted_properties pożądane właściwości], które są używane w wiki, ale nie mają strony opisującej je. Odmiennego spojrzenia dostarczają wykazy na stronach specjalnych [[Special:Properties|wszystkich]] oraz [[Special:UnusedProperties|niewykorzystywanych właściwości]].",
"smw-special-wantedproperties-template": "$1 ($2 {{PLURAL:$2|użycie|użycia|użyć}})",
"smw_purge": "Odśwież",
"smw-purge-failed": "Odświeżanie nie powiodło się",
"types": "Typy",
- "smw_types_docu": "Poniżej znajduje się lista wszystkich typów danych, które mogą zostać przypisane atrybutom.",
- "smw-special-types-no-such-type": "Określony typ danych nie istnieje",
+ "smw_types_docu": "Wykaz [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes dostępnych typów danych]. Każdy [https://www.semantic-mediawiki.org/wiki/Help:Datatype typ] reprezentuje unikatowy zbiór atrybutów charakteryzujących wartości poprzez sposób ich składowania w pamięci i wyświetlania. Charakterystyki te są dziedziczone w przypisanych właściwościach.",
+ "smw-special-types-no-such-type": "\"$1\" jest nieznany lub nie został określony jako poprawny typ danych.",
"smw-statistics": "Statystyka semantyczna",
"smw-statistics-property-instance": "{{PLURAL:$1|Wartość|Wartości}} właściwości (łącznie)",
"smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|Właściwość|Właściwości}}]] (łącznie)",
@@ -214,10 +217,10 @@
"smw_ask_editquery": "Edytuj zapytanie",
"smw_add_sortcondition": "[Dodaj warunki sortowania]",
"smw-ask-sort-add-action": "Dodaj warunek sortowania",
- "smw_ask_hidequery": "Ukryj zapytanie",
+ "smw_ask_hidequery": "Ukryj zapytanie (widok skrócony)",
"smw_ask_help": "Pomoc dla tworzenia zapytań",
"smw_ask_queryhead": "Warunek",
- "smw_ask_printhead": "Dodatkowe dane do wyświetlenia",
+ "smw_ask_printhead": "Instrukcje wydruku",
"smw_ask_printdesc": "(dodaj w linii jedną nazwę właściwości)",
"smw_ask_format_as": "Formatuj jako",
"smw_ask_defaultformat": "domyślny",
@@ -235,7 +238,7 @@
"smw-ask-search": "Szukaj",
"smw-ask-debug": "Debugowanie",
"smw-ask-debug-desc": "Tworzy informacje o debugowaniu zapytań",
- "smw-ask-no-cache": "Nie używaj pamięci podręcznej",
+ "smw-ask-no-cache": "Wyłącz pamięć podręczną",
"smw-ask-no-cache-desc": "Wyniki bez pamięci podręcznej zapytań",
"smw-ask-result": "Wynik",
"smw-ask-empty": "Wymaż wszystkie wpisy",
@@ -257,8 +260,8 @@
"smw_browselink": "Przeglądaj właściwości",
"smw_browse_article": "Wpisz nazwę artykułu, od którego chcesz rozpocząć przeglądanie.",
"smw_browse_go": "Idź",
- "smw_browse_show_incoming": "pokaż właściwości linkujące tutaj",
- "smw_browse_hide_incoming": "ukryj właściwości linkujące tutaj",
+ "smw_browse_show_incoming": "Pokaż właściwości linkujące tutaj",
+ "smw_browse_hide_incoming": "Ukryj właściwości linkujące tutaj",
"smw_browse_no_outgoing": "Ta strona nie ma żadnych właściwości.",
"smw_browse_no_incoming": "Żadne właściwości nie linkują do tej strony.",
"smw-browse-from-backend": "Informacje są obecnie pobierane z zaplecza.",
@@ -288,11 +291,11 @@
"smw_smwadmin_updatenotstarted": "Jest już uruchomiony proces aktualizacji.\nKolejny nie zostanie utworzony.",
"smw_smwadmin_updatestopped": "Wszystkie istniejące procesy aktualizacji zostały zatrzymane.",
"smw_smwadmin_updatenotstopped": "W celu zatrzymania uruchomionego procesu aktualizacji należy zaznaczyć pole wyboru, aby potwierdzić decyzję.",
- "smw-admin-docu": "Ta strona specjalna pomoże Ci w instalacji i modernizacji <a href=\"http://semantic-mediawiki.org\">Semantycznego MediaWiki</a>.\nPamiętaj przed wykonaniem funkcji administracyjnych o utworzeniu kopii zapasowej ważnych danych.",
+ "smw-admin-docu": "Ta strona specjalna pomoże Ci w instalacji, modernizacji, utrzymaniu i użytkowaniu <a href=\"https://www.semantic-mediawiki.org\">Semantycznego MediaWiki</a> a także udostępnia dalsze funkcje i zadania administracyjne oraz statystyki.\nPamiętaj przed wykonaniem funkcji administracyjnych o utworzeniu kopii zapasowej ważnych danych.",
"smw-admin-db": "Konserwacja bazy danych",
"smw-admin-db-preparation": "Inicjalizacja tabeli trwa i może chwilę potrwać, zanim wyniki zostaną wyświetlone w oczekiwaniu na rozmiar i możliwe optymalizacje tabeli.",
"smw-admin-dbdocu": "Semantyczne MediaWiki wymaga rozszerzeń do bazy danych MediaWiki, które umożliwiają przechowywanie danych semantycznych.\nPoniższa funkcja zapewnia, że baza danych zostanie poprawnie przygotowana.\nZmiany wykonane w tym kroku nie mają wpływu na pozostałą część bazy danych MediaWiki i mogą łatwo zostać cofnięte w razie potrzeby.\nTa operacja może zostać wykonana wielokrotnie bez wyrządzenia szkód ale konieczna jest tylko raz w trakcie instalacji lub aktualizacji.",
- "smw-admin-permissionswarn": "Jeśli operacja nie powiedzie się i wystąpią błędy SQL, najprawdopodobniej użytkownik bazy danych wykorzystywany przez Twoją wiki (sprawdź plik LocalSettings.php) nie ma wystarczających uprawnień.\nNadaj użytkownikowi dodatkowe uprawnienia do tworzenia i usuwania tabel, tymczasowo użyj konta root w pliku LocalSettings.php lub użyj skryptu konserwacyjnego <code>setupStore.php</code>, który ma uprawnienia administratora.",
+ "smw-admin-permissionswarn": "Jeśli operacja nie powiedzie się i wystąpią błędy SQL, najprawdopodobniej użytkownik bazy danych wykorzystywany przez Twoją wiki (sprawdź plik LocalSettings.php) nie ma wystarczających uprawnień.\nNadaj użytkownikowi dodatkowe uprawnienia do tworzenia i usuwania tabel, tymczasowo użyj konta root bazy danych w pliku LocalSettings.php lub użyj skryptu konserwacyjnego <code>setupStore.php</code>, który ma uprawnienia administratora.",
"smw-admin-dbbutton": "Inicjuj lub aktualizuj tabele",
"smw-admin-announce": "Ogłoś swoją wiki",
"smw-admin-deprecation-notice-docu": "Poniższa sekcja zawiera ustawienia, które zostały wycofane lub usunięte, ale zostały wykryte jako aktywne na tej wiki. Oczekuje się, że każda kolejna wersja usunie obsługę tych konfiguracji.",
@@ -342,6 +345,7 @@
"smw-admin-supplementary-elastic-mappings-title": "Mapowania",
"smw-admin-supplementary-elastic-mappings-summary": "Podsumowanie",
"smw-admin-supplementary-elastic-nodes-title": "Węzły",
+ "smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u> pokazuje statystyki węzła",
"smw-admin-supplementary-elastic-indices-title": "Wskaźniki",
"smw-admin-supplementary-elastic-statistics-title": "Statystyki",
"smw-admin-supplementary-elastic-status-replication": "Status replikacji",
@@ -382,7 +386,7 @@
"smw-ui-tooltip-title-note": "Notatka",
"smw-ui-tooltip-title-legend": "Legenda",
"smw-ui-tooltip-title-reference": "Przypis",
- "smw_unknowntype": "Typ atrybutu jest nieprawidłowy.",
+ "smw_unknowntype": "Typ \"$1\" tego atrybutu jest nieprawidłowy.",
"smw_concept_header": "Strony koncepcji „$1”",
"smw_conceptarticlecount": "{{PLURAL:$1|Wyświetlona jest jedna strona |Wyświetlone zostały $1 strony|Wyświetlonych zostało $1 stron}}.",
"smw-qp-empty-data": "Żądane dane nie mogły zostać wyświetlone ze względu na niewystarczające kryteria wyboru.",
@@ -400,6 +404,7 @@
"action-smw-ruleedit": "edytowania strony reguł (Semantic MediaWiki)",
"smw-property-predefined-default": "„$1” jest właściwością predefiniowaną.",
"smw-property-predefined-long-askde": "Jest to wartość numeryczna obliczana na podstawie zagnieżdżenia podkwerendy, łańcuchów własności i dostępnych elementów opisu z wykonaniem zapytania ograniczonego przez parametr konfiguracyjny <code>[https://www.semantic-mediawiki.org/wiki/Help:$smwgQMaxDepth $smwgQMaxDepth]</code>.",
+ "smw-sp-properties-docu": "Ta strona wymienia [https://www.semantic-mediawiki.org/wiki/Property właściwości] dostępne dla tej wiki oraz liczniki ich użycia. Dla utrzymania aktualności statystyk liczników zaleca się regularne uruchamianie skryptu administracyjnego [https://www.semantic-mediawiki.org/wiki/rebuildPropertyStatistics statystyk właściwości]. Odmiennego spojrzenia dostarczają wykazy na stronach specjalnych [[Special:UnusedProperties|właściwości niewykorzystywanych]] oraz [[Special:WantedProperties|pożądanych]].",
"smw-sp-properties-cache-info": "Wymienione dane zostały pobrane z [https://www.semantic-mediawiki.org/wiki/Caching cache] i były ostatnio aktualizowane $1.",
"smw-sp-properties-header-label": "Lista właściwości",
"smw-sp-admin-settings-button": "Utwórz listę ustawień",
@@ -407,7 +412,6 @@
"smw-admin-idlookup-input": "Wyszukiwanie:",
"smw-admin-objectid": "Identyfikator:",
"smw-admin-tab-general": "Przegląd",
- "smw-admin-tab-rebuild": "Konserwacja",
"smw-admin-tab-supplement": "Funkcje dodatkowe",
"smw-admin-tab-registry": "Rejestr",
"smw-livepreview-loading": "Trwa ładowanie…",
@@ -422,6 +426,7 @@
"smw-search-profile-sort-recent": "Najnowsze",
"smw-search-profile-sort-title": "Tytuł",
"smw-search-profile-extended-help-namespace": "Pole wyboru przestrzeni nazw zostanie ukryte, gdy tylko zostanie wybrany formularz, ale można je pokazać za pomocą przycisku „pokaż/ukryj”.",
+ "smw-search-profile-extended-help-query-link": "(Aby uzyskać więcej szczegółów $1).",
"smw-search-profile-extended-section-sort": "Sortuj według",
"smw-search-profile-extended-section-namespace": "Przestrzeń nazw",
"smw-search-profile-extended-section-query": "Zapytanie",
@@ -442,8 +447,12 @@
"smw-types-list": "Lista typów danych",
"smw-types-default": "„$1” jest wbudowanym typem danych.",
"smw-types-help": "Więcej informacji i przykładów można znaleźć na tej [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 stronie pomocy].",
+ "smw-type-boo": "„$1” jest podstawowym typem danych opisującym wartość prawda/fałsz.",
"smw-type-tel": "„$1” to specjalny typ danych do opisywania międzynarodowych numerów telefonicznych zgodnie z RFC 3966.",
- "smw-type-dat": "„$1” to typ danych reprezentujący punkty w czasie w ujednoliconym formacie.",
+ "smw-type-dat": "„$1” to podstawowy typ danych, reprezentujący punkty w czasie w ujednoliconym formacie.",
+ "smw-type-ema": "„$1” jest specjalnym typem danych reprezentującym adres e-mail.",
+ "smw-type-tem": "„$1” jest specjalnym typem danych reprezentującym temperaturę.",
+ "smw-type-qty": "„$1” jest typem danych opisującym wielkości z reprezentacją numeryczną i jednostką miary.",
"smw-type-tab-properties": "Właściwości",
"smw-type-tab-types": "Typy",
"smw-type-tab-errors": "Błędy",
@@ -489,7 +498,7 @@
"smw-data-lookup": "Pobieranie danych...",
"smw-data-lookup-with-wait": "Żądanie jest przetwarzane i może zająć chwilę.",
"smw-no-data-available": "Brak dostępnych danych.",
- "smw-property-req-violation-predefined-type": "Właściwość „$1” jako predefiniowana właściwość zawiera deklarację typu „$3”, która jest niezgodna z domyślnym typem tej właściwości.",
+ "smw-property-req-violation-predefined-type": "Właściwość „$1” jako predefiniowana właściwość zawiera deklarację typu „$2”, która jest niezgodna z domyślnym typem tej właściwości.",
"smw-property-req-violation-type": "Właściwość zawiera konkurencyjne specyfikacje typów, które mogą skutkować adnotacjami o nieprawidłowej wartości, dlatego oczekuje się, że użytkownik przydzieli jeden odpowiedni typ.",
"protect-level-smw-pageedit": "Zezwalaj tylko użytkownikom z uprawnieniami do edycji stron (Semantic MediaWiki)",
"smw-edit-protection": "Ta strona jest [[Property:Is edit protected|zabezpieczona]], aby zapobiec przypadkowej modyfikacji danych i może być edytowana tylko przez użytkowników z odpowiednimi uprawnieniami do edycji („$1”) lub [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups grupę użytkowników].",
@@ -530,6 +539,9 @@
"smw-processing": "Przetwarzanie...",
"smw-redirect-target-unresolvable": "Cel jest nierozwiązalny z powodu „$1”",
"smw-types-title": "Typ: $1",
+ "smw-schema-type-help-link": "https://www.semantic-mediawiki.org/wiki/Help:Schema/Type/$1",
+ "smw-schema-type": "Typ",
+ "smw-schema-tag": "{{PLURAL:$1|Znacznik|Znaczniki}}",
"smw-ask-title-keyword-type": "Wyszukiwanie słów kluczowych",
"smw-ask-message-keyword-type": "To wyszukiwanie pasuje do warunku <code><nowiki>$1</nowiki></code>.",
"smw-remote-source-unavailable": "Nie można połączyć się ze zdalnym celem „$1”.",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/pt-br.json b/www/wiki/extensions/SemanticMediaWiki/i18n/pt-br.json
index 0e31585a..94258a64 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/pt-br.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/pt-br.json
@@ -33,6 +33,11 @@
},
"smw-desc": "Tornando seu wiki mais acessível - para máquinas ''e'' humanos ([https://www.semantic-mediawiki.org/wiki/Help:User_manual documentação online])",
"smw-title": "Semantic MediaWiki",
+ "smw-upgrade-error": "O Semantic MediaWiki foi instalado e ativado mas está faltando um [https://www.semantic-mediawiki.org/wiki/Help:Upgrade código de atualização] apropriado que corresponda: <code>$1</code>.",
+ "smw-upgrade-error-why-title": "Por que eu vejo este erro?",
+ "smw-upgrade-error-why-explain": "A estrutura interna do banco de dados do Semantic MediaWiki foi alterada e necessita alguns ajustes para estar totalmente funcional. Pode haver vários motivos incluindo: \n* Propriedades fixas adicionais (requer configuração de tabelas) foram adicionadas\n* Uma atualização contém algumas mudanças nas tabelas ou índices tornando uma interceptação obrigatória antes de acessar os dados",
+ "smw-upgrade-error-how-title": "Como corrigir este erro?",
+ "smw-upgrade-error-how-explain": "Um administrador (ou qualquer pessoa com direitos administrativos) precisa executar o script de manutenção [https://www.mediawiki.org/wiki/Manual:Update.php update.php] do MediaWiki ou o [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] do Semantic MediaWiki. Você também pode consultar as seguintes páginas para mais informações:\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation Instruções de instalação] \n* [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting Solução de problemas]",
"smw-semantics-not-enabled": "A funcionalidade do Semantic MediaWiki não foi ativada neste wiki.",
"smw_viewasrdf": "Feed RDF",
"smw_finallistconjunct": " e",
@@ -126,6 +131,7 @@
"smw-paramdesc-feeddescription": "Texto a ser utilizado como descrição do feed",
"smw-paramdesc-feedpagecontent": "Conteúdo da página a ser exibido com o feed",
"smw-label-feed-description": "$1 $2 feed",
+ "smw-paramdesc-mimetype": "O tipo de mídia (MIME type) para o arquivo de saída.",
"smw_iq_disabled": "As consultas semânticas foram desativadas neste wiki",
"smw_iq_moreresults": "… mais resultados",
"smw_parseerror": "O valor fornecido não foi compreendido.",
@@ -138,6 +144,7 @@
"smw_emptystring": "Cadeias de caracteres vazias não são aceitas.",
"smw_notinenum": "\"$1\" não está na lista ($2) dos [[Property:Allows value|valores permitidos]] para a propriedade \"$3\".",
"smw-datavalue-constraint-error-allows-value-list": "\"$1\" não está na lista ($2) dos [[Property:Allows value|valores permitidos]] para a propriedade \"$3\".",
+ "smw-datavalue-constraint-error-allows-value-range": "\"$1\" não está no intervalo de \"$2\" especificado pela restrição [[Property:Allows value|permite valor]] para a propriedade \"$3\".",
"smw_noboolean": "\"$1\" não é reconhecido como um valor Booleano (verdadeiro/falso).",
"smw_true_words": "verdadeiro,v,sim,s,true,t,yes,y",
"smw_false_words": "falso,f,não,nao,n,false,no",
@@ -336,9 +343,9 @@
"smw_smwadmin_updatenotstopped": "Para parar o processo de atualização em execução, você precisa ativar a caixa de seleção para indicar que realmente tem certeza.",
"smw-admin-docu": "Esta página especial te ajuda durante a instalação, atualização ou manutenção do <a href=\"http://semantic-mediawiki.org\">Semantic MediaWiki</a>. Ela também fornece funções administrativas, tarefas e estatísticas. \nLembre-se de efetuar cópias de segurança dos dados importantes antes de executar funções administrativas.",
"smw-admin-environment": "Ambiente de software",
- "smw-admin-db": "Manutenção da base de dados",
+ "smw-admin-db": "Configuração do banco de dados",
"smw-admin-db-preparation": "A inicialização da tabela está em curso e pode demorar algum tempo até que os resultados sejam apresentados, dependendo do tamanho e de possíveis otimizações da tabela.",
- "smw-admin-dbdocu": "O Semantic MediaWiki requer algumas extensões à base de dados MediaWiki de forma a armazenar os dados semânticos. \nA função abaixo assegura que a sua base de dados esteja devidamente configurada. \nAs alterações feitas neste passo não afetam o resto da base de dados do MediaWiki e podem ser facilmente desfeitas se desejado.\nEsta função de instalação pode ser executada várias vezes sem causar quaisquer danos, mas é necessária apenas uma vez na instalação ou na atualização.",
+ "smw-admin-dbdocu": "O Semantic MediaWiki requer sua própria estrutura de banco de dados (e é independente do MediaWiki, portanto, não afeta o resto da instalação do MediaWiki), a fim de armazenar os dados semânticos.\nEsta função de instalação pode ser executada várias vezes sem causar quaisquer danos, mas é necessária apenas uma vez na instalação ou na atualização.",
"smw-admin-permissionswarn": "Se a operação falhar com erros de SQL, provavelmente o usuário da base de dados utilizado pelo seu wiki (consulte o seu arquivo LocalSettings.php) não possui permissões suficientes.\nConceda a esse usuário permissões adicionais para criar e eliminar tabelas, introduza temporariamente as credenciais do seu superusuário (<i>root</i>) da base de dados em LocalSettings.php, ou use o ''script'' de manutenção <code>setupStore.php</code>, o qual pode utilizar as credenciais de um administrador.",
"smw-admin-dbbutton": "Inicializar ou atualizar tabelas",
"smw-admin-announce": "Anuncie seu wiki",
@@ -365,7 +372,7 @@
"smw_smwadmin_datarefreshbutton": "Programar reconstrução de dados",
"smw_smwadmin_datarefreshstop": "Parar esta atualização",
"smw_smwadmin_datarefreshstopconfirm": "Sim, tenho {{GENDER:$1|certeza}}.",
- "smw-admin-job-scheduler-note": "A maioria das atividades desta seção são executadas como processos de segundo plano para evitar impasses durante a sua execução. O [https://www.mediawiki.org/wiki/Manual:Job_queue executor de processos] é responsável pelo processamento, pelo que é crítico que o script de manutenção <code>runJobs.php</code> (ver também o parâmetro de configuração $<code>wgRunJobsAsync</code>) tenha uma capacidade adequada.",
+ "smw-admin-job-scheduler-note": "Tarefas (aquelas habilitadas) nesta seção são executadas via fila de processos para evitar situações de travamento durante a sua execução. A [https://www.mediawiki.org/wiki/Manual:Job_queue fila de processos] é responsável pelo processamento, assim sendo, é crítico que o script de manutenção <code>runJobs.php</code> tenha uma capacidade adequada (veja também o parâmetro de configuração <code>$wgRunJobsAsync</code>).",
"smw-admin-outdateddisposal-title": "Eliminação de entidades obsoletas",
"smw-admin-outdateddisposal-intro": "Algumas atividades (a alteração de um tipo de propriedade, a remoção de páginas wiki ou a correção de valores em erro) resultam em [https://www.semantic-mediawiki.org/wiki/Outdated_entities entidades desatualizadas] e é recomendado que estas sejam removidas periodicamente para liberar espaço nas tabelas associadas.",
"smw-admin-outdateddisposal-active": "Foi agendado um processo de eliminação de entidades desatualizadas.",
@@ -387,7 +394,7 @@
"smw-admin-questions": "Se tiver mais questões ou sugestões, junte-se à <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">lista de discussão</a> ou a <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">sala de bate-papo</a> dos usuários do Semantic MediaWiki.",
"smw-admin-other-functions": "Outras funções",
"smw-admin-supplementary-section-title": "Funções suplementares",
- "smw-admin-supplementary-section-subtitle": "Funções disponíveis",
+ "smw-admin-supplementary-section-subtitle": "Funções do núcleo",
"smw-admin-supplementary-section-intro": "Esta seção fornece funções adicionais além do escopo de manutenção e é possível que algumas funções listadas na [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions documentação] estejam restritas ou indisponíveis e, portanto, inacessível neste wiki.",
"smw-admin-supplementary-settings-title": "Configurações",
"smw-admin-supplementary-settings-intro": "<u>$1</u> contém uma lista das consigurações disponíveis utilizadas no Semantic MediaWiki",
@@ -402,9 +409,10 @@
"smw-admin-supplementary-operational-statistics-cache-title": "Estatísticas de Cache",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> mostra estatísticas relacionadas com a cache",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
- "smw-admin-supplementary-elastic-intro": "<u>$1</u> informa sobre configurações e estatísticas de índices",
+ "smw-admin-supplementary-elastic-section-subtitle": "Funções Elasticsearch",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> exibe configurações e estatísticas de índices",
"smw-admin-supplementary-elastic-docu": "Esta página contém informações sobre configurações, mapeamentos, situação e estatísticas de índices relacionados ao cluster do Elasticsearch que está conectado ao Semantic MediaWiki e seu [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
- "smw-admin-supplementary-elastic-functions": "Funções disponíveis",
+ "smw-admin-supplementary-elastic-functions": "Funções suportadas",
"smw-admin-supplementary-elastic-settings-title": "Configurações",
"smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> utilizado pelo Elasticsearch para gerenciar os índices do Semantic MediaWiki",
"smw-admin-supplementary-elastic-mappings-title": "Mapeamentos",
@@ -519,9 +527,22 @@
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Visão geral",
"smw-admin-tab-notices": "Avisos de descontinuação",
- "smw-admin-tab-rebuild": "Manutenção",
+ "smw-admin-tab-maintenance": "Manutenção",
"smw-admin-tab-supplement": "Funções suplementares",
"smw-admin-tab-registry": "Registro",
+ "smw-admin-maintenance-no-description": "Sem descrição.",
+ "smw-admin-maintenance-script-section-title": "Lista de scripts de manutenção disponíveis",
+ "smw-admin-maintenance-script-section-intro": "Os scripts de manutenção a seguir requerem um administrador e acesso à linha de comando para poder executar scripts listados.",
+ "smw-admin-maintenance-script-description-dumprdf": "Exportação RDF de triplos existentes.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "Este script é usado para gerenciar as ''caches'' de conceitos do Semantic MediaWiki, sendo ele que pode criar, remover e atualizar ''caches'' selecionadas.",
+ "smw-admin-maintenance-script-description-rebuilddata": "Recria todos os dados semânticos na base de dados, percorrendo todas as páginas que possam ter dados semânticos.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "Reconstrói o índice do Elasticsearch (nas instalações que usam o <code>ElasticStore</code>), percorrendo todas as entidades que possuem dados semânticos.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "Reconstrói o índice de pesquisa de texto completo <code>SQLStore</code> (nas instalações onde a configuração foi ativada).",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "Recria as estatísticas de uso para todas as entidades de propriedade.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "Remove entidades duplicadas encontradas em tabelas selecionadas que não possuem referências ativas.",
+ "smw-admin-maintenance-script-description-setupstore": "Configura o modo de armazenamento selecionado em <code>LocalSettings.php</code>.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "Atualiza o campo <code>smw_sort</code> do <code>SQLStore</code> (de acordo com a configuração [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation $smwgEntityCollation]).",
+ "smw-admin-maintenance-script-description-populatehashfield": "Popula o campo <code>smw_hash</code> das linhas em que este não tem um valor.",
"smw-livepreview-loading": "Carregando...",
"smw-sp-searchbyproperty-description": "Esta página fornece uma simples [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces interface de navegação] para encontrar entidades descritas por uma propriedade e um determinado valor. Outras interfaces de busca disponíveis incluem a página de [[Special:PageProperty|busca por propriedade]] e o [[Special:Ask|construtor de consultas]].",
"smw-sp-searchbyproperty-resultlist-header": "Lista de resultados",
@@ -605,10 +626,10 @@
"smw-types-list": "Lista de tipos de dados",
"smw-types-default": "\"$1\" é um tipo de dado predefinido.",
"smw-types-help": "Mais informações e exemplos podem ser encontrados na [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 página de ajuda].",
- "smw-type-anu": "\"$1\" é uma variante do tipo de dado [[Special:Types/URL|URL]] e é utilizada, na maior parte das vezes, para exportar uma declaração ''owl:AnnotationProperty''.",
+ "smw-type-anu": "\"$1\" é uma variante do tipo de dados [[Special:Types/URL|URL]] e é utilizada, na maior parte das vezes, para exportar uma declaração ''owl:AnnotationProperty''.",
"smw-type-boo": "\"$1\" é um tipo de dado básico para descrever um valor verdadeiro ou falso.",
- "smw-type-cod": "\"$1\" é uma variante do tipo de dado [[Special:Types/Text|Texto]] para ser utilizada com textos técnicos de tamanho arbitrário, tais como listagens de código fonte.",
- "smw-type-geo": "\"$1\" é um tipo de dados que descreve localizações geográficas e requer a [https://www.semantic-mediawiki.org/wiki/Extension:Maps extensão \"Mapas\"].",
+ "smw-type-cod": "\"$1\" é uma variante do tipo de dados [[Special:Types/Text|Texto]] para ser utilizada com textos técnicos de tamanho arbitrário, tais como listagens de código fonte.",
+ "smw-type-geo": "\"$1\" é um tipo de dados que descreve localizações geográficas e requer a extensão [https://www.semantic-mediawiki.org/wiki/Extension:Maps \"Maps\"].",
"smw-type-tel": "\"$1\" é um tipo de dado especial para descrever números internacionais de telefone de acordo com a RFC 3966.",
"smw-type-txt": "\"$1\" é um tipo de dado básico para descrever textos de tamanho arbitrário.",
"smw-type-dat": "\"$1\" é um tipo de dado básico para representar pontos no tempo em um formato unificado.",
@@ -628,7 +649,7 @@
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
"smw-special-pageproperty-description": "Esta página fornece uma interface de navegação para encontrar todos os valores de uma propriedade e uma determinada página. Entre as outras interfaces de pesquisa disponíveis, incluem-se a [[Special:SearchByProperty|pesquisa de propriedades]] e o [[Special:Ask|construtor de consultas ''ask'']].",
"smw-property-predefined-errc": "\"$1\" é uma propriedade predefinida fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] que apresenta os erros que aparecem em relação às marcações impróprias de valores ou de erros de processamento de entrada desses valores.",
- "smw-property-predefined-long-errc": "Os erros são coletados numa [https://www.semantic-mediawiki.org/wiki/Help:Container estrutura recipiente] que pode incluir uma referencia à propriedade que causou a discrepância.",
+ "smw-property-predefined-long-errc": "Os erros são coletados em uma [https://www.semantic-mediawiki.org/wiki/Help:Container estrutura recipiente] que pode incluir uma referência à propriedade que causou a discrepância.",
"smw-property-predefined-errt": "\"$1\" é uma propriedade predefinida que contém uma descrição textual de um erro e é fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-subobject-parser-invalid-naming-scheme": "Um subobjeto definido por um usuário utilizou um esquema de nome inválido. A notação com ponto ($1) nos primeiros cinco caracteres está reservada para o uso exclusivo pelas extensões. Você pode configurar um [https://www.semantic-mediawiki.org/wiki/Help:Adding_subobjects#Named_identifier identificador nomeado].",
"smw-datavalue-record-invalid-property-declaration": "O definição do registro contém a propriedade \"$1\" que está, por sua vez, declarada também como sendo do tipo registro e isso não é permitido.",
@@ -699,7 +720,7 @@
"smw-property-predefined-long-pefu": "Espera-se que o URI contenha um espaço reservado que será ajustado com um valor de [[Special:Types/External identifier|identificador externo]] para formar uma referência de recurso válida.",
"smw-type-eid": "\"$1\" é uma variante do tipo de dados [[Special:Types/Text|Texto]] que requer propriedades atribuídas para declarar um [[Property:External formatter uri|formatador de URI externo]].",
"smw-property-predefined-keyw": "\"$1\" é uma propriedade predefinida e um [[Special:Types/Keyword|tipo]], fornecidas pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico], que normalizam um texto e têm um tamanho restrito de caracteres.",
- "smw-type-keyw": "\"$1\" é uma variante de tipo de dados de [[Special:Types/Text|Texto]] tem um tamanho restrito de caracteres e normaliza a sua representação de conteúdos.",
+ "smw-type-keyw": "\"$1\" é uma variante de tipo de dados [[Special:Types/Text|Texto]] que tem um tamanho restrito de caracteres e que normaliza a sua representação de conteúdo.",
"smw-datavalue-stripmarker-parse-error": "O valor fornecido, \"$1\", contém [https://en.wikipedia.org/wiki/Help:Strip_markers marcadores do analisador sintático] e, portanto, não pode ser suficientemente analisado.",
"smw-datavalue-parse-error": "O valor fornecido \"$1\" não foi compreendido.",
"smw-datavalue-propertylist-invalid-property-key": "A lista de propriedades \"$1\" continha uma chave de propriedade inválida \"$2\".",
@@ -782,10 +803,11 @@
"smw-property-reserved-category": "Categoria",
"smw-category": "Categoria",
"smw-datavalue-uri-invalid-scheme": " \"$1\" não foi listado como um esquema URI válido.",
+ "smw-datavalue-uri-invalid-authority-path-component": "\"$1\" foi identificado para conter uma autoridade ou um componente de caminho \"$2\" inválido.",
"smw-browse-property-group-title": "Grupo de propriedades",
"smw-browse-property-group-label": "Nome do grupo de propriedades",
"smw-browse-property-group-description": "Descrição do grupo de propriedades",
- "smw-property-predefined-ppgr": "\"$1\" é uma propriedade predefinida que identifica as entidades (principalmente as categorias) que são utilizadas como instâncias de agrupamento para as propriedades, e é fornecida pela extensão [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico].",
+ "smw-property-predefined-ppgr": "\"$1\" é uma propriedade predefinida que identifica as entidades (principalmente as categorias) que são utilizadas como instâncias de agrupamento para as propriedades, e é fornecida pela extensão [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-filter": "Filtro",
"smw-section-expand": "Expandir a seção",
"smw-section-collapse": "Reduzir a seção",
@@ -834,5 +856,8 @@
"smw-ask-tab-result": "Resultado",
"smw-ask-tab-extra": "Extra",
"smw-ask-tab-debug": "Depurar",
- "smw-ask-tab-code": "Código"
+ "smw-ask-tab-code": "Código",
+ "smw-install-incomplete-intro": "A instalação (ou atualização) de <b>Semantic MediaWiki</b> não foi finalizado e um administrador deve executar as seguintes tarefas para evitar inconsistências de dados antes que os usuários continuem a criar ou alterar o conteúdo.",
+ "smw-install-incomplete-populate-hash-field": "O passo de preenchimento do campo <code>smw_hash</code> foi pulado durante a configuração; é necessário executar o ''script'' [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php].",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/pt.json b/www/wiki/extensions/SemanticMediaWiki/i18n/pt.json
index 9f6e6eda..35774a3e 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/pt.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/pt.json
@@ -22,11 +22,17 @@
"Nemo bis",
"MokaAkashiyaPT",
"Eduardo Addad de Oliveira",
- "Athena in Wonderland"
+ "Athena in Wonderland",
+ "Mansil alfalb"
]
},
"smw-desc": "Tornar a sua wiki mais inteligível - para máquinas ''e'' seres humanos ([https://www.semantic-mediawiki.org/wiki/Help:User_manual documentação ''online''])",
"smw-title": "MediaWiki Semântico",
+ "smw-upgrade-error": "O MediaWiki Semântico foi instalado e ativado, mas tem em falta uma [https://www.semantic-mediawiki.org/wiki/Help:Upgrade chave de atualização] apropriada que corresponda a: <code>$1</code>.",
+ "smw-upgrade-error-why-title": "Porque estou a ver este erro?",
+ "smw-upgrade-error-why-explain": "A estrutura interna da base de dados do MediaWiki Semântico mudou e necessita de alguns ajustamentos para ficar completamente funcional. Pode haver vários motivos para a mudança, incluindo: \n* Foram adicionadas propriedades fixas (requer configuração adicional de tabelas).\n* Uma atualização contém algumas mudanças nas tabelas ou índices, tornando obrigatória uma interceção antes de se aceder aos dados.",
+ "smw-upgrade-error-how-title": "Como corrijo este erro?",
+ "smw-upgrade-error-how-explain": "Um administrador (ou outra pessoa com privilégios de administrador) tem de executar o ficheiro de comandos de manutenção [https://www.mediawiki.org/wiki/Manual:Update.php update.php] do MediaWiki ou o [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] do MediaWiki Semântico. Para obter mais ajuda, pode também consultar as seguintes páginas:\n* Instruções de [https://www.semantic-mediawiki.org/wiki/Help:Installation instalação].\n* Página de ajuda sobre [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting resolução de problemas].",
"smw-semantics-not-enabled": "A funcionalidade MediaWiki Semântico não foi ativada nesta wiki.",
"smw_viewasrdf": "Feed RDF",
"smw_finallistconjunct": "e",
@@ -121,6 +127,7 @@
"smw-paramdesc-feeddescription": "O texto a ser usado como descrição do ''feed''",
"smw-paramdesc-feedpagecontent": "O conteúdo da página a ser apresentado com o ''feed''",
"smw-label-feed-description": "''Feed'' $2 $1",
+ "smw-paramdesc-mimetype": "O tipo de multimédia (tipo MIME) para o ficheiro de saída.",
"smw_iq_disabled": "As consultas semânticas foram impossibilitadas nesta wiki.",
"smw_iq_moreresults": "… mais resultados",
"smw_parseerror": "O valor fornecido não foi compreendido.",
@@ -132,7 +139,9 @@
"smw_manytypes": "Foi definido mais de um tipo para a propriedade.",
"smw_emptystring": "Não são aceites textos vazios.",
"smw_notinenum": "\"$1\" não está na lista ($2) dos [[Property:Allows value|valores permitidos]] para a propriedade \"$3\".",
- "smw_noboolean": "“$1” não é reconhecido como um valor booliano (verdadeiro/falso).",
+ "smw-datavalue-constraint-error-allows-value-list": "\"$1\" não está na lista ($2) de [[Property:Allows value|valores permitidos]] para a propriedade \"$3\".",
+ "smw-datavalue-constraint-error-allows-value-range": "\"$1\" não está no intervalo de \"$2\" especificado pela restrição [[Property:Allows value|permite valor]] para a propriedade \"$3\".",
+ "smw_noboolean": "\"$1\" não é reconhecido como um valor booliano (verdadeiro/falso).",
"smw_true_words": "verdadeiro,v,sim,s",
"smw_false_words": "falso,f,não,nao,n",
"smw_nofloat": "“$1” não é um número.",
@@ -208,7 +217,7 @@
"smw-purge-failed": "A atualização falhou",
"types": "Tipos",
"smw_types_docu": "Lista dos [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes tipos de dados disponíveis] em que cada [https://www.semantic-mediawiki.org/wiki/Help:Datatype tipo] representa um conjunto único de atributos, para descrever um valor em termos das características de armazenamento e apresentação que são hereditárias para uma propriedade atribuída.",
- "smw-special-types-no-such-type": "O tipo de dados especificado não existe",
+ "smw-special-types-no-such-type": "\"$1\" é desconhecido ou não foi especificado como tipo de dados válido.",
"smw-statistics": "Estatísticas de semântica",
"smw-statistics-property-instance": "{{PLURAL:$1|Valor|valores}} de propriedade (total)",
"smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|Propriedade|Propriedades}}]] (total)",
@@ -329,9 +338,9 @@
"smw_smwadmin_updatenotstopped": "Para parar o processo de atualização em curso, deve marcar a caixa de seleção para indicar que tem realmente a certeza.",
"smw-admin-docu": "Esta página especial auxilia-o durante a instalação, atualização, manutenção e utilização do <a href=\"https://www.semantic-mediawiki.org\">MediaWiki Semântico</a> e fornece outras funções e tarefas administrativas, assim como estatísticas.\nLembre-se de efetuar cópias de segurança dos dados importantes antes de executar funções administrativas.",
"smw-admin-environment": "Ambiente de ''software''",
- "smw-admin-db": "Manutenção da base de dados",
+ "smw-admin-db": "Configuração da base de dados",
"smw-admin-db-preparation": "A inicialização da tabela está em curso e pode demorar algum tempo até os resultados serem apresentados, dependendo do tamanho da tabela e de possíveis otimizações da mesma.",
- "smw-admin-dbdocu": "O MediaWiki Semântico requer algumas alterações da base de dados do MediaWiki, de forma a armazenar os dados semânticos.\nA função abaixo assegura que a sua base de dados está devidamente preparada.\nAs alterações feitas neste passo não afetam o resto da base de dados do MediaWiki, e podem ser facilmente desfeitas se desejado.\nEsta função de preparação pode ser executada várias vezes sem causar quaisquer danos, mas é necessária apenas uma vez na instalação ou atualização.",
+ "smw-admin-dbdocu": "O MediaWiki Semântico requer uma estrutura própria de dados (que é independente do MediaWiki e, portanto, não afeta o resto da instalação do MediaWiki), para armazenar os dados semânticos.\nEsta função de preparação pode ser executada várias vezes sem causar quaisquer danos, mas é necessária apenas uma vez, na instalação ou durante uma atualização.",
"smw-admin-permissionswarn": "Se a operação falhar com erros de SQL, é provável que o utilizador da base de dados usado pela sua wiki (consulte o seu ficheiro \"LocalSettings.php\") não tenha as permissões necessárias.\nConceda a este utilizador permissões adicionais para criar e eliminar tabelas, introduza temporariamente as credenciais do seu super-utilizador (''root'') da base de dados no ficheiro \"LocalSettings.php\", ou use o ''script'' de manutenção <code>setupStore.php</code>, o qual pode usar as credenciais de um administrador.",
"smw-admin-dbbutton": "Inicializar ou atualizar tabelas",
"smw-admin-announce": "Anuncie a sua wiki",
@@ -358,7 +367,7 @@
"smw_smwadmin_datarefreshbutton": "Programar a reconstrução dos dados",
"smw_smwadmin_datarefreshstop": "Parar esta atualização",
"smw_smwadmin_datarefreshstopconfirm": "Sim, {{GENDER:$1|tenho}} a certeza.",
- "smw-admin-job-scheduler-note": "A maioria das atividades desta secção são executadas como processos de segundo plano para evitar situações de impasse durante a sua execução. O [https://www.mediawiki.org/wiki/Manual:Job_queue executor de processos] é responsável pelo processamento, pelo que é crítico que o script de manutenção <code>runJobs.php</code> (ver também o parâmetro de configuração $<code>wgRunJobsAsync</code>) tenha uma capacidade adequada.",
+ "smw-admin-job-scheduler-note": "As atividades (ativas) desta secção são executadas através da fila de tarefas para evitar situações de impasse durante a sua execução. A [https://www.mediawiki.org/wiki/Manual:Job_queue fila de tarefas] é responsável pelo processamento, pelo que é crítico que o ''script'' de manutenção <code>runJobs.php</code> tenha uma capacidade adequada (ver também o parâmetro de configuração $<code>wgRunJobsAsync</code>).",
"smw-admin-outdateddisposal-title": "Eliminação de entidades desatualizadas",
"smw-admin-outdateddisposal-intro": "Algumas atividades (a alteração de um tipo de propriedade, a remoção de páginas da wiki, ou a correção de valores em erro) resultam em [https://www.semantic-mediawiki.org/wiki/Outdated_entities entidades desatualizadas] e é recomendado que estas sejam removidas periodicamente para libertar o respetivo espaço nas tabelas.",
"smw-admin-outdateddisposal-active": "Foi agendado um processo de eliminação de entidades desatualizadas.",
@@ -380,7 +389,7 @@
"smw-admin-questions": "Se tem mais questões ou sugestões, junte-se à discussão na <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">lista de divulgação</a> do MediaWiki Semântico ou na <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">sala de conversação</a>.",
"smw-admin-other-functions": "Outras funções",
"smw-admin-supplementary-section-title": "Funções suplementares",
- "smw-admin-supplementary-section-subtitle": "Funções disponíveis",
+ "smw-admin-supplementary-section-subtitle": "Funções centrais",
"smw-admin-supplementary-section-intro": "Esta secção disponibiliza funções adicionais fora do âmbito da manutenção e é possível que algumas das funções listadas na [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions documentação] estejam restringidas ou indisponíveis e, portanto, inacessíveis nesta wiki.",
"smw-admin-supplementary-settings-title": "Definições de configuração",
"smw-admin-supplementary-settings-intro": "<u>$1</u> contém uma lista das definições disponíveis que são usadas no MediaWiki Semântico",
@@ -395,9 +404,10 @@
"smw-admin-supplementary-operational-statistics-cache-title": "Estatísticas da cache",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> mostra estatísticas relacionadas com a cache",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
- "smw-admin-supplementary-elastic-intro": "<u>$1</u> dá informação sobre configurações e estatísticas de indexação",
- "smw-admin-supplementary-elastic-docu": "Esta página contém informação sobre as configurações, os mapeamentos, o estado e as estatísticas dos índices, de um cluster Elasticsearch que está ligado ao MediaWiki Semântico e à respetiva [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
- "smw-admin-supplementary-elastic-functions": "Funções disponíveis",
+ "smw-admin-supplementary-elastic-section-subtitle": "Funções Elasticsearch",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> mostra configurações e estatísticas de indexação",
+ "smw-admin-supplementary-elastic-docu": "Esta página contém informação sobre as configurações, os mapeamentos, o estado e as estatísticas dos índices, de um ''cluster'' Elasticsearch que está ligado ao MediaWiki Semântico e ao respetivo [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
+ "smw-admin-supplementary-elastic-functions": "Funções suportadas",
"smw-admin-supplementary-elastic-settings-title": "Configurações",
"smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> usadas pelo Elasticsearch para gerir os índices do MediaWiki Semântico",
"smw-admin-supplementary-elastic-mappings-title": "Mapeamentos",
@@ -489,7 +499,7 @@
"action-smw-ruleedit": "editar páginas de regras (MediaWiki Semântico)",
"smw-property-predefined-default": "\"$1\" é uma propriedade predefinida.",
"smw-property-predefined-common": "Esta propriedade é predefinida (também chamada [https://www.semantic-mediawiki.org/wiki/Help:Special_properties propriedade especial]) e vem com privilégios de administração adicionais, mas pode ser usada como qualquer outra [https://www.semantic-mediawiki.org/wiki/Property propriedade definida pelo utilizador].",
- "smw-property-predefined-ask": "\"$1\" é uma propriedade predefinida que representa meta informação (na forma de [https://www.semantic-mediawiki.org/wiki/Subobject subobjeto]) acerca de consultas individuais, fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico].",
+ "smw-property-predefined-ask": "\"$1\" é uma propriedade predefinida que representa metainformação (na forma de [https://www.semantic-mediawiki.org/wiki/Subobject subobjeto]) acerca de consultas individuais, fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico].",
"smw-property-predefined-asksi": "\"$1\" é uma propriedade predefinida que recolhe o número de condições usadas numa consulta, fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico].",
"smw-property-predefined-askde": "\"$1\" é uma propriedade predefinida que fornece informação sobre a profundidade de uma consulta, fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico].",
"smw-property-predefined-long-askde": "É um valor numérico calculado com base nas consultas intercaladas, nas cadeias de propriedades e nos elementos descritivos disponíveis, sendo que a execução de cada consulta está restringida pelo parâmetro de configuração <code>[https://www.semantic-mediawiki.org/wiki/Help:$smwgQMaxDepth $smwgQMaxDepth]</code>.",
@@ -512,9 +522,22 @@
"smw-admin-objectid": "Identificador:",
"smw-admin-tab-general": "Visão geral",
"smw-admin-tab-notices": "Avisos de descontinuação",
- "smw-admin-tab-rebuild": "Manutenção",
+ "smw-admin-tab-maintenance": "Manutenção",
"smw-admin-tab-supplement": "Funções suplementares",
"smw-admin-tab-registry": "Registo",
+ "smw-admin-maintenance-no-description": "Sem descrição.",
+ "smw-admin-maintenance-script-section-title": "Lista dos ''scripts'' de manutenção disponíveis",
+ "smw-admin-maintenance-script-section-intro": "Os seguintes ''scripts'' de manutenção requerem um administrador e acesso à linha de comandos para poder executar os ''scripts'' listados.",
+ "smw-admin-maintenance-script-description-dumprdf": "Exportação para RDF das triplas existentes.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "Este ''script'' é usado para gerir as ''caches'' de conceitos do MediaWiki Semântico, sendo que pode criar, remover e atualizar ''caches'' selecionadas.",
+ "smw-admin-maintenance-script-description-rebuilddata": "Recria todos os dados semânticos na base de dados, percorrendo todas as páginas que possam ter dados semânticos.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "Reconstrói o índice Elasticsearch (nas instalações que usam o <code>ElasticStore</code>), percorrendo todas as entidades que têm dados semânticos.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "Reconstrói o índice de pesquisa de texto completo <code>SQLStore</code> (nas instalações onde a configuração foi ativada).",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "Reconstrói as estatísticas de utilização de todas as entidades propriedade.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "Remove as entidades duplicadas encontradas em tabelas selecionadas que não tenham referências ativas.",
+ "smw-admin-maintenance-script-description-setupstore": "Configura o servidor de armazenamento selecionado em <code>LocalSettings.php</code>.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "Atualiza o campo <code>smw_sort</code> do <code>SQLStore</code> (de acordo com a configuração [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation $smwgEntityCollation]).",
+ "smw-admin-maintenance-script-description-populatehashfield": "Popula o campo <code>smw_hash</code> das linhas em que este não tem um valor.",
"smw-livepreview-loading": "A carregar…",
"smw-sp-searchbyproperty-description": "Esta página fornece uma [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces interface de navegação] simples para encontrar entidades descritas por uma propriedade e pelo nome de um valor. Entre as outras interfaces de pesquisa disponíveis, incluem-se a [[Special:PageProperty|página de pesquisa de propriedades]] e o [[Special:Ask|construtor de consultas ''ask'']].",
"smw-sp-searchbyproperty-resultlist-header": "Lista de resultados",
@@ -594,16 +617,30 @@
"smw-datavalue-restricted-use": "O valor de dados \"$1\" foi marcado para uso restrito.",
"smw-datavalue-invalid-number": "\"$1\" não pode ser interpretado como um número.",
"smw-query-condition-circular": "Foi detetada uma possível condição circular em \"$1\".",
+ "smw-query-condition-empty": "A descrição da consulta tem uma condição vazia.",
"smw-types-list": "Lista de tipos de dados",
"smw-types-default": "\"$1\" é um tipo de dados interno.",
- "smw-types-help": "Mais informações e exemplos podem ser encontrados na [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 página de ajuda].",
+ "smw-types-help": "Mais informações e exemplos podem ser encontrados nesta [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 página de ajuda].",
"smw-type-anu": "\"$1\" é uma variante do tipo de dados [[Special:Types/URL|URL]], usada sobretudo para uma declaração de exportação ''owl:AnnotationProperty''.",
- "smw-type-boo": "\"$1\" é um tipo de dados primitivo para descrever um valor verdadeiro ou falso.",
+ "smw-type-boo": "\"$1\" é um tipo de dados básico para descrever um valor verdadeiro ou falso.",
"smw-type-cod": "\"$1\" é uma variante do tipo de dados [[Special:Types/Text|Texto]], usado para textos técnicos de comprimento arbitrário, como listagens de código fonte.",
- "smw-type-geo": "\"$1\" é um tipo de dados que descreve localizações geográficas e requer a [https://www.semantic-mediawiki.org/wiki/Extension:Maps extensão \"Mapas\"].",
+ "smw-type-geo": "\"$1\" é um tipo de dados que descreve localizações geográficas e requer a extensão [https://www.semantic-mediawiki.org/wiki/Extension:Maps \"Mapas\"].",
"smw-type-tel": "\"$1\" é um tipo de dados especial para descrever números telefónicos internacionais segundo o RFC 3966.",
- "smw-type-txt": "\"$1\" é um tipo de dados primitivo para descrever textos (''strings'') de comprimento arbitrário.",
- "smw-type-dat": "\"$1\" é um tipo de dados para representar pontos no tempo num formato unificado.",
+ "smw-type-txt": "\"$1\" é um tipo de dados básico para descrever textos (''strings'') de comprimento arbitrário.",
+ "smw-type-dat": "\"$1\" é um tipo de dados básico para representar pontos no tempo num formato unificado.",
+ "smw-type-ema": "\"$1\" é um tipo de dados especial para representar um correio eletrónico.",
+ "smw-type-tem": "\"$1\" é um tipo de dados numérico especial para representar uma temperatura.",
+ "smw-type-qty": "\"$1\" é um tipo de dados para descrever quantidades com uma representação numérica e uma unidade de medida.",
+ "smw-type-rec": "\"$1\" é um tipo de dados recipiente que especifica uma lista de propriedades com tipos, numa ordem fixa.",
+ "smw-type-extra-tem": "O esquema de conversão inclui as unidades suportadas, como Kelvin, Celsius, Fahrenheit e Rankine.",
+ "smw-type-tab-properties": "Propriedades",
+ "smw-type-tab-types": "Tipos",
+ "smw-type-tab-errors": "Erros",
+ "smw-type-primitive": "Básico",
+ "smw-type-contextual": "Contextual",
+ "smw-type-compound": "Composto",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
"smw-special-pageproperty-description": "Esta página fornece uma interface de navegação para encontrar todos os valores de uma propriedade e uma determinada página. Entre as outras interfaces de pesquisa disponíveis, incluem-se a [[Special:SearchByProperty|pesquisa de propriedades]] e o [[Special:Ask|construtor de consultas ''ask'']].",
"smw-property-predefined-errc": "\"$1\" é uma propriedade predefinida, fornecida pelo [https://www.semantic-mediawiki.org/wiki/Help:Special_properties MediaWiki Semântico], e representa erros relacionados com anotações de valor incorretas ou com o processamento de entradas.",
@@ -712,6 +749,7 @@
"smw-category-change-propagation-locked-error": "A categoria \"$1\" foi alterada e requer que as entidades atribuídas sejam reavaliadas usando um processo de [https://www.semantic-mediawiki.org/wiki/Change_propagation propagação de alterações]. Entretanto, a página da categoria foi trancada até que a atualização da especificação primária esteja finalizada para impedir interrupções intermédias ou especificações contraditórias. O processo pode demorar algum tempo até destrancar a página porque depende do tamanho e da frequência da gestão da [https://www.mediawiki.org/wiki/Manual:Job_queue fila de tarefas].",
"smw-category-change-propagation-locked-warning": "A categoria \"$1\" foi alterada e requer que as entidades atribuídas sejam reavaliadas usando um processo de [https://www.semantic-mediawiki.org/wiki/Change_propagation propagação de alterações]. A atualização pode demorar algum tempo porque depende do tamanho e frequência da [https://www.mediawiki.org/wiki/Manual:Job_queue fila de tarefas] e é sugerido que adie alterações à categoria para impedir interrupções intermédias ou especificações contraditórias.",
"smw-category-change-propagation-pending": "Estão pendentes atualizações devidas à [https://www.semantic-mediawiki.org/wiki/Change_propagation propagação de alterações] ($1 [https://www.mediawiki.org/wiki/Manual:Job_queue {{PLURAL:$1|tarefa estimada|tarefas estimadas}}]) e é recomendado que aguarde até que o processo esteja finalizado antes de fazer alterações à categoria, para impedir interrupções intermédias ou especificações contraditórias.",
+ "smw-category-invalid-value-assignment": "\"$1\" não é reconhecido como categoria válida ou anotação de valor.",
"protect-level-smw-pageedit": "Permitir só utilizadores com permissão de edição de páginas (MediaWiki Semântico)",
"smw-create-protection": "A criação da propriedade \"$1\" está restrita a utilizadores com o direito \"$2\" ou um [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups grupo de utilizadores] apropriado enquanto o [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode modo de autoridade] está ativado.",
"smw-create-protection-exists": "A alteração da propriedade \"$1\" está restrita a utilizadores com o direito \"$2\" ou um [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups grupo de utilizadores] apropriado enquanto o [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode modo de autoridade] está ativado.",
@@ -745,7 +783,7 @@
"smw-category-invalid-redirect-target": "A categoria \"$1\" contém um destino inválido de redirecionamento para um espaço nominal que não é de categorias.",
"smw-parser-function-expensive-execution-limit": "A função do analisador sintático atingiu o limite para execuções de funções exigentes (consulte o parâmetro de configuração [https://www.semantic-mediawiki.org/wiki/Help:$smwgQExpensiveExecutionLimit <code>$smwgQExpensiveExecutionLimit</code>]).",
"smw-postproc-queryref": "O MediaWiki Semântico está a recarregar a página atual devido à necessidade de algum processamento após a consulta.",
- "apihelp-smwinfo-summary": "Módulo da API para obter informação sobre estatísticas e outra meta informação do MediaWiki Semântico.",
+ "apihelp-smwinfo-summary": "Módulo da API para obter informação sobre estatísticas e outra metainformação do MediaWiki Semântico.",
"apihelp-ask-summary": "Módulo da API para consultar o MediaWiki Semântico usando a linguagem \"ask\".",
"apihelp-askargs-summary": "Módulo da API para consultar o MediaWiki Semântico usando a linguagem \"ask\" na forma de lista de condições, propriedades a mostrar e parâmetros.",
"apihelp-browsebyproperty-summary": "Módulo da API para obter informação sobre uma propriedade ou lista de propriedades.",
@@ -770,7 +808,7 @@
"smw-ask-format-help-link": "Formato [https://www.semantic-mediawiki.org/wiki/Help:$1_format $1]",
"smw-help": "Ajuda",
"smw-cheat-sheet": "Auxiliar",
- "smw-personal-jobqueue-watchlist": "Lista de vigilância da fila de tarefas",
+ "smw-personal-jobqueue-watchlist": "Lista de vigilância (fila de tarefas)",
"smw-property-predefined-label-skey": "Chave de ordenação",
"smw-processing": "A processar...",
"smw-redirect-target-unresolvable": "O destino é irresolúvel pela razão \"$1\"",
@@ -812,5 +850,8 @@
"smw-ask-tab-result": "Resultado",
"smw-ask-tab-extra": "Extra",
"smw-ask-tab-debug": "Despistagem de defeitos",
- "smw-ask-tab-code": "Código"
+ "smw-ask-tab-code": "Código",
+ "smw-install-incomplete-intro": "A instalação (ou atualização) do <b>MediaWiki Semântico</b> não foi finalizada e um administrador deve executar as seguintes tarefas para evitar inconsistências de dados antes que os utilizadores continuem a criar ou alterar conteúdos.",
+ "smw-install-incomplete-populate-hash-field": "O preenchimento do campo <code>smw_hash</code> foi saltado durante a configuração; é necessário executar o ''script'' [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php].",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/qqq.json b/www/wiki/extensions/SemanticMediaWiki/i18n/qqq.json
index a62d6a79..79fe615e 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/qqq.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/qqq.json
@@ -21,6 +21,11 @@
},
"smw-desc": "{{desc|name=Semantic MediaWiki|url=https://www.mediawiki.org/wiki/Extension:Semantic_MediaWiki}}",
"smw-title": "{{notranslate}}\n\nName of the extension as it should be displayed.\n\n{{Identical|Semantic MediaWiki}}",
+ "smw-upgrade-error": "This is an error message.\n\nParameter:\n* $1 - holds the upgrade key",
+ "smw-upgrade-error-why-title": "This is a section header.",
+ "smw-upgrade-error-why-explain": "This is an error message.",
+ "smw-upgrade-error-how-title": "This is a section header.",
+ "smw-upgrade-error-how-explain": "This is an error message.",
"smw-semantics-not-enabled": "This is an informatory message.",
"smw_viewasrdf": "This is the text of the link that is triggering the results export when clicked. It appears on pages in namespace Concept: or within the [https://semantic-mediawiki.org/wiki/Help:Browsing_interfaces#The_factbox factbox].",
"smw_finallistconjunct": "The last separator in a list. For example a list could look like this: \"A, B, and C\". The comma might not be appropriate in your language.\n\t{{Identical|And}}",
@@ -119,6 +124,7 @@
"smw-paramdesc-feedpagecontent": "This option allows to enable page content to be generated with the feed",
"smw-label-feed-link": "This is the text of the link that is triggering the results export to a RSS-file when clicked. {{optional}}",
"smw-label-feed-description": "This message is displayed as the feed description, e.g. \"News on translatewiki.net rss feed\".\n\nParameters:\n* $1 - a feed description, e.g. \"News on translatewiki.net\"\n* $2 - a feed type. either \"rss\" or \"atom\"\n{{Identical|Feed}}",
+ "smw-paramdesc-mimetype": "This is the description of the \"mimetype\" parameter of the \"templatefile\" [https://www.semantic-mediawiki.org/wiki/Help:Result_formats result format] for [https://www.semantic-mediawiki.org/wiki/Help:Inline_queries inline queries].",
"smw_iq_disabled": "This is an information message.",
"smw_iq_moreresults": "This is the text of the link that points to further results in case the [https://semantic-mediawiki.org/wiki/Help:Inline_queries inline query] has more than currently displayed on the page. See also message {{msg-mw|Smw-paramdesc-searchlabel}}.",
"smw_parseerror": "This is an error/warning message.",
@@ -399,6 +405,7 @@
"smw-admin-supplementary-operational-statistics-cache-title": "This is the label of a link on special page \"SemanticMediaWiki\".",
"smw-admin-supplementary-operational-statistics-cache-intro": "This is an item shown on special page \"Semantic MediaWiki\"\n\nParameters:\n* Holds a link to a subpage. The lable of the link is defined with {{Msg-mw|Smw-admin-supplementary-operational-statistics-cache-title}}",
"smw-admin-supplementary-elastic-title": "This is the label of a link on special page \"SemanticMediaWiki\".",
+ "smw-admin-supplementary-elastic-section-subtitle": "This is a section header on special page \"Semantic MediaWiki\".",
"smw-admin-supplementary-elastic-intro": "This is an informatory message that describes the link accessible via $1.\n\nParameters:\n* $1 - holds the name specified in {{Msg-mw|Smw-admin-supplementary-elastic-title}}",
"smw-admin-supplementary-elastic-docu": "This is an informatory message describing a section on special page \"SemanticMediawiki\"",
"smw-admin-supplementary-elastic-functions": "This is a section header on special page \"SemanticMediaWiki\".",
@@ -516,9 +523,22 @@
"smw-admin-objectid": "A label\n{{Identical|ID}}",
"smw-admin-tab-general": "This is the label of a tab.\n{{Identical|Overview}}",
"smw-admin-tab-notices": "This is the label of a tab.",
- "smw-admin-tab-rebuild": "This is the label of a tab.",
+ "smw-admin-tab-maintenance": "This is the label of a tab on special page \"Semantic MediaWiki\".",
"smw-admin-tab-supplement": "This is the label of a tab.",
"smw-admin-tab-registry": "This is the label of a tab.\n\n{{Identical|Registry}}",
+ "smw-admin-maintenance-no-description": "This is an informatory message.",
+ "smw-admin-maintenance-script-section-title": "This is a section header on special page \"SemanticMediaWiki\".",
+ "smw-admin-maintenance-script-section-intro": "This is an informatory text on special page \"SemanticMediaWiki\".",
+ "smw-admin-maintenance-script-description-dumprdf": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-rebuilddata": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-setupstore": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "This is the short description of a maintenance script.",
+ "smw-admin-maintenance-script-description-populatehashfield": "This is the short description of a maintenance script.",
"smw-livepreview-loading": "{{Identical|Loading}}Message displayed while data is loading.",
"smw-sp-searchbyproperty-description": "Extended description text for the [[Special:SearchByProperty]] page.",
"smw-sp-searchbyproperty-resultlist-header": "A header label",
@@ -643,6 +663,7 @@
"smw-property-predefined-askco": "This informatory message describes the [https://www.semantic-mediawiki.org/wiki/Help:Special_properties special property] holding the [https://www.semantic-mediawiki.org/wiki/Help:Special_property_Query_status_code status code] of a query.\n\nParameter:\n\n* $1 - name of predefined property",
"smw-property-predefined-long-askco": "This informatory message describes the [https://semantic-mediawiki.org/wiki/Help:Special_properties special property] on the property's page. Translate \"internal codified\" in a sense of \"internally used representation of a state\" the query is in.",
"smw-property-predefined-prec": "This informatory message describes the [https://semantic-mediawiki.org/wiki/Help:Special_properties special property].\n\n* $1 holds the name of the special property.",
+ "smw-property-predefined-attch-link": "This informatory message describes a [https://www.semantic-mediawiki.org/wiki/Help:Special_properties special property].\n\nParameter:\n* $1 holds the name of the special property.",
"smw-types-extra-geo-not-available": "This is an informatory message shown to the user.\n\n* $1 holds the name of the property.",
"smw-datavalue-monolingual-dataitem-missing": "This is an error message shown to the user.",
"smw-datavalue-monolingual-lcode-parenthesis": "{{optional}}",
@@ -785,6 +806,7 @@
"smw-property-reserved-category": "This is the name of a reserved property name.\n\n{{Identical|Category}}",
"smw-category": "This is a label. singular only.\n\n{{Identical|Category}}",
"smw-datavalue-uri-invalid-scheme": "This is an error message.\n\nParameter:\n* $1 - holds the identifier of an Uniform Resource Identifier (URI) schema",
+ "smw-datavalue-uri-invalid-authority-path-component": "This is an error message. Translate authority in a sense of \"responsible for/responsibility\".\n\nParameters:\n* $1 - holds a broken URI\n* $2 - holds the transgressing part of the broken URI",
"smw-browse-property-group-title": "This is the name of a header on special page \"Browse\".",
"smw-browse-property-group-label": "This is the label of an entity similar to special property which is shown er on special page \"Browse\".",
"smw-browse-property-group-description": "This is the label of an entity similar to special property which is shown er on special page \"Browse\".",
@@ -838,5 +860,8 @@
"smw-ask-tab-extra": "This is the label of a tab on special page \"Ask\".",
"smw-ask-tab-debug": "This is the label of a tab on special page \"Ask\".",
"smw-ask-tab-code": "This is the label of a tab on special page \"Ask\".",
- "smw-helplink-concepts": "This message links to the respective help page on <semantic-mediawiki.org>.\n\n{{Optional}}"
+ "smw-helplink-concepts": "This message links to the respective help page on <semantic-mediawiki.org>.\n\n{{Optional}}",
+ "smw-install-incomplete-intro": "This is an error message.",
+ "smw-install-incomplete-populate-hash-field": "This is an error/informatory message.",
+ "smw-helplink": "This is the URL formatter for an link to the homepage to Semantic MediaWiki.\n{{Optional}} \n\nor\n\n{{Notranslate}}"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/ru.json b/www/wiki/extensions/SemanticMediaWiki/i18n/ru.json
index 0f21a23b..ee64c81d 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/ru.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/ru.json
@@ -50,7 +50,9 @@
"Drbug",
"Батыр Комдошев",
"Infovarius",
- "Soul Train"
+ "Soul Train",
+ "Alex Mashin",
+ "Nk88"
]
},
"smw-desc": "Делает вашу вики более доступной — для машин ''и'' людей ([https://www.semantic-mediawiki.org/wiki/Help:User_manual документация в сети])",
@@ -72,7 +74,7 @@
"smw_multiple_concepts": "Страница представления может содержать только одно определение представления.",
"smw_concept_cache_miss": "Концепт «$1» в настоящий момент не может быть использовано, так как настройка вики-сайта требует, чтобы его результат определялся в фоновом режиме. Если данное сообщение не исчезнет через некоторое время, обратитесь к администратору вики-сайта для включения данного концепта.",
"smw_noinvannot": "Обратным свойствам не могут быть присвоены значения.",
- "version-semantic": "Семантические расширения (Semantic MediaWiki)",
+ "version-semantic": "Семантические расширения",
"smw_baduri": "Извините, но ссылки из диапазона \"$1\" не доступны отсюда.",
"smw_csv_link": "CSV",
"smw_dsv_link": "DSV",
@@ -183,7 +185,7 @@
"smw_noqueryfeature": "Часть запроса была опущена, так как некоторые из возможностей языка запросов не поддерживаются на этом вики-сайте ($1).",
"smw_noconjunctions": "Часть запроса была опущена, так как операция «Логическое И» не поддерживается на этом вики-сайте ($1).",
"smw_nodisjunctions": "Ошибка: Дизъюнкции (логическое ИЛИ) не поддерживаются данным сайтом, поэтому использующая их часть запроса была проигнорирована ($1).",
- "smw_querytoolarge": "{{PLURAL:$2|1=Указанное условие|$2 указанных условий|$2 указанных условия}} запроса не могут быть выполнены из-за ограничения на глубину или размер запроса: <code>$1</code>.",
+ "smw_querytoolarge": "{{PLURAL:$2|1=Указанное условие|$2 указанных условия|$2 указанных условий}} запроса не могут быть выполнены из-за ограничения на глубину или размер запроса: <code>$1</code>.",
"smw_notemplategiven": "Чтобы данный запрос выполнялся, необходимо задать значение для параметра «template».",
"smw_db_sparqlqueryproblem": "Не удалось получить результат запроса к базе данных SPARQL. Эта может быть временная ошибка или проблема в программном обеспечении базы данных.",
"smw_db_sparqlqueryincomplete": "Поиск ответа на запрос оказался слишком сложным и был прерван. Некоторые результаты могут быть не показаны. По возможности попробуйте упростить запрос.",
@@ -224,8 +226,8 @@
"concepts": "Концепты",
"smw-special-concept-docu": "[https://www.semantic-mediawiki.org/wiki/Help:Концепты Концепт] можно рассматривать как «динамическую категорию», т.е. как совокупность страниц, которая не создана вручную, а собрана Семантической Медиавики из описания данного запроса.",
"smw-special-concept-header": "Список концептов",
- "smw-special-concept-count": "В списке {{PLURAL:$1|1=числится следующий|числятся следующие}} {{PLURAL:$1|$1 концепт|$1 концептов|$1 концепта|1=концепт}}",
- "smw-special-concept-empty": "Концепты не найдены.",
+ "smw-special-concept-count": "В списке {{PLURAL:$1|1=числится следующий|числятся следующие}} {{PLURAL:$1|$1 концепция|$1 концепции|$1 концепций|1=концепция}}",
+ "smw-special-concept-empty": "Концепции не найдены.",
"unusedproperties": "Неиспользуемые свойства",
"smw-unusedproperties-docu": "На этой странице перечислены [https://www.semantic-mediawiki.org/wiki/Wanted_properties неиспользуемые свойства], которые определены, но при этом ни одна страница не использует их. См. также:[[Special:Properties|используемые]] и [[Special:WantedProperties|требуемые свойства]].",
"smw-unusedproperty-template": "$1 имеет тип $2",
@@ -240,22 +242,22 @@
"smw_types_docu": "Список [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes доступных типов данных], в котором каждый [https://www.semantic-mediawiki.org/wiki/Help:Datatype тип данных] представляет собой уникальный набор атрибутов для описания значения с точки зрения хранения и отображения характеристик, которые можно задавать для свойств.",
"smw-special-types-no-such-type": "\"$1\" неизвестен или не был указан как действительный тип данных.",
"smw-statistics": "Семантическая статистика",
- "smw-statistics-property-instance": "{{PLURAL:$1|1=Значение|Значения}} свойства (всего)",
- "smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|1=Свойство|Свойства}}]] (всего)",
- "smw-statistics-property-total-legacy": "{{PLURAL:$1|1=Свойство|Свойства}} (всего)",
- "smw-statistics-property-used": "[[Special:Properties|{{PLURAL:$1|Свойство|Свойства}}]] (с хотя бы одним значением)",
- "smw-statistics-property-page": "{{PLURAL:$1|Свойство|Свойства}} (зарегистрировано на странице)",
- "smw-statistics-property-type": "{{PLURAL:$1|Свойство|Свойства}} (назначено для типа данных)",
- "smw-statistics-query-inline-legacy": "{{PLURAL:$1|Запрос|Запросы}}",
- "smw-statistics-query-inline": "[[Property:Has query|{{PLURAL:$1|Запрос|Запросы}}]]",
+ "smw-statistics-property-instance": "{{PLURAL:$1|1=Значение|Значения|Значений}} свойства (всего)",
+ "smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|1=Свойство|Свойства|Свойств}}]] (всего)",
+ "smw-statistics-property-total-legacy": "{{PLURAL:$1|1=Свойство|Свойства|Свойств}} (всего)",
+ "smw-statistics-property-used": "[[Special:Properties|{{PLURAL:$1|Свойство|Свойства|Свойств}}]] (с хотя бы одним значением)",
+ "smw-statistics-property-page": "{{PLURAL:$1|Свойство|Свойства|Свойств}} (зарегистрировано на странице)",
+ "smw-statistics-property-type": "{{PLURAL:$1|Свойство|Свойства|Свойств}} (назначено для типа данных)",
+ "smw-statistics-query-inline-legacy": "{{PLURAL:$1|Запрос|Запроса|Запросов}}",
+ "smw-statistics-query-inline": "[[Property:Has query|{{PLURAL:$1|Запрос|Запроса|Запросов}}]]",
"smw-statistics-query-size": "Размер запроса",
- "smw-statistics-concept-count-legacy": "{{PLURAL:$1|1=Концепт|Концепты}}",
- "smw-statistics-concept-count": "[[Special:Concepts|{{PLURAL:$1|1=Концепт|Концепты}}]]",
- "smw-statistics-subobject-count": "[[Property:Has subobject|{{PLURAL:$1|Подобъект|Подобъекты}}]]",
- "smw-statistics-subobject-count-legacy": "{{PLURAL:$1|Подобъект|Подобъекты}}",
- "smw-statistics-datatype-count": "[[Special:Types|{{PLURAL:$1|1=Тип данных|Типы данных}}]]",
- "smw-statistics-error-count": "{{PLURAL:$1|Значения свойства|Значений свойств}} ([[Special:ProcessingErrorList|{{PLURAL:$1|неправильная аннотация|неправильные аннотации}}]])",
- "smw-statistics-error-count-legacy": "{{PLURAL:$1|Значение свойства|Значения свойства|Значений свойств}} ({{PLURAL:$1|неправильная аннотация|неправильные аннотации}})",
+ "smw-statistics-concept-count-legacy": "{{PLURAL:$1|1=Концепция|Концепции|Концепций}}",
+ "smw-statistics-concept-count": "[[Special:Concepts|{{PLURAL:$1|1=Концепция|Концепции|Концепций}}]]",
+ "smw-statistics-subobject-count": "[[Property:Has subobject|{{PLURAL:$1|Подобъект|Подобъекта|Подобъектов}}]]",
+ "smw-statistics-subobject-count-legacy": "{{PLURAL:$1|Подобъект|Подобъекта|Подобъектов}}",
+ "smw-statistics-datatype-count": "[[Special:Types|{{PLURAL:$1|1=Тип данных|Типа данных|Типов данных}}]]",
+ "smw-statistics-error-count": "{{PLURAL:$1|Значение свойства|Значения свойства|Значений свойств}} ([[Special:ProcessingErrorList|{{PLURAL:$1|неправильная аннотация|неправильные аннотации|неправильных аннотаций}}]])",
+ "smw-statistics-error-count-legacy": "{{PLURAL:$1|Значение свойства|Значения свойства|Значений свойств}} ({{PLURAL:$1|неправильная аннотация|неправильные аннотации|неправильных аннотаций}})",
"smw-statistics-delete-count": "{{PLURAL:$1|Устаревший объект (отмеченный для удаления)|Устаревших объекта (отмеченных для удаления)|Устаревших объектов (отмеченных для удаления)}}",
"smw_uri_doc": "Преобразователь URI осуществляет [$1 W3C поиск http тэгов с использованием Range-14].\nДанная возможность упрощает поиск семантической информации.",
"ask": "Семантический поиск",
@@ -309,7 +311,7 @@
"searchbyproperty": "Искать по свойству",
"processingerrorlist": "Список ошибок обработки",
"propertylabelsimilarity": "Сообщение о похожести метки свойств",
- "smw-processingerrorlist-intro": "Cписок ошибок в работе [https://www.semantic-mediawiki.org/ Semantic MediaWiki]. Этот список рекомендуется регулярно просматривать, исправляя некорректные аннотации значений.",
+ "smw-processingerrorlist-intro": "Cписок ошибок в работе [https://www.semantic-mediawiki.org/ Semantic MediaWiki]. Этот список рекомендуется регулярно просматривать, исправляя некорректные семантические аннотации.",
"smw_sbv_docu": "Искать все страницы, которые содержат указаннок свойство и значение.",
"smw_sbv_novalue": "Укажите значение или просмотрите все значения свойства $1.",
"smw_sbv_displayresult": "Список всех страниц, которые содержат свойство $1 со значением $2.",
@@ -349,6 +351,7 @@
"smw-admin-statistics-job-docu": "Статистика заданий отображает информацию о запланированных заданиях Semantic MediaWiki, которые еще не были выполнены. Количество заданий может быть неточным или может содержать неудачные попытки их выполнения. Обратитесь к [https://www.mediawiki.org/wiki/manual:Job_queue к руководству] за дополнительной информацией.",
"smw-admin-statistics-querycache-title": "Статистика кэша запросов",
"smw-admin-statistics-querycache-disabled": "[https://www.semantic-mediawiki.org/wiki/QueryCache QueryCache] не включён на этой вики, поэтому статистика недоступна.",
+ "smw-admin-statistics-querycache-explain": "Статистика кэша показывает текущие показатели кэша нарастающим итогом, а также производные метрики:\n* \"misses\" — общее количество промахов кэша, потребовавших обращения к семантическому хранилищу (БД или RDF-хранидище),\n* \"deletes\" — общее число удалений из кэша, вызванных обновлением страницы или обработкой зависимости,\n* \"hits\" — количество удачных получений из кэша, как от встроенных запросов, так и со спецстраницы [[Служебная:Ask]] или посредством API,\n* \"medianRetrievalResponseTime\" — ориентировочное медианное время (в секундах) выполнения кэшированных и некэшированных запросов к данным за время сбора статистики,\n* \"noCache\" — количество запросов без попыток обращения к кэшу (запросы с <code>limit=0</code>, опция no-cache и т.п.)",
"smw-admin-permission-missing": "Доступ к этой странице ограничен. Пожалуйста, обратитесь к [https://www.semantic-mediawiki.org/wiki/Help:Permissions справочоной] странице помощи за подробной информацией.",
"smw-admin-setupsuccess": "Система хранения была установлена.",
"smw_smwadmin_return": "Вернуться к $1",
@@ -358,7 +361,7 @@
"smw_smwadmin_updatenotstopped": "Чтобы остановить запущенный процесс обновления, вы должны поставить отметку, подтверждающую, что вы действительно уверены в этом решении.",
"smw-admin-docu": "Эта служебная страница поможет вам в процессе установки, обновления, обслуживания и использования расширения <a href=\"http://semantic-mediawiki.org\">Semantic MediaWiki</a>.\nНе забывайте производить резервное копирование важных данных перед выполнением административных действий.",
"smw-admin-environment": "Оболочка программного обеспечения",
- "smw-admin-db": "Обслуживание базы данных",
+ "smw-admin-db": "Настройка базы данных",
"smw-admin-db-preparation": "Идёт установка таблицы. Это может занять некоторое время, прежде чем отобразятся результаты и возможная оптимизация таблицы.",
"smw-admin-dbdocu": "Semantic MediaWiki требует наличия некоторых расширений, позволяющих хранить семантические данные в базе данных MediaWiki.\nПриведённая ниже функция проверяет корректность настроек базы данных.\nВыполненные здесь изменения не влияют на основную часть базы данных MediaWiki и при желании могут быть легко отменены.\nХотя эта функция может быть многократно выполнена без каких-либо последствий, её запуск необходим только один раз — во время установки или обновления Semantic MediaWiki.",
"smw-admin-permissionswarn": "Причиной сбоев при выполнении SQL-команд может быть отсутствие необходимых прав у пользователя, от имени которого вы подключаетесь к базе данных вики (проверьте файл LocalSettings.php).\nПопробуйте предоставить этому пользователю дополнительные права на создание и удаление таблиц; временно введите логин «root» в файле LocalSettings.php, или используйте обслуживающий скрипт <code>setupStore.php</code>, который может использовать настройки администратора.",
@@ -399,7 +402,7 @@
"smw-admin-propertystatistics-button": "Запланировать перестройку свойства",
"smw-admin-fulltext-title": "Перестройка полнотекстового поиска",
"smw-admin-fulltext-intro": "Перестраивает поисковый индекс из таблиц свойств с включённым типом данных [https://www.semantic-mediawiki.org/wiki/Full-text полнотекстового поиска]. Изменения в правила индексации (изменённые шумовые слова, новый стемер и т. п.) и/или заново добавленная или изменённая таблица требуют повторного запуска этого задания.",
- "smw-admin-fulltext-active": "Была запланирована работа по перепрограммированию полнотекстового поиска.",
+ "smw-admin-fulltext-active": "Была запланирована работа по перепостроению полнотекстового поиска.",
"smw-admin-fulltext-button": "Запланировать полнотекстовую перестройку",
"smw-admin-support": "Получение поддержки",
"smw-admin-supportdocu": "Различные ресурсы, которые помогут вам в случае проблем:",
@@ -409,34 +412,46 @@
"smw-admin-questions": "Если у вас есть дополнительные вопросы или предложения, присоединяйтесь к обсуждению в <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">списках рассылки пользователей Semantic MediaWiki</a> или в <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">чате</a>.",
"smw-admin-other-functions": "Другие функции",
"smw-admin-supplementary-section-title": "Дополнительные функции",
- "smw-admin-supplementary-section-subtitle": "Доступные функции",
+ "smw-admin-supplementary-section-subtitle": "Функции ядра",
"smw-admin-supplementary-section-intro": "Эта секция содержит дополнительные функции кроме цели обслуживания, и возможно, что некоторые функции, которые перечислены в [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions документации], ограничены или недоступны, и поэтому это нельзя сделать в этой вики.",
"smw-admin-supplementary-settings-title": "Параметры конфигурации",
+ "smw-admin-supplementary-settings-intro": "<u>$1</u> выводит общий список доступных настроек Semantic MediaWiki",
"smw-admin-supplementary-operational-statistics-title": "Оперативная статистика",
"smw-admin-supplementary-operational-statistics-intro": "<u>$1</u> отображает расширенную информацию.",
"smw-admin-supplementary-idlookup-title": "Поиск и удаление сущности",
"smw-admin-supplementary-idlookup-intro": "<u>$1</u> содержит функции для поиска и расположения отдельных сущностей",
"smw-admin-supplementary-duplookup-title": "Дублирующие объекты",
"smw-admin-supplementary-duplookup-intro": "<u>$1</u> для перечисления записей, которые классифицируются как содержащие дубликаты в таблице сущностей",
+ "smw-admin-supplementary-duplookup-docu": "На этой странице перечислены [https://www.semantic-mediawiki.org/wiki/Help:Entity_table семантические записи], отмеченные как дубликаты. Дубликаты изредка (если вообще) появляются только из-за прерванного обновления базы данных или неудавшегося отката транзакции",
+ "smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
"smw-admin-supplementary-operational-statistics-cache-title": "Статистика кэша",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> показывает статистику касательно кэша",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
"smw-admin-supplementary-elastic-intro": "<u>$1</u> информирует о настройках и статистике кэша",
- "smw-admin-supplementary-elastic-functions": "Доступные функции",
+ "smw-admin-supplementary-elastic-docu": "На этой странице находятся данные о настройках, отображениях, состоянии и статистике индексов, относящаяся к кластеру ''Elasticsearch'', подключённому к ''Semantic MediaWiki'' и его хранилищу [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
+ "smw-admin-supplementary-elastic-functions": "Поддерживаемые функции",
"smw-admin-supplementary-elastic-settings-title": "Настройки",
+ "smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> используется ''Elasticsearch'' для управления индексами ''Semantic MediaWiki''",
"smw-admin-supplementary-elastic-mappings-title": "Соответствия",
+ "smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u> — список отображений индексов и полей",
+ "smw-admin-supplementary-elastic-mappings-docu": "На этой странице находятся подробности отображения полей, используемых с текущими индексами. Отчёт об отображении следует анализировать, учитывая значение переменной <code>index.mapping.total_fields.limit</code>, хранящей максимальное число полей в индексе.",
"smw-admin-supplementary-elastic-mappings-summary": "Описание",
+ "smw-admin-supplementary-elastic-mappings-fields": "Отображения полей",
"smw-admin-supplementary-elastic-nodes-title": "Узлы",
"smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u> показывает статистику узлов",
"smw-admin-supplementary-elastic-indices-title": "Индексы",
"smw-admin-supplementary-elastic-indices-intro": "<u>$1</u> предоставляет обзор доступных индексов и их статистику",
"smw-admin-supplementary-elastic-statistics-title": "Статистика",
"smw-admin-supplementary-elastic-statistics-intro": "<u>$1</u> показывает статистику уровня индекса",
+ "smw-admin-supplementary-elastic-statistics-docu": "Эта страница дает представление о статистике индексов для различных операций, выполняемых на уровне индекса, возвращенная статистика агрегируется с первичными и суммарными агрегациями. [Https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-stats.html страница справки] содержит подробное описание статистики доступных индексов.",
"smw-admin-supplementary-elastic-status-replication": "Статус репликации",
"smw-admin-supplementary-elastic-status-last-active-replication": "Последняя активная репликация: $1",
"smw-admin-supplementary-elastic-status-refresh-interval": "Интервал обновления: $1",
+ "smw-admin-supplementary-elastic-status-recovery-job-count": "Задержка восстановления работ: $1 (оценка)",
+ "smw-admin-supplementary-elastic-status-file-ingest-job-count": "Журнал невыполненных работ (файл): $1 (оценка)",
"smw-admin-supplementary-elastic-status-rebuild-lock": "Репликация заблокирована: $1 (перепостроение в процессе)",
- "smw-list-count": "Список содержит $1 {{PLURAL:$1|запись|записи (записей)}}.",
+ "smw-list-count": "Список содержит $1 {{PLURAL:$1|запись|записи|записей}}.",
+ "smw-list-count-from-cache": "В списке, полученном из кэша в (UTC: $2), $1 {{PLURAL:$1|значение|значения|значений}}.",
"smw-property-label-uniqueness": "Метка \"$1\" была сопоставлена по крайней мере с одним другим представлением свойств. Пожалуйста, проконсультируйтесь со [https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness страницей помощи] о том, как устранить эту проблему.",
"smw-property-label-similarity-title": "Сообщение о подобности названий свойств",
"smw-property-label-similarity-intro": "<u>$1</u> вычисляет подобие существующих названий свойств",
@@ -451,6 +466,7 @@
"smw-page-indicator-usage-count": "Примерное [https://www.semantic-mediawiki.org/wiki/Help:Property_usage_count \nколичество использований]: {{PLURAL:$2|'''$2'''}}",
"smw-property-indicator-type-info": "Свойство, определённое {{PLURAL:$1|участником|системой}}",
"smw-property-indicator-last-count-update": "Примерное число использований\nПоследний раз обновлено: $1",
+ "smw-concept-indicator-cache-update": "Счётчик кэша\nОбновлён в $1",
"smw-createproperty-isproperty": "Это свойство типа $1.",
"smw-createproperty-allowedvals": "Для данного свойства {{PLURAL:$1|1=допускается следующее значение|допускаются следующие значения}}:",
"smw-paramdesc-category-delim": "Разделитель",
@@ -463,9 +479,15 @@
"prefs-ask-options": "Параметры семантического поиска",
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/ Semantic MediaWiki] (и связанные с ней расширения) предоставляют возможности индивидуальной настройки для некоторых функций. Для получения дополнительной информации, пожалуйста, посмотрите в [https://www.semantic-mediawiki.org/wiki/Help:User_preferences раздел справки].",
"smw-prefs-ask-options-tooltip-display": "Отображать параметр «текст» в виде всплывающей подсказки",
+ "smw-prefs-ask-options-compact-view-basic": "Включить простой сжатый формат",
+ "smw-prefs-help-ask-options-compact-view-basic": "Если включено, показывает сокращённый набор ссылок на Special:Ask в сжатом формате",
"smw-prefs-general-options-time-correction": "Включить корректировку времени для служебных страниц при помощи локальной настройки [[Special:Preferences#mw-prefsection-rendering|временного смещения]]",
+ "smw-prefs-general-options-jobqueue-watchlist": "Показывать список наблюдения за очередью задач на личной панели",
+ "smw-prefs-help-general-options-jobqueue-watchlist": "Включите, чтобы показывать [https://www.semantic-mediawiki.org/wiki/Help:Job_queue_watchlist список] ожидающих избранных задач, вместе с приблизительными размерами их очередей.",
"smw-prefs-general-options-disable-editpage-info": "Отключить вступительный текст на странице редактирования",
+ "smw-prefs-general-options-disable-search-info": "Отключить информацию о поддержке синтаксиса на стандартной странице поиска",
"smw-prefs-general-options-suggester-textinput": "Включить ассистента ввода для предложений семантических объектов",
+ "smw-prefs-help-general-options-suggester-textinput": "Включите, чтобы получать [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance автодополнение] названий свойств, концепций и категорий при вводе",
"smw-ui-tooltip-title-property": "Свойство",
"smw-ui-tooltip-title-quantity": "Преобразование единиц",
"smw-ui-tooltip-title-info": "Информация",
@@ -477,17 +499,18 @@
"smw-ui-tooltip-title-note": "Примечание",
"smw-ui-tooltip-title-legend": "Легенда",
"smw-ui-tooltip-title-reference": "Примечание",
- "smw_unknowntype": "Для этого свойства задан некорректный тип",
- "smw-concept-cache-text": "Концепт имеет в общей сложности $1 {{PLURAL:$1|страницу|страницы|страниц}} и последний раз обновлялся $2 в $3.",
+ "smw_unknowntype": "Для этого свойства задан неизвестный тип «$1»",
+ "smw-concept-cache-text": "Концепция имеет в общей сложности $1 {{PLURAL:$1|страницу|страницы|страниц}} и последний раз обновлялся $2 в $3.",
"smw_concept_header": "Страницы, использующие представление «$1»",
- "smw_conceptarticlecount": "Ниже {{PLURAL:$1|показана|показаны|показано}} $1 {{PLURAL:$1|страница|страницы|страниц}}.",
+ "smw_conceptarticlecount": "Ниже {{PLURAL:$1|показана|показаны}} $1 {{PLURAL:$1|страница|страницы|страниц}}.",
"smw-qp-empty-data": "Запрошенные данные не удаётся отобразить из-за недостаточности некоторых критериев отбора.",
- "right-smw-admin": "доступ к административным задачам (Semantic MediaWiki)",
- "right-smw-patternedit": "доступ к редактированию разрешенных для обслуживания регулярных выражений и шаблонов (Semantic MediaWiki)",
- "right-smw-pageedit": "редактирование страниц с аннотацией <code>Is edit protected</code> (Semantic MediaWiki)",
+ "right-smw-admin": "Доступ к администрированию (Semantic MediaWiki)",
+ "right-smw-patternedit": "Доступ к редактированию разрешенных для обслуживания регулярных выражений и шаблонов (Semantic MediaWiki)",
+ "right-smw-pageedit": "Редактирование страниц с аннотацией <code>Is edit protected</code> (Semantic MediaWiki)",
"right-smw-ruleedit": "Редактировать страницы правил (Semantic MediaWiki)",
"restriction-level-smw-pageedit": "защищено (только подходящие пользователи)",
"action-smw-patternedit": "редактирования регулярных выражений, используемых Semantic MediaWiki",
+ "action-smw-pageedit": "редактирование страниц с аннотацией <code>Is edit protected</code> (''Semantic MediaWiki'')",
"group-smwadministrator": "Администраторы (Semantic MediaWiki)",
"group-smwadministrator-member": "{{GENDER:$1|администратор (Semantic MediaWiki)}}",
"grouppage-smwadministrator": "{{ns:project}}:Администраторы (Semantic MediaWiki)",
@@ -501,6 +524,7 @@
"smw-property-predefined-ask": "«$1» — это предопределённое свойство, которое представляет мета-данные (в форме [https://www.semantic-mediawiki.org/wiki/Subobject подобъекта]) об индивидуальных запросах и предоставляется [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-asksi": "«$1» — это предопределённое свойство, которое собирает количество условий, используемых в запросе и предоставляется [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-askde": "«$1» — предварительно определенное свойство, которое информирует о глубине запроса и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-property-predefined-long-askde": "Численное значение, полученное на основании вложенности подзапросов, цепочек свойств и доступных элементов описания и используемой для ограничения выполнения запросов посредством настройки <code>[https://www.semantic-mediawiki.org/wiki/Help:$smwgQMaxDepth $smwgQMaxDepth]</code>",
"smw-property-predefined-askpa": "$1 - это предопределенное свойство, описывающее параметры влияющие на результат запроса. Предоставляется от [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-long-askpa": "Это часть набора свойств, который определяет [https://www.semantic-mediawiki.org/wiki/Help:Query_profiler query profile].",
"smw-sp-properties-docu": "На этой странице перечислены доступные [https://www.semantic-mediawiki.org/wiki/Property свойства] и количество их использований в этой вики. Для получения актуальной статистики рекомендуется, чтоб сервисный скрипт [https://www.semantic-mediawiki.org/wiki/rebuildPropertyStatistics статистики свойст] запускался на регулярной основе. Для дифференцированного представления см. служебные страницы со списком [[Special:UnusedProperties|неиспользованных]] или [[Special:WantedProperties|требуемых свойств]].",
@@ -520,9 +544,10 @@
"smw-admin-objectid": "Идентификатор:",
"smw-admin-tab-general": "Обзор",
"smw-admin-tab-notices": "Замечания по запрету",
- "smw-admin-tab-rebuild": "Техническое обслуживание",
+ "smw-admin-tab-maintenance": "Техническое обслуживание",
"smw-admin-tab-supplement": "Дополнительные функции",
"smw-admin-tab-registry": "Реестр",
+ "smw-admin-maintenance-no-description": "Нет описания.",
"smw-livepreview-loading": "Загрузка…",
"smw-sp-searchbyproperty-description": "На этой странице предоставлен простой [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces интерфейс просмотра] для нахождения сущностей по описанным свойствам и именованным значениям. Другие доступные интерфейсы поиска включают в себя [[Special:PageProperty|страницу поиск свойств]] и [[Special:Ask|построитель поисковых запросов]].",
"smw-sp-searchbyproperty-resultlist-header": "Список результатов",
@@ -535,17 +560,29 @@
"smw-editpage-property-annotation-enabled": "Это свойство можно расширить с помощью семантических аннотаций для указания типа данных (например <nowiki>\"[[Has type::Page]]\"</nowiki>) или других поддерживаемых утверждений (e.g. <nowiki>\"[[Subproperty of::dc:date]]\"</nowiki>). Описание, как расширить эту страницу смотрите на странице справки о [https://www.semantic-mediawiki.org/wiki/Help:Property_declaration \nзаявлении свойства] или [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes список доступных типов данных].",
"smw-editpage-property-annotation-disabled": "Это свойство нельзя расширить аннотацией типа данных (например <nowiki>\"[[Has type::Page]]\"</nowiki>), поскольку она уже предварительно определена (см. более подробную информацию на справочной странице о [https://www.semantic-mediawiki.org/wiki/Help:Special_properties специальные свойства]).",
"smw-editpage-concept-annotation-enabled": "Этот концепт можно расширить с использованием парсерной функции #concept. Описание, как использовать #concept, см. на справочной странице о [https://www.semantic-mediawiki.org/wiki/Help:Concepts концептах].",
+ "smw-search-syntax-support": "Поле поиска поддерживает [https://www.semantic-mediawiki.org/wiki/Help:Semantic_search синтаксис семантических запросов] ''MediaWiki''",
"smw-search-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance Помощник по вводу] включён, чтобы упростить выбор всех возможных опций и категорий.",
+ "smw-search-help-intro": "Ввод <code><nowiki>[[ ... ]]</nowiki></code> укажет процессору использовать поисковый механизм ''Semantic MediaWiki''. Обратите внимание, что сочетание <code><nowiki>[[ ... ]]</nowiki></code> с простым текстовым поиском, наподобие <code><nowiki>[[ ... ]] OR Lorem ipsum</nowiki></code>, не поддерживается.",
+ "smw-search-help-structured": "Структурированный поиск:\n\n*<code><nowiki>[[Category:Lorem ipsum]]</nowiki></code>, <code><nowiki>[[Has number::123]]</nowiki></code> — [https://www.semantic-mediawiki.org/wiki/Help:Search#Filter_context контекст отбора]\n\n*<code><nowiki>[[Has text::~*lorem*]]</nowiki></code> — с [https://www.semantic-mediawiki.org/wiki/Help:Search#Query_context контекстом запроса]",
+ "smw-search-help-ask": "По этим ссылкам находится информация о том, как использовать функцию парсера <code>#ask</code>:\n\n* [https://www.semantic-mediawiki.org/wiki/Help:Selecting_pages Выбор страниц] — как выбирать страницы и составлять условия отбора\n\n*[https://www.semantic-mediawiki.org/wiki/Help:Search_operators Поисковые операторы] — поддерживаемые поисковые операторы, включая отбор по диапазонам и метасимволам",
"smw-search-input": "Ввод и поиск",
+ "smw-search-help-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance Автодополение] в поле ввода требует одиниз следующих префиксов:\n\n*<code>p:</code> для свойств (например, <code><nowiki>[[p:Has ...</nowiki></code>)\n\n*<code>c:</code> для категорий\n\n*<code>con:</code> для концепций",
"smw-search-syntax": "Синтаксис",
"smw-search-profile": "Дополнительно",
+ "smw-search-profile-tooltip": "Функции поиска, относящиеся к Semantic MediaWiki",
"smw-search-profile-sort-best": "Лучшее совпадение",
"smw-search-profile-sort-recent": "Самые недавние",
"smw-search-profile-sort-title": "Название",
+ "smw-search-profile-extended-help-intro": "Специальный: Поиск [https://www.semantic-mediawiki.org/wiki/Help:SMWSearch/Extended_profile расширенный профиль] предоставляет доступ к функциям поиска, специфичным для Semantic MediaWiki и его поддерживаемой серверной части запроса.",
+ "smw-search-profile-extended-help-sort": "Порядок сортировки результатов запроса:",
+ "smw-search-profile-extended-help-sort-title": "*«Название» с использованием заголовка страницы (или отображаемого заголовка) в качестве критерия сортировки",
+ "smw-search-profile-extended-help-sort-recent": "* \"Совсем недавние\" для показа страниц в порядке последнего изменения (от недавних к давним), при этом подобъекты не будут выведены, поскольку для них не определено свойство [[Property:Modification date|Дата изменения]]",
+ "smw-search-profile-extended-help-search-syntax": "Поле поиска поддерживает синстаксис функции парсера <code>#ask</code> для семантического поиска. Полезные выражения включают:",
"smw-search-profile-extended-help-query-link": "(О подробностях см. $1).",
"smw-search-profile-extended-help-find-forms": "Доступные формы",
"smw-search-profile-extended-section-sort": "Сортировать по",
"smw-search-profile-extended-section-form": "Формы",
+ "smw-search-profile-extended-section-search-syntax": "Поиск входа",
"smw-search-profile-extended-section-namespace": "Пространство имён",
"smw-search-profile-extended-section-query": "Запрос",
"smw-search-profile-link-caption-query": "см.",
@@ -555,31 +592,52 @@
"log-show-hide-smw": "$1 журнал Semantic MediaWiki",
"logeventslist-smw-log": "Журнал Semantic MediaWiki",
"log-description-smw": "Деятельность относительно [https://www.semantic-mediawiki.org/wiki/Help:Logging включенных типов событий], которую регистрирует Semantic MediaWiki и ее компоненты.",
+ "smw-datavalue-import-missing-namespace-uri": "Не удалось найти URI пространства имен «$1» в [[MediaWiki:Smw import $1|импорте $1]].",
"smw-datavalue-import-missing-type": "Не было найдено определение типа для «$1» в [[MediaWiki:Smw import $2|импорте $2]].",
"smw-datavalue-import-link": "[[MediaWiki:Smw import $1|Импорт $1]]",
+ "smw-datavalue-import-invalid-value": "«$1» не является действительным форматом и должен состоять из «пространство имен»:«идентификатор» (например «foaf:name»).",
"smw-property-predefined-impo": "\"$1\" — это предопределённое свойство, которое описывает отношение к [https://www.semantic-mediawiki.org/wiki/Help:Import_vocabulary заимствованной лексике] и предоставляется [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-type": "«$1» — предварительно определенное свойство, которое описывает [[Special:Types|тип данных]] свойства, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-sobj": "«$1» — предопределённое свойство, которое представляет построение [https://www.semantic-mediawiki.org/wiki/Help:Container контейнера], и обеспечиваемое [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
- "smw-property-predefined-errp": "«$1» — это предварительно определенное свойство для отслеживания ошибок ввода аннотаций нерегулярных значений, что были, вероятно, вызваны ограничениями типа или [[Property:Allows value|разрешенных значений]], обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-property-predefined-long-sobj": "Это хранилище позволяет сохранять значения свойств, как на обычной вики-странице, но в особом пространстве, привязанном к содержащей его странице",
+ "smw-property-predefined-errp": "«$1» — это предварительно определённое свойство для отслеживания неверных значений в аннотациях и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-property-predefined-long-errp": "Обычно вызывается несоответствием типа данных или несоблюдением ограничения [[Property:Allows value|допустимых значений]].",
"smw-property-predefined-pval": "[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Allows_value «$1»] — \nпредварительно определенное свойство, которое может определять список разрешенных значений, чтобы ограничивать назначение значений для свойства, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-property-predefined-pvali": "[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Allows_value_list «$1»] — предопределённое свойство, для хранения ссылки на список допустимых значений свойства. Предоставляется ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]''.",
+ "smw-datavalue-property-restricted-annotation-use": "Свойство «$1» имеет особое назначение, и его значение не может устанавливаться в семантической аннотации.",
+ "smw-datavalue-property-restricted-declarative-use": "Свойство «$1» — декларативное, и должно использоваться только на страницах свойств или категорий.",
+ "smw-datavalue-property-create-restriction": "Свойство «$1» ещё не существует, а у пользователя нет разрешения «$2» (см. [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode Режим разграничения доступа]), чтобы создавать новые свойства.",
+ "smw-datavalue-property-invalid-character": "«$1» содержит запрещённый символ «$2» и, следовательно, отмечено, как недопустимое.",
+ "smw-datavalue-property-invalid-chain": "Использование цепочки свойств «$1» недопустимо в семантической аннотации.",
"smw-datavalue-restricted-use": "Значение данных «$1» было отмечено для ограниченного использования.",
"smw-datavalue-invalid-number": "«$1» не может быть интерпретировано как число.",
"smw-query-condition-circular": "Возможное циклическое условие было обнаружено в «$1».",
+ "smw-query-condition-empty": "В запросе есть пустое условие.",
"smw-types-list": "Список типов данных",
"smw-types-default": "«$1» является встроенным типом данных.",
"smw-types-help": "Дальнейшую информацию и примеры можно найти на [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 странице справки].",
"smw-type-anu": "«$1» — это вариант типа данных [[Special:Types/URL|URL]] и в основном используется для экспортной декларации \"owl:AnnotationProperty\".",
"smw-type-boo": "«$1» — это примитивный тип данных для описания значения истина/ложь.",
"smw-type-cod": "«$1» — это вариант типа данных [[Special:Types/Text|Текст]] для использования в технических текстах произвольной длины, таких как списки исходного кода.",
- "smw-type-geo": "«$1» — это тип данных, который описывает географическое положение и требует [https://www.semantic-mediawiki.org/wiki/Extension:Maps расширение «Maps»].",
+ "smw-type-geo": "«$1» — это тип данных, который описывает географическое положение и требует установить [https://www.semantic-mediawiki.org/wiki/Extension:Maps расширение «Maps»].",
"smw-type-tel": "«$1» — это специальный тип данных для описания международных телефонных номеров согласно RFC 3966.",
"smw-type-txt": "«$1» — это примитивный тип данных для описания строк произвольной длины.",
"smw-type-dat": "«$1» — это тип данных для представления моментов времени в едином формате.",
+ "smw-type-ema": "«$1» — тип данных для хранения адреса электронной почты.",
+ "smw-type-tem": "«$1» — особый численный тип данных для хранения температуры.",
+ "smw-type-qty": "«$1» — численный тип данных с единицей измерения.",
+ "smw-type-rec": "«$1» — тип данных для хранения упрядоченного списка типизированных свойств.",
+ "smw-type-extra-tem": "Процедура перевода поддерживает температурные шкалы Кельвина, Цельсия, Фаренгейта и Ранкина.",
"smw-type-tab-properties": "Свойства",
"smw-type-tab-types": "Типы",
"smw-type-tab-errors": "Ошибки",
+ "smw-type-primitive": "Скалярные",
+ "smw-type-contextual": "Зависимые",
+ "smw-type-compound": "Составные",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
- "smw-special-pageproperty-description": "На этой странице представлен интерфейс просмотра для поиска всех значений свойства и заданной страницы. Другие доступные интерфейсы поиска включают в себя [[Special:SearchByProperty|поиск свойств]] и [[Special:Ask|спросить построитель запросов]].",
+ "smw-special-pageproperty-description": "На этой странице представлен интерфейс просмотра для поиска всех значений свойства и заданной страницы. Другие доступные интерфейсы поиска включают в себя [[Special:SearchByProperty|поиск свойств]] и [[Special:Ask|построитель поисковых запросов]].",
"smw-property-predefined-errc": "«$1» — это предварительно определённое свойство, обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] и представляет ошибки, которые возникли в связи с неправильными аннотациями значений или обработкой ввода.",
"smw-property-predefined-long-errc": "Ошибки накапливаются в [https://www.semantic-mediawiki.org/wiki/Help:Container контейнере], который также может включать ссылки на свойство, которое и повлекло несоответствие.",
"smw-property-predefined-errt": "«$1» — это предварительно определенное свойство, содержит текстовое описание ошибки и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
@@ -594,6 +652,9 @@
"smw-property-predefined-askfo": "«$1» — это предварительно определенное свойство содержит имя конечного формата, использованного в запросе, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-askst": "«$1» — это предварительно определенное свойство, описывающее условия запроса в виде строки, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-askdu": "«$1» — это предварительно определенное свойство, содержащее значение времени (в секундах), которое требуется для завершения выполнения запроса, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
+ "smw-property-predefined-asksc": "«$1» — предопределённое свойство, предоставленное ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'' для хранения альтернативных (т.е. внешник) источников запросов.",
+ "smw-property-predefined-askco": "«$1» — предопределённое свойство, предоставленное ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'' для хранения состояния запроса или его частей.",
+ "smw-property-predefined-long-askco": "Число или числа, представляющие код состояния запроса (см. [https://www.semantic-mediawiki.org/wiki/Help:Query_profiler Профилировщик запросов]).",
"smw-property-predefined-prec": "«$1» — это предварительно определенное свойство, описывающее [https://www.semantic-mediawiki.org/wiki/Help:Display_precision точность отображения] (в десятичных цифрах) для числовых типов данных.",
"smw-types-extra-geo-not-available": "[https://www.semantic-mediawiki.org/wiki/Extension:Maps Расширение «Maps»] не было обнаружено, поэтому свойство «$1» ограничено в своей работе.",
"smw-datavalue-monolingual-dataitem-missing": "Отсутствует ожидаемый элемент для построения одноязычного значение.",
@@ -614,26 +675,78 @@
"smw_allows_pattern": "Чтобы доступ к странице был открыт с помощью свойства «[[Property:Allows pattern|Allows pattern]]», эта страница должна содержать список ссылок (после которого идут [https://ru.wikipedia.org/wiki/Регулярные_выражения регулярные выражения]). Для редактирования этой страницы необходимы права <code>smw-patternedit</code>.",
"smw-datavalue-allows-pattern-mismatch": "Регулярное выражение «$2» классифицировало значение «$1» как недопустимое.",
"smw-datavalue-allows-pattern-reference-unknown": "Ссылки на шаблон «$1» не удалось сравнить с записью на [[MediaWiki:Smw allows pattern]].",
+ "smw-datavalue-allows-value-list-unknown": "Строка «$1» не найдена в списке [[MediaWiki:Smw allows list $1]] .",
+ "smw-datavalue-allows-value-list-missing-marker": "Список «$1» не содержит строк с маркёром списка <code>*</code>.",
"smw-datavalue-feature-not-supported": "Функция «$1» не поддерживается или была выключена в этой вики.",
"smw-property-predefined-pvap": "«$1» — это предварительно определенное свойство, которой можно указать [[MediaWiki:Smw allows pattern|ссылка на шаблон]], чтобы применить сопоставление [https://en.wikipedia.org/wiki/Regular_expression регулярных выражений], и которая обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-dtitle": "«$1» — это предварительно определенное свойство, которой для сущности можно назначить отдельное название для отображения, и которое обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-pvuc": "«$1» — это предварительно определенное свойство, которое обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] для ограничения присвоения значений для каждого экземпляра уникальным значением (или максимум одним).",
"smw-property-predefined-long-pvuc": "Уникальность устанавливается, когда два значения являются неодинаковыми в своей символьной репрезентации, и любое нарушение этого ограничения будет квалифицировано как ошибка.",
"smw-datavalue-uniqueness-constraint-error": "Свойство «$1» позволяет только уникальные присвоенные значения, а «$2» уже было аннотировано в теме «$3».",
+ "smw-datavalue-uniqueness-constraint-isknown": "Свойство «$1» предусматривает только уникальные присвоения. На странице «$2» уже есть присвоенное значение. «$3» нарушает требование уникальности.",
+ "smw-property-predefined-boo": "«$1» — [[Special:Types/Boolean|тип данных]] и предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'' для хранения булевых значений.",
+ "smw-property-predefined-num": "«$1» — [[Special:Types/Number|тип данных]] и предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'' для хранения численных данных.",
+ "smw-property-predefined-dat": "«$1» — [[Special:Types/Date|тип данных]] и предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', для хранения дат.",
+ "smw-property-predefined-uri": "«$1» — [[Special:Types/Date|тип данных]] и предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', для хранения URI и URL.",
+ "smw-property-predefined-qty": "«$1» — [[Special:Types/Date|тип данных]] и предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', для хранения количественных данных с единицами измерения.",
+ "smw-datavalue-time-invalid-offset-zone-usage": "Сдвиг и часовой пояс в «$1» не распознан.",
+ "smw-datavalue-time-invalid-values": "Значение «$1» содержит не распознанную информацию «$2».",
"smw-datavalue-time-invalid-date-components-common": "«$1» содержит некоторую не поддающуюся интерпретации информации.",
+ "smw-datavalue-time-invalid-date-components-dash": "«$1» содержит посторонний дефис или другой символ, не допустимый в дате.",
"smw-datavalue-time-invalid-date-components-empty": "«$1» содержит некоторые пустые компоненты.",
+ "smw-datavalue-time-invalid-date-components-three": "«$1» содержит более трёх составляющих, требуемых для распознания даты.",
+ "smw-datavalue-time-invalid-date-components-sequence": "«$1» содержит последовательность символов, не поддающуюся интерпретации в соответствии с имеющейся матрицей компонентов дат.",
+ "smw-datavalue-time-invalid-ampm": "«$1» содержит подстроку «$2», которая не может содержаться во времени в двенадцатичасовом формате.",
+ "smw-datavalue-time-invalid-jd": "«$1» не поддаётся разбору в качестве корректного юлианского дня (результат разбора — «$2»)",
+ "smw-datavalue-external-formatter-uri-missing-placeholder": "В маске URI нет символа подстановки «$1».",
"smw-datavalue-external-formatter-invalid-uri": "«$1» — недопустимый URL-адрес.",
+ "smw-datavalue-external-identifier-formatter-missing": "Не назначено свойство «[[Property:External formatter uri|External formatter URI]]».",
+ "smw-datavalue-keyword-maximum-length": "Ключевое слово превысило максимальную длину $1 {{PLURAL:$1|символ|символа|символов}}.",
+ "smw-property-predefined-eid": "«$1» — [[Special:Types/External identifier|тип данных]] и предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', для хранения внешних идентификаторов.",
+ "smw-property-predefined-peid": "«$1» — предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', для хранения внешнего идентификатора.",
+ "smw-property-predefined-pefu": "«$1» — предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', для хранения адреса внешнего ресурса с символом подстановки.",
+ "smw-property-predefined-long-pefu": "В URI должен содержаться символ подстановки, который будет заменён на [[Special:Types/External identifier|внешний идентификатор]] для получения правильной ссылки на ресурс",
+ "smw-type-eid": "«$1» — разновидность типа «[[Special:Types/Text|Текст]]», для которого надо указать свойство «[[Property:External formatter uri|External formatter URI]]».",
"smw-datavalue-parse-error": "Переданное значение «$1» не было понято.",
"smw-datavalue-propertylist-invalid-property-key": "Список свойств «$1» содержит недопустимый ключ свойства «$2».",
+ "smw-datavalue-type-invalid-typeuri": "Тип «$1» не может быть преобразован в корректный URI.",
+ "smw-datavalue-wikipage-invalid-title": "Значение «$1» типа «Страница» содержит недопустимые символы или неполно и может привести к неожиданным результатам при семантическом аннотировании или запросе.",
+ "smw-datavalue-wikipage-property-invalid-title": "Свойство «$1» типа «Страница» со значением «$2» содержит недопустимые символы или неполно и может привести к неожиданным результатам при семантическом аннотировании или запросе.",
"smw-datavalue-reference-outputformat": "$1: $2",
+ "smw-datavalue-reference-invalid-fields-definition": "Тип «[[Special:Types/Reference|Ссылка]]» требует ввода списка свойств, объявленных с помощью свойства «[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Has_fields Has fields]».",
"smw-parser-invalid-json-format": "JSON-парсер вернул ошибку «$1».",
"smw-property-preferred-title-format": "$1 ($2)",
+ "smw-property-preferred-label-language-combination-exists": "«$1» нельзя использовать в качестве предпочтительной метки, поскольку язык «$2» уже назначен метке «$3».",
"smw-parse": "$1",
"smw-clipboard-copy-link": "Скопировать ссылку в буфер обмена",
+ "smw-property-userdefined-fixedtable": "Свойство «$1» сконфигурировано как as [https://www.semantic-mediawiki.org/wiki/Fixed_properties фиксированное], и любые изменения его [https://www.semantic-mediawiki.org/wiki/Type_declaration типа] требуют или запустить <code>setupStore.php</code>, или выполнить задачу «Установка и обновление базы данных» на служебной странице ''[[Special:SemanticMediaWiki|SemanticMediaWiki]]''.",
"smw-data-lookup": "Извлечение данных…",
+ "smw-data-lookup-with-wait": "Запрос обрабатывается и может занять некоторое время.",
"smw-no-data-available": "Нет доступных данных.",
+ "smw-property-req-violation-missing-fields": "Для свойства «$1» типа «$2» не задано обязательное свойство <code>Has fields</code>.",
+ "smw-property-req-violation-missing-formatter-uri": "Для свойства «$1» не задано обязательное свойство <code>External formatter URI</code>.",
+ "smw-property-req-violation-predefined-type": "Для предопределённого свойства «$1» задан тип «$2», с которым несовместимо значение свойства по умолчанию.",
+ "smw-property-req-violation-import-type": "Обнаружено объявление типа, которое несовместимо с предопределенным типом импортированного словаря «$1». Как правило, нет необходимости объявлять тип, потому что информация извлекается из определения импорта.",
+ "smw-property-req-violation-change-propagation-locked-error": "Свойство «$1» изменено, и связанные с ним страницы должны быть обновлены путём [https://www.semantic-mediawiki.org/wiki/Change_propagation распространения изменений]. Страница свойства закрыта от изменений пока первичное обновление не будет завершено, чтобы избежать прерывания обновления или противоречивых настроек свойства. Это может занять некоторое время, зависящее от размера [https://www.mediawiki.org/wiki/Manual:Job_queue очереди задач] и частоты её обработки, по истечении которого страница будет открыта для изменений.",
+ "smw-property-req-violation-change-propagation-locked-warning": "Свойство «$1» изменено, и связанные страницы должны быть обновены путём [https://www.semantic-mediawiki.org/wiki/Change_propagation распространения изменений]. Обновление может занять некоторое время, зависящее от размера [https://www.mediawiki.org/wiki/Manual:Job_queue очереди заданий]. Рекомендуется отложить редактирование свойства, чтобы избежать прерывания обновления или противоречивых настроек.",
+ "smw-property-req-violation-change-propagation-pending": "Оюидается [https://www.semantic-mediawiki.org/wiki/Change_propagation Распространение изменений] (около $1 [https://www.mediawiki.org/wiki/Manual:Job_queue {{PLURAL:$1|задание|заданий|задания}}]). Рекомендуется отложить редактирование страницы свойства, пока процесс не будет завершён, чтобы избезать прерываний обновления или противоречивых настроек свойства.",
+ "smw-property-req-violation-missing-maps-extension": "Расширение '[https://www.semantic-mediawiki.org/wiki/Extension:Maps Maps]', необходимое для этого типа данных. Как следствие, функциональность этого свойства ограничена.",
+ "smw-property-req-violation-type": "Для этого свойства указаны противоречивые типы данных, что может привести к установке некорректных значений для него. Следует выбрать один подходящий тип.",
+ "smw-change-propagation-protection": "Эта страница закрыта для изменений, чтобы предотвратить случайное изменение, пока идёт [https://www.semantic-mediawiki.org/wiki/Change_propagation распространение изменений]. Это может занять некоторое время, зависящее от размера и частоты обработки [https://www.mediawiki.org/wiki/Manual:Job_queue очереди заданий], прежде чем страница будет открыта для изменений.",
+ "smw-category-change-propagation-locked-error": "Категория «$1» изменена, и связанные страницы должны быть обновлены путём [https://www.semantic-mediawiki.org/wiki/Change_propagation распространения изменений]. А пока, страница категорий закрыта для изменений, пока обновление не будет завершено, чтобы избежать прерывания обновления или противоречий в настройках. Это может занять некоторое время, зависящее от размера [https://www.mediawiki.org/wiki/Manual:Job_queue очереди заданий], прежде чем страница будет открыта для изменений.",
+ "smw-category-change-propagation-locked-warning": "Категория «$1» изменена, и связанные страницы должны быть обновлены путём [https://www.semantic-mediawiki.org/wiki/Change_propagation распространения изменений]. Это может занять некоторое время, зависящее от размера [https://www.mediawiki.org/wiki/Manual:Job_queue очереди заданий], прежде чем страница будет открыта для изменений. Предлагается отложить редактирование страницы, пока обновление не будет завершено, чтобы избежать прерывания обновления или противоречий в настройках.",
+ "smw-category-change-propagation-pending": "Ожидается обновление в результате [https://www.semantic-mediawiki.org/wiki/Change_propagation распространения обновлений] (около $1 [https://www.mediawiki.org/wiki/Manual:Job_queue {{PLURAL:$1|задание|заданий|задания}}]). Рекомендуется отложить редактирование категории, пока обновление не будет завершено, чтобы избежать прерывания обновления или противоречивых настроек.",
+ "smw-category-invalid-value-assignment": "«$1» — не является действительной семантической аннотацией или заданием категории.",
"protect-level-smw-pageedit": "Разрешить только участникам, имеющим право на редактирование страниц (Semantic MediaWiki)",
+ "smw-create-protection": "Пока действует [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode режим ограниченного доступа], создание свойства «$1» разрешено только пользователям с правами «$2» (или из [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups группы]).",
+ "smw-create-protection-exists": "Пока действует [https://www.semantic-mediawiki.org/wiki/Help:Authority_mode режим ограниченного доступа], изменение свойства «$1» разрешено только пользователям с правами «$2» (или из такой [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups группы]).",
+ "smw-edit-protection": "Эта страница [[Property:Is edit protected|защищена от изменений]], чтобы предотвратить нежелательное изменеие данных, и может редактироваться только пользователями с правами «$1» или из такой [https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups группы].",
+ "smw-edit-protection-disabled": "Режим защиты от редактирования выключен, следовательно свойство «$1» не может быть использовано для защиты страницы от редактирования.",
+ "smw-edit-protection-auto-update": "Уровень защиты страницы изменён на основании значения свойства «Is edit protected».",
"smw-edit-protection-enabled": "Редактировать страницы (Semantic MediaWiki)",
+ "smw-patternedit-protection": "Эта страница защищена и может редактироваться только пользователями с правами <code>smw-patternedit</code> (см. ''[https://www.semantic-mediawiki.org/wiki/Help:Permissions разрешения]'').",
+ "smw-property-predefined-edip": "«$1» — предопределённое свойство, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]'', хранящее признак защиты от редактирования.",
+ "smw-property-predefined-long-edip": "Хотя любой участник может установить это свойство на страницу, только участники с особыми полномочиями смогут изменить или удалить защиту после того, как она будет установлена.",
"smw-query-reference-link-label": "Ссылка на запрос",
"smw-format-datatable-emptytable": "Данные отсутствуют в таблице",
"smw-format-datatable-info": "Отображение записей от _START_ до _END_ с _TOTAL_",
@@ -654,27 +767,45 @@
"smw-format-datatable-toolbar-export": "Экспорт",
"smw-format-list-other-fields-open": " (",
"smw-format-list-other-fields-close": ")",
+ "smw-category-invalid-redirect-target": "Категория «$1» содержит некорректное перенаправление в иное пространство имён.",
+ "apihelp-smwinfo-summary": "Модуль API для получения информации о статистике Semantic MediaWiki и другой метаинформации.",
+ "apihelp-ask-summary": "Модуль API для запроса Semantic MediaWiki с использованием языка запросов.",
+ "apihelp-askargs-summary": "Модуль API для запроса Semantic MediaWiki с использованием языка запросов в качестве списка условий, распечаток и параметров.",
+ "apihelp-browsebyproperty-summary": "Модуль API для получения информации о свойстве или списке свойств.",
+ "apihelp-browsebysubject-summary": "Модуль API для получения информации о предмете.",
+ "apihelp-smwtask-summary": "Модуль API для выполнения задач, связанных с Semantic MediaWiki.",
+ "apihelp-smwbrowse-summary": "Модуль API для поддержки действий просмотра для различных типов объектов в Semantic MediaWiki.",
"smw-api-invalid-parameters": "Недопустимые параметры, \"$1\"",
+ "smw-property-page-list-count": "$1 {{PLURAL:$1|страница|страниц|страницы}}, использующих это свойство.",
+ "smw-property-page-list-search-count": "$1 {{PLURAL:$1|страница|страниц|страницы}}, на которых для свойства установлено значение «$2».",
"smw-property-reserved-category": "Категория",
"smw-category": "Категория",
+ "smw-datavalue-uri-invalid-scheme": "«$1» не указан, как допустимый протокол URI",
"smw-browse-property-group-title": "Группа свойств",
"smw-browse-property-group-label": "Метка группы свойств",
"smw-browse-property-group-description": "Описание группы свойств",
+ "smw-property-predefined-ppgr": "«$1» — предопределённое свойство, отмечающее сущности (в основном, категории), используемые для группировки свойств, предоставляемое ''[https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki]''.",
"smw-filter": "Фильтр",
"smw-section-expand": "Раскрыть раздел",
"smw-section-collapse": "Свернуть раздел",
+ "smw-ask-format-help-link": "Формат [https://www.semantic-mediawiki.org/wiki/Help:$1_format $1]",
"smw-help": "Справка",
+ "smw-cheat-sheet": "Шпаргалка",
+ "smw-personal-jobqueue-watchlist": "Список наблюдения (очередь заданий)",
"smw-property-predefined-label-skey": "Ключ сортировки",
"smw-processing": "Обработка…",
"smw-types-title": "Тип: $1",
"smw-schema-namespace-editcontentmodel-disallowed": "Изменение контентной модели [https://www.semantic-mediawiki.org/wiki/Help:Schema страницы схемы] не разрешено.",
"smw-schema-namespace-edit-protection": "Эта страница защищена, править её могут только участники с [https://www.semantic-mediawiki.org/wiki/Help:Permissions правом] <code>smw-schemaedit</code>.",
"smw-schema-error": "Ошибка проверки",
+ "smw-schema-error-violation": "Нарушение («$1», «$2»)",
"smw-schema-title": "Схема",
"smw-schema-type": "Тип",
"smw-property-predefined-schema-desc": "«$1» — это предварительно определенное свойство, содержащее описание схемы, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-property-predefined-schema-def": "«$1» — это предварительно определенное свойство, которое описывает содержимое схемы, и обеспечивается [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki].",
"smw-ask-title-keyword-type": "Поиск по ключевым словам",
+ "smw-remote-source-unavailable": "\nНевозможно подключиться к удаленной цели «$1».",
+ "smw-remote-source-disabled": "Источник '' '$1' '' отключил поддержку удаленного запроса!",
"smw-parameter-missing": "Параметр «$1» отсутствует.",
"smw-property-tab-usage": "Использование",
"smw-property-tab-redirects": "Синонимы",
@@ -682,5 +813,9 @@
"smw-property-tab-specification": "… ещё",
"smw-concept-tab-list": "Список",
"smw-concept-tab-errors": "Ошибки",
- "smw-ask-tab-code": "Код"
+ "smw-ask-tab-result": "Результат",
+ "smw-ask-tab-extra": "Дополнительно",
+ "smw-ask-tab-debug": "Отладка",
+ "smw-ask-tab-code": "Код",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/sr-ec.json b/www/wiki/extensions/SemanticMediaWiki/i18n/sr-ec.json
index 9393f118..cc47df30 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/sr-ec.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/sr-ec.json
@@ -18,6 +18,11 @@
"Zoranzoki21"
]
},
+ "smw-desc": "Чини вики приступачнијим — за машине „и” људе ([https://www.semantic-mediawiki.org/wiki/Help:User_manual документација на мрежи])",
+ "smw-title": "Семантички Медијавики",
+ "smw-upgrade-error-why-title": "Зашто видим ову грешку?",
+ "smw-upgrade-error-how-title": "Како да исправим ову грешку?",
+ "smw-semantics-not-enabled": "Функционалност Семантичког MediaWiki-ја није омогућена за овај вики.",
"smw_viewasrdf": "RDF фид",
"smw_finallistconjunct": " и",
"smw-factbox-head": "… више о страници „$1”",
@@ -30,6 +35,7 @@
"smw_multiple_concepts": "Свака страница концепта сме да има само једну дефиницију концепта.",
"smw_concept_cache_miss": "Концепт \"$1\" се тренутно не може користити, пошто конфигурација викија захтева да буде компутован офлајн.\nАко проблем не нестане за неко време, затражите од администратора сајта да учини овај концепт доступним.",
"smw_noinvannot": "На обртна својства не могу да се доделе вредности.",
+ "version-semantic": "Семантички додаци",
"smw_baduri": "URI-ји за облик „$1“ нису дозвољени.",
"smw_csv_link": "CSV",
"smw_json_link": "JSON",
@@ -37,11 +43,11 @@
"smw_printername_count": "Резултат бројања",
"smw_printername_csv": "CSV извоз",
"smw_printername_dsv": "DSV извоз",
- "smw_printername_debug": "Упит за пречишћавање (само за експерте)",
+ "smw_printername_debug": "Упит за отклањање грешака (за стручњаке)",
"smw_printername_embedded": "Угради садржај странице",
"smw_printername_json": "JSON извоз",
- "smw_printername_list": "Списак",
- "smw_printername_plainlist": "Обичан списак",
+ "smw_printername_list": "Листа",
+ "smw_printername_plainlist": "Обична листа",
"smw_printername_ol": "Набрајање",
"smw_printername_table": "Табела",
"smw_printername_broadtable": "Широка табела",
@@ -70,7 +76,7 @@
"smw_wrong_namespace": "Само странице из именског простора \"$1\" су дозвољене овде.",
"smw_manytypes": "Више од једног типа је дефинисано за ову особину.",
"smw_emptystring": "Празни стрингови нису прихватљиви.",
- "smw_notinenum": "„$1“ није на списку ($2) [[Property:Allows value|могућих вредности]] за особину „$3“.",
+ "smw_notinenum": "„$1” није на листи ($2) [[Property:Allows value|могућих вредности]] за својство „$3”.",
"smw_noboolean": "\"$1\" није препознат као Болова вредност (истинито/неистинито).",
"smw_true_words": "истинито, и, да, д",
"smw_false_words": "неистинито, н, не, н",
@@ -90,12 +96,13 @@
"smw_noqueryfeature": "Неки делови овог упита нису подржани на овом викију, те је део упита изостављен ($1).",
"smw_noconjunctions": "Конјукције у упитима нису подржане на овом викију, те је део упита изостављен ($1).",
"smw_nodisjunctions": "Дисјункције у упитима нису подржане на овом викију, те је део упита изостављен ($1).",
- "smw_querytoolarge": "Следеће услове упита није могуће разматрати због рестрикција викија за дужину и обим упита: $1.",
+ "smw_querytoolarge": "Није могуће разматрати {{PLURAL:$2|следећи услов упита $2|следеће услове упита $2}} због ограничења викија на величину и дубину упита: <code>$1</code>.",
"smw_notemplategiven": "Понудите вредност за параметар ”шаблон”, како би овај формат упита дао резултат.",
"smw_type_header": "Особине типа \"$1\"",
"smw_typearticlecount": "Приказ $1 {{PLURAL:$1|особине|особина}} за овај тип.",
"smw_attribute_header": "Странице које користе особину \"$1\"",
"smw_attributearticlecount": "Приказ $1 {{PLURAL:$1|странице|страница}} које користе ову особину.",
+ "smw-propertylist-subproperty-header": "Подсвојства",
"smw-propertylist-redirect-header": "Синоними",
"specialpages-group-smw_group": "Семантички Медијавики",
"exportrdf": "Извоз страница у RDF",
@@ -105,15 +112,19 @@
"smw_exportrdf_lastdate": "Не извози странице које нису мењане од датог момента.",
"smw_exportrdf_submit": "Извоз",
"uriresolver": "URI резолвер",
- "properties": "Особине",
+ "properties": "Својства",
"smw_properties_docu": "Следеће особине се користе на викију.",
"smw_property_template": "$1 типа $2 ($3 {{PLURAL:$3|употреба|употребе|употреба}})",
"smw_property_template_notype": "$1 ($2)",
"smw_propertylackspage": "Све особине требају имати описну страницу!",
"smw_propertylackstype": "Нема дефинисаног типа за ову особину (за сада усвајам тип $1).",
"smw_propertyhardlyused": "Ова особина једва да се користи на овом викију!",
+ "smw-special-property-searchform-options": "Опције",
"smw-special-wantedproperties-filter-label": "Филтер:",
+ "smw-special-wantedproperties-filter-none": "Ништа",
+ "smw-special-wantedproperties-filter-unapproved": "Неодобрено",
"concepts": "Концепти",
+ "smw-special-concept-header": "Листа концепата",
"unusedproperties": "Неискоришћене особине",
"smw-unusedproperties-docu": "Следеће особине постоје иако нема других страница које их користе.",
"smw-unusedproperty-template": "$1 типа $2",
@@ -122,14 +133,19 @@
"smw-wantedproperty-template": "$1 ($2 {{PLURAL:$2|употреба|употреба}})",
"smw_purge": "Освежи",
"types": "Типови",
- "smw_types_docu": "Списак [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes доступних врста података] са сваком [https://www.semantic-mediawiki.org/wiki/Help:Datatype врстом] представља јединствен скуп атрибута који описују вредност у смислу карактеристика чување и излагање које су наследне по додељеним својствима.",
+ "smw_types_docu": "Листа [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes доступних типова података] са сваким [https://www.semantic-mediawiki.org/wiki/Help:Datatype типом] представља јединствен скуп атрибута који описују вредност у смислу карактеристика чување и излагање које су наследне по додељеним својствима.",
+ "smw-statistics": "Семантичка статистика",
+ "smw-statistics-query-size": "Величина упита",
+ "smw-statistics-concept-count-legacy": "{{PLURAL:$1|Концепт|Концепти}}",
"ask": "Семантичка претрага",
"smw_ask_sortby": "Поређај у колоне (опционално)",
"smw_ask_ascorder": "Растући",
"smw_ask_descorder": "Опадајући",
+ "smw-ask-order-rand": "Случајно",
"smw_ask_submit": "Пронађи резултате",
"smw_ask_editquery": "Уреди упит",
"smw_add_sortcondition": "[Додај услове сортирања]",
+ "smw-ask-sort-add-action": "Додај услове сортирања",
"smw_ask_hidequery": "Сакриј упит (компактни приказ)",
"smw_ask_help": "Упит у странице помоћи",
"smw_ask_queryhead": "Услов",
@@ -142,17 +158,22 @@
"smw_ask_hide_embed": "Сакриј уградбени код",
"smw_ask_embed_instr": "За непосредно гнеждење овог упита у страницу викија, користи доњи код.",
"smw-ask-delete": "Уклони",
+ "smw-ask-sorting": "Сортирање",
+ "smw-ask-options": "Опције",
+ "smw-ask-options-sort": "Опције сортирања",
+ "smw-ask-format-options": "Формат и опције",
+ "smw-ask-parameters": "Параметри",
"smw-ask-search": "Претрага",
"smw-ask-result": "Резултат",
"smw-ask-empty": "Очисти све уносе",
"smw-ask-format": "Формат",
"smw-ask-query-search-info": "На упит <code><nowiki>$1</nowiki></code> одговорио је {{PLURAL:$3|1=<code>$2</code> (из кеша)|<code>$2</code> (из кеша)|<code>$2</code>}} за $4 {{PLURAL:$4|секунд|секунда|секунди}}.",
- "searchbyproperty": "Претрага по особинама",
+ "searchbyproperty": "Претрага по својствима",
"smw_sbv_docu": "Претражи све странице које поседују дату особину и вредност.",
"smw_sbv_novalue": "Унесите ваљану вредност за ову особину, или погледајте све вредности особине за \"$1\".",
- "smw_sbv_displayresult": "Списак свих страница које садрже особину \"$1\" са вредношћу \"$2\"",
- "smw_sbv_displayresultfuzzy": "Списак свих страница које садрже својство „$1” са вредношћу „$2”.\nПошто је пронађено само неколико резултата, такође су приказане приближне вредности.",
- "smw_sbv_property": "Особина:",
+ "smw_sbv_displayresult": "Листа свих страница које садрже својство „$1” са вредношћу „$2”",
+ "smw_sbv_displayresultfuzzy": "Листа свих страница које садрже својство „$1” са вредношћу „$2”.\nПошто је пронађено само неколико резултата, такође су приказане приближне вредности.",
+ "smw_sbv_property": "Својство:",
"smw_sbv_value": "Вредност:",
"smw_sbv_submit": "Пронађи резултате",
"browse": "Преглед викија",
@@ -160,13 +181,15 @@
"smw_browse_article": "Унесите име почетне странице за претрагу.",
"smw_browse_go": "Иди",
"smw_browse_more": "…",
- "smw_browse_show_incoming": "прикажи особине које вежу овде",
- "smw_browse_hide_incoming": "сакриј особине које вежу овде",
- "smw_browse_no_outgoing": "Ова страница нема особина.",
+ "smw_browse_show_incoming": "Прикажи долазна својства",
+ "smw_browse_hide_incoming": "Сакриј долазна својства",
+ "smw_browse_no_outgoing": "Ова страница нема својства.",
"smw_browse_no_incoming": "Нема особина које вежу на ову страницу.",
+ "smw-browse-show-group": "Прикажи групе",
+ "smw-browse-hide-group": "Сакриј групе",
"smw_inverse_label_default": "$1 од",
- "smw_inverse_label_property": "Реципрочна етикета особине",
- "pageproperty": "Страница за претрагу особина",
+ "smw_inverse_label_property": "Обрнута ознака својства",
+ "pageproperty": "Страница за претрагу својства",
"smw_pp_docu": "Претражи све вредности особине на датој страници.\nУнесите обоје, и страницу, и особину.",
"smw_pp_from": "Са странице:",
"smw_pp_type": "Својство:",
@@ -176,6 +199,7 @@
"smw_result_results": "Резултати",
"smw_result_noresults": "Нема резултата.",
"smwadmin": "Административне и одржавачке могућности",
+ "smw-admin-statistics-job-title": "Статистика послова",
"smw-admin-setupsuccess": "Машина за складиштење је постављена.",
"smw_smwadmin_return": "Назад на $1",
"smw_smwadmin_updatestarted": "Нов процес ажурирања за освежавање семантичких података је започет.\nСви сачувани подаци ће бити поново изграђени или поправљени по потреби.\nМожете да пратите ток ажурирања на овој посебној страници.",
@@ -183,7 +207,7 @@
"smw_smwadmin_updatestopped": "Сви постојећи процеси ажурирања су обустављени.",
"smw_smwadmin_updatenotstopped": "Како бисте обуставили покренути процес ажурирања, морате активирати контролни оквир да бисте потврдили да сте сигурни да желите да га обуставите.",
"smw-admin-docu": "Ова посебна страница вам помаже приликом инсталирања, ажурирања, одржавања и коришћења <a href=\"https://www.semantic-mediawiki.org\">Семантичког медијавикија</a> и такође обезбеђује додатне функције администрације и задатке, као и статистику.\nНе заборавите да направите копију вредних података пре него покренете функције администрације.",
- "smw-admin-db": "Одржавање базе података",
+ "smw-admin-db": "Подешавање базе података",
"smw-admin-dbdocu": "Семантички медијавики захтева неке додатке у бази података Медијавикија, како би се могли чувати семантички подаци.\nДоња функција потврђује да је ваша база података исправно инсталирана.\nПромене које су направљене у овом кораку немају последица за остали део базе података Медијавикија, а по потреби се могу врло лако поништити.\nОва функција инсталирања се може покретати више пута без бојазни да ће нанети неку штету, али је неопходна само једном приликом инсталирања или ажурирања.",
"smw-admin-permissionswarn": "Ако се операција заврши са SQL грешкама, корисник базе података (погледајте вашу LocalSettings.php датотеку) вероватно нема довољно дозвола за извршавање неопходних операција.\nИли дајте неопходне дозволе том кориснику како би могао да прави и брише табеле у бази, привремено се пријавите као корен базе података у LocalSettings.php датотеци, или користите скрипту за одржавање <code>setupStore.php</code>, која може користити акредитације администратора.",
"smw-admin-dbbutton": "Покретање или ажурирање табела",
@@ -208,33 +232,76 @@
"smw-admin-smwhomepage": "Потпуна корисничка документација за Семантички медијавики је на <b><a href=\"https://www.semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
"smw-admin-bugsreport": "Грешке могу да се пријављују на <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">пратиоцу грешака</a>. Страница „<a href=\"https://www.semantic-mediawiki.org/wiki/Help:Reporting_bugs\">Пријављивање грешака</a>” пружа неке смернице о томе како да напишете ефикасан извештај о грешци.",
"smw-admin-questions": "Ако имате даљих питања или предлога, укључите се у дискусију на <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">корисничком мејлинг списку Сематичког медијавикија</a> или <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">чет соби</a>.",
+ "smw-admin-other-functions": "Друге функције",
+ "smw-admin-supplementary-section-subtitle": "Основне функције",
+ "smw-admin-supplementary-settings-title": "Подешавања конфигурације",
+ "smw-admin-supplementary-operational-statistics-title": "Оперативна статистика",
+ "smw-admin-supplementary-operational-statistics-cache-title": "Статистика кеширања",
+ "smw-admin-supplementary-elastic-functions": "Подржане функције",
+ "smw-admin-supplementary-elastic-settings-title": "Подешавања",
"smw-admin-supplementary-elastic-mappings-summary": "Резиме",
+ "smw-admin-supplementary-elastic-statistics-title": "Статистика",
"smw_adminlinks_datastructure": "Структура података",
"smw_adminlinks_displayingdata": "Приказивање података",
"smw_adminlinks_inlinequerieshelp": "Помоћ за непосредне упите",
+ "smw-info-par-message": "Порука за приказ.",
"prefs-smw": "Семантички Медијавики",
"prefs-general-options": "Опште опције",
+ "smw-ui-tooltip-title-info": "Информације",
+ "smw-ui-tooltip-title-warning": "Упозорење",
+ "smw-ui-tooltip-title-error": "Грешка",
+ "smw-ui-tooltip-title-parameter": "Параметар",
+ "smw-ui-tooltip-title-event": "Догађај",
+ "smw-ui-tooltip-title-note": "Напомена",
+ "smw-ui-tooltip-title-legend": "Легенда",
+ "smw-ui-tooltip-title-reference": "Референца",
"smw_unknowntype": "„$1” тип овог својства је неважећи.",
"smw_concept_header": "Странице концепта \"$1\"",
"smw_conceptarticlecount": "Приказ $1 {{PLURAL:$1|странице|страница}} које припадају том концепту.",
"right-smw-admin": "приступање администраторским задацима (Семантички Медијавики)",
"action-smw-patternedit": "уређујете регуларне изразе које користи Семантички Медијавики",
+ "group-smwadministrator": "Администратори (Семантички Медијавики)",
+ "grouppage-smwadministrator": "{{ns:project}}:Администратори (Семантички Медијавики)",
+ "smw-sp-properties-header-label": "Листа својстава",
+ "smw-sp-admin-settings-button": "Генериши листу подешавања",
+ "smw-admin-idlookup-input": "Претрага:",
+ "smw-admin-objectid": "ID:",
+ "smw-admin-tab-general": "Преглед",
+ "smw-admin-tab-maintenance": "Одржавање",
+ "smw-admin-tab-supplement": "Допунске функције",
"smw-admin-tab-registry": "Регистар",
+ "smw-admin-maintenance-no-description": "Без описа.",
"smw-livepreview-loading": "Учитавам…",
+ "smw-sp-searchbyproperty-resultlist-header": "Листа резултата",
+ "smw-search-syntax": "Синтакса",
+ "smw-search-profile-tooltip": "Претражите функције у вези Семантичког Медијавикија",
+ "smw-search-profile-sort-title": "Наслов",
+ "smw-search-profile-extended-help-query-link": "(За више детаља $1).",
"smw-search-profile-extended-help-find-forms": "доступни облици",
+ "smw-search-profile-extended-section-sort": "Сортирај по",
+ "smw-search-profile-extended-section-form": "Обрасци",
"smw-search-profile-extended-section-namespace": "Именски простор",
+ "smw-search-profile-extended-section-query": "Упит",
+ "smw-search-profile-link-caption-query": "прикажи",
"smw-search-show": "Прикажи",
"smw-search-hide": "Сакриј",
+ "log-name-smw": "Дневник Семантичког Медијавикија",
+ "log-show-hide-smw": "$1 дневник Семантичког Медијавикија",
+ "logeventslist-smw-log": "Дневник Семантичког Медијавикија",
"smw-type-tab-properties": "Својства",
"smw-type-tab-types": "Типови",
"smw-type-tab-errors": "Грешке",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
"smw-limitreport-intext-parsertime": "[SMW] Време рашчлањивања унутартекстуалних анотација",
"smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|секунд|секунда|секунди}}",
+ "smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|секунд|секунде|секунди}}",
"smw-limitreport-pagepurge-storeupdatetime-value": "$1 {{PLURAL:$1|секунд|секунда|секунди}}",
- "smw-datavalue-allows-value-list-missing-marker": "Садржај списка „$1” нема ставке са * као ознаком списка.",
+ "smw-datavalue-allows-value-list-missing-marker": "Садржају листе „$1” недостају ставке са * као означивачем листе.",
"smw-datavalue-wikipage-invalid-title": "Унесена вредност типа странице „$1” садржи невалидне карактере или је некомплетна и стога може да узрокује неочекиване резултате током претраге или процеса означавања.",
"smw-datavalue-wikipage-property-invalid-title": "Својство „$1” (као тип странице) са унесеном вредношћу „$2” садржи невалидне карактере или је некомплетно и стога може да узрокује неочекиване резултате током претраге или процеса означавања.",
"smw-clipboard-copy-link": "Копирај везу на клипборд",
+ "smw-data-lookup": "Добављање података…",
"smw-no-data-available": "Нема података.",
"smw-format-datatable-emptytable": "Нема доступних података у табели",
"smw-format-datatable-info": "Приказ _START_ до _END_ од _TOTAL_ ставки",
@@ -252,6 +319,13 @@
"smw-format-datatable-previous": "Претходни",
"smw-format-datatable-sortascending": ": активирај за растуће сортирање колоне",
"smw-format-datatable-sortdescending": ": активирај за опадајуће сортирање колоне",
+ "smw-format-datatable-toolbar-export": "Извоз",
+ "smw-property-reserved-category": "Категорија",
+ "smw-category": "Категорија",
+ "smw-filter": "Филтер",
+ "smw-help": "Помоћ",
+ "smw-processing": "Обрађивање…",
+ "smw-types-title": "Тип: $1",
"smw-schema-error": "Грешка приликом провере ваљаности",
"smw-schema-error-violation": "Кршење („$1”, „$2”)",
"smw-schema-title": "Шема",
@@ -261,8 +335,9 @@
"smw-property-tab-redirects": "Синоними",
"smw-property-tab-subproperties": "Подсвојства",
"smw-property-tab-specification": "… више",
- "smw-concept-tab-list": "Списак",
+ "smw-concept-tab-list": "Листа",
"smw-concept-tab-errors": "Грешке",
"smw-ask-tab-extra": "Додатно",
- "smw-ask-tab-code": "Кôд"
+ "smw-ask-tab-code": "Кôд",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Помоћ:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/sr-el.json b/www/wiki/extensions/SemanticMediaWiki/i18n/sr-el.json
index c3b486b0..233f2665 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/sr-el.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/sr-el.json
@@ -7,42 +7,55 @@
"Rancher",
"Slaven Kosanovic",
"Sociologist",
- "Kghbln"
+ "Kghbln",
+ "Acamicamacaraca",
+ "Obsuser",
+ "Zoranzoki21"
]
},
- "smw_viewasrdf": "RDF dovod",
- "smw_finallistconjunct": ", i",
- "smw_factbox_head": "Činjenice o $1",
- "smw_isspecprop": "Ova osobina je posebna osobina na ovom vikiju.",
- "smw_concept_description": "Opis koncepta \"$1\"",
- "smw_no_concept_namespace": "Koncepte je jedino moguće definisati na stranicama u imenskom prostoru Concept:",
- "smw_multiple_concepts": "Svaka pojedinačna stranica koncepta, može sadržati definiciju samo jednog koncepta.",
+ "smw_viewasrdf": "RDF fid",
+ "smw_finallistconjunct": " i",
+ "smw-factbox-head": "… više o stranici „$1”",
+ "smw-factbox-facts": "Činjenice",
+ "smw_isspecprop": "Ovo svojstvo je posebno na ovom vikiju.",
+ "smw-concept-cache-header": "Upotreba keša",
+ "smw-concept-no-cache": "Nije dostupan keš.",
+ "smw_concept_description": "Opis koncepta „$1”",
+ "smw_no_concept_namespace": "Koncepti jedino mogu da se definišu na stranicama u imenskom prostoru Concept:",
+ "smw_multiple_concepts": "Svaka stranica koncepta sme da ima samo jednu definiciju koncepta.",
"smw_concept_cache_miss": "Koncept \"$1\" se trenutno ne može koristiti, pošto konfiguracija vikija zahteva da bude komputovan oflajn.\nAko problem ne nestane za neko vreme, zatražite od administratora sajta da učini ovaj koncept dostupnim.",
- "smw_noinvannot": "Vrednosti nije moguće pripisati inverznim osobinama.",
- "smw_baduri": "URI-ji oblika \"$1\", nisu prihvatljivi.",
+ "smw_noinvannot": "Na obrtna svojstva ne mogu da se dodele vrednosti.",
+ "smw_baduri": "URI-ji za oblik „$1“ nisu dozvoljeni.",
"smw_csv_link": "CSV",
"smw_json_link": "JSON",
"smw_rdf_link": "RDF",
- "smw_printername_count": "Izbroj rezultate",
+ "smw_printername_count": "Rezultat brojanja",
"smw_printername_csv": "CSV izvoz",
+ "smw_printername_dsv": "DSV izvoz",
"smw_printername_debug": "Upit za prečišćavanje (samo za eksperte)",
- "smw_printername_embedded": "Ugnezdi sadržaj stranice",
+ "smw_printername_embedded": "Ugradi sadržaj stranice",
"smw_printername_json": "JSON izvoz",
"smw_printername_list": "Spisak",
- "smw_printername_ol": "Enumeracija",
+ "smw_printername_plainlist": "Običan spisak",
+ "smw_printername_ol": "Nabrajanje",
"smw_printername_table": "Tabela",
"smw_printername_broadtable": "Široka tabela",
"smw_printername_template": "Šablon",
- "smw-paramdesc-limit": "Maksimalni broj rezultata koji će biti vraćeni",
+ "smw_printername_templatefile": "Datoteka šablona",
+ "smw_printername_rdf": "RDF izvoz",
+ "smw_printername_category": "Kategorija",
+ "validator-type-class-SMWParamSource": "tekst",
+ "smw-paramdesc-limit": "Najveći broj rezultata koji će biti vraćeni",
"smw-paramdesc-mainlabel": "Etiketa koja će se koristiti za ime glavne stranice",
"smw-paramdesc-link": "Prikaži vrednosti u obliku veza",
- "smw-paramdesc-intro": "Tekst koji treba da se prikaže prije rezultata upita (u slučaju potrebe)",
+ "smw-paramdesc-intro": "Tekst koji treba da se prikaže pre rezultata upita (u slučaju potrebe)",
"smw-paramdesc-outro": "Tekst koji treba da se prikaže iza rezultata upita (u slučaju potrebe)",
"smw-paramdesc-default": "Tekst koji treba da se prikaže u slučaju da upit nije dao rezultate",
- "smw-paramdesc-sep": "Razdvajač za vrednosti",
- "smw-paramdesc-columns": "Broj kolona u kojima će se prikazati rezultati (predodređeno $1)",
+ "smw-paramdesc-sep": "Razdvajač između rezultata",
+ "smw-paramdesc-columns": "Broj kolona u kojima će se prikazati rezultati",
"smw-paramdesc-embedonly": "Ne prikazuj zaglavlja",
"smw-paramdesc-searchlabel": "Tekst veze s rezultatima",
+ "smw-paramdesc-template-arguments": "Podešavanje isporuke imenovanih parametara do šablona",
"smw_iq_disabled": "Semantički upiti su onemogućeni na ovom vikiju.",
"smw_iq_moreresults": "... više rezultata",
"smw_parseerror": "Data vrednost nije shvaćena.",
@@ -72,16 +85,15 @@
"smw_noqueryfeature": "Neki delovi ovog upita nisu podržani na ovom vikiju, te je deo upita izostavljen ($1).",
"smw_noconjunctions": "Konjukcije u upitima nisu podržane na ovom vikiju, te je deo upita izostavljen ($1).",
"smw_nodisjunctions": "Disjunkcije u upitima nisu podržane na ovom vikiju, te je deo upita izostavljen ($1).",
- "smw_querytoolarge": "Sledeće uslove upita nije moguće razmatrati zbog restrikcija vikija za dužinu i obim upita: $1.",
+ "smw_querytoolarge": "Sledeće uslove upita nije moguće razmatrati zbog restrikcija vikija za dužinu i obim upita: <code>$1</code>.",
"smw_notemplategiven": "Ponudite vrednost za parametar ”šablon”, kako bi ovaj format upita dao rezultat.",
"smw_type_header": "Osobine tipa \"$1\"",
"smw_typearticlecount": "Prikaz $1 {{PLURAL:$1|osobine|osobina}} za ovaj tip.",
"smw_attribute_header": "Stranice koje koriste osobinu \"$1\"",
"smw_attributearticlecount": "Prikaz $1 {{PLURAL:$1|stranice|stranica}} koje koriste ovu osobinu.",
- "smw_subproperty_header": "Podosobine",
- "smw-subpropertylist-count": "Ova osobina sadrži {{PLURAL:$1|sledeću $1 podosobinu|sledeće $1 podosobine}}:",
+ "smw-propertylist-redirect-header": "Sinonimi",
"specialpages-group-smw_group": "Semantički Medijaviki",
- "exportrdf": "Izvezi stranice u RDF",
+ "exportrdf": "Izvoz stranica u RDF",
"smw_exportrdf_docu": "Ova stranica omogućava preuzimanje podataka s neke stranice u formatu RDF.\nDa biste izvezli stranice, unesite naslove u kućicu ispod (po jedan naslov u svakom redu).",
"smw_exportrdf_recursive": "Rekurzivno izvezi sve povezane stranice.\nObratite pažnju da rezultat može biti veoma obiman!",
"smw_exportrdf_backlinks": "Takođe izvezi sve stranice koje vežu na već izvezene stranice.\nGeneriše RDF koji je moguće pregledati.",
@@ -90,50 +102,56 @@
"uriresolver": "URI rezolver",
"properties": "Osobine",
"smw_properties_docu": "Sledeće osobine se koriste na vikiju.",
- "smw_property_template": "$1 tipa $2 ($3)",
+ "smw_property_template": "$1 tipa $2 ($3 {{PLURAL:$3|upotreba|upotrebe|upotreba}})",
"smw_property_template_notype": "$1 ($2)",
"smw_propertylackspage": "Sve osobine trebaju imati opisnu stranicu!",
"smw_propertylackstype": "Nema definisanog tipa za ovu osobinu (za sada usvajam tip $1).",
"smw_propertyhardlyused": "Ova osobina jedva da se koristi na ovom vikiju!",
+ "smw-special-wantedproperties-filter-label": "Filter:",
+ "concepts": "Koncepti",
"unusedproperties": "Neiskorišćene osobine",
- "smw_unusedproperties_docu": "Sledeće osobine postoje iako nema drugih stranica koje ih koriste.",
- "smw_unusedproperty_template": "$1 tipa $2",
+ "smw-unusedproperties-docu": "Sledeće osobine postoje iako nema drugih stranica koje ih koriste.",
+ "smw-unusedproperty-template": "$1 tipa $2",
"wantedproperties": "Tražene osobine",
- "smw_wantedproperties_docu": "Sledeće osobine se koriste na vikiju, ali još uvek nemaju svoju stranicu sa opisom.",
- "smw_wantedproperty_template": "$1 ($2 {{PLURAL:$2|upotreba|upotreba}})",
+ "smw-wantedproperties-docu": "Sledeće osobine se koriste na vikiju, ali još uvek nemaju svoju stranicu sa opisom.",
+ "smw-wantedproperty-template": "$1 ($2 {{PLURAL:$2|upotreba|upotreba}})",
"smw_purge": "Osveži",
"types": "Tipovi",
- "smw_types_docu": "Ovo je spisak svih vrsta podataka koji mogu da se dodeljuju svojstvima.",
-
-
+ "smw_types_docu": "Spisak [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes dostupnih vrsta podataka] sa svakom [https://www.semantic-mediawiki.org/wiki/Help:Datatype vrstom] predstavlja jedinstven skup atributa koji opisuju vrednost u smislu karakteristika čuvanje i izlaganje koje su nasledne po dodeljenim svojstvima.",
"ask": "Semantička pretraga",
- "smw_ask_sortby": "Sortiraj u kolone (opciono)",
+ "smw_ask_sortby": "Poređaj u kolone (opcionalno)",
"smw_ask_ascorder": "Rastući",
"smw_ask_descorder": "Opadajući",
"smw_ask_submit": "Pronađi rezultate",
"smw_ask_editquery": "Uredi upit",
"smw_add_sortcondition": "[Dodaj uslove sortiranja]",
- "smw_ask_hidequery": "Sakrij upit",
+ "smw_ask_hidequery": "Sakrij upit (kompaktni prikaz)",
"smw_ask_help": "Upit u stranice pomoći",
- "smw_ask_queryhead": "Upit",
- "smw_ask_printhead": "Dodatni podaci za prikaz",
+ "smw_ask_queryhead": "Uslov",
+ "smw_ask_printhead": "Izbor štampe",
"smw_ask_printdesc": "(dodaj jedno ime osobine po liniji)",
- "smw_ask_format_as": "Formatiraj kao:",
+ "smw_ask_format_as": "Oblikuj kao:",
"smw_ask_defaultformat": "podrazumevano",
- "smw_ask_otheroptions": "Ostale postavke",
- "smw_ask_show_embed": "Prikaži ugneždeni kod",
- "smw_ask_hide_embed": "Sakrij ugneždeni kod",
+ "smw_ask_otheroptions": "Druge opcije",
+ "smw_ask_show_embed": "Prikaži ugrađeni kod",
+ "smw_ask_hide_embed": "Sakrij ugradbeni kod",
"smw_ask_embed_instr": "Za neposredno gneždenje ovog upita u stranicu vikija, koristi donji kod.",
- "searchbyproperty": "Pretraži po osobinama",
+ "smw-ask-delete": "Ukloni",
+ "smw-ask-search": "Pretraga",
+ "smw-ask-result": "Rezultat",
+ "smw-ask-empty": "Očisti sve unose",
+ "smw-ask-format": "Format",
+ "smw-ask-query-search-info": "Na upit <code><nowiki>$1</nowiki></code> odgovorio je {{PLURAL:$3|1=<code>$2</code> (iz keša)|<code>$2</code> (iz keša)|<code>$2</code>}} za $4 {{PLURAL:$4|sekund|sekunda|sekundi}}.",
+ "searchbyproperty": "Pretraga po osobinama",
"smw_sbv_docu": "Pretraži sve stranice koje poseduju datu osobinu i vrednost.",
"smw_sbv_novalue": "Unesite valjanu vrednost za ovu osobinu, ili pogledajte sve vrednosti osobine za \"$1\".",
"smw_sbv_displayresult": "Spisak svih stranica koje sadrže osobinu \"$1\" sa vrednošću \"$2\"",
- "smw_sbv_displayresultfuzzy": "Spisak svih stranica koje sadrže osobinu \"$1\" sa vrednošću \"$2\".\nPošto je pronađeno samo nekoliko rezultata, takođe su prikazane približne vrednosti.",
+ "smw_sbv_displayresultfuzzy": "Spisak svih stranica koje sadrže svojstvo „$1” sa vrednošću „$2”.\nPošto je pronađeno samo nekoliko rezultata, takođe su prikazane približne vrednosti.",
"smw_sbv_property": "Osobina:",
"smw_sbv_value": "Vrednost:",
"smw_sbv_submit": "Pronađi rezultate",
- "browse": "Pregledaj viki",
- "smw_browselink": "Pregledaj osobine",
+ "browse": "Pregled vikija",
+ "smw_browselink": "Pregled svojstava",
"smw_browse_article": "Unesite ime početne stranice za pretragu.",
"smw_browse_go": "Idi",
"smw_browse_more": "…",
@@ -145,44 +163,101 @@
"smw_inverse_label_property": "Recipročna etiketa osobine",
"pageproperty": "Stranica za pretragu osobina",
"smw_pp_docu": "Pretraži sve vrednosti osobine na datoj stranici.\nUnesite oboje, i stranicu, i osobinu.",
- "smw_pp_from": "Od stranice",
- "smw_pp_type": "Osobina",
+ "smw_pp_from": "Sa stranice:",
+ "smw_pp_type": "Svojstvo:",
"smw_pp_submit": "Pronađeni rezultati",
- "smw_result_prev": "Prethodni",
- "smw_result_next": "Sledeće",
+ "smw_result_prev": "Prethodnih",
+ "smw_result_next": "Sledećih",
"smw_result_results": "Rezultati",
"smw_result_noresults": "Nema rezultata.",
- "smwadmin": "Upravljačke funkcije za Semantički medijaviki",
- "smw_smwadmin_setupsuccess": "Mašina za skladištenje je uspešno pokrenuta.",
+ "smwadmin": "Administrativne i održavačke mogućnosti",
+ "smw-admin-setupsuccess": "Mašina za skladištenje je postavljena.",
"smw_smwadmin_return": "Nazad na $1",
- "smw_smwadmin_updatestarted": "Započet je novi proces za obnavljanje semantičkih podataka.\nSvi sačuvani podaci će biti ponovo obnovljeni ili popravljeni po potrebi.\nMožete pratiti tok ažuriranja na ovoj posebnoj stranici.\n\nNazad na $1.",
- "smw_smwadmin_updatenotstarted": "Već je u toku jedan proces ažuriranja.\nNe pokrećite drugi.\n\nNazad na $1.",
- "smw_smwadmin_updatestopped": "Svi postojeći procesi ažuriranja su obustavljeni.\n\nNazad na $1.",
- "smw_smwadmin_updatenotstopped": "Kako biste obustavili pokrenuti proces ažuriranja, morate aktivirati kontrolni okvir da biste potvrdili da ste sigurni da želite da ga obustavite.\n\nNazad na $1.",
- "smw_smwadmin_docu": "Ova posebna stranica vam pomaže prilikom instaliranja i ažuriranja <a href=\"https://www.semantic-mediawiki.org\">Semantičkog medijavikija</a>.\nNe zaboravite da napravite kopiju vrednih podataka pre nego pokrenete funkcije administracije.",
- "smw_smwadmin_db": "Instaliranje i ažuriranje baze podataka",
- "smw_smwadmin_dbdocu": "Semantički medijaviki zahteva neke dodatke u bazi podataka Medijavikija, kako bi se mogli čuvati semantički podaci.\nDonja funkcija potvrđuje da je vaša baza podataka ispravno instalirana.\nPromene koje će se sada izvesti nemaju posledica za ostali deo baze podataka Medijavikija, a po potrebi se mogu vrlo lako poništiti.\nOva funkcija instaliranja se može pokretati više puta bez bojazni da će naneti neku štetu, ali je neophodna samo jednom prilikom instaliranja ili ažuriranja.",
- "smw_smwadmin_permissionswarn": "Ako se operacija završi sa SQL greškama, korisnik baze podataka (pogledajte vaš LocalSettings.php) verovatno nema dovoljno dozvola za izvršavanje neophodnih operacija.\nIli dajte neophodne dozvole tom korisniku kako bi mogao da pravi i briše tabele u bazi, privremeno se ulogujte kao root u LocalSettings.php, ili koristite skriptu za održavanje <tt>setupStore.php</tt>, koja može koristiti akreditaciju iz skripte LocalSettings.php.",
- "smw_smwadmin_dbbutton": "Pokretanje ili ažuriranje tabela baze podataka",
- "smw_smwadmin_announce": "Dojavite o postojanju vašeg vikija",
- "smw_smwadmin_datarefresh": "Popravljanje podataka i ažuriranje",
- "smw_smwadmin_datarefreshdocu": "Moguće je restaurirati sve podatke Semantičkog medijavikija, bazirajući se na sadržaju vikija.\nTo može biti korisno za reparaciju podataka ili obnavljanje podataka u slučaju da su se izvršile neke izmene u unutrašnjem formatu zbog nadogradnje softvera.\nAžuriranje će se obaviti stranicu po stranicu i neće se odmah završiti.\nSledeći prikaz služi za nadgledanje ažuriranja u progresu i omogućava vam da ih pokrenete ili obustavite (osim ako administrator sajta nije isključio ovu mogućnost).",
+ "smw_smwadmin_updatestarted": "Nov proces ažuriranja za osvežavanje semantičkih podataka je započet.\nSvi sačuvani podaci će biti ponovo izgrađeni ili popravljeni po potrebi.\nMožete da pratite tok ažuriranja na ovoj posebnoj stranici.",
+ "smw_smwadmin_updatenotstarted": "Već je u toku jedan proces ažuriranja.\nNe pokrećite drugi.",
+ "smw_smwadmin_updatestopped": "Svi postojeći procesi ažuriranja su obustavljeni.",
+ "smw_smwadmin_updatenotstopped": "Kako biste obustavili pokrenuti proces ažuriranja, morate aktivirati kontrolni okvir da biste potvrdili da ste sigurni da želite da ga obustavite.",
+ "smw-admin-docu": "Ova posebna stranica vam pomaže prilikom instaliranja, ažuriranja, održavanja i korišćenja <a href=\"https://www.semantic-mediawiki.org\">Semantičkog medijavikija</a> i takođe obezbeđuje dodatne funkcije administracije i zadatke, kao i statistiku.\nNe zaboravite da napravite kopiju vrednih podataka pre nego pokrenete funkcije administracije.",
+ "smw-admin-db": "Održavanje baze podataka",
+ "smw-admin-dbdocu": "Semantički medijaviki zahteva neke dodatke u bazi podataka Medijavikija, kako bi se mogli čuvati semantički podaci.\nDonja funkcija potvrđuje da je vaša baza podataka ispravno instalirana.\nPromene koje su napravljene u ovom koraku nemaju posledica za ostali deo baze podataka Medijavikija, a po potrebi se mogu vrlo lako poništiti.\nOva funkcija instaliranja se može pokretati više puta bez bojazni da će naneti neku štetu, ali je neophodna samo jednom prilikom instaliranja ili ažuriranja.",
+ "smw-admin-permissionswarn": "Ako se operacija završi sa SQL greškama, korisnik baze podataka (pogledajte vašu LocalSettings.php datoteku) verovatno nema dovoljno dozvola za izvršavanje neophodnih operacija.\nIli dajte neophodne dozvole tom korisniku kako bi mogao da pravi i briše tabele u bazi, privremeno se prijavite kao koren baze podataka u LocalSettings.php datoteci, ili koristite skriptu za održavanje <code>setupStore.php</code>, koja može koristiti akreditacije administratora.",
+ "smw-admin-dbbutton": "Pokretanje ili ažuriranje tabela",
+ "smw-admin-announce": "Najavite Vašu vikiju",
+ "smw-admin-deprecation-notice-title": "Napomene o zastarevanju",
+ "smw-admin-deprecation-notice-docu": "Sledeća sekcija sadrži podešavanja koja su zastarela ili su uklonjena ali su detektovana kao aktivna na ovoj Viki. Očekuje se da će se nekim budućim ažuriranjem ukloniti podrša za ova podešavanja.",
+ "smw-admin-deprecation-notice-config-notice": "<code>[https://www.semantic-mediawiki.org/wiki/Help:$1 $1]</code> je zastareo parametar i biće uklonjen u verziji $2",
+ "smw-admin-deprecation-notice-config-replacement": "<code>[https://www.semantic-mediawiki.org/wiki/Help:$1 $1]</code> je zamenjen parametar sa parametrom <code>[https://www.semantic-mediawiki.org/wiki/Help:$2 $2]</code>",
+ "smw-admin-deprecation-notice-config-removal": "<code>[https://www.semantic-mediawiki.org/wiki/Help:$1 $1]</code> je uklonjen parametar u verziji $2",
+ "smw-admin-deprecation-notice-title-notice": "Predstojeće promene",
+ "smw-admin-deprecation-notice-title-replacement": "Zamenjena ili preimenovana podešavanja",
+ "smw-admin-deprecation-notice-title-removal": "Uklonjena podešavanja",
+ "smw_smwadmin_datarefresh": "Popravljanje podataka",
+ "smw_smwadmin_datarefreshdocu": "Postoji mogućnost za vraćanje svih podataka semantičkog Medijavikija koji su zasnovani na trenutnom sadržaju vikija.\nOvo je korisno za ispravku oštećenih podataka ili za obnovu podataka ako je unutrašnji format promenjen kao rezultat dogradnje softvera.\nAžuriranje se vrši za svaku stranicu ponaosob, i treba da prođe neko vreme kako bi se sve vratilo u normalu.\nIspod je prikazano da li je ažuriranje u toku, a to vam omogućava da započnete ili zaustavite dogradnje (osim ako tu mogućnost nije isključio administrator).",
"smw_smwadmin_datarefreshprogress": "<strong>Jedno ažuriranje je već u toku.</strong>\nNormalno je da ažuriranje napreduje sporo, pošto se samo osvežavaju mali delovi podataka svaki put kada korisnik pristupi vikiju.\nDa bi se ovo ažuriranje brže završilo, možete pokrenuti skriptu za održavanje Medijavikija <code>runJobs.php</code> (koristite opciju <code>--maxjobs 1000</code> za ograničenje broja ažuriranja u jednom paketu).\nProcena napredovanja trenutnog ažuriranja:",
- "smw_smwadmin_datarefreshbutton": "Počni ažuriranje podataka",
+ "smw_smwadmin_datarefreshbutton": "Zakaži ponovnu igradnju podataka",
"smw_smwadmin_datarefreshstop": "Zaustavi ovo ažuriranje",
- "smw_smwadmin_datarefreshstopconfirm": "Da, siguran/-na sam",
- "smw_smwadmin_support": "Dobijanje podrške",
- "smw_smwadmin_supportdocu": "Postoji više mesta koja mogu pomoći u slučaju problema:",
- "smw_smwadmin_installfile": "Ako se nađete u problemima sa vašom instalacijom, pogledajte vodič u <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md#smw-installation\">fajlu INSTALL</a>.",
- "smw_smwadmin_smwhomepage": "Potpuna korisnička dokumentacija za Semantički medijaviki, nalazi se na sajtu <b><a href=\"http://semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
- "smw_smwadmin_mediazilla": "Bagovi se mogu prijavljivati na <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">Medijazilu</a>.",
- "smw_smwadmin_questions": "Ako imate daljih pitanja ili sugestija, uključite se u diskusiju na listi <a href=\"http://sourceforge.net/mailarchive/forum.php?forum_name=semediawiki-user\">Semantic MediaWiki user forum</a>.",
+ "smw_smwadmin_datarefreshstopconfirm": "Da, {{GENDER:$1|siguran|sigurna}} sam.",
+ "smw-admin-support": "Dobijanje podrške",
+ "smw-admin-supportdocu": "Obezbeđeni su razni resursi da bi vam pomogli u slučaju problemâ:",
+ "smw-admin-installfile": "Ako naiđete na problem pri instalaciji, najpre pročitajte smernice u <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md\">datoteci INSTALL</a> i <a href=\"https://www.semantic-mediawiki.org/wiki/Help:Installation\">stranici za instalaciju</a>.",
+ "smw-admin-smwhomepage": "Potpuna korisnička dokumentacija za Semantički medijaviki je na <b><a href=\"https://www.semantic-mediawiki.org\">semantic-mediawiki.org</a></b>.",
+ "smw-admin-bugsreport": "Greške mogu da se prijavljuju na <a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">pratiocu grešaka</a>. Stranica „<a href=\"https://www.semantic-mediawiki.org/wiki/Help:Reporting_bugs\">Prijavljivanje grešaka</a>” pruža neke smernice o tome kako da napišete efikasan izveštaj o grešci.",
+ "smw-admin-questions": "Ako imate daljih pitanja ili predloga, uključite se u diskusiju na <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">korisničkom mejling spisku Sematičkog medijavikija</a> ili <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">čet sobi</a>.",
+ "smw-admin-supplementary-elastic-mappings-summary": "Rezime",
"smw_adminlinks_datastructure": "Struktura podataka",
"smw_adminlinks_displayingdata": "Prikazivanje podataka",
"smw_adminlinks_inlinequerieshelp": "Pomoć za neposredne upite",
"prefs-smw": "Semantički Medijaviki",
- "smw_unknowntype": "Tip ovog svojstva je pogrešan.",
+ "prefs-general-options": "Opšte opcije",
+ "smw_unknowntype": "„$1” tip ovog svojstva je nevažeći.",
"smw_concept_header": "Stranice koncepta \"$1\"",
"smw_conceptarticlecount": "Prikaz $1 {{PLURAL:$1|stranice|stranica}} koje pripadaju tom konceptu.",
- "smw-livepreview-loading": "Učitavam…"
+ "right-smw-admin": "pristupanje administratorskim zadacima (Semantički Medijaviki)",
+ "action-smw-patternedit": "uređujete regularne izraze koje koristi Semantički Medijaviki",
+ "smw-admin-tab-registry": "Registar",
+ "smw-livepreview-loading": "Učitavam…",
+ "smw-search-profile-extended-help-find-forms": "dostupni oblici",
+ "smw-search-profile-extended-section-namespace": "Imenski prostor",
+ "smw-search-show": "Prikaži",
+ "smw-search-hide": "Sakrij",
+ "smw-type-tab-properties": "Svojstva",
+ "smw-type-tab-types": "Tipovi",
+ "smw-type-tab-errors": "Greške",
+ "smw-limitreport-intext-parsertime": "[SMW] Vreme raščlanjivanja unutartekstualnih anotacija",
+ "smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|sekund|sekunda|sekundi}}",
+ "smw-limitreport-pagepurge-storeupdatetime-value": "$1 {{PLURAL:$1|sekund|sekunda|sekundi}}",
+ "smw-datavalue-allows-value-list-missing-marker": "Sadržaj spiska „$1” nema stavke sa * kao oznakom spiska.",
+ "smw-datavalue-wikipage-invalid-title": "Unesena vrednost tipa stranice „$1” sadrži nevalidne karaktere ili je nekompletna i stoga može da uzrokuje neočekivane rezultate tokom pretrage ili procesa označavanja.",
+ "smw-datavalue-wikipage-property-invalid-title": "Svojstvo „$1” (kao tip stranice) sa unesenom vrednošću „$2” sadrži nevalidne karaktere ili je nekompletno i stoga može da uzrokuje neočekivane rezultate tokom pretrage ili procesa označavanja.",
+ "smw-clipboard-copy-link": "Kopiraj vezu na klipbord",
+ "smw-no-data-available": "Nema podataka.",
+ "smw-format-datatable-emptytable": "Nema dostupnih podataka u tabeli",
+ "smw-format-datatable-info": "Prikaz _START_ do _END_ od _TOTAL_ stavki",
+ "smw-format-datatable-infoempty": "Prikaz 0 do 0 od 0 stavki",
+ "smw-format-datatable-infofiltered": "(filtrirano od _MAX_ ukupno stavki)",
+ "smw-format-datatable-infothousands": ".",
+ "smw-format-datatable-lengthmenu": "Prikaži _MENU_ stavki",
+ "smw-format-datatable-loadingrecords": "Učitavanje...",
+ "smw-format-datatable-processing": "Obrada...",
+ "smw-format-datatable-search": "Pretraga:",
+ "smw-format-datatable-zerorecords": "Nema nađenih odgovarajućih podataka",
+ "smw-format-datatable-first": "Prvi",
+ "smw-format-datatable-last": "Poslednji",
+ "smw-format-datatable-next": "Sledeći",
+ "smw-format-datatable-previous": "Prethodni",
+ "smw-format-datatable-sortascending": ": aktiviraj za rastuće sortiranje kolone",
+ "smw-format-datatable-sortdescending": ": aktiviraj za opadajuće sortiranje kolone",
+ "smw-schema-error": "Greška prilikom provere valjanosti",
+ "smw-schema-error-violation": "Kršenje („$1”, „$2”)",
+ "smw-schema-title": "Šema",
+ "smw-schema-type": "Tip",
+ "smw-schema-tag": "{{PLURAL:$1|Oznaka|Oznake}}",
+ "smw-property-tab-usage": "Upotreba",
+ "smw-property-tab-redirects": "Sinonimi",
+ "smw-property-tab-subproperties": "Podsvojstva",
+ "smw-property-tab-specification": "… više",
+ "smw-concept-tab-list": "Spisak",
+ "smw-concept-tab-errors": "Greške",
+ "smw-ask-tab-extra": "Dodatno",
+ "smw-ask-tab-code": "Kôd"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/sv.json b/www/wiki/extensions/SemanticMediaWiki/i18n/sv.json
index ead9f205..9217168f 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/sv.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/sv.json
@@ -32,12 +32,16 @@
},
"smw-desc": "Gör din wiki mer tillgänglig – för både maskiner och människor ([https://www.semantic-mediawiki.org/wiki/Help:User_manual dokumentation online])",
"smw-title": "Semantic MediaWiki",
+ "smw-upgrade-error-why-title": "Varför ser jag detta fel?",
+ "smw-upgrade-error-how-title": "Hur fixar jag detta fel?",
"smw-semantics-not-enabled": "Semantic MediaWiki-funktionalitet är inte aktiverad på denna wiki.",
"smw_viewasrdf": "RDF-matning",
"smw_finallistconjunct": "och",
"smw-factbox-head": "... mer om \"$1\"",
"smw-factbox-facts": "Fakta",
"smw-factbox-facts-help": "Visar påståenden och fakta som en användare har skapat",
+ "smw-factbox-attachments": "Bilagor",
+ "smw-factbox-attachments-help": "Visa tillgängliga bilagor",
"smw_isspecprop": "Den här egenskapen är en specialegenskap på den här wikin.",
"smw-concept-cache-header": "Cacheanvändning",
"smw-concept-cache-count": "[https://www.semantic-mediawiki.org/wiki/Help:Concept_cache_count Konceptcachen] innehåller {{PLURAL:$1|'''en''' entitet|'''$1''' entiteter}} ($2).",
@@ -113,6 +117,7 @@
"smw-paramdesc-feeddescription": "Texten som ska användas som beskrivning av feeden",
"smw-paramdesc-feedpagecontent": "Sidinnehåll som ska visas tillsammans med feeden",
"smw-label-feed-description": "$1 $2-feed",
+ "smw-paramdesc-mimetype": "Mediatypen (MIMI-typen) för utmatningsfilen",
"smw_iq_disabled": "Beklagar. Semantiska sökning har slagits av på den här wikin.",
"smw_iq_moreresults": "… ytterligare resultat",
"smw_parseerror": "Det angivna värdet förstods inte.",
@@ -307,8 +312,8 @@
"smw_smwadmin_updatenotstopped": "För att avsluta uppdaterings-processen måste du aktivera kryss-rutan.",
"smw-admin-docu": "Denna specialsida hjälper dig under installation, uppgradering, underhåll och användning av <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWiki</a> och tillhandahåller också ytterligare administrativa funktioner och uppgifter, såväl som statistik.\nKom ihåg att säkerhetskopiera värdefull data innan du kör administrativa funktioner!",
"smw-admin-environment": "Programvarumiljö",
- "smw-admin-db": "Databasunderhåll",
- "smw-admin-dbdocu": "Semantic MediaWiki kräver några tillägg i MediaWiki-databasen för att kunna lagra semantiska data.\nFunktionen nedan ser till att din databas konfigureras korrekt.\nÄndringarna som görs i detta steg påverkar inte resten av MediaWiki-databasen, och kan lätt göras ogjorda om så önskas.\nDenna installationsfunktion kan köras flera gånger utan att orsaka någon skada, men det är bara nödvändigt att köra den en gång vid installation eller uppgradering.",
+ "smw-admin-db": "Inställning av databas",
+ "smw-admin-dbdocu": "Semantic's Mediawiki kräver sin egen databas-struktur (och är oberoende från Mediawiki vilket inte påverkar resten av Mediawiki-installationen) för att kunna lagra semantic-datan.\nDet här installationsfunktionen kan exekveras flerfaldiga gånger utan att det gör någon skada, men det behövs endast en gång i installation eller uppgradering.",
"smw-admin-permissionswarn": "Om operationen misslyckas och visar SQL-fel så har din användare för databasen (kolla inställningarna i filen \"LocalSettings.php\") förmodligen inte tillräckliga rättigheter.\nDet finns tre sätt att åtgärda detta: Ge rättigheter till användaren att skapa och radera tabeller, ändra temporärt användaren till ''root'' i \"LocalSettings.php\", eller använd underhålls-scriptet <code>setupStore.php</code>, vilken kan använda rättigheterna för en administratör.",
"smw-admin-dbbutton": "Initialisera eller uppgradera tabeller",
"smw-admin-announce": "Meddela att din wiki finns",
@@ -337,7 +342,7 @@
"smw-admin-questions": "Om du har ytterligare frågor eller förslag, diskutera dem på <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">Semantic MediaWiki användarsändlista</a>!",
"smw-admin-other-functions": "Andra funktioner",
"smw-admin-supplementary-section-title": "Extra funktioner",
- "smw-admin-supplementary-section-subtitle": "Tillgängliga funktioner",
+ "smw-admin-supplementary-section-subtitle": "Kärnfunktioner",
"smw-admin-supplementary-section-intro": "Vissa av de listades funktionerna i detta avsnitt kan vara begränsade och är därför otillgängliga på denna wiki.",
"smw-admin-supplementary-settings-title": "Konfigurationsinställningar",
"smw-admin-supplementary-operational-statistics-title": "Driftstatistik",
@@ -418,8 +423,11 @@
"smw-admin-idlookup-input": "Sök:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "Översikt",
- "smw-admin-tab-rebuild": "Underhåll",
+ "smw-admin-tab-maintenance": "Underhåll",
"smw-admin-tab-registry": "Register",
+ "smw-admin-maintenance-no-description": "Ingen beskrivning.",
+ "smw-admin-maintenance-script-section-title": "Lista över tillgängliga underhållsskript",
+ "smw-admin-maintenance-script-section-intro": "Följande underhållsskript kräver en administratör och åtkomst till kommandoraden för att kunna utföra listade skript.",
"smw-livepreview-loading": "Laddar…",
"smw-sp-searchbyproperty-description": "Denna sida erbjuder ett enkelt [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces navigeringsgränssnitt] för att hitta entiteter som beskrivs av en egenskap och ett namngivet värde. Andra tillgängliga sökgränssnitt inkluderar [[Special:PageProperty|sidegenskapssök]] och [[Special:Ask|ask-förfrågningsbyggare]].",
"smw-sp-searchbyproperty-resultlist-header": "Lista med resultat",
@@ -433,8 +441,11 @@
"smw-search-profile-sort-recent": "Senaste",
"smw-search-profile-sort-title": "Titel",
"smw-search-profile-extended-help-query": "Länk till: $1",
+ "smw-search-profile-extended-help-query-link": "(För mer detaljer $1).",
+ "smw-search-profile-extended-help-find-forms": "tillgängliga formulär",
"smw-search-profile-extended-section-sort": "Sortera efter",
"smw-search-profile-extended-section-form": "Formulär",
+ "smw-search-profile-extended-section-search-syntax": "Sökinmatning",
"smw-search-profile-extended-section-namespace": "Namnrymd",
"smw-search-profile-extended-section-query": "Förfrågan",
"smw-search-profile-link-caption-query": "se",
@@ -461,6 +472,9 @@
"smw-type-tab-types": "Typer",
"smw-type-tab-errors": "Fel",
"smw-type-primitive": "Grundläggande",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
+ "smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
"smw-types-extra-mlt-lcode": "Datatypen {{PLURAL:$2|kräver inte}} en språkkod (t.ex. {{PLURAL:$2|ett värde utan en språkkod accepteras inte}}).",
"smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|sekund|sekunder}}",
"smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|sekund|sekunder}}",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/uk.json b/www/wiki/extensions/SemanticMediaWiki/i18n/uk.json
index 7592e7c7..08895df3 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/uk.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/uk.json
@@ -25,6 +25,11 @@
},
"smw-desc": "Робить вашу вікі доступнішою — для машин ''та'' людей ([https://www.semantic-mediawiki.org/wiki/Help:User_manual довідка в мережі])",
"smw-title": "Семантична MediaWiki",
+ "smw-upgrade-error": "Семантичну MediaWiki встановлено й увімкнено, але вона не має належного [https://www.semantic-mediawiki.org/wiki/Help:Upgrade ключа оновлення], який відповідав би: <code>$1</code>.",
+ "smw-upgrade-error-why-title": "Чому я бачу цю помилку?",
+ "smw-upgrade-error-why-explain": "Внутрішня структура бази даних Семантичної MediaWiki змінилася і потребує деякого коригування, щоб повноцінно функціювати. Цьому може бути декілька причин, серед яких:\n* Додано додаткові фіксовані властивості (необхідні додаткові налаштування таблиць)\n* Оновлення містить якісь зміни до таблиць або індекси, що роблять перехоплення обов'язковим перед отриманням доступу до даних",
+ "smw-upgrade-error-how-title": "Як мені виправити цю помилку?",
+ "smw-upgrade-error-how-explain": "Адміністраторові (чи будь-якій особі з адміністративними правами) треба або запустити [https://www.mediawiki.org/wiki/Manual:Update.php update.php] MediaWiki, або скрипт обслуговування [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] Семантичної MediaWiki. Також можна звіритися з такими сторінками, щоб дізнатися більше:\n* Інструкції щодо [https://www.semantic-mediawiki.org/wiki/Help:Installation встановлення]\n* Сторінка довідки на тему [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting вирішення проблем]",
"smw-semantics-not-enabled": "Функціонал Семантичного Медіавікі не ввімкнено в цій вікі.",
"smw_viewasrdf": "вивід RDF",
"smw_finallistconjunct": " і",
@@ -117,6 +122,7 @@
"smw-paramdesc-feeddescription": "Текст, який необхідно використовувати як опис каналу",
"smw-paramdesc-feedpagecontent": "Вміст сторінки буде відображатися з каналу",
"smw-label-feed-description": "$1 $2 канал",
+ "smw-paramdesc-mimetype": "Тип медіафайлу (тип MIME) для файлу на виході",
"smw_iq_disabled": "Семантичні запити було вимкнено у цій вікі.",
"smw_iq_moreresults": "... подальші результати",
"smw_parseerror": "Вказане значення — незрозуміле.",
@@ -126,6 +132,8 @@
"smw_manytypes": "Для властивості означено більше одного типу даних.",
"smw_emptystring": "Використовувати пусті рядки не дозволяється.",
"smw_notinenum": "«$1» не є у списку ($2) [[Property:Allows value|дозволених значень]] для властивості «$3».",
+ "smw-datavalue-constraint-error-allows-value-list": "«$1» немає в списку ($2) [[Property:Allows value|дозволених значень]] для властивості «$3».",
+ "smw-datavalue-constraint-error-allows-value-range": "«$1» не перебуває в межах діапазону «$2», вказаного в обмеженні [[Property:Allows value|дозволених значень]] для властивості «$3».",
"smw_noboolean": "«$1» не розпізнається як булове значення (значення «так/ні»).",
"smw_true_words": "true,t,yes,y,так,т",
"smw_false_words": "false,f,no,n,ні,н",
@@ -191,7 +199,7 @@
"smw-special-concept-count": "{{PLURAL:$1|Наступне поняття|$1 наступні поняття|$1 наступних понять}} {{PLURAL:$1|перераховане|переховані|перераховано}}.",
"smw-special-concept-empty": "Поняття не знайдено.",
"unusedproperties": "Властивості, що не використовуються",
- "smw-unusedproperties-docu": "На цій сторінці перераховані [https://www.semantic-mediawiki.org/wiki/Unused_properties невикористані властивості], які були оголошені, хоча ніякі інші сторінки працюють. Для диференційованого підходу див. у [[Special:Properties|весь]] або [[Special:WantedProperties|параметрів]] спеціальні сторінки.",
+ "smw-unusedproperties-docu": "На цій сторінці перераховані [https://www.semantic-mediawiki.org/wiki/Unused_properties невикористані властивості], які були оголошені, хоча ніякі інші сторінки їх не використовують. Для диференційованого вигляду див. спеціальні сторінки [[Special:Properties|всіх]] або [[Special:WantedProperties|потрібних властивостей]].",
"smw-unusedproperty-template": "$1 із типом даних $2",
"wantedproperties": "Потрібні властивості",
"smw-wantedproperties-docu": "На цій сторінці перелічені [https://www.semantic-mediawiki.org/wiki/Wanted_properties бажані властивості], які використовуються у вікі, але не мають сторінки опису. Диференційований показ див. на спеціальних сторінках [[Special:Properties|усіх]] або [[Special:UnusedProperties|невикористовуваних властивостей]].",
@@ -202,7 +210,7 @@
"smw-purge-failed": "Не вдалось оновити",
"types": "Типи",
"smw_types_docu": "Список [https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes доступних типів даних], де кожен [https://www.semantic-mediawiki.org/wiki/Help:Datatype тип] репрезентує унікальний набір атрибутів, що описують значення з точки зору характеристик зберігання й відображення, похідних від присвоєної властивості.",
- "smw-special-types-no-such-type": "Указаного типу даних не існує",
+ "smw-special-types-no-such-type": "\"$1\" невідомий або не був указаний як правильний тип даних.",
"smw-statistics": "Семантична статистика",
"smw-statistics-property-instance": "{{PLURAL:$1|1= Значення|Значення}} властивості (всього)",
"smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|Властивість|Властивості|Властивостей}}]] (всього)",
@@ -323,9 +331,9 @@
"smw_smwadmin_updatenotstopped": "Щоб зупинити запущений процес оновлення, Ви маєте поставити позначку, аби засвідчити, що ви справді впевнені в цьому.",
"smw-admin-docu": "Ця сторінка допоможе при встановленні, оновленні, обслуговуванні та використанню <a href=\"https://www.semantic-mediawiki.org\">Семантичної MediaWiki</a>, а також забезпечує подальші адміністративні функції і завдання, так само як і статистику. Не забудьте зробити резервну копію всіх важливих даних перед запуском адміністративних функцій.",
"smw-admin-environment": "Оболонка програмного забезпечення",
- "smw-admin-db": "Обслуговування бази даних",
+ "smw-admin-db": "Налаштування бази даних",
"smw-admin-db-preparation": "Триває ініціалізація таблиці, і це може зайняти трохи часу, перед тим як результати буде виведено, залежно від розміру та ймовірної оптимізації таблиці.",
- "smw-admin-dbdocu": "Семантична MediaWiki потребує деяких розширень бази даних, щоб могти зберігати семантичну інформацію. Подана нижче функція забезпечує правильне налаштування бази даних. Зміни, котрі вона вносить, не зачіпають решти бази даних MediaWiki, та можуть бути легко скасовані. Хоча цю функцію безпечно запускати кілька разів, її використання потрібне лише один раз для встановлення чи оновлення.",
+ "smw-admin-dbdocu": "Семантична MediaWiki вимагає своєї власної структури бази даних (і є незалежною від MediaWiki, тож не впливає на решту інсталяції MediaWiki) для зберігання семантичних даних.\nЦю функцію налаштування можна виконувати багато разів без жодної шкоди, але насправді вона необхідна лише раз — під час встановлення чи оновлення.",
"smw-admin-permissionswarn": "Якщо ця операція буде зупинена через помилки SQL, вірогідною причиною може бути відсутність необхідних прав користувача, під іменем якого вікі під'єднується до бази даних (він вказується у файлі «LocalSettings.php»). В такому випадку вам необхідно або дозволити цьому користувачу створювати та вилучати таблиці БД, або тимчасово ввести в файл «LocalSettings.php» ім'я користувача БД «root», або використати сценарій обслуговування <code>setupStore.php</code>, який може використовувати облікові дані адміністратора.",
"smw-admin-dbbutton": "Ініціалізація або оновлення таблиць",
"smw-admin-announce": "Заявити про Вашу вікі",
@@ -352,7 +360,7 @@
"smw_smwadmin_datarefreshbutton": "Почати оновлення даних",
"smw_smwadmin_datarefreshstop": "Зупинити це оновлення",
"smw_smwadmin_datarefreshstopconfirm": "Так, я впевнен{{GENDER:$1|ий|а}}.",
- "smw-admin-job-scheduler-note": "Більшість дій у цьому розділі виконуються як завдання, щоб уникнути глухих кутів у ході їх виконання. [https://www.mediawiki.org/wiki/Manual:Job_queue Планувальник завдань] відповідальний за процес, тому критично важливо, щоб скрипт обслуговування <code>runJobs.php</code> (див. також параметр конфігурації <code>$wgRunJobsAsync</code>) мав відповідну спроможність.",
+ "smw-admin-job-scheduler-note": "Завдання (ті, що увімкнені) у цьому розділі виконуються через чергу завдань, щоб уникнути глухих кутів у ході їх виконання. [https://www.mediawiki.org/wiki/Manual:Job_queue Черга завдань] відповідальна за обробку, тому критично важливо, щоб скрипт обслуговування мав відповідну спроможність <code>runJobs.php</code> (див. також параметр конфігурації <code>$wgRunJobsAsync</code>).",
"smw-admin-outdateddisposal-title": "Ліквідація застарілих сутностей",
"smw-admin-outdateddisposal-intro": "Деякі дії (зміна типу властивості, вилучення вікісторінок чи виправлення помилкових значень) спричинять появу [https://www.semantic-mediawiki.org/wiki/Outdated_entities застарілих сутностей], тому рекомендується час від часу вилучати їх, щоб звільняти простір у пов'язаній таблиці. Залежно від часового інтервалу, визначеного планувальником завдань, процес очищення може зайняти деякий час перед тим, як завдання буде виконано і завершено. Залежно від вікна часу, визначеного планувальником завдань, процес виправлення може зайняти деякий час перед тим, як завдання буде виконано й завершено.",
"smw-admin-outdateddisposal-active": "Було заплановано завдання з ліквідації застарілих сутностей.",
@@ -374,7 +382,7 @@
"smw-admin-questions": "Якщо у вас є додаткові запитання чи побажання, приєднуйтесь до обговорень на <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">поштовій розсилці для користувачів Семантичної MediaWiki</a>, або в <a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">чат-кімнаті</a>.",
"smw-admin-other-functions": "Інші функції",
"smw-admin-supplementary-section-title": "Додаткові функції",
- "smw-admin-supplementary-section-subtitle": "Доступні функції",
+ "smw-admin-supplementary-section-subtitle": "Основні функції",
"smw-admin-supplementary-section-intro": "У цьому розділі подано додаткові функції поза цілями підтримки, і може бути, що деякі з функцій, перелічених [https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions документації], будуть обмежені або недоступні у цій вікі.",
"smw-admin-supplementary-settings-title": "Параметри конфігурації",
"smw-admin-supplementary-settings-intro": "<u>$1</u> виводить збірний список доступних параметрів, що використовуються у Семантичній MediaWiki",
@@ -384,13 +392,37 @@
"smw-admin-supplementary-idlookup-intro": "<u>$1</u> містить функції для пошуку й розташування окремих сутностей",
"smw-admin-supplementary-duplookup-title": "Дубльовані сутності",
"smw-admin-supplementary-duplookup-intro": "<u>$1</span> для переліку записів, які класифікуються як такі, що містять дублікати у таблиці сутностей",
+ "smw-admin-supplementary-duplookup-docu": "Ця сторінка перелічує записи з [https://www.semantic-mediawiki.org/wiki/Help:Entity_table таблиці сутностей], категоризовані як дублікати. Дублікати записів можуть з'являтися лише в рідкісних випадках (або й узагалі ніколи), потенційно спричинені передчасно завершеним процесом під час оновлення бази даних чи невдалої транзакції відкоту.",
+ "smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
"smw-admin-supplementary-operational-statistics-cache-title": "Статистика кешу",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> Показати кеш-дотичну статистику",
- "smw-admin-supplementary-elastic-intro": "<u>$1</u> інформує про налаштування та статистику кешу",
- "smw-admin-supplementary-elastic-functions": "Доступні функції",
+ "smw-admin-supplementary-elastic-title": "Elasticsearch",
+ "smw-admin-supplementary-elastic-section-subtitle": "Функції Elasticsearch",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> показує налаштування та статистику індексу",
+ "smw-admin-supplementary-elastic-docu": "Ця сторінка містить інформацію про налаштування, мапування, здоров'я, а також статистику індексу, пов'язані з кластером Elasticsearch, який поєднаний із Семантичною MediaWiki та її [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>].",
+ "smw-admin-supplementary-elastic-functions": "Підтримувані функції",
"smw-admin-supplementary-elastic-settings-title": "Налаштування",
+ "smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> використовується Elasticsearch для керування індексами Семантичної MediaWiki",
+ "smw-admin-supplementary-elastic-mappings-title": "Мапування",
+ "smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u> для перелічення індексів і мапувань полів",
+ "smw-admin-supplementary-elastic-mappings-docu": "Ця сторінка містить подробиці щодо мапувань полів, використовуваних з поточними індексами. Підсумок мапування слід прослідковувати у зв'язку з <code>index.mapping.total_fields.limit</code>, що зазначає максимальну кількість полів у індексі.",
+ "smw-admin-supplementary-elastic-mappings-summary": "Підсумок",
+ "smw-admin-supplementary-elastic-mappings-fields": "Мапування полів",
+ "smw-admin-supplementary-elastic-nodes-title": "Вузли",
+ "smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u> показує статистику вузлів",
+ "smw-admin-supplementary-elastic-indices-title": "Індекси",
+ "smw-admin-supplementary-elastic-indices-intro": "<u>$1</u> надає загальний огляд доступних індексів та їхню статистику",
"smw-admin-supplementary-elastic-statistics-title": "Статистика",
+ "smw-admin-supplementary-elastic-statistics-intro": "<u>$1</u> показує статистику рівня індексів",
+ "smw-admin-supplementary-elastic-statistics-docu": "Ця сторінка дає загальне уявлення про статистику індексів для різних операцій, що відбуваються на рівні індексів; статистика, що виводиться, збирається шляхом праймеріз та загальних агрегацій. [https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-stats.html Сторінка довідки] містить детальний опис доступної статистики індексів.",
+ "smw-admin-supplementary-elastic-status-replication": "Статус реплікації",
+ "smw-admin-supplementary-elastic-status-last-active-replication": "Остання активна реплікація: $1",
"smw-admin-supplementary-elastic-status-refresh-interval": "Інтервал оновлення: $1",
+ "smw-admin-supplementary-elastic-status-recovery-job-count": "Затримка завдань з відновлення: $1 (приблизно)",
+ "smw-admin-supplementary-elastic-status-file-ingest-job-count": "Затримка завдань із вживання (файл): $1 (приблизно)",
+ "smw-admin-supplementary-elastic-status-rebuild-lock": "Реплікацію заблоковано: $1 (перебудова у процесі)",
+ "smw-list-count": "Список містить $1 {{PLURAL:$1|запис|записи|записів}}.",
+ "smw-list-count-from-cache": "Список містить $1 {{PLURAL:$1|запис|записи|записів}}, і його було отримано з кешу (UTC: $2).",
"smw-property-label-uniqueness": "Назва «$1» збігається принаймні з одним іншим представленням властивості. Будь ласка, проконсультуйтеся зі [https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness сторінкою довідки], щоб дізнатись, як вирішити цю проблему.",
"smw-property-label-similarity-title": "Звіт про подібність назв властивостей",
"smw-property-label-similarity-intro": "<u>$1</u> обчислює подібності наявних назв властивостей",
@@ -418,9 +450,15 @@
"prefs-ask-options": "Опції Special:Ask",
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/ Семантична Медіавікі] (та пов'язані розширення), забезпечують можливість індивідуальних налаштувань для обраних функцій. Для отримання додаткової інформації, будь ласка, перегляньте цю [http://semantic-mediawiki.org/wiki/Help:User_preferences сторінку довідки].",
"smw-prefs-ask-options-tooltip-display": "Показувати текст параметра як інформаційну підказку",
+ "smw-prefs-ask-options-compact-view-basic": "Увімкнути базовий компактний режим перегляду",
+ "smw-prefs-help-ask-options-compact-view-basic": "Якщо увімкнено, показує зменшений набір посилань у компактному режимі перегляду Special:Ask.",
"smw-prefs-general-options-time-correction": "Увімкнути коригування часу для спеціальних сторінок за допомогою локального налаштування [[Special:Preferences#mw-prefsection-rendering|часового зміщення]]",
+ "smw-prefs-general-options-jobqueue-watchlist": "Показувати на моїй персональній панелі список спостереження за чергою завдань",
+ "smw-prefs-help-general-options-jobqueue-watchlist": "Якщо увімкнено, показує [https://www.semantic-mediawiki.org/wiki/Help:Job_queue_watchlist список] обраних завдань, що очікують своєї черги, разом із приблизними розмірами черги.",
"smw-prefs-general-options-disable-editpage-info": "Вимкнути вступний текст на сторінці редагування",
- "smw-prefs-general-options-suggester-textinput": "Увімкнути [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance асистента вводу] для пропозицій семантичних сутностей",
+ "smw-prefs-general-options-disable-search-info": "Вимкнути довідкову інформацію про синтаксис на стандартній сторінці пошуку",
+ "smw-prefs-general-options-suggester-textinput": "Увімкнути підтримку вводу для семантичних сутностей",
+ "smw-prefs-help-general-options-suggester-textinput": "Якщо увімкнено, дає змогу використовувати [https://www.semantic-mediawiki.org/wiki/Help:Input_assistance підтримку вводу] для пошуку властивостей, концептів та категорій у контексті введеного пошукового запиту.",
"smw-ui-tooltip-title-property": "Властивість",
"smw-ui-tooltip-title-quantity": "Конверсія одиниць",
"smw-ui-tooltip-title-info": "Інформація",
@@ -432,7 +470,7 @@
"smw-ui-tooltip-title-note": "Примітка",
"smw-ui-tooltip-title-legend": "Легенда",
"smw-ui-tooltip-title-reference": "Посилання на джерело",
- "smw_unknowntype": "Для цього властивості вказано некоректний тип",
+ "smw_unknowntype": "Тип \"$1\" для цієї властивості некоректний",
"smw-concept-cache-text": "Поняття має $1 {{PLURAL:$1|сторінку|сторінки|сторінок}}, і востаннє було оновлено $3, $2.",
"smw_concept_header": "Сторінки, що належать до концепції «$1»",
"smw_conceptarticlecount": "{{PLURAL:$1|1=Показана|Показані}} нижче $1 {{PLURAL:$1|сторінка|сторінки|сторінок}}.",
@@ -465,21 +503,34 @@
"smw-sp-properties-header-label": "Список властивостей",
"smw-admin-settings-docu": "Відображає список всіх стандартних і локалізованих налаштувань, які мають стосунок до середовища Семантичної MediaWiki. За детальною інформацією про окремі параметри зверніться до сторінки довідки щодо [https://www.semantic-mediawiki.org/wiki/Help:Configuration налаштувань].",
"smw-sp-admin-settings-button": "Створити список налаштувань",
- "smw-admin-idlookup-title": "Пошук ідентифікатора об'єкта",
- "smw-admin-idlookup-docu": "Цей розділ показує технічні подробиці про окрему сутність (вікісторінку, підоб'єкт, властивість тощо) в Семантичній MediaWiki. Введені дані можуть бути ідентифікатором або рядком, відповідно до обраного поля. Зверніть увагу, що будь-яке посилання на ідентифікатор не слід плутати з ідентифікатором версії чи сторінки у MediaWiki.",
- "smw-admin-iddispose-title": "Ліквідація ідентифікатора",
+ "smw-admin-idlookup-title": "Пошук",
+ "smw-admin-idlookup-docu": "Цей розділ показує технічні подробиці про окрему сутність (вікісторінку, підоб'єкт, властивість тощо) в Семантичній MediaWiki. Введені дані можуть бути числовим ідентифікатором або рядковим значенням, відповідно до поля пошуку, проте будь-яке посилання на ідентифікатор стосується Семантичної MediaWiki, а не ідентифікатора версії чи сторінки в MediaWiki.",
+ "smw-admin-iddispose-title": "Ліквідація",
"smw-admin-iddispose-docu": "Зверніть увагу, що операція з ліквідації не обмежена і призведе до вилучення ідентифікатора внутрішнього об'єкта з рушія бази даних після підтвердження. Будь ласка, виконуйте цю дію '''обережно''' і лише після того, як ознайомитеся з [https://www.semantic-mediawiki.org/wiki/Help:Object_ID_disposal документацією].",
"smw-admin-iddispose-done": "ID «$1» вилучено з бекенду бази даних.",
- "smw-admin-iddispose-references": "Ідентифікатор «$1» із принаймні одним активним записом табличного посилання.",
+ "smw-admin-iddispose-references": "Ідентифікатор \"$1\" {{PLURAL:$2|не має активних посилань|має щонайменше одне активне посилання}}:",
"smw-admin-iddispose-references-multiple": "Список збігів із принаймні одним активним записом посилання.",
- "smw-admin-iddispose-no-references": "Ідентифікатор «$1» не знайдено, або ж він не містив жодного посилання.",
+ "smw-admin-iddispose-no-references": "Пошук не зміг зіставити \"$1\" з елементом таблиці.",
"smw-admin-idlookup-input": "Пошук:",
"smw-admin-objectid": "Ідентифікатор:",
"smw-admin-tab-general": "Огляд",
"smw-admin-tab-notices": "Сповіщення про застарілість",
- "smw-admin-tab-rebuild": "Технічне обслуговування",
+ "smw-admin-tab-maintenance": "Обслуговування",
"smw-admin-tab-supplement": "Додаткові функції",
"smw-admin-tab-registry": "Реєстр",
+ "smw-admin-maintenance-no-description": "Немає опису.",
+ "smw-admin-maintenance-script-section-title": "Список доступних скриптів обслуговування",
+ "smw-admin-maintenance-script-section-intro": "Подані скрипти обслуговування вимагають прав адміністратора й доступу до командного рядка, щоб можна було виконувати перелічені скрипти.",
+ "smw-admin-maintenance-script-description-dumprdf": "RDF-експорт існуючих трійок.",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "Цей скрипт використовується для керування кешем концептів для Семантичної вікі, де він може створювати, вилучити й оновлювати вибраний кеш.",
+ "smw-admin-maintenance-script-description-rebuilddata": "Відтворює всі семантичні дані в базі даних шляхом швидкого аналізу всіх сторінок, які можуть мати семантичні дані.",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "Відбудовує індекс Elasticsearch (для інсталяцій, які використовують <code>ElasticStore</code>) шляхом швидкого аналізу всіх сутностей, які мають семантичні дані.",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "Відбудовує індекс повнотекстового пошуку <code>SQLStore</code> (для інсталяцій, у яких це налаштування увімкнено).",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "Відбудовує статистику використання для всіх сутностей властивостей.",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "Вилучає дублікати сутностей, виявлені у вибраних таблицях, які не мають активних посилань на джерела.",
+ "smw-admin-maintenance-script-description-setupstore": "Встановлює бекенд сховища, вибраний у <code>LocalSettings.php</code>.",
+ "smw-admin-maintenance-script-description-updateentitycollation": "Оновлює поле <code>smw_sort</code> у <code>SQLStore</code> (відповідно до налаштування [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation $smwgEntityCollation]).",
+ "smw-admin-maintenance-script-description-populatehashfield": "Заповнює поле <code>smw_hash</code> для рядків, які не мають відповідного значення.",
"smw-livepreview-loading": "Завантаження…",
"smw-sp-searchbyproperty-description": "На цій сторінці розміщено простий [https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces інтерфейс перегляду] для пошуку сутностей, описаних властивістю й іменним значенням. До інших доступних пошукових інтерфейсів належать [[Special:PageProperty|пошук властивостей сторінки]] та [[Special:Ask|майстер запитів ask]].",
"smw-sp-searchbyproperty-resultlist-header": "Список результатів",
@@ -494,7 +545,23 @@
"smw-editpage-concept-annotation-enabled": "Цей концепт можна розширити з використанням парсерної функції #concept. Опис, як використовувати #concept, див. на довідковій сторінці про [https://www.semantic-mediawiki.org/wiki/Help:Concepts концепт].",
"smw-search-syntax-support": "Пошукові запити підтримують [https://www.semantic-mediawiki.org/wiki/Help:Semantic_search синтаксис семантичних запитів] для пошуку результатів з використанням Семантичної MediaWiki.",
"smw-search-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance Асистента вводу] також увімкнено для полегшення попереднього вибору доступних властивостей і категорій.",
+ "smw-search-help-intro": "Введення <code><nowiki>[[ ... ]]</nowiki></code> повідомить процесорові вводу, що він має скористатися бекендом пошуку Семантичної MediaWiki. Слід зауважити, що поєднання <code><nowiki>[[ ... ]]</nowiki></code> з неструктурованим текстовим пошуком, таке як <code><nowiki>[[ ... ]] OR Lorem ipsum</nowiki></code> не підтримується.",
+ "smw-search-help-structured": "Структурований пошук:\n\n*<code><nowiki>[[Category:Lorem ipsum]]</nowiki></code>, <code><nowiki>[[Has number::123]]</nowiki></code> (як [https://www.semantic-mediawiki.org/wiki/Help:Search#Filter_context фільтрований контекст])\n\n*<code><nowiki>[[Has text::~*lorem*]]</nowiki></code> (із [https://www.semantic-mediawiki.org/wiki/Help:Search#Query_context контекстом запиту])",
+ "smw-search-help-proximity": "Приблизний пошук (коли властивість невідома, доступно '''лише''' для тих бекендів, які забезпечують інтеграцію повнотекстового пошуку):\n\n*<code><nowiki>[[in:lorem ipsum]]</nowiki></code> (пошук «lorem» та «ipsum» у всіх індексованих документах)\n\n* <code><nowiki>[[phrase:lorem ipsum]]</nowiki></code> (пошук збігів «lorem ipsum» як цілісної фрази)",
+ "smw-search-help-ask": "Подані посилання пояснять, як користуватися синтаксисом <code>#ask</code>.\n\n* [https://www.semantic-mediawiki.org/wiki/Help:Selecting_pages Вибір сторінок] — описує, як вибирати сторінки й будувати умови\n\n*[https://www.semantic-mediawiki.org/wiki/Help:Search_operators Пошукові оператори] — перелічує доступні пошукові оператори, включно з тими, що використовуються для пошуку в діапазоні, а також запитами з використанням пошукових шаблонів (wildcards)",
+ "smw-search-input": "Введення тексту й пошук",
+ "smw-search-help-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance Підтримка вводу] надається для поля вводу і вимагає використання одного з таких префіксів:\n\n*<code>p:</code> для увімкнення пропозицій властивостей (напр., <code><nowiki>[[p:Has ...</nowiki></code>)\n\n*<code>c:</code> для увімкнення пропозицій категорій\n\n*<code>con:</code> для увімкнення пропозицій концептів",
"smw-search-syntax": "Синтаксис",
+ "smw-search-profile": "Додатково",
+ "smw-search-profile-tooltip": "Функції пошуку у зв'язку із Семантичною MediaWiki",
+ "smw-search-profile-sort-best": "Найкращий збіг",
+ "smw-search-profile-sort-recent": "Найновіші",
+ "smw-search-profile-sort-title": "Назва",
+ "smw-search-profile-extended-help-intro": "[https://www.semantic-mediawiki.org/wiki/Help:SMWSearch/Extended_profile Розширений профііль] спеціальної сторінки Special:Search надає доступ до пошукових функцій, специфчних для Семантичної MediaWiki та її підтримуваного бекенду запитів.",
+ "smw-search-profile-extended-help-sort": "Встановлює налаштування сортування для показу результатів:",
+ "smw-search-profile-extended-help-sort-title": "* «Назва» використовуватиме назву сторінки (чи назву, яку використовується для показу) як критерій сортування",
+ "smw-search-profile-extended-help-sort-recent": "* «Найновіші» покаже спершу сутності, які недавно хтось змінював (підоб'єктні сутності буде приховано, оскільки вони не анотуються за допомогою [[Property:Modification date|дати редагування]])",
+ "smw-search-profile-extended-help-sort-best": "* «Найкращий збіг» сортуватиме сутності за [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore/Relevancy відповідністю] на основі оцінок, які надає бекенд",
"log-name-smw": "Журнал Семантичної MediaWiki",
"log-show-hide-smw": "$1 журнал Семантичної MediaWiki",
"log-description-smw": "Діяльність щодо [https://www.semantic-mediawiki.org/wiki/Help:Logging увімкнених типів подій], яку реєструє Семантична MediaWiki та її компоненти.",
@@ -520,7 +587,7 @@
"smw-query-condition-circular": "Можливу циклічну умову було виявлено у «$1».",
"smw-types-list": "Список типів даних",
"smw-types-default": "«$1» є вбудованим типом даних.",
- "smw-types-help": "Подальшу інформацію і приклади можна знайти на [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 сторінці довідки].",
+ "smw-types-help": "Подальшу інформацію і приклади можна знайти на цій [https://www.semantic-mediawiki.org/wiki/Help:Type_$1 сторінці довідки].",
"smw-type-anu": "«$1» — це варіант типу даних [[Special:Types/URL|URL]] і здебільшого використовується для експортної декларації ''owl:AnnotationProperty''.",
"smw-type-boo": "«$1» — це примітивний тип даних для опису значення істина/хиба.",
"smw-type-cod": "«$1» — це варіант типу даних [[Special:Types/Text|Текст]] для використання у технічних текстах довільної довжини, таких як списки вихідного коду.",
@@ -669,5 +736,27 @@
"smw-property-page-list-search-count": "Показано $1 {{PLURAL:$1|сторінку, яка використовує|сторінки, які використовують|сторінок, які використовують}} цю властивість зі збігом значення «$2».",
"smw-property-reserved-category": "Категорія",
"smw-category": "Категорія",
- "smw-help": "Допомога"
+ "smw-help": "Допомога",
+ "smw-ask-title-keyword-type": "Пошук за ключовим словом",
+ "smw-ask-message-keyword-type": "Цей пошук відповідає умові <code><nowiki>$1</nowiki></code>.",
+ "smw-remote-source-unavailable": "Не вдалося під'єднатись до віддаленої цілі «$1».",
+ "smw-remote-source-disabled": "Джерело '''$1''' вимкнуло підтримку віддалених запитів!",
+ "smw-remote-source-unmatched-id": "Джерело '''$1''' не відповідає версії Семантичної MediaWiki, яка має підтримку віддалених запитів.",
+ "smw-remote-request-note": "Результат отримано із віддаленого джерела '''$1''', і є ймовірність, що згенерований контент містить інформацію, недоступну в межах поточної вікі.",
+ "smw-remote-request-note-cached": "Результат '''кешовано''' з віддаленого джерела '''$1''', і є ймовірність, що згенерований контент містить інформацію, недоступну в межах поточної вікі.",
+ "smw-parameter-missing": "Відсутній параметр «$1».",
+ "smw-property-tab-usage": "Використання",
+ "smw-property-tab-redirects": "Синоніми",
+ "smw-property-tab-subproperties": "Підвластивості",
+ "smw-property-tab-errors": "Неналежні призначення",
+ "smw-property-tab-specification": "... більше",
+ "smw-concept-tab-list": "Список",
+ "smw-concept-tab-errors": "Помилки",
+ "smw-ask-tab-result": "Результат",
+ "smw-ask-tab-extra": "Додатково",
+ "smw-ask-tab-debug": "Налагодження",
+ "smw-ask-tab-code": "Код",
+ "smw-install-incomplete-intro": "Встановлення (чи оновлення) <b>Семантичної MediaWiki</b> не завершено, і треба, щоб якийсь адміністратор запустив подані завдання, щоб запобігти невідповідності даних, перед тим, як користувачі почнуть створювати чи змінювати контент сайту.",
+ "smw-install-incomplete-populate-hash-field": "Заповнення полів <code>smw_hash</code> було пропущено під час встановлення; необхідно виконати скрипт [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php].",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hans.json b/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hans.json
index 5bba4222..5943e927 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hans.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hans.json
@@ -28,7 +28,8 @@
"Hanyanbo98",
"夢蝶葬花",
"A Chinese Wikipedian",
- "Phenolla"
+ "Phenolla",
+ "Angrydog001"
]
},
"smw-desc": "让您更亲近wiki——对机器''与''人都是如此([https://www.semantic-mediawiki.org/wiki/Help:User_manual 在线文档])",
@@ -337,7 +338,7 @@
"smw_smwadmin_updatenotstopped": "请勾选复选框,以确认确实希望终止正在运行的升级进程。",
"smw-admin-docu": "此特殊页面在您安装、升级、维护与使用<a href=\"https://www.semantic-mediawiki.org\">语义MediaWiki</a>时提供帮助,并进一步提供管理功能和任务,以及统计。请记住,在执行管理功能前备份贵重数据。",
"smw-admin-environment": "软件环境",
- "smw-admin-db": "数据库维护",
+ "smw-admin-db": "数据库设置",
"smw-admin-db-preparation": "表格初始化正在进行,并在显示结果前可能持续一段时间,正在等待大小及可能的表格优化。",
"smw-admin-dbdocu": "语义MediaWiki需要对MediaWiki数据库做一些扩展,以存储语义数据。以下功能可确保您的数据库被适当配置。这个步骤所做的修改不会影响MediaWiki数据库的其他部分,如果需要,可以方便地撤销所做的修改。这个设置功能可多次执行,不会造成任何危害,但是只需在安装或升级时执行一次即可。",
"smw-admin-permissionswarn": "如果操作因SQL错误而失败,可能是您wiki的数据库用户(检查您的“LocalSettings.php”文件)没有相应权限。您可以向该用户赋予创建和删除表格的权限,或临时将数据库根用户的登录信息输入至您的“LocalSettings.php”文件。您也可以使用维护脚本<code>setupStore.php</code>,这个脚本可以使用管理员的信息。",
@@ -405,7 +406,7 @@
"smw-admin-supplementary-elastic-title": "Elasticsearch",
"smw-admin-supplementary-elastic-intro": "<u>$1</u>告知有关设置和索引统计",
"smw-admin-supplementary-elastic-docu": "此页面包含有关Elasticsearch集群相关的设置、映射、健康和索引统计信息,该集群连接到语义MediaWiki及其[https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>]。",
- "smw-admin-supplementary-elastic-functions": "可用函数",
+ "smw-admin-supplementary-elastic-functions": "支持的功能",
"smw-admin-supplementary-elastic-settings-title": "设置",
"smw-admin-supplementary-elastic-settings-intro": "<u>$1</u>由Elasticsearch使用以管理语义MediaWiki指数",
"smw-admin-supplementary-elastic-mappings-title": "映射",
@@ -513,9 +514,10 @@
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "概览",
"smw-admin-tab-notices": "弃用通告",
- "smw-admin-tab-rebuild": "维护",
"smw-admin-tab-supplement": "补充函数",
"smw-admin-tab-registry": "注册",
+ "smw-admin-maintenance-no-description": "无描述",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "重新生成所有属性实体的使用统计信息。",
"smw-livepreview-loading": "正在载入...",
"smw-sp-searchbyproperty-description": "此页面提供一个简单的[https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces 浏览界面]用于发现一个属性和一个命名值定义的实体。其他可用搜索界面包括[[Special:PageProperty|页面属性搜索]]和[[Special:Ask|询问查询生成器]]。",
"smw-sp-searchbyproperty-resultlist-header": "结果列表",
@@ -597,6 +599,7 @@
"smw-type-txt": "“$1”是一个描述任意长度字符串的原始数据类型。",
"smw-type-dat": "“$1”是一个代表统一格式的时间点的数据类型。",
"smw-type-ema": "“$1”是以电子邮件之殊,体。",
+ "smw-type-rec": "“$1”是一个容器数据类型,它以固定的顺序指定类型化属性的列表。",
"smw-type-tab-properties": "属性",
"smw-type-tab-types": "样式",
"smw-type-tab-errors": "错误",
@@ -778,6 +781,7 @@
"smw-schema-error": "验证错误",
"smw-schema-type-help-link": "https://www.semantic-mediawiki.org/wiki/Help:Schema/Type/$1",
"smw-schema-type": "类型",
+ "smw-schema-tag": "{{PLURAL:$1|标签|标签}}",
"smw-ask-title-keyword-type": "关键词搜索",
"smw-ask-message-keyword-type": "此搜索匹配<code><nowiki>$1</nowiki></code>条件。",
"smw-remote-source-unavailable": "无法连接远程“$1”目标。",
diff --git a/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hant.json b/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hant.json
index 099d4ffe..58f6943a 100644
--- a/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hant.json
+++ b/www/wiki/extensions/SemanticMediaWiki/i18n/zh-hant.json
@@ -33,16 +33,21 @@
"A Chinese Wikipedian"
]
},
- "smw-desc": "讓您的 Wiki 更易於取得所需的資料 - 不論是對機器''與''人類\n([https://www.semantic-mediawiki.org/wiki/Help:User_manual 線上說明文件])",
- "smw-title": "語義 MediaWiki",
- "smw-semantics-not-enabled": "語義 MediaWiki 功能沒有為此 wiki 啟用。",
+ "smw-desc": "讓您的 Wiki 更容易使用 - 不論是對於機器''或''人類([https://www.semantic-mediawiki.org/wiki/Help:User_manual 線上說明文件])",
+ "smw-title": "Semantic MediaWiki",
+ "smw-upgrade-error": "Semantic MediaWiki 已安裝完並且已啟用,但缺少符合:<code>$1</code> 的相稱[https://www.semantic-mediawiki.org/wiki/Help:Upgrade 更新鍵]。",
+ "smw-upgrade-error-why-title": "為什麼我會看到此錯誤。",
+ "smw-upgrade-error-why-explain": "Semantic MediaWiki 的內部資料庫架構已更改,並且需要做出一些調整來讓功能齊全,這可能有包含以下數種原因:\n* 已添加額外固定屬性(需要額外表格設定)\n* 更新包含一些對於表格的變動,或是在存取資料之前索引有必要產生中斷",
+ "smw-upgrade-error-how-title": "我要如何修正此錯誤?",
+ "smw-upgrade-error-how-explain": "管理員(或是任何有管理權限的人)已執行 MediaWiki 的 [https://www.mediawiki.org/wiki/Manual:Update.php update.php] 或是 Semantic MediaWiki 的 [https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php setupStore.php] 維護手稿。您可以查閱以下頁面來獲得進一步協助:\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation 安裝]介紹\n* [https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting 狀況處理]說明頁面",
+ "smw-semantics-not-enabled": "Semantic MediaWiki 功能沒有為此 wiki 啟用。",
"smw_viewasrdf": "訂閱 RDF feed",
- "smw_finallistconjunct": " 和",
+ "smw_finallistconjunct": "和",
"smw-factbox-head": "...更多有關「$1」",
"smw-factbox-facts": "事實",
"smw-factbox-facts-help": "顯示由某一使用者所創建的聲明和事實",
"smw-factbox-facts-derived": "衍生的事實",
- "smw-factbox-facts-derived-help": "顯示衍生自規則的事實,或是在其他推理科技的幫助下生成的事實",
+ "smw-factbox-facts-derived-help": "顯示衍生自規則的實情,或是在其它推理技術幫助下所生成的實情",
"smw_isspecprop": "此屬性為此 Wiki 的特殊屬性。",
"smw-concept-cache-header": "暫存使用",
"smw-concept-cache-count": "[https://www.semantic-mediawiki.org/wiki/Help:Concept_cache_count 概念快取]包含 {{PLURAL:$1|'''1'''|'''$1'''}} 個實體($2)。",
@@ -73,7 +78,7 @@
"smw_printername_category": "類別",
"validator-type-class-SMWParamSource": "內容",
"smw-paramdesc-limit": "查詢結果數量上限",
- "smw-paramdesc-offset": "第一個結果的位置",
+ "smw-paramdesc-offset": "第一個結果的偏差",
"smw-paramdesc-headers": "顯示標頭/屬性名稱",
"smw-paramdesc-mainlabel": "主要頁面的標籤名稱",
"smw-paramdesc-link": "以連結顯示數值",
@@ -82,11 +87,12 @@
"smw-paramdesc-default": "查詢結果為空時顯示的文字",
"smw-paramdesc-sep": "結果之間的分隔符號",
"smw-paramdesc-propsep": "結果記錄的内容之間的分隔符號",
+ "smw-paramdesc-valuesep": "用於結果裡屬性值之間的分隔符號",
"smw-paramdesc-showsep": "顯示分隔符號於 CSV 檔案的頂端 (\"sep=<value>\")",
"smw-paramdesc-distribution": "顯示出現的次數,不顯示所有數值。",
"smw-paramdesc-distributionsort": "依出現次數排序數值分布。",
"smw-paramdesc-distributionlimit": "限制數值分佈只計算特殊數值。",
- "smw-paramdesc-aggregation": "指定聚合應與什麼相關",
+ "smw-paramdesc-aggregation": "指定聚集應與什麼相關",
"smw-paramdesc-template": "用來顯示列印頁面的模板名稱",
"smw-paramdesc-columns": "所要顯示結果的欄數",
"smw-paramdesc-userparam": "使用模板時,傳遞給模板的參數值",
@@ -100,7 +106,7 @@
"smw-paramdesc-rdfsyntax": "使用 RDF 語法",
"smw-paramdesc-csv-sep": "指定的欄位分隔符號",
"smw-paramdesc-csv-valuesep": "指定一個值的分隔符號",
- "smw-paramdesc-csv-merge": "合併行和列值與獨立的對象識別字(或稱首列)",
+ "smw-paramdesc-csv-merge": "與相同主題識別字(或稱首欄)來合併列和欄的值",
"smw-paramdesc-csv-bom": "在輸出檔案的頂端添加 BOM(訊號位元組順序字元)",
"smw-paramdesc-dsv-separator": "使用的分隔符號",
"smw-paramdesc-dsv-filename": "DSV 檔案名稱",
@@ -127,6 +133,7 @@
"smw-paramdesc-feeddescription": "訂閱來源的描述文字",
"smw-paramdesc-feedpagecontent": "訂閱來源顯示的頁面內容",
"smw-label-feed-description": "訂閱 $1 $2 feed",
+ "smw-paramdesc-mimetype": "用於輸出檔案的媒體類型(MIME 類型)",
"smw_iq_disabled": "此 wiki 的語義查詢已被停用",
"smw_iq_moreresults": "...更多結果",
"smw_parseerror": "輸入的值無法理解。",
@@ -135,7 +142,9 @@
"smw_wrong_namespace": "此處只允許命名空間 \"$1\" 中的頁面。",
"smw_manytypes": "此屬性定義了一種以上類型。",
"smw_emptystring": "不接受空字元串。",
- "smw_notinenum": "“$1”不在用於“$3”屬性[[Property:Allows value|所允許值]]的清單($2)中。",
+ "smw_notinenum": "「$1」不在用於「$3」屬性[[Property:Allows value|所允許值]]的清單($2)中。",
+ "smw-datavalue-constraint-error-allows-value-list": "「$1」不在用於「$3」屬性[[Property:Allows value|所允許值]]的清單($2)中。",
+ "smw-datavalue-constraint-error-allows-value-range": "「$1」沒有符合用於限制屬性「$3」的[[Property:Allows value|允許值]]所指定的「$2」範圍。",
"smw_noboolean": "\"$1\" 不是布林 (是非) 值",
"smw_true_words": "true,t,yes,y,是,真,對",
"smw_false_words": "false,f,no,n,否,假,錯",
@@ -157,7 +166,7 @@
"smw_noqueryfeature": "此 wiki 不支援一些查詢功能,查詢被部分停止 ($1) 。",
"smw_noconjunctions": "此 wiki 不支援查詢中的合取,查詢被部分停止 ($1) 。",
"smw_nodisjunctions": "此 wiki 不支援查詢中的析取,查詢被部分停止 ($1) 。",
- "smw_querytoolarge": "由于此wiki在査詢大小或深度上的限制,下列{{PLURAL:$2|查詢準則}}無法考慮:<code>$1</code>。",
+ "smw_querytoolarge": "由于此 wiki 在査詢大小或深度上的限制,下列{{PLURAL:$2|查詢準則}}無法列入考慮:<code>$1</code>。",
"smw_notemplategiven": "為使查詢格式正常工作,請為參數 \"模板\" 賦值。",
"smw_db_sparqlqueryproblem": "無法從 SPARQL 資料庫獲得查詢結果。這個錯誤可能是暫時的,也可能是資料庫軟體的錯誤造成的。",
"smw_db_sparqlqueryincomplete": "本查詢太過複雜因而被中止,可能會因此遺失部分結果。如果可能,請嘗試改用一個較簡單的查詢。",
@@ -185,34 +194,34 @@
"smw_propertylackstype": "此屬性未指定類型 (目前預設為類型 $1)",
"smw_propertyhardlyused": "此屬性在本 wiki 中不常使用。",
"smw-property-name-invalid": "無法使用屬性 $1 (無效的屬性名稱)。",
- "smw-property-name-reserved": "“$1”被列舉為保留名稱,且不應用作屬性。以下[https://www.semantic-mediawiki.org/wiki/Help:Property_naming 幫助頁面]可能包含有關為何該名稱是保留名稱的資訊。",
+ "smw-property-name-reserved": "「$1」被列舉為保留名稱,且不應用作屬性。以下[https://www.semantic-mediawiki.org/wiki/Help:Property_naming 幫助頁面]可能包含有關為何該名稱是保留名稱的資訊。",
"smw-sp-property-searchform": "顯示包含以下內容的屬性:",
"smw-sp-property-searchform-inputinfo": "輸入區分大小寫且當用來搜尋時只會顯示符合條件的屬性。",
"smw-special-property-searchform": "顯示包含以下內容的屬性:",
"smw-special-property-searchform-inputinfo": "輸入區分大小寫且當用來搜尋時只會顯示符合條件的屬性。",
"smw-special-property-searchform-options": "選項",
- "smw-special-wantedproperties-filter-label": "篩選器:",
+ "smw-special-wantedproperties-filter-label": "篩選:",
"smw-special-wantedproperties-filter-none": "無",
"smw-special-wantedproperties-filter-unapproved": "未批准",
- "smw-special-wantedproperties-filter-unapproved-desc": "過濾用於權威模式時連接的選項。",
+ "smw-special-wantedproperties-filter-unapproved-desc": "篩選用於權威模式時連接的選項。",
"concepts": "概念",
"smw-special-concept-docu": "[https://www.semantic-mediawiki.org/wiki/Help:Concepts 概念]可被看做是 \"動態分類\",即非手動建立的頁面集合,是由 Semantic MediaWiki 從指定查詢中的描述所找出。",
"smw-special-concept-header": "概念清單",
"smw-special-concept-count": "以下列出{{PLURAL:$1|1 個概念|$1 個概念}}。",
"smw-special-concept-empty": "查無概念。",
"unusedproperties": "未使用的屬性",
- "smw-unusedproperties-docu": "此頁面列舉雖然沒有被其他頁面使用,但已聲明的[https://www.semantic-mediawiki.org/wiki/Unused_properties 未使用屬性]。要查看不同視圖,請參見[[Special:Properties|完整]]或[[Special:WantedProperties|需要的屬性]]特殊頁面。",
+ "smw-unusedproperties-docu": "此頁面列出已聲明,沒有被其它頁面使用的[https://www.semantic-mediawiki.org/wiki/Unused_properties 未使用屬性]。差別內容請參見[[Special:Properties|全部屬性]]或[[Special:WantedProperties|所需屬性]]特殊頁面。",
"smw-unusedproperty-template": "類型為 $2 的屬性 $1",
"wantedproperties": "需要的屬性",
- "smw-wantedproperties-docu": "此頁面列舉在wiki中使用,但沒有頁面描述的[https://www.semantic-mediawiki.org/wiki/Wanted_properties 需要的屬性]。要查看不同視圖,請參見[[Special:Properties|完整]]或[[Special:UnusedProperties|未使用屬性]]特殊頁面。",
+ "smw-wantedproperties-docu": "此頁面列出在 wiki 中使用,但沒有頁面描述的[https://www.semantic-mediawiki.org/wiki/Wanted_properties 所需屬性]。差別內容請參見[[Special:Properties|全部屬性]]或[[Special:UnusedProperties|未使用屬性]]特殊頁面。",
"smw-wantedproperty-template": "$1 ($2 {{PLURAL:$2|use|使用}})",
- "smw-special-wantedproperties-docu": "此頁面列舉在wiki中使用,但沒有頁面描述的[https://www.semantic-mediawiki.org/wiki/Wanted_properties 需要的屬性]。要查看不同視圖,請參見[[Special:Properties|完整]]或[[Special:UnusedProperties|未使用屬性]]特殊頁面。",
+ "smw-special-wantedproperties-docu": "此頁面列出在 wiki 中使用,但沒有頁面描述的[https://www.semantic-mediawiki.org/wiki/Wanted_properties 所需屬性]。差別內容請參見[[Special:Properties|全部屬性]]或[[Special:UnusedProperties|未使用屬性]]特殊頁面。",
"smw-special-wantedproperties-template": "$1($2 {{PLURAL:$2|次使用}})",
"smw_purge": "重新整理",
"smw-purge-failed": "重新整理失敗",
"types": "類型",
"smw_types_docu": "[https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes 可用資料類型]的列表,每種[https://www.semantic-mediawiki.org/wiki/Help:Datatype 類型]代表唯一的屬性集,以描述儲存方面的值,並顯示遺傳至分配内容的特徵。",
- "smw-special-types-no-such-type": "指定的資料型態不存在",
+ "smw-special-types-no-such-type": "「$1」為未知,或是尚未指定成有效的資料型態。",
"smw-statistics": "Semantic 語義統計",
"smw-statistics-property-instance": "屬性{{PLURAL:$1|值|值}} (總計)",
"smw-statistics-property-total": "[[Special:Properties|{{PLURAL:$1|屬性|屬性}}]] (總計)",
@@ -242,7 +251,7 @@
"smw_ask_editquery": "編輯查詢",
"smw_add_sortcondition": "[增加排序條件]",
"smw-ask-sort-add-action": "增加排序條件",
- "smw_ask_hidequery": "隱藏查詢",
+ "smw_ask_hidequery": "隱藏查詢(密集檢視)",
"smw_ask_help": "查詢幫助",
"smw_ask_queryhead": "條件",
"smw_ask_printhead": "列印輸出選擇",
@@ -272,11 +281,18 @@
"smw-ask-format": "格式",
"smw-ask-format-selection-help": "有關選定格式的幫助:$1",
"smw-ask-condition-change-info": "條件已改變,搜尋引擎需要重新運行査詢來產生匹配新要求的結果。",
+ "smw-ask-input-assistance": "輸入幫助",
+ "smw-ask-condition-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance 輸入幫助]提供於列印輸出、排序、條件欄位方面。條件欄位需要以下字首之一:",
+ "smw-ask-condition-input-assistance-property": "<code>p:</code> 檢索屬性建議(例如:<code>[[p:Has ...</code>)",
"smw-ask-condition-input-assistance-category": "<code>c:</code> 來索取分類建議",
"smw-ask-condition-input-assistance-concept": "<code>con:</code> 來索取概念建議",
+ "smw-ask-format-change-info": "格式已變動,並且需要再次執行查詢來比對新參數和視覺化選項。",
+ "smw-ask-format-export-info": "所選格式為不具有視覺化呈現的匯出格式,因此內容結果僅能提供下載。",
+ "smw-ask-query-search-info": "查詢 <code><nowiki>$1</nowiki></code> 由 {{PLURAL:$3|1=<code>$2</code>(來自快取)|<code>$2</code>(來自快取)|<code>$2</code>}}在 $4 {{PLURAL:$4|秒|秒}}內回應。",
"searchbyproperty": "按屬性查詢",
"processingerrorlist": "處理錯誤清單",
"propertylabelsimilarity": "屬性標籤相似度報告",
+ "smw-processingerrorlist-intro": "以下清單提供有關出現在連接 [https://www.semantic-mediawiki.org/ Semantic MediaWiki] 時的處理錯誤方面概要。建議定期查看此清單,並修正無效的值註解。",
"smw_sbv_docu": "搜尋所有已設定屬性和值的頁面。",
"smw_sbv_novalue": "為此屬性輸入一個有效值,或者顯示所有 \"$1\" 的屬性值。",
"smw_sbv_displayresult": "有值為 \"$2\" 的屬性 \"$1\" 的所有頁面清單",
@@ -293,14 +309,17 @@
"smw_browse_no_outgoing": "這個頁面沒有設定屬性。",
"smw_browse_no_incoming": "沒有屬性連結到此頁。",
"smw-browse-from-backend": "訊息目前正從後端取得。",
+ "smw-browse-intro": "此頁面提供有關主題或實體實例的詳情,請輸入物件名稱來檢查。",
"smw-browse-invalid-subject": "主題驗證返回“$1”錯誤。",
"smw-browse-api-subject-serialization-invalid": "主題有無效的序列化格式。",
+ "smw-browse-js-disabled": "似乎是 Javascript 被停用或無法使用,我們建議使用支援 Javascript 的瀏覽器。其它選項有在 [https://www.semantic-mediawiki.org/wiki/Help:$smwgBrowseByApi <code>$smwgBrowseByApi</code>] 設置參數頁面裡被提及到。",
"smw-browse-show-group": "顯示群組",
"smw-browse-hide-group": "隱藏群組",
+ "smw-noscript": "此頁面或操作需要 Javascript 才能執行,請在您的瀏覽器上啟用 Javascript,或是使用支援 Javascript 的瀏覽器,以讓依據要求所提供的功能可運作。進一步的詳細內容,請查看 [https://www.semantic-mediawiki.org/wiki/Help:Noscript noscript] 說明頁面。",
"smw_inverse_label_default": "的 $1",
"smw_inverse_label_property": "逆屬性標籤",
"pageproperty": "頁面屬性搜尋",
- "smw_pp_docu": "在指定頁面搜尋某屬性的所有值。\n輸入頁面和屬性。",
+ "smw_pp_docu": "輸入頁面和屬性,或是僅輸入屬性來索取所有分配的值。",
"smw_pp_from": "從頁面:",
"smw_pp_type": "屬性:",
"smw_pp_submit": "搜尋結果",
@@ -308,20 +327,25 @@
"smw_result_next": "下一個",
"smw_result_results": "結果",
"smw_result_noresults": "沒有結果。",
- "smwadmin": "管理並維護函式",
- "smw-admin-statistics-job-title": "工作統計",
+ "smwadmin": "管理並維護功能",
+ "smw-admin-statistics-job-title": "任務統計",
+ "smw-admin-statistics-job-docu": "任務統計顯示出有關已安排但尚未執行的 Semantic MediaWiki 任務。任務數目可能會有些不精準或是包含到失敗的嘗試,請查閱[https://www.mediawiki.org/wiki/Manual:Job_queue 手冊]來獲得進一步資訊。",
"smw-admin-statistics-querycache-title": "查詢快取統計",
+ "smw-admin-statistics-querycache-disabled": "[https://www.semantic-mediawiki.org/wiki/QueryCache 查詢快取]在此 wiki 未啟用,藉此沒有可用的統計內容。",
+ "smw-admin-statistics-querycache-explain": "快取統計為含有臨時累計內容和衍生資料,包括: \n* \"misses\" 是嘗試從快取索取資料但帶有無效回應,而必須直接做儲存(資料庫、三重儲存或其它)檢索的總數\n* \"deletes\" 代表回收快取操作(透過清除或是依靠查詢)的總數量\n* \"hits\" 含有來自內嵌(來自以 wiki 頁面的查詢呼叫)或非內嵌(如有啟用,由像是 Special:Ask 頁面或是 API 的請求) 來源索取的快取數量\n* \"medianRetrievalResponseTime\" 是用於超過收集過程時間段落的快取、非快取檢索請求回應時間(以秒為單位)中位數的取向值\n* \"noCache\" 表示沒有嘗試從快取來索取結果的次數(limit=0 的查詢,或是 'no-cache' 等其它選項)",
+ "smw-admin-permission-missing": "出於缺少權限緣故,被阻止存取此頁面,請參閱[https://www.semantic-mediawiki.org/wiki/Help:Permissions 權限]說明頁面來獲得更多有關所需設定的詳情。",
"smw-admin-setupsuccess": "儲存引擎已設定。",
"smw_smwadmin_return": "返回 $1",
"smw_smwadmin_updatestarted": "更新語意資料過程開始。\n所有已儲存資料將被按需重建或修復。\n你可以透過本特殊頁面追蹤更新程序。",
"smw_smwadmin_updatenotstarted": "已有更新程序正在執行,請勿建立另一個。",
"smw_smwadmin_updatestopped": "已停止所有更新程序。",
- "smw_smwadmin_updatenotstopped": "若要停止更新程序,您必須活化核取方塊以指出是真的很確定。",
- "smw-admin-docu": "這個特殊頁面為您安裝、升級、維護和使用<a href=\"https://www.semantic-mediawiki.org\">語義MediaWiki</a>時提供說明,並提供進一步的管理功能和任務,以及統計。\n請記得在執行管理功能前備份好資料。",
+ "smw_smwadmin_updatenotstopped": "若要停止更新程序,您必須勾選核取方塊來表示您確實如此要求。",
+ "smw-admin-docu": "這個特殊頁面為您安裝、升級、維護和使用 <a href=\"https://www.semantic-mediawiki.org\">Semantic MediaWiki</a> 時提供說明,並提供進一步的管理功能和任務,以及統計。\n請記得在執行管理功能前備份好資料。",
"smw-admin-environment": "軟體環境",
- "smw-admin-db": "資料庫維護",
- "smw-admin-dbdocu": "Semantic MediaWiki 將 MediaWiki 資料庫做一些擴充套件,以儲存語意資料。\n以下功能可幫助你正確設定資料庫。\n這個步驟所做的修改不會影響 MediaWiki 資料庫的其他部分,如果需要,可以方便地還原所做的修改。\n這個定射功能可多次執行,不會造成任何危害。但是只需在安裝或升級時執行一次即可。",
- "smw-admin-permissionswarn": "如果操作因 SQL 錯誤而失敗,可能是維基的資歷庫使用者 (檢查您的 LocalSettings.php) 沒有相應權限。你可以向該使用者賦予建立和刪除表格的權限,或臨時將資料庫根使用者的登入資訊輸入 LocalSettings.php,或使用維護腳本<code>setupStore.php</code>,這個腳本可以使用 LocalSettings.php 中的資訊。",
+ "smw-admin-db": "資料庫設定",
+ "smw-admin-db-preparation": "表格初始化正在進行,在依據大小來顯示出結果以及可能進行的表格最佳化之前,可能會花費一段時間 。",
+ "smw-admin-dbdocu": "Semantic MediaWiki 需要本身所持有的資料庫架構來儲存語意資料(這獨立於 MediaWiki,不會對 MediaWiki 的安裝部份造成影響)\n這個設定功能可多次執行,不會造成任何危害。但是只需在安裝或升級時執行一次即可。",
+ "smw-admin-permissionswarn": "如果操作因 SQL 錯誤而失敗,可能是您 wiki 所用的資料庫使用者(可在您的 LocalSettings.php 檔案上檢查)沒有相應權限。您可以向該使用者賦予建立和刪除表格的權限,或臨時將資料庫 root 使用者的登入資訊輸入在 LocalSettings.php 檔案,或是使用維護腳本 <code>setupStore.php</code>,該腳本可以使用 LocalSettings.php 中的資訊。",
"smw-admin-dbbutton": "初始化或升級表格",
"smw-admin-announce": "發佈 wiki",
"smw-admin-announce-text": "若您的 wiki 是公開的,您可以在 <a href=\"https://wikiapiary.com\">WikiApiary</a> 註冊它,這是用來追蹤 wiki 的 wiki。",
@@ -335,76 +359,95 @@
"smw-admin-deprecation-notice-config-replacement-option-list": "<code>$1</code> 正在替換為 <code>$2</code>",
"smw-admin-deprecation-notice-config-removal": "<code>[https://www.semantic-mediawiki.org/wiki/Help:$1 $1]</code>已在 $2 版本中被移除",
"smw-admin-deprecation-notice-title-notice": "即將進行的更改",
- "smw-admin-deprecation-notice-title-notice-explanation": "現已檢測到該wiki使用了以下設定,並計畫在今後的發佈版本中移除或更改。",
+ "smw-admin-deprecation-notice-title-notice-explanation": "現已檢測到此 wiki 使用了以下設定,並計畫在今後的發佈版本中移除或更改。",
"smw-admin-deprecation-notice-title-replacement": "已替換或重新命名的設定",
- "smw-admin-deprecation-notice-title-replacement-explanation": "以下包含已重命名或有另外修改的設定,並建議立刻更新其名稱或格式。",
+ "smw-admin-deprecation-notice-title-replacement-explanation": "以下段落包含已重新命名或或是其它變動的設定,建議立即更新其名稱或格式。",
"smw-admin-deprecation-notice-title-removal": "已移除的設定",
"smw-admin-deprecation-notice-title-removal-explanation": "列出的設定已在上一個發佈版本中移除,但在此 wiki 上被檢測到使用著。",
"smw-smwadmin-refresh-title": "資料修復與更新",
"smw_smwadmin_datarefresh": "資料重建",
"smw_smwadmin_datarefreshdocu": "可以基於維基先有內容對所有 Semantic MediaWki 資料進行重置。\n這個功能對修復損壞的資料,或者在軟體升級,內部格式改變時更新資料非常有用。\n更新時逐頁面執行的,需要一段時間。\n下方將顯示更新是否正在進行,並允許你開始或終止更新。 (此功能可以被網站管理員停用)",
"smw_smwadmin_datarefreshprogress": "<strong>有一個更新正在進行。</strong>\n更新程序可能會很慢,因為該程序僅在使用者訪問維基時小塊地更新資料。\n可以使用 MediaWiki 維護腳本<code>runJobs.php</code> (使用選項 <code>--maxjobs 1000</code> 限制每批更新數目) 來加快更新完成速度。\n目前更新的估計進度:",
- "smw_smwadmin_datarefreshbutton": "開始更新資料",
+ "smw_smwadmin_datarefreshbutton": "安排資料重建",
"smw_smwadmin_datarefreshstop": "停止更新",
"smw_smwadmin_datarefreshstopconfirm": "是的,我{{GENDER:$1|確認}}。",
- "smw-admin-job-scheduler-note": "多數活動都為了使用工作調度批量執行而被計畫為工作,來計畫並完成加工,囙此關鍵是維護腳本<code>runJobs.php</code>或<code>$wgRunJobsAsync</code>是否有響應管理。",
+ "smw-admin-job-scheduler-note": "在此段落的任務(已啟用)會透過任務佇列進行,以避免在執行期間出現死結狀況。[https://www.mediawiki.org/wiki/Manual:Job_queue 任務佇列]負責程序,在緊要時可採用 <code>runJobs.php</code> 維護用手稿檔案(另參見設置參數 <code>$wgRunJobsAsync</code>)。",
"smw-admin-outdateddisposal-title": "過時實體處置",
- "smw-admin-outdateddisposal-intro": "部分活動(对屬性類型的更改,wiki頁面的移除,或錯誤值的糾正)將創建[https://www.semantic-mediawiki.org/wiki/Outdated_entities 過時實體],並建議定期移除它們以釋放相關表空間。",
- "smw-admin-outdateddisposal-active": "過時實體處置工作已加入隊列。",
- "smw-admin-outdateddisposal-button": "計畫處置",
- "smw-admin-feature-disabled": "該功能已在此wiki禁用。請查閱<a href=\"https://www.semantic-mediawiki.org/wiki/Help:$smwgAdminFeatures\">設定</a>幫助頁面或聯絡系統管理員。",
+ "smw-admin-outdateddisposal-intro": "部分操作(對於屬性類型的更改、wiki 頁面的移除、或錯誤值的糾正)的結果會在[https://www.semantic-mediawiki.org/wiki/Outdated_entities 過時實體]上,並建議定期移除它們以釋放相關表格空間。",
+ "smw-admin-outdateddisposal-active": "過時實體處置任務已加入排程。",
+ "smw-admin-outdateddisposal-button": "安排處置",
+ "smw-admin-feature-disabled": "該功能已在此 wiki 上禁用。請查閱<a href=\"https://www.semantic-mediawiki.org/wiki/Help:$smwgAdminFeatures\">設定</a>幫助頁面或聯絡系統管理員。",
"smw-admin-propertystatistics-title": "屬性統計重建",
"smw-admin-propertystatistics-intro": "重建整個屬性使用統計以及其中的更新,並更正[https://www.semantic-mediawiki.org/wiki/Help:Property_usage_count usage 使用計數]屬性。",
- "smw-admin-propertystatistics-active": "統計重建工作已加入隊列。",
- "smw-admin-propertystatistics-button": "計畫統計重建",
+ "smw-admin-propertystatistics-active": "屬性統計重建任務已加入排程。",
+ "smw-admin-propertystatistics-button": "安排統計重建",
"smw-admin-fulltext-title": "重建全文搜尋",
- "smw-admin-fulltext-intro": "从屬性表中使用啟用的[https://www.semantic-mediawiki.org/wiki/Full-text 全文搜索]資料類型重建蒐索索引。對索引規則的更改(改變的停用詞、新的詞幹等)和/或新添加或改變的表格需要重新運行此工作。",
- "smw-admin-fulltext-active": "全文搜尋重建工作已加入隊列。",
+ "smw-admin-fulltext-intro": "從啟用[https://www.semantic-mediawiki.org/wiki/Full-text 全文搜索]資料類型的屬性表格來重建搜尋索引。對索引規則的更改(改變的停用詞、新的詞幹等)以及/或是新的已添加或已變動表格,需要重新運行此任務。",
+ "smw-admin-fulltext-active": "全文搜尋重建任務已加入排程。",
"smw-admin-fulltext-button": "排程重建全文",
"smw-admin-support": "獲得協助",
"smw-admin-supportdocu": "已提供各種資源來幫助您解决以下問題:",
"smw-admin-installfile": "如果您安裝時遇到問題,請先檢查<a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/docs/INSTALL.md\">安裝文件</a>及<a href=\"https://www.semantic-mediawiki.org/wiki/Help:Installation\">安裝頁面</a>中的指引。",
- "smw-admin-smwhomepage": "語義MediaWiki的完整使用者文件請查閱<b><a href=\"https://www.semantic-mediawiki.org\">semantic-mediawiki.org</a></b>。",
+ "smw-admin-smwhomepage": "Semantic MediaWiki 的完整使用者文件請查閱 <b><a href=\"https://www.semantic-mediawiki.org\">semantic-mediawiki.org</a></b>。",
"smw-admin-bugsreport": "程式問題可在<a href=\"https://github.com/SemanticMediaWiki/SemanticMediaWiki/issues\">問題追蹤</a>報告,<a href=\"https://www.semantic-mediawiki.org/wiki/Help:Reporting_bugs\">報告錯誤</a>頁面提供一些如何書寫有效問題報告的指導。",
- "smw-admin-questions": "如果有問題或建議,可加入語義MediaWiki<a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">用戶郵件列表</a>,或是<a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">聊天室</a>的討論。",
- "smw-admin-other-functions": "其它函式",
- "smw-admin-supplementary-section-title": "補充函式",
- "smw-admin-supplementary-section-subtitle": "可用函式",
- "smw-admin-supplementary-section-intro": "此章節列舉的部分函數可能受限制,並囙此在此wiki不可使用。",
+ "smw-admin-questions": "如果有問題或建議,可加入 Semantic MediaWiki <a href=\"https://sourceforge.net/p/semediawiki/mailman/semediawiki-user/\">使用者郵件清單</a>,或是<a href=\"https://www.semantic-mediawiki.org/wiki/Semantic_MediaWiki_chatroom\">聊天室</a>的討論。",
+ "smw-admin-other-functions": "其它功能",
+ "smw-admin-supplementary-section-title": "補充功能",
+ "smw-admin-supplementary-section-subtitle": "核心功能",
+ "smw-admin-supplementary-section-intro": "此段落所提供額外功能不在所維護範圍之內,並且可能是列在[https://www.semantic-mediawiki.org/wiki/Help:Special:SemanticMediaWiki/Supplementary_functions 文檔]裡的部份函式為受到限制或是不可用,因此在此 wiki 上不可取用。",
"smw-admin-supplementary-settings-title": "設置設定",
- "smw-admin-supplementary-settings-intro": "<u>$1</u> 輸出用於語義 MediaWiki 的可用設定的集合清單",
+ "smw-admin-supplementary-settings-intro": "<u>$1</u> 輸出用於 Semantic MediaWiki 的可用設定的集合清單",
"smw-admin-supplementary-operational-statistics-title": "操作統計",
"smw-admin-supplementary-operational-statistics-intro": "<u>$1</u>顯示擴充的統計集合",
"smw-admin-supplementary-idlookup-title": "實體查找與處置",
- "smw-admin-supplementary-idlookup-intro": "<u>$1</u>包含查找並處置個別實體的函式",
+ "smw-admin-supplementary-idlookup-intro": "<u>$1</u>包含查找並處置個別實體的功能",
"smw-admin-supplementary-duplookup-title": "重複項目",
- "smw-admin-supplementary-duplookup-intro": "<u>$1</u>列舉在實體表中,包含重複項的記錄",
- "smw-admin-supplementary-duplookup-docu": "此頁面列舉來自[https://www.semantic-mediawiki.org/wiki/Help:Entity_table 實體表]的記錄,他們被歸類為重複項。重複記錄(如有)只應在罕見場合出現,這可能由資料庫更新期間的結束過程,或是未成功的回退事宜導致。",
+ "smw-admin-supplementary-duplookup-intro": "<u>$1</u> 列出歸類在實體表中含有重複內容的項",
+ "smw-admin-supplementary-duplookup-docu": "此頁面列舉來自[https://www.semantic-mediawiki.org/wiki/Help:Entity_table 實體表]的項目,它們被歸類為重複項。重複項(如有)應僅偶然會在資料庫更新期間的結束過程裡發生,或是未成功的回退事項所導致。",
"smw-admin-supplementary-duplookup-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Duplicate_entities",
"smw-admin-supplementary-operational-statistics-cache-title": "快取統計",
"smw-admin-supplementary-operational-statistics-cache-intro": "<u>$1</u> 顯示出快取相關統計",
"smw-admin-supplementary-elastic-title": "Elasticsearch",
- "smw-admin-supplementary-elastic-intro": "<u>$1</u> 告知有關設定與索引統計",
- "smw-admin-supplementary-elastic-functions": "可用函式",
+ "smw-admin-supplementary-elastic-section-subtitle": "Elasticsearch 功能",
+ "smw-admin-supplementary-elastic-intro": "<u>$1</u> 顯示設定與索引統計",
+ "smw-admin-supplementary-elastic-docu": "此頁面包含有關設定的資訊、對應、狀態,以及相關連結到 Semantic MediaWiki 以及其 [https://www.semantic-mediawiki.org/wiki/Help:ElasticStore <code>ElasticStore</code>] 之 Elasticsearch 叢集的索引統計。",
+ "smw-admin-supplementary-elastic-functions": "支援功能",
"smw-admin-supplementary-elastic-settings-title": "設定",
+ "smw-admin-supplementary-elastic-settings-intro": "<u>$1</u> 由 Elasticsearch 所使用來管理 Semantic MediaWiki 索引",
+ "smw-admin-supplementary-elastic-mappings-title": "對應",
+ "smw-admin-supplementary-elastic-mappings-intro": "<u>$1</u> 用來列出索引與欄位對應",
+ "smw-admin-supplementary-elastic-mappings-docu": "此頁面包含與目前索引一同使用的欄位對應詳情。對應摘要應與指定出在索引裡最大欄位數的 <code>index.mapping.total_fields.limit</code> 一同連結監測。",
"smw-admin-supplementary-elastic-mappings-summary": "摘要",
+ "smw-admin-supplementary-elastic-mappings-fields": "欄位對應",
"smw-admin-supplementary-elastic-nodes-title": "節點",
"smw-admin-supplementary-elastic-nodes-intro": "<u>$1</u>顯示節點統計",
+ "smw-admin-supplementary-elastic-indices-title": "索引",
+ "smw-admin-supplementary-elastic-indices-intro": "<u>$1</u> 提供可用索引以及其統計內容的概要",
"smw-admin-supplementary-elastic-statistics-title": "統計",
"smw-admin-supplementary-elastic-statistics-intro": "<u>$1</u> 顯示索引層級統計",
+ "smw-admin-supplementary-elastic-statistics-docu": "此頁面提供發生在索引層級上不同操作的索引統計方面洞察,所回傳統計是以初級內容與總計集成的聚合。[https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-stats.html 說明頁面]包含可用索引統計的詳情描述。",
+ "smw-admin-supplementary-elastic-status-replication": "複製狀態",
+ "smw-admin-supplementary-elastic-status-last-active-replication": "上一次有效的複製:$1",
"smw-admin-supplementary-elastic-status-refresh-interval": "重整間隔:$1",
+ "smw-admin-supplementary-elastic-status-recovery-job-count": "積壓修復任務:$1(估計值)",
+ "smw-admin-supplementary-elastic-status-file-ingest-job-count": "積壓收取(檔案)任務:$1(估計值)",
+ "smw-admin-supplementary-elastic-status-rebuild-lock": "複製已鎖定:$1(進行中的重建)",
"smw-list-count": "清單包含 $1 個{{PLURAL:$1|項目|項目}}。",
"smw-list-count-from-cache": "清單包含 $1 個{{PLURAL:$1|實體}},並自快取還原(UTC:$2)。",
- "smw-property-label-uniqueness": "“$1”標籤匹配了至少一個其他内容表現。請查閱[https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness 幫助頁面]瞭解如何解决該問題。",
+ "smw-property-label-uniqueness": "「$1」標籤符合了至少一個其它屬性表示內容。請查閱[https://www.semantic-mediawiki.org/wiki/Help:Property_uniqueness 幫助頁面]瞭解如何解决該問題。",
"smw-property-label-similarity-title": "屬性標籤相似度報告",
"smw-property-label-similarity-intro": "<u>$1</u>可對現有屬性標籤的相似性進行計算",
"smw-property-label-similarity-threshold": "門檻:",
"smw-property-label-similarity-type": "顯示類型 ID",
"smw-property-label-similarity-noresult": "找不到符合所選項目的结果。",
- "smw-property-label-similarity-docu": "在兩個可幫助過濾拼寫錯誤或的屬性標籤,或是在提供相同概念的等價内容(參見特殊頁面[[Special:Properties|屬性]]以闡明報告屬性的概念和用法)之間,比較並報告[https://www.semantic-mediawiki.org/wiki/Property_similarity 語法相似性](不是語義相似性)。可以通過調整閥值來調整相似性距離的寬窄。<code>[[Property:$1|$1]]</code>被用于从分析中排除屬性。",
+ "smw-property-label-similarity-docu": "比較與報告兩個屬性標籤間的[https://www.semantic-mediawiki.org/wiki/Property_similarity 語法相似性](不是語義相似性),可幫助篩選掉拼寫錯誤或提供相同概念的等效屬性(請參見特殊頁面[[Special:Properties|屬性]]來闡明報告屬性的概念和用法)。可透過調整臨界值來增加或減少相似距離。<code>[[Property:$1|$1]]</code> 用於從分析中排除屬性。",
+ "smw-admin-operational-statistics": "此頁面包含存在於或來自 Semantic MediaWiki 相關功能的所收集運作統計。Wiki 特定統計的擴充清單可[[Special:Statistics|<b>在此</b>]]找到。",
"smw_adminlinks_datastructure": "資料結構",
"smw_adminlinks_displayingdata": "資料顯示",
"smw_adminlinks_inlinequerieshelp": "直接插入式查詢幫助",
+ "smw-page-indicator-usage-count": "已估計[https://www.semantic-mediawiki.org/wiki/Help:Property_usage_count 使用次數]:{{PLURAL:$2|'''$2'''}}",
+ "smw-property-indicator-type-info": "{{PLURAL:$1|使用者|系統}}定義的屬性",
+ "smw-property-indicator-last-count-update": "估計使用數\n上一次更新於:$1",
"smw-concept-indicator-cache-update": "快取數\n上一次更新:$1",
"smw-createproperty-isproperty": "它是一個類型為$1的屬性。",
"smw-createproperty-allowedvals": "允許的{{PLURAL:$1|屬性值為|屬性值為}}:",
@@ -413,12 +456,20 @@
"smw-paramdesc-category-userparam": "傳遞模板的參數",
"smw-info-par-message": "顯示的訊息。",
"smw-info-par-icon": "顯示的圖示,\"訊息\"或\"警告\"。",
- "prefs-smw": "語義 MediaWiki",
+ "prefs-smw": "Semantic MediaWiki",
"prefs-general-options": "一般選項",
"prefs-ask-options": "Special:Ask 選項",
"smw-prefs-intro-text": "[https://www.semantic-mediawiki.org/ 語義MediaWiki] (及相關擴充套件) 在部分指定的函數各自提供自訂功能。請參閱[https://www.semantic-mediawiki.org/wiki/Help:User_preferences 使用說明頁面]以獲取更多資訊。",
"smw-prefs-ask-options-tooltip-display": "顯示參數文字作為資訊提示",
+ "smw-prefs-ask-options-compact-view-basic": "啟用基本密集檢視",
+ "smw-prefs-help-ask-options-compact-view-basic": "若有啟用,顯示在 Special:Ask 密集檢視的連結簡化集合。",
+ "smw-prefs-general-options-time-correction": "使用本地[[Special:Preferences#mw-prefsection-rendering|時間偏移]]偏好設定來啟用替特殊頁面做時間調正。",
+ "smw-prefs-general-options-jobqueue-watchlist": "在我的個人工具列顯示任務佇列",
+ "smw-prefs-help-general-options-jobqueue-watchlist": "若有啟用,將待定所選任務[https://www.semantic-mediawiki.org/wiki/Help:Job_queue_watchlist 清單]與所估計佇列大小一同顯示。",
"smw-prefs-general-options-disable-editpage-info": "在編輯頁面停用前言文字",
+ "smw-prefs-general-options-disable-search-info": "在標準搜尋頁面上停用語法支援資訊",
+ "smw-prefs-general-options-suggester-textinput": "啟用語意實體的輸入幫助",
+ "smw-prefs-help-general-options-suggester-textinput": "若有啟用,允許使用[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance 輸入幫助]來查找來自輸入上下文的屬性、概念、以及分類。",
"smw-ui-tooltip-title-property": "屬性",
"smw-ui-tooltip-title-quantity": "單位轉換",
"smw-ui-tooltip-title-info": "資訊",
@@ -434,77 +485,292 @@
"smw-concept-cache-text": "此概念總共有 $1 {{PLURAL:$1|個頁面|個頁面}},最後更新於 $2 $3。",
"smw_concept_header": "概念 \"$1\" 的頁面",
"smw_conceptarticlecount": "顯示於以下 $1 {{PLURAL:$1|個頁面|個頁面}}。",
- "right-smw-admin": "存取管理工作項目 (語意 MediaWiki)",
+ "smw-qp-empty-data": "出於一些選擇標準不足,請求資料無法顯示。",
+ "right-smw-admin": "存取管理工作項目(Semantic MediaWiki)",
+ "right-smw-patternedit": "編輯維護所允許正規表達式與模式方面的取用(Semantic MediaWiki)",
+ "right-smw-pageedit": "編輯有關 <code>Is edit protected</code> 註釋頁面的取用(Semantic MediaWiki)",
"right-smw-ruleedit": "編輯規則頁面(Semantic MediaWiki)",
"restriction-level-smw-pageedit": "已保護(僅限有資格的使用者)",
"action-smw-patternedit": "編輯由語義MediaWiki使用的規則運算式",
- "group-smwadministrator": "管理員(語義 MediaWiki)",
- "group-smwadministrator-member": "{{GENDER:$1|管理員(語義 MediaWiki)}}",
- "grouppage-smwadministrator": "{{ns:project}}:管理員(語義 MediaWiki)",
- "group-smwcurator": "監護人(語意MediaWiki)",
- "action-smw-admin": "存取語意 MediaWiki 的管理工作項目",
+ "action-smw-pageedit": "編輯帶有註釋 <code>Is edit protected</code> 的頁面(Semantic MediaWiki)",
+ "group-smwadministrator": "管理員(Semantic MediaWiki)",
+ "group-smwadministrator-member": "{{GENDER:$1|管理員(Semantic MediaWiki)}}",
+ "grouppage-smwadministrator": "{{ns:project}}:管理員(Semantic MediaWiki)",
+ "group-smwcurator": "策展人(Semantic MediaWiki)",
+ "group-smwcurator-member": "{{GENDER:$1|策展人(Semantic MediaWiki)}}",
+ "grouppage-smwcurator": "{{ns:project}}:策展人(Semantic MediaWiki)",
+ "action-smw-admin": "存取 Semantic MediaWiki 的管理工作項目",
"action-smw-ruleedit": "編輯規則頁面(Semantic MediaWiki)",
"smw-property-predefined-default": "「$1」是預先定義的屬性。",
+ "smw-property-predefined-common": "此屬性為預先部署(即為[https://www.semantic-mediawiki.org/wiki/Help:Special_properties 特殊屬性])且帶有額外管理權限,但可以像其它[https://www.semantic-mediawiki.org/wiki/Property 使用者定義屬性]般地使用。",
+ "smw-property-predefined-ask": "「$1」是代表出有關各查詢的詮釋資訊(在[https://www.semantic-mediawiki.org/wiki/Subobject 子物件]的形式),且由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供的預先定義屬性。",
+ "smw-property-predefined-asksi": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,收集使用在查詢的條件數量之預先定義屬性。",
+ "smw-property-predefined-askde": "「$1」是用由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,告知有關查詢深度的預先定義屬性。",
+ "smw-property-predefined-long-askde": "這是基於子查詢巢狀、屬性鏈,和可用的描述元素,根據 <code>[https://www.semantic-mediawiki.org/wiki/Help:$smwgQMaxDepth $smwgQMaxDepth]</code> 設置參數所限制的執行查詢計算出來的數值。",
+ "smw-property-predefined-askpa": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,描述影響查詢結果的參數之預先定義屬性。",
+ "smw-property-predefined-long-askpa": "這是屬性集合的一部分,可指定[https://www.semantic-mediawiki.org/wiki/Help:Query_profiler 查詢偏好設定]。",
+ "smw-sp-properties-docu": "此頁面列出此 wiki 上的可用[https://www.semantic-mediawiki.org/wiki/Property 屬性]以及其使用數。為了能有最新的數量統計,建議您定期運作[https://www.semantic-mediawiki.org/wiki/rebuildPropertyStatistics 屬性統計]維護手稿程式。觀點上的差異,請查看[[Special:UnusedProperties|未使用]]或[[Special:WantedProperties|有所需要]]的屬性特殊頁面。",
+ "smw-sp-properties-cache-info": "所列出資料已從[https://www.semantic-mediawiki.org/wiki/Caching 快取]檢索,並更新於 $1。",
"smw-sp-properties-header-label": "屬性清單",
+ "smw-admin-settings-docu": "顯示所有相關 Semantic MediaWiki 環境之預設及本地化設定的清單。有關個別設定詳情,請參閱[https://www.semantic-mediawiki.org/wiki/Help:Configuration 設置]說明頁面。",
"smw-sp-admin-settings-button": "產生設定清單",
"smw-admin-idlookup-title": "查找",
+ "smw-admin-idlookup-docu": "此段落顯示出有關在 Semantic MediaWiki 上個別實體(wiki 頁面、子物件、屬性、其它) 的技術詳情。輸入內容可以是數字 ID 或是字串值來比對相關搜尋欄位,不過任何 ID 的引用是相關 Semantic MediaWiki;而不是 MediaWiki 的頁面或修訂 ID。",
"smw-admin-iddispose-title": "擴散",
"smw-admin-iddispose-docu": "請注意,處理操作不受限制,一旦確認,存儲引擎中的所有數據和掛起的請求將全部被删除。請'''慎重'''執行此任務,並只在查閱[https://www.semantic-mediawiki.org/wiki/Help:Object_ID_disposal 檔案]後進行。",
"smw-admin-iddispose-done": "ID“$1”已從存儲後端中移除。",
+ "smw-admin-iddispose-references": "ID「$1」{{PLURAL:$2|沒有|至少有一個}}有效的參考文獻。",
+ "smw-admin-iddispose-references-multiple": "至少具有一個有效參考文獻紀錄的符合清單。",
+ "smw-admin-iddispose-no-references": "搜尋無法找出符合「$1」的表格項目。",
"smw-admin-idlookup-input": "搜尋:",
"smw-admin-objectid": "ID:",
"smw-admin-tab-general": "預覽",
"smw-admin-tab-notices": "停用通知",
- "smw-admin-tab-rebuild": "維護",
+ "smw-admin-tab-maintenance": "維護",
+ "smw-admin-tab-supplement": "補充功能",
"smw-admin-tab-registry": "註冊",
+ "smw-admin-maintenance-no-description": "沒有描述。",
+ "smw-admin-maintenance-script-section-title": "可用維護手稿清單",
+ "smw-admin-maintenance-script-section-intro": "以下維護手稿需要為管理員,並且得使用命令列才能執行所列出的手稿。",
+ "smw-admin-maintenance-script-description-dumprdf": "現有的三重 RDF 匯出。",
+ "smw-admin-maintenance-script-description-rebuildconceptcache": "此手稿用於管理 Semantic MediaWiki 的概念快取,這可創建、移除、更新所選快取。",
+ "smw-admin-maintenance-script-description-rebuilddata": "以循環透過所有可能含有語意資料的頁面來重新創建在資料庫的語意資料。",
+ "smw-admin-maintenance-script-description-rebuildelasticindex": "以循環透過所有含有語意資料的實體來重新建置 Elasticsearch 索引(用於使用 <code>ElasticStore</code> 的安裝)。",
+ "smw-admin-maintenance-script-description-rebuildfulltextsearchtable": "重新建置 <code>SQLStore</code> 全文搜尋索引(用於設定已啟用的安裝。",
+ "smw-admin-maintenance-script-description-rebuildpropertystatistics": "重新建置所有屬性實體的使用統計內容。",
+ "smw-admin-maintenance-script-description-removeduplicateentities": "移除在所選且沒有有效參考文獻的表格上找出的重複實體。",
+ "smw-admin-maintenance-script-description-setupstore": "設定在 <code>LocalSettings.php</code> 所選的儲存後端。",
+ "smw-admin-maintenance-script-description-updateentitycollation": "更新在 <code>SQLStore</code> 的 <code>smw_sort</code> 欄位(依據 [https://www.semantic-mediawiki.org/wiki/Help:$smwgEntityCollation $smwgEntityCollation] 設定)。",
+ "smw-admin-maintenance-script-description-populatehashfield": "為缺少值的列填充 <code>smw_hash</code> 欄位。",
"smw-livepreview-loading": "讀取中...",
+ "smw-sp-searchbyproperty-description": "此頁面提供用於找尋由屬性實體與命名值所描述實體的簡易[https://www.semantic-mediawiki.org/wiki/Help:Browsing_interfaces 瀏覽介面]。其它可用的搜尋介面,包含有[[Special:PageProperty|頁面屬性搜尋]]以及[[Special:Ask|詢問查詢建置]]。",
"smw-sp-searchbyproperty-resultlist-header": "結果清單",
+ "smw-sp-searchbyproperty-nonvaluequery": "已分配屬性「$1」的值清單。",
+ "smw-sp-searchbyproperty-valuequery": "已註解屬性「$1」帶有值「$2」的頁面清單",
+ "smw-datavalue-number-textnotallowed": "「$1」不能分配給值為 $2 的聲明數字類型。",
+ "smw-datavalue-number-nullnotallowed": "「$1」回傳了「NULL」,這不允許作為數字。",
"smw-editpage-annotation-enabled": "此頁面支援語義文內註釋 (例如 <nowiki>\"[[Is specified as::World Heritage Site]]\"</nowiki>) 來建立由 Semantic MediaWiki 提供的結構化、可查詢的內容。 如何使用標示法或 #ask 分析器功能的詳細說明,請查看 [https://www.semantic-mediawiki.org/wiki/Help:Getting_started 入門指引]、[https://www.semantic-mediawiki.org/wiki/Help:In-text_annotation 文內註釋]或[https://www.semantic-mediawiki.org/wiki/Help:Inline_queries 行內查詢]說明頁面。",
"smw-editpage-annotation-disabled": "由於命名空間限制,此頁面在語義文內註釋中不會開啟。有關如何開啟命名空間的詳細資料可在[https://www.semantic-mediawiki.org/wiki/Help:Configuration 設定]說明頁面找到。",
+ "smw-editpage-property-annotation-enabled": "此屬性可以擴充使用語意註解來指定資料類型(例如:<nowiki>\"[[Has type::Page]]\"</nowiki>)或支援的宣告(例如:<nowiki>\"[[Subproperty of::dc:date]]\"</nowiki>)。有關如何增加此頁面的描述,請查看[https://www.semantic-mediawiki.org/wiki/Help:Property_declaration 屬性宣告]或是[https://www.semantic-mediawiki.org/wiki/Help:List_of_datatypes 可用資料類型清單]說明頁面。",
+ "smw-editpage-property-annotation-disabled": "此屬性已被預先定義,因此不能以資料類型註解(例如:<nowiki>\"[[Has type::Page]]\"</nowiki>)來擴充(請查看[https://www.semantic-mediawiki.org/wiki/Help:Special_properties 特殊屬性]說明頁面來獲得更多資訊)。",
+ "smw-editpage-concept-annotation-enabled": "此概念可使用 #concept 解析功能來擴充。有關如何使用 #concept 的敘述內容,請參見 [https://www.semantic-mediawiki.org/wiki/Help:Concepts 概念]說明頁面。",
+ "smw-search-syntax-support": "搜尋輸入支援語意[https://www.semantic-mediawiki.org/wiki/Help:Semantic_search 查詢語法]的使用,來協助使用 Semantic MediaWiki 比對結果。",
+ "smw-search-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance 輸入幫助]也已啟用,來減少可用屬性和分類的預先選擇。",
+ "smw-search-help-intro": "<code><nowiki>[[ ... ]]</nowiki></code> 輸入會指示至輸入處理器來使用 Semantic MediaWiki 後端搜尋。另外需注意不支援 <code><nowiki>[[ ... ]]</nowiki></code> 結合像是 <code><nowiki>[[ ... ]] OR Lorem ipsum</nowiki></code> 這樣的非結構化文字搜尋。",
+ "smw-search-help-structured": "結構化搜尋:\n\n*<code><nowiki>[[Category:Lorem ipsum]]</nowiki></code>、<code><nowiki>[[Has number::123]]</nowiki></code>(作為 [https://www.semantic-mediawiki.org/wiki/Help:Search#Filter_context 已篩選語境])\n\n*<code><nowiki>[[Has text::~*lorem*]]</nowiki></code>(帶有[https://www.semantic-mediawiki.org/wiki/Help:Search#Query_context 查詢語境])",
+ "smw-search-help-proximity": "接近搜尋(未知的屬性,'''只'''對於提供全文搜尋整合的後端可用):\n\n*<code><nowiki>[[in:lorem ipsum]]</nowiki></code>(在所有文件裡搜尋已索引的 \"lorem\" 和 \"ipsum\")\n\n* <code><nowiki>[[phrase:lorem ipsum]]</nowiki></code>(比對 \"lorem ipsum\" 為詞組)",
+ "smw-search-help-ask": "以下連結會解釋如何使用 <code>#ask</code> 語法。\n\n* [https://www.semantic-mediawiki.org/wiki/Help:Selecting_pages 選擇頁面]描述來選擇頁面如何並建置條件\n\n*[https://www.semantic-mediawiki.org/wiki/Help:Search_operators 搜尋運算]列出包括用於範圍和萬用查詢的可用搜尋運算",
"smw-search-input": "輸入與搜尋",
+ "smw-search-help-input-assistance": "[https://www.semantic-mediawiki.org/wiki/Help:Input_assistance 輸入幫助]用於輸入欄位時提供,這需要使用以下字首之一:\n\n*<code>p:</code> 用來啟用屬性建議(例如:<code><nowiki>[[p:Has ...</nowiki></code>)\n\n*<code>c:</code> 用來啟用分類建議\n\n*<code>con:</code> 用來啟用概念建議",
+ "smw-search-syntax": "語法",
+ "smw-search-profile": "擴充",
+ "smw-search-profile-tooltip": "搜尋與 Semantic MediaWiki 關聯的功能",
"smw-search-profile-sort-best": "最佳符合",
"smw-search-profile-sort-recent": "最新",
"smw-search-profile-sort-title": "標題",
+ "smw-search-profile-extended-help-intro": "Special:Search [https://www.semantic-mediawiki.org/wiki/Help:SMWSearch/Extended_profile 擴充偏好設定]提供取用在特定於 Semantic MediaWiki 的搜尋功能,並且支援後端查詢。",
+ "smw-search-profile-extended-help-sort": "指定用於結果顯示的排序偏好:",
+ "smw-search-profile-extended-help-sort-title": "* \"Title\" 使用頁面標題(或顯示標題)來作為排序標準",
+ "smw-search-profile-extended-help-sort-recent": "* \"Most recent\" 會優先顯示出最多近期變動的實體(子物件實體會抑制成這些實體,並不會以[[Property:Modification date|修改日期]]來註解)",
+ "smw-search-profile-extended-help-sort-best": "* \"Best match\" 會基於由後端所提供的[https://www.semantic-mediawiki.org/wiki/Help:ElasticStore/Relevancy 關聯度]分數來排序實體",
+ "smw-search-profile-extended-help-form": "所提供會根據所見的不同屬性和值欄位來比對特定使用情況的表單(如有保持著),會減少輸入過程讓要持續搜尋請求的使用者能更容易利用。(請查看$1)",
+ "smw-search-profile-extended-help-namespace": "當表單選擇時,命名空間選擇框會被隱藏起來,但可借助「顯示/隱藏」按鈕來將其可見。",
+ "smw-search-profile-extended-help-search-syntax": "搜尋輸入欄位支援用來定義 Semantic MediaWiki 指定搜尋語境的 <code>#ask</code> 語法使用。有效的表達式包含:",
+ "smw-search-profile-extended-help-search-syntax-simplified-in": "* <code>in:</code> 用於查詢包含「...」的任何內容,這在所涉及的搜尋上下文或屬性未知時很有用(例如:<code>in:(lorem && ipsum)</code> 等同 <code><nowiki>[[~~*lorem*]] && [[~~*ipsum*]]</nowiki></code>)。",
+ "smw-search-profile-extended-help-search-syntax-simplified-phrase": "* <code>phrase:</code> 為在完全相同排序裡查找任何含有「...」的項目",
+ "smw-search-profile-extended-help-search-syntax-simplified-has": "* <code>has:</code> 為符合任何具有屬性 \"...\" 的項目(例如:<code>has:(Foo && Bar)</code> 等同於 <code><nowiki>[[Foo::+]] && [[Bar::+]]</nowiki></code>)",
+ "smw-search-profile-extended-help-search-syntax-simplified-not": "* <code>not:</code> 為沒有符合任何包含「...」的項目",
+ "smw-search-profile-extended-help-search-syntax-prefix": "* 額外可用且已定義的自定義字首,例如像是:$1",
+ "smw-search-profile-extended-help-search-syntax-reserved": "* 一些表達式為保留的,例如像是:<nowiki>$1</nowiki>",
+ "smw-search-profile-extended-help-search-syntax-note": "''一些所列出的操作,僅適用於啟用的全文索引或 ElasticStore。''",
"smw-search-profile-extended-help-query": "已使用 <code><nowiki>$1</nowiki></code> 作為查詢。",
+ "smw-search-profile-extended-help-query-link": "(更多詳情$1)。",
+ "smw-search-profile-extended-help-find-forms": "可用表單",
"smw-search-profile-extended-section-sort": "排序依",
+ "smw-search-profile-extended-section-form": "表單",
+ "smw-search-profile-extended-section-search-syntax": "搜尋輸入",
"smw-search-profile-extended-section-namespace": "命名空間",
"smw-search-profile-extended-section-query": "查詢",
+ "smw-search-profile-link-caption-query": "請參閱",
"smw-search-show": "顯示",
"smw-search-hide": "隱藏",
- "log-name-smw": "語意 MediaWiki 日誌",
- "log-show-hide-smw": "$1 語義 MediaWiki 日誌",
+ "log-name-smw": "Semantic MediaWiki 日誌",
+ "log-show-hide-smw": "$1 Semantic MediaWiki 日誌",
"logeventslist-smw-log": "Semantic MediaWiki 日誌",
+ "log-description-smw": "有關[https://www.semantic-mediawiki.org/wiki/Help:Logging 已啟用事件類型]的操作,該已由 Semantic MediaWiki 及其元件所回報。",
"logentry-smw-maintenance": "由 Semantic MediaWiki 發佈出的維護相關事件",
"smw-datavalue-import-unknown-namespace": "匯入的命名空間 \"$1\" 不明,請確認 OWL 匯入詳細資訊,可至 [[MediaWiki:Smw import $1]] 取得。",
"smw-datavalue-import-missing-namespace-uri": "無法在[[MediaWiki:Smw import $1|$1 匯入]]資料中找到 \"$1\" 命名空間的 URI。",
+ "smw-datavalue-import-missing-type": "在 [[MediaWiki:Smw import $2|$2]] 個匯入裡,找不到用於「$1」的類型定義。",
"smw-datavalue-import-link": "[[MediaWiki:Smw import $1|$1 匯入]]",
- "smw-property-predefined-impo": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來描述與[https://semantic-mediawiki.org/wiki/Help:Import_vocabulary 已匯入詞彙]間的關係的預定義屬性。",
- "smw-property-predefined-type": "“$1”是用來描述屬性[[Special:Types|資料類型]]的預設屬性,並由[https://www.semantic-mediawiki.org/wiki/Help:Special_properties 語義MediaWiki]提供。",
+ "smw-datavalue-import-invalid-value": "「$1」不是個有效格式,且預期要含有\"命名空間\":\"識別碼\"(例如:\"foaf:name\")。",
+ "smw-datavalue-import-invalid-format": "字串「$1」預期應分割成四個部分,但格式未能理解。",
+ "smw-property-predefined-impo": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來描述與[https://semantic-mediawiki.org/wiki/Help:Import_vocabulary 已匯入詞彙]間的關係的預先定義屬性。",
+ "smw-property-predefined-type": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來描述屬性[[Special:Types|資料類型]]的預先定義屬性。",
+ "smw-property-predefined-sobj": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來表示出[https://www.semantic-mediawiki.org/wiki/Help:Container 容器]結構的預先定義屬性。",
+ "smw-property-predefined-long-sobj": "容器允許與普通 wiki 頁面相似,但當連結至嵌入主題時,是以不同實體空間的累積屬性-值分配。",
+ "smw-property-predefined-errp": "「$1」是用由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,用來追蹤異常值通知方面輸入錯誤的預先定義屬性。",
+ "smw-property-predefined-long-errp": "在多數情況下,這是由於類型不符合或是[[Property:Allows value|值]]方面的限制所造成。",
+ "smw-property-predefined-pval": "[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Allows_value \"$1\"] 是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,可定義出允許值清單,來對屬性做值分配限制的預先定義屬性。",
+ "smw-property-predefined-pvali": "[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Allows_value_list \"$1\"] 是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,可指定參考文獻至允許值清單,來對屬性做值分配限制的預先定義屬性。",
+ "smw-datavalue-property-restricted-annotation-use": "屬性「$1」有限制應用區域,且不能由使用者來註解屬性。",
+ "smw-datavalue-property-restricted-declarative-use": "屬性「$1」是陳述屬性,且僅能在屬性和分類頁面上使用。",
+ "smw-datavalue-property-create-restriction": "屬性「$1」不存在,且使用者缺少建立或是以未核准屬性來註解值的「$2」權限(查看[https://www.semantic-mediawiki.org/wiki/Help:Authority_mode 權威模式])。",
+ "smw-datavalue-property-invalid-character": "「$1」包含作為屬性標籤一部份的列舉字元「$2」,因此被歸類為無效。",
+ "smw-datavalue-property-invalid-chain": "不允許在註解過程中使用「$1」作為屬性鏈。",
"smw-datavalue-restricted-use": "資料值「$1」被標記為限制使用。",
"smw-datavalue-invalid-number": "\"$1\" 無法作為數字解讀。",
"smw-query-condition-circular": "於 \"$1\" 偵測到可能會發生循環的情況。",
+ "smw-query-condition-empty": "查詢描述含有空的條件。",
"smw-types-list": "資料型態清單",
"smw-types-default": "\"$1\" 是內建的資料型態。",
- "smw-types-help": "更多的資訊與範例可在[https://www.semantic-mediawiki.org/wiki/Help:Type_$1 說明頁面]找到。",
+ "smw-types-help": "更多的資訊與範例可在此[https://www.semantic-mediawiki.org/wiki/Help:Type_$1 說明頁面]找到。",
"smw-type-anu": "\"$1\" 是 [[Special:Types/URL|URL]] 資料型態的變體,大多用在 ''owl:AnnotationProperty'' 匯出宣告。",
- "smw-type-boo": "\"$1\" 是原始資料型態,用來描述真/假值。",
- "smw-type-cod": "\"$1\" 是 [[Special:Types/Text|Text]] 資料型態的變體,使用在不定長度的技術文字,如原始碼清單。",
- "smw-type-geo": "\"$1\" 是資料型態,用來描述地理位置,需要搭配[https://www.semantic-mediawiki.org/wiki/Extension:Maps 擴充功能 \"Maps\"] 使用。",
+ "smw-type-boo": "「$1」是基本資料型態,用來描述真/假值。",
+ "smw-type-cod": "\"$1\" 是[[Special:Types/Text|文字]]資料型態的變體,使用在不定長度的技術文字,如原始碼清單。",
+ "smw-type-geo": "「$1」是資料型態,用來描述地理位置,需要搭配 [https://www.semantic-mediawiki.org/wiki/Extension:Maps \"Maps\"] 擴充功能使用。",
"smw-type-tel": "\"$1\" 是特殊的資料型態,用來描述依 RFC 3966 規範的國際電話號碼。",
- "smw-type-txt": "\"$1\" 是原始資料型態,用來描述任意長度的字串。",
- "smw-type-dat": "\"$1\" 是資料型態,用來代表時間點,使用統一格式。",
+ "smw-type-txt": "「$1」是基本資料型態,用來描述任意長度的字串。",
+ "smw-type-dat": "「$1」是基本資料型態,使用統一格式來代表時間點。",
+ "smw-type-ema": "「$1」是表現出電子郵件的特殊資料類型。",
+ "smw-type-tem": "「$1」是代表溫度的特殊數字資料類型。",
+ "smw-type-qty": "「$1」是以數字表示以及計量單位來描述數量的資料類型。",
+ "smw-type-rec": "「$1」是指定出固定排序類型化的屬性清單之容器資料類型。",
+ "smw-type-extra-tem": "轉換架構含有像是克耳文、攝氏、華氏,以及蘭金溫標這類的支援單位。",
+ "smw-type-tab-properties": "屬性",
+ "smw-type-tab-types": "類型",
"smw-type-tab-errors": "錯誤",
+ "smw-type-primitive": "基本",
+ "smw-type-contextual": "上下文",
+ "smw-type-compound": "合成詞",
+ "smw-specials-bytype-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Type_$1",
+ "smw-specials-types-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Types",
"smw-special-pageproperty-helplink": "https://www.semantic-mediawiki.org/wiki/Help:Special:PageProperty",
+ "smw-special-pageproperty-description": "此頁面提供瀏覽用於找尋屬性全部值與指定頁面的介面。其它可用搜尋介面包括[[Special:SearchByProperty|屬性搜尋]]與[[Special:Ask|請求查詢建置器]]。",
+ "smw-property-predefined-errc": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,表示出現在連接到不恰當值註解或輸入處理時的錯誤之預先定義屬性。",
+ "smw-property-predefined-long-errc": "錯誤會收集於[https://www.semantic-mediawiki.org/wiki/Help:Container 容器]裡,可能會包含導致內容不符的屬性參考文獻。",
+ "smw-property-predefined-errt": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,含有錯誤方面文字描述的預先定義屬性。",
+ "smw-subobject-parser-invalid-naming-scheme": "使用者定義的子物件包含無效的命名架構。使用在前五個字元的點號($1)已被保留用於擴充方面。您可以來設定[https://www.semantic-mediawiki.org/wiki/Help:Adding_subobjects#Named_identifier 命名的識別碼]。",
+ "smw-datavalue-record-invalid-property-declaration": "紀錄定義包含著本身已被聲明為紀錄類型屬性「$1」,因此不被許可。",
+ "smw-property-predefined-mdat": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,對應主題最後一次修改的日期之預先定義屬性。",
+ "smw-property-predefined-cdat": "「$1」是用由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,對應主題首次修訂的日期之預先定義屬性。",
+ "smw-property-predefined-newp": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,表示出是否為新主題的預先定義屬性。",
+ "smw-property-predefined-ledt": "「$1」是用由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,含有使用者所建立出最新一次修訂的頁面名稱之預先定義屬性。",
+ "smw-property-predefined-mime": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來描述已上傳檔案的 MIME 類型之預先定義屬性。",
+ "smw-property-predefined-media": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來描述已上傳檔案的多媒體類型之預先定義屬性。",
+ "smw-property-predefined-askfo": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,持有使用在查詢裡結果格式名稱的預先定義屬性。",
+ "smw-property-predefined-askst": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,以字串來描述查詢條件的預先定義屬性。",
+ "smw-property-predefined-askdu": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,含有查詢執行完畢所需時間值(以秒為單位)的預先定義屬性。",
+ "smw-property-predefined-asksc": "「$1」是用由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,確認替代(例如:遠端、聯合)查詢來源的預先定義屬性。",
+ "smw-property-predefined-askco": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,描述查詢狀態或構成要素的預先定義屬性。",
+ "smw-property-predefined-long-askco": "數字或分配數字代表內部編碼狀態,在[https://www.semantic-mediawiki.org/wiki/Help:Query_profiler 說明頁面]裡含有進一步解釋。",
+ "smw-property-predefined-prec": "「$1」是用於數字資料類型裡[https://www.semantic-mediawiki.org/wiki/Help:Display_precision 顯示精確度](小數位數)的預先定義屬性。",
+ "smw-property-predefined-attch-link": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,收集在頁面裡所找出的內嵌檔案和圖片連結之預先定義屬性。",
+ "smw-types-extra-geo-not-available": "未偵測到[https://www.semantic-mediawiki.org/wiki/Extension:Maps 擴充「Maps」] ,因此「$1」的運作能力被受限。",
+ "smw-datavalue-monolingual-dataitem-missing": "缺少用來建置單語合成詞值的預期項目。",
+ "smw-datavalue-languagecode-missing": "對於「$1」註解,解析器無法判斷語言代碼(例如像:\"foo@en\")。",
+ "smw-datavalue-languagecode-invalid": "「$1」不被認為是支援的語言代碼。",
+ "smw-property-predefined-lcode": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,表示出 BCP47 格式語言代碼的預先定義屬性。",
+ "smw-type-mlt-rec": "「$1」是以特定[[Property:Language code|語言代碼]]來關聯文字值的[https://www.semantic-mediawiki.org/wiki/Help:Container 容器]資料類型。",
+ "smw-types-extra-mlt-lcode": "資料類型{{PLURAL:$2|需要|不需}}語言代碼(註:{{PLURAL:$2|不接受沒有語言代碼的值註解|可接受沒有語言代碼的值註解}})。",
+ "smw-property-predefined-text": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,表示出任意長度文字的預先定義屬性。",
+ "smw-property-predefined-pdesc": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,允許描述在語境裡屬性的預先定義屬性。",
+ "smw-property-predefined-list": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來定義與[[Special:Types/Record|紀錄]]類型屬性一同使用的屬性清單之預先定義屬性。",
+ "smw-limitreport-intext-parsertime": "[SMW]文內註解解析器時間",
+ "smw-limitreport-intext-postproctime": "[SMW]發佈處理時間",
"smw-limitreport-intext-parsertime-value": "$1 {{PLURAL:$1|秒|秒}}",
"smw-limitreport-intext-postproctime-value": "$1 {{PLURAL:$1|秒|秒}}",
+ "smw-limitreport-pagepurge-storeupdatetime": "[SMW]存儲更新時間(在頁面清除時)",
"smw-limitreport-pagepurge-storeupdatetime-value": "$1 {{PLURAL:$1|秒|秒}}",
+ "smw_allows_pattern": "此頁面預期包含參考文獻清單(依據[https://zh.wikipedia.org/wiki/%E6%AD%A3%E5%88%99%E8%A1%A8%E8%BE%BE%E5%BC%8F 正規表示式]),透過[[Property:Allows pattern|允許模式]]參數可用。要編輯此頁面,需要 <code>smw-patternedit</code> 權限。",
+ "smw-datavalue-allows-pattern-mismatch": "「$1」被正規表達式「$2」歸類為無效。",
+ "smw-datavalue-allows-pattern-reference-unknown": "「$1」模式參考文獻不符合在 [[MediaWiki:Smw allows pattern]] 裡的項目。",
+ "smw-datavalue-allows-value-list-unknown": "「$1」清單參考文獻不符合[[MediaWiki:Smw allows list $1]]頁面。",
+ "smw-datavalue-allows-value-list-missing-marker": "「$1」清單內容缺少帶有 * 清單標記的項目。",
+ "smw-datavalue-feature-not-supported": "「$1」功能在此 wiki 不支援或是被停用。",
+ "smw-property-predefined-pvap": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,可指定[[MediaWiki:Smw allows pattern|模式參照]]來套用到[https://zh.wikipedia.org/wiki/%E6%AD%A3%E5%88%99%E8%A1%A8%E8%BE%BE%E5%BC%8F 正規表達式]比對的預先定義屬性。",
+ "smw-property-predefined-dtitle": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,可為實體分配不同顯示標題的預先定義屬性。",
+ "smw-property-predefined-pvuc": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,替各實例限制值分配以達到內容不重複(或最多一個)的預先定義屬性。",
+ "smw-property-predefined-long-pvuc": "唯一性會在兩個值在字面涵義上不相等時建立,且違反任何限制會被歸類為錯誤。",
+ "smw-datavalue-uniqueness-constraint-error": "屬性「$1」僅允許唯一值分配,而「$2」已註解在主題「$3」裡。",
+ "smw-datavalue-uniqueness-constraint-isknown": "屬性「$1」僅允許唯一值註解,「$2」已包含所分配值。「$3」違反了唯一性限制。",
+ "smw-property-predefined-boo": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來代表布林值的[[Special:Types/Boolean|類型]]及預先定義屬性。",
+ "smw-property-predefined-num": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來代表數字值的[[Special:Types/Number|類型]]及預先定義屬性。",
+ "smw-property-predefined-dat": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來代表日期值的[[Special:Types/Date|類型]]及預先定義屬性。",
+ "smw-property-predefined-uri": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來代表 URI/URL 值的[[Special:Types/URL|類型]]及預先定義屬性。",
+ "smw-property-predefined-qty": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來代表數量的[[Special:Types/Quantity|類型]]及預先定義屬性。",
+ "smw-datavalue-time-invalid-offset-zone-usage": "「$1」含有不支援的偏差和區域識別碼。",
+ "smw-datavalue-time-invalid-values": "值「$1」包含在「$2」形式下無法解釋的資訊。",
+ "smw-datavalue-time-invalid-date-components-common": "「$1」包含一些無法解釋的資訊。",
+ "smw-datavalue-time-invalid-date-components-dash": "「$1」含有外部連接號或是其它無效的闡明日期字元。",
+ "smw-datavalue-time-invalid-date-components-empty": "「$1」包含一些空的成份。",
+ "smw-datavalue-time-invalid-date-components-three": "「$1」包含超過闡明日期所需的三個要素。",
+ "smw-datavalue-time-invalid-date-components-sequence": "「$1」含有無法解讀,違反用於日期組件之可用符合模型的序列。",
+ "smw-datavalue-time-invalid-ampm": "「$1」包含作為小時元素的「$2」,這在 12 小時制裡是無效的。",
+ "smw-datavalue-time-invalid-jd": "無法將輸入值「$1」解讀為有效的儒略日,以「$2」內容回報。",
+ "smw-datavalue-time-invalid-prehistoric": "無法解讀過時的輸入值「$1」。例如在舊式上下文裡指定了超過一年或是日曆模組,可能會回傳非預期的結果。",
+ "smw-datavalue-time-invalid": "無法將輸入值「$1」解讀為有效的日期或時間成份,以「$2」內容回報。",
+ "smw-datavalue-external-formatter-uri-missing-placeholder": "格式化 URI 缺少「$1」佔位符。",
+ "smw-datavalue-external-formatter-invalid-uri": "「$1」是無效的 URL。",
+ "smw-datavalue-external-identifier-formatter-missing": "屬性缺少[[Property:External formatter uri|\"外部格式化 URI\"]] 分配。",
+ "smw-datavalue-keyword-maximum-length": "關鍵詞超出最大長度 $1 個{{PLURAL:$1|字元|字元}}。",
+ "smw-property-predefined-eid": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來代表外部識別碼的[[Special:Types/External identifier|類型]]及預先定義屬性。",
+ "smw-property-predefined-peid": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,指定外部識別碼的預先定義屬性。",
+ "smw-property-predefined-pefu": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,以佔位符來指定外部資源的預先定義屬性。",
+ "smw-property-predefined-long-pefu": "URI 預期包含將由[[Special:Types/External identifier|外部識別碼]]值所調整的佔位符,來形成有效的資源參照。",
+ "smw-type-eid": "\"$1\" 是[[Special:Types/Text|文字]]資料型態的變體,需要分配屬性來聲明[[Property:External formatter uri|外部格式化 URI]]。",
+ "smw-property-predefined-keyw": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,可標準化文字且含有限制字元長度的預先定義屬性與[[Special:Types/Keyword|類型]]。",
+ "smw-type-keyw": "\"$1\" 是[[Special:Types/Text|文字]]資料型態的變體,為有限的字元長度,且規範內容的表現形式。",
+ "smw-datavalue-stripmarker-parse-error": "提供的值「$1」含有 [https://en.wikipedia.org/wiki/Help:Strip_markers strip markers] 內容,因此不能被充分解析。",
+ "smw-datavalue-parse-error": "提供的值「$1」無法理解。",
+ "smw-datavalue-propertylist-invalid-property-key": "屬性清單「$1」包含無效的屬性鍵「$2」。",
+ "smw-datavalue-type-invalid-typeuri": "類型「$1」不可轉換成有效的 URI 表述。",
+ "smw-datavalue-wikipage-missing-fragment-context": "Wiki 頁面輸入值「$1」不可在不帶脈絡頁面情況下使用。",
+ "smw-datavalue-wikipage-invalid-title": "頁面類型輸入值「$1」包含無效字元或是內容不完整,導致在查詢或註釋過程裡發生意外結果。",
+ "smw-datavalue-wikipage-property-invalid-title": "屬性「$1」(作為頁面類型)所帶的輸入值「$2」包含無效字元或是內容不完整,導致在查詢或註釋過程裡發生意外結果。",
+ "smw-datavalue-wikipage-empty": "Wiki 頁面輸入值為空(例如像:<code>[[SomeProperty::]], [[]]</code>),因此不能用作為查詢條件的名稱或一部份。",
+ "smw-type-ref-rec": "「$1」是個允許記錄有關值分配之額外資訊(例如:出處資料)的[https://www.semantic-mediawiki.org/wiki/Container 容器]類型。",
"smw-datavalue-reference-outputformat": "$1:$2",
+ "smw-datavalue-reference-invalid-fields-definition": "[[Special:Types/Reference|參考文獻]]類型應為聲明使用[https://www.semantic-mediawiki.org/wiki/Help:Special_property_Has_fields 含有欄位]屬性的屬性清單。",
+ "smw-parser-invalid-json-format": "JSON 解析器回傳了「$1」。",
"smw-property-preferred-title-format": "$1($2)",
+ "smw-property-preferred-label-language-combination-exists": "「$1」不能用於首選標籤,因為語言「$2」已分配給標籤「$3」。",
"smw-parse": "$1",
"smw-clipboard-copy-link": "複製到剪貼簿",
+ "smw-property-userdefined-fixedtable": "「$1」被設置為[https://www.semantic-mediawiki.org/wiki/Fixed_properties 固定屬性],並且任何對其[https://www.semantic-mediawiki.org/wiki/Type_declaration 類型宣告]的變更需要運作 <code>setupStore.php</code> 或是完成特殊[[Special:SemanticMediaWiki|「資料庫與安裝與更新」]]任務。",
"smw-data-lookup": "索取資料中...",
"smw-data-lookup-with-wait": "正在處理請求,可能需花費一些時間。",
"smw-no-data-available": "沒有可用資料。",
+ "smw-property-req-violation-missing-fields": "因定義 <code>Has fields</code> 屬性失敗,屬性「$1」缺少用於註釋「$2」類型的宣告詳情。",
+ "smw-property-req-violation-missing-formatter-uri": "因定義 <code>External formatter URI</code> 屬性失敗,屬性「$1」缺少用於註釋類型的定義詳情。",
+ "smw-property-req-violation-predefined-type": "作為預先定義屬性的「$1」屬性包含「$2」類型宣告,因此與此屬性的預設類型不相容。",
+ "smw-property-req-violation-import-type": "偵測到與所匯入詞彙「$1」預先定義類型不相容的類型宣告。在一般情況下,因為有從匯入定義裡檢索資訊,所以不需要宣告類型。",
+ "smw-property-req-violation-change-propagation-locked-error": "屬性「$1」已調整,並要求使用[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]過程來重新評估分配的實體。此期間屬性頁面會在主要規格更新完成之前被鎖定,以防止中途打斷或是規格衝突。在頁面取消鎖定之前,過程花費的時間會依據[https://www.mediawiki.org/wiki/Manual:Job_queue 任務佇列]排程的大小與頻率。",
+ "smw-property-req-violation-change-propagation-locked-warning": "屬性「$1」已調整,並要求使用[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]過程來重新評估分配的實體。更新花費的時間會依據[https://www.mediawiki.org/wiki/Manual:Job_queue 任務佇列]排程的大小與頻率,並建議延後對屬性進行更改,以防止中途打斷或是規格衝突。",
+ "smw-property-req-violation-change-propagation-pending": "[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]更新正在等待中(估計有 $1 個[https://www.mediawiki.org/wiki/Manual:Job_queue {{PLURAL:$1|任務|任務}}]),建議在處理完成前暫停屬性方面的變動,以防止中途打斷或是規格衝突。",
+ "smw-property-req-violation-missing-maps-extension": "Semantic MediaWiki 無法檢測出[https://www.semantic-mediawiki.org/wiki/Extension:Maps 「Maps」]擴充,該為所選屬性的必要條件,因此受限了此屬性的功能。",
+ "smw-property-req-violation-type": "屬性包含衝突的類型規格,可能會導致值註解無效,因此應讓使用者分配到一個適當的類型。",
+ "smw-change-propagation-protection": "此頁面已被鎖定,以防止當[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]更新在運行時意外的資料變動。在頁面解開鎖定前,會依據[https://www.mediawiki.org/wiki/Manual:Job_queue 任務佇列]排程的大小與頻率花費一段時間。",
+ "smw-category-change-propagation-locked-error": "分類「$1」已調整,並要求使用[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]過程來重新評估分配的實體。此期間分類頁面會在主要規格更新完成之前被鎖定,以防止中途打斷或是規格衝突。在頁面取消鎖定之前,過程花費的時間會依據[https://www.mediawiki.org/wiki/Manual:Job_queue 任務佇列]排程的大小與頻率。",
+ "smw-category-change-propagation-locked-warning": "分類「$1」已調整,並要求使用[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]過程來重新評估分配的實體。更新花費的時間會依據[https://www.mediawiki.org/wiki/Manual:Job_queue 任務佇列]排程的大小與頻率,並建議延後對分類進行更改,以防止中途打斷或是規格衝突。",
+ "smw-category-change-propagation-pending": "[https://www.semantic-mediawiki.org/wiki/Change_propagation 更改傳播]更新正在等待中(估計有 $1 個[https://www.mediawiki.org/wiki/Manual:Job_queue {{PLURAL:$1|任務|任務}}]),建議在處理完成前暫停分類方面的變動,以防止中途打斷或是規格衝突。",
+ "smw-category-invalid-value-assignment": "「$1」未被視為有效分類或值註解。",
+ "protect-level-smw-pageedit": "僅允許俱有頁面編輯權限的使用者(Semantic MediaWiki)",
+ "smw-create-protection": "當[https://www.semantic-mediawiki.org/wiki/Help:Authority_mode 權威模式]啟用後,具有符合「$2」權限的使用者(或是[https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups 使用者群組])會在建立屬性「$1」時受限",
+ "smw-create-protection-exists": "當[https://www.semantic-mediawiki.org/wiki/Help:Authority_mode 權威模式]啟用後,具有符合「$2」權限的使用者(或是[https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups 使用者群組])會在更改屬性「$1」時受限",
+ "smw-edit-protection": "此頁面已被[[Property:Is edit protected|保護]]以防止意外的資料變動,並僅可由擁有編輯權限(\"$1\")的使用者或[https://www.semantic-mediawiki.org/wiki/Help:User_rights_and_user_groups 使用者群組]來編輯。",
+ "smw-edit-protection-disabled": "編輯保護已被停用,因此「$1」不能用於保護實體頁面來免於未經授權的編輯。",
+ "smw-edit-protection-auto-update": "Semantic MediaWiki 已根據「Is edit protected」屬性來更新保護狀態。",
+ "smw-edit-protection-enabled": "編輯已保護內容(Semantic MediaWiki)",
+ "smw-patternedit-protection": "此頁面已被保護,並僅能由具有適當 <code>smw-patternedit</code> [https://www.semantic-mediawiki.org/wiki/Help:Permissions 權限]的使用者編輯。",
+ "smw-property-predefined-edip": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,指示編輯是否受到保護的預先定義屬性。",
+ "smw-property-predefined-long-edip": "儘管任何使用者都能添加此屬性至主題,但僅有專用權限的使用者可以對已被添加的實體做出編輯或解除保護。",
+ "smw-query-reference-link-label": "查詢參考文獻",
+ "smw-format-datatable-emptytable": "表格裡沒有可用資料",
+ "smw-format-datatable-info": "顯示 _TOTAL_ 個項目裡從 _START_ 到 _END_ 的內容",
+ "smw-format-datatable-infoempty": "顯示 0 個項目從 0 到 0 的內容",
+ "smw-format-datatable-infofiltered": "(從 _MAX_ total 項目篩選)",
+ "smw-format-datatable-infothousands": ",",
"smw-format-datatable-lengthmenu": "顯示 _MENU_ 項目",
"smw-format-datatable-loadingrecords": "載入中...",
"smw-format-datatable-processing": "處理中...",
@@ -514,27 +780,84 @@
"smw-format-datatable-last": "最後",
"smw-format-datatable-next": "下一個",
"smw-format-datatable-previous": "上一個",
+ "smw-format-datatable-sortascending": ":啟用升冪排序欄位",
+ "smw-format-datatable-sortdescending": ":啟用降冪排序欄位",
"smw-format-datatable-toolbar-export": "匯出",
"smw-format-list-other-fields-open": " (",
"smw-format-list-other-fields-close": ")",
+ "smw-category-invalid-redirect-target": "分類「$1」包含指向到非分類命名空間的無效重新導向目標。",
+ "smw-parser-function-expensive-execution-limit": "解析功能已達到耗量執行的限制(請參閱 [https://www.semantic-mediawiki.org/wiki/Help:$smwgQExpensiveExecutionLimit <code>$smwgQExpensiveExecutionLimit</code>] 設置參數)。",
+ "smw-postproc-queryref": "Semantic MediaWiki 會在一些必要查詢後期處理條件下,重新整理頁面。",
+ "apihelp-smwinfo-summary": "檢索有關 Semantic MediaWiki 統計資訊與其它詮釋資訊的 API 模組。",
+ "apihelp-ask-summary": "使用請求語言來查詢 Semantic MediaWiki 的 API 模組。",
+ "apihelp-askargs-summary": "使用請求語言作為條件、輸出內容、參數的清單,來查詢 Semantic MediaWiki 的 API 模組。",
+ "apihelp-browsebyproperty-summary": "檢索有關屬性或是屬性清單資訊的 API 模組。",
+ "apihelp-browsebysubject-summary": "檢索有關主題資訊的 API 模組。",
+ "apihelp-smwtask-summary": "執行 Semantic MediaWiki 相關任務的 API 模組。",
+ "apihelp-smwbrowse-summary": "支援在 Semantic MediaWiki 瀏覽不同實體類型行動的 API 模組。",
+ "apihelp-ask-parameter-api-version": "輸出格式:\n;2:用於結果清單,使用 {} 的後端相容格式。\n;3:使用 [] 來作為結果清單的實驗格式。",
+ "smw-api-invalid-parameters": "無效參數「$1」",
+ "smw-parser-recursion-level-exceeded": "$1 個遞迴的層次在解析期間溢出。建議您驗證模板結構,或是如有需要可設置參數 <code>$maxRecursionDepth</code>。",
+ "smw-property-page-list-count": "顯示使用到此屬性的 $1 個{{PLURAL:$1|頁面|頁面}}。",
+ "smw-property-page-list-search-count": "顯示使用到符合值「$2」之屬性的 $1 個{{PLURAL:$1|頁面|頁面}}。",
"smw-property-reserved-category": "分類",
"smw-category": "分類",
+ "smw-datavalue-uri-invalid-scheme": "「$1」未被列入在有效的 URI 架構。",
+ "smw-datavalue-uri-invalid-authority-path-component": "「$1」被確認含有無效的權威「$2」或路徑組成。",
"smw-browse-property-group-title": "屬性群組",
"smw-browse-property-group-label": "屬性群組標籤",
"smw-browse-property-group-description": "屬性群組描述",
+ "smw-property-predefined-ppgr": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,可識別用來替屬性分組實例之實體(主要是分類)的預先定義屬性。",
+ "smw-filter": "篩選",
+ "smw-section-expand": "展開章節",
+ "smw-section-collapse": "摺疊章節",
"smw-ask-format-help-link": "[https://www.semantic-mediawiki.org/wiki/Help:$1_format $1]格式",
+ "smw-help": "說明",
+ "smw-cheat-sheet": "提示",
+ "smw-personal-jobqueue-watchlist": "監視清單(任務佇列)",
+ "smw-property-predefined-label-skey": "排序鍵",
+ "smw-processing": "處理中...",
+ "smw-redirect-target-unresolvable": "目標無法解決,出於原因「$1」",
"smw-types-title": "類型:$1",
+ "smw-schema-namespace-editcontentmodel-disallowed": "不允許更改[https://www.semantic-mediawiki.org/wiki/Help:Schema 架構頁面]的內容模組。",
+ "smw-schema-namespace-edit-protection": "此頁面已被保護,並僅能由具有適當 <code>smw-schemaedit</code> [https://www.semantic-mediawiki.org/wiki/Help:Permissions 權限]的使用者編輯。",
"smw-schema-error": "驗證錯誤",
+ "smw-schema-error-schema": "用於目前架構的規格與驗證「$1」發現以下不相容或不合規則:",
+ "smw-schema-error-violation": "不合規則(\"$1\",\"$2\")",
+ "smw-schema-error-type-missing": "內容缺少可用於識別且用在[https://www.semantic-mediawiki.org/wiki/Help:Schema 架構命名空間]的類型",
+ "smw-schema-error-type-unknown": "類型「$1」未註冊,因此不能用於[https://www.semantic-mediawiki.org/wiki/Help:Schema 架構命名空間]內容裡。",
+ "smw-schema-title": "架構",
"smw-schema-type-help-link": "https://www.semantic-mediawiki.org/wiki/Help:Schema/Type/$1",
"smw-schema-type": "類型",
+ "smw-schema-description-link-format-schema": "此架構類型預期來定義出與分配給屬性的[[Property:Formatter schema|格式化架構]]相關,用於創建上下文有關連結的字元。",
+ "smw-schema-description-search-form-schema": "此架構類型預期用來定義用於[https://www.semantic-mediawiki.org/wiki/Help:SMWSearch 擴充搜尋]偏好設定的輸入表單與字元,其中包含如何產生輸入欄位、定義預設命名空間、或是宣告用於搜尋請求之字首表達的說明。",
"smw-schema-tag": "{{PLURAL:$1|標籤|標籤}}",
+ "smw-property-predefined-schema-desc": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,儲存架構描述的預先定義屬性。",
+ "smw-property-predefined-schema-def": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,儲存架構內容的預先定義屬性。",
+ "smw-property-predefined-schema-tag": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 提供,識別綱要收集的預先定義屬性。",
+ "smw-property-predefined-long-schema-tag": "識別相似內容或特徵之綱要的標籤。",
+ "smw-property-predefined-schema-type": "「$1」是由 [https://www.semantic-mediawiki.org/wiki/Help:Special_properties Semantic MediaWiki] 所提供,用來描述可區分架構類型的預先定義屬性。",
+ "smw-property-predefined-long-schema-type": "各[https://www.semantic-mediawiki.org/wiki/Help:Schema/Type 類型]預期透過[https://www.semantic-mediawiki.org/wiki/Help:Schema#validation 驗證模組]來提供本身的語法元素闡明、限制、表達。",
"smw-ask-title-keyword-type": "關鍵字搜尋",
+ "smw-ask-message-keyword-type": "此搜尋符合 <code><nowiki>$1</nowiki></code> 條件。",
+ "smw-remote-source-unavailable": "無法連接至遠端「$1」目標。",
+ "smw-remote-source-disabled": "來源'''$1'''已停用遠端請求支援!",
+ "smw-remote-source-unmatched-id": "來源「'''$1'''」不符合可支援遠端請求的 Semantic MediaWiki 版本。",
+ "smw-remote-request-note": "結果已從遠端來源「'''$1'''」檢索,並且可能用於產生包含目前 wiki 的不可用資訊內容。",
+ "smw-remote-request-note-cached": "結果已從遠端來源「'''$1'''」給'''快取''',並且可能用於產生包含目前 wiki 的不可用資訊內容。",
"smw-parameter-missing": "遺失參數「$1」。",
+ "smw-property-tab-usage": "使用量",
+ "smw-property-tab-redirects": "同義詞",
+ "smw-property-tab-subproperties": "子屬性",
+ "smw-property-tab-errors": "不適當分配",
"smw-property-tab-specification": "... 更多",
"smw-concept-tab-list": "清單",
"smw-concept-tab-errors": "錯誤",
"smw-ask-tab-result": "結果",
"smw-ask-tab-extra": "額外",
"smw-ask-tab-debug": "除錯",
- "smw-ask-tab-code": "代碼"
+ "smw-ask-tab-code": "代碼",
+ "smw-install-incomplete-intro": "<b>Semantic MediaWiki</b> 的安裝(或更新)尚未結束,在使用者繼續創建或更動內容之前,管理員需執行以下任務來防止資料不一致。",
+ "smw-install-incomplete-populate-hash-field": "在設定過程中裡有略過填充 <code>smw_hash</code> 欄位,需要 [https://www.semantic-mediawiki.org/wiki/Help:populateHashField.php populateHashField.php] 手稿來執行。",
+ "smw-helplink": "https://www.semantic-mediawiki.org/wiki/Help:$1"
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/IdeAliases.php b/www/wiki/extensions/SemanticMediaWiki/includes/IdeAliases.php
index dfdaa65f..3c83dd78 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/IdeAliases.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/IdeAliases.php
@@ -44,7 +44,7 @@ class SMWRefreshJob extends SMW\RefreshJob {
abstract class SMWResultPrinter extends SMW\ResultPrinter {
}
-class SMWCategoryResultPrinter extends SMW\CategoryResultPrinter {
+class SMWCategoryResultPrinter extends SMW\Query\ResultPrinters\CategoryResultPrinter {
}
class SMWDSVResultPrinter extends SMW\DsvResultPrinter {
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/RecurringEvents.php b/www/wiki/extensions/SemanticMediaWiki/includes/RecurringEvents.php
index 3d4025bb..1a171fec 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/RecurringEvents.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/RecurringEvents.php
@@ -11,7 +11,7 @@ use SMWDITime;
*
* This class determines recurring events based on invoked parameters
*
- * @see http://semantic-mediawiki.org/wiki/Help:Recurring_events
+ * @see https://www.semantic-mediawiki.org/wiki/Help:Recurring_events
*
* @license GNU GPL v2+
* @since 1.9
@@ -53,15 +53,6 @@ class RecurringEvents {
private $maxNumRecurringEvents = 25;
/**
- * @since 1.9
- *
- * @param array $parameters
- */
- public function __construct( array $parameters ) {
- $this->parse( $parameters );
- }
-
- /**
* @since 2.5
*
* @param integer $defaultNumRecurringEvents
@@ -157,7 +148,7 @@ class RecurringEvents {
*
* @param array $parameters
*/
- private function parse( array $parameters ) {
+ public function parse( array $parameters ) {
// Initialize variables.
$all_date_strings = [];
$start_date = $end_date = $unit = $period = $week_num = null;
@@ -292,18 +283,22 @@ class RecurringEvents {
$display_month = ( $cur_month == 0 ) ? 12 : $cur_month;
}
- // If the date is February 29, and this isn't
- // a leap year, change it to February 28.
- if ( $cur_month == 2 && $cur_day == 29 ) {
- if ( !date( 'L', strtotime( "$cur_year-1-1" ) ) ) {
- $cur_day = 28;
- }
- }
+ // If the date is greater than 28 for February, and it is not
+ // a leap year, change it to be a fixed 28 otherwise set it to
+ // 29 (for a leap year date)
+ if ( $cur_month == 2 && $cur_day > 28 ) {
+ $cur_day = !date( 'L', strtotime( "$cur_year-1-1" ) ) ? 28 : 29;
+ } elseif ( $cur_day > 30 ) {
+ // Check whether 31 is a valid day of a month
+ $cur_day = ( $display_month - 1 ) % 7 % 2 ? 30 : 31;
+ }
$date_str = "$cur_year-$display_month-$cur_day $cur_time";
$cur_date = DataValueFactory::getInstance()->newTypeIDValue( '_dat', $date_str );
$all_date_strings = array_merge( $all_date_strings, $included_dates);
- $cur_date_jd = $cur_date->getDataItem()->getJD();
+ if ( $cur_date->isValid() ) {
+ $cur_date_jd = $cur_date->getDataItem()->getJD();
+ }
} elseif ( $unit == 'dayofweekinmonth' ) {
// e.g., "3rd Monday of every month"
$prev_month = $cur_date->getMonth();
@@ -313,7 +308,7 @@ class RecurringEvents {
if ( $new_month == 0 ) {
$new_month = 12;
}
-
+
$new_year = $prev_year + floor( ( $prev_month + $period - 1 ) / 12 );
$cur_date_jd += ( 28 * $period ) - 7;
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/Settings.php b/www/wiki/extensions/SemanticMediaWiki/includes/Settings.php
index 7093cbf8..64d0b3d0 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/Settings.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/Settings.php
@@ -48,6 +48,8 @@ class Settings extends Options {
'smwgExtraneousLanguageFileDir' => $GLOBALS['smwgExtraneousLanguageFileDir'],
'smwgServicesFileDir' => $GLOBALS['smwgServicesFileDir'],
'smwgResourceLoaderDefFiles' => $GLOBALS['smwgResourceLoaderDefFiles'],
+ 'smwgMaintenanceDir' => $GLOBALS['smwgMaintenanceDir'],
+ 'smwgConfigFileDir' => $GLOBALS['smwgConfigFileDir'],
'smwgImportFileDirs' => $GLOBALS['smwgImportFileDirs'],
'smwgImportReqVersion' => $GLOBALS['smwgImportReqVersion'],
'smwgSemanticsEnabled' => $GLOBALS['smwgSemanticsEnabled'],
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/Setup.php b/www/wiki/extensions/SemanticMediaWiki/includes/Setup.php
index cb83e803..33d215a4 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/Setup.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/Setup.php
@@ -147,6 +147,15 @@ final class Setup {
}
/**
+ * @since 3.0
+ *
+ * @param array &$vars
+ */
+ public function loadSchema( &$vars ) {
+ Installer::loadSchema( $vars );
+ }
+
+ /**
* @since 1.9
*
* @param array &$vars
@@ -154,17 +163,16 @@ final class Setup {
*/
public function init( &$vars, $directory ) {
- if ( $this->isValid() === false ) {
-
- $text = 'Semantic MediaWiki was installed and enabled but is missing an appropriate ';
- $text .= '<a href="https://www.semantic-mediawiki.org/wiki/Help:Upgrade">upgrade key</a>. ';
- $text .= 'Please run MediaWiki\'s <a href="https://www.mediawiki.org/wiki/Manual:Update.php">update.php</a> ';
- $text .= 'or Semantic MediaWiki\'s <a href="https://www.semantic-mediawiki.org/wiki/Help:SetupStore.php">setupStore.php</a> maintenance script first. ';
- $text .= 'You may also consult the following pages:';
- $text .= '<ul><li><a href="https://www.semantic-mediawiki.org/wiki/Help:Installation">Installation</a></li>';
- $text .= '<li><a href="https://www.semantic-mediawiki.org/wiki/Help:Installation/Troubleshooting">Troubleshooting</a></li></ul>';
+ $this->initMessageCallbackHandler();
- smwfAbort( $text );
+ if ( $this->isValid() === false ) {
+ smwfAbort(
+ Message::get( [ 'smw-upgrade-error', $vars['smwgUpgradeKey'] ], Message::PARSE ) .
+ '<h3>' . Message::get( 'smw-upgrade-error-why-title' ) . '</h3>' .
+ Message::get( 'smw-upgrade-error-why-explain', Message::PARSE ) .
+ '<h3>' . Message::get( 'smw-upgrade-error-how-title' ) . '</h3>' .
+ Message::get( 'smw-upgrade-error-how-explain', Message::PARSE )
+ );
}
$this->addDefaultConfigurations( $vars );
@@ -174,7 +182,6 @@ final class Setup {
}
$this->initConnectionProviders( );
- $this->initMessageCallbackHandler();
$this->registerJobClasses( $vars );
$this->registerPermissions( $vars );
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Record.php b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Record.php
index 940ac723..f4bab7e6 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Record.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Record.php
@@ -101,7 +101,7 @@ class SMWRecordValue extends AbstractMultiValue {
$diProperty,
$values[$valueIndex],
false,
- $this->getContextPage()
+ $containerSemanticData->getSubject()
);
if ( $dataValue->isValid() ) { // valid DV: keep
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_URI.php b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_URI.php
index d6cc88a0..94724268 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_URI.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_URI.php
@@ -146,6 +146,11 @@ class SMWURIValue extends SMWDataValue {
$hierpart = substr( $hierpart, 2 );
}
+ // #3540
+ if ( $hierpart !== '' && $hierpart[0] === '/' ) {
+ return $this->addErrorMsg( [ 'smw-datavalue-uri-invalid-authority-path-component', $value, $hierpart ] );
+ }
+
break;
case SMW_URI_MODE_TEL:
$scheme = 'tel';
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_WikiPage.php b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_WikiPage.php
index 3fa5edd0..c1c1579e 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_WikiPage.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_WikiPage.php
@@ -139,7 +139,7 @@ class SMWWikiPageValue extends SMWDataValue {
// instance to distinguish [[~Foo*]] from [[Help:~Foo*]]
if ( $this->getOption( self::OPT_QUERY_COMP_CONTEXT ) || $this->getOption( self::OPT_QUERY_CONTEXT ) ) {
- $title = Title::newFromText( $value );
+ $title = Title::newFromText( $value, $this->m_fixNamespace );
// T:P0427 If the user value says `ab c*` then make sure to use this one
// instead of the transformed DBKey which would be `Ab c*`
@@ -479,20 +479,45 @@ class SMWWikiPageValue extends SMWDataValue {
* @return Title
*/
public function getTitle() {
- if ( ( $this->isValid() ) && is_null( $this->m_title ) ) {
- $this->m_title = $this->m_dataitem->getTitle();
- if ( is_null( $this->m_title ) ) { // should not normally happen, but anyway ...
- $this->addErrorMsg(
- [
- 'smw_notitle',
- Localizer::getInstance()->getNamespaceTextById( $this->m_dataitem->getNamespace() ) . ':' . $this->m_dataitem->getDBkey()
- ]
+ if ( $this->m_title !== null ) {
+ return $this->m_title;
+ }
+
+ if ( $this->isValid() ) {
+
+ if ( ( $title = $this->m_dataitem->getTitle() ) !== null ) {
+ return $this->m_title = $title;
+ }
+
+ // #3278, Special handling of `>` in the user namespace, MW (1.31+)
+ // added a prefix to users that originate from imported content
+ if (
+ $this->m_dataitem->getNamespace() === NS_USER &&
+ strpos( $this->m_dataitem->getDBkey(), '>' ) !== false ) {
+
+ $this->setOption( self::OPT_DISABLE_INFOLINKS, true );
+
+ $this->m_title = Title::newFromText(
+ $this->m_dataitem->getDBkey()
);
+
+ return $this->m_title;
}
}
- return $this->m_title;
+ $errArg = $this->m_caption;
+
+ if ( $this->isValid() ) {
+ $ns = Localizer::getInstance()->getNamespaceTextById(
+ $this->m_dataitem->getNamespace()
+ );
+
+ $errArg = "$ns:" . $this->m_dataitem->getDBkey();
+ }
+
+ // Should not normally happen, but anyway ...
+ $this->addErrorMsg( [ 'smw_notitle', $errArg ] );
}
/**
diff --git a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DataValue.php b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DataValue.php
index b9dad499..a4becb46 100644
--- a/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DataValue.php
+++ b/www/wiki/extensions/SemanticMediaWiki/includes/datavalues/SMW_DataValue.php
@@ -72,11 +72,16 @@ abstract class SMWDataValue {
const OPT_QUERY_COMP_CONTEXT = 'query.comparator.context';
/**
- * Option to disable an infolinks highlight/tooltip
+ * Option to disable related infolinks
*/
const OPT_DISABLE_INFOLINKS = 'disable.infolinks';
/**
+ * Option to disable service links
+ */
+ const OPT_DISABLE_SERVICELINKS = 'disable.servicelinks';
+
+ /**
* Option to use compact infolinks
*/
const OPT_COMPACT_INFOLINKS = 'compact.infolinks';
@@ -621,11 +626,15 @@ abstract class SMWDataValue {
*/
public function getInfolinkText( $outputformat, $linker = null ) {
+ if ( $this->getOption( self::OPT_DISABLE_INFOLINKS ) === true ) {
+ return '';
+ }
+
if ( $this->infoLinksProvider === null ) {
$this->infoLinksProvider = $this->dataValueServiceFactory->newInfoLinksProvider( $this );
}
- if ( $this->getOption( self::OPT_DISABLE_INFOLINKS ) === true ) {
+ if ( $this->getOption( self::OPT_DISABLE_SERVICELINKS ) === true ) {
$this->infoLinksProvider->disableServiceLinks();
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/maintenance/README.md b/www/wiki/extensions/SemanticMediaWiki/maintenance/README.md
index 92d8dd4e..37f675da 100644
--- a/www/wiki/extensions/SemanticMediaWiki/maintenance/README.md
+++ b/www/wiki/extensions/SemanticMediaWiki/maintenance/README.md
@@ -21,4 +21,86 @@ MediaWiki location:
In some setups that use a lot of shared code for many wikis, it might be
required to specify the location of "LocalSettings.php" explicitly, too:
- export MW_INSTALL_PATH="/path/to/mediawiki" && php setupStore.php --conf=/path/to/mediawiki/LocalSettings.php
+```
+export MW_INSTALL_PATH="/path/to/mediawiki" && php setupStore.php --conf=/path/to/mediawiki/LocalSettings.php
+```
+
+### dumpRDF.php
+
+Complete RDF export of existing triples.
+
+Usage:
+- php dumpRDF.php
+- [--categories|--classes|--concepts|--conf|--d|--dbpass|--dbuser|--e|--file|--globals|--help|--individuals|--memory-limit|--page|--profiler|--properties|--quiet|--server|--types|--wiki]
+
+### populateHashField.php
+
+Populate the `smw_hash` field for all entities that have a missing entry.
+
+Usage:
+- php populateHashField.php
+- [--conf|--dbpass|--dbuser|--globals|--help|--memory-limit|--profiler|--quiet|--server|--wiki]
+
+### rebuildConceptCache.php
+
+Manages concept caches in Semantic MediaWiki.
+
+Usage:
+- php rebuildConceptCache.php
+- [--concept|--conf|--create|--dbpass|--dbuser|--debug|--delete|--e|--globals|--hard|--help|--memory-limit|--old|--profiler|--quiet|--report-runtime|--s|--server|--status|--update|--verbose|--wiki|--with-maintenance-log]
+
+### rebuildData.php
+
+Recreates all the semantic data in the database
+
+Usage:
+- php rebuildData.php
+- [--b|--categories|--conf|--d|--dbpass|--dbuser|--debug|--dispose-outdated|--e|--exception-log|--f|--force-update|--globals|--help|--ignore-exceptions|--memory-limit|--n|--no-cache|--p|--page|--profiler|--property-statistics|--query|--quiet|--redirects|--report-poolcache|--report-runtime|--revision-mode|--s|--server|--shallow-update|--skip-properties|--startidfile|--v|--wiki|--with-maintenance-log]
+
+### rebuildElasticIndex.php
+
+Rebuilds the Elasticsearch index.
+
+Usage:
+- php rebuildElasticIndex.php
+- [--conf|--dbpass|--dbuser|--debug|--delete-all|--e|--force-refresh|--globals|--help|--memory-limit|--page|--profiler|--quiet|--report-runtime|--run-fileindex|--s|--server|--skip-fileindex|--update-settings|--wiki]
+
+### rebuildFulltextSearchTable.php
+
+Rebuilds the fulltext search index.
+
+Usage:
+- php rebuildFulltextSearchTable.php
+- [--conf|--dbpass|--dbuser|--globals|--help|--memory-limit|--optimize|--profiler|--quick|--quiet|--report-runtime|--server|--v|--wiki|--with-maintenance-log]
+
+### rebuildPropertyStatistics.php
+
+Rebuilds the property usage statistics
+
+Usage:
+- php rebuildPropertyStatistics.php
+- [--conf|--dbpass|--dbuser|--globals|--help|--memory-limit|--profiler|--quiet|--server|--wiki|--with-maintenance-log]
+
+### removeDuplicateEntities.php
+
+Removes duplicate entities.
+
+Usage:
+- php removeDuplicateEntities.php
+- [--conf|--dbpass|--dbuser|--globals|--help|--memory-limit|--profiler|--quiet|--s|--server|--wiki]
+
+### setupStore.php
+
+Sets up the storage backend.
+
+Usage:
+- php setupStore.php
+- [--backend|--conf|--dbpass|--dbuser|--delete|--globals|--help|--memory-limit|--nochecks|--profiler|--quiet|--server|--skip-import|--skip-optimize|--wiki]
+
+### updateEntityCollation.php
+
+Updates the `smw_sort` field.
+
+Usage:
+- php updateEntityCollation.php
+- [--conf|--dbpass|--dbuser|--globals|--help|--memory-limit|--profiler|--quiet|--s|--server|--wiki]
diff --git a/www/wiki/extensions/SemanticMediaWiki/maintenance/populateHashField.php b/www/wiki/extensions/SemanticMediaWiki/maintenance/populateHashField.php
new file mode 100644
index 00000000..e19d0e69
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/maintenance/populateHashField.php
@@ -0,0 +1,222 @@
+<?php
+
+namespace SMW\Maintenance;
+
+use Onoi\MessageReporter\MessageReporter;
+use SMW\ApplicationFactory;
+use SMW\SQLStore\SQLStore;
+use SMW\SQLStore\Installer;
+use SMW\Setup;
+use SMW\Store;
+
+$basePath = getenv( 'MW_INSTALL_PATH' ) !== false ? getenv('MW_INSTALL_PATH' ) : __DIR__ . '/../../..';
+
+require_once $basePath . '/maintenance/Maintenance.php';
+
+/**
+ * @license GNU GPL v2+
+ * @since 3.1
+ *
+ * @author mwjames
+ */
+class PopulateHashField extends \Maintenance {
+
+ /**
+ * Threshold as the when the `populateHashField.php` should be used by an
+ * administrator instead.
+ *
+ * This postpones the execution to after `setupStore.php`/`update.php` in
+ * order to help minimize the time required for the initial setup/upgrade.
+ */
+ const COUNT_SCRIPT_EXECUTION_THRESHOLD = 200000;
+
+ /**
+ * @var Store
+ */
+ private $store;
+
+ /**
+ * @var MessageReporter
+ */
+ private $messageReporter;
+
+ /**
+ * @since 3.1
+ */
+ public function __construct() {
+ $this->mDescription = "Populate the 'smw_hash' field for all entities that have a missing entry.";
+ parent::__construct();
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param Store $store
+ */
+ public function setComplete( $incomplete ) {
+
+ $this->reportMessage(
+ " ... writing the status to the setup information file ... \n"
+ );
+
+ Installer::setUpgradeFile(
+ $GLOBALS,
+ [
+ Installer::POPULATE_HASH_FIELD_COMPLETE => $incomplete
+ ]
+ );
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param Store $store
+ */
+ public function setStore( Store $store ) {
+ $this->store = $store;
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param MessageReporter $messageReporter
+ */
+ public function setMessageReporter( MessageReporter $messageReporter ) {
+ $this->messageReporter = $messageReporter;
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param string $message
+ */
+ public function reportMessage( $message ) {
+
+ if ( $this->messageReporter !== null ) {
+ return $this->messageReporter->reportMessage( $message );
+ }
+
+ $this->output( $message );
+ }
+
+ /**
+ * @see Maintenance::execute
+ */
+ public function execute() {
+
+ if ( !Setup::isEnabled() ) {
+ $this->reportMessage( "\nYou need to have Semantic MediaWiki enabled in order to run the maintenance script!\n" );
+ exit;
+ }
+
+ $this->store = ApplicationFactory::getInstance()->getStore(
+ 'SMW\SQLStore\SQLStore'
+ );
+
+ $this->reportMessage( "\nChecking 'smw_hash' field consistency ...\n" );
+ $this->populate();
+
+ $this->reportMessage( " ... done.\n" );
+
+ return true;
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @return Iterator
+ */
+ public function fetchRows() {
+
+ $connection = $this->store->getConnection( 'mw.db' );
+
+ return $connection->select(
+ SQLStore::ID_TABLE,
+ [
+ 'smw_id',
+ 'smw_title',
+ 'smw_namespace',
+ 'smw_iw',
+ 'smw_subobject'
+ ],
+ [
+ 'smw_hash' => null,
+ 'smw_iw != ' . $connection->addQuotes( SMW_SQL3_SMWDELETEIW )
+ ],
+ __METHOD__
+ );
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param Iterator $rows
+ */
+ public function populate( \Iterator $rows = null ) {
+
+ if ( $rows === null ) {
+ $rows = $this->fetchRows();
+ }
+
+ $connection = $this->store->getConnection( 'mw.db' );
+ $idTable = $this->store->getObjectIds();
+
+ $count = 0;
+ $i = 0;
+
+ if ( $rows !== null ) {
+ $count = $rows->numRows();
+ }
+
+ if ( $count == 0 ) {
+ $this->reportMessage( " ... all rows populated ...\n" );
+ } else {
+ $this->reportMessage( " ... missing $count rows ...\n" );
+
+ foreach ( $rows as $row ) {
+
+ $hash = $idTable->computeSha1(
+ [
+ $row->smw_title,
+ (int)$row->smw_namespace,
+ $row->smw_iw,
+ $row->smw_subobject
+ ]
+ );
+
+ $this->reportMessage(
+ $this->progress( $row->smw_id, $i++, $count )
+ );
+
+ $connection->update(
+ SQLStore::ID_TABLE,
+ [
+ 'smw_hash' => $hash
+ ],
+ [
+ 'smw_id' => $row->smw_id
+ ],
+ __METHOD__
+ );
+ }
+ }
+
+ $this->reportMessage( "\n" );
+ $this->setComplete( true );
+ }
+
+ /**
+ * @see Maintenance::addDefaultParams
+ */
+ protected function addDefaultParams() {
+ parent::addDefaultParams();
+ }
+
+ private function progress( $id, $i, $count ) {
+ return "\r". sprintf( "%-35s%s", " ... updating document no.", sprintf( "%s (%1.0f%%)", $id, round( ( $i / $count ) * 100 ) ) );
+ }
+
+}
+
+$maintClass = 'SMW\Maintenance\PopulateHashField';
+require_once( RUN_MAINTENANCE_IF_MAIN );
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/DataValues/ReferenceValue.php b/www/wiki/extensions/SemanticMediaWiki/src/DataValues/ReferenceValue.php
index ec0082a8..cbcb4208 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/DataValues/ReferenceValue.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/DataValues/ReferenceValue.php
@@ -212,7 +212,7 @@ class ReferenceValue extends AbstractMultiValue {
$property,
$values[$index],
false,
- $this->getContextPage()
+ $containerSemanticData->getSubject()
);
if ( $dataValue->isValid() ) { // valid DV: keep
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php b/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php
index 67bc66ad..e9408dfc 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/FileIndexer.php
@@ -198,7 +198,7 @@ class FileIndexer {
// Avoid a "failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found"
$file_headers = @get_headers( $url );
- if ( $file_headers[0] !== 'HTTP/1.1 404 Not Found' && $file_headers[0] !== 'HTTP/1.0 404 Not Found' ) {
+ if ( $file_headers !== false && $file_headers[0] !== 'HTTP/1.1 404 Not Found' && $file_headers[0] !== 'HTTP/1.0 404 Not Found' ) {
$contents = file_get_contents( $url );
} else {
$this->logger->info( [ 'File indexer', "HTTP/1.1 404 Not Found for $url" ], $context );
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/Indexer.php b/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/Indexer.php
index 12283d50..98e177a9 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/Indexer.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Elastic/Indexer/Indexer.php
@@ -553,6 +553,9 @@ class Indexer {
private function map_data( $bulk, $changeDiff ) {
+ $dbType = $this->store->getInfo( 'db' );
+ $unescape_bytea = isset( $dbType['postgres'] );
+
$inserts = [];
$inverted = [];
@@ -580,7 +583,7 @@ class Indexer {
continue;
}
- $this->mapRows( $fieldChangeOp, $propertyList, $inserts, $inverted );
+ $this->mapRows( $fieldChangeOp, $propertyList, $inserts, $inverted, $unescape_bytea );
}
}
@@ -593,7 +596,7 @@ class Indexer {
}
}
- private function mapRows( $fieldChangeOp, $propertyList, &$insertRows, &$invertedRows ) {
+ private function mapRows( $fieldChangeOp, $propertyList, &$insertRows, &$invertedRows, $unescape_bytea ) {
// The structure to be expected in ES:
//
@@ -674,6 +677,13 @@ class Indexer {
$type = 'txtField';
$val = $ins['o_blob'] === null ? $ins['o_hash'] : $ins['o_blob'];
+ // Postgres requires special handling of blobs otherwise escaped
+ // text elements are used as index input
+ // Tests: P9010, Q0704, Q1206, and Q0103
+ if ( $unescape_bytea && $ins['o_blob'] !== null ) {
+ $val = pg_unescape_bytea( $val );
+ }
+
// #3020, 3035
if ( isset( $prop['_type'] ) && $prop['_type'] === '_keyw' ) {
$val = DIBlob::normalize( $ins['o_hash'] );
@@ -686,6 +696,11 @@ class Indexer {
} elseif ( $fieldChangeOp->has( 'o_serialized' ) && $fieldChangeOp->has( 'o_blob' ) ) {
$type = 'uriField';
$val = $ins['o_blob'] === null ? $ins['o_serialized'] : $ins['o_blob'];
+
+ if ( $unescape_bytea && $ins['o_blob'] !== null ) {
+ $val = pg_unescape_bytea( $val );
+ }
+
} elseif ( $fieldChangeOp->has( 'o_serialized' ) && $fieldChangeOp->has( 'o_sortkey' ) ) {
$type = strpos( $ins['o_serialized'], '/' ) !== false ? 'datField' : 'numField';
$val = (float)$ins['o_sortkey'];
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotReadableException.php b/www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotReadableException.php
new file mode 100644
index 00000000..83e2ad68
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotReadableException.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace SMW\Exception;
+
+use RuntimeException;
+
+/**
+ * @license GNU GPL v2+
+ * @since 3.0
+ *
+ * @author mwjames
+ */
+class FileNotReadableException extends RuntimeException {
+
+ /**
+ * @since 3.0
+ *
+ * @param string $file
+ */
+ public function __construct( $file ) {
+ parent::__construct( "$file is not readable." );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotWritableException.php b/www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotWritableException.php
new file mode 100644
index 00000000..a9ccb44f
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Exception/FileNotWritableException.php
@@ -0,0 +1,24 @@
+<?php
+
+namespace SMW\Exception;
+
+use RuntimeException;
+
+/**
+ * @license GNU GPL v2+
+ * @since 3.0
+ *
+ * @author mwjames
+ */
+class FileNotWritableException extends RuntimeException {
+
+ /**
+ * @since 3.0
+ *
+ * @param string $file
+ */
+ public function __construct( $file ) {
+ parent::__construct( "$file is not writable." );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Factbox/Factbox.php b/www/wiki/extensions/SemanticMediaWiki/src/Factbox/Factbox.php
index 61eec849..feae3999 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Factbox/Factbox.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Factbox/Factbox.php
@@ -407,7 +407,7 @@ class Factbox {
$outputFormat = $dataValue->getOutputFormat();
$dataValue->setOutputFormat( $outputFormat ? $outputFormat : 'LOCL' );
- $dataValue->setOption( $dataValue::OPT_DISABLE_INFOLINKS, true );
+ $dataValue->setOption( $dataValue::OPT_DISABLE_SERVICELINKS, true );
if ( $dataValue->isValid() ) {
$list[] = $dataValue->getLongWikiText( true ) . $dataValue->getInfolinkText( SMW_OUTPUT_WIKI );
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Connection/Query.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Connection/Query.php
index 0c83b33f..7b55d457 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Connection/Query.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Connection/Query.php
@@ -121,7 +121,7 @@ class Query {
*/
public function hasField( $field = '' ) {
- if ( $field === '' ) {
+ if ( (string)$field === '' ) {
return $this->fields !== [];
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php
index 761ee6cc..f63406ff 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/CallableUpdate.php
@@ -323,7 +323,7 @@ class CallableUpdate implements DeferrableUpdate {
];
}
- private function emptyCallback() {
+ protected function emptyCallback() {
$this->logger->info(
[
'DeferrableUpdate',
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/TransactionalCallableUpdate.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/TransactionalCallableUpdate.php
index 7feff7eb..d98d6983 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/TransactionalCallableUpdate.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Deferred/TransactionalCallableUpdate.php
@@ -171,7 +171,7 @@ class TransactionalCallableUpdate extends CallableUpdate {
*/
public function cancelOnRollback( $trigger ) {
if ( $trigger === Database::TRIGGER_ROLLBACK ) {
- $this->callback = null;
+ $this->callback = [ $this, 'emptyCancelCallback' ];
}
}
@@ -265,4 +265,11 @@ class TransactionalCallableUpdate extends CallableUpdate {
}
}
+ protected function emptyCancelCallback() {
+ $this->logger->info(
+ [ 'DeferrableUpdate', 'cancelOnRollback' ],
+ [ 'role' => 'developer', 'method' => __METHOD__ ]
+ );
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/BeforePageDisplay.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/BeforePageDisplay.php
index b249634e..34324af1 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/BeforePageDisplay.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/BeforePageDisplay.php
@@ -6,6 +6,8 @@ use OutputPage;
use Skin;
use SpecialPage;
use Title;
+use SMW\Message;
+use Html;
/**
* BeforePageDisplay hook which allows last minute changes to the
@@ -49,6 +51,10 @@ class BeforePageDisplay extends HookHandler {
$outputPage->addModules( 'ext.smw.suggester.textInput' );
}
+ if ( ( $tasks = $this->getOption( 'installer.incomplete_tasks', [] ) ) !== [] ) {
+ $outputPage->prependHTML( $this->incompleteTasksHTML( $tasks ) );
+ }
+
// Add export link to the head
if ( $title instanceof Title && !$title->isSpecialPage() ) {
$link['rel'] = 'alternate';
@@ -67,4 +73,21 @@ class BeforePageDisplay extends HookHandler {
return true;
}
+ private function incompleteTasksHTML( array $messages ) {
+
+ $html = '';
+
+ foreach ( $messages as $message ) {
+ $html .= Html::rawElement( 'li', [], Message::get( $message, Message::PARSE ) );
+ }
+
+ return Html::rawElement(
+ 'div',
+ [
+ 'class' => 'smw-callout smw-callout-error plainlinks'
+ ],
+ Message::get( 'smw-install-incomplete-intro' ) . "<ul>$html</ul>"
+ );
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/HookListener.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/HookListener.php
index da79d510..ed8eefcb 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/HookListener.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/HookListener.php
@@ -9,6 +9,7 @@ use SMW\ParserFunctions\DocumentationParserFunction;
use SMW\ParserFunctions\InfoParserFunction;
use SMW\ParserFunctions\SectionTag;
use SMW\MediaWiki\Search\SearchProfileForm;
+use SMW\SQLStore\Installer;
use SMW\Site;
use SMW\Store;
use SMW\Options;
@@ -159,7 +160,7 @@ class HookListener {
// Disallow the file cache to avoid skipping the ArticleViewHeader hook
// on Article::tryFileCache
- return !$applicationFactory->getSettings( 'smwgEnabledQueryDependencyLinksStore' );
+ return true;
}
/**
@@ -171,6 +172,12 @@ class HookListener {
$beforePageDisplay = new BeforePageDisplay();
+ $beforePageDisplay->setOptions(
+ [
+ 'installer.incomplete_tasks' => Installer::incompleteTasks( $GLOBALS )
+ ]
+ );
+
return $beforePageDisplay->process( $outputPage, $skin );
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/ResourceLoaderTestModules.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/ResourceLoaderTestModules.php
index ccd065de..6fcc5acf 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/ResourceLoaderTestModules.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Hooks/ResourceLoaderTestModules.php
@@ -83,8 +83,8 @@ class ResourceLoaderTestModules extends HookHandler {
'ext.smw.api'
],
'position' => 'top',
- 'localpath' => $this->path,
- 'remoteExtPath' => '..' . substr( $this->path, strlen( $this->ip ) ),
+ 'localBasePath' => $this->path,
+ 'remoteExtPath' => 'SemanticMediaWiki',
];
return true;
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Admin/TaskHandler.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Admin/TaskHandler.php
index 187b344f..0a8afbc1 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Admin/TaskHandler.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Admin/TaskHandler.php
@@ -46,7 +46,7 @@ abstract class TaskHandler {
* @return boolean
*/
public function isEnabledFeature( $feature ) {
- return ( ( $this->enabledFeatures & $feature ) == $feature );
+ return ( ( (int)$this->enabledFeatures & $feature ) == $feature );
}
/**
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/HtmlForm.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/HtmlForm.php
index 3ef5f92f..8c4eaf88 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/HtmlForm.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/HtmlForm.php
@@ -134,11 +134,11 @@ class HtmlForm {
* @since 3.0
*
* @param UrlArgs $urlArgs
- * @param QueryResult $queryResult
+ * @param QueryResult|string|null $queryResult
*
* @return string
*/
- public function getForm( UrlArgs $urlArgs, QueryResult $queryResult = null, $text = '' ) {
+ public function getForm( UrlArgs $urlArgs, $queryResult = null, $text = '' ) {
$html = $this->buildHTML( $urlArgs, $queryResult, $text );
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/ParametersProcessor.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/ParametersProcessor.php
index 6b510e0f..19d86c2e 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/ParametersProcessor.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Ask/ParametersProcessor.php
@@ -54,13 +54,13 @@ class ParametersProcessor {
// First make all inputs into a simple parameter list that can again be
// parsed into components later.
- $reqParameters = self::getParameterList( $request, $params );
+ $parameterList = self::getParameterList( $request, $params );
$printouts = [];
// Check for q= query string, used whenever this special page calls
// itself (via submit or plain link):
if ( ( $q = $request->getText( 'q' ) ) !== '' ) {
- $reqParameters[] = $q;
+ $parameterList[] = $q;
}
// Parameters separated by newlines here (compatible with text-input for
@@ -71,14 +71,14 @@ class ParametersProcessor {
// Check for param strings in po (printouts), appears in some links
// and in submits:
- $reqParameters = self::checkReqParameters(
+ $parameterList = self::checkParameterList(
$request,
- $reqParameters,
+ $parameterList,
$printouts
);
list( $queryString, $parameters, $printouts ) = QueryProcessor::getComponentsFromFunctionParams(
- $reqParameters,
+ $parameterList,
false
);
@@ -195,7 +195,7 @@ class ParametersProcessor {
return $parameterList;
}
- private static function checkReqParameters( $request, $reqParameters, $printouts ) {
+ private static function checkParameterList( $request, $parameterList, $printouts ) {
// Add initial ? if omitted (all params considered as printouts)
foreach ( $printouts as $param ) {
@@ -205,22 +205,32 @@ class ParametersProcessor {
$param = '?' . $param;
}
- $reqParameters[] = $param;
+ $parameterList[] = $param;
}
$parameters = [];
- unset( $reqParameters['title'] );
+ unset( $parameterList['title'] );
// MW's internal token
- unset( $reqParameters['wpEditToken'] );
+ unset( $parameterList['wpEditToken'] );
- // Split ?Has property=Foo|+index=1 into a [ '?Has property=Foo', '+index=1' ]
- foreach ( $reqParameters as $key => $value ) {
- if (
- ( $key !== '' && $key{0} == '?' && strpos( $value, '|' ) !== false ) ||
- ( is_string( $value ) && $value !== '' && $value{0} == '?' && strpos( $value, '|' ) !== false ) ) {
+ foreach ( $parameterList as $key => $value ) {
+ if ( self::hasPipe( $key, $value ) ) {
+
+ // #3523 `?TestAsk=[[Foo|Bar]]` replace `|`
+ if ( self::hasLink( $value ) ) {
+ $value = self::replace( '|', '0x7C', $value );
+ }
+ // #1407 Split: `?Has property=Foo|+index=1` into a [ '?Has property=Foo', '+index=1' ])
foreach ( explode( '|', $value ) as $k => $val ) {
+
+ // #3523 `?TestAsk=[[Foo|Bar]]|+index=1` decode
+ // the part that contains `0x7C`
+ if ( strpos( $val, '0x7C' ) !== false ) {
+ $val = self::replace( '0x7C', '|', $val );
+ }
+
$parameters[] = $k == 0 && $key{0} == '?' ? $key . '=' . $val : $val;
}
} elseif ( is_string( $key ) ) {
@@ -233,4 +243,31 @@ class ParametersProcessor {
return $parameters;
}
+ private static function hasPipe( $key, $value ) {
+
+ if ( $key !== '' && $key{0} == '?' && strpos( $value, '|' ) !== false ) {
+ return true;
+ }
+
+ if ( is_string( $value ) && $value !== '' && $value{0} == '?' && strpos( $value, '|' ) !== false ) {
+ return true;
+ }
+
+ return false;
+ }
+
+ private static function hasLink( $value ) {
+ return strpos( $value, '[[' ) !== false && strpos( $value, ']]' ) !== false ;
+ }
+
+ private static function replace( $source, $target, $value ) {
+ return preg_replace_callback(
+ '/\[\[([^\[\]]*)\]\]/xu',
+ function( array $matches ) use ( $source, $target ) {
+ return str_replace( [ $source ], [ $target ], $matches[0] );
+ },
+ $value
+ );
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Browse/ValueFormatter.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Browse/ValueFormatter.php
index 3ff67730..98a87e48 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Browse/ValueFormatter.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/Browse/ValueFormatter.php
@@ -103,8 +103,12 @@ class ValueFormatter {
}
$html = $dataValue->getLongHTMLText( $linker );
- $isCompactLink = $dataValue->getOption( DataValue::OPT_COMPACT_INFOLINKS, false );
+ if ( $dataValue->getOption( DataValue::OPT_DISABLE_INFOLINKS, false ) === true ) {
+ return $html;
+ }
+
+ $isCompactLink = $dataValue->getOption( DataValue::OPT_COMPACT_INFOLINKS, false );
$noInfolinks = [ '_INST', '_SKEY' ];
if ( in_array( $dataValue->getTypeID(), [ '_wpg', '_wpp', '__sob'] ) ) {
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/SpecialAsk.php b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/SpecialAsk.php
index a9a5612a..fe2d817d 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/SpecialAsk.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/MediaWiki/Specials/SpecialAsk.php
@@ -294,16 +294,9 @@ class SpecialAsk extends SpecialPage {
$duration = 0;
$error = '';
+ $printer = null;
if ( $this->queryString !== '' ) {
-
- $printer = QueryProcessor::getResultPrinter(
- $this->parameters['format'],
- QueryProcessor::SPECIAL_PAGE
- );
-
- $printer->setShowErrors( false );
-
list( $result, $res, $duration ) = $this->fetchResults(
$printer,
$queryobj,
@@ -311,7 +304,7 @@ class SpecialAsk extends SpecialPage {
);
}
- if ( isset( $printer ) && $printer->isExportFormat() ) {
+ if ( $printer !== null && $printer->isExportFormat() ) {
// Avoid a possible "Cannot modify header information - headers already sent by ..."
if ( defined( 'MW_PHPUNIT_TEST' ) && method_exists( $printer, 'disableHttpHeader' ) ) {
@@ -354,6 +347,8 @@ class SpecialAsk extends SpecialPage {
if ( $res instanceof QueryResult ) {
$isFromCache = $res->isFromCache();
$error = ErrorWidget::queryError( $queryobj );
+ } elseif ( is_string( $res ) ) {
+ $error = $res;
}
$infoText = $this->getInfoText(
@@ -410,10 +405,17 @@ class SpecialAsk extends SpecialPage {
);
}
- private function fetchResults( $printer, &$queryobj, &$urlArgs ) {
+ private function fetchResults( &$printer, &$queryobj, &$urlArgs ) {
list( $res, $debug, $duration, $queryobj, $native_result ) = $this->getQueryResult();
+ $printer = QueryProcessor::getResultPrinter(
+ $this->parameters['format'],
+ QueryProcessor::SPECIAL_PAGE
+ );
+
+ $printer->setShowErrors( false );
+
$hidequery = $this->getRequest()->getVal( 'eq' ) == 'no';
$request_type = $this->getRequest()->getVal( 'request_type', '' );
$result = '';
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctionFactory.php b/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctionFactory.php
index e435088b..a38f404c 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctionFactory.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctionFactory.php
@@ -316,24 +316,27 @@ class ParserFunctionFactory {
$parser->getTargetLanguage()
);
+ $recurringEvents = new RecurringEvents();
+
+ $recurringEvents->setDefaultNumRecurringEvents(
+ $settings->get( 'smwgDefaultNumRecurringEvents' )
+ );
+
+ $recurringEvents->setMaxNumRecurringEvents(
+ $settings->get( 'smwgMaxNumRecurringEvents' )
+ );
+
$recurringEventsParserFunction = new RecurringEventsParserFunc(
$parserData,
$subobject,
- $messageFormatter
+ $messageFormatter,
+ $recurringEvents
);
$recurringEventsParserFunction->isCapitalLinks(
Site::isCapitalLinks()
);
- $recurringEventsParserFunction->setDefaultNumRecurringEvents(
- $settings->get( 'smwgDefaultNumRecurringEvents' )
- );
-
- $recurringEventsParserFunction->setMaxNumRecurringEvents(
- $settings->get( 'smwgMaxNumRecurringEvents' )
- );
-
$recurringEventsParserFunction->isComparableContent(
$settings->get( 'smwgUseComparableContentHash' )
);
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctions/RecurringEventsParserFunction.php b/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctions/RecurringEventsParserFunction.php
index 98d70ad1..9a161e0c 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctions/RecurringEventsParserFunction.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/ParserFunctions/RecurringEventsParserFunction.php
@@ -29,42 +29,16 @@ class RecurringEventsParserFunction extends SubobjectParserFunction {
private $recurringEvents;
/**
- * @var integer
- */
- private $defaultNumRecurringEvents = 25;
-
- /**
- * @var integer
- */
- private $maxNumRecurringEvents = 25;
-
- /**
* @since 1.9
*
* @param ParserData $parserData
* @param Subobject $subobject
* @param MessageFormatter $messageFormatter
+ * @param RecurringEvents $recurringEvents
*/
- public function __construct( ParserData $parserData, Subobject $subobject, MessageFormatter $messageFormatter ) {
+ public function __construct( ParserData $parserData, Subobject $subobject, MessageFormatter $messageFormatter, RecurringEvents $recurringEvents ) {
parent::__construct ( $parserData, $subobject, $messageFormatter );
- }
-
- /**
- * @since 2.5
- *
- * @param integer $defaultNumRecurringEvents
- */
- public function setDefaultNumRecurringEvents( $defaultNumRecurringEvents ) {
- $this->defaultNumRecurringEvents = $defaultNumRecurringEvents;
- }
-
- /**
- * @since 2.5
- *
- * @param integer $maxNumRecurringEvents
- */
- public function setMaxNumRecurringEvents( $maxNumRecurringEvents ) {
- $this->maxNumRecurringEvents = $maxNumRecurringEvents;
+ $this->recurringEvents = $recurringEvents;
}
/**
@@ -76,7 +50,11 @@ class RecurringEventsParserFunction extends SubobjectParserFunction {
*/
public function parse( ParserParameterProcessor $parameters ) {
- $this->initRecurringEvents( $parameters->toArray() );
+ $this->useFirstElementAsPropertyLabel( true );
+
+ $this->recurringEvents->parse(
+ $parameters->toArray()
+ );
$this->messageFormatter->addFromArray(
$this->recurringEvents->getErrors()
@@ -108,26 +86,11 @@ class RecurringEventsParserFunction extends SubobjectParserFunction {
// Update ParserOutput
$this->parserData->pushSemanticDataToParserOutput();
- return $this->messageFormatter->addFromArray( $this->parserData->getErrors() )->getHtml();
- }
-
- private function initRecurringEvents( $parameters ) {
-
- $this->useFirstElementAsPropertyLabel( true );
-
- if ( $this->recurringEvents !== null ) {
- return $this->recurringEvents;
- }
-
- $this->recurringEvents = new RecurringEvents( $parameters );
-
- $this->recurringEvents->setDefaultNumRecurringEvents(
- $this->defaultNumRecurringEvents
+ $this->messageFormatter->addFromArray(
+ $this->parserData->getErrors()
);
- $this->recurringEvents->setMaxNumRecurringEvents(
- $this->maxNumRecurringEvents
- );
+ return $this->messageFormatter->getHtml();
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Query/Parser/DescriptionProcessor.php b/www/wiki/extensions/SemanticMediaWiki/src/Query/Parser/DescriptionProcessor.php
index b97be0da..45af6deb 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Query/Parser/DescriptionProcessor.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Query/Parser/DescriptionProcessor.php
@@ -13,6 +13,7 @@ use SMW\Query\Language\Disjunction;
use SMW\Query\Language\ValueDescription;
use SMW\Site;
use SMWDataValue as DataValue;
+use SMW\Query\QueryComparator;
/**
* @license GNU GPL v2+
@@ -167,6 +168,20 @@ class DescriptionProcessor {
$dataValue->setContextPage( $this->contextPage );
$dataValue->setOption( DataValue::OPT_QUERY_CONTEXT, true );
+
+ // #3587
+ // Requesting capital links is influenced by two factors, `wgCapitalLinks`
+ // is enabled sitewide and the `WikiPageValue` condition is identified
+ // as SMW_CMP_EQ/NEQ (e.g. [[Foo]], [[!Foo]]) with other expressions
+ // (e.g. [[~foo*]]) to remain in the form of the user input
+ $queryComparator = QueryComparator::getInstance();
+
+ if ( Site::isCapitalLinks() && (
+ $queryComparator->containsComparator( $chunk, SMW_CMP_EQ ) ||
+ $queryComparator->containsComparator( $chunk, SMW_CMP_NEQ ) ) ) {
+ $dataValue->setOption( 'isCapitalLinks', true );
+ }
+
$description = null;
$description = $dataValue->getQueryDescription( $chunk );
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Query/Processor/ParamListProcessor.php b/www/wiki/extensions/SemanticMediaWiki/src/Query/Processor/ParamListProcessor.php
index 373695e3..d7c0b22d 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Query/Processor/ParamListProcessor.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Query/Processor/ParamListProcessor.php
@@ -120,7 +120,7 @@ class ParamListProcessor {
}
$serialization['query'] = str_replace(
- [ '&lt;', '&gt;', '-3D' ],
+ [ '&lt;', '&gt;', '0x003D' ],
['<', '>', '=' ],
$serialization['query']
);
@@ -173,11 +173,17 @@ class ParamListProcessor {
private function encodeEq ( $param ) {
// Bug 32955 / #640
- // Modify (e.g. replace `=`) a condition string only if enclosed by [[ ... ]]
+ // Modify (e.g. replace `=`) a condition string only if enclosed by
+ // [[ ... ]]
+ //
+ // #3560
+ // Instead of `-3D` as temporary replacement, use the UTF representation
+ // to decode the `=` sign and eliminate possible collisions with a search
+ // request that contains `-3D` string
return preg_replace_callback(
'/\[\[([^\[\]]*)\]\]/xu',
function( array $matches ) {
- return str_replace( [ '=' ], [ '-3D' ], $matches[0] );
+ return str_replace( [ '=' ], [ '0x003D' ], $matches[0] );
},
$param
);
@@ -246,9 +252,9 @@ class ParamListProcessor {
// Don't trim here, some parameters care for " "
//
// #3196
- // Ensure to decode `-3D` from encodeEq to support things like
+ // Ensure to decode `0x003D` from encodeEq to support things like
// `|intro=[[File:Foo.png|link=Bar]]`
- $serialization['parameters'][$p] = str_replace( [ '-3D' ], [ '=' ], $parts[1] );
+ $serialization['parameters'][$p] = str_replace( [ '0x003D' ], [ '=' ], $parts[1] );
} else {
$serialization['query'] .= $param;
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Query/RemoteRequest.php b/www/wiki/extensions/SemanticMediaWiki/src/Query/RemoteRequest.php
index 58ab9922..325d0c7b 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Query/RemoteRequest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Query/RemoteRequest.php
@@ -229,7 +229,7 @@ class RemoteRequest implements QueryEngine {
$this->httpRequest->setOption(
ONOI_HTTP_REQUEST_RESPONSECACHE_PREFIX,
- Site::prefix( 'smw:query:remote:' )
+ Site::id( 'smw:query:remote:' )
);
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/EntityStore/SemanticDataLookup.php b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/EntityStore/SemanticDataLookup.php
index c5337577..ca1d95fa 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/EntityStore/SemanticDataLookup.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/EntityStore/SemanticDataLookup.php
@@ -220,6 +220,8 @@ class SemanticDataLookup {
$query->condition( $query->eq( 'p_id', $extraCondition['p_id'] ) );
}
}
+ } else {
+ $requestOptions = new RequestOptions();
}
$valueCount = 0;
@@ -243,6 +245,39 @@ class SemanticDataLookup {
$fieldname
);
+ // Don't use DISTINCT for subject related value match but make sure
+ // (#3531) it is used when requesting other values in order to retrieve
+ // all available unique values within the range of the limit
+ if ( !$isSubject ) {
+ $requestOptions->setOption( 'DISTINCT', true );
+
+ // Don't sort, this avoids a SQL `filesort`/`temporary table` usage
+ // in combination with DISTINCT, values will be listed as-is instead
+ // of a lexical representation but can be compensated by selecting a
+ // wider range in case this is used as retrieving "all" values
+ // for a property
+
+ // SELECT DISTINCT o_id AS id0, o0.smw_title AS v0, o0.smw_namespace
+ // AS v1, o0.smw_iw AS v2, o0.smw_sortkey AS v3, o0.smw_subobject AS
+ // v4 FROM `smw_di_wikipage` INNER JOIN `smw_object_ids` AS o0 ON
+ // o_id=o0.smw_id WHERE (p_id='x') LIMIT 51
+ //
+ // 8.6281ms
+ //
+ // vs.
+ //
+ // SELECT DISTINCT o_id AS id0, o0.smw_title AS v0, o0.smw_namespace
+ // AS v1, o0.smw_iw AS v2, o0.smw_sortkey AS v3, o0.smw_subobject AS
+ // v4 FROM `smw_di_wikipage` INNER JOIN `smw_object_ids` AS o0 ON
+ // o_id=o0.smw_id WHERE (p_id='x') ORDER BY o_id LIMIT 51
+ //
+ // 24189.0128ms
+ //
+ // PS: In case of a `TYPE_WIKIPAGE` entity, sorting by `o_id`
+ // wouldn't make much sense as it does not guarantee any lexical order
+ $requestOptions->setOption( 'ORDER BY', false );
+ }
+
// Apply sorting/string matching; only with given property
if ( !$isSubject ) {
$conds = $this->store->getSQLConditions(
@@ -253,14 +288,14 @@ class SemanticDataLookup {
);
$query->condition( $conds );
- $query->options( $this->store->getSQLOptions( $requestOptions, $valueField ) + [ 'DISTINCT' ] );
} else {
$valueField = '';
-
- // Don't use DISTINCT for value of one subject:
- $query->options( $this->store->getSQLOptions( $requestOptions, $valueField ) );
}
+ $query->options(
+ $this->store->getSQLOptions( $requestOptions, $valueField )
+ );
+
$res = $connection->query(
$query,
__METHOD__
@@ -287,6 +322,13 @@ class SemanticDataLookup {
$connection->freeResult( $res );
+ // Sorting via PHP for an explicit disabled `ORDER BY` to ensure that
+ // the result set has at least a lexical order applied for the range of
+ // retrieved values
+ if ( $requestOptions->getOption( 'ORDER BY' ) === false ) {
+ sort( $result );
+ }
+
return $result;
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/Installer.php b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/Installer.php
index da5ae4f6..ec68ddf4 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/Installer.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/Installer.php
@@ -10,7 +10,9 @@ use SMW\CompatibilityMode;
use SMW\MediaWiki\Jobs\EntityIdDisposerJob;
use SMW\MediaWiki\Jobs\PropertyStatisticsRebuildJob;
use SMW\Options;
+use SMW\Site;
use SMW\Utils\File;
+use SMW\Exception\FileNotWritableException;
/**
* @private
@@ -45,6 +47,11 @@ class Installer implements MessageReporter {
const OPT_SCHEMA_UPDATE = 'installer.schema.update';
/**
+ * `smw_hash` field population
+ */
+ const POPULATE_HASH_FIELD_COMPLETE = 'populate.smw_hash_field_complete';
+
+ /**
* @var TableSchemaManager
*/
private $tableSchemaManager;
@@ -65,6 +72,11 @@ class Installer implements MessageReporter {
private $options;
/**
+ * @var File
+ */
+ private $file;
+
+ /**
* @since 2.5
*
* @param TableSchemaManager $tableSchemaManager
@@ -93,6 +105,15 @@ class Installer implements MessageReporter {
}
/**
+ * @since 3.0
+ *
+ * @param File $file
+ */
+ public function setFile( File $file ) {
+ $this->file = $file;
+ }
+
+ /**
* @since 2.5
*
* @param boolean $verbose
@@ -130,7 +151,9 @@ class Installer implements MessageReporter {
$this->table_optimization( $messageReporter );
$this->supplement_jobs( $messageReporter );
- self::setUpgradeKey( new File(), $GLOBALS, $messageReporter );
+ $file = $this->file !== null ? $this->file : new File();
+
+ self::setUpgradeKey( $GLOBALS, $messageReporter, $file );
Hooks::run(
'SMW::SQLStore::Installer::AfterCreateTablesComplete',
@@ -188,6 +211,24 @@ class Installer implements MessageReporter {
/**
* @since 3.0
*
+ * @param array $vars
+ */
+ public static function loadSchema( &$vars ) {
+
+ // @see #3506
+ $file = File::dir( $vars['smwgConfigFileDir'] . '/.smw.json' );
+
+ // Doesn't exist? The `Setup::init` will take care of it by trying to create
+ // a new file and if it fails or unable to do so wail raise an exception
+ // as we expect to have access to it.
+ if ( is_readable( $file ) ) {
+ $vars['smw.json'] = json_decode( file_get_contents( $file ), true );
+ }
+ }
+
+ /**
+ * @since 3.0
+ *
* @param boolean $isCli
*
* @return boolean
@@ -202,11 +243,40 @@ class Installer implements MessageReporter {
return true;
}
- if ( !isset( $GLOBALS['smw.json']['upgradeKey'] ) ) {
+ // #3563, Use the specific wiki-id as identifier for the instance in use
+ $id = Site::id();
+
+ if ( !isset( $GLOBALS['smw.json'][$id]['upgrade_key'] ) ) {
return false;
}
- return self::getUpgradeKey( $GLOBALS ) === $GLOBALS['smw.json']['upgradeKey'];
+ return self::makeUpgradeKey( $GLOBALS ) === $GLOBALS['smw.json'][$id]['upgrade_key'];
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param array $vars
+ *
+ * @return []
+ */
+ public static function incompleteTasks( $vars ) {
+
+ $id = Site::id();
+ $tasks = [];
+
+ // Key field => [ value that constitutes the `INCOMPLETE` state, error msg ]
+ $checks = [
+ self::POPULATE_HASH_FIELD_COMPLETE => [ false, 'smw-install-incomplete-populate-hash-field' ]
+ ];
+
+ foreach ( $checks as $key => $value ) {
+ if ( isset( $vars['smw.json'][$id][$key] ) && $vars['smw.json'][$id][$key] === $value[0] ) {
+ $tasks[] = $value[1];
+ }
+ }
+
+ return $tasks;
}
/**
@@ -216,7 +286,7 @@ class Installer implements MessageReporter {
*
* @return string
*/
- public static function getUpgradeKey( $vars ) {
+ public static function makeUpgradeKey( $vars ) {
// The following settings influence the "shape" of the tables required
// therefore use the content to compute a key that reflects any
@@ -246,31 +316,71 @@ class Installer implements MessageReporter {
/**
* @since 3.0
*
- * @param File $file
* @param array $vars
+ * @param MessageReporter $messageReporter|null
+ * @param File $file|null
*/
- public static function setUpgradeKey( File $file, $vars, $messageReporter = null ) {
+ public static function setUpgradeKey( $vars, MessageReporter $messageReporter = null, File $file = null ) {
- $key = self::getUpgradeKey( $vars );
+ // #3563, Use the specific wiki-id as identifier for the instance in use
+ $key = self::makeUpgradeKey( $vars );
+ $id = Site::id();
- if ( isset( $vars['smw.json']['upgradeKey'] ) && $key === $vars['smw.json']['upgradeKey'] ) {
+ if (
+ isset( $vars['smw.json'][$id]['upgrade_key'] ) &&
+ $key === $vars['smw.json'][$id]['upgrade_key'] ) {
return false;
}
if ( $messageReporter !== null ) {
- $messageReporter->reportMessage( "\nSetting upgrade key ..." );
+ $messageReporter->reportMessage( "\nSetting $id upgrade key ..." );
}
+ self::setUpgradeFile( $vars, [ 'upgrade_key' => $key ], $file );
+
+ if ( $messageReporter !== null ) {
+ $messageReporter->reportMessage( "\n ... done.\n" );
+ }
+ }
+
+ /**
+ * @since 3.0
+ *
+ * @param File $file
+ * @param array $vars
+ */
+ public static function setUpgradeFile( $vars, $args = [], File $file = null ) {
+
+ $configFile = $vars['smwgConfigFileDir'] . '/.smw.json';
+
+ if ( $file === null ) {
+ $file = new File();
+ }
+
+ $id = Site::id();
+
if ( !isset( $vars['smw.json'] ) ) {
$vars['smw.json'] = [];
}
- $vars['smw.json']['upgradeKey'] = $key;
-
- $file->write( $vars['smwgIP'] . '/.smw.json', json_encode( $vars['smw.json'] ) );
+ foreach ( $args as $key => $value ) {
+ $vars['smw.json'][$id][$key] = $value;
+ }
- if ( $messageReporter !== null ) {
- $messageReporter->reportMessage( "\n ... done.\n" );
+ try {
+ $file->write(
+ $configFile,
+ json_encode( $vars['smw.json'], JSON_PRETTY_PRINT )
+ );
+ } catch( FileNotWritableException $e ) {
+ // Users may not have `wgShowExceptionDetails` enabled and would
+ // therefore not see the exception error message hence we fail hard
+ // and die
+ die(
+ "\n\nERROR: " . $e->getMessage() . "\n" .
+ "\n The \"smwgConfigFileDir\" setting should point to a" .
+ "\n directory that is persistent and writable!\n"
+ );
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/SQLStoreFactory.php b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/SQLStoreFactory.php
index f4ef2b85..0cba4d0e 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/SQLStoreFactory.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/SQLStoreFactory.php
@@ -33,6 +33,7 @@ use SMW\SQLStore\Lookup\UnusedPropertyListLookup;
use SMW\SQLStore\Lookup\UsageStatisticsListLookup;
use SMW\SQLStore\Lookup\ProximityPropertyValueLookup;
use SMW\SQLStore\TableBuilder\TableBuilder;
+use SMW\SQLStore\TableBuilder\Examiner\HashField;
use SMW\Utils\CircularReferenceGuard;
use SMWRequestOptions as RequestOptions;
use SMWSql3SmwIds as EntityIdManager;
@@ -399,7 +400,8 @@ class SQLStoreFactory {
);
$tableIntegrityExaminer = new TableIntegrityExaminer(
- $this->store
+ $this->store,
+ new HashField( $this->store )
);
$tableSchemaManager = new TableSchemaManager(
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/Examiner/HashField.php b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/Examiner/HashField.php
new file mode 100644
index 00000000..0e866368
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/Examiner/HashField.php
@@ -0,0 +1,87 @@
+<?php
+
+namespace SMW\SQLStore\TableBuilder\Examiner;
+
+use Onoi\MessageReporter\MessageReporterAwareTrait;
+use SMW\SQLStore\SQLStore;
+use SMW\Maintenance\PopulateHashField;
+
+/**
+ * @license GNU GPL v2+
+ * @since 3.1
+ *
+ * @author mwjames
+ */
+class HashField {
+
+ use MessageReporterAwareTrait;
+
+ /**
+ * @var SQLStore
+ */
+ private $store;
+
+ /**
+ * @var PopulateHashField
+ */
+ private $populateHashField;
+
+ /**
+ * @since 3.1
+ *
+ * @param SQLStore $store
+ * @param PopulateHashField|null $populateHashField
+ */
+ public function __construct( SQLStore $store, PopulateHashField $populateHashField = null ) {
+ $this->store = $store;
+ $this->populateHashField = $populateHashField;
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @return integer
+ */
+ public static function threshold() {
+ return PopulateHashField::COUNT_SCRIPT_EXECUTION_THRESHOLD;
+ }
+
+ /**
+ * @since 3.1
+ *
+ * @param array $opts
+ */
+ public function check( array $opts = [] ) {
+
+ $this->messageReporter->reportMessage( "Checking smw_hash field consistency ...\n" );
+ require_once $GLOBALS['smwgMaintenanceDir'] . "/populateHashField.php";
+
+ if ( $this->populateHashField === null ) {
+ $this->populateHashField = new PopulateHashField();
+ }
+
+ $this->populateHashField->setStore( $this->store );
+ $this->populateHashField->setMessageReporter( $this->messageReporter );
+
+ $rows = $this->populateHashField->fetchRows();
+ $count = 0;
+
+ if ( $rows !== null ) {
+ $count = $rows->numRows();
+ }
+
+ if ( $count > self::threshold() ) {
+ $this->messageReporter->reportMessage( " ... missing $count rows ...\n" );
+ $this->messageReporter->reportMessage( " ... skipping the `smw_hash` field population ...\n" );
+
+ $this->populateHashField->setComplete( false );
+ } elseif ( $count != 0 ) {
+ $this->populateHashField->populate( $rows );
+ } else {
+ $this->populateHashField->setComplete( true );
+ }
+
+ $this->messageReporter->reportMessage( " ... done.\n" );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/MySQLTableBuilder.php b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/MySQLTableBuilder.php
index 29417b7c..7c9a5ebc 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/MySQLTableBuilder.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableBuilder/MySQLTableBuilder.php
@@ -100,10 +100,10 @@ class MySQLTableBuilder extends TableBuilder {
return $tableOption;
}
- // @see $wgDBattributes, This replacement is needed for compatibility,
+ // @see $wgDBTableOptions, This replacement is needed for compatibility,
// http://bugs.mysql.com/bug.php?id=17501
- if ( isset( $this->config['wgDBattributes'] ) ) {
- return str_replace( 'TYPE', 'ENGINE', $this->config['wgDBattributes'] );
+ if ( isset( $this->config['wgDBTableOptions'] ) ) {
+ return str_replace( 'TYPE', 'ENGINE', $this->config['wgDBTableOptions'] );
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableIntegrityExaminer.php b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableIntegrityExaminer.php
index f13f6c9c..690a3d97 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableIntegrityExaminer.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/SQLStore/TableIntegrityExaminer.php
@@ -2,14 +2,15 @@
namespace SMW\SQLStore;
-use Onoi\MessageReporter\MessageReporter;
-use Onoi\MessageReporter\MessageReporterAware;
+use Onoi\MessageReporter\MessageReporterAwareTrait;
use Onoi\MessageReporter\NullMessageReporter;
use SMW\DIProperty;
use SMW\Exception\PredefinedPropertyLabelMismatchException;
use SMW\MediaWiki\Collator;
use SMW\PropertyRegistry;
use SMW\SQLStore\TableBuilder\Table;
+use SMW\SQLStore\Installer;
+use SMW\SQLStore\TableBuilder\Examiner\HashField;
use SMWSql3SmwIds;
/**
@@ -23,7 +24,9 @@ use SMWSql3SmwIds;
*
* @author mwjames
*/
-class TableIntegrityExaminer implements MessageReporterAware {
+class TableIntegrityExaminer {
+
+ use MessageReporterAwareTrait;
/**
* @var SQLStore
@@ -31,9 +34,9 @@ class TableIntegrityExaminer implements MessageReporterAware {
private $store;
/**
- * @var MessageReporter
+ * @var HashField
*/
- private $messageReporter;
+ private $hashField;
/**
* @var array
@@ -44,25 +47,16 @@ class TableIntegrityExaminer implements MessageReporterAware {
* @since 2.5
*
* @param SQLStore $store
+ * @param HashField $hashField
*/
- public function __construct( SQLStore $store ) {
+ public function __construct( SQLStore $store, HashField $hashField ) {
$this->store = $store;
+ $this->hashField = $hashField;
$this->messageReporter = new NullMessageReporter();
$this->setPredefinedPropertyList( PropertyRegistry::getInstance()->getPropertyList() );
}
/**
- * @see MessageReporterAware::setMessageReporter
- *
- * @since 2.5
- *
- * @param MessageReporter $messageReporter
- */
- public function setMessageReporter( MessageReporter $messageReporter ) {
- $this->messageReporter = $messageReporter;
- }
-
- /**
* @since 2.5
*
* @param array $propertyList
@@ -93,7 +87,10 @@ class TableIntegrityExaminer implements MessageReporterAware {
public function checkOnPostCreation( TableBuilder $tableBuilder ) {
$this->checkPredefinedPropertyIndices();
- $this->checkHashField();
+
+ $this->hashField->setMessageReporter( $this->messageReporter );
+ $this->hashField->check();
+
$this->checkSortField( $tableBuilder->getLog() );
// Call out for RDBMS specific implementations
@@ -343,60 +340,5 @@ class TableIntegrityExaminer implements MessageReporterAware {
);
}
- private function checkHashField() {
-
- $this->messageReporter->reportMessage( "Checking smw_hash field ...\n" );
- $connection = $this->store->getConnection( DB_MASTER );
-
- $rows = $connection->select(
- SQLStore::ID_TABLE,
- [
- 'smw_id',
- 'smw_title',
- 'smw_namespace',
- 'smw_iw',
- 'smw_subobject'
- ],
- [
- 'smw_hash' => null
- ],
- __METHOD__
- );
-
- $count = $rows !== null ? $rows->numRows() : 0;
- $i = 0;
-
- if ( $count == 0 ) {
- return $this->messageReporter->reportMessage( " ... done.\n" );
- }
-
- $this->messageReporter->reportMessage( " ... missing $count rows ...\n" );
-
- foreach ( $rows as $row ) {
- $i++;
-
- $hash = $this->store->getObjectIds()->computeSha1(
- [
- $row->smw_title,
- (int)$row->smw_namespace,
- $row->smw_iw,
- $row->smw_subobject
- ]
- );
-
- $this->messageReporter->reportMessage(
- "\r". sprintf( "%-35s%s", " ... updating document no.", sprintf( "%s (%1.0f%%)", $row->smw_id, round( ( $i / $count ) * 100 ) ) )
- );
-
- $connection->update(
- SQLStore::ID_TABLE,
- [ 'smw_hash' => $hash ],
- [ 'smw_id' => $row->smw_id ],
- __METHOD__
- );
- }
-
- $this->messageReporter->reportMessage( "\n ... done.\n" );
- }
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Serializers/QueryResultSerializer.php b/www/wiki/extensions/SemanticMediaWiki/src/Serializers/QueryResultSerializer.php
index 8aa57cec..ecba7d30 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Serializers/QueryResultSerializer.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Serializers/QueryResultSerializer.php
@@ -101,7 +101,17 @@ class QueryResultSerializer implements DispatchableSerializer {
];
foreach ( $recordValue->getDataItem()->getSemanticData()->getPropertyValues( $property ) as $value ) {
- $recordDiValues[$label]['item'][] = self::getSerialization( $value );
+
+ if ( $property->findPropertyTypeID() === '_qty' ) {
+ $dataValue = DataValueFactory::getInstance()->newDataValueByItem( $value, $property );
+
+ $recordDiValues[$label]['item'][] = [
+ 'value' => $dataValue->getNumber(),
+ 'unit' => $dataValue->getUnit()
+ ];
+ } else {
+ $recordDiValues[$label]['item'][] = self::getSerialization( $value );
+ }
}
}
$result = $recordDiValues;
@@ -130,6 +140,11 @@ class QueryResultSerializer implements DispatchableSerializer {
// (unit is part of the datavalue object)
if ( $printRequest !== null && $printRequest->getTypeID() === '_qty' ) {
$diProperty = $printRequest->getData()->getDataItem();
+
+ if ( $printRequest->isMode( \SMW\Query\PrintRequest::PRINT_CHAIN ) ) {
+ $diProperty = $printRequest->getData()->getLastPropertyChainValue()->getDataItem();
+ }
+
$dataValue = DataValueFactory::getInstance()->newDataValueByItem( $dataItem, $diProperty );
$result = [
@@ -259,8 +274,12 @@ class QueryResultSerializer implements DispatchableSerializer {
return $serialized;
}
+ $serialized['redi'] = '';
+
// To match forwarded redirects
- $serialized['redi'] = !$data->getInceptiveProperty()->equals( $data->getDataItem() ) ? $data->getInceptiveProperty()->getKey() : '';
+ if ( !$data->getInceptiveProperty()->equals( $data->getDataItem() ) ) {
+ $serialized['redi'] = $data->getInceptiveProperty()->getKey();
+ }
// To match internal properties like _MDAT
$serialized['key'] = $data->getDataItem()->getKey();
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Site.php b/www/wiki/extensions/SemanticMediaWiki/src/Site.php
index 9d841979..c2bd3281 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Site.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Site.php
@@ -95,15 +95,17 @@ class Site {
/**
* @since 3.0
*
- * @return boolean
+ * @param $affix string
+ *
+ * @return string
*/
- public static function prefix( $name = '' ) {
+ public static function id( $affix = '' ) {
- if ( $name{0} !== ':' ) {
- $name = ':' . $name;
+ if ( $affix !== '' && $affix{0} !== ':' ) {
+ $affix = ':' . $affix;
}
- return wfWikiID() . $name;
+ return wfWikiID() . $affix;
}
/**
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/TypesRegistry.php b/www/wiki/extensions/SemanticMediaWiki/src/TypesRegistry.php
index 589d63fd..90afb490 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/TypesRegistry.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/TypesRegistry.php
@@ -156,7 +156,7 @@ class TypesRegistry {
// ID => [ valueType, isVisible, isAnnotable, isDeclarative ]
'_TYPE' => [ '__typ', true, true, true ], // "has type"
- '_URI' => [ '__spu', true, true, true ], // "equivalent URI"
+ '_URI' => [ '__spu', true, true, false ], // "equivalent URI"
'_INST' => [ '__sin', false, true, false ], // instance of a category
'_UNIT' => [ '__sps', true, true, true ], // "displays unit"
'_IMPO' => [ '__imp', true, true, true ], // "imported from"
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Utils/Csv.php b/www/wiki/extensions/SemanticMediaWiki/src/Utils/Csv.php
index e6eafa72..3a3c0309 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Utils/Csv.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Utils/Csv.php
@@ -10,6 +10,8 @@ namespace SMW\Utils;
*/
class Csv {
+ const DEFAULT_SEP = ',';
+
/**
* @var boolean
*/
@@ -40,10 +42,13 @@ class Csv {
*
* @return string
*/
- public function toString( array $header, array $rows, $sep = ',' ) {
+ public function toString( array $header, array $rows, $sep = self::DEFAULT_SEP ) {
$handle = fopen( 'php://temp', 'r+' );
+ // fputcsv(): delimiter must be a single character
+ $sep = $sep !== '' ? $sep{0} : self::DEFAULT_SEP;
+
// https://en.wikipedia.org/wiki/Comma-separated_values#Standardization
// http://php.net/manual/en/function.fputcsv.php
if ( $this->bom ) {
diff --git a/www/wiki/extensions/SemanticMediaWiki/src/Utils/File.php b/www/wiki/extensions/SemanticMediaWiki/src/Utils/File.php
index 1e08b5cf..f17154dd 100644
--- a/www/wiki/extensions/SemanticMediaWiki/src/Utils/File.php
+++ b/www/wiki/extensions/SemanticMediaWiki/src/Utils/File.php
@@ -3,6 +3,7 @@
namespace SMW\Utils;
use RuntimeException;
+use SMW\Exception\FileNotWritableException;
/**
* @license GNU GPL v2+
@@ -13,6 +14,17 @@ use RuntimeException;
class File {
/**
+ * @since 3.1
+ *
+ * @param string $file
+ *
+ * @return string
+ */
+ public static function dir( $file ) {
+ return str_replace( [ '\\', '//', '/' ], DIRECTORY_SEPARATOR, $file );
+ }
+
+ /**
* @since 3.0
*
* @param string $file
@@ -20,6 +32,13 @@ class File {
* @param integer $flags
*/
public function write( $file, $contents, $flags = 0 ) {
+
+ $file = self::dir( $file );
+
+ if ( !is_writable( dirname( $file ) ) ) {
+ throw new FileNotWritableException( "$file" );
+ }
+
file_put_contents( $file, $contents, $flags );
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/bootstrap.php b/www/wiki/extensions/SemanticMediaWiki/tests/bootstrap.php
index bd7349de..57c890f9 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/bootstrap.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/bootstrap.php
@@ -1,7 +1,5 @@
<?php
-use SMW\SQLStore\Installer;
-use SMW\Utils\File;
use SMW\MediaWiki\Connection\Sequence;
use SMW\ApplicationFactory;
use SMW\SQLStore\SQLStore;
@@ -39,10 +37,6 @@ register_shutdown_function( function() {
return;
}
- // Restore the smw.json upgrade key with the settings
- // that match the LocalSettings.php
- Installer::setUpgradeKey( new File(), $GLOBALS );
-
// Reset any sequence modified during the test
$sequence = new Sequence(
ApplicationFactory::getInstance()->getConnectionManager()->getConnection( 'mw.db' )
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/JsonTestCaseScriptRunnerTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/JsonTestCaseScriptRunnerTest.php
index a3dea7ae..c622b849 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/JsonTestCaseScriptRunnerTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/JsonTestCaseScriptRunnerTest.php
@@ -277,6 +277,7 @@ class JsonTestCaseScriptRunnerTest extends JsonTestCaseScriptRunner {
'smwgCacheUsage',
'smwgQSortFeatures',
'smwgElasticsearchConfig',
+ 'smwgDefaultNumRecurringEvents',
// MW related
'wgLanguageCode',
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0112.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0112.json
new file mode 100644
index 00000000..7f659c20
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0112.json
@@ -0,0 +1,58 @@
+{
+ "description": "Test #set_recurring_event parser (#3541, en)",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has date",
+ "contents": "[[Has type::Date]]"
+ },
+ {
+ "page": "John Doe's Birthdays",
+ "contents": "{{#set_recurring_event: Is birthday |property=Has date |start=1948-11-03 |end=2019-01-06 |unit=year |period=1 }}"
+ },
+ {
+ "page": "John Doe's Number of Birthdays",
+ "contents": "{{#ask: [[Is birthday::John Doe's Birthdays]] |format=count }}"
+ },
+ {
+ "page": "Jane Doe's Birthdays",
+ "contents": "{{#set_recurring_event: Is birthday |property=Has date |start=1953-05-06 |unit=year |period=1 }}"
+ },
+ {
+ "page": "Jane Doe's Number of Birthdays",
+ "contents": "{{#ask: [[Is birthday::Jane Doe's Birthdays]] |format=count }}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0 #set_recurring_event parser with end date",
+ "subject": "John Doe's Number of Birthdays",
+ "assert-output": {
+ "to-contain": [
+ "71"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#1 #set_recurring_event parser without end date",
+ "subject": "Jane Doe's Number of Birthdays",
+ "assert-output": {
+ "to-contain": [
+ "111"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLang": "en",
+ "smwgDefaultNumRecurringEvents": "110"
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0113.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0113.json
new file mode 100644
index 00000000..d6d39ce1
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0113.json
@@ -0,0 +1,126 @@
+{
+ "description": "Test #set_recurring_event parser include and exclude parameters",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has date",
+ "contents": "[[Has type::Date]]"
+ },
+ {
+ "page": "Team meetings - en",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=January 14, 2019 9:30 am |end=June 30, 2019 |unit=week |period=2 |include=May 7, 2019 9:30 am; June 18, 2019 9:30 am; June 27, 2019 10:00 am |exclude=May 6, 2019 9:30 am; June 17, 2019 9:30 am }}"
+ },
+ {
+ "page": "Team meetings - fr",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=14 janvier 2019 9:30 am |end=30 juin 2019 |unit=week |period=2 |include=7 mai 2019 9:30 am; 18 juin 2019 9:30 am; 27 juin 2019 10:00 am |exclude=6 mai 2019 9:30 am; 17 juin 2019 9:30 am }}"
+ },
+ {
+ "page": "Team meetings - ISO",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=2019-01-14T09:30:00 |end=2019-06-30 |unit=week |period=2 |include=2019-05-07T09:30:00; 2019-06-18T09:30:00; 2019-06-27T10:00:00 |exclude=2019-05-06T09:30:00; 2019-06-17T09:30:00 }}"
+ },
+ {
+ "page": "Team meetings in first half of 2019 - 0 - en",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - en]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in first half of 2019 - 1 - en",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - en]] |?Has date |format=plainlist }}"
+ },
+ {
+ "page": "Team meetings in first half of 2019 - 2 - fr",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - fr]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in first half of 2019 - 3 - fr",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - fr]] |?Has date |format=plainlist }}"
+ },
+ {
+ "page": "Team meetings in first half of 2019 - 4 - ISO",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - ISO]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in first half of 2019 - 5 - ISO",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - ISO]] |?Has date |format=plainlist }}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0 #set_recurring_event parser with end date, included and excluded dates - count",
+ "subject": "Team meetings in first half of 2019 - 0 - en",
+ "assert-output": {
+ "to-contain": [
+ "13"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#1 #set_recurring_event parser with end date, included and excluded dates - print",
+ "subject": "Team meetings in first half of 2019 - 1 - en",
+ "assert-output": {
+ "to-contain": [
+ "27 juin 2019 10:00:00"
+ ],
+ "not-contain": [
+ "6 mai 2019 09:30:00"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#2 #set_recurring_event parser with end date, included and excluded dates - count",
+ "subject": "Team meetings in first half of 2019 - 2 - fr",
+ "assert-output": {
+ "to-contain": [
+ "13"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#3 #set_recurring_event parser with end date, included and excluded dates - print",
+ "subject": "Team meetings in first half of 2019 - 3 - fr",
+ "assert-output": {
+ "to-contain": [
+ "27 juin 2019 10:00:00"
+ ],
+ "not-contain": [
+ "6 mai 2019 09:30:00"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#4 #set_recurring_event parser with end date, included and excluded dates - count",
+ "subject": "Team meetings in first half of 2019 - 4 - ISO",
+ "assert-output": {
+ "to-contain": [
+ "13"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#5 #set_recurring_event parser with end date, included and excluded dates - print",
+ "subject": "Team meetings in first half of 2019 - 5 - ISO",
+ "assert-output": {
+ "to-contain": [
+ "27 juin 2019 10:00:00"
+ ],
+ "not-contain": [
+ "6 mai 2019 09:30:00"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "fr",
+ "wgLang": "en"
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0114.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0114.json
new file mode 100644
index 00000000..6921be44
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0114.json
@@ -0,0 +1,85 @@
+{
+ "description": "Test #set_recurring_event parser week number parameter",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has date",
+ "contents": "[[Has type::Date]]"
+ },
+ {
+ "page": "Team meetings 1",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=January 15, 2019 9:30 am |end=December 31, 2019 |unit=month |week number=2 }}"
+ },
+ {
+ "page": "Team meetings 2",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=January 31, 2019 9:30 am |end=December 31, 2019 |unit=month |week number=-1 }}"
+ },
+ {
+ "page": "Team meetings in 2019 - 0",
+ "contents": "{{#ask: [[Is team meeting::Team meetings 1]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in 2019 - 1",
+ "contents": "{{#ask: [[Is team meeting::Team meetings 1]] |?Has date |format=plainlist }}"
+ },
+ {
+ "page": "Team meetings in 2019 - 2",
+ "contents": "{{#ask: [[Is team meeting::Team meetings 2]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in 2019 - 3",
+ "contents": "{{#ask: [[Is team meeting::Team meetings 2]] |?Has date |format=plainlist }}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0 #set_recurring_event parser with end date and week number dates - count",
+ "subject": "Team meetings in 2019 - 0",
+ "assert-output": {
+ "to-contain": [
+ "12"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#1 #set_recurring_event parser with end date and week number dates - print",
+ "subject": "Team meetings in 2019 - 1",
+ "assert-output": {
+ "to-contain": [
+ "10 décembre 2019 09:30:00"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#2 #set_recurring_event parser with end date and week number dates - count",
+ "subject": "Team meetings in 2019 - 2",
+ "assert-output": {
+ "to-contain": [
+ "12"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#3 #set_recurring_event parser with end date and week number dates - print",
+ "subject": "Team meetings in 2019 - 3",
+ "assert-output": {
+ "to-contain": [
+ "29 août 2019 09:30:00"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "fr",
+ "wgLang": "de"
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0115.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0115.json
new file mode 100644
index 00000000..96c9c8bd
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0115.json
@@ -0,0 +1,130 @@
+{
+ "description": "Test `#set_recurring_event` parser for events on 29th to 31st of the month (#3598 - `wgContLang=fr`, `wgLang=en`)",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has date",
+ "contents": "[[Has type::Date]]"
+ },
+ {
+ "page": "Team meetings - en",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=January 31, 2003 9:30 am |end=December 31, 2004 9:30 am |unit=month }}"
+ },
+ {
+ "page": "Team meetings - fr",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=30 janvier 2003 9:30 am |end=31 décembre 2004 9:30 am |unit=month }}"
+ },
+ {
+ "page": "Team meetings - ISO",
+ "contents": "{{#set_recurring_event: Is team meeting |property=Has date |start=2003-01-29T09:30:00 |end=2004-12-31T09:30:00 |unit=month }}"
+ },
+ {
+ "page": "Team meetings in 2003 and 2004 - 0 - en",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - en]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in 2003 and 2004 - 1 - en",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - en]] |?Has date |format=plainlist }}"
+ },
+ {
+ "page": "Team meetings in 2003 and 2004 - 2 - fr",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - fr]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in 2003 and 2004 - 3 - fr",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - fr]] |?Has date |format=plainlist }}"
+ },
+ {
+ "page": "Team meetings in 2003 and 2004 - 4 - ISO",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - ISO]] |format=count }}"
+ },
+ {
+ "page": "Team meetings in 2003 and 2004 - 5 - ISO",
+ "contents": "{{#ask: [[Is team meeting::Team meetings - ISO]] |?Has date |format=plainlist }}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0 #set_recurring_event parser for the 31st or alternatively the last day of a month - count",
+ "subject": "Team meetings in 2003 and 2004 - 0 - en",
+ "assert-output": {
+ "to-contain": [
+ "24"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#1 #set_recurring_event parser for the 31st or alternatively the last day of a month - print",
+ "subject": "Team meetings in 2003 and 2004 - 1 - en",
+ "assert-output": {
+ "to-contain": [
+ "31 mars 2003 09:30:00",
+ "30 avril 2003 09:30:00",
+ "30 novembre 2004 09:30:00",
+ "31 décembre 2004 09:30:00"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#2 #set_recurring_event parser for the 30th or alternatively the last day of a month - count",
+ "subject": "Team meetings in 2003 and 2004 - 2 - fr",
+ "assert-output": {
+ "to-contain": [
+ "24"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#3 #set_recurring_event parser for the 30th or alternatively the last day of a month - print",
+ "subject": "Team meetings in 2003 and 2004 - 3 - fr",
+ "assert-output": {
+ "to-contain": [
+ "28 février 2003 09:30:00",
+ "30 mars 2003 09:30:00",
+ "29 février 2004 09:30:00",
+ "30 mars 2004 09:30:00"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#4 #set_recurring_event parser for the 29th or alternatively the last day of a month - count",
+ "subject": "Team meetings in 2003 and 2004 - 4 - ISO",
+ "assert-output": {
+ "to-contain": [
+ "24"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#5 #set_recurring_event parser for the 29th or alternatively the last day of a month - print",
+ "subject": "Team meetings in 2003 and 2004 - 5 - ISO",
+ "assert-output": {
+ "to-contain": [
+ "28 février 2003 09:30:00",
+ "29 août 2003 09:30:00",
+ "29 février 2004 09:30:00",
+ "29 août 2004 09:30:00"
+ ],
+ "not-contain": [
+ "29 février 2003 09:30:00",
+ "28 février 2004 09:30:00"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "fr",
+ "wgLang": "en"
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0208.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0208.json
index 7bbbb9d1..2e42ef6c 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0208.json
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0208.json
@@ -98,7 +98,7 @@
"1.0e-5",
"4.0e-4",
"2.0e-6",
- "30,000"
+ "30000"
]
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0443.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0443.json
index d8763ff1..b7897824 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0443.json
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0443.json
@@ -1,5 +1,5 @@
{
- "description": "Test conditions and strict constraint validations for uniqueness `_PVUC` (#1463, `wgContLang=en`, `wgLang=en`, `smwgDVFeatures`)",
+ "description": "Test conditions and strict constraint validations for uniqueness `_PVUC` on `_txt`/`_rec`/`_ref_rec` with unique field (#1463, #3547, `smwgDVFeatures`)",
"setup": [
{
"namespace": "SMW_NS_PROPERTY",
@@ -12,12 +12,52 @@
"contents": "[[Has type::Text]] [[Has uniqueness constraint::true]]"
},
{
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Unique field",
+ "contents": "[[Has type::Text]] [[Has uniqueness constraint::true]]"
+ },
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Another unique field",
+ "contents": "[[Has type::Text]] [[Has uniqueness constraint::true]]"
+ },
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Unique record",
+ "contents": "[[Has type::Record]] [[Has fields::Unique field;Non unique field]]"
+ },
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Unique reference",
+ "contents": "[[Has type::Reference]] [[Has fields::Unique field;Another unique field;Non unique field]]"
+ },
+ {
"page": "Example/P0443/1",
"contents": "[[Has uniqueness one::Allowed one]] [[Has uniqueness one::Not permitted]] [[Has uniqueness two::Allowed two]] [[Has uniqueness two::Not permitted]]"
},
{
"page": "Example/P0443/2",
"contents": "[[Has uniqueness one::1111]] {{#ask: [[Has uniqueness one::1111]] |link=none |format=plainlist}}"
+ },
+ {
+ "page": "Example/P0443/3",
+ "contents": "[[Unique record::abc;123]]"
+ },
+ {
+ "page": "Example/P0443/4",
+ "contents": "[[Unique record::abc;123]] (fails on abc)"
+ },
+ {
+ "page": "Example/P0443/5",
+ "contents": "[[Unique reference::abc;def;123]] (fails on abc)"
+ },
+ {
+ "page": "Example/P0443/6",
+ "contents": "[[Unique reference::abcd;def;123]]"
+ },
+ {
+ "page": "Example/P0443/7",
+ "contents": "[[Unique reference::abcde;def;123]] (fails on def)"
}
],
"tests": [
@@ -55,6 +95,92 @@
"<p>1111 Example/P0443/2"
]
}
+ },
+ {
+ "type": "parser",
+ "about": "#2 (verify uniqueness of field in record )",
+ "subject": "Example/P0443/3",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_MDAT",
+ "_SKEY",
+ "Unique record"
+ ],
+ "propertyValues": [
+ "abc; 123"
+ ]
+ }
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#3 (verify uniqueness of field in record fails for same value as used in Example/P0443/3)",
+ "subject": "Example/P0443/4",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_MDAT",
+ "_SKEY",
+ "_ERRC"
+ ]
+ }
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#4 (verify uniqueness of field in reference fails for same value as used in Example/P0443/3)",
+ "subject": "Example/P0443/5",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_MDAT",
+ "_SKEY",
+ "_ERRC"
+ ]
+ }
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#5 (verify uniqueness for reference with uniqueness fields)",
+ "subject": "Example/P0443/6",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_MDAT",
+ "_SKEY",
+ "Unique reference"
+ ],
+ "propertyValues": [
+ "abcd"
+ ]
+ }
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#6 (verify uniqueness of field in reference fails for same value as used in Example/P0443/6)",
+ "subject": "Example/P0443/7",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_MDAT",
+ "_SKEY",
+ "_ERRC"
+ ]
+ }
+ }
}
],
"settings": {
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0461.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0461.json
new file mode 100644
index 00000000..cf24f3be
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0461.json
@@ -0,0 +1,92 @@
+{
+ "description": "Test `_wpg` value with lower/upper first case letter +DISPLAYTITLE (#3587, `wgRestrictDisplayTitle`, `wgCapitalLinks`)",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has number",
+ "contents": "[[Has type::Number]]"
+ },
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has text",
+ "contents": "[[Has type::Text]]"
+ },
+ {
+ "page": "P0461/1",
+ "contents": "[[Has number::123]] [[Has text::abc]] [[Category:P0461]] {{DISPLAYTITLE:p0461/1}}"
+ },
+ {
+ "page": "P0461/2",
+ "contents": "[[Category:P0461]] [[Has text::ABC]] {{DISPLAYTITLE:p0461/2}}"
+ },
+ {
+ "page": "P0461/Q.1",
+ "contents": "{{#show: p0461/1 |?Has number |intro=p0461: }}"
+ },
+ {
+ "page": "P0461/Q.2",
+ "contents": "{{#show: P0461/1 |?Has number |intro=P0461: }}"
+ },
+ {
+ "page": "P0461/Q.3",
+ "contents": "{{#ask: [[p0461/1]] |?Has text |intro=p0461: |format=plain |mainlabel=- |headers=hide }}"
+ },
+ {
+ "page": "P0461/Q.4",
+ "contents": "{{#ask: [[P0461/1]] |?Has text |intro=P0461: |format=plain |mainlabel=- |headers=hide }}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0 (#show, lower case `p0461`)",
+ "subject": "P0461/Q.1",
+ "assert-output": {
+ "to-contain": [
+ "p0461:123"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#1 (#show, upper case `P0461`)",
+ "subject": "P0461/Q.2",
+ "assert-output": {
+ "to-contain": [
+ "P0461:123"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#2 (#ask, lower case `p0461`)",
+ "subject": "P0461/Q.3",
+ "assert-output": {
+ "to-contain": [
+ "p0461:abc"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#3 (#ask, upper case `P0461`)",
+ "subject": "P0461/Q.4",
+ "assert-output": {
+ "to-contain": [
+ "P0461:abc"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLang": "en",
+ "wgCapitalLinks": true,
+ "wgRestrictDisplayTitle": false
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0503.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0503.json
index 493c9ad6..9a908ac9 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0503.json
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0503.json
@@ -1,5 +1,5 @@
{
- "description": "Test in-text annotation `_uri` on valid/invalid scheme",
+ "description": "Test in-text annotation `_uri` on valid/invalid scheme/path",
"setup": [
{
"namespace": "SMW_NS_PROPERTY",
@@ -15,6 +15,10 @@
"contents": "[[Has url::User:Test]]"
},
{
+ "page": "Example/P0503/3",
+ "contents": "[[Has url::http:///]]"
+ },
+ {
"page": "Example/P0503/Q.1",
"contents": "{{#ask: [[Has url::User:Test]] |default=No result }}"
}
@@ -67,6 +71,25 @@
"<span class=\"smw-highlighter\" data-type=\"4\" data-state=\"inline\""
]
}
+ },
+ {
+ "type": "parser",
+ "about": "#3 invalid path `///`",
+ "subject": "Example/P0503/3#_ERRd3ce18ed907900b1ec8f6a2b7bce6aea",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_SKEY",
+ "_ERRT",
+ "_ERRP"
+ ],
+ "propertyValues": [
+ "\"http:///\" has been idendified to contain an invalid \"/\" authority or path component."
+ ]
+ }
+ }
}
],
"settings": {
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0504.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0504.json
new file mode 100644
index 00000000..a80aa705
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0504.json
@@ -0,0 +1,49 @@
+{
+ "description": "Test Equivalent URI (`__spu`)",
+ "setup": [
+ {
+ "namespace": "NS_MAIN",
+ "page": "Test:P0504/1",
+ "contents": "[[Equivalent URI::http://www.wikidata.org/entity/Q20728]]"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#3601, Equivalent URI property must not be declarative, (i. e., it can be used on subject pages, as well as property and category pages)",
+ "subject": "Test:P0504/1",
+ "assert-store": {
+ "semantic-data": {
+ "strictPropertyValueMatch": false,
+ "propertyCount": 3,
+ "propertyKeys": [
+ "_URI",
+ "_MDAT",
+ "_SKEY"
+ ],
+ "propertyValues": [
+ "http://www.wikidata.org/entity/Q20728"
+ ]
+ }
+ },
+ "assert-output": {
+ "not-contain": [
+ "is a declarative property"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLang": "en",
+ "smwgNamespacesWithSemanticLinks": {
+ "NS_MAIN": true,
+ "SMW_NS_PROPERTY": true
+ }
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0712.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0712.json
new file mode 100644
index 00000000..0a9c2811
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/p-0712.json
@@ -0,0 +1,64 @@
+{
+ "description": "Test `#ask` on `format=template`/`link=none`/DISPLAYTITLE with nested template",
+ "setup": [
+ {
+ "namespace": "NS_TEMPLATE",
+ "page": "Example/P0712/Parse 1",
+ "contents": "<includeonly>'''Parse 1 result:'''<br>Modify to link: [[{{{1|}}}]]<br>As-is output: {{{1|}}} '''Parse 2 result:'''<br>{{Example/P0712/Parse 2|{{{1|}}} }}</includeonly>"
+ },
+ {
+ "namespace": "NS_TEMPLATE",
+ "page": "Example/P0712/Parse 2",
+ "contents": "<includeonly>Modify to link: [[{{{1|}}}]]<br>As-is output: {{{1|}}}</includeonly>"
+ },
+ {
+ "page": "Test:P0712/1",
+ "contents": "[[Issue::3853]] {{DISPLAYTITLE:Displaytitle P0712}}"
+ },
+ {
+ "page": "Test:P0712/Q.1",
+ "contents": "{{#ask: [[Issue::3853]] |link=none |template=Example/P0712/Parse 1 |format=template }}"
+ },
+ {
+ "page": "Test:P0712/Q.2",
+ "contents": "{{#ask: [[Issue::3853]] |template=Example/P0712/Parse 1 |format=template }}"
+ }
+ ],
+ "tests": [
+ {
+ "type": "parser",
+ "about": "#0 `link=none`",
+ "subject": "Test:P0712/Q.1",
+ "assert-output": {
+ "to-contain": [
+ "<b>Parse 1 result:</b><br />Modify to link: <a href=\".*Test:P0712/1\" title=\"Test:P0712/1\">Test:P0712/1</a>",
+ "<b>Parse 2 result:</b><br />Modify to link: <a href=\".*Test:P0712/1\" title=\"Test:P0712/1\">Test:P0712/1 </a><br />As-is output: Test:P0712/1"
+ ]
+ }
+ },
+ {
+ "type": "parser",
+ "about": "#1 ",
+ "subject": "Test:P0712/Q.2",
+ "assert-output": {
+ "to-contain": [
+ "<b>Parse 1 result:</b><br />Modify to link: [[<a href=\".*Test:P0712/1\" title=\"Test:P0712/1\">Displaytitle P0712</a>]]<br />",
+ "<b>Parse 2 result:</b><br />Modify to link: [[<a href=\".*/Test:P0712/1\" title=\"Test:P0712/1\">Displaytitle P0712</a> ]]"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLang": "en",
+ "wgRestrictDisplayTitle": false,
+ "smwgPageSpecialProperties": [
+ "_MDAT"
+ ]
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0612.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0612.json
index c151c49c..928bd4da 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0612.json
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0612.json
@@ -1,5 +1,5 @@
{
- "description": "Test `_wpg` object value that contains `=` (equals sign) (#640, #710, #1542, #1645, `wgContLang=en`, `wgLang=en`)",
+ "description": "Test `_wpg` object value that contains `=` (equals sign) (#640, #710, #1542, #1645, #3560)",
"setup": [
{
"namespace": "SMW_NS_PROPERTY",
@@ -11,6 +11,10 @@
"contents": "[[Category:Q0612]] [[Has page::{{FULLPAGENAME}}]]"
},
{
+ "page": "Example/Q0612/-3D=",
+ "contents": "[[Category:Q0612]] [[Has page::{{FULLPAGENAME}}]]"
+ },
+ {
"page": "Example/Q0612/Q1",
"contents": "{{#show: Example/Q0612/1(=) |?Has page |link=none }}"
}
@@ -61,6 +65,21 @@
"Example/Q0612/1(=)#0##"
]
}
+ },
+ {
+ "type": "query",
+ "about": "#1",
+ "condition": "[[Category:Q0612]] [[Has page::Example/Q0612/-3D=]]",
+ "printouts": [],
+ "parameters": {
+ "limit": 10
+ },
+ "assert-queryresult": {
+ "count": 1,
+ "results": [
+ "Example/Q0612/-3D=#0##"
+ ]
+ }
}
],
"settings": {
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0623.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0623.json
new file mode 100644
index 00000000..4ef1d39c
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/q-0623.json
@@ -0,0 +1,85 @@
+{
+ "description": "Test query with `_SUBC`",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has page",
+ "contents": "[[Has type::Page]]"
+ },
+ {
+ "namespace": "NS_CATEGORY",
+ "page": "Q0623",
+ "contents": ""
+ },
+ {
+ "namespace": "NS_CATEGORY",
+ "page": "Q0623/1",
+ "contents": "[[Category:Q0623]]"
+ },
+ {
+ "namespace": "NS_CATEGORY",
+ "page": "Q0623/1/1",
+ "contents": "[[Category:Q0623/1]]"
+ },
+ {
+ "namespace": "NS_CATEGORY",
+ "page": "Q0623/1/2",
+ "contents": "[[Category:Q0623/1]]"
+ }
+ ],
+ "tests": [
+ {
+ "type": "query",
+ "about": "#0 (without `Category:` namespace, #3550)",
+ "condition": "[[Subcategory of::Q0623/1]]",
+ "printouts": [],
+ "parameters": {
+ "limit": "10"
+ },
+ "assert-queryresult": {
+ "count": 2,
+ "results": [
+ "Q0623/1/1#14##",
+ "Q0623/1/2#14##"
+ ]
+ }
+ },
+ {
+ "type": "query",
+ "about": "#1 (with `Category:` namespace)",
+ "condition": "[[Subcategory of::Category:Q0623/1]]",
+ "printouts": [],
+ "parameters": {
+ "limit": "10"
+ },
+ "assert-queryresult": {
+ "count": 2,
+ "results": [
+ "Q0623/1/1#14##",
+ "Q0623/1/2#14##"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "smwgNamespacesWithSemanticLinks": {
+ "NS_MAIN": true,
+ "NS_CATEGORY": true,
+ "SMW_NS_PROPERTY": true,
+ "NS_HELP": true
+ },
+ "wgContLang": "en",
+ "wgLang": "en",
+ "smwgQSubpropertyDepth": 10,
+ "smwgQSubcategoryDepth": 10,
+ "smwgSparqlQFeatures": [
+ "SMW_SPARQL_QF_SUBP",
+ "SMW_SPARQL_QF_SUBC"
+ ]
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0018.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0018.json
index d705dd4a..6491a23c 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0018.json
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0018.json
@@ -26,6 +26,50 @@
"<div id=\"ask-status\" class=\"smw-ask-status plainlinks\"><noscript><div class=\"smw-callout smw-callout-error\">"
]
}
+ },
+ {
+ "type": "special",
+ "about": "#1 (@see #3542, `format= table`)",
+ "special-page": {
+ "page": "Ask",
+ "query-parameters": "-5B-5BCategory:S0018-5D-5D/-3FHas-20page/mainlabel%3D/offset%3D0/format%3D-20table",
+ "request-parameters": {}
+ },
+ "assert-output": {
+ "to-contain": [
+ "{{#ask: [[Category:S0018]]",
+ " |?Has page",
+ " |format=table",
+ " |limit=50",
+ " |offset=0",
+ " |sort=",
+ " |order=asc",
+ " |mainlabel=",
+ "}}"
+ ]
+ }
+ },
+ {
+ "type": "special",
+ "about": "#2 (`format=TABLE`)",
+ "special-page": {
+ "page": "Ask",
+ "query-parameters": "-5B-5BCategory:S0018-5D-5D/-3FHas-20page/mainlabel%3D/offset%3D0/format%3DTABLE",
+ "request-parameters": {}
+ },
+ "assert-output": {
+ "to-contain": [
+ "{{#ask: [[Category:S0018]]",
+ " |?Has page",
+ " |format=table",
+ " |limit=50",
+ " |offset=0",
+ " |sort=",
+ " |order=asc",
+ " |mainlabel=",
+ "}}"
+ ]
+ }
}
],
"settings": {
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0031.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0031.json
new file mode 100644
index 00000000..829a37c8
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0031.json
@@ -0,0 +1,95 @@
+{
+ "description": "Test `Special:Ask` output on `?...=[[...|...]]|+index...`",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has page",
+ "contents": "[[Has type::Page]]"
+ },
+ {
+ "page": "Example/S0031/1",
+ "contents": "[[Has page::123]] [[Category:S0031]]"
+ }
+ ],
+ "tests": [
+ {
+ "type": "special",
+ "about": "#0 (#3211, label `?Has page=[[Foo|bar]]` ",
+ "special-page": {
+ "page": "Ask",
+ "query-parameters": "-5B-5BHas-20page::123-5D-5D-20-5B-5BCategory:S0031-5D-5D/-3FHas-20page%3D-5B-5BFoo-7Cbar-5D-5D/mainlabel%3D/offset%3D0/format%3Dtable/headers%3Dplain",
+ "request-parameters": []
+ },
+ "assert-output": {
+ "to-contain": [
+ "{{#ask: [[Has page::123]] [[Category:S0031]]",
+ " |?Has page=[[Foo|bar]]",
+ " |order=asc",
+ " |headers=plain",
+ " |mainlabel="
+ ]
+ }
+ },
+ {
+ "type": "special",
+ "about": "#1 (#3211, label `?Has page=[[Foo|bar]]|+index=1` ",
+ "special-page": {
+ "page": "Ask",
+ "query-parameters": "-5B-5BHas-20page::123-5D-5D-20-5B-5BCategory:S0031-5D-5D/-3FHas-20page%3D-5B-5BFoo-7Cbar-5D-5D-7C%2Bindex%3D1/mainlabel%3D/offset%3D0/format%3Dtable/headers%3Dplain",
+ "request-parameters": []
+ },
+ "assert-output": {
+ "to-contain": [
+ "{{#ask: [[Has page::123]] [[Category:S0031]]",
+ " |?Has page=[[Foo|bar]]|+index=1",
+ " |order=asc",
+ " |headers=plain",
+ " |mainlabel="
+ ]
+ }
+ },
+ {
+ "type": "special",
+ "about": "#2 (#3211, label `?Has page=[[Foo|bar]]|+index=1` ",
+ "special-page": {
+ "page": "Ask",
+ "query-parameters": [],
+ "request-parameters": {
+ "p": {
+ "headers": "plain",
+ "limit": "10",
+ "offset": "0",
+ "mainlabel": "",
+ "searchlabel": ""
+ },
+ "q": "[[Has page::123]] [[Category:S0031]]",
+ "po": "?Has page=[[Foo|bar]]|+index=1"
+ }
+ },
+ "assert-output": {
+ "to-contain": [
+ "{{#ask: [[Has page::123]] [[Category:S0031]]",
+ " |?Has page=[[Foo|bar]]|+index=1",
+ " |order=asc",
+ " |headers=plain"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLanguageCode": "en",
+ "smwgPageSpecialProperties": [
+ "_MDAT"
+ ],
+ "smwgNamespacesWithSemanticLinks": {
+ "NS_MAIN": true,
+ "SMW_NS_PROPERTY": true
+ }
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0032.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0032.json
new file mode 100644
index 00000000..dd2f11ad
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0032.json
@@ -0,0 +1,65 @@
+{
+ "description": "Test `format=json` output via `Special:Ask` for `_ref_rec`/`_qty` type (#3517)",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Ref prop",
+ "contents": "[[Has type::Reference]] [[Has fields::Field prop;other prop]]"
+ },
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Field prop",
+ "contents": "[[Has type::Quantity]] [[Corresponds to::1 km]]"
+ },
+ {
+ "namespace": "NS_MAIN",
+ "page": "S0032/1",
+ "contents": "[[Ref prop::123;S0032/2]] [[Category:S0032]]"
+ }
+ ],
+ "tests": [
+ {
+ "type": "special",
+ "about": "#0",
+ "special-page": {
+ "page": "Ask",
+ "request-parameters": {
+ "p": {
+ "link": "none",
+ "limit": "10",
+ "offset": "0",
+ "mainlabel": "",
+ "prettyprint": false,
+ "unescape": true,
+ "format": "json"
+ },
+ "q": "[[Category:S0032]]",
+ "po": "?Ref prop.Field prop"
+ }
+ },
+ "assert-output": {
+ "to-contain": [
+ "\"chain\":\"Ref prop.Field prop\"",
+ "{\"Field prop\":[{\"value\":123,\"unit\":\"km\"}]}"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLang": "en",
+ "wgLanguageCode": "en",
+ "smwgPageSpecialProperties": [
+ "_MDAT"
+ ],
+ "smwgNamespacesWithSemanticLinks": {
+ "NS_MAIN": true,
+ "SMW_NS_PROPERTY": true
+ }
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0033.json b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0033.json
new file mode 100644
index 00000000..ad430659
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/JSONScript/TestCases/s-0033.json
@@ -0,0 +1,59 @@
+{
+ "description": "Test output from `Special:SearchByProperty` to show all values for a property (#3531)",
+ "setup": [
+ {
+ "namespace": "SMW_NS_PROPERTY",
+ "page": "Has vtext",
+ "contents": "[[Has type::Text]]"
+ },
+ {
+ "page": "Test/S0033/1",
+ "contents": "[[Has vtext::123]] [[Has vtext::456]] [[Has vtext::abc]] [[Has vtext::def]] [[Has vtext::1001]] [[Has vtext::42]]"
+ },
+ {
+ "page": "Test/S0033/2",
+ "contents": "[[Has vtext::123]] [[Has vtext::456]] [[Has vtext::abc]] [[Has vtext::def]] [[Has vtext::1001]] [[Has vtext::42]]"
+ },
+ {
+ "page": "Test/S0033/3",
+ "contents": "[[Has vtext::123]] [[Has vtext::456]] [[Has vtext::abc]] [[Has vtext::def]] [[Has vtext::1001]] [[Has vtext::42]]"
+ },
+ {
+ "page": "Test/S0033/4",
+ "contents": "[[Has vtext::123]] [[Has vtext::456]] [[Has vtext::abc]] [[Has vtext::def]] [[Has vtext::1001]] [[Has vtext::42]]"
+ }
+ ],
+ "tests": [
+ {
+ "type": "special",
+ "about": "#0 (find all values for property `Has vtext`)",
+ "special-page": {
+ "page": "SearchByProperty",
+ "query-parameters": "",
+ "request-parameters": {
+ "limit": 6,
+ "property": "Has vtext"
+ }
+ },
+ "assert-output": {
+ "to-contain": [
+ "<li>1001.*</li>",
+ "<li>123.*</li>",
+ "<li>42.*</li>",
+ "<li>456.*</li>",
+ "<li>abc.*</li>",
+ "<li>def.*</ul>"
+ ]
+ }
+ }
+ ],
+ "settings": {
+ "wgContLang": "en",
+ "wgLanguageCode": "en"
+ },
+ "meta": {
+ "version": "2",
+ "is-incomplete": false,
+ "debug": false
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/Maintenance/PopulateHashFieldTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/Maintenance/PopulateHashFieldTest.php
new file mode 100644
index 00000000..a75828a1
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Integration/Maintenance/PopulateHashFieldTest.php
@@ -0,0 +1,45 @@
+<?php
+
+namespace SMW\Tests\Integration\Maintenance;
+
+use SMW\Tests\MwDBaseUnitTestCase;
+use SMW\Tests\TestEnvironment;
+
+/**
+ * @group semantic-mediawiki
+ * @group medium
+ *
+ * @license GNU GPL v2+
+ * @since 3.1
+ *
+ * @author mwjames
+ */
+class PopulateHashField extends MwDBaseUnitTestCase {
+
+ protected $destroyDatabaseTablesAfterRun = true;
+ private $runnerFactory;
+
+ protected function setUp() {
+ parent::setUp();
+
+ $this->runnerFactory = TestEnvironment::getUtilityFactory()->newRunnerFactory();
+ }
+
+ protected function tearDown() {
+ parent::tearDown();
+ }
+
+ public function testRun() {
+
+ $maintenanceRunner = $this->runnerFactory->newMaintenanceRunner(
+ 'SMW\Maintenance\PopulateHashField'
+ );
+
+ $maintenanceRunner->setQuiet();
+
+ $this->assertTrue(
+ $maintenanceRunner->run()
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/EventHandlerTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/EventHandlerTest.php
index d011322e..0413c400 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/EventHandlerTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/EventHandlerTest.php
@@ -73,7 +73,7 @@ class EventHandlerTest extends \PHPUnit_Framework_TestCase {
public function testAddCallbackListenerForAdhocRegistration() {
- $eventDispatcher = $this->getMockBuilder( '\Onoi\EventDispatcher\EventDispatcher' )
+ $eventDispatcher = $this->getMockBuilder( '\Onoi\EventDispatcher\Dispatcher\GenericEventDispatcher' )
->disableOriginalConstructor()
->getMock();
@@ -84,8 +84,7 @@ class EventHandlerTest extends \PHPUnit_Framework_TestCase {
$this->anything() );
$instance = new EventHandler( $eventDispatcher );
- $instance->addCallbackListener( 'foo', function (){
- } );
+ $instance->addCallbackListener( 'foo', function (){} );
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotReadableExceptionTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotReadableExceptionTest.php
new file mode 100644
index 00000000..fa98e353
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotReadableExceptionTest.php
@@ -0,0 +1,33 @@
+<?php
+
+namespace SMW\Tests\Exception;
+
+use SMW\Exception\FileNotReadableException;
+
+/**
+ * @covers \SMW\Exception\FileNotReadableException
+ * @group semantic-mediawiki
+ *
+ * @license GNU GPL v2+
+ * @since 3.0
+ *
+ * @author mwjames
+ */
+class FileNotReadableExceptionTest extends \PHPUnit_Framework_TestCase {
+
+ public function testCanConstruct() {
+
+ $instance = new FileNotReadableException( 'Foo' );
+
+ $this->assertInstanceof(
+ FileNotReadableException::class,
+ $instance
+ );
+
+ $this->assertInstanceof(
+ '\RuntimeException',
+ $instance
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotWritableExceptionTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotWritableExceptionTest.php
new file mode 100644
index 00000000..5c9f3cac
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Exception/FileNotWritableExceptionTest.php
@@ -0,0 +1,33 @@
+<?php
+
+namespace SMW\Tests\Exception;
+
+use SMW\Exception\FileNotWritableException;
+
+/**
+ * @covers \SMW\Exception\FileNotWritableException
+ * @group semantic-mediawiki
+ *
+ * @license GNU GPL v2+
+ * @since 3.0
+ *
+ * @author mwjames
+ */
+class FileNotWritableExceptionTest extends \PHPUnit_Framework_TestCase {
+
+ public function testCanConstruct() {
+
+ $instance = new FileNotWritableException( 'Foo' );
+
+ $this->assertInstanceof(
+ FileNotWritableException::class,
+ $instance
+ );
+
+ $this->assertInstanceof(
+ '\RuntimeException',
+ $instance
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Deferred/TransactionalCallableUpdateTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Deferred/TransactionalCallableUpdateTest.php
index 1a44a81b..4505ba62 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Deferred/TransactionalCallableUpdateTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Deferred/TransactionalCallableUpdateTest.php
@@ -351,4 +351,45 @@ class TransactionalCallableUpdateTest extends \PHPUnit_Framework_TestCase {
$this->testEnvironment->executePendingDeferredUpdates();
}
+ public function testCancelOnRollback() {
+
+ $connection = $this->getMockBuilder( '\SMW\MediaWiki\Database' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $connection->expects( $this->never() )
+ ->method( 'getEmptyTransactionTicket' );
+
+ $this->testEnvironment->clearPendingDeferredUpdates();
+
+ $test = $this->getMockBuilder( '\stdClass' )
+ ->disableOriginalConstructor()
+ ->setMethods( [ 'doTest' ] )
+ ->getMock();
+
+ $test->expects( $this->never() )
+ ->method( 'doTest' );
+
+ $callback = function() use ( $test ) {
+ $test->doTest();
+ };
+
+ $instance = new TransactionalCallableUpdate(
+ $callback,
+ $connection
+ );
+
+ $instance->setLogger( $this->spyLogger );
+
+ $instance->isDeferrableUpdate( false );
+ $instance->commitWithTransactionTicket();
+
+ // #3765
+ $instance->cancelOnRollback( \SMW\MediaWiki\Database::TRIGGER_ROLLBACK );
+
+ $instance->pushUpdate();
+
+ $this->testEnvironment->executePendingDeferredUpdates();
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/BeforePageDisplayTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/BeforePageDisplayTest.php
index e00ec322..3c025f01 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/BeforePageDisplayTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/BeforePageDisplayTest.php
@@ -77,6 +77,30 @@ class BeforePageDisplayTest extends \PHPUnit_Framework_TestCase {
$instance->process( $this->outputPage, $this->skin );
}
+ public function testPrependHTML_InstallerIncompleteTasks() {
+
+ $user = $this->getMockBuilder( '\User' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $this->outputPage->expects( $this->atLeastOnce() )
+ ->method( 'prependHTML' );
+
+ $this->outputPage->expects( $this->atLeastOnce() )
+ ->method( 'getUser' )
+ ->will( $this->returnValue( $user ) );
+
+ $instance = new BeforePageDisplay();
+
+ $instance->setOptions(
+ [
+ 'installer.incomplete_tasks' => [ 'Foo', 'Bar' ]
+ ]
+ );
+
+ $instance->process( $this->outputPage, $this->skin );
+ }
+
/**
* @dataProvider titleDataProvider
*/
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/ResourceLoaderTestModulesTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/ResourceLoaderTestModulesTest.php
index 2ac8fb33..dea78b79 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/ResourceLoaderTestModulesTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Hooks/ResourceLoaderTestModulesTest.php
@@ -42,6 +42,16 @@ class ResourceLoaderTestModulesTest extends \PHPUnit_Framework_TestCase {
'ext.smw.tests',
$testModules['qunit']
);
+
+ $this->assertArrayHasKey(
+ 'localBasePath',
+ $testModules['qunit']['ext.smw.tests']
+ );
+
+ $this->assertArrayHasKey(
+ 'remoteExtPath',
+ $testModules['qunit']['ext.smw.tests']
+ );
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Specials/Ask/ParametersProcessorTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Specials/Ask/ParametersProcessorTest.php
index 65d98474..532b9d48 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Specials/Ask/ParametersProcessorTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/MediaWiki/Specials/Ask/ParametersProcessorTest.php
@@ -46,6 +46,63 @@ class ParametersProcessorTest extends \PHPUnit_Framework_TestCase {
);
}
+ public function testParameters_Printrequest_PlusPipe() {
+
+ $request = $this->getMockBuilder( '\WebRequest' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $parameters = [
+ '[[Foo::bar]]',
+ '|?Foo=Bar|+index=1'
+ ];
+
+ $result = ParametersProcessor::process( $request, $parameters );
+
+ $this->assertEquals(
+ 'Bar|+index=1',
+ $result[1]['|?foo']
+ );
+ }
+
+ public function testParameters_Printrequest_WikiLink() {
+
+ $request = $this->getMockBuilder( '\WebRequest' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $parameters = [
+ '[[Foo::bar]]',
+ '|?Foo=[[Some|other]]'
+ ];
+
+ $result = ParametersProcessor::process( $request, $parameters );
+
+ $this->assertEquals(
+ '[[Some|other]]',
+ $result[1]['|?foo']
+ );
+ }
+
+ public function testParameters_Printrequest_WikiLink_PlusPipe() {
+
+ $request = $this->getMockBuilder( '\WebRequest' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $parameters = [
+ '[[Foo::bar]]',
+ '|?Foo=[[Some|other]]|+index=1'
+ ];
+
+ $result = ParametersProcessor::process( $request, $parameters );
+
+ $this->assertEquals(
+ '[[Some|other]]|+index=1',
+ $result[1]['|?foo']
+ );
+ }
+
public function testParametersWithDefaults() {
$request = $this->getMockBuilder( '\WebRequest' )
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/ParserFunctions/RecurringEventsParserFunctionTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/ParserFunctions/RecurringEventsParserFunctionTest.php
index 2192fbdb..d00fa934 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/ParserFunctions/RecurringEventsParserFunctionTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/ParserFunctions/RecurringEventsParserFunctionTest.php
@@ -6,6 +6,7 @@ use ParserOutput;
use ReflectionClass;
use SMW\MessageFormatter;
use SMW\ParserData;
+use SMW\RecurringEvents;
use SMW\ParserFunctions\RecurringEventsParserFunction;
use SMW\ParserParameterProcessor;
use SMW\Subobject;
@@ -35,11 +36,12 @@ class RecurringEventsParserFunctionTest extends \PHPUnit_Framework_TestCase {
->getMock();
$this->assertInstanceOf(
- '\SMW\ParserFunctions\RecurringEventsParserFunction',
+ RecurringEventsParserFunction::class,
new RecurringEventsParserFunction(
$parserData,
$subobject,
- $messageFormatter
+ $messageFormatter,
+ new RecurringEvents()
)
);
}
@@ -49,30 +51,28 @@ class RecurringEventsParserFunctionTest extends \PHPUnit_Framework_TestCase {
*/
public function testParse( array $params, array $expected ) {
+ $recurringEvents = new RecurringEvents();
+ $recurringEvents->setDefaultNumRecurringEvents( 100 );
+ $recurringEvents->setMaxNumRecurringEvents( 100 );
+
$title = Title::newFromText( __METHOD__ );
$instance = new RecurringEventsParserFunction(
new ParserData( $title, new ParserOutput() ),
new Subobject( $title ),
- new MessageFormatter( \Language::factory( 'en' ) )
+ new MessageFormatter( \Language::factory( 'en' ) ),
+ $recurringEvents
);
- $instance->setDefaultNumRecurringEvents( 100 );
- $instance->setMaxNumRecurringEvents( 100 );
-
$result = $instance->parse(
new ParserParameterProcessor( $params )
);
$this->assertTrue( $result !== '' ? $expected['errors'] : !$expected['errors'] );
- $reflector = new ReflectionClass( '\SMW\ParserFunctions\RecurringEventsParserFunction' );
- $events = $reflector->getProperty( 'recurringEvents' );
- $events->setAccessible( true );
-
$this->assertEquals(
$expected['parameters'],
- $events->getValue( $instance )->getParameters()
+ $recurringEvents->getParameters()
);
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Parser/DescriptionProcessorTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Parser/DescriptionProcessorTest.php
index 098ddc36..0a1fcde5 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Parser/DescriptionProcessorTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Parser/DescriptionProcessorTest.php
@@ -22,7 +22,7 @@ class DescriptionProcessorTest extends \PHPUnit_Framework_TestCase {
public function testCanConstruct() {
$this->assertInstanceOf(
- 'SMW\Query\Parser\DescriptionProcessor',
+ DescriptionProcessor::class,
new DescriptionProcessor()
);
}
@@ -55,7 +55,7 @@ class DescriptionProcessorTest extends \PHPUnit_Framework_TestCase {
);
}
- public function testDescriptionForWikiPageValueChunk() {
+ public function testDescriptionForWikiPageValueChunkOnEqualMatch() {
$instance = new DescriptionProcessor();
@@ -67,7 +67,7 @@ class DescriptionProcessorTest extends \PHPUnit_Framework_TestCase {
);
$this->assertEquals(
- new DIWikiPage( 'bar', NS_MAIN ),
+ new DIWikiPage( 'Bar', NS_MAIN ),
$valueDescription->getDataItem()
);
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Processor/ParamListProcessorTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Processor/ParamListProcessorTest.php
index 8434f675..4636db13 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Processor/ParamListProcessorTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Query/Processor/ParamListProcessorTest.php
@@ -122,6 +122,47 @@ class ParamListProcessorTest extends \PHPUnit_Framework_TestCase {
]
];
+ // #3560
+ yield [
+ [ '[[Foo::Bar=-3DFoo]]' ],
+ false,
+ [
+ 'showMode' => false,
+ 'templateArgs' => false,
+ 'query' => '[[Foo::Bar=-3DFoo]]',
+ 'printouts' => [],
+ 'parameters' => [],
+ 'this' => []
+ ]
+ ];
+
+ yield [
+ [ '[[Foo::Bar=-3DFoox003D]]' ],
+ false,
+ [
+ 'showMode' => false,
+ 'templateArgs' => false,
+ 'query' => '[[Foo::Bar=-3DFoox003D]]',
+ 'printouts' => [],
+ 'parameters' => [],
+ 'this' => []
+ ]
+ ];
+
+ // A user shouldn't use `0x003D` as representation for `=`
+ yield [
+ [ '[[Foo::Bar=-3DFoo0x003D]]' ],
+ false,
+ [
+ 'showMode' => false,
+ 'templateArgs' => false,
+ 'query' => '[[Foo::Bar=-3DFoo=]]',
+ 'printouts' => [],
+ 'parameters' => [],
+ 'this' => []
+ ]
+ ];
+
yield [
[ '[[Foo::Bar]]', 'mainlabel=-' ],
false,
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/EntityStore/SemanticDataLookupTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/EntityStore/SemanticDataLookupTest.php
index bb25729f..de5e5872 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/EntityStore/SemanticDataLookupTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/EntityStore/SemanticDataLookupTest.php
@@ -4,6 +4,7 @@ namespace SMW\Tests\SQLStore\EntityStore;
use SMW\DIProperty;
use SMW\DIWikiPage;
+use SMWDIBlob as DIBlob;
use SMW\RequestOptions;
use SMW\SQLStore\EntityStore\SemanticDataLookup;
use SMW\Tests\PHPUnitCompat;
@@ -253,7 +254,7 @@ class SemanticDataLookupTest extends \PHPUnit_Framework_TestCase {
$instance->fetchSemanticData( 42, $subject, $propertyTable, $requestOptions );
$this->assertEquals(
- "SELECT p.smw_title AS prop, fooField AS v0, AS v2 FROM " .
+ "SELECT p.smw_title AS prop, fooField AS v0 FROM " .
"INNER JOIN smw_object_ids AS p ON p_id=p.smw_id " .
"WHERE (s_id='42') AND (p.smw_iw!=':smw') AND (p.smw_iw!=':smw-delete') AND (p_id='9999') " .
"LIMIT 4",
@@ -298,11 +299,58 @@ class SemanticDataLookupTest extends \PHPUnit_Framework_TestCase {
$instance->fetchSemanticData( 42, null, $propertyTable );
$this->assertEquals(
- "SELECT p.smw_title AS prop, fooField AS v0, AS v2 FROM " .
+ "SELECT p.smw_title AS prop, fooField AS v0 FROM " .
"INNER JOIN smw_object_ids AS p ON p_id=p.smw_id " .
"WHERE (s_id='42') AND (p.smw_iw!=':smw') AND (p.smw_iw!=':smw-delete')",
$this->query->build()
);
}
+ public function testFetchSemanticData_NonWikiPageTable_DISTINCT_SELECT() {
+
+ $row = new \stdClass;
+ $row->prop = 'FOO';
+ $row->v0 = '1001';
+
+ $this->dataItemHandler->expects( $this->any() )
+ ->method( 'getFetchFields' )
+ ->will( $this->returnValue( [ 'fooField' => 'fieldType' ] ) );
+
+ $propertyTable = $this->getMockBuilder( '\SMW\SQLStore\PropertyTableDefinition' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $propertyTable->expects( $this->atLeastOnce() )
+ ->method( 'getDIType' )
+ ->will( $this->returnValue( 'Foo' ) );
+
+ $propertyTable->expects( $this->atLeastOnce() )
+ ->method( 'getName' )
+ ->will( $this->returnValue( 'bar_table' ) );
+
+ $this->connection->expects( $this->any() )
+ ->method( 'addQuotes' )
+ ->will( $this->returnCallback( function( $value ) { return "'$value'"; } ) );
+
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->will( $this->returnValue( [ $row ] ) );
+
+ $dataItem = new DIBlob( __METHOD__ );
+
+ $requestOptions = new RequestOptions();
+ $requestOptions->setLimit( 4 );
+
+ $instance = new SemanticDataLookup(
+ $this->store
+ );
+
+ $instance->fetchSemanticData( 42, $dataItem, $propertyTable, $requestOptions );
+
+ $this->assertEquals(
+ "SELECT DISTINCT fooField AS v0 FROM bar_table WHERE (p_id='42') LIMIT 4",
+ $this->query->build()
+ );
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/InstallerTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/InstallerTest.php
index 0cf450e6..084e4fcb 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/InstallerTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/InstallerTest.php
@@ -22,6 +22,7 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
private $tableSchemaManager;
private $tableBuilder;
private $tableIntegrityExaminer;
+ private $file;
protected function setUp() {
parent::setUp();
@@ -44,6 +45,10 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
->disableOriginalConstructor()
->getMock();
+ $this->file = $this->getMockBuilder( '\SMW\Utils\File' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
$this->testEnvironment->registerObject( 'JobQueue', $this->jobQueue );
}
@@ -83,6 +88,7 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
);
$instance->setMessageReporter( $this->spyMessageReporter );
+ $instance->setFile( $this->file );
$instance->setOptions(
[
@@ -126,6 +132,8 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
);
$instance->setMessageReporter( $this->spyMessageReporter );
+ $instance->setFile( $this->file );
+
$instance->setOptions(
[
Installer::OPT_SUPPLEMENT_JOBS => true
@@ -157,6 +165,7 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
);
$instance->setMessageReporter( $this->spyMessageReporter );
+ $instance->setFile( $this->file );
$this->assertTrue(
$instance->install( false )
@@ -226,7 +235,7 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
);
}
- public function testGetUpgradeKey() {
+ public function testMakeUpgradeKey() {
$var1 = [
'smwgUpgradeKey' => '',
@@ -241,12 +250,12 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
];
$this->assertEquals(
- Installer::getUpgradeKey( $var1 ),
- Installer::getUpgradeKey( $var2 )
+ Installer::makeUpgradeKey( $var1 ),
+ Installer::makeUpgradeKey( $var2 )
);
}
- public function testGetUpgradeKey_SpecialFixedProperties() {
+ public function testMakeUpgradeKey_SpecialFixedProperties() {
$var1 = [
'smwgUpgradeKey' => '',
@@ -261,8 +270,8 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
];
$this->assertNotEquals(
- Installer::getUpgradeKey( $var1 ),
- Installer::getUpgradeKey( $var2 )
+ Installer::makeUpgradeKey( $var1 ),
+ Installer::makeUpgradeKey( $var2 )
);
}
@@ -282,13 +291,58 @@ class InstallerTest extends \PHPUnit_Framework_TestCase {
);
$vars = [
+ 'smwgConfigFileDir' => 'Foo/',
'smwgIP' => '',
'smwgUpgradeKey' => '',
'smwgFixedProperties' => [],
'smwgPageSpecialProperties' => []
];
- $instance->setUpgradeKey( $file, $vars, $this->spyMessageReporter );
+ $instance->setUpgradeKey( $vars, $this->spyMessageReporter, $file );
+ }
+
+ public function testSetUpgradeFile() {
+
+ $expected = json_encode( [ \SMW\Site::id() => [ 'Foo' => 42 ] ], JSON_PRETTY_PRINT );
+
+ $file = $this->getMockBuilder( '\SMW\Utils\File' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $file->expects( $this->once() )
+ ->method( 'write' )
+ ->with(
+ $this->equalTo( 'Foo_dir/.smw.json' ),
+ $this->equalTo( $expected ) );
+
+ $instance = new Installer(
+ $this->tableSchemaManager,
+ $this->tableBuilder,
+ $this->tableIntegrityExaminer
+ );
+
+ $vars = [
+ 'smwgConfigFileDir' => 'Foo_dir'
+ ];
+
+ $instance->setUpgradeFile( $vars, [ 'Foo' => 42 ], $file );
+ }
+
+ public function testIncompleteTasks() {
+
+ $vars = [
+ 'smw.json' => [ \SMW\Site::id() => [ Installer::POPULATE_HASH_FIELD_COMPLETE => false ] ]
+ ];
+
+ $this->assertEquals(
+ [ 'smw-install-incomplete-populate-hash-field' ],
+ Installer::incompleteTasks( $vars )
+ );
+
+ $this->assertEquals(
+ [],
+ Installer::incompleteTasks( [] )
+ );
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/Examiner/HashFieldTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/Examiner/HashFieldTest.php
new file mode 100644
index 00000000..3497f40f
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/Examiner/HashFieldTest.php
@@ -0,0 +1,106 @@
+<?php
+
+namespace SMW\Tests\SQLStore\TableBuilder\Examiner;
+
+use SMW\SQLStore\TableBuilder\Examiner\HashField;
+use SMW\Tests\TestEnvironment;
+
+/**
+ * @covers \SMW\SQLStore\TableBuilder\Examiner\HashField
+ * @group semantic-mediawiki
+ *
+ * @license GNU GPL v2+
+ * @since 3.1
+ *
+ * @author mwjames
+ */
+class HashFieldTest extends \PHPUnit_Framework_TestCase {
+
+ private $spyMessageReporter;
+ private $store;
+ private $populateHashField;
+
+ protected function setUp() {
+ parent::setUp();
+ $this->spyMessageReporter = TestEnvironment::getUtilityFactory()->newSpyMessageReporter();
+
+ $this->store = $this->getMockBuilder( '\SMW\SQLStore\SQLStore' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $this->populateHashField = $this->getMockBuilder( '\SMW\Maintenance\PopulateHashField' )
+ ->disableOriginalConstructor()
+ ->getMock();
+ }
+
+ public function testCanConstruct() {
+
+ $this->assertInstanceOf(
+ HashField::class,
+ new HashField( $this->store )
+ );
+ }
+
+ public function testCheck_Populate() {
+
+ $resultWrapper = $this->getMockBuilder( '\ResultWrapper' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $resultWrapper->expects( $this->once() )
+ ->method( 'numRows' )
+ ->will( $this->returnValue( HashField::threshold() - 1 ) );
+
+ $this->populateHashField->expects( $this->atLeastOnce() )
+ ->method( 'populate' );
+
+ $this->populateHashField->expects( $this->once() )
+ ->method( 'fetchRows' )
+ ->will( $this->returnValue( $resultWrapper ) );
+
+ $instance = new HashField(
+ $this->store,
+ $this->populateHashField
+ );
+
+ $instance->setMessageReporter( $this->spyMessageReporter );
+ $instance->check();
+
+ $this->assertContains(
+ 'Checking smw_hash field consistency',
+ $this->spyMessageReporter->getMessagesAsString()
+ );
+ }
+
+ public function testCheck_Incomplete() {
+
+ $resultWrapper = $this->getMockBuilder( '\ResultWrapper' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $resultWrapper->expects( $this->once() )
+ ->method( 'numRows' )
+ ->will( $this->returnValue( HashField::threshold() + 1 ) );
+
+ $this->populateHashField->expects( $this->atLeastOnce() )
+ ->method( 'setComplete' );
+
+ $this->populateHashField->expects( $this->once() )
+ ->method( 'fetchRows' )
+ ->will( $this->returnValue( $resultWrapper ) );
+
+ $instance = new HashField(
+ $this->store,
+ $this->populateHashField
+ );
+
+ $instance->setMessageReporter( $this->spyMessageReporter );
+ $instance->check();
+
+ $this->assertContains(
+ 'Checking smw_hash field consistency',
+ $this->spyMessageReporter->getMessagesAsString()
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/MySQLTableBuilderTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/MySQLTableBuilderTest.php
index 638b7de8..4babb85b 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/MySQLTableBuilderTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/MySQLTableBuilderTest.php
@@ -16,24 +16,42 @@ use SMW\SQLStore\TableBuilder\Table;
*/
class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
- public function testCanConstruct() {
+ private $connection;
- $connection = $this->getMockBuilder( '\DatabaseBase' )
+ protected function setUp() {
+
+ $this->connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
+ ->setMethods( [ 'tableExists', 'query', 'dbSchema', 'tablePrefix' ] )
->getMockForAbstractClass();
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->any() )
->method( 'getType' )
->will( $this->returnValue( 'mysql' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'dbSchema' )
+ ->will( $this->returnValue( '' ) );
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tablePrefix' )
+ ->will( $this->returnValue( '' ) );
+ }
+
+ public function testCanConstruct() {
+
$this->assertInstanceOf(
MySQLTableBuilder::class,
- MySQLTableBuilder::factory( $connection )
+ MySQLTableBuilder::factory( $this->connection )
);
}
public function testCreateNewTable() {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
$connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
->setMethods( [ 'tableExists', 'query' ] )
@@ -49,10 +67,34 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
$connection->expects( $this->once() )
->method( 'query' )
- ->with( $this->stringContains( 'CREATE TABLE `xyz`."foo"' ) );
+ ->with( $this->equalTo( 'CREATE TABLE `xyz`."foo" (bar TEXT) tableoptions_foobar' ) );
$instance = MySQLTableBuilder::factory( $connection );
$instance->addConfig( 'wgDBname', 'xyz' );
+ $instance->addConfig( 'wgDBTableOptions', 'tableoptions_foobar' );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+
+ $instance->create( $table );
+ }
+
+ public function testCreateNewTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'CREATE TABLE `xyz`."foo"' ) );
+
+ $instance = MySQLTableBuilder::factory( $this->connection );
+ $instance->addConfig( 'wgDBname', 'xyz' );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -62,6 +104,10 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testUpdateExistingTableWithNewField() {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
$connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
->setMethods( [ 'tableExists', 'query' ] )
@@ -92,8 +138,39 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
$instance->create( $table );
}
+ public function testUpdateExistingTableWithNewField_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
+
+ $this->connection->expects( $this->at( 4 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'DESCRIBE' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 5 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD `bar` text FIRST' ) );
+
+ $instance = MySQLTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+
+ $instance->create( $table );
+ }
+
public function testUpdateExistingTableWithNewFieldAndDefault() {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
$connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
->setMethods( [ 'tableExists', 'query' ] )
@@ -125,8 +202,40 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
$instance->create( $table );
}
+ public function testUpdateExistingTableWithNewFieldAndDefault_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
+
+ $this->connection->expects( $this->at( 4 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'DESCRIBE' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 5 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD `bar` text' . " DEFAULT '0'" . ' FIRST' ) );
+
+ $instance = MySQLTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+ $table->addDefault( 'bar', 0 );
+
+ $instance->create( $table );
+ }
+
public function testCreateIndex() {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
$connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
->setMethods( [ 'tableExists', 'query' ] )
@@ -158,8 +267,40 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
$instance->create( $table );
}
+ public function testCreateIndex_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->at( 7 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'SHOW INDEX' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 10 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD INDEX (bar)' ) );
+
+ $instance = MySQLTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+ $table->addIndex( 'bar' );
+
+ $instance->create( $table );
+ }
+
public function testDropTable() {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
$connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
->setMethods( [ 'tableExists', 'query' ] )
@@ -183,8 +324,32 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
$instance->drop( $table );
}
+ public function testDropTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->once() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
+
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'DROP TABLE "foo"' ) );
+
+ $instance = MySQLTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $instance->drop( $table );
+ }
+
public function testOptimizeTable() {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
$connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
->setMethods( [ 'query' ] )
@@ -208,4 +373,24 @@ class MySQLTableBuilderTest extends \PHPUnit_Framework_TestCase {
$instance->optimize( $table );
}
+ public function testOptimizeTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ANALYZE TABLE "foo"' ) );
+
+ $this->connection->expects( $this->at( 6 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'OPTIMIZE TABLE "foo"' ) );
+
+ $instance = MySQLTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $instance->optimize( $table );
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/PostgresTableBuilderTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/PostgresTableBuilderTest.php
index 7dd73660..9211a2d3 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/PostgresTableBuilderTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/PostgresTableBuilderTest.php
@@ -16,42 +16,73 @@ use SMW\SQLStore\TableBuilder\Table;
*/
class PostgresTableBuilderTest extends \PHPUnit_Framework_TestCase {
- public function testCanConstruct() {
+ private $connection;
+
+ protected function setUp() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
+ $this->connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
+ ->setMethods( [ 'tableExists', 'query', 'dbSchema', 'tablePrefix', 'onTransactionIdle' ] )
->getMockForAbstractClass();
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->any() )
->method( 'getType' )
->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'dbSchema' )
+ ->will( $this->returnValue( '' ) );
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tablePrefix' )
+ ->will( $this->returnValue( '' ) );
+ }
+
+ public function testCanConstruct() {
+
$this->assertInstanceOf(
PostgresTableBuilder::class,
- PostgresTableBuilder::factory( $connection )
+ PostgresTableBuilder::factory( $this->connection )
);
}
public function testCreateTableOnNewTable() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'CREATE TABLE' ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+
+ $instance->create( $table );
+ }
- $connection->expects( $this->any() )
+ public function testCreateTableOnNewTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( false ) );
- $connection->expects( $this->once() )
+ $this->connection->expects( $this->once() )
->method( 'query' )
->with( $this->stringContains( 'CREATE TABLE' ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -61,29 +92,51 @@ class PostgresTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testUpdateTableWithNewField() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->at( 2 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'SELECT a.attname as' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD "bar" TEXT' ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+
+ $instance->create( $table );
+ }
+
+ public function testUpdateTableWithNewField_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( true ) );
- $connection->expects( $this->at( 2 ) )
+ $this->connection->expects( $this->at( 4 ) )
->method( 'query' )
->with( $this->stringContains( 'SELECT a.attname as' ) )
->will( $this->returnValue( [] ) );
- $connection->expects( $this->at( 3 ) )
+ $this->connection->expects( $this->at( 5 ) )
->method( 'query' )
->with( $this->stringContains( 'ALTER TABLE "foo" ADD "bar" TEXT' ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -93,29 +146,52 @@ class PostgresTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testUpdateTableWithNewFieldAndDefault() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->at( 2 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'SELECT a.attname as' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD "bar" TEXT'. " DEFAULT '0'" ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+ $table->addDefault( 'bar', 0 );
+
+ $instance->create( $table );
+ }
+
+ public function testUpdateTableWithNewFieldAndDefault_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( true ) );
- $connection->expects( $this->at( 2 ) )
+ $this->connection->expects( $this->at( 4 ) )
->method( 'query' )
->with( $this->stringContains( 'SELECT a.attname as' ) )
->will( $this->returnValue( [] ) );
- $connection->expects( $this->at( 3 ) )
+ $this->connection->expects( $this->at( 5 ) )
->method( 'query' )
->with( $this->stringContains( 'ALTER TABLE "foo" ADD "bar" TEXT'. " DEFAULT '0'" ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -126,33 +202,60 @@ class PostgresTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testCreateIndex() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query', 'indexInfo' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->any() )
+ ->method( 'indexInfo' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'SELECT i.relname AS indexname' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 5 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'CREATE INDEX foo_idx_bar ON foo (bar)' ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+ $table->addIndex( 'bar' );
+
+ $instance->create( $table );
+ }
- $connection->expects( $this->any() )
+ public function testCreateIndex_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( false ) );
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->any() )
->method( 'indexInfo' )
->will( $this->returnValue( false ) );
- $connection->expects( $this->at( 3 ) )
+ $this->connection->expects( $this->at( 7 ) )
->method( 'query' )
->with( $this->stringContains( 'SELECT i.relname AS indexname' ) )
->will( $this->returnValue( [] ) );
- $connection->expects( $this->at( 5 ) )
+ $this->connection->expects( $this->at( 11 ) )
->method( 'query' )
->with( $this->stringContains( 'CREATE INDEX foo_idx_bar ON foo (bar)' ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -163,24 +266,39 @@ class PostgresTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testDropTable() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->once() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
- $connection->expects( $this->once() )
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'DROP TABLE IF EXISTS "foo"' ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $instance->drop( $table );
+ }
+
+ public function testDropTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->once() )
->method( 'tableExists' )
->will( $this->returnValue( true ) );
- $connection->expects( $this->once() )
+ $this->connection->expects( $this->once() )
->method( 'query' )
->with( $this->stringContains( 'DROP TABLE IF EXISTS "foo"' ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$instance->drop( $table );
@@ -188,44 +306,77 @@ class PostgresTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testDoCheckOnAfterCreate() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'query', 'getType', 'onTransactionIdle' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'postgres' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'onTransactionIdle' )
+ ->will( $this->returnCallback( function( $callback ) { return $callback(); } ) );
+
+ $this->connection->expects( $this->at( 4 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER SEQUENCE' ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $instance->checkOn( $instance::POST_CREATION );
+ }
- $connection->expects( $this->any() )
+ public function testDoCheckOnAfterCreate_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'onTransactionIdle' )
->will( $this->returnCallback( function( $callback ) { return $callback(); } ) );
- $connection->expects( $this->at( 4 ) )
+ $this->connection->expects( $this->at( 6 ) )
->method( 'query' )
->with( $this->stringContains( 'ALTER SEQUENCE' ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$instance->checkOn( $instance::POST_CREATION );
}
public function testOptimizeTable() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
+ ->method( 'getType' )
+ ->will( $this->returnValue( 'postgres' ) );
+
+ $this->connection->expects( $this->at( 1 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ANALYZE "foo"' ) );
+
+ $instance = PostgresTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $instance->optimize( $table );
+ }
+
+ public function testOptimizeTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->any() )
->method( 'getType' )
->will( $this->returnValue( 'postgres' ) );
- $connection->expects( $this->at( 1 ) )
+ $this->connection->expects( $this->at( 3 ) )
->method( 'query' )
->with( $this->stringContains( 'ANALYZE "foo"' ) );
- $instance = PostgresTableBuilder::factory( $connection );
+ $instance = PostgresTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$instance->optimize( $table );
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/SQLiteTableBuilderTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/SQLiteTableBuilderTest.php
index cdabc327..05d31825 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/SQLiteTableBuilderTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableBuilder/SQLiteTableBuilderTest.php
@@ -16,42 +16,73 @@ use SMW\SQLStore\TableBuilder\Table;
*/
class SQLiteTableBuilderTest extends \PHPUnit_Framework_TestCase {
- public function testCanConstruct() {
+ private $connection;
+
+ protected function setUp() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
+ $this->connection = $this->getMockBuilder( '\DatabaseBase' )
->disableOriginalConstructor()
+ ->setMethods( [ 'tableExists', 'query', 'dbSchema', 'tablePrefix' ] )
->getMockForAbstractClass();
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->any() )
->method( 'getType' )
->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'dbSchema' )
+ ->will( $this->returnValue( '' ) );
+
+ $this->connection->expects( $this->any() )
+ ->method( 'tablePrefix' )
+ ->will( $this->returnValue( '' ) );
+ }
+
+ public function testCanConstruct() {
+
$this->assertInstanceOf(
SQLiteTableBuilder::class,
- SQLiteTableBuilder::factory( $connection )
+ SQLiteTableBuilder::factory( $this->connection )
);
}
public function testCreateTableOnNewTable() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'CREATE TABLE' ) );
- $connection->expects( $this->any() )
+ $instance = SQLiteTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+
+ $instance->create( $table );
+ }
+
+ public function testCreateTableOnNewTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( false ) );
- $connection->expects( $this->once() )
+ $this->connection->expects( $this->once() )
->method( 'query' )
->with( $this->stringContains( 'CREATE TABLE' ) );
- $instance = SQLiteTableBuilder::factory( $connection );
+ $instance = SQLiteTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -61,29 +92,51 @@ class SQLiteTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testUpdateTableWithNewField() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
- $connection->expects( $this->any() )
+ $this->connection->expects( $this->at( 2 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'PRAGMA table_info("foo")' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD `bar` text' ) );
+
+ $instance = SQLiteTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+
+ $instance->create( $table );
+ }
+
+ public function testUpdateTableWithNewField_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( true ) );
- $connection->expects( $this->at( 2 ) )
+ $this->connection->expects( $this->at( 4 ) )
->method( 'query' )
->with( $this->stringContains( 'PRAGMA table_info("foo")' ) )
->will( $this->returnValue( [] ) );
- $connection->expects( $this->at( 3 ) )
+ $this->connection->expects( $this->at( 5 ) )
->method( 'query' )
->with( $this->stringContains( 'ALTER TABLE "foo" ADD `bar` text' ) );
- $instance = SQLiteTableBuilder::factory( $connection );
+ $instance = SQLiteTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -93,29 +146,52 @@ class SQLiteTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testUpdateTableWithNewFieldAndDefault() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
+
+ $this->connection->expects( $this->at( 2 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'PRAGMA table_info("foo")' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ALTER TABLE "foo" ADD `bar` text' . " DEFAULT '0'" ) );
+
+ $instance = SQLiteTableBuilder::factory( $this->connection );
- $connection->expects( $this->any() )
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+ $table->addDefault( 'bar', 0 );
+
+ $instance->create( $table );
+ }
+
+ public function testUpdateTableWithNewFieldAndDefault_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( true ) );
- $connection->expects( $this->at( 2 ) )
+ $this->connection->expects( $this->at( 4 ) )
->method( 'query' )
->with( $this->stringContains( 'PRAGMA table_info("foo")' ) )
->will( $this->returnValue( [] ) );
- $connection->expects( $this->at( 3 ) )
+ $this->connection->expects( $this->at( 5 ) )
->method( 'query' )
->with( $this->stringContains( 'ALTER TABLE "foo" ADD `bar` text' . " DEFAULT '0'" ) );
- $instance = SQLiteTableBuilder::factory( $connection );
+ $instance = SQLiteTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -126,29 +202,52 @@ class SQLiteTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testCreateIndex() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->any() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( false ) );
+
+ $this->connection->expects( $this->at( 3 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'PRAGMA index_list("foo")' ) )
+ ->will( $this->returnValue( [] ) );
+
+ $this->connection->expects( $this->at( 4 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'CREATE INDEX "foo"_index0' ) );
+
+ $instance = SQLiteTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $table->addColumn( 'bar', 'text' );
+ $table->addIndex( 'bar' );
+
+ $instance->create( $table );
+ }
+
+ public function testCreateIndex_132() {
- $connection->expects( $this->any() )
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->any() )
->method( 'tableExists' )
->will( $this->returnValue( false ) );
- $connection->expects( $this->at( 3 ) )
+ $this->connection->expects( $this->at( 7 ) )
->method( 'query' )
->with( $this->stringContains( 'PRAGMA index_list("foo")' ) )
->will( $this->returnValue( [] ) );
- $connection->expects( $this->at( 4 ) )
+ $this->connection->expects( $this->at( 10 ) )
->method( 'query' )
->with( $this->stringContains( 'CREATE INDEX "foo"_index0' ) );
- $instance = SQLiteTableBuilder::factory( $connection );
+ $instance = SQLiteTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$table->addColumn( 'bar', 'text' );
@@ -159,24 +258,39 @@ class SQLiteTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testDropTable() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'tableExists', 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->once() )
+ ->method( 'tableExists' )
+ ->will( $this->returnValue( true ) );
+
+ $this->connection->expects( $this->once() )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'DROP TABLE "foo"' ) );
+
+ $instance = SQLiteTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $instance->drop( $table );
+ }
- $connection->expects( $this->once() )
+ public function testDropTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
+
+ $this->connection->expects( $this->once() )
->method( 'tableExists' )
->will( $this->returnValue( true ) );
- $connection->expects( $this->once() )
+ $this->connection->expects( $this->once() )
->method( 'query' )
->with( $this->stringContains( 'DROP TABLE "foo"' ) );
- $instance = SQLiteTableBuilder::factory( $connection );
+ $instance = SQLiteTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$instance->drop( $table );
@@ -184,20 +298,31 @@ class SQLiteTableBuilderTest extends \PHPUnit_Framework_TestCase {
public function testOptimizeTable() {
- $connection = $this->getMockBuilder( '\DatabaseBase' )
- ->disableOriginalConstructor()
- ->setMethods( [ 'query' ] )
- ->getMockForAbstractClass();
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '>=' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->any() )
- ->method( 'getType' )
- ->will( $this->returnValue( 'sqlite' ) );
+ $this->connection->expects( $this->at( 1 ) )
+ ->method( 'query' )
+ ->with( $this->stringContains( 'ANALYZE "foo"' ) );
+
+ $instance = SQLiteTableBuilder::factory( $this->connection );
+
+ $table = new Table( 'foo' );
+ $instance->optimize( $table );
+ }
+
+ public function testOptimizeTable_132() {
+
+ if ( version_compare( $GLOBALS['wgVersion'], '1.32', '<' ) ) {
+ $this->markTestSkipped( 'MediaWiki changed the Database signature!' );
+ }
- $connection->expects( $this->at( 1 ) )
+ $this->connection->expects( $this->at( 3 ) )
->method( 'query' )
->with( $this->stringContains( 'ANALYZE "foo"' ) );
- $instance = SQLiteTableBuilder::factory( $connection );
+ $instance = SQLiteTableBuilder::factory( $this->connection );
$table = new Table( 'foo' );
$instance->optimize( $table );
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableIntegrityExaminerTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableIntegrityExaminerTest.php
index d37d8fd6..1c9b561f 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableIntegrityExaminerTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/SQLStore/TableIntegrityExaminerTest.php
@@ -2,7 +2,7 @@
namespace SMW\Tests\SQLStore;
-use Onoi\MessageReporter\MessageReporterFactory;
+use SMW\Tests\TestEnvironment;
use SMW\SQLStore\TableIntegrityExaminer;
/**
@@ -17,21 +17,27 @@ use SMW\SQLStore\TableIntegrityExaminer;
class TableIntegrityExaminerTest extends \PHPUnit_Framework_TestCase {
private $spyMessageReporter;
+ private $hashField;
+ private $store;
protected function setUp() {
parent::setUp();
- $this->spyMessageReporter = MessageReporterFactory::getInstance()->newSpyMessageReporter();
- }
+ $this->spyMessageReporter = TestEnvironment::getUtilityFactory()->newSpyMessageReporter();
- public function testCanConstruct() {
+ $this->hashField = $this->getMockBuilder( '\SMW\SQLStore\TableBuilder\Examiner\HashField' )
+ ->disableOriginalConstructor()
+ ->getMock();
- $store = $this->getMockBuilder( '\SMW\SQLStore\SQLStore' )
+ $this->store = $this->getMockBuilder( '\SMW\SQLStore\SQLStore' )
->disableOriginalConstructor()
->getMock();
+ }
+
+ public function testCanConstruct() {
$this->assertInstanceOf(
- '\SMW\SQLStore\TableIntegrityExaminer',
- new TableIntegrityExaminer( $store )
+ TableIntegrityExaminer::class,
+ new TableIntegrityExaminer( $this->store, $this->hashField )
);
}
@@ -84,7 +90,8 @@ class TableIntegrityExaminerTest extends \PHPUnit_Framework_TestCase {
->method( 'checkOn' );
$instance = new TableIntegrityExaminer(
- $store
+ $store,
+ $this->hashField
);
$instance->setPredefinedPropertyList( [
@@ -152,7 +159,8 @@ class TableIntegrityExaminerTest extends \PHPUnit_Framework_TestCase {
->method( 'checkOn' );
$instance = new TableIntegrityExaminer(
- $store
+ $store,
+ $this->hashField
);
$instance->setPredefinedPropertyList( [
@@ -204,7 +212,8 @@ class TableIntegrityExaminerTest extends \PHPUnit_Framework_TestCase {
->method( 'checkOn' );
$instance = new TableIntegrityExaminer(
- $store
+ $store,
+ $this->hashField
);
$instance->setPredefinedPropertyList( [
@@ -263,7 +272,8 @@ class TableIntegrityExaminerTest extends \PHPUnit_Framework_TestCase {
->method( 'checkOn' );
$instance = new TableIntegrityExaminer(
- $store
+ $store,
+ $this->hashField
);
$instance->setPredefinedPropertyList( [] );
@@ -308,7 +318,8 @@ class TableIntegrityExaminerTest extends \PHPUnit_Framework_TestCase {
->method( 'drop' );
$instance = new TableIntegrityExaminer(
- $store
+ $store,
+ $this->hashField
);
$instance->setMessageReporter( $this->spyMessageReporter );
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/CsvTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/CsvTest.php
index 67514d87..92c9ce8b 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/CsvTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/CsvTest.php
@@ -198,6 +198,30 @@ class CsvTest extends \PHPUnit_Framework_TestCase {
true,
"sep=,\nH1,H2,H3,H4\nFoo,1,2,3\nBar,1,2,3\n"
];
+
+ // fputcsv ... delimiter must be a single character
+ yield [
+ [],
+ [
+ [ 'Foo', '1', '2', '3' ],
+ [ 'Bar', '1', '2', '3' ],
+ ],
+ ',..;',
+ false,
+ "Foo,1,2,3\nBar,1,2,3\n"
+ ];
+
+ // fputcsv ... delimiter must be a single character
+ yield [
+ [],
+ [
+ [ 'Foo', '1', '2', '3' ],
+ [ 'Bar', '1', '2', '3' ],
+ ],
+ '',
+ false,
+ "Foo,1,2,3\nBar,1,2,3\n"
+ ];
}
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/FileTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/FileTest.php
index dd74300b..636ba0a0 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/FileTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Unit/Utils/FileTest.php
@@ -3,6 +3,7 @@
namespace SMW\Tests\Utils;
use SMW\Utils\File;
+use SMW\Tests\PHPUnitCompat;
/**
* @covers \SMW\Utils\File
@@ -15,6 +16,8 @@ use SMW\Utils\File;
*/
class FileTest extends \PHPUnit_Framework_TestCase {
+ use PHPUnitCompat;
+
public function testCanConstruct() {
$instance = new File();
@@ -25,4 +28,20 @@ class FileTest extends \PHPUnit_Framework_TestCase {
);
}
+ public function testWrite_ThrowsException() {
+
+ $instance = new File();
+
+ $this->setExpectedException( '\SMW\Exception\FileNotWritableException' );
+ $instance->write( 'abc/Foo', '' );
+ }
+
+ public function testDir() {
+
+ $this->assertInternalType(
+ 'string',
+ File::dir( 'foo' )
+ );
+ }
+
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Utils/Validators/SemanticDataValidator.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Utils/Validators/SemanticDataValidator.php
index 84673a1b..8eec37b2 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Utils/Validators/SemanticDataValidator.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/Utils/Validators/SemanticDataValidator.php
@@ -416,7 +416,7 @@ class SemanticDataValidator extends \PHPUnit_Framework_Assert {
continue;
}
- if ( strpos( $propertyValue, $value ) !== false ) {
+ if ( strpos( $propertyValue, (string)$value ) !== false ) {
unset( $expected['propertyValues'][$key] );
continue;
}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/DataValues/WikiPageValueTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/DataValues/WikiPageValueTest.php
new file mode 100644
index 00000000..953c2a23
--- /dev/null
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/DataValues/WikiPageValueTest.php
@@ -0,0 +1,68 @@
+<?php
+
+namespace SMW\Tests\DataValues;
+
+use SMW\DataItemFactory;
+use SMW\Tests\TestEnvironment;
+use SMWWikiPageValue as WikiPageValue;
+
+/**
+ * @covers \SMWWikiPageValue
+ * @group semantic-mediawiki
+ *
+ * @license GNU GPL v2+
+ * @since 3.1
+ *
+ * @author mwjames
+ */
+class WikiPageValueTest extends \PHPUnit_Framework_TestCase {
+
+ private $testEnvironment;
+ private $dataItemFactory;
+
+ protected function setUp() {
+ parent::setUp();
+
+ $this->testEnvironment = new TestEnvironment();
+ $this->dataItemFactory = new DataItemFactory();
+
+ $this->propertySpecificationLookup = $this->getMockBuilder( '\SMW\PropertySpecificationLookup' )
+ ->disableOriginalConstructor()
+ ->getMock();
+
+ $this->testEnvironment->registerObject( 'PropertySpecificationLookup', $this->propertySpecificationLookup );
+ }
+
+ protected function tearDown() {
+ $this->testEnvironment->tearDown();
+ parent::tearDown();
+ }
+
+ public function testCanConstruct() {
+
+ $this->assertInstanceOf(
+ WikiPageValue::class,
+ new WikiPageValue( '' )
+ );
+ }
+
+ public function testDisableInfolinksOnSpecialUsernamePrefix() {
+
+ $instance = new WikiPageValue( '_wpg' );
+
+ $this->assertFalse(
+ $instance->getOption( WikiPageValue::OPT_DISABLE_INFOLINKS )
+ );
+
+ $instance->setDataItem(
+ $this->dataItemFactory->newDIWikiPage( '>Foo', NS_USER )
+ );
+
+ $instance->getTitle();
+
+ $this->assertTrue(
+ $instance->getOption( WikiPageValue::OPT_DISABLE_INFOLINKS )
+ );
+ }
+
+}
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/InfolinkTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/InfolinkTest.php
index 98f23bc2..6a47317a 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/InfolinkTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/InfolinkTest.php
@@ -86,6 +86,8 @@ class InfolinkTest extends \PHPUnit_Framework_TestCase {
$instance = new Infolink( true, 'Foo', 'Bar/Foobar' );
+ $instance->setCompactLink( true );
+
$this->assertContains(
'/Bar/Foobar',
$instance->getLocalURL()
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/RecurringEventsTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/RecurringEventsTest.php
index 0fbd1f91..70f3dd7b 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/RecurringEventsTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/RecurringEventsTest.php
@@ -16,25 +16,11 @@ use SMW\RecurringEvents;
*/
class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
- /**
- * @return RecurringEvents
- */
- private function newInstance( array $params ) {
-
- $parameters = new ParserParameterFormatter( $params );
-
- $instance = new RecurringEvents( $parameters->toArray() );
- $instance->setDefaultNumRecurringEvents( 10 );
- $instance->setMaxNumRecurringEvents( 50 );
-
- return $instance;
- }
-
public function testCanConstruct() {
$this->assertInstanceOf(
- '\SMW\RecurringEvents',
- new RecurringEvents( [] )
+ RecurringEvents::class,
+ new RecurringEvents()
);
}
@@ -44,7 +30,15 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
* @since 1.9
*/
public function testGetErrors( array $params, array $expected ) {
- $this->assertCount( $expected['errors'], $this->newInstance( $params )->getErrors() );
+
+ $parameters = new ParserParameterFormatter( $params );
+
+ $instance = new RecurringEvents();
+ $instance->parse( $parameters->toArray() );
+
+ $this->assertCount(
+ $expected['errors'],
+ $instance->getErrors() );
}
/**
@@ -53,7 +47,16 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
* @since 1.9
*/
public function testGetProperty( array $params, array $expected ) {
- $this->assertEquals( $expected['property'], $this->newInstance( $params )->getProperty() );
+
+ $parameters = new ParserParameterFormatter( $params );
+
+ $instance = new RecurringEvents();
+ $instance->parse( $parameters->toArray() );
+
+ $this->assertEquals(
+ $expected['property'],
+ $instance->getProperty()
+ );
}
/**
@@ -62,7 +65,16 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
* @since 1.9
*/
public function testGetParameters( array $params, array $expected ) {
- $this->assertEquals( $expected['parameters'], $this->newInstance( $params )->getParameters() );
+
+ $parameters = new ParserParameterFormatter( $params );
+
+ $instance = new RecurringEvents();
+ $instance->parse( $parameters->toArray() );
+
+ $this->assertEquals(
+ $expected['parameters'],
+ $instance->getParameters()
+ );
}
/**
@@ -71,7 +83,16 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
* @since 1.9
*/
public function testGetDates( array $params, array $expected ) {
- $this->assertEquals( $expected['dates'], $this->newInstance( $params )->getDates() );
+
+ $parameters = new ParserParameterFormatter( $params );
+
+ $instance = new RecurringEvents();
+ $instance->parse( $parameters->toArray() );
+
+ $this->assertEquals(
+ $expected['dates'],
+ $instance->getDates()
+ );
}
/**
@@ -103,7 +124,16 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
* @since 1.
*/
public function testMassInsert( array $params, array $expected ) {
- $this->assertCount( $expected['count'], $this->newInstance( $params )->getDates() );
+
+ $parameters = new ParserParameterFormatter( $params );
+
+ $instance = new RecurringEvents();
+ $instance->parse( $parameters->toArray() );
+
+ $this->assertCount(
+ $expected['count'],
+ $instance->getDates()
+ );
}
/**
@@ -112,7 +142,8 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
* @since 1.9
*/
public function testGetJulianDay() {
- $instance = $this->newInstance( [] );
+ $instance = new RecurringEvents();
+ $instance->parse( [] );
// SMWDIWikiPage stub object
$dataValue = $this->getMockBuilder( 'SMWTimeValue' )
@@ -123,7 +154,10 @@ class RecurringEventsTest extends \PHPUnit_Framework_TestCase {
->method( 'getDataItem' )
->will( $this->returnValue( null ) );
- $this->assertEquals( null, $instance->getJulianDay( $dataValue ) );
+ $this->assertEquals(
+ null,
+ $instance->getJulianDay( $dataValue )
+ );
}
/**
diff --git a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/SetupTest.php b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/SetupTest.php
index 6c1f396b..d9cf96fc 100644
--- a/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/SetupTest.php
+++ b/www/wiki/extensions/SemanticMediaWiki/tests/phpunit/includes/SetupTest.php
@@ -59,7 +59,8 @@ class SetupTest extends \PHPUnit_Framework_TestCase {
'wgLanguageCode' => 'en',
'wgLang' => $language,
'IP' => 'Foo',
- 'smwgSemanticsEnabled' => true
+ 'smwgSemanticsEnabled' => true,
+ 'smwgConfigFileDir' => ''
];
foreach ( $this->defaultConfig as $key => $value ) {
diff --git a/www/wiki/extensions/SpamBlacklist/Gruntfile.js b/www/wiki/extensions/SpamBlacklist/Gruntfile.js
index 37319b17..3a2f7450 100644
--- a/www/wiki/extensions/SpamBlacklist/Gruntfile.js
+++ b/www/wiki/extensions/SpamBlacklist/Gruntfile.js
@@ -23,7 +23,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/SpamBlacklist/composer.json b/www/wiki/extensions/SpamBlacklist/composer.json
index 021a14cb..b822010c 100644
--- a/www/wiki/extensions/SpamBlacklist/composer.json
+++ b/www/wiki/extensions/SpamBlacklist/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/SpamBlacklist/extension.json b/www/wiki/extensions/SpamBlacklist/extension.json
index d12b0611..f8317b2a 100644
--- a/www/wiki/extensions/SpamBlacklist/extension.json
+++ b/www/wiki/extensions/SpamBlacklist/extension.json
@@ -8,13 +8,12 @@
"url": "https://www.mediawiki.org/wiki/Extension:SpamBlacklist",
"descriptionmsg": "spam-blacklist-desc",
"type": "antispam",
- "license-name": "GPL-2.0+",
- "callback": "SpamBlacklistHooks::registerExtension",
+ "license-name": "GPL-2.0-or-later",
"requires": {
- "MediaWiki": ">= 1.26.0"
+ "MediaWiki": ">= 1.31.0"
},
"GroupPermissions": {
- "sysop": {
+ "user": {
"spamblacklistlog": true
}
},
@@ -44,14 +43,14 @@
]
},
"AutoloadClasses": {
- "ApiSpamBlacklist": "api/ApiSpamBlacklist.php",
- "BaseBlacklist": "BaseBlacklist.php",
- "EmailBlacklist": "EmailBlacklist.php",
- "SpamBlacklistHooks": "SpamBlacklistHooks.php",
- "SpamBlacklist": "SpamBlacklist_body.php",
- "SpamBlacklistLogFormatter": "SpamBlacklistLogFormatter.php",
- "SpamRegexBatch": "SpamRegexBatch.php",
- "SpamBlacklistPreAuthenticationProvider": "SpamBlacklistPreAuthenticationProvider.php"
+ "ApiSpamBlacklist": "includes/ApiSpamBlacklist.php",
+ "BaseBlacklist": "includes/BaseBlacklist.php",
+ "EmailBlacklist": "includes/EmailBlacklist.php",
+ "SpamBlacklistHooks": "includes/SpamBlacklistHooks.php",
+ "SpamBlacklist": "includes/SpamBlacklist.php",
+ "SpamBlacklistLogFormatter": "includes/SpamBlacklistLogFormatter.php",
+ "SpamRegexBatch": "includes/SpamRegexBatch.php",
+ "SpamBlacklistPreAuthenticationProvider": "includes/SpamBlacklistPreAuthenticationProvider.php"
},
"Hooks": {
"EditFilterMergedContent": [
@@ -85,5 +84,12 @@
"LogSpamBlacklistHits": false,
"SpamBlacklistEventLogging": false
},
+ "AuthManagerAutoConfig": {
+ "preauth": {
+ "SpamBlacklistPreAuthenticationProvider": {
+ "class": "SpamBlacklistPreAuthenticationProvider"
+ }
+ }
+ },
"manifest_version": 1
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/ais.json b/www/wiki/extensions/SpamBlacklist/i18n/ais.json
index f0d72517..1f438f85 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/ais.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/ais.json
@@ -5,6 +5,17 @@
"Bunukwiki"
]
},
+ "spam-blacklist": "#<!—amana pisumad tina tusil --> <pre>\n# amahicahica micunus ta kasabelih a hekal URL i tina piazihan tu sulit amalangat.\n# tina piazihan tu sulit silaheciay a subal dada’ i tina Wiki, kahica nu kawaw piazih tu tatenga’ay sacahamin-subal malangat piazihan tu sulit.\n# mahizaay a cudad piazih tu tatenga’ay https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n#\n# kamu-sakilul kese tinaku isasa’ay:\n# * amahicahica nay \"#\" tatebanan nu nisulitan angangan a tusil u buhci tu kamu amin \n# * amahicahica caay inayi’ ku cacan a tusil apakuhica tatungusay pakatineng a zateng sapisasutili’ URL a angangan-kikay kalungangan \n #</pre> <!—amana pisumad tina tusil -->",
+ "spam-whitelist": "#<!—amana pisumad tina tusil --> <pre>\n# amahicahica hekal URL itini piazihan-tu-sulit *caay* amalangat \n# kanahatu macunus tuway i malangatay a piazihan-tu-sulit.\n#\n# kamu-sakilul kese mahiza isasa’ay:\n# * amahicahica nay \"#\" tatebanan nu nisulitan angangan a tusil u buhci tu kamu amin \n# * amahicahica caay inayi’ ku cacan a tusil apakuhica tatungusay pakatineng a zateng sapisasutili’ URL a angangan-kikay kalungangan \n \n#</pre> <!—amana pisumad tina tusil -->",
+ "email-blacklist": "#<!—amana pisumad tina tusil --> <pre>\n# amahicahica pangangan saca patayzaan a imyiyo(Email) puenengan i tina piazihan tu sulit amalangat.\n# tina piazihan tu sulit silaheciay a subal dada’ i tina Wiki, kahica nu kawaw piazih tu tatenga’ay sacahamin-subal malangat piazihan tu sulit.\n# mahizaay a cudad piazih tu tatenga’ay https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n#\n# kamu-sakilul kese tinaku isasa’ay:\n# * amahicahica nay \"#\" tatebanan nu nisulitan angangan a tusil u buhci tu kamu amin\n# * amahicahica caay nayi’ ku cacan a silsil apahica ku tatungusay pakatineng a zateng sapihica sasutili’ imyiyo(Email) puenengan a angangan-kikay kalungangan \n#</pre> <!—amana pisumad tina tusil -->",
+ "email-whitelist": "#<!—amana pisumad tina tusil --> <pre>\n# amahicahica hekal URL itini piazihan-tu-sulit *caay* amalangat \n# kanahatu macunus tuway i malangatay a piazihan-tu-sulit。\n#\n# kamu-sakilul kese mahiza isasa’ay:\n# * amahicahica nay \"#\" tatebanan nu nisulitan angangan a tusil u buhci tu kamu amin \n# * amahicahica caay inayi’ ku cacan a tusil apakuhica tatungusay pakatineng a zateng sapisasutili’ URL a angangan-kikay kalungangan \n \n #</pre> <!—amana pisumad tina tusil --> ",
+ "spam-blacklisted-email": "pasilsil tuway milangat piazihan-tu-sulit a imyiyo(email) puenengan",
+ "spam-blacklisted-email-text": "numisuay imyiyo(email) puenengan ayza mapacumud tu malangat piazihan tu sulit, a mitena’ tunumisu pabahel tu imyiyo (email) pabeli tu zumaay a misaungayay.",
+ "spam-blacklisted-email-signup": "nipabeliay a imyiyo(email) puenengan ayzasa mapasilsil tu malangat piazihan tu sulit,la’cus pisaungay",
+ "spam-invalid-lines": "isasa’ patahtah a langat piazihan-tu-sulit izaw ku{{PLURAL:$1|cacay|yadah}} pisaungay tu la’cusay a tatungusay pakatineng a zateng, kanca misumad kyu kapah misuped tina kasabelih.",
+ "spam-blacklist-desc": "i tatungusay pakatineng a zateng tu palana’an a mitena’ patahtah sakaluk, taneng malangat ku kasabelih labu’ay URL atu pangangan tu misaungayay a Email ngangan nu luma’.",
"log-name-spamblacklist": "patahtah a malangat ku nasulitan",
+ "log-description-spamblacklist": "tina belih nasulit tu sacahamin matatungus patahtah malangat piazihan-tu-sulit a sikawaw.",
+ "logentry-spamblacklist-hit": "{{GENDER:$2|$1}} i $3 mitanam micunus a $4 matatungus patahtah malangat piazihan tu sulit labu’ay kasacacay.",
"right-spamblacklistlog": "ciwsace patahtah malangat nasulitan-nazipa’an"
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/ast.json b/www/wiki/extensions/SpamBlacklist/i18n/ast.json
index 45ad18e6..1b3074b9 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/ast.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/ast.json
@@ -5,7 +5,7 @@
"Xuacu"
]
},
- "spam-blacklist": "#<!-- dexe esta llinia exautamente como ta --> <pre>\n# Les URLs esternes que casen con esta llista bloquiaránse cuando s'amiesten a una páxina.\n# Esta llista afeuta namái a esta wiki; mire tamién la llista negra global.\n# Pa ver la documentación vea https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n#\n# La sintaxis ye ésta:\n# * Tol testu dende un caráuter \"#\" hasta lo cabero la llinia ye un comentariu\n# * Toa llinia non balera ye un fragmentu regex qu'afeuta namái a los sirvidores de les URLs\n\n#</pre> <!-- dexe esta llinia exautamente como ta -->",
+ "spam-blacklist": "#<!-- dexa esta llinia exautamente como ta --> <pre>\n# Les URLs esternes que casen con esta llista bloquiaránse cuando s'amiesten a una páxina.\n# Esta llista afeuta namái a esta wiki; mira tamién la llista negra global.\n# Pa ver la documentación visita https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n#\n# La sintaxis ye ésta:\n# * Tol testu dende un caráuter \"#\" hasta fin de llinia ye un comentariu\n# * Toa llinia non balera ye un fragmentu regex que namái casará colos sirvidores de les URLs\n\n#</pre> <!-- dexa<pre> esta llinia exautamente como ta -->",
"spam-whitelist": " #<!-- dexa esta llinia exautamente como ta --> <pre>\n# Les URLs esternes d'esta llista *nun* se bloquiarán inda si quedaríen bloquiaes\n# por una entrada na llista negra.\n#\n# La sintaxis ye esta:\n# * Tol testu dende un caráuter \"#\" hasta lo cabero la llinia ye un comentariu\n# * Toa llinia non balera ye un fragmentu regex qu'afeuta namái a les URLs especificaes\n #</pre> <!-- dexa esta llinia exautamente como ta -->",
"email-blacklist": " # Los correos que casen con esta llista tendrán torgao rexistrase o unviar corréu.\n # Esta llista afeuta namái a esta wiki; mira tamién la llista negra global.\n # Pa ver la documentación visita https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n #<!-- dexa esta llinia exautamente como ta --> <pre>\n#\n# La sintaxis ye esta:\n# * Tol testu dende un caráuter \"#\" hasta lo cabero la llinia ye un comentariu\n# * Toa llinia non balera ye un fragmentu regex qu'afeuta namái a los sirvidores de corréu\n\n #</pre> <!-- dexa esta llinia exautamente como ta -->",
"email-whitelist": "#<!-- Dexa esta llinia tal y como ta --> <pre>\n# Los correos que casen con esta llista *nun* se bloquiarán, incluío si\n# los hubieren bloquiao entraes de la llista negra.\n#\n #</pre> <!-- Dexa esta llinia tal y como ta -->\n# La sintaxis ye esta:\n# * Tol testu dende un caráuter \"#\" hasta lo cabero la llinia ye un comentariu\n# * Toa llinia non balera ye un fragmentu regex qu'afeuta namái a los sirvidores de corréu",
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/bg.json b/www/wiki/extensions/SpamBlacklist/i18n/bg.json
index 1aa242c4..d29d29b2 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/bg.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/bg.json
@@ -2,10 +2,14 @@
"@metadata": {
"authors": [
"Spiritia",
- "Borislav"
+ "Borislav",
+ "ShockD",
+ "StanProg"
]
},
"spam-invalid-lines": "{{PLURAL:$1|Следният запис|Следните записи}} от черния списък на спама {{PLURAL:$1|е невалиден регулярен израз|са невалидни регулярни изрази}} и трябва да {{PLURAL:$1|бъде коригиран|бъдат коригирани}} преди съхраняване на страницата:",
- "spam-blacklist-desc": "Инструмент за защита от спам, използващ регулярни изрази: [[МедияУики:Spam-blacklist]] и [[МедияУики:Spam-whitelist]]",
- "log-name-spamblacklist": "Дневник на черния списък против спам"
+ "spam-blacklist-desc": "Инструмент за защита от спам, използващ регулярни изрази и позволяващ добавяне в черен списък на страници и имейл адреси, достъпен за регистрирани потребители",
+ "log-name-spamblacklist": "Дневник на черния списък против спам",
+ "log-description-spamblacklist": "Тези събития следят съвпаденията с черния списък против спам.",
+ "logentry-spamblacklist-hit": "{{GENDER:$2|$1}} предизвика съвпадение с черния списък против спам в $3, опитвайки се да добави $4."
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/br.json b/www/wiki/extensions/SpamBlacklist/i18n/br.json
index e4553e6b..8cf336e0 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/br.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/br.json
@@ -1,12 +1,13 @@
{
"@metadata": {
"authors": [
- "Fulup"
+ "Fulup",
+ "Zoranzoki21"
]
},
"spam-blacklist": " # Stanket e vo an URLoù diavaez a glot gant ar roll-mañ ma vezont ouzhpennet en ur bajenn.\n # Ne sell ar roll-mañ nemet ouzh ar wiki-mañ ; sellit ivez ouzh al listenn zu hollek.\n # Aze emañ an titouroù https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n #<!-- leave this line exactly as it is --> <pre>\n#\n# Setu doare an ereadur :\n# * Pep tra adalek un arouezenn \"#\" betek dibenn al linenn zo un evezhiadenn\n# * Kement linenn anc'houllo zo un darnad lavarenn reoliek na gloto nemet gant an ostizien el liammoù gourskrid\n\n #</pre> <!-- lezel al linenn-mañ tre evel m'emañ -->",
"spam-whitelist": " #<!-- lezel al linenn-mañ tre evel m'emañ --> <pre>\n# *Ne vo ket* stanket al liammoù gourskrid a glot gant al listenn-mañ\n# ha pa vijent bet stanket gant monedoù ar listenn zu.\n#\n# Setu an eredur :\n# * Pep tra adalek un arouezenn \"#\" betek dibenn al linenn zo un ev evezhiadenn\n# * Kement linenn anc'houllo zo un darnad skrid poellek na zielfennno nemet an ostizien el liammoù gourskrid\n\n #</pre> <!-- lezel al linenn-mañ tre evel m'emañ -->",
- "email-blacklist": " # Miret e vo ouzh ar chomlec'hioù postel a glot gant ar roll-mañ da enrollañ pe da gas posteloù\n # Ne sell ar roll-mañ nemet ouzh ar wiki-mañ ; sellit ivez ouzh al listenn zu hollek.\n # Aze emañ an titouroù http://www.mediawiki.org/wiki/Extension:SpamBlacklist\n #<!-- lezel al linenn-mañ tre evel m'emañ --> <pre>\n#\n# Setu doare an ereadur :\n# * Kement testenn zo war-lerc'h un arouezenn \"#\" betek dibenn al linenn a vez sellet outi evel un evezhiadenn\n# * Kement linenn n'eo ket goullo zo un tamm eus ul lavarenn reoliek na gloto nemet gant an ostizien el liammoù gourskrid\n\n #</pre> <!-- lezel al linenn-mañ tre evel m'emañ -->",
+ "email-blacklist": " # Miret e vo ouzh ar chomlec'hioù postel a glot gant ar roll-mañ da enrollañ pe da gas posteloù\n # Ne sell ar roll-mañ nemet ouzh ar wiki-mañ ; sellit ivez ouzh al listenn zu hollek.\n # Aze emañ an titouroù https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n #<!-- lezel al linenn-mañ tre evel m'emañ --> <pre>\n#\n# Setu doare an ereadur :\n# * Kement testenn zo war-lerc'h un arouezenn \"#\" betek dibenn al linenn a vez sellet outi evel un evezhiadenn\n# * Kement linenn n'eo ket goullo zo un tamm eus ul lavarenn reoliek na gloto nemet gant an ostizien el liammoù gourskrid\n\n #</pre> <!-- lezel al linenn-mañ tre evel m'emañ -->",
"email-whitelist": " #<!-- lezel al linenn-mañ tre evel m'emañ --> <pre>\n# *Ne vo ket* stanket ar chomlec'hioù postel zo er roll-mañ ha pa oant da vezañ\n# diouzh enmontoù al listenn zu.\n#\n #</pre> <!-- lezel al linenn-mañ tre evel m'emañ -->\n# Setu an ereadur :\n# * Kement tra zo war-lerc'h un arouezenn \"#\" betek dibenn al linenn zo un evezhiadenn\n# * Kement linenn n'eo ket goullo zo un tamm regex (lavarenn reoliek) a vo lakaet a-geñver gant al lodenn \"ostiz\" e diabarzh ar chomlec'hioù postel",
"spam-blacklisted-email": "Chomlec'hioù postel ha listenn zu",
"spam-blacklisted-email-text": "Evit ar mare emañ ho chomlec'h postel war ul listenn zu ha n'haller ket kas posteloù drezañ d'an implijerien all.",
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/de.json b/www/wiki/extensions/SpamBlacklist/i18n/de.json
index f54c244f..fbe56de3 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/de.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/de.json
@@ -7,7 +7,8 @@
"Raimond Spekking",
"S2cchst",
"Umherirrender",
- "Wnme"
+ "Wnme",
+ "Debenben"
]
},
"spam-blacklist": " # Externe URLs, die in dieser Liste enthalten sind, blockieren das Speichern einer Seite.\n # Diese Liste hat nur Auswirkungen auf dieses Wiki. Siehe ggf. auch die globale Blockierliste.\n # Siehe auch https://www.mediawiki.org/wiki/Extension:SpamBlacklist für die Dokumentation dieser Funktion. \n #<!-- Diese Zeile darf nicht verändert werden! --> <pre>\n#\n# Syntax:\n# * Alles ab dem „#“-Zeichen bis zum Ende der Zeile ist ein Kommentar\n# * Jede nicht-leere Zeile ist ein regulärer Ausdruck, der gegen die Host-Namen in den URLs geprüft wird.\n\n #</pre> <!-- Diese Zeile darf nicht verändert werden! -->",
@@ -25,6 +26,7 @@
"right-spamblacklistlog": "Spam-Blacklist-Logbuch ansehen",
"action-spamblacklistlog": "dieses Logbuch einzusehen",
"apihelp-spamblacklist-description": "Überprüft eine oder mehrere URLs gegen die Spam-Blacklist.",
+ "apihelp-spamblacklist-summary": "Überprüft eine oder mehrere URLs gegen die Spam-Blacklist.",
"apihelp-spamblacklist-param-url": "Gegen die Blacklist zu überprüfende URLs.",
"apihelp-spamblacklist-example-1": "Überprüft zwei URLs gegen die Blacklist"
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/el.json b/www/wiki/extensions/SpamBlacklist/i18n/el.json
index 022e0302..72ab32c2 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/el.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/el.json
@@ -2,11 +2,12 @@
"@metadata": {
"authors": [
"Dead3y3",
- "Geraki"
+ "Geraki",
+ "Nikosgranturismogt"
]
},
"spam-blacklist": " # Εξωτερικά URLs που ταιριάζουν σε αυτή τη λίστα θα φραγούν όταν προστίθενται σε μία σελίδα.\n # Αυτή η λίστα επηρεάζει μόνο αυτό το wiki· αναφερθείτε επίσης στην καθολική μαύρη λίστα.\n # Για τεκμηρίωση δείτε τον σύνδεσμο https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n #<!-- leave this line exactly as it is --> <pre>\n#\n# Η σύνταξη είναι ως ακολούθως:\n# * Οτιδήποτε από τον χαρακτήρα «#» μέχρι το τέλος της γραμμής είναι ένα σχόλιο\n# * Οποιαδήποτε μη κενή γραμμή είναι ένα κομμάτι κανονικής έκφρασης το οποίο θα ταιριάξει μόνο hosts\n# μέσα σε URLs\n\n #</pre> <!-- leave this line exactly as it is -->",
"spam-whitelist": " #<!-- leave this line exactly as it is --> <pre>\n# Εξωτερικά URLs που ταιριάζουν σε αυτή τη λίστα _δεν_ θα φραγούν ακόμα και αν είχαν\n# φραγεί από εγγραφές της μαύρης λίστας.\n#\n# Η σύνταξη είναι ως ακολούθως:\n# * Οτιδήποτε από τον χαρακτήρα «#» μέχρι το τέλος της γραμμής είναι ένα σχόλιο\n# * Οποιαδήποτε μη κενή γραμμή είναι ένα κομμάτι κανονικής έκφρασης το οποίο θα ταιριάξει μόνο hosts\n# μέσα σε URLs\n\n #</pre> <!-- leave this line exactly as it is -->",
"spam-invalid-lines": "{{PLURAL:$1|Η ακόλουθη γραμμή|Οι ακόλουθες γραμμές}} της μαύρης λίστας spam είναι {{PLURAL:$1|άκυρη κανονική έκφραση|άκυρες κανονικές εκφράσεις}} και {{PLURAL:$1|χρειάζεται|χρειάζονται}} διόρθωση πριν την αποθήκευση της σελίδας:",
- "spam-blacklist-desc": "Εργαλείο anti-spam βασισμένο σε κανονικές εκφράσεις: [[MediaWiki:Spam-blacklist]] και [[MediaWiki:Spam-whitelist]]"
+ "spam-blacklist-desc": "Εργαλείο anti-spam βασισμένο σε κανονικές εκφράσεις που επιτρέπει την τοποθέτηση διευθύνσεων URL και διευθύνσεων ηλεκτρονικών ταχυδρομείων σε μαύρη λίστα για τους εγγεγραμμένους χρήστες"
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/gl.json b/www/wiki/extensions/SpamBlacklist/i18n/gl.json
index 3cb39a78..d3532d14 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/gl.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/gl.json
@@ -17,7 +17,7 @@
"spam-invalid-lines": "{{PLURAL:$1|A seguinte liña|As seguintes}} da lista negra de spam {{PLURAL:$1|é unha expresión regular inválida|son expresións regulares inválidas}} e {{PLURAL:$1|haina|hainas}} que corrixir antes de gardar a páxina:",
"spam-blacklist-desc": "Ferramenta antispam baseada en expresións regulares que permite incluír enderezos URL e enderezos de correo electrónico nunha lista negra para os usuarios rexistrados",
"log-name-spamblacklist": "Rexistro da lista negra de spam",
- "log-description-spamblacklist": "Este rexistro fai un seguimento das coincidencias coa lista negra de spam.",
+ "log-description-spamblacklist": "Este rexistro fai un seguimento das coincidencias coa lista negra de publicidade.",
"logentry-spamblacklist-hit": "$1 provocou a activación da lista negra de spam en \"$3\" ao intentar engadir $4.",
"right-spamblacklistlog": "Ver o rexistro da lista negra de spam",
"action-spamblacklistlog": "ver o rexistro da lista negra de spam",
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/id.json b/www/wiki/extensions/SpamBlacklist/i18n/id.json
index 7d339490..4c30457e 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/id.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/id.json
@@ -3,7 +3,8 @@
"authors": [
"Farras",
"IvanLanin",
- "Meursault2004"
+ "Meursault2004",
+ "Gombang"
]
},
"spam-blacklist": "\n # URL eksternal yang cocok dengan daftar berikut akan diblokir jika ditambahkan pada suatu halaman.\n # Daftar ini hanya berpengaruh pada wiki ini; rujuklah juga daftar hitam global.\n # Untuk dokumentasi, lihat https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n #<!-- biarkan baris ini seperti adanya --> <pre>\n#\n# Sintaksnya adalah sebagai berikut:\n# * Semua yang diawali dengan karakter \"#\" hingga akhir baris adalah komentar\n# * Semua baris yang tidak kosong adalah fragmen regex yang hanya akan dicocokkan dengan nama host di dalam URL\n\n #</pre> <!-- biarkan baris ini seperti adanya -->",
@@ -11,5 +12,7 @@
"spam-blacklisted-email": "Alamat surel yang masuk daftar hitam",
"spam-blacklisted-email-signup": "Alamat surel yang dimasukkan saat ini sedang tidak boleh digunakan.",
"spam-invalid-lines": "{{PLURAL:$1|Baris|Baris-baris}} daftar hitam spam berikut adalah {{PLURAL:$1|ekspresi|ekspresi}} regular yang tak valid dan {{PLURAL:$1|perlu|perlu}} dikoreksi sebelum disimpan:",
- "spam-blacklist-desc": "Perkakas anti-spam berbasis regex: [[MediaWiki:Spam-blacklist]] dan [[MediaWiki:Spam-whitelist]]"
+ "spam-blacklist-desc": "Perkakas anti-spam berbasis regex: [[MediaWiki:Spam-blacklist]] dan [[MediaWiki:Spam-whitelist]]",
+ "log-name-spamblacklist": "Catatan daftar hitam spam",
+ "right-spamblacklistlog": "Lihat catatan daftar hitam spam"
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/ja.json b/www/wiki/extensions/SpamBlacklist/i18n/ja.json
index 6de822e1..5a9bfd7f 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/ja.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/ja.json
@@ -6,7 +6,8 @@
"JtFuruhata",
"Marine-Blue",
"Shirayuki",
- "Whym"
+ "Whym",
+ "Yusuke1109"
]
},
"spam-blacklist": " #<!-- この行は変更しないでください --> <pre>\n# この一覧に掲載されている外部URLをページに追加すると編集をブロックします。\n# この一覧はこのウィキでのみ有効です。グローバル ブラックリストも参照してください。\n# 利用方法は https://www.mediawiki.org/wiki/Extension:SpamBlacklist/ja をご覧ください。\n#\n# 構文は以下の通りです:\n# * 「#」以降行末まではコメントです\n# * 空でない行は、URLに含まれるホスト名との一致を検出する正規表現です\n\n #</pre> <!-- この行は変更しないでください -->",
@@ -24,6 +25,7 @@
"right-spamblacklistlog": "スパムブラックリストを閲覧",
"action-spamblacklistlog": "スパムブラックリスト記録の閲覧",
"apihelp-spamblacklist-description": "1 件以上の URL についてスパムブラックリストに登録されているか検証します。",
+ "apihelp-spamblacklist-summary": "1件以上の URL についてスパムブラックリストに登録されているか検証します。",
"apihelp-spamblacklist-param-url": "ブラックリストに登録されているか検証する URL です。",
"apihelp-spamblacklist-example-1": "2 件の URL についてブラックリストに登録されているか検証"
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/ko.json b/www/wiki/extensions/SpamBlacklist/i18n/ko.json
index 3a531438..df42c37c 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/ko.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/ko.json
@@ -6,7 +6,9 @@
"Klutzy",
"Kwj2772",
"아라",
- "Ykhwong"
+ "Ykhwong",
+ "Nuevo Paso",
+ "Garam"
]
},
"spam-blacklist": " #<!-- 이 줄은 그대로 두십시오 --> <pre>\n# 이 필터에 해당하는 URL을 문서에 넣을 경우 해당 편집의 저장을 자동으로 막습니다.\n# 이 필터는 여기 위키 내에서만 적용됩니다. 광역 블랙리스트 기능이 있을 경우 해당 목록도 작동합니다.\n# 설명서에 대해서는 https://www.mediawiki.org/wiki/Extension:SpamBlacklist 문서를 참고하세요\n# \n# 문법은 다음과 같습니다:\n# * \"\"#\" 문자에서 줄의 끝까지는 주석입니다\n# * 각 줄은 정규 표현식으로, URL 문장을 검사하는 데에 사용됩니다\n\n #</pre> <!-- 이 줄은 그대로 두십시오 -->",
@@ -20,7 +22,9 @@
"spam-blacklist-desc": "정규 표현식을 사용해 문서에 있는 URL과 등록된 사용자의 이메일 주소를 블랙리스트 처리하여 스팸을 막는 도구",
"log-name-spamblacklist": "스팸 블랙리스트 기록",
"log-description-spamblacklist": "이 사건은 스팸 블랙리스트의 일치를 추적합니다.",
- "logentry-spamblacklist-hit": "{{GENDER:$2|$1}}님이 $4을(를) 추가하려고 했을 때에 $3 문서에 대한 스팸 블랙리스트의 일치가 발생했습니다.",
+ "logentry-spamblacklist-hit": "{{GENDER:$2|$1}} 사용자가 $3 문서에 $4을(를) 추가하려 하자 스팸 블랙리스트의 일치가 일어났습니다.",
"right-spamblacklistlog": "스팸 블랙리스트 기록 보기",
- "action-spamblacklistlog": "스팸 블랙리스트 기록을 볼"
+ "action-spamblacklistlog": "스팸 블랙리스트 기록을 볼",
+ "apihelp-spamblacklist-description": "SpamBlacklist에 대해 하나 이상의 URL의 유효성을 확인합니다.",
+ "apihelp-spamblacklist-summary": "SpamBlacklist에 대해 하나 이상의 URL의 유효성을 확인합니다."
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/pl.json b/www/wiki/extensions/SpamBlacklist/i18n/pl.json
index a981ff13..6d21068f 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/pl.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/pl.json
@@ -7,7 +7,8 @@
"Sp5uhe",
"WTM",
"Peter Bowman",
- "Woytecr"
+ "Woytecr",
+ "Railfail536"
]
},
"spam-blacklist": " #<!-- zostaw tę linię dokładnie tak, jak jest --> <pre>\n# Dodawanie w treści stron linków zewnętrznych pasujących do tej listy będzie blokowane.\n# Lista dotyczy wyłącznie tej wiki; istnieje też globalna czarna lista.\n# Dokumentacja znajduje się na stronie https://www.mediawiki.org/wiki/Extension:SpamBlacklist\n#\n# Składnia jest następująca:\n# * Wszystko od znaku „#” do końca linii jest komentarzem\n# * Każda niepusta linia jest fragmentem wyrażenia regularnego, które będzie dopasowywane jedynie do hostów wewnątrz linków\n\n #</pre> <!-- zostaw tę linię dokładnie tak, jak jest -->",
@@ -25,6 +26,7 @@
"right-spamblacklistlog": "Podgląd rejestru czarnej listy spamu",
"action-spamblacklistlog": "przeglądania rejestru filtru antyspamowego",
"apihelp-spamblacklist-description": "Sprawdź jeden lub wiele URL pod kątem obecności na czarnej liście spamu.",
+ "apihelp-spamblacklist-summary": "Sprawdź jeden lub więcej adresów URL pod kątem obecności na liście spamu.",
"apihelp-spamblacklist-param-url": "URLe do sprawdzenia pod kątem obecności na czarnej liście.",
"apihelp-spamblacklist-example-1": "Sprawdź dwa URL pod kątem obecności na czarnej liście"
}
diff --git a/www/wiki/extensions/SpamBlacklist/i18n/ur.json b/www/wiki/extensions/SpamBlacklist/i18n/ur.json
index e35dbddd..325febcc 100644
--- a/www/wiki/extensions/SpamBlacklist/i18n/ur.json
+++ b/www/wiki/extensions/SpamBlacklist/i18n/ur.json
@@ -4,5 +4,8 @@
"Muhammad Shuaib"
]
},
- "right-spamblacklistlog": "سیاہ فہرست کے نوشتۂ فاضل کاری کا معائنہ"
+ "spam-blacklisted-email": "فہرست سیاہ میں موجود برقی ڈاک پتے",
+ "log-name-spamblacklist": "نوشتہ فاضل کاری برائے فہرست سیاہ",
+ "right-spamblacklistlog": "سیاہ فہرست کے نوشتۂ فاضل کاری کا معائنہ",
+ "action-spamblacklistlog": "سیاہ فہرست کے نوشتۂ فاضل کاری کا معائنہ کرنے"
}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/ApiSpamBlacklist.php b/www/wiki/extensions/SpamBlacklist/includes/ApiSpamBlacklist.php
new file mode 100644
index 00000000..5b91f2bc
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/ApiSpamBlacklist.php
@@ -0,0 +1,72 @@
+<?php
+/**
+ * SpamBlacklist extension API
+ *
+ * Copyright © 2013 Wikimedia Foundation
+ * Based on code by Ian Baker, Victor Vasiliev, Bryan Tong Minh, Roan Kattouw,
+ * Alex Z., and Jackmcbarn
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Query module check a URL against the blacklist
+ *
+ * @ingroup API
+ * @ingroup Extensions
+ */
+class ApiSpamBlacklist extends ApiBase {
+
+ public function execute() {
+ $params = $this->extractRequestParams();
+ $matches = BaseBlacklist::getInstance( 'spam' )->filter( $params['url'], null, true );
+ $res = $this->getResult();
+
+ if ( $matches !== false ) {
+ // this url is blacklisted.
+ $res->addValue( 'spamblacklist', 'result', 'blacklisted' );
+ $res->setIndexedTagName( $matches, 'match' );
+ $res->addValue( 'spamblacklist', 'matches', $matches );
+ } else {
+ // not blacklisted
+ $res->addValue( 'spamblacklist', 'result', 'ok' );
+ }
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'url' => [
+ ApiBase::PARAM_REQUIRED => true,
+ ApiBase::PARAM_ISMULTI => true,
+ ]
+ ];
+ }
+
+ /**
+ * @see ApiBase::getExamplesMessages()
+ * @return array
+ */
+ protected function getExamplesMessages() {
+ return [
+ 'action=spamblacklist&url=http://www.example.com/|http://www.example.org/'
+ => 'apihelp-spamblacklist-example-1',
+ ];
+ }
+
+ public function getHelpUrls() {
+ return [ 'https://www.mediawiki.org/wiki/Extension:SpamBlacklist/API' ];
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/BaseBlacklist.php b/www/wiki/extensions/SpamBlacklist/includes/BaseBlacklist.php
new file mode 100644
index 00000000..add77e79
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/BaseBlacklist.php
@@ -0,0 +1,448 @@
+<?php
+
+/**
+ * Base class for different kinds of blacklists
+ */
+abstract class BaseBlacklist {
+ /**
+ * Array of blacklist sources
+ *
+ * @var array
+ */
+ public $files = [];
+
+ /**
+ * Array containing regexes to test against
+ *
+ * @var bool|array
+ */
+ protected $regexes = false;
+
+ /**
+ * Chance of receiving a warning when the filter is hit
+ *
+ * @var int
+ */
+ public $warningChance = 100;
+
+ /**
+ * @var int
+ */
+ public $warningTime = 600;
+
+ /**
+ * @var int
+ */
+ public $expiryTime = 900;
+
+ /**
+ * Array containing blacklists that extend BaseBlacklist
+ *
+ * @var array
+ */
+ private static $blacklistTypes = [
+ 'spam' => 'SpamBlacklist',
+ 'email' => 'EmailBlacklist',
+ ];
+
+ /**
+ * Array of blacklist instances
+ *
+ * @var array
+ */
+ private static $instances = [];
+
+ /**
+ * Constructor
+ *
+ * @param array $settings
+ */
+ function __construct( $settings = [] ) {
+ foreach ( $settings as $name => $value ) {
+ $this->$name = $value;
+ }
+ }
+
+ /**
+ * @param array $links
+ * @param Title $title
+ * @param bool $preventLog
+ * @return mixed
+ */
+ abstract public function filter( array $links, Title $title, $preventLog = false );
+
+ /**
+ * Adds a blacklist class to the registry
+ *
+ * @param string $type
+ * @param string $class
+ */
+ public static function addBlacklistType( $type, $class ) {
+ self::$blacklistTypes[$type] = $class;
+ }
+
+ /**
+ * Return the array of blacklist types currently defined
+ *
+ * @return array
+ */
+ public static function getBlacklistTypes() {
+ return self::$blacklistTypes;
+ }
+
+ /**
+ * @return SpamBlacklist
+ */
+ public static function getSpamBlacklist() {
+ return self::getInstance( 'spam' );
+ }
+
+ /**
+ * @return EmailBlacklist
+ */
+ public static function getEmailBlacklist() {
+ return self::getInstance( 'email' );
+ }
+
+ /**
+ * Returns an instance of the given blacklist
+ *
+ * @deprecated Use getSpamBlacklist() or getEmailBlacklist() instead
+ * @param string $type Code for the blacklist
+ * @return BaseBlacklist
+ * @throws Exception
+ */
+ public static function getInstance( $type ) {
+ if ( !isset( self::$blacklistTypes[$type] ) ) {
+ throw new Exception( "Invalid blacklist type '$type' passed to " . __METHOD__ );
+ }
+
+ if ( !isset( self::$instances[$type] ) ) {
+ global $wgBlacklistSettings;
+
+ // Prevent notices
+ if ( !isset( $wgBlacklistSettings[$type] ) ) {
+ $wgBlacklistSettings[$type] = [];
+ }
+
+ $class = self::$blacklistTypes[$type];
+ self::$instances[$type] = new $class( $wgBlacklistSettings[$type] );
+ }
+
+ return self::$instances[$type];
+ }
+
+ /**
+ * Returns the code for the blacklist implementation
+ *
+ * @return string
+ */
+ abstract protected function getBlacklistType();
+
+ /**
+ * Check if the given local page title is a spam regex source.
+ *
+ * @param Title $title
+ * @return bool
+ */
+ public static function isLocalSource( Title $title ) {
+ global $wgDBname, $wgBlacklistSettings;
+
+ if ( $title->getNamespace() == NS_MEDIAWIKI ) {
+ $sources = [];
+ foreach ( self::$blacklistTypes as $type => $class ) {
+ $type = ucfirst( $type );
+ $sources += [
+ "$type-blacklist",
+ "$type-whitelist"
+ ];
+ }
+
+ if ( in_array( $title->getDBkey(), $sources ) ) {
+ return true;
+ }
+ }
+
+ $thisHttp = wfExpandUrl( $title->getFullUrl( 'action=raw' ), PROTO_HTTP );
+ $thisHttpRegex = '/^' . preg_quote( $thisHttp, '/' ) . '(?:&.*)?$/';
+
+ $files = [];
+ foreach ( self::$blacklistTypes as $type => $class ) {
+ if ( isset( $wgBlacklistSettings[$type]['files'] ) ) {
+ $files += $wgBlacklistSettings[$type]['files'];
+ }
+ }
+
+ foreach ( $files as $fileName ) {
+ $matches = [];
+ if ( preg_match( '/^DB: (\w*) (.*)$/', $fileName, $matches ) ) {
+ if ( $wgDBname == $matches[1] ) {
+ if ( $matches[2] == $title->getPrefixedDbKey() ) {
+ // Local DB fetch of this page...
+ return true;
+ }
+ }
+ } elseif ( preg_match( $thisHttpRegex, $fileName ) ) {
+ // Raw view of this page
+ return true;
+ }
+ }
+
+ return false;
+ }
+
+ /**
+ * Returns the type of blacklist from the given title
+ *
+ * @todo building a regex for this is pretty overkill
+ * @param Title $title
+ * @return bool|string
+ */
+ public static function getTypeFromTitle( Title $title ) {
+ global $wgContLang;
+
+ $types = array_map( [ $wgContLang, 'ucfirst' ], array_keys( self::$blacklistTypes ) );
+ $regex = '/(' . implode( '|', $types ). ')-(?:blacklist|whitelist)/';
+
+ if ( preg_match( $regex, $title->getDBkey(), $m ) ) {
+ return strtolower( $m[1] );
+ }
+
+ return false;
+ }
+
+ /**
+ * Fetch local and (possibly cached) remote blacklists.
+ * Will be cached locally across multiple invocations.
+ * @return array set of regular expressions, potentially empty.
+ */
+ function getBlacklists() {
+ if ( $this->regexes === false ) {
+ $this->regexes = array_merge(
+ $this->getLocalBlacklists(),
+ $this->getSharedBlacklists() );
+ }
+ return $this->regexes;
+ }
+
+ /**
+ * Returns the local blacklist
+ *
+ * @return array Regular expressions
+ */
+ public function getLocalBlacklists() {
+ $that = $this;
+ $type = $this->getBlacklistType();
+
+ return ObjectCache::getMainWANInstance()->getWithSetCallback(
+ wfMemcKey( 'spamblacklist', $type, 'blacklist-regex' ),
+ $this->expiryTime,
+ function () use ( $that, $type ) {
+ return SpamRegexBatch::regexesFromMessage( "{$type}-blacklist", $that );
+ }
+ );
+ }
+
+ /**
+ * Returns the (local) whitelist
+ *
+ * @return array Regular expressions
+ */
+ public function getWhitelists() {
+ $that = $this;
+ $type = $this->getBlacklistType();
+
+ return ObjectCache::getMainWANInstance()->getWithSetCallback(
+ wfMemcKey( 'spamblacklist', $type, 'whitelist-regex' ),
+ $this->expiryTime,
+ function () use ( $that, $type ) {
+ return SpamRegexBatch::regexesFromMessage( "{$type}-whitelist", $that );
+ }
+ );
+ }
+
+ /**
+ * Fetch (possibly cached) remote blacklists.
+ * @return array
+ */
+ function getSharedBlacklists() {
+ $listType = $this->getBlacklistType();
+
+ wfDebugLog( 'SpamBlacklist', "Loading $listType regex..." );
+
+ if ( count( $this->files ) == 0 ) {
+ # No lists
+ wfDebugLog( 'SpamBlacklist', "no files specified\n" );
+ return [];
+ }
+
+ $miss = false;
+
+ $that = $this;
+ $regexes = ObjectCache::getMainWANInstance()->getWithSetCallback(
+ // This used to be cached per-site, but that could be bad on a shared
+ // server where not all wikis have the same configuration.
+ wfMemcKey( 'spamblacklist', $listType, 'shared-blacklist-regex' ),
+ $this->expiryTime,
+ function () use ( $that, &$miss ) {
+ $miss = true;
+ return $that->buildSharedBlacklists();
+ }
+ );
+
+ if ( !$miss ) {
+ wfDebugLog( 'SpamBlacklist', "Got shared spam regexes from cache\n" );
+ }
+
+ return $regexes;
+ }
+
+ /**
+ * Clear all primary blacklist cache keys
+ *
+ * @note: this method is unused atm
+ */
+ function clearCache() {
+ $listType = $this->getBlacklistType();
+
+ $cache = ObjectCache::getMainWANInstance();
+ $cache->delete( wfMemcKey( 'spamblacklist', $listType, 'shared-blacklist-regex' ) );
+ $cache->delete( wfMemcKey( 'spamblacklist', $listType, 'blacklist-regex' ) );
+ $cache->delete( wfMemcKey( 'spamblacklist', $listType, 'whitelist-regex' ) );
+
+ wfDebugLog( 'SpamBlacklist', "$listType blacklist local cache cleared.\n" );
+ }
+
+ function buildSharedBlacklists() {
+ $regexes = [];
+ $listType = $this->getBlacklistType();
+ # Load lists
+ wfDebugLog( 'SpamBlacklist', "Constructing $listType blacklist\n" );
+ foreach ( $this->files as $fileName ) {
+ $matches = [];
+ if ( preg_match( '/^DB: ([\w-]*) (.*)$/', $fileName, $matches ) ) {
+ $text = $this->getArticleText( $matches[1], $matches[2] );
+ } elseif ( preg_match( '/^(https?:)?\/\//', $fileName ) ) {
+ $text = $this->getHttpText( $fileName );
+ } else {
+ $text = file_get_contents( $fileName );
+ wfDebugLog( 'SpamBlacklist', "got from file $fileName\n" );
+ }
+
+ // Build a separate batch of regexes from each source.
+ // While in theory we could squeeze a little efficiency
+ // out of combining multiple sources in one regex, if
+ // there's a bad line in one of them we'll gain more
+ // from only having to break that set into smaller pieces.
+ $regexes = array_merge( $regexes,
+ SpamRegexBatch::regexesFromText( $text, $this, $fileName ) );
+ }
+
+ return $regexes;
+ }
+
+ function getHttpText( $fileName ) {
+ global $wgDBname, $messageMemc;
+ $listType = $this->getBlacklistType();
+
+ # HTTP request
+ # To keep requests to a minimum, we save results into $messageMemc, which is
+ # similar to $wgMemc except almost certain to exist. By default, it is stored
+ # in the database
+ # There are two keys, when the warning key expires, a random thread will refresh
+ # the real key. This reduces the chance of multiple requests under high traffic
+ # conditions.
+ $key = "{$listType}_blacklist_file:$fileName";
+ $warningKey = "$wgDBname:{$listType}filewarning:$fileName";
+ $httpText = $messageMemc->get( $key );
+ $warning = $messageMemc->get( $warningKey );
+
+ if ( !is_string( $httpText ) || ( !$warning && !mt_rand( 0, $this->warningChance ) ) ) {
+ wfDebugLog( 'SpamBlacklist', "Loading $listType blacklist from $fileName\n" );
+ $httpText = Http::get( $fileName );
+ if ( $httpText === false ) {
+ wfDebugLog( 'SpamBlacklist', "Error loading $listType blacklist from $fileName\n" );
+ }
+ $messageMemc->set( $warningKey, 1, $this->warningTime );
+ $messageMemc->set( $key, $httpText, $this->expiryTime );
+ } else {
+ wfDebugLog( 'SpamBlacklist', "Got $listType blacklist from HTTP cache for $fileName\n" );
+ }
+ return $httpText;
+ }
+
+ /**
+ * Fetch an article from this or another local MediaWiki database.
+ * This is probably *very* fragile, and shouldn't be used perhaps.
+ *
+ * @param string $wiki
+ * @param string $article
+ * @return string
+ */
+ function getArticleText( $wiki, $article ) {
+ wfDebugLog( 'SpamBlacklist',
+ "Fetching {$this->getBlacklistType()} blacklist from '$article' on '$wiki'...\n" );
+
+ $title = Title::newFromText( $article );
+ // Load all the relevant tables from the correct DB.
+ // This assumes that old_text is the actual text or
+ // that the external store system is at least unified.
+ if ( is_callable( [ Revision::class, 'getQueryInfo' ] ) ) {
+ $revQuery = Revision::getQueryInfo( [ 'page', 'text' ] );
+ } else {
+ $revQuery = [
+ 'tables' => [ 'revision', 'page', 'text' ],
+ 'fields' => array_merge(
+ Revision::selectFields(),
+ Revision::selectPageFields(),
+ Revision::selectTextFields()
+ ),
+ 'joins' => [
+ 'text' => [ 'JOIN', 'old_id=rev_text_id' ]
+ ],
+ ];
+ }
+ $row = wfGetDB( DB_REPLICA, [], $wiki )->selectRow(
+ $revQuery['tables'],
+ $revQuery['fields'],
+ [
+ 'page_namespace' => $title->getNamespace(), // assume NS IDs match
+ 'page_title' => $title->getDBkey(), // assume same case rules
+ ],
+ __METHOD__,
+ [],
+ [ 'page' => [ 'JOIN', 'rev_id=page_latest' ] ] + $revQuery['joins']
+ );
+
+ return $row
+ ? ContentHandler::getContentText( Revision::newFromRow( $row )->getContent() )
+ : false;
+ }
+
+ /**
+ * Returns the start of the regex for matches
+ *
+ * @return string
+ */
+ public function getRegexStart() {
+ return '/[a-z0-9_\-.]*';
+ }
+
+ /**
+ * Returns the end of the regex for matches
+ *
+ * @param int $batchSize
+ * @return string
+ */
+ public function getRegexEnd( $batchSize ) {
+ return ( $batchSize > 0 ) ? '/Sim' : '/im';
+ }
+
+ /**
+ * @param Title $title
+ * @param string[] $entries
+ */
+ public function warmCachesForFilter( Title $title, array $entries ) {
+ // subclass this
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/EmailBlacklist.php b/www/wiki/extensions/SpamBlacklist/includes/EmailBlacklist.php
new file mode 100644
index 00000000..afcc8eb2
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/EmailBlacklist.php
@@ -0,0 +1,67 @@
+<?php
+
+/**
+ * Email Blacklisting
+ */
+class EmailBlacklist extends BaseBlacklist {
+ /**
+ * @param array $links
+ * @param Title $title
+ * @param bool $preventLog
+ * @return mixed
+ */
+ public function filter( array $links, Title $title, $preventLog = false ) {
+ throw new LogicException( __CLASS__ . ' cannot be used to filter links.' );
+ }
+
+ /**
+ * Returns the code for the blacklist implementation
+ *
+ * @return string
+ */
+ protected function getBlacklistType() {
+ return 'email';
+ }
+
+ /**
+ * Checks a User object for a blacklisted email address
+ *
+ * @param User $user
+ * @return bool True on valid email
+ */
+ public function checkUser( User $user ) {
+ $blacklists = $this->getBlacklists();
+ $whitelists = $this->getWhitelists();
+
+ // The email to check
+ $email = $user->getEmail();
+
+ if ( !count( $blacklists ) ) {
+ // Nothing to check
+ return true;
+ }
+
+ // Check for whitelisted email addresses
+ if ( is_array( $whitelists ) ) {
+ wfDebugLog( 'SpamBlacklist', "Excluding whitelisted email addresses from " .
+ count( $whitelists ) . " regexes: " . implode( ', ', $whitelists ) . "\n" );
+ foreach ( $whitelists as $regex ) {
+ if ( preg_match( $regex, $email ) ) {
+ // Whitelisted email
+ return true;
+ }
+ }
+ }
+
+ # Do the match
+ wfDebugLog( 'SpamBlacklist', "Checking e-mail address against " . count( $blacklists ) .
+ " regexes: " . implode( ', ', $blacklists ) . "\n" );
+ foreach ( $blacklists as $regex ) {
+ if ( preg_match( $regex, $email ) ) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklist.php b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklist.php
new file mode 100644
index 00000000..a6122bc9
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklist.php
@@ -0,0 +1,348 @@
+<?php
+
+if ( !defined( 'MEDIAWIKI' ) ) {
+ exit;
+}
+
+use \MediaWiki\MediaWikiServices;
+use Wikimedia\Rdbms\Database;
+
+class SpamBlacklist extends BaseBlacklist {
+ const STASH_TTL = 180;
+ const STASH_AGE_DYING = 150;
+
+ /**
+ * Changes to external links, for logging purposes
+ * @var array[]
+ */
+ private $urlChangeLog = [];
+
+ /**
+ * Returns the code for the blacklist implementation
+ *
+ * @return string
+ */
+ protected function getBlacklistType() {
+ return 'spam';
+ }
+
+ /**
+ * Apply some basic anti-spoofing to the links before they get filtered,
+ * see @bug 12896
+ *
+ * @param string $text
+ *
+ * @return string
+ */
+ protected function antiSpoof( $text ) {
+ $text = str_replace( '.', '.', $text );
+ return $text;
+ }
+
+ /**
+ * @param string[] $links An array of links to check against the blacklist
+ * @param Title $title The title of the page to which the filter shall be applied.
+ * This is used to load the old links already on the page, so
+ * the filter is only applied to links that got added. If not given,
+ * the filter is applied to all $links.
+ * @param bool $preventLog Whether to prevent logging of hits. Set to true when
+ * the action is testing the links rather than attempting to save them
+ * (e.g. the API spamblacklist action)
+ * @param string $mode Either 'check' or 'stash'
+ *
+ * @return string[]|bool Matched text(s) if the edit should not be allowed; false otherwise
+ */
+ function filter( array $links, Title $title = null, $preventLog = false, $mode = 'check' ) {
+ $statsd = MediaWikiServices::getInstance()->getStatsdDataFactory();
+ $cache = ObjectCache::getLocalClusterInstance();
+
+ // If there are no new links, and we are logging,
+ // mark all of the current links as being removed.
+ if ( !$links && $this->isLoggingEnabled() ) {
+ $this->logUrlChanges( $this->getCurrentLinks( $title ), [], [] );
+ }
+
+ if ( !$links ) {
+ return false;
+ }
+
+ sort( $links );
+ $key = $cache->makeKey(
+ 'blacklist',
+ $this->getBlacklistType(),
+ 'pass',
+ sha1( implode( "\n", $links ) ),
+ (string)$title
+ );
+ // Skip blacklist checks if nothing matched during edit stashing...
+ $knownNonMatchAsOf = $cache->get( $key );
+ if ( $mode === 'check' ) {
+ if ( $knownNonMatchAsOf ) {
+ $statsd->increment( 'spamblacklist.check-stash.hit' );
+
+ return false;
+ } else {
+ $statsd->increment( 'spamblacklist.check-stash.miss' );
+ }
+ } elseif ( $mode === 'stash' ) {
+ if ( $knownNonMatchAsOf && ( time() - $knownNonMatchAsOf ) < self::STASH_AGE_DYING ) {
+ return false; // OK; not about to expire soon
+ }
+ }
+
+ $blacklists = $this->getBlacklists();
+ $whitelists = $this->getWhitelists();
+
+ if ( count( $blacklists ) ) {
+ // poor man's anti-spoof, see bug 12896
+ $newLinks = array_map( [ $this, 'antiSpoof' ], $links );
+
+ $oldLinks = [];
+ if ( $title !== null ) {
+ $oldLinks = $this->getCurrentLinks( $title );
+ $addedLinks = array_diff( $newLinks, $oldLinks );
+ } else {
+ // can't load old links, so treat all links as added.
+ $addedLinks = $newLinks;
+ }
+
+ wfDebugLog( 'SpamBlacklist', "Old URLs: " . implode( ', ', $oldLinks ) );
+ wfDebugLog( 'SpamBlacklist', "New URLs: " . implode( ', ', $newLinks ) );
+ wfDebugLog( 'SpamBlacklist', "Added URLs: " . implode( ', ', $addedLinks ) );
+
+ if ( !$preventLog ) {
+ $this->logUrlChanges( $oldLinks, $newLinks, $addedLinks );
+ }
+
+ $links = implode( "\n", $addedLinks );
+
+ # Strip whitelisted URLs from the match
+ if ( is_array( $whitelists ) ) {
+ wfDebugLog( 'SpamBlacklist', "Excluding whitelisted URLs from " . count( $whitelists ) .
+ " regexes: " . implode( ', ', $whitelists ) . "\n" );
+ foreach ( $whitelists as $regex ) {
+ wfSuppressWarnings();
+ $newLinks = preg_replace( $regex, '', $links );
+ wfRestoreWarnings();
+ if ( is_string( $newLinks ) ) {
+ // If there wasn't a regex error, strip the matching URLs
+ $links = $newLinks;
+ }
+ }
+ }
+
+ # Do the match
+ wfDebugLog( 'SpamBlacklist', "Checking text against " . count( $blacklists ) .
+ " regexes: " . implode( ', ', $blacklists ) . "\n" );
+ $retVal = false;
+ foreach ( $blacklists as $regex ) {
+ wfSuppressWarnings();
+ $matches = [];
+ $check = ( preg_match_all( $regex, $links, $matches ) > 0 );
+ wfRestoreWarnings();
+ if ( $check ) {
+ wfDebugLog( 'SpamBlacklist', "Match!\n" );
+ global $wgRequest;
+ $ip = $wgRequest->getIP();
+ $fullUrls = [];
+ $fullLineRegex = substr( $regex, 0, strrpos( $regex, '/' ) ) . '.*/Sim';
+ preg_match_all( $fullLineRegex, $links, $fullUrls );
+ $imploded = implode( ' ', $fullUrls[0] );
+ wfDebugLog( 'SpamBlacklistHit', "$ip caught submitting spam: $imploded\n" );
+ if ( !$preventLog ) {
+ $this->logFilterHit( $title, $imploded ); // Log it
+ }
+ if ( $retVal === false ) {
+ $retVal = [];
+ }
+ $retVal = array_merge( $retVal, $fullUrls[1] );
+ }
+ }
+ if ( is_array( $retVal ) ) {
+ $retVal = array_unique( $retVal );
+ }
+ } else {
+ $retVal = false;
+ }
+
+ if ( $retVal === false ) {
+ // Cache the typical negative results
+ $cache->set( $key, time(), self::STASH_TTL );
+ if ( $mode === 'stash' ) {
+ $statsd->increment( 'spamblacklist.check-stash.store' );
+ }
+ }
+
+ return $retVal;
+ }
+
+ public function isLoggingEnabled() {
+ global $wgSpamBlacklistEventLogging;
+ return $wgSpamBlacklistEventLogging && class_exists( 'EventLogging' );
+ }
+
+ /**
+ * Diff added/removed urls and generate events for them
+ *
+ * @param string[] $oldLinks
+ * @param string[] $newLinks
+ * @param string[] $addedLinks
+ */
+ public function logUrlChanges( $oldLinks, $newLinks, $addedLinks ) {
+ if ( !$this->isLoggingEnabled() ) {
+ return;
+ }
+
+ $removedLinks = array_diff( $oldLinks, $newLinks );
+ foreach ( $addedLinks as $url ) {
+ $this->logUrlChange( $url, 'insert' );
+ }
+
+ foreach ( $removedLinks as $url ) {
+ $this->logUrlChange( $url, 'remove' );
+ }
+ }
+
+ /**
+ * Actually push the url change events post-save
+ *
+ * @param User $user
+ * @param Title $title
+ * @param int $revId
+ */
+ public function doLogging( User $user, Title $title, $revId ) {
+ if ( !$this->isLoggingEnabled() ) {
+ return;
+ }
+
+ $baseInfo = [
+ 'revId' => $revId,
+ 'pageId' => $title->getArticleID(),
+ 'pageNamespace' => $title->getNamespace(),
+ 'userId' => $user->getId(),
+ 'userText' => $user->getName(),
+ ];
+ $changes = $this->urlChangeLog;
+ // Empty the changes queue in case this function gets called more than once
+ $this->urlChangeLog = [];
+
+ DeferredUpdates::addCallableUpdate( function () use ( $changes, $baseInfo ) {
+ foreach ( $changes as $change ) {
+ EventLogging::logEvent(
+ 'ExternalLinksChange',
+ 15716074,
+ $baseInfo + $change
+ );
+ }
+ } );
+ }
+
+ /**
+ * Queue log data about change for a url addition or removal
+ *
+ * @param string $url
+ * @param string $action 'insert' or 'remove'
+ */
+ private function logUrlChange( $url, $action ) {
+ $parsed = wfParseUrl( $url );
+ if ( !isset( $parsed['host'] ) ) {
+ wfDebugLog( 'SpamBlacklist', "Unable to parse $url" );
+ return;
+ }
+ $info = [
+ 'action' => $action,
+ 'protocol' => $parsed['scheme'],
+ 'domain' => $parsed['host'],
+ 'path' => isset( $parsed['path'] ) ? $parsed['path'] : '',
+ 'query' => isset( $parsed['query'] ) ? $parsed['query'] : '',
+ 'fragment' => isset( $parsed['fragment'] ) ? $parsed['fragment'] : '',
+ ];
+
+ $this->urlChangeLog[] = $info;
+ }
+
+ /**
+ * Look up the links currently in the article, so we can
+ * ignore them on a second run.
+ *
+ * WARNING: I can add more *of the same link* with no problem here.
+ * @param Title $title
+ * @return array
+ */
+ function getCurrentLinks( Title $title ) {
+ $cache = ObjectCache::getMainWANInstance();
+ return $cache->getWithSetCallback(
+ // Key is warmed via warmCachesForFilter() from ApiStashEdit
+ $cache->makeKey( 'external-link-list', $title->getLatestRevID() ),
+ $cache::TTL_MINUTE,
+ function ( $oldValue, &$ttl, array &$setOpts ) use ( $title ) {
+ $dbr = wfGetDB( DB_REPLICA );
+ $setOpts += Database::getCacheSetOptions( $dbr );
+
+ return $dbr->selectFieldValues(
+ 'externallinks',
+ 'el_to',
+ [ 'el_from' => $title->getArticleID() ], // should be zero queries
+ __METHOD__
+ );
+ }
+ );
+ }
+
+ public function warmCachesForFilter( Title $title, array $entries ) {
+ $this->filter( $entries, $title, true /* no logging */, 'stash' );
+ }
+
+ /**
+ * Returns the start of the regex for matches
+ *
+ * @return string
+ */
+ public function getRegexStart() {
+ return '/(?:https?:)?\/\/+[a-z0-9_\-.]*(';
+ }
+
+ /**
+ * Returns the end of the regex for matches
+ *
+ * @param int $batchSize
+ * @return string
+ */
+ public function getRegexEnd( $batchSize ) {
+ return ')' . parent::getRegexEnd( $batchSize );
+ }
+ /**
+ * Logs the filter hit to Special:Log if
+ * $wgLogSpamBlacklistHits is enabled.
+ *
+ * @param Title $title
+ * @param string $url URL that the user attempted to add
+ */
+ public function logFilterHit( $title, $url ) {
+ global $wgUser, $wgLogSpamBlacklistHits;
+ if ( $wgLogSpamBlacklistHits ) {
+ $logEntry = new ManualLogEntry( 'spamblacklist', 'hit' );
+ $logEntry->setPerformer( $wgUser );
+ $logEntry->setTarget( $title );
+ $logEntry->setParameters( [
+ '4::url' => $url,
+ ] );
+ $logid = $logEntry->insert();
+ $log = new LogPage( 'spamblacklist' );
+ if ( $log->isRestricted() ) {
+ // Make sure checkusers can see this action if the log is restricted
+ // (which is the default)
+ if ( ExtensionRegistry::getInstance()->isLoaded( 'CheckUser' )
+ && class_exists( 'CheckUserHooks' )
+ ) {
+ $rc = $logEntry->getRecentChange( $logid );
+ CheckUserHooks::updateCheckUserData( $rc );
+ }
+ } else {
+ // If the log is unrestricted, publish normally to RC,
+ // which will also update checkuser
+ $logEntry->publish( $logid, "rc" );
+ }
+ }
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistHooks.php b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistHooks.php
new file mode 100644
index 00000000..ca8c656f
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistHooks.php
@@ -0,0 +1,283 @@
+<?php
+
+/**
+ * Hooks for the spam blacklist extension
+ */
+class SpamBlacklistHooks {
+
+ /**
+ * Hook function for EditFilterMergedContent
+ *
+ * @param IContextSource $context
+ * @param Content $content
+ * @param Status $status
+ * @param string $summary
+ * @param User $user
+ * @param bool $minoredit
+ *
+ * @return bool
+ */
+ static function filterMergedContent(
+ IContextSource $context,
+ Content $content,
+ Status $status,
+ $summary,
+ User $user,
+ $minoredit
+ ) {
+ $title = $context->getTitle();
+
+ // get the link from the not-yet-saved page content.
+ $editInfo = $context->getWikiPage()->prepareContentForEdit( $content );
+ $pout = $editInfo->output;
+ $links = array_keys( $pout->getExternalLinks() );
+
+ // HACK: treat the edit summary as a link if it contains anything
+ // that looks like it could be a URL or e-mail address.
+ if ( preg_match( '/\S(\.[^\s\d]{2,}|[\/@]\S)/', $summary ) ) {
+ $links[] = $summary;
+ }
+
+ $spamObj = BaseBlacklist::getSpamBlacklist();
+ $matches = $spamObj->filter( $links, $title );
+
+ if ( $matches !== false ) {
+ $status->fatal( 'spamprotectiontext' );
+
+ foreach ( $matches as $match ) {
+ $status->fatal( 'spamprotectionmatch', $match );
+ }
+
+ $status->apiHookResult = [
+ 'spamblacklist' => implode( '|', $matches ),
+ ];
+ }
+
+ // Always return true, EditPage will look at $status->isOk().
+ return true;
+ }
+
+ public static function onParserOutputStashForEdit(
+ WikiPage $page,
+ Content $content,
+ ParserOutput $output
+ ) {
+ $links = array_keys( $output->getExternalLinks() );
+ $spamObj = BaseBlacklist::getSpamBlacklist();
+ $spamObj->warmCachesForFilter( $page->getTitle(), $links );
+ }
+
+ /**
+ * Verify that the user can send emails
+ *
+ * @param User &$user
+ * @param array &$hookErr
+ * @return bool
+ */
+ public static function userCanSendEmail( &$user, &$hookErr ) {
+ $blacklist = BaseBlacklist::getEmailBlacklist();
+ if ( $blacklist->checkUser( $user ) ) {
+ return true;
+ }
+
+ $hookErr = [ 'spam-blacklisted-email', 'spam-blacklisted-email-text', null ];
+
+ return false;
+ }
+
+ /**
+ * Hook function for EditFilter
+ * Confirm that a local blacklist page being saved is valid,
+ * and toss back a warning to the user if it isn't.
+ *
+ * @param EditPage $editPage
+ * @param string $text
+ * @param string $section
+ * @param string &$hookError
+ * @return bool
+ */
+ static function validate( EditPage $editPage, $text, $section, &$hookError ) {
+ $title = $editPage->getTitle();
+ $thisPageName = $title->getPrefixedDBkey();
+
+ if ( !BaseBlacklist::isLocalSource( $title ) ) {
+ wfDebugLog( 'SpamBlacklist',
+ "Spam blacklist validator: [[$thisPageName]] not a local blacklist\n"
+ );
+ return true;
+ }
+
+ $type = BaseBlacklist::getTypeFromTitle( $title );
+ if ( $type === false ) {
+ return true;
+ }
+
+ $lines = explode( "\n", $text );
+
+ $badLines = SpamRegexBatch::getBadLines( $lines, BaseBlacklist::getInstance( $type ) );
+ if ( $badLines ) {
+ wfDebugLog( 'SpamBlacklist',
+ "Spam blacklist validator: [[$thisPageName]] given invalid input lines: " .
+ implode( ', ', $badLines ) . "\n"
+ );
+
+ $badList = "*<code>" .
+ implode( "</code>\n*<code>",
+ array_map( 'wfEscapeWikiText', $badLines ) ) .
+ "</code>\n";
+ $hookError =
+ "<div class='errorbox'>" .
+ wfMessage( 'spam-invalid-lines' )->numParams( $badLines )->text() . "<br />" .
+ $badList .
+ "</div>\n" .
+ "<br clear='all' />\n";
+ } else {
+ wfDebugLog( 'SpamBlacklist',
+ "Spam blacklist validator: [[$thisPageName]] ok or empty blacklist\n"
+ );
+ }
+
+ return true;
+ }
+
+ /**
+ * Hook function for PageContentSaveComplete
+ * Clear local spam blacklist caches on page save.
+ *
+ * @param WikiPage $wikiPage
+ * @param User $user
+ * @param Content $content
+ * @param string $summary
+ * @param bool $isMinor
+ * @param bool $isWatch
+ * @param string $section
+ * @param int $flags
+ * @param Revision|null $revision
+ * @param Status $status
+ * @param int $baseRevId
+ *
+ * @return bool
+ */
+ static function pageSaveContent(
+ WikiPage $wikiPage,
+ User $user,
+ Content $content,
+ $summary,
+ $isMinor,
+ $isWatch,
+ $section,
+ $flags,
+ $revision,
+ Status $status,
+ $baseRevId
+ ) {
+ if ( $revision ) {
+ BaseBlacklist::getSpamBlacklist()
+ ->doLogging( $user, $wikiPage->getTitle(), $revision->getId() );
+ }
+
+ if ( !BaseBlacklist::isLocalSource( $wikiPage->getTitle() ) ) {
+ return true;
+ }
+
+ // This sucks because every Blacklist needs to be cleared
+ foreach ( BaseBlacklist::getBlacklistTypes() as $type => $class ) {
+ $blacklist = BaseBlacklist::getInstance( $type );
+ $blacklist->clearCache();
+ }
+
+ return true;
+ }
+
+ /**
+ * @param UploadBase $upload
+ * @param User $user
+ * @param array $props
+ * @param string $comment
+ * @param string $pageText
+ * @param array|ApiMessage &$error
+ * @return bool
+ */
+ public static function onUploadVerifyUpload(
+ UploadBase $upload,
+ User $user,
+ array $props,
+ $comment,
+ $pageText,
+ &$error
+ ) {
+ $title = $upload->getTitle();
+
+ // get the link from the not-yet-saved page content.
+ $content = ContentHandler::makeContent( $pageText, $title );
+ $parserOptions = $content->getContentHandler()->makeParserOptions( 'canonical' );
+ $output = $content->getParserOutput( $title, null, $parserOptions );
+ $links = array_keys( $output->getExternalLinks() );
+
+ // HACK: treat comment as a link if it contains anything
+ // that looks like it could be a URL or e-mail address.
+ if ( preg_match( '/\S(\.[^\s\d]{2,}|[\/@]\S)/', $comment ) ) {
+ $links[] = $comment;
+ }
+ if ( !$links ) {
+ return true;
+ }
+
+ $spamObj = BaseBlacklist::getSpamBlacklist();
+ $matches = $spamObj->filter( $links, $title );
+
+ if ( $matches !== false ) {
+ $error = new ApiMessage(
+ wfMessage( 'spamprotectiontext' ),
+ 'spamblacklist',
+ [
+ 'spamblacklist' => [ 'matches' => $matches ],
+ 'message' => [
+ 'key' => 'spamprotectionmatch',
+ 'params' => $matches[0],
+ ],
+ ]
+ );
+ }
+
+ return true;
+ }
+
+ /**
+ * @param WikiPage &$article
+ * @param User &$user
+ * @param string &$reason
+ * @param string &$error
+ */
+ public static function onArticleDelete( WikiPage &$article, User &$user, &$reason, &$error ) {
+ $spam = BaseBlacklist::getSpamBlacklist();
+ if ( !$spam->isLoggingEnabled() ) {
+ return;
+ }
+
+ // Log the changes, but we only commit them once the deletion has happened.
+ // We do that since the external links table could get cleared before the
+ // ArticleDeleteComplete hook runs
+ $spam->logUrlChanges( $spam->getCurrentLinks( $article->getTitle() ), [], [] );
+ }
+
+ /**
+ * @param WikiPage &$page
+ * @param User &$user
+ * @param string $reason
+ * @param int $id
+ * @param Content|null $content
+ * @param LogEntry $logEntry
+ */
+ public static function onArticleDeleteComplete(
+ &$page,
+ User &$user,
+ $reason,
+ $id,
+ Content $content = null,
+ LogEntry $logEntry
+ ) {
+ $spam = BaseBlacklist::getSpamBlacklist();
+ $spam->doLogging( $user, $page->getTitle(), $page->getLatest() );
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistLogFormatter.php b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistLogFormatter.php
new file mode 100644
index 00000000..e0c20079
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistLogFormatter.php
@@ -0,0 +1,11 @@
+<?php
+
+class SpamBlacklistLogFormatter extends LogFormatter {
+
+ protected function getMessageParameters() {
+ $params = parent::getMessageParameters();
+ $params[3] = Message::rawParam( htmlspecialchars( $params[3] ) );
+ return $params;
+ }
+
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistPreAuthenticationProvider.php b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistPreAuthenticationProvider.php
new file mode 100644
index 00000000..ed87203d
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/SpamBlacklistPreAuthenticationProvider.php
@@ -0,0 +1,14 @@
+<?php
+
+use MediaWiki\Auth\AbstractPreAuthenticationProvider;
+
+class SpamBlacklistPreAuthenticationProvider extends AbstractPreAuthenticationProvider {
+ public function testForAccountCreation( $user, $creator, array $reqs ) {
+ $blacklist = BaseBlacklist::getEmailBlacklist();
+ if ( $blacklist->checkUser( $user ) ) {
+ return StatusValue::newGood();
+ }
+
+ return StatusValue::newFatal( 'spam-blacklisted-email-signup' );
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/includes/SpamRegexBatch.php b/www/wiki/extensions/SpamBlacklist/includes/SpamRegexBatch.php
new file mode 100644
index 00000000..d7d70e7e
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/includes/SpamRegexBatch.php
@@ -0,0 +1,175 @@
+<?php
+
+/**
+ * Utility class for working with blacklists
+ */
+class SpamRegexBatch {
+ /**
+ * Build a set of regular expressions matching URLs with the list of regex fragments.
+ * Returns an empty list if the input list is empty.
+ *
+ * @param array $lines list of fragments which will match in URLs
+ * @param BaseBlacklist $blacklist
+ * @param int $batchSize largest allowed batch regex;
+ * if 0, will produce one regex per line
+ * @return array
+ */
+ static function buildRegexes( $lines, BaseBlacklist $blacklist, $batchSize=4096 ) {
+ # Make regex
+ # It's faster using the S modifier even though it will usually only be run once
+ // $regex = 'https?://+[a-z0-9_\-.]*(' . implode( '|', $lines ) . ')';
+ // return '/' . str_replace( '/', '\/', preg_replace('|\\\*/|', '/', $regex) ) . '/Sim';
+ $regexes = [];
+ $regexStart = $blacklist->getRegexStart();
+ $regexEnd = $blacklist->getRegexEnd( $batchSize );
+ $build = false;
+ foreach ( $lines as $line ) {
+ if ( substr( $line, -1, 1 ) == "\\" ) {
+ // Final \ will break silently on the batched regexes.
+ // Skip it here to avoid breaking the next line;
+ // warnings from getBadLines() will still trigger on
+ // edit to keep new ones from floating in.
+ continue;
+ }
+ // FIXME: not very robust size check, but should work. :)
+ if ( $build === false ) {
+ $build = $line;
+ } elseif ( strlen( $build ) + strlen( $line ) > $batchSize ) {
+ $regexes[] = $regexStart .
+ str_replace( '/', '\/', preg_replace( '|\\\*/|u', '/', $build ) ) .
+ $regexEnd;
+ $build = $line;
+ } else {
+ $build .= '|';
+ $build .= $line;
+ }
+ }
+ if ( $build !== false ) {
+ $regexes[] = $regexStart .
+ str_replace( '/', '\/', preg_replace( '|\\\*/|u', '/', $build ) ) .
+ $regexEnd;
+ }
+ return $regexes;
+ }
+
+ /**
+ * Confirm that a set of regexes is either empty or valid.
+ *
+ * @param array $regexes set of regexes
+ * @return bool true if ok, false if contains invalid lines
+ */
+ static function validateRegexes( $regexes ) {
+ foreach ( $regexes as $regex ) {
+ wfSuppressWarnings();
+ $ok = preg_match( $regex, '' );
+ wfRestoreWarnings();
+
+ if ( $ok === false ) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+ /**
+ * Strip comments and whitespace, then remove blanks
+ *
+ * @param array $lines
+ * @return array
+ */
+ static function stripLines( $lines ) {
+ return array_filter(
+ array_map( 'trim',
+ preg_replace( '/#.*$/', '',
+ $lines ) ) );
+ }
+
+ /**
+ * Do a sanity check on the batch regex.
+ *
+ * @param array $lines unsanitized input lines
+ * @param BaseBlacklist $blacklist
+ * @param bool|string $fileName optional for debug reporting
+ * @return array of regexes
+ */
+ static function buildSafeRegexes( $lines, BaseBlacklist $blacklist, $fileName=false ) {
+ $lines = self::stripLines( $lines );
+ $regexes = self::buildRegexes( $lines, $blacklist );
+ if ( self::validateRegexes( $regexes ) ) {
+ return $regexes;
+ } else {
+ // _Something_ broke... rebuild line-by-line; it'll be
+ // slower if there's a lot of blacklist lines, but one
+ // broken line won't take out hundreds of its brothers.
+ if ( $fileName ) {
+ wfDebugLog( 'SpamBlacklist', "Spam blacklist warning: bogus line in $fileName\n" );
+ }
+ return self::buildRegexes( $lines, $blacklist, 0 );
+ }
+ }
+
+ /**
+ * Returns an array of invalid lines
+ *
+ * @param array $lines
+ * @param BaseBlacklist $blacklist
+ * @return array of input lines which produce invalid input, or empty array if no problems
+ */
+ static function getBadLines( $lines, BaseBlacklist $blacklist ) {
+ $lines = self::stripLines( $lines );
+
+ $badLines = [];
+ foreach ( $lines as $line ) {
+ if ( substr( $line, -1, 1 ) == "\\" ) {
+ // Final \ will break silently on the batched regexes.
+ $badLines[] = $line;
+ }
+ }
+
+ $regexes = self::buildRegexes( $lines, $blacklist );
+ if ( self::validateRegexes( $regexes ) ) {
+ // No other problems!
+ return $badLines;
+ }
+
+ // Something failed in the batch, so check them one by one.
+ foreach ( $lines as $line ) {
+ $regexes = self::buildRegexes( [ $line ], $blacklist );
+ if ( !self::validateRegexes( $regexes ) ) {
+ $badLines[] = $line;
+ }
+ }
+ return $badLines;
+ }
+
+ /**
+ * Build a set of regular expressions from the given multiline input text,
+ * with empty lines and comments stripped.
+ *
+ * @param string $source
+ * @param BaseBlacklist $blacklist
+ * @param bool|string $fileName optional, for reporting of bad files
+ * @return array of regular expressions, potentially empty
+ */
+ static function regexesFromText( $source, BaseBlacklist $blacklist, $fileName=false ) {
+ $lines = explode( "\n", $source );
+ return self::buildSafeRegexes( $lines, $blacklist, $fileName );
+ }
+
+ /**
+ * Build a set of regular expressions from a MediaWiki message.
+ * Will be correctly empty if the message isn't present.
+ *
+ * @param string $message
+ * @param BaseBlacklist $blacklist
+ * @return array of regular expressions, potentially empty
+ */
+ static function regexesFromMessage( $message, BaseBlacklist $blacklist ) {
+ $source = wfMessage( $message )->inContentLanguage();
+ if ( !$source->isDisabled() ) {
+ return self::regexesFromText( $source->plain(), $blacklist );
+ } else {
+ return [];
+ }
+ }
+}
diff --git a/www/wiki/extensions/SpamBlacklist/maintenance/cleanup.php b/www/wiki/extensions/SpamBlacklist/maintenance/cleanup.php
index c56f1482..0a7236bc 100644
--- a/www/wiki/extensions/SpamBlacklist/maintenance/cleanup.php
+++ b/www/wiki/extensions/SpamBlacklist/maintenance/cleanup.php
@@ -1,129 +1,114 @@
<?php
-
/**
* An aggressive spam cleanup script.
- * Searches the database for matching pages, and reverts them to the last non-spammed revision.
- * If all revisions contain spam, deletes the page
+ * Searches the database for matching pages, and reverts them to
+ * the last non-spammed revision.
+ * If all revisions contain spam, blanks the page
*/
-require_once '../../maintenance/commandLine.inc';
-require_once 'SpamBlacklist_body.php';
-
-/**
- * Find the latest revision of the article that does not contain spam and revert to it
- */
-function cleanupArticle( Revision $rev, $regexes, $match ) {
- $title = $rev->getTitle();
- $revId = $rev->getId();
- while ( $rev ) {
- $matches = false;
- foreach ( $regexes as $regex ) {
- $matches = $matches
- || preg_match(
- $regex,
- ContentHandler::getContentText( $rev->getContent() )
- );
- }
- if ( !$matches ) {
- // Didn't find any spam
- break;
- }
- # Revision::getPrevious can't be used in this way before MW 1.6 (Revision.php 1.26)
- # $rev = $rev->getPrevious();
- $revId = $title->getPreviousRevisionID( $revId );
- if ( $revId ) {
- $rev = Revision::newFromTitle( $title, $revId );
- } else {
- $rev = false;
- }
- }
- if ( !$rev ) {
- // Didn't find a non-spammy revision, delete the page
- /*
- print "All revisions are spam, deleting...\n";
- $article = new Article( $title );
- $article->doDeleteArticle( "All revisions matched the spam blacklist" );
- */
- // Too scary, blank instead
- print "All revisions are spam, blanking...\n";
- $text = '';
- $comment = "All revisions matched the spam blacklist ($match), blanking";
- } else {
- // Revert to this revision
- $text = ContentHandler::getContentText( $rev->getContent() );
- $comment = "Cleaning up links to $match";
- }
- $wikiPage = new WikiPage( $title );
- $wikiPage->doEditContent( ContentHandler::makeContent( $text, $title ), $comment );
+$IP = getenv( 'MW_INSTALL_PATH' );
+if ( $IP === false ) {
+ $IP = __DIR__ . '/../../..';
}
+require_once "$IP/maintenance/Maintenance.php";
-// ------------------------------------------------------------------------------
-
-$username = 'Spam cleanup script';
-if ( method_exists( 'User', 'newSystemUser' ) ) {
- $wgUser = User::newSystemUser( $username, [ 'steal' => true ] );
-} else {
- $wgUser = User::newFromName( $username );
- if ( $wgUser->idForName() == 0 ) {
- // Create the user
- $status = $wgUser->addToDatabase();
- if ( $status === null || $status->isOK() ) {
- $dbw = wfGetDB( DB_MASTER );
- $dbw->update( 'user', [ 'user_password' => 'nologin' ],
- [ 'user_name' => $username ], $username );
- }
+class Cleanup extends Maintenance {
+ public function __construct() {
+ parent::__construct();
+ $this->requireExtension( 'SpamBlacklist' );
+ $this->addOption( 'dry-run', 'Only do a dry run' );
}
-}
-if ( isset( $options['n'] ) ) {
- $dryRun = true;
-} else {
- $dryRun = false;
-}
+ public function execute() {
+ $user = User::newSystemUser( 'Spam cleanup script', [ 'steal' => true ] );
-$sb = new SpamBlacklist( $wgSpamBlacklistSettings );
-if ( $wgSpamBlacklistFiles ) {
- $sb->files = $wgSpamBlacklistFiles;
-}
-$regexes = $sb->getBlacklists();
-if ( !$regexes ) {
- print "Invalid regex, can't clean up spam\n";
- exit( 1 );
-}
+ $sb = BaseBlacklist::getSpamBlacklist();
+ $regexes = $sb->getBlacklists();
+ if ( !$regexes ) {
+ $this->fatalError( "Invalid regex, can't clean up spam" );
+ }
+ $dryRun = $this->hasOption( 'dry-run' );
-$dbr = wfGetDB( DB_SLAVE );
-$maxID = $dbr->selectField( 'page', 'MAX(page_id)' );
-$reportingInterval = 100;
+ $dbr = wfGetDB( DB_REPLICA );
+ $maxID = (int)$dbr->selectField( 'page', 'MAX(page_id)' );
+ $reportingInterval = 100;
-print "Regexes are " . implode( ', ', array_map( 'count', $regexes ) ) . " bytes\n";
-print "Searching for spam in $maxID pages...\n";
-if ( $dryRun ) {
- print "Dry run only\n";
-}
+ $this->output( "Regexes are " . implode( ', ', array_map( 'count', $regexes ) ) . " bytes\n" );
+ $this->output( "Searching for spam in $maxID pages...\n" );
+ if ( $dryRun ) {
+ $this->output( "Dry run only\n" );
+ }
-for ( $id = 1; $id <= $maxID; $id++ ) {
- if ( $id % $reportingInterval == 0 ) {
- printf( "%-8d %-5.2f%%\r", $id, $id / $maxID * 100 );
- }
- $revision = Revision::loadFromPageId( $dbr, $id );
- if ( $revision ) {
- $text = ContentHandler::getContentText( $revision->getContent() );
- if ( $text ) {
- foreach ( $regexes as $regex ) {
- if ( preg_match( $regex, $text, $matches ) ) {
- $title = $revision->getTitle();
- $titleText = $title->getPrefixedText();
- if ( $dryRun ) {
- print "\nFound spam in [[$titleText]]\n";
- } else {
- print "\nCleaning up links to {$matches[0]} in [[$titleText]]\n";
- $match = str_replace( 'http://', '', $matches[0] );
- cleanupArticle( $revision, $regexes, $match );
+ for ( $id = 1; $id <= $maxID; $id++ ) {
+ if ( $id % $reportingInterval == 0 ) {
+ printf( "%-8d %-5.2f%%\r", $id, $id / $maxID * 100 );
+ }
+ $revision = Revision::loadFromPageId( $dbr, $id );
+ if ( $revision ) {
+ $text = ContentHandler::getContentText( $revision->getContent() );
+ if ( $text ) {
+ foreach ( $regexes as $regex ) {
+ if ( preg_match( $regex, $text, $matches ) ) {
+ $title = $revision->getTitle();
+ $titleText = $title->getPrefixedText();
+ if ( $dryRun ) {
+ $this->output( "Found spam in [[$titleText]]\n" );
+ } else {
+ $this->output( "Cleaning up links to {$matches[0]} in [[$titleText]]\n" );
+ $match = str_replace( 'http://', '', $matches[0] );
+ $this->cleanupArticle( $revision, $regexes, $match, $user );
+ }
+ }
}
}
}
}
+ // Just for satisfaction
+ printf( "%-8d %-5.2f%%\n", $id - 1, ( $id - 1 ) / $maxID * 100 );
+ }
+
+ /**
+ * Find the latest revision of the article that does not contain spam and revert to it
+ * @param Revision $rev
+ * @param array $regexes
+ * @param array $match
+ * @param User $user
+ */
+ private function cleanupArticle( Revision $rev, $regexes, $match, User $user ) {
+ $title = $rev->getTitle();
+ while ( $rev ) {
+ $matches = false;
+ foreach ( $regexes as $regex ) {
+ $matches = $matches
+ || preg_match(
+ $regex,
+ ContentHandler::getContentText( $rev->getContent() )
+ );
+ }
+ if ( !$matches ) {
+ // Didn't find any spam
+ break;
+ }
+
+ $rev = $rev->getPrevious();
+ }
+ if ( !$rev ) {
+ // Didn't find a non-spammy revision, blank the page
+ $this->output( "All revisions are spam, blanking...\n" );
+ $text = '';
+ $comment = "All revisions matched the spam blacklist ($match), blanking";
+ } else {
+ // Revert to this revision
+ $text = ContentHandler::getContentText( $rev->getContent() );
+ $comment = "Cleaning up links to $match";
+ }
+ $wikiPage = new WikiPage( $title );
+ $wikiPage->doEditContent(
+ ContentHandler::makeContent( $text, $title ), $comment,
+ 0, false, $user
+ );
}
}
-// Just for satisfaction
-printf( "%-8d %-5.2f%%\n", $id - 1, ( $id - 1 ) / $maxID * 100 );
+
+$maintClass = Cleanup::class;
+require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/www/wiki/extensions/SpamBlacklist/tests/phan/config.php b/www/wiki/extensions/SpamBlacklist/tests/phan/config.php
new file mode 100644
index 00000000..467f0c27
--- /dev/null
+++ b/www/wiki/extensions/SpamBlacklist/tests/phan/config.php
@@ -0,0 +1,19 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+$cfg['directory_list'] = array_merge(
+ $cfg['directory_list'],
+ [
+ './../../extensions/CheckUser',
+ './../../extensions/EventLogging',
+ ]
+);
+$cfg['exclude_analysis_directory_list'] = array_merge(
+ $cfg['exclude_analysis_directory_list'],
+ [
+ './../../extensions/CheckUser',
+ './../../extensions/EventLogging',
+ ]
+);
+
+return $cfg;
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/Gruntfile.js b/www/wiki/extensions/SyntaxHighlight_GeSHi/Gruntfile.js
index 7e4ab440..e176bc95 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/Gruntfile.js
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/Gruntfile.js
@@ -4,7 +4,7 @@
* @package SyntaxHighlight_GeSHi
*/
-/* eslint-env node */
+/* eslint-env node, es6 */
module.exports = function ( grunt ) {
var conf = grunt.file.readJSON( 'extension.json' );
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/README b/www/wiki/extensions/SyntaxHighlight_GeSHi/README
index 61e774d1..1384e9f4 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/README
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/README
@@ -14,10 +14,7 @@ with earlier versions of MediaWiki, visit:
== Installation ==
-First, you will need to ensure that this extension's Composer-managed
-dependencies are available. In the extension directory, run 'composer update'.
-
-Next, Add this line to your LocalSettings.php:
+Add this line to your LocalSettings.php:
wfLoadExtension( 'SyntaxHighlight_GeSHi' );
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/composer.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/composer.json
index ee9562ba..12557914 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/composer.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/composer.json
@@ -1,15 +1,14 @@
{
"name": "mediawiki/syntax-highlight",
"description": "Syntax highlighting extension for MediaWiki",
- "require": {
- "symfony/process": "~3.2"
- },
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
- "license": "GPL-2.0+",
+ "license": "GPL-2.0-or-later",
"authors": [
{
"name": "Brion Vibber",
@@ -32,10 +31,17 @@
}
],
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude vendor --exclude node_modules",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/extension.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/extension.json
index dd753f36..4e7d5c0e 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/extension.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/extension.json
@@ -11,10 +11,10 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:SyntaxHighlight",
"descriptionmsg": "syntaxhighlight-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "parserhook",
"requires": {
- "MediaWiki": ">= 1.27"
+ "MediaWiki": ">= 1.31"
},
"MessagesDirs": {
"SyntaxHighlight_GeSHi": [
@@ -22,13 +22,12 @@
]
},
"AutoloadClasses": {
- "SyntaxHighlight": "SyntaxHighlight.class.php",
- "SyntaxHighlight_GeSHi": "SyntaxHighlight.class.php",
- "GeSHi": "SyntaxHighlight.GeSHi.php",
- "SyntaxHighlightAce": "SyntaxHighlight.ace.php",
- "SyntaxHighlightGeSHiCompat": "SyntaxHighlight.GeSHi.compat.php",
- "ResourceLoaderGeSHiVisualEditorModule": "ResourceLoaderSyntaxHighlightVisualEditorModule.php",
- "ResourceLoaderSyntaxHighlightVisualEditorModule": "ResourceLoaderSyntaxHighlightVisualEditorModule.php"
+ "SyntaxHighlight": "includes/SyntaxHighlight.php",
+ "SyntaxHighlight_GeSHi": "includes/SyntaxHighlight.php",
+ "GeSHi": "includes/GeSHi.php",
+ "SyntaxHighlightAce": "includes/SyntaxHighlightAce.php",
+ "SyntaxHighlightGeSHiCompat": "includes/SyntaxHighlightGeSHiCompat.php",
+ "ResourceLoaderSyntaxHighlightVisualEditorModule": "includes/ResourceLoaderSyntaxHighlightVisualEditorModule.php"
},
"ResourceFileModulePaths": {
"localBasePath": "modules",
@@ -36,7 +35,6 @@
},
"ResourceModules": {
"ext.pygments": {
- "position": "top",
"targets": [
"desktop",
"mobile"
@@ -74,9 +72,5 @@
"TrackingCategories": [
"syntaxhighlight-error-category"
],
- "ParserTestFiles": [
- "tests/parserTests.txt"
- ],
- "load_composer_autoloader": true,
"manifest_version": 1
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/ar.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/ar.json
index 15eeef78..d5d34820 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/ar.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/ar.json
@@ -7,8 +7,16 @@
"ديفيد"
]
},
- "syntaxhighlight-desc": "يوفر تعليم النص <code>&lt;syntaxhighlight&gt;</code> باستخدام [http://pygments.org/ معلم GeSHi]",
+ "syntaxhighlight-desc": "يوفر تمييزا لتركيب <code>&lt;syntaxhighlight&gt;</code> باستخدام [http://pygments.org/ Pygments - Python syntax highlighter]",
"syntaxhighlight-error-category": "صفحات بها أخطاء في تعليم الصيغة",
"syntaxhighlight-error-category-desc": "كان هناك خطأ عند محاولة لتسليط الضوء على الكود المدرجة في الصفحة.",
- "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "نص خام"
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-code": "الكود",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-language": "اللغة",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-none": "(لا شيء)",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-showlines": "إظهار أرقام الخطوط",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "رقم سطر البدء",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "نص خام",
+ "syntaxhighlight-error-pygments-invocation-failure": "فشل استدعاء Pygments",
+ "syntaxhighlight-error-unknown-language": "لغة غير معروفة \"$1\"",
+ "syntaxhighlight-error-exceeds-size-limit": "يتجاوز حجم الكود البالغ $1 {{PLURAL:$1|بايت}} الحد الأقصى المسموح به وهو $2 {{PLURAL:$2|بايت}}"
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/az.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/az.json
index b1bbcb63..7fef3e81 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/az.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/az.json
@@ -4,5 +4,6 @@
"Wertuose"
]
},
- "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-none": "(heç biri)"
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-none": "(heç biri)",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Kodlaşdırma fraqmenti"
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/de.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/de.json
index 8bfe9d37..3e437a06 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/de.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/de.json
@@ -8,13 +8,13 @@
},
"syntaxhighlight-desc": "Ergänzt das Tag <code>&lt;syntaxhighlight&gt;</code> zur Syntaxhervorhebung mit Hilfe des [http://pygments.org/ Python-Syntax-Highlighters „Pygments“]",
"syntaxhighlight-error-category": "Seiten mit Syntaxhervorhebungsfehlern",
- "syntaxhighlight-error-category-desc": "Es gab einen Fehler beim Versuch, Code in der Seite hervorzuheben.",
+ "syntaxhighlight-error-category-desc": "Es gab einen Fehler bei der Syntaxhervorhebung des auf der Seite eingebetteten Codes.",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-code": "Code",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-language": "Sprache",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-none": "(Keine)",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-showlines": "Zeilennummern anzeigen",
- "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "Start-Zeilennummer",
- "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Code-Block",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "Startzeilennummer",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Codeblock",
"syntaxhighlight-error-pygments-invocation-failure": "Fehler beim Aufrufen von Pygments",
"syntaxhighlight-error-unknown-language": "Unbekannte Sprache „$1“",
"syntaxhighlight-error-exceeds-size-limit": "Die Codegröße von {{PLURAL:$1|einem Byte|$1 Bytes}} überschreitet das erlaubte Maximum von {{PLURAL:$2|einem Byte|$2 Bytes}}"
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hr.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hr.json
index f0d4e28e..224c38f8 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hr.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hr.json
@@ -13,5 +13,6 @@
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-code": "Kôd",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-language": "Jezik",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-showlines": "Prikaži brojeve redova",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "Broj početnog reda",
"syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Računalni kôd"
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hy.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hy.json
new file mode 100644
index 00000000..b07d7204
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/hy.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "Դավիթ Սարոյան"
+ ]
+ },
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-code": "Կոդ",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-language": "Լեզու",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-none": "(ոչ մի)",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-showlines": "Ցույց տալ տողերի թիվը",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "Առաջին տողի թիվը",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Կոդի հատված",
+ "syntaxhighlight-error-unknown-language": "Անհայտ լեզու «$1»"
+}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/mwl.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/mwl.json
new file mode 100644
index 00000000..4b2ed830
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/mwl.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
+ ]
+ },
+ "syntaxhighlight-error-category": "Páiginas cun erros ne l çtaque de sintaxe"
+}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-ec.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-ec.json
index 5e520ab2..ece34e83 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-ec.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-ec.json
@@ -5,9 +5,11 @@
"Rancher",
"Sasa Stefanovic",
"Сербијана",
- "Obsuser"
+ "Obsuser",
+ "Prevodim"
]
},
"syntaxhighlight-desc": "Омогућава визуелно означавање синтаксе <code>&lt;syntaxhighlight&gt;</code> коришћењем [http://pygments.org/ Pygments хајлајтера].",
- "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "Број почетне линије"
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline": "Број почетне линије",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Парче кôда"
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-el.json b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-el.json
index 0159744d..bcd302c4 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-el.json
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/i18n/sr-el.json
@@ -2,8 +2,10 @@
"@metadata": {
"authors": [
"MaxSem",
- "Michaello"
+ "Michaello",
+ "Prevodim"
]
},
- "syntaxhighlight-desc": "Omogućava vizuelno označavanje sintakse <code>&lt;syntaxhighlight&gt;</code> korišćenjem [http://pygments.org/ GeSHi hajlajtera]."
+ "syntaxhighlight-desc": "Omogućava vizuelno označavanje sintakse <code>&lt;syntaxhighlight&gt;</code> korišćenjem [http://pygments.org/ GeSHi hajlajtera].",
+ "syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title": "Parče kôda"
}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/GeSHi.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/GeSHi.php
new file mode 100644
index 00000000..516de12f
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/GeSHi.php
@@ -0,0 +1,42 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Stub class for maintaining backward-compatibility with extensions
+ * that have not been updated for version 2.0 of SyntaxHighlight_GeSHi.
+ */
+class GeSHi {
+
+ private $html;
+
+ public function __construct( $html ) {
+ $this->html = $html;
+ }
+
+ public function error() {
+ }
+
+ public function set_language( $language ) {
+ }
+
+ public function parse_code() {
+ global $wgOut;
+ $wgOut->addModuleStyles( 'ext.pygments' );
+ return $this->html;
+ }
+}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/ResourceLoaderSyntaxHighlightVisualEditorModule.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/ResourceLoaderSyntaxHighlightVisualEditorModule.php
new file mode 100644
index 00000000..720cfd22
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/ResourceLoaderSyntaxHighlightVisualEditorModule.php
@@ -0,0 +1,70 @@
+<?php
+
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+class ResourceLoaderSyntaxHighlightVisualEditorModule extends ResourceLoaderFileModule {
+
+ protected $targets = [ 'desktop', 'mobile' ];
+
+ /**
+ * @param ResourceLoaderContext $context
+ * @return string JavaScript code
+ */
+ public function getScript( ResourceLoaderContext $context ) {
+ $scripts = parent::getScript( $context );
+
+ return $scripts . Xml::encodeJsCall(
+ 've.dm.MWSyntaxHighlightNode.static.addPygmentsLanguages', [
+ $this->getPygmentsLanguages()
+ ],
+ ResourceLoader::inDebugMode()
+ ) . Xml::encodeJsCall(
+ 've.dm.MWSyntaxHighlightNode.static.addGeshiToPygmentsMap', [
+ SyntaxHighlightGeSHiCompat::getGeSHiToPygmentsMap()
+ ],
+ ResourceLoader::inDebugMode()
+ ) . Xml::encodeJsCall(
+ 've.dm.MWSyntaxHighlightNode.static.addPygmentsToAceMap', [
+ SyntaxHighlightAce::getPygmentsToAceMap()
+ ],
+ ResourceLoader::inDebugMode()
+ );
+ }
+
+ /**
+ * Don't break debug mode by only showing file URLs
+ * @param ResourceLoaderContext $context
+ * @return array
+ */
+ public function getScriptURLsForDebug( ResourceLoaderContext $context ) {
+ return ResourceLoaderModule::getScriptURLsForDebug( $context );
+ }
+
+ /**
+ * Get a full list of available languages
+ * @return array
+ */
+ private function getPygmentsLanguages() {
+ $lexers = require __DIR__ . '/../SyntaxHighlight.lexers.php';
+ return $lexers;
+ }
+
+ public function enableModuleContentVersion() {
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlight.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlight.php
new file mode 100644
index 00000000..076efe1e
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlight.php
@@ -0,0 +1,577 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+use MediaWiki\Shell\Shell;
+
+class SyntaxHighlight {
+
+ /** @var int The maximum number of lines that may be selected for highlighting. **/
+ const HIGHLIGHT_MAX_LINES = 1000;
+
+ /** @var int Maximum input size for the highlighter (100 kB). **/
+ const HIGHLIGHT_MAX_BYTES = 102400;
+
+ /** @var string CSS class for syntax-highlighted code. **/
+ const HIGHLIGHT_CSS_CLASS = 'mw-highlight';
+
+ /** @var int Cache version. Increment whenever the HTML changes. */
+ const CACHE_VERSION = 2;
+
+ /** @var array Mapping of MIME-types to lexer names. **/
+ private static $mimeLexers = [
+ 'text/javascript' => 'javascript',
+ 'application/json' => 'javascript',
+ 'text/xml' => 'xml',
+ ];
+
+ /**
+ * Get the Pygments lexer name for a particular language.
+ *
+ * @param string $lang Language name.
+ * @return string|null Lexer name, or null if no matching lexer.
+ */
+ private static function getLexer( $lang ) {
+ static $lexers = null;
+
+ if ( $lang === null ) {
+ return null;
+ }
+
+ if ( !$lexers ) {
+ $lexers = require __DIR__ . '/../SyntaxHighlight.lexers.php';
+ }
+
+ $lexer = strtolower( $lang );
+
+ if ( in_array( $lexer, $lexers ) ) {
+ return $lexer;
+ }
+
+ $geshi2pygments = SyntaxHighlightGeSHiCompat::getGeSHiToPygmentsMap();
+
+ // Check if this is a GeSHi lexer name for which there exists
+ // a compatible Pygments lexer with a different name.
+ if ( isset( $geshi2pygments[$lexer] ) ) {
+ $lexer = $geshi2pygments[$lexer];
+ if ( in_array( $lexer, $lexers ) ) {
+ return $lexer;
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * Register parser hook
+ *
+ * @param Parser &$parser
+ */
+ public static function onParserFirstCallInit( Parser &$parser ) {
+ foreach ( [ 'source', 'syntaxhighlight' ] as $tag ) {
+ $parser->setHook( $tag, [ 'SyntaxHighlight', 'parserHook' ] );
+ }
+ }
+
+ /**
+ * Parser hook
+ *
+ * @param string $text
+ * @param array $args
+ * @param Parser $parser
+ * @return string
+ * @throws MWException
+ */
+ public static function parserHook( $text, $args, $parser ) {
+ global $wgUseTidy;
+
+ // Replace strip markers (For e.g. {{#tag:syntaxhighlight|<nowiki>...}})
+ $out = $parser->mStripState->unstripNoWiki( $text );
+
+ // Don't trim leading spaces away, just the linefeeds
+ $out = preg_replace( '/^\n+/', '', rtrim( $out ) );
+
+ // Convert deprecated attributes
+ if ( isset( $args['enclose'] ) ) {
+ if ( $args['enclose'] === 'none' ) {
+ $args['inline'] = true;
+ }
+ unset( $args['enclose'] );
+ }
+
+ $lexer = isset( $args['lang'] ) ? $args['lang'] : '';
+
+ $result = self::highlight( $out, $lexer, $args );
+ if ( !$result->isGood() ) {
+ $parser->addTrackingCategory( 'syntaxhighlight-error-category' );
+ }
+ $out = $result->getValue();
+
+ // HTML Tidy will convert tabs to spaces incorrectly (bug 30930).
+ // But the conversion from tab to space occurs while reading the input,
+ // before the conversion from &#9; to tab, so we can armor it that way.
+ if ( $wgUseTidy ) {
+ $out = str_replace( "\t", '&#9;', $out );
+ }
+
+ // Allow certain HTML attributes
+ $htmlAttribs = Sanitizer::validateAttributes( $args, [ 'style', 'class', 'id', 'dir' ] );
+ if ( !isset( $htmlAttribs['class'] ) ) {
+ $htmlAttribs['class'] = self::HIGHLIGHT_CSS_CLASS;
+ } else {
+ $htmlAttribs['class'] .= ' ' . self::HIGHLIGHT_CSS_CLASS;
+ }
+ if ( !( isset( $htmlAttribs['dir'] ) && $htmlAttribs['dir'] === 'rtl' ) ) {
+ $htmlAttribs['dir'] = 'ltr';
+ }
+
+ if ( isset( $args['inline'] ) ) {
+ // Enforce inlineness. Stray newlines may result in unexpected list and paragraph processing
+ // (also known as doBlockLevels()).
+ $out = str_replace( "\n", ' ', $out );
+ $out = Html::rawElement( 'code', $htmlAttribs, $out );
+
+ } else {
+ // Not entirely sure what benefit this provides, but it was here already
+ $htmlAttribs['class'] .= ' ' . 'mw-content-' . $htmlAttribs['dir'];
+
+ // Unwrap Pygments output to provide our own wrapper. We can't just always use the 'nowrap'
+ // option (pass 'inline'), since it disables other useful things like line highlighting.
+ // Tolerate absence of quotes for Html::element() and wgWellFormedXml=false.
+ if ( $out !== '' ) {
+ $m = [];
+ if ( preg_match( '/^<div class="?mw-highlight"?>(.*)<\/div>$/s', trim( $out ), $m ) ) {
+ $out = trim( $m[1] );
+ } else {
+ throw new MWException( 'Unexpected output from Pygments encountered' );
+ }
+ }
+
+ // Use 'nowiki' strip marker to prevent list processing (also known as doBlockLevels()).
+ // However, leave the wrapping <div/> outside to prevent <p/>-wrapping.
+ $marker = $parser::MARKER_PREFIX . '-syntaxhighlightinner-' .
+ sprintf( '%08X', $parser->mMarkerIndex++ ) . $parser::MARKER_SUFFIX;
+ $parser->mStripState->addNoWiki( $marker, $out );
+
+ $out = Html::openElement( 'div', $htmlAttribs ) .
+ $marker .
+ Html::closeElement( 'div' );
+ }
+
+ // Register CSS
+ $parser->getOutput()->addModuleStyles( 'ext.pygments' );
+
+ return $out;
+ }
+
+ /**
+ * @return string
+ */
+ public static function getPygmentizePath() {
+ global $wgPygmentizePath;
+
+ // If $wgPygmentizePath is unset, use the bundled copy.
+ if ( $wgPygmentizePath === false ) {
+ $wgPygmentizePath = __DIR__ . '/../pygments/pygmentize';
+ }
+
+ return $wgPygmentizePath;
+ }
+
+ /**
+ * @param string $code
+ * @param bool $inline
+ */
+ private static function plainCodeWrap( $code, $inline ) {
+ if ( $inline ) {
+ return htmlspecialchars( $code, ENT_NOQUOTES );
+ }
+
+ return Html::rawElement(
+ 'div',
+ [ 'class' => self::HIGHLIGHT_CSS_CLASS ],
+ Html::element( 'pre', [], $code )
+ );
+ }
+
+ /**
+ * Highlight a code-block using a particular lexer.
+ *
+ * @param string $code Code to highlight.
+ * @param string|null $lang Language name, or null to use plain markup.
+ * @param array $args Associative array of additional arguments.
+ * If it contains a 'line' key, the output will include line numbers.
+ * If it includes a 'highlight' key, the value will be parsed as a
+ * comma-separated list of lines and line-ranges to highlight.
+ * If it contains a 'start' key, the value will be used as the line at which to
+ * start highlighting.
+ * If it contains a 'inline' key, the output will not be wrapped in `<div><pre/></div>`.
+ * @return Status Status object, with HTML representing the highlighted
+ * code as its value.
+ */
+ public static function highlight( $code, $lang = null, $args = [] ) {
+ $status = new Status;
+
+ $lexer = self::getLexer( $lang );
+ if ( $lexer === null && $lang !== null ) {
+ $status->warning( 'syntaxhighlight-error-unknown-language', $lang );
+ }
+
+ // For empty tag, output nothing instead of empty <pre>.
+ if ( $code === '' ) {
+ $status->value = '';
+ return $status;
+ }
+
+ $length = strlen( $code );
+ if ( strlen( $code ) > self::HIGHLIGHT_MAX_BYTES ) {
+ // Disable syntax highlighting
+ $lexer = null;
+ $status->warning(
+ 'syntaxhighlight-error-exceeds-size-limit',
+ $length,
+ self::HIGHLIGHT_MAX_BYTES
+ );
+ } elseif ( Shell::isDisabled() ) {
+ // Disable syntax highlighting
+ $lexer = null;
+ $status->warning( 'syntaxhighlight-error-pygments-invocation-failure' );
+ wfWarn(
+ 'MediaWiki determined that it cannot invoke Pygments. ' .
+ 'As a result, SyntaxHighlight_GeSHi will not perform any syntax highlighting. ' .
+ 'See the debug log for details: ' .
+ 'https://www.mediawiki.org/wiki/Manual:$wgDebugLogFile'
+ );
+ }
+
+ $inline = isset( $args['inline'] );
+
+ if ( $inline ) {
+ $code = trim( $code );
+ }
+
+ if ( $lexer === null ) {
+ // When syntax highlighting is disabled..
+ $status->value = self::plainCodeWrap( $code, $inline );
+ return $status;
+ }
+
+ $options = [
+ 'cssclass' => self::HIGHLIGHT_CSS_CLASS,
+ 'encoding' => 'utf-8',
+ ];
+
+ // Line numbers
+ if ( isset( $args['line'] ) ) {
+ $options['linenos'] = 'inline';
+ }
+
+ if ( $lexer === 'php' && strpos( $code, '<?php' ) === false ) {
+ $options['startinline'] = 1;
+ }
+
+ // Highlight specific lines
+ if ( isset( $args['highlight'] ) ) {
+ $lines = self::parseHighlightLines( $args['highlight'] );
+ if ( count( $lines ) ) {
+ $options['hl_lines'] = implode( ' ', $lines );
+ }
+ }
+
+ // Starting line number
+ if ( isset( $args['start'] ) && ctype_digit( $args['start'] ) ) {
+ $options['linenostart'] = (int)$args['start'];
+ }
+
+ if ( $inline ) {
+ $options['nowrap'] = 1;
+ }
+
+ $cache = ObjectCache::getMainWANInstance();
+ $error = null;
+ $output = $cache->getWithSetCallback(
+ $cache->makeGlobalKey( 'highlight', self::makeCacheKeyHash( $code, $lexer, $options ) ),
+ $cache::TTL_MONTH,
+ function ( $oldValue, &$ttl ) use ( $code, $lexer, $options, &$error ) {
+ $optionPairs = [];
+ foreach ( $options as $k => $v ) {
+ $optionPairs[] = "{$k}={$v}";
+ }
+ $result = Shell::command(
+ self::getPygmentizePath(),
+ '-l', $lexer,
+ '-f', 'html',
+ '-O', implode( ',', $optionPairs )
+ )
+ ->input( $code )
+ ->restrict( Shell::RESTRICT_DEFAULT | Shell::NO_NETWORK )
+ ->execute();
+
+ if ( $result->getExitCode() != 0 ) {
+ $ttl = WANObjectCache::TTL_UNCACHEABLE;
+ $error = $result->getStderr();
+ return null;
+ }
+
+ return $result->getStdout();
+ }
+ );
+
+ if ( $error !== null || $output === null ) {
+ $status->warning( 'syntaxhighlight-error-pygments-invocation-failure' );
+ wfWarn( 'Failed to invoke Pygments: ' . $error );
+ // Fall back to preformatted code without syntax highlighting
+ $output = self::plainCodeWrap( $code, $inline );
+ }
+
+ if ( $inline ) {
+ // We've already trimmed the input $code before highlighting,
+ // but pygment's standard out adds a line break afterwards,
+ // which would then be preserved in the paragraph that wraps this,
+ // and become visible as a space. Avoid that.
+ $output = trim( $output );
+ }
+
+ $status->value = $output;
+ return $status;
+ }
+
+ /**
+ * Construct a cache key for the results of a Pygments invocation.
+ *
+ * @param string $code Code to be highlighted.
+ * @param string $lexer Lexer name.
+ * @param array $options Options array.
+ * @return string Cache key.
+ */
+ private static function makeCacheKeyHash( $code, $lexer, $options ) {
+ $optionString = FormatJson::encode( $options, false, FormatJson::ALL_OK );
+ return md5( "{$code}|{$lexer}|{$optionString}|" . self::CACHE_VERSION );
+ }
+
+ /**
+ * Take an input specifying a list of lines to highlight, returning
+ * a raw list of matching line numbers.
+ *
+ * Input is comma-separated list of lines or line ranges.
+ *
+ * @param string $lineSpec
+ * @return int[] Line numbers.
+ */
+ protected static function parseHighlightLines( $lineSpec ) {
+ $lines = [];
+ $values = array_map( 'trim', explode( ',', $lineSpec ) );
+ foreach ( $values as $value ) {
+ if ( ctype_digit( $value ) ) {
+ $lines[] = (int)$value;
+ } elseif ( strpos( $value, '-' ) !== false ) {
+ list( $start, $end ) = array_map( 'trim', explode( '-', $value ) );
+ if ( self::validHighlightRange( $start, $end ) ) {
+ for ( $i = intval( $start ); $i <= $end; $i++ ) {
+ $lines[] = $i;
+ }
+ }
+ }
+ if ( count( $lines ) > self::HIGHLIGHT_MAX_LINES ) {
+ $lines = array_slice( $lines, 0, self::HIGHLIGHT_MAX_LINES );
+ break;
+ }
+ }
+ return $lines;
+ }
+
+ /**
+ * Validate a provided input range
+ * @param int $start
+ * @param int $end
+ * @return bool
+ */
+ protected static function validHighlightRange( $start, $end ) {
+ // Since we're taking this tiny range and producing a an
+ // array of every integer between them, it would be trivial
+ // to DoS the system by asking for a huge range.
+ // Impose an arbitrary limit on the number of lines in a
+ // given range to reduce the impact.
+ return ctype_digit( $start ) &&
+ ctype_digit( $end ) &&
+ $start > 0 &&
+ $start < $end &&
+ $end - $start < self::HIGHLIGHT_MAX_LINES;
+ }
+
+ /**
+ * Hook into Content::getParserOutput to provide syntax highlighting for
+ * script content.
+ *
+ * @param Content $content
+ * @param Title $title
+ * @param int $revId
+ * @param ParserOptions $options
+ * @param bool $generateHtml
+ * @param ParserOutput &$output
+ * @return bool
+ * @since MW 1.21
+ */
+ public static function onContentGetParserOutput( Content $content, Title $title,
+ $revId, ParserOptions $options, $generateHtml, ParserOutput &$output
+ ) {
+ global $wgParser, $wgTextModelsToParse;
+
+ if ( !$generateHtml ) {
+ // Nothing special for us to do, let MediaWiki handle this.
+ return true;
+ }
+
+ // Determine the language
+ $extension = ExtensionRegistry::getInstance();
+ $models = $extension->getAttribute( 'SyntaxHighlightModels' );
+ $model = $content->getModel();
+ if ( !isset( $models[$model] ) ) {
+ // We don't care about this model, carry on.
+ return true;
+ }
+ $lexer = $models[$model];
+
+ // Hope that $wgSyntaxHighlightModels does not contain silly types.
+ $text = ContentHandler::getContentText( $content );
+ if ( !$text ) {
+ // Oops! Non-text content? Let MediaWiki handle this.
+ return true;
+ }
+
+ // Parse using the standard parser to get links etc. into the database, HTML is replaced below.
+ // We could do this using $content->fillParserOutput(), but alas it is 'protected'.
+ if ( $content instanceof TextContent && in_array( $model, $wgTextModelsToParse ) ) {
+ $output = $wgParser->parse( $text, $title, $options, true, true, $revId );
+ }
+
+ $status = self::highlight( $text, $lexer );
+ if ( !$status->isOK() ) {
+ return true;
+ }
+ $out = $status->getValue();
+
+ $output->addModuleStyles( 'ext.pygments' );
+ $output->setText( '<div dir="ltr">' . $out . '</div>' );
+
+ // Inform MediaWiki that we have parsed this page and it shouldn't mess with it.
+ return false;
+ }
+
+ /**
+ * Hook to provide syntax highlighting for API pretty-printed output
+ *
+ * @param IContextSource $context
+ * @param string $text
+ * @param string $mime
+ * @param string $format
+ * @since MW 1.24
+ * @return bool
+ */
+ public static function onApiFormatHighlight( IContextSource $context, $text, $mime, $format ) {
+ if ( !isset( self::$mimeLexers[$mime] ) ) {
+ return true;
+ }
+
+ $lexer = self::$mimeLexers[$mime];
+ $status = self::highlight( $text, $lexer );
+ if ( !$status->isOK() ) {
+ return true;
+ }
+
+ $out = $status->getValue();
+ if ( preg_match( '/^<pre([^>]*)>/i', $out, $m ) ) {
+ $attrs = Sanitizer::decodeTagAttributes( $m[1] );
+ $attrs['class'] .= ' api-pretty-content';
+ $encodedAttrs = Sanitizer::safeEncodeTagAttributes( $attrs );
+ $out = '<pre' . $encodedAttrs. '>' . substr( $out, strlen( $m[0] ) );
+ }
+ $output = $context->getOutput();
+ $output->addModuleStyles( 'ext.pygments' );
+ $output->addHTML( '<div dir="ltr">' . $out . '</div>' );
+
+ // Inform MediaWiki that we have parsed this page and it shouldn't mess with it.
+ return false;
+ }
+
+ /**
+ * Conditionally register resource loader modules that depends on the
+ * VisualEditor MediaWiki extension.
+ *
+ * @param ResourceLoader &$resourceLoader
+ */
+ public static function onResourceLoaderRegisterModules( &$resourceLoader ) {
+ if ( !ExtensionRegistry::getInstance()->isLoaded( 'VisualEditor' ) ) {
+ return;
+ }
+
+ $resourceLoader->register( 'ext.geshi.visualEditor', [
+ 'class' => ResourceLoaderSyntaxHighlightVisualEditorModule::class,
+ 'localBasePath' => __DIR__ . '/../modules',
+ 'remoteExtPath' => 'SyntaxHighlight_GeSHi/modules',
+ 'scripts' => [
+ 've-syntaxhighlight/ve.dm.MWSyntaxHighlightNode.js',
+ 've-syntaxhighlight/ve.ce.MWSyntaxHighlightNode.js',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightWindow.js',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.js',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightDialogTool.js',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.js',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightInspectorTool.js',
+ ],
+ 'styles' => [
+ 've-syntaxhighlight/ve.ce.MWSyntaxHighlightNode.css',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.css',
+ 've-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.css',
+ ],
+ 'dependencies' => [
+ 'ext.visualEditor.mwcore',
+ 'oojs-ui.styles.icons-editing-advanced'
+ ],
+ 'messages' => [
+ 'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-code',
+ 'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-language',
+ 'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-none',
+ 'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-showlines',
+ 'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-startingline',
+ 'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title',
+ ],
+ 'targets' => [ 'desktop', 'mobile' ],
+ ] );
+ }
+
+ /**
+ * Backward-compatibility shim for extensions.
+ * @deprecated since MW 1.25
+ */
+ public static function prepare( $text, $lang ) {
+ wfDeprecated( __METHOD__ );
+ return new GeSHi( self::highlight( $text, $lang )->getValue() );
+ }
+
+ /**
+ * Backward-compatibility shim for extensions.
+ * @deprecated since MW 1.25
+ * @param GeSHi $geshi
+ * @return string
+ */
+ public static function buildHeadItem( $geshi ) {
+ wfDeprecated( __METHOD__ );
+ $geshi->parse_code();
+ return '';
+ }
+}
+class_alias( SyntaxHighlight::class, 'SyntaxHighlight_GeSHi' );
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightAce.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightAce.php
new file mode 100644
index 00000000..54991f32
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightAce.php
@@ -0,0 +1,174 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Class provides functionality to map Ace lexer definitions
+ */
+class SyntaxHighlightAce {
+ /** @var array This map is inverted, because it is easier to maintain this way */
+ private static $aceLexers = [
+ 'ABAP' => [ 'abap' ],
+ 'ABC' => [],
+ 'ActionScript' => [ 'actionscript', 'actionscript3' ],
+ 'ADA' => [ 'ada', 'ada2005', 'ada95' ],
+ 'Apache_Conf' => [ 'apache', 'apacheconf', 'aconf' ],
+ 'AsciiDoc' => [],
+ 'Assembly_x86' => [ 'nasm' ],
+ 'AutoHotKey' => [ 'autohotkey', 'ah' ],
+ 'BatchFile' => [ 'bat', 'batch', 'dosbatch', 'winbatch' ],
+ 'C_Cpp' => [ 'cpp', 'c++' ],
+ 'C9Search' => [],
+ 'Cirru' => [ 'cirru' ],
+ 'Clojure' => [ 'clojure', 'clj' ],
+ 'Cobol' => [ 'cobol' ],
+ 'coffee' => [ 'coffee', 'coffeescript', 'coffee-script' ],
+ 'ColdFusion' => [ 'cfm' ],
+ 'CSharp' => [ 'csharp', '#' ],
+ 'CSS' => [ 'css' ],
+ 'Curly' => [],
+ 'D' => [ 'd' ],
+ 'Dart' => [ 'dart' ],
+ 'Diff' => [ 'diff', 'udiff' ],
+ 'Django' => [ 'django', 'html+django', 'html+jinja', 'htmldjango' ],
+ 'Dockerfile' => [ 'Dockerfile', 'docker' ],
+ 'Dot' => [],
+ 'Dummy' => [],
+ 'DummySyntax' => [],
+ 'Eiffel' => [ 'eiffel' ],
+ 'EJS' => [],
+ 'Elixir' => [ 'elixer', 'ex', 'exs' ],
+ 'Elm' => [ 'elm' ],
+ 'Erlang' => [ 'erlang' ],
+ 'Forth' => [],
+ 'Fortran' => [ 'fortran' ],
+ 'FTL' => [],
+ 'Gcode' => [],
+ 'Gherkin' => [ 'cucumber', 'gherkin' ],
+ 'Gitignore' => [],
+ 'Glsl' => [ 'glsl' ],
+ 'Gobstones' => [],
+ 'golang' => [ 'go' ],
+ 'Groovy' => [ 'groovy' ],
+ 'HAML' => [ 'haml' ],
+ 'Handlebars' => [ 'html+handlebars' ],
+ 'Haskell' => [ 'haskell', 'hs' ],
+ 'haXe' => [ 'hx', 'haxe', 'hxsl' ],
+ 'HTML' => [ 'html' ],
+ 'HTML_Elixir' => [],
+ 'HTML_Ruby' => [ 'rhtml', 'html+erb', 'html+ruby' ],
+ 'INI' => [ 'ini', 'cfg', 'dosini' ],
+ 'Io' => [ 'io' ],
+ 'Jack' => [ '' ],
+ 'Jade' => [ 'jade' ],
+ 'Java' => [ 'java' ],
+ 'JavaScript' => [ 'Javascript', 'js' ],
+ 'JSON' => [ 'json' ],
+ 'JSONiq' => [],
+ 'JSP' => [ 'jsp' ],
+ 'JSX' => [],
+ 'Julia' => [ 'julia', 'jl' ],
+ 'LaTeX' => [ 'latex' ],
+ 'Lean' => [ 'lean' ],
+ 'LESS' => [ 'less' ],
+ 'Liquid' => [ 'liquid' ],
+ 'Lisp' => [ 'lisp', 'common-lisp', 'cl' ],
+ 'LiveScript' => [ 'Livescript', 'live-script' ],
+ 'LogiQL' => [],
+ 'LSL' => [ 'lsl' ],
+ 'Lua' => [ 'lua' ],
+ 'LuaPage' => [],
+ 'Lucene' => [],
+ 'Makefile' => [ 'make', 'makefile', 'mf', 'bsdmake' ],
+ 'Markdown' => [],
+ 'Mask' => [ 'mask' ],
+ 'MATLAB' => [ 'matlab' ],
+ 'Maze' => [],
+ 'MEL' => [],
+ 'MUSHCode' => [],
+ 'MySQL' => [ 'mysql' ],
+ 'Nix' => [ 'nix', 'nixos' ],
+ 'NSIS' => [ 'nsis', 'nsi', 'nsh' ],
+ 'ObjectiveC' => [ 'objectivec', 'objective-c', 'obj-c', 'objc',
+ 'objective-c++', 'objectivec++', 'obj-c++', 'objc++' ],
+ 'OCaml' => [ 'ocaml' ],
+ 'Pascal' => [ 'pascal', 'delphi', 'pas', 'objectpascal' ],
+ 'Perl' => [ 'perl', 'pl', 'perl6', 'pl6' ],
+ 'pgSQL' => [ 'postgresql', 'postgres' ],
+ 'PHP' => [ 'php', 'php3', 'php4', 'php5', 'html+php' ],
+ 'Powershell' => [ 'powershell', 'posh', 'ps1', 'psm1' ],
+ 'Praat' => [ 'praat' ],
+ 'Prolog' => [ 'prolog' ],
+ 'Properties' => [ 'properties', 'jproperties' ],
+ 'Protobuf' => [ 'protobuf', 'proto' ],
+ 'Python' => [ 'python', 'py', 'sage', 'pyton3', 'py3' ],
+ 'R' => [],
+ 'Razor' => [],
+ 'RDoc' => [],
+ 'RHTML' => [], // HTML with Rcode, not ruby
+ 'RST' => [ 'rst', 'rest', 'restructuredtext' ],
+ 'Ruby' => [ 'ruby', 'rb', 'duby' ],
+ 'Rust' => [ 'rust' ],
+ 'SASS' => [ 'sass' ],
+ 'SCAD' => [],
+ 'Scala' => [ 'scala' ],
+ 'Scheme' => [ 'scheme', 'scm' ],
+ 'SCSS' => [ 'scss' ],
+ 'SH' => [ 'sh', 'bash', 'ksh', 'shell' ],
+ 'SJS' => [],
+ 'Smarty' => [ 'smarty', 'html+smarty' ],
+ 'snippets' => [],
+ 'Soy_Template' => [],
+ 'Space' => [],
+ 'SQL' => [ 'sql' ],
+ 'SQLServer' => [],
+ 'Stylus' => [],
+ 'SVG' => [],
+ 'Swift' => [ 'swift' ],
+ 'Tcl' => [ 'tcl' ],
+ 'Tex' => [ 'tex' ],
+ 'Text' => [ 'text' ],
+ 'Textile' => [],
+ 'Toml' => [],
+ 'Twig' => [ 'html+twig', 'twig' ],
+ 'Typescript' => [ 'typescript', 'ts' ],
+ 'Vala' => [ 'vala', 'vapi' ],
+ 'VBScript' => [],
+ 'Velocity' => [ 'velocity', 'html+velocity' ],
+ 'Verilog' => [ 'verilog', 'v', 'systemverilog', 'sv' ],
+ 'VHDL' => [ 'vhdl' ],
+ 'Wollok' => [],
+ 'XML' => [ 'xml' ],
+ 'XQuery' => [ 'xquery', 'xqy', 'xq', 'xql', 'xqm' ],
+ 'YAML' => [ 'yaml' ],
+ ];
+
+ public static function getPygmentsToAceMap() {
+ $result = [];
+ foreach ( self::$aceLexers as $aceName => $pygmentsLexers ) {
+ foreach ( $pygmentsLexers as $lexer ) {
+ if ( strcasecmp( $lexer, $aceName ) === 0 ) {
+ continue;
+ }
+ if ( !array_key_exists( $lexer, $result ) ) {
+ $result[ $lexer ] = $aceName;
+ }
+ }
+ }
+ return $result;
+ }
+}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightGeSHiCompat.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightGeSHiCompat.php
new file mode 100644
index 00000000..a6f38323
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/includes/SyntaxHighlightGeSHiCompat.php
@@ -0,0 +1,113 @@
+<?php
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+class SyntaxHighlightGeSHiCompat {
+ /** @var array A mapping of GeSHi lexer names to compatible Pygments lexers. */
+ private static $compatibleLexers = [
+ // Assembler
+ 'arm' => 'asm',
+ '6502acme' => 'asm',
+ '6502tasm' => 'asm',
+ '6502kickass' => 'asm',
+ '68000devpac' => 'asm',
+ 'dcpu16' => 'asm',
+ 'm68k' => 'asm',
+ 'mmix' => 'nasm',
+ 'mpasm' => 'asm',
+ 'pic16' => 'asm',
+ 'z80' => 'asm',
+
+ // BASIC
+ 'xbasic' => 'basic',
+ 'thinbasic' => 'basic',
+ 'sdlbasic' => 'basic',
+ 'purebasic' => 'basic',
+ 'mapbasic' => 'basic',
+ 'locobasic' => 'basic',
+ 'gwbasic' => 'basic',
+ 'freebasic' => 'basic',
+ 'basic4gl' => 'basic',
+ 'zxbasic' => 'basic',
+ 'gambas' => 'basic',
+ 'oobas' => 'basic',
+ 'bascomavr' => 'basic',
+
+ // C / C++
+ 'c_loadrunner' => 'c',
+ 'c_mac' => 'c',
+ 'c_winapi' => 'c',
+ 'upc' => 'c',
+ 'cpp-qt' => 'cpp',
+ 'cpp-winapi' => 'cpp',
+ 'urbi' => 'cpp',
+
+ // HTML
+ 'html4strict' => 'html',
+ 'html5' => 'html',
+
+ // JavaScript
+ 'jquery' => 'javascript',
+ 'ecmascript' => 'javascript',
+
+ // Microsoft
+ 'vb' => 'vbnet',
+ 'asp' => 'aspx-vb',
+ 'visualfoxpro' => 'foxpro',
+ 'dos' => 'bat',
+ 'visualprolog' => 'prolog',
+ 'reg' => 'registry',
+
+ // Miscellaneous
+ 'cadlisp' => 'lisp',
+ 'java5' => 'java',
+ 'php-brief' => 'php',
+ 'povray' => 'pov',
+ 'pys60' => 'python',
+ 'rails' => 'ruby',
+ 'rpmspec' => 'spec',
+ 'rsplus' => 'splus',
+ 'gettext' => 'pot',
+
+ // ML
+ 'ocaml-brief' => 'ocaml',
+ 'standardml' => 'sml',
+
+ // Modula 2
+ 'modula3' => 'modula2',
+ 'oberon2' => 'modula2',
+
+ // SQL
+ 'dcl' => 'sql',
+ 'plsql' => 'sql',
+ 'oracle11' => 'sql',
+ 'oracle8' => 'sql',
+
+ // REXX
+ 'oorexx' => 'rexx',
+ 'netrexx' => 'rexx',
+
+ // xpp is basically Java
+ 'xpp' => 'java',
+
+ // apt
+ 'apt_sources' => 'debsources',
+ ];
+
+ public static function getGeSHiToPygmentsMap() {
+ return self::$compatibleLexers;
+ }
+}
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateCSS.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateCSS.php
index ce953cb6..56bf7350 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateCSS.php
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateCSS.php
@@ -22,7 +22,7 @@
* @ingroup Maintenance
*/
-use Symfony\Component\Process\ProcessBuilder;
+use MediaWiki\Shell\Shell;
$IP = getenv( 'MW_INSTALL_PATH' ) ?: __DIR__ . '/../../..';
@@ -32,6 +32,8 @@ class UpdateCSS extends Maintenance {
public function __construct() {
parent::__construct();
+
+ $this->requireExtension( 'SyntaxHighlight' );
$this->addDescription( 'Generate CSS code for SyntaxHighlight_GeSHi' );
}
@@ -39,22 +41,20 @@ class UpdateCSS extends Maintenance {
$target = __DIR__ . '/../modules/pygments.generated.css';
$css = "/* Stylesheet generated by updateCSS.php */\n";
- $builder = new ProcessBuilder();
- $builder->setPrefix( SyntaxHighlight_GeSHi::getPygmentizePath() );
-
- $process = $builder
- ->add( '-f' )->add( 'html' )
- ->add( '-S' )->add( 'default' )
- ->add( '-a' )->add( '.' . SyntaxHighlight::HIGHLIGHT_CSS_CLASS )
- ->getProcess();
-
- $process->run();
+ $result = Shell::command(
+ SyntaxHighlight::getPygmentizePath(),
+ '-f', 'html',
+ '-S', 'default',
+ '-a', '.' . SyntaxHighlight::HIGHLIGHT_CSS_CLASS
+ )
+ ->restrict( Shell::RESTRICT_DEFAULT | Shell::NO_NETWORK )
+ ->execute();
- if ( !$process->isSuccessful() ) {
- throw new \RuntimeException( $process->getErrorOutput() );
+ if ( $result->getExitCode() != 0 ) {
+ throw new \RuntimeException( $result->getStderr() );
}
- $css .= $process->getOutput();
+ $css .= $result->getStdout();
if ( file_put_contents( $target, $css ) === false ) {
$this->output( "Failed to write to {$target}\n" );
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateLexerList.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateLexerList.php
index 00ee8a43..1937d856 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateLexerList.php
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/maintenance/updateLexerList.php
@@ -22,15 +22,17 @@
* @ingroup Maintenance
*/
-use Symfony\Component\Process\ProcessBuilder;
+use MediaWiki\Shell\Shell;
$IP = getenv( 'MW_INSTALL_PATH' ) ?: __DIR__ . '/../../..';
require_once "$IP/maintenance/Maintenance.php";
-class UpdateLanguageList extends Maintenance {
+class UpdateLexerList extends Maintenance {
public function __construct() {
parent::__construct();
+
+ $this->requireExtension( 'SyntaxHighlight' );
$this->addDescription( 'Update list of lexers supported by SyntaxHighlight_GeSHi' );
}
@@ -43,17 +45,18 @@ class UpdateLanguageList extends Maintenance {
$lexers = [];
- $builder = new ProcessBuilder();
- $builder->setPrefix( SyntaxHighlight_GeSHi::getPygmentizePath() );
-
- $process = $builder->add( '-L' )->add( 'lexer' )->getProcess();
- $process->run();
+ $result = Shell::command(
+ SyntaxHighlight::getPygmentizePath(),
+ '-L', 'lexer'
+ )
+ ->restrict( Shell::RESTRICT_DEFAULT | Shell::NO_NETWORK )
+ ->execute();
- if ( !$process->isSuccessful() ) {
- throw new \RuntimeException( $process->getErrorOutput() );
+ if ( $result->getExitCode() != 0 ) {
+ throw new \RuntimeException( $result->getStderr() );
}
- $output = $process->getOutput();
+ $output = $result->getStdout();
foreach ( explode( "\n", $output ) as $line ) {
if ( substr( $line, 0, 1 ) === '*' ) {
$newLexers = explode( ', ', trim( $line, "* :\n" ) );
@@ -72,5 +75,5 @@ class UpdateLanguageList extends Maintenance {
}
}
-$maintClass = 'UpdateLanguageList';
+$maintClass = 'UpdateLexerList';
require_once RUN_MAINTENANCE_IF_MAIN;
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/pygments.wrapper.css b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/pygments.wrapper.css
index 50cfa19d..5588b415 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/pygments.wrapper.css
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/pygments.wrapper.css
@@ -48,6 +48,7 @@ div.mw-hightlight {
-moz-user-select: none;
-webkit-user-select: none;
-ms-user-select: none;
+ user-select: none;
}
/* To interact better with the 'display: block' above, doesn't affect other uses */
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.css b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.css
index d4c4a2b2..de51edd5 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.css
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialog.css
@@ -10,7 +10,8 @@
}
.ve-ui-mwSyntaxHighlightDialog-content .ve-ui-mwExtensionWindow-input textarea {
- font-family: monospace, 'Courier';
+ /* T176636 */
+ font-family: monospace, monospace;
}
.ve-ui-mwSyntaxHighlightDialog-content .ve-ui-mwSyntaxHighlightWindow-languageField,
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialogTool.js b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialogTool.js
index dbc75169..e91e35f4 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialogTool.js
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightDialogTool.js
@@ -20,7 +20,7 @@ ve.ui.MWSyntaxHighlightDialogTool = function VeUiMWSyntaxHighlightDialogTool() {
OO.inheritClass( ve.ui.MWSyntaxHighlightDialogTool, ve.ui.FragmentWindowTool );
ve.ui.MWSyntaxHighlightDialogTool.static.name = 'syntaxhighlightDialog';
ve.ui.MWSyntaxHighlightDialogTool.static.group = 'object';
-ve.ui.MWSyntaxHighlightDialogTool.static.icon = 'alienextension';
+ve.ui.MWSyntaxHighlightDialogTool.static.icon = 'markup';
ve.ui.MWSyntaxHighlightDialogTool.static.title = OO.ui.deferMsg(
'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title' );
ve.ui.MWSyntaxHighlightDialogTool.static.modelClasses = [ ve.dm.MWBlockSyntaxHighlightNode ];
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.css b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.css
index e03c48fa..32ff1c0b 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.css
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspector.css
@@ -6,7 +6,8 @@
*/
.ve-ui-mwSyntaxHighlightInspector-content .ve-ui-mwExtensionWindow-input textarea {
- font-family: monospace, 'Courier';
+ /* T176636 */
+ font-family: monospace, monospace;
}
.ve-ui-mwSyntaxHighlightInspector-content .oo-ui-numberInputWidget {
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspectorTool.js b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspectorTool.js
index 2eb42d6d..47e26f16 100644
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspectorTool.js
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/modules/ve-syntaxhighlight/ve.ui.MWSyntaxHighlightInspectorTool.js
@@ -20,7 +20,7 @@ ve.ui.MWSyntaxHighlightInspectorTool = function VeUiMWSyntaxHighlightInspectorTo
OO.inheritClass( ve.ui.MWSyntaxHighlightInspectorTool, ve.ui.FragmentInspectorTool );
ve.ui.MWSyntaxHighlightInspectorTool.static.name = 'syntaxhighlightInspector';
ve.ui.MWSyntaxHighlightInspectorTool.static.group = 'object';
-ve.ui.MWSyntaxHighlightInspectorTool.static.icon = 'alienextension';
+ve.ui.MWSyntaxHighlightInspectorTool.static.icon = 'markup';
ve.ui.MWSyntaxHighlightInspectorTool.static.title = OO.ui.deferMsg(
'syntaxhighlight-visualeditor-mwsyntaxhighlightinspector-title' );
ve.ui.MWSyntaxHighlightInspectorTool.static.modelClasses = [ ve.dm.MWInlineSyntaxHighlightNode ];
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/create_pygmentize_bundle b/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/create_pygmentize_bundle
index c6366a2e..d69fa690 100755
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/create_pygmentize_bundle
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/create_pygmentize_bundle
@@ -1,26 +1,22 @@
-#!/usr/bin/env python
+#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Create a standalone, executable 'pygmentize' bundle.
Author: Ori Livneh
"""
-import sys
-reload(sys)
-sys.setdefaultencoding('utf-8')
-
import hashlib
import io
import os
import stat
import textwrap
-import urllib2
-import xmlrpclib
+import urllib.request
+import xmlrpc.client
import zipfile
-PYGMENTIZE_LAUNCHER = textwrap.dedent(b'''\
- #!/usr/bin/env python
+PYGMENTIZE_LAUNCHER = textwrap.dedent('''\
+ #!/usr/bin/env python3
import sys
import pygments.cmdline
@@ -32,7 +28,7 @@ PYGMENTIZE_LAUNCHER = textwrap.dedent(b'''\
print('Querying PyPI for the latest Pygments release...')
-pypi = xmlrpclib.ServerProxy('https://pypi.python.org/pypi')
+pypi = xmlrpc.client.ServerProxy('https://pypi.python.org/pypi')
latest_version = pypi.package_releases('Pygments')[0]
for release in pypi.release_urls('Pygments', latest_version):
if (release['packagetype'] == 'bdist_wheel' and
@@ -44,7 +40,7 @@ for release in pypi.release_urls('Pygments', latest_version):
raise RuntimeError('No suitable package found.')
print('Retrieving version %s (%s)...' % (latest_version, url))
-req = urllib2.urlopen(url)
+req = urllib.request.urlopen(url)
buf = io.BytesIO(req.read())
print('Verifying...')
@@ -58,8 +54,8 @@ with zipfile.ZipFile(buf, 'a') as zf:
data = buf.getvalue()
script_dir = os.path.dirname(os.path.abspath(__file__))
file_path = os.path.join(script_dir, 'pygmentize')
-with open(file_path, 'w') as f:
- f.write('#!/usr/bin/env python\n')
+with open(file_path, 'wb') as f:
+ f.write(b'#!/usr/bin/env python3\n')
f.write(data)
file_st = os.stat(file_path)
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/pygmentize b/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/pygmentize
index 8b1e9dac..b02e4c7f 100755
--- a/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/pygmentize
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/pygments/pygmentize
Binary files differ
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/tests/parser/parserTests.txt b/www/wiki/extensions/SyntaxHighlight_GeSHi/tests/parser/parserTests.txt
new file mode 100644
index 00000000..8326964f
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/tests/parser/parserTests.txt
@@ -0,0 +1,168 @@
+!! hooks
+source
+!! endhooks
+
+!! test
+Non-existent language
+!!input
+<source lang="doesnotexist">
+foobar
+</source>
+!! result
+<div class="mw-highlight mw-content-ltr" dir="ltr"><pre>foobar</pre></div>
+
+!! end
+
+!! test
+No language specified
+!! wikitext
+<source>
+foo
+</source>
+!! html
+<div class="mw-highlight mw-content-ltr" dir="ltr"><pre>foo</pre></div>
+
+!! end
+
+!! test
+No language specified (no wellformed xml)
+!! config
+!! wikitext
+<source>
+bar
+</source>
+!! html
+<div class="mw-highlight mw-content-ltr" dir="ltr"><pre>bar</pre></div>
+
+!! end
+
+!! test
+XSS is escaped
+!!input
+<source lang="doesnotexist">
+<script>alert("pwnd")</script>
+<IMG SRC=`javascript:alert("RSnake says, 'XSS'")`>
+<IMG
+SRC=&#106;&#97;&#118;&#97;&#115;&#99;&#114;&#105;&#112;&#116;&#58;&#97;&#108;&#101;&#114;&#116;&#40;
+&#39;&#88;&#83;&#83;&#39;&#41;
+\";alert('XSS');//
+</script><script>alert('XSS');</script>
+%253cscript%253ealert(document.cookie)%253c/script%253e
+</source>
+!! result
+<div class="mw-highlight mw-content-ltr" dir="ltr"><pre>&lt;script>alert("pwnd")&lt;/script>
+&lt;IMG SRC=`javascript:alert("RSnake says, 'XSS'")`>
+&lt;IMG
+SRC=&amp;#106;&amp;#97;&amp;#118;&amp;#97;&amp;#115;&amp;#99;&amp;#114;&amp;#105;&amp;#112;&amp;#116;&amp;#58;&amp;#97;&amp;#108;&amp;#101;&amp;#114;&amp;#116;&amp;#40;
+&amp;#39;&amp;#88;&amp;#83;&amp;#83;&amp;#39;&amp;#41;
+\";alert('XSS');//
+&lt;/script>&lt;script>alert('XSS');&lt;/script>
+%253cscript%253ealert(document.cookie)%253c/script%253e</pre></div>
+
+!! end
+
+!! test
+XSS is escaped (inline)
+!!input
+<source lang="doesnotexist" inline>
+<script>alert("pwnd")</script>
+<IMG SRC=`javascript:alert("RSnake says, 'XSS'")`>
+<IMG
+SRC=&#106;&#97;&#118;&#97;&#115;&#99;&#114;&#105;&#112;&#116;&#58;&#97;&#108;&#101;&#114;&#116;&#40;
+&#39;&#88;&#83;&#83;&#39;&#41;
+\";alert('XSS');//
+</script><script>alert('XSS');</script>
+%253cscript%253ealert(document.cookie)%253c/script%253e
+</source>
+!! result
+<p><code class="mw-highlight" dir="ltr">&lt;script&gt;alert("pwnd")&lt;/script&gt; &lt;IMG SRC=`javascript:alert("RSnake says, 'XSS'")`&gt; &lt;IMG SRC=&amp;#106;&amp;#97;&amp;#118;&amp;#97;&amp;#115;&amp;#99;&amp;#114;&amp;#105;&amp;#112;&amp;#116;&amp;#58;&amp;#97;&amp;#108;&amp;#101;&amp;#114;&amp;#116;&amp;#40; &amp;#39;&amp;#88;&amp;#83;&amp;#83;&amp;#39;&amp;#41; \";alert('XSS');// &lt;/script&gt;&lt;script&gt;alert('XSS');&lt;/script&gt;&#160;%253cscript%253ealert(document.cookie)%253c/script%253e</code>
+</p>
+!! end
+
+!! test
+Default behaviour (inner is pre)
+!!input
+<source lang="javascript">
+var a;
+</source>
+!! result
+<div class="mw-highlight mw-content-ltr" dir="ltr"><pre><span></span><span class="kd">var</span> <span class="nx">a</span><span class="p">;</span>
+</pre></div>
+
+!! end
+
+!! test
+Multiline <source/> in lists
+!!input
+* <source>a
+b</source>
+
+* foo <source>a
+b</source>
+!! html
+<ul><li><div class="mw-highlight mw-content-ltr" dir="ltr"><pre>a
+b</pre></div></li></ul>
+<ul><li>foo <div class="mw-highlight mw-content-ltr" dir="ltr"><pre>a
+b</pre></div></li></ul>
+
+!! html+tidy
+<ul><li><div class="mw-highlight mw-content-ltr" dir="ltr"><pre>a
+b</pre></div></li></ul>
+<ul><li>foo <div class="mw-highlight mw-content-ltr" dir="ltr"><pre>a
+b</pre></div></li></ul>
+!! end
+
+!! test
+Custom attributes
+!!input
+<source lang="javascript" id="foo" class="bar" dir="rtl" style="font-size: larger;">var a;</source>
+!! result
+<div id="foo" class="bar mw-highlight mw-content-rtl" dir="rtl" style="font-size: larger;"><pre><span></span><span class="kd">var</span> <span class="nx">a</span><span class="p">;</span>
+</pre></div>
+
+!! end
+
+!! test
+Inline attribute (inline code)
+!!input
+Text <source lang="javascript" inline>var a;</source>.
+!! result
+<p>Text <code class="mw-highlight" dir="ltr"><span class="kd">var</span> <span class="nx">a</span><span class="p">;</span></code>.
+</p>
+!! end
+
+!! test
+Enclose none (inline code)
+!!input
+Text <source lang="javascript" enclose="none">var a;</source>.
+!! result
+<p>Text <code class="mw-highlight" dir="ltr"><span class="kd">var</span> <span class="nx">a</span><span class="p">;</span></code>.
+</p>
+!! end
+
+!! test
+Enclose with nowiki
+!! input
+{{#tag:syntaxhighlight|<nowiki>foo</nowiki>|lang="text"|inline=none}}
+!! result
+<p><code class="mw-highlight" dir="ltr">foo</code>
+</p>
+!! end
+
+!! test
+No code
+!! input
+<source lang="CSharp"></source>
+!! result
+<div class="mw-highlight mw-content-ltr" dir="ltr"></div>
+
+!! end
+
+!! test
+Just whitespace
+!! input
+<source lang="CSharp"> </source>
+!! result
+<div class="mw-highlight mw-content-ltr" dir="ltr"></div>
+
+!! end
diff --git a/www/wiki/extensions/SyntaxHighlight_GeSHi/tests/phan/config.php b/www/wiki/extensions/SyntaxHighlight_GeSHi/tests/phan/config.php
new file mode 100644
index 00000000..6b93adce
--- /dev/null
+++ b/www/wiki/extensions/SyntaxHighlight_GeSHi/tests/phan/config.php
@@ -0,0 +1,6 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+$cfg['suppress_issue_types'][] = 'PhanDeprecatedClass';
+
+return $cfg;
diff --git a/www/wiki/extensions/TitleBlacklist/Gruntfile.js b/www/wiki/extensions/TitleBlacklist/Gruntfile.js
index e4033e51..26ca0c16 100644
--- a/www/wiki/extensions/TitleBlacklist/Gruntfile.js
+++ b/www/wiki/extensions/TitleBlacklist/Gruntfile.js
@@ -17,7 +17,8 @@ module.exports = function ( grunt ) {
jsonlint: {
all: [
'**/*.json',
- '!node_modules/**'
+ '!node_modules/**',
+ '!vendor/**'
]
}
} );
diff --git a/www/wiki/extensions/TitleBlacklist/composer.json b/www/wiki/extensions/TitleBlacklist/composer.json
index 021a14cb..b822010c 100644
--- a/www/wiki/extensions/TitleBlacklist/composer.json
+++ b/www/wiki/extensions/TitleBlacklist/composer.json
@@ -1,14 +1,23 @@
{
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
+ "jakub-onderka/php-parallel-lint": "1.0.0",
"jakub-onderka/php-console-highlighter": "0.3.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0"
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
- "fix": "phpcbf",
+ "fix": [
+ "phpcbf",
+ "minus-x fix ."
+ ],
"test": [
"parallel-lint . --exclude node_modules --exclude vendor",
- "phpcs -p -s"
+ "phpcs -p -s",
+ "minus-x check ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/TitleBlacklist/extension.json b/www/wiki/extensions/TitleBlacklist/extension.json
index c770dba3..75de9045 100644
--- a/www/wiki/extensions/TitleBlacklist/extension.json
+++ b/www/wiki/extensions/TitleBlacklist/extension.json
@@ -7,10 +7,10 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:TitleBlacklist",
"descriptionmsg": "titleblacklist-desc",
- "license-name": "GPL-2.0+",
+ "license-name": "GPL-2.0-or-later",
"type": "antispam",
"requires": {
- "MediaWiki": ">= 1.27.0"
+ "MediaWiki": ">= 1.29.0"
},
"GroupPermissions": {
"sysop": {
@@ -46,13 +46,13 @@
]
},
"AutoloadClasses": {
- "TitleBlacklist": "TitleBlacklist.list.php",
- "TitleBlacklistEntry": "TitleBlacklist.list.php",
- "TitleBlacklistHooks": "TitleBlacklist.hooks.php",
- "TitleBlacklistAuthenticationRequest": "TitleBlacklistAuthenticationRequest.php",
- "TitleBlacklistPreAuthenticationProvider": "TitleBlacklistPreAuthenticationProvider.php",
- "Scribunto_LuaTitleBlacklistLibrary": "TitleBlacklist.library.php",
- "ApiQueryTitleBlacklist": "api/ApiQueryTitleBlacklist.php"
+ "TitleBlacklist": "includes/TitleBlacklist.php",
+ "TitleBlacklistEntry": "includes/TitleBlacklistEntry.php",
+ "TitleBlacklistHooks": "includes/TitleBlacklistHooks.php",
+ "TitleBlacklistAuthenticationRequest": "includes/TitleBlacklistAuthenticationRequest.php",
+ "TitleBlacklistPreAuthenticationProvider": "includes/TitleBlacklistPreAuthenticationProvider.php",
+ "Scribunto_LuaTitleBlacklistLibrary": "includes/Scribunto_LuaTitleBlacklistLibrary.php",
+ "ApiQueryTitleBlacklist": "includes/api/ApiQueryTitleBlacklist.php"
},
"ResourceModules": {
"mediawiki.api.titleblacklist": {
@@ -67,7 +67,6 @@
"localBasePath": "modules",
"remoteExtPath": "TitleBlacklist/modules"
},
- "callback": "TitleBlacklistHooks::onRegistration",
"Hooks": {
"getUserPermissionsErrorsExpensive": [
"TitleBlacklistHooks::userCan"
@@ -99,5 +98,12 @@
},
"TitleBlacklistBlockAutoAccountCreation": true
},
+ "AuthManagerAutoConfig": {
+ "preauth": {
+ "TitleBlacklistPreAuthenticationProvider": {
+ "class": "TitleBlacklistPreAuthenticationProvider"
+ }
+ }
+ },
"manifest_version": 1
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/ais.json b/www/wiki/extensions/TitleBlacklist/i18n/ais.json
index b2e29965..cfe685c9 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/ais.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/ais.json
@@ -1,8 +1,31 @@
{
"@metadata": {
"authors": [
- "Benel"
+ "Benel",
+ "Bunukwiki"
]
},
- "titleblacklist-override": "sekipo malangat piazihan tu sulit"
+ "action-titleblacklistlog": "ciwsace satangahan malangat piazihan-tu-sulit nasulitan-nazipa’an",
+ "log-description-titleblacklist": "tina belih misult tu sacahamin matatungus satangahan malangat piazihan-tu-sulit a sikawaw.",
+ "logentry-titleblacklist-hit-username": "$1 mitanam panganganen ku canghaw $3 sa {{GENDER:$2|matebing}} matatungus sakacucek $4 ku tangan malangat piazihan tu sulit sikawaw.",
+ "titleblacklist-desc": "mahasa mikuwanay kapah misaungay [[MediaWiki:Titleblacklist|milangat piazihan-tu-sulit]] atu [[MediaWiki:Titlewhitelist|mahasa piazihan-tu-sulit]] ngay satezep patizeng kasabelih atu misaungayay canghaw.",
+ "titleblacklist": "# tina kasabilih sa u satangahanay nu malangat piazihan-tu-sulit, matatungus tina tatungusay pakatineng a zateng a satangahan atu misaungayay apasatezep misaungay.\n# buhci tu kamu pisaungay \"#\".\n# piazihan-tu-sulit pataayaw tu kawaw malecad ku tabakiay atu adidi’ay nu sulit-bacu",
+ "titlewhitelist": "# tina kasabelih satangahan mahasa piazihan tu sulit buhci tu kamu ka pisaungay \"#\".\n# piazihan tu sulit pataayaw tu kawaw caay kasasizuma ku tabakiay atu adidi’ay a sulit",
+ "titleblacklist-forbidden-edit": "pyawti \"$2\" masatezep tu ku pisaungay.\nyapyawti matatungus isasa’ malangat ku piazihan tu sulit tu kasacacay: <code>$1</code>",
+ "titleblacklist-forbidden-move": "satangahan \"$3\" masatezep tuway misaungay, la’cus milimad \"$2\" tayza \"$3\". \nkya satangahan matatungus isasa’ay malangatay a piazihan-tu-sulit kasacacay:<code>$1</code>",
+ "titleblacklist-forbidden-upload": "tangan kalungangan \"$2\" mapasatezep tuway pisaungay.\nkya kalungangan matatungus isasa’ay a malangat piazihan tu sulit kasacacay: code>$1</code>",
+ "titleblacklist-forbidden-new-account": "misaungayay a kalungangan \"$2\" mapasatezep tu ku pisaungay.\nu kalungangan matatungus tu zikuz malangat piazihan tu sulit nu kasacacay:<code>$1</code>",
+ "titleblacklist-invalid": "satangahan malangat piazihan tu sulit labu’ay isasa’ay {{PLURAL:$1|cacay silsil|yadah silsil}} la’cus; taayaw misuped kapisumad henay:",
+ "titleblacklist-override": "sekipo malangat piazihan tu sulit",
+ "titleblacklist-override-help": "mataneng tu ku tungus a situngusay kapah tu misetin ciniza misekipo satangahan kakaian tademaw kinsa.",
+ "titleblacklist-warning": "<strong> patalaw: tina kasabelih matatungus isasa’ay a satangahan malangat piazihan-tu-sulit kasacacay, kapah a dada’ nay mikuwanay saca izaway <code>tboverride</code> tungus a misaungayay mikawaway-kalumyiti: </strong><br /><code>$1</code>",
+ "right-tboverride": "mitahpu satangahan saca misaungayay a kalungangan kakaian tademaw",
+ "right-tboverride-account": "mitahpu misaungayay a kalungangan kakaian tademaw",
+ "right-titleblacklistlog": "satangahan milangat piazihan-tu-sulit nasulitan-nazipa’an",
+ "apihelp-titleblacklist-param-title": "amipacyinyin milangat piazihan-tu-sulit a sulisulitan.",
+ "apihelp-titleblacklist-param-action": "a mikinsaay a pisaungay.",
+ "apihelp-titleblacklist-param-nooverride": "amana mitanam mitahpu satangahan malangat piazihan-tu-sulit.",
+ "apihelp-titleblacklist-example-1": "kinsa [[Foo]] pasilsil tu malangatay kalungangan",
+ "apihelp-titleblacklist-example-2": "kinsa [[Bar]] pasilsil tu haw mikawaway-kalumyiti malangatay a kalungangan",
+ "apihelp-createaccount-param-ignoretitleblacklist": "takud han pahengad kinsa(maydih isasa’ay cacay a tungus:<code>tboverride</code>, <code>tboverride-account</code>)"
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/bg.json b/www/wiki/extensions/TitleBlacklist/i18n/bg.json
index d8b3ce42..ea74223c 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/bg.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/bg.json
@@ -4,19 +4,23 @@
"Borislav",
"DCLXVI",
"Spiritia",
- "Termininja"
+ "Termininja",
+ "ShockD",
+ "StanProg"
]
},
"log-name-titleblacklist": "Дневник на черния списък на заглавията",
+ "log-description-titleblacklist": "Тези събития следят съвпаденията с черния списък на заглавия.",
+ "logentry-titleblacklist-hit-username": "$1 {{GENDER:$2|предизвика}} съвпадение с черния списък на заглавията, опитвайки се да създаде сметка $3, съвпадаща с $4.",
"titleblacklist-desc": "Позволява на администраторите да забраняват създаването на страници и потребителски сметки чрез [[MediaWiki:Titleblacklist|черен]] и [[MediaWiki:Titlewhitelist|бял списък]].",
"titleblacklist": "# Страницата съдържа черен списък за заглавия на страници\n# Страници и потребители, чиито имена съответстват с регулярните изрази в списъка, не могат да бъдат създавани.\n# За коментари се използва символът „#“.",
"titlewhitelist": "# Това е бял списък на заглавията. Използвайте \"#\" за въвеждане на коментари.\n# По подразбиране списъкът е нечувствителен на малки и главни букви",
- "titleblacklist-forbidden-edit": "Страницата \"$2\" не може да бъде създадена, тъй като съвпада със запис от черния списък: <code>$1</code>",
- "titleblacklist-forbidden-move": "Страницата \"$2\" не може да бъде преместена като \"$3\", тъй като съвпада със запис от черния списък: <code>$1</code>",
- "titleblacklist-forbidden-upload": "Файлът \"$2\" не може да бъде качен, тъй като съвпада със запис от черния списък: <code>$1</code>",
+ "titleblacklist-forbidden-edit": "Страницата „$2“ не може да бъде създадена, тъй като съвпада със запис от черния списък: <code>$1</code>",
+ "titleblacklist-forbidden-move": "Страницата „$2“ не може да бъде преместена като „$3“, тъй като съвпада със запис от черния списък: <code>$1</code>",
+ "titleblacklist-forbidden-upload": "Файлът „$2“ не може да бъде качен, тъй като съвпада със запис от черния списък: <code>$1</code>",
"titleblacklist-forbidden-new-account": "Забранено е създаването на потребителско име „$2“.\nТо отговаря на следния запис от черния списък: <code>$1</code>",
"titleblacklist-invalid": "{{PLURAL:$1|Следният ред|Следните редове}} от черния списък на заглавията {{PLURAL:$1|е невалиден|са невалидни}} и трябва да {{PLURAL:$1|бъде коригиран|бъдат коригирани}} преди съхранение:",
"titleblacklist-override": "Игнорирай черния списък",
- "titleblacklist-warning": "<strong>Внимание: Тази страница може да бъде редактирана само от администратори и други потребители с <code>tboverride</code> права защото съвпада със следния запис от \"черния списък\":</strong><br /><code>$1</code>",
- "right-tboverride": "Презаписване върху черния списък на заглавията"
+ "titleblacklist-warning": "<strong>Внимание: Тази страница може да бъде редактирана само от администратори и други потребители с <code>tboverride</code> права защото съвпада със следния запис от „черния списък“:</strong><br /><code>$1</code>",
+ "right-tboverride": "Игнориране на черния списък на страници и участници"
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/de.json b/www/wiki/extensions/TitleBlacklist/i18n/de.json
index b7cbeae8..9b089ca7 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/de.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/de.json
@@ -11,7 +11,8 @@
"The Evil IP address",
"Umherirrender",
"Wnme",
- "MGChecker"
+ "MGChecker",
+ "Debenben"
]
},
"action-titleblacklistlog": "das Titel-Blacklist-Logbuch anzusehen",
@@ -33,6 +34,7 @@
"right-tboverride-account": "Die schwarze Liste unerwünschter Benutzernamen außer Kraft setzen",
"right-titleblacklistlog": "Das Titel-Blacklist-Logbuch ansehen",
"apihelp-titleblacklist-description": "Überprüft einen Seiten-, Datei- oder Benutzernamen gegen die Titel-Blacklist.",
+ "apihelp-titleblacklist-summary": "Überprüft einen Seiten-, Datei- oder Benutzernamen gegen die Titel-Blacklist.",
"apihelp-titleblacklist-param-title": "Die Zeichenfolge, die gegen die Blacklist geprüft werden soll.",
"apihelp-titleblacklist-param-action": "Die zu überprüfende Aktion.",
"apihelp-titleblacklist-param-nooverride": "Nicht versuchen, die Titel-Blacklist zu überschreiben.",
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/fa.json b/www/wiki/extensions/TitleBlacklist/i18n/fa.json
index 85be910a..8fa29b64 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/fa.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/fa.json
@@ -28,5 +28,8 @@
"titleblacklist-warning": "<strong>هشدار: این صفحه فقط توسط مدیران سیستم و کاربرانی که مجوز <code>tboverride</code> دارند قابل ویرایش شدن است؛ چون صفحه منطبق با لیست‌سیاه زیر است: </strong><br /><code>$1</code>",
"right-tboverride": "نادیده گرفتن لیست سیاه عنوان یا نام کاربری",
"right-tboverride-account": "لغو فهرست سیاه نام کاربری",
- "right-titleblacklistlog": "مشاهدۀ سیاهۀ لیست سیاه عنوان"
+ "right-titleblacklistlog": "مشاهدۀ سیاهۀ لیست سیاه عنوان",
+ "apihelp-titleblacklist-param-nooverride": "سعی نکن فهرست‌سیاه‌نام را بازنویسی کنی",
+ "apihelp-titleblacklist-example-1": "بررسی اینکه آیا [[Foo]] در فهرست سیاه هست یا نه",
+ "apihelp-titleblacklist-example-2": "بررسی اینکه آیا [[Bar]] در فهرست سیاه ویرایش هست یا نه"
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/ja.json b/www/wiki/extensions/TitleBlacklist/i18n/ja.json
index df0ad7e9..6ef773b1 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/ja.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/ja.json
@@ -12,7 +12,8 @@
"Whym",
"Sujiniku",
"2nd-player",
- "Otokoume"
+ "Otokoume",
+ "Yusuke1109"
]
},
"action-titleblacklistlog": "ページ名ブラックリストの記録の閲覧",
@@ -32,7 +33,9 @@
"right-tboverride": "ページ名/利用者名のブラックリストによる制限を受けない",
"right-tboverride-account": "利用者名ブラックリストを無視",
"right-titleblacklistlog": "ページ名ブラックリストの記録を閲覧",
- "apihelp-titleblacklist-description": "TitleBllacklist に対して記事のページ名、ファイル名、利用者名を検証します。",
+ "apihelp-titleblacklist-description": "TitleBllacklist に対してページ名、ファイル名、利用者名を検証します。",
"apihelp-titleblacklist-param-action": "確認対象の操作",
+ "apihelp-titleblacklist-param-nooverride": "titleblacklistを上書きしようとしないでください。",
+ "apihelp-titleblacklist-example-1": "[[Foo]]がブラックリストに載っているかどうかを確認する",
"apihelp-createaccount-param-ignoretitleblacklist": "なりすましチェックを無視する (<code>tboverride</code> または <code>tboverride-account</code> の権限が必要)。"
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/roa-tara.json b/www/wiki/extensions/TitleBlacklist/i18n/roa-tara.json
index f4746452..b21f7287 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/roa-tara.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/roa-tara.json
@@ -7,6 +7,7 @@
"action-titleblacklistlog": "'ndruche 'u titole de l'archivije de l'elenghe gnure",
"log-name-titleblacklist": "Archivije de le titole bloccate",
"log-description-titleblacklist": "Ste evende tracciane le trasute jndr'à l'elenghe gnure de le rummate.",
+ "logentry-titleblacklist-hit-username": "$1 {{GENDER:$2|ave causate}} l'attivazzione d'a lista gnore de le titole pruvanne a ccrejà 'u cunde $3 ca corrisponne a $4.",
"titleblacklist-desc": "Permette a l'amministrature de vietà ccrejaziune de le pàggene e le cunde utinde pe 'na [[MediaWiki:Titleblacklist|lista gnore]] e [[MediaWiki:Titlewhitelist|lista vianghe]]",
"titleblacklist": "# Stu titele jè in lista gnore. Le titele e l'utinde ca se ponne comborndà cu le espressiune regolare aqquà non ge ponne essere ccrejate.\n# Ause \"#\" pe le commende.\n# Quiste jè sensibbele a le maiuscole e le minuscole de partenze",
"titlewhitelist": "# Stu titele jè in lista vianghe.\n# Ause \"#\" pe le commende.\n# Quiste jè sensibbele a le maiuscole e le minuscole de partenze",
@@ -16,8 +17,10 @@
"titleblacklist-forbidden-new-account": "'U nome de l'utende \"$2\" ha state escluse da 'a ccreiazione.<br />\nJidde se combronde cu le vosce d'a lista gnore: <code>$1</code>",
"titleblacklist-invalid": "{{PLURAL:$1|'A seguenda linèe|Le seguende linèe}} jndr'à lista gnore de le titele {{PLURAL:$1|jè|sonde}} invalide;\npe piacere corregge {{PLURAL:$1|jedde|lore}} apprime de reggistrà:",
"titleblacklist-override": "No scè penzanne 'a lista gnore",
+ "titleblacklist-override-help": "Le utinde cu le privilegge insufficiende ponne 'mbostà st'opzione pe cacà le condrolle de lista gnore sus a 'u titole.",
"right-tboverride": "Sovrascrive 'a lista gnore de le titole o de le utinde",
"right-tboverride-account": "Sovrasrive 'a lista gnore de le utinde",
"right-titleblacklistlog": "'Ndruche l'archivije de le titole jndr'à l'elenghe gnure",
- "apihelp-titleblacklist-param-action": "L'azione ha state verificate."
+ "apihelp-titleblacklist-param-action": "L'azione ha state verificate.",
+ "apihelp-titleblacklist-param-nooverride": "No pruvà a sovrascrivere l'elenghe de le titole da scettà."
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/ru.json b/www/wiki/extensions/TitleBlacklist/i18n/ru.json
index 44151308..ec03f4f0 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/ru.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/ru.json
@@ -8,7 +8,8 @@
"Kaganer",
"Александр Сигачёв",
"Okras",
- "NBS"
+ "NBS",
+ "Mouse21"
]
},
"action-titleblacklistlog": "просмотр журнала запрещённыx названий",
@@ -29,8 +30,12 @@
"right-tboverride": "игнорирование чёрного списка имён страниц или участников",
"right-tboverride-account": "игнорирование чёрного списка имён участников",
"right-titleblacklistlog": "просмотр журнала запрещённыx названий",
+ "apihelp-titleblacklist-description": "Подтвердите заголовок страницы, имя файла или имя пользователя в списке TitleBlacklist.",
+ "apihelp-titleblacklist-summary": "Подтвердите заголовок страницы, имя файла или имя пользователя в списке TitleBlacklist.",
+ "apihelp-titleblacklist-param-title": "Строка для проверки против черного списка.",
"apihelp-titleblacklist-param-action": "Действие, которое должно быть проверено.",
"apihelp-titleblacklist-param-nooverride": "Не пытайтесь переопределить список запрещённыx названий.",
"apihelp-titleblacklist-example-1": "Проверить, занесена ли статья [[Foo]] в чёрный список",
- "apihelp-titleblacklist-example-2": "Проверить, занесена ли статья [[Bar]] в чёрный список для редактирования"
+ "apihelp-titleblacklist-example-2": "Проверить, занесена ли статья [[Bar]] в чёрный список для редактирования",
+ "apihelp-createaccount-param-ignoretitleblacklist": "Игнорировать проверки подмены (требует одного из следующих прав: <code>tboverride</code>, <code>tboverride-account</code>)."
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/th.json b/www/wiki/extensions/TitleBlacklist/i18n/th.json
index 8ca5407c..a9c8556d 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/th.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/th.json
@@ -7,5 +7,6 @@
},
"titleblacklist-forbidden-edit": "ชื่อบทความ \"$2\" ถูกห้ามสร้างในระบบนี้\n\nชื่อหัวข้อนี้ตรงกับบัญชีดำในส่วนของ: <code>$1</code>",
"titleblacklist-forbidden-upload": "ไฟล์ชื่อ \"$2\" ถูกห้ามจากการสร้าง\nเนื่องจากตรงกับชื่อที่ปรากฎในบัญชีดำดังต่อไปนี้: <code>$1</code>",
- "titleblacklist-forbidden-new-account": "ชื่อผู้ใช้ \"$2\" ถูกห้ามจากการสร้าง\nเนื่องจากตรงกับชื่อที่ปรากฎในบัญชีดำดังต่อไปนี้: <code>$1</code>"
+ "titleblacklist-forbidden-new-account": "ชื่อผู้ใช้ \"$2\" ถูกห้ามจากการสร้าง\nเนื่องจากตรงกับชื่อที่ปรากฎในบัญชีดำดังต่อไปนี้: <code>$1</code>",
+ "right-titleblacklistlog": "ดูปูมบัญชีดำชื่อเรื่อง"
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/uk.json b/www/wiki/extensions/TitleBlacklist/i18n/uk.json
index ef1aa2fe..890d31b3 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/uk.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/uk.json
@@ -20,7 +20,7 @@
"titleblacklist": "# Це список заборонених назв. Сторінки і користувачі, назви яких підпадають під регулярні вирази з цього списку, не можуть бути створені.\n# Використовуйте \"#\" для коментарів.\n# Список за замовчуванням нечутливий до регістру",
"titlewhitelist": "# Це «білий список» назв. Використовуйте «#» для коментарів.\n# Список за замовчуванням нечутливий до регістру",
"titleblacklist-forbidden-edit": "Сторінку з назвою \"$2\" заборонено створювати. Вона підпадає під наступний запис із списку заборонених назв: <code>$1</code>",
- "titleblacklist-forbidden-move": "Не можна перейменувати \"$2\" на \"$3\", бо назва \"$3\" є забороненою.\nВона підпадає під наступний запис із списку заборонених назв: <code>$1</code>",
+ "titleblacklist-forbidden-move": "Неможливо перейменувати «$2» на «$3», бо назва «$3» є забороненою.\nВона підпадає під такий запис зі списку заборонених назв: <code>$1</code>",
"titleblacklist-forbidden-upload": "Назва файлу \"$2\" є забороненою для створення.\nВона підпадає під наступний запис із списку заборонених назв: <code>$1</code>",
"titleblacklist-forbidden-new-account": "Заборонено використовувати ім'я користувача «$2».\nІм'я відповідає наступному запису з чорного списку: <code>$1</code>",
"titleblacklist-invalid": "{{PLURAL:$1|1=Наступний рядок|Наступні рядки}} списку заборонених назв є {{PLURAL:$1|1=помилковим|помилковими}};\nбудь ласка, виправте {{PLURAL:$1|1=його|їх}} перед збереженням:",
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/ur.json b/www/wiki/extensions/TitleBlacklist/i18n/ur.json
index 3b9e3fd2..59cb912b 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/ur.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/ur.json
@@ -2,12 +2,13 @@
"@metadata": {
"authors": [
"පසිඳු කාවින්ද",
- "Muhammad Shuaib"
+ "Muhammad Shuaib",
+ "BukhariSaeed"
]
},
"action-titleblacklistlog": "عنوان کے نوشتۂ فہرست سیاہ کو دیکھنے",
"titleblacklist-override": "سیاہ فہرست کو نظر انداز کریں",
- "right-tboverride": "اس عنوان کے بلیک لسٹ کی جگہ لے لے",
+ "right-tboverride": "صارف ناموں یا عنوان کی بلیک لسٹ کی منسوخی",
"right-tboverride-account": "صارف ناموں کی سیاہ فہرست کی منسوخی",
"right-titleblacklistlog": "عنوان کے نوشتۂ فہرست سیاہ کا معائنہ"
}
diff --git a/www/wiki/extensions/TitleBlacklist/i18n/zh-hant.json b/www/wiki/extensions/TitleBlacklist/i18n/zh-hant.json
index 43e26014..0f879886 100644
--- a/www/wiki/extensions/TitleBlacklist/i18n/zh-hant.json
+++ b/www/wiki/extensions/TitleBlacklist/i18n/zh-hant.json
@@ -9,7 +9,8 @@
"Waihorace",
"Cwlin0416",
"Liuxinyu970226",
- "LNDDYL"
+ "LNDDYL",
+ "Hello903hello"
]
},
"action-titleblacklistlog": "檢視標題封鎖清單日誌",
@@ -30,7 +31,7 @@
"right-tboverride": "覆蓋標題或使用者名稱黑名單",
"right-tboverride-account": "覆蓋使用者名稱黑名單",
"right-titleblacklistlog": "檢視標題封鎖清單日誌",
- "apihelp-titleblacklist-description": "使用 TitleBlacklist 檢驗文章標題、檔案名稱或使用者名稱。",
+ "apihelp-titleblacklist-description": "檢驗一個頁面標題、檔案名稱或使用者名稱有否抵觸標題黑名單。",
"apihelp-titleblacklist-param-title": "要用來檢驗封鎖清單的字串。",
"apihelp-titleblacklist-param-action": "要檢查的操作。",
"apihelp-titleblacklist-param-nooverride": "不要嘗試覆蓋標題封鎖清單。",
diff --git a/www/wiki/extensions/TitleBlacklist/includes/Scribunto_LuaTitleBlacklistLibrary.php b/www/wiki/extensions/TitleBlacklist/includes/Scribunto_LuaTitleBlacklistLibrary.php
new file mode 100644
index 00000000..3ed4ce06
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/Scribunto_LuaTitleBlacklistLibrary.php
@@ -0,0 +1,35 @@
+<?php
+
+class Scribunto_LuaTitleBlacklistLibrary extends Scribunto_LuaLibraryBase {
+ public function register() {
+ $lib = [
+ 'test' => [ $this, 'test' ],
+ ];
+
+ return $this->getEngine()->registerInterface(
+ __DIR__ . '/mw.ext.TitleBlacklist.lua', $lib, []
+ );
+ }
+
+ public function test( $action = null, $title = null ) {
+ $this->checkType( 'mw.ext.TitleBlacklist.test', 1, $action, 'string' );
+ $this->checkTypeOptional( 'mw.ext.TitleBlacklist.test', 2, $title, 'string', '' );
+ $this->incrementExpensiveFunctionCount();
+ if ( $title == '' ) {
+ $title = $this->getParser()->mTitle->getPrefixedText();
+ }
+ $entry = TitleBlacklist::singleton()->isBlacklisted( $title, $action );
+ if ( $entry ) {
+ return [ [
+ 'params' => $entry->getParams(),
+ 'regex' => $entry->getRegex(),
+ 'raw' => $entry->getRaw(),
+ 'version' => $entry->getFormatVersion(),
+ 'message' => $entry->getErrorMessage( $action ),
+ 'custommessage' => $entry->getCustomMessage()
+ ] ];
+ }
+ return [ null ];
+ }
+
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklist.php b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklist.php
new file mode 100644
index 00000000..85f8ef77
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklist.php
@@ -0,0 +1,343 @@
+<?php
+/**
+ * Title Blacklist class
+ * @author Victor Vasiliev
+ * @copyright © 2007-2010 Victor Vasiliev et al
+ * @license GPL-2.0-or-later
+ * @file
+ */
+
+/**
+ * @ingroup Extensions
+ */
+
+/**
+ * Implements a title blacklist for MediaWiki
+ */
+class TitleBlacklist {
+ /** @var array */
+ private $mBlacklist = null;
+
+ /** @var array */
+ private $mWhitelist = null;
+
+ /** @var TitleBlacklist */
+ protected static $instance = null;
+
+ const VERSION = 3; // Blacklist format
+
+ /**
+ * Get an instance of this class
+ *
+ * @return TitleBlacklist
+ */
+ public static function singleton() {
+ if ( self::$instance === null ) {
+ self::$instance = new self;
+ }
+ return self::$instance;
+ }
+
+ /**
+ * Destroy/reset the current singleton instance.
+ *
+ * This is solely for testing and will fail unless MW_PHPUNIT_TEST is
+ * defined.
+ */
+ public static function destroySingleton() {
+ if ( !defined( 'MW_PHPUNIT_TEST' ) ) {
+ throw new MWException(
+ 'Can not invoke ' . __METHOD__ . '() ' .
+ 'out of tests (MW_PHPUNIT_TEST not set).'
+ );
+ }
+
+ self::$instance = null;
+ }
+
+ /**
+ * Load all configured blacklist sources
+ */
+ public function load() {
+ global $wgTitleBlacklistSources, $wgTitleBlacklistCaching;
+
+ $cache = ObjectCache::getMainWANInstance();
+ // Try to find something in the cache
+ $cachedBlacklist = $cache->get( wfMemcKey( "title_blacklist_entries" ) );
+ if ( is_array( $cachedBlacklist ) && count( $cachedBlacklist ) > 0
+ && ( $cachedBlacklist[0]->getFormatVersion() == self::VERSION )
+ ) {
+ $this->mBlacklist = $cachedBlacklist;
+ return;
+ }
+
+ $sources = $wgTitleBlacklistSources;
+ $sources['local'] = [ 'type' => 'message' ];
+ $this->mBlacklist = [];
+ foreach ( $sources as $sourceName => $source ) {
+ $this->mBlacklist = array_merge(
+ $this->mBlacklist,
+ $this->parseBlacklist( $this->getBlacklistText( $source ), $sourceName )
+ );
+ }
+ $cache->set( wfMemcKey( "title_blacklist_entries" ),
+ $this->mBlacklist, $wgTitleBlacklistCaching['expiry'] );
+ wfDebugLog( 'TitleBlacklist-cache', 'Updated ' . wfMemcKey( "title_blacklist_entries" )
+ . ' with ' . count( $this->mBlacklist ) . ' entries.' );
+ }
+
+ /**
+ * Load local whitelist
+ */
+ public function loadWhitelist() {
+ global $wgTitleBlacklistCaching;
+
+ $cache = ObjectCache::getMainWANInstance();
+ $cachedWhitelist = $cache->get( wfMemcKey( "title_whitelist_entries" ) );
+ if ( is_array( $cachedWhitelist ) && count( $cachedWhitelist ) > 0
+ && ( $cachedWhitelist[0]->getFormatVersion() != self::VERSION )
+ ) {
+ $this->mWhitelist = $cachedWhitelist;
+ return;
+ }
+ $this->mWhitelist = $this->parseBlacklist( wfMessage( 'titlewhitelist' )
+ ->inContentLanguage()->text(), 'whitelist' );
+ $cache->set( wfMemcKey( "title_whitelist_entries" ),
+ $this->mWhitelist, $wgTitleBlacklistCaching['expiry'] );
+ }
+
+ /**
+ * Get the text of a blacklist from a specified source
+ *
+ * @param array $source A blacklist source from $wgTitleBlacklistSources
+ * @return string The content of the blacklist source as a string
+ */
+ private static function getBlacklistText( $source ) {
+ if ( !is_array( $source ) || count( $source ) <= 0 ) {
+ return ''; // Return empty string in error case
+ }
+
+ if ( $source['type'] == 'message' ) {
+ return wfMessage( 'titleblacklist' )->inContentLanguage()->text();
+ } elseif ( $source['type'] == 'localpage' && count( $source ) >= 2 ) {
+ $title = Title::newFromText( $source['src'] );
+ if ( is_null( $title ) ) {
+ return '';
+ }
+ if ( $title->getNamespace() == NS_MEDIAWIKI ) {
+ $msg = wfMessage( $title->getText() )->inContentLanguage();
+ if ( !$msg->isDisabled() ) {
+ return $msg->text();
+ } else {
+ return '';
+ }
+ } else {
+ $page = WikiPage::factory( $title );
+ if ( $page->exists() ) {
+ return ContentHandler::getContentText( $page->getContent() );
+ }
+ }
+ } elseif ( $source['type'] == 'url' && count( $source ) >= 2 ) {
+ return self::getHttp( $source['src'] );
+ } elseif ( $source['type'] == 'file' && count( $source ) >= 2 ) {
+ if ( file_exists( $source['src'] ) ) {
+ return file_get_contents( $source['src'] );
+ } else {
+ return '';
+ }
+ }
+
+ return '';
+ }
+
+ /**
+ * Parse blacklist from a string
+ *
+ * @param string $list Text of a blacklist source
+ * @param string $sourceName
+ * @return array of TitleBlacklistEntry entries
+ */
+ public static function parseBlacklist( $list, $sourceName ) {
+ $lines = preg_split( "/\r?\n/", $list );
+ $result = [];
+ foreach ( $lines as $line ) {
+ $line = TitleBlacklistEntry::newFromString( $line, $sourceName );
+ if ( $line ) {
+ $result[] = $line;
+ }
+ }
+
+ return $result;
+ }
+
+ /**
+ * Check whether the blacklist restricts given user
+ * performing a specific action on the given Title
+ *
+ * @param Title $title Title to check
+ * @param User $user User to check
+ * @param string $action Action to check; 'edit' if unspecified
+ * @param bool $override If set to true, overrides work
+ * @return TitleBlacklistEntry|bool The corresponding TitleBlacklistEntry if
+ * blacklisted; otherwise false
+ */
+ public function userCannot( $title, $user, $action = 'edit', $override = true ) {
+ $entry = $this->isBlacklisted( $title, $action );
+ if ( !$entry ) {
+ return false;
+ }
+ $params = $entry->getParams();
+ if ( isset( $params['autoconfirmed'] ) && $user->isAllowed( 'autoconfirmed' ) ) {
+ return false;
+ }
+ if ( $override && self::userCanOverride( $user, $action ) ) {
+ return false;
+ }
+ return $entry;
+ }
+
+ /**
+ * Check whether the blacklist restricts
+ * performing a specific action on the given Title
+ *
+ * @param Title $title Title to check
+ * @param string $action Action to check; 'edit' if unspecified
+ * @return TitleBlacklistEntry|bool The corresponding TitleBlacklistEntry if blacklisted;
+ * otherwise FALSE
+ */
+ public function isBlacklisted( $title, $action = 'edit' ) {
+ if ( !( $title instanceof Title ) ) {
+ $title = Title::newFromText( $title );
+ if ( !( $title instanceof Title ) ) {
+ // The fact that the page name is invalid will stop whatever
+ // action is going through. No sense in doing more work here.
+ return false;
+ }
+ }
+ $blacklist = $this->getBlacklist();
+ $autoconfirmedItem = false;
+ foreach ( $blacklist as $item ) {
+ if ( $item->matches( $title->getFullText(), $action ) ) {
+ if ( $this->isWhitelisted( $title, $action ) ) {
+ return false;
+ }
+ $params = $item->getParams();
+ if ( !isset( $params['autoconfirmed'] ) ) {
+ return $item;
+ }
+ if ( !$autoconfirmedItem ) {
+ $autoconfirmedItem = $item;
+ }
+ }
+ }
+ return $autoconfirmedItem;
+ }
+
+ /**
+ * Check whether it has been explicitly whitelisted that the
+ * current User may perform a specific action on the given Title
+ *
+ * @param Title $title Title to check
+ * @param string $action Action to check; 'edit' if unspecified
+ * @return bool True if whitelisted; otherwise false
+ */
+ public function isWhitelisted( $title, $action = 'edit' ) {
+ if ( !( $title instanceof Title ) ) {
+ $title = Title::newFromText( $title );
+ }
+ $whitelist = $this->getWhitelist();
+ foreach ( $whitelist as $item ) {
+ if ( $item->matches( $title->getFullText(), $action ) ) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ /**
+ * Get the current blacklist
+ *
+ * @return TitleBlacklistEntry[]
+ */
+ public function getBlacklist() {
+ if ( is_null( $this->mBlacklist ) ) {
+ $this->load();
+ }
+ return $this->mBlacklist;
+ }
+
+ /**
+ * Get the current whitelist
+ *
+ * @return Array of TitleBlacklistEntry items
+ */
+ public function getWhitelist() {
+ if ( is_null( $this->mWhitelist ) ) {
+ $this->loadWhitelist();
+ }
+ return $this->mWhitelist;
+ }
+
+ /**
+ * Get the text of a blacklist source via HTTP
+ *
+ * @param string $url URL of the blacklist source
+ * @return string The content of the blacklist source as a string
+ */
+ private static function getHttp( $url ) {
+ global $messageMemc, $wgTitleBlacklistCaching;
+ $key = "title_blacklist_source:" . md5( $url ); // Global shared
+ $warnkey = wfMemcKey( "titleblacklistwarning", md5( $url ) );
+ $result = $messageMemc->get( $key );
+ $warn = $messageMemc->get( $warnkey );
+ if ( !is_string( $result )
+ || ( !$warn && !mt_rand( 0, $wgTitleBlacklistCaching['warningchance'] ) )
+ ) {
+ $result = Http::get( $url );
+ $messageMemc->set( $warnkey, 1, $wgTitleBlacklistCaching['warningexpiry'] );
+ $messageMemc->set( $key, $result, $wgTitleBlacklistCaching['expiry'] );
+ }
+ return $result;
+ }
+
+ /**
+ * Invalidate the blacklist cache
+ */
+ public function invalidate() {
+ $cache = ObjectCache::getMainWANInstance();
+ $cache->delete( wfMemcKey( "title_blacklist_entries" ) );
+ }
+
+ /**
+ * Validate a new blacklist
+ *
+ * @suppress PhanParamSuspiciousOrder The preg_match() params are in the correct order
+ * @param array $blacklist
+ * @return Array of bad entries; empty array means blacklist is valid
+ */
+ public function validate( $blacklist ) {
+ $badEntries = [];
+ foreach ( $blacklist as $e ) {
+ wfSuppressWarnings();
+ $regex = $e->getRegex();
+ if ( preg_match( "/{$regex}/u", '' ) === false ) {
+ $badEntries[] = $e->getRaw();
+ }
+ wfRestoreWarnings();
+ }
+ return $badEntries;
+ }
+
+ /**
+ * Inidcates whether user can override blacklist on certain action.
+ *
+ * @param User $user
+ * @param string $action Action
+ *
+ * @return bool
+ */
+ public static function userCanOverride( $user, $action ) {
+ return $user->isAllowed( 'tboverride' ) ||
+ ( $action == 'new-account' && $user->isAllowed( 'tboverride-account' ) );
+ }
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistAuthenticationRequest.php b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistAuthenticationRequest.php
new file mode 100644
index 00000000..928a60e0
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistAuthenticationRequest.php
@@ -0,0 +1,22 @@
+<?php
+
+use MediaWiki\Auth\AuthenticationRequest;
+
+/**
+ * An authentication request that allows users with sufficiently high privileges to skip the
+ * title blacklist check.
+ */
+class TitleBlacklistAuthenticationRequest extends AuthenticationRequest {
+ public $ignoreTitleBlacklist;
+
+ public function getFieldInfo() {
+ return [
+ 'ignoreTitleBlacklist' => [
+ 'type' => 'checkbox',
+ 'label' => wfMessage( 'titleblacklist-override' ),
+ 'help' => wfMessage( 'titleblacklist-override-help' ),
+ 'optional' => true,
+ ],
+ ];
+ }
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistEntry.php b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistEntry.php
new file mode 100644
index 00000000..57233680
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistEntry.php
@@ -0,0 +1,293 @@
+<?php
+/**
+ * Title Blacklist class
+ * @author Victor Vasiliev
+ * @copyright © 2007-2010 Victor Vasiliev et al
+ * @license GPL-2.0-or-later
+ * @file
+ */
+
+/**
+ * @ingroup Extensions
+ */
+
+/**
+ * Represents a title blacklist entry
+ */
+class TitleBlacklistEntry {
+ /**
+ * Raw line
+ * @var string
+ */
+ private $mRaw;
+
+ /**
+ * Regular expression to match
+ * @var string
+ */
+ private $mRegex;
+
+ /**
+ * Parameters for this entry
+ * @var array
+ */
+ private $mParams;
+
+ /**
+ * Entry format version
+ * @var string
+ */
+ private $mFormatVersion;
+
+ /**
+ * Source of this entry
+ * @var string
+ */
+ private $mSource;
+
+ /**
+ * Construct a new TitleBlacklistEntry.
+ *
+ * @param string $regex Regular expression to match
+ * @param array $params Parameters for this entry
+ * @param string $raw Raw contents of this line
+ */
+ private function __construct( $regex, $params, $raw, $source ) {
+ $this->mRaw = $raw;
+ $this->mRegex = $regex;
+ $this->mParams = $params;
+ $this->mFormatVersion = TitleBlacklist::VERSION;
+ $this->mSource = $source;
+ }
+
+ /**
+ * Returns whether this entry is capable of filtering new accounts.
+ */
+ private function filtersNewAccounts() {
+ global $wgTitleBlacklistUsernameSources;
+
+ if ( $wgTitleBlacklistUsernameSources === '*' ) {
+ return true;
+ }
+
+ if ( !$wgTitleBlacklistUsernameSources ) {
+ return false;
+ }
+
+ if ( !is_array( $wgTitleBlacklistUsernameSources ) ) {
+ throw new Exception(
+ '$wgTitleBlacklistUsernameSources must be "*", false or an array' );
+ }
+
+ return in_array( $this->mSource, $wgTitleBlacklistUsernameSources, true );
+ }
+
+ /**
+ * Check whether a user can perform the specified action on the specified Title
+ *
+ * @param string $title Title to check
+ * @param string $action Action to check
+ * @return bool TRUE if the the regex matches the title, and is not overridden
+ * else false if it doesn't match (or was overridden)
+ */
+ public function matches( $title, $action ) {
+ if ( $title == '' ) {
+ return false;
+ }
+
+ if ( $action === 'new-account' && !$this->filtersNewAccounts() ) {
+ return false;
+ }
+
+ if ( isset( $this->mParams['antispoof'] )
+ && is_callable( 'AntiSpoof::checkUnicodeString' )
+ ) {
+ if ( $action === 'edit' ) {
+ // Use process cache for frequently edited pages
+ $cache = ObjectCache::getMainWANInstance();
+ list( $ok, $norm ) = $cache->getWithSetCallback(
+ $cache->makeKey( 'titleblacklist', 'normalized-unicode', md5( $title ) ),
+ $cache::TTL_MONTH,
+ function () use ( $title ) {
+ return AntiSpoof::checkUnicodeString( $title );
+ },
+ [ 'pcTTL' => $cache::TTL_PROC_LONG ]
+ );
+ } else {
+ list( $ok, $norm ) = AntiSpoof::checkUnicodeString( $title );
+ }
+
+ if ( $ok === "OK" ) {
+ list( $ver, $title ) = explode( ':', $norm, 2 );
+ } else {
+ wfDebugLog( 'TitleBlacklist', 'AntiSpoof could not normalize "' . $title . '".' );
+ }
+ }
+
+ wfSuppressWarnings();
+ $match = preg_match(
+ "/^(?:{$this->mRegex})$/us" . ( isset( $this->mParams['casesensitive'] ) ? '' : 'i' ),
+ $title
+ );
+ wfRestoreWarnings();
+
+ if ( $match ) {
+ if ( isset( $this->mParams['moveonly'] ) && $action != 'move' ) {
+ return false;
+ }
+ if ( isset( $this->mParams['newaccountonly'] ) && $action != 'new-account' ) {
+ return false;
+ }
+ if ( !isset( $this->mParams['noedit'] ) && $action == 'edit' ) {
+ return false;
+ }
+ if ( isset( $this->mParams['reupload'] ) && $action == 'upload' ) {
+ // Special:Upload also checks 'create' permissions when not reuploading
+ return false;
+ }
+ return true;
+ }
+
+ return false;
+ }
+
+ /**
+ * Create a new TitleBlacklistEntry from a line of text
+ *
+ * @param string $line String containing a line of blacklist text
+ * @param string $source
+ * @return TitleBlacklistEntry|null
+ */
+ public static function newFromString( $line, $source ) {
+ $raw = $line; // Keep line for raw data
+ $options = [];
+ // Strip comments
+ $line = preg_replace( "/^\\s*([^#]*)\\s*((.*)?)$/", "\\1", $line );
+ $line = trim( $line );
+ // A blank string causes problems later on
+ if ( $line === '' ) {
+ return null;
+ }
+ // Parse the rest of message
+ $pockets = [];
+ if ( !preg_match( '/^(.*?)(\s*<([^<>]*)>)?$/', $line, $pockets ) ) {
+ return null;
+ }
+ $regex = trim( $pockets[1] );
+ $regex = str_replace( '_', ' ', $regex ); // We'll be matching against text form
+ $opts_str = isset( $pockets[3] ) ? trim( $pockets[3] ) : '';
+ // Parse opts
+ $opts = preg_split( '/\s*\|\s*/', $opts_str );
+ foreach ( $opts as $opt ) {
+ $opt2 = strtolower( $opt );
+ if ( $opt2 == 'autoconfirmed' ) {
+ $options['autoconfirmed'] = true;
+ }
+ if ( $opt2 == 'moveonly' ) {
+ $options['moveonly'] = true;
+ }
+ if ( $opt2 == 'newaccountonly' ) {
+ $options['newaccountonly'] = true;
+ }
+ if ( $opt2 == 'noedit' ) {
+ $options['noedit'] = true;
+ }
+ if ( $opt2 == 'casesensitive' ) {
+ $options['casesensitive'] = true;
+ }
+ if ( $opt2 == 'reupload' ) {
+ $options['reupload'] = true;
+ }
+ if ( preg_match( '/errmsg\s*=\s*(.+)/i', $opt, $matches ) ) {
+ $options['errmsg'] = $matches[1];
+ }
+ if ( $opt2 == 'antispoof' ) {
+ $options['antispoof'] = true;
+ }
+ }
+ // Process magic words
+ preg_match_all( '/{{\s*([a-z]+)\s*:\s*(.+?)\s*}}/', $regex, $magicwords, PREG_SET_ORDER );
+ foreach ( $magicwords as $mword ) {
+ global $wgParser; // Functions we're calling don't need, nevertheless let's use it
+ switch ( strtolower( $mword[1] ) ) {
+ case 'ns':
+ $cpf_result = CoreParserFunctions::ns( $wgParser, $mword[2] );
+ if ( is_string( $cpf_result ) ) {
+ // All result will have the same value, so we can just use str_seplace()
+ $regex = str_replace( $mword[0], $cpf_result, $regex );
+ }
+ break;
+ case 'int':
+ $cpf_result = wfMessage( $mword[2] )->inContentLanguage()->text();
+ if ( is_string( $cpf_result ) ) {
+ $regex = str_replace( $mword[0], $cpf_result, $regex );
+ }
+ }
+ }
+ // Return result
+ if ( $regex ) {
+ return new TitleBlacklistEntry( $regex, $options, $raw, $source );
+ } else {
+ return null;
+ }
+ }
+
+ /**
+ * @return string This entry's regular expression
+ */
+ public function getRegex() {
+ return $this->mRegex;
+ }
+
+ /**
+ * @return string This entry's raw line
+ */
+ public function getRaw() {
+ return $this->mRaw;
+ }
+
+ /**
+ * @return array This entry's parameters
+ */
+ public function getParams() {
+ return $this->mParams;
+ }
+
+ /**
+ * @return string Custom message for this entry
+ */
+ public function getCustomMessage() {
+ return isset( $this->mParams['errmsg'] ) ? $this->mParams['errmsg'] : null;
+ }
+
+ /**
+ * @return string The format version
+ */
+ public function getFormatVersion() {
+ return $this->mFormatVersion;
+ }
+
+ /**
+ * Set the format version
+ *
+ * @param string $v New version to set
+ */
+ public function setFormatVersion( $v ) {
+ $this->mFormatVersion = $v;
+ }
+
+ /**
+ * Return the error message name for the blacklist entry.
+ *
+ * @param string $operation Operation name (as in titleblacklist-forbidden message name)
+ *
+ * @return string The error message name
+ */
+ public function getErrorMessage( $operation ) {
+ $message = $this->getCustomMessage();
+ // For grep:
+ // titleblacklist-forbidden-edit, titleblacklist-forbidden-move,
+ // titleblacklist-forbidden-upload, titleblacklist-forbidden-new-account
+ return $message ? $message : "titleblacklist-forbidden-{$operation}";
+ }
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistHooks.php b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistHooks.php
new file mode 100644
index 00000000..b7c3a6e1
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistHooks.php
@@ -0,0 +1,269 @@
+<?php
+/**
+ * Hooks for Title Blacklist
+ * @author Victor Vasiliev
+ * @copyright © 2007-2010 Victor Vasiliev et al
+ * @license GPL-2.0-or-later
+ */
+
+/**
+ * Hooks for the TitleBlacklist class
+ *
+ * @ingroup Extensions
+ */
+class TitleBlacklistHooks {
+
+ /**
+ * getUserPermissionsErrorsExpensive hook
+ *
+ * @param Title $title
+ * @param User $user
+ * @param string $action
+ * @param array &$result
+ * @return bool
+ */
+ public static function userCan( $title, $user, $action, &$result ) {
+ # Some places check createpage, while others check create.
+ # As it stands, upload does createpage, but normalize both
+ # to the same action, to stop future similar bugs.
+ if ( $action === 'createpage' || $action === 'createtalk' ) {
+ $action = 'create';
+ }
+ if ( $action == 'create' || $action == 'edit' || $action == 'upload' ) {
+ $blacklisted = TitleBlacklist::singleton()->userCannot( $title, $user, $action );
+ if ( $blacklisted instanceof TitleBlacklistEntry ) {
+ $errmsg = $blacklisted->getErrorMessage( 'edit' );
+ $params = [
+ $blacklisted->getRaw(),
+ $title->getFullText()
+ ];
+ ApiResult::setIndexedTagName( $params, 'param' );
+ $result = ApiMessage::create(
+ wfMessage(
+ $errmsg,
+ htmlspecialchars( $blacklisted->getRaw() ),
+ $title->getFullText()
+ ),
+ 'titleblacklist-forbidden',
+ [
+ 'message' => [
+ 'key' => $errmsg,
+ 'params' => $params,
+ ],
+ 'line' => $blacklisted->getRaw(),
+ // As $errmsg usually represents a non-default message here, and ApiBase
+ // uses ->inLanguage( 'en' )->useDatabase( false ) for all messages, it will
+ // never result in useful 'info' text in the API. Try this, extra data seems
+ // to override the default.
+ 'info' => 'TitleBlacklist prevents this title from being created',
+ ]
+ );
+ return false;
+ }
+ }
+ return true;
+ }
+
+ /**
+ * Display a notice if a user is only able to create or edit a page
+ * because they have tboverride.
+ *
+ * @param Title $title
+ * @param int $oldid
+ * @param array &$notices
+ * @return true
+ */
+ public static function displayBlacklistOverrideNotice( Title $title, $oldid, array &$notices ) {
+ if ( !RequestContext::getMain()->getUser()->isAllowed( 'tboverride' ) ) {
+ return true;
+ }
+
+ $blacklisted = TitleBlacklist::singleton()->isBlacklisted(
+ $title,
+ $title->exists() ? 'edit' : 'create'
+ );
+ if ( !$blacklisted ) {
+ return true;
+ }
+
+ $params = $blacklisted->getParams();
+ if ( isset( $params['autoconfirmed'] ) ) {
+ return true;
+ }
+
+ $msg = wfMessage( 'titleblacklist-warning' );
+ $notices['titleblacklist'] = $msg->rawParams(
+ htmlspecialchars( $blacklisted->getRaw() ) )->parseAsBlock();
+ return true;
+ }
+
+ /**
+ * MovePageCheckPermissions hook (1.25+)
+ *
+ * @param Title $oldTitle
+ * @param Title $newTitle
+ * @param User $user
+ * @param string $reason
+ * @param Status $status
+ * @return bool
+ */
+ public static function onMovePageCheckPermissions(
+ Title $oldTitle, Title $newTitle, User $user, $reason, Status $status
+ ) {
+ $titleBlacklist = TitleBlacklist::singleton();
+ $blacklisted = $titleBlacklist->userCannot( $newTitle, $user, 'move' );
+ if ( !$blacklisted ) {
+ $blacklisted = $titleBlacklist->userCannot( $oldTitle, $user, 'edit' );
+ }
+ if ( $blacklisted instanceof TitleBlacklistEntry ) {
+ $status->fatal( ApiMessage::create( [
+ $blacklisted->getErrorMessage( 'move' ),
+ $blacklisted->getRaw(),
+ $oldTitle->getFullText(),
+ $newTitle->getFullText()
+ ] ) );
+ return false;
+ }
+
+ return true;
+ }
+
+ /**
+ * Check whether a user name is acceptable for account creation or autocreation, and explain
+ * why not if that's the case.
+ *
+ * @param string $userName
+ * @param User $creatingUser
+ * @param bool $override Should the test be skipped, if the user has sufficient privileges?
+ * @param bool $log Log blacklist hits to Special:Log
+ * @return StatusValue
+ */
+ public static function testUserName(
+ $userName, User $creatingUser, $override = true, $log = false
+ ) {
+ $title = Title::makeTitleSafe( NS_USER, $userName );
+ $blacklisted = TitleBlacklist::singleton()->userCannot( $title, $creatingUser,
+ 'new-account', $override );
+ if ( $blacklisted instanceof TitleBlacklistEntry ) {
+ if ( $log ) {
+ self::logFilterHitUsername( $creatingUser, $title, $blacklisted->getRaw() );
+ }
+ $message = $blacklisted->getErrorMessage( 'new-account' );
+ $params = [
+ $blacklisted->getRaw(),
+ $userName,
+ ];
+ ApiResult::setIndexedTagName( $params, 'param' );
+ return StatusValue::newFatal( ApiMessage::create(
+ [ $message, $blacklisted->getRaw(), $userName ],
+ 'titleblacklist-forbidden',
+ [
+ 'message' => [
+ 'key' => $message,
+ 'params' => $params,
+ ],
+ 'line' => $blacklisted->getRaw(),
+ // The text of the message probably isn't useful API info, so do this instead
+ 'info' => 'TitleBlacklist prevents this username from being created',
+ ]
+ ) );
+ }
+ return StatusValue::newGood();
+ }
+
+ /**
+ * EditFilter hook
+ *
+ * @param EditPage $editor
+ * @param string $text
+ * @param string $section
+ * @param string &$error
+ * @return true
+ */
+ public static function validateBlacklist( $editor, $text, $section, &$error ) {
+ $title = $editor->getTitle();
+
+ if ( $title->getNamespace() == NS_MEDIAWIKI && $title->getDBkey() == 'Titleblacklist' ) {
+ $blackList = TitleBlacklist::singleton();
+ $bl = $blackList->parseBlacklist( $text, 'page' );
+ $ok = $blackList->validate( $bl );
+ if ( count( $ok ) == 0 ) {
+ return true;
+ }
+
+ $errmsg = wfMessage( 'titleblacklist-invalid' )->numParams( count( $ok ) )->text();
+ $errlines = '* <code>' .
+ implode( "</code>\n* <code>", array_map( 'wfEscapeWikiText', $ok ) ) .
+ '</code>';
+ $error = Html::openElement( 'div', [ 'class' => 'errorbox' ] ) .
+ $errmsg .
+ "\n" .
+ $errlines .
+ Html::closeElement( 'div' ) . "\n" .
+ Html::element( 'br', [ 'clear' => 'all' ] ) . "\n";
+
+ // $error will be displayed by the edit class
+ }
+ return true;
+ }
+
+ /**
+ * PageContentSaveComplete hook
+ *
+ * @param WikiPage &$wikiPage
+ * @param User &$user
+ * @param Content $content
+ * @param string $summary
+ * @param bool $isminor
+ * @param bool $iswatch
+ * @param string $section
+ *
+ * @return true
+ */
+ public static function clearBlacklist(
+ WikiPage &$wikiPage, &$user,
+ $content, $summary, $isminor, $iswatch, $section
+ ) {
+ $title = $wikiPage->getTitle();
+ if ( $title->getNamespace() == NS_MEDIAWIKI && $title->getDBkey() == 'Titleblacklist' ) {
+ TitleBlacklist::singleton()->invalidate();
+ }
+ return true;
+ }
+
+ /**
+ * Logs the filter username hit to Special:Log if
+ * $wgTitleBlacklistLogHits is enabled.
+ *
+ * @param User $user
+ * @param Title $title
+ * @param string $entry
+ */
+ public static function logFilterHitUsername( $user, $title, $entry ) {
+ global $wgTitleBlacklistLogHits;
+ if ( $wgTitleBlacklistLogHits ) {
+ $logEntry = new ManualLogEntry( 'titleblacklist', 'hit-username' );
+ $logEntry->setPerformer( $user );
+ $logEntry->setTarget( $title );
+ $logEntry->setParameters( [
+ '4::entry' => $entry,
+ ] );
+ $logid = $logEntry->insert();
+ $logEntry->publish( $logid );
+ }
+ }
+
+ /**
+ * External Lua library for Scribunto
+ *
+ * @param string $engine
+ * @param array &$extraLibraries
+ * @return bool
+ */
+ public static function scribuntoExternalLibraries( $engine, array &$extraLibraries ) {
+ if ( $engine == 'lua' ) {
+ $extraLibraries['mw.ext.TitleBlacklist'] = 'Scribunto_LuaTitleBlacklistLibrary';
+ }
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistPreAuthenticationProvider.php b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistPreAuthenticationProvider.php
new file mode 100644
index 00000000..8c737bae
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/TitleBlacklistPreAuthenticationProvider.php
@@ -0,0 +1,58 @@
+<?php
+
+use MediaWiki\Auth\AbstractPreAuthenticationProvider;
+use MediaWiki\Auth\AuthenticationRequest;
+use MediaWiki\Auth\AuthManager;
+
+class TitleBlacklistPreAuthenticationProvider extends AbstractPreAuthenticationProvider {
+ protected $blockAutoAccountCreation;
+
+ public function __construct( $params = [] ) {
+ global $wgTitleBlacklistBlockAutoAccountCreation;
+
+ $params += [
+ 'blockAutoAccountCreation' => $wgTitleBlacklistBlockAutoAccountCreation
+ ];
+
+ $this->blockAutoAccountCreation = (bool)$params['blockAutoAccountCreation'];
+ }
+
+ public function getAuthenticationRequests( $action, array $options ) {
+ $needOverrideOption = false;
+ switch ( $action ) {
+ case AuthManager::ACTION_CREATE:
+ $user = User::newFromName( $options['username'] ) ?: new User();
+ $needOverrideOption = TitleBlacklist::userCanOverride( $user, 'new-account' );
+ break;
+ }
+
+ return $needOverrideOption ? [ new TitleBlacklistAuthenticationRequest() ] : [];
+ }
+
+ public function testForAccountCreation( $user, $creator, array $reqs ) {
+ /** @var TitleBlacklistAuthenticationRequest $req */
+ $req = AuthenticationRequest::getRequestByClass( $reqs,
+ TitleBlacklistAuthenticationRequest::class );
+ // For phan check, to ensure that $req is instance of \TitleBlacklistAuthenticationRequest
+ // or null
+ if ( $req instanceof TitleBlacklistAuthenticationRequest ) {
+ $override = $req->ignoreTitleBlacklist;
+ } else {
+ $override = false;
+ }
+
+ return TitleBlacklistHooks::testUserName( $user->getName(), $creator, $override, true );
+ }
+
+ public function testUserForCreation( $user, $autocreate, array $options = [] ) {
+ $sv = StatusValue::newGood();
+ $creator = RequestContext::getMain()->getUser();
+
+ if ( !$autocreate && empty( $options['creating'] ) || $this->blockAutoAccountCreation ) {
+ $sv->merge( TitleBlacklistHooks::testUserName(
+ $user->getName(), $creator, true, (bool)$autocreate
+ ) );
+ }
+ return $sv;
+ }
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/api/ApiQueryTitleBlacklist.php b/www/wiki/extensions/TitleBlacklist/includes/api/ApiQueryTitleBlacklist.php
new file mode 100644
index 00000000..82e93cde
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/api/ApiQueryTitleBlacklist.php
@@ -0,0 +1,107 @@
+<?php
+/**
+ * TitleBlacklist extension API
+ *
+ * Copyright © 2011 Wikimedia Foundation and Ian Baker <ian@wikimedia.org>
+ * Based on code by Victor Vasiliev, Bryan Tong Minh, Roan Kattouw, and Alex Z.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/**
+ * Query module check a title against the blacklist
+ *
+ * @ingroup API
+ * @ingroup Extensions
+ */
+class ApiQueryTitleBlacklist extends ApiBase {
+
+ public function __construct( $query, $moduleName ) {
+ parent::__construct( $query, $moduleName, 'tb' );
+ }
+
+ public function execute() {
+ $params = $this->extractRequestParams();
+ $action = $params['action'];
+ $override = !$params['nooverride'];
+
+ // createtalk and createpage are useless as they're treated exactly like create
+ if ( $action === 'createpage' || $action === 'createtalk' ) {
+ $action = 'create';
+ }
+
+ $title = Title::newFromText( $params['title'] );
+ if ( !$title ) {
+ $this->dieWithError(
+ [ 'apierror-invalidtitle', wfEscapeWikiText( $params['title'] ) ]
+ );
+ }
+
+ $blacklisted = TitleBlacklist::singleton()->userCannot(
+ $title, $this->getUser(), $action, $override
+ );
+ if ( $blacklisted instanceof TitleBlacklistEntry ) {
+ // this title is blacklisted.
+ $result = [
+ htmlspecialchars( $blacklisted->getRaw() ),
+ htmlspecialchars( $params['title'] ),
+ ];
+
+ $res = $this->getResult();
+ $res->addValue( 'titleblacklist', 'result', 'blacklisted' );
+ // there aren't any messages for create(talk|page), using edit for those instead
+ $message = $blacklisted->getErrorMessage( $action !== 'create' ? $action : 'edit' );
+ $res->addValue( 'titleblacklist', 'reason', wfMessage( $message, $result )->text() );
+ $res->addValue( 'titleblacklist', 'message', $message );
+ $res->addValue( 'titleblacklist', 'line', htmlspecialchars( $blacklisted->getRaw() ) );
+ } else {
+ // not blacklisted
+ $this->getResult()->addValue( 'titleblacklist', 'result', 'ok' );
+ }
+ }
+
+ public function getAllowedParams() {
+ return [
+ 'title' => [
+ ApiBase::PARAM_REQUIRED => true,
+ ],
+ 'action' => [
+ ApiBase::PARAM_DFLT => 'edit',
+ ApiBase::PARAM_ISMULTI => false,
+ ApiBase::PARAM_TYPE => [
+ // createtalk and createpage are useless as they're treated exactly like create
+ 'create', 'edit', 'upload', 'createtalk', 'createpage', 'move', 'new-account'
+ ],
+ ],
+ 'nooverride' => [
+ ApiBase::PARAM_DFLT => false,
+ ]
+ ];
+ }
+
+ /**
+ * @see ApiBase::getExamplesMessages()
+ * @return array
+ */
+ protected function getExamplesMessages() {
+ return [
+ 'action=titleblacklist&tbtitle=Foo'
+ => 'apihelp-titleblacklist-example-1',
+ 'action=titleblacklist&tbtitle=Bar&tbaction=edit'
+ => 'apihelp-titleblacklist-example-2',
+ ];
+ }
+}
diff --git a/www/wiki/extensions/TitleBlacklist/includes/mw.ext.TitleBlacklist.lua b/www/wiki/extensions/TitleBlacklist/includes/mw.ext.TitleBlacklist.lua
new file mode 100644
index 00000000..1b48eed1
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/includes/mw.ext.TitleBlacklist.lua
@@ -0,0 +1,22 @@
+local TitleBlacklist = {}
+local php
+
+function TitleBlacklist.test( action, title )
+ return php.test( action, title )
+end
+
+function TitleBlacklist.setupInterface( options )
+ -- Boilerplate
+ TitleBlacklist.setupInterface = nil
+ php = mw_interface
+ mw_interface = nil
+
+ -- Register this library in the "mw" global
+ mw = mw or {}
+ mw.ext = mw.ext or {}
+ mw.ext.TitleBlacklist = TitleBlacklist
+
+ package.loaded['mw.ext.TitleBlacklist'] = TitleBlacklist
+end
+
+return TitleBlacklist
diff --git a/www/wiki/extensions/TitleBlacklist/tests/phan/config.php b/www/wiki/extensions/TitleBlacklist/tests/phan/config.php
new file mode 100644
index 00000000..9a1424e9
--- /dev/null
+++ b/www/wiki/extensions/TitleBlacklist/tests/phan/config.php
@@ -0,0 +1,19 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+$cfg['directory_list'] = array_merge(
+ $cfg['directory_list'],
+ [
+ './../../extensions/AntiSpoof',
+ './../../extensions/Scribunto',
+ ]
+);
+$cfg['exclude_analysis_directory_list'] = array_merge(
+ $cfg['exclude_analysis_directory_list'],
+ [
+ './../../extensions/AntiSpoof',
+ './../../extensions/Scribunto',
+ ]
+);
+
+return $cfg;
diff --git a/www/wiki/extensions/TitleBlacklist/tests/phpunit/ApiQueryTitleBlacklistTest.php b/www/wiki/extensions/TitleBlacklist/tests/phpunit/ApiQueryTitleBlacklistTest.php
index 5e775ce6..88aa723e 100644
--- a/www/wiki/extensions/TitleBlacklist/tests/phpunit/ApiQueryTitleBlacklistTest.php
+++ b/www/wiki/extensions/TitleBlacklist/tests/phpunit/ApiQueryTitleBlacklistTest.php
@@ -16,7 +16,8 @@ ini_set( 'include_path', ini_get( 'include_path' ) . ':' .
/**
* @group medium
- **/
+ * @covers ApiQueryTitleBlacklist
+ */
class ApiQueryTitleBlacklistTest extends ApiTestCase {
function setUp() {
diff --git a/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistAuthenticationRequestTest.php b/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistAuthenticationRequestTest.php
index ea084025..6d05475e 100644
--- a/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistAuthenticationRequestTest.php
+++ b/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistAuthenticationRequestTest.php
@@ -3,6 +3,9 @@
use MediaWiki\Auth\AuthenticationRequestTestCase;
use MediaWiki\Auth\AuthManager;
+/**
+ * @covers TitleBlacklistAuthenticationRequest
+ */
class TitleBlacklistAuthenticationRequestTest extends AuthenticationRequestTestCase {
public function setUp() {
global $wgDisableAuthManager;
diff --git a/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistPreAuthenticationProviderTest.php b/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistPreAuthenticationProviderTest.php
index e48868b0..30036853 100644
--- a/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistPreAuthenticationProviderTest.php
+++ b/www/wiki/extensions/TitleBlacklist/tests/phpunit/TitleBlacklistPreAuthenticationProviderTest.php
@@ -3,6 +3,7 @@ use MediaWiki\Auth\AuthManager;
/**
* @group Database
+ * @covers TitleBlacklistPreAuthenticationProvider
*/
class TitleBlacklistPreAuthenticationProviderTest extends MediaWikiTestCase {
public function setUp() {
diff --git a/www/wiki/extensions/Validator/.gitignore b/www/wiki/extensions/Validator/.gitignore
new file mode 100644
index 00000000..9421515a
--- /dev/null
+++ b/www/wiki/extensions/Validator/.gitignore
@@ -0,0 +1,10 @@
+*~
+*.kate-swp
+
+!.*
+.idea
+
+composer.phar
+composer.lock
+
+vendor/ \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/.scrutinizer.yml b/www/wiki/extensions/Validator/.scrutinizer.yml
new file mode 100644
index 00000000..19751cec
--- /dev/null
+++ b/www/wiki/extensions/Validator/.scrutinizer.yml
@@ -0,0 +1,12 @@
+inherit: true
+
+tools:
+ external_code_coverage: true
+ php_code_sniffer: true
+ php_cpd: true
+ php_cs_fixer: true
+ php_loc: true
+ php_mess_detector: true
+ php_pdepend: true
+ php_analyzer: true
+ sensiolabs_security_checker: true
diff --git a/www/wiki/extensions/Validator/.travis.yml b/www/wiki/extensions/Validator/.travis.yml
new file mode 100644
index 00000000..a98998bf
--- /dev/null
+++ b/www/wiki/extensions/Validator/.travis.yml
@@ -0,0 +1,20 @@
+language: php
+
+matrix:
+ include:
+ - env: DBTYPE=mysql; MW=master
+ php: 5.6
+ - env: DBTYPE=mysql; MW=1.21.0
+ php: 5.5
+ - env: DBTYPE=sqlite; MW=1.22.0
+ php: 5.6
+ - env: DBTYPE=sqlite; MW=master; TYPE=coverage
+ php: 7
+
+before_script: bash ./build/travis/before_script.sh
+
+script: bash ./build/travis/script.sh
+
+after_success: bash ./build/travis/after_success.sh
+
+sudo: false
diff --git a/www/wiki/extensions/Validator/COPYING b/www/wiki/extensions/Validator/COPYING
new file mode 100644
index 00000000..72ef1f32
--- /dev/null
+++ b/www/wiki/extensions/Validator/COPYING
@@ -0,0 +1,103 @@
+'''Valitator''' is a free, open-source extension to MediaWiki that provides a parameter processing framework allowing to declaratively define a set of parameters and how they should be processed.
+
+Copyright (C) 2009
+
+
+The license text below "====" applies to all files within this distribution, other than those that are in a directory which contains files named "LICENSE" or "COPYING", or a subdirectory thereof. For those files, the license text contained in said file overrides any license information contained in directories of smaller depth. Alternative licenses are typically used for software that is provided by external parties, and merely packaged with this extension for convenience.
+----
+----
+
+== GNU GENERAL PUBLIC LICENSE ==
+Version 2, June 1991
+
+Copyright (C) 1989, 1991 Free Software Foundation, Inc.,<br />
+51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+
+Everyone is permitted to copy and distribute verbatim copies<br />
+of this license document, but changing it is not allowed.
+
+=== Preamble ===
+The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software - to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too.
+
+When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things.
+
+To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it.
+
+For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights.
+
+We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software.
+
+Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all.
+
+The precise terms and conditions for copying, distribution and modification follow.
+
+=== TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION ===
+
+'''0.''' This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does.
+
+'''1.''' You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.
+
+'''2.''' You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions:
+
+: '''a)''' You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change.
+
+: '''b)''' You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License.
+
+: '''c)''' If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.
+
+'''3.''' You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following:
+
+: '''a)''' Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,
+
+: '''b)''' Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,
+
+: '''c)''' Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.
+
+If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code.
+
+'''4.''' You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.
+
+'''5.''' You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it.
+
+'''6.''' Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License.
+
+'''7.''' If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances.
+
+It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot impose that choice.
+
+This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.
+
+'''8.''' If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License.
+
+'''9.''' The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation.
+
+'''10.''' If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally.
+
+'''<big>NO WARRANTY</big>'''
+
+'''11.''' BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+'''12.''' IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
+
+'''<big>END OF TERMS AND CONDITIONS</big>'''
diff --git a/www/wiki/extensions/Validator/README.md b/www/wiki/extensions/Validator/README.md
new file mode 100644
index 00000000..57eea7ca
--- /dev/null
+++ b/www/wiki/extensions/Validator/README.md
@@ -0,0 +1,348 @@
+# Validator
+
+The Validator MediaWiki extension, provides a parameter processing
+framework that provides a way to declaratively define a set of parameters and how they
+should be processed. It can take such declarations together with a list of raw
+parameters and provide the processed values.
+
+The functionality provided by this extension largely comes from the [ParamProcessor library]
+(https://github.com/JeroenDeDauw/ParamProcessor).
+
+[![Build Status](https://travis-ci.org/JeroenDeDauw/Validator.svg?branch=master)](https://travis-ci.org/JeroenDeDauw/Validator)
+[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/JeroenDeDauw/Validator/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/JeroenDeDauw/Validator/?branch=master)
+[![Code Coverage](https://scrutinizer-ci.com/g/JeroenDeDauw/Validator/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/JeroenDeDauw/Validator/?branch=master)
+[![Dependency Status](https://www.versioneye.com/php/mediawiki:validator/badge.png)](https://www.versioneye.com/php/mediawiki:validator)
+
+On [Packagist](https://packagist.org/packages/mediawiki/validator):
+[![Latest Stable Version](https://poser.pugx.org/mediawiki/validator/version.png)](https://packagist.org/packages/mediawiki/validator)
+[![Download count](https://poser.pugx.org/mediawiki/validator/d/total.png)](https://packagist.org/packages/mediawiki/validator)
+
+## Installation
+
+You can use [Composer](http://getcomposer.org/) to download and install
+this package as well as its dependencies. Alternatively you can simply clone
+the git repository and take care of loading yourself.
+
+### Composer
+
+To add this package as a local, per-project dependency to your project, simply add a
+dependency on `mediawiki/validator` to your project's `composer.json` file.
+Here is a minimal example of a `composer.json` file that just defines a dependency on
+Validator 2.2:
+
+ {
+ "require": {
+ "mediawiki/validator": "2.2.*"
+ }
+ }
+
+### Manual
+
+Get the Validator code, either via git, or some other means. Also get all dependencies.
+You can find a list of the dependencies in the "require" section of the composer.json file.
+Load all dependencies and the load the Validator extension by including its entry point:
+Validator.php.
+
+Simply include the entry point in your LocalSettings.php file:
+
+```php
+require_once( "$IP/extensions/Validator/Validator.php" );
+```
+
+## Authors
+
+Validator has been written by
+[Jeroen De Dauw](https://www.mediawiki.org/wiki/User:Jeroen_De_Dauw)
+to support [Maps](https://github.com/JeroenDeDauw/Maps)
+and [Semantic MediaWiki](https://www.semantic-mediawiki.org/).
+
+## Release notes
+
+### Version 2.2.1 (2016-10-10)
+
+* Moved i18n registration out of wgExtensionFunctions
+
+### Version 2.2.0 (2016-10-09)
+
+* Improved initialization code so that the entry point can be included when MediaWiki is not loaded
+
+### Version 2.1.0 (2016-10-09)
+
+* Dropped support for MediaWiki older than 1.23
+* Dropped support for PHP older than 5.5
+
+### Version 2.0.6 (2016-07-01)
+
+* Added missing system message
+* Translation updates
+* Fixed failing test (only the test itself had an issue)
+
+### Version 2.0.5 (2016-04-04)
+
+* Translation updates
+* Compatibility with PHP 7 has now been tested
+
+### Version 2.0.4 (2014-06-25)
+
+* Updated used ParamProcessor version from ~1.0.0 to ~1.1
+
+### Version 2.0.3 (2014-06-16)
+
+* Removed obsolete magic words internationalization file
+
+### Version 2.0.2 (2014-06-14)
+
+* Fixed issue in deprecated ParserHook class
+
+### Version 2.0.1 (2014-06-14)
+
+* Removed #listerrors and #describe parser hooks
+
+### Version 2.0 (2014-06-14)
+
+* Dropped deprecated class aliases
+* Dropped deprecated ParamProcessor.php entry point
+* Use composer based autoloading
+* Added TravisCI and ScrutinizerCI integration
+* Changed minimum MediaWiki version from 1.16 to 1.17
+* Migrated messages to the new MediaWiki i18n JSON format
+
+### Version 1.0.1 (2014-03-25)
+
+* Translation updates
+* Main copy of the source code is now on GitHub
+
+### Version 1.0 (2013-11-21)
+
+This release is primarily a redesign of many internal APIs aimed at greater
+stability and cleaner interfaces exposed to the outside.
+
+Most code has been moved to the new [ParamProcessor library]
+(https://github.com/JeroenDeDauw/ParamProcessor), leaving the Validator extension
+as a thin MediaWiki specific wrapper.
+
+##### Compatibility changes
+
+* The ParamProcessor library is now required, version 1.0 or later.
+* Changed minimum MediaWiki version from 1.16 to 1.18.
+* Full compatibility with MediaWiki 1.20, 1.21, 1.22 and forward-compatibility with 1.23.
+* Added compatibility with PHP 5.4.x and PHP 5.5.x
+* Dropped support for Validator 0.4.x parameter definitions, including Criteria and Manipulations
+
+##### Deprecations
+
+* Deprecated the ParserHook class
+* Deprecated the describe parser hook
+* Deprecated the listerrors parser hook
+
+### Version 0.5.1 (2012-11-21)
+
+* Added compatibility with PHP 5.4.
+
+### Version 0.5 (2012-10-05)
+
+##### Compatibility changes
+
+* Changed minimum MediaWiki version from 1.16 to 1.17.
+* Full compatibility with MediaWiki 1.19 and MediaWiki 1.20 and forward-compatibility with 1.21.
+
+#### New features
+
+* New light-weight array definition of ParamDefinition objects supported.
+* Added DimensionParam.
+* Added ValidatorOptions class of which an instance can be passed to Validator
+to globally change precessing behaviour. The most notable new option is the
+'rawStringParameters' one, which when set to true (default) will expect values
+in string format, and when set to false (new capability) will expect values
+in their native formats (ie lists should be actual array objects).
+
+#### Enhancements
+
+* Split Parameter into Param and ParamDefinition classes.
+ * ParamDefinition objects each represent a type and contain the
+logic to validate and manipulate values.
+ * Param objects hold a ParamDefinition, the user provided value,
+and processing state.
+* Added several new options to various of the ParamDefinition objects that
+where not available in earlier criteria and manipulation objects.
+* Added tests for all ParamDefinition objects.
+* Added high level tests for Validator and tests for ValidatorOptions.
+
+#### Deprecations
+
+* Deprecated Parameter (and deriving) classes.
+* Deprecated ParameterCriterion (and deriving) classes.
+* Deprecated ParameterManipulation (and deriving) classes.
+* Deprecated the constructor method of the Validator class.
+
+### Version 0.4.14 (2012-03-10)
+
+* New built-in parameter type 'title'. Accepts existing and non-existing page titles which are valid within the wiki.
+
+### Version 0.4.13 (2011-11-30)
+
+* ParserHook::$parser now is a reference to the original parser object, as one would suspect.
+ Before this has only been the case for tag extension but not for parser function calls.
+
+* if SFH_OBJECT_ARGS and therefore object parser function arguments are available in the MW
+ version used with Validator, ParserHook::$frame will not be null anymore. Therefore a new
+ function ParserHook::renderFunctionObj() is introduced, handling these SFH_OBJECT_ARGS hooks.
+
+* ParserHook constructor now accepts a bitfield for flags to define further customization for
+ registered Hooks. First option can be set via ParserHook::FH_NO_HASH to define that the function
+ hook should be callable without leading hash ("{{plural:...}}"-like style).
+
+* Option for unnamed parameter handling to work without named fallback. This allows to ignore '='
+ within parameter values entirely, these parameters bust be set before any named parameter then.
+ See Validator::setFunctionParams() and ParserHook::getParameterInfo() for details.
+
+* ParserHook Validation messages will now output text in global content language instead of users interface language.
+
+### Version 0.4.12 (2011-10-15)
+
+* Internationalization fix in the describe parser hook.
+
+### Version 0.4.11 (2011-09-14)
+
+* Fixed compatibility fallback in Parameter::getDescription.
+* Fixed handling of list parameters in ParameterInput.
+
+### Version 0.4.10 (2011-08-04)
+
+* Added language parameter to describe that allows setting the lang for the generated docs.
+* Added getMessage method to ParserHook class for better i18n.
+
+### Version 0.4.9 (2011-07-30)
+
+* Added setMessage and getMessage methods to Parameter class for better i18n.
+
+### Version 0.4.8 (2011-07-19)
+
+* Added unit tests for the criteria.
+* Fixed issue with handling floats in CriterionInRange.
+* Added support for open limits in CriterionHasLength and CriterionItemCount.
+
+### Version 0.4.7 (2011-05-15)
+
+* Added ParameterInput class to generate HTML inputs for parameters, based on code from SMWs Special:Ask.
+* Added "$manipulate = true" as second parameter for Parameter::setDefault,
+ which gets passed to Parameter::setDoManipulationOfDefault.
+* Boolean manipulation now ignores values that are already a boolean.
+
+### Version 0.4.6 (2011-03-21)
+
+* Removed ParamManipulationBoolstr.
+* Added method to get the allowed values to CriterionInArray.
+* Added automatic non-using of boolean manipulation when a boolean param was defaulted to a boolean value.
+* Parameter fix in ListParameter::setDefault, follow up to change in 0.4.5.
+
+### Version 0.4.5 (2011-03-05)
+
+* Escaping fix in the describe parser hook.
+* Added string manipulation, applied by default on strings and chars.
+
+### Version 0.4.4 (2011-02-16)
+
+* Tweaks to parser usage in the ParserHook class.
+* Fixed incorrect output of nested pre-tags in the describe parser hook.
+
+### Version 0.4.3.1 (2011-01-20)
+
+* Removed underscore and space switching behavior for tag extensions and parser functions.
+
+### Version 0.4.3 (2011-01-11)
+
+* Added describe parser hook that enables automatic documentation generation of parser hooks defined via Validator.
+* Modified the ParserHook and Parameter classes to allow specifying a description message.
+
+### Version 0.4.2 (2010-10-28)
+
+* Fixed compatibility with MediaWiki 1.15.x.
+* Removed the lowerCaseValue field in the Parameter class and replaced it's functionality with a ParameterManipulation.
+
+### Version 0.4.1 (2010-10-20)
+
+* Made several small fixes and improvements.
+
+### Version 0.4 (2010-10-15)
+
+##### New features
+
+* Added ParserHook class that allows for out-of-the-box parser function and tag extension creation
+with full Validator support.
+* Added listerrors parser hook that allows you to list all validation errors that occurred at the point it's rendered.
+* Added support for conditional parameter adding.
+
+##### Refactoring
+
+Basically everything got rewritten...
+
+* Added Parameter and ListParameter classes to replace parameter definitions in array form.
+* Added ParameterCriterion and ListParameterCriterion classes for better handling of parameter criteria.
+* Added ParameterManipulation and ListParameterManipulation classes for more structured formatting of parameters.
+* Added ValidationError class to better describe errors.
+* Replaced the error level enum by ValidationError::SEVERITY_ and ValidationError::ACTION_, which are linked in $egErrorActions.
+
+### Version 0.3.6 (2010-08-26)
+
+* Added support for 'tolower' argument in parameter info definitions.
+
+### Version 0.3.5 (2010-07-26)
+
+* Fixed issue with the original parameter name (and in some cases also value) in error messages.
+
+### Version 0.3.4 (2010-07-07)
+
+* Fixed issue with parameter reference that occurred in php 5.3 and later.
+* Fixed escaping issue that caused parameter names in error messages to be shown incorrectly.
+* Fixed small issue with parameter value trimming that caused problems when objects where passed.
+
+### Version 0.3.3 (2010-06-20)
+
+* Fixed bug that caused notices when using the ValidatorManager::manageParsedParameters method in some cases.
+
+### Version 0.3.2 (2010-06-07)
+
+* Added lower casing to parameter names, and optionally, but default on, lower-casing for parameter values.
+* Added removal of default parameters from the default parameter queue when used as a named parameter.
+
+### Version 0.3.1 (2010-06-04)
+
+* Added ValidatorManager::manageParsedParameters and Validator::setParameters.
+
+### Version 0.3 (2010-05-31)
+
+* Added generic default parameter support.
+* Added parameter dependency support.
+* Added full meta data support for validation and formatting functions, enabling more advanced handling of parameters.
+* Major refactoring to conform to MediaWiki convention.
+
+### Version 0.2.2 (2010-03-01)
+
+* Fixed potential xss vectors.
+* Minor code improvements.
+
+### Version 0.2.1 (2010-02-01)
+
+* Changed the inclusion of the upper bound for range validation functions.
+* Small language fixes.
+
+### Version 0.2 (2009-12-25)
+
+* Added handling for lists of a type, instead of having list as a type. This includes per-item-validation and per-item-defaulting.
+* Added list validation functions: item_count and unique_items
+* Added boolean, number and char types.
+* Added support for output types. The build in output types are lists, arrays, booleans and strings. Via a hook you can add your own output types.
+* Added Validator_ERRORS_MINIMAL value for $egValidatorErrorLevel.
+* Added warning message to ValidatorManager that will be shown for errors when egValidatorErrorLevel is Validator_ERRORS_WARN.
+* Added criteria support for is_boolean, has_length and regex.
+
+### Version 0.1 (2009-12-17)
+
+* Initial release, featuring parameter validation, defaulting and error generation.
+
+## Links
+
+* [Validator on Packagist](https://packagist.org/packages/mediawiki/validator)
+* [Validator on Ohloh](https://www.ohloh.net/p/validator)
+* [Validator on MediaWiki.org](https://www.mediawiki.org/wiki/Extension:Validator)
diff --git a/www/wiki/extensions/Validator/Validator.php b/www/wiki/extensions/Validator/Validator.php
new file mode 100644
index 00000000..d172e129
--- /dev/null
+++ b/www/wiki/extensions/Validator/Validator.php
@@ -0,0 +1,82 @@
+<?php
+
+/**
+ * Initialization file for the Validator MediaWiki extension.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+
+if ( defined( 'ParamProcessor_VERSION' ) ) {
+ // Do not initialize more than once.
+ return 1;
+}
+
+define( 'Validator_VERSION', '2.2.1' );
+define( 'ParamProcessor_VERSION', Validator_VERSION ); // @deprecated since 1.0
+
+// Internationalization
+$GLOBALS['wgMessagesDirs']['Validator'] = __DIR__ . '/i18n';
+
+
+$GLOBALS['wgExtensionFunctions'][] = function () {
+ if ( version_compare( $GLOBALS['wgVersion'], '1.23c', '<' ) ) {
+ die( '<b>Error:</b> This version of Validator requires MediaWiki 1.23 or above.' );
+ }
+
+ if ( is_readable( __DIR__ . '/vendor/autoload.php' ) ) {
+ include_once( __DIR__ . '/vendor/autoload.php' );
+ }
+
+ if ( !class_exists( ParamProcessor\Processor::class ) ) {
+ throw new Exception( 'Validator depends on the ParamProcessor library.' );
+ }
+
+ // Display extension information
+ $GLOBALS['wgExtensionCredits']['other'][] = array(
+ 'path' => __FILE__,
+ 'name' => 'Validator',
+ 'version' => Validator_VERSION,
+ 'author' => array(
+ '[https://www.mediawiki.org/wiki/User:Jeroen_De_Dauw Jeroen De Dauw]'
+ ),
+ 'url' => 'https://github.com/JeroenDeDauw/Validator',
+ 'descriptionmsg' => 'validator-desc',
+ 'license-name' => 'GPL-2.0+'
+ );
+
+ /**
+ * Hook to add PHPUnit test cases.
+ * @see https://www.mediawiki.org/wiki/Manual:Hooks/UnitTestsList
+ *
+ * @since 1.0
+ *
+ * @param array $files
+ *
+ * @return boolean
+ */
+ $GLOBALS['wgHooks']['UnitTestsList'][] = function( array &$files ) {
+ // @codeCoverageIgnoreStart
+ $directoryIterator = new RecursiveDirectoryIterator( __DIR__ . '/tests/phpunit/' );
+
+ /**
+ * @var SplFileInfo $fileInfo
+ */
+ foreach ( new RecursiveIteratorIterator( $directoryIterator ) as $fileInfo ) {
+ if ( substr( $fileInfo->getFilename(), -8 ) === 'Test.php' ) {
+ $files[] = $fileInfo->getPathname();
+ }
+ }
+
+ return true;
+ // @codeCoverageIgnoreEnd
+ };
+
+ $GLOBALS['wgDataValues']['mediawikititle'] = ParamProcessor\MediaWikiTitleValue::class;
+
+ $GLOBALS['wgParamDefinitions']['title'] = array(
+ 'string-parser' => ParamProcessor\TitleParser::class,
+ 'validator' => ValueValidators\TitleValidator::class,
+ );
+};
+
diff --git a/www/wiki/extensions/Validator/build/travis/after_success.sh b/www/wiki/extensions/Validator/build/travis/after_success.sh
new file mode 100644
index 00000000..62e3bd6c
--- /dev/null
+++ b/www/wiki/extensions/Validator/build/travis/after_success.sh
@@ -0,0 +1,14 @@
+#! /bin/bash
+
+set -x
+
+originalDirectory=$(pwd)
+
+if [ "$TYPE" == "coverage" ]
+then
+ wget https://scrutinizer-ci.com/ocular.phar
+ du -hs $originalDirectory/build/coverage.clover
+ ls -lap $originalDirectory
+ ls -lap $originalDirectory/build
+ php ocular.phar code-coverage:upload --format=php-clover $originalDirectory/build/coverage.clover
+fi \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/build/travis/before_script.sh b/www/wiki/extensions/Validator/build/travis/before_script.sh
new file mode 100644
index 00000000..1221cb0c
--- /dev/null
+++ b/www/wiki/extensions/Validator/build/travis/before_script.sh
@@ -0,0 +1,39 @@
+#! /bin/bash
+
+set -x
+
+originalDirectory=$(pwd)
+
+cd ..
+
+wget https://github.com/wikimedia/mediawiki-core/archive/$MW.tar.gz
+tar -zxf $MW.tar.gz
+mv mediawiki-$MW phase3
+
+cd phase3
+
+composer self-update
+composer install --prefer-source
+
+mysql -e 'create database its_a_mw;'
+php maintenance/install.php --dbtype $DBTYPE --dbuser root --dbname its_a_mw --dbpath $(pwd) --pass nyan TravisWiki admin
+
+cd extensions
+
+cp -r $originalDirectory Validator
+
+cd Validator
+composer install --prefer-source
+composer require 'phpunit/phpunit=3.7.*' --prefer-source
+
+cd ../..
+
+echo 'require_once( __DIR__ . "/extensions/Validator/Validator.php" );' >> LocalSettings.php
+
+echo 'error_reporting(E_ALL| E_STRICT);' >> LocalSettings.php
+echo 'ini_set("display_errors", 1);' >> LocalSettings.php
+echo '$wgShowExceptionDetails = true;' >> LocalSettings.php
+echo '$wgDevelopmentWarnings = true;' >> LocalSettings.php
+echo "putenv( 'MW_INSTALL_PATH=$(pwd)' );" >> LocalSettings.php
+
+php maintenance/update.php --quick
diff --git a/www/wiki/extensions/Validator/build/travis/script.sh b/www/wiki/extensions/Validator/build/travis/script.sh
new file mode 100644
index 00000000..1fd5f119
--- /dev/null
+++ b/www/wiki/extensions/Validator/build/travis/script.sh
@@ -0,0 +1,14 @@
+#! /bin/bash
+
+set -x
+
+originalDirectory=$(pwd)
+
+cd ../phase3/tests/phpunit
+
+if [ "$TYPE" == "coverage" ]
+then
+ php phpunit.php --group Validator -c ../../extensions/Validator/phpunit.xml.dist --coverage-clover $originalDirectory/build/coverage.clover
+else
+ php phpunit.php --group Validator -c ../../extensions/Validator/phpunit.xml.dist
+fi \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/composer.json b/www/wiki/extensions/Validator/composer.json
new file mode 100644
index 00000000..ca0efcb9
--- /dev/null
+++ b/www/wiki/extensions/Validator/composer.json
@@ -0,0 +1,48 @@
+{
+ "name": "mediawiki/validator",
+ "type": "mediawiki-extension",
+ "description": "MediaWiki wrapper for the ParamProcessor library",
+ "keywords": [
+ "ParamProcessor",
+ "Validator",
+ "MediaWiki",
+ "SMW",
+ "Semantic MediaWiki"
+ ],
+ "homepage": "https://github.com/JeroenDeDauw/Validator",
+ "license": "GPL-2.0+",
+ "authors": [
+ {
+ "name": "Jeroen De Dauw",
+ "email": "jeroendedauw@gmail.com",
+ "homepage": "http://jeroendedauw.com",
+ "role": "Developer"
+ }
+ ],
+ "support": {
+ "irc": "irc://irc.freenode.net/mediawiki"
+ },
+ "require": {
+ "php": ">=5.5.0",
+ "param-processor/param-processor": "~1.1"
+ },
+ "require-dev": {
+ "data-values/common": "~0.3.1"
+ },
+ "autoload": {
+ "files" : [
+ "Validator.php"
+ ],
+ "psr-4": {
+ "ParamProcessor\\": "src/ParamProcessor/"
+ },
+ "classmap": [
+ "src/legacy/"
+ ]
+ },
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.2.x-dev"
+ }
+ }
+}
diff --git a/www/wiki/extensions/Validator/i18n/af.json b/www/wiki/extensions/Validator/i18n/af.json
new file mode 100644
index 00000000..0af79f5e
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/af.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Naudefj"
+ ]
+ },
+ "validator-desc": "Die valideerder gee ander uitbreidings die vermoë om parameters van ontlederfunksies en etiket-uitbreidings te valideer, op hulle verstekwaardes in te stel en om foutboodskappe te genereer",
+ "validator-warning": "Waarskuwing: $1",
+ "validator-error": "Fout: $1",
+ "validator-fatal-error": "Onherstelbare fout: $1",
+ "validator_error_parameters": "Die volgende {{PLURAL:$1|fout|foute}} is in u sintaks waargeneem:",
+ "validator_error_unknown_argument": "$1 is nie 'n geldige parameter nie.",
+ "validator_error_required_missing": "Die verpligte parameter $1 is nie verskaf nie.",
+ "validator-type-string": "teks",
+ "validator-type-integer": "geheel getal",
+ "validator-type-float": "getal",
+ "validator-type-boolean": "ja/nee",
+ "validator-type-char": "karakter",
+ "validator-type-title": "titel",
+ "validator-type-string-list": "lys met tekste",
+ "validator-type-integer-list": "lys met gehele getalle",
+ "validator-type-float-list": "lys met getalle",
+ "validator-type-boolean-list": "lys met ja/nee",
+ "validator-type-char-list": "lys met karakters",
+ "validator-type-title-list": "lys met titels",
+ "validator-listerrors-errors": "Foute",
+ "validator-listerrors-minor": "Oorkomelik",
+ "validator-listerrors-low": "Laag",
+ "validator-listerrors-normal": "Gemiddeld",
+ "validator-listerrors-high": "Groot",
+ "validator-listerrors-fatal": "Fataal",
+ "validator-describe-descriptionmsg": "'''Beskrywing''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasse}}''': $1",
+ "validator-describe-listtype": "Lys met $1 items",
+ "validator-describe-empty": "leeg",
+ "validator-describe-required": "verpligtend",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliasse",
+ "validator-describe-header-type": "Tipe",
+ "validator-describe-header-default": "Standaard",
+ "validator-describe-header-description": "Beskrywing",
+ "validator-describe-parameters": "Parameters",
+ "validator-describe-syntax": "Sintaks",
+ "validator_error_empty_argument": "Die parameter $1 mag nie leeg wees nie.",
+ "validator_error_must_be_number": "Die parameter $1 mag net 'n getal wees.",
+ "validator_error_must_be_integer": "Die parameter $1 kan slegs 'n heelgetal wees.",
+ "validator_error_invalid_range": "Die parameter $1 moet tussen $2 en $3 lê.",
+ "validator_error_invalid_argument": "Die waarde $1 is nie geldig vir parameter $2 nie.",
+ "validator_error_accepts_only": "Die parameter $1 kan slegs die volgende {{PLURAL:$3|waarde|waardes}} hê: $2.",
+ "validator-message-nodesc": "Geen beskrywing"
+}
diff --git a/www/wiki/extensions/Validator/i18n/aln.json b/www/wiki/extensions/Validator/i18n/aln.json
new file mode 100644
index 00000000..46b97e1c
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/aln.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mdupont"
+ ]
+ },
+ "validator-desc": "Validator është një zgjerim MediaWiki që ofron parametër përgjithshme trajtimin mbështetje të shtesave të tjera",
+ "validator_error_parameters": "Më poshtë {{PLURAL:$1|gabim ka gabime|kanë}} është zbuluar në sintaksën e juaj:",
+ "validator_warning_parameters": "Ka {{PLURAL:$1|është|janë gabime gabim}} në sintaksë tuaj.",
+ "validator_error_unknown_argument": "$1 nuk është një parametër i vlefshëm.",
+ "validator_error_required_missing": "Parametrat e nevojshëm $1 nuk jepet.",
+ "validator_error_empty_argument": "Parametër $1 nuk mund të ketë një vlerë bosh.",
+ "validator_error_must_be_number": "Parametër $1 mund të jetë vetëm një numër.",
+ "validator_error_must_be_integer": "Parametër $1 mund të jetë vetëm një numër i plotë.",
+ "validator_error_invalid_range": "Parametër $1 duhet të jetë në mes të $2 dhe $3.",
+ "validator_error_invalid_argument": "Vlera $1 nuk është i vlefshëm për parametër $2.",
+ "validator_list_error_empty_argument": "Parametër $1 nuk e pranon vlerat bosh.",
+ "validator_list_error_must_be_number": "Parametër $1 mund të përmbajë vetëm numrat.",
+ "validator_list_error_must_be_integer": "Parametër $1 mund të përmbajë vetëm numra të plotë.",
+ "validator_list_error_invalid_range": "Të gjitha vlerat e parametrit $1 duhet të jetë në mes të $2 dhe $3.",
+ "validator_list_error_invalid_argument": "Një ose më shumë vlera për parametër $1 janë të pavlefshme.",
+ "validator_error_accepts_only": "Parametër $1 vetëm pranon {{PLURAL:$3|kjo vlerë|këtyre vlerave}}: $2.",
+ "validator_list_omitted": "{{PLURAL:$2 |vlerë|vlerat}} $1 {{PLURAL:$2|ka|kanë}} janë lënë jashtë."
+}
diff --git a/www/wiki/extensions/Validator/i18n/ar.json b/www/wiki/extensions/Validator/i18n/ar.json
new file mode 100644
index 00000000..8ed5864a
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ar.json
@@ -0,0 +1,48 @@
+{
+ "@metadata": {
+ "authors": [
+ "Meno25",
+ "روخو"
+ ]
+ },
+ "validator-desc": "المحقق يوفر طريقة سهلة للامتدادات الأخرى للتحقق من محددات دوال المحلل وامتدادات الوسوم، وضبط القيم الافتراضية وتوليد رسائل الخطأ",
+ "validator-warning": "تحذير: $1",
+ "validator-error": "خطأ: $1",
+ "validator-fatal-error": "خطأ قاتل: $1",
+ "validator_error_parameters": "{{PLURAL:$1|الخطأ التالي|الاخطاء التالية}} تم كشفها في صياغتك:",
+ "validator_warning_parameters": "هناك {{PLURAL:$1|خطأ|أخطاء}} في صياغتك.",
+ "validator_error_unknown_argument": "$1 ليس محددا صحيحا.",
+ "validator_error_required_missing": "المحدد المطلوب $1 ليس متوفرا.",
+ "validator-type-string": "نص",
+ "validator-type-float": "رقم",
+ "validator-type-boolean": "نعم/لا",
+ "validator-type-title": "عنوان",
+ "validator-listerrors-errors": "أخطاء",
+ "validator-listerrors-minor": "ثانوي",
+ "validator-listerrors-low": "منخفض",
+ "validator-listerrors-normal": "طبيعي",
+ "validator-listerrors-high": "مرتفع",
+ "validator-listerrors-fatal": "قاتل",
+ "validator-describe-descriptionmsg": "'''وصف''': $1",
+ "validator-describe-empty": "فارغ",
+ "validator-describe-required": "مطلوب",
+ "validator-describe-header-parameter": "محدد",
+ "validator-describe-header-type": "نوع",
+ "validator-describe-header-default": "افتراضي",
+ "validator-describe-header-description": "الوصف",
+ "validator-describe-parameters": "محددات",
+ "validator-describe-syntax": "صياغة",
+ "validator_error_empty_argument": "المحدد $1 لا يمكن أن تكون قيمته فارغة.",
+ "validator_error_must_be_number": "المحدد $1 يمكن أن يكون فقط عددا.",
+ "validator_error_must_be_integer": "المحدد $1 يمكن أن يكون عددا صحيحا فقط.",
+ "validator_error_invalid_range": "المحدد $1 يجب أن يكون بين $2 و $3.",
+ "validator_error_invalid_argument": "القيمة $1 ليست صحيحة للمحدد $2.",
+ "validator_list_error_empty_argument": "المحدد $1 لا يقبل القيم الفارغة.",
+ "validator_list_error_must_be_number": "المحدد $1 يمكن أن يحتوي فقط على أرقام.",
+ "validator_list_error_must_be_integer": "المحدد $1 يمكن أن يحتوي فقط على أرقام صحيحة.",
+ "validator_list_error_invalid_range": "كل قيم المحدد $1 يجب أن تكون بين $2 و$3.",
+ "validator_list_error_invalid_argument": "قيمة واحدة أو أكثر للمحدد $1 غير صحيحة.",
+ "validator_error_accepts_only": "المحدد $1 يقبل فقط {{PLURAL:$3|هذه القيمة|هذه القيم}}: $2.",
+ "validator_list_omitted": "{{PLURAL:$2|القيمة|القيم}} $1 {{PLURAL:$2|تم|تم}} مسحها.",
+ "validator-message-nodesc": "لا وصف تم توفيره"
+}
diff --git a/www/wiki/extensions/Validator/i18n/be-tarask.json b/www/wiki/extensions/Validator/i18n/be-tarask.json
new file mode 100644
index 00000000..209fdc80
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/be-tarask.json
@@ -0,0 +1,96 @@
+{
+ "@metadata": {
+ "authors": [
+ "EugeneZelenko",
+ "Jim-by",
+ "Wizardist",
+ "Red Winged Duck"
+ ]
+ },
+ "validator-desc": "Бібліятэка апрацоўкі дэкляратыўных парамэтраў",
+ "validator-warning": "Папярэджаньне: $1",
+ "validator-error": "Памылка: $1",
+ "validator-fatal-error": "Крытычная памылка: $1",
+ "validator_error_parameters": "У вашым сынтаксісе {{PLURAL:$1|1=выяўленая наступная памылка|выяўленыя наступныя памылкі}}:",
+ "validator_warning_parameters": "У вашым сынтаксісе {{PLURAL:$1|1=маецца памылка|маюцца памылкі}}.",
+ "validator-warning-adittional-errors": "… і {{PLURAL:$1|1=яшчэ адна праблема|яшчэ некалькі праблемаў}}.",
+ "validator-error-omitted": "{{PLURAL:$2|1=Значэньне «$1» было прапушчанае|Значэньні «$1» былі прапушчаныя}}.",
+ "validator-error-problem": "Узьнікла праблема з парамэтрам $1.",
+ "validator_error_unknown_argument": "Няслушны парамэтар $1.",
+ "validator_error_required_missing": "Не пададзены абавязковы парамэтар $1.",
+ "validator-error-override-argument": "Спрабаваў памяняць значэньне парамэтру $1 з «$2» на «$3»",
+ "validator-type-string": "тэкст",
+ "validator-type-integer": "цэлы лік",
+ "validator-type-float": "лік",
+ "validator-type-boolean": "так/не",
+ "validator-type-char": "сымбаль",
+ "validator-type-dimension": "колькасьць і адзінка вымярэньня",
+ "validator-type-title": "назва",
+ "validator-type-string-list": "сьпіс тэкстаў",
+ "validator-type-integer-list": "сьпіс цэлых лікаў",
+ "validator-type-float-list": "сьпіс лічбаў",
+ "validator-type-boolean-list": "сьпіс «так/не»",
+ "validator-type-char-list": "сьпіс сымбаляў",
+ "validator-type-title-list": "сьпіс загалоўкаў",
+ "validator-listerrors-errors": "Памылкі",
+ "validator-listerrors-minor": "Дробная",
+ "validator-listerrors-low": "Малая",
+ "validator-listerrors-normal": "Звычайная",
+ "validator-listerrors-high": "Значная",
+ "validator-listerrors-fatal": "Фатальная",
+ "validator-listerrors-description": "Пералічвае памылкі (і папярэджаньні), якія адбыліся ў працэдурах-перахопніках парсэра, дададзеных праз Validator.\nПаказваюцца толькі працэдуры-перахопнікі парсэра, якія знаходзяцца Вышэй listerrors.\nЗьмясьціце listerrors у самы канец старонкі, каб атрымаць сьпіс усіх памылак.",
+ "validator-listerrors-par-minseverity": "Мінімальная сур’ёзнасьць праблемы, для таго каб яна была ўключаная ў сьпіс.",
+ "validator-describe-description": "Стварае дакумэнтацыю для аднаго ці болей працэдур-перахопнікаў парсэра, атрымаўшым вызначэньне праз Validator.",
+ "validator-describe-notfound": "Не існуе працэдур-перахопніка парсэра для «$1».",
+ "validator-describe-descriptionmsg": "'''Апісаньне''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|1=Псэўданім|Псэўданімы}}''': $1",
+ "validator-describe-parserfunction": "Рэалізаваная толькі функцыя парсэру.",
+ "validator-describe-tagextension": "Рэалізаваная толькі як пашырэньне тэгу.",
+ "validator-describe-bothhooks": "Рэалізаваная як функцыя парсэру і як пашырэньне тэгу.",
+ "validator-describe-par-hooks": "Працэдура-перахопнік парсэра, для якой паказваць дакумэнтацыю.",
+ "validator-describe-par-pre": "Дазваляе Вам атрымліваць актуальны вікі-тэкст для дакумэнтацыі, без паказу на старонцы.",
+ "validator-describe-par-language": "Мова, на якой паказваць апісаньні",
+ "validator-describe-listtype": "Сьпіс элемэнтаў $1",
+ "validator-describe-empty": "пуста",
+ "validator-describe-required": "абавязкова",
+ "validator-describe-header-parameter": "Парамэтар",
+ "validator-describe-header-aliases": "Псэўданімы",
+ "validator-describe-header-type": "Тып",
+ "validator-describe-header-default": "Па змоўчваньні",
+ "validator-describe-header-description": "Апісаньне",
+ "validator-describe-parameters": "Парамэтры",
+ "validator-describe-syntax": "Сынтаксіс",
+ "validator-describe-tagmin": "Пашырэньне тэга, якое мае толькі неабходныя парамэтры.",
+ "validator-describe-tagmax": "Пашырэньне тэга з усімі парамэтрамі.",
+ "validator-describe-tagdefault": "Пашырэньне тэга з усімі парамэтрамі, выкарыстаньнем запісаў парамэтраў па змоўчваньні.",
+ "validator-describe-pfmin": "Функцыя парсэра, якае мае толькі неабходныя парамэтры.",
+ "validator-describe-pfmax": "Функцыя парсэра з усімі парамэтрамі.",
+ "validator-describe-pfdefault": "Функцыя парсэра з усімі парамэтрамі, выкарыстаньнем запісаў парамэтраў па змоўчваньні.",
+ "validator-describe-autogen": "Зьмест гэтай сэкцыі быў аўтаматычна створаны працэдурай-перахопнікам парсэра «describe» пашырэньня Validator.",
+ "validator_error_empty_argument": "Парамэтар $1 ня можа мець пустое значэньне.",
+ "validator_error_must_be_number": "Парамэтар $1 можа быць толькі лікам.",
+ "validator_error_must_be_integer": "Парамэтар $1 можа быць толькі цэлым лікам.",
+ "validator_error_must_be_title": "Парамэтар $1 можа быць роўны толькі слушнай назьве вікістаронкі.",
+ "validator_error_must_be_existing_title": "Парамэтар $1 можа быць роўны толькі назьве наяўнай вікістаронкі.",
+ "validator-error-must-be-float": "Парамэтар $1 можа быць толькі лікам з плаваючай коскай.",
+ "validator_error_invalid_range": "Парамэтар $1 павінен быць паміж $2 і $3.",
+ "validator-error-invalid-regex": "парамэтар $1 мусіць адпавядаць гэтаму рэгулярнаму выразу: $2.",
+ "validator-error-invalid-length": "Парамэтар $1 павінен мець даўжыню $2.",
+ "validator-error-invalid-length-range": "Парамэтар $1 павінен мець даўжыню паміж $2 і $3.",
+ "validator_error_invalid_argument": "Значэньне $1 не зьяўляецца слушным для парамэтру $2.",
+ "validator_list_error_empty_argument": "Парамэтар $1 ня можа прымаць пустыя значэньні.",
+ "validator_list_error_must_be_number": "Парамэтар $1 можа ўтрымліваць толькі лікі.",
+ "validator_list_error_must_be_integer": "Парамэтар $1 можа ўтрымліваць толькі цэлыя лікі.",
+ "validator_list_error_must_be_title": "Парамэтра $1 можа ўтрымліваць толькі слушныя назвы вікістаронак.",
+ "validator_list_error_must_be_existing_title": "Парамэтар $1 можа ўтрымліваць толькі назвы наяўных вікістаронак.",
+ "validator-list-error-must-be-float": "Парамэтар $1 можа ўтрымліваць толькі лікі з плаваючай кропкай.",
+ "validator_list_error_invalid_range": "Усе значэньні парамэтру $1 павінны знаходзіцца паміж $2 і $3.",
+ "validator-list-error-invalid-regex": "Усе значэньні парамэтру $1 мусяць адпавядаць гэтаму рэгулярнаму выразу: $2.",
+ "validator_list_error_invalid_argument": "Адно ці болей значэньняў парамэтру $1 зьяўляюцца няслушнымі.",
+ "validator-list-error-accepts-only": "Адно ці некалькі значэньняў парамэтру $1 зьяўляюцца няслушнымі. {{PLURAL:$3|1=Мусіць быць наступнае значэньне|Мусяць быць наступныя значэньні}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Адно ці некалькі значэньняў парамэтру $1 зьяўляюцца няслушнымі. {{PLURAL:$3|1=Мусіць быць наступнае значэньне|Мусяць быць наступныя значэньні}}: $2 (і $4 {{PLURAL:$4|прапушчанае значэньне|прапушчаныя значэньні|прапушчаных значэньняў}}).",
+ "validator_error_accepts_only": "Значэньне «$4» зьяўляецца няслушным для парамэтру $1. Ён можа прымаць толькі {{PLURAL:$3|1=гэтае значэньне|гэтыя значэньні}}: $2.",
+ "validator-error-accepts-only-omitted": "Значэньне «$2» зьяўляецца няслушным для парамэтру $1. Ён мусіць мець {{PLURAL:$5|1=наступнае значэньне|наступныя значэньні}}: $3 (і $4 {{PLURAL:$4|прапушчанае значэньне|прапушчаныя значэньні|прапушчаных значэньняў}}).",
+ "validator_list_omitted": "{{PLURAL:$2|1=Значэньне|Значэньні}} $1 {{PLURAL:$2|1=было прапушчанае|былі прапушчаныя}}.",
+ "validator-message-nodesc": "Апісаньне не пазначанае"
+}
diff --git a/www/wiki/extensions/Validator/i18n/bg.json b/www/wiki/extensions/Validator/i18n/bg.json
new file mode 100644
index 00000000..7e80a288
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/bg.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "DCLXVI",
+ "Reedy",
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "validator-type-string": "текст",
+ "validator-type-float": "номер",
+ "validator-type-title": "заглавие",
+ "validator-describe-empty": "празно",
+ "validator-describe-header-type": "Тип",
+ "validator-describe-header-default": "По подразбиране",
+ "validator-describe-parameters": "Параметри",
+ "validator_error_empty_argument": "Параметърът $1 не може да има празна стойност."
+}
diff --git a/www/wiki/extensions/Validator/i18n/bn.json b/www/wiki/extensions/Validator/i18n/bn.json
new file mode 100644
index 00000000..0ccf26c5
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/bn.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ehsanulhb"
+ ]
+ },
+ "validator-describe-descriptionmsg": "'''বিবরণ''': $1",
+ "validator-describe-header-description": "বিবরণ"
+}
diff --git a/www/wiki/extensions/Validator/i18n/br.json b/www/wiki/extensions/Validator/i18n/br.json
new file mode 100644
index 00000000..b177efc6
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/br.json
@@ -0,0 +1,73 @@
+{
+ "@metadata": {
+ "authors": [
+ "Fohanno",
+ "Fulup",
+ "Gwendal",
+ "Y-M D"
+ ]
+ },
+ "validator-desc": "Un doare aes eo kadarnataer evit an astennoù all da gadarnaat arventennoù ar fonksionoù parser hag astennoù ar balizennoù, evit termeniñ talvoudennoù dre ziouer ha sevel kemennoù fazioù",
+ "validator-warning": "Diwallit : $1",
+ "validator-error": "Fazi : $1",
+ "validator-fatal-error": "Fazi diremed: $1",
+ "validator_error_parameters": "Kavet eo bet ar {{PLURAL:$1|fazi|fazioù}} da-heul en hoc'h ereadur :",
+ "validator_warning_parameters": "{{PLURAL:$1|Ur fazi|Fazioù}} zo en hoc'h ereadur.",
+ "validator-warning-adittional-errors": "... {{PLURAL:$1|hag ur gudenn bennak all|ha meur a gudenn all}}.",
+ "validator-error-omitted": "N'eo ket bet merket ar {{PLURAL:$2|roadenn \"$1\"|roadennoù \"$1\"}}.",
+ "validator-error-problem": "Ur gudenn zo bet gant an arventenn $1.",
+ "validator_error_unknown_argument": "$1 n'eo ket un arventenn reizh.",
+ "validator_error_required_missing": "N'eo ket bet pourchaset an arventenn rekis $1",
+ "validator-error-override-argument": "Klasket en deus ar meziant erlec'hiañ an arventenn $1 (talvoud : $2) gant an talvoud \"$3\"",
+ "validator-type-string": "testenn",
+ "validator-type-integer": "Niver klok",
+ "validator-type-float": "niver",
+ "validator-type-boolean": "ya/nann",
+ "validator-type-char": "arouezenn",
+ "validator-type-title": "titl",
+ "validator-type-string-list": "roll testennoù",
+ "validator-type-integer-list": "roll niveroù anterin",
+ "validator-type-float-list": "roll niveroù",
+ "validator-type-boolean-list": "roll ya/ket",
+ "validator-type-char-list": "roll arouezennoù",
+ "validator-type-title-list": "roll titiloù",
+ "validator-listerrors-errors": "Fazioù",
+ "validator-listerrors-minor": "Minor",
+ "validator-listerrors-low": "Gwan",
+ "validator-listerrors-normal": "Reizh",
+ "validator-listerrors-high": "Uhel",
+ "validator-listerrors-fatal": "Diremed",
+ "validator-describe-descriptionmsg": "'''Deskrivadur''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasoù}}''': $1",
+ "validator-describe-listtype": "Roll gant $1 elfenn",
+ "validator-describe-empty": "goullo",
+ "validator-describe-required": "rekis",
+ "validator-describe-header-parameter": "Arventenn",
+ "validator-describe-header-aliases": "Aliasoù",
+ "validator-describe-header-type": "Seurt",
+ "validator-describe-header-default": "Dre ziouer",
+ "validator-describe-header-description": "Deskrivadur",
+ "validator-describe-parameters": "Arventennoù",
+ "validator-describe-syntax": "Ereadurezh",
+ "validator_error_empty_argument": "N'hall ket an arventenn $1 bezañ goullo he zalvoudenn",
+ "validator_error_must_be_number": "Un niver e rank an arventenn $1 bezañ hepken.",
+ "validator_error_must_be_integer": "Rankout a ra an arventenn $1 bezañ un niver anterin.",
+ "validator-error-must-be-float": "Rankout a ra an arventenn $1 bezañ un niver skej war-neuñv.",
+ "validator_error_invalid_range": "Rankout a ra an arventenn $1 bezañ etre $2 hag $3.",
+ "validator-error-invalid-regex": "Rankout a ra an arventenn $1 klotañ gant ar jedad poellek-mañ : $2.",
+ "validator-error-invalid-length": "Ret eo d'an arventenn $1 bezañ par he hed da $2.",
+ "validator-error-invalid-length-range": "Rankout a ra an arventenn $1 bezañ he hed etre $2 hag $3.",
+ "validator_error_invalid_argument": "N'eo ket reizh an dalvoudenn $1 evit an arventenn $2.",
+ "validator_list_error_empty_argument": "Ne zegemer ket an arventenn $1 an talvoudennoù goullo.",
+ "validator_list_error_must_be_number": "N'hall bezañ nemet niveroù en arventenn $1.",
+ "validator_list_error_must_be_integer": "N'hall bezañ nemet niveroù anterin en arventenn $1.",
+ "validator-list-error-must-be-float": "N'hall bezañ nemet niveroù gant skej en arventenn $1.",
+ "validator_list_error_invalid_range": "An holl talvoudennoù eus an arventenn $1 a rank bezañ etre $2 ha $3.",
+ "validator-list-error-invalid-regex": "Rankout a ra holl dalvoudoù an arventenn $1 klotañ gant ar jedad poellek-mañ : $2.",
+ "validator_list_error_invalid_argument": "Faziek eo unan pe meur a dalvoudenn eus an arventenn $1.",
+ "validator-list-error-accepts-only": "Direizh eo unan pe meur a hini eus an talvoudoù evit an arventenn $1.\nNe zegemer nemet an {{PLURAL:$3|talvoud|talvoudoù}}-mañ : $2.",
+ "validator-list-error-accepts-only-omitted": "Direizh eo unan pe meur a hini eus an talvoudoù evit an arventenn $1.\nNe zegemer nemet an {{PLURAL:$3|talvoud|talvoudoù}}-mañ : $2 (ha $4 {{PLURAL:$4|talvoud anroet|talvoud anroet}}).",
+ "validator_error_accepts_only": "Ne zegemer ket an arventenn $1 an talvoud \"$4\". Ne zegemer nemet {{PLURAL:$3|an talvoud|an talvoudoù}}-mañ : $2.",
+ "validator-error-accepts-only-omitted": "Direizh eo an talvoud \"$2\" evit an arventenn $1.\nNe zegemer nemet an {{PLURAL:$5|talvoud|talvoudoù}}-mañ : $3 (ha $4 {{PLURAL:$4|talvoud anroet|talvoud anroet}}).",
+ "validator_list_omitted": "Disoñjet eo bet an {{PLURAL:$2|talvoudenn|talvoudennoù}} $1."
+}
diff --git a/www/wiki/extensions/Validator/i18n/bs.json b/www/wiki/extensions/Validator/i18n/bs.json
new file mode 100644
index 00000000..bc939009
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/bs.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "CERminator"
+ ]
+ },
+ "validator-desc": "Validator pruža jednostavni način za druga proširenja u svrhu validacije parametara parserskih funkcija i proširenja oznaka, postavlja pretpostavljene vrijednosti i generira poruke pogrešaka.",
+ "validator-warning": "Upozorenje: $1",
+ "validator-error": "Greška: $1",
+ "validator-fatal-error": "Fatalna greška: $1",
+ "validator_error_parameters": "U Vašoj sintaksi {{PLURAL:$1|je|su}} {{PLURAL:$1|otkivena slijedeća greška|otkrivene slijedeće greške}}:",
+ "validator_warning_parameters": "{{PLURAL:$1|Postoji greška|Postoje greške}} u Vašoj sintaksi.",
+ "validator-warning-adittional-errors": "... i {{PLURAL:$1|još jedan problem|još nekoliko problema}}.",
+ "validator_error_unknown_argument": "$1 nije valjan parametar.",
+ "validator_error_required_missing": "Obavezni parametar $1 nije naveden.",
+ "validator-error-override-argument": "Pokušano da se preskoči parametar $1 (vrijednost: $2) vrijednošću \"$3\"",
+ "validator-listerrors-normal": "Normalno",
+ "validator_error_empty_argument": "Parametar $1 ne može imati praznu vrijednost.",
+ "validator_error_must_be_number": "Parametar $1 može biti samo broj.",
+ "validator_error_must_be_integer": "Parametar $1 može biti samo cijeli broj.",
+ "validator-error-must-be-float": "Parametar $1 može biti samo broj sa plutajućim zarezom.",
+ "validator_error_invalid_range": "Parametar $1 mora biti između $2 i $3.",
+ "validator-error-invalid-length": "Parametar $1 mora imati dužinu $2.",
+ "validator-error-invalid-length-range": "Parametar $1 mora imati dužinu između $2 i $3.",
+ "validator_error_invalid_argument": "Vrijednost $1 nije valjana za parametar $2.",
+ "validator_list_error_empty_argument": "Parametar $1 ne prima prazne vrijednosti.",
+ "validator_list_error_must_be_number": "Parametar $1 može sadržavati samo brojeve.",
+ "validator_list_error_must_be_integer": "Parametar $1 može sadržavati samo cijele brojeve.",
+ "validator_list_error_invalid_range": "Sve vrijednosti parametra $1 moraju biti između $2 i $3.",
+ "validator_list_error_invalid_argument": "Jedna ili više vrijednosti za parametar $1 nisu valjane.",
+ "validator_error_accepts_only": "Vrijednost \"$4\" nije valjana za parametar $1. On prihvata samo {{PLURAL:$3|ovu vrijednost|ove vrijednosti}}: $2.",
+ "validator_list_omitted": "{{PLURAL:$2|Vrijednost|Vrijednosti}} $1 {{PLURAL:$2|je ispuštena|su ispuštene}}."
+}
diff --git a/www/wiki/extensions/Validator/i18n/ca.json b/www/wiki/extensions/Validator/i18n/ca.json
new file mode 100644
index 00000000..d1f307ea
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ca.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Luckas"
+ ]
+ },
+ "validator-describe-descriptionmsg": "'''Descripció''': $1",
+ "validator-describe-header-description": "Descripció"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ce.json b/www/wiki/extensions/Validator/i18n/ce.json
new file mode 100644
index 00000000..ffac3a87
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ce.json
@@ -0,0 +1,37 @@
+{
+ "@metadata": {
+ "authors": [
+ "Умар"
+ ]
+ },
+ "validator-warning": "Тергам: $1",
+ "validator-error": "ГӀалат: $1",
+ "validator-fatal-error": "Кхераме гӀалат: $1",
+ "validator-warning-adittional-errors": "… и {{PLURAL:$1|1=кхин цхьа бала|кхин маситта баланаш}}.",
+ "validator-type-string": "йоза",
+ "validator-type-integer": "дуьззина терахь",
+ "validator-type-float": "терахь",
+ "validator-type-boolean": "хӀаъ/хӀахӀа",
+ "validator-type-char": "символ",
+ "validator-type-title": "цӀе",
+ "validator-type-string-list": "йозанийн могӀам",
+ "validator-type-integer-list": "дуьззина терхьийн могӀам",
+ "validator-type-float-list": "терхьийн могӀам",
+ "validator-type-boolean-list": "могӀам хӀаъ/хӀахӀа",
+ "validator-type-char-list": "символийн могӀам",
+ "validator-type-title-list": "цӀерийн могӀам",
+ "validator-listerrors-errors": "ГӀалаташ",
+ "validator-listerrors-minor": "Ладамбоцу",
+ "validator-listerrors-low": "Лахара",
+ "validator-listerrors-normal": "ЛартӀахь",
+ "validator-listerrors-high": "Лаккхара",
+ "validator-listerrors-fatal": "Фаталан",
+ "validator-describe-descriptionmsg": "'''Цуьнах лаьцна''': $1",
+ "validator-describe-par-language": "Яздаран йолу интерфейсан мотт",
+ "validator-describe-required": "оьшу",
+ "validator-describe-header-type": "Тайпа",
+ "validator-describe-header-default": "Iад йитарца",
+ "validator-describe-header-description": "Цуьнах лаьцна",
+ "validator-describe-parameters": "Параметраш",
+ "validator-describe-syntax": "Синтаксис"
+}
diff --git a/www/wiki/extensions/Validator/i18n/cs.json b/www/wiki/extensions/Validator/i18n/cs.json
new file mode 100644
index 00000000..db27d683
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/cs.json
@@ -0,0 +1,70 @@
+{
+ "@metadata": {
+ "authors": [
+ "Matěj Grabovský",
+ "Mormegil",
+ "Reaperman",
+ "Vks",
+ "XenoPheX",
+ "Dvorapa"
+ ]
+ },
+ "validator-desc": "Knihovna pro deklarativní zpracování parametrů",
+ "validator-warning": "Varování: $1",
+ "validator-error": "Chyba: $1",
+ "validator-fatal-error": "Kritická chyba: $1",
+ "validator_error_parameters": "Ve vaší syntaxi {{PLURAL:$1|byla nalezena následující chyba|byly nalezeny následující chyby}}:",
+ "validator_warning_parameters": "Ve vaší syntaxi {{PLURAL:$1|je chyba|jsou chyby}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Hodnota „$1“ byla|Hodnoty „$1“ byly}} vynechány.",
+ "validator-error-problem": "Vyskytl se problém s parametrem $1.",
+ "validator_error_unknown_argument": "$1 není platný parametr.",
+ "validator_error_required_missing": "Povinný parameter $1 nebyl specifikován.",
+ "validator-type-string": "text",
+ "validator-type-integer": "celé číslo",
+ "validator-type-float": "číslo",
+ "validator-type-boolean": "ano/ne",
+ "validator-type-char": "znak",
+ "validator-type-dimension": "číslo a jednotka délky",
+ "validator-listerrors-errors": "Chyby",
+ "validator-listerrors-low": "Nízká",
+ "validator-listerrors-normal": "Střední",
+ "validator-listerrors-high": "Vysoká",
+ "validator-listerrors-fatal": "Kritická",
+ "validator-describe-descriptionmsg": "''' Popis ''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasy}}''': $1",
+ "validator-describe-empty": "prázdné",
+ "validator-describe-required": "vyžadované",
+ "validator-describe-header-parameter": "Parametr",
+ "validator-describe-header-aliases": "Aliasy",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Výchozí",
+ "validator-describe-header-description": "Popis",
+ "validator-describe-parameters": "Parametry",
+ "validator-describe-syntax": "Syntaxe",
+ "validator_error_empty_argument": "Parametr $1 nemůže být prázdný.",
+ "validator_error_must_be_number": "Parametr $1 může být pouze číslo.",
+ "validator_error_must_be_integer": "Parametr $1 může být pouze celé číslo.",
+ "validator_error_must_be_title": "Parametr $1 může být pouze platný název wiki stránky.",
+ "validator_error_must_be_existing_title": "Parametr $1 může být pouze název existující wiki stránky.",
+ "validator-error-must-be-float": "Parametr $1 může být pouze číslo s desetinnou čárkou.",
+ "validator_error_invalid_range": "Parametr $1 musí být v rozmezí $2 až $3.",
+ "validator-error-invalid-regex": "Parametr $1 musí odpovídat tomuto regulárnímu výrazu: $2.",
+ "validator-error-invalid-length": "Parametr $1 musí mít délku $2.",
+ "validator-error-invalid-length-range": "Parametr $1 musí mít délku mezi $2 a $3.",
+ "validator_error_invalid_argument": "$1 není platná hodnota pro parametr $2.",
+ "validator_list_error_empty_argument": "Parametr $1 npeřijímá prázdné hoodnoty.",
+ "validator_list_error_must_be_number": "Parametr $1 může obsahovat pouze čísla.",
+ "validator_list_error_must_be_integer": "Paramter $1 může obsahovat pouze celá čísla.",
+ "validator_list_error_must_be_title": "Parametr $1 může obsahovat pouze platné názvy wiki stránek.",
+ "validator_list_error_must_be_existing_title": "Parametr $1 může obsahovat pouze názvy existujících wiki stránek.",
+ "validator-list-error-must-be-float": "Parametr $1 může obsahovat pouze čísla s desetinnou čárkou.",
+ "validator_list_error_invalid_range": "Všechny hodnoty parametru $1 musí být v rozmezí $2 až $3.",
+ "validator-list-error-invalid-regex": "Všechny hodnoty parametru $1 musí odpovídat tomuto regulárnímu výrazu: $2.",
+ "validator_list_error_invalid_argument": "Jedna nebo více hodnot parametru $1 jsou neplatné.",
+ "validator-list-error-accepts-only": "Jedna či více hodnot parametru $1 jsou neplatné. {{{{PLURAL:$3|Platná je pouze tato hodnota|Platné jsou pouze tyto hodnoty}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Jedna či více hodnot parametru $1 jsou neplatné. {{PLURAL:$3|Platná je pouze tato hodnota|Platné jsou pouze tyto hodnoty}}: $2 (a $4 {{PLURAL:$4|vynechaná hodnota|vynechané hodnoty|vynechaných hodnot}}).",
+ "validator_error_accepts_only": "Parametr $1 nemůže mít hodnotu „$4“; přijímá pouze {{PLURAL:$3|tuto hodnotu|tyto hodnoty}}: $2.",
+ "validator-error-accepts-only-omitted": "Hodnota \"$2\" není pro parametr $1 platná. {{PLURAL:$3|Platná je pouze tato hodnota|Platné jsou pouze tyto hodnoty}}: $2 (a $4 {{PLURAL:$4|vynechaná hodnota|vynechané hodnoty}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Hodnota $1 byla vynechána|Hodnoty $1 byly vynechány}}.",
+ "validator-message-nodesc": "Popis není k dispozici"
+}
diff --git a/www/wiki/extensions/Validator/i18n/cu.json b/www/wiki/extensions/Validator/i18n/cu.json
new file mode 100644
index 00000000..79c70a5a
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/cu.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "ОйЛ"
+ ]
+ },
+ "validator-error": "блаꙁна : $1",
+ "validator-listerrors-errors": "блаꙁнꙑ"
+}
diff --git a/www/wiki/extensions/Validator/i18n/da.json b/www/wiki/extensions/Validator/i18n/da.json
new file mode 100644
index 00000000..d8740e41
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/da.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Christian List"
+ ]
+ },
+ "validator-type-string": "tekst"
+}
diff --git a/www/wiki/extensions/Validator/i18n/de.json b/www/wiki/extensions/Validator/i18n/de.json
new file mode 100644
index 00000000..d80e0fc8
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/de.json
@@ -0,0 +1,99 @@
+{
+ "@metadata": {
+ "authors": [
+ "DaSch",
+ "Imre",
+ "Kghbln",
+ "LWChris",
+ "Metalhead64",
+ "Purodha",
+ "Das Schäfchen"
+ ]
+ },
+ "validator-desc": "Stellt anderen Programmerweiterungen eine deklarative Bibliothek zur Verarbeitung von Parametern bereit",
+ "validator-warning": "Warnung: $1",
+ "validator-error": "Fehler: $1",
+ "validator-fatal-error": "'''Schwerwiegender Fehler:''' $1",
+ "validator_error_parameters": "{{PLURAL:$1|Der folgende Fehler wurde|Die folgenden Fehler wurden}} in der Syntax gefunden:",
+ "validator_warning_parameters": "{{PLURAL:$1|Es ist ein Fehler|Es sind Fehler}} in der Syntax.",
+ "validator-warning-adittional-errors": "… und {{PLURAL:$1|ein weiteres Problem|weitere Probleme}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Der Wert „$1“ wurde|Die Werte „$1“ wurden}} ausgelassen.",
+ "validator-error-problem": "Es gab ein Problem mit Parameter $1.",
+ "validator_error_unknown_argument": "„$1“ ist kein gültiger Parameter.",
+ "validator_error_required_missing": "Der notwendige Parameter „$1“ wurde nicht angegeben.",
+ "validator-error-override-argument": "Es wurde versucht Parameter $1 ($2) mit dem Wert „$3“ zu überschreiben.",
+ "validator-type-string": "Text",
+ "validator-type-integer": "Ganzzahl",
+ "validator-type-float": "Gleitkommazahl",
+ "validator-type-boolean": "ja/nein",
+ "validator-type-char": "Zeichen",
+ "validator-type-dimension": "Zahl mit Maßeinheit",
+ "validator-type-title": "Titel",
+ "validator-type-string-list": "Liste mit Texten",
+ "validator-type-integer-list": "Liste mit ganzen Zahlen",
+ "validator-type-float-list": "Liste mit Zahlen",
+ "validator-type-boolean-list": "Liste mit Ja/Nein-Angaben",
+ "validator-type-char-list": "Liste mit Zeichen",
+ "validator-type-title-list": "Liste mit Seitennamen",
+ "validator-listerrors-errors": "Fehler",
+ "validator-listerrors-minor": "Marginal",
+ "validator-listerrors-low": "Klein",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Groß",
+ "validator-listerrors-fatal": "Schwerwiegend",
+ "validator-listerrors-description": "Zeigt Fehler und Warnungen an, die bei über die Erweiterung Validator genutzten Parsererweiterungen auftraten.\nSie zeigt sie lediglich für die Parsererweiterungen an, die oberhalb des Tags „<code>listerrors</code>“ eingefügt wurden. „<code>listerrors</code>“ sollte daher am oder gegen Ende der Seite eingefügt werden, um alle Fehler und Warnungen angezeigt zu bekommen.",
+ "validator-listerrors-par-minseverity": "Der Mindestschweregrad eines Problems, damit dieses angezeigt wird.",
+ "validator-describe-description": "Erzeugt die Dokumentation für eine oder mehrere Parsererweiterungen, die über die Erweiterung Validator definiert wurden.",
+ "validator-describe-notfound": "Es ist keine Parsererweiterung vorhanden, die „$1“ verarbeitet.",
+ "validator-describe-descriptionmsg": "'''Beschreibung:''' $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasse}}:''' $1",
+ "validator-describe-parserfunction": "Sie ist lediglich als Parsererweiterung in Form einer Funktion implementiert.",
+ "validator-describe-tagextension": "Sie ist lediglich als Parsererweiterung in Form eines Tags implementiert.",
+ "validator-describe-bothhooks": "Sie ist sowohl als Parsererweiterung in Form einer Funktion wie auch eines Tags implementiert.",
+ "validator-describe-par-hooks": "Die Parsererweiterungen, zu der die Dokumentation angezeigt werden soll.",
+ "validator-describe-par-pre": "Ermöglicht die Ausgabe der Dokumentation in Wikitext, wobei dieser nicht gerendert wird.",
+ "validator-describe-par-language": "Die Sprache, in der die Beschreibungen angezeigt werden sollen",
+ "validator-describe-listtype": "Liste von Elementen: $1",
+ "validator-describe-empty": "leer",
+ "validator-describe-required": "erforderlich",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliasse",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Standard",
+ "validator-describe-header-description": "Beschreibung",
+ "validator-describe-parameters": "Parameter",
+ "validator-describe-syntax": "Syntax",
+ "validator-describe-tagmin": "Parsererweiterung als Tag, nur mit den erforderlichen Parametern.",
+ "validator-describe-tagmax": "Parsererweiterung als Tag mitsamt allen Parametern.",
+ "validator-describe-tagdefault": "Parsererweiterung als Tag mitsamt allen Parametern, welche die Standardnotation für Parameter nutzen.",
+ "validator-describe-pfmin": "Parsererweiterung als Funktion, nur mit den erforderlichen Parametern.",
+ "validator-describe-pfmax": "Parsererweiterung als Funktion mitsamt allen Parametern.",
+ "validator-describe-pfdefault": "Parsererweiterung als Funktion mitsamt allen Parametern, welche die Standardnotation für Parameter nutzen.",
+ "validator-describe-autogen": "Der Inhalt dieses Abschnitts wurde automatisch mit Hilfe der Parserfunktion „<code>describe</code>“ der Erweiterung Validator erstellt.",
+ "validator_error_empty_argument": "Parameter $1 kann keinen leeren Wert haben.",
+ "validator_error_must_be_number": "Parameter $1 kann nur eine Nummer sein.",
+ "validator_error_must_be_integer": "Parameter $1 kann nur eine ganze Zahl sein.",
+ "validator_error_must_be_title": "Parameter $1 kann nur ein gültiger Seitenname sein.",
+ "validator_error_must_be_existing_title": "Parameter $1 kann nur ein vorhandener Seitenname sein.",
+ "validator-error-must-be-float": "Parameter $1 kann nur eine Gleitkommazahl sein.",
+ "validator_error_invalid_range": "Parameter $1 muss zwischen $2 und $3 liegen.",
+ "validator-error-invalid-regex": "Parameter $1 muss diesem regulären Ausdruck entsprechen: $2.",
+ "validator-error-invalid-length": "Parameter $1 muss eine Länge von $2 haben.",
+ "validator-error-invalid-length-range": "Parameter $1 muss eine Länge zwischen $2 und $3 haben.",
+ "validator_error_invalid_argument": "Der Wert $1 ist nicht gültig für den Parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 akzeptiert keine leeren Werte.",
+ "validator_list_error_must_be_number": "Parameter $1 kann nur Ziffern enthalten.",
+ "validator_list_error_must_be_integer": "Parameter $1 kann nur ganze Zahlen enthalten.",
+ "validator_list_error_must_be_title": "Parameter $1 kann nur gültige Seitennamen enthalten.",
+ "validator_list_error_must_be_existing_title": "Parameter $1 kann nur vorhandene Seitennamen enthalten.",
+ "validator-list-error-must-be-float": "Parameter $1 kann nur Gleitkommazahlen enthalten.",
+ "validator_list_error_invalid_range": "Alle Werte des Parameters $1 müssen zwischen $2 und $3 liegen.",
+ "validator-list-error-invalid-regex": "Alle Werte des Parameters $1 müssen diesem regulären Ausdruck entsprechen: $2.",
+ "validator_list_error_invalid_argument": "Einer oder mehrere Werte für Parameter $1 sind ungültig.",
+ "validator-list-error-accepts-only": "Einer oder mehrere Werte für Parameter $1 sind ungültig.\nNur {{PLURAL:$3|der folgende Wert wird|die folgenden Werte werden}} akzeptiert: $2.",
+ "validator-list-error-accepts-only-omitted": "Einer oder mehrere Werte für Parameter $1 sind ungültig.\nNur {{PLURAL:$3|der folgende Wert wird|die folgenden Werte werden}} akzeptiert: $2 (sowie $4 ausgelassene {{PLURAL:$4|Wert|Werte}}).",
+ "validator_error_accepts_only": "Der Wert „$4“ ist nicht gültig für den Parameter $1. Nur {{PLURAL:$3|der folgende Wert wird|die folgenden Werte werden}} akzeptiert: $2.",
+ "validator-error-accepts-only-omitted": "Der Wert „$2“ ist nicht gültig für den Parameter $1. Nur {{PLURAL:$5|der folgende Wert wird|die folgenden Werte werden}} akzeptiert: $3 (sowie $4 nicht angezeigte {{PLURAL:$4|Wert|Werte}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Der Wert „$1“ wurde|Die Werte „$1“ wurden}} ausgelassen.",
+ "validator-message-nodesc": "Die Beschreibung dieses Parameters ist nicht vorhanden"
+}
diff --git a/www/wiki/extensions/Validator/i18n/diq.json b/www/wiki/extensions/Validator/i18n/diq.json
new file mode 100644
index 00000000..919794dc
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/diq.json
@@ -0,0 +1,19 @@
+{
+ "@metadata": {
+ "authors": [
+ "Erdemaslancan",
+ "Mirzali"
+ ]
+ },
+ "validator-listerrors-errors": "Xırabi",
+ "validator-listerrors-minor": "Qıcek",
+ "validator-listerrors-low": "Kemi",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Berz",
+ "validator-describe-required": "lazım",
+ "validator-describe-header-parameter": "Parametre",
+ "validator-describe-header-type": "Babet",
+ "validator-describe-header-default": "Hesabiyaye",
+ "validator-describe-header-description": "Şınasnayış",
+ "validator-describe-parameters": "Parametrey"
+}
diff --git a/www/wiki/extensions/Validator/i18n/dsb.json b/www/wiki/extensions/Validator/i18n/dsb.json
new file mode 100644
index 00000000..778aece9
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/dsb.json
@@ -0,0 +1,51 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "validator-desc": "Deklaratiwna biblioteka za pśeźěłowanje parametrow",
+ "validator-warning": "Warnowanje: $1",
+ "validator-error": "Zmólka: $1",
+ "validator-fatal-error": "Rozwažna zmólka: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Slědujuca zmólka jo se namakała|Slědujucej zmólce stej se namakałej|Slědujuce zmólki su se namakali|Slědujuce zmólki su se namakali}} w twójej syntaksy:",
+ "validator_warning_parameters": "{{PLURAL:$1|Jo zmólka|Stej zmólce|Su zmólki|Su zmólki}} w twójej syntaksy.",
+ "validator-error-problem": "Jo był problem z parametrom $1.",
+ "validator_error_unknown_argument": "$1 njejo płaśiwy parameter.",
+ "validator_error_required_missing": "Trěbny parameter $1 njejo pódany.",
+ "validator-type-string": "tekst",
+ "validator-type-integer": "ceła licba",
+ "validator-type-float": "licba",
+ "validator-type-boolean": "jo/ně",
+ "validator-type-char": "znamuško",
+ "validator-listerrors-errors": "Zmólki",
+ "validator-listerrors-minor": "Snadna",
+ "validator-listerrors-low": "Niska",
+ "validator-listerrors-normal": "Normalna",
+ "validator-listerrors-high": "Wusoka",
+ "validator-listerrors-fatal": "Rozwažna",
+ "validator-describe-descriptionmsg": "'''wopisanje''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasa|Aliase|Aliase}}''': $1",
+ "validator-describe-listtype": "Lisćina $1 {{PLURAL:$1|elementa|elementowu|elementow|elementow}}",
+ "validator-describe-empty": "prozny",
+ "validator-describe-required": "trěbny",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliase",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Standard",
+ "validator-describe-header-description": "Wopisanje",
+ "validator-describe-parameters": "Parametry",
+ "validator-describe-syntax": "Syntaksa",
+ "validator_error_empty_argument": "Parameter $1 njamóžo proznu gódnotu měś.",
+ "validator_error_must_be_number": "Parameter $1 móžo jano licba byś.",
+ "validator_error_must_be_integer": "Parameter $1 móžo jano ceła licba byś.",
+ "validator_error_invalid_range": "Parameter $1 musy mjazy $2 a $3 byś.",
+ "validator_error_invalid_argument": "Gódnota $1 njejo płaśiwa za parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 njeakceptěrujo prozne gódnoty.",
+ "validator_list_error_must_be_number": "Parameter $1 móžo jano licby wopśimjeś.",
+ "validator_list_error_must_be_integer": "Parameter $1 móžo jano cełe licby wopśimjeś.",
+ "validator_list_error_invalid_range": "Wšykne gódnoty parametra $1 muse mjazy $2 a $3 byś.",
+ "validator_list_error_invalid_argument": "Jadna gódnota abo wěcej gódnotow za parameter $1 su njepłaśiwe.",
+ "validator_error_accepts_only": "Gódnota \"$4\" njejo płaśiwa za parameter $1. Akcepteptěrujo se jano {{PLURAL:$3|toś ta gódnota|toś tej gódnośe|toś te gódnoty|toś te gódnoty}}: $2.",
+ "validator_list_omitted": "{{PLURAL:$2|Gódnota|Gódnośe|Gódnoty|Gódnoty}} $1 {{PLURAL:$2|jo se wuwóstajiła|stej se wuwóstajiłej|su se wuwóstajili|su se wuwostajili}}."
+}
diff --git a/www/wiki/extensions/Validator/i18n/el.json b/www/wiki/extensions/Validator/i18n/el.json
new file mode 100644
index 00000000..304f07b8
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/el.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dada",
+ "Lou",
+ "Protnet",
+ "ZaDiak",
+ "Απεργός"
+ ]
+ },
+ "validator-desc": "Παρέχει γενική υποστήριξη χειρισμού παραμέτρων για άλλες επεκτάσεις",
+ "validator-error": "Σφάλμα: $1",
+ "validator-fatal-error": "Ανεπανόρθωτο σφάλμα: $1",
+ "validator_error_unknown_argument": "$1 δεν είναι μια έγκυρη παράμετρος.",
+ "validator_error_required_missing": "Λείπει η απαιτούμενη παράμετρος $1.",
+ "validator-type-string": "κείμενο",
+ "validator_error_must_be_number": "Η παράμετρος $1 μπορεί να είναι μόνο αριθμός.",
+ "validator_error_must_be_integer": "Η παράμετρος $1 μπορεί να είναι μόνο ακέραιος αριθμός.",
+ "validator_list_error_must_be_number": "Η παράμετρος $1 μπορεί να περιέχει μόνο αριθμούς.",
+ "validator_list_error_must_be_integer": "Η παράμετρος $1 μπορεί να περιέχει μόνο ακέραιους αριθμούς.",
+ "validator_list_error_invalid_range": "Όλες οι τιμές της παραμέτρου $1 πρέπει να είναι μεταξύ $2 και $3."
+}
diff --git a/www/wiki/extensions/Validator/i18n/en.json b/www/wiki/extensions/Validator/i18n/en.json
new file mode 100644
index 00000000..38e5a8ee
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/en.json
@@ -0,0 +1,96 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jeroen De Dauw",
+ "Daniel Werner",
+ "Karsten Hoffmeyer"
+ ]
+ },
+ "validator-desc": "Declarative parameter processing library",
+ "validator-warning": "Warning: $1",
+ "validator-error": "Error: $1",
+ "validator-fatal-error": "Fatal error: $1",
+ "validator_error_parameters": "The following {{PLURAL:$1|error has|errors have}} been detected in your syntax:",
+ "validator_warning_parameters": "There {{PLURAL:$1|is an error|are errors}} in your syntax.",
+ "validator-warning-adittional-errors": "... and {{PLURAL:$1|one more issue|multiple more issues}}.",
+ "validator-error-omitted": "The {{PLURAL:$2|value \"$1\" has|values \"$1\" have}} been omitted.",
+ "validator-error-problem": "There was a problem with parameter $1.",
+ "validator_error_unknown_argument": "$1 is not a valid parameter.",
+ "validator_error_required_missing": "The required parameter \"$1\" is not provided.",
+ "validator-error-override-argument": "Tried to override parameter $1 (value: $2) with value \"$3\"",
+ "validator-type-string": "text",
+ "validator-type-integer": "whole number",
+ "validator-type-float": "number",
+ "validator-type-boolean": "yes/no",
+ "validator-type-char": "character",
+ "validator-type-dimension": "number and dimensional unit",
+ "validator-type-title": "title",
+ "validator-type-string-list": "list of texts",
+ "validator-type-integer-list": "list of integers",
+ "validator-type-float-list": "list of numbers",
+ "validator-type-boolean-list": "list of yes/no",
+ "validator-type-char-list": "list characters",
+ "validator-type-title-list": "list of titles",
+ "validator-listerrors-errors": "Errors",
+ "validator-listerrors-severity-message": "($1) $2",
+ "validator-listerrors-minor": "Minor",
+ "validator-listerrors-low": "Low",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "High",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Lists errors (and warnings) that occurred in parser hooks added via Validator.\nOnly lists for parser hooks added above where listerrors is inserted;\nplace listerrors at or near the bottom of the page to get all errors.",
+ "validator-listerrors-par-minseverity": "The minimum severity of an issue for it to be listed.",
+ "validator-describe-description": "Generates documentation for one or more parser hooks defined via Validator.",
+ "validator-describe-notfound": "There is no parser hook that handles \"$1\".",
+ "validator-describe-descriptionmsg": "'''Description''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliases}}''': $1",
+ "validator-describe-parserfunction": "Implemented only as parser function.",
+ "validator-describe-tagextension": "Implemented only as tag extension.",
+ "validator-describe-bothhooks": "Implemented as both parser function and as tag extension.",
+ "validator-describe-par-hooks": "The parser hooks for which to display documentation.",
+ "validator-describe-par-pre": "Allows you to get the actual wikitext for the documentation, without it being rendered on the page.",
+ "validator-describe-par-language": "The language to display the descriptions in",
+ "validator-describe-listtype": "List of $1 items",
+ "validator-describe-empty": "empty",
+ "validator-describe-required": "required",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliases",
+ "validator-describe-header-type": "Type",
+ "validator-describe-header-default": "Default",
+ "validator-describe-header-description": "Description",
+ "validator-describe-parameters": "Parameters",
+ "validator-describe-syntax": "Syntax",
+ "validator-describe-tagmin": "Tag extension with only the required parameters.",
+ "validator-describe-tagmax": "Tag extension with all parameters.",
+ "validator-describe-tagdefault": "Tag extension with all parameters using the default parameter notation.",
+ "validator-describe-pfmin": "Parser function with only the required parameters.",
+ "validator-describe-pfmax": "Parser function with all parameters.",
+ "validator-describe-pfdefault": "Parser function with all parameters using the default parameter notation.",
+ "validator-describe-autogen": "The contents of this section was auto-generated by the \"describe\" parser hook of the Validator extension.",
+ "validator_error_empty_argument": "Parameter $1 can not have an empty value.",
+ "validator_error_must_be_number": "Parameter $1 can only be a number.",
+ "validator_error_must_be_integer": "Parameter $1 can only be an integer.",
+ "validator_error_must_be_title": "Parameter $1 can only be a valid wiki page name.",
+ "validator_error_must_be_existing_title": "Parameter $1 can only be an existing wiki page name.",
+ "validator-error-must-be-float": "Parameter $1 can only be a floating point number.",
+ "validator_error_invalid_range": "Parameter $1 must be between $2 and $3.",
+ "validator-error-invalid-regex": "Parameter $1 must match this regular expression: $2.",
+ "validator-error-invalid-length": "Parameter $1 must have a length of $2.",
+ "validator-error-invalid-length-range": "Parameter $1 must have a length between $2 and $3.",
+ "validator_error_invalid_argument": "The value $1 is not valid for parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 does not accept empty values.",
+ "validator_list_error_must_be_number": "Parameter $1 can only contain numbers.",
+ "validator_list_error_must_be_integer": "Parameter $1 can only contain integers.",
+ "validator_list_error_must_be_title": "Parameter $1 can only contain valid wiki page names.",
+ "validator_list_error_must_be_existing_title": "Parameter $1 can only contain existing wiki page names.",
+ "validator-list-error-must-be-float": "Parameter $1 can only contain floats.",
+ "validator_list_error_invalid_range": "All values of parameter $1 must be between $2 and $3.",
+ "validator-list-error-invalid-regex": "All values of parameter $1 must match this regular expression: $2.",
+ "validator_list_error_invalid_argument": "One or more values for parameter $1 are invalid.",
+ "validator-list-error-accepts-only": "One or more values for parameter $1 are invalid. It only accepts {{PLURAL:$3|this value|these values}}: $2.",
+ "validator-list-error-accepts-only-omitted": "One or more values for parameter $1 are invalid. It only accepts {{PLURAL:$3|this value|these values}}: $2 (and $4 omitted {{PLURAL:$4|value|values}}).",
+ "validator_error_accepts_only": "The value \"$4\" is not valid for parameter $1. It only accepts {{PLURAL:$3|this value|these values}}: $2.",
+ "validator-error-accepts-only-omitted": "The value \"$2\" is not valid for parameter $1. It only accepts {{PLURAL:$5|this value|these values}}: $3 (and $4 omitted {{PLURAL:$4|value|values}}).",
+ "validator_list_omitted": "The {{PLURAL:$2|value|values}} $1 {{PLURAL:$2|has|have}} been omitted.",
+ "validator-message-nodesc": "No description provided"
+}
diff --git a/www/wiki/extensions/Validator/i18n/eo.json b/www/wiki/extensions/Validator/i18n/eo.json
new file mode 100644
index 00000000..caa6b9cf
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/eo.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "Luckas",
+ "Yekrats"
+ ]
+ },
+ "validator_error_unknown_argument": "$1 ne estas valida parametro.",
+ "validator_error_required_missing": "La nepra parametro $1 mankas.",
+ "validator-describe-descriptionmsg": "'''Priskribo''': $1",
+ "validator-describe-header-description": "Priskribo",
+ "validator_error_empty_argument": "Parametro $1 ne povas esti nula valoro.",
+ "validator_error_must_be_number": "Parametro $1 nur povas esti numero.",
+ "validator_error_must_be_integer": "Parametro $1 nur povas esti entjero.",
+ "validator_error_invalid_range": "Parametro $1 estu inter $2 kaj $3.",
+ "validator_list_error_invalid_argument": "Unu aŭ pliaj valoroj por parametro $1 estas malvalida."
+}
diff --git a/www/wiki/extensions/Validator/i18n/es.json b/www/wiki/extensions/Validator/i18n/es.json
new file mode 100644
index 00000000..cc21f0a3
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/es.json
@@ -0,0 +1,100 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armando-Martin",
+ "Ciencia Al Poder",
+ "Crazymadlover",
+ "Imre",
+ "Translationista",
+ "Fitoschido",
+ "Macofe",
+ "Indiralena"
+ ]
+ },
+ "validator-desc": "Biblioteca de procesamiento de parámetros declarativa",
+ "validator-warning": "Advertencia: $1",
+ "validator-error": "Error: $1",
+ "validator-fatal-error": "Error fatal: $1",
+ "validator_error_parameters": "Se {{PLURAL:$1|detectó el siguiente error|detectaron los siguientes errores}} en la sintaxis empleada:",
+ "validator_warning_parameters": "Hay {{PLURAL:$1|un error|errores}} en tu sintaxis.",
+ "validator-warning-adittional-errors": "...y {{PLURAL:$1|otro problema|muchos otros problemas}}.",
+ "validator-error-omitted": "Se {{PLURAL:$2|omitió el valor «$1»|omitieron los valores «$1»}}.",
+ "validator-error-problem": "Ha habido un problema con el parámetro $1.",
+ "validator_error_unknown_argument": "$1 no es un parámetro válido.",
+ "validator_error_required_missing": "No se ha provisto el parámetro requerido $1.",
+ "validator-error-override-argument": "Se ha intentado sobreescribir el parámetro $1 (valor: $2) con el valor \"$3\"",
+ "validator-type-string": "texto",
+ "validator-type-integer": "número entero",
+ "validator-type-float": "número",
+ "validator-type-boolean": "sí/no",
+ "validator-type-char": "carácter",
+ "validator-type-dimension": "número y unidad de dimensión",
+ "validator-type-title": "título",
+ "validator-type-string-list": "lista de textos",
+ "validator-type-integer-list": "lista de números enteros",
+ "validator-type-float-list": "lista de números",
+ "validator-type-boolean-list": "lista de sí/no",
+ "validator-type-char-list": "listar caracteres",
+ "validator-type-title-list": "lista de títulos",
+ "validator-listerrors-errors": "Errores",
+ "validator-listerrors-minor": "Menor",
+ "validator-listerrors-low": "Bajo",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Alto",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Lista los errores (y advertencias) que se produjeron en las asociaciones (hook) del analizador (parser) añadidas a través de validador.\nSólo se muestran en las listas las asociaciones del analizador agregados antes de la inserción de listerrors;\n coloque listerrors alfinal o cerca de la parte inferior de la página para obtener todos los errores.",
+ "validator-listerrors-par-minseverity": "La gravedad mínima de una cuestión para que aparezca en la lista.",
+ "validator-describe-description": "Genera documentación para una o más asociaciones del analizador (parser hooks) definidas a través de Validator.",
+ "validator-describe-notfound": "No hay ninguna asociación del analizador (parser hook) que controle \"$1\".",
+ "validator-describe-descriptionmsg": "'''Descripción''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Alias}}''': $1",
+ "validator-describe-parserfunction": "Implementado sólo como función del analizador (parser).",
+ "validator-describe-tagextension": "Implementado sólo como etiqueta de extensión.",
+ "validator-describe-bothhooks": "Implementado como función del analizador y como etiqueta de extensión.",
+ "validator-describe-par-hooks": "Asociación del analizador (parser hook) para que la que desea mostrar la documentación.",
+ "validator-describe-par-pre": "Le permite obtener el texto wiki real para la documentación, sin que se procese (render) como imagen en la página.",
+ "validator-describe-par-language": "El idioma en el que mostrar las descripciones",
+ "validator-describe-listtype": "Lista de $1 elementos",
+ "validator-describe-empty": "vacío",
+ "validator-describe-required": "obligatorio",
+ "validator-describe-header-parameter": "Parámetro",
+ "validator-describe-header-aliases": "Alias",
+ "validator-describe-header-type": "Tipo",
+ "validator-describe-header-default": "Predeterminado",
+ "validator-describe-header-description": "Descripción",
+ "validator-describe-parameters": "Parámetros",
+ "validator-describe-syntax": "Sintaxis",
+ "validator-describe-tagmin": "Etiqueta de extensión sólo con los parámetros obligatorios.",
+ "validator-describe-tagmax": "Etiqueta de extensión con todos los parámetros.",
+ "validator-describe-tagdefault": "Etiqueta de extensión con todos los parámetros, empleando la notación de los parámetros por defecto.",
+ "validator-describe-pfmin": "Función del analizador (parser) sólo con los parámetros obligatorios.",
+ "validator-describe-pfmax": "Función del analizador (parser) con todos los parámetros.",
+ "validator-describe-pfdefault": "Función del analizador (parser) con todos los parámetros, empleando la notación predeterminada de los parámetros.",
+ "validator-describe-autogen": "El contenido de esta sección fue generado automáticamente por la asociación del analizador (parser hook) \"describe\" de la extensión Validator.",
+ "validator_error_empty_argument": "El parámetro $1 no puede tener un valor vacío.",
+ "validator_error_must_be_number": "El parámetro $1 sólo puede ser un número.",
+ "validator_error_must_be_integer": "El parámetro $1 sólo puede ser un número entero.",
+ "validator_error_must_be_title": "El parámetro $1 sólo puede ser un nombre de página wiki válido.",
+ "validator_error_must_be_existing_title": "El parámetro $1 sólo puede ser un nombre de página wiki existente.",
+ "validator-error-must-be-float": "El parámetro $1 tiene que ser un número de punto flotante.",
+ "validator_error_invalid_range": "El parámetro $1 debe ser entre $2 y $3.",
+ "validator-error-invalid-regex": "El parámetro $1 tiene que coincidir con esta expresión racional : $2.",
+ "validator-error-invalid-length": "El parámetro $1 tiene que tener una longitud de $2.",
+ "validator-error-invalid-length-range": "El parámetro $1 tiene que tener una longitud comprendida entre $2 y $3.",
+ "validator_error_invalid_argument": "El valor $1 no es válido para el parámetro $2.",
+ "validator_list_error_empty_argument": "El parámetro $1 no acepta valores vacíos.",
+ "validator_list_error_must_be_number": "El parámetro $1 sólo puede contener números.",
+ "validator_list_error_must_be_integer": "El parámetro $1 sólo puede contener números enteros.",
+ "validator_list_error_must_be_title": "El parámetro $1 sólo puede contener nombres válidos de página wiki.",
+ "validator_list_error_must_be_existing_title": "El parámetro $1 sólo puede contener nombres de páginas wiki existentes.",
+ "validator-list-error-must-be-float": "El parámetro $1 sólo puede contener floats.",
+ "validator_list_error_invalid_range": "Todos los valores del parámetro $1 deben ser entre $2 y $3.",
+ "validator-list-error-invalid-regex": "El parámetro $1 tiene que coincidir con esta expresión regular: $2.",
+ "validator_list_error_invalid_argument": "Uno o más valores del parámetros $1 son inválidos.",
+ "validator-list-error-accepts-only": "Uno o más valores para el parámetro $1 son inválidos.\nSólo acepta{{PLURAL:$3|este valor| estos valores}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Uno o más valores para el parámetro $1 son inválidos. Sólo acepta {{PLURAL:$3|este valor|estos valores}}: $2 (y $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_error_accepts_only": "El valor \"$4\" no es válido para el parámetro $1. El parámetro sólo acepta {{PLURAL:$3|este valor|estos valores}}: $2.",
+ "validator-error-accepts-only-omitted": "El valor $2 no es válido para el parámetro $1.\nSólo acepta {{PLURAL:$5|este valor|estos valores}}: $3 (y $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_list_omitted": "{{PLURAL:$2|El valor|Los valores}} $1 {{PLURAL:$2|ha sido omitido|han sido omitidos}}.",
+ "validator-message-nodesc": "No se aporta ninguna descripción"
+}
diff --git a/www/wiki/extensions/Validator/i18n/et.json b/www/wiki/extensions/Validator/i18n/et.json
new file mode 100644
index 00000000..bbcbe32c
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/et.json
@@ -0,0 +1,30 @@
+{
+ "@metadata": {
+ "authors": [
+ "Avjoska",
+ "Pikne"
+ ]
+ },
+ "validator-warning": "Hoiatus: $1",
+ "validator-error": "Tõrge: $1",
+ "validator-type-string": "tekst",
+ "validator-type-integer": "täisarv",
+ "validator-type-float": "number",
+ "validator-type-boolean": "jah/ei",
+ "validator-type-char": "märk",
+ "validator-type-title": "pealkiri",
+ "validator-type-string-list": "tekstide loetelu",
+ "validator-type-float-list": "numbrite loetelu",
+ "validator-listerrors-errors": "Vead",
+ "validator-listerrors-low": "Madal",
+ "validator-listerrors-normal": "Normaalne",
+ "validator-listerrors-high": "Kõrge",
+ "validator-describe-descriptionmsg": "'''Kirjeldus''': $1",
+ "validator-describe-empty": "tühi",
+ "validator-describe-required": "nõutav",
+ "validator-describe-header-parameter": "Parameeter",
+ "validator-describe-header-type": "Tüüp",
+ "validator-describe-header-description": "Kirjeldus",
+ "validator-describe-parameters": "Parameetrid",
+ "validator-describe-syntax": "Süntaks"
+}
diff --git a/www/wiki/extensions/Validator/i18n/eu.json b/www/wiki/extensions/Validator/i18n/eu.json
new file mode 100644
index 00000000..58380627
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/eu.json
@@ -0,0 +1,22 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද",
+ "Subi"
+ ]
+ },
+ "validator-type-string": "testua",
+ "validator-type-integer": "zenbaki osoa",
+ "validator-type-float": "zenbakia",
+ "validator-type-boolean": "bai/ez",
+ "validator-type-char": "karakterea",
+ "validator-listerrors-errors": "Erroreak",
+ "validator-listerrors-low": "Baxua",
+ "validator-listerrors-normal": "Normala",
+ "validator-listerrors-high": "Altua",
+ "validator-describe-descriptionmsg": "'''Deskribapena''': $1",
+ "validator-describe-empty": "hutsik",
+ "validator-describe-header-type": "Mota",
+ "validator-describe-header-default": "Lehenetsia",
+ "validator-describe-header-description": "Deskribapena"
+}
diff --git a/www/wiki/extensions/Validator/i18n/fa.json b/www/wiki/extensions/Validator/i18n/fa.json
new file mode 100644
index 00000000..0fc92869
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/fa.json
@@ -0,0 +1,94 @@
+{
+ "@metadata": {
+ "authors": [
+ "Armin1392",
+ "Mjbmr",
+ "پاناروما"
+ ]
+ },
+ "validator-desc": "پارامتر اعلانی پردازش کتابخانه",
+ "validator-warning": "هشدار: $1",
+ "validator-error": "خطا: $1",
+ "validator-fatal-error": "خطای مهلک: $1",
+ "validator_error_parameters": "{{PLURAL:$1|خطا|خطاها}} در نحو شما تشخیص داده شده‌اندː",
+ "validator_warning_parameters": "{{PLURAL:$1|یک خطا|خطاهایی}} در نحو شما است.",
+ "validator-warning-adittional-errors": "... و {{PLURAL:$1|یک مسئله بیشتر|چند مسئله بیشتر}}.",
+ "validator-error-omitted": "{{PLURAL:$2|مقدار \"$1\" |مقدارها \"$1\"}} حذف شده‌اند.",
+ "validator-error-problem": "مشکلی با پارامتر $1 وجود داشت.",
+ "validator_error_unknown_argument": "$1 یک پارامتر معتبر نیست.",
+ "validator_error_required_missing": "پارامتر مورد نیاز \"$1\" ارائه نشده‌است.",
+ "validator-error-override-argument": "سعی به لغو پارامتر $1 (مقدارː$2) با مقدار \"$3\"",
+ "validator-type-string": "متن",
+ "validator-type-integer": "عدد صحیح",
+ "validator-type-float": "شماره",
+ "validator-type-boolean": "بله/خیر",
+ "validator-type-char": "شخصیت",
+ "validator-type-title": "عنوان",
+ "validator-type-string-list": "فهرست متون",
+ "validator-type-integer-list": "فهرست اعداد صحیح",
+ "validator-type-float-list": "فهرست شماره‌ها",
+ "validator-type-boolean-list": "فهرست بله/خیر",
+ "validator-type-char-list": "فهرست شخصیت‌ها",
+ "validator-type-title-list": "فهرست عناوین",
+ "validator-listerrors-errors": "خطاها",
+ "validator-listerrors-minor": "جزئی",
+ "validator-listerrors-low": "کم",
+ "validator-listerrors-normal": "عادی",
+ "validator-listerrors-high": "زیاد",
+ "validator-listerrors-fatal": "کشنده",
+ "validator-listerrors-description": "فهرست خطاهایی (و هشدارهایی) که در قلاب تجزیه‌کننده از طریق اعتبارسنج افزوده شده.\nفقط فهرست‌ها برای افزودن قلاب‌های تجزیه‌کننده بالای جایی که فهرست خطاها قرار داده شده‌است؛\nقرار دادن فهرست خطاها در نزدیکی پایین صفحه برای دریافت همه خطاها.",
+ "validator-listerrors-par-minseverity": "حداقل شدت مسئله برای فهرست شدن.",
+ "validator-describe-description": "تولید اسناد برای یک یا چند قلاب‌های تجزیه‌کننده تعریف شده از طریق اعتبارسنج.",
+ "validator-describe-notfound": "هیچ قلاب تجزیه‌کننده‌ای که \"$1\" را کنترل کند وجود ندارد.",
+ "validator-describe-descriptionmsg": "'''شرح''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|نام مستعار|نام‌های مستعار}}''': $1",
+ "validator-describe-parserfunction": "تنها به عنوان عملیات تجزیه‌مننده اجرا شده.",
+ "validator-describe-tagextension": "تنها به عنوان گستره برچسب اجرا شده.",
+ "validator-describe-bothhooks": "اجرا شده به عنوان هر دو عملیات تجزیه‌کننده و گستره برچسب.",
+ "validator-describe-par-hooks": "قلاب‌های تجریه کننده برای نمایش اسناد.",
+ "validator-describe-par-pre": "به شما برای دریافت متن ویکی واقعی برای اسناد، بدون اینکه در صفحه ارائه شود، اجازه می‌دهد.",
+ "validator-describe-par-language": "زبان برای نمایش توصیفات در",
+ "validator-describe-listtype": "فهرست موارد $1",
+ "validator-describe-empty": "خالی",
+ "validator-describe-required": "ضروری",
+ "validator-describe-header-parameter": "مولفه",
+ "validator-describe-header-aliases": "نام‌های مستعار",
+ "validator-describe-header-type": "نوع",
+ "validator-describe-header-default": "پیش فرض",
+ "validator-describe-header-description": "تشریح",
+ "validator-describe-parameters": "پارامترها",
+ "validator-describe-syntax": "نحو",
+ "validator-describe-tagmin": "برچسب گستره فقط با پارامترهای مورد نیاز",
+ "validator-describe-tagmax": "برچسب گستره با همهٔ پارامترها",
+ "validator-describe-tagdefault": "گستره برچسب با هر پارامتری با استفاده از نماد پارامتر پیش‌فرض.",
+ "validator-describe-pfmin": "عملیات تجزیه‌کننده فقط با پارامترهای مورد نیاز.",
+ "validator-describe-pfmax": "فعالیت تجزیه کننده با همهٔ پارامترها.",
+ "validator-describe-pfdefault": "عملیات تجزیه‌کننده با همه پارامترها با استفاده از نماد پارامتر پیش‌فرض.",
+ "validator-describe-autogen": "محتوای این بخش توسط \"توصیف\" قلاب تجزیه‌کننده گیتره اعتبارسنج، به طور خودکار تولید شده‌بود.",
+ "validator_error_empty_argument": "پارامتر $1 نمی‌تواند یک مقدار خالی باشد.",
+ "validator_error_must_be_number": "پارامتر $1 می‌تواند فقط یک عدد باشد.",
+ "validator_error_must_be_integer": "پارامتر $1 می‌تواند فقط یک عدد صحیح باشد.",
+ "validator_error_must_be_title": "پارامتر $1 می‌تواند فقط یک نام صفحهٔ ویکی معتبر باشد.",
+ "validator_error_must_be_existing_title": "پارامتر $1 می‌تواند فقط یک نام صفحهٔ ویکی موجود باشد.",
+ "validator-error-must-be-float": "پارامتر $1 می‌تواند فقط یک عدد نقطهٔ معلق باشد.",
+ "validator_error_invalid_range": "پارامتر $1 باید بین $2 و $3 باشد.",
+ "validator-error-invalid-regex": "پارامتر $1باید با این عبارت منظم مطابق باشد: $2",
+ "validator-error-invalid-length": "پارامتر $1 باید طول $2 داشته باشد.",
+ "validator-error-invalid-length-range": "پارامتر $1 باید طول بین $2 و $3 داشته باشد.",
+ "validator_error_invalid_argument": "مقدار $1 برای پارامتر $2 معتبر نیست.",
+ "validator_list_error_empty_argument": "پارامتر $1 مقادیر خالی را نمی‌پذیرد.",
+ "validator_list_error_must_be_number": "پارامتر $1 می‌تواند فقط شامل اعداد باشد.",
+ "validator_list_error_must_be_integer": "پارامتر $1 می‌تواند فقط شامل اعداد صحیح باشد.",
+ "validator_list_error_must_be_title": "پارامتر $1 می‌تواند فقط شامل نام‌های صفحهٔ ویکی معتبر باشد.",
+ "validator_list_error_must_be_existing_title": "پارامتر $1 می‌تواند فقط شامل نام‌های صفحهٔ ویکی موجود باشد.",
+ "validator-list-error-must-be-float": "پارامتر $1 می‌تواند فقط شامل معلق‌ها باشد.",
+ "validator_list_error_invalid_range": "همهٔ مقادیر پارامتر $1 باید بین $2 و $3 باشند.",
+ "validator-list-error-invalid-regex": "همهٔ مقادیر پارامتر $1 باید با این عبارت منظم مطابق باشند: $2.",
+ "validator_list_error_invalid_argument": "یک یا چند مقادیر برای پارامتر $1 نامعتبر است.",
+ "validator-list-error-accepts-only": "یک یا چند مقدار برای پارامتر $1 نامعتبر است. این فقط {{PLURAL:$3|این مقدار|این مقادیر}} را می‌پذیردː $2.",
+ "validator-list-error-accepts-only-omitted": "یک یا جند مقادیر برای پارامتر $1 نامعتبر است. این فقط {{PLURAL:$3|این مقدار|این مقادیر}} را می‌پذیردː $2 (و $4حذف شده {{PLURAL:$4|مقدار|مقادیر}}).",
+ "validator_error_accepts_only": "مقدار \"$4\" برای پارامتر $1 معتبر نیست. این فقط {{PLURAL:$3|این مقدار|این مقادیر}} را می‌پذیردː $2.",
+ "validator-error-accepts-only-omitted": "مقدار \"$2\" برای پارامتر $1 معتبر نیست . این فقط {{PLURAL:$5|این مقدار|این مقادیر}} را می‌پذیردː $3 (و $4 حذف شده {{PLURAL:$4|مقدار|مقادیر}}).",
+ "validator_list_omitted": "{{PLURAL:$2|مقدار|مقادیر}} $1 {{PLURAL:$2|has|have}} حذف شده‌اند.",
+ "validator-message-nodesc": "هیچ توصیفی ارائه نشده"
+}
diff --git a/www/wiki/extensions/Validator/i18n/fi.json b/www/wiki/extensions/Validator/i18n/fi.json
new file mode 100644
index 00000000..0768b7f2
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/fi.json
@@ -0,0 +1,31 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beluga",
+ "Crt",
+ "Nedergard",
+ "Silvonen",
+ "Str4nd",
+ "VezonThunder"
+ ]
+ },
+ "validator-desc": "Tarkastaja tarjoaa helpon tavan muille laajennuksille jäsenninfunktioiden ja tagilaajennusten parametrien tarkastukseen, oletusarvojen asettamiseen ja virheilmoitusten luomiseen.",
+ "validator-warning": "Varoitus: $1",
+ "validator-error": "Virhe: $1",
+ "validator-fatal-error": "Vakava virhe: $1",
+ "validator_error_unknown_argument": "$1 ei ole sallittu parametri.",
+ "validator-type-string": "teksti",
+ "validator-type-integer": "kokonaisluku",
+ "validator-type-float": "luku",
+ "validator-type-boolean": "kyllä/ei",
+ "validator-type-char": "merkki",
+ "validator-type-title": "otsikko",
+ "validator-listerrors-errors": "Virheet",
+ "validator-describe-empty": "tyhjä",
+ "validator-describe-required": "pakollinen",
+ "validator-describe-header-type": "Tyyppi",
+ "validator-describe-header-default": "Oletus",
+ "validator-describe-header-description": "Kuvaus",
+ "validator_error_must_be_number": "Parametrin $1 on oltava luku.",
+ "validator_error_must_be_integer": "Parametrin $1 on oltava kokonaisluku."
+}
diff --git a/www/wiki/extensions/Validator/i18n/fr.json b/www/wiki/extensions/Validator/i18n/fr.json
new file mode 100644
index 00000000..c3c829ba
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/fr.json
@@ -0,0 +1,105 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31",
+ "Crochet.david",
+ "DavidL",
+ "Gomoko",
+ "IAlex",
+ "Jean-Frédéric",
+ "LIMAFOX76",
+ "McDutchie",
+ "Peter17",
+ "PieRRoMaN",
+ "Sherbrooke",
+ "Urhixidur",
+ "Verdy p"
+ ]
+ },
+ "validator-desc": "Bibliothèque de traitement des paramètres déclaratifs",
+ "validator-warning": "Attention : $1",
+ "validator-error": "Erreur : $1",
+ "validator-fatal-error": "Erreur fatale : $1",
+ "validator_error_parameters": "{{PLURAL:$1|L’erreur suivante a été détectée|Les erreurs suivantes ont été détectées}} dans votre syntaxe :",
+ "validator_warning_parameters": "Il y a {{PLURAL:$1|une erreur|des erreurs}} dans votre syntaxe.",
+ "validator-warning-adittional-errors": "... ainsi {{PLURAL:$1|qu'un problème supplémentaire|que plusieurs autres problèmes}}.",
+ "validator-error-omitted": "{{PLURAL:$2|La valeur « $1 » a été oubliée|Les valeurs « $1 » ont été oubliées}}.",
+ "validator-error-problem": "Il y a un problème avec le paramètre $1.",
+ "validator_error_unknown_argument": "$1 n’est pas un paramètre valide.",
+ "validator_error_required_missing": "Le paramètre requis $1 n’est pas renseigné.",
+ "validator-error-override-argument": "Le logiciel a essayé de remplacer le paramètre $1 (valeur : $2) avec la valeur « $3 »",
+ "validator-type-string": "texte",
+ "validator-type-integer": "nombre entier",
+ "validator-type-float": "nombre",
+ "validator-type-boolean": "oui/non",
+ "validator-type-char": "caractère",
+ "validator-type-dimension": "nombre et unité de dimension",
+ "validator-type-title": "titre",
+ "validator-type-string-list": "liste de textes",
+ "validator-type-integer-list": "liste de nombres entiers",
+ "validator-type-float-list": "liste de nombres",
+ "validator-type-boolean-list": "liste de oui/non",
+ "validator-type-char-list": "caractères de la liste",
+ "validator-type-title-list": "liste de titres",
+ "validator-listerrors-errors": "Erreurs",
+ "validator-listerrors-minor": "Mineur",
+ "validator-listerrors-low": "Faible",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Élevé",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Liste les erreurs (et les avertissements) qui se sont produites dans les ''hooks'' de l'analyseur syntaxique ''via'' ''Validator''.\nSeules les listes pour les ''hooks'' de l'analyseur syntaxique (ajoutées où apparaît <code>listerrors</code>) sont insérées ;\nplacer <code>listerrors</code> au plus bas de la page pour obtenir toutes les erreurs.",
+ "validator-listerrors-par-minseverity": "La sévérité minimale d'une erreur pour être listée.",
+ "validator-describe-description": "Génère la documentation pour un ou plusieurs ''hooks'' de l'analyseur syntaxique ''via'' ''Validator'.",
+ "validator-describe-notfound": "Il n'y a pas de ''hook'' qui gère « $1 ».",
+ "validator-describe-descriptionmsg": "'''Description''' : $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias}}''' : $1",
+ "validator-describe-parserfunction": "Mis en œuvre uniquement comme fonction de l'analyseur syntaxique.",
+ "validator-describe-tagextension": "Mis en œuvre seulement comme balise d'extension.",
+ "validator-describe-bothhooks": "Mis en œuvre comme fonction de l'analyseur syntaxique et comme balise d'extension.",
+ "validator-describe-par-hooks": "Les ''hooks'' de l'analyseur syntaxique dont il faut afficher la documentation.",
+ "validator-describe-par-pre": "Vous permet d'obtenir le wikitexte courant de la documentation, sans qu'il soit rendu sur la page.",
+ "validator-describe-par-language": "La langue dans laquelle afficher les descriptions",
+ "validator-describe-listtype": "Liste de $1 éléments",
+ "validator-describe-empty": "vide",
+ "validator-describe-required": "requis",
+ "validator-describe-header-parameter": "Paramètre",
+ "validator-describe-header-aliases": "Alias",
+ "validator-describe-header-type": "Type",
+ "validator-describe-header-default": "Par défaut",
+ "validator-describe-header-description": "Description",
+ "validator-describe-parameters": "Paramètres",
+ "validator-describe-syntax": "Syntaxe",
+ "validator-describe-tagmin": "Balise d'extension comprenant seulement les paramètres requis.",
+ "validator-describe-tagmax": "Balise d'extension comprenant tous les paramètres.",
+ "validator-describe-tagdefault": "Balise d'extension comprenant tous les paramètres en utilisant la notation par défaut des paramètres.",
+ "validator-describe-pfmin": "Fonction de l'analyseur syntaxique comprenant seulement les paramètres requis.",
+ "validator-describe-pfmax": "Fonction de l'analyseur syntaxique comprenant tous les paramètres.",
+ "validator-describe-pfdefault": "Fonction de l'analyseur syntaxique comprenant tous les paramètres en utilisant la notation par défaut des paramètres.",
+ "validator-describe-autogen": "Le contenu de cette section a été généré automatiquement par le ''hook'' ''Describe'' de l'extension ''Validator''.",
+ "validator_error_empty_argument": "Le paramètre $1 ne peut pas avoir une valeur vide.",
+ "validator_error_must_be_number": "Le paramètre $1 ne peut être qu'un nombre.",
+ "validator_error_must_be_integer": "Le paramètre $1 ne peut être qu'un entier.",
+ "validator_error_must_be_title": "Le paramètre $1 ne peut être qu'un nom de page wiki valide.",
+ "validator_error_must_be_existing_title": "Le paramètre $1 ne peut être qu'un nom de page wiki existante.",
+ "validator-error-must-be-float": "Le paramètre $1 ne peut être qu'un nombre à virgule flottante.",
+ "validator_error_invalid_range": "Le paramètre $1 doit être compris entre $2 et $3.",
+ "validator-error-invalid-regex": "Le paramètre $1 doit concorder avec cette expression rationnelle : « $2 ».",
+ "validator-error-invalid-length": "Le paramètre $1 doit avoir une longueur de $2.",
+ "validator-error-invalid-length-range": "Le paramètre $1 doit avoir une longueur comprise entre $2 et $3.",
+ "validator_error_invalid_argument": "La valeur $1 n’est pas valide pour le paramètre $2.",
+ "validator_list_error_empty_argument": "Le paramètre $1 n’accepte pas les valeurs vides.",
+ "validator_list_error_must_be_number": "Le paramètre $1 ne peut contenir que des nombres.",
+ "validator_list_error_must_be_integer": "Le paramètre $1 ne peut contenir que des entiers.",
+ "validator_list_error_must_be_title": "Le paramètre $1 ne peut contenir que des noms de page wiki valides.",
+ "validator_list_error_must_be_existing_title": "Le paramètre $1 ne peut contenir que des noms de page wiki existantes.",
+ "validator-list-error-must-be-float": "Le paramètre $1 ne peut contenir que des nombres à virgule.",
+ "validator_list_error_invalid_range": "Toutes les valeurs du paramètre $1 doivent être comprises entre $2 et $3.",
+ "validator-list-error-invalid-regex": "Toutes les valeurs du paramètre $1 doivent concorder avec cette expression rationnelle : « $2 ».",
+ "validator_list_error_invalid_argument": "Une ou plusieurs valeurs du paramètre $1 sont invalides.",
+ "validator-list-error-accepts-only": "Une ou plusieurs valeurs du paramètre $1 sont invalides. Ce paramètre n’accepte que {{PLURAL:$3|cette valeur|ces valeurs}} : $2.",
+ "validator-list-error-accepts-only-omitted": "Une ou plusieurs valeurs du paramètre $1 sont invalides. Ce paramètre n’accepte que {{PLURAL:$3|cette valeur|ces valeurs}} : $2 (et {{PLURAL:$4|la valeur omise|les valeurs omises}} $4).",
+ "validator_error_accepts_only": "La valeur « $4 » n'est pas valable pour le paramètre $1. Ce paramètre accepte uniquement {{PLURAL:$3|cette valeur|ces valeurs}} : $2.",
+ "validator-error-accepts-only-omitted": "La valeur « $2 » n’est pas valable pour le paramètre $1. Ce paramètre n’accepte que {{PLURAL:$5|cette valeur|ces valeurs}} : $3 (et {{PLURAL:$4|la valeur omise|les valeurs omises}} $4).",
+ "validator_list_omitted": "{{PLURAL:$2|La valeur|Les valeurs}} $1 {{PLURAL:$2|a été oubliée|ont été oubliées}}.",
+ "validator-message-nodesc": "Aucune description fournie"
+}
diff --git a/www/wiki/extensions/Validator/i18n/frp.json b/www/wiki/extensions/Validator/i18n/frp.json
new file mode 100644
index 00000000..06d4dc5c
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/frp.json
@@ -0,0 +1,60 @@
+{
+ "@metadata": {
+ "authors": [
+ "ChrisPtDe"
+ ]
+ },
+ "validator-warning": "Avèrtissement : $1",
+ "validator-error": "Èrror : $1",
+ "validator-fatal-error": "Èrror fatala : $1",
+ "validator_error_parameters": "{{PLURAL:$1|Ceta èrror at étâ dècelâ|Cetes èrrors ont étâ dècelâs}} dens voutra sintaxa :",
+ "validator_warning_parameters": "Y at {{PLURAL:$1|una èrror|des èrrors}} dens voutra sintaxa.",
+ "validator-warning-adittional-errors": "... et un {{PLURAL:$1|problèmo de ples|mouél d’ôtros problèmos}}.",
+ "validator-error-omitted": "{{PLURAL:$2|La valor « $1 » at étâ oubliâ|Les valors « $1 » ont étâ oubliâs}}.",
+ "validator-error-problem": "Y at un problèmo avouéc lo paramètre $1.",
+ "validator_error_unknown_argument": "$1 est pas un paramètre valido.",
+ "validator_error_required_missing": "Lo paramètre nècèssèro $1 est pas balyê.",
+ "validator-error-override-argument": "La programeria at tâchiê de remplaciér lo paramètre $1 (valor : $2) avouéc la valor « $3 »",
+ "validator-type-string": "tèxto",
+ "validator-type-integer": "nombro entiér",
+ "validator-type-float": "nombro",
+ "validator-type-boolean": "ouè/nan",
+ "validator-type-char": "caractèro",
+ "validator-type-title": "titro",
+ "validator-type-string-list": "lista de tèxtos",
+ "validator-type-integer-list": "lista de nombros entiérs",
+ "validator-type-float-list": "lista de nombros",
+ "validator-type-boolean-list": "lista de ouè / nan",
+ "validator-type-char-list": "lista de caractèros",
+ "validator-type-title-list": "lista de titros",
+ "validator-listerrors-errors": "Èrrors",
+ "validator-listerrors-minor": "Petiôt",
+ "validator-listerrors-low": "Fêblo",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Hôt",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-describe-descriptionmsg": "'''Dèscripcion :''' $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Nom paralèlo|Noms paralèlos}} :''' $1",
+ "validator-describe-listtype": "Lista de $1 èlèments",
+ "validator-describe-empty": "vouedo",
+ "validator-describe-required": "nècèssèro",
+ "validator-describe-header-parameter": "Paramètre",
+ "validator-describe-header-aliases": "Noms paralèlos",
+ "validator-describe-header-type": "Tipo",
+ "validator-describe-header-default": "Per dèfôt",
+ "validator-describe-header-description": "Dèscripcion",
+ "validator-describe-parameters": "Paramètres",
+ "validator-describe-syntax": "Sintaxa",
+ "validator_error_empty_argument": "Lo paramètre $1 pôt pas avêr una valor voueda.",
+ "validator_error_must_be_number": "Lo paramètre $1 pôt étre ren qu’un nombro.",
+ "validator_error_must_be_integer": "Lo paramètre $1 pôt étre ren qu’un entiér.",
+ "validator_error_invalid_range": "Lo paramètre $1 dêt étre entre-mié $2 et $3.",
+ "validator_error_invalid_argument": "La valor $1 est pas valida por lo paramètre $2.",
+ "validator_list_error_empty_argument": "Lo paramètre $1 accèpte pas les valors vouedes.",
+ "validator_list_error_must_be_number": "Lo paramètre $1 pôt contegnir ren que des nombros.",
+ "validator_list_error_must_be_integer": "Lo paramètre $1 pôt contegnir ren que des entiérs.",
+ "validator_list_error_invalid_range": "Totes les valors du paramètre $1 dêvont étre entre-mié $2 et $3.",
+ "validator_list_error_invalid_argument": "Yona ou ben un mouél de valors du paramètre $1 sont envalides.",
+ "validator_error_accepts_only": "La valor « $4 » est pas valida por lo paramètre $1. Accèpte ren que {{PLURAL:$3|ceta valor|cetes valors}} : $2.",
+ "validator_list_omitted": "{{PLURAL:$2|La valor|Les valors}} $1 {{PLURAL:$2|at étâ oubliâ|ont étâ oubliâs}}."
+}
diff --git a/www/wiki/extensions/Validator/i18n/frr.json b/www/wiki/extensions/Validator/i18n/frr.json
new file mode 100644
index 00000000..9849cdab
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/frr.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Murma174"
+ ]
+ },
+ "validator-describe-empty": "leesag"
+}
diff --git a/www/wiki/extensions/Validator/i18n/fy.json b/www/wiki/extensions/Validator/i18n/fy.json
new file mode 100644
index 00000000..56b636f3
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/fy.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
+ ]
+ },
+ "validator-warning": "Warskôging: $1",
+ "validator-error": "Flater: $1",
+ "validator-listerrors-normal": "Normaal"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ga.json b/www/wiki/extensions/Validator/i18n/ga.json
new file mode 100644
index 00000000..7aa2c519
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ga.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "validator-type-title": "Teideal",
+ "validator-listerrors-normal": "Gnáth",
+ "validator-describe-header-type": "Cineál",
+ "validator-describe-header-default": "réamhshocrú"
+}
diff --git a/www/wiki/extensions/Validator/i18n/gl.json b/www/wiki/extensions/Validator/i18n/gl.json
new file mode 100644
index 00000000..25402dec
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/gl.json
@@ -0,0 +1,94 @@
+{
+ "@metadata": {
+ "authors": [
+ "Toliño",
+ "Elisardojm"
+ ]
+ },
+ "validator-desc": "Biblioteca de procesamento de parámetros declarativos",
+ "validator-warning": "Atención: $1",
+ "validator-error": "Erro: $1",
+ "validator-fatal-error": "Erro fatal: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Detectouse o seguinte erro|Detectáronse os seguintes erros}} na sintaxe empregada:",
+ "validator_warning_parameters": "Hai {{PLURAL:$1|un erro|erros}} na súa sintaxe.",
+ "validator-warning-adittional-errors": "... e {{PLURAL:$1|un problema máis|moitos máis problemas}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Omitiuse o valor \"$1\"|Omitíronse os valores \"$1\"}}.",
+ "validator-error-problem": "Houbo un problema co parámetro $1.",
+ "validator_error_unknown_argument": "\"$1\" non é un parámetro válido.",
+ "validator_error_required_missing": "Non se proporcionou o parámetro obrigatorio \"$1\".",
+ "validator-error-override-argument": "Intentouse sobrescribir o parámetro $1 (valor: $2) co valor \"$3\"",
+ "validator-type-string": "texto",
+ "validator-type-integer": "número enteiro",
+ "validator-type-float": "número",
+ "validator-type-boolean": "si/non",
+ "validator-type-char": "carácter",
+ "validator-type-dimension": "número e unidade de dimensión",
+ "validator-type-title": "título",
+ "validator-type-string-list": "lista de textos",
+ "validator-type-integer-list": "lista de números enteiros",
+ "validator-type-float-list": "lista de números",
+ "validator-type-boolean-list": "lista de si/non",
+ "validator-type-char-list": "lista de caracteres",
+ "validator-type-title-list": "lista de títulos",
+ "validator-listerrors-errors": "Erros",
+ "validator-listerrors-minor": "Menor",
+ "validator-listerrors-low": "Baixo",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Alto",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Lista os erros (e avisos) que ocorreron no asociador do analizador engadidos a través do Validator.\nSó aparecerán nas listas para os asociadores do analizador que estean colocados enriba de listerrors;\ncoloque listerrors na parte inferior da páxina para obter todos os erros.",
+ "validator-listerrors-par-minseverity": "A severidade mínima dun problema para que apareza na lista.",
+ "validator-describe-description": "Xera a documentación para un ou máis asociadores do analizador definidos a través do Validator.",
+ "validator-describe-notfound": "Non hai ningún asociador do analizador que manexe \"$1\".",
+ "validator-describe-descriptionmsg": "'''Descrición:''' $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alcume|Alcumes}}:''' $1",
+ "validator-describe-parserfunction": "Implementado só como función analítica.",
+ "validator-describe-tagextension": "Implementado só como etiqueta de extensión.",
+ "validator-describe-bothhooks": "Implementado como función analítica e como etiqueta de extensión.",
+ "validator-describe-par-hooks": "O analizador de asociadores para o que mostrar a documentación.",
+ "validator-describe-par-pre": "Permite obter o texto wiki para a documentación, sen que sexa renderizado na páxina.",
+ "validator-describe-par-language": "A lingua na que mostrar as descricións",
+ "validator-describe-listtype": "Lista de $1 elementos",
+ "validator-describe-empty": "baleiro",
+ "validator-describe-required": "obrigatorio",
+ "validator-describe-header-parameter": "Parámetro",
+ "validator-describe-header-aliases": "Pseudónimos",
+ "validator-describe-header-type": "Tipo",
+ "validator-describe-header-default": "Por defecto",
+ "validator-describe-header-description": "Descrición",
+ "validator-describe-parameters": "Parámetros",
+ "validator-describe-syntax": "Sintaxe",
+ "validator-describe-tagmin": "Etiqueta de extensión cos únicos parámetros obrigatorios.",
+ "validator-describe-tagmax": "Etiqueta de extensión con todos os parámetros.",
+ "validator-describe-tagdefault": "Etiqueta de extensión con todos os parámetros, empregando a notación por defecto dos parámetros.",
+ "validator-describe-pfmin": "Función analítica cos únicos parámetros obrigatorios.",
+ "validator-describe-pfmax": "Función analítica con todos os parámetros.",
+ "validator-describe-pfdefault": "Función analítica con todos os parámetros, empregando a notación por defecto dos parámetros.",
+ "validator-describe-autogen": "O contido desta sección foi xerado automaticamente polo analizador do asociador \"describir\" da extensión Validator.",
+ "validator_error_empty_argument": "O parámetro \"$1\" non pode ter un valor baleiro.",
+ "validator_error_must_be_number": "O parámetro \"$1\" só pode ser un número.",
+ "validator_error_must_be_integer": "O parámetro \"$1\" só pode ser un número enteiro.",
+ "validator_error_must_be_title": "O parámetro \"$1\" só pode ser o nome válido para unha páxina do wiki.",
+ "validator_error_must_be_existing_title": "O parámetro \"$1\" só pode ser o nome dunha páxina do wiki que exista.",
+ "validator-error-must-be-float": "O parámetro \"$1\" só pode ser un número de coma flotante.",
+ "validator_error_invalid_range": "O parámetro \"$1\" debe estar entre $2 e $3.",
+ "validator-error-invalid-regex": "O parámetro \"$1\" debe coincidir con esta expresión regular: $2.",
+ "validator-error-invalid-length": "O parámetro \"$1\" debe ter unha lonxitude de $2.",
+ "validator-error-invalid-length-range": "O parámetro \"$1\" ter unha lonxitude de entre $2 e $3.",
+ "validator_error_invalid_argument": "O valor \"$1\" non é válido para o parámetro \"$2\".",
+ "validator_list_error_empty_argument": "O parámetro \"$1\" non acepta valores en branco.",
+ "validator_list_error_must_be_number": "O parámetro \"$1\" só pode conter números.",
+ "validator_list_error_must_be_integer": "O parámetro \"$1\" só pode conter números enteiros.",
+ "validator_list_error_must_be_title": "O parámetro \"$1\" só pode conter nomes válidos para páxinas do wiki.",
+ "validator_list_error_must_be_existing_title": "O parámetro \"$1\" só pode conter nomes de páxinas do wiki que existan.",
+ "validator-list-error-must-be-float": "O parámetro \"$1\" só pode conter comas flotantes.",
+ "validator_list_error_invalid_range": "Todos os valores do parámetro \"$1\" deben estar comprendidos entre $2 e $3.",
+ "validator-list-error-invalid-regex": "Todos os valores do parámetro \"$1\" deben coincidir con esta expresión regular: $2.",
+ "validator_list_error_invalid_argument": "Un ou varios valores do parámetro \"$1\" non son válidos.",
+ "validator-list-error-accepts-only": "Un ou varios valores do parámetro \"$1\" non son válidos. Só acepta {{PLURAL:$3|este valor|estes valores}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Un ou varios valores do parámetro \"$1\" non son válidos. Só acepta {{PLURAL:$3|este valor|estes valores}}: $2 (e $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_error_accepts_only": "O valor \"$4\" non é válido para o parámetro \"$1\". Só acepta {{PLURAL:$3|este valor|estes valores}}: $2.",
+ "validator-error-accepts-only-omitted": "O valor \"$2\" non é válido para o parámetro \"$1\". Só acepta {{PLURAL:$5|este valor|estes valores}}: $3 (e $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_list_omitted": "{{PLURAL:$2|O valor|Os valores}} \"$1\" {{PLURAL:$2|foi omitido|foron omitidos}}.",
+ "validator-message-nodesc": "Non se achegou descrición ningunha"
+}
diff --git a/www/wiki/extensions/Validator/i18n/gsw.json b/www/wiki/extensions/Validator/i18n/gsw.json
new file mode 100644
index 00000000..810de37f
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/gsw.json
@@ -0,0 +1,81 @@
+{
+ "@metadata": {
+ "authors": [
+ "Als-Chlämens",
+ "Als-Holder"
+ ]
+ },
+ "validator-desc": "Validator stellt e eifachi Form z Verfiegig fir anderi Erwyterige go Parameter validiere vu Parser- un Tag-Funktione, go Standardwärt definiere un Fählermäldige generiere",
+ "validator-warning": "Warnig: $1",
+ "validator-error": "Fähler: $1",
+ "validator-fatal-error": "Fähler, wu nit cha behobe wäre: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Dää Fähler isch|Die Fähler sin}} in Dyyre Syntax gfunde wore:",
+ "validator_warning_parameters": "S het {{PLURAL:$1|e Fähler|Fähler}} in dyyre Syntax.",
+ "validator-warning-adittional-errors": "... un {{PLURAL:$1|e ander Probläm|$1 anderi Probläm}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Dr Wärt|D Wärt}} „$1“ {{PLURAL:$2|isch|sin}} uusgloo wore.",
+ "validator-error-problem": "S het e Probläm gee mit em Parameter $1.",
+ "validator_error_unknown_argument": "$1 isch kei giltige Parameter.",
+ "validator_error_required_missing": "Dr Paramter $1, wu aagforderet woren isch, wird nit z Verfiegig gstellt.",
+ "validator-error-override-argument": "S isch versuecht wore, dr Parameter $1 (Wärt: $2) mit em Wärt „$3“ z iberschryybe",
+ "validator-type-string": "Täxt",
+ "validator-type-integer": "Ganzzahl",
+ "validator-type-float": "Zahl",
+ "validator-type-boolean": "Jo/Nei",
+ "validator-type-char": "Zeiche",
+ "validator-listerrors-errors": "Fähler",
+ "validator-listerrors-minor": "Gring",
+ "validator-listerrors-low": "Chlei",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Groß",
+ "validator-listerrors-fatal": "Schwär",
+ "validator-listerrors-description": "Zeigt Fähler un Warnigen aa, wu ufträtte sin bi dr Parserhook, wu iber d Erwyterig Validator gnutzt wäre.\nZeigt nume d Parserhook aa, wu iber em Elemänt „listerrors“ yygfiegt wore sin.\n„Listerrors“ sott wäge däm am oder gege Änd vu dr Syte yygfiegt wäre, ass alli Fähler un Warnigen aazeigt wäre.",
+ "validator-listerrors-par-minseverity": "Dr Mindeschtschwärigrad vun eme Probläm, ass es aazeigt wird.",
+ "validator-describe-description": "Generiert d Dokumentation fir ein oder mehreri Parserhook, wu mit dr Erwyterig Validator definiert wore sin.",
+ "validator-describe-notfound": "S git kei Parserhook, wu „$1“ verarbeitet.",
+ "validator-describe-descriptionmsg": "'''Bschrybig:''' $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasse}}:''' $1",
+ "validator-describe-parserfunction": "Numen as Parserfunktion implementiert.",
+ "validator-describe-tagextension": "Numen as Elementerweiteryg implementiert.",
+ "validator-describe-bothhooks": "As Parserfunktion un au as Elementerwyterig implementiert.",
+ "validator-describe-par-hooks": "D Parserhook, wu d Dokumentation derfir soll aazeigt wäre.",
+ "validator-describe-par-pre": "Macht d Uusgab vu dr Dokumentation in Wikitext megli ohni ass dää bi dr Darstellig vu dr Syte gnutzt wird.",
+ "validator-describe-par-language": "D Sprooch, wo d Beschrybe drin aazeigt worde sölle",
+ "validator-describe-listtype": "Lischt vu $1 {{PLURAL:$1|Element|Element}}",
+ "validator-describe-empty": "läär",
+ "validator-describe-required": "erforderlig",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliasse",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Standard",
+ "validator-describe-header-description": "Bschrybig",
+ "validator-describe-parameters": "Parameter",
+ "validator-describe-syntax": "Syntax",
+ "validator-describe-tagmin": "Elementerwyterig, nume mit dr erforderlige Parameter.",
+ "validator-describe-tagmax": "Elementerwyterig mit allne Parameter.",
+ "validator-describe-tagdefault": "Elementerwyterig mit allne Parameter, wu d Standardnotation fir Parameter nutze.",
+ "validator-describe-pfmin": "Parserfunktion, nume mit dr erforderlige Parameter.",
+ "validator-describe-pfmax": "Parserfunktion mit allne Parameter.",
+ "validator-describe-pfdefault": "Parserfunktion mit allne Parameter, wu d Standardnotation fir Parameter nutze.",
+ "validator-describe-autogen": "Dr Inhalt vu däm Abschnitt isch automatisch dur dr Parserhook „describe“ vu dr Erwyterig Validator generiert wore.",
+ "validator_error_empty_argument": "Dr Parameter $1 cha kei lääre Wärt haa.",
+ "validator_error_must_be_number": "Dr Parameter $1 cha nume ne Zahl syy.",
+ "validator_error_must_be_integer": "Parameter $1 cha nume ne giltigi Zahl syy.",
+ "validator-error-must-be-float": "Parameter $1 cha nume ne Gleitkommazahl syy.",
+ "validator_error_invalid_range": "Dr Parameter $1 muess zwische $2 un $3 syy.",
+ "validator-error-invalid-regex": "Parameter $1 mueß däm reguläre Uusdruck entspräche: $2.",
+ "validator-error-invalid-length": "Parameter $1 mueß e Lengi haa vu $2.",
+ "validator-error-invalid-length-range": "Parameter $1 mueß e Lengi haa zwische $2 un $3.",
+ "validator_error_invalid_argument": "Dr Wärt $1 isch nit giltig fir dr Parameter $2.",
+ "validator_list_error_empty_argument": "Bim Parameter $1 sin keini lääre Wärt zuegloo.",
+ "validator_list_error_must_be_number": "Fir dr Parameter $1 si nume Zahle zuegloo.",
+ "validator_list_error_must_be_integer": "Fir dr Parameter $1 sin nume ganzi Zahle zuegloo.",
+ "validator-list-error-must-be-float": "Im Parameter $1 cha s nume Gleitkommazahle haa.",
+ "validator_list_error_invalid_range": "Alli Wärt fir dr Parameter $1 mien zwische $2 un $3 lige.",
+ "validator-list-error-invalid-regex": "Alli Wärt vum Parameter $1 mien däm reguläre Uusdruck entspräche: $2.",
+ "validator_list_error_invalid_argument": "Ein oder mehreri Wärt fir dr Parameter $1 sin nit giltig.",
+ "validator-list-error-accepts-only": "Ein oder meh Wärt fir dr Parameter $1 sin nit giltig.\nNume {{PLURAL:$3|dää Wärt wird|die Wärt wäre}} akzeptiert: $2.",
+ "validator-list-error-accepts-only-omitted": "Ein oder meh Wärt fir dr Parameter $1 sin nit giltig.\nNume {{PLURAL:$3|dää Wärt wird|die Wärt wäre}} akzeptiert: $2 (un $4 uusglosseni {{PLURAL:$4|Wärt|Wärt}}).",
+ "validator_error_accepts_only": "Dr Wärt „$4“ isch nit giltig fir dr Parameter $1. Nume {{PLURAL:$3|dää Wärt wird|die Wärt wäre}} akzeptiert: „$2“.",
+ "validator-error-accepts-only-omitted": "Dr Wärt „$2“ isch nit giltig fir dr Parameter $1.\nNume {{PLURAL:$5|dää Wärt wird|die Wärt wäre}} akzeptiert: $3 (un $4 uusglosseni {{PLURAL:$4|Wärt|Wärt}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Dr Wärt|D Wärt}} $1 {{PLURAL:$2|isch|sin}} uusgloo wore."
+}
diff --git a/www/wiki/extensions/Validator/i18n/he.json b/www/wiki/extensions/Validator/i18n/he.json
new file mode 100644
index 00000000..90eba7f2
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/he.json
@@ -0,0 +1,98 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amire80",
+ "Inkbug",
+ "Rotemliss",
+ "YaronSh",
+ "IKhitron",
+ "Guycn2"
+ ]
+ },
+ "validator-desc": "ספריית עיבוד פרמטרים הצהרתי",
+ "validator-warning": "אזהרה: $1",
+ "validator-error": "שגיאה: $1",
+ "validator-fatal-error": "שגיאה חמורה: $1",
+ "validator_error_parameters": "{{PLURAL:$1|השגיאה הבאה נמצאה|השגיאות הבאות נמצאו}} בתחביר:",
+ "validator_warning_parameters": "{{PLURAL:$1|ישנה שגיאה|ישנן שגיאות}} בתחביר שלכם.",
+ "validator-warning-adittional-errors": "... ועוד {{PLURAL:$1|בעיה אחת|מספר בעיות}}.",
+ "validator-error-omitted": "{{PLURAL:$2|הערך|הערכים}} \"$1\" {{PLURAL:$2|הושמט|הושמטו}}.",
+ "validator-error-problem": "הייתה בעיה עם הפרמטר $1.",
+ "validator_error_unknown_argument": "$1 אינו פרמטר תקני.",
+ "validator_error_required_missing": "הפרמטר הדרוש $1 לא צוין.",
+ "validator-error-override-argument": "ניסיון לעקוף את הפרמטר $1 (ערך: $2) ולהציב את הערך \"$3\"",
+ "validator-type-string": "טקסט",
+ "validator-type-integer": "מספר שלם",
+ "validator-type-float": "מספר",
+ "validator-type-boolean": "כן או לא",
+ "validator-type-char": "תו",
+ "validator-type-dimension": "מספר ויחידה ממדית",
+ "validator-type-title": "כותרת",
+ "validator-type-string-list": "רשימת טקסטים",
+ "validator-type-integer-list": "רשימת מספרים שלמים",
+ "validator-type-float-list": "רשימת מספרים",
+ "validator-type-boolean-list": "רשימת כן/לא",
+ "validator-type-char-list": "רשימת תווים",
+ "validator-type-title-list": "רשימת כותרות",
+ "validator-listerrors-errors": "שגיאות",
+ "validator-listerrors-minor": "משנית",
+ "validator-listerrors-low": "נמוכה",
+ "validator-listerrors-normal": "רגילה",
+ "validator-listerrors-high": "גבוהה",
+ "validator-listerrors-fatal": "חמורה",
+ "validator-listerrors-description": "מכין רשימת של שגיאות ואזהרות שהתרחשו במילות הפעלה של מפענח שנוספו דרך Validator.\nרק רשימות עבור מילות הפעלה של מפענח מעל listerrors;\nיש לשים את listerrors בתחתית העמוד או קרוב אליה כדי לקבל את כל השגיאות.",
+ "validator-listerrors-par-minseverity": "יש להזין את רמת החומרה המזערית.",
+ "validator-describe-description": "מחולל תיעוד עבור מילות הפעלה במפענח שמוגדרות דרך Validator.",
+ "validator-describe-notfound": "\"$1\" אינו מטופל על־ידי שום מילת הפעלה במפענח.",
+ "validator-describe-descriptionmsg": "'''תיאור''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|כינוי|כינויים}}''': $1",
+ "validator-describe-parserfunction": "מיושם רק בתור פונקציית מפענח.",
+ "validator-describe-tagextension": "מיושם רק בתור הרחבת תג.",
+ "validator-describe-bothhooks": "מיושם הן בתור פונקציית מפענח והן בתור הרחבת תג.",
+ "validator-describe-par-hooks": "מילות הפעלה של מפענח שעבורן יש להציג תיעוד.",
+ "validator-describe-par-pre": "מאפשר לייצר את קוד הוויקי עבור התיעוד מבלי להציג אותו על הדף.",
+ "validator-describe-par-language": "באיזו שפה להציג את התיאורים",
+ "validator-describe-listtype": "רשימה של פריטים מסוג \"$1\"",
+ "validator-describe-empty": "ריק",
+ "validator-describe-required": "נדרש",
+ "validator-describe-header-parameter": "פרמטר",
+ "validator-describe-header-aliases": "כינויים",
+ "validator-describe-header-type": "סוג",
+ "validator-describe-header-default": "בררת המחדל",
+ "validator-describe-header-description": "תיאור",
+ "validator-describe-parameters": "פרמטרים",
+ "validator-describe-syntax": "תחביר",
+ "validator-describe-tagmin": "הרחבת תג רק עם הפרמטרים הדרושים.",
+ "validator-describe-tagmax": "הרחבת תג עם כל הפרמטרים.",
+ "validator-describe-tagdefault": "הרחבת תג עם כל הפרמטרים עם ציון פרמטרים בבררת מחדל.",
+ "validator-describe-pfmin": "פונקציית מפענח רק עם הפרמטרים הדרושים.",
+ "validator-describe-pfmax": "פונקציית מפענח עם כל הפרמטרים.",
+ "validator-describe-pfdefault": "פונקציית מפענח שבה כל הפרמטרים משתמשים בציון פרמטרים בבררת מחדל.",
+ "validator-describe-autogen": "תוכן החלק הזה חולל באופן אוטומטי באמצעות מילת ההפעלה \"descrbibe\" של ההרחבה Validator.",
+ "validator_error_empty_argument": "הפרמטר $1 לא יכול להיות ערך ריק.",
+ "validator_error_must_be_number": "הפרמטר $1 יכול להיות מספר בלבד.",
+ "validator_error_must_be_integer": "הפרמטר $1 יכול להיות מספר שלם בלבד.",
+ "validator_error_must_be_title": "פרמטר $1 יכול להיות רק שם תקין של דף ויקי.",
+ "validator_error_must_be_existing_title": "פרמטר $1 יכול להיות רק שם של דף ויקי קיים.",
+ "validator-error-must-be-float": "הפרמטר $1 יכול להיות רק מספר עם נקודה צפה.",
+ "validator_error_invalid_range": "הפרמטר $1 חייב להיות בין $2 ל־$3.",
+ "validator-error-invalid-regex": "פרמטר $1 חייב להתאים לביטוי הרגולרי הבא: $2.",
+ "validator-error-invalid-length": "אורך פרמטר $1 חייב להיות $2.",
+ "validator-error-invalid-length-range": "אורך פרמטר $1 חייב להיות בין $2 לבין $3.",
+ "validator_error_invalid_argument": "הערך $1 אינו תקני עבור הפרמטר $2.",
+ "validator_list_error_empty_argument": "פרמטר $1 אינו יכול להיות ריק.",
+ "validator_list_error_must_be_number": "פרמטר $1 יכול להכיל רק מספרים.",
+ "validator_list_error_must_be_integer": "פרמטר $1 יכול להכיל רק מספרים שלמים.",
+ "validator_list_error_must_be_title": "פרמטר $1 יכול להכיל רק שמות של דפי ויקי תקינים.",
+ "validator_list_error_must_be_existing_title": "פרמטר $1 יכול להכיל רק שמות של דפי ויקי קיימים.",
+ "validator-list-error-must-be-float": "פרמטר $1 יכול להכיל רק מספר עם נקודה צפה.",
+ "validator_list_error_invalid_range": "כל הערכים של הפרמטר $1 צריכים להיות בין $2 לבין $3.",
+ "validator-list-error-invalid-regex": "כל הערכים של הפרמטר $1 צריכים להתאים לביטוי הרגולרי הבא: $2.",
+ "validator_list_error_invalid_argument": "ערך בלתי־חוקי אחד או יותר עבור הפרמטר $1.",
+ "validator-list-error-accepts-only": "ערך בלתי־חוקי אחד או יותר עבור הפרמטר $1. הוא מקבל רק את {{PLURAL:$3|הערך הזה|הערכים האלה}}: $2.",
+ "validator-list-error-accepts-only-omitted": "ערכים לא תקינים הוזנו לפרמטר \"$1\". הוא יכול לקבל רק את {{PLURAL:$3|הערך הבא|הערכים הבאים}}: $2 (וכן {{PLURAL:$4|ערך מושמט אחד|$4 ערכים מושמטים}}).",
+ "validator_error_accepts_only": "הערך \"$4\" אינו תקין עבור הפרמטר $1. הוא מקבל רק את {{PLURAL:$3|הערך הבא|הערכים הבאים}}: $2.",
+ "validator-error-accepts-only-omitted": "הערך \"$2\" אינו תקין עבור הפרמטר $1. הוא יכול לקבל רק את {{PLURAL:$5|הערך הבא|הערכים הבאים}}: $3 (וכן {{PLURAL:$4|ערך מושמט אחד|$4 ערכים מושמטים}}).",
+ "validator_list_omitted": "{{PLURAL:$2|הערך|הערכים}} $1 {{PLURAL:$2|הושמט|הושמטו}}.",
+ "validator-message-nodesc": "ללא תיאור"
+}
diff --git a/www/wiki/extensions/Validator/i18n/hsb.json b/www/wiki/extensions/Validator/i18n/hsb.json
new file mode 100644
index 00000000..ee093682
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/hsb.json
@@ -0,0 +1,92 @@
+{
+ "@metadata": {
+ "authors": [
+ "Michawiki"
+ ]
+ },
+ "validator-desc": "Deklaratiwna biblioteka za předźěłowanje parametrow",
+ "validator-warning": "Warnowanje: $1",
+ "validator-error": "Zmylk: $1",
+ "validator-fatal-error": "Chutny zmylk: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Slědowacy zmylk bu|Slědowacej zmylkaj buštej|Slědowace zmylki buchu|Slědowace zmylki buchu}} w twojej syntaksy {{PLURAL:$1|wotkryty|wotkrytej|wotkryte|wotkryte}}:",
+ "validator_warning_parameters": "{{PLURAL:$1|Je zmylk|Stej zmylkaj|Su zmylki|Su zmylki}} w twojej syntaksy.",
+ "validator-warning-adittional-errors": "... a {{PLURAL:$1|dalši problem|dalšej problemaj|dalše problemy|dalše problemy}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Hódnota \"$1\" je so wuwostajena|Hódnoće \"$1\" stej so wuwostajenej|Hódnoty \"$1\" su so wuwostajene|Hódnoty \"$1\" su so wuwostajene}}.",
+ "validator-error-problem": "Bě problem z parametrom $1.",
+ "validator_error_unknown_argument": "$1 płaćiwy parameter njeje.",
+ "validator_error_required_missing": "Trěbny parameter $1 njeje podaty.",
+ "validator-error-override-argument": "Spyta so parameter $1 (hódnota: $2) přez \"$3\" přepisować",
+ "validator-type-string": "tekst",
+ "validator-type-integer": "cyła ličba",
+ "validator-type-float": "ličba",
+ "validator-type-boolean": "haj/ně",
+ "validator-type-char": "znamješko",
+ "validator-type-title": "titul",
+ "validator-type-string-list": "tekstowa lisćina",
+ "validator-type-integer-list": "lisćina cyłych ličbow",
+ "validator-type-float-list": "lisćina ličbow",
+ "validator-type-boolean-list": "lisćina haj-ně",
+ "validator-type-char-list": "znamješka nalistować",
+ "validator-type-title-list": "lisćina titulow",
+ "validator-listerrors-errors": "Zmylki",
+ "validator-listerrors-minor": "Snadny",
+ "validator-listerrors-low": "Niski",
+ "validator-listerrors-normal": "Normalny",
+ "validator-listerrors-high": "Wysoki",
+ "validator-listerrors-fatal": "Chutny",
+ "validator-listerrors-description": "Nalistuje zmylki (a warnowanja), kotrež su w parserowych hóčkach wustupili, kotrež su so přez Validator přidali.\nListuje jenož parserowe hóčki, kotrež bu wyše \"listerror\" zasunjene;\nstaj \"listerrors\" deleka na stronje abo blisko kónca strony, zo by wšě zmylki widźał.",
+ "validator-listerrors-par-minseverity": "Minimalna ćežkosć problema, zo by so zwobraznił.",
+ "validator-describe-description": "Płodźi dokumentaciju za jednu parserowu hóčku abo wjacore parserowe hóčki přez Validator.",
+ "validator-describe-notfound": "Njeje parserowa hóčka, kotraž \"$1\" wobdźěłuje.",
+ "validator-describe-descriptionmsg": "'''Wopisanje''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasaj|Aliasy|Aliasow}}''': $1",
+ "validator-describe-parserfunction": "Jenož jako parserowa funkcija implementowany.",
+ "validator-describe-tagextension": "Jenož jako elementowe rozšěrjenje implementowany.",
+ "validator-describe-bothhooks": "Jako parserowa funkcija kaž tež jako elementowe rozšěrjenje implementowany.",
+ "validator-describe-par-hooks": "Parserowe hóčki, za kotrež ma so dokumentacija zwobraznić.",
+ "validator-describe-par-pre": "Zmóžnja woprawdźity wikitekst za dokumentaciju wobstarać, bjez toho zo so na stronje rysował.",
+ "validator-describe-par-language": "Rěč, w kotrejž wopisanje ma so zwobraznić",
+ "validator-describe-listtype": "Lisćina $1 {{PLURAL:$1|elementa|elementow|elementow|elementow}}",
+ "validator-describe-empty": "prózdny",
+ "validator-describe-required": "trěbny",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliasy",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Standard",
+ "validator-describe-header-description": "Wopisanje",
+ "validator-describe-parameters": "Parametry",
+ "validator-describe-syntax": "Syntaksa",
+ "validator-describe-tagmin": "Elementowe rozšěrjenje jenož z trěbnymi parametrami.",
+ "validator-describe-tagmax": "Elementowe rozšěrjenje ze wšěmi parametrami.",
+ "validator-describe-tagdefault": "Elementowe rozšěrjenje ze wšěmi parametrami, kotrež standardnu notaciju za parametry wužiwaja.",
+ "validator-describe-pfmin": "Parserowa funkcija jenož z trěbnymi parametrami.",
+ "validator-describe-pfmax": "Parserowa funkcija ze wšěmi parametrami.",
+ "validator-describe-pfdefault": "Parserowa funkcija ze wšěmi parametrami, kotrež standardnu notaciju za parametry wužiwaja.",
+ "validator-describe-autogen": "Wobsah tutoho wotrězka je so přez parserowu hóčku rozšěrjenja Validator awtomatisce spłodźił.",
+ "validator_error_empty_argument": "Parameter $1 njemóže prózdnu hódnotu měć.",
+ "validator_error_must_be_number": "Parameter $1 móže jenož ličba być.",
+ "validator_error_must_be_integer": "Parameter $1 móže jenož cyła ličba być.",
+ "validator_error_must_be_title": "Parameter $1 móže jenož płaćiwe mjeno wikistrony być.",
+ "validator_error_must_be_existing_title": "Parameter $1 móže jenož ekistowace mjeno wikistrony być.",
+ "validator-error-must-be-float": "Parameter $1 móže jenož ličba z pohibliwej komu być.",
+ "validator_error_invalid_range": "Parameter $1 dyrbi mjez $2 a $3 być.",
+ "validator-error-invalid-regex": "Parameter $1 dyrbi tutomu regularnemu wurazej wotpowědować: $2",
+ "validator-error-invalid-length": "Parameter $1 dyrbi $2 dołhi być.",
+ "validator-error-invalid-length-range": "Parameter $1 dyrbi mjez $2 a $3 dołhi być.",
+ "validator_error_invalid_argument": "Hódnota $1 njeje płaćiwa za parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 njeakceptuje prózdne hódnoty.",
+ "validator_list_error_must_be_number": "Parameter $1 móže jenož ličby wobsahować.",
+ "validator_list_error_must_be_integer": "Parameter $1 móže jenož cyłe ličby wobsahować.",
+ "validator_list_error_must_be_title": "Parameter $1 móže jenož płaćiwe mjena wikistronow wobsahować.",
+ "validator_list_error_must_be_existing_title": "Parameter $1 móže jenož eksistowace mjena wikistronow wobsahować.",
+ "validator-list-error-must-be-float": "Parameter $1 móže jenož ličby z pohibliwej komu wobsahować.",
+ "validator_list_error_invalid_range": "Wšě hódnoty parametra $1 dyrbja mjez $2 a $3 być.",
+ "validator-list-error-invalid-regex": "Wšě hódnoty parametra $1 dyrbja tutomu regularnemu wurazej wotpowědować: $2",
+ "validator_list_error_invalid_argument": "Jedna hódnota abo wjace hódnotow za parameter $1 su njepłaćiwe.",
+ "validator-list-error-accepts-only": "Jedna abo wjacore hódnoty za parameter $1 su njepłaćiwe. {{PLURAL:$3|Akceptuje|Akceptujetej|Akceptuja|Akceptuja}} so jenož {{PLURAL:$3|tuta hódnota|tutej hódnoće|tute hódnoty|tute hódnoty}}: $2",
+ "validator-list-error-accepts-only-omitted": "Jedna abo wjacore hódnoty za parameter $1 su njepłaćiwe. {{PLURAL:$3|Akceptuje|Akceptujetej|Akceptuja|Akceptuja}} so jenož {{PLURAL:$3|tuta hódnota|tutej hódnoće|tute hódnoty|tute hódnoty}}: $2 (a $4 {{PLURAl:$4|wuwostajena hódnota|wuwostajenej hódnoće|wuwostajene hódnoty|wuwostajenych hódnotow}}).",
+ "validator_error_accepts_only": "Hódnota \"$4\" za parameter $1 płaćiwa njeje. Akceptuje jenož {{PLURAL:$3|tutu hódnotu|tutej hódnoće|tute hódnoty|tute hódnoty}}: $2.",
+ "validator-error-accepts-only-omitted": "Hódnota \"$2\" njeje płaćiwa za parameter $1. {{PLURAL:$5|Akceptuje|Akceptujetej|Akceptuja|Akceptuja}} so jenož {{PLURAL:$5|tuta hódnota|tutej hódnoće|tute hódnoty|tute hódnoty}}: $3 (a $4 {{PLURAl:$4|wuwostajena hódnota|wuwostajenej hódnoće|wuwostajene hódnoty|wuwostajenych hódnotow}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Hódnota|Hódnoće|Hódnoty|Hódnoty}} $1 {{PLURAL:$2|je so wuwostajiła|stej so wuwostajiłoj|su so wuwostajili|su so wuwostajili}}.",
+ "validator-message-nodesc": "Žane wopisanje podate"
+}
diff --git a/www/wiki/extensions/Validator/i18n/hu.json b/www/wiki/extensions/Validator/i18n/hu.json
new file mode 100644
index 00000000..b9b97192
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/hu.json
@@ -0,0 +1,64 @@
+{
+ "@metadata": {
+ "authors": [
+ "Dani",
+ "Glanthor Reviol",
+ "TK-999"
+ ]
+ },
+ "validator-desc": "Az érvényesség-ellenőrző egyszerű lehetőséget nyújt más kiterjesztéseknek az elemzőfüggvények és tagek paramétereinek ellenőrzésére, alapértelmezett értékek beállítására, valamint hibaüzenetek generálására.",
+ "validator-warning": "Figyelmeztetés: $1",
+ "validator-error": "Hiba: $1",
+ "validator-fatal-error": "Végzetes hiba: $1",
+ "validator_error_parameters": "A következő {{PLURAL:$1|hiba található|hibák találhatóak}} a szintaxisban:",
+ "validator_warning_parameters": "{{PLURAL:$1|Hiba van|Hibák vannak}} a szintaxisodban.",
+ "validator-warning-adittional-errors": "... és {{PLURAL:$1|egy|több}} további hiba.",
+ "validator-error-omitted": "A(z) \"$1\" {{PLURAL:$2|értéket|értékeket}} kihagyták.",
+ "validator-error-problem": "Probléma volt a(z) $1 paraméterrel.",
+ "validator_error_unknown_argument": "A(z) $1 nem érvényes paraméter.",
+ "validator_error_required_missing": "A(z) $1 kötelező paraméter nem lett megadva.",
+ "validator-error-override-argument": "Megkísérelte a(z) $1 paraméter (érték: $2) felülírását a(z) \"$3\" értékkel.",
+ "validator-type-string": "szöveg",
+ "validator-type-integer": "egész szám",
+ "validator-type-float": "szám",
+ "validator-type-boolean": "igen/nem",
+ "validator-type-char": "karakter",
+ "validator-type-title": "cím",
+ "validator-type-string-list": "szövegek listája",
+ "validator-type-integer-list": "egész számok listája",
+ "validator-type-float-list": "számok listája",
+ "validator-type-boolean-list": "igen/nem lista",
+ "validator-listerrors-errors": "Hibák",
+ "validator-listerrors-minor": "Apró",
+ "validator-listerrors-low": "Alacsony",
+ "validator-listerrors-normal": "Normális",
+ "validator-listerrors-high": "Komoly",
+ "validator-listerrors-fatal": "Végzetes",
+ "validator-describe-descriptionmsg": "'''Leírás''': $1",
+ "validator-describe-empty": "üres",
+ "validator-describe-required": "kötelező",
+ "validator-describe-header-parameter": "Paraméter",
+ "validator-describe-header-aliases": "Álnevek",
+ "validator-describe-header-type": "Típus",
+ "validator-describe-header-default": "Alapértelmezett",
+ "validator-describe-header-description": "Leírás",
+ "validator-describe-parameters": "Paraméterek",
+ "validator-describe-syntax": "Szintaxis",
+ "validator_error_empty_argument": "A(z) $1 paraméter értéke nem lehet üres.",
+ "validator_error_must_be_number": "A(z) $1 paraméter csak szám lehet.",
+ "validator_error_must_be_integer": "A(z) $1 paraméter csak egész szám lehet.",
+ "validator-error-must-be-float": "A(z) $1 paraméter csak lebegőpontos szám lehet.",
+ "validator_error_invalid_range": "A(z) $1 paraméter értékének $2 és $3 között kell lennie.",
+ "validator-error-invalid-regex": "A(z) $1 paraméternek illeszkednie kell a következő reguláris kifejezésre: $2.",
+ "validator-error-invalid-length": "A(z) $1 paraméternek legalább $2 karakter hosszúnak kell lennie.",
+ "validator-error-invalid-length-range": "A(z) $1 paraméternek $2 és $3 karakter közötti hosszúnak kell lennie.",
+ "validator_error_invalid_argument": "A(z) $1 érték nem érvényes a(z) $2 paraméterhez.",
+ "validator_list_error_empty_argument": "A(z) $1 paraméter nem fogad el üres értékeket.",
+ "validator_list_error_must_be_number": "A(z) $1 paraméter csak számokat tartalmazhat.",
+ "validator_list_error_must_be_integer": "A(z) $1 paraméter csak egész számokat tartalmazhat.",
+ "validator-list-error-must-be-float": "A(z) $1 paraméter csak lebegőpontos számokat tartalmazhat.",
+ "validator_list_error_invalid_range": "A(z) $1 paraméter összes értékének $2 és $3 közöttinek kell lennie.",
+ "validator_list_error_invalid_argument": "A(z) $1 paraméter egy vagy több értéke érvénytelen.",
+ "validator_error_accepts_only": "A(z) $1 paraméter csak a következő {{PLURAL:$3|értéket|értékeket}} fogadja el: $2",
+ "validator_list_omitted": "A(z) $1 {{PLURAL:$2|érték mellőzve lett.|értékek mellőzve lettek.}}"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ia.json b/www/wiki/extensions/Validator/i18n/ia.json
new file mode 100644
index 00000000..670ac9a5
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ia.json
@@ -0,0 +1,92 @@
+{
+ "@metadata": {
+ "authors": [
+ "McDutchie"
+ ]
+ },
+ "validator-desc": "Bibliotheca pro le tractamento de parametros declarative",
+ "validator-warning": "Aviso: $1",
+ "validator-error": "Error: $1",
+ "validator-fatal-error": "Error fatal: $1",
+ "validator_error_parameters": "Le sequente {{PLURAL:$1|error|errores}} ha essite detegite in tu syntaxe:",
+ "validator_warning_parameters": "Il ha {{PLURAL:$1|un error|errores}} in tu syntaxe.",
+ "validator-warning-adittional-errors": "... e {{PLURAL:$1|un altere problema|plure altere problemas}}.",
+ "validator-error-omitted": "Le {{PLURAL:$2|valor|valores}} \"$1\" ha essite omittite.",
+ "validator-error-problem": "Il habeva un problema con le parametro $1.",
+ "validator_error_unknown_argument": "$1 non es un parametro valide.",
+ "validator_error_required_missing": "Le parametro requisite $1 non ha essite fornite.",
+ "validator-error-override-argument": "Tentava supplantar le parametro $1 (valor: $2) con le valor \"$3\"",
+ "validator-type-string": "texto",
+ "validator-type-integer": "numero integre",
+ "validator-type-float": "numero",
+ "validator-type-boolean": "si/no",
+ "validator-type-char": "character",
+ "validator-type-title": "titulo",
+ "validator-type-string-list": "lista de textos",
+ "validator-type-integer-list": "lista de numeros integre",
+ "validator-type-float-list": "lista de numeros",
+ "validator-type-boolean-list": "lista de si/no",
+ "validator-type-char-list": "lista de characteres",
+ "validator-type-title-list": "lista de titulos",
+ "validator-listerrors-errors": "Errores",
+ "validator-listerrors-minor": "Minor",
+ "validator-listerrors-low": "Basse",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Alte",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Lista errores (e advertimentos) que occurreva in uncinos analysator addite con Validator.\nIsto face listas solmente pro le uncinos analysator addite supra le loco ubi \"listerrors\" es inserite;\nmitte \"listerrors\" al fin del pagina, o proxime al fin, pro obtener tote le errores.",
+ "validator-listerrors-par-minseverity": "Le severitate minime de un problema pro esser listate.",
+ "validator-describe-description": "Genera documentation pro un o plus uncinos del analysator syntactic, definite via Validator.",
+ "validator-describe-notfound": "Non existe un uncino del analysator syntactic que manea \"$1\".",
+ "validator-describe-descriptionmsg": "'''Description''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliases}}''': $1",
+ "validator-describe-parserfunction": "Implementate solmente como function del analysator syntactic.",
+ "validator-describe-tagextension": "Implementate solmente como extension de etiquetta.",
+ "validator-describe-bothhooks": "Implementate como function del analysator syntactic e como extension de etiquetta.",
+ "validator-describe-par-hooks": "Le uncinos del analysator syntactic pro le quales presentar documentation.",
+ "validator-describe-par-pre": "Permitte obtener le ver wikitexto pro le documentation, sin render lo in le pagina.",
+ "validator-describe-par-language": "Le lingua in que presentar le descriptiones",
+ "validator-describe-listtype": "Lista de $1 elementos",
+ "validator-describe-empty": "vacue",
+ "validator-describe-required": "requirite",
+ "validator-describe-header-parameter": "Parametro",
+ "validator-describe-header-aliases": "Aliases",
+ "validator-describe-header-type": "Typo",
+ "validator-describe-header-default": "Predefinition",
+ "validator-describe-header-description": "Description",
+ "validator-describe-parameters": "Parametros",
+ "validator-describe-syntax": "Syntaxe",
+ "validator-describe-tagmin": "Extension de etiquetta con solmente le parametros obligatori.",
+ "validator-describe-tagmax": "Extension de etiquetta con tote le parametros.",
+ "validator-describe-tagdefault": "Extension de etiquetta con tote le parametros usante le notation predefinite de parametros.",
+ "validator-describe-pfmin": "Function analysator con solmente le parametros obligatori.",
+ "validator-describe-pfmax": "Function analysator con tote le parametros.",
+ "validator-describe-pfdefault": "Function analysator con tote le parametros usante le notation predefinite de parametros.",
+ "validator-describe-autogen": "Le contento de iste section esseva auto-generate per le uncino analysator \"describe\" del extension Validator.",
+ "validator_error_empty_argument": "Le parametro $1 non pote haber un valor vacue.",
+ "validator_error_must_be_number": "Le parametro $1 pote solmente esser un numero.",
+ "validator_error_must_be_integer": "Le parametro $1 pote solmente esser un numero integre.",
+ "validator_error_must_be_title": "Le parametro $1 pote solmente esser un nomine de pagina wiki valide.",
+ "validator_error_must_be_existing_title": "Le parametro $1 pote solmente esser un nomine de pagina wiki existente.",
+ "validator-error-must-be-float": "Le parametro $1 pote solmente esser un numero con fraction decimal.",
+ "validator_error_invalid_range": "Le parametro $1 debe esser inter $2 e $3.",
+ "validator-error-invalid-regex": "Le parametro $1 debe corresponder a iste expression regular: $2.",
+ "validator-error-invalid-length": "Le parametro $1 debe haber un longitude de $2.",
+ "validator-error-invalid-length-range": "Le parametro $1 debe haber un longitude inter $2 e $3.",
+ "validator_error_invalid_argument": "Le valor $1 non es valide pro le parametro $2.",
+ "validator_list_error_empty_argument": "Le parametro $1 non accepta valores vacue.",
+ "validator_list_error_must_be_number": "Le parametro $1 pote solmente continer numeros.",
+ "validator_list_error_must_be_integer": "Le parametro $1 pote solmente continer numeros integre.",
+ "validator_list_error_must_be_title": "Le parametro $1 pote solmente continer nomines de pagina wiki valide.",
+ "validator_list_error_must_be_existing_title": "Le parametro $1 pote solmente continer nomines de pagina wiki existente.",
+ "validator-list-error-must-be-float": "Le parametro $1 pote solmente continer numeros a comma flottante.",
+ "validator_list_error_invalid_range": "Tote le valores del parametro $1 debe esser inter $2 e $3.",
+ "validator-list-error-invalid-regex": "Tote le valores del parametro $1 debe corresponder a iste expression regular: $2.",
+ "validator_list_error_invalid_argument": "Un o plus valores pro le parametro $1 es invalide.",
+ "validator-list-error-accepts-only": "Un o plus valores del parametro $1 es invalide.\nIllo accepta solmente iste {{PLURAL:$3|valor|valores}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Un o plus valores del parametro $1 es invalide.\nIllo accepta solmente iste {{PLURAL:$3|valor|valores}}: $2. (e $4 {{PLURAL:$4|valor|valores}} omittite).",
+ "validator_error_accepts_only": "Le valor \"$4\" non es valide pro le parametro $1. Illo accepta solmente iste {{PLURAL:$3|valor|valores}}: $2.",
+ "validator-error-accepts-only-omitted": "Le valor \"$2\" non es valide pro le parametro $1.\nIllo accepta solmente iste {{PLURAL:$5|valor|valores}}: $3 (e $4 {{PLURAL:$4|valor|valores}} omittite).",
+ "validator_list_omitted": "Le {{PLURAL:$2|valor|valores}} $1 ha essite omittite.",
+ "validator-message-nodesc": "Sin description"
+}
diff --git a/www/wiki/extensions/Validator/i18n/id.json b/www/wiki/extensions/Validator/i18n/id.json
new file mode 100644
index 00000000..7d242067
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/id.json
@@ -0,0 +1,82 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bennylin",
+ "Farras",
+ "Irwangatot",
+ "IvanLanin"
+ ]
+ },
+ "validator-desc": "Validator memberikan cara mudah untuk ekstensi lain untuk memvalidasi parameter ParserFunction dan ekstensi tag, mengatur nilai biasa dan membuat pesan kesalahan",
+ "validator-warning": "Peringatan: $1",
+ "validator-error": "Kesalahan: $1",
+ "validator-fatal-error": "Kesalahan fatal: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Kesalahan|Kesalahan}} berikut telah terdeteksi pada sintaks Anda:",
+ "validator_warning_parameters": "Terdapat {{PLURAL:$1|kesalahan|kesalahan}} pada sintaks Anda.",
+ "validator-warning-adittional-errors": "... dan {{PLURAL:$1|satu|banyak}} masalah lain.",
+ "validator-error-omitted": "Nilai {{PLURAL:$2|\"$1\"|\"$1\"}} telah diabaikan.",
+ "validator-error-problem": "Ada masalah dengan parameter $1.",
+ "validator_error_unknown_argument": "$1 bukan parameter yang benar.",
+ "validator_error_required_missing": "Parameter $1 yang diperlukan tidak diberikan.",
+ "validator-error-override-argument": "Mencoba menimpa parameter $1 (nilai: $2) dengan nilai \"$3\"",
+ "validator-type-string": "teks",
+ "validator-type-integer": "bilangan bulat",
+ "validator-type-float": "nomor",
+ "validator-type-boolean": "ya/tidak",
+ "validator-type-char": "karakter",
+ "validator-listerrors-errors": "Kesalahan",
+ "validator-listerrors-minor": "Kecil",
+ "validator-listerrors-low": "Rendah",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Tinggi",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Daftar galat (dan peringatan) yang terjadi pada pengait parser yang ditambahkan melalui Validator.\nHanya daftar untuk pengait parser yang ditambahkan di atas bagian tempat listerrors disisipkan;\ntempatkan listerrors pada atau di dekat bagian bawah halaman untuk mendapatkan semua kesalahan.",
+ "validator-listerrors-par-minseverity": "Tingkat keparahan minimum masalah yang didaftarkan.",
+ "validator-describe-description": "Menghasilkan dokumentasi untuk satu atau beberapa pengait parser yang didefinisikan melalui Validator.",
+ "validator-describe-notfound": "Tidak ada pengait parser yang menangani \"$1\".",
+ "validator-describe-descriptionmsg": "'''Deskripsi''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Alias}}''': $1",
+ "validator-describe-parserfunction": "Diterapkan hanya sebagai fungsi parser.",
+ "validator-describe-tagextension": "Diterapkan hanya sebagai ekstensi tag.",
+ "validator-describe-bothhooks": "Diterapkan sebagai fungsi parser dan ekstensi tag.",
+ "validator-describe-par-hooks": "Pengait parser untuk menampilkan dokumentasi.",
+ "validator-describe-par-pre": "Memungkinkan Anda mengambil tekswiki aktual untuk dokumentasi, tanpa ditampilkan pada halaman.",
+ "validator-describe-listtype": "Daftar $1 butir",
+ "validator-describe-empty": "kosong",
+ "validator-describe-required": "wajib diisi",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Alias",
+ "validator-describe-header-type": "Jenis",
+ "validator-describe-header-default": "Bawaan",
+ "validator-describe-header-description": "Deskripsi",
+ "validator-describe-parameters": "Parameter",
+ "validator-describe-syntax": "Sintaksis",
+ "validator-describe-tagmin": "Ekstensi tag hanya dengan parameter wajib.",
+ "validator-describe-tagmax": "Ekstensi tag dengan semua parameter.",
+ "validator-describe-tagdefault": "Ekstensi tag dengan semua parameter menggunakan notasi parameter bawaan.",
+ "validator-describe-pfmin": "Fungsi parser hanya dengan parameter wajib.",
+ "validator-describe-pfmax": "Fungsi parser dengan semua parameter.",
+ "validator-describe-pfdefault": "Fungsi parser dengan semua parameter menggunakan notasi parameter bawaan.",
+ "validator-describe-autogen": "Isi bagian ini adalah dihasilkan otomatis oleh pengait parser \"describe\" dari ekstensi Validator.",
+ "validator_error_empty_argument": "Parameter $1 tidak dapat bernilai kosong.",
+ "validator_error_must_be_number": "Parameter $1 hanya dapat berupa angka.",
+ "validator_error_must_be_integer": "Parameter $1 hanya dapat berupa integer.",
+ "validator-error-must-be-float": "Parameter $1 hanya dapat berupa angka titik kambang.",
+ "validator_error_invalid_range": "Parameter $1 harus antara $2 dan $3.",
+ "validator-error-invalid-regex": "Parameter $1 harus sesuai dengan persamaan reguler: $2.",
+ "validator-error-invalid-length": "Parameter $1 harus memiliki panjang $2.",
+ "validator-error-invalid-length-range": "Parameter $1 harus memiliki panjang antara $2 dan $3.",
+ "validator_error_invalid_argument": "Nilai $1 tidak valid untuk parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 tidak menerima nilai kosong.",
+ "validator_list_error_must_be_number": "Parameter $1 hanya dapat berisi angka.",
+ "validator_list_error_must_be_integer": "Parameter $1 hanya dapat berisi bilangan bulat.",
+ "validator-list-error-must-be-float": "Parameter $1 hanya dapat berisi angka kambang.",
+ "validator_list_error_invalid_range": "Semua nilai parameter $1 harus antara $2 dan $3.",
+ "validator-list-error-invalid-regex": "Semua nilai parameter $1 harus sesuai dengan persamaan reguler: $2.",
+ "validator_list_error_invalid_argument": "Satu nilai atau lebih untuk parameter $1 tidak sah.",
+ "validator-list-error-accepts-only": "Satu atau lebih nilai untuk parameter $1 tidak sah. Parameter itu hanya menerima {{PLURAL:$3|nilai berikut|nilai berikut}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Satu atau lebih nilai untuk parameter $1 tidak sah. Parameter itu hanya menerima {{PLURAL:$3|nilai berikut|nilai berikut}}: $2 (dan $4 {{PLURAL:$4|nilai|nilai}} yang diabaikan).",
+ "validator_error_accepts_only": "Nilai \"$4\" tidak sah untuk parameter $1. Nilai yang diterima hanyalah {{PLURAL:$3|nilai ini|nilai-nilai ini}}: $2.",
+ "validator-error-accepts-only-omitted": "Nilai \"$2\" tidak sah untuk parameter $1. Parameter itu hanya menerima {{PLURAL:$5|nilai berikut|nilai berikut}}: $3 (dan $4 {{PLURAL:$4|nilai|nilai}} yang diabaikan).",
+ "validator_list_omitted": "{{PLURAL:$2|Nilai|Nilai}} $1 {{PLURAL:$2|telah|telah}} dihapus."
+}
diff --git a/www/wiki/extensions/Validator/i18n/it.json b/www/wiki/extensions/Validator/i18n/it.json
new file mode 100644
index 00000000..323469f6
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/it.json
@@ -0,0 +1,95 @@
+{
+ "@metadata": {
+ "authors": [
+ "Beta16",
+ "Civvì",
+ "HalphaZ"
+ ]
+ },
+ "validator-desc": "Libreria per la dichiarazione dei parametri di elaborazione",
+ "validator-warning": "Attenzione: $1",
+ "validator-error": "Errore: $1",
+ "validator-fatal-error": "Errore fatale: $1",
+ "validator_error_parameters": "Nella tua sintassi {{PLURAL:$1|è stato individuato il seguente errore|sono stati individuati i seguenti errori}}:",
+ "validator_warning_parameters": "Nella tua sintassi {{PLURAL:$1|c'è un errore|ci sono errori}}.",
+ "validator-warning-adittional-errors": "... e {{PLURAL:$1|un altro problema|altri problemi}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Il valore \"$1\" è stato omesso|I valori \"$1\" sono stati omessi}}.",
+ "validator-error-problem": "C'era un problema con il parametro $1.",
+ "validator_error_unknown_argument": "$1 non è un parametro valido.",
+ "validator_error_required_missing": "Il parametro richiesto $1 non è stato fornito.",
+ "validator-error-override-argument": "Tentativo di sovrascrivere il parametro $1 (valore: $2) con il valore \"$3\"",
+ "validator-type-string": "testo",
+ "validator-type-integer": "numero intero",
+ "validator-type-float": "numero",
+ "validator-type-boolean": "sì/no",
+ "validator-type-char": "carattere",
+ "validator-type-dimension": "numero e unità di misura",
+ "validator-type-title": "titolo",
+ "validator-type-string-list": "elenco dei testi",
+ "validator-type-integer-list": "elenco di numeri interi",
+ "validator-type-float-list": "elenco dei numeri",
+ "validator-type-boolean-list": "elenco di sì/no",
+ "validator-type-char-list": "elenco dei caratteri",
+ "validator-type-title-list": "elenco dei titoli",
+ "validator-listerrors-errors": "Errori",
+ "validator-listerrors-minor": "Minore",
+ "validator-listerrors-low": "Bassa",
+ "validator-listerrors-normal": "Normale",
+ "validator-listerrors-high": "Alta",
+ "validator-listerrors-fatal": "Fatale",
+ "validator-listerrors-description": "Elenca gli errori (e gli avvisi) che si sono verificati negli hook del parser aggiunti tramite Validator.\nVengono elencati solo per gli hook del parser aggiunti sopra l'inserimento di listerrors;\nmetti listerrors alla fine o in prossimità della parte inferiore della pagina per ottenere tutti gli errori.",
+ "validator-listerrors-par-minseverity": "Il livello minimo di gravità di un problema per poter essere elencato.",
+ "validator-describe-description": "Genera la documentazione per uno o più hook del parser definito tramite Validator.",
+ "validator-describe-notfound": "Non c'è alcun hook del parser che gestisce \"$1\".",
+ "validator-describe-descriptionmsg": "'''Descrizione''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias}}''': $1",
+ "validator-describe-parserfunction": "Implementato solo come funzione parser.",
+ "validator-describe-tagextension": "Implementato solo come tag di estensione.",
+ "validator-describe-bothhooks": "Implementato come sia funzione parser che come tag di estensione.",
+ "validator-describe-par-hooks": "L'hook del parser di cui visualizzare la documentazione.",
+ "validator-describe-par-pre": "Consente di ottenere il wikitesto attuale per la documentazione, senza che sia stato effettuato il rendering della pagina.",
+ "validator-describe-par-language": "La lingua in cui visualizzare la descrizione",
+ "validator-describe-listtype": "Elenco di elementi di tipo $1",
+ "validator-describe-empty": "vuota",
+ "validator-describe-required": "obbligatorio",
+ "validator-describe-header-parameter": "Parametro",
+ "validator-describe-header-aliases": "Alias",
+ "validator-describe-header-type": "Tipo",
+ "validator-describe-header-default": "Predefinito",
+ "validator-describe-header-description": "Descrizione",
+ "validator-describe-parameters": "Parametri",
+ "validator-describe-syntax": "Sintassi",
+ "validator-describe-tagmin": "Ttag di estensione con solo i parametri obbligatori.",
+ "validator-describe-tagmax": "Ttag di estensione con tutti i parametri.",
+ "validator-describe-tagdefault": "Ttag di estensione con tutti i parametri utilizzando la notazione per i parametri predefinita.",
+ "validator-describe-pfmin": "Funzione parser con solo i parametri obbligatori.",
+ "validator-describe-pfmax": "Funzione parser con tutti i parametri.",
+ "validator-describe-pfdefault": "Funzione parser con tutti i parametri utilizzando la notazione per i parametri predefinita.",
+ "validator-describe-autogen": "Il contenuto di questa sezione è stata generata automaticamente dal hook del parser \"describe\" dell'estensione Validator.",
+ "validator_error_empty_argument": "Il parametro $1 non può avere un valore vuoto.",
+ "validator_error_must_be_number": "Il parametro $1 può essere solo un numero.",
+ "validator_error_must_be_integer": "Il parametro $1 può essere solo un intero.",
+ "validator_error_must_be_title": "Il parametro $1 può essere solo un nome valido di una pagina wiki.",
+ "validator_error_must_be_existing_title": "Il parametro $1 può essere solo un nome di una pagina wiki esistente.",
+ "validator-error-must-be-float": "Il parametro $1 può essere solo un numero decimale.",
+ "validator_error_invalid_range": "Il parametro $1 deve essere compreso tra $2 e $3.",
+ "validator-error-invalid-regex": "Il parametro $1 deve corrispondere a questa espressione regolare: $2.",
+ "validator-error-invalid-length": "Il parametro $1 deve avere una lunghezza di $2.",
+ "validator-error-invalid-length-range": "Il parametro $1 deve avere una lunghezza compresa tra $2 e $3.",
+ "validator_error_invalid_argument": "Il valore $1 non è valido per il parametro $2.",
+ "validator_list_error_empty_argument": "Il parametro $1 non accetta valori vuoti.",
+ "validator_list_error_must_be_number": "Il parametro $1 può contenere solo numeri.",
+ "validator_list_error_must_be_integer": "Il parametro $1 può contenere solo numeri interi.",
+ "validator_list_error_must_be_title": "Il parametro $1 può contenere solo un nome valido di una pagina wiki.",
+ "validator_list_error_must_be_existing_title": "Il parametro $1 può contenere solo un nome di una pagina wiki esistente.",
+ "validator-list-error-must-be-float": "Il parametro $1 può contenere solo numeri decimali.",
+ "validator_list_error_invalid_range": "Tutti i valori del parametro $1 devono essere compresi tra $2 e $3.",
+ "validator-list-error-invalid-regex": "Tutti i valori del parametro $1 devono corrispondere a questa espressione regolare: $2.",
+ "validator_list_error_invalid_argument": "Uno o più valori del parametro $1 non sono validi.",
+ "validator-list-error-accepts-only": "Uno o più valori del parametro $1 non sono validi. {{PLURAL:$3|Il valore accettato è|I valori accettati sono}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Uno o più valori del parametro $1 non sono validi. {{PLURAL:$3|Il valore accettato è|I valori accettati sono}}: $2 (e $4 {{PLURAL:$4|valore omesso|valori omessi}}).",
+ "validator_error_accepts_only": "Il valore \"$4\" non è valido per il parametro $1. Accetta solo {{PLURAL:$3|questo valore|questi valori}}: $2.",
+ "validator-error-accepts-only-omitted": "Il valore \"$2\" non è valido per il parametro $1. {{PLURAL:$5|Il valore accettato è|I valori accettati sono}}: $3 (e $4 {{PLURAL:$4|valore omesso|valori omessi}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Il valore|I valori}} $1 {{PLURAL:$2|è stato omesso|sono stati omessi}}.",
+ "validator-message-nodesc": "Nessuna descrizione fornita"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ja.json b/www/wiki/extensions/Validator/i18n/ja.json
new file mode 100644
index 00000000..135ad822
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ja.json
@@ -0,0 +1,82 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aotake",
+ "Fryed-peach",
+ "Marine-Blue",
+ "Shirayuki",
+ "Whym",
+ "Yanajin66"
+ ]
+ },
+ "validator-desc": "宣言的引数処理ライブラリ",
+ "validator-warning": "警告: $1",
+ "validator-error": "エラー: $1",
+ "validator-fatal-error": "致命的なエラー: $1",
+ "validator_error_parameters": "以下の構文{{PLURAL:$1|エラー}}を検出しました:",
+ "validator_warning_parameters": "構文{{PLURAL:$1|エラー}}があります。",
+ "validator-warning-adittional-errors": "...と{{PLURAL:$1|​&#32;1 件の問題点|複数の問題点}}。",
+ "validator-error-omitted": "{{PLURAL:$2|値「$1」}}を省略しました。",
+ "validator-error-problem": "引数 $1 に問題点がありました。",
+ "validator_error_unknown_argument": "$1 は有効な引数ではありません。",
+ "validator_error_required_missing": "必須の引数「$1」が指定されていません。",
+ "validator-error-override-argument": "引数 $1 (値: $2) を値「$3」で上書きしようとしました",
+ "validator-type-string": "テキスト",
+ "validator-type-float": "数値",
+ "validator-type-boolean": "はい/いいえ",
+ "validator-type-char": "文字",
+ "validator-type-title": "ページ名",
+ "validator-listerrors-errors": "エラー",
+ "validator-listerrors-minor": "非常に軽度",
+ "validator-listerrors-low": "軽度",
+ "validator-listerrors-normal": "普通",
+ "validator-listerrors-high": "重大",
+ "validator-listerrors-fatal": "非常に重大",
+ "validator-describe-notfound": "「$1」を処理できるパーサーフックはありません。",
+ "validator-describe-descriptionmsg": "'''説明''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|別名}}''': $1",
+ "validator-describe-parserfunction": "パーサー関数としてのみ実装されています。",
+ "validator-describe-tagextension": "タグ拡張機能としてのみ実装されています。",
+ "validator-describe-bothhooks": "パーサー関数およびタグ拡張機能の両方として実装されています。",
+ "validator-describe-par-hooks": "説明文を表示するパーサーフックです。",
+ "validator-describe-par-language": "説明を表示する言語",
+ "validator-describe-empty": "空",
+ "validator-describe-required": "必須",
+ "validator-describe-header-parameter": "引数",
+ "validator-describe-header-aliases": "別名",
+ "validator-describe-header-type": "種類",
+ "validator-describe-header-default": "既定",
+ "validator-describe-header-description": "説明",
+ "validator-describe-parameters": "引数",
+ "validator-describe-syntax": "構文",
+ "validator-describe-tagmin": "必須の引数のみを持つタグ拡張機能です。",
+ "validator-describe-tagmax": "すべての引数を持つタグ拡張機能です。",
+ "validator-describe-pfmin": "必須の引数のみを持つパーサー関数です。",
+ "validator-describe-pfmax": "すべての引数を持つパーサー関数です。",
+ "validator_error_empty_argument": "引数 $1 は空の値を取ることはできません。",
+ "validator_error_must_be_number": "引数 $1 には数値のみを指定できます。",
+ "validator_error_must_be_integer": "引数 $1 には整数のみを指定できます。",
+ "validator_error_must_be_title": "引数 $1 には有効なウィキ ページ名のみを指定できます。",
+ "validator_error_must_be_existing_title": "引数 $1 には既存のウィキ ページ名のみを指定できます。",
+ "validator-error-must-be-float": "引数 $1 には浮動小数点数のみ指定できます。",
+ "validator_error_invalid_range": "引数 $1 は $2 から $3 の間の値である必要があります。",
+ "validator-error-invalid-regex": "引数 $1 はこの正規表現に一致する必要があります: $2",
+ "validator-error-invalid-length": "引数 $1 は長さが $2 である必要があります。",
+ "validator-error-invalid-length-range": "引数 $1 は長さが $2 から $3 までの範囲である必要があります。",
+ "validator_error_invalid_argument": "引数 $2 の値 $1 は無効です。",
+ "validator_list_error_empty_argument": "引数 $1 は空の値を取りません。",
+ "validator_list_error_must_be_number": "引数 $1 には数値のみを指定できます。",
+ "validator_list_error_must_be_integer": "引数 $1 には整数のみを指定できます。",
+ "validator_list_error_must_be_title": "引数 $1 には有効なウィキ ページ名 (複数) のみを指定できます。",
+ "validator_list_error_must_be_existing_title": "引数 $1 には既存のウィキ ページ名 (複数) のみを指定できます。",
+ "validator-list-error-must-be-float": "引数 $1 には浮動小数点数のみを指定できます。",
+ "validator_list_error_invalid_range": "引数 $1 の値はすべて $2 と $3 の間のものでなくてはなりません。",
+ "validator-list-error-invalid-regex": "引数 $1 のすべての値は以下の正規表現と一致する必要があります: $2",
+ "validator_list_error_invalid_argument": "引数 $1 に 1 つ以上の無効な値があります。",
+ "validator-list-error-accepts-only": "引数 $1 に 1 つ以上の無効な値があります。{{PLURAL:$3|この値|これらの値}}のみを使用できます: $2",
+ "validator-list-error-accepts-only-omitted": "引数 $1 に 1 つ以上の無効な値があります。{{PLURAL:$3|この値|これらの値}}のみを使用できます: $2 (と省略された $4 の{{PLURAL:$4|値}})",
+ "validator_error_accepts_only": "引数 $1 の値「$4」は無効です。{{PLURAL:$3|この値|これらの値}}のみを使用できます: $2",
+ "validator-error-accepts-only-omitted": "引数 $1 の値「$2」は無効です。{{PLURAL:$5|この値|これらの値}}のみを使用できます: $3 (と省略された $4 の{{PLURAL:$4|値}})",
+ "validator_list_omitted": "{{PLURAL:$2|値}} $1 は省略されました。",
+ "validator-message-nodesc": "説明はありません"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ka.json b/www/wiki/extensions/Validator/i18n/ka.json
new file mode 100644
index 00000000..072e6e62
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ka.json
@@ -0,0 +1,40 @@
+{
+ "@metadata": {
+ "authors": [
+ "David1010",
+ "ITshnik"
+ ]
+ },
+ "validator-warning": "გაფრთხილება: $1",
+ "validator-error": "შეცდომა: $1",
+ "validator-fatal-error": "ფატალური შეცდომა: $1",
+ "validator_error_unknown_argument": "$1 არ არის სწორი პარამეტრი.",
+ "validator-type-string": "ტექსტი",
+ "validator-type-integer": "მთლიანი რიცხვი",
+ "validator-type-float": "ნომერი",
+ "validator-type-boolean": "დიახ/არა",
+ "validator-type-char": "სიმბოლო",
+ "validator-type-title": "სათაური",
+ "validator-type-string-list": "ტექსტების სია",
+ "validator-type-float-list": "რიცხვების სია",
+ "validator-type-boolean-list": "დიახ/არა სია",
+ "validator-type-char-list": "სიმბოლოების სია",
+ "validator-type-title-list": "სათაურების სია",
+ "validator-listerrors-errors": "შეცდომები",
+ "validator-listerrors-minor": "უმნიშვნელო",
+ "validator-listerrors-low": "დაბალი",
+ "validator-listerrors-normal": "ნორმალური",
+ "validator-listerrors-high": "მაღალი",
+ "validator-listerrors-fatal": "ფატალური",
+ "validator-describe-descriptionmsg": "'''აღწერა''': $1",
+ "validator-describe-empty": "ცარიელი",
+ "validator-describe-required": "სავალდებულოა",
+ "validator-describe-header-parameter": "პარამეტრი",
+ "validator-describe-header-aliases": "ფსევდონიმები",
+ "validator-describe-header-type": "ტიპი",
+ "validator-describe-header-default": "სტანდარტული",
+ "validator-describe-header-description": "აღწერა",
+ "validator-describe-parameters": "პარამეტრები",
+ "validator-describe-syntax": "სინტაქსი",
+ "validator_error_empty_argument": "პარამეტრი $1 არ შეუძლია ცარიელი მნიშვნელობის მიღება."
+}
diff --git a/www/wiki/extensions/Validator/i18n/ko.json b/www/wiki/extensions/Validator/i18n/ko.json
new file mode 100644
index 00000000..d4cfa424
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ko.json
@@ -0,0 +1,96 @@
+{
+ "@metadata": {
+ "authors": [
+ "Priviet",
+ "아라",
+ "Ykhwong",
+ "Revi"
+ ]
+ },
+ "validator-desc": "선언적 변수 처리 라이브러리",
+ "validator-warning": "경고: $1",
+ "validator-error": "오류: $1",
+ "validator-fatal-error": "치명적인 오류: $1",
+ "validator_error_parameters": "문법에서 지정한 다음 {{PLURAL:$1|오류가 있습니다}}:",
+ "validator_warning_parameters": "문법에서 {{PLURAL:$1|오류가 있습니다}}.",
+ "validator-warning-adittional-errors": "... 그리고 {{PLURAL:$1|하나의 많은 문제|여러 많은 문제}}가 있습니다.",
+ "validator-error-omitted": "{{PLURAL:$2|\"$1\" 값}}은 생략합니다.",
+ "validator-error-problem": "$1 변수에 문제가 있습니다.",
+ "validator_error_unknown_argument": "$1은(는) 올바른 변수가 아닙니다.",
+ "validator_error_required_missing": "\"$1\" 필수 변수를 제공하지 않았습니다.",
+ "validator-error-override-argument": "\"$3\" 값으로 $1 변수(값: $2)를 무시하려 했습니다",
+ "validator-type-string": "텍스트",
+ "validator-type-integer": "정수",
+ "validator-type-float": "숫자",
+ "validator-type-boolean": "예/아니오",
+ "validator-type-char": "글자",
+ "validator-type-dimension": "수치 단위",
+ "validator-type-title": "제목",
+ "validator-type-string-list": "텍스트 목록",
+ "validator-type-integer-list": "정수 목록",
+ "validator-type-float-list": "숫자 목록",
+ "validator-type-boolean-list": "예/아니오 목록",
+ "validator-type-char-list": "글자 목록",
+ "validator-type-title-list": "제목 목록",
+ "validator-listerrors-errors": "오류",
+ "validator-listerrors-minor": "사소",
+ "validator-listerrors-low": "낮음",
+ "validator-listerrors-normal": "보통",
+ "validator-listerrors-high": "높음",
+ "validator-listerrors-fatal": "심각",
+ "validator-listerrors-description": "변수기를 통해 추가한 파서 훅에서 발생한 오류(와 경고) 목록입니다.\n파서 훅에 대한 목록만 오류 목록이 삽입하는 곳에 추가됩니다.\n모든 오류를 얻으려면 문서 하단이나 가까운 오류 목록에 넣으십시오.",
+ "validator-listerrors-par-minseverity": "이에 대한 문제의 최소 심각도를 나타내야 합니다.",
+ "validator-describe-description": "변수기를 통해 지정한 하나 이상의 파서 훅에 대한 문서를 생성합니다.",
+ "validator-describe-notfound": "\"$1\" 핸들에는 파서 훅이 없습니다.",
+ "validator-describe-descriptionmsg": "'''설명''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|별명}}''': $1",
+ "validator-describe-parserfunction": "파서 함수로만 구현합니다.",
+ "validator-describe-tagextension": "태그 확장 기능으로만 구현합니다.",
+ "validator-describe-bothhooks": "파서 함수와 태그 확장 기능 모두로 구현합니다.",
+ "validator-describe-par-hooks": "파서는 문서를 보여주는 데에 대해서 연결합니다.",
+ "validator-describe-par-pre": "문서에 렌더링되지 않고 문서에 대한 실제 위키텍스트를 얻도록 허용합니다.",
+ "validator-describe-par-language": "설명을 보여줄 언어",
+ "validator-describe-listtype": "$1 항목의 목록",
+ "validator-describe-empty": "비었음",
+ "validator-describe-required": "필수",
+ "validator-describe-header-parameter": "변수",
+ "validator-describe-header-aliases": "별명",
+ "validator-describe-header-type": "종류",
+ "validator-describe-header-default": "기본값",
+ "validator-describe-header-description": "설명",
+ "validator-describe-parameters": "변수",
+ "validator-describe-syntax": "문법",
+ "validator-describe-tagmin": "필요한 변수에만 태그 확장 기능.",
+ "validator-describe-tagmax": "모든 변수와 태그 확장 기능.",
+ "validator-describe-tagdefault": "기본 변수 표기을 사용하여 모든 변수와 태그 확장 기능.",
+ "validator-describe-pfmin": "필요한 변수에만 파서 함수.",
+ "validator-describe-pfmax": "모든 변수와 파서 함수.",
+ "validator-describe-pfdefault": "기본 변수 표기을 사용하여 모든 변수와 파서 함수.",
+ "validator-describe-autogen": "이 부분의 내용은 변수기 확장 기능의 \"설명\" 파서 훅에 의해 자동으로 만들었습니다.",
+ "validator_error_empty_argument": "$1 변수는 빈 값을 가질 수 없습니다.",
+ "validator_error_must_be_number": "$1 변수만 숫자가 될 수 있습니다.",
+ "validator_error_must_be_integer": "$1 변수만 정수가 될 수 있습니다.",
+ "validator_error_must_be_title": "$1 변수만 유효한 위키 문서 이름이 될 수 있습니다.",
+ "validator_error_must_be_existing_title": "$1 변수만 기존 위키 문서 이름이 될 수 있습니다.",
+ "validator-error-must-be-float": "$1 변수만 부동 소수점 숫자가 될 수 있습니다.",
+ "validator_error_invalid_range": "$1 변수는 $2와(과) $3 사이여야 합니다.",
+ "validator-error-invalid-regex": "$1 변수는 이 정규 표현식과 일치해야 합니다: $2.",
+ "validator-error-invalid-length": "$1 변수는 $2의 길이를 가져야 합니다.",
+ "validator-error-invalid-length-range": "$1 변수는 $2와(과) $3 사이의 길이를 가져야 합니다.",
+ "validator_error_invalid_argument": "$1 값은 $2 변수에 유효하지 않습니다.",
+ "validator_list_error_empty_argument": "$1 변수는 빈 값을 허용하지 않습니다.",
+ "validator_list_error_must_be_number": "$1 변수는 숫자만 포함할 수 있습니다.",
+ "validator_list_error_must_be_integer": "$1 변수는 정수만 포함할 수 있습니다.",
+ "validator_list_error_must_be_title": "$1 변수는 유효한 위키 문서 이름만 포함할 수 있습니다.",
+ "validator_list_error_must_be_existing_title": "$1 변수는 기존 위키 문서 이름만 포함할 수 있습니다.",
+ "validator-list-error-must-be-float": "$1 변수는 부동 소수점 숫자만 포함할 수 있습니다.",
+ "validator_list_error_invalid_range": "$1 변수의 모든 값은 $2와(과) $3 사이여야 합니다.",
+ "validator-list-error-invalid-regex": "$1 변수의 모든 값은 이 정규 표현식과 일치해야 합니다: $2.",
+ "validator_list_error_invalid_argument": "$1 변수에 대해 하나 이상의 값이 잘못되었습니다.",
+ "validator-list-error-accepts-only": "$1 변수에 대해 하나 이상의 값이 잘못되었습니다. {{PLURAL:$3|이 값}}만 승인합니다: $2.",
+ "validator-list-error-accepts-only-omitted": "$1 변수에 대해 하나 이상의 값이 잘못되었습니다. {{PLURAL:$3|이 값}}만 승인합니다: $2 (그리고 $4 값은 생략합니다).",
+ "validator_error_accepts_only": "\"$4\" 값은 $1 변수에 대해 유효하지 않습니다. {{PLURAL:$3|이 값}}만 승인합니다: $2.",
+ "validator-error-accepts-only-omitted": "\"$2\" 값은 $1 변수에 대해 유효하지 않습니다. {{PLURAL:$5|이 값}}만 승인합니다: $3 (그리고 $4 값은 생략합니다).",
+ "validator_list_omitted": "$1 {{PLURAL:$2|값}}은 생략{{PLURAL:$2|합니다}}.",
+ "validator-message-nodesc": "설명을 제공하지 않았습니다"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ksh.json b/www/wiki/extensions/Validator/i18n/ksh.json
new file mode 100644
index 00000000..524be449
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ksh.json
@@ -0,0 +1,65 @@
+{
+ "@metadata": {
+ "authors": [
+ "Purodha"
+ ]
+ },
+ "validator-desc": "{{int:validator_name}} brängk eine eijfache Wääsch, der Parrammeetere fun Paaser-Fungkßjohne un Zohsatzprojramme ze prööve, Schtandatt-Wääte enzefööje, un Fähler ze mällde.",
+ "validator-warning": "Opjepaß: $1",
+ "validator-error": "Fähler: $1",
+ "validator-fatal-error": "'''Dä!''' $1",
+ "validator_error_parameters": "{{PLURAL:$1|Heh dä|Heh di|Keine}} Fähler {{PLURAL:$1|es|sin|es}} en Dinge Syntax opjevalle:",
+ "validator_warning_parameters": "Et {{PLURAL:$1|es ene|sin|es keine}} Fähler en Dinge Süntax.",
+ "validator-warning-adittional-errors": "…&nbsp;un {{PLURAL:$1|noch e Problehm|söns Problehme|söns kei Problehm}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Dä Wert „$1“ fählt|De Wääte „$1“ fähle|Nix fählt}}.",
+ "validator-error-problem": "Et johv e Problehm mem Parrameehter $1.",
+ "validator_error_unknown_argument": "„$1“ es keine jöltijje Parameeter.",
+ "validator_error_required_missing": "Dä Parameeter $1 moß aanjejovve sin, un fählt.",
+ "validator-error-override-argument": "Versooht, dä Parrameeter $1 (mem Wäät: $2) met „$3“ ze övverschriive.",
+ "validator-type-string": "Täx",
+ "validator-type-integer": "janze Zahl (ohne Komma!)",
+ "validator-type-float": "Zahl (met Komma)",
+ "validator-type-boolean": "Joh udder Nää",
+ "validator-type-char": "Zeische, Zeffer, Boochschtaabe,&nbsp;…",
+ "validator-type-title": "Övverschreff",
+ "validator-type-string-list": "Lėß met Täxte",
+ "validator-type-integer-list": "Lėß met janze Zahle",
+ "validator-type-float-list": "Lėß met Zahle",
+ "validator-type-boolean-list": "Lėß met Joh udder Nää",
+ "validator-type-title-list": "Leß vun Övverschreffte",
+ "validator-listerrors-errors": "Fähler",
+ "validator-listerrors-minor": "Bahl ejahl",
+ "validator-listerrors-low": "Kleineshkeit",
+ "validator-listerrors-normal": "Nommahl",
+ "validator-listerrors-high": "Huh",
+ "validator-listerrors-fatal": "Schlemm",
+ "validator-listerrors-par-minseverity": "Wi schlemm ene Fähler winnishßdens sin moß, domet_e aanjezeish weed.",
+ "validator-describe-notfound": "Et jidd_er keine Paaserhooke, dä „$1“ afhandele deiht.",
+ "validator-describe-parserfunction": "Bloß als ene Paaserfunxjuhn enjeresht.",
+ "validator-describe-listtype": "Leß met {{PLURAL:$1|einem Endraach|$1 Endrääsh|keinem Endraach}}",
+ "validator-describe-empty": "nix dren",
+ "validator-describe-required": "nüüdesch",
+ "validator-describe-header-parameter": "Parrameeter",
+ "validator-describe-header-type": "Zoot",
+ "validator-describe-header-default": "Schtandatt",
+ "validator-describe-header-description": "Beschrievong",
+ "validator-describe-parameters": "Parrameetere",
+ "validator-describe-syntax": "Süntax",
+ "validator_error_empty_argument": "Dä Parameeter $1 kann keine Wäät met nix dren hann.",
+ "validator_error_must_be_number": "Dä Parameeter $1 kann blohß en Zahl sin.",
+ "validator_error_must_be_integer": "Dä Parrameeter $1 kann bloß en jannze Zahl sin.",
+ "validator-error-must-be-float": "Dä Parameeter $1 kann blohß en Zahl met Komma sin.",
+ "validator_error_invalid_range": "Dä Parameeter $1 moß zwesche $2 un $3 sin.",
+ "validator-error-invalid-regex": "Dä Parrameeter $1 moß op dä rejolähre Ußdrok „<code>$2</code>“ paße.",
+ "validator-error-invalid-length": "Dä Parameeter $1 moß $2 Zeijshe lang sin.",
+ "validator-error-invalid-length-range": "Dä Parameeter $1 moß zwesche $2 un $3 Zeijshe lang sin.",
+ "validator_error_invalid_argument": "Däm Parameeter $2 singe Wäät es $1, dat es ävver doför nit jöltesch.",
+ "validator_list_error_empty_argument": "Dä Parameeter $1 kann nit läddesh sin.",
+ "validator_list_error_must_be_number": "Dä Parameeter $1 kann blohß Zeffere änthallde.",
+ "validator_list_error_must_be_integer": "Dä Parameeter $1 kann blohß janze Zahle änthallde.",
+ "validator-list-error-must-be-float": "Dä Parameeter $1 kann blohß Zahle met Komma dren änthallde.",
+ "validator_list_error_invalid_range": "All de Wääte vum Parameeter $1 möße zwesche $2 un $3 lijje.",
+ "validator_error_accepts_only": "„$4“ es nit ze Bruche, weil dä Parameeter $1 {{PLURAL:$3|bloß eine Wäät|bloß eine vun heh dä Wääte|keine Wäät}} han kann: $2",
+ "validator_list_omitted": "{{PLURAL:$2|Dä Wäät|De Wääte|Keine Wäät}} $1 {{PLURAL:$2|es|sen|se}} fottjelohße woode.",
+ "validator-message-nodesc": "Kein Beschrievong doh"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ku-latn.json b/www/wiki/extensions/Validator/i18n/ku-latn.json
new file mode 100644
index 00000000..f1f3d057
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ku-latn.json
@@ -0,0 +1,17 @@
+{
+ "@metadata": {
+ "authors": [
+ "George Animal"
+ ]
+ },
+ "validator-error": "Çewtî:$1",
+ "validator-type-string": "nivîs",
+ "validator-type-boolean": "erê/na",
+ "validator-type-title": "sernav",
+ "validator-listerrors-errors": "Çewtî",
+ "validator-listerrors-high": "bilind",
+ "validator-describe-empty": "vala",
+ "validator-describe-header-parameter": "Parametre",
+ "validator-describe-header-type": "Cure",
+ "validator-describe-header-description": "Danasîn"
+}
diff --git a/www/wiki/extensions/Validator/i18n/lb.json b/www/wiki/extensions/Validator/i18n/lb.json
new file mode 100644
index 00000000..a53695bc
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/lb.json
@@ -0,0 +1,79 @@
+{
+ "@metadata": {
+ "authors": [
+ "Les Meloures",
+ "Robby",
+ "Soued031"
+ ]
+ },
+ "validator-desc": "Library fir d'Behandlung vun deklarative Parameter",
+ "validator-warning": "Opgepasst: $1",
+ "validator-error": "Feeler: $1",
+ "validator-fatal-error": "Fatale Feeler: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Dëse Feeler gouf|Dës Feeler goufen}} an Ärer Syntax fonnt:",
+ "validator_warning_parameters": "Et {{PLURAL:$1|ass ee|si}} Feeler an Ärer Syntax.",
+ "validator-warning-adittional-errors": "… an {{PLURAL:$1|e weidere Sujet|weider Sujeten}}.",
+ "validator-error-omitted": "{{PLURAL:$2|De Wäert|D'Wäerter}} \"$1\" {{PLURAL:$2|gouf|goufe}} vergiess.",
+ "validator-error-problem": "Et gouf e Problem mam Parameter $1.",
+ "validator_error_unknown_argument": "$1 ass kee valbele Parameter.",
+ "validator_error_required_missing": "Den obligatoresche Parameter $1 war net derbäi.",
+ "validator-error-override-argument": "huet versicht de Parameter $1 (Wäert: $2) mam Wäert \"$3\" z'iwwerschreiwen",
+ "validator-type-string": "Text",
+ "validator-type-integer": "Ganz Zuel",
+ "validator-type-float": "Zuel",
+ "validator-type-boolean": "Jo/Neen",
+ "validator-type-char": "Zeechen",
+ "validator-type-title": "Titel",
+ "validator-type-string-list": "Lëscht vun den Texter",
+ "validator-type-float-list": "Lëscht vun Zuelen",
+ "validator-type-boolean-list": "Jo/Neen Lëscht",
+ "validator-type-title-list": "Lëscht vun Titelen",
+ "validator-listerrors-errors": "Feeler",
+ "validator-listerrors-minor": "Marginal",
+ "validator-listerrors-low": "Niddreg",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Héich",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-par-minseverity": "Déi mannste Schwieregkeet vun engem Feeler fir datt en hei gewise gëtt.",
+ "validator-describe-descriptionmsg": "'''Beschreiwung''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasen}}:''' $1",
+ "validator-describe-parserfunction": "Nëmmen als Parser-Funktioun implementéiert.",
+ "validator-describe-tagextension": "Nëmmen als Tag-Erweiderung implementéiert.",
+ "validator-describe-par-language": "D'Sprooch an där d'Beschreiwunge gewise solle ginn",
+ "validator-describe-listtype": "Lëscht mat {{PLURAL:$1|engem Element|$1 Elementer}}",
+ "validator-describe-empty": "eidel",
+ "validator-describe-required": "obligatoresch",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliasen",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Standard",
+ "validator-describe-header-description": "Beschreiwung",
+ "validator-describe-parameters": "Parameteren",
+ "validator-describe-syntax": "Syntax",
+ "validator-describe-pfmax": "Parserfonctioun mat alle Parameter.",
+ "validator_error_empty_argument": "De Parameter $1 ka keen eidele Wäert hunn.",
+ "validator_error_must_be_number": "De Parameter $1 ka just eng Zuel sinn",
+ "validator_error_must_be_integer": "De Parameter $1 ka just eng ganz Zuel sinn.",
+ "validator_error_must_be_title": "Parameter $1 kann nëmmen e valabele Wiki-Säitennumm sinn.",
+ "validator_error_must_be_existing_title": "Parameter $1 kann nëmmen e Wiki-Säitennumm sinn deen et gëtt.",
+ "validator-error-must-be-float": "Parameter $1 kann nëmmen eng Féisskommazuel sinn.",
+ "validator_error_invalid_range": "De Parameter $1 muss tëscht $2 an $3 leien.",
+ "validator-error-invalid-regex": "De Parameter $1 muss sou ausgesinn: $2",
+ "validator-error-invalid-length": "Parameter $1 muss eng Längt vu(n) $2 hunn.",
+ "validator-error-invalid-length-range": "De Parameter $1 muss eng Längt tëscht $2 an $3 hunn.",
+ "validator_error_invalid_argument": "De Wäert $1 ass net valabel fir de Parameter $2.",
+ "validator_list_error_empty_argument": "De Parameter $1 hëlt keng eidel Wäerter un.",
+ "validator_list_error_must_be_number": "Am Parameter $1 kënnen nëmmen Zuelen dra sinn.",
+ "validator_list_error_must_be_integer": "Am Parameter $1 kënnen nëmme ganz Zuele sinn.",
+ "validator_list_error_must_be_title": "Am Parameter $1 kënnen nëmme valabel Wiki-Säitennimm sinn.",
+ "validator-list-error-must-be-float": "Am Parameter $1 kënnen nëmme Kommazuelen dra sinn.",
+ "validator_list_error_invalid_range": "All Wäerter vum Parameter $1 mussen tëscht $2 an $3 leien.",
+ "validator-list-error-invalid-regex": "All Wäerter vum Parameter $1 mussen dësem regulären Ausdrock entspriechen: $2",
+ "validator_list_error_invalid_argument": "Een oder méi Wäerter fir de Parameter $1 sinn net valabel.",
+ "validator-list-error-accepts-only": "Een oder méi Wäerter vum Parameter $1 sinn net valabel.\nEn akzeptéiert nëmmen {{PLURAL:$3|dëse Wäert|dës Wäerter}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Een oder méi Wäerter fir de Parameter $1 sinn net valabel.\nEn akzeptéiert nëmmen {{PLURAL:$3|dëse Wäert|dës Wäerter}}: $2 (an {{PLURAL:$4|een ausgeloossene Wäert|$4 ausgeloosse Wäerter}}).",
+ "validator_error_accepts_only": "De Wäert $4 ass net valabel fir de Parameter $1. En akzeptéiert just {{PLURAL:$3|dëse Wäert|dës Wäerter}}: $2",
+ "validator-error-accepts-only-omitted": "De Wäert \"$2\" ass net valabel fir de Parameter $1.\nEn akzeptéiert nëmmen {{PLURAL:$5|dëse Wäert|dës Wäerter}}: $3 (an {{PLURAL:$4|een ausgeloossene Wäert|$4 ausgeloosse Wäerter}}).",
+ "validator_list_omitted": "{{PLURAL:$2|De Wäert|D'Wäerter}} $1 {{PLURAL:$2|gouf|goufe}} vergiess.",
+ "validator-message-nodesc": "Et gëtt keng Beschreiwung"
+}
diff --git a/www/wiki/extensions/Validator/i18n/lki.json b/www/wiki/extensions/Validator/i18n/lki.json
new file mode 100644
index 00000000..aead5f60
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/lki.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Lakzon"
+ ]
+ },
+ "validator-describe-descriptionmsg": "'''شرح''': $1",
+ "validator-describe-header-description": "تشریح"
+}
diff --git a/www/wiki/extensions/Validator/i18n/lt.json b/www/wiki/extensions/Validator/i18n/lt.json
new file mode 100644
index 00000000..c6250298
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/lt.json
@@ -0,0 +1,59 @@
+{
+ "@metadata": {
+ "authors": [
+ "Eitvys200"
+ ]
+ },
+ "validator-warning": "Įspėjimas: $1",
+ "validator-error": "Klaida: $1",
+ "validator-fatal-error": "Lemtinga klaida: $1",
+ "validator-error-problem": "Kilo problema su parametru $1.",
+ "validator_error_unknown_argument": "$1 nėra galimas parametras.",
+ "validator_error_required_missing": "Reikalingas parametras „$1“ nepateiktas.",
+ "validator-type-string": "tekstas",
+ "validator-type-integer": "visas skaičius",
+ "validator-type-float": "skaičius",
+ "validator-type-boolean": "taip/ne",
+ "validator-type-char": "simbolis",
+ "validator-type-dimension": "skaičiaus ir matavimo vienetas",
+ "validator-type-title": "pavadinimas",
+ "validator-type-string-list": "tekstų sąrašas",
+ "validator-type-integer-list": "sveikųjų skaičių sąrašas",
+ "validator-type-float-list": "skaičių sąrašas",
+ "validator-type-boolean-list": "taip/ne sąrašas",
+ "validator-type-title-list": "pavadinimų sąrašas",
+ "validator-listerrors-errors": "Klaidos",
+ "validator-listerrors-low": "Žemas",
+ "validator-listerrors-normal": "Normalus",
+ "validator-listerrors-high": "Aukštas",
+ "validator-listerrors-fatal": "Lemtingas",
+ "validator-describe-listtype": "$1 objektų sąrašas",
+ "validator-describe-empty": "tuščia",
+ "validator-describe-required": "privalomas",
+ "validator-describe-header-parameter": "Parametras",
+ "validator-describe-header-aliases": "Alternatyvūs vardai",
+ "validator-describe-header-type": "Tipas",
+ "validator-describe-header-default": "Numatytasis",
+ "validator-describe-header-description": "Aprašymas",
+ "validator-describe-parameters": "Parametrai",
+ "validator-describe-syntax": "Sintaksė",
+ "validator-describe-tagmin": "Žymės plėtinys tik su privalomais parametrais.",
+ "validator-describe-tagmax": "Žymės plėtinys su visais parametrais.",
+ "validator_error_empty_argument": "Parametras $1 negali turėti tuščios vertės.",
+ "validator_error_must_be_number": "Parametras $1 gali būti tik skaičius",
+ "validator_error_must_be_integer": "Parametras $1 gali būti tik sveikasis skaičius.",
+ "validator_error_must_be_title": "Parametras $1 gali būti tik galiojantis viki puslapio pavadinimas.",
+ "validator_error_must_be_existing_title": "Parametras $1 būti tik egzistuojantis viki puslapio pavadinimas.",
+ "validator_error_invalid_range": "Parametras $1 turi būti tarp $2 ir $3.",
+ "validator-error-invalid-regex": "Parametras $1 turi atitikti įprastą išraišką: $2.",
+ "validator-error-invalid-length": "Parametras $1 turi būti $2 ilgio.",
+ "validator-error-invalid-length-range": "Parametras $1 turi būti tarp $2 ir $3 ilgio.",
+ "validator_error_invalid_argument": "$1 vertė nėra galimas $2 parametras.",
+ "validator_list_error_empty_argument": "Parametras $1 nepriima tuščių reikšmių.",
+ "validator_list_error_must_be_number": "Parametre $1 gali būti tik skaičiai.",
+ "validator_list_error_must_be_integer": "Parametre $1 gali būti tik sveikieji skaičiai.",
+ "validator_list_error_must_be_title": "Parametre $1 gali būti tik galiojantys viki puslapio pavadinimai.",
+ "validator_list_error_must_be_existing_title": "Parametre $1 gali būti tik egzistuojantys viki puslapio pavadinimai.",
+ "validator_list_error_invalid_range": "Visos parametro $1 reikšmės turi būti tarp $2 ir $3.",
+ "validator-message-nodesc": "Nepateiktas joks aprašymas"
+}
diff --git a/www/wiki/extensions/Validator/i18n/lv.json b/www/wiki/extensions/Validator/i18n/lv.json
new file mode 100644
index 00000000..c74a9fd6
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/lv.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "GreenZeb"
+ ]
+ },
+ "validator-listerrors-errors": "Kļūdas",
+ "validator-listerrors-minor": "Maznozīmīgas",
+ "validator-listerrors-fatal": "Fatālas"
+}
diff --git a/www/wiki/extensions/Validator/i18n/mk.json b/www/wiki/extensions/Validator/i18n/mk.json
new file mode 100644
index 00000000..5757b609
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/mk.json
@@ -0,0 +1,95 @@
+{
+ "@metadata": {
+ "authors": [
+ "Bjankuloski06",
+ "McDutchie"
+ ]
+ },
+ "validator-desc": "Декларативна библиотека за обработка на параметри",
+ "validator-warning": "Предупредување: $1",
+ "validator-error": "Грешка: $1",
+ "validator-fatal-error": "Кобна грешка: $1",
+ "validator_error_parameters": "Во вашата синтакса {{PLURAL:$1|е откриена следнава грешка|се откриени следниве грешки}}:",
+ "validator_warning_parameters": "Имате {{PLURAL:$1|грешка|грешки}} во синтаксата.",
+ "validator-warning-adittional-errors": "... и {{PLURAL:$1|уште еден проблем|повеќе други проблеми}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Изоставена е вредноста „$1“|Изоставени се вредностите „$1“}}.",
+ "validator-error-problem": "Се појави проблем со параметарот $1.",
+ "validator_error_unknown_argument": "$1 не е важечки параметар.",
+ "validator_error_required_missing": "Бараниот параметар $1 не е наведен.",
+ "validator-error-override-argument": "Се обидовте да презапишете врз параметарот $1 (вредност: $2) со вредност „$3“",
+ "validator-type-string": "текст",
+ "validator-type-integer": "цел број",
+ "validator-type-float": "број",
+ "validator-type-boolean": "да/не",
+ "validator-type-char": "знак",
+ "validator-type-dimension": "број и димензионална единица",
+ "validator-type-title": "наслов",
+ "validator-type-string-list": "список на текстови",
+ "validator-type-integer-list": "список на цели броеви",
+ "validator-type-float-list": "список на броеви",
+ "validator-type-boolean-list": "список на да/не",
+ "validator-type-char-list": "список на знаци",
+ "validator-type-title-list": "списо на наслови",
+ "validator-listerrors-errors": "Грешки",
+ "validator-listerrors-severity-message": "($1) $2",
+ "validator-listerrors-minor": "Ситни",
+ "validator-listerrors-low": "Малку",
+ "validator-listerrors-normal": "Нормално",
+ "validator-listerrors-high": "Многу",
+ "validator-listerrors-fatal": "Кобна",
+ "validator-listerrors-description": "Ги наведува грешките (и предупредувањата) што се јавиле кај расчленувачките пресретници додадени преку Потврдувачот (Validator).\nГи наведува само расчленувачките пресретници додадени погоре каде е вметнато „listerrors“;\nставете го „listerrors“ на или близу дното на страницата за да ви се прикажат сите грешки.",
+ "validator-listerrors-par-minseverity": "Минималната сериозност на проблемот за да биде наведен.",
+ "validator-describe-description": "Создава документација за една или повеќе расчленувачки пресретници определени преку Потврдувачот.",
+ "validator-describe-notfound": "Нема расчленувачки пресретник што работи со „$1“.",
+ "validator-describe-descriptionmsg": "'''Опис''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Истозначник|Истозначници}}''': $1",
+ "validator-describe-parserfunction": "Се применува само во својство на расчленувачка функција.",
+ "validator-describe-tagextension": "Се применува само во својство на додаток за означување.",
+ "validator-describe-bothhooks": "Се применува во својство на расчленувачка функција и додаток за означување (обете).",
+ "validator-describe-par-hooks": "Расчленувачките пресретници за кои сакате да се прикаже документација.",
+ "validator-describe-par-pre": "Ви овозможува да го добиете самиот викитекст за документацијата, без да се испише на страницата",
+ "validator-describe-par-language": "На кој јазик да се прикажуваат описите",
+ "validator-describe-listtype": "Список на $1 ставки",
+ "validator-describe-empty": "празно",
+ "validator-describe-required": "задолжително",
+ "validator-describe-header-parameter": "Параметар",
+ "validator-describe-header-aliases": "Истозначници",
+ "validator-describe-header-type": "Вид",
+ "validator-describe-header-default": "По основно",
+ "validator-describe-header-description": "Опис",
+ "validator-describe-parameters": "Параметри",
+ "validator-describe-syntax": "Синтакса",
+ "validator-describe-tagmin": "Додаток за означување само со задолжителните параметри.",
+ "validator-describe-tagmax": "Додаток за означување со сите параметри.",
+ "validator-describe-tagdefault": "Додаток за означување кајшто сите параметри ја користат стандардната параметарска нотација.",
+ "validator-describe-pfmin": "Расчленувачка функција само со задолжителните параметри.",
+ "validator-describe-pfmax": "Расчленувачка функција со сите параметри.",
+ "validator-describe-pfdefault": "Расчленувачка функција кајшто сите параметри ја користат стандардната параметарска нотација.",
+ "validator-describe-autogen": "Содржината на овој поднаслов е создадена автоматски од расчленувачкиот пресретник „describe“ на додатокот Потврдувач (Validator).",
+ "validator_error_empty_argument": "Параметарот $1 не може да има празна вредност.",
+ "validator_error_must_be_number": "Параметарот $1 може да биде само број.",
+ "validator_error_must_be_integer": "Параметарот $1 може да биде само цел број.",
+ "validator_error_must_be_title": "Параметарот $1 може да биде само важечко име на викистраница.",
+ "validator_error_must_be_existing_title": "Параметарот $1 може да биде само постоечко име на викистраница.",
+ "validator-error-must-be-float": "Параметарот $1 може да биде само број со подвижна точка.",
+ "validator_error_invalid_range": "Параметарот $1 мора да изнесува помеѓу $2 и $3.",
+ "validator-error-invalid-regex": "Параметарот $1 мора да се совпаѓа со следниов регуларен израз: $2.",
+ "validator-error-invalid-length": "Параметарот $1 мора да има должина од $2.",
+ "validator-error-invalid-length-range": "Должината на параметарот параметарот $1 мора да изнесува помеѓу $2 и $3.",
+ "validator_error_invalid_argument": "Вредноста $1 е неважечка за параметарот $2.",
+ "validator_list_error_empty_argument": "Параметарот $1 не прифаќа празни вредности.",
+ "validator_list_error_must_be_number": "Параметарот $1 може да содржи само бројки.",
+ "validator_list_error_must_be_integer": "Параметарот $1 може да содржи само цели броеви.",
+ "validator_list_error_must_be_title": "Параметарот $1 може да содржи само важечки имиња на викистраници.",
+ "validator_list_error_must_be_existing_title": "Параметарот $1 може да содржи само постоечки имиња на викистраници.",
+ "validator-list-error-must-be-float": "Параметарот $1 може да содржи само подвижни бинарни точки.",
+ "validator_list_error_invalid_range": "Сите вредности на параметарот $1 мора да бидат помеѓу $2 и $3.",
+ "validator-list-error-invalid-regex": "Сите вредности на параметарот $1 мора да се совпаднат со следниов регуларен израз: $2.",
+ "validator_list_error_invalid_argument": "Една или повеќе вредности на параметарот $1 се неважечки.",
+ "validator-list-error-accepts-only": "Параметарот $1 има една или повеќе неважечки вредности.\nСе {{PLURAL:$3|прифаќа само следнава вредност|прифаќаат само следниве вредности}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Параметарот $1 има една или повеќе неважечки вредности.\nСе {{PLURAL:$3|прифаќа само следнава вредност|прифаќаат само следниве вредности}}: $2 (и $4 {{PLURAL:$4|изоставена вредност|изоставени вредности}}).",
+ "validator_error_accepts_only": "Вредноста „$4“ е неважечка за параметарот $1. Се {{PLURAL:$3|прифаќа само следнава вредност|прифаќаат само следниве вредности}}: $2.",
+ "validator-error-accepts-only-omitted": "Вредноста „$2“ не е важечка за параметарот $1. Се прифаќаат само следниве вредности: $3 (и $4 изоставени вредности).",
+ "validator_list_omitted": "{{PLURAL:$2|Вредноста|Вредностите}} $1 {{PLURAL:$2|беше испуштена|беа испуштени}}.",
+ "validator-message-nodesc": "Нема наведено опис"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ms.json b/www/wiki/extensions/Validator/i18n/ms.json
new file mode 100644
index 00000000..45ce2155
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ms.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Anakmalaysia"
+ ]
+ },
+ "validator-describe-descriptionmsg": "'''Keterangan''': $1",
+ "validator-describe-empty": "kosong",
+ "validator-describe-required": "wajib",
+ "validator-describe-header-default": "Asali"
+}
diff --git a/www/wiki/extensions/Validator/i18n/nb.json b/www/wiki/extensions/Validator/i18n/nb.json
new file mode 100644
index 00000000..0420f720
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/nb.json
@@ -0,0 +1,81 @@
+{
+ "@metadata": {
+ "authors": [
+ "Event",
+ "Nghtwlkr"
+ ]
+ },
+ "validator-desc": "Gir generisk støtte for parameterhåndtering fra andre utvidelser",
+ "validator-warning": "Advarsel: $1",
+ "validator-error": "Feil: $1",
+ "validator-fatal-error": "Kritisk feil: $1",
+ "validator_error_parameters": "Følgende {{PLURAL:$1|feil|feil}} har blitt oppdaget i syntaksen din:",
+ "validator_warning_parameters": "Det er {{PLURAL:$1|én feil|flere feil}} i syntaksen din.",
+ "validator-warning-adittional-errors": "... og {{PLURAL:$1|ett problem til|flere problem}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Verdien|Verdiene}} «$1» har blitt utelatt.",
+ "validator-error-problem": "Det var et problem med parameter $1.",
+ "validator_error_unknown_argument": "$1 er ikke en gyldig parameter.",
+ "validator_error_required_missing": "Den nødvendige parameteren «$1» er ikke angitt.",
+ "validator-error-override-argument": "Prøvde å overkjøre parameter $1 (verdi: $2) med verdien «$3»",
+ "validator-type-string": "tekst",
+ "validator-type-integer": "heltall",
+ "validator-type-float": "tall",
+ "validator-type-boolean": "ja/nei",
+ "validator-type-char": "tegn",
+ "validator-listerrors-errors": "Feil",
+ "validator-listerrors-minor": "Mindre",
+ "validator-listerrors-low": "Lav",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Høy",
+ "validator-listerrors-fatal": "Kritisk",
+ "validator-listerrors-description": "Lister opp feil (og advarsler) som oppsto i \"parser hooks\" via Validator.\nLister bare opp for \"parser hooks\" lagt til over der \"listerrors\" er satt inn;\nplasser \"listerrors\" på eller nær bunnen av siden for å få frem alle feilene.",
+ "validator-listerrors-par-minseverity": "Minimum alvorlighetsgrad for at en sak skal listes opp.",
+ "validator-describe-description": "Genererer dokumentasjon for en eller flere \"parser hooks\" definert via Validator.",
+ "validator-describe-notfound": "Det finnes ingen \"parser hook\" som håndterer \"$1\".",
+ "validator-describe-descriptionmsg": "''Beskrivelse''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliaser}}''': $1",
+ "validator-describe-parserfunction": "Bare implementert som en parser-funksjon.",
+ "validator-describe-tagextension": "Bare implementert som en tag-utvidelse.",
+ "validator-describe-bothhooks": "Implementert både som en parser-funksjon og en tag-utvidelse.",
+ "validator-describe-par-hooks": "\"Parser hooks\" som brukes for å angi dokumentasjon.",
+ "validator-describe-par-pre": "Tillater deg å få den faktiske wikiteksten for dokumentasjonen uten at den blir gjengitt på siden.",
+ "validator-describe-par-language": "Språket som brukes for beskrivelsene",
+ "validator-describe-listtype": "Liste av $1 elementer",
+ "validator-describe-empty": "tom",
+ "validator-describe-required": "påkrevet",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliaser",
+ "validator-describe-header-type": "Type",
+ "validator-describe-header-default": "Standard",
+ "validator-describe-header-description": "Beskrivelse",
+ "validator-describe-parameters": "Parametre",
+ "validator-describe-syntax": "Syntaks",
+ "validator-describe-tagmin": "Tag-utvidelse bare med de påkrevde parametrene.",
+ "validator-describe-tagmax": "Tag-utvidelse med alle parametrene.",
+ "validator-describe-tagdefault": "Tag-utvidelse med alle parametrene som bruker standard parameternotasjon.",
+ "validator-describe-pfmin": "Parser-funksjon bare med de påkrevde parametrene.",
+ "validator-describe-pfmax": "Parser-funksjon med alle parametrene.",
+ "validator-describe-pfdefault": "Parser-funksjon med alle parametrene som bruker standard parameternotasjon.",
+ "validator-describe-autogen": "Innholdet i dette avsnittet ble autogenerert av \"describe parser hook\" fra Validator-utvidelsen.",
+ "validator_error_empty_argument": "Parameter $1 kan ikke ha en tom verdi.",
+ "validator_error_must_be_number": "Parameter $1 må være et tall.",
+ "validator_error_must_be_integer": "Parameter $1 må være et heltall.",
+ "validator-error-must-be-float": "Parameter $1 må være et flyttall.",
+ "validator_error_invalid_range": "Parameter $1 må være mellom $2 og $3.",
+ "validator-error-invalid-regex": "Parameter $1 må samsvare med dette regulæruttrykket: $2.",
+ "validator-error-invalid-length": "Parameter $1 må ha en lengde på $2.",
+ "validator-error-invalid-length-range": "Parameter $1 må ha en lengde mellom $2 og $3.",
+ "validator_error_invalid_argument": "Verdien $1 er ikke gyldig for parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 kan ikke ikke ha en tom verdi.",
+ "validator_list_error_must_be_number": "Parameter $1 kan bare inneholde tall.",
+ "validator_list_error_must_be_integer": "Parameter $1 kan bare inneholde heltall.",
+ "validator-list-error-must-be-float": "Parameter $1 kan bare innholde flyttall.",
+ "validator_list_error_invalid_range": "Alle verdier av parameter $1 må være mellom $2 og $3.",
+ "validator-list-error-invalid-regex": "Alle verdier av parameter $1 må samsvare med dette regulæruttrykket: $2.",
+ "validator_list_error_invalid_argument": "Parameter $1 har en eller flere ugyldige verdier.",
+ "validator-list-error-accepts-only": "En eller flere verdier for parameter $1 er ugyldige.\nDen godtar bare {{PLURAL:$3|denne verdien|disse verdiene}}: $2.",
+ "validator-list-error-accepts-only-omitted": "En eller flere verdier for parameter $1 er ugyldige.\nDen godtar bare {{PLURAL:$3|denne verdien|disse verdiene}}: $2 (og $4 {{PLURAL:$4|utelatt verdi|utelatte verdier}}).",
+ "validator_error_accepts_only": "Verdien «$4» er ikke gyldig for parameter $1. Den godtar kun {{PLURAL:$3|denne verdien|disse verdiene}}: $2.",
+ "validator-error-accepts-only-omitted": "Verdien «$2» er ikke gyldig for parameter $1.\nDen godtar bare {{PLURAL:$5|denne verdien|disse verdiene}}: $3 (og $4 {{PLURAL:$4|utelatt verdi|utelatte verdier}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Verdien|Verdiene}} $1 har blitt utelatt."
+}
diff --git a/www/wiki/extensions/Validator/i18n/nl.json b/www/wiki/extensions/Validator/i18n/nl.json
new file mode 100644
index 00000000..e11b964a
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/nl.json
@@ -0,0 +1,94 @@
+{
+ "@metadata": {
+ "authors": [
+ "Jeroen De Dauw",
+ "SPQRobin",
+ "Siebrand"
+ ]
+ },
+ "validator-desc": "Bibliotheek voor het verwerken van declaratieve parameters",
+ "validator-warning": "Waarschuwing: $1",
+ "validator-error": "Fout: $1",
+ "validator-fatal-error": "Onherstelbare fout: $1",
+ "validator_error_parameters": "In uw syntaxis {{PLURAL:$1|is de volgende fout|zijn de volgende fouten}} gedetecteerd:",
+ "validator_warning_parameters": "Er {{PLURAL:$1|zit een fout|zitten $1 fouten}} in uw syntaxis.",
+ "validator-warning-adittional-errors": "... en nog {{PLURAL:$1|een ander probleem|$1 andere problemen}}.",
+ "validator-error-omitted": "De {{PLURAL:$2|waarde \"$1\" ontbreekt|waarden \"$1\" ontbreken}}.",
+ "validator-error-problem": "Er was een probleem met de parameter $1.",
+ "validator_error_unknown_argument": "$1 is geen geldige parameter.",
+ "validator_error_required_missing": "De verplichte parameter $1 is niet opgegeven.",
+ "validator-error-override-argument": "Geprobeerd de parameter $1 (waarde: $2) te overschrijven met waarde \"$3\".",
+ "validator-type-string": "tekst",
+ "validator-type-integer": "geheel getal",
+ "validator-type-float": "getal",
+ "validator-type-boolean": "ja / nee",
+ "validator-type-char": "teken",
+ "validator-type-title": "paginanaam",
+ "validator-type-string-list": "lijst met teksten",
+ "validator-type-integer-list": "lijst met gehele getallen",
+ "validator-type-float-list": "lijst met getallen",
+ "validator-type-boolean-list": "lijst met ja/nee",
+ "validator-type-char-list": "lijst met tekens",
+ "validator-type-title-list": "lijst met paginanamen",
+ "validator-listerrors-errors": "Fouten",
+ "validator-listerrors-minor": "Overkomelijk",
+ "validator-listerrors-low": "Laag",
+ "validator-listerrors-normal": "Gemiddeld",
+ "validator-listerrors-high": "Groot",
+ "validator-listerrors-fatal": "Fataal",
+ "validator-listerrors-description": "Fouten en waarschuwingen weergeven die zijn opgetreden in parserhooks die via Validator zijn toegevoegd.\nGeeft alleen parserhooks weer die zijn toegevoegd voordat de fout is opgetreden;\nplaats fouten onderaan of bijna onderaan pagina's om alle fouten weer te geven.",
+ "validator-listerrors-par-minseverity": "De minimale ernst van een probleem voordat het wordt weergegeven.",
+ "validator-describe-description": "Maakt documentatie aan voor een of meer parserhooks die via Validator zijn gedefinieerd.",
+ "validator-describe-notfound": "Er is geen parserhook die \"$1\" afhandelt.",
+ "validator-describe-descriptionmsg": "'''Beschrijving''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliassen}}''': $1",
+ "validator-describe-parserfunction": "Alleen als parserfunctie geïmplementeerd.",
+ "validator-describe-tagextension": "Alleen als labeluitbreiding geïmplementeerd.",
+ "validator-describe-bothhooks": "Als parserfunctie en labeluitbreiding geïmplementeerd.",
+ "validator-describe-par-hooks": "Parserhooks waarvoor documentatie weergegeven moet worden.",
+ "validator-describe-par-pre": "Maakt het mogelijk de wikitekst voor de documentatie weer te geven zonder dat deze wordt verwerkt.",
+ "validator-describe-par-language": "De taal om de beschrijvingen in weer te geven",
+ "validator-describe-listtype": "Lijst met $1 items",
+ "validator-describe-empty": "leeg",
+ "validator-describe-required": "vereist",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Aliassen",
+ "validator-describe-header-type": "Type",
+ "validator-describe-header-default": "Standaard",
+ "validator-describe-header-description": "Beschrijving",
+ "validator-describe-parameters": "Parameters",
+ "validator-describe-syntax": "Syntaxis",
+ "validator-describe-tagmin": "Labeluitbreiding met alleen de verplichte parameters.",
+ "validator-describe-tagmax": "Labeluitbreiding met alle parameters.",
+ "validator-describe-tagdefault": "Labeluitbreiding met alle parameters die de standaard parameternotatie gebruiken.",
+ "validator-describe-pfmin": "Parserfunctie met alleen de verplichte parameters.",
+ "validator-describe-pfmax": "Parserfunctie met alle parameters.",
+ "validator-describe-pfdefault": "Parserfunctie met alle parameters die de standaard parameternotatie gebruiken.",
+ "validator-describe-autogen": "De inhoud van deze paragraaf is automatisch aangemaakt door de parserhook \"beschrijven\" (describe) van de uitbreiding Validator.",
+ "validator_error_empty_argument": "De parameter $1 mag niet leeg zijn.",
+ "validator_error_must_be_number": "De parameter $1 mag alleen een getal zijn.",
+ "validator_error_must_be_integer": "De parameter $1 kan alleen een heel getal zijn.",
+ "validator_error_must_be_title": "Parameter $1 kan alleen een geldige wikipaginanaam zijn.",
+ "validator_error_must_be_existing_title": "Parameter $1 kan alleen een bestaande wikipaginanaam zijn.",
+ "validator-error-must-be-float": "Parameter $1 kan alleen een getal met decimalen zijn.",
+ "validator_error_invalid_range": "De parameter $1 moet tussen $2 en $3 liggen.",
+ "validator-error-invalid-regex": "De parameter $1 moet voldoen aan deze reguliere expressie: $2.",
+ "validator-error-invalid-length": "Parameter $1 moet een lengte hebben van $2.",
+ "validator-error-invalid-length-range": "Parameter $1 moet een lengte hebben tussen $2 en $3.",
+ "validator_error_invalid_argument": "De waarde $1 is niet geldig voor de parameter $2.",
+ "validator_list_error_empty_argument": "Voor de parameter $1 zijn lege waarden niet toegestaan.",
+ "validator_list_error_must_be_number": "Voor de parameter $1 zijn alleen getallen toegestaan.",
+ "validator_list_error_must_be_integer": "Voor de parameter $1 zijn alleen hele getallen toegestaan.",
+ "validator_list_error_must_be_title": "Parameter $1 kan alleen geldige wikipaginanamen bevatten.",
+ "validator_list_error_must_be_existing_title": "Parameter $1 kan alleen bestaande wikipaginanamen bevatten.",
+ "validator-list-error-must-be-float": "Voor de parameter $1 zijn alleen getallen met drijvende komma toegestaan.",
+ "validator_list_error_invalid_range": "Alle waarden voor de parameter $1 moeten tussen $2 en $3 liggen.",
+ "validator-list-error-invalid-regex": "Alle waarden voor de parameter $1 moeten voldoen aan deze reguliere expressie: $2.",
+ "validator_list_error_invalid_argument": "Een of meerdere waarden voor de parameter $1 zijn ongeldig.",
+ "validator-list-error-accepts-only": "Een of meer waarden voor de parameter $1 zijn ongeldig.\nAlleen deze {{PLURAL:$3|waarde is|waarden zijn}} toegestaan: $2.",
+ "validator-list-error-accepts-only-omitted": "Een of meer waarden voor de parameter $1 zijn ongeldig.\nAlleen deze {{PLURAL:$3|waarde is|waarden zijn}} toegestaan: $2.\nAls ook $4 weggelaten {{PLURAL:$4|waarde|waarden}}.",
+ "validator_error_accepts_only": "De waarde \"$4\" is ongeldig voor parameter $1. Deze kan alleen de volgende {{PLURAL:$3|waarde|waarden}} hebben: $2.",
+ "validator-error-accepts-only-omitted": "De waarde \"$2\" is niet geldig voor de parameter $1.\nAlleen deze {{PLURAL:$5|waarde is|waarden zijn}} toegestaan: $3.\nAls ook $4 weggelaten {{PLURAL:$4|waarde|waarden}}.",
+ "validator_list_omitted": "De {{PLURAL:$2|waarde|waarden}} $1 {{PLURAL:$2|ontbreekt|ontbreken}}.",
+ "validator-message-nodesc": "Geen beschrijving"
+}
diff --git a/www/wiki/extensions/Validator/i18n/oc.json b/www/wiki/extensions/Validator/i18n/oc.json
new file mode 100644
index 00000000..d0eed61c
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/oc.json
@@ -0,0 +1,45 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cedric31",
+ "Jfblanc"
+ ]
+ },
+ "validator-desc": "Bibliotèca de tractament dels paramètres declaratius",
+ "validator-error": "Error : $1",
+ "validator-fatal-error": "Error fatal : $1",
+ "validator_error_parameters": "{{PLURAL:$1|L'error seguenta es estada detectada|Las errors seguentas son estadas detectadas}} dins vòstra sintaxi",
+ "validator_error_unknown_argument": "$1 es pas un paramètre valedor.",
+ "validator_error_required_missing": "Manca lo paramètre $1 qu'es obligatòri.",
+ "validator-type-string": "tèxte",
+ "validator-type-integer": "nombre entièr",
+ "validator-type-float": "nombre",
+ "validator-type-boolean": "òc/non",
+ "validator-type-char": "caractèr",
+ "validator-type-title": "títol",
+ "validator-type-string-list": "lista de tèxtes",
+ "validator-type-integer-list": "lista de nombres entièrs",
+ "validator-type-float-list": "lista de nombres",
+ "validator-listerrors-errors": "Errors",
+ "validator-listerrors-minor": "Menor",
+ "validator-listerrors-low": "Feble",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Elevat",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-describe-descriptionmsg": "'''Descripcion''' : $1",
+ "validator-describe-empty": "void",
+ "validator-describe-required": "requesit",
+ "validator-describe-header-parameter": "Paramètre",
+ "validator-describe-header-aliases": "Aliasses",
+ "validator-describe-header-type": "Tipe",
+ "validator-describe-header-default": "Per defaut",
+ "validator-describe-header-description": "Descripcion",
+ "validator-describe-parameters": "Paramètres",
+ "validator-describe-syntax": "Sintaxi",
+ "validator_error_empty_argument": "Lo paramètre $1 pòt pas estar voide.",
+ "validator_error_must_be_number": "Lo paramètre $1 deu èsser un nombre.",
+ "validator_error_must_be_integer": "Lo paramètre $1 deu èsser un nombre entièr.",
+ "validator_error_invalid_range": "Lo paramètre $1 deu èsser entre $2 e $3.",
+ "validator_error_invalid_argument": "$1 es pas valedor pel paramètre $2.",
+ "validator_error_accepts_only": "La valor « $4 » es pas valabla pel paramètre $1. Aqueste paramètre accèpta pas qu'{{PLURAL:$3|aquesta valor|aquestas valors}} : $2."
+}
diff --git a/www/wiki/extensions/Validator/i18n/os.json b/www/wiki/extensions/Validator/i18n/os.json
new file mode 100644
index 00000000..85ee81da
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/os.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "Amikeco"
+ ]
+ },
+ "validator-describe-empty": "афтид"
+}
diff --git a/www/wiki/extensions/Validator/i18n/pfl.json b/www/wiki/extensions/Validator/i18n/pfl.json
new file mode 100644
index 00000000..76fbccb9
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/pfl.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Manuae"
+ ]
+ },
+ "validator-type-string": "Tegschd",
+ "validator-type-boolean": "Ja/Nä",
+ "validator-type-char": "Zaische"
+}
diff --git a/www/wiki/extensions/Validator/i18n/pl.json b/www/wiki/extensions/Validator/i18n/pl.json
new file mode 100644
index 00000000..5dde86df
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/pl.json
@@ -0,0 +1,96 @@
+{
+ "@metadata": {
+ "authors": [
+ "BeginaFelicysym",
+ "Fizykaa",
+ "Matma Rex",
+ "Sp5uhe",
+ "Woytecr"
+ ]
+ },
+ "validator-desc": "Dostarcza innym rozszerzeniom ogólną obsługę parametrów",
+ "validator-warning": "Uwaga: $1",
+ "validator-error": "Błąd: $1",
+ "validator-fatal-error": "Błąd krytyczny – $1",
+ "validator_error_parameters": "W Twoim kodzie {{PLURAL:$1|został wykryty następujący błąd|zostały wykryte następujące błędy}} składni:",
+ "validator_warning_parameters": "W Twoim kodzie {{PLURAL:$1|wystąpił błąd|wystąpiły błędy}} składni.",
+ "validator-warning-adittional-errors": "... i {{PLURAL:$1|jeszcze jeden problem|wiele więcej problemów}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Wartość „$1” została pominięta|Wartości „$1” zostały pominięte}}.",
+ "validator-error-problem": "Wystąpił problem z parametrem $1.",
+ "validator_error_unknown_argument": "$1 jest niepoprawnym parametrem.",
+ "validator_error_required_missing": "Obowiązkowy parametr $1 nie został przekazany.",
+ "validator-error-override-argument": "Próba nadpisania parametru $1 o wartości „$2” nową wartością „$3”",
+ "validator-type-string": "tekst",
+ "validator-type-integer": "liczba całkowita",
+ "validator-type-float": "liczba rzeczywista",
+ "validator-type-boolean": "tak lub nie",
+ "validator-type-char": "znak",
+ "validator-type-title": "tytuł",
+ "validator-type-string-list": "lista ciągów znaków",
+ "validator-type-integer-list": "lista liczb całkowitych",
+ "validator-type-float-list": "lista liczb",
+ "validator-type-boolean-list": "lista tak/nie",
+ "validator-type-char-list": "lista znaków",
+ "validator-type-title-list": "lista tytułów",
+ "validator-listerrors-errors": "Błędy",
+ "validator-listerrors-minor": "Nieistotny",
+ "validator-listerrors-low": "Mało istotny",
+ "validator-listerrors-normal": "Typowy",
+ "validator-listerrors-high": "Istotny",
+ "validator-listerrors-fatal": "Krytyczny",
+ "validator-listerrors-description": "Wyświetla błędy (i ostrzeżenia), które wystąpiły w przechwyceniu parsera dodawanemu przez walidator.\nTylko wyświetlenia dla przechwyceń parsera dodanych powyżej miejsca umieszczenia listerrors;\n umieść listerrors na lub w pobliżu końca strony, aby uzyskać wszystkie błędy.",
+ "validator-listerrors-par-minseverity": "Minimalna waga problemu aby został wymieniony.",
+ "validator-describe-description": "Generuje dokumentację dla jednego lub więcej przechwyceń parsera, zdefiniowanych przez walidator.",
+ "validator-describe-notfound": "Nie ma żadnych przechwyceń analizatora składni, obsługujących \" $1 \".",
+ "validator-describe-descriptionmsg": "'''Opis''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasy}}''': $1",
+ "validator-describe-parserfunction": "Zaimplementowano wyłącznie jako funkcję parsera.",
+ "validator-describe-tagextension": "Zaimplementowano wyłącznie jako rozszerzenie znacznika.",
+ "validator-describe-bothhooks": "Zaimplementowano jako zarówno funkcję parsera i rozszerzenie znacznika.",
+ "validator-describe-par-hooks": "Przechwycenia parsera, dla których wyświetlić dokumentację.",
+ "validator-describe-par-pre": "Umożliwia uzyskanie rzeczywistego wikitekstu dokumentacji, bez renderowania na stronie.",
+ "validator-describe-par-language": "Język wyświetlania opisów",
+ "validator-describe-listtype": "Lista $1 elementów",
+ "validator-describe-empty": "puste",
+ "validator-describe-required": "wymagane",
+ "validator-describe-header-parameter": "Parametr",
+ "validator-describe-header-aliases": "Aliasy",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Domyślnie",
+ "validator-describe-header-description": "Opis",
+ "validator-describe-parameters": "Parametry",
+ "validator-describe-syntax": "Składnia",
+ "validator-describe-tagmin": "Rozszerzenie znacznika wyłącznie z wymaganymi parametrami.",
+ "validator-describe-tagmax": "Rozszerzenie znacznika ze wszystkimi parametrami.",
+ "validator-describe-tagdefault": "Rozszerzenie znacznika z wszystkimi parametrami przy użyciu domyślnej notacji parametrów.",
+ "validator-describe-pfmin": "Funkcja parsera wyłącznie z wymaganymi parametrami.",
+ "validator-describe-pfmax": "Funkcja parsera ze wszystkimi parametrami.",
+ "validator-describe-pfdefault": "Funkcja analizatora składni ze wszystkimi parametrami przy użyciu domyślnej notacji parametrów.",
+ "validator-describe-autogen": "Zawartość niniejszej sekcji została automatycznie wygenerowana przez przechwycenie analizatora składni \"describe\" rozszerzenia walidatora.",
+ "validator_error_empty_argument": "Parametr $1 nie może być pusty.",
+ "validator_error_must_be_number": "Parametr $1 musi być liczbą.",
+ "validator_error_must_be_integer": "Parametr $1 musi być liczbą całkowitą.",
+ "validator_error_must_be_title": "Parametr $1 może być tylko poprawną nazwą strony wiki.",
+ "validator_error_must_be_existing_title": "Parametr $1 może być tylko nazwą istniejącej strony wiki.",
+ "validator-error-must-be-float": "Parametr $1 musi być liczbą rzeczywistą.",
+ "validator_error_invalid_range": "Parametr $1 musi zawierać się w przedziale od $2 do $3.",
+ "validator-error-invalid-regex": "Parametr $1 musi pasować do wyrażenia regularnego $2.",
+ "validator-error-invalid-length": "Parametr $1 musi mieć długość $2.",
+ "validator-error-invalid-length-range": "Długość parametru $1 musi zawierać się w przedziale od $2 do $3.",
+ "validator_error_invalid_argument": "Nieprawidłowa wartość $1 parametru $2.",
+ "validator_list_error_empty_argument": "Parametr $1 nie może być pusty.",
+ "validator_list_error_must_be_number": "Parametrem $1 mogą być wyłącznie liczby.",
+ "validator_list_error_must_be_integer": "Parametrem $1 mogą być wyłącznie liczby całkowite.",
+ "validator_list_error_must_be_title": "Parametr $1 może być tylko poprawnymi nazwami stron wiki.",
+ "validator_list_error_must_be_existing_title": "Parametr $1 może być tylko nazwami istniejących stron wiki.",
+ "validator-list-error-must-be-float": "Parametrem $1 mogą być wyłącznie liczby rzeczywiste.",
+ "validator_list_error_invalid_range": "Wartości parametru $1 muszą zawierać się w przedziale od $2 do $3.",
+ "validator-list-error-invalid-regex": "Wszystkie wartości parametru $1 muszą pasować do wyrażenia regularnego $2.",
+ "validator_list_error_invalid_argument": "Przynajmniej jedna wartość parametru $1 jest nieprawidłowa.",
+ "validator-list-error-accepts-only": "Jedna lub więcej wartości parametru $1 są nieprawidłowe.\nMoże przyjmować wyłącznie {{PLURAL:$3|wartość|wartości:}} $2.",
+ "validator-list-error-accepts-only-omitted": "Jedna lub więcej wartości parametru $1 są nieprawidłowe.\nMoże przyjmować wyłącznie {{PLURAL:$3|wartość|wartości:}} $2 (oraz $4 {{PLURAL:$4|pominiętą wartość|pominięte wartości|pominiętych wartości}}).",
+ "validator_error_accepts_only": "Wartość „$4” jest nieprawidłowa dla parametru $1. {{PLURAL:$3|Dopuszczalna jest wyłącznie wartość|Dopuszczalne są wyłącznie wartości:}} $2.",
+ "validator-error-accepts-only-omitted": "Wartość „$2” parametru $1 jest nieprawidłowa.\nParametr może przyjmować wyłącznie {{PLURAL:$5|wartość|wartości:}} $3 (oraz $4 {{PLURAL:$4|pominiętą wartość|pominięte wartości|pominiętych wartości}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Parametr|Parametry}} $1 {{PLURAL:$2|został opuszczony|zostały opuszczone}}.",
+ "validator-message-nodesc": "Nie podano opisu"
+}
diff --git a/www/wiki/extensions/Validator/i18n/pms.json b/www/wiki/extensions/Validator/i18n/pms.json
new file mode 100644
index 00000000..d33f7ac0
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/pms.json
@@ -0,0 +1,94 @@
+{
+ "@metadata": {
+ "authors": [
+ "Borichèt",
+ "Dragonòt",
+ "McDutchie"
+ ]
+ },
+ "validator-desc": "Librarìe ëd tratament dij paràmeter diciairativ",
+ "validator-warning": "Avis: $1",
+ "validator-error": "Eror: $1",
+ "validator-fatal-error": "Eror Fatal: $1",
+ "validator_error_parameters": "{{PLURAL:$1|L'eror sì-sota a l'é stàit|J'eror sì-sota a son ëstàit}} trovà an soa sintassi:",
+ "validator_warning_parameters": "{{PLURAL:$1|A-i é n'|A-i son dj'}}eror ant soa sintassi.",
+ "validator-warning-adittional-errors": "... e {{PLURAL:$1|ëdcò n'àutr problema|vàire àutri problema}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Ël valor \"$1\" a l'é|Ij valor \"$1\" a son}} stàit sautà.",
+ "validator-error-problem": "A-i é staje un problema con ël paràmetr $1.",
+ "validator_error_unknown_argument": "$1 a l'é un paràmetr pa bon.",
+ "validator_error_required_missing": "Ël paràmetr obligatòri $1 a l'é pa dàit.",
+ "validator-error-override-argument": "Provà a coaté ël paràmetr $1 (valor: $2) con ël valor \"$3\"",
+ "validator-type-string": "test",
+ "validator-type-integer": "nùmer antregh",
+ "validator-type-float": "nùmer",
+ "validator-type-boolean": "bò/nò",
+ "validator-type-char": "caràter",
+ "validator-type-title": "tìtol",
+ "validator-type-string-list": "lista ëd test",
+ "validator-type-integer-list": "lista d'antregh",
+ "validator-type-float-list": "lista ëd nùmer",
+ "validator-type-boolean-list": "lista ëd sì/nò",
+ "validator-type-char-list": "caràter ëd la lista",
+ "validator-type-title-list": "lista ëd tìtoj",
+ "validator-listerrors-errors": "Eror",
+ "validator-listerrors-minor": "Pi cit",
+ "validator-listerrors-low": "Bass",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Àut",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "A lista j'eror (e j'avis) che a son capità ant ij gancio ëd l'analisator sintàtich via Validator.\nMach le liste dij gancio ëd l'analisator sintàtich giontà anté ch'a-i é listerrors a son anserìe;\npiassé listerrors dzora o davzin ël fond ëd la pàgina për ciapé tùit j'eror.",
+ "validator-listerrors-par-minseverity": "La gravità mìnima ëd n'eror përchè a sia listà.",
+ "validator-describe-description": "A genera la documentassion për un o pi gancio ëd l'analisator sintàtich definì via Validator.",
+ "validator-describe-notfound": "A-i é gnun gancio ëd l'analisator sintàtich ch'a gestissa \"$1\".",
+ "validator-describe-descriptionmsg": "'''Descrission''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Alias}}''': $1",
+ "validator-describe-parserfunction": "Realisà mach com funsion ëd l'analisator sintàtich.",
+ "validator-describe-tagextension": "Realisà mach com estension ëd tichëtta.",
+ "validator-describe-bothhooks": "Realisà sia com funsion ëd l'analisator sintàtich che com estension ëd tichëtta.",
+ "validator-describe-par-hooks": "Ij gancio ëd l'analisator sintàtich dont ësmon-e la documentassion.",
+ "validator-describe-par-pre": "A-j përmët d'avèj ël wikitest atual për la documentassion, sensa ch'a sia smonù an sla pàgina.",
+ "validator-describe-par-language": "La lenga ant la qual smon-e le descrission",
+ "validator-describe-listtype": "Lista ëd $1 element",
+ "validator-describe-empty": "veuid",
+ "validator-describe-required": "ciamà",
+ "validator-describe-header-parameter": "Paràmetr",
+ "validator-describe-header-aliases": "Alias",
+ "validator-describe-header-type": "Sòrt",
+ "validator-describe-header-default": "Për sòlit",
+ "validator-describe-header-description": "Descrission",
+ "validator-describe-parameters": "Paràmetr",
+ "validator-describe-syntax": "Sintassi",
+ "validator-describe-tagmin": "Estension ëd tichëtta con mach ij paràmetr obligatòri.",
+ "validator-describe-tagmax": "Estension ëd tichëtta con tùit ij paràmetr.",
+ "validator-describe-tagdefault": "Estension ëd tichëtta con tùit ij paràmetr an dovrand la notassion dë stàndard dij paràmetr.",
+ "validator-describe-pfmin": "Funsion ëd l'analisator sintàtich con mach ij paràmetr obligatòri.",
+ "validator-describe-pfmax": "Funsion ëd l'analisator sintàtich con tùit ij paràmetr.",
+ "validator-describe-pfdefault": "Funsion ëd l'analisator sintàtich con tùit ij paràmetr an dovrand la notassion dë stàndard dij paràmetr.",
+ "validator-describe-autogen": "Ël contnù dë sta session a l'é stàit generà an automàtich dal gancio \"descrive\" ëd l'analisator sintàtich ëd l'estension ëd Validator.",
+ "validator_error_empty_argument": "Ël paràmetr $1 a peul pa avèj un valor veuid.",
+ "validator_error_must_be_number": "Ël paràmetr $1 a peul mach esse un nùmer.",
+ "validator_error_must_be_integer": "Ël paràmetr $1 a peul mach esse n'antregh.",
+ "validator_error_must_be_title": "Ël paràmeter $1 a peul mach esse un nòm ëd pàgina wiki bon.",
+ "validator_error_must_be_existing_title": "Ël paràmetr $1 a peul mach esse un nòm ëd pàgina wiki esistenta.",
+ "validator-error-must-be-float": "Ël paràmetr $1 a peul mach esse un nùmer an vìrgola mòbil.",
+ "validator_error_invalid_range": "Ël paràmetr $1 a deuv esse an tra $2 e $3.",
+ "validator-error-invalid-regex": "Ël paràmetr $1 a dev cobiesse con sta espression regolar: $2.",
+ "validator-error-invalid-length": "Ël paràmetr $1 a dev avèj na longheur ëd $2.",
+ "validator-error-invalid-length-range": "Ël paràmetr $1 a dev avèj na longheur antra $2 e $3.",
+ "validator_error_invalid_argument": "Ël valor $1 a l'é pa bon për ël paràmetr $2.",
+ "validator_list_error_empty_argument": "Ël paràmetr $1 a aceta pa dij valor veuid.",
+ "validator_list_error_must_be_number": "Ël paràmetr $1 a peul mach conten-e dij nùmer.",
+ "validator_list_error_must_be_integer": "Ël paràmetr $1 a peul mach conten-e dj'antegr.",
+ "validator_list_error_must_be_title": "Ël paràmetr $1 a peul mach conten-e dij nòm ëd pàgina wiki bon.",
+ "validator_list_error_must_be_existing_title": "Ël paràmetr $1 a peul mach conten-e dij nòm ëd pàgine wiki esistente.",
+ "validator-list-error-must-be-float": "Ël paràmetr $1 a peul mach conten-e dij nùmer con vìrgola.",
+ "validator_list_error_invalid_range": "Tùit ij valor dël paràmetr $1 a deuvo esse tra $2 e $3.",
+ "validator-list-error-invalid-regex": "Tùit ij valor dël paràmetr $1 a devo cobiesse con sta espression regolar: $2.",
+ "validator_list_error_invalid_argument": "Un o pi valor dël paràmetr $1 a son pa bon.",
+ "validator-list-error-accepts-only": "Un o pi valor për ël paràmetr $1 a son pa bon.\nA aceta mach {{PLURAL:$3|sto valor|sti valor}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Un o pi valor për ël paràmetr $1 a son pa bon.\nA aceta mach {{PLURAL:$3|sto valor|sti valor}}: $2 (e $4 {{PLURAL:$4|valor|valor}} sautà).",
+ "validator_error_accepts_only": "Ël valor \"$4\" a l'é pa bon për ël paràmetr $1. A aceta mach {{PLURAL:$3|sto valor-sì|sti valor-sì}}: $2.",
+ "validator-error-accepts-only-omitted": "Ël valor \"$2\" a l'é pa bon për ël paràmetr $1. A aceta mach sti valor: $3 (e ij valor pa butà $4).",
+ "validator_list_omitted": "{{PLURAL:$2|Ël valor|Ij valor}} $1 {{PLURAL:$2|a l'é|a son}} pa stàit butà.",
+ "validator-message-nodesc": "Gnun-a descrission fornìa"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ps.json b/www/wiki/extensions/Validator/i18n/ps.json
new file mode 100644
index 00000000..873863ec
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ps.json
@@ -0,0 +1,21 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ahmed-Najib-Biabani-Ibrahimkhel"
+ ]
+ },
+ "validator-error": "تېروتنه: $1",
+ "validator-type-string": "متن",
+ "validator-type-float": "شمېره",
+ "validator-type-boolean": "هو/نه",
+ "validator-type-char": "لوښه",
+ "validator-type-title": "سرليک",
+ "validator-type-float-list": "د شمېرو لړليک",
+ "validator-type-boolean-list": "د هو/نه لړليک",
+ "validator-type-char-list": "د لوښو لړليک",
+ "validator-listerrors-errors": "تېروتنې",
+ "validator-listerrors-normal": "نورمال",
+ "validator-describe-empty": "تش",
+ "validator-describe-header-default": "تلواليز",
+ "validator-describe-header-description": "څرگندونه"
+}
diff --git a/www/wiki/extensions/Validator/i18n/pt-br.json b/www/wiki/extensions/Validator/i18n/pt-br.json
new file mode 100644
index 00000000..895668ac
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/pt-br.json
@@ -0,0 +1,96 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cainamarques",
+ "Giro720",
+ "Jaideraf",
+ "Luckas",
+ "Luckas Blade"
+ ]
+ },
+ "validator-desc": "Biblioteca para o processamento de parâmetros declarativos",
+ "validator-warning": "Atenção: $1",
+ "validator-error": "Erro: $1",
+ "validator-fatal-error": "Erro crítico: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Foi detectado o seguinte erro sintático|Foram detectados os seguintes erros sintáticos}}:",
+ "validator_warning_parameters": "{{PLURAL:$1|Existe um erro|Existem erros}} em sua sintaxe.",
+ "validator-warning-adittional-errors": "... e {{PLURAL:$1|mais um problema|vários outros problemas}}.",
+ "validator-error-omitted": "{{PLURAL:$2|O valor \"$1\" foi omitido|Os valores \"$1\" foram omitidos}}.",
+ "validator-error-problem": "Houve um problema com o parâmetro $1.",
+ "validator_error_unknown_argument": "$1 não é um parâmetro válido.",
+ "validator_error_required_missing": "O parâmetro obrigatório \"$1\" não foi fornecido.",
+ "validator-error-override-argument": "Tentativa de sobrepor o parâmetro $1 (valor: $2) com o valor \"$3\"",
+ "validator-type-string": "texto",
+ "validator-type-integer": "número inteiro",
+ "validator-type-float": "número",
+ "validator-type-boolean": "sim/não",
+ "validator-type-char": "caractere",
+ "validator-type-title": "título",
+ "validator-type-string-list": "lista de textos",
+ "validator-type-integer-list": "lista de números inteiros",
+ "validator-type-float-list": "lista de números",
+ "validator-type-boolean-list": "lista de sim/não",
+ "validator-type-char-list": "lista de caracteres",
+ "validator-type-title-list": "lista de títulos",
+ "validator-listerrors-errors": "Erros",
+ "validator-listerrors-minor": "Menor",
+ "validator-listerrors-low": "Baixo",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Alto",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Lista os erros (e avisos) que ocorreram nos hooks do analisador sintático adicionados através da extensão Validator.\nConstarão na lista apenas os hooks adicionados acima de onde estão inseridos os listerrors;\npara obter todos os erros, coloque listerrors ao final da página.",
+ "validator-listerrors-par-minseverity": "A gravidade mínima de um problema para que ele seja listado.",
+ "validator-describe-description": "Gera a documentação para um ou mais hooks do analisador sintático definidos através da extensão Validator.",
+ "validator-describe-notfound": "Não existe qualquer hook para lidar com \"$1\".",
+ "validator-describe-descriptionmsg": "'''Descrição''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Nome alternativo|Nomes alternativos}}''': $1",
+ "validator-describe-parserfunction": "Implementado apenas como parser function.",
+ "validator-describe-tagextension": "Implementado apenas como extensão de tag.",
+ "validator-describe-bothhooks": "Implementado tanto como parser function e como extensão de tag.",
+ "validator-describe-par-hooks": "Os hooks do analisador sintático para os quais serão mostradas a documentação.",
+ "validator-describe-par-pre": "Permite obter o wikitexto real da documentação sem que ele esteja formatado na página.",
+ "validator-describe-par-language": "A língua em que as descrições serão apresentadas",
+ "validator-describe-listtype": "Lista de $1 itens",
+ "validator-describe-empty": "vazio",
+ "validator-describe-required": "obrigatório",
+ "validator-describe-header-parameter": "Parâmetro",
+ "validator-describe-header-aliases": "Nomes alternativos",
+ "validator-describe-header-type": "Tipo",
+ "validator-describe-header-default": "Padrão",
+ "validator-describe-header-description": "Descrição",
+ "validator-describe-parameters": "Parâmetros",
+ "validator-describe-syntax": "Sintaxe",
+ "validator-describe-tagmin": "Extensão de tag só com os parâmetros obrigatórios.",
+ "validator-describe-tagmax": "Extensão de tag com todos os parâmetros.",
+ "validator-describe-tagdefault": "Extensão de tag com todos os parâmetros utilizando a notação de parâmetro padrão.",
+ "validator-describe-pfmin": "Parser function só com os parâmetros obrigatórios.",
+ "validator-describe-pfmax": "Parser function com todos os parâmetros.",
+ "validator-describe-pfdefault": "Parser function com todos os parâmetros utilizando a notação de parâmetro padrão.",
+ "validator-describe-autogen": "O conteúdo desta seção foi gerado de forma automática pelo hook \"describe\" do analisador sintático criado pela extensão Validator.",
+ "validator_error_empty_argument": "O parâmetro $1 não pode estar vazio.",
+ "validator_error_must_be_number": "O parâmetro $1 só pode ser um número.",
+ "validator_error_must_be_integer": "O parâmetro $1 só pode ser um número inteiro.",
+ "validator_error_must_be_title": "O parâmetro $1 só pode ser um nome válido de página wiki.",
+ "validator_error_must_be_existing_title": "O parâmetro $1 só pode ser um nome de página wiki existente.",
+ "validator-error-must-be-float": "O parâmetro $1 deve ser um número de ponto flutuante.",
+ "validator_error_invalid_range": "O parâmetro $1 precisa estar entre $2 e $3.",
+ "validator-error-invalid-regex": "O parâmetro $1 deve corresponder à expressão regular: $2.",
+ "validator-error-invalid-length": "O parâmetro $1 deve ter um comprimento de $2.",
+ "validator-error-invalid-length-range": "O parâmetro $1 precisa ter um comprimento entre $2 e $3.",
+ "validator_error_invalid_argument": "O valor $1 não é válido para o parâmetro $2.",
+ "validator_list_error_empty_argument": "O parâmetro $1 não pode estar vazio.",
+ "validator_list_error_must_be_number": "O parâmetro $1 só pode conter números.",
+ "validator_list_error_must_be_integer": "O parâmetro $1 só pode conter números inteiros.",
+ "validator_list_error_must_be_title": "O parâmetro $1 só pode conter nomes válidos de páginas wiki.",
+ "validator_list_error_must_be_existing_title": "O parâmetro $1 só pode conter nomes de páginas wiki existentes.",
+ "validator-list-error-must-be-float": "O parâmetro $1 só pode conter valores de ponto flutuante.",
+ "validator_list_error_invalid_range": "Todos os valores do parâmetro $1 precisam estar entre $2 e $3.",
+ "validator-list-error-invalid-regex": "Todos os valores do parâmetro $1 devem corresponder à expressão regular: $2.",
+ "validator_list_error_invalid_argument": "Um ou mais valores do parâmetro $1 são inválidos.",
+ "validator-list-error-accepts-only": "Um ou mais valores para o parâmetro $1 são inválidos. Só {{PLURAL:$3|é permitido este valor|são permitidos estes valores}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Um ou mais valores para o parâmetro $1 são inválidos. Só {{PLURAL:$3|é permitido este valor|são permitidos estes valores}}: $2 (e $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_error_accepts_only": "O valor \"$4\" não é válido para o parâmetro $1. Esse parâmetro só aceita {{PLURAL:$3|este valor|estes valores}}: $2.",
+ "validator-error-accepts-only-omitted": "O valor \"$2\" não é válido para o parâmetro $1. Só {{PLURAL:$5|é permitido este valor|são permitidos estes valores}}: $3 (e $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_list_omitted": "{{PLURAL:$2|O valor $1 foi omitido|Os valores $1 foram omitidos}}.",
+ "validator-message-nodesc": "Nenhuma descrição fornecida"
+}
diff --git a/www/wiki/extensions/Validator/i18n/pt.json b/www/wiki/extensions/Validator/i18n/pt.json
new file mode 100644
index 00000000..8554e5a9
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/pt.json
@@ -0,0 +1,94 @@
+{
+ "@metadata": {
+ "authors": [
+ "Giro720",
+ "Hamilton Abreu",
+ "Lijealso",
+ "Luckas",
+ "SandroHc",
+ "Waldir"
+ ]
+ },
+ "validator-desc": "O Serviço de Validação permite que, de forma simples, as outras extensões possam validar parâmetros das funções do analisador sintáctico e das extensões dos elementos HTML, definir valores por omissão e gerar mensagens de erro",
+ "validator-warning": "Aviso: $1",
+ "validator-error": "Erro: $1",
+ "validator-fatal-error": "Erro fatal: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Foi detectado o seguinte erro sintático|Foram detectados os seguintes erros sintáticos}}:",
+ "validator_warning_parameters": "{{PLURAL:$1|Existe um erro sintáctico|Existem erros sintácticos}}.",
+ "validator-warning-adittional-errors": "... e {{PLURAL:$1|mais um problema|vários outros problemas}}.",
+ "validator-error-omitted": "{{PLURAL:$2|O valor \"$1\" foi omitido|Os valores \"$1\" foram omitidos}}.",
+ "validator-error-problem": "Houve um problema com o parâmetro $1.",
+ "validator_error_unknown_argument": "$1 não é um parâmetro válido.",
+ "validator_error_required_missing": "O parâmetro obrigatório $1 não foi fornecido.",
+ "validator-error-override-argument": "Tentativa de sobrepor o parâmetro $1 (valor: $2) com o valor \"$3\"",
+ "validator-type-string": "texto",
+ "validator-type-integer": "número inteiro",
+ "validator-type-float": "número",
+ "validator-type-boolean": "sim/não",
+ "validator-type-char": "carácter",
+ "validator-type-title": "título",
+ "validator-type-string-list": "lista de textos",
+ "validator-type-integer-list": "lista de números inteiros",
+ "validator-type-float-list": "lista de números",
+ "validator-type-boolean-list": "lista de sim/não",
+ "validator-type-char-list": "lista de caracteres",
+ "validator-type-title-list": "lista de títulos",
+ "validator-listerrors-errors": "Erros",
+ "validator-listerrors-minor": "Menor",
+ "validator-listerrors-low": "Baixo",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Alto",
+ "validator-listerrors-fatal": "Fatal",
+ "validator-listerrors-description": "Lista os erros (e avisos) que ocorreram nos hooks do analisador sintáctico adicionados através do Serviço de Validação.\nDa lista constarão apenas os hooks que apareçam acima do ponto na página onde está listerrors;\npara obter todos os erros, coloque listerrors ao fundo da página.",
+ "validator-listerrors-par-minseverity": "A gravidade mínima de um problema, para que este seja listado.",
+ "validator-describe-description": "Gera documentação para um ou mais hooks do analisador sintáctico definidos através do Serviço de Validação.",
+ "validator-describe-notfound": "Não existe nenhum hook para lidar com \"$1\".",
+ "validator-describe-descriptionmsg": "'''Descrição''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Nome alternativo|Nomes alternativos}}''': $1",
+ "validator-describe-parserfunction": "Implementada apenas como função do analisador sintáctico.",
+ "validator-describe-tagextension": "Implementada apenas como extensão de tag.",
+ "validator-describe-bothhooks": "Implementada como função do analisador sintáctico e como extensão de tag.",
+ "validator-describe-par-hooks": "Os hooks do analisador sintáctico para os quais será mostrada documentação.",
+ "validator-describe-par-pre": "Permite obter o texto wiki real da documentação, sem que este seja formatado na página.",
+ "validator-describe-par-language": "A língua em que as descrições serão apresentadas",
+ "validator-describe-listtype": "Lista de $1 elementos",
+ "validator-describe-empty": "vazio",
+ "validator-describe-required": "necessário",
+ "validator-describe-header-parameter": "Parâmetro",
+ "validator-describe-header-aliases": "Nomes alternativos",
+ "validator-describe-header-type": "Tipo",
+ "validator-describe-header-default": "Por omissão",
+ "validator-describe-header-description": "Descrição",
+ "validator-describe-parameters": "Parâmetros",
+ "validator-describe-syntax": "Sintaxe",
+ "validator-describe-tagmin": "Extensão de tag só com os parâmetros obrigatórios.",
+ "validator-describe-tagmax": "Extensão de tag com todos os parâmetros.",
+ "validator-describe-tagdefault": "Extensão de tag com todos os parâmetros, usando a notação do parâmetro por omissão.",
+ "validator-describe-pfmin": "Função do analisador sintáctico só com os parâmetros obrigatórios.",
+ "validator-describe-pfmax": "Função do analisador sintáctico com todos os parâmetros.",
+ "validator-describe-pfdefault": "Função do analisador sintáctico com todos os parâmetros, usando a notação do parâmetro por omissão.",
+ "validator-describe-autogen": "O conteúdo desta seção foi gerado de forma automática pelo hook \"describe\" do analisador sintático, criado pela extensão Serviço de Validação.",
+ "validator_error_empty_argument": "O parâmetro $1 não pode estar vazio.",
+ "validator_error_must_be_number": "O parâmetro $1 só pode ser numérico.",
+ "validator_error_must_be_integer": "O parâmetro $1 só pode ser um número inteiro.",
+ "validator_error_must_be_title": "O parâmetro $1 só pode ser um nome válido de página wiki.",
+ "validator_error_must_be_existing_title": "O parâmetro $1 só pode ser um nome de uma página wiki já existente.",
+ "validator-error-must-be-float": "O parâmetro $1 só pode ser um número de vírgula flutuante.",
+ "validator_error_invalid_range": "O parâmetro $1 tem de ser entre $2 e $3.",
+ "validator-error-invalid-regex": "O parâmetro $1 deve corresponder à expressão regular: $2.",
+ "validator-error-invalid-length": "O parâmetro $1 tem de ter um comprimento de $2.",
+ "validator-error-invalid-length-range": "O parâmetro $1 tem de ter um comprimento entre $2 e $3.",
+ "validator_error_invalid_argument": "O valor $1 não é válido para o parâmetro $2.",
+ "validator_list_error_empty_argument": "O parâmetro $1 não pode estar vazio.",
+ "validator_list_error_must_be_number": "O parâmetro $1 só pode ser numérico.",
+ "validator_list_error_must_be_integer": "O parâmetro $1 só pode ser um número inteiro.",
+ "validator-list-error-must-be-float": "O parâmetro $1 só pode conter valores de vírgula flutuante.",
+ "validator_list_error_invalid_range": "Todos os valores do parâmetro $1 têm de ser entre $2 e $3.",
+ "validator-list-error-invalid-regex": "Todos os valores do parâmetro $1 devem corresponder à expressão regular: $2.",
+ "validator_list_error_invalid_argument": "Um ou mais valores do parâmetro $1 são inválidos.",
+ "validator-list-error-accepts-only": "Um ou mais valores para o parâmetro $1 são inválidos.\nSó {{PLURAL:$3|é aceite este valor|são aceites estes valores}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Um ou mais valores para o parâmetro $1 são inválidos.\nSó {{PLURAL:$3|é aceite este valor|são aceites estes valores}}: $2 (e $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_error_accepts_only": "O valor \"$4\" não é válido para o parâmetro $1. O parâmetro só aceita {{PLURAL:$3|este valor|estes valores}}: $2.",
+ "validator-error-accepts-only-omitted": "O valor $2 não é válido para o parâmetro $1.\nSó {{PLURAL:$5|é aceite este valor|são aceites estes valores}}: $3 (e $4 {{PLURAL:$4|valor omitido|valores omitidos}}).",
+ "validator_list_omitted": "{{PLURAL:$2|O valor $1 foi omitido|Os valores $1 foram omitidos}}."
+}
diff --git a/www/wiki/extensions/Validator/i18n/qqq.json b/www/wiki/extensions/Validator/i18n/qqq.json
new file mode 100644
index 00000000..d19a6379
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/qqq.json
@@ -0,0 +1,101 @@
+{
+ "@metadata": {
+ "authors": [
+ "EugeneZelenko",
+ "Fryed-peach",
+ "Kghbln",
+ "Purodha",
+ "Raymond",
+ "Shirayuki",
+ "Liuxinyu970226",
+ "Umherirrender"
+ ]
+ },
+ "validator-desc": "{{desc|name=Validator|url=https://www.mediawiki.org/wiki/Extension:Validator}}",
+ "validator-warning": "This message indicates an error detected. $1 holds the warning message.\n\n{{Identical|Warning}}",
+ "validator-error": "This message indicates an error detected. $1 holds the error report.\n\n{{Identical|Error}}",
+ "validator-fatal-error": "This message indicates a fatal error detected. $1 holds the fatal error report.",
+ "validator_error_parameters": "Parameters:\n* $1 is the number of syntax errors, for PLURAL support (optional)",
+ "validator_warning_parameters": "Parameters:\n* $1 - the number of syntax errors, for PLURAL support (optional)",
+ "validator-warning-adittional-errors": "Parameters:\n* $1 - number of issues",
+ "validator-error-omitted": "Parameters:\n* $1 - ...\n* $2 - number of values",
+ "validator-error-problem": "This is an error message. $1 holds the name of the parameter causing the error.",
+ "validator_error_unknown_argument": "This is an error message. Parameters:\n* $1 - the name of the erroneous parameter provided",
+ "validator_error_required_missing": "This is an error message. $1 holds the name of the parameter which was not provided.",
+ "validator-error-override-argument": "Parameters:\n* $1 - parameter name\n* $2 - old value\n* $3 - new value",
+ "validator-type-string": "This is the name of a type of values that may be assigned to a parameter. In this case it is some \"text\" (string).\n{{Related|Validator-type}}\n{{Identical|Text}}",
+ "validator-type-integer": "This is the name of a type of values that may be assigned to a parameter. In this case it is some \"whole number\" (integer).\n{{Related|Validator-type}}",
+ "validator-type-float": "This is the name of a type of values that may be assigned to a parameter. In this case it is some \"number\".\n{{Related|Validator-type}}\n{{Identical|Number}}",
+ "validator-type-boolean": "This is the name of a type of values that may be assigned to a parameter. In this case it is a boolean value (yes or no).\n{{Related|Validator-type}}",
+ "validator-type-char": "This is the name of a type of values that may be assigned to a parameter. In this case it is some \"character\".\n{{Related|Validator-type}}\n{{Identical|Character}}",
+ "validator-type-dimension": "This is the name of a type of values that may be assigned to a parameter. In this case it is some \"number with a dimensional unit\", e.g. 5px, 2em, etc.,\n{{Related|Validator-type}}",
+ "validator-type-title": "This is the name of a type of values that may be assigned to a parameter. In this case it is the \"title\" of a page.\n{{Related|Validator-type}}\n{{Identical|Title}}",
+ "validator-type-string-list": "This is the name of a type of values that may be assigned to a parameter. In this case multiple \"texts\" (strings).\n{{Related|Validator-type}}",
+ "validator-type-integer-list": "This is the name of a type of values that may be assigned to a parameter. In this case multiple \"whole numbers\" (integers).\n{{Related|Validator-type}}",
+ "validator-type-float-list": "This is the name of a type of values that may be assigned to a parameter. In this case multiple \"numbers\".\n{{Related|Validator-type}}",
+ "validator-type-boolean-list": "This is the name of a type of values that may be assigned to a parameter. In this case multiple \"booleans\" (yes or no).\n{{Related|Validator-type}}",
+ "validator-type-char-list": "This is the name of a type of values that may be assigned to a parameter. In this case multiple \"characters\".\n{{Related|Validator-type}}",
+ "validator-type-title-list": "This is the name of a type of values that may be assigned to a parameter. In this case multiple \"page names\".\n{{Related|Validator-type}}",
+ "validator-listerrors-errors": "This is the title of the section added to a page after inserting the \"listerrors\" tag or the \"listerrors\" parser function. Possible errors which were detected are listed in this section.\n\n{{Identical|Error}}",
+ "validator-listerrors-severity-message": "{{Optional}}\n* $1 = severity\n* $2 = message",
+ "validator-listerrors-minor": "This is the name of a status that is assigned to an error report.\n{{Identical|Minor}}",
+ "validator-listerrors-low": "This is the name of a status that is assigned to an error report.\n{{Identical|Low}}",
+ "validator-listerrors-normal": "This is the name of a status that is assigned to an error report.\n\n{{Identical|Normal}}",
+ "validator-listerrors-high": "This is the name of a status that is assigned to an error report.\n{{Identical|High}}",
+ "validator-listerrors-fatal": "This is the name of a status that is assigned to an error report.\n{{Identical|Fatal}}",
+ "validator-listerrors-description": "This is the message describing purpose of the „<code>listerrors</code>“ tag.",
+ "validator-listerrors-par-minseverity": "This is the description message for the \"minseverity\" parameter that may be used in conjunction with the <code>listerrors</code> tag.",
+ "validator-describe-description": "This is the message describing purpose of the „<code>describe</code>“ tag.\n{{related|Validator-describe}}",
+ "validator-describe-notfound": "Parameters:\n* $1 - parser hook name",
+ "validator-describe-descriptionmsg": "Preceded by HTML comment {{msg-mw|Validator-describe-autogen}}.\n\nParameters:\n* $1 - message or description\n{{Identical|Description}}\n{{related|Validator-describe}}",
+ "validator-describe-aliases": "Used to describe the list of aliases. Parameters:\n* $1 - list of aliases\n* $2 - number of aliases\nPreceded by {{msg-mw|validator-describe-descriptionmsg}} and a new line.\n{{Identical|Alias}}\n{{related|Validator-describe}}",
+ "validator-describe-parserfunction": "{{Related|Validator-describe}}",
+ "validator-describe-tagextension": "{{Related|Validator-describe}}",
+ "validator-describe-bothhooks": "{{Related|Validator-describe}}",
+ "validator-describe-par-hooks": "This is the description message for the \"hooks\" parameter that may be used in conjunction with the <code>describe</code> tag.\n{{related|Validator-describe}}",
+ "validator-describe-par-pre": "This is the description message for the \"pre\" parameter that may be used in conjunction with the <code>describe</code> tag.\n{{related|Validator-describe}}",
+ "validator-describe-par-language": "This is the description message for the \"language\" parameter that may be used in conjunction with the <code>describe</code> tag.\n{{related|Validator-describe}}",
+ "validator-describe-listtype": "This is a patchwork message. $1 stands for one of these messages: {{msg-mw|Validator-type-string}}, {{msg-mw|Validator-type-number}}, {{msg-mw|Validator-type-integer}}, {{msg-mw|Validator-type-float}}, {{msg-mw|Validator-type-boolean}}, {{msg-mw|Validator-type-char}}\n{{related|Validator-describe}}",
+ "validator-describe-empty": "{{Identical|Empty}}\n{{related|Validator-describe}}",
+ "validator-describe-required": "{{related|Validator-describe}}\n{{Identical|Required}}",
+ "validator-describe-header-parameter": "{{Identical|Parameter}}\n{{related|Validator-describe}}",
+ "validator-describe-header-aliases": "{{Identical|Alias}}\n{{related|Validator-describe}}",
+ "validator-describe-header-type": "{{Identical|Type}}\n{{Related|Validator-describe}}",
+ "validator-describe-header-default": "{{Identical|Default}}\n{{related|Validator-describe}}",
+ "validator-describe-header-description": "{{Identical|Description}}\n{{Related|Validator-describe}}",
+ "validator-describe-parameters": "{{Identical|Parameter}}\n{{related|Validator-describe}}",
+ "validator-describe-syntax": "{{related|Validator-describe}}\n{{Identical|Syntax}}",
+ "validator-describe-tagmin": "{{Related|Validator-describe}}",
+ "validator-describe-tagmax": "{{Related|Validator-describe}}",
+ "validator-describe-tagdefault": "{{Related|Validator-describe}}",
+ "validator-describe-pfmin": "{{Related|Validator-describe}}",
+ "validator-describe-pfmax": "{{Related|Validator-describe}}",
+ "validator-describe-pfdefault": "{{Related|Validator-describe}}",
+ "validator-describe-autogen": "{{Related|Validator-describe}}",
+ "validator_error_empty_argument": "Unused at this time.\n\nParameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator list error empty argument}}\n{{Related|Validator error}}",
+ "validator_error_must_be_number": "Unused at this time.\n\nParameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator list error must be number}}\n{{Related|Validator error}}",
+ "validator_error_must_be_integer": "Unused at this time.\n\nParameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator list error must be integer}}\n{{Related|Validator error}}",
+ "validator_error_must_be_title": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator list error must be title}}\n{{Related|Validator error}}",
+ "validator_error_must_be_existing_title": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator list error must be existing title}}\n{{Related|Validator error}}",
+ "validator-error-must-be-float": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator-list-error-must-be-float}}\n{{Related|Validator error}}",
+ "validator_error_invalid_range": "Parameters:\n* $1 - parameter name\n* $2 - value\n* $3 - value\nSee also:\n* {{msg-mw|Validator list error invalid range}}\n{{Related|Validator error}}",
+ "validator-error-invalid-regex": "Parameters:\n* $1 - parameter name\n* $2 - regular expression\nSee also:\n* {{msg-mw|Validator-list-error-invalid-regex}}\n{{Related|Validator error}}",
+ "validator-error-invalid-length": "Parameters:\n* $1 - parameter name\n* $2 - length\n{{Related|Validator error}}",
+ "validator-error-invalid-length-range": "Parameters:\n* $1 - parameter name\n* $2 - length\n* $3 - length\n{{Related|Validator error}}",
+ "validator_error_invalid_argument": "Parameters:\n* $1 - value\n* $2 - parameter name\nSee also:\n* {{msg-mw|Validator list error invalid argument}}\n{{Related|Validator error}}",
+ "validator_list_error_empty_argument": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator error empty argument}}\n{{Related|Validator list error}}",
+ "validator_list_error_must_be_number": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator error must be number}}\n{{Related|Validator list error}}",
+ "validator_list_error_must_be_integer": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator error must be integer}}\n{{Related|Validator list error}}",
+ "validator_list_error_must_be_title": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator error must be title}}\n{{Related|Validator list error}}",
+ "validator_list_error_must_be_existing_title": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator error must be existing title}}\n{{Related|Validator list error}}",
+ "validator-list-error-must-be-float": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator-error-must-be-float}}\n{{Related|Validator list error}}",
+ "validator_list_error_invalid_range": "Parameters:\n* $1 - parameter name\n* $2 - value\n* $3 - value\nSee also:\n* {{msg-mw|Validator error invalid range}}\n{{Related|Validator list error}}",
+ "validator-list-error-invalid-regex": "Parameters:\n* $1 - parameter name\n* $2 - regular expression\nSee also:\n* {{msg-mw|Validator-error-invalid-regex}}\n{{Related|Validator list error}}",
+ "validator_list_error_invalid_argument": "Parameters:\n* $1 - parameter name\nSee also:\n* {{msg-mw|Validator-list-error-accepts-only}}\n* {{msg-mw|Validator-list-error-accepts-only-omitted}}\n* {{msg-mw|Validator error accepts only}}\n* {{msg-mw|Validator-error-accepts-only-omitted}}\n{{Related|Validator list error}}",
+ "validator-list-error-accepts-only": "Parameters:\n* $1 - parameter name\n* $2 - list of values\n* $3 - number of values\nSee also:\n* {{msg-mw|Validator list error invalid argument}}\n* {{msg-mw|Validator-list-error-accepts-only-omitted}}\n* {{msg-mw|Validator error accepts only}}\n* {{msg-mw|Validator-error-accepts-only-omitted}}\n{{Related|Validator list error}}",
+ "validator-list-error-accepts-only-omitted": "Parameters:\n* $1 - parameter name\n* $2 - ...\n* $3 - number of values\n* $4 - number of values\nSee also:\n* {{msg-mw|Validator list error invalid argument}}\n* {{msg-mw|Validator-list-error-accepts-only}}\n* {{msg-mw|Validator error accepts only}}\n* {{msg-mw|Validator-error-accepts-only-omitted}}\n{{Related|Validator list error}}",
+ "validator_error_accepts_only": "Parameters:\n* $1 - parameter name\n* $2 - ...\n* $3 - number of values\n* $4 - value\nSee also:\n* {{msg-mw|Validator list error invalid argument}}\n* {{msg-mw|Validator-list-error-accepts-only}}\n* {{msg-mw|Validator-list-error-accepts-only-omitted}}\n* {{msg-mw|Validator-error-accepts-only-omitted}}",
+ "validator-error-accepts-only-omitted": "Parameters:\n* $1 - parameter name\n* $2 - value\n* $3 - ...\n* $4 - number of values\n* $5 - number of values\nSee also:\n* {{msg-mw|Validator list error invalid argument}}\n* {{msg-mw|Validator-list-error-accepts-only}}\n* {{msg-mw|Validator-list-error-accepts-only-omitted}}\n* {{msg-mw|Validator error accepts only}}",
+ "validator_list_omitted": "Parameters:\n* $1 - ...\n* $2 - number of values",
+ "validator-message-nodesc": "Indicates that no parameter description is available"
+}
diff --git a/www/wiki/extensions/Validator/i18n/qu.json b/www/wiki/extensions/Validator/i18n/qu.json
new file mode 100644
index 00000000..a414792d
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/qu.json
@@ -0,0 +1,8 @@
+{
+ "@metadata": {
+ "authors": [
+ "AlimanRuna"
+ ]
+ },
+ "validator-warning": "Yuyampay: $1"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ro.json b/www/wiki/extensions/Validator/i18n/ro.json
new file mode 100644
index 00000000..4e4e0366
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ro.json
@@ -0,0 +1,49 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minisarm",
+ "Stelistcristi"
+ ]
+ },
+ "validator-warning": "Avertisment: $1",
+ "validator-error": "Eroare: $1",
+ "validator-fatal-error": "Eroare fatală: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Următoarea eroare a fost detectată|Următoarele erori au fost detectate}} în sintaxa dumneavoastră:",
+ "validator_warning_parameters": "Există {{PLURAL:$1|o eroare|erori}} în sintaxa dumneavoastră.",
+ "validator-warning-adittional-errors": "... și încă {{PLURAL:$1|o problemă|alte câteva probleme}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Valoarea „$1” a fost omisă|Valorile „$1” au fost omise}}.",
+ "validator-error-problem": "S-a produs o problemă cu parametrul $1.",
+ "validator_error_unknown_argument": "$1 nu este un parametru valid.",
+ "validator_error_required_missing": "Parametrul solicitat „$1” nu este furnizat.",
+ "validator-error-override-argument": "S-a încercat suprascrierea parametrului $1 (valoare: $2) cu valoarea „$3”",
+ "validator-type-string": "text",
+ "validator-type-integer": "număr întreg",
+ "validator-type-float": "număr",
+ "validator-type-boolean": "da/nu",
+ "validator-type-char": "caracter",
+ "validator-type-title": "titlu",
+ "validator-type-string-list": "listă de texte",
+ "validator-type-integer-list": "listă de numere întregi",
+ "validator-type-float-list": "listă de numere",
+ "validator-type-boolean-list": "listă de valori da/nu",
+ "validator-type-char-list": "listă de caractere",
+ "validator-type-title-list": "listă de titluri",
+ "validator-listerrors-errors": "Erori",
+ "validator-listerrors-minor": "Minoră",
+ "validator-describe-descriptionmsg": "'''Descriere''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias|Aliasuri}}''': $1",
+ "validator-describe-listtype": "Listă de elemente „$1”",
+ "validator-describe-empty": "fără conținut",
+ "validator-describe-required": "necesar",
+ "validator-describe-header-parameter": "Parametru",
+ "validator-describe-header-aliases": "Aliasuri",
+ "validator-describe-header-type": "Tip",
+ "validator-describe-header-default": "Implicit",
+ "validator-describe-header-description": "Descriere",
+ "validator-describe-parameters": "Parametri",
+ "validator-describe-syntax": "Sintaxă",
+ "validator_error_empty_argument": "Parametrul $1 nu poate avea o valoare goală.",
+ "validator_error_must_be_number": "Parametrul $1 poate fi doar un număr.",
+ "validator_error_must_be_integer": "Parametrul $1 poate fi doar un număr întreg.",
+ "validator-message-nodesc": "Nicio descriere furnizată"
+}
diff --git a/www/wiki/extensions/Validator/i18n/roa-tara.json b/www/wiki/extensions/Validator/i18n/roa-tara.json
new file mode 100644
index 00000000..c0934785
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/roa-tara.json
@@ -0,0 +1,24 @@
+{
+ "@metadata": {
+ "authors": [
+ "Joetaras"
+ ]
+ },
+ "validator-warning": "Avvertimende: $1",
+ "validator-error": "Errore: $1",
+ "validator-fatal-error": "Errore fatale: $1",
+ "validator_error_unknown_argument": "$1 non g'è 'nu parametre valide.",
+ "validator_error_required_missing": "'U parametre richieste \"$1\" non g'è disponibbile.",
+ "validator-type-string": "teste",
+ "validator-type-float": "numere",
+ "validator-type-boolean": "sìne/none",
+ "validator-type-char": "carattere",
+ "validator-type-title": "titole",
+ "validator-type-string-list": "elenghe de teste",
+ "validator-type-integer-list": "elenghe de intere",
+ "validator-type-float-list": "elenghe de numere",
+ "validator-type-boolean-list": "elenghe de sìne/none",
+ "validator-type-char-list": "elenghe de carattere",
+ "validator-type-title-list": "elenghe de titole",
+ "validator-listerrors-errors": "Errore"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ru.json b/www/wiki/extensions/Validator/i18n/ru.json
new file mode 100644
index 00000000..9926ee85
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ru.json
@@ -0,0 +1,102 @@
+{
+ "@metadata": {
+ "authors": [
+ "Aleksandrit",
+ "Eleferen",
+ "Haffman",
+ "Kaganer",
+ "Lockal",
+ "MaxSem",
+ "McDutchie",
+ "Okras",
+ "Van de Bugger",
+ "Александр Сигачёв"
+ ]
+ },
+ "validator-desc": "Библиотека обработки декларативных параметров",
+ "validator-warning": "Внимание: $1",
+ "validator-error": "Ошибка: $1",
+ "validator-fatal-error": "Критическая ошибка: $1",
+ "validator_error_parameters": "В вашем синтаксисе {{PLURAL:$1|1=обнаружена следующая ошибка|обнаружены следующие ошибки}}:",
+ "validator_warning_parameters": "В вашем синтаксисе {{PLURAL:$1|1=имеется ошибка|имеются ошибки}}.",
+ "validator-warning-adittional-errors": "… и {{PLURAL:$1|1=ещё одна проблема|ещё несколько проблем}}.",
+ "validator-error-omitted": "{{PLURAL:$2|1=Значение «$1» пропущено|Значения «$1» пропущены}}.",
+ "validator-error-problem": "Обнаружена проблема с параметром «$1».",
+ "validator_error_unknown_argument": "$1 — недопустимый параметр.",
+ "validator_error_required_missing": "Не указан обязательный параметр $1.",
+ "validator-error-override-argument": "Попытка переопределения параметра $1 (значение: $2) значением «$3»",
+ "validator-type-string": "текст",
+ "validator-type-integer": "целое число",
+ "validator-type-float": "число",
+ "validator-type-boolean": "да/нет",
+ "validator-type-char": "символ",
+ "validator-type-dimension": "число и единица измерения",
+ "validator-type-title": "название",
+ "validator-type-string-list": "список текстов",
+ "validator-type-integer-list": "список целых чисел",
+ "validator-type-float-list": "список цифр",
+ "validator-type-boolean-list": "список да/нет",
+ "validator-type-char-list": "список символов",
+ "validator-type-title-list": "список названий",
+ "validator-listerrors-errors": "Ошибки",
+ "validator-listerrors-minor": "Незначительная",
+ "validator-listerrors-low": "Низкая",
+ "validator-listerrors-normal": "Обычная",
+ "validator-listerrors-high": "Высокая",
+ "validator-listerrors-fatal": "Фатальная",
+ "validator-listerrors-description": "Перечисляет ошибки (и предупреждения), произошедшие в обработчиках парсера, добавленных с помощью Validator.\nВыводятся только обработчики парсера, добавленные выше вставленно listerrors.\nПоместите listerrors в самый конец страницы, чтобы получить все ошибки.",
+ "validator-listerrors-par-minseverity": "Минимальная серьезность вопроса, для включения в список.",
+ "validator-describe-description": "Создает документацию для одного или нескольких обработчиков парсера, по пределениям Validator.",
+ "validator-describe-notfound": "Не существует обработчика парсера для «$1».",
+ "validator-describe-descriptionmsg": "'''Описание''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|1=Псевдоним|Псевдонимы}}''': $1",
+ "validator-describe-parserfunction": "Реализована только функция парсера.",
+ "validator-describe-tagextension": "Реализовано только как дополнительный тег.",
+ "validator-describe-bothhooks": "Реализовано и функция парсера, и дополнительный тег.",
+ "validator-describe-par-hooks": "Обработчик парсера, для которого отображать документацию.",
+ "validator-describe-par-pre": "Позволяет получить фактический викитекст для документации, без показа на странице.",
+ "validator-describe-par-language": "Язык для отображения описания",
+ "validator-describe-listtype": "Перечень пунктов $1",
+ "validator-describe-empty": "пусто",
+ "validator-describe-required": "требуется",
+ "validator-describe-header-parameter": "Параметр",
+ "validator-describe-header-aliases": "Псевдонимы",
+ "validator-describe-header-type": "Тип",
+ "validator-describe-header-default": "По умолчанию",
+ "validator-describe-header-description": "Описание",
+ "validator-describe-parameters": "Параметры",
+ "validator-describe-syntax": "Синтаксис",
+ "validator-describe-tagmin": "Теговое расширение, имеющее только обязательные параметры.",
+ "validator-describe-tagmax": "Теговое расширение со всеми параметрами.",
+ "validator-describe-tagdefault": "Теговое расширение со всеми параметрами, использованием параметров по умолчанию.",
+ "validator-describe-pfmin": "Парсерная функция, имеющая только обязательные параметры.",
+ "validator-describe-pfmax": "Парсерная функция со всеми параметрами.",
+ "validator-describe-pfdefault": "Парсерная функция со всеми параметрами, использованием параметров по умолчанию.",
+ "validator-describe-autogen": "Содержимое этого раздела было автоматически создано парсерным обработчиком «describe» расширения Validator.",
+ "validator_error_empty_argument": "Параметр «$1» не может принимать пустое значение.",
+ "validator_error_must_be_number": "Значением параметра «$1» могут быть только числа.",
+ "validator_error_must_be_integer": "Параметр «$1» может быть только целым числом.",
+ "validator_error_must_be_title": "Параметр «$1» может быть только допустимым именем вики-страницы.",
+ "validator_error_must_be_existing_title": "Параметр «$1» может быть только именем существующей вики-страницы.",
+ "validator-error-must-be-float": "Параметр «$1» может быть числом с плавающей точкой.",
+ "validator_error_invalid_range": "Параметр «$1» должен быть от $2 до $3.",
+ "validator-error-invalid-regex": "Параметр «$1» должен соответствовать регулярному выражению «$2».",
+ "validator-error-invalid-length": "Параметр «$1» должен иметь длину $2.",
+ "validator-error-invalid-length-range": "Параметр «$1» должен иметь длину от $2 до $3.",
+ "validator_error_invalid_argument": "Значение $1 недопустимо для параметра $2",
+ "validator_list_error_empty_argument": "Параметр $1 не может принимать пустые значения.",
+ "validator_list_error_must_be_number": "Параметр $1 может содержать только цифры.",
+ "validator_list_error_must_be_integer": "Параметр $1 может содержать только целые числа.",
+ "validator_list_error_must_be_title": "Параметр $1 может содержать только допустимые имена вики-страниц.",
+ "validator_list_error_must_be_existing_title": "Параметр $1 может содержать только имена существующих вики-страниц.",
+ "validator-list-error-must-be-float": "Параметр «$1» может содержать только числа с плавающей точкой.",
+ "validator_list_error_invalid_range": "Все значения параметра $1 должна находиться в диапазоне от $2 до $3.",
+ "validator-list-error-invalid-regex": "Все значения параметра «$1» должны соответствовать регулярноve выражению «$2».",
+ "validator_list_error_invalid_argument": "Одно или несколько значений параметра $1 ошибочны.",
+ "validator-list-error-accepts-only": "Одно или несколько значений параметра $1 ошибочны. {{PLURAL:$3|1=Допустимо только следующее значение|Допустимы только следующие значения}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Одно или несколько значений параметра $1 ошибочны.\n{{PLURAL:$3|1=Допустимо только следующее значение|Допустимы только следующие значения}}: $2 (и $4 {{PLURAL:$4|опущенное значение|опущенных значений|опущенных значения}}).",
+ "validator_error_accepts_only": "Значение «$4» не подходит для параметра $1. Он может принимать только {{PLURAL:$3|1=следующее значение|следующие значения}}: $2.",
+ "validator-error-accepts-only-omitted": "Значение «$2» не подходит для параметра $1.\n{{PLURAL:$5|1=Допускается только значение|Допускаются только значения}}: $3 (и $4 {{PLURAL:$4|пропущенное значение|пропущенных значений|пропущенных значения}}).",
+ "validator_list_omitted": "{{PLURAL:$2|1=Значение $1 было пропущено|Значения $1 были пропущены}}.",
+ "validator-message-nodesc": "Описание не предоставлено"
+}
diff --git a/www/wiki/extensions/Validator/i18n/rue.json b/www/wiki/extensions/Validator/i18n/rue.json
new file mode 100644
index 00000000..9120de83
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/rue.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Gazeb"
+ ]
+ },
+ "validator-type-string": "текст",
+ "validator-listerrors-errors": "Хыбы"
+}
diff --git a/www/wiki/extensions/Validator/i18n/sah.json b/www/wiki/extensions/Validator/i18n/sah.json
new file mode 100644
index 00000000..103c62a4
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/sah.json
@@ -0,0 +1,14 @@
+{
+ "@metadata": {
+ "authors": [
+ "HalanTul"
+ ]
+ },
+ "validator-warning": "Болҕой: $1",
+ "validator-error": "Алҕас: $1",
+ "validator-fatal-error": "Бөдөҥ алҕас: $1",
+ "validator-type-boolean": "сөп/суох",
+ "validator-type-char": "бэлиэ",
+ "validator-type-title": "аат",
+ "validator-type-string-list": "тиэкис тиһилигэ"
+}
diff --git a/www/wiki/extensions/Validator/i18n/si.json b/www/wiki/extensions/Validator/i18n/si.json
new file mode 100644
index 00000000..4b596c98
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/si.json
@@ -0,0 +1,71 @@
+{
+ "@metadata": {
+ "authors": [
+ "Calcey",
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "validator-desc": "තහවුරු කරන්නා ටැග් දිඟුවන් හා parser ශ්‍රිතවල පරාමිතීන් තහවුරු කිරීමට අනෙක් දිඟුවන් සඳහා පහසු ක්‍රමයක් සපයයි,පෙරනිමි අගයන් පිහිටුවීම හා දෝෂ පණිවුඩ ජනනය කිරීම ද සිදු කරයි",
+ "validator-warning": "අවවාදය: $1",
+ "validator-error": "දෝෂය: $1",
+ "validator-fatal-error": "මාරාන්තික දෝෂය: $1",
+ "validator_error_parameters": "ඔබේ වාග් රීතිය මඟින් පහත {{PLURAL:$1|දෝෂය|දෝෂයන්}} අනාවරණය කරනු ලැබ ඇත",
+ "validator-error-problem": "$1 පරාමිතිය සමඟ ගැටලුවක් තිබුණි.",
+ "validator_error_unknown_argument": "$1 වලංගු පරාමිතියක් නොවේ.",
+ "validator_error_required_missing": "අවශ්‍ය වන $1 පරාමිතිය සපයා නොමැත.",
+ "validator-type-string": "පෙළ",
+ "validator-type-integer": "සම්පූර්ණ අංකය",
+ "validator-type-float": "අංකය",
+ "validator-type-boolean": "ඔව්/නැහැ",
+ "validator-type-char": "අක්ෂරය",
+ "validator-type-title": "ශීර්ෂය",
+ "validator-type-string-list": "පාඨ ලැයිස්තුව",
+ "validator-type-integer-list": "පූර්ණ සංඛ්‍යා ලැයිස්තුව",
+ "validator-type-float-list": "අංක ලැයිස්තුව",
+ "validator-type-boolean-list": "ඔව්/නැහැ ලැයිස්තුව",
+ "validator-type-char-list": "අක්ෂර ලැයිස්තුව",
+ "validator-type-title-list": "ශීර්ෂ ලැයිස්තුව",
+ "validator-listerrors-errors": "දෝෂ",
+ "validator-listerrors-minor": "සුළු",
+ "validator-listerrors-low": "අවම",
+ "validator-listerrors-normal": "සාමාන්‍ය",
+ "validator-listerrors-high": "ඉහළ",
+ "validator-listerrors-fatal": "මාරාන්තික",
+ "validator-describe-descriptionmsg": "'''විස්තරය''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|අන්වර්ථ නාමය|අන්වර්ථ නාම}}''': $1",
+ "validator-describe-parserfunction": "ව්‍යාකරණ විග්‍රහ කෘත්‍යක් ලෙස පමණක් ක්‍රියාවට නංවා ඇත.",
+ "validator-describe-tagextension": "ටැග විස්තීර්ණයක් ලෙස පමණක් ක්‍රියාවට නංවා ඇත.",
+ "validator-describe-par-language": "විස්තර සංදර්ශනය කල යුතු භාෂාව",
+ "validator-describe-listtype": "$1 අයිතමවල ලැයිස්තුව",
+ "validator-describe-empty": "හිස්",
+ "validator-describe-required": "අවශ්‍යයි",
+ "validator-describe-header-parameter": "පරාමිතිය",
+ "validator-describe-header-aliases": "අන්වර්ථ නාම",
+ "validator-describe-header-type": "වර්ගය",
+ "validator-describe-header-default": "සාමාන්‍ය",
+ "validator-describe-header-description": "විස්තරය",
+ "validator-describe-parameters": "පරාමිතීන්",
+ "validator-describe-syntax": "වාක්‍ය වින්‍යාසය",
+ "validator-describe-tagmax": "සියලුම පරාමිතීන් සමඟ සම්බන්ධක දිගුව.",
+ "validator-describe-pfmax": "සියලුම පරාමිතීන් සමඟ ව්‍යාකරණ විග්‍රහ කෘත්‍ය.",
+ "validator_error_empty_argument": "$1 පරාමිතියට හිස් අගයක් තිබිය නොහැක.",
+ "validator_error_must_be_number": "$1 පරාමිතිය විය හැක්කේ ඉලක්කමක් පමණි.",
+ "validator_error_must_be_integer": "$1 පරාමිතිය විය හැක්කේ පූර්ණාංකයක් පමණි.",
+ "validator_error_must_be_title": "$1 පරාමිතිය විය හැක්කේ වලංගු විකි පිටු නාමයක් පමණි.",
+ "validator_error_must_be_existing_title": "$1 පරාමිතිය විය හැක්කේ පවත්නා විකි පිටු නාමයක් පමණි.",
+ "validator-error-must-be-float": "$1 පරාමිතිය විය හැක්කේ ඉපිලෙන ලක්ෂ්‍ය අංකයක් පමණි.",
+ "validator_error_invalid_range": "$1 පරාමිතිය $2 හා $3 අතර විය යුතුය.",
+ "validator-error-invalid-regex": "$1 පරාමිතිය විය මෙම ක්‍රමවත් උච්චාරණයට ගැලපිය යුතුය: $2.",
+ "validator-error-invalid-length": "$1 පරාමිතිය $2 දිගකින් යුක්ත විය යුතුය.",
+ "validator-error-invalid-length-range": "$1 පරාමිතිය $2 සහ $3 අතර දිගකින් යුක්ත විය යුතුය.",
+ "validator_error_invalid_argument": "$2 පරාමිතිය සඳහා $1 අගය වලංගු නොවේ.",
+ "validator_list_error_empty_argument": "$1 පරාමිතිය හිස් අගයන් බාරගනු නොලැබේ.",
+ "validator_list_error_must_be_number": "$1 පරාමිතියේ අඩංගු විය හැක්කේ ඉලක්කම් පමණි.",
+ "validator_list_error_must_be_integer": "$1 පරාමිතියේ අඩංගු විය හැක්කේ පූර්ණාංක පමණි.",
+ "validator_list_error_must_be_title": "$1 පරාමිතියේ අඩංගු විය හැක්කේ වලංගු විකි පිටු නාම පමණි.",
+ "validator_list_error_must_be_existing_title": "$1 පරාමිතියේ අඩංගු විය හැක්කේ පවත්නා විකි පිටු නාම පමණි.",
+ "validator-list-error-must-be-float": "$1 පරාමිතියේ අඩංගු විය හැක්කේ ප්ලාවක පමණි.",
+ "validator_list_error_invalid_argument": "$1 පරාමිතිය සඳහා එක් හෝ තවත් අගයන් වලංගු ඒවා නොවේ.",
+ "validator_error_accepts_only": "$1 පරාමිතිය විසින් පිළිගනු ලබන්නේ {{PLURAL:$3|මෙම අගය|මෙම අගයන්}}: $2 පමණි.",
+ "validator-message-nodesc": "විස්තරයක් සපයා නොමැත"
+}
diff --git a/www/wiki/extensions/Validator/i18n/sr-ec.json b/www/wiki/extensions/Validator/i18n/sr-ec.json
new file mode 100644
index 00000000..f7ccd8db
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/sr-ec.json
@@ -0,0 +1,10 @@
+{
+ "@metadata": {
+ "authors": [
+ "Rancher",
+ "Milicevic01"
+ ]
+ },
+ "validator-error": "Грешка: $1",
+ "validator-listerrors-severity-message": "($1) $2"
+}
diff --git a/www/wiki/extensions/Validator/i18n/sr-el.json b/www/wiki/extensions/Validator/i18n/sr-el.json
new file mode 100644
index 00000000..17f05a27
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/sr-el.json
@@ -0,0 +1,9 @@
+{
+ "@metadata": {
+ "authors": [
+ "Milicevic01"
+ ]
+ },
+ "validator-error": "Greška: $1",
+ "validator-listerrors-severity-message": "($1) $2"
+}
diff --git a/www/wiki/extensions/Validator/i18n/sv.json b/www/wiki/extensions/Validator/i18n/sv.json
new file mode 100644
index 00000000..7d71f69c
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/sv.json
@@ -0,0 +1,100 @@
+{
+ "@metadata": {
+ "authors": [
+ "Cybjit",
+ "Fluff",
+ "Jopparn",
+ "Martinwiss",
+ "Ozp",
+ "Per",
+ "Sertion",
+ "WikiPhoenix",
+ "Lokal Profil"
+ ]
+ },
+ "validator-desc": "Bibliotek för bearbetning av deklarativa parametrar",
+ "validator-warning": "Varning: $1",
+ "validator-error": "Fel: $1",
+ "validator-fatal-error": "Kritiskt fel: $1",
+ "validator_error_parameters": "Följande {{PLURAL:$1|fel|fel}} har upptäckts i din syntax:",
+ "validator_warning_parameters": "Det finns {{PLURAL:$1|ett|flera}} fel i din syntax.",
+ "validator-warning-adittional-errors": "\n... och {{PLURAL:$1|ett problem till|fler problem}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Värdet \"$1\" har|Värdena\"$1\" har}} uteslutits",
+ "validator-error-problem": "Ett problem uppstod med parametern $1.",
+ "validator_error_unknown_argument": "$1 är inte en giltig paramter.",
+ "validator_error_required_missing": "Den nödvändiga parametern $1 har inte angivits.",
+ "validator-error-override-argument": "Försökte skriva över parametern $1 (värde: $2) med värde \"$3\"",
+ "validator-type-string": "text",
+ "validator-type-integer": "helt nummer",
+ "validator-type-float": "nummer",
+ "validator-type-boolean": "ja/nej",
+ "validator-type-char": "tecken",
+ "validator-type-title": "titel",
+ "validator-type-string-list": "listor med texter",
+ "validator-type-integer-list": "listor med heltal",
+ "validator-type-float-list": "listor med siffror",
+ "validator-type-boolean-list": "listor med ja/nej",
+ "validator-type-char-list": "listor med tecken",
+ "validator-type-title-list": "listor med rubriker",
+ "validator-listerrors-errors": "Fel",
+ "validator-listerrors-minor": "Smärre",
+ "validator-listerrors-low": "Låg",
+ "validator-listerrors-normal": "Normal",
+ "validator-listerrors-high": "Hög",
+ "validator-listerrors-fatal": "Kritisk",
+ "validator-listerrors-description": "Listar fel (och varningar) som inträffat i parserhookar vilka lagts till via Validator.\nEnbart listor för parserhookar som lagts till ovanför <code>listerrors</code>-taggen infogats;\nplacera <code>listerrors</code>-taggen vid eller nära slutet av sidan för att få med alla fel.",
+ "validator-listerrors-par-minseverity": "Minsta allvarlighetsgraden för att ett fel ska listas.",
+ "validator-describe-description": "Genererar dokumentation för en eller flera parserhookar som definierats via Validator.",
+ "validator-describe-notfound": "Det finns ingen parserhook som hanterar \"$1\".",
+ "validator-describe-descriptionmsg": "'''Beskrivning''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Alias}}''': $1",
+ "validator-describe-parserfunction": "Endast implementerad som parserfunktion.",
+ "validator-describe-tagextension": "Endast implementerad som tagg-tillägg.",
+ "validator-describe-bothhooks": "Implementerad som både parserfunktion och tagg-tillägg.",
+ "validator-describe-par-hooks": "Parserhooken för vilken dokumentation ska visas.",
+ "validator-describe-par-pre": "Gör att du kan få de faktiska wikitext för dokumentation, utan att den renderas på sidan.",
+ "validator-describe-par-language": "Det språk beskrivningarna ska visas i",
+ "validator-describe-listtype": "Lista med \"$1\"-element",
+ "validator-describe-empty": "tom",
+ "validator-describe-required": "behövs",
+ "validator-describe-header-parameter": "Parameter",
+ "validator-describe-header-aliases": "Alias",
+ "validator-describe-header-type": "Typ",
+ "validator-describe-header-default": "Förvalt",
+ "validator-describe-header-description": "Beskrivning",
+ "validator-describe-parameters": "Parametrar",
+ "validator-describe-syntax": "Syntax",
+ "validator-describe-tagmin": "Tagg-tillägg med enbart de krävda parametrarna.",
+ "validator-describe-tagmax": "Tagg-tillägg med alla parametrar.",
+ "validator-describe-tagdefault": "Tagg-tillägg där alla parametrar använder standardnotation.",
+ "validator-describe-pfmin": "Parserfunktion med enbart de krävda parametrarna.",
+ "validator-describe-pfmax": "Parserfunktion med alla parametrar.",
+ "validator-describe-pfdefault": "Parserfunktion där alla parametrar använder standardnotation.",
+ "validator-describe-autogen": "Innehållet i det här avsnittet auto-genererades av \"describe\"-parserhooken i Validator-tillägget.",
+ "validator_error_empty_argument": "Parameter $1 kan inte lämnas tom.",
+ "validator_error_must_be_number": "Parameter $1 måste bestå av ett tal.",
+ "validator_error_must_be_integer": "Parameter $1 måste vara ett heltal.",
+ "validator_error_must_be_title": "Parameter $1 kan endast vara namnet på en giltig wikisida.",
+ "validator_error_must_be_existing_title": "Parameter $1 kan endast vara namnet på en existerande wikisida.",
+ "validator-error-must-be-float": "Parameter $1 kan endast vara ett flyttal.",
+ "validator_error_invalid_range": "Parameter $1 måste vara i mellan $2 och $3.",
+ "validator-error-invalid-regex": "Parameter $1 måste matcha detta reguljära uttryck: $2.",
+ "validator-error-invalid-length": "Parameter $1 måste ha en längd på $2.",
+ "validator-error-invalid-length-range": "Parameter $1 måste ha en längd mellan $2 och $3.",
+ "validator_error_invalid_argument": "Värdet $1 är inte giltigt för parameter $2.",
+ "validator_list_error_empty_argument": "Parameter $1 accepterar inte tomma värden.",
+ "validator_list_error_must_be_number": "Parameter $1 får endast innehålla siffror.",
+ "validator_list_error_must_be_integer": "Parameter $1 får endast innehålla heltal.",
+ "validator_list_error_must_be_title": "Parameter $1 kan endast innehåll giltiga namn på wikisidor.",
+ "validator_list_error_must_be_existing_title": "Parameter $1 kan endast innehåll existerande namn på wikisidor.",
+ "validator-list-error-must-be-float": "Parameter $1 får endast innehålla flyttal.",
+ "validator_list_error_invalid_range": "Alla värden på parameter $1 måste vara mellan $2 och $3.",
+ "validator-list-error-invalid-regex": "Alla värden på parameter $1 måste matcha detta reguljära uttryck: $2.",
+ "validator_list_error_invalid_argument": "Ett eller flera värden på parameter $1 är ogiltiga.",
+ "validator-list-error-accepts-only": "Ett eller flera värden på parameter $1 är ogiltiga. Den accepterar enbart {{PLURAL:$3|detta värde|dessa värden}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Ett eller flera värden på parameter $1 är ogiltiga. Den accepterar enbart {{PLURAL:$3|detta värde|dessa värden}}: $2 (och $4 {{PLURAL:$4|värde|värden}} utelämnades).",
+ "validator_error_accepts_only": "Värdet \"$4\" är inte giltigt för parametern $1. Den accepterar bara {{PLURAL:$3|detta värde|dessa värden}}: $2.",
+ "validator-error-accepts-only-omitted": "Värdet \"$2\" är ogiltigt för parameter $1. Den accepterar enbart {{PLURAL:$5|detta värde|dessa värden}}: $3 (och $4 {{PLURAL:$4|värde|värden}} utelämnades).",
+ "validator_list_omitted": "{{PLURAL:$2|Värdet|Värdena}} $1 har blivit {{PLURAL:$2|utelämnat|utelämnade}}.",
+ "validator-message-nodesc": "Ingen beskrivning tillhandahölls"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ta.json b/www/wiki/extensions/Validator/i18n/ta.json
new file mode 100644
index 00000000..a4118ecb
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ta.json
@@ -0,0 +1,38 @@
+{
+ "@metadata": {
+ "authors": [
+ "Karthi.dr",
+ "Shanmugamp7",
+ "மதனாஹரன்"
+ ]
+ },
+ "validator-warning": "எச்சரிக்கை: $1",
+ "validator-error": "பிழை: $1",
+ "validator-type-string": "உரை",
+ "validator-type-integer": "முழு எண்",
+ "validator-type-float": "எண்",
+ "validator-type-boolean": "ஆம்/இல்லை",
+ "validator-type-char": "வரியுரு",
+ "validator-type-title": "தலைப்பு",
+ "validator-type-string-list": "உரைகளின் பட்டியல்",
+ "validator-type-integer-list": "முழு எண்களின் பட்டியல்",
+ "validator-type-float-list": "எண்களின் பட்டியல்",
+ "validator-type-boolean-list": "ஆம்/இல்லை களின் பட்டியல்",
+ "validator-type-char-list": "எழுத்துகளை பட்டியலிடு",
+ "validator-type-title-list": "தலைப்புகளின் பட்டியல்",
+ "validator-listerrors-errors": "பிழைகள்",
+ "validator-listerrors-minor": "சிறிய",
+ "validator-listerrors-low": "குறைவு",
+ "validator-listerrors-normal": "சாதரணம்",
+ "validator-listerrors-high": "அதிகம்",
+ "validator-describe-listtype": "$1 உருப்படிகளின் பட்டியல்",
+ "validator-describe-empty": "காலி",
+ "validator-describe-required": "தேவைபடுகிறது",
+ "validator-describe-header-parameter": "அளபுரு",
+ "validator-describe-header-type": "வகை",
+ "validator-describe-header-default": "இயல்புநிலை",
+ "validator-describe-header-description": "விளக்கம்",
+ "validator-describe-parameters": "அளபுருக்கள்",
+ "validator-describe-syntax": "வழிமுறைத் தொடரமைப்பு",
+ "validator-message-nodesc": "விவரணமேதும் வழங்கப்படவில்லை"
+}
diff --git a/www/wiki/extensions/Validator/i18n/te.json b/www/wiki/extensions/Validator/i18n/te.json
new file mode 100644
index 00000000..a9791eec
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/te.json
@@ -0,0 +1,33 @@
+{
+ "@metadata": {
+ "authors": [
+ "Chaduvari",
+ "Ravichandra",
+ "Veeven"
+ ]
+ },
+ "validator-warning": "హెచ్చరిక: $1",
+ "validator-error": "లోపం: $1",
+ "validator_error_unknown_argument": "$1 అనేది సరైన పరామితి కాదు.",
+ "validator_error_required_missing": "తప్పకుండా కావాల్సిన $1 పరామితిని ఇవ్వలేదు.",
+ "validator-type-string": "పాఠ్యం",
+ "validator-type-integer": "పూర్ణ సంఖ్య",
+ "validator-type-float": "సంఖ్య",
+ "validator-type-boolean": "అవును/కాదు",
+ "validator-type-title": "శీర్షిక",
+ "validator-listerrors-errors": "పొరపాట్లు",
+ "validator-describe-descriptionmsg": "'''వివరణ''': $1",
+ "validator-describe-required": "తప్పనిసరి",
+ "validator-describe-header-aliases": "మారుపేర్లు",
+ "validator-describe-header-type": "రకం",
+ "validator-describe-header-default": "అప్రమేయం",
+ "validator-describe-header-description": "వివరణ",
+ "validator-describe-parameters": "పరామితులు",
+ "validator_error_empty_argument": "$1 పరామితి ఖాళీగా ఉండకూడదు",
+ "validator_error_must_be_number": "$1 పరామితి ఖచ్చితంగా ఓ సంఖ్య అయిఉండాలి",
+ "validator_error_must_be_integer": "$1 పరామితి ఒక పూర్ణసంఖ్య అయిఉండాలి",
+ "validator_error_invalid_range": "$1 పరామితి $2, $3 మద్యలో ఉండాలి.",
+ "validator_error_invalid_argument": "$2 పరామితి కోసం $1 విలువ సరైంది కాదు",
+ "validator_list_error_must_be_number": "$1 పరామితి ఖచ్చితంగా సంఖ్యలను మాత్రమే కలిగివుండాలి.",
+ "validator_list_error_must_be_integer": "$1 పరామితి పూర్ణసంఖ్యలను మాత్రమే కలిగివుండాలి."
+}
diff --git a/www/wiki/extensions/Validator/i18n/tl.json b/www/wiki/extensions/Validator/i18n/tl.json
new file mode 100644
index 00000000..5c255bc2
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/tl.json
@@ -0,0 +1,93 @@
+{
+ "@metadata": {
+ "authors": [
+ "AnakngAraw"
+ ]
+ },
+ "validator-desc": "Nagbibigay ng panlahatang magtangkilik na paghawak sa ibang mga dugtong",
+ "validator-warning": "Babala: $1",
+ "validator-error": "Kamalian: $1",
+ "validator-fatal-error": "Masidhing kamalian: $1",
+ "validator_error_parameters": "Ang sumusunod na {{PLURAL:$1|kamalian|mga kamalian}} ay napansin sa iyong sintaks:",
+ "validator_warning_parameters": "May {{PLURAL:$1|mali|mga mali}} sa sintaks mo.",
+ "validator-warning-adittional-errors": "... at {{PLURAL:$1|isa pang paksa|maramihan pang mga paksa}}.",
+ "validator-error-omitted": "Ang {{PLURAL:$2|halagang \"$1\" ay|mga halaga \"$1\" ay}} natanggal na.",
+ "validator-error-problem": "Nagkaroon ng suliranin sa parametrong $1.",
+ "validator_error_unknown_argument": "Ang $1 ay isang hindi tanggap na parametro.",
+ "validator_error_required_missing": "Hindi ibinigay ang kailangang parametro na $1.",
+ "validator-error-override-argument": "Sinubukang pangingibabawan ang parametrong $1 (halaga: $2) ng halagang \"$3\"",
+ "validator-type-string": "teksto",
+ "validator-type-integer": "buong bilang",
+ "validator-type-float": "bilang",
+ "validator-type-boolean": "oo/hindi",
+ "validator-type-char": "panitik",
+ "validator-type-title": "pamagat",
+ "validator-type-string-list": "lista ng mga teksto",
+ "validator-type-integer-list": "lista ng mga buumbilang",
+ "validator-type-float-list": "lista ng mga bilang",
+ "validator-type-boolean-list": "lista ng oo/hindi",
+ "validator-type-char-list": "lista ng mga panitik",
+ "validator-type-title-list": "lista ng mga pamagat",
+ "validator-listerrors-errors": "Mga kamalian",
+ "validator-listerrors-severity-message": "($1) $2",
+ "validator-listerrors-minor": "Munti",
+ "validator-listerrors-low": "Mababa",
+ "validator-listerrors-normal": "Karaniwan",
+ "validator-listerrors-high": "Mataas",
+ "validator-listerrors-fatal": "Nakamamatay",
+ "validator-listerrors-description": "Naglilista ng mga kamalian (at mga babala) na naganap sa mga kawit na pambanghay na idinagdag sa pamamagitan ng Validator (Tagapagpatunay).\nNaglilista lang ng mga kawit na pambanghay na idinagdag sa itaas kung saan isiningit ang listerrors (mga kamalian sa lista);\nilagay ang listerrrors (mga kamalian sa lista) doon o malapit sa ilalim ng pahina upang makuha ang lahat ng mga kamalian.",
+ "validator-listerrors-par-minseverity": "Ang pinakamaliit na kalubhaan ng isang paksa para ito maitala.",
+ "validator-describe-description": "Bumbuo ng dokumentasyon para sa isa o mahigit pang mga kalawit na pambanghay na binigyan ng kahulugan sa pamamagitan ng Tagapagpatunay.",
+ "validator-describe-notfound": "Walang kawit ng pambanghay na humahawak sa \"$1\".",
+ "validator-describe-descriptionmsg": "'''Paglalarawan''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Taguri|Mga taguri}}''': $1",
+ "validator-describe-parserfunction": "Ipinatupad lamang bilang tungkuling pambanghay.",
+ "validator-describe-tagextension": "Ipinatupad lamang bilang dugtong ng tatak.",
+ "validator-describe-bothhooks": "Ipinatupad bilang kapwa tungkulin ng pambanghay at bilang dugtong ng tatak.",
+ "validator-describe-par-hooks": "Ang mga kalawit ng pambanghay para kung saan ipapakita ang dokumentasyon.",
+ "validator-describe-par-pre": "Nagpapahintulot sa iyo upang makuha ang talagang teksto ng wiki para sa dokumentasyon, na hindi ito inihaharap sa ibabaw ng pahina.",
+ "validator-describe-par-language": "Ang wika na pagpapakitaan ng mga paglalarawan",
+ "validator-describe-listtype": "Tala ng $1 mga bagay",
+ "validator-describe-empty": "walang laman",
+ "validator-describe-required": "kailangan",
+ "validator-describe-header-parameter": "parametro",
+ "validator-describe-header-aliases": "Mga taguri",
+ "validator-describe-header-type": "Uri",
+ "validator-describe-header-default": "Likas na nakatakda",
+ "validator-describe-header-description": "Paglalarawan",
+ "validator-describe-parameters": "Mga parametro",
+ "validator-describe-syntax": "Palaugnayan",
+ "validator-describe-tagmin": "Tatakan ang mga dugtong na may kinakailangang mga parametro lamang.",
+ "validator-describe-tagmax": "Dugtong ng tatak na mayroon ng lahat ng mga parametro.",
+ "validator-describe-tagdefault": "Dugtong ng tatak na mayroon ng lahat ng mga parametro na ginagamit ang likas na nakatakdang talihalat ng parametro.",
+ "validator-describe-pfmin": "Tungkuling pambanghay na mayroon lamang ng kinakailangang mga parametro.",
+ "validator-describe-pfmax": "Tungkulin ng pambanghay na mayroon ng lahat ng mga parametro.",
+ "validator-describe-pfdefault": "Tungkulin ng pambanghay na mayroon ng lahat ng mga parametro na ginagamit ang likas na nakatakdang katalaan ng parametro.",
+ "validator-describe-autogen": "Ang nilalaman ng seksiyong ito ay kusang nilikha ng kawit na pambanghay na \"describe\" ng dugtong na Validator.",
+ "validator_error_empty_argument": "Hindi dapat na isang halagang walang laman ang parametrong $1.",
+ "validator_error_must_be_number": "Dapat na bilang lang ang parametrong $1.",
+ "validator_error_must_be_integer": "Dapat na tambilang lang ang parametrong $1.",
+ "validator_error_must_be_title": "Ang parametrong $1 ay maaaring maging isang katanggap-tanggap na pangalan ng pahina ng wiki lamang.",
+ "validator_error_must_be_existing_title": "Ang parametrong $1 ay maaaring maging isang umiiral na pangalan ng pahina ng wiki lamang.",
+ "validator-error-must-be-float": "Ang parametrong $1 ay maaaring isang lumulutang na bilang ng punto lamang.",
+ "validator_error_invalid_range": "Dapat na nasa pagitan ng $2 at $3 ang parametrong $1.",
+ "validator-error-invalid-regex": "Ang parametrong $1 ay dapat tumugma sa ganitong pangkaraniwang pagsasaad: $2.",
+ "validator-error-invalid-length": "Ang parametrong $1 ay dapat na may isang haba na $2.",
+ "validator-error-invalid-length-range": "Ang parametrong $1 ay dapat na may isang haba na nasa pagitan ng $2 at $3.",
+ "validator_error_invalid_argument": "Ang halagang $1 ay hindi tanggap para sa parametrong $2.",
+ "validator_list_error_empty_argument": "Hindi tumatanggap ng halagang walang laman ang parametrong $1.",
+ "validator_list_error_must_be_number": "Dapat na naglalaman lang ng mga bilang ang parametrong $1.",
+ "validator_list_error_must_be_integer": "Dapat na naglalaman lang ng mga tambilang ang parametrong $1.",
+ "validator_list_error_must_be_title": "Ang parametrong $1 ay maaaring maglaman lamang ng katanggap-tanggap na mga pangalan ng pahina ng wiki.",
+ "validator_list_error_must_be_existing_title": "Ang parametrong $1 ay maaaring maglaman lamang ng umiiral na mga pangalan ng pahina ng wiki lamang.",
+ "validator-list-error-must-be-float": "Ang parametrong $1 ay maaaring maglaman lamang ng mga palutang.",
+ "validator_list_error_invalid_range": "Dapat na nasa pagitan ng $2 at $3 ang lahat ng mga halaga ng parametrong $1.",
+ "validator-list-error-invalid-regex": "Ang lahat ng mga halaga ng parametrong $1 ay dapat na tumugma sa pangkaraniwang pagsasaad na ito: $2.",
+ "validator_list_error_invalid_argument": "Hindi tanggap ang isa o higit pang mga halaga para sa parametrong $1.",
+ "validator-list-error-accepts-only": "Hindi katanggap-tanggap ang isa o mas maraming mga halaga para sa parametrong $1. Tumatanggap lamang ito ng {{PLURAL:$3|ganitong halaga|ganitong mga halaga}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Hindi katanggap-tanggap ang isa o masa marami pang mga halaga para sa parametrong $1. Tumatanggap lamang ito ng {{PLURAL:$3|ganitong halaga|ganitong mga halaga}}: $2 (at $4 na inalis na {{PLURAL:$4|halaga|mga halaga}}).",
+ "validator_error_accepts_only": "Ang halagang \"$4\" ay hindi katanggap-tanggap para sa parametrong $1. Tumatanggap lamang ito ng\n{{PLURAL:$3|ganitong halaga|ganitong mga halaga}}: $2.",
+ "validator-error-accepts-only-omitted": "Ang halagang \"$2\" ay hindi katanggap-tanggap para sa parametrong $1. Tumatanggap lamang ito ng {{PLURAL:$5|ganitong halaga|ganitong mga halaga}}: $3 (at $4 na inalis na {{PLURAL:$4|halaga|mga halaga}}).",
+ "validator_list_omitted": "Tinanggal {{PLURAL:$2|na ang|na ang mga}} {{PLURAL:$2|halaga|halaga}} ng $1.",
+ "validator-message-nodesc": "Walang ibinigay na paglalarawan"
+}
diff --git a/www/wiki/extensions/Validator/i18n/tr.json b/www/wiki/extensions/Validator/i18n/tr.json
new file mode 100644
index 00000000..03550b20
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/tr.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "Erdemaslancan",
+ "Vito Genovese",
+ "Stultiwikia"
+ ]
+ },
+ "validator_error_unknown_argument": "$1, geçerli bir parametre değildir.",
+ "validator-describe-aliases": "$2 Eşdeş: $1",
+ "validator-describe-required": "gerekli",
+ "validator-describe-header-parameter": "Parametre",
+ "validator-describe-header-aliases": "Eşdeşler",
+ "validator-describe-header-type": "Tür",
+ "validator_error_empty_argument": "$1 parametresi boş bir değere sahip olamaz.",
+ "validator_error_must_be_number": "$1 parametresi sadece sayı olabilir.",
+ "validator_error_must_be_integer": "$1 parametresi sadece bir tamsayı olabilir",
+ "validator_list_error_empty_argument": "$1 parametresi boş değerleri kabul etmemektedir.",
+ "validator_list_error_must_be_number": "$1 parametresi sadece sayı içerebilir."
+}
diff --git a/www/wiki/extensions/Validator/i18n/uk.json b/www/wiki/extensions/Validator/i18n/uk.json
new file mode 100644
index 00000000..c9093d20
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/uk.json
@@ -0,0 +1,99 @@
+{
+ "@metadata": {
+ "authors": [
+ "Andriykopanytsia",
+ "Base",
+ "NickK",
+ "Olvin",
+ "Prima klasy4na",
+ "Ата",
+ "Piramidion"
+ ]
+ },
+ "validator-desc": "Бібліотека обробки декларативних параметрів",
+ "validator-warning": "Увага: $1",
+ "validator-error": "Помилка: $1",
+ "validator-fatal-error": "Критична помилка: $1",
+ "validator_error_parameters": "У вашому синтаксисі {{PLURAL:$1|1=виявлена така помилка|виявлені такі помилки}}:",
+ "validator_warning_parameters": "У Вашому синтаксисі {{PLURAL:$1|1=є помилка|є помилки}}",
+ "validator-warning-adittional-errors": "… і {{PLURAL:$1|1=ще одна проблема|ще декілька проблем}}.",
+ "validator-error-omitted": "{{PLURAL:$2|Значення «$1»}} пропущено.",
+ "validator-error-problem": "Виявлено проблему із параметром $1.",
+ "validator_error_unknown_argument": "$1 не є допустимим параметром.",
+ "validator_error_required_missing": "Не вказано обов'язковий параметр «$1».",
+ "validator-error-override-argument": "Спроба перевизначення параметра $1 (значення: $2) значенням «$3»",
+ "validator-type-string": "текст",
+ "validator-type-integer": "ціле число",
+ "validator-type-float": "число",
+ "validator-type-boolean": "так/ні",
+ "validator-type-char": "символ",
+ "validator-type-dimension": "число й одиниця виміру",
+ "validator-type-title": "заголовок",
+ "validator-type-string-list": "список текстів",
+ "validator-type-integer-list": "список цілих чисел",
+ "validator-type-float-list": "список чисел",
+ "validator-type-boolean-list": "число так/ні",
+ "validator-type-char-list": "список символів",
+ "validator-type-title-list": "список заголовків",
+ "validator-listerrors-errors": "Помилки",
+ "validator-listerrors-minor": "Незначна",
+ "validator-listerrors-low": "Низька",
+ "validator-listerrors-normal": "Звичайна",
+ "validator-listerrors-high": "Висока",
+ "validator-listerrors-fatal": "Фатальна",
+ "validator-listerrors-description": "Перераховує помилки (і попередження), що трапляються в обробниках парсеру, доданих через Validator.\nВиводяться тільки обробники парсеру, додані вище, де вставлено listerrors;\nпомістіть listerrors в кінець сторінки, щоб отримати усі помилки.",
+ "validator-listerrors-par-minseverity": "Мінімальна серйозність питання для включення його в список.",
+ "validator-describe-description": "Створює документацію для одного чи декількох обробників парсеру, визначених через Validator.",
+ "validator-describe-notfound": "Не існує обробнику парсеру для «$1».",
+ "validator-describe-descriptionmsg": "'''Опис''': $1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|Псевдонім|Псевдоніми|Псевдонімів}}''': $1",
+ "validator-describe-parserfunction": "Реалізовано лише як парсерна функція.",
+ "validator-describe-tagextension": "Реалізовано лише як тег розширення.",
+ "validator-describe-bothhooks": "Реалізовано і як парсерна функція, і як тег розширення.",
+ "validator-describe-par-hooks": "Обробник парсеру, для якого відображається документація.",
+ "validator-describe-par-pre": "Дозволяє отримувати фактичний вікітекст для документації без виведення його на сторінку.",
+ "validator-describe-par-language": "Мова для відображення описів",
+ "validator-describe-listtype": "Список елементів типу $1",
+ "validator-describe-empty": "пусто",
+ "validator-describe-required": "обов'язково",
+ "validator-describe-header-parameter": "Параметр",
+ "validator-describe-header-aliases": "Псевдоніми",
+ "validator-describe-header-type": "Тип",
+ "validator-describe-header-default": "Стандартно",
+ "validator-describe-header-description": "Опис",
+ "validator-describe-parameters": "Параметри",
+ "validator-describe-syntax": "Синтаксис",
+ "validator-describe-tagmin": "Доповнення тегу з одними лише обов'язковими параметрами.",
+ "validator-describe-tagmax": "Доповнення тегу з усіма параметрами.",
+ "validator-describe-tagdefault": "Доповнення тегу з усіма параметрами, із застосуванням стандартної нотації параметрів.",
+ "validator-describe-pfmin": "Функція аналізатора, що має лише обов'язкові параметри.",
+ "validator-describe-pfmax": "Функція парсера зі всіма параметрами.",
+ "validator-describe-pfdefault": "Парсерна функція з усіма параметрами, із застосуванням стандартної нотації параметрів.",
+ "validator-describe-autogen": "Вміст цього розділу було автоматично створено обробником парсеру \"describe\" розширення Validator.",
+ "validator_error_empty_argument": "Параметр $1 не може приймати порожнє значення.",
+ "validator_error_must_be_number": "Параметр $1 може бути лише числом.",
+ "validator_error_must_be_integer": "Параметр $1 може бути лише цілим числом.",
+ "validator_error_must_be_title": "Параметр $1 може бути лише допустимою назвою вікі-сторінки.",
+ "validator_error_must_be_existing_title": "Параметр $1 може бути лише назвою існуючої вікі-сторінки.",
+ "validator-error-must-be-float": "Параметр $1 може бути лише числом з плаваючою крапкою.",
+ "validator_error_invalid_range": "Параметр $1 повинен бути від $2 до $3.",
+ "validator-error-invalid-regex": "Параметр $1 повинен відповідати регулярному виразу: $2.",
+ "validator-error-invalid-length": "Параметр $1 повинен мати довжину $2.",
+ "validator-error-invalid-length-range": "Параметр $1 повинен мати довжину від $2 до $3.",
+ "validator_error_invalid_argument": "Значення $1 не є допустимим для параметра $2.",
+ "validator_list_error_empty_argument": "Параметр $1 не може приймати порожні значення.",
+ "validator_list_error_must_be_number": "Параметр $1 може включати лише числа.",
+ "validator_list_error_must_be_integer": "Параметр $1 може включати лише цілі числа.",
+ "validator_list_error_must_be_title": "Параметр $1 може включати лише допустимі назви вікі-сторінок.",
+ "validator_list_error_must_be_existing_title": "Параметр $1 може включати лише назви існуючих вікі-сторінок.",
+ "validator-list-error-must-be-float": "Параметр $1 може включати лише числа з плаваючою крапкою.",
+ "validator_list_error_invalid_range": "Усі значення параметра $1 мають лежати між $2 і $3.",
+ "validator-list-error-invalid-regex": "Усі значення параметра $1 мають відповідати цьому регулярному виразу: $2.",
+ "validator_list_error_invalid_argument": "Одне або більше значень параметра $1 не припустимі.",
+ "validator-list-error-accepts-only": "Одне або більше значень параметра $1 не припустимі. {{PLURAL:$3|1=Допустиме лише таке значення|Допустимі лише такі значення}}: $2.",
+ "validator-list-error-accepts-only-omitted": "Одне або більше значень параметра $1 не припустимі. {{PLURAL:$3|1=Допустиме лише таке значення|Допустимі лише такі значення}}: $2 (і $4 {{PLURAL:$4|опущене значення|опущені значення|опущених значень}}).",
+ "validator_error_accepts_only": "Значення \"$4\" не припустиме для параметра $1. {{PLURAL:$3|1=Допустиме лише таке значення|Допустимі лише такі значення}}: $2.",
+ "validator-error-accepts-only-omitted": "Значення параметра \"$2\" не припустиме для параметра $1. {{PLURAL:$5|1=Допустиме лише таке значення|Допустимі лише такі значення}}: $3 (і $4 {{PLURAL:$4|опущене значення|опущені значення|опущених значень}}).",
+ "validator_list_omitted": "{{PLURAL:$2|Значення}} $1 {{PLURAL:$2|1=було пропущене|були пропущені}}.",
+ "validator-message-nodesc": "Опис відсутній"
+}
diff --git a/www/wiki/extensions/Validator/i18n/ur.json b/www/wiki/extensions/Validator/i18n/ur.json
new file mode 100644
index 00000000..cbc16bfa
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/ur.json
@@ -0,0 +1,20 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "validator-type-string": "ٹیکسٹ",
+ "validator-type-char": "کردار",
+ "validator-type-title": "عنوان",
+ "validator-listerrors-errors": "غلطیاں",
+ "validator-listerrors-low": "کم",
+ "validator-listerrors-normal": "عام",
+ "validator-listerrors-high": "اعلی",
+ "validator-listerrors-fatal": "مہلک",
+ "validator-describe-empty": "خالی",
+ "validator-describe-header-type": "قسم",
+ "validator-describe-header-default": "پہلے سے طے شدہ",
+ "validator-describe-header-description": "تفصیل",
+ "validator-describe-syntax": "نحو"
+}
diff --git a/www/wiki/extensions/Validator/i18n/vi.json b/www/wiki/extensions/Validator/i18n/vi.json
new file mode 100644
index 00000000..3e54df09
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/vi.json
@@ -0,0 +1,52 @@
+{
+ "@metadata": {
+ "authors": [
+ "Minh Nguyen",
+ "Vinhtantran",
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "validator-desc": "Thư viện xử lý tham số một cách khai báo",
+ "validator-warning": "Cảnh báo: $1",
+ "validator-error": "Lỗi: $1",
+ "validator_error_parameters": "{{PLURAL:$1|Lỗi|Các lỗi}} cú pháp sau được nhận ra trong mã của bạn:",
+ "validator_warning_parameters": "Có {{PLURAL:$1}}lỗi cú pháp trong mã của bạn.",
+ "validator_error_unknown_argument": "$1 không phải là tham số hợp lệ.",
+ "validator_error_required_missing": "Không định rõ tham số bắt buộc “$1”.",
+ "validator-type-string": "văn bản",
+ "validator-type-integer": "số nguyên",
+ "validator-type-float": "Số",
+ "validator-type-boolean": "có/không",
+ "validator-type-char": "ký tự",
+ "validator-type-title": "Tựa đề",
+ "validator-type-string-list": "danh sách văn bản",
+ "validator-type-integer-list": "danh sách số nguyên",
+ "validator-type-float-list": "danh sách con số",
+ "validator-type-boolean-list": "danh sách có/không",
+ "validator-type-char-list": "danh sách ký tự",
+ "validator-type-title-list": "danh sách tiêu đề",
+ "validator-listerrors-errors": "Lỗi",
+ "validator-listerrors-low": "Thấp",
+ "validator-listerrors-normal": "Thường",
+ "validator-listerrors-high": "Cao",
+ "validator-describe-descriptionmsg": "'''Miêu tả''': $1",
+ "validator-describe-empty": "có sản phẩm nào",
+ "validator-describe-header-parameter": "Tham số",
+ "validator-describe-header-type": "Loại",
+ "validator-describe-header-default": "Mặc định",
+ "validator-describe-header-description": "Miêu tả",
+ "validator-describe-parameters": "Tham số",
+ "validator-describe-syntax": "Cú pháp",
+ "validator_error_empty_argument": "Tham số “$1” không được để trống.",
+ "validator_error_must_be_number": "Tham số “$1” phải là con số.",
+ "validator_error_must_be_integer": "Tham số “$1” phải là số nguyên.",
+ "validator_error_invalid_range": "Tham số “$1” phải nằm giữa $2 và $3.",
+ "validator_error_invalid_argument": "Giá trị “$1” không hợp tham số “$2”.",
+ "validator_list_error_empty_argument": "Không được để trống tham số “$1”.",
+ "validator_list_error_must_be_number": "Tham số “$1” chỉ được phép bao gồm con số.",
+ "validator_list_error_must_be_integer": "Tham số “$1” chỉ được phép bao gồm số nguyên.",
+ "validator_list_error_invalid_range": "Tất cả các giá trị của tham số “$1” phải nằm giữa $2 và $3.",
+ "validator_list_error_invalid_argument": "Ít nhất một giá trị của tham số “$1” không hợp lệ.",
+ "validator_error_accepts_only": "Tham số $1 có giá trị không hợp lệ “$4”. Tham số chỉ nhận được {{PLURAL:$3|giá trị|các giá trị}} này: $2.",
+ "validator_list_omitted": "{{PLURAL:$2|Giá trị|Các giá trị}} “$1” bị bỏ qua."
+}
diff --git a/www/wiki/extensions/Validator/i18n/yi.json b/www/wiki/extensions/Validator/i18n/yi.json
new file mode 100644
index 00000000..12421bce
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/yi.json
@@ -0,0 +1,12 @@
+{
+ "@metadata": {
+ "authors": [
+ "පසිඳු කාවින්ද"
+ ]
+ },
+ "validator-type-string": "טעקסט",
+ "validator-type-title": "קעפל",
+ "validator-listerrors-normal": "נארמאַל",
+ "validator-describe-empty": "ליידיק",
+ "validator-describe-header-description": "באַשרײַבונג"
+}
diff --git a/www/wiki/extensions/Validator/i18n/zh-hans.json b/www/wiki/extensions/Validator/i18n/zh-hans.json
new file mode 100644
index 00000000..417d0034
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/zh-hans.json
@@ -0,0 +1,101 @@
+{
+ "@metadata": {
+ "authors": [
+ "Hydra",
+ "Liuxinyu970226",
+ "Richarddong",
+ "Shirayuki",
+ "Wilsonmess",
+ "Xiaomingyan",
+ "Yfdyh000",
+ "乌拉跨氪"
+ ]
+ },
+ "validator-desc": "声明参数处理库",
+ "validator-warning": "警告:$1",
+ "validator-error": "错误:$1",
+ "validator-fatal-error": "致命错误:$1",
+ "validator_error_parameters": "从您的语法中检测到以下{{PLURAL:$1|错误}}:",
+ "validator_warning_parameters": "您的语法中存在{{PLURAL:$1|一个错误|若干错误}}。",
+ "validator-warning-adittional-errors": "......以及{{PLURAL:$1|更多的问题}}。",
+ "validator-error-omitted": "{{PLURAL:$2|值“$1”|“$1”等值}}已被忽略。",
+ "validator-error-problem": "参数$1存在一个问题。",
+ "validator_error_unknown_argument": "$1 不是一个有效的参数。",
+ "validator_error_required_missing": "未提供必需参数“$1”。",
+ "validator-error-override-argument": "试图将参数$1(值:$2)覆盖为值“$3”",
+ "validator-type-string": "文本",
+ "validator-type-integer": "整数",
+ "validator-type-float": "浮点数",
+ "validator-type-boolean": "布尔值",
+ "validator-type-char": "字符",
+ "validator-type-dimension": "数字和空间单位",
+ "validator-type-title": "标题",
+ "validator-type-string-list": "文本列表",
+ "validator-type-integer-list": "整数列表",
+ "validator-type-float-list": "数字列表",
+ "validator-type-boolean-list": "是否列表",
+ "validator-type-char-list": "字符列表",
+ "validator-type-title-list": "标题列表",
+ "validator-listerrors-errors": "错误",
+ "validator-listerrors-severity-message": "($1)$2",
+ "validator-listerrors-minor": "很小",
+ "validator-listerrors-low": "小",
+ "validator-listerrors-normal": "中",
+ "validator-listerrors-high": "大",
+ "validator-listerrors-fatal": "致命",
+ "validator-listerrors-description": "列举发生在通过Validator添加的解析器钩的错误(及警告)。只列举上面插入listerrors的地方添加的解析器钩;将listerrors放置在页面底部或其附近以获取所有错误。",
+ "validator-listerrors-par-minseverity": "要被列举的问题的最小严重度。",
+ "validator-describe-description": "为一个或更多通过Validator定义的解析器钩生成文档。",
+ "validator-describe-notfound": "没有处理“$1”的解析器钩子。",
+ "validator-describe-descriptionmsg": "'''说明''':$1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|别名}}''':$1",
+ "validator-describe-parserfunction": "只作为解析器函数执行。",
+ "validator-describe-tagextension": "只执行为标签扩展。",
+ "validator-describe-bothhooks": "同时作为解析器函数和标签扩展执行。",
+ "validator-describe-par-hooks": "显示文档的解析器钩。",
+ "validator-describe-par-pre": "允许您获取文档实际的wiki文本,而不需要将其呈现在页面上。",
+ "validator-describe-par-language": "要在描述中显示的语言",
+ "validator-describe-listtype": "$1项列表",
+ "validator-describe-empty": "空白",
+ "validator-describe-required": "必填",
+ "validator-describe-header-parameter": "参数",
+ "validator-describe-header-aliases": "别名",
+ "validator-describe-header-type": "类型",
+ "validator-describe-header-default": "默认",
+ "validator-describe-header-description": "说明",
+ "validator-describe-parameters": "参数",
+ "validator-describe-syntax": "语法",
+ "validator-describe-tagmin": "只标记需要参数的扩展。",
+ "validator-describe-tagmax": "带所有参数的标签扩展。",
+ "validator-describe-tagdefault": "具有所有参数并使用默认参数表示法的标签扩展。",
+ "validator-describe-pfmin": "只带必须参数的解析器函数。",
+ "validator-describe-pfmax": "带所有参数的解析器函数。",
+ "validator-describe-pfdefault": "带所有使用默认参数符号的参数解析器函数。",
+ "validator-describe-autogen": "此段落的内容由Validator扩展的“describe”解析器钩自动生成。",
+ "validator_error_empty_argument": "参数 $1 不能为空。",
+ "validator_error_must_be_number": "参数 $1 只能为数字。",
+ "validator_error_must_be_integer": "参数 $1 只能为整数。",
+ "validator_error_must_be_title": "参数$1只能是有效的wiki页面名。",
+ "validator_error_must_be_existing_title": "参数$1只能是现有wiki页面名。",
+ "validator-error-must-be-float": "参数$1只能是一个浮点数。",
+ "validator_error_invalid_range": "参数 $1 的范围必须介于 $2 与 $3 之间。",
+ "validator-error-invalid-regex": "参数$1必须匹配此正则表达式:$2。",
+ "validator-error-invalid-length": "参数$1必须指定$2的长度。",
+ "validator-error-invalid-length-range": "参数$1的长度必须介于$2和$3之间。",
+ "validator_error_invalid_argument": "值 $1 对于参数 $2 不合法。",
+ "validator_list_error_empty_argument": "参数 $1 不接受空值。",
+ "validator_list_error_must_be_number": "参数 $1 只能包含数字。",
+ "validator_list_error_must_be_integer": "参数 $1 只能包含整数。",
+ "validator_list_error_must_be_title": "参数 $1 只能包含有效的wiki页面名。",
+ "validator_list_error_must_be_existing_title": "参数 $1 只能包含现有的wiki页面名。",
+ "validator-list-error-must-be-float": "参数 $1 只能包含浮点数。",
+ "validator_list_error_invalid_range": "参数 $1 所有合法的值都必须介于 $2 与 $3 之间。",
+ "validator-list-error-invalid-regex": "参数 $1 所有合法的值都必须匹配此正则表达式:$2。",
+ "validator_list_error_invalid_argument": "参数 $1 的一个或多个值不合法。",
+ "validator-list-error-accepts-only": "参数$1的一个或更多值无效。它只允许以下$3个值:$2。",
+ "validator-list-error-accepts-only-omitted": "参数$1的一个或更多值无效。它只允许以下$3个值:$2(以及$4个省略值)。",
+ "validator_error_accepts_only": "参数$1的值“$4”无效。它只允许以下$3个值:$2。",
+ "validator-error-accepts-only-omitted": "参数$1的值“$2”无效。它只允许以下$5个值:$3(以及$4个省略值)。",
+ "validator_list_omitted": "{{PLURAL:$2|值}}$1已省略。",
+ "validator-message-nodesc": "没有提供描述"
+}
diff --git a/www/wiki/extensions/Validator/i18n/zh-hant.json b/www/wiki/extensions/Validator/i18n/zh-hant.json
new file mode 100644
index 00000000..9946830a
--- /dev/null
+++ b/www/wiki/extensions/Validator/i18n/zh-hant.json
@@ -0,0 +1,90 @@
+{
+ "@metadata": {
+ "authors": [
+ "Mark85296341",
+ "Shirayuki",
+ "Wrightbus",
+ "LNDDYL",
+ "Cwlin0416",
+ "Liuxinyu970226"
+ ]
+ },
+ "validator-desc": "宣告式參數處理程式庫",
+ "validator-warning": "警告:$1",
+ "validator-error": "錯誤:$1",
+ "validator-fatal-error": "嚴重錯誤:$1",
+ "validator_error_parameters": "已偵測到您的語法中有下列{{PLURAL:$1|一個錯誤|多個錯誤}}:",
+ "validator_warning_parameters": "您的語法有{{PLURAL:$1|一個錯誤|多個錯誤}} 。",
+ "validator-warning-adittional-errors": "... 且還有{{PLURAL:$1|一個問題|多個問題}}。",
+ "validator-error-omitted": "{{PLURAL:$2|數值 \"$1\"|數值 \"$1\"}} 已被省略。",
+ "validator-error-problem": "參數 $1 有問題。",
+ "validator_error_unknown_argument": "$1 不是一個有效的參數。",
+ "validator_error_required_missing": "未提供必要的參數 $1 。",
+ "validator-error-override-argument": "嘗試使用數值 \"$3\" 覆蓋參數 $1 (數值:$2)",
+ "validator-type-string": "文字",
+ "validator-type-integer": "整數",
+ "validator-type-float": "浮點數",
+ "validator-type-boolean": "布林值",
+ "validator-type-char": "字元",
+ "validator-type-title": "標題",
+ "validator-type-string-list": "文字清單",
+ "validator-type-integer-list": "整數清單",
+ "validator-type-float-list": "浮點數清單",
+ "validator-type-boolean-list": "布林值清單",
+ "validator-type-char-list": "字元清單",
+ "validator-type-title-list": "標題清單",
+ "validator-listerrors-errors": "錯誤",
+ "validator-listerrors-severity-message": "($1)$2",
+ "validator-listerrors-minor": "微小",
+ "validator-listerrors-low": "小",
+ "validator-listerrors-normal": "一般",
+ "validator-listerrors-high": "大",
+ "validator-listerrors-fatal": "嚴重",
+ "validator-describe-descriptionmsg": "'''描述''':$1",
+ "validator-describe-aliases": "'''{{PLURAL:$2|別名}}''':$1",
+ "validator-describe-parserfunction": "僅開啟分析器函數。",
+ "validator-describe-tagextension": "僅開啟標籤擴充套件。",
+ "validator-describe-bothhooks": "開啟分析器函數與標籤擴充套件。",
+ "validator-describe-listtype": "$1 個清單項目",
+ "validator-describe-empty": "空白",
+ "validator-describe-required": "必填",
+ "validator-describe-header-parameter": "參數",
+ "validator-describe-header-aliases": "別名",
+ "validator-describe-header-type": "類型",
+ "validator-describe-header-default": "預設",
+ "validator-describe-header-description": "描述",
+ "validator-describe-parameters": "參數",
+ "validator-describe-syntax": "語法",
+ "validator-describe-tagmin": "標籤擴充套件,只含必填參數。",
+ "validator-describe-tagmax": "標籤擴充套件,含所有參數。",
+ "validator-describe-tagdefault": "標籤擴充套件,含所有參數並使用預設參數表示法。",
+ "validator-describe-pfmin": "分析器函數,只含密填參數。",
+ "validator-describe-pfmax": "分析器函數,含所有參數。",
+ "validator-describe-pfdefault": "分析器函數,含所有參數並使用預設參數表示法",
+ "validator_error_empty_argument": "參數 $1 不可為空。",
+ "validator_error_must_be_number": "參數 $1 只能為數字。",
+ "validator_error_must_be_integer": "參數 $1 只能為整數。",
+ "validator_error_must_be_title": "參數 $1 只能為有效的 Wiki 頁面名稱。",
+ "validator_error_must_be_existing_title": "參數 $1 只能為已存在的 Wiki 頁面名稱。",
+ "validator-error-must-be-float": "參數 $1 只能為浮點數。",
+ "validator_error_invalid_range": "參數 $1 必須介於 $2 與 $3 之間。",
+ "validator-error-invalid-regex": "參數 $1 必須符合此正規表示法:$2",
+ "validator-error-invalid-length": "參數 $1 長度必須為 $2",
+ "validator-error-invalid-length-range": "參數 $1 長度必須介於 $2 與 $3 之間。",
+ "validator_error_invalid_argument": "參數 $2 的參數值 $1 無效。",
+ "validator_list_error_empty_argument": "參數 $1 不接受空值。",
+ "validator_list_error_must_be_number": "參數 $1 只能包含數字。",
+ "validator_list_error_must_be_integer": "參數 $1 只能包含整數。",
+ "validator_list_error_must_be_title": "參數 $1 只能包含有效的 Wiki 頁面名稱。",
+ "validator_list_error_must_be_existing_title": "參數 $1 只能包含已存在的 Wiki 頁面名稱。",
+ "validator-list-error-must-be-float": "參數 $1 只能包含浮點數。",
+ "validator_list_error_invalid_range": "參數 $1 所有的參數值都必須介於 $2 與 $3 之間。",
+ "validator-list-error-invalid-regex": "參數 $1 所有的參數值都必須符合此正規表示法:$2。",
+ "validator_list_error_invalid_argument": "參數 $1 的一個或多個參數值無效。",
+ "validator-list-error-accepts-only": "參數 $1 的一個或多個參數值無效,只接受{{PLURAL:$3|參數值|參數值}}:$2。",
+ "validator-list-error-accepts-only-omitted": "參數 $1 的一個或多個參數值無效,只接受{{PLURAL:$3|參數值|參數值}}:$2 (且略過 $4 個{{PLURAL:$4|參數值|參數值}})。",
+ "validator_error_accepts_only": "參數 $1 的參數值 \"$4\" 無效,只接受{{PLURAL:$3|參數值|參數值}}:$2。",
+ "validator-error-accepts-only-omitted": "參數 $1 的參數值 \"$2\" 無效,只接受{{PLURAL:$5|參數值|參數值}}:$3 (且略過 $4 個{{PLURAL:$4|參數值|參數值}})。",
+ "validator_list_omitted": "已略過 $1 個{{PLURAL:$2|參數值}}。",
+ "validator-message-nodesc": "未提供任何描述"
+}
diff --git a/www/wiki/extensions/Validator/phpunit.xml.dist b/www/wiki/extensions/Validator/phpunit.xml.dist
new file mode 100644
index 00000000..0f791be2
--- /dev/null
+++ b/www/wiki/extensions/Validator/phpunit.xml.dist
@@ -0,0 +1,24 @@
+<phpunit backupGlobals="false"
+ backupStaticAttributes="false"
+ bootstrap="tests/bootstrap.php"
+ cacheTokens="false"
+ colors="true"
+ convertErrorsToExceptions="true"
+ convertNoticesToExceptions="true"
+ convertWarningsToExceptions="true"
+ stopOnError="false"
+ stopOnFailure="false"
+ stopOnIncomplete="false"
+ stopOnSkipped="false"
+ verbose="true">
+ <testsuites>
+ <testsuite name="Validator">
+ <directory>tests/phpunit</directory>
+ </testsuite>
+ </testsuites>
+ <filter>
+ <whitelist addUncoveredFilesFromWhitelist="true">
+ <directory suffix=".php">src</directory>
+ </whitelist>
+ </filter>
+</phpunit>
diff --git a/www/wiki/extensions/Validator/src/ParamProcessor/MediaWikiTitleValue.php b/www/wiki/extensions/Validator/src/ParamProcessor/MediaWikiTitleValue.php
new file mode 100644
index 00000000..d8f4e708
--- /dev/null
+++ b/www/wiki/extensions/Validator/src/ParamProcessor/MediaWikiTitleValue.php
@@ -0,0 +1,105 @@
+<?php
+
+namespace ParamProcessor;
+
+use DataValues\DataValueObject;
+use InvalidArgumentException;
+use Title;
+
+/**
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MediaWikiTitleValue extends DataValueObject {
+
+ /**
+ * @since 0.1
+ *
+ * @var Title
+ */
+ protected $title;
+
+ /**
+ * @since 0.1
+ *
+ * @param Title $title
+ *
+ * @throws InvalidArgumentException
+ */
+ public function __construct( Title $title ) {
+ $this->title = $title;
+ }
+
+ /**
+ * @see Serializable::serialize
+ *
+ * @since 0.1
+ *
+ * @return string
+ */
+ public function serialize() {
+ return $this->title->getFullText();
+ }
+
+ /**
+ * @see Serializable::unserialize
+ *
+ * @since 0.1
+ *
+ * @param string $value
+ *
+ * @return MediaWikiTitleValue
+ */
+ public function unserialize( $value ) {
+ $this->__construct( Title::newFromText( $value ) );
+ }
+
+ /**
+ * @see DataValue::getType
+ *
+ * @since 0.1
+ *
+ * @return string
+ */
+ public static function getType() {
+ return 'mediawikititle';
+ }
+
+ /**
+ * @see DataValue::getSortKey
+ *
+ * @since 0.1
+ *
+ * @return string|float|int
+ */
+ public function getSortKey() {
+ return $this->title->getCategorySortkey();
+ }
+
+ /**
+ * Returns the Title object.
+ * @see DataValue::getValue
+ *
+ * @since 0.1
+ *
+ * @return Title
+ */
+ public function getValue() {
+ return $this->title;
+ }
+
+ /**
+ * Constructs a new instance of the DataValue from the provided data.
+ * This can round-trip with @see getArrayValue
+ *
+ * @since 0.1
+ *
+ * @param mixed $data
+ *
+ * @return MediaWikiTitleValue
+ */
+ public static function newFromArray( $data ) {
+ return new static( $data );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/src/ParamProcessor/TitleParser.php b/www/wiki/extensions/Validator/src/ParamProcessor/TitleParser.php
new file mode 100644
index 00000000..a6f2b887
--- /dev/null
+++ b/www/wiki/extensions/Validator/src/ParamProcessor/TitleParser.php
@@ -0,0 +1,36 @@
+<?php
+
+namespace ParamProcessor;
+
+use ValueParsers\ParseException;
+use ValueParsers\StringValueParser;
+
+/**
+ * ValueParser that parses the string representation of a MediaWiki Title object.
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class TitleParser extends StringValueParser {
+
+ /**
+ * @see StringValueParser::stringParse
+ *
+ * @since 0.1
+ *
+ * @param string $value
+ *
+ * @return MediaWikiTitleValue
+ * @throws ParseException
+ */
+ protected function stringParse( $value ) {
+ $value = \Title::newFromText( $value );
+
+ if ( is_null( $value ) ) {
+ throw new ParseException( 'Not a title' );
+ }
+
+ return new MediaWikiTitleValue( $value );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/src/legacy/ParserHook.php b/www/wiki/extensions/Validator/src/legacy/ParserHook.php
new file mode 100644
index 00000000..d7b4925c
--- /dev/null
+++ b/www/wiki/extensions/Validator/src/legacy/ParserHook.php
@@ -0,0 +1,613 @@
+<?php
+
+use ParamProcessor\ParamDefinition;
+use ParamProcessor\ProcessingError;
+use ParamProcessor\Processor;
+
+/**
+ * Class for out of the box parser hook functionality integrated with the validation
+ * provided by Validator.
+ *
+ * @since 0.4
+ * @deprecated since 1.0 in favour of the ParserHooks library
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ * @author Daniel Werner
+ */
+abstract class ParserHook {
+
+ const TYPE_TAG = 0;
+ const TYPE_FUNCTION = 1;
+
+ /**
+ * @since 0.4.3
+ *
+ * @var array
+ */
+ protected static $registeredHooks = array();
+
+ /**
+ * Returns an array of registered parser hooks (keys) and their handling
+ * ParserHook deriving class names (values).
+ *
+ * @since 0.4.3
+ *
+ * @return array
+ */
+ public static function getRegisteredParserHooks() {
+ return self::$registeredHooks;
+ }
+
+ /**
+ * Returns the name of the ParserHook deriving class that defines a certain parser hook,
+ * or false if there is none.
+ *
+ * @since 0.4.3
+ *
+ * @param string $hookName
+ *
+ * @return mixed string or false
+ */
+ public static function getHookClassName( $hookName ) {
+ return array_key_exists( $hookName, self::$registeredHooks ) ? self::$registeredHooks[$hookName] : false;
+ }
+
+ /**
+ * @since 0.4
+ *
+ * @var Processor
+ */
+ protected $validator;
+
+ /**
+ * @since 0.4
+ *
+ * @var Parser
+ */
+ protected $parser;
+
+ /**
+ * @since 0.4.4
+ *
+ * @var PPFrame
+ */
+ protected $frame;
+
+ /**
+ * @since 0.4.4
+ *
+ * @var ParserHook::TYPE_ enum item
+ */
+ protected $currentType;
+
+ /**
+ * @since 0.4
+ *
+ * @var boolean
+ */
+ public $forTagExtensions;
+
+ /**
+ * @since 0.4
+ *
+ * @var boolean
+ */
+ public $forParserFunctions;
+
+ /**
+ * Bitfifeld of Options influencing the characteristics of the registered
+ * tag/parser function.
+ *
+ * @since 0.4.13
+ *
+ * @var int
+ */
+ protected $parserHookOptions;
+
+ /**
+ * Gets the name of the parser hook.
+ *
+ * @since 0.4
+ *
+ * @return string or array of string
+ */
+ protected abstract function getName();
+
+ /**
+ * Renders and returns the output.
+ *
+ * @since 0.4
+ *
+ * @param array $parameters
+ *
+ * @return string
+ */
+ protected abstract function render( array $parameters );
+
+ /**
+ * Flag for constructor, whether the function hook should be one callable without
+ * leading hash, i.e. {{plural:...}} instead of {{#if:...}}
+ *
+ * @since 0.4.13
+ */
+ const FH_NO_HASH = 1;
+
+ /* *
+ * @ToDo: implementation of this functionality
+ *
+ * Flag for constructor, whether the tag hook should be handled as function tag hook
+ * and not as a normal tag hook. See Parser::setFunctionTagHook() for details.
+ */
+ #const TH_AS_FUNCTION_TAG = 2;
+
+ /**
+ * Constructor.
+ *
+ * @since 0.4
+ *
+ * @param boolean $forTagExtensions
+ * @param boolean $forParserFunctions
+ * @param integer $flag combination of option flags to manipulare the parser hooks
+ * characteristics. The following are available:
+ * - ParserHook::FH_NO_HASH makes the function callable without leading hash.
+ */
+ public function __construct( $forTagExtensions = true, $forParserFunctions = true, $flags = 0 ) {
+ $this->forTagExtensions = $forTagExtensions;
+ $this->forParserFunctions = $forParserFunctions;
+ // store flags:
+ $this->parserHookOptions = $flags;
+ }
+
+ /**
+ * Function to hook up the coordinate rendering functions to the parser.
+ *
+ * @since 0.4
+ *
+ * @param Parser $parser
+ *
+ * @return true
+ */
+ public function init( Parser &$parser ) {
+ $className = get_class( $this );
+ $first = true;
+
+ foreach ( $this->getNames() as $name ) {
+ if ( $first ) {
+ self::$registeredHooks[$name] = $className;
+ $first = false;
+ }
+
+ // Parser Tag hooking:
+ if ( $this->forTagExtensions ) {
+ $parser->setHook(
+ $name,
+ array( new ParserHookCaller( $className, 'renderTag' ), 'runTagHook' )
+ );
+ }
+
+ // Parser Function hooking:
+ if ( $this->forParserFunctions ) {
+ $flags = 0;
+ $function = 'renderFunction';
+ $callerFunction = 'runFunctionHook';
+
+ // use object arguments if available:
+ if ( defined( 'SFH_OBJECT_ARGS' ) ) {
+ $flags = $flags | SFH_OBJECT_ARGS;
+ $function .= 'Obj';
+ $callerFunction .= 'Obj';
+ }
+ // no leading Hash required?
+ if ( $this->parserHookOptions & self::FH_NO_HASH ) {
+ $flags = $flags | SFH_NO_HASH;
+ }
+
+ $parser->setFunctionHook(
+ $name,
+ array( new ParserHookCaller( $className, $function ), $callerFunction ),
+ $flags
+ );
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Returns an array with the names for the parser hook.
+ *
+ * @since 0.4
+ *
+ * @return array
+ */
+ protected function getNames() {
+ $names = $this->getName();
+
+ if ( !is_array( $names ) ) {
+ $names = array( $names );
+ }
+
+ return $names;
+ }
+
+ /**
+ * Function to add the magic word in pre MW 1.16.
+ *
+ * @since 0.4
+ *
+ * @param array $magicWords
+ * @param string $langCode
+ *
+ * @return boolean
+ */
+ public function magic( array &$magicWords, $langCode ) {
+ foreach ( $this->getNames() as $name ) {
+ $magicWords[$name] = array( 0, $name );
+ }
+
+ return true;
+ }
+
+ /**
+ * Handler for rendering the tag hook registered by Parser::setHook()
+ *
+ * @since 0.4
+ *
+ * @param mixed $input string or null
+ * @param array $args
+ * @param Parser $parser
+ * @param PPFrame $frame Available from 1.16
+ *
+ * @return string
+ */
+ public function renderTag( $input, array $args, Parser $parser, PPFrame $frame = null ) {
+ $this->parser = $parser;
+ $this->frame = $frame;
+
+ $defaultParameters = $this->getDefaultParameters( self::TYPE_TAG );
+ $defaultParam = array_shift( $defaultParameters );
+
+ // If there is a first default parameter, set the tag contents as its value.
+ if ( !is_null( $defaultParam ) && !is_null( $input ) ) {
+ $args[$defaultParam] = $input;
+ }
+
+ return $this->validateAndRender( $args, self::TYPE_TAG );
+ }
+
+ /**
+ * Handler for rendering the function hook registered by Parser::setFunctionHook()
+ *
+ * @since 0.4
+ *
+ * @param Parser &$parser
+ * ... further arguments ...
+ *
+ * @return array
+ */
+ public function renderFunction( Parser &$parser /*, n args */ ) {
+ $args = func_get_args();
+
+ $this->parser = array_shift( $args );
+
+ $output = $this->validateAndRender( $args, self::TYPE_FUNCTION );
+ $options = $this->getFunctionOptions();
+
+ if ( array_key_exists( 'isHTML', $options ) && $options['isHTML'] ) {
+ /** @ToDo: FIXME: Is this really necessary? The same thing is propably going to
+ * happen in Parser::braceSubstitution() if 'isHTML' is set!
+ * @ToDo: other options besides 'isHTML' like 'noparse' are ignored here!
+ */
+ return $this->parser->insertStripItem( $output, $this->parser->mStripState );
+ }
+
+ return array_merge(
+ array( $output ),
+ $options
+ );
+ }
+
+ /**
+ * Handler for rendering the function hook registered by Parser::setFunctionHook() together
+ * with object style arguments (SFH_OBJECT_ARGS flag).
+ *
+ * @since 0.4.13
+ *
+ * @param Parser &$parser
+ * @param PPFrame $frame
+ * @param type $args
+ * @return array
+ */
+ public function renderFunctionObj( Parser &$parser, PPFrame $frame, $args ) {
+ $this->frame = $frame;
+
+ // create non-object args for old style 'renderFunction()'
+ $oldStyleArgs = array( &$parser );
+
+ foreach( $args as $arg ) {
+ $oldStyleArgs[] = trim( $frame->expand( $arg ) );
+ }
+
+ /*
+ * since we can't validate un-expandet arguments, we just go on with old-style function
+ * handling from here. Only advantage is that we have $this->frame set properly.
+ */
+ return call_user_func_array( array( $this, 'renderFunction' ), $oldStyleArgs );
+ }
+
+ /**
+ * Returns the parser function otpions.
+ *
+ * @since 0.4
+ *
+ * @return array
+ */
+ protected function getFunctionOptions() {
+ return array();
+ }
+
+ /**
+ * Takes care of validation and rendering, and returns the output.
+ *
+ * @since 0.4
+ *
+ * @param array $arguments
+ * @param integer $type Item of the ParserHook::TYPE_ enum
+ *
+ * @return string
+ */
+ public function validateAndRender( array $arguments, $type ) {
+ $names = $this->getNames();
+ $this->validator = Processor::newDefault();
+ $this->validator->getOptions()->setName( $names[0] );
+
+ if ( $type === self::TYPE_FUNCTION ) {
+ $this->validator->setFunctionParams( $arguments, $this->getParameterInfo( $type ), $this->getDefaultParameters( $type ) );
+ }
+ else {
+ $this->validator->setParameters( $arguments, $this->getParameterInfo( $type ) );
+ }
+
+ $this->validator->validateParameters();
+
+ $fatalError = $this->validator->hasFatalError();
+
+ if ( $fatalError === false ) {
+ $output = $this->render( $this->validator->getParameterValues() );
+ }
+ else {
+ $output = $this->renderFatalError( $fatalError );
+ }
+
+ return $output;
+ }
+
+ /**
+ * Returns the ProcessingError objects for the errors and warnings that should be displayed.
+ *
+ * @since 0.4
+ *
+ * @return array of array of ProcessingError
+ */
+ protected function getErrorsToDisplay() {
+ $errors = array();
+ $warnings = array();
+
+ foreach ( $this->validator->getErrors() as $error ) {
+ // Check if the severity of the error is high enough to display it.
+ if ( $error->shouldShow() ) {
+ $errors[] = $error;
+ }
+ elseif ( $error->shouldWarn() ) {
+ $warnings[] = $error;
+ }
+ }
+
+ return array( 'errors' => $errors, 'warnings' => $warnings );
+ }
+
+ /**
+ * Creates and returns the output when a fatal error prevent regular rendering.
+ *
+ * @since 0.4
+ *
+ * @param ProcessingError $error
+ *
+ * @return string
+ */
+ protected function renderFatalError( ProcessingError $error ) {
+ return '<div><span class="errorbox">' .
+ wfMessage( 'validator-fatal-error', $error->getMessage() )->parse() .
+ '</span></div><br /><br />';
+ }
+
+ // TODO: replace render errors functionality
+
+ /**
+ * Returns an array containing the parameter info.
+ * Override in deriving classes to add parameter info.
+ *
+ * @since 0.4
+ *
+ * @param integer $type Item of the ParserHook::TYPE_ enum
+ *
+ * @return array
+ */
+ protected function getParameterInfo( $type ) {
+ return array();
+ }
+
+ public function getParamDefinitions( $type = self::TYPE_FUNCTION ) {
+ return $this->getParameterInfo( $type );
+ }
+
+ /**
+ * Returns the list of default parameters. These parameters can be used as
+ * unnamed parameters where it is not necessary to use the name and the '=' as
+ * long as there is no '=' within the value.
+ * It is possible to define that a parameter should not have a named fallback.
+ * Therefore the information has to be returnd as sub-array with the parameter
+ * name as first and Validator::PARAM_UNNAMED as second value. Parameter using
+ * this option must be set first, before any unnamed parameter in the same order
+ * as set here. All parameters defined before the last parameter making use of
+ * Validator::PARAM_UNNAMED will automatically be populated with this option.
+ *
+ * Override in deriving classes to add default parameters.
+ *
+ * @since 0.4
+ *
+ * @param integer $type Item of the ParserHook::TYPE_ enum
+ *
+ * @return array
+ */
+ protected function getDefaultParameters( $type ) {
+ return array();
+ }
+
+ /**
+ * Returns the data needed to describe the parser hook.
+ * This is mainly needed because some of the individual get methods
+ * that return the needed data are protected, and cannot be made
+ * public without breaking b/c in a rather bad way.
+ *
+ * @since 0.4.3
+ *
+ * @param integer $type Item of the ParserHook::TYPE_ enum
+ *
+ * @return array
+ */
+ public function getDescriptionData( $type ) {
+ return array(
+ 'names' => $this->getNames(),
+ 'description' => $this->getDescription(),
+ 'message' => $this->getMessage(),
+ 'parameters' => ParamDefinition::getCleanDefinitions( $this->getParameterInfo( $type ) ),
+ 'defaults' => $this->getDefaultParameters( $type ),
+ );
+ }
+
+ /**
+ * Returns a description for the parser hook, or false when there is none.
+ * Override in deriving classes to add a message.
+ *
+ * @since 0.4.3
+ * @deprecated since 1.0
+ *
+ * @return mixed string or false
+ */
+ public function getDescription() {
+ $msg = $this->getMessage();
+ return $msg === false ? false : wfMessage( $msg )->plain();
+ }
+
+ /**
+ * Returns a description message for the parser hook, or false when there is none.
+ * Override in deriving classes to add a message.
+ *
+ * @since 0.4.10
+ *
+ * @return mixed string or false
+ */
+ public function getMessage() {
+ return false;
+ }
+
+ /**
+ * Returns if the current render request is coming from a tag extension.
+ *
+ * @since 0.4.4
+ *
+ * @return boolean
+ */
+ protected function isTag() {
+ return $this->currentType == self::TYPE_TAG;
+ }
+
+ /**
+ * Returns if the current render request is coming from a parser function.
+ *
+ * @since 0.4.4
+ *
+ * @return boolean
+ */
+ protected function isFunction() {
+ return $this->currentType == self::TYPE_FUNCTION;
+ }
+
+ /**
+ * Utility function to parse wikitext without having to care
+ * about handling a tag extension or parser function.
+ *
+ * @since 0.4.4
+ *
+ * @param string $text The wikitext to be parsed
+ *
+ * @return string the parsed output
+ */
+ protected function parseWikitext( $text ) {
+ // Parse the wikitext to HTML.
+ if ( $this->isFunction() ) {
+ return $this->parser->parse(
+ $text,
+ $this->parser->mTitle,
+ $this->parser->mOptions,
+ true,
+ false
+ )->getText();
+ }
+ else {
+ return $this->parser->recursiveTagParse(
+ $text,
+ $this->frame
+ );
+ }
+ }
+
+}
+
+/**
+ * Completely evil class to create a new instance of the handling ParserHook when the actual hook gets called.
+ *
+ * @evillness >9000 - to be replaced when a better solution (LSB?) is possible.
+ *
+ * @since 0.4
+ *
+ * @author Jeroen De Dauw
+ * @author Daniel Werner
+ */
+class ParserHookCaller {
+
+ protected $class;
+ protected $method;
+
+ function __construct( $class, $method ) {
+ $this->class = $class;
+ $this->method = $method;
+ }
+
+ /*
+ * See Parser::braceSubstitution() and Parser::extensionSubstitution() for details about
+ * how the Parser object and other parameters are being passed. Therefore for function
+ * hooks &$parser fullfills the same purpos as $parser for the tag hook.
+ * functionTagHook (!) calls (if implemented at a later time) are more like function hooks,
+ * meaning, they would require &$parser as well.
+ */
+
+ public function runTagHook( $input, array $args, Parser $parser, PPFrame $frame = null ) {
+ $obj = new $this->class();
+ return $obj->{$this->method}( $input, $args, $parser, $frame );
+ }
+
+ public function runFunctionHook( Parser &$parser /*, n args */ ) {
+ $args = func_get_args();
+ $args[0] = &$parser; // with '&' becaus call_user_func_array is being used
+ return call_user_func_array( array( new $this->class(), $this->method ), $args );
+ }
+
+ public function runFunctionHookObj( Parser &$parser, PPFrame $frame, array $args ) {
+ $obj = new $this->class();
+ return $obj->{$this->method}( $parser, $frame, $args );
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/src/legacy/README.md b/www/wiki/extensions/Validator/src/legacy/README.md
new file mode 100644
index 00000000..c23a5130
--- /dev/null
+++ b/www/wiki/extensions/Validator/src/legacy/README.md
@@ -0,0 +1,4 @@
+The files is this directory contain functionality that although
+it's currently bundled with ParamProcessor and make use it,
+do not really belong to ParamProcessor, and could just as well
+be put into their own extension(s). \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/tests/bootstrap.php b/www/wiki/extensions/Validator/tests/bootstrap.php
new file mode 100644
index 00000000..55d8f80e
--- /dev/null
+++ b/www/wiki/extensions/Validator/tests/bootstrap.php
@@ -0,0 +1,24 @@
+<?php
+
+if ( php_sapi_name() !== 'cli' ) {
+ die( 'Not an entry point' );
+}
+
+$pwd = getcwd();
+chdir( __DIR__ . '/..' );
+passthru( 'composer update' );
+chdir( $pwd );
+
+$shouldUseMwHack = !defined( 'MEDIAWIKI' );
+
+if ( $shouldUseMwHack ) {
+ require_once( __DIR__ . '/evilMediaWikiBootstrap.php' );
+}
+
+require_once( __DIR__ . '/../vendor/autoload.php' );
+
+if ( $shouldUseMwHack ) {
+ foreach ( $GLOBALS['wgExtensionFunctions'] as $extensionFunction ) {
+ call_user_func( $extensionFunction );
+ }
+} \ No newline at end of file
diff --git a/www/wiki/extensions/Validator/tests/evilMediaWikiBootstrap.php b/www/wiki/extensions/Validator/tests/evilMediaWikiBootstrap.php
new file mode 100644
index 00000000..776a6c14
--- /dev/null
+++ b/www/wiki/extensions/Validator/tests/evilMediaWikiBootstrap.php
@@ -0,0 +1,72 @@
+<?php
+
+define( 'MEDIAWIKI', true );
+
+global $IP;
+$IP = getenv( 'MW_INSTALL_PATH' );
+
+if ( $IP === false ) {
+ $IP = dirname( __FILE__ ) . '/../../..';
+}
+
+$self = 'foobar';
+
+// Detect compiled mode
+# Get the MWInit class
+require_once "$IP/includes/Init.php";
+require_once "$IP/includes/AutoLoader.php";
+# Stub the profiler
+require_once "$IP/includes/profiler/Profiler.php";
+
+# Start the profiler
+$wgProfiler = array();
+if ( file_exists( "$IP/StartProfiler.php" ) ) {
+ require "$IP/StartProfiler.php";
+}
+
+// Some other requires
+require_once "$IP/includes/Defines.php";
+
+require_once MWInit::compiledPath( 'includes/DefaultSettings.php' );
+
+foreach ( get_defined_vars() as $key => $var ) {
+ if ( !array_key_exists( $key, $GLOBALS ) ) {
+ $GLOBALS[$key] = $var;
+ }
+}
+
+if ( defined( 'MW_CONFIG_CALLBACK' ) ) {
+ # Use a callback function to configure MediaWiki
+ MWFunction::call( MW_CONFIG_CALLBACK );
+} else {
+ // Require the configuration (probably LocalSettings.php)
+ require loadSettings();
+}
+
+// Some last includes
+require_once MWInit::compiledPath( 'includes/Setup.php' );
+
+// Much much faster startup than creating a title object
+$wgTitle = null;
+
+global $wgAutoloadClasses;
+
+if ( is_null( $wgAutoloadClasses ) ) {
+ $wgAutoloadClasses = array();
+}
+
+require_once $IP . '/tests/TestsAutoLoader.php';
+
+function loadSettings() {
+ global $wgCommandLineMode, $IP;
+
+ $settingsFile = "$IP/LocalSettings.php";
+
+ if ( !is_readable( $settingsFile ) ) {
+ $this->error( "A copy of your installation's LocalSettings.php\n" .
+ "must exist and be readable in the source directory.\n" .
+ "Use --conf to specify it.", true );
+ }
+ $wgCommandLineMode = true;
+ return $settingsFile;
+}
diff --git a/www/wiki/extensions/Validator/tests/phpunit/Definitions/TitleParamTest.php b/www/wiki/extensions/Validator/tests/phpunit/Definitions/TitleParamTest.php
new file mode 100644
index 00000000..eab6a3fe
--- /dev/null
+++ b/www/wiki/extensions/Validator/tests/phpunit/Definitions/TitleParamTest.php
@@ -0,0 +1,77 @@
+<?php
+
+namespace ParamProcessor\Tests\Definitions;
+
+/**
+ * @group Validator
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class TitleParamTest extends ParamDefinitionTest {
+
+ /**
+ * @see ParamDefinitionTest::getDefinitions
+ */
+ public function getDefinitions() {
+ $params = parent::getDefinitions();
+
+ $params['empty-empty'] = $params['empty'];
+ $params['empty-empty']['hastoexist'] = false;
+
+ $params['values-empty'] = $params['values'];
+ $params['values-empty']['hastoexist'] = false;
+ $params['values-empty']['values'][] = \Title::newFromText( 'foo' );
+
+ return $params;
+ }
+
+ /**
+ * @see ParamDefinitionTest::valueProvider
+ *
+ * @param boolean $stringlyTyped
+ *
+ * @return array
+ */
+ public function valueProvider( $stringlyTyped = true ) {
+ $values = array(
+ 'empty-empty' => array(
+ array( 'foo bar page', true, \Title::newFromText( 'foo bar page' ) ),
+ array( '|', false ),
+ array( '', false ),
+ ),
+ 'empty' => array(
+ array( 'foo bar page', false ),
+ array( '|', false ),
+ array( '', false ),
+ ),
+ 'values-empty' => array(
+ array( 'foo', true, \Title::newFromText( 'foo' ) ),
+ array( 'foo bar page', false ),
+ ),
+ 'values' => array(
+ array( 'foo', false ),
+ array( 'foo bar page', false ),
+ ),
+ );
+
+ if ( !$stringlyTyped ) {
+ foreach ( $values as &$set ) {
+ foreach ( $set as &$value ) {
+ $value[0] = \Title::newFromText( $value[0] );
+ }
+ }
+ }
+
+ return $values;
+ }
+
+ /**
+ * @see ParamDefinitionTest::getType
+ * @return string
+ */
+ public function getType() {
+ return 'title';
+ }
+
+}
diff --git a/www/wiki/extensions/Validator/tests/phpunit/MediaWikiTitleValueTest.php b/www/wiki/extensions/Validator/tests/phpunit/MediaWikiTitleValueTest.php
new file mode 100644
index 00000000..3545b788
--- /dev/null
+++ b/www/wiki/extensions/Validator/tests/phpunit/MediaWikiTitleValueTest.php
@@ -0,0 +1,22 @@
+<?php
+
+namespace ParamProcessor\Tests;
+
+use ParamProcessor\MediaWikiTitleValue;
+
+/**
+ * @covers ParamProcessor\MediaWikiTitleValue
+ *
+ * @group Validator
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class MediaWikiTitleValueTest extends \PHPUnit_Framework_TestCase {
+
+ public function testGivenValidPage_getValueWorks( ) {
+ $titleValue = new MediaWikiTitleValue( \Title::newFromText( 'Foobar' ) );
+ $this->assertSame( 'Foobar', $titleValue->getValue()->getFullText() );
+ }
+
+}
diff --git a/www/wiki/extensions/Validator/tests/phpunit/TitleParserTest.php b/www/wiki/extensions/Validator/tests/phpunit/TitleParserTest.php
new file mode 100644
index 00000000..18194c9e
--- /dev/null
+++ b/www/wiki/extensions/Validator/tests/phpunit/TitleParserTest.php
@@ -0,0 +1,43 @@
+<?php
+
+namespace ParamProcessor\Tests;
+
+use ParamProcessor\MediaWikiTitleValue;
+use ParamProcessor\TitleParser;
+
+/**
+ * @group Validator
+ *
+ * @licence GNU GPL v2+
+ * @author Jeroen De Dauw < jeroendedauw@gmail.com >
+ */
+class TitleParserTest extends \PHPUnit_Framework_TestCase {
+
+ /**
+ * @dataProvider validInputProvider
+ */
+ public function testValidInputs( $input, $expected ) {
+ $parser = new TitleParser();
+
+ $this->assertEquals(
+ $expected,
+ $parser->parse( $input )
+ );
+ }
+
+ public function validInputProvider() {
+ $argLists = array();
+
+ $valid = array(
+ 'Foo bar',
+ 'Ohi there!',
+ );
+
+ foreach ( $valid as $value ) {
+ $argLists[] = array( $value, new MediaWikiTitleValue( \Title::newFromText( $value ) ) );
+ }
+
+ return $argLists;
+ }
+
+} \ No newline at end of file
diff --git a/www/wiki/extensions/WikiEditor/README b/www/wiki/extensions/WikiEditor/README
index e50b6951..88051092 100644
--- a/www/wiki/extensions/WikiEditor/README
+++ b/www/wiki/extensions/WikiEditor/README
@@ -1,20 +1,16 @@
-# WikiEditor provides enhancements to the MediaWiki edit page
+WikiEditor provides enhancements to the MediaWiki edit page
-# This extension requires MediaWiki 1.17+ because it makes use of ResourceLoader.
+# This extension requires MediaWiki 1.28 or higher.
-# Example LocalSettings.php additions
+For installation, once the code is copied into your extensions directory, you can load it for your
+wiki by adding to LocalSettings.php the line:
-require_once( "$IP/extensions/WikiEditor/WikiEditor.php" );
+ wfLoadExtensions( "WikiEditor" );
-# Before configuring this extension, see WikiEditor.php and become familiar with the initial state and structure of the
-# $wgWikiEditorFeatures configuration variable. Essentially it's an array of arrays, keyed by feature name, each
-# containing global and user keys with boolean values. "global" indicates that it should be turned on for everyone
-# always, while user indicates that users should be allowed to turn it on or off in their user preferences.
+By default, when installed this extension will be available to all users, and logged-in users can
+disable it from their preferences. If you wish all users to have it, and be unable to disable it,
+add it to $wgHiddenPrefs in your LocalSettings.php:
-# To enable a preference by default but still allow users to disable it in preferences, use something like...
+ $wgHiddenPrefs[] = 'usebetatoolbar';
-$wgDefaultUserOptions['usebetatoolbar'] = 1;
-
-# Release 1.21 removes the $wgWikiEditorToolbarClickTracking config variable
-# and with it support for tracking clicks on WikiEditor features via the
-# ClickTracking extension.
+More can be found on the extension's page: https://www.mediawiki.org/wiki/Extension:WikiEditor
diff --git a/www/wiki/extensions/WikiEditor/composer.json b/www/wiki/extensions/WikiEditor/composer.json
index e59af45c..39ab3b77 100644
--- a/www/wiki/extensions/WikiEditor/composer.json
+++ b/www/wiki/extensions/WikiEditor/composer.json
@@ -1,17 +1,24 @@
{
- "license": "GPL-2.0+",
+ "license": "GPL-2.0-or-later",
"require-dev": {
- "jakub-onderka/php-parallel-lint": "0.9.2",
- "mediawiki/mediawiki-codesniffer": "0.12.0",
- "jakub-onderka/php-console-highlighter": "0.3.2"
+ "jakub-onderka/php-parallel-lint": "1.0.0",
+ "mediawiki/mediawiki-codesniffer": "18.0.0",
+ "jakub-onderka/php-console-highlighter": "0.3.2",
+ "mediawiki/minus-x": "0.3.1",
+ "mediawiki/mediawiki-phan-config": "0.2.0"
},
"scripts": {
"test": [
- "parallel-lint . --exclude vendor",
- "phpcs -p -s"
+ "parallel-lint . --exclude vendor --exclude node_modules",
+ "phpcs -p -s",
+ "minus-x check ."
],
"fix": [
- "phpcbf"
+ "phpcbf",
+ "minus-x fix ."
]
+ },
+ "extra": {
+ "phan-taint-check-plugin": "1.2.0"
}
}
diff --git a/www/wiki/extensions/WikiEditor/extension.json b/www/wiki/extensions/WikiEditor/extension.json
index d604f3cf..498cd54a 100644
--- a/www/wiki/extensions/WikiEditor/extension.json
+++ b/www/wiki/extensions/WikiEditor/extension.json
@@ -10,8 +10,11 @@
],
"url": "https://www.mediawiki.org/wiki/Extension:WikiEditor",
"descriptionmsg": "wikieditor-desc",
- "license-name": "GPL-2.0+",
- "type": "other",
+ "license-name": "GPL-2.0-or-later",
+ "type": "editor",
+ "requires": {
+ "MediaWiki": ">= 1.28.0"
+ },
"MessagesDirs": {
"WikiEditor": [
"i18n"
@@ -47,70 +50,23 @@
]
},
"ResourceModules": {
- "jquery.wikiEditor": {
- "group": "ext.wikiEditor",
- "dependencies": [
- "jquery.wikiEditor.core",
- "jquery.wikiEditor.toolbar",
- "jquery.wikiEditor.dialogs"
- ]
- },
- "jquery.wikiEditor.core": {
+ "ext.wikiEditor": {
"group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.js",
- "styles": "jquery.wikiEditor.less",
- "dependencies": [
- "jquery.client",
- "jquery.textSelection",
- "mediawiki.language"
+ "scripts": [
+ "jquery.wikiEditor.js",
+ "jquery.wikiEditor.toolbar.js",
+ "jquery.wikiEditor.toolbar.config.js",
+ "jquery.wikiEditor.dialogs.js",
+ "jquery.wikiEditor.dialogs.config.js",
+ "ext.wikiEditor.js",
+ "ext.wikiEditor.toolbar.js",
+ "ext.wikiEditor.dialogs.js"
],
- "messages": [
- "wikieditor-wikitext-tab",
- "wikieditor-loading"
- ]
- },
- "jquery.wikiEditor.dialogs": {
- "group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.dialogs.js",
- "styles": "jquery.wikiEditor.dialogs.less",
- "dependencies": [
- "jquery.wikiEditor.core",
- "jquery.wikiEditor.toolbar",
- "jquery.ui.dialog",
- "jquery.ui.button",
- "jquery.ui.draggable",
- "jquery.ui.resizable",
- "jquery.tabIndex"
- ]
- },
- "jquery.wikiEditor.dialogs.config": {
- "group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.dialogs.config.js",
- "styles": "jquery.wikiEditor.dialogs.config.less",
- "dependencies": [
- "jquery.wikiEditor.core",
- "jquery.wikiEditor.dialogs",
- "jquery.wikiEditor.toolbar.i18n",
- "jquery.suggestions",
- "mediawiki.Upload.Dialog",
- "mediawiki.ForeignStructuredUpload.BookletLayout",
- "mediawiki.api",
- "mediawiki.RegExp",
- "mediawiki.Title",
- "mediawiki.jqueryMsg"
- ],
- "messages": [
- "wikieditor-toolbar-tool-file-title",
- "wikieditor-toolbar-file-target",
- "wikieditor-toolbar-file-caption",
- "wikieditor-toolbar-file-size",
- "wikieditor-toolbar-file-float",
- "wikieditor-toolbar-file-default",
- "wikieditor-toolbar-file-format-none",
- "wikieditor-toolbar-file-format",
- "wikieditor-toolbar-tool-file-insert",
- "wikieditor-toolbar-tool-file-cancel",
- "wikieditor-toolbar-tool-file-upload"
+ "styles": [
+ "jquery.wikiEditor.less",
+ "jquery.wikiEditor.toolbar.less",
+ "jquery.wikiEditor.dialogs.less",
+ "jquery.wikiEditor.dialogs.config.less"
],
"templates": {
"dialogInsertFile.html": "templates/dialogInsertFile.html",
@@ -118,49 +74,10 @@
"dialogInsertReference.html": "templates/dialogInsertReference.html",
"dialogInsertTable.html": "templates/dialogInsertTable.html",
"dialogReplace.html": "templates/dialogReplace.html"
- }
- },
- "jquery.wikiEditor.preview": {
- "group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.preview.js",
- "styles": "jquery.wikiEditor.preview.less",
- "dependencies": [
- "jquery.wikiEditor.core",
- "mediawiki.api"
- ]
- },
- "jquery.wikiEditor.publish": {
- "group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.publish.js",
- "dependencies": [
- "jquery.wikiEditor.core",
- "jquery.wikiEditor.dialogs"
- ]
- },
- "jquery.wikiEditor.toolbar": {
- "group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.toolbar.js",
- "styles": "jquery.wikiEditor.toolbar.less",
- "dependencies": [
- "jquery.wikiEditor.core",
- "jquery.wikiEditor.toolbar.i18n",
- "jquery.cookie",
- "jquery.async"
- ]
- },
- "jquery.wikiEditor.toolbar.config": {
- "group": "ext.wikiEditor",
- "scripts": "jquery.wikiEditor.toolbar.config.js",
- "dependencies": [
- "jquery.wikiEditor.core",
- "jquery.wikiEditor.toolbar.i18n",
- "jquery.wikiEditor.toolbar",
- "mediawiki.language.specialCharacters"
- ]
- },
- "jquery.wikiEditor.toolbar.i18n": {
- "group": "ext.wikiEditor",
+ },
"messages": [
+ "wikieditor-wikitext-tab",
+ "wikieditor-loading",
"wikieditor-toolbar-loading",
"wikieditor-toolbar-tool-bold",
"wikieditor-toolbar-tool-bold-example",
@@ -331,107 +248,100 @@
"wikieditor-toolbar-help-content-signature-result",
"wikieditor-toolbar-help-content-indent-description",
"wikieditor-toolbar-help-content-indent-syntax",
- "wikieditor-toolbar-help-content-indent-result"
- ]
- },
- "ext.wikiEditor": {
- "group": "ext.wikiEditor",
+ "wikieditor-toolbar-help-content-indent-result",
+ "wikieditor-toolbar-tool-file-title",
+ "wikieditor-toolbar-file-target",
+ "wikieditor-toolbar-file-caption",
+ "wikieditor-toolbar-file-size",
+ "wikieditor-toolbar-file-float",
+ "wikieditor-toolbar-file-default",
+ "wikieditor-toolbar-file-format-none",
+ "wikieditor-toolbar-file-format",
+ "wikieditor-toolbar-tool-file-insert",
+ "wikieditor-toolbar-tool-file-cancel",
+ "wikieditor-toolbar-tool-file-upload"
+ ],
"dependencies": [
- "ext.wikiEditor.core",
- "ext.wikiEditor.toolbar",
- "ext.wikiEditor.dialogs"
+ "jquery.async",
+ "jquery.cookie",
+ "jquery.suggestions",
+ "jquery.tabIndex",
+ "jquery.textSelection",
+ "jquery.ui.button",
+ "jquery.ui.dialog",
+ "jquery.ui.draggable",
+ "jquery.ui.resizable",
+ "mediawiki.api",
+ "mediawiki.ForeignStructuredUpload.BookletLayout",
+ "mediawiki.jqueryMsg",
+ "mediawiki.language.specialCharacters",
+ "mediawiki.language",
+ "mediawiki.RegExp",
+ "mediawiki.Title",
+ "mediawiki.Upload.Dialog",
+ "mediawiki.user",
+ "oojs-ui.styles.icons-content",
+ "oojs-ui.styles.icons-editing-advanced",
+ "oojs-ui.styles.icons-editing-core",
+ "oojs-ui.styles.icons-editing-list",
+ "oojs-ui.styles.icons-editing-styling",
+ "oojs-ui.styles.icons-media"
]
},
"ext.wikiEditor.styles": {
"group": "ext.wikiEditor",
"styles": "ext.wikiEditor.toolbar.styles.less"
},
- "ext.wikiEditor.core": {
- "group": "ext.wikiEditor",
- "scripts": "ext.wikiEditor.js",
- "dependencies": [
- "jquery.wikiEditor.core",
- "mediawiki.user"
- ]
+ "ext.wikiEditor.toolbar": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
},
"ext.wikiEditor.dialogs": {
- "group": "ext.wikiEditor",
- "scripts": "ext.wikiEditor.dialogs.js",
- "dependencies": [
- "ext.wikiEditor.core",
- "ext.wikiEditor.toolbar",
- "jquery.wikiEditor.dialogs",
- "jquery.wikiEditor.dialogs.config"
- ]
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
},
- "ext.wikiEditor.preview": {
- "group": "ext.wikiEditor",
- "scripts": "ext.wikiEditor.preview.js",
- "dependencies": [
- "ext.wikiEditor.core",
- "jquery.wikiEditor.preview"
- ],
- "messages": [
- "wikieditor-preview-tab",
- "wikieditor-preview-changes-tab",
- "wikieditor-preview-loading"
- ]
+ "ext.wikiEditor.core": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
},
- "ext.wikiEditor.publish": {
- "group": "ext.wikiEditor",
- "scripts": "ext.wikiEditor.publish.js",
- "dependencies": [
- "ext.wikiEditor.core",
- "jquery.wikiEditor.publish"
- ],
- "messages": [
- "wikieditor-publish-button-publish",
- "wikieditor-publish-button-cancel",
- "wikieditor-publish-dialog-title",
- "wikieditor-publish-dialog-summary",
- "wikieditor-publish-dialog-minor",
- "wikieditor-publish-dialog-watch",
- "wikieditor-publish-dialog-publish",
- "wikieditor-publish-dialog-goback"
- ]
+ "jquery.wikiEditor": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
},
- "ext.wikiEditor.toolbar": {
- "group": "ext.wikiEditor",
- "scripts": "ext.wikiEditor.toolbar.js",
- "dependencies": [
- "ext.wikiEditor.core",
- "jquery.wikiEditor.toolbar",
- "jquery.wikiEditor.toolbar.config"
- ]
+ "jquery.wikiEditor.core": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
+ },
+ "jquery.wikiEditor.dialogs": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
+ },
+ "jquery.wikiEditor.dialogs.config": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
+ },
+ "jquery.wikiEditor.toolbar": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
+ },
+ "jquery.wikiEditor.toolbar.config": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
+ },
+ "jquery.wikiEditor.toolbar.i18n": {
+ "dependencies": "ext.wikiEditor",
+ "deprecated": "Please use 'ext.wikiEditor' instead."
}
},
"ResourceFileModulePaths": {
"localBasePath": "modules",
"remoteExtPath": "WikiEditor/modules"
},
- "config": {
- "WikiEditorFeatures": {
- "toolbar": {
- "global": false,
- "user": true
- },
- "dialogs": {
- "global": false,
- "user": true
- },
- "preview": {
- "global": false,
- "user": true
- },
- "publish": {
- "global": false,
- "user": true
- },
- "_merge_strategy": "array_plus_2d"
- }
+ "DefaultUserOptions": {
+ "usebetatoolbar": true
},
"AutoloadClasses": {
- "WikiEditorHooks": "WikiEditor.hooks.php"
+ "WikiEditorHooks": "includes/WikiEditorHooks.php"
},
"manifest_version": 1
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/af.json b/www/wiki/extensions/WikiEditor/i18n/af.json
index 6b3c9195..a289d8b9 100644
--- a/www/wiki/extensions/WikiEditor/i18n/af.json
+++ b/www/wiki/extensions/WikiEditor/i18n/af.json
@@ -14,23 +14,9 @@
"wikieditor-desc": "Voorsien 'n uitbreibare wikiteks-verwerker en modules met bykomende funksies",
"wikieditor-wikitext-tab": "Wikiteks",
"wikieditor-loading": "Laai tans",
- "wikieditor-preview-preference": "Wysig en voorskou langs mekaar",
- "wikieditor-preview-tab": "Voorskou",
- "wikieditor-preview-changes-tab": "Wysigings",
- "wikieditor-preview-loading": "Besig om te laai...",
- "wikieditor-publish-preference": "Aktiveer stap-vir-stap publisering",
- "wikieditor-publish-button-publish": "Publiseer",
- "wikieditor-publish-button-cancel": "Kanselleer",
- "wikieditor-publish-dialog-title": "Publiseer na {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Wysigingsopsomming (beskryf kortliks wat u verander het):",
- "wikieditor-publish-dialog-minor": "Klein wysiging",
- "wikieditor-publish-dialog-watch": "Hou die bladsy dop",
- "wikieditor-publish-dialog-publish": "Publiseer",
- "wikieditor-publish-dialog-goback": "Terug",
"wikieditor-toolbar": "Wysigingswerksbalk",
"wikieditor-toolbar-desc": "Wysigingsbalk met verhoogde bruikbaarheid",
"wikieditor-toolbar-preference": "Gebruik gevorderde redigeringsbalk",
- "wikieditor-toolbar-dialogs-preference": "Aktiveer dialoog vir die byvoeging van skakels, tabelle en meer",
"wikieditor-toolbar-loading": "Besig om te laai...",
"wikieditor-toolbar-tool-bold": "Vetdruk",
"wikieditor-toolbar-tool-bold-example": "Vetgedrukte teks",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ais.json b/www/wiki/extensions/WikiEditor/i18n/ais.json
index 3f8947ce..33bd3e81 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ais.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ais.json
@@ -6,30 +6,30 @@
"Benel"
]
},
+ "wikieditor": "tapabaw Wiki a sulit mikawaway-kalumyiti taypuolayta",
+ "wikieditor-desc": "nipabeli Wiki sulit mikawaway-kalumyiti taypuolayta sacunusan sasahicaan atu mahizaay a bacu-saupu",
+ "wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "miasip henay ayza…",
- "wikieditor-preview-preference": "miwawah pulung-silsil pataayaway miazih",
- "wikieditor-preview-changes-tab": "misumad",
- "wikieditor-preview-loading": "miasip henay ayza…",
- "wikieditor-publish-button-cancel": "palawpes",
- "wikieditor-publish-dialog-minor": "cayka yadah ku misumad",
- "wikieditor-publish-dialog-watch": "miazih tuyni kasabelih",
- "wikieditor-publish-dialog-publish": "patiyak",
- "wikieditor-publish-dialog-goback": "tatiku",
"wikieditor-toolbar": "mikawaway-kalumyiti sakaluk a silsil",
+ "wikieditor-toolbar-desc": "pamikawaway-kalumyiti kasabelih kadayumay a kasabelih sakaluk-silsil",
"wikieditor-toolbar-preference": "miwawah tapabaw mikawaway-kalumyiti sakaluk layalay",
"wikieditor-toolbar-loading": "miasip henay ayza…",
"wikieditor-toolbar-tool-bold": "kibetulay",
"wikieditor-toolbar-tool-bold-example": "kibetulay a sulit",
"wikieditor-toolbar-tool-italic": "tukenihay",
- "wikieditor-toolbar-tool-italic-example": "tukenihay nisulit",
+ "wikieditor-toolbar-tool-italic-example": "tukenihay a sulit",
"wikieditor-toolbar-tool-ilink": "labu-labu misiket",
"wikieditor-toolbar-tool-ilink-example": "misiket satangahan a sulit",
+ "wikieditor-toolbar-tool-xlink": "hekal-hekal misiket (amana katawal saka http:// paangangan)",
+ "wikieditor-toolbar-tool-xlink-example": "http://www.example.com misiket satangah",
+ "wikieditor-toolbar-tool-link": "masasiket",
"wikieditor-toolbar-tool-link-title": "paheceken tu masasiket",
+ "wikieditor-toolbar-tool-link-int": "misasiket Wiki kasabelih",
"wikieditor-toolbar-tool-link-int-target": "papatuzu’an a kasabelih acasa calay-puenengan(wangcan):",
"wikieditor-toolbar-tool-link-int-target-tooltip": "kasabelih satangahan acasa URL",
"wikieditor-toolbar-tool-link-int-text": "paazih ku sulit:",
"wikieditor-toolbar-tool-link-int-text-tooltip": "sapaazih a cudad",
- "wikieditor-toolbar-tool-link-ext": "masasiket tu hekalay calay-belih(wangyi)",
+ "wikieditor-toolbar-tool-link-ext": "masasiket tu hekalay calay-kabelih(wangyei)",
"wikieditor-toolbar-tool-link-ext-target": "misiket tu calay-puenengan(wangzi):",
"wikieditor-toolbar-tool-link-ext-text": "masasiket tu sulit:",
"wikieditor-toolbar-tool-link-insert": "paheceken tu masasiket",
@@ -38,8 +38,12 @@
"wikieditor-toolbar-tool-link-int-target-status-notexists": "kasabelih nayai’ tu",
"wikieditor-toolbar-tool-link-int-target-status-invalid": "la’cusay a satangahan",
"wikieditor-toolbar-tool-link-int-target-status-external": "masasiket tu hekal",
+ "wikieditor-toolbar-tool-link-int-target-status-loading": "imahina mikinsa kasabelih izaw tu haw...",
"wikieditor-toolbar-tool-link-int-target-status-disambig": "caayay kalecad azihen a kasabilih",
+ "wikieditor-toolbar-tool-link-int-invalid": "matuzu’ay satangahan la’cus.",
+ "wikieditor-toolbar-tool-link-lookslikeinternal": "namisulitan nu misu tu URL hakay pasayza i cacay nu Wiki a kasabelih.\nmaydih kisu haw miliyaw tu labu’ay masasiket?",
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "masasiket tu hekal",
+ "wikieditor-toolbar-tool-link-empty": "caay henay kisu pacumud amisasiketay a canacanan.",
"wikieditor-toolbar-tool-file": "nicunusay a tangan",
"wikieditor-toolbar-tool-file-example": "tinaku.jpg",
"wikieditor-toolbar-tool-file-title": "paheceken tu tangan",
@@ -63,12 +67,17 @@
"wikieditor-toolbar-section-advanced": "tapabaw",
"wikieditor-toolbar-tool-heading": "satangahan",
"wikieditor-toolbar-tool-heading-1": "satangahan 1",
+ "wikieditor-toolbar-tool-heading-2": "satangahan 2",
"wikieditor-toolbar-tool-heading-3": "satangahan 3",
+ "wikieditor-toolbar-tool-heading-4": "satangahan 4",
"wikieditor-toolbar-tool-heading-5": "satangahan 5",
+ "wikieditor-toolbar-tool-heading-example": "satangahan a sulit",
"wikieditor-toolbar-group-format": "kese",
"wikieditor-toolbar-tool-ulist-example": "tatebanan nu nisulitan piazihan tu sulit kasacacay",
"wikieditor-toolbar-tool-olist": "banggu nu piazihan tu sulit",
"wikieditor-toolbar-tool-olist-example": "kasacacay nu banggu piazihan tu sulit",
+ "wikieditor-toolbar-tool-nowiki": "caay pisaungay Wiki kesehwa kamu-kilul",
+ "wikieditor-toolbar-tool-nowiki-example": "pacucuk caayay kesehwaay a cudad",
"wikieditor-toolbar-tool-redirect": "miliyaw patatuzu’",
"wikieditor-toolbar-tool-redirect-example": "pabalucu’an kasabelih",
"wikieditor-toolbar-tool-big": "patabaki(micuwat)",
@@ -76,11 +85,14 @@
"wikieditor-toolbar-tool-small": "sukep",
"wikieditor-toolbar-tool-small-example": "sukepen tu sulit",
"wikieditor-toolbar-tool-superscript": "ipabaway a sawantan",
+ "wikieditor-toolbar-tool-superscript-example": "pabaw-bacu sulit",
"wikieditor-toolbar-tool-subscript": "isasa’ay a bacu",
"wikieditor-toolbar-tool-subscript-example": "sulit nu isasa’ay a bacu",
"wikieditor-toolbar-tool-gallery": "sulu nu zunga",
+ "wikieditor-toolbar-tool-gallery-example": "Example.jpg|satangahan 1\nExample.jpg|satangahan 2",
"wikieditor-toolbar-tool-newline": "pazumaan tu tusil",
"wikieditor-toolbar-tool-table": "sapat nu sulit",
+ "wikieditor-toolbar-tool-table-example-old": "-\n! satangahan 1\n! satangahan 2\n! satangahan 3\n|-\n| silsil 1, sapisuped-haku1\n| silsil 1, sapisuped-haku2\n| silsil 1, sapisuped-haku3\n|-\n| silsil 2, sapisuped-haku1\n| silsil 2, sapisuped-haku2\n| silsil 2, sapisuped-haku3",
"wikieditor-toolbar-tool-table-example-cell-text": "u sulit nu sapisuped-haku",
"wikieditor-toolbar-tool-table-example-header": "satangahan a sulit",
"wikieditor-toolbar-tool-table-title": "paheceken tu sapat nu sulit",
@@ -93,6 +105,9 @@
"wikieditor-toolbar-tool-table-preview": "pataayaway miazih",
"wikieditor-toolbar-tool-table-insert": "pacucuk",
"wikieditor-toolbar-tool-table-cancel": "palawpes",
+ "wikieditor-toolbar-tool-table-toomany": "tina kasasukamu a atilad la’cus picucuk matabesiw $1 {{PLURAL:$1|sapisuped-haku}}a sapat nu sulit.",
+ "wikieditor-toolbar-tool-table-invalidnumber": "namasulit numisuay a silsil-sulyang saca langat-sulyang la’cus.",
+ "wikieditor-toolbar-tool-table-zero": "amana kisu pacucuk cacay inayi’-silsil saca inayi’-langat a sapat nu sulit.",
"wikieditor-toolbar-tool-replace-search": "kilim:",
"wikieditor-toolbar-tool-replace-replace": "mibalic atu paliyun ni:",
"wikieditor-toolbar-tool-replace-case": "u sulit manakanca malalanep",
@@ -101,6 +116,10 @@
"wikieditor-toolbar-tool-replace-button-replace": "balic",
"wikieditor-toolbar-tool-replace-button-replaceall": "hamin mibalic",
"wikieditor-toolbar-tool-replace-close": "edeben",
+ "wikieditor-toolbar-tool-replace-nomatch": "caay katepa amahicahica tu matatungus kasacacay.",
+ "wikieditor-toolbar-tool-replace-success": "malaheci tu {{PLURAL:$1|balic}}.",
+ "wikieditor-toolbar-tool-replace-emptysearch": "inayi’ kisu misulit maydih mikilimay a lacul.",
+ "wikieditor-toolbar-tool-replace-invalidregex": "tatungusay pakatineng-zateng nasuliten nu misu la’cus:$1",
"wikieditor-toolbar-section-characters": "sazumaay azihen a sulit",
"wikieditor-toolbar-section-help": "buhci tu kamu",
"wikieditor-toolbar-help-heading-description": "sapuelac",
@@ -109,25 +128,58 @@
"wikieditor-toolbar-help-page-link": "masasiket",
"wikieditor-toolbar-help-page-heading": "satangahan",
"wikieditor-toolbar-help-page-list": "piazihan tu sulit",
+ "wikieditor-toolbar-help-page-file": "tangan",
"wikieditor-toolbar-help-page-reference": "miazih tu tatenga’ay saangangan",
"wikieditor-toolbar-help-page-discussion": "matatengil",
"wikieditor-toolbar-help-content-italic-description": "tukenihay",
- "wikieditor-toolbar-help-content-italic-syntax": "\"tukenihay nisulit\"",
+ "wikieditor-toolbar-help-content-italic-syntax": "\"tukenihay a sulit\"",
+ "wikieditor-toolbar-help-content-italic-result": "<em>tukenihay nisulit</em>",
"wikieditor-toolbar-help-content-bold-description": "kibetulay",
"wikieditor-toolbar-help-content-bold-syntax": "'''kibetulay a sulit'''",
+ "wikieditor-toolbar-help-content-bold-result": "<strong>kibetulay a sulit</strong>",
"wikieditor-toolbar-help-content-bolditalic-description": "kibetulay tukenihay nisulit",
+ "wikieditor-toolbar-help-content-bolditalic-syntax": "'''' kibetulay tukenihay a sulit '''''",
+ "wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>kibetulay tukenihay nisulit</em></strong>",
"wikieditor-toolbar-help-content-ilink-description": "labu-labu misiket",
+ "wikieditor-toolbar-help-content-ilink-syntax": "[[kasabelih satangahan]]<br />[[kasabelih satangahan|masasiket aazihen-paya]]",
+ "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>kasabelih satangahan</a><br /><a href='#'>masasiket aazihen-paya</a>",
"wikieditor-toolbar-help-content-xlink-description": "masasiket tu hekal",
- "wikieditor-toolbar-help-content-heading2-description": "saka 2 saselal a satangahan",
- "wikieditor-toolbar-help-content-heading3-description": "saka 3 saselal a satangahan",
- "wikieditor-toolbar-help-content-heading4-description": "saka 4 saselal a satangahan",
- "wikieditor-toolbar-help-content-heading5-description": "saka 5 saselal a satangahan",
+ "wikieditor-toolbar-help-content-xlink-syntax": "[http://www.example.org masasiket aazihen-paya ]<br />[http://www.example.org]<br />http://www.example.org",
+ "wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'> masasiket aazihen-paya </a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.example.org</a>",
+ "wikieditor-toolbar-help-content-heading2-description": "saka 2 tindud satangahan",
+ "wikieditor-toolbar-help-content-heading2-syntax": "==satangahan a sulit ==",
+ "wikieditor-toolbar-help-content-heading2-result": "<h2>satangahan a sulit</h2>",
+ "wikieditor-toolbar-help-content-heading3-description": "saka 3 tindud satangahan",
+ "wikieditor-toolbar-help-content-heading3-syntax": "=== satangahan a sulit ===",
+ "wikieditor-toolbar-help-content-heading3-result": "<h3>satangahan a sulit</h3>",
+ "wikieditor-toolbar-help-content-heading4-description": "saka 4 tindud satangahan",
+ "wikieditor-toolbar-help-content-heading4-syntax": "==== satangahan a sulit ====",
+ "wikieditor-toolbar-help-content-heading4-result": "<h4>satangahan a sulit</h4>",
+ "wikieditor-toolbar-help-content-heading5-description": "saka 5 tindud satangahan",
+ "wikieditor-toolbar-help-content-heading5-syntax": "===== satangahan a sulit =====",
+ "wikieditor-toolbar-help-content-heading5-result": "<h5>satangahan a sulit</h5>",
+ "wikieditor-toolbar-help-content-ulist-syntax": "* piazihan-tu-sulit kasacacay<br />* piazihan-tu-sulit kasacacay",
"wikieditor-toolbar-help-content-olist-description": "banggu nu piazihan tu sulit",
+ "wikieditor-toolbar-help-content-olist-syntax": "# piazihan-tu-sulit kasacacay<br /># piazihan-tu-sulit kasacacay",
+ "wikieditor-toolbar-help-content-olist-result": "<ol><li>piazihan tu sulit kasacacay</li><li>piazihan tu sulit kasacacay</li></ol>",
"wikieditor-toolbar-help-content-file-description": "nicunusay a tangan",
+ "wikieditor-toolbar-help-content-file-syntax": "[[$1:Example.png|$2|$3]]",
"wikieditor-toolbar-help-content-file-caption": "satangahan a sulit",
"wikieditor-toolbar-help-content-reference-description": "miazih tu tatenga’ay nasulitan",
+ "wikieditor-toolbar-help-content-reference-syntax": "kasabelih a sulit.\n&lt;ref&gt;[http://www.example.org masasiket sulit], micunus ku sulit. &lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-reference-result": "kasabelih sulit.<sup><a href='#'>[1]</a></sup>",
+ "wikieditor-toolbar-help-content-named-reference-description": "mapanganganay a miazih tu tatenga’ay nasulitan",
+ "wikieditor-toolbar-help-content-named-reference-syntax": "kasabelih sulit. &lt;ref name=\"test\"&gt;[http://www.example.org Link text]&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-named-reference-result": "kasabelih sulit.<sup><a href='#'>[2]</a></sup>",
+ "wikieditor-toolbar-help-content-rereference-description": "misaliyaw pisaungay malecaday a miazih tu tatenga’ay saangangan",
+ "wikieditor-toolbar-help-content-rereference-result": "kasabelih sulit.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "paazih miazih tu tatenga’ay nay",
+ "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b><a rel='nofollow' title='http://www.example.org' class='external text' href='#'> masasiketay a sulit </a>,nicunus a kawaw sulit。</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b><a rel='nofollow' title='http://www.example.org' class='external text' href='#'> masasiketay a sulit </a></li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "sulitan a ngangan atu tuki",
+ "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'> misaungayay a kalungangan </a> (<a href='#' title='$2:Username'> sasukamu </a>) 15:54, 10 June 2009 (UTC)",
"wikieditor-toolbar-help-content-signature-description": "sulitan a ngangan",
- "wikieditor-toolbar-help-content-indent-description": "kitiw"
+ "wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'> misaungayay a kalungangan </a> (<a href='#' title='$2:Username'> sasukamu </a>)",
+ "wikieditor-toolbar-help-content-indent-description": "kitiw",
+ "wikieditor-toolbar-help-content-indent-syntax": "habutud cudad <br />:kitiw-silsil cudad <br />::kitiw-silsil cudad",
+ "wikieditor-toolbar-help-content-indent-result": "habutud sulit <dl><dd>satisil sulit <dl><dd>satisil sulit </dd></dl></dd></dl>"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/aln.json b/www/wiki/extensions/WikiEditor/i18n/aln.json
index 011eba00..7ad12c64 100644
--- a/www/wiki/extensions/WikiEditor/i18n/aln.json
+++ b/www/wiki/extensions/WikiEditor/i18n/aln.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Siguron një ndërfaqe të vazhdohet redaktimi wikitext dhe module shumë me metrazh të siguruar",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Ngarkim",
- "wikieditor-preview-preference": "Aktivizo-krah për krah preview",
- "wikieditor-preview-tab": "Preview",
- "wikieditor-preview-changes-tab": "Ndryshimet",
- "wikieditor-preview-loading": "Loading ...",
- "wikieditor-publish-preference": "Aktivizo-hap pas hapi botuese",
- "wikieditor-publish-button-publish": "Publikoj",
- "wikieditor-publish-button-cancel": "Anuloj",
- "wikieditor-publish-dialog-title": "Publikimi në {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "përmbledhje Edit (përshkruaj shkurtimisht ndryshimet që keni bërë):",
- "wikieditor-publish-dialog-minor": "Redaktim i vogël",
- "wikieditor-publish-dialog-watch": "Watch këtë faqe",
- "wikieditor-publish-dialog-publish": "Publikoj",
- "wikieditor-publish-dialog-goback": "Kthehem",
"wikieditor-toolbar": "Editing toolbar",
"wikieditor-toolbar-desc": "toolbar Redakto faqe me të përdorshmërisë zgjeruar",
"wikieditor-toolbar-preference": "Lejo redaktimin zgjeruar toolbar",
- "wikieditor-toolbar-dialogs-preference": "dialogs Aktivizo për futjen e lidhjeve, tavolina dhe më shumë",
"wikieditor-toolbar-loading": "Loading ...",
"wikieditor-toolbar-tool-bold": "Guximtar",
"wikieditor-toolbar-tool-bold-example": "Tekst i trashë",
diff --git a/www/wiki/extensions/WikiEditor/i18n/an.json b/www/wiki/extensions/WikiEditor/i18n/an.json
index f9ae637f..f0cf4d2d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/an.json
+++ b/www/wiki/extensions/WikiEditor/i18n/an.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Proporciona una interficie extensible de modificación de wikitexto y quantos modulos de funcionalidatz",
"wikieditor-wikitext-tab": "Wikitexto",
"wikieditor-loading": "Cargando",
- "wikieditor-preview-preference": "Activar a previsualización costau a costau",
- "wikieditor-preview-tab": "Previsualizar",
- "wikieditor-preview-changes-tab": "Cambios",
- "wikieditor-preview-loading": "Cargando...",
- "wikieditor-publish-preference": "Activar a publicación trango a trango",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Cancelar",
- "wikieditor-publish-dialog-title": "Publicar en {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resumen d'edición (describa breument os cambios que ha feito):",
- "wikieditor-publish-dialog-minor": "Edición menor",
- "wikieditor-publish-dialog-watch": "Cosirar ista pachina",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Tornar",
"wikieditor-toolbar": "Barra de ferramientas d'edición",
"wikieditor-toolbar-desc": "Barra de ferramientas d'edición con usabilidat amillorada",
"wikieditor-toolbar-preference": "Activar a barra de ferramientas d'edición amillorada",
- "wikieditor-toolbar-dialogs-preference": "Activar as caixas de dialogos ta ficar vinclos, tablas y atros",
"wikieditor-toolbar-loading": "Cargando...",
"wikieditor-toolbar-tool-bold": "Negreta",
"wikieditor-toolbar-tool-bold-example": "Texto en negreta",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ar.json b/www/wiki/extensions/WikiEditor/i18n/ar.json
index a2c77a42..926e2e15 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ar.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ar.json
@@ -18,26 +18,12 @@
]
},
"wikieditor": "الواجهة المتقدمة لتعديل نص ويكي",
- "wikieditor-desc": "يوفر واجهة تعديل نص ويكي قابلة للتمديد والعديد من الوحدات التي توفر المزايا",
+ "wikieditor-desc": "يوفر واجهة تعديل نص ويكي قابلة للتمديد",
"wikieditor-wikitext-tab": "نص الويكي",
"wikieditor-loading": "تحميل...",
- "wikieditor-preview-preference": "تفعيل المعاينة جنبا بجنب",
- "wikieditor-preview-tab": "معاينة",
- "wikieditor-preview-changes-tab": "تغييرات",
- "wikieditor-preview-loading": "تحميل...",
- "wikieditor-publish-preference": "تفعيل النشر خطوة بخطوة",
- "wikieditor-publish-button-publish": "انشر",
- "wikieditor-publish-button-cancel": "إلغاء",
- "wikieditor-publish-dialog-title": "انشر في {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "ملخص التعديل (اشرح باختصار التغييرات التي أجريتها):",
- "wikieditor-publish-dialog-minor": "تعديل طفيف",
- "wikieditor-publish-dialog-watch": "راقب هذه الصفحة",
- "wikieditor-publish-dialog-publish": "انشر",
- "wikieditor-publish-dialog-goback": "ارجع",
"wikieditor-toolbar": "شريط أدوات التحرير",
"wikieditor-toolbar-desc": "شريط تحرير الصفحات مع تحسين الاستخدامية",
"wikieditor-toolbar-preference": "تفعيل شريط أدوات التحرير المحسن",
- "wikieditor-toolbar-dialogs-preference": "تفعيل حوارات إدراج الوصلات والجداول وخاصية البحث والاستبدال",
"wikieditor-toolbar-loading": "تحميل...",
"wikieditor-toolbar-tool-bold": "غليظ",
"wikieditor-toolbar-tool-bold-example": "نص غليظ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/arc.json b/www/wiki/extensions/WikiEditor/i18n/arc.json
index ba1d7104..72deb25e 100644
--- a/www/wiki/extensions/WikiEditor/i18n/arc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/arc.json
@@ -5,11 +5,6 @@
"Michaelovic"
]
},
- "wikieditor-preview-tab": "ܚܝܪܐ ܩܕܡܝܐ",
- "wikieditor-preview-changes-tab": "ܫܘܚܠܦ̈ܐ",
- "wikieditor-publish-button-cancel": "ܒܛܘܠ",
- "wikieditor-publish-dialog-minor": "ܫܘܚܠܦܐ ܙܥܘܪܐ",
- "wikieditor-publish-dialog-watch": "ܪܗܝ ܦܐܬܐ ܗܕܐ",
"wikieditor-toolbar-tool-bold": "ܥܒܝܬܐ",
"wikieditor-toolbar-tool-bold-example": "ܟܬܒܬܐ ܥܒܝܬܐ",
"wikieditor-toolbar-tool-italic": "ܦܠܝܡܬܐ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/arz.json b/www/wiki/extensions/WikiEditor/i18n/arz.json
index d63285e0..b73cada9 100644
--- a/www/wiki/extensions/WikiEditor/i18n/arz.json
+++ b/www/wiki/extensions/WikiEditor/i18n/arz.json
@@ -10,19 +10,6 @@
"wikieditor-desc": "بيدّى interface بتاع wikitext بينفع يتكبّر و modules كتيره بتنفع تعمل مميزات",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "بيلوّد",
- "wikieditor-preview-preference": "شغّل الپروڤه بتاعة الجنب مع جنب",
- "wikieditor-preview-tab": "پروڤه",
- "wikieditor-preview-changes-tab": "تغييرات",
- "wikieditor-preview-loading": "بيلوّد...",
- "wikieditor-publish-preference": "شغل النشر واحده بواحده",
- "wikieditor-publish-button-publish": "انشر",
- "wikieditor-publish-button-cancel": "كانسل",
- "wikieditor-publish-dialog-title": "انشر فى {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "ملخص التعديل (اشرح بإختصار التغييرات اللى عملتها):",
- "wikieditor-publish-dialog-minor": "تعديل صغير",
- "wikieditor-publish-dialog-watch": "راقب الصفحه دى",
- "wikieditor-publish-dialog-publish": "انشر",
- "wikieditor-publish-dialog-goback": "ارجع",
"wikieditor-toolbar": "شريط عدّة التحرير",
"wikieditor-toolbar-desc": "عدّل صفحة العدّة بالenhanced usability",
"wikieditor-toolbar-loading": "بتلوّد...",
diff --git a/www/wiki/extensions/WikiEditor/i18n/as.json b/www/wiki/extensions/WikiEditor/i18n/as.json
index b74a8092..0b8fa416 100644
--- a/www/wiki/extensions/WikiEditor/i18n/as.json
+++ b/www/wiki/extensions/WikiEditor/i18n/as.json
@@ -13,23 +13,9 @@
"wikieditor-desc": "এখন বহলাব পৰা ৱিকিপাঠ্য সম্পাদনা ইণ্টাৰফে'চ আৰু বহু বৈশিষ্টসম্পন্ন মডিউল প্ৰদান কৰে",
"wikieditor-wikitext-tab": "ৱিকিপাঠ্য",
"wikieditor-loading": "ল'ড হৈ আছে…",
- "wikieditor-preview-preference": "ওচৰা-ওচৰি প্ৰাক্‌দৰ্শন সক্ৰিয় কৰক",
- "wikieditor-preview-tab": "প্রাকদর্শন",
- "wikieditor-preview-changes-tab": "পৰিবৰ্তনসমূহ",
- "wikieditor-preview-loading": "ল'ড হৈ আছে…",
- "wikieditor-publish-preference": "ধাপে ধাপে প্ৰকাশ কৰা সক্ৰিয় কৰক",
- "wikieditor-publish-button-publish": "প্ৰকাশ কৰক",
- "wikieditor-publish-button-cancel": "বাতিল কৰক",
- "wikieditor-publish-dialog-title": "{{SITENAME}} ত প্ৰকাশ কৰক",
- "wikieditor-publish-dialog-summary": "সম্পাদনা সাৰাংশ (আপুনি কি পৰিৱর্তন কৰিছে সেই বিষয়ে অলপ লিখক):",
- "wikieditor-publish-dialog-minor": "অগুৰুত্বপূৰ্ণ সম্পাদনা",
- "wikieditor-publish-dialog-watch": "এই পৃষ্ঠাটো লক্ষ্য কৰক",
- "wikieditor-publish-dialog-publish": "প্ৰকাশ কৰক",
- "wikieditor-publish-dialog-goback": "পাছলৈ যাওক",
"wikieditor-toolbar": "সম্পাদনা টুলবাৰ",
"wikieditor-toolbar-desc": "অধিক ব্যৱহাৰযোগ্য সম্পাদনা পৃষ্ঠাৰ টুলবাৰ",
"wikieditor-toolbar-preference": "শক্তিশালী সম্পাদনা টুলবাৰ সক্ৰিয় কৰক",
- "wikieditor-toolbar-dialogs-preference": "লিংক, টেবল আৰু অধিক বস্তু সংযোজনৰ বাবে ডায়লগ সক্ৰিয় কৰক",
"wikieditor-toolbar-loading": "ল'ড হৈ আছে…",
"wikieditor-toolbar-tool-bold": "গাঢ়",
"wikieditor-toolbar-tool-bold-example": "গাঢ় পাঠ্য",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ast.json b/www/wiki/extensions/WikiEditor/i18n/ast.json
index 1b6f29f8..5d23a880 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ast.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ast.json
@@ -7,26 +7,12 @@
]
},
"wikieditor": "Interfaz avanzada d'edición de testu wiki",
- "wikieditor-desc": "Ufre una interfaz estensible d'edición de testu wiki y munchos módulos de funciones",
+ "wikieditor-desc": "Ufre una interfaz avanzada y estensible d'edición de testu wiki",
"wikieditor-wikitext-tab": "Testu wiki",
"wikieditor-loading": "Cargando...",
- "wikieditor-preview-preference": "Activar la vista previa comparativa",
- "wikieditor-preview-tab": "Vista previa",
- "wikieditor-preview-changes-tab": "Cambios",
- "wikieditor-preview-loading": "Cargando...",
- "wikieditor-publish-preference": "Activar la publicación pasu a pasu",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Encaboxar",
- "wikieditor-publish-dialog-title": "Publicar en {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resume d'edición (describe de mou curtiu los cambios que ficisti):",
- "wikieditor-publish-dialog-minor": "Edición menor",
- "wikieditor-publish-dialog-watch": "Vixilar esta páxina",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Volver",
"wikieditor-toolbar": "Editando la barra de ferramientes",
"wikieditor-toolbar-desc": "Barra de ferramientes de la páxina d'edición con usabilidá enantada",
"wikieditor-toolbar-preference": "Activar a barra d'edición enantada",
- "wikieditor-toolbar-dialogs-preference": "Activar los asistentes p'amestar enllaces y tables, y tamién la función de guetar y trocar",
"wikieditor-toolbar-loading": "Cargando...",
"wikieditor-toolbar-tool-bold": "Negrina",
"wikieditor-toolbar-tool-bold-example": "Testu en negrina",
diff --git a/www/wiki/extensions/WikiEditor/i18n/az.json b/www/wiki/extensions/WikiEditor/i18n/az.json
index e517706b..859c4f4d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/az.json
+++ b/www/wiki/extensions/WikiEditor/i18n/az.json
@@ -13,15 +13,6 @@
},
"wikieditor-wikitext-tab": "Vikimətn",
"wikieditor-loading": "Yüklə",
- "wikieditor-preview-tab": "Sınaq görüntüsü",
- "wikieditor-preview-changes-tab": "Dəyişikliklər",
- "wikieditor-preview-loading": "Yüklənir…",
- "wikieditor-publish-button-publish": "Yeniləmə",
- "wikieditor-publish-button-cancel": "Ləğv et",
- "wikieditor-publish-dialog-minor": "Kiçik dəyişiklik",
- "wikieditor-publish-dialog-watch": "Bu səhifəni izlə",
- "wikieditor-publish-dialog-publish": "Publish",
- "wikieditor-publish-dialog-goback": "Geriyə",
"wikieditor-toolbar-loading": "Yüklənir…",
"wikieditor-toolbar-tool-bold": "Qalın",
"wikieditor-toolbar-tool-bold-example": "Qalın mətn",
diff --git a/www/wiki/extensions/WikiEditor/i18n/azb.json b/www/wiki/extensions/WikiEditor/i18n/azb.json
index 5a7fa7d4..2e0e513c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/azb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/azb.json
@@ -12,17 +12,7 @@
},
"wikieditor-wikitext-tab": "ویکی‌متن",
"wikieditor-loading": "یوکلنیر...",
- "wikieditor-preview-tab": "سیناق گؤستریشی",
- "wikieditor-preview-changes-tab": "ديَیشیکلیک‌لر",
- "wikieditor-preview-loading": "یوکلنیر...",
- "wikieditor-publish-button-publish": "یئنیلمه",
- "wikieditor-publish-button-cancel": "لغو ائت",
- "wikieditor-publish-dialog-minor": "کیچیک دییشیک‌لیک",
- "wikieditor-publish-dialog-watch": "بو صفحه‌نی ایزله",
- "wikieditor-publish-dialog-publish": "یایلما",
- "wikieditor-publish-dialog-goback": "دالییا گییت",
"wikieditor-toolbar-preference": "گلیشمیش دییشدیرمه آراج چۇبوغونو چالیشدیر",
- "wikieditor-toolbar-dialogs-preference": "تعامل پنجره‌لرینی باغلانتی، جدول و داها باشقاسینی آرتیرماق اۆچون چالیشدیر",
"wikieditor-toolbar-loading": "یوکلنیر...",
"wikieditor-toolbar-tool-bold": "قالین رنگ",
"wikieditor-toolbar-tool-bold-example": "قالین یازی",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ba.json b/www/wiki/extensions/WikiEditor/i18n/ba.json
index 6a943d83..452f8fa6 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ba.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ba.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Киңәйтелгән викитекст мөхәррирләү интерфейсы менән һәм модулдәр тарафынан күп мөмкинлектәр менән тәьмин итә",
"wikieditor-wikitext-tab": "Викитекст",
"wikieditor-loading": "Сығарыу",
- "wikieditor-preview-preference": "Йәнәш ҡарап сығыуҙы тоҡандырырға",
- "wikieditor-preview-tab": "Ҡарап сығыу",
- "wikieditor-preview-changes-tab": "Үҙгәрештәр",
- "wikieditor-preview-loading": "Сығарыу...",
- "wikieditor-publish-preference": "Аҙымлап баҫтырыуҙы тоҡандырырға",
- "wikieditor-publish-button-publish": "Баҫтырып сығарырға",
- "wikieditor-publish-button-cancel": "Кире алырға",
- "wikieditor-publish-dialog-title": " {{SITENAME}} проектына баҫтырып сығарырға",
- "wikieditor-publish-dialog-summary": "Үҙгәртеүҙәр тасуирламаһы (ниндәй үҙгәртеүҙәр кереткәнегеҙҙе ҡыҫҡаса тасуирлағыҙ):",
- "wikieditor-publish-dialog-minor": "Әҙ генә үҙгәрештәр",
- "wikieditor-publish-dialog-watch": "Был битте күҙәтергә",
- "wikieditor-publish-dialog-publish": "Баҫтырып сығарырға",
- "wikieditor-publish-dialog-goback": "Кире ҡайтырға",
"wikieditor-toolbar": "Мөхәррирләү ҡоралдары",
"wikieditor-toolbar-desc": "Яҡшыртылған мөхәррирләү ҡоралдары",
"wikieditor-toolbar-preference": "Яҡшыртылған мөхәррирләү ҡоралдарын ҡулланырға",
- "wikieditor-toolbar-dialogs-preference": "Һылтанмалар, таблицалар өҫтәү өсөн мастерҙы тоҡандырырға, шулай уҡ өҫтәлмә һәм алмаштырыу функциялары",
"wikieditor-toolbar-loading": "Сығарыу...",
"wikieditor-toolbar-tool-bold": "Ҡалын",
"wikieditor-toolbar-tool-bold-example": "Ҡалын яҙылыш",
diff --git a/www/wiki/extensions/WikiEditor/i18n/be-tarask.json b/www/wiki/extensions/WikiEditor/i18n/be-tarask.json
index 28943e03..e9c65744 100644
--- a/www/wiki/extensions/WikiEditor/i18n/be-tarask.json
+++ b/www/wiki/extensions/WikiEditor/i18n/be-tarask.json
@@ -11,26 +11,12 @@
]
},
"wikieditor": "Пашыраны інтэрфэйс рэдагаваньня вікі-тэксту",
- "wikieditor-desc": "Дадае пашыраны інтэрфэйс рэдагаваньня вікі-тэксту і шмат модульных магчымасьцяў",
+ "wikieditor-desc": "Забясьпечвае паглыблены і пашыраны інтэрфэйс рэдагаваньня вікітэксту",
"wikieditor-wikitext-tab": "Вікі-тэкст",
"wikieditor-loading": "Загрузка",
- "wikieditor-preview-preference": "Уключыць папярэдні прагляд адзін каля аднаго",
- "wikieditor-preview-tab": "Папярэдні прагляд",
- "wikieditor-preview-changes-tab": "Зьмены",
- "wikieditor-preview-loading": "Загрузка…",
- "wikieditor-publish-preference": "Уключыць пакрокавую публікацыю",
- "wikieditor-publish-button-publish": "Апублікаваць",
- "wikieditor-publish-button-cancel": "Скасаваць",
- "wikieditor-publish-dialog-title": "Апублікаваць у {{GRAMMAR:месны|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Апісаньне рэдагаваньняў (коратка апішыце зробленыя Вамі зьмены):",
- "wikieditor-publish-dialog-minor": "Дробная праўка",
- "wikieditor-publish-dialog-watch": "Назіраць за гэтай старонкай",
- "wikieditor-publish-dialog-publish": "Апублікаваць",
- "wikieditor-publish-dialog-goback": "Вярнуцца",
"wikieditor-toolbar": "Панэль інструмэнтаў для рэдагаваньня",
"wikieditor-toolbar-desc": "Панэль інструмэнтаў для рэдагаваньня з палепшанай зручнасьцю",
"wikieditor-toolbar-preference": "Уключыць палепшаную панэль інструмэнтаў для рэдагаваньня",
- "wikieditor-toolbar-dialogs-preference": "Дазволіць формы для ўстаўкі спасылак, табліцаў, а таксама для пошуку і замены",
"wikieditor-toolbar-loading": "Загрузка…",
"wikieditor-toolbar-tool-bold": "Тоўсты",
"wikieditor-toolbar-tool-bold-example": "Тоўсты тэкст",
diff --git a/www/wiki/extensions/WikiEditor/i18n/be.json b/www/wiki/extensions/WikiEditor/i18n/be.json
index c0988d33..bd32e2e9 100644
--- a/www/wiki/extensions/WikiEditor/i18n/be.json
+++ b/www/wiki/extensions/WikiEditor/i18n/be.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Дадае палепшаны інтэрфейс праўкі вікітэкста і шмат модульных функцый",
"wikieditor-wikitext-tab": "Вікітэкст",
"wikieditor-loading": "Загрузка",
- "wikieditor-preview-preference": "Уключыць перадпаказ бок аб бок",
- "wikieditor-preview-tab": "Перадпаказ",
- "wikieditor-preview-changes-tab": "Змены",
- "wikieditor-preview-loading": "Загрузка...",
- "wikieditor-publish-preference": "Уключыць пакрокавую публікацыю",
- "wikieditor-publish-button-publish": "Апублікаваць",
- "wikieditor-publish-button-cancel": "Закрыць",
- "wikieditor-publish-dialog-title": "Апублікаваць у {{GRAMMAR:месны|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Тлумачэнне правак (каротка апішыце зробленыя праўкі)",
- "wikieditor-publish-dialog-minor": "Дробная праўка",
- "wikieditor-publish-dialog-watch": "Назіраць за гэтай старонкай",
- "wikieditor-publish-dialog-publish": "Апублікаваць",
- "wikieditor-publish-dialog-goback": "Вярнуцца",
"wikieditor-toolbar": "Панэль інструментаў",
"wikieditor-toolbar-desc": "Панэль інструментаў з палепшанымі магчымасцямі",
"wikieditor-toolbar-preference": "Уключыць панэль інструментаў з палепшанымі магчымасцямі",
- "wikieditor-toolbar-dialogs-preference": "Уключыць формы для ўстаўкі спасылак, табліц, а таксама для пошуку і замены",
"wikieditor-toolbar-loading": "Загрузка…",
"wikieditor-toolbar-tool-bold": "Цёмны",
"wikieditor-toolbar-tool-bold-example": "Цёмны тэкст",
diff --git a/www/wiki/extensions/WikiEditor/i18n/bg.json b/www/wiki/extensions/WikiEditor/i18n/bg.json
index c72e674c..13c433fa 100644
--- a/www/wiki/extensions/WikiEditor/i18n/bg.json
+++ b/www/wiki/extensions/WikiEditor/i18n/bg.json
@@ -9,30 +9,17 @@
"Wizardist",
"Macofe",
"V111P",
- "Vodnokon4e"
+ "Vodnokon4e",
+ "StanProg"
]
},
"wikieditor": "Подобрен интерфейс за редактиране на уикитекст",
- "wikieditor-desc": "Предлага разширяем интерфейс за редактиране на уикитекст и множество модули с допълнителни функционалности",
+ "wikieditor-desc": "Предлага съвременен, разширяем интерфейс за редактиране на уикитекст",
"wikieditor-wikitext-tab": "Уикитекст",
"wikieditor-loading": "Зареждане",
- "wikieditor-preview-preference": "Активиране на успореден преглед",
- "wikieditor-preview-tab": "Предварителен преглед",
- "wikieditor-preview-changes-tab": "Промени",
- "wikieditor-preview-loading": "Зареждане...",
- "wikieditor-publish-preference": "Включване на публикуване стъпка по стъпка",
- "wikieditor-publish-button-publish": "Публикуване",
- "wikieditor-publish-button-cancel": "Отказване",
- "wikieditor-publish-dialog-title": "Публикуване в {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Резюме на редакцията (кратко описание на текущо направените промени):",
- "wikieditor-publish-dialog-minor": "Малка промяна",
- "wikieditor-publish-dialog-watch": "Наблюдаване на страницата",
- "wikieditor-publish-dialog-publish": "Публикуване",
- "wikieditor-publish-dialog-goback": "Връщане",
"wikieditor-toolbar": "Лента за редактиране",
"wikieditor-toolbar-desc": "Лента за редактиране с подобрени възможности за използваемост",
"wikieditor-toolbar-preference": "Включване на разширената лента с инструменти",
- "wikieditor-toolbar-dialogs-preference": "Включване на инструменти за вмъкване на препратки и таблици, както и функцията за търсене и замяна на текст",
"wikieditor-toolbar-loading": "Зареждане...",
"wikieditor-toolbar-tool-bold": "Получер (удебелен) текст",
"wikieditor-toolbar-tool-bold-example": "Получер текст",
@@ -128,6 +115,7 @@
"wikieditor-toolbar-tool-table-preview": "Предварителен преглед",
"wikieditor-toolbar-tool-table-insert": "Вмъкване",
"wikieditor-toolbar-tool-table-cancel": "Отказване",
+ "wikieditor-toolbar-tool-table-example-text": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut nec purus diam. Sed aliquam imperdiet nunc quis lacinia. Donec rutrum consectetur placerat. Sed volutpat neque non purus faucibus id ultricies enim euismod.",
"wikieditor-toolbar-tool-table-toomany": "През този диалогов режим не може да се вмъкне таблица с повече от $1 {{PLURAL:$1|клетка|клетки}}.",
"wikieditor-toolbar-tool-table-invalidnumber": "Не сте въвели валидно число за броя редове или стълбове.",
"wikieditor-toolbar-tool-table-zero": "Не можете да вмъкнете таблица с нула на брой редове или стълбове.",
@@ -141,11 +129,11 @@
"wikieditor-toolbar-tool-replace-button-replace": "Заместване",
"wikieditor-toolbar-tool-replace-button-replaceall": "Замяна на всички",
"wikieditor-toolbar-tool-replace-close": "Затваряне",
- "wikieditor-toolbar-tool-replace-nomatch": "Нямаше резултати, които да отговарят на вашето търсене.",
+ "wikieditor-toolbar-tool-replace-nomatch": "Няма резултати, които да отговарят на вашето търсене.",
"wikieditor-toolbar-tool-replace-success": "{{PLURAL:$1|Направена е $1 замяна|Направени са $1 замени}}.",
"wikieditor-toolbar-tool-replace-emptysearch": "Не сте въвели низ за търсене.",
"wikieditor-toolbar-tool-replace-invalidregex": "Въведеният от вас регулярен израз е невалиден: $1",
- "wikieditor-toolbar-section-characters": "Специални символи",
+ "wikieditor-toolbar-section-characters": "Специални знаци",
"wikieditor-toolbar-section-help": "Помощ",
"wikieditor-toolbar-help-heading-description": "Описание",
"wikieditor-toolbar-help-heading-syntax": "В режим на редактиране",
@@ -200,8 +188,10 @@
"wikieditor-toolbar-help-content-named-reference-syntax": "Текст на страницата.&lt;ref name=\"тест\"&gt;[http://www.example.org Текст на препратката]&lt;/ref&gt;",
"wikieditor-toolbar-help-content-named-reference-result": "Текст на страницата.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "Множествена употреба на един и същ източник",
+ "wikieditor-toolbar-help-content-rereference-syntax": "&lt;ref name=\"test\" /&gt;",
"wikieditor-toolbar-help-content-rereference-result": "Текст на страницата.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "Извеждане на източниците",
+ "wikieditor-toolbar-help-content-showreferences-syntax": "&lt;references /&gt;",
"wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Текст на външната препратка</a>, допълнителен текст.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Текст на външната препратка</a></li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "Подпис с дата и час",
"wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Потребителско име</a> (<a href='#' title='$2:Username'>беседа</a>) 15:54, 10 юни 2009 (UTC)",
diff --git a/www/wiki/extensions/WikiEditor/i18n/bjn.json b/www/wiki/extensions/WikiEditor/i18n/bjn.json
index b6c699bb..42bc3680 100644
--- a/www/wiki/extensions/WikiEditor/i18n/bjn.json
+++ b/www/wiki/extensions/WikiEditor/i18n/bjn.json
@@ -8,13 +8,6 @@
},
"wikieditor-wikitext-tab": "NaskahWiki",
"wikieditor-loading": "Mamuat",
- "wikieditor-preview-tab": "Tilik",
- "wikieditor-preview-changes-tab": "Parubahan",
- "wikieditor-preview-loading": "Ma'unggah...",
- "wikieditor-publish-button-cancel": "Walangi",
- "wikieditor-publish-dialog-minor": "Babakan sapalih",
- "wikieditor-publish-dialog-watch": "Itihi tungkaran ini",
- "wikieditor-publish-dialog-goback": "Bulik",
"wikieditor-toolbar": "Kukuar pakakas mambabak",
"wikieditor-toolbar-tool-bold": "Kandal",
"wikieditor-toolbar-tool-bold-example": "Naskah kandal",
diff --git a/www/wiki/extensions/WikiEditor/i18n/bn.json b/www/wiki/extensions/WikiEditor/i18n/bn.json
index 0083d24c..c5d57be7 100644
--- a/www/wiki/extensions/WikiEditor/i18n/bn.json
+++ b/www/wiki/extensions/WikiEditor/i18n/bn.json
@@ -14,19 +14,6 @@
"wikieditor-desc": "একটি সম্প্রসারণযোগ্য উইকিটেক্সট সম্পাদনা ইন্টারফেস প্রদান করে এবং এবং বহু বৈশিষ্ট্য মডিউল প্রদান করে",
"wikieditor-wikitext-tab": "উইকিটেক্সট",
"wikieditor-loading": "লোড হচ্ছে...",
- "wikieditor-preview-preference": "পাশাপাশি প্রাকদর্শন সক্রিয় করো",
- "wikieditor-preview-tab": "প্রাকদর্শন",
- "wikieditor-preview-changes-tab": "পরিবর্তন",
- "wikieditor-preview-loading": "লোড হচ্ছে...",
- "wikieditor-publish-preference": "ধাপে ধাপে প্রকাশ করা সক্রিয় করো",
- "wikieditor-publish-button-publish": "প্রকাশ করো",
- "wikieditor-publish-button-cancel": "বাতিল",
- "wikieditor-publish-dialog-title": "{{SITENAME}} এ প্রকাশ করো",
- "wikieditor-publish-dialog-summary": "সম্পাদনা সারাংশ (আপনি কি পরিবর্তন করেছেন তা অল্প কথায় লিখুন):",
- "wikieditor-publish-dialog-minor": "অনুল্লেখ্য সম্পাদনা",
- "wikieditor-publish-dialog-watch": "এই পাতাটি নজরে রাখুন",
- "wikieditor-publish-dialog-publish": "প্রকাশ করো",
- "wikieditor-publish-dialog-goback": "ফিরে যাও",
"wikieditor-toolbar": "সম্পাদনা সরঞ্জামদণ্ড",
"wikieditor-toolbar-desc": "বেশি ব্যবহারযোগ্য সম্পাদনা পাতার সরঞ্জামদণ্ড",
"wikieditor-toolbar-preference": "শক্তিশালী সম্পাদনা সরঞ্জামদণ্ড সক্রিয় করো",
diff --git a/www/wiki/extensions/WikiEditor/i18n/bo.json b/www/wiki/extensions/WikiEditor/i18n/bo.json
index 23c49a85..5caff424 100644
--- a/www/wiki/extensions/WikiEditor/i18n/bo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/bo.json
@@ -5,8 +5,6 @@
]
},
"wikieditor-loading": "འདྲེན་པ།",
- "wikieditor-preview-tab": "སྔ་མ།",
- "wikieditor-publish-button-cancel": "རྩིས་མེད།",
"wikieditor-toolbar-tool-replace-close": "སྒོ་རྒྱག་པ།",
"wikieditor-toolbar-help-page-list": "རེའུ་མིག"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/bpy.json b/www/wiki/extensions/WikiEditor/i18n/bpy.json
index 9a24fe6d..4866a6c2 100644
--- a/www/wiki/extensions/WikiEditor/i18n/bpy.json
+++ b/www/wiki/extensions/WikiEditor/i18n/bpy.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "উইকি-টেক্ট পতানির কা সালকরানি একরব অসারে ইন্টারফেস বারো আরাকউ ফিচার দিতই মডিউল",
"wikieditor-wikitext-tab": "উইকিটেক্সট",
"wikieditor-loading": "আনরাঙ",
- "wikieditor-preview-preference": "কাদাহাত আকচা দেখাদে",
- "wikieditor-preview-tab": "আগচা",
- "wikieditor-preview-changes-tab": "বদালাসিতা",
- "wikieditor-preview-loading": "লোডিং…",
- "wikieditor-publish-preference": "কাকেয়ে-কাকেয়ে ফঙকরানিহান থা কর",
- "wikieditor-publish-button-publish": "ফঙকর",
- "wikieditor-publish-button-cancel": "বাতিল করেদে",
- "wikieditor-publish-dialog-title": "{{SITENAME}} হাত ফঙকর",
- "wikieditor-publish-dialog-summary": "পতানির বারে (তি কিহান পতাসত্তা অহানর বারে বাট্টি করে মাতেদে):",
- "wikieditor-publish-dialog-minor": "হুরু-মুরু পতানিহান",
- "wikieditor-publish-dialog-watch": "পাতাএহান খিয়ালে থ",
- "wikieditor-publish-dialog-publish": "ফঙকর",
- "wikieditor-publish-dialog-goback": "আলথকে যাগা",
"wikieditor-toolbar": "পতানির টুলবার",
"wikieditor-toolbar-desc": "বপ ব্যবহারঅর পতানির পাতা অতার টুলবার",
"wikieditor-toolbar-preference": "লিঙপা পতার টুলবার ফঙে থ",
- "wikieditor-toolbar-dialogs-preference": "তিলকরিসি লিংক, ছক বারো আরতার ডায়ালগ ফঙে থ",
"wikieditor-toolbar-loading": "লোডিং…",
"wikieditor-toolbar-tool-bold": "গাঢ়পা",
"wikieditor-toolbar-tool-bold-example": "গাঢ়পা ইকা",
diff --git a/www/wiki/extensions/WikiEditor/i18n/br.json b/www/wiki/extensions/WikiEditor/i18n/br.json
index 3a8ab8f8..855857f7 100644
--- a/www/wiki/extensions/WikiEditor/i18n/br.json
+++ b/www/wiki/extensions/WikiEditor/i18n/br.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Poruchas a ra un etrefas kemmañ wikitestenn astennidik ha meur a arc'hwel all.",
"wikieditor-wikitext-tab": "Wikitestenn",
"wikieditor-loading": "O kargañ...",
- "wikieditor-preview-preference": "Gweredekaat ar rakweled skoaz-ouzh-skoaz",
- "wikieditor-preview-tab": "Rakwelet",
- "wikieditor-preview-changes-tab": "Kemmoù",
- "wikieditor-preview-loading": "O kargañ...",
- "wikieditor-publish-preference": "Gweredekaat an embann pazenn-ha-pazenn",
- "wikieditor-publish-button-publish": "Embann",
- "wikieditor-publish-button-cancel": "Nullañ",
- "wikieditor-publish-dialog-title": "Embann war {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Aozañ an diverrañ (deskrivañ berr-ha-berr ar c'hemmoù degaset ganeoc'h) :",
- "wikieditor-publish-dialog-minor": "Kemmig dister",
- "wikieditor-publish-dialog-watch": "Evezhiañ ar bajenn-mañ",
- "wikieditor-publish-dialog-publish": "Embann",
- "wikieditor-publish-dialog-goback": "Distreiñ",
"wikieditor-toolbar": "Barrenn ostilhoù kemmañ",
"wikieditor-toolbar-desc": "Barrenn ostilhoù kemmañ aesoc'h da implijout",
"wikieditor-toolbar-preference": "Gweredekaat ar varrenn ostilhoù kemmañ gwellaet",
- "wikieditor-toolbar-dialogs-preference": "Gweredekaat ar boestoù divizout evit ouzhpennañ liammoù, taolennoù ha traoù all",
"wikieditor-toolbar-loading": "O kargañ...",
"wikieditor-toolbar-tool-bold": "Tev",
"wikieditor-toolbar-tool-bold-example": "Testenn dev",
diff --git a/www/wiki/extensions/WikiEditor/i18n/bs.json b/www/wiki/extensions/WikiEditor/i18n/bs.json
index 64965ebc..7b4192e1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/bs.json
+++ b/www/wiki/extensions/WikiEditor/i18n/bs.json
@@ -7,26 +7,14 @@
"KWiki",
"Munja",
"Srdjan m",
- "Semso98"
+ "Semso98",
+ "Obsuser"
]
},
"wikieditor": "Napredni interfejs za uređivanje wikiteksta",
"wikieditor-desc": "Omogućava proširivi interfejs za uređivanje wikiteksta i mnoge module sa brojnim mogućnostima",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Učitavam...",
- "wikieditor-preview-preference": "Uključi uporedni pregled",
- "wikieditor-preview-tab": "Pregled",
- "wikieditor-preview-changes-tab": "Promjene",
- "wikieditor-preview-loading": "Učitavam...",
- "wikieditor-publish-preference": "Uključi objavljivanje u koracima",
- "wikieditor-publish-button-publish": "Objavi",
- "wikieditor-publish-button-cancel": "Otkaži",
- "wikieditor-publish-dialog-title": "Objavi na {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Uredi sažetak (kratko opiši izmjene koje ste načinili):",
- "wikieditor-publish-dialog-minor": "mala izmjena",
- "wikieditor-publish-dialog-watch": "Prati ovu stranicu",
- "wikieditor-publish-dialog-publish": "Objavi",
- "wikieditor-publish-dialog-goback": "Vrati se nazad",
"wikieditor-toolbar": "Uređivanje alatne trake",
"wikieditor-toolbar-desc": "Alatna traka stranice za uređivanje sa poboljšanom upotrebljivošću",
"wikieditor-toolbar-preference": "Uključi naprednu traku za uređivanje",
@@ -128,18 +116,18 @@
"wikieditor-toolbar-tool-table-toomany": "Ubacivanje tabele s više od $1 {{PLURAL:$1|ćelija}} nije moguće putem ovog dijaloga.",
"wikieditor-toolbar-tool-table-invalidnumber": "Niste unijeli valjan broj redova ili kolona.",
"wikieditor-toolbar-tool-table-zero": "Ne možete unijeti tabelu bez redova ili kolona.",
- "wikieditor-toolbar-tool-replace": "Pronađi i zamijeni",
- "wikieditor-toolbar-tool-replace-title": "Nađi i zamijeni",
+ "wikieditor-toolbar-tool-replace": "Pretraži i zamijeni",
+ "wikieditor-toolbar-tool-replace-title": "Traži i zamijeni",
"wikieditor-toolbar-tool-replace-search": "Pretraži:",
"wikieditor-toolbar-tool-replace-replace": "Zamijeni sa:",
- "wikieditor-toolbar-tool-replace-case": "Razlikuj velika i mala slova",
- "wikieditor-toolbar-tool-replace-regex": "Smatraj traženi pojam kao regularni izraz",
- "wikieditor-toolbar-tool-replace-button-findnext": "Nađi sljedeći",
+ "wikieditor-toolbar-tool-replace-case": "Pazi na veličinu slova",
+ "wikieditor-toolbar-tool-replace-regex": "Postupi s nizom za pretragu kao s regularnim izrazom",
+ "wikieditor-toolbar-tool-replace-button-findnext": "Nađi sljedeće",
"wikieditor-toolbar-tool-replace-button-replace": "Zamijeni",
"wikieditor-toolbar-tool-replace-button-replaceall": "Zamijeni sve",
"wikieditor-toolbar-tool-replace-close": "Zatvori",
"wikieditor-toolbar-tool-replace-nomatch": "Vaša pretraga nije dala nijedan rezultat.",
- "wikieditor-toolbar-tool-replace-success": "Načinjeno $1 {{PLURAL:$1|izmjena|izmjene}}.",
+ "wikieditor-toolbar-tool-replace-success": "{{PLURAL:$1|Napravljena $1 zamjena|Napravljene $1 zamjene|Napravljeno $1 zamjena}}.",
"wikieditor-toolbar-tool-replace-emptysearch": "Niste unijeli ništa za pretragu.",
"wikieditor-toolbar-tool-replace-invalidregex": "Regularni izraz koji ste unijeli nije valjan: $1",
"wikieditor-toolbar-section-characters": "Posebni znakovi",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ca.json b/www/wiki/extensions/WikiEditor/i18n/ca.json
index 9bfe6c4e..deeb70cb 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ca.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ca.json
@@ -17,22 +17,9 @@
]
},
"wikieditor": "Interfície avançada de modificació de wikitext",
- "wikieditor-desc": "Proporciona una interfície extensible de modificació de wikitext i diversos mòduls de funcionalitats",
+ "wikieditor-desc": "Proporciona una interfície avançada i extensible d'edició de wikitext",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Carregant",
- "wikieditor-preview-preference": "Habilita la previsualització costat per costat",
- "wikieditor-preview-tab": "Previsualització",
- "wikieditor-preview-changes-tab": "Canvis",
- "wikieditor-preview-loading": "Carregant ...",
- "wikieditor-publish-preference": "Habilita la publicació pas a pas",
- "wikieditor-publish-button-publish": "Publica",
- "wikieditor-publish-button-cancel": "Anuŀla",
- "wikieditor-publish-dialog-title": "Publicar a {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resum d'edició (descriviu breument els canvis realitzats):",
- "wikieditor-publish-dialog-minor": "Edició menor",
- "wikieditor-publish-dialog-watch": "Vigila aquesta pàgina",
- "wikieditor-publish-dialog-publish": "Publica",
- "wikieditor-publish-dialog-goback": "Torna",
"wikieditor-toolbar": "Editant la barra d'eines",
"wikieditor-toolbar-desc": "Barra d'eines d'edició amb usabilitat millorada",
"wikieditor-toolbar-preference": "Habilita la barra d'eines millorada",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ce.json b/www/wiki/extensions/WikiEditor/i18n/ce.json
index 04597f80..a721ef98 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ce.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ce.json
@@ -10,19 +10,6 @@
"wikieditor-desc": "Тадарш даран шоьйра интерфейс латайо кхин дукху фукцеш а",
"wikieditor-wikitext-tab": "Викийоза",
"wikieditor-loading": "Чуйолуш",
- "wikieditor-preview-preference": "Латайé хьалха хьажар дуьхь дуьхьал",
- "wikieditor-preview-tab": "Хьалха хьажар",
- "wikieditor-preview-changes-tab": "хийцамаш",
- "wikieditor-preview-loading": "Чуйолуш…",
- "wikieditor-publish-preference": "Латайé цхьац ког бокхуш чутохар",
- "wikieditor-publish-button-publish": "Арахеца",
- "wikieditor-publish-button-cancel": "Цаоьшу",
- "wikieditor-publish-dialog-title": "{{SITENAME}} проектехь арахецар",
- "wikieditor-publish-dialog-summary": "Хийцамах лаьцна (доц язде хlу хийцам бина ахьа):",
- "wikieditor-publish-dialog-minor": "Жима хийцам",
- "wikieditor-publish-dialog-watch": "Тергам бé хӀокху агӀона",
- "wikieditor-publish-dialog-publish": "Арахеца",
- "wikieditor-publish-dialog-goback": "Юха",
"wikieditor-toolbar": "Тадаран меттиг",
"wikieditor-toolbar-desc": "Тадаран меттиг гӀоле лелорца",
"wikieditor-toolbar-preference": "Гайта дика кечйина панель",
@@ -48,7 +35,7 @@
"wikieditor-toolbar-tool-link-insert": "Чуйилла хьажорг",
"wikieditor-toolbar-tool-link-cancel": "Цаоьшу",
"wikieditor-toolbar-tool-link-int-target-status-exists": "Иштта агӀо йолуш ю",
- "wikieditor-toolbar-tool-link-int-target-status-notexists": "Ишта агӀо яц",
+ "wikieditor-toolbar-tool-link-int-target-status-notexists": "Иштта агӀо яц",
"wikieditor-toolbar-tool-link-int-target-status-invalid": "Ца магайо цӀе",
"wikieditor-toolbar-tool-link-int-target-status-external": "Арахьара хьажорг",
"wikieditor-toolbar-tool-link-int-target-status-loading": "АгӀо юьй хьажар…",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ckb.json b/www/wiki/extensions/WikiEditor/i18n/ckb.json
index 1517676a..d89362af 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ckb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ckb.json
@@ -15,23 +15,9 @@
"wikieditor": "ڕووکاری پێشکەوتووی دەستکاریکردنی ویکیدەق",
"wikieditor-wikitext-tab": "ویکیدەق",
"wikieditor-loading": "بارکردن",
- "wikieditor-preview-preference": "ڕێگەپێدان بە پێشبینینی شانبەشان",
- "wikieditor-preview-tab": "پێشبینین",
- "wikieditor-preview-changes-tab": "گۆڕانکارییەکان",
- "wikieditor-preview-loading": "باركردن‌ ...",
- "wikieditor-publish-preference": "ڕێگە بدە بە بڵاوکردنەوەی ھەنگاوبەھەنگاو",
- "wikieditor-publish-button-publish": "بڵاوی بکەوە",
- "wikieditor-publish-button-cancel": "ھەڵوەشاندنەوە",
- "wikieditor-publish-dialog-title": "لە {{SITENAME}} بڵاوی بکەوە",
- "wikieditor-publish-dialog-summary": "کورتەی دەستکاری (بەکورتی ئەو گۆڕانکارییانەی کردووتە وەسف بکە):",
- "wikieditor-publish-dialog-minor": "دەستکاریی بچووک",
- "wikieditor-publish-dialog-watch": "ئەم پەڕەیە بخە ژێر چاودێری",
- "wikieditor-publish-dialog-publish": "بڵاوی بکەوە",
- "wikieditor-publish-dialog-goback": "بگەڕێوە",
"wikieditor-toolbar": "شریتامرازی دەستکاریکردن",
"wikieditor-toolbar-desc": "شریتامرازی پەڕەی دەستکاریکردن بە کارەمەیی پەرەپێدراو",
"wikieditor-toolbar-preference": "ڕێگە بدە بە شریتامرازی پەرەسندووی دەستکاریکردن",
- "wikieditor-toolbar-dialogs-preference": "ڕێگە بدە بە پەنجەرە وتووێژییەکان بۆ تێخستنی بەستەرەکان، خشتەکان و ھتد.",
"wikieditor-toolbar-loading": "خەریکی بارکردن...",
"wikieditor-toolbar-tool-bold": "تۆخ",
"wikieditor-toolbar-tool-bold-example": "دەقی تۆخ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/cs.json b/www/wiki/extensions/WikiEditor/i18n/cs.json
index 381afd74..bc6e1d53 100644
--- a/www/wiki/extensions/WikiEditor/i18n/cs.json
+++ b/www/wiki/extensions/WikiEditor/i18n/cs.json
@@ -6,26 +6,14 @@
"Littledogboy",
"Mormegil",
"Macofe",
- "Dvorapa"
+ "Dvorapa",
+ "Matěj Suchánek"
]
},
"wikieditor": "Vylepšené rozhraní pro editaci wikitextu",
- "wikieditor-desc": "Poskytuje rozšiřitelné editační rozhraní a mnoho modulů s novými funkcemi",
+ "wikieditor-desc": "Poskytuje pokročilé, rozšiřitelné rozhraní pro editaci wikitextu",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Načítá se",
- "wikieditor-preview-preference": "Zapnout náhledy v panelu",
- "wikieditor-preview-tab": "Náhled",
- "wikieditor-preview-changes-tab": "Změny",
- "wikieditor-preview-loading": "Načítá se…",
- "wikieditor-publish-preference": "Zapnout průvodce publikováním",
- "wikieditor-publish-button-publish": "Publikovat",
- "wikieditor-publish-button-cancel": "Storno",
- "wikieditor-publish-dialog-title": "Publikovat do {{grammar:2sg|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Shrnutí editace (stručně popište provedené změny):",
- "wikieditor-publish-dialog-minor": "Malá editace",
- "wikieditor-publish-dialog-watch": "Sledovat tuto stránku",
- "wikieditor-publish-dialog-publish": "Publikovat",
- "wikieditor-publish-dialog-goback": "Zpět",
"wikieditor-toolbar": "Editační panel nástrojů",
"wikieditor-toolbar-desc": "Editační panel nástrojů s vylepšenou použitelností",
"wikieditor-toolbar-preference": "Zapnout vylepšený panel nástrojů",
diff --git a/www/wiki/extensions/WikiEditor/i18n/csb.json b/www/wiki/extensions/WikiEditor/i18n/csb.json
index 21796c65..56f943d2 100644
--- a/www/wiki/extensions/WikiEditor/i18n/csb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/csb.json
@@ -5,7 +5,6 @@
"Kaszeba"
]
},
- "wikieditor-preview-loading": "Ladowanié...",
"wikieditor-toolbar-loading": "Ladowanié...",
"wikieditor-toolbar-tool-bold": "Grëbi",
"wikieditor-toolbar-tool-bold-example": "Wëtłëszczony drëk",
diff --git a/www/wiki/extensions/WikiEditor/i18n/cu.json b/www/wiki/extensions/WikiEditor/i18n/cu.json
index d9230d06..db34fac4 100644
--- a/www/wiki/extensions/WikiEditor/i18n/cu.json
+++ b/www/wiki/extensions/WikiEditor/i18n/cu.json
@@ -4,11 +4,6 @@
"ОйЛ"
]
},
- "wikieditor-preview-changes-tab": "мѣнꙑ",
- "wikieditor-publish-button-publish": "съхранѥниѥ",
- "wikieditor-publish-dialog-minor": "малаꙗ мѣна",
- "wikieditor-publish-dialog-watch": "сѥѩ страницѧ блюдєниѥ",
- "wikieditor-publish-dialog-publish": "съхранѥниѥ",
"wikieditor-toolbar-tool-ilink-example": "съвѧꙁи имѧ",
"wikieditor-toolbar-tool-xlink-example": "http://www.example.com съвѧꙁи имѧ",
"wikieditor-toolbar-tool-link": "съвѧꙁь",
diff --git a/www/wiki/extensions/WikiEditor/i18n/cy.json b/www/wiki/extensions/WikiEditor/i18n/cy.json
index 9135c074..fb56cdf7 100644
--- a/www/wiki/extensions/WikiEditor/i18n/cy.json
+++ b/www/wiki/extensions/WikiEditor/i18n/cy.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Yn darparu rhyngwyneb estynadwy ar gyfer golygu testun wici a llawer o fodiwlau o nodweddion arbennig",
"wikieditor-wikitext-tab": "Testun wici",
"wikieditor-loading": "Wrthi'n llwytho",
- "wikieditor-preview-preference": "Galluogi rhagolwg ochr-yn-ochr",
- "wikieditor-preview-tab": "Rhagolwg",
- "wikieditor-preview-changes-tab": "Newidiadau",
- "wikieditor-preview-loading": "Wrthi'n llwytho...",
- "wikieditor-publish-preference": "Galluogi cyhoeddi cam-wrth-gam",
- "wikieditor-publish-button-publish": "Cyhoeddi",
- "wikieditor-publish-button-cancel": "Diddymu",
- "wikieditor-publish-dialog-title": "Cyhoeddi ar {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Crynodeb golygu (rhowch ddisgrifiad byr o'ch newididau):",
- "wikieditor-publish-dialog-minor": "Golygiad bychan",
- "wikieditor-publish-dialog-watch": "Dilyn hynt y dudalen hon",
- "wikieditor-publish-dialog-publish": "Cyhoedder",
- "wikieditor-publish-dialog-goback": "Yn ôl",
"wikieditor-toolbar": "Bar offer golygu",
"wikieditor-toolbar-desc": "Bar offer y dudalen olygu gyda gwelliannau defnyddioldeb",
"wikieditor-toolbar-preference": "Defnyddio'r bar offer golygu estynedig",
- "wikieditor-toolbar-dialogs-preference": "Galluogi'r dewin sy'n mewnosod cysylltau a thablau, ac sy'n gallu chwilio a disodli",
"wikieditor-toolbar-loading": "Wrthi'n llwytho...",
"wikieditor-toolbar-tool-bold": "Praff",
"wikieditor-toolbar-tool-bold-example": "Testun praff",
diff --git a/www/wiki/extensions/WikiEditor/i18n/da.json b/www/wiki/extensions/WikiEditor/i18n/da.json
index 66de6f3b..ab78e314 100644
--- a/www/wiki/extensions/WikiEditor/i18n/da.json
+++ b/www/wiki/extensions/WikiEditor/i18n/da.json
@@ -15,23 +15,9 @@
"wikieditor-desc": "Giver et udvidet interface til redigering af wikitekst og mange moduler med hjælpefunktioner",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Indlæser...",
- "wikieditor-preview-preference": "Aktiver forhåndsvisning side-om-side",
- "wikieditor-preview-tab": "Forhåndsvisning",
- "wikieditor-preview-changes-tab": "Ændringer",
- "wikieditor-preview-loading": "Indlæser...",
- "wikieditor-publish-preference": "Aktiver skridt-for-skridt udgivelse",
- "wikieditor-publish-button-publish": "Udgiv",
- "wikieditor-publish-button-cancel": "Afbryd",
- "wikieditor-publish-dialog-title": "Udgiv til {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Redigeringsbeskrivelse (beskriv kort de ændringer, du har lavet)",
- "wikieditor-publish-dialog-minor": "Mindre ændring",
- "wikieditor-publish-dialog-watch": "Overvåg denne side",
- "wikieditor-publish-dialog-publish": "Udgiv",
- "wikieditor-publish-dialog-goback": "Gå tilbage",
"wikieditor-toolbar": "Værktøjslinje til redigering",
"wikieditor-toolbar-desc": "Værktøjslinje til redigering med udvidet brugervenlighed",
"wikieditor-toolbar-preference": "Aktiver forbedret værktøjslinje til redigering",
- "wikieditor-toolbar-dialogs-preference": "Aktiver guider til at indsætte links, tabeller samt søg og erstat-funktionen",
"wikieditor-toolbar-loading": "Indlæser ...",
"wikieditor-toolbar-tool-bold": "Fed",
"wikieditor-toolbar-tool-bold-example": "Fed tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/de-ch.json b/www/wiki/extensions/WikiEditor/i18n/de-ch.json
index c3bf18ae..f022e0ba 100644
--- a/www/wiki/extensions/WikiEditor/i18n/de-ch.json
+++ b/www/wiki/extensions/WikiEditor/i18n/de-ch.json
@@ -5,7 +5,6 @@
"Geitost"
]
},
- "wikieditor-toolbar-dialogs-preference": "Assistenten zum Einfügen von Links und Tabellen sowie die Funktion «Suchen und Ersetzen» aktivieren",
"wikieditor-toolbar-tool-reference-example": "Fussnotentext hier einfügen",
"wikieditor-toolbar-tool-big": "Gross",
"wikieditor-toolbar-tool-big-example": "Grosser Text",
diff --git a/www/wiki/extensions/WikiEditor/i18n/de-formal.json b/www/wiki/extensions/WikiEditor/i18n/de-formal.json
index 00213284..abc2c26b 100644
--- a/www/wiki/extensions/WikiEditor/i18n/de-formal.json
+++ b/www/wiki/extensions/WikiEditor/i18n/de-formal.json
@@ -5,7 +5,6 @@
"Kghbln"
]
},
- "wikieditor-publish-dialog-summary": "Zusammenfassung (kurze Beschreibung der von Ihnen vorgenommenen Änderungen):",
"wikieditor-toolbar-tool-link-lookslikeinternal": "Die von Ihnen angegebene URL wirkt wie eine, die auf eine andere Wikiseite verlinken würde.\nMöchten Sie daraus einen internen Link machen?",
"wikieditor-toolbar-tool-link-empty": "Sie haben nichts zum Verlinken angegeben.",
"wikieditor-toolbar-tool-table-invalidnumber": "Sie haben keine gültige Anzahl von Zeilen oder Spalten angegeben.",
diff --git a/www/wiki/extensions/WikiEditor/i18n/de.json b/www/wiki/extensions/WikiEditor/i18n/de.json
index 79cb9366..7846557d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/de.json
+++ b/www/wiki/extensions/WikiEditor/i18n/de.json
@@ -17,26 +17,12 @@
]
},
"wikieditor": "Fortgeschrittener Wikitext-Editor",
- "wikieditor-desc": "Ermöglicht eine erweiterbare Oberfläche zur Wikitext-Bearbeitung sowie viele weitere neue Funktionen",
+ "wikieditor-desc": "Stellt einen modernen und erweiterbaren Wikitext-Editor bereit",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Lade …",
- "wikieditor-preview-preference": "Gegenüberstellungsvorschau ermöglichen",
- "wikieditor-preview-tab": "Vorschau",
- "wikieditor-preview-changes-tab": "Änderungen",
- "wikieditor-preview-loading": "Lade …",
- "wikieditor-publish-preference": "Schritt-für-Schritt-Veröffentlichung ermöglichen",
- "wikieditor-publish-button-publish": "Veröffentlichen",
- "wikieditor-publish-button-cancel": "Abbrechen",
- "wikieditor-publish-dialog-title": "Auf {{SITENAME}} veröffentlichen",
- "wikieditor-publish-dialog-summary": "Zusammenfassung (kurze Beschreibung der von dir vorgenommenen Änderungen):",
- "wikieditor-publish-dialog-minor": "Kleine Änderung",
- "wikieditor-publish-dialog-watch": "Diese Seite beobachten",
- "wikieditor-publish-dialog-publish": "Veröffentlichen",
- "wikieditor-publish-dialog-goback": "Zurück",
"wikieditor-toolbar": "Bearbeiten-Werkzeugleiste",
"wikieditor-toolbar-desc": "Bearbeiten-Werkzeugleiste mit verbesserter Benutzerfreundlichkeit",
"wikieditor-toolbar-preference": "Erweiterte Bearbeiten-Werkzeugleiste aktivieren",
- "wikieditor-toolbar-dialogs-preference": "Assistenten zum Einfügen von Links und Tabellen sowie die Funktion „Suchen und Ersetzen“ aktivieren",
"wikieditor-toolbar-loading": "Lade …",
"wikieditor-toolbar-tool-bold": "Fett",
"wikieditor-toolbar-tool-bold-example": "Fetter Text",
diff --git a/www/wiki/extensions/WikiEditor/i18n/diq.json b/www/wiki/extensions/WikiEditor/i18n/diq.json
index 953b2440..1d3f5c25 100644
--- a/www/wiki/extensions/WikiEditor/i18n/diq.json
+++ b/www/wiki/extensions/WikiEditor/i18n/diq.json
@@ -17,23 +17,9 @@
"wikieditor-desc": "Yew miyanriyê wikitekstio ke raverşiyayo u xeylê feature-providing modules temin keno",
"wikieditor-wikitext-tab": "Wikimetın",
"wikieditor-loading": "Bar beno...",
- "wikieditor-preview-preference": "Pê heta verasayışi ake",
- "wikieditor-preview-tab": "Verqayt",
- "wikieditor-preview-changes-tab": "Vurnayışi",
- "wikieditor-preview-loading": "Bar beno...",
- "wikieditor-publish-preference": "Gam gam vılabyayışi aktiv kı",
- "wikieditor-publish-button-publish": "Vıla ke",
- "wikieditor-publish-button-cancel": "Bıterkın",
- "wikieditor-publish-dialog-title": "{{SITENAME}} rê çap ke",
- "wikieditor-publish-dialog-summary": "Xulasayê vurnayişi (ser vurnayişê xo xulasa binuse):",
- "wikieditor-publish-dialog-minor": "Vurriyayışo werdi",
- "wikieditor-publish-dialog-watch": "Ena perre seyr kerê.",
- "wikieditor-publish-dialog-publish": "Vıla ke",
- "wikieditor-publish-dialog-goback": "Peyser şo",
"wikieditor-toolbar": "nizamkerdışê çuyaya haceti",
"wikieditor-toolbar-desc": "Xacetê çuveyî pê enhanced usability bivurne",
"wikieditor-toolbar-preference": "çuyaya haceti yo dewlemendbiyayeyi aktif ker",
- "wikieditor-toolbar-dialogs-preference": "Qey têare kerdışê gıre, tablo usb'ani mesajan aktif bıkere",
"wikieditor-toolbar-loading": "Bar beno...",
"wikieditor-toolbar-tool-bold": "qalın",
"wikieditor-toolbar-tool-bold-example": "Metno qalın",
@@ -157,7 +143,7 @@
"wikieditor-toolbar-help-page-list": "Listey",
"wikieditor-toolbar-help-page-file": "dosyayi",
"wikieditor-toolbar-help-page-reference": "Çımey",
- "wikieditor-toolbar-help-page-discussion": "Vaten",
+ "wikieditor-toolbar-help-page-discussion": "Werênayış",
"wikieditor-toolbar-help-content-italic-description": "italik",
"wikieditor-toolbar-help-content-italic-syntax": "''metno italik''",
"wikieditor-toolbar-help-content-italic-result": "<em>metno italik</em>",
diff --git a/www/wiki/extensions/WikiEditor/i18n/dsb.json b/www/wiki/extensions/WikiEditor/i18n/dsb.json
index 9802b21a..07055c88 100644
--- a/www/wiki/extensions/WikiEditor/i18n/dsb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/dsb.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Stoj rozšyrjobny pówjerch za wobźěłowanje wikiteksta a wjele modulow k dispoziciji",
"wikieditor-wikitext-tab": "WikiTekst",
"wikieditor-loading": "Zacytujo se",
- "wikieditor-preview-preference": "Pśeglěd bok pó boku zmóžniś",
- "wikieditor-preview-tab": "Pśeglěd",
- "wikieditor-preview-changes-tab": "Změny",
- "wikieditor-preview-loading": "Zacytujo se...",
- "wikieditor-publish-preference": "Publicěrowanje kšać pó kšacu zmóžniś",
- "wikieditor-publish-button-publish": "Wózjawiś",
- "wikieditor-publish-button-cancel": "Pśetergnuś",
- "wikieditor-publish-dialog-title": "Do {{GRAMMAR:genitiw|{{SITENAME}}}} wózjawiś",
- "wikieditor-publish-dialog-summary": "Zespominanje změnow (wópisaj krotko změny, kótareř sy cynił):",
- "wikieditor-publish-dialog-minor": "Snadna změna",
- "wikieditor-publish-dialog-watch": "Toś ten bok wobglědowaś",
- "wikieditor-publish-dialog-publish": "Wózjawiś",
- "wikieditor-publish-dialog-goback": "Slědk",
"wikieditor-toolbar": "Wobźěłowańska rědowa kšoma",
"wikieditor-toolbar-desc": "Rědowa kšoma za wobźěłowanje bokow z pólěpšoneju wužywajobnosću",
"wikieditor-toolbar-preference": "Pólěpšonu wobźěłowańsku rědowu kšomu aktiwěrowaś",
- "wikieditor-toolbar-dialogs-preference": "Asistenty za zasajźenje wótkazow, tabelow a funkciju pytanja a wuměnjenja zmóžniś",
"wikieditor-toolbar-loading": "Zacytujo se...",
"wikieditor-toolbar-tool-bold": "Tucny",
"wikieditor-toolbar-tool-bold-example": "Tucny tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/el.json b/www/wiki/extensions/WikiEditor/i18n/el.json
index 4fb5c2c3..5b939f20 100644
--- a/www/wiki/extensions/WikiEditor/i18n/el.json
+++ b/www/wiki/extensions/WikiEditor/i18n/el.json
@@ -18,23 +18,9 @@
"wikieditor-desc": "Παρέχει μία επεκτάσιμη διεπαφή επεξεργασίας κειμένου wiki και πολλές μονάδες παροχής χαρακτηριστικών",
"wikieditor-wikitext-tab": "Κείμενο wiki",
"wikieditor-loading": "Φόρτωση",
- "wikieditor-preview-preference": "Ενεργοποίηση προεπισκόπησης δίπλα-δίπλα",
- "wikieditor-preview-tab": "Προεπισκόπηση",
- "wikieditor-preview-changes-tab": "Αλλαγές",
- "wikieditor-preview-loading": "Φόρτωση...",
- "wikieditor-publish-preference": "Ενεργοποίηση δημοσίευσης βήμα προς βήμα",
- "wikieditor-publish-button-publish": "Δημοσίευση",
- "wikieditor-publish-button-cancel": "Άκυρο",
- "wikieditor-publish-dialog-title": "Δημοσίευση στο {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Σύνοψη επεξεργασίας (περιγράψτε συντόμως τις αλλαγές που έχετε κάνει):",
- "wikieditor-publish-dialog-minor": "Μικροεπεξεργασία",
- "wikieditor-publish-dialog-watch": "Παρακολούθηση αυτής της σελίδας",
- "wikieditor-publish-dialog-publish": "Δημοσίευση",
- "wikieditor-publish-dialog-goback": "Πήγαινε πίσω",
"wikieditor-toolbar": "Επεξεργασία εργαλειοθήκης",
"wikieditor-toolbar-desc": "Μπάρα εργαλείων επεξεργασίας σελίδων με περισσότερες δυνατότητες χρήσης",
"wikieditor-toolbar-preference": "Ενεργοποιήστε την μπάρα εργαλείων με τις περισσότερες δυνατότητες επεξεργασίας",
- "wikieditor-toolbar-dialogs-preference": "Ενεργοποίηση οδηγών για την εισαγωγή συνδέσμων, πινάκων όπως και της λειτουργίας αναζήτησης και αντικατάστασης",
"wikieditor-toolbar-loading": "Φόρτωση...",
"wikieditor-toolbar-tool-bold": "Έντονα",
"wikieditor-toolbar-tool-bold-example": "Έντονο κείμενο",
diff --git a/www/wiki/extensions/WikiEditor/i18n/eml.json b/www/wiki/extensions/WikiEditor/i18n/eml.json
index 5eef4c53..783b761c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/eml.json
+++ b/www/wiki/extensions/WikiEditor/i18n/eml.json
@@ -4,8 +4,6 @@
"Gloria sah"
]
},
- "wikieditor-publish-button-cancel": "Scanślèr",
- "wikieditor-publish-dialog-goback": "Torna indrē",
"wikieditor-toolbar": "Bara di strumèint p'r editèr",
"wikieditor-toolbar-tool-link": "Colegamèint",
"wikieditor-toolbar-tool-link-title": "Mèter dèint'r un colegamèint",
diff --git a/www/wiki/extensions/WikiEditor/i18n/en.json b/www/wiki/extensions/WikiEditor/i18n/en.json
index ef00d574..d5c99168 100644
--- a/www/wiki/extensions/WikiEditor/i18n/en.json
+++ b/www/wiki/extensions/WikiEditor/i18n/en.json
@@ -5,22 +5,9 @@
]
},
"wikieditor": "Advanced wikitext editing interface",
- "wikieditor-desc": "Provides an extendable wikitext editing interface and many feature-providing modules",
+ "wikieditor-desc": "Provides an advanced, extensible wikitext editing interface",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Loading...",
- "wikieditor-preview-preference": "Enable side-by-side preview",
- "wikieditor-preview-tab": "Preview",
- "wikieditor-preview-changes-tab": "Changes",
- "wikieditor-preview-loading": "Loading...",
- "wikieditor-publish-preference": "Enable step-by-step publishing",
- "wikieditor-publish-button-publish": "Publish",
- "wikieditor-publish-button-cancel": "Cancel",
- "wikieditor-publish-dialog-title": "Publish to {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Edit summary (briefly describe the changes you have made):",
- "wikieditor-publish-dialog-minor": "Minor edit",
- "wikieditor-publish-dialog-watch": "Watch this page",
- "wikieditor-publish-dialog-publish": "Publish",
- "wikieditor-publish-dialog-goback": "Go back",
"wikieditor-toolbar": "Editing toolbar",
"wikieditor-toolbar-desc": "Edit page toolbar with enhanced usability",
"wikieditor-toolbar-preference": "Enable enhanced editing toolbar",
diff --git a/www/wiki/extensions/WikiEditor/i18n/eo.json b/www/wiki/extensions/WikiEditor/i18n/eo.json
index 47461026..f51a5748 100644
--- a/www/wiki/extensions/WikiEditor/i18n/eo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/eo.json
@@ -18,23 +18,9 @@
"wikieditor-desc": "Ebligas redaktan interfacon por etendebla vikiteksto kaj multaj utilaj moduloj",
"wikieditor-wikitext-tab": "Vikiteksto",
"wikieditor-loading": "Ŝargante",
- "wikieditor-preview-preference": "Enŝaltu antaŭvidon apud la redaktofenestro",
- "wikieditor-preview-tab": "Antaŭvido",
- "wikieditor-preview-changes-tab": "Ŝanĝoj",
- "wikieditor-preview-loading": "Ŝargante...",
- "wikieditor-publish-preference": "Ŝalti po-paŝan eldonadon",
- "wikieditor-publish-button-publish": "Konservi",
- "wikieditor-publish-button-cancel": "Nuligi",
- "wikieditor-publish-dialog-title": "Konservi al {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resumo (mallonge priskribu la ŝanĝoj faritaj):",
- "wikieditor-publish-dialog-minor": "Eta redakto",
- "wikieditor-publish-dialog-watch": "Atenti ĉi tiun paĝon",
- "wikieditor-publish-dialog-publish": "Eldoni",
- "wikieditor-publish-dialog-goback": "Reen",
"wikieditor-toolbar": "Ilobreto por redaktoj",
"wikieditor-toolbar-desc": "Ilobreto por redaktoj, kun plibonigita uzebleco",
"wikieditor-toolbar-preference": "Enŝalti plibonigitan ilobreton por redaktoj",
- "wikieditor-toolbar-dialogs-preference": "Enŝalti dialogujojn por aldoni ligilojn, tabelojn kaj pli",
"wikieditor-toolbar-loading": "Ŝarĝante...",
"wikieditor-toolbar-tool-bold": "Diklitera",
"wikieditor-toolbar-tool-bold-example": "Diklitera teksto",
diff --git a/www/wiki/extensions/WikiEditor/i18n/es.json b/www/wiki/extensions/WikiEditor/i18n/es.json
index d0d65a3e..fbc55b9b 100644
--- a/www/wiki/extensions/WikiEditor/i18n/es.json
+++ b/www/wiki/extensions/WikiEditor/i18n/es.json
@@ -20,26 +20,14 @@
"Macofe",
"Yllelder",
"Indiralena",
- "Sophivorus"
+ "Sophivorus",
+ "2axterix2"
]
},
"wikieditor": "Interfaz avanzada de edición de wikitexto",
- "wikieditor-desc": "Provee de una interfaz extensible de edición de wikitexto y varios módulos que ofrecen características",
+ "wikieditor-desc": "Provee una interfaz avanzada y extensible de edición de wikitexto",
"wikieditor-wikitext-tab": "Wikitexto",
"wikieditor-loading": "Cargando…",
- "wikieditor-preview-preference": "Habilitar previsualización comparativa",
- "wikieditor-preview-tab": "Previsualizar",
- "wikieditor-preview-changes-tab": "Cambios",
- "wikieditor-preview-loading": "Cargando...",
- "wikieditor-publish-preference": "Habilitar publicación paso a paso",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Cancelar",
- "wikieditor-publish-dialog-title": "Publicar en {{{SITENAME}}}",
- "wikieditor-publish-dialog-summary": "Resumen de edición (describe brevemente los cambios que has realizado):",
- "wikieditor-publish-dialog-minor": "Edición menor",
- "wikieditor-publish-dialog-watch": "Vigilar esta página",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Regresar",
"wikieditor-toolbar": "Barra de herramientas de edición",
"wikieditor-toolbar-desc": "Barra de herramientas de la página de edición con usabilidad mejorada",
"wikieditor-toolbar-preference": "Activar la barra de herramientas de edición mejorada",
@@ -214,7 +202,7 @@
"wikieditor-toolbar-help-content-showreferences-description": "Mostrar referencias",
"wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Texto del enlace</a>, texto adicional.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Texto del enlace</a></li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "Fecha y firma",
- "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Nombre de usuario</a> (<a href='#' title='$2:Username'>discusión</a>) 15:54, 10 June 2009 (UTC)",
+ "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Nombre de usuario</a> (<a href='#' title='$2:Username'>discusión</a>) 15:54, 10 de junio de 2009 (UTC)",
"wikieditor-toolbar-help-content-signature-description": "Firma",
"wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>Nombre de usuario</a> (<a href='#' title='$2:Username'>discusión</a>)",
"wikieditor-toolbar-help-content-indent-description": "Sangría",
diff --git a/www/wiki/extensions/WikiEditor/i18n/et.json b/www/wiki/extensions/WikiEditor/i18n/et.json
index b89c70e9..bb8724ae 100644
--- a/www/wiki/extensions/WikiEditor/i18n/et.json
+++ b/www/wiki/extensions/WikiEditor/i18n/et.json
@@ -8,26 +8,12 @@
]
},
"wikieditor": "Vikiteksti laiendatud redigeerimisliides",
- "wikieditor-desc": "Sisaldab vikiteksti laiendatud redigeerimisliidest ja palju redigeerimisfunktsioone.",
+ "wikieditor-desc": "Sisaldab võimalusterohkemat ja laiendatavat redigeerimisliidest.",
"wikieditor-wikitext-tab": "Vikitekst",
"wikieditor-loading": "Laadimine...",
- "wikieditor-preview-preference": "Kasuta kõrvalkaardil kuvatavat eelvaadet",
- "wikieditor-preview-tab": "Eelvaade",
- "wikieditor-preview-changes-tab": "Muudatused",
- "wikieditor-preview-loading": "Laadimine...",
- "wikieditor-publish-preference": "Kasuta astmelist avaldamist",
- "wikieditor-publish-button-publish": "Avalda",
- "wikieditor-publish-button-cancel": "Loobu",
- "wikieditor-publish-dialog-title": "{{GRAMMAR:inessive|{{SITENAME}}}} avaldamine",
- "wikieditor-publish-dialog-summary": "Redaktsiooni kokkuvõte (kirjelda lühidalt tehtud muudatusi):",
- "wikieditor-publish-dialog-minor": "Pisimuudatus",
- "wikieditor-publish-dialog-watch": "Jälgi seda lehekülge",
- "wikieditor-publish-dialog-publish": "Avalda",
- "wikieditor-publish-dialog-goback": "Tagasi",
"wikieditor-toolbar": "Toimetamise tööriistariba",
"wikieditor-toolbar-desc": "Täiustatud kasutushõlpsusega redigeerimislehekülje tööriistariba",
"wikieditor-toolbar-preference": "Kasuta laiendatud redigeerimisriba",
- "wikieditor-toolbar-dialogs-preference": "Kasuta viisardeid tabelite lisamisel ning otsi- ja asendusfunktsiooni jaoks",
"wikieditor-toolbar-loading": "Laadimine...",
"wikieditor-toolbar-tool-bold": "Rasvane",
"wikieditor-toolbar-tool-bold-example": "Rasvane kiri",
diff --git a/www/wiki/extensions/WikiEditor/i18n/eu.json b/www/wiki/extensions/WikiEditor/i18n/eu.json
index f815771f..1b1ed7d6 100644
--- a/www/wiki/extensions/WikiEditor/i18n/eu.json
+++ b/www/wiki/extensions/WikiEditor/i18n/eu.json
@@ -9,26 +9,14 @@
"Macofe",
"Sator",
"Subi",
- "Theklan"
+ "Theklan",
+ "Iñaki LL"
]
},
"wikieditor": "Wikitestu edizio-interfaze aurreratua",
"wikieditor-desc": "Wikitestua editatzeko interfazea eta ezaugarri berriak ematen ditu",
"wikieditor-wikitext-tab": "Wikitestua",
"wikieditor-loading": "Kargatzen",
- "wikieditor-preview-preference": "Aldetik aldeko aurrikuspena gaitu",
- "wikieditor-preview-tab": "Aurreikuspena",
- "wikieditor-preview-changes-tab": "Aldaketak",
- "wikieditor-preview-loading": "Kargatzen...",
- "wikieditor-publish-preference": "Pausoz pausoko argitarapena ahalbideratu",
- "wikieditor-publish-button-publish": "Argitaratu",
- "wikieditor-publish-button-cancel": "Utzi",
- "wikieditor-publish-dialog-title": "{{SITENAME}}era argitaratu",
- "wikieditor-publish-dialog-summary": "Laburpena (azaldu itzazu egin dituzun aldaketak, laburki):",
- "wikieditor-publish-dialog-minor": "Aldaketa txikia",
- "wikieditor-publish-dialog-watch": "Orrialde hau jarraitu",
- "wikieditor-publish-dialog-publish": "Argitaratu",
- "wikieditor-publish-dialog-goback": "Atzera joan",
"wikieditor-toolbar": "Tresna-barra aldatzen",
"wikieditor-toolbar-desc": "Orrialdeko editatzeko barra aldatu era erabilgarritasun hobetuarekin",
"wikieditor-toolbar-preference": "Editatzeko tresna barra hobetua gaitu",
@@ -91,7 +79,7 @@
"wikieditor-toolbar-tool-heading-3": "3. maila",
"wikieditor-toolbar-tool-heading-4": "4. maila",
"wikieditor-toolbar-tool-heading-5": "5. maila",
- "wikieditor-toolbar-tool-heading-example": "&#32;Izenburuaren testua&#32;",
+ "wikieditor-toolbar-tool-heading-example": "&#32;Azpiatalburuko testua&#32;",
"wikieditor-toolbar-group-format": "Formatua",
"wikieditor-toolbar-tool-ulist": "Puntudun zerrenda",
"wikieditor-toolbar-tool-ulist-example": "Puntudun zerrendako elementua",
@@ -116,7 +104,7 @@
"wikieditor-toolbar-tool-table": "Taula",
"wikieditor-toolbar-tool-table-example-old": "-\n! goiburua 1\n! goiburua 2\n! goiburua 3\n|-\n| errenkada 1, gela 1\n| errenkada 1, gela 2\n| errenkada 1, gela 3\n|-\n| errenkada 2, gela 1\n| errenkada 2, gela 2\n| errenkada 2, gela 3",
"wikieditor-toolbar-tool-table-example-cell-text": "Gelatxo testua",
- "wikieditor-toolbar-tool-table-example-header": "Goiburu testua",
+ "wikieditor-toolbar-tool-table-example-header": "Atalburuko testua",
"wikieditor-toolbar-tool-table-title": "Taula txertatu",
"wikieditor-toolbar-tool-table-dimensions-rows": "Errenkadak",
"wikieditor-toolbar-tool-table-dimensions-columns": "Zutabeak",
@@ -151,7 +139,7 @@
"wikieditor-toolbar-help-heading-result": "Lortzen duzuna",
"wikieditor-toolbar-help-page-format": "Formatua ematen",
"wikieditor-toolbar-help-page-link": "Loturak",
- "wikieditor-toolbar-help-page-heading": "Goiburuak",
+ "wikieditor-toolbar-help-page-heading": "Atalburuak",
"wikieditor-toolbar-help-page-list": "Zerrendak",
"wikieditor-toolbar-help-page-file": "Fitxategiak",
"wikieditor-toolbar-help-page-reference": "Erreferentziak",
@@ -166,23 +154,23 @@
"wikieditor-toolbar-help-content-bolditalic-syntax": "'''''Letra lodi eta etzaneko testua'''''",
"wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>Letra lodi eta etzaneko testua</em></strong>",
"wikieditor-toolbar-help-content-ilink-description": "Barne lotura",
- "wikieditor-toolbar-help-content-ilink-syntax": "[[Orriaren titulua]]<br />[[Orriaren titulua|Loturaren etiketa]]",
- "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Orriaren titulua</a><br /><a href='#'>Etiketaren lotura</a>",
+ "wikieditor-toolbar-help-content-ilink-syntax": "[[Orriaren izenburua]]<br />[[Orriaren izenburua|Loturaren etiketa]]",
+ "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Orriaren izenburua</a><br /><a href='#'>Etiketaren lotura</a>",
"wikieditor-toolbar-help-content-xlink-description": "Kanpo lotura",
"wikieditor-toolbar-help-content-xlink-syntax": "[http://www.adibidea.org Loturaren izena]<br />[http://www.adibidea.org]<br />http://www.adibidea.org",
"wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>Loturaren izena</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.adibidea.org</a>",
"wikieditor-toolbar-help-content-heading2-description": "2. mailako goiburua",
- "wikieditor-toolbar-help-content-heading2-syntax": "== Izenburuaren testua ==",
- "wikieditor-toolbar-help-content-heading2-result": "<h2>Izenburuaren testua</h2>",
+ "wikieditor-toolbar-help-content-heading2-syntax": "== Atalburuko testua ==",
+ "wikieditor-toolbar-help-content-heading2-result": "<h2>Azpiatalburuko testua</h2>",
"wikieditor-toolbar-help-content-heading3-description": "3. mailako izenburua",
- "wikieditor-toolbar-help-content-heading3-syntax": "=== Izenburuaren testua ===",
- "wikieditor-toolbar-help-content-heading3-result": "<h3>Izenburuaren testua</h3>",
+ "wikieditor-toolbar-help-content-heading3-syntax": "=== Azpiatalburuko testua ===",
+ "wikieditor-toolbar-help-content-heading3-result": "<h3>Azpiatalburuko testua</h3>",
"wikieditor-toolbar-help-content-heading4-description": "4. mailako izenburua",
- "wikieditor-toolbar-help-content-heading4-syntax": "==== Izenburuaren testua ====",
- "wikieditor-toolbar-help-content-heading4-result": "<h4>Izenburuaren testua</h4>",
+ "wikieditor-toolbar-help-content-heading4-syntax": "==== Atalburuko testua ====",
+ "wikieditor-toolbar-help-content-heading4-result": "<h4>2. azpiatalburuko testua</h4>",
"wikieditor-toolbar-help-content-heading5-description": "5. mailako izenburua",
- "wikieditor-toolbar-help-content-heading5-syntax": "===== Izenburuaren testua =====",
- "wikieditor-toolbar-help-content-heading5-result": "<h5>Izenburuaren testua</h5>",
+ "wikieditor-toolbar-help-content-heading5-syntax": "===== 3. azpiatalburuko testua =====",
+ "wikieditor-toolbar-help-content-heading5-result": "<h5>3. azpiatalburuko testua</h5>",
"wikieditor-toolbar-help-content-ulist-description": "Puntudun zerrenda",
"wikieditor-toolbar-help-content-ulist-syntax": "* Zerrendako elementua<br />* Zerrendako elementua",
"wikieditor-toolbar-help-content-ulist-result": "<ul><li>Zerrendako elementua</li><li>Zerrendako elementua</li></ul>",
diff --git a/www/wiki/extensions/WikiEditor/i18n/fa.json b/www/wiki/extensions/WikiEditor/i18n/fa.json
index 5dfa5d61..7a3d21ea 100644
--- a/www/wiki/extensions/WikiEditor/i18n/fa.json
+++ b/www/wiki/extensions/WikiEditor/i18n/fa.json
@@ -10,30 +10,17 @@
"Wayiran",
"ZxxZxxZ",
"Alirezaaa",
- "MohandesWiki"
+ "MohandesWiki",
+ "Alifakoor"
]
},
"wikieditor": "رابط ویرایش پیشرفته ویکی‌متن",
- "wikieditor-desc": "یک رابط ویرایش پیشرفته ویکی‌متن و چندین پودمان دارای قابلیت فراهم می‌کند",
+ "wikieditor-desc": "یک رابط ویرایش پیشرفته ویکی‌متن فراهم می‌کند",
"wikieditor-wikitext-tab": "ویکی‌متن",
"wikieditor-loading": "در حال بارگیری...",
- "wikieditor-preview-preference": "پیش‌نمایش کنار متن فعال شود",
- "wikieditor-preview-tab": "پیش‌نمایش",
- "wikieditor-preview-changes-tab": "تغییرها",
- "wikieditor-preview-loading": "در حال بارگیری...",
- "wikieditor-publish-preference": "انتشار گام‌به‌گام فعال شود",
- "wikieditor-publish-button-publish": "انتشار",
- "wikieditor-publish-button-cancel": "لغو",
- "wikieditor-publish-dialog-title": "انتشار در {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "خلاصه ویرایش (توضیح مختصر در مورد تغییری که دادید):",
- "wikieditor-publish-dialog-minor": "ویرایش جزئی",
- "wikieditor-publish-dialog-watch": "پی‌گیری این صفحه",
- "wikieditor-publish-dialog-publish": "انتشار",
- "wikieditor-publish-dialog-goback": "بازگشت به عقب",
"wikieditor-toolbar": "نوار ابزار ویرایش",
"wikieditor-toolbar-desc": "نوار ابزار ویرایش صفحه با استفاده‌پذیری بالاتر",
"wikieditor-toolbar-preference": "نوارابزار ویرایش پیشرفته فعال شود",
- "wikieditor-toolbar-dialogs-preference": "پنجره‌های تعاملی برای وارد کردن پیوندها، جدول‌ها و دستور جستجو و جایگزینی فعال شود",
"wikieditor-toolbar-loading": "در حال بارگیری...",
"wikieditor-toolbar-tool-bold": "پررنگ",
"wikieditor-toolbar-tool-bold-example": "متن پررنگ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/fi.json b/www/wiki/extensions/WikiEditor/i18n/fi.json
index b64dead2..a1b180bc 100644
--- a/www/wiki/extensions/WikiEditor/i18n/fi.json
+++ b/www/wiki/extensions/WikiEditor/i18n/fi.json
@@ -23,23 +23,9 @@
"wikieditor-desc": "Tarjoaa laajennettavan muokkauskäyttöliittymän wikitekstille ja muita toimintoja.",
"wikieditor-wikitext-tab": "Wikiteksti",
"wikieditor-loading": "Ladataan",
- "wikieditor-preview-preference": "Ota käyttöön vierekkäinen esikatselu",
- "wikieditor-preview-tab": "Esikatselu",
- "wikieditor-preview-changes-tab": "Muutokset",
- "wikieditor-preview-loading": "Ladataan…",
- "wikieditor-publish-preference": "Ota käyttöön vaiheittainen julkaisu",
- "wikieditor-publish-button-publish": "Julkaise",
- "wikieditor-publish-button-cancel": "Peruuta",
- "wikieditor-publish-dialog-title": "Julkaise {{GRAMMAR:inessive|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Muokkausyhteenveto (kuvaa lyhyesti tekemiäsi muutoksia):",
- "wikieditor-publish-dialog-minor": "Pieni muutos",
- "wikieditor-publish-dialog-watch": "Tarkkaile tätä sivua",
- "wikieditor-publish-dialog-publish": "Julkaise",
- "wikieditor-publish-dialog-goback": "Palaa takaisin",
"wikieditor-toolbar": "Työkalupalkki muokkaukseen",
"wikieditor-toolbar-desc": "Muokkaussivun työkalupalkki paremmalla käytettävyydellä.",
"wikieditor-toolbar-preference": "Ota käyttöön parannettu työkalupalkki muokkauksissa",
- "wikieditor-toolbar-dialogs-preference": "Ota käyttöön aputoiminnot, joiden avulla voit lisätä linkkejä ja taulukoita sekä etsiä ja korvata tekstiä",
"wikieditor-toolbar-loading": "Ladataan…",
"wikieditor-toolbar-tool-bold": "Lihavointi",
"wikieditor-toolbar-tool-bold-example": "Lihavoitu teksti",
diff --git a/www/wiki/extensions/WikiEditor/i18n/fr.json b/www/wiki/extensions/WikiEditor/i18n/fr.json
index d3d341c5..c9b9fd87 100644
--- a/www/wiki/extensions/WikiEditor/i18n/fr.json
+++ b/www/wiki/extensions/WikiEditor/i18n/fr.json
@@ -17,26 +17,14 @@
"Zetud",
"Macofe",
"Djiboun",
- "Freak2fast4u"
+ "Freak2fast4u",
+ "Wladek92"
]
},
"wikieditor": "Interface avancée de modification de wikitexte",
- "wikieditor-desc": "Fournit une interface de modification de wikitexte extensible et de nombreuses fonctionnalités.",
+ "wikieditor-desc": "Fournit une interface de modification de texte wiki avancée et extensible.",
"wikieditor-wikitext-tab": "Wikitexte",
"wikieditor-loading": "Chargement en cours...",
- "wikieditor-preview-preference": "Activer la prévisualisation côte à côte",
- "wikieditor-preview-tab": "Prévisualiser",
- "wikieditor-preview-changes-tab": "Changements",
- "wikieditor-preview-loading": "Chargement...",
- "wikieditor-publish-preference": "Activer la publication étape par étape",
- "wikieditor-publish-button-publish": "Publier",
- "wikieditor-publish-button-cancel": "Annuler",
- "wikieditor-publish-dialog-title": "Publier sur {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Résumé de modification (décrivez brièvement les changements que vous avez apportés) :",
- "wikieditor-publish-dialog-minor": "Modification mineure",
- "wikieditor-publish-dialog-watch": "Suivre cette page",
- "wikieditor-publish-dialog-publish": "Publier",
- "wikieditor-publish-dialog-goback": "Retour",
"wikieditor-toolbar": "Barre d’outils de modification",
"wikieditor-toolbar-desc": "Barre d’outils de modification avec l’utilisabilité améliorée",
"wikieditor-toolbar-preference": "Activer la barre d’outils améliorée",
diff --git a/www/wiki/extensions/WikiEditor/i18n/frp.json b/www/wiki/extensions/WikiEditor/i18n/frp.json
index 949eee33..bc266a12 100644
--- a/www/wiki/extensions/WikiEditor/i18n/frp.json
+++ b/www/wiki/extensions/WikiEditor/i18n/frp.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Balye una entèrface de changement de vouiquitèxto èxtensibla et un mouél de fonccionalitâts.",
"wikieditor-wikitext-tab": "Vouiquitèxto",
"wikieditor-loading": "Chargement",
- "wikieditor-preview-preference": "Activar la prèvisualisacion a châ couta",
- "wikieditor-preview-tab": "Prèvisualisacion",
- "wikieditor-preview-changes-tab": "Changements",
- "wikieditor-preview-loading": "Chargement...",
- "wikieditor-publish-preference": "Activar la publecacion a châ ètapa",
- "wikieditor-publish-button-publish": "Publeyér",
- "wikieditor-publish-button-cancel": "Anular",
- "wikieditor-publish-dialog-title": "Publeyér dessus {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Rèsumâ de changement (dècrîde en grôs los changements que vos éd fêts) :",
- "wikieditor-publish-dialog-minor": "Petiôt changement",
- "wikieditor-publish-dialog-watch": "Siuvre ceta pâge",
- "wikieditor-publish-dialog-publish": "Publeyér",
- "wikieditor-publish-dialog-goback": "Retôrn",
"wikieditor-toolbar": "Bârra d’outils d’èdicion",
"wikieditor-toolbar-desc": "Bârra d’outils d’èdicion avouéc l’utilisabilitât mèlyorâ",
"wikieditor-toolbar-preference": "Activar la bârra d’outils d’èdicion mèlyorâ",
- "wikieditor-toolbar-dialogs-preference": "Activar les bouètes de dialogo por apondre des lims, des tablôs et ples",
"wikieditor-toolbar-loading": "Chargement...",
"wikieditor-toolbar-tool-bold": "Grâs",
"wikieditor-toolbar-tool-bold-example": "Tèxto en grâs",
diff --git a/www/wiki/extensions/WikiEditor/i18n/fur.json b/www/wiki/extensions/WikiEditor/i18n/fur.json
index e6293abb..bdacd50a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/fur.json
+++ b/www/wiki/extensions/WikiEditor/i18n/fur.json
@@ -4,9 +4,6 @@
"Klenje"
]
},
- "wikieditor-preview-tab": "Anteprime",
- "wikieditor-preview-changes-tab": "Cambiaments",
- "wikieditor-preview-loading": "Daûr a cjamâ…",
"wikieditor-toolbar-loading": "Daûr a cjamâ…",
"wikieditor-toolbar-tool-bold": "Gruessut",
"wikieditor-toolbar-tool-bold-example": "Test in gruessut",
diff --git a/www/wiki/extensions/WikiEditor/i18n/fy.json b/www/wiki/extensions/WikiEditor/i18n/fy.json
index 0fefb44a..1e566e6b 100644
--- a/www/wiki/extensions/WikiEditor/i18n/fy.json
+++ b/www/wiki/extensions/WikiEditor/i18n/fy.json
@@ -2,10 +2,10 @@
"@metadata": {
"authors": [
"Kening Aldgilles",
- "Robin0van0der0vliet"
+ "Robin0van0der0vliet",
+ "Robin van der Vliet"
]
},
- "wikieditor-publish-button-cancel": "Annulearje",
"wikieditor-toolbar": "Bewurkingsbalke",
"wikieditor-toolbar-tool-bold": "Fet",
"wikieditor-toolbar-tool-italic": "Kursyf",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ga.json b/www/wiki/extensions/WikiEditor/i18n/ga.json
index e4d4a2dc..a7b8447a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ga.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ga.json
@@ -1,24 +1,41 @@
{
"@metadata": {
"authors": [
- "පසිඳු කාවින්ද"
+ "පසිඳු කාවින්ද",
+ "Nmacu"
]
},
"wikieditor-loading": "Ag Lódáil....",
- "wikieditor-preview-tab": "Réamhamharc",
- "wikieditor-preview-loading": "Ag Lódáil....",
- "wikieditor-publish-button-cancel": "Cealaigh",
"wikieditor-toolbar-loading": "Ag Lódáil....",
+ "wikieditor-toolbar-tool-link-title": "Ionsáigh nasc",
+ "wikieditor-toolbar-tool-link-insert": "Ionsáigh nasc",
"wikieditor-toolbar-tool-link-cancel": "Cealaigh",
+ "wikieditor-toolbar-tool-file-title": "Ionsáigh comhad",
"wikieditor-toolbar-file-format": "Formáid:",
+ "wikieditor-toolbar-tool-file-insert": "Ionsáigh",
"wikieditor-toolbar-tool-file-cancel": "Cealaigh",
+ "wikieditor-toolbar-tool-reference-example": "Ionsáigh téacs an fhonóta anseo",
"wikieditor-toolbar-tool-reference-cancel": "Cealaigh",
+ "wikieditor-toolbar-tool-reference-insert": "Ionsáigh",
+ "wikieditor-toolbar-tool-heading": "Ceannteideal",
+ "wikieditor-toolbar-tool-heading-example": "Téacs an cheannteidil",
"wikieditor-toolbar-group-format": "Formáid",
+ "wikieditor-toolbar-tool-nowiki-example": "Ionsáigh téacs neamhfhormáidithe anseo",
+ "wikieditor-toolbar-group-insert": "Ionsáigh",
+ "wikieditor-toolbar-tool-table-title": "Ionsáigh tábla",
"wikieditor-toolbar-tool-table-preview": "Réamhamharc",
+ "wikieditor-toolbar-tool-table-insert": "Ionsáigh",
"wikieditor-toolbar-tool-table-cancel": "Cealaigh",
"wikieditor-toolbar-tool-replace-close": "Dún",
"wikieditor-toolbar-section-help": "Cuidiú",
+ "wikieditor-toolbar-help-page-heading": "Ceannteidil",
"wikieditor-toolbar-help-page-file": "Comhaid",
"wikieditor-toolbar-help-page-discussion": "Plé",
+ "wikieditor-toolbar-help-content-heading2-description": "Ceannteideal leibhéal 2",
+ "wikieditor-toolbar-help-content-heading2-result": "<h2>Téacs an cheannteidil</h2>",
+ "wikieditor-toolbar-help-content-heading3-syntax": "=== Téacs an cheannteidil ===",
+ "wikieditor-toolbar-help-content-heading4-description": "Ceannteideal leibhéal 4",
+ "wikieditor-toolbar-help-content-heading4-result": "<h4>Téacs an cheannteidil</h4>",
+ "wikieditor-toolbar-help-content-heading5-syntax": "===== Téacs an cheannteidil =====",
"wikieditor-toolbar-help-content-signature-description": "Síniú"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/gd.json b/www/wiki/extensions/WikiEditor/i18n/gd.json
index 1816ac7a..c025c51c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/gd.json
+++ b/www/wiki/extensions/WikiEditor/i18n/gd.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Bheir seo dhut eadar-aghaidh deasachadh wikitext adhartach agus iomadh mòideal a bheir dhut feartan",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "'Ga luchdadh",
- "wikieditor-preview-preference": "Cuir an comas ro-shealladh taobh ri taobh",
- "wikieditor-preview-tab": "Ro-shealladh",
- "wikieditor-preview-changes-tab": "Mùthaidhean",
- "wikieditor-preview-loading": "'Ga luchdadh...",
- "wikieditor-publish-preference": "Cuir an comas foillseachadh ceum air cheum",
- "wikieditor-publish-button-publish": "Foillisch",
- "wikieditor-publish-button-cancel": "Sguir dheth",
- "wikieditor-publish-dialog-title": "Foillsich gu {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Gearr-chunntas an deasachaidh (mìnich na rinn thu gu goirid):",
- "wikieditor-publish-dialog-minor": "Mùthadh beag",
- "wikieditor-publish-dialog-watch": "Cum sùil air an duilleag seo",
- "wikieditor-publish-dialog-publish": "Foillisch",
- "wikieditor-publish-dialog-goback": "Air ais",
"wikieditor-toolbar": "Am bàr-inneil deasachaidh",
"wikieditor-toolbar-desc": "Am bàr-inneil deasachaidh le comasan a bharrachd",
"wikieditor-toolbar-preference": "Cuir am bàr-inneil le comasan a bharrachd an comas",
- "wikieditor-toolbar-dialogs-preference": "Cuir an comas na draoidhean airson ceanglaichean, clàran agus am foincsean airson lorg a dhèanamh no rudan a chur an àite rudan eile",
"wikieditor-toolbar-loading": "'Ga luchdadh...",
"wikieditor-toolbar-tool-bold": "Trom",
"wikieditor-toolbar-tool-bold-example": "Teacs trom",
diff --git a/www/wiki/extensions/WikiEditor/i18n/gl.json b/www/wiki/extensions/WikiEditor/i18n/gl.json
index 79ef6a1c..fe4bd123 100644
--- a/www/wiki/extensions/WikiEditor/i18n/gl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/gl.json
@@ -7,26 +7,12 @@
]
},
"wikieditor": "Interface avanzada de edición de texto wiki",
- "wikieditor-desc": "Proporciona unha interface extensible de edición de texto wiki e moitas funcionalidades de módulos",
+ "wikieditor-desc": "Proporciona unha interface avanzada e extensible de edición de texto wiki",
"wikieditor-wikitext-tab": "Texto wiki",
"wikieditor-loading": "Cargando...",
- "wikieditor-preview-preference": "Activar a vista previa comparativa",
- "wikieditor-preview-tab": "Vista previa",
- "wikieditor-preview-changes-tab": "Cambios",
- "wikieditor-preview-loading": "Cargando...",
- "wikieditor-publish-preference": "Activar a publicación paso a paso",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Cancelar",
- "wikieditor-publish-dialog-title": "Publicar en {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resumo de edición (describa brevemente os cambios que fixo):",
- "wikieditor-publish-dialog-minor": "Edición pequena",
- "wikieditor-publish-dialog-watch": "Vixiar esta páxina",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Volver",
"wikieditor-toolbar": "Barra de ferramentas de edición",
"wikieditor-toolbar-desc": "Editar a páxina da barra de ferramentas cunha mellor usabilidade",
"wikieditor-toolbar-preference": "Activar a barra de ferramentas de edición mellorada",
- "wikieditor-toolbar-dialogs-preference": "Activar os diálogos para engadir ligazóns, táboas, así como a función de buscar e substituír",
"wikieditor-toolbar-loading": "Cargando...",
"wikieditor-toolbar-tool-bold": "Negra",
"wikieditor-toolbar-tool-bold-example": "Texto en negra",
diff --git a/www/wiki/extensions/WikiEditor/i18n/grc.json b/www/wiki/extensions/WikiEditor/i18n/grc.json
index 5b0fb6f0..9050c116 100644
--- a/www/wiki/extensions/WikiEditor/i18n/grc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/grc.json
@@ -4,7 +4,6 @@
"Crazymadlover"
]
},
- "wikieditor-publish-button-cancel": "Ἀκυροῦν",
"wikieditor-toolbar": "Ἐργαλειοθήκη μεταγραφῆς",
"wikieditor-toolbar-loading": "Φορτίζειν…",
"wikieditor-toolbar-tool-bold": "ἔντονον",
diff --git a/www/wiki/extensions/WikiEditor/i18n/gsw.json b/www/wiki/extensions/WikiEditor/i18n/gsw.json
index 0499d248..37b8bb94 100644
--- a/www/wiki/extensions/WikiEditor/i18n/gsw.json
+++ b/www/wiki/extensions/WikiEditor/i18n/gsw.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Stellt e uusklappbari Wikitext-Bearbeitigsoberflechi z Verfiegig un vili Modul mit extra Megligkeite",
"wikieditor-wikitext-tab": "WikiText",
"wikieditor-loading": "Am Lade",
- "wikieditor-preview-preference": "Gegeiniberstelligs-Vorschau meglig mache",
- "wikieditor-preview-tab": "Vorschau",
- "wikieditor-preview-changes-tab": "Änderige",
- "wikieditor-preview-loading": "Am Lade ...",
- "wikieditor-publish-preference": "Schritt-fir-Schritt-Vereffentlichung meglig mache",
- "wikieditor-publish-button-publish": "Publiziere",
- "wikieditor-publish-button-cancel": "Abbräche",
- "wikieditor-publish-dialog-title": "Uf {{SITENAME}} publiziere",
- "wikieditor-publish-dialog-summary": "Zämmefassig (churzi Bschryybig vu dr Änderige, wu du gmacht hesch):",
- "wikieditor-publish-dialog-minor": "Chleinigkeite sin gänderet wore",
- "wikieditor-publish-dialog-watch": "Die Syte beobachte",
- "wikieditor-publish-dialog-publish": "Publiziere",
- "wikieditor-publish-dialog-goback": "Zruck",
"wikieditor-toolbar": "Wärchzygchäschtli bearbeite",
"wikieditor-toolbar-desc": "Wärchzygchäschtli mit ere verbesserete Benutzerfrejndligkeit bearbeite",
"wikieditor-toolbar-preference": "Verbesseret Bearbeitigs-Wärchzygchäschtli meglig mache",
- "wikieditor-toolbar-dialogs-preference": "Dialog aktiviere zum Links, Tabälle usw. yysetze",
"wikieditor-toolbar-loading": "Am Lade ...",
"wikieditor-toolbar-tool-bold": "Fätt",
"wikieditor-toolbar-tool-bold-example": "Tekscht fätt",
diff --git a/www/wiki/extensions/WikiEditor/i18n/gu.json b/www/wiki/extensions/WikiEditor/i18n/gu.json
index 1139bfaa..465a39cf 100644
--- a/www/wiki/extensions/WikiEditor/i18n/gu.json
+++ b/www/wiki/extensions/WikiEditor/i18n/gu.json
@@ -13,23 +13,9 @@
"wikieditor-desc": "વિસ્તૃત વિકિલખાણ દેખાવ અને ઘણી સુવિધાઓ વાળા મોડ્યુલ્સ પૂરા પાડે છે",
"wikieditor-wikitext-tab": "વિકિલેખન (વિકિટેક્સ્ટ)‌",
"wikieditor-loading": "લવાઇ રહ્યું છે...",
- "wikieditor-preview-preference": "બાજુમાં પુન:અવલોકન ચાલુ રાખો",
- "wikieditor-preview-tab": "પૂર્વદર્શન",
- "wikieditor-preview-changes-tab": "ફેરફારો",
- "wikieditor-preview-loading": "લવાઇ રહ્યું છે...",
- "wikieditor-publish-preference": "ટપ્પા વાર પ્રકાશન કાર્યાન્વીત કરો",
- "wikieditor-publish-button-publish": "પ્રસિદ્ધ કરો",
- "wikieditor-publish-button-cancel": "રદ કરો",
- "wikieditor-publish-dialog-title": "{{SITENAME}} પર પ્રસિદ્ધ કરો",
- "wikieditor-publish-dialog-summary": "સારમાં ફેરફાર કરો. (તમે કરેલા ફેરફારનો સાર):",
- "wikieditor-publish-dialog-minor": "નાનકડો ફેરફાર",
- "wikieditor-publish-dialog-watch": "આ પાનાને ધ્યાનમાં રાખો",
- "wikieditor-publish-dialog-publish": "પ્રસિદ્ધ કરો",
- "wikieditor-publish-dialog-goback": "પાછાં જાવ",
"wikieditor-toolbar": "ફેરફાર સાધન કંપાસ",
"wikieditor-toolbar-desc": "પૃષ્ઠના ફેરફાર સાધનો ને વધારેલ વપરાશ સાધનો ધરાવતી પેટી ઉમેરી મુકો",
"wikieditor-toolbar-preference": "અદ્યતન સંપાદન સાધનો સક્રીય કરો",
- "wikieditor-toolbar-dialogs-preference": "કડીઓ, કોઠા અને અન્ય વસ્તુઓ ઉમેરવા સંભાષણ સક્રીય કરો",
"wikieditor-toolbar-loading": "લવાઇ રહ્યું છે...",
"wikieditor-toolbar-tool-bold": "ઘાટું",
"wikieditor-toolbar-tool-bold-example": "ઘાટું લખાણ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/gv.json b/www/wiki/extensions/WikiEditor/i18n/gv.json
index 9dfadaf3..3bdf5809 100644
--- a/www/wiki/extensions/WikiEditor/i18n/gv.json
+++ b/www/wiki/extensions/WikiEditor/i18n/gv.json
@@ -8,23 +8,9 @@
},
"wikieditor-wikitext-tab": "Teks wiki",
"wikieditor-loading": "Laadey",
- "wikieditor-preview-preference": "Lhiggey da roie-haishbynys çheu-ry-heu",
- "wikieditor-preview-tab": "Roie-haishbynys",
- "wikieditor-preview-changes-tab": "Caghlaaghyn",
- "wikieditor-preview-loading": "Laadey...",
- "wikieditor-publish-preference": "Lhiggey da soilshaghey magh beggan er veggan",
- "wikieditor-publish-button-publish": "Soilshaghey magh",
- "wikieditor-publish-button-cancel": "Dolley magh",
- "wikieditor-publish-dialog-title": "Soilshaghey magh myr {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Giare-choontey (insh dooin dy giare ny ren uss caghlaa):",
- "wikieditor-publish-dialog-minor": "Myn-arraghey",
- "wikieditor-publish-dialog-watch": "Freill arrey er y duillag shoh",
- "wikieditor-publish-dialog-publish": "Soilshaghey magh",
- "wikieditor-publish-dialog-goback": "Erash",
"wikieditor-toolbar": "Barr greieyn reaghey",
"wikieditor-toolbar-desc": "Barr greieyn reaghey tooilley yn-ymmydey",
"wikieditor-toolbar-preference": "Lhiggey da barr greieyn reaghey tooilley yn-ymmydey",
- "wikieditor-toolbar-dialogs-preference": "Lhiggey da kishtaghyn cooney dys cur stiagh kianglaghyn, taabylyn as reddyn elley",
"wikieditor-toolbar-loading": "Laadey...",
"wikieditor-toolbar-tool-bold": "Trome",
"wikieditor-toolbar-tool-bold-example": "Teks trome",
diff --git a/www/wiki/extensions/WikiEditor/i18n/he.json b/www/wiki/extensions/WikiEditor/i18n/he.json
index a1e0beae..8b0cc8b1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/he.json
+++ b/www/wiki/extensions/WikiEditor/i18n/he.json
@@ -11,26 +11,12 @@
]
},
"wikieditor": "ממשק מתקדם לעריכת טקסט ויקי",
- "wikieditor-desc": "מספקת מנשק עריכת ויקיטקסט הניתן להרחבה ומודולים המאפשרים להוסיף יכולות",
+ "wikieditor-desc": "מספק ממשק עריכה מתקדם וניתן להרחבה",
"wikieditor-wikitext-tab": "קוד ויקי",
"wikieditor-loading": "בטעינה...",
- "wikieditor-preview-preference": "הפעלת תצוגה מקדימה מקבילה",
- "wikieditor-preview-tab": "תצוגה מקדימה",
- "wikieditor-preview-changes-tab": "שינויים",
- "wikieditor-preview-loading": "נטען...",
- "wikieditor-publish-preference": "הפעלת פרסום \"צעד־אחר־צעד\"",
- "wikieditor-publish-button-publish": "פרסום",
- "wikieditor-publish-button-cancel": "ביטול",
- "wikieditor-publish-dialog-title": "פרסום אל {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "תקציר העריכה (תיאור קצר של השינויים שעשית):",
- "wikieditor-publish-dialog-minor": "עריכה משנית",
- "wikieditor-publish-dialog-watch": "מעקב אחר דף זה",
- "wikieditor-publish-dialog-publish": "פרסום",
- "wikieditor-publish-dialog-goback": "חזרה אחורה",
"wikieditor-toolbar": "סרגל עריכה",
"wikieditor-toolbar-desc": "סרגל עריכת הדף עם שמישות מורחבת",
"wikieditor-toolbar-preference": "הפעלת סרגל העריכה המשופר",
- "wikieditor-toolbar-dialogs-preference": "הפעלת אשפים להוספת קישורים, טבלאות וכפתור \"חיפוש והחלפה\"",
"wikieditor-toolbar-loading": "בטעינה...",
"wikieditor-toolbar-tool-bold": "הדגשה",
"wikieditor-toolbar-tool-bold-example": "טקסט מודגש",
@@ -63,7 +49,7 @@
"wikieditor-toolbar-tool-link-lookslikeinternal-int": "קישור פנימי",
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "קישור חיצוני",
"wikieditor-toolbar-tool-link-empty": "לא הזנת שום דבר לקשר אליו.",
- "wikieditor-toolbar-tool-file": "קובץ המוצג בדף",
+ "wikieditor-toolbar-tool-file": "קובץ מוטבע",
"wikieditor-toolbar-tool-file-example": "דוגמה.jpg",
"wikieditor-toolbar-tool-file-title": "הוספת קובץ",
"wikieditor-toolbar-file-target": "שם הקובץ:",
@@ -189,7 +175,7 @@
"wikieditor-toolbar-help-content-olist-description": "רשימה ממוספרת",
"wikieditor-toolbar-help-content-olist-syntax": "# פריט רשימה<br /># פריט רשימה",
"wikieditor-toolbar-help-content-olist-result": "<ol><li>פריט רשימה</li><li>פריט רשימה</li></ol>",
- "wikieditor-toolbar-help-content-file-description": "קובץ המוצג בדף",
+ "wikieditor-toolbar-help-content-file-description": "קובץ מוטבע",
"wikieditor-toolbar-help-content-file-syntax": "[[$1:דוגמה.png|$2|$3]]",
"wikieditor-toolbar-help-content-file-caption": "טקסט הכיתוב",
"wikieditor-toolbar-help-content-reference-description": "הערת שוליים",
diff --git a/www/wiki/extensions/WikiEditor/i18n/hi.json b/www/wiki/extensions/WikiEditor/i18n/hi.json
index c0046fe7..baeae05d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/hi.json
+++ b/www/wiki/extensions/WikiEditor/i18n/hi.json
@@ -14,18 +14,6 @@
"wikieditor-desc": "प्रदान करता है एक विकितेक्ष्त् एदितिङ् इन्तेर्फचे और् बहुत् सुविधा प्रदान कर्ता है मॉड्यूल",
"wikieditor-wikitext-tab": "विकिपाठ्य",
"wikieditor-loading": "लदान",
- "wikieditor-preview-preference": "सक्षम पक्ष ध्वारा पक्ष पूर्वावलोकन",
- "wikieditor-preview-tab": "पूर्वावलोकन",
- "wikieditor-preview-changes-tab": "बदलाव",
- "wikieditor-preview-loading": "लदान्",
- "wikieditor-publish-preference": "सक्श्म्",
- "wikieditor-publish-button-publish": "प्रकाशित करें",
- "wikieditor-publish-button-cancel": "रद्द करें",
- "wikieditor-publish-dialog-title": "{{SITENAME}} को छापा जाय",
- "wikieditor-publish-dialog-minor": "छोटा संपादन",
- "wikieditor-publish-dialog-watch": "इस पृष्ठ पे ध्यान रखेँ",
- "wikieditor-publish-dialog-publish": "प्रकाशित करें",
- "wikieditor-publish-dialog-goback": "पीछे जाइए",
"wikieditor-toolbar": "संपादन उपकरण पट्टी",
"wikieditor-toolbar-loading": "लोड हो रहा है...",
"wikieditor-toolbar-tool-bold": "गहरा",
diff --git a/www/wiki/extensions/WikiEditor/i18n/hr.json b/www/wiki/extensions/WikiEditor/i18n/hr.json
index b9956e1e..d4a474cf 100644
--- a/www/wiki/extensions/WikiEditor/i18n/hr.json
+++ b/www/wiki/extensions/WikiEditor/i18n/hr.json
@@ -15,19 +15,6 @@
"wikieditor-desc": "Pruža proširivo sučelje za uređivanje wikiteksta i više modula s raznim dodacima",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Učitavanje",
- "wikieditor-preview-preference": "Omogući usporedni pregled",
- "wikieditor-preview-tab": "Pregled",
- "wikieditor-preview-changes-tab": "Promjene",
- "wikieditor-preview-loading": "Učitavam…",
- "wikieditor-publish-preference": "Omogući postupno objavljivanje",
- "wikieditor-publish-button-publish": "Objaviti",
- "wikieditor-publish-button-cancel": "Odustani",
- "wikieditor-publish-dialog-title": "Objavi na {{GRAMMAR:dajalnik|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Uredi sažetak (kratko opišite promjene koje ste učinili):",
- "wikieditor-publish-dialog-minor": "Manja promjena",
- "wikieditor-publish-dialog-watch": "Prati ovu stranicu",
- "wikieditor-publish-dialog-publish": "Objaviti",
- "wikieditor-publish-dialog-goback": "Idi natrag",
"wikieditor-toolbar": "Alatna vrpca",
"wikieditor-toolbar-desc": "Alatna vrpca za uređivanje s poboljšanom uporabljivošću",
"wikieditor-toolbar-preference": "Omogući poboljšanu alatnu traku",
@@ -42,12 +29,12 @@
"wikieditor-toolbar-tool-xlink-example": "http://www.primjer.com naziv poveznice",
"wikieditor-toolbar-tool-link": "Poveznica",
"wikieditor-toolbar-tool-link-title": "Umetni poveznicu",
- "wikieditor-toolbar-tool-link-int": "U wiki stranicu",
+ "wikieditor-toolbar-tool-link-int": "U wikistranicu",
"wikieditor-toolbar-tool-link-int-target": "Naslov stranice:",
"wikieditor-toolbar-tool-link-int-target-tooltip": "Naslov ili URL stranice",
"wikieditor-toolbar-tool-link-int-text": "Tekst poveznice",
"wikieditor-toolbar-tool-link-int-text-tooltip": "Tekst za prikaz",
- "wikieditor-toolbar-tool-link-ext": "Za vanjske web stranice",
+ "wikieditor-toolbar-tool-link-ext": "Za vanjske web-stranice",
"wikieditor-toolbar-tool-link-ext-target": "URL poveznice:",
"wikieditor-toolbar-tool-link-ext-text": "Tekst poveznice:",
"wikieditor-toolbar-tool-link-insert": "Umetni poveznicu",
diff --git a/www/wiki/extensions/WikiEditor/i18n/hsb.json b/www/wiki/extensions/WikiEditor/i18n/hsb.json
index f95ca298..c45f9725 100644
--- a/www/wiki/extensions/WikiEditor/i18n/hsb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/hsb.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Steji rozšěrjujomny powjerch za wobdźěłowanje wikiteksta a wjele modulow k dispoziciji.",
"wikieditor-wikitext-tab": "WikiTekst",
"wikieditor-loading": "Začituje so",
- "wikieditor-preview-preference": "Přehlad bok po boku zmóžnić",
- "wikieditor-preview-tab": "Přehlad",
- "wikieditor-preview-changes-tab": "Změny",
- "wikieditor-preview-loading": "Začituje so...",
- "wikieditor-publish-preference": "Publikowanje krok po kroku zmóžnić",
- "wikieditor-publish-button-publish": "Wozjewić",
- "wikieditor-publish-button-cancel": "Přetorhnyć",
- "wikieditor-publish-dialog-title": "Do {{GRAMMAR:genitiw|{{SITENAME}}}} wozjewić",
- "wikieditor-publish-dialog-summary": "Zjeće změnow (wopisaj krótko změny, kotrež sy činił):",
- "wikieditor-publish-dialog-minor": "Snadna změna",
- "wikieditor-publish-dialog-watch": "Tutu stronu wobkedźbować",
- "wikieditor-publish-dialog-publish": "Wozjewić",
- "wikieditor-publish-dialog-goback": "Wróćo",
"wikieditor-toolbar": "Gratowa lajsta za wobdźěłowanje",
"wikieditor-toolbar-desc": "Gratowa lajsta za wobdźěłowanje stronow z polěpšenej wužiwajomnosću",
"wikieditor-toolbar-preference": "Polěpšenu gratowu lajstu za wobdźěłowanje aktiwizować",
- "wikieditor-toolbar-dialogs-preference": "Asistenty za zasadźenje wotkazow, tabelow a funkciju pytanja a wuměnjenja zmóžnić",
"wikieditor-toolbar-loading": "Čita so...",
"wikieditor-toolbar-tool-bold": "Tučny",
"wikieditor-toolbar-tool-bold-example": "Tučny tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/hu.json b/www/wiki/extensions/WikiEditor/i18n/hu.json
index 6eff7674..982e657d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/hu.json
+++ b/www/wiki/extensions/WikiEditor/i18n/hu.json
@@ -11,30 +11,17 @@
"Csega",
"Macofe",
"Tacsipacsi",
- "Bináris"
+ "Bináris",
+ "Bencemac"
]
},
"wikieditor": "Fejlett szerkesztőfelület wikiszöveghez",
"wikieditor-desc": "Bővíthető szerkesztőfelület wikiszöveghez és több, új funkciókat kínáló modul",
"wikieditor-wikitext-tab": "Wikiszöveg",
"wikieditor-loading": "Betöltés…",
- "wikieditor-preview-preference": "Előnézet egymás mellett engedélyezése",
- "wikieditor-preview-tab": "Előnézet",
- "wikieditor-preview-changes-tab": "Változtatások",
- "wikieditor-preview-loading": "Betöltés…",
- "wikieditor-publish-preference": "Lépésről lépésre közzététel engedélyezése",
- "wikieditor-publish-button-publish": "Közzététel",
- "wikieditor-publish-button-cancel": "Mégse",
- "wikieditor-publish-dialog-title": "Közzététel a(z) {{SITENAME}} wikin",
- "wikieditor-publish-dialog-summary": "Szerkesztési összefoglaló (pontosan írd le az általad végzett változtatásokat):",
- "wikieditor-publish-dialog-minor": "Apró szerkesztés",
- "wikieditor-publish-dialog-watch": "Lap figyelése",
- "wikieditor-publish-dialog-publish": "Közzététel",
- "wikieditor-publish-dialog-goback": "Vissza",
"wikieditor-toolbar": "Szerkesztő-eszköztár",
"wikieditor-toolbar-desc": "Használhatóbb szerkesztő eszköztár",
"wikieditor-toolbar-preference": "Fejlettebb szerkesztő-eszköztár használata",
- "wikieditor-toolbar-dialogs-preference": "Varázslók engedélyezése hivatkozások, táblázatok beillesztéséhez, valamint a keresés és csere funkcióhoz",
"wikieditor-toolbar-loading": "Betöltés…",
"wikieditor-toolbar-tool-bold": "Félkövér",
"wikieditor-toolbar-tool-bold-example": "Félkövér szöveg",
@@ -79,6 +66,7 @@
"wikieditor-toolbar-file-format-none": "nincs",
"wikieditor-toolbar-tool-file-insert": "Beszúrás",
"wikieditor-toolbar-tool-file-cancel": "Mégse",
+ "wikieditor-toolbar-tool-file-upload": "Feltöltés",
"wikieditor-toolbar-tool-reference": "Forráshivatkozás",
"wikieditor-toolbar-tool-reference-example": "Ide írd a lábjegyzet szövegét",
"wikieditor-toolbar-tool-reference-cancel": "Mégse",
diff --git a/www/wiki/extensions/WikiEditor/i18n/hy.json b/www/wiki/extensions/WikiEditor/i18n/hy.json
index 1cacb714..5efff8e1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/hy.json
+++ b/www/wiki/extensions/WikiEditor/i18n/hy.json
@@ -4,26 +4,14 @@
"Chaojoker",
"Vadgt",
"Xelgen",
- "Macofe"
+ "Macofe",
+ "23artashes"
]
},
"wikieditor-loading": "Բեռնվում է…",
- "wikieditor-preview-preference": "Միացնել կողք–կողքի նախադիտումը",
- "wikieditor-preview-tab": "Նախադիտել",
- "wikieditor-preview-changes-tab": "Փոփոխություններ",
- "wikieditor-preview-loading": "Բեռնում…",
- "wikieditor-publish-button-publish": "Հրատարակել",
- "wikieditor-publish-button-cancel": "Բեկանել",
- "wikieditor-publish-dialog-title": "Հրատարակել {{SITENAME}} նախագծում",
- "wikieditor-publish-dialog-summary": "Խմբագրման ամփոփում (հակիրճ նկարագրեք ձեր կատարած փոփոխությունները)",
- "wikieditor-publish-dialog-minor": "Չնչին խմբագրում",
- "wikieditor-publish-dialog-watch": "Հսկել այս էջը",
- "wikieditor-publish-dialog-publish": "Հրատարակել",
- "wikieditor-publish-dialog-goback": "Հետ գնալ",
"wikieditor-toolbar": "Խմբագրման վահանակ",
"wikieditor-toolbar-desc": "Բարձրացրած հարմարավետությամբ խմբագրման վահանակ",
"wikieditor-toolbar-preference": "Ակտիվացնել բարելավված խմբագրման վահանակը",
- "wikieditor-toolbar-dialogs-preference": "Ակտիվացնել երկխոսությունները հղումների, աղյուսակների և այլնի համար",
"wikieditor-toolbar-loading": "Բեռնում…",
"wikieditor-toolbar-tool-bold": "Թավատառ",
"wikieditor-toolbar-tool-bold-example": "Թավատառ տեքստ",
@@ -38,7 +26,7 @@
"wikieditor-toolbar-tool-link-int": "Վիքիի էջին",
"wikieditor-toolbar-tool-link-int-target": "Էջի վերնագիր․",
"wikieditor-toolbar-tool-link-int-target-tooltip": "Էջի վերնագիր կամ URL",
- "wikieditor-toolbar-tool-link-int-text": "Հղման տեսքստ․",
+ "wikieditor-toolbar-tool-link-int-text": "Հղման տեքստ․",
"wikieditor-toolbar-tool-link-int-text-tooltip": "Ներմուծեք տեքստը, որ պետք է ցուցադրվի",
"wikieditor-toolbar-tool-link-ext": "Արտաքին վեբ էջին",
"wikieditor-toolbar-tool-link-ext-target": "Հղման URL․",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ia.json b/www/wiki/extensions/WikiEditor/i18n/ia.json
index 9c7c429d..39aadf2d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ia.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ia.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Forni un interfacie de modification de wikitexto extensibile con multe modulos a functiones additional",
"wikieditor-wikitext-tab": "Wikitexto",
"wikieditor-loading": "Carga…",
- "wikieditor-preview-preference": "Activar le previsualisation latere a latere",
- "wikieditor-preview-tab": "Previsualisation",
- "wikieditor-preview-changes-tab": "Modificationes",
- "wikieditor-preview-loading": "Cargamento...",
- "wikieditor-publish-preference": "Activar publication passo a passo",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Cancellar",
- "wikieditor-publish-dialog-title": "Publicar in {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Summario del modification (describe brevemente le cambios que tu ha facite):",
- "wikieditor-publish-dialog-minor": "Modification minor",
- "wikieditor-publish-dialog-watch": "Observar iste pagina",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Retornar",
"wikieditor-toolbar": "Instrumentario de modification",
"wikieditor-toolbar-desc": "Barra con instrumentos de modification con augmento de usabilitate",
"wikieditor-toolbar-preference": "Activar le instrumentario de modification meliorate",
- "wikieditor-toolbar-dialogs-preference": "Activar dialogos pro inserer ligamines, tabellas e le function de cercar e reimplaciar",
"wikieditor-toolbar-loading": "Cargamento in curso…",
"wikieditor-toolbar-tool-bold": "Grasse",
"wikieditor-toolbar-tool-bold-example": "Texto grasse",
@@ -38,9 +24,9 @@
"wikieditor-toolbar-tool-link": "Ligamine",
"wikieditor-toolbar-tool-link-title": "Inserer ligamine",
"wikieditor-toolbar-tool-link-int": "A un pagina wiki",
- "wikieditor-toolbar-tool-link-int-target": "Titulo del pagina:",
+ "wikieditor-toolbar-tool-link-int-target": "Pagina o URL de destination:",
"wikieditor-toolbar-tool-link-int-target-tooltip": "Titulo o URL del pagina",
- "wikieditor-toolbar-tool-link-int-text": "Texto del ligamine:",
+ "wikieditor-toolbar-tool-link-int-text": "Texto a monstrar:",
"wikieditor-toolbar-tool-link-int-text-tooltip": "Entra le texto que debe esser monstrate",
"wikieditor-toolbar-tool-link-ext": "A un pagina web externe",
"wikieditor-toolbar-tool-link-ext-target": "URL del ligamine:",
@@ -115,8 +101,8 @@
"wikieditor-toolbar-tool-table-dimensions-columns": "Columnas",
"wikieditor-toolbar-tool-table-dimensions-header": "Includer linea de capite",
"wikieditor-toolbar-tool-table-wikitable": "Stilo con bordos",
- "wikieditor-toolbar-tool-table-sortable": "Render tabella assortibile",
- "wikieditor-toolbar-tool-table-example": "Texto del cellula",
+ "wikieditor-toolbar-tool-table-sortable": "Render le tabella ordinabile",
+ "wikieditor-toolbar-tool-table-example": "Exemplo",
"wikieditor-toolbar-tool-table-preview": "Previsualisation",
"wikieditor-toolbar-tool-table-insert": "Inserer",
"wikieditor-toolbar-tool-table-cancel": "Cancellar",
diff --git a/www/wiki/extensions/WikiEditor/i18n/id.json b/www/wiki/extensions/WikiEditor/i18n/id.json
index 47389c48..5bf27d88 100644
--- a/www/wiki/extensions/WikiEditor/i18n/id.json
+++ b/www/wiki/extensions/WikiEditor/i18n/id.json
@@ -9,30 +9,17 @@
"Kenrick95",
"William Surya Permana",
"Macofe",
- "WongKentir"
+ "WongKentir",
+ "Gombang"
]
},
"wikieditor": "Antarmuka penyuntingan teks wiki canggih",
"wikieditor-desc": "Menyediakan antarmuka penyuntingan teks wiki yang lebih berkembang dan banyak modul penyedia fitur",
"wikieditor-wikitext-tab": "TeksWiki",
"wikieditor-loading": "Pembebanan",
- "wikieditor-preview-preference": "Aktifkan pratayang bersisian",
- "wikieditor-preview-tab": "Pratayang",
- "wikieditor-preview-changes-tab": "Perubahan",
- "wikieditor-preview-loading": "Mengunggah...",
- "wikieditor-publish-preference": "Aktifkan penerbitan langkah demi langkah",
- "wikieditor-publish-button-publish": "Terbitkan",
- "wikieditor-publish-button-cancel": "Batalkan",
- "wikieditor-publish-dialog-title": "Terbitkan ke",
- "wikieditor-publish-dialog-summary": "Ringkasan suntingan (jelaskan dengan ringkas perubahan yang Anda buat):",
- "wikieditor-publish-dialog-minor": "Suntingan kecil",
- "wikieditor-publish-dialog-watch": "Pantau halaman ini",
- "wikieditor-publish-dialog-publish": "Terbitkan",
- "wikieditor-publish-dialog-goback": "Kembali",
"wikieditor-toolbar": "Bilah alat penyuntingan",
"wikieditor-toolbar-desc": "Bilah alat penyuntingan dengan kebergunaan yang ditingkatkan",
"wikieditor-toolbar-preference": "Aktifkan bilah alat penyuntingan yang telah ditingkatkan",
- "wikieditor-toolbar-dialogs-preference": "Aktifkan bantuan untuk menambahkan pranala, tabel dan lainnya",
"wikieditor-toolbar-loading": "Mengunggah...",
"wikieditor-toolbar-tool-bold": "Tebal",
"wikieditor-toolbar-tool-bold-example": "Teks tebal",
@@ -59,6 +46,7 @@
"wikieditor-toolbar-tool-link-int-target-status-invalid": "Judul tidak sah",
"wikieditor-toolbar-tool-link-int-target-status-external": "Pranala luar",
"wikieditor-toolbar-tool-link-int-target-status-loading": "Memeriksa keberadaan halaman...",
+ "wikieditor-toolbar-tool-link-int-target-status-disambig": "Halaman disambiguasi",
"wikieditor-toolbar-tool-link-int-invalid": "Judul yang Anda berikan tidak sah.",
"wikieditor-toolbar-tool-link-lookslikeinternal": "URL yang Anda berikan tampaknya merupakan pranala ke halaman wiki lain.\nApakah Anda ingin membuatnya menjadi pranala internal?",
"wikieditor-toolbar-tool-link-lookslikeinternal-int": "Pranala internal",
@@ -191,9 +179,13 @@
"wikieditor-toolbar-help-content-olist-result": "<ol><li>Isi daftar</li><li>Isi daftar</li></ol>",
"wikieditor-toolbar-help-content-file-description": "Menyisipkan berkas",
"wikieditor-toolbar-help-content-file-syntax": "[[$1:Example.png|$2|$3]]",
+ "wikieditor-toolbar-help-content-file-caption": "Teks keterangan",
"wikieditor-toolbar-help-content-reference-description": "Referensi",
"wikieditor-toolbar-help-content-reference-syntax": "Teks halaman.&lt;ref&gt;[http://www.contoh.org Teks pranala], teks tambahan.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "Teks halaman.<sup><a href='#'>[1]</a></sup>",
+ "wikieditor-toolbar-help-content-named-reference-description": "Referensi bernama",
+ "wikieditor-toolbar-help-content-named-reference-syntax": "Teks halaman.&lt;ref name=\"test\"&gt;[http://www.example.org teks pranala]&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-named-reference-result": "Teks halaman.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "Penggunaan kembali referensi yang sama",
"wikieditor-toolbar-help-content-rereference-result": "Teks halaman.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "Menampilkan referensi",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ig.json b/www/wiki/extensions/WikiEditor/i18n/ig.json
index 528789b9..af558445 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ig.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ig.json
@@ -5,13 +5,6 @@
]
},
"wikieditor-loading": "Ọ na biá",
- "wikieditor-preview-changes-tab": "Ihe gbanwere",
- "wikieditor-preview-loading": "Ọ biágó...",
- "wikieditor-publish-button-publish": "Bìpụta",
- "wikieditor-publish-button-cancel": "Kàchá",
- "wikieditor-publish-dialog-minor": "Orü ntà",
- "wikieditor-publish-dialog-publish": "Bìpụta",
- "wikieditor-publish-dialog-goback": "Gá na àzú",
"wikieditor-toolbar-loading": "Ọ biágó...",
"wikieditor-toolbar-tool-bold": "Shí íke",
"wikieditor-toolbar-tool-bold-example": "Mkpúrù èdè íke",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ilo.json b/www/wiki/extensions/WikiEditor/i18n/ilo.json
index a6a6eb0b..c1147038 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ilo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ilo.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Mangited ti mapadakkel nga interface ti panagurnos ti wikitext ken dagiti modulo a mangited ti adu a langa",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Agkarkarga...",
- "wikieditor-preview-preference": "Pakabaelan ti agabay a panagipadas",
- "wikieditor-preview-tab": "Ipadas",
- "wikieditor-preview-changes-tab": "Dagiti sinukatan",
- "wikieditor-preview-loading": "Agkarkarga...",
- "wikieditor-publish-preference": "Pakabaelan ti naiyaddang a panagipablaak",
- "wikieditor-publish-button-publish": "Ipablaak",
- "wikieditor-publish-button-cancel": "Ukasen",
- "wikieditor-publish-dialog-title": "Ipabablaak iti {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Pakapukpukan ti panagurnos (ipalawag bassit dagiti sinukatam) :",
- "wikieditor-publish-dialog-minor": "Bassit a panagurnos",
- "wikieditor-publish-dialog-watch": "Bantayan daytoy a panid",
- "wikieditor-publish-dialog-publish": "Ipablaak",
- "wikieditor-publish-dialog-goback": "Agsubli",
"wikieditor-toolbar": "Baras ti ramit ti panagurnos",
"wikieditor-toolbar-desc": "Baras ti ramit ti panagurnos nga addaan iti napasayaat a kaserbi",
"wikieditor-toolbar-preference": "Pakabaelan ti napasayaat a baras ti ramit ti panagurnos",
- "wikieditor-toolbar-dialogs-preference": "Pakabaelan dagiti mangngarading para iti panangisengngat kadagiti silpo, tabtabla ken ti pay annong ti panagbiruk ken panagisukat",
"wikieditor-toolbar-loading": "Agkarkarga...",
"wikieditor-toolbar-tool-bold": "Napuskol",
"wikieditor-toolbar-tool-bold-example": "Teksto a napuskol",
diff --git a/www/wiki/extensions/WikiEditor/i18n/inh.json b/www/wiki/extensions/WikiEditor/i18n/inh.json
index 6c890c16..6de88ddf 100644
--- a/www/wiki/extensions/WikiEditor/i18n/inh.json
+++ b/www/wiki/extensions/WikiEditor/i18n/inh.json
@@ -9,42 +9,50 @@
]
},
"wikieditor": "Викитекст хувцара шера интерфейс",
- "wikieditor-desc": "Iалашъю викитекст хувцара шералуш йола интерфейс а, модулеша оттаеш йола тайп-тайпара дукха функцеш а",
+ "wikieditor-desc": "Викитекст хувцара шералуш йола интерфейс а модулеша оттаеш йола тайп-тайпара функцеш а Iалашъю",
"wikieditor-wikitext-tab": "Викитекст",
"wikieditor-loading": "Доттар...",
- "wikieditor-preview-preference": "Лотае хьалххе бIаргтохар «уллув»",
- "wikieditor-preview-tab": "Хьалххе бIаргтохар",
- "wikieditor-preview-changes-tab": "Хувцамаш",
- "wikieditor-preview-loading": "Доттар...",
- "wikieditor-publish-preference": "Лотаé гIа боаккхаш еш йола публикаци",
- "wikieditor-publish-button-publish": "Арахеца",
- "wikieditor-publish-button-cancel": "Эшац",
- "wikieditor-publish-dialog-title": "{{SITENAME}} проекта чу арахецар",
- "wikieditor-publish-dialog-summary": "Хувцамах лаьца (лоаца белгалде (язде) малагIа хувцам ба Iа баьр)",
- "wikieditor-publish-dialog-minor": "ЗӀамига хувцам",
- "wikieditor-publish-dialog-watch": "Зем бе укх оагӀон",
- "wikieditor-publish-dialog-publish": "Арахеца",
- "wikieditor-publish-dialog-goback": "Юха",
+ "wikieditor-toolbar": "Хувцара панель",
+ "wikieditor-toolbar-desc": "Лелае дукха аттагIа йола хувцара панель",
+ "wikieditor-toolbar-preference": "Хьалотае тоая йола хувцара панель",
"wikieditor-toolbar-loading": "Доттар...",
"wikieditor-toolbar-tool-bold": "Сома",
"wikieditor-toolbar-tool-bold-example": "Сома йоазон текст",
"wikieditor-toolbar-tool-italic": "Сиха йоазув",
"wikieditor-toolbar-tool-italic-example": "Сиха йоазон текст",
- "wikieditor-toolbar-tool-ilink": "Чура тIахьожаярг",
- "wikieditor-toolbar-tool-ilink-example": "ТIахьожаярга дáкъа цIи",
- "wikieditor-toolbar-tool-xlink": "Арахьара тIахьожаярг (йиц ма ялийтта префикс http://)",
- "wikieditor-toolbar-tool-xlink-example": "http://www.example.com тIахьожаярга дáкъа цIи",
- "wikieditor-toolbar-tool-link": "ТIахьожаярг",
- "wikieditor-toolbar-tool-link-ext-target": "URL тIахьожаяргаш:",
+ "wikieditor-toolbar-tool-ilink": "Чура тӀатовжам",
+ "wikieditor-toolbar-tool-ilink-example": "ТӀатовжама кепакорт",
+ "wikieditor-toolbar-tool-xlink": "Арахьара тӀатовжам (йиц ма ялийтта префикс http://)",
+ "wikieditor-toolbar-tool-xlink-example": "http://www.example.com тӀатовжама кепакорт",
+ "wikieditor-toolbar-tool-link": "Тӏатовжам",
+ "wikieditor-toolbar-tool-link-title": "Чуоттабе тIатовжам",
+ "wikieditor-toolbar-tool-link-int": "Вики-оагӀонгахьа",
+ "wikieditor-toolbar-tool-link-int-target": "Дагалаьца оагӀув е URL:",
+ "wikieditor-toolbar-tool-link-int-target-tooltip": "ОагӀон цӀи е URL",
+ "wikieditor-toolbar-tool-link-int-text": "Гойташ йола текст:",
+ "wikieditor-toolbar-tool-link-int-text-tooltip": "Ӏочуязъе гуш хила езаш йола текст",
+ "wikieditor-toolbar-tool-link-ext": "Арахьарча оагӀонгахьа",
+ "wikieditor-toolbar-tool-link-ext-target": "ТIатовжама URL:",
+ "wikieditor-toolbar-tool-link-ext-text": "ТӀатовжама текст:",
+ "wikieditor-toolbar-tool-link-insert": "Чуоттабе тIатовжам",
"wikieditor-toolbar-tool-link-cancel": "Эшац",
- "wikieditor-toolbar-tool-link-int-target-status-external": "Арахьара тIахьожаярг",
- "wikieditor-toolbar-tool-link-lookslikeinternal-int": "Чура тIахьожаярг",
- "wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Арахьара тIахьожаярг",
- "wikieditor-toolbar-tool-file": "Чуоттаяь файл",
+ "wikieditor-toolbar-tool-link-int-target-status-exists": "Из оагӀув йолаш я",
+ "wikieditor-toolbar-tool-link-int-target-status-notexists": "Из оагӀув йоацаш я",
+ "wikieditor-toolbar-tool-link-int-target-status-invalid": "Мегаргйоаца цӀи",
+ "wikieditor-toolbar-tool-link-int-target-status-external": "Арахьара тIатовжам",
+ "wikieditor-toolbar-tool-link-int-target-status-loading": "ОагӀув йолаш хилар тахкар",
+ "wikieditor-toolbar-tool-link-int-target-status-disambig": "Дукха маӀанаш дола оагӀонаш",
+ "wikieditor-toolbar-tool-link-int-invalid": "Белгалъяь цӀи мегаргьяц",
+ "wikieditor-toolbar-tool-link-lookslikeinternal-int": "Чура тӏатовжам",
+ "wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Арахьара тIатовжам",
+ "wikieditor-toolbar-tool-link-empty": "ТIатовжа моттиг белгалъяь яц Iа",
+ "wikieditor-toolbar-tool-file": "Чуоттае файл",
"wikieditor-toolbar-tool-file-example": "Example.jpg",
+ "wikieditor-toolbar-tool-file-title": "Файл чуяккха",
"wikieditor-toolbar-file-target": "Файла цӀи:",
"wikieditor-toolbar-file-caption": "Кулг яздар:",
"wikieditor-toolbar-file-size": "Боарам:",
+ "wikieditor-toolbar-file-float": "Нийсдар:",
"wikieditor-toolbar-file-format": "Формат:",
"wikieditor-toolbar-tool-file-cancel": "Эшац",
"wikieditor-toolbar-tool-reference": "Белгалдоахар",
@@ -55,11 +63,11 @@
"wikieditor-toolbar-tool-heading-3": "ЛáгIа 3",
"wikieditor-toolbar-tool-heading-4": "ЛáгIа 4",
"wikieditor-toolbar-tool-heading-5": "ЛáгIа 5",
- "wikieditor-toolbar-tool-heading-example": "Дáкъа цIера текст",
+ "wikieditor-toolbar-tool-heading-example": "Кепакерта текст",
"wikieditor-toolbar-group-format": "Формат",
"wikieditor-toolbar-tool-nowiki": "Теркал ма е вики-форматировани",
"wikieditor-toolbar-tool-nowiki-example": "Укхаза хувца езаш йоаца текст хьачуоттае",
- "wikieditor-toolbar-tool-redirect": "ДIа-сахьожадар",
+ "wikieditor-toolbar-tool-redirect": "ДIа-хьа хьожавар",
"wikieditor-toolbar-tool-big": "Йоккха",
"wikieditor-toolbar-tool-big-example": "Йоккха текст",
"wikieditor-toolbar-tool-small": "ЗIамига",
@@ -67,5 +75,5 @@
"wikieditor-toolbar-tool-replace-search": "Хьалáха:",
"wikieditor-toolbar-section-characters": "ЛаьрххIа дола хьаракаш",
"wikieditor-toolbar-section-help": "Новкъoстал",
- "wikieditor-toolbar-help-page-link": "ТIахьожаяргаш"
+ "wikieditor-toolbar-help-page-link": "Тӏатовжамаш"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/io.json b/www/wiki/extensions/WikiEditor/i18n/io.json
index a2c490f4..9ad7dafc 100644
--- a/www/wiki/extensions/WikiEditor/i18n/io.json
+++ b/www/wiki/extensions/WikiEditor/i18n/io.json
@@ -2,14 +2,10 @@
"@metadata": {
"authors": [
"Malafaya",
- "Lakaoso"
+ "Lakaoso",
+ "Joao Xavier"
]
},
- "wikieditor-preview-changes-tab": "Chanji",
- "wikieditor-publish-button-cancel": "Anular",
- "wikieditor-publish-dialog-minor": "Mikra chanjo",
- "wikieditor-publish-dialog-watch": "Surveyar ca pagino",
- "wikieditor-publish-dialog-goback": "Retroirar",
"wikieditor-toolbar-tool-italic": "Kursiva",
"wikieditor-toolbar-tool-italic-example": "Kursiva texto",
"wikieditor-toolbar-tool-ilink": "Interna ligilo",
@@ -28,6 +24,7 @@
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Extera ligilo",
"wikieditor-toolbar-tool-file-example": "Exemplo.jpg",
"wikieditor-toolbar-tool-reference-insert": "Adjuntar",
+ "wikieditor-toolbar-section-advanced": "Plura utensili",
"wikieditor-toolbar-tool-heading-1": "Nivelo 1",
"wikieditor-toolbar-tool-heading-2": "Nivelo 2",
"wikieditor-toolbar-tool-heading-3": "Nivelo 3",
@@ -55,6 +52,10 @@
"wikieditor-toolbar-help-page-list": "Listi",
"wikieditor-toolbar-help-page-file": "Arkivi",
"wikieditor-toolbar-help-content-ilink-description": "Interna ligilo",
+ "wikieditor-toolbar-help-content-ilink-syntax": "[[Titulo di la pagino]]<br />[[Titulo di la pagino|Etiketo dil ligilo]]",
+ "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Titulo di la pagino</a><br /><a href='#'>Etiketo dil ligilo</a>",
"wikieditor-toolbar-help-content-xlink-description": "Extera ligilo",
+ "wikieditor-toolbar-help-content-xlink-syntax": "[http://www.example.org Etiketo dil ligilo]<br />[http://www.example.org]<br />http://www.example.org",
+ "wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>Etiketo dil ligilo</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.example.org</a>",
"wikieditor-toolbar-help-content-signature-description": "Signaturo"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/is.json b/www/wiki/extensions/WikiEditor/i18n/is.json
index 7a203a08..f4bb6bc8 100644
--- a/www/wiki/extensions/WikiEditor/i18n/is.json
+++ b/www/wiki/extensions/WikiEditor/i18n/is.json
@@ -4,27 +4,14 @@
"Krun",
"Maxí",
"Snævar",
- "Macofe"
+ "Macofe",
+ "Sveinn í Felli"
]
},
"wikieditor-wikitext-tab": "Wiki-texti",
"wikieditor-loading": "Hleður...",
- "wikieditor-preview-preference": "Virkja forskoðun á samanburði síðna",
- "wikieditor-preview-tab": "Forskoða",
- "wikieditor-preview-changes-tab": "Breytingar",
- "wikieditor-preview-loading": "Hleð...",
- "wikieditor-publish-preference": "Virkja skref-eftir-skref útgáfu",
- "wikieditor-publish-button-publish": "Útgefa",
- "wikieditor-publish-button-cancel": "Hætta við",
- "wikieditor-publish-dialog-title": "Útgefa á {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Breytingarágrip (lýstu stuttlega þeim breytingum sem þú hefur gert):",
- "wikieditor-publish-dialog-minor": "Minniháttar breyting",
- "wikieditor-publish-dialog-watch": "Vakta þessa síðu",
- "wikieditor-publish-dialog-publish": "Útgefa",
- "wikieditor-publish-dialog-goback": "Fara til baka",
"wikieditor-toolbar": "Breytingarstika",
"wikieditor-toolbar-desc": "Breytingarstika með auknu notagildi",
- "wikieditor-toolbar-dialogs-preference": "Virkja valmyndir fyrir innsetningu tengla, taflna og aðgerðna að skipta út texta.",
"wikieditor-toolbar-loading": "Hleð...",
"wikieditor-toolbar-tool-bold": "Feitletrað",
"wikieditor-toolbar-tool-bold-example": "Feitletraður texti",
@@ -69,6 +56,7 @@
"wikieditor-toolbar-file-format-none": "ekkert",
"wikieditor-toolbar-tool-file-insert": "Setja inn",
"wikieditor-toolbar-tool-file-cancel": "Hætta við",
+ "wikieditor-toolbar-tool-file-upload": "Senda",
"wikieditor-toolbar-tool-reference": "Tilvísanir",
"wikieditor-toolbar-tool-reference-example": "Settu tilvísunina hér",
"wikieditor-toolbar-tool-reference-cancel": "Hætta við",
@@ -187,6 +175,7 @@
"wikieditor-toolbar-help-content-reference-description": "Tilvísun",
"wikieditor-toolbar-help-content-reference-syntax": "Texti síðu.&lt;ref&gt;[http://www.example.org Titill síðu], Skoðað 1. janúar 2010.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "Texti síðu.<sup><a href='#'>[1]</a></sup>",
+ "wikieditor-toolbar-help-content-named-reference-result": "Texti síðu.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "Áframhaldandi notkun á sömu tilvísun",
"wikieditor-toolbar-help-content-rereference-result": "Texti síðu.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "Sýna tilvísanir",
diff --git a/www/wiki/extensions/WikiEditor/i18n/it.json b/www/wiki/extensions/WikiEditor/i18n/it.json
index 7d40e468..ae8c81df 100644
--- a/www/wiki/extensions/WikiEditor/i18n/it.json
+++ b/www/wiki/extensions/WikiEditor/i18n/it.json
@@ -19,26 +19,12 @@
]
},
"wikieditor": "Interfaccia avanzata di modifica del wikitesto",
- "wikieditor-desc": "Fornisce un'interfaccia di modifica del wikitesto estensibile e molti moduli che forniscono altre funzionalità",
+ "wikieditor-desc": "Fornisce un'interfaccia di modifica avanzata del wikitesto estensibile",
"wikieditor-wikitext-tab": "Wikitesto",
"wikieditor-loading": "Caricamento",
- "wikieditor-preview-preference": "Abilita anteprima laterale",
- "wikieditor-preview-tab": "Anteprima",
- "wikieditor-preview-changes-tab": "Modifiche",
- "wikieditor-preview-loading": "Caricamento in corso...",
- "wikieditor-publish-preference": "Abilita pubblicazione passo dopo passo",
- "wikieditor-publish-button-publish": "Pubblica",
- "wikieditor-publish-button-cancel": "Annulla",
- "wikieditor-publish-dialog-title": "Pubblica su {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Oggetto (descrivi brevemente le modifiche che hai fatto):",
- "wikieditor-publish-dialog-minor": "Modifica di minore importanza",
- "wikieditor-publish-dialog-watch": "Osserva questa pagina",
- "wikieditor-publish-dialog-publish": "Pubblica",
- "wikieditor-publish-dialog-goback": "Indietro",
"wikieditor-toolbar": "Barra degli strumenti di modifica",
"wikieditor-toolbar-desc": "Barra degli strumenti di modifica della pagina con migliorata usabilità",
"wikieditor-toolbar-preference": "Abilita la barra degli strumenti di modifica avanzata",
- "wikieditor-toolbar-dialogs-preference": "Abilita le finestre per l'inserimento di collegamenti, tabelle e la funzione di cerca e sostituisci",
"wikieditor-toolbar-loading": "Caricamento in corso...",
"wikieditor-toolbar-tool-bold": "Grassetto",
"wikieditor-toolbar-tool-bold-example": "Testo in grassetto",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ja.json b/www/wiki/extensions/WikiEditor/i18n/ja.json
index 332517ba..25352563 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ja.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ja.json
@@ -21,23 +21,9 @@
"wikieditor-desc": "拡張可能なウィキテキスト編集インターフェイスと多数の機能モジュールを提供する",
"wikieditor-wikitext-tab": "ウィキテキスト",
"wikieditor-loading": "読み込み中...",
- "wikieditor-preview-preference": "比較プレビューを有効にする",
- "wikieditor-preview-tab": "プレビュー",
- "wikieditor-preview-changes-tab": "差分",
- "wikieditor-preview-loading": "読み込み中...",
- "wikieditor-publish-preference": "段階的投稿を有効にする",
- "wikieditor-publish-button-publish": "投稿",
- "wikieditor-publish-button-cancel": "中止",
- "wikieditor-publish-dialog-title": "{{SITENAME}} への投稿",
- "wikieditor-publish-dialog-summary": "編集内容の要約 (あなたが行なった変更を簡潔に説明してください):",
- "wikieditor-publish-dialog-minor": "細部の編集",
- "wikieditor-publish-dialog-watch": "このページをウォッチ",
- "wikieditor-publish-dialog-publish": "投稿",
- "wikieditor-publish-dialog-goback": "戻る",
"wikieditor-toolbar": "編集ツールバー",
"wikieditor-toolbar-desc": "使いやすさの向上したページ編集ツールバー",
"wikieditor-toolbar-preference": "改良型編集ツールバーを有効にする",
- "wikieditor-toolbar-dialogs-preference": "リンクや表の挿入、および検索と置換のためのウィザードを有効にする",
"wikieditor-toolbar-loading": "読み込み中...",
"wikieditor-toolbar-tool-bold": "太字",
"wikieditor-toolbar-tool-bold-example": "太字文",
diff --git a/www/wiki/extensions/WikiEditor/i18n/jv.json b/www/wiki/extensions/WikiEditor/i18n/jv.json
index 1b30d479..94844144 100644
--- a/www/wiki/extensions/WikiEditor/i18n/jv.json
+++ b/www/wiki/extensions/WikiEditor/i18n/jv.json
@@ -10,19 +10,6 @@
"wikieditor-desc": "Nyepakaké antarmuka besut tèks wiki sing bisa diambani lan modhul-modhul mawa fitur",
"wikieditor-wikitext-tab": "Tèks wiki",
"wikieditor-loading": "Ngamot...",
- "wikieditor-preview-preference": "Urubaké pratuduh jèjèran",
- "wikieditor-preview-tab": "Pratuduh",
- "wikieditor-preview-changes-tab": "Owahan",
- "wikieditor-preview-loading": "Ngamot...",
- "wikieditor-publish-preference": "Urubaké pangecap jangkah baka jangkah",
- "wikieditor-publish-button-publish": "Babar",
- "wikieditor-publish-button-cancel": "Wurung",
- "wikieditor-publish-dialog-title": "Babar menyang {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Besut ringkesan (wedharaké kanthi ringkes owahan apa waé sing wis panjenengan gawé):",
- "wikieditor-publish-dialog-minor": "Besutan cilik",
- "wikieditor-publish-dialog-watch": "Awasi kaca iki",
- "wikieditor-publish-dialog-publish": "Babar",
- "wikieditor-publish-dialog-goback": "Balik",
"wikieditor-toolbar": "Wilah piranti besut",
"wikieditor-toolbar-desc": "Besut wilah piranti kaca mawa kagunan linuwih",
"wikieditor-toolbar-preference": "Urubaké wilah piranti besut sing linuwih",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ka.json b/www/wiki/extensions/WikiEditor/i18n/ka.json
index 15ba96ca..d1f04ee6 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ka.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ka.json
@@ -13,23 +13,9 @@
"wikieditor-desc": "ვიკიტექსტის რედაქტირების გაფართოებული ინტერფეისისა და სხვა ფუნქციებს უზრუნველყოფს",
"wikieditor-wikitext-tab": "ვიკიტექსტი",
"wikieditor-loading": "იტვირთება",
- "wikieditor-preview-preference": "ჩართეთ გვერდითი გადახედვა",
- "wikieditor-preview-tab": "წინასწარ",
- "wikieditor-preview-changes-tab": "ცვლილებები",
- "wikieditor-preview-loading": "იტვირთება...",
- "wikieditor-publish-preference": "ჩართეთ ნაბიჯ-ნაბიჯი პუბლიკაცია",
- "wikieditor-publish-button-publish": "გამოქვეყნება",
- "wikieditor-publish-button-cancel": "გაუქმება",
- "wikieditor-publish-dialog-title": "გამოქვეყნება {{SITENAME}}-ში.",
- "wikieditor-publish-dialog-summary": "ცვლილების მოკლე აღწერა (წერილობით აღწერეთ, თუ რა ცვლილება შეიტანეთ):",
- "wikieditor-publish-dialog-minor": "მცირე შესწორება",
- "wikieditor-publish-dialog-watch": "ამ გვერდის თვალთვალი",
- "wikieditor-publish-dialog-publish": "გამოქვეყნება",
- "wikieditor-publish-dialog-goback": "უკან",
"wikieditor-toolbar": "რედაქტირების პანელი",
"wikieditor-toolbar-desc": "რედაქტირების პანელი გაუმჯობესებული იუზაბილითით",
"wikieditor-toolbar-preference": "ჩართეთ რედაქტირების გაუმჯობესებული პანელი",
- "wikieditor-toolbar-dialogs-preference": "ბმულების, ცხრილებისა და სხვა ობიექტების ჩასასმელად ჩართეთ დიალოგები",
"wikieditor-toolbar-loading": "იტვირთება…",
"wikieditor-toolbar-tool-bold": "მუქი",
"wikieditor-toolbar-tool-bold-example": "მუქი ტექსტი",
diff --git a/www/wiki/extensions/WikiEditor/i18n/kiu.json b/www/wiki/extensions/WikiEditor/i18n/kiu.json
index 2b000340..1ab2e77e 100644
--- a/www/wiki/extensions/WikiEditor/i18n/kiu.json
+++ b/www/wiki/extensions/WikiEditor/i18n/kiu.json
@@ -5,7 +5,6 @@
"Kumkumuk"
]
},
- "wikieditor-publish-button-cancel": "Bıtexelne",
"wikieditor-toolbar-tool-link": "Girê",
"wikieditor-toolbar-tool-link-cancel": "Bıtexelne",
"wikieditor-toolbar-tool-file-cancel": "Bıtexelne",
diff --git a/www/wiki/extensions/WikiEditor/i18n/kk-cyrl.json b/www/wiki/extensions/WikiEditor/i18n/kk-cyrl.json
index 847382fa..82d2558b 100644
--- a/www/wiki/extensions/WikiEditor/i18n/kk-cyrl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/kk-cyrl.json
@@ -9,22 +9,9 @@
"wikieditor": "Уикимәтінді өңдеудің кеңейтілген интерфейсі",
"wikieditor-wikitext-tab": "Уикимәтін",
"wikieditor-loading": "Күте тұр...",
- "wikieditor-preview-tab": "Қарап шығу",
- "wikieditor-preview-changes-tab": "Өзгерістер",
- "wikieditor-preview-loading": "Күте тұр...",
- "wikieditor-publish-preference": "Саты-сатысымен жариялауды қосу",
- "wikieditor-publish-button-publish": "Жариялау",
- "wikieditor-publish-button-cancel": "Болдырмау",
- "wikieditor-publish-dialog-title": "{{SITENAME}} сайтына жариялау",
- "wikieditor-publish-dialog-summary": "Өңдеме түйіндемесі (жасаған өзгерістеріңізді қысқаша сипаттаңыз)",
- "wikieditor-publish-dialog-minor": "Шағын өңдеме",
- "wikieditor-publish-dialog-watch": "Бұл бетті бақылау",
- "wikieditor-publish-dialog-publish": "Жариялау",
- "wikieditor-publish-dialog-goback": "Артқа",
"wikieditor-toolbar": "Өңдеу жақтауы",
"wikieditor-toolbar-desc": "Қолдануға ыңғайлы өңдеу құралдары үстелі",
"wikieditor-toolbar-preference": "Кеңейтілген өңдеу құралдары үстелін қосу",
- "wikieditor-toolbar-dialogs-preference": "Сілтемелер кірістіру, кестелер сонымен бірге іздеу және алмастыру функциялары үшін шеберді қосу",
"wikieditor-toolbar-loading": "Жүктеуде…",
"wikieditor-toolbar-tool-bold": "Жуан жазу",
"wikieditor-toolbar-tool-bold-example": "Жуан мәтін",
diff --git a/www/wiki/extensions/WikiEditor/i18n/km.json b/www/wiki/extensions/WikiEditor/i18n/km.json
index 0b634e2b..85ee685a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/km.json
+++ b/www/wiki/extensions/WikiEditor/i18n/km.json
@@ -8,22 +8,9 @@
"wikieditor": "អន្តរមុខសំរាប់កែប្រែអត្ថបទវិគីថ្នាក់ខ្ពស់",
"wikieditor-wikitext-tab": "អត្ថបទវិគី",
"wikieditor-loading": "កំពុងផ្ទុក",
- "wikieditor-preview-preference": "ប្រើការមើលមុខផ្ទឹមគ្នា",
- "wikieditor-preview-tab": "ការមើលមុន",
- "wikieditor-preview-changes-tab": "បំលាស់ប្ដូរ",
- "wikieditor-preview-loading": "កំពុងផ្ទុក…",
- "wikieditor-publish-preference": "ប្រើការផ្សព្វផ្យាយជាដំណាក់ៗ",
- "wikieditor-publish-button-publish": "បោះផ្សាយ",
- "wikieditor-publish-button-cancel": "បោះបង់",
- "wikieditor-publish-dialog-title": "បោះផ្សាយក្នុង{{SITENAME}}",
- "wikieditor-publish-dialog-summary": "ចំណារពន្យល់ (រៀបរាប់ដោយសង្ខេបពីកំណែប្រែដែលអ្នកបានធ្វើឡើង)៖",
- "wikieditor-publish-dialog-minor": "កំណែប្រែតិចតួច",
- "wikieditor-publish-dialog-watch": "តាមដាន​ទំព័រនេះ",
- "wikieditor-publish-dialog-publish": "បោះផ្សាយ",
- "wikieditor-publish-dialog-goback": "ត្រឡប់​ក្រោយ",
"wikieditor-toolbar": "របារឧបករណ៍កែប្រែ",
+ "wikieditor-toolbar-desc": "របារឧបរកណ៍កែប្រែទំព័រដែលកាន់តែស្រួលប្រើ",
"wikieditor-toolbar-preference": "ប្រើរបារឧបករណ៍កែប្រែទំនើប",
- "wikieditor-toolbar-dialogs-preference": "ប្រើផ្ទាំងពិសេសសំរាប់បញ្ចូលតំណភ្ជាប់ តារាង ជាដើម",
"wikieditor-toolbar-loading": "កំពុងផ្ទុក…",
"wikieditor-toolbar-tool-bold": "អក្សរដិត",
"wikieditor-toolbar-tool-bold-example": "អត្ថបទជាអក្សរដិត",
@@ -49,7 +36,8 @@
"wikieditor-toolbar-tool-link-int-target-status-notexists": "ទំព័រមិនទាន់មាន",
"wikieditor-toolbar-tool-link-int-target-status-invalid": "ចំណងជើងមិនត្រឹមត្រូវ",
"wikieditor-toolbar-tool-link-int-target-status-external": "តំណភ្ជាប់​ខាងក្រៅ",
- "wikieditor-toolbar-tool-link-int-target-status-loading": "កំពុងពិនិត្យថាតើទំព័រមានហើយឫនៅ...",
+ "wikieditor-toolbar-tool-link-int-target-status-loading": "កំពុងពិនិត្យថាតើទំព័រមានហើយឬនៅ...",
+ "wikieditor-toolbar-tool-link-int-target-status-disambig": "ទំព័រអសង្ស័យកម្ម",
"wikieditor-toolbar-tool-link-int-invalid": "ចំណងជើងដែលអ្នកបានផ្ដល់អោយមិនត្រឹមត្រូវទេ",
"wikieditor-toolbar-tool-link-lookslikeinternal": "URLដែលអ្នកបានផ្ដល់អោយ ទំនងជាតំណភ្ជាប់ទៅកាន់ទំព័រមួយទៀតក្នុងវិគី។\n\nតើអ្នកចង់ប្ដូរវាជាតំណភ្ជាប់ខាងក្នុងវិញទេ?",
"wikieditor-toolbar-tool-link-lookslikeinternal-int": "តំណភ្ជាប់​ខាងក្នុង",
@@ -57,6 +45,17 @@
"wikieditor-toolbar-tool-link-empty": "អ្នកមិនបានវាយបញ្ចូលពាក្យសំរាប់ដាក់តំណភ្ជាប់ទេ។",
"wikieditor-toolbar-tool-file": "រូបភាពបង្កប់",
"wikieditor-toolbar-tool-file-example": "ឧទាហរណ៍.jpg",
+ "wikieditor-toolbar-tool-file-title": "បញ្ចូលឯកសារ",
+ "wikieditor-toolbar-file-target": "ឈ្មោះឯកសារ​៖",
+ "wikieditor-toolbar-file-caption": "កូនចំណងជើង៖",
+ "wikieditor-toolbar-file-size": "ទំហំ​៖",
+ "wikieditor-toolbar-file-float": "តម្រៀប៖",
+ "wikieditor-toolbar-file-default": "(លំនាំដើម)",
+ "wikieditor-toolbar-file-format": "ទម្រង់:",
+ "wikieditor-toolbar-file-format-none": "គ្មាន",
+ "wikieditor-toolbar-tool-file-insert": "បញ្ចូល",
+ "wikieditor-toolbar-tool-file-cancel": "បោះបង់",
+ "wikieditor-toolbar-tool-file-upload": "ផ្ទុកឡើង​",
"wikieditor-toolbar-tool-reference": "ឯកសារយោង",
"wikieditor-toolbar-tool-reference-example": "បញ្ចូលអត្ថបទយោងនៅទីនេះ",
"wikieditor-toolbar-tool-reference-cancel": "បោះបង់",
@@ -107,18 +106,20 @@
"wikieditor-toolbar-tool-table-preview": "មើលជាមុន",
"wikieditor-toolbar-tool-table-insert": "បញ្ចូល",
"wikieditor-toolbar-tool-table-cancel": "បោះបង់​",
+ "wikieditor-toolbar-tool-table-toomany": "ផ្ទាំងនេះមិនអាចបញ្ចូលតារាងមួយដែលមានច្រើនជា $1 {{PLURAL:$1|ប្រអប់}}ទេ។",
"wikieditor-toolbar-tool-table-invalidnumber": "អ្នកមិនបានបញ្ចូលចំនួនជួរដេកនិងជួរឈរបានត្រឹមត្រូវទេ។",
"wikieditor-toolbar-tool-table-zero": "អ្នកមិនអាចបញ្ចូលតារាងដែលមានជួរដេកឬជួរឈរចំនួនសូន្យបានទេ។",
"wikieditor-toolbar-tool-replace": "ស្វែងរកនិងជំនួស",
"wikieditor-toolbar-tool-replace-title": "ស្វែងរកនិងជំនួស",
"wikieditor-toolbar-tool-replace-search": "ស្វែងរក៖",
"wikieditor-toolbar-tool-replace-replace": "ជំនួសដោយ៖",
+ "wikieditor-toolbar-tool-replace-case": "គិតអក្សរធំអក្សរតូច",
"wikieditor-toolbar-tool-replace-button-findnext": "រុករក​បន្ទាប់​",
"wikieditor-toolbar-tool-replace-button-replace": "ជំនួស",
"wikieditor-toolbar-tool-replace-button-replaceall": "ជំនួសទាំងអស់",
"wikieditor-toolbar-tool-replace-close": "បិទ",
"wikieditor-toolbar-tool-replace-nomatch": "រកមិនឃើញអ្វីដែលអ្នកចង់រកទេ។",
- "wikieditor-toolbar-tool-replace-success": "បានធ្វើការជំនួសចំនួន $1។",
+ "wikieditor-toolbar-tool-replace-success": "បានធ្វើ{{PLURAL:$1|ការជំនួស|ការជំនួស}}ចំនួន $1។",
"wikieditor-toolbar-tool-replace-emptysearch": "អ្នកមិនបានវាយបញ្ចូលពាក្យសំរាប់ស្វែងរកទេ។",
"wikieditor-toolbar-section-characters": "តួអក្សរពិសេសៗ",
"wikieditor-toolbar-section-help": "ជំនួយ",
@@ -142,23 +143,23 @@
"wikieditor-toolbar-help-content-bolditalic-syntax": "'''''អត្ថបទជាអក្សរដិត &amp; ទ្រេត'''''",
"wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>អត្ថបទជាអក្សរដិត &amp; ទ្រេត</em></strong>",
"wikieditor-toolbar-help-content-ilink-description": "តំណភ្ជាប់​ខាងក្នុង",
- "wikieditor-toolbar-help-content-ilink-syntax": "[[ចំនងជើងទំព័រ|ប្លាកសំគាល់តំនភ្ជាប់]]<br />[[ចំនងជើងទំព័រ]]",
- "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>ប្លាកសំគាល់តំនភ្ជាប់</a><br /><a href='#'>ចំនងជើងទំព័រ</a>",
+ "wikieditor-toolbar-help-content-ilink-syntax": "[[ចំណងជើងទំព័រ]]<br />[[ចំណងជើងទំព័រ|ប្លាកសម្គាល់តំណភ្ជាប់]]",
+ "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>ចំណងជើងទំព័រ</a><br /><a href='#'>ប្លាកសម្គាល់តំណភ្ជាប់</a>",
"wikieditor-toolbar-help-content-xlink-description": "តំណភ្ជាប់​ខាងក្រៅ",
"wikieditor-toolbar-help-content-xlink-syntax": "[http://www.ឧទាហរណ៍.org ប្លាកសំគាល់តំនភ្ជាប់]<br />[http://www.ឧទាហរណ៍.org]<br />http://www.ឧទាហរណ៍.org",
"wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>ប្លាកសំគាល់តំនភ្ជាប់</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.ឧទាហរណ៍.org</a>",
- "wikieditor-toolbar-help-content-heading2-description": "កូនចំនងជើងកំរិត២",
- "wikieditor-toolbar-help-content-heading2-syntax": "== កូនចំនងជើង ==",
- "wikieditor-toolbar-help-content-heading2-result": "<h2>កូនចំនងជើង</h2>",
- "wikieditor-toolbar-help-content-heading3-description": "កូនចំនងជើងកំរិត៣",
- "wikieditor-toolbar-help-content-heading3-syntax": "=== កូនចំនងជើង ===",
- "wikieditor-toolbar-help-content-heading3-result": "<h3>កូនចំនងជើង</h3>",
- "wikieditor-toolbar-help-content-heading4-description": "កូនចំនងជើងកំរិត៤",
- "wikieditor-toolbar-help-content-heading4-syntax": "==== កូនចំនងជើង ====",
- "wikieditor-toolbar-help-content-heading4-result": "<h4>កូនចំនងជើង</h4>",
- "wikieditor-toolbar-help-content-heading5-description": "កូនចំនងជើងកំរិត៥",
- "wikieditor-toolbar-help-content-heading5-syntax": "===== កូនចំនងជើង =====",
- "wikieditor-toolbar-help-content-heading5-result": "<h5>កូនចំនងជើង</h5>",
+ "wikieditor-toolbar-help-content-heading2-description": "កូនចំណងជើងកំរិត២",
+ "wikieditor-toolbar-help-content-heading2-syntax": "== កូនចំណងជើង ==",
+ "wikieditor-toolbar-help-content-heading2-result": "<h2>កូនចំណងជើង</h2>",
+ "wikieditor-toolbar-help-content-heading3-description": "កូនចំណងជើងកំរិត៣",
+ "wikieditor-toolbar-help-content-heading3-syntax": "=== កូនចំណងជើង ===",
+ "wikieditor-toolbar-help-content-heading3-result": "<h3>កូនចំណងជើង</h3>",
+ "wikieditor-toolbar-help-content-heading4-description": "កូនចំណងជើងកំរិត៤",
+ "wikieditor-toolbar-help-content-heading4-syntax": "==== កូនចំណងជើង ====",
+ "wikieditor-toolbar-help-content-heading4-result": "<h4>កូនចំណងជើង</h4>",
+ "wikieditor-toolbar-help-content-heading5-description": "កូនចំណងជើងកំរិត៥",
+ "wikieditor-toolbar-help-content-heading5-syntax": "===== កូនចំណងជើង =====",
+ "wikieditor-toolbar-help-content-heading5-result": "<h5>កូនចំណងជើង</h5>",
"wikieditor-toolbar-help-content-ulist-description": "បញ្ជីផ្ដើមដោយត្រេ",
"wikieditor-toolbar-help-content-ulist-syntax": "* ធាតុរបស់បញ្ជី<br />* ធាតុរបស់បញ្ជី",
"wikieditor-toolbar-help-content-ulist-result": "<ul><li>ធាតុរបស់បញ្ជី</li><li>ធាតុរបស់បញ្ជី</li></ul>",
@@ -167,6 +168,7 @@
"wikieditor-toolbar-help-content-olist-result": "<ol><li>ធាតុរបស់បញ្ជី</li><li>ធាតុរបស់បញ្ជី</li></ol>",
"wikieditor-toolbar-help-content-file-description": "រូបភាពបង្កប់",
"wikieditor-toolbar-help-content-file-syntax": "[[$1:ឧទាហរណ៍.png|$2|$3]]",
+ "wikieditor-toolbar-help-content-file-caption": "អត្ថបទកូនចំណងជើង",
"wikieditor-toolbar-help-content-reference-description": "ឯកសារ​យោង​",
"wikieditor-toolbar-help-content-reference-syntax": "អត្ថបទ​ទំព័រ​.&lt;ref&gt;[http://www.example.org តំណ​ភ្ជាប់], អក្សរ​បន្ថែម​.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "អត្ថបទ​ទំព័រ​.<sup><a href='#'>[1]</a></sup>",
@@ -178,7 +180,7 @@
"wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>អត្តនាម</a> (<a href='#' title='$2:Username'>ការពិភាក្សា</a>) ១៥:៥៤, ១០ មិថុនា ២០០៩ (UTC)",
"wikieditor-toolbar-help-content-signature-description": "ហត្ថលេខា​",
"wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>អត្តនាម</a> (<a href='#' title='$2:Username'>ការពិភាក្សា</a>)",
- "wikieditor-toolbar-help-content-indent-description": "ខិតចូល (Indent)",
- "wikieditor-toolbar-help-content-indent-syntax": "អក្សរ​ធម្មតា​<br />:អក្សរ​ខិតចូល​<br />::អក្សរ​ខិតចូល​",
- "wikieditor-toolbar-help-content-indent-result": "អក្សរ​ធម្មតា​​<dl><dd>អក្សរ​ខិតចូល​<dl><dd>អក្សរ​ខិតចូល​</dd></dl></dd></dl>"
+ "wikieditor-toolbar-help-content-indent-description": "ចូលបន្ទាត់",
+ "wikieditor-toolbar-help-content-indent-syntax": "អក្សរ​ធម្មតា​<br />:អក្សរ​ចូលបន្ទាត់​<br />::អក្សរ​ចូលបន្ទាត់",
+ "wikieditor-toolbar-help-content-indent-result": "អក្សរ​ធម្មតា​​<dl><dd>អក្សរ​ចូលបន្ទាត់<dl><dd>អក្សរ​ចូលបន្ទាត់​</dd></dl></dd></dl>"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/kn.json b/www/wiki/extensions/WikiEditor/i18n/kn.json
index ab5252e6..481e51a5 100644
--- a/www/wiki/extensions/WikiEditor/i18n/kn.json
+++ b/www/wiki/extensions/WikiEditor/i18n/kn.json
@@ -9,18 +9,6 @@
"wikieditor": "ಮುಂದುವರಿದ ವಿಕಿಪಠ್ಯ ಸಂಪಾದನೆಯ ಅಂತರ್‍ಸಂಪರ್ಕ",
"wikieditor-wikitext-tab": "ವಿಕಿಪಠ್ಯ",
"wikieditor-loading": "ತುಂಬಿಸಲಾಗುತ್ತಿದೆ....",
- "wikieditor-preview-preference": "ಅಕ್ಕ ಪಕ್ಕ ಮುನ್ನೋಟ ಸಾಧ್ಯವಾಗಿಸು",
- "wikieditor-preview-tab": "ಮುನ್ನೋಟ",
- "wikieditor-preview-changes-tab": "ಬದಲಾವಣೆಗಳು",
- "wikieditor-preview-loading": "ತುಂಬಿಸಲಾಗುತ್ತಿದೆ....",
- "wikieditor-publish-preference": "ಅನುಕ್ರಮವಾಗಿ ಪ್ರಕಟಪಡುಸುವಿಕೆಯನ್ನು ಸಾಧ್ಯವಾಗಿಸು",
- "wikieditor-publish-button-publish": "ಪ್ರಕಟಪಡಿಸು",
- "wikieditor-publish-button-cancel": "ರದ್ದುಪಡಿಸು",
- "wikieditor-publish-dialog-title": "{{SITENAME}}ಗೆ ಪ್ರಕಟಪಡಿಸು",
- "wikieditor-publish-dialog-minor": "ಚಿಕ್ಕ ಸಂಪಾದನೆ",
- "wikieditor-publish-dialog-watch": "ಈ ಪುಟವನ್ನು ವೀಕ್ಷಿಸಿ",
- "wikieditor-publish-dialog-publish": "ಪ್ರಕಟಪಡಿಸು",
- "wikieditor-publish-dialog-goback": "ಹಿಂದೆ ಹೋಗಿ",
"wikieditor-toolbar": "ಸಂಪಾದನೆ ಪರಿಕರಪಟ್ಟಿ",
"wikieditor-toolbar-desc": "ವರ್ಧಿತ ಬಳಕೆಸ್ನೇಹಿ ಸಂಪಾದನೆ ಪರಿಕರಪಟ್ಟಿ",
"wikieditor-toolbar-preference": "ವರ್ಧಿತ ಸಂಪಾದನೆ ಪರಿಕರಪಟ್ಟಿಯನ್ನು ಸಶಕ್ತಗೊಳಿಸು",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ko.json b/www/wiki/extensions/WikiEditor/i18n/ko.json
index c085ae1a..a6e081e3 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ko.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ko.json
@@ -12,26 +12,14 @@
"아라",
"Macofe",
"Hwangjy9",
- "Ykhwong"
+ "Ykhwong",
+ "Garam"
]
},
"wikieditor": "확장된 위키텍스트 편집 인터페이스",
- "wikieditor-desc": "확장된 위키 문법 편집 인터페이스와 다양한 기능을 제공하는 모듈을 제공합니다",
+ "wikieditor-desc": "확장 가능한 고급 위키텍스트 편집 인터페이스를 제공합니다",
"wikieditor-wikitext-tab": "위키텍스트",
"wikieditor-loading": "불러오는 중...",
- "wikieditor-preview-preference": "미리 보기 비교 활성화",
- "wikieditor-preview-tab": "미리 보기",
- "wikieditor-preview-changes-tab": "차이",
- "wikieditor-preview-loading": "불러오는 중...",
- "wikieditor-publish-preference": "한 단계씩 게시 활성화",
- "wikieditor-publish-button-publish": "게시",
- "wikieditor-publish-button-cancel": "취소",
- "wikieditor-publish-dialog-title": "{{SITENAME}}에 게시",
- "wikieditor-publish-dialog-summary": "편집 요약 (바꾼 내용을 간략하게 설명하세요):",
- "wikieditor-publish-dialog-minor": "사소한 편집",
- "wikieditor-publish-dialog-watch": "이 문서 주시하기",
- "wikieditor-publish-dialog-publish": "게시",
- "wikieditor-publish-dialog-goback": "돌아가기",
"wikieditor-toolbar": "편집 도구 모음",
"wikieditor-toolbar-desc": "사용성이 향상된 문서 편집 도구 모음",
"wikieditor-toolbar-preference": "향상된 편집 도구 모음 활성화하기",
@@ -118,13 +106,13 @@
"wikieditor-toolbar-tool-newline": "새 줄",
"wikieditor-toolbar-tool-table": "표",
"wikieditor-toolbar-tool-table-example-old": "-\n! 제목 1\n! 제목 2\n! 제목 3\n|-\n| 1행 1열\n| 1행 2열\n| 1행 3열\n|-\n| 2행 1열\n| 2행 2열\n| 2행 3열",
- "wikieditor-toolbar-tool-table-example-cell-text": "셀 내용",
+ "wikieditor-toolbar-tool-table-example-cell-text": "칸 내용",
"wikieditor-toolbar-tool-table-example-header": "표 제목",
"wikieditor-toolbar-tool-table-title": "표 넣기",
"wikieditor-toolbar-tool-table-dimensions-rows": "행",
"wikieditor-toolbar-tool-table-dimensions-columns": "열",
"wikieditor-toolbar-tool-table-dimensions-header": "표 제목란을 포함시키기",
- "wikieditor-toolbar-tool-table-wikitable": "셀 경계선이 있는 스타일",
+ "wikieditor-toolbar-tool-table-wikitable": "칸 경계선이 있는 형태",
"wikieditor-toolbar-tool-table-sortable": "표를 정렬할 수 있게 만들기",
"wikieditor-toolbar-tool-table-example": "예시",
"wikieditor-toolbar-tool-table-preview": "미리 보기",
diff --git a/www/wiki/extensions/WikiEditor/i18n/krc.json b/www/wiki/extensions/WikiEditor/i18n/krc.json
index e729210e..f35856e9 100644
--- a/www/wiki/extensions/WikiEditor/i18n/krc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/krc.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Викитекст редакторлауну кенгертилген интерфейсин эмда модулла берген кёб башха функцияны джетиштиреди.",
"wikieditor-wikitext-tab": "Викитекст",
"wikieditor-loading": "Джюклеу",
- "wikieditor-preview-preference": "Бир бири къатында ал къарауну джандыр",
- "wikieditor-preview-tab": "Ал къарау",
- "wikieditor-preview-changes-tab": "Тюрлениуле",
- "wikieditor-preview-loading": "Джюклениу...",
- "wikieditor-publish-preference": "Атлам-атлам чыгъарыуну джандыр",
- "wikieditor-publish-button-publish": "Чыгъар",
- "wikieditor-publish-button-cancel": "Ызына алыу",
- "wikieditor-publish-dialog-title": "{{SITENAME}} проектде чыгъар",
- "wikieditor-publish-dialog-summary": "Тюрлениулени ачыкълау (къаллай тюрлениулени этилгенин къысхасы бла белгилегиз):",
- "wikieditor-publish-dialog-minor": "Гитче тюрлендириу",
- "wikieditor-publish-dialog-watch": "Бу бетни сынчыкъла",
- "wikieditor-publish-dialog-publish": "Чыгъар",
- "wikieditor-publish-dialog-goback": "Артха",
"wikieditor-toolbar": "Тюзетиулени панели",
"wikieditor-toolbar-desc": "Хайырланыр мадары игиленнген тюрлендириу панель",
"wikieditor-toolbar-preference": "Игиленнген тюрлендириу панелни джандыр",
- "wikieditor-toolbar-dialogs-preference": "Джибериулени, таблицаланы эмда андан башханы къошар ючюн мастерни джандыр",
"wikieditor-toolbar-loading": "Джюклениу...",
"wikieditor-toolbar-tool-bold": "Къалын",
"wikieditor-toolbar-tool-bold-example": "Къалын джазыу",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ksh.json b/www/wiki/extensions/WikiEditor/i18n/ksh.json
index ef61b576..cea60538 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ksh.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ksh.json
@@ -8,23 +8,9 @@
"wikieditor-desc": "Brängk en Müjjeleschkeit för Wikkitäx ennzejävve un ze ändere en et Wikki, di mer ußboue kann, un di noch allerhand Kröhmsches met dobei hät.",
"wikieditor-wikitext-tab": "Wikkitäx",
"wikieditor-loading": "Ben aam Lahde&nbsp;…",
- "wikieditor-preview-preference": "Donn de {{int:preview}} nevvedraan zohlohße",
- "wikieditor-preview-tab": "{{int:preview}}",
- "wikieditor-preview-changes-tab": "Änderonge",
- "wikieditor-preview-loading": "Ben aam Lahde&nbsp;…",
- "wikieditor-publish-preference": "Et Schrett för Schrett öffentlesch Maache zohlohße",
- "wikieditor-publish-button-publish": "Öffentlesch maache!",
- "wikieditor-publish-button-cancel": "{{int:cancel}}",
- "wikieditor-publish-dialog-title": "En dä {{SITENAME}} öffentlesch maache",
- "wikieditor-publish-dialog-summary": "Koot Zosammejefass (Wat De verändert häs, en koot):",
- "wikieditor-publish-dialog-minor": "{{int:minoredit}}",
- "wikieditor-publish-dialog-watch": "{{int:watchthis}}",
- "wikieditor-publish-dialog-publish": "{{int:wikieditor-publish-button-publish}}",
- "wikieditor-publish-dialog-goback": "Jangk Retuhr!",
"wikieditor-toolbar": "Werkzüsh för et Ändere",
"wikieditor-toolbar-desc": "Verbesserte Werkzüsh för et Ändere",
"wikieditor-toolbar-preference": "Donn et ußföerlesh Werkzüsh för et Ändere aanzeije (bruch Java_Skripp)",
- "wikieditor-toolbar-dialogs-preference": "Donn de Lengks aanzeije för Lengks, Tabälle en Sigge em Wiki ennzeföhje un schalld et Söhke un Ußtuusche en.",
"wikieditor-toolbar-loading": "Ben aam Lahde&nbsp;…",
"wikieditor-toolbar-tool-bold": "Fätte Schreff",
"wikieditor-toolbar-tool-bold-example": "Fätte Schreff",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ku-latn.json b/www/wiki/extensions/WikiEditor/i18n/ku-latn.json
index 73e85c82..b70f2ccf 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ku-latn.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ku-latn.json
@@ -9,15 +9,6 @@
]
},
"wikieditor-loading": "Bar dibe",
- "wikieditor-preview-tab": "Pêşdîtin",
- "wikieditor-preview-changes-tab": "Guhartin",
- "wikieditor-preview-loading": "Bar dibe…",
- "wikieditor-publish-button-publish": "Weşandin",
- "wikieditor-publish-button-cancel": "Betal bike",
- "wikieditor-publish-dialog-minor": "Guhertina biçûk",
- "wikieditor-publish-dialog-watch": "Vê rûpelê bişopîne",
- "wikieditor-publish-dialog-publish": "Weşandin",
- "wikieditor-publish-dialog-goback": "Vegere",
"wikieditor-toolbar-loading": "Bar dibe…",
"wikieditor-toolbar-tool-bold": "Stûr",
"wikieditor-toolbar-tool-bold-example": "Nivîsa stûr",
@@ -72,7 +63,7 @@
"wikieditor-toolbar-tool-table-preview": "Pêşdîtin",
"wikieditor-toolbar-tool-table-insert": "Tevlî bike",
"wikieditor-toolbar-tool-table-cancel": "Betal bike",
- "wikieditor-toolbar-tool-replace-close": "Girtin",
+ "wikieditor-toolbar-tool-replace-close": "Bigre",
"wikieditor-toolbar-section-characters": "Karakterên taybet",
"wikieditor-toolbar-section-help": "Alîkarî",
"wikieditor-toolbar-help-heading-description": "Danasîn",
diff --git a/www/wiki/extensions/WikiEditor/i18n/kw.json b/www/wiki/extensions/WikiEditor/i18n/kw.json
index e9c4dec3..f050b023 100644
--- a/www/wiki/extensions/WikiEditor/i18n/kw.json
+++ b/www/wiki/extensions/WikiEditor/i18n/kw.json
@@ -9,15 +9,6 @@
},
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Ow karga...",
- "wikieditor-preview-tab": "Ragweles",
- "wikieditor-preview-changes-tab": "Chanjyow",
- "wikieditor-preview-loading": "Ow karga...",
- "wikieditor-publish-button-publish": "Dyllo",
- "wikieditor-publish-button-cancel": "Hedhi",
- "wikieditor-publish-dialog-title": "Dyllo war {{SITENAME}}",
- "wikieditor-publish-dialog-minor": "Chanj byhan",
- "wikieditor-publish-dialog-watch": "Golya an folen-ma",
- "wikieditor-publish-dialog-publish": "Dyllo",
"wikieditor-toolbar": "Toulvar chanjya",
"wikieditor-toolbar-desc": "Toulvar folen janjya gans devnydh gwellhes",
"wikieditor-toolbar-preference": "Galosegi an toulvar chanjya gwellhes",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ky.json b/www/wiki/extensions/WikiEditor/i18n/ky.json
index f768ee1d..70d79c61 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ky.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ky.json
@@ -7,10 +7,6 @@
]
},
"wikieditor-loading": "Жүктөлүүдө...",
- "wikieditor-preview-changes-tab": "Өзгөртүүлөр",
- "wikieditor-preview-loading": "Жүктөлүүдө...",
- "wikieditor-publish-button-cancel": "Жокко чыгаруу",
- "wikieditor-publish-dialog-goback": "Артка",
"wikieditor-toolbar-loading": "Жүктөлүүдө...",
"wikieditor-toolbar-tool-bold": "Калың",
"wikieditor-toolbar-tool-bold-example": "Калың текст",
diff --git a/www/wiki/extensions/WikiEditor/i18n/la.json b/www/wiki/extensions/WikiEditor/i18n/la.json
index e3a9e506..54b3cd34 100644
--- a/www/wiki/extensions/WikiEditor/i18n/la.json
+++ b/www/wiki/extensions/WikiEditor/i18n/la.json
@@ -5,12 +5,10 @@
"OrbiliusMagister",
"UV",
"Macofe",
- "Laurentianus"
+ "Laurentianus",
+ "Lesgles"
]
},
- "wikieditor-preview-tab": "Prospectus",
- "wikieditor-preview-changes-tab": "Mutata",
- "wikieditor-preview-loading": "Depromens...",
"wikieditor-toolbar-preference": "Maiorem trabem editoriam offerre",
"wikieditor-toolbar-loading": "Depromens…",
"wikieditor-toolbar-tool-bold": "Litterae pingues",
@@ -51,7 +49,7 @@
"wikieditor-toolbar-tool-newline": "Nova linea",
"wikieditor-toolbar-tool-table": "Tabula",
"wikieditor-toolbar-section-characters": "Characteres speciales",
- "wikieditor-toolbar-section-help": "Adiutatum",
+ "wikieditor-toolbar-section-help": "Auxilium",
"wikieditor-toolbar-help-heading-description": "Descriptio",
"wikieditor-toolbar-help-heading-syntax": "Quod scribis",
"wikieditor-toolbar-help-heading-result": "Quod accipies",
diff --git a/www/wiki/extensions/WikiEditor/i18n/lad.json b/www/wiki/extensions/WikiEditor/i18n/lad.json
index ae808020..edc63c9f 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lad.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lad.json
@@ -4,8 +4,5 @@
"Menachem.Moreira"
]
},
- "wikieditor-wikitext-tab": "Vikiteksto",
- "wikieditor-publish-button-publish": "Publikar",
- "wikieditor-publish-dialog-title": "Publikar a {{SITENAME}}",
- "wikieditor-publish-dialog-publish": "Publikar"
+ "wikieditor-wikitext-tab": "Vikiteksto"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/lb.json b/www/wiki/extensions/WikiEditor/i18n/lb.json
index 7e02f196..88e3b7e0 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lb.json
@@ -6,26 +6,12 @@
]
},
"wikieditor": "Erweiderten Interface fir d'Änner vu Wikitext",
- "wikieditor-desc": "Liwwert en erweiderbaren Interface fir d'Ännere vu Wikitext a vill Module mat Funktiounen",
+ "wikieditor-desc": "Liwwert en erweiderbaren Interface fir d'Ännere vu Wikitext",
"wikieditor-wikitext-tab": "WikiText",
"wikieditor-loading": "Lueden",
- "wikieditor-preview-preference": "side-by-side kucken ouni ze späicheren aschalten",
- "wikieditor-preview-tab": "Kucken ouni ze späicheren",
- "wikieditor-preview-changes-tab": "Ännerungen",
- "wikieditor-preview-loading": "Lueden...",
- "wikieditor-publish-preference": "Schrëtt-fir-Schrëtt Publikatioun aschalten",
- "wikieditor-publish-button-publish": "Verëffentlechen",
- "wikieditor-publish-button-cancel": "Ofbriechen",
- "wikieditor-publish-dialog-title": "Op {{SITENAME}} verëffentlechen",
- "wikieditor-publish-dialog-summary": "Resumé vun der Ännerung (beschreift kuerz d'Ännerungen déi Dir gemaach hutt):",
- "wikieditor-publish-dialog-minor": "Kleng Ännerung",
- "wikieditor-publish-dialog-watch": "Dës Säit iwwerwaachen",
- "wikieditor-publish-dialog-publish": "Verëffentlechen",
- "wikieditor-publish-dialog-goback": "Zréck goen",
"wikieditor-toolbar": "Toolbar änneren",
"wikieditor-toolbar-desc": "Toolbar vun de Säitenännerunge mat erweiderter Benotzerfrëndlechkeet",
"wikieditor-toolbar-preference": "Déi erweidert Ännerungs-Toolbar aktivéieren",
- "wikieditor-toolbar-dialogs-preference": "Assistente fir d'Drasetze vu Linken, Tabelle genee sou wéi d'Funktioun 'sichen an ersetzen' aschalten",
"wikieditor-toolbar-loading": "Lueden...",
"wikieditor-toolbar-tool-bold": "Fettgedréckt",
"wikieditor-toolbar-tool-bold-example": "Fettgedréckten Text",
diff --git a/www/wiki/extensions/WikiEditor/i18n/li.json b/www/wiki/extensions/WikiEditor/i18n/li.json
index 2e231de6..2eff549e 100644
--- a/www/wiki/extensions/WikiEditor/i18n/li.json
+++ b/www/wiki/extensions/WikiEditor/i18n/li.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Voeg 'nen oetbreidbare teksverwerker veur wikiteks toe en modules mit extra meugelikheje",
"wikieditor-wikitext-tab": "Wikiteks",
"wikieditor-loading": "Laje",
- "wikieditor-preview-preference": "Bewirke en betrachte naevenein",
- "wikieditor-preview-tab": "Veurbesjouwing",
- "wikieditor-preview-changes-tab": "Verangeringe",
- "wikieditor-preview-loading": "Laje...",
- "wikieditor-publish-preference": "Zèt oetbringe ein veur ein aan",
- "wikieditor-publish-button-publish": "Bring oet",
- "wikieditor-publish-button-cancel": "Braek aaf",
- "wikieditor-publish-dialog-title": "Bring oet nao {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Bewerkingssamevatting (besjrief kórt de gemaakdje verangeringe):",
- "wikieditor-publish-dialog-minor": "Klein bewèrking",
- "wikieditor-publish-dialog-watch": "Volg dees pazjena",
- "wikieditor-publish-dialog-publish": "Bring oet",
- "wikieditor-publish-dialog-goback": "Trök",
"wikieditor-toolbar": "Bewèrkingswèrkbalk",
"wikieditor-toolbar-desc": "Nuje bewèrkingsbalk",
"wikieditor-toolbar-preference": "Gebroek de nuje bewèrkingsbalk",
- "wikieditor-toolbar-dialogs-preference": "Zèt inveurvensters aan",
"wikieditor-toolbar-loading": "Laje…",
"wikieditor-toolbar-tool-bold": "Vèt",
"wikieditor-toolbar-tool-bold-example": "Vètten teks",
diff --git a/www/wiki/extensions/WikiEditor/i18n/lij.json b/www/wiki/extensions/WikiEditor/i18n/lij.json
index dd048560..9756f0fd 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lij.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lij.json
@@ -4,6 +4,5 @@
"Giromin Cangiaxo"
]
},
- "wikieditor-toolbar-preference": "Abillita a bara di strumenti de modiffica avançâ",
- "wikieditor-toolbar-dialogs-preference": "Abillita i barcoin pe insei di inganci, de tabelle e a fonçion çerca e sostitoisci"
+ "wikieditor-toolbar-preference": "Abillita a bara di strumenti de modiffica avançâ"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/lki.json b/www/wiki/extensions/WikiEditor/i18n/lki.json
index 54101460..a59c01fb 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lki.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lki.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "یک رابط ویرایش پیشرفته ویکی‌متن و چندین پودمان دارای قابلیت فراهم می‌کند",
"wikieditor-wikitext-tab": "ویکی‌متن",
"wikieditor-loading": "...(loading)بارنیائن",
- "wikieditor-preview-preference": "فعال‌سازی پیش‌نمایش کنار یک دیگر",
- "wikieditor-preview-tab": "پیش‌نمایش",
- "wikieditor-preview-changes-tab": "گؤەڕیال(تغییرات)",
- "wikieditor-preview-loading": "...(loading)بارنیائن",
- "wikieditor-publish-preference": "فعال‌سازی انتشار گام‌به‌گام",
- "wikieditor-publish-button-publish": "انتشار",
- "wikieditor-publish-button-cancel": "ئآهووسانن/لغو",
- "wikieditor-publish-dialog-title": "انتشار در {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "خلاصه ویرایش (توضیح مختصر در مورد تغییری که دادید):",
- "wikieditor-publish-dialog-minor": "دۀسکاریۀل جزئی",
- "wikieditor-publish-dialog-watch": "پئ گیری اێ وەلگە",
- "wikieditor-publish-dialog-publish": "انتشار",
- "wikieditor-publish-dialog-goback": "بوو دؤما/ عقب",
"wikieditor-toolbar": "نوار ابزار ویرایش",
"wikieditor-toolbar-desc": "نوار ابزار ویرایش صفحه با استفاده‌پذیری بالاتر",
"wikieditor-toolbar-preference": "فعال کردن نوارابزار ویرایش پیشرفته",
- "wikieditor-toolbar-dialogs-preference": "فعال‌سازی پنجره‌های تعاملی برای وارد کردن پیوندها، جدول‌ها همراه با دستور جستجو و جایگزینی",
"wikieditor-toolbar-loading": "...(loading)بارنیائن",
"wikieditor-toolbar-tool-bold": "پررنگ",
"wikieditor-toolbar-tool-bold-example": "متن پررنگ",
@@ -71,7 +57,7 @@
"wikieditor-toolbar-tool-file-insert": "قرار دائن",
"wikieditor-toolbar-tool-file-cancel": "ئآهووسانن/لغو",
"wikieditor-toolbar-tool-file-upload": "بارگذاری",
- "wikieditor-toolbar-tool-reference": "بن چۀک/مۀنبۀع",
+ "wikieditor-toolbar-tool-reference": "بنچەک(منبع)",
"wikieditor-toolbar-tool-reference-example": "متن زیرنویس را اینجا اضافه کنید",
"wikieditor-toolbar-tool-reference-cancel": "ئآهووسانن/لغو",
"wikieditor-toolbar-tool-reference-title": "افزودن منبع/بِنچةک",
@@ -79,7 +65,7 @@
"wikieditor-toolbar-tool-reference-text": "متن منبع",
"wikieditor-toolbar-tool-signature": "امضا و برچسب زمان",
"wikieditor-toolbar-section-advanced": "پیشرفتۀ",
- "wikieditor-toolbar-tool-heading": "سةر وةڵگة",
+ "wikieditor-toolbar-tool-heading": "عنوان",
"wikieditor-toolbar-tool-heading-1": "سطح ۱",
"wikieditor-toolbar-tool-heading-2": "سطح ۲",
"wikieditor-toolbar-tool-heading-3": "سطح ۳",
@@ -145,7 +131,7 @@
"wikieditor-toolbar-help-heading-result": "آن چه به دست می‌آورید",
"wikieditor-toolbar-help-page-format": "قالب‌بندی",
"wikieditor-toolbar-help-page-link": "لینکۀل",
- "wikieditor-toolbar-help-page-heading": "سةر وةڵگةل",
+ "wikieditor-toolbar-help-page-heading": "عنوان",
"wikieditor-toolbar-help-page-list": "لیستةل",
"wikieditor-toolbar-help-page-file": "پرونده‌ها",
"wikieditor-toolbar-help-page-reference": "بن چۀکةل/منابع",
@@ -186,7 +172,7 @@
"wikieditor-toolbar-help-content-file-description": "پرونده جاسازی‌شده",
"wikieditor-toolbar-help-content-file-syntax": "[[$1:Example.png|$2|$3]]",
"wikieditor-toolbar-help-content-file-caption": "متن زیرنویس",
- "wikieditor-toolbar-help-content-reference-description": "بن چۀک/مۀنبۀع",
+ "wikieditor-toolbar-help-content-reference-description": "بنچەک(منبع)",
"wikieditor-toolbar-help-content-reference-syntax": "متن صفحه.&lt;ref&gt;[http://www.example.org متن پیوند]، متن اضافی.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "متن صفحه.<sup><a href='#'>[1]</a></sup>",
"wikieditor-toolbar-help-content-named-reference-description": "منبع نامگذای‌شده",
diff --git a/www/wiki/extensions/WikiEditor/i18n/lrc.json b/www/wiki/extensions/WikiEditor/i18n/lrc.json
index 6ede339c..5e56f992 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lrc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lrc.json
@@ -8,17 +8,6 @@
"wikieditor": "كاروری پيشرفته ويراشتگر ويكی متن",
"wikieditor-wikitext-tab": "ويكی متن",
"wikieditor-loading": "د حالت سوار كرد",
- "wikieditor-preview-tab": "پيش زمينه",
- "wikieditor-preview-changes-tab": "آلشتيا",
- "wikieditor-preview-loading": "د حالت سوار كرد",
- "wikieditor-publish-preference": "توانايی پا وه پا سی انتشار",
- "wikieditor-publish-button-publish": "منتشر كردن",
- "wikieditor-publish-button-cancel": "رد كردن",
- "wikieditor-publish-dialog-title": "انتشار سی{{نوم مالگه}}",
- "wikieditor-publish-dialog-minor": "ويرايشت كؤچك",
- "wikieditor-publish-dialog-watch": "ديئن ای بلگه",
- "wikieditor-publish-dialog-publish": "منتشر كردن",
- "wikieditor-publish-dialog-goback": "ورئرد",
"wikieditor-toolbar": "اوزارگه ويرايشت",
"wikieditor-toolbar-loading": "د حالت سوار كرد",
"wikieditor-toolbar-tool-bold": "توپر",
diff --git a/www/wiki/extensions/WikiEditor/i18n/lt.json b/www/wiki/extensions/WikiEditor/i18n/lt.json
index b0a9854f..9e644918 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lt.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lt.json
@@ -10,30 +10,17 @@
"Pofka",
"Salpusnis",
"Albertas",
- "Zygimantus"
+ "Zygimantus",
+ "Manvydasz"
]
},
- "wikieditor": "Išplėstinė wikiteksto redagavimo sąsaja",
- "wikieditor-desc": "Prideda išplečiamą wikiteksto redagavimo sąsają ir daug funkcijų turinčius modulius",
- "wikieditor-wikitext-tab": "Wikitekstas",
- "wikieditor-loading": "Įkeliama",
- "wikieditor-preview-preference": "Įjungti ''side-by-side'' peržiūrą",
- "wikieditor-preview-tab": "Peržiūra",
- "wikieditor-preview-changes-tab": "Pokyčiai",
- "wikieditor-preview-loading": "Kraunama...",
- "wikieditor-publish-preference": "Įjungti žingsnis po žingsnio publikavimą",
- "wikieditor-publish-button-publish": "Publikuoti",
- "wikieditor-publish-button-cancel": "Atšaukti",
- "wikieditor-publish-dialog-title": "Publikuoti į {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Redagavimo komentaras (trumpai aprašykite, kokius pakeitimus padarėte):",
- "wikieditor-publish-dialog-minor": "Smulkus keitimas",
- "wikieditor-publish-dialog-watch": "Stebėti šį puslapį",
- "wikieditor-publish-dialog-publish": "Publikuoti",
- "wikieditor-publish-dialog-goback": "Grįžti",
+ "wikieditor": "Išplėstinė vikiteksto redagavimo sąsaja",
+ "wikieditor-desc": "Prideda pažangią, išplečiamą vikiteksto redagavimo sąsają",
+ "wikieditor-wikitext-tab": "Vikitekstas",
+ "wikieditor-loading": "Įkeliama...",
"wikieditor-toolbar": "Redagavimo įrankių juosta",
"wikieditor-toolbar-desc": "Redaguoti įrankių juostą, siekiant didesnio praktiškumo",
"wikieditor-toolbar-preference": "Įjungti naudingesnę įrankių juostą",
- "wikieditor-toolbar-dialogs-preference": "Įgalinti vedlius nuorodoms, lentelėms įterpti, taip pat paieškos ir keitimo funkciją",
"wikieditor-toolbar-loading": "Kraunama...",
"wikieditor-toolbar-tool-bold": "Paryškinti",
"wikieditor-toolbar-tool-bold-example": "Paryškinti tekstą",
@@ -42,10 +29,10 @@
"wikieditor-toolbar-tool-ilink": "Vidinė nuoroda",
"wikieditor-toolbar-tool-ilink-example": "Nuorodos pavadinimas",
"wikieditor-toolbar-tool-xlink": "Išorinė nuoroda (nepamirškite http:// priedėlio)",
- "wikieditor-toolbar-tool-xlink-example": "http://www.example.com nuorodos pavadinimas",
+ "wikieditor-toolbar-tool-xlink-example": "http://www.pavyzdys.lt nuorodos pavadinimas",
"wikieditor-toolbar-tool-link": "Nuoroda",
"wikieditor-toolbar-tool-link-title": "Įterpti nuorodą",
- "wikieditor-toolbar-tool-link-int": "Į wiki puslapį",
+ "wikieditor-toolbar-tool-link-int": "Į viki puslapį",
"wikieditor-toolbar-tool-link-int-target": "Paskirties puslapis arba URL:",
"wikieditor-toolbar-tool-link-int-target-tooltip": "Puslapio pavadinimas arba URL",
"wikieditor-toolbar-tool-link-int-text": "Rodomas tekstas:",
@@ -61,12 +48,12 @@
"wikieditor-toolbar-tool-link-int-target-status-external": "Išorinė nuoroda",
"wikieditor-toolbar-tool-link-int-target-status-loading": "Tikrinama, ar puslapis egzistuoja...",
"wikieditor-toolbar-tool-link-int-target-status-disambig": "Paaiškinimo puslapis",
- "wikieditor-toolbar-tool-link-int-invalid": "Nurodytas pavadinimas yra neleistinas",
- "wikieditor-toolbar-tool-link-lookslikeinternal": "Adresas, kurį nurodėte, atrodo, turėjo yra nuoroda į kitą wiki puslapį. Ar norite paversti nuorodą vidine?",
+ "wikieditor-toolbar-tool-link-int-invalid": "Jūsų nurodytas pavadinimas neleistinas.",
+ "wikieditor-toolbar-tool-link-lookslikeinternal": "Adresas, kurį nurodėte, tikriausiai yra nuoroda į kitą viki puslapį. Ar norite paversti nuorodą vidine?",
"wikieditor-toolbar-tool-link-lookslikeinternal-int": "Vidinė nuoroda",
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Išorinė nuoroda",
"wikieditor-toolbar-tool-link-empty": "Jūs neįvedėte nieko, į ką nurodyti.",
- "wikieditor-toolbar-tool-file": "Įdėti failą",
+ "wikieditor-toolbar-tool-file": "Įterpta rinkmena",
"wikieditor-toolbar-tool-file-example": "Pavyzdys.jpg",
"wikieditor-toolbar-tool-file-title": "Įterpti failą",
"wikieditor-toolbar-file-target": "Failo pavadinimas:",
@@ -82,9 +69,9 @@
"wikieditor-toolbar-tool-reference": "Išnaša",
"wikieditor-toolbar-tool-reference-example": "Čia įterpkite teksto išnašą",
"wikieditor-toolbar-tool-reference-cancel": "Atšaukti",
- "wikieditor-toolbar-tool-reference-title": "Įtraukti nuorodą",
+ "wikieditor-toolbar-tool-reference-title": "Įtraukti išnašą",
"wikieditor-toolbar-tool-reference-insert": "Įtraukti",
- "wikieditor-toolbar-tool-reference-text": "Nuorodos tekstas",
+ "wikieditor-toolbar-tool-reference-text": "Išnašos tekstas",
"wikieditor-toolbar-tool-signature": "Jūsų parašas bei laikas",
"wikieditor-toolbar-section-advanced": "Išplėstinis",
"wikieditor-toolbar-tool-heading": "Antraštė",
@@ -99,9 +86,9 @@
"wikieditor-toolbar-tool-ulist-example": "Punktuoto sąrašo elementas",
"wikieditor-toolbar-tool-olist": "Numeruotas sąrašas",
"wikieditor-toolbar-tool-olist-example": "Numeruoto sąrašo elementas",
- "wikieditor-toolbar-tool-nowiki": "Ignoruoti wiki formatą",
+ "wikieditor-toolbar-tool-nowiki": "Ignoruoti viki formatavimą",
"wikieditor-toolbar-tool-nowiki-example": "Čia įterpkite neformuotą tekstą",
- "wikieditor-toolbar-tool-redirect": "nukreipimą",
+ "wikieditor-toolbar-tool-redirect": "Nukreipimas",
"wikieditor-toolbar-tool-redirect-example": "Tikslinio puslapio pavadinimas",
"wikieditor-toolbar-tool-big": "Didelis",
"wikieditor-toolbar-tool-big-example": "Didelis tekstas",
@@ -129,7 +116,7 @@
"wikieditor-toolbar-tool-table-preview": "Peržiūra",
"wikieditor-toolbar-tool-table-insert": "Įterpti",
"wikieditor-toolbar-tool-table-cancel": "Atšaukti",
- "wikieditor-toolbar-tool-table-toomany": "Įterpti lentelę su daugiau nei $1 {{PLURAL:$1|}} langelių šiame lange negalima.",
+ "wikieditor-toolbar-tool-table-toomany": "Įterpti lentelę su daugiau nei $1 {{PLURAL:$1|langelių}} šiame lange negalima.",
"wikieditor-toolbar-tool-table-invalidnumber": "Jūs neįvedėte leistino skaičiaus eilučių ar stulpelių.",
"wikieditor-toolbar-tool-table-zero": "Jūs negalite įterpti lentelės su nuliu eilučių ar stulpelių.",
"wikieditor-toolbar-tool-replace": "Ieškoti ir pakeisti",
@@ -143,7 +130,7 @@
"wikieditor-toolbar-tool-replace-button-replaceall": "Pakeisti visus",
"wikieditor-toolbar-tool-replace-close": "Uždaryti",
"wikieditor-toolbar-tool-replace-nomatch": "Jūsų paieška nieko nerado.",
- "wikieditor-toolbar-tool-replace-success": "Atlikta $1{{PLURAL:$1|}} pakeitimas (-ų).",
+ "wikieditor-toolbar-tool-replace-success": "Atlikta $1{{PLURAL:$1|pakeitimas|pakeitimai|pakeitimų}}.",
"wikieditor-toolbar-tool-replace-emptysearch": "Jūs nieko neįvedėte į paiešką.",
"wikieditor-toolbar-tool-replace-invalidregex": "Reguliarioji išraiška, kurią įvedėte, yra neleistina: $1",
"wikieditor-toolbar-section-characters": "Specialieji simboliai",
@@ -155,7 +142,7 @@
"wikieditor-toolbar-help-page-link": "Nuorodos",
"wikieditor-toolbar-help-page-heading": "Antraštės",
"wikieditor-toolbar-help-page-list": "Sąrašai",
- "wikieditor-toolbar-help-page-file": "Failai",
+ "wikieditor-toolbar-help-page-file": "Rinkmenos",
"wikieditor-toolbar-help-page-reference": "Išnašos",
"wikieditor-toolbar-help-page-discussion": "Aptarimas",
"wikieditor-toolbar-help-content-italic-description": "Kursyvas",
@@ -171,8 +158,8 @@
"wikieditor-toolbar-help-content-ilink-syntax": "[[Puslapio pavadinimas]]<br />[[Puslapio pavadinimas|Nuorodos žymė]]",
"wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Puslapio pavadinimas</a><br /><a href='#'>Nuorodos žymė</a>",
"wikieditor-toolbar-help-content-xlink-description": "Išorinė nuoroda",
- "wikieditor-toolbar-help-content-xlink-syntax": "[http://www.example.org Nuorodos pavadinimas]<br />[http://www.example.org]<br />http://www.example.org",
- "wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>Nuorodos pavadinimas</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.example.org</a>",
+ "wikieditor-toolbar-help-content-xlink-syntax": "[http://www.pavyzdys.org Nuorodos pavadinimas]<br />[http://www.pavyzdys.org]<br />http://www.pavyzdys.org",
+ "wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>Nuorodos pavadinimas</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.pavyzdys.org</a>",
"wikieditor-toolbar-help-content-heading2-description": "2-ojo lygio antraštė",
"wikieditor-toolbar-help-content-heading2-syntax": "== Antraštės tekstas ==",
"wikieditor-toolbar-help-content-heading2-result": "<h2>Antraštės tekstas</h2>",
@@ -191,21 +178,21 @@
"wikieditor-toolbar-help-content-olist-description": "Numeruotas sąrašas",
"wikieditor-toolbar-help-content-olist-syntax": "# Sąrašo elementas<br /># Sąrašo elementas",
"wikieditor-toolbar-help-content-olist-result": "<ol><li>Sąrašo elementas</li><li>Sąrašo elementas</li></ol>",
- "wikieditor-toolbar-help-content-file-description": "Įterpti failą",
+ "wikieditor-toolbar-help-content-file-description": "Įterpta rinkmena",
"wikieditor-toolbar-help-content-file-syntax": "[[$1:Pavyzdys.png|$2|$3]]",
"wikieditor-toolbar-help-content-file-caption": "Antraštės tekstas",
"wikieditor-toolbar-help-content-reference-description": "Išnaša",
- "wikieditor-toolbar-help-content-reference-syntax": "Puslapio tekstas.&lt;ref&gt;[http://www.example.org Nuorodos tekstas], papildomas tekstas.&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-reference-syntax": "Puslapio tekstas.&lt;ref&gt;[http://www.pavyzdys.org Nuorodos tekstas], papildomas tekstas.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "Puslapio tekstas.<sup><a href='#'>[1]</a></sup>",
"wikieditor-toolbar-help-content-named-reference-description": "Nuoroda su pavadinimu",
- "wikieditor-toolbar-help-content-named-reference-syntax": "Puslapio tekstas.&lt;ref name=\"testas\"&gt;[http://www.example.org Nuorodos tekstas]&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-named-reference-syntax": "Puslapio tekstas.&lt;ref name=\"testas\"&gt;[http://www.pavyzdys.org Nuorodos tekstas]&lt;/ref&gt;",
"wikieditor-toolbar-help-content-named-reference-result": "Puslapio tekstas.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "Papildomas tos pačios išnašos naudojimas",
"wikieditor-toolbar-help-content-rereference-result": "Puslapio tekstas.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "Rodyti išnašas",
- "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Nuorodos tekstas</a>, papildomas tekstas.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Nuorodos tekstas</a></li></ol>",
+ "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.pavyzdys.org' class='external text' href='#'>Nuorodos tekstas</a>, papildomas tekstas.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.pavyzdys.org' class='external text' href='#'>Nuorodos tekstas</a></li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "Parašas bei laikas",
- "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Naudotojo vardas</a> (<a href='#' title='$2:Username'>aptarimas</a>) 15:54, 10 June 2009 (UTC)",
+ "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Naudotojo vardas</a> (<a href='#' title='$2:Username'>aptarimas</a>) 15:54, 2009 birželio 10 d. (UTC)",
"wikieditor-toolbar-help-content-signature-description": "Parašas",
"wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>Naudotojo vardas</a> (<a href='#' title='$2:Username'>aptarimas</a>)",
"wikieditor-toolbar-help-content-indent-description": "Įtrauka",
diff --git a/www/wiki/extensions/WikiEditor/i18n/lus.json b/www/wiki/extensions/WikiEditor/i18n/lus.json
index e84b112d..ff2d7e95 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lus.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lus.json
@@ -7,9 +7,6 @@
},
"wikieditor-wikitext-tab": "Wikithu",
"wikieditor-loading": "Nghâk lawks...",
- "wikieditor-preview-tab": "Enchhinna",
- "wikieditor-preview-changes-tab": "Tihdanglamte",
- "wikieditor-preview-loading": "Nghâk lawks...",
"wikieditor-toolbar-tool-bold": "Tháu",
"wikieditor-toolbar-tool-bold-example": "Kutziak tháu",
"wikieditor-toolbar-tool-italic": "Äwn",
diff --git a/www/wiki/extensions/WikiEditor/i18n/lv.json b/www/wiki/extensions/WikiEditor/i18n/lv.json
index 4444faf8..f4a01eab 100644
--- a/www/wiki/extensions/WikiEditor/i18n/lv.json
+++ b/www/wiki/extensions/WikiEditor/i18n/lv.json
@@ -11,20 +11,9 @@
},
"wikieditor-wikitext-tab": "Vikiteksts",
"wikieditor-loading": "Ielādē…",
- "wikieditor-preview-preference": "Ieslēgt ''side-by-side'' priekšskatu",
- "wikieditor-preview-tab": "Pirmskats",
- "wikieditor-preview-changes-tab": "Izmaiņas",
- "wikieditor-preview-loading": "Ielādē…",
- "wikieditor-publish-button-publish": "Publicēt",
- "wikieditor-publish-button-cancel": "Atcelt",
- "wikieditor-publish-dialog-minor": "Maznozīmīgs labojums",
- "wikieditor-publish-dialog-watch": "Uzraudzīt šo lapu",
- "wikieditor-publish-dialog-publish": "Publicēt",
- "wikieditor-publish-dialog-goback": "Atpakaļ",
"wikieditor-toolbar": "Rediģēšanas rīku josla",
"wikieditor-toolbar-desc": "Rediģēšanas rīku josla ar uzlabotu lietojamību",
"wikieditor-toolbar-preference": "Izmantot paplašināto rediģēšanas rīkjoslu",
- "wikieditor-toolbar-dialogs-preference": "Izmantot dialoga logus saišu, tabulu u.c. ievietošanai",
"wikieditor-toolbar-loading": "Ielādē…",
"wikieditor-toolbar-tool-bold": "Pustrekns",
"wikieditor-toolbar-tool-bold-example": "Pustrekns teksts",
diff --git a/www/wiki/extensions/WikiEditor/i18n/mai.json b/www/wiki/extensions/WikiEditor/i18n/mai.json
index 19b888bf..c50b0b2a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/mai.json
+++ b/www/wiki/extensions/WikiEditor/i18n/mai.json
@@ -8,18 +8,6 @@
"wikieditor-desc": "प्रदान करत एक विकिपाठ्य सम्पादन इन्टरफेस आ बहुत सुविधा प्रदान करैत अछि",
"wikieditor-wikitext-tab": "विकिपाठ्य",
"wikieditor-loading": "लोड भऽ रहल अछि...",
- "wikieditor-preview-preference": "सक्षम पक्ष ध्वारा पक्ष पूर्वावलोकन",
- "wikieditor-preview-tab": "पूर्वावलोकन",
- "wikieditor-preview-changes-tab": "परिवर्तन",
- "wikieditor-preview-loading": "लोड भऽ रहल अछि...",
- "wikieditor-publish-preference": "प्रकाशित कदम सक्षम करी",
- "wikieditor-publish-button-publish": "प्रकाशित करी",
- "wikieditor-publish-button-cancel": "रद्द करी",
- "wikieditor-publish-dialog-title": "{{SITENAME}}पर छापल जाए",
- "wikieditor-publish-dialog-minor": "छोट सम्पादन",
- "wikieditor-publish-dialog-watch": "ई पृष्ठके ध्यानसूचीमे राखी",
- "wikieditor-publish-dialog-publish": "प्रकाशित करी",
- "wikieditor-publish-dialog-goback": "पाछा जाए",
"wikieditor-toolbar": "सम्पादन उपकरण पट्टी",
"wikieditor-toolbar-tool-bold": "बोल्ड",
"wikieditor-toolbar-tool-bold-example": "मोट अक्षर",
diff --git a/www/wiki/extensions/WikiEditor/i18n/min.json b/www/wiki/extensions/WikiEditor/i18n/min.json
index d19d533a..bdefa0d9 100644
--- a/www/wiki/extensions/WikiEditor/i18n/min.json
+++ b/www/wiki/extensions/WikiEditor/i18n/min.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Manyadiokan suntiangan antarmuko teks wiki nan banyak fitua",
"wikieditor-wikitext-tab": "Teks wiki",
"wikieditor-loading": "Loading...",
- "wikieditor-preview-preference": "Aktifkan pratonton basisian",
- "wikieditor-preview-tab": "Pratonton",
- "wikieditor-preview-changes-tab": "Parubahan",
- "wikieditor-preview-loading": "Loading...",
- "wikieditor-publish-preference": "Aktifkan panarbitan batahap",
- "wikieditor-publish-button-publish": "Tabikan",
- "wikieditor-publish-button-cancel": "Batal",
- "wikieditor-publish-dialog-title": "Tabikan ka {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Ikhtisar suntiangan (jalehan sacaro ringkeh parubahan nan Sanak buek):",
- "wikieditor-publish-dialog-minor": "Suntiangan ketek",
- "wikieditor-publish-dialog-watch": "Pantau laman ko",
- "wikieditor-publish-dialog-publish": "Tabikan",
- "wikieditor-publish-dialog-goback": "Baliak",
"wikieditor-toolbar": "Bilah suntiang",
"wikieditor-toolbar-desc": "Laman bilah suntiang jo kagunoan lanjuik",
"wikieditor-toolbar-preference": "Aktipan bilah panyuntiangan tingkek lanjuik",
- "wikieditor-toolbar-dialogs-preference": "Aktipan bantuan untuak manambah pautan, tabel dan lainnyo",
"wikieditor-toolbar-loading": "Loading...",
"wikieditor-toolbar-tool-bold": "Taba",
"wikieditor-toolbar-tool-bold-example": "Teks taba",
diff --git a/www/wiki/extensions/WikiEditor/i18n/mk.json b/www/wiki/extensions/WikiEditor/i18n/mk.json
index 66f74e03..30b910b2 100644
--- a/www/wiki/extensions/WikiEditor/i18n/mk.json
+++ b/www/wiki/extensions/WikiEditor/i18n/mk.json
@@ -6,26 +6,12 @@
]
},
"wikieditor": "Посредник за напредно уредување со викитекст",
- "wikieditor-desc": "Дава проширлив посредник за уредување со викитекст и многу модули за разни други алатки",
+ "wikieditor-desc": "Дава напреден и проширлив посредник за уредување со викитекст и многу модули за разни други алатки",
"wikieditor-wikitext-tab": "ВикиТекст",
"wikieditor-loading": "Вчитувам",
- "wikieditor-preview-preference": "Овозможи преглед „рамо до рамо“",
- "wikieditor-preview-tab": "Преглед",
- "wikieditor-preview-changes-tab": "Промени",
- "wikieditor-preview-loading": "Вчитувам...",
- "wikieditor-publish-preference": "Овозможи објавување „чекор по чекор“",
- "wikieditor-publish-button-publish": "Објави",
- "wikieditor-publish-button-cancel": "Откажи",
- "wikieditor-publish-dialog-title": "Објави на {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Опис на уредувањето (накратко опишете ги промените кои ги направивте):",
- "wikieditor-publish-dialog-minor": "Ситно уредување",
- "wikieditor-publish-dialog-watch": "Набљудувај ја страницава",
- "wikieditor-publish-dialog-publish": "Објави",
- "wikieditor-publish-dialog-goback": "Назад",
"wikieditor-toolbar": "Алатник за уредување",
"wikieditor-toolbar-desc": "Алатник за уредување со подобрена употребливост",
"wikieditor-toolbar-preference": "Вклучи го подобрениот алатник за уредување",
- "wikieditor-toolbar-dialogs-preference": "Овозможи помошници за вметнување врски, табели, како и можноста за пребарување и замена",
"wikieditor-toolbar-loading": "Вчитувам...",
"wikieditor-toolbar-tool-bold": "Задебелено",
"wikieditor-toolbar-tool-bold-example": "Задебелен текст",
@@ -113,7 +99,7 @@
"wikieditor-toolbar-tool-table-example-header": "Текст на наслов",
"wikieditor-toolbar-tool-table-title": "Вметни табела",
"wikieditor-toolbar-tool-table-dimensions-rows": "Редови",
- "wikieditor-toolbar-tool-table-dimensions-columns": "Колони",
+ "wikieditor-toolbar-tool-table-dimensions-columns": "Столбови",
"wikieditor-toolbar-tool-table-dimensions-header": "Вклучи насловен ред",
"wikieditor-toolbar-tool-table-wikitable": "Стил со граници",
"wikieditor-toolbar-tool-table-sortable": "Подредлива табела",
@@ -122,8 +108,8 @@
"wikieditor-toolbar-tool-table-insert": "Вметни",
"wikieditor-toolbar-tool-table-cancel": "Откажи",
"wikieditor-toolbar-tool-table-toomany": "Не можете да вметнувате табела со повеќе од $1 {{PLURAL:$1|ќелии}} со овој дијалог.",
- "wikieditor-toolbar-tool-table-invalidnumber": "Не внесовте важечки број на редови или колони.",
- "wikieditor-toolbar-tool-table-zero": "Не можете да вметнувате табела со нула редови или колони.",
+ "wikieditor-toolbar-tool-table-invalidnumber": "Не внесовте важечки број на редови или столбови.",
+ "wikieditor-toolbar-tool-table-zero": "Не можете да вметнувате табела со нула редови или столбови.",
"wikieditor-toolbar-tool-replace": "Најди и замени",
"wikieditor-toolbar-tool-replace-title": "Најди и замени",
"wikieditor-toolbar-tool-replace-search": "Барај:",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ml.json b/www/wiki/extensions/WikiEditor/i18n/ml.json
index 5ca10304..a96919ce 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ml.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ml.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "വികസിപ്പിക്കാവുന്ന വിധത്തിലുള്ള വിക്കിഎഴുത്ത് തിരുത്തൽ സമ്പർക്കമുഖവും മറ്റ് സവിശേഷ ഘടകങ്ങളും നൽകുന്നു",
"wikieditor-wikitext-tab": "വിക്കിഎഴുത്ത്",
"wikieditor-loading": "ശേഖരിക്കുന്നു...",
- "wikieditor-preview-preference": "അരികിലായുള്ള പ്രിവ്യൂ സജ്ജമാക്കുക",
- "wikieditor-preview-tab": "എങ്ങനെയുണ്ടെന്നു കാണുക",
- "wikieditor-preview-changes-tab": "മാറ്റങ്ങൾ",
- "wikieditor-preview-loading": "ശേഖരിക്കുന്നു...",
- "wikieditor-publish-preference": "ഘട്ടം ഘട്ടമായുള്ള പ്രസിദ്ധപ്പെടുത്തൽ സജ്ജമാക്കുക",
- "wikieditor-publish-button-publish": "പ്രസിദ്ധീകരിക്കുക",
- "wikieditor-publish-button-cancel": "റദ്ദാക്കുക",
- "wikieditor-publish-dialog-title": "{{SITENAME}} സംരംഭത്തിൽ പ്രസിദ്ധീകരിക്കുക",
- "wikieditor-publish-dialog-summary": "തിരുത്തലിന്റെ ചുരുക്കം (താങ്കൾ വരുത്തിയ മാറ്റങ്ങൾ ലഘുവായി വിശദീകരിക്കുക):",
- "wikieditor-publish-dialog-minor": "ചെറു തിരുത്തൽ",
- "wikieditor-publish-dialog-watch": "ഈ താൾ ശ്രദ്ധിക്കുക",
- "wikieditor-publish-dialog-publish": "പ്രസിദ്ധീകരിക്കുക",
- "wikieditor-publish-dialog-goback": "പഴയ താളിലേയ്ക്ക് മടങ്ങുക",
"wikieditor-toolbar": "തിരുത്തൽ പണിപ്പെട്ടി",
"wikieditor-toolbar-desc": "തിരുത്താനുള്ള താളിൽ മെച്ചപ്പെട്ട ഉപയോഗത്തിനായുള്ള പണിപ്പെട്ടി",
"wikieditor-toolbar-preference": "തിരുത്തുവാനുള്ള വിശദ പണിപ്പെട്ടി ഉപയോഗപ്പെടുത്തുക",
- "wikieditor-toolbar-dialogs-preference": "കണ്ണികൾ, പട്ടികകൾ ഒപ്പം തിരഞ്ഞ് കണ്ടെത്താനും മാറ്റാനും ഉള്ള സൗകര്യം തുടങ്ങിയവ ഉൾപ്പെടുത്താനുള്ള വഴികാട്ടി സജ്ജമാക്കുക",
"wikieditor-toolbar-loading": "ശേഖരിക്കുന്നു...",
"wikieditor-toolbar-tool-bold": "കടുപ്പിക്കുക",
"wikieditor-toolbar-tool-bold-example": "കട്ടികൂട്ടിയ എഴുത്ത്",
@@ -72,6 +58,7 @@
"wikieditor-toolbar-file-format-none": "ഒന്നുമില്ല",
"wikieditor-toolbar-tool-file-insert": "ഉൾപ്പെടുത്തുക",
"wikieditor-toolbar-tool-file-cancel": "റദ്ദാക്കുക",
+ "wikieditor-toolbar-tool-file-upload": "അപ്‌ലോഡ്",
"wikieditor-toolbar-tool-reference": "അവലംബം",
"wikieditor-toolbar-tool-reference-example": "അടിക്കുറിപ്പിനുള്ള എഴുത്ത് ഇവിടെ ചേർക്കുക",
"wikieditor-toolbar-tool-reference-cancel": "റദ്ദാക്കുക",
@@ -122,7 +109,7 @@
"wikieditor-toolbar-tool-table-preview": "എങ്ങനെയുണ്ടെന്നു കാണുക",
"wikieditor-toolbar-tool-table-insert": "ഉൾപ്പെടുത്തുക",
"wikieditor-toolbar-tool-table-cancel": "റദ്ദാക്കുക",
- "wikieditor-toolbar-tool-table-toomany": "ഇതുപയോഗിച്ച് 1000 കളങ്ങളിൽ അധികമുള്ള പട്ടിക ഉൾപ്പെടുത്തുക സാദ്ധ്യമല്ല.",
+ "wikieditor-toolbar-tool-table-toomany": "ഇതുപയോഗിച്ച് $1 {{PLURAL:$1|കളങ്ങളിൽ}} അധികമുള്ള പട്ടിക ഉൾപ്പെടുത്തുക സാദ്ധ്യമല്ല.",
"wikieditor-toolbar-tool-table-invalidnumber": "വരികൾക്കും നിരകൾക്കും സാധുവായ എണ്ണം താങ്കൾ നൽകിയിട്ടില്ല.",
"wikieditor-toolbar-tool-table-zero": "പൂജ്യം വരികളോ നിരകളോ ഉള്ള പട്ടിക ഉൾപ്പെടുത്താൻ താങ്കൾക്കു കഴിയില്ല.",
"wikieditor-toolbar-tool-replace": "കണ്ടെത്തുക മാറ്റുക",
@@ -161,8 +148,8 @@
"wikieditor-toolbar-help-content-bolditalic-syntax": "'''''കട്ടികൂട്ടി ചെരിച്ചുള്ള എഴുത്ത്'''''",
"wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>കട്ടികൂട്ടി ചെരിച്ചുള്ള എഴുത്ത്</em></strong>",
"wikieditor-toolbar-help-content-ilink-description": "ആന്തരിക കണ്ണി",
- "wikieditor-toolbar-help-content-ilink-syntax": "[[താളിന്റെ തലക്കെട്ട്|കണ്ണിയുടെ നാമം]]<br />[[താളിന്റെ തലക്കെട്ട്]]",
- "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>കണ്ണിയുടെ നാമം</a><br /><a href='#'>താളിന്റെ തലക്കെട്ട്</a>",
+ "wikieditor-toolbar-help-content-ilink-syntax": "[[താളിന്റെ തലക്കെട്ട്]]<br />[[താളിന്റെ തലക്കെട്ട്|കണ്ണിയുടെ നാമം]]",
+ "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>താളിന്റെ തലക്കെട്ട്</a><br /><a href='#'>കണ്ണിയുടെ നാമം</a>",
"wikieditor-toolbar-help-content-xlink-description": "പുറത്തേയ്ക്കുള്ള കണ്ണി",
"wikieditor-toolbar-help-content-xlink-syntax": "[http://www.example.org കണ്ണിയുടെ പേര്]<br />[http://www.example.org]<br />http://www.example.org",
"wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>കണ്ണിയുടെ പേര്</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.example.org</a>",
@@ -186,13 +173,17 @@
"wikieditor-toolbar-help-content-olist-result": "<ol><li>ലിസ്റ്റിലെ അംഗം</li><li>ലിസ്റ്റിലെ അംഗം</li></ol>",
"wikieditor-toolbar-help-content-file-description": "പ്രമാണം ചേർക്കൽ",
"wikieditor-toolbar-help-content-file-syntax": "[[$1:Example.png|$2|$3]]",
+ "wikieditor-toolbar-help-content-file-caption": "അടിക്കുറിപ്പ്",
"wikieditor-toolbar-help-content-reference-description": "അവലംബം",
"wikieditor-toolbar-help-content-reference-syntax": "താളിലെ എഴുത്ത്.&lt;ref&gt;[http://www.example.org കണ്ണിയായുള്ള എഴുത്ത്], കൂടുതൽ എഴുത്ത്.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "താളിലെ എഴുത്ത്.<sup><a href='#'>[1]</a></sup>",
+ "wikieditor-toolbar-help-content-named-reference-description": "പേരുള്ള അവലംബം",
+ "wikieditor-toolbar-help-content-named-reference-syntax": "താളിലെ എഴുത്ത്.&lt;ref name=\"test\"&gt;[http://www.example.org കണ്ണിയുടെ എഴുത്ത്]&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-named-reference-result": "താളിലെ എഴുത്ത്.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "അതേ അവലംബത്തിന്റെ കൂടുതൽ ഉപയോഗം",
"wikieditor-toolbar-help-content-rereference-result": "താളിലെ എഴുത്ത്.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "അവലംബങ്ങൾ പ്രദർശിപ്പിക്കുക",
- "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>കണ്ണിയായുള്ള എഴുത്ത്</a>, കൂടുതൽ എഴുത്ത്.</li></ol>",
+ "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>കണ്ണിയുടെ എഴുത്ത്</a>, അധിക എഴുത്ത്.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>കണ്ണിയുടെ എഴുത്ത്</a></li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "സമയമുദ്രയോടുകൂടിയ ഒപ്പ്",
"wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>ഉപയോക്തൃനാമം</a> (<a href='#' title='$2:Username'>സംവാദം</a>) 15:54, 10 ജൂൺ 2009 (UTC)",
"wikieditor-toolbar-help-content-signature-description": "ഒപ്പ്",
diff --git a/www/wiki/extensions/WikiEditor/i18n/mr.json b/www/wiki/extensions/WikiEditor/i18n/mr.json
index aaa8a20e..7bfbe420 100644
--- a/www/wiki/extensions/WikiEditor/i18n/mr.json
+++ b/www/wiki/extensions/WikiEditor/i18n/mr.json
@@ -9,30 +9,17 @@
"V.narsikar",
"अभय नातू",
"संतोष दहिवळ",
- "Macofe"
+ "Macofe",
+ "Sureshkhole"
]
},
"wikieditor": "विकिमजकूर संपादनाची विकसित सुविधा",
"wikieditor-desc": "विस्तारणीय विकिमजकुर संपादन आंतरपृष्ठ (इंटरफेस) आणि बर्‍याच वैशिष्ट्यपूर्ण निश्चयिका (मॊड्यूल्स) पुरवते",
"wikieditor-wikitext-tab": "विकिमजकूर",
"wikieditor-loading": "प्रभारण करीत आहे",
- "wikieditor-preview-preference": "सोबतच आजु-बाजूस दिसणारी झलक शक्य करा.",
- "wikieditor-preview-tab": "झलक",
- "wikieditor-preview-changes-tab": "बदल",
- "wikieditor-preview-loading": "प्रभारण करीत आहे",
- "wikieditor-publish-preference": "टप्प्या-टप्प्याने प्रकाशन शक्य करा",
- "wikieditor-publish-button-publish": "प्रकाशित करा\nदाखवा",
- "wikieditor-publish-button-cancel": "रद्द करा",
- "wikieditor-publish-dialog-title": "{{संकेतस्थळनाव}} येथे प्रदर्शित करा",
- "wikieditor-publish-dialog-summary": "बदलांचा सारांश :(आपण केलेल्या बदलांचे थोडक्यात वर्णन करा):",
- "wikieditor-publish-dialog-minor": "छोटा बदल",
- "wikieditor-publish-dialog-watch": "पान निरीक्षणांतर्गत ठेवा",
- "wikieditor-publish-dialog-publish": "प्रकाशित करा",
- "wikieditor-publish-dialog-goback": "मागे जा",
"wikieditor-toolbar": "संपादन साधनपट्टी",
"wikieditor-toolbar-desc": "सुलभीकरणाने वर्धित संपादनपान साधनपट्टी",
"wikieditor-toolbar-preference": "वर्धित संपादन साधनपट्टी सक्षम करा",
- "wikieditor-toolbar-dialogs-preference": "दुवे, सारण्या टाकण्यासाठी तसेच, शोधा व 'ने बदला' (search and replace) क्रियेसाठी जादूगार(विझार्ड) सक्षम करा.",
"wikieditor-toolbar-loading": "प्रभारण करीत आहे",
"wikieditor-toolbar-tool-bold": "ठळक",
"wikieditor-toolbar-tool-bold-example": "ठळक मजकूर",
@@ -197,6 +184,8 @@
"wikieditor-toolbar-help-content-reference-syntax": "पान मजकूर.&lt;ref&gt;[http://www.example.org दुवा मजकूर], अतिरिक्त मजकूर.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "पान मजकूर.<sup><a href='#'>[१]</a></sup>",
"wikieditor-toolbar-help-content-named-reference-description": "नामित संदर्भ",
+ "wikieditor-toolbar-help-content-named-reference-syntax": "पान मजकूर.&lt;ref name=\"test\"&gt;[http://www.example.org Link text]&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-named-reference-result": "पान मजकूर.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "याच संदर्भाचा अतिरिक्त वापर",
"wikieditor-toolbar-help-content-rereference-result": "पान मजकूर.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "संदर्भ दर्शवा",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ms.json b/www/wiki/extensions/WikiEditor/i18n/ms.json
index 050b48ea..3649534c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ms.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ms.json
@@ -15,23 +15,9 @@
"wikieditor-desc": "Menyediakan halaman wikitext suntingan dan ciri modul lain",
"wikieditor-wikitext-tab": "Wikiteks",
"wikieditor-loading": "Editor sedang dimuatkan",
- "wikieditor-preview-preference": "Aktifkan pralihat perbandingan",
- "wikieditor-preview-tab": "Pralihat",
- "wikieditor-preview-changes-tab": "Perubahan",
- "wikieditor-preview-loading": "Memuatkan...",
- "wikieditor-publish-preference": "Aktifkan tutorial penerbitan",
- "wikieditor-publish-button-publish": "Terbitkan",
- "wikieditor-publish-button-cancel": "Batalkan",
- "wikieditor-publish-dialog-title": "Paparkan pada laman ((sitename))",
- "wikieditor-publish-dialog-summary": "Sunting ringkasan (jelaskan perubahan yang disertakan secara ringkas)",
- "wikieditor-publish-dialog-minor": "Suntingan kecil",
- "wikieditor-publish-dialog-watch": "Pantau laman ini",
- "wikieditor-publish-dialog-publish": "Terbitkan",
- "wikieditor-publish-dialog-goback": "Kembali",
"wikieditor-toolbar": "Bar alatan penyuntingan",
"wikieditor-toolbar-desc": "Bar alatan penyuntingan maju",
"wikieditor-toolbar-preference": "Bolehkan alatan penyuntingan maju",
- "wikieditor-toolbar-dialogs-preference": "Bolehkan pendeta untuk menyisipkan pautan di samping juga fungsi cari dan ganti",
"wikieditor-toolbar-loading": "Memuatkan...",
"wikieditor-toolbar-tool-bold": "Teks tebal",
"wikieditor-toolbar-tool-bold-example": "Teks tebal",
diff --git a/www/wiki/extensions/WikiEditor/i18n/mt.json b/www/wiki/extensions/WikiEditor/i18n/mt.json
index c09c874c..86256b7b 100644
--- a/www/wiki/extensions/WikiEditor/i18n/mt.json
+++ b/www/wiki/extensions/WikiEditor/i18n/mt.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Tipprovdi interfaċċa ta' modifika tat-test tal-wiki estendibbli u ħafna moduli li jipprovdu aktar funzjonalitajiet",
"wikieditor-wikitext-tab": "Test tal-wiki",
"wikieditor-loading": "Tiela'",
- "wikieditor-preview-preference": "Ippermetti dehra proviżorja fil-ġenb",
- "wikieditor-preview-tab": "Dehra proviżorja",
- "wikieditor-preview-changes-tab": "Tibdil",
- "wikieditor-preview-loading": "Tiela'...",
- "wikieditor-publish-preference": "Ippermetti pubblikazzjoni pass pass",
- "wikieditor-publish-button-publish": "Ippubblika",
- "wikieditor-publish-button-cancel": "Annulla",
- "wikieditor-publish-dialog-title": "Ippubblika fuq {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Taqsira (iddeskrivi fil-qasir it-tibdil li għamilt):",
- "wikieditor-publish-dialog-minor": "Modifika minuri",
- "wikieditor-publish-dialog-watch": "Segwi din il-paġna",
- "wikieditor-publish-dialog-publish": "Ippubblika",
- "wikieditor-publish-dialog-goback": "Mur lura",
"wikieditor-toolbar": "Kaxxa tal-għodda għall-immodifikar",
"wikieditor-toolbar-desc": "Immodifika l-kaxxa tal-għodda b'akbar użabilità",
"wikieditor-toolbar-preference": "Awtorizza l-użu tal-kaxxa tal-għodda estiża",
- "wikieditor-toolbar-dialogs-preference": "Awtorizza l-għajnuna għaż-żieda ta' test wiki avvanzat",
"wikieditor-toolbar-loading": "Tiela'...",
"wikieditor-toolbar-tool-bold": "Tipa ħoxna",
"wikieditor-toolbar-tool-bold-example": "Tipa ħoxna",
diff --git a/www/wiki/extensions/WikiEditor/i18n/mwl.json b/www/wiki/extensions/WikiEditor/i18n/mwl.json
index 4268d748..f0321f8f 100644
--- a/www/wiki/extensions/WikiEditor/i18n/mwl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/mwl.json
@@ -1,14 +1,39 @@
{
"@metadata": {
"authors": [
- "MokaAkashiyaPT"
+ "MokaAkashiyaPT",
+ "Athena in Wonderland"
]
},
- "wikieditor-preview-tab": "Antebison",
"wikieditor-toolbar-preference": "Atibar la barra de ferramientas d'eidiçon melhorada",
+ "wikieditor-toolbar-tool-bold-example": "Testo a negrito",
+ "wikieditor-toolbar-tool-italic-example": "Testo an eitálico",
+ "wikieditor-toolbar-tool-link-title": "Poner ua lhigaçon",
+ "wikieditor-toolbar-tool-link-int": "Pa ua páigina na wiki",
+ "wikieditor-toolbar-tool-link-int-target": "Páigina ó lhigaçon eiletrónica de çtino:",
+ "wikieditor-toolbar-tool-link-int-target-tooltip": "Títalo ó lhigaçon eiletrónica de la páigina",
+ "wikieditor-toolbar-tool-link-int-text": "Testo a apersentar:",
+ "wikieditor-toolbar-tool-link-int-text-tooltip": "Poner l testo a apersentar",
+ "wikieditor-toolbar-tool-link-ext": "Pa ua páigina sterna na anternete",
+ "wikieditor-toolbar-tool-link-insert": "Poner lhigaçon",
"wikieditor-toolbar-tool-link-int-target-status-disambig": "Páigina de zambiguaçon",
+ "wikieditor-toolbar-section-advanced": "Eidiçon abançada",
+ "wikieditor-toolbar-tool-heading": "Cabeçalho",
"wikieditor-toolbar-tool-heading-1": "Nible 1",
+ "wikieditor-toolbar-tool-heading-2": "Nible 2",
+ "wikieditor-toolbar-tool-heading-3": "Nible 3",
+ "wikieditor-toolbar-tool-heading-4": "Nible 4",
+ "wikieditor-toolbar-tool-heading-5": "Nible 5",
+ "wikieditor-toolbar-tool-heading-example": "Testo de cabeçalho",
+ "wikieditor-toolbar-group-format": "Formatar",
+ "wikieditor-toolbar-tool-ulist-example": "Eilemiento de lhista cun marcas",
+ "wikieditor-toolbar-tool-nowiki-example": "Poner eiqui l testo sin formataçon",
"wikieditor-toolbar-tool-redirect-example": "Nome de la páigina de çtino",
+ "wikieditor-toolbar-tool-big-example": "Testo grande",
+ "wikieditor-toolbar-tool-small-example": "Testo pequeinho",
+ "wikieditor-toolbar-tool-superscript-example": "Testo an subrescrito",
+ "wikieditor-toolbar-tool-subscript-example": "Testo an subscrito",
+ "wikieditor-toolbar-tool-gallery-example": "Eisemplo1.jpg|Lhegenda1\nEisemplo2.jpg|Lhegenda2",
"wikieditor-toolbar-tool-table-example-old": "-\n! cabeçalho 1\n! cabeçalho 2\n! cabeçalho 3\n|-\n| lhinha 1, queluna 1\n| lhinha 1, queluna 2\n| lhinha 1, queluna 3\n|-\n| lhinha 2, queluna 1\n| lhinha 2, queluna 2\n| lhinha 2, queluna 3",
"wikieditor-toolbar-tool-table-example-cell-text": "Testo de la célula",
"wikieditor-toolbar-tool-table-example-header": "Testo de l cabeçalho",
@@ -20,8 +45,17 @@
"wikieditor-toolbar-tool-table-sortable": "Tornar la tabela ourdenable",
"wikieditor-toolbar-tool-table-example": "Eisemplo",
"wikieditor-toolbar-tool-table-insert": "Poner",
- "wikieditor-toolbar-tool-table-cancel": "Cancelar",
+ "wikieditor-toolbar-tool-table-cancel": "Çfazer",
"wikieditor-toolbar-tool-replace-nomatch": "La sue percura nun porduziu resultados.",
"wikieditor-toolbar-section-characters": "Caráteles speciales",
+ "wikieditor-toolbar-help-page-format": "Formataçon",
+ "wikieditor-toolbar-help-content-italic-syntax": "''Testo an eitálico''",
+ "wikieditor-toolbar-help-content-italic-result": "<em>Testo an eitálico</em>",
+ "wikieditor-toolbar-help-content-bold-syntax": "'''Testo a negrito'''",
+ "wikieditor-toolbar-help-content-bold-result": "<strong>Testo a negrito</strong>",
+ "wikieditor-toolbar-help-content-ulist-syntax": "* Eilemiento de lhista<br />* Eilemiento de lhista",
+ "wikieditor-toolbar-help-content-ulist-result": "<ul><li>Eilemiento de lhista</li><li>Eilemiento de lhista</li></ul>",
+ "wikieditor-toolbar-help-content-olist-syntax": "# Eilemiento de lhista<br /># Eilemiento de lhista",
+ "wikieditor-toolbar-help-content-olist-result": "<ol><li>Eilemiento de lhista</li><li>Eilemiento de lhista</li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Nome de outelizador(a)</a> (<a href='#' title='$2:Username'>cumbersa</a>) 15h54min de 10 de júnio de 2009 (UTC)"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/nah.json b/www/wiki/extensions/WikiEditor/i18n/nah.json
index 81375b9f..7fa69fe0 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nah.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nah.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Tèwàlmàktia sè mìxmankànetzòwilìxtlâtli kàmpa wìtz in wikitlâkuilòlmantli tlèn moyêyèktlàlis ìwàn kèski ìyànalòwan kàmpa mowàlnèxtia in ìntlâtlamảtilis",
"wikieditor-wikitext-tab": "Wikitlâkuilòlmantli",
"wikieditor-loading": "Tlehcoticah...",
- "wikieditor-preview-preference": "Motekitìltìs in tlanênektikàyö achtỏpaỉtalistli",
- "wikieditor-preview-tab": "Achtopaittaliztli",
- "wikieditor-preview-changes-tab": "Tlapatlaliztli",
- "wikieditor-preview-loading": "Tlehcoticah...",
- "wikieditor-publish-preference": "Motekitìltìs tlasêsêsèntèìxmảchìltìstli",
- "wikieditor-publish-button-publish": "Motèìxmảchìltìs",
- "wikieditor-publish-button-cancel": "Moxitiniz",
- "wikieditor-publish-dialog-title": "Motèìxmảchìltìs ìpan {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Ìpòpòwilis tlayèktlàlilòtl (xikỉto ìka kèski tlatòlli in tlapảtlalistli tlèn òtikchìuh):",
- "wikieditor-publish-dialog-minor": "Tepỉtzìn tlayèktlàlilòtl",
- "wikieditor-publish-dialog-watch": "Mopanỉtas inìn tlaìxtlapalli",
- "wikieditor-publish-dialog-publish": "Motèìxmảchìltìs",
- "wikieditor-publish-dialog-goback": "Ximocuepa",
"wikieditor-toolbar": "Tlayêyèktlàlilòkàtekitiâpalli",
"wikieditor-toolbar-desc": "Ìtekitiâpal in tlayêyèktlàlilòkàtlaìxtlapalli ìwàn okảchi kuâkualli tlamantli tlatekitiliskàyòtl",
"wikieditor-toolbar-preference": "Motekitìltìs in okảchi kualli tekitiâpalli tlèn ìka tlayêyèktlàlilo",
- "wikieditor-toolbar-dialogs-preference": "Motekitìltìs tlanônòtzaliskàyòtl tlèn ìnka tlatzòtzòwìltlàlilòs, tlatlapaltlàlilòs wàn oksẻki îtlàtlèn monẻkis motlàlìs",
"wikieditor-toolbar-loading": "Motlamàmaltîtỉka....",
"wikieditor-toolbar-tool-bold": "Tliltic",
"wikieditor-toolbar-tool-bold-example": "Tliltic tlahcuilolmantli",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nan.json b/www/wiki/extensions/WikiEditor/i18n/nan.json
index 2986d70e..eeeb1837 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nan.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nan.json
@@ -8,14 +8,6 @@
"wikieditor-desc": "Thê-kiong chi̍t-ê thang khok-chhiong ê wikitext pian-chi̍p kài-bin kiam chē khoán kong-lêng-sèng module",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Chài-ji̍p...",
- "wikieditor-preview-preference": "Ún-chún siang-pêng pí-tùi chhì-khòaⁿ",
- "wikieditor-preview-tab": "Chhì-khòaⁿ",
- "wikieditor-preview-changes-tab": "Kái-piàn",
- "wikieditor-preview-loading": "Chài-ji̍p...",
- "wikieditor-publish-preference": "Ún-chún chiàu kai-tōaⁿ hoat-piáu",
- "wikieditor-publish-button-publish": "Hoat-piáu",
- "wikieditor-publish-button-cancel": "Chhú-siau",
- "wikieditor-publish-dialog-title": "Hoat-piáu kòe {{SITENAME}}",
"wikieditor-toolbar-tool-redirect": "Choán-ia̍h",
"wikieditor-toolbar-tool-redirect-example": "Bo̍k-phiau-ia̍h hō-miâ",
"wikieditor-toolbar-tool-big": "Tōa",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nap.json b/www/wiki/extensions/WikiEditor/i18n/nap.json
index ea68d455..58530ae6 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nap.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nap.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Ve mettesse nu wikitesto ca se putesse spannere cagnanno interfaccia e tante module ca dipenneno 'e na funzionalità",
"wikieditor-wikitext-tab": "Wikitesto",
"wikieditor-loading": "Carecamiento 'n curso…",
- "wikieditor-preview-preference": "Premmettesse l'anteprimma affiancata a lato a lato",
- "wikieditor-preview-tab": "Anteprimma",
- "wikieditor-preview-changes-tab": "Cagnamiente",
- "wikieditor-preview-loading": "Carecamiento 'n curso…",
- "wikieditor-publish-preference": "Premmettesse 'a pubbrecazione affiancata a lato a lato...",
- "wikieditor-publish-button-publish": "Pubbreca",
- "wikieditor-publish-button-cancel": "Canciella",
- "wikieditor-publish-dialog-title": "Pubbreca su {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Riepilego 'e cagnamiente (veloce veloce descrivesse 'e cagnamiente c'avite fatto vuje):",
- "wikieditor-publish-dialog-minor": "Cagnamiento piccerillo",
- "wikieditor-publish-dialog-watch": "Tiene d'uocchio sta paggena",
- "wikieditor-publish-dialog-publish": "Pubbreca",
- "wikieditor-publish-dialog-goback": "Torna arreto",
"wikieditor-toolbar": "Barra 'e cagnamiente",
"wikieditor-toolbar-desc": "Cagna 'a paggena d' 'a barra 'e strumiente cun l'usabbilità avanzata",
"wikieditor-toolbar-preference": "Abbìa 'a barra strumiente 'e cagnamiento migliurata",
- "wikieditor-toolbar-dialogs-preference": "Premmettesse 'e guide d'azzeccà cullegamente, tabbelle e pure 'e trova-sostituisce",
"wikieditor-toolbar-loading": "Carecamiento 'n curso…",
"wikieditor-toolbar-tool-bold": "Grassetto",
"wikieditor-toolbar-tool-bold-example": "Testo 'n grassetto",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nb.json b/www/wiki/extensions/WikiEditor/i18n/nb.json
index 213120b8..eb89d3fc 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nb.json
@@ -14,26 +14,12 @@
]
},
"wikieditor": "Avansert grensesnitt for redigering av wikitekst",
- "wikieditor-desc": "Gir et utvidbart tekstredigeringsgrensesnitt og mange utvidelsesmoduler",
+ "wikieditor-desc": "Gir et avansert, utvidbart tekstredigeringsgrensesnitt",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Laster…",
- "wikieditor-preview-preference": "Aktiver forhåndsvisning side-ved-side",
- "wikieditor-preview-tab": "Forhåndsvisning",
- "wikieditor-preview-changes-tab": "Endringer",
- "wikieditor-preview-loading": "Laster…",
- "wikieditor-publish-preference": "Aktiver steg-for-steg publisering",
- "wikieditor-publish-button-publish": "Publiser",
- "wikieditor-publish-button-cancel": "Avbryt",
- "wikieditor-publish-dialog-title": "Publiser til {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Redigeringssammendrag (oppsummering av hvilke endringer du har gjort)",
- "wikieditor-publish-dialog-minor": "Mindre endring",
- "wikieditor-publish-dialog-watch": "Overvåk denne siden",
- "wikieditor-publish-dialog-publish": "Publiser",
- "wikieditor-publish-dialog-goback": "Gå tilbake",
"wikieditor-toolbar": "Verktøylinje for redigering",
"wikieditor-toolbar-desc": "Verktøylinje for redigering med utvidet brukervennlighet",
"wikieditor-toolbar-preference": "Aktiver utvidet verktøylinje for redigering",
- "wikieditor-toolbar-dialogs-preference": "Slå på veivisere for å sette inn lenker, tabeller og søk- og erstatt-funksjonen",
"wikieditor-toolbar-loading": "Laster…",
"wikieditor-toolbar-tool-bold": "Fet",
"wikieditor-toolbar-tool-bold-example": "Fet tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nds-nl.json b/www/wiki/extensions/WikiEditor/i18n/nds-nl.json
index 9ec38196..9922e816 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nds-nl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nds-nl.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Hierdeur krie'j n tekstverwarker veur wikitekste die'j uut kunnen breien en modules mit extra funksies",
"wikieditor-wikitext-tab": "Wikitekste",
"wikieditor-loading": "An t laojen...",
- "wikieditor-preview-preference": "Bewarken en naokieken naos mekaar",
- "wikieditor-preview-tab": "Naokieken",
- "wikieditor-preview-changes-tab": "Wiezigingen",
- "wikieditor-preview-loading": "An t laojen...",
- "wikieditor-publish-preference": "Stap veur stap publiseren inschakelen",
- "wikieditor-publish-button-publish": "Publiseren",
- "wikieditor-publish-button-cancel": "Aofbreken",
- "wikieditor-publish-dialog-title": "Publiseren naor {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Bewarkingssamenvatting (beschrief de wijzingen in t kort):",
- "wikieditor-publish-dialog-minor": "Kleine bewarking",
- "wikieditor-publish-dialog-watch": "Volg disse zied",
- "wikieditor-publish-dialog-publish": "Publiseren",
- "wikieditor-publish-dialog-goback": "Weerumme",
"wikieditor-toolbar": "Bewarkingswarkbalke",
"wikieditor-toolbar-desc": "Bewarkingsbalke die makkeliker te gebruken is",
"wikieditor-toolbar-preference": "De uutebreien bewarkingsbalke anzetten",
- "wikieditor-toolbar-dialogs-preference": "Dialogen inschakelen veur t plaotsen van verwiezingen, tabellen en zeuken en vervangen",
"wikieditor-toolbar-loading": "An t laojen...",
"wikieditor-toolbar-tool-bold": "Vet",
"wikieditor-toolbar-tool-bold-example": "Vet-edrokten tekste",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nds.json b/www/wiki/extensions/WikiEditor/i18n/nds.json
index 78ed5f42..216a1295 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nds.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nds.json
@@ -6,13 +6,6 @@
},
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "An’t Laden...",
- "wikieditor-preview-tab": "Vörschau",
- "wikieditor-preview-changes-tab": "Ännern",
- "wikieditor-preview-loading": "An’t Laden...",
- "wikieditor-publish-button-cancel": "Afbreken",
- "wikieditor-publish-dialog-minor": "Lütte Ännern",
- "wikieditor-publish-dialog-watch": "Op disse Siet oppassen",
- "wikieditor-publish-dialog-goback": "Torüch",
"wikieditor-toolbar-loading": "An’t Laden...",
"wikieditor-toolbar-tool-bold": "Fett",
"wikieditor-toolbar-tool-bold-example": "Fetten Text",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ne.json b/www/wiki/extensions/WikiEditor/i18n/ne.json
index d294fa84..d27546f1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ne.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ne.json
@@ -7,13 +7,6 @@
]
},
"wikieditor-loading": "लोड हुदैछ...",
- "wikieditor-preview-tab": "पूर्वावलोकन",
- "wikieditor-preview-changes-tab": "परिवर्तनहरू",
- "wikieditor-preview-loading": "लोड हुदैछ...",
- "wikieditor-publish-button-publish": "प्रकाशित गर्नुहोस",
- "wikieditor-publish-button-cancel": "रद्द गर्ने",
- "wikieditor-publish-dialog-publish": "प्रकाशित गर्नुहोस",
- "wikieditor-publish-dialog-goback": "पछाडि पर्कने",
"wikieditor-toolbar": "सम्पादन उपकरणपट्टी",
"wikieditor-toolbar-loading": "लोड हुदैछ...",
"wikieditor-toolbar-tool-bold": "गाढा",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nl-informal.json b/www/wiki/extensions/WikiEditor/i18n/nl-informal.json
index e629431e..8eed4c90 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nl-informal.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nl-informal.json
@@ -4,7 +4,6 @@
"Siebrand"
]
},
- "wikieditor-publish-dialog-summary": "Bewerkingssamenvatting (beschrijf kort de door jou gemaakte wijzingen):",
"wikieditor-toolbar-tool-link-int-invalid": "De pagina die je hebt opgegeven is ongeldig.",
"wikieditor-toolbar-tool-link-lookslikeinternal": "De URL die je hebt opgegeven lijkt bedoeld te zijn als koppeling naar een andere wikipagina.\nWil je er een interne koppeling van maken?",
"wikieditor-toolbar-tool-link-empty": "Je hebt niets opgegeven om naar te verwijzen.",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nl.json b/www/wiki/extensions/WikiEditor/i18n/nl.json
index 93067b50..bbb42f41 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nl.json
@@ -14,30 +14,17 @@
"Sjoerddebruin",
"Servien",
"Dinosaur918",
- "Mainframe98"
+ "Mainframe98",
+ "Mar(c)"
]
},
"wikieditor": "Uitgebreide tekstverwerker voor wikitekst",
- "wikieditor-desc": "Voegt een uitbreidbare tekstverwerker voor wikitekst toe en modules met extra mogelijkheden",
+ "wikieditor-desc": "Biedt een geavanceerde, uitbreidbare wikitext-bewerkingsinterface",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Bezig met laden...",
- "wikieditor-preview-preference": "Bewerken en voorvertoning naast elkaar",
- "wikieditor-preview-tab": "Voorvertoning",
- "wikieditor-preview-changes-tab": "Wijzigingen",
- "wikieditor-preview-loading": "Bezig met laden…",
- "wikieditor-publish-preference": "Stap voor stap publiceren inschakelen",
- "wikieditor-publish-button-publish": "Publiceren",
- "wikieditor-publish-button-cancel": "Annuleren",
- "wikieditor-publish-dialog-title": "Publiceren naar {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Bewerkingssamenvatting (beschrijf kort de gemaakte wijzingen):",
- "wikieditor-publish-dialog-minor": "Kleine bewerking",
- "wikieditor-publish-dialog-watch": "Deze pagina volgen",
- "wikieditor-publish-dialog-publish": "Publiceren",
- "wikieditor-publish-dialog-goback": "Terug",
"wikieditor-toolbar": "Bewerkingswerkbalk",
"wikieditor-toolbar-desc": "Bewerkingsbalk die eenvoudiger te gebruiken is",
"wikieditor-toolbar-preference": "Uitgebreide bewerkingsbalk inschakelen",
- "wikieditor-toolbar-dialogs-preference": "Dialogen inschakelen voor het toevoegen van koppelingen, tabellen, en zoeken en vervangen",
"wikieditor-toolbar-loading": "Bezig met laden…",
"wikieditor-toolbar-tool-bold": "Vet",
"wikieditor-toolbar-tool-bold-example": "Vetgedrukte tekst",
@@ -210,7 +197,7 @@
"wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Koppelingstekst</a>, extra tekst.</li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "Ondertekening met tijdstempel",
"wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Gebruikersnaam</a> (<a href='#' title='$2:Username'>overleg</a>) 15:54, 10 juni 2009 (UTC)",
- "wikieditor-toolbar-help-content-signature-description": "Ondertekening",
+ "wikieditor-toolbar-help-content-signature-description": "Handtekening",
"wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>Gebruikersnaam</a> (<a href='#' title='$2:Username'>overleg</a>)",
"wikieditor-toolbar-help-content-indent-description": "Inspringen",
"wikieditor-toolbar-help-content-indent-syntax": "Normale tekst<br />:Ingesprongen tekst<br />::Ingesprongen tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nn.json b/www/wiki/extensions/WikiEditor/i18n/nn.json
index c81a275a..91354fc3 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nn.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nn.json
@@ -12,23 +12,9 @@
"wikieditor": "Avansert grensesnitt for endring av wikitekst",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Lastar",
- "wikieditor-preview-preference": "Ta i bruk førehandsvising side-om-side",
- "wikieditor-preview-tab": "Førehandsvising",
- "wikieditor-preview-changes-tab": "Endringar",
- "wikieditor-preview-loading": "Lastar…",
- "wikieditor-publish-preference": "Ta i bruk steg for steg-publisering",
- "wikieditor-publish-button-publish": "Publiser",
- "wikieditor-publish-button-cancel": "Avbryt",
- "wikieditor-publish-dialog-title": "Publiser på {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Endringssamandrag (oppsummering av kva for endringar du har gjort):",
- "wikieditor-publish-dialog-minor": "Småplukk",
- "wikieditor-publish-dialog-watch": "Overvak sida",
- "wikieditor-publish-dialog-publish": "Publiser",
- "wikieditor-publish-dialog-goback": "Gå tilbake",
"wikieditor-toolbar": "Verktøyline for redigering",
"wikieditor-toolbar-desc": "Ei meir brukarvenleg verktøylinje for redigering",
"wikieditor-toolbar-preference": "Ta i bruk utvida verktøylinje for redigering",
- "wikieditor-toolbar-dialogs-preference": "Aktiver dialogar for insetjing av lenkjer, tabellar og søk og byt ut-funksjonen",
"wikieditor-toolbar-loading": "Lastar …",
"wikieditor-toolbar-tool-bold": "Feit",
"wikieditor-toolbar-tool-bold-example": "Feit tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/nso.json b/www/wiki/extensions/WikiEditor/i18n/nso.json
index 547fe384..57aa94fa 100644
--- a/www/wiki/extensions/WikiEditor/i18n/nso.json
+++ b/www/wiki/extensions/WikiEditor/i18n/nso.json
@@ -5,10 +5,6 @@
]
},
"wikieditor-loading": "Laiša",
- "wikieditor-preview-changes-tab": "Diphetogo",
- "wikieditor-preview-loading": "Laiša...",
- "wikieditor-publish-button-cancel": "Khansela",
- "wikieditor-publish-dialog-goback": "Boela morago",
"wikieditor-toolbar-loading": "Laiša...",
"wikieditor-toolbar-tool-xlink": "Hlomaganyo ya kantle (gopola go thoma ka http://)",
"wikieditor-toolbar-tool-link": "Hlomaganyo",
diff --git a/www/wiki/extensions/WikiEditor/i18n/oc.json b/www/wiki/extensions/WikiEditor/i18n/oc.json
index 1757d91d..627479bf 100644
--- a/www/wiki/extensions/WikiEditor/i18n/oc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/oc.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Provesís una interfàcia de modificacion de wikitèxte extensible e mantuna foncionalitats.",
"wikieditor-wikitext-tab": "Wikitèxte",
"wikieditor-loading": "Cargament",
- "wikieditor-preview-preference": "Activar la previsualizacion còsta a còsta",
- "wikieditor-preview-tab": "Previsualizacion",
- "wikieditor-preview-changes-tab": "Cambiaments",
- "wikieditor-preview-loading": "Cargament...",
- "wikieditor-publish-preference": "Activar la publicacion etapa per etapa",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Anullar",
- "wikieditor-publish-dialog-title": "Publicar sus {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resumit de modificacion (descrivètz brèvament los cambiaments qu'avètz aportats) :",
- "wikieditor-publish-dialog-minor": "Modificacion menora",
- "wikieditor-publish-dialog-watch": "Seguir aquesta pagina",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Retorn",
"wikieditor-toolbar": "Barra d’aisinas de modificacion",
"wikieditor-toolbar-desc": "Modificacion de la barra d'aisinas amb l'utilizabilitat melhorada",
"wikieditor-toolbar-preference": "Activar la barra d'aisinas melhorada",
- "wikieditor-toolbar-dialogs-preference": "Activar los assistents per apondre de ligams, de tablèus emai la foncion de recèrca e remplaçament",
"wikieditor-toolbar-loading": "Cargament ...",
"wikieditor-toolbar-tool-bold": "Gras",
"wikieditor-toolbar-tool-bold-example": "Tèxte en gras",
diff --git a/www/wiki/extensions/WikiEditor/i18n/olo.json b/www/wiki/extensions/WikiEditor/i18n/olo.json
index fbc05009..9fb1f3f9 100644
--- a/www/wiki/extensions/WikiEditor/i18n/olo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/olo.json
@@ -5,12 +5,6 @@
]
},
"wikieditor-wikitext-tab": "Wikitekstu",
- "wikieditor-publish-button-publish": "Piästä ilmah",
- "wikieditor-publish-button-cancel": "Hylgiä",
- "wikieditor-publish-dialog-minor": "Pieni kohendus",
- "wikieditor-publish-dialog-watch": "Valvo tädä sivuu",
- "wikieditor-publish-dialog-publish": "Piästä ilmah",
- "wikieditor-publish-dialog-goback": "Mene järilleh",
"wikieditor-toolbar-tool-bold": "Sangei",
"wikieditor-toolbar-tool-bold-example": "Sangei tekstu",
"wikieditor-toolbar-tool-italic": "Kursivoitu",
diff --git a/www/wiki/extensions/WikiEditor/i18n/or.json b/www/wiki/extensions/WikiEditor/i18n/or.json
index ce73a758..8db35307 100644
--- a/www/wiki/extensions/WikiEditor/i18n/or.json
+++ b/www/wiki/extensions/WikiEditor/i18n/or.json
@@ -14,23 +14,9 @@
"wikieditor-desc": "ଏକ ଉନ୍ନତ ଉଇକିଟେକ୍ସଟ ସମ୍ପାଦନା ଇଣ୍ଟରଫେସ ଓ ଅନେକ ସୁବିଧା ଯୋଗାଣକାରୀ ମଡ୍ୟୁଲ ଯୋଗାଇଥାଏ",
"wikieditor-wikitext-tab": "ଉଇକିଟେକ୍ସଟ",
"wikieditor-loading": "ଖୋଜୁଛି...",
- "wikieditor-preview-preference": "ଲଗାଲଗି ଦେଖଣା ସଚଳ କରାଇବେ",
- "wikieditor-preview-tab": "ସାଇତିବା ଆଗରୁ ଦେଖଣା",
- "wikieditor-preview-changes-tab": "ବଦଳମାନ",
- "wikieditor-preview-loading": "ଖୋଲୁଛି...",
- "wikieditor-publish-preference": "ସ୍ତର ପରେ ସ୍ତର ପ୍ରକାଶନ",
- "wikieditor-publish-button-publish": "ପ୍ରକାଶ କରିବେ",
- "wikieditor-publish-button-cancel": "ନାକଚ",
- "wikieditor-publish-dialog-title": "{{SITENAME}}ରେ ପ୍ରକାଶିତ କରିବେ",
- "wikieditor-publish-dialog-summary": "ସାରକଥା ସମ୍ପାଦନ କରିବେ (ଆପଣ କରିଥିବା ବଦଳସବୁକୁ ଅଳ୍ପରେ ବଖାଣିବେ):",
- "wikieditor-publish-dialog-minor": "ସାମାନ୍ୟ ବଦଳ",
- "wikieditor-publish-dialog-watch": "ଏହି ପୃଷ୍ଠାଟିକୁ ଦେଖିବେ",
- "wikieditor-publish-dialog-publish": "ପ୍ରକାଶ କରିବେ",
- "wikieditor-publish-dialog-goback": "ପଛକୁ ଫେରିବେ",
"wikieditor-toolbar": "ସମ୍ପାଦନା ଉପକରଣ ଟୁଲବାର",
"wikieditor-toolbar-desc": "ଅଧିକ ବ୍ୟବହାର ସୁବିଧା ସହ ପୃଷ୍ଠା ସମ୍ପାଦନା ଉପକରଣ ଟୁଲବାର",
"wikieditor-toolbar-preference": "ଉନ୍ନତ ସମ୍ପାଦନା ଉପକରଣ ଟୁଲବାର ସଚଳ କରନ୍ତୁ",
- "wikieditor-toolbar-dialogs-preference": "ଲିଙ୍କ, ସାରଣୀ (ଟେବୁଲ), ଖୋଜିବା ଓ ବଦଳାଇବା ଆଦି କାମ ପାଇଁ ଉଇଜାର୍ଡ଼ମାନ ସକ୍ରିୟ କରନ୍ତୁ",
"wikieditor-toolbar-loading": "ଖୋଲୁଅଛି...",
"wikieditor-toolbar-tool-bold": "ବୋଲ୍‌ଡ (Bold)",
"wikieditor-toolbar-tool-bold-example": "ବୋଲ୍‌ଡ (Bold) ଲେଖା",
diff --git a/www/wiki/extensions/WikiEditor/i18n/os.json b/www/wiki/extensions/WikiEditor/i18n/os.json
index 72a61a37..fb73b9c6 100644
--- a/www/wiki/extensions/WikiEditor/i18n/os.json
+++ b/www/wiki/extensions/WikiEditor/i18n/os.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Дæтты уæрæхгæнаг викитекст ивыны интерфейс æмæ бирæ фадатдæттаг модулы",
"wikieditor-wikitext-tab": "Викитекст",
"wikieditor-loading": "Æвгæд цæуы...",
- "wikieditor-preview-preference": "Фарсæй-фарсмæ разбакаст баиу кæнын",
- "wikieditor-preview-tab": "Разæркаст",
- "wikieditor-preview-changes-tab": "Ивдтытæ",
- "wikieditor-preview-loading": "Æвгæд цæуы...",
- "wikieditor-publish-preference": "Радгай рауагъд баиу кæнын",
- "wikieditor-publish-button-publish": "Рауадзын",
- "wikieditor-publish-button-cancel": "Ныууадзын",
- "wikieditor-publish-dialog-title": "{{grammar:genitive|{{SITENAME}}}} рауадзын",
- "wikieditor-publish-dialog-summary": "Ивды бындур (цыбырæй бамбарын кæн цы ивдтытæ бахастай):",
- "wikieditor-publish-dialog-minor": "Чысыл ивд",
- "wikieditor-publish-dialog-watch": "Ацы фарсмæ цæст æрдарын",
- "wikieditor-publish-dialog-publish": "Рауадзын",
- "wikieditor-publish-dialog-goback": "Фæстæмæ",
"wikieditor-toolbar": "Ивыны панель",
"wikieditor-toolbar-desc": "Æнцонгонд архайдимæ ивыны панель",
"wikieditor-toolbar-preference": "Хуыздæргонд ивыны панель баиу кæнын",
- "wikieditor-toolbar-dialogs-preference": "Æрвитæн тыссын, таблицæ æмæ æндæрты диалогтæ баиу кæнын",
"wikieditor-toolbar-loading": "Æвгæд цæуы...",
"wikieditor-toolbar-tool-bold": "Бæзджын",
"wikieditor-toolbar-tool-bold-example": "Бæзджын текст",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pa.json b/www/wiki/extensions/WikiEditor/i18n/pa.json
index d48f9450..f40b792f 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pa.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pa.json
@@ -6,18 +6,6 @@
},
"wikieditor-wikitext-tab": "ਵਿਕੀਲਿਖਤ",
"wikieditor-loading": "ਲੋਡ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ…",
- "wikieditor-preview-tab": "ਝਲਕ",
- "wikieditor-preview-changes-tab": "ਤਬਦੀਲੀਆਂ",
- "wikieditor-preview-loading": "ਲੋਡ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ...",
- "wikieditor-publish-preference": "ਕਦਮ ਦਰ ਕਦਮ ਛਾਪਾ ਚਾਲੂ ਕਰੋ",
- "wikieditor-publish-button-publish": "ਛਾਪੋ",
- "wikieditor-publish-button-cancel": "ਰੱਦ ਕਰੋ",
- "wikieditor-publish-dialog-title": "{{SITENAME}} 'ਤੇ ਛਾਪੋ",
- "wikieditor-publish-dialog-summary": "ਸੋਧ ਸਾਰ (ਆਪਣੀਆਂ ਤਬਦੀਲੀਆਂ ਦੀ ਸੰਖੇਪ ਸਾਰ ਦਿਓ):",
- "wikieditor-publish-dialog-minor": "ਛੋਟੀ ਸੋਧ",
- "wikieditor-publish-dialog-watch": "ਇਹ ਸਫ਼ਾ ਵਾਚੋ",
- "wikieditor-publish-dialog-publish": "ਛਾਪੋ",
- "wikieditor-publish-dialog-goback": "ਪਿੱਛੇ ਜਾਓ",
"wikieditor-toolbar": "ਸੰਦਬਕਸਾ ਸੋਧਿਆ ਜਾ ਰਿਹਾ ਹੈ",
"wikieditor-toolbar-loading": "ਲੋਡ ਕੀਤਾ ਜਾ ਰਿਹਾ ਹੈ…",
"wikieditor-toolbar-tool-bold": "ਮੋਟੇ ਅੱਖਰਾਂ ਵਿਚ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pdc.json b/www/wiki/extensions/WikiEditor/i18n/pdc.json
index c6e91612..5c20a217 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pdc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pdc.json
@@ -6,12 +6,6 @@
},
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Laade",
- "wikieditor-preview-tab": "Aagucke",
- "wikieditor-preview-changes-tab": "Enneringe",
- "wikieditor-preview-loading": "am laade…",
- "wikieditor-publish-dialog-minor": "Nur Gleenigkeete sinn gennert",
- "wikieditor-publish-dialog-watch": "Des Blatt watsche",
- "wikieditor-publish-dialog-goback": "Zerrick",
"wikieditor-toolbar": "Gscharr fer Enneringe",
"wikieditor-toolbar-loading": "Laade…",
"wikieditor-toolbar-tool-bold": "Fett",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pfl.json b/www/wiki/extensions/WikiEditor/i18n/pfl.json
index 3fdfde94..db694c40 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pfl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pfl.json
@@ -4,7 +4,6 @@
"Manuae"
]
},
- "wikieditor-preview-changes-tab": "Änarunge",
"wikieditor-toolbar-tool-bold": "Fedd",
"wikieditor-toolbar-tool-bold-example": "Fedde Tegschd",
"wikieditor-toolbar-tool-italic": "Schräsch",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pl.json b/www/wiki/extensions/WikiEditor/i18n/pl.json
index 0b625873..825d360e 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pl.json
@@ -15,30 +15,17 @@
"Mareklug",
"Chrumps",
"Woytecr",
- "Matma Rex"
+ "Matma Rex",
+ "Railfail536"
]
},
"wikieditor": "Zaawansowany interfejs edycji wikitekstu",
- "wikieditor-desc": "Dostarcza rozszerzalny interfejs edycji wikitekstu oraz wiele funkcji oferowane przez moduły",
+ "wikieditor-desc": "Oferuje zaawansowany, rozszerzalny interfejs edycji wikitekstu",
"wikieditor-wikitext-tab": "Wikikod",
"wikieditor-loading": "Ładowanie",
- "wikieditor-preview-preference": "Włącz sąsiadujący podgląd",
- "wikieditor-preview-tab": "Podgląd",
- "wikieditor-preview-changes-tab": "Zmiany",
- "wikieditor-preview-loading": "Wczytywanie...",
- "wikieditor-publish-preference": "Wspomaganie publikacji materiału krok po kroku",
- "wikieditor-publish-button-publish": "Opublikuj",
- "wikieditor-publish-button-cancel": "Anuluj",
- "wikieditor-publish-dialog-title": "Opublikuj w {{GRAMMAR:MS.lp|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Zmiany (krótki opis wykonanych zmian)",
- "wikieditor-publish-dialog-minor": "Drobna zmiana",
- "wikieditor-publish-dialog-watch": "Obserwuj tę stronę",
- "wikieditor-publish-dialog-publish": "Publikowanie",
- "wikieditor-publish-dialog-goback": "Wróć",
"wikieditor-toolbar": "Pasek narzędzi edycyjnych",
"wikieditor-toolbar-desc": "Ułatwiający pracę pasek narzędzi edycyjnych",
"wikieditor-toolbar-preference": "Włącz rozszerzony pasek narzędzi edycyjnych",
- "wikieditor-toolbar-dialogs-preference": "Włącz kreatory dodawania linków, tabel itp.",
"wikieditor-toolbar-loading": "Ładowanie...",
"wikieditor-toolbar-tool-bold": "Wytłuszczenie",
"wikieditor-toolbar-tool-bold-example": "Tekst tłustą czcionką",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pms.json b/www/wiki/extensions/WikiEditor/i18n/pms.json
index 8ff5b0ea..37a5efb1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pms.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pms.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "A dà n'antërfacia ëd modìfica estendìbil ëd wikitext e motobin ëd modoj ch'a dan ëd fonsionalità",
"wikieditor-wikitext-tab": "Test Wiki",
"wikieditor-loading": "Cariament",
- "wikieditor-preview-preference": "Abìlita la previsualisassion da part a part",
- "wikieditor-preview-tab": "Previsualisassion",
- "wikieditor-preview-changes-tab": "Cangiament",
- "wikieditor-preview-loading": "A caria ...",
- "wikieditor-publish-preference": "Abìlita publicassion pass për pass",
- "wikieditor-publish-button-publish": "Pùblica",
- "wikieditor-publish-button-cancel": "Scancela",
- "wikieditor-publish-dialog-title": "Pùblica dzora {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Modìfica resumé (descriv curtament ij cambi ch'it l'has fàit)",
- "wikieditor-publish-dialog-minor": "Modìfiche pì cite",
- "wikieditor-publish-dialog-watch": "Ten d'euj sta pàgina-sì",
- "wikieditor-publish-dialog-publish": "Pùblica",
- "wikieditor-publish-dialog-goback": "Torna andré",
"wikieditor-toolbar": "Bara d'utiss ëd modìfica",
"wikieditor-toolbar-desc": "Bara d'utiss ëd modìfica con dovrabilità ameliorà",
"wikieditor-toolbar-preference": "Ativé la bara d'utiss ameliorà",
- "wikieditor-toolbar-dialogs-preference": "Ativé j'assistent për gionté dle anliure, dle tàule e ëdcò la fonsion d'arserca e rampiass",
"wikieditor-toolbar-loading": "Cariament...",
"wikieditor-toolbar-tool-bold": "Grassèt",
"wikieditor-toolbar-tool-bold-example": "Test an grassèt",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pnb.json b/www/wiki/extensions/WikiEditor/i18n/pnb.json
index 32a95220..e4c87fe1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pnb.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pnb.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "وڈا ہون والا وکیٹیکسٹ ایڈیٹنگ تے موڈیولز دیو۔",
"wikieditor-wikitext-tab": "وکی ٹکسٹ",
"wikieditor-loading": "لوڈنگ",
- "wikieditor-preview-preference": "نال نال دتا وکھالہ قابل کرو۔",
- "wikieditor-preview-tab": "کچا کم وکھاؤ",
- "wikieditor-preview-changes-tab": "تبدیلیاں",
- "wikieditor-preview-loading": "لوڈنگ۔۔۔",
- "wikieditor-publish-preference": "تھوڑی تھوڑی چھپائی قابل کرو۔",
- "wikieditor-publish-button-publish": "چھاپو",
- "wikieditor-publish-button-cancel": "کینسل",
- "wikieditor-publish-dialog-title": "{{SITENAME}} تے چھاپ دیو",
- "wikieditor-publish-dialog-summary": "سمری بدلو (تھوڑے بولاں تبدیلیاں جیہڑیاں تساں کیتیاں دسو):",
- "wikieditor-publish-dialog-minor": "نکی تبدیلی",
- "wikieditor-publish-dialog-watch": "اس صفحے تے اکھ رکھو",
- "wikieditor-publish-dialog-publish": "چھاپو",
- "wikieditor-publish-dialog-goback": "واپس آؤ",
"wikieditor-toolbar": "لکھت اوزار",
"wikieditor-toolbar-desc": "اوزار پٹی چ تبدیلی ورتن کرکے کرو۔",
"wikieditor-toolbar-preference": "ودیا اوزار پٹی نوں چالو کرو۔",
- "wikieditor-toolbar-dialogs-preference": "ڈائیلاگ نوں قابل کرو جوڑ یا پعاڑے یا ہور رلان لئی۔",
"wikieditor-toolbar-loading": "لوڈنگ۔۔۔",
"wikieditor-toolbar-tool-bold": "موٹا",
"wikieditor-toolbar-tool-bold-example": "موٹی لکھائی",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ps.json b/www/wiki/extensions/WikiEditor/i18n/ps.json
index 31bef92d..a81e133a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ps.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ps.json
@@ -1,28 +1,15 @@
{
"@metadata": {
"authors": [
- "Ahmed-Najib-Biabani-Ibrahimkhel"
+ "Ahmed-Najib-Biabani-Ibrahimkhel",
+ "Baloch Khan"
]
},
"wikieditor": "د پرمختللی ويکي متن د سمون ليدنمخ",
"wikieditor-wikitext-tab": "ويکي متن",
"wikieditor-loading": "رابرسېرېږي...",
- "wikieditor-preview-preference": "څنگ په څنگ مخليدنه چارنول",
- "wikieditor-preview-tab": "مخليدنه",
- "wikieditor-preview-changes-tab": "بدلونونه",
- "wikieditor-preview-loading": "رابرسېرېږي...",
- "wikieditor-publish-preference": "گام په گام خپرېدنه چارنده کول",
- "wikieditor-publish-button-publish": "خپرول",
- "wikieditor-publish-button-cancel": "ناگارل",
- "wikieditor-publish-dialog-title": "{{SITENAME}} کې خپرول",
- "wikieditor-publish-dialog-summary": "د سمون لنډيز (په لنډه توگه د خپلو بدلونونو څرگندونه وکړۍ):",
- "wikieditor-publish-dialog-minor": "وړوکی سمون",
- "wikieditor-publish-dialog-watch": "همدا مخ کتل",
- "wikieditor-publish-dialog-publish": "خپرول",
- "wikieditor-publish-dialog-goback": "پر شا تلل",
"wikieditor-toolbar": "د سمون توکپټه",
"wikieditor-toolbar-preference": "د سمون پرمختللې اوزارپټه چارنول",
- "wikieditor-toolbar-dialogs-preference": "د تړنو، لښتيالونو د ورټومبلو، همدا شان د پلټنې او ځايناستولو لپاره کوډگران چارنول",
"wikieditor-toolbar-loading": "رابرسېرېږي...",
"wikieditor-toolbar-tool-bold": "زغرد",
"wikieditor-toolbar-tool-bold-example": "زغرد متن",
@@ -82,6 +69,7 @@
"wikieditor-toolbar-tool-ulist-example": "د گولۍ داره لړليک توکی",
"wikieditor-toolbar-tool-olist": "شمېرن لړليک",
"wikieditor-toolbar-tool-olist-example": "د گولۍ داره لړليک توکی",
+ "wikieditor-toolbar-tool-nowiki-example": "{{Wy/ps/ښه|Pagebanner default.jpg|1000px|}} '''{{Wy/ps/BASICPAGENAME}}''' د '''0000''' هيواد 1_1_1 ده، چې د 2_2_2 هيواد په 3_3_3 سيمه کې موقعیت لري.\n==مخته ولاړ سي==\n*[[Wy/ps/777|888]]\n*[[Wy/ps/777|888]]\n*[[Wy/ps/777|888]] \n==سرچینې==\n{{Wy/ps/نابشپړ}}[[Category:Wy/ps]] \n[[Category:Wy/ps/نور کار غواړي]] [[Category:Wy/ps/ښارونه]]",
"wikieditor-toolbar-tool-redirect": "مخ گرځېدنه",
"wikieditor-toolbar-tool-redirect-example": "د هدفي مخ نوم",
"wikieditor-toolbar-tool-big": "لوی",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pt-br.json b/www/wiki/extensions/WikiEditor/i18n/pt-br.json
index 8ef5025d..336c625a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pt-br.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pt-br.json
@@ -23,22 +23,9 @@
]
},
"wikieditor": "Interface avançada de edição de wikitexto",
- "wikieditor-desc": "Fornece uma interface extensível de edição de textowiki e vários módulos funcionais",
+ "wikieditor-desc": "Fornece uma interface avançada e extensível de edição de texto wiki",
"wikieditor-wikitext-tab": "Wikitexto",
"wikieditor-loading": "Carregando...",
- "wikieditor-preview-preference": "Habilitar a previsão lado-a-lado",
- "wikieditor-preview-tab": "Visualizar",
- "wikieditor-preview-changes-tab": "Mudanças",
- "wikieditor-preview-loading": "Carregando...",
- "wikieditor-publish-preference": "Ativar publicação passo-a-passo",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Cancelar",
- "wikieditor-publish-dialog-title": "Publicar na {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Sumário de edição (breve descrição das suas alterações):",
- "wikieditor-publish-dialog-minor": "Edição menor",
- "wikieditor-publish-dialog-watch": "Vigiar esta página",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Voltar",
"wikieditor-toolbar": "Barra de ferramentas de edição",
"wikieditor-toolbar-desc": "Barra de ferramentas de edição com usabilidade melhorada",
"wikieditor-toolbar-preference": "Ativar a barra de ferramentas de edição melhorada",
diff --git a/www/wiki/extensions/WikiEditor/i18n/pt.json b/www/wiki/extensions/WikiEditor/i18n/pt.json
index 68030a50..84e96d54 100644
--- a/www/wiki/extensions/WikiEditor/i18n/pt.json
+++ b/www/wiki/extensions/WikiEditor/i18n/pt.json
@@ -19,58 +19,44 @@
]
},
"wikieditor": "Interface avançada de edição de texto wiki",
- "wikieditor-desc": "Fornece uma interface extensível de edição de texto wiki e vários módulos funcionais",
- "wikieditor-wikitext-tab": "Texto Wiki",
+ "wikieditor-desc": "Fornece uma interface avançada e extensível de edição de texto wiki",
+ "wikieditor-wikitext-tab": "Texto wiki",
"wikieditor-loading": "A carregar…",
- "wikieditor-preview-preference": "Possibilitar antevisão lado a lado",
- "wikieditor-preview-tab": "Antevisão",
- "wikieditor-preview-changes-tab": "Alterações",
- "wikieditor-preview-loading": "A carregar…",
- "wikieditor-publish-preference": "Possibilitar publicação passo a passo",
- "wikieditor-publish-button-publish": "Publicar",
- "wikieditor-publish-button-cancel": "Cancelar",
- "wikieditor-publish-dialog-title": "Publicar na wiki {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Resumo de edição (breve descrição das suas alterações):",
- "wikieditor-publish-dialog-minor": "Edição menor",
- "wikieditor-publish-dialog-watch": "Vigiar esta página",
- "wikieditor-publish-dialog-publish": "Publicar",
- "wikieditor-publish-dialog-goback": "Voltar",
"wikieditor-toolbar": "Barra de ferramentas de edição",
"wikieditor-toolbar-desc": "Barra de ferramentas de edição com usabilidade melhorada",
"wikieditor-toolbar-preference": "Ativar a barra de ferramentas de edição melhorada",
- "wikieditor-toolbar-dialogs-preference": "Possibilitar diálogos de inserção de ligações, tabelas, bem como pesquisa e substituição de funções",
"wikieditor-toolbar-loading": "A carregar…",
"wikieditor-toolbar-tool-bold": "Negrito",
"wikieditor-toolbar-tool-bold-example": "Texto a negrito",
"wikieditor-toolbar-tool-italic": "Itálico",
"wikieditor-toolbar-tool-italic-example": "Texto em itálico",
- "wikieditor-toolbar-tool-ilink": "Link interno",
- "wikieditor-toolbar-tool-ilink-example": "Título do link",
- "wikieditor-toolbar-tool-xlink": "Link externo (lembre-se do prefixo http://)",
- "wikieditor-toolbar-tool-xlink-example": "http://www.example.com título do link",
- "wikieditor-toolbar-tool-link": "Link",
- "wikieditor-toolbar-tool-link-title": "Inserir um link",
+ "wikieditor-toolbar-tool-ilink": "Hiperligação interna",
+ "wikieditor-toolbar-tool-ilink-example": "Título da hiperligação",
+ "wikieditor-toolbar-tool-xlink": "Hiperligação externa (lembre-se do prefixo http://)",
+ "wikieditor-toolbar-tool-xlink-example": "http://www.example.com título da hiperligação",
+ "wikieditor-toolbar-tool-link": "Hiperligação",
+ "wikieditor-toolbar-tool-link-title": "Inserir hiperligação",
"wikieditor-toolbar-tool-link-int": "Para uma página na wiki",
"wikieditor-toolbar-tool-link-int-target": "Página ou URL de destino:",
"wikieditor-toolbar-tool-link-int-target-tooltip": "Título ou URL da página",
"wikieditor-toolbar-tool-link-int-text": "Texto a apresentar:",
"wikieditor-toolbar-tool-link-int-text-tooltip": "Introduza o texto a apresentar",
"wikieditor-toolbar-tool-link-ext": "Para uma página externa na internet",
- "wikieditor-toolbar-tool-link-ext-target": "URL do link:",
- "wikieditor-toolbar-tool-link-ext-text": "Texto do link:",
- "wikieditor-toolbar-tool-link-insert": "Inserir link",
+ "wikieditor-toolbar-tool-link-ext-target": "URL da hiperligação:",
+ "wikieditor-toolbar-tool-link-ext-text": "Texto da hiperligação:",
+ "wikieditor-toolbar-tool-link-insert": "Inserir hiperligação",
"wikieditor-toolbar-tool-link-cancel": "Cancelar",
"wikieditor-toolbar-tool-link-int-target-status-exists": "A página existe",
"wikieditor-toolbar-tool-link-int-target-status-notexists": "A página não existe",
"wikieditor-toolbar-tool-link-int-target-status-invalid": "Título inválido",
- "wikieditor-toolbar-tool-link-int-target-status-external": "Link externo",
+ "wikieditor-toolbar-tool-link-int-target-status-external": "Hiperligação externa",
"wikieditor-toolbar-tool-link-int-target-status-loading": "A verificar se a página existe...",
"wikieditor-toolbar-tool-link-int-target-status-disambig": "Página de desambiguação",
"wikieditor-toolbar-tool-link-int-invalid": "O título que especificou é inválido.",
- "wikieditor-toolbar-tool-link-lookslikeinternal": "O URL que especificou parece ser um link para outra página da wiki. Deseja torná-lo num link interno?",
- "wikieditor-toolbar-tool-link-lookslikeinternal-int": "Link interno",
- "wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Link externo",
- "wikieditor-toolbar-tool-link-empty": "Não introduziu o destino do link.",
+ "wikieditor-toolbar-tool-link-lookslikeinternal": "O URL que especificou parece ser uma hiperligação para outra página da wiki. Deseja torná-la numa hiperligação interna?",
+ "wikieditor-toolbar-tool-link-lookslikeinternal-int": "Hiperligação interna",
+ "wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Hiperligação externa",
+ "wikieditor-toolbar-tool-link-empty": "Não introduziu o destino da hiperligação.",
"wikieditor-toolbar-tool-file": "Ficheiro incorporado",
"wikieditor-toolbar-tool-file-example": "Exemplo.jpg",
"wikieditor-toolbar-tool-file-title": "Inserir ficheiro",
@@ -157,7 +143,7 @@
"wikieditor-toolbar-help-heading-syntax": "O que escreve",
"wikieditor-toolbar-help-heading-result": "Resultado",
"wikieditor-toolbar-help-page-format": "Formatação",
- "wikieditor-toolbar-help-page-link": "Links",
+ "wikieditor-toolbar-help-page-link": "Hiperligações",
"wikieditor-toolbar-help-page-heading": "Cabeçalhos",
"wikieditor-toolbar-help-page-list": "Listas",
"wikieditor-toolbar-help-page-file": "Ficheiros",
@@ -172,12 +158,12 @@
"wikieditor-toolbar-help-content-bolditalic-description": "Negrito e itálico",
"wikieditor-toolbar-help-content-bolditalic-syntax": "'''''Texto em negrito e itálico'''''",
"wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>Texto em negrito e itálico</em></strong>",
- "wikieditor-toolbar-help-content-ilink-description": "Link interno",
- "wikieditor-toolbar-help-content-ilink-syntax": "[[Título da página]]<br />[[Título da página|Texto da ligação]]",
- "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Título da página</a><br /><a href='#'>Texto da ligação</a>",
- "wikieditor-toolbar-help-content-xlink-description": "Link externo",
- "wikieditor-toolbar-help-content-xlink-syntax": "[http://www.example.org Texto do link]<br />[http://www.example.org]<br />http://www.example.org",
- "wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>Texto do link</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.example.org</a>",
+ "wikieditor-toolbar-help-content-ilink-description": "Hiperligação interna",
+ "wikieditor-toolbar-help-content-ilink-syntax": "[[Título da página]]<br />[[Título da página|Texto da hiperligação]]",
+ "wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Título da página</a><br /><a href='#'>Texto da hiperligação</a>",
+ "wikieditor-toolbar-help-content-xlink-description": "Hiperligação externa",
+ "wikieditor-toolbar-help-content-xlink-syntax": "[http://www.example.org Texto da hiperligação]<br />[http://www.example.org]<br />http://www.example.org",
+ "wikieditor-toolbar-help-content-xlink-result": "<a href='#' class='external'>Texto da hiperligação</a><br /><a href='#' class='external autonumber'>[1]</a><br /><a href='#' class='external'>http://www.example.org</a>",
"wikieditor-toolbar-help-content-heading2-description": "Subtítulo de nível 2",
"wikieditor-toolbar-help-content-heading2-syntax": "== Subtítulo ==",
"wikieditor-toolbar-help-content-heading2-result": "<h2>Subtítulo</h2>",
@@ -200,15 +186,15 @@
"wikieditor-toolbar-help-content-file-syntax": "[[$1:Exemplo.png|$2|$3]]",
"wikieditor-toolbar-help-content-file-caption": "Texto da legenda",
"wikieditor-toolbar-help-content-reference-description": "Referência",
- "wikieditor-toolbar-help-content-reference-syntax": "Texto da página.&lt;ref&gt;[http://www.exemplo.org Texto do link], texto adicional.&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-reference-syntax": "Texto da página.&lt;ref&gt;[http://www.exemplo.org Texto da hiperligação], texto adicional.&lt;/ref&gt;",
"wikieditor-toolbar-help-content-reference-result": "Texto da página.<sup><a href='#'>[1]</a></sup>",
"wikieditor-toolbar-help-content-named-reference-description": "Referência nomeada",
- "wikieditor-toolbar-help-content-named-reference-syntax": "Texto da página.&lt;ref name=\"test\"&gt;[http://www.example.org Link text]&lt;/ref&gt;",
+ "wikieditor-toolbar-help-content-named-reference-syntax": "Texto da página.&lt;ref name=\"test\"&gt;[http://www.example.org Texto da hiperligação]&lt;/ref&gt;",
"wikieditor-toolbar-help-content-named-reference-result": "Texto da página.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-rereference-description": "Reutilização da mesma referência",
"wikieditor-toolbar-help-content-rereference-result": "Texto da página.<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "Mostrar referências",
- "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><a title='' href='#'><b>^</b></a> <a rel='nofollow' title=\"http://www.example.org\" class='external text' href='#'>Texto da ligação</a>, texto adicional.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Texto da ligação</a></li></ol>",
+ "wikieditor-toolbar-help-content-showreferences-result": "<ol class='references'><li id='cite_note-test-0'><a title='' href='#'><b>^</b></a> <a rel='nofollow' title=\"http://www.example.org\" class='external text' href='#'>Texto da hiperligação</a>, texto adicional.</li><li id='cite_note-test-1'><b><a title='' href='#'>^</a></b> <a rel='nofollow' title='http://www.example.org' class='external text' href='#'>Texto da hiperligação</a></li></ol>",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "Assinatura com data e hora",
"wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>Nome de utilizador</a> (<a href='#' title='$2:Username'>discussão</a>) 15h54min de 10 de junho de 2009 (UTC)",
"wikieditor-toolbar-help-content-signature-description": "Assinatura",
diff --git a/www/wiki/extensions/WikiEditor/i18n/qqq.json b/www/wiki/extensions/WikiEditor/i18n/qqq.json
index 401ed693..ab7b7396 100644
--- a/www/wiki/extensions/WikiEditor/i18n/qqq.json
+++ b/www/wiki/extensions/WikiEditor/i18n/qqq.json
@@ -25,26 +25,15 @@
"Macofe",
"Totosunarto",
"Robby",
- "Quiddity"
+ "Quiddity",
+ "Alifakoor",
+ "Acamicamacaraca"
]
},
- "wikieditor": "An extension to allow for advanced editing features.\nhttps://www.mediawiki.org/wiki/Extension:WikiEditor",
- "wikieditor-desc": "{{desc|name=Wiki Editor|url=https://www.mediawiki.org/wiki/Extension:WikiEditor}}\nI guess that \"feature-providing modules\" means the same as \"modules providing features\".",
- "wikieditor-wikitext-tab": "Caption of the tab containing the edit box",
+ "wikieditor": "An extension to provide an advanced, extensible wikitext editing interface.\nhttps://www.mediawiki.org/wiki/Extension:WikiEditor",
+ "wikieditor-desc": "Sorry, the documentation apears out of date:\n\n\n{{desc|name=WikiEditor|url=https://www.mediawiki.org/wiki/Extension:WikiEditor}}",
+ "wikieditor-wikitext-tab": "Caption of the tab containing the edit box\n{{Identical|Wikitext}}",
"wikieditor-loading": "Explanatory text for the temporary cover placed over the wikieditor while it's being assembled.\n{{Identical|Loading}}",
- "wikieditor-preview-preference": "Option in [[Special:Preferences]], tab ''{{int:prefs-editing}}''",
- "wikieditor-preview-tab": "Caption of the tab containing the preview\n\n{{Identical|Preview}}",
- "wikieditor-preview-changes-tab": "Caption of the tab containing a diff of the user's changes, à la ''{{int:Showdiff}}'' ({{msg-mw|Showdiff|notext=1}}).\n\n{{Identical|Change}}",
- "wikieditor-preview-loading": "Alt text for spinner displayed while preview is being loaded\n{{Identical|Loading}}",
- "wikieditor-publish-preference": "Option in [[Special:Preferences]], tab ''{{int:prefs-editing}}''",
- "wikieditor-publish-button-publish": "Button to the right of the Edit/Preview tabs that opens a dialog window that lets the user save their edit\n\n{{Identical|Publish}}",
- "wikieditor-publish-button-cancel": "Button to the right of the Edit/Preview tabs that has the same effect as the {{msg-mw|Cancel}} link below the edit box.\n\n{{Identical|Cancel}}",
- "wikieditor-publish-dialog-title": "Title of the dialog that opens when the user clicks the Publish button",
- "wikieditor-publish-dialog-summary": "Label for the edit summary textbox in the dialog that opens when the user clicks the Publish button. See also {{msg-mw|Summary}}.",
- "wikieditor-publish-dialog-minor": "Label for the minor edit checkbox in the dialog that opens when the user clicks the Publish button.\n\nSee also:\n* {{msg-mw|Minoredit}}\n{{Identical|Minor edit}}",
- "wikieditor-publish-dialog-watch": "Label for the watch checkbox in the dialog that opens when the user clicks the Publish button\n\n{{Identical|Watch this page}}",
- "wikieditor-publish-dialog-publish": "Button that saves the user's edit in the dialog that opens when the user clicks the Publish button\n\n{{Identical|Publish}}",
- "wikieditor-publish-dialog-goback": "Button that closes the dialog that opens when the user clicks the Publish button.\n{{Identical|Go back}}",
"wikieditor-toolbar": "A customizable toolbar for the WikiEditor.\nFor more information, see https://www.mediawiki.org/wiki/Extension:WikiEditor/Toolbar_customization",
"wikieditor-toolbar-desc": "Unused at this time.",
"wikieditor-toolbar-preference": "Option in [[Special:Preferences]]",
@@ -81,7 +70,7 @@
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "{{Identical|External link}}",
"wikieditor-toolbar-tool-link-empty": "Used in the link dialog of the toolbar as hint after clicking the insert button",
"wikieditor-toolbar-tool-file": "{{Identical|Embedded file}}",
- "wikieditor-toolbar-tool-file-example": "{{Identical|Example}}",
+ "wikieditor-toolbar-tool-file-example": "Translate Example, but don't translate .jpg\n{{Identical|Example}}",
"wikieditor-toolbar-tool-file-title": "Title for insert file dialog",
"wikieditor-toolbar-file-target": "Label for the input of filename on insert file dialog.\n{{Identical|Filename}}",
"wikieditor-toolbar-file-caption": "Label for input of caption on insert file dialog\n\n{{Identical|Caption}}",
diff --git a/www/wiki/extensions/WikiEditor/i18n/qu.json b/www/wiki/extensions/WikiEditor/i18n/qu.json
index 7df416bc..012c2801 100644
--- a/www/wiki/extensions/WikiEditor/i18n/qu.json
+++ b/www/wiki/extensions/WikiEditor/i18n/qu.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Mast'arinalla wiki qillqa llamk'apuna uyapurata achka yanapaykuq llamk'anachakunatapas haywan",
"wikieditor-wikitext-tab": "Wiki qillqa",
"wikieditor-loading": "Chaqnamuspa",
- "wikieditor-preview-preference": "Chiqa-chiqallan ñawpaq qhawayta atichiy",
- "wikieditor-preview-tab": "Ñawpaqta qhawallay",
- "wikieditor-preview-changes-tab": "Hukchasqakuna",
- "wikieditor-preview-loading": "Chaqnamuspa…",
- "wikieditor-publish-preference": "Thatki-thatkilla uyaychayta atichiy",
- "wikieditor-publish-button-publish": "Uyaychay",
- "wikieditor-publish-button-cancel": "Ama niy",
- "wikieditor-publish-dialog-title": "{{SITENAME}} nisqapi uyaychay",
- "wikieditor-publish-dialog-summary": "Llamk'apuypa pisichaynin (rurasqayki hukchasqakunata pisilla rimakunawan ch'uyanchay):",
- "wikieditor-publish-dialog-minor": "Aslla hukchay",
- "wikieditor-publish-dialog-watch": "Kay p'anqata watiqay",
- "wikieditor-publish-dialog-publish": "Uyaychay",
- "wikieditor-publish-dialog-goback": "Kutimuy",
"wikieditor-toolbar": "Llamk'apunapaq butunnintin uma siq'i",
"wikieditor-toolbar-desc": "Kallpachasqa llamk'apunapaq butunnintin uma siq'i",
"wikieditor-toolbar-preference": "Kallpachasqa llamk'apunapaq butunnintin uma siq'ita atichiy",
- "wikieditor-toolbar-dialogs-preference": "T'inkikunata, wachuchasqakunata sat'inapaq, maskanapaq huknachanapaqpas layqakunata atichiy",
"wikieditor-toolbar-loading": "Chaqnamuspa…",
"wikieditor-toolbar-tool-bold": "Yanasapa",
"wikieditor-toolbar-tool-bold-example": "Yanasapa qillqa",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ro.json b/www/wiki/extensions/WikiEditor/i18n/ro.json
index 6d0a4854..d3048713 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ro.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ro.json
@@ -7,30 +7,17 @@
"Minisarm",
"Stelistcristi",
"Macofe",
- "Wintereu"
+ "Wintereu",
+ "Strainu"
]
},
"wikieditor": "Interfață de modificare wikitext avansată",
- "wikieditor-desc": "Afișează o interfață de modificare a wikitextului ce se poate extinde cu multe funcționalități",
+ "wikieditor-desc": "Afișează o interfață avansată de modificare a wikitextului ce poate fi extinsă",
"wikieditor-wikitext-tab": "Text wiki",
"wikieditor-loading": "Se încarcă...",
- "wikieditor-preview-preference": "Activează previzualizarea unul-lângă-altul",
- "wikieditor-preview-tab": "Previzualizare",
- "wikieditor-preview-changes-tab": "Modificări",
- "wikieditor-preview-loading": "Se încarcă...",
- "wikieditor-publish-preference": "Activează publicarea pas cu pas",
- "wikieditor-publish-button-publish": "Salvează pagina",
- "wikieditor-publish-button-cancel": "Renunță",
- "wikieditor-publish-dialog-title": "Publică pe {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Descrierea modificărilor (descrieți pe scurt modificările făcute):",
- "wikieditor-publish-dialog-minor": "Modificare minoră",
- "wikieditor-publish-dialog-watch": "Urmărește această pagină",
- "wikieditor-publish-dialog-publish": "Salvează pagina",
- "wikieditor-publish-dialog-goback": "Înapoi",
"wikieditor-toolbar": "Modificarea barei de instrumente",
"wikieditor-toolbar-desc": "Modificarea barei de instrumente cu utilizare ridicată",
"wikieditor-toolbar-preference": "Activează varianta îmbunătățită a barei de unelte",
- "wikieditor-toolbar-dialogs-preference": "Activează asistență pentru inserarea legăturilor, tabelelor, precum și pentru funcțiile de căutare și înlocuire",
"wikieditor-toolbar-loading": "Se încarcă...",
"wikieditor-toolbar-tool-bold": "Aldin",
"wikieditor-toolbar-tool-bold-example": "Text aldin",
diff --git a/www/wiki/extensions/WikiEditor/i18n/roa-tara.json b/www/wiki/extensions/WikiEditor/i18n/roa-tara.json
index 2332f4c1..731b5634 100644
--- a/www/wiki/extensions/WikiEditor/i18n/roa-tara.json
+++ b/www/wiki/extensions/WikiEditor/i18n/roa-tara.json
@@ -6,26 +6,12 @@
]
},
"wikieditor": "Wikitext avanzate pe le cangiaminde de l'inderfacce",
- "wikieditor-desc": "Dè 'nu wikitext estendibbele pe le cangiaminde de l'inderfacce e 'nu sbuenne de funzionalità de cchiù previste sus a le module",
+ "wikieditor-desc": "Dèje 'n'inderfaccia de cangiaminde avanzate d'u uicchiteste estendibbele",
"wikieditor-wikitext-tab": "Uicchiteste",
"wikieditor-loading": "Stoche a careche",
- "wikieditor-preview-preference": "Abbilite l'andeprime da na vanne a l'otre",
- "wikieditor-preview-tab": "Andeprime",
- "wikieditor-preview-changes-tab": "Cangiaminde",
- "wikieditor-preview-loading": "Carecamende...",
- "wikieditor-publish-preference": "Abbilete 'a pubblecazione passe pe passe",
- "wikieditor-publish-button-publish": "Pubbleche",
- "wikieditor-publish-button-cancel": "Annulle",
- "wikieditor-publish-dialog-title": "Pubbleche sus a {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Riepileghe de le cangiaminde (veloce veloce descrive le cangiaminde ca tu è fatte):",
- "wikieditor-publish-dialog-minor": "Cangiamende stuèdeche",
- "wikieditor-publish-dialog-watch": "Condrolle sta pàgene",
- "wikieditor-publish-dialog-publish": "Pubbleche",
- "wikieditor-publish-dialog-goback": "Tuèrne rrete",
"wikieditor-toolbar": "Barre de le cangiaminde",
"wikieditor-toolbar-desc": "Cange 'a pàgene d'a barre de le struminde cu l'usabbilità avanzate",
"wikieditor-toolbar-preference": "Abbilite 'a barre de le struminde pe le cangiaminde avanzate",
- "wikieditor-toolbar-dialogs-preference": "Abbilite le procedure guidate pe l'inzerimende de collegaminde, tabbelle e otre cose pa funzione de ricerche e sostituzione",
"wikieditor-toolbar-loading": "Stoche a careche…",
"wikieditor-toolbar-tool-bold": "Grascette",
"wikieditor-toolbar-tool-bold-example": "Teste grascette",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ru.json b/www/wiki/extensions/WikiEditor/i18n/ru.json
index dc64202e..77e114e1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ru.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ru.json
@@ -18,30 +18,17 @@
"Amire80",
"Sealle",
"Jack who built the house",
- "Mailman"
+ "Mailman",
+ "Smigles"
]
},
"wikieditor": "Расширенный интерфейс редактирования викитекста",
"wikieditor-desc": "Обеспечивает расширяемый интерфейс редактирования викитекста и многие функции, предоставляемые модулями",
- "wikieditor-wikitext-tab": "Викитекст",
+ "wikieditor-wikitext-tab": "Вики-текст",
"wikieditor-loading": "Загрузка",
- "wikieditor-preview-preference": "Включить предпросмотр «бок о бок»",
- "wikieditor-preview-tab": "Предпросмотр",
- "wikieditor-preview-changes-tab": "Изменения",
- "wikieditor-preview-loading": "Загрузка…",
- "wikieditor-publish-preference": "Включить пошаговую публикацию",
- "wikieditor-publish-button-publish": "Опубликовать",
- "wikieditor-publish-button-cancel": "Отмена",
- "wikieditor-publish-dialog-title": "Публикация в проекте {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Описание изменений (кратко укажите какие изменения были произведены):",
- "wikieditor-publish-dialog-minor": "Малое изменение",
- "wikieditor-publish-dialog-watch": "Наблюдать за этой страницей",
- "wikieditor-publish-dialog-publish": "Опубликовать",
- "wikieditor-publish-dialog-goback": "Назад",
"wikieditor-toolbar": "Панель редактирования",
"wikieditor-toolbar-desc": "Панель редактирования, более удобная в использовании",
"wikieditor-toolbar-preference": "Включить улучшенную панель редактирования",
- "wikieditor-toolbar-dialogs-preference": "Включить мастера для вставки ссылок, таблиц, а также функции вставки и замены",
"wikieditor-toolbar-loading": "Загрузка…",
"wikieditor-toolbar-tool-bold": "Полужирный",
"wikieditor-toolbar-tool-bold-example": "Полужирное начертание",
diff --git a/www/wiki/extensions/WikiEditor/i18n/rue.json b/www/wiki/extensions/WikiEditor/i18n/rue.json
index 8ca45e63..a8bdd0ff 100644
--- a/www/wiki/extensions/WikiEditor/i18n/rue.json
+++ b/www/wiki/extensions/WikiEditor/i18n/rue.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Забезпечує росшырительный інтерфейс едітованя вікітексту з богато функціоналныма модулами",
"wikieditor-wikitext-tab": "Вікітекст",
"wikieditor-loading": "Награває ся",
- "wikieditor-preview-preference": "Запнути нагляды в панелї",
- "wikieditor-preview-tab": "Нагляд",
- "wikieditor-preview-changes-tab": "Зміны",
- "wikieditor-preview-loading": "Награваня...",
- "wikieditor-publish-preference": "Запнути кроковане публікованя",
- "wikieditor-publish-button-publish": "Публіковати",
- "wikieditor-publish-button-cancel": "Сторно",
- "wikieditor-publish-dialog-title": "Публіковати на {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Опис едітованя (короткый опис змін, зробленых вами):",
- "wikieditor-publish-dialog-minor": "Мала едітація",
- "wikieditor-publish-dialog-watch": "Слїдовати тоту сторінку",
- "wikieditor-publish-dialog-publish": "Публіковати",
- "wikieditor-publish-dialog-goback": "Назад",
"wikieditor-toolbar": "Едітачный панел інштрументів",
"wikieditor-toolbar-desc": "Едітачный панел інштрументів з вылїпшенов хосновательностёв",
"wikieditor-toolbar-preference": "Запнути вылїпшеный панел інштрументів",
- "wikieditor-toolbar-dialogs-preference": "Поволити діалоґы про вкладаня одказів, таблиць ітд.",
"wikieditor-toolbar-loading": "Награваня...",
"wikieditor-toolbar-tool-bold": "Тучне",
"wikieditor-toolbar-tool-bold-example": "Тучный текст",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sa.json b/www/wiki/extensions/WikiEditor/i18n/sa.json
index ae8adba2..d319a470 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sa.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sa.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "मध्यस्थसम्पादनयोग्यं विस्तारशीलं विकिपाठ्यांशं विविधानुकूलकारिणः विभागान् च प्रददाति",
"wikieditor-wikitext-tab": "विकिपाठः",
"wikieditor-loading": "आरोपयति...",
- "wikieditor-preview-preference": "पक्षशः प्राग्दृश्यं सक्षमं क्रियताम्",
- "wikieditor-preview-tab": "प्राग्दृश्यम्",
- "wikieditor-preview-changes-tab": "परिवर्तनानि",
- "wikieditor-preview-loading": "आरोपयति.....",
- "wikieditor-publish-preference": "सोपानशः प्रकाशनं सक्षमं क्रियताम्",
- "wikieditor-publish-button-publish": "प्रकाश्यताम्",
- "wikieditor-publish-button-cancel": "निरस्यताम्",
- "wikieditor-publish-dialog-title": "{{SITENAME}} इत्येतत् प्रकाश्यताम्",
- "wikieditor-publish-dialog-summary": "सारः सम्पाद्यताम् (भवता कृतानि परिवर्तनानि संक्षेपेण विव्रियताम्) :",
- "wikieditor-publish-dialog-minor": "लघु सम्पादनम्",
- "wikieditor-publish-dialog-watch": "इदं पृष्ठं निरीक्षताम्",
- "wikieditor-publish-dialog-publish": "प्रकाश्यताम्",
- "wikieditor-publish-dialog-goback": "प्रतिगम्यताम्",
"wikieditor-toolbar": "उपकरणपेटिका सम्पाद्यताम्",
"wikieditor-toolbar-desc": "विवृद्धोपयोगयुक्तम् उपकरणपेटिकापृष्ठं सम्पाद्यताम्",
"wikieditor-toolbar-preference": "विवृद्धोपकरणपेटिकायाः सम्पादनं सक्रियं क्रियताम्",
- "wikieditor-toolbar-dialogs-preference": "अनुबन्धकोष्टकादीनां समायोजनाय सम्भाषणं सक्रियं करोतु",
"wikieditor-toolbar-loading": "आरोपयति.....",
"wikieditor-toolbar-tool-bold": "स्थूलक्षरम्",
"wikieditor-toolbar-tool-bold-example": "स्थूलाक्षरैः युक्तः भागः",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sah.json b/www/wiki/extensions/WikiEditor/i18n/sah.json
index 85a09d44..365998db 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sah.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sah.json
@@ -10,19 +10,6 @@
"wikieditor-desc": "Биики тиэкис кэҥэтиллэр интерфейсын уонна модуллар көмөлөрүнэн атын кыахтары хааччыйар",
"wikieditor-wikitext-tab": "Биики тиэкис",
"wikieditor-loading": "Хачайдааһын",
- "wikieditor-preview-preference": "Инники көрүүнү сэргэстэһиннэрэ көрдөр",
- "wikieditor-preview-tab": "Холоон көрүү",
- "wikieditor-preview-changes-tab": "Уларыйыылар",
- "wikieditor-preview-loading": "Хачайдана турар...",
- "wikieditor-publish-preference": "Биирдии хаамыынан бэчээккэ таһаарыыны холбоо",
- "wikieditor-publish-button-publish": "Бэчээккэ таһаарарга",
- "wikieditor-publish-button-cancel": "Төнүн",
- "wikieditor-publish-dialog-title": "{{SITENAME}} бырайыакка бэчээттэммит",
- "wikieditor-publish-dialog-summary": "Уларытыы туһунан (тугу уларыппыккын кылгастык кэпсээ):",
- "wikieditor-publish-dialog-minor": "Кыра суолталаах уларытыы",
- "wikieditor-publish-dialog-watch": "Бу сирэйи кэтииргэ",
- "wikieditor-publish-dialog-publish": "Бэчээттииргэ",
- "wikieditor-publish-dialog-goback": "Төнүн",
"wikieditor-toolbar": "Көннөрүү хаптаһына (панель)",
"wikieditor-toolbar-desc": "Тупсарыллыбыт уларытыы хаптаһына",
"wikieditor-toolbar-preference": "Тупсарыллыбыт уларытыы хаптаһынын холбуурга",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sat.json b/www/wiki/extensions/WikiEditor/i18n/sat.json
new file mode 100644
index 00000000..534eff54
--- /dev/null
+++ b/www/wiki/extensions/WikiEditor/i18n/sat.json
@@ -0,0 +1,11 @@
+{
+ "@metadata": {
+ "authors": [
+ "Ramjit Tudu"
+ ]
+ },
+ "wikieditor-toolbar-tool-file": "ᱛᱚᱯᱟᱦᱟᱜ ᱨᱮᱫ",
+ "wikieditor-toolbar-tool-file-title": "ᱨᱮᱫ ᱟᱫᱮᱨ",
+ "wikieditor-toolbar-help-page-file": "ᱨᱮᱫᱠᱚ",
+ "wikieditor-toolbar-help-content-file-description": "ᱛᱚᱯᱟᱦᱟᱜ ᱨᱮᱫ"
+}
diff --git a/www/wiki/extensions/WikiEditor/i18n/sc.json b/www/wiki/extensions/WikiEditor/i18n/sc.json
index f09addcd..c7cc767c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sc.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sc.json
@@ -7,17 +7,9 @@
]
},
"wikieditor-loading": "Carrigamentu",
- "wikieditor-preview-preference": "Abilita s'antiprima cumparativa",
- "wikieditor-preview-tab": "Antiprima",
- "wikieditor-preview-changes-tab": "Mudàntzias",
- "wikieditor-preview-loading": "Carrigamentu...",
- "wikieditor-publish-button-publish": "Pùblica",
- "wikieditor-publish-dialog-minor": "Modìfica minore",
- "wikieditor-publish-dialog-watch": "Pone custa pàgina in sa watchlist mea",
"wikieditor-toolbar": "Barra de is ainas pro ssu càmbiu",
"wikieditor-toolbar-desc": "Barra de is ainas pro sa modìfica megiorada",
"wikieditor-toolbar-preference": "Abilita sa barra de is ainas megiorada",
- "wikieditor-toolbar-dialogs-preference": "Abìlita s'assistimentu pro insertare ligòngios, tabellas e sa funtzione de chirca e remplasa",
"wikieditor-toolbar-loading": "Carrigamentu...",
"wikieditor-toolbar-tool-bold": "Grassu",
"wikieditor-toolbar-tool-bold-example": "Testu grassu",
diff --git a/www/wiki/extensions/WikiEditor/i18n/scn.json b/www/wiki/extensions/WikiEditor/i18n/scn.json
index 4f812fe8..f3e7688c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/scn.json
+++ b/www/wiki/extensions/WikiEditor/i18n/scn.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Duna na ntirfazza di canci dû testu wiki ca si pò stènniri e assai àutri môduli ca dùnanu àutri funziunalità",
"wikieditor-wikitext-tab": "testu wiki",
"wikieditor-loading": "Caricamentu",
- "wikieditor-preview-preference": "Abbilita antiprima latirali",
- "wikieditor-preview-tab": "Antiprima",
- "wikieditor-preview-changes-tab": "Canci",
- "wikieditor-preview-loading": "Caricamentu...",
- "wikieditor-publish-preference": "Abbilita pubblicazzioni passu doppu passu",
- "wikieditor-publish-button-publish": "Pubblica",
- "wikieditor-publish-button-cancel": "Annulla",
- "wikieditor-publish-dialog-title": "Pubblica supra {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Riassuntu dî canci (scrivi chiddu ca fa facisti)",
- "wikieditor-publish-dialog-minor": "Canci di mpurtanza nica",
- "wikieditor-publish-dialog-watch": "Talìa sta pàggina",
- "wikieditor-publish-dialog-publish": "Pubblica",
- "wikieditor-publish-dialog-goback": "Narreri",
"wikieditor-toolbar": "Barra dî strummenta di canci",
"wikieditor-toolbar-desc": "Barra dî strummenta di canci dâ pàggina cu na megghiu usabbilità",
"wikieditor-toolbar-preference": "Abbilita la barra avanzata dî strummenta di canci",
- "wikieditor-toolbar-dialogs-preference": "Attiva li pruciduri guidati pi nziriri liami e tabbelli e pâ funzioni di arricerca e rimpiazzu",
"wikieditor-toolbar-loading": "Caricamentu in corsu...",
"wikieditor-toolbar-tool-bold": "Grassettu",
"wikieditor-toolbar-tool-bold-example": "Testu in grassettu",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sd.json b/www/wiki/extensions/WikiEditor/i18n/sd.json
index 69646b7b..2c8d9596 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sd.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sd.json
@@ -5,7 +5,6 @@
"Indus Asia"
]
},
- "wikieditor-publish-button-cancel": "رد",
"wikieditor-toolbar-tool-bold": "گھري",
"wikieditor-toolbar-tool-bold-example": "گھري لکت",
"wikieditor-toolbar-tool-italic": "ٽيڏي",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sh.json b/www/wiki/extensions/WikiEditor/i18n/sh.json
index a27d83b4..cf880b6a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sh.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sh.json
@@ -5,8 +5,6 @@
"Srdjan m"
]
},
- "wikieditor-preview-tab": "Pregled",
- "wikieditor-publish-button-cancel": "Otkaži",
"wikieditor-toolbar-tool-bold": "Podebljano",
"wikieditor-toolbar-tool-italic": "Ukošeno",
"wikieditor-toolbar-tool-link-cancel": "Otkaži",
diff --git a/www/wiki/extensions/WikiEditor/i18n/si.json b/www/wiki/extensions/WikiEditor/i18n/si.json
index 2eec7503..ceca5237 100644
--- a/www/wiki/extensions/WikiEditor/i18n/si.json
+++ b/www/wiki/extensions/WikiEditor/i18n/si.json
@@ -16,23 +16,9 @@
"wikieditor-desc": "විස්තීරණය කළ හැකි විකිපෙළ සංස්කරණය කිරීමේ අතුරු මුහුණතක් හා බොහෝ විශේෂාංග-ලබාදෙන මොඩියුල සපයයි",
"wikieditor-wikitext-tab": "විකි පෙළ",
"wikieditor-loading": "ප්‍රවේශනය වෙමින් පවතී",
- "wikieditor-preview-preference": "දෙපසින්වූ පූර්ව දර්ශනය සක්‍රීය කරයි",
- "wikieditor-preview-tab": "පෙර දසුන",
- "wikieditor-preview-changes-tab": "වෙනස් කිරීම්",
- "wikieditor-preview-loading": "ප්‍රවේශනය වෙමින් පවතී...",
- "wikieditor-publish-preference": "පියවරෙන්-පියවර ප්‍රකාශනය කළ හැකියි",
- "wikieditor-publish-button-publish": "ප්‍රකාශයට පත්කරන්න",
- "wikieditor-publish-button-cancel": "අත් හරින්න",
- "wikieditor-publish-dialog-title": "{{SITENAME}} ට ප්‍රකාශනය කරන්න",
- "wikieditor-publish-dialog-summary": "සාරාංශය සංස්කරණය කරන්න (ඔබ සිදු කළ වෙනස්කම් කෙටියෙන් විස්තර කරන්න):",
- "wikieditor-publish-dialog-minor": "සුළු සංස්කරණය",
- "wikieditor-publish-dialog-watch": "මෙම පිටුව මුර කරන්න",
- "wikieditor-publish-dialog-publish": "ප්‍රකාශයට පත්කරන්න",
- "wikieditor-publish-dialog-goback": "ආපසු යන්න",
"wikieditor-toolbar": "සංස්කරණ මෙවලම් තීරුව",
"wikieditor-toolbar-desc": "වර්ධිත පරිශීලන හැකියාව සහිත සංස්කරණ පිටු මෙවලම් තීරුව",
"wikieditor-toolbar-preference": "වර්ධිත මෙවලම් තීරුව සක්‍රීය කරන්න",
- "wikieditor-toolbar-dialogs-preference": "දියුණු කළ විකි පෙළක් ඇතුල් කිරීම ස‍ඳහා උදව් සක්‍රීය කරන්න",
"wikieditor-toolbar-loading": "ප්‍රවේශනය වෙමින් පවතී...",
"wikieditor-toolbar-tool-bold": "තද පැහැ අකුරු",
"wikieditor-toolbar-tool-bold-example": "තද පැහැති අකුරු පෙළ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sk.json b/www/wiki/extensions/WikiEditor/i18n/sk.json
index 29b911c1..4ca031c6 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sk.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sk.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Poskytuje rozšíriteľné rozhranie na úpravu wikitextu a mnohé moduly poskytujúce funkcionalitu",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Načítava sa",
- "wikieditor-preview-preference": "Zapnúť náhľad vedľa úprav",
- "wikieditor-preview-tab": "Náhľad",
- "wikieditor-preview-changes-tab": "Zmeny",
- "wikieditor-preview-loading": "Načítava sa...",
- "wikieditor-publish-preference": "Zapnúť publikovanie krok za krokom",
- "wikieditor-publish-button-publish": "Publikovať",
- "wikieditor-publish-button-cancel": "Zrušiť",
- "wikieditor-publish-dialog-title": "Publikovať na {{GRAMMAR:lokál|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Zhrnutie úprav (stručný popis zmien, ktoré ste vykonali):",
- "wikieditor-publish-dialog-minor": "Drobná úprava",
- "wikieditor-publish-dialog-watch": "Sledovať túto stránku",
- "wikieditor-publish-dialog-publish": "Zverejniť",
- "wikieditor-publish-dialog-goback": "Prejsť späť",
"wikieditor-toolbar": "Panel nástrojov na úpravy",
"wikieditor-toolbar-desc": "Panel nástrojov na úpravy stránky s rozšírenou použiteľnosťou",
"wikieditor-toolbar-preference": "Zapnúť rozšírený panel nástrojov na úpravy",
- "wikieditor-toolbar-dialogs-preference": "Povoliť dialógy na vkladanie odkazov, tabuliek atď.",
"wikieditor-toolbar-loading": "Načítava sa...",
"wikieditor-toolbar-tool-bold": "Hrubý",
"wikieditor-toolbar-tool-bold-example": "Hrubý text",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sl.json b/www/wiki/extensions/WikiEditor/i18n/sl.json
index d171710e..01e61dfc 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sl.json
@@ -3,30 +3,17 @@
"authors": [
"Dbc334",
"Eleassar",
- "Yerpo"
+ "Yerpo",
+ "Janezdrilc"
]
},
"wikieditor": "Napredni vmesnik za urejanje wikibesedila",
- "wikieditor-desc": "Nudi razširjen vmesnik za urejanje wikibesedila in mnogo modulov z dodatnimi funkcijami",
+ "wikieditor-desc": "Nudi napreden, razširljiv vmesnik za urejanje wikibesedila",
"wikieditor-wikitext-tab": "Wikibesedilo",
"wikieditor-loading": "Nalaganje",
- "wikieditor-preview-preference": "Omogoči vzporedni predogled",
- "wikieditor-preview-tab": "Predogled",
- "wikieditor-preview-changes-tab": "Spremembe",
- "wikieditor-preview-loading": "Nalaganje ...",
- "wikieditor-publish-preference": "Omogoči objavljanje korak-po-koraku",
- "wikieditor-publish-button-publish": "Objavi",
- "wikieditor-publish-button-cancel": "Prekliči",
- "wikieditor-publish-dialog-title": "Objavi na {{GRAMMAR:dajalnik|{{SITENAME}}}}",
- "wikieditor-publish-dialog-summary": "Povzetek urejanja (na kratko opišite narejene spremembe):",
- "wikieditor-publish-dialog-minor": "Manjše urejanje",
- "wikieditor-publish-dialog-watch": "Opazuj stran",
- "wikieditor-publish-dialog-publish": "Objavi",
- "wikieditor-publish-dialog-goback": "Pojdi nazaj",
"wikieditor-toolbar": "Urejevalna orodna vrstica",
"wikieditor-toolbar-desc": "Urejevalna orodna vrstica z večjo uporabnostjo",
"wikieditor-toolbar-preference": "Omogoči izboljšano urejevalno vrstico",
- "wikieditor-toolbar-dialogs-preference": "Omogoči čarovnike za vstavljanje povezav in tabel, kakor tudi funkcijo išči in zamenjaj",
"wikieditor-toolbar-loading": "Nalaganje ...",
"wikieditor-toolbar-tool-bold": "Krepko",
"wikieditor-toolbar-tool-bold-example": "Krepko besedilo",
@@ -59,7 +46,7 @@
"wikieditor-toolbar-tool-link-lookslikeinternal-int": "Notranja povezava",
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Zunanja povezava",
"wikieditor-toolbar-tool-link-empty": "Niste vnesli ničesar, na kar bi se lahko povezovalo.",
- "wikieditor-toolbar-tool-file": "Vgradi datoteko",
+ "wikieditor-toolbar-tool-file": "Vstavi datoteko",
"wikieditor-toolbar-tool-file-example": "Zgled.jpg",
"wikieditor-toolbar-tool-file-title": "Vstavi datoteko",
"wikieditor-toolbar-file-target": "Ime datoteke:",
diff --git a/www/wiki/extensions/WikiEditor/i18n/so.json b/www/wiki/extensions/WikiEditor/i18n/so.json
index 1af99f43..6510015f 100644
--- a/www/wiki/extensions/WikiEditor/i18n/so.json
+++ b/www/wiki/extensions/WikiEditor/i18n/so.json
@@ -4,6 +4,5 @@
"Abshirdheere"
]
},
- "wikieditor-toolbar-preference": "Hawlgali marinka qalabka waxbedelka ee horumariyaha.",
- "wikieditor-toolbar-dialogs-preference": "Ka shaqaysii daaqadaha galinta ee xiriirka, jadwallada iyo shaqaysiinta raadinta isdhaafsiga"
+ "wikieditor-toolbar-preference": "Hawlgali marinka qalabka waxbedelka ee horumariyaha."
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/sq.json b/www/wiki/extensions/WikiEditor/i18n/sq.json
index 6a19c6ec..f3532d11 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sq.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sq.json
@@ -13,23 +13,9 @@
"wikieditor-desc": "Siguron një redaktimi të vazhdueshëm wikitekst dhe shumë sigurime metrazhi",
"wikieditor-wikitext-tab": "Tekstwiki",
"wikieditor-loading": "Duke ngarkuar...",
- "wikieditor-preview-preference": "Aktivizoni parapamjen krah-për-krah",
- "wikieditor-preview-tab": "Parapamje",
- "wikieditor-preview-changes-tab": "Ndryshimet",
- "wikieditor-preview-loading": "Duke ngarkuar...",
- "wikieditor-publish-preference": "Aktivizoni publikimin hap-pas-hapi",
- "wikieditor-publish-button-publish": "Publikuar",
- "wikieditor-publish-button-cancel": "Anulo",
- "wikieditor-publish-dialog-title": "Publikimi për {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Përmbledhje (përshkrim të shkurtër e ndryshimeve që e keni bërë):",
- "wikieditor-publish-dialog-minor": "Redaktim i vogël",
- "wikieditor-publish-dialog-watch": "Mbikqyre këtë faqe",
- "wikieditor-publish-dialog-publish": "Publikuar",
- "wikieditor-publish-dialog-goback": "Kthehu",
"wikieditor-toolbar": "Redaktoni trat me vegla",
"wikieditor-toolbar-desc": "Redaktoni shiritin e veglave të faqes me përdorshmëri të zgjeruar",
"wikieditor-toolbar-preference": "Aktizoni redaktimin e zgjeruar të shiritit të mjeteve",
- "wikieditor-toolbar-dialogs-preference": "Aktivizoni dialogun për të futur lidhjet, tabelët etj.",
"wikieditor-toolbar-loading": "Duke punuar...",
"wikieditor-toolbar-tool-bold": "Trashë",
"wikieditor-toolbar-tool-bold-example": "Tekst i trashë",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sr-ec.json b/www/wiki/extensions/WikiEditor/i18n/sr-ec.json
index 4c00e3b9..834c6d35 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sr-ec.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sr-ec.json
@@ -12,50 +12,39 @@
"Михајло Анђелковић",
"Macofe",
"Сербијана",
- "Srdjan m"
+ "Srdjan m",
+ "Acamicamacaraca",
+ "Obsuser",
+ "BadDog"
]
},
- "wikieditor": "Напредно окружење за уређивање вики-текста",
- "wikieditor-desc": "Пружа прошириво корисничко окружење за уређивање викитекста и много модула са бројним могућностима",
+ "wikieditor": "Напредно окружење за уређивање викитекста",
+ "wikieditor-desc": "Пружа напредно, прошириво корисничко окружење за уређивање викитекста",
"wikieditor-wikitext-tab": "Викитекст",
- "wikieditor-loading": "Учитавање...",
- "wikieditor-preview-preference": "Омогући упоредни преглед",
- "wikieditor-preview-tab": "Преглед",
- "wikieditor-preview-changes-tab": "Измене",
- "wikieditor-preview-loading": "Учитавам…",
- "wikieditor-publish-preference": "Омогући постепено објављивање",
- "wikieditor-publish-button-publish": "Објави",
- "wikieditor-publish-button-cancel": "Откажи",
- "wikieditor-publish-dialog-title": "Објави на {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Опис измене (укратко опишите шта сте изменили):",
- "wikieditor-publish-dialog-minor": "Мања измена",
- "wikieditor-publish-dialog-watch": "Надгледај ову страницу",
- "wikieditor-publish-dialog-publish": "Објави",
- "wikieditor-publish-dialog-goback": "Врати се",
- "wikieditor-toolbar": "Алатна трака за уређивање",
- "wikieditor-toolbar-desc": "Алатна трака за уређивање с побољшаном употребљивошћу",
+ "wikieditor-loading": "Учитавам...",
+ "wikieditor-toolbar": "Трака са алаткама за уређивање",
+ "wikieditor-toolbar-desc": "Трака са алаткама за уређивање с побољшаном употребљивошћу",
"wikieditor-toolbar-preference": "Омогући побољшану траку за уређивање",
- "wikieditor-toolbar-dialogs-preference": "Омогући чаробњаке за убацивање веза, табела и више",
"wikieditor-toolbar-loading": "Учитавам…",
"wikieditor-toolbar-tool-bold": "Подебљано",
"wikieditor-toolbar-tool-bold-example": "Подебљан текст",
"wikieditor-toolbar-tool-italic": "Искошено",
- "wikieditor-toolbar-tool-italic-example": "Искошени текст",
+ "wikieditor-toolbar-tool-italic-example": "Искошен текст",
"wikieditor-toolbar-tool-ilink": "Унутрашња веза",
"wikieditor-toolbar-tool-ilink-example": "Наслов везе",
"wikieditor-toolbar-tool-xlink": "Спољна веза (с предметком http://)",
- "wikieditor-toolbar-tool-xlink-example": "http://www.primer.com наслов везе",
+ "wikieditor-toolbar-tool-xlink-example": "http://www.example.com наслов везе",
"wikieditor-toolbar-tool-link": "Веза",
- "wikieditor-toolbar-tool-link-title": "Убаци везу",
+ "wikieditor-toolbar-tool-link-title": "Убацивање везе",
"wikieditor-toolbar-tool-link-int": "Према вики страници",
- "wikieditor-toolbar-tool-link-int-target": "Наслов странице или УРЛ:",
+ "wikieditor-toolbar-tool-link-int-target": "Циљана страница или URL:",
"wikieditor-toolbar-tool-link-int-target-tooltip": "Наслов странице или URL",
"wikieditor-toolbar-tool-link-int-text": "Текст везе:",
"wikieditor-toolbar-tool-link-int-text-tooltip": "Текст за приказ",
- "wikieditor-toolbar-tool-link-ext": "Према спољној страници",
+ "wikieditor-toolbar-tool-link-ext": "Према спољашњој страници",
"wikieditor-toolbar-tool-link-ext-target": "Адреса везе:",
"wikieditor-toolbar-tool-link-ext-text": "Текст везе:",
- "wikieditor-toolbar-tool-link-insert": "Убаци везу",
+ "wikieditor-toolbar-tool-link-insert": "Убаци",
"wikieditor-toolbar-tool-link-cancel": "Откажи",
"wikieditor-toolbar-tool-link-int-target-status-exists": "Страница постоји",
"wikieditor-toolbar-tool-link-int-target-status-notexists": "Страница не постоји",
@@ -67,26 +56,26 @@
"wikieditor-toolbar-tool-link-lookslikeinternal": "Спољашња веза коју сте унели изгледа као веза према другој вики страници. Да ли желите да је промените у унутрашњу везу?",
"wikieditor-toolbar-tool-link-lookslikeinternal-int": "Унутрашња веза",
"wikieditor-toolbar-tool-link-lookslikeinternal-ext": "Спољашња веза",
- "wikieditor-toolbar-tool-link-empty": "Ниста унели ништа за повезивање.",
+ "wikieditor-toolbar-tool-link-empty": "Ништа нисте унели за повезивање.",
"wikieditor-toolbar-tool-file": "Убацивање датотеке",
"wikieditor-toolbar-tool-file-example": "Пример.jpg",
"wikieditor-toolbar-tool-file-title": "Убацивање датотеке",
"wikieditor-toolbar-file-target": "Назив датотеке:",
- "wikieditor-toolbar-file-caption": "Наслов:",
+ "wikieditor-toolbar-file-caption": "Опис:",
"wikieditor-toolbar-file-size": "Величина:",
"wikieditor-toolbar-file-float": "Позиција:",
- "wikieditor-toolbar-file-default": "(подразумевано)",
+ "wikieditor-toolbar-file-default": "(подразумевана)",
"wikieditor-toolbar-file-format": "Формат:",
"wikieditor-toolbar-file-format-none": "ништа",
"wikieditor-toolbar-tool-file-insert": "Убаци",
"wikieditor-toolbar-tool-file-cancel": "Откажи",
"wikieditor-toolbar-tool-file-upload": "Отпреми",
- "wikieditor-toolbar-tool-reference": "Навод",
+ "wikieditor-toolbar-tool-reference": "Референца",
"wikieditor-toolbar-tool-reference-example": "Овде унесите текст фусноте",
"wikieditor-toolbar-tool-reference-cancel": "Откажи",
- "wikieditor-toolbar-tool-reference-title": "Убаци референцу",
+ "wikieditor-toolbar-tool-reference-title": "Убацивање референце",
"wikieditor-toolbar-tool-reference-insert": "Убаци",
- "wikieditor-toolbar-tool-reference-text": "Текст навода",
+ "wikieditor-toolbar-tool-reference-text": "Текст референце",
"wikieditor-toolbar-tool-signature": "Потпис с тренутним временом",
"wikieditor-toolbar-section-advanced": "Напредно",
"wikieditor-toolbar-tool-heading": "Наслов",
@@ -97,56 +86,56 @@
"wikieditor-toolbar-tool-heading-5": "Ниво 5",
"wikieditor-toolbar-tool-heading-example": "Текст наслова",
"wikieditor-toolbar-group-format": "Облик",
- "wikieditor-toolbar-tool-ulist": "Списак с ознакама",
- "wikieditor-toolbar-tool-ulist-example": "Ставка пописа с ознакама",
+ "wikieditor-toolbar-tool-ulist": "Списак с булетима",
+ "wikieditor-toolbar-tool-ulist-example": "Ставка набројивог списка",
"wikieditor-toolbar-tool-olist": "Нумерисани списак",
"wikieditor-toolbar-tool-olist-example": "Ставка нумерисаног списка",
"wikieditor-toolbar-tool-nowiki": "Без викиобликовања",
"wikieditor-toolbar-tool-nowiki-example": "Убаците необликован текст овде",
"wikieditor-toolbar-tool-redirect": "Преусмерење",
- "wikieditor-toolbar-tool-redirect-example": "Име циљне странице",
+ "wikieditor-toolbar-tool-redirect-example": "име циљне странице",
"wikieditor-toolbar-tool-big": "Увећано",
- "wikieditor-toolbar-tool-big-example": "Велики текст",
+ "wikieditor-toolbar-tool-big-example": "Увећан текст",
"wikieditor-toolbar-tool-small": "Умањено",
- "wikieditor-toolbar-tool-small-example": "Мали текст",
+ "wikieditor-toolbar-tool-small-example": "Умањен текст",
"wikieditor-toolbar-tool-superscript": "Експонент",
"wikieditor-toolbar-tool-superscript-example": "Текст експонента",
"wikieditor-toolbar-tool-subscript": "Индекс",
"wikieditor-toolbar-tool-subscript-example": "Текст индекса",
"wikieditor-toolbar-group-insert": "Убаци",
"wikieditor-toolbar-tool-gallery": "Галерија слика",
- "wikieditor-toolbar-tool-gallery-example": "пример1.jpg|Наслов1\nпример2.jpg|Наслов2",
+ "wikieditor-toolbar-tool-gallery-example": "Пример1.jpg|наслов1\nПример2.jpg|наслов2",
"wikieditor-toolbar-tool-newline": "Нови ред",
"wikieditor-toolbar-tool-table": "Табела",
- "wikieditor-toolbar-tool-table-example-old": "-\n! наслов 1\n! наслов 2\n! наслов 3\n|-\n| ред 1, ћелија 1\n| ред 1, ћелија 2\n| ред 1, ћелија 3\n|-\n| ред 2, ћелија 1\n| ред 2, ћелија 2\n| ред 2, ћелија 3",
+ "wikieditor-toolbar-tool-table-example-old": "-\n! Наслов 1\n! Наслов 2\n! Наслов 3\n|-\n| Ред 1, ћелија 1\n| Ред 1, ћелија 2\n| Ред 1, ћелија 3\n|-\n| Ред 2, ћелија 1\n| Ред 2, ћелија 2\n| Ред 2, ћелија 3",
"wikieditor-toolbar-tool-table-example-cell-text": "Текст ћелије",
"wikieditor-toolbar-tool-table-example-header": "Текст наслова",
- "wikieditor-toolbar-tool-table-title": "Убаци табелу",
+ "wikieditor-toolbar-tool-table-title": "Убацивање табеле",
"wikieditor-toolbar-tool-table-dimensions-rows": "Редова",
"wikieditor-toolbar-tool-table-dimensions-columns": "Колона",
- "wikieditor-toolbar-tool-table-dimensions-header": "Додај насловни ред",
+ "wikieditor-toolbar-tool-table-dimensions-header": "Насловни ред",
"wikieditor-toolbar-tool-table-wikitable": "Стил с границама",
- "wikieditor-toolbar-tool-table-sortable": "Сврставање табеле",
+ "wikieditor-toolbar-tool-table-sortable": "Сортабилна табела",
"wikieditor-toolbar-tool-table-example": "Пример",
"wikieditor-toolbar-tool-table-preview": "Преглед",
"wikieditor-toolbar-tool-table-insert": "Убаци",
"wikieditor-toolbar-tool-table-cancel": "Откажи",
"wikieditor-toolbar-tool-table-example-text": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut nec purus diam. Sed aliquam imperdiet nunc quis lacinia. Donec rutrum consectetur placerat. Sed volutpat neque non purus faucibus id ultricies enim euismod.",
"wikieditor-toolbar-tool-table-toomany": "Не можете да убацујете табеле с више од $1 {{PLURAL:$1|ћелије|ћелија}} с овим прозорчетом.",
- "wikieditor-toolbar-tool-table-invalidnumber": "Нисте унели валидан број редова и колона",
+ "wikieditor-toolbar-tool-table-invalidnumber": "Нисте унели исправан број редова и колона",
"wikieditor-toolbar-tool-table-zero": "Не можете да унесете табелу са 0 редова или колона.",
- "wikieditor-toolbar-tool-replace": "Тражи и замени",
+ "wikieditor-toolbar-tool-replace": "Претражи и замени",
"wikieditor-toolbar-tool-replace-title": "Тражи и замени",
- "wikieditor-toolbar-tool-replace-search": "Тражи:",
+ "wikieditor-toolbar-tool-replace-search": "Претражи:",
"wikieditor-toolbar-tool-replace-replace": "Замени са:",
"wikieditor-toolbar-tool-replace-case": "Пази на величину слова",
- "wikieditor-toolbar-tool-replace-regex": "Поступи с нитима за претрагу као с обичним изразима",
+ "wikieditor-toolbar-tool-replace-regex": "Поступи са стрингом за претрагу као с регуларним изразом",
"wikieditor-toolbar-tool-replace-button-findnext": "Нађи следеће",
"wikieditor-toolbar-tool-replace-button-replace": "Замени",
"wikieditor-toolbar-tool-replace-button-replaceall": "Замени све",
"wikieditor-toolbar-tool-replace-close": "Затвори",
"wikieditor-toolbar-tool-replace-nomatch": "Претрага није пронашла резултате.",
- "wikieditor-toolbar-tool-replace-success": "Направљених {{PLURAL:$1|замена}}: $1.",
+ "wikieditor-toolbar-tool-replace-success": "{{PLURAL:$1|Направљена $1 замена|Направљене $1 замене|Направљено $1 замена}}.",
"wikieditor-toolbar-tool-replace-emptysearch": "Нисте унели ништа за претрагу.",
"wikieditor-toolbar-tool-replace-invalidregex": "Израз који сте унели није исправан: $1",
"wikieditor-toolbar-section-characters": "Посебни знакови",
@@ -162,14 +151,14 @@
"wikieditor-toolbar-help-page-reference": "Референце",
"wikieditor-toolbar-help-page-discussion": "Разговор",
"wikieditor-toolbar-help-content-italic-description": "Искошено",
- "wikieditor-toolbar-help-content-italic-syntax": "''Искошени текст''",
- "wikieditor-toolbar-help-content-italic-result": "<em>Искошени текст</em>",
+ "wikieditor-toolbar-help-content-italic-syntax": "''Искошен текст''",
+ "wikieditor-toolbar-help-content-italic-result": "<em>Искошен текст</em>",
"wikieditor-toolbar-help-content-bold-description": "Подебљано",
- "wikieditor-toolbar-help-content-bold-syntax": "'''Подебљани текст'''",
- "wikieditor-toolbar-help-content-bold-result": "<strong>Подебљани текст</strong>",
+ "wikieditor-toolbar-help-content-bold-syntax": "'''Подебљан текст'''",
+ "wikieditor-toolbar-help-content-bold-result": "<strong>Подебљан текст</strong>",
"wikieditor-toolbar-help-content-bolditalic-description": "Подебљано и искошено",
- "wikieditor-toolbar-help-content-bolditalic-syntax": "'''''Подебљани и искошени текст'''''",
- "wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>Подебљани и искошени текст</em></strong>",
+ "wikieditor-toolbar-help-content-bolditalic-syntax": "'''''Подебљан и искошен текст'''''",
+ "wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>Подебљан и искошен текст</em></strong>",
"wikieditor-toolbar-help-content-ilink-description": "Унутрашња веза",
"wikieditor-toolbar-help-content-ilink-syntax": "[[Наслов странице]]<br />[[Наслов странице|Назив везе]]",
"wikieditor-toolbar-help-content-ilink-result": "<a href='#'>Наслов странице</a><br /><a href='#'>Назив везе</a>",
@@ -188,7 +177,7 @@
"wikieditor-toolbar-help-content-heading5-description": "Наслов петог нивоа",
"wikieditor-toolbar-help-content-heading5-syntax": "===== Текст наслова =====",
"wikieditor-toolbar-help-content-heading5-result": "<h5>Наслов одељка</h5>",
- "wikieditor-toolbar-help-content-ulist-description": "Списак с ознакама",
+ "wikieditor-toolbar-help-content-ulist-description": "Списак с булетима",
"wikieditor-toolbar-help-content-ulist-syntax": "* Ставка<br />* Ставка",
"wikieditor-toolbar-help-content-ulist-result": "<ul><li>Ставка</li><li>Ставка</li></ul>",
"wikieditor-toolbar-help-content-olist-description": "Нумерисани списак",
@@ -214,6 +203,6 @@
"wikieditor-toolbar-help-content-signature-description": "Потпис",
"wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>Корисничко име</a> (<a href='#' title='$2:Username'>разговор</a>)",
"wikieditor-toolbar-help-content-indent-description": "Увлачење",
- "wikieditor-toolbar-help-content-indent-syntax": "Обични текст<br />:Увучени текст<br />::Увучени текст",
- "wikieditor-toolbar-help-content-indent-result": "Обични текст<dl><dd>Увучени текст<dl><dd>Увучени текст</dd></dl></dd></dl>"
+ "wikieditor-toolbar-help-content-indent-syntax": "Обичан текст<br />:Увучен текст<br />::Увучен текст",
+ "wikieditor-toolbar-help-content-indent-result": "Обичан текст<dl><dd>Увучен текст<dl><dd>Увучен текст</dd></dl></dd></dl>"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/sr-el.json b/www/wiki/extensions/WikiEditor/i18n/sr-el.json
index a52dff9d..4f65ad63 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sr-el.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sr-el.json
@@ -7,30 +7,17 @@
"Жељко Тодоровић",
"Milicevic01",
"Macofe",
- "Srdjan m"
+ "Srdjan m",
+ "Obsuser"
]
},
"wikieditor": "Napredno sučelje uređivanja vikiteksta",
"wikieditor-desc": "Pruža proširivo korisničko okruženje za uređivanje vikiteksta i mnogo modula sa brojnim mogućnostima",
"wikieditor-wikitext-tab": "Vikitekst",
"wikieditor-loading": "Učitavanje...",
- "wikieditor-preview-preference": "Omogući uporedni pregled",
- "wikieditor-preview-tab": "Pretpregled",
- "wikieditor-preview-changes-tab": "Izmene",
- "wikieditor-preview-loading": "Učitavanje...",
- "wikieditor-publish-preference": "Omogući postepeno objavljivanje",
- "wikieditor-publish-button-publish": "Objavi",
- "wikieditor-publish-button-cancel": "Otkaži",
- "wikieditor-publish-dialog-title": "Objavi na {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Opis izmene (ukratko opišite šta ste izmenili):",
- "wikieditor-publish-dialog-minor": "Mala izmena",
- "wikieditor-publish-dialog-watch": "Nadgledaj ovu stranicu",
- "wikieditor-publish-dialog-publish": "Objavi",
- "wikieditor-publish-dialog-goback": "Vrati se",
"wikieditor-toolbar": "Alatna traka za uređivanje",
"wikieditor-toolbar-desc": "Alatna traka za uređivanje s poboljšanom upotrebljivošću",
"wikieditor-toolbar-preference": "Omogući poboljšanu traku za uređivanje",
- "wikieditor-toolbar-dialogs-preference": "Omogući čarobnjake za ubacivanje veza, tabela i više",
"wikieditor-toolbar-loading": "Učitavanje...",
"wikieditor-toolbar-tool-bold": "Podebljano",
"wikieditor-toolbar-tool-bold-example": "Podebljan tekst",
@@ -92,7 +79,7 @@
"wikieditor-toolbar-tool-heading-5": "Nivo 5",
"wikieditor-toolbar-tool-heading-example": "Tekst odeljka",
"wikieditor-toolbar-group-format": "Oblik",
- "wikieditor-toolbar-tool-ulist": "Spisak s oznakama",
+ "wikieditor-toolbar-tool-ulist": "Spisak s buletima",
"wikieditor-toolbar-tool-ulist-example": "Stavka popisa s oznakama",
"wikieditor-toolbar-tool-olist": "Numerisani spisak",
"wikieditor-toolbar-tool-olist-example": "Stavka numerisanog spiska",
@@ -130,18 +117,18 @@
"wikieditor-toolbar-tool-table-toomany": "Ne možete da ubacujete tabele s više od $1 {{PLURAL:$1|ćelije|ćelija}} s ovim prozorčetom.",
"wikieditor-toolbar-tool-table-invalidnumber": "Niste uneli validan broj redova i kolona",
"wikieditor-toolbar-tool-table-zero": "Ne možete da unesete tabelu sa 0 redova ili kolona.",
- "wikieditor-toolbar-tool-replace": "Traži i zameni",
+ "wikieditor-toolbar-tool-replace": "Pretraži i zameni",
"wikieditor-toolbar-tool-replace-title": "Traži i zameni",
- "wikieditor-toolbar-tool-replace-search": "Traži:",
+ "wikieditor-toolbar-tool-replace-search": "Pretraži:",
"wikieditor-toolbar-tool-replace-replace": "Zameni sa:",
"wikieditor-toolbar-tool-replace-case": "Pazi na veličinu slova",
- "wikieditor-toolbar-tool-replace-regex": "Postupi s nitima za pretragu kao s običnim izrazima",
+ "wikieditor-toolbar-tool-replace-regex": "Postupi sa stringom za pretragu kao s regularnim izrazom",
"wikieditor-toolbar-tool-replace-button-findnext": "Nađi sledeće",
"wikieditor-toolbar-tool-replace-button-replace": "Zameni",
"wikieditor-toolbar-tool-replace-button-replaceall": "Zameni sve",
"wikieditor-toolbar-tool-replace-close": "Zatvori",
"wikieditor-toolbar-tool-replace-nomatch": "Pretraga nije pronašla rezultate.",
- "wikieditor-toolbar-tool-replace-success": "Napravljenih {{PLURAL:$1|zamena}}: $1.",
+ "wikieditor-toolbar-tool-replace-success": "{{PLURAL:$1|Napravljena $1 zamena|Napravljene $1 zamene|Napravljeno $1 zamena}}.",
"wikieditor-toolbar-tool-replace-emptysearch": "Niste uneli ništa za pretragu.",
"wikieditor-toolbar-tool-replace-invalidregex": "Izraz koji ste uneli nije ispravan: $1",
"wikieditor-toolbar-section-characters": "Posebni znakovi",
@@ -183,7 +170,7 @@
"wikieditor-toolbar-help-content-heading5-description": "Naslov petog nivoa",
"wikieditor-toolbar-help-content-heading5-syntax": "===== Tekst naslova =====",
"wikieditor-toolbar-help-content-heading5-result": "<h5>Naslov odeljka</h5>",
- "wikieditor-toolbar-help-content-ulist-description": "Spisak s oznakama",
+ "wikieditor-toolbar-help-content-ulist-description": "Spisak s buletima",
"wikieditor-toolbar-help-content-ulist-syntax": "* Stavka<br />* Stavka",
"wikieditor-toolbar-help-content-ulist-result": "<ul><li>Stavka</li><li>Stavka</li></ul>",
"wikieditor-toolbar-help-content-olist-description": "Numerisani spisak",
diff --git a/www/wiki/extensions/WikiEditor/i18n/su.json b/www/wiki/extensions/WikiEditor/i18n/su.json
index 4605b15f..d45ca736 100644
--- a/www/wiki/extensions/WikiEditor/i18n/su.json
+++ b/www/wiki/extensions/WikiEditor/i18n/su.json
@@ -8,17 +8,6 @@
},
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Ngamuat",
- "wikieditor-preview-tab": "Pramidang",
- "wikieditor-preview-changes-tab": "Parobahan",
- "wikieditor-preview-loading": "Ngamuat…",
- "wikieditor-publish-button-publish": "Terbitkeun",
- "wikieditor-publish-button-cancel": "Bolay",
- "wikieditor-publish-dialog-title": "Terbitkeun di {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Ringkesna (parobahan naon anu dijieun):",
- "wikieditor-publish-dialog-minor": "Éditan minor",
- "wikieditor-publish-dialog-watch": "Awaskeun ieu kaca",
- "wikieditor-publish-dialog-publish": "Terbitkeun",
- "wikieditor-publish-dialog-goback": "Balik deui",
"wikieditor-toolbar": "Tulbar paranti ngédit",
"wikieditor-toolbar-loading": "Ngamuat…",
"wikieditor-toolbar-tool-bold": "Kandel",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sv.json b/www/wiki/extensions/WikiEditor/i18n/sv.json
index 41ba9fe5..f48cee26 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sv.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sv.json
@@ -20,23 +20,9 @@
"wikieditor-desc": "Tillhandahåller ett utökat gränssnitt för redigering av wikitext och många moduler som tillhandahåller funktioner",
"wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "Laddar...",
- "wikieditor-preview-preference": "Aktivera förhandsgranskning sida-vid-sida",
- "wikieditor-preview-tab": "Förhandsgranska",
- "wikieditor-preview-changes-tab": "Ändringar",
- "wikieditor-preview-loading": "Laddar...",
- "wikieditor-publish-preference": "Aktivera steg-för-steg-publicering",
- "wikieditor-publish-button-publish": "Publicera",
- "wikieditor-publish-button-cancel": "Avbryt",
- "wikieditor-publish-dialog-title": "Publicera i {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Redigeringssammanfattning (beskriv överskådligt de förändringar du har gjort):",
- "wikieditor-publish-dialog-minor": "Mindre ändring",
- "wikieditor-publish-dialog-watch": "Bevaka denna sida",
- "wikieditor-publish-dialog-publish": "Publicera",
- "wikieditor-publish-dialog-goback": "Gå tillbaka",
"wikieditor-toolbar": "Redigeringsverktygsrad",
"wikieditor-toolbar-desc": "Redigeringsverktygsrad med utökad användbarhet",
"wikieditor-toolbar-preference": "Aktivera utökad redigeringsverktygsrad",
- "wikieditor-toolbar-dialogs-preference": "Aktivera guider för att lägga in länkar, tabeller såväl som sök- och ersättningsfunktionen",
"wikieditor-toolbar-loading": "Laddar...",
"wikieditor-toolbar-tool-bold": "Fet",
"wikieditor-toolbar-tool-bold-example": "Fet text",
diff --git a/www/wiki/extensions/WikiEditor/i18n/sw.json b/www/wiki/extensions/WikiEditor/i18n/sw.json
index 3749ecd2..d355ce95 100644
--- a/www/wiki/extensions/WikiEditor/i18n/sw.json
+++ b/www/wiki/extensions/WikiEditor/i18n/sw.json
@@ -4,29 +4,16 @@
"Kwisha",
"Lloffiwr",
"Muddyb Blast Producer",
- "Macofe"
+ "Macofe",
+ "Muddyb"
]
},
"wikieditor": "Kusano ya juu ya kuandika kiwiki",
"wikieditor-wikitext-tab": "Maandishi ya kiwiki",
"wikieditor-loading": "Inapakizwa",
- "wikieditor-preview-preference": "Kuona hakikisho ya mabadiliko na ukurasa ulivyo sasa kwa pamoja.",
- "wikieditor-preview-tab": "Hakiki",
- "wikieditor-preview-changes-tab": "Mabadiliko",
- "wikieditor-preview-loading": "Inapakiwa...",
- "wikieditor-publish-preference": "Kuwezesha kutoa mabadiliko hatua kwa hatua",
- "wikieditor-publish-button-publish": "Toa",
- "wikieditor-publish-button-cancel": "Batilisha",
- "wikieditor-publish-dialog-title": "Kutoa kwenye {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Muhtasari ya kuhariri (ueleze kifupi mabadiliko ulioyafanya):",
- "wikieditor-publish-dialog-minor": "Badiliko dogo",
- "wikieditor-publish-dialog-watch": "Fuatilia ukurasa huu",
- "wikieditor-publish-dialog-publish": "Chapisha",
- "wikieditor-publish-dialog-goback": "Rudi",
"wikieditor-toolbar": "Mwambaa zana wa kuhariri",
"wikieditor-toolbar-desc": "Mwambaa zana wa kuhariri uliozidishwa",
"wikieditor-toolbar-preference": "Tumia mwambaa zana wa kuhariri uliozidishwa",
- "wikieditor-toolbar-dialogs-preference": "Kuwezesha visanduku vya zana za kuingiza viungo, jedwali na mengineyo",
"wikieditor-toolbar-loading": "Inapakizwa...",
"wikieditor-toolbar-tool-bold": "Koze",
"wikieditor-toolbar-tool-bold-example": "Maandishi ya kooze",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ta.json b/www/wiki/extensions/WikiEditor/i18n/ta.json
index 6958f109..a05b867f 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ta.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ta.json
@@ -17,19 +17,6 @@
"wikieditor-desc": "நீட்டிக்கத்தகு விக்கிஉரை இடைமுகத்தையும் மேலும் பல அம்சங்களையும் தருகிறது",
"wikieditor-wikitext-tab": "விக்கிஉரை",
"wikieditor-loading": "ஏற்றப்படுகிறது",
- "wikieditor-preview-preference": "பக்கம் பக்கமாக முன்னோட்டம் பார்த்தலைச் செயல்படுத்துக",
- "wikieditor-preview-tab": "முன்தோற்றம்",
- "wikieditor-preview-changes-tab": "மாற்றங்கள்",
- "wikieditor-preview-loading": "ஏற்றப்படுகிறது...",
- "wikieditor-publish-preference": "படிப்படியாக வெளியிடலைச் செயல்படுத்துக",
- "wikieditor-publish-button-publish": "வெளியிடு",
- "wikieditor-publish-button-cancel": "விட்டுவிடு",
- "wikieditor-publish-dialog-title": "{{SITENAME}} என்பதற்கு வெளியிடு",
- "wikieditor-publish-dialog-summary": "தொகுப்புச் சுருக்கம் (நீங்கள் செய்த மாற்றங்களைச் சுருக்கமாகக் கூறவும்):",
- "wikieditor-publish-dialog-minor": "சிறு தொகுப்பு",
- "wikieditor-publish-dialog-watch": "இந்தப் பக்கத்தைக் கவனிக்கவும்",
- "wikieditor-publish-dialog-publish": "வெளியிடு",
- "wikieditor-publish-dialog-goback": "பின் செல்லவும்",
"wikieditor-toolbar": "தொகுப்புக் கருவிப்பட்டை",
"wikieditor-toolbar-desc": "பக்கக் கருவிப்பட்டையை மேம்படுத்தப்பட்ட பயன்பாட்டுடன் தொகுக்கவும்",
"wikieditor-toolbar-preference": "மேம்படுத்தப்பட்ட தொகுத்தல் கருவிப்பட்டையைச் செயற்படுத்தவும்",
diff --git a/www/wiki/extensions/WikiEditor/i18n/tay.json b/www/wiki/extensions/WikiEditor/i18n/tay.json
index af15b233..4c7bd976 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tay.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tay.json
@@ -6,21 +6,34 @@
]
},
"wikieditor-loading": "Lpgun...",
- "wikieditor-preview-preference": "Gyahiy pingluw binkgan na pnaynman pkita’",
- "wikieditor-preview-tab": "Pnaynama’ mita’",
- "wikieditor-preview-loading": "lpgun...",
- "wikieditor-publish-button-cancel": "Laxan",
- "wikieditor-publish-dialog-minor": "Cikuy sinbah",
- "wikieditor-publish-dialog-publish": "Skayal kwara’ squliq",
- "wikieditor-publish-dialog-goback": "’bzinah",
+ "wikieditor-toolbar": "Binkgan lalu’ na ssr’zyut miru’",
"wikieditor-toolbar-loading": "Lpgun...",
"wikieditor-toolbar-tool-bold": "Qthuy na biru’",
+ "wikieditor-toolbar-tool-bold-example": "Qthuy na biru’",
"wikieditor-toolbar-tool-italic": "Mtkkiy",
+ "wikieditor-toolbar-tool-italic-example": "Mtkkiy na biru’",
+ "wikieditor-toolbar-tool-ilink": "Pin’ubuy tay qsahuy",
+ "wikieditor-toolbar-tool-ilink-example": "P’ubuy sa lalu’ na kkayal",
+ "wikieditor-toolbar-tool-xlink": "’ubuy tay bzinah (zngyay su’ yaquw http://quw tqsu’ miru’)",
+ "wikieditor-toolbar-tool-xlink-example": "http://www.example.com p’ubuy sa lalu’ na kkayal",
+ "wikieditor-toolbar-tool-link-title": "Qlhan quw ’ubuy",
+ "wikieditor-toolbar-tool-link-int-text": "Pkt’aniy quw biru’:",
"wikieditor-toolbar-tool-link-int-text-tooltip": "Biru’ na musa’ spkaykita’",
"wikieditor-toolbar-tool-link-ext": "’ubuy sa wangye’ tay bzinah",
"wikieditor-toolbar-tool-link-ext-target": "P’ubuy URL:",
+ "wikieditor-toolbar-tool-link-ext-text": "P’ubuy biru’:",
+ "wikieditor-toolbar-tool-link-insert": "Qlhan quw ’ubuy",
"wikieditor-toolbar-tool-link-cancel": "Laxan",
+ "wikieditor-toolbar-tool-link-int-target-status-exists": "Yasa niya’ maki’ krayryax quw zngazyan qaniy",
+ "wikieditor-toolbar-tool-link-int-target-status-notexists": "Ungat zzngayan",
+ "wikieditor-toolbar-tool-link-int-target-status-invalid": "Ungat zyuwaw na lalu’",
+ "wikieditor-toolbar-tool-link-int-target-status-external": "’ubuy tay bzinah",
+ "wikieditor-toolbar-tool-link-int-target-status-disambig": "Llpgan na sinblayan na kay’",
+ "wikieditor-toolbar-tool-link-lookslikeinternal-ext": "’ubuy tay bzinah",
+ "wikieditor-toolbar-tool-file": "Pinraw niya’ biru’ na tang’an",
"wikieditor-toolbar-tool-file-example": "Galan pspngan na.jpg",
+ "wikieditor-toolbar-tool-file-title": "Qlhan quw Tang’an",
+ "wikieditor-toolbar-file-target": "Lalu’ na Tang’an:",
"wikieditor-toolbar-file-caption": "Lalu’:",
"wikieditor-toolbar-file-size": "Sspngan kinkrahu’:",
"wikieditor-toolbar-file-float": "Tnaqun paybkuw:",
@@ -29,34 +42,56 @@
"wikieditor-toolbar-file-format-none": "ungat",
"wikieditor-toolbar-tool-file-cancel": "Laxan",
"wikieditor-toolbar-tool-file-upload": "Pawsa’ sa kktan",
+ "wikieditor-toolbar-tool-reference": "Kmita’ sa bungkeng",
"wikieditor-toolbar-tool-reference-cancel": "Laxan",
"wikieditor-toolbar-tool-reference-title": "Hbaniy quw knita’ squw bunkeng",
"wikieditor-toolbar-tool-reference-text": "Kt’aniy sa biru’ na bunkeng",
+ "wikieditor-toolbar-tool-signature": "Miru’ lalu’ squw zikang",
"wikieditor-toolbar-section-advanced": "Mkkura’ pinqbaqan",
"wikieditor-toolbar-tool-heading": "Lalu’",
+ "wikieditor-toolbar-tool-heading-1": "Lalu’ na kinkrahu’ na biru’ 1",
+ "wikieditor-toolbar-tool-heading-3": "Lalu’ na kinkrahu’ na biru’ 3",
+ "wikieditor-toolbar-tool-heading-4": "Lalu’ na kinkrahu’ na biru’ 4",
+ "wikieditor-toolbar-tool-heading-5": "Lalu’ na kinkrahu’ na biru’ 5",
+ "wikieditor-toolbar-tool-heading-example": "Lalu’ na biru’ kkayal",
"wikieditor-toolbar-group-format": "Ksu’",
+ "wikieditor-toolbar-tool-ulist": "Biru’ na sinbbaq sa binkgan biru’ na kktan",
"wikieditor-toolbar-tool-ulist-example": "Ungat quw sni’ naha’ biru’ sa binkgan biru’na kktan",
+ "wikieditor-toolbar-tool-olist": "Banggo’ na binkgan na zngayan",
"wikieditor-toolbar-tool-olist-example": "Banggo’ na binkgan lmlamu’",
+ "wikieditor-toolbar-tool-redirect": "T’aring lawziy pglaing",
"wikieditor-toolbar-tool-redirect-example": "Lalu’ na sngusan zngazyan",
"wikieditor-toolbar-tool-big": "Pkrahu’",
+ "wikieditor-toolbar-tool-big-example": "Pkrahu’ biru’",
"wikieditor-toolbar-tool-small": "Pkcikuy",
+ "wikieditor-toolbar-tool-small-example": "Pkcikuy biru’",
"wikieditor-toolbar-tool-superscript": "Pinbays niya’ bitu’ cikuy squw mkraya’ na biru’",
"wikieditor-toolbar-tool-subscript": "Pinbays niya’ bitu’ cikuy squw mkyahu’ na biru’",
+ "wikieditor-toolbar-tool-subscript-example": "Pinraw niya’ miru’ sa tay kyahu’ na biru’ ka biru’ ttaykuy",
"wikieditor-toolbar-group-insert": "Shap",
"wikieditor-toolbar-tool-gallery": "Sslyan pinzga’",
"wikieditor-toolbar-tool-newline": "Iyuw quw bkgan",
"wikieditor-toolbar-tool-table": "Qnaysan niya’ sa bbrwan",
+ "wikieditor-toolbar-tool-table-example-cell-text": "Biru’ na cucunko’",
+ "wikieditor-toolbar-tool-table-example-header": "Lalu’ na biru’ kkayal",
+ "wikieditor-toolbar-tool-table-title": "Qlhan quw qnaysan matas bbrwan",
"wikieditor-toolbar-tool-table-dimensions-rows": "Llpgan kinpzyux na binkgan",
"wikieditor-toolbar-tool-table-dimensions-columns": "Kolmns",
+ "wikieditor-toolbar-tool-table-wikitable": "Inrkyasan na sni’ sa syaw na syasing",
"wikieditor-toolbar-tool-table-sortable": "Aki’ baqun mkuw quw xyo na bbrwan",
"wikieditor-toolbar-tool-table-example": "Pinkaykita’ naha’ sa ppslungan",
"wikieditor-toolbar-tool-table-preview": "Pnaynama’ mita’",
"wikieditor-toolbar-tool-table-insert": "Shap",
"wikieditor-toolbar-tool-table-cancel": "Laxan",
+ "wikieditor-toolbar-tool-replace": "Hhkangi’ squw saynagun",
"wikieditor-toolbar-tool-replace-search": "Hhkangi’:",
+ "wikieditor-toolbar-tool-replace-replace": "Saynagun maha:",
"wikieditor-toolbar-tool-replace-case": "Siy ga mtnaq kwara’ kinkrahu’ na bniru’ su’ biru’",
+ "wikieditor-toolbar-tool-replace-button-findnext": "Hkangi’ sa qutux tay suruw",
"wikieditor-toolbar-tool-replace-button-replace": "Saynagun",
+ "wikieditor-toolbar-tool-replace-button-replaceall": "Saynagun kwara’",
"wikieditor-toolbar-tool-replace-close": "Ql’iy",
+ "wikieditor-toolbar-section-characters": "Kin ini’ ptnaq na bnrwan biru’",
"wikieditor-toolbar-section-help": "Minblaq kmal",
"wikieditor-toolbar-help-heading-description": "Myawsu’:",
"wikieditor-toolbar-help-heading-syntax": "Qsahuy na bniru’ su’",
@@ -66,9 +101,23 @@
"wikieditor-toolbar-help-page-heading": "Lalu’",
"wikieditor-toolbar-help-page-list": "Binzyagan sa kktan",
"wikieditor-toolbar-help-page-file": "Biru’ na zayzyuwaw",
+ "wikieditor-toolbar-help-page-reference": "Kmita’ sa bungkeng",
"wikieditor-toolbar-help-content-italic-description": "Mtkkiy",
+ "wikieditor-toolbar-help-content-italic-syntax": "\"Mtkkiy na biru’\"",
"wikieditor-toolbar-help-content-bold-description": "Qthuy na biru’",
+ "wikieditor-toolbar-help-content-bold-syntax": "'''Qthuy na biru’'''",
"wikieditor-toolbar-help-content-bolditalic-description": "Mtkkiy ruw mqalux",
"wikieditor-toolbar-help-content-bolditalic-result": "<strong><em>Mtkkiy ruw mqalux</em></strong>",
+ "wikieditor-toolbar-help-content-ilink-description": "Pin’ubuy tay qsahuy",
+ "wikieditor-toolbar-help-content-xlink-description": "’ubuy tay bzinah",
+ "wikieditor-toolbar-help-content-heading2-syntax": "==Lalu’ na biru’ kkayal ==",
+ "wikieditor-toolbar-help-content-heading3-syntax": "=== Lalu’ na biru’ kkayal ===",
+ "wikieditor-toolbar-help-content-heading4-syntax": "==== Lalu’ na biru’ kkayal ====",
+ "wikieditor-toolbar-help-content-heading5-syntax": "===== Lalu’ na biru’ kkayal =====",
+ "wikieditor-toolbar-help-content-ulist-description": "Biru’ na sinbbaq sa binkgan biru’ na kktan",
+ "wikieditor-toolbar-help-content-olist-description": "Banggo’ na binkgan na zngayan",
+ "wikieditor-toolbar-help-content-file-description": "Pinraw niya’ biru’ na tang’an",
+ "wikieditor-toolbar-help-content-file-caption": "Lalu’ na biru’ kkayal",
+ "wikieditor-toolbar-help-content-reference-description": "Kmita’ sa bungkeng",
"wikieditor-toolbar-help-content-signature-description": "Miru’ lalu’"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/te.json b/www/wiki/extensions/WikiEditor/i18n/te.json
index 6eadb0fc..f98c1a94 100644
--- a/www/wiki/extensions/WikiEditor/i18n/te.json
+++ b/www/wiki/extensions/WikiEditor/i18n/te.json
@@ -8,21 +8,8 @@
"wikieditor": "ఉన్నత వికీపాఠ్య దిద్దుబాటు ముఖాంతరం",
"wikieditor-wikitext-tab": "వికీపాఠ్యం",
"wikieditor-loading": "లోడవుతూంది",
- "wikieditor-preview-preference": "మార్చేపెట్టె పక్క మునుజూపుని చేతనంచేయి",
- "wikieditor-preview-tab": "మునుజూపు",
- "wikieditor-preview-changes-tab": "మార్పులు",
- "wikieditor-preview-loading": "లోడవుతోంది...",
- "wikieditor-publish-button-publish": "ప్రచురించు",
- "wikieditor-publish-button-cancel": "రద్దుచేయి",
- "wikieditor-publish-dialog-title": "{{SITENAME}}లో ప్రచురించు",
- "wikieditor-publish-dialog-summary": "మార్పు సంగ్రహం (మీరు చేసిన మార్పులని క్లుప్తంగా వివరించండి):",
- "wikieditor-publish-dialog-minor": "చిన్న మార్పు",
- "wikieditor-publish-dialog-watch": "ఈ పేజీ మీద కన్నేసి ఉంచు",
- "wikieditor-publish-dialog-publish": "ప్రచురించు",
- "wikieditor-publish-dialog-goback": "వెనక్కి వెళ్ళు",
"wikieditor-toolbar": "ఎడిటింగ్ టూల్‌బార్",
"wikieditor-toolbar-desc": "మెరుగైన ఉపయోగశీలతో దిద్దుబాటు పేజీ పనిముట్లపట్టీ",
- "wikieditor-toolbar-dialogs-preference": "లంకెలు, పట్టికలు మరియు మరెన్నింటినే చేర్చడానికి సంవాదపేటికలను చేతనంచేయి",
"wikieditor-toolbar-loading": "లోడవుతోంది...",
"wikieditor-toolbar-tool-bold": "బొద్దు",
"wikieditor-toolbar-tool-bold-example": "బొద్దు పాఠ్యం",
diff --git a/www/wiki/extensions/WikiEditor/i18n/th.json b/www/wiki/extensions/WikiEditor/i18n/th.json
index 168acd88..ca671745 100644
--- a/www/wiki/extensions/WikiEditor/i18n/th.json
+++ b/www/wiki/extensions/WikiEditor/i18n/th.json
@@ -10,23 +10,9 @@
},
"wikieditor-wikitext-tab": "ข้อความวิกิ",
"wikieditor-loading": "กำลังโหลด",
- "wikieditor-preview-preference": "เปิดใช้งานการแสดงตัวอย่างแบบเคียงข้าง",
- "wikieditor-preview-tab": "แสดงตัวอย่าง",
- "wikieditor-preview-changes-tab": "ความเปลี่ยนแปลง",
- "wikieditor-preview-loading": "กำลังโหลด...",
- "wikieditor-publish-preference": "เปิดใช้งานการเผยแพร่ทีละขั้นตอน",
- "wikieditor-publish-button-publish": "เผยแพร่",
- "wikieditor-publish-button-cancel": "ยกเลิก",
- "wikieditor-publish-dialog-title": "เผยแพร่ไปยัง {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "สรุปการแก้ไข (อธิบายย่อๆ ถึงการเปลี่ยนแปลงที่คุณกระทำ):",
- "wikieditor-publish-dialog-minor": "เป็นการแก้ไขเล็กน้อย",
- "wikieditor-publish-dialog-watch": "เฝ้าดูหน้านี้",
- "wikieditor-publish-dialog-publish": "เผยแพร่",
- "wikieditor-publish-dialog-goback": "กลับไป",
"wikieditor-toolbar": "แถบเครื่องมือสำหรับการแก้ไข",
"wikieditor-toolbar-desc": "แถบเครื่องมือเสริมความสามารถการใช้งานในการแก้ไขหน้า",
"wikieditor-toolbar-preference": "เปิดใช้แถบเครื่องมือเสริมความสามารถการแก้ไข",
- "wikieditor-toolbar-dialogs-preference": "เปิดกล่องโต้ตอบสำหรับการแทรกลิงก์ ตาราง และอื่นๆ",
"wikieditor-toolbar-loading": "กำลังดึงข้อมูล...",
"wikieditor-toolbar-tool-bold": "ตัวหนา",
"wikieditor-toolbar-tool-bold-example": "ข้อความตัวหนา",
@@ -118,7 +104,7 @@
"wikieditor-toolbar-tool-replace-search": "ค้นหาข้อความ:",
"wikieditor-toolbar-tool-replace-replace": "แทนที่ด้วย:",
"wikieditor-toolbar-tool-replace-case": "ค้นหาโดยคำนึงถึงตัวพิมพ์เล็ก-ใหญ่",
- "wikieditor-toolbar-tool-replace-regex": "ให้วลีค้นหาเป็นคำอธิบายทั่วไป",
+ "wikieditor-toolbar-tool-replace-regex": "ให้ข้อความค้นหาเป็นนิพจน์ปรกติ",
"wikieditor-toolbar-tool-replace-button-findnext": "ค้นหาตัวต่อไป",
"wikieditor-toolbar-tool-replace-button-replaceall": "แทนที่ทั้งหมด",
"wikieditor-toolbar-tool-replace-close": "ปิด",
@@ -180,9 +166,9 @@
"wikieditor-toolbar-help-content-rereference-result": "ข้อความในหน้า<sup><a href='#'>[2]</a></sup>",
"wikieditor-toolbar-help-content-showreferences-description": "แสดงแหล่งอ้างอิง",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "ลายเซ็นพร้อมลงเวลา",
- "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>ชื่อผู้ใช้</a> (<a href='#' title='$2:Username'>พูดคุย</a>) 15:54, 10 June 2009 (UTC)",
+ "wikieditor-toolbar-help-content-signaturetimestamp-result": "--<a href='#' title='$1:Username'>ชื่อผู้ใช้</a> (<a href='#' title='$2:Username'>คุย</a>) 15:54, 10 มิถุนายน 2552 (UTC)",
"wikieditor-toolbar-help-content-signature-description": "ลายเซ็น",
- "wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>ชื่อผู้ใช้</a> (<a href='#' title='$2:Username'>พูดคุย</a>)",
+ "wikieditor-toolbar-help-content-signature-result": "<a href='#' title='$1:Username'>ชื่อผู้ใช้</a> (<a href='#' title='$2:Username'>คุย</a>)",
"wikieditor-toolbar-help-content-indent-description": "ย่อหน้า",
"wikieditor-toolbar-help-content-indent-syntax": "บรรทัดปกติ<br />:บรรทัดย่อหน้า<br />::บรรทัดย่อหน้า",
"wikieditor-toolbar-help-content-indent-result": "บรรทัดปกติ<dl><dd>บรรทัดย่อหน้า<dl><dd>บรรทัดย่อหน้า</dd></dl></dd></dl>"
diff --git a/www/wiki/extensions/WikiEditor/i18n/tk.json b/www/wiki/extensions/WikiEditor/i18n/tk.json
index c6137377..bcbbe527 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tk.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tk.json
@@ -9,23 +9,9 @@
"wikieditor-desc": "Giňeldilýän wikitekst redkatirleme interfeýsini we köp aýratynlykly modullary üpjün edýär",
"wikieditor-wikitext-tab": "Wikitekst",
"wikieditor-loading": "Ýüklenilýär",
- "wikieditor-preview-preference": "Egin-egne deslapky syny aç",
- "wikieditor-preview-tab": "Deslapky syn",
- "wikieditor-preview-changes-tab": "Üýtgeşmeler",
- "wikieditor-preview-loading": "Ýüklenilýär...",
- "wikieditor-publish-preference": "Ädimme-ädim neşir etmekligi aç",
- "wikieditor-publish-button-publish": "Neşir et",
- "wikieditor-publish-button-cancel": "Goýbolsun et",
- "wikieditor-publish-dialog-title": "{{SITENAME}} taslamasynda neşir et",
- "wikieditor-publish-dialog-summary": "Özgerdiş düşündirişi (eden üýtgeşmeleriňizi gysgaça düşündiriň):",
- "wikieditor-publish-dialog-minor": "Ujypsyzja özgerdiş",
- "wikieditor-publish-dialog-watch": "Sahypany gözegçilige al",
- "wikieditor-publish-dialog-publish": "Neşir et",
- "wikieditor-publish-dialog-goback": "Yza gaýt",
"wikieditor-toolbar": "Redaktirleme gural paneli",
"wikieditor-toolbar-desc": "Güýçlendirilen oňaýlylyk bilen sahypa gural panelini redaktirle",
"wikieditor-toolbar-preference": "Güýçlendirilen redaktirleme gural panelini aç",
- "wikieditor-toolbar-dialogs-preference": "Çykgytlary, tablisalary we ýenekileri girizmek üçin dialoglary aç",
"wikieditor-toolbar-loading": "Yüklenýär...",
"wikieditor-toolbar-tool-bold": "Goýy",
"wikieditor-toolbar-tool-bold-example": "Goýy tekst",
diff --git a/www/wiki/extensions/WikiEditor/i18n/tl.json b/www/wiki/extensions/WikiEditor/i18n/tl.json
index 458271d5..c57326e7 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tl.json
@@ -13,23 +13,9 @@
"wikieditor-desc": "Nagbibigay ng maidurugtong na dugtungang-mukha na pambago ng wikiteksto at maraming mga modulong nagbibigay ng katangiang-kasangkapan",
"wikieditor-wikitext-tab": "Wikiteksto",
"wikieditor-loading": "Ikinakarga",
- "wikieditor-preview-preference": "Paganahin ang magkatabing paunang-tingin",
- "wikieditor-preview-tab": "Paunang tanaw",
- "wikieditor-preview-changes-tab": "Mga pagbabago",
- "wikieditor-preview-loading": "Ikinakarga...",
- "wikieditor-publish-preference": "Paganahin ang hakbang-hakbang na paglalathala",
- "wikieditor-publish-button-publish": "Ilathala",
- "wikieditor-publish-button-cancel": "Huwag ituloy",
- "wikieditor-publish-dialog-title": "Ilathala sa {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Buod ng pagbabago (maikling ilarawan ang mga pagbabagong ginawa mo):",
- "wikieditor-publish-dialog-minor": "Maliit na pagbabago",
- "wikieditor-publish-dialog-watch": "Bantayan ang pahinang ito",
- "wikieditor-publish-dialog-publish": "Ilathala",
- "wikieditor-publish-dialog-goback": "Bumalik",
"wikieditor-toolbar": "Kahong kasangkapan na pamatnugot",
"wikieditor-toolbar-desc": "Kahong kasangkapan na pamatnugot na may pinainam na pagkanagagamit",
"wikieditor-toolbar-preference": "Paganahin ang pinainam na kahong kasangkapang pamatnugot",
- "wikieditor-toolbar-dialogs-preference": "Paganahin ang mga salitaan para sa pagsisingit ng mga kawing, mga tabla at marami pa",
"wikieditor-toolbar-loading": "Ikinakarga...",
"wikieditor-toolbar-tool-bold": "Makapal",
"wikieditor-toolbar-tool-bold-example": "Makapal na panitik",
diff --git a/www/wiki/extensions/WikiEditor/i18n/tr.json b/www/wiki/extensions/WikiEditor/i18n/tr.json
index 2326ac5f..6822db8d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tr.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tr.json
@@ -20,23 +20,9 @@
"wikieditor-desc": "Genişletilebilir bir viki metni düzenleme arayüzü ve birçok özellik sağlayan modüller sağlar",
"wikieditor-wikitext-tab": "Vikimetin",
"wikieditor-loading": "Yükleniyor...",
- "wikieditor-preview-preference": "Yan yana ön izlemeyi etkinleştir",
- "wikieditor-preview-tab": "Ön izleme",
- "wikieditor-preview-changes-tab": "Değişiklikler",
- "wikieditor-preview-loading": "Yükleniyor...",
- "wikieditor-publish-preference": "Adım adım yayınlamayı etkinleştir",
- "wikieditor-publish-button-publish": "Yayınla",
- "wikieditor-publish-button-cancel": "İptal",
- "wikieditor-publish-dialog-title": "{{SITENAME}} bünyesinde yayınla",
- "wikieditor-publish-dialog-summary": "Değişiklik özeti (yaptığınız değişiklikleri kısaca açıklayın):",
- "wikieditor-publish-dialog-minor": "Küçük değişiklik",
- "wikieditor-publish-dialog-watch": "Bu sayfayı izle",
- "wikieditor-publish-dialog-publish": "Yayınla",
- "wikieditor-publish-dialog-goback": "Geri git",
"wikieditor-toolbar": "Araç çubuğu düzenleme",
"wikieditor-toolbar-desc": "Gelişmiş kullanılabilirlik ile sayfa araç çubuğunu düzenle",
"wikieditor-toolbar-preference": "Gelişmiş düzenleme araç çubuğunu etkinleştir",
- "wikieditor-toolbar-dialogs-preference": "Bağlantılar, tablolar ve daha fazlasını eklemek için iletileri etkinleştir",
"wikieditor-toolbar-loading": "Yükleniyor...",
"wikieditor-toolbar-tool-bold": "Kalın",
"wikieditor-toolbar-tool-bold-example": "Kalın metin",
diff --git a/www/wiki/extensions/WikiEditor/i18n/tt-cyrl.json b/www/wiki/extensions/WikiEditor/i18n/tt-cyrl.json
index 5e94146b..e879fdfc 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tt-cyrl.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tt-cyrl.json
@@ -12,23 +12,9 @@
"wikieditor-desc": "Викитекстны үзгәртү буенча киңәйтелгән интефейс (модулляр тарафынна бирелә)",
"wikieditor-wikitext-tab": "Викитекст",
"wikieditor-loading": "Йөкләү",
- "wikieditor-preview-preference": "Алдан карауны ачу",
- "wikieditor-preview-tab": "Алдан карау",
- "wikieditor-preview-changes-tab": "Үзгәртүләр",
- "wikieditor-preview-loading": "Йөкләү...",
- "wikieditor-publish-preference": "Баскычлы куюны ачу",
- "wikieditor-publish-button-publish": "Чыгарырга",
- "wikieditor-publish-button-cancel": "Кире кагу",
- "wikieditor-publish-dialog-title": " {{SITENAME}} проектына кертергә",
- "wikieditor-publish-dialog-summary": "Үзгәртүләр тасвирламасы (барлык үзгәртүләрне кыска гына иттереп языгыз):",
- "wikieditor-publish-dialog-minor": "Кече үзгәртү",
- "wikieditor-publish-dialog-watch": "Бу битне күзәтү",
- "wikieditor-publish-dialog-publish": "Чыгарырга",
- "wikieditor-publish-dialog-goback": "Артка",
"wikieditor-toolbar": "Төзәтү панеле",
"wikieditor-toolbar-desc": "Яңартылган үзгәртү панеле",
"wikieditor-toolbar-preference": "Яңа үзгәртү панелен куллана башлау",
- "wikieditor-toolbar-dialogs-preference": "Сылтамаларны, табыннар һәм башка җисемнәрне кую остасын ачу",
"wikieditor-toolbar-loading": "Йөкләү...",
"wikieditor-toolbar-tool-bold": "Куе төс",
"wikieditor-toolbar-tool-bold-example": "Калын язылыш",
diff --git a/www/wiki/extensions/WikiEditor/i18n/tyv.json b/www/wiki/extensions/WikiEditor/i18n/tyv.json
index 55e649ec..5166c6d1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tyv.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tyv.json
@@ -8,13 +8,6 @@
},
"wikieditor-wikitext-tab": "Викисөзүглел",
"wikieditor-loading": "Чүдүртүнүп тур...",
- "wikieditor-preview-tab": "Чижеглей көөр",
- "wikieditor-preview-changes-tab": "Өскерилгелер",
- "wikieditor-preview-loading": "Чүдүртүнүп тур...",
- "wikieditor-publish-button-publish": "Үндүр чарлаар",
- "wikieditor-publish-button-cancel": "Ойталал",
- "wikieditor-publish-dialog-publish": "Үндүр чарлаар",
- "wikieditor-publish-dialog-goback": "Дедир",
"wikieditor-toolbar-loading": "Чүдүртүнүп тур...",
"wikieditor-toolbar-tool-bold": "Карарткан",
"wikieditor-toolbar-tool-bold-example": "Карарткан сөзүглел",
diff --git a/www/wiki/extensions/WikiEditor/i18n/tzm.json b/www/wiki/extensions/WikiEditor/i18n/tzm.json
index 6a1c5605..bde479b1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/tzm.json
+++ b/www/wiki/extensions/WikiEditor/i18n/tzm.json
@@ -5,7 +5,6 @@
]
},
"wikieditor-wikitext-tab": "ⵡⵉⴽⵉⴰⴹⵔⵉⵙ",
- "wikieditor-publish-button-publish": "ⴼⵙⴻⵔ",
"wikieditor-toolbar-tool-bold": "Bold",
"wikieditor-toolbar-tool-link": "ⴰⵣⴷⴰⵢ",
"wikieditor-toolbar-tool-link-int": "ⵖⵔ ⵜⴰⵙⵏⴰ ⵏ ⵡⵉⴽⵉ",
diff --git a/www/wiki/extensions/WikiEditor/i18n/udm.json b/www/wiki/extensions/WikiEditor/i18n/udm.json
index 16ab6af2..700750ac 100644
--- a/www/wiki/extensions/WikiEditor/i18n/udm.json
+++ b/www/wiki/extensions/WikiEditor/i18n/udm.json
@@ -4,6 +4,5 @@
"Kaganer"
]
},
- "wikieditor-preview-tab": "Бамез эскерон",
"wikieditor-toolbar-tool-table-preview": "Эскерон"
}
diff --git a/www/wiki/extensions/WikiEditor/i18n/ug-arab.json b/www/wiki/extensions/WikiEditor/i18n/ug-arab.json
index 4507d05c..e5f825d5 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ug-arab.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ug-arab.json
@@ -5,14 +5,6 @@
]
},
"wikieditor-loading": "يۈكلەۋاتىدۇ…",
- "wikieditor-preview-tab": "ئالدىن كۆزەت",
- "wikieditor-preview-changes-tab": "ئۆزگىرىشلەر",
- "wikieditor-preview-loading": "يۈكلەۋاتىدۇ…",
- "wikieditor-publish-button-publish": "ئېلان قىلىش",
- "wikieditor-publish-button-cancel": "ۋاز كەچ",
- "wikieditor-publish-dialog-watch": "بۇ بەتنى كۆزەت",
- "wikieditor-publish-dialog-publish": "ئېلان قىلىش",
- "wikieditor-publish-dialog-goback": "كەينىگە",
"wikieditor-toolbar-loading": "يۈكلەۋاتىدۇ…",
"wikieditor-toolbar-tool-bold": "توم",
"wikieditor-toolbar-tool-bold-example": "توم خەت",
diff --git a/www/wiki/extensions/WikiEditor/i18n/uk.json b/www/wiki/extensions/WikiEditor/i18n/uk.json
index f7b1d269..c6e5961d 100644
--- a/www/wiki/extensions/WikiEditor/i18n/uk.json
+++ b/www/wiki/extensions/WikiEditor/i18n/uk.json
@@ -20,23 +20,9 @@
"wikieditor-desc": "Забезпечує розширюваний інтерфейс редагування вікітексту і багато функціональних модулів",
"wikieditor-wikitext-tab": "Вікітекст",
"wikieditor-loading": "Завантаження…",
- "wikieditor-preview-preference": "Увімкнути додаткову панель швидкого перемикання: \"Редагувати\" — \"Попередній перегляд\"",
- "wikieditor-preview-tab": "Попередній перегляд",
- "wikieditor-preview-changes-tab": "Зміни",
- "wikieditor-preview-loading": "Завантаження…",
- "wikieditor-publish-preference": "Увімкнути публікацію крок за кроком",
- "wikieditor-publish-button-publish": "Опублікувати",
- "wikieditor-publish-button-cancel": "Скасувати",
- "wikieditor-publish-dialog-title": "Опублікувати на {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Опис редагування (короткий опис змін, зроблених вами):",
- "wikieditor-publish-dialog-minor": "Незначне редагування",
- "wikieditor-publish-dialog-watch": "Спостерігати за цією сторінкою",
- "wikieditor-publish-dialog-publish": "Опублікувати",
- "wikieditor-publish-dialog-goback": "Назад",
"wikieditor-toolbar": "Панель засобів редагування",
"wikieditor-toolbar-desc": "Панель засобів редагування з покращеною ужитковістю",
"wikieditor-toolbar-preference": "Увімкнути покращену панель засобів редагування",
- "wikieditor-toolbar-dialogs-preference": "Увімкнути майстри для додавання посилань, таблиць, а також функції пошуку і заміни",
"wikieditor-toolbar-loading": "Завантаження…",
"wikieditor-toolbar-tool-bold": "Жирний",
"wikieditor-toolbar-tool-bold-example": "Жирний текст",
diff --git a/www/wiki/extensions/WikiEditor/i18n/ur.json b/www/wiki/extensions/WikiEditor/i18n/ur.json
index f084f31c..11fd36b4 100644
--- a/www/wiki/extensions/WikiEditor/i18n/ur.json
+++ b/www/wiki/extensions/WikiEditor/i18n/ur.json
@@ -5,29 +5,16 @@
"Ebraminio",
"محبوب عالم",
"පසිඳු කාවින්ද",
- "Muhammad Shuaib"
+ "Muhammad Shuaib",
+ "BukhariSaeed"
]
},
"wikieditor": "ویکی متن کی تدوین کیلئے پیش رفتہ سطح البین",
"wikieditor-desc": "ویکی متن کیلئے تدوینی مواجہہ اور کئی خدوخال دینے والے مطبقیات فراہم کرتا ہے۔",
"wikieditor-wikitext-tab": "ویکی متن",
"wikieditor-loading": "لَدرہا ہے",
- "wikieditor-preview-preference": "پہلو بہ پہلو پیش منظر فعال کرو",
- "wikieditor-preview-tab": "پیش منظر",
- "wikieditor-preview-changes-tab": "تبدیلیاں",
- "wikieditor-preview-loading": "لادرہا ہے۔۔",
- "wikieditor-publish-preference": "قدم بہ قدم شائع کاری فعال کرو",
- "wikieditor-publish-button-publish": "شائع کرو",
- "wikieditor-publish-button-cancel": "منسوخ",
- "wikieditor-publish-dialog-title": "نشر بطرف {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "خلاصۂ تدوین (اپنی کی گئی تبدیلیوں کی مختصر وضاحت کریں):",
- "wikieditor-publish-dialog-minor": "معمولی ترمیم",
- "wikieditor-publish-dialog-watch": "یہ صفحہ زیرِنظر کریں",
- "wikieditor-publish-dialog-publish": "شائع کرو",
- "wikieditor-publish-dialog-goback": "پیچھے جاؤ",
"wikieditor-toolbar": "تدوینی اوزارتختہ",
"wikieditor-toolbar-preference": "ترمیمی خانہ آلات فعال کریں",
- "wikieditor-toolbar-dialogs-preference": "روابط و جدول کے اندراج اور تلاش و تبدیلی متن کی سہولتیں فعال کریں",
"wikieditor-toolbar-loading": "لَدرہا ہے۔۔",
"wikieditor-toolbar-tool-bold": "جلی",
"wikieditor-toolbar-tool-bold-example": "دبیز متن",
@@ -120,7 +107,7 @@
"wikieditor-toolbar-tool-table-preview": "نمائش",
"wikieditor-toolbar-tool-table-insert": "داخل",
"wikieditor-toolbar-tool-table-cancel": "منسوخ",
- "wikieditor-toolbar-tool-table-toomany": "اِس مکالمہ کے ذریعے $1 سے زیادہ خانوں والے جدول کا ادخال ممکن نہیں۔",
+ "wikieditor-toolbar-tool-table-toomany": "اِس مکالمہ کے ذریعے $1 سے زیادہ {{PLURAL:$1|خانوں}} والے جدول کا ادخال ممکن نہیں۔",
"wikieditor-toolbar-tool-table-invalidnumber": "آپ نے قطاروں یا صفوں کا صحیح شمار داخل نہیں کیا۔",
"wikieditor-toolbar-tool-table-zero": "آپ صفر قطاروں یا صفوں کا جدول داخل نہیں کرسکتے۔",
"wikieditor-toolbar-tool-replace": "متن میں تلاش اور تبدیلی",
@@ -134,7 +121,7 @@
"wikieditor-toolbar-tool-replace-button-replaceall": "سب تبدیل کریں",
"wikieditor-toolbar-tool-replace-close": "بند کریں",
"wikieditor-toolbar-tool-replace-nomatch": "آپ کی تلاش سے کچھ ملا نہیں۔",
- "wikieditor-toolbar-tool-replace-success": "$1 تبدیلیاں کی گئیں۔",
+ "wikieditor-toolbar-tool-replace-success": "$1 {{PLURAL:$1|تبدیلی کی گئی|تبدیلیاں کی گئیں}}۔",
"wikieditor-toolbar-tool-replace-emptysearch": "آپ نے تلاش کیلئے کچھ دیا نہیں۔",
"wikieditor-toolbar-section-characters": "خاص محارف",
"wikieditor-toolbar-section-help": "مدد",
@@ -147,7 +134,7 @@
"wikieditor-toolbar-help-page-list": "فہارست",
"wikieditor-toolbar-help-page-file": "ملفات",
"wikieditor-toolbar-help-page-reference": "حوالہ جات",
- "wikieditor-toolbar-help-page-discussion": "تبادلہٴ خیال",
+ "wikieditor-toolbar-help-page-discussion": "تبادلۂ خیال",
"wikieditor-toolbar-help-content-italic-description": "ترچھا",
"wikieditor-toolbar-help-content-italic-syntax": "''ترچھا متن''",
"wikieditor-toolbar-help-content-italic-result": "<em>ترچھا متن</em>",
@@ -178,7 +165,7 @@
"wikieditor-toolbar-help-content-olist-syntax": "# فہرستی مد<br /># فہرستی مد",
"wikieditor-toolbar-help-content-olist-result": "<ol><li>فہرستی مد</li><li>فہرستی مد</li></ol>",
"wikieditor-toolbar-help-content-file-description": "پیوستہ ملف",
- "wikieditor-toolbar-help-content-file-syntax": "[[$1:مثال.png|$2|تعقیبی متن]]",
+ "wikieditor-toolbar-help-content-file-syntax": "[[$1:مثال.png|$2|$3]]",
"wikieditor-toolbar-help-content-reference-description": "حوالہ",
"wikieditor-toolbar-help-content-showreferences-description": "حوالہ جات دکھاؤ",
"wikieditor-toolbar-help-content-signaturetimestamp-description": "دستخط بمع مُہرِوقت",
diff --git a/www/wiki/extensions/WikiEditor/i18n/uz.json b/www/wiki/extensions/WikiEditor/i18n/uz.json
index a128e5f2..02d07592 100644
--- a/www/wiki/extensions/WikiEditor/i18n/uz.json
+++ b/www/wiki/extensions/WikiEditor/i18n/uz.json
@@ -10,23 +10,9 @@
"wikieditor-desc": "Vikimatnni tahrirlashning kengaytirilgan interfeysi va modullar tomonidan taqdim qilinadigan koʻpchilik amallar bilan taʼminlaydi",
"wikieditor-wikitext-tab": "Vikimatn",
"wikieditor-loading": "Yuklash...",
- "wikieditor-preview-preference": "«Yonma-yon» koʻrib chiqish funksiyasini yoqish",
- "wikieditor-preview-tab": "Batafsil koʻrsatish",
- "wikieditor-preview-changes-tab": "Oʻzgarishlar",
- "wikieditor-preview-loading": "Yuklash...",
- "wikieditor-publish-preference": "Qadamba-qadam nashr qilishni yoqish",
- "wikieditor-publish-button-publish": "Nashr qilish",
- "wikieditor-publish-button-cancel": "Bekor qilish",
- "wikieditor-publish-dialog-title": "{{SITENAME}} loyihasida nashr qilish",
- "wikieditor-publish-dialog-summary": "Oʻzgarishlar tavsifi (qanday oʻzgarishlar sodir boʻlganini qisqacha koʻrsating):",
- "wikieditor-publish-dialog-minor": "Kichik oʻzgarish",
- "wikieditor-publish-dialog-watch": "Bu sahifani kuzatish",
- "wikieditor-publish-dialog-publish": "Nashr qilish",
- "wikieditor-publish-dialog-goback": "Orqaga",
"wikieditor-toolbar": "Tahrirlash darchasi",
"wikieditor-toolbar-desc": "Foydalanishga qulayroq boʻlgan tahrirlash darchasi",
"wikieditor-toolbar-preference": "Yaxshilangan tahrirlash darchasini yoqish",
- "wikieditor-toolbar-dialogs-preference": "Havolalar, jadvallar va boshqa obyektlarni qoʻyish uchun dialoglarni yoqish",
"wikieditor-toolbar-loading": "Yuklash...",
"wikieditor-toolbar-tool-bold": "Qalin",
"wikieditor-toolbar-tool-bold-example": "Qalin matn",
diff --git a/www/wiki/extensions/WikiEditor/i18n/vec.json b/www/wiki/extensions/WikiEditor/i18n/vec.json
index ebb40ba1..104c3b2e 100644
--- a/www/wiki/extensions/WikiEditor/i18n/vec.json
+++ b/www/wiki/extensions/WikiEditor/i18n/vec.json
@@ -11,23 +11,9 @@
"wikieditor-desc": "Fornise na interfacia avansada de modifica testo wiki e vari moduli funsionali",
"wikieditor-wikitext-tab": "Testo wiki",
"wikieditor-loading": "Drio cargar...",
- "wikieditor-preview-preference": "Ativa l'anteprima parte par parte",
- "wikieditor-preview-tab": "Anteprima",
- "wikieditor-preview-changes-tab": "Canbiamenti",
- "wikieditor-preview-loading": "So' drio cargar...",
- "wikieditor-publish-preference": "Intaca la publicasion un toco a la olta",
- "wikieditor-publish-button-publish": "Pùblica",
- "wikieditor-publish-button-cancel": "Anula",
- "wikieditor-publish-dialog-title": "Pùblica su {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Somario de la modifica (descrivi brevemente i canbiamenti che te ghè fato):",
- "wikieditor-publish-dialog-minor": "Modifica picenina",
- "wikieditor-publish-dialog-watch": "Tien d'ocio sta pàgina",
- "wikieditor-publish-dialog-publish": "Pùblica",
- "wikieditor-publish-dialog-goback": "Torna indrìo",
"wikieditor-toolbar": "Bara dei strumenti de modifica",
"wikieditor-toolbar-desc": "Modifica bara dei strumenti de la pàgina co na magiore uxabilità",
"wikieditor-toolbar-preference": "Abilita bara dei strumenti de modifica avansada",
- "wikieditor-toolbar-dialogs-preference": "Intacar le finestre par xontar colegamenti, tabèle e la funsion de serca e sostituissi",
"wikieditor-toolbar-loading": "So' drio cargar...",
"wikieditor-toolbar-tool-bold": "Graseto",
"wikieditor-toolbar-tool-bold-example": "Testo in graseto",
diff --git a/www/wiki/extensions/WikiEditor/i18n/vep.json b/www/wiki/extensions/WikiEditor/i18n/vep.json
index 8d05386c..adfde2f1 100644
--- a/www/wiki/extensions/WikiEditor/i18n/vep.json
+++ b/www/wiki/extensions/WikiEditor/i18n/vep.json
@@ -5,12 +5,6 @@
]
},
"wikieditor-wikitext-tab": "Vikitekst",
- "wikieditor-preview-tab": "Ezikacund",
- "wikieditor-preview-changes-tab": "Toižetused",
- "wikieditor-publish-button-publish": "Publikuida",
- "wikieditor-publish-dialog-minor": "Penikaine redakcii",
- "wikieditor-publish-dialog-publish": "Publikuida",
- "wikieditor-publish-dialog-goback": "Tagaze",
"wikieditor-toolbar": "Redaktiruindan panel'",
"wikieditor-toolbar-loading": "Ozutase…",
"wikieditor-toolbar-tool-bold": "Lihavoitud",
diff --git a/www/wiki/extensions/WikiEditor/i18n/vi.json b/www/wiki/extensions/WikiEditor/i18n/vi.json
index 613b3cc3..13687f3c 100644
--- a/www/wiki/extensions/WikiEditor/i18n/vi.json
+++ b/www/wiki/extensions/WikiEditor/i18n/vi.json
@@ -12,19 +12,6 @@
"wikieditor-desc": "Cung cấp giao diện sửa đổi mã wiki có thể mở rộng, cũng như nhiều tính năng khác",
"wikieditor-wikitext-tab": "Mã wiki",
"wikieditor-loading": "Đang tải",
- "wikieditor-preview-preference": "Cho phép so sánh cạnh nhau",
- "wikieditor-preview-tab": "Xem trước",
- "wikieditor-preview-changes-tab": "Các thay đổi",
- "wikieditor-preview-loading": "Đang tải…",
- "wikieditor-publish-preference": "Đăng từng bước một",
- "wikieditor-publish-button-publish": "Đăng",
- "wikieditor-publish-button-cancel": "Hủy bỏ",
- "wikieditor-publish-dialog-title": "Đăng vào {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Tóm lược sửa đổi (miêu tả ngắn gọn các thay đổi của bạn):",
- "wikieditor-publish-dialog-minor": "Sửa đổi nhỏ",
- "wikieditor-publish-dialog-watch": "Theo dõi trang này",
- "wikieditor-publish-dialog-publish": "Đăng",
- "wikieditor-publish-dialog-goback": "Trở lại",
"wikieditor-toolbar": "Thanh công cụ sửa đổi",
"wikieditor-toolbar-desc": "Thanh công cụ ở trang sửa đổi được cải tiến để dễ sử dụng hơn",
"wikieditor-toolbar-preference": "Sử dụng thanh công cụ sửa đổi nâng cao",
diff --git a/www/wiki/extensions/WikiEditor/i18n/vo.json b/www/wiki/extensions/WikiEditor/i18n/vo.json
index 72d61aae..42434c28 100644
--- a/www/wiki/extensions/WikiEditor/i18n/vo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/vo.json
@@ -4,7 +4,6 @@
"Malafaya"
]
},
- "wikieditor-preview-changes-tab": "Votükams",
"wikieditor-toolbar-tool-ilink-example": "Yümatiäd",
"wikieditor-toolbar-tool-link": "Yüm",
"wikieditor-toolbar-tool-link-title": "Läükön yümi",
diff --git a/www/wiki/extensions/WikiEditor/i18n/wo.json b/www/wiki/extensions/WikiEditor/i18n/wo.json
index c6684de1..eb0ac884 100644
--- a/www/wiki/extensions/WikiEditor/i18n/wo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/wo.json
@@ -7,7 +7,6 @@
"wikieditor-toolbar": "Banqaasu jumtukaayu coppite",
"wikieditor-toolbar-desc": "Banqaasu jumtukaayu coppite bees gënal ag jëfandikoom",
"wikieditor-toolbar-preference": "Doxal banqaasu jumtukaayu coppite bees gënal bi",
- "wikieditor-toolbar-dialogs-preference": "Doxal palanteeri duggaluwaayu lëkkalekaay, xaatim ak yeneen",
"wikieditor-toolbar-loading": "Ci yoonu yeb...",
"wikieditor-toolbar-tool-bold": "Duuf",
"wikieditor-toolbar-tool-bold-example": "Mbind mu duuf",
diff --git a/www/wiki/extensions/WikiEditor/i18n/yi.json b/www/wiki/extensions/WikiEditor/i18n/yi.json
index 499baa7f..7ca2a4be 100644
--- a/www/wiki/extensions/WikiEditor/i18n/yi.json
+++ b/www/wiki/extensions/WikiEditor/i18n/yi.json
@@ -6,25 +6,12 @@
]
},
"wikieditor": "פֿארטגעשריטענע וויקיטעקסט רעדאַקטירונג",
- "wikieditor-desc": "פֿאַרברייטבאַרער וויקיטעקס רעדאַקטירונג אויבערפֿלאך מיט א סך מאדולן וואָס פֿאַרזארגן נײַע פֿונקציאנען",
+ "wikieditor-desc": "פֿאַרזארגט א פֿארגעשריטענעם, פֿאַרברייטבאַרן וויקיטעקסט רעדאַקטירונג אייבערפֿלאך",
"wikieditor-wikitext-tab": "וויקיטעקסט",
"wikieditor-loading": "לאָדנדיק",
- "wikieditor-preview-preference": "דערמעגלעכן זייַט-אויף-זייַט פֿאָרויסיקע ווייַזונג",
- "wikieditor-preview-tab": "פֿאראויסשטעלונג",
- "wikieditor-preview-changes-tab": "ענדערונגען",
- "wikieditor-preview-loading": "לאָדט…",
- "wikieditor-publish-button-publish": "פֿאַרעפֿנטלעכן",
- "wikieditor-publish-button-cancel": "אַנולירן",
- "wikieditor-publish-dialog-title": "פארעפנטלעכן אויף {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "רעדאקטירן רעזומע (קורצע באשרייבונג פון אייערע ענדערונגען):",
- "wikieditor-publish-dialog-minor": "מינערדיקער רעדאַקטירונג",
- "wikieditor-publish-dialog-watch": "אויפֿפאַסן אויף דעם בלאַט",
- "wikieditor-publish-dialog-publish": "פֿאַרעפֿנטלעכן",
- "wikieditor-publish-dialog-goback": "צוריקגיין",
"wikieditor-toolbar": "רעדאקטירונג געצייג־פאס",
"wikieditor-toolbar-desc": "רעדאַקטירן בלאַט געצייגפאַס מיט פֿאַרברייטערטער ניצלעכקייט",
"wikieditor-toolbar-preference": "אַקטיווירן פֿאַרברייטערטן רעדאַקטירונג פאַס",
- "wikieditor-toolbar-dialogs-preference": "דערמעגלעכן אסיסטאנטן פֿאַר אַרײַנלייגן לינקען, טאַבעלעס ווי אויך די זוכן און פֿאַרבײַטן פֿונקציע.",
"wikieditor-toolbar-loading": "אָנלאָדן...",
"wikieditor-toolbar-tool-bold": "דיק",
"wikieditor-toolbar-tool-bold-example": "דיקער טעקסט",
diff --git a/www/wiki/extensions/WikiEditor/i18n/yo.json b/www/wiki/extensions/WikiEditor/i18n/yo.json
index 68577497..04d71a3b 100644
--- a/www/wiki/extensions/WikiEditor/i18n/yo.json
+++ b/www/wiki/extensions/WikiEditor/i18n/yo.json
@@ -7,23 +7,9 @@
},
"wikieditor-wikitext-tab": "Ìkọ wiki",
"wikieditor-loading": "Úngbéyọ",
- "wikieditor-preview-preference": "Ìgbàláyè àyẹ̀wò lẹ́gbẹ̀ẹ́ ara wọn",
- "wikieditor-preview-tab": "Àyẹ̀wò",
- "wikieditor-preview-changes-tab": "Àwọn àtúnṣe",
- "wikieditor-preview-loading": "Óúnbọ̀wá...",
- "wikieditor-publish-preference": "Ìgbàláyè ìtẹ̀jáde lẹ́sẹ-sẹ",
- "wikieditor-publish-button-publish": "Ìtẹ̀jáde",
- "wikieditor-publish-button-cancel": "Fagilé",
- "wikieditor-publish-dialog-title": "Ìtẹ̀jáde sí {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "Àkótán àtúnṣe (àlàyé ní sókí àtúnṣe tí ẹ ṣe):",
- "wikieditor-publish-dialog-minor": "Àtúnṣe kékeré",
- "wikieditor-publish-dialog-watch": "M'ójútó ojúewé yìí",
- "wikieditor-publish-dialog-publish": "Ìtẹ̀jáde",
- "wikieditor-publish-dialog-goback": "Padà sẹ́yìn",
"wikieditor-toolbar": "Àtúnṣe sí pẹpẹ irinṣẹ́",
"wikieditor-toolbar-desc": "Àtúnṣe ojúewé pẹpẹ irinṣẹ́ pẹ̀lú ìṣeémúlò amúdára",
"wikieditor-toolbar-preference": "Ìgbàláyè pẹpẹ irinṣẹ́ àtúnṣe mímúdára",
- "wikieditor-toolbar-dialogs-preference": "Ìgbàláyè àwọn pátákó àkíyèsí fún ìkìbọ̀ ìjápọ̀, tábìlì àti bẹ́ẹ̀bẹ́ẹ̀ lọ",
"wikieditor-toolbar-loading": "Óúnbọ̀wá...",
"wikieditor-toolbar-tool-bold": "Kedere",
"wikieditor-toolbar-tool-bold-example": "Ìkọ kedere",
@@ -57,6 +43,7 @@
"wikieditor-toolbar-tool-link-empty": "Ẹ kò kọ ùnkankan láti jápọ̀ mọ́.",
"wikieditor-toolbar-tool-file": "Fáìlì alákòósínú",
"wikieditor-toolbar-tool-file-example": "Àpẹrẹ.jpg",
+ "wikieditor-toolbar-file-target": "Orúkọ fáìlì:",
"wikieditor-toolbar-tool-reference": "Ìtọ́kasí",
"wikieditor-toolbar-tool-reference-example": "Ìkìbọ ìkọ ìkíyésí níbí",
"wikieditor-toolbar-tool-reference-cancel": "Fagilé",
diff --git a/www/wiki/extensions/WikiEditor/i18n/yue.json b/www/wiki/extensions/WikiEditor/i18n/yue.json
index a237aa91..46d5b5ef 100644
--- a/www/wiki/extensions/WikiEditor/i18n/yue.json
+++ b/www/wiki/extensions/WikiEditor/i18n/yue.json
@@ -14,23 +14,9 @@
"wikieditor-desc": "提供一個可以展開嘅維基文字編輯界面同埋好多其他特色嘅模組",
"wikieditor-wikitext-tab": "維基文字",
"wikieditor-loading": "載入緊",
- "wikieditor-preview-preference": "用side-by-side預覽功能",
- "wikieditor-preview-tab": "預覽",
- "wikieditor-preview-changes-tab": "改動",
- "wikieditor-preview-loading": "載入緊…",
- "wikieditor-publish-preference": "啟用一步還一步嘅發佈功能",
- "wikieditor-publish-button-publish": "發佈",
- "wikieditor-publish-button-cancel": "取消",
- "wikieditor-publish-dialog-title": "發佈去{{SITENAME}}",
- "wikieditor-publish-dialog-summary": "摘要 (簡單講下你改左咩)",
- "wikieditor-publish-dialog-minor": "小編輯",
- "wikieditor-publish-dialog-watch": "睇實呢一頁",
- "wikieditor-publish-dialog-publish": "發佈",
- "wikieditor-publish-dialog-goback": "番去",
"wikieditor-toolbar": "編輯工具列",
"wikieditor-toolbar-desc": "加強可用性嘅編輯版工具",
"wikieditor-toolbar-preference": "開着加強編輯工具列",
- "wikieditor-toolbar-dialogs-preference": "啟用信息框去提供插入連結同表格等嘅幫助",
"wikieditor-toolbar-loading": "載入緊...",
"wikieditor-toolbar-tool-bold": "粗體",
"wikieditor-toolbar-tool-bold-example": "粗體字",
diff --git a/www/wiki/extensions/WikiEditor/i18n/zh-hans.json b/www/wiki/extensions/WikiEditor/i18n/zh-hans.json
index 30406645..7b352eb3 100644
--- a/www/wiki/extensions/WikiEditor/i18n/zh-hans.json
+++ b/www/wiki/extensions/WikiEditor/i18n/zh-hans.json
@@ -17,26 +17,12 @@
]
},
"wikieditor": "高级维基文本编辑界面",
- "wikieditor-desc": "提供可扩充的维基文本编辑界面及功能组件",
- "wikieditor-wikitext-tab": "维基文本",
+ "wikieditor-desc": "提供高级、可扩充的wiki文本编辑界面",
+ "wikieditor-wikitext-tab": "Wiki文本",
"wikieditor-loading": "正在载入……",
- "wikieditor-preview-preference": "启用双列对比预览",
- "wikieditor-preview-tab": "预览",
- "wikieditor-preview-changes-tab": "更改",
- "wikieditor-preview-loading": "正在载入...",
- "wikieditor-publish-preference": "启用逐步发表功能",
- "wikieditor-publish-button-publish": "发布",
- "wikieditor-publish-button-cancel": "取消",
- "wikieditor-publish-dialog-title": "发表到{{SITENAME}}",
- "wikieditor-publish-dialog-summary": "编辑摘要(请简要描述您作出的更改):",
- "wikieditor-publish-dialog-minor": "小编辑",
- "wikieditor-publish-dialog-watch": "监视本页",
- "wikieditor-publish-dialog-publish": "发布",
- "wikieditor-publish-dialog-goback": "后退",
"wikieditor-toolbar": "编辑工具栏",
"wikieditor-toolbar-desc": "有增强的使用性能的页面编辑工具栏",
"wikieditor-toolbar-preference": "启用增强的编辑工具栏",
- "wikieditor-toolbar-dialogs-preference": "启用插入链接表格向导及查找和替换功能",
"wikieditor-toolbar-loading": "正在载入……",
"wikieditor-toolbar-tool-bold": "粗体",
"wikieditor-toolbar-tool-bold-example": "粗体文字",
diff --git a/www/wiki/extensions/WikiEditor/i18n/zh-hant.json b/www/wiki/extensions/WikiEditor/i18n/zh-hant.json
index b9dfa159..64779a0a 100644
--- a/www/wiki/extensions/WikiEditor/i18n/zh-hant.json
+++ b/www/wiki/extensions/WikiEditor/i18n/zh-hant.json
@@ -25,27 +25,13 @@
"Black9869184"
]
},
- "wikieditor": "進階 Wiki 文字編輯介面",
+ "wikieditor": "進階 wikitext 編輯介面",
"wikieditor-desc": "提供 Wiki 文字編輯介面擴充功能及相關模組",
- "wikieditor-wikitext-tab": "Wiki 文字",
+ "wikieditor-wikitext-tab": "Wikitext",
"wikieditor-loading": "讀取中...",
- "wikieditor-preview-preference": "開啟並排預覽",
- "wikieditor-preview-tab": "預覽",
- "wikieditor-preview-changes-tab": "變更",
- "wikieditor-preview-loading": "讀取中...",
- "wikieditor-publish-preference": "開啟發佈協助功能",
- "wikieditor-publish-button-publish": "發佈",
- "wikieditor-publish-button-cancel": "取消",
- "wikieditor-publish-dialog-title": "發佈至 {{SITENAME}}",
- "wikieditor-publish-dialog-summary": "編輯摘要 (簡要描述您編輯的內容):",
- "wikieditor-publish-dialog-minor": "小修改",
- "wikieditor-publish-dialog-watch": "監視本頁",
- "wikieditor-publish-dialog-publish": "發佈",
- "wikieditor-publish-dialog-goback": "返回",
"wikieditor-toolbar": "編輯工具列",
"wikieditor-toolbar-desc": "使編輯頁面更簡單的頁面工具列",
"wikieditor-toolbar-preference": "開啟進階編輯工具列",
- "wikieditor-toolbar-dialogs-preference": "開啟插入連結、表格、搜尋與取代的協助功能",
"wikieditor-toolbar-loading": "讀取中...",
"wikieditor-toolbar-tool-bold": "粗體",
"wikieditor-toolbar-tool-bold-example": "粗體文字",
@@ -57,7 +43,7 @@
"wikieditor-toolbar-tool-xlink-example": "http://www.example.com 連結標題",
"wikieditor-toolbar-tool-link": "連結",
"wikieditor-toolbar-tool-link-title": "插入連結",
- "wikieditor-toolbar-tool-link-int": "連結 Wiki 頁面",
+ "wikieditor-toolbar-tool-link-int": "連至 wiki 頁面",
"wikieditor-toolbar-tool-link-int-target": "目標頁面或網址:",
"wikieditor-toolbar-tool-link-int-target-tooltip": "頁面標題或 URL",
"wikieditor-toolbar-tool-link-int-text": "顯示文字:",
diff --git a/www/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php b/www/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php
new file mode 100644
index 00000000..27f4e4aa
--- /dev/null
+++ b/www/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php
@@ -0,0 +1,332 @@
+<?php
+/**
+ * Hooks for WikiEditor extension
+ *
+ * @file
+ * @ingroup Extensions
+ */
+
+class WikiEditorHooks {
+ // ID used for grouping entries all of a session's entries together in
+ // EventLogging.
+ private static $statsId = false;
+
+ /* Static Methods */
+
+ /**
+ * Log stuff to EventLogging's Schema:Edit - see https://meta.wikimedia.org/wiki/Schema:Edit
+ * If you don't have EventLogging installed, does nothing.
+ *
+ * @param string $action
+ * @param Article $article Which article (with full context, page, title, etc.)
+ * @param array $data Data to log for this action
+ * @return bool Whether the event was logged or not.
+ */
+ public static function doEventLogging( $action, $article, $data = [] ) {
+ global $wgVersion;
+ if ( !class_exists( 'EventLogging' ) ) {
+ return false;
+ }
+ // Sample 6.25% (via hex digit)
+ if ( $data['editingSessionId'][0] > '0' ) {
+ return false;
+ }
+
+ $user = $article->getContext()->getUser();
+ $page = $article->getPage();
+ $title = $article->getTitle();
+
+ $data = [
+ 'action' => $action,
+ 'version' => 1,
+ 'editor' => 'wikitext',
+ 'platform' => 'desktop', // FIXME
+ 'integration' => 'page',
+ 'page.id' => $page->getId(),
+ 'page.title' => $title->getPrefixedText(),
+ 'page.ns' => $title->getNamespace(),
+ 'page.revid' => $page->getRevision() ? $page->getRevision()->getId() : 0,
+ 'user.id' => $user->getId(),
+ 'user.editCount' => $user->getEditCount() ?: 0,
+ 'mediawiki.version' => $wgVersion
+ ] + $data;
+
+ if ( $user->isAnon() ) {
+ $data['user.class'] = 'IP';
+ }
+
+ return EventLogging::logEvent( 'Edit', 13457736, $data );
+ }
+
+ /**
+ * EditPage::showEditForm:initial hook
+ *
+ * Adds the modules to the edit form
+ *
+ * @param EditPage $editPage the current EditPage object.
+ * @param OutputPage $outputPage object.
+ * @return bool
+ */
+ public static function editPageShowEditFormInitial( EditPage $editPage, OutputPage $outputPage ) {
+ if ( $editPage->contentModel !== CONTENT_MODEL_WIKITEXT ) {
+ return true;
+ }
+
+ $article = $editPage->getArticle();
+ $request = $article->getContext()->getRequest();
+
+ // Add modules if enabled
+ $user = $article->getContext()->getUser();
+ if ( $user->getOption( 'usebetatoolbar' ) ) {
+ $outputPage->addModuleStyles( 'ext.wikiEditor.styles' );
+ $outputPage->addModules( 'ext.wikiEditor' );
+ }
+
+ // Don't run this if the request was posted - we don't want to log 'init' when the
+ // user just pressed 'Show preview' or 'Show changes', or switched from VE keeping
+ // changes.
+ if ( class_exists( 'EventLogging' ) && !$request->wasPosted() ) {
+ $data = [];
+ $data['editingSessionId'] = self::getEditingStatsId();
+ if ( $request->getVal( 'section' ) ) {
+ $data['action.init.type'] = 'section';
+ } else {
+ $data['action.init.type'] = 'page';
+ }
+ if ( $request->getHeader( 'Referer' ) ) {
+ if ( $request->getVal( 'section' ) === 'new' || !$article->exists() ) {
+ $data['action.init.mechanism'] = 'new';
+ } else {
+ $data['action.init.mechanism'] = 'click';
+ }
+ } else {
+ $data['action.init.mechanism'] = 'url';
+ }
+
+ self::doEventLogging( 'init', $article, $data );
+ }
+
+ return true;
+ }
+
+ /**
+ * EditPage::showEditForm:fields hook
+ *
+ * Adds the event fields to the edit form
+ *
+ * @param EditPage $editPage the current EditPage object.
+ * @param OutputPage $outputPage object.
+ * @return bool
+ */
+ public static function editPageShowEditFormFields( EditPage $editPage, OutputPage $outputPage ) {
+ if ( $editPage->contentModel !== CONTENT_MODEL_WIKITEXT ) {
+ return true;
+ }
+
+ $req = $outputPage->getRequest();
+ $editingStatsId = $req->getVal( 'editingStatsId' );
+ if ( !$editingStatsId || !$req->wasPosted() ) {
+ $editingStatsId = self::getEditingStatsId();
+ }
+
+ $outputPage->addHTML(
+ Xml::element(
+ 'input',
+ [
+ 'type' => 'hidden',
+ 'name' => 'editingStatsId',
+ 'id' => 'editingStatsId',
+ 'value' => $editingStatsId
+ ]
+ )
+ );
+ return true;
+ }
+
+ /**
+ * EditPageBeforeEditToolbar hook
+ *
+ * Disable the old toolbar if the new one is enabled
+ *
+ * @param string &$toolbar
+ * @return bool
+ */
+ public static function EditPageBeforeEditToolbar( &$toolbar ) {
+ global $wgUser;
+ if ( $wgUser->getOption( 'usebetatoolbar' ) ) {
+ $toolbar = '';
+ // Return false to signify that the toolbar has been over-written, so
+ // the old toolbar code shouldn't be added to the page.
+ return false;
+ }
+ return true;
+ }
+
+ /**
+ * GetPreferences hook
+ *
+ * Adds WikiEditor-related items to the preferences
+ *
+ * @param User $user current user
+ * @param array &$defaultPreferences list of default user preference controls
+ * @return bool
+ */
+ public static function getPreferences( $user, &$defaultPreferences ) {
+ // Ideally this key would be 'wikieditor-toolbar'
+ $defaultPreferences['usebetatoolbar'] = [
+ 'type' => 'toggle',
+ 'label-message' => 'wikieditor-toolbar-preference',
+ 'section' => 'editing/editor',
+ ];
+
+ return true;
+ }
+
+ /**
+ * @param array &$vars
+ * @return bool
+ */
+ public static function resourceLoaderGetConfigVars( &$vars ) {
+ // expose magic words for use by the wikieditor toolbar
+ self::getMagicWords( $vars );
+
+ $vars['mw.msg.wikieditor'] = wfMessage( 'sig-text', '~~~~' )->inContentLanguage()->text();
+
+ return true;
+ }
+
+ /**
+ * ResourceLoaderTestModules hook
+ *
+ * Registers JavaScript test modules
+ *
+ * @param array &$testModules array of javascript testing modules. 'qunit' is fed using
+ * tests/qunit/QUnitTestResources.php.
+ * @param ResourceLoader &$resourceLoader
+ * @return bool
+ */
+ public static function resourceLoaderTestModules( &$testModules, &$resourceLoader ) {
+ $testModules['qunit']['ext.wikiEditor.toolbar.test'] = [
+ 'scripts' => [ 'tests/qunit/ext.wikiEditor.toolbar.test.js' ],
+ 'dependencies' => [ 'ext.wikiEditor' ],
+ 'localBasePath' => __DIR__ . '/..',
+ 'remoteExtPath' => 'WikiEditor',
+ ];
+ return true;
+ }
+
+ /**
+ * MakeGlobalVariablesScript hook
+ *
+ * Adds enabled/disabled switches for WikiEditor modules
+ * @param array &$vars
+ * @return bool
+ */
+ public static function makeGlobalVariablesScript( &$vars ) {
+ // Build and export old-style wgWikiEditorEnabledModules object for back compat
+ $vars['wgWikiEditorEnabledModules'] = [];
+ return true;
+ }
+
+ /**
+ * Expose useful magic words which are used by the wikieditor toolbar
+ * @param array &$vars
+ * @return bool
+ */
+ private static function getMagicWords( &$vars ) {
+ $requiredMagicWords = [
+ 'redirect',
+ 'img_right',
+ 'img_left',
+ 'img_none',
+ 'img_center',
+ 'img_thumbnail',
+ 'img_framed',
+ 'img_frameless',
+ ];
+ $magicWords = [];
+ foreach ( $requiredMagicWords as $name ) {
+ $magicWords[$name] = MagicWord::get( $name )->getSynonym( 0 );
+ }
+ $vars['wgWikiEditorMagicWords'] = $magicWords;
+ return true;
+ }
+
+ /**
+ * Gets a 32 character alphanumeric random string to be used for stats.
+ * @return string
+ */
+ private static function getEditingStatsId() {
+ if ( !self::$statsId ) {
+ self::$statsId = MWCryptRand::generateHex( 32 );
+ }
+ return self::$statsId;
+ }
+
+ /**
+ * This is attached to the MediaWiki 'EditPage::attemptSave' hook.
+ *
+ * @param EditPage $editPage
+ * @return bool
+ */
+ public static function editPageAttemptSave( EditPage $editPage ) {
+ $article = $editPage->getArticle();
+ $request = $article->getContext()->getRequest();
+ if ( $request->getVal( 'editingStatsId' ) ) {
+ self::doEventLogging(
+ 'saveAttempt',
+ $article,
+ [ 'editingSessionId' => $request->getVal( 'editingStatsId' ) ]
+ );
+ }
+
+ return true;
+ }
+
+ /**
+ * This is attached to the MediaWiki 'EditPage::attemptSave:after' hook.
+ *
+ * @param EditPage $editPage
+ * @param Status $status
+ * @return bool
+ */
+ public static function editPageAttemptSaveAfter( EditPage $editPage, Status $status ) {
+ $article = $editPage->getArticle();
+ $request = $article->getContext()->getRequest();
+ if ( $request->getVal( 'editingStatsId' ) ) {
+ $data = [];
+ $data['editingSessionId'] = $request->getVal( 'editingStatsId' );
+
+ if ( $status->isOK() ) {
+ $action = 'saveSuccess';
+ } else {
+ $action = 'saveFailure';
+ $errors = $status->getErrorsArray();
+
+ if ( isset( $errors[0][0] ) ) {
+ $data['action.saveFailure.message'] = $errors[0][0];
+ }
+
+ if ( $status->value === EditPage::AS_CONFLICT_DETECTED ) {
+ $data['action.saveFailure.type'] = 'editConflict';
+ } elseif ( $status->value === EditPage::AS_ARTICLE_WAS_DELETED ) {
+ $data['action.saveFailure.type'] = 'editPageDeleted';
+ } elseif ( isset( $errors[0][0] ) && $errors[0][0] === 'abusefilter-disallowed' ) {
+ $data['action.saveFailure.type'] = 'extensionAbuseFilter';
+ } elseif ( isset( $editPage->getArticle()->getPage()->ConfirmEdit_ActivateCaptcha ) ) {
+ // TODO: :(
+ $data['action.saveFailure.type'] = 'extensionCaptcha';
+ } elseif ( isset( $errors[0][0] ) && $errors[0][0] === 'spamprotectiontext' ) {
+ $data['action.saveFailure.type'] = 'extensionSpamBlacklist';
+ } else {
+ // Catch everything else... We don't seem to get userBadToken or
+ // userNewUser through this hook.
+ $data['action.saveFailure.type'] = 'responseUnknown';
+ }
+ }
+ self::doEventLogging( $action, $article, $data );
+ }
+
+ return true;
+ }
+}
diff --git a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.dialogs.js b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.dialogs.js
index 271c170e..13972ddb 100644
--- a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.dialogs.js
+++ b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.dialogs.js
@@ -2,10 +2,6 @@
* JavaScript for WikiEditor Dialogs
*/
jQuery( function ( $ ) {
- if ( !$.wikiEditor.isSupported( $.wikiEditor.modules.dialogs ) ) {
- return;
- }
-
// Replace icons
$.wikiEditor.modules.dialogs.config.replaceIcons( $( '#wpTextbox1' ) );
diff --git a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.js b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.js
index 33278e05..3defae4e 100644
--- a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.js
+++ b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.js
@@ -58,9 +58,24 @@
if ( $editingSessionIdInput.length ) {
editingSessionId = $editingSessionIdInput.val();
- logEditEvent( 'ready', {
- editingSessionId: editingSessionId
- } );
+ if ( window.performance && window.performance.timing ) {
+ // We want to track from the time the user started to try to
+ // launch the editor which navigationStart approximates. All
+ // of our supported browsers *should* allow this. Rather than
+ // fall back to the timestamp when the page loaded for those
+ // that don't, we just ignore them, so as to not skew the
+ // results towards better-performance in those cases.
+ logEditEvent( 'ready', {
+ editingSessionId: editingSessionId,
+ timing: Date.now() - window.performance.timing.navigationStart
+ } );
+ $textarea.on( 'wikiEditor-toolbar-doneInitialSections', function () {
+ logEditEvent( 'loaded', {
+ editingSessionId: editingSessionId,
+ timing: Date.now() - window.performance.timing.navigationStart
+ } );
+ } );
+ }
$textarea.closest( 'form' ).submit( function () {
submitting = true;
} );
diff --git a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.js b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.js
index df0400d6..0c38d40e 100644
--- a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.js
+++ b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.js
@@ -2,10 +2,6 @@
* JavaScript for WikiEditor Toolbar
*/
jQuery( function ( $ ) {
- if ( !$.wikiEditor.isSupported( $.wikiEditor.modules.toolbar ) ) {
- $( '.wikiEditor-oldToolbar' ).show();
- return;
- }
// The old toolbar is still in place and needs to be removed so there aren't two toolbars
$( '#toolbar' ).remove();
// Add toolbar module
diff --git a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.styles.less b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.styles.less
index 1011e55b..da93bfaa 100644
--- a/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.styles.less
+++ b/www/wiki/extensions/WikiEditor/modules/ext.wikiEditor.toolbar.styles.less
@@ -4,13 +4,12 @@
/* Hide vanilla MediaWiki's "Editing help" link, as we provide it in the toolbar */
.client-js .editButtons {
- .editHelp,
- .mw-editButtons-pipe-separator {
+ .editHelp {
display: none;
}
}
-/* stylelint-disable selector-no-id */
+/* stylelint-disable selector-max-id */
form#editform {
margin: 0;
@@ -22,9 +21,7 @@ form#editform {
resize: vertical;
}
-/* Hide the old toolbar until the wikiEditor toolbar is deemed not supported,
- * hide the WikiEditor toolbar until it's css has loaded */
-.wikiEditor-oldToolbar,
+/* Hide the WikiEditor toolbar until its css has loaded */
.wikiEditor-ui-toolbar {
display: none;
}
@@ -38,7 +35,7 @@ form#editform {
/* Set a margin on the textarea while we load, matching the height,
* of the wikieditor toolbar to prevent reflow. After the wikieditor ui is loaded,
* the textarea is wrapped inside wikieditor-ui div and no longer matches */
-.client-js .wikiEditor-oldToolbar + #wpTextbox1 {
+.client-js .mw-editform > #wpTextbox1 {
/* Toolbar height + padding + bottom border = 26 + 2*3 + 1 */
margin-top: 33px;
}
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.js b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.js
index ccbcead8..c8d329f8 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.js
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.js
@@ -9,11 +9,6 @@
replaceIcons: function ( $textarea ) {
$textarea
- .wikiEditor( 'removeFromToolbar', { section: 'main', group: 'insert', tool: 'xlink' } )
- .wikiEditor( 'removeFromToolbar', { section: 'main', group: 'insert', tool: 'ilink' } )
- .wikiEditor( 'removeFromToolbar', { section: 'main', group: 'insert', tool: 'file' } )
- .wikiEditor( 'removeFromToolbar', { section: 'main', group: 'insert', tool: 'reference' } )
- .wikiEditor( 'removeFromToolbar', { section: 'advanced', group: 'insert', tool: 'table' } )
.wikiEditor( 'addToToolbar', {
section: 'main',
group: 'insert',
@@ -21,8 +16,7 @@
link: {
labelMsg: 'wikieditor-toolbar-tool-link',
type: 'button',
- icon: 'insert-link.png',
- offset: [ 2, -1654 ],
+ oouiIcon: 'link',
action: {
type: 'dialog',
module: 'insert-link'
@@ -31,8 +25,7 @@
file: {
labelMsg: 'wikieditor-toolbar-tool-file',
type: 'button',
- icon: 'insert-file.png',
- offset: [ 2, -1438 ],
+ oouiIcon: 'image',
action: {
type: 'dialog',
module: 'insert-file'
@@ -42,8 +35,7 @@
labelMsg: 'wikieditor-toolbar-tool-reference',
filters: [ 'body.ns-subject' ],
type: 'button',
- icon: 'insert-reference.png',
- offset: [ 2, -1798 ],
+ oouiIcon: 'book',
action: {
type: 'dialog',
module: 'insert-reference'
@@ -58,8 +50,7 @@
table: {
labelMsg: 'wikieditor-toolbar-tool-table',
type: 'button',
- icon: 'insert-table.png',
- offset: [ 2, -1942 ],
+ oouiIcon: 'table',
action: {
type: 'dialog',
module: 'insert-table'
@@ -75,8 +66,7 @@
replace: {
labelMsg: 'wikieditor-toolbar-tool-replace',
type: 'button',
- icon: 'search-replace.png',
- offset: [ -70, -214 ],
+ oouiIcon: 'find',
action: {
type: 'dialog',
module: 'search-and-replace'
@@ -115,7 +105,7 @@
}
// Updates the status indicator above the target link
- function updateWidget( status ) {
+ function updateWidget( status, reason ) {
$( '#wikieditor-toolbar-link-int-target-status' ).children().hide();
$( '#wikieditor-toolbar-link-int-target' ).parent()
.removeClass(
@@ -129,6 +119,13 @@
$( '.ui-dialog:visible .ui-dialog-buttonpane button:first' )
.prop( 'disabled', true )
.addClass( 'disabled' );
+ if ( reason ) {
+ $( '#wikieditor-toolbar-link-int-target-status-invalid' ).html( reason );
+ } else {
+ $( '#wikieditor-toolbar-link-int-target-status-invalid' )
+ .text( mw.msg( 'wikieditor-toolbar-tool-link-int-target-status-invalid' ) );
+ }
+
} else {
$( '.ui-dialog:visible .ui-dialog-buttonpane button:first' )
.prop( 'disabled', false )
@@ -142,7 +139,8 @@
// Abort previous request
var request = $( '#wikieditor-toolbar-link-int-target-status' ).data( 'request' ),
target = $( '#wikieditor-toolbar-link-int-target' ).val(),
- cache = $( '#wikieditor-toolbar-link-int-target-status' ).data( 'existencecache' );
+ cache = $( '#wikieditor-toolbar-link-int-target-status' ).data( 'existencecache' ),
+ reasoncache = $( '#wikieditor-toolbar-link-int-target-status' ).data( 'reasoncache' );
// ensure the internal parameter is a boolean
if ( internal !== true ) {
internal = false;
@@ -151,7 +149,7 @@
request.abort();
}
if ( hasOwn.call( cache, target ) ) {
- updateWidget( cache[ target ] );
+ updateWidget( cache[ target ], reasoncache[ target ] );
return;
}
if ( target.replace( /^\s+$/, '' ) === '' ) {
@@ -164,12 +162,6 @@
updateWidget( 'external' );
return;
}
- if ( target.indexOf( '|' ) !== -1 ) {
- // Title contains | , which means it's invalid
- // but confuses the API. Show invalid and bypass API
- updateWidget( 'invalid' );
- return;
- }
// Show loading spinner while waiting for the API to respond
updateWidget( 'loading' );
// Call the API to check page status, saving the request object so it can be aborted if
@@ -183,10 +175,12 @@
formatversion: 2,
action: 'query',
prop: 'pageprops',
- titles: target,
- ppprop: 'disambiguation'
+ titles: [ target ],
+ ppprop: 'disambiguation',
+ errorformat: 'html',
+ errorlang: mw.config.get( 'wgUserLanguage' )
} ).done( function ( data ) {
- var status, page;
+ var status, page, reason = null;
if ( !data.query || !data.query.pages ) {
// This happens in some weird cases like interwiki links
status = false;
@@ -197,6 +191,7 @@
status = 'notexists';
} else if ( page.invalid ) {
status = 'invalid';
+ reason = page.invalidreason && page.invalidreason.html;
} else if ( page.pageprops ) {
status = 'disambig';
}
@@ -205,8 +200,9 @@
// parameter was not passed
if ( !internal ) {
cache[ target ] = status;
+ reasoncache[ target ] = reason;
}
- updateWidget( status );
+ updateWidget( status, reason );
} )
);
}
@@ -321,7 +317,6 @@
)
.append( $( '<div>' )
.attr( 'id', 'wikieditor-toolbar-link-int-target-status-invalid' )
- .text( mw.msg( 'wikieditor-toolbar-tool-link-int-target-status-invalid' ) )
)
.append( $( '<div>' )
.attr( 'id', 'wikieditor-toolbar-link-int-target-status-external' )
@@ -336,6 +331,7 @@
.text( mw.msg( 'wikieditor-toolbar-tool-link-int-target-status-disambig' ) )
)
.data( 'existencecache', {} )
+ .data( 'reasoncache', {} )
.children().hide();
$( '#wikieditor-toolbar-link-int-target' )
@@ -383,8 +379,7 @@
search: title,
namespace: 0,
suggest: ''
- } )
- .done( function ( data ) {
+ } ).done( function ( data ) {
cache[ title ] = data[ 1 ];
$( that ).suggestions( 'suggestions', data[ 1 ] );
} );
@@ -531,7 +526,7 @@
$( '#wikieditor-toolbar-link-int-target' ).change();
$( '#wikieditor-toolbar-link-dialog' ).data( 'whitespace', [ '', '' ] );
if ( selection !== '' ) {
- if ( ( matches = selection.match( /^(\s*)\[\[([^\]\|]+)(\|([^\]\|]*))?\]\](\s*)$/ ) ) ) {
+ if ( ( matches = selection.match( /^(\s*)\[\[([^\]|]+)(\|([^\]|]*))?\]\](\s*)$/ ) ) ) {
// [[foo|bar]] or [[foo]]
target = matches[ 2 ];
text = ( matches[ 4 ] ? matches[ 4 ] : matches[ 2 ] );
@@ -663,7 +658,7 @@
.data( 'whitespace', [ '', '' ] )
.data( 'attributes', '' );
if ( selection !== '' ) {
- if ( ( matches = selection.match( /^(\s*)<ref([^\>]*)>([^<]*)<\/ref\>(\s*)$/ ) ) ) {
+ if ( ( matches = selection.match( /^(\s*)<ref([^>]*)>([^<]*)<\/ref>(\s*)$/ ) ) ) {
text = matches[ 3 ];
// Preserve whitespace when replacing
$( '#wikieditor-toolbar-reference-dialog' )
@@ -702,24 +697,20 @@
init: function () {
var magicWordsI18N = mw.config.get( 'wgWikiEditorMagicWords' ),
defaultMsg = mw.msg( 'wikieditor-toolbar-file-default' );
- $( this )
- .find( '[data-i18n-magic]' )
- .text( function () {
- return magicWordsI18N[ $( this ).attr( 'data-i18n-magic' ) ];
- } )
- .removeAttr( 'data-i18n-magic' )
- .end()
- .find( '#wikieditor-toolbar-file-size' )
- .attr( 'placeholder', defaultMsg )
- // The message may be long in some languages
- .attr( 'size', defaultMsg.length )
- .end()
- .find( '[rel]' )
- .text( function () {
- return mw.msg( $( this ).attr( 'rel' ) );
- } )
- .removeAttr( 'rel' )
- .end();
+ $( this ).find( '[data-i18n-magic]' )
+ .text( function () {
+ return magicWordsI18N[ $( this ).attr( 'data-i18n-magic' ) ];
+ } )
+ .removeAttr( 'data-i18n-magic' );
+ $( this ).find( '#wikieditor-toolbar-file-size' )
+ .attr( 'placeholder', defaultMsg )
+ // The message may be long in some languages
+ .attr( 'size', defaultMsg.length );
+ $( this ).find( '[rel]' )
+ .text( function () {
+ return mw.msg( $( this ).attr( 'rel' ) );
+ } )
+ .removeAttr( 'rel' );
},
dialog: {
resizable: false,
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.less b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.less
index d98aee2e..f95a7c26 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.less
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.config.less
@@ -4,7 +4,7 @@
* CSS for WikiEditor Dialogs
*/
-/* stylelint-disable selector-no-id */
+/* stylelint-disable selector-max-id */
/* Replace Dialog */
#wikieditor-toolbar-replace-search,
@@ -57,7 +57,7 @@
}
.ui-dialog-buttonpane {
- border-top: 1px solid #ccc !important;
+ border-top: 1px solid #c8ccd1 !important;
}
}
/* stylelint-enable declaration-no-important */
@@ -200,7 +200,7 @@ body.rtl {
.wikiEditor-template-dialog-field-wrapper {
padding: 0.75em 0.33em;
- border-bottom: 1px dashed #c0c0c0;
+ border-bottom: 1px dashed #c8ccd1;
clear: both;
&:first-child {
@@ -243,16 +243,3 @@ body.rtl {
.wikiEditor-dialog-editoptions {
margin-top: 15px;
}
-
-/* Publish dialog */
-.wikiEditor-publish-dialog-copywarn {
- margin-top: 0.5em;
-}
-
-.wikiEditor-publish-dialog-summary {
- margin-top: 1.5em;
-}
-
-.wikiEditor-publish-dialog-options {
- margin-top: 1.5em;
-}
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.js b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.js
index 04ae33c6..a5d44d42 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.js
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.js
@@ -75,7 +75,7 @@
// Defer building of modules, unless they require immediate creation
for ( mod in config ) {
module = config[ mod ];
- // Only create the dialog if it's supported, isn't filtered and doesn't exist yet
+ // Only create the dialog if it isn't filtered and doesn't exist yet
filtered = false;
if ( typeof module.filters !== 'undefined' ) {
for ( i = 0; i < module.filters.length; i++ ) {
@@ -92,7 +92,7 @@
}
// Re-select from the DOM, we might have removed the dialog just now
$existingDialog = $( '#' + module.id );
- if ( !filtered && $.wikiEditor.isSupported( module ) && $existingDialog.length === 0 ) {
+ if ( !filtered && $existingDialog.length === 0 ) {
$.wikiEditor.modules.dialogs.modules[ mod ] = module;
context.$textarea.trigger( 'wikiEditor-dialogs-setup-' + mod );
// If this dialog requires immediate creation, create it now
@@ -130,7 +130,7 @@
}
configuration.buttons = configuration.newButtons;
if ( module.htmlTemplate ) {
- $content = mw.template.get( 'jquery.wikiEditor.dialogs.config', module.htmlTemplate ).render();
+ $content = mw.template.get( 'ext.wikiEditor', module.htmlTemplate ).render();
} else if ( module.html instanceof jQuery ) {
$content = module.html;
} else {
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.less b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.less
index ee9ff98c..394e516b 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.less
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.dialogs.less
@@ -3,8 +3,6 @@
*/
.wikiEditor-toolbar-dialog {
- border: 0;
-
.ui-dialog-content {
/* stylelint-disable declaration-no-important */
fieldset {
@@ -14,7 +12,7 @@
}
/* stylelint-enable declaration-no-important */
- input[type='text'] {
+ input[ type='text' ] {
-moz-box-sizing: border-box;
-ms-box-sizing: border-box;
-webkit-box-sizing: border-box;
@@ -23,8 +21,8 @@
}
input {
- &[type='radio'],
- &[type='checkbox'] {
+ &[ type='radio' ],
+ &[ type='checkbox' ] {
margin-left: 0;
}
}
@@ -58,5 +56,5 @@ body {
}
.wikieditor-toolbar-dialog-hint {
- color: #999;
+ color: #54595d;
}
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.js b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.js
index efbe5de3..16ebcbb2 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.js
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.js
@@ -55,67 +55,23 @@
instances: [],
/**
- * For each browser name, an array of conditions that must be met are supplied in [operation, value]-form where
- * operation is a string containing a JavaScript compatible binary operator and value is either a number to be
- * compared with $.browser.versionNumber or a string to be compared with $.browser.version. If a browser is not
- * specifically mentioned, we just assume things will work.
- */
- browsers: {
- // Left-to-right languages
- ltr: {
- msie: [ [ '>=', 9 ] ],
- firefox: [ [ '>=', 4 ] ],
- opera: [ [ '>=', '10.5' ] ],
- safari: [ [ '>=', 5 ] ],
- chrome: [ [ '>=', 5 ] ],
- netscape: [ [ '>=', 9 ] ],
- blackberry: false,
- ipod: [ [ '>=', 6 ] ],
- iphone: [ [ '>=', 6 ] ]
- },
- // Right-to-left languages
- rtl: {
- msie: [ [ '>=', 9 ] ],
- firefox: [ [ '>=', 4 ] ],
- opera: [ [ '>=', '10.5' ] ],
- safari: [ [ '>=', 5 ] ],
- chrome: [ [ '>=', 5 ] ],
- netscape: [ [ '>=', 9 ] ],
- blackberry: false,
- ipod: [ [ '>=', 6 ] ],
- iphone: [ [ '>=', 6 ] ]
- }
- },
-
- /**
* Path to images - this is a bit messy, and it would need to change if this code (and images) gets moved into the
* core - or anywhere for that matter...
*/
imgPath: mw.config.get( 'wgExtensionAssetsPath' ) + '/WikiEditor/modules/images/',
/**
- * Checks the current browser against the browsers object to determine if the browser has been black-listed or not.
- * Because these rules are often very complex, the object contains configurable operators and can check against
- * either the browser version number or string. This process also involves checking if the current browser is among
- * those which we have configured as compatible or not. If the browser was not configured as compatible we just go on
- * assuming things will work - the argument here is to prevent the need to update the code when a new browser comes
- * to market. The assumption here is that any new browser will be built on an existing engine or be otherwise so
- * similar to another existing browser that things actually do work as expected. The merits of this argument, which
- * is essentially to blacklist rather than whitelist are debatable, but at this point we've decided it's the more
- * "open-web" way to go.
+ * Checks if the client supports WikiEditor.
*
- * @param {Object} module Module object, defaults to $.wikiEditor
+ * Since 1.31 this check is deprecated and can be skipped as all browsers
+ * which are served JS by MediaWiki support WikiEditor.
+ *
+ * @deprecated since 1.31
* @return {boolean}
*/
- isSupported: function ( module ) {
- // Fallback to the wikiEditor browser map if no special map is provided in the module
- var mod = module && 'browsers' in module ? module : $.wikiEditor;
- // Check for and make use of cached value and early opportunities to bail
- if ( typeof mod.supported === 'undefined' ) {
- // Run a browser support test and then cache and return the result
- mod.supported = $.client.test( mod.browsers );
- }
- return mod.supported;
+ isSupported: function () {
+ mw.log.warn( '$.wikiEditor.isSupported is deprecated.' );
+ return true;
},
/**
@@ -199,37 +155,15 @@
*
* @param {Object} icon Icon object from e.g. toolbar config
* @param {string} path Default icon path, defaults to $.wikiEditor.imgPath
- * @return {string}
- */
- autoIcon: function ( icon, path ) {
- var src = $.wikiEditor.autoLang( icon );
- path = path || $.wikiEditor.imgPath;
- // Prepend path if src is not absolute
- if ( src.substr( 0, 7 ) !== 'http://' && src.substr( 0, 8 ) !== 'https://' && src[ 0 ] !== '/' ) {
- src = path + src;
- }
- return src + '?' + mw.loader.getVersion( 'jquery.wikiEditor' );
- },
-
- /**
- * Get the sprite offset for a language if available, icon for a language if available, or the default offset or icon,
- * in that order of preference.
- *
- * @param {Object} icon Icon object, see autoIcon()
- * @param {Object} offset Offset object
- * @param {string} path Icon path, see autoIcon()
* @return {Object}
*/
- autoIconOrOffset: function ( icon, offset, path ) {
+ autoIcon: function ( icon, path ) {
var i, key, src;
path = path || $.wikiEditor.imgPath;
for ( i = 0; i < fallbackChain.length; i++ ) {
key = fallbackChain[ i ];
- if ( offset && hasOwn.call( offset, key ) ) {
- return offset[ key ];
- }
if ( icon && hasOwn.call( icon, key ) ) {
src = icon[ key ];
// Prepend path if src is not absolute
@@ -239,7 +173,7 @@
return src + '?' + mw.loader.getVersion( 'jquery.wikiEditor' );
}
}
- return offset || icon;
+ return icon;
}
};
@@ -249,17 +183,9 @@
* @return {jQuery}
*/
$.fn.wikiEditor = function () {
- var context, profile, hasFocus, cursorPos,
+ var context, hasFocus, cursorPos,
args, modules, module, e, call;
- // Skip any further work when running in browsers that are unsupported
- if ( !$.wikiEditor.isSupported() ) {
- return $( this );
- }
-
- // Save browser profile for detailed tests.
- profile = $.client.profile();
-
/* Initialization */
// The wikiEditor context is stored in the element's data, so when this function gets called again we can pick up right
@@ -309,10 +235,8 @@
modules = data;
}
for ( module in modules ) {
- // Check for the existence of an available / supported module with a matching name and a create function
- if ( typeof module === 'string' && typeof $.wikiEditor.modules[ module ] !== 'undefined' &&
- $.wikiEditor.isSupported( $.wikiEditor.modules[ module ] )
- ) {
+ // Check for the existence of an available module with a matching name and a create function
+ if ( typeof module === 'string' && typeof $.wikiEditor.modules[ module ] !== 'undefined' ) {
// Extend the context's core API with this module's own API calls
if ( 'api' in $.wikiEditor.modules[ module ] ) {
for ( call in $.wikiEditor.modules[ module ].api ) {
@@ -323,7 +247,10 @@
}
}
// Activate the module on this context
- if ( 'fn' in $.wikiEditor.modules[ module ] && 'create' in $.wikiEditor.modules[ module ].fn ) {
+ if ( 'fn' in $.wikiEditor.modules[ module ] &&
+ 'create' in $.wikiEditor.modules[ module ].fn &&
+ typeof context.modules[ module ] === 'undefined'
+ ) {
// Add a place for the module to put it's own stuff
context.modules[ module ] = {};
// Tell the module to create itself on the context
@@ -469,46 +396,23 @@
},
/**
- * Save scrollTop and cursor position for old IE (<=10)
- * Related to old IE 8 issues that are no longer reproducible
- */
- saveCursorAndScrollTop: function () {
- // Deprecated, do nothing
- },
-
- /**
- * Restore scrollTo and cursor position for IE (<=10)
- * Related to old IE 8 issues that are no longer reproducible
- */
- restoreCursorAndScrollTop: function () {
- var IHateIE8;
- if ( profile.name === 'msie' && document.selection && document.selection.createRange ) {
- IHateIE8 = context.$textarea.data( 'IHateIE8' );
- if ( IHateIE8 ) {
- context.$textarea.scrollTop( IHateIE8.scrollTop );
- context.$textarea.textSelection( 'setSelection', { start: IHateIE8.pos[ 0 ], end: IHateIE8.pos[ 1 ] } );
- context.$textarea.data( 'IHateIE8', null );
- }
- }
- },
-
- /**
- * Save text selection for old IE (<=10)
+ * Save text selection
*/
saveSelection: function () {
- if ( profile.name === 'msie' && document.selection && document.selection.createRange ) {
- context.$textarea.focus();
- context.savedSelection = document.selection.createRange();
- }
+ context.$textarea.focus();
+ context.savedSelection = {
+ selectionStart: context.$textarea[ 0 ].selectionStart,
+ selectionEnd: context.$textarea[ 0 ].selectionEnd
+ };
},
/**
- * Restore text selection for old IE (<=10)
+ * Restore text selection
*/
restoreSelection: function () {
- if ( profile.name === 'msie' && context.savedSelection !== null ) {
+ if ( context.savedSelection ) {
context.$textarea.focus();
- context.savedSelection.select();
+ context.$textarea[ 0 ].setSelectionRange( context.savedSelection.selectionStart, context.savedSelection.selectionEnd );
context.savedSelection = null;
}
}
@@ -594,8 +498,7 @@
modules[ args[ 1 ] ] = '';
}
for ( module in modules ) {
- // Only allow modules which are supported (and thus actually being turned on) affect the decision to extend
- if ( module in $.wikiEditor.modules && $.wikiEditor.isSupported( $.wikiEditor.modules[ module ] ) ) {
+ if ( module in $.wikiEditor.modules ) {
// Activate all required core extensions on context
for ( e in $.wikiEditor.extensions ) {
if (
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.less b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.less
index 8258febf..ac9dcf26 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.less
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.less
@@ -8,7 +8,6 @@
position: relative;
clear: both;
width: 100%;
- background-color: #e0eef7;
textarea {
width: 100%;
@@ -24,12 +23,12 @@
}
.wikiEditor-ui-view {
- border: 1px solid #c0c0c0;
+ border: 1px solid #c8ccd1;
}
.wikiEditor-ui-top {
position: relative;
- border-bottom: 1px solid #c0c0c0;
+ border-bottom: 1px solid #c8ccd1;
}
.wikiEditor-ui-left {
@@ -39,7 +38,7 @@
.wikiEditor-ui-right {
float: right;
- background: #f3f3f3;
+ background: #f8f9fa;
overflow: hidden;
}
}
@@ -60,15 +59,15 @@
height: 2.5em;
margin-right: -1px;
background-color: #fff;
- border-left: 1px solid #c0c0c0;
- border-top: 1px solid #c0c0c0;
+ border-left: 1px solid #c8ccd1;
+ border-top: 1px solid #c8ccd1;
div {
float: left;
height: 2.5em;
- background-color: #f3f3f3;
- border-right: 1px solid #c0c0c0;
- border-bottom: 1px solid #c0c0c0;
+ background-color: #f8f9fa;
+ border-right: 1px solid #c8ccd1;
+ border-bottom: 1px solid #c8ccd1;
a {
display: inline-block;
@@ -82,7 +81,7 @@
background-color: #fff;
a {
- color: #333;
+ color: #222;
&:hover {
text-decoration: none;
@@ -110,8 +109,8 @@
}
.wikiEditor-ui-loading {
- background: #f3f3f3;
- border: 1px solid #c0c0c0;
+ background: #f8f9fa;
+ border: 1px solid #c8ccd1;
left: 0;
height: 100%;
margin: -1px;
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.config.js b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.config.js
index 51ab1113..c4f63565 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.config.js
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.config.js
@@ -19,47 +19,7 @@
bold: {
labelMsg: 'wikieditor-toolbar-tool-bold',
type: 'button',
- offset: {
- 'default': [ 2, -574 ],
- en: [ 2, -142 ],
- cs: [ 2, -142 ],
- de: [ 2, -214 ],
- fa: [ 2, -142 ],
- fr: [ 2, -286 ],
- gl: [ 2, -358 ],
- es: [ 2, -358 ],
- he: [ 2, -142 ],
- hu: [ 2, -214 ],
- it: [ 2, -286 ],
- nl: [ 2, -502 ],
- pt: [ 2, -358 ],
- pl: [ 2, -142 ],
- ml: [ 2, -142 ]
- },
- icon: {
- 'default': 'format-bold.png',
- en: 'format-bold-B.png',
- ce: 'format-bold-Iab.svg',
- cs: 'format-bold-B.png',
- de: 'format-bold-F.png',
- fa: 'format-bold-B.png',
- fr: 'format-bold-G.png',
- gl: 'format-bold-N.png',
- es: 'format-bold-N.png',
- eu: 'format-bold-L.png',
- he: 'format-bold-B.png',
- hu: 'format-bold-F.png',
- hy: 'format-bold-hy.png',
- it: 'format-bold-G.png',
- ka: 'format-bold-ka.png',
- ky: 'format-bold-ru.png',
- nl: 'format-bold-V.png',
- os: 'format-bold-os.png',
- pt: 'format-bold-N.png',
- pl: 'format-bold-B.png',
- ru: 'format-bold-ru.png',
- ml: 'format-bold-B.png'
- },
+ oouiIcon: 'bold',
action: {
type: 'encapsulate',
options: {
@@ -77,48 +37,7 @@
id: 'italic',
labelMsg: 'wikieditor-toolbar-tool-italic',
type: 'button',
- offset: {
- 'default': [ 2, -718 ],
- en: [ 2, -862 ],
- cs: [ 2, -862 ],
- de: [ 2, -934 ],
- fa: [ 2, -862 ],
- fr: [ 2, -862 ],
- gl: [ 2, -790 ],
- es: [ 2, -790 ],
- he: [ 2, -862 ],
- it: [ 2, -790 ],
- ky: [ 2, -934 ],
- nl: [ 2, -790 ],
- os: [ 2, -934 ],
- pt: [ 2, -862 ],
- pl: [ 2, -862 ],
- ru: [ 2, -934 ],
- ml: [ 2, -862 ]
- },
- icon: {
- 'default': 'format-italic.png',
- en: 'format-italic-I.png',
- cs: 'format-italic-I.png',
- de: 'format-italic-K.png',
- fa: 'format-italic-I.png',
- fr: 'format-italic-I.png',
- gl: 'format-italic-C.png',
- es: 'format-italic-C.png',
- eu: 'format-italic-E.png',
- he: 'format-italic-I.png',
- hu: 'format-italic-D.png',
- hy: 'format-italic-hy.png',
- it: 'format-italic-C.png',
- ka: 'format-italic-ka.png',
- ky: 'format-italic-K.png',
- nl: 'format-italic-C.png',
- os: 'format-italic-K.png',
- pt: 'format-italic-I.png',
- pl: 'format-italic-I.png',
- ru: 'format-italic-K.png',
- ml: 'format-italic-I.png'
- },
+ oouiIcon: 'italic',
action: {
type: 'encapsulate',
options: {
@@ -134,68 +53,10 @@
},
insert: {
tools: {
- xlink: {
- labelMsg: 'wikieditor-toolbar-tool-xlink',
- type: 'button',
- icon: 'insert-xlink.png',
- offset: [ -70, 2 ],
- action: {
- type: 'encapsulate',
- options: {
- pre: '[',
- periMsg: 'wikieditor-toolbar-tool-xlink-example',
- post: ']'
- }
- }
- },
- ilink: {
- labelMsg: 'wikieditor-toolbar-tool-ilink',
- type: 'button',
- icon: 'insert-ilink.png',
- offset: [ 2, -1582 ],
- action: {
- type: 'encapsulate',
- options: {
- pre: '[[',
- periMsg: 'wikieditor-toolbar-tool-ilink-example',
- post: ']]'
- }
- }
- },
- file: {
- labelMsg: 'wikieditor-toolbar-tool-file',
- type: 'button',
- icon: 'insert-file.png',
- offset: [ 2, -1438 ],
- action: {
- type: 'encapsulate',
- options: {
- pre: '[[' + fileNamespace + ':',
- periMsg: 'wikieditor-toolbar-tool-file-example',
- post: '|' + mw.config.get( 'wgWikiEditorMagicWords' ).img_thumbnail + ']]'
- }
- }
- },
- reference: {
- labelMsg: 'wikieditor-toolbar-tool-reference',
- filters: [ 'body.ns-subject' ],
- type: 'button',
- offset: [ 2, -1798 ],
- icon: 'insert-reference.png',
- action: {
- type: 'encapsulate',
- options: {
- pre: '<ref>',
- periMsg: 'wikieditor-toolbar-tool-reference-example',
- post: '</ref>'
- }
- }
- },
signature: {
labelMsg: 'wikieditor-toolbar-tool-signature',
type: 'button',
- offset: [ 2, -1870 ],
- icon: 'insert-signature.png',
+ oouiIcon: 'signature',
action: {
type: 'encapsulate',
options: {
@@ -284,14 +145,7 @@
ulist: {
labelMsg: 'wikieditor-toolbar-tool-ulist',
type: 'button',
- icon: {
- 'default': 'format-ulist.png',
- 'default-rtl': 'format-ulist-rtl.png'
- },
- offset: {
- 'default': [ 2, -1366 ],
- 'default-rtl': [ -70, -286 ]
- },
+ oouiIcon: 'listBullet',
action: {
type: 'encapsulate',
options: {
@@ -306,14 +160,7 @@
olist: {
labelMsg: 'wikieditor-toolbar-tool-olist',
type: 'button',
- icon: {
- 'default': 'format-olist.png',
- 'default-rtl': 'format-olist-rtl.png'
- },
- offset: {
- 'default': [ 2, -1078 ],
- 'default-rtl': [ -70, -358 ]
- },
+ oouiIcon: 'listNumbered',
action: {
type: 'encapsulate',
options: {
@@ -328,8 +175,7 @@
nowiki: {
labelMsg: 'wikieditor-toolbar-tool-nowiki',
type: 'button',
- icon: 'insert-nowiki.png',
- offset: [ -70, -70 ],
+ oouiIcon: 'noWikiText',
action: {
type: 'encapsulate',
options: {
@@ -342,8 +188,7 @@
newline: {
labelMsg: 'wikieditor-toolbar-tool-newline',
type: 'button',
- icon: 'insert-newline.png',
- offset: [ 2, -1726 ],
+ oouiIcon: 'newline',
action: {
type: 'encapsulate',
options: {
@@ -358,8 +203,7 @@
big: {
labelMsg: 'wikieditor-toolbar-tool-big',
type: 'button',
- icon: 'format-big.png',
- offset: [ 2, 2 ],
+ oouiIcon: 'bigger',
action: {
type: 'encapsulate',
options: {
@@ -372,8 +216,7 @@
small: {
labelMsg: 'wikieditor-toolbar-tool-small',
type: 'button',
- icon: 'format-small.png',
- offset: [ 2, -1150 ],
+ oouiIcon: 'smaller',
action: {
type: 'encapsulate',
options: {
@@ -386,8 +229,7 @@
superscript: {
labelMsg: 'wikieditor-toolbar-tool-superscript',
type: 'button',
- icon: 'format-superscript.png',
- offset: [ 2, -1294 ],
+ oouiIcon: 'superscript',
action: {
type: 'encapsulate',
options: {
@@ -400,8 +242,7 @@
subscript: {
labelMsg: 'wikieditor-toolbar-tool-subscript',
type: 'button',
- icon: 'format-subscript.png',
- offset: [ 2, -1222 ],
+ oouiIcon: 'subscript',
action: {
type: 'encapsulate',
options: {
@@ -419,8 +260,7 @@
gallery: {
labelMsg: 'wikieditor-toolbar-tool-gallery',
type: 'button',
- icon: 'insert-gallery.png',
- offset: [ 2, -1510 ],
+ oouiIcon: 'imageGallery',
action: {
type: 'encapsulate',
options: {
@@ -434,33 +274,10 @@
}
}
},
- table: {
- labelMsg: 'wikieditor-toolbar-tool-table',
- type: 'button',
- icon: 'insert-table.png',
- offset: [ 2, -1942 ],
- filters: [ '#wpTextbox1:not(.toolbar-dialogs)' ],
- action: {
- type: 'encapsulate',
- options: {
- pre: '{| class="wikitable" border="1"\n|',
- periMsg: 'wikieditor-toolbar-tool-table-example-old',
- post: '\n|}',
- ownline: true
- }
- }
- },
redirect: {
labelMsg: 'wikieditor-toolbar-tool-redirect',
type: 'button',
- icon: {
- 'default': 'insert-redirect.png',
- 'default-rtl': 'insert-redirect-rtl.png'
- },
- offset: {
- 'default': [ -70, -142 ],
- 'default-rtl': [ -70, -502 ]
- },
+ oouiIcon: 'articleRedirect',
action: {
type: 'encapsulate',
options: {
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.js b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.js
index 5ea5b662..c701ad58 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.js
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.js
@@ -117,8 +117,7 @@
actions = $characters.data( 'actions' );
for ( i = 0; i < data.characters.length; i++ ) {
// Character
- $characters
- .append(
+ $characters.append(
$( $.wikiEditor.modules.toolbar.fn.buildCharacter( data.characters[ i ], actions ) )
.mousedown( function ( e ) {
// No dragging!
@@ -285,7 +284,7 @@
if ( label ) {
$label = $( '<span>' )
.addClass( 'label' )
- .html( label );
+ .text( label );
$group.append( $label );
}
empty = true;
@@ -306,7 +305,7 @@
return $group;
},
buildTool: function ( context, id, tool ) {
- var i, label, $button, offsetOrIcon, $select, $options,
+ var i, label, $button, icon, $select, $options, oouiButton,
option, optionLabel;
if ( 'filters' in tool ) {
for ( i = 0; i < tool.filters.length; i++ ) {
@@ -318,28 +317,42 @@
label = $.wikiEditor.autoMsg( tool, 'label' );
switch ( tool.type ) {
case 'button':
- offsetOrIcon = $.wikiEditor.autoIconOrOffset(
- tool.icon,
- tool.offset,
- $.wikiEditor.imgPath + 'toolbar/'
- );
- $button = $( '<a>' )
- .attr( {
- href: '#',
- title: label,
- rel: id,
- role: 'button',
- 'class': 'tool tool-button'
- } )
- .text( label );
- if ( typeof offsetOrIcon === 'object' ) {
- $button
- .addClass( 'wikiEditor-toolbar-spritedButton' )
- .css( 'backgroundPosition', offsetOrIcon[ 0 ] + 'px ' + offsetOrIcon[ 1 ] + 'px' );
- } else if ( offsetOrIcon !== undefined ) { // Bug T172500
- $button
- .css( 'background-image', 'url(' + offsetOrIcon + ')' );
+ if ( tool.oouiIcon ) {
+ oouiButton = new OO.ui.ButtonWidget( {
+ framed: false,
+ classes: [ 'tool' ],
+ icon: tool.oouiIcon,
+ title: label
+ } );
+ $button = oouiButton.$element;
+ $button.attr( 'rel', id );
+ $button.data( 'ooui', oouiButton );
+ } else {
+ $button = $( '<a>' )
+ .attr( {
+ href: '#',
+ title: label,
+ rel: id,
+ role: 'button',
+ 'class': 'tool tool-button'
+ } )
+ .text( label );
+ if ( tool.icon ) {
+ icon = $.wikiEditor.autoIcon(
+ tool.icon,
+ $.wikiEditor.imgPath + 'toolbar/'
+ );
+ $button.css( 'background-image', 'url(' + icon + ')' );
+ }
}
+ $button.data( 'setActive', function ( active ) {
+ $button.toggleClass( 'tool-active', active );
+
+ // OOUI button
+ if ( $button.data( 'ooui' ) ) {
+ $button.data( 'ooui' ).setFlags( { progressive: active } );
+ }
+ } );
if ( 'action' in tool ) {
$button
.data( 'action', tool.action )
@@ -395,20 +408,20 @@
}
$select.append( $( '<div>' ).addClass( 'menu' ).append( $options ) );
$select.append( $( '<a>' )
- .addClass( 'label' )
- .text( label )
- .data( 'options', $options )
- .attr( 'href', '#' )
- .mousedown( function ( e ) {
- // No dragging!
- e.preventDefault();
- return false;
- } )
- .click( function ( e ) {
- $( this ).data( 'options' ).animate( { opacity: 'toggle' }, 'fast' );
- e.preventDefault();
- return false;
- } )
+ .addClass( 'label' )
+ .text( label )
+ .data( 'options', $options )
+ .attr( 'href', '#' )
+ .mousedown( function ( e ) {
+ // No dragging!
+ e.preventDefault();
+ return false;
+ } )
+ .click( function ( e ) {
+ $( this ).data( 'options' ).animate( { opacity: 'toggle' }, 'fast' );
+ e.preventDefault();
+ return false;
+ } )
);
return $select;
default:
diff --git a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.less b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.less
index da393bd9..69d50d54 100644
--- a/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.less
+++ b/www/wiki/extensions/WikiEditor/modules/jquery.wikiEditor.toolbar.less
@@ -7,9 +7,7 @@
.wikiEditor-ui-toolbar {
position: relative;
display: block;
- .background-image('images/toolbar/base.png');
- background-position: left top;
- background-repeat: repeat-x;
+ .vertical-gradient( #fdfefe, #e8f2f8, 0, 32px );
.empty {
display: none;
@@ -25,8 +23,8 @@
.section {
float: left;
width: 100%;
- border-top: 1px solid #ddd;
- background-color: #e0eef7;
+ border-top: 1px solid #c8ccd1;
+ background-color: #eaf3ff;
}
.section-hidden {
@@ -66,7 +64,7 @@
a.current,
a.current:visited {
.background-image-svg('images/toolbar/arrow-down.svg', 'images/toolbar/arrow-down.png');
- color: #333;
+ color: #222;
&:hover {
text-decoration: none;
@@ -89,7 +87,7 @@
float: left;
height: 26px;
padding-right: 6px;
- border-right: 1px solid #ddd;
+ border-right: 1px solid #c8ccd1;
margin: 3px;
/* Toolbar */
@@ -101,7 +99,7 @@
margin: 2px;
margin-left: 5px;
margin-right: 8px;
- color: #777;
+ color: #666;
cursor: default;
}
@@ -119,7 +117,7 @@
margin: 2px;
height: 22px;
cursor: pointer;
- border: 1px solid #c0c0c0;
+ border: 1px solid #c8ccd1;
padding: 0;
margin-right: 0;
background-color: #fff;
@@ -135,7 +133,7 @@
margin-right: 4px;
cursor: pointer;
text-decoration: none;
- color: #333;
+ color: #222;
}
.menu {
@@ -144,7 +142,7 @@
display: none;
margin-left: -1px;
margin-top: 22px;
- border: 1px solid #c0c0c0;
+ border: 1px solid #c8ccd1;
background-color: #fff;
}
}
@@ -158,42 +156,42 @@
white-space: nowrap;
&:hover {
- background-color: #e0eef7;
+ background-color: #eaf3ff;
}
- &[rel='heading-2'] {
+ &[ rel='heading-2' ] {
font-size: 150%;
font-weight: normal;
}
- &[rel='heading-3'] {
+ &[ rel='heading-3' ] {
font-size: 132%;
font-weight: normal;
}
- &[rel='heading-4'] {
+ &[ rel='heading-4' ] {
font-size: 116%;
font-weight: normal;
}
- &[rel='heading-5'] {
+ &[ rel='heading-5' ] {
font-size: 100%;
font-weight: bold;
}
}
}
}
+
+ &:last-of-type {
+ border-right: 0;
+ }
}
.group-search {
float: right;
padding: 0 0 0 6px;
border-right: 0;
- border-left: 1px solid #ddd;
- }
-
- .group-insert {
- border-right: 0;
+ border-left: 1px solid #c8ccd1;
}
/* Booklet */
@@ -213,14 +211,14 @@
}
.current {
- background-color: #fafafa;
- color: #333;
+ background-color: #eaecf0;
+ color: #222;
cursor: default;
}
}
.pages {
- background-color: #fafafa;
+ background-color: #f8f9fa;
height: 125px;
overflow: auto;
}
@@ -238,12 +236,12 @@
}
th {
- color: #999;
+ color: #54595d;
}
td {
color: #000;
- border-top: 1px solid #eee;
+ border-top: 1px solid #eaecf0;
}
th,
@@ -284,17 +282,17 @@
/* Characters Pages */
.page-characters {
+ padding-bottom: 5px;
div {
span {
- border: 1px solid #ddd;
+ border: 1px solid #c8ccd1;
padding: 5px;
padding-left: 8px;
padding-right: 8px;
margin-left: 5px;
margin-top: 5px;
height: 1em;
- float: left;
- display: block;
+ display: inline-block;
color: #000;
text-decoration: none;
cursor: pointer;
@@ -305,12 +303,12 @@
&:hover {
background-color: #fff;
text-decoration: none;
- border-color: #a8d7f9;
+ border-color: #36c;
}
}
}
- div[dir='rtl'] span {
+ div[ dir='rtl' ] span {
/* @noflip */
direction: rtl;
}
@@ -320,8 +318,8 @@
.tool-button {
background-position: 2px 2px;
background-repeat: no-repeat;
- display: block;
- float: left;
+ display: inline-block;
+ vertical-align: middle;
height: 22px;
text-indent: -9999px;
width: 22px;
@@ -330,15 +328,41 @@
overflow: hidden;
}
-/* Sprited Buttons */
-.wikiEditor-toolbar-spritedButton {
- .background-image-svg('images/toolbar/button-sprite.svg', 'images/toolbar/button-sprite.png');
+/* OOUI buttons */
+.tool.oo-ui-buttonElement-frameless.oo-ui-iconElement {
+ margin: 0;
+ padding: 3px;
+ > .oo-ui-buttonElement-button {
+ padding: 0;
+ border: 0;
+ > .oo-ui-iconElement-icon {
+ margin: 0;
+ width: 20px;
+ height: 20px;
+ min-width: 20px;
+ min-height: 20px;
+ left: 0;
+ // Reduce opacity like Apex theme
+ opacity: 0.7;
+ }
+ }
+}
+
+.tool-button.tool-active,
+.tool.tool-active.oo-ui-buttonElement-frameless.oo-ui-iconElement {
+ outline: 1px solid #dae5ec;
+ background-color: #ecf4f9;
+ box-shadow: inset 0 -10px 10px rgba( 255, 255, 255, 0.4 );
+}
+
+.tool.tool-active.oo-ui-buttonElement-frameless.oo-ui-iconElement > .oo-ui-buttonElement-button > .oo-ui-iconElement-icon {
+ opacity: 0.9;
}
.ui-widget {
table {
td.wikieditor-toolbar-table-preview-wrapper {
- background: #e5e5e5;
+ background: #eaecf0;
padding: 10px;
span {
padding: 4px 6px 0;
diff --git a/www/wiki/extensions/WikiEditor/tests/phan/config.php b/www/wiki/extensions/WikiEditor/tests/phan/config.php
new file mode 100644
index 00000000..543ff740
--- /dev/null
+++ b/www/wiki/extensions/WikiEditor/tests/phan/config.php
@@ -0,0 +1,22 @@
+<?php
+
+$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
+
+$cfg['directory_list'] = array_merge(
+ $cfg['directory_list'],
+ [
+ './../../extensions/EventLogging',
+ ]
+);
+
+$cfg['exclude_analysis_directory_list'] = array_merge(
+ $cfg['exclude_analysis_directory_list'],
+ [
+ './../../extensions/EventLogging',
+ ]
+);
+
+// \WikiPage->ConfirmEdit_ActivateCaptcha not exist is a false-positive
+$cfg['suppress_issue_types'][] = 'PhanUndeclaredProperty';
+
+return $cfg;
diff --git a/www/wiki/extensions/WikiEditor/tests/qunit/ext.wikiEditor.toolbar.test.js b/www/wiki/extensions/WikiEditor/tests/qunit/ext.wikiEditor.toolbar.test.js
index 7f7fc150..2ae6a256 100644
--- a/www/wiki/extensions/WikiEditor/tests/qunit/ext.wikiEditor.toolbar.test.js
+++ b/www/wiki/extensions/WikiEditor/tests/qunit/ext.wikiEditor.toolbar.test.js
@@ -10,7 +10,7 @@
}
} ) );
- QUnit.test( 'Toolbars', 16, function ( assert ) {
+ QUnit.test( 'Toolbars', function ( assert ) {
// Add toolbar section
var data = {
sections: {
@@ -141,7 +141,7 @@
assert.equal( this.$ui.find( '*[rel="emoticons"].section' ).length, 0, 'After removing toolbar section' );
} );
- QUnit.test( 'Booklets', 20, function ( assert ) {
+ QUnit.test( 'Booklets', function ( assert ) {
// Add booklet section
var data = {
sections: {